@syware/jlib 0.11.1 → 0.12.0

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/README.md CHANGED
@@ -83,18 +83,38 @@ part of the page.
83
83
 
84
84
  ## Vibe coding
85
85
 
86
- The repository is also a Claude Code plugin marketplace, with two plugins: `jlib` teaches Claude the components,
87
- where their API is and the way an app is written on them; `syware-ux` adds how SyWare's apps behave, from the UX
88
- patterns. In Claude Code:
89
-
90
- ```
91
- /plugin marketplace add bioleyl/jlib
92
- /plugin install jlib@jlib
93
- /plugin install syware-ux@jlib
94
- ```
95
-
96
- How an app's repository gives them to everyone working on it, and how to ask Claude well: the site's
97
- [Vibe coding](https://bioleyl.github.io/jlib/vibe-coding) page. The plugins are in [plugins/](plugins).
86
+ Two skills teach coding agents to build on jlib: `jlib-official`, the components (each one's whole API, offline),
87
+ the way an app is written on them, the mistakes agents make and a self-check; and `syware-ux`, how SyWare's apps
88
+ behave, every UX pattern in full and the checklist a page is reviewed against. They build on Jadis's skill,
89
+ `jadis-official`. Install them in one of three ways:
90
+
91
+ - **Claude Code**, as plugins that update with each release; `syware-ux` brings `jlib-official`, which brings
92
+ `jadis-official` (for an app that does not follow SyWare's UX, install `jlib-official@jlib`):
93
+
94
+ ```
95
+ /plugin marketplace add bioleyl/jadis
96
+ /plugin marketplace add bioleyl/jlib
97
+ /plugin install syware-ux@jlib
98
+ ```
99
+
100
+ - **Any agent**, with [skills.sh](https://skills.sh) (Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot,
101
+ OpenCode…):
102
+
103
+ ```bash
104
+ npx skills add bioleyl/jlib
105
+ npx skills add bioleyl/jadis
106
+ ```
107
+
108
+ - **Any agent**, with the install script, which asks which skills and where: `~/.agents/skills`, `~/.claude/skills`,
109
+ the project's `.agents/skills` or `.claude/skills`, or another folder (`--help` for the options):
110
+
111
+ ```bash
112
+ curl -fsSL https://raw.githubusercontent.com/bioleyl/jlib/main/install-skill.sh | sh
113
+ ```
114
+
115
+ The skills are in [plugins/](plugins): [jlib-official](plugins/jlib-official/skills/jlib-official/SKILL.md) and
116
+ [syware-ux](plugins/syware-ux/skills/syware-ux/SKILL.md). How a team shares them and how to ask well: the site's
117
+ [Vibe coding](https://bioleyl.github.io/jlib/vibe-coding) page.
98
118
 
99
119
  ## Development
100
120
 
@@ -102,6 +102,8 @@ export declare class JlInput extends JlFormControl {
102
102
  templateHtml(): Node;
103
103
  templateCss(): string;
104
104
  onConnect(): void;
105
+ /** Enter: `enter` for the page, then the form submits, as from a native field. */
106
+ private onKey;
105
107
  protected resetValue(): void;
106
108
  /** The browser calls it for a disabled fieldset and for the element's own disabled attribute, even before render. */
107
109
  protected setDisabledByForm(disabled: boolean): void;
@@ -142,10 +142,16 @@ var JlInput = class extends JlFormControl {
142
142
  this.events.emit("input", native.value);
143
143
  });
144
144
  this.on(native, "change", () => this.events.emit("change", native.value));
145
- this.on(native, "keydown", (event) => event.key === ENTER && this.events.emit("enter", native.value));
145
+ this.on(native, "keydown", (event) => this.onKey(event));
146
146
  this.on(this._refs.clear, "click", () => this.clearValue());
147
147
  this.on(this._refs.reveal, "click", () => this.toggleReveal());
148
148
  }
149
+ /** Enter: `enter` for the page, then the form submits, as from a native field. */
150
+ onKey(event) {
151
+ if (event.key !== ENTER) return;
152
+ this.events.emit("enter", this._refs.native.value);
153
+ this.submitImplicitly(event);
154
+ }
149
155
  resetValue() {
150
156
  this.value.set(this.getAttribute("value") ?? "");
151
157
  }
@@ -23,6 +23,13 @@ export declare abstract class JlFormControl extends JlElement {
23
23
  formDisabledCallback(disabled: boolean): void;
24
24
  protected abstract resetValue(): void;
25
25
  protected abstract setDisabledByForm(disabled: boolean): void;
26
+ /**
27
+ * Submits the form the field belongs to, as Enter in a native field of one line does. The native field inside the
28
+ * shadow root belongs to no form, so the browser's own implicit submission never reaches the page's: each field of
29
+ * one line calls this for an Enter it did not use itself. Nothing during a composition (an IME choosing a word), or
30
+ * outside a form; `requestSubmit` checks the form's fields first, as a submit button does.
31
+ */
32
+ protected submitImplicitly(event: KeyboardEvent): void;
26
33
  /** Copies the native field's validity, so the form sees the same errors the browser would show. */
27
34
  protected mirrorValidity(native: ValidatedElement): void;
28
35
  }
@@ -33,6 +33,16 @@ var JlFormControl = class extends JlElement {
33
33
  formDisabledCallback(disabled) {
34
34
  this.setDisabledByForm(disabled);
35
35
  }
36
+ /**
37
+ * Submits the form the field belongs to, as Enter in a native field of one line does. The native field inside the
38
+ * shadow root belongs to no form, so the browser's own implicit submission never reaches the page's: each field of
39
+ * one line calls this for an Enter it did not use itself. Nothing during a composition (an IME choosing a word), or
40
+ * outside a form; `requestSubmit` checks the form's fields first, as a submit button does.
41
+ */
42
+ submitImplicitly(event) {
43
+ if (event.isComposing) return;
44
+ this.internals.form?.requestSubmit();
45
+ }
36
46
  /** Copies the native field's validity, so the form sees the same errors the browser would show. */
37
47
  mirrorValidity(native) {
38
48
  if (native.validity.valid) {
@@ -195,13 +195,19 @@ var JlCombobox = class extends JlFormControl {
195
195
  this.openList(true);
196
196
  }
197
197
  onKey(event) {
198
- if ((/* @__PURE__ */ new Map([
198
+ const handler = (/* @__PURE__ */ new Map([
199
199
  ["ArrowDown", () => this.onArrow(1, event.altKey)],
200
200
  ["ArrowUp", () => this.onArrow(-1, event.altKey)],
201
201
  ["Enter", () => this.onEnter()],
202
202
  ["Escape", () => this.onEscape()],
203
203
  ["Tab", () => this.onTab()]
204
- ])).get(event.key)?.() === true) event.preventDefault();
204
+ ])).get(event.key);
205
+ if (handler === void 0) return;
206
+ if (handler()) {
207
+ event.preventDefault();
208
+ return;
209
+ }
210
+ if (event.key === "Enter") this.submitImplicitly(event);
205
211
  }
206
212
  /** Down opens the list or moves down it; Alt + Down opens it as it is, Alt + Up closes it. */
207
213
  onArrow(direction, alt) {
@@ -197,6 +197,11 @@ var JlDatePicker = class extends JlFormControl {
197
197
  if (event.key === "ArrowDown") {
198
198
  event.preventDefault();
199
199
  this.openPopup();
200
+ return;
201
+ }
202
+ if (event.key === "Enter") {
203
+ this.commitText();
204
+ this.submitImplicitly(event);
200
205
  }
201
206
  }
202
207
  onOpenPress() {
@@ -139,7 +139,10 @@ var JlNumberInput = class extends JlFormControl {
139
139
  ["ArrowDown", () => this.stepBy(-1)],
140
140
  ["ArrowUp", () => this.stepBy(1)],
141
141
  ["End", () => this.goToBound(this.max.get())],
142
- ["Enter", () => this.commitText()],
142
+ ["Enter", () => {
143
+ this.commitText();
144
+ this.submitImplicitly(event);
145
+ }],
143
146
  ["Home", () => this.goToBound(this.min.get())],
144
147
  ["PageDown", () => this.stepBy(-10)],
145
148
  ["PageUp", () => this.stepBy(PAGE_STEPS)]
@@ -166,6 +166,7 @@ var JlSearch = class extends JlFormControl {
166
166
  event.preventDefault();
167
167
  this.search(this.value.get());
168
168
  this.events.emit("enter", this.value.get());
169
+ this.submitImplicitly(event);
169
170
  return;
170
171
  }
171
172
  if (event.key === "Escape" && this.value.get() !== "") {
@@ -164,7 +164,7 @@ var JlTagInput = class extends JlFormControl {
164
164
  this.renderMatches();
165
165
  }
166
166
  onFieldKey(event) {
167
- if ((/* @__PURE__ */ new Map([
167
+ const handler = (/* @__PURE__ */ new Map([
168
168
  [COMMA, () => {
169
169
  this.commitText();
170
170
  return true;
@@ -175,7 +175,13 @@ var JlTagInput = class extends JlFormControl {
175
175
  ["Backspace", () => this.removeLastIfEmpty()],
176
176
  ["Enter", () => this.onEnter()],
177
177
  ["Escape", () => this.closeList()]
178
- ])).get(event.key)?.() === true) event.preventDefault();
178
+ ])).get(event.key);
179
+ if (handler === void 0) return;
180
+ if (handler()) {
181
+ event.preventDefault();
182
+ return;
183
+ }
184
+ if (event.key === "Enter") this.submitImplicitly(event);
179
185
  }
180
186
  /** Enter adds the suggestion the arrows reached, or the typed text; in an empty field it submits the form. */
181
187
  onEnter() {
@@ -1,3 +1,3 @@
1
1
  // src/organisms/jl-dialog.css?inline
2
- var jl_dialog_default = ":host{--width:520px;display:contents}:host([size=sm]){--width:400px}:host([size=lg]){--width:820px}:host([size=full]){--width:100vw}dialog{width:min(var(--width), calc(100vw - 32px));border:1px solid var(--jl-line);border-radius:var(--jl-radius-lg);background:var(--jl-surface);max-height:min(760px,100dvh - 48px);color:var(--jl-text);font-size:var(--jl-font-md);box-shadow:var(--jl-shadow-lg);flex-direction:column;padding:0;display:flex}dialog:not([open]){display:none}:host([size=full]) dialog{height:calc(100dvh - 32px);max-height:calc(100dvh - 32px)}dialog[open]{animation:rise var(--jl-slow) var(--jl-ease)}dialog::backdrop{background:var(--jl-scrim);-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px)}header{align-items:flex-start;gap:12px;padding:20px 16px 4px 24px;display:flex}.titles{flex:1;gap:4px;padding-top:4px;display:grid}h2{letter-spacing:-.01em;font-size:17px;font-weight:650;line-height:1.3}.description{color:var(--jl-muted);font-size:var(--jl-font-sm);line-height:1.5}.body{flex:1;padding:16px 24px;line-height:1.55;overflow:auto}footer{flex-wrap:wrap;justify-content:flex-end;gap:8px;padding:0 24px 20px;display:flex}@keyframes rise{0%{opacity:0;transform:translateY(8px)scale(.98)}}";
2
+ var jl_dialog_default = ":host{--width:520px;display:contents}:host([size=sm]){--width:400px}:host([size=lg]){--width:820px}:host([size=full]){--width:100vw}dialog{width:min(var(--width), calc(100vw - 32px));border:1px solid var(--jl-line);border-radius:var(--jl-radius-lg);background:var(--jl-surface);max-height:min(760px,100dvh - 48px);color:var(--jl-text);font-size:var(--jl-font-md);box-shadow:var(--jl-shadow-lg);flex-direction:column;padding:0;display:flex}dialog:not([open]){display:none}:host([size=full]) dialog{height:calc(100dvh - 32px);max-height:calc(100dvh - 32px)}dialog[open]{animation:rise var(--jl-slow) var(--jl-ease)}dialog::backdrop{background:var(--jl-scrim);-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px)}header{align-items:flex-start;gap:12px;padding:20px 16px 4px 24px;display:flex}.titles{flex:1;gap:4px;padding-top:4px;display:grid}h2{letter-spacing:-.01em;font-size:17px;font-weight:650;line-height:1.3}.description{color:var(--jl-muted);font-size:var(--jl-font-sm);line-height:1.5}.body{flex:1;padding:16px 24px;line-height:1.55;position:relative;overflow:auto}footer{flex-wrap:wrap;justify-content:flex-end;gap:8px;padding:0 24px 20px;display:flex}@keyframes rise{0%{opacity:0;transform:translateY(8px)scale(.98)}}";
3
3
  export { jl_dialog_default as default };
@@ -1,3 +1,3 @@
1
1
  // src/organisms/jl-drawer.css?inline
2
- var jl_drawer_default = ":host{--size:420px;--from:translateX(100%);display:contents}:host([size=sm]){--size:320px}:host([size=lg]){--size:640px}:host([placement=left]){--from:translateX(-100%)}:host([placement=bottom]){--size:60dvh;--from:translateY(100%)}:host([placement=bottom][size=sm]){--size:40dvh}:host([placement=bottom][size=lg]){--size:88dvh}dialog{width:min(var(--size), calc(100vw - 24px));border:none;border-left:1px solid var(--jl-line);background:var(--jl-surface);max-width:none;height:100dvh;max-height:none;color:var(--jl-text);font-size:var(--jl-font-md);box-shadow:var(--jl-shadow-lg);transform:var(--from);transition:transform var(--jl-slow) var(--jl-ease), display var(--jl-slow) allow-discrete, overlay var(--jl-slow) allow-discrete;flex-direction:column;margin:0;padding:0;display:none;position:fixed;inset:0 0 0 auto}dialog[open]{display:flex;transform:none}@starting-style{dialog[open]{transform:var(--from)}}:host([placement=left]) dialog{border-right:1px solid var(--jl-line);border-left:none;inset:0 auto 0 0}:host([placement=bottom]) dialog{width:100%;height:auto;max-height:var(--size);border:1px solid var(--jl-line);border-radius:var(--jl-radius-xl) var(--jl-radius-xl) 0 0;border-bottom:none;inset:auto 0 0}dialog::backdrop{transition:background var(--jl-slow) var(--jl-ease), display var(--jl-slow) allow-discrete, overlay var(--jl-slow) allow-discrete;background:0 0}dialog[open]::backdrop{background:var(--jl-scrim)}@starting-style{dialog[open]::backdrop{background:0 0}}.handle{display:none}:host([placement=bottom]) .handle{border-radius:var(--jl-radius-pill);background:var(--jl-line-strong);flex:none;width:40px;height:4px;margin:10px auto 0;display:block}header{border-bottom:1px solid var(--jl-line);flex:none;align-items:flex-start;gap:12px;padding:18px 16px 14px 24px;display:flex}:host([placement=bottom]) header{padding-top:10px}.titles{flex:1;gap:4px;min-width:0;padding-top:4px;display:grid}h2{letter-spacing:-.01em;font-size:17px;font-weight:650;line-height:1.3}.description{color:var(--jl-muted);font-size:var(--jl-font-sm);line-height:1.5}.actions{flex:none;align-items:center;gap:4px;display:flex}.body{overscroll-behavior:contain;flex:1;min-height:0;padding:20px 24px;line-height:1.55;overflow:auto}footer{border-top:1px solid var(--jl-line);background:var(--jl-surface);flex-wrap:wrap;flex:none;justify-content:flex-end;gap:8px;padding:14px 24px;display:flex}:host([placement=bottom]) footer{padding-bottom:max(14px, env(safe-area-inset-bottom))}";
2
+ var jl_drawer_default = ":host{--size:420px;--from:translateX(100%);display:contents}:host([size=sm]){--size:320px}:host([size=lg]){--size:640px}:host([placement=left]){--from:translateX(-100%)}:host([placement=bottom]){--size:60dvh;--from:translateY(100%)}:host([placement=bottom][size=sm]){--size:40dvh}:host([placement=bottom][size=lg]){--size:88dvh}dialog{width:min(var(--size), calc(100vw - 24px));border:none;border-left:1px solid var(--jl-line);background:var(--jl-surface);max-width:none;height:100dvh;max-height:none;color:var(--jl-text);font-size:var(--jl-font-md);box-shadow:var(--jl-shadow-lg);transform:var(--from);transition:transform var(--jl-slow) var(--jl-ease), display var(--jl-slow) allow-discrete, overlay var(--jl-slow) allow-discrete;flex-direction:column;margin:0;padding:0;display:none;position:fixed;inset:0 0 0 auto}dialog[open]{display:flex;transform:none}@starting-style{dialog[open]{transform:var(--from)}}:host([placement=left]) dialog{border-right:1px solid var(--jl-line);border-left:none;inset:0 auto 0 0}:host([placement=bottom]) dialog{width:100%;height:auto;max-height:var(--size);border:1px solid var(--jl-line);border-radius:var(--jl-radius-xl) var(--jl-radius-xl) 0 0;border-bottom:none;inset:auto 0 0}dialog::backdrop{transition:background var(--jl-slow) var(--jl-ease), display var(--jl-slow) allow-discrete, overlay var(--jl-slow) allow-discrete;background:0 0}dialog[open]::backdrop{background:var(--jl-scrim)}@starting-style{dialog[open]::backdrop{background:0 0}}.handle{display:none}:host([placement=bottom]) .handle{border-radius:var(--jl-radius-pill);background:var(--jl-line-strong);flex:none;width:40px;height:4px;margin:10px auto 0;display:block}header{border-bottom:1px solid var(--jl-line);flex:none;align-items:flex-start;gap:12px;padding:18px 16px 14px 24px;display:flex}:host([placement=bottom]) header{padding-top:10px}.titles{flex:1;gap:4px;min-width:0;padding-top:4px;display:grid}h2{letter-spacing:-.01em;font-size:17px;font-weight:650;line-height:1.3}.description{color:var(--jl-muted);font-size:var(--jl-font-sm);line-height:1.5}.actions{flex:none;align-items:center;gap:4px;display:flex}.body{overscroll-behavior:contain;flex:1;min-height:0;padding:20px 24px;line-height:1.55;position:relative;overflow:auto}footer{border-top:1px solid var(--jl-line);background:var(--jl-surface);flex-wrap:wrap;flex:none;justify-content:flex-end;gap:8px;padding:14px 24px;display:flex}:host([placement=bottom]) footer{padding-bottom:max(14px, env(safe-area-inset-bottom))}";
3
3
  export { jl_drawer_default as default };
@@ -1,3 +1,3 @@
1
1
  // src/organisms/jl-table.css?inline
2
- var jl_table_default = ":host{contain:inline-size;--max-height:none;--cell-y:10px;--cell-x:14px;--select-width:44px;--expand-width:36px;--lead:0px;display:block}:host([expandable]){--lead:var(--expand-width)}:host([expandable][selectable]){--expand-width:28px;--lead:calc(var(--select-width) + var(--expand-width))}:host([dense]){--cell-y:6px;--cell-x:12px}.scroll{max-height:var(--max-height);border:1px solid var(--jl-line);border-radius:var(--jl-radius);background:var(--jl-surface);overscroll-behavior-x:contain;overflow:auto}:host([expandable]) .scroll{container-type:inline-size}table{border-collapse:separate;border-spacing:0;width:100%;color:var(--jl-text);font-size:var(--jl-font-md);line-height:20px}th,td{padding:var(--cell-y) var(--cell-x);white-space:nowrap;vertical-align:middle}th{z-index:1;border-bottom:1px solid var(--jl-line);background:var(--jl-surface-2);color:var(--jl-muted);font-size:var(--jl-font-xs);letter-spacing:.01em;text-align:left;font-weight:600;position:sticky;top:0}td{border-top:1px solid var(--jl-line-soft)}tbody tr:first-child td{border-top:none}tbody tr.empty td{padding:40px var(--cell-x);color:var(--jl-muted);text-align:center}tbody tr.detail td{padding:0 var(--cell-x) calc(var(--cell-y) + 6px) calc(var(--lead) + var(--cell-x));white-space:normal;cursor:auto;border-top:none}.detail-body{left:calc(var(--lead) + var(--cell-x));max-width:calc(100cqi - var(--lead) - 2 * var(--cell-x));position:sticky}.align-left{text-align:left}.align-center{text-align:center}.align-right{text-align:right}.sort{border-radius:var(--jl-radius-xs);color:inherit;font-weight:inherit;letter-spacing:inherit;cursor:pointer;background:0 0;border:none;align-items:center;gap:4px;margin:-2px -4px;padding:2px 4px;display:inline-flex}.sort:hover{color:var(--jl-text)}.sort-icon{color:var(--jl-faint)}th[data-sorted]{color:var(--jl-text)}th[data-sorted] .sort-icon{color:var(--jl-accent)}tbody tr[data-selected] td,tbody tr[data-marked] td{background:var(--jl-accent-soft)}tbody tr[data-marked] td:first-child{box-shadow:inset 3px 0 0 var(--jl-accent)}tbody tr:not(.empty,.skeleton,.detail,[data-selected]):hover td,:host([striped]) tbody tr:nth-child(2n of :where(:not(.detail))):not(.empty,[data-selected],[data-marked]) td{background:var(--jl-surface-2)}:host([striped]) tbody tr:not(.empty,.skeleton,.detail,[data-selected]):hover td{background:var(--jl-surface-3)}:host([striped]) tbody tr:nth-child(2n of :where(:not(.detail))):not([data-selected],[data-marked])+.detail td{background:var(--jl-surface-2)}.format-number{font-variant-numeric:tabular-nums}td.wrap{white-space:normal;overflow-wrap:anywhere;min-width:160px}.format-date{color:var(--jl-text-2);font-variant-numeric:tabular-nums}code{border-radius:var(--jl-radius-xs);background:var(--jl-code-bg);font-size:var(--jl-font-xs);padding:2px 6px}.select-cell{width:var(--select-width);padding-right:0;line-height:0}.expand-cell{width:var(--expand-width);padding-right:0;padding-left:calc(var(--cell-x) - 4px);line-height:0}.select-cell+.expand-cell{padding-left:0}:host([expandable]) tbody tr[data-index]{cursor:pointer}.expand{border-radius:var(--jl-radius-xs);width:24px;height:24px;color:var(--jl-muted);cursor:pointer;background:0 0;border:none;justify-content:center;align-items:center;margin:-2px 0;padding:0;display:inline-flex}.expand:hover{color:var(--jl-text)}.chevron{transition:rotate var(--jl-fast) var(--jl-ease)}.expand[aria-expanded=true] .chevron{rotate:90deg}.check{display:inline-flex;position:relative}.checkbox{border:1.5px solid var(--jl-line-strong);background:var(--jl-surface);cursor:pointer;appearance:none;width:16px;height:16px;transition:background var(--jl-fast) var(--jl-ease), border-color var(--jl-fast) var(--jl-ease);border-radius:4px;margin:0}.checkbox:hover{border-color:var(--jl-muted)}.checkbox:checked,.checkbox:indeterminate{border-color:var(--jl-accent);background:var(--jl-accent)}.checkbox:disabled{cursor:not-allowed;opacity:.5}.mark{pointer-events:none;position:absolute;inset:0}.checkbox:checked+.mark:after{border:solid var(--jl-on-accent);content:\"\";border-width:0 2px 2px 0;width:5px;height:9px;position:absolute;top:2.5px;left:5.5px;rotate:45deg}.checkbox:indeterminate+.mark:after{background:var(--jl-on-accent);content:\"\";border-radius:1px;height:2px;position:absolute;top:7px;left:4px;right:4px}.empty-content{align-items:center;gap:8px;display:inline-flex}.empty jl-icon{color:var(--jl-faint)}.bone{border-radius:var(--jl-radius-pill);background:linear-gradient(90deg, var(--jl-surface-3) 30%, var(--jl-surface-2) 50%, var(--jl-surface-3) 70%) 0 0 / 300% 100%;vertical-align:middle;width:70%;max-width:160px;height:10px;animation:1.4s linear infinite shimmer;display:inline-block}.bone.box{border-radius:4px;width:16px;height:16px}tbody tr.skeleton:nth-child(3n+2) .bone:not(.box){width:50%}tbody tr.skeleton:nth-child(3n) .bone:not(.box){width:85%}@media (prefers-reduced-motion:reduce){.bone{animation:none}}@keyframes shimmer{0%{background-position:100% 0}to{background-position:0 0}}.cell-description{color:var(--jl-muted);font-size:var(--jl-font-xs);margin-top:2px}";
2
+ var jl_table_default = ":host{contain:inline-size;--max-height:none;--cell-y:10px;--cell-x:14px;--select-width:44px;--expand-width:36px;--lead:0px;display:block}:host([expandable]){--lead:var(--expand-width)}:host([expandable][selectable]){--expand-width:28px;--lead:calc(var(--select-width) + var(--expand-width))}:host([dense]){--cell-y:6px;--cell-x:12px}.scroll{max-height:var(--max-height);border:1px solid var(--jl-line);border-radius:var(--jl-radius);background:var(--jl-surface);overscroll-behavior-x:contain;position:relative;overflow:auto}:host([expandable]) .scroll{container-type:inline-size}table{border-collapse:separate;border-spacing:0;width:100%;color:var(--jl-text);font-size:var(--jl-font-md);line-height:20px}th,td{padding:var(--cell-y) var(--cell-x);white-space:nowrap;vertical-align:middle}th{z-index:1;border-bottom:1px solid var(--jl-line);background:var(--jl-surface-2);color:var(--jl-muted);font-size:var(--jl-font-xs);letter-spacing:.01em;text-align:left;font-weight:600;position:sticky;top:0}td{border-top:1px solid var(--jl-line-soft)}tbody tr:first-child td{border-top:none}tbody tr.empty td{padding:40px var(--cell-x);color:var(--jl-muted);text-align:center}tbody tr.detail td{padding:0 var(--cell-x) calc(var(--cell-y) + 6px) calc(var(--lead) + var(--cell-x));white-space:normal;cursor:auto;border-top:none}.detail-body{left:calc(var(--lead) + var(--cell-x));max-width:calc(100cqi - var(--lead) - 2 * var(--cell-x));position:sticky}.align-left{text-align:left}.align-center{text-align:center}.align-right{text-align:right}.sort{border-radius:var(--jl-radius-xs);color:inherit;font-weight:inherit;letter-spacing:inherit;cursor:pointer;background:0 0;border:none;align-items:center;gap:4px;margin:-2px -4px;padding:2px 4px;display:inline-flex}.sort:hover{color:var(--jl-text)}.sort-icon{color:var(--jl-faint)}th[data-sorted]{color:var(--jl-text)}th[data-sorted] .sort-icon{color:var(--jl-accent)}tbody tr[data-selected] td,tbody tr[data-marked] td{background:var(--jl-accent-soft)}tbody tr[data-marked] td:first-child{box-shadow:inset 3px 0 0 var(--jl-accent)}tbody tr:not(.empty,.skeleton,.detail,[data-selected]):hover td,:host([striped]) tbody tr:nth-child(2n of :where(:not(.detail))):not(.empty,[data-selected],[data-marked]) td{background:var(--jl-surface-2)}:host([striped]) tbody tr:not(.empty,.skeleton,.detail,[data-selected]):hover td{background:var(--jl-surface-3)}:host([striped]) tbody tr:nth-child(2n of :where(:not(.detail))):not([data-selected],[data-marked])+.detail td{background:var(--jl-surface-2)}.format-number{font-variant-numeric:tabular-nums}td.wrap{white-space:normal;overflow-wrap:anywhere;min-width:160px}.format-date{color:var(--jl-text-2);font-variant-numeric:tabular-nums}code{border-radius:var(--jl-radius-xs);background:var(--jl-code-bg);font-size:var(--jl-font-xs);padding:2px 6px}.select-cell{width:var(--select-width);padding-right:0;line-height:0}.expand-cell{width:var(--expand-width);padding-right:0;padding-left:calc(var(--cell-x) - 4px);line-height:0}.select-cell+.expand-cell{padding-left:0}:host([expandable]) tbody tr[data-index]{cursor:pointer}.expand{border-radius:var(--jl-radius-xs);width:24px;height:24px;color:var(--jl-muted);cursor:pointer;background:0 0;border:none;justify-content:center;align-items:center;margin:-2px 0;padding:0;display:inline-flex}.expand:hover{color:var(--jl-text)}.chevron{transition:rotate var(--jl-fast) var(--jl-ease)}.expand[aria-expanded=true] .chevron{rotate:90deg}.check{display:inline-flex;position:relative}.checkbox{border:1.5px solid var(--jl-line-strong);background:var(--jl-surface);cursor:pointer;appearance:none;width:16px;height:16px;transition:background var(--jl-fast) var(--jl-ease), border-color var(--jl-fast) var(--jl-ease);border-radius:4px;margin:0}.checkbox:hover{border-color:var(--jl-muted)}.checkbox:checked,.checkbox:indeterminate{border-color:var(--jl-accent);background:var(--jl-accent)}.checkbox:disabled{cursor:not-allowed;opacity:.5}.mark{pointer-events:none;position:absolute;inset:0}.checkbox:checked+.mark:after{border:solid var(--jl-on-accent);content:\"\";border-width:0 2px 2px 0;width:5px;height:9px;position:absolute;top:2.5px;left:5.5px;rotate:45deg}.checkbox:indeterminate+.mark:after{background:var(--jl-on-accent);content:\"\";border-radius:1px;height:2px;position:absolute;top:7px;left:4px;right:4px}.empty-content{align-items:center;gap:8px;display:inline-flex}.empty jl-icon{color:var(--jl-faint)}.bone{border-radius:var(--jl-radius-pill);background:linear-gradient(90deg, var(--jl-surface-3) 30%, var(--jl-surface-2) 50%, var(--jl-surface-3) 70%) 0 0 / 300% 100%;vertical-align:middle;width:70%;max-width:160px;height:10px;animation:1.4s linear infinite shimmer;display:inline-block}.bone.box{border-radius:4px;width:16px;height:16px}tbody tr.skeleton:nth-child(3n+2) .bone:not(.box){width:50%}tbody tr.skeleton:nth-child(3n) .bone:not(.box){width:85%}@media (prefers-reduced-motion:reduce){.bone{animation:none}}@keyframes shimmer{0%{background-position:100% 0}to{background-position:0 0}}.cell-description{color:var(--jl-muted);font-size:var(--jl-font-xs);margin-top:2px}";
3
3
  export { jl_table_default as default };
@@ -1,3 +1,3 @@
1
1
  // src/templates/jl-split-view.css?inline
2
- var jl_split_view_default = ":host{height:100%;min-height:0;display:block}.split{grid-template-columns:minmax(0, var(--position,50%)) 1px minmax(0, 1fr);height:100%;display:grid}:host([orientation=vertical]) .split{grid-template-columns:none;grid-template-rows:minmax(0, var(--position,50%)) 1px minmax(0, 1fr)}.pane{min-width:0;min-height:0;overflow:auto}.divider{z-index:1;background:var(--jl-line);cursor:col-resize;touch-action:none;transition:background var(--jl-fast) var(--jl-ease);position:relative}:host([orientation=vertical]) .divider{cursor:row-resize}.divider:before{content:\"\";position:absolute;inset:0 -5px}:host([orientation=vertical]) .divider:before{inset:-5px 0}.divider:hover,.divider:focus-visible,:host([dragging]) .divider{background:var(--jl-accent)}.divider:focus-visible{box-shadow:var(--jl-focus-ring)}.grip{border:1px solid var(--jl-line-strong);border-radius:var(--jl-radius-pill);background:var(--jl-surface);width:6px;height:28px;transition:border-color var(--jl-fast) var(--jl-ease);position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}:host([orientation=vertical]) .grip{width:28px;height:6px}.divider:hover .grip,.divider:focus-visible .grip,:host([dragging]) .grip{border-color:var(--jl-accent)}:host([dragging]){cursor:col-resize;-webkit-user-select:none;user-select:none}:host([dragging][orientation=vertical]){cursor:row-resize}:host([dragging]) .pane{pointer-events:none}:host([stacked]) .split{grid-template-rows:minmax(0,1fr);grid-template-columns:minmax(0,1fr)}:host([stacked]) .divider,:host([stacked]:not([pane=end])) .end,:host([stacked][pane=end]) .start{display:none}";
2
+ var jl_split_view_default = ":host{height:100%;min-height:0;display:block}.split{grid-template-columns:minmax(0, var(--position,50%)) 1px minmax(0, 1fr);height:100%;display:grid}:host([orientation=vertical]) .split{grid-template-columns:none;grid-template-rows:minmax(0, var(--position,50%)) 1px minmax(0, 1fr)}.pane{min-width:0;min-height:0;position:relative;overflow:auto}.divider{z-index:1;background:var(--jl-line);cursor:col-resize;touch-action:none;transition:background var(--jl-fast) var(--jl-ease);position:relative}:host([orientation=vertical]) .divider{cursor:row-resize}.divider:before{content:\"\";position:absolute;inset:0 -5px}:host([orientation=vertical]) .divider:before{inset:-5px 0}.divider:hover,.divider:focus-visible,:host([dragging]) .divider{background:var(--jl-accent)}.divider:focus-visible{box-shadow:var(--jl-focus-ring)}.grip{border:1px solid var(--jl-line-strong);border-radius:var(--jl-radius-pill);background:var(--jl-surface);width:6px;height:28px;transition:border-color var(--jl-fast) var(--jl-ease);position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}:host([orientation=vertical]) .grip{width:28px;height:6px}.divider:hover .grip,.divider:focus-visible .grip,:host([dragging]) .grip{border-color:var(--jl-accent)}:host([dragging]){cursor:col-resize;-webkit-user-select:none;user-select:none}:host([dragging][orientation=vertical]){cursor:row-resize}:host([dragging]) .pane{pointer-events:none}:host([stacked]) .split{grid-template-rows:minmax(0,1fr);grid-template-columns:minmax(0,1fr)}:host([stacked]) .divider,:host([stacked]:not([pane=end])) .end,:host([stacked][pane=end]) .start{display:none}";
3
3
  export { jl_split_view_default as default };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@syware/jlib",
3
- "version": "0.11.1",
3
+ "version": "0.12.0",
4
4
  "description": "A tree-shakeable component library on Jadis and native Web Components, organised in atomic design",
5
5
  "keywords": [
6
6
  "web-components",