@nonoun/native-dashboard 0.4.9 → 0.4.11

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.
@@ -0,0 +1,8 @@
1
+ import { NSidebarNav } from './sidebar/sidebar-nav-element.ts';
2
+ import { NSidebarNavItem } from './sidebar/sidebar-nav-item-element.ts';
3
+ import { NSidebarGroup } from './sidebar/sidebar-group-element.ts';
4
+ import { NSidebarGroupHeader } from './sidebar/sidebar-group-header-element.ts';
5
+ import { NSidebar } from './sidebar/sidebar-element.ts';
6
+ import { NSidebarItem } from './sidebar/sidebar-item-element.ts';
7
+ export { NSidebarNav, NSidebarNavItem, NSidebarGroup, NSidebarGroupHeader, NSidebar, NSidebarItem };
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAC;AAC/D,OAAO,EAAE,eAAe,EAAE,MAAM,uCAAuC,CAAC;AACxE,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAC;AAChF,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AAcjE,OAAO,EAAE,WAAW,EAAE,eAAe,EAAE,aAAa,EAAE,mBAAmB,EAChE,QAAQ,EAAE,YAAY,EAAE,CAAC"}
@@ -8,7 +8,7 @@
8
8
  :where(n-sidebar-nav-item):not(:defined) { visibility: hidden; }
9
9
 
10
10
  /* ╭──────────────────────────────────────────────────────────╮
11
- │ native-app
11
+ │ native-app
12
12
  │ Full-page layout: collapsible/resizable sidebar aside │
13
13
  │ + content column (breadcrumb, canvas, body, chat). │
14
14
  ╰──────────────────────────────────────────────────────────╯ */
@@ -201,52 +201,27 @@
201
201
  :where(native-app) :where(section.content) > :where(main) > :where(header),
202
202
  :where(native-app) :where(section.content) > :where(main) > :where(section),
203
203
  :where(native-app) :where(section.content) > :where(main) > :where(footer) {
204
- padding: var(--n-dashboard-panel-content-padding, 0);
205
204
  box-sizing: border-box;
206
205
  }
207
206
 
208
- :where(native-app) :where(section.content) > :where(main):has(> header, > footer) {
209
- overflow: hidden;
210
- }
211
-
212
- :where(native-app) :where(section.content) > :where(main):has(> header, > footer) > :where(section) {
213
- flex: 1 1 0%;
214
- min-height: 0;
215
- overflow-y: auto;
216
- scrollbar-width: none;
217
- display: flex;
218
- flex-direction: column;
219
- gap: var(--n-dashboard-panel-content-gap, 0);
220
- }
221
-
222
- :where(native-app) :where(section.content) > :where(main)[show-scrollbar] > :where(section) {
223
- scrollbar-width: thin;
224
- }
225
-
226
207
  :where(native-app) :where(section.content) > :where(main) > :where(header) {
227
- flex: none;
208
+ position: sticky;
209
+ top: 0;
228
210
  border-bottom: 1px solid var(--n-border-muted);
229
211
  background: var(--n-ground);
230
212
  z-index: 1;
231
213
  }
232
214
 
233
215
  :where(native-app) :where(section.content) > :where(main) > :where(footer) {
234
- flex: none;
216
+ position: sticky;
217
+ bottom: 0;
235
218
  border-top: 1px solid var(--n-border-muted);
236
219
  background: var(--n-ground);
237
220
  }
238
221
 
239
- /* Content max-width centering (same as dashboard-panel.css semantic selectors) */
240
- :where(native-app) :where(section.content) > :where(main) > :where(header) > *,
241
- :where(native-app) :where(section.content) > :where(main) > :where(section) > *,
242
- :where(native-app) :where(section.content) > :where(main) > :where(footer) > * {
243
- max-width: var(--n-dashboard-panel-content-max-width, none);
244
- width: 100%;
245
- margin-inline: auto;
246
- }
247
222
 
248
223
  /* Aside panel — semantic equivalent of n-dashboard-panel[aside] */
