@elyra/canvas 12.10.2 → 12.11.2

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.
Files changed (205) hide show
  1. package/dist/canvas-constants-7f93e705.js +2 -0
  2. package/dist/canvas-constants-7f93e705.js.map +1 -0
  3. package/dist/canvas-constants-ac5daafb.js +2 -0
  4. package/dist/canvas-constants-ac5daafb.js.map +1 -0
  5. package/dist/canvas-controller-190542a6.js +2 -0
  6. package/dist/canvas-controller-190542a6.js.map +1 -0
  7. package/dist/canvas-controller-cbee8dd7.js +2 -0
  8. package/dist/canvas-controller-cbee8dd7.js.map +1 -0
  9. package/dist/canvas-logger-815781bb.js +2 -0
  10. package/dist/canvas-logger-815781bb.js.map +1 -0
  11. package/dist/canvas-logger-a0f1beaa.js +2 -0
  12. package/dist/canvas-logger-a0f1beaa.js.map +1 -0
  13. package/dist/common-canvas-8d2ddc6b.js +2 -0
  14. package/dist/common-canvas-8d2ddc6b.js.map +1 -0
  15. package/dist/common-canvas-e0a57cdb.js +2 -0
  16. package/dist/common-canvas-e0a57cdb.js.map +1 -0
  17. package/dist/common-canvas.es.js +1 -1
  18. package/dist/common-canvas.es.js.map +1 -1
  19. package/dist/common-canvas.js +1 -1
  20. package/dist/common-canvas.js.map +1 -1
  21. package/dist/common-properties-09ec10eb.js +2 -0
  22. package/dist/common-properties-09ec10eb.js.map +1 -0
  23. package/dist/common-properties-f1b96e0f.js +2 -0
  24. package/dist/common-properties-f1b96e0f.js.map +1 -0
  25. package/dist/datarecord-metadata-v3-schema-bda88f2e.js +2 -0
  26. package/dist/datarecord-metadata-v3-schema-bda88f2e.js.map +1 -0
  27. package/dist/datarecord-metadata-v3-schema-d7ad05cd.js +2 -0
  28. package/dist/datarecord-metadata-v3-schema-d7ad05cd.js.map +1 -0
  29. package/dist/en-2ed89528.js +2 -0
  30. package/dist/en-2ed89528.js.map +1 -0
  31. package/dist/en-e93855cc.js +2 -0
  32. package/dist/en-e93855cc.js.map +1 -0
  33. package/dist/extends-39f57612.js +7 -0
  34. package/dist/extends-39f57612.js.map +1 -0
  35. package/dist/extends-51d9ddcc.js +7 -0
  36. package/dist/extends-51d9ddcc.js.map +1 -0
  37. package/dist/flexible-table-154a3359.js +2 -0
  38. package/dist/flexible-table-154a3359.js.map +1 -0
  39. package/dist/flexible-table-5e4a1e6d.js +2 -0
  40. package/dist/flexible-table-5e4a1e6d.js.map +1 -0
  41. package/dist/icon-811ffddd.js +2 -0
  42. package/dist/icon-811ffddd.js.map +1 -0
  43. package/dist/icon-d6909a68.js +2 -0
  44. package/dist/icon-d6909a68.js.map +1 -0
  45. package/dist/index-4fd90a14.js +2 -0
  46. package/dist/index-4fd90a14.js.map +1 -0
  47. package/dist/index-6d138021.js +2 -0
  48. package/dist/index-6d138021.js.map +1 -0
  49. package/dist/isArrayLikeObject-31e5e646.js +2 -0
  50. package/dist/isArrayLikeObject-31e5e646.js.map +1 -0
  51. package/dist/isArrayLikeObject-7c33c7fd.js +2 -0
  52. package/dist/isArrayLikeObject-7c33c7fd.js.map +1 -0
  53. package/dist/lib/canvas-controller.es.js +1 -1
  54. package/dist/lib/canvas-controller.js +1 -1
  55. package/dist/lib/canvas.es.js +1 -1
  56. package/dist/lib/canvas.js +1 -1
  57. package/dist/lib/context-menu.es.js +1 -1
  58. package/dist/lib/context-menu.es.js.map +1 -1
  59. package/dist/lib/context-menu.js +1 -1
  60. package/dist/lib/context-menu.js.map +1 -1
  61. package/dist/lib/properties/field-picker.es.js +1 -1
  62. package/dist/lib/properties/field-picker.js +1 -1
  63. package/dist/lib/properties/flexible-table.es.js +1 -1
  64. package/dist/lib/properties/flexible-table.js +1 -1
  65. package/dist/lib/properties.es.js +1 -1
  66. package/dist/lib/properties.js +1 -1
  67. package/dist/lib/tooltip.es.js +1 -1
  68. package/dist/lib/tooltip.es.js.map +1 -1
  69. package/dist/lib/tooltip.js +1 -1
  70. package/dist/lib/tooltip.js.map +1 -1
  71. package/dist/styles/common-canvas.min.css +1 -1
  72. package/dist/styles/common-canvas.min.css.map +1 -1
  73. package/dist/toolbar-335252dd.js +2 -0
  74. package/dist/toolbar-335252dd.js.map +1 -0
  75. package/dist/toolbar-85e6c77b.js +2 -0
  76. package/dist/toolbar-85e6c77b.js.map +1 -0
  77. package/locales/command-actions/locales/en.json +7 -1
  78. package/locales/command-actions/locales/eo.json +7 -1
  79. package/locales/command-actions/locales/index.js +3 -1
  80. package/locales/command-actions/locales/ko.json +9 -0
  81. package/locales/common-canvas/locales/en.json +3 -0
  82. package/locales/common-canvas/locales/eo.json +3 -0
  83. package/locales/common-canvas/locales/index.js +3 -1
  84. package/locales/common-canvas/locales/ko.json +32 -0
  85. package/locales/common-properties/locales/index.js +3 -1
  86. package/locales/common-properties/locales/ko.json +93 -0
  87. package/locales/palette/locales/index.js +3 -1
  88. package/locales/palette/locales/ko.json +10 -0
  89. package/locales/toolbar/locales/index.js +3 -1
  90. package/locales/toolbar/locales/ko.json +8 -0
  91. package/package.json +2 -1
  92. package/src/color-picker/color-picker-panel.jsx +61 -0
  93. package/src/color-picker/color-picker.jsx +37 -0
  94. package/src/color-picker/color-picker.scss +46 -0
  95. package/src/command-actions/colorSelectedObjectsAction.js +72 -0
  96. package/src/command-actions/deleteObjectsAction.js +16 -11
  97. package/src/command-actions/pasteAction.js +50 -21
  98. package/src/common-canvas/canvas-controller.js +32 -5
  99. package/src/common-canvas/cc-bottom-panel.jsx +15 -9
  100. package/src/common-canvas/cc-contents.jsx +115 -8
  101. package/src/common-canvas/cc-toolbar.jsx +7 -6
  102. package/src/common-canvas/common-canvas-utils.js +73 -90
  103. package/src/common-canvas/common-canvas.scss +5 -5
  104. package/src/common-canvas/constants/canvas-constants.js +17 -16
  105. package/src/common-canvas/label-util.js +1 -1
  106. package/src/common-canvas/svg-canvas-d3.js +20 -107
  107. package/src/common-canvas/svg-canvas-d3.scss +66 -4
  108. package/src/common-canvas/svg-canvas-pipeline.js +201 -0
  109. package/src/common-canvas/svg-canvas-renderer.js +325 -339
  110. package/src/common-canvas/svg-canvas-utils-links.js +3 -3
  111. package/src/common-canvas/svg-canvas-utils-nodes.js +22 -44
  112. package/src/common-properties/actions.js +4 -0
  113. package/src/common-properties/components/field-picker/field-picker.jsx +33 -36
  114. package/src/common-properties/components/field-picker/field-picker.scss +20 -23
  115. package/src/common-properties/components/flexible-table/flexible-table.jsx +46 -31
  116. package/src/common-properties/components/flexible-table/flexible-table.scss +14 -17
  117. package/src/common-properties/components/properties-buttons/properties-buttons.jsx +28 -21
  118. package/src/common-properties/components/table-buttons/table-buttons.jsx +3 -1
  119. package/src/common-properties/components/table-buttons/table-buttons.scss +8 -8
  120. package/src/common-properties/components/title-editor/title-editor.jsx +31 -4
  121. package/src/common-properties/components/title-editor/title-editor.scss +30 -5
  122. package/src/common-properties/components/virtualized-table/virtualized-table.jsx +119 -27
  123. package/src/common-properties/components/virtualized-table/virtualized-table.scss +72 -8
  124. package/src/common-properties/constants/constants.js +5 -1
  125. package/src/common-properties/constants/form-constants.js +1 -0
  126. package/src/common-properties/controls/abstract-table.jsx +12 -11
  127. package/src/common-properties/controls/abstract-table.scss +6 -2
  128. package/src/common-properties/controls/dropdown/dropdown.scss +4 -0
  129. package/src/common-properties/controls/expression/expression-builder/expression-select-field-function.jsx +2 -2
  130. package/src/common-properties/controls/expression/expression.scss +1 -1
  131. package/src/common-properties/controls/passwordfield/passwordfield.jsx +2 -2
  132. package/src/common-properties/controls/readonlytable/readonlytable.jsx +4 -2
  133. package/src/common-properties/controls/selectcolumns/selectcolumns.scss +0 -19
  134. package/src/common-properties/controls/someofselect/someofselect.scss +2 -2
  135. package/src/common-properties/form/ControlInfo.js +8 -0
  136. package/src/common-properties/form/EditorForm.js +4 -0
  137. package/src/common-properties/form/ParameterInfo.js +4 -0
  138. package/src/common-properties/panels/sub-panel/cell.jsx +18 -23
  139. package/src/common-properties/panels/sub-panel/sub-panel.scss +5 -22
  140. package/src/common-properties/properties-controller.js +18 -0
  141. package/src/common-properties/properties-main/properties-main.jsx +15 -9
  142. package/src/common-properties/properties-main/properties-main.scss +9 -2
  143. package/src/common-properties/properties-store.js +27 -1
  144. package/src/common-properties/reducers/properties-settings.js +17 -1
  145. package/src/context-menu/common-context-menu.jsx +74 -29
  146. package/src/context-menu/context-menu-wrapper.jsx +2 -2
  147. package/src/icons/icon.jsx +5 -46
  148. package/src/index.scss +1 -0
  149. package/src/object-model/api-pipeline.js +18 -7
  150. package/src/object-model/object-model.js +27 -3
  151. package/src/object-model/redux/reducers/canvasinfo.js +36 -0
  152. package/src/object-model/redux/reducers/comments.js +58 -10
  153. package/src/object-model/redux/reducers/externalpipelineflows.js +1 -0
  154. package/src/object-model/redux/reducers/links.js +9 -7
  155. package/src/object-model/redux/reducers/selectioninfo.js +2 -1
  156. package/src/palette/palette-content-list-item.jsx +8 -1
  157. package/src/palette/palette-dialog-content-grid-node.jsx +8 -1
  158. package/src/toolbar/toolbar-action-item.jsx +75 -11
  159. package/src/toolbar/toolbar-overflow-item.jsx +2 -3
  160. package/src/tooltip/tooltip.jsx +4 -1
  161. package/stats.html +1 -1
  162. package/dist/canvas-constants-af93267a.js +0 -2
  163. package/dist/canvas-constants-af93267a.js.map +0 -1
  164. package/dist/canvas-constants-ffce3b78.js +0 -2
  165. package/dist/canvas-constants-ffce3b78.js.map +0 -1
  166. package/dist/canvas-controller-3f67c4fb.js +0 -2
  167. package/dist/canvas-controller-3f67c4fb.js.map +0 -1
  168. package/dist/canvas-controller-cee447d2.js +0 -2
  169. package/dist/canvas-controller-cee447d2.js.map +0 -1
  170. package/dist/common-canvas-e212a9c1.js +0 -2
  171. package/dist/common-canvas-e212a9c1.js.map +0 -1
  172. package/dist/common-canvas-e98191b3.js +0 -2
  173. package/dist/common-canvas-e98191b3.js.map +0 -1
  174. package/dist/common-properties-653e50e3.js +0 -2
  175. package/dist/common-properties-653e50e3.js.map +0 -1
  176. package/dist/common-properties-e2c6def7.js +0 -2
  177. package/dist/common-properties-e2c6def7.js.map +0 -1
  178. package/dist/datarecord-metadata-v3-schema-10ddafaf.js +0 -2
  179. package/dist/datarecord-metadata-v3-schema-10ddafaf.js.map +0 -1
  180. package/dist/datarecord-metadata-v3-schema-1504c843.js +0 -2
  181. package/dist/datarecord-metadata-v3-schema-1504c843.js.map +0 -1
  182. package/dist/en-517f38fc.js +0 -2
  183. package/dist/en-517f38fc.js.map +0 -1
  184. package/dist/en-dc6f2e9f.js +0 -2
  185. package/dist/en-dc6f2e9f.js.map +0 -1
  186. package/dist/extends-5a45f92e.js +0 -7
  187. package/dist/extends-5a45f92e.js.map +0 -1
  188. package/dist/extends-a52336ca.js +0 -8
  189. package/dist/extends-a52336ca.js.map +0 -1
  190. package/dist/flexible-table-e6ccbe58.js +0 -2
  191. package/dist/flexible-table-e6ccbe58.js.map +0 -1
  192. package/dist/flexible-table-f60c1680.js +0 -2
  193. package/dist/flexible-table-f60c1680.js.map +0 -1
  194. package/dist/index-567978da.js +0 -2
  195. package/dist/index-567978da.js.map +0 -1
  196. package/dist/index-59486e9a.js +0 -2
  197. package/dist/index-59486e9a.js.map +0 -1
  198. package/dist/isEmpty-def8f509.js +0 -2
  199. package/dist/isEmpty-def8f509.js.map +0 -1
  200. package/dist/isEmpty-e171b734.js +0 -2
  201. package/dist/isEmpty-e171b734.js.map +0 -1
  202. package/dist/toolbar-404bf690.js +0 -2
  203. package/dist/toolbar-404bf690.js.map +0 -1
  204. package/dist/toolbar-611d8ab9.js +0 -2
  205. package/dist/toolbar-611d8ab9.js.map +0 -1
