@truedat/df 7.0.4 → 7.0.6
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/package.json +5 -5
- package/src/components/hierarchies/HierarchyView.js +1 -1
- package/src/components/widgets/DropdownField.js +1 -3
- package/src/templates/components/templateForm/FieldForm.js +0 -34
- package/src/templates/components/templateForm/TemplateForm.js +0 -1
- package/src/templates/components/templateForm/__tests__/FieldForm.spec.js +3 -2
- package/src/templates/components/templateForm/__tests__/__snapshots__/FieldForm.spec.js.snap +601 -282
- package/src/components/hierarchies/Hierarchy.js +0 -316
- package/src/components/hierarchies/__tests__/Hierarchy.spec.js +0 -42
- package/src/components/hierarchies/__tests__/__snapshots__/Hierarchy.spec.js.snap +0 -189
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@truedat/df",
|
|
3
|
-
"version": "7.0.
|
|
3
|
+
"version": "7.0.6",
|
|
4
4
|
"description": "Truedat Web Data Quality Module",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"jsnext:main": "src/index.js",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"@testing-library/jest-dom": "^5.16.5",
|
|
35
35
|
"@testing-library/react": "^12.0.0",
|
|
36
36
|
"@testing-library/user-event": "^13.2.1",
|
|
37
|
-
"@truedat/test": "7.0.
|
|
37
|
+
"@truedat/test": "7.0.6",
|
|
38
38
|
"babel-jest": "^28.1.0",
|
|
39
39
|
"babel-plugin-dynamic-import-node": "^2.3.3",
|
|
40
40
|
"babel-plugin-lodash": "^3.3.4",
|
|
@@ -87,8 +87,8 @@
|
|
|
87
87
|
},
|
|
88
88
|
"dependencies": {
|
|
89
89
|
"@apollo/client": "^3.7.1",
|
|
90
|
-
"@truedat/auth": "7.0.
|
|
91
|
-
"@truedat/core": "7.0.
|
|
90
|
+
"@truedat/auth": "7.0.6",
|
|
91
|
+
"@truedat/core": "7.0.6",
|
|
92
92
|
"decode-uri-component": "^0.2.2",
|
|
93
93
|
"path-to-regexp": "^1.7.0",
|
|
94
94
|
"prop-types": "^15.8.1",
|
|
@@ -109,5 +109,5 @@
|
|
|
109
109
|
"react-dom": ">= 16.8.6 < 17",
|
|
110
110
|
"semantic-ui-react": ">= 2.0.3 < 2.2"
|
|
111
111
|
},
|
|
112
|
-
"gitHead": "
|
|
112
|
+
"gitHead": "00bc7f5ff0c4a073987b4ed538f9547a12d2d0ad"
|
|
113
113
|
}
|
|
@@ -8,8 +8,8 @@ import { linkTo } from "@truedat/core/routes";
|
|
|
8
8
|
import { CSVFileModal } from "@truedat/core/components";
|
|
9
9
|
import { HistoryBackButton } from "@truedat/core/components";
|
|
10
10
|
import { ConfirmModal } from "@truedat/core/components";
|
|
11
|
+
import Hierarchy from "@truedat/core/components/Hierarchy";
|
|
11
12
|
import HierarchyCrumbs from "./HierarchyCrumbs";
|
|
12
|
-
import Hierarchy from "./Hierarchy";
|
|
13
13
|
|
|
14
14
|
const getLastId = _.flow(
|
|
15
15
|
_.pathOr([], "nodes"),
|
|
@@ -38,9 +38,7 @@ DropdownField.propTypes = {
|
|
|
38
38
|
|
|
39
39
|
const makeMapStateToProps = () => {
|
|
40
40
|
const mapStateToProps = (state, props) => ({
|
|
41
|
-
loading:
|
|
42
|
-
(_.path("field.type")(props) == "system" && state.systemsLoading) ||
|
|
43
|
-
(_.path("field.type")(props) == "domain" && state.domainsLoading),
|
|
41
|
+
loading: _.path("field.type")(props) == "system" && state.systemsLoading,
|
|
44
42
|
});
|
|
45
43
|
return mapStateToProps;
|
|
46
44
|
};
|
|
@@ -14,8 +14,6 @@ import {
|
|
|
14
14
|
} from "./widgetDefinitions";
|
|
15
15
|
import { getValues } from "./valueDefinitions";
|
|
16
16
|
|
|
17
|
-
const boostingEnabledScopes = ["bg", "dq", "ie", "ri"];
|
|
18
|
-
|
|
19
17
|
const typeFromKey = (keys) =>
|
|
20
18
|
_.includes("role_groups")(keys)
|
|
21
19
|
? "role_groups"
|
|
@@ -49,7 +47,6 @@ export const FieldForm = ({
|
|
|
49
47
|
widget,
|
|
50
48
|
disabledName,
|
|
51
49
|
errors,
|
|
52
|
-
boost = "",
|
|
53
50
|
} = field;
|
|
54
51
|
const fieldNamePrefix = `${groupNamePrefix}.fields[${fieldIndex}]`;
|
|
55
52
|
const valueName = `${fieldNamePrefix}.values`;
|
|
@@ -229,37 +226,6 @@ export const FieldForm = ({
|
|
|
229
226
|
required
|
|
230
227
|
options={getCardinalityOptions(formatMessage)(widget)}
|
|
231
228
|
/>
|
|
232
|
-
|
|
233
|
-
{_.includes(scope)(boostingEnabledScopes) ? (
|
|
234
|
-
<Form.Field>
|
|
235
|
-
<label>
|
|
236
|
-
<FormattedMessage id="template.field.boost.label" />
|
|
237
|
-
<Popup
|
|
238
|
-
trigger={
|
|
239
|
-
<Icon
|
|
240
|
-
className="rule-form-popup"
|
|
241
|
-
name="question circle outline"
|
|
242
|
-
/>
|
|
243
|
-
}
|
|
244
|
-
content={formatMessage(
|
|
245
|
-
{ id: "template.field.boost.tooltip" },
|
|
246
|
-
{ br: <br /> }
|
|
247
|
-
)}
|
|
248
|
-
on="click"
|
|
249
|
-
hideOnScroll
|
|
250
|
-
/>
|
|
251
|
-
</label>
|
|
252
|
-
<Form.Input
|
|
253
|
-
name={`${fieldNamePrefix}.boost`}
|
|
254
|
-
fluid
|
|
255
|
-
value={boost}
|
|
256
|
-
required
|
|
257
|
-
onChange={onChange}
|
|
258
|
-
type="number"
|
|
259
|
-
step="0.01"
|
|
260
|
-
/>
|
|
261
|
-
</Form.Field>
|
|
262
|
-
) : null}
|
|
263
229
|
</Form.Group>
|
|
264
230
|
<ValuesField
|
|
265
231
|
defaultField={defaultField}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { shallow } from "enzyme";
|
|
3
|
+
import { render } from "@truedat/test/render";
|
|
3
4
|
import { intl } from "@truedat/test/intl-stub";
|
|
4
5
|
import { FieldForm } from "../FieldForm";
|
|
5
6
|
|
|
@@ -25,8 +26,8 @@ describe("<FieldForm />", () => {
|
|
|
25
26
|
const fieldIndex = 0;
|
|
26
27
|
const fieldCount = 1;
|
|
27
28
|
const props = { field, fieldIndex, fieldCount, onDelete, onMove, onChange };
|
|
28
|
-
const
|
|
29
|
-
expect(
|
|
29
|
+
const { container } = render(<FieldForm {...props} />);
|
|
30
|
+
expect(container).toMatchSnapshot();
|
|
30
31
|
});
|
|
31
32
|
|
|
32
33
|
it("renders a FormInput disabled if editMode and disabled field are true", () => {
|