@yourgpt/copilot-sdk 1.4.33 → 1.4.35
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/README.md +2 -0
- package/dist/styles.css +129 -42
- package/dist/ui/index.cjs +213 -452
- package/dist/ui/index.cjs.map +1 -1
- package/dist/ui/index.d.cts +15 -7
- package/dist/ui/index.d.ts +15 -7
- package/dist/ui/index.js +213 -452
- package/dist/ui/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -49,6 +49,8 @@ function App() {
|
|
|
49
49
|
|
|
50
50
|
> **Note:** The `@source` path must point to `dist/` (not `src/`) and include all file extensions `{js,ts,jsx,tsx}`.
|
|
51
51
|
|
|
52
|
+
> **Important:** For Tailwind v4, you also need the `@theme inline` block to map CSS variables like `--background` to Tailwind utilities like `bg-background`. If you have shadcn/ui, this is already configured. Otherwise, see the [Quick Start guide](https://copilot-sdk.yourgpt.ai/docs/quickstart) for complete setup.
|
|
53
|
+
|
|
52
54
|
## Theming
|
|
53
55
|
|
|
54
56
|
Works automatically with existing shadcn/ui setup. For projects without shadcn:
|
package/dist/styles.css
CHANGED
|
@@ -1,64 +1,151 @@
|
|
|
1
1
|
/* YourGPT Copilot SDK - Base Styles */
|
|
2
|
-
/*
|
|
2
|
+
/*
|
|
3
|
+
* IMPORTANT: These are fallback defaults only.
|
|
4
|
+
* If user has their own shadcn/ui CSS variables defined on :root,
|
|
5
|
+
* those will be used instead (user styles should be imported AFTER this file
|
|
6
|
+
* or defined outside @layer to take precedence).
|
|
7
|
+
*
|
|
8
|
+
* To ensure your app's variables take precedence:
|
|
9
|
+
* 1. Import SDK styles first: import "@yourgpt/copilot-sdk/ui/styles.css"
|
|
10
|
+
* 2. Then import your globals.css with your :root variables
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
/* Low-priority layer for SDK defaults - user styles will override */
|
|
14
|
+
@layer csdk-base {
|
|
15
|
+
:root {
|
|
16
|
+
--background: hsl(0 0% 100%);
|
|
17
|
+
--foreground: hsl(240 10% 3.9%);
|
|
18
|
+
--card: hsl(0 0% 100%);
|
|
19
|
+
--card-foreground: hsl(240 10% 3.9%);
|
|
20
|
+
--popover: hsl(0 0% 100%);
|
|
21
|
+
--popover-foreground: hsl(240 10% 3.9%);
|
|
22
|
+
--primary: hsl(240 5.9% 10%);
|
|
23
|
+
--primary-foreground: hsl(0 0% 98%);
|
|
24
|
+
--secondary: hsl(240 4.8% 95.9%);
|
|
25
|
+
--secondary-foreground: hsl(240 5.9% 10%);
|
|
26
|
+
--muted: hsl(240 4.8% 95.9%);
|
|
27
|
+
--muted-foreground: hsl(240 3.8% 46.1%);
|
|
28
|
+
--accent: hsl(240 4.8% 95.9%);
|
|
29
|
+
--accent-foreground: hsl(240 5.9% 10%);
|
|
30
|
+
--destructive: hsl(0 84.2% 60.2%);
|
|
31
|
+
--destructive-foreground: hsl(0 0% 98%);
|
|
32
|
+
--border: hsl(240 5.9% 90%);
|
|
33
|
+
--input: hsl(240 5.9% 90%);
|
|
34
|
+
--ring: hsl(240 5.9% 10%);
|
|
35
|
+
--radius: 0.5rem;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.dark {
|
|
39
|
+
--background: hsl(240 10% 3.9%);
|
|
40
|
+
--foreground: hsl(0 0% 98%);
|
|
41
|
+
--card: hsl(240 10% 3.9%);
|
|
42
|
+
--card-foreground: hsl(0 0% 98%);
|
|
43
|
+
--popover: hsl(240 10% 3.9%);
|
|
44
|
+
--popover-foreground: hsl(0 0% 98%);
|
|
45
|
+
--primary: hsl(0 0% 98%);
|
|
46
|
+
--primary-foreground: hsl(240 5.9% 10%);
|
|
47
|
+
--secondary: hsl(240 3.7% 15.9%);
|
|
48
|
+
--secondary-foreground: hsl(0 0% 98%);
|
|
49
|
+
--muted: hsl(240 3.7% 15.9%);
|
|
50
|
+
--muted-foreground: hsl(240 5% 64.9%);
|
|
51
|
+
--accent: hsl(240 3.7% 15.9%);
|
|
52
|
+
--accent-foreground: hsl(0 0% 98%);
|
|
53
|
+
--destructive: hsl(0 62.8% 30.6%);
|
|
54
|
+
--destructive-foreground: hsl(0 0% 98%);
|
|
55
|
+
--border: hsl(240 3.7% 15.9%);
|
|
56
|
+
--input: hsl(240 3.7% 15.9%);
|
|
57
|
+
--ring: hsl(240 4.9% 83.9%);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
3
60
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
61
|
+
/* Loader Animations */
|
|
62
|
+
@keyframes csdk-spinner-fade {
|
|
63
|
+
0%, 100% { opacity: 1; }
|
|
64
|
+
50% { opacity: 0.15; }
|
|
65
|
+
}
|
|
7
66
|
|
|
8
|
-
|
|
9
|
-
|
|
67
|
+
@keyframes csdk-thin-pulse {
|
|
68
|
+
0%, 100% { opacity: 1; transform: scale(1); }
|
|
69
|
+
50% { opacity: 0.5; transform: scale(0.85); }
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
@keyframes csdk-pulse-dot {
|
|
73
|
+
0%, 100% { opacity: 1; transform: scale(1); }
|
|
74
|
+
50% { opacity: 0.4; transform: scale(0.75); }
|
|
75
|
+
}
|
|
10
76
|
|
|
11
|
-
|
|
12
|
-
|
|
77
|
+
@keyframes csdk-bounce-dots {
|
|
78
|
+
0%, 80%, 100% { transform: translateY(0); }
|
|
79
|
+
40% { transform: translateY(-6px); }
|
|
80
|
+
}
|
|
13
81
|
|
|
14
|
-
|
|
15
|
-
|
|
82
|
+
@keyframes csdk-typing {
|
|
83
|
+
0%, 60%, 100% { opacity: 0.3; transform: scale(0.8); }
|
|
84
|
+
30% { opacity: 1; transform: scale(1); }
|
|
85
|
+
}
|
|
16
86
|
|
|
17
|
-
|
|
18
|
-
|
|
87
|
+
@keyframes csdk-wave {
|
|
88
|
+
0%, 100% { transform: scaleY(0.5); }
|
|
89
|
+
50% { transform: scaleY(1); }
|
|
90
|
+
}
|
|
19
91
|
|
|
20
|
-
|
|
21
|
-
|
|
92
|
+
@keyframes csdk-blink {
|
|
93
|
+
0%, 100% { opacity: 1; }
|
|
94
|
+
50% { opacity: 0; }
|
|
95
|
+
}
|
|
22
96
|
|
|
23
|
-
|
|
24
|
-
|
|
97
|
+
@keyframes csdk-text-blink {
|
|
98
|
+
0%, 100% { opacity: 1; }
|
|
99
|
+
50% { opacity: 0.4; }
|
|
100
|
+
}
|
|
25
101
|
|
|
26
|
-
|
|
27
|
-
|
|
102
|
+
@keyframes csdk-shimmer {
|
|
103
|
+
0% { background-position: 100% center; }
|
|
104
|
+
100% { background-position: -100% center; }
|
|
105
|
+
}
|
|
28
106
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
107
|
+
@keyframes csdk-loading-dots {
|
|
108
|
+
0%, 20% { opacity: 0; }
|
|
109
|
+
40%, 100% { opacity: 1; }
|
|
110
|
+
}
|
|
32
111
|
|
|
33
|
-
|
|
112
|
+
/* Loader Animation Classes */
|
|
113
|
+
.csdk-loader-spinner-fade {
|
|
114
|
+
animation: csdk-spinner-fade 1.2s linear infinite;
|
|
34
115
|
}
|
|
35
116
|
|
|
36
|
-
.
|
|
37
|
-
|
|
38
|
-
|
|
117
|
+
.csdk-loader-thin-pulse {
|
|
118
|
+
animation: csdk-thin-pulse 1.5s ease-in-out infinite;
|
|
119
|
+
}
|
|
39
120
|
|
|
40
|
-
|
|
41
|
-
|
|
121
|
+
.csdk-loader-pulse-dot {
|
|
122
|
+
animation: csdk-pulse-dot 1.2s ease-in-out infinite;
|
|
123
|
+
}
|
|
42
124
|
|
|
43
|
-
|
|
44
|
-
|
|
125
|
+
.csdk-loader-bounce-dots {
|
|
126
|
+
animation: csdk-bounce-dots 1.4s ease-in-out infinite;
|
|
127
|
+
}
|
|
45
128
|
|
|
46
|
-
|
|
47
|
-
|
|
129
|
+
.csdk-loader-typing {
|
|
130
|
+
animation: csdk-typing 1s infinite;
|
|
131
|
+
}
|
|
48
132
|
|
|
49
|
-
|
|
50
|
-
|
|
133
|
+
.csdk-loader-wave {
|
|
134
|
+
animation: csdk-wave 1s ease-in-out infinite;
|
|
135
|
+
}
|
|
51
136
|
|
|
52
|
-
|
|
53
|
-
|
|
137
|
+
.csdk-loader-blink {
|
|
138
|
+
animation: csdk-blink 1s step-end infinite;
|
|
139
|
+
}
|
|
54
140
|
|
|
55
|
-
|
|
56
|
-
|
|
141
|
+
.csdk-loader-text-blink {
|
|
142
|
+
animation: csdk-text-blink 2s ease-in-out infinite;
|
|
143
|
+
}
|
|
57
144
|
|
|
58
|
-
|
|
59
|
-
|
|
145
|
+
.csdk-loader-shimmer {
|
|
146
|
+
animation: csdk-shimmer 4s infinite linear;
|
|
147
|
+
}
|
|
60
148
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
--ring: hsl(240 4.9% 83.9%);
|
|
149
|
+
.csdk-loader-loading-dots {
|
|
150
|
+
animation: csdk-loading-dots 1.4s infinite;
|
|
64
151
|
}
|