survey-creator-react 3.2.2 → 3.2.4

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "survey-creator-react",
3
- "version": "3.2.2",
3
+ "version": "3.2.4",
4
4
  "description": "Embeddable SurveyJS drag-and-drop form builder for JSON-based forms in React. Create dynamic surveys, polls, quizzes, and other forms, configure conditional logic and validation, and customize the editor UI.",
5
5
  "author": "DevSoft Baltic OU <info@devsoftbaltic.com>",
6
6
  "homepage": "https://surveyjs.io/",
@@ -67,9 +67,9 @@
67
67
  "ace-builds": "^1.4.12",
68
68
  "react": "^16.5.0 || ^17.0.1 || ^18.1.0 || ^19.0.0",
69
69
  "react-dom": "^16.5.0 || ^17.0.1 || ^18.1.0 || ^19.0.0",
70
- "survey-core": "3.2.2",
71
- "survey-react-ui": "3.2.2",
72
- "survey-creator-core": "3.2.2"
70
+ "survey-core": "3.2.4",
71
+ "survey-react-ui": "3.2.4",
72
+ "survey-creator-core": "3.2.4"
73
73
  },
74
74
  "peerDependenciesMeta": {
75
75
  "ace-builds": {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * SurveyJS Creator v3.2.2
2
+ * SurveyJS Creator v3.2.4
3
3
  * (c) 2015-2026 Devsoft Baltic OÜ - http://surveyjs.io/
4
4
  * Github: https://github.com/surveyjs/survey-creator
5
5
  * License: https://surveyjs.io/Licenses#SurveyCreator
@@ -128,7 +128,7 @@
128
128
  }
129
129
  render() {
130
130
  const item = this.item;
131
- return (surveyReactUi.attachKey2click(React__namespace.createElement("div", { role: "tab", id: "tab-" + item.id, "aria-selected": item.active, "aria-controls": "scrollableDiv-" + item.id, className: item.getRootCss(), onClick: () => item.doAction() },
131
+ return (surveyReactUi.attachKey2click(React__namespace.createElement("div", { role: "tab", id: "tab-" + item.id, "aria-selected": item.active, "aria-controls": "scrollableDiv-" + item.id, className: item.getRootCss(), "data-sv-tooltip": item.hasIcon ? item.tooltip || item.title : undefined, onClick: () => item.doAction() },
132
132
  item.hasTitle ? React__namespace.createElement("span", { className: item.getTitleCss() }, item.title) : null,
133
133
  item.hasIcon ? React__namespace.createElement(surveyReactUi.SvgIcon, { iconName: item.iconName, className: item.getIconCss(), size: "auto", title: item.tooltip || item.title }) : null)));
134
134
  }
@@ -560,7 +560,7 @@
560
560
  e.stopPropagation();
561
561
  }
562
562
  this.props.click();
563
- }, title: this.props.title }, this.props.text))));
563
+ }, title: this.props.title, "data-sv-tooltip": this.props.title }, this.props.text))));
564
564
  }
565
565
  renderIcon(classes) {
566
566
  classes += " svc-action-button--icon";
@@ -573,7 +573,7 @@
573
573
  e.stopPropagation();
574
574
  }
575
575
  this.props.click();
576
- }, title: this.props.title },
576
+ }, title: this.props.title, "data-sv-tooltip": this.props.title },
577
577
  React__namespace.createElement(surveyReactUi.SvgIcon, { size: "auto", iconName: this.props.iconName })))));
578
578
  }
579
579
  }
@@ -917,12 +917,16 @@
917
917
  }
