survey-js-ui 3.2.5 → 3.2.6

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-js-ui",
3
- "version": "3.2.5",
3
+ "version": "3.2.6",
4
4
  "license": "MIT",
5
5
  "homepage": "https://surveyjs.io/",
6
6
  "author": "DevSoft Baltic OU <info@devsoftbaltic.com>",
@@ -60,7 +60,7 @@
60
60
  },
61
61
  "dependencies": {},
62
62
  "peerDependencies": {
63
- "survey-core": "3.2.5",
63
+ "survey-core": "3.2.6",
64
64
  "@types/react-dom": "*",
65
65
  "@types/react": "*"
66
66
  }
package/survey-js-ui.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * surveyjs - Survey JavaScript library v3.2.5
2
+ * surveyjs - Survey JavaScript library v3.2.6
3
3
  * Copyright (c) 2015-2026 Devsoft Baltic OÜ - http://surveyjs.io/
4
4
  * License: MIT (http://www.opensource.org/licenses/mit-license.php)
5
5
  */
@@ -605,15 +605,18 @@
605
605
  renderButtonContent() {
606
606
  const text = this.renderText();
607
607
  const svgIcon = !!this.item.iconName ? (_$1(SvgIcon, { className: this.item.cssClasses.itemIcon, size: this.item.iconSize, iconName: this.item.iconName, title: this.item.tooltip || this.item.title })) : null;
608
+ // A trailing icon (a filter chip's chevron); the bar's cssClasses give its class.
609
+ const markerIcon = !!this.item.markerIconName ? (_$1(SvgIcon, { className: this.item.cssClasses.itemMarkerIcon, iconName: this.item.markerIconName, size: "auto" })) : null;
608
610
  return (_$1(k$2, null,
609
611
  svgIcon,
610
- text));
612
+ text,
613
+ markerIcon));
611
614
  }
612
615
  renderInnerButton() {
613
616
  const className = this.item.getActionBarItemCss();
614
617
  const buttonContent = this.renderButtonContent();
615
618
  const tabIndex = this.item.disableTabStop ? -1 : undefined;
616
- const button = attachKey2click(_$1("button", { ref: this.ref, className: className, type: "button", disabled: this.item.disabled, onMouseDown: (args) => this.item.doMouseDown(args), onFocus: (args) => this.item.doFocus(args), onClick: (args) => this.item.doAction(args), title: this.item.getTooltip(), "data-sv-tooltip": this.item.getTooltip(), tabIndex: tabIndex, "aria-checked": this.item.ariaChecked, "aria-expanded": this.item.ariaExpanded, "aria-controls": this.item.ariaControls, "aria-labelledby": this.item.ariaLabelledBy, "aria-label": this.item.ariaLabel, role: this.item.ariaRole }, buttonContent), this.item, { processEsc: false });
619
+ const button = attachKey2click(_$1("button", { ref: this.ref, className: className, type: "button", disabled: this.item.disabled, onMouseDown: (args) => this.item.doMouseDown(args), onFocus: (args) => this.item.doFocus(args), onClick: (args) => this.item.doAction(args), title: this.item.getTooltip(), "data-sv-tooltip": this.item.getTooltip(), tabIndex: tabIndex, "aria-checked": this.item.ariaChecked, "aria-expanded": this.item.ariaExpanded, "aria-controls": this.item.ariaControls, "aria-labelledby": this.item.ariaLabelledBy, "aria-describedby": this.item.ariaDescribedBy, "aria-label": this.item.ariaLabel, role: this.item.ariaRole }, buttonContent), this.item, { processEsc: false });
617
620
  return button;
618
621
  }
