Skip to content

Commit 7fe526a

Browse files
committed
chore: update conditions to show invalid editor
1 parent d1cbb15 commit 7fe526a

File tree

1 file changed

+3
-2
lines changed
  • packages/frontend/src/pages/AiBuilder

1 file changed

+3
-2
lines changed

packages/frontend/src/pages/AiBuilder/index.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,11 @@ import {
1414
} from './AiBuilderContext'
1515

1616
function AiBuilderContent() {
17-
const { aiBuilderType, flowName, isFormMode } = useAiBuilderContext()
17+
const { aiBuilderType, flowName, isFormMode, chatInput, chatMessages } =
18+
useAiBuilderContext()
1819

1920
// TODO(kevinkim-ogp): remove this once A/B test is complete
20-
if (aiBuilderType === 'ai-form') {
21+
if (aiBuilderType === 'ai-form' && !chatInput && chatMessages?.length === 0) {
2122
return <InvalidEditorPage message="You do not have access to this." />
2223
}
2324

0 commit comments

Comments
 (0)