918
918
  renderContent() {
919
919
  if (!this.model.needRenderContent) {
920
- return React__namespace.createElement("div", { className: "svc-page__loading-content" },
920
+ return React__namespace.createElement("div", { className: this.model.loadingContentCss },
921
921
  React__namespace.createElement(surveyReactUi.LoadingIndicatorComponent, null));
922
922
  }
923
923
  return (React__namespace.createElement(PageElementContent, { page: this.props.page, survey: this.props.survey, creator: this.props.creator }));
924
924
  }
925
925
  renderHeader() {
926
+ // The loading placeholder renders no header and no footer: reading their action containers builds them
927
+ // (and fires onElementGetActions / onPageGetFooterActions) for every page, rendered or not.
928
+ if (!this.model.needRenderContent)
929
+ return null;
926
930
  const actions = (React__namespace.createElement("div", { className: "svc-page__content-actions" },
927
931
  React__namespace.createElement(surveyReactUi.SurveyActionBar, { model: this.model.actionContainer }),
928
932
  (this.model.topActionContainer.hasActions ? React__namespace.createElement(surveyReactUi.SurveyActionBar, { model: this.model.topActionContainer }) : null)));
@@ -934,6 +938,8 @@
934
938
  actions));
935
939
  }
936
940
  renderFooter() {
941
+ if (!this.model.needRenderContent)
942
+ return null;
937
943
  return React__namespace.createElement(surveyReactUi.SurveyActionBar, { model: this.model.footerActionsBar });
938
944
  }
939
945
  }
@@ -1196,7 +1202,7 @@
1196
1202
  this.model.item = this.props.item;
1197
1203
  const button = this.model.allowAdd ? (this.renderButton(this.model.addAction)) : (React__namespace.createElement(React__namespace.Fragment, null,
1198
1204
  " ",
1199
- this.model.isDraggable ? (React__namespace.createElement("span", { className: "svc-item-value-controls__drag" },
1205
+ this.model.isDraggable ? (React__namespace.createElement("span", { className: "svc-item-value-controls__drag", "data-sv-tooltip": this.model.dragTooltip },
1200
1206
  React__namespace.createElement(surveyReactUi.SvgIcon, { className: "svc-item-value-controls__drag-icon", size: "auto", iconName: "icon-drag-24x24", title: this.model.dragTooltip }))) : null,
1201
1207
  this.model.allowRemove ? this.renderButton(this.model.removeAction) : null));
1202
1208
  const itemkey = this.props.element.key + (this.model.allowAdd ? "_new" : "");
@@ -2524,7 +2530,7 @@
2524
2530
  const errors = React__namespace.createElement(TabJsonEditorErrorsComponent, { data: this.model });
2525
2531
  return (React__namespace.createElement("div", { className: "svc-creator-tab__content" },
2526
2532
  React__namespace.createElement("div", { className: "svc-json-editor-tab__content" },
2527
- React__namespace.createElement("textarea", { ref: input => (setControl(input)), className: "svc-json-editor-tab__content-area", value: this.model.text, onChange: (e) => (this.model.text = e.target.value), onKeyDown: (e) => this.model.checkKey(e, e), disabled: this.model.readOnly, "aria-label": this.model.ariaLabel }),
2533
+ React__namespace.createElement("textarea", { ref: input => (setControl(input)), className: "svc-json-editor-tab__content-area", value: this.model.text, onChange: (e) => this.model.onTextInput(e.target.value), onKeyDown: (e) => this.model.checkKey(e, e), disabled: this.model.readOnly, "aria-label": this.model.ariaLabel }),
2528
2534
  errors)));
2529
2535
  }
2530
2536
  }
