@emamid/svelte-data-table 0.0.21 → 1.0.1

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.
Files changed (81) hide show
  1. package/dist/DataTable.svelte +303 -239
  2. package/dist/DataTable.svelte.d.ts +30 -60
  3. package/dist/DataTableDataCell.svelte +157 -90
  4. package/dist/DataTableDataCell.svelte.d.ts +18 -27
  5. package/dist/DataTableHeaderCell.svelte +63 -21
  6. package/dist/DataTableHeaderCell.svelte.d.ts +9 -23
  7. package/dist/DataTableIcon.svelte +25 -0
  8. package/dist/DataTableIcon.svelte.d.ts +9 -0
  9. package/dist/DataTableRow.svelte +150 -80
  10. package/dist/DataTableRow.svelte.d.ts +26 -34
  11. package/dist/cells/Actions.d.ts +1 -1
  12. package/dist/cells/Actions.js +10 -11
  13. package/dist/cells/ActionsCell.svelte +58 -23
  14. package/dist/cells/ActionsCell.svelte.d.ts +9 -34
  15. package/dist/cells/ButtonCell.svelte +58 -16
  16. package/dist/cells/ButtonCell.svelte.d.ts +11 -20
  17. package/dist/cells/CheckboxCell.svelte +72 -19
  18. package/dist/cells/CheckboxCell.svelte.d.ts +11 -22
  19. package/dist/cells/InputCell.svelte +93 -49
  20. package/dist/cells/InputCell.svelte.d.ts +14 -25
  21. package/dist/cells/MultiSelectCell.svelte +85 -26
  22. package/dist/cells/MultiSelectCell.svelte.d.ts +15 -26
  23. package/dist/cells/NumberInputCell.svelte +90 -45
  24. package/dist/cells/NumberInputCell.svelte.d.ts +13 -24
  25. package/dist/cells/RadioCell.svelte +66 -0
  26. package/dist/cells/RadioCell.svelte.d.ts +12 -0
  27. package/dist/cells/RangeCell.svelte +66 -17
  28. package/dist/cells/RangeCell.svelte.d.ts +13 -22
  29. package/dist/cells/SelectCell.svelte +87 -26
  30. package/dist/cells/SelectCell.svelte.d.ts +15 -26
  31. package/dist/cells/SpinCell.svelte +91 -42
  32. package/dist/cells/SpinCell.svelte.d.ts +13 -28
  33. package/dist/cells/TabWrapper.svelte +23 -21
  34. package/dist/cells/TabWrapper.svelte.d.ts +10 -22
  35. package/dist/cells/index.d.ts +2 -4
  36. package/dist/cells/index.js +2 -4
  37. package/dist/common.d.ts +199 -53
  38. package/dist/common.js +30 -11
  39. package/dist/index.d.ts +2 -2
  40. package/dist/index.js +1 -1
  41. package/dist/themes/active.d.ts +4 -0
  42. package/dist/themes/active.js +12 -0
  43. package/dist/themes/daisyUI.d.ts +2 -0
  44. package/dist/themes/daisyUI.js +47 -0
  45. package/dist/themes/default.d.ts +2 -0
  46. package/dist/themes/default.js +57 -0
  47. package/dist/themes/iconify.d.ts +2 -0
  48. package/dist/themes/iconify.js +33 -0
  49. package/dist/themes/index.d.ts +4 -0
  50. package/dist/themes/index.js +4 -0
  51. package/package.json +28 -30
  52. package/dist/DataTable.doc.d.ts +0 -81
  53. package/dist/DataTable.doc.js +0 -81
  54. package/dist/cells/ActionsCell.doc.d.ts +0 -28
  55. package/dist/cells/ActionsCell.doc.js +0 -28
  56. package/dist/cells/ButtonCell.doc.d.ts +0 -9
  57. package/dist/cells/ButtonCell.doc.js +0 -9
  58. package/dist/cells/CheckboxCell.doc.d.ts +0 -6
  59. package/dist/cells/CheckboxCell.doc.js +0 -6
  60. package/dist/cells/InputCell.doc.d.ts +0 -6
  61. package/dist/cells/InputCell.doc.js +0 -6
  62. package/dist/cells/MultiSelectCell.doc.d.ts +0 -8
  63. package/dist/cells/MultiSelectCell.doc.js +0 -8
  64. package/dist/cells/NumberInputCell.doc.d.ts +0 -6
  65. package/dist/cells/NumberInputCell.doc.js +0 -6
  66. package/dist/cells/RangeCell.doc.d.ts +0 -7
  67. package/dist/cells/RangeCell.doc.js +0 -7
  68. package/dist/cells/RatingCell.doc.d.ts +0 -7
  69. package/dist/cells/RatingCell.doc.js +0 -7
  70. package/dist/cells/RatingCell.svelte +0 -13
  71. package/dist/cells/RatingCell.svelte.d.ts +0 -22
  72. package/dist/cells/SelectCell.doc.d.ts +0 -8
  73. package/dist/cells/SelectCell.doc.js +0 -8
  74. package/dist/cells/SpinCell.doc.d.ts +0 -13
  75. package/dist/cells/SpinCell.doc.js +0 -13
  76. package/dist/cells/TabWrapper.doc.d.ts +0 -5
  77. package/dist/cells/TabWrapper.doc.js +0 -5
  78. package/dist/cells/ToggleCell.doc.d.ts +0 -6
  79. package/dist/cells/ToggleCell.doc.js +0 -6
  80. package/dist/cells/ToggleCell.svelte +0 -21
  81. package/dist/cells/ToggleCell.svelte.d.ts +0 -23
