survey-react 1.9.129 → 1.9.130
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/defaultV2.css +18 -4
- package/defaultV2.css.map +1 -1
- package/defaultV2.min.css +2 -2
- package/modern.css +5 -3
- package/modern.css.map +1 -1
- package/modern.min.css +2 -2
- package/package.json +1 -1
- package/survey.css +3 -2
- package/survey.css.map +1 -1
- package/survey.min.css +2 -2
- package/survey.react.d.ts +63 -30
- package/survey.react.js +448 -154
- package/survey.react.js.map +1 -1
- package/survey.react.min.js +3 -3
package/survey.react.d.ts
CHANGED
@@ -1678,6 +1678,7 @@ declare module "defaultCss/defaultV2Css" {
|
|
1678
1678
|
itemOnError: string;
|
1679
1679
|
control: string;
|
1680
1680
|
itemChecked: string;
|
1681
|
+
itemExchanged: string;
|
1681
1682
|
itemIndeterminate: string;
|
1682
1683
|
itemDisabled: string;
|
1683
1684
|
itemHover: string;
|
@@ -3251,6 +3252,11 @@ declare module "panel" {
|
|
3251
3252
|
get rows(): Array<QuestionRowModel>;
|
3252
3253
|
ensureRowsVisibility(): void;
|
3253
3254
|
protected onRowsChanged(): void;
|
3255
|
+
private locCountRowUpdates;
|
3256
|
+
private blockRowsUpdates;
|
3257
|
+
private releaseRowsUpdates;
|
3258
|
+
private updateRowsBeforeElementRemoved;
|
3259
|
+
private updateRowsOnElementAdded;
|
3254
3260
|
protected onAddElement(element: IElement, index: number): void;
|
3255
3261
|
protected onRemoveElement(element: IElement): void;
|
3256
3262
|
private onElementVisibilityChanged;
|
@@ -3317,6 +3323,7 @@ declare module "panel" {
|
|
3317
3323
|
* @see addNewPanel
|
3318
3324
|
*/
|
3319
3325
|
addElement(element: IElement, index?: number): boolean;
|
3326
|
+
insertElement(element: IElement, dest?: IElement, location?: "bottom" | "top" | "left" | "right"): void;
|
3320
3327
|
insertElementAfter(element: IElement, after: IElement): void;
|
3321
3328
|
insertElementBefore(element: IElement, before: IElement): void;
|
3322
3329
|
protected canAddElement(element: IElement): boolean;
|
@@ -3339,7 +3346,7 @@ declare module "panel" {
|
|
3339
3346
|
*
|
3340
3347
|
* This method returns `null` if the panel cannot be created or added to this panel/page; otherwise, the method returns the created panel.
|
3341
3348
|
* @param name A panel name.
|
3342
|
-
* @see
|
3349
|
+
* @see elementsup
|
3343
3350
|
* @see addElement
|
3344
3351
|
*/
|
3345
3352
|
addNewPanel(name?: string): PanelModel;
|
@@ -3686,7 +3693,7 @@ declare module "question_file" {
|
|
3686
3693
|
*/
|
3687
3694
|
get maxSize(): number;
|
3688
3695
|
set maxSize(val: number);
|
3689
|
-
chooseFile(): void;
|
3696
|
+
chooseFile(event: MouseEvent): void;
|
3690
3697
|
/**
|
3691
3698
|
* Specifies whether users should confirm file deletion.
|
3692
3699
|
*
|
@@ -3778,7 +3785,7 @@ declare module "question_file" {
|
|
3778
3785
|
protected onChangeQuestionValue(newValue: any): void;
|
3779
3786
|
protected calcCssClasses(css: any): any;
|
3780
3787
|
updateElementCss(reNew?: boolean): void;
|
3781
|
-
|
3788
|
+
onSurveyLoad(): void;
|
3782
3789
|
protected needResponsiveness(): boolean;
|
3783
3790
|
protected supportResponsiveness(): boolean;
|
3784
3791
|
protected getObservedElementSelector(): string;
|
@@ -5175,6 +5182,7 @@ declare module "dragdrop/dom-adapter" {
|
|
5175
5182
|
export class DragDropDOMAdapter implements IDragDropDOMAdapter {
|
5176
5183
|
private dd;
|
5177
5184
|
private longTap;
|
5185
|
+
private fitToContainer;
|
5178
5186
|
static PreventScrolling: boolean;
|
5179
5187
|
private timeoutID;
|
5180
5188
|
private startX;
|
@@ -5185,7 +5193,7 @@ declare module "dragdrop/dom-adapter" {
|
|
5185
5193
|
private savedTargetNodeParent;
|
5186
5194
|
private savedTargetNodeIndex;
|
5187
5195
|
private scrollIntervalId;
|
5188
|
-
constructor(dd: IDragDropEngine, longTap?: boolean);
|
5196
|
+
constructor(dd: IDragDropEngine, longTap?: boolean, fitToContainer?: boolean);
|
5189
5197
|
private get rootElement();
|
5190
5198
|
private stopLongTapIfMoveEnough;
|
5191
5199
|
private get isMicroMovement();
|
@@ -5546,7 +5554,7 @@ declare module "question_matrixdynamic" {
|
|
5546
5554
|
protected updateProgressInfoByValues(res: IProgressInfo): void;
|
5547
5555
|
private getValueForNewRow;
|
5548
5556
|
/**
|
5549
|
-
* Specifies whether users can drag and drop matrix rows to reorder them. Applies only if [`
|
5557
|
+
* Specifies whether users can drag and drop matrix rows to reorder them. Applies only if [`transposeData`](#transposeData) is `false`.
|
5550
5558
|
*
|
5551
5559
|
* Default value: `false`
|
5552
5560
|
*/
|
@@ -5679,8 +5687,7 @@ declare module "question_matrixdynamic" {
|
|
5679
5687
|
* - `"bottom"` - Displays the Add Row button at the bottom of the matrix.
|
5680
5688
|
* - `"topBottom"` - Displays the Add Row button at the top and bottom of the matrix.
|
5681
5689
|
*
|
5682
|
-
* Default value: `"top"` if `
|
5683
|
-
* @see columnLayout
|
5690
|
+
* Default value: `"top"` if [`transposeData`](#transposeData) is `true`; `"bottom"` if `transposeData` is `false` or the matrix is in compact mode.
|
5684
5691
|
* @see addRowText
|
5685
5692
|
*/
|
5686
5693
|
get addRowLocation(): string;
|
@@ -6564,7 +6571,7 @@ declare module "question_paneldynamic" {
|
|
6564
6571
|
getPrevButtonCss(): string;
|
6565
6572
|
getNextButtonCss(): string;
|
6566
6573
|
/**
|
6567
|
-
* A text displayed when Dynamic Panel contains no entries.
|
6574
|
+
* A text displayed when Dynamic Panel contains no entries.
|
6568
6575
|
*/
|
6569
6576
|
get noEntriesText(): string;
|
6570
6577
|
set noEntriesText(val: string);
|
@@ -9991,6 +9998,7 @@ declare module "survey" {
|
|
9991
9998
|
get isLogoBefore(): boolean;
|
9992
9999
|
get isLogoAfter(): boolean;
|
9993
10000
|
get logoClassNames(): string;
|
10001
|
+
private titleIsEmpty;
|
9994
10002
|
get renderedHasTitle(): boolean;
|
9995
10003
|
get renderedHasDescription(): boolean;
|
9996
10004
|
get hasTitle(): boolean;
|
@@ -13346,12 +13354,16 @@ declare module "question_matrixdropdownbase" {
|
|
13346
13354
|
protected updateColumnsAndRows(): void;
|
13347
13355
|
itemValuePropertyChanged(item: ItemValue, name: string, oldValue: any, newValue: any): void;
|
13348
13356
|
/**
|
13349
|
-
* Specifies
|
13357
|
+
* Specifies whether to display [`columns`](#columns) as rows and [`rows`](#rows) as columns.
|
13350
13358
|
*
|
13351
|
-
* Default value: `
|
13352
|
-
*
|
13353
|
-
*
|
13354
|
-
|
13359
|
+
* Default value: `false`
|
13360
|
+
*
|
13361
|
+
* [View Demo](https://surveyjs.io/form-library/examples/transpose-dynamic-rows-to-columns-in-matrix/ (linkStyle))
|
13362
|
+
*/
|
13363
|
+
get transposeData(): boolean;
|
13364
|
+
set transposeData(val: boolean);
|
13365
|
+
/**
|
13366
|
+
* This property is obsolete. Use the [`transposeData`](#transposeData) property instead.
|
13355
13367
|
*/
|
13356
13368
|
get columnLayout(): string;
|
13357
13369
|
set columnLayout(val: string);
|
@@ -13383,10 +13395,10 @@ declare module "question_matrixdropdownbase" {
|
|
13383
13395
|
set cellErrorLocation(value: string);
|
13384
13396
|
getChildErrorLocation(child: Question): string;
|
13385
13397
|
/**
|
13386
|
-
* Returns `true` if columns are placed in the horizontal direction and rows in the vertical direction.
|
13398
|
+
* Returns `true` if [`columns`](#columns) are placed in the horizontal direction and [`rows`](#columns) in the vertical direction.
|
13387
13399
|
*
|
13388
|
-
* To specify the layout, use the `
|
13389
|
-
* @see
|
13400
|
+
* To specify the layout, use the [`transposeData`](#transposeData) property. If you set it to `true`, the survey applies it only when the screen has enough space. Otherwise, the survey falls back to the original layout, but the `transposeData` property remains set to `true`. Unlike `transposeData`, the `isColumnLayoutHorizontal` property always indicates the current layout.
|
13401
|
+
* @see transposeData
|
13390
13402
|
*/
|
13391
13403
|
get isColumnLayoutHorizontal(): boolean;
|
13392
13404
|
/**
|
@@ -14046,6 +14058,7 @@ declare module "jsonobject" {
|
|
14046
14058
|
isBindable: boolean;
|
14047
14059
|
className: string;
|
14048
14060
|
alternativeName: string;
|
14061
|
+
oldName: string;
|
14049
14062
|
classNamePart: string;
|
14050
14063
|
baseClassName: string;
|
14051
14064
|
defaultValueValue: any;
|
@@ -14116,6 +14129,7 @@ declare module "jsonobject" {
|
|
14116
14129
|
set visible(val: boolean);
|
14117
14130
|
isAvailableInVersion(ver: string): boolean;
|
14118
14131
|
getSerializedName(ver: string): string;
|
14132
|
+
getSerializedProperty(obj: any, ver: string): JsonObjectProperty;
|
14119
14133
|
private isAvailableInVersionCore;
|
14120
14134
|
get isLocalizable(): boolean;
|
14121
14135
|
set isLocalizable(val: boolean);
|
@@ -14184,6 +14198,7 @@ declare module "jsonobject" {
|
|
14184
14198
|
setObjPropertyValue(obj: any, name: string, val: any): void;
|
14185
14199
|
private getObjPropertyValueCore;
|
14186
14200
|
private isObjWrapper;
|
14201
|
+
private isNeedUseObjWrapper;
|
14187
14202
|
addClass(name: string, properties: Array<any>, creator?: (json?: any) => any, parentName?: string): JsonMetadataClass;
|
14188
14203
|
removeClass(name: string): void;
|
14189
14204
|
overrideClassCreatore(name: string, creator: () => any): void;
|
@@ -14286,6 +14301,7 @@ declare module "jsonobject" {
|
|
14286
14301
|
private addDynamicProperties;
|
14287
14302
|
private propertiesToJson;
|
14288
14303
|
valueToJson(obj: any, result: any, prop: JsonObjectProperty, options?: ISaveToJSONOptions): void;
|
14304
|
+
private valueToJsonCore;
|
14289
14305
|
valueToObj(value: any, obj: any, property: JsonObjectProperty, jsonObj?: any, options?: ILoadFromJSONOptions): void;
|
14290
14306
|
private removePosOnValueToJson;
|
14291
14307
|
private removePos;
|
@@ -15062,27 +15078,43 @@ declare module "settings" {
|
|
15062
15078
|
*/
|
15063
15079
|
tagboxCloseOnSelect: boolean;
|
15064
15080
|
/**
|
15065
|
-
* A
|
15081
|
+
* A function that activates a browser confirm dialog.
|
15082
|
+
*
|
15083
|
+
* Use the following code to execute this function:
|
15084
|
+
*
|
15085
|
+
* ```js
|
15086
|
+
* import { settings } from "survey-core";
|
15066
15087
|
*
|
15067
|
-
*
|
15088
|
+
* // `result` contains `true` if the action was confirmed or `false` otherwise
|
15089
|
+
* const result = settings.confirmActionFunc("Are you sure?");
|
15090
|
+
* ```
|
15091
|
+
*
|
15092
|
+
* You can redefine the `confirmActionFunc` function if you want to display a custom dialog window. Your function should return `true` if a user confirms an action or `false` otherwise.
|
15068
15093
|
* @param message A message to be displayed in the confirm dialog window.
|
15069
15094
|
*/
|
15070
15095
|
confirmActionFunc: (message: string) => boolean;
|
15071
15096
|
/**
|
15072
|
-
* A
|
15073
|
-
*
|
15074
|
-
* To display a custom confirm dialog, set this property to a function that renders it. This function should return `true` to be enabled; otherwise, a survey executes the [`confirmActionFunc`](#confirmActionFunc) function. Pass the dialog result as the `callback` parameter: `true` if a user confirms an action, `false` otherwise.
|
15097
|
+
* A function that activates a proprietary SurveyJS confirm dialog.
|
15075
15098
|
*
|
15076
|
-
*
|
15099
|
+
* Use the following code to execute this function:
|
15077
15100
|
*
|
15078
15101
|
* ```js
|
15079
15102
|
* import { settings } from "survey-core";
|
15080
15103
|
*
|
15081
|
-
*
|
15082
|
-
*
|
15083
|
-
*
|
15084
|
-
*
|
15104
|
+
* settings.confirmActionAsync("Are you sure?", (confirmed) => {
|
15105
|
+
* if (confirmed) {
|
15106
|
+
* // ...
|
15107
|
+
* // Proceed with the action
|
15108
|
+
* // ...
|
15109
|
+
* } else {
|
15110
|
+
* // ...
|
15111
|
+
* // Cancel the action
|
15112
|
+
* // ...
|
15113
|
+
* }
|
15114
|
+
* });
|
15085
15115
|
* ```
|
15116
|
+
*
|
15117
|
+
* You can redefine the `confirmActionAsync` function if you want to display a custom dialog window. Your function should return `true` to be enabled; otherwise, a survey executes the [`confirmActionFunc`](#confirmActionFunc) function. Pass the dialog result as the `callback` parameter: `true` if a user confirms an action, `false` otherwise.
|
15086
15118
|
* @param message A message to be displayed in the confirm dialog window.
|
15087
15119
|
* @param callback A callback function that should be called with `true` if a user confirms an action or `false` otherwise.
|
15088
15120
|
*/
|
@@ -16858,6 +16890,9 @@ declare module "question_boolean" {
|
|
16858
16890
|
set labelTrue(val: string);
|
16859
16891
|
get locLabelTrue(): LocalizableString;
|
16860
16892
|
get isDeterminated(): boolean;
|
16893
|
+
swapOrder: boolean;
|
16894
|
+
get locLabelLeft(): LocalizableString;
|
16895
|
+
get locLabelRight(): LocalizableString;
|
16861
16896
|
/**
|
16862
16897
|
* Gets or sets a text label that corresponds to a negative answer.
|
16863
16898
|
*
|
@@ -17103,10 +17138,9 @@ declare module "popup-survey" {
|
|
17103
17138
|
get allowClose(): boolean;
|
17104
17139
|
set allowClose(val: boolean);
|
17105
17140
|
/**
|
17106
|
-
* Specifies whether to display a button that
|
17141
|
+
* Specifies whether to display a button that allows respondents to show the pop-up survey in full screen mode.
|
17107
17142
|
*
|
17108
17143
|
* Default value: `false`
|
17109
|
-
*
|
17110
17144
|
*/
|
17111
17145
|
get allowFullScreen(): boolean;
|
17112
17146
|
set allowFullScreen(val: boolean);
|
@@ -17278,7 +17312,7 @@ declare module "entries/chunks/model" {
|
|
17278
17312
|
export { JsonError, JsonIncorrectTypeError, JsonMetadata, JsonMetadataClass, JsonMissingTypeError, JsonMissingTypeErrorBase, JsonObject, JsonObjectProperty, JsonRequiredPropertyError, JsonUnknownPropertyError, Serializer, property, propertyArray } from "jsonobject";
|
17279
17313
|
export { IMatrixDropdownData, MatrixDropdownCell, MatrixDropdownRowModelBase, QuestionMatrixDropdownModelBase } from "question_matrixdropdownbase";
|
17280
17314
|
export { MatrixDropdownColumn, matrixDropdownColumnTypes } from "question_matrixdropdowncolumn";
|
17281
|
-
export { QuestionMatrixDropdownRenderedCell, QuestionMatrixDropdownRenderedRow, QuestionMatrixDropdownRenderedTable } from "question_matrixdropdownrendered";
|
17315
|
+
export { QuestionMatrixDropdownRenderedCell, QuestionMatrixDropdownRenderedRow, QuestionMatrixDropdownRenderedErrorRow, QuestionMatrixDropdownRenderedTable } from "question_matrixdropdownrendered";
|
17282
17316
|
export { MatrixDropdownRowModel, QuestionMatrixDropdownModel } from "question_matrixdropdown";
|
17283
17317
|
export { MatrixDynamicRowModel, QuestionMatrixDynamicModel } from "question_matrixdynamic";
|
17284
17318
|
export { MatrixRowModel, MatrixCells, QuestionMatrixModel, IMatrixData } from "question_matrix";
|
@@ -25229,7 +25263,6 @@ declare module "react/panel-base" {
|
|
25229
25263
|
componentDidUpdate(prevProps: any, prevState: any): void;
|
25230
25264
|
private doAfterRender;
|
25231
25265
|
protected canRender(): boolean;
|
25232
|
-
private renderedRowsCache;
|
25233
25266
|
protected renderRows(css: any): Array<JSX.Element>;
|
25234
25267
|
protected createRow(row: QuestionRowModel, css: any): JSX.Element;
|
25235
25268
|
}
|