@x33025/sveltely 0.0.56 → 0.0.57
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/dist/components/AnimatedNumber.demo.svelte +28 -0
- package/dist/components/AnimatedNumber.demo.svelte.d.ts +9 -0
- package/dist/components/AsyncButton.demo.svelte +24 -0
- package/dist/components/AsyncButton.demo.svelte.d.ts +23 -0
- package/dist/components/ChipInput.demo.svelte +18 -0
- package/dist/components/ChipInput.demo.svelte.d.ts +9 -0
- package/dist/components/Local/ComponentGrid.svelte +53 -0
- package/dist/components/Local/ComponentGrid.svelte.d.ts +14 -0
- package/dist/components/Local/HeroCard.svelte +51 -0
- package/dist/components/Local/HeroCard.svelte.d.ts +11 -0
- package/dist/components/NavigationStack/NavigationStack.svelte +8 -7
- package/dist/components/NavigationStack/NavigationStack.svelte.d.ts +1 -0
- package/dist/components/NavigationStack/Toolbar.svelte +5 -4
- package/dist/components/NavigationStack/Toolbar.svelte.d.ts +1 -0
- package/dist/components/Pagination.demo.svelte +27 -0
- package/dist/components/Pagination.demo.svelte.d.ts +10 -0
- package/dist/components/Popover/Popover.demo.svelte +35 -0
- package/dist/components/Popover/Popover.demo.svelte.d.ts +8 -0
- package/dist/components/Popover/Popover.svelte +11 -3
- package/dist/components/SearchInput.demo.svelte +18 -0
- package/dist/components/SearchInput.demo.svelte.d.ts +9 -0
- package/dist/components/SearchInput.svelte +39 -0
- package/dist/components/SearchInput.svelte.d.ts +9 -0
- package/dist/components/SegmentedPicker.demo.svelte +24 -0
- package/dist/components/SegmentedPicker.demo.svelte.d.ts +9 -0
- package/dist/components/SegmentedPicker.svelte +11 -1
- package/dist/components/SegmentedPicker.svelte.d.ts +1 -0
- package/dist/components/Sheet/Sheet.demo.svelte +38 -0
- package/dist/components/Sheet/Sheet.demo.svelte.d.ts +8 -0
- package/dist/components/Slider.demo.svelte +18 -0
- package/dist/components/Slider.demo.svelte.d.ts +9 -0
- package/dist/components/Spinner.demo.svelte +12 -0
- package/dist/components/Spinner.demo.svelte.d.ts +23 -0
- package/dist/components/Tooltip.demo.svelte +16 -0
- package/dist/components/Tooltip.demo.svelte.d.ts +23 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/style/index.css +75 -1
- package/dist/style.css +174 -56
- package/package.json +1 -1
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'AnimatedNumber',
|
|
4
|
+
description: 'Spring-driven numeric transitions.',
|
|
5
|
+
isProminent: false
|
|
6
|
+
};
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<script lang="ts">
|
|
10
|
+
import AnimatedNumber from './AnimatedNumber.svelte';
|
|
11
|
+
|
|
12
|
+
let value = $state(1234);
|
|
13
|
+
|
|
14
|
+
const bump = () => {
|
|
15
|
+
value += Math.round(100 + Math.random() * 900);
|
|
16
|
+
};
|
|
17
|
+
</script>
|
|
18
|
+
|
|
19
|
+
<div class="vstack center gap-3">
|
|
20
|
+
<AnimatedNumber {value} class="text-3xl font-semibold text-zinc-900" />
|
|
21
|
+
<button
|
|
22
|
+
type="button"
|
|
23
|
+
class="rounded-full bg-zinc-900 px-3 py-2 text-sm text-white"
|
|
24
|
+
onclick={bump}
|
|
25
|
+
>
|
|
26
|
+
Change number
|
|
27
|
+
</button>
|
|
28
|
+
</div>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
isProminent: boolean;
|
|
5
|
+
};
|
|
6
|
+
import AnimatedNumber from './AnimatedNumber.svelte';
|
|
7
|
+
declare const AnimatedNumber: import("svelte").Component<Record<string, never>, {}, "">;
|
|
8
|
+
type AnimatedNumber = ReturnType<typeof AnimatedNumber>;
|
|
9
|
+
export default AnimatedNumber;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'AsyncButton',
|
|
4
|
+
description: 'Async action button with loading and error states.'
|
|
5
|
+
};
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<script lang="ts">
|
|
9
|
+
import { SaveIcon } from '@lucide/svelte';
|
|
10
|
+
import AsyncButton from './AsyncButton.svelte';
|
|
11
|
+
|
|
12
|
+
const runDemo = async () => {
|
|
13
|
+
await new Promise<void>((resolve) => {
|
|
14
|
+
setTimeout(resolve, 1000);
|
|
15
|
+
});
|
|
16
|
+
};
|
|
17
|
+
</script>
|
|
18
|
+
|
|
19
|
+
<AsyncButton
|
|
20
|
+
icon={SaveIcon}
|
|
21
|
+
label="Run async action"
|
|
22
|
+
action={runDemo}
|
|
23
|
+
class="rounded-full bg-zinc-900 px-3 py-2 text-sm text-white"
|
|
24
|
+
/>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
};
|
|
5
|
+
import AsyncButton from './AsyncButton.svelte';
|
|
6
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
7
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
8
|
+
$$bindings?: Bindings;
|
|
9
|
+
} & Exports;
|
|
10
|
+
(internal: unknown, props: {
|
|
11
|
+
$$events?: Events;
|
|
12
|
+
$$slots?: Slots;
|
|
13
|
+
}): Exports & {
|
|
14
|
+
$set?: any;
|
|
15
|
+
$on?: any;
|
|
16
|
+
};
|
|
17
|
+
z_$$bindings?: Bindings;
|
|
18
|
+
}
|
|
19
|
+
declare const AsyncButton: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
|
|
20
|
+
[evt: string]: CustomEvent<any>;
|
|
21
|
+
}, {}, {}, string>;
|
|
22
|
+
type AsyncButton = InstanceType<typeof AsyncButton>;
|
|
23
|
+
export default AsyncButton;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'ChipInput',
|
|
4
|
+
description: 'Editable chip list with bindable tags.',
|
|
5
|
+
isProminent: false
|
|
6
|
+
};
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<script lang="ts">
|
|
10
|
+
import ChipInput from './ChipInput.svelte';
|
|
11
|
+
|
|
12
|
+
let tags = $state(['svelte', 'ui', 'search']);
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<div class="vstack w-full max-w-sm gap-2">
|
|
16
|
+
<ChipInput bind:tags />
|
|
17
|
+
<p class="text-xs text-zinc-500">Tags: {tags.join(', ')}</p>
|
|
18
|
+
</div>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
isProminent: boolean;
|
|
5
|
+
};
|
|
6
|
+
import ChipInput from './ChipInput.svelte';
|
|
7
|
+
declare const ChipInput: import("svelte").Component<Record<string, never>, {}, "">;
|
|
8
|
+
type ChipInput = ReturnType<typeof ChipInput>;
|
|
9
|
+
export default ChipInput;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Component } from 'svelte';
|
|
3
|
+
import HeroCard from './HeroCard.svelte';
|
|
4
|
+
|
|
5
|
+
type DemoEntry = {
|
|
6
|
+
component: Component;
|
|
7
|
+
name: string;
|
|
8
|
+
description: string;
|
|
9
|
+
isProminent: boolean;
|
|
10
|
+
columnSpan?: 1 | 2;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
type Props = {
|
|
14
|
+
demos: DemoEntry[];
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
let { demos }: Props = $props();
|
|
18
|
+
</script>
|
|
19
|
+
|
|
20
|
+
<div
|
|
21
|
+
class="component-grid grid gap-4 overflow-auto p-6 md:grid-flow-dense md:grid-cols-2 xl:grid-cols-3"
|
|
22
|
+
>
|
|
23
|
+
{#each demos as entry}
|
|
24
|
+
{@const DemoComponent = entry.component}
|
|
25
|
+
<HeroCard
|
|
26
|
+
title={entry.name}
|
|
27
|
+
description={entry.description}
|
|
28
|
+
isProminent={entry.isProminent}
|
|
29
|
+
columnSpan={entry.columnSpan ?? 1}
|
|
30
|
+
>
|
|
31
|
+
<DemoComponent />
|
|
32
|
+
</HeroCard>
|
|
33
|
+
{/each}
|
|
34
|
+
</div>
|
|
35
|
+
|
|
36
|
+
<style>
|
|
37
|
+
.component-grid :global(.hero-card) {
|
|
38
|
+
min-height: 14rem;
|
|
39
|
+
border: 1px solid rgb(228 228 231);
|
|
40
|
+
border-radius: 1rem;
|
|
41
|
+
box-shadow: 0 1px 2px rgb(0 0 0 / 0.05);
|
|
42
|
+
align-items: stretch;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.component-grid :global(.hero-card h1) {
|
|
46
|
+
font-size: 1rem;
|
|
47
|
+
line-height: 1.5rem;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.component-grid :global(.hero-card p) {
|
|
51
|
+
max-width: none;
|
|
52
|
+
}
|
|
53
|
+
</style>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Component } from 'svelte';
|
|
2
|
+
type DemoEntry = {
|
|
3
|
+
component: Component;
|
|
4
|
+
name: string;
|
|
5
|
+
description: string;
|
|
6
|
+
isProminent: boolean;
|
|
7
|
+
columnSpan?: 1 | 2;
|
|
8
|
+
};
|
|
9
|
+
type Props = {
|
|
10
|
+
demos: DemoEntry[];
|
|
11
|
+
};
|
|
12
|
+
declare const ComponentGrid: Component<Props, {}, "">;
|
|
13
|
+
type ComponentGrid = ReturnType<typeof ComponentGrid>;
|
|
14
|
+
export default ComponentGrid;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Snippet } from 'svelte';
|
|
3
|
+
|
|
4
|
+
type Props = {
|
|
5
|
+
title?: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
children?: Snippet;
|
|
8
|
+
isProminent?: boolean;
|
|
9
|
+
columnSpan?: 1 | 2;
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
let { title, description = '', children, isProminent = false, columnSpan = 1 }: Props = $props();
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<div class="hero-card vstack gap-2" data-column-span={columnSpan}>
|
|
16
|
+
{#if title}
|
|
17
|
+
<h1 class="text-3xl font-semibold tracking-tight text-zinc-950">{title}</h1>
|
|
18
|
+
{#if description}
|
|
19
|
+
<p class="max-w-3xl text-sm text-zinc-600">{description}</p>
|
|
20
|
+
{/if}
|
|
21
|
+
{/if}
|
|
22
|
+
<div
|
|
23
|
+
class="hero-card-content center flex"
|
|
24
|
+
class:overflow-hidden={isProminent}
|
|
25
|
+
class:rounded-xl={isProminent}
|
|
26
|
+
class:bg-zinc-50={isProminent}
|
|
27
|
+
class:p-4={isProminent}
|
|
28
|
+
>
|
|
29
|
+
{#if children}
|
|
30
|
+
{@render children()}
|
|
31
|
+
{/if}
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
|
|
35
|
+
<style>
|
|
36
|
+
.hero-card {
|
|
37
|
+
background: white;
|
|
38
|
+
padding: 1.5rem;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.hero-card-content {
|
|
42
|
+
min-height: 0;
|
|
43
|
+
flex: 1 1 auto;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
@media (min-width: 48rem) {
|
|
47
|
+
.hero-card[data-column-span='2'] {
|
|
48
|
+
grid-column: span 2;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
</style>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
type Props = {
|
|
3
|
+
title?: string;
|
|
4
|
+
description?: string;
|
|
5
|
+
children?: Snippet;
|
|
6
|
+
isProminent?: boolean;
|
|
7
|
+
columnSpan?: 1 | 2;
|
|
8
|
+
};
|
|
9
|
+
declare const HeroCard: import("svelte").Component<Props, {}, "">;
|
|
10
|
+
type HeroCard = ReturnType<typeof HeroCard>;
|
|
11
|
+
export default HeroCard;
|
|
@@ -6,9 +6,10 @@
|
|
|
6
6
|
left?: Snippet;
|
|
7
7
|
right?: Snippet;
|
|
8
8
|
children?: Snippet;
|
|
9
|
+
chrome?: boolean;
|
|
9
10
|
}
|
|
10
11
|
|
|
11
|
-
let { left, right, children }: Props = $props();
|
|
12
|
+
let { left, right, children, chrome = true }: Props = $props();
|
|
12
13
|
|
|
13
14
|
const existingContext = getContext<{
|
|
14
15
|
leftOpen?: boolean;
|
|
@@ -38,14 +39,14 @@
|
|
|
38
39
|
});
|
|
39
40
|
</script>
|
|
40
41
|
|
|
41
|
-
<div class="hstack size-full">
|
|
42
|
+
<div class="navigation-stack hstack size-full" data-chrome={chrome ? 'true' : 'false'}>
|
|
42
43
|
{#if left}
|
|
43
44
|
<div
|
|
44
|
-
class="h-full overflow-hidden
|
|
45
|
+
class="navigation-stack-sidebar navigation-stack-sidebar-left h-full overflow-hidden transition-all duration-300 ease-in-out"
|
|
45
46
|
style="width: {leftOpen ? 'var(--navigation-stack-sidebar-width)' : '0'}"
|
|
46
47
|
>
|
|
47
48
|
<div
|
|
48
|
-
class="vstack h-full overflow-auto
|
|
49
|
+
class="navigation-stack-sidebar-inner vstack h-full overflow-auto p-4"
|
|
49
50
|
style="width: var(--navigation-stack-sidebar-width);"
|
|
50
51
|
>
|
|
51
52
|
{@render left()}
|
|
@@ -53,7 +54,7 @@
|
|
|
53
54
|
</div>
|
|
54
55
|
{/if}
|
|
55
56
|
|
|
56
|
-
<div class="vstack flex-1">
|
|
57
|
+
<div class="navigation-stack-content vstack flex-1">
|
|
57
58
|
{#if children}
|
|
58
59
|
{@render children()}
|
|
59
60
|
{/if}
|
|
@@ -61,11 +62,11 @@
|
|
|
61
62
|
|
|
62
63
|
{#if right}
|
|
63
64
|
<div
|
|
64
|
-
class="h-full overflow-hidden
|
|
65
|
+
class="navigation-stack-sidebar navigation-stack-sidebar-right h-full overflow-hidden transition-all duration-300 ease-in-out"
|
|
65
66
|
style="width: {rightOpen ? 'var(--navigation-stack-sidebar-width)' : '0'}"
|
|
66
67
|
>
|
|
67
68
|
<div
|
|
68
|
-
class="vstack h-full overflow-auto
|
|
69
|
+
class="navigation-stack-sidebar-inner vstack h-full overflow-auto p-4"
|
|
69
70
|
style="width: var(--navigation-stack-sidebar-width);"
|
|
70
71
|
>
|
|
71
72
|
{@render right()}
|
|
@@ -4,19 +4,20 @@
|
|
|
4
4
|
interface Props {
|
|
5
5
|
header?: Snippet;
|
|
6
6
|
children?: Snippet;
|
|
7
|
+
chrome?: boolean;
|
|
7
8
|
}
|
|
8
9
|
|
|
9
|
-
let { header, children }: Props = $props();
|
|
10
|
+
let { header, children, chrome = true }: Props = $props();
|
|
10
11
|
</script>
|
|
11
12
|
|
|
12
|
-
<div class="vstack h-full">
|
|
13
|
+
<div class="navigation-stack-toolbar-shell vstack h-full" data-chrome={chrome ? 'true' : 'false'}>
|
|
13
14
|
{#if header}
|
|
14
|
-
<div class="flex items-center gap-2
|
|
15
|
+
<div class="navigation-stack-toolbar flex items-center gap-2 p-2">
|
|
15
16
|
{@render header()}
|
|
16
17
|
</div>
|
|
17
18
|
{/if}
|
|
18
19
|
|
|
19
|
-
<div class="vstack h-full">
|
|
20
|
+
<div class="navigation-stack-toolbar-content vstack h-full">
|
|
20
21
|
{#if children}
|
|
21
22
|
{@render children()}
|
|
22
23
|
{/if}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'Pagination',
|
|
4
|
+
description: 'Pagination control with local demo state.',
|
|
5
|
+
isProminent: false,
|
|
6
|
+
columnSpan: 2
|
|
7
|
+
};
|
|
8
|
+
</script>
|
|
9
|
+
|
|
10
|
+
<script lang="ts">
|
|
11
|
+
import Pagination from './Pagination.svelte';
|
|
12
|
+
|
|
13
|
+
let data = $state({
|
|
14
|
+
view: 'list',
|
|
15
|
+
page: 3,
|
|
16
|
+
totalPages: 12,
|
|
17
|
+
hasNext: true
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
const onPageChange = (page: number) => {
|
|
21
|
+
data = { ...data, page, hasNext: page < data.totalPages };
|
|
22
|
+
};
|
|
23
|
+
</script>
|
|
24
|
+
|
|
25
|
+
<div class="w-fit">
|
|
26
|
+
<Pagination {data} showFirstLast={true} onPageChange={(page) => onPageChange(page)} />
|
|
27
|
+
</div>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
isProminent: boolean;
|
|
5
|
+
columnSpan: number;
|
|
6
|
+
};
|
|
7
|
+
import Pagination from './Pagination.svelte';
|
|
8
|
+
declare const Pagination: import("svelte").Component<Record<string, never>, {}, "">;
|
|
9
|
+
type Pagination = ReturnType<typeof Pagination>;
|
|
10
|
+
export default Pagination;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'Popover',
|
|
4
|
+
description: 'Composable popover with trigger and content snippets.'
|
|
5
|
+
};
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<script lang="ts">
|
|
9
|
+
import Popover from './Popover.svelte';
|
|
10
|
+
import SearchInput from '../SearchInput.svelte';
|
|
11
|
+
|
|
12
|
+
let search = $state('');
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<Popover align="center">
|
|
16
|
+
{#snippet trigger()}
|
|
17
|
+
<button
|
|
18
|
+
type="button"
|
|
19
|
+
class="rounded-full border border-zinc-300 px-3 py-2 text-sm text-zinc-800"
|
|
20
|
+
>
|
|
21
|
+
Open popover
|
|
22
|
+
</button>
|
|
23
|
+
{/snippet}
|
|
24
|
+
|
|
25
|
+
<div class="vstack gap-2">
|
|
26
|
+
<label for="popover-demo-search" class="text-sm font-medium text-zinc-700">Search</label>
|
|
27
|
+
<SearchInput
|
|
28
|
+
id="popover-demo-search"
|
|
29
|
+
bind:value={search}
|
|
30
|
+
placeholder="Type to search..."
|
|
31
|
+
confirmText="Enter"
|
|
32
|
+
class="w-64"
|
|
33
|
+
/>
|
|
34
|
+
</div>
|
|
35
|
+
</Popover>
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
};
|
|
5
|
+
import Popover from './Popover.svelte';
|
|
6
|
+
declare const Popover: import("svelte").Component<Record<string, never>, {}, "">;
|
|
7
|
+
type Popover = ReturnType<typeof Popover>;
|
|
8
|
+
export default Popover;
|
|
@@ -224,6 +224,12 @@
|
|
|
224
224
|
}
|
|
225
225
|
}
|
|
226
226
|
|
|
227
|
+
function handleTriggerKeydown(event: KeyboardEvent) {
|
|
228
|
+
if (event.key !== 'Enter' && event.key !== ' ') return;
|
|
229
|
+
event.preventDefault();
|
|
230
|
+
toggle();
|
|
231
|
+
}
|
|
232
|
+
|
|
227
233
|
function handleOutsideClick(event: MouseEvent) {
|
|
228
234
|
if (!open) return;
|
|
229
235
|
if (isEventInPopoverTree(event)) return;
|
|
@@ -273,15 +279,17 @@
|
|
|
273
279
|
data-popover-parent-id={parentPopoverId ?? ''}
|
|
274
280
|
>
|
|
275
281
|
<div bind:this={triggerEl}>
|
|
276
|
-
<
|
|
277
|
-
type="button"
|
|
282
|
+
<div
|
|
278
283
|
class="text-left"
|
|
284
|
+
role="button"
|
|
285
|
+
tabindex="0"
|
|
279
286
|
onclick={toggle}
|
|
287
|
+
onkeydown={handleTriggerKeydown}
|
|
280
288
|
aria-expanded={open}
|
|
281
289
|
aria-haspopup="dialog"
|
|
282
290
|
>
|
|
283
291
|
{@render trigger()}
|
|
284
|
-
</
|
|
292
|
+
</div>
|
|
285
293
|
</div>
|
|
286
294
|
|
|
287
295
|
{#if open}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'SearchInput',
|
|
4
|
+
description: 'Search field with icon, input, and optional confirmation hint.',
|
|
5
|
+
isProminent: false
|
|
6
|
+
};
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<script lang="ts">
|
|
10
|
+
import SearchInput from './SearchInput.svelte';
|
|
11
|
+
|
|
12
|
+
let value = $state('');
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<div class="vstack w-full max-w-sm gap-2">
|
|
16
|
+
<SearchInput bind:value placeholder="Search components..." confirmText="Enter" class="w-full" />
|
|
17
|
+
<p class="text-xs text-zinc-500">Value: {value || 'empty'}</p>
|
|
18
|
+
</div>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
isProminent: boolean;
|
|
5
|
+
};
|
|
6
|
+
import SearchInput from './SearchInput.svelte';
|
|
7
|
+
declare const SearchInput: import("svelte").Component<Record<string, never>, {}, "">;
|
|
8
|
+
type SearchInput = ReturnType<typeof SearchInput>;
|
|
9
|
+
export default SearchInput;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { SearchIcon } from '@lucide/svelte';
|
|
3
|
+
import type { HTMLInputAttributes } from 'svelte/elements';
|
|
4
|
+
|
|
5
|
+
type Props = {
|
|
6
|
+
value?: string;
|
|
7
|
+
confirmText?: string | null;
|
|
8
|
+
inputClass?: string;
|
|
9
|
+
} & Omit<HTMLInputAttributes, 'children' | 'type' | 'value'>;
|
|
10
|
+
|
|
11
|
+
let {
|
|
12
|
+
value = $bindable(''),
|
|
13
|
+
confirmText = null,
|
|
14
|
+
inputClass = '',
|
|
15
|
+
class: className = '',
|
|
16
|
+
disabled = false,
|
|
17
|
+
placeholder = 'Search',
|
|
18
|
+
...props
|
|
19
|
+
}: Props = $props();
|
|
20
|
+
</script>
|
|
21
|
+
|
|
22
|
+
<label class="search-input {className}" data-disabled={disabled ? 'true' : 'false'}>
|
|
23
|
+
<span class="search-input-icon" aria-hidden="true">
|
|
24
|
+
<SearchIcon class="size-4" />
|
|
25
|
+
</span>
|
|
26
|
+
<input
|
|
27
|
+
type="search"
|
|
28
|
+
bind:value
|
|
29
|
+
{disabled}
|
|
30
|
+
{placeholder}
|
|
31
|
+
class="search-input-field {inputClass}"
|
|
32
|
+
{...props}
|
|
33
|
+
/>
|
|
34
|
+
{#if confirmText}
|
|
35
|
+
<span class="search-input-confirm">
|
|
36
|
+
{confirmText}
|
|
37
|
+
</span>
|
|
38
|
+
{/if}
|
|
39
|
+
</label>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { HTMLInputAttributes } from 'svelte/elements';
|
|
2
|
+
type Props = {
|
|
3
|
+
value?: string;
|
|
4
|
+
confirmText?: string | null;
|
|
5
|
+
inputClass?: string;
|
|
6
|
+
} & Omit<HTMLInputAttributes, 'children' | 'type' | 'value'>;
|
|
7
|
+
declare const SearchInput: import("svelte").Component<Props, {}, "value">;
|
|
8
|
+
type SearchInput = ReturnType<typeof SearchInput>;
|
|
9
|
+
export default SearchInput;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'SegmentedPicker',
|
|
4
|
+
description: 'Segmented selection between fixed options.',
|
|
5
|
+
isProminent: false
|
|
6
|
+
};
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<script lang="ts">
|
|
10
|
+
import SegmentedPicker from './SegmentedPicker.svelte';
|
|
11
|
+
|
|
12
|
+
const options = [
|
|
13
|
+
{ label: 'Day', value: 'day' },
|
|
14
|
+
{ label: 'Week', value: 'week', disabled: true },
|
|
15
|
+
{ label: 'Month', value: 'month' }
|
|
16
|
+
];
|
|
17
|
+
|
|
18
|
+
let value = $state('week');
|
|
19
|
+
</script>
|
|
20
|
+
|
|
21
|
+
<div class="vstack center gap-2">
|
|
22
|
+
<SegmentedPicker {options} bind:value />
|
|
23
|
+
<p class="text-xs text-zinc-500">Selected: {value}</p>
|
|
24
|
+
</div>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
isProminent: boolean;
|
|
5
|
+
};
|
|
6
|
+
import SegmentedPicker from './SegmentedPicker.svelte';
|
|
7
|
+
declare const SegmentedPicker: import("svelte").Component<Record<string, never>, {}, "">;
|
|
8
|
+
type SegmentedPicker = ReturnType<typeof SegmentedPicker>;
|
|
9
|
+
export default SegmentedPicker;
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
type Option = {
|
|
3
3
|
label: string;
|
|
4
4
|
value: string;
|
|
5
|
+
disabled?: boolean;
|
|
5
6
|
};
|
|
6
7
|
|
|
7
8
|
let {
|
|
@@ -22,7 +23,16 @@
|
|
|
22
23
|
class:segmented-picker-disabled={disabled}
|
|
23
24
|
>
|
|
24
25
|
{#each options as option}
|
|
25
|
-
{#if option.
|
|
26
|
+
{#if option.disabled}
|
|
27
|
+
<span
|
|
28
|
+
class={`segmented-picker-button segmented-picker-button-disabled ${
|
|
29
|
+
option.value === value ? 'segmented-picker-button-disabled-selected' : ''
|
|
30
|
+
}`}
|
|
31
|
+
aria-disabled="true"
|
|
32
|
+
>
|
|
33
|
+
{option.label}
|
|
34
|
+
</span>
|
|
35
|
+
{:else if option.value === value}
|
|
26
36
|
<span class="segmented-picker-button segmented-picker-button-active">{option.label}</span>
|
|
27
37
|
{:else}
|
|
28
38
|
<button
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'Sheet',
|
|
4
|
+
description: 'Overlay sheet with local open state.'
|
|
5
|
+
};
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<script lang="ts">
|
|
9
|
+
import Sheet from './Sheet.svelte';
|
|
10
|
+
|
|
11
|
+
let open = $state(false);
|
|
12
|
+
</script>
|
|
13
|
+
|
|
14
|
+
<button
|
|
15
|
+
type="button"
|
|
16
|
+
class="rounded-full bg-zinc-900 px-3 py-2 text-sm text-white"
|
|
17
|
+
onclick={() => (open = true)}
|
|
18
|
+
>
|
|
19
|
+
Open sheet
|
|
20
|
+
</button>
|
|
21
|
+
|
|
22
|
+
<Sheet bind:open label="Example Sheet">
|
|
23
|
+
<div class="vstack gap-3">
|
|
24
|
+
<p class="text-sm text-zinc-700">This is a simple sheet example.</p>
|
|
25
|
+
<div class="rounded border border-gray-200/70 p-3 text-sm text-gray-700">
|
|
26
|
+
<div>Panel one content.</div>
|
|
27
|
+
<div class="mt-2">Panel two content.</div>
|
|
28
|
+
<div class="mt-2">Panel three content.</div>
|
|
29
|
+
</div>
|
|
30
|
+
<button
|
|
31
|
+
type="button"
|
|
32
|
+
class="rounded-full border border-zinc-300 px-3 py-2 text-sm text-zinc-800"
|
|
33
|
+
onclick={() => (open = false)}
|
|
34
|
+
>
|
|
35
|
+
Close
|
|
36
|
+
</button>
|
|
37
|
+
</div>
|
|
38
|
+
</Sheet>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'Slider',
|
|
4
|
+
description: 'Range input with shared slider styling.',
|
|
5
|
+
isProminent: false
|
|
6
|
+
};
|
|
7
|
+
</script>
|
|
8
|
+
|
|
9
|
+
<script lang="ts">
|
|
10
|
+
import Slider from './Slider.svelte';
|
|
11
|
+
|
|
12
|
+
let value = $state(35);
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<div class="vstack w-full max-w-sm gap-2">
|
|
16
|
+
<Slider bind:value min={0} max={100} class="w-full" />
|
|
17
|
+
<p class="text-xs text-zinc-500">Value: {value}</p>
|
|
18
|
+
</div>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
isProminent: boolean;
|
|
5
|
+
};
|
|
6
|
+
import Slider from './Slider.svelte';
|
|
7
|
+
declare const Slider: import("svelte").Component<Record<string, never>, {}, "">;
|
|
8
|
+
type Slider = ReturnType<typeof Slider>;
|
|
9
|
+
export default Slider;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
};
|
|
5
|
+
import Spinner from './Spinner.svelte';
|
|
6
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
7
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
8
|
+
$$bindings?: Bindings;
|
|
9
|
+
} & Exports;
|
|
10
|
+
(internal: unknown, props: {
|
|
11
|
+
$$events?: Events;
|
|
12
|
+
$$slots?: Slots;
|
|
13
|
+
}): Exports & {
|
|
14
|
+
$set?: any;
|
|
15
|
+
$on?: any;
|
|
16
|
+
};
|
|
17
|
+
z_$$bindings?: Bindings;
|
|
18
|
+
}
|
|
19
|
+
declare const Spinner: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
|
|
20
|
+
[evt: string]: CustomEvent<any>;
|
|
21
|
+
}, {}, {}, string>;
|
|
22
|
+
type Spinner = InstanceType<typeof Spinner>;
|
|
23
|
+
export default Spinner;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<script module lang="ts">
|
|
2
|
+
export const demo = {
|
|
3
|
+
name: 'Tooltip',
|
|
4
|
+
description: 'Hover or focus a trigger to reveal contextual text.'
|
|
5
|
+
};
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<script lang="ts">
|
|
9
|
+
import Tooltip from './Tooltip.svelte';
|
|
10
|
+
</script>
|
|
11
|
+
|
|
12
|
+
<Tooltip label="This is a tooltip">
|
|
13
|
+
<button type="button" class="rounded-full border border-zinc-300 px-3 py-2 text-sm text-zinc-800">
|
|
14
|
+
Hover me
|
|
15
|
+
</button>
|
|
16
|
+
</Tooltip>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const demo: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
};
|
|
5
|
+
import Tooltip from './Tooltip.svelte';
|
|
6
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
7
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
8
|
+
$$bindings?: Bindings;
|
|
9
|
+
} & Exports;
|
|
10
|
+
(internal: unknown, props: {
|
|
11
|
+
$$events?: Events;
|
|
12
|
+
$$slots?: Slots;
|
|
13
|
+
}): Exports & {
|
|
14
|
+
$set?: any;
|
|
15
|
+
$on?: any;
|
|
16
|
+
};
|
|
17
|
+
z_$$bindings?: Bindings;
|
|
18
|
+
}
|
|
19
|
+
declare const Tooltip: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
|
|
20
|
+
[evt: string]: CustomEvent<any>;
|
|
21
|
+
}, {}, {}, string>;
|
|
22
|
+
type Tooltip = InstanceType<typeof Tooltip>;
|
|
23
|
+
export default Tooltip;
|
package/dist/index.d.ts
CHANGED
|
@@ -13,3 +13,4 @@ export { default as Tooltip } from './components/Tooltip.svelte';
|
|
|
13
13
|
export { default as Popover } from './components/Popover';
|
|
14
14
|
export { default as ChipInput } from './components/ChipInput.svelte';
|
|
15
15
|
export { default as AsyncButton } from './components/AsyncButton.svelte';
|
|
16
|
+
export { default as SearchInput } from './components/SearchInput.svelte';
|
package/dist/index.js
CHANGED
|
@@ -13,3 +13,4 @@ export { default as Tooltip } from './components/Tooltip.svelte';
|
|
|
13
13
|
export { default as Popover } from './components/Popover';
|
|
14
14
|
export { default as ChipInput } from './components/ChipInput.svelte';
|
|
15
15
|
export { default as AsyncButton } from './components/AsyncButton.svelte';
|
|
16
|
+
export { default as SearchInput } from './components/SearchInput.svelte';
|
package/dist/style/index.css
CHANGED
|
@@ -87,13 +87,50 @@
|
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
.pagination {
|
|
90
|
-
@apply gap-4;
|
|
90
|
+
@apply inline-flex w-fit gap-4;
|
|
91
91
|
}
|
|
92
92
|
|
|
93
93
|
.sidebar-toggle {
|
|
94
94
|
@apply rounded p-1.5 hover:bg-zinc-100;
|
|
95
95
|
}
|
|
96
96
|
|
|
97
|
+
.navigation-stack-sidebar-left {
|
|
98
|
+
@apply border-r border-zinc-200;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.navigation-stack-sidebar-right {
|
|
102
|
+
@apply border-l border-zinc-200;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.navigation-stack-sidebar-inner {
|
|
106
|
+
@apply bg-zinc-50;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.navigation-stack-toolbar {
|
|
110
|
+
@apply border-b border-zinc-200 bg-white;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.navigation-stack[data-chrome='false'] .navigation-stack-sidebar-left,
|
|
114
|
+
.navigation-stack[data-chrome='false'] .navigation-stack-sidebar-right {
|
|
115
|
+
@apply border-transparent;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.navigation-stack[data-chrome='false'] .navigation-stack-sidebar-inner {
|
|
119
|
+
@apply bg-transparent;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.navigation-stack-toolbar-shell[data-chrome='false'] .navigation-stack-toolbar {
|
|
123
|
+
@apply border-transparent bg-transparent;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.navigation-stack-toolbar-shell[data-chrome='false'] .navigation-stack-toolbar-content {
|
|
127
|
+
@apply bg-transparent;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.navigation-stack-toolbar-shell[data-chrome='false'] .sidebar-toggle {
|
|
131
|
+
@apply hover:bg-transparent;
|
|
132
|
+
}
|
|
133
|
+
|
|
97
134
|
.popover {
|
|
98
135
|
@apply border border-gray-200 bg-white p-1 shadow-md;
|
|
99
136
|
}
|
|
@@ -234,6 +271,43 @@
|
|
|
234
271
|
.segmented-picker-button-active {
|
|
235
272
|
@apply bg-white shadow-xs;
|
|
236
273
|
}
|
|
274
|
+
|
|
275
|
+
.segmented-picker-button-disabled {
|
|
276
|
+
@apply cursor-not-allowed text-zinc-400;
|
|
277
|
+
pointer-events: none;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.segmented-picker-button-disabled-selected {
|
|
281
|
+
@apply bg-zinc-200 text-zinc-400 shadow-none;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.search-input {
|
|
285
|
+
@apply inline-flex items-center gap-2 rounded-md border border-zinc-200 bg-white px-3 py-2 text-sm text-zinc-900 shadow-xs transition-colors;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
.search-input:focus-within {
|
|
289
|
+
@apply border-zinc-400;
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
.search-input[data-disabled='true'] {
|
|
293
|
+
@apply cursor-not-allowed opacity-60;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
.search-input-icon {
|
|
297
|
+
@apply shrink-0 text-zinc-500;
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
.search-input-field {
|
|
301
|
+
@apply min-w-0 flex-1 bg-transparent outline-none;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
.search-input-field::-webkit-search-cancel-button {
|
|
305
|
+
appearance: none;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
.search-input-confirm {
|
|
309
|
+
@apply shrink-0 text-xs font-medium tracking-[0.18em] text-zinc-500 uppercase;
|
|
310
|
+
}
|
|
237
311
|
}
|
|
238
312
|
|
|
239
313
|
@layer theme {
|
package/dist/style.css
CHANGED
|
@@ -7,11 +7,7 @@
|
|
|
7
7
|
"Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
|
|
8
8
|
--font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
|
|
9
9
|
"Courier New", monospace;
|
|
10
|
-
--color-red-100: oklch(93.6% 0.032 17.717);
|
|
11
|
-
--color-red-200: oklch(88.5% 0.062 18.334);
|
|
12
|
-
--color-red-500: oklch(63.7% 0.237 25.331);
|
|
13
10
|
--color-red-600: oklch(57.7% 0.245 27.325);
|
|
14
|
-
--color-red-700: oklch(50.5% 0.213 27.518);
|
|
15
11
|
--color-gray-200: oklch(92.8% 0.006 264.531);
|
|
16
12
|
--color-gray-700: oklch(37.3% 0.034 259.733);
|
|
17
13
|
--color-gray-900: oklch(21% 0.034 264.665);
|
|
@@ -21,21 +17,29 @@
|
|
|
21
17
|
--color-zinc-300: oklch(87.1% 0.006 286.286);
|
|
22
18
|
--color-zinc-400: oklch(70.5% 0.015 286.067);
|
|
23
19
|
--color-zinc-500: oklch(55.2% 0.016 285.938);
|
|
20
|
+
--color-zinc-600: oklch(44.2% 0.017 285.786);
|
|
24
21
|
--color-zinc-700: oklch(37% 0.013 285.805);
|
|
25
22
|
--color-zinc-800: oklch(27.4% 0.006 286.033);
|
|
26
23
|
--color-zinc-900: oklch(21% 0.006 285.885);
|
|
24
|
+
--color-zinc-950: oklch(14.1% 0.005 285.823);
|
|
27
25
|
--color-black: #000;
|
|
28
26
|
--color-white: #fff;
|
|
29
27
|
--spacing: 0.25rem;
|
|
28
|
+
--container-sm: 24rem;
|
|
29
|
+
--container-3xl: 48rem;
|
|
30
30
|
--text-xs: 0.75rem;
|
|
31
31
|
--text-xs--line-height: calc(1 / 0.75);
|
|
32
32
|
--text-sm: 0.875rem;
|
|
33
33
|
--text-sm--line-height: calc(1.25 / 0.875);
|
|
34
|
+
--text-3xl: 1.875rem;
|
|
35
|
+
--text-3xl--line-height: calc(2.25 / 1.875);
|
|
34
36
|
--font-weight-medium: 500;
|
|
35
37
|
--font-weight-semibold: 600;
|
|
38
|
+
--tracking-tight: -0.025em;
|
|
36
39
|
--tracking-wide: 0.025em;
|
|
37
40
|
--radius-sm: 0.25rem;
|
|
38
41
|
--radius-md: 0.375rem;
|
|
42
|
+
--radius-xl: 0.75rem;
|
|
39
43
|
--shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
|
|
40
44
|
--ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
|
|
41
45
|
--animate-spin: spin 1s linear infinite;
|
|
@@ -245,6 +249,9 @@
|
|
|
245
249
|
.flex {
|
|
246
250
|
display: flex;
|
|
247
251
|
}
|
|
252
|
+
.grid {
|
|
253
|
+
display: grid;
|
|
254
|
+
}
|
|
248
255
|
.hidden {
|
|
249
256
|
display: none;
|
|
250
257
|
}
|
|
@@ -265,6 +272,10 @@
|
|
|
265
272
|
width: calc(var(--spacing) * 4);
|
|
266
273
|
height: calc(var(--spacing) * 4);
|
|
267
274
|
}
|
|
275
|
+
.size-6 {
|
|
276
|
+
width: calc(var(--spacing) * 6);
|
|
277
|
+
height: calc(var(--spacing) * 6);
|
|
278
|
+
}
|
|
268
279
|
.size-full {
|
|
269
280
|
width: 100%;
|
|
270
281
|
height: 100%;
|
|
@@ -287,12 +298,6 @@
|
|
|
287
298
|
.w-8 {
|
|
288
299
|
width: calc(var(--spacing) * 8);
|
|
289
300
|
}
|
|
290
|
-
.w-56 {
|
|
291
|
-
width: calc(var(--spacing) * 56);
|
|
292
|
-
}
|
|
293
|
-
.w-60 {
|
|
294
|
-
width: calc(var(--spacing) * 60);
|
|
295
|
-
}
|
|
296
301
|
.w-64 {
|
|
297
302
|
width: calc(var(--spacing) * 64);
|
|
298
303
|
}
|
|
@@ -302,6 +307,12 @@
|
|
|
302
307
|
.w-full {
|
|
303
308
|
width: 100%;
|
|
304
309
|
}
|
|
310
|
+
.max-w-3xl {
|
|
311
|
+
max-width: var(--container-3xl);
|
|
312
|
+
}
|
|
313
|
+
.max-w-sm {
|
|
314
|
+
max-width: var(--container-sm);
|
|
315
|
+
}
|
|
305
316
|
.flex-1 {
|
|
306
317
|
flex: 1;
|
|
307
318
|
}
|
|
@@ -337,15 +348,24 @@
|
|
|
337
348
|
.items-center {
|
|
338
349
|
align-items: center;
|
|
339
350
|
}
|
|
351
|
+
.justify-between {
|
|
352
|
+
justify-content: space-between;
|
|
353
|
+
}
|
|
340
354
|
.justify-center {
|
|
341
355
|
justify-content: center;
|
|
342
356
|
}
|
|
357
|
+
.gap-1 {
|
|
358
|
+
gap: calc(var(--spacing) * 1);
|
|
359
|
+
}
|
|
343
360
|
.gap-2 {
|
|
344
361
|
gap: calc(var(--spacing) * 2);
|
|
345
362
|
}
|
|
346
363
|
.gap-3 {
|
|
347
364
|
gap: calc(var(--spacing) * 3);
|
|
348
365
|
}
|
|
366
|
+
.gap-4 {
|
|
367
|
+
gap: calc(var(--spacing) * 4);
|
|
368
|
+
}
|
|
349
369
|
.space-y-2 {
|
|
350
370
|
:where(& > :not(:last-child)) {
|
|
351
371
|
--tw-space-y-reverse: 0;
|
|
@@ -365,22 +385,16 @@
|
|
|
365
385
|
.rounded-full {
|
|
366
386
|
border-radius: calc(infinity * 1px);
|
|
367
387
|
}
|
|
388
|
+
.rounded-md {
|
|
389
|
+
border-radius: var(--radius-md);
|
|
390
|
+
}
|
|
391
|
+
.rounded-xl {
|
|
392
|
+
border-radius: var(--radius-xl);
|
|
393
|
+
}
|
|
368
394
|
.border {
|
|
369
395
|
border-style: var(--tw-border-style);
|
|
370
396
|
border-width: 1px;
|
|
371
397
|
}
|
|
372
|
-
.border-r {
|
|
373
|
-
border-right-style: var(--tw-border-style);
|
|
374
|
-
border-right-width: 1px;
|
|
375
|
-
}
|
|
376
|
-
.border-b {
|
|
377
|
-
border-bottom-style: var(--tw-border-style);
|
|
378
|
-
border-bottom-width: 1px;
|
|
379
|
-
}
|
|
380
|
-
.border-l {
|
|
381
|
-
border-left-style: var(--tw-border-style);
|
|
382
|
-
border-left-width: 1px;
|
|
383
|
-
}
|
|
384
398
|
.border-gray-200\/70 {
|
|
385
399
|
border-color: color-mix(in srgb, oklch(92.8% 0.006 264.531) 70%, transparent);
|
|
386
400
|
@supports (color: color-mix(in lab, red, red)) {
|
|
@@ -393,24 +407,21 @@
|
|
|
393
407
|
.border-zinc-300 {
|
|
394
408
|
border-color: var(--color-zinc-300);
|
|
395
409
|
}
|
|
396
|
-
.bg-red-100 {
|
|
397
|
-
background-color: var(--color-red-100);
|
|
398
|
-
}
|
|
399
410
|
.bg-white {
|
|
400
411
|
background-color: var(--color-white);
|
|
401
412
|
}
|
|
402
413
|
.bg-zinc-50 {
|
|
403
414
|
background-color: var(--color-zinc-50);
|
|
404
415
|
}
|
|
405
|
-
.bg-zinc-100 {
|
|
406
|
-
background-color: var(--color-zinc-100);
|
|
407
|
-
}
|
|
408
416
|
.bg-zinc-900 {
|
|
409
417
|
background-color: var(--color-zinc-900);
|
|
410
418
|
}
|
|
411
419
|
.p-0 {
|
|
412
420
|
padding: calc(var(--spacing) * 0);
|
|
413
421
|
}
|
|
422
|
+
.p-1 {
|
|
423
|
+
padding: calc(var(--spacing) * 1);
|
|
424
|
+
}
|
|
414
425
|
.p-2 {
|
|
415
426
|
padding: calc(var(--spacing) * 2);
|
|
416
427
|
}
|
|
@@ -420,6 +431,9 @@
|
|
|
420
431
|
.p-4 {
|
|
421
432
|
padding: calc(var(--spacing) * 4);
|
|
422
433
|
}
|
|
434
|
+
.p-6 {
|
|
435
|
+
padding: calc(var(--spacing) * 6);
|
|
436
|
+
}
|
|
423
437
|
.px-2 {
|
|
424
438
|
padding-inline: calc(var(--spacing) * 2);
|
|
425
439
|
}
|
|
@@ -435,6 +449,10 @@
|
|
|
435
449
|
.text-left {
|
|
436
450
|
text-align: left;
|
|
437
451
|
}
|
|
452
|
+
.text-3xl {
|
|
453
|
+
font-size: var(--text-3xl);
|
|
454
|
+
line-height: var(--tw-leading, var(--text-3xl--line-height));
|
|
455
|
+
}
|
|
438
456
|
.text-sm {
|
|
439
457
|
font-size: var(--text-sm);
|
|
440
458
|
line-height: var(--tw-leading, var(--text-sm--line-height));
|
|
@@ -455,6 +473,10 @@
|
|
|
455
473
|
--tw-font-weight: var(--font-weight-semibold);
|
|
456
474
|
font-weight: var(--font-weight-semibold);
|
|
457
475
|
}
|
|
476
|
+
.tracking-tight {
|
|
477
|
+
--tw-tracking: var(--tracking-tight);
|
|
478
|
+
letter-spacing: var(--tracking-tight);
|
|
479
|
+
}
|
|
458
480
|
.tracking-wide {
|
|
459
481
|
--tw-tracking: var(--tracking-wide);
|
|
460
482
|
letter-spacing: var(--tracking-wide);
|
|
@@ -465,21 +487,27 @@
|
|
|
465
487
|
.text-red-600 {
|
|
466
488
|
color: var(--color-red-600);
|
|
467
489
|
}
|
|
468
|
-
.text-red-700 {
|
|
469
|
-
color: var(--color-red-700);
|
|
470
|
-
}
|
|
471
490
|
.text-white {
|
|
472
491
|
color: var(--color-white);
|
|
473
492
|
}
|
|
474
493
|
.text-zinc-500 {
|
|
475
494
|
color: var(--color-zinc-500);
|
|
476
495
|
}
|
|
496
|
+
.text-zinc-600 {
|
|
497
|
+
color: var(--color-zinc-600);
|
|
498
|
+
}
|
|
477
499
|
.text-zinc-700 {
|
|
478
500
|
color: var(--color-zinc-700);
|
|
479
501
|
}
|
|
480
502
|
.text-zinc-800 {
|
|
481
503
|
color: var(--color-zinc-800);
|
|
482
504
|
}
|
|
505
|
+
.text-zinc-900 {
|
|
506
|
+
color: var(--color-zinc-900);
|
|
507
|
+
}
|
|
508
|
+
.text-zinc-950 {
|
|
509
|
+
color: var(--color-zinc-950);
|
|
510
|
+
}
|
|
483
511
|
.uppercase {
|
|
484
512
|
text-transform: uppercase;
|
|
485
513
|
}
|
|
@@ -536,13 +564,6 @@
|
|
|
536
564
|
--tw-outline-style: none;
|
|
537
565
|
outline-style: none;
|
|
538
566
|
}
|
|
539
|
-
.hover\:bg-red-200 {
|
|
540
|
-
&:hover {
|
|
541
|
-
@media (hover: hover) {
|
|
542
|
-
background-color: var(--color-red-200);
|
|
543
|
-
}
|
|
544
|
-
}
|
|
545
|
-
}
|
|
546
567
|
.hover\:bg-zinc-100 {
|
|
547
568
|
&:hover {
|
|
548
569
|
@media (hover: hover) {
|
|
@@ -550,18 +571,6 @@
|
|
|
550
571
|
}
|
|
551
572
|
}
|
|
552
573
|
}
|
|
553
|
-
.hover\:bg-zinc-200 {
|
|
554
|
-
&:hover {
|
|
555
|
-
@media (hover: hover) {
|
|
556
|
-
background-color: var(--color-zinc-200);
|
|
557
|
-
}
|
|
558
|
-
}
|
|
559
|
-
}
|
|
560
|
-
.focus\:border-zinc-400 {
|
|
561
|
-
&:focus {
|
|
562
|
-
border-color: var(--color-zinc-400);
|
|
563
|
-
}
|
|
564
|
-
}
|
|
565
574
|
.focus\:outline-none {
|
|
566
575
|
&:focus {
|
|
567
576
|
--tw-outline-style: none;
|
|
@@ -588,14 +597,19 @@
|
|
|
588
597
|
opacity: 50%;
|
|
589
598
|
}
|
|
590
599
|
}
|
|
591
|
-
.
|
|
592
|
-
|
|
593
|
-
|
|
600
|
+
.md\:grid-flow-dense {
|
|
601
|
+
@media (width >= 48rem) {
|
|
602
|
+
grid-auto-flow: dense;
|
|
594
603
|
}
|
|
595
604
|
}
|
|
596
|
-
.
|
|
597
|
-
|
|
598
|
-
|
|
605
|
+
.md\:grid-cols-2 {
|
|
606
|
+
@media (width >= 48rem) {
|
|
607
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
.xl\:grid-cols-3 {
|
|
611
|
+
@media (width >= 80rem) {
|
|
612
|
+
grid-template-columns: repeat(3, minmax(0, 1fr));
|
|
599
613
|
}
|
|
600
614
|
}
|
|
601
615
|
}
|
|
@@ -700,6 +714,8 @@
|
|
|
700
714
|
outline-style: none;
|
|
701
715
|
}
|
|
702
716
|
.pagination {
|
|
717
|
+
display: inline-flex;
|
|
718
|
+
width: fit-content;
|
|
703
719
|
gap: calc(var(--spacing) * 4);
|
|
704
720
|
}
|
|
705
721
|
.sidebar-toggle {
|
|
@@ -711,6 +727,45 @@
|
|
|
711
727
|
}
|
|
712
728
|
}
|
|
713
729
|
}
|
|
730
|
+
.navigation-stack-sidebar-left {
|
|
731
|
+
border-right-style: var(--tw-border-style);
|
|
732
|
+
border-right-width: 1px;
|
|
733
|
+
border-color: var(--color-zinc-200);
|
|
734
|
+
}
|
|
735
|
+
.navigation-stack-sidebar-right {
|
|
736
|
+
border-left-style: var(--tw-border-style);
|
|
737
|
+
border-left-width: 1px;
|
|
738
|
+
border-color: var(--color-zinc-200);
|
|
739
|
+
}
|
|
740
|
+
.navigation-stack-sidebar-inner {
|
|
741
|
+
background-color: var(--color-zinc-50);
|
|
742
|
+
}
|
|
743
|
+
.navigation-stack-toolbar {
|
|
744
|
+
border-bottom-style: var(--tw-border-style);
|
|
745
|
+
border-bottom-width: 1px;
|
|
746
|
+
border-color: var(--color-zinc-200);
|
|
747
|
+
background-color: var(--color-white);
|
|
748
|
+
}
|
|
749
|
+
.navigation-stack[data-chrome='false'] .navigation-stack-sidebar-left, .navigation-stack[data-chrome='false'] .navigation-stack-sidebar-right {
|
|
750
|
+
border-color: transparent;
|
|
751
|
+
}
|
|
752
|
+
.navigation-stack[data-chrome='false'] .navigation-stack-sidebar-inner {
|
|
753
|
+
background-color: transparent;
|
|
754
|
+
}
|
|
755
|
+
.navigation-stack-toolbar-shell[data-chrome='false'] .navigation-stack-toolbar {
|
|
756
|
+
border-color: transparent;
|
|
757
|
+
background-color: transparent;
|
|
758
|
+
}
|
|
759
|
+
.navigation-stack-toolbar-shell[data-chrome='false'] .navigation-stack-toolbar-content {
|
|
760
|
+
background-color: transparent;
|
|
761
|
+
}
|
|
762
|
+
.navigation-stack-toolbar-shell[data-chrome='false'] .sidebar-toggle {
|
|
763
|
+
&:hover {
|
|
764
|
+
@media (hover: hover) {
|
|
765
|
+
background-color: transparent;
|
|
766
|
+
}
|
|
767
|
+
}
|
|
768
|
+
}
|
|
714
769
|
.popover {
|
|
715
770
|
border-style: var(--tw-border-style);
|
|
716
771
|
border-width: 1px;
|
|
@@ -858,6 +913,69 @@
|
|
|
858
913
|
--tw-shadow: 0 1px 2px 0 var(--tw-shadow-color, rgb(0 0 0 / 0.05));
|
|
859
914
|
box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
|
|
860
915
|
}
|
|
916
|
+
.segmented-picker-button-disabled {
|
|
917
|
+
cursor: not-allowed;
|
|
918
|
+
color: var(--color-zinc-400);
|
|
919
|
+
pointer-events: none;
|
|
920
|
+
}
|
|
921
|
+
.segmented-picker-button-disabled-selected {
|
|
922
|
+
background-color: var(--color-zinc-200);
|
|
923
|
+
color: var(--color-zinc-400);
|
|
924
|
+
--tw-shadow: 0 0 #0000;
|
|
925
|
+
box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
|
|
926
|
+
}
|
|
927
|
+
.search-input {
|
|
928
|
+
display: inline-flex;
|
|
929
|
+
align-items: center;
|
|
930
|
+
gap: calc(var(--spacing) * 2);
|
|
931
|
+
border-radius: var(--radius-md);
|
|
932
|
+
border-style: var(--tw-border-style);
|
|
933
|
+
border-width: 1px;
|
|
934
|
+
border-color: var(--color-zinc-200);
|
|
935
|
+
background-color: var(--color-white);
|
|
936
|
+
padding-inline: calc(var(--spacing) * 3);
|
|
937
|
+
padding-block: calc(var(--spacing) * 2);
|
|
938
|
+
font-size: var(--text-sm);
|
|
939
|
+
line-height: var(--tw-leading, var(--text-sm--line-height));
|
|
940
|
+
color: var(--color-zinc-900);
|
|
941
|
+
--tw-shadow: 0 1px 2px 0 var(--tw-shadow-color, rgb(0 0 0 / 0.05));
|
|
942
|
+
box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
|
|
943
|
+
transition-property: color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, --tw-gradient-from, --tw-gradient-via, --tw-gradient-to;
|
|
944
|
+
transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));
|
|
945
|
+
transition-duration: var(--tw-duration, var(--default-transition-duration));
|
|
946
|
+
}
|
|
947
|
+
.search-input:focus-within {
|
|
948
|
+
border-color: var(--color-zinc-400);
|
|
949
|
+
}
|
|
950
|
+
.search-input[data-disabled='true'] {
|
|
951
|
+
cursor: not-allowed;
|
|
952
|
+
opacity: 60%;
|
|
953
|
+
}
|
|
954
|
+
.search-input-icon {
|
|
955
|
+
flex-shrink: 0;
|
|
956
|
+
color: var(--color-zinc-500);
|
|
957
|
+
}
|
|
958
|
+
.search-input-field {
|
|
959
|
+
min-width: calc(var(--spacing) * 0);
|
|
960
|
+
flex: 1;
|
|
961
|
+
background-color: transparent;
|
|
962
|
+
--tw-outline-style: none;
|
|
963
|
+
outline-style: none;
|
|
964
|
+
}
|
|
965
|
+
.search-input-field::-webkit-search-cancel-button {
|
|
966
|
+
appearance: none;
|
|
967
|
+
}
|
|
968
|
+
.search-input-confirm {
|
|
969
|
+
flex-shrink: 0;
|
|
970
|
+
font-size: var(--text-xs);
|
|
971
|
+
line-height: var(--tw-leading, var(--text-xs--line-height));
|
|
972
|
+
--tw-font-weight: var(--font-weight-medium);
|
|
973
|
+
font-weight: var(--font-weight-medium);
|
|
974
|
+
--tw-tracking: 0.18em;
|
|
975
|
+
letter-spacing: 0.18em;
|
|
976
|
+
color: var(--color-zinc-500);
|
|
977
|
+
text-transform: uppercase;
|
|
978
|
+
}
|
|
861
979
|
}
|
|
862
980
|
@layer theme {
|
|
863
981
|
:root {
|