@servicetitan/table 23.1.0 → 23.2.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/filters/standard-filter-with-multiselect/filter-cell-ext.d.ts.map +1 -1
- package/dist/filters/standard-filter-with-multiselect/filter-cell-ext.js +6 -2
- package/dist/filters/standard-filter-with-multiselect/filter-cell-ext.js.map +1 -1
- package/dist/filters/standard-filter-with-multiselect/filter-cell-ext.module.css +29 -0
- package/package.json +6 -6
- package/src/filters/standard-filter-with-multiselect/filter-cell-ext.module.css +29 -0
- package/src/filters/standard-filter-with-multiselect/filter-cell-ext.module.css.d.ts +3 -0
- package/src/filters/standard-filter-with-multiselect/filter-cell-ext.tsx +22 -3
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"filter-cell-ext.d.ts","sourceRoot":"","sources":["../../../src/filters/standard-filter-with-multiselect/filter-cell-ext.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,EAAE,EAAe,MAAM,OAAO,CAAC;AAKjE,OAAO,EAMH,aAAa,EACb,kBAAkB,EACrB,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,6BAA6B,IAAI,8BAA8B,EAAE,MAAM,yEAAyE,CAAC;
|
1
|
+
{"version":3,"file":"filter-cell-ext.d.ts","sourceRoot":"","sources":["../../../src/filters/standard-filter-with-multiselect/filter-cell-ext.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,EAAE,EAAe,MAAM,OAAO,CAAC;AAKjE,OAAO,EAMH,aAAa,EACb,kBAAkB,EACrB,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,6BAA6B,IAAI,8BAA8B,EAAE,MAAM,yEAAyE,CAAC;AAY1J,UAAU,kBAAkB;IACxB,KAAK,EAAE,GAAG,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,kBAAmB,SAAQ,8BAA8B;IACtE,OAAO,EAAE,kBAAkB,EAAE,CAAC;IAC9B,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,gCAAgC,CAAC,EAAE,OAAO,CAAC;IAC3C,0BAA0B,CAAC,EAAE,OAAO,CAAC;IACrC,qBAAqB,CAAC,CAAC,EAAE,EAAE,YAAY,CAAC,aAAa,CAAC,EAAE,SAAS,EAAE,aAAa,GAAG,SAAS,CAAC;IAC7F,oBAAoB,CAAC,CACjB,OAAO,EAAE,kBAAkB,EAC3B,EAAE,EAAE,YAAY,CAAC,aAAa,CAAC,GAChC,YAAY,CAAC,aAAa,CAAC,CAAC;IAC/B,2BAA2B,CAAC,CAAC,OAAO,EAAE,YAAY,CAAC,cAAc,CAAC,GAAG,SAAS,CAAC;CAClF;AAGD,eAAO,MAAM,aAAa,EAAE,EAAE,CAAC,kBAAkB,CA6I/C,CAAC"}
|
@@ -4,8 +4,9 @@ import { observer, useLocalStore } from 'mobx-react';
|
|
4
4
|
import { multiselectOperators, isMultiselectOperator } from './multiselect-operators';
|
5
5
|
import { DropDownList, MultiSelect, } from '@progress/kendo-react-dropdowns';
|
6
6
|
import { IsUnaryFilter, cellOperatorChange, } from '@progress/kendo-react-grid/dist/npm/filterCommon';
|
7
|
-
import { Icon } from '@servicetitan/design-system';
|
7
|
+
import { Icon, Tooltip } from '@servicetitan/design-system';
|
8
8
|
import * as Styles from './filter-cell-ext.module.css';
|
9
|
+
import classNames from 'classnames';
|
9
10
|
// like standard filter cell (rendered for string type), but with support of multiselect operators
|
10
11
|
export const FilterCellExt = observer(props => {
|
11
12
|
const store = useLocalStore(oprops => ({
|
@@ -77,6 +78,9 @@ export const FilterCellExt = observer(props => {
|
|
77
78
|
(!props.handleCustomValuesAsNumber || !isNaN(+store.searchQuery))) ||
|
78
79
|
false;
|
79
80
|
return (_jsxs("div", { children: [_jsx(DropDownList, { value: store.operatorValue, onChange: handleOperatorChange, data: store.operators, className: "m-b-1", textField: "text" }), (typeof operator !== 'string' || !IsUnaryFilter(operator)) &&
|
80
|
-
(isMultiselectOperator(operator) ? (_jsx(MultiSelect, { value: store.multiselectValue, onChange: handleMultiselectChange, filterable: true, onFilterChange: store.filterChange, allowCustom: allowCustomAdd, data: store.filteredVisibleValues, textField: "text", dataItemKey: "value", className:
|
81
|
+
(isMultiselectOperator(operator) ? (_jsx(MultiSelect, { value: store.multiselectValue, onChange: handleMultiselectChange, filterable: true, onFilterChange: store.filterChange, allowCustom: allowCustomAdd, data: store.filteredVisibleValues, textField: "text", dataItemKey: "value", className: classNames('m-b-1', Styles.multiSelect), header: allowCustomAdd && _jsx("div", { className: Styles.customItemAddMarker }), footer: allowCustomAdd ? (_jsxs("div", Object.assign({ className: Styles.returnToUse }, { children: [_jsx(Icon, { name: "keyboard_return" }), "to create filter"] }))) : (store.onlyFirstValues && (_jsxs("div", Object.assign({ className: Styles.returnToUse }, { children: ["First ", store.onlyFirstValues, " values are shown. ", _jsx("br", {}), "Type to search for other values."] })))), itemRender: multiselectItemRender, tagRender: multiselectTagRender !== null && multiselectTagRender !== void 0 ? multiselectTagRender : defaultMultiselectTagRender, listNoDataRender: multiselectListNoDataRender })) : (_jsx("input", { className: "k-input k-input-md k-rounded-md k-input-solid m-b-1", value: props.value, onChange: handleInputChange })))] }));
|
81
82
|
});
|
83
|
+
const defaultMultiselectTagRender = (tagData, li) => {
|
84
|
+
return (_jsx(Tooltip, Object.assign({ portal: true, text: tagData.text, className: Styles.multiSelectTagTooltipWrapper, popperClassName: Styles.multiSelectTagTooltip }, { children: li })));
|
85
|
+
};
|
82
86
|
//# sourceMappingURL=filter-cell-ext.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"filter-cell-ext.js","sourceRoot":"","sources":["../../../src/filters/standard-filter-with-multiselect/filter-cell-ext.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AACrD,OAAO,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAEtF,OAAO,EACH,YAAY,EAEZ,WAAW,GAKd,MAAM,iCAAiC,CAAC;AAGzC,OAAO,EACH,aAAa,EACb,kBAAkB,GACrB,MAAM,kDAAkD,CAAC;
|
1
|
+
{"version":3,"file":"filter-cell-ext.js","sourceRoot":"","sources":["../../../src/filters/standard-filter-with-multiselect/filter-cell-ext.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AACrD,OAAO,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAEtF,OAAO,EACH,YAAY,EAEZ,WAAW,GAKd,MAAM,iCAAiC,CAAC;AAGzC,OAAO,EACH,aAAa,EACb,kBAAkB,GACrB,MAAM,kDAAkD,CAAC;AAE1D,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AAE5D,OAAO,KAAK,MAAM,MAAM,8BAA8B,CAAC;AACvD,OAAO,UAAU,MAAM,YAAY,CAAC;AAuBpC,kGAAkG;AAClG,MAAM,CAAC,MAAM,aAAa,GAA2B,QAAQ,CAAC,KAAK,CAAC,EAAE;IAClE,MAAM,KAAK,GAAG,aAAa,CACvB,MAAM,CAAC,EAAE,CAAC,CAAC;QACP,IAAI,SAAS;YACT,OAAO,oBAAoB,CAAC,MAAM,CAC9B,MAAM,CAAC,gCAAgC;gBACnC,CAAC,CAAC,MAAM,CAAC,SAAS,CAAC,MAAM,CACnB,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,QAAQ,KAAK,SAAS,IAAI,CAAC,CAAC,QAAQ,KAAK,YAAY,CAC/D;gBACH,CAAC,CAAC,MAAM,CAAC,SAAS,CACzB,CAAC;QACN,CAAC;QACD,IAAI,aAAa;YACb,O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EAAC,iBAAiB,GAAG,yBAE7B,CACT,CAAC,CAAC,CAAC,CACA,KAAK,CAAC,eAAe,IAAI,CACrB,6BAAK,SAAS,EAAE,MAAM,CAAC,WAAW,2BACvB,KAAK,CAAC,eAAe,yBAAoB,cAAM,yCAEpD,CACT,CACJ,EAEL,UAAU,EAAE,qBAAqB,EACjC,SAAS,EAAE,oBAAoB,aAApB,oBAAoB,cAApB,oBAAoB,GAAI,2BAA2B,EAC9D,gBAAgB,EAAE,2BAA2B,GAC/C,CACL,CAAC,CAAC,CAAC,CACA,gBACI,SAAS,EAAC,qDAAqD,EAC/D,KAAK,EAAE,KAAK,CAAC,KAAK,EAClB,QAAQ,EAAE,iBAAiB,GAC7B,CACL,CAAC,IACJ,CACT,CAAC;AACN,CAAC,CAAC,CAAC;AAEH,MAAM,2BAA2B,GAAG,CAChC,OAA2B,EAC3B,EAA+B,EACJ,EAAE;IAC7B,OAAO,CACH,KAAC,OAAO,kBACJ,MAAM,QACN,IAAI,EAAE,OAAO,CAAC,IAAI,EAClB,SAAS,EAAE,MAAM,CAAC,4BAA4B,EAC9C,eAAe,EAAE,MAAM,CAAC,qBAAqB,gBAE5C,EAAE,IACG,CACb,CAAC;AACN,CAAC,CAAC"}
|
@@ -1,3 +1,5 @@
|
|
1
|
+
/* stylelint-disable no-descending-specificity */
|
2
|
+
|
1
3
|
.return-to-use {
|
2
4
|
padding: var(--spacing-1);
|
3
5
|
color: var(--color-neutral-90);
|
@@ -21,3 +23,30 @@
|
|
21
23
|
.custom-item-add-marker + :global(.k-list .k-custom-item) {
|
22
24
|
display: none;
|
23
25
|
}
|
26
|
+
|
27
|
+
.multi-select {
|
28
|
+
max-height: 20vh;
|
29
|
+
overflow: auto;
|
30
|
+
}
|
31
|
+
|
32
|
+
.multi-select-tag-tooltip-wrapper {
|
33
|
+
display: inline-flex;
|
34
|
+
flex-flow: row nowrap;
|
35
|
+
align-items: center;
|
36
|
+
justify-content: center;
|
37
|
+
gap: 4px;
|
38
|
+
position: relative;
|
39
|
+
overflow: hidden;
|
40
|
+
}
|
41
|
+
.multi-select-tag-tooltip-wrapper > div {
|
42
|
+
max-width: 100%;
|
43
|
+
}
|
44
|
+
.multi-select-tag-tooltip-wrapper :global(.k-chip) {
|
45
|
+
max-width: 100%;
|
46
|
+
}
|
47
|
+
|
48
|
+
.multi-select-tag-tooltip {
|
49
|
+
z-index: 1115 !important;
|
50
|
+
}
|
51
|
+
|
52
|
+
/* stylelint-enable */
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@servicetitan/table",
|
3
|
-
"version": "23.
|
3
|
+
"version": "23.2.0",
|
4
4
|
"description": "",
|
5
5
|
"homepage": "https://docs.st.dev/docs/frontend/table",
|
6
6
|
"repository": {
|
@@ -36,9 +36,9 @@
|
|
36
36
|
"memoize-one": "~6.0.0"
|
37
37
|
},
|
38
38
|
"devDependencies": {
|
39
|
-
"@servicetitan/data-query": "^23.
|
39
|
+
"@servicetitan/data-query": "^23.2.0",
|
40
40
|
"@servicetitan/design-system": ">=12.4.1",
|
41
|
-
"@servicetitan/form": "^23.
|
41
|
+
"@servicetitan/form": "^23.2.0",
|
42
42
|
"@servicetitan/react-ioc": "^21.6.0",
|
43
43
|
"@servicetitan/suppress-warnings": "^21.6.0",
|
44
44
|
"@types/accounting": "~0.4.2",
|
@@ -52,9 +52,9 @@
|
|
52
52
|
"react": "~17.0.2"
|
53
53
|
},
|
54
54
|
"peerDependencies": {
|
55
|
-
"@servicetitan/data-query": "^23.
|
55
|
+
"@servicetitan/data-query": "^23.2.0",
|
56
56
|
"@servicetitan/design-system": ">=12.4.1",
|
57
|
-
"@servicetitan/form": "^23.
|
57
|
+
"@servicetitan/form": "^23.2.0",
|
58
58
|
"@servicetitan/react-ioc": ">21.0.0",
|
59
59
|
"@servicetitan/suppress-warnings": ">21.0.0",
|
60
60
|
"accounting": "~0.4.1",
|
@@ -71,5 +71,5 @@
|
|
71
71
|
"cli": {
|
72
72
|
"webpack": false
|
73
73
|
},
|
74
|
-
"gitHead": "
|
74
|
+
"gitHead": "3616d7fff8482c1e65a0d6281b5ddeca9b32f2ab"
|
75
75
|
}
|
@@ -1,3 +1,5 @@
|
|
1
|
+
/* stylelint-disable no-descending-specificity */
|
2
|
+
|
1
3
|
.return-to-use {
|
2
4
|
padding: var(--spacing-1);
|
3
5
|
color: var(--color-neutral-90);
|
@@ -21,3 +23,30 @@
|
|
21
23
|
.custom-item-add-marker + :global(.k-list .k-custom-item) {
|
22
24
|
display: none;
|
23
25
|
}
|
26
|
+
|
27
|
+
.multi-select {
|
28
|
+
max-height: 20vh;
|
29
|
+
overflow: auto;
|
30
|
+
}
|
31
|
+
|
32
|
+
.multi-select-tag-tooltip-wrapper {
|
33
|
+
display: inline-flex;
|
34
|
+
flex-flow: row nowrap;
|
35
|
+
align-items: center;
|
36
|
+
justify-content: center;
|
37
|
+
gap: 4px;
|
38
|
+
position: relative;
|
39
|
+
overflow: hidden;
|
40
|
+
}
|
41
|
+
.multi-select-tag-tooltip-wrapper > div {
|
42
|
+
max-width: 100%;
|
43
|
+
}
|
44
|
+
.multi-select-tag-tooltip-wrapper :global(.k-chip) {
|
45
|
+
max-width: 100%;
|
46
|
+
}
|
47
|
+
|
48
|
+
.multi-select-tag-tooltip {
|
49
|
+
z-index: 1115 !important;
|
50
|
+
}
|
51
|
+
|
52
|
+
/* stylelint-enable */
|
@@ -18,8 +18,11 @@ import {
|
|
18
18
|
IsUnaryFilter,
|
19
19
|
cellOperatorChange,
|
20
20
|
} from '@progress/kendo-react-grid/dist/npm/filterCommon';
|
21
|
-
|
21
|
+
|
22
|
+
import { Icon, Tooltip } from '@servicetitan/design-system';
|
23
|
+
|
22
24
|
import * as Styles from './filter-cell-ext.module.css';
|
25
|
+
import classNames from 'classnames';
|
23
26
|
//
|
24
27
|
|
25
28
|
interface ValueWithLowerCase {
|
@@ -154,7 +157,7 @@ export const FilterCellExt: FC<FilterCellExtProps> = observer(props => {
|
|
154
157
|
data={store.filteredVisibleValues}
|
155
158
|
textField="text"
|
156
159
|
dataItemKey="value"
|
157
|
-
className=
|
160
|
+
className={classNames('m-b-1', Styles.multiSelect)}
|
158
161
|
header={allowCustomAdd && <div className={Styles.customItemAddMarker} />}
|
159
162
|
footer={
|
160
163
|
allowCustomAdd ? (
|
@@ -172,7 +175,7 @@ export const FilterCellExt: FC<FilterCellExtProps> = observer(props => {
|
|
172
175
|
)
|
173
176
|
}
|
174
177
|
itemRender={multiselectItemRender}
|
175
|
-
tagRender={multiselectTagRender}
|
178
|
+
tagRender={multiselectTagRender ?? defaultMultiselectTagRender}
|
176
179
|
listNoDataRender={multiselectListNoDataRender}
|
177
180
|
/>
|
178
181
|
) : (
|
@@ -185,3 +188,19 @@ export const FilterCellExt: FC<FilterCellExtProps> = observer(props => {
|
|
185
188
|
</div>
|
186
189
|
);
|
187
190
|
});
|
191
|
+
|
192
|
+
const defaultMultiselectTagRender = (
|
193
|
+
tagData: MultiSelectTagData,
|
194
|
+
li: ReactElement<HTMLLIElement>
|
195
|
+
): ReactElement<HTMLLIElement> => {
|
196
|
+
return (
|
197
|
+
<Tooltip
|
198
|
+
portal
|
199
|
+
text={tagData.text}
|
200
|
+
className={Styles.multiSelectTagTooltipWrapper}
|
201
|
+
popperClassName={Styles.multiSelectTagTooltip}
|
202
|
+
>
|
203
|
+
{li}
|
204
|
+
</Tooltip>
|
205
|
+
);
|
206
|
+
};
|