aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/chatbot/chatboxcomponents/ProgressBar.tsx
diff options
context:
space:
mode:
authorA.J. Shulman <Shulman.aj@gmail.com>2024-09-07 12:43:05 -0400
committerA.J. Shulman <Shulman.aj@gmail.com>2024-09-07 12:43:05 -0400
commit4791cd23af08da70895204a3a7fbaf889d9af2d5 (patch)
treec4c2534e64724d62bae9152763f1a74cd5a963e0 /src/client/views/nodes/chatbot/chatboxcomponents/ProgressBar.tsx
parent210f8f5f1cd19e9416a12524cce119b273334fd3 (diff)
completely restructured, added comments, and significantly reduced the length of the prompt (~72% shorter and cheaper)
Diffstat (limited to 'src/client/views/nodes/chatbot/chatboxcomponents/ProgressBar.tsx')
-rw-r--r--src/client/views/nodes/chatbot/chatboxcomponents/ProgressBar.tsx22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/client/views/nodes/chatbot/chatboxcomponents/ProgressBar.tsx b/src/client/views/nodes/chatbot/chatboxcomponents/ProgressBar.tsx
new file mode 100644
index 000000000..b9fd08742
--- /dev/null
+++ b/src/client/views/nodes/chatbot/chatboxcomponents/ProgressBar.tsx
@@ -0,0 +1,22 @@
+import React from 'react';
+import './ProgressBar.scss';
+
+/**
+ * ProgressBar is a functional React component that displays a loading spinner
+ * to indicate progress or ongoing processing. It uses two bouncing elements
+ * to create a smooth animation that represents an active state.
+ *
+ * The animation consists of two divs (`double-bounce1` and `double-bounce2`),
+ * each of which will bounce in and out of view, creating a pulsating effect.
+ */
+export const ProgressBar: React.FC = () => {
+ return (
+ <div className="spinner-container">
+ {/* Spinner div containing two bouncing elements */}
+ <div className="spinner">
+ <div className="double-bounce1"></div> {/* First bouncing element */}
+ <div className="double-bounce2"></div> {/* Second bouncing element */}
+ </div>
+ </div>
+ );
+};