@chocbite/ts-lib-ui 1.0.6 → 1.1.1
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/AGENTS.md +172 -3
- package/SOURCE.md +2161 -273
- package/base/index.mjs +7 -7
- package/base/index.mjs.map +1 -1
- package/canvas/index.mjs +8 -8
- package/canvas/index.mjs.map +1 -1
- package/context-menu/index.d.mts +2 -2
- package/context-menu/index.mjs +1 -1
- package/{context-menu-Bo8R6DmK.mjs → context-menu-hHRJ33Lu.mjs} +149 -111
- package/context-menu-hHRJ33Lu.mjs.map +1 -0
- package/document/index.mjs +1 -1
- package/document/index.mjs.map +1 -1
- package/dom/index.mjs +1 -1
- package/dom/index.mjs.map +1 -1
- package/form/index.d.mts +4 -3
- package/form/index.mjs +30 -29
- package/form/index.mjs.map +1 -1
- package/icons/index.mjs +1 -1
- package/{icons-e2J_Ojic.mjs → icons-B88i-7MC.mjs} +2 -2
- package/{index-Pr2sLv9e.d.mts → index-76zZKjTH.d.mts} +32 -16
- package/index-D6L_jK1x.d.mts +385 -0
- package/keyboard/index.mjs +12 -12
- package/keyboard/index.mjs.map +1 -1
- package/list/index.d.mts +2 -2
- package/list/index.mjs +1 -1
- package/list-Bic1UzeC.mjs +1640 -0
- package/list-Bic1UzeC.mjs.map +1 -0
- package/package.json +5 -80
- package/selection/index.mjs +1 -1
- package/selection/index.mjs.map +1 -1
- package/settings/index.mjs +1 -1
- package/settings/index.mjs.map +1 -1
- package/spinner/index.mjs +3 -3
- package/spinner/index.mjs.map +1 -1
- package/state_ui/index.mjs +1 -1
- package/{state_ui-Bm3TeKNL.mjs → state_ui-Dtm2y5RU.mjs} +3 -3
- package/state_ui-Dtm2y5RU.mjs.map +1 -0
- package/style.css +349 -63
- package/svg/index.mjs +1 -1
- package/{svg-1bp-yIPC.mjs → svg-Yz7elqnU.mjs} +16 -16
- package/svg-Yz7elqnU.mjs.map +1 -0
- package/test/index.mjs +1 -1
- package/test/index.mjs.map +1 -1
- package/theme/index.mjs +1 -1
- package/{theme-DgVtLDzP.mjs → theme-DilOXXDu.mjs} +9 -9
- package/theme-DilOXXDu.mjs.map +1 -0
- package/context-menu-Bo8R6DmK.mjs.map +0 -1
- package/index-BTUFkF9s.d.mts +0 -173
- package/list-DOXIQOEY.mjs +0 -715
- package/list-DOXIQOEY.mjs.map +0 -1
- package/state_ui-Bm3TeKNL.mjs.map +0 -1
- package/svg-1bp-yIPC.mjs.map +0 -1
- package/theme-DgVtLDzP.mjs.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "./style.css";
|
|
2
2
|
import state from "@chocbite/ts-lib/state";
|
|
3
|
-
//
|
|
3
|
+
// state_ui/array.ts
|
|
4
4
|
/**Applies an array to the child nodes of a parent, one node per value.
|
|
5
5
|
* Arrays from array states carry what changed, so only the changed nodes are touched,
|
|
6
6
|
* a plain array is applied as a whole, reusing existing nodes when update is given.
|
|
@@ -74,7 +74,7 @@ const ARRAY_UI = {
|
|
|
74
74
|
* @param array new value of the array
|
|
75
75
|
* @param handlers make, update and remove the nodes*/
|
|
76
76
|
apply };
|
|
77
|
-
//
|
|
77
|
+
// state_ui/index.ts
|
|
78
78
|
/**Shows states of @chocbite/ts-lib/state in the document*/
|
|
79
79
|
const state_ui = {
|
|
80
80
|
/**Array states, applies arrays to child nodes*/
|
|
@@ -84,4 +84,4 @@ const state_ui = {
|
|
|
84
84
|
};
|
|
85
85
|
export { state_ui as t };
|
|
86
86
|
|
|
87
|
-
//# sourceMappingURL=state_ui-
|
|
87
|
+
//# sourceMappingURL=state_ui-Dtm2y5RU.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"state_ui-Dtm2y5RU.mjs","names":[],"sources":["../../package-ui/state_ui/array.ts","../../package-ui/state_ui/index.ts"],"sourcesContent":["import state from \"@chocbite/ts-lib/state\";\n\n/**How the nodes for the values of an array are made, updated and removed*/\nexport interface StateUIArrayApplyHandlers<T, N extends ChildNode> {\n /**Gives the node for a value*/\n create: (value: T) => N;\n /**Updates a node to a new value, when given nodes are reused, otherwise nodes of changed values are replaced*/\n update?: (node: N, value: T) => void;\n /**Called for every node that is removed or replaced*/\n destroy?: (node: N) => void;\n}\n\n/**Applies an array to the child nodes of a parent, one node per value.\n * Arrays from array states carry what changed, so only the changed nodes are touched,\n * a plain array is applied as a whole, reusing existing nodes when update is given.\n * @param parent node holding the nodes for the array, it must contain nothing else\n * @param array new value of the array\n * @param handlers make, update and remove the nodes*/\nfunction apply<T, N extends ChildNode>(\n parent: ParentNode,\n array: readonly T[],\n handlers: StateUIArrayApplyHandlers<T, N>,\n): void {\n const { create, update, destroy } = handlers;\n //Live list, it follows every change made below\n const nodes = parent.childNodes as NodeListOf<N>;\n const remove = (node: N) => {\n destroy?.(node);\n node.remove();\n };\n for (const change of state.a.read(array)) {\n switch (change.type) {\n case \"fresh\": {\n if (update) {\n const reused = Math.min(nodes.length, change.items.length);\n for (let i = 0; i < reused; i++) update(nodes[i], change.items[i]);\n while (nodes.length > change.items.length)\n remove(nodes[nodes.length - 1]);\n parent.append(...change.items.slice(reused).map((v) => create(v)));\n } else {\n if (destroy) for (const node of [...nodes]) destroy(node);\n parent.replaceChildren(...change.items.map((v) => create(v)));\n }\n break;\n }\n case \"added\": {\n const created = change.items.map((v) => create(v));\n const next = nodes[change.index];\n if (next) next.before(...created);\n else parent.append(...created);\n break;\n }\n case \"removed\":\n for (let i = 0; i < change.items.length; i++) {\n const node = nodes[change.index];\n if (node) remove(node);\n }\n break;\n case \"changed\":\n for (let i = 0; i < change.items.length; i++) {\n const node = nodes[change.index + i];\n if (!node) continue;\n if (update) update(node, change.items[i]);\n else {\n destroy?.(node);\n node.replaceWith(create(change.items[i]));\n }\n }\n break;\n case \"moved\": {\n const moved: N[] = [];\n //Every removal moves the next node to from_index\n for (let i = 0; i < change.items.length; i++) {\n const node = nodes[change.from_index];\n if (!node) break;\n moved.push(node);\n node.remove();\n }\n const next = nodes[change.to_index];\n if (next) next.before(...moved);\n else parent.append(...moved);\n break;\n }\n }\n }\n}\n\n/**Array states shown in the document*/\nexport const ARRAY_UI = {\n /**Applies an array to the child nodes of a parent, one node per value.\n * Arrays from array states carry what changed, so only the changed nodes are touched,\n * a plain array is applied as a whole, reusing existing nodes when update is given.\n * @param parent node holding the nodes for the array, it must contain nothing else\n * @param array new value of the array\n * @param handlers make, update and remove the nodes*/\n apply,\n};\n","import { ARRAY_UI } from \"./array\";\n\n/**Shows states of @chocbite/ts-lib/state in the document*/\nexport const state_ui = {\n //The \"as typeof\" casts make the declaration output reference the helper objects instead of inlining\n //their types, inlining would drop the doc comments on their members\n /* eslint-disable @typescript-eslint/no-unnecessary-type-assertion */\n /**Array states, applies arrays to child nodes*/\n a: ARRAY_UI as typeof ARRAY_UI,\n /**Array states, applies arrays to child nodes*/\n array: ARRAY_UI as typeof ARRAY_UI,\n /* eslint-enable @typescript-eslint/no-unnecessary-type-assertion */\n};\nexport default state_ui;\n\nexport type { StateUIArrayApplyHandlers } from \"./array\";\n"],"mappings":";;;;;;;;;AAkBA,SAAS,MACP,QACA,OACA,UACM;CACN,MAAM,EAAE,QAAQ,QAAQ,YAAY;CAEpC,MAAM,QAAQ,OAAO;CACrB,MAAM,UAAU,SAAY;EAC1B,UAAU,IAAI;EACd,KAAK,OAAO;CACd;CACA,KAAK,MAAM,UAAU,MAAM,EAAE,KAAK,KAAK,GACrC,QAAQ,OAAO,MAAf;EACE,KAAK;GACH,IAAI,QAAQ;IACV,MAAM,SAAS,KAAK,IAAI,MAAM,QAAQ,OAAO,MAAM,MAAM;IACzD,KAAK,IAAI,IAAI,GAAG,IAAI,QAAQ,KAAK,OAAO,MAAM,IAAI,OAAO,MAAM,EAAE;IACjE,OAAO,MAAM,SAAS,OAAO,MAAM,QACjC,OAAO,MAAM,MAAM,SAAS,EAAE;IAChC,OAAO,OAAO,GAAG,OAAO,MAAM,MAAM,MAAM,CAAC,CAAC,KAAK,MAAM,OAAO,CAAC,CAAC,CAAC;GACnE,OAAO;IACL,IAAI,SAAS,KAAK,MAAM,QAAQ,CAAC,GAAG,KAAK,GAAG,QAAQ,IAAI;IACxD,OAAO,gBAAgB,GAAG,OAAO,MAAM,KAAK,MAAM,OAAO,CAAC,CAAC,CAAC;GAC9D;GACA;EAEF,KAAK,SAAS;GACZ,MAAM,UAAU,OAAO,MAAM,KAAK,MAAM,OAAO,CAAC,CAAC;GACjD,MAAM,OAAO,MAAM,OAAO;GAC1B,IAAI,MAAM,KAAK,OAAO,GAAG,OAAO;QAC3B,OAAO,OAAO,GAAG,OAAO;GAC7B;EACF;EACA,KAAK;GACH,KAAK,IAAI,IAAI,GAAG,IAAI,OAAO,MAAM,QAAQ,KAAK;IAC5C,MAAM,OAAO,MAAM,OAAO;IAC1B,IAAI,MAAM,OAAO,IAAI;GACvB;GACA;EACF,KAAK;GACH,KAAK,IAAI,IAAI,GAAG,IAAI,OAAO,MAAM,QAAQ,KAAK;IAC5C,MAAM,OAAO,MAAM,OAAO,QAAQ;IAClC,IAAI,CAAC,MAAM;IACX,IAAI,QAAQ,OAAO,MAAM,OAAO,MAAM,EAAE;SACnC;KACH,UAAU,IAAI;KACd,KAAK,YAAY,OAAO,OAAO,MAAM,EAAE,CAAC;IAC1C;GACF;GACA;EACF,KAAK,SAAS;GACZ,MAAM,QAAa,CAAC;GAEpB,KAAK,IAAI,IAAI,GAAG,IAAI,OAAO,MAAM,QAAQ,KAAK;IAC5C,MAAM,OAAO,MAAM,OAAO;IAC1B,IAAI,CAAC,MAAM;IACX,MAAM,KAAK,IAAI;IACf,KAAK,OAAO;GACd;GACA,MAAM,OAAO,MAAM,OAAO;GAC1B,IAAI,MAAM,KAAK,OAAO,GAAG,KAAK;QACzB,OAAO,OAAO,GAAG,KAAK;GAC3B;EACF;CACF;AAEJ;;AAGA,MAAa,WAAW;;;;;;;AAOtB,MACF;;;AC7FA,MAAa,WAAW;;CAKtB,GAAG;;CAEH,OAAO;AAET"}
|
package/style.css
CHANGED
|
@@ -2697,20 +2697,6 @@ contextmenu-option .shortcut {
|
|
|
2697
2697
|
contextmenu-option .checkmark {
|
|
2698
2698
|
text-align: center;
|
|
2699
2699
|
}
|
|
2700
|
-
contextmenu-container {
|
|
2701
|
-
display: block;
|
|
2702
|
-
z-index: 999999999;
|
|
2703
|
-
position: fixed;
|
|
2704
|
-
pointer-events: none;
|
|
2705
|
-
touch-action: none;
|
|
2706
|
-
top: 0;
|
|
2707
|
-
left: 0;
|
|
2708
|
-
width: 100vw;
|
|
2709
|
-
height: 100vh;
|
|
2710
|
-
}
|
|
2711
|
-
html {
|
|
2712
|
-
overflow: auto;
|
|
2713
|
-
}
|
|
2714
2700
|
contextmenu-buffer {
|
|
2715
2701
|
display: table-row;
|
|
2716
2702
|
height: 1.8rem;
|
|
@@ -2761,6 +2747,17 @@ contextmenu-buffer > * {
|
|
|
2761
2747
|
contextmenu-buffer > * > svg {
|
|
2762
2748
|
fill: var(--contextmenu-hoverText);
|
|
2763
2749
|
}
|
|
2750
|
+
contextmenu-container {
|
|
2751
|
+
display: block;
|
|
2752
|
+
z-index: 999999999;
|
|
2753
|
+
position: fixed;
|
|
2754
|
+
pointer-events: none;
|
|
2755
|
+
touch-action: none;
|
|
2756
|
+
top: 0;
|
|
2757
|
+
left: 0;
|
|
2758
|
+
width: 100vw;
|
|
2759
|
+
height: 100vh;
|
|
2760
|
+
}
|
|
2764
2761
|
contextmenu-menu {
|
|
2765
2762
|
display: block;
|
|
2766
2763
|
position: fixed;
|
|
@@ -2901,21 +2898,19 @@ contextmenu-submenu .chevron > svg {
|
|
|
2901
2898
|
.touch contextmenu-submenu .chevron > svg {
|
|
2902
2899
|
width: 2.6rem;
|
|
2903
2900
|
}
|
|
2901
|
+
html {
|
|
2902
|
+
overflow: auto;
|
|
2903
|
+
}
|
|
2904
2904
|
list-addrow {
|
|
2905
2905
|
display: contents;
|
|
2906
2906
|
}
|
|
2907
|
-
list-addrow[inert]
|
|
2907
|
+
list-addrow[inert] span.add {
|
|
2908
2908
|
opacity: 0.6;
|
|
2909
2909
|
pointer-events: none;
|
|
2910
2910
|
}
|
|
2911
|
-
list-addrow
|
|
2911
|
+
list-addrow span.add {
|
|
2912
2912
|
color: var(--list-colors-text-add);
|
|
2913
2913
|
grid-column: 1/-1;
|
|
2914
|
-
}
|
|
2915
|
-
list-container > div.sub-rows list-addrow > span {
|
|
2916
|
-
grid-column: 2/-1;
|
|
2917
|
-
}
|
|
2918
|
-
list-addrow > span {
|
|
2919
2914
|
display: flex;
|
|
2920
2915
|
align-items: center;
|
|
2921
2916
|
justify-content: center;
|
|
@@ -2929,19 +2924,19 @@ list-addrow > span {
|
|
|
2929
2924
|
min-height: var(--list-size-add_min);
|
|
2930
2925
|
outline: none;
|
|
2931
2926
|
}
|
|
2932
|
-
.touch list-addrow
|
|
2927
|
+
.touch list-addrow span.add {
|
|
2933
2928
|
min-height: var(--list-size-touch_add_min);
|
|
2934
2929
|
}
|
|
2935
|
-
list-addrow
|
|
2930
|
+
list-addrow span.add:focus-visible {
|
|
2936
2931
|
outline: 2px solid var(--list-colors-focus-normal);
|
|
2937
2932
|
}
|
|
2938
|
-
list-addrow
|
|
2933
|
+
list-addrow span.add:hover {
|
|
2939
2934
|
background-color: var(--list-colors-background-row_hover);
|
|
2940
2935
|
}
|
|
2941
|
-
list-addrow
|
|
2936
|
+
list-addrow span.add:active {
|
|
2942
2937
|
box-shadow: 0 0rem 0.2rem 0rem var(--list-colors-border-header);
|
|
2943
2938
|
}
|
|
2944
|
-
list-addrow
|
|
2939
|
+
list-addrow span.add svg {
|
|
2945
2940
|
fill: var(--list-colors-icon-add_icon);
|
|
2946
2941
|
height: 1.2em;
|
|
2947
2942
|
width: auto;
|
|
@@ -2949,11 +2944,35 @@ list-addrow > span svg {
|
|
|
2949
2944
|
}
|
|
2950
2945
|
list-keyfield {
|
|
2951
2946
|
--list-row-size: var(--list-size-row_min);
|
|
2947
|
+
--list-key-indent: calc(var(--list-row-size) / 2);
|
|
2948
|
+
--list-key-indent-space: calc(var(--list-row-size) / 2 - 0.1rem);
|
|
2949
|
+
--list-key-opener: var(--list-row-size);
|
|
2950
|
+
--list-key-icon: calc(var(--list-row-size) - 0.4rem);
|
|
2952
2951
|
}
|
|
2953
2952
|
.touch list-keyfield {
|
|
2954
2953
|
--list-row-size: var(--list-size-touch_row_min);
|
|
2954
|
+
--list-key-indent: calc(var(--list-row-size) / 2 - 0.3rem + 1.5px);
|
|
2955
|
+
--list-key-indent-space: calc(var(--list-row-size) / 2 - 0.4rem);
|
|
2956
|
+
--list-key-opener: calc(var(--list-row-size) - 0.4rem);
|
|
2957
|
+
--list-key-icon: calc(var(--list-row-size) - 1.1rem);
|
|
2955
2958
|
}
|
|
2956
2959
|
list-keyfield {
|
|
2960
|
+
--list-key-min-icon: 0px;
|
|
2961
|
+
--list-key-min-text: 0px;
|
|
2962
|
+
}
|
|
2963
|
+
list-keyfield.has-icon {
|
|
2964
|
+
--list-key-min-icon: calc(var(--list-key-icon) + 0.5rem);
|
|
2965
|
+
}
|
|
2966
|
+
list-keyfield.has-text, list-keyfield.tail {
|
|
2967
|
+
--list-key-min-text: 4rem;
|
|
2968
|
+
}
|
|
2969
|
+
list-keyfield {
|
|
2970
|
+
--list-key-min: calc(
|
|
2971
|
+
var(--list-key-depth) *
|
|
2972
|
+
(var(--list-key-indent) + 1px + var(--list-key-indent-space)) +
|
|
2973
|
+
var(--list-key-opener) + var(--list-key-min-icon) +
|
|
2974
|
+
var(--list-key-min-text) + 1px
|
|
2975
|
+
);
|
|
2957
2976
|
position: sticky;
|
|
2958
2977
|
left: 0;
|
|
2959
2978
|
display: flex;
|
|
@@ -2963,7 +2982,7 @@ list-keyfield {
|
|
|
2963
2982
|
border-right: 1px solid var(--list-colors-border-column);
|
|
2964
2983
|
background-color: var(--list-colors-background-row_odd);
|
|
2965
2984
|
}
|
|
2966
|
-
list-keyfield:focus-visible::before {
|
|
2985
|
+
list-keyfield:focus-visible:not(.click-focus)::before {
|
|
2967
2986
|
content: "";
|
|
2968
2987
|
position: absolute;
|
|
2969
2988
|
width: 100%;
|
|
@@ -2973,34 +2992,35 @@ list-keyfield:focus-visible::before {
|
|
|
2973
2992
|
z-index: 1;
|
|
2974
2993
|
pointer-events: none;
|
|
2975
2994
|
}
|
|
2995
|
+
list-row.open > div > list-keyfield {
|
|
2996
|
+
background-image: linear-gradient(var(--list-colors-border-column), var(--list-colors-border-column));
|
|
2997
|
+
background-repeat: no-repeat;
|
|
2998
|
+
background-size: 1px 50%;
|
|
2999
|
+
background-position: calc((var(--list-key-depth) + 1) * (var(--list-key-indent) + 1px + var(--list-key-indent-space)) + var(--list-key-opener) / 2) 100%;
|
|
3000
|
+
}
|
|
2976
3001
|
list-keyfield > div {
|
|
2977
|
-
|
|
2978
|
-
|
|
3002
|
+
flex-shrink: 0;
|
|
3003
|
+
width: var(--list-key-indent);
|
|
3004
|
+
margin-right: var(--list-key-indent-space);
|
|
2979
3005
|
height: 100%;
|
|
2980
3006
|
position: relative;
|
|
2981
3007
|
border-right: 1px solid;
|
|
2982
3008
|
}
|
|
2983
|
-
|
|
2984
|
-
width: calc(var(--list-row-size) / 2 - 0.3rem + 1.5px);
|
|
2985
|
-
margin-right: calc(var(--list-row-size) / 2 - 0.4rem);
|
|
2986
|
-
}
|
|
2987
|
-
list-keyfield.openable > span > div {
|
|
3009
|
+
list-keyfield.openable > span.opener > div {
|
|
2988
3010
|
display: block;
|
|
2989
3011
|
}
|
|
2990
|
-
list-keyfield > span {
|
|
3012
|
+
list-keyfield > span.opener {
|
|
2991
3013
|
position: relative;
|
|
3014
|
+
flex-shrink: 0;
|
|
2992
3015
|
display: flex;
|
|
2993
3016
|
align-items: center;
|
|
2994
3017
|
justify-content: flex-start;
|
|
2995
3018
|
height: 100%;
|
|
2996
3019
|
min-height: var(--list-row-size);
|
|
2997
3020
|
background-color: inherit;
|
|
2998
|
-
width: var(--list-
|
|
3021
|
+
width: var(--list-key-opener);
|
|
2999
3022
|
}
|
|
3000
|
-
|
|
3001
|
-
width: calc(var(--list-row-size) - 0.4rem);
|
|
3002
|
-
}
|
|
3003
|
-
list-keyfield > span::before {
|
|
3023
|
+
list-keyfield > span.opener::before {
|
|
3004
3024
|
content: "";
|
|
3005
3025
|
display: block;
|
|
3006
3026
|
position: absolute;
|
|
@@ -3010,20 +3030,20 @@ list-keyfield > span::before {
|
|
|
3010
3030
|
top: 0;
|
|
3011
3031
|
border-right: 1px solid var(--list-colors-border-column);
|
|
3012
3032
|
}
|
|
3013
|
-
list-addrow > list-keyfield > span::before, list-rowserror > list-keyfield > span::before, list-row:not(.addrow) > span > list-row:last-child >
|
|
3014
|
-
height:
|
|
3033
|
+
list-addrow > list-keyfield > span.opener::before, div:not(.addrow) > list-rowserror > list-keyfield > span.opener::before, list-row:not(.addrow) > list-rowserror > list-keyfield > span.opener::before, list-row:not(.addrow) > span > list-row:last-child > div > list-keyfield > span.opener::before, div:not(.addrow) > div > list-row:last-child > div > list-keyfield > span.opener::before {
|
|
3034
|
+
height: 50%;
|
|
3015
3035
|
}
|
|
3016
|
-
list-keyfield > span::after {
|
|
3036
|
+
list-keyfield > span.opener::after {
|
|
3017
3037
|
content: "";
|
|
3018
3038
|
display: block;
|
|
3019
3039
|
position: absolute;
|
|
3020
|
-
height:
|
|
3040
|
+
height: 50%;
|
|
3021
3041
|
width: 50%;
|
|
3022
3042
|
top: 0;
|
|
3023
3043
|
left: 50%;
|
|
3024
3044
|
border-bottom: 1px solid var(--list-colors-border-column);
|
|
3025
3045
|
}
|
|
3026
|
-
list-keyfield > span > div {
|
|
3046
|
+
list-keyfield > span.opener > div {
|
|
3027
3047
|
font-family: "Material Symbols Rounded";
|
|
3028
3048
|
font-weight: normal;
|
|
3029
3049
|
font-style: normal;
|
|
@@ -3043,18 +3063,18 @@ list-keyfield > span > div {
|
|
|
3043
3063
|
z-index: 1;
|
|
3044
3064
|
background-color: inherit;
|
|
3045
3065
|
}
|
|
3046
|
-
.touch list-keyfield > span > div {
|
|
3066
|
+
.touch list-keyfield > span.opener > div {
|
|
3047
3067
|
height: calc(var(--list-row-size) - 1.2rem);
|
|
3048
3068
|
width: calc(var(--list-row-size) - 1.4rem);
|
|
3049
3069
|
margin-left: 0.6rem;
|
|
3050
3070
|
}
|
|
3051
|
-
list-row.open > * > list-keyfield > span > div::before {
|
|
3071
|
+
list-row.open > * > list-keyfield > span.opener > div::before {
|
|
3052
3072
|
content: "\e313";
|
|
3053
3073
|
}
|
|
3054
|
-
list-keyfield > span > div:hover::before {
|
|
3074
|
+
list-keyfield > span.opener > div:hover::before {
|
|
3055
3075
|
background-color: var(--list-colors-focus-normal);
|
|
3056
3076
|
}
|
|
3057
|
-
list-keyfield > span > div::before {
|
|
3077
|
+
list-keyfield > span.opener > div::before {
|
|
3058
3078
|
font-family: "Material Symbols Rounded";
|
|
3059
3079
|
font-weight: normal;
|
|
3060
3080
|
font-style: normal;
|
|
@@ -3076,27 +3096,121 @@ list-keyfield > span > div::before {
|
|
|
3076
3096
|
font-size: 1.2rem;
|
|
3077
3097
|
line-height: 0rem;
|
|
3078
3098
|
}
|
|
3079
|
-
.touch list-keyfield > span > div::before {
|
|
3099
|
+
.touch list-keyfield > span.opener > div::before {
|
|
3080
3100
|
inset: -0.4rem;
|
|
3081
3101
|
font-size: 2rem;
|
|
3082
3102
|
}
|
|
3083
|
-
list-keyfield
|
|
3103
|
+
list-keyfield > span.text {
|
|
3104
|
+
display: flex;
|
|
3105
|
+
align-self: center;
|
|
3106
|
+
align-items: center;
|
|
3107
|
+
min-width: 0;
|
|
3108
|
+
color: var(--list-colors-text-key_field);
|
|
3109
|
+
padding: 0 0.25rem;
|
|
3110
|
+
min-height: var(--list-row-size);
|
|
3111
|
+
background-color: inherit;
|
|
3112
|
+
}
|
|
3113
|
+
list-keyfield > svg {
|
|
3084
3114
|
position: relative;
|
|
3115
|
+
flex-shrink: 0;
|
|
3116
|
+
align-self: center;
|
|
3117
|
+
background-color: inherit;
|
|
3085
3118
|
fill: var(--list-colors-icon-key_icon);
|
|
3086
3119
|
padding: 0.25rem;
|
|
3087
|
-
width:
|
|
3120
|
+
width: var(--list-key-icon);
|
|
3088
3121
|
height: auto;
|
|
3089
3122
|
}
|
|
3090
|
-
|
|
3091
|
-
|
|
3092
|
-
|
|
3123
|
+
list-keyfield.tail {
|
|
3124
|
+
grid-column: 1/-1;
|
|
3125
|
+
border-right: none;
|
|
3126
|
+
}
|
|
3127
|
+
list-keyfield.tail > :last-child {
|
|
3128
|
+
flex-grow: 1;
|
|
3129
|
+
}
|
|
3130
|
+
list-keyfield.tail::after {
|
|
3131
|
+
display: none;
|
|
3093
3132
|
}
|
|
3094
3133
|
list-keyfield::after {
|
|
3095
3134
|
content: "";
|
|
3135
|
+
align-self: flex-start;
|
|
3096
3136
|
height: 50%;
|
|
3097
3137
|
border-bottom: 1px solid var(--list-colors-border-column);
|
|
3098
3138
|
flex-grow: 1;
|
|
3099
|
-
|
|
3139
|
+
}
|
|
3140
|
+
list-dragfield {
|
|
3141
|
+
position: sticky;
|
|
3142
|
+
left: 0;
|
|
3143
|
+
z-index: 2;
|
|
3144
|
+
display: flex;
|
|
3145
|
+
align-items: center;
|
|
3146
|
+
justify-content: center;
|
|
3147
|
+
box-sizing: border-box;
|
|
3148
|
+
min-height: var(--list-drag-width);
|
|
3149
|
+
user-select: none;
|
|
3150
|
+
touch-action: none;
|
|
3151
|
+
border-right: 1px solid var(--list-colors-border-column);
|
|
3152
|
+
}
|
|
3153
|
+
list-dragfield::before {
|
|
3154
|
+
font-family: "Material Symbols Rounded";
|
|
3155
|
+
font-weight: normal;
|
|
3156
|
+
font-style: normal;
|
|
3157
|
+
letter-spacing: normal;
|
|
3158
|
+
text-transform: none;
|
|
3159
|
+
white-space: nowrap;
|
|
3160
|
+
word-wrap: normal;
|
|
3161
|
+
direction: ltr;
|
|
3162
|
+
-webkit-font-feature-settings: "liga";
|
|
3163
|
+
-webkit-font-smoothing: antialiased;
|
|
3164
|
+
font-size: 1.2rem;
|
|
3165
|
+
line-height: 1;
|
|
3166
|
+
color: var(--list-colors-icon-drag);
|
|
3167
|
+
}
|
|
3168
|
+
.touch list-dragfield::before {
|
|
3169
|
+
font-size: 1.8rem;
|
|
3170
|
+
}
|
|
3171
|
+
list-row.movable > div > list-dragfield {
|
|
3172
|
+
cursor: grab;
|
|
3173
|
+
}
|
|
3174
|
+
list-row.movable > div > list-dragfield::before {
|
|
3175
|
+
content: "\e945";
|
|
3176
|
+
}
|
|
3177
|
+
|
|
3178
|
+
list-row.dragging > div > * {
|
|
3179
|
+
opacity: 0.4;
|
|
3180
|
+
}
|
|
3181
|
+
|
|
3182
|
+
list-container > span.list-drop {
|
|
3183
|
+
display: block;
|
|
3184
|
+
position: absolute;
|
|
3185
|
+
z-index: 998;
|
|
3186
|
+
pointer-events: none;
|
|
3187
|
+
box-sizing: border-box;
|
|
3188
|
+
background-color: var(--list-colors-focus-normal);
|
|
3189
|
+
}
|
|
3190
|
+
list-container > span.list-drop[hidden] {
|
|
3191
|
+
display: none;
|
|
3192
|
+
}
|
|
3193
|
+
list-container > span.list-drop.into {
|
|
3194
|
+
background-color: transparent;
|
|
3195
|
+
border: 2px solid var(--list-colors-focus-normal);
|
|
3196
|
+
}
|
|
3197
|
+
|
|
3198
|
+
span.list-drag-label {
|
|
3199
|
+
display: block;
|
|
3200
|
+
position: fixed;
|
|
3201
|
+
z-index: 10000;
|
|
3202
|
+
pointer-events: none;
|
|
3203
|
+
padding: 0.2rem 0.5rem;
|
|
3204
|
+
border-radius: 0.3rem;
|
|
3205
|
+
font-size: 0.9rem;
|
|
3206
|
+
white-space: nowrap;
|
|
3207
|
+
color: var(--list-colors-text-field);
|
|
3208
|
+
background-color: var(--list-colors-background-row_even);
|
|
3209
|
+
border: 1px solid var(--list-colors-border-header);
|
|
3210
|
+
box-shadow: 0 0.1rem 0.3rem var(--list-colors-border-header);
|
|
3211
|
+
}
|
|
3212
|
+
span.list-drag-label.none {
|
|
3213
|
+
opacity: 0.5;
|
|
3100
3214
|
}
|
|
3101
3215
|
list-container {
|
|
3102
3216
|
position: relative;
|
|
@@ -3120,8 +3234,6 @@ list-container > div > list-headerrow > * {
|
|
|
3120
3234
|
}
|
|
3121
3235
|
list-container > div > list-headerrow > *:first-child {
|
|
3122
3236
|
left: 0;
|
|
3123
|
-
z-index: 3;
|
|
3124
|
-
border-right: 1px solid var(--list-colors-border-column);
|
|
3125
3237
|
}
|
|
3126
3238
|
list-container > div > list-headerrow > list-headerfield {
|
|
3127
3239
|
box-sizing: border-box;
|
|
@@ -3163,8 +3275,9 @@ list-container > div > list-headerrow > list-headerfield > div > div {
|
|
|
3163
3275
|
cursor: ew-resize;
|
|
3164
3276
|
justify-content: center;
|
|
3165
3277
|
align-items: center;
|
|
3278
|
+
touch-action: none;
|
|
3166
3279
|
}
|
|
3167
|
-
list-container > div > list-headerrow > list-headerfield > div > div:hover {
|
|
3280
|
+
list-container > div > list-headerrow > list-headerfield > div > div:hover, list-container > div > list-headerrow > list-headerfield > div > div.active {
|
|
3168
3281
|
background-color: var(--list-colors-background-row_hover);
|
|
3169
3282
|
}
|
|
3170
3283
|
list-container > div > list-headerrow > list-headerfield > div > div::after {
|
|
@@ -3173,13 +3286,124 @@ list-container > div > list-headerrow > list-headerfield > div > div::after {
|
|
|
3173
3286
|
height: 80%;
|
|
3174
3287
|
background-color: var(--list-colors-border-column);
|
|
3175
3288
|
}
|
|
3289
|
+
list-container > div > list-headerrow > list-headerfield > div > div.active::after {
|
|
3290
|
+
background-color: var(--list-colors-focus-normal);
|
|
3291
|
+
}
|
|
3292
|
+
.touch list-container > div > list-headerrow > list-headerfield > div > div {
|
|
3293
|
+
width: 1.5rem;
|
|
3294
|
+
}
|
|
3295
|
+
.touch list-container > div > list-headerrow > list-headerfield > div > div::after {
|
|
3296
|
+
width: 3px;
|
|
3297
|
+
height: 60%;
|
|
3298
|
+
transform: translateX(-0.2rem);
|
|
3299
|
+
box-shadow: 0.4rem 0 0 var(--list-colors-border-column);
|
|
3300
|
+
}
|
|
3301
|
+
.touch list-container > div > list-headerrow > list-headerfield > div > div.active::after {
|
|
3302
|
+
box-shadow: 0.4rem 0 0 var(--list-colors-focus-normal);
|
|
3303
|
+
}
|
|
3176
3304
|
list-container > div > div {
|
|
3177
3305
|
display: contents;
|
|
3178
3306
|
}
|
|
3307
|
+
|
|
3308
|
+
list-container > div > list-headerrow > .key > div > span {
|
|
3309
|
+
justify-content: flex-start;
|
|
3310
|
+
}
|
|
3311
|
+
list-container > div > list-headerrow > .key > div > span > span {
|
|
3312
|
+
font-family: "Material Symbols Rounded";
|
|
3313
|
+
font-weight: normal;
|
|
3314
|
+
font-style: normal;
|
|
3315
|
+
letter-spacing: normal;
|
|
3316
|
+
text-transform: none;
|
|
3317
|
+
white-space: nowrap;
|
|
3318
|
+
word-wrap: normal;
|
|
3319
|
+
direction: ltr;
|
|
3320
|
+
-webkit-font-feature-settings: "liga";
|
|
3321
|
+
-webkit-font-smoothing: antialiased;
|
|
3322
|
+
display: flex;
|
|
3323
|
+
align-items: center;
|
|
3324
|
+
justify-content: center;
|
|
3325
|
+
flex-shrink: 0;
|
|
3326
|
+
width: var(--list-size-row_min);
|
|
3327
|
+
height: var(--list-size-row_min);
|
|
3328
|
+
border-radius: 0.2rem;
|
|
3329
|
+
font-size: 1.2rem;
|
|
3330
|
+
cursor: pointer;
|
|
3331
|
+
color: var(--list-colors-icon-sub_opener);
|
|
3332
|
+
}
|
|
3333
|
+
.touch list-container > div > list-headerrow > .key > div > span > span {
|
|
3334
|
+
width: var(--list-size-touch_row_min);
|
|
3335
|
+
height: var(--list-size-touch_row_min);
|
|
3336
|
+
font-size: 2rem;
|
|
3337
|
+
}
|
|
3338
|
+
list-container > div > list-headerrow > .key > div > span > span:hover {
|
|
3339
|
+
background-color: var(--list-colors-background-row_hover);
|
|
3340
|
+
}
|
|
3341
|
+
list-container > div > list-headerrow > .key > div > span > .list-open-all::before {
|
|
3342
|
+
content: "\e5d7";
|
|
3343
|
+
}
|
|
3344
|
+
list-container > div > list-headerrow > .key > div > span > .list-close-all::before {
|
|
3345
|
+
content: "\e5d6";
|
|
3346
|
+
}
|
|
3347
|
+
|
|
3348
|
+
list-container > input.list-warn {
|
|
3349
|
+
all: unset;
|
|
3350
|
+
visibility: hidden;
|
|
3351
|
+
position: absolute;
|
|
3352
|
+
pointer-events: none;
|
|
3353
|
+
height: 0px;
|
|
3354
|
+
width: 0px;
|
|
3355
|
+
}
|
|
3356
|
+
|
|
3357
|
+
list-container > div {
|
|
3358
|
+
--list-drag-width: 0px;
|
|
3359
|
+
--list-check-width: 0px;
|
|
3360
|
+
--list-lead-size: var(--list-size-row_min);
|
|
3361
|
+
}
|
|
3362
|
+
.touch list-container > div {
|
|
3363
|
+
--list-lead-size: var(--list-size-touch_row_min);
|
|
3364
|
+
}
|
|
3365
|
+
list-container > div.drag {
|
|
3366
|
+
--list-drag-width: var(--list-lead-size);
|
|
3367
|
+
}
|
|
3368
|
+
list-container > div.check {
|
|
3369
|
+
--list-check-width: var(--list-lead-size);
|
|
3370
|
+
}
|
|
3371
|
+
list-container > div list-keyfield,
|
|
3372
|
+
list-container > div > list-headerrow > .key {
|
|
3373
|
+
left: calc(var(--list-drag-width) + var(--list-check-width));
|
|
3374
|
+
}
|
|
3375
|
+
list-container > div > list-headerrow > :first-child,
|
|
3376
|
+
list-container > div > list-headerrow > .key,
|
|
3377
|
+
list-container > div > list-headerrow > list-dragfield,
|
|
3378
|
+
list-container > div > list-headerrow > list-checkfield {
|
|
3379
|
+
z-index: 1000;
|
|
3380
|
+
}
|
|
3381
|
+
list-container > div.key-sized list-keyfield {
|
|
3382
|
+
box-sizing: border-box;
|
|
3383
|
+
contain: inline-size;
|
|
3384
|
+
min-width: max(var(--list-key-width), var(--list-key-min));
|
|
3385
|
+
}
|
|
3386
|
+
list-container > div.key-sized list-keyfield > span.text {
|
|
3387
|
+
overflow-wrap: anywhere;
|
|
3388
|
+
}
|
|
3389
|
+
list-container > div.key-sized > list-headerrow > .key {
|
|
3390
|
+
min-width: var(--list-key-width);
|
|
3391
|
+
}
|
|
3392
|
+
list-container > div.lead-1 list-keyfield.tail,
|
|
3393
|
+
list-container > div.lead-1 list-addrow > span,
|
|
3394
|
+
list-container > div.lead-1 list-error {
|
|
3395
|
+
grid-column: 2/-1;
|
|
3396
|
+
}
|
|
3397
|
+
list-container > div.lead-2 list-keyfield.tail,
|
|
3398
|
+
list-container > div.lead-2 list-addrow > span,
|
|
3399
|
+
list-container > div.lead-2 list-error {
|
|
3400
|
+
grid-column: 3/-1;
|
|
3401
|
+
}
|
|
3179
3402
|
list-rowserror {
|
|
3180
3403
|
display: contents;
|
|
3181
3404
|
}
|
|
3182
|
-
list-rowserror > list-error
|
|
3405
|
+
list-rowserror > list-error,
|
|
3406
|
+
list-rowserror > list-keyfield {
|
|
3183
3407
|
background-color: var(--list-colors-background-row_odd);
|
|
3184
3408
|
}
|
|
3185
3409
|
|
|
@@ -3197,9 +3421,6 @@ list-error {
|
|
|
3197
3421
|
.touch list-error {
|
|
3198
3422
|
min-height: var(--list-size-touch_row_min);
|
|
3199
3423
|
}
|
|
3200
|
-
list-container > div.sub-rows list-error {
|
|
3201
|
-
grid-column: 2/-1;
|
|
3202
|
-
}
|
|
3203
3424
|
list-textfield,
|
|
3204
3425
|
list-numberfield,
|
|
3205
3426
|
list-nodefield {
|
|
@@ -3273,3 +3494,68 @@ list-row > span {
|
|
|
3273
3494
|
list-row:not(.open) > list-addrow {
|
|
3274
3495
|
display: none;
|
|
3275
3496
|
}
|
|
3497
|
+
|
|
3498
|
+
list-row.selected > div > * {
|
|
3499
|
+
background-color: var(--list-colors-background-row_selected);
|
|
3500
|
+
}
|
|
3501
|
+
list-row.selected > div:hover > * {
|
|
3502
|
+
background-color: var(--list-colors-background-row_selected_hover);
|
|
3503
|
+
}
|
|
3504
|
+
list-checkfield {
|
|
3505
|
+
position: sticky;
|
|
3506
|
+
left: var(--list-drag-width);
|
|
3507
|
+
z-index: 2;
|
|
3508
|
+
display: flex;
|
|
3509
|
+
align-items: center;
|
|
3510
|
+
justify-content: center;
|
|
3511
|
+
box-sizing: border-box;
|
|
3512
|
+
min-height: var(--list-check-width);
|
|
3513
|
+
user-select: none;
|
|
3514
|
+
cursor: pointer;
|
|
3515
|
+
outline: none;
|
|
3516
|
+
border-right: 1px solid var(--list-colors-border-column);
|
|
3517
|
+
}
|
|
3518
|
+
list-checkfield::before {
|
|
3519
|
+
font-family: "Material Symbols Rounded";
|
|
3520
|
+
font-weight: normal;
|
|
3521
|
+
font-style: normal;
|
|
3522
|
+
letter-spacing: normal;
|
|
3523
|
+
text-transform: none;
|
|
3524
|
+
white-space: nowrap;
|
|
3525
|
+
word-wrap: normal;
|
|
3526
|
+
direction: ltr;
|
|
3527
|
+
-webkit-font-feature-settings: "liga";
|
|
3528
|
+
-webkit-font-smoothing: antialiased;
|
|
3529
|
+
font-size: 1.2rem;
|
|
3530
|
+
line-height: 1;
|
|
3531
|
+
color: var(--list-colors-icon-check);
|
|
3532
|
+
}
|
|
3533
|
+
.touch list-checkfield::before {
|
|
3534
|
+
font-size: 1.8rem;
|
|
3535
|
+
}
|
|
3536
|
+
list-checkfield:focus-visible:not(.click-focus) {
|
|
3537
|
+
outline: 2px solid var(--list-colors-focus-normal);
|
|
3538
|
+
outline-offset: -2px;
|
|
3539
|
+
}
|
|
3540
|
+
|
|
3541
|
+
list-container > div.multi list-row.selectable > div > list-checkfield::before,
|
|
3542
|
+
list-container > div.multi > list-headerrow > list-checkfield::before {
|
|
3543
|
+
content: "\e835";
|
|
3544
|
+
}
|
|
3545
|
+
list-container > div.multi list-row.selectable.selected > div > list-checkfield::before,
|
|
3546
|
+
list-container > div.multi > list-headerrow > list-checkfield.all::before {
|
|
3547
|
+
content: "\e834";
|
|
3548
|
+
}
|
|
3549
|
+
list-container > div.multi > list-headerrow > list-checkfield.some:not(.all)::before {
|
|
3550
|
+
content: "\e909";
|
|
3551
|
+
}
|
|
3552
|
+
|
|
3553
|
+
list-container > div.single list-row.selectable > div > list-checkfield::before {
|
|
3554
|
+
content: "\e836";
|
|
3555
|
+
}
|
|
3556
|
+
list-container > div.single list-row.selectable.selected > div > list-checkfield::before {
|
|
3557
|
+
content: "\e837";
|
|
3558
|
+
}
|
|
3559
|
+
list-container > div.single > list-headerrow > list-checkfield {
|
|
3560
|
+
cursor: default;
|
|
3561
|
+
}
|
package/svg/index.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import "../style.css";
|
|
2
|
-
export { n as SVGAnchorPoint, t as svg } from "../svg-
|
|
2
|
+
export { n as SVGAnchorPoint, t as svg } from "../svg-Yz7elqnU.mjs";
|