survey-react 1.12.37 → 1.12.39
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 +1 -1
- package/defaultV2.min.css +1 -1
- package/modern.css +1 -1
- package/modern.min.css +1 -1
- package/package.json +1 -1
- package/survey.css +1 -1
- package/survey.min.css +1 -1
- package/survey.react.d.ts +12 -2
- package/survey.react.js +148 -64
- package/survey.react.js.map +1 -1
- package/survey.react.min.js +3 -3
package/defaultV2.css
CHANGED
package/defaultV2.min.css
CHANGED
package/modern.css
CHANGED
package/modern.min.css
CHANGED
package/package.json
CHANGED
package/survey.css
CHANGED
package/survey.min.css
CHANGED
package/survey.react.d.ts
CHANGED
@@ -59,6 +59,7 @@ declare module "packages/survey-core/src/helpers" {
|
|
59
59
|
static randomizeArray<T>(array: Array<T>): Array<T>;
|
60
60
|
static getUnbindValue(value: any): any;
|
61
61
|
static createCopy(obj: any): any;
|
62
|
+
static createCopyWithPrefix(obj: any, prefix?: string): any;
|
62
63
|
static isConvertibleToNumber(value: any): boolean;
|
63
64
|
static isValueObject(val: any, excludeArray?: boolean): boolean;
|
64
65
|
static isNumber(value: any): boolean;
|
@@ -226,6 +227,7 @@ declare module "packages/survey-core/src/surveyStrings" {
|
|
226
227
|
}): void;
|
227
228
|
currentLocale: string;
|
228
229
|
defaultLocale: string;
|
230
|
+
getCorrectLocaleName(loc: string): string;
|
229
231
|
getLocaleStrings(loc: string): any;
|
230
232
|
getString: (strName: string, locale?: string) => any;
|
231
233
|
getLocaleName(loc: string, inEnglish?: boolean): string;
|
@@ -371,7 +373,6 @@ declare module "packages/survey-core/src/conditionProcessValue" {
|
|
371
373
|
private getValueFromSurvey;
|
372
374
|
private getValueFromValues;
|
373
375
|
private getNonNestedObject;
|
374
|
-
private getNonNestedObjectCore;
|
375
376
|
private getObjInArray;
|
376
377
|
private getFirstPropertyName;
|
377
378
|
private getObjectValue;
|
@@ -3232,6 +3233,8 @@ declare module "packages/survey-core/src/question_custom" {
|
|
3232
3233
|
protected getQuestionByName(name: string): IQuestion;
|
3233
3234
|
protected getDefaultTitle(): string;
|
3234
3235
|
setValue(name: string, newValue: any, locNotification: any, allowNotifyValueChanged?: boolean): any;
|
3236
|
+
updateCommentFromSurvey(newValue: any): any;
|
3237
|
+
get requireUpdateCommentValue(): boolean;
|
3235
3238
|
protected onSetData(): void;
|
3236
3239
|
hasErrors(fireCallback?: boolean, rec?: any): boolean;
|
3237
3240
|
focus(onError?: boolean): void;
|
@@ -3254,6 +3257,7 @@ declare module "packages/survey-core/src/question_custom" {
|
|
3254
3257
|
private createDynamicProperties;
|
3255
3258
|
protected initElement(el: SurveyElement): void;
|
3256
3259
|
updateElementCss(reNew?: boolean): void;
|
3260
|
+
setIsMobile(val: boolean): void;
|
3257
3261
|
protected updateElementCssCore(cssClasses: any): void;
|
3258
3262
|
protected getDisplayValueCore(keyAsText: boolean, value: any): any;
|
3259
3263
|
}
|
@@ -3311,6 +3315,7 @@ declare module "packages/survey-core/src/question_custom" {
|
|
3311
3315
|
protected getDisplayValueCore(keyAsText: boolean, value: any): any;
|
3312
3316
|
private setAfterRenderCallbacks;
|
3313
3317
|
get ariaRole(): string;
|
3318
|
+
setIsMobile(val: boolean): void;
|
3314
3319
|
}
|
3315
3320
|
}
|
3316
3321
|
declare module "packages/survey-core/src/questionfactory" {
|
@@ -7231,6 +7236,7 @@ declare module "packages/survey-core/src/question_paneldynamic" {
|
|
7231
7236
|
private hasPanelBuildFirstTime;
|
7232
7237
|
private isBuildingPanelsFirstTime;
|
7233
7238
|
private buildPanelsFirstTime;
|
7239
|
+
private runTriggersOnBuildPanelsFirstTime;
|
7234
7240
|
private get showAddPanelButton();
|
7235
7241
|
private get wasNotRenderedInSurvey();
|
7236
7242
|
private get canBuildPanels();
|
@@ -7240,6 +7246,7 @@ declare module "packages/survey-core/src/question_paneldynamic" {
|
|
7240
7246
|
runTriggers(name: string, value: any, keys?: any): void;
|
7241
7247
|
private reRunCondition;
|
7242
7248
|
protected runPanelsCondition(panels: PanelModel[], values: HashTable<any>, properties: HashTable<any>): void;
|
7249
|
+
private isValueChangedWithoutPanels;
|
7243
7250
|
onAnyValueChanged(name: string, questionName: string): void;
|
7244
7251
|
private hasKeysDuplicated;
|
7245
7252
|
private updatePanelsContainsErrors;
|
@@ -14149,6 +14156,7 @@ declare module "packages/survey-core/src/question" {
|
|
14149
14156
|
protected getDefaultRunner(runner: ExpressionRunner, expression: string): ExpressionRunner;
|
14150
14157
|
protected setDefaultValue(): void;
|
14151
14158
|
private setDefaultValueCore;
|
14159
|
+
protected updateValueWithDefaultsOrClear(): void;
|
14152
14160
|
protected isValueExpression(val: any): boolean;
|
14153
14161
|
protected setValueAndRunExpression(runner: ExpressionRunner, defaultValue: any, setFunc: (val: any) => void, values?: HashTable<any>, properties?: HashTable<any>): void;
|
14154
14162
|
protected convertFuncValuetoQuestionValue(val: any): any;
|
@@ -14698,7 +14706,7 @@ declare module "packages/survey-core/src/question_matrixdropdownbase" {
|
|
14698
14706
|
private setValueCore;
|
14699
14707
|
private updateQuestionsValue;
|
14700
14708
|
private updateSharedQuestionsValue;
|
14701
|
-
runTriggers(name: string, value: any): void;
|
14709
|
+
runTriggers(name: string, value: any, keys?: any): void;
|
14702
14710
|
private hasQuestonError;
|
14703
14711
|
get isEmpty(): boolean;
|
14704
14712
|
getQuestionByColumn(column: MatrixDropdownColumn): Question;
|
@@ -15017,6 +15025,7 @@ declare module "packages/survey-core/src/question_matrixdropdownbase" {
|
|
15017
15025
|
private isGenereatingRows;
|
15018
15026
|
protected getVisibleRows(): Array<MatrixDropdownRowModelBase>;
|
15019
15027
|
private generateVisibleRowsIfNeeded;
|
15028
|
+
private runTriggersOnNewRows;
|
15020
15029
|
private getVisibleFromGenerated;
|
15021
15030
|
private updateValueOnRowsGeneration;
|
15022
15031
|
get totalValue(): any;
|
@@ -15086,6 +15095,7 @@ declare module "packages/survey-core/src/question_matrixdropdownbase" {
|
|
15086
15095
|
protected createQuestionCore(row: MatrixDropdownRowModelBase, column: MatrixDropdownColumn): Question;
|
15087
15096
|
protected deleteRowValue(newValue: any, row: MatrixDropdownRowModelBase): any;
|
15088
15097
|
private isDoingonAnyValueChanged;
|
15098
|
+
private isValueChangedWithoutRows;
|
15089
15099
|
onAnyValueChanged(name: string, questionName: string): void;
|
15090
15100
|
protected isObject(value: any): boolean;
|
15091
15101
|
private getOnCellValueChangedOptions;
|
package/survey.react.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* surveyjs - Survey JavaScript library v1.12.
|
2
|
+
* surveyjs - Survey JavaScript library v1.12.39
|
3
3
|
* Copyright (c) 2015-2025 Devsoft Baltic OÜ - http://surveyjs.io/
|
4
4
|
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
|
5
5
|
*/
|
@@ -2419,11 +2419,15 @@ var helpers_Helpers = /** @class */ (function () {
|
|
2419
2419
|
return value;
|
2420
2420
|
};
|
2421
2421
|
Helpers.createCopy = function (obj) {
|
2422
|
+
return this.createCopyWithPrefix(obj, undefined);
|
2423
|
+
};
|
2424
|
+
Helpers.createCopyWithPrefix = function (obj, prefix) {
|
2422
2425
|
var res = {};
|
2423
2426
|
if (!obj)
|
2424
2427
|
return res;
|
2425
2428
|
for (var key in obj) {
|
2426
|
-
|
2429
|
+
var newKey = prefix ? prefix + key : key;
|
2430
|
+
res[newKey] = obj[key];
|
2427
2431
|
}
|
2428
2432
|
return res;
|
2429
2433
|
};
|
@@ -2886,17 +2890,20 @@ var surveyLocalization = {
|
|
2886
2890
|
return this.currentLocaleValue === this.defaultLocaleValue ? "" : this.currentLocaleValue;
|
2887
2891
|
},
|
2888
2892
|
set currentLocale(val) {
|
2889
|
-
|
2890
|
-
val = "cs";
|
2891
|
-
this.currentLocaleValue = val;
|
2893
|
+
this.currentLocaleValue = this.getCorrectLocaleName(val);
|
2892
2894
|
},
|
2893
2895
|
get defaultLocale() {
|
2894
2896
|
return this.defaultLocaleValue;
|
2895
2897
|
},
|
2896
2898
|
set defaultLocale(val) {
|
2897
|
-
|
2898
|
-
|
2899
|
-
|
2899
|
+
this.defaultLocaleValue = this.getCorrectLocaleName(val);
|
2900
|
+
},
|
2901
|
+
getCorrectLocaleName: function (loc) {
|
2902
|
+
if (loc === "cz")
|
2903
|
+
loc = "cs";
|
2904
|
+
if (loc === "ua")
|
2905
|
+
loc = "uk";
|
2906
|
+
return loc;
|
2900
2907
|
},
|
2901
2908
|
getLocaleStrings: function (loc) {
|
2902
2909
|
return this.locales[loc];
|
@@ -3258,6 +3265,9 @@ var jsonobject_JsonObjectProperty = /** @class */ (function () {
|
|
3258
3265
|
},
|
3259
3266
|
set: function (newValue) {
|
3260
3267
|
this.defaultValueValue = newValue;
|
3268
|
+
if (newValue !== undefined) {
|
3269
|
+
this.defaultValueFunc = undefined;
|
3270
|
+
}
|
3261
3271
|
},
|
3262
3272
|
enumerable: false,
|
3263
3273
|
configurable: true
|
@@ -5204,59 +5214,46 @@ var conditionProcessValue_ProcessValue = /** @class */ (function () {
|
|
5204
5214
|
res.value = 0;
|
5205
5215
|
res.hasValue = true;
|
5206
5216
|
}
|
5207
|
-
var
|
5208
|
-
if (!
|
5217
|
+
var obj = this.getNonNestedObject(curValue, text, false);
|
5218
|
+
if (!obj)
|
5209
5219
|
return res;
|
5210
|
-
res.path =
|
5211
|
-
res.value = !!
|
5212
|
-
? this.getObjectValue(nonNestedObj.value, nonNestedObj.text)
|
5213
|
-
: nonNestedObj.value;
|
5220
|
+
res.path = obj.path;
|
5221
|
+
res.value = !!obj.text ? this.getObjectValue(obj.value, obj.text) : obj.value;
|
5214
5222
|
res.hasValue = !helpers_Helpers.isValueEmpty(res.value);
|
5215
5223
|
return res;
|
5216
5224
|
};
|
5217
5225
|
ProcessValue.prototype.getNonNestedObject = function (obj, text, createPath) {
|
5218
|
-
var
|
5219
|
-
var
|
5220
|
-
var res = this.getNonNestedObjectCore(obj, text, createPath, checkedKeys);
|
5221
|
-
while (!res && len < checkedKeys.length) {
|
5222
|
-
len = checkedKeys.length;
|
5223
|
-
res = this.getNonNestedObjectCore(obj, text, createPath, checkedKeys);
|
5224
|
-
}
|
5225
|
-
return res;
|
5226
|
-
};
|
5227
|
-
ProcessValue.prototype.getNonNestedObjectCore = function (obj, text, createPath, checkedKeys) {
|
5228
|
-
var curName = this.getFirstPropertyName(text, obj, createPath, checkedKeys);
|
5229
|
-
if (!!curName) {
|
5230
|
-
checkedKeys.push(curName);
|
5231
|
-
}
|
5226
|
+
var curName = this.getFirstPropertyName(text, obj, createPath);
|
5227
|
+
var curObj = obj;
|
5232
5228
|
var path = !!curName ? [curName] : null;
|
5233
|
-
|
5234
|
-
|
5229
|
+
var curText = text;
|
5230
|
+
while (curText != curName && !!curObj) {
|
5231
|
+
var isArray = curText[0] == "[";
|
5235
5232
|
if (!isArray) {
|
5236
|
-
if (!curName &&
|
5233
|
+
if (!curName && curText === this.getFirstName(curText))
|
5237
5234
|
return { value: obj, text: text, path: path };
|
5238
|
-
|
5239
|
-
if (helpers_Helpers.isValueEmpty(
|
5235
|
+
curObj = this.getObjectValue(curObj, curName);
|
5236
|
+
if (helpers_Helpers.isValueEmpty(curObj) && !createPath)
|
5240
5237
|
return null;
|
5241
|
-
|
5238
|
+
curText = curText.substring(curName.length);
|
5242
5239
|
}
|
5243
5240
|
else {
|
5244
|
-
var objInArray = this.getObjInArray(
|
5241
|
+
var objInArray = this.getObjInArray(curObj, curText);
|
5245
5242
|
if (!objInArray)
|
5246
5243
|
return null;
|
5247
|
-
|
5248
|
-
|
5244
|
+
curObj = objInArray.value;
|
5245
|
+
curText = objInArray.text;
|
5249
5246
|
path.push(objInArray.index);
|
5250
5247
|
}
|
5251
|
-
if (!!
|
5252
|
-
|
5248
|
+
if (!!curText && curText[0] == ".") {
|
5249
|
+
curText = curText.substring(1);
|
5253
5250
|
}
|
5254
|
-
curName = this.getFirstPropertyName(
|
5251
|
+
curName = this.getFirstPropertyName(curText, curObj, createPath);
|
5255
5252
|
if (!!curName) {
|
5256
5253
|
path.push(curName);
|
5257
5254
|
}
|
5258
5255
|
}
|
5259
|
-
return { value:
|
5256
|
+
return { value: curObj, text: curText, path: path };
|
5260
5257
|
};
|
5261
5258
|
ProcessValue.prototype.getObjInArray = function (curValue, text) {
|
5262
5259
|
if (!Array.isArray(curValue))
|
@@ -5273,11 +5270,10 @@ var conditionProcessValue_ProcessValue = /** @class */ (function () {
|
|
5273
5270
|
return null;
|
5274
5271
|
return { value: curValue[index], text: text, index: index };
|
5275
5272
|
};
|
5276
|
-
ProcessValue.prototype.getFirstPropertyName = function (name, obj, createProp
|
5273
|
+
ProcessValue.prototype.getFirstPropertyName = function (name, obj, createProp) {
|
5277
5274
|
if (createProp === void 0) { createProp = false; }
|
5278
|
-
if (checkedKeys === void 0) { checkedKeys = undefined; }
|
5279
5275
|
if (!name)
|
5280
|
-
return
|
5276
|
+
return "";
|
5281
5277
|
if (!obj)
|
5282
5278
|
obj = {};
|
5283
5279
|
if (obj.hasOwnProperty(name))
|
@@ -5285,9 +5281,8 @@ var conditionProcessValue_ProcessValue = /** @class */ (function () {
|
|
5285
5281
|
var nameInLow = name.toLowerCase();
|
5286
5282
|
var A = nameInLow[0];
|
5287
5283
|
var a = A.toUpperCase();
|
5284
|
+
var keyWithDot = "";
|
5288
5285
|
for (var key in obj) {
|
5289
|
-
if (Array.isArray(checkedKeys) && checkedKeys.indexOf(key) > -1)
|
5290
|
-
continue;
|
5291
5286
|
var first = key[0];
|
5292
5287
|
if (first === a || first === A) {
|
5293
5288
|
var keyName = key.toLowerCase();
|
@@ -5298,10 +5293,15 @@ var conditionProcessValue_ProcessValue = /** @class */ (function () {
|
|
5298
5293
|
var ch = nameInLow[keyName.length];
|
5299
5294
|
if (ch != "." && ch != "[")
|
5300
5295
|
continue;
|
5301
|
-
if (keyName == nameInLow.substring(0, keyName.length))
|
5302
|
-
|
5296
|
+
if (keyName == nameInLow.substring(0, keyName.length)) {
|
5297
|
+
if (keyWithDot.length < key.length) {
|
5298
|
+
keyWithDot = key;
|
5299
|
+
}
|
5300
|
+
}
|
5303
5301
|
}
|
5304
5302
|
}
|
5303
|
+
if (keyWithDot)
|
5304
|
+
return keyWithDot;
|
5305
5305
|
if (createProp && name[0] !== "[") {
|
5306
5306
|
var ind = name.indexOf(".");
|
5307
5307
|
if (ind > -1) {
|
@@ -19046,8 +19046,7 @@ var question_Question = /** @class */ (function (_super) {
|
|
19046
19046
|
_this.createLocalizableString("requiredErrorText", _this);
|
19047
19047
|
_this.addTriggerInfo("resetValueIf", function () { return !_this.isEmpty(); }, function () {
|
19048
19048
|
_this.startSetValueOnExpression();
|
19049
|
-
_this.
|
19050
|
-
_this.updateValueWithDefaults();
|
19049
|
+
_this.updateValueWithDefaultsOrClear();
|
19051
19050
|
_this.finishSetValueOnExpression();
|
19052
19051
|
});
|
19053
19052
|
var setValueIfInfo = _this.addTriggerInfo("setValueIf", function () { return true; }, function () { return _this.runSetValueExpression(); });
|
@@ -21456,6 +21455,16 @@ var question_Question = /** @class */ (function (_super) {
|
|
21456
21455
|
this.defaultValueRunner = this.getDefaultRunner(this.defaultValueRunner, this.defaultValueExpression);
|
21457
21456
|
this.setValueAndRunExpression(this.defaultValueRunner, this.getUnbindValue(this.defaultValue), function (val) { return func(val); });
|
21458
21457
|
};
|
21458
|
+
Question.prototype.updateValueWithDefaultsOrClear = function () {
|
21459
|
+
if (this.isDesignMode || this.isLoadingFromJson)
|
21460
|
+
return;
|
21461
|
+
if (this.isDefaultValueEmpty()) {
|
21462
|
+
this.clearValue();
|
21463
|
+
}
|
21464
|
+
else {
|
21465
|
+
this.setDefaultValue();
|
21466
|
+
}
|
21467
|
+
};
|
21459
21468
|
Question.prototype.isValueExpression = function (val) {
|
21460
21469
|
return !!val && typeof val == "string" && val.length > 0 && val[0] == "=";
|
21461
21470
|
};
|
@@ -25368,6 +25377,18 @@ var question_custom_QuestionCustomModel = /** @class */ (function (_super) {
|
|
25368
25377
|
return;
|
25369
25378
|
_super.prototype.setValue.call(this, name, newValue, locNotification, allowNotifyValueChanged);
|
25370
25379
|
};
|
25380
|
+
QuestionCustomModel.prototype.updateCommentFromSurvey = function (newValue) {
|
25381
|
+
_super.prototype.updateCommentFromSurvey.call(this, newValue);
|
25382
|
+
var q = this.contentQuestion;
|
25383
|
+
if (!!q) {
|
25384
|
+
q.updateCommentFromSurvey(newValue);
|
25385
|
+
}
|
25386
|
+
};
|
25387
|
+
Object.defineProperty(QuestionCustomModel.prototype, "requireUpdateCommentValue", {
|
25388
|
+
get: function () { var _a; return (_a = this.contentQuestion) === null || _a === void 0 ? void 0 : _a.requireUpdateCommentValue; },
|
25389
|
+
enumerable: false,
|
25390
|
+
configurable: true
|
25391
|
+
});
|
25371
25392
|
QuestionCustomModel.prototype.onSetData = function () {
|
25372
25393
|
_super.prototype.onSetData.call(this);
|
25373
25394
|
if (!!this.survey && !this.isEmpty()) {
|
@@ -25559,6 +25580,12 @@ var question_custom_QuestionCustomModel = /** @class */ (function (_super) {
|
|
25559
25580
|
}
|
25560
25581
|
_super.prototype.updateElementCss.call(this, reNew);
|
25561
25582
|
};
|
25583
|
+
QuestionCustomModel.prototype.setIsMobile = function (val) {
|
25584
|
+
_super.prototype.setIsMobile.call(this, val);
|
25585
|
+
if (!!this.contentQuestion) {
|
25586
|
+
this.contentQuestion.setIsMobile(val);
|
25587
|
+
}
|
25588
|
+
};
|
25562
25589
|
QuestionCustomModel.prototype.updateElementCssCore = function (cssClasses) {
|
25563
25590
|
if (!!this.contentQuestion) {
|
25564
25591
|
cssClasses = this.contentQuestion.cssClasses;
|
@@ -25971,6 +25998,14 @@ var question_custom_QuestionCompositeModel = /** @class */ (function (_super) {
|
|
25971
25998
|
enumerable: false,
|
25972
25999
|
configurable: true
|
25973
26000
|
});
|
26001
|
+
QuestionCompositeModel.prototype.setIsMobile = function (val) {
|
26002
|
+
_super.prototype.setIsMobile.call(this, val);
|
26003
|
+
if (!!this.contentPanel) {
|
26004
|
+
this.contentPanel.questions.forEach(function (q) {
|
26005
|
+
q.setIsMobile(val);
|
26006
|
+
});
|
26007
|
+
}
|
26008
|
+
};
|
25974
26009
|
QuestionCompositeModel.ItemVariableName = "composite";
|
25975
26010
|
return QuestionCompositeModel;
|
25976
26011
|
}(question_custom_QuestionCustomModelBase));
|
@@ -26981,9 +27016,10 @@ var question_matrixdropdowncolumn_MatrixDropdownColumn = /** @class */ (function
|
|
26981
27016
|
* @see readOnly
|
26982
27017
|
*/
|
26983
27018
|
get: function () {
|
26984
|
-
return this.
|
27019
|
+
return this.getPropertyValue("isRequired");
|
26985
27020
|
},
|
26986
27021
|
set: function (val) {
|
27022
|
+
this.setPropertyValue("isRequired", val);
|
26987
27023
|
this.templateQuestion.isRequired = val;
|
26988
27024
|
},
|
26989
27025
|
enumerable: false,
|
@@ -27701,7 +27737,14 @@ Serializer.addClass("matrixdropdowncolumn", [
|
|
27701
27737
|
},
|
27702
27738
|
},
|
27703
27739
|
{ name: "colCount", default: -1, choices: [-1, 0, 1, 2, 3, 4] },
|
27704
|
-
"isRequired:boolean",
|
27740
|
+
{ name: "isRequired:boolean", defaultFunc: function (obj) {
|
27741
|
+
var _a;
|
27742
|
+
var q = (_a = obj) === null || _a === void 0 ? void 0 : _a.templateQuestion;
|
27743
|
+
if (!!q) {
|
27744
|
+
return Serializer.findProperty(q.getType(), "isRequired").getDefaultValue(q) || false;
|
27745
|
+
}
|
27746
|
+
return false;
|
27747
|
+
} },
|
27705
27748
|
"isUnique:boolean",
|
27706
27749
|
{
|
27707
27750
|
name: "requiredErrorText:text",
|
@@ -29654,10 +29697,10 @@ var question_matrixdropdownbase_MatrixDropdownRowModelBase = /** @class */ (func
|
|
29654
29697
|
}
|
29655
29698
|
}
|
29656
29699
|
};
|
29657
|
-
MatrixDropdownRowModelBase.prototype.runTriggers = function (name, value) {
|
29658
|
-
if (!name)
|
29700
|
+
MatrixDropdownRowModelBase.prototype.runTriggers = function (name, value, keys) {
|
29701
|
+
if (!name && !keys)
|
29659
29702
|
return;
|
29660
|
-
this.questions.forEach(function (q) { return q.runTriggers(name, value); });
|
29703
|
+
this.questions.forEach(function (q) { return q.runTriggers(name, value, keys); });
|
29661
29704
|
};
|
29662
29705
|
MatrixDropdownRowModelBase.prototype.hasQuestonError = function (question) {
|
29663
29706
|
if (!question)
|
@@ -30002,7 +30045,6 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
|
|
30002
30045
|
var _this = _super.call(this, name) || this;
|
30003
30046
|
_this.isRowChanging = false;
|
30004
30047
|
_this.lockResetRenderedTable = false;
|
30005
|
-
_this.isDoingonAnyValueChanged = false;
|
30006
30048
|
_this.createItemValues("choices");
|
30007
30049
|
_this.createLocalizableString("placeholder", _this, false, true);
|
30008
30050
|
_this.createLocalizableString("keyDuplicationError", _this, false, true);
|
@@ -30960,6 +31002,10 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
|
|
30960
31002
|
this.generatedVisibleRows.forEach(function (row) { return _this.onMatrixRowCreated(row); });
|
30961
31003
|
if (this.data) {
|
30962
31004
|
this.runCellsCondition(this.data.getFilteredValues(), this.data.getFilteredProperties());
|
31005
|
+
if (this.isValueChangedWithoutRows) {
|
31006
|
+
this.isValueChangedWithoutRows = false;
|
31007
|
+
this.runTriggersOnNewRows();
|
31008
|
+
}
|
30963
31009
|
}
|
30964
31010
|
if (!!this.generatedVisibleRows) {
|
30965
31011
|
this.updateValueOnRowsGeneration(this.generatedVisibleRows);
|
@@ -30967,6 +31013,17 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
|
|
30967
31013
|
}
|
30968
31014
|
}
|
30969
31015
|
};
|
31016
|
+
QuestionMatrixDropdownModelBase.prototype.runTriggersOnNewRows = function () {
|
31017
|
+
var _this = this;
|
31018
|
+
var val = this.value;
|
31019
|
+
this.generatedVisibleRows.forEach(function (row) {
|
31020
|
+
var rowValue = _this.getRowValueCore(row, val);
|
31021
|
+
if (!helpers_Helpers.isValueEmpty(rowValue)) {
|
31022
|
+
var triggeredValue = helpers_Helpers.createCopyWithPrefix(rowValue, question_matrixdropdownbase_MatrixDropdownRowModelBase.RowVariableName + ".");
|
31023
|
+
row.runTriggers("", undefined, triggeredValue);
|
31024
|
+
}
|
31025
|
+
});
|
31026
|
+
};
|
30970
31027
|
QuestionMatrixDropdownModelBase.prototype.getVisibleFromGenerated = function (rows) {
|
30971
31028
|
var res = [];
|
30972
31029
|
if (!rows)
|
@@ -31569,10 +31626,14 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
|
|
31569
31626
|
: newValue;
|
31570
31627
|
};
|
31571
31628
|
QuestionMatrixDropdownModelBase.prototype.onAnyValueChanged = function (name, questionName) {
|
31572
|
-
if (this.isUpdateLocked ||
|
31573
|
-
this.isDoingonAnyValueChanged ||
|
31574
|
-
!this.generatedVisibleRows)
|
31629
|
+
if (this.isUpdateLocked || this.isDoingonAnyValueChanged)
|
31575
31630
|
return;
|
31631
|
+
if (!this.generatedVisibleRows) {
|
31632
|
+
if (name === this.getValueName()) {
|
31633
|
+
this.isValueChangedWithoutRows = true;
|
31634
|
+
}
|
31635
|
+
return;
|
31636
|
+
}
|
31576
31637
|
this.isDoingonAnyValueChanged = true;
|
31577
31638
|
var rows = this.generatedVisibleRows;
|
31578
31639
|
for (var i = 0; i < rows.length; i++) {
|
@@ -44192,8 +44253,13 @@ var survey_SurveyModel = /** @class */ (function (_super) {
|
|
44192
44253
|
return;
|
44193
44254
|
if (newPage == this.currentPage)
|
44194
44255
|
return;
|
44256
|
+
var curEl = this.currentSingleElement;
|
44257
|
+
if (!this.isShowingPreview && !!curEl && newPage !== curEl.page) {
|
44258
|
+
this.currentSingleElement = newPage.getFirstVisibleElement();
|
44259
|
+
return;
|
44260
|
+
}
|
44195
44261
|
var oldValue = this.currentPage;
|
44196
|
-
if (!this.isShowingPreview && !
|
44262
|
+
if (!this.isShowingPreview && !curEl && !this.currentPageChanging(newPage, oldValue))
|
44197
44263
|
return;
|
44198
44264
|
this.setPropertyValue("currentPage", newPage);
|
44199
44265
|
if (!!newPage) {
|
@@ -69236,6 +69302,10 @@ var question_paneldynamic_QuestionPanelDynamicModel = /** @class */ (function (_
|
|
69236
69302
|
this.setPanelsSurveyImpl();
|
69237
69303
|
this.setPanelsState();
|
69238
69304
|
this.assignOnPropertyChangedToTemplate();
|
69305
|
+
if (this.data && this.isValueChangedWithoutPanels) {
|
69306
|
+
this.isValueChangedWithoutPanels = false;
|
69307
|
+
this.runTriggersOnBuildPanelsFirstTime();
|
69308
|
+
}
|
69239
69309
|
if (!!this.survey) {
|
69240
69310
|
for (var i = 0; i < this.panelCount; i++) {
|
69241
69311
|
this.notifyOnPanelAddedRemoved(true, i);
|
@@ -69249,6 +69319,17 @@ var question_paneldynamic_QuestionPanelDynamicModel = /** @class */ (function (_
|
|
69249
69319
|
this.isBuildingPanelsFirstTime = false;
|
69250
69320
|
this.releaseAnimations();
|
69251
69321
|
};
|
69322
|
+
QuestionPanelDynamicModel.prototype.runTriggersOnBuildPanelsFirstTime = function () {
|
69323
|
+
var _this = this;
|
69324
|
+
var val = this.value;
|
69325
|
+
this.visiblePanelsCore.forEach(function (p) {
|
69326
|
+
var panelValue = _this.getPanelItemData(p.data);
|
69327
|
+
if (!helpers_Helpers.isValueEmpty(panelValue)) {
|
69328
|
+
var triggeredValue_1 = helpers_Helpers.createCopyWithPrefix(panelValue, question_paneldynamic_QuestionPanelDynamicItem.ItemVariableName + ".");
|
69329
|
+
p.questions.forEach(function (q) { return q.runTriggers("", undefined, triggeredValue_1); });
|
69330
|
+
}
|
69331
|
+
});
|
69332
|
+
};
|
69252
69333
|
Object.defineProperty(QuestionPanelDynamicModel.prototype, "showAddPanelButton", {
|
69253
69334
|
get: function () { return this.allowAddPanel && !this.isReadOnly; },
|
69254
69335
|
enumerable: false,
|
@@ -69327,6 +69408,9 @@ var question_paneldynamic_QuestionPanelDynamicModel = /** @class */ (function (_
|
|
69327
69408
|
};
|
69328
69409
|
QuestionPanelDynamicModel.prototype.onAnyValueChanged = function (name, questionName) {
|
69329
69410
|
_super.prototype.onAnyValueChanged.call(this, name, questionName);
|
69411
|
+
if (!this.hasPanelBuildFirstTime && name === this.getValueName()) {
|
69412
|
+
this.isValueChangedWithoutPanels = true;
|
69413
|
+
}
|
69330
69414
|
for (var i = 0; i < this.panelsCore.length; i++) {
|
69331
69415
|
this.panelsCore[i].onAnyValueChanged(name, questionName);
|
69332
69416
|
this.panelsCore[i].onAnyValueChanged(question_paneldynamic_QuestionPanelDynamicItem.ItemVariableName, "");
|
@@ -72640,7 +72724,7 @@ var mask_datetime_InputMaskDateTime = /** @class */ (function (_super) {
|
|
72640
72724
|
};
|
72641
72725
|
InputMaskDateTime.prototype.getMaxDateForMonth = function (year, month) {
|
72642
72726
|
if (month == 2)
|
72643
|
-
return year % 4 == 0 && year % 100 != 0 || year % 400 ? 29 : 28;
|
72727
|
+
return year % 4 == 0 && year % 100 != 0 || year % 400 == 0 ? 29 : 28;
|
72644
72728
|
return [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][month - 1];
|
72645
72729
|
};
|
72646
72730
|
InputMaskDateTime.prototype.isDateValid = function (dateTime) {
|
@@ -73141,9 +73225,9 @@ Serializer.addClass("currencymask", [
|
|
73141
73225
|
|
73142
73226
|
var Version;
|
73143
73227
|
var ReleaseDate;
|
73144
|
-
Version = "" + "1.12.
|
73228
|
+
Version = "" + "1.12.39";
|
73145
73229
|
settings.version = Version;
|
73146
|
-
ReleaseDate = "" + "2025-
|
73230
|
+
ReleaseDate = "" + "2025-06-03";
|
73147
73231
|
function checkLibraryVersion(ver, libraryName) {
|
73148
73232
|
if (Version != ver) {
|
73149
73233
|
var str = "survey-core has version '" + Version + "' and " + libraryName
|
@@ -82518,7 +82602,7 @@ var ukrainianSurveyStrings = {
|
|
82518
82602
|
ok: "ГАРАЗД",
|
82519
82603
|
cancel: "Скасувати"
|
82520
82604
|
};
|
82521
|
-
setupLocale({ localeCode: "
|
82605
|
+
setupLocale({ localeCode: "uk", strings: ukrainianSurveyStrings, nativeName: "українська", englishName: "Ukrainian" });
|
82522
82606
|
// The following strings have been translated by a machine translation service
|
82523
82607
|
// Remove those strings that you have corrected manually
|
82524
82608
|
// indexText: "{0} of {1}" => "{0} {1}"
|