@poirazis/supercomponents-shared 1.2.14 → 1.2.16
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/index.js +11177 -11403
- package/dist/index.umd.cjs +15 -14
- package/package.json +8 -8
- package/src/lib/SuperButton/SuperButton.svelte +16 -21
- package/src/lib/SuperField/SuperField.svelte +13 -14
- package/src/lib/SuperForm/InnerForm.svelte +9 -2
- package/src/lib/SuperForm/SuperForm.svelte +5 -5
- package/src/lib/SuperPopover/SuperPopover.svelte +1 -1
- package/src/lib/SuperTable/SuperTable.svelte +4 -3
- package/src/lib/SuperTable/controls/RowButtonsColumn.svelte +1 -1
- package/src/lib/SuperTable/controls/SelectionColumn.svelte +1 -1
- package/src/lib/SuperTableCells/CellCommon.css +97 -35
- package/src/lib/SuperTableCells/CellDatetime.svelte +2 -3
- package/src/lib/SuperTableCells/CellLink.svelte +8 -8
- package/src/lib/SuperTableCells/CellOptions.svelte +321 -237
- package/src/lib/SuperTableCells/CellOptionsAdvanced.svelte +209 -186
- package/src/lib/SuperTableCells/CellSkeleton.svelte +1 -1
- package/src/lib/SuperTableCells/CellString.svelte +19 -39
- package/src/lib/SuperTableCells/CellStringSimple.svelte +1 -4
- package/src/lib/SuperTableColumn/SuperTableColumn.svelte +2 -2
- package/src/lib/SuperTableColumn/parts/SuperColumnRow.svelte +1 -1
- package/src/lib/SuperTableCells/JSDOC_GUIDE.md +0 -869
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@poirazis/supercomponents-shared",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.16",
|
|
4
4
|
"description": "Shared Svelte components library",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"packageManager": "bun@1.0.0",
|
|
@@ -48,13 +48,13 @@
|
|
|
48
48
|
"zod": "4.3.5"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@budibase/types": "^3.
|
|
52
|
-
"@sveltejs/package": "^2.
|
|
53
|
-
"@sveltejs/vite-plugin-svelte": "^4.0.
|
|
54
|
-
"@tsconfig/svelte": "^5.0.
|
|
55
|
-
"postcss": "^8.
|
|
56
|
-
"sass": "^1.
|
|
57
|
-
"svelte": "^5.
|
|
51
|
+
"@budibase/types": "^3.30.1",
|
|
52
|
+
"@sveltejs/package": "^2.5.7",
|
|
53
|
+
"@sveltejs/vite-plugin-svelte": "^4.0.4",
|
|
54
|
+
"@tsconfig/svelte": "^5.0.8",
|
|
55
|
+
"postcss": "^8.5.6",
|
|
56
|
+
"sass": "^1.97.3",
|
|
57
|
+
"svelte": "^5.53.0",
|
|
58
58
|
"typescript": "^5.9.3",
|
|
59
59
|
"vite": "^5.4.21",
|
|
60
60
|
"vite-plugin-css-injected-by-js": "^3.5.2"
|
|
@@ -175,13 +175,13 @@
|
|
|
175
175
|
<style>
|
|
176
176
|
.super-button {
|
|
177
177
|
border: 1px solid var(--spectrum-global-color-gray-400);
|
|
178
|
-
background-color: var(--spectrum-global-color-gray-
|
|
178
|
+
background-color: var(--spectrum-global-color-gray-50);
|
|
179
179
|
color: var(--spectrum-global-color-gray-800);
|
|
180
180
|
display: flex;
|
|
181
181
|
align-items: center;
|
|
182
|
-
|
|
182
|
+
justify-content: center;
|
|
183
|
+
padding: 0rem 1rem;
|
|
183
184
|
min-width: 5rem;
|
|
184
|
-
padding: 0rem 0.75rem;
|
|
185
185
|
gap: 0.5rem;
|
|
186
186
|
height: 2rem;
|
|
187
187
|
|
|
@@ -194,13 +194,9 @@
|
|
|
194
194
|
|
|
195
195
|
&.small {
|
|
196
196
|
min-width: 4rem;
|
|
197
|
-
padding: 0rem
|
|
197
|
+
padding: 0rem 1rem;
|
|
198
198
|
gap: 0.5rem;
|
|
199
199
|
height: 1.85rem;
|
|
200
|
-
|
|
201
|
-
&.ink {
|
|
202
|
-
height: 1.5rem;
|
|
203
|
-
}
|
|
204
200
|
}
|
|
205
201
|
|
|
206
202
|
&.large {
|
|
@@ -209,6 +205,8 @@
|
|
|
209
205
|
|
|
210
206
|
& > span {
|
|
211
207
|
white-space: nowrap;
|
|
208
|
+
font-size: 14px;
|
|
209
|
+
font-weight: 600;
|
|
212
210
|
}
|
|
213
211
|
|
|
214
212
|
&.icon {
|
|
@@ -229,6 +227,7 @@
|
|
|
229
227
|
& > i {
|
|
230
228
|
display: none;
|
|
231
229
|
opacity: 0.9;
|
|
230
|
+
font-weight: 400;
|
|
232
231
|
}
|
|
233
232
|
}
|
|
234
233
|
|
|
@@ -286,12 +285,9 @@
|
|
|
286
285
|
}
|
|
287
286
|
}
|
|
288
287
|
.ink {
|
|
289
|
-
background-color: var(--spectrum-global-color-gray-
|
|
290
|
-
border: 1px solid
|
|
288
|
+
background-color: var(--spectrum-global-color-gray-800);
|
|
289
|
+
border: 1px solid transparent;
|
|
291
290
|
color: var(--spectrum-global-color-gray-50);
|
|
292
|
-
font-weight: 700;
|
|
293
|
-
opacity: 0.9;
|
|
294
|
-
max-height: 1.35rem;
|
|
295
291
|
|
|
296
292
|
&.quiet {
|
|
297
293
|
border-color: transparent !important;
|
|
@@ -300,12 +296,12 @@
|
|
|
300
296
|
&:hover,
|
|
301
297
|
&:focus {
|
|
302
298
|
color: var(--spectrum-global-color-gray-50);
|
|
303
|
-
background-color: var(--spectrum-global-color-gray-
|
|
299
|
+
background-color: var(--spectrum-global-color-gray-900);
|
|
304
300
|
}
|
|
305
301
|
}
|
|
306
302
|
&:hover,
|
|
307
303
|
&:focus {
|
|
308
|
-
background-color: var(--spectrum-global-color-gray-
|
|
304
|
+
background-color: var(--spectrum-global-color-gray-900);
|
|
309
305
|
}
|
|
310
306
|
|
|
311
307
|
&:active {
|
|
@@ -315,8 +311,9 @@
|
|
|
315
311
|
.primary {
|
|
316
312
|
&:hover,
|
|
317
313
|
&:focus {
|
|
318
|
-
border: 1px solid var(--spectrum-global-color-gray-
|
|
319
|
-
color: var(--spectrum-global-color-gray-
|
|
314
|
+
border: 1px solid var(--spectrum-global-color-gray-600);
|
|
315
|
+
background-color: var(--spectrum-global-color-gray-800);
|
|
316
|
+
color: var(--spectrum-global-color-gray-50);
|
|
320
317
|
}
|
|
321
318
|
&:active {
|
|
322
319
|
background-color: var(--spectrum-global-color-gray-100);
|
|
@@ -327,7 +324,7 @@
|
|
|
327
324
|
border-color: transparent;
|
|
328
325
|
background-color: transparent;
|
|
329
326
|
&:hover {
|
|
330
|
-
background-color: var(--spectrum-global-color-gray-
|
|
327
|
+
background-color: var(--spectrum-global-color-gray-400);
|
|
331
328
|
color: var(--spectrum-global-color-gray-900);
|
|
332
329
|
}
|
|
333
330
|
}
|
|
@@ -340,12 +337,10 @@
|
|
|
340
337
|
font-weight: 500;
|
|
341
338
|
|
|
342
339
|
&.quiet {
|
|
343
|
-
border-color: transparent;
|
|
344
340
|
background-color: transparent;
|
|
345
341
|
|
|
346
342
|
&:hover {
|
|
347
|
-
background-color:
|
|
348
|
-
border-color: var(--spectrum-global-color-gray-400);
|
|
343
|
+
background-color: var(--spectrum-global-color-gray-200);
|
|
349
344
|
}
|
|
350
345
|
}
|
|
351
346
|
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
showTooltip = false;
|
|
53
53
|
};
|
|
54
54
|
|
|
55
|
-
$: width = labelPos == "left" ? (labelWidth ? labelWidth : "
|
|
55
|
+
$: width = labelPos == "left" ? (labelWidth ? labelWidth : "6rem") : "auto";
|
|
56
56
|
$: isLabelTruncated = checkIfTruncated(labelElement);
|
|
57
57
|
</script>
|
|
58
58
|
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
class:left-label={labelPos == "left"}
|
|
62
62
|
class:multirow
|
|
63
63
|
class:tall
|
|
64
|
-
style:--height={height}
|
|
64
|
+
style:--field-height={height}
|
|
65
65
|
style:--max-height={maxHeight}
|
|
66
66
|
>
|
|
67
67
|
{#if labelPos}
|
|
@@ -106,16 +106,17 @@
|
|
|
106
106
|
|
|
107
107
|
<style>
|
|
108
108
|
.super-field {
|
|
109
|
+
flex: 1;
|
|
109
110
|
min-width: 80px;
|
|
110
111
|
width: 100%;
|
|
111
112
|
display: flex;
|
|
112
113
|
flex-direction: column;
|
|
113
114
|
align-items: stretch;
|
|
114
115
|
overflow: hidden;
|
|
115
|
-
min-height: var(--height);
|
|
116
|
+
min-height: var(--field-height, 2rem);
|
|
116
117
|
|
|
117
118
|
&.multirow {
|
|
118
|
-
max-height: var(--height);
|
|
119
|
+
max-height: var(--field-height);
|
|
119
120
|
}
|
|
120
121
|
|
|
121
122
|
&.left-label {
|
|
@@ -132,40 +133,37 @@
|
|
|
132
133
|
flex-direction: row;
|
|
133
134
|
align-items: stretch;
|
|
134
135
|
}
|
|
135
|
-
|
|
136
|
-
&:focus-within {
|
|
137
|
-
& > .superlabel {
|
|
138
|
-
color: var(--spectrum-global-golor-gray-700);
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
136
|
}
|
|
142
137
|
|
|
143
138
|
.inline-cells {
|
|
144
|
-
flex:
|
|
139
|
+
flex: 1;
|
|
145
140
|
display: flex;
|
|
146
141
|
align-items: stretch;
|
|
147
142
|
min-height: 2rem;
|
|
148
143
|
overflow: hidden;
|
|
149
144
|
|
|
150
145
|
&.multirow {
|
|
146
|
+
flex: 1;
|
|
151
147
|
flex-direction: column;
|
|
152
148
|
align-items: stretch;
|
|
153
|
-
justify-content: flex;
|
|
154
149
|
}
|
|
155
150
|
}
|
|
156
151
|
|
|
157
152
|
.superlabel {
|
|
158
|
-
flex: 0 0 auto;
|
|
159
153
|
width: var(--label-width);
|
|
160
154
|
overflow: hidden;
|
|
161
155
|
display: flex;
|
|
162
156
|
align-items: center;
|
|
163
157
|
justify-content: space-between;
|
|
164
|
-
font-weight:
|
|
158
|
+
font-weight: 300;
|
|
165
159
|
line-height: 1.65rem;
|
|
160
|
+
letter-spacing: 0.35px;
|
|
166
161
|
color: var(--spectrum-global-color-gray-700);
|
|
162
|
+
font-family: "inter", sans-serif;
|
|
167
163
|
gap: 1rem;
|
|
168
164
|
transition: 130ms;
|
|
165
|
+
padding-left: 2px;
|
|
166
|
+
opacity: 0.9;
|
|
169
167
|
|
|
170
168
|
&.left {
|
|
171
169
|
flex-direction: column;
|
|
@@ -173,6 +171,7 @@
|
|
|
173
171
|
justify-content: center;
|
|
174
172
|
line-height: 1rem;
|
|
175
173
|
gap: 0px;
|
|
174
|
+
padding-left: unset;
|
|
176
175
|
|
|
177
176
|
&.tall {
|
|
178
177
|
justify-content: flex-start;
|
|
@@ -52,6 +52,8 @@
|
|
|
52
52
|
export let formValue: Record<string, any> = {};
|
|
53
53
|
export let labelPosition: string | boolean = "above";
|
|
54
54
|
export let columns: number = 1;
|
|
55
|
+
export let rowGap: string = "0.5rem";
|
|
56
|
+
export let columnGap: string = "0.5rem";
|
|
55
57
|
|
|
56
58
|
const {
|
|
57
59
|
Provider,
|
|
@@ -593,8 +595,10 @@
|
|
|
593
595
|
class="super-form-inner-form"
|
|
594
596
|
class:labels-left={labelPosition === "left"}
|
|
595
597
|
class:no-labels={labelPosition === false || labelPosition === "none"}
|
|
596
|
-
class:field-group={
|
|
598
|
+
class:field-group={true}
|
|
597
599
|
style:grid-template-columns={`repeat(${columns * 6}, 1fr)`}
|
|
600
|
+
style:row-gap={rowGap}
|
|
601
|
+
style:column-gap={columnGap}
|
|
598
602
|
>
|
|
599
603
|
<slot />
|
|
600
604
|
</div>
|
|
@@ -614,6 +618,8 @@
|
|
|
614
618
|
flex: auto;
|
|
615
619
|
display: grid;
|
|
616
620
|
column-gap: 0.5rem;
|
|
621
|
+
row-gap: 0.5rem;
|
|
622
|
+
align-content: flex-start;
|
|
617
623
|
}
|
|
618
624
|
|
|
619
625
|
:global(.super-form-inner-form.field-group > .component > *) {
|
|
@@ -621,7 +627,8 @@
|
|
|
621
627
|
}
|
|
622
628
|
|
|
623
629
|
.super-form-inner-form.labels-left {
|
|
624
|
-
row-gap: 0.
|
|
630
|
+
row-gap: 0.5rem;
|
|
631
|
+
column-gap: 1rem;
|
|
625
632
|
}
|
|
626
633
|
.super-form-inner-form.no-labels {
|
|
627
634
|
row-gap: 0.25rem;
|
|
@@ -30,6 +30,8 @@
|
|
|
30
30
|
export let provideContext: boolean = true;
|
|
31
31
|
export let provideContextScope: "local" | "global" = "global";
|
|
32
32
|
export let labelPosition: "above" | "left" | false;
|
|
33
|
+
export let rowGap: string = "0.5rem";
|
|
34
|
+
export let columnGap: string = "0.5rem";
|
|
33
35
|
|
|
34
36
|
// Export the full form API to be used by parents
|
|
35
37
|
export let form;
|
|
@@ -67,11 +69,7 @@
|
|
|
67
69
|
row,
|
|
68
70
|
);
|
|
69
71
|
$: resetKey = hashString(
|
|
70
|
-
schemaKey +
|
|
71
|
-
JSON.stringify(initialValues) +
|
|
72
|
-
actionType +
|
|
73
|
-
readonly +
|
|
74
|
-
disabled,
|
|
72
|
+
schemaKey + JSON.stringify(initialValues) + actionType,
|
|
75
73
|
);
|
|
76
74
|
|
|
77
75
|
const getInitialValues = (
|
|
@@ -152,6 +150,8 @@
|
|
|
152
150
|
{provideContext}
|
|
153
151
|
{provideContextScope}
|
|
154
152
|
{labelPosition}
|
|
153
|
+
{rowGap}
|
|
154
|
+
{columnGap}
|
|
155
155
|
on:change
|
|
156
156
|
on:reset
|
|
157
157
|
>
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
class:hide-popover={open && !showPopover}
|
|
111
111
|
role="presentation"
|
|
112
112
|
style="height: {customHeight}; --customZindex: {customZindex};"
|
|
113
|
-
transition:fly|local={{ y: -20, duration: animate ?
|
|
113
|
+
transition:fly|local={{ y: -20, duration: animate ? 350 : 0 }}
|
|
114
114
|
>
|
|
115
115
|
<slot />
|
|
116
116
|
</div>
|
|
@@ -135,7 +135,6 @@
|
|
|
135
135
|
|
|
136
136
|
$: dataSourceStore.set(dataSource);
|
|
137
137
|
$: filterStore.set(filter);
|
|
138
|
-
$: stbSchema.set($stbData?.definition?.schema);
|
|
139
138
|
|
|
140
139
|
// Update columnsStore when columnList changes
|
|
141
140
|
$: columnsStore.set(columnList || []);
|
|
@@ -1193,6 +1192,7 @@
|
|
|
1193
1192
|
$stbSelected = [];
|
|
1194
1193
|
$cachedRows = [];
|
|
1195
1194
|
$stbVisibleRows = [];
|
|
1195
|
+
$stbSchema = {};
|
|
1196
1196
|
|
|
1197
1197
|
stbData = createFetch($dataSourceStore);
|
|
1198
1198
|
|
|
@@ -1214,6 +1214,7 @@
|
|
|
1214
1214
|
}
|
|
1215
1215
|
|
|
1216
1216
|
$cachedRows = [...fetchState.rows];
|
|
1217
|
+
$stbSchema = fetchState.definition?.schema || {};
|
|
1217
1218
|
return "Idle";
|
|
1218
1219
|
}
|
|
1219
1220
|
},
|
|
@@ -1610,8 +1611,8 @@
|
|
|
1610
1611
|
style:font-size={sizingMap[size].rowFontSize}
|
|
1611
1612
|
style:--super-table-devider-color={$tableStyles.color}
|
|
1612
1613
|
style:--super-table-body-height={maxBodyHeight}
|
|
1613
|
-
style:--super-table-header-height={$tableStyles.headerHeight}
|
|
1614
|
-
style:--super-table-footer-height={$tableStyles.footerHeight}
|
|
1614
|
+
style:--super-table-header-height={$tableStyles.headerHeight + "px"}
|
|
1615
|
+
style:--super-table-footer-height={$tableStyles.footerHeight + "px"}
|
|
1615
1616
|
style:--super-table-horizontal-dividers={$tableStyles.horizontal}
|
|
1616
1617
|
style:--super-table-vertical-dividers={$tableStyles.vertical}
|
|
1617
1618
|
style:--super-table-cell-padding={sizingMap[size].cellPadding}
|
|
@@ -70,7 +70,7 @@
|
|
|
70
70
|
class:hovered={$stbHovered == visibleRow || $stbMenuID == visibleRow}
|
|
71
71
|
class:is-editing={$stbEditing == visibleRow}
|
|
72
72
|
class:disabled={$rowMetadata[visibleRow].disabled}
|
|
73
|
-
style:min-height={$rowMetadata[visibleRow].height}
|
|
73
|
+
style:min-height={$rowMetadata[visibleRow].height + "px"}
|
|
74
74
|
style:padding-right={canScroll && right ? "1.5rem" : "0.5rem"}
|
|
75
75
|
>
|
|
76
76
|
<!-- svelte-ignore a11y-click-events-have-key-events -->
|
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
class:selected
|
|
83
83
|
class:hovered={$stbHovered == visibleRow || $stbMenuID == visibleRow}
|
|
84
84
|
class:disabled={$stbRowMetadata[visibleRow]?.disabled}
|
|
85
|
-
style:height={$stbRowMetadata[visibleRow]?.height}
|
|
85
|
+
style:height={$stbRowMetadata[visibleRow]?.height + "px"}
|
|
86
86
|
on:mouseenter={() => ($stbHovered = visibleRow)}
|
|
87
87
|
on:mouseleave={() => ($stbHovered = null)}
|
|
88
88
|
>
|
|
@@ -9,8 +9,11 @@
|
|
|
9
9
|
width: 100%;
|
|
10
10
|
max-height: 2rem;
|
|
11
11
|
font-size: 13px;
|
|
12
|
-
padding: 0 0.
|
|
12
|
+
padding: 0 0.75rem 0 0.75rem;
|
|
13
13
|
gap: 0.5rem;
|
|
14
|
+
font-family:
|
|
15
|
+
var(--spectrum-textfield-text-font-family),
|
|
16
|
+
var(--spectrum-global-font-family-base);
|
|
14
17
|
|
|
15
18
|
&.multirow {
|
|
16
19
|
padding: unset;
|
|
@@ -66,32 +69,43 @@
|
|
|
66
69
|
overflow: hidden;
|
|
67
70
|
gap: 0.5rem;
|
|
68
71
|
|
|
72
|
+
span {
|
|
73
|
+
overflow: hidden;
|
|
74
|
+
text-overflow: ellipsis;
|
|
75
|
+
white-space: nowrap;
|
|
76
|
+
}
|
|
77
|
+
|
|
69
78
|
&:focus {
|
|
70
79
|
outline: none;
|
|
71
80
|
}
|
|
72
81
|
|
|
73
82
|
&.placeholder {
|
|
74
|
-
font-weight: 400;
|
|
75
|
-
color: var(--spectrum-global-color-gray-500);
|
|
76
83
|
overflow: hidden;
|
|
77
84
|
text-overflow: ellipsis;
|
|
78
85
|
white-space: nowrap;
|
|
86
|
+
font-weight: 400;
|
|
87
|
+
color: var(--spectrum-global-color-gray-500);
|
|
88
|
+
font-style: italic !important;
|
|
79
89
|
|
|
80
|
-
|
|
90
|
+
span {
|
|
91
|
+
overflow: hidden;
|
|
92
|
+
text-overflow: ellipsis;
|
|
93
|
+
white-space: nowrap;
|
|
94
|
+
font-weight: 400;
|
|
95
|
+
color: var(--spectrum-global-color-gray-500);
|
|
81
96
|
font-style: italic !important;
|
|
82
97
|
}
|
|
83
98
|
}
|
|
84
99
|
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
100
|
+
&.textarea {
|
|
101
|
+
flex: 1;
|
|
102
|
+
padding: 0.5rem 0.75rem !important;
|
|
103
|
+
display: flex;
|
|
104
|
+
align-items: flex-start;
|
|
105
|
+
overflow-y: auto;
|
|
90
106
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
white-space: normal;
|
|
94
|
-
text-overflow: unset;
|
|
107
|
+
span {
|
|
108
|
+
white-space: pre-wrap;
|
|
95
109
|
}
|
|
96
110
|
}
|
|
97
111
|
|
|
@@ -108,7 +122,7 @@
|
|
|
108
122
|
display: flex;
|
|
109
123
|
align-items: center;
|
|
110
124
|
overflow: hidden;
|
|
111
|
-
padding:
|
|
125
|
+
padding: 0rem 0.5rem;
|
|
112
126
|
|
|
113
127
|
.loope {
|
|
114
128
|
display: none;
|
|
@@ -258,6 +272,42 @@
|
|
|
258
272
|
}
|
|
259
273
|
}
|
|
260
274
|
|
|
275
|
+
.superCell.loading {
|
|
276
|
+
pointer-events: none;
|
|
277
|
+
background-color: rgb(
|
|
278
|
+
from var(--spectrum-global-color-gray-200) r g b / 0.75
|
|
279
|
+
) !important;
|
|
280
|
+
border: 1px solid rgb(from var(--spectrum-global-color-gray-200) r g b / 0.75) !important;
|
|
281
|
+
}
|
|
282
|
+
.superCell.loading::after {
|
|
283
|
+
content: "";
|
|
284
|
+
position: absolute;
|
|
285
|
+
top: 0;
|
|
286
|
+
left: 0;
|
|
287
|
+
right: 0;
|
|
288
|
+
bottom: 0;
|
|
289
|
+
opacity: 0.65;
|
|
290
|
+
background-image: linear-gradient(
|
|
291
|
+
90deg,
|
|
292
|
+
rgba(255, 255, 255, 0) 0,
|
|
293
|
+
rgba(255, 255, 255, 0.15) 20%,
|
|
294
|
+
rgba(255, 255, 255, 0.2) 60%,
|
|
295
|
+
rgba(255, 255, 255, 0.15) 80%,
|
|
296
|
+
rgba(255, 255, 255, 0)
|
|
297
|
+
) !important;
|
|
298
|
+
animation: loadingShimmer 2s infinite;
|
|
299
|
+
pointer-events: none;
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
@keyframes loadingShimmer {
|
|
303
|
+
0% {
|
|
304
|
+
transform: translateX(-80%);
|
|
305
|
+
}
|
|
306
|
+
100% {
|
|
307
|
+
transform: translateX(100%);
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
|
|
261
311
|
.superCell.formInput {
|
|
262
312
|
border-radius: 4px;
|
|
263
313
|
color: var(--spectrum-global-color-gray-800);
|
|
@@ -266,15 +316,18 @@
|
|
|
266
316
|
min-height: 2rem;
|
|
267
317
|
|
|
268
318
|
&.inEdit:not(.naked-field):not(.has-popup) {
|
|
269
|
-
border: 1px solid var(--spectrum-global-color-blue-400);
|
|
319
|
+
border: 1px solid var(--primaryColor, --spectrum-global-color-blue-400);
|
|
270
320
|
|
|
271
321
|
&:focus-within:not(.naked-field):not(.has-popup) {
|
|
272
|
-
border: 1px solid var(--spectrum-global-color-blue-400);
|
|
322
|
+
border: 1px solid var(--primaryColor, --spectrum-global-color-blue-400);
|
|
273
323
|
}
|
|
274
324
|
}
|
|
275
325
|
|
|
276
|
-
&:hover:not(.disabled):not(.readonly):not(.inEdit) {
|
|
277
|
-
border: 1px solid
|
|
326
|
+
&:hover:not(.disabled):not(.readonly):not(.inEdit):not(.naked-field) {
|
|
327
|
+
border: 1px solid
|
|
328
|
+
rgb(
|
|
329
|
+
from var(--primaryColor, --spectrum-global-color-blue-400) r g b / 0.5
|
|
330
|
+
) !important;
|
|
278
331
|
cursor: pointer;
|
|
279
332
|
}
|
|
280
333
|
|
|
@@ -307,8 +360,15 @@
|
|
|
307
360
|
}
|
|
308
361
|
|
|
309
362
|
.superCell.formInput.has-popup {
|
|
363
|
+
background-color: var(--spectrum-global-color-gray-50);
|
|
364
|
+
|
|
365
|
+
&:hover:not(.disabled):not(.readonly):not(.inEdit) {
|
|
366
|
+
border-color: var(--spectrum-global-color-gray-100) !important;
|
|
367
|
+
cursor: pointer;
|
|
368
|
+
}
|
|
369
|
+
|
|
310
370
|
&.inEdit {
|
|
311
|
-
border: 1px solid var(--spectrum-global-color-
|
|
371
|
+
border: 1px solid var(--spectrum-global-color-gray-200) !important;
|
|
312
372
|
background-color: var(--spectrum-global-color-gray-200) !important;
|
|
313
373
|
cursor: pointer !important;
|
|
314
374
|
}
|
|
@@ -322,7 +382,7 @@
|
|
|
322
382
|
min-height: unset;
|
|
323
383
|
max-height: unset;
|
|
324
384
|
border: 1px solid transparent;
|
|
325
|
-
padding: 0 0.5rem;
|
|
385
|
+
padding: 0 0.5rem !important;
|
|
326
386
|
|
|
327
387
|
&:hover:not(.readonly):not(.inEdit) {
|
|
328
388
|
border: 1px dashed var(--spectrum-global-color-blue-400);
|
|
@@ -353,6 +413,10 @@
|
|
|
353
413
|
color: inherit;
|
|
354
414
|
letter-spacing: inherit;
|
|
355
415
|
font-size: inherit;
|
|
416
|
+
padding: unset !important;
|
|
417
|
+
font-family:
|
|
418
|
+
var(--spectrum-textfield-text-font-family),
|
|
419
|
+
var(--spectrum-global-font-family-base);
|
|
356
420
|
|
|
357
421
|
&:focus {
|
|
358
422
|
outline: none;
|
|
@@ -363,22 +427,20 @@
|
|
|
363
427
|
}
|
|
364
428
|
|
|
365
429
|
&.placeholder {
|
|
430
|
+
overflow: hidden;
|
|
431
|
+
text-overflow: ellipsis;
|
|
432
|
+
white-space: nowrap;
|
|
433
|
+
font-weight: 400;
|
|
434
|
+
color: var(--spectrum-global-color-gray-500);
|
|
366
435
|
font-style: italic !important;
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
overflow: auto;
|
|
376
|
-
resize: none;
|
|
377
|
-
font-family: inherit;
|
|
378
|
-
font-size: inherit;
|
|
379
|
-
line-height: inherit;
|
|
380
|
-
color: inherit;
|
|
381
|
-
height: unset;
|
|
436
|
+
span {
|
|
437
|
+
overflow: hidden;
|
|
438
|
+
text-overflow: ellipsis;
|
|
439
|
+
white-space: nowrap;
|
|
440
|
+
font-weight: 400;
|
|
441
|
+
color: var(--spectrum-global-color-gray-500);
|
|
442
|
+
font-style: italic !important;
|
|
443
|
+
}
|
|
382
444
|
}
|
|
383
445
|
}
|
|
384
446
|
|
|
@@ -146,7 +146,7 @@
|
|
|
146
146
|
? processStringSync(cellOptions.template, { value })
|
|
147
147
|
: value
|
|
148
148
|
? formatDate(innerDate, currentDateFormat)
|
|
149
|
-
:
|
|
149
|
+
: undefined;
|
|
150
150
|
|
|
151
151
|
$: placeholder = cellOptions?.placeholder || "";
|
|
152
152
|
$: inEdit = $cellState == "Editing";
|
|
@@ -196,7 +196,6 @@
|
|
|
196
196
|
class:open-popup={open}
|
|
197
197
|
style:color={cellOptions.color}
|
|
198
198
|
style:background={cellOptions.background}
|
|
199
|
-
style:font-weight={cellOptions.fontWeight}
|
|
200
199
|
on:focus={cellState.focus}
|
|
201
200
|
on:keypress={cellState.handleKeyboard}
|
|
202
201
|
on:focusout={cellState.focusout}
|
|
@@ -211,7 +210,7 @@
|
|
|
211
210
|
class:placeholder={!formattedValue}
|
|
212
211
|
on:click={() => (open = !open)}
|
|
213
212
|
>
|
|
214
|
-
{formattedValue || placeholder}
|
|
213
|
+
<span>{formattedValue || placeholder}</span>
|
|
215
214
|
<i
|
|
216
215
|
class="ri-calendar-line"
|
|
217
216
|
style="font-size: 16px; justify-self: flex-end"
|
|
@@ -205,7 +205,14 @@
|
|
|
205
205
|
<div class="value" class:placeholder={localValue?.length < 1}>
|
|
206
206
|
{#if localValue?.length < 1}
|
|
207
207
|
<span> {placeholder} </span>
|
|
208
|
-
{:else if
|
|
208
|
+
{:else if simpleView}
|
|
209
|
+
<span>
|
|
210
|
+
{#if cellOptions.role == "formInput" && localValue.length > 1}
|
|
211
|
+
({localValue.length})
|
|
212
|
+
{/if}
|
|
213
|
+
{localValue.map((v) => v.primaryDisplay).join(", ")}
|
|
214
|
+
</span>
|
|
215
|
+
{:else}
|
|
209
216
|
<div
|
|
210
217
|
class="items"
|
|
211
218
|
class:pills
|
|
@@ -237,13 +244,6 @@
|
|
|
237
244
|
</span>
|
|
238
245
|
{/if}
|
|
239
246
|
</div>
|
|
240
|
-
{:else}
|
|
241
|
-
<span>
|
|
242
|
-
{#if cellOptions.role == "formInput" && localValue.length > 1}
|
|
243
|
-
({localValue.length})
|
|
244
|
-
{/if}
|
|
245
|
-
{localValue.map((v) => v.primaryDisplay).join(", ")}
|
|
246
|
-
</span>
|
|
247
247
|
{/if}
|
|
248
248
|
</div>
|
|
249
249
|
{#if !readonly && (cellOptions.role == "formInput" || inEdit)}
|