@evergis/uilib-gl 1.0.105 → 1.0.107
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.
|
@@ -35,6 +35,14 @@ export declare type FilterTypeOption = IOption & {
|
|
|
35
35
|
checkboxes?: boolean;
|
|
36
36
|
};
|
|
37
37
|
export declare type FilterValue = [DatePickerDate, DatePickerDate] | Date | [number | undefined, number | undefined] | number | string | string[] | boolean | null | undefined;
|
|
38
|
+
export interface FilterBooleanInputSettings {
|
|
39
|
+
trueText?: string;
|
|
40
|
+
falseText?: string;
|
|
41
|
+
nullText?: string;
|
|
42
|
+
}
|
|
43
|
+
export interface FilterInputSettings {
|
|
44
|
+
boolean: FilterBooleanInputSettings;
|
|
45
|
+
}
|
|
38
46
|
export interface FilterInputProps {
|
|
39
47
|
label?: string;
|
|
40
48
|
value?: FilterValue;
|
|
@@ -54,4 +62,5 @@ export interface FilterInputProps {
|
|
|
54
62
|
prefix?: ReactNode;
|
|
55
63
|
active?: boolean;
|
|
56
64
|
menuMaxHeight?: string;
|
|
65
|
+
settings?: FilterInputSettings;
|
|
57
66
|
}
|
package/dist/uilib-gl.esm.js
CHANGED
|
@@ -26228,6 +26228,8 @@ const FILTER_OPTIONS_BOOL = [{
|
|
|
26228
26228
|
/* eslint-disable max-lines */
|
|
26229
26229
|
const FilterInput = /*#__PURE__*/memo( // eslint-disable-next-line max-lines-per-function
|
|
26230
26230
|
_ref => {
|
|
26231
|
+
var _settings$boolean, _settings$boolean2, _settings$boolean3;
|
|
26232
|
+
|
|
26231
26233
|
let {
|
|
26232
26234
|
value: propValue,
|
|
26233
26235
|
type: inputType,
|
|
@@ -26246,7 +26248,8 @@ _ref => {
|
|
|
26246
26248
|
disabled,
|
|
26247
26249
|
prefix,
|
|
26248
26250
|
active,
|
|
26249
|
-
menuMaxHeight
|
|
26251
|
+
menuMaxHeight,
|
|
26252
|
+
settings
|
|
26250
26253
|
} = _ref;
|
|
26251
26254
|
const [filterValue, setFilterValue] = useState(null);
|
|
26252
26255
|
const [isMenuOpened, toggleMenu] = useToggle();
|
|
@@ -26438,20 +26441,23 @@ _ref => {
|
|
|
26438
26441
|
return React.createElement(Dropdown, {
|
|
26439
26442
|
label: label,
|
|
26440
26443
|
options: [{
|
|
26441
|
-
text: "
|
|
26444
|
+
text: (settings == null ? void 0 : (_settings$boolean = settings.boolean) == null ? void 0 : _settings$boolean.trueText) ?? "true",
|
|
26442
26445
|
value: "true"
|
|
26443
26446
|
}, {
|
|
26444
|
-
text: "
|
|
26447
|
+
text: (settings == null ? void 0 : (_settings$boolean2 = settings.boolean) == null ? void 0 : _settings$boolean2.falseText) ?? "false",
|
|
26445
26448
|
value: "false"
|
|
26449
|
+
}, {
|
|
26450
|
+
text: (settings == null ? void 0 : (_settings$boolean3 = settings.boolean) == null ? void 0 : _settings$boolean3.nullText) ?? "null",
|
|
26451
|
+
value: "null"
|
|
26446
26452
|
}],
|
|
26447
|
-
value: filterValue ? "true" : "false",
|
|
26453
|
+
value: filterValue === true ? "true" : filterValue === false ? "false" : "null",
|
|
26448
26454
|
zIndex: zIndex,
|
|
26449
26455
|
disabled: isDisabled,
|
|
26450
26456
|
width: "100%",
|
|
26451
26457
|
onChange: value => {
|
|
26452
|
-
var _value
|
|
26458
|
+
var _value$, _value$2;
|
|
26453
26459
|
|
|
26454
|
-
onFilterChange(FILTER_OPTIONS_BOOL[0], (value == null ? void 0 : (_value$ = value[0]) == null ? void 0 : _value$.value) === "true");
|
|
26460
|
+
onFilterChange(FILTER_OPTIONS_BOOL[0], (value == null ? void 0 : (_value$ = value[0]) == null ? void 0 : _value$.value) === "true" ? true : (value == null ? void 0 : (_value$2 = value[0]) == null ? void 0 : _value$2.value) === "false" ? false : null);
|
|
26455
26461
|
},
|
|
26456
26462
|
menuMaxHeight: menuMaxHeight
|
|
26457
26463
|
});
|
|
@@ -26993,6 +26999,7 @@ const PreviewImageContainer = styled.div`
|
|
|
26993
26999
|
display: flex;
|
|
26994
27000
|
box-sizing: border-box;
|
|
26995
27001
|
justify-content: center;
|
|
27002
|
+
align-items: center;
|
|
26996
27003
|
`;
|
|
26997
27004
|
const PreviewImage = /*#__PURE__*/styled(Image)`
|
|
26998
27005
|
width: 100%;
|
|
@@ -27019,6 +27026,7 @@ const ArrowsContainer = styled.div`
|
|
|
27019
27026
|
justify-content: space-between;
|
|
27020
27027
|
`;
|
|
27021
27028
|
const PreviewOverlay = /*#__PURE__*/styled(DialogOverlay)`
|
|
27029
|
+
background: rgba(17, 37, 47, 0.85);
|
|
27022
27030
|
overflow: hidden;
|
|
27023
27031
|
|
|
27024
27032
|
@media (max-width: 768px) {
|
|
@@ -27109,11 +27117,13 @@ const PreviewImageError = styled.div`
|
|
|
27109
27117
|
align-items: center;
|
|
27110
27118
|
justify-content: center;
|
|
27111
27119
|
gap: 0.5rem;
|
|
27120
|
+
max-width: 40rem;
|
|
27121
|
+
max-height: 22.5rem;
|
|
27112
27122
|
width: 100%;
|
|
27113
27123
|
height: 100%;
|
|
27114
|
-
|
|
27115
|
-
background: rgba(0, 0, 0, 0.24);
|
|
27124
|
+
background: rgba(255, 255, 255, 0.06);
|
|
27116
27125
|
border-radius: 0.25rem;
|
|
27126
|
+
color: rgba(255, 255, 255, 0.54);
|
|
27117
27127
|
|
|
27118
27128
|
${Icon} {
|
|
27119
27129
|
width: 3rem;
|