@truedat/dd 6.9.4 → 6.9.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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@truedat/dd",
3
- "version": "6.9.4",
3
+ "version": "6.9.6",
4
4
  "description": "Truedat Web Data Dictionary",
5
5
  "sideEffects": false,
6
6
  "jsnext:main": "src/index.js",
@@ -115,5 +115,5 @@
115
115
  "react-dom": ">= 16.8.6 < 17",
116
116
  "semantic-ui-react": ">= 2.0.3 < 2.2"
117
117
  },
118
- "gitHead": "7d6b440dd9af26cf2dcf21ad4c321f845c40e9b3"
118
+ "gitHead": "79df0d9e1a3eaa40944ee959ac52699200389037"
119
119
  }
@@ -291,6 +291,7 @@ export const DATA_STRUCTURE_VERSION_QUERY = gql`
291
291
  metadata
292
292
  name
293
293
  type
294
+ has_note
294
295
  note
295
296
  }
296
297
  children {
@@ -302,6 +303,7 @@ export const DATA_STRUCTURE_VERSION_QUERY = gql`
302
303
  metadata
303
304
  name
304
305
  type
306
+ has_note
305
307
  note
306
308
  }
307
309
  siblings {
@@ -389,6 +391,7 @@ export const DATA_STRUCTURE_VERSION_QUERY = gql`
389
391
  implementation_count
390
392
  data_structure_link_count
391
393
 
394
+ has_note
392
395
  note
393
396
  profile {
394
397
  max
@@ -442,6 +445,7 @@ export const DATA_STRUCTURE_VERSION_QUERY = gql`
442
445
  total_count
443
446
  unique_count
444
447
  }
448
+ has_note
445
449
  note(select_fields: $note_fields)
446
450
  }
447
451
  relations {
@@ -72,7 +72,7 @@ exports[`<StructureFieldRow /> matches the latest snapshot 1`] = `
72
72
  class=""
73
73
  >
74
74
  <span
75
- class="structure.field.hasnote.false"
75
+ class="structure.field.hasnote.true"
76
76
  >
77
77
  No
78
78
  </span>
@@ -20,16 +20,14 @@ const linkToStructureDecorator = ({ data_structure_id: id, alias, name }) => (
20
20
  <Link to={linkTo.STRUCTURE({ id })}>{_.defaultTo(name)(alias)}</Link>
21
21
  );
22
22
 
23
- const hasNoteDecorator = ({ note }) =>
24
- _.isNull(note) ||
25
- _.isEmpty(note) ||
26
- (note.hasOwnProperty("has_note") && !note.has_note) ? (
23
+ const hasNoteDecorator = ({ has_note }) =>
24
+ has_note ? (
27
25
  <span className="structure.field.hasnote.false">
28
- {translateDecorator("structure.field.hasnote.false")}
26
+ {translateDecorator("structure.field.hasnote.true")}
29
27
  </span>
30
28
  ) : (
31
29
  <span className="structure.field.hasnote.true">
32
- {translateDecorator("structure.field.hasnote.true")}
30
+ {translateDecorator("structure.field.hasnote.false")}
33
31
  </span>
34
32
  );
35
33
 
@@ -93,7 +91,7 @@ export const defaultStructureFieldColumns = [
93
91
  },
94
92
  {
95
93
  name: "note",
96
- fieldSelector: _.pick(["note"]),
94
+ fieldSelector: _.pick(["has_note"]),
97
95
  fieldDecorator: hasNoteDecorator,
98
96
  },
99
97
  ];