svelte-tably 1.0.1 → 1.0.2-next.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.
@@ -1,39 +1,39 @@
1
- <!-- @component
2
-
3
- This is a description, \
4
- on how to use this.
5
-
6
- @example
7
- <Component />
8
-
9
- -->
10
-
11
- <script module lang='ts'>
12
-
13
- export function getDefaultHeader<T extends AnyRecord,V>(title: string) {
14
- return (
15
- (anchor: Comment) => snippetLiteral(defaultHeader)(anchor, () => title)
16
- ) as unknown as () => any
17
- }
18
-
19
- </script>
20
-
21
- <script lang='ts'>
22
-
23
- import { fromProps, snippetLiteral, type AnyRecord } from '../utility.svelte.js'
24
- import { ColumnState, type ColumnProps, type HeaderCtx, type ColumnSnippets } from './column-state.svelte.js'
25
-
26
- type T = $$Generic<Record<PropertyKey, any>>
27
- type V = $$Generic
28
-
29
- let {...props}: ColumnProps<T, V> = $props()
30
- const properties = fromProps(props)
31
-
32
- new ColumnState<T, V>(properties)
33
-
34
- </script>
35
-
36
-
37
- {#snippet defaultHeader(title: string)}
38
- {title}
1
+ <!-- @component
2
+
3
+ This is a description, \
4
+ on how to use this.
5
+
6
+ @example
7
+ <Component />
8
+
9
+ -->
10
+
11
+ <script module lang='ts'>
12
+
13
+ export function getDefaultHeader<T extends AnyRecord,V>(title: string) {
14
+ return (
15
+ (anchor: Comment) => snippetLiteral(defaultHeader)(anchor, () => title)
16
+ ) as unknown as () => any
17
+ }
18
+
19
+ </script>
20
+
21
+ <script lang='ts'>
22
+
23
+ import { fromProps, snippetLiteral, type AnyRecord } from '../utility.svelte.js'
24
+ import { ColumnState, type ColumnProps, type HeaderCtx, type ColumnSnippets } from './column-state.svelte.js'
25
+
26
+ type T = $$Generic<Record<PropertyKey, any>>
27
+ type V = $$Generic
28
+
29
+ let {...props}: ColumnProps<T, V> = $props()
30
+ const properties = fromProps(props)
31
+
32
+ new ColumnState<T, V>(properties)
33
+
34
+ </script>
35
+
36
+
37
+ {#snippet defaultHeader(title: string)}
38
+ {title}
39
39
  {/snippet}
@@ -1,24 +1,24 @@
1
- <!-- @component
2
-
3
- This is a description, \
4
- on how to use this.
5
-
6
- @example
7
- <Component />
8
-
9
- -->
10
-
11
- <script lang='ts'>
12
-
13
- import { ExpandableState, type ExpandableProps } from './expandable-state.svelte.js'
14
- import type { AnyRecord } from '../utility.svelte.js'
15
- import { fromProps } from '../utility.svelte.js'
16
-
17
- type T = $$Generic<AnyRecord>
18
-
19
- let { ...restProps }: ExpandableProps<T> = $props()
20
-
21
- const properties = fromProps(restProps)
22
- new ExpandableState<T>(properties)
23
-
24
- </script>
1
+ <!-- @component
2
+
3
+ This is a description, \
4
+ on how to use this.
5
+
6
+ @example
7
+ <Component />
8
+
9
+ -->
10
+
11
+ <script lang='ts'>
12
+
13
+ import { ExpandableState, type ExpandableProps } from './expandable-state.svelte.js'
14
+ import type { AnyRecord } from '../utility.svelte.js'
15
+ import { fromProps } from '../utility.svelte.js'
16
+
17
+ type T = $$Generic<AnyRecord>
18
+
19
+ let { ...restProps }: ExpandableProps<T> = $props()
20
+
21
+ const properties = fromProps(restProps)
22
+ new ExpandableState<T>(properties)
23
+
24
+ </script>
@@ -1,21 +1,21 @@
1
- <!-- @component
2
-
3
- This is a description, \
4
- on how to use this.
5
-
6
- @example
7
- <Component />
8
-
9
- -->
10
-
11
- <script lang='ts' generics='T extends Record<PropertyKey, unknown>'>
12
-
13
- import { PanelState, type PanelProps } from './panel-state.svelte.js'
14
- import { fromProps } from '../utility.svelte.js'
15
-
16
- let {...props}: PanelProps<T> = $props()
17
- const properties = fromProps(props)
18
-
19
- new PanelState<T>(properties)
20
-
1
+ <!-- @component
2
+
3
+ This is a description, \
4
+ on how to use this.
5
+
6
+ @example
7
+ <Component />
8
+
9
+ -->
10
+
11
+ <script lang='ts' generics='T extends Record<PropertyKey, unknown>'>
12
+
13
+ import { PanelState, type PanelProps } from './panel-state.svelte.js'
14
+ import { fromProps } from '../utility.svelte.js'
15
+
16
+ let {...props}: PanelProps<T> = $props()
17
+ const properties = fromProps(props)
18
+
19
+ new PanelState<T>(properties)
20
+
21
21
  </script>
@@ -1,24 +1,24 @@
1
- <!-- @component
2
-
3
- This is a description, \
4
- on how to use this.
5
-
6
- @example
7
- <Component />
8
-
9
- -->
10
-
11
- <script lang='ts'>
12
-
13
- import { RowState, type RowProps } from './row-state.svelte.js'
14
- import type { AnyRecord } from '../utility.svelte.js'
15
- import { fromProps } from '../utility.svelte.js'
16
-
17
- type T = $$Generic<AnyRecord>
18
-
19
- let { ...restProps }: RowProps<T> = $props()
20
-
21
- const properties = fromProps(restProps)
22
- new RowState<T>(properties)
23
-
24
- </script>
1
+ <!-- @component
2
+
3
+ This is a description, \
4
+ on how to use this.
5
+
6
+ @example
7
+ <Component />
8
+
9
+ -->
10
+
11
+ <script lang='ts'>
12
+
13
+ import { RowState, type RowProps } from './row-state.svelte.js'
14
+ import type { AnyRecord } from '../utility.svelte.js'
15
+ import { fromProps } from '../utility.svelte.js'
16
+
17
+ type T = $$Generic<AnyRecord>
18
+
19
+ let { ...restProps }: RowProps<T> = $props()
20
+
21
+ const properties = fromProps(restProps)
22
+ new RowState<T>(properties)
23
+
24
+ </script>