@servicetitan/table 23.4.0 → 24.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (86) hide show
  1. package/dist/demo/filters/async-select-filter.d.ts +3 -0
  2. package/dist/demo/filters/async-select-filter.d.ts.map +1 -0
  3. package/dist/demo/filters/async-select-filter.js +23 -0
  4. package/dist/demo/filters/async-select-filter.js.map +1 -0
  5. package/dist/demo/filters/categories.d.ts +9 -0
  6. package/dist/demo/filters/categories.d.ts.map +1 -0
  7. package/dist/demo/filters/categories.js +33 -0
  8. package/dist/demo/filters/categories.js.map +1 -0
  9. package/dist/demo/filters/multiselect-filter.d.ts +3 -0
  10. package/dist/demo/filters/multiselect-filter.d.ts.map +1 -0
  11. package/dist/demo/filters/multiselect-filter.js +14 -0
  12. package/dist/demo/filters/multiselect-filter.js.map +1 -0
  13. package/dist/demo/filters/range-filter.d.ts +5 -0
  14. package/dist/demo/filters/range-filter.d.ts.map +1 -0
  15. package/dist/demo/filters/range-filter.js +24 -0
  16. package/dist/demo/filters/range-filter.js.map +1 -0
  17. package/dist/demo/filters/single-select-filter.d.ts +3 -0
  18. package/dist/demo/filters/single-select-filter.d.ts.map +1 -0
  19. package/dist/demo/filters/single-select-filter.js +20 -0
  20. package/dist/demo/filters/single-select-filter.js.map +1 -0
  21. package/dist/demo/filters/table.store.d.ts +9 -0
  22. package/dist/demo/filters/table.store.d.ts.map +1 -0
  23. package/dist/demo/filters/table.store.js +73 -0
  24. package/dist/demo/filters/table.store.js.map +1 -0
  25. package/dist/demo/overview/products.js +10 -10
  26. package/dist/filters/async-select/async-select-filter.d.ts +19 -0
  27. package/dist/filters/async-select/async-select-filter.d.ts.map +1 -0
  28. package/dist/filters/async-select/async-select-filter.js +168 -0
  29. package/dist/filters/async-select/async-select-filter.js.map +1 -0
  30. package/dist/filters/async-select/async-select-filter.stories.d.ts +7 -0
  31. package/dist/filters/async-select/async-select-filter.stories.d.ts.map +1 -0
  32. package/dist/filters/async-select/async-select-filter.stories.js +7 -0
  33. package/dist/filters/async-select/async-select-filter.stories.js.map +1 -0
  34. package/dist/filters/index.d.ts +3 -1
  35. package/dist/filters/index.d.ts.map +1 -1
  36. package/dist/filters/index.js +3 -1
  37. package/dist/filters/index.js.map +1 -1
  38. package/dist/filters/multiselect-filter/multiselect-filter.d.ts.map +1 -0
  39. package/dist/filters/{multiselect-filter.js → multiselect-filter/multiselect-filter.js} +1 -1
  40. package/dist/filters/multiselect-filter/multiselect-filter.js.map +1 -0
  41. package/dist/filters/multiselect-filter/multiselect-filter.stories.d.ts +7 -0
  42. package/dist/filters/multiselect-filter/multiselect-filter.stories.d.ts.map +1 -0
  43. package/dist/filters/multiselect-filter/multiselect-filter.stories.js +7 -0
  44. package/dist/filters/multiselect-filter/multiselect-filter.stories.js.map +1 -0
  45. package/dist/filters/range-filter/range-filter.stories.d.ts +9 -0
  46. package/dist/filters/range-filter/range-filter.stories.d.ts.map +1 -0
  47. package/dist/filters/range-filter/range-filter.stories.js +9 -0
  48. package/dist/filters/range-filter/range-filter.stories.js.map +1 -0
  49. package/dist/filters/single-select/single-select-filter.d.ts +9 -0
  50. package/dist/filters/single-select/single-select-filter.d.ts.map +1 -0
  51. package/dist/filters/single-select/single-select-filter.js +30 -0
  52. package/dist/filters/single-select/single-select-filter.js.map +1 -0
  53. package/dist/filters/single-select/single-select-filter.stories.d.ts +7 -0
  54. package/dist/filters/single-select/single-select-filter.stories.d.ts.map +1 -0
  55. package/dist/filters/single-select/single-select-filter.stories.js +7 -0
  56. package/dist/filters/single-select/single-select-filter.stories.js.map +1 -0
  57. package/dist/index.d.ts +1 -0
  58. package/dist/index.d.ts.map +1 -1
  59. package/dist/index.js +1 -0
  60. package/dist/index.js.map +1 -1
  61. package/dist/utils/filters.d.ts +4 -0
  62. package/dist/utils/filters.d.ts.map +1 -0
  63. package/dist/utils/filters.js +22 -0
  64. package/dist/utils/filters.js.map +1 -0
  65. package/package.json +6 -6
  66. package/src/demo/filters/async-select-filter.tsx +53 -0
  67. package/src/demo/filters/categories.tsx +40 -0
  68. package/src/demo/filters/multiselect-filter.tsx +32 -0
  69. package/src/demo/filters/range-filter.tsx +72 -0
  70. package/src/demo/filters/single-select-filter.tsx +51 -0
  71. package/src/demo/filters/table.store.ts +45 -0
  72. package/src/demo/overview/products.ts +10 -10
  73. package/src/filters/async-select/async-select-filter.stories.tsx +7 -0
  74. package/src/filters/async-select/async-select-filter.tsx +249 -0
  75. package/src/filters/index.ts +3 -1
  76. package/src/filters/multiselect-filter/multiselect-filter.stories.tsx +7 -0
  77. package/src/filters/{multiselect-filter.tsx → multiselect-filter/multiselect-filter.tsx} +1 -1
  78. package/src/filters/range-filter/range-filter.stories.tsx +13 -0
  79. package/src/filters/single-select/single-select-filter.stories.tsx +7 -0
  80. package/src/filters/single-select/single-select-filter.tsx +66 -0
  81. package/src/index.ts +1 -0
  82. package/src/utils/__tests__/filters.test.ts +31 -0
  83. package/src/utils/filters.ts +33 -0
  84. package/dist/filters/multiselect-filter.d.ts.map +0 -1
  85. package/dist/filters/multiselect-filter.js.map +0 -1
  86. /package/dist/filters/{multiselect-filter.d.ts → multiselect-filter/multiselect-filter.d.ts} +0 -0