@@ -23,14 +23,11 @@ import TableButtons from "./../components/table-buttons";
23
23
  import SubPanelCell from "./../panels/sub-panel/cell.jsx";
24
24
  import ReadonlyControl from "./readonly";
25
25
  import * as PropertyUtils from "./../util/property-utils";
26
- import Icon from "./../../icons/icon.jsx";
27
26
  import classNames from "classnames";
28
27
  import { Add16, TrashCan16, Edit16 } from "@carbon/icons-react";
29
28
  import { ControlType, EditStyle } from "./../constants/form-constants";
30
29
 
31
- import { MESSAGE_KEYS, STATES,
32
- TABLE_SUBPANEL_BUTTON_WIDTH, SORT_DIRECTION,
33
- ROW_SELECTION, CARBON_ICONS } from "./../constants/constants";
30
+ import { MESSAGE_KEYS, STATES, TABLE_SUBPANEL_BUTTON_WIDTH, SORT_DIRECTION, ROW_SELECTION } from "./../constants/constants";
34
31
 
35
32
  import { isEqual, findIndex, sortBy, cloneDeep } from "lodash";
36
33
 
@@ -366,7 +363,8 @@ export default class AbstractTable extends React.Component {
366
363
  width: columnDef.width,
367
364
  content: cellContent,
368
365
  className: cellClassName,
369
- value: this.props.controller.getPropertyValue(propertyId)
366
+ value: this.props.controller.getPropertyValue(propertyId),
367
+ resizable: columnDef.resizable
370
368
  };
