@asgard-js/react 0.0.43-canary.13 → 0.0.43-canary.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/chatbot/api-key-input/api-key-input.d.ts.map +1 -1
- package/dist/context/asgard-theme-context.d.ts +2 -0
- package/dist/context/asgard-theme-context.d.ts.map +1 -1
- package/dist/index.js +7605 -7607
- package/package.json +1 -1
- package/src/components/chatbot/api-key-input/api-key-input.tsx +2 -4
- package/src/context/asgard-theme-context.tsx +6 -4
package/package.json
CHANGED
|
@@ -28,8 +28,6 @@ export function ApiKeyInput({
|
|
|
28
28
|
const [showPassword, setShowPassword] = useState(false);
|
|
29
29
|
const { chatbot } = useAsgardThemeContext();
|
|
30
30
|
const { avatar } = useAsgardContext();
|
|
31
|
-
console.log('chatbot', chatbot);
|
|
32
|
-
console.log('chatbot.primaryComponent', chatbot.primaryComponent);
|
|
33
31
|
|
|
34
32
|
const handleSubmit = (e: FormEvent): void => {
|
|
35
33
|
e.preventDefault();
|
|
@@ -119,8 +117,8 @@ export function ApiKeyInput({
|
|
|
119
117
|
[styles.loading]: loading,
|
|
120
118
|
})}
|
|
121
119
|
style={{
|
|
122
|
-
backgroundColor: chatbot?.
|
|
123
|
-
color: chatbot?.
|
|
120
|
+
backgroundColor: chatbot?.mainColor,
|
|
121
|
+
color: chatbot?.secondaryColor,
|
|
124
122
|
}}
|
|
125
123
|
>
|
|
126
124
|
{loading ? 'Loading...' : 'Continue'}
|
|
@@ -31,6 +31,8 @@ export interface AsgardThemeContextValue {
|
|
|
31
31
|
backgroundColor?: CSSProperties['backgroundColor'];
|
|
32
32
|
borderColor?: CSSProperties['borderColor'];
|
|
33
33
|
inactiveColor?: CSSProperties['color'];
|
|
34
|
+
mainColor?: CSSProperties['color'];
|
|
35
|
+
secondaryColor?: CSSProperties['color'];
|
|
34
36
|
primaryComponent?: {
|
|
35
37
|
mainColor?: CSSProperties['color'];
|
|
36
38
|
secondaryColor?: CSSProperties['color'];
|
|
@@ -267,8 +269,8 @@ export function AsgardThemeContextProvider(
|
|
|
267
269
|
chatbot: {
|
|
268
270
|
backgroundColor: themeFromAnnotations.chatbot?.backgroundColor,
|
|
269
271
|
borderColor: themeFromAnnotations.chatbot?.borderColor,
|
|
270
|
-
|
|
271
|
-
|
|
272
|
+
mainColor: themeFromAnnotations.chatbot?.primaryComponent?.mainColor,
|
|
273
|
+
secondaryColor: themeFromAnnotations.chatbot?.primaryComponent?.secondaryColor,
|
|
272
274
|
|
|
273
275
|
header: {
|
|
274
276
|
style: {
|
|
@@ -410,8 +412,8 @@ export function AsgardThemeContextProvider(
|
|
|
410
412
|
chatbot: {
|
|
411
413
|
backgroundColor: propsTheme.chatbot?.backgroundColor,
|
|
412
414
|
borderColor: propsTheme.chatbot?.borderColor,
|
|
413
|
-
|
|
414
|
-
|
|
415
|
+
mainColor: propsTheme.chatbot?.primaryComponent?.mainColor,
|
|
416
|
+
secondaryColor: propsTheme.chatbot?.primaryComponent?.secondaryColor,
|
|
415
417
|
header: {
|
|
416
418
|
style: {
|
|
417
419
|
borderBottomColor: propsTheme.chatbot?.borderColor,
|