survey-creator-core 1.9.97 → 1.9.99

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.
@@ -9,8 +9,10 @@ export declare class PageAdorner extends SurveyElementAdornerBase<PageModel> {
9
9
  questionTypeSelectorModel: any;
10
10
  currentAddQuestionType: string;
11
11
  dragTypeOverMe: DragTypeOverMeEnum;
12
+ private updateDragTypeOverMe;
12
13
  constructor(creator: CreatorBase, page: PageModel);
13
14
  protected attachElement(surveyElement: PageModel): void;
15
+ protected detachElement(surveyElement: PageModel): void;
14
16
  protected onElementSelectedChanged(isSelected: boolean): void;
15
17
  private patchPageForDragDrop;
16
18
  dispose(): void;
@@ -1 +1,7 @@
1
- export {};
1
+ import { IQuestion } from "survey-core";
2
+ export declare function elementSettingsToCssVariable(question: IQuestion, themeCssVariables: {
3
+ [index: string]: string;
4
+ }): void;
5
+ export declare function elementSettingsFromCssVariable(question: IQuestion, themeCssVariables: {
6
+ [index: string]: string;
7
+ }, defaultBackcolorVariable: string, defaultHovercolorVariable: string): any;
@@ -1 +1,8 @@
1
+ import { IQuestion } from "survey-core";
1
2
  export declare const DefaultFonts: string[];
3
+ export declare function fontsettingsToCssVariable(question: IQuestion, themeCssVariables: {
4
+ [index: string]: string;
5
+ }): void;
6
+ export declare function fontsettingsFromCssVariable(question: IQuestion, themeCssVariables: {
7
+ [index: string]: string;
8
+ }, defaultColorVariable?: string): any;
@@ -25,7 +25,7 @@ export declare const PredefinedColors: {
25
25
  };
26
26
  export interface ICreatorTheme extends ITheme {
27
27
  themeName?: string;
28
- themePalette?: string;
28
+ colorPalette?: string;
29
29
  }
30
30
  export declare class ThemeSurveyTabViewModel extends Base {
31
31
  private surveyProvider;
@@ -72,6 +72,7 @@ export declare class ThemeSurveyTabViewModel extends Base {
72
72
  importFromFile(file: File): void;
73
73
  setThemeFromFile(theme: ITheme): void;
74
74
  setJSON(json: any, currTheme: any): void;
75
+ private blockThemeChangedNotifications;
75
76
  initialize(json: any, options: any): void;
76
77
  private updatePageItem;
77
78
  private getCurrentPageItem;
@@ -162,6 +162,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
162
162
  * - `"portrait"`
163
163
  */
164
164
  previewOrientation: "landscape" | "portrait";
165
+ startEditTitleOnQuestionAdded: boolean;
165
166
  private isRTLValue;
166
167
  private alwaySaveTextInPropertyEditorsValue;
167
168
  private toolbarValue;
@@ -185,6 +186,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
185
186
  private newQuestionChangedNames;
186
187
  private selectionHistoryControllerValue;
187
188
  private saveSurveyFuncValue;
189
+ private saveThemeFuncValue;
188
190
  viewType: string;
189
191
  /**
190
192
  * Returns the current show view name. The possible returns values are:
@@ -501,6 +503,22 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
501
503
  *- options.title the default value of the title. You can change the default value.
502
504
  */
503
505
  onConditionGetTitle: CreatorEvent;
506
+ /**
507
+ * An event that is raised when Survey Creator populates a condition editor with operators. Use this event to hide individual condition operators.
508
+ *
509
+ * Parameters:
510
+ *
511
+ * - `sender`: `CreatorBase`\
512
+ * A Survey Creator instance that raised the event.
513
+ * - `options.questionName`: `String`\
514
+ * The name of a question for which conditions are displayed.
515
+ * - `options.operator`: `"empty"` | `"notempty"` | `"equal"` | `"notequal"` | `"contains"` | `"notcontains"` | `"anyof"` | `"allof"` | `"greater"` | `"less"` | `"greaterorequal"` | `"lessorequal"`\
516
+ * A condition opeator for which the event is raised.
517
+ * - `options.show`: `Boolean`\
518
+ * A Boolean property that you can set to `false` if you want to hide the condition operator.
519
+ *
520
+ */
521
+ onGetConditionOperator: CreatorEvent;
504
522
  /**
505
523
  * Use this event to modify the display text of a logic item in the Logic tab.
506
524
  *
@@ -845,7 +863,12 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
845
863
  * Default value: `"defaultV2"`
846
864
  */
847
865
  themeForPreview: string;
848
- theme: ITheme;
866
+ hasPendingThemeChanges: boolean;
867
+ isThemePristine: boolean;
868
+ private _theme;
869
+ get theme(): ITheme;
870
+ set theme(newTheme: ITheme);
871
+ raiseThemeChanged(): void;
849
872
  private _allowModifyPages;
850
873
  /**
851
874
  * Specifies whether users can add, edit, and delete survey pages.
@@ -1346,6 +1369,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
1346
1369
  onGetElementEditorTitleCallback(obj: Base, title: string): string;
1347
1370
  onConditionQuestionsGetListCallback(propertyName: string, obj: Base, editor: any, list: any[]): string;
1348
1371
  onConditionGetTitleCallback(expression: string, title: string): string;
1372
+ isConditionOperatorEnabled(questionName: string, operator: string, isEnabled: boolean): boolean;
1349
1373
  onLogicGetTitleCallback(expression: string, expressionText: string, text: string, logicItem: any): string;
1350
1374
  getProcessedTranslationItemText(locale: string, locString: ILocalizableString, newText: string, obj: any): string;
1351
1375
  getTranslationExportedText(obj: Base, name: string, locString: ILocalizableString, locale: string, text: string): string;
@@ -1356,9 +1380,16 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
1356
1380
  */
1357
1381
  autoSaveDelay: number;
1358
1382
  private autoSaveTimerId;
1359
- protected doAutoSave(): void;
1383
+ protected doAutoSave(saveFunc?: () => void): void;
1360
1384
  saveNo: number;
1361
1385
  doSave(): void;
1386
+ doSaveTheme(): void;
1387
+ /**
1388
+ * Assign to this property a function that will be called on clicking the 'Save' button or on any change if isAutoSave equals true.
1389
+ * @see isAutoSave
1390
+ */
1391
+ get saveThemeFunc(): any;
1392
+ set saveThemeFunc(value: any);
1362
1393
  showSaveButton: boolean;
1363
1394
  /**
1364
1395
  * Assign to this property a function that will be called on clicking the 'Save' button or on any change if isAutoSave equals true.
@@ -134,6 +134,7 @@ export declare var settings: {
134
134
  */
135
135
  dragDrop: {
136
136
  restrictDragQuestionBetweenPages: boolean;
137
+ allowDragToTheSameLine: boolean;
137
138
  };
138
139
  /**
139
140
  * Creator layout settings
@@ -186,6 +187,7 @@ export interface ISurveyCreatorOptions {
186
187
  createSurvey(json: any, reason: string, surveyType?: new (json: any) => SurveyModel): any;
187
188
  onConditionQuestionsGetListCallback(propertyName: string, obj: Base, editor: any, list: any[]): string;
188
189
  onConditionGetTitleCallback(expression: string, title: string): string;
190
+ isConditionOperatorEnabled(questionName: string, operator: string, isEnabled: boolean): boolean;
189
191
  onLogicGetTitleCallback(expression: string, displayExpression: string, text: string, logicItem: any): string;
190
192
  getProcessedTranslationItemText(locale: string, locString: ILocalizableString, newText: string, obj: any): string;
191
193
  getTranslationExportedText(obj: Base, name: string, locString: ILocalizableString, locale: string, text: string): string;
@@ -226,6 +228,7 @@ export declare class EmptySurveyCreatorOptions implements ISurveyCreatorOptions
226
228
  createSurvey(json: any, reason: string, surveyType?: new (json: any) => SurveyModel): SurveyModel;
227
229
  onConditionQuestionsGetListCallback(propertyName: string, obj: Base, editor: any, list: any[]): string;
228
230
  onConditionGetTitleCallback(expression: string, title: string): string;
231
+ isConditionOperatorEnabled(questionName: string, operator: string, isEnabled: boolean): boolean;
229
232
  onLogicGetTitleCallback(expression: string, displayExpression: string, text: string, logicItem: any): string;
230
233
  getTranslationExportedText(obj: Base, name: string, locString: ILocalizableString, locale: string, text: string): string;
231
234
  uploadFiles(files: File[], question: Question, uploadingCallback: (status: string, data: any) => any): void;
@@ -11,6 +11,7 @@ export declare class QuestionColorModel extends QuestionTextModel {
11
11
  private resetRenderedValue;
12
12
  private updateRenderedValue;
13
13
  get renderedValue(): string;
14
+ getSwatchCss(): string;
14
15
  getSwatchStyle(): {
15
16
  [index: string]: string;
16
17
  };
@@ -12,4 +12,5 @@ export declare class QuestionFileEditorModel extends QuestionFileModel {
12
12
  onInputBlur(event: Event): void;
13
13
  getType(): string;
14
14
  getIsClearButtonDisabled(): boolean;
15
+ getChooseButtonCss(): string;
15
16
  }
@@ -877,6 +877,7 @@ export declare var defaultStrings: {
877
877
  };
878
878
  pehelp: {
879
879
  cookieName: string;
880
+ size: string;
880
881
  format: string;
881
882
  totalText: string;
882
883
  acceptedTypes: string;
@@ -848,6 +848,7 @@ export declare var enStrings: {
848
848
  };
849
849
  pehelp: {
850
850
  cookieName: string;
851
+ size: string;
851
852
  format: string;
852
853
  totalText: string;
853
854
  acceptedTypes: string;
@@ -80,6 +80,7 @@ export declare class ConditionEditor extends PropertyEditorSetupValue {
80
80
  private setupConditionQuestionName;
81
81
  private setupRemoveQuestion;
82
82
  private setItemToPanel;
83
+ private updateSurveyVariable;
83
84
  private getConditionQuestions;
84
85
  private getText;
85
86
  private getEditorItems;
@@ -128,6 +128,7 @@ export declare class PropertyGridModel {
128
128
  protected createSurvey(json: any): SurveyModel;
129
129
  protected getSurveyJSON(): any;
130
130
  private validateQuestionValue;
131
+ private getErrorTextOnValidate;
131
132
  private onValidateQuestion;
132
133
  private onValueChanging;
133
134
  private isPropNameInValid;
@@ -329,6 +329,7 @@ export declare var propertyGridCss: {
329
329
  color: {
330
330
  root: string;
331
331
  swatch: string;
332
+ swatchDisabled: string;
332
333
  colorInput: string;
333
334
  control: string;
334
335
  colorDropdown: string;
@@ -345,6 +346,7 @@ export declare var propertyGridCss: {
345
346
  fileInput: string;
346
347
  clearButton: string;
347
348
  chooseButton: string;
349
+ chooseButtonDisabled: string;
348
350
  };
349
351
  linkvalue: {
350
352
  content: string;
@@ -29,7 +29,7 @@ export declare function parseColor(value: string): {
29
29
  };
30
30
  export declare function HSBToRGB(h: any, s: any, b: any): number[];
31
31
  export declare function RGBToHSB(r: any, g: any, b: any): number[];
32
- export declare function assign(...objects: Array<any>): void;
32
+ export declare function assign(...inputs: Array<any>): void;
33
33
  export declare class ColorCalculator {
34
34
  colorSettings: {
35
35
  baseColorAlpha: number;