@@ -0,0 +1,66 @@
1
+ <!-- @migration-task Error while migrating Svelte code: $$props is used together with named props in a way that cannot be automatically migrated. -->
2
+ <script lang="ts">
3
+ import {
4
+ getDataTableContext,
5
+ joinInputClasses,
6
+ } from '../common';
7
+ import type {
8
+ ColumnConfig,
9
+ DataCellChangedEvent,
10
+ } from '../common';
11
+ import { activeTheme } from '../themes/active';
12
+
13
+ interface Props {
14
+ column: ColumnConfig;
15
+ item: any;
16
+ maxValue: number;
17
+ oncellchanged?: (event: DataCellChangedEvent) => void;
18
+ value: number;
19
+ [key: string]: any;
20
+ }
21
+
22
+ let {
23
+ column,
24
+ item,
25
+ maxValue,
26
+ oncellchanged,
27
+ value,
28
+ ...inputProps
29
+ }: Props = $props();
30
+
31
+ let internalValue: number = $derived(value);
32
+ const tableTheme = getDataTableContext()?.theme || {};
33
+
34
+ const getClass = (element: string) => joinInputClasses(
35
+ 'radio',
36
+ element, [
37
+ activeTheme,
38
+ tableTheme,
39
+ column.theme,
40
+ ],
41
+ )
42
+
43
+ const spanClass = $derived(getClass('span'));
44
+ const inputClass = $derived(getClass('input'));
45
+ </script>
46
+
47
+ <span class={spanClass}>
48
+ {#each { length: maxValue}, buttonNum}
49
+ <input
50
+ checked={internalValue === buttonNum + 1}
51
+ class={inputClass}
52
+ onchange={() => {
53
+ internalValue = buttonNum + 1;
54
+ console.log('Radio selected value:', internalValue);
55
+ oncellchanged?.({
56
+ column,
57
+ item,
58
+ oldValue: value,
59
+ newValue: internalValue,
60
+ });
61
+ }}
62
+ type="radio"
63
+ {...inputProps}
64
+ />
65
+ {/each}
66
+ </span>
@@ -0,0 +1,12 @@
1
+ import type { ColumnConfig, DataCellChangedEvent } from '../common';
2
+ interface Props {
3
+ column: ColumnConfig;
4
+ item: any;
5
+ maxValue: number;
6
+ oncellchanged?: (event: DataCellChangedEvent) => void;
7
+ value: number;
8
+ [key: string]: any;
9
+ }
10
+ declare const RadioCell: import("svelte").Component<Props, {}, "">;
11
+ type RadioCell = ReturnType<typeof RadioCell>;
12
+ export default RadioCell;
@@ -1,19 +1,68 @@
1
- <script>import { createEventDispatcher } from "svelte";
2
- import { Range } from "flowbite-svelte";
3
- export let caption = "";
4
- export let column;
5
- export let item;
6
- export let value;
7
- let localValue = value;
8
- const dispatch = createEventDispatcher();
9
- const changed = () => {
10
- dispatch("cellChanged", {
11
- column,
12
- item,
13
- oldValue: value,
14
- newValue: localValue
15
- });
16
- };
1
+ <script lang="ts">
2
+ import {
3
+ getDataTableContext,
4
+ joinInputClasses,
5
+ } from '../common';
6
+ import type {
7
+ ColumnConfig,
8
+ DataCellChangedEvent,
9
+ } from '../common.ts';
10
+ import { activeTheme } from '../themes/active';
11
+
12
+ interface Props {
13
+ caption?: string;
14
+ column: ColumnConfig;
15
+ item: any;
16
+ max: number;
17
+ min: number;
18
+ oncellchanged?: (event: DataCellChangedEvent) => void;
19
+ value: number;
20
+ [key: string]: any;
21
+ };
22
+
23
+ let {
24
+ caption,
25
+ column,
26
+ inputType = 'text',
27
+ item,
28
+ max = 100,
29
+ min = 0,
30
+ oncellchanged,
31
+ value,
32
+ ...inputProps
33
+ }: Props = $props();
34
+
35
+ let internalValue = $derived(value);
36
+ const tableTheme = getDataTableContext()?.theme || {};
37
+
38
+ const changed = () => {
39
+ if (value !== internalValue) {
40
+ oncellchanged?.({
41
+ column,
42
+ item,
43
+ oldValue: value,
44
+ newValue: internalValue,
45
+ });
46
+ }
47
+ };
48
+
49
+ const inputClass = $derived(joinInputClasses(
50
+ 'range',
51
+ 'input', [
52
+ activeTheme,
53
+ tableTheme,
54
+ column.theme,
55
+ ],
56
+ ))
17
57
  </script>
18
58
 
19
- <Range {...$$props} bind:value={localValue} on:change={changed}>{#if caption}{caption}{/if}</Range>
59
+ <input
60
+ class={inputClass}
61
+ {max}
62
+ {min}
63
+ onchange={changed}
64
+ type="range"
65
+ bind:value={internalValue}
66
+ {...inputProps}
67
+ />
68
+ {#if caption}{caption}{/if}
@@ -1,23 +1,14 @@
1
- import { SvelteComponent } from "svelte";
2
- import type { ColumnConfig } from '../common.ts';
3
- declare const __propDef: {
4
- props: {
5
- [x: string]: any;
6
- caption?: string | undefined;
7
- column: ColumnConfig;
8
- item: any;
9
- value: any;
10
- };
11
- events: {
12
- cellChanged: CustomEvent<any>;
13
- } & {
14
- [evt: string]: CustomEvent<any>;
15
- };
16
- slots: {};
17
- };
18
- export type RangeCellProps = typeof __propDef.props;
19
- export type RangeCellEvents = typeof __propDef.events;
20
- export type RangeCellSlots = typeof __propDef.slots;
21
- export default class RangeCell extends SvelteComponent<RangeCellProps, RangeCellEvents, RangeCellSlots> {
1
+ import type { ColumnConfig, DataCellChangedEvent } from '../common.ts';
2
+ interface Props {
3
+ caption?: string;
4
+ column: ColumnConfig;
5
+ item: any;
6
+ max: number;
7
+ min: number;
8
+ oncellchanged?: (event: DataCellChangedEvent) => void;
9
+ value: number;
10
+ [key: string]: any;
22
11
  }
23
- export {};
12
+ declare const RangeCell: import("svelte").Component<Props, {}, "">;
13
+ type RangeCell = ReturnType<typeof RangeCell>;
14
+ export default RangeCell;
@@ -1,30 +1,91 @@
1
- <script>import { createEventDispatcher } from "svelte";
2
- import { Select } from "flowbite-svelte";
3
- import TabWrapper from "./TabWrapper.svelte";
4
- export let item;
5
- export let column;
6
- export let displayProp = "name";
7
- export let valueProp = "id";
8
- export let items = [];
9
- export let value;
10
- let newValue = value;
11
- const dispatch = createEventDispatcher();
12
- $:
13
- if (value !== newValue) {
14
- dispatch("cellChanged", {
15
- column,
16
- item,
17
- oldValue: value,
18
- newValue
19
- });
20
- }
1
+ <script lang="ts">
2
+ import {
3
+ getDataTableContext,
4
+ joinInputClasses,
5
+ } from '../common';
6
+ import type {
7
+ ColumnConfig,
8
+ DataCellChangedEvent,
9
+ DataCellEvent,
10
+ } from '../common';
11
+ import { activeTheme } from '../themes/active';
12
+
13
+ import TabWrapper from './TabWrapper.svelte';
14
+
15
+ interface Props {
16
+ column: ColumnConfig;
17
+ item: any;
18
+ displayProp?: string;
19
+ valueProp?: string;
20
+ items: any[];
21
+ oncellchanged?: (event: DataCellChangedEvent) => void;
22
+ onnexttab?: (event: DataCellEvent) => void;
23
+ onprevtab?: (event: DataCellEvent) => void;
24
+ value: any;
25
+ [key: string]: any;
26
+ }
27
+
28
+ let {
29
+ column,
30
+ item,
31
+ displayProp = 'name',
32
+ valueProp = 'id',
33
+ items,
34
+ oncellchanged,
35
+ onnexttab,
36
+ onprevtab,
37
+ value,
38
+ ...inputProps
39
+ }: Props = $props();
40
+
41
+ let newValue = $derived(value);
42
+ const tableTheme = getDataTableContext()?.theme || {};
43
+
44
+ const dispatchCellChanged = () => {
45
+ if (value !== newValue) {
46
+ oncellchanged?.({
47
+ column,
48
+ item,
49
+ oldValue: value,
50
+ newValue: newValue,
51
+ });
52
+ }
53
+ };
54
+
55
+ const getClass = (element: string) => joinInputClasses(
56
+ 'select',
57
+ element, [
58
+ activeTheme,
59
+ tableTheme,
60
+ column.theme,
61
+ ],
62
+ )
63
+
64
+ const selectClass = $derived(getClass('select'));
65
+ const optionClass = $derived(getClass('option'));
21
66
  </script>
22
67
 
23
- <TabWrapper {column} {item} on:prevTab on:nextTab>
24
- <Select
25
- {...$$props}
26
- items={items.map((item) => ({ value: item[valueProp], name: item[displayProp] }))}
27
- bind:value={newValue}
68
+ <TabWrapper
69
+ {column}
70
+ {item}
71
+ {onprevtab}
72
+ {onnexttab}
73
+ >
74
+ <!-- svelte-ignore a11y_autofocus -->
75
+ <select
28
76
  autofocus
29
- />
77
+ class={selectClass}
78
+ onchange={dispatchCellChanged}
79
+ bind:value={newValue}
80
+ {...inputProps}
81
+ >
82
+ {#each items as selectItem}
83
+ <option
84
+ class={optionClass}
85
+ value={selectItem[valueProp]}
86
+ >
87
+ {selectItem[displayProp]}
88
+ </option>
89
+ {/each}
90
+ </select>
30
91
  </TabWrapper>
@@ -1,27 +1,16 @@
1
- import { SvelteComponent } from "svelte";
2
- import type { ColumnConfig } from '../common.js';
3
- declare const __propDef: {
4
- props: {
5
- [x: string]: any;
6
- item: any;
7
- column: ColumnConfig;
8
- displayProp?: string | undefined;
9
- valueProp?: string | undefined;
10
- items?: any[] | undefined;
11
- value: any;
12
- };
13
- events: {
14
- prevTab: CustomEvent<any>;
15
- nextTab: CustomEvent<any>;
16
- cellChanged: CustomEvent<any>;
17
- } & {
18
- [evt: string]: CustomEvent<any>;
19
- };
20
- slots: {};
21
- };
22
- export type SelectCellProps = typeof __propDef.props;
23
- export type SelectCellEvents = typeof __propDef.events;
24
- export type SelectCellSlots = typeof __propDef.slots;
25
- export default class SelectCell extends SvelteComponent<SelectCellProps, SelectCellEvents, SelectCellSlots> {
1
+ import type { ColumnConfig, DataCellChangedEvent, DataCellEvent } from '../common';
2
+ interface Props {
3
+ column: ColumnConfig;
4
+ item: any;
5
+ displayProp?: string;
6
+ valueProp?: string;
7
+ items: any[];
8
+ oncellchanged?: (event: DataCellChangedEvent) => void;
9
+ onnexttab?: (event: DataCellEvent) => void;
10
+ onprevtab?: (event: DataCellEvent) => void;
11
+ value: any;
12
+ [key: string]: any;
26
13
  }
27
- export {};
14
+ declare const SelectCell: import("svelte").Component<Props, {}, "">;
15
+ type SelectCell = ReturnType<typeof SelectCell>;
16
+ export default SelectCell;
@@ -1,52 +1,101 @@
1
- <script>import { createEventDispatcher } from "svelte";
2
- import { Button } from "flowbite-svelte";
3
- import { MinusSolid, PlusSolid } from "flowbite-svelte-icons";
4
- export let item;
5
- export let column;
6
- export let value;
7
- export let decValue = 1;
8
- export let incValue = 1;
9
- export let minValue = void 0;
10
- export let maxValue = void 0;
11
- export let minusIcon = MinusSolid;
12
- export let minusIconClass = "pr-1 w-3 h-3";
13
- export let plusIcon = PlusSolid;
14
- export let plusIconClass = "pr-1 w-3 h-3";
15
- const dispatch = createEventDispatcher();
16
- const decrement = () => {
17
- dispatch("cellChanged", {
18
- column,
19
- item,
20
- oldValue: value,
21
- newValue: (value || 0) - decValue
22
- });
23
- };
24
- const increment = () => {
25
- dispatch("cellChanged", {
26
- column,
27
- item,
28
- oldValue: value,
29
- newValue: (value || 0) + incValue
30
- });
31
- };
1
+ <script lang="ts">
2
+ import {
3
+ getDataTableContext,
4
+ getInputIcon,
5
+ joinInputClasses,
6
+ } from '../common';
7
+ import type {
8
+ ColumnConfig,
9
+ DataCellChangedEvent,
10
+ } from '../common';
11
+ import { activeTheme } from '../themes/active';
12
+
13
+ import DataTableIcon from '../DataTableIcon.svelte';
14
+
15
+ interface Props {
16
+ column: ColumnConfig;
17
+ decValue?: number;
18
+ incValue?: number;
19
+ item: any;
20
+ maxValue?: number | undefined;
21
+ minValue?: number | undefined;
22
+ oncellchanged?: (event: DataCellChangedEvent) => void;
23
+ value: any;
24
+ }
25
+
26
+ let {
27
+ column,
28
+ decValue = 1,
29
+ incValue = 1,
30
+ item,
31
+ maxValue = undefined,
32
+ minValue = undefined,
33
+ oncellchanged,
34
+ value,
35
+ }: Props = $props();
36
+
37
+ const tableTheme = getDataTableContext()?.theme || {};
38
+
39
+ const decrement = () => {
40
+ oncellchanged?.({
41
+ column,
42
+ item,
43
+ oldValue: value,
44
+ newValue: (value || 0) - decValue,
45
+ });
46
+ };
47
+
48
+ const increment = () => {
49
+ oncellchanged?.({
50
+ column,
51
+ item,
52
+ oldValue: value,
53
+ newValue: (value || 0) + incValue,
54
+ });
55
+ };
56
+
57
+ const getClass = (element: string) => joinInputClasses(
58
+ 'spinner',
59
+ element, [
60
+ activeTheme,
61
+ tableTheme,
62
+ column.theme,
63
+ ],
64
+ )
65
+
66
+ const getIcon = (propName: string) => getInputIcon(
67
+ 'spinner',
68
+ propName, [
69
+ activeTheme,
70
+ tableTheme,
71
+ column.theme,
72
+ ],
73
+ )
74
+
75
+ let divClass = $derived(getClass('div'));
76
+ let minusButtonClass = $derived(getClass('minusButton'));
77
+ let plusButtonClass = $derived(getClass('plusButton'));
78
+
79
+ let minusIcon = $derived(getIcon('minusIcon'));
80
+ let plusIcon =$derived(getIcon('plusIcon'));
32
81
  </script>
33
82
 
34
- <div class="spinner">
35
- <Button
36
- color="none"
37
- class="pr-1"
38
- on:click={decrement}
83
+ <div class={divClass}>
84
+ <button
39
85
  disabled={minValue !== undefined && value - decValue < minValue}
40
- ><svelte:component this={minusIcon} class={minusIconClass} /></Button
86
+ class={minusButtonClass}
87
+ onclick={decrement}
41
88
  >
89
+ <DataTableIcon icon={minusIcon}/>
90
+ </button>
42
91
  {value || 0}
43
- <Button
44
- color="none"
45
- class="pl-1"
46
- on:click={increment}
92
+ <button
47
93
  disabled={maxValue !== undefined && value + incValue > maxValue}
48
- ><svelte:component this={plusIcon} class={plusIconClass} /></Button
94
+ class={plusButtonClass}
95
+ onclick={increment}
49
96
  >
97
+ <DataTableIcon icon={plusIcon}/>
98
+ </button>
50
99
  </div>
51
100
 
52
101
  <style>
@@ -1,29 +1,14 @@
1
- import { SvelteComponent } from "svelte";
2
- import type { ColumnConfig } from '../common.js';
3
- declare const __propDef: {
4
- props: {
5
- item: any;
6
- column: ColumnConfig;
7
- value: any;
8
- decValue?: number | undefined;
9
- incValue?: number | undefined;
10
- minValue?: number | undefined;
11
- maxValue?: number | undefined;
12
- minusIcon?: ConstructorOfATypedSvelteComponent | undefined;
13
- minusIconClass?: string | undefined;
14
- plusIcon?: ConstructorOfATypedSvelteComponent | undefined;
15
- plusIconClass?: string | undefined;
16
- };
17
- events: {
18
- cellChanged: CustomEvent<any>;
19
- } & {
20
- [evt: string]: CustomEvent<any>;
21
- };
22
- slots: {};
23
- };
24
- export type SpinCellProps = typeof __propDef.props;
25
- export type SpinCellEvents = typeof __propDef.events;
26
- export type SpinCellSlots = typeof __propDef.slots;
27
- export default class SpinCell extends SvelteComponent<SpinCellProps, SpinCellEvents, SpinCellSlots> {
1
+ import type { ColumnConfig, DataCellChangedEvent } from '../common';
2
+ interface Props {
3
+ column: ColumnConfig;
4
+ decValue?: number;
5
+ incValue?: number;
6
+ item: any;
7
+ maxValue?: number | undefined;
8
+ minValue?: number | undefined;
9
+ oncellchanged?: (event: DataCellChangedEvent) => void;
10
+ value: any;
28
11
  }
29
- export {};
12
+ declare const SpinCell: import("svelte").Component<Props, {}, "">;
13
+ type SpinCell = ReturnType<typeof SpinCell>;
14
+ export default SpinCell;
@@ -1,23 +1,25 @@
1
- <script>import { createEventDispatcher } from "svelte";
2
- export let item = null;
3
- export let column = null;
4
- const dispatch = createEventDispatcher();
5
- const prevTab = (_event) => {
6
- dispatch("prevTab", {
7
- column,
8
- item
9
- });
10
- };
11
- const nextTab = (_event) => {
12
- dispatch("nextTab", {
13
- column,
14
- item
15
- });
16
- };
1
+ <script lang="ts">
2
+ import type { ColumnConfig, DataCellEvent } from '../common';
3
+
4
+ interface Props {
5
+ item: any;
6
+ column: ColumnConfig;
7
+ children?: import('svelte').Snippet;
8
+ onnexttab?: (event: DataCellEvent) => void;
9
+ onprevtab?: (event: DataCellEvent) => void;
10
+ }
11
+
12
+ let {
13
+ item,
14
+ column,
15
+ children,
16
+ onnexttab,
17
+ onprevtab,
18
+ }: Props = $props();
17
19
  </script>
18
20
 
19
- <!-- svelte-ignore a11y-no-noninteractive-tabindex-->
20
- <div tabindex="0" on:focus={prevTab} />
21
- <slot />
22
- <!-- svelte-ignore a11y-no-noninteractive-tabindex-->
23
- <div tabindex="0" on:focus={nextTab} />
21
+ <!-- svelte-ignore a11y_no_noninteractive_tabindex-->
22
+ <div tabindex="0" onfocus={() => onprevtab?.({ column, item })}></div>
23
+ {@render children?.()}
24
+ <!-- svelte-ignore a11y_no_noninteractive_tabindex-->
25
+ <div tabindex="0" onfocus={() => onnexttab?.({ column, item })}></div>
@@ -1,23 +1,11 @@
1
- import { SvelteComponent } from "svelte";
2
- import type { ColumnConfig } from '../common.js';
3
- declare const __propDef: {
4
- props: {
5
- item?: any;
6
- column?: ColumnConfig | null | undefined;
7
- };
8
- events: {
9
- prevTab: CustomEvent<any>;
10
- nextTab: CustomEvent<any>;
11
- } & {
12
- [evt: string]: CustomEvent<any>;
13
- };
14
- slots: {
15
- default: {};
16
- };
17
- };
18
- export type TabWrapperProps = typeof __propDef.props;
19
- export type TabWrapperEvents = typeof __propDef.events;
20
- export type TabWrapperSlots = typeof __propDef.slots;
21
- export default class TabWrapper extends SvelteComponent<TabWrapperProps, TabWrapperEvents, TabWrapperSlots> {
1
+ import type { ColumnConfig, DataCellEvent } from '../common';
2
+ interface Props {
3
+ item: any;
4
+ column: ColumnConfig;
5
+ children?: import('svelte').Snippet;
6
+ onnexttab?: (event: DataCellEvent) => void;
7
+ onprevtab?: (event: DataCellEvent) => void;
22
8
  }
23
- export {};
9
+ declare const TabWrapper: import("svelte").Component<Props, {}, "">;
10
+ type TabWrapper = ReturnType<typeof TabWrapper>;
11
+ export default TabWrapper;
@@ -13,13 +13,11 @@ export * from './NumberInputCell.svelte';
13
13
  export { default as NumberInputCell } from './NumberInputCell.svelte';
14
14
  export * from './RangeCell.svelte';
15
15
  export { default as RangeCell } from './RangeCell.svelte';
16
- export * from './RatingCell.svelte';
17
- export { default as RatingCell } from './RatingCell.svelte';
16
+ export * from './RadioCell.svelte';
17
+ export { default as RadioCell } from './RadioCell.svelte';
18
18
  export * from './SelectCell.svelte';
19
19
  export { default as SelectCell } from './SelectCell.svelte';
20
20
  export * from './SpinCell.svelte';
21
21
  export { default as SpinCell } from './SpinCell.svelte';
22
22
  export * from './TabWrapper.svelte';
23
23
  export { default as TabWrapper } from './TabWrapper.svelte';
24
- export * from './ToggleCell.svelte';
25
- export { default as ToggleCell } from './ToggleCell.svelte';
@@ -13,13 +13,11 @@ export * from './NumberInputCell.svelte';
13
13
  export { default as NumberInputCell } from './NumberInputCell.svelte';
14
14
  export * from './RangeCell.svelte';
15
15
  export { default as RangeCell } from './RangeCell.svelte';
16
- export * from './RatingCell.svelte';
17
- export { default as RatingCell } from './RatingCell.svelte';
16
+ export * from './RadioCell.svelte';
17
+ export { default as RadioCell } from './RadioCell.svelte';
18
18
  export * from './SelectCell.svelte';
19
19
  export { default as SelectCell } from './SelectCell.svelte';
20
20
  export * from './SpinCell.svelte';
21
21
  export { default as SpinCell } from './SpinCell.svelte';
22
22
  export * from './TabWrapper.svelte';
23
23
  export { default as TabWrapper } from './TabWrapper.svelte';
24
- export * from './ToggleCell.svelte';
25
- export { default as ToggleCell } from './ToggleCell.svelte';