@sassoftware/vi-api 1.46.0 → 1.51.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.
@@ -1,6 +1,6 @@
1
1
  /* tslint:disable */
2
2
  /* eslint-disable */
3
- // Generated using typescript-generator version 2.15.527 on 2025-02-05 14:39:22.
3
+ // Generated using typescript-generator version 2.15.527 on 2025-09-03 08:54:51.
4
4
 
5
5
  export interface ActionRequestRep {
6
6
  version?: number;
@@ -17,6 +17,15 @@ export interface ActionResponseRep {
17
17
  alertChanged?: boolean;
18
18
  }
19
19
 
20
+ export interface ActiveScenarioFiredEventRep extends ExtendedScenarioFiredEventRep {
21
+ queueId?: string;
22
+ assignedUserId?: string;
23
+ strategyId?: string;
24
+ actionableEntityId?: string;
25
+ actionableEntityType?: string;
26
+ actionableEntityLabel?: string;
27
+ }
28
+
20
29
  export interface AlertConstants {
21
30
  }
22
31
 
@@ -115,10 +124,6 @@ export interface AlertRep extends BaseRep {
115
124
  autoActivateScore?: number;
116
125
  strategyRangeLow?: number;
117
126
  strategyRangeHigh?: number;
118
- queueEntryTimestamp?: string;
119
- assignmentTimestamp?: string;
120
- checkoutTimestamp?: string;
121
- userServiceTimestamp?: string;
122
127
  systemServiceTimestamp?: string;
123
128
  autoCloseTimestamp?: string;
124
129
  autoActivateTimestamp?: string;
@@ -127,6 +132,10 @@ export interface AlertRep extends BaseRep {
127
132
  dispositionTimestamp?: string;
128
133
  suppressionEndTimestamp?: string;
129
134
  holdEndTimestamp?: string;
135
+ queueEntryTimestamp?: string;
136
+ assignmentTimestamp?: string;
137
+ checkoutTimestamp?: string;
138
+ userServiceTimestamp?: string;
130
139
  }
131
140
 
132
141
  export interface AlertVersionSummaryRep {
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@types/alert-reps",
3
- "version": "20.2.2",
3
+ "version": "21.1.1",
4
4
  "types": "index.d.ts"
5
5
  }
package/api.module.js CHANGED
@@ -28,6 +28,8 @@ import { TabApiService } from "./tab/tab-api.service";
28
28
  import { ThemeApiService } from "./theme/theme-api.service";
29
29
  import { TraversalApiService } from "./traversal/traversal-api.service";
30
30
  import { PageTemplateApiService } from "./page-template/page-template-api.service";
31
+ import { PageSharedModule } from "../spb/shared/spb-shared.module";
32
+ import { HubCommonsModule } from "../fdh/hub-commons/hub-commons.module";
31
33
  let ApiModule = class ApiModule {
32
34
  };
33
35
  ApiModule = __decorate([
@@ -56,6 +58,11 @@ ApiModule = __decorate([
56
58
  TabApiService,
57
59
  ThemeApiService,
58
60
  TraversalApiService
61
+ ],
62
+ // Import modules which bootstrap used AngularJs injectables
63
+ imports: [
64
+ PageSharedModule,
65
+ HubCommonsModule
59
66
  ]
60
67
  })
61
68
  ], ApiModule);
@@ -44,8 +44,8 @@ export interface CreateObjectPageBindings extends CommonPageViewerBindings {
44
44
  * Optionally provide a pageModel using window.sas.vi.pageModel.createFromObject.
45
45
  * The pageModel type must match docType.
46
46
  * The pageModel data will be populated with initialCreateData.
47
- * The pageModel can be used to inspect current data and validity
48
- * but the reference to this model will be broken if a new template is to be loaded due to a mode transition or other condition.
47
+ * The pageModel can be used to inspect current data and validity,
48
+ * but the reference to this model will be broken if a new template is loaded due to a mode transition or other condition.
49
49
  * Prefer using setApi and onChange to interact with the page.
50
50
  */
51
51
  pageModel?: PageModel;
@@ -65,11 +65,11 @@ export interface EditObjectPageBindings extends CommonPageViewerBindings {
65
65
  templateUuid?: string;
66
66
  /**
67
67
  * Optionally provide a pageModel using window.sas.vi.pageModel.createFromObject.
68
- * The pageModel type must match docType.
69
- * The pageModel data will be populated using the loaded object response from the given docType and docId.
70
- * The pageModel can be used to inspect current data and validity
71
- * but the reference to this model will be broken if a new template is to be loaded due to a mode transition or other condition.
72
- * Prefer using setApi and onChange to interact with the page.
68
+ * The pageModel type must match `docType`.
69
+ * The `docType` and `docId` are used to fetch the document page, and `pageModel.data` is set using the field values from this response.
70
+ * The pageModel can be used to inspect current data and validity,
71
+ * but the reference to this model will be broken if a new template is loaded due to a mode transition or other condition.
72
+ * Prefer using `setApi` and `onChange` to interact with the page.
73
73
  */
74
74
  pageModel?: PageModel;
75
75
  }
@@ -96,32 +96,32 @@ export interface StaticDataPageBindings extends CommonPageViewerBindings {
96
96
  staticDocumentData: VIObject;
97
97
  }
98
98
  export interface CommonPageViewerBindings {
99
- /** Show the page toolbar. This contains the toolbar actions associated with the object's Entity type. */
99
+ /** Show the page toolbar. This contains the toolbar actions associated with the object's entity type. */
100
100
  showToolbar?: boolean;
101
101
  /**
102
102
  * Assign the given CSS classes to the page viewer's container.
103
- * This is the element which encompasses the main document view and the toolbar.
103
+ * This element encompasses the main document view and the toolbar.
104
104
  */
105
105
  containerClass?: string;
106
106
  /** If true, the page viewer will fill its parent element's height. */
107
107
  fitToContainerHeight?: boolean;
108
108
  /**
109
109
  * Assign the given CSS classes to the page viewer's main section.
110
- * This is the element which displays the main document, excluding toolbar.
110
+ * This element displays the main document, excluding toolbar.
111
111
  */
112
112
  pageClass?: string;
113
113
  /**
114
- * Enable workspace and insight tabs to be rendered.
114
+ * Enable the workspace and insight tabs to be rendered.
115
115
  */
116
116
  enableSheets?: boolean;
117
117
  /**
118
- * A callback which is called when the page viewer is initialized.
119
- * It provides an API which can be used to check the page viewer state and save the document.
118
+ * A callback that is called when the page viewer is initialized.
119
+ * It provides an API that can be used to check the page viewer state and save the document.
120
120
  */
121
121
  setApi?: (api: PageViewerApi) => void;
122
- /** A callback which is called when the page viewer dirty state changes. */
122
+ /** A callback that is called when the page viewer dirty state changes. */
123
123
  onDirty?: (isDirty: boolean) => void;
124
- /** A callback which is called when the pageModel's mode or data changes. */
124
+ /** A callback that is called when the pageModel's mode or data changes. */
125
125
  onChange?: (change: PageDataChange | PageModeChange) => void;
126
126
  }
127
127
  /** @deprecated use {@link PageViewerBindings} */
@@ -153,25 +153,89 @@ export interface ControlCollectionBindings {
153
153
  pageModel?: PageModel;
154
154
  root?: boolean;
155
155
  }
156
+ /**
157
+ * Defines the bindings for managing relationship details in a component.
158
+ */
156
159
  export interface RelationshipDetailsBindings {
160
+ /**
161
+ * Defines the identifier of the target object type that the relationship references.
162
+ */
157
163
  targetObjectTypeName: string;
164
+ /**
165
+ * Defines the display label of the target object type.
166
+ */
158
167
  targetObjectTypeLabel: string;
168
+ /**
169
+ * Defines the identifier of the parent object type that owns the relationship.
170
+ */
159
171
  parentObjectTypeName: string;
172
+ /**
173
+ * Specifies the user-friendly label of the parent object type.
174
+ */
160
175
  parentObjectTypeLabel: string;
176
+ /**
177
+ * Represents the list of reasons that define the purpose or context of the relationship.
178
+ */
161
179
  linkReasons: Relationship[];
180
+ /**
181
+ * Represents the currently selected item in the relationship, if applicable.
182
+ * Contains an object with `id` and `type` fields to identify the selected item.
183
+ */
162
184
  selectedItem?: {
163
185
  id: string;
164
186
  type: string;
165
187
  };
188
+ /**
189
+ * Fields that are read-only and cannot be modified by the user within the relationships properties panel
190
+ */
191
+ readOnlyFields?: string[];
192
+ /**
193
+ * Fields that are hidden and cannot be seen by the user within the relationships properties panel
194
+ */
195
+ hiddenFields?: string[];
196
+ /**
197
+ * Contains the data for a new page model, if applicable.
198
+ * Includes a `PageModelObjectData` object to represent the model structure.
199
+ */
166
200
  newPageModel?: {
167
201
  model: PageModelObjectData;
168
202
  };
203
+ /**
204
+ * Callback invoked when a link reason is selected.
205
+ * @param linkReason - The selected link reason.
206
+ */
169
207
  onLinkReasonSelected: (linkReason: Relationship) => void;
208
+ /**
209
+ * Represents the current field values of the relationship as key-value pairs.
210
+ */
170
211
  relationshipValues?: Record<string, any>;
212
+ /**
213
+ * Represents the initial field values used to populate the related object during creation.
214
+ */
171
215
  initialCreateData?: Record<string, any>;
216
+ /**
217
+ * Callback to set the API for the page viewer.
218
+ * Provides a `PageViewerAPI` instance to the component.
219
+ * @param api - The `PageViewerAPI` instance.
220
+ */
172
221
  setApi?: (api: PageViewerApi) => void;
222
+ /**
223
+ * Callback invoked when the related page changes.
224
+ * Triggered by events such as data updates or mode transitions.
225
+ * @param change - The event describing the change, either `PageDataChange` or `PageModeChange`.
226
+ */
173
227
  onRelatedPageChange?: (change: PageDataChange | PageModeChange) => void;
228
+ /**
229
+ * Callback invoked when the relationship values are updated.
230
+ * Provides both the current and previous values for comparison.
231
+ * @param current - The updated relationship values.
232
+ * @param previous - The previous relationship values, if available.
233
+ */
174
234
  onRelationshipValuesChange?: (current: Record<string, any>, previous?: Record<string, any>) => void;
235
+ /**
236
+ * Callback invoked when the related page is loading is complete.
237
+ */
238
+ onRelatedPageLoad?: () => void;
175
239
  }
176
240
  export interface SearchInputInputBindings {
177
241
  entityName: string;
@@ -246,3 +310,10 @@ export interface TimeSliderBindings extends TimeSliderInputBindings {
246
310
  close?: () => void;
247
311
  }
248
312
  export type SviComponentBindings = ControlCollectionBindings | RelationshipDetailsBindings | SearchInputBindings | PageViewerBindings | PagePreviewBindings | SearchAndSelectWithPreviewBindings | TimeSliderBindings;
313
+ /**
314
+ * Merges provided bindings with default bindings. If both are functions, wraps them so both are called.
315
+ * @param provided The provided bindings.
316
+ * @param defaults The default bindings.
317
+ * @returns The merged bindings object.
318
+ */
319
+ export declare function mergeBindings<T extends object>(provided?: T, defaults?: Partial<T>): T;
@@ -5,3 +5,26 @@ export var PageViewerBindingsType;
5
5
  PageViewerBindingsType["ViewObject"] = "VIEW";
6
6
  PageViewerBindingsType["StaticData"] = "STATIC";
7
7
  })(PageViewerBindingsType || (PageViewerBindingsType = {}));
8
+ /**
9
+ * Merges provided bindings with default bindings. If both are functions, wraps them so both are called.
10
+ * @param provided The provided bindings.
11
+ * @param defaults The default bindings.
12
+ * @returns The merged bindings object.
13
+ */
14
+ export function mergeBindings(provided = {}, defaults = {}) {
15
+ const merged = { ...provided };
16
+ Object.entries(defaults || {}).forEach(([name, defaultBinding]) => {
17
+ // Use index signature to avoid 'any' and 'Function' types
18
+ const providedValue = merged[name];
19
+ if (typeof defaultBinding === "function" && typeof providedValue === "function") {
20
+ merged[name] = (...args) => {
21
+ defaultBinding(...args);
22
+ return providedValue(...args);
23
+ };
24
+ }
25
+ else if (providedValue === undefined) {
26
+ merged[name] = defaultBinding;
27
+ }
28
+ });
29
+ return merged;
30
+ }
@@ -172,7 +172,7 @@ export interface ConfigApi {
172
172
  * @method
173
173
  * @description Register a callback to override the default action when selecting the configuration bundle in the administration application.
174
174
  * @param bundleName {string} The name of the configuration bundle.
175
- * @param callback {function(): void} A function which should open a view to
175
+ * @param callback {function(): void} A function that should open a view to
176
176
  * allow the user to modify the given configuration bundle.
177
177
  */
178
178
  registerOpenConfigurationCallback(bundleName: string, callback: () => void): void;
@@ -197,7 +197,7 @@ export interface ConfigApi {
197
197
  getSharedDialogContainer(): HTMLElement;
198
198
  /**
199
199
  * @method
200
- * @description Get the services which are an optional part of the SAS Visual Investigator deployment.
200
+ * @description Get the services that are an optional part of the SAS Visual Investigator deployment.
201
201
  * @returns A map of service identifiers to their enabled status (true or false).
202
202
  */
203
203
  getEnabledOptionalServices(): Record<string, boolean>;
@@ -28,6 +28,7 @@ export interface IBaseControlAttribute {
28
28
  displayName: ResourcedString;
29
29
  order?: number;
30
30
  required?: boolean | string;
31
+ requiredExpression?: string;
31
32
  description?: ResourcedString;
32
33
  localizable?: boolean | string;
33
34
  defaultValue?: any;
@@ -37,6 +38,7 @@ export interface IBaseControlAttribute {
37
38
  hideOnDisable?: boolean;
38
39
  cssClass?: string;
39
40
  triggerResizeOnChange?: boolean;
41
+ featureFlagId?: string;
40
42
  }
41
43
  type BaseControlAttribute = Omit<IBaseControlAttribute, "type">;
42
44
  export interface IGenericControlAttribute extends BaseControlAttribute {
@@ -142,6 +144,7 @@ export interface IControlAttributeRelationshipSummary extends Omit<BaseControlAt
142
144
  export interface IControlAttributeTextInput extends BaseControlAttribute {
143
145
  type: StandardPropertyTypes.TextInput | `${StandardPropertyTypes.TextInput}`;
144
146
  defaultValue?: ResourcedString | string;
147
+ multiLine?: boolean;
145
148
  }
146
149
  export interface IControlAttributeInterpolatedTextInput extends Omit<IControlAttributeTextInput, "type"> {
147
150
  type: StandardPropertyTypes.InterpolatedTextInput | `${StandardPropertyTypes.InterpolatedTextInput}`;
@@ -44,6 +44,8 @@ export declare enum StandardPropertyTypes {
44
44
  UserGroupChooser = "UserGroupChooser",
45
45
  TileProviderChooser = "TileProviderChooser",
46
46
  StatusThresholdPicker = "StatusThresholdPicker",
47
+ NetworkNodeSelector = "NetworkNodeSelector",
48
+ NetworkLinkSelector = "NetworkLinkSelector",
47
49
  Hidden = "Hidden",
48
50
  Disabled = "Disabled",
49
51
  Condition = "Condition"
@@ -46,6 +46,8 @@ export var StandardPropertyTypes;
46
46
  StandardPropertyTypes["UserGroupChooser"] = "UserGroupChooser";
47
47
  StandardPropertyTypes["TileProviderChooser"] = "TileProviderChooser";
48
48
  StandardPropertyTypes["StatusThresholdPicker"] = "StatusThresholdPicker";
49
+ StandardPropertyTypes["NetworkNodeSelector"] = "NetworkNodeSelector";
50
+ StandardPropertyTypes["NetworkLinkSelector"] = "NetworkLinkSelector";
49
51
  StandardPropertyTypes["Hidden"] = "Hidden";
50
52
  StandardPropertyTypes["Disabled"] = "Disabled";
51
53
  StandardPropertyTypes["Condition"] = "Condition";
@@ -0,0 +1,11 @@
1
+ import { FieldType, NumberDataType } from "./data-types";
2
+ interface BaseFieldProperties {
3
+ type: string;
4
+ }
5
+ export interface NumberFieldProperties extends BaseFieldProperties {
6
+ type: "numberField";
7
+ disableThousandsSeparator?: boolean;
8
+ }
9
+ export type ClientFieldProperties = NumberFieldProperties | undefined;
10
+ export type FieldTypeToClientFieldProperties<Type extends FieldType> = Type extends NumberDataType ? NumberFieldProperties : ClientFieldProperties;
11
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -3,10 +3,10 @@ import { PageEventsApiBase, PageMode, PageModel } from "../page-model/page-model
3
3
  import { FieldType, FieldTypeToValue } from "./data-types";
4
4
  import { PageDataChange, PageModeChange, StateChange } from "./events";
5
5
  import { Control, RefreshablePageControlOptions, SlidingPanelContent, SlidingPanelProperties, TypeAttributes } from "./page";
6
+ import { FieldTypeToClientFieldProperties } from "./client-field-properties";
6
7
  import { FieldTypeToRestrictions, FileRestrictions } from "./restrictions";
7
8
  import { AttachmentFormData } from "./file";
8
9
  import { MaskingControlApi, MaskingPageApi } from "./masking-api";
9
- import { IControlClientStates } from "../../spb/page-viewer/control-member/api/control-state-api";
10
10
  /**
11
11
  * The minimum API that should be supported on control members across solutions.
12
12
  */
@@ -72,6 +72,20 @@ export interface ControlApiBase<ControlTypeAttributes extends TypeAttributes = T
72
72
  * @returns The value of the control's field.
73
73
  */
74
74
  getFieldValue(): FieldTypeToValue<ControlFieldType>;
75
+ /**
76
+ * Returns the formatted value of the control's field.
77
+ * Field must be configured as dataSource in the control's typeAttributes.
78
+ * @method
79
+ * @returns A promise that resolves to the formatted field value, or undefined if the field is not found.
80
+ */
81
+ getFormattedDisplayValue(): Promise<string | undefined>;
82
+ /**
83
+ * Returns the client field properties that are associated with the calling control.
84
+ * Field must be configured as dataSource in the control's typeAttributes.
85
+ * @method
86
+ * @returns The field restrictions that should be applied.
87
+ */
88
+ getClientFieldProperties(): FieldTypeToClientFieldProperties<ControlFieldType> | undefined;
75
89
  /**
76
90
  * Returns the field restrictions that are associated with the calling control.
77
91
  * Field must be configured as dataSource in the control's typeAttributes.
@@ -204,7 +218,7 @@ export interface ControlStateApi {
204
218
  * @param state {string} The key of the state to be returned.
205
219
  * @returns The specified state of the calling control, or undefined if no match.
206
220
  */
207
- get<T extends keyof IControlClientStates>(state: T): boolean | undefined;
221
+ get<T extends keyof ControlClientStates>(state: T): boolean | undefined;
208
222
  /**
209
223
  * Registers a function to be invoked whenever a state change event occurs.
210
224
  * This function receives an object that contains information about the change event.
@@ -244,6 +258,22 @@ export interface ControlPageFieldApi {
244
258
  * @param field {string} Field name.
245
259
  */
246
260
  getFieldValue<Type extends FieldType>(field: string): FieldTypeToValue<Type>;
261
+ /**
262
+ * Returns the formatted value of the supplied field.
263
+ * This works only with fields for the current object with which the control is associated.
264
+ * @method
265
+ * @param field {string} Field name.
266
+ * @returns A promise that resolves to the formatted field value, or undefined if the field is not found.
267
+ */
268
+ getFormattedDisplayValue(field: string): Promise<string | undefined>;
269
+ /**
270
+ * Returns the client field properties that are associated with the calling control.
271
+ * @method
272
+ * @template {FieldType} Field type.
273
+ * @param field {string} Field name to get client field properties for.
274
+ * @returns Configured client field properties.
275
+ */
276
+ getClientFieldProperties<Type extends FieldType>(field: string): FieldTypeToClientFieldProperties<Type> | undefined;
247
277
  /**
248
278
  * Returns the field restrictions that are associated with the calling control.
249
279
  * @method
@@ -263,11 +293,11 @@ export interface ControlPageApiBase {
263
293
  */
264
294
  readonly file: ControlFileApiBase;
265
295
  /**
266
- * The object ID, if applicable. Otherwise "".
296
+ * The object ID. Returns an empty string ("") if not applicable.
267
297
  */
268
298
  readonly objectId: string;
269
299
  /**
270
- * The object name, if applicable. Otherwise "".
300
+ * The object name. Returns an empty string ("") if not applicable.
271
301
  */
272
302
  readonly objectName: string;
273
303
  /**
@@ -376,7 +406,7 @@ export interface ControlPageApi extends ControlPageApiBase {
376
406
  reloadRefreshableControls(categoryToRefresh?: string, controlToRefresh?: Control): void;
377
407
  /**
378
408
  * @method
379
- * @returns True if any RefreshableControls have options.requiresIndex present. Otherwise False
409
+ * @returns True if any RefreshableControls have options.requiresIndex present. Otherwise false
380
410
  */
381
411
  hasAnyRefreshableControlRequiresIndex(): boolean;
382
412
  /**
@@ -405,15 +435,15 @@ export interface ControlPageApi extends ControlPageApiBase {
405
435
  /**
406
436
  * Checks if a page is in edit mode.
407
437
  * @method
408
- * @returns A boolean value that checks whether or not a page is in edit mode. Undefined if there is no page model.
438
+ * @returns A boolean value that checks if a page is in edit mode. Undefined if there is no page model.
409
439
  */
410
440
  isInEditMode(): boolean | undefined;
411
441
  /**
412
442
  * Takes a page out of edit mode. Promise resolves with a boolean value to determine if the user has saved or not.
413
443
  * If the user has not saved, the user is prompted to do so.
414
444
  * @method
415
- * @param closeTab {boolean} Checks if the tab should close after edit mode is cancelled.
416
- * @returns A Promise that resolves when the edit has been cancelled.
445
+ * @param closeTab {boolean} Checks if the tab should close after edit mode is canceled.
446
+ * @returns A Promise that resolves when the edit has been canceled.
417
447
  */
418
448
  cancelEdit(closeTab: boolean): Promise<{
419
449
  userSaved: boolean;
@@ -440,7 +470,7 @@ export interface ControlPageApi extends ControlPageApiBase {
440
470
  * @method
441
471
  * @param stopEditing {boolean} Checks if the page should leave edit mode after it is saved.
442
472
  * @param closeObject {boolean} Checks if the page should be closed after it is saved.
443
- * @returns A Promise which resolves when the page has been saved.
473
+ * @returns A Promise that resolves when the page has been saved.
444
474
  */
445
475
  save(stopEditing: boolean, closeObject: boolean): Promise<void>;
446
476
  /**
@@ -477,7 +507,7 @@ export interface ControlFileApi extends ControlFileApiBase {
477
507
  *
478
508
  * @method
479
509
  * @param {IAttachmentFormData} options Additional options to pass to the file upload dialog box.
480
- * @returns {Promise<SASObjectAttachedFile[]>} Promise which resolves to an array of uploaded files.
510
+ * @returns {Promise<SASObjectAttachedFile[]>} Promise that resolves to an array of uploaded files.
481
511
  */
482
512
  openFileUploadDialog(options: AttachmentFormData): Promise<SASObjectAttachedFile[]>;
483
513
  /**
@@ -486,7 +516,7 @@ export interface ControlFileApi extends ControlFileApiBase {
486
516
  * @method
487
517
  * @param {boolean} allowMultiple Determines if multiple files can be uploaded at once.
488
518
  * @param {number} [maxSize=] Maximum size of the image to be uploaded, in bytes.
489
- * @returns {Promise<SASObjectAttachedFile[]>} A Promise which resolves to an array of uploaded files.
519
+ * @returns {Promise<SASObjectAttachedFile[]>} A Promise that resolves to an array of uploaded files.
490
520
  */
491
521
  openImageUploadDialog(allowMultiple: boolean, maxSize?: number): Promise<SASObjectAttachedFile[]>;
492
522
  /**
@@ -494,7 +524,7 @@ export interface ControlFileApi extends ControlFileApiBase {
494
524
  *
495
525
  * @method
496
526
  * @param {string} [category=] An optional file category to filter by.
497
- * @returns {Promise<SASObjectAttachedFile[]>} A Promise which resolves to an array of files.
527
+ * @returns {Promise<SASObjectAttachedFile[]>} A Promise that resolves to an array of files.
498
528
  */
499
529
  getFiles(category?: string): Promise<SASObjectAttachedFile[]>;
500
530
  /**
@@ -541,3 +571,45 @@ export interface FieldNotOnPageError {
541
571
  message: string;
542
572
  fields: string[];
543
573
  }
574
+ /**
575
+ * Represents the client states of a control.
576
+ */
577
+ export interface ControlClientStates {
578
+ /**
579
+ * Indicates if the control is required.
580
+ */
581
+ required: boolean;
582
+ /**
583
+ * Indicates if the control is read-only.
584
+ */
585
+ readOnly: boolean;
586
+ /**
587
+ * Indicates if the control is hidden.
588
+ */
589
+ hidden: boolean;
590
+ /**
591
+ * Indicates if the control allows input.
592
+ */
593
+ allowInput: boolean;
594
+ /**
595
+ * Indicates if the control could potentially be read-only
596
+ */
597
+ couldBeReadOnly: boolean;
598
+ /**
599
+ * Indicates if the control could potentially be required
600
+ */
601
+ couldBeRequired: boolean;
602
+ /**
603
+ * Indicates if the control is disabled.
604
+ */
605
+ disabled: boolean;
606
+ /**
607
+ * Indicates if the control has masking active.
608
+ * @deprecated Use `api.control.masking.isMasked` instead.
609
+ */
610
+ maskActive: boolean;
611
+ /**
612
+ * A dynamic map of additional states, where the key is the state name and the value is a boolean.
613
+ */
614
+ [state: string]: boolean;
615
+ }
@@ -68,6 +68,7 @@ export interface PageModeChange {
68
68
  export interface StateChange {
69
69
  readOnly?: boolean;
70
70
  hidden?: boolean;
71
+ disabled?: boolean;
71
72
  required?: boolean;
72
73
  allowInput?: boolean;
73
74
  couldBeReadOnly?: boolean;
package/control/file.d.ts CHANGED
@@ -1,14 +1,27 @@
1
+ import { Control } from ".";
2
+ import { PageModel } from "../page-model/page-model-api";
1
3
  export interface AttachmentFormData {
2
- title: string;
3
- label: string;
4
- options: AttachmentDialogOptions;
5
- pageModel?: {
6
- id?: string;
4
+ /**
5
+ * @deprecated Use AttachmentDialogOptions.dialogTitle instead.
6
+ */
7
+ title?: string;
8
+ /**
9
+ * @deprecated Use AttachmentDialogOptions.filesLabel instead.
10
+ */
11
+ label?: string;
12
+ options?: AttachmentDialogOptions;
13
+ pageModel?: PageModel | {
14
+ id: string;
7
15
  type: string;
8
16
  };
17
+ childNode?: Control;
9
18
  }
10
19
  export interface AttachmentDialogOptions {
11
20
  maxSize?: number;
12
21
  allowMultiple?: boolean;
22
+ allowInput?: boolean;
13
23
  fileExtensions?: string;
24
+ filesLabel?: string;
25
+ addFilesLabel?: string;
26
+ dialogTitle?: string;
14
27
  }
@@ -6,3 +6,4 @@ export * from "./image";
6
6
  export * from "./page";
7
7
  export * from "./restrictions";
8
8
  export * from "./toolbar-property-api";
9
+ export * from "./client-field-properties";
package/control/index.js CHANGED
@@ -6,3 +6,4 @@ export * from "./image";
6
6
  export * from "./page";
7
7
  export * from "./restrictions";
8
8
  export * from "./toolbar-property-api";
9
+ export * from "./client-field-properties";
@@ -73,7 +73,7 @@ export interface MaskingPageApi {
73
73
  /**
74
74
  * Invokes the callback whenever any field value is masked.
75
75
  * When an individual field is masked via a mask call, the callback will be invoked once.
76
- * When multiple fields are masked via a single mask/mask all call, the callback will be invoked once.
76
+ * When multiple fields are masked via a single mask/mask all call, the callback will be invoked once.
77
77
  * @param callback The callback function.
78
78
  * @returns A function that removes the callback.
79
79
  */
@@ -91,7 +91,7 @@ export interface MaskingPageApi {
91
91
  /**
92
92
  * Invokes the callback whenever any field value is unmasked.
93
93
  * When an individual field is unmasked via an unmask call, the callback will be invoked once.
94
- * When multiple fields are unmasked via a single unmask/unmask all call, the callback will be invoked once.
94
+ * When multiple fields are unmasked via a single unmask/unmask all call, the callback will be invoked once.
95
95
  * @param callback The callback function.
96
96
  * @returns A function that removes the callback.
97
97
  */
@@ -12,6 +12,8 @@ export interface SASObjectAttachedFile extends SASUploadedFile {
12
12
  uploadedAt?: string;
13
13
  uploadedBy?: string;
14
14
  version?: number;
15
+ link?: string;
16
+ isLink?: boolean;
15
17
  }
16
18
  export interface FileChange {
17
19
  changeType: FileOperationMethod;
@@ -86,7 +86,7 @@ export interface ObjectApi {
86
86
  * @param objectTypeVersion {number} Object type version.
87
87
  * @param fieldValues {FieldValues} Field values of the object.
88
88
  * @param [options] {UpdateObjectOptions} Optional extra parameters.
89
- * @return A Promise that resolves to the updated object when the object has successfully been updated.
89
+ * @return A Promise that resolves to the updated object when the object been successfully updated.
90
90
  */
91
91
  updateObject(objectType: string, objectId: string, objectTypeId: number, objectTypeVersion: number, fieldValues: FieldValues, options?: UpdateObjectOptions): Promise<VIObject>;
92
92
  /**
@@ -100,7 +100,7 @@ export interface ObjectApi {
100
100
  * @param newFieldValues {FieldValues} Field values after the object was edited
101
101
  * @param objectVersion {number} Object Version
102
102
  * @param [options] {UpdateObjectOptions} Optional extra parameters.
103
- * @return A Promise that resolves to the updated object when the object has successfully been updated.
103
+ * @return A Promise that resolves to the updated object when the object has been successfully updated.
104
104
  */
105
105
  patchObject(objectType: string, objectId: string, objectTypeId: number, objectTypeVersion: number, originalFieldValues: FieldValues, newFieldValues: FieldValues, objectVersion: number, options?: UpdateObjectOptions): Promise<VIObject>;
106
106
  /**
@@ -227,7 +227,7 @@ export interface ObjectApi {
227
227
  * @description Launches a wizard allowing users to create an object/relationship.
228
228
  * The relationship wizard is determined by the relateToParentLabel or relateToParentName defined in the wizardValues parameter.
229
229
  * @param wizardValues {CreateDialogModel} Object containing entity and relationship data.
230
- * @returns A Promise which resolves when the dialog box is closed.
230
+ * @returns A Promise that resolves when the dialog box is closed.
231
231
  */
232
232
  openCreateAndLinkDialog(wizardValues: CreateDialogModel): Promise<CreateDialogModel>;
233
233
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sassoftware/vi-api",
3
- "version": "1.46.0",
3
+ "version": "1.51.0",
4
4
  "description": "Types used in the SAS Visual Investigator API",
5
5
  "keywords": [
6
6
  "SAS",