survey-react 1.9.132 → 1.9.134

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/survey.react.d.ts CHANGED
@@ -1402,6 +1402,7 @@ declare module "defaultCss/defaultV2Css" {
1402
1402
  progressText: string;
1403
1403
  progressButtonsRoot: string;
1404
1404
  progressButtonsNumbered: string;
1405
+ progressButtonsFitSurveyWidth: string;
1405
1406
  progressButtonsContainerCenter: string;
1406
1407
  progressButtonsContainer: string;
1407
1408
  progressButtonsConnector: string;
@@ -1871,6 +1872,7 @@ declare module "defaultCss/defaultV2Css" {
1871
1872
  chooseFileAsIcon: string;
1872
1873
  chooseFileIconId: string;
1873
1874
  disabled: string;
1875
+ controlDisabled: string;
1874
1876
  removeButton: string;
1875
1877
  removeButtonBottom: string;
1876
1878
  removeButtonIconId: string;
@@ -5127,6 +5129,7 @@ declare module "dragdrop/core" {
5127
5129
  protected domAdapter: IDragDropDOMAdapter;
5128
5130
  constructor(surveyValue?: ISurvey, creator?: any, longTap?: boolean, domAdapter?: IDragDropDOMAdapter);
5129
5131
  startDrag(event: PointerEvent, draggedElement: any, parentElement?: any, draggedElementNode?: HTMLElement, preventSaveTargetNode?: boolean): void;
5132
+ private getRootElement;
5130
5133
  dragInit(event: PointerEvent, draggedElement: any, parentElement?: any, draggedElementNode?: HTMLElement): void;
5131
5134
  protected onStartDrag(event?: PointerEvent): void;
5132
5135
  protected isDropTargetDoesntChanged(newIsBottom: boolean): boolean;
@@ -8063,12 +8066,64 @@ declare module "question_textbase" {
8063
8066
  onKeyDownPreprocess: (event: any) => void;
8064
8067
  }
8065
8068
  }
8069
+ declare module "mask/mask_utils" {
8070
+ export var numberDefinition: RegExp;
8071
+ export interface IMaskedInputResult {
8072
+ value: string;
8073
+ caretPosition: number;
8074
+ cancelPreventDefault?: boolean;
8075
+ }
8076
+ export interface ITextInputParams {
8077
+ prevValue: string;
8078
+ selectionStart: number;
8079
+ selectionEnd: number;
8080
+ insertedChars: string | null;
8081
+ inputDirection?: "forward" | "backward";
8082
+ }
8083
+ export interface IInputMask {
8084
+ getMaskedValue(src: any): string;
8085
+ getUnmaskedValue(src: string): any;
8086
+ processInput(args: ITextInputParams): IMaskedInputResult;
8087
+ }
8088
+ }
8089
+ declare module "mask/mask_base" {
8090
+ import { Base } from "base";
8091
+ import { IInputMask, IMaskedInputResult, ITextInputParams } from "mask/mask_utils";
8092
+ export class InputMaskBase extends Base implements IInputMask {
8093
+ saveMaskedValue: boolean;
8094
+ getType(): string;
8095
+ setData(json: any): void;
8096
+ getData(): any;
8097
+ processInput(args: ITextInputParams): IMaskedInputResult;
8098
+ getUnmaskedValue(src: string): any;
8099
+ getMaskedValue(src: any): string;
8100
+ }
8101
+ }
8102
+ declare module "mask/input_element_adapter" {
8103
+ import { InputMaskBase } from "mask/mask_base";
8104
+ import { ITextInputParams } from "mask/mask_utils";
8105
+ export class InputElementAdapter {
8106
+ private inputMaskInstance;
8107
+ private inputElement;
8108
+ private prevUnmaskedValue;
8109
+ constructor(inputMaskInstance: InputMaskBase, inputElement: HTMLInputElement, value?: string);
8110
+ inputMaskInstancePropertyChangedHandler: (sender: any, options: any) => void;
8111
+ beforeInputHandler: (event: any) => void;
8112
+ blurInputHandler: (event: any) => void;
8113
+ createArgs(event: any): ITextInputParams;
8114
+ addInputEventListener(): void;
8115
+ removeInputEventListener(): void;
8116
+ dispose(): void;
8117
+ }
8118
+ }
8066
8119
  declare module "question_text" {
8067
8120
  import { LocalizableString, LocalizableStrings } from "localizablestring";
8068
8121
  import { HashTable } from "helpers";
8069
8122
  import { SurveyError } from "survey-error";
8070
8123
  import { QuestionTextBase } from "question_textbase";
8071
8124
  import { CssClassBuilder } from "utils/cssClassBuilder";
8125
+ import { InputMaskBase } from "mask/mask_base";
8126
+ import { IInputMask } from "mask/mask_utils";
8072
8127
  /**
8073
8128
  * A class that describes the Single-Line Input question type.
8074
8129
  *
@@ -8078,6 +8133,17 @@ declare module "question_text" {
8078
8133
  private locDataListValue;
8079
8134
  private minValueRunner;
8080
8135
  private maxValueRunner;
8136
+ private maskInputAdapter;
8137
+ private createMaskAdapter;
8138
+ private deleteMaskAdapter;
8139
+ private updateMaskAdapter;
8140
+ onSetMaskType(newValue: string): void;
8141
+ maskType: string;
8142
+ get maskTypeIsEmpty(): boolean;
8143
+ get maskSettings(): InputMaskBase;
8144
+ set maskSettings(val: InputMaskBase);
8145
+ private setNewMaskSettingsProperty;
8146
+ protected createMaskSettings(): InputMaskBase;
8081
8147
  constructor(name: string);
8082
8148
  protected isTextValue(): boolean;
8083
8149
  getType(): string;
@@ -8154,6 +8220,9 @@ declare module "question_text" {
8154
8220
  * @see max
8155
8221
  */
8156
8222
  get isMinMaxType(): boolean;
8223
+ get maskInstance(): IInputMask;
8224
+ get inputValue(): string;
8225
+ set inputValue(val: string);
8157
8226
  protected onCheckForErrors(errors: Array<SurveyError>, isOnValueChanged: boolean): void;
8158
8227
  protected canSetValueToSurvey(): boolean;
8159
8228
  protected convertFuncValuetoQuestionValue(val: any): any;
@@ -8193,6 +8262,8 @@ declare module "question_text" {
8193
8262
  onChange: (event: any) => void;
8194
8263
  onBlur: (event: any) => void;
8195
8264
  onFocus: (event: any) => void;
8265
+ afterRenderQuestionElement(el: HTMLElement): void;
8266
+ beforeDestroyQuestionElement(el: HTMLElement): void;
8196
8267
  }
8197
8268
  export function isMinMaxType(obj: any): boolean;
8198
8269
  }
@@ -8605,6 +8676,8 @@ declare module "progress-buttons" {
8605
8676
  isCanShowItemTitles(element: HTMLElement): boolean;
8606
8677
  clearConnectorsWidth(element: HTMLElement): void;
8607
8678
  adjustConnectors(element: HTMLElement): void;
8679
+ get isFitToSurveyWidth(): boolean;
8680
+ get progressWidth(): string;
8608
8681
  get showItemNumbers(): boolean;
8609
8682
  get showItemTitles(): boolean;
8610
8683
  getItemNumber(page: PageModel): string;
@@ -9911,8 +9984,8 @@ declare module "survey" {
9911
9984
  setIsMobile(newVal?: boolean): void;
9912
9985
  get isMobile(): boolean;
9913
9986
  private _isCompact;
9914
- private set isCompact(value);
9915
- private get isCompact();
9987
+ set isCompact(newVal: boolean);
9988
+ get isCompact(): boolean;
9916
9989
  protected isLogoImageChoosen(): string;
9917
9990
  get titleMaxWidth(): string;
9918
9991
  /**
@@ -10126,6 +10199,7 @@ declare module "survey" {
10126
10199
  *
10127
10200
  * Default value: `false`
10128
10201
  * @see progressBarShowPageNumbers
10202
+ * @see progressBarInheritWidthFrom
10129
10203
  */
10130
10204
  progressBarShowPageTitles: boolean;
10131
10205
  /**
@@ -10133,8 +10207,22 @@ declare module "survey" {
10133
10207
  *
10134
10208
  * Default value: `false`
10135
10209
  * @see progressBarShowPageTitles
10210
+ * @see progressBarInheritWidthFrom
10136
10211
  */
10137
10212
  progressBarShowPageNumbers: boolean;
10213
+ /**
10214
+ * Specifies whether the progress bar spans the width of the survey or that of the survey container. Applies only when the [progress bar is visible](https://surveyjs.io/form-library/documentation/api-reference/survey-data-model#showProgressBar) and [`progressBarType`](https://surveyjs.io/form-library/documentation/api-reference/survey-data-model#progressBarType) is `"pages"`.
10215
+ *
10216
+ * Possible values:
10217
+ *
10218
+ * - `"survey"`\
10219
+ * The progress bar width is the same as the survey width.
10220
+ * - `"container"` (default)\
10221
+ * The progress bar width is the same as the survey container width.
10222
+ * @see progressBarShowPageTitles
10223
+ * @see progressBarShowPageNumbers
10224
+ */
10225
+ progressBarInheritWidthFrom: "survey" | "container";
10138
10226
  get isShowProgressBarOnTop(): boolean;
10139
10227
  get isShowProgressBarOnBottom(): boolean;
10140
10228
  getProgressTypeComponent(): string;
@@ -10646,10 +10734,10 @@ declare module "survey" {
10646
10734
  private onShowingPreviewChanged;
10647
10735
  private changeCurrentPageFromPreview;
10648
10736
  private originalPages;
10649
- protected onQuestionsOnPageModeChanged(oldValue: string): void;
10737
+ protected onQuestionsOnPageModeChanged(oldValue: string, isFirstLoad?: boolean): void;
10650
10738
  private restoreOriginalPages;
10651
10739
  private getPageStartIndex;
10652
- private isCreatingPagesForPreview;
10740
+ private isLockingUpdateOnPageModes;
10653
10741
  private setupPagesForPageModes;
10654
10742
  private createPagesForQuestionOnPageMode;
10655
10743
  private createSinglePage;
@@ -11559,6 +11647,7 @@ declare module "survey-element" {
11559
11647
  isDragMe: boolean;
11560
11648
  readOnlyChangedCallback: () => void;
11561
11649
  static ScrollElementToTop(elementId: string, scrollIfVisible?: boolean): boolean;
11650
+ private static ScrollElementToViewCore;
11562
11651
  static GetFirstNonTextElement(elements: any, removeSpaces?: boolean): any;
11563
11652
  static FocusElement(elementId: string): boolean;
11564
11653
  private static focusElementCore;
@@ -15352,6 +15441,13 @@ declare module "settings" {
15352
15441
  dataList: string[];
15353
15442
  };
15354
15443
  legacyProgressBarView: boolean;
15444
+ maskSettings: {
15445
+ patternPlaceholderChar: string;
15446
+ patternEscapeChar: string;
15447
+ patternDefinitions: {
15448
+ [key: string]: RegExp;
15449
+ };
15450
+ };
15355
15451
  };
15356
15452
  }
15357
15453
  declare module "question_matrixdropdown" {
@@ -17358,6 +17454,114 @@ declare module "question_buttongroup" {
17358
17454
  onChange(): void;
17359
17455
  }
17360
17456
  }
17457
+ declare module "mask/mask_pattern" {
17458
+ import { InputMaskBase } from "mask/mask_base";
17459
+ import { IMaskedInputResult, ITextInputParams } from "mask/mask_utils";
17460
+ import { ILoadFromJSONOptions } from "base-interfaces";
17461
+ export interface IMaskLiteral {
17462
+ type: "const" | "regex" | "fixed";
17463
+ value: any;
17464
+ }
17465
+ export function getLiterals(pattern: string): Array<IMaskLiteral>;
17466
+ export function getMaskedValueByPattern(src: string, pattern: string | Array<IMaskLiteral>, matchWholeMask: boolean): string;
17467
+ export function getUnmaskedValueByPattern(str: string, pattern: string | Array<IMaskLiteral>, matchWholeMask: boolean, skipFixedChar?: boolean): string;
17468
+ export class InputMaskPattern extends InputMaskBase {
17469
+ private literals;
17470
+ pattern: string;
17471
+ protected updateLiterals(): void;
17472
+ protected onPropertyValueChanged(name: string, oldValue: any, newValue: any): void;
17473
+ getType(): string;
17474
+ fromJSON(json: any, options?: ILoadFromJSONOptions): void;
17475
+ _getMaskedValue(src: string, matchWholeMask?: boolean): string;
17476
+ _getUnmaskedValue(src: string, matchWholeMask?: boolean): string;
17477
+ processInput(args: ITextInputParams): IMaskedInputResult;
17478
+ getMaskedValue(src: any): string;
17479
+ getUnmaskedValue(src: string): any;
17480
+ }
17481
+ }
17482
+ declare module "mask/mask_numeric" {
17483
+ import { InputMaskBase } from "mask/mask_base";
17484
+ import { IMaskedInputResult, ITextInputParams } from "mask/mask_utils";
17485
+ interface INumericalComposition {
17486
+ integralPart: string;
17487
+ fractionalPart: string;
17488
+ isNegative?: boolean;
17489
+ hasDecimalSeparator?: boolean;
17490
+ }
17491
+ export function splitString(str: string, reverse?: boolean, n?: number): Array<string>;
17492
+ export class InputMaskNumeric extends InputMaskBase {
17493
+ allowNegativeValues: boolean;
17494
+ decimalSeparator: string;
17495
+ precision: number;
17496
+ thousandsSeparator: string;
17497
+ min: number;
17498
+ max: number;
17499
+ private calccaretPosition;
17500
+ displayNumber(parsedNumber: INumericalComposition, insertThousandsSeparator?: boolean, matchWholeMask?: boolean): string;
17501
+ convertNumber(parsedNumber: INumericalComposition): number;
17502
+ validateNumber(number: INumericalComposition): boolean;
17503
+ parseNumber(src: string | number): INumericalComposition;
17504
+ getNumberMaskedValue(src: string | number, matchWholeMask?: boolean): string;
17505
+ private getNumberUnmaskedValue;
17506
+ getMaskedValue(src: any): string;
17507
+ getUnmaskedValue(src: string): any;
17508
+ processInput(args: ITextInputParams): IMaskedInputResult;
17509
+ getType(): string;
17510
+ protected isPropertyEmpty(value: any): boolean;
17511
+ }
17512
+ }
17513
+ declare module "mask/mask_datetime" {
17514
+ import { InputMaskPattern } from "mask/mask_pattern";
17515
+ import { IMaskedInputResult, ITextInputParams } from "mask/mask_utils";
17516
+ export interface IDateTimeMaskLexem {
17517
+ type: "month" | "day" | "year" | "separator";
17518
+ value: any;
17519
+ count: number;
17520
+ maxCount: number;
17521
+ }
17522
+ export function getDateTimeLexems(pattern: string): Array<IDateTimeMaskLexem>;
17523
+ export class InputMaskDateTime extends InputMaskPattern {
17524
+ private turnOfTheCentury;
17525
+ private lexems;
17526
+ private inputDateTimeData;
17527
+ min: string;
17528
+ max: string;
17529
+ getType(): string;
17530
+ protected updateLiterals(): void;
17531
+ private leaveOnlyNumbers;
17532
+ private getMaskedStrFromISO;
17533
+ private initInputDateTimeData;
17534
+ private getISO_8601Format;
17535
+ private isYearValid;
17536
+ private isDateValid;
17537
+ private getPlaceholder;
17538
+ private updateInputDateTimeData;
17539
+ private getCorrectDatePartFormat;
17540
+ private createIDateTimeComposition;
17541
+ private parseTwoDigitYear;
17542
+ private getFormatedString;
17543
+ private setInputDateTimeData;
17544
+ _getMaskedValue(src: string, matchWholeMask?: boolean): string;
17545
+ private getPartsOld;
17546
+ private getParts;
17547
+ getUnmaskedValue(src: string): any;
17548
+ getMaskedValue(src: string): string;
17549
+ processInput(args: ITextInputParams): IMaskedInputResult;
17550
+ }
17551
+ }
17552
+ declare module "mask/mask_currency" {
17553
+ import { InputMaskNumeric } from "mask/mask_numeric";
17554
+ import { IMaskedInputResult, ITextInputParams } from "mask/mask_utils";
17555
+ export class InputMaskCurrency extends InputMaskNumeric {
17556
+ prefix: string;
17557
+ suffix: string;
17558
+ getType(): string;
17559
+ private wrapText;
17560
+ unwrapInputArgs(args: ITextInputParams): void;
17561
+ processInput(args: ITextInputParams): IMaskedInputResult;
17562
+ getMaskedValue(src: any): string;
17563
+ }
17564
+ }
17361
17565
  declare module "entries/chunks/model" {
17362
17566
  export var Version: string;
17363
17567
  export var ReleaseDate: string;
@@ -17450,6 +17654,11 @@ declare module "entries/chunks/model" {
17450
17654
  export { QuestionButtonGroupModel, ButtonGroupItemModel, ButtonGroupItemValue } from "question_buttongroup";
17451
17655
  export { IsMobile, IsTouch, _setIsTouch } from "utils/devices";
17452
17656
  export { confirmAction, confirmActionAsync, detectIEOrEdge, doKey2ClickUp, doKey2ClickDown, doKey2ClickBlur, loadFileFromBase64, increaseHeightByContent, createSvg, chooseFiles, sanitizeEditableContent, IAttachKey2clickOptions } from "utils/utils";
17657
+ export { InputMaskBase } from "mask/mask_base";
17658
+ export { InputMaskPattern } from "mask/mask_pattern";
17659
+ export { InputMaskNumeric } from "mask/mask_numeric";
17660
+ export { InputMaskDateTime } from "mask/mask_datetime";
17661
+ export { InputMaskCurrency } from "mask/mask_currency";
17453
17662
  export * from "utils/cssClassBuilder";
17454
17663
  export { surveyCss, defaultV2Css, defaultV2ThemeName } from "defaultCss/defaultV2Css";
17455
17664
  export { DragDropCore } from "dragdrop/core";
@@ -17661,6 +17870,7 @@ declare module "defaultCss/cssstandard" {
17661
17870
  headerCell: string;
17662
17871
  row: string;
17663
17872
  rowAdditional: string;
17873
+ rowTextCell: string;
17664
17874
  detailRow: string;
17665
17875
  detailRowText: string;
17666
17876
  detailCell: string;
@@ -18187,6 +18397,7 @@ declare module "defaultCss/cssmodern" {
18187
18397
  cell: string;
18188
18398
  headerCell: string;
18189
18399
  row: string;
18400
+ rowTextCell: string;
18190
18401
  rowAdditional: string;
18191
18402
  detailRow: string;
18192
18403
  detailRowText: string;
@@ -25087,6 +25298,7 @@ declare module "react/components/action-bar/action-bar" {
25087
25298
  get model(): ActionContainer<Action>;
25088
25299
  componentDidMount(): void;
25089
25300
  componentWillUnmount(): void;
25301
+ componentDidUpdate(prevProps: IActionBarProps, prevState: any): void;
25090
25302
  protected getStateElement(): Base;
25091
25303
  renderElement(): any;
25092
25304
  renderItems(): JSX.Element[];
@@ -25885,6 +26097,8 @@ declare module "react/reactquestion_text" {
25885
26097
  constructor(props: any);
25886
26098
  protected renderInput(): JSX.Element;
25887
26099
  protected renderElement(): JSX.Element;
26100
+ protected setValueCore(newValue: any): void;
26101
+ protected getValueCore(): any;
25888
26102
  private renderDataList;
25889
26103
  }
25890
26104
  }