@lavalogic/scoria 0.19.3 → 0.19.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/dist/Components/CollapsibleCard.svelte +2 -1
- package/dist/Components/GridInput.svelte +3 -2
- package/dist/Components/Modal.svelte +23 -7
- package/dist/Components/Table/Body/Rows/Columns/FocusableImmutableCell.svelte +2 -2
- package/dist/Components/Table/Body/Rows/Columns/TableNumberInput.svelte +7 -3
- package/dist/Components/Table/Body/Rows/Columns/TableTextInput.svelte +7 -3
- package/dist/Helpers/Helpers.svelte.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
<svelte:options runes />
|
|
2
2
|
|
|
3
3
|
<script lang="ts">
|
|
4
|
+
import { loadingText } from '../Helpers/Helpers.svelte.js';
|
|
4
5
|
import { Size } from '../Types/Internal/Size.js';
|
|
5
6
|
import { Colour } from '../scss/colours.js';
|
|
6
7
|
import Action from './Action.svelte';
|
|
@@ -34,7 +35,7 @@
|
|
|
34
35
|
<h3>{title}</h3>
|
|
35
36
|
{#if subtitle}
|
|
36
37
|
{#await subtitle}
|
|
37
|
-
<span>
|
|
38
|
+
<span>{loadingText}</span>
|
|
38
39
|
{:then subtitle}
|
|
39
40
|
<span>{subtitle}</span>
|
|
40
41
|
{/await}
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
module
|
|
6
6
|
>
|
|
7
7
|
import { dev } from '$app/environment';
|
|
8
|
+
import { loadingText } from '../Helpers/Helpers.svelte.js';
|
|
8
9
|
import type { GridItem } from '../Types/Internal/GridItem.js';
|
|
9
10
|
import type {
|
|
10
11
|
GridMultiSelectItem,
|
|
@@ -105,7 +106,7 @@
|
|
|
105
106
|
{:else if isSelect(item)}
|
|
106
107
|
{#if isMultiSelect(item)}
|
|
107
108
|
{#await item.options}
|
|
108
|
-
|
|
109
|
+
{loadingText}
|
|
109
110
|
{:then options}
|
|
110
111
|
{#if isMultiSelectObject<V, VP>(item)}
|
|
111
112
|
<MultiSelect
|
|
@@ -139,7 +140,7 @@
|
|
|
139
140
|
{/await}
|
|
140
141
|
{:else if isSingleSelect(item)}
|
|
141
142
|
{#await item.options}
|
|
142
|
-
|
|
143
|
+
{loadingText}
|
|
143
144
|
{:then options}
|
|
144
145
|
{#if isSingleSelectObject(item)}
|
|
145
146
|
<SingleSelect
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
<svelte:options runes />
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script
|
|
4
|
+
module
|
|
5
|
+
lang="ts"
|
|
6
|
+
>
|
|
4
7
|
import { DATAMatrix } from '../Helpers/Datamatrix.js';
|
|
5
8
|
import { devCatch, passthrough } from '../Helpers/Helpers.svelte.js';
|
|
6
9
|
import { ColourSet } from '../scss/colours.js';
|
|
@@ -57,7 +60,7 @@
|
|
|
57
60
|
explanation,
|
|
58
61
|
children,
|
|
59
62
|
footer,
|
|
60
|
-
onclose
|
|
63
|
+
onclose,
|
|
61
64
|
}: ModalProps = $props();
|
|
62
65
|
|
|
63
66
|
let dialog: HTMLDialogElement | undefined;
|
|
@@ -160,7 +163,7 @@
|
|
|
160
163
|
size={Size.DoubleXLarge}
|
|
161
164
|
onclick={() => dialog?.close()}
|
|
162
165
|
icon={{
|
|
163
|
-
name: 'cross'
|
|
166
|
+
name: 'cross',
|
|
164
167
|
}}
|
|
165
168
|
onkeydown={handleEsc}
|
|
166
169
|
colourSet={ColourSet.Primary}
|
|
@@ -181,11 +184,17 @@
|
|
|
181
184
|
{#if defaultTimer}
|
|
182
185
|
<!-- class:paused -->
|
|
183
186
|
<div class="bar-container">
|
|
184
|
-
<div
|
|
187
|
+
<div
|
|
188
|
+
class:paused
|
|
189
|
+
class="bar-timer"
|
|
190
|
+
></div>
|
|
185
191
|
</div>
|
|
186
192
|
{/if}
|
|
187
193
|
|
|
188
|
-
<div
|
|
194
|
+
<div
|
|
195
|
+
class="modal-main"
|
|
196
|
+
class:noscroll
|
|
197
|
+
>
|
|
189
198
|
{#if explanation}
|
|
190
199
|
{@render explanation()}
|
|
191
200
|
{/if}
|
|
@@ -201,7 +210,10 @@
|
|
|
201
210
|
<div class="button-barcode-set">
|
|
202
211
|
{#if button.barcodeValue}
|
|
203
212
|
{@const icon = DATAMatrix(button.barcodeValue)}
|
|
204
|
-
<DataMatrixIcon
|
|
213
|
+
<DataMatrixIcon
|
|
214
|
+
title={button.label}
|
|
215
|
+
{icon}
|
|
216
|
+
/>
|
|
205
217
|
{/if}
|
|
206
218
|
<button
|
|
207
219
|
onkeydown={passthrough}
|
|
@@ -215,7 +227,10 @@
|
|
|
215
227
|
<div class="button-barcode-set">
|
|
216
228
|
{#if button.barcodeValue}
|
|
217
229
|
{@const icon = DATAMatrix(button.barcodeValue)}
|
|
218
|
-
<DataMatrixIcon
|
|
230
|
+
<DataMatrixIcon
|
|
231
|
+
title={button.label}
|
|
232
|
+
{icon}
|
|
233
|
+
/>
|
|
219
234
|
{/if}
|
|
220
235
|
<button
|
|
221
236
|
onkeydown={passthrough}
|
|
@@ -486,6 +501,7 @@ form.modal-root {
|
|
|
486
501
|
overflow: visible;
|
|
487
502
|
}
|
|
488
503
|
|
|
504
|
+
.modal-main.noscroll,
|
|
489
505
|
.noscroll {
|
|
490
506
|
overflow: visible;
|
|
491
507
|
}
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
>
|
|
7
7
|
import { TableContext } from '../../../Types/Context/TableContext.svelte.js';
|
|
8
8
|
import { TableFocusDetails } from '../../../Types/Focus/TableFocusDetails.svelte.js';
|
|
9
|
-
import { devCatch, isValidityTuple } from '../../../../../Helpers/Helpers.svelte.js';
|
|
9
|
+
import { devCatch, isValidityTuple, loadingText } from '../../../../../Helpers/Helpers.svelte.js';
|
|
10
10
|
import type { SelectOption } from '../../../../../Types/Internal/SelectOption.js';
|
|
11
11
|
import { Validity } from '../../../../../Types/Internal/Validity.js';
|
|
12
12
|
import { getContext } from 'svelte';
|
|
@@ -89,7 +89,7 @@ class:bottom={focusDetails.bottomEdge} -->
|
|
|
89
89
|
>
|
|
90
90
|
{#if hasValue}
|
|
91
91
|
{#await visibleValue}
|
|
92
|
-
|
|
92
|
+
{loadingText}
|
|
93
93
|
{:then v}
|
|
94
94
|
{(v instanceof Date
|
|
95
95
|
? v.toLocaleDateString()
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
import type { TableCell } from '../../../Types/Columns/TableCell.js';
|
|
19
19
|
import { TableContext } from '../../../Types/Context/TableContext.svelte.js';
|
|
20
20
|
import { TableFocusDetails } from '../../../Types/Focus/TableFocusDetails.svelte.js';
|
|
21
|
-
import { devCatch, isValidityTuple } from '../../../../../Helpers/Helpers.svelte.js';
|
|
21
|
+
import { devCatch, isValidityTuple, loadingText } from '../../../../../Helpers/Helpers.svelte.js';
|
|
22
22
|
import { InputVariant } from '../../../../../Types/Internal/InputVariant.js';
|
|
23
23
|
import { Validity } from '../../../../../Types/Internal/Validity.js';
|
|
24
24
|
import { getContext, tick, untrack } from 'svelte';
|
|
@@ -38,6 +38,10 @@
|
|
|
38
38
|
});
|
|
39
39
|
let tempNumericValue: number = $state(0);
|
|
40
40
|
|
|
41
|
+
const visibleValue = $derived(
|
|
42
|
+
cell.column.columnDef.getDisplayValue?.(cell.row.original, cell.row.originalIndex) ?? value
|
|
43
|
+
);
|
|
44
|
+
|
|
41
45
|
$effect(() => {
|
|
42
46
|
void value;
|
|
43
47
|
untrack(() => {
|
|
@@ -345,8 +349,8 @@
|
|
|
345
349
|
class:warning={validity == Validity.Warning}
|
|
346
350
|
class:error={validity == Validity.Invalid}
|
|
347
351
|
ondblclick={handleDoubleClickFocus}
|
|
348
|
-
>{#await
|
|
349
|
-
|
|
352
|
+
>{#await visibleValue}
|
|
353
|
+
{loadingText}
|
|
350
354
|
{:then value}{value ?? '-'}{/await}</td
|
|
351
355
|
>
|
|
352
356
|
{/if}
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
import { TableContext } from '../../../Types/Context/TableContext.svelte.js';
|
|
10
10
|
import { TableFocusDetails } from '../../../Types/Focus/TableFocusDetails.svelte.js';
|
|
11
11
|
import TextInput from '../../../../TextInput.svelte';
|
|
12
|
-
import { devCatch, isValidityTuple } from '../../../../../Helpers/Helpers.svelte.js';
|
|
12
|
+
import { devCatch, isValidityTuple, loadingText } from '../../../../../Helpers/Helpers.svelte.js';
|
|
13
13
|
import { InputVariant } from '../../../../../Types/Internal/InputVariant.js';
|
|
14
14
|
import { Validity } from '../../../../../Types/Internal/Validity.js';
|
|
15
15
|
import { getContext, tick, untrack } from 'svelte';
|
|
@@ -53,6 +53,10 @@
|
|
|
53
53
|
|
|
54
54
|
const value = $derived(cell.getValue());
|
|
55
55
|
|
|
56
|
+
const visibleValue = $derived(
|
|
57
|
+
cell.column.columnDef.getDisplayValue?.(cell.row.original, cell.row.originalIndex) ?? value
|
|
58
|
+
);
|
|
59
|
+
|
|
56
60
|
let tempTextValue: string = $state('');
|
|
57
61
|
|
|
58
62
|
let tdref = $state<HTMLTableCellElement | undefined>();
|
|
@@ -347,8 +351,8 @@
|
|
|
347
351
|
}}
|
|
348
352
|
ondblclick={handleDoubleClickFocus}
|
|
349
353
|
>
|
|
350
|
-
{#await
|
|
351
|
-
|
|
354
|
+
{#await visibleValue}
|
|
355
|
+
{loadingText}
|
|
352
356
|
{:then value}
|
|
353
357
|
{value}
|
|
354
358
|
{:catch error}
|
package/dist/index.d.ts
CHANGED
|
@@ -132,7 +132,7 @@ export { TooltipContext } from './Contexts/TooltipContext.svelte.js';
|
|
|
132
132
|
export { UntypedInputContext } from './Contexts/UntypedInputContext.svelte.js';
|
|
133
133
|
export { Delay } from './Delay/Delay.js';
|
|
134
134
|
export { DATAMatrix } from './Helpers/Datamatrix.js';
|
|
135
|
-
export { asyncAll, asyncEvery, asyncFilter, asyncFilterIndices, asyncFlatMap, asyncForEach, asyncMap, asyncSleep, asyncSome, autoPluralise, devCatch, generateShortUUID, generateUUID, getCanvasContext, getErrorMessage, gridItem, isDateTuple, isNumberTuple, isValidEmailAddress, localTimeFormat, passthrough, refWrapper, SQLFriendly, SQLFriendlyWithLocalTime, vowels, } from './Helpers/Helpers.svelte.js';
|
|
135
|
+
export { asyncAll, asyncEvery, asyncFilter, asyncFilterIndices, asyncFlatMap, asyncForEach, asyncMap, asyncSleep, asyncSome, autoPluralise, devCatch, generateShortUUID, generateUUID, getCanvasContext, getErrorMessage, gridItem, isDateTuple, isNumberTuple, isValidEmailAddress, loadingText, localTimeFormat, passthrough, refWrapper, SQLFriendly, SQLFriendlyWithLocalTime, vowels, } from './Helpers/Helpers.svelte.js';
|
|
136
136
|
export { type INamed } from './Helpers/INamed.js';
|
|
137
137
|
export { AttributeOperation } from './Types/Internal/AttributeOperation.js';
|
|
138
138
|
export { type BigRadioOption } from './Types/Internal/BigRadioOption.js';
|
package/dist/index.js
CHANGED
|
@@ -132,7 +132,7 @@ export { TooltipContext } from './Contexts/TooltipContext.svelte.js';
|
|
|
132
132
|
export { UntypedInputContext } from './Contexts/UntypedInputContext.svelte.js';
|
|
133
133
|
export { Delay } from './Delay/Delay.js';
|
|
134
134
|
export { DATAMatrix } from './Helpers/Datamatrix.js';
|
|
135
|
-
export { asyncAll, asyncEvery, asyncFilter, asyncFilterIndices, asyncFlatMap, asyncForEach, asyncMap, asyncSleep, asyncSome, autoPluralise, devCatch, generateShortUUID, generateUUID, getCanvasContext, getErrorMessage, gridItem, isDateTuple, isNumberTuple, isValidEmailAddress, localTimeFormat, passthrough, refWrapper, SQLFriendly, SQLFriendlyWithLocalTime, vowels, } from './Helpers/Helpers.svelte.js';
|
|
135
|
+
export { asyncAll, asyncEvery, asyncFilter, asyncFilterIndices, asyncFlatMap, asyncForEach, asyncMap, asyncSleep, asyncSome, autoPluralise, devCatch, generateShortUUID, generateUUID, getCanvasContext, getErrorMessage, gridItem, isDateTuple, isNumberTuple, isValidEmailAddress, loadingText, localTimeFormat, passthrough, refWrapper, SQLFriendly, SQLFriendlyWithLocalTime, vowels, } from './Helpers/Helpers.svelte.js';
|
|
136
136
|
export {} from './Helpers/INamed.js';
|
|
137
137
|
export { AttributeOperation } from './Types/Internal/AttributeOperation.js';
|
|
138
138
|
export {} from './Types/Internal/BigRadioOption.js';
|