371
369
  }
372
370
  _getCustomCtrlContent(propertyId, columnDef, defaultContent, tableInfo) {
@@ -632,12 +630,14 @@ export default class AbstractTable extends React.Component {
632
630
  const selectedEditRow = this.props.control.rowSelection === ROW_SELECTION.MULTIPLE
633
631
  ? this.makeSelectedEditRow(this.props.selectedRows)
634
632
  : null;
635
-
636
633
  let topRightPanel = <div />;
637
634
  if (customButtons) {
638
635
  topRightPanel = this.makeCustomButtonsPanel(tableState, customButtons);
639
636
  } else if (this.isReadonlyTable()) {
640
- topRightPanel = this.makeEditButtonPanel(tableState, tableButtonConfig);
637
+ if (!this.props.hideEditButton) {
638
+ topRightPanel = this.makeEditButtonPanel(tableState, tableButtonConfig);
639
+ }
640
+
641
641
  } else if (this.props.addRemoveRows) {
642
642
  topRightPanel = this.makeAddRemoveButtonPanel(tableState, tableButtonConfig);
643
643
  }
@@ -711,6 +711,7 @@ export default class AbstractTable extends React.Component {
711
711
  "label": columnLabel,
712
712
  "width": columnDef.width,
713
713
  "description": (columnDef.description ? columnDef.description.text : null),
714
+ "resizable": columnDef.resizable ? columnDef.resizable : false,
714
715
  "operation": (columnDef.generatedValues && columnDef.generatedValues.operation ? columnDef.generatedValues.operation : null) });
715
716
  if (columnDef.filterable) {
716
717
  filterFields.push(columnDef.name);
@@ -771,7 +772,6 @@ export default class AbstractTable extends React.Component {
771
772
  }
772
773
 
773
774
  const subItemButton = this.props.buildUIItem(rowIndex, this.props.control.childItem, propertyId, this.indexOfColumn);
774
- const settingsIcon = <Icon type={CARBON_ICONS.SETTINGS} />;
775
775
  // Hack to decompose the button into our own in-table link
776
776
  const subCell = (
777
777
  <div className="properties-table-subcell">
@@ -779,7 +779,6 @@ export default class AbstractTable extends React.Component {
779
779
  label={subItemButton.props.label}
780
780
  title={subItemButton.props.title}
781
781
  panel={subItemButton.props.panel}
782
- buttonIcon={settingsIcon}
783
782
  disabled={tableState === STATES.DISABLED}
784
783
  controller={this.props.controller}
785
784
  propertyId={this.props.propertyId}
@@ -804,9 +803,11 @@ AbstractTable.propTypes = {
804
803
  value: PropTypes.array, // pass in by redux
805
804
  selectedRows: PropTypes.array, // set by redux
806
805
  addRemoveRows: PropTypes.bool, // set by redux
807
- tableButtons: PropTypes.object // set in by redux
806
+ tableButtons: PropTypes.object, // set in by redux
807
+ hideEditButton: PropTypes.bool // set by redux
808
808
  };
809
809
 
810
810
  AbstractTable.defaultProps = {
811
- addRemoveRows: true
811
+ addRemoveRows: true,
812
+ hideEditButton: false,
812
813
  };
@@ -16,7 +16,7 @@
16
16
 
17
17
  .properties-table-cell-control {
18
18
  >div>:first-child {
19
- margin-left: $spacing-04;
19
+ padding: 0 $spacing-05;
20
20
  }
21
21
  }
22
22
 
@@ -35,9 +35,13 @@
35
35
  color: $ui-01;
36
36
  }
37
37
 
38
+ .properties-ft-table-header {
39
+ display: none;
40
+ }
41
+
38
42
  // align summaryTable row
39
43
  .properties-vt-row-checkbox {
40
- margin-left: 0;
44
+ width: 1.25rem;
41
45
  }
42
46
 
43
47
  .properties-vt-row-class {
@@ -31,6 +31,9 @@
31
31
  .bx--select-input--inline__wrapper {
32
32
  width: 100%;
33
33
  }
34
+ svg {
35
+ right: 0;
36
+ }
34
37
  }
35
38
  .bx--select-input {
36
39
  width: inherit; // Override carbon default width: auto
@@ -43,6 +46,7 @@
43
46
  &:focus {
44
47
  outline: unset;
45
48
  }
49
+
46
50
  }
47
51
  &.error {
48
52
  .bx--select-input {
@@ -366,7 +366,7 @@ export default class ExpressionSelectFieldOrFunction extends React.Component {
366
366
  }
367
367
 
368
368
  if (categoryInfo) {
369
- fieldHeaders.push({ key: "fieldName", label: categoryInfo.field_columns.field_column_info.locLabel });
369
+ fieldHeaders.push({ key: "fieldName", label: categoryInfo.field_columns.field_column_info.locLabel, resizable: true });
370
370
  valueHeader.push({ key: "values", label: categoryInfo.field_columns.value_column_info.locLabel });
371
371
  if (categoryInfo.field_columns.additional_column_info) {
372
372
  for (let i = 0; i < categoryInfo.field_columns.additional_column_info.length; i++) {
@@ -572,7 +572,7 @@ export default class ExpressionSelectFieldOrFunction extends React.Component {
572
572
  MESSAGE_KEYS.EXPRESSION_RETURN_COLUMN);
573
573
 
574
574
 
575
- headers.push({ key: "function", label: functionColumn, width: 73 });
575
+ headers.push({ key: "function", label: functionColumn, width: 73, resizable: true });
576
576
  headers.push({ key: "return", label: returnColumn, width: 27 });
577
577
  const table = this._buildFunctionTable(this.state.functionCategory);
578
578
 
@@ -45,7 +45,7 @@
45
45
 
46
46
  .cm-s-custom .cm-number { color: $text-02; }
47
47
 
48
- .cm-s-custom .cm-def { color: $ui-01; }
48
+ .cm-s-custom .cm-def { color: $support-01; }
49
49
 
50
50
  .cm-s-custom .cm-variable,
51
51
  .cm-s-custom .cm-punctuation,
@@ -17,7 +17,7 @@
17
17
  import React from "react";
18
18
  import PropTypes from "prop-types";
19
19
  import { connect } from "react-redux";
20
- import { PasswordInput } from "carbon-components-react";
20
+ import { TextInput } from "carbon-components-react";
21
21
  import ValidationMessage from "./../../components/validation-message";
22
22
  import * as ControlUtils from "./../../util/control-utils";
23
23
  import { STATES } from "./../../constants/constants.js";
@@ -40,7 +40,7 @@ class PasswordControl extends React.Component {
40
40
  const validationProps = ControlUtils.getValidationProps(this.props.messageInfo, this.props.tableControl);
41
41
  return (
42
42
  <div className={className} data-id={ControlUtils.getDataId(this.props.propertyId)}>
43
- <PasswordInput
43
+ <TextInput.PasswordInput
44
44
  {...validationProps}
45
45
  autoComplete="off"
46
46
  id={this.id}
@@ -100,7 +100,8 @@ ReadonlyTableControl.propTypes = {
100
100
  value: PropTypes.array, // pass in by redux
101
101
  messageInfo: PropTypes.object, // pass in by redux
102
102
  addRemoveRows: PropTypes.bool, // set by redux
103
- tableButtons: PropTypes.object // set in by redux
103
+ tableButtons: PropTypes.object, // set in by redux
104
+ hideEditButton: PropTypes.bool // set by redux
104
105
  };
105
106
 
106
107
 
@@ -110,7 +111,8 @@ const mapStateToProps = (state, ownProps) => ({
110
111
  messageInfo: ownProps.controller.getErrorMessage(ownProps.propertyId),
111
112
  selectedRows: ownProps.controller.getSelectedRows(ownProps.propertyId),
112
113
  addRemoveRows: ownProps.controller.getAddRemoveRows(ownProps.propertyId),
113
- tableButtons: ownProps.controller.getTableButtons(ownProps.propertyId)
114
+ tableButtons: ownProps.controller.getTableButtons(ownProps.propertyId),
115
+ hideEditButton: ownProps.controller.getHideEditButton(ownProps.propertyId)
114
116
  });
115
117
 
116
118
  export default connect(mapStateToProps, null)(ReadonlyTableControl);
@@ -14,25 +14,6 @@
14
14
  * limitations under the License.
15
15
  */
16
16
 
17
- // overwrite flexible-table.scss: .flexible-table-container-absolute-noheader tr
18
17
  .properties-column-select {
19
- tbody > tr > td {
20
- padding: 8px 0;
21
- }
22
- }
23
-
24
- .column-select-table-row {
25
- font-weight: 500;
26
- color: $interactive-01;
27
- .row-checkbox {
28
- padding-left: 12px;
29
- }
30
- }
31
- //rebase-part
32
- .column-select-table-selected-row {
33
- background-color: $ui-03;
34
- }
35
18
 
36
- .properties-column-select .properties-ft-container-wrapper {
37
- height: 150px;
38
19
  }
@@ -34,7 +34,7 @@
34
34
  border: 1px solid $support-03;
35
35
  }
36
36
  }
37
- .table .bx--form-item.bx--checkbox-wrapper {
38
- margin: 5px 0 5px 5px;
37
+ .properties-vt-row-checkbox {
38
+ margin-right: 1rem;
39
39
  }
40
40
  }
@@ -59,6 +59,9 @@ export class Control {
59
59
  if (typeof settings.filterable === "boolean") {
60
60
  this.filterable = settings.filterable;
61
61
  }
62
+ if (typeof settings.resizable === "boolean") {
63
+ this.resizable = settings.resizable;
64
+ }
62
65
  if (settings.language) {
63
66
  this.language = settings.language;
64
67
  }
@@ -131,6 +134,11 @@ export class Control {
131
134
  if (typeof settings.addRemoveRows === "boolean") {
132
135
  this.addRemoveRows = settings.addRemoveRows;
133
136
  }
137
+
138
+ if (typeof settings.hideEditButton === "boolean") {
139
+ this.hideEditButton = settings.hideEditButton;
140
+ }
141
+
134
142
  if (typeof settings.header === "boolean") {
135
143
  this.header = settings.header;
136
144
  }
@@ -458,6 +458,9 @@ function _makeControl(parameterMetadata, paramName, group, structureDefinition,
458
458
  controlType = ControlType.TIMEFIELD;
459
459
  }
460
460
  break;
461
+ case Type.TIMESTAMP:
462
+ controlType = ControlType.TIMESTAMP;
463
+ break;
461
464
  case Type.STRUCTURE: {
462
465
  const structureDef = isSubControl ? structureMetadata.getStructure(parameter.baseType()) : structureDefinition;
463
466
 
@@ -565,6 +568,7 @@ function _makeControl(parameterMetadata, paramName, group, structureDefinition,
565
568
  settings.valueIcons = parameter.valueIcons;
566
569
  settings.sortable = parameter.sortable;
567
570
  settings.filterable = parameter.filterable;
571
+ settings.resizable = parameter.resizable;
568
572
  settings.charLimit = parameter.charLimit;
569
573
  settings.subControls = subControls;
570
574
  settings.keyIndex = keyIndex;
@@ -88,6 +88,9 @@ export class ParameterDef {
88
88
  if (toType(settings.filterable) === "boolean") {
89
89
  this.filterable = settings.filterable;
90
90
  }
91
+ if (toType(settings.resizable) === "boolean") {
92
+ this.resizable = settings.resizable;
93
+ }
91
94
  if (settings.editStyle) {
92
95
  this.editStyle = settings.editStyle;
93
96
  }
@@ -329,6 +332,7 @@ export class ParameterDef {
329
332
  "valueIcons": propertyOf(uihint)("value_icons"),
330
333
  "sortable": propertyOf(uihint)("sortable"),
331
334
  "filterable": propertyOf(uihint)("filterable"),
335
+ "resizable": propertyOf(uihint)("resizable"),
332
336
  "editStyle": propertyOf(uihint)("edit_style"),
333
337
  "required": propertyOf(param)("required"),
334
338
  "numberGenerator": propertyOf(uihint)("number_generator"),
@@ -17,6 +17,7 @@
17
17
  import React from "react";
18
18
  import PropTypes from "prop-types";
19
19
  import { Button } from "carbon-components-react";
20
+ import { Settings16 } from "@carbon/icons-react";
20
21
  import { v4 as uuid4 } from "uuid";
21
22
  import { formatMessage } from "./../../util/property-utils";
22
23
  import Tooltip from "./../../../tooltip/tooltip.jsx";
@@ -58,7 +59,6 @@ export default class SubPanelCell extends React.Component {
58
59
  MESSAGE_KEYS.SUBPANEL_BUTTON_TOOLTIP);
59
60
  const applyLabel = formatMessage(this.props.controller.getReactIntl(), MESSAGE_KEYS.APPLYBUTTON_LABEL);
60
61
  const rejectLabel = formatMessage(this.props.controller.getReactIntl(), MESSAGE_KEYS.REJECTBUTTON_LABEL);
61
- const innerObject = this.props.buttonIcon ? this.props.buttonIcon : this.props.label || "";
62
62
  return (
63
63
 
64
64
  <SubPanelInvoker ref={ (ref) => (this.subPanelInvoker = ref) }
@@ -67,26 +67,22 @@ export default class SubPanelCell extends React.Component {
67
67
  rejectLabel={rejectLabel}
68
68
  controller={this.props.controller}
69
69
  >
70
- <div>
71
- <Tooltip
72
- id={uuid4() + "-" + tooltipId}
73
- tip={subPanelToolTip}
74
- direction="left"
75
- className="properties-tooltips icon-tooltip"
76
- >
77
- <Button
78
- className="properties-subpanel-button"
79
- type="button"
80
- size="small"
81
- kind="secondary"
82
- onClick={this.showSubPanel}
83
- disabled={disabled}
84
- aria-label={subPanelToolTip}
85
- >
86
- {innerObject}
87
- </Button>
88
- </Tooltip>
89
- </div>
70
+ <Tooltip
71
+ id={uuid4() + "-" + tooltipId}
72
+ tip={subPanelToolTip}
73
+ direction="left"
74
+ className="properties-tooltips icon-tooltip"
75
+ >
76
+ <Button
77
+ className="properties-subpanel-button"
78
+ kind="ghost"
79
+ renderIcon={Settings16}
80
+ onClick={this.showSubPanel}
81
+ disabled={disabled}
82
+ iconDescription={subPanelToolTip}
83
+ hasIconOnly
84
+ />
85
+ </Tooltip>
90
86
  </SubPanelInvoker>
91
87
  );
92
88
  }
@@ -99,6 +95,5 @@ SubPanelCell.propTypes = {
99
95
  disabled: PropTypes.bool,
100
96
  controller: PropTypes.object.isRequired,
101
97
  propertyId: PropTypes.object,
102
- rightFlyout: PropTypes.bool,
103
- buttonIcon: PropTypes.object
98
+ rightFlyout: PropTypes.bool
104
99
  };
@@ -15,27 +15,10 @@
15
15
  */
16
16
 
17
17
  button.properties-subpanel-button {
18
- cursor: pointer;
19
- height: 100%;
20
- align-items: center;
18
+ padding: 0; // override carbon
19
+ min-height: 2rem; // override carbon
20
+ height: 2rem;
21
+ width: 2rem;
21
22
  display: flex;
22
- border: 0;
23
- border-style: none;
24
- padding: 0;
25
- background: unset;
26
- > svg {
27
- width: 18px;
28
- height: 18px;
29
- fill: $interactive-01;
30
- }
31
- &:hover:not([disabled]) > svg {
32
- fill: $hover-primary;
33
- }
34
- &[disabled] {
35
- cursor: default;
36
- background: unset;
37
- }
38
- &:focus, &:hover {
39
- background-color: transparent;
40
- }
23
+ justify-content: center;
41
24
  }
@@ -1797,6 +1797,24 @@ export default class PropertiesController {
1797
1797
  return this.propertiesStore.getAddRemoveRows(propertyId);
1798
1798
  }
1799
1799
 
1800
+ /**
1801
+ * Set the hideEditButton attribute to 'enabled' for the given propertyId
1802
+ * @param propertyId The unique property identifier
1803
+ * @param enabled boolean value to enable or disable hideditButton
1804
+ */
1805
+ setHideEditButton(propertyId, enabled) {
1806
+ this.propertiesStore.setHideEditButton(propertyId, enabled);
1807
+ }
1808
+
1809
+ /**
1810
+ * Returns the true if hideEditButton is enabled for the given propertyID
1811
+ * @param propertyId The unique property identifier
1812
+ * @return boolean
1813
+ */
1814
+ getHideEditButton(propertyId) {
1815
+ return this.propertiesStore.getHideEditButton(propertyId);
1816
+ }
1817
+
1800
1818
  /**
1801
1819
  * Freeze row move buttons for row indexes in given array
1802
1820
  * @param propertyId The unique property identifier
@@ -168,10 +168,6 @@ class PropertiesMain extends React.Component {
168
168
  if (this.props.propertiesConfig.buttonLabels && this.props.propertiesConfig.buttonLabels.primary) {
169
169
  return this.props.propertiesConfig.buttonLabels.primary;
170
170
  }
171
- // Update apply button text to `Close` when applyOnBlur
172
- if (this.props.propertiesConfig.applyOnBlur && this.props.propertiesConfig.rightFlyout) {
173
- return PropertyUtils.formatMessage(this.props.intl, MESSAGE_KEYS.PROPERTIESEDIT_CLOSEBUTTON_LABEL);
174
- }
175
171
  return PropertyUtils.formatMessage(this.props.intl, MESSAGE_KEYS.PROPERTIESEDIT_APPLYBUTTON_LABEL);
176
172
  }
177
173
 
@@ -408,9 +404,10 @@ class PropertiesMain extends React.Component {
408
404
  }
409
405
 
410
406
  render() {
407
+ const applyOnBlurEnabled = this.props.propertiesConfig.applyOnBlur && this.props.propertiesConfig.rightFlyout;
411
408
  let cancelHandler = this.cancelHandler.bind(this, CANCEL);
412
409
  // when onBlur cancel shouldn't be rendered.
413
- if (this.props.propertiesConfig.applyOnBlur && this.props.propertiesConfig.rightFlyout) {
410
+ if (applyOnBlurEnabled) {
414
411
  cancelHandler = null;
415
412
  }
416
413
  const applyLabel = this.getApplyButtonLabel();
@@ -430,6 +427,7 @@ class PropertiesMain extends React.Component {
430
427
  help={formData.help}
431
428
  controller={this.propertiesController}
432
429
  helpClickHandler={this.props.callbacks.helpClickHandler}
430
+ closeHandler={applyOnBlurEnabled ? this.applyPropertiesEditing.bind(this, true) : null}
433
431
  icon={formData.icon}
434
432
  heading={formData.heading}
435
433
  showHeading={this.props.propertiesConfig.heading}
@@ -439,7 +437,7 @@ class PropertiesMain extends React.Component {
439
437
 
440
438
  buttonsContainer = (<MainEditorPropertiesButtons
441
439
  controller={this.propertiesController}
442
- okHandler={this.applyPropertiesEditing.bind(this, true)}
440
+ okHandler={!applyOnBlurEnabled ? this.applyPropertiesEditing.bind(this, true) : null}
443
441
  cancelHandler={cancelHandler}
444
442
  applyLabel={applyLabel}
445
443
  rejectLabel={rejectLabel}
@@ -482,9 +480,17 @@ class PropertiesMain extends React.Component {
482
480
  {editorForm}
483
481
  </PropertiesEditor>);
484
482
  } else if (this.props.propertiesConfig.containerType === "Custom") {
485
- propertiesDialog = (<div className={classNames("properties-custom-container", { "properties-custom-container-with-heading": hasHeading })}>
486
- {editorForm}
487
- </div>);
483
+ propertiesDialog = (
484
+ <div className={classNames("properties-custom-container",
485
+ {
486
+ "properties-custom-container-with-heading": !applyOnBlurEnabled && hasHeading,
487
+ "properties-custom-container-applyOnBlur": applyOnBlurEnabled && !hasHeading,
488
+ "properties-custom-container-applyOnBlur-with-heading": applyOnBlurEnabled && hasHeading
489
+ }
490
+ )}
491
+ >
492
+ {editorForm}
493
+ </div>);
488
494
  } else { // Modal
489
495
  propertiesDialog = (<PropertiesModal
490
496
  onHide={this.props.callbacks.closePropertiesDialog}
@@ -15,6 +15,7 @@
15
15
  */
16
16
 
17
17
  @import "./properties-main-widths.scss";
18
+ $properties-modal-buttons-height: $spacing-10;
18
19
 
19
20
  .properties-right-flyout {
20
21
  // Set the font explicitly to 14px to shrink them across the entire properties editor
@@ -67,11 +68,17 @@
67
68
 
68
69
 
69
70
  .properties-right-flyout > .properties-custom-container {
70
- height: calc(100% - 136px);
71
+ height: calc(100% - 65px - #{$properties-modal-buttons-height}); // Properties title - 65px
71
72
  overflow-y: auto;
72
73
  transform: translateZ(0); // https://github.com/elyra-ai/canvas/issues/160
73
74
  &.properties-custom-container-with-heading {
74
- height: calc(100% - 160px);
75
+ height: calc(100% - 89px - #{$properties-modal-buttons-height}); // Properties title - 89px
76
+ }
77
+ &.properties-custom-container-applyOnBlur {
78
+ height: calc(100% - #{$spacing-12}); // Properties title - 97px
79
+ }
80
+ &.properties-custom-container-applyOnBlur-with-heading {
81
+ height: calc(100% - 89px); // Properties title - 89px
75
82
  }
76
83
  }
77
84
 
@@ -25,7 +25,7 @@ import { setActionStates, updateActionState } from "./actions";
25
25
  import { clearSelectedRows, updateSelectedRows, disableRowMoveButtons } from "./actions";
26
26
  import { clearStaticRows, updateStaticRows } from "./actions";
27
27
  import { setErrorMessages, updateErrorMessage, clearErrorMessage } from "./actions";
28
- import { setDatasetMetadata, setSaveButtonDisable, setAddRemoveRows, setTableButtonEnabled } from "./actions";
28
+ import { setDatasetMetadata, setSaveButtonDisable, setAddRemoveRows, setTableButtonEnabled, setHideEditButton } from "./actions";
29
29
  import { setTitle, setActiveTab } from "./actions";
30
30
  import propertiesReducer from "./reducers/properties";
31
31
  import controlStatesReducer from "./reducers/control-states";
@@ -494,6 +494,32 @@ export default class PropertiesStore {
494
494
  }
495
495
  return defaultValue;
496
496
  }
497
+
498
+ /**
499
+ * Set the hideEditButton attribute to 'true' for the given propertyId
500
+ * @param propertyId The unique property identifier
501
+ * @param enabled boolean value for disable or enable edit button by state hideEditButton
502
+ */
503
+ setHideEditButton(propertyId, enabled) {
504
+ this.store.dispatch(setHideEditButton({ propertyId: propertyId, value: enabled }));
505
+ }
506
+
507
+ /**
508
+ * Returns true if hideEditButton is true for the given propertyID
509
+ * @param propertyId The unique property identifier
510
+ * @return boolean
511
+ */
512
+ getHideEditButton(propertyId) {
513
+ const state = this.store.getState();
514
+ const defaultValue = false; // Default to false to show disable edit buttons
515
+ if (state.propertiesSettingsReducer[propertyId.name]) {
516
+ if (typeof propertyId.row !== "undefined") {
517
+ return getNestedPropertySetting(propertyId, state.propertiesSettingsReducer[propertyId.name], "hideEditButton", defaultValue);
518
+ }
519
+ return state.propertiesSettingsReducer[propertyId.name].hideEditButton;
520
+ }
521
+ return defaultValue;
522
+ }
497
523
  }
498
524
 
499
525
  function getNestedPropertySetting(propertyId, state, setting, defaultValue) {
@@ -15,7 +15,7 @@
15
15
  */
16
16
 
17
17
  import { set } from "lodash";
18
- import { SET_ADD_REMOVE_ROWS, SET_TABLE_BUTTON_ENABLED } from "../actions";
18
+ import { SET_ADD_REMOVE_ROWS, SET_TABLE_BUTTON_ENABLED, SET_HIDE_EDIT_BUTTON } from "../actions";
19
19
 
20
20
  /*
21
21
  * Stores the state information for all controls. States are stored as objects with keys being name, row, col.
@@ -56,6 +56,22 @@ function states(state = {}, action) {
56
56
  }
57
57
  return Object.assign({}, state, newState);
58
58
  }
59
+ case SET_HIDE_EDIT_BUTTON: {
60
+ if (propertyId === null) {
61
+ return state;
62
+ }
63
+ const newState = state;
64
+ if (typeof newState[propertyId.name] === "undefined") {
65
+ newState[propertyId.name] = {};
66
+ }
67
+
68
+ if (typeof propertyId.row !== "undefined") {
69
+ updateNestedPropertySetting(propertyId, newState[propertyId.name], "hideEditButton", action.info.value);
70
+ } else {
71
+ newState[propertyId.name].hideEditButton = action.info.value;
72
+ }
73
+ return Object.assign({}, state, newState);
74
+ }
59
75
  default: {
60
76
  return state;
61
77
  }