@integry/sdk 4.6.48 → 4.6.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@integry/sdk",
3
- "version": "4.6.48",
3
+ "version": "4.6.49",
4
4
  "description": "Integry SDK",
5
5
  "main": "dist/umd/index.umd.js",
6
6
  "module": "dist/esm/index.csm.js",
@@ -7,7 +7,7 @@
7
7
  .functionFieldLabel {
8
8
  display: block;
9
9
  margin-bottom: 0.5rem;
10
- font-size: 13px;
10
+ font-size: 12px;
11
11
  }
12
12
 
13
13
  .functionFieldAddBtn {
@@ -87,6 +87,7 @@
87
87
  padding: 1.25rem 1.5rem;
88
88
  border-bottom: 1px solid #e5e7eb;
89
89
  position: relative;
90
+ padding-bottom: 0;
90
91
  }
91
92
 
92
93
  .functionFieldModalTitle {
@@ -100,6 +101,7 @@
100
101
  margin: 0.5rem 0 0;
101
102
  font-size: 0.875rem;
102
103
  color: #6b7280;
104
+ margin-bottom: 10px;
103
105
  }
104
106
 
105
107
  .functionFieldCloseBtn {
@@ -27,6 +27,7 @@ interface ObjectFieldProps {
27
27
  activityOutputData: any;
28
28
  activityOutputDataRaw: any;
29
29
  objectValue?: any;
30
+ isDisabled?: boolean;
30
31
  }
31
32
 
32
33
  type Option = {
@@ -108,6 +109,7 @@ const ObjectField = (props: ObjectFieldProps) => {
108
109
  activityOutputData,
109
110
  activityOutputDataRaw,
110
111
  objectValue,
112
+ isDisabled = false,
111
113
  } = props;
112
114
  const [objectArray, setObjectArray] = useState<FieldObject[]>(
113
115
  Array.isArray(objectValue) ? objectValue : [{}],
@@ -339,6 +341,7 @@ const ObjectField = (props: ObjectFieldProps) => {
339
341
  isEditable=${true}
340
342
  allowTagsInText=${activityOutputDataRaw}
341
343
  fieldId=${`${field.id}_${fieldName}`}
344
+ isDisabled=${isDisabled}
342
345
  ><//>
343
346
  `}
344
347
  ${fieldType === 'TEXTAREA' &&
@@ -374,6 +377,7 @@ const ObjectField = (props: ObjectFieldProps) => {
374
377
  fieldDetails?.meta?.machine_name || ''
375
378
  ] || ''
376
379
  : formatValueForTextarea(objectValue)}
380
+ isDisabled=${isDisabled}
377
381
  ><//>
378
382
  `}
379
383
  ${fieldType === 'CHECKBOX' &&
@@ -403,6 +407,7 @@ const ObjectField = (props: ObjectFieldProps) => {
403
407
  placeholder="${placeholder}"
404
408
  isRequired="${fieldDetails.meta.is_required}"
405
409
  isDynamic=${true}
410
+ isDisabled=${isDisabled}
406
411
  endpointUrl=${fieldDetails.meta.ui.ui_field?.data_source?.url ||
407
412
  ''}
408
413
  options=${options}
@@ -432,6 +437,7 @@ const ObjectField = (props: ObjectFieldProps) => {
432
437
  placeholder="${placeholder}"
433
438
  isRequired="${fieldDetails.meta.is_required}"
434
439
  isDynamic=${false}
440
+ isDisabled=${isDisabled}
435
441
  endpointUrl=${JSON.stringify(
436
442
  fieldDetails.meta.ui.ui_field?.options,
437
443
  ) || ''}
@@ -106,6 +106,9 @@
106
106
  &.readonly {
107
107
  // width: 70%;
108
108
  }
109
+ svg {
110
+ vertical-align: baseline;
111
+ }
109
112
  }
110
113
  .deleteIcon {
111
114
  width: 20px;
@@ -34,6 +34,7 @@ export type DynamicFieldsProps = {
34
34
  dataSourceBody?: any;
35
35
  parentFieldsChanged?: boolean;
36
36
  value?: any;
37
+ isDisabled?: boolean;
37
38
  } & StoreType;
38
39
 
39
40
  interface DynamicDataItem {
@@ -63,6 +64,7 @@ const DynamicTypedFields = (props: DynamicFieldsProps) => {
63
64
  activityOutputDataRaw,
64
65
  value,
65
66
  onChange,
67
+ isDisabled = false,
66
68
  } = props;
67
69
  const [dynamicItems, setDynamicItems] = useState<DynamicDataItem[]>([]);
68
70
  const [loading, setLoading] = useState<boolean>(true);
@@ -159,7 +161,7 @@ const DynamicTypedFields = (props: DynamicFieldsProps) => {
159
161
  : html`
160
162
  ${dynamicItems.map(
161
163
  (el) => html`
162
- <div class=${styles.dynamicFieldWrapper}>
164
+ <div class=${styles.dynamicTypedFieldWrapper}>
163
165
  <${MultipurposeField}
164
166
  id="${el.id}"
165
167
  title="${el.title}"
@@ -177,6 +179,7 @@ const DynamicTypedFields = (props: DynamicFieldsProps) => {
177
179
  isMappable=${Object.entries(activityOutputData || {})
178
180
  .length > 0}
179
181
  allowTagsInText=${true}
182
+ isDisabled=${isDisabled}
180
183
  ><//>
181
184
  </div>
182
185
  `,
@@ -65,3 +65,9 @@ a.optionsRefresh {
65
65
  cursor: pointer;
66
66
  text-decoration: none;
67
67
  }
68
+ .dynamicTypedFieldWrapper {
69
+ [class^='styles-module_readonlyHint'] {
70
+ top: 24px;
71
+ height: 37px;
72
+ }
73
+ }
@@ -899,6 +899,7 @@ class FunctionForm extends Component<
899
899
  this.props.variables || {},
900
900
  )}
901
901
  value=${this.state.dynamicFieldDataState[field.id] || {}}
902
+ isDisabled=${isAIAssisted}
902
903
  />
903
904
  `,
904
905
  )}
@@ -931,6 +932,7 @@ class FunctionForm extends Component<
931
932
  activityOutputDataRaw=${JSONToActivityOutputData(
932
933
  this.props.variables || {},
933
934
  )}
935
+ isDisabled=${isAIAssisted}
934
936
  />
935
937
  `,
936
938
  )}