@lostgradient/cinder 0.24.4 → 0.24.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/CHANGELOG.md +10 -0
- package/components.json +1 -1
- package/dist/components/json-schema-editor/index.js +2095 -5515
- package/dist/components/json-schema-editor/json-schema-editor-state.svelte.d.ts +1 -0
- package/dist/components/json-schema-editor/json-schema-editor.css +4 -0
- package/dist/components/waveform/index.js +17 -5
- package/dist/components/waveform/waveform.css +27 -0
- package/dist/index.js +344 -312
- package/dist/server/components/json-schema-editor/index.js +2 -10
- package/dist/server/components/waveform/index.js +1 -1
- package/dist/server/index.js +2 -2
- package/dist/server/{index.server-tdrncj5e.js → index.server-qhfya7fx.js} +10 -3
- package/dist/server/{index.server-7h3nmj3g.js → index.server-tb414d8x.js} +62 -58
- package/package.json +2 -1
- package/src/components/json-schema-editor/diff-view.svelte +1 -1
- package/src/components/json-schema-editor/json-schema-editor-impl.svelte +2 -2
- package/src/components/json-schema-editor/json-schema-editor-state.svelte.ts +26 -16
- package/src/components/json-schema-editor/json-schema-editor.css +4 -0
- package/src/components/json-schema-editor/json-schema-toolbar.svelte +2 -2
- package/src/components/json-schema-editor/json-schema-validator.ts +17 -3
- package/src/components/json-schema-editor/property-editor.constants.ts +0 -1
- package/src/components/json-schema-editor/property-editor.svelte +4 -10
- package/src/components/json-schema-editor/property-list.svelte +19 -4
- package/src/components/waveform/waveform.css +27 -0
- package/src/components/waveform/waveform.svelte +28 -15
- package/src/styles/tokens-base.css +3 -3
|
@@ -26,6 +26,7 @@ export declare function createEditorState(options: CreateEditorStateOptions): {
|
|
|
26
26
|
readonly jsonDraftText: string;
|
|
27
27
|
readonly jsonDraftIsDirty: boolean;
|
|
28
28
|
readonly hasChanges: boolean;
|
|
29
|
+
readonly hasDiffChanges: boolean;
|
|
29
30
|
readonly isFormEditable: boolean;
|
|
30
31
|
readonly diffOriginal: string;
|
|
31
32
|
readonly diffCurrent: string;
|
|
@@ -1401,7 +1401,7 @@ var root_3 = $2.from_svg(`<rect class="cinder-waveform__bar" aria-hidden="true">
|
|
|
1401
1401
|
var root_4 = $2.from_svg(`<path class="cinder-waveform__path" aria-hidden="true"></path>`);
|
|
1402
1402
|
var root_5 = $2.from_svg(`<line class="cinder-waveform__baseline" x1="0" aria-hidden="true"></line><!>`, 1);
|
|
1403
1403
|
var root_6 = $2.from_html(`<tr><td> </td><td> </td></tr>`);
|
|
1404
|
-
var root_7 = $2.from_html(`<table><caption> </caption><thead><tr><th scope="col">Sample index</th><th scope="col">Amplitude</th></tr></thead><tbody></tbody></table>`);
|
|
1404
|
+
var root_7 = $2.from_html(`<div><table><caption> </caption><thead><tr><th scope="col">Sample index</th><th scope="col">Amplitude</th></tr></thead><tbody></tbody></table></div>`);
|
|
1405
1405
|
var root_8 = $2.from_html(`<figure><!> <div class="cinder-waveform__viewport"><!> <svg role="img"><!><!></svg></div> <!></figure>`);
|
|
1406
1406
|
function Waveform($$anchor, $$props) {
|
|
1407
1407
|
const generatedId = $2.props_id();
|
|
@@ -1677,7 +1677,16 @@ function Waveform($$anchor, $$props) {
|
|
|
1677
1677
|
var node_10 = $2.sibling(div, 2);
|
|
1678
1678
|
{
|
|
1679
1679
|
var consequent_8 = ($$anchor2) => {
|
|
1680
|
-
var
|
|
1680
|
+
var div_3 = root_7();
|
|
1681
|
+
$2.attribute_effect(div_3, () => ({
|
|
1682
|
+
class: dataTableVisibility() === "screen-reader-only" ? "cinder-sr-only" : "cinder-waveform__table-scroll",
|
|
1683
|
+
...dataTableVisibility() === "visible" ? {
|
|
1684
|
+
role: "region",
|
|
1685
|
+
"aria-label": `${$$props.label} data table`,
|
|
1686
|
+
tabindex: 0
|
|
1687
|
+
} : {}
|
|
1688
|
+
}));
|
|
1689
|
+
var table = $2.child(div_3);
|
|
1681
1690
|
var caption = $2.child(table);
|
|
1682
1691
|
var text_4 = $2.child(caption, true);
|
|
1683
1692
|
$2.reset(caption);
|
|
@@ -1699,11 +1708,14 @@ function Waveform($$anchor, $$props) {
|
|
|
1699
1708
|
});
|
|
1700
1709
|
$2.reset(tbody);
|
|
1701
1710
|
$2.reset(table);
|
|
1711
|
+
$2.reset(div_3);
|
|
1702
1712
|
$2.template_effect(($0) => {
|
|
1703
1713
|
$2.set_class(table, 1, $0);
|
|
1704
1714
|
$2.set_text(text_4, $2.get(tableCaption));
|
|
1705
|
-
}, [
|
|
1706
|
-
|
|
1715
|
+
}, [
|
|
1716
|
+
() => $2.clsx(dataTableClass(dataTableVisibility() === "screen-reader-only" ? "visible" : dataTableVisibility()))
|
|
1717
|
+
]);
|
|
1718
|
+
$2.append($$anchor2, div_3);
|
|
1707
1719
|
};
|
|
1708
1720
|
$2.if(node_10, ($$render) => {
|
|
1709
1721
|
if ($2.get(hasDataTable))
|
|
@@ -1730,4 +1742,4 @@ export {
|
|
|
1730
1742
|
Waveform
|
|
1731
1743
|
};
|
|
1732
1744
|
|
|
1733
|
-
//# debugId=
|
|
1745
|
+
//# debugId=4BFB0486F9E3162264756E2164756E21
|
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
.cinder-waveform {
|
|
4
4
|
display: grid;
|
|
5
5
|
gap: var(--cinder-space-2);
|
|
6
|
+
min-inline-size: 0;
|
|
7
|
+
max-inline-size: 100%;
|
|
6
8
|
color: var(--_cinder-chart-foreground, currentColor);
|
|
7
9
|
background: var(--_cinder-chart-background, transparent);
|
|
8
10
|
}
|
|
@@ -17,6 +19,31 @@
|
|
|
17
19
|
position: relative;
|
|
18
20
|
}
|
|
19
21
|
|
|
22
|
+
.cinder-waveform__table-scroll {
|
|
23
|
+
inline-size: 100%;
|
|
24
|
+
max-inline-size: 100%;
|
|
25
|
+
overflow-x: auto;
|
|
26
|
+
overscroll-behavior-inline: contain;
|
|
27
|
+
-webkit-overflow-scrolling: touch;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.cinder-waveform__table-scroll > table {
|
|
31
|
+
min-inline-size: max-content;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.cinder-waveform__table-scroll:focus-visible {
|
|
35
|
+
outline: var(--cinder-ring-width) solid transparent;
|
|
36
|
+
box-shadow: var(--_cinder-focus-ring-shadow);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
@media (forced-colors: active) {
|
|
40
|
+
.cinder-waveform__table-scroll:focus-visible {
|
|
41
|
+
outline: var(--cinder-ring-width) solid ButtonText;
|
|
42
|
+
outline-offset: 2px;
|
|
43
|
+
box-shadow: none;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
20
47
|
.cinder-waveform svg {
|
|
21
48
|
display: block;
|
|
22
49
|
inline-size: 100%;
|