@crystallize/design-system 1.7.0 → 1.9.0
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/CHANGELOG.md +13 -0
- package/dist/index.css +53 -332
- package/dist/index.d.ts +15 -8
- package/dist/index.js +1717 -4568
- package/dist/index.mjs +1639 -2355
- package/package.json +1 -1
- package/src/action-menu/action-item-separator.tsx +14 -0
- package/src/action-menu/action-item.tsx +2 -2
- package/src/action-menu/action-menu.css +8 -0
- package/src/action-menu/action-menu.tsx +2 -1
- package/src/dropdown-menu/dropdown-menu-root.tsx +3 -1
- package/src/dropdown-menu/index.ts +5 -2
- package/src/iconography/subscription-contracts.tsx +4 -4
- package/src/iconography/subscription-plans.tsx +5 -5
- package/src/rich-text-editor/model/crystallize-to-lexical.ts +12 -1
- package/src/rich-text-editor/model/lexical-to-crystallize.ts +38 -38
- package/src/rich-text-editor/nodes/BaseNodes.ts +0 -7
- package/src/rich-text-editor/nodes/TableCellNodes.ts +0 -7
- package/src/rich-text-editor/plugins/ActionsPlugin/index.tsx +1 -1
- package/src/rich-text-editor/plugins/CodeActionMenuPlugin/components/CopyButton/index.tsx +3 -2
- package/src/rich-text-editor/plugins/CodeActionMenuPlugin/components/PrettierButton/index.tsx +0 -1
- package/src/rich-text-editor/plugins/FloatingTextFormatToolbarPlugin/index.css +17 -17
- package/src/rich-text-editor/plugins/FloatingTextFormatToolbarPlugin/index.tsx +1 -1
- package/src/rich-text-editor/plugins/MaxLengthPlugin/index.tsx +2 -7
- package/src/rich-text-editor/plugins/TableActionMenuPlugin/index.tsx +80 -149
- package/src/rich-text-editor/plugins/ToolbarPlugin/index.tsx +23 -36
- package/src/rich-text-editor/plugins/ToolbarPlugin/insert-table.tsx +55 -0
- package/src/rich-text-editor/rich-text-editor.css +10 -322
- package/src/rich-text-editor/rich-text-editor.stories.tsx +35 -5
- package/src/rich-text-editor/rich-text-editor.tsx +6 -39
- package/src/rich-text-editor/tests/rich-text-editor-code.test.tsx +10 -6
- package/src/rich-text-editor/tests/rich-text-editor-model-conversions.test.tsx +19 -7
- package/src/rich-text-editor/themes/CrystallizeRTEditorTheme.css +3 -11
- package/dist/TableComponent-I2YOOYOU.css +0 -281
- package/dist/TableComponent-QINOO453.mjs +0 -1377
- package/dist/chevron-down-3FRWSIKS.svg +0 -1
- package/dist/chunk-VUXQZRSP.mjs +0 -737
- package/dist/markdown-4BGQNLLT.svg +0 -1
- package/src/rich-text-editor/nodes/KeywordNode.ts +0 -73
- package/src/rich-text-editor/nodes/TableComponent.tsx +0 -1547
- package/src/rich-text-editor/nodes/TableNode.tsx +0 -398
- package/src/rich-text-editor/plugins/ComponentPickerPlugin/index.tsx +0 -320
- package/src/rich-text-editor/plugins/DragDropPastePlugin/index.ts +0 -40
- package/src/rich-text-editor/plugins/MarkdownShortcutPlugin/index.tsx +0 -16
- package/src/rich-text-editor/plugins/MarkdownTransformers/index.ts +0 -195
- package/src/rich-text-editor/plugins/SpeechToTextPlugin/index.ts +0 -113
- package/src/rich-text-editor/plugins/TableCellResizer/index.css +0 -12
- package/src/rich-text-editor/plugins/TableCellResizer/index.tsx +0 -386
- package/src/rich-text-editor/plugins/TablePlugin.tsx +0 -190
- package/src/rich-text-editor/plugins/TreeViewPlugin/index.tsx +0 -25
- package/src/rich-text-editor/plugins/TypingPerfPlugin/index.ts +0 -117
|
@@ -1,281 +0,0 @@
|
|
|
1
|
-
/* src/button/button.css */
|
|
2
|
-
.c-btn {
|
|
3
|
-
display: inline-grid;
|
|
4
|
-
cursor: pointer;
|
|
5
|
-
grid-auto-flow: column;
|
|
6
|
-
align-items: center;
|
|
7
|
-
gap: 0.5rem;
|
|
8
|
-
white-space: nowrap;
|
|
9
|
-
border-radius: 0.25rem;
|
|
10
|
-
border-style: none;
|
|
11
|
-
background-color: transparent;
|
|
12
|
-
font-family:
|
|
13
|
-
Roboto,
|
|
14
|
-
ui-sans-serif,
|
|
15
|
-
system-ui,
|
|
16
|
-
-apple-system,
|
|
17
|
-
BlinkMacSystemFont,
|
|
18
|
-
"Segoe UI",
|
|
19
|
-
Roboto,
|
|
20
|
-
"Helvetica Neue",
|
|
21
|
-
Arial,
|
|
22
|
-
"Noto Sans",
|
|
23
|
-
sans-serif,
|
|
24
|
-
"Apple Color Emoji",
|
|
25
|
-
"Segoe UI Emoji",
|
|
26
|
-
"Segoe UI Symbol",
|
|
27
|
-
"Noto Color Emoji";
|
|
28
|
-
font-weight: 600;
|
|
29
|
-
color: rgb(var(--c-color-gray));
|
|
30
|
-
text-decoration-line: none;
|
|
31
|
-
outline-offset: -1px;
|
|
32
|
-
}
|
|
33
|
-
.c-btn:focus-visible {
|
|
34
|
-
outline-style: solid;
|
|
35
|
-
outline-width: 1px;
|
|
36
|
-
outline-color: inherit;
|
|
37
|
-
outline-color: currentColor;
|
|
38
|
-
}
|
|
39
|
-
.c-btn:disabled {
|
|
40
|
-
cursor: default;
|
|
41
|
-
--tw-text-opacity: 1;
|
|
42
|
-
color: rgb(var(--c-color-gray-300-600) / var(--tw-text-opacity));
|
|
43
|
-
}
|
|
44
|
-
.c-btn__prepend,
|
|
45
|
-
.c-btn__append {
|
|
46
|
-
display: flex;
|
|
47
|
-
align-items: center;
|
|
48
|
-
}
|
|
49
|
-
.c-btn__prepend {
|
|
50
|
-
margin-left: -0.5rem;
|
|
51
|
-
}
|
|
52
|
-
.c-btn__append {
|
|
53
|
-
margin-right: -0.5rem;
|
|
54
|
-
}
|
|
55
|
-
.c-btn__loading-spinner {
|
|
56
|
-
position: absolute;
|
|
57
|
-
left: 0.25rem;
|
|
58
|
-
display: flex;
|
|
59
|
-
align-items: center;
|
|
60
|
-
justify-content: center;
|
|
61
|
-
}
|
|
62
|
-
.c-btn,
|
|
63
|
-
.c-btn .c-btn__loading-spinner {
|
|
64
|
-
--tw-bg-opacity: 1;
|
|
65
|
-
background-color: rgb(var(--c-color-purple-50-900) / var(--tw-bg-opacity));
|
|
66
|
-
}
|
|
67
|
-
.c-btn:not(:disabled):hover {
|
|
68
|
-
outline-style: solid;
|
|
69
|
-
outline-width: 1px;
|
|
70
|
-
outline-color: rgb(var(--c-color-purple-200-700) / 1);
|
|
71
|
-
}
|
|
72
|
-
.c-btn:not(:disabled):active {
|
|
73
|
-
--tw-bg-opacity: 1;
|
|
74
|
-
background-color: rgb(var(--c-color-purple-100-800) / var(--tw-bg-opacity));
|
|
75
|
-
}
|
|
76
|
-
.c-btn-loading {
|
|
77
|
-
position: relative;
|
|
78
|
-
}
|
|
79
|
-
.c-btn-loading .c-btn__prepend,
|
|
80
|
-
.c-btn-loading .c-btn__append {
|
|
81
|
-
opacity: 0;
|
|
82
|
-
transition-property: opacity;
|
|
83
|
-
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
84
|
-
transition-duration: 150ms;
|
|
85
|
-
}
|
|
86
|
-
.c-btn-elevate {
|
|
87
|
-
--tw-shadow: 0 2px 4px rgba(130,138,144,0.15);
|
|
88
|
-
--tw-shadow-colored: 0 2px 4px var(--tw-shadow-color);
|
|
89
|
-
box-shadow:
|
|
90
|
-
var(--tw-ring-offset-shadow, 0 0 #0000),
|
|
91
|
-
var(--tw-ring-shadow, 0 0 #0000),
|
|
92
|
-
var(--tw-shadow);
|
|
93
|
-
}
|
|
94
|
-
.c-btn-elevate,
|
|
95
|
-
.c-btn-elevate .c-btn__loading-spinner {
|
|
96
|
-
--tw-bg-opacity: 1;
|
|
97
|
-
background-color: rgb(var(--c-color-elevate) / var(--tw-bg-opacity));
|
|
98
|
-
}
|
|
99
|
-
.c-btn-elevate:not(:disabled):hover {
|
|
100
|
-
outline-color: rgb(var(--c-color-gray-100-800) / 1);
|
|
101
|
-
}
|
|
102
|
-
.c-btn-elevate:not(:disabled):active {
|
|
103
|
-
--tw-bg-opacity: 1;
|
|
104
|
-
background-color: rgb(var(--c-color-purple-50-900) / var(--tw-bg-opacity));
|
|
105
|
-
}
|
|
106
|
-
.c-btn-action,
|
|
107
|
-
.c-btn-action .c-btn__loading-spinner {
|
|
108
|
-
--tw-bg-opacity: 1;
|
|
109
|
-
background-color: rgb(var(--c-color-cyan-100-800) / var(--tw-bg-opacity));
|
|
110
|
-
}
|
|
111
|
-
.c-btn-action:not(:disabled):hover {
|
|
112
|
-
outline-style: solid;
|
|
113
|
-
outline-width: 1px;
|
|
114
|
-
outline-color: rgb(var(--c-color-cyan-300-600) / 1);
|
|
115
|
-
}
|
|
116
|
-
.c-btn-action:not(:disabled):active {
|
|
117
|
-
--tw-bg-opacity: 1;
|
|
118
|
-
background-color: rgb(var(--c-color-cyan-200-700) / var(--tw-bg-opacity));
|
|
119
|
-
}
|
|
120
|
-
.c-btn-danger {
|
|
121
|
-
--tw-text-opacity: 1;
|
|
122
|
-
color: rgb(var(--c-color-pink-600-300) / var(--tw-text-opacity));
|
|
123
|
-
}
|
|
124
|
-
.c-btn-danger:not(:disabled):hover {
|
|
125
|
-
outline-color: rgb(var(--c-color-pink-300-600) / 1);
|
|
126
|
-
}
|
|
127
|
-
.c-btn-xs {
|
|
128
|
-
height: 1.5rem;
|
|
129
|
-
padding-top: 0.5rem;
|
|
130
|
-
padding-bottom: 0.5rem;
|
|
131
|
-
padding-left: 1rem;
|
|
132
|
-
padding-right: 1rem;
|
|
133
|
-
}
|
|
134
|
-
.c-btn-xs .c-btn__loading-spinner {
|
|
135
|
-
left: 3px;
|
|
136
|
-
}
|
|
137
|
-
.c-btn-sm {
|
|
138
|
-
height: 2.25rem;
|
|
139
|
-
padding-left: 1.5rem;
|
|
140
|
-
padding-right: 1.5rem;
|
|
141
|
-
font-size: 0.875rem;
|
|
142
|
-
line-height: 1.25rem;
|
|
143
|
-
}
|
|
144
|
-
.c-btn-md {
|
|
145
|
-
height: 2.75rem;
|
|
146
|
-
padding-left: 2rem;
|
|
147
|
-
padding-right: 2rem;
|
|
148
|
-
font-size: 1rem;
|
|
149
|
-
line-height: 1.5rem;
|
|
150
|
-
}
|
|
151
|
-
.c-btn-lg {
|
|
152
|
-
height: 3.5rem;
|
|
153
|
-
padding-left: 2.5rem;
|
|
154
|
-
padding-right: 2.5rem;
|
|
155
|
-
font-size: 1.125rem;
|
|
156
|
-
line-height: 1.75rem;
|
|
157
|
-
}
|
|
158
|
-
.c-btn-lg .c-btn__loading-spinner {
|
|
159
|
-
left: 0.5rem;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
/* src/spinner/spinner.css */
|
|
163
|
-
.c-spinner {
|
|
164
|
-
display: inline-flex;
|
|
165
|
-
align-items: center;
|
|
166
|
-
}
|
|
167
|
-
@keyframes spin {
|
|
168
|
-
to {
|
|
169
|
-
transform: rotate(360deg);
|
|
170
|
-
}
|
|
171
|
-
0% {
|
|
172
|
-
transform: rotate(0deg);
|
|
173
|
-
stroke-dashoffset: 26.4;
|
|
174
|
-
}
|
|
175
|
-
50% {
|
|
176
|
-
transform: rotate(720deg);
|
|
177
|
-
stroke-dashoffset: 125.6;
|
|
178
|
-
}
|
|
179
|
-
100% {
|
|
180
|
-
transform: rotate(1080deg);
|
|
181
|
-
stroke-dashoffset: 26.4;
|
|
182
|
-
}
|
|
183
|
-
}
|
|
184
|
-
.c-spinner-artifact {
|
|
185
|
-
animation: spin 2s linear infinite;
|
|
186
|
-
fill: transparent;
|
|
187
|
-
}
|
|
188
|
-
.c-spinner-children {
|
|
189
|
-
margin-left: 15px;
|
|
190
|
-
display: inline-block;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
/* src/input-with-label/input-with-label.css */
|
|
194
|
-
.c-input-with-label {
|
|
195
|
-
position: relative;
|
|
196
|
-
display: block;
|
|
197
|
-
border-radius: 0.25rem;
|
|
198
|
-
border-width: 1px;
|
|
199
|
-
border-style: solid;
|
|
200
|
-
border-color: transparent;
|
|
201
|
-
padding: 0.75rem;
|
|
202
|
-
}
|
|
203
|
-
.c-input-with-label-input-wrap {
|
|
204
|
-
margin-top: 0.25rem;
|
|
205
|
-
display: flex;
|
|
206
|
-
}
|
|
207
|
-
.c-input-with-label-input {
|
|
208
|
-
flex: 1 1 0%;
|
|
209
|
-
overflow: hidden;
|
|
210
|
-
text-overflow: ellipsis;
|
|
211
|
-
font-size: 1rem;
|
|
212
|
-
line-height: 1.5rem;
|
|
213
|
-
}
|
|
214
|
-
.c-input-with-label-append {
|
|
215
|
-
margin-right: -0.75rem;
|
|
216
|
-
display: flex;
|
|
217
|
-
flex-shrink: 0;
|
|
218
|
-
align-items: center;
|
|
219
|
-
padding-left: 0.75rem;
|
|
220
|
-
padding-right: 0.75rem;
|
|
221
|
-
}
|
|
222
|
-
.c-input-with-label-elevated {
|
|
223
|
-
--tw-bg-opacity: 1;
|
|
224
|
-
background-color: rgb(var(--c-color-elevate) / var(--tw-bg-opacity));
|
|
225
|
-
--tw-shadow: 0 2px 4px rgba(130,138,144,0.15);
|
|
226
|
-
--tw-shadow-colored: 0 2px 4px var(--tw-shadow-color);
|
|
227
|
-
box-shadow:
|
|
228
|
-
var(--tw-ring-offset-shadow, 0 0 #0000),
|
|
229
|
-
var(--tw-ring-shadow, 0 0 #0000),
|
|
230
|
-
var(--tw-shadow);
|
|
231
|
-
}
|
|
232
|
-
.c-input-with-label.c-input-with-label--error {
|
|
233
|
-
color: rgb(var(--c-color-pink-600-300));
|
|
234
|
-
}
|
|
235
|
-
.c-input-with-label-error {
|
|
236
|
-
margin-top: 0.25rem !important;
|
|
237
|
-
font-size: 0.75rem;
|
|
238
|
-
line-height: 1rem;
|
|
239
|
-
color: rgb(var(--c-color-pink-600-300));
|
|
240
|
-
}
|
|
241
|
-
.c-input-with-label-sm {
|
|
242
|
-
font-size: 0.875rem;
|
|
243
|
-
line-height: 1.25rem;
|
|
244
|
-
}
|
|
245
|
-
.c-input-with-label-lg {
|
|
246
|
-
font-size: 1.125rem;
|
|
247
|
-
line-height: 1.75rem;
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
/* src/input/input.css */
|
|
251
|
-
.c-input {
|
|
252
|
-
border-style: none;
|
|
253
|
-
background-color: transparent;
|
|
254
|
-
padding: 0px;
|
|
255
|
-
}
|
|
256
|
-
.c-input::placeholder {
|
|
257
|
-
font-size: 0.875rem;
|
|
258
|
-
line-height: 1.25rem;
|
|
259
|
-
font-weight: 400;
|
|
260
|
-
font-style: italic;
|
|
261
|
-
--tw-text-opacity: 1;
|
|
262
|
-
color: rgb(var(--c-color-gray-300-600) / var(--tw-text-opacity));
|
|
263
|
-
}
|
|
264
|
-
.c-input:focus {
|
|
265
|
-
outline: 2px solid transparent;
|
|
266
|
-
outline-offset: 2px;
|
|
267
|
-
}
|
|
268
|
-
.c-input:disabled {
|
|
269
|
-
cursor: not-allowed;
|
|
270
|
-
--tw-text-opacity: 1;
|
|
271
|
-
color: rgb(var(--c-color-gray-400-500) / var(--tw-text-opacity));
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
/* src/label/label.css */
|
|
275
|
-
.c-label {
|
|
276
|
-
font-size: 0.875rem;
|
|
277
|
-
line-height: 1.25rem;
|
|
278
|
-
font-weight: 500;
|
|
279
|
-
--tw-text-opacity: 1;
|
|
280
|
-
color: rgb(var(--c-color-gray-500-400) / var(--tw-text-opacity));
|
|
281
|
-
}
|