Skip to content

Commit

Permalink
AIExample is optional - fix to type error
Browse files Browse the repository at this point in the history
  • Loading branch information
Catrovitch committed Aug 1, 2024
1 parent fc9ddc7 commit 1c62dbc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/client/pages/InventorsAssistant/FirstStep.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const FirstStep: React.FC<FirstStepProps> = ({

const [aiElaboration3, setAiElaboration3] = useState('')

const handleFirstCheck = async (aiExample: string) => {
const handleFirstCheck = async (aiExample?: string) => {
setCurrentStep(2)
setAiInputFeedbackSuccess1('info')
const message = aiExample || inventiveMessage
Expand All @@ -71,7 +71,7 @@ const FirstStep: React.FC<FirstStepProps> = ({
}
}

const handleSecondCheck = async (aiExample: string) => {
const handleSecondCheck = async (aiExample?: string) => {
setCurrentStep(3)
setAiInputFeedbackSuccess2('info')
const message = aiExample || publicityMessage
Expand All @@ -95,7 +95,7 @@ const FirstStep: React.FC<FirstStepProps> = ({
}
}

const handleThirdCheck = async (aiExample: string) => {
const handleThirdCheck = async (aiExample?: string) => {
setAiInputFeedbackSuccess3('info')
const message = aiExample || industrialMessage
const response = await apiClient.post('/llm/step1check3', {
Expand Down
2 changes: 1 addition & 1 deletion src/client/pages/InventorsAssistant/LlmInputFeedback.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ type LlmInputFeedbackProps = {
alertSeverity: 'info' | 'success' | 'warning'
aiElaboration: string
setUserInput: React.Dispatch<React.SetStateAction<string>>
handleStepCheck: (aiElaboration?: string) => void
handleStepCheck: (aiExample?: string) => void
}

const LlmInputFeedback = ({
Expand Down
2 changes: 1 addition & 1 deletion src/client/pages/InventorsAssistant/UserInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import LlmInputFeedback from './LlmInputFeedback'
type UserInputProps = {
inventiveMessage: string
setUserInput: React.Dispatch<React.SetStateAction<string>>
handleStepCheck: (aiElaboration?: string) => void
handleStepCheck: (aiExample?: string) => void
aiInputFeedback: string
aiInputFeedbackSuccess: 'info' | 'success' | 'warning'
aiElaboration: string
Expand Down

0 comments on commit 1c62dbc

Please sign in to comment.