Skip to content

Commit

Permalink
chatgpt to genie
Browse files Browse the repository at this point in the history
  • Loading branch information
vickeykumar committed Jun 27, 2024
1 parent a869662 commit bc66725
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 23 deletions.
2 changes: 1 addition & 1 deletion src/resources/chat-widget/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ async function init() {
);
open({ target } as Event);
}
addMessageToHistory("system", "welcome to openrepl.com");
addMessageToHistory("system", "welcome to openrepl.com!! I am Genie. your OpenRepl AI assistant.");
addMessageToHistory("system", "documentation: "+documentation);
addMessageToHistory("system", "keywords: "+ keywords);
setupFBListener();
Expand Down
17 changes: 1 addition & 16 deletions src/resources/chat-widget/src/widget.html
Original file line number Diff line number Diff line change
@@ -1,21 +1,6 @@
<div id="chat-widget__header">
<div id="chat-widget__title">
<svg
id="chat-widget__title_icon"
width="24"
height="19"
viewBox="0 0 24 19"
>
<path
d="M9 6C9.55229 6 10 6.44772 10 7V9C10 9.55228 9.55229 10 9 10C8.44771 10 8 9.55228 8 9V7C8 6.44772 8.44771 6 9 6Z"
/>
<path
d="M16 7C16 6.44772 15.5523 6 15 6C14.4477 6 14 6.44772 14 7V9C14 9.55228 14.4477 10 15 10C15.5523 10 16 9.55228 16 9V7Z"
/>
<path
d="M19.2099 16C19.0086 16 18.815 16.0768 18.6684 16.2147L16.4858 18.269C15.2525 19.4298 13.2248 18.6278 13.1191 16.9374C13.0862 16.4105 12.6493 16 12.1213 16H5C3.34315 16 2 14.6569 2 13V9C2 9.55228 1.55228 10 1 10C0.447715 10 0 9.55228 0 9V6C0 5.44772 0.447715 5 1 5C1.55228 5 2 5.44772 2 6V3C2 1.34315 3.34315 0 5 0H19C20.6569 0 22 1.34315 22 3V6C22 5.44772 22.4477 5 23 5C23.5523 5 24 5.44772 24 6V9C24 9.55228 23.5523 10 23 10C22.4477 10 22 9.55228 22 9V13.2099C22 14.7508 20.7508 16 19.2099 16ZM5 2C4.44772 2 4 2.44772 4 3V13C4 13.5523 4.44772 14 5 14H12.1213C13.7053 14 15.0163 15.2315 15.1152 16.8124L17.2977 14.7583C17.8152 14.2712 18.4992 14 19.2099 14C19.6463 14 20 13.6463 20 13.2099V3C20 2.44772 19.5523 2 19 2H5Z"
/>
</svg>
<?xml version="1.0" encoding="utf-8"?><svg version="1.1" id="chat-widget__title_icon" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="50" height="50" viewBox="-30 0 128 125" xml:space="preserve"><style type="text/css">.st0{fill-rule:evenodd;clip-rule:evenodd;}</style><g><path class="st0" d="M55.41,80.68c-3.63,1.09-7.09,1.07-10.44,0.22c-3.58-0.91-7-2.78-10.3-5.27c-3.44,2.58-7.04,4.35-10.84,5.12 c-3.66,0.74-7.47,0.54-11.45-0.75c-1.64,9.06,0.1,16.51,4.31,22.79c3.97,5.93,10.16,10.87,17.82,15.17 c-0.29-1.2-0.48-2.36-0.57-3.48c-0.19-2.34,0.06-4.48,0.74-6.44c1.63-4.74,5.4-7.32,9.4-10.06C49.28,94.4,54.92,90.52,55.41,80.68 L55.41,80.68z M24.03,10.16c-1.5-5.84,2.44-10.46,8.4-10.14c4.06,0.22,6.89,2.39,9.19,4.79c3.86,4.02,6.2,8.66,10.32,5.64 c-0.05,3.7-1.83,6.21-5.55,6.92c0.65,1.34,1.15,2.83,1.45,4.48c0.07,0.38,0.13,0.76,0.18,1.15c1.08,0.46,2.01,1.16,2.71,2.01 c0.84,1.02,1.35,2.27,1.39,3.63c0.05,1.41-0.41,2.73-1.24,3.82c1.45,0.38,2.52,1.69,2.52,3.26c0,1.86-1.51,3.37-3.37,3.37 c-1.74,0-3.18-1.33-3.35-3.03c-0.94,2.87-2.07,5.62-4.09,7.82c-0.3,0.32-0.61,0.61-0.94,0.88c1.78,0.1,3.53,0.24,5.23,0.42 c9.12,1.01,15.17,4.63,18.52,9.2c1.9,2.6,2.93,5.5,3.15,8.41c0.22,2.91-0.36,5.83-1.68,8.48c-1.64,3.29-4.42,6.14-8.21,8.01 c0.03,12.59-6.65,17.18-12.78,21.39c-3.54,2.43-6.87,4.71-8.15,8.44c-0.53,1.54-0.72,3.25-0.57,5.13c0.16,1.94,0.68,4.06,1.58,6.38 c0.19,0.43,0.19,0.94-0.04,1.39c-0.41,0.8-1.38,1.12-2.18,0.71C26.8,117.75,18.9,111.9,14,104.59c-4.81-7.18-6.72-15.7-4.63-26.05 c-1.5-0.82-2.87-1.81-4.07-2.94c-2.02-1.9-3.55-4.2-4.44-6.72c-1.78-5.07-0.93-10.98,3.98-16.35c1.68-1.84,3.71-3.26,5.99-4.35 c2.23-1.07,4.69-1.83,7.28-2.37c1.31-0.27,2.65-0.49,4.01-0.65c-0.74-0.61-1.4-1.31-1.97-2.08c-0.64-0.88-1.17-1.87-1.57-2.98 c-0.03-0.06-0.07-0.11-0.1-0.17c-0.54-0.96-1.04-2-1.47-3.1c-0.46,1.31-1.71,2.26-3.18,2.26c-1.86,0-3.37-1.51-3.37-3.37 c0-1.21,0.64-2.28,1.61-2.87c-0.56-0.92-0.87-1.97-0.87-3.08c0-1.36,0.47-2.62,1.28-3.67c0.66-0.86,1.56-1.57,2.6-2.07 c0.07-0.79,0.18-1.58,0.33-2.36c1.05-5.46,4.26-9.23,8.28-11.31C23.79,10.28,23.91,10.22,24.03,10.16L24.03,10.16z M36.62,47.81 c-1.47,0.98-2.5,2.21-2.39,4.52c-2.68-0.43-3.59-1.52-5.04-3.52c-0.69-0.18-1.47-0.48-2.27-0.84c-0.23,0.01-0.47,0.03-0.7,0.04 c-2.57,0.17-5.09,0.46-7.47,0.96c-2.35,0.49-4.56,1.17-6.53,2.11c-1.92,0.92-3.62,2.11-5,3.62c-3.99,4.37-4.71,9.09-3.3,13.11 c0.71,2.02,1.96,3.87,3.6,5.42c1.66,1.57,3.73,2.82,6.06,3.62c5.78,1.98,13.14,1.13,19.91-4.68c0.55-0.69,1.12-1.34,1.71-1.95 c-1.76-1.57-3.55-2.63-5.36-3.24c-2.18-0.74-4.43-0.84-6.73-0.44c-0.88,0.15-1.72-0.44-1.88-1.32c-0.15-0.88,0.44-1.72,1.32-1.88 c2.82-0.49,5.59-0.35,8.31,0.56c2.31,0.78,4.55,2.12,6.72,4.1c0.47-0.39,0.95-0.76,1.45-1.11c2.04-1.46,4.25-2.61,6.59-3.52 c0.83-0.32,1.77,0.09,2.09,0.93c0.32,0.83-0.09,1.77-0.92,2.09c-2.09,0.81-4.07,1.84-5.88,3.14c-1.39,0.99-2.69,2.15-3.89,3.48 c2.45,1.83,4.94,3.26,7.49,4.13c2.92,1,5.94,1.26,9.1,0.52l0,0c5.02-1.24,8.57-4.24,10.39-7.87c1.06-2.12,1.53-4.46,1.35-6.79 c-0.18-2.33-1-4.65-2.53-6.74c-2.85-3.9-8.15-6.99-16.26-7.89c-2.03-0.22-4.08-0.38-6.14-0.47C39.14,47.86,37.88,47.83,36.62,47.81 L36.62,47.81z M29.83,44.01c1.16-0.84,1.44-3.08,2.81-3.03c1.42,0.05,1.61,2.54,2.89,2.88l0.01,0.08c3.29-0.7,6.18-2.56,7.81-5.48 c1.16-2.44,1.62-5.33,2.09-8.34c0.41-2.63,0.46-5.35-0.02-7.95c-0.9-4.87-3.21-7.75-6.71-9.6c-2.17-1.14-4.6-1.72-7.04-1.72 c-2.44-0.01-4.89,0.55-7.06,1.68c-3.52,1.82-5.84,4.66-6.77,9.48c-0.54,2.81-0.5,5.78-0.02,8.62 C19.17,38.68,24.14,42.99,29.83,44.01L29.83,44.01z M25.04,24.29c0.87,0,1.57,0.98,1.57,2.18s-0.7,2.18-1.57,2.18 c-0.87,0-1.57-0.98-1.57-2.18S24.17,24.29,25.04,24.29L25.04,24.29z M27.24,36.48c-0.33-0.47-0.14-0.72,0.2-0.95 c0.23-0.16,0.54-0.14,0.88-0.05c1.64,0.44,1.65,0.64,3.49,0.63c1.84-0.01,2.13-0.28,3.72-0.68c0.27-0.07,0.53-0.09,0.76-0.02 c0.53,0.17,0.71,0.57,0.38,1.06C34.37,39.84,29,38.95,27.24,36.48L27.24,36.48z M35.91,22.81c-0.15,0.3-0.08,0.58,0.14,0.71 c0.41,0.25,1.23-0.2,1.76-0.31c0.82-0.17,1.66-0.14,2.5,0.07c0.44,0.12,1.03,0.42,1.47,0.3c0.34-0.1,0.49-0.43,0.31-0.73 C41.04,21.06,36.72,21.12,35.91,22.81L35.91,22.81z M21.95,22.81c-0.15,0.3-0.08,0.58,0.14,0.71c0.41,0.25,1.23-0.2,1.76-0.31 c0.82-0.17,1.66-0.14,2.5,0.07c0.44,0.12,1.03,0.42,1.47,0.3c0.34-0.1,0.49-0.43,0.31-0.73C27.09,21.06,22.76,21.12,21.95,22.81 L21.95,22.81z M30.08,32.33c0.03-0.25,0.22-0.34,0.56-0.32h2.66c0.36-0.03,0.61,0.05,0.65,0.36c0.07,0.56-0.55,0.98-0.98,1.19 c-0.64,0.32-1.38,0.34-2.03-0.03C30.53,33.29,30.01,32.86,30.08,32.33L30.08,32.33z M39.02,24.29c0.87,0,1.57,0.98,1.57,2.18 s-0.7,2.18-1.57,2.18c-0.87,0-1.57-0.98-1.57-2.18S38.15,24.29,39.02,24.29L39.02,24.29z M49.78,33.6 c-0.46,0.38-0.97,0.7-1.52,0.97c-0.21,0.33-0.33,0.72-0.33,1.13c0,1.17,0.95,2.12,2.12,2.12c1.17,0,2.12-0.95,2.12-2.12 c0-1.17-0.95-2.12-2.12-2.12C49.95,33.59,49.86,33.59,49.78,33.6L49.78,33.6z M15.94,35.84c-1.14-0.38-2.15-1.01-2.94-1.81 c-0.06-0.06-0.12-0.13-0.18-0.19c-0.66,0.36-1.11,1.06-1.11,1.86c0,1.17,0.95,2.12,2.12,2.12C14.95,37.82,15.87,36.94,15.94,35.84 L15.94,35.84z M13.99,32.34c0.67,0.03,1.28,0.26,1.79,0.63c-0.16-0.67-0.3-1.34-0.42-2.03c-0.26-1.53-0.4-3.11-0.4-4.68 c-0.43,0.3-0.8,0.65-1.1,1.04c-0.54,0.7-0.86,1.55-0.86,2.44C13.01,30.71,13.38,31.6,13.99,32.34L13.99,32.34z M48.21,25.24 c0.06,1.73-0.06,3.48-0.33,5.17c-0.13,0.83-0.29,1.64-0.48,2.45c0.69-0.31,1.29-0.74,1.77-1.26c0.75-0.81,1.18-1.83,1.15-2.92 c-0.03-0.9-0.38-1.73-0.94-2.42C49.05,25.87,48.66,25.53,48.21,25.24L48.21,25.24z M33.41,8.53V7.38c0-1.2-1.02-2.17-2.27-2.17 h-0.77c-1.25,0-2.27,0.98-2.27,2.17v1.42c1.17-0.24,2.37-0.35,3.57-0.35C32.24,8.44,32.82,8.47,33.41,8.53L33.41,8.53z"/></g></svg>
<!-- Widget title text is placed here -->
</div>
<div class="input-group">
Expand Down
2 changes: 1 addition & 1 deletion src/resources/chat-widget/src/widgetHtmlString.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const widgetHTML = `<div id="chat-widget__header"><div id="chat-widget__title"><svg id="chat-widget__title_icon" width="24" height="19" viewBox="0 0 24 19"><path d="M9 6C9.55229 6 10 6.44772 10 7V9C10 9.55228 9.55229 10 9 10C8.44771 10 8 9.55228 8 9V7C8 6.44772 8.44771 6 9 6Z"/><path d="M16 7C16 6.44772 15.5523 6 15 6C14.4477 6 14 6.44772 14 7V9C14 9.55228 14.4477 10 15 10C15.5523 10 16 9.55228 16 9V7Z"/><path d="M19.2099 16C19.0086 16 18.815 16.0768 18.6684 16.2147L16.4858 18.269C15.2525 19.4298 13.2248 18.6278 13.1191 16.9374C13.0862 16.4105 12.6493 16 12.1213 16H5C3.34315 16 2 14.6569 2 13V9C2 9.55228 1.55228 10 1 10C0.447715 10 0 9.55228 0 9V6C0 5.44772 0.447715 5 1 5C1.55228 5 2 5.44772 2 6V3C2 1.34315 3.34315 0 5 0H19C20.6569 0 22 1.34315 22 3V6C22 5.44772 22.4477 5 23 5C23.5523 5 24 5.44772 24 6V9C24 9.55228 23.5523 10 23 10C22.4477 10 22 9.55228 22 9V13.2099C22 14.7508 20.7508 16 19.2099 16ZM5 2C4.44772 2 4 2.44772 4 3V13C4 13.5523 4.44772 14 5 14H12.1213C13.7053 14 15.0163 15.2315 15.1152 16.8124L17.2977 14.7583C17.8152 14.2712 18.4992 14 19.2099 14C19.6463 14 20 13.6463 20 13.2099V3C20 2.44772 19.5523 2 19 2H5Z"/></svg></div><div class="input-group"><span style="font-weight: var(--chat-widget-title-weight);">PeerChat</span><label class="switch"><input type="checkbox" id="peerchat-switch"><span class="slider"></span></label></div></div><div id="chat-widget__body"><form id="chat-widget__form"><textarea autocomplete="off" id="chat-widget__input" name="message" type="text" placeholder="Ask me a question…" required aria-label="Message"></textarea><button id="chat-widget__submit" type="submit"><i class="fa fa-paper-plane" style="font-size: large;"></i></button></form></div>`;
export const widgetHTML = `<div id="chat-widget__header"><div id="chat-widget__title"> <?xml version="1.0" encoding="utf-8"?><svg version="1.1" id="chat-widget__title_icon" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="50" height="50" viewBox="-30 0 128 125" xml:space="preserve"><style type="text/css">.st0{fill-rule:evenodd;clip-rule:evenodd;}</style><g><path class="st0" d="M55.41,80.68c-3.63,1.09-7.09,1.07-10.44,0.22c-3.58-0.91-7-2.78-10.3-5.27c-3.44,2.58-7.04,4.35-10.84,5.12 c-3.66,0.74-7.47,0.54-11.45-0.75c-1.64,9.06,0.1,16.51,4.31,22.79c3.97,5.93,10.16,10.87,17.82,15.17 c-0.29-1.2-0.48-2.36-0.57-3.48c-0.19-2.34,0.06-4.48,0.74-6.44c1.63-4.74,5.4-7.32,9.4-10.06C49.28,94.4,54.92,90.52,55.41,80.68 L55.41,80.68z M24.03,10.16c-1.5-5.84,2.44-10.46,8.4-10.14c4.06,0.22,6.89,2.39,9.19,4.79c3.86,4.02,6.2,8.66,10.32,5.64 c-0.05,3.7-1.83,6.21-5.55,6.92c0.65,1.34,1.15,2.83,1.45,4.48c0.07,0.38,0.13,0.76,0.18,1.15c1.08,0.46,2.01,1.16,2.71,2.01 c0.84,1.02,1.35,2.27,1.39,3.63c0.05,1.41-0.41,2.73-1.24,3.82c1.45,0.38,2.52,1.69,2.52,3.26c0,1.86-1.51,3.37-3.37,3.37 c-1.74,0-3.18-1.33-3.35-3.03c-0.94,2.87-2.07,5.62-4.09,7.82c-0.3,0.32-0.61,0.61-0.94,0.88c1.78,0.1,3.53,0.24,5.23,0.42 c9.12,1.01,15.17,4.63,18.52,9.2c1.9,2.6,2.93,5.5,3.15,8.41c0.22,2.91-0.36,5.83-1.68,8.48c-1.64,3.29-4.42,6.14-8.21,8.01 c0.03,12.59-6.65,17.18-12.78,21.39c-3.54,2.43-6.87,4.71-8.15,8.44c-0.53,1.54-0.72,3.25-0.57,5.13c0.16,1.94,0.68,4.06,1.58,6.38 c0.19,0.43,0.19,0.94-0.04,1.39c-0.41,0.8-1.38,1.12-2.18,0.71C26.8,117.75,18.9,111.9,14,104.59c-4.81-7.18-6.72-15.7-4.63-26.05 c-1.5-0.82-2.87-1.81-4.07-2.94c-2.02-1.9-3.55-4.2-4.44-6.72c-1.78-5.07-0.93-10.98,3.98-16.35c1.68-1.84,3.71-3.26,5.99-4.35 c2.23-1.07,4.69-1.83,7.28-2.37c1.31-0.27,2.65-0.49,4.01-0.65c-0.74-0.61-1.4-1.31-1.97-2.08c-0.64-0.88-1.17-1.87-1.57-2.98 c-0.03-0.06-0.07-0.11-0.1-0.17c-0.54-0.96-1.04-2-1.47-3.1c-0.46,1.31-1.71,2.26-3.18,2.26c-1.86,0-3.37-1.51-3.37-3.37 c0-1.21,0.64-2.28,1.61-2.87c-0.56-0.92-0.87-1.97-0.87-3.08c0-1.36,0.47-2.62,1.28-3.67c0.66-0.86,1.56-1.57,2.6-2.07 c0.07-0.79,0.18-1.58,0.33-2.36c1.05-5.46,4.26-9.23,8.28-11.31C23.79,10.28,23.91,10.22,24.03,10.16L24.03,10.16z M36.62,47.81 c-1.47,0.98-2.5,2.21-2.39,4.52c-2.68-0.43-3.59-1.52-5.04-3.52c-0.69-0.18-1.47-0.48-2.27-0.84c-0.23,0.01-0.47,0.03-0.7,0.04 c-2.57,0.17-5.09,0.46-7.47,0.96c-2.35,0.49-4.56,1.17-6.53,2.11c-1.92,0.92-3.62,2.11-5,3.62c-3.99,4.37-4.71,9.09-3.3,13.11 c0.71,2.02,1.96,3.87,3.6,5.42c1.66,1.57,3.73,2.82,6.06,3.62c5.78,1.98,13.14,1.13,19.91-4.68c0.55-0.69,1.12-1.34,1.71-1.95 c-1.76-1.57-3.55-2.63-5.36-3.24c-2.18-0.74-4.43-0.84-6.73-0.44c-0.88,0.15-1.72-0.44-1.88-1.32c-0.15-0.88,0.44-1.72,1.32-1.88 c2.82-0.49,5.59-0.35,8.31,0.56c2.31,0.78,4.55,2.12,6.72,4.1c0.47-0.39,0.95-0.76,1.45-1.11c2.04-1.46,4.25-2.61,6.59-3.52 c0.83-0.32,1.77,0.09,2.09,0.93c0.32,0.83-0.09,1.77-0.92,2.09c-2.09,0.81-4.07,1.84-5.88,3.14c-1.39,0.99-2.69,2.15-3.89,3.48 c2.45,1.83,4.94,3.26,7.49,4.13c2.92,1,5.94,1.26,9.1,0.52l0,0c5.02-1.24,8.57-4.24,10.39-7.87c1.06-2.12,1.53-4.46,1.35-6.79 c-0.18-2.33-1-4.65-2.53-6.74c-2.85-3.9-8.15-6.99-16.26-7.89c-2.03-0.22-4.08-0.38-6.14-0.47C39.14,47.86,37.88,47.83,36.62,47.81 L36.62,47.81z M29.83,44.01c1.16-0.84,1.44-3.08,2.81-3.03c1.42,0.05,1.61,2.54,2.89,2.88l0.01,0.08c3.29-0.7,6.18-2.56,7.81-5.48 c1.16-2.44,1.62-5.33,2.09-8.34c0.41-2.63,0.46-5.35-0.02-7.95c-0.9-4.87-3.21-7.75-6.71-9.6c-2.17-1.14-4.6-1.72-7.04-1.72 c-2.44-0.01-4.89,0.55-7.06,1.68c-3.52,1.82-5.84,4.66-6.77,9.48c-0.54,2.81-0.5,5.78-0.02,8.62 C19.17,38.68,24.14,42.99,29.83,44.01L29.83,44.01z M25.04,24.29c0.87,0,1.57,0.98,1.57,2.18s-0.7,2.18-1.57,2.18 c-0.87,0-1.57-0.98-1.57-2.18S24.17,24.29,25.04,24.29L25.04,24.29z M27.24,36.48c-0.33-0.47-0.14-0.72,0.2-0.95 c0.23-0.16,0.54-0.14,0.88-0.05c1.64,0.44,1.65,0.64,3.49,0.63c1.84-0.01,2.13-0.28,3.72-0.68c0.27-0.07,0.53-0.09,0.76-0.02 c0.53,0.17,0.71,0.57,0.38,1.06C34.37,39.84,29,38.95,27.24,36.48L27.24,36.48z M35.91,22.81c-0.15,0.3-0.08,0.58,0.14,0.71 c0.41,0.25,1.23-0.2,1.76-0.31c0.82-0.17,1.66-0.14,2.5,0.07c0.44,0.12,1.03,0.42,1.47,0.3c0.34-0.1,0.49-0.43,0.31-0.73 C41.04,21.06,36.72,21.12,35.91,22.81L35.91,22.81z M21.95,22.81c-0.15,0.3-0.08,0.58,0.14,0.71c0.41,0.25,1.23-0.2,1.76-0.31 c0.82-0.17,1.66-0.14,2.5,0.07c0.44,0.12,1.03,0.42,1.47,0.3c0.34-0.1,0.49-0.43,0.31-0.73C27.09,21.06,22.76,21.12,21.95,22.81 L21.95,22.81z M30.08,32.33c0.03-0.25,0.22-0.34,0.56-0.32h2.66c0.36-0.03,0.61,0.05,0.65,0.36c0.07,0.56-0.55,0.98-0.98,1.19 c-0.64,0.32-1.38,0.34-2.03-0.03C30.53,33.29,30.01,32.86,30.08,32.33L30.08,32.33z M39.02,24.29c0.87,0,1.57,0.98,1.57,2.18 s-0.7,2.18-1.57,2.18c-0.87,0-1.57-0.98-1.57-2.18S38.15,24.29,39.02,24.29L39.02,24.29z M49.78,33.6 c-0.46,0.38-0.97,0.7-1.52,0.97c-0.21,0.33-0.33,0.72-0.33,1.13c0,1.17,0.95,2.12,2.12,2.12c1.17,0,2.12-0.95,2.12-2.12 c0-1.17-0.95-2.12-2.12-2.12C49.95,33.59,49.86,33.59,49.78,33.6L49.78,33.6z M15.94,35.84c-1.14-0.38-2.15-1.01-2.94-1.81 c-0.06-0.06-0.12-0.13-0.18-0.19c-0.66,0.36-1.11,1.06-1.11,1.86c0,1.17,0.95,2.12,2.12,2.12C14.95,37.82,15.87,36.94,15.94,35.84 L15.94,35.84z M13.99,32.34c0.67,0.03,1.28,0.26,1.79,0.63c-0.16-0.67-0.3-1.34-0.42-2.03c-0.26-1.53-0.4-3.11-0.4-4.68 c-0.43,0.3-0.8,0.65-1.1,1.04c-0.54,0.7-0.86,1.55-0.86,2.44C13.01,30.71,13.38,31.6,13.99,32.34L13.99,32.34z M48.21,25.24 c0.06,1.73-0.06,3.48-0.33,5.17c-0.13,0.83-0.29,1.64-0.48,2.45c0.69-0.31,1.29-0.74,1.77-1.26c0.75-0.81,1.18-1.83,1.15-2.92 c-0.03-0.9-0.38-1.73-0.94-2.42C49.05,25.87,48.66,25.53,48.21,25.24L48.21,25.24z M33.41,8.53V7.38c0-1.2-1.02-2.17-2.27-2.17 h-0.77c-1.25,0-2.27,0.98-2.27,2.17v1.42c1.17-0.24,2.37-0.35,3.57-0.35C32.24,8.44,32.82,8.47,33.41,8.53L33.41,8.53z"/></g></svg></div><div class="input-group"><span style="font-weight: var(--chat-widget-title-weight);">PeerChat</span><label class="switch"><input type="checkbox" id="peerchat-switch"><span class="slider"></span></label></div></div><div id="chat-widget__body"><form id="chat-widget__form"><textarea autocomplete="off" id="chat-widget__input" name="message" type="text" placeholder="Ask me a question…" required aria-label="Message"></textarea><button id="chat-widget__submit" type="submit"><i class="fa fa-paper-plane" style="font-size: large;"></i></button></form></div>`;
14 changes: 12 additions & 2 deletions src/resources/css/scribbler-landing.css
Original file line number Diff line number Diff line change
Expand Up @@ -1170,8 +1170,7 @@ overflow: hidden;
bottom: 20px;
right: 20px;
border: none;
width: 50px; /* Button width */
height: 50px; /* Button height */
width: 60px; /* Button width */
display: flex;
align-items: center;
justify-content: center;
Expand All @@ -1184,4 +1183,15 @@ overflow: hidden;
width: 40px; /* SVG width */
height: 40px; /* SVG height */
}
.floating-button:hover img {
animation: shake 0.5s infinite;
}

