survey-creator-core 1.9.30 → 1.9.33
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 +2 -2
- package/package.json +1 -1
- package/survey-creator-core.css +51 -14
- package/survey-creator-core.d.ts +179 -114
- package/survey-creator-core.i18n.js +624 -113
- package/survey-creator-core.i18n.min.js +2 -2
- package/survey-creator-core.js +318 -303
- package/survey-creator-core.min.css +9 -9
- package/survey-creator-core.min.js +3 -3
package/survey-creator-core.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Type definition for Survey Creatorlibrary. Platform independent (core) v1.9.
|
|
2
|
+
* Type definition for Survey Creatorlibrary. Platform independent (core) v1.9.33
|
|
3
3
|
* Copyright (c) 2015-2022 Devsoft Baltic OÜ - https://surveyjs.io/
|
|
4
4
|
* License: https://surveyjs.io/Licenses#SurveyCreator
|
|
5
5
|
*/
|
|
@@ -9,9 +9,9 @@ import { DragDropChoices, Event, AdaptiveActionContainer, PageModel, IElement }
|
|
|
9
9
|
import { IPanel, ISurveyElement, SurveyElement, QuestionSelectBase, QuestionRowModel } from "survey-core";
|
|
10
10
|
import { LocalizableString, DragOrClickHelper, PanelModel, QuestionDropdownModel, ListModel } from "survey-core";
|
|
11
11
|
import { PopupModel, EventBase, PanelModelBase, QuestionNonValue, SurveyTemplateRendererTemplateData } from "survey-core";
|
|
12
|
-
import { ComputedUpdater, QuestionCheckboxModel, ILocalizableString, ArrayChanges
|
|
13
|
-
import { HashTable, QuestionMatrixDynamicModel, QuestionMatrixModel, QuestionMatrixDropdownModel
|
|
14
|
-
import {
|
|
12
|
+
import { QuestionRatingModel, ComputedUpdater, QuestionCheckboxModel, ILocalizableString, ArrayChanges } from "survey-core";
|
|
13
|
+
import { ImageItemValue, HashTable, QuestionMatrixDynamicModel, QuestionMatrixModel, QuestionMatrixDropdownModel } from "survey-core";
|
|
14
|
+
import { QuestionPanelDynamicModel, QuestionCommentModel, MatrixDynamicRowModel } from "survey-core";
|
|
15
15
|
|
|
16
16
|
export { editorLocalization as localization };
|
|
17
17
|
|
|
@@ -64,6 +64,43 @@ export interface ISurveyCreatorOptions {
|
|
|
64
64
|
onConditionGetTitleCallback(expression: string, title: string): string;
|
|
65
65
|
}
|
|
66
66
|
/*
|
|
67
|
+
* Creator options that you can pass in Creator constructor
|
|
68
|
+
*/
|
|
69
|
+
export interface ICreatorOptions {
|
|
70
|
+
showDesignerTab?: boolean;
|
|
71
|
+
showPreviewTab?: boolean;
|
|
72
|
+
showJSONEditorTab?: boolean;
|
|
73
|
+
showLogicTab?: boolean;
|
|
74
|
+
showEmbeddedSurveyTab?: boolean;
|
|
75
|
+
showTranslationTab?: boolean;
|
|
76
|
+
haveCommercialLicense?: boolean;
|
|
77
|
+
isAutoSave?: boolean;
|
|
78
|
+
isRTLValue?: boolean;
|
|
79
|
+
allowEditSurveyTitle?: boolean;
|
|
80
|
+
allowEditExpressionsInTextEditor?: boolean;
|
|
81
|
+
showOptions?: boolean;
|
|
82
|
+
showTitlesInExpressions?: boolean;
|
|
83
|
+
useTabsInElementEditor?: boolean;
|
|
84
|
+
showErrorOnFailedSave?: boolean;
|
|
85
|
+
generateValidJSON?: boolean;
|
|
86
|
+
readOnly?: boolean;
|
|
87
|
+
showPagesInTestSurveyTab?: boolean;
|
|
88
|
+
showPagesInPreviewTab?: boolean;
|
|
89
|
+
showSimulatorInTestSurveyTab?: boolean;
|
|
90
|
+
themeForPreview?: string;
|
|
91
|
+
showSimulatorInPreviewTab?: boolean;
|
|
92
|
+
showDefaultLanguageInPreviewTab?: string | boolean;
|
|
93
|
+
showInvisibleElementsInPreviewTab?: boolean;
|
|
94
|
+
showObjectTitles?: boolean;
|
|
95
|
+
showHeaderInEmptySurvey?: boolean;
|
|
96
|
+
allowModifyPages?: boolean;
|
|
97
|
+
maximumColumnsCount?: number;
|
|
98
|
+
maximumChoicesCount?: number;
|
|
99
|
+
maximumRowsCount?: number;
|
|
100
|
+
maximumRateValues?: number;
|
|
101
|
+
maxLogicItemsInCondition?: number;
|
|
102
|
+
}
|
|
103
|
+
/*
|
|
67
104
|
* The Toolbox item description.
|
|
68
105
|
*/
|
|
69
106
|
export interface IQuestionToolboxItem extends IAction {
|
|
@@ -117,14 +154,14 @@ export interface ISurveyLogicType {
|
|
|
117
154
|
dependedOnPropertyName?: string;
|
|
118
155
|
isInvisible?: boolean;
|
|
119
156
|
showInUI?: boolean;
|
|
120
|
-
showIf?:
|
|
121
|
-
getCollection?: any;
|
|
157
|
+
showIf?: (survey: SurveyModel) => boolean;
|
|
158
|
+
getCollection?: (survey: SurveyModel) => any;
|
|
122
159
|
isUniqueItem?: boolean;
|
|
123
160
|
questionNames?: any;
|
|
124
|
-
getDisplayText?:
|
|
125
|
-
getElementName?:
|
|
126
|
-
getSelectorChoices?: any;
|
|
127
|
-
supportContext?:
|
|
161
|
+
getDisplayText?: (element: Base, formatStr: string, lt: SurveyLogicType) => string;
|
|
162
|
+
getElementName?: (element: Base) => string;
|
|
163
|
+
getSelectorChoices?: (survey: SurveyModel, context: Question) => any;
|
|
164
|
+
supportContext?: (question: Base) => boolean;
|
|
128
165
|
getParentElement(element: Base): Base;
|
|
129
166
|
}
|
|
130
167
|
export interface ISurveyLogicItemOwner {
|
|
@@ -160,20 +197,20 @@ export interface IPropertyGridEditor {
|
|
|
160
197
|
fit(prop: JsonObjectProperty, context?: string): boolean;
|
|
161
198
|
isDefault?: any;
|
|
162
199
|
getJSON(obj: Base, prop: JsonObjectProperty, options: ISurveyCreatorOptions): any;
|
|
163
|
-
showModalPropertyEditor?: any;
|
|
164
|
-
onCreated?:
|
|
165
|
-
onAfterRenderQuestion?: any;
|
|
166
|
-
createPropertyEditorSetup?:
|
|
167
|
-
isPropertyEditorSetupEnabled?:
|
|
168
|
-
canClearPropertyValue?:
|
|
169
|
-
clearPropertyValue?:
|
|
170
|
-
onMasterValueChanged?:
|
|
171
|
-
onAddIntoPropertyValue?:
|
|
172
|
-
onMatrixCellCreated?: any;
|
|
173
|
-
onMatrixCellValueChanged?: any;
|
|
174
|
-
onMatrixAllowRemoveRow?: any;
|
|
175
|
-
onGetQuestionTitleActions?: any;
|
|
176
|
-
onUpdateQuestionCssClasses?: any;
|
|
200
|
+
showModalPropertyEditor?: (editor: IPropertyGridEditor, property: JsonObjectProperty, question: Question, options: ISurveyCreatorOptions) => any;
|
|
201
|
+
onCreated?: (obj: Base, question: Question, prop: JsonObjectProperty, options: ISurveyCreatorOptions) => void;
|
|
202
|
+
onAfterRenderQuestion?: (obj: Base, prop: JsonObjectProperty, evtOptions: any) => void;
|
|
203
|
+
createPropertyEditorSetup?: (obj: Base, prop: JsonObjectProperty, question: Question, options: ISurveyCreatorOptions) => IPropertyEditorSetup;
|
|
204
|
+
isPropertyEditorSetupEnabled?: (obj: Base, prop: JsonObjectProperty, question: Question, options: ISurveyCreatorOptions) => boolean;
|
|
205
|
+
canClearPropertyValue?: (obj: Base, prop: JsonObjectProperty, question: Question, options: ISurveyCreatorOptions) => boolean;
|
|
206
|
+
clearPropertyValue?: (obj: Base, prop: JsonObjectProperty, question: Question, options: ISurveyCreatorOptions) => void;
|
|
207
|
+
onMasterValueChanged?: (obj: Base, prop: JsonObjectProperty, question: Question) => void;
|
|
208
|
+
onAddIntoPropertyValue?: (obj: Base, prop: JsonObjectProperty, question: Question, options: ISurveyCreatorOptions) => void;
|
|
209
|
+
onMatrixCellCreated?: (obj: Base, options: any) => void;
|
|
210
|
+
onMatrixCellValueChanged?: (obj: Base, options: any) => void;
|
|
211
|
+
onMatrixAllowRemoveRow?: (obj: Base, row: any) => boolean;
|
|
212
|
+
onGetQuestionTitleActions?: (obj: Base, options: any) => void;
|
|
213
|
+
onUpdateQuestionCssClasses?: (obj: Base, options: any) => void;
|
|
177
214
|
}
|
|
178
215
|
export interface ITranslationLocales {
|
|
179
216
|
locales: any;
|
|
@@ -181,7 +218,7 @@ export interface ITranslationLocales {
|
|
|
181
218
|
readOnly: boolean;
|
|
182
219
|
getLocaleName(loc: string): string;
|
|
183
220
|
availableTranlationsChangedCallback: any;
|
|
184
|
-
tranlationChangedCallback: any;
|
|
221
|
+
tranlationChangedCallback: (locale: string, name: string, value: string, context: any) => void;
|
|
185
222
|
translateItemAfterRender(item: TranslationItem, el: any, locale: string): any;
|
|
186
223
|
fireOnObjCreating(obj: Base): any;
|
|
187
224
|
removeLocale(loc: string): void;
|
|
@@ -207,9 +244,7 @@ export interface IKeyboardShortcut {
|
|
|
207
244
|
name?: string;
|
|
208
245
|
hotKey: any;
|
|
209
246
|
macOsHotkey?: any;
|
|
210
|
-
execute: any;
|
|
211
|
-
}
|
|
212
|
-
export interface ICreatorOptions {
|
|
247
|
+
execute: (context: any) => void;
|
|
213
248
|
}
|
|
214
249
|
export interface ICreatorPlugin {
|
|
215
250
|
activate: any;
|
|
@@ -249,7 +284,7 @@ export declare class ConditionEditorItem {
|
|
|
249
284
|
value: any;
|
|
250
285
|
}
|
|
251
286
|
export declare class ConditionEditorItemsBuilder {
|
|
252
|
-
constructor(hasValue?:
|
|
287
|
+
constructor(hasValue?: (name: string) => boolean);
|
|
253
288
|
build(text: string): Array<ConditionEditorItem>;
|
|
254
289
|
}
|
|
255
290
|
export declare class CreatorAction extends Action implements ICreatorAction {
|
|
@@ -334,6 +369,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
334
369
|
* You can set this option in creator constructor only
|
|
335
370
|
*/
|
|
336
371
|
get pageEditMode(): "standard" | "single" | "bypage";
|
|
372
|
+
set pageEditMode(val: "standard" | "single" | "bypage");
|
|
337
373
|
surveyValue: SurveyModel;
|
|
338
374
|
get toolbarItems(): any;
|
|
339
375
|
get toolbar(): any;
|
|
@@ -344,7 +380,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
344
380
|
newPanels: any;
|
|
345
381
|
newQuestionChangedNames: any;
|
|
346
382
|
selectionHistoryControllerValue: SelectionHistory;
|
|
347
|
-
saveSurveyFuncValue: any;
|
|
383
|
+
saveSurveyFuncValue: (no: number, onSaveCallback: any, isSuccess: boolean) => any;
|
|
348
384
|
viewType: string;
|
|
349
385
|
/*
|
|
350
386
|
* Returns the current show view name. The possible returns values are:
|
|
@@ -564,21 +600,26 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
564
600
|
*/
|
|
565
601
|
onPropertyValidationCustomError: Event<(sender: CreatorBase, options: any) => any, any>;
|
|
566
602
|
/*
|
|
567
|
-
*
|
|
568
|
-
*
|
|
569
|
-
*
|
|
570
|
-
*
|
|
571
|
-
*
|
|
572
|
-
*
|
|
573
|
-
*
|
|
603
|
+
* An event that is raised each time a user edits a survey object property.
|
|
604
|
+
* Use this event to correct or validate the property value while the user enters it.
|
|
605
|
+
*
|
|
606
|
+
* The event handler accepts the following arguments:
|
|
607
|
+
*
|
|
608
|
+
* - `sender`- A Survey Creator instance that raised the event.
|
|
609
|
+
* - `options.obj` - A survey object instance (question or panel) whose property is being edited.
|
|
610
|
+
* - `options.propertyName` - The name of the property.
|
|
611
|
+
* - `options.value` - A property value entered by a user.
|
|
612
|
+
* - `options.newValue` - A corrected property value. Specify this field if you want to override the `options.value`.
|
|
613
|
+
* - `options.doValidation` - Enable this field to validate the property value while the user enters it.
|
|
574
614
|
*/
|
|
575
615
|
onPropertyValueChanging: Event<(sender: CreatorBase, options: any) => any, any>;
|
|
576
616
|
/*
|
|
577
|
-
*
|
|
578
|
-
*
|
|
579
|
-
*
|
|
580
|
-
*
|
|
581
|
-
*
|
|
617
|
+
* An event that is raised after a property in a survey object has changed.
|
|
618
|
+
*
|
|
619
|
+
* - `sender`- A Survey Creator instance that raised the event.
|
|
620
|
+
* - `options.obj` - A survey object instance (question or panel) whose property has changed.
|
|
621
|
+
* - `options.propertyName` - The name of the property.
|
|
622
|
+
* - `options.value` - A new property value.
|
|
582
623
|
*/
|
|
583
624
|
onSurveyPropertyValueChanged: Event<(sender: CreatorBase, options: any) => any, any>;
|
|
584
625
|
/*
|
|
@@ -754,7 +795,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
754
795
|
/*
|
|
755
796
|
* This callback is used internally for setting survey JSON text.
|
|
756
797
|
*/
|
|
757
|
-
setSurveyJSONTextCallback:
|
|
798
|
+
setSurveyJSONTextCallback: (text: string) => void;
|
|
758
799
|
/*
|
|
759
800
|
* You need to set this property to true if you want to use tabs instead of accordion in the popup element's editor.
|
|
760
801
|
*/
|
|
@@ -963,7 +1004,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
963
1004
|
addPage(pagetoAdd?: PageModel): PageModel;
|
|
964
1005
|
protected initTabs(): void;
|
|
965
1006
|
getOptions(): ICreatorOptions;
|
|
966
|
-
protected setOptions(options:
|
|
1007
|
+
protected setOptions(options: ICreatorOptions): void;
|
|
967
1008
|
isCanModifyProperty(obj: Base, propertyName: string): boolean;
|
|
968
1009
|
onIsPropertyReadOnlyCallback(obj: Base, property: JsonObjectProperty, readOnly: boolean, parentObj: Base, parentProperty: JsonObjectProperty): boolean;
|
|
969
1010
|
/*
|
|
@@ -1086,14 +1127,14 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
1086
1127
|
/*
|
|
1087
1128
|
* Open file chooser dialog
|
|
1088
1129
|
*/
|
|
1089
|
-
chooseFiles(input: any, onFilesChosen: any): void;
|
|
1130
|
+
chooseFiles(input: any, onFilesChosen: (files: any) => void): void;
|
|
1090
1131
|
/*
|
|
1091
1132
|
* Upload the files on a server
|
|
1092
1133
|
*/
|
|
1093
|
-
uploadFiles(files: any, uploadingCallback: any): void;
|
|
1134
|
+
uploadFiles(files: any, uploadingCallback: (status: string, data: any) => any): void;
|
|
1094
1135
|
initKeyboardShortcuts(rootNode: any): void;
|
|
1095
1136
|
removeKeyboardShortcuts(rootNode: any): void;
|
|
1096
|
-
protected onKeyDownHandler: any;
|
|
1137
|
+
protected onKeyDownHandler: (event: any) => void;
|
|
1097
1138
|
shortcuts: any;
|
|
1098
1139
|
registerShortcut(name: string, shortcut: IKeyboardShortcut): void;
|
|
1099
1140
|
unRegisterShortcut(name: string): void;
|
|
@@ -1138,8 +1179,8 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
1138
1179
|
convertCurrentQuestion(newType: string): void;
|
|
1139
1180
|
getAddNewQuestionText(currentAddQuestionType?: string): any;
|
|
1140
1181
|
get addNewQuestionText(): any;
|
|
1141
|
-
getQuestionTypeSelectorModel(beforeAdd:
|
|
1142
|
-
addNewQuestionInPage(beforeAdd: any, panel?: IPanel, type?: string): void;
|
|
1182
|
+
getQuestionTypeSelectorModel(beforeAdd: (type: string) => void, panel?: IPanel): any;
|
|
1183
|
+
addNewQuestionInPage(beforeAdd: (string: any) => void, panel?: IPanel, type?: string): void;
|
|
1143
1184
|
createIActionBarItemByClass(className: string, title: string, iconName: string): Action;
|
|
1144
1185
|
onElementMenuItemsChanged(element: any, items: any): void;
|
|
1145
1186
|
getElementAllowOperations(element: SurveyElement): any;
|
|
@@ -1148,6 +1189,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
|
|
|
1148
1189
|
protected onPropertyValueChanged(name: string, oldValue: any, newValue: any): void;
|
|
1149
1190
|
initResponsivityManager(container: any): void;
|
|
1150
1191
|
resetResponsivityManager(): void;
|
|
1192
|
+
showHeaderInEmptySurvey: any;
|
|
1151
1193
|
showPageNavigator: any;
|
|
1152
1194
|
showTabs: any;
|
|
1153
1195
|
showToolbar: any;
|
|
@@ -1165,7 +1207,7 @@ export declare class CreatorResponsivityManager {
|
|
|
1165
1207
|
currentWidth: any;
|
|
1166
1208
|
prevShowToolbox: any;
|
|
1167
1209
|
prevShowPageNavigator: any;
|
|
1168
|
-
|
|
1210
|
+
static screenSizeBreakpoints: any;
|
|
1169
1211
|
process(): void;
|
|
1170
1212
|
dispose(): void;
|
|
1171
1213
|
}
|
|
@@ -1261,7 +1303,7 @@ export declare class ItemValueWrapperViewModel extends Base {
|
|
|
1261
1303
|
allowItemOperations: ICollectionItemAllowOperations;
|
|
1262
1304
|
canTouchItems: boolean;
|
|
1263
1305
|
onPointerDown(pointerDownEvent: any): void;
|
|
1264
|
-
startDragItemValue: any;
|
|
1306
|
+
startDragItemValue: (pointerDownEvent: any, currentTarget: any) => void;
|
|
1265
1307
|
dispose(): void;
|
|
1266
1308
|
handleDragDropGhostPositionChanged: any;
|
|
1267
1309
|
get isDraggable(): boolean;
|
|
@@ -1321,7 +1363,7 @@ export declare class MatrixCellWrapperViewModel extends Base {
|
|
|
1321
1363
|
row: any;
|
|
1322
1364
|
column: any;
|
|
1323
1365
|
isSelected: boolean;
|
|
1324
|
-
onSelectionChanged: any;
|
|
1366
|
+
onSelectionChanged: (sender: any, options: any) => void;
|
|
1325
1367
|
editQuestion(model: MatrixCellWrapperViewModel): void;
|
|
1326
1368
|
get context(): any;
|
|
1327
1369
|
selectContext(model: MatrixCellWrapperViewModel, event: any): void;
|
|
@@ -1338,7 +1380,7 @@ export declare class Notifier extends Base {
|
|
|
1338
1380
|
notify(message: string, type?: "info" | "error"): void;
|
|
1339
1381
|
}
|
|
1340
1382
|
export declare class ObjectSelector {
|
|
1341
|
-
constructor(creator: CreatorBase, survey: SurveyModel, getObjectDisplayName?:
|
|
1383
|
+
constructor(creator: CreatorBase, survey: SurveyModel, getObjectDisplayName?: (obj: Base, reason: string, displayName: string) => string);
|
|
1342
1384
|
surveyValue: SurveyModel;
|
|
1343
1385
|
deepestLevel: number;
|
|
1344
1386
|
filteredTextInLow: string;
|
|
@@ -1357,12 +1399,12 @@ export declare class ObjectSelectorItem extends Action {
|
|
|
1357
1399
|
hasText(filteredTextInLow: string): boolean;
|
|
1358
1400
|
}
|
|
1359
1401
|
export declare class ObjectSelectorModel extends Base {
|
|
1360
|
-
constructor(creator: CreatorBase, getObjectDisplayName?:
|
|
1402
|
+
constructor(creator: CreatorBase, getObjectDisplayName?: (obj: Base, reason: string, displayName: string) => string);
|
|
1361
1403
|
selector: ObjectSelector;
|
|
1362
1404
|
listModelValue: ListModel;
|
|
1363
1405
|
isVisible: boolean;
|
|
1364
1406
|
get list(): ListModel;
|
|
1365
|
-
show(survey: SurveyModel, selectedObj: Base, onClose:
|
|
1407
|
+
show(survey: SurveyModel, selectedObj: Base, onClose: (obj: Base) => void): void;
|
|
1366
1408
|
refresh(): void;
|
|
1367
1409
|
}
|
|
1368
1410
|
export declare class PageNavigatorViewModel extends Base {
|
|
@@ -1370,8 +1412,8 @@ export declare class PageNavigatorViewModel extends Base {
|
|
|
1370
1412
|
icon: string;
|
|
1371
1413
|
pageListModel: ListModel;
|
|
1372
1414
|
popupModel: any;
|
|
1373
|
-
pagesChangedFunc: any;
|
|
1374
|
-
currentPagesChangedFunc: any;
|
|
1415
|
+
pagesChangedFunc: (sender: PagesController, options: any) => void;
|
|
1416
|
+
currentPagesChangedFunc: (sender: PagesController, options: any) => void;
|
|
1375
1417
|
dispose(): void;
|
|
1376
1418
|
items: any;
|
|
1377
1419
|
visible: boolean;
|
|
@@ -1387,7 +1429,7 @@ export declare class PagesController extends Base {
|
|
|
1387
1429
|
creator: ICreatorSelectionOwner;
|
|
1388
1430
|
onPagesChanged: EventBase<PagesController>;
|
|
1389
1431
|
onCurrentPageChanged: EventBase<PagesController>;
|
|
1390
|
-
currentPageChangedFunc: any;
|
|
1432
|
+
currentPageChangedFunc: (sender: SurveyModel, options: any) => any;
|
|
1391
1433
|
surveyValue: SurveyModel;
|
|
1392
1434
|
page2Display: PageModel;
|
|
1393
1435
|
get survey(): SurveyModel;
|
|
@@ -1411,7 +1453,7 @@ export declare class PropertyGridModel {
|
|
|
1411
1453
|
currentlySelectedProperty: string;
|
|
1412
1454
|
currentlySelectedPanel: PanelModel;
|
|
1413
1455
|
objValueChangedCallback: any;
|
|
1414
|
-
changedFromActionCallback:
|
|
1456
|
+
changedFromActionCallback: (obj: Base, propertyName: string) => void;
|
|
1415
1457
|
refresh(): void;
|
|
1416
1458
|
get obj(): Base;
|
|
1417
1459
|
set obj(val: Base);
|
|
@@ -1483,6 +1525,19 @@ export declare class QuestionLinkValueModel extends Question {
|
|
|
1483
1525
|
doLinkClick(): void;
|
|
1484
1526
|
doClearClick(): void;
|
|
1485
1527
|
}
|
|
1528
|
+
export declare class QuestionRatingAdornerViewModel extends Base {
|
|
1529
|
+
constructor(creator: CreatorBase, surveyElement: SurveyElement, templateData: SurveyTemplateRendererTemplateData);
|
|
1530
|
+
creator: CreatorBase;
|
|
1531
|
+
surveyElement: SurveyElement;
|
|
1532
|
+
templateData: SurveyTemplateRendererTemplateData;
|
|
1533
|
+
get element(): QuestionRatingModel;
|
|
1534
|
+
addItem(model: QuestionRatingAdornerViewModel): void;
|
|
1535
|
+
removeItem(model: QuestionRatingAdornerViewModel): void;
|
|
1536
|
+
get allowAdd(): boolean;
|
|
1537
|
+
get allowRemove(): boolean;
|
|
1538
|
+
get addTooltip(): string;
|
|
1539
|
+
get removeTooltip(): string;
|
|
1540
|
+
}
|
|
1486
1541
|
/*
|
|
1487
1542
|
* The list of Toolbox items.
|
|
1488
1543
|
*/
|
|
@@ -1493,7 +1548,6 @@ export declare class QuestionToolbox extends AdaptiveActionContainer<QuestionToo
|
|
|
1493
1548
|
static defaultIconName: string;
|
|
1494
1549
|
_orderedQuestions: any;
|
|
1495
1550
|
static getQuestionDefaultSettings(questionType: string): any;
|
|
1496
|
-
static _questionDefaultSettings: any;
|
|
1497
1551
|
/*
|
|
1498
1552
|
* Modify this array to change the toolbox items order.
|
|
1499
1553
|
*/
|
|
@@ -1648,9 +1702,9 @@ export declare class ResizeManager {
|
|
|
1648
1702
|
mouseDevice: "mouse" | "pointer" | "touch";
|
|
1649
1703
|
events: any;
|
|
1650
1704
|
setHandles(newVal: string): void;
|
|
1651
|
-
onMouseDownListener: any;
|
|
1652
|
-
resize: any;
|
|
1653
|
-
stopResize: any;
|
|
1705
|
+
onMouseDownListener: (e: any) => void;
|
|
1706
|
+
resize: (e: any) => void;
|
|
1707
|
+
stopResize: (e: any) => void;
|
|
1654
1708
|
dispose(): void;
|
|
1655
1709
|
}
|
|
1656
1710
|
export declare class RowViewModel extends Base {
|
|
@@ -1746,8 +1800,8 @@ export declare class SurveyElementAdornerBase<T extends SurveyElement = SurveyEl
|
|
|
1746
1800
|
creator: CreatorBase;
|
|
1747
1801
|
actionContainer: any;
|
|
1748
1802
|
allowDragging: boolean;
|
|
1749
|
-
selectedPropPageFunc: any;
|
|
1750
|
-
sidebarFlyoutModeChangedFunc: any;
|
|
1803
|
+
selectedPropPageFunc: (sender: Base, options: any) => void;
|
|
1804
|
+
sidebarFlyoutModeChangedFunc: (sender: Base, options: any) => void;
|
|
1751
1805
|
protected detachElement(surveyElement: T): void;
|
|
1752
1806
|
protected attachElement(surveyElement: T): void;
|
|
1753
1807
|
protected setSurveyElement(surveyElement: T): void;
|
|
@@ -1820,7 +1874,7 @@ export declare class SurveyLogic extends Base implements ISurveyLogicItemOwner {
|
|
|
1820
1874
|
static set visibleActions(val: any);
|
|
1821
1875
|
static get types(): any;
|
|
1822
1876
|
invisibleItems: any;
|
|
1823
|
-
onChangedCallback:
|
|
1877
|
+
onChangedCallback: (item: SurveyLogicItem, changeType: string) => void;
|
|
1824
1878
|
/*
|
|
1825
1879
|
* The event is called when logic item is saved.
|
|
1826
1880
|
* <br/> options.item is the saved logic item.
|
|
@@ -2065,8 +2119,8 @@ export declare class SurveySimulatorModel extends Base {
|
|
|
2065
2119
|
get zoomScale(): number;
|
|
2066
2120
|
activateZoom: any;
|
|
2067
2121
|
deactivateZoom: any;
|
|
2068
|
-
listenTryToZoomWithWheel: any;
|
|
2069
|
-
listenTryToZoom: any;
|
|
2122
|
+
listenTryToZoomWithWheel: (e: any) => boolean;
|
|
2123
|
+
listenTryToZoom: (e: any) => boolean;
|
|
2070
2124
|
tryToZoom(data: any, event: any): boolean;
|
|
2071
2125
|
resetZoomParameters(): void;
|
|
2072
2126
|
get activeDevice(): string;
|
|
@@ -2091,8 +2145,8 @@ export declare class SurveyTextWorker {
|
|
|
2091
2145
|
export declare class TabDesignerViewModel extends Base {
|
|
2092
2146
|
constructor(creator: CreatorBase);
|
|
2093
2147
|
widthUpdater: any;
|
|
2094
|
-
checkNewPageHandler: any;
|
|
2095
|
-
surveyOnPropertyChanged: any;
|
|
2148
|
+
checkNewPageHandler: (sender: SurveyModel, options: any) => void;
|
|
2149
|
+
surveyOnPropertyChanged: (sender: SurveyModel, options: any) => void;
|
|
2096
2150
|
pagesControllerValue: PagesController;
|
|
2097
2151
|
newPage: PageModel;
|
|
2098
2152
|
showNewPage: boolean;
|
|
@@ -2122,7 +2176,7 @@ export declare class TestSurveyTabViewModel extends Base {
|
|
|
2122
2176
|
nextPageAction: Action;
|
|
2123
2177
|
selectPageAction: Action;
|
|
2124
2178
|
pagePopupModel: any;
|
|
2125
|
-
onSurveyCreatedCallback: any;
|
|
2179
|
+
onSurveyCreatedCallback: (survey: SurveyModel) => any;
|
|
2126
2180
|
simulator: SurveySimulatorModel;
|
|
2127
2181
|
showInvisibleElements: any;
|
|
2128
2182
|
showPagesInTestSurveyTab: any;
|
|
@@ -2151,12 +2205,12 @@ export declare class ToolbarActionContainer extends ActionContainer {
|
|
|
2151
2205
|
export declare class ToolboxToolViewModel extends Base {
|
|
2152
2206
|
constructor(item: IQuestionToolboxItem, creator: CreatorBase);
|
|
2153
2207
|
dragOrClickHelper: DragOrClickHelper;
|
|
2154
|
-
click: any;
|
|
2208
|
+
click: (event: any) => void;
|
|
2155
2209
|
get allowAdd(): boolean;
|
|
2156
2210
|
onPointerDown(pointerDownEvent: any): boolean;
|
|
2157
2211
|
_node: any;
|
|
2158
|
-
onPointerUp: any;
|
|
2159
|
-
startDragToolboxItem: any;
|
|
2212
|
+
onPointerUp: (pointerUpEvent: any) => void;
|
|
2213
|
+
startDragToolboxItem: (pointerDownEvent: any, currentTarget: any) => boolean;
|
|
2160
2214
|
}
|
|
2161
2215
|
export declare class Transaction {
|
|
2162
2216
|
constructor(_name: string);
|
|
@@ -2174,14 +2228,14 @@ export declare class Translation extends Base implements ITranslationLocales {
|
|
|
2174
2228
|
exportToCSVFileUI: any;
|
|
2175
2229
|
importFromCSVFileUI: any;
|
|
2176
2230
|
importFinishedCallback: any;
|
|
2177
|
-
translateItemAfterRenderCallback: any;
|
|
2231
|
+
translateItemAfterRenderCallback: (item: TranslationItem, el: any, locale: string) => void;
|
|
2178
2232
|
availableTranlationsChangedCallback: any;
|
|
2179
|
-
tranlationChangedCallback: any;
|
|
2180
|
-
translationStringVisibilityCallback:
|
|
2181
|
-
localeInitialVisibleCallback:
|
|
2233
|
+
tranlationChangedCallback: (locale: string, name: string, value: string, context: any) => void;
|
|
2234
|
+
translationStringVisibilityCallback: (obj: Base, propertyName: string, visible: boolean) => boolean;
|
|
2235
|
+
localeInitialVisibleCallback: (locale: string) => boolean;
|
|
2182
2236
|
surveyValue: SurveyModel;
|
|
2183
2237
|
settingsSurveyValue: SurveyModel;
|
|
2184
|
-
onBaseObjCreatingCallback:
|
|
2238
|
+
onBaseObjCreatingCallback: (obj: Base) => void;
|
|
2185
2239
|
chooseLanguagePopupModel: any;
|
|
2186
2240
|
chooseLanguageActions: any;
|
|
2187
2241
|
getType(): string;
|
|
@@ -2195,11 +2249,12 @@ export declare class Translation extends Base implements ITranslationLocales {
|
|
|
2195
2249
|
stringsSurvey: SurveyModel;
|
|
2196
2250
|
stringsHeaderSurvey: SurveyModel;
|
|
2197
2251
|
isEmpty: boolean;
|
|
2198
|
-
makeObservable(onBaseObjCreating:
|
|
2252
|
+
makeObservable(onBaseObjCreating: (obj: Base) => void): void;
|
|
2199
2253
|
fireOnObjCreating(obj: Base): void;
|
|
2200
2254
|
get settingsSurvey(): SurveyModel;
|
|
2201
2255
|
get localesQuestion(): QuestionCheckboxModel;
|
|
2202
2256
|
protected createSettingsSurvey(): SurveyModel;
|
|
2257
|
+
isChooseLanguageEnabled: boolean;
|
|
2203
2258
|
getSurveyLocales(): any;
|
|
2204
2259
|
protected onPropertyValueChanged(name: string, oldValue: any, newValue: any): void;
|
|
2205
2260
|
get survey(): SurveyModel;
|
|
@@ -2298,7 +2353,7 @@ export declare class UndoRedoManager {
|
|
|
2298
2353
|
redo(): void;
|
|
2299
2354
|
suspend(): void;
|
|
2300
2355
|
resume(): void;
|
|
2301
|
-
changesFinishedCallback:
|
|
2356
|
+
changesFinishedCallback: (changes: IUndoRedoChange) => void;
|
|
2302
2357
|
}
|
|
2303
2358
|
export declare class AceJsonEditorModel extends JsonEditorBaseModel {
|
|
2304
2359
|
constructor(creator: CreatorBase);
|
|
@@ -2441,7 +2496,7 @@ export declare class QuestionAdornerViewModel extends SurveyElementAdornerBase {
|
|
|
2441
2496
|
get isRequired(): any;
|
|
2442
2497
|
set isRequired(val: any);
|
|
2443
2498
|
onPointerDown(pointerDownEvent: any): void;
|
|
2444
|
-
startDragSurveyElement: any;
|
|
2499
|
+
startDragSurveyElement: (event: any) => boolean;
|
|
2445
2500
|
get allowEdit(): boolean;
|
|
2446
2501
|
get showAddQuestionButton(): boolean;
|
|
2447
2502
|
getConvertToTypesActions(): Array<IAction>;
|
|
@@ -2629,7 +2684,7 @@ export declare class TranslationGroup extends TranslationItemBase {
|
|
|
2629
2684
|
get localeCount(): number;
|
|
2630
2685
|
get locWidth(): string;
|
|
2631
2686
|
getLocaleName(loc: string): string;
|
|
2632
|
-
removeLocale:
|
|
2687
|
+
removeLocale: (loc: string) => void;
|
|
2633
2688
|
reset(): void;
|
|
2634
2689
|
fillLocales(locales: any): void;
|
|
2635
2690
|
makeObservable(): void;
|
|
@@ -2688,6 +2743,8 @@ export declare class ConditionEditor extends PropertyEditorSetupValue {
|
|
|
2688
2743
|
constructor(survey: SurveyModel, object?: Base, options?: ISurveyCreatorOptions, propertyName?: string);
|
|
2689
2744
|
static canParseExpression(text: string): boolean;
|
|
2690
2745
|
static canBuildExpression(text: string): boolean;
|
|
2746
|
+
static isOperatorEnabled(qType: string, operatorTypes: any): boolean;
|
|
2747
|
+
static isClassContains(qType: string, contains: any, notContains: any): boolean;
|
|
2691
2748
|
objectValue: Base;
|
|
2692
2749
|
surveyValue: SurveyModel;
|
|
2693
2750
|
contextValue: Question;
|
|
@@ -2696,7 +2753,7 @@ export declare class ConditionEditor extends PropertyEditorSetupValue {
|
|
|
2696
2753
|
addConditionQuestionsHash: any;
|
|
2697
2754
|
isModalValue: boolean;
|
|
2698
2755
|
allConditionQuestions: any;
|
|
2699
|
-
onContextChanged:
|
|
2756
|
+
onContextChanged: (context: Question) => void;
|
|
2700
2757
|
get title(): string;
|
|
2701
2758
|
set title(val: string);
|
|
2702
2759
|
get isModal(): boolean;
|
|
@@ -2812,7 +2869,7 @@ export declare class PropertyGridEditorMatrix extends PropertyGridEditor {
|
|
|
2812
2869
|
constructor();
|
|
2813
2870
|
onCreated(obj: Base, question: Question, prop: JsonObjectProperty): void;
|
|
2814
2871
|
onMatrixCellCreated(obj: Base, options: any): void;
|
|
2815
|
-
onGetMatrixRowAction(obj: Base, options: any, setObjFunc:
|
|
2872
|
+
onGetMatrixRowAction(obj: Base, options: any, setObjFunc: (obj: Base) => void): void;
|
|
2816
2873
|
onGetQuestionTitleActions(obj: Base, options: any): void;
|
|
2817
2874
|
onValueChanged(obj: Base, prop: JsonObjectProperty, question: Question): void;
|
|
2818
2875
|
protected updateTitleActions(question: Question): void;
|
|
@@ -2865,7 +2922,7 @@ export declare class PropertyGridEditorStringBase extends PropertyGridEditor {
|
|
|
2865
2922
|
export declare class PropertyGridValueEditorBase extends PropertyGridEditor {
|
|
2866
2923
|
constructor();
|
|
2867
2924
|
getJSON(obj: Base, prop: JsonObjectProperty, options: ISurveyCreatorOptions): any;
|
|
2868
|
-
onCreated:
|
|
2925
|
+
onCreated: (obj: Base, question: Question, prop: JsonObjectProperty, options: ISurveyCreatorOptions) => void;
|
|
2869
2926
|
clearPropertyValue(obj: Base, prop: JsonObjectProperty, question: Question, options: ISurveyCreatorOptions): void;
|
|
2870
2927
|
protected isValueEmpty(val: any): boolean;
|
|
2871
2928
|
isSupportGrouping(): boolean;
|
|
@@ -2875,16 +2932,6 @@ export declare class QuestionImageAdornerViewModel extends QuestionAdornerViewMo
|
|
|
2875
2932
|
questionRoot: any;
|
|
2876
2933
|
chooseFile(model: QuestionImageAdornerViewModel): void;
|
|
2877
2934
|
}
|
|
2878
|
-
export declare class QuestionRatingAdornerViewModel extends QuestionAdornerViewModel {
|
|
2879
|
-
constructor(creator: CreatorBase, surveyElement: SurveyElement, templateData: SurveyTemplateRendererTemplateData);
|
|
2880
|
-
get element(): QuestionRatingModel;
|
|
2881
|
-
addItem(model: QuestionRatingAdornerViewModel): void;
|
|
2882
|
-
removeItem(model: QuestionRatingAdornerViewModel): void;
|
|
2883
|
-
get allowAdd(): boolean;
|
|
2884
|
-
get allowRemove(): boolean;
|
|
2885
|
-
get addTooltip(): string;
|
|
2886
|
-
get removeTooltip(): string;
|
|
2887
|
-
}
|
|
2888
2935
|
export declare class TabJsonEditorAcePlugin extends TabJsonEditorBasePlugin implements ICreatorPlugin {
|
|
2889
2936
|
constructor(creator: CreatorBase);
|
|
2890
2937
|
protected createModel(creator: CreatorBase): JsonEditorBaseModel;
|
|
@@ -3102,7 +3149,6 @@ export declare class PropertyGridTriggerValueInLogicEditor extends PropertyGridT
|
|
|
3102
3149
|
fit(prop: JsonObjectProperty, context?: string): boolean;
|
|
3103
3150
|
getJSON(obj: Base, prop: JsonObjectProperty, options: ISurveyCreatorOptions): any;
|
|
3104
3151
|
}
|
|
3105
|
-
export declare function getLocString(strName: string, locale?: string): string;
|
|
3106
3152
|
export declare function getNextValue(prefix: string, values: any): string | number;
|
|
3107
3153
|
export declare function findParentNode(className: string, sourceNode: any): any;
|
|
3108
3154
|
export declare function focusFirstControl(renderedElements: any): void;
|
|
@@ -3117,6 +3163,8 @@ export declare function copyObject(dst: any, src: any): void;
|
|
|
3117
3163
|
export declare function copyCssClasses(dest: any, source: any): void;
|
|
3118
3164
|
export declare function assignDefaultV2Classes(destination: any, questionType: string): void;
|
|
3119
3165
|
export declare function wrapTextByCurlyBraces(text: string): string;
|
|
3166
|
+
export declare function capitalize(str: string): string;
|
|
3167
|
+
export declare function getLocString(strName: string, locale?: string): string;
|
|
3120
3168
|
export declare function getLogicString(name: string): string;
|
|
3121
3169
|
export declare function parsePropertyDescription(text: string): string;
|
|
3122
3170
|
export declare function setSurveyJSONForPropertyGrid(json: any, updateOnTyping?: boolean, titleLocationLeft?: boolean): void;
|
|
@@ -3131,8 +3179,6 @@ export declare function getItemValueWrapperComponentName(item: ItemValue, questi
|
|
|
3131
3179
|
export declare function getItemValueWrapperComponentData(item: ItemValue, question: QuestionSelectBase, creator: CreatorBase): any;
|
|
3132
3180
|
export declare function isStringEditable(element: any, name: string): boolean;
|
|
3133
3181
|
export declare function isTextInput(target: any): boolean;
|
|
3134
|
-
export declare var editorLocalization: EditorLocalization;
|
|
3135
|
-
export declare var defaultStrings: any;
|
|
3136
3182
|
export declare var settings: {
|
|
3137
3183
|
translation: {
|
|
3138
3184
|
sortByName: boolean,
|
|
@@ -3187,6 +3233,19 @@ export declare var settings: {
|
|
|
3187
3233
|
maximumRateValues: number,
|
|
3188
3234
|
generalTabName: string,
|
|
3189
3235
|
},
|
|
3236
|
+
toolbox: {
|
|
3237
|
+
/*
|
|
3238
|
+
* Use it to change the default question JSON on dropping it into designer or converting questions
|
|
3239
|
+
*/
|
|
3240
|
+
defaultJSON: {
|
|
3241
|
+
imagepicker: {
|
|
3242
|
+
choices: any,
|
|
3243
|
+
},
|
|
3244
|
+
image: {
|
|
3245
|
+
imageLink: string,
|
|
3246
|
+
},
|
|
3247
|
+
},
|
|
3248
|
+
},
|
|
3190
3249
|
/*
|
|
3191
3250
|
* Notification settings
|
|
3192
3251
|
*/
|
|
@@ -3231,6 +3290,8 @@ export declare var opositeValues: {
|
|
|
3231
3290
|
No: string,
|
|
3232
3291
|
NO: string,
|
|
3233
3292
|
};
|
|
3293
|
+
export declare var editorLocalization: EditorLocalization;
|
|
3294
|
+
export declare var defaultStrings: any;
|
|
3234
3295
|
export declare var propertyGridCss: {
|
|
3235
3296
|
root: string,
|
|
3236
3297
|
container: string,
|
|
@@ -3502,6 +3563,9 @@ export declare var propertyGridCss: {
|
|
|
3502
3563
|
controls: string,
|
|
3503
3564
|
clearButton: string,
|
|
3504
3565
|
},
|
|
3566
|
+
propertygrid_restfull: {
|
|
3567
|
+
content: string,
|
|
3568
|
+
},
|
|
3505
3569
|
saveData: {
|
|
3506
3570
|
root: string,
|
|
3507
3571
|
saving: string,
|
|
@@ -3532,7 +3596,7 @@ export declare var propertyGridCss: {
|
|
|
3532
3596
|
export declare var json: {
|
|
3533
3597
|
name: string,
|
|
3534
3598
|
showInToolbox: boolean,
|
|
3535
|
-
createElements: any,
|
|
3599
|
+
createElements: (panel: any) => void,
|
|
3536
3600
|
};
|
|
3537
3601
|
export declare var DEFAULT_MONITOR_DPI: number;
|
|
3538
3602
|
export declare var simulatorDevices: {
|
|
@@ -3716,20 +3780,20 @@ export declare var PropertyGridEditorCollection: {
|
|
|
3716
3780
|
editors: any,
|
|
3717
3781
|
fitHash: any,
|
|
3718
3782
|
clearHash: any,
|
|
3719
|
-
register:
|
|
3720
|
-
getEditor:
|
|
3721
|
-
isEditorFit:
|
|
3722
|
-
getJSON: any,
|
|
3723
|
-
onCreated: any,
|
|
3724
|
-
onAfterRenderQuestion: any,
|
|
3725
|
-
onMatrixCellCreated: any,
|
|
3726
|
-
onMatrixCellValueChanged: any,
|
|
3727
|
-
onMatrixAllowRemoveRow:
|
|
3728
|
-
onGetMatrixRowAction: any,
|
|
3729
|
-
onUpdateQuestionCssClasses: any,
|
|
3730
|
-
onGetQuestionTitleActions: any,
|
|
3731
|
-
onValueChanged:
|
|
3732
|
-
onMasterValueChanged:
|
|
3783
|
+
register: (editor: IPropertyGridEditor) => void,
|
|
3784
|
+
getEditor: (prop: JsonObjectProperty, context?: string) => IPropertyGridEditor,
|
|
3785
|
+
isEditorFit: (prop: JsonObjectProperty, asDefault?: boolean) => IPropertyGridEditor,
|
|
3786
|
+
getJSON: (obj: Base, prop: JsonObjectProperty, options: ISurveyCreatorOptions, context?: string) => any,
|
|
3787
|
+
onCreated: (obj: Base, question: Question, prop: JsonObjectProperty, options: ISurveyCreatorOptions) => any,
|
|
3788
|
+
onAfterRenderQuestion: (obj: Base, prop: JsonObjectProperty, evtOptions: any) => void,
|
|
3789
|
+
onMatrixCellCreated: (obj: Base, prop: JsonObjectProperty, options: any) => void,
|
|
3790
|
+
onMatrixCellValueChanged: (obj: Base, prop: JsonObjectProperty, options: any) => void,
|
|
3791
|
+
onMatrixAllowRemoveRow: (obj: Base, prop: JsonObjectProperty, row: MatrixDynamicRowModel) => boolean,
|
|
3792
|
+
onGetMatrixRowAction: (obj: Base, prop: JsonObjectProperty, options: any, setObjFunc: any) => any,
|
|
3793
|
+
onUpdateQuestionCssClasses: (obj: Base, prop: JsonObjectProperty, options: any) => void,
|
|
3794
|
+
onGetQuestionTitleActions: (obj: Base, prop: JsonObjectProperty, options: any) => void,
|
|
3795
|
+
onValueChanged: (obj: Base, prop: JsonObjectProperty, question: Question) => void,
|
|
3796
|
+
onMasterValueChanged: (obj: Base, prop: JsonObjectProperty, question: Question) => void,
|
|
3733
3797
|
};
|
|
3734
3798
|
export declare var translationCss: {
|
|
3735
3799
|
root: string,
|
|
@@ -4218,6 +4282,7 @@ export declare var logicCss: {
|
|
|
4218
4282
|
controlDisabled: string,
|
|
4219
4283
|
controlLabel: string,
|
|
4220
4284
|
materialDecorator: string,
|
|
4285
|
+
controlValue: string,
|
|
4221
4286
|
},
|
|
4222
4287
|
imagepicker: {
|
|
4223
4288
|
root: string,
|