249
- :where(native-app) :where(section.content) > :where(aside) {
224
+ :where(native-app) :where(section.content) > :where(n-aside) {
250
225
  --n-ground: var(--n-panel);
251
226
 
252
227
  position: relative;
@@ -265,7 +240,7 @@
265
240
  margin var(--n-duration) var(--n-easing);
266
241
  }
267
242
 
268
- :where(native-app) :where(section.content) > :where(aside)[open] {
243
+ :where(native-app) :where(section.content) > :where(n-aside)[open] {
269
244
  width: var(--n-aside-width, 360px);
270
245
  min-width: var(--n-aside-min-width, 280px);
271
246
  margin-inline-start: calc(var(--n-space-k) * var(--n-space));
@@ -275,18 +250,18 @@
275
250
 
276
251
  /* WHY: When n-chat manages its own sub-container padding and scroll,
277
252
  the layout container delegates — no own padding, no own scroll. */
278
- :where(native-app) :where(section.content) > :where(aside)[open]:has(> n-chat) {
253
+ :where(native-app) :where(section.content) > :where(n-aside)[open]:has(> n-chat) {
279
254
  padding: 0;
280
255
  overflow: visible;
281
256
  }
282
257
 
283
258
  /* WHY: Disable width transition while dragging — it fights the pointer. */
284
- :where(native-app) :where(section.content) > :where(aside)[resizing] {
259
+ :where(native-app) :where(section.content) > :where(n-aside)[resizing] {
285
260
  transition: none;
286
261
  }
287
262
 
288
263
  /* Aside resize handle */
289
- :where(native-app) :where(section.content) > :where(aside) :where(.layout-resize-handle) {
264
+ :where(native-app) :where(section.content) > :where(n-aside) :where(.layout-resize-handle) {
290
265
  position: absolute;
291
266
  top: 0;
292
267
  left: 0;
@@ -296,15 +271,12 @@
296
271
  z-index: 1;
297
272
  }
298
273
 
299
- :where(native-app) :where(section.content) > :where(aside) :where(.layout-resize-handle):hover,
300
- :where(native-app) :where(section.content) > :where(aside)[resizing] :where(.layout-resize-handle) {
274
+ :where(native-app) :where(section.content) > :where(n-aside) :where(.layout-resize-handle):hover,
275
+ :where(native-app) :where(section.content) > :where(n-aside)[resizing] :where(.layout-resize-handle) {
301
276
  background: var(--n-border-muted);
302
277
  }
303
278
 
304
- /* Collapsed padding — semantic selectors */
305
- :where(native-app)[collapsed] :where(section.content) {
306
- padding-inline-start: 0;
307
- }
279
+ /* Collapsed — semantic selectors */
308
280
 
309
281
  :where(native-app)[collapsed] > :where(:not([slot])) > :where(nav) {
310
282
  padding-inline-start: 0;
@@ -1120,20 +1092,20 @@
1120
1092
  /* WHY: When n-body is present, delegate overflow to it so
1121
1093
  header/footer stay fixed while body scrolls. */
1122
1094
 
1123
- :where(n-dashboard-panel):has(> .body) {
1095
+ :where(n-dashboard-panel):has(> n-body) {
1124
1096
  overflow: hidden;
1125
1097
  padding: 0;
1126
1098
  }
1127
- :where(n-dashboard-panel) > :where(.body) {
1099
+ :where(n-dashboard-panel) > :where(n-body) {
1128
1100
  overflow-y: auto;
1129
1101
  scrollbar-width: none;
1130
1102
  }
1131
1103
 
1132
- :where(n-dashboard-panel) > :where(header) {
1104
+ :where(n-dashboard-panel) > :where(n-header) {
1133
1105
  border-bottom: 1px solid var(--n-border-muted);
1134
1106
  }
1135
1107
 
1136
- :where(n-dashboard-panel) > :where(footer) {
1108
+ :where(n-dashboard-panel) > :where(n-footer) {
1137
1109
  border-top: 1px solid var(--n-border-muted);
1138
1110
  }
1139
1111
 
@@ -0,0 +1,11 @@
1
+ import { NativeElement } from '@nonoun/native-ui';
2
+ /** Full-page layout with a resizable sidebar aside and content column.
3
+ * Coordinates nav-group flyout popovers when the sidebar is collapsed. */
4
+ export declare class NSidebar extends NativeElement {
5
+ #private;
6
+ static observedAttributes: string[];
7
+ attributeChangedCallback(name: string, old: string | null, val: string | null): void;
8
+ setup(): void;
9
+ teardown(): void;
10
+ }
11
+ //# sourceMappingURL=sidebar-element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sidebar-element.d.ts","sourceRoot":"","sources":["../../src/sidebar/sidebar-element.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAoB,MAAM,mBAAmB,CAAC;AAGpE;2EAC2E;AAC3E,qBAAa,QAAS,SAAQ,aAAa;;IACzC,MAAM,CAAC,kBAAkB,WAAiB;IAS1C,wBAAwB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IASpF,KAAK,IAAI,IAAI;IAwCb,QAAQ,IAAI,IAAI;CAoGjB"}
@@ -0,0 +1,24 @@
1
+ import { NativeElement } from '@nonoun/native-ui';
2
+ /**
3
+ * Collapsible group of navigation items using native details/summary.
4
+ * Exposes `openFlyout()` / `closeFlyout()` for collapsed-sidebar mode —
5
+ * the sidebar layout coordinator decides *when* to call them.
6
+ * @attr {boolean} open - Whether the group is expanded
7
+ */
8
+ export declare class NSidebarGroup extends NativeElement {
9
+ #private;
10
+ static observedAttributes: string[];
11
+ constructor();
12
+ /** Whether the flyout popover is currently open. */
13
+ get flyoutOpen(): boolean;
14
+ get open(): boolean;
15
+ set open(val: boolean);
16
+ attributeChangedCallback(name: string, old: string | null, val: string | null): void;
17
+ setup(): void;
18
+ teardown(): void;
19
+ /** Stamp n-option elements from child nav-items, open the flyout popover. */
20
+ openFlyout(): void;
21
+ /** Clear the flyout and close the popover. Returns focus to the summary. */
22
+ closeFlyout(): void;
23
+ }
24
+ //# sourceMappingURL=sidebar-group-element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sidebar-group-element.d.ts","sourceRoot":"","sources":["../../src/sidebar/sidebar-group-element.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,aAAa,EAAqB,MAAM,mBAAmB,CAAC;AAE7E;;;;;GAKG;AACH,qBAAa,aAAc,SAAQ,aAAa;;IAC9C,MAAM,CAAC,kBAAkB,WAAY;;IAkBrC,oDAAoD;IACpD,IAAI,UAAU,IAAI,OAAO,CAExB;IAED,IAAI,IAAI,IAAI,OAAO,CAElB;IAED,IAAI,IAAI,CAAC,GAAG,EAAE,OAAO,EAGpB;IAED,wBAAwB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IAQpF,KAAK,IAAI,IAAI;IAkEb,QAAQ,IAAI,IAAI;IA2ChB,6EAA6E;IAC7E,UAAU,IAAI,IAAI;IAuClB,4EAA4E;IAC5E,WAAW,IAAI,IAAI;CA+BpB"}
@@ -0,0 +1,7 @@
1
+ import { NativeElement } from '@nonoun/native-ui';
2
+ /** Non-interactive heading label for a navigation group. */
3
+ export declare class NSidebarGroupHeader extends NativeElement {
4
+ constructor();
5
+ setup(): void;
6
+ }
7
+ //# sourceMappingURL=sidebar-group-header-element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sidebar-group-header-element.d.ts","sourceRoot":"","sources":["../../src/sidebar/sidebar-group-header-element.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAO,MAAM,mBAAmB,CAAC;AAEvD,4DAA4D;AAC5D,qBAAa,mBAAoB,SAAQ,aAAa;;IAOpD,KAAK,IAAI,IAAI;CAgBd"}
@@ -0,0 +1,10 @@
1
+ import { NativeElement } from '@nonoun/native-ui';
2
+ /** Generic sidebar row wrapper. Passive by default — provides inline padding for
3
+ * arbitrary content (buttons, links, custom elements). When a child
4
+ * `n-listbox[popover]` is present, wires PopoverController for click-to-toggle. */
5
+ export declare class NSidebarItem extends NativeElement {
6
+ #private;
7
+ setup(): void;
8
+ teardown(): void;
9
+ }
10
+ //# sourceMappingURL=sidebar-item-element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sidebar-item-element.d.ts","sourceRoot":"","sources":["../../src/sidebar/sidebar-item-element.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAqB,MAAM,mBAAmB,CAAC;AAErE;;oFAEoF;AACpF,qBAAa,YAAa,SAAQ,aAAa;;IAI7C,KAAK,IAAI,IAAI;IAYb,QAAQ,IAAI,IAAI;CAmBjB"}
@@ -0,0 +1,20 @@
1
+ import { NativeElement } from '@nonoun/native-ui';
2
+ /**
3
+ * Sidebar navigation with roving focus and selection indicator.
4
+ * @attr {string} value - Currently selected nav item value
5
+ * @attr {boolean} disabled - Disables all nav items
6
+ * @fires native:change - Fired when selection changes with `{ value, label }` detail
7
+ */
8
+ export declare class NSidebarNav extends NativeElement {
9
+ #private;
10
+ static observedAttributes: string[];
11
+ constructor();
12
+ get value(): string | null;
13
+ set value(val: string | null);
14
+ get disabled(): boolean;
15
+ set disabled(val: boolean);
16
+ attributeChangedCallback(name: string, old: string | null, val: string | null): void;
17
+ setup(): void;
18
+ teardown(): void;
19
+ }
20
+ //# sourceMappingURL=sidebar-nav-element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sidebar-nav-element.d.ts","sourceRoot":"","sources":["../../src/sidebar/sidebar-nav-element.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAgE,MAAM,mBAAmB,CAAC;AAGhH;;;;;GAKG;AACH,qBAAa,WAAY,SAAQ,aAAa;;IAC5C,MAAM,CAAC,kBAAkB,WAAyB;;IAalD,IAAI,KAAK,IAAI,MAAM,GAAG,IAAI,CAA+C;IAEzE,IAAI,KAAK,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,EAO3B;IAED,IAAI,QAAQ,IAAI,OAAO,CAAiC;IACxD,IAAI,QAAQ,CAAC,GAAG,EAAE,OAAO,EAA8B;IAEvD,wBAAwB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IAYpF,KAAK,IAAI,IAAI;IAoCb,QAAQ,IAAI,IAAI;CAIjB"}
@@ -0,0 +1,23 @@
1
+ import { NativeElement } from '@nonoun/native-ui';
2
+ /**
3
+ * Selectable navigation item within a nav component.
4
+ * @attr {string} value - Item value emitted on selection
5
+ * @attr {boolean} disabled - Disables this item
6
+ * @attr {string} label - Display label (falls back to text content)
7
+ * @fires native:select - Fired on click with `{ value, label }` detail
8
+ */
9
+ export declare class NSidebarNavItem extends NativeElement {
10
+ #private;
11
+ static observedAttributes: string[];
12
+ constructor();
13
+ get value(): string;
14
+ set value(val: string);
15
+ get disabled(): boolean;
16
+ set disabled(val: boolean);
17
+ get label(): string;
18
+ set label(val: string);
19
+ attributeChangedCallback(name: string, old: string | null, val: string | null): void;
20
+ setup(): void;
21
+ teardown(): void;
22
+ }
23
+ //# sourceMappingURL=sidebar-nav-item-element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sidebar-nav-item-element.d.ts","sourceRoot":"","sources":["../../src/sidebar/sidebar-nav-item-element.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,aAAa,EAAwC,MAAM,mBAAmB,CAAC;AAGhG;;;;;;GAMG;AACH,qBAAa,eAAgB,SAAQ,aAAa;;IAChD,MAAM,CAAC,kBAAkB,WAAkC;;IAc3D,IAAI,KAAK,IAAI,MAAM,CAElB;IAED,IAAI,KAAK,CAAC,GAAG,EAAE,MAAM,EAKpB;IAED,IAAI,QAAQ,IAAI,OAAO,CAAiC;IACxD,IAAI,QAAQ,CAAC,GAAG,EAAE,OAAO,EAA8B;IAEvD,IAAI,KAAK,IAAI,MAAM,CAElB;IAED,IAAI,KAAK,CAAC,GAAG,EAAE,MAAM,EASpB;IAED,wBAAwB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IAiBpF,KAAK,IAAI,IAAI;IAQb,QAAQ,IAAI,IAAI;CAajB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nonoun/native-dashboard",
3
- "version": "0.4.9",
3
+ "version": "0.4.11",
4
4
  "description": "Dashboard layout and navigation components for @nonoun/native-ui",
5
5
  "license": "MIT",
6
6
  "type": "module",