@gisce/react-ooui 1.1.64-rc.0 → 1.1.65-rc.0
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/dist/react-ooui.es.js +15 -27
- package/dist/react-ooui.es.js.map +1 -1
- package/dist/react-ooui.umd.js +11 -11
- package/dist/react-ooui.umd.js.map +1 -1
- package/dist/widgets/views/searchFilter/SearchField.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/widgets/views/searchFilter/SearchField.tsx +9 -23
package/dist/react-ooui.es.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import React__default, { useContext, useState, useEffect, useRef, useLayoutEffect, Component, useCallback, forwardRef, useImperativeHandle } from "react";
|
|
3
3
|
import { Tooltip as Tooltip$2, Typography as Typography$1, Form as Form$3, Row, Col, Modal, Button as Button$1, Dropdown, Menu, Spin, Divider, Space, Input as Input$1, Select, Checkbox, Alert, Timeline as Timeline$1, Statistic, Card, Tag as Tag$1, message as message$1, DatePicker as DatePicker$1, TimePicker, InputNumber, Progress, Pagination, Tabs, Popover, Radio as Radio$1, Switch as Switch$1, Steps as Steps$1, Layout } from "antd";
|
|
4
|
-
import { Label as Label$1, Field as Field$2, Tree as Tree$1, Reference as Reference$1, Selection as Selection$1, Many2one as Many2one$1, Boolean as Boolean$2, Container as Container$1, parseContext, Form as Form$4, Integer as Integer$1, SearchFilter as SearchFilter$1, transformDomainForChildWidget, graphProcessor, parseGraph, graphFieldUtils } from "@gisce/ooui";
|
|
4
|
+
import { Label as Label$1, Field as Field$2, Tree as Tree$1, Reference as Reference$1, Selection as Selection$1, Many2one as Many2one$1, Boolean as Boolean$2, Container as Container$1, parseContext, Form as Form$4, Integer as Integer$1, SearchFieldTypes, SearchFilter as SearchFilter$1, transformDomainForChildWidget, graphProcessor, parseGraph, graphFieldUtils } from "@gisce/ooui";
|
|
5
5
|
import * as AntIcons from "@ant-design/icons";
|
|
6
6
|
import AntIcons__default, { QuestionCircleOutlined, ExclamationCircleOutlined as ExclamationCircleOutlined$3, LoadingOutlined as LoadingOutlined$3, DownOutlined, WarningOutlined, CloseOutlined as CloseOutlined$3, CheckOutlined as CheckOutlined$3, TranslationOutlined, FolderOpenOutlined, DownloadOutlined, ClearOutlined, StarFilled, StarOutlined, UpOutlined, SearchOutlined, RightCircleOutlined, ThunderboltOutlined, PrinterOutlined, EnterOutlined as EnterOutlined$3, PlusSquareOutlined, MinusSquareOutlined, FileAddOutlined, AlignLeftOutlined, ApiOutlined, DeleteOutlined, LeftOutlined, RightOutlined, EyeOutlined, FormOutlined, TableOutlined, AreaChartOutlined, CalendarOutlined, LinkOutlined, SaveOutlined, CopyOutlined as CopyOutlined$3, InfoCircleOutlined as InfoCircleOutlined$3, ReloadOutlined, EditOutlined as EditOutlined$3, FilterOutlined, CloseCircleFilled as CloseCircleFilled$3, BorderOuterOutlined, SettingOutlined, ExportOutlined } from "@ant-design/icons";
|
|
7
7
|
import { Interweave } from "interweave";
|
|
@@ -3682,12 +3682,12 @@ var pattern = {
|
|
|
3682
3682
|
email: /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,
|
|
3683
3683
|
url: new RegExp("^(?!mailto:)(?:(?:http|https|ftp)://|//)(?:\\S+(?::\\S*)?@)?(?:(?:(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[0-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)(?:\\.(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)*(?:\\.(?:[a-z\\u00a1-\\uffff]{2,})))|localhost)(?::\\d{2,5})?(?:(/|\\?|#)[^\\s]*)?$", "i"),
|
|
3684
3684
|
hex: /^#?([a-f0-9]{6}|[a-f0-9]{3})$/i
|
|
3685
|
-
}, types$
|
|
3685
|
+
}, types$1 = {
|
|
3686
3686
|
integer: function(t) {
|
|
3687
|
-
return types$
|
|
3687
|
+
return types$1.number(t) && parseInt(t, 10) === t;
|
|
3688
3688
|
},
|
|
3689
3689
|
float: function(t) {
|
|
3690
|
-
return types$
|
|
3690
|
+
return types$1.number(t) && !types$1.integer(t);
|
|
3691
3691
|
},
|
|
3692
3692
|
array: function(t) {
|
|
3693
3693
|
return Array.isArray(t);
|
|
@@ -3708,7 +3708,7 @@ var pattern = {
|
|
|
3708
3708
|
return isNaN(t) ? !1 : typeof t == "number";
|
|
3709
3709
|
},
|
|
3710
3710
|
object: function(t) {
|
|
3711
|
-
return typeof t == "object" && !types$
|
|
3711
|
+
return typeof t == "object" && !types$1.array(t);
|
|
3712
3712
|
},
|
|
3713
3713
|
method: function(t) {
|
|
3714
3714
|
return typeof t == "function";
|
|
@@ -3729,7 +3729,7 @@ function type(e, t, r, n, a) {
|
|
|
3729
3729
|
return;
|
|
3730
3730
|
}
|
|
3731
3731
|
var o = ["integer", "float", "array", "regexp", "object", "method", "email", "number", "date", "url", "hex"], s = e.type;
|
|
3732
|
-
o.indexOf(s) > -1 ? types$
|
|
3732
|
+
o.indexOf(s) > -1 ? types$1[s](t) || n.push(format$1(a.messages.types[s], e.fullField, e.type)) : s && typeof t !== e.type && n.push(format$1(a.messages.types[s], e.fullField, e.type));
|
|
3733
3733
|
}
|
|
3734
3734
|
function range(e, t, r, n, a) {
|
|
3735
3735
|
var o = typeof e.len == "number", s = typeof e.min == "number", u = typeof e.max == "number", l = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g, c = t, d = null, f = typeof t == "number", p = typeof t == "string", h = Array.isArray(t);
|
|
@@ -14657,19 +14657,7 @@ const {
|
|
|
14657
14657
|
&.ant-select:not(.ant-select-customize-input) .ant-select-selector {
|
|
14658
14658
|
background-color: ${Config.requiredColor};
|
|
14659
14659
|
}
|
|
14660
|
-
|
|
14661
|
-
text: "text",
|
|
14662
|
-
many2one: "many2one",
|
|
14663
|
-
char: "char",
|
|
14664
|
-
boolean: "boolean",
|
|
14665
|
-
selection: "selection",
|
|
14666
|
-
float: "float",
|
|
14667
|
-
float_time: "float_time",
|
|
14668
|
-
progressbar: "progressbar",
|
|
14669
|
-
integer: "integer",
|
|
14670
|
-
date: "date",
|
|
14671
|
-
datetime: "datetime"
|
|
14672
|
-
};
|
|
14660
|
+
`;
|
|
14673
14661
|
function SearchField(e) {
|
|
14674
14662
|
const {
|
|
14675
14663
|
field: t
|
|
@@ -14679,7 +14667,7 @@ function SearchField(e) {
|
|
|
14679
14667
|
t: r
|
|
14680
14668
|
} = useContext(LocaleContext);
|
|
14681
14669
|
switch (t.type) {
|
|
14682
|
-
case
|
|
14670
|
+
case SearchFieldTypes.boolean: {
|
|
14683
14671
|
const a = new Selection$1({
|
|
14684
14672
|
name: t._id,
|
|
14685
14673
|
string: t.label,
|
|
@@ -14691,27 +14679,27 @@ function SearchField(e) {
|
|
|
14691
14679
|
showLabel: !0
|
|
14692
14680
|
});
|
|
14693
14681
|
}
|
|
14694
|
-
case
|
|
14695
|
-
case
|
|
14696
|
-
case
|
|
14697
|
-
case
|
|
14682
|
+
case SearchFieldTypes.float:
|
|
14683
|
+
case SearchFieldTypes.progressbar:
|
|
14684
|
+
case SearchFieldTypes.float_time:
|
|
14685
|
+
case SearchFieldTypes.integer:
|
|
14698
14686
|
return /* @__PURE__ */ jsx(PairFields, {
|
|
14699
14687
|
ooui: t,
|
|
14700
14688
|
showLabel: !0
|
|
14701
14689
|
});
|
|
14702
|
-
case
|
|
14690
|
+
case SearchFieldTypes.date:
|
|
14703
14691
|
return /* @__PURE__ */ jsx(DateRangePicker, {
|
|
14704
14692
|
ooui: t,
|
|
14705
14693
|
layout: "vertical",
|
|
14706
14694
|
showLabel: !0
|
|
14707
14695
|
});
|
|
14708
|
-
case
|
|
14696
|
+
case SearchFieldTypes.datetime:
|
|
14709
14697
|
return /* @__PURE__ */ jsx(DateTimeRangePicker, {
|
|
14710
14698
|
ooui: t,
|
|
14711
14699
|
layout: "vertical",
|
|
14712
14700
|
showLabel: !0
|
|
14713
14701
|
});
|
|
14714
|
-
case
|
|
14702
|
+
case SearchFieldTypes.selection:
|
|
14715
14703
|
return /* @__PURE__ */ jsx(MultiSelection, {
|
|
14716
14704
|
layout: "vertical",
|
|
14717
14705
|
ooui: t,
|