619
622
  componentDidMount() {
@@ -900,19 +903,25 @@
900
903
 
901
904
  class ComponentsContainer extends SurveyElementBase {
902
905
  renderElement() {
903
- const components = this.props.survey.getContainerContent(this.props.container);
906
+ const groups = this.props.survey.getContainerContentGroups(this.props.container);
904
907
  const needRenderWrapper = this.props.needRenderWrapper === false ? false : true;
905
- if (components.length == 0) {
908
+ if (groups.length == 0) {
906
909
  return null;
907
910
  }
911
+ const content = groups.map(group => this.renderGroup(group));
908
912
  if (!needRenderWrapper) {
909
- return _$1(k$2, null, components.map(component => {
910
- return ReactElementFactory.Instance.createElement(component.component, { survey: this.props.survey, model: component.data, container: this.props.container, key: component.id });
911
- }));
913
+ return _$1(k$2, null, content);
914
+ }
915
+ return _$1("div", { className: "sv-components-column" + " sv-components-container-" + this.props.container }, content);
916
+ }
917
+ renderGroup(group) {
918
+ if (!group.css) {
919
+ return this.renderComponent(group.elements[0]);
912
920
  }
913
- return _$1("div", { className: "sv-components-column" + " sv-components-container-" + this.props.container }, components.map(component => {
914
- return ReactElementFactory.Instance.createElement(component.component, { survey: this.props.survey, model: component.data, container: this.props.container, key: component.id });
915
- }));
921
+ return _$1("div", { className: group.css, key: group.key }, group.elements.map(component => this.renderComponent(component)));
922
+ }
923
+ renderComponent(component) {
924
+ return ReactElementFactory.Instance.createElement(component.component, { survey: this.props.survey, model: component.data, container: this.props.container, key: component.id });
916
925
  }
917
926
  }
918
927
  ReactElementFactory.Instance.registerElement("sv-components-container", (props) => {
@@ -1237,6 +1246,10 @@
1237
1246
 
1238
1247
  var draghorizontal_24x16 = "<svg viewBox=\"0 0 24 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M17.5 9.25C16.81 9.25 16.25 9.81 16.25 10.5C16.25 11.19 16.81 11.75 17.5 11.75C18.19 11.75 18.75 11.19 18.75 10.5C18.75 9.81 18.19 9.25 17.5 9.25ZM17.25 10.5C17.25 10.36 17.36 10.25 17.5 10.25C17.64 10.25 17.75 10.36 17.75 10.5C17.75 10.78 17.25 10.78 17.25 10.5ZM17.5 6.75C18.19 6.75 18.75 6.19 18.75 5.5C18.75 4.81 18.19 4.25 17.5 4.25C16.81 4.25 16.25 4.81 16.25 5.5C16.25 6.19 16.81 6.75 17.5 6.75ZM17.5 5.25C17.64 5.25 17.75 5.36 17.75 5.5C17.75 5.78 17.25 5.78 17.25 5.5C17.25 5.36 17.36 5.25 17.5 5.25ZM12.5 9.25C11.81 9.25 11.25 9.81 11.25 10.5C11.25 11.19 11.81 11.75 12.5 11.75C13.19 11.75 13.75 11.19 13.75 10.5C13.75 9.81 13.19 9.25 12.5 9.25ZM12.25 10.5C12.25 10.36 12.36 10.25 12.5 10.25C12.64 10.25 12.75 10.36 12.75 10.5C12.75 10.78 12.25 10.78 12.25 10.5ZM12.5 4.25C11.81 4.25 11.25 4.81 11.25 5.5C11.25 6.19 11.81 6.75 12.5 6.75C13.19 6.75 13.75 6.19 13.75 5.5C13.75 4.81 13.19 4.25 12.5 4.25ZM12.25 5.5C12.25 5.36 12.36 5.25 12.5 5.25C12.64 5.25 12.75 5.36 12.75 5.5C12.75 5.78 12.25 5.78 12.25 5.5ZM7.5 9.25C6.81 9.25 6.25 9.81 6.25 10.5C6.25 11.19 6.81 11.75 7.5 11.75C8.19 11.75 8.75 11.19 8.75 10.5C8.75 9.81 8.19 9.25 7.5 9.25ZM7.25 10.5C7.25 10.36 7.36 10.25 7.5 10.25C7.64 10.25 7.75 10.36 7.75 10.5C7.75 10.78 7.25 10.78 7.25 10.5ZM7.5 4.25C6.81 4.25 6.25 4.81 6.25 5.5C6.25 6.19 6.81 6.75 7.5 6.75C8.19 6.75 8.75 6.19 8.75 5.5C8.75 4.81 8.19 4.25 7.5 4.25ZM7.25 5.5C7.25 5.36 7.36 5.25 7.5 5.25C7.64 5.25 7.75 5.36 7.75 5.5C7.75 5.78 7.25 5.78 7.25 5.5Z\"/></svg>";
1239
1248
 
1249
+ var edit_16x16 = "<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M14.1209 2.0525L13.9509 1.8825C12.8809 0.812502 11.1309 0.812502 10.0609 1.8825L2.47089 9.4625C2.37089 9.5625 2.31089 9.6825 2.27089 9.8125L1.27089 13.8125C1.21089 14.0625 1.28089 14.3425 1.47089 14.5225C1.61089 14.6625 1.80089 14.7425 2.00089 14.7425C2.06089 14.7425 2.12089 14.7425 2.18089 14.7225L6.18089 13.7225C6.31089 13.6925 6.43089 13.6225 6.53089 13.5225L14.1209 5.9325C15.1909 4.8625 15.1909 3.1125 14.1209 2.0425V2.0525ZM5.62089 12.3125L3.04089 12.9625L3.69089 10.3825L9.00089 5.0525L10.9409 6.9925L5.62089 12.3125ZM13.0609 4.8725L12.0009 5.9325L10.0609 3.9925L11.1209 2.9325C11.6109 2.4425 12.4009 2.4425 12.8909 2.9325L13.0609 3.1025C13.5509 3.5925 13.5509 4.3825 13.0609 4.8725Z\"/></svg>";
1250
+
1251
+ var edit_24x24 = "<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M20.1301 6.05252L17.9601 3.88252C16.8901 2.81252 15.1401 2.81252 14.0701 3.88252L4.48014 13.4625C4.37014 13.5725 4.30014 13.7125 4.27014 13.8725L3.26014 19.8725C3.22014 20.1125 3.30014 20.3525 3.47014 20.5225C3.61014 20.6625 3.80014 20.7425 4.00014 20.7425C4.04014 20.7425 4.08014 20.7425 4.12014 20.7425L10.1201 19.7425C10.2701 19.7125 10.4201 19.6425 10.5301 19.5325L20.1201 9.94252C20.6401 9.42252 20.9301 8.73252 20.9301 8.00252C20.9301 7.27252 20.6401 6.57252 20.1201 6.06252L20.1301 6.05252ZM16.0101 11.9325L12.0701 7.99252L13.0101 7.05252L16.9501 10.9925L16.0101 11.9325ZM9.65014 18.2925L4.92014 19.0825L5.71014 14.3525L11.0101 9.05252L14.9501 12.9925L9.65014 18.2925ZM19.0701 8.87252L18.0101 9.93252L14.0701 5.99252L15.1301 4.93252C15.6201 4.44252 16.4101 4.44252 16.9001 4.93252L19.0701 7.10252C19.3101 7.34252 19.4401 7.65252 19.4401 7.98252C19.4401 8.31252 19.3101 8.63252 19.0701 8.86252V8.87252Z\"/></svg>";
1252
+
1240
1253
  var editsmall_16x16 = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\"><path d=\"M13.1209 3.05249L12.9509 2.88249C11.8809 1.81249 10.1309 1.81249 9.06089 2.88249L3.47089 8.46249C3.37089 8.56249 3.31089 8.68249 3.27089 8.81249L2.27089 12.8125C2.21089 13.0625 2.28089 13.3425 2.47089 13.5225C2.61089 13.6625 2.80089 13.7425 3.00089 13.7425C3.06089 13.7425 3.12089 13.7425 3.18089 13.7225L7.18089 12.7225C7.31089 12.6925 7.43089 12.6225 7.53089 12.5225L13.1209 6.93249C14.1909 5.86249 14.1909 4.11249 13.1209 3.04249V3.05249ZM6.62089 11.3125L4.04089 11.9625L4.69089 9.38249L8.01089 6.06249L9.95089 8.00249L6.63089 11.3225L6.62089 11.3125ZM12.0609 5.87249L11.0009 6.93249L9.06089 4.99249L10.1209 3.93249C10.6109 3.44249 11.4009 3.44249 11.8909 3.93249L12.0609 4.10249C12.5509 4.59249 12.5509 5.38249 12.0609 5.87249Z\"/></svg>";
1241
1254
 
1242
1255
  var expand_16x16 = "<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.75 8C11.75 8.41 11.41 8.75 11 8.75H8.75V11C8.75 11.41 8.41 11.75 8 11.75C7.59 11.75 7.25 11.41 7.25 11V8.75H5C4.59 8.75 4.25 8.41 4.25 8C4.25 7.59 4.59 7.25 5 7.25H7.25V5C7.25 4.59 7.59 4.25 8 4.25C8.41 4.25 8.75 4.59 8.75 5V7.25H11C11.41 7.25 11.75 7.59 11.75 8Z\"/></svg>";
@@ -1245,6 +1258,10 @@
1245
1258
 
1246
1259
  var file_72x72 = "<svg viewBox=\"0 0 72 72\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M62.83 12.83L53.17 3.17C52.7982 2.79866 52.357 2.50421 51.8714 2.30346C51.3858 2.1027 50.8654 1.99959 50.34 2H14C12.4087 2 10.8826 2.63214 9.75735 3.75736C8.63214 4.88258 8 6.4087 8 8V64C8 65.5913 8.63214 67.1174 9.75735 68.2426C10.8826 69.3679 12.4087 70 14 70H58C59.5913 70 61.1174 69.3679 62.2426 68.2426C63.3679 67.1174 64 65.5913 64 64V15.66C64.0004 15.1346 63.8973 14.6142 63.6965 14.1286C63.4958 13.643 63.2013 13.2018 62.83 12.83ZM52 4.83L61.17 14H56C54.9391 14 53.9217 13.5786 53.1716 12.8284C52.4214 12.0783 52 11.0609 52 10V4.83ZM62 64C62 65.0609 61.5786 66.0783 60.8284 66.8284C60.0783 67.5786 59.0609 68 58 68H14C12.9391 68 11.9217 67.5786 11.1716 66.8284C10.4214 66.0783 10 65.0609 10 64V8C10 6.93914 10.4214 5.92172 11.1716 5.17157C11.9217 4.42143 12.9391 4 14 4H50V10C50 11.5913 50.6321 13.1174 51.7574 14.2426C52.8826 15.3679 54.4087 16 56 16H62V64ZM22 26H50V28H22V26ZM22 32H50V34H22V32ZM22 38H50V40H22V38ZM22 44H50V46H22V44Z\"/></svg>";
1247
1260
 
1261
+ var filter_16x16 = "<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M14 10.25H12.63C12.3 9.1 11.25 8.25 10 8.25C8.75 8.25 7.7 9.1 7.37 10.25H2C1.59 10.25 1.25 10.59 1.25 11C1.25 11.41 1.59 11.75 2 11.75H7.37C7.7 12.9 8.75 13.75 10 13.75C11.25 13.75 12.3 12.9 12.63 11.75H14C14.41 11.75 14.75 11.41 14.75 11C14.75 10.59 14.41 10.25 14 10.25ZM10 12.25C9.31 12.25 8.75 11.69 8.75 11C8.75 10.31 9.31 9.75 10 9.75C10.69 9.75 11.25 10.31 11.25 11C11.25 11.69 10.69 12.25 10 12.25ZM2 5.75H3.37C3.7 6.9 4.75 7.75 6 7.75C7.25 7.75 8.3 6.9 8.63 5.75H14C14.41 5.75 14.75 5.41 14.75 5C14.75 4.59 14.41 4.25 14 4.25H8.63C8.3 3.1 7.25 2.25 6 2.25C4.75 2.25 3.7 3.1 3.37 4.25H2C1.59 4.25 1.25 4.59 1.25 5C1.25 5.41 1.59 5.75 2 5.75ZM6 3.75C6.69 3.75 7.25 4.31 7.25 5C7.25 5.69 6.69 6.25 6 6.25C5.31 6.25 4.75 5.69 4.75 5C4.75 4.31 5.31 3.75 6 3.75Z\"/></svg>";
1262
+
1263
+ var filter_24x24 = "<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M3 6.75H5.37C5.7 7.9 6.75 8.75 8 8.75C9.25 8.75 10.3 7.9 10.63 6.75H21C21.41 6.75 21.75 6.41 21.75 6C21.75 5.59 21.41 5.25 21 5.25H10.63C10.3 4.1 9.25 3.25 8 3.25C6.75 3.25 5.7 4.1 5.37 5.25H3C2.59 5.25 2.25 5.59 2.25 6C2.25 6.41 2.59 6.75 3 6.75ZM8 4.75C8.69 4.75 9.25 5.31 9.25 6C9.25 6.69 8.69 7.25 8 7.25C7.31 7.25 6.75 6.69 6.75 6C6.75 5.31 7.31 4.75 8 4.75ZM21 11.25H18.63C18.3 10.1 17.25 9.25 16 9.25C14.75 9.25 13.7 10.1 13.37 11.25H3C2.59 11.25 2.25 11.59 2.25 12C2.25 12.41 2.59 12.75 3 12.75H13.37C13.7 13.9 14.75 14.75 16 14.75C17.25 14.75 18.3 13.9 18.63 12.75H21C21.41 12.75 21.75 12.41 21.75 12C21.75 11.59 21.41 11.25 21 11.25ZM16 13.25C15.31 13.25 14.75 12.69 14.75 12C14.75 11.31 15.31 10.75 16 10.75C16.69 10.75 17.25 11.31 17.25 12C17.25 12.69 16.69 13.25 16 13.25ZM21 17.25H10.63C10.3 16.1 9.25 15.25 8 15.25C6.75 15.25 5.7 16.1 5.37 17.25H3C2.59 17.25 2.25 17.59 2.25 18C2.25 18.41 2.59 18.75 3 18.75H5.37C5.7 19.9 6.75 20.75 8 20.75C9.25 20.75 10.3 19.9 10.63 18.75H21C21.41 18.75 21.75 18.41 21.75 18C21.75 17.59 21.41 17.25 21 17.25ZM8 19.25C7.31 19.25 6.75 18.69 6.75 18C6.75 17.31 7.31 16.75 8 16.75C8.69 16.75 9.25 17.31 9.25 18C9.25 18.69 8.69 19.25 8 19.25Z\"/></svg>";
1264
+
1248
1265
  var flip_24x24 = "<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M14.53 17.4775C14.82 17.7675 14.82 18.2475 14.53 18.5375L11.53 21.5375C11.38 21.6875 11.19 21.7575 11 21.7575C10.81 21.7575 10.62 21.6875 10.47 21.5375C10.18 21.2475 10.18 20.7675 10.47 20.4775L12.2 18.7475C12.13 18.7475 12.07 18.7475 12 18.7475C6.62 18.7475 2.25 15.7475 2.25 12.0575C2.25 10.2975 3.22 8.6375 4.99 7.3875C5.33 7.1475 5.8 7.2275 6.03 7.5675C6.27 7.9075 6.19 8.3775 5.85 8.6075C4.49 9.5675 3.74 10.7875 3.74 12.0575C3.74 14.9175 7.44 17.2475 11.99 17.2475C12.05 17.2475 12.11 17.2475 12.17 17.2475L10.46 15.5375C10.17 15.2475 10.17 14.7675 10.46 14.4775C10.75 14.1875 11.23 14.1875 11.52 14.4775L14.52 17.4775H14.53ZM12 5.2575C11.93 5.2575 11.87 5.2575 11.8 5.2575L13.53 3.5275C13.82 3.2375 13.82 2.7575 13.53 2.4675C13.24 2.1775 12.76 2.1775 12.47 2.4675L9.47 5.4675C9.18 5.7575 9.18 6.2375 9.47 6.5275L12.47 9.5275C12.62 9.6775 12.81 9.7475 13 9.7475C13.19 9.7475 13.38 9.6775 13.53 9.5275C13.82 9.2375 13.82 8.7575 13.53 8.4675L11.82 6.7575C11.88 6.7575 11.94 6.7575 12 6.7575C16.55 6.7575 20.25 9.0875 20.25 11.9475C20.25 13.2075 19.5 14.4375 18.14 15.3975C17.8 15.6375 17.72 16.1075 17.96 16.4475C18.11 16.6575 18.34 16.7675 18.57 16.7675C18.72 16.7675 18.87 16.7275 19 16.6275C20.77 15.3775 21.75 13.7175 21.75 11.9575C21.75 8.2675 17.38 5.2675 12 5.2675V5.2575Z\"/></svg>";
1249
1266
 
1250
1267
  var folder_24x24 = "<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M21.72 9.24C21.45 8.92 21.12 8.67 20.75 8.5V8C20.75 6.48 19.52 5.25 18 5.25H10.65C10.32 4.1 9.26 3.25 8 3.25H6C4.48 3.25 3.25 4.48 3.25 6V18C3.25 19.52 4.48 20.75 6 20.75H18.33C19.66 20.75 20.8 19.8 21.04 18.49L22.31 11.49C22.46 10.69 22.24 9.86 21.72 9.24ZM4.75 18V6C4.75 5.31 5.31 4.75 6 4.75H8C8.69 4.75 9.25 5.31 9.25 6C9.25 6.41 9.59 6.75 10 6.75H18C18.69 6.75 19.25 7.31 19.25 8V8.25H9.27C7.94 8.25 6.8 9.2 6.56 10.51L5.29 17.51C5.19 18.07 5.27 18.64 5.51 19.15C5.06 18.96 4.75 18.52 4.75 18ZM20.83 11.22L19.56 18.22C19.45 18.81 18.94 19.25 18.33 19.25H8C7.63 19.25 7.28 19.09 7.04 18.8C6.8 18.51 6.7 18.14 6.77 17.78L8.04 10.78C8.15 10.19 8.66 9.75 9.27 9.75H19.6C19.97 9.75 20.32 9.91 20.56 10.2C20.8 10.49 20.9 10.86 20.83 11.22Z\"/></svg>";
@@ -1271,6 +1288,8 @@
1271
1288
 
1272
1289
  var plus_16x16 = "<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M8 2.25C8.41 2.25 8.75 2.59 8.75 3V7.25H13C13.41 7.25 13.75 7.59 13.75 8C13.75 8.41 13.41 8.75 13 8.75H8.75V13C8.75 13.41 8.41 13.75 8 13.75C7.59 13.75 7.25 13.41 7.25 13V8.75H3C2.59 8.75 2.25 8.41 2.25 8C2.25 7.59 2.59 7.25 3 7.25H7.25V3C7.25 2.59 7.59 2.25 8 2.25Z\"/></svg>";
1273
1290
 
1291
+ var plus_24x24 = "<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 2.5C12.4142 2.5 12.75 2.83579 12.75 3.25V11.25H20.75L20.8271 11.2539C21.2051 11.2925 21.5 11.6118 21.5 12C21.5 12.3882 21.2051 12.7075 20.8271 12.7461L20.75 12.75H12.75V20.75L12.7461 20.8271C12.7075 21.2051 12.3882 21.5 12 21.5C11.6118 21.5 11.2925 21.2051 11.2539 20.8271L11.25 20.75V12.75H3.25C2.83579 12.75 2.5 12.4142 2.5 12C2.5 11.5858 2.83579 11.25 3.25 11.25H11.25V3.25C11.25 2.83579 11.5858 2.5 12 2.5Z\"/></svg>";
1292
+
1274
1293
  var radio_16x16 = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\"><circle cx=\"8\" cy=\"8\" r=\"4\"/></svg>";
1275
1294
 
1276
1295
  var ranking_arrows = "<svg viewBox=\"0 0 10 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M10 5L5 0L0 5H4V9H6V5H10Z\"/><path d=\"M6 19V15H4V19H0L5 24L10 19H6Z\"/></svg>";
@@ -1317,6 +1336,12 @@
1317
1336
 
1318
1337
  var sort_16x16 = "<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M5.28284 7.47861C5.37477 7.51396 5.45962 7.57053 5.53033 7.64124L8.35876 10.4697C8.64867 10.7596 8.64867 11.2404 8.35876 11.5303C8.06884 11.8202 7.58801 11.8202 7.2981 11.5303L5.74953 9.98177L5.74953 13.8284C5.74953 14.0406 5.66468 14.2244 5.53033 14.3588C5.39598 14.4931 5.21213 14.578 5 14.578C4.58988 14.578 4.25047 14.2385 4.25047 13.8284L4.25047 9.98177L2.7019 11.5303C2.41199 11.8202 1.93116 11.8202 1.64124 11.5303C1.35133 11.2404 1.35133 10.7596 1.64124 10.4697L4.46967 7.64124C4.54038 7.57053 4.61816 7.52103 4.71716 7.47861C4.901 7.4079 5.10607 7.40083 5.29698 7.47861H5.28284ZM13.296 4.47467L11.7475 6.02323L11.7475 2.17657C11.7475 1.76645 11.4081 1.42704 10.9979 1.42704C10.5878 1.42704 10.2484 1.76645 10.2484 2.17657V6.02323L8.69983 4.47467C8.40992 4.18476 7.92909 4.18476 7.63917 4.47467C7.34926 4.76458 7.34926 5.24542 7.63917 5.53533L10.4676 8.36376C10.5383 8.43447 10.6161 8.48397 10.7151 8.52639C10.8989 8.5971 11.104 8.60417 11.2949 8.52639C11.3868 8.49104 11.4717 8.43447 11.5424 8.36376L14.3708 5.53533C14.6607 5.24542 14.6607 4.76458 14.3708 4.47467C14.0809 4.18476 13.6001 4.18476 13.3102 4.47467H13.296Z\"/></svg>";
1319
1338
 
1339
+ var sparkle_16x16 = "<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M6.93913 2.02558C7.06326 1.97411 7.20302 1.97411 7.32715 2.02558L7.38835 2.05553L7.46061 2.10696C7.52321 2.16012 7.55765 2.21612 7.57324 2.24368C7.5962 2.28429 7.6084 2.31948 7.61295 2.33287C7.61842 2.34897 7.62251 2.36247 7.62402 2.36803L7.62793 2.38235L7.94564 3.61477C8.18302 4.53503 8.27919 4.88338 8.45801 5.161C8.6253 5.42063 8.84616 5.64149 9.10579 5.80878C9.38341 5.9876 9.73176 6.08377 10.652 6.32115L11.8844 6.63886C11.8864 6.63937 11.8927 6.64112 11.8988 6.64277C11.9043 6.64428 11.9178 6.64837 11.9339 6.65384C11.9473 6.65839 11.9825 6.67059 12.0231 6.69355C12.0507 6.70914 12.1067 6.74358 12.1598 6.80618L12.2113 6.87845L12.2412 6.93964C12.3013 7.08459 12.2915 7.25106 12.2113 7.38886C12.1473 7.49861 12.0599 7.55296 12.0231 7.57376C11.9825 7.59672 11.9473 7.60892 11.9339 7.61347C11.9178 7.61894 11.9043 7.62302 11.8988 7.62454C11.8927 7.62619 11.8864 7.62794 11.8844 7.62844L10.652 7.94615C9.73176 8.18354 9.38341 8.27971 9.10579 8.45852C8.84616 8.62581 8.6253 8.84667 8.45801 9.10631C8.27919 9.38393 8.18302 9.73228 7.94564 10.6525L7.62793 11.885C7.62742 11.8869 7.62568 11.8932 7.62402 11.8993C7.62251 11.9048 7.61842 11.9183 7.61295 11.9344C7.6084 11.9478 7.5962 11.983 7.57324 12.0236C7.55244 12.0604 7.4981 12.1479 7.38835 12.2118C7.23075 12.3036 7.03552 12.3036 6.87793 12.2118C6.76818 12.1479 6.71383 12.0604 6.69303 12.0236C6.67007 11.983 6.65787 11.9478 6.65332 11.9344C6.64785 11.9183 6.64377 11.9048 6.64225 11.8993C6.6406 11.8932 6.63885 11.8869 6.63835 11.885L6.32064 10.6525C6.08325 9.73228 5.98708 9.38393 5.80827 9.10631C5.64098 8.84667 5.42012 8.62581 5.16048 8.45852C4.88286 8.27971 4.53451 8.18354 3.61426 7.94615L2.38183 7.62844C2.37988 7.62794 2.37359 7.62619 2.36751 7.62454C2.36195 7.62302 2.34846 7.61894 2.33236 7.61347C2.31896 7.60892 2.28377 7.59672 2.24316 7.57376C2.2064 7.55296 2.11894 7.49861 2.05501 7.38886C1.96324 7.23127 1.96324 7.03604 2.05501 6.87845L2.10644 6.80618C2.15961 6.74358 2.2156 6.70914 2.24316 6.69355C2.28377 6.67059 2.31896 6.65839 2.33236 6.65384C2.34846 6.64837 2.36195 6.64428 2.36751 6.64277C2.37359 6.64112 2.37988 6.63937 2.38183 6.63886L3.61426 6.32115C4.53451 6.08377 4.88286 5.9876 5.16048 5.80878C5.42012 5.64149 5.64098 5.42063 5.80827 5.161C5.98708 4.88338 6.08325 4.53503 6.32064 3.61477L6.63835 2.38235C6.63885 2.3804 6.6406 2.37411 6.64225 2.36803C6.64377 2.36247 6.64785 2.34897 6.65332 2.33287C6.65787 2.31948 6.67007 2.28429 6.69303 2.24368C6.71383 2.20692 6.76818 2.11946 6.87793 2.05553L6.93913 2.02558ZM7.13314 4.46048C6.99075 4.98691 6.86295 5.3704 6.64941 5.70201C6.40479 6.0818 6.08129 6.4053 5.7015 6.64993C5.36988 6.86346 4.98639 6.99127 4.45996 7.13365C4.98639 7.27604 5.36988 7.40384 5.7015 7.61738C6.08129 7.862 6.40479 8.1855 6.64941 8.56529C6.86286 8.89678 6.99082 9.28006 7.13314 9.80618C7.27546 9.28006 7.40341 8.89678 7.61686 8.56529C7.86149 8.1855 8.18499 7.862 8.56478 7.61738C8.89626 7.40393 9.27955 7.27597 9.80566 7.13365C9.27955 6.99133 8.89626 6.86338 8.56478 6.64993C8.18499 6.4053 7.86149 6.0818 7.61686 5.70201C7.40333 5.3704 7.27552 4.98691 7.13314 4.46048Z\"/><path d=\"M12.1476 10.848C12.2435 10.533 12.6895 10.533 12.7854 10.848L13.037 11.6746C13.0693 11.7809 13.1525 11.8641 13.2588 11.8965L14.0854 12.1481C14.4005 12.244 14.4005 12.69 14.0854 12.7859L13.2588 13.0375C13.1525 13.0698 13.0693 13.153 13.037 13.2593L12.7854 14.0859C12.6895 14.401 12.2435 14.401 12.1476 14.0859L11.896 13.2593C11.8637 13.153 11.7805 13.0698 11.6742 13.0375L10.8475 12.7859C10.5325 12.69 10.5325 12.244 10.8475 12.1481L11.6742 11.8965C11.7805 11.8641 11.8637 11.7809 11.896 11.6746L12.1476 10.848Z\"/><path d=\"M11.2087 1.82878C11.2662 1.63976 11.5338 1.63976 11.5913 1.82878L11.7578 2.37587C11.7773 2.43964 11.8272 2.48955 11.8909 2.50897L12.438 2.67548C12.6271 2.73301 12.6271 3.00062 12.438 3.05815L11.8909 3.22467C11.8272 3.24408 11.7773 3.29399 11.7578 3.35777L11.5913 3.90486C11.5338 4.09388 11.2662 4.09388 11.2087 3.90486L11.0421 3.35777C11.0227 3.29399 10.9728 3.24408 10.909 3.22467L10.362 3.05815C10.1729 3.00062 10.1729 2.73301 10.362 2.67548L10.909 2.50897C10.9728 2.48955 11.0227 2.43964 11.0421 2.37587L11.2087 1.82878Z\"/></svg>";
1340
+
1341
+ var sparkle_24x24 = "<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M10.4087 3.03837C10.5949 2.96117 10.8045 2.96117 10.9907 3.03837L11.0825 3.08329L11.1909 3.16044C11.2848 3.24018 11.3365 3.32417 11.3599 3.36552C11.3943 3.42643 11.4126 3.47921 11.4194 3.49931C11.4276 3.52346 11.4338 3.5437 11.436 3.55204L11.4419 3.57353L11.9185 5.42216C12.2745 6.80254 12.4188 7.32507 12.687 7.7415C12.9379 8.13095 13.2692 8.46224 13.6587 8.71318C14.0751 8.9814 14.5976 9.12565 15.978 9.48173L17.8267 9.95829C17.8296 9.95905 17.839 9.96167 17.8481 9.96415C17.8565 9.96642 17.8767 9.97255 17.9009 9.98075C17.921 9.98758 17.9738 10.0059 18.0347 10.0403C18.076 10.0637 18.16 10.1154 18.2397 10.2093L18.3169 10.3177L18.3618 10.4095C18.452 10.6269 18.4373 10.8766 18.3169 11.0833C18.221 11.2479 18.0898 11.3294 18.0347 11.3606C17.9738 11.3951 17.921 11.4134 17.9009 11.4202C17.8767 11.4284 17.8565 11.4345 17.8481 11.4368C17.839 11.4393 17.8296 11.4419 17.8267 11.4427L15.978 11.9192C14.5976 12.2753 14.0751 12.4196 13.6587 12.6878C13.2692 12.9387 12.9379 13.27 12.687 13.6595C12.4188 14.0759 12.2745 14.5984 11.9185 15.9788L11.4419 17.8274C11.4411 17.8304 11.4385 17.8398 11.436 17.8489C11.4338 17.8573 11.4276 17.8775 11.4194 17.9017C11.4126 17.9217 11.3943 17.9745 11.3599 18.0354C11.3287 18.0906 11.2471 18.2218 11.0825 18.3177C10.8461 18.4553 10.5533 18.4553 10.3169 18.3177C10.1523 18.2218 10.0707 18.0906 10.0395 18.0354C10.0051 17.9745 9.9868 17.9217 9.97998 17.9017C9.97178 17.8775 9.96565 17.8573 9.96338 17.8489C9.9609 17.8398 9.95827 17.8304 9.95752 17.8274L9.48096 15.9788C9.12487 14.5984 8.98062 14.0759 8.7124 13.6595C8.46146 13.27 8.13017 12.9387 7.74072 12.6878C7.3243 12.4196 6.80177 12.2753 5.42139 11.9192L3.57275 11.4427C3.56982 11.4419 3.56038 11.4393 3.55127 11.4368C3.54292 11.4345 3.52268 11.4284 3.49853 11.4202C3.47844 11.4134 3.42566 11.3951 3.36474 11.3606C3.3096 11.3294 3.17841 11.2479 3.08252 11.0833C2.94486 10.8469 2.94486 10.5541 3.08252 10.3177L3.15967 10.2093C3.23941 10.1154 3.3234 10.0637 3.36474 10.0403C3.42566 10.0059 3.47844 9.98758 3.49853 9.98075C3.52268 9.97255 3.54292 9.96642 3.55127 9.96415C3.56038 9.96167 3.56982 9.95905 3.57275 9.95829L5.42139 9.48173C6.80177 9.12565 7.3243 8.9814 7.74072 8.71318C8.13017 8.46224 8.46146 8.13095 8.7124 7.7415C8.98062 7.32507 9.12487 6.80254 9.48096 5.42216L9.95752 3.57353C9.95827 3.57059 9.9609 3.56116 9.96338 3.55204C9.96565 3.5437 9.97178 3.52346 9.97998 3.49931C9.9868 3.47921 10.0051 3.42643 10.0395 3.36552C10.0707 3.31037 10.1523 3.17918 10.3169 3.08329L10.4087 3.03837ZM10.6997 6.69071C10.4861 7.48036 10.2944 8.0556 9.97412 8.55302C9.60718 9.1227 9.12193 9.60796 8.55224 9.97489C8.05482 10.2952 7.47958 10.4869 6.68994 10.7005C7.47958 10.9141 8.05482 11.1058 8.55224 11.4261C9.12193 11.793 9.60718 12.2783 9.97412 12.8479C10.2943 13.3452 10.4862 13.9201 10.6997 14.7093C10.9132 13.9201 11.1051 13.3452 11.4253 12.8479C11.7922 12.2783 12.2775 11.793 12.8472 11.4261C13.3444 11.1059 13.9193 10.914 14.7085 10.7005C13.9193 10.487 13.3444 10.2951 12.8472 9.97489C12.2775 9.60796 11.7922 9.1227 11.4253 8.55302C11.105 8.0556 10.9133 7.48036 10.6997 6.69071Z\"/><path d=\"M18.2214 16.272C18.3652 15.7995 19.0342 15.7995 19.1781 16.272L19.5555 17.512C19.604 17.6714 19.7288 17.7962 19.8882 17.8447L21.1282 18.2221C21.6007 18.3659 21.6007 19.035 21.1282 19.1788L19.8882 19.5562C19.7288 19.6047 19.604 19.7295 19.5555 19.8889L19.1781 21.1289C19.0342 21.6014 18.3652 21.6014 18.2214 21.1289L17.844 19.8889C17.7955 19.7295 17.6707 19.6047 17.5113 19.5562L16.2713 19.1788C15.7988 19.035 15.7988 18.3659 16.2713 18.2221L17.5113 17.8447C17.6707 17.7962 17.7955 17.6714 17.844 17.512L18.2214 16.272Z\"/><path d=\"M16.813 2.74316C16.8993 2.45964 17.3007 2.45964 17.387 2.74316L17.6368 3.5638C17.6659 3.65946 17.7408 3.73433 17.8364 3.76345L18.6571 4.01322C18.9406 4.09952 18.9406 4.50093 18.6571 4.58722L17.8364 4.837C17.7408 4.86612 17.6659 4.94098 17.6368 5.03665L17.387 5.85728C17.3007 6.14081 16.8993 6.14081 16.813 5.85729L16.5632 5.03665C16.5341 4.94098 16.4592 4.86612 16.3636 4.837L15.5429 4.58722C15.2594 4.50093 15.2594 4.09952 15.5429 4.01322L16.3636 3.76345C16.4592 3.73433 16.5341 3.65946 16.5632 3.5638L16.813 2.74316Z\"/></svg>";
1342
+
1343
+ var star_16x16 = "<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.5406 15.23C11.2506 15.23 10.9506 15.15 10.6806 15L8.00057 13.49L5.32057 15C4.72057 15.34 3.99057 15.3 3.44057 14.89C2.88057 14.48 2.62057 13.81 2.75057 13.13L3.35057 10.08L1.06057 7.96999C0.560569 7.49999 0.370569 6.79999 0.590569 6.14999C0.800569 5.48999 1.36057 5.03999 2.05057 4.95999L5.12057 4.58999L6.41057 1.77999C6.70057 1.14999 7.31057 0.759995 8.00057 0.759995C8.69057 0.759995 9.30057 1.14999 9.59057 1.77999L10.8806 4.58999L13.9506 4.95999C14.6306 5.03999 15.1906 5.49999 15.4106 6.14999C15.6206 6.80999 15.4406 7.49999 14.9406 7.96999L12.6606 10.09L13.2606 13.14C13.3906 13.82 13.1306 14.49 12.5706 14.9C12.2606 15.12 11.9006 15.23 11.5506 15.23H11.5406ZM7.99057 11.88C8.12057 11.88 8.24057 11.91 8.36057 11.98L11.4106 13.7C11.5306 13.77 11.6306 13.72 11.6806 13.68C11.7306 13.64 11.8006 13.57 11.7806 13.43L11.1006 9.96999C11.0506 9.71999 11.1306 9.44999 11.3206 9.27999L13.9006 6.87999C14.0006 6.78999 13.9806 6.67999 13.9706 6.61999C13.9606 6.55999 13.9006 6.46999 13.7606 6.44999L10.2806 6.02999C10.0206 5.99999 9.80057 5.83999 9.69057 5.59999L8.23057 2.40999C8.17057 2.27999 8.06057 2.25999 8.00057 2.25999C7.94057 2.25999 7.83057 2.27999 7.77057 2.40999L6.31057 5.59999C6.20057 5.83999 5.98057 5.99999 5.72057 6.02999L2.24057 6.44999C2.10057 6.46999 2.05057 6.55999 2.03057 6.61999C2.01057 6.67999 1.99057 6.78999 2.10057 6.87999L4.68057 9.27999C4.87057 9.45999 4.96057 9.71999 4.90057 9.96999L4.22057 13.43C4.19057 13.57 4.27057 13.64 4.32057 13.68C4.37057 13.72 4.47057 13.76 4.59057 13.7L7.64057 11.98C7.75057 11.92 7.88057 11.88 8.01057 11.88H7.99057Z\"/></svg>";
1344
+
1320
1345
  const icons = {
1321
1346
  "modernbooleancheckchecked": modernbooleancheckchecked,
1322
1347
  "modernbooleancheckind": modernbooleancheckind,
@@ -1353,10 +1378,14 @@
1353
1378
  "delete-24x24": delete_24x24,
1354
1379
  "drag-24x24": drag_24x24,
1355
1380
  "draghorizontal-24x16": draghorizontal_24x16,
1381
+ "edit-16x16": edit_16x16,
1382
+ "edit-24x24": edit_24x24,
1356
1383
  "editsmall-16x16": editsmall_16x16,
1357
1384
  "expand-16x16": expand_16x16,
1358
1385
  "expanddetails-16x16": expanddetails_16x16,
1359
1386
  "file-72x72": file_72x72,
1387
+ "filter-16x16": filter_16x16,
1388
+ "filter-24x24": filter_24x24,
1360
1389
  "flip-24x24": flip_24x24,
1361
1390
  "folder-24x24": folder_24x24,
1362
1391
  "fullsize-16x16": fullsize_16x16,
@@ -1370,6 +1399,7 @@
1370
1399
  "navmenu-24x24": navmenu_24x24,
1371
1400
  "noimage-48x48": noimage_48x48,
1372
1401
  "plus-16x16": plus_16x16,
1402
+ "plus-24x24": plus_24x24,
1373
1403
  "radio-16x16": radio_16x16,
1374
1404
  "ranking-arrows": ranking_arrows,
1375
1405
  "rankingdot-16x16": rankingdot_16x16,
@@ -1393,6 +1423,9 @@
1393
1423
  "smiley-rate8-24x24": smiley_rate8_24x24,
1394
1424
  "smiley-rate9-24x24": smiley_rate9_24x24,
1395
1425
  "sort-16x16": sort_16x16,
1426
+ "sparkle-16x16": sparkle_16x16,
1427
+ "sparkle-24x24": sparkle_24x24,
1428
+ "star-16x16": star_16x16,
1396
1429
  };
1397
1430
 
1398
1431
  exports.icons = icons;
@@ -4995,7 +5028,7 @@
4995
5028
  const cssClasses = this.props.cssClasses;
4996
5029
  const matrix = this.props.question;
4997
5030
  const text = this.renderLocString(matrix.locNoRowsText);
4998
- const textDiv = _$1("div", { className: cssClasses.noRowsText }, text);
5031
+ const textDiv = _$1("div", { id: matrix.noRowsTextId, className: cssClasses.noRowsText }, text);
4999
5032
  const toolbar = matrix.getShowPlaceholderToolbar() ? ReactElementFactory.Instance.createElement("sv-action-bar", { model: matrix.toolbar }) : null;
5000
5033
  return (_$1("div", { className: cssClasses.noRowsSection },
5001
5034
  textDiv,
@@ -5133,7 +5166,7 @@
5133
5166
  const cssClasses = this.props.cssClasses;
5134
5167
  const question = this.props.question;
5135
5168
  return (_$1("div", { className: cssClasses.noEntriesPlaceholder },
5136
- _$1("span", null, this.renderLocString(question.locNoEntriesText)),
5169
+ _$1("span", { id: question.noEntriesTextId }, this.renderLocString(question.locNoEntriesText)),
5137
5170
  question.getShowPlaceholderToolbar() ? _$1(SurveyActionBar, { model: question.footerToolbar }) : null));
5138
5171
  }
5139
5172
  }
@@ -5943,6 +5976,368 @@
5943
5976
  return _$1(SurveyQuestionImage, props);
5944
5977
  });
5945
5978
 
5979
+ // The Filter Control (#11890). Everything it shows is survey-core's: the chips, Clear All, Save and
5980
+ // Filters are actions the question owns (filter-toolbars.ts), drawn with sv-action-bar; a badge's
5981
+ // popup is a FilterFieldPopup; the Filters dialog is a FilterModal over a FilterConditionsEditor, and
5982
+ // New Preset and Edit Preset are FilterPresetDialogs; the classes are the theme's "filter"
5983
+ // entry. This file only lays the parts out and draws the few pieces that are not standard components:
5984
+ // a checkbox list entry, the popup's frame, the dialogs' content.
5985
+ // Create custom filter has nothing here: it is a survey, drawn by the "survey" component.
5986
+ // The editor survey is rendered as a page, not as a whole Survey (a Survey inside another survey's
5987
+ // question would put a <form> inside a <form>), so what the Survey component would answer for its
5988
+ // questions is answered here, from the editor survey itself.
5989
+ class FilterEditorCreator {
5990
+ constructor(survey) {
5991
+ this.survey = survey;
5992
+ }
5993
+ createQuestionElement(question) {
5994
+ return ReactQuestionFactory.Instance.createQuestion(question.isDefaultRendering() ? question.getTemplate() : question.getComponentName(), { question: question, isDisplayMode: question.isInputReadOnly, creator: this });
5995
+ }
5996
+ renderError(key, error, cssClasses, element) {
5997
+ return ReactElementFactory.Instance.createElement(this.survey.questionErrorComponent, { key: key, error, cssClasses, element });
5998
+ }
5999
+ questionTitleLocation() {
6000
+ return this.survey.questionTitleLocation;
6001
+ }
6002
+ questionErrorLocation() {
6003
+ return this.survey.questionErrorLocation;
6004
+ }
6005
+ }
6006
+ // The page of an editor survey: the Filters dialog's fields, a "condition" popup's, and a preset
6007
+ // dialog's form and fields.
6008
+ class FilterEditorPage extends SurveyElementBase {
6009
+ constructor() {
6010
+ super(...arguments);
6011
+ this.rootRef = b$1();
6012
+ }
6013
+ getCreator(survey) {
6014
+ if (this.creatorSurvey !== survey) {
6015
+ this.creator = new FilterEditorCreator(survey);
6016
+ this.creatorSurvey = survey;
6017
+ }
6018
+ return this.creator;
6019
+ }
6020
+ componentDidMount() {
6021
+ super.componentDidMount();
6022
+ this.updateRootElement();
6023
+ }
6024
+ componentDidUpdate(prevProps, prevState) {
6025
+ super.componentDidUpdate(prevProps, prevState);
6026
+ this.updateRootElement();
6027
+ }
6028
+ componentWillUnmount() {
6029
+ super.componentWillUnmount();
6030
+ this.clearRootElement();
6031
+ }
6032
+ // The Survey component would set this; a page rendered on its own leaves it to its host. It is
6033
+ // cleared on unmount, unless something else set it in the meantime.
6034
+ updateRootElement() {
6035
+ const editor = this.props.editor;
6036
+ if (!!editor && !editor.isDisposed && !!this.rootRef.current) {
6037
+ if (this.rootSurvey !== editor.survey) {
6038
+ this.clearRootElement();
6039
+ }
6040
+ editor.survey.rootElement = this.rootRef.current;
6041
+ this.rootSurvey = editor.survey;
6042
+ this.rootElement = this.rootRef.current;
6043
+ }
6044
+ }
6045
+ clearRootElement() {
6046
+ const survey = this.rootSurvey;
6047
+ if (!!survey && !survey.isDisposed && survey.rootElement === this.rootElement) {
6048
+ survey.rootElement = undefined;
6049
+ }
6050
+ this.rootSurvey = undefined;
6051
+ this.rootElement = undefined;
6052
+ }
6053
+ renderElement() {
6054
+ const editor = this.props.editor;
6055
+ if (!editor || editor.isDisposed)
6056
+ return null;
6057
+ const survey = editor.survey;
6058
+ // No page while every field is hidden - Search in Filters found none, or a preset's text stands in
6059
+ // their place: a survey has no current page with nothing visible on it.
6060
+ const page = !!survey.currentPage ? _$1(SurveyPage, { survey: survey, page: survey.currentPage, css: survey.css, creator: this.getCreator(survey) }) : null;
6061
+ return _$1("div", { className: this.props.className, ref: this.rootRef }, page);
6062
+ }
6063
+ }
6064
+ // The Filters dialog's content: Search in Filters, the presets with Add New and Edit Selected, the text
6065
+ // of a preset that does not decompose with Edit..., "nothing found" and the fields; its footer is the
6066
+ // dialog's own. It watches the holder, so an emptied holder unmounts the content before survey-core
6067
+ // disposes the dialog's model: a holder never holds a disposed one.
6068
+ class SurveyFilterModal extends SurveyElementBase {
6069
+ get modal() {
6070
+ const holder = this.props.holder;
6071
+ return !!holder ? holder.modal : undefined;
6072
+ }
6073
+ getStateElements() {
6074
+ const holder = this.props.holder;
6075
+ const modal = this.modal;
6076
+ if (!modal)
6077
+ return !!holder ? [holder] : [];
6078
+ return [holder, modal, modal.presetsToolbar, modal.expressionToolbar];
6079
+ }
6080
+ renderSearch(modal) {
6081
+ const css = modal.cssClasses;
6082
+ const searchCss = modal.searchCss;
6083
+ return _$1("div", { className: css.modalSection },
6084
+ _$1("div", { className: searchCss.root },
6085
+ _$1(SvgIcon, { className: css.searchIcon, iconName: "icon-search-24x24", size: "auto" }),
6086
+ _$1("input", { type: "text", className: searchCss.control, value: modal.filterText, placeholder: modal.searchPlaceholder, "aria-label": modal.searchPlaceholder, onChange: (e) => { modal.filterText = e.target.value; } }),
6087
+ modal.showSearchClear ? _$1(SurveyActionBarItem, { item: modal.searchClearAction }) : null));
6088
+ }
6089
+ renderPresets(modal) {
6090
+ if (!modal.presetsToolbar.hasVisibleActions)
6091
+ return null;
6092
+ const css = modal.cssClasses;
6093
+ return _$1("div", { className: css.modalSection, role: "group", "aria-labelledby": modal.presetsTitleId },
6094
+ _$1("div", { className: css.modalSectionHeader },
6095
+ _$1("div", { className: css.modalSectionTitle, id: modal.presetsTitleId }, modal.presetsTitle)),
6096
+ _$1(SurveyActionBar, { model: modal.presetsToolbar }));
6097
+ }
6098
+ renderExpression(modal) {
6099
+ if (!modal.showExpression)
6100
+ return null;
6101
+ const css = modal.cssClasses;
6102
+ return _$1("div", { className: css.modalSection + " " + css.modalExpression },
6103
+ _$1("div", { className: css.modalSectionTitle }, modal.expressionTitle),
6104
+ _$1("div", { className: css.modalExpressionText }, modal.presetExpression),
6105
+ _$1(SurveyActionBar, { model: modal.expressionToolbar }));
6106
+ }
6107
+ renderNothingFound(modal) {
6108
+ if (!modal.isNothingFound)
6109
+ return null;
6110
+ const css = modal.cssClasses;
6111
+ return _$1("div", { className: css.modalNothingFound },
6112
+ _$1(SvgIcon, { className: css.modalNothingFoundIcon, iconName: "icon-search-24x24", size: "auto" }),
6113
+ _$1("div", null, modal.nothingFoundText));
6114
+ }
6115
+ renderElement() {
6116
+ const modal = this.modal;
6117
+ if (!modal)
6118
+ return null;
6119
+ const css = modal.cssClasses;
6120
+ return _$1("div", { className: css.modalContent },
6121
+ this.renderSearch(modal),
6122
+ this.renderPresets(modal),
6123
+ this.renderExpression(modal),
6124
+ this.renderNothingFound(modal),
6125
+ _$1(FilterEditorPage, { editor: modal.editor, className: modal.editorCss }));
6126
+ }
6127
+ }
6128
+ ReactElementFactory.Instance.registerElement(surveyCore.filterModalComponentName, (props) => { return _$1(SurveyFilterModal, props); });
6129
+ // New Preset and Edit Preset: the form - the name and the tagbox of Contains, or the text - and the
6130
+ // dialog's survey - the fields' editors in a frame and the AI description with its Create or Edit; the
6131
+ // footer is the dialog's own. A form made anew (Edit as Expression, an AI answer) is drawn anew, keyed
6132
+ // by its survey's uniqueId: element ids restart in every survey, so a page id would be the same for
6133
+ // each new form. The dialog's survey lives as long as the dialog, and its ids keep counting: it needs
6134
+ // no key.
6135
+ class SurveyFilterPresetDialog extends SurveyElementBase {
6136
+ get dialog() {
6137
+ const holder = this.props.holder;
6138
+ return !!holder ? holder.presetDialog : undefined;
6139
+ }
6140
+ getStateElements() {
6141
+ const holder = this.props.holder;
6142
+ const dialog = this.dialog;
6143
+ if (!dialog)
6144
+ return !!holder ? [holder] : [];
6145
+ return [holder, dialog];
6146
+ }
6147
+ renderElement() {
6148
+ const dialog = this.dialog;
6149
+ if (!dialog)
6150
+ return null;
6151
+ const form = dialog.form;
6152
+ // The page is empty with no field picked and no description (see hasSurveyContent).
6153
+ const hasFields = dialog.hasSurveyContent;
6154
+ return _$1("div", { className: dialog.contentCss },
6155
+ !!form ? _$1(FilterEditorPage, { key: form.uniqueId, editor: { survey: form, isDisposed: dialog.isDisposed }, className: dialog.formCss }) : null,
6156
+ hasFields ? _$1(FilterEditorPage, { editor: { survey: dialog.survey, isDisposed: dialog.isDisposed }, className: dialog.editorCss }) : null);
6157
+ }
6158
+ }
6159
+ ReactElementFactory.Instance.registerElement(surveyCore.filterPresetDialogComponentName, (props) => { return _$1(SurveyFilterPresetDialog, props); });
6160
+ // A badge's popup: the search box (a long list, or one a value can be typed into), a checkbox list's
6161
+ // title row with its link, the list or the operator and value, and Apply.
6162
+ class SurveyFilterFieldPopup extends SurveyElementBase {
6163
+ get popup() {
6164
+ const holder = this.props.holder;
6165
+ return !!holder ? holder.fieldPopup : undefined;
6166
+ }
6167
+ getStateElements() {
6168
+ const holder = this.props.holder;
6169
+ const popup = this.popup;
6170
+ if (!popup)
6171
+ return !!holder ? [holder] : [];
6172
+ const res = [holder, popup.headerToolbar, popup.footerToolbar];
6173
+ if (!!popup.list)
6174
+ res.push(popup.list);
6175
+ return res;
6176
+ }
6177
+ renderSearch(popup) {
6178
+ const list = popup.list;
6179
+ if (!list || !popup.showSearch)
6180
+ return null;
6181
+ const css = popup.cssClasses;
6182
+ return _$1("div", { className: css.popupSearch },
6183
+ _$1(SvgIcon, { className: css.popupSearchIcon, iconName: "icon-search-24x24", size: "auto" }),
6184
+ _$1("input", { type: "text", className: css.popupSearchInput, value: list.filterString || "", placeholder: list.filterStringPlaceholder, "aria-label": list.filterStringPlaceholder, onChange: (e) => { list.filterString = e.target.value; }, onKeyDown: (e) => { popup.onSearchKeyDown(e.nativeEvent); } }));
6185
+ }
6186
+ renderElement() {
6187
+ const popup = this.popup;
6188
+ if (!popup)
6189
+ return null;
6190
+ const css = popup.cssClasses;
6191
+ const body = !!popup.list ? _$1(List, { model: popup.list }) : _$1(FilterEditorPage, { editor: popup.editor, className: css.editor });
6192
+ const footer = popup.footerToolbar.hasActions
6193
+ ? _$1("div", { className: css.popupFooter },
6194
+ _$1(SurveyActionBar, { model: popup.footerToolbar })) : null;
6195
+ const header = popup.showHeader ? _$1("div", { className: css.popupHeader },
6196
+ _$1("div", { className: css.popupTitle }, popup.title),
6197
+ _$1(SurveyActionBar, { model: popup.headerToolbar })) : null;
6198
+ return _$1("div", { className: css.popup },
6199
+ this.renderSearch(popup),
6200
+ header,
6201
+ _$1("div", { className: css.popupBody }, body),
6202
+ footer);
6203
+ }
6204
+ }
6205
+ ReactElementFactory.Instance.registerElement(surveyCore.filterFieldPopupComponentName, (props) => { return _$1(SurveyFilterFieldPopup, props); });
6206
+ // "Save as..."'s popup: the new preset's name and Save.
6207
+ class SurveyFilterSaveAsPopup extends SurveyElementBase {
6208
+ get popup() {
6209
+ const holder = this.props.holder;
6210
+ return !!holder ? holder.saveAsPopup : undefined;
6211
+ }
6212
+ getStateElements() {
6213
+ const holder = this.props.holder;
6214
+ const popup = this.popup;
6215
+ if (!popup)
6216
+ return !!holder ? [holder] : [];
6217
+ return [holder, popup.footerToolbar];
6218
+ }
6219
+ renderElement() {
6220
+ const popup = this.popup;
6221
+ if (!popup)
6222
+ return null;
6223
+ const css = popup.cssClasses;
6224
+ return _$1("div", { className: css.popup },
6225
+ _$1("div", { className: css.popupBody },
6226
+ _$1(FilterEditorPage, { editor: popup, className: css.editor })),
6227
+ _$1("div", { className: css.popupFooter },
6228
+ _$1(SurveyActionBar, { model: popup.footerToolbar })));
6229
+ }
6230
+ }
6231
+ ReactElementFactory.Instance.registerElement(surveyCore.filterSaveAsPopupComponentName, (props) => { return _$1(SurveyFilterSaveAsPopup, props); });
6232
+ // An entry of a checkbox list: drawn checked by the entry's active flag (FilterFieldPopup keeps it).
6233
+ // A value the respondent typed has no remove button: a button inside a list option is nested
6234
+ // interactive content, and unchecking the value is how it goes. The "Add" entry is its text alone.
6235
+ class SurveyFilterListItem extends SurveyElementBase {
6236
+ getStateElement() {
6237
+ return this.props.item;
6238
+ }
6239
+ renderElement() {
6240
+ const item = this.props.item;
6241
+ if (!item || !item.data || !item.data.popup)
6242
+ return null;
6243
+ const popup = item.data.popup;
6244
+ const css = popup.cssClasses;
6245
+ const text = _$1("span", { className: css.listItemText }, item.title);
6246
+ if (item.data.isAdd)
6247
+ return _$1("div", { className: css.listItem }, text);
6248
+ const check = _$1("span", { className: popup.getItemCheckCss(item), "aria-hidden": "true" },
6249
+ _$1("span", { className: css.listItemCheckDecorator },
6250
+ _$1(SvgIcon, { iconName: "icon-check-16x16", size: "auto", css: css.listItemCheckIcon })));
6251
+ return _$1("div", { className: css.listItem },
6252
+ check,
6253
+ text);
6254
+ }
6255
+ }
6256
+ ReactElementFactory.Instance.registerElement(surveyCore.filterListItemComponentName, (props) => { return _$1(SurveyFilterListItem, props); });
6257
+ // A chip (FilterChip): the standard action button (its trailing chevron is the item's markerIconName)
6258
+ // and, while the chip can be cleared, its cross - a button of its own, which the theme draws over the
6259
+ // chip's end. Its popup is drawn by the control, outside the chips row (see
6260
+ // QuestionFilterModel.popupChips); the chip only shows that the popup is open.
6261
+ class SurveyFilterChip extends SurveyActionBarItem {
6262
+ get chip() {
6263
+ return this.item;
6264
+ }
6265
+ componentDidMount() {
6266
+ super.componentDidMount();
6267
+ this.viewModel = new surveyCore.ActionDropdownViewModel(this.item);
6268
+ }
6269
+ componentWillUnmount() {
6270
+ super.componentWillUnmount();
6271
+ this.viewModel.dispose();
6272
+ }
6273
+ renderElement() {
6274
+ const chip = this.chip;
6275
+ const cross = chip.isClearable ? _$1(SurveyActionBarItem, { item: chip.clearAction }) : null;
6276
+ return _$1("div", { className: chip.boxCss },
6277
+ this.renderInnerButton(),
6278
+ cross);
6279
+ }
6280
+ }
6281
+ ReactElementFactory.Instance.registerElement(surveyCore.filterChipComponentName, (props) => { return _$1(SurveyFilterChip, props); });
6282
+ class SurveyQuestionFilter extends SurveyQuestionElementBase {
6283
+ constructor() {
6284
+ super(...arguments);
6285
+ this.chipsRef = b$1();
6286
+ }
6287
+ get question() {
6288
+ return this.questionBase;
6289
+ }
6290
+ getStateElements() {
6291
+ const q = this.question;
6292
+ if (!q)
6293
+ return [];
6294
+ // A disposed question has released its layout, and asking for it would build a new one.
6295
+ return q.isDisposed ? [q] : [q, q.chipsLayout];
6296
+ }
6297
+ // FilterChipsLayout cuts the chips row to one row, and measures the row again itself whenever it
6298
+ // changes: the renderer only attaches it and detaches it.
6299
+ componentDidMount() {
6300
+ super.componentDidMount();
6301
+ const el = this.chipsRef.current;
6302
+ if (!!el && !!this.question && !this.question.isDisposed) {
6303
+ this.question.chipsLayout.attach(el);
6304
+ }
6305
+ }
6306
+ componentWillUnmount() {
6307
+ super.componentWillUnmount();
6308
+ if (!!this.question && !this.question.isDisposed) {
6309
+ this.question.chipsLayout.detach();
6310
+ }
6311
+ }
6312
+ renderSearch() {
6313
+ const q = this.question;
6314
+ if (!q.showSearch)
6315
+ return null;
6316
+ const css = q.cssClasses;
6317
+ const searchCss = q.searchCss;
6318
+ return _$1("div", { className: css.searchRow },
6319
+ _$1("div", { className: q.searchRootCss },
6320
+ _$1(SvgIcon, { className: css.searchIcon, iconName: "icon-search-24x24", size: "auto" }),
6321
+ _$1("input", { type: "text", className: searchCss.control, value: q.searchString, placeholder: q.searchPlaceholder, "aria-label": q.searchLabel, disabled: q.isSearchDisabled, onChange: (e) => { q.searchString = e.target.value; } }),
6322
+ q.showSearchClear ? _$1(SurveyActionBarItem, { item: q.searchClearAction }) : null),
6323
+ _$1(SurveyActionBar, { model: q.searchToolbar }));
6324
+ }
6325
+ // The chips' popups are drawn outside the chips row: on a phone the row scrolls sideways, and iOS
6326
+ // Safari keeps a fixed popup inside such a row.
6327
+ renderElement() {
6328
+ const q = this.question;
6329
+ const css = q.cssClasses;
6330
+ return _$1("div", { className: q.getQuestionRootCss() },
6331
+ this.renderSearch(),
6332
+ _$1("div", { className: css.chipsRow },
6333
+ _$1("div", { className: q.chipsCss, ref: this.chipsRef },
6334
+ _$1(SurveyActionBar, { model: q.chipsToolbar })),
6335
+ _$1(SurveyActionBar, { model: q.clearToolbar })),
6336
+ _$1("div", { className: css.popups }, q.popupChips.map((chip) => _$1(Popup, { key: chip.id, model: chip.popupModel }))));
6337
+ }
6338
+ }
6339
+ ReactQuestionFactory.Instance.registerQuestion("filter", (props) => { return _$1(SurveyQuestionFilter, props); });
6340
+
5946
6341
  class SurveyQuestionSignaturePad extends SurveyQuestionElementBase {
5947
6342
  constructor(props) {
5948
6343
  super(props);
@@ -6543,7 +6938,7 @@
6543
6938
  }
6544
6939
  };
6545
6940
  const preact = React;
6546
- surveyCore.checkLibraryVersion(`${"3.2.5"}`, "survey-js-ui");
6941
+ surveyCore.checkLibraryVersion(`${"3.2.6"}`, "survey-js-ui");
6547
6942
 
6548
6943
  Object.defineProperty(exports, 'Model', {
6549
6944
  enumerable: true,
@@ -6611,6 +7006,12 @@
6611
7006
  exports.SurveyFileChooseButton = SurveyFileChooseButton;
6612
7007
  exports.SurveyFileItem = SurveyFileItem;
6613
7008
  exports.SurveyFilePreview = SurveyFilePreview;
7009
+ exports.SurveyFilterChip = SurveyFilterChip;
7010
+ exports.SurveyFilterFieldPopup = SurveyFilterFieldPopup;
7011
+ exports.SurveyFilterListItem = SurveyFilterListItem;
7012
+ exports.SurveyFilterModal = SurveyFilterModal;
7013
+ exports.SurveyFilterPresetDialog = SurveyFilterPresetDialog;
7014
+ exports.SurveyFilterSaveAsPopup = SurveyFilterSaveAsPopup;
6614
7015
  exports.SurveyFlowPanel = SurveyFlowPanel;
6615
7016
  exports.SurveyHeader = SurveyHeader;
6616
7017
  exports.SurveyLocStringEditor = SurveyLocStringEditor;
@@ -6643,6 +7044,7 @@
6643
7044
  exports.SurveyQuestionEmpty = SurveyQuestionEmpty;
6644
7045
  exports.SurveyQuestionExpression = SurveyQuestionExpression;
6645
7046
  exports.SurveyQuestionFile = SurveyQuestionFile;
7047
+ exports.SurveyQuestionFilter = SurveyQuestionFilter;
6646
7048
  exports.SurveyQuestionHtml = SurveyQuestionHtml;
6647
7049
  exports.SurveyQuestionImage = SurveyQuestionImage;
6648
7050
  exports.SurveyQuestionImageMap = SurveyQuestionImageMap;