@@ -0,0 +1,3 @@
1
+ import { FC } from 'react';
2
+ export declare const TableExample: FC;
3
+ //# sourceMappingURL=async-select-filter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"async-select-filter.d.ts","sourceRoot":"","sources":["../../../src/demo/filters/async-select-filter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAW,EAAE,EAAE,MAAM,OAAO,CAAC;AASpC,eAAO,MAAM,YAAY,EAAE,EA2C1B,CAAC"}
@@ -0,0 +1,23 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useMemo } from 'react';
3
+ import { observer } from 'mobx-react';
4
+ import { provide, useDependencies } from '@servicetitan/react-ioc';
5
+ import { Table, TableColumn, asyncSelectColumnMenuFilter } from '../..';
6
+ import { TableStore } from './table.store';
7
+ import { CategoryCell } from './categories';
8
+ export const TableExample = provide({
9
+ singletons: [TableStore],
10
+ })(observer(() => {
11
+ const [{ categoryFetcher, madeInFetcher, tableState }] = useDependencies(TableStore);
12
+ const madeInColumnMenu = useMemo(() => asyncSelectColumnMenuFilter({
13
+ dataFetcher: madeInFetcher,
14
+ placeholder: 'Search for made-ins',
15
+ }), [madeInFetcher]);
16
+ const categoryColumnMenu = useMemo(() => asyncSelectColumnMenuFilter({
17
+ dataFetcher: categoryFetcher,
18
+ placeholder: 'Search for Categories',
19
+ multiple: true,
20
+ }), [categoryFetcher]);
21
+ return (_jsxs(Table, Object.assign({ tableState: tableState, striped: false }, { children: [_jsx(TableColumn, { field: "ProductID", title: "ID", editable: false, width: "100px" }), _jsx(TableColumn, { field: "ProductName", title: "Product Name", width: "240px" }), _jsx(TableColumn, { field: "MadeIn", title: "Made In (async single-select filter)", columnMenu: madeInColumnMenu }), _jsx(TableColumn, { field: "CategoryID", title: "Category (async multi-select filter)", columnMenu: categoryColumnMenu, cell: CategoryCell })] })));
22
+ }));
23
+ //# sourceMappingURL=async-select-filter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"async-select-filter.js","sourceRoot":"","sources":["../../../src/demo/filters/async-select-filter.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,OAAO,EAAM,MAAM,OAAO,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAEnE,OAAO,EAAE,KAAK,EAAE,WAAW,EAAE,2BAA2B,EAAE,MAAM,OAAO,CAAC;AAExE,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAE5C,MAAM,CAAC,MAAM,YAAY,GAAO,OAAO,CAAC;IACpC,UAAU,EAAE,CAAC,UAAU,CAAC;CAC3B,CAAC,CACE,QAAQ,CAAC,GAAG,EAAE;IACV,MAAM,CAAC,EAAE,eAAe,EAAE,aAAa,EAAE,UAAU,EAAE,CAAC,GAAG,eAAe,CAAC,UAAU,CAAC,CAAC;IAErF,MAAM,gBAAgB,GAAG,OAAO,CAC5B,GAAG,EAAE,CACD,2BAA2B,CAAC;QACxB,WAAW,EAAE,aAAa;QAC1B,WAAW,EAAE,qBAAqB;KACrC,CAAC,EACN,CAAC,aAAa,CAAC,CAClB,CAAC;IAEF,MAAM,kBAAkB,GAAG,OAAO,CAC9B,GAAG,EAAE,CACD,2BAA2B,CAAC;QACxB,WAAW,EAAE,eAAe;QAC5B,WAAW,EAAE,uBAAuB;QACpC,QAAQ,EAAE,IAAI;KACjB,CAAC,EACN,CAAC,eAAe,CAAC,CACpB,CAAC;IAEF,OAAO,CACH,MAAC,KAAK,kBAAC,UAAU,EAAE,UAAU,EAAE,OAAO,EAAE,KAAK,iBACzC,KAAC,WAAW,IAAC,KAAK,EAAC,WAAW,EAAC,KAAK,EAAC,IAAI,EAAC,QAAQ,EAAE,KAAK,EAAE,KAAK,EAAC,OAAO,GAAG,EAC3E,KAAC,WAAW,IAAC,KAAK,EAAC,aAAa,EAAC,KAAK,EAAC,cAAc,EAAC,KAAK,EAAC,OAAO,GAAG,EACtE,KAAC,WAAW,IACR,KAAK,EAAC,QAAQ,EACd,KAAK,EAAC,sCAAsC,EAC5C,UAAU,EAAE,gBAAgB,GAC9B,EACF,KAAC,WAAW,IACR,KAAK,EAAC,YAAY,EAClB,KAAK,EAAC,sCAAsC,EAC5C,UAAU,EAAE,kBAAkB,EAC9B,IAAI,EAAE,YAAY,GACpB,KACE,CACX,CAAC;AACN,CAAC,CAAC,CACL,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { FC } from 'react';
2
+ import { TableCellProps } from '../../table';
3
+ export interface Category {
4
+ CategoryID: number;
5
+ CategoryName: string;
6
+ }
7
+ export declare const categories: Category[];
8
+ export declare const CategoryCell: FC<TableCellProps>;
9
+ //# sourceMappingURL=categories.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"categories.d.ts","sourceRoot":"","sources":["../../../src/demo/filters/categories.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAC3B,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7C,MAAM,WAAW,QAAQ;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;CACxB;AAED,eAAO,MAAM,UAAU,EAAE,QAAQ,EAyBhC,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,EAAE,CAAC,cAAc,CAI3C,CAAC"}
@@ -0,0 +1,33 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ export const categories = [
3
+ {
4
+ CategoryID: 1,
5
+ CategoryName: 'Wok',
6
+ },
7
+ {
8
+ CategoryID: 2,
9
+ CategoryName: 'Sushi',
10
+ },
11
+ {
12
+ CategoryID: 6,
13
+ CategoryName: 'Gunkan',
14
+ },
15
+ {
16
+ CategoryID: 7,
17
+ CategoryName: 'Miso',
18
+ },
19
+ {
20
+ CategoryID: 8,
21
+ CategoryName: 'Roll',
22
+ },
23
+ {
24
+ CategoryID: 10,
25
+ CategoryName: 'Sashimi',
26
+ },
27
+ ];
28
+ export const CategoryCell = props => {
29
+ var _a;
30
+ const { field, dataItem } = props;
31
+ return _jsx("td", { children: (_a = categories.find(c => c.CategoryID === dataItem[field])) === null || _a === void 0 ? void 0 : _a.CategoryName });
32
+ };
33
+ //# sourceMappingURL=categories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"categories.js","sourceRoot":"","sources":["../../../src/demo/filters/categories.tsx"],"names":[],"mappings":";AAQA,MAAM,CAAC,MAAM,UAAU,GAAe;IAClC;QACI,UAAU,EAAE,CAAC;QACb,YAAY,EAAE,KAAK;KACtB;IACD;QACI,UAAU,EAAE,CAAC;QACb,YAAY,EAAE,OAAO;KACxB;IACD;QACI,UAAU,EAAE,CAAC;QACb,YAAY,EAAE,QAAQ;KACzB;IACD;QACI,UAAU,EAAE,CAAC;QACb,YAAY,EAAE,MAAM;KACvB;IACD;QACI,UAAU,EAAE,CAAC;QACb,YAAY,EAAE,MAAM;KACvB;IACD;QACI,UAAU,EAAE,EAAE;QACd,YAAY,EAAE,SAAS;KAC1B;CACJ,CAAC;AAEF,MAAM,CAAC,MAAM,YAAY,GAAuB,KAAK,CAAC,EAAE;;IACpD,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC;IAElC,OAAO,uBAAK,MAAA,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,UAAU,KAAK,QAAQ,CAAC,KAAM,CAAC,CAAC,0CAAE,YAAY,GAAM,CAAC;AAC5F,CAAC,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { FC } from 'react';
2
+ export declare const TableExampleSimple: FC;
3
+ //# sourceMappingURL=multiselect-filter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"multiselect-filter.d.ts","sourceRoot":"","sources":["../../../src/demo/filters/multiselect-filter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAW,EAAE,EAAE,MAAM,OAAO,CAAC;AAUpC,eAAO,MAAM,kBAAkB,EAAE,EAqBhC,CAAC"}
@@ -0,0 +1,14 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useMemo } from 'react';
3
+ import { provide, useDependencies } from '@servicetitan/react-ioc';
4
+ import { observer } from 'mobx-react';
5
+ import { Table, TableColumn, multiSelectColumnMenuFilter } from '../..';
6
+ import { TableStore } from './table.store';
7
+ export const TableExampleSimple = provide({
8
+ singletons: [TableStore],
9
+ })(observer(() => {
10
+ const [{ tableState, madeInOptions }] = useDependencies(TableStore);
11
+ const madeInColumnMenu = useMemo(() => multiSelectColumnMenuFilter(madeInOptions), [madeInOptions]);
12
+ return (_jsxs(Table, Object.assign({ tableState: tableState }, { children: [_jsx(TableColumn, { field: "ProductID", title: "ID", editable: false, width: "100px" }), _jsx(TableColumn, { field: "ProductName", title: "Product Name", width: "240px" }), _jsx(TableColumn, { field: "MadeIn", title: "Made In", columnMenu: madeInColumnMenu })] })));
13
+ }));
14
+ //# sourceMappingURL=multiselect-filter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"multiselect-filter.js","sourceRoot":"","sources":["../../../src/demo/filters/multiselect-filter.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,OAAO,EAAM,MAAM,OAAO,CAAC;AAEpC,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAEnE,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,OAAO,EAAE,KAAK,EAAE,WAAW,EAAE,2BAA2B,EAAE,MAAM,OAAO,CAAC;AAExE,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,MAAM,CAAC,MAAM,kBAAkB,GAAO,OAAO,CAAC;IAC1C,UAAU,EAAE,CAAC,UAAU,CAAC;CAC3B,CAAC,CACE,QAAQ,CAAC,GAAG,EAAE;IACV,MAAM,CAAC,EAAE,UAAU,EAAE,aAAa,EAAE,CAAC,GAAG,eAAe,CAAC,UAAU,CAAC,CAAC;IAEpE,MAAM,gBAAgB,GAAG,OAAO,CAC5B,GAAG,EAAE,CAAC,2BAA2B,CAAC,aAAa,CAAC,EAChD,CAAC,aAAa,CAAC,CAClB,CAAC;IAEF,OAAO,CACH,MAAC,KAAK,kBAAC,UAAU,EAAE,UAAU,iBACzB,KAAC,WAAW,IAAC,KAAK,EAAC,WAAW,EAAC,KAAK,EAAC,IAAI,EAAC,QAAQ,EAAE,KAAK,EAAE,KAAK,EAAC,OAAO,GAAG,EAE3E,KAAC,WAAW,IAAC,KAAK,EAAC,aAAa,EAAC,KAAK,EAAC,cAAc,EAAC,KAAK,EAAC,OAAO,GAAG,EAEtE,KAAC,WAAW,IAAC,KAAK,EAAC,QAAQ,EAAC,KAAK,EAAC,SAAS,EAAC,UAAU,EAAE,gBAAgB,GAAI,KACxE,CACX,CAAC;AACN,CAAC,CAAC,CACL,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { FC } from 'react';
2
+ export declare const TableExampleDate: FC;
3
+ export declare const TableExampleNumber: FC;
4
+ export declare const TableExampleCurrency: FC;
5
+ //# sourceMappingURL=range-filter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"range-filter.d.ts","sourceRoot":"","sources":["../../../src/demo/filters/range-filter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAa3B,eAAO,MAAM,gBAAgB,EAAE,EAkB9B,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE,EAkBhC,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,EAkBlC,CAAC"}
@@ -0,0 +1,24 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { observer } from 'mobx-react';
3
+ import { provide, useDependencies } from '@servicetitan/react-ioc';
4
+ import { Table, TableColumn, DateRangeColumnMenuFilter, NumericRangeColumnMenuFilter, CurrencyRangeColumnMenuFilter, } from '../..';
5
+ import { TableStore } from './table.store';
6
+ export const TableExampleDate = provide({
7
+ singletons: [TableStore],
8
+ })(observer(() => {
9
+ const [{ tableState }] = useDependencies(TableStore);
10
+ return (_jsxs(Table, Object.assign({ tableState: tableState }, { children: [_jsx(TableColumn, { field: "ProductID", title: "ID", editable: false, width: "100px" }), _jsx(TableColumn, { field: "ProductName", title: "Product Name", width: "240px" }), _jsx(TableColumn, { field: "UnitsOnOrder", title: "Units On Order", columnMenu: DateRangeColumnMenuFilter })] })));
11
+ }));
12
+ export const TableExampleNumber = provide({
13
+ singletons: [TableStore],
14
+ })(observer(() => {
15
+ const [{ tableState }] = useDependencies(TableStore);
16
+ return (_jsxs(Table, Object.assign({ tableState: tableState }, { children: [_jsx(TableColumn, { field: "ProductID", title: "ID", editable: false, width: "100px" }), _jsx(TableColumn, { field: "ProductName", title: "Product Name", width: "240px" }), _jsx(TableColumn, { field: "UnitsInStock", title: "Units In Stock", columnMenu: NumericRangeColumnMenuFilter })] })));
17
+ }));
18
+ export const TableExampleCurrency = provide({
19
+ singletons: [TableStore],
20
+ })(observer(() => {
21
+ const [{ tableState }] = useDependencies(TableStore);
22
+ return (_jsxs(Table, Object.assign({ tableState: tableState }, { children: [_jsx(TableColumn, { field: "ProductID", title: "ID", editable: false, width: "100px" }), _jsx(TableColumn, { field: "ProductName", title: "Product Name", width: "240px" }), _jsx(TableColumn, { field: "UnitPrice", title: "Unit Price", columnMenu: CurrencyRangeColumnMenuFilter })] })));
23
+ }));
24
+ //# sourceMappingURL=range-filter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"range-filter.js","sourceRoot":"","sources":["../../../src/demo/filters/range-filter.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAEnE,OAAO,EACH,KAAK,EACL,WAAW,EACX,yBAAyB,EACzB,4BAA4B,EAC5B,6BAA6B,GAChC,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,MAAM,CAAC,MAAM,gBAAgB,GAAO,OAAO,CAAC;IACxC,UAAU,EAAE,CAAC,UAAU,CAAC;CAC3B,CAAC,CACE,QAAQ,CAAC,GAAG,EAAE;IACV,MAAM,CAAC,EAAE,UAAU,EAAE,CAAC,GAAG,eAAe,CAAC,UAAU,CAAC,CAAC;IAErD,OAAO,CACH,MAAC,KAAK,kBAAC,UAAU,EAAE,UAAU,iBACzB,KAAC,WAAW,IAAC,KAAK,EAAC,WAAW,EAAC,KAAK,EAAC,IAAI,EAAC,QAAQ,EAAE,KAAK,EAAE,KAAK,EAAC,OAAO,GAAG,EAC3E,KAAC,WAAW,IAAC,KAAK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AC,WAAW,IAAC,KAAK,EAAC,aAAa,EAAC,KAAK,EAAC,cAAc,EAAC,KAAK,EAAC,OAAO,GAAG,EACtE,KAAC,WAAW,IACR,KAAK,EAAC,WAAW,EACjB,KAAK,EAAC,YAAY,EAClB,UAAU,EAAE,6BAA6B,GAC3C,KACE,CACX,CAAC;AACN,CAAC,CAAC,CACL,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { FC } from 'react';
2
+ export declare const TableExample: FC;
3
+ //# sourceMappingURL=single-select-filter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"single-select-filter.d.ts","sourceRoot":"","sources":["../../../src/demo/filters/single-select-filter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAW,EAAE,EAAE,MAAM,OAAO,CAAC;AAWpC,eAAO,MAAM,YAAY,EAAE,EAuC1B,CAAC"}
@@ -0,0 +1,20 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useMemo } from 'react';
3
+ import { provide, useDependencies } from '@servicetitan/react-ioc';
4
+ import { observer } from 'mobx-react';
5
+ import { Table, TableColumn, singleSelectColumnMenuFilter } from '../..';
6
+ import { TableStore } from './table.store';
7
+ import { categories, CategoryCell } from './categories';
8
+ export const TableExample = provide({
9
+ singletons: [TableStore],
10
+ })(observer(() => {
11
+ const [{ tableState, madeInOptions }] = useDependencies(TableStore);
12
+ const madeInColumnMenu = useMemo(() => singleSelectColumnMenuFilter({ options: madeInOptions }), [madeInOptions]);
13
+ const categoryColumnMenu = useMemo(() => singleSelectColumnMenuFilter({
14
+ options: categories,
15
+ renderItem: cat => cat.CategoryName,
16
+ valueSelector: cat => cat.CategoryID,
17
+ }), []);
18
+ return (_jsxs(Table, Object.assign({ tableState: tableState, striped: false }, { children: [_jsx(TableColumn, { field: "ProductID", title: "ID", editable: false, width: "100px" }), _jsx(TableColumn, { field: "ProductName", title: "Product Name", width: "240px" }), _jsx(TableColumn, { field: "MadeIn", title: "Made In (simple single-select filter)", columnMenu: madeInColumnMenu }), _jsx(TableColumn, { field: "CategoryID", title: "Category (simple single-select filter)", columnMenu: categoryColumnMenu, cell: CategoryCell })] })));
19
+ }));
20
+ //# sourceMappingURL=single-select-filter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"single-select-filter.js","sourceRoot":"","sources":["../../../src/demo/filters/single-select-filter.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,OAAO,EAAM,MAAM,OAAO,CAAC;AAEpC,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAEnE,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,OAAO,EAAE,KAAK,EAAE,WAAW,EAAE,4BAA4B,EAAE,MAAM,OAAO,CAAC;AAEzE,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAExD,MAAM,CAAC,MAAM,YAAY,GAAO,OAAO,CAAC;IACpC,UAAU,EAAE,CAAC,UAAU,CAAC;CAC3B,CAAC,CACE,QAAQ,CAAC,GAAG,EAAE;IACV,MAAM,CAAC,EAAE,UAAU,EAAE,aAAa,EAAE,CAAC,GAAG,eAAe,CAAC,UAAU,CAAC,CAAC;IAEpE,MAAM,gBAAgB,GAAG,OAAO,CAC5B,GAAG,EAAE,CAAC,4BAA4B,CAAC,EAAE,OAAO,EAAE,aAAa,EAAE,CAAC,EAC9D,CAAC,aAAa,CAAC,CAClB,CAAC;IAEF,MAAM,kBAAkB,GAAG,OAAO,CAC9B,GAAG,EAAE,CACD,4BAA4B,CAAC;QACzB,OAAO,EAAE,UAAU;QACnB,UAAU,EAAE,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,YAAY;QACnC,aAAa,EAAE,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,UAAU;KACvC,CAAC,EACN,EAAE,CACL,CAAC;IAEF,OAAO,CACH,MAAC,KAAK,kBAAC,UAAU,EAAE,UAAU,EAAE,OAAO,EAAE,KAAK,iBACzC,KAAC,WAAW,IAAC,KAAK,EAAC,WAAW,EAAC,KAAK,EAAC,IAAI,EAAC,QAAQ,EAAE,KAAK,EAAE,KAAK,EAAC,OAAO,GAAG,EAC3E,KAAC,WAAW,IAAC,KAAK,EAAC,aAAa,EAAC,KAAK,EAAC,cAAc,EAAC,KAAK,EAAC,OAAO,GAAG,EACtE,KAAC,WAAW,IACR,KAAK,EAAC,QAAQ,EACd,KAAK,EAAC,uCAAuC,EAC7C,UAAU,EAAE,gBAAgB,GAC9B,EACF,KAAC,WAAW,IACR,KAAK,EAAC,YAAY,EAClB,KAAK,EAAC,wCAAwC,EAC9C,UAAU,EAAE,kBAAkB,EAC9B,IAAI,EAAE,YAAY,GACpB,KACE,CACX,CAAC;AACN,CAAC,CAAC,CACL,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { TableState, AsyncSelectFilterDataFetcher } from '../..';
2
+ export declare class TableStore {
3
+ tableState: TableState<import("../overview/product").Product, number, never, never>;
4
+ get madeInOptions(): string[];
5
+ categoryFetcher: AsyncSelectFilterDataFetcher<number>;
6
+ madeInFetcher: AsyncSelectFilterDataFetcher<string>;
7
+ private getDataSource;
8
+ }
9
+ //# sourceMappingURL=table.store.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"table.store.d.ts","sourceRoot":"","sources":["../../../src/demo/filters/table.store.ts"],"names":[],"mappings":"AAEA,OAAO,EAAsB,UAAU,EAAE,4BAA4B,EAAE,MAAM,OAAO,CAAC;AAIrF,qBACa,UAAU;IACnB,UAAU,0EAGP;IAEH,IAAI,aAAa,aAEhB;IAED,eAAe,EAAE,4BAA4B,CAAC,MAAM,CAAC,CAUnD;IAEF,aAAa,EAAE,4BAA4B,CAAC,MAAM,CAAC,CAUjD;IAEF,OAAO,CAAC,aAAa;CAGxB"}
@@ -0,0 +1,73 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
8
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
9
+ return new (P || (P = Promise))(function (resolve, reject) {
10
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
11
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
12
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
13
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
14
+ });
15
+ };
16
+ import { injectable } from '@servicetitan/react-ioc';
17
+ import { InMemoryDataSource, TableState } from '../..';
18
+ import { products } from '../overview/products';
19
+ import { categories } from './categories';
20
+ let TableStore = class TableStore {
21
+ constructor() {
22
+ Object.defineProperty(this, "tableState", {
23
+ enumerable: true,
24
+ configurable: true,
25
+ writable: true,
26
+ value: new TableState({
27
+ dataSource: this.getDataSource(),
28
+ pageSize: 5,
29
+ })
30
+ });
31
+ Object.defineProperty(this, "categoryFetcher", {
32
+ enumerable: true,
33
+ configurable: true,
34
+ writable: true,
35
+ value: (opts) => __awaiter(this, void 0, void 0, function* () {
36
+ var _a;
37
+ yield new Promise(resolve => setTimeout(resolve, 1500));
38
+ const sv = (_a = opts.search) === null || _a === void 0 ? void 0 : _a.trim().toLowerCase();
39
+ return {
40
+ data: categories
41
+ .filter(cat => (sv ? cat.CategoryName.toLowerCase().includes(sv) : true))
42
+ .map(cat => ({ value: cat.CategoryID, text: cat.CategoryName })),
43
+ };
44
+ })
45
+ });
46
+ Object.defineProperty(this, "madeInFetcher", {
47
+ enumerable: true,
48
+ configurable: true,
49
+ writable: true,
50
+ value: (opts) => __awaiter(this, void 0, void 0, function* () {
51
+ var _b;
52
+ yield new Promise(resolve => setTimeout(resolve, 1500));
53
+ const sv = (_b = opts.search) === null || _b === void 0 ? void 0 : _b.trim().toLowerCase();
54
+ return {
55
+ data: this.madeInOptions
56
+ .filter(opt => (sv ? opt.toLowerCase().includes(sv) : true))
57
+ .map(opt => ({ value: opt, text: opt })),
58
+ };
59
+ })
60
+ });
61
+ }
62
+ get madeInOptions() {
63
+ return Array.from(new Set(products.map(p => p.MadeIn)));
64
+ }
65
+ getDataSource() {
66
+ return new InMemoryDataSource(products, row => row.ProductID);
67
+ }
68
+ };
69
+ TableStore = __decorate([
70
+ injectable()
71
+ ], TableStore);
72
+ export { TableStore };
73
+ //# sourceMappingURL=table.store.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"table.store.js","sourceRoot":"","sources":["../../../src/demo/filters/table.store.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAErD,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAgC,MAAM,OAAO,CAAC;AACrF,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAG1C,IAAa,UAAU,GAAvB,MAAa,UAAU;IAAvB;QACI;;;;mBAAa,IAAI,UAAU,CAAC;gBACxB,UAAU,EAAE,IAAI,CAAC,aAAa,EAAE;gBAChC,QAAQ,EAAE,CAAC;aACd,CAAC;WAAC;QAMH;;;;mBAAwD,CAAM,IAAI,EAAC,EAAE;;gBACjE,MAAM,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC,CAAC;gBAExD,MAAM,EAAE,GAAG,MAAA,IAAI,C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A0BO,aAAa;QACjB,OAAO,IAAI,kBAAkB,CAAC,QAAQ,EAAE,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;IAClE,CAAC;CACJ,CAAA;AArCY,UAAU;IADtB,UAAU,EAAE;GACA,UAAU,CAqCtB;SArCY,UAAU"}
@@ -9,7 +9,7 @@ export const products = [
9
9
  QuantityPerUnit: '10 boxes x 20 bags',
10
10
  UnitPrice: 18.0,
11
11
  UnitsInStock: 39,
12
- UnitsOnOrder: new Date('1/11/2019'),
12
+ UnitsOnOrder: new Date('1/11/2023'),
13
13
  Discontinued: false,
14
14
  AvailableFor: UserRole.Admin,
15
15
  },
