@gisce/react-ooui 1.2.0-rc.84 → 1.2.0-rc.85
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/actionbar/SearchBar.d.ts.map +1 -1
- package/dist/react-ooui.es.js +14 -0
- package/dist/react-ooui.es.js.map +1 -1
- package/dist/react-ooui.umd.js +2 -2
- package/dist/react-ooui.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/actionbar/SearchBar.tsx +8 -4
- package/src/widgets/base/many2one/Many2one.tsx +2 -2
package/package.json
CHANGED
|
@@ -13,9 +13,8 @@ function SearchBar(props: Props) {
|
|
|
13
13
|
const { onSearch, disabled = false, searchText } = props;
|
|
14
14
|
const { t } = useContext(LocaleContext) as LocaleContextType;
|
|
15
15
|
const [form] = Form.useForm();
|
|
16
|
-
const [mustShowClearSuffix, setMustShowClearSuffix] =
|
|
17
|
-
false
|
|
18
|
-
);
|
|
16
|
+
const [mustShowClearSuffix, setMustShowClearSuffix] =
|
|
17
|
+
useState<boolean>(false);
|
|
19
18
|
|
|
20
19
|
function handleSubmit(values: any) {
|
|
21
20
|
onSearch(values.search);
|
|
@@ -42,6 +41,7 @@ function SearchBar(props: Props) {
|
|
|
42
41
|
onChange={(e) => {
|
|
43
42
|
setMustShowClearSuffix(e.target.value.length > 0);
|
|
44
43
|
}}
|
|
44
|
+
style={{ borderTopRightRadius: 0, borderBottomRightRadius: 0 }}
|
|
45
45
|
suffix={
|
|
46
46
|
(mustShowClearSuffix ||
|
|
47
47
|
(searchText && searchText.length > 0)) && (
|
|
@@ -57,7 +57,11 @@ function SearchBar(props: Props) {
|
|
|
57
57
|
</Form.Item>
|
|
58
58
|
</Col>
|
|
59
59
|
<Col>
|
|
60
|
-
<Button
|
|
60
|
+
<Button
|
|
61
|
+
htmlType="submit"
|
|
62
|
+
disabled={disabled}
|
|
63
|
+
style={{ borderTopLeftRadius: 0, borderBottomLeftRadius: 0 }}
|
|
64
|
+
>
|
|
61
65
|
{t("search")}
|
|
62
66
|
</Button>
|
|
63
67
|
</Col>
|
|
@@ -257,7 +257,7 @@ export const Many2oneInput: React.FC<Many2oneInputProps> = (
|
|
|
257
257
|
}
|
|
258
258
|
/>
|
|
259
259
|
</Col>
|
|
260
|
-
<Col flex="32px">
|
|
260
|
+
<Col flex="32px" style={{ paddingRight: 0 }}>
|
|
261
261
|
<Button
|
|
262
262
|
icon={<FolderOpenOutlined />}
|
|
263
263
|
disabled={id === undefined || text === "" || inputText === undefined}
|
|
@@ -268,7 +268,7 @@ export const Many2oneInput: React.FC<Many2oneInputProps> = (
|
|
|
268
268
|
tabIndex={-1}
|
|
269
269
|
/>
|
|
270
270
|
</Col>
|
|
271
|
-
<Col flex="32px">
|
|
271
|
+
<Col flex="32px" style={{ paddingLeft: 0 }}>
|
|
272
272
|
<Button
|
|
273
273
|
icon={searching ? <LoadingOutlined /> : <SearchOutlined />}
|
|
274
274
|
disabled={readOnly || searching}
|