@elyra/canvas 13.0.0-alpha.1 → 13.0.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/build.sh +6 -2
- package/dist/{canvas-controller-488d8e7b.js → canvas-controller-13afbf7b.js} +2 -2
- package/dist/{canvas-controller-866bf117.js.map → canvas-controller-13afbf7b.js.map} +1 -1
- package/dist/{canvas-controller-866bf117.js → canvas-controller-bf9c0dd2.js} +2 -2
- package/dist/{canvas-controller-488d8e7b.js.map → canvas-controller-bf9c0dd2.js.map} +1 -1
- package/dist/common-canvas-bbc57d20.js +2 -0
- package/dist/common-canvas-bbc57d20.js.map +1 -0
- package/dist/common-canvas-ef71be09.js +2 -0
- package/dist/common-canvas-ef71be09.js.map +1 -0
- package/dist/common-canvas.es.js +1 -1
- package/dist/common-canvas.js +1 -1
- package/dist/common-properties-ddfc6e24.js +2 -0
- package/dist/common-properties-ddfc6e24.js.map +1 -0
- package/dist/common-properties-e64e7304.js +2 -0
- package/dist/common-properties-e64e7304.js.map +1 -0
- package/dist/lib/canvas-controller.es.js +1 -1
- package/dist/lib/canvas-controller.js +1 -1
- package/dist/lib/canvas.es.js +1 -1
- package/dist/lib/canvas.js +1 -1
- package/dist/lib/command-stack.es.js +1 -1
- package/dist/lib/command-stack.es.js.map +1 -1
- package/dist/lib/command-stack.js +1 -1
- package/dist/lib/command-stack.js.map +1 -1
- package/dist/lib/properties.es.js +1 -1
- package/dist/lib/properties.js +1 -1
- package/dist/styles/common-canvas.min.css +1 -1
- package/dist/styles/common-canvas.min.css.map +1 -1
- package/dist/{toolbar-35db2f4c.js → toolbar-5417d781.js} +2 -2
- package/dist/{toolbar-35db2f4c.js.map → toolbar-5417d781.js.map} +1 -1
- package/dist/{toolbar-9b99500d.js → toolbar-bcb3055d.js} +2 -2
- package/dist/{toolbar-9b99500d.js.map → toolbar-bcb3055d.js.map} +1 -1
- package/package.json +1 -1
- package/src/command-stack/command-stack.js +4 -0
- package/src/common-canvas/canvas-controller.js +14 -6
- package/src/common-canvas/cc-context-toolbar.jsx +10 -3
- package/src/common-canvas/cc-toolbar.jsx +0 -3
- package/src/common-canvas/common-canvas.scss +0 -6
- package/src/common-canvas/svg-canvas-renderer.js +10 -2
- package/src/common-canvas/svg-canvas-utils-external.js +21 -10
- package/src/common-properties/components/editor-form/editor-form.jsx +33 -14
- package/src/common-properties/components/editor-form/editor-form.scss +42 -43
- package/src/common-properties/controls/control-factory.js +9 -2
- package/src/common-properties/controls/datefield/datefield.jsx +12 -14
- package/src/common-properties/controls/datepicker/datepicker.jsx +21 -23
- package/src/common-properties/controls/datepicker-range/datepicker-range.jsx +33 -35
- package/src/common-properties/controls/dropdown/dropdown.jsx +37 -43
- package/src/common-properties/controls/dropdown/dropdown.scss +1 -1
- package/src/common-properties/controls/multiselect/multiselect.jsx +23 -27
- package/src/common-properties/controls/numberfield/numberfield.jsx +16 -18
- package/src/common-properties/controls/passwordfield/passwordfield.jsx +15 -17
- package/src/common-properties/controls/radioset/radioset.jsx +11 -8
- package/src/common-properties/controls/radioset/radioset.scss +6 -14
- package/src/common-properties/controls/slider/slider.jsx +16 -18
- package/src/common-properties/controls/textarea/textarea.jsx +20 -24
- package/src/common-properties/controls/textfield/textfield.jsx +13 -15
- package/src/common-properties/controls/timefield/timefield.jsx +12 -14
- package/src/common-properties/form/ControlInfo.js +1 -1
- package/src/common-properties/panels/subtabs/subtabs.scss +4 -4
- package/src/toolbar/toolbar-action-item.jsx +38 -4
- package/src/toolbar/toolbar-button-item.jsx +38 -28
- package/src/toolbar/toolbar-overflow-item.jsx +27 -10
- package/src/toolbar/toolbar.jsx +22 -22
- package/src/toolbar/toolbar.scss +61 -11
- package/stats.html +1 -1
- package/dist/common-canvas-3ffaf6ca.js +0 -2
- package/dist/common-canvas-3ffaf6ca.js.map +0 -1
- package/dist/common-canvas-c1a57382.js +0 -2
- package/dist/common-canvas-c1a57382.js.map +0 -1
- package/dist/common-properties-3cce68e0.js +0 -2
- package/dist/common-properties-3cce68e0.js.map +0 -1
- package/dist/common-properties-5cac340d.js +0 -2
- package/dist/common-properties-5cac340d.js.map +0 -1
|
@@ -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 { DatePicker, DatePickerInput
|
|
20
|
+
import { DatePicker, DatePickerInput } from "@carbon/react";
|
|
21
21
|
import classNames from "classnames";
|
|
22
22
|
import { v4 as uuid4 } from "uuid";
|
|
23
23
|
|
|
@@ -135,40 +135,38 @@ class DatepickerRangeControl extends React.Component {
|
|
|
135
135
|
|
|
136
136
|
return (
|
|
137
137
|
<div className={className} data-id={ControlUtils.getDataId(this.props.propertyId)}>
|
|
138
|
-
<
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
</DatePicker>
|
|
171
|
-
</Layer>
|
|
138
|
+
<DatePicker
|
|
139
|
+
datePickerType={DATEPICKER_TYPE.RANGE}
|
|
140
|
+
dateFormat={this.dateFormat}
|
|
141
|
+
onChange={this.handleDateRangeChange.bind(this)}
|
|
142
|
+
locale={this.locale}
|
|
143
|
+
allowInput
|
|
144
|
+
>
|
|
145
|
+
<DatePickerInput
|
|
146
|
+
{...validationProps}
|
|
147
|
+
id={`${this.id}-start`}
|
|
148
|
+
placeholder={this.props.control.additionalText}
|
|
149
|
+
labelText={!this.props.tableControl && startLabel}
|
|
150
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
151
|
+
size={this.getDatepickerSize()}
|
|
152
|
+
onChange={this.handleInputStartChange.bind(this)}
|
|
153
|
+
value={this.state.valueStart}
|
|
154
|
+
onBlur={this.onStartBlur.bind(this)}
|
|
155
|
+
helperText={!this.props.tableControl && startHelperText}
|
|
156
|
+
/>
|
|
157
|
+
<DatePickerInput
|
|
158
|
+
{...validationProps}
|
|
159
|
+
id={`${this.id}-end`}
|
|
160
|
+
placeholder={this.props.control.additionalText}
|
|
161
|
+
labelText={!this.props.tableControl && endLabel}
|
|
162
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
163
|
+
size={this.getDatepickerSize()}
|
|
164
|
+
onChange={this.handleInputEndChange.bind(this)}
|
|
165
|
+
value={this.state.valueEnd}
|
|
166
|
+
onBlur={this.onEndBlur.bind(this)}
|
|
167
|
+
helperText={!this.props.tableControl && endHelperText}
|
|
168
|
+
/>
|
|
169
|
+
</DatePicker>
|
|
172
170
|
<ValidationMessage inTable={this.props.tableControl} tableOnly state={this.props.state} messageInfo={this.props.messageInfo} />
|
|
173
171
|
</div>
|
|
174
172
|
);
|
|
@@ -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 { SelectItem, Select, Dropdown, ComboBox
|
|
20
|
+
import { SelectItem, Select, Dropdown, ComboBox } from "@carbon/react";
|
|
21
21
|
import { isEqual, isEmpty } from "lodash";
|
|
22
22
|
import * as ControlUtils from "./../../util/control-utils";
|
|
23
23
|
import ValidationMessage from "./../../components/validation-message";
|
|
@@ -220,54 +220,48 @@ class DropDown extends React.Component {
|
|
|
220
220
|
options.push(<SelectItem text={option.label} key={this.id + "-" + option.value} value={option.value} />);
|
|
221
221
|
}
|
|
222
222
|
dropdownComponent = (
|
|
223
|
-
<
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
</Select>
|
|
235
|
-
</Layer>
|
|
223
|
+
<Select
|
|
224
|
+
id={this.id}
|
|
225
|
+
hideLabel
|
|
226
|
+
inline
|
|
227
|
+
labelText={this.props.control.label ? this.props.control.label.text : ""}
|
|
228
|
+
disabled={this.props.state === STATES.DISABLED || this.disableEmptyListDropdown}
|
|
229
|
+
onChange={this.handleChange}
|
|
230
|
+
value={selection}
|
|
231
|
+
>
|
|
232
|
+
{ options }
|
|
233
|
+
</Select>
|
|
236
234
|
);
|
|
237
235
|
} else if (this.props.control.customValueAllowed) { // combobox dropdown not allowed in tables
|
|
238
236
|
dropdownComponent = (
|
|
239
|
-
<
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
/>
|
|
253
|
-
</Layer>
|
|
237
|
+
<ComboBox
|
|
238
|
+
{...validationProps}
|
|
239
|
+
aria-label={this.props.control.label ? this.props.control.label.text : ""}
|
|
240
|
+
id={`${ControlUtils.getDataId(this.props.propertyId)}-dropdown`}
|
|
241
|
+
disabled={this.props.state === STATES.DISABLED || this.disableEmptyListDropdown}
|
|
242
|
+
placeholder={dropDown.selectedOption.label}
|
|
243
|
+
selectedItem={dropDown.selectedOption.label}
|
|
244
|
+
items={dropDown.options}
|
|
245
|
+
onChange={this.handleComboOnChange}
|
|
246
|
+
onInputChange={this.handleOnInputChange}
|
|
247
|
+
translateWithId={(id) => listBoxMenuIconTranslationIds[id]}
|
|
248
|
+
titleText={this.props.controlItem}
|
|
249
|
+
/>
|
|
254
250
|
);
|
|
255
251
|
} else {
|
|
256
252
|
dropdownComponent = (
|
|
257
|
-
<
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
/>
|
|
270
|
-
</Layer>
|
|
253
|
+
<Dropdown
|
|
254
|
+
{...validationProps}
|
|
255
|
+
id={`${ControlUtils.getDataId(this.props.propertyId)}-dropdown`}
|
|
256
|
+
disabled={this.props.state === STATES.DISABLED || this.disableEmptyListDropdown}
|
|
257
|
+
type="default"
|
|
258
|
+
items={dropDown.options}
|
|
259
|
+
onChange={this.handleChange}
|
|
260
|
+
selectedItem={dropDown.selectedOption}
|
|
261
|
+
label={this.emptyLabel}
|
|
262
|
+
translateWithId={(id) => listBoxMenuIconTranslationIds[id]}
|
|
263
|
+
titleText={this.props.controlItem}
|
|
264
|
+
/>
|
|
271
265
|
);
|
|
272
266
|
}
|
|
273
267
|
|
|
@@ -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 { MultiSelect, FilterableMultiSelect
|
|
20
|
+
import { MultiSelect, FilterableMultiSelect } from "@carbon/react";
|
|
21
21
|
import * as ControlUtils from "./../../util/control-utils";
|
|
22
22
|
import ValidationMessage from "./../../components/validation-message";
|
|
23
23
|
import classNames from "classnames";
|
|
@@ -145,35 +145,31 @@ class MultiSelectControl extends React.Component {
|
|
|
145
145
|
let dropdownComponent = null;
|
|
146
146
|
if (this.props.control.filterable) {
|
|
147
147
|
dropdownComponent = (
|
|
148
|
-
<
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
/>
|
|
160
|
-
</Layer>
|
|
148
|
+
<FilterableMultiSelect
|
|
149
|
+
{...validationProps}
|
|
150
|
+
id={`${ControlUtils.getDataId(this.props.propertyId)}-multiselect-filterable`}
|
|
151
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
152
|
+
translateWithId={(id) => listBoxMenuIconTranslationIds[id]}
|
|
153
|
+
items={multiSelectDropdown.options}
|
|
154
|
+
initialSelectedItems={multiSelectDropdown.selectedOptions}
|
|
155
|
+
onChange={this.handleOnChange}
|
|
156
|
+
placeholder={label}
|
|
157
|
+
titleText={this.props.tableControl ? null : this.props.controlItem}
|
|
158
|
+
/>
|
|
161
159
|
);
|
|
162
160
|
} else {
|
|
163
161
|
dropdownComponent = (
|
|
164
|
-
<
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
/>
|
|
176
|
-
</Layer>
|
|
162
|
+
<MultiSelect
|
|
163
|
+
{...validationProps}
|
|
164
|
+
id={`${ControlUtils.getDataId(this.props.propertyId)}-multiselect`}
|
|
165
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
166
|
+
translateWithId={(id) => listBoxMenuIconTranslationIds[id]}
|
|
167
|
+
items={multiSelectDropdown.options}
|
|
168
|
+
selectedItems={multiSelectDropdown.selectedOptions}
|
|
169
|
+
onChange={this.handleOnChange}
|
|
170
|
+
label={label}
|
|
171
|
+
titleText={this.props.tableControl ? null : this.props.controlItem}
|
|
172
|
+
/>
|
|
177
173
|
);
|
|
178
174
|
}
|
|
179
175
|
|
|
@@ -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 { NumberInput, Button
|
|
20
|
+
import { NumberInput, Button } from "@carbon/react";
|
|
21
21
|
import ValidationMessage from "./../../components/validation-message";
|
|
22
22
|
import * as ControlUtils from "./../../util/control-utils";
|
|
23
23
|
import { formatMessage } from "./../../util/property-utils";
|
|
@@ -158,23 +158,21 @@ class NumberfieldControl extends React.Component {
|
|
|
158
158
|
const validationProps = ControlUtils.getValidationProps(this.props.messageInfo, this.props.tableControl);
|
|
159
159
|
return (
|
|
160
160
|
<div className={className} data-id={ControlUtils.getDataId(this.props.propertyId)}>
|
|
161
|
-
<
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
/>
|
|
177
|
-
</Layer>
|
|
161
|
+
<NumberInput
|
|
162
|
+
{...validationProps}
|
|
163
|
+
ref= { (ref) => (this.numberInput = ref)}
|
|
164
|
+
id={this.id}
|
|
165
|
+
onChange={this.handleChange.bind(this)}
|
|
166
|
+
disabled={disabled}
|
|
167
|
+
step={this.props.control.increment}
|
|
168
|
+
value={controlValue}
|
|
169
|
+
placeholder={this.props.control.additionalText}
|
|
170
|
+
label={this.props.controlItem}
|
|
171
|
+
hideLabel={this.props.tableControl}
|
|
172
|
+
allowEmpty
|
|
173
|
+
hideSteppers={this.props.tableControl || (this.props.control.controlType === ControlType.NUMBERFIELD)}
|
|
174
|
+
onInput={this.onInput.bind(this)}
|
|
175
|
+
/>
|
|
178
176
|
{numberGenerator}
|
|
179
177
|
<ValidationMessage inTable={this.props.tableControl} tableOnly state={this.props.state} messageInfo={this.props.messageInfo} />
|
|
180
178
|
</div>
|
|
@@ -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 { TextInput
|
|
20
|
+
import { TextInput } from "@carbon/react";
|
|
21
21
|
import ValidationMessage from "./../../components/validation-message";
|
|
22
22
|
import * as ControlUtils from "./../../util/control-utils";
|
|
23
23
|
import { STATES, MESSAGE_KEYS } from "./../../constants/constants.js";
|
|
@@ -49,22 +49,20 @@ class PasswordControl extends React.Component {
|
|
|
49
49
|
const validationProps = ControlUtils.getValidationProps(this.props.messageInfo, this.props.tableControl);
|
|
50
50
|
return (
|
|
51
51
|
<div className={className} data-id={ControlUtils.getDataId(this.props.propertyId)}>
|
|
52
|
-
<
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
/>
|
|
67
|
-
</Layer>
|
|
52
|
+
<TextInput.PasswordInput
|
|
53
|
+
{...validationProps}
|
|
54
|
+
autoComplete="off"
|
|
55
|
+
id={this.id}
|
|
56
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
57
|
+
placeholder={this.props.control.additionalText}
|
|
58
|
+
onChange={this.handleChange.bind(this)}
|
|
59
|
+
value={value}
|
|
60
|
+
labelText={this.props.controlItem}
|
|
61
|
+
hideLabel={this.props.tableControl}
|
|
62
|
+
tooltipAlignment="end"
|
|
63
|
+
showPasswordLabel={showPasswordLabel}
|
|
64
|
+
hidePasswordLabel={hidePasswordLabel}
|
|
65
|
+
/>
|
|
68
66
|
<ValidationMessage inTable={this.props.tableControl} tableOnly state={this.props.state} messageInfo={this.props.messageInfo} />
|
|
69
67
|
</div>);
|
|
70
68
|
}
|
|
@@ -21,10 +21,9 @@ import { isEqual } from "lodash";
|
|
|
21
21
|
import * as ControlUtils from "./../../util/control-utils";
|
|
22
22
|
import * as ConditionsUtils from "./../../ui-conditions/conditions-utils.js";
|
|
23
23
|
import ValidationMessage from "./../../components/validation-message";
|
|
24
|
-
import { RadioButton } from "@carbon/react";
|
|
24
|
+
import { RadioButton, RadioButtonGroup } from "@carbon/react";
|
|
25
25
|
import classNames from "classnames";
|
|
26
26
|
import { STATES, UPDATE_TYPE } from "./../../constants/constants.js";
|
|
27
|
-
import { ORIENTATIONS } from "./../../constants/form-constants.js";
|
|
28
27
|
import { v4 as uuid4 } from "uuid";
|
|
29
28
|
import { Information } from "@carbon/react/icons";
|
|
30
29
|
import Tooltip from "./../../../tooltip/tooltip.jsx";
|
|
@@ -200,6 +199,10 @@ class RadiosetControl extends React.Component {
|
|
|
200
199
|
name: this.props.propertyId.name,
|
|
201
200
|
row: i
|
|
202
201
|
};
|
|
202
|
+
const labelWithInfo = (<div className="label-tooltip-container">
|
|
203
|
+
{valueSet.valueLabels[i]}
|
|
204
|
+
{tooltipIcon}
|
|
205
|
+
</div>);
|
|
203
206
|
buttons.push(
|
|
204
207
|
<div key={i} className="properties-radioset-panel">
|
|
205
208
|
<div className="properties-radioset-tooltip">
|
|
@@ -207,12 +210,11 @@ class RadiosetControl extends React.Component {
|
|
|
207
210
|
key={i}
|
|
208
211
|
id={ControlUtils.getControlId(id, this.uuid)}
|
|
209
212
|
disabled={disabled || itemDisabled}
|
|
210
|
-
labelText={
|
|
213
|
+
labelText={labelWithInfo}
|
|
211
214
|
value={val}
|
|
212
215
|
onChange={this.handleChange}
|
|
213
216
|
checked={checked}
|
|
214
217
|
/>
|
|
215
|
-
{tooltipIcon}
|
|
216
218
|
</div>
|
|
217
219
|
{optionalPanel}
|
|
218
220
|
</div>
|
|
@@ -223,12 +225,13 @@ class RadiosetControl extends React.Component {
|
|
|
223
225
|
<div data-id={ControlUtils.getDataId(this.props.control, this.props.propertyId)}
|
|
224
226
|
className={classNames("properties-radioset ", { "hide": this.props.state === STATES.HIDDEN })}
|
|
225
227
|
>
|
|
226
|
-
<
|
|
227
|
-
|
|
228
|
-
|
|
228
|
+
<RadioButtonGroup className={classNames("properties-radio-button-group", this.props.messageInfo ? this.props.messageInfo.type : null)}
|
|
229
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
230
|
+
name="radio-button-group"
|
|
231
|
+
orientation={this.props.control.orientation}
|
|
229
232
|
>
|
|
230
233
|
{buttons}
|
|
231
|
-
</
|
|
234
|
+
</RadioButtonGroup>
|
|
232
235
|
<ValidationMessage state={this.props.state} messageInfo={this.props.messageInfo} inTable={this.props.tableControl} />
|
|
233
236
|
</div>
|
|
234
237
|
);
|
|
@@ -26,24 +26,12 @@
|
|
|
26
26
|
|
|
27
27
|
.properties-radio-button-group {
|
|
28
28
|
display: block;
|
|
29
|
-
|
|
29
|
+
.cds--radio-button-group--label-right { // Horizontal-long labels to wrap properly
|
|
30
30
|
display: inline-flex;
|
|
31
31
|
flex-wrap: wrap;
|
|
32
|
-
.properties-radioset-panel {
|
|
33
|
-
display: flex;
|
|
34
|
-
height: auto;
|
|
35
|
-
align-items: center;
|
|
36
|
-
margin-bottom: 0;
|
|
37
|
-
}
|
|
38
32
|
}
|
|
39
33
|
.properties-radioset-panel {
|
|
40
|
-
margin-
|
|
41
|
-
margin-right: $spacing-04;
|
|
42
|
-
display: flex;
|
|
43
|
-
justify-content: flex-start;
|
|
44
|
-
align-items: center;
|
|
45
|
-
flex-wrap: wrap;
|
|
46
|
-
overflow: hidden;
|
|
34
|
+
margin-right: $spacing-04; // space between first label and next radiobtn
|
|
47
35
|
.cds--radio-button-wrapper{
|
|
48
36
|
margin-right: 0; // We removed the space between radio & tooltip to position it correctly
|
|
49
37
|
}
|
|
@@ -52,6 +40,10 @@
|
|
|
52
40
|
align-items: center;
|
|
53
41
|
margin: 2.5px 0 1.5px 0;
|
|
54
42
|
}
|
|
43
|
+
.label-tooltip-container {
|
|
44
|
+
display: flex;
|
|
45
|
+
align-items: center;
|
|
46
|
+
}
|
|
55
47
|
.properties-control-nested-panel{
|
|
56
48
|
flex-basis: 100%;
|
|
57
49
|
width: 100%;
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
|
|
17
17
|
import React from "react";
|
|
18
18
|
import PropTypes from "prop-types";
|
|
19
|
-
import { Slider
|
|
19
|
+
import { Slider } from "@carbon/react";
|
|
20
20
|
import { connect } from "react-redux";
|
|
21
21
|
import classNames from "classnames";
|
|
22
22
|
import { v4 as uuid4 } from "uuid";
|
|
@@ -50,23 +50,21 @@ class SliderControl extends React.Component {
|
|
|
50
50
|
<div className={classNames("properties-slider ", { "hide": this.props.state === STATES.HIDDEN },
|
|
51
51
|
this.props.messageInfo ? this.props.messageInfo.type : null)} data-id={ControlUtils.getDataId(this.props.propertyId)}
|
|
52
52
|
>
|
|
53
|
-
<
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
/>
|
|
69
|
-
</Layer>
|
|
53
|
+
<Slider
|
|
54
|
+
value={this.props.value !== null && typeof this.props.value !== "undefined" ? this.props.value : minValue}
|
|
55
|
+
min={minValue}
|
|
56
|
+
max={maxValue}
|
|
57
|
+
minLabel={minLabel}
|
|
58
|
+
maxLabel={maxLabel}
|
|
59
|
+
step={step}
|
|
60
|
+
labelText={this.props.controlItem}
|
|
61
|
+
onChange={this.handleChange}
|
|
62
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
63
|
+
ariaLabelInput={formatMessage(this.reactIntl, MESSAGE_KEYS.SLIDER_NUMBER_INPUT_LABEL)}
|
|
64
|
+
formatLabel={
|
|
65
|
+
(val, label) => label || val
|
|
66
|
+
}
|
|
67
|
+
/>
|
|
70
68
|
<ValidationMessage state={this.props.state} messageInfo={this.props.messageInfo} inTable={this.props.tableControl} />
|
|
71
69
|
</div>
|
|
72
70
|
);
|
|
@@ -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 { TextArea
|
|
20
|
+
import { TextArea } from "@carbon/react";
|
|
21
21
|
import ValidationMessage from "./../../components/validation-message";
|
|
22
22
|
import * as ControlUtils from "./../../util/control-utils";
|
|
23
23
|
import { formatMessage } from "./../../util/property-utils";
|
|
@@ -71,33 +71,29 @@ class TextareaControl extends React.Component {
|
|
|
71
71
|
};
|
|
72
72
|
validationProps = ControlUtils.getValidationProps(errorMessage, this.props.tableControl);
|
|
73
73
|
textArea = (<div>
|
|
74
|
-
<
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
/>
|
|
84
|
-
</Layer>
|
|
74
|
+
<TextArea
|
|
75
|
+
{...validationProps}
|
|
76
|
+
id={this.id}
|
|
77
|
+
disabled
|
|
78
|
+
placeholder={this.props.control.additionalText}
|
|
79
|
+
value={value}
|
|
80
|
+
labelText={this.props.controlItem}
|
|
81
|
+
hideLabel={this.props.tableControl}
|
|
82
|
+
/>
|
|
85
83
|
<ValidationMessage inTable={this.props.tableControl} tableOnly={!showValidationMessage} state={""} messageInfo={errorMessage} />
|
|
86
84
|
</div>);
|
|
87
85
|
} else {
|
|
88
86
|
textArea = (
|
|
89
|
-
<
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
/>
|
|
100
|
-
</Layer>
|
|
87
|
+
<TextArea
|
|
88
|
+
{...validationProps}
|
|
89
|
+
id={this.id}
|
|
90
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
91
|
+
placeholder={this.props.control.additionalText}
|
|
92
|
+
onChange={this.handleChange.bind(this)}
|
|
93
|
+
value={value}
|
|
94
|
+
labelText={this.props.controlItem}
|
|
95
|
+
hideLabel={this.props.tableControl}
|
|
96
|
+
/>
|
|
101
97
|
);
|
|
102
98
|
}
|
|
103
99
|
|
|
@@ -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 { TextInput
|
|
20
|
+
import { TextInput } from "@carbon/react";
|
|
21
21
|
import ReadonlyControl from "./../readonly";
|
|
22
22
|
import ValidationMessage from "./../../components/validation-message";
|
|
23
23
|
import * as ControlUtils from "./../../util/control-utils";
|
|
@@ -96,20 +96,18 @@ class TextfieldControl extends React.Component {
|
|
|
96
96
|
} else {
|
|
97
97
|
const validationProps = ControlUtils.getValidationProps(this.props.messageInfo, this.props.tableControl);
|
|
98
98
|
textInput = (
|
|
99
|
-
<
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
/>
|
|
112
|
-
</Layer>
|
|
99
|
+
<TextInput
|
|
100
|
+
{...validationProps}
|
|
101
|
+
autoComplete={this.props.tableControl === true ? "off" : "on"}
|
|
102
|
+
id={this.id}
|
|
103
|
+
disabled={ this.props.state === STATES.DISABLED}
|
|
104
|
+
placeholder={this.props.control.additionalText}
|
|
105
|
+
onChange={this.handleChange.bind(this)}
|
|
106
|
+
value={value}
|
|
107
|
+
labelText={this.props.controlItem}
|
|
108
|
+
hideLabel={this.props.tableControl}
|
|
109
|
+
ref={(ref) => (this.textInputRef = ref)}
|
|
110
|
+
/>
|
|
113
111
|
);
|
|
114
112
|
}
|
|
115
113
|
|
|
@@ -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 { TextInput
|
|
20
|
+
import { TextInput } from "@carbon/react";
|
|
21
21
|
import { parse, format, isValid } from "date-fns";
|
|
22
22
|
import classNames from "classnames";
|
|
23
23
|
|
|
@@ -71,19 +71,17 @@ class TimefieldControl extends React.Component {
|
|
|
71
71
|
const validationProps = ControlUtils.getValidationProps(this.props.messageInfo, this.props.tableControl);
|
|
72
72
|
return (
|
|
73
73
|
<div className={className} data-id={ControlUtils.getDataId(this.props.propertyId)}>
|
|
74
|
-
<
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
/>
|
|
86
|
-
</Layer>
|
|
74
|
+
<TextInput
|
|
75
|
+
{...validationProps}
|
|
76
|
+
autoComplete="off"
|
|
77
|
+
id={this.id}
|
|
78
|
+
disabled={this.props.state === STATES.DISABLED}
|
|
79
|
+
placeholder={this.props.control.additionalText}
|
|
80
|
+
onChange={this.handleChange.bind(this)}
|
|
81
|
+
value={this.value}
|
|
82
|
+
labelText={this.props.controlItem}
|
|
83
|
+
hideLabel={this.props.tableControl}
|
|
84
|
+
/>
|
|
87
85
|
<ValidationMessage inTable={this.props.tableControl} tableOnly state={this.props.state} messageInfo={this.props.messageInfo} />
|
|
88
86
|
</div>
|
|
89
87
|
);
|