@@ -22,7 +22,7 @@ export const products = [
22
22
  QuantityPerUnit: '24 - 12 oz bottles',
23
23
  UnitPrice: 19.0,
24
24
  UnitsInStock: 17,
25
- UnitsOnOrder: new Date('2/11/2019'),
25
+ UnitsOnOrder: new Date('2/11/2023'),
26
26
  Discontinued: false,
27
27
  },
28
28
  {
@@ -34,7 +34,7 @@ export const products = [
34
34
  QuantityPerUnit: '12 - 550 ml bottles',
35
35
  UnitPrice: 10.0,
36
36
  UnitsInStock: 13,
37
- UnitsOnOrder: new Date('3/11/2019'),
37
+ UnitsOnOrder: new Date('3/11/2023'),
38
38
  Discontinued: false,
39
39
  AvailableFor: UserRole.Owner,
40
40
  },
@@ -47,7 +47,7 @@ export const products = [
47
47
  QuantityPerUnit: '48 - 6 oz jars',
48
48
  UnitPrice: 22.0,
49
49
  UnitsInStock: 53,
50
- UnitsOnOrder: new Date('4/11/2019'),
50
+ UnitsOnOrder: new Date('4/11/2023'),
51
51
  Discontinued: false,
52
52
  },
53
53
  {
@@ -59,7 +59,7 @@ export const products = [
59
59
  QuantityPerUnit: '36 boxes',
60
60
  UnitPrice: 21.35,
61
61
  UnitsInStock: 0,
62
- UnitsOnOrder: new Date('5/11/2019'),
62
+ UnitsOnOrder: new Date('5/11/2023'),
63
63
  Discontinued: true,
64
64
  AvailableFor: UserRole.GeneralOffice,
65
65
  },
@@ -72,7 +72,7 @@ export const products = [
72
72
  QuantityPerUnit: '12 - 8 oz jars',
73
73
  UnitPrice: 25.0,
74
74
  UnitsInStock: 120,
75
- UnitsOnOrder: new Date('6/11/2019'),
75
+ UnitsOnOrder: new Date('6/11/2023'),
76
76
  Discontinued: false,
77
77
  },
78
78
  {
@@ -84,7 +84,7 @@ export const products = [
84
84
  QuantityPerUnit: '12 - 1 lb pkgs.',
85
85
  UnitPrice: 30.0,
86
86
  UnitsInStock: 15,
87
- UnitsOnOrder: new Date('7/11/2019'),
87
+ UnitsOnOrder: new Date('7/11/2023'),
88
88
  Discontinued: false,
89
89
  },
90
90
  {
@@ -96,7 +96,7 @@ export const products = [
96
96
  QuantityPerUnit: '12 - 12 oz jars',
97
97
  UnitPrice: 40.0,
98
98
  UnitsInStock: 6,
99
- UnitsOnOrder: new Date('8/11/2019'),
99
+ UnitsOnOrder: new Date('8/11/2023'),
100
100
  Discontinued: false,
101
101
  },
102
102
  {
@@ -108,7 +108,7 @@ export const products = [
108
108
  QuantityPerUnit: '18 - 500 g pkgs.',
109
109
  UnitPrice: 97.0,
110
110
  UnitsInStock: 29,
111
- UnitsOnOrder: new Date('9/11/2019'),
111
+ UnitsOnOrder: new Date('9/11/2023'),
112
112
  Discontinued: true,
113
113
  },
114
114
  {
@@ -120,7 +120,7 @@ export const products = [
120
120
  QuantityPerUnit: '12 - 200 ml jars',
121
121
  UnitPrice: 31.0,
122
122
  UnitsInStock: 31,
123
- UnitsOnOrder: new Date('10/11/2019'),
123
+ UnitsOnOrder: new Date('10/11/2023'),
124
124
  Discontinued: false,
125
125
  },
126
126
  ];
@@ -0,0 +1,19 @@
1
+ import { ReactNode } from 'react';
2
+ import { IdType } from '@servicetitan/data-query';
3
+ export declare type AsyncSelectFilterDataFetcher<TV extends IdType = IdType, TO extends AsyncSelectItem<TV> = AsyncSelectItem<TV>> = (opts: {
4
+ search?: string;
5
+ }) => Promise<{
6
+ data: TO[];
7
+ }>;
8
+ export interface AsyncSelectItem<TV extends IdType = IdType> {
9
+ value: TV;
10
+ text: string;
11
+ }
12
+ export interface AsyncSelectFilterOptions<TID extends IdType, TO extends AsyncSelectItem<TID>> {
13
+ dataFetcher: AsyncSelectFilterDataFetcher<TID, TO>;
14
+ placeholder: string;
15
+ multiple?: boolean;
16
+ renderItem?: (item: TO) => ReactNode;
17
+ }
18
+ export declare function asyncSelectColumnMenuFilter<TID extends IdType, TO extends AsyncSelectItem<TID>>(options: AsyncSelectFilterOptions<TID, TO>): (props: import("@servicetitan/design-system").TableColumnMenuProps) => JSX.Element;
19
+ //# sourceMappingURL=async-select-filter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"async-select-filter.d.ts","sourceRoot":"","sources":["../../../src/filters/async-select/async-select-filter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA6B,SAAS,EAA+B,MAAM,OAAO,CAAC;AAU1F,OAAO,EAAE,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAMlD,oBAAY,4BAA4B,CACpC,EAAE,SAAS,MAAM,GAAG,MAAM,EAC1B,EAAE,SAAS,eAAe,CAAC,EAAE,CAAC,GAAG,eAAe,CAAC,EAAE,CAAC,IACpD,CAAC,IAAI,EAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,KAAK,OAAO,CAAC;IAAE,IAAI,EAAE,EAAE,EAAE,CAAA;CAAE,CAAC,CAAC;AAE3D,MAAM,WAAW,eAAe,CAAC,EAAE,SAAS,MAAM,GAAG,MAAM;IACvD,KAAK,EAAE,EAAE,CAAC;IACV,IAAI,EAAE,MAAM,CAAC;CAChB;AAwJD,MAAM,WAAW,wBAAwB,CAAC,GAAG,SAAS,MAAM,EAAE,EAAE,SAAS,eAAe,CAAC,GAAG,CAAC;IACzF,WAAW,EAAE,4BAA4B,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;IACnD,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,EAAE,KAAK,SAAS,CAAC;CACxC;AAMD,wBAAgB,2BAA2B,CAAC,GAAG,SAAS,MAAM,EAAE,EAAE,SAAS,eAAe,CAAC,GAAG,CAAC,EAC3F,OAAO,EAAE,wBAAwB,CAAC,GAAG,EAAE,EAAE,CAAC,sFA4D7C"}
@@ -0,0 +1,168 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
11
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
12
+ return new (P || (P = Promise))(function (resolve, reject) {
13
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
14
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
15
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
16
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
17
+ });
18
+ };
19
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
20
+ import { Component, Fragment } from 'react';
21
+ import { Checkbox, Radio, Input, Spinner, BodyText, } from '@servicetitan/design-system';
22
+ import { renderCustomColumnMenuFilter } from '../column-menu-filters';
23
+ import { makeObservable, observable, runInAction } from 'mobx';
24
+ import { observer } from 'mobx-react';
25
+ let SelectorAsync = class SelectorAsync extends Component {
26
+ constructor(props) {
27
+ super(props);
28
+ Object.defineProperty(this, "shownOptions", {
29
+ enumerable: true,
30
+ configurable: true,
31
+ writable: true,
32
+ value: []
33
+ });
34
+ Object.defineProperty(this, "search", {
35
+ enumerable: true,
36
+ configurable: true,
37
+ writable: true,
38
+ value: ''
39
+ });
40
+ Object.defineProperty(this, "error", {
41
+ enumerable: true,
42
+ configurable: true,
43
+ writable: true,
44
+ value: false
45
+ });
46
+ Object.defineProperty(this, "loading", {
47
+ enumerable: true,
48
+ configurable: true,
49
+ writable: true,
50
+ value: false
51
+ });
52
+ Object.defineProperty(this, "handleKeyDown", {
53
+ enumerable: true,
54
+ configurable: true,
55
+ writable: true,
56
+ value: (event) => {
57
+ if (event.key === 'Enter') {
58
+ event.stopPropagation();
59
+ }
60
+ }
61
+ });
62
+ Object.defineProperty(this, "handleSearch", {
63
+ enumerable: true,
64
+ configurable: true,
65
+ writable: true,
66
+ value: (_0, data) => {
67
+ runInAction(() => (this.search = data.value));
68
+ this.searchOptions().catch();
69
+ }
70
+ });
71
+ Object.defineProperty(this, "searchOptions", {
72
+ enumerable: true,
73
+ configurable: true,
74
+ writable: true,
75
+ value: () => __awaiter(this, void 0, void 0, function* () {
76
+ runInAction(() => {
77
+ this.loading = true;
78
+ });
79
+ try {
80
+ const { data } = yield this.props.dataFetcher({
81
+ search: this.search,
82
+ });
83
+ runInAction(() => {
84
+ this.shownOptions = data;
85
+ this.error = false;
86
+ this.loading = false;
87
+ });
88
+ }
89
+ catch (_a) {
90
+ runInAction(() => {
91
+ this.error = true;
92
+ this.loading = false;
93
+ });
94
+ }
95
+ })
96
+ });
97
+ makeObservable(this);
98
+ }
99
+ componentDidMount() {
100
+ this.searchOptions().catch();
101
+ }
102
+ render() {
103
+ const selectedOptions = this.props.selected;
104
+ const selected = new Set(selectedOptions.map(opt => opt.value));
105
+ const ItemComponent = this.props.itemComponent;
106
+ return (_jsxs(Fragment, { children: [_jsx(Input, { className: "m-x-half m-t-half m-b-2", placeholder: this.props.placeholder, onChange: this.handleSearch, onKeyDown: this.handleKeyDown, size: "xsmall", value: this.search }), _jsxs("div", Object.assign({ className: "p-x-half position-relative", onKeyDown: this.handleKeyDown }, { children: [!!selectedOptions.length && (_jsx("div", Object.assign({ className: "border-bottom m-y-half" }, { children: selectedOptions.map(option => (_jsx(ItemComponent, { option: option, checked: true, renderer: this.props.renderer, onChange: this.props.onChange }, option.value))) }))), this.error ? (_jsx(BodyText, Object.assign({ className: "c-red-500" }, { children: "Unable to load options" }))) : this.shownOptions.length ? (this.shownOptions
107
+ .filter(opt => !selected.has(opt.value))
108
+ .map(option => (_jsx(ItemComponent, { option: option, checked: false, renderer: this.props.renderer, onChange: this.props.onChange }, option.value)))) : this.loading ? (_jsx(BodyText, { children: "\u00A0" })) : (_jsx(BodyText, { children: "No options found" })), this.loading && (_jsx("div", Object.assign({ className: "position-absolute top-0 bottom-0 left-0 right-0 opacity-disabled bg-white d-f justify-content-center" }, { children: _jsx(Spinner, { size: "tiny" }) })))] }))] }));
109
+ }
110
+ };
111
+ __decorate([
112
+ observable,
113
+ __metadata("design:type", Array)
114
+ ], SelectorAsync.prototype, "shownOptions", void 0);
115
+ __decorate([
116
+ observable,
117
+ __metadata("design:type", Object)
118
+ ], SelectorAsync.prototype, "search", void 0);
119
+ __decorate([
120
+ observable,
121
+ __metadata("design:type", Object)
122
+ ], SelectorAsync.prototype, "error", void 0);
123
+ __decorate([
124
+ observable,
125
+ __metadata("design:type", Object)
126
+ ], SelectorAsync.prototype, "loading", void 0);
127
+ SelectorAsync = __decorate([
128
+ observer,
129
+ __metadata("design:paramtypes", [Object])
130
+ ], SelectorAsync);
131
+ const SelectorItemSingle = ({ option, renderer, checked, onChange }) => {
132
+ var _a;
133
+ return (_jsx(Radio, { label: (_a = renderer === null || renderer === void 0 ? void 0 : renderer(option)) !== null && _a !== void 0 ? _a : option.text, checked: checked, onChange: (_, event) => onChange(option, true, event), className: "m-b-1" }));
134
+ };
135
+ const SelectorItemMultiple = ({ option, renderer, checked, onChange }) => {
136
+ var _a;
137
+ return (_jsx(Checkbox, { label: (_a = renderer === null || renderer === void 0 ? void 0 : renderer(option)) !== null && _a !== void 0 ? _a : option.text, checked: checked, onChange: (_, checked, event) => onChange(option, checked, event), className: "m-b-1" }));
138
+ };
139
+ export function asyncSelectColumnMenuFilter(options) {
140
+ const contains = (value, options) => options === null || options === void 0 ? void 0 : options.some(opt => opt.value === value);
141
+ const equals = (value, option) => (option === null || option === void 0 ? void 0 : option.value) === value;
142
+ const FilterCell = options.multiple
143
+ ? ({ value, onChange }) => {
144
+ const handleChange = (option, checked, event) => {
145
+ const val = checked
146
+ ? (value !== null && value !== void 0 ? value : []).concat(option)
147
+ : (value !== null && value !== void 0 ? value : []).filter(opt => opt.value !== option.value);
148
+ onChange({
149
+ value: val.length ? val : undefined,
150
+ operator: val.length ? contains : '',
151
+ syntheticEvent: event,
152
+ });
153
+ };
154
+ return (_jsx(SelectorAsync, { selected: value !== null && value !== void 0 ? value : [], itemComponent: SelectorItemMultiple, onChange: handleChange, placeholder: options.placeholder, renderer: options.renderItem, dataFetcher: options.dataFetcher }));
155
+ }
156
+ : ({ value, onChange }) => {
157
+ const handleChange = (option, checked, event) => {
158
+ onChange({
159
+ value: option,
160
+ operator: option ? equals : '',
161
+ syntheticEvent: event,
162
+ });
163
+ };
164
+ return (_jsx(SelectorAsync, { selected: value ? [value] : [], onChange: handleChange, itemComponent: SelectorItemSingle, placeholder: options.placeholder, renderer: options.renderItem, dataFetcher: options.dataFetcher }));
165
+ };
166
+ return renderCustomColumnMenuFilter(FilterCell);
167
+ }
168
+ //# sourceMappingURL=async-select-filter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"async-select-filter.js","sourceRoot":"","sources":["../../../src/filters/async-select/async-select-filter.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,SAAS,EAA6B,QAAQ,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AAE,KAAK;iBACxB,CAAC,CAAC;YACP,CAAC,CAAC;YAEF,OAAO,CACH,KAAC,aAAa,IACV,QAAQ,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,EAC9B,QAAQ,EAAE,YAAY,EACtB,aAAa,EAAE,kBAAkB,EACjC,WAAW,EAAE,OAAO,CAAC,WAAW,EAChC,QAAQ,EAAE,OAAO,CAAC,UAAU,EAC5B,WAAW,EAAE,OAAO,CAAC,WAAW,GAClC,CACL,CAAC;QACN,CAAC,CAAC;IAER,OAAO,4BAA4B,CAAC,UAAU,CAAC,CAAC;AACpD,CAAC"}
@@ -0,0 +1,7 @@
1
+ /// <reference types="react" />
2
+ declare const _default: {
3
+ title: string;
4
+ };
5
+ export default _default;
6
+ export declare const AsyncSelect: () => JSX.Element;
7
+ //# sourceMappingURL=async-select-filter.stories.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"async-select-filter.stories.d.ts","sourceRoot":"","sources":["../../../src/filters/async-select/async-select-filter.stories.tsx"],"names":[],"mappings":";;;;AAEA,wBAEE;AAEF,eAAO,MAAM,WAAW,mBAAyB,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { TableExample } from '../../demo/filters/async-select-filter';
3
+ export default {
4
+ title: 'Table/Filters',
5
+ };
6
+ export const AsyncSelect = () => _jsx(TableExample, {});
7
+ //# sourceMappingURL=async-select-filter.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"async-select-filter.stories.js","sourceRoot":"","sources":["../../../src/filters/async-select/async-select-filter.stories.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,wCAAwC,CAAC;AAEtE,eAAe;IACX,KAAK,EAAE,eAAe;CACzB,CAAC;AAEF,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,EAAE,CAAC,KAAC,YAAY,KAAG,CAAC"}
@@ -4,6 +4,8 @@ export * from './standard-filter-with-multiselect/standard-filter-with-multisele
4
4
  export * from './time-filter/time-filter';
5
5
  export * from './column-menu-filters';
6
6
  export * from './field-values-filter';
7
- export * from './multiselect-filter';
7
+ export * from './multiselect-filter/multiselect-filter';
8
8
  export * from './numeric-filter-extended/numeric-filter-extended';
9
+ export * from './single-select/single-select-filter';
10
+ export * from './async-select/async-select-filter';
9
11
  //# sourceMappingURL=index.d.ts.map