@askrjs/themes 0.2.0 → 0.2.2
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/THEMING.md +1 -1
- package/dist/components/_internal/block-layout.d.ts +1 -0
- package/dist/components/_internal/block-layout.js +2 -0
- package/dist/components/_internal/block-layout.js.map +1 -1
- package/dist/components/catalog.d.ts +33 -15
- package/dist/components/catalog.js +58 -74
- package/dist/components/catalog.js.map +1 -1
- package/dist/components.d.ts +2 -2
- package/dist/themes/default/index.css +71 -70
- package/package.json +2 -1
- package/src/components/_internal/block-layout.ts +3 -0
- package/src/components/catalog.tsx +183 -53
- package/src/themes/default/styles/base/reset.css +4 -0
- package/src/themes/default/styles/display/table.css +32 -31
- package/src/themes/default/styles/display/virtual-table.css +21 -9
- package/src/themes/default/styles/shell/navbar.css +29 -25
- package/templates/theme/styles/base/reset.css +4 -0
- package/templates/theme/styles/display/table.css +32 -31
- package/templates/theme/styles/display/virtual-table.css +21 -9
- package/templates/theme/styles/shell/navbar.css +29 -25
|
@@ -3,6 +3,8 @@ import { Slot } from "@askrjs/askr/foundations";
|
|
|
3
3
|
import type { Ref } from "@askrjs/askr/foundations/utilities";
|
|
4
4
|
import { DialogContent, DialogDescription, DialogTitle } from "@askrjs/ui";
|
|
5
5
|
import { Block } from "./block";
|
|
6
|
+
import type { BlockDivProps, BlockElement, BlockResponsiveValue, BlockSpace } from "./block";
|
|
7
|
+
import type { BlockLayoutProps } from "./_internal/block-layout";
|
|
6
8
|
import { classes } from "./_internal/classes";
|
|
7
9
|
import { mergeProps } from "./_internal/merge-props";
|
|
8
10
|
|
|
@@ -70,7 +72,71 @@ function buttonPart(props: CatalogComponentProps, slot: string, className?: stri
|
|
|
70
72
|
);
|
|
71
73
|
}
|
|
72
74
|
|
|
73
|
-
|
|
75
|
+
type LegacySpace = BlockSpace | "none" | "1" | "2" | "3" | "4" | "5" | "6" | "8";
|
|
76
|
+
type LegacyWrap = boolean | "wrap" | "nowrap";
|
|
77
|
+
|
|
78
|
+
type LegacyLayoutConveniences = {
|
|
79
|
+
gap?: BlockResponsiveValue<LegacySpace>;
|
|
80
|
+
p?: BlockResponsiveValue<LegacySpace>;
|
|
81
|
+
padding?: BlockResponsiveValue<LegacySpace>;
|
|
82
|
+
wrap?: BlockResponsiveValue<LegacyWrap>;
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
type LegacyStructuralProps = Partial<
|
|
86
|
+
Pick<
|
|
87
|
+
BlockDivProps,
|
|
88
|
+
| "children"
|
|
89
|
+
| "class"
|
|
90
|
+
| "className"
|
|
91
|
+
| "style"
|
|
92
|
+
| "ref"
|
|
93
|
+
| "id"
|
|
94
|
+
| "title"
|
|
95
|
+
| "role"
|
|
96
|
+
| "tabIndex"
|
|
97
|
+
| "hidden"
|
|
98
|
+
| "dir"
|
|
99
|
+
| "lang"
|
|
100
|
+
| "onAbort"
|
|
101
|
+
| "onBlur"
|
|
102
|
+
| "onChange"
|
|
103
|
+
| "onClick"
|
|
104
|
+
| "onDblClick"
|
|
105
|
+
| "onFocus"
|
|
106
|
+
| "onInput"
|
|
107
|
+
| "onKeyDown"
|
|
108
|
+
| "onKeyUp"
|
|
109
|
+
| "onMouseDown"
|
|
110
|
+
| "onMouseEnter"
|
|
111
|
+
| "onMouseLeave"
|
|
112
|
+
| "onMouseMove"
|
|
113
|
+
| "onMouseOut"
|
|
114
|
+
| "onMouseOver"
|
|
115
|
+
| "onMouseUp"
|
|
116
|
+
| "onPointerDown"
|
|
117
|
+
| "onPointerDownCapture"
|
|
118
|
+
| "onPointerEnter"
|
|
119
|
+
| "onPointerLeave"
|
|
120
|
+
| "onPointerMove"
|
|
121
|
+
| "onPointerUp"
|
|
122
|
+
| "onScroll"
|
|
123
|
+
| "onSubmit"
|
|
124
|
+
| "onTouchEnd"
|
|
125
|
+
| "onTouchStart"
|
|
126
|
+
| "onWheel"
|
|
127
|
+
>
|
|
128
|
+
> & {
|
|
129
|
+
as?: BlockElement;
|
|
130
|
+
asChild?: boolean;
|
|
131
|
+
[attribute: `aria-${string}`]: BlockDivProps[`aria-${string}`];
|
|
132
|
+
[attribute: `data-${string}`]: BlockDivProps[`data-${string}`];
|
|
133
|
+
};
|
|
134
|
+
|
|
135
|
+
export type LegacyLayoutProps = Omit<BlockLayoutProps, "gap" | "padding" | "wrap"> &
|
|
136
|
+
LegacyStructuralProps &
|
|
137
|
+
LegacyLayoutConveniences;
|
|
138
|
+
|
|
139
|
+
function normalizeLegacySpace(value: LegacySpace): BlockSpace {
|
|
74
140
|
if (value === "none") return "0";
|
|
75
141
|
if (value === "1") return "xs";
|
|
76
142
|
if (value === "2") return "xs";
|
|
@@ -82,63 +148,116 @@ function normalizeLegacySpace(value: unknown): unknown {
|
|
|
82
148
|
return value;
|
|
83
149
|
}
|
|
84
150
|
|
|
85
|
-
function
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
151
|
+
function normalizeLegacyResponsiveSpace(
|
|
152
|
+
value: BlockResponsiveValue<LegacySpace> | undefined,
|
|
153
|
+
): BlockResponsiveValue<BlockSpace> | undefined {
|
|
154
|
+
if (value === undefined) return undefined;
|
|
155
|
+
if (typeof value === "object") {
|
|
156
|
+
return Object.fromEntries(
|
|
157
|
+
Object.entries(value).map(([breakpoint, space]) => [
|
|
158
|
+
breakpoint,
|
|
159
|
+
normalizeLegacySpace(space as LegacySpace),
|
|
160
|
+
]),
|
|
161
|
+
);
|
|
162
|
+
}
|
|
163
|
+
return normalizeLegacySpace(value);
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
function normalizeLegacyWrap(value: LegacyWrap): boolean {
|
|
167
|
+
if (value === "wrap") return true;
|
|
168
|
+
if (value === "nowrap") return false;
|
|
169
|
+
return value;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
function normalizeLegacyResponsiveWrap(
|
|
173
|
+
value: BlockResponsiveValue<LegacyWrap> | undefined,
|
|
174
|
+
): BlockResponsiveValue<boolean> | undefined {
|
|
175
|
+
if (value === undefined) return undefined;
|
|
176
|
+
if (typeof value === "object") {
|
|
177
|
+
return Object.fromEntries(
|
|
178
|
+
Object.entries(value).map(([breakpoint, wrap]) => [
|
|
179
|
+
breakpoint,
|
|
180
|
+
normalizeLegacyWrap(wrap as LegacyWrap),
|
|
181
|
+
]),
|
|
182
|
+
);
|
|
183
|
+
}
|
|
184
|
+
return normalizeLegacyWrap(value);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
const warnedLegacyLayouts = new Set<string>();
|
|
188
|
+
|
|
189
|
+
function warnDeprecatedLayout(component: string, replacement: string) {
|
|
190
|
+
const metaEnvironment = (import.meta as ImportMeta & { env?: { DEV?: boolean } }).env;
|
|
191
|
+
const nodeEnvironment = (
|
|
192
|
+
globalThis as typeof globalThis & { process?: { env?: { NODE_ENV?: string } } }
|
|
193
|
+
).process?.env?.NODE_ENV;
|
|
194
|
+
|
|
195
|
+
if (metaEnvironment?.DEV !== true && nodeEnvironment !== "development") return;
|
|
196
|
+
if (warnedLegacyLayouts.has(component)) return;
|
|
197
|
+
warnedLegacyLayouts.add(component);
|
|
198
|
+
console.warn(`[askr-themes] ${component} is deprecated. ${replacement}`);
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
function layoutAlias(
|
|
202
|
+
component: string,
|
|
203
|
+
replacement: string,
|
|
204
|
+
props: LegacyLayoutProps,
|
|
205
|
+
defaults: Record<string, unknown>,
|
|
206
|
+
): JSX.Element {
|
|
207
|
+
warnDeprecatedLayout(component, replacement);
|
|
208
|
+
const { gap, p, padding, wrap, ...rest } = props as LegacyLayoutProps & Record<string, unknown>;
|
|
93
209
|
const BlockComponent = Block as (blockProps: Record<string, unknown>) => JSX.Element;
|
|
94
|
-
const wrapStyle = wrap
|
|
95
|
-
? {
|
|
96
|
-
...style,
|
|
97
|
-
flexWrap: "wrap",
|
|
98
|
-
}
|
|
99
|
-
: style;
|
|
100
210
|
|
|
101
211
|
return (
|
|
102
212
|
<BlockComponent
|
|
103
213
|
{...defaults}
|
|
104
214
|
{...rest}
|
|
105
|
-
gap={
|
|
106
|
-
padding={padding ??
|
|
107
|
-
|
|
215
|
+
gap={normalizeLegacyResponsiveSpace(gap)}
|
|
216
|
+
padding={normalizeLegacyResponsiveSpace(padding ?? p)}
|
|
217
|
+
wrap={normalizeLegacyResponsiveWrap(wrap)}
|
|
108
218
|
/>
|
|
109
219
|
);
|
|
110
220
|
}
|
|
111
221
|
|
|
112
|
-
/**
|
|
113
|
-
export function Box(props:
|
|
114
|
-
|
|
222
|
+
/** @deprecated Use {@link Block} directly. */
|
|
223
|
+
export function Box(props: LegacyLayoutProps): JSX.Element;
|
|
224
|
+
export function Box(props: LegacyLayoutProps): JSX.Element {
|
|
225
|
+
return layoutAlias("Box", "Use Block directly.", props, {});
|
|
115
226
|
}
|
|
116
227
|
|
|
117
|
-
/**
|
|
118
|
-
export function Stack(props:
|
|
119
|
-
|
|
228
|
+
/** @deprecated Use `<Block direction="column">`. */
|
|
229
|
+
export function Stack(props: LegacyLayoutProps): JSX.Element;
|
|
230
|
+
export function Stack(props: LegacyLayoutProps): JSX.Element {
|
|
231
|
+
return layoutAlias("Stack", 'Use <Block direction="column">.', props, { direction: "column" });
|
|
120
232
|
}
|
|
121
233
|
|
|
122
|
-
/**
|
|
123
|
-
export function Inline(props:
|
|
124
|
-
|
|
234
|
+
/** @deprecated Use `<Block direction="row">`. */
|
|
235
|
+
export function Inline(props: LegacyLayoutProps): JSX.Element;
|
|
236
|
+
export function Inline(props: LegacyLayoutProps): JSX.Element {
|
|
237
|
+
return layoutAlias("Inline", 'Use <Block direction="row">.', props, { direction: "row" });
|
|
125
238
|
}
|
|
126
239
|
|
|
127
|
-
/**
|
|
128
|
-
export function Shell(props:
|
|
240
|
+
/** @deprecated Compose semantic {@link Block} primitives instead. */
|
|
241
|
+
export function Shell(props: LegacyLayoutProps & { variant?: string }): JSX.Element;
|
|
242
|
+
export function Shell(props: LegacyLayoutProps & { variant?: string }): JSX.Element {
|
|
129
243
|
const { variant: _variant, ...rest } = props;
|
|
130
244
|
void _variant;
|
|
131
|
-
return layoutAlias(rest, {});
|
|
245
|
+
return layoutAlias("Shell", "Compose semantic Block primitives instead.", rest, {});
|
|
132
246
|
}
|
|
133
247
|
|
|
134
|
-
/**
|
|
135
|
-
export function ShellNav(props:
|
|
136
|
-
|
|
248
|
+
/** @deprecated Use `<Block as="nav">`. */
|
|
249
|
+
export function ShellNav(props: LegacyLayoutProps): JSX.Element;
|
|
250
|
+
export function ShellNav(props: LegacyLayoutProps): JSX.Element {
|
|
251
|
+
return layoutAlias("ShellNav", 'Use <Block as="nav">.', props, {});
|
|
137
252
|
}
|
|
138
253
|
|
|
139
|
-
/**
|
|
140
|
-
export function ShellMain(props:
|
|
141
|
-
|
|
254
|
+
/** @deprecated Use `<Block as="main" grow>`. */
|
|
255
|
+
export function ShellMain(props: LegacyLayoutProps): JSX.Element;
|
|
256
|
+
export function ShellMain(props: LegacyLayoutProps): JSX.Element {
|
|
257
|
+
return layoutAlias("ShellMain", 'Use <Block as="main" grow>.', props, {
|
|
258
|
+
as: "main",
|
|
259
|
+
grow: true,
|
|
260
|
+
});
|
|
142
261
|
}
|
|
143
262
|
|
|
144
263
|
/** Renders the `alert-title` part of the shadcn-compatible catalog primitives. */
|
|
@@ -157,7 +276,14 @@ export function AlertDescription(props: CatalogComponentProps): JSX.Element {
|
|
|
157
276
|
|
|
158
277
|
/** Renders the `breadcrumb` part of the shadcn-compatible catalog primitives. */
|
|
159
278
|
export function Breadcrumb(props: CatalogComponentProps): JSX.Element {
|
|
160
|
-
return catalogPart(
|
|
279
|
+
return catalogPart(
|
|
280
|
+
{ "aria-label": "Breadcrumb", ...props },
|
|
281
|
+
{
|
|
282
|
+
slot: "breadcrumb",
|
|
283
|
+
element: "nav",
|
|
284
|
+
role: "navigation",
|
|
285
|
+
},
|
|
286
|
+
);
|
|
161
287
|
}
|
|
162
288
|
|
|
163
289
|
/** Renders the `breadcrumb-list` part of the shadcn-compatible catalog primitives. */
|
|
@@ -252,12 +378,12 @@ export function CalendarNextButton(props: CatalogComponentProps): JSX.Element {
|
|
|
252
378
|
|
|
253
379
|
/** Renders the `calendar-grid` part of the shadcn-compatible catalog primitives. */
|
|
254
380
|
export function CalendarGrid(props: CatalogComponentProps): JSX.Element {
|
|
255
|
-
return catalogPart(props, { slot: "calendar-grid"
|
|
381
|
+
return catalogPart(props, { slot: "calendar-grid" });
|
|
256
382
|
}
|
|
257
383
|
|
|
258
384
|
/** Renders the `calendar-head` part of the shadcn-compatible catalog primitives. */
|
|
259
385
|
export function CalendarHead(props: CatalogComponentProps): JSX.Element {
|
|
260
|
-
return catalogPart(props, { slot: "calendar-head"
|
|
386
|
+
return catalogPart(props, { slot: "calendar-head" });
|
|
261
387
|
}
|
|
262
388
|
|
|
263
389
|
/** Renders the `calendar-body` part of the shadcn-compatible catalog primitives. */
|
|
@@ -267,12 +393,12 @@ export function CalendarBody(props: CatalogComponentProps): JSX.Element {
|
|
|
267
393
|
|
|
268
394
|
/** Renders the `calendar-row` part of the shadcn-compatible catalog primitives. */
|
|
269
395
|
export function CalendarRow(props: CatalogComponentProps): JSX.Element {
|
|
270
|
-
return catalogPart(props, { slot: "calendar-row"
|
|
396
|
+
return catalogPart(props, { slot: "calendar-row" });
|
|
271
397
|
}
|
|
272
398
|
|
|
273
399
|
/** Renders the `calendar-cell` part of the shadcn-compatible catalog primitives. */
|
|
274
400
|
export function CalendarCell(props: CatalogComponentProps): JSX.Element {
|
|
275
|
-
return catalogPart(props, { slot: "calendar-cell"
|
|
401
|
+
return catalogPart(props, { slot: "calendar-cell" });
|
|
276
402
|
}
|
|
277
403
|
|
|
278
404
|
/** Renders a single selectable day cell in the calendar grid, with selection/range/today state exposed as data attributes. */
|
|
@@ -292,7 +418,6 @@ export function CalendarDay(
|
|
|
292
418
|
{
|
|
293
419
|
disabled,
|
|
294
420
|
"aria-disabled": disabled ? "true" : undefined,
|
|
295
|
-
"aria-selected": selected ? "true" : undefined,
|
|
296
421
|
"data-disabled": disabled ? "" : undefined,
|
|
297
422
|
"data-outside": outside ? "true" : undefined,
|
|
298
423
|
"data-range-end": rangeEnd ? "true" : undefined,
|
|
@@ -338,14 +463,13 @@ export function Combobox(props: CatalogComponentProps): JSX.Element {
|
|
|
338
463
|
return catalogPart(props, { slot: "combobox" });
|
|
339
464
|
}
|
|
340
465
|
|
|
341
|
-
/**
|
|
466
|
+
/** Styling-only combobox input; consumers supplying behavior also own its complete ARIA contract. */
|
|
342
467
|
export function ComboboxInput(props: CatalogComponentProps): JSX.Element {
|
|
343
468
|
const { ref, class: className, ...rest } = props;
|
|
344
469
|
const finalProps = mergeProps(rest, {
|
|
345
470
|
ref,
|
|
346
471
|
class: classes("input", className),
|
|
347
472
|
"data-slot": "combobox-input",
|
|
348
|
-
role: "combobox",
|
|
349
473
|
});
|
|
350
474
|
|
|
351
475
|
return <input {...finalProps} />;
|
|
@@ -353,12 +477,12 @@ export function ComboboxInput(props: CatalogComponentProps): JSX.Element {
|
|
|
353
477
|
|
|
354
478
|
/** Renders the `combobox-list` part of the shadcn-compatible catalog primitives. */
|
|
355
479
|
export function ComboboxList(props: CatalogComponentProps): JSX.Element {
|
|
356
|
-
return catalogPart(props, { slot: "combobox-list"
|
|
480
|
+
return catalogPart(props, { slot: "combobox-list" });
|
|
357
481
|
}
|
|
358
482
|
|
|
359
483
|
/** Renders the `combobox-option` part of the shadcn-compatible catalog primitives. */
|
|
360
484
|
export function ComboboxOption(props: CatalogComponentProps): JSX.Element {
|
|
361
|
-
return catalogPart(props, { slot: "combobox-option"
|
|
485
|
+
return catalogPart(props, { slot: "combobox-option" });
|
|
362
486
|
}
|
|
363
487
|
|
|
364
488
|
/** Renders the `command` part of the shadcn-compatible catalog primitives. */
|
|
@@ -390,7 +514,7 @@ export function CommandHeader(props: CatalogComponentProps): JSX.Element {
|
|
|
390
514
|
|
|
391
515
|
/** Renders the `command-list` part of the shadcn-compatible catalog primitives. */
|
|
392
516
|
export function CommandList(props: CatalogComponentProps): JSX.Element {
|
|
393
|
-
return catalogPart(props, { slot: "command-list"
|
|
517
|
+
return catalogPart(props, { slot: "command-list" });
|
|
394
518
|
}
|
|
395
519
|
|
|
396
520
|
/** Renders the `command-empty` part of the shadcn-compatible catalog primitives. */
|
|
@@ -416,12 +540,11 @@ export function CommandItem(
|
|
|
416
540
|
return catalogPart(
|
|
417
541
|
{
|
|
418
542
|
"aria-disabled": disabled ? "true" : undefined,
|
|
419
|
-
"aria-selected": selected || active ? "true" : undefined,
|
|
420
543
|
"data-disabled": disabled ? "" : undefined,
|
|
421
544
|
"data-selected": selected || active ? "true" : undefined,
|
|
422
545
|
...rest,
|
|
423
546
|
},
|
|
424
|
-
{ slot: "command-item"
|
|
547
|
+
{ slot: "command-item" },
|
|
425
548
|
);
|
|
426
549
|
}
|
|
427
550
|
|
|
@@ -682,7 +805,14 @@ export function NavigationMenuIndicator(props: CatalogComponentProps): JSX.Eleme
|
|
|
682
805
|
|
|
683
806
|
/** Renders the `pagination` part of the shadcn-compatible catalog primitives. */
|
|
684
807
|
export function Pagination(props: CatalogComponentProps): JSX.Element {
|
|
685
|
-
return catalogPart(
|
|
808
|
+
return catalogPart(
|
|
809
|
+
{ "aria-label": "Pagination", ...props },
|
|
810
|
+
{
|
|
811
|
+
slot: "pagination",
|
|
812
|
+
element: "nav",
|
|
813
|
+
role: "navigation",
|
|
814
|
+
},
|
|
815
|
+
);
|
|
686
816
|
}
|
|
687
817
|
|
|
688
818
|
/** Renders the `pagination-content` part of the shadcn-compatible catalog primitives. */
|
|
@@ -747,12 +877,12 @@ export function ResizablePanel(props: CatalogComponentProps): JSX.Element {
|
|
|
747
877
|
|
|
748
878
|
/** Styling-only separator slot; it does not implement resizing, pointer dragging, or keyboard controls. */
|
|
749
879
|
export function ResizableHandle(props: CatalogComponentProps): JSX.Element {
|
|
750
|
-
return catalogPart(props, { slot: "resizable-handle"
|
|
880
|
+
return catalogPart(props, { slot: "resizable-handle" });
|
|
751
881
|
}
|
|
752
882
|
|
|
753
883
|
/** Renders the `tabs-list` part of the shadcn-compatible catalog primitives. */
|
|
754
884
|
export function TabsList(props: CatalogComponentProps): JSX.Element {
|
|
755
|
-
return catalogPart(props, { slot: "tabs-list"
|
|
885
|
+
return catalogPart(props, { slot: "tabs-list" });
|
|
756
886
|
}
|
|
757
887
|
|
|
758
888
|
/** Renders the `tabs-content` part of the shadcn-compatible catalog primitives. */
|
|
@@ -762,7 +892,7 @@ export function TabsTrigger(props: CatalogComponentProps): JSX.Element {
|
|
|
762
892
|
|
|
763
893
|
/** Renders the `tabs-content` part of the shadcn-compatible catalog primitives. */
|
|
764
894
|
export function TabsContent(props: CatalogComponentProps): JSX.Element {
|
|
765
|
-
return catalogPart(props, { slot: "tabs-content"
|
|
895
|
+
return catalogPart(props, { slot: "tabs-content" });
|
|
766
896
|
}
|
|
767
897
|
|
|
768
898
|
/** Sheet variant of the dialog content part; defaults to sliding in from the right. */
|
|
@@ -3,13 +3,12 @@
|
|
|
3
3
|
min-inline-size: 0;
|
|
4
4
|
border-collapse: collapse;
|
|
5
5
|
border-spacing: 0;
|
|
6
|
-
table-layout:
|
|
6
|
+
table-layout: auto;
|
|
7
7
|
border: 0;
|
|
8
8
|
border-radius: 0;
|
|
9
9
|
background: transparent;
|
|
10
10
|
color: var(--ak-color-text);
|
|
11
11
|
box-shadow: none;
|
|
12
|
-
overflow: hidden;
|
|
13
12
|
}
|
|
14
13
|
|
|
15
14
|
:where([data-slot="data-table"]) {
|
|
@@ -19,16 +18,16 @@
|
|
|
19
18
|
}
|
|
20
19
|
|
|
21
20
|
:where([data-slot="table-caption"]) {
|
|
22
|
-
padding:
|
|
21
|
+
padding-block-start: var(--ak-space-md);
|
|
23
22
|
color: var(--ak-color-text-muted);
|
|
24
23
|
font-size: var(--ak-font-size-sm);
|
|
25
24
|
line-height: var(--ak-line-height-normal);
|
|
26
25
|
text-align: start;
|
|
27
|
-
caption-side:
|
|
26
|
+
caption-side: bottom;
|
|
28
27
|
}
|
|
29
28
|
|
|
30
29
|
:where([data-slot="table-head"]) {
|
|
31
|
-
background:
|
|
30
|
+
background: transparent;
|
|
32
31
|
}
|
|
33
32
|
|
|
34
33
|
:where([data-slot="table-body"]) {
|
|
@@ -36,58 +35,60 @@
|
|
|
36
35
|
}
|
|
37
36
|
|
|
38
37
|
:where([data-slot="table-foot"]) {
|
|
39
|
-
|
|
38
|
+
border-block-start: 1px solid var(--ak-color-border);
|
|
39
|
+
background: color-mix(in srgb, var(--ak-color-surface-muted) 50%, transparent);
|
|
40
|
+
font-weight: var(--ak-font-weight-medium);
|
|
40
41
|
}
|
|
41
42
|
|
|
42
43
|
:where([data-slot="table-row"]) {
|
|
43
44
|
background: inherit;
|
|
45
|
+
border-block-end: 1px solid var(--ak-color-border);
|
|
44
46
|
transition: background var(--ak-duration-fast) var(--ak-ease-standard);
|
|
45
47
|
}
|
|
46
48
|
|
|
47
|
-
:where(
|
|
48
|
-
|
|
49
|
+
:where(
|
|
50
|
+
[data-slot="table-row"]:hover,
|
|
51
|
+
[data-slot="table-row"][aria-expanded="true"],
|
|
52
|
+
[data-slot="table-row"][data-state="selected"]
|
|
53
|
+
) {
|
|
54
|
+
background: color-mix(in srgb, var(--ak-color-surface-muted) 50%, transparent);
|
|
49
55
|
}
|
|
50
56
|
|
|
51
57
|
:where([data-slot="table-header-cell"]),
|
|
52
58
|
:where([data-slot="table-cell"]) {
|
|
53
|
-
padding: var(--ak-space-sm);
|
|
54
|
-
border-block-end: 1px solid var(--ak-color-border);
|
|
59
|
+
padding: var(--ak-space-sm) var(--ak-space-xs);
|
|
55
60
|
color: var(--ak-color-text);
|
|
56
61
|
font-size: var(--ak-font-size-sm);
|
|
57
62
|
line-height: var(--ak-line-height-normal);
|
|
58
63
|
text-align: start;
|
|
59
|
-
vertical-align:
|
|
60
|
-
|
|
64
|
+
vertical-align: middle;
|
|
65
|
+
white-space: normal;
|
|
61
66
|
}
|
|
62
67
|
|
|
63
|
-
:where([data-slot="table-body"] [data-slot="table-row"]:last-child
|
|
68
|
+
:where([data-slot="table-body"] [data-slot="table-row"]:last-child),
|
|
69
|
+
:where([data-slot="table-foot"] [data-slot="table-row"]:last-child) {
|
|
64
70
|
border-block-end: 0;
|
|
65
71
|
}
|
|
66
72
|
|
|
67
73
|
:where([data-slot="table-header-cell"]) {
|
|
68
|
-
|
|
69
|
-
font-weight: var(--ak-font-weight-
|
|
70
|
-
letter-spacing: 0;
|
|
71
|
-
overflow-wrap: normal;
|
|
72
|
-
text-transform: none;
|
|
73
|
-
word-break: normal;
|
|
74
|
-
white-space: normal;
|
|
74
|
+
block-size: 2.5rem;
|
|
75
|
+
font-weight: var(--ak-font-weight-medium);
|
|
75
76
|
}
|
|
76
77
|
|
|
77
78
|
:where([data-slot="table-cell"]) {
|
|
78
79
|
font-weight: var(--ak-font-weight-regular);
|
|
79
80
|
}
|
|
80
81
|
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
}
|
|
82
|
+
:where(
|
|
83
|
+
[data-slot="table-header-cell"]:has([role="checkbox"]),
|
|
84
|
+
[data-slot="table-cell"]:has([role="checkbox"])
|
|
85
|
+
) {
|
|
86
|
+
padding-inline-end: 0;
|
|
87
|
+
}
|
|
88
88
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
89
|
+
:where(
|
|
90
|
+
[data-slot="table-header-cell"] > [role="checkbox"],
|
|
91
|
+
[data-slot="table-cell"] > [role="checkbox"]
|
|
92
|
+
) {
|
|
93
|
+
transform: translateY(2px);
|
|
93
94
|
}
|
|
@@ -30,11 +30,11 @@
|
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
:where([data-slot="virtual-table-head"]) {
|
|
33
|
-
background: var(--ak-color-surface
|
|
33
|
+
background: var(--ak-color-surface);
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
:where([data-slot="virtual-table-header-row"]) {
|
|
37
|
-
background:
|
|
37
|
+
background: var(--ak-color-surface);
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
:where([data-slot="virtual-table-body"]) {
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
:where([data-slot="virtual-table-header-cell"], [data-slot="virtual-table-cell"]) {
|
|
45
|
-
padding: var(--ak-space-sm);
|
|
45
|
+
padding: var(--ak-space-sm) var(--ak-space-xs);
|
|
46
46
|
border-block-end: 1px solid var(--ak-color-border);
|
|
47
47
|
color: var(--ak-color-text);
|
|
48
48
|
font-size: var(--ak-font-size-sm);
|
|
@@ -55,10 +55,8 @@
|
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
:where([data-slot="virtual-table-header-cell"]) {
|
|
58
|
-
|
|
59
|
-
font-weight: var(--ak-font-weight-
|
|
60
|
-
letter-spacing: 0;
|
|
61
|
-
text-transform: none;
|
|
58
|
+
block-size: 2.5rem;
|
|
59
|
+
font-weight: var(--ak-font-weight-medium);
|
|
62
60
|
}
|
|
63
61
|
|
|
64
62
|
:where([data-slot="virtual-table-row"]) {
|
|
@@ -69,11 +67,11 @@
|
|
|
69
67
|
}
|
|
70
68
|
|
|
71
69
|
:where([data-slot="virtual-table-row"]:hover) {
|
|
72
|
-
background: var(--ak-color-
|
|
70
|
+
background: color-mix(in srgb, var(--ak-color-surface-muted) 50%, transparent);
|
|
73
71
|
}
|
|
74
72
|
|
|
75
73
|
:where([data-slot="virtual-table-row"][data-selected="true"]) {
|
|
76
|
-
background: var(--ak-color-
|
|
74
|
+
background: color-mix(in srgb, var(--ak-color-surface-muted) 50%, transparent);
|
|
77
75
|
color: var(--ak-color-text);
|
|
78
76
|
}
|
|
79
77
|
|
|
@@ -87,6 +85,20 @@
|
|
|
87
85
|
min-inline-size: 0;
|
|
88
86
|
}
|
|
89
87
|
|
|
88
|
+
:where(
|
|
89
|
+
[data-slot="virtual-table-header-cell"]:has([role="checkbox"]),
|
|
90
|
+
[data-slot="virtual-table-cell"]:has([role="checkbox"])
|
|
91
|
+
) {
|
|
92
|
+
padding-inline-end: 0;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
:where(
|
|
96
|
+
[data-slot="virtual-table-header-cell"] > [role="checkbox"],
|
|
97
|
+
[data-slot="virtual-table-cell"] > [role="checkbox"]
|
|
98
|
+
) {
|
|
99
|
+
transform: translateY(2px);
|
|
100
|
+
}
|
|
101
|
+
|
|
90
102
|
@media (max-width: 30rem) {
|
|
91
103
|
:where([data-slot="virtual-table-header-cell"], [data-slot="virtual-table-cell"]) {
|
|
92
104
|
padding: var(--ak-space-sm) var(--ak-space-xs);
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
align-items: stretch;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
:where([data-slot="navbar"]
|
|
21
|
+
:where([data-slot="navbar"] [data-slot="nav-group"]:not([data-align="end"])) {
|
|
22
22
|
grid-column: 2;
|
|
23
23
|
justify-self: center;
|
|
24
24
|
}
|
|
@@ -187,14 +187,15 @@
|
|
|
187
187
|
}
|
|
188
188
|
|
|
189
189
|
@media (min-width: 40rem) {
|
|
190
|
+
:where([data-slot="navbar"][data-collapse-at="sm"]) :where([data-slot="navbar-collapse"]) {
|
|
191
|
+
display: block;
|
|
192
|
+
grid-column: 2 / -1;
|
|
193
|
+
width: 100%;
|
|
194
|
+
}
|
|
195
|
+
|
|
190
196
|
:where([data-slot="navbar"][data-collapse-at="sm"]) :where([data-slot="navbar-content"]) {
|
|
191
197
|
display: flex;
|
|
192
|
-
|
|
193
|
-
justify-self: center;
|
|
194
|
-
flex-basis: auto;
|
|
195
|
-
flex-direction: row;
|
|
196
|
-
align-items: center;
|
|
197
|
-
width: auto;
|
|
198
|
+
width: 100%;
|
|
198
199
|
}
|
|
199
200
|
|
|
200
201
|
:where([data-slot="navbar"][data-collapse-at="sm"])
|
|
@@ -214,14 +215,15 @@
|
|
|
214
215
|
}
|
|
215
216
|
|
|
216
217
|
@media (min-width: 48rem) {
|
|
218
|
+
:where([data-slot="navbar"][data-collapse-at="md"]) :where([data-slot="navbar-collapse"]) {
|
|
219
|
+
display: block;
|
|
220
|
+
grid-column: 2 / -1;
|
|
221
|
+
width: 100%;
|
|
222
|
+
}
|
|
223
|
+
|
|
217
224
|
:where([data-slot="navbar"][data-collapse-at="md"]) :where([data-slot="navbar-content"]) {
|
|
218
225
|
display: flex;
|
|
219
|
-
|
|
220
|
-
justify-self: center;
|
|
221
|
-
flex-basis: auto;
|
|
222
|
-
flex-direction: row;
|
|
223
|
-
align-items: center;
|
|
224
|
-
width: auto;
|
|
226
|
+
width: 100%;
|
|
225
227
|
}
|
|
226
228
|
|
|
227
229
|
:where([data-slot="navbar"][data-collapse-at="md"])
|
|
@@ -241,14 +243,15 @@
|
|
|
241
243
|
}
|
|
242
244
|
|
|
243
245
|
@media (min-width: 64rem) {
|
|
246
|
+
:where([data-slot="navbar"][data-collapse-at="lg"]) :where([data-slot="navbar-collapse"]) {
|
|
247
|
+
display: block;
|
|
248
|
+
grid-column: 2 / -1;
|
|
249
|
+
width: 100%;
|
|
250
|
+
}
|
|
251
|
+
|
|
244
252
|
:where([data-slot="navbar"][data-collapse-at="lg"]) :where([data-slot="navbar-content"]) {
|
|
245
253
|
display: flex;
|
|
246
|
-
|
|
247
|
-
justify-self: center;
|
|
248
|
-
flex-basis: auto;
|
|
249
|
-
flex-direction: row;
|
|
250
|
-
align-items: center;
|
|
251
|
-
width: auto;
|
|
254
|
+
width: 100%;
|
|
252
255
|
}
|
|
253
256
|
|
|
254
257
|
:where([data-slot="navbar"][data-collapse-at="lg"])
|
|
@@ -268,14 +271,15 @@
|
|
|
268
271
|
}
|
|
269
272
|
|
|
270
273
|
@media (min-width: 80rem) {
|
|
274
|
+
:where([data-slot="navbar"][data-collapse-at="xl"]) :where([data-slot="navbar-collapse"]) {
|
|
275
|
+
display: block;
|
|
276
|
+
grid-column: 2 / -1;
|
|
277
|
+
width: 100%;
|
|
278
|
+
}
|
|
279
|
+
|
|
271
280
|
:where([data-slot="navbar"][data-collapse-at="xl"]) :where([data-slot="navbar-content"]) {
|
|
272
281
|
display: flex;
|
|
273
|
-
|
|
274
|
-
justify-self: center;
|
|
275
|
-
flex-basis: auto;
|
|
276
|
-
flex-direction: row;
|
|
277
|
-
align-items: center;
|
|
278
|
-
width: auto;
|
|
282
|
+
width: 100%;
|
|
279
283
|
}
|
|
280
284
|
|
|
281
285
|
:where([data-slot="navbar"][data-collapse-at="xl"])
|