@@ -2899,7 +2905,7 @@
2899
2905
  renderElement() {
2900
2906
  const tooltip = this.item.tooltip || this.item.title;
2901
2907
  const title = this.item.hasTitle ? React__namespace.createElement("span", { className: "svc-switcher__title" }, this.item.title) : null;
2902
- const button = surveyReactUi.attachKey2click(React__namespace.createElement("button", { className: this.item.getActionBarItemCss(), type: "button", disabled: this.item.disabled, onClick: (args) => this.item.action(this.item, this.item.getIsTrusted(args)), title: tooltip, "aria-checked": this.item.ariaChecked, "aria-expanded": this.item.ariaExpanded, role: this.item.ariaRole },
2908
+ const button = surveyReactUi.attachKey2click(React__namespace.createElement("button", { className: this.item.getActionBarItemCss(), type: "button", disabled: this.item.disabled, onClick: (args) => this.item.action(this.item, this.item.getIsTrusted(args)), title: tooltip, "data-sv-tooltip": tooltip, "aria-checked": this.item.ariaChecked, "aria-expanded": this.item.ariaExpanded, role: this.item.ariaRole },
2903
2909
  React__namespace.createElement("div", { className: this.item.getSwitcherIconCss() },
2904
2910
  React__namespace.createElement("div", { className: "svc-switcher__icon-thumb" })),
2905
2911
  title), this.item, { processEsc: false });
@@ -3008,7 +3014,7 @@
3008
3014
  if (!this.props.item.data.showFixButton)
3009
3015
  return null;
3010
3016
  const item = this.props.item;
3011
- return (surveyReactUi.attachKey2click(React__namespace.createElement("button", { type: "button", onClick: (event) => { event.stopPropagation(); item.data.fixError(); }, title: item.data.fixButtonTitle, className: "svc-json-error__fix-button" },
3017
+ return (surveyReactUi.attachKey2click(React__namespace.createElement("button", { type: "button", onClick: (event) => { event.stopPropagation(); item.data.fixError(); }, title: item.data.fixButtonTitle, "data-sv-tooltip": item.data.fixButtonTitle, className: "svc-json-error__fix-button" },
3012
3018
  React__namespace.createElement(surveyReactUi.SvgIcon, { iconName: item.data.fixButtonIcon, size: "auto" }))));
3013
3019
  }
3014
3020
  };
@@ -3201,7 +3207,7 @@
3201
3207
  }
3202
3208
  renderElement() {
3203
3209
  return (React__namespace.createElement("div", null,
3204
- surveyReactUi.attachKey2click(React__namespace.createElement("label", { onClick: event => this.question.chooseFiles(event.nativeEvent), className: this.item.getActionBarItemCss(), htmlFor: this.question.inputId, "aria-label": this.question.chooseButtonCaption },
3210
+ surveyReactUi.attachKey2click(React__namespace.createElement("label", { onClick: event => this.question.chooseFiles(event.nativeEvent), className: this.item.getActionBarItemCss(), htmlFor: this.question.inputId, "data-sv-tooltip": this.item.title, "aria-label": this.question.chooseButtonCaption },
3205
3211
  React__namespace.createElement(surveyReactUi.SvgIcon, { iconName: this.item.iconName, size: "auto", title: this.item.title, className: this.item.cssClasses.itemIcon }),
3206
3212
  React__namespace.createElement("span", { className: "sv-visuallyhidden" }, this.question.chooseButtonCaption))),
3207
3213
  React__namespace.createElement("input", { type: "file", disabled: this.item.disabled, className: this.question.cssClasses.fileInput, id: this.question.inputId, "aria-required": this.question.ariaRequired, "aria-label": this.question.ariaLabel, "aria-invalid": this.question.ariaInvalid, "aria-describedby": this.question.ariaDescribedBy, multiple: false, title: this.question.inputTitle, accept: this.question.acceptedTypes, tabIndex: -1, onChange: (event) => this.question.onFileInputChange(event.nativeEvent) })));
@@ -3215,8 +3221,8 @@
3215
3221
  });
3216
3222
 
3217
3223
  exports.Version = void 0;
3218
- exports.Version = `${"3.2.2"}`;
3219
- surveyCore.checkLibraryVersion(`${"3.2.2"}`, "survey-creator-react");
3224
+ exports.Version = `${"3.2.4"}`;
3225
+ surveyCore.checkLibraryVersion(`${"3.2.4"}`, "survey-creator-react");
3220
3226
 
3221
3227
  Object.defineProperty(exports, "PropertyGridEditorCollection", {
3222
3228
  enumerable: true,