Skip to content

Commit

Permalink
feat: styles for ai chatbot components (#320)
Browse files Browse the repository at this point in the history
  • Loading branch information
isekovanic authored Dec 4, 2024
1 parent 7f592fb commit 711c4bb
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 4 deletions.
3 changes: 3 additions & 0 deletions src/v2/styles/AIStateIndicator/AIStateIndicator-layout.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.str-chat__ai-state-indicator-container {
padding: 0 8px;
}
7 changes: 7 additions & 0 deletions src/v2/styles/AIStateIndicator/AIStateIndicator-theme.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.str-chat__ai-state-indicator-container {
background-color: var(--str-chat__grey300);
}

.str-chat__ai-state-indicator-text {
color: var(--str-chat__text-color);
}
8 changes: 7 additions & 1 deletion src/v2/styles/MessageInput/MessageInput-layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,12 @@
width: 100%;
}

.str-chat__stop-ai-generation-button {
width: calc(var(--str-chat__spacing-px) * 30);
height: calc(var(--str-chat__spacing-px) * 28);
cursor: pointer;
}

.str-chat__send-button {
--str-chat-icon-height: calc(var(--str-chat__spacing-px) * 32);
@include utils.flex-row-center;
Expand Down Expand Up @@ -240,4 +246,4 @@
.str-chat__attachment-selector-actions-menu {
min-width: 300px;
padding-block: 0.5rem;
}
}
12 changes: 9 additions & 3 deletions src/v2/styles/MessageInput/MessageInput-theme.scss
Original file line number Diff line number Diff line change
Expand Up @@ -168,10 +168,10 @@

/* Box shadow applied to the cooldown timer */
--str-chat__cooldown-box-shadow: none;

/* Color applied to an icon in a button that opens attachment selector */
--str-chat__attachment-selector-button-icon-color: var(--str-chat__text-low-emphasis-color);

/* Color applied to an icon in a button that opens attachment selector when hovered over */
--str-chat__attachment-selector-button-icon-color-hover: var(--str-chat__primary-color);

Expand Down Expand Up @@ -221,6 +221,12 @@
}
}

.str-chat__stop-ai-generation-button {
background-image: var(--str-chat__circle-stop-icon);
background-color: transparent;
border-width: 0;
}

.str-chat__send-button {
--str-chat-icon-color: var(--str-chat__message-send-color);
@include utils.component-layer-overrides('message-send');
Expand Down Expand Up @@ -342,4 +348,4 @@
mask: var(--str-chat__poll-icon) no-repeat center / contain;
}
}
}
}
1 change: 1 addition & 0 deletions src/v2/styles/_icons.scss
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
--str-chat__folder-icon: url('data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIGZpbGw9ImN1cnJlbnRDb2xvciIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KICAgIDxwYXRoIGQ9Ik0xOCAySDEwTDggMEgyQzAuOSAwIDAuMDA5OTk5OTkgMC45IDAuMDA5OTk5OTkgMkwwIDE0QzAgMTUuMSAwLjkgMTYgMiAxNkgxOEMxOS4xIDE2IDIwIDE1LjEgMjAgMTRWNEMyMCAyLjkgMTkuMSAyIDE4IDJaTTE4IDE0SDJWNEgxOFYxNFoiIC8+Cjwvc3ZnPgo=');
--str-chat__poll-icon: url('data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMTggMTgiIGZpbGw9ImN1cnJlbnRDb2xvciIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KICAgIDxwYXRoIGQ9Ik0xNiAwSDJDMC45IDAgMCAwLjkgMCAyVjE2QzAgMTcuMSAwLjkgMTggMiAxOEgxNkMxNy4xIDE4IDE4IDE3LjEgMTggMTZWMkMxOCAwLjkgMTcuMSAwIDE2IDBaTTE2IDE2SDJWMkgxNlYxNlpNNCA3SDZWMTRINFY3Wk04IDRIMTBWMTRIOFY0Wk0xMiAxMEgxNFYxNEgxMlYxMFoiLz4KPC9zdmc+');
--str-chat__handle-icon: url('data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMTYgNiIgZmlsbD0iY3VycmVuQ29sb3IiIHhtbG5zPSJodHRwOi8vd3d3LnczL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1NCAxMy4wMTExVjE4Ljg5OTFDMTIuNDE1NCAxOS41NzQyIDEyLjgzNTkgMTkuOTgzNyAxMy41MjIxIDE5Ljk4MzdaIiBmaWxsPSIjMDA1ZmZmIi8+Cjwvc3ZnPg==');
}

@font-face {
Expand Down
1 change: 1 addition & 0 deletions src/v2/styles/index.layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,4 @@
@use 'ThreadList/ThreadList-layout';
@use 'ChatView/ChatView-layout';
@use 'UnreadCountBadge/UnreadCountBadge-layout';
@use 'AIStateIndicator/AIStateIndicator-layout';
1 change: 1 addition & 0 deletions src/v2/styles/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,4 @@
@use 'ThreadList/ThreadList-theme';
@use 'ChatView/ChatView-theme';
@use 'UnreadCountBadge/UnreadCountBadge-theme';
@use 'AIStateIndicator/AIStateIndicator-theme';

0 comments on commit 711c4bb

Please sign in to comment.