@lavalogic/scoria 0.19.2 → 0.19.4
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/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/TableQuerySelect.svelte +1 -0
- package/dist/Components/Table/Body/Rows/Columns/TableTextInput.svelte +7 -3
- package/dist/Components/Table/Headers/TableHead.svelte +0 -6
- package/dist/Helpers/Helpers.svelte.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
|
|
@@ -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}
|
|
@@ -56,12 +56,6 @@
|
|
|
56
56
|
none: 'sort-none',
|
|
57
57
|
} as const;
|
|
58
58
|
|
|
59
|
-
$effect(() => {
|
|
60
|
-
if (tableContext.debug && !groups.length) {
|
|
61
|
-
$inspect(side, tableContext.table, tableContext.table.columnVisibility);
|
|
62
|
-
}
|
|
63
|
-
});
|
|
64
|
-
|
|
65
59
|
let currentDropTarget: HTMLTableCellElement | null = $state(null);
|
|
66
60
|
|
|
67
61
|
function setCurrentDropTarget(target: EventTarget | null) {
|