survey-creator-core 1.9.90 → 1.9.91

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,7 +9,6 @@ export declare class SurveySimulatorModel extends Base {
9
9
  isRunning: boolean;
10
10
  simulatorEnabled: boolean;
11
11
  simulatorScaleEnabled: boolean;
12
- themeVariables: any;
13
12
  private currZoomScale;
14
13
  get zoomScale(): number;
15
14
  activateZoom: () => void;
@@ -53,6 +53,7 @@ export declare class StringEditorViewModelBase extends Base {
53
53
  onCompositionEnd(event: any): void;
54
54
  onBlur(event: any): void;
55
55
  done(event: Event): void;
56
+ onPaste(event: ClipboardEvent): void;
56
57
  onKeyDown(event: KeyboardEvent): boolean;
57
58
  onKeyUp(event: KeyboardEvent): boolean;
58
59
  private justFocused;
@@ -1,5 +1 @@
1
1
  export declare function createColor(value: any): string;
2
- export declare function parseColor(value: string): {
3
- color: string;
4
- opacity: number;
5
- };
@@ -10,6 +10,9 @@ export declare class TabThemePlugin implements ICreatorPlugin {
10
10
  private designerAction;
11
11
  private prevPageAction;
12
12
  private nextPageAction;
13
+ private importAction;
14
+ private exportAction;
15
+ private inputFileElement;
13
16
  private simulatorTheme;
14
17
  private sidebarTab;
15
18
  model: ThemeSurveyTabViewModel;
@@ -1,48 +1,13 @@
1
1
  import { SurveySimulatorModel } from "../simulator";
2
- import { Base, PageModel, SurveyModel, Action, IAction, ActionContainer } from "survey-core";
2
+ import { Base, PageModel, SurveyModel, Action, IAction, ActionContainer, ITheme } from "survey-core";
3
3
  import { CreatorBase } from "../../creator-base";
4
- export declare const Themes: {
5
- "default-light": {
6
- "--sjs-primary-backcolor": string;
7
- "--sjs-primary-backcolor-light": string;
8
- "--sjs-primary-backcolor-dark": string;
9
- "--background": string;
10
- "--background-dim": string;
11
- "--background-dim-light": string;
12
- "--sjs-general-forecolor": string;
13
- "--sjs-general-forecolor-light": string;
14
- "--sjs-general-dim-forecolor": string;
15
- "--sjs-general-dim-forecolor-light": string;
16
- "--sjs-editor-background": string;
17
- "--sjs-question-background": string;
18
- "--sjs-primary-forecolor": string;
19
- "--foreground": string;
20
- "--base-unit": string;
21
- "--sjs-corner-radius": string;
22
- };
23
- "default-dark": {
24
- "--sjs-primary-backcolor": string;
25
- "--sjs-primary-backcolor-light": string;
26
- "--sjs-primary-backcolor-dark": string;
27
- "--background": string;
28
- "--background-dim": string;
29
- "--background-dim-light": string;
30
- "--sjs-general-forecolor": string;
31
- "--sjs-general-forecolor-light": string;
32
- "--sjs-general-dim-forecolor": string;
33
- "--sjs-general-dim-forecolor-light": string;
34
- "--sjs-editor-background": string;
35
- "--sjs-question-background": string;
36
- "--sjs-primary-forecolor": string;
37
- "--foreground": string;
38
- "--base-unit": string;
39
- "--sjs-corner-radius": string;
40
- };
41
- };
4
+ export declare const Themes: any;
42
5
  export declare class ThemeSurveyTabViewModel extends Base {
43
6
  private surveyProvider;
44
7
  private startTheme;
45
8
  private json;
9
+ exportToFileUI: any;
10
+ importFromFileUI: any;
46
11
  pages: ActionContainer;
47
12
  prevPageAction: Action;
48
13
  testAgainAction: Action;
@@ -61,6 +26,7 @@ export declare class ThemeSurveyTabViewModel extends Base {
61
26
  themeName: any;
62
27
  themePalette: any;
63
28
  themeMode: any;
29
+ getFullThemeName(_themeName?: string): any;
64
30
  get themeVariables(): any;
65
31
  get activeLanguage(): string;
66
32
  set activeLanguage(val: string);
@@ -68,8 +34,12 @@ export declare class ThemeSurveyTabViewModel extends Base {
68
34
  get pageActions(): Array<Action>;
69
35
  get isPageToolbarVisible(): boolean;
70
36
  get themeEditorSurvey(): SurveyModel;
37
+ get currentTheme(): ITheme;
71
38
  constructor(surveyProvider: CreatorBase, startTheme?: any);
39
+ private loadTheme;
72
40
  updateSimulatorSurvey(json: any, theme: any): void;
41
+ exportToFile(fileName: string): void;
42
+ importFromFile(file: File): void;
73
43
  setJSON(json: any, currTheme: any): void;
74
44
  initialize(json: any, options: any): void;
75
45
  private updatePageItem;
@@ -88,5 +58,7 @@ export declare class ThemeSurveyTabViewModel extends Base {
88
58
  private updatePrevNextPageActionState;
89
59
  initializeColorCalculator(): void;
90
60
  protected createThemeEditorSurvey(): SurveyModel;
61
+ private loadThemeIntoPropertyGrid;
62
+ private setThemeToSurvey;
91
63
  private getThemeEditorSurveyJSON;
92
64
  }
@@ -1,5 +1,5 @@
1
1
  import * as Survey from "survey-core";
2
- import { Base, SurveyModel, Question, PageModel, IElement, JsonObjectProperty, ActionContainer, AdaptiveActionContainer, IAction, Action, IPanel, SurveyElement, ItemValue, QuestionSelectBase, LocalizableString, ILocalizableString, ILocalizableOwner, PopupBaseViewModel, EventBase } from "survey-core";
2
+ import { Base, SurveyModel, Question, PageModel, IElement, JsonObjectProperty, ActionContainer, AdaptiveActionContainer, IAction, Action, IPanel, SurveyElement, ItemValue, QuestionSelectBase, LocalizableString, ILocalizableString, ILocalizableOwner, PopupBaseViewModel, EventBase, ITheme } from "survey-core";
3
3
  import { ISurveyCreatorOptions, ICollectionItemAllowOperations } from "./creator-settings";
4
4
  import { DragDropChoices } from "survey-core";
5
5
  import { QuestionToolbox } from "./toolbox";
@@ -836,6 +836,7 @@ export declare class CreatorBase extends Base implements ISurveyCreatorOptions,
836
836
  * Default value: `"defaultV2"`
837
837
  */
838
838
  themeForPreview: string;
839
+ theme: ITheme;
839
840
  private _allowModifyPages;
840
841
  /**
841
842
  * Specifies whether users can add, edit, and delete survey pages.
@@ -19,6 +19,9 @@ export declare var settings: {
19
19
  */
20
20
  exportFileName: string;
21
21
  };
22
+ theme: {
23
+ exportFileName: string;
24
+ };
22
25
  operators: {
23
26
  empty: any[];
24
27
  notempty: any[];
@@ -100,6 +103,7 @@ export declare var settings: {
100
103
  choices: string[];
101
104
  };
102
105
  imagepicker: {
106
+ imageFit: string;
103
107
  choices: {
104
108
  value: string;
105
109
  imageLink: string;
@@ -1,6 +1,7 @@
1
- import { QuestionTextModel } from "survey-core";
1
+ import { Action, ItemValue, QuestionTextModel } from "survey-core";
2
2
  export declare class QuestionColorModel extends QuestionTextModel {
3
3
  unit: string;
4
+ constructor(name: string);
4
5
  private getCorrectedValue;
5
6
  protected setNewValue(newValue: string): void;
6
7
  onBeforeInput(event: InputEvent): void;
@@ -15,4 +16,12 @@ export declare class QuestionColorModel extends QuestionTextModel {
15
16
  };
16
17
  get isInputTextUpdate(): boolean;
17
18
  onSurveyValueChanged(newValue: any): void;
19
+ private _dropdownAction;
20
+ get dropdownAction(): Action;
21
+ get choices(): Array<ItemValue>;
22
+ set choices(newValue: Array<ItemValue>);
23
+ get showDropdownAction(): boolean;
24
+ createDropdownAction(): Action;
25
+ private updateChoices;
26
+ get itemComponent(): string;
18
27
  }
@@ -160,6 +160,8 @@ export declare var defaultStrings: {
160
160
  translationImportFromSCVButton: string;
161
161
  translationMergeLocaleWithDefault: string;
162
162
  translationPlaceHolder: string;
163
+ themeExportButton: string;
164
+ themeImportButton: string;
163
165
  bold: string;
164
166
  italic: string;
165
167
  underline: string;
@@ -218,6 +220,7 @@ export declare var defaultStrings: {
218
220
  column_requireText: string;
219
221
  trigger_completeText: string;
220
222
  trigger_setvalueText: string;
223
+ trigger_setvalueEmptyText: string;
221
224
  trigger_copyvalueText: string;
222
225
  trigger_skipText: string;
223
226
  trigger_runExpressionText1: string;
@@ -14,6 +14,8 @@ export * from "../components/tabs/test";
14
14
  export * from "../components/tabs/test-plugin";
15
15
  export * from "../components/tabs/theme-custom-questions/color-settings";
16
16
  export * from "../components/tabs/theme-custom-questions/boxshadow-settings";
17
+ export * from "../components/tabs/theme-custom-questions/font-settings";
18
+ export * from "../components/tabs/theme-custom-questions/element-settings";
17
19
  export * from "../components/tabs/theme";
18
20
  export * from "../components/tabs/theme-plugin";
19
21
  export * from "../components/tabs/logic";
@@ -131,6 +131,8 @@ export declare var enStrings: {
131
131
  translationImportFromSCVButton: string;
132
132
  translationMergeLocaleWithDefault: string;
133
133
  translationPlaceHolder: string;
134
+ themeExportButton: string;
135
+ themeImportButton: string;
134
136
  bold: string;
135
137
  italic: string;
136
138
  underline: string;
@@ -189,6 +191,7 @@ export declare var enStrings: {
189
191
  column_requireText: string;
190
192
  trigger_completeText: string;
191
193
  trigger_setvalueText: string;
194
+ trigger_setvalueEmptyText: string;
192
195
  trigger_copyvalueText: string;
193
196
  trigger_skipText: string;
194
197
  trigger_runExpressionText1: string;
@@ -328,7 +328,9 @@ export declare var propertyGridCss: {
328
328
  colorInput: string;
329
329
  control: string;
330
330
  colorDropdown: string;
331
- colorDrodownIcon: string;
331
+ colorDropdownIcon: string;
332
+ colorItem: string;
333
+ swatchIcon: string;
332
334
  };
333
335
  fileedit: {
334
336
  root: string;
@@ -23,6 +23,10 @@ export declare function getQuestionFromObj(obj: SurveyElement): Question;
23
23
  export declare function ingectAlpha(baseColor: any, alpha: number): any;
24
24
  export declare function convertRgbaToString(rgbValues: Array<number>, alpha: number): string;
25
25
  export declare function parseRgbaFromString(value: string): Array<number>;
26
+ export declare function parseColor(value: string): {
27
+ color: string;
28
+ opacity: number;
29
+ };
26
30
  export declare function HSBToRGB(h: any, s: any, b: any): number[];
27
31
  export declare function RGBToHSB(r: any, g: any, b: any): number[];
28
32
  export declare function assign(...objects: Array<any>): void;