@keyframes shake {
0% { transform: rotate(0deg); }
25% { transform: rotate(-45deg); }
50% { transform: rotate(0deg); }
75% { transform: rotate(45deg); }
100% { transform: rotate(0deg); }
}
/* chatgpt button ends */
4 changes: 4 additions & 0 deletions src/resources/images/genie.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions src/resources/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -677,9 +677,9 @@ <h3 class="section__title">Share/Collaborate</h3>
});
processtheme();
/* chatwidget */
window.ChatWidget.config.widgetTitle = "Ask GPT";
window.ChatWidget.config.widgetTitle = "Ask Genie";
window.ChatWidget.config.greetingMessage =
"Hello there! Welcome to openrepl.com.\nAn opensource platform to write and run your code snippets in REPL.";
"Hello there! Welcome to openrepl.com.\nAn opensource platform to write and run your code snippets in REPL.\nI am Genie, your OpenRepl AI assistant.";
window.ChatWidget.config.url = "/chat/completions";
window.ChatWidget.config.api_key = openai_access_token;
window.ChatWidget.config.firebaseconfig = firebaseconfig;
Expand Down Expand Up @@ -707,7 +707,7 @@ <h3 class="section__title">Share/Collaborate</h3>
});
</script>
<button data-chat-widget-button class="share-btn floating-button opaq" style="position: fixed; right: 20px; bottom: 20px; border-radius: 10%;z-index: 9999;">
<img src="./images/chatgpt.svg" alt="Ask GPT" />
<img src="./images/genie.svg" alt="Ask Genie" />
</button>
<!-- chatgpt Section end -->
</body>
Expand Down

0 comments on commit bc66725

Please sign in to comment.