@universal-ember/table 3.0.2 → 3.0.3
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/declarations/-private/-type-tests/plugin-properties.test.d.ts +2 -0
- package/declarations/-private/-type-tests/plugin-properties.test.d.ts.map +1 -0
- package/declarations/-private/-type-tests/plugin-with.test.d.ts +2 -0
- package/declarations/-private/-type-tests/plugin-with.test.d.ts.map +1 -0
- package/declarations/-private/-type-tests/plugins-accessors.test.d.ts +2 -0
- package/declarations/-private/-type-tests/plugins-accessors.test.d.ts.map +1 -0
- package/declarations/-private/-type-tests/plugins-signature-from.test.d.ts +2 -0
- package/declarations/-private/-type-tests/plugins-signature-from.test.d.ts.map +1 -0
- package/declarations/-private/-type-tests/plugins-signature-utils.test.d.ts +2 -0
- package/declarations/-private/-type-tests/plugins-signature-utils.test.d.ts.map +1 -0
- package/declarations/-private/-type-tests/table-api.test.d.ts +2 -0
- package/declarations/-private/-type-tests/table-api.test.d.ts.map +1 -0
- package/declarations/-private/-type-tests/table-config.test.d.ts +2 -0
- package/declarations/-private/-type-tests/table-config.test.d.ts.map +1 -0
- package/declarations/-private/column.d.ts +18 -0
- package/declarations/-private/column.d.ts.map +1 -0
- package/declarations/-private/ember-compat.d.ts +8 -0
- package/declarations/-private/ember-compat.d.ts.map +1 -0
- package/declarations/-private/interfaces/column.d.ts +63 -0
- package/declarations/-private/interfaces/column.d.ts.map +1 -0
- package/declarations/-private/interfaces/index.d.ts +8 -0
- package/declarations/-private/interfaces/index.d.ts.map +1 -0
- package/declarations/-private/interfaces/modifier.d.ts +7 -0
- package/declarations/-private/interfaces/modifier.d.ts.map +1 -0
- package/declarations/-private/interfaces/pagination.d.ts +17 -0
- package/declarations/-private/interfaces/pagination.d.ts.map +1 -0
- package/declarations/-private/interfaces/plugins.d.ts +315 -0
- package/declarations/-private/interfaces/plugins.d.ts.map +1 -0
- package/declarations/-private/interfaces/preferences.d.ts +74 -0
- package/declarations/-private/interfaces/preferences.d.ts.map +1 -0
- package/declarations/-private/interfaces/selection.d.ts +36 -0
- package/declarations/-private/interfaces/selection.d.ts.map +1 -0
- package/declarations/-private/interfaces/table.d.ts +109 -0
- package/declarations/-private/interfaces/table.d.ts.map +1 -0
- package/declarations/-private/js-helper.d.ts +39 -0
- package/declarations/-private/js-helper.d.ts.map +1 -0
- package/declarations/-private/preferences.d.ts +45 -0
- package/declarations/-private/preferences.d.ts.map +1 -0
- package/declarations/-private/private-types.d.ts +6 -0
- package/declarations/-private/private-types.d.ts.map +1 -0
- package/declarations/-private/row.d.ts +12 -0
- package/declarations/-private/row.d.ts.map +1 -0
- package/declarations/-private/table.d.ts +136 -0
- package/declarations/-private/table.d.ts.map +1 -0
- package/declarations/-private/utils.d.ts +3 -0
- package/declarations/-private/utils.d.ts.map +1 -0
- package/declarations/index.d.ts +14 -0
- package/declarations/index.d.ts.map +1 -0
- package/declarations/plugins/-private/base.d.ts +281 -0
- package/declarations/plugins/-private/base.d.ts.map +1 -0
- package/declarations/plugins/-private/utils.d.ts +22 -0
- package/declarations/plugins/-private/utils.d.ts.map +1 -0
- package/declarations/plugins/column-reordering/helpers.d.ts +33 -0
- package/declarations/plugins/column-reordering/helpers.d.ts.map +1 -0
- package/declarations/plugins/column-reordering/index.d.ts +5 -0
- package/declarations/plugins/column-reordering/index.d.ts.map +1 -0
- package/declarations/plugins/column-reordering/plugin.d.ts +148 -0
- package/declarations/plugins/column-reordering/plugin.d.ts.map +1 -0
- package/declarations/plugins/column-reordering/utils.d.ts +8 -0
- package/declarations/plugins/column-reordering/utils.d.ts.map +1 -0
- package/declarations/plugins/column-resizing/handle.d.ts +128 -0
- package/declarations/plugins/column-resizing/handle.d.ts.map +1 -0
- package/declarations/plugins/column-resizing/helpers.d.ts +35 -0
- package/declarations/plugins/column-resizing/helpers.d.ts.map +1 -0
- package/declarations/plugins/column-resizing/index.d.ts +6 -0
- package/declarations/plugins/column-resizing/index.d.ts.map +1 -0
- package/declarations/plugins/column-resizing/plugin.d.ts +160 -0
- package/declarations/plugins/column-resizing/plugin.d.ts.map +1 -0
- package/declarations/plugins/column-resizing/resize-observer.d.ts +14 -0
- package/declarations/plugins/column-resizing/resize-observer.d.ts.map +1 -0
- package/declarations/plugins/column-resizing/utils.d.ts +22 -0
- package/declarations/plugins/column-resizing/utils.d.ts.map +1 -0
- package/declarations/plugins/column-visibility/helpers.d.ts +18 -0
- package/declarations/plugins/column-visibility/helpers.d.ts.map +1 -0
- package/declarations/plugins/column-visibility/index.d.ts +5 -0
- package/declarations/plugins/column-visibility/index.d.ts.map +1 -0
- package/declarations/plugins/column-visibility/plugin.d.ts +64 -0
- package/declarations/plugins/column-visibility/plugin.d.ts.map +1 -0
- package/declarations/plugins/data-sorting/helpers.d.ts +38 -0
- package/declarations/plugins/data-sorting/helpers.d.ts.map +1 -0
- package/declarations/plugins/data-sorting/index.d.ts +7 -0
- package/declarations/plugins/data-sorting/index.d.ts.map +1 -0
- package/declarations/plugins/data-sorting/plugin.d.ts +102 -0
- package/declarations/plugins/data-sorting/plugin.d.ts.map +1 -0
- package/declarations/plugins/data-sorting/types.d.ts +23 -0
- package/declarations/plugins/data-sorting/types.d.ts.map +1 -0
- package/declarations/plugins/index.d.ts +6 -0
- package/declarations/plugins/index.d.ts.map +1 -0
- package/declarations/plugins/metadata/helpers.d.ts +4 -0
- package/declarations/plugins/metadata/helpers.d.ts.map +1 -0
- package/declarations/plugins/metadata/index.d.ts +5 -0
- package/declarations/plugins/metadata/index.d.ts.map +1 -0
- package/declarations/plugins/metadata/plugin.d.ts +25 -0
- package/declarations/plugins/metadata/plugin.d.ts.map +1 -0
- package/declarations/plugins/row-selection/helpers.d.ts +6 -0
- package/declarations/plugins/row-selection/helpers.d.ts.map +1 -0
- package/declarations/plugins/row-selection/index.d.ts +5 -0
- package/declarations/plugins/row-selection/index.d.ts.map +1 -0
- package/declarations/plugins/row-selection/plugin.d.ts +80 -0
- package/declarations/plugins/row-selection/plugin.d.ts.map +1 -0
- package/declarations/plugins/sticky-columns/helpers.d.ts +17 -0
- package/declarations/plugins/sticky-columns/helpers.d.ts.map +1 -0
- package/declarations/plugins/sticky-columns/index.d.ts +5 -0
- package/declarations/plugins/sticky-columns/index.d.ts.map +1 -0
- package/declarations/plugins/sticky-columns/plugin.d.ts +70 -0
- package/declarations/plugins/sticky-columns/plugin.d.ts.map +1 -0
- package/declarations/test-support/index.d.ts +15 -0
- package/declarations/test-support/index.d.ts.map +1 -0
- package/declarations/utils.d.ts +26 -0
- package/declarations/utils.d.ts.map +1 -0
- package/package.json +2 -1
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { BasePlugin } from '../-private/base.ts';
|
|
2
|
+
import type { Row, Table } from '../../index.ts';
|
|
3
|
+
import type { PluginSignature, RowApi } from '../../-private/interfaces';
|
|
4
|
+
export interface Signature<DataType = any, Key = DataType> extends PluginSignature {
|
|
5
|
+
Meta: {
|
|
6
|
+
Table: TableMeta;
|
|
7
|
+
Row: RowMeta;
|
|
8
|
+
};
|
|
9
|
+
Options: {
|
|
10
|
+
Plugin: {
|
|
11
|
+
/**
|
|
12
|
+
* A set of selected things using the same type of Identifier
|
|
13
|
+
* returned from `key`
|
|
14
|
+
*/
|
|
15
|
+
selection: Set<Key> | Array<Key>;
|
|
16
|
+
} & ({
|
|
17
|
+
/**
|
|
18
|
+
* For a given row's data, how should the key be determined?
|
|
19
|
+
* this could be a remote id from a database, or some other attribute
|
|
20
|
+
*
|
|
21
|
+
* This could be useful for indicating in UI if a particular item is selected.
|
|
22
|
+
*
|
|
23
|
+
* If not provided, the row's data will be used as the key
|
|
24
|
+
*/
|
|
25
|
+
key: (data: DataType) => Key;
|
|
26
|
+
/**
|
|
27
|
+
* When a row is clicked, this will be invoked,
|
|
28
|
+
* allowing you to update your selection object
|
|
29
|
+
*/
|
|
30
|
+
onSelect: (item: Key, row: Row<DataType>) => void;
|
|
31
|
+
/**
|
|
32
|
+
* When a row is clicked (and the row is selected), this will be invoked,
|
|
33
|
+
* allowing you to update your selection object
|
|
34
|
+
*/
|
|
35
|
+
onDeselect: (item: Key, row: Row<DataType>) => void;
|
|
36
|
+
} | {
|
|
37
|
+
/**
|
|
38
|
+
* When a row is clicked (and the row is not selected), this will be invoked,
|
|
39
|
+
* allowing you to update your selection object
|
|
40
|
+
*/
|
|
41
|
+
onSelect: (item: DataType | any, row: Row<DataType>) => void;
|
|
42
|
+
/**
|
|
43
|
+
* When a row is clicked (and the row is selected), this will be invoked,
|
|
44
|
+
* allowing you to update your selection object
|
|
45
|
+
*/
|
|
46
|
+
onDeselect: (item: DataType | any, row: Row<DataType>) => void;
|
|
47
|
+
});
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* This plugin provides a means of managing selection of a single row in a table.
|
|
52
|
+
*
|
|
53
|
+
* The state of what is actually selected is managed by you, but this plugin
|
|
54
|
+
* will wire up the click listeners as well as let you know which *data* is clicked.
|
|
55
|
+
*/
|
|
56
|
+
export declare class RowSelection<DataType = any, Key = DataType> extends BasePlugin<Signature<DataType, Key>> {
|
|
57
|
+
#private;
|
|
58
|
+
name: string;
|
|
59
|
+
meta: {
|
|
60
|
+
row: typeof RowMeta;
|
|
61
|
+
table: typeof TableMeta;
|
|
62
|
+
};
|
|
63
|
+
constructor(table: Table);
|
|
64
|
+
rowModifier: (element: HTMLElement, { row }: RowApi<Table<any>>) => () => void;
|
|
65
|
+
}
|
|
66
|
+
declare class TableMeta {
|
|
67
|
+
#private;
|
|
68
|
+
constructor(table: Table);
|
|
69
|
+
get selection(): Set<unknown>;
|
|
70
|
+
}
|
|
71
|
+
declare class RowMeta {
|
|
72
|
+
#private;
|
|
73
|
+
constructor(row: Row<any>);
|
|
74
|
+
get isSelected(): boolean;
|
|
75
|
+
toggle: () => void;
|
|
76
|
+
select: () => void;
|
|
77
|
+
deselect: () => void;
|
|
78
|
+
}
|
|
79
|
+
export {};
|
|
80
|
+
//# sourceMappingURL=plugin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../src/plugins/row-selection/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAiB,MAAM,qBAAqB,CAAC;AAEhE,OAAO,KAAK,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AACjD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,2BAA2B,CAAC;AAEzE,MAAM,WAAW,SAAS,CAAC,QAAQ,GAAG,GAAG,EAAE,GAAG,GAAG,QAAQ,CACvD,SAAQ,eAAe;IACvB,IAAI,EAAE;QACJ,KAAK,EAAE,SAAS,CAAC;QACjB,GAAG,EAAE,OAAO,CAAC;KACd,CAAC;IACF,OAAO,EAAE;QACP,MAAM,EAAE;YACN;;;eAGG;YACH,SAAS,EAAE,GAAG,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC,GAAG,CAAC,CAAC;SAClC,GAAG,CACA;YACE;;;;;;;eAOG;YACH,GAAG,EAAE,CAAC,IAAI,EAAE,QAAQ,KAAK,GAAG,CAAC;YAC7B;;;eAGG;YACH,QAAQ,EAAE,CAAC,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,KAAK,IAAI,CAAC;YAClD;;;eAGG;YACH,UAAU,EAAE,CAAC,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,KAAK,IAAI,CAAC;SACrD,GACD;YACE;;;eAGG;YACH,QAAQ,EAAE,CAAC,IAAI,EAAE,QAAQ,GAAG,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,KAAK,IAAI,CAAC;YAC7D;;;eAGG;YACH,UAAU,EAAE,CAAC,IAAI,EAAE,QAAQ,GAAG,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,QAAQ,CAAC,KAAK,IAAI,CAAC;SAChE,CACJ,CAAC;KACH,CAAC;CACH;AAED;;;;;GAKG;AACH,qBAAa,YAAY,CAAC,QAAQ,GAAG,GAAG,EAAE,GAAG,GAAG,QAAQ,CAAE,SAAQ,UAAU,CAC1E,SAAS,CAAC,QAAQ,EAAE,GAAG,CAAC,CACzB;;IACC,IAAI,SAAmB;IAEvB,IAAI;;;MAGF;gBAEU,KAAK,EAAE,KAAK;IAcxB,WAAW,GAAI,SAAS,WAAW,EAAE,SAAS,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,gBAU9D;CAiCH;AAED,cAAM,SAAS;;gBAGD,KAAK,EAAE,KAAK;IAIxB,IACI,SAAS,IAAI,GAAG,CAAC,OAAO,CAAC,CAa5B;CACF;AAED,cAAM,OAAO;;gBAGC,GAAG,EAAE,GAAG,CAAC,GAAG,CAAC;IAIzB,IAAI,UAAU,IAAI,OAAO,CAaxB;IAED,MAAM,aAQJ;IAEF,MAAM,aAYJ;IAEF,QAAQ,aAYN;CACH"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { htmlSafe } from '@ember/template';
|
|
2
|
+
import type { Column } from '../../index.ts';
|
|
3
|
+
export declare const isSticky: <DataType = unknown>(column: Column<DataType>) => boolean;
|
|
4
|
+
export declare const styleFor: <DataType = unknown>(column: Column<DataType>) => Partial<CSSStyleDeclaration>;
|
|
5
|
+
/**
|
|
6
|
+
* In this plugin, both header and cells have the same styles,
|
|
7
|
+
* if applicable.
|
|
8
|
+
*
|
|
9
|
+
* Until this RFC https://github.com/emberjs/rfcs/pull/883
|
|
10
|
+
* is merged and implemented, we can't performantly
|
|
11
|
+
* use modifiers for apply styles.
|
|
12
|
+
*
|
|
13
|
+
* In the mean time, we'll need to append style strings, which is more work
|
|
14
|
+
* for consumers, but is a reasonable trade-off for now.
|
|
15
|
+
*/
|
|
16
|
+
export declare const styleStringFor: <DataType = unknown>(column: Column<DataType>) => ReturnType<typeof htmlSafe>;
|
|
17
|
+
//# sourceMappingURL=helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../src/plugins/sticky-columns/helpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAK3C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAE7C,eAAO,MAAM,QAAQ,GAAI,QAAQ,GAAG,OAAO,EAAE,QAAQ,MAAM,CAAC,QAAQ,CAAC,YACrB,CAAC;AAEjD,eAAO,MAAM,QAAQ,GAAI,QAAQ,GAAG,OAAO,EACzC,QAAQ,MAAM,CAAC,QAAQ,CAAC,KACvB,OAAO,CAAC,mBAAmB,CAAgD,CAAC;AAE/E;;;;;;;;;;GAUG;AACH,eAAO,MAAM,cAAc,GAAI,QAAQ,GAAG,OAAO,EAC/C,QAAQ,MAAM,CAAC,QAAQ,CAAC,KACvB,UAAU,CAAC,OAAO,QAAQ,CAc5B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/plugins/sticky-columns/index.ts"],"names":[],"mappings":"AACA,cAAc,cAAc,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,aAAa,IAAI,MAAM,EAAE,MAAM,aAAa,CAAC;AAGtD,YAAY,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { BasePlugin } from '../-private/base.ts';
|
|
2
|
+
import type { ColumnApi } from '../../plugins/index.ts';
|
|
3
|
+
import type { Column } from '../../index.ts';
|
|
4
|
+
interface ColumnOptions {
|
|
5
|
+
/**
|
|
6
|
+
* Whether or not to enable stickiness on the column
|
|
7
|
+
* (default is false)
|
|
8
|
+
*
|
|
9
|
+
* valid values: 'left', 'right', false
|
|
10
|
+
*/
|
|
11
|
+
sticky?: boolean | string;
|
|
12
|
+
}
|
|
13
|
+
export interface Signature {
|
|
14
|
+
Options: {
|
|
15
|
+
Column: ColumnOptions;
|
|
16
|
+
Plugin: {
|
|
17
|
+
/**
|
|
18
|
+
* Opts this plugin out of engaging in the modifier system
|
|
19
|
+
* and instead requires setting a `style` attribute on
|
|
20
|
+
* th / td tags for getting the "position: sticky" behovior
|
|
21
|
+
* on columns.
|
|
22
|
+
*/
|
|
23
|
+
workaroundForModifierTimingUpdateRFC883?: boolean;
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
Meta: {
|
|
27
|
+
Table: TableMeta;
|
|
28
|
+
Column: ColumnMeta;
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
export declare class StickyColumns extends BasePlugin<Signature> {
|
|
32
|
+
name: string;
|
|
33
|
+
/**
|
|
34
|
+
* This plugin requires that the resizing plugin be present, because the resizing plugin is
|
|
35
|
+
* what manages the base width of the columns.
|
|
36
|
+
*
|
|
37
|
+
* Other width-management plugins can be used instead of ColumnResizing, but they must declare
|
|
38
|
+
* that they manage the width of the columns.
|
|
39
|
+
*/
|
|
40
|
+
static requires: string[];
|
|
41
|
+
meta: {
|
|
42
|
+
table: typeof TableMeta;
|
|
43
|
+
column: typeof ColumnMeta;
|
|
44
|
+
};
|
|
45
|
+
conditionallyRemoveStyles: (element: HTMLElement) => void;
|
|
46
|
+
headerCellModifier: (element: HTMLElement, { column, table }: ColumnApi) => void;
|
|
47
|
+
/**
|
|
48
|
+
* Not yet supported. Pending Ember RFC #883
|
|
49
|
+
*
|
|
50
|
+
* TODO: switch ColumnApi to "RowApi", add the row's data
|
|
51
|
+
*/
|
|
52
|
+
cellModifier: (element: HTMLElement, { column, table }: ColumnApi) => void;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* @private
|
|
56
|
+
*
|
|
57
|
+
* Contains state and behaviors for the sticiness
|
|
58
|
+
*/
|
|
59
|
+
export declare class ColumnMeta {
|
|
60
|
+
private column;
|
|
61
|
+
constructor(column: Column);
|
|
62
|
+
get isSticky(): boolean;
|
|
63
|
+
get position(): 'left' | 'right' | 'none';
|
|
64
|
+
get offset(): string | undefined;
|
|
65
|
+
get style(): Partial<Pick<CSSStyleDeclaration, 'position' | 'left' | 'right' | 'zIndex'>>;
|
|
66
|
+
}
|
|
67
|
+
export declare class TableMeta {
|
|
68
|
+
}
|
|
69
|
+
export {};
|
|
70
|
+
//# sourceMappingURL=plugin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../src/plugins/sticky-columns/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAA0B,MAAM,qBAAqB,CAAC;AAGzE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACxD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAI7C,UAAU,aAAa;IACrB;;;;;OAKG;IACH,MAAM,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CAC3B;AAED,MAAM,WAAW,SAAS;IACxB,OAAO,EAAE;QACP,MAAM,EAAE,aAAa,CAAC;QACtB,MAAM,EAAE;YACN;;;;;eAKG;YACH,uCAAuC,CAAC,EAAE,OAAO,CAAC;SACnD,CAAC;KACH,CAAC;IACF,IAAI,EAAE;QACJ,KAAK,EAAE,SAAS,CAAC;QACjB,MAAM,EAAE,UAAU,CAAC;KACpB,CAAC;CACH;AAED,qBAAa,aAAc,SAAQ,UAAU,CAAC,SAAS,CAAC;IACtD,IAAI,SAAoB;IAExB;;;;;;OAMG;IACH,MAAM,CAAC,QAAQ,WAAmB;IAElC,IAAI;;;MAGF;IAEF,yBAAyB,GAAI,SAAS,WAAW,UAgB/C;IAEF,kBAAkB,GAAI,SAAS,WAAW,EAAE,mBAAmB,SAAS,UAetE;IAEF;;;;OAIG;IACH,YAAY,GAAI,SAAS,WAAW,EAAE,mBAAmB,SAAS,UAehE;CACH;AAED;;;;GAIG;AACH,qBAAa,UAAU;IACT,OAAO,CAAC,MAAM;gBAAN,MAAM,EAAE,MAAM;IAElC,IAAI,QAAQ,YAEX;IAED,IAAI,QAAQ,IAAI,MAAM,GAAG,OAAO,GAAG,MAAM,CAYxC;IAED,IACI,MAAM,uBAoCT;IAED,IAAI,KAAK,IAAI,OAAO,CAClB,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,MAAM,GAAG,OAAO,GAAG,QAAQ,CAAC,CACpE,CAUA;CACF;AAOD,qBAAa,SAAS;CAAG"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
interface Selectors {
|
|
2
|
+
resizeHandle?: string;
|
|
3
|
+
scrollContainer?: string;
|
|
4
|
+
}
|
|
5
|
+
export declare function createHelpers(selectors: Selectors): {
|
|
6
|
+
dragLeft: (column: Element, amount: number) => Promise<void>;
|
|
7
|
+
dragRight: (column: Element, amount: number) => Promise<void>;
|
|
8
|
+
scrollLeft: (distance: number) => Promise<void>;
|
|
9
|
+
scrollRight: (distance: number) => Promise<void>;
|
|
10
|
+
swipeLeft: (distance: number) => Promise<void>;
|
|
11
|
+
swipeRight: (distance: number) => Promise<void>;
|
|
12
|
+
};
|
|
13
|
+
export declare function requestAnimationFrameSettled(): Promise<void>;
|
|
14
|
+
export {};
|
|
15
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/test-support/index.ts"],"names":[],"mappings":"AAGA,UAAU,SAAS;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,wBAAgB,aAAa,CAAC,SAAS,EAAE,SAAS;uBAuD3B,OAAO,UAAU,MAAM;wBACtB,OAAO,UAAU,MAAM;2BATT,MAAM;4BAPL,MAAM;0BAAN,MAAM;2BAOP,MAAM;EAe3C;AAED,wBAAsB,4BAA4B,kBAGjD"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { Sort, SortsOptions } from './plugins/data-sorting/types.ts';
|
|
2
|
+
/**
|
|
3
|
+
* @example
|
|
4
|
+
*
|
|
5
|
+
* ```ts
|
|
6
|
+
* deserializeSorts('first_name.asc', { separator: '.', transform: 'camelize' });
|
|
7
|
+
* // => [{ property: 'firstName', direction: 'ascending' }]
|
|
8
|
+
*
|
|
9
|
+
* deserializeSorts('last_name.desc', { separator: '.', transform: 'camelize' });
|
|
10
|
+
* // => [{ property: 'lastName', direction: 'descending' }]
|
|
11
|
+
* ```
|
|
12
|
+
*/
|
|
13
|
+
export declare const deserializeSorts: (sortString: string, options?: SortsOptions) => Sort[];
|
|
14
|
+
/**
|
|
15
|
+
* @example
|
|
16
|
+
*
|
|
17
|
+
* ```ts
|
|
18
|
+
* serializeSorts([{ property: 'firstName', direction: 'ascending' }],{ separator: '.', transform: 'camelize' });
|
|
19
|
+
* // => 'first_name.asc'
|
|
20
|
+
*
|
|
21
|
+
* serializeSorts([{ property: 'lastName', direction: 'descending' }],{ separator: '.', transform: 'camelize' });
|
|
22
|
+
* // => 'last_name.desc'
|
|
23
|
+
* ```
|
|
24
|
+
*/
|
|
25
|
+
export declare function serializeSorts(sorts: Sort[], options?: SortsOptions): string;
|
|
26
|
+
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,IAAI,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAE1E;;;;;;;;;;GAUG;AAEH,eAAO,MAAM,gBAAgB,GAC3B,YAAY,MAAM,EAClB,UAAS,YAAwD,KAChE,IAAI,EA4BN,CAAC;AAEF;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAC5B,KAAK,EAAE,IAAI,EAAE,EACb,OAAO,GAAE,YAA0D,GAClE,MAAM,CAkBR"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@universal-ember/table",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.3",
|
|
4
4
|
"description": "An implementation of table behaviors for driving any table or table-like UI -- all without a UI (headless)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ember-addon",
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
"author": "NullVoxPopuli",
|
|
14
14
|
"files": [
|
|
15
15
|
"addon-main.js",
|
|
16
|
+
"declarations",
|
|
16
17
|
"dist",
|
|
17
18
|
"src"
|
|
18
19
|
],
|