Skip to content
Snippets Groups Projects
Unverified Commit 2afae5a6 authored by Avanish Singh's avatar Avanish Singh Committed by GitHub
Browse files

Add files via upload

parent 2f9ea755
No related branches found
No related tags found
No related merge requests found
......@@ -12,7 +12,7 @@ const ChatbotComponent = () => {
])
const greetingMessage = {
info: "Hey, Welcome to FoodWhizz, What would you like to have today? Say Hey to start...",
info: "Hey, Welcome to FoodWhizz, What would you like to have today? Enter name of food you like to make today",
type: "left",
name: "FoodWhizz"
};
......@@ -28,9 +28,9 @@ const ChatbotComponent = () => {
const newUserMessage = createMessage(value_info, value_type, "User");
setMessages([...messages, newUserMessage]);
socket.emit('Client message',value_info)
socket.emit('client message',value_info)
socket.on('bot-message',(data) =>{
const newBotMessage = createMessage(data, "left", "Bot");
const newBotMessage = createMessage(data, "left", "FoodWhizz");
setMessages([...messages,newUserMessage,newBotMessage]);
})
}
......@@ -72,4 +72,4 @@ const ChatbotComponent = () => {
);
};
export default ChatbotComponent;
export default ChatbotComponent;
\ No newline at end of file
......@@ -23,7 +23,7 @@ const InputSection = (props) => {
return (
<div className="header_bottom" id="input">
<textarea id="input_section" ref={textareaRef} onKeyDown={handleKeyDown} placeholder="say HEY to start" value={value} onChange={event => setValue(event.target.value)}></textarea>
<textarea id="input_section" ref={textareaRef} onKeyDown={handleKeyDown} placeholder="Name food you wanna have today" value={value} onChange={event => setValue(event.target.value)}></textarea>
<button className="send_button" type="submit" id="send" onClick={HandleSend}>Send</button>
</div>
);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment