survey-react 1.9.31 → 1.9.32

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
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Type definition for Survey JavaScript library for React v1.9.31
2
+ * Type definition for Survey JavaScript library for React v1.9.32
3
3
  * Copyright (c) 2015-2022 Devsoft Baltic OÜ - https://surveyjs.io/
4
4
  * License: MIT (http://www.opensource.org/licenses/mit-license.php)
5
5
  */
@@ -654,6 +654,10 @@ export declare class Base {
654
654
  * - [*"text"*](https://surveyjs.io/Documentation/Library?id=questiontextmodel)
655
655
  */
656
656
  getType(): string;
657
+ /*
658
+ * Use this method to find out if the current instance is of the given `typeName` or inherited from it.
659
+ */
660
+ isDescendantOf(typeName: string): boolean;
657
661
  getSurvey(isLive?: boolean): ISurvey;
658
662
  /*
659
663
  * Returns true if the question in design mode right now.
@@ -743,6 +747,9 @@ export declare class Base {
743
747
  */
744
748
  unRegisterFunctionOnPropertiesValueChanged(names: any, key?: string): void;
745
749
  createCustomLocalizableObj(name: string): void;
750
+ getLocale(): string;
751
+ getLocalizationString(strName: string): string;
752
+ getLocalizationFormatString(strName: string, args: any): string;
746
753
  protected createLocalizableString(name: string, owner: ILocalizableOwner, useMarkDown?: boolean, defaultStr?: string | boolean): LocalizableString;
747
754
  getLocalizableString(name: string): LocalizableString;
748
755
  getLocalizableStringText(name: string, defaultStr?: string): string;
@@ -1305,6 +1312,8 @@ export declare class SurveyError {
1305
1312
  getText(): string;
1306
1313
  getErrorType(): string;
1307
1314
  protected getDefaultText(): string;
1315
+ protected getLocale(): string;
1316
+ protected getLocalizationString(locStrName: string): string;
1308
1317
  }
1309
1318
  export declare class SurveyHeader extends React.Component<ISurveyHeaderProps, any> {
1310
1319
  constructor(props: ISurveyHeaderProps);
@@ -2452,8 +2461,8 @@ export declare class PopupBaseViewModel extends Base {
2452
2461
  clickOutside(): void;
2453
2462
  cancel(): void;
2454
2463
  apply(): void;
2455
- get cancelButtonText(): any;
2456
- get applyButtonText(): any;
2464
+ get cancelButtonText(): string;
2465
+ get applyButtonText(): string;
2457
2466
  dispose(): void;
2458
2467
  initializePopupContainer(): void;
2459
2468
  unmountPopupContainer(): void;
@@ -2492,10 +2501,10 @@ export declare class PopupModel<T = any> extends Base {
2492
2501
  title: string;
2493
2502
  displayMode: "popup" | "overlay";
2494
2503
  widthMode: "contentWidth" | "fixedWidth";
2504
+ onVisibilityChanged: EventBase<PopupModel<any>>;
2495
2505
  get isVisible(): boolean;
2496
2506
  set isVisible(val: boolean);
2497
2507
  toggleVisibility(): void;
2498
- onVisibilityChanged: (isVisible: boolean) => void;
2499
2508
  }
2500
2509
  export declare class QuestionMatrixDropdownRenderedRow extends Base {
2501
2510
  constructor(cssClasses: any, isDetailRow?: boolean);
@@ -3132,7 +3141,7 @@ export declare class EmailValidator extends SurveyValidator {
3132
3141
  re: any;
3133
3142
  getType(): string;
3134
3143
  validate(value: any, name?: string, values?: any, properties?: any): ValidatorResult;
3135
- protected getDefaultErrorText(name: string): any;
3144
+ protected getDefaultErrorText(name: string): string;
3136
3145
  }
3137
3146
  /*
3138
3147
  * Show error if expression returns false
@@ -3147,7 +3156,7 @@ export declare class ExpressionValidator extends SurveyValidator {
3147
3156
  get isRunning(): boolean;
3148
3157
  validate(value: any, name?: string, values?: any, properties?: any): ValidatorResult;
3149
3158
  protected generateError(res: boolean, value: any, name: string): ValidatorResult;
3150
- protected getDefaultErrorText(name: string): any;
3159
+ protected getDefaultErrorText(name: string): string;
3151
3160
  protected ensureConditionRunner(): boolean;
3152
3161
  /*
3153
3162
  * The expression property.
@@ -3213,7 +3222,7 @@ export declare class ListModel extends ActionContainer {
3213
3222
  isItemSelected: (itemValue: Action) => boolean;
3214
3223
  getItemClass: (itemValue: Action) => string;
3215
3224
  getItemIndent: (itemValue: any) => string;
3216
- get filteredTextPlaceholder(): any;
3225
+ get filteredTextPlaceholder(): string;
3217
3226
  onKeyDown(event: any): void;
3218
3227
  onPointerDown(event: any, item: any): void;
3219
3228
  refresh(): void;
@@ -3255,7 +3264,7 @@ export declare class NumericValidator extends SurveyValidator {
3255
3264
  constructor(minValue?: number, maxValue?: number);
3256
3265
  getType(): string;
3257
3266
  validate(value: any, name?: string, values?: any, properties?: any): ValidatorResult;
3258
- protected getDefaultErrorText(name: string): any;
3267
+ protected getDefaultErrorText(name: string): string;
3259
3268
  /*
3260
3269
  * The minValue property.
3261
3270
  */
@@ -3475,7 +3484,9 @@ export declare class SurveyElement extends SurveyElementCore implements ISurveyE
3475
3484
  protected setPage(parent: IPanel, newPage: IPage): void;
3476
3485
  protected getSearchableLocKeys(keys: any): void;
3477
3486
  protected get isDefaultV2Theme(): boolean;
3487
+ get showErrorsAboveQuestion(): boolean;
3478
3488
  get isErrorsModeTooltip(): boolean;
3489
+ protected getIsErrorsModeTooltip(): boolean;
3479
3490
  get hasParent(): boolean;
3480
3491
  protected get hasFrameV2(): boolean;
3481
3492
  /*
@@ -3550,7 +3561,6 @@ export declare class SurveyModel extends SurveyElementCore implements ISurvey, I
3550
3561
  valuesHash: any;
3551
3562
  variablesHash: any;
3552
3563
  editingObjValue: Base;
3553
- localeValue: string;
3554
3564
  textPreProcessor: TextPreProcessor;
3555
3565
  timerModelValue: SurveyTimerModel;
3556
3566
  navigationBarValue: any;
@@ -4445,7 +4455,7 @@ export declare class SurveyModel extends SurveyElementCore implements ISurvey, I
4445
4455
  getRendererContextForString(element: Base, locStr: LocalizableString): LocalizableString;
4446
4456
  getExpressionDisplayValue(question: IQuestion, value: any, displayValue: string): string;
4447
4457
  getProcessedText(text: string): string;
4448
- getLocString(str: string): any;
4458
+ getLocString(str: string): string;
4449
4459
  getErrorCustomText(text: string, error: SurveyError): string;
4450
4460
  getSurveyErrorCustomText(obj: Base, text: string, error: SurveyError): string;
4451
4461
  /*
@@ -5714,7 +5724,7 @@ export declare class TextValidator extends SurveyValidator {
5714
5724
  constructor();
5715
5725
  getType(): string;
5716
5726
  validate(value: any, name?: string, values?: any, properties?: any): ValidatorResult;
5717
- protected getDefaultErrorText(name: string): any;
5727
+ protected getDefaultErrorText(name: string): string;
5718
5728
  /*
5719
5729
  * The minLength property.
5720
5730
  */
@@ -5975,6 +5985,7 @@ export declare class PanelModelBase extends SurveyElement implements IPanel, ICo
5975
5985
  protected onAddElement(element: IElement, index: number): void;
5976
5986
  protected onRemoveElement(element: IElement): void;
5977
5987
  protected canRenderFirstRows(): boolean;
5988
+ protected getDragDropInfo(): any;
5978
5989
  protected updateRowsRemoveElementFromRow(element: IElement, row: QuestionRowModel): void;
5979
5990
  elementWidthChanged(el: IElement): void;
5980
5991
  /*
@@ -6307,6 +6318,10 @@ export declare class Question extends SurveyElement implements IQuestion, ICondi
6307
6318
  get cssDescription(): string;
6308
6319
  protected setCssDescription(val: string): void;
6309
6320
  protected getCssDescription(cssClasses: any): string;
6321
+ protected getIsErrorsModeTooltip(): boolean;
6322
+ showErrorOnCore(location: string): boolean;
6323
+ get showErrorOnTop(): boolean;
6324
+ get showErrorOnBottom(): boolean;
6310
6325
  get cssError(): string;
6311
6326
  protected setCssError(val: string): void;
6312
6327
  protected getCssError(cssClasses: any): string;
@@ -6325,6 +6340,7 @@ export declare class Question extends SurveyElement implements IQuestion, ICondi
6325
6340
  protected fireCallback(callback: any): void;
6326
6341
  getOthersMaxLength(): any;
6327
6342
  protected onCreating(): void;
6343
+ getFirstQuestionToFocus(withError: boolean): Question;
6328
6344
  protected getFirstInputElementId(): string;
6329
6345
  protected getFirstErrorInputElementId(): string;
6330
6346
  protected getProcessedTextValue(textValue: TextPreProcessorValue): void;
@@ -6653,6 +6669,7 @@ export declare class SurveyQuestionCustom extends SurveyQuestionUncontrolledElem
6653
6669
  }
6654
6670
  export declare class SurveyQuestionDropdownBase<T> extends SurveyQuestionUncontrolledElement<T> {
6655
6671
  constructor(props: any);
6672
+ onClick: (event: any) => void;
6656
6673
  protected setValueCore(newValue: any): void;
6657
6674
  protected getValueCore(): any;
6658
6675
  protected renderSelect(cssClasses: any): JSX.Element;
@@ -6849,6 +6866,7 @@ export declare class PageModel extends PanelModelBase implements IPage {
6849
6866
  protected onNumChanged(value: number): void;
6850
6867
  protected onVisibleChanged(): void;
6851
6868
  dragDropInfo: DragDropInfo;
6869
+ protected getDragDropInfo(): any;
6852
6870
  dragDropStart(src: IElement, target: IElement, nestedPanelDepth?: number): void;
6853
6871
  dragDropMoveTo(destination: ISurveyElement, isBottom?: boolean, isEdge?: boolean): boolean;
6854
6872
  dragDropFinish(isCancel?: boolean): IElement;
@@ -7457,6 +7475,7 @@ export declare class QuestionPanelDynamicModel extends Question implements IQues
7457
7475
  panelCountChangedCallback: any;
7458
7476
  currentIndexChangedCallback: any;
7459
7477
  get hasSingleInput(): boolean;
7478
+ getFirstQuestionToFocus(withError: boolean): Question;
7460
7479
  setSurveyImpl(value: ISurveyImpl, isLight?: boolean): void;
7461
7480
  getType(): string;
7462
7481
  get isCompositeQuestion(): boolean;
@@ -8280,7 +8299,6 @@ export declare class QuestionCompositeModel extends QuestionCustomModelBase {
8280
8299
  textProcessing: QuestionCompositeTextProcessor;
8281
8300
  protected createWrapper(): void;
8282
8301
  getTemplate(): string;
8283
- protected getCssType(): string;
8284
8302
  protected getElement(): SurveyElement;
8285
8303
  get contentPanel(): PanelModel;
8286
8304
  hasErrors(fireCallback?: boolean, rec?: any): boolean;
@@ -8331,6 +8349,8 @@ export declare class QuestionCustomModel extends QuestionCustomModelBase {
8331
8349
  */
8332
8350
  export declare class QuestionDropdownModel extends QuestionSelectBase {
8333
8351
  constructor(name: string);
8352
+ onOpened: EventBase<QuestionDropdownModel>;
8353
+ onOpenedCallBack(): void;
8334
8354
  /*
8335
8355
  * This flag controls whether to show options caption item ('Choose...').
8336
8356
  */
@@ -8630,6 +8650,7 @@ export declare class QuestionMatrixDropdownModelBase extends QuestionMatrixBaseM
8630
8650
  protected getIsRunningValidators(): boolean;
8631
8651
  getAllErrors(): Array<SurveyError>;
8632
8652
  protected getUniqueColumns(): Array<MatrixDropdownColumn>;
8653
+ getFirstQuestionToFocus(withError: boolean): Question;
8633
8654
  protected getFirstInputElementId(): string;
8634
8655
  protected getFirstErrorInputElementId(): string;
8635
8656
  protected getFirstCellQuestion(onError: boolean): Question;
@@ -9222,7 +9243,7 @@ export declare class QuestionRadiogroupModel extends QuestionCheckboxBase {
9222
9243
  get showClearButton(): boolean;
9223
9244
  set showClearButton(val: boolean);
9224
9245
  get canShowClearButton(): boolean;
9225
- get clearButtonCaption(): any;
9246
+ get clearButtonCaption(): string;
9226
9247
  supportGoNextPageAutomatic(): boolean;
9227
9248
  }
9228
9249
  /*
@@ -10813,6 +10834,7 @@ export declare var defaultV2Css: {
10813
10834
  cell: string,
10814
10835
  headerCell: string,
10815
10836
  rowTextCell: string,
10837
+ cellRequiredText: string,
10816
10838
  detailButton: string,
10817
10839
  detailButtonExpanded: string,
10818
10840
  detailIcon: string,
@@ -10832,6 +10854,7 @@ export declare var defaultV2Css: {
10832
10854
  cell: string,
10833
10855
  headerCell: string,
10834
10856
  rowTextCell: string,
10857
+ cellRequiredText: string,
10835
10858
  button: string,
10836
10859
  detailRow: string,
10837
10860
  detailButton: string,