@clikvn/agent-widget-embedded 1.1.5-dev-25 → 1.1.5
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/CLAUDE.md +169 -169
- package/README.md +20 -20
- package/base.json +21 -21
- package/dist/components/Chat/BookMeetingForm.d.ts.map +1 -1
- package/dist/index.html +71 -65
- package/dist/web.d.ts.map +1 -1
- package/dist/web.js +1 -1
- package/docs/agent-response-trace/agentflow.txt +62 -62
- package/docs/agent-response-trace/chatflow.txt +26 -26
- package/docs/brand-ui-command-actions-tools.md +269 -269
- package/package.json +101 -101
- package/public/index.html +54 -54
- package/rollup.config.js +67 -67
- package/tailwind.config.cjs +145 -145
- package/.claude/settings.local.json +0 -12
- package/.idea/clik-ai-chatbot-embedded.iml +0 -12
- package/.idea/codeStyles/Project.xml +0 -59
- package/.idea/codeStyles/codeStyleConfig.xml +0 -5
- package/.idea/inspectionProfiles/Project_Default.xml +0 -6
- package/.idea/jsLinters/eslint.xml +0 -6
- package/.idea/modules.xml +0 -8
- package/.idea/prettier.xml +0 -6
- package/.idea/vcs.xml +0 -6
package/tailwind.config.cjs
CHANGED
|
@@ -1,145 +1,145 @@
|
|
|
1
|
-
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
2
|
-
const defaultTheme = require('tailwindcss/defaultTheme');
|
|
3
|
-
const plugin = require('tailwindcss/plugin');
|
|
4
|
-
|
|
5
|
-
function rem2px(input, fontSize = 16) {
|
|
6
|
-
if (input == null) {
|
|
7
|
-
return input;
|
|
8
|
-
}
|
|
9
|
-
switch (typeof input) {
|
|
10
|
-
case 'object':
|
|
11
|
-
if (Array.isArray(input)) {
|
|
12
|
-
return input.map((val) => rem2px(val, fontSize));
|
|
13
|
-
}
|
|
14
|
-
// eslint-disable-next-line no-case-declarations
|
|
15
|
-
const ret = {};
|
|
16
|
-
for (const key in input) {
|
|
17
|
-
ret[key] = rem2px(input[key], fontSize);
|
|
18
|
-
}
|
|
19
|
-
return ret;
|
|
20
|
-
case 'string':
|
|
21
|
-
return input.replace(
|
|
22
|
-
/(\d*\.?\d+)rem$/,
|
|
23
|
-
(_, val) => `${parseFloat(val) * fontSize}px`
|
|
24
|
-
);
|
|
25
|
-
case 'function':
|
|
26
|
-
return eval(
|
|
27
|
-
input
|
|
28
|
-
.toString()
|
|
29
|
-
.replace(
|
|
30
|
-
/(\d*\.?\d+)rem/g,
|
|
31
|
-
(_, val) => `${parseFloat(val) * fontSize}px`
|
|
32
|
-
)
|
|
33
|
-
);
|
|
34
|
-
default:
|
|
35
|
-
return input;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
/** @type {import('tailwindcss').Config} */
|
|
40
|
-
module.exports = {
|
|
41
|
-
darkMode: ['class'],
|
|
42
|
-
content: ['./src/**/*.{js,jsx,ts,tsx}'],
|
|
43
|
-
theme: {
|
|
44
|
-
...rem2px(defaultTheme),
|
|
45
|
-
fontFamily: {
|
|
46
|
-
sans: ['Be Vietnam Pro', 'sans-serif'],
|
|
47
|
-
mono: ['Be Vietnam Pro', 'sans-serif'],
|
|
48
|
-
},
|
|
49
|
-
extend: {
|
|
50
|
-
keyframes: {
|
|
51
|
-
'fade-in': {
|
|
52
|
-
'0%': {
|
|
53
|
-
opacity: '0',
|
|
54
|
-
},
|
|
55
|
-
'100%': {
|
|
56
|
-
opacity: '1',
|
|
57
|
-
},
|
|
58
|
-
},
|
|
59
|
-
},
|
|
60
|
-
animation: {
|
|
61
|
-
'fade-in': 'fade-in 0.3s ease-out',
|
|
62
|
-
},
|
|
63
|
-
borderRadius: {
|
|
64
|
-
lg: 'var(--radius)',
|
|
65
|
-
md: 'calc(var(--radius) - 2px)',
|
|
66
|
-
sm: 'calc(var(--radius) - 4px)',
|
|
67
|
-
},
|
|
68
|
-
colors: {
|
|
69
|
-
background: 'hsl(var(--background))',
|
|
70
|
-
foreground: 'hsl(var(--foreground))',
|
|
71
|
-
card: {
|
|
72
|
-
DEFAULT: 'hsl(var(--card))',
|
|
73
|
-
foreground: 'hsl(var(--card-foreground))',
|
|
74
|
-
},
|
|
75
|
-
popover: {
|
|
76
|
-
DEFAULT: 'hsl(var(--popover))',
|
|
77
|
-
foreground: 'hsl(var(--popover-foreground))',
|
|
78
|
-
},
|
|
79
|
-
primary: {
|
|
80
|
-
DEFAULT: 'hsl(var(--primary))',
|
|
81
|
-
foreground: 'hsl(var(--primary-foreground))',
|
|
82
|
-
},
|
|
83
|
-
secondary: {
|
|
84
|
-
DEFAULT: 'hsl(var(--secondary))',
|
|
85
|
-
foreground: 'hsl(var(--secondary-foreground))',
|
|
86
|
-
},
|
|
87
|
-
muted: {
|
|
88
|
-
DEFAULT: 'hsl(var(--muted))',
|
|
89
|
-
foreground: 'hsl(var(--muted-foreground))',
|
|
90
|
-
},
|
|
91
|
-
accent: {
|
|
92
|
-
DEFAULT: 'hsl(var(--accent))',
|
|
93
|
-
foreground: 'hsl(var(--accent-foreground))',
|
|
94
|
-
},
|
|
95
|
-
destructive: {
|
|
96
|
-
DEFAULT: 'hsl(var(--destructive))',
|
|
97
|
-
foreground: 'hsl(var(--destructive-foreground))',
|
|
98
|
-
},
|
|
99
|
-
border: 'hsl(var(--border))',
|
|
100
|
-
input: 'hsl(var(--input))',
|
|
101
|
-
ring: 'hsl(var(--ring))',
|
|
102
|
-
chart: {
|
|
103
|
-
1: 'hsl(var(--chart-1))',
|
|
104
|
-
2: 'hsl(var(--chart-2))',
|
|
105
|
-
3: 'hsl(var(--chart-3))',
|
|
106
|
-
4: 'hsl(var(--chart-4))',
|
|
107
|
-
5: 'hsl(var(--chart-5))',
|
|
108
|
-
},
|
|
109
|
-
sidebar: {
|
|
110
|
-
DEFAULT: 'hsl(var(--sidebar-background))',
|
|
111
|
-
foreground: 'hsl(var(--sidebar-foreground))',
|
|
112
|
-
primary: 'hsl(var(--sidebar-primary))',
|
|
113
|
-
'primary-foreground': 'hsl(var(--sidebar-primary-foreground))',
|
|
114
|
-
accent: 'hsl(var(--sidebar-accent))',
|
|
115
|
-
'accent-foreground': 'hsl(var(--sidebar-accent-foreground))',
|
|
116
|
-
border: 'hsl(var(--sidebar-border))',
|
|
117
|
-
ring: 'hsl(var(--sidebar-ring))',
|
|
118
|
-
},
|
|
119
|
-
},
|
|
120
|
-
},
|
|
121
|
-
},
|
|
122
|
-
plugins: [
|
|
123
|
-
require('tailwindcss-animate'),
|
|
124
|
-
require('@tailwindcss/typography'),
|
|
125
|
-
plugin(function ({ addVariant }) {
|
|
126
|
-
addVariant('wrapped', ({ container }) => {
|
|
127
|
-
container.walkRules((rule) => {
|
|
128
|
-
rule.selector = `.clik-chatbot-wrapper ${rule.selector}`;
|
|
129
|
-
});
|
|
130
|
-
});
|
|
131
|
-
}),
|
|
132
|
-
function ({ addUtilities }) {
|
|
133
|
-
const newUtilities = {
|
|
134
|
-
'.no-scrollbar': {
|
|
135
|
-
'-ms-overflow-style': 'none' /* IE and Edge */,
|
|
136
|
-
'scrollbar-width': 'none' /* Firefox */,
|
|
137
|
-
},
|
|
138
|
-
'.no-scrollbar::-webkit-scrollbar': {
|
|
139
|
-
display: 'none' /* Chrome, Safari, Opera */,
|
|
140
|
-
},
|
|
141
|
-
};
|
|
142
|
-
addUtilities(newUtilities, ['responsive']);
|
|
143
|
-
},
|
|
144
|
-
],
|
|
145
|
-
};
|
|
1
|
+
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
2
|
+
const defaultTheme = require('tailwindcss/defaultTheme');
|
|
3
|
+
const plugin = require('tailwindcss/plugin');
|
|
4
|
+
|
|
5
|
+
function rem2px(input, fontSize = 16) {
|
|
6
|
+
if (input == null) {
|
|
7
|
+
return input;
|
|
8
|
+
}
|
|
9
|
+
switch (typeof input) {
|
|
10
|
+
case 'object':
|
|
11
|
+
if (Array.isArray(input)) {
|
|
12
|
+
return input.map((val) => rem2px(val, fontSize));
|
|
13
|
+
}
|
|
14
|
+
// eslint-disable-next-line no-case-declarations
|
|
15
|
+
const ret = {};
|
|
16
|
+
for (const key in input) {
|
|
17
|
+
ret[key] = rem2px(input[key], fontSize);
|
|
18
|
+
}
|
|
19
|
+
return ret;
|
|
20
|
+
case 'string':
|
|
21
|
+
return input.replace(
|
|
22
|
+
/(\d*\.?\d+)rem$/,
|
|
23
|
+
(_, val) => `${parseFloat(val) * fontSize}px`
|
|
24
|
+
);
|
|
25
|
+
case 'function':
|
|
26
|
+
return eval(
|
|
27
|
+
input
|
|
28
|
+
.toString()
|
|
29
|
+
.replace(
|
|
30
|
+
/(\d*\.?\d+)rem/g,
|
|
31
|
+
(_, val) => `${parseFloat(val) * fontSize}px`
|
|
32
|
+
)
|
|
33
|
+
);
|
|
34
|
+
default:
|
|
35
|
+
return input;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/** @type {import('tailwindcss').Config} */
|
|
40
|
+
module.exports = {
|
|
41
|
+
darkMode: ['class'],
|
|
42
|
+
content: ['./src/**/*.{js,jsx,ts,tsx}'],
|
|
43
|
+
theme: {
|
|
44
|
+
...rem2px(defaultTheme),
|
|
45
|
+
fontFamily: {
|
|
46
|
+
sans: ['Be Vietnam Pro', 'sans-serif'],
|
|
47
|
+
mono: ['Be Vietnam Pro', 'sans-serif'],
|
|
48
|
+
},
|
|
49
|
+
extend: {
|
|
50
|
+
keyframes: {
|
|
51
|
+
'fade-in': {
|
|
52
|
+
'0%': {
|
|
53
|
+
opacity: '0',
|
|
54
|
+
},
|
|
55
|
+
'100%': {
|
|
56
|
+
opacity: '1',
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
animation: {
|
|
61
|
+
'fade-in': 'fade-in 0.3s ease-out',
|
|
62
|
+
},
|
|
63
|
+
borderRadius: {
|
|
64
|
+
lg: 'var(--radius)',
|
|
65
|
+
md: 'calc(var(--radius) - 2px)',
|
|
66
|
+
sm: 'calc(var(--radius) - 4px)',
|
|
67
|
+
},
|
|
68
|
+
colors: {
|
|
69
|
+
background: 'hsl(var(--background))',
|
|
70
|
+
foreground: 'hsl(var(--foreground))',
|
|
71
|
+
card: {
|
|
72
|
+
DEFAULT: 'hsl(var(--card))',
|
|
73
|
+
foreground: 'hsl(var(--card-foreground))',
|
|
74
|
+
},
|
|
75
|
+
popover: {
|
|
76
|
+
DEFAULT: 'hsl(var(--popover))',
|
|
77
|
+
foreground: 'hsl(var(--popover-foreground))',
|
|
78
|
+
},
|
|
79
|
+
primary: {
|
|
80
|
+
DEFAULT: 'hsl(var(--primary))',
|
|
81
|
+
foreground: 'hsl(var(--primary-foreground))',
|
|
82
|
+
},
|
|
83
|
+
secondary: {
|
|
84
|
+
DEFAULT: 'hsl(var(--secondary))',
|
|
85
|
+
foreground: 'hsl(var(--secondary-foreground))',
|
|
86
|
+
},
|
|
87
|
+
muted: {
|
|
88
|
+
DEFAULT: 'hsl(var(--muted))',
|
|
89
|
+
foreground: 'hsl(var(--muted-foreground))',
|
|
90
|
+
},
|
|
91
|
+
accent: {
|
|
92
|
+
DEFAULT: 'hsl(var(--accent))',
|
|
93
|
+
foreground: 'hsl(var(--accent-foreground))',
|
|
94
|
+
},
|
|
95
|
+
destructive: {
|
|
96
|
+
DEFAULT: 'hsl(var(--destructive))',
|
|
97
|
+
foreground: 'hsl(var(--destructive-foreground))',
|
|
98
|
+
},
|
|
99
|
+
border: 'hsl(var(--border))',
|
|
100
|
+
input: 'hsl(var(--input))',
|
|
101
|
+
ring: 'hsl(var(--ring))',
|
|
102
|
+
chart: {
|
|
103
|
+
1: 'hsl(var(--chart-1))',
|
|
104
|
+
2: 'hsl(var(--chart-2))',
|
|
105
|
+
3: 'hsl(var(--chart-3))',
|
|
106
|
+
4: 'hsl(var(--chart-4))',
|
|
107
|
+
5: 'hsl(var(--chart-5))',
|
|
108
|
+
},
|
|
109
|
+
sidebar: {
|
|
110
|
+
DEFAULT: 'hsl(var(--sidebar-background))',
|
|
111
|
+
foreground: 'hsl(var(--sidebar-foreground))',
|
|
112
|
+
primary: 'hsl(var(--sidebar-primary))',
|
|
113
|
+
'primary-foreground': 'hsl(var(--sidebar-primary-foreground))',
|
|
114
|
+
accent: 'hsl(var(--sidebar-accent))',
|
|
115
|
+
'accent-foreground': 'hsl(var(--sidebar-accent-foreground))',
|
|
116
|
+
border: 'hsl(var(--sidebar-border))',
|
|
117
|
+
ring: 'hsl(var(--sidebar-ring))',
|
|
118
|
+
},
|
|
119
|
+
},
|
|
120
|
+
},
|
|
121
|
+
},
|
|
122
|
+
plugins: [
|
|
123
|
+
require('tailwindcss-animate'),
|
|
124
|
+
require('@tailwindcss/typography'),
|
|
125
|
+
plugin(function ({ addVariant }) {
|
|
126
|
+
addVariant('wrapped', ({ container }) => {
|
|
127
|
+
container.walkRules((rule) => {
|
|
128
|
+
rule.selector = `.clik-chatbot-wrapper ${rule.selector}`;
|
|
129
|
+
});
|
|
130
|
+
});
|
|
131
|
+
}),
|
|
132
|
+
function ({ addUtilities }) {
|
|
133
|
+
const newUtilities = {
|
|
134
|
+
'.no-scrollbar': {
|
|
135
|
+
'-ms-overflow-style': 'none' /* IE and Edge */,
|
|
136
|
+
'scrollbar-width': 'none' /* Firefox */,
|
|
137
|
+
},
|
|
138
|
+
'.no-scrollbar::-webkit-scrollbar': {
|
|
139
|
+
display: 'none' /* Chrome, Safari, Opera */,
|
|
140
|
+
},
|
|
141
|
+
};
|
|
142
|
+
addUtilities(newUtilities, ['responsive']);
|
|
143
|
+
},
|
|
144
|
+
],
|
|
145
|
+
};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"permissions": {
|
|
3
|
-
"allow": [
|
|
4
|
-
"Bash(yarn lint:fix)",
|
|
5
|
-
"Bash(yarn build)",
|
|
6
|
-
"Bash(yarn lint src/components/Chat/Message.tsx src/utils/toolUtils.ts src/utils/messageUtils.ts)",
|
|
7
|
-
"Bash(yarn lint src/components/Chat/ProductList.tsx)"
|
|
8
|
-
],
|
|
9
|
-
"deny": [],
|
|
10
|
-
"ask": []
|
|
11
|
-
}
|
|
12
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<module type="WEB_MODULE" version="4">
|
|
3
|
-
<component name="NewModuleRootManager">
|
|
4
|
-
<content url="file://$MODULE_DIR$">
|
|
5
|
-
<excludeFolder url="file://$MODULE_DIR$/.tmp" />
|
|
6
|
-
<excludeFolder url="file://$MODULE_DIR$/temp" />
|
|
7
|
-
<excludeFolder url="file://$MODULE_DIR$/tmp" />
|
|
8
|
-
</content>
|
|
9
|
-
<orderEntry type="inheritedJdk" />
|
|
10
|
-
<orderEntry type="sourceFolder" forTests="false" />
|
|
11
|
-
</component>
|
|
12
|
-
</module>
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
<component name="ProjectCodeStyleConfiguration">
|
|
2
|
-
<code_scheme name="Project" version="173">
|
|
3
|
-
<HTMLCodeStyleSettings>
|
|
4
|
-
<option name="HTML_SPACE_INSIDE_EMPTY_TAG" value="true" />
|
|
5
|
-
</HTMLCodeStyleSettings>
|
|
6
|
-
<JSCodeStyleSettings version="0">
|
|
7
|
-
<option name="FORCE_SEMICOLON_STYLE" value="true" />
|
|
8
|
-
<option name="SPACE_BEFORE_FUNCTION_LEFT_PARENTH" value="false" />
|
|
9
|
-
<option name="USE_DOUBLE_QUOTES" value="false" />
|
|
10
|
-
<option name="FORCE_QUOTE_STYlE" value="true" />
|
|
11
|
-
<option name="ENFORCE_TRAILING_COMMA" value="WhenMultiline" />
|
|
12
|
-
<option name="SPACES_WITHIN_OBJECT_LITERAL_BRACES" value="true" />
|
|
13
|
-
<option name="SPACES_WITHIN_IMPORTS" value="true" />
|
|
14
|
-
</JSCodeStyleSettings>
|
|
15
|
-
<TypeScriptCodeStyleSettings version="0">
|
|
16
|
-
<option name="FORCE_SEMICOLON_STYLE" value="true" />
|
|
17
|
-
<option name="SPACE_BEFORE_FUNCTION_LEFT_PARENTH" value="false" />
|
|
18
|
-
<option name="USE_DOUBLE_QUOTES" value="false" />
|
|
19
|
-
<option name="FORCE_QUOTE_STYlE" value="true" />
|
|
20
|
-
<option name="ENFORCE_TRAILING_COMMA" value="WhenMultiline" />
|
|
21
|
-
<option name="SPACES_WITHIN_OBJECT_LITERAL_BRACES" value="true" />
|
|
22
|
-
<option name="SPACES_WITHIN_IMPORTS" value="true" />
|
|
23
|
-
</TypeScriptCodeStyleSettings>
|
|
24
|
-
<VueCodeStyleSettings>
|
|
25
|
-
<option name="INTERPOLATION_NEW_LINE_AFTER_START_DELIMITER" value="false" />
|
|
26
|
-
<option name="INTERPOLATION_NEW_LINE_BEFORE_END_DELIMITER" value="false" />
|
|
27
|
-
</VueCodeStyleSettings>
|
|
28
|
-
<codeStyleSettings language="HTML">
|
|
29
|
-
<option name="SOFT_MARGINS" value="80" />
|
|
30
|
-
<indentOptions>
|
|
31
|
-
<option name="INDENT_SIZE" value="2" />
|
|
32
|
-
<option name="CONTINUATION_INDENT_SIZE" value="2" />
|
|
33
|
-
<option name="TAB_SIZE" value="2" />
|
|
34
|
-
</indentOptions>
|
|
35
|
-
</codeStyleSettings>
|
|
36
|
-
<codeStyleSettings language="JavaScript">
|
|
37
|
-
<option name="SOFT_MARGINS" value="80" />
|
|
38
|
-
<indentOptions>
|
|
39
|
-
<option name="INDENT_SIZE" value="2" />
|
|
40
|
-
<option name="CONTINUATION_INDENT_SIZE" value="2" />
|
|
41
|
-
<option name="TAB_SIZE" value="2" />
|
|
42
|
-
</indentOptions>
|
|
43
|
-
</codeStyleSettings>
|
|
44
|
-
<codeStyleSettings language="TypeScript">
|
|
45
|
-
<option name="SOFT_MARGINS" value="80" />
|
|
46
|
-
<indentOptions>
|
|
47
|
-
<option name="INDENT_SIZE" value="2" />
|
|
48
|
-
<option name="CONTINUATION_INDENT_SIZE" value="2" />
|
|
49
|
-
<option name="TAB_SIZE" value="2" />
|
|
50
|
-
</indentOptions>
|
|
51
|
-
</codeStyleSettings>
|
|
52
|
-
<codeStyleSettings language="Vue">
|
|
53
|
-
<option name="SOFT_MARGINS" value="80" />
|
|
54
|
-
<indentOptions>
|
|
55
|
-
<option name="CONTINUATION_INDENT_SIZE" value="2" />
|
|
56
|
-
</indentOptions>
|
|
57
|
-
</codeStyleSettings>
|
|
58
|
-
</code_scheme>
|
|
59
|
-
</component>
|
package/.idea/modules.xml
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<project version="4">
|
|
3
|
-
<component name="ProjectModuleManager">
|
|
4
|
-
<modules>
|
|
5
|
-
<module fileurl="file://$PROJECT_DIR$/.idea/clik-ai-chatbot-embedded.iml" filepath="$PROJECT_DIR$/.idea/clik-ai-chatbot-embedded.iml" />
|
|
6
|
-
</modules>
|
|
7
|
-
</component>
|
|
8
|
-
</project>
|
package/.idea/prettier.xml
DELETED