@kineticdata/react 6.0.5 → 6.1.1
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/README.md +110 -110
- package/assets/task/icons/defer.svg +12 -12
- package/assets/task/icons/drag-handle.svg +3 -3
- package/assets/task/icons/filter.svg +11 -11
- package/assets/task/icons/loop.svg +10 -10
- package/assets/task/icons/plus_small.svg +5 -5
- package/assets/task/icons/routine.svg +9 -9
- package/assets/task/icons/scale-minus.svg +11 -11
- package/assets/task/icons/scale-plus.svg +13 -13
- package/assets/task/icons/start.svg +11 -11
- package/assets/task/icons/stop.svg +8 -8
- package/lib/apis/core/activity.js +4 -4
- package/lib/apis/core/attributeDefinitions.js +64 -6
- package/lib/apis/core/attributeDefinitions.test.js +7 -4
- package/lib/apis/core/authentication.js +12 -1
- package/lib/apis/core/bridgeModels.test.js +46 -23
- package/lib/apis/core/bridgedresources.js +41 -41
- package/lib/apis/core/fileResources.js +2 -6
- package/lib/apis/core/forms.js +51 -2
- package/lib/apis/core/forms.test.js +32 -19
- package/lib/apis/core/integrations.js +61 -0
- package/lib/apis/core/kapps.js +49 -0
- package/lib/apis/core/kapps.test.js +16 -10
- package/lib/apis/core/notices.js +7 -0
- package/lib/apis/core/securityPolicyDefinitions.test.js +7 -4
- package/lib/apis/core/space.js +18 -0
- package/lib/apis/core/space.test.js +16 -10
- package/lib/apis/core/submissionActivities.js +38 -0
- package/lib/apis/core/submissions.js +114 -15
- package/lib/apis/core/translations.test.js +126 -55
- package/lib/apis/core/userPreferences.js +59 -0
- package/lib/apis/core/webApis.js +32 -2
- package/lib/apis/core/webhooks.test.js +7 -4
- package/lib/apis/http.js +30 -5
- package/lib/apis/index.js +48 -0
- package/lib/apis/integrator/index.js +337 -0
- package/lib/apis/system/index.js +64 -12
- package/lib/apis/task/index.js +9 -2
- package/lib/components/agent/filestore/FilestoreForm.js +1 -1
- package/lib/components/common/AttributeSelect.js +11 -2
- package/lib/components/common/BridgeSelect.js +3 -1
- package/lib/components/common/ConnectionSelect.js +73 -0
- package/lib/components/common/FormSelect.js +3 -1
- package/lib/components/common/NodeSelect.js +1 -0
- package/lib/components/common/StaticSelect.js +16 -6
- package/lib/components/common/TableInput.js +4 -1
- package/lib/components/common/TeamSelect.js +3 -1
- package/lib/components/common/ToastContainer.js +34 -10
- package/lib/components/common/Typeahead.js +62 -23
- package/lib/components/common/UserSelect.js +3 -1
- package/lib/components/common/authentication/AuthenticationContainer.js +121 -55
- package/lib/components/common/authentication/RequestInterceptor.js +1 -1
- package/lib/components/common/preferences/PreferencesProvider.js +461 -0
- package/lib/components/core/attribute_definition/AttributeDefinitionForm.js +10 -7
- package/lib/components/core/bridge_model/BridgeModelTable.js +19 -0
- package/lib/components/core/bridge_model_attribute/BridgeModelAttributeForm.js +6 -9
- package/lib/components/core/bridge_model_attribute/BridgeModelAttributeTable.js +0 -4
- package/lib/components/core/bridge_model_qualification/BridgeModelQualificationForm.js +7 -10
- package/lib/components/core/bridge_model_qualification/BridgeModelQualificationTable.js +2 -15
- package/lib/components/core/category/CategoryForm.js +4 -1
- package/lib/components/core/category/CategoryTable.js +2 -2
- package/lib/components/core/core_form/CoreForm.js +18 -10
- package/lib/components/core/field_definition/FieldDefinitionForm.js +3 -3
- package/lib/components/core/file_resource/FileResourceForm.js +2 -1
- package/lib/components/core/file_resource/FileResourceTable.js +14 -7
- package/lib/components/core/form/FormForm.js +42 -19
- package/lib/components/core/form/FormTable.js +13 -14
- package/lib/components/core/form_type/FormTypeForm.js +3 -0
- package/lib/components/core/i18n/Moment.js +1 -0
- package/lib/components/core/integration/IntegrationForm.js +232 -0
- package/lib/components/core/integration/IntegrationTable.js +142 -0
- package/lib/components/core/kapp/KappForm.js +18 -5
- package/lib/components/core/kapp/KappTable.js +3 -3
- package/lib/components/core/log/LogTable.js +1 -1
- package/lib/components/core/security_definition/SecurityDefinitionForm.js +48 -10
- package/lib/components/core/space/SpaceForm.js +17 -36
- package/lib/components/core/submission/DatastoreSubmissionTable.js +4 -4
- package/lib/components/core/submission/FormSubmissionTable.js +12 -7
- package/lib/components/core/submission/KappSubmissionTable.js +4 -4
- package/lib/components/core/submission/SubmissionActivityForm.js +79 -0
- package/lib/components/core/submission/SubmissionForm.js +15 -3
- package/lib/components/core/team/TeamTable.js +17 -7
- package/lib/components/core/translation/EntryTable.js +8 -7
- package/lib/components/core/user/UserForm.js +2 -0
- package/lib/components/core/user/UserTable.js +22 -22
- package/lib/components/core/webapi/WebApiForm.js +5 -2
- package/lib/components/core/webapi/WebApiTable.js +2 -2
- package/lib/components/core/webhook/WebhookForm.js +43 -33
- package/lib/components/core/webhook/WebhookTable.js +16 -16
- package/lib/components/core/webhook_job/WebhookJobTable.js +17 -6
- package/lib/components/form/Form.helpers.js +10 -4
- package/lib/components/form/Form.js +264 -171
- package/lib/components/form/Form.models.js +6 -1
- package/lib/components/form/FormState.js +9 -5
- package/lib/components/form/SimpleForm.js +2 -2
- package/lib/components/form/defaults/CodeField.js +44 -1
- package/lib/components/index.js +152 -3
- package/lib/components/integrator/connection/ConnectionForm.js +156 -0
- package/lib/components/integrator/connection/ConnectionTable.js +82 -0
- package/lib/components/integrator/connection/config_fields/http.js +570 -0
- package/lib/components/integrator/connection/config_fields/sql.js +123 -0
- package/lib/components/integrator/integrationTypes.js +120 -0
- package/lib/components/integrator/operation/OperationForm.js +148 -0
- package/lib/components/integrator/operation/OperationTable.js +62 -0
- package/lib/components/integrator/operation/config_fields/http.js +185 -0
- package/lib/components/integrator/operation/config_fields/sql.js +81 -0
- package/lib/components/system/SystemSecurityForm.js +1 -1
- package/lib/components/system/SystemTaskAdapterForm.js +9 -9
- package/lib/components/system/SystemUserForm.js +2 -0
- package/lib/components/system/helpers.js +123 -100
- package/lib/components/system/spaces/SystemSpaceForm.js +9 -37
- package/lib/components/system/spaces/SystemTenantForm.js +276 -104
- package/lib/components/system/spaces/SystemTenantMigrateForm.js +449 -0
- package/lib/components/system/spaces/SystemTenantTable.js +20 -16
- package/lib/components/table/Table.js +75 -15
- package/lib/components/table/Table.redux.js +297 -73
- package/lib/components/table/defaults/FilterControl.js +24 -0
- package/lib/components/table/defaults/index.js +2 -0
- package/lib/components/table/tests/Table.test.js +22 -22
- package/lib/components/table/tests/components.js +9 -2
- package/lib/components/task/builder/Connector.js +51 -41
- package/lib/components/task/builder/ConnectorForm.js +11 -7
- package/lib/components/task/builder/Node.js +31 -35
- package/lib/components/task/builder/NodeForm.js +93 -22
- package/lib/components/task/builder/NodeParametersForm.js +29 -17
- package/lib/components/task/builder/SvgCanvas.js +3 -17
- package/lib/components/task/builder/TaskDefinitionConfigForm.js +18 -50
- package/lib/components/task/builder/TreeBuilder.js +23 -3
- package/lib/components/task/builder/builder.redux.js +342 -197
- package/lib/components/task/builder/constants.js +10 -2
- package/lib/components/task/builder/helpers.js +231 -81
- package/lib/components/task/builder/models.js +7 -6
- package/lib/components/task/category/TaskCategoryTable.js +3 -3
- package/lib/components/task/common/UsageTable.js +9 -2
- package/lib/components/task/handlers/HandlerTable.js +44 -37
- package/lib/components/task/policy_rule/PolicyRuleTable.js +3 -3
- package/lib/components/task/runs/CreateManualTriggerForm.js +2 -0
- package/lib/components/task/runs/RunTable.js +10 -14
- package/lib/components/task/runs/RunTaskTable.js +1 -1
- package/lib/components/task/sources/SourceTable.js +2 -2
- package/lib/components/task/triggers/TriggerTable.js +2 -2
- package/lib/components/task/workflows/LinkedWorkflowTable.js +16 -11
- package/lib/components/task/workflows/WorkflowForm.js +27 -8
- package/lib/components/task/workflows/WorkflowTable.js +27 -26
- package/lib/helpers/index.js +307 -74
- package/lib/index.js +2 -1
- package/lib/saga.js +4 -4
- package/lib/store.js +2 -1
- package/package.json +7 -6
- package/proxyhelper.js +201 -176
- package/CHANGELOG.md +0 -94
package/lib/helpers/index.js
CHANGED
|
@@ -12,16 +12,21 @@ var _exportNames = {
|
|
|
12
12
|
generateKey: true,
|
|
13
13
|
slugify: true,
|
|
14
14
|
buildDefinitionId: true,
|
|
15
|
-
|
|
15
|
+
buildCodeEditorBindings: true,
|
|
16
16
|
buildAgentPath: true,
|
|
17
17
|
handleFormErrors: true,
|
|
18
18
|
INDEX_STATIC_PARTS: true,
|
|
19
19
|
TIMELINES: true,
|
|
20
|
-
MAX_PART_LENGTH: true
|
|
20
|
+
MAX_PART_LENGTH: true,
|
|
21
|
+
usePrevious: true
|
|
21
22
|
};
|
|
22
|
-
exports.splitTeamName = exports.slugify = exports.partitionListBy = exports.handleFormErrors = exports.generateKey = exports.bundle = exports.buildDefinitionId = exports.
|
|
23
|
+
exports.splitTeamName = exports.slugify = exports.partitionListBy = exports.handleFormErrors = exports.generateKey = exports.bundle = exports.buildDefinitionId = exports.buildCodeEditorBindings = exports.buildAgentPath = exports.TIMELINES = exports.MAX_PART_LENGTH = exports.K = exports.INDEX_STATIC_PARTS = void 0;
|
|
24
|
+
exports.usePrevious = usePrevious;
|
|
25
|
+
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/toConsumableArray"));
|
|
23
26
|
var _toArray2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/toArray"));
|
|
27
|
+
var _react = require("react");
|
|
24
28
|
var _immutable = require("immutable");
|
|
29
|
+
var _lodashEs = require("lodash-es");
|
|
25
30
|
var _SearchBuilder = require("./SearchBuilder");
|
|
26
31
|
Object.keys(_SearchBuilder).forEach(function (key) {
|
|
27
32
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -104,83 +109,300 @@ var buildDefinitionId = exports.buildDefinitionId = function buildDefinitionId(t
|
|
|
104
109
|
// Remove unwanted chars
|
|
105
110
|
.replace(/[^A-Za-z0-9_]+/g, '');
|
|
106
111
|
};
|
|
107
|
-
var
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
var
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
112
|
+
var STATIC_FORM_BINDINGS = [{
|
|
113
|
+
label: 'name',
|
|
114
|
+
boost: 20
|
|
115
|
+
}, {
|
|
116
|
+
label: 'slug',
|
|
117
|
+
boost: 20
|
|
118
|
+
}];
|
|
119
|
+
var STATIC_FORM_BINDINGS_DETAILED = [].concat(STATIC_FORM_BINDINGS, [{
|
|
120
|
+
label: 'anonymous'
|
|
121
|
+
}, {
|
|
122
|
+
label: 'description'
|
|
123
|
+
}, {
|
|
124
|
+
label: 'status'
|
|
125
|
+
}, {
|
|
126
|
+
label: 'type'
|
|
127
|
+
}, {
|
|
128
|
+
label: 'createdAt',
|
|
129
|
+
boost: -20
|
|
130
|
+
}, {
|
|
131
|
+
label: 'createdBy',
|
|
132
|
+
boost: -20
|
|
133
|
+
}, {
|
|
134
|
+
label: 'updatedAt',
|
|
135
|
+
boost: -20
|
|
136
|
+
}, {
|
|
137
|
+
label: 'updatedBy',
|
|
138
|
+
boost: -20
|
|
139
|
+
}]);
|
|
140
|
+
var STATIC_KAPP_BINDINGS = [{
|
|
141
|
+
label: 'name',
|
|
142
|
+
boost: 20
|
|
143
|
+
}, {
|
|
144
|
+
label: 'slug',
|
|
145
|
+
boost: 20
|
|
146
|
+
}];
|
|
147
|
+
var STATIC_SPACE_BINDINGS = [{
|
|
148
|
+
label: 'name',
|
|
149
|
+
boost: 20
|
|
150
|
+
}, {
|
|
151
|
+
label: 'slug',
|
|
152
|
+
boost: 20
|
|
153
|
+
}];
|
|
154
|
+
var STATIC_SUBMISSION_BINDINGS = [{
|
|
155
|
+
label: 'id',
|
|
156
|
+
boost: 20
|
|
157
|
+
}, {
|
|
158
|
+
label: 'coreState'
|
|
159
|
+
}, {
|
|
160
|
+
label: 'currentPage'
|
|
161
|
+
}, {
|
|
162
|
+
label: 'handle'
|
|
163
|
+
}, {
|
|
164
|
+
label: 'type'
|
|
165
|
+
}, {
|
|
166
|
+
label: 'closedAt',
|
|
167
|
+
boost: -20
|
|
168
|
+
}, {
|
|
169
|
+
label: 'closedBy',
|
|
170
|
+
boost: -20
|
|
171
|
+
}, {
|
|
172
|
+
label: 'createdAt',
|
|
173
|
+
boost: -20
|
|
174
|
+
}, {
|
|
175
|
+
label: 'createdBy',
|
|
176
|
+
boost: -20
|
|
177
|
+
}, {
|
|
178
|
+
label: 'submittedAt',
|
|
179
|
+
boost: -20
|
|
180
|
+
}, {
|
|
181
|
+
label: 'submittedBy',
|
|
182
|
+
boost: -20
|
|
183
|
+
}, {
|
|
184
|
+
label: 'updatedAt',
|
|
185
|
+
boost: -20
|
|
186
|
+
}, {
|
|
187
|
+
label: 'updatedBy',
|
|
188
|
+
boost: -20
|
|
189
|
+
}];
|
|
190
|
+
var STATIC_SUBMISSION_BINDINGS_DETAILED = [].concat(STATIC_SUBMISSION_BINDINGS, [{
|
|
191
|
+
label: 'sessionToken'
|
|
192
|
+
}]);
|
|
193
|
+
var STATIC_IDENTITY_BINDINGS = [{
|
|
194
|
+
label: 'username',
|
|
195
|
+
boost: 20
|
|
196
|
+
}, {
|
|
197
|
+
label: 'displayName',
|
|
198
|
+
boost: 10
|
|
199
|
+
}, {
|
|
200
|
+
label: 'email',
|
|
201
|
+
boost: 10
|
|
202
|
+
}, {
|
|
203
|
+
label: 'anonymous'
|
|
204
|
+
}, {
|
|
205
|
+
label: 'authenticated'
|
|
206
|
+
}, {
|
|
207
|
+
label: 'sessionToken'
|
|
208
|
+
}, {
|
|
209
|
+
label: 'spaceAdmin'
|
|
210
|
+
}, {
|
|
211
|
+
label: 'teams'
|
|
212
|
+
}];
|
|
213
|
+
var STATIC_FILE_BINDINGS = [{
|
|
214
|
+
label: 'folder'
|
|
215
|
+
}, {
|
|
216
|
+
label: 'name'
|
|
217
|
+
}, {
|
|
218
|
+
label: 'path'
|
|
219
|
+
}];
|
|
220
|
+
var STATIC_TEAM_BINDINGS = [{
|
|
221
|
+
label: 'name'
|
|
222
|
+
}, {
|
|
223
|
+
label: 'slug'
|
|
224
|
+
}];
|
|
225
|
+
var STATIC_USER_BINDINGS = [{
|
|
226
|
+
label: 'username',
|
|
227
|
+
boost: 20
|
|
228
|
+
}, {
|
|
229
|
+
label: 'displayName',
|
|
230
|
+
boost: 10
|
|
231
|
+
}, {
|
|
232
|
+
label: 'email',
|
|
233
|
+
boost: 10
|
|
234
|
+
}, {
|
|
235
|
+
label: 'spaceAdmin'
|
|
236
|
+
}];
|
|
237
|
+
|
|
238
|
+
/**
|
|
239
|
+
* Builds code editor bindings from the provided options
|
|
240
|
+
*
|
|
241
|
+
* @param {object} options
|
|
242
|
+
*
|
|
243
|
+
* @param {object} [options.values] Options for values bindings
|
|
244
|
+
* @param {string} [options.values.label=values]
|
|
245
|
+
* @param {object[]} options.values.data
|
|
246
|
+
* @param {object} options.values.data[].name
|
|
247
|
+
* @param {object} options.values.data[].renderType
|
|
248
|
+
*
|
|
249
|
+
* @param {object} [options.form] Options for form bindings
|
|
250
|
+
* @param {string} [options.form.label=form]
|
|
251
|
+
* @param {boolean} [options.form.detailed]
|
|
252
|
+
* @param {object[]} [options.form.staticBindings]
|
|
253
|
+
* @param {object[]} [options.form.attributeDefinitions]
|
|
254
|
+
*
|
|
255
|
+
* @param {object} [options.kapp] Options for kapp bindings
|
|
256
|
+
* @param {string} [options.kapp.label=kapp]
|
|
257
|
+
* @param {object[]} [options.kapp.staticBindings]
|
|
258
|
+
* @param {object[]} [options.kapp.attributeDefinitions]
|
|
259
|
+
*
|
|
260
|
+
* @param {object} [options.space] Options for space bindings
|
|
261
|
+
* @param {string} [options.space.label=space]
|
|
262
|
+
* @param {object[]} [options.space.staticBindings]
|
|
263
|
+
* @param {object[]} [options.space.attributeDefinitions]
|
|
264
|
+
*
|
|
265
|
+
* @param {object} [options.submission] Options for submission bindings
|
|
266
|
+
* @param {string} [options.submission.label=submission]
|
|
267
|
+
* @param {boolean} [options.submission.detailed]
|
|
268
|
+
* @param {object[]} [options.submission.staticBindings]
|
|
269
|
+
*
|
|
270
|
+
* @param {object} [options.identity] Options for identity bindings
|
|
271
|
+
* @param {string} [options.identity.label=identity]
|
|
272
|
+
* @param {object[]} [options.identity.staticBindings]
|
|
273
|
+
* @param {object[]} [options.identity.attributeDefinitions]
|
|
274
|
+
* @param {object[]} [options.identity.profileAttributeDefinitions]
|
|
275
|
+
*
|
|
276
|
+
* @param {object} [options.user] Options for user bindings
|
|
277
|
+
* @param {string} [options.user.label=user]
|
|
278
|
+
* @param {object[]} [options.user.staticBindings]
|
|
279
|
+
* @param {object[]} [options.user.attributeDefinitions]
|
|
280
|
+
* @param {object[]} [options.user.profileAttributeDefinitions]
|
|
281
|
+
*
|
|
282
|
+
* @param {object} [options.team] Options for team bindings
|
|
283
|
+
* @param {string} [options.team.label=team]
|
|
284
|
+
* @param {object[]} [options.team.staticBindings]
|
|
285
|
+
* @param {object[]} [options.team.attributeDefinitions]
|
|
286
|
+
*
|
|
287
|
+
* @param {object} [options.file] Options for file resource bindings
|
|
288
|
+
* @param {string} [options.file.label=file]
|
|
289
|
+
* @param {object[]} [options.file.staticBindings]
|
|
290
|
+
*
|
|
291
|
+
* @param {object} [options.resources] Options for bridged resource bindings
|
|
292
|
+
* @param {string} [options.resources.label=resources]
|
|
293
|
+
* @param {string} [options.resources.bridgedResourceName]
|
|
294
|
+
* @param {string[]} [options.resources.attributes]
|
|
295
|
+
*
|
|
296
|
+
* @param {object} [options.integration] Options for integration bindings
|
|
297
|
+
* @param {string} [options.integration.label=integration]
|
|
298
|
+
* @param {string} [options.integration.integrationName]
|
|
299
|
+
* @param {string[]} [options.integration.outputs]
|
|
300
|
+
*
|
|
301
|
+
* @param {object[]} [options.staticBindings] Additional bindings to include
|
|
302
|
+
*
|
|
303
|
+
* @returns The bindings object to be used by the CodeEditor component.
|
|
304
|
+
*/
|
|
305
|
+
var buildCodeEditorBindings = exports.buildCodeEditorBindings = function buildCodeEditorBindings() {
|
|
306
|
+
var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
307
|
+
values = _ref.values,
|
|
308
|
+
form = _ref.form,
|
|
309
|
+
kapp = _ref.kapp,
|
|
310
|
+
space = _ref.space,
|
|
311
|
+
submission = _ref.submission,
|
|
312
|
+
identity = _ref.identity,
|
|
313
|
+
user = _ref.user,
|
|
314
|
+
team = _ref.team,
|
|
315
|
+
file = _ref.file,
|
|
316
|
+
resources = _ref.resources,
|
|
317
|
+
integration = _ref.integration,
|
|
318
|
+
staticBindings = _ref.staticBindings;
|
|
319
|
+
return (0, _immutable.List)([values && buildValuesBindings(values.label || 'values', (0, _immutable.List)(values.data)), form && buildObjectWithAttributesBindings(form.label || 'form', (0, _immutable.List)(form.staticBindings).concat(form.detailed ? STATIC_FORM_BINDINGS_DETAILED : STATIC_FORM_BINDINGS), (0, _immutable.List)(form.attributeDefinitions)), kapp && buildObjectWithAttributesBindings(kapp.label || 'kapp', (0, _immutable.List)(kapp.staticBindings).concat(STATIC_KAPP_BINDINGS), (0, _immutable.List)(kapp.attributeDefinitions)), space && buildObjectWithAttributesBindings(space.label || 'space', (0, _immutable.List)(space.staticBindings).concat(STATIC_SPACE_BINDINGS), (0, _immutable.List)(space.attributeDefinitions)), submission && buildObjectWithAttributesBindings(submission.label || 'submission', (0, _immutable.List)(submission.staticBindings).concat(submission.detailed ? STATIC_SUBMISSION_BINDINGS_DETAILED : STATIC_SUBMISSION_BINDINGS)), identity && buildObjectWithAttributesBindings(identity.label || 'identity', (0, _immutable.List)(identity.staticBindings).concat(STATIC_IDENTITY_BINDINGS), (0, _immutable.List)(identity.attributeDefinitions), (0, _immutable.List)(identity.profileAttributeDefinitions)), user && buildObjectWithAttributesBindings(user.label || 'user', (0, _immutable.List)(user.staticBindings).concat(STATIC_USER_BINDINGS), (0, _immutable.List)(user.attributeDefinitions), (0, _immutable.List)(user.profileAttributeDefinitions)), team && buildObjectWithAttributesBindings(team.label || 'team', (0, _immutable.List)(team.staticBindings).concat(STATIC_TEAM_BINDINGS), (0, _immutable.List)(team.attributeDefinitions)), file && buildObjectWithAttributesBindings(file.label || 'file', (0, _immutable.List)(file.staticBindings).concat(STATIC_FILE_BINDINGS), (0, _immutable.List)(file.attributeDefinitions)), resources && buildResourcesBindings(resources.label || 'resources', resources.bridgedResourceName, resources.attributes), integration && buildIntegrationBindings(integration.label || 'integration', integration.integrationName, integration.integrationProperty, integration.outputs)].concat((0, _toConsumableArray2["default"])((staticBindings || []).map(function (binding) {
|
|
320
|
+
return (0, _immutable.fromJS)(binding);
|
|
321
|
+
}))).filter(Boolean));
|
|
322
|
+
};
|
|
323
|
+
|
|
324
|
+
// Builds code editor binding for kinetic objects with optional attribute
|
|
325
|
+
// definitions
|
|
326
|
+
var buildObjectWithAttributesBindings = function buildObjectWithAttributesBindings(label) {
|
|
327
|
+
var staticBindings = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : (0, _immutable.List)();
|
|
328
|
+
var attributeDefinitions = arguments.length > 2 ? arguments[2] : undefined;
|
|
329
|
+
var profileAttributeDefinitions = arguments.length > 3 ? arguments[3] : undefined;
|
|
330
|
+
return (0, _immutable.Map)({
|
|
331
|
+
label: label,
|
|
332
|
+
type: 'function',
|
|
333
|
+
children: staticBindings.concat([attributeDefinitions && (0, _immutable.Map)({
|
|
334
|
+
label: 'attribute',
|
|
335
|
+
siblings: buildAttributeBindings(attributeDefinitions),
|
|
336
|
+
detail: 'Attribute Selector',
|
|
337
|
+
collapseSiblings: true
|
|
338
|
+
}), profileAttributeDefinitions && (0, _immutable.Map)({
|
|
339
|
+
label: 'profileAttribute',
|
|
340
|
+
siblings: buildAttributeBindings(profileAttributeDefinitions, true),
|
|
341
|
+
detail: 'Profile Attribute Selector',
|
|
342
|
+
collapseSiblings: true
|
|
343
|
+
})].filter(Boolean))
|
|
123
344
|
});
|
|
124
|
-
|
|
345
|
+
};
|
|
346
|
+
|
|
347
|
+
// Converts a list of attribute definitions to code editor bindings
|
|
348
|
+
var buildAttributeBindings = function buildAttributeBindings() {
|
|
349
|
+
var definitions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : (0, _immutable.List)();
|
|
350
|
+
var isProfile = arguments.length > 1 ? arguments[1] : undefined;
|
|
351
|
+
return definitions.map(function (def) {
|
|
125
352
|
return (0, _immutable.Map)({
|
|
126
|
-
|
|
127
|
-
|
|
353
|
+
label: (0, _immutable.get)(def, 'name'),
|
|
354
|
+
detail: "".concat(isProfile ? 'Profile ' : '', "Attribute").concat((0, _immutable.get)(def, 'allowsMultiple') ? ' (Multiple)' : ''),
|
|
355
|
+
section: "".concat(isProfile ? 'Profile ' : '', "Attributes")
|
|
128
356
|
});
|
|
129
357
|
});
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
358
|
+
};
|
|
359
|
+
|
|
360
|
+
// Converts a list of field data objects to code editor bindings
|
|
361
|
+
var buildValuesBindings = function buildValuesBindings(label) {
|
|
362
|
+
var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : (0, _immutable.List)();
|
|
363
|
+
return (0, _immutable.Map)({
|
|
364
|
+
label: label,
|
|
365
|
+
type: 'function',
|
|
366
|
+
children: data.map(function (field) {
|
|
367
|
+
return (0, _immutable.Map)({
|
|
368
|
+
label: (0, _immutable.get)(field, 'name'),
|
|
369
|
+
detail: (0, _lodashEs.capitalize)((0, _immutable.get)(field, 'renderType'))
|
|
370
|
+
});
|
|
371
|
+
})
|
|
136
372
|
});
|
|
137
373
|
};
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
return
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
374
|
+
|
|
375
|
+
// Converts bridged resources data to code editor bindings
|
|
376
|
+
var buildResourcesBindings = function buildResourcesBindings(label, bridgedResourceName, attributes) {
|
|
377
|
+
return (0, _immutable.Map)({
|
|
378
|
+
label: label,
|
|
379
|
+
type: 'function',
|
|
380
|
+
children: [(0, _immutable.Map)({
|
|
381
|
+
label: bridgedResourceName,
|
|
382
|
+
siblings: attributes.map(function (label) {
|
|
383
|
+
return (0, _immutable.Map)({
|
|
384
|
+
label: label,
|
|
385
|
+
section: "".concat(bridgedResourceName, " Bridged Resource")
|
|
386
|
+
});
|
|
387
|
+
}),
|
|
388
|
+
detail: 'Bridged Resource',
|
|
389
|
+
collapseSiblings: true
|
|
390
|
+
})]
|
|
391
|
+
});
|
|
152
392
|
};
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
children:
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
children: ['Kapp', 'Form', 'Submission'].includes(scope) && bindify('kapp', KAPP_STATIC_BINDINGS, (0, _immutable.get)(kapp, 'kappAttributeDefinitions'))
|
|
167
|
-
})], ['Space', (0, _immutable.Map)({
|
|
168
|
-
children: bindify('space', SPACE_STATIC_BINDINGS, (0, _immutable.get)(space, 'spaceAttributeDefinitions'))
|
|
169
|
-
})], ['Submission', (0, _immutable.Map)({
|
|
170
|
-
children: ['Submission', 'Datastore Submission'].includes(scope) && bindify('submission', SUBMISSION_STATIC_BINDINGS)
|
|
171
|
-
})], ['Team', (0, _immutable.Map)({
|
|
172
|
-
children: scope === 'Team' && bindify('team', TEAM_STATIC_BINDINGS, (0, _immutable.get)(space, 'teamAttributeDefinitions'))
|
|
173
|
-
})], ['User', (0, _immutable.Map)({
|
|
174
|
-
children: scope === 'User' && bindify('user', USER_STATIC_BINDINGS, (0, _immutable.get)(space, 'userAttributeDefinitions'))
|
|
175
|
-
})], ['Values', (0, _immutable.Map)({
|
|
176
|
-
children: ['Submission', 'Datastore Submission'].includes(scope) && (form || kapp) && (0, _immutable.OrderedMap)((form ? form.get('fields') : kapp.get('fields')).map(function (field) {
|
|
177
|
-
return [field.get('name'), (0, _immutable.Map)({
|
|
178
|
-
value: "values('".concat(field.get('name'), "')"),
|
|
179
|
-
tags: []
|
|
180
|
-
})];
|
|
181
|
-
}))
|
|
182
|
-
})]]).filter(function (o) {
|
|
183
|
-
return o.get('children') && !o.get('children').isEmpty() || o.has('value');
|
|
393
|
+
|
|
394
|
+
// Converts integration data to code editor bindings
|
|
395
|
+
var buildIntegrationBindings = function buildIntegrationBindings(label, integrationName, integrationProperty, outputs) {
|
|
396
|
+
return (0, _immutable.Map)({
|
|
397
|
+
label: label,
|
|
398
|
+
type: 'function',
|
|
399
|
+
detail: 'Integration Result',
|
|
400
|
+
children: outputs.map(function (label) {
|
|
401
|
+
return (0, _immutable.Map)({
|
|
402
|
+
label: label,
|
|
403
|
+
section: "".concat(integrationName, " Integration") + (integrationProperty ? "\n\xA0\u2BA1 Properties of: ".concat(integrationProperty) : '')
|
|
404
|
+
});
|
|
405
|
+
})
|
|
184
406
|
});
|
|
185
407
|
};
|
|
186
408
|
var buildAgentPath = exports.buildAgentPath = function buildAgentPath(options) {
|
|
@@ -197,4 +419,15 @@ var handleFormErrors = exports.handleFormErrors = function handleFormErrors(key)
|
|
|
197
419
|
};
|
|
198
420
|
var INDEX_STATIC_PARTS = exports.INDEX_STATIC_PARTS = ['closedBy', 'coreState', 'createdBy', 'handle', 'submittedBy', 'type', 'updatedBy'].sort();
|
|
199
421
|
var TIMELINES = exports.TIMELINES = ['createdAt', 'updatedAt', 'submittedAt', 'closedAt'].sort();
|
|
200
|
-
var MAX_PART_LENGTH = exports.MAX_PART_LENGTH = 10;
|
|
422
|
+
var MAX_PART_LENGTH = exports.MAX_PART_LENGTH = 10;
|
|
423
|
+
function usePrevious(value) {
|
|
424
|
+
// The ref object is a generic container whose current property is mutable ...
|
|
425
|
+
// ... and can hold any value, similar to an instance property on a class
|
|
426
|
+
var ref = (0, _react.useRef)();
|
|
427
|
+
// Store current value in ref
|
|
428
|
+
(0, _react.useEffect)(function () {
|
|
429
|
+
ref.current = value;
|
|
430
|
+
}, [value]); // Only re-run if value changes
|
|
431
|
+
// Return previous value (happens before update in useEffect above)
|
|
432
|
+
return ref.current;
|
|
433
|
+
}
|
package/lib/index.js
CHANGED
|
@@ -90,7 +90,8 @@ var KineticLib = exports.KineticLib = function KineticLib(props) {
|
|
|
90
90
|
value: _defaults.DefaultCommonConfig.merge(_defaults2.DefaultFieldConfig).merge(_defaults3.DefaultTableConfig).merge((0, _immutable.remove)(props.components || {}, 'fields')).merge(props.components && props.components.fields)
|
|
91
91
|
}, typeof props.children === 'function' ? /*#__PURE__*/_react["default"].createElement(_AuthenticationContainer.AuthenticationContainer, {
|
|
92
92
|
skipInit: props.skipInit,
|
|
93
|
-
system: props.system
|
|
93
|
+
system: props.system,
|
|
94
|
+
preferences: props.preferences
|
|
94
95
|
}, props.children) : props.children))));
|
|
95
96
|
};
|
|
96
97
|
var history = exports.history = typeof window !== 'undefined' && window.bundle ? (0, _history.createHashHistory)() : null;
|
package/lib/saga.js
CHANGED
|
@@ -80,10 +80,10 @@ var generatorFns = {};
|
|
|
80
80
|
var runningTasks = {};
|
|
81
81
|
var pendingTasks = {};
|
|
82
82
|
|
|
83
|
-
/**
|
|
84
|
-
* Takes either a single argument which should be a saga effect that we can
|
|
85
|
-
* extract from which we can extract the name automatically. Or a pair of
|
|
86
|
-
* arguments, the name and the saga generator function.
|
|
83
|
+
/**
|
|
84
|
+
* Takes either a single argument which should be a saga effect that we can
|
|
85
|
+
* extract from which we can extract the name automatically. Or a pair of
|
|
86
|
+
* arguments, the name and the saga generator function.
|
|
87
87
|
*/
|
|
88
88
|
var regSaga = exports.regSaga = function regSaga(arg0, arg1) {
|
|
89
89
|
if (arg1) {
|
package/lib/store.js
CHANGED
|
@@ -29,7 +29,7 @@ Object.defineProperty(exports, "runSaga", {
|
|
|
29
29
|
return _saga.runSaga;
|
|
30
30
|
}
|
|
31
31
|
});
|
|
32
|
-
exports.store = exports.selectWaiting = void 0;
|
|
32
|
+
exports.useSelector = exports.store = exports.selectWaiting = void 0;
|
|
33
33
|
var _regeneratorRuntime2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/regeneratorRuntime"));
|
|
34
34
|
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/toConsumableArray"));
|
|
35
35
|
var _react = require("react");
|
|
@@ -73,6 +73,7 @@ var connect = exports.connect = function connect() {
|
|
|
73
73
|
}
|
|
74
74
|
return _reactRedux.connect.apply(void 0, (0, _toConsumableArray2["default"])((0, _immutable.setIn)(args, [3, 'context'], context)));
|
|
75
75
|
};
|
|
76
|
+
var useSelector = exports.useSelector = (0, _reactRedux.createSelectorHook)(context);
|
|
76
77
|
var selectWaiting = exports.selectWaiting = /*#__PURE__*/(0, _regeneratorRuntime2["default"])().mark(function selectWaiting(selector) {
|
|
77
78
|
var value;
|
|
78
79
|
return (0, _regeneratorRuntime2["default"])().wrap(function selectWaiting$(_context) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kineticdata/react",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.1.1",
|
|
4
4
|
"description": "A React library for the Kinetic Platform",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"files": [
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"prepublishOnly": "yarn build"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"axios": "
|
|
22
|
+
"axios": "1.8.3",
|
|
23
23
|
"classnames": "^2.2.6",
|
|
24
24
|
"deepequal": "^0.0.1",
|
|
25
25
|
"draft-js": "^0.11.7",
|
|
@@ -31,12 +31,14 @@
|
|
|
31
31
|
"lodash.isstring": "^4.0.1",
|
|
32
32
|
"modularscale-sass": "^3.0.8",
|
|
33
33
|
"moment": "^2.29.4",
|
|
34
|
-
"prismjs": "1.
|
|
34
|
+
"prismjs": "1.30.0",
|
|
35
35
|
"prop-types": "^15.8.1",
|
|
36
|
+
"qs": "^6.11.0",
|
|
36
37
|
"react-autosuggest": "^9.4.3",
|
|
38
|
+
"react-beautiful-dnd": "^11.0.5",
|
|
37
39
|
"react-popper": "^1.3.4",
|
|
38
40
|
"react-redux": "^8.1.3",
|
|
39
|
-
"reactstrap": "^9.2.
|
|
41
|
+
"reactstrap": "^9.2.3",
|
|
40
42
|
"redux": "^4.2.1",
|
|
41
43
|
"redux-saga": "^1.2.3"
|
|
42
44
|
},
|
|
@@ -76,6 +78,5 @@
|
|
|
76
78
|
"suiteNameTemplate": "{filepath}",
|
|
77
79
|
"classNameTemplate": "{classname}",
|
|
78
80
|
"titleTemplate": "{title}"
|
|
79
|
-
}
|
|
80
|
-
"gitHead": "46bbd148a831a29c1a81ec3a081b3e60cdccb03e"
|
|
81
|
+
}
|
|
81
82
|
}
|