Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

survey-analytics

Package Overview
Dependencies
Maintainers
1
Versions
331
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

survey-analytics - npm Package Compare versions

Comparing version 1.7.23 to 1.7.24

2

package.json

@@ -14,3 +14,3 @@ {

},
"version": "1.7.23",
"version": "1.7.24",
"name": "survey-analytics",

@@ -17,0 +17,0 @@ "description": "SurveyJS analytics Library.",

@@ -91,1 +91,5 @@ ![SurveyJS Analytics](https://surveyjstest.azurewebsites.net/Content/Images/design/analytics/Monitor.png)

- Support high load scenario - process at least billion records
## Limitations
- SurveyJS Analytics doesn't support objects as values (e.g. of dropdown, radiogroup and other select question items)

@@ -1,2 +0,2 @@

/*Type definitions for SurveyJS Analytics library v1.7.23
/*Type definitions for SurveyJS Analytics library v1.7.24
Copyright (c) 2015-2019 Devsoft Baltic OÜ - http://surveyjs.io/

@@ -11,2 +11,3 @@ Definitions by: Devsoft Baltic OÜ <https://github.com/surveyjs/>

import { IQuestion } from "survey-core";
import { QuestionMatrixDropdownModel } from "survey-core";
import { SurveyModel } from "survey-core";

@@ -18,2 +19,3 @@ import { ItemValue } from "survey-core";

import "./localization/french";
import "./localization/russian";

@@ -57,2 +59,3 @@ export var localization: {

resetFilter: string;
changeLocale: string;
clearButton: string;

@@ -67,4 +70,18 @@ addElement: string;

export interface IDataInfo {
dataName: string;
getValues(): Array<any>;
getLabels(): Array<string>;
getSeriesValues(): Array<string>;
getSeriesLabels(): Array<string>;
}
export class DataProvider {
static seriesMarkerKey: string;
constructor(_data?: Array<any>);
data: Array<any>;
getData(dataInfo: IDataInfo): number[][];
}
import "./visualizerBase.scss";
export class VisualizerBase {
export class VisualizerBase implements IDataInfo {
question: Question;

@@ -89,2 +106,7 @@ protected data: Array<{

});
readonly dataName: string;
getSeriesValues(): Array<string>;
getSeriesLabels(): Array<string>;
getValues(): Array<any>;
getLabels(): Array<string>;
registerToolbarItem(name: string, creator: (toolbar?: HTMLDivElement) => HTMLElement): void;

@@ -155,2 +177,3 @@ readonly name: string;

}, _elements?: Array<IVisualizerPanelElement>, isTrustedAccess?: boolean);
readonly name: string;
readonly allowDynamicLayout: boolean;

@@ -167,2 +190,3 @@ readonly allowHideQuestions: boolean;

protected readonly hiddenElements: IVisualizerPanelElement[];
protected readonly locales: any;
protected getElement(name: string): IVisualizerPanelElement;

@@ -220,2 +244,3 @@ /**

}>, options?: Object);
readonly name: string;
update(data: Array<{

@@ -233,2 +258,3 @@ [index: string]: any;

}>, options?: Object);
readonly name: string;
getQuestions(): Question[];

@@ -238,9 +264,11 @@ }

export class VisualizationMatrixDropdown extends VisualizerBase {
constructor(question: Question, data: Array<{
protected _panelVisualizer: VisualizationPanel;
constructor(question: QuestionMatrixDropdownModel, data: Array<{
[index: string]: any;
}>, options?: Object);
readonly name: string;
update(data: Array<{
[index: string]: any;
}>): void;
getQuestions(): Question[];
getQuestions(): import("survey-core").Question[];
destroyContent(container: HTMLElement): void;

@@ -463,2 +491,3 @@ renderContent(container: HTMLElement): void;

protected renderContent(container: HTMLElement): void;
getData(): any[];
}

@@ -472,3 +501,3 @@

}
export class GaugePlotly extends Number {
export class GaugePlotly extends NumberModel {
static types: string[];

@@ -482,6 +511,2 @@ constructor(question: Question, data: Array<{

export class PlotlyMatrixChartAdapter extends PlotlyChartAdapter {
constructor(model: MatrixPlotly);
protected patchConfigParameters(chartNode: HTMLDivElement, traces: Array<any>, layout: any, config: any): void;
}
export class MatrixPlotly extends Matrix {

@@ -568,2 +593,3 @@ static types: string[];

chartType: string;
readonly name: string;
protected onChartTypeChanged(): void;

@@ -580,3 +606,3 @@ protected setChartType(chartType: string): void;

protected renderFooter(container: HTMLElement): void;
valuesSource(): any[];
valuesSource(): Array<ItemValue>;
getValues(): Array<any>;

@@ -587,3 +613,3 @@ getLabels(): Array<string>;

export class Number extends VisualizerBase {
export class NumberModel extends VisualizerBase {
static stepsCount: number;

@@ -597,2 +623,3 @@ static generateTextsCallback: (question: Question, maxValue: number, minValue: number, stepsCount: number, texts: string[]) => string[];

}>, options?: Object);
readonly name: string;
update(data: Array<{

@@ -606,5 +633,3 @@ [index: string]: any;

generateColors(maxValue: number, minValue: number, stepsCount: number): any[];
readonly result: any;
readonly resultMax: any;
readonly resultMin: any;
getData(): number[];
}

@@ -616,4 +641,6 @@

}>, options?: Object);
valuesSource(): any[];
getLabels(): any[];
readonly name: string;
getSeriesValues(): Array<string>;
getSeriesLabels(): Array<string>;
valuesSource(): Array<ItemValue>;
getData(): any[];

@@ -628,2 +655,3 @@ }

}>, options?: Object);
readonly name: string;
readonly booleanQuestion: QuestionBooleanModel;

@@ -630,0 +658,0 @@ static trueColor: string;

/*!
* surveyjs - SurveyJS Analytics library v1.7.23
* surveyjs - SurveyJS Analytics library v1.7.24
* Copyright (c) 2015-2019 Devsoft Baltic OÜ - http://surveyjs.io/
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
*/
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("survey-core")):"function"==typeof define&&define.amd?define("SurveyAnalyticsDatatables",["survey-core"],e):"object"==typeof exports?exports.SurveyAnalyticsDatatables=e(require("survey-core")):t.SurveyAnalyticsDatatables=e(t.Survey)}(window,(function(t){return function(t){var e={};function n(a){if(e[a])return e[a].exports;var i=e[a]={i:a,l:!1,exports:{}};return t[a].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,a){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:a})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var a=Object.create(null);if(n.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(a,i,function(e){return t[e]}.bind(null,i));return a},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=22)}([function(t,e,n){"use strict";n.d(e,"a",(function(){return i})),n.d(e,"b",(function(){return o}));var a={groupButton:"Group By Me",ungroupButton:"Ungroup By Me",selectButton:"Select Me",hideColumn:"Hide column",showColumn:"Show column",makePrivateColumn:"Make column private",makePublicColumn:"Make column public",moveToDetail:"Move to Detail",showAsColumn:"Show as Column",visualizer_text:"Texts in table",visualizer_wordcloud:"Wordcloud",chartType_bar:"Bar",chartType_stackedbar:"Stacked Bar",chartType_doughnut:"Doughnut",chartType_pie:"Pie",chartType_scatter:"Scatter",chartType_gauge:"Gauge",chartType_bullet:"Bullet",hideButton:"Hide",showButton:"Show",resetFilter:"Reset Filter",clearButton:"Clear",addElement:"Choose question to show...",defaultOrder:"Default",ascOrder:"Ascending",descOrder:"Descending",showMinorColumns:"Show minor columns",otherCommentTitle:"Other items and comments"},i={currentLocaleValue:"",defaultLocaleValue:"en",locales:{},localeNames:{},supportedLocales:[],get currentLocale(){return this.currentLocaleValue===this.defaultLocaleValue?"":this.currentLocaleValue},set currentLocale(t){this.currentLocaleValue=t},get defaultLocale(){return this.defaultLocaleValue},set defaultLocale(t){this.defaultLocaleValue=t},getString:function(t){var e=this.currentLocale?this.locales[this.currentLocale]:this.locales[this.defaultLocale];e&&e[t]||(e=this.locales[this.defaultLocale]);var n=e[t];return void 0===n&&(n=this.locales.en[t]||t),n},getLocales:function(){var t=[];if(t.push(""),this.supportedLocales&&this.supportedLocales.length>0)for(var e=0;e<this.supportedLocales.length;e++)t.push(this.supportedLocales[e]);else for(var n in this.locales)t.push(n);return t.sort(),t}},o=a;i.locales.en=a,i.localeNames.en="english"},function(t,e,n){"use strict";var a,i,o;n.d(e,"b",(function(){return a})),n.d(e,"c",(function(){return i})),n.d(e,"a",(function(){return o})),function(t){t[t.Visible=0]="Visible",t[t.Invisible=1]="Invisible",t[t.PublicInvisible=2]="PublicInvisible"}(a||(a={})),function(t){t[t.Column=0]="Column",t[t.Row=1]="Row"}(i||(i={})),function(t){t[t.Text=0]="Text",t[t.FileLink=1]="FileLink",t[t.Image=2]="Image"}(o||(o={}))},function(t,e,n){"use strict";n.d(e,"c",(function(){return a})),n.d(e,"b",(function(){return i})),n.d(e,"d",(function(){return r})),n.d(e,"a",(function(){return s}));var a=function(){function t(){}return t.createSelector=function(t,e,n){var a=document.createElement("div");a.className="sa-question__select-wrapper";var i=document.createElement("select");return i.className="sa-question__select",t.forEach((function(t){var n=document.createElement("option");n.value=t.value,n.text=t.text,n.selected=e(t),i.appendChild(n)})),i.onchange=n,a.appendChild(i),a},t.createButton=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var a=document.createElement("span");return a.className="sa-toolbar__button "+n,a.innerText=e,a.onclick=t,a},t}(),i=function(){function t(){}return t.createSvgElement=function(t){var e=document.createElementNS("http://www.w3.org/2000/svg","svg"),n=document.createElementNS("http://www.w3.org/2000/svg","use");return n.setAttributeNS("http://www.w3.org/1999/xlink","href","#sa-svg-"+t),e.appendChild(n),e},t.createSvgButton=function(e){var n=document.createElement("button");return n.className="sa-table__svg-button",n.appendChild(t.createSvgElement(e)),n},t.createBtn=function(t){var e=document.createElement("button");return e.className="sa-table__btn sa-table__btn--small sa-table__btn--gray",e.innerHTML=t,e},t.createInput=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var a=document.createElement("input");return a.className=t,a.placeholder=e,a.defaultValue=n,a},t}(),o={runningInBrowser:"function"==typeof window.URL.createObjectURL};function r(){return o.runningInBrowser}var s=function(){function t(){}return t.zipArrays=function(t,e){for(var n=[],a=0;a<Math.min(t.length,e.length);a++)n[a]=[t[a],e[a]];return n},t.unzipArrays=function(t){var e={first:[],second:[]};return t.forEach((function(t,n){e.first[n]=t[0],e.second[n]=t[1]})),e},t.sortDictionary=function(t,e,n){var a=this.zipArrays(t,e),i=function(t,e,n){void 0===n&&(n=!0);var a=t[1]<e[1]?1:t[1]==e[1]?0:-1;return n?a:-1*a};a.sort((function(t,e){return n?i(t,e,!1):i(t,e)}));var o=this.unzipArrays(a);return{keys:o.first,values:o.second}},t.toPercentage=function(t,e){return t/e*100},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));Object.assign;function a(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function a(){this.constructor=t}t.prototype=null===e?Object.create(e):(a.prototype=e.prototype,new a)}},function(e,n){e.exports=t},function(t,e,n){"use strict";var a=n(0);a.a.locales.fa={groupButton:"گروه بندی با",ungroupButton:"حذف گروه",selectButton:"انتخاب",hideColumn:"مخفی کردن ستون",showColumn:"نمایش ستون",moveToDetail:"انتقال به جزئیات",showAsColumn:"نمایش به عنوان ستون",visualizer_text:"متون در جدول",visualizer_wordcloud:"ابر کلمات",chartType_bar:"میله ای",chartType_pie:"دابره ای(pie)",chartType_scatter:"پراکندگی(Scatter)",chartType_gauge:"عقربه ای",chartType_bullet:"Bullet",hideButton:"مخفی",resetFilter:"بازنشانی فیلترها",clearButton:"پاک کردن",addElement:"انتخاب سوال برای نمایش..."},a.a.localeNames.fa="Farsi(Persian)"},function(t,e,n){"use strict";var a=n(0);a.a.locales.fr={groupButton:"Grouper",ungroupButton:"Dissocier",selectButton:"Sélectionner",hideColumn:"Masquer colonne",showColumn:"Afficher colonne",makePrivateColumn:"Rendre la colonne privé",makePublicColumn:"Rendre la colonne public",moveToDetail:"Déplacer vers détails",showAsColumn:"Afficher en colonne",visualizer_text:"Textes en table",visualizer_wordcloud:"Nuages de mots",chartType_bar:"Barres",chartType_stackedbar:"Barres empilées",chartType_doughnut:"Anneau",chartType_pie:"Secteurs",chartType_scatter:"Nuages de points",chartType_gauge:"Gauge",chartType_bullet:"Bulles",hideButton:"Masquer",resetFilter:"Rafraichir Filtres",clearButton:"Rafraichir",addElement:"Choisir la question à afficher...",defaultOrder:"Defaut",ascOrder:"Ascendant",descOrder:"Descendant",showMinorColumns:"Afficher les colonnes mineures"},a.a.localeNames.fr="French"},function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var a=n(4),i=n(1),o=function(){function t(t,e,n,o,r){var s=this;void 0===o&&(o=[]),void 0===r&&(r=!1),this.survey=t,this.data=e,this.options=n,this._columns=o,this.isTrustedAccess=r,this._rows=[],this.onColumnsVisibilityChanged=new a.Event,this.onColumnsLocationChanged=new a.Event,this.onRowCreated=new a.Event,this.onTableToolsCreated=new a.Event,this.onColumnToolsCreated=new a.Event,this.buildColumns=function(t){return s.survey.getAllQuestions().map((function(t){return{name:t.name,displayName:(t.title||"").trim()||t.name,dataType:"file"!==t.getType()?i.a.Text:i.a.FileLink,visibility:"file"!==t.getType()?i.b.Visible:i.b.Invisible,location:i.c.Column}}))},this.isVisible=function(t){return s.isTrustedAccess&&t!==i.b.Invisible||!s.isTrustedAccess&&t===i.b.Visible},this.getAvailableColumns=function(){return s.columns.filter((function(t){return t.location===i.c.Column&&s.isVisible(t.visibility)}))},0===o.length&&(this._columns=this.buildColumns(t)),this.initTableData(e)}return t.prototype.getData=function(){return this.data},t.prototype.getCreatedRows=function(){return[].concat(this._rows)},Object.defineProperty(t.prototype,"columns",{get:function(){return[].concat(this._columns)},enumerable:!0,configurable:!0}),t.prototype.initTableData=function(t){var e=this;this.tableData=(t||[]).map((function(t){var n={};return e.survey.data=t,e._columns.forEach((function(a){var i=t[a.name],o=e.survey.getQuestionByName(a.name);o&&(i=o.displayValue),n[a.name]="string"==typeof i?i:JSON.stringify(i)||""})),n}))},t.prototype.setColumnLocation=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].location=e,this.onColumnsLocationChanged.fire(this,null)},t.prototype.setColumnVisibility=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].visibility=e,this.onColumnsVisibilityChanged.fire(this,null)},t.prototype.getColumnVisibility=function(t){return this.columns.filter((function(e){return e.name===t}))[0].visibility},t.prototype.doStateSave=function(){this.stateSaveCallback({columns:this.columns},this.data)},t.prototype.stateSaveCallback=function(t,e){},t}()},function(t,e,n){"use strict";n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return u}));var a=n(3),i=n(4),o=n(0),r=n(1),s=n(2),l=function(){function t(t,e,n,a){var o=this;this.table=t,this.toolsContainer=e,this.detailsContainer=n,this.renderDetailActions=a,this.detailedRowClass="sa-table__detail-row",this.isDetailsExpanded=!1,this.onToggleDetails=new i.Event,this.details=new p(t,this,n,a),this.tools=new d(e,t,this),t.onColumnsLocationChanged.add((function(){o.closeDetails()}))}return t.prototype.getIsDetailsExpanded=function(){return!1},t.prototype.render=function(){this.tools.render()},t.prototype.openDetails=function(){this.details.open(),this.getElement().className+=" "+this.detailedRowClass,this.onToggleDetails.fire(this,{isExpanded:!0}),this.isDetailsExpanded=!0},t.prototype.closeDetails=function(){this.details.close(),this.getElement().classList.remove(this.detailedRowClass),this.onToggleDetails.fire(this,{isExpanded:!1}),this.isDetailsExpanded=!1},t.prototype.toggleDetails=function(){this.isDetailsExpanded?this.closeDetails():this.openDetails()},t}(),c=function(t){function e(e,n,a,i,o){var r=t.call(this,e,n,a,o)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=a,r.innerRow=i,r.renderDetailActions=o,r}return Object(a.a)(e,t),e.prototype.getElement=function(){return this.innerRow.getElement()},e.prototype.getData=function(){return this.innerRow.getData()},e}(l),u=function(t){function e(e,n,a,i,o){var r=t.call(this,e,n,a,o)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=a,r._innerRow=i,r.renderDetailActions=o,r.rowElement=i.node(),r.rowData=i.data(),r._innerRow=r._innerRow.row(r.rowElement),r}return Object(a.a)(e,t),Object.defineProperty(e.prototype,"innerRow",{get:function(){return this._innerRow.row(this.rowElement)},enumerable:!0,configurable:!0}),e.prototype.getElement=function(){return this.rowElement},e.prototype.getData=function(){return this.rowData},e}(l),d=function(){function t(t,e,n){this.targetNode=t,this.table=e,this.row=n,this.createDetailsBtn=function(t){var e=s.b.createSvgButton("detail");return e.title=o.a.getString("showMinorColumns"),e.onclick=function(){t.toggleDetails()},e},this.actions=[this.createDetailsBtn]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.row,t.table))}))},t}(),p=function(){function t(t,e,n,a){var i=this;this.table=t,this.row=e,this.targetNode=n,this.renderActions=a,this.createShowAsColumnButton=function(t){var e=document.createElement("button");return e.innerHTML=o.a.getString("showAsColumn"),e.className="sa-table__btn sa-table__btn--gray",e.onclick=function(e){e.stopPropagation(),i.table.setColumnLocation(t,r.c.Column)},e};var s=document.createElement("table");s.className="sa-table__detail-table",this.detailsTable=s,this.table.onColumnsLocationChanged.add((function(){i.close()}))}return t.prototype.setContainer=function(t){this.targetNode=t},t.prototype.open=function(){var t=this;this.detailsTable.innerHTML="";var e=[];if(this.table.columns.filter((function(t){return t.location===r.c.Row&&t})).forEach((function(n){var a=document.createElement("tr");a.className="sa-table__detail";var i=document.createElement("td");i.textContent=n.displayName;var o=document.createElement("td");o.textContent=t.row.getData()[n.name];var r=document.createElement("td");r.appendChild(t.createShowAsColumnButton(n.name)),a.appendChild(i),a.appendChild(o),a.appendChild(r),e.push(a)})),this.renderActions){var n=document.createElement("tr");n.className="sa-table__detail";var a=document.createElement("td");a.colSpan=3,n.appendChild(a),e.push(n),this.renderActions(a,this.row)}e.forEach((function(e){t.detailsTable.appendChild(e)})),this.targetNode.appendChild(this.detailsTable)},t.prototype.close=function(){this.detailsTable.remove()},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var a=n(2),i=n(0),o=n(1),r=function(){function t(t,e,n,a){this.targetNode=t,this.table=e,this.columnName=n,this.isTrustedAccess=a}return t.prototype.render=function(){this.targetNode.appendChild(this.createDragBtn()),this.targetNode.appendChild(this.createSortBtn()),this.targetNode.appendChild(this.createHideBtn()),this.isTrustedAccess&&this.targetNode.appendChild(this.createColumnPrivateButton()),this.targetNode.appendChild(this.createMoveToDetailsBtn()),this.targetNode.appendChild(this.createFilterInput())},t.prototype.createDragBtn=function(){var t=document.createElement("button");return t.className="sa-table__svg-button sa-table__drag-button",t.appendChild(a.b.createSvgElement("drag")),t.onclick=function(t){t.stopPropagation()},t},t.prototype.createSortBtn=function(){var t=this,e=i.a.getString("descOrder"),n=i.a.getString("ascOrder"),o=a.b.createSvgButton("sorting");o.title="";var r="asc";return o.onclick=function(a){"asc"==r?(o.title=e,r="desc"):(o.title=n,r="asc"),t.table.sortByColumn(t.columnName,r)},o.ondrag=function(t){t.stopPropagation()},o},t.prototype.createHideBtn=function(){var t=this,e=a.b.createSvgButton("hide");return e.title=i.a.getString("hideColumn"),e.onclick=function(){t.table.setColumnVisibility(t.columnName,o.b.Invisible)},e},t.prototype.createMoveToDetailsBtn=function(){var t=this,e=a.b.createSvgButton("movetodetails");return e.title=i.a.getString("moveToDetail"),e.onclick=function(e){e.stopPropagation(),t.table.setColumnLocation(t.columnName,o.c.Row)},e},t.prototype.createFilterInput=function(){var t=this,e=a.b.createInput("sa-table__filter","Search...");return e.onclick=function(t){return t.stopPropagation()},e.onchange=function(n){t.table.applyColumnFilter(t.columnName,e.value)},e},t.prototype.createColumnPrivateButton=function(){var t=this,e=document.createElement("button"),n=a.b.createSvgElement("makeprivate"),r=a.b.createSvgElement("makepublic"),s=this.table.getColumnVisibility(this.columnName);function l(t){t===o.b.PublicInvisible?(e.className="sa-table__svg-button sa-table__svg-button--active",e.title=i.a.getString("makePublicColumn"),n.style.display="block",r.style.display="none"):(e.className="sa-table__svg-button",e.title=i.a.getString("makePrivateColumn"),n.style.display="none",r.style.display="block")}return l(s),e.appendChild(n),e.appendChild(r),e.onclick=function(e){e.stopPropagation(),s=s===o.b.PublicInvisible?o.b.Visible:o.b.PublicInvisible,t.table.setColumnVisibility(t.columnName,s),l(s)},e},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var a=n(0),i=n(1),o=n(2),r=function(){function t(t,e){this.targetNode=t,this.table=e,this.createShowColumnDropdown=function(t){var e=document.createElement("select");function n(){var n=t.columns.filter((function(t){return t.visibility===i.b.Invisible}));if(0!=n.length){e.style.display="initial",e.innerHTML="";var o=document.createElement("option");o.text=a.a.getString("showColumn"),o.disabled=!0,o.selected=!0,e.appendChild(o),n.forEach((function(t){var n=document.createElement("option"),a=t.displayName;a.length>20&&(a=a.substring(0,20)+"..."),n.text=a,n.title=t.displayName,n.value=t.name,e.appendChild(n)}))}else e.style.display="none"}return e.classList.add("sa-table__show-column"),e.onchange=function(e){var n=e.target.value;e.stopPropagation(),n&&t.setColumnVisibility(n,i.b.Visible)},n(),t.onColumnsVisibilityChanged.add((function(){n()})),e},this.actions=[this.createFilterInput,this.createShowColumnDropdown,this.createEntriesSelector]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.table))}))},t.prototype.createFilterInput=function(t){var e=o.b.createInput("sa-table__global-filter","Search...");return e.onchange=function(e){t.applyFilter(e.target.value)},e},t.prototype.createEntriesSelector=function(t){var e=document.createElement("div");e.className="sa-table__entries";var n=document.createElement("span");n.innerHTML="Show";var a=document.createElement("span");return a.innerHTML="entries",a.className="sa-table__entries-label sa-table__entries-label--left",e.appendChild(n),n.className="sa-table__entries-label sa-table__entries-label--right",e.appendChild(function(t){var e=document.createElement("select");return["1","5","10","25","50","75","100"].forEach((function(t){var n=document.createElement("option");n.innerHTML=t,e.appendChild(n)})),e.value="5",e.onchange=function(){t.setPageSize(Number(e.value))},e}(t)),e.appendChild(a),e},t}()},function(t,e){t.exports='<svg style="display:none;"><symbol viewBox="0 0 16 16" id="sa-svg-detail"><circle class="st0" cx="1.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="8.5" r="1.5"></circle></symbol><symbol viewBox="0 0 16 16" id="sa-svg-drag"><path class="st0" d="M13 5l-1 1 1 1H9V3l1 1 1-1-3-3-3 3 1 1 1-1v4H3l1-1-1-1-3 3 3 3 1-1-1-1h4v4l-1-1-1 1 3 3 3-3-1-1-1 1V9h4l-1 1 1 1 3-3z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-hide"><path class="st1" d="M12.79 4.2L16 1l-1-1-3.32 3.32C10.57 2.55 9.32 2 8 2 3.63 2 0 7.97 0 7.97s1.27 2.1 3.21 3.82l-3.23 3.23.98.98 3.35-3.34C5.41 13.44 6.67 14 8 14c4.37 0 8-6 8-6s-1.27-2.09-3.21-3.8zM2 7.97c1.07-1.47 3.61-4 6-4 .8 0 1.6.27 2.35.68l-.78.78c-.46-.29-.99-.46-1.57-.46-1.66 0-3 1.34-3 3 0 .58.17 1.11.46 1.57l-.97.97A13.38 13.38 0 0 1 2 7.97zm6 4c-.8 0-1.59-.27-2.33-.67l.78-.77c.45.27.98.44 1.55.44 1.66 0 3-1.34 3-3 0-.57-.17-1.09-.44-1.55l.98-.98c1.11.87 2.01 1.91 2.46 2.52-1.07 1.48-3.61 4.01-6 4.01z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makeprivate"><circle class="st0" cx="8" cy="4" r="3"></circle><path class="st0" d="M8 8c-3.31 0-6 2.73-6 4.67S5.27 15 8 15s6-.4 6-2.33S11.31 8 8 8z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makepublic"><circle class="st0" cx="6" cy="5" r="3"></circle><path class="st0" d="M10 5c0 .34-.06.67-.14.99.05 0 .09.01.14.01 1.66 0 3-1.34 3-3s-1.34-3-3-3C8.97 0 8.07.52 7.53 1.3 8.98 1.91 10 3.33 10 5zM6 9c-3.31 0-6 2.73-6 4.67S3.27 16 6 16s6-.4 6-2.33S9.31 9 6 9zM10 7c-.19 0-.38.01-.57.03a4.14 4.14 0 0 1-1.37 1.39c3 .83 5.23 3.31 5.42 5.28 1.44-.31 2.52-.92 2.52-2.03C16 9.74 13.31 7 10 7z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-movetodetails"><circle class="st0" cx="1.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="14.5" r="1.5"></circle><path class="st0" d="M12 1h3v9h-3zM2.02 7.02L1 6 0 7l3 3 3-3-1-1-.94.94C4.33 4.73 6.21 3 8.5 3c.17 0 .33.03.5.05V1.03C8.83 1.01 8.67 1 8.5 1 5.08 1 2.27 3.66 2.02 7.02z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-sorting"><path class="st0" d="M8 3l2 2 1-1-3-3-3 3 1 1zM8 13l-2-2-1 1 3 3 3-3-1-1z"></path></symbol></svg>'},,,function(t,e,n){},,,,,,,,function(t,e,n){"use strict";n.r(e),n.d(e,"localization",(function(){return a.a})),n.d(e,"surveyStrings",(function(){return a.b})),n.d(e,"DataTables",(function(){return m}));var a=n(0),i=(n(5),n(6),n(3)),o=n(7),r=n(4),s=n(1),l=(n(14),n(8)),c=n(9),u=n(10);if(document){var d=n(11),p=document.createElement("div");p.style.display="none",p.innerHTML=d,document.head.appendChild(p)}var h=window.jQuery,m=function(t){function e(e,n,a,i,o){void 0===i&&(i=[]),void 0===o&&(o=!1);var s=t.call(this,e,n,a,i,o)||this;return s.currentPageNumber=0,s.columnsChanged=new r.Event,s.groupBy=[],s.detailButtonCreators=[],0===i.length&&(s._columns=s.buildColumns(e)),s}return Object(i.a)(e,t),e.initJQuery=function(t){h=t},e.prototype.onColumnsChanged=function(){this.columnsChanged.fire(this,{survey:this.survey})},Object.defineProperty(e.prototype,"columns",{get:function(){return[].concat(this._columns)},set:function(t){this._columns=t,this.update(!0)},enumerable:!0,configurable:!0}),e.prototype.update=function(t){if(void 0===t&&(t=!1),this.isRendered){t&&this.initTableData(this.data),this.currentPageNumber=this.datatableApi.page.info().page;var e=this.renderResult;this.destroy(),this.render(e)}},Object.defineProperty(e.prototype,"isRendered",{get:function(){return!!this.renderResult},enumerable:!0,configurable:!0}),e.prototype.destroy=function(){var t=this.renderResult.children[0];h.fn.DataTable.isDataTable(t)&&h(t).DataTable().destroy(),this.datatableApi=void 0,this.renderResult.innerHTML="",this.renderResult=void 0},e.prototype.setColumnVisibility=function(e,n){t.prototype.setColumnVisibility.call(this,e,n);var a=n==s.b.Invisible;this.datatableApi.column(e+":name").visible(!a)},e.prototype.setColumnLocation=function(e,n){t.prototype.setColumnLocation.call(this,e,n);var a=this.datatableApi.column(e+":name"),i=n==s.c.Column;a.visible(i)},e.prototype.createActionContainer=function(){var t=document.createElement("div");return t.className="sa-table__action-container",t},e.prototype.applyFilter=function(t){this.datatableApi.search(t).draw(!1)},e.prototype.applyColumnFilter=function(t,e){var n=this.datatableApi.column(t+":name");n.search()!==e&&n.search(e).draw(!1)},e.prototype.sortByColumn=function(t,e){this.datatableApi.column(t+":name").order(e).draw(!1)},e.prototype.setPageSize=function(t){this.datatableApi.page.len(t).draw(!1)},e.prototype.render=function(t){var e=this;t.className+=" sa-table sa-datatables",t.innerHTML="";var n=document.createElement("table"),a=this.getColumns(),i=a.map((function(t){return t.data})),o="sa-table__btn sa-table__btn--small sa-table__btn--gray",r=h.extend(!0,{buttons:[{extend:"copy",className:o},{extend:"csv",className:o},{extend:"print",className:o}],dom:'B<"sa-datatables__tools">prtip',data:this.tableData,pageLength:5,responsive:!1,scrollX:!0,columns:a,colReorder:{fixedColumnsLeft:1,realtime:!1},language:{sSearch:" ",searchPlaceholder:"Search...",sLengthMenu:"Show _MENU_ entries",paginate:{previous:" ",next:" "}},select:"api",headerCallback:function(t,a,o,r,s){h(n).dataTable().api();var l=e;h(t).children("th").each((function(t){var e=h(this);if(e.unbind("click.DT"),i[t]&&0===e.has("button").length){var n=l.createActionContainer(),a=new c.a(n,l,i[t],l.isTrustedAccess);l.onColumnToolsCreated.fire(this,{tools:a}),a.render()}e.prepend(n)}))}},this.options);t.appendChild(n),n.width="100%",n.className="sa-datatables__table display responsive dataTable";var s=this.datatableApi=h(n).DataTable(r),d=h("div.sa-datatables__tools")[0],p=new u.a(d,this);this.onTableToolsCreated.fire(this,{tools:p}),p.render(),s.page(this.currentPageNumber),this.datatableApi.rowGroup().enable(!1).draw(!1),s.on("column-reorder",(function(t,n,a){var i=e._columns.splice(a.from-1,1);e._columns.splice(a.to-1,0,i[0]),e.onColumnsChanged()})),s.rows().eq(0).each((function(t){var n=s.row(t),a=document.createElement("tr"),i=document.createElement("td");i.className="sa-datatables__details-container",a.appendChild(i);var o=n.node(),r=n.cell(n.index(),0).node(),c=new l.a(e,r,i,n,e.renderDetailActions);c.onToggleDetails.add((function(t,e){e.isExpanded?(i.colSpan=o.childElementCount,o.parentNode.insertBefore(a,o.nextSibling)):a.remove()})),e.onRowCreated.fire(e,{row:c}),e._rows.push(c),c.render()})),s.draw(!1),this.renderResult=t},e.prototype.doStateSave=function(){this.datatableApi.state.save()},e.prototype.stateSaveCallback=function(t,e){},e.prototype.getColumns=function(){var t=this,e=this.getAvailableColumns().map((function(e,n){var a=t.survey.getQuestionByName(e.name);return{name:e.name,data:e.name,sTitle:a&&a.title||e.displayName,visible:e.visibility!==s.b.Invisible,orderable:!1,mRender:function(t,n,a){var i=a[e.name];return"string"==typeof i?h("<div>").text(i).html():JSON.stringify(i)}}}));return[{orderable:!1,data:null,defaultContent:""}].concat(e)},e.prototype.layout=function(){this.datatableApi&&this.datatableApi.columns.adjust()},e}(o.a)}])}));
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("survey-core")):"function"==typeof define&&define.amd?define("SurveyAnalyticsDatatables",["survey-core"],e):"object"==typeof exports?exports.SurveyAnalyticsDatatables=e(require("survey-core")):t.SurveyAnalyticsDatatables=e(t.Survey)}(window,(function(t){return function(t){var e={};function n(a){if(e[a])return e[a].exports;var i=e[a]={i:a,l:!1,exports:{}};return t[a].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,a){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:a})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var a=Object.create(null);if(n.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(a,i,function(e){return t[e]}.bind(null,i));return a},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=22)}([function(t,e,n){"use strict";n.d(e,"a",(function(){return i})),n.d(e,"b",(function(){return o}));var a={groupButton:"Group By Me",ungroupButton:"Ungroup By Me",selectButton:"Select Me",hideColumn:"Hide column",showColumn:"Show column",makePrivateColumn:"Make column private",makePublicColumn:"Make column public",moveToDetail:"Move to Detail",showAsColumn:"Show as Column",visualizer_text:"Texts in table",visualizer_wordcloud:"Wordcloud",chartType_bar:"Bar",chartType_stackedbar:"Stacked Bar",chartType_doughnut:"Doughnut",chartType_pie:"Pie",chartType_scatter:"Scatter",chartType_gauge:"Gauge",chartType_bullet:"Bullet",hideButton:"Hide",showButton:"Show",resetFilter:"Reset Filter",changeLocale:"Change Locale",clearButton:"Clear",addElement:"Choose question to show...",defaultOrder:"Default",ascOrder:"Ascending",descOrder:"Descending",showMinorColumns:"Show minor columns",otherCommentTitle:"Other items and comments"},i={currentLocaleValue:"",defaultLocaleValue:"en",locales:{},localeNames:{},supportedLocales:[],get currentLocale(){return this.currentLocaleValue===this.defaultLocaleValue?"":this.currentLocaleValue},set currentLocale(t){this.currentLocaleValue=t},get defaultLocale(){return this.defaultLocaleValue},set defaultLocale(t){this.defaultLocaleValue=t},getString:function(t){var e=this.currentLocale?this.locales[this.currentLocale]:this.locales[this.defaultLocale];e&&e[t]||(e=this.locales[this.defaultLocale]);var n=e[t];return void 0===n&&(n=this.locales.en[t]||t),n},getLocales:function(){var t=[];if(t.push(""),this.supportedLocales&&this.supportedLocales.length>0)for(var e=0;e<this.supportedLocales.length;e++)t.push(this.supportedLocales[e]);else for(var n in this.locales)t.push(n);return t.sort(),t}},o=a;i.locales.en=a,i.localeNames.en="english"},function(t,e,n){"use strict";var a,i,o;n.d(e,"b",(function(){return a})),n.d(e,"c",(function(){return i})),n.d(e,"a",(function(){return o})),function(t){t[t.Visible=0]="Visible",t[t.Invisible=1]="Invisible",t[t.PublicInvisible=2]="PublicInvisible"}(a||(a={})),function(t){t[t.Column=0]="Column",t[t.Row=1]="Row"}(i||(i={})),function(t){t[t.Text=0]="Text",t[t.FileLink=1]="FileLink",t[t.Image=2]="Image"}(o||(o={}))},function(t,e,n){"use strict";n.d(e,"c",(function(){return a})),n.d(e,"b",(function(){return i})),n.d(e,"d",(function(){return r})),n.d(e,"a",(function(){return s}));var a=function(){function t(){}return t.createSelector=function(t,e,n){var a=document.createElement("div");a.className="sa-question__select-wrapper";var i=document.createElement("select");return i.className="sa-question__select",t.forEach((function(t){var n=document.createElement("option");n.value=t.value,n.text=t.text,n.selected=e(t),i.appendChild(n)})),i.onchange=n,a.appendChild(i),a},t.createButton=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var a=document.createElement("span");return a.className="sa-toolbar__button "+n,a.innerText=e,a.onclick=t,a},t}(),i=function(){function t(){}return t.createSvgElement=function(t){var e=document.createElementNS("http://www.w3.org/2000/svg","svg"),n=document.createElementNS("http://www.w3.org/2000/svg","use");return n.setAttributeNS("http://www.w3.org/1999/xlink","href","#sa-svg-"+t),e.appendChild(n),e},t.createSvgButton=function(e){var n=document.createElement("button");return n.className="sa-table__svg-button",n.appendChild(t.createSvgElement(e)),n},t.createBtn=function(t){var e=document.createElement("button");return e.className="sa-table__btn sa-table__btn--small sa-table__btn--gray",e.innerHTML=t,e},t.createInput=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var a=document.createElement("input");return a.className=t,a.placeholder=e,a.defaultValue=n,a},t}(),o={runningInBrowser:"function"==typeof window.URL.createObjectURL};function r(){return o.runningInBrowser}var s=function(){function t(){}return t.zipArrays=function(t,e){for(var n=[],a=0;a<Math.min(t.length,e.length);a++)n[a]=[t[a],e[a]];return n},t.unzipArrays=function(t){var e={first:[],second:[]};return t.forEach((function(t,n){e.first[n]=t[0],e.second[n]=t[1]})),e},t.sortDictionary=function(t,e,n){var a=this.zipArrays(t,e),i=function(t,e,n){void 0===n&&(n=!0);var a=t[1]<e[1]?1:t[1]==e[1]?0:-1;return n?a:-1*a};a.sort((function(t,e){return n?i(t,e,!1):i(t,e)}));var o=this.unzipArrays(a);return{keys:o.first,values:o.second}},t.toPercentage=function(t,e){return t/e*100},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));Object.assign;function a(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function a(){this.constructor=t}t.prototype=null===e?Object.create(e):(a.prototype=e.prototype,new a)}},function(e,n){e.exports=t},function(t,e,n){"use strict";var a=n(0);a.a.locales.fa={groupButton:"گروه بندی با",ungroupButton:"حذف گروه",selectButton:"انتخاب",hideColumn:"مخفی کردن ستون",showColumn:"نمایش ستون",moveToDetail:"انتقال به جزئیات",showAsColumn:"نمایش به عنوان ستون",visualizer_text:"متون در جدول",visualizer_wordcloud:"ابر کلمات",chartType_bar:"میله ای",chartType_pie:"دابره ای(pie)",chartType_scatter:"پراکندگی(Scatter)",chartType_gauge:"عقربه ای",chartType_bullet:"Bullet",hideButton:"مخفی",resetFilter:"بازنشانی فیلترها",clearButton:"پاک کردن",addElement:"انتخاب سوال برای نمایش..."},a.a.localeNames.fa="Farsi(Persian)"},function(t,e,n){"use strict";var a=n(0);a.a.locales.fr={groupButton:"Grouper",ungroupButton:"Dissocier",selectButton:"Sélectionner",hideColumn:"Masquer colonne",showColumn:"Afficher colonne",makePrivateColumn:"Rendre la colonne privé",makePublicColumn:"Rendre la colonne public",moveToDetail:"Déplacer vers détails",showAsColumn:"Afficher en colonne",visualizer_text:"Textes en table",visualizer_wordcloud:"Nuages de mots",chartType_bar:"Barres",chartType_stackedbar:"Barres empilées",chartType_doughnut:"Anneau",chartType_pie:"Secteurs",chartType_scatter:"Nuages de points",chartType_gauge:"Gauge",chartType_bullet:"Bulles",hideButton:"Masquer",resetFilter:"Rafraichir Filtres",clearButton:"Rafraichir",addElement:"Choisir la question à afficher...",defaultOrder:"Defaut",ascOrder:"Ascendant",descOrder:"Descendant",showMinorColumns:"Afficher les colonnes mineures"},a.a.localeNames.fr="French"},function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var a=n(4),i=n(1),o=function(){function t(t,e,n,o,r){var s=this;void 0===o&&(o=[]),void 0===r&&(r=!1),this.survey=t,this.data=e,this.options=n,this._columns=o,this.isTrustedAccess=r,this._rows=[],this.onColumnsVisibilityChanged=new a.Event,this.onColumnsLocationChanged=new a.Event,this.onRowCreated=new a.Event,this.onTableToolsCreated=new a.Event,this.onColumnToolsCreated=new a.Event,this.buildColumns=function(t){return s.survey.getAllQuestions().map((function(t){return{name:t.name,displayName:(t.title||"").trim()||t.name,dataType:"file"!==t.getType()?i.a.Text:i.a.FileLink,visibility:"file"!==t.getType()?i.b.Visible:i.b.Invisible,location:i.c.Column}}))},this.isVisible=function(t){return s.isTrustedAccess&&t!==i.b.Invisible||!s.isTrustedAccess&&t===i.b.Visible},this.getAvailableColumns=function(){return s.columns.filter((function(t){return t.location===i.c.Column&&s.isVisible(t.visibility)}))},0===o.length&&(this._columns=this.buildColumns(t)),this.initTableData(e)}return t.prototype.getData=function(){return this.data},t.prototype.getCreatedRows=function(){return[].concat(this._rows)},Object.defineProperty(t.prototype,"columns",{get:function(){return[].concat(this._columns)},enumerable:!0,configurable:!0}),t.prototype.initTableData=function(t){var e=this;this.tableData=(t||[]).map((function(t){var n={};return e.survey.data=t,e._columns.forEach((function(a){var i=t[a.name],o=e.survey.getQuestionByName(a.name);o&&(i=o.displayValue),n[a.name]="string"==typeof i?i:JSON.stringify(i)||""})),n}))},t.prototype.setColumnLocation=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].location=e,this.onColumnsLocationChanged.fire(this,null)},t.prototype.setColumnVisibility=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].visibility=e,this.onColumnsVisibilityChanged.fire(this,null)},t.prototype.getColumnVisibility=function(t){return this.columns.filter((function(e){return e.name===t}))[0].visibility},t.prototype.doStateSave=function(){this.stateSaveCallback({columns:this.columns},this.data)},t.prototype.stateSaveCallback=function(t,e){},t}()},function(t,e,n){"use strict";n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return u}));var a=n(3),i=n(4),o=n(0),r=n(1),s=n(2),l=function(){function t(t,e,n,a){var o=this;this.table=t,this.toolsContainer=e,this.detailsContainer=n,this.renderDetailActions=a,this.detailedRowClass="sa-table__detail-row",this.isDetailsExpanded=!1,this.onToggleDetails=new i.Event,this.details=new p(t,this,n,a),this.tools=new d(e,t,this),t.onColumnsLocationChanged.add((function(){o.closeDetails()}))}return t.prototype.getIsDetailsExpanded=function(){return!1},t.prototype.render=function(){this.tools.render()},t.prototype.openDetails=function(){this.details.open(),this.getElement().className+=" "+this.detailedRowClass,this.onToggleDetails.fire(this,{isExpanded:!0}),this.isDetailsExpanded=!0},t.prototype.closeDetails=function(){this.details.close(),this.getElement().classList.remove(this.detailedRowClass),this.onToggleDetails.fire(this,{isExpanded:!1}),this.isDetailsExpanded=!1},t.prototype.toggleDetails=function(){this.isDetailsExpanded?this.closeDetails():this.openDetails()},t}(),c=function(t){function e(e,n,a,i,o){var r=t.call(this,e,n,a,o)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=a,r.innerRow=i,r.renderDetailActions=o,r}return Object(a.a)(e,t),e.prototype.getElement=function(){return this.innerRow.getElement()},e.prototype.getData=function(){return this.innerRow.getData()},e}(l),u=function(t){function e(e,n,a,i,o){var r=t.call(this,e,n,a,o)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=a,r._innerRow=i,r.renderDetailActions=o,r.rowElement=i.node(),r.rowData=i.data(),r._innerRow=r._innerRow.row(r.rowElement),r}return Object(a.a)(e,t),Object.defineProperty(e.prototype,"innerRow",{get:function(){return this._innerRow.row(this.rowElement)},enumerable:!0,configurable:!0}),e.prototype.getElement=function(){return this.rowElement},e.prototype.getData=function(){return this.rowData},e}(l),d=function(){function t(t,e,n){this.targetNode=t,this.table=e,this.row=n,this.createDetailsBtn=function(t){var e=s.b.createSvgButton("detail");return e.title=o.a.getString("showMinorColumns"),e.onclick=function(){t.toggleDetails()},e},this.actions=[this.createDetailsBtn]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.row,t.table))}))},t}(),p=function(){function t(t,e,n,a){var i=this;this.table=t,this.row=e,this.targetNode=n,this.renderActions=a,this.createShowAsColumnButton=function(t){var e=document.createElement("button");return e.innerHTML=o.a.getString("showAsColumn"),e.className="sa-table__btn sa-table__btn--gray",e.onclick=function(e){e.stopPropagation(),i.table.setColumnLocation(t,r.c.Column)},e};var s=document.createElement("table");s.className="sa-table__detail-table",this.detailsTable=s,this.table.onColumnsLocationChanged.add((function(){i.close()}))}return t.prototype.setContainer=function(t){this.targetNode=t},t.prototype.open=function(){var t=this;this.detailsTable.innerHTML="";var e=[];if(this.table.columns.filter((function(t){return t.location===r.c.Row&&t})).forEach((function(n){var a=document.createElement("tr");a.className="sa-table__detail";var i=document.createElement("td");i.textContent=n.displayName;var o=document.createElement("td");o.textContent=t.row.getData()[n.name];var r=document.createElement("td");r.appendChild(t.createShowAsColumnButton(n.name)),a.appendChild(i),a.appendChild(o),a.appendChild(r),e.push(a)})),this.renderActions){var n=document.createElement("tr");n.className="sa-table__detail";var a=document.createElement("td");a.colSpan=3,n.appendChild(a),e.push(n),this.renderActions(a,this.row)}e.forEach((function(e){t.detailsTable.appendChild(e)})),this.targetNode.appendChild(this.detailsTable)},t.prototype.close=function(){this.detailsTable.remove()},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var a=n(2),i=n(0),o=n(1),r=function(){function t(t,e,n,a){this.targetNode=t,this.table=e,this.columnName=n,this.isTrustedAccess=a}return t.prototype.render=function(){this.targetNode.appendChild(this.createDragBtn()),this.targetNode.appendChild(this.createSortBtn()),this.targetNode.appendChild(this.createHideBtn()),this.isTrustedAccess&&this.targetNode.appendChild(this.createColumnPrivateButton()),this.targetNode.appendChild(this.createMoveToDetailsBtn()),this.targetNode.appendChild(this.createFilterInput())},t.prototype.createDragBtn=function(){var t=document.createElement("button");return t.className="sa-table__svg-button sa-table__drag-button",t.appendChild(a.b.createSvgElement("drag")),t.onclick=function(t){t.stopPropagation()},t},t.prototype.createSortBtn=function(){var t=this,e=i.a.getString("descOrder"),n=i.a.getString("ascOrder"),o=a.b.createSvgButton("sorting");o.title="";var r="asc";return o.onclick=function(a){"asc"==r?(o.title=e,r="desc"):(o.title=n,r="asc"),t.table.sortByColumn(t.columnName,r)},o.ondrag=function(t){t.stopPropagation()},o},t.prototype.createHideBtn=function(){var t=this,e=a.b.createSvgButton("hide");return e.title=i.a.getString("hideColumn"),e.onclick=function(){t.table.setColumnVisibility(t.columnName,o.b.Invisible)},e},t.prototype.createMoveToDetailsBtn=function(){var t=this,e=a.b.createSvgButton("movetodetails");return e.title=i.a.getString("moveToDetail"),e.onclick=function(e){e.stopPropagation(),t.table.setColumnLocation(t.columnName,o.c.Row)},e},t.prototype.createFilterInput=function(){var t=this,e=a.b.createInput("sa-table__filter","Search...");return e.onclick=function(t){return t.stopPropagation()},e.onchange=function(n){t.table.applyColumnFilter(t.columnName,e.value)},e},t.prototype.createColumnPrivateButton=function(){var t=this,e=document.createElement("button"),n=a.b.createSvgElement("makeprivate"),r=a.b.createSvgElement("makepublic"),s=this.table.getColumnVisibility(this.columnName);function l(t){t===o.b.PublicInvisible?(e.className="sa-table__svg-button sa-table__svg-button--active",e.title=i.a.getString("makePublicColumn"),n.style.display="block",r.style.display="none"):(e.className="sa-table__svg-button",e.title=i.a.getString("makePrivateColumn"),n.style.display="none",r.style.display="block")}return l(s),e.appendChild(n),e.appendChild(r),e.onclick=function(e){e.stopPropagation(),s=s===o.b.PublicInvisible?o.b.Visible:o.b.PublicInvisible,t.table.setColumnVisibility(t.columnName,s),l(s)},e},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var a=n(0),i=n(1),o=n(2),r=function(){function t(t,e){this.targetNode=t,this.table=e,this.createShowColumnDropdown=function(t){var e=document.createElement("select");function n(){var n=t.columns.filter((function(t){return t.visibility===i.b.Invisible}));if(0!=n.length){e.style.display="initial",e.innerHTML="";var o=document.createElement("option");o.text=a.a.getString("showColumn"),o.disabled=!0,o.selected=!0,e.appendChild(o),n.forEach((function(t){var n=document.createElement("option"),a=t.displayName;a.length>20&&(a=a.substring(0,20)+"..."),n.text=a,n.title=t.displayName,n.value=t.name,e.appendChild(n)}))}else e.style.display="none"}return e.classList.add("sa-table__show-column"),e.onchange=function(e){var n=e.target.value;e.stopPropagation(),n&&t.setColumnVisibility(n,i.b.Visible)},n(),t.onColumnsVisibilityChanged.add((function(){n()})),e},this.actions=[this.createFilterInput,this.createShowColumnDropdown,this.createEntriesSelector]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.table))}))},t.prototype.createFilterInput=function(t){var e=o.b.createInput("sa-table__global-filter","Search...");return e.onchange=function(e){t.applyFilter(e.target.value)},e},t.prototype.createEntriesSelector=function(t){var e=document.createElement("div");e.className="sa-table__entries";var n=document.createElement("span");n.innerHTML="Show";var a=document.createElement("span");return a.innerHTML="entries",a.className="sa-table__entries-label sa-table__entries-label--left",e.appendChild(n),n.className="sa-table__entries-label sa-table__entries-label--right",e.appendChild(function(t){var e=document.createElement("select");return["1","5","10","25","50","75","100"].forEach((function(t){var n=document.createElement("option");n.innerHTML=t,e.appendChild(n)})),e.value="5",e.onchange=function(){t.setPageSize(Number(e.value))},e}(t)),e.appendChild(a),e},t}()},function(t,e){t.exports='<svg style="display:none;"><symbol viewBox="0 0 16 16" id="sa-svg-detail"><circle class="st0" cx="1.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="8.5" r="1.5"></circle></symbol><symbol viewBox="0 0 16 16" id="sa-svg-drag"><path class="st0" d="M13 5l-1 1 1 1H9V3l1 1 1-1-3-3-3 3 1 1 1-1v4H3l1-1-1-1-3 3 3 3 1-1-1-1h4v4l-1-1-1 1 3 3 3-3-1-1-1 1V9h4l-1 1 1 1 3-3z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-hide"><path class="st1" d="M12.79 4.2L16 1l-1-1-3.32 3.32C10.57 2.55 9.32 2 8 2 3.63 2 0 7.97 0 7.97s1.27 2.1 3.21 3.82l-3.23 3.23.98.98 3.35-3.34C5.41 13.44 6.67 14 8 14c4.37 0 8-6 8-6s-1.27-2.09-3.21-3.8zM2 7.97c1.07-1.47 3.61-4 6-4 .8 0 1.6.27 2.35.68l-.78.78c-.46-.29-.99-.46-1.57-.46-1.66 0-3 1.34-3 3 0 .58.17 1.11.46 1.57l-.97.97A13.38 13.38 0 0 1 2 7.97zm6 4c-.8 0-1.59-.27-2.33-.67l.78-.77c.45.27.98.44 1.55.44 1.66 0 3-1.34 3-3 0-.57-.17-1.09-.44-1.55l.98-.98c1.11.87 2.01 1.91 2.46 2.52-1.07 1.48-3.61 4.01-6 4.01z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makeprivate"><circle class="st0" cx="8" cy="4" r="3"></circle><path class="st0" d="M8 8c-3.31 0-6 2.73-6 4.67S5.27 15 8 15s6-.4 6-2.33S11.31 8 8 8z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makepublic"><circle class="st0" cx="6" cy="5" r="3"></circle><path class="st0" d="M10 5c0 .34-.06.67-.14.99.05 0 .09.01.14.01 1.66 0 3-1.34 3-3s-1.34-3-3-3C8.97 0 8.07.52 7.53 1.3 8.98 1.91 10 3.33 10 5zM6 9c-3.31 0-6 2.73-6 4.67S3.27 16 6 16s6-.4 6-2.33S9.31 9 6 9zM10 7c-.19 0-.38.01-.57.03a4.14 4.14 0 0 1-1.37 1.39c3 .83 5.23 3.31 5.42 5.28 1.44-.31 2.52-.92 2.52-2.03C16 9.74 13.31 7 10 7z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-movetodetails"><circle class="st0" cx="1.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="14.5" r="1.5"></circle><path class="st0" d="M12 1h3v9h-3zM2.02 7.02L1 6 0 7l3 3 3-3-1-1-.94.94C4.33 4.73 6.21 3 8.5 3c.17 0 .33.03.5.05V1.03C8.83 1.01 8.67 1 8.5 1 5.08 1 2.27 3.66 2.02 7.02z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-sorting"><path class="st0" d="M8 3l2 2 1-1-3-3-3 3 1 1zM8 13l-2-2-1 1 3 3 3-3-1-1z"></path></symbol></svg>'},,,function(t,e,n){},,,,,,,,function(t,e,n){"use strict";n.r(e),n.d(e,"localization",(function(){return a.a})),n.d(e,"surveyStrings",(function(){return a.b})),n.d(e,"DataTables",(function(){return m}));var a=n(0),i=(n(5),n(6),n(3)),o=n(7),r=n(4),s=n(1),l=(n(14),n(8)),c=n(9),u=n(10);if(document){var d=n(11),p=document.createElement("div");p.style.display="none",p.innerHTML=d,document.head.appendChild(p)}var h=window.jQuery,m=function(t){function e(e,n,a,i,o){void 0===i&&(i=[]),void 0===o&&(o=!1);var s=t.call(this,e,n,a,i,o)||this;return s.currentPageNumber=0,s.columnsChanged=new r.Event,s.groupBy=[],s.detailButtonCreators=[],0===i.length&&(s._columns=s.buildColumns(e)),s}return Object(i.a)(e,t),e.initJQuery=function(t){h=t},e.prototype.onColumnsChanged=function(){this.columnsChanged.fire(this,{survey:this.survey})},Object.defineProperty(e.prototype,"columns",{get:function(){return[].concat(this._columns)},set:function(t){this._columns=t,this.update(!0)},enumerable:!0,configurable:!0}),e.prototype.update=function(t){if(void 0===t&&(t=!1),this.isRendered){t&&this.initTableData(this.data),this.currentPageNumber=this.datatableApi.page.info().page;var e=this.renderResult;this.destroy(),this.render(e)}},Object.defineProperty(e.prototype,"isRendered",{get:function(){return!!this.renderResult},enumerable:!0,configurable:!0}),e.prototype.destroy=function(){var t=this.renderResult.children[0];h.fn.DataTable.isDataTable(t)&&h(t).DataTable().destroy(),this.datatableApi=void 0,this.renderResult.innerHTML="",this.renderResult=void 0},e.prototype.setColumnVisibility=function(e,n){t.prototype.setColumnVisibility.call(this,e,n);var a=n==s.b.Invisible;this.datatableApi.column(e+":name").visible(!a)},e.prototype.setColumnLocation=function(e,n){t.prototype.setColumnLocation.call(this,e,n);var a=this.datatableApi.column(e+":name"),i=n==s.c.Column;a.visible(i)},e.prototype.createActionContainer=function(){var t=document.createElement("div");return t.className="sa-table__action-container",t},e.prototype.applyFilter=function(t){this.datatableApi.search(t).draw(!1)},e.prototype.applyColumnFilter=function(t,e){var n=this.datatableApi.column(t+":name");n.search()!==e&&n.search(e).draw(!1)},e.prototype.sortByColumn=function(t,e){this.datatableApi.column(t+":name").order(e).draw(!1)},e.prototype.setPageSize=function(t){this.datatableApi.page.len(t).draw(!1)},e.prototype.render=function(t){var e=this;t.className+=" sa-table sa-datatables",t.innerHTML="";var n=document.createElement("table"),a=this.getColumns(),i=a.map((function(t){return t.data})),o="sa-table__btn sa-table__btn--small sa-table__btn--gray",r=h.extend(!0,{buttons:[{extend:"copy",className:o},{extend:"csv",className:o},{extend:"print",className:o}],dom:'B<"sa-datatables__tools">prtip',data:this.tableData,pageLength:5,responsive:!1,scrollX:!0,columns:a,colReorder:{fixedColumnsLeft:1,realtime:!1},language:{sSearch:" ",searchPlaceholder:"Search...",sLengthMenu:"Show _MENU_ entries",paginate:{previous:" ",next:" "}},select:"api",headerCallback:function(t,a,o,r,s){h(n).dataTable().api();var l=e;h(t).children("th").each((function(t){var e=h(this);if(e.unbind("click.DT"),i[t]&&0===e.has("button").length){var n=l.createActionContainer(),a=new c.a(n,l,i[t],l.isTrustedAccess);l.onColumnToolsCreated.fire(this,{tools:a}),a.render()}e.prepend(n)}))}},this.options);t.appendChild(n),n.width="100%",n.className="sa-datatables__table display responsive dataTable";var s=this.datatableApi=h(n).DataTable(r),d=h("div.sa-datatables__tools")[0],p=new u.a(d,this);this.onTableToolsCreated.fire(this,{tools:p}),p.render(),s.page(this.currentPageNumber),this.datatableApi.rowGroup().enable(!1).draw(!1),s.on("column-reorder",(function(t,n,a){var i=e._columns.splice(a.from-1,1);e._columns.splice(a.to-1,0,i[0]),e.onColumnsChanged()})),s.rows().eq(0).each((function(t){var n=s.row(t),a=document.createElement("tr"),i=document.createElement("td");i.className="sa-datatables__details-container",a.appendChild(i);var o=n.node(),r=n.cell(n.index(),0).node(),c=new l.a(e,r,i,n,e.renderDetailActions);c.onToggleDetails.add((function(t,e){e.isExpanded?(i.colSpan=o.childElementCount,o.parentNode.insertBefore(a,o.nextSibling)):a.remove()})),e.onRowCreated.fire(e,{row:c}),e._rows.push(c),c.render()})),s.draw(!1),this.renderResult=t},e.prototype.doStateSave=function(){this.datatableApi.state.save()},e.prototype.stateSaveCallback=function(t,e){},e.prototype.getColumns=function(){var t=this,e=this.getAvailableColumns().map((function(e,n){var a=t.survey.getQuestionByName(e.name);return{name:e.name,data:e.name,sTitle:a&&a.title||e.displayName,visible:e.visibility!==s.b.Invisible,orderable:!1,mRender:function(t,n,a){var i=a[e.name];return"string"==typeof i?h("<div>").text(i).html():JSON.stringify(i)}}}));return[{orderable:!1,data:null,defaultContent:""}].concat(e)},e.prototype.layout=function(){this.datatableApi&&this.datatableApi.columns.adjust()},e}(o.a)}])}));
/*!
* surveyjs - SurveyJS Analytics library v1.7.23
* surveyjs - SurveyJS Analytics library v1.7.24
* Copyright (c) 2015-2019 Devsoft Baltic OÜ - http://surveyjs.io/
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
*/
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("survey-core"),require("tabulator-tables")):"function"==typeof define&&define.amd?define("SurveyAnalyticsTabulator",["survey-core","tabulator-tables"],e):"object"==typeof exports?exports.SurveyAnalyticsTabulator=e(require("survey-core"),require("tabulator-tables")):t.SurveyAnalyticsTabulator=e(t.Survey,t.Tabulator)}(window,(function(t,e){return function(t){var e={};function n(o){if(e[o])return e[o].exports;var a=e[o]={i:o,l:!1,exports:{}};return t[o].call(a.exports,a,a.exports,n),a.l=!0,a.exports}return n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var a in t)n.d(o,a,function(e){return t[e]}.bind(null,a));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=23)}([function(t,e,n){"use strict";n.d(e,"a",(function(){return a})),n.d(e,"b",(function(){return i}));var o={groupButton:"Group By Me",ungroupButton:"Ungroup By Me",selectButton:"Select Me",hideColumn:"Hide column",showColumn:"Show column",makePrivateColumn:"Make column private",makePublicColumn:"Make column public",moveToDetail:"Move to Detail",showAsColumn:"Show as Column",visualizer_text:"Texts in table",visualizer_wordcloud:"Wordcloud",chartType_bar:"Bar",chartType_stackedbar:"Stacked Bar",chartType_doughnut:"Doughnut",chartType_pie:"Pie",chartType_scatter:"Scatter",chartType_gauge:"Gauge",chartType_bullet:"Bullet",hideButton:"Hide",showButton:"Show",resetFilter:"Reset Filter",clearButton:"Clear",addElement:"Choose question to show...",defaultOrder:"Default",ascOrder:"Ascending",descOrder:"Descending",showMinorColumns:"Show minor columns",otherCommentTitle:"Other items and comments"},a={currentLocaleValue:"",defaultLocaleValue:"en",locales:{},localeNames:{},supportedLocales:[],get currentLocale(){return this.currentLocaleValue===this.defaultLocaleValue?"":this.currentLocaleValue},set currentLocale(t){this.currentLocaleValue=t},get defaultLocale(){return this.defaultLocaleValue},set defaultLocale(t){this.defaultLocaleValue=t},getString:function(t){var e=this.currentLocale?this.locales[this.currentLocale]:this.locales[this.defaultLocale];e&&e[t]||(e=this.locales[this.defaultLocale]);var n=e[t];return void 0===n&&(n=this.locales.en[t]||t),n},getLocales:function(){var t=[];if(t.push(""),this.supportedLocales&&this.supportedLocales.length>0)for(var e=0;e<this.supportedLocales.length;e++)t.push(this.supportedLocales[e]);else for(var n in this.locales)t.push(n);return t.sort(),t}},i=o;a.locales.en=o,a.localeNames.en="english"},function(t,e,n){"use strict";var o,a,i;n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return i})),function(t){t[t.Visible=0]="Visible",t[t.Invisible=1]="Invisible",t[t.PublicInvisible=2]="PublicInvisible"}(o||(o={})),function(t){t[t.Column=0]="Column",t[t.Row=1]="Row"}(a||(a={})),function(t){t[t.Text=0]="Text",t[t.FileLink=1]="FileLink",t[t.Image=2]="Image"}(i||(i={}))},function(t,e,n){"use strict";n.d(e,"c",(function(){return o})),n.d(e,"b",(function(){return a})),n.d(e,"d",(function(){return r})),n.d(e,"a",(function(){return l}));var o=function(){function t(){}return t.createSelector=function(t,e,n){var o=document.createElement("div");o.className="sa-question__select-wrapper";var a=document.createElement("select");return a.className="sa-question__select",t.forEach((function(t){var n=document.createElement("option");n.value=t.value,n.text=t.text,n.selected=e(t),a.appendChild(n)})),a.onchange=n,o.appendChild(a),o},t.createButton=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var o=document.createElement("span");return o.className="sa-toolbar__button "+n,o.innerText=e,o.onclick=t,o},t}(),a=function(){function t(){}return t.createSvgElement=function(t){var e=document.createElementNS("http://www.w3.org/2000/svg","svg"),n=document.createElementNS("http://www.w3.org/2000/svg","use");return n.setAttributeNS("http://www.w3.org/1999/xlink","href","#sa-svg-"+t),e.appendChild(n),e},t.createSvgButton=function(e){var n=document.createElement("button");return n.className="sa-table__svg-button",n.appendChild(t.createSvgElement(e)),n},t.createBtn=function(t){var e=document.createElement("button");return e.className="sa-table__btn sa-table__btn--small sa-table__btn--gray",e.innerHTML=t,e},t.createInput=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var o=document.createElement("input");return o.className=t,o.placeholder=e,o.defaultValue=n,o},t}(),i={runningInBrowser:"function"==typeof window.URL.createObjectURL};function r(){return i.runningInBrowser}var l=function(){function t(){}return t.zipArrays=function(t,e){for(var n=[],o=0;o<Math.min(t.length,e.length);o++)n[o]=[t[o],e[o]];return n},t.unzipArrays=function(t){var e={first:[],second:[]};return t.forEach((function(t,n){e.first[n]=t[0],e.second[n]=t[1]})),e},t.sortDictionary=function(t,e,n){var o=this.zipArrays(t,e),a=function(t,e,n){void 0===n&&(n=!0);var o=t[1]<e[1]?1:t[1]==e[1]?0:-1;return n?o:-1*o};o.sort((function(t,e){return n?a(t,e,!1):a(t,e)}));var i=this.unzipArrays(o);return{keys:i.first,values:i.second}},t.toPercentage=function(t,e){return t/e*100},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));Object.assign;function o(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function o(){this.constructor=t}t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}},function(e,n){e.exports=t},function(t,e,n){"use strict";var o=n(0);o.a.locales.fa={groupButton:"گروه بندی با",ungroupButton:"حذف گروه",selectButton:"انتخاب",hideColumn:"مخفی کردن ستون",showColumn:"نمایش ستون",moveToDetail:"انتقال به جزئیات",showAsColumn:"نمایش به عنوان ستون",visualizer_text:"متون در جدول",visualizer_wordcloud:"ابر کلمات",chartType_bar:"میله ای",chartType_pie:"دابره ای(pie)",chartType_scatter:"پراکندگی(Scatter)",chartType_gauge:"عقربه ای",chartType_bullet:"Bullet",hideButton:"مخفی",resetFilter:"بازنشانی فیلترها",clearButton:"پاک کردن",addElement:"انتخاب سوال برای نمایش..."},o.a.localeNames.fa="Farsi(Persian)"},function(t,e,n){"use strict";var o=n(0);o.a.locales.fr={groupButton:"Grouper",ungroupButton:"Dissocier",selectButton:"Sélectionner",hideColumn:"Masquer colonne",showColumn:"Afficher colonne",makePrivateColumn:"Rendre la colonne privé",makePublicColumn:"Rendre la colonne public",moveToDetail:"Déplacer vers détails",showAsColumn:"Afficher en colonne",visualizer_text:"Textes en table",visualizer_wordcloud:"Nuages de mots",chartType_bar:"Barres",chartType_stackedbar:"Barres empilées",chartType_doughnut:"Anneau",chartType_pie:"Secteurs",chartType_scatter:"Nuages de points",chartType_gauge:"Gauge",chartType_bullet:"Bulles",hideButton:"Masquer",resetFilter:"Rafraichir Filtres",clearButton:"Rafraichir",addElement:"Choisir la question à afficher...",defaultOrder:"Defaut",ascOrder:"Ascendant",descOrder:"Descendant",showMinorColumns:"Afficher les colonnes mineures"},o.a.localeNames.fr="French"},function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var o=n(4),a=n(1),i=function(){function t(t,e,n,i,r){var l=this;void 0===i&&(i=[]),void 0===r&&(r=!1),this.survey=t,this.data=e,this.options=n,this._columns=i,this.isTrustedAccess=r,this._rows=[],this.onColumnsVisibilityChanged=new o.Event,this.onColumnsLocationChanged=new o.Event,this.onRowCreated=new o.Event,this.onTableToolsCreated=new o.Event,this.onColumnToolsCreated=new o.Event,this.buildColumns=function(t){return l.survey.getAllQuestions().map((function(t){return{name:t.name,displayName:(t.title||"").trim()||t.name,dataType:"file"!==t.getType()?a.a.Text:a.a.FileLink,visibility:"file"!==t.getType()?a.b.Visible:a.b.Invisible,location:a.c.Column}}))},this.isVisible=function(t){return l.isTrustedAccess&&t!==a.b.Invisible||!l.isTrustedAccess&&t===a.b.Visible},this.getAvailableColumns=function(){return l.columns.filter((function(t){return t.location===a.c.Column&&l.isVisible(t.visibility)}))},0===i.length&&(this._columns=this.buildColumns(t)),this.initTableData(e)}return t.prototype.getData=function(){return this.data},t.prototype.getCreatedRows=function(){return[].concat(this._rows)},Object.defineProperty(t.prototype,"columns",{get:function(){return[].concat(this._columns)},enumerable:!0,configurable:!0}),t.prototype.initTableData=function(t){var e=this;this.tableData=(t||[]).map((function(t){var n={};return e.survey.data=t,e._columns.forEach((function(o){var a=t[o.name],i=e.survey.getQuestionByName(o.name);i&&(a=i.displayValue),n[o.name]="string"==typeof a?a:JSON.stringify(a)||""})),n}))},t.prototype.setColumnLocation=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].location=e,this.onColumnsLocationChanged.fire(this,null)},t.prototype.setColumnVisibility=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].visibility=e,this.onColumnsVisibilityChanged.fire(this,null)},t.prototype.getColumnVisibility=function(t){return this.columns.filter((function(e){return e.name===t}))[0].visibility},t.prototype.doStateSave=function(){this.stateSaveCallback({columns:this.columns},this.data)},t.prototype.stateSaveCallback=function(t,e){},t}()},function(t,e,n){"use strict";n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return u}));var o=n(3),a=n(4),i=n(0),r=n(1),l=n(2),s=function(){function t(t,e,n,o){var i=this;this.table=t,this.toolsContainer=e,this.detailsContainer=n,this.renderDetailActions=o,this.detailedRowClass="sa-table__detail-row",this.isDetailsExpanded=!1,this.onToggleDetails=new a.Event,this.details=new p(t,this,n,o),this.tools=new d(e,t,this),t.onColumnsLocationChanged.add((function(){i.closeDetails()}))}return t.prototype.getIsDetailsExpanded=function(){return!1},t.prototype.render=function(){this.tools.render()},t.prototype.openDetails=function(){this.details.open(),this.getElement().className+=" "+this.detailedRowClass,this.onToggleDetails.fire(this,{isExpanded:!0}),this.isDetailsExpanded=!0},t.prototype.closeDetails=function(){this.details.close(),this.getElement().classList.remove(this.detailedRowClass),this.onToggleDetails.fire(this,{isExpanded:!1}),this.isDetailsExpanded=!1},t.prototype.toggleDetails=function(){this.isDetailsExpanded?this.closeDetails():this.openDetails()},t}(),c=function(t){function e(e,n,o,a,i){var r=t.call(this,e,n,o,i)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=o,r.innerRow=a,r.renderDetailActions=i,r}return Object(o.a)(e,t),e.prototype.getElement=function(){return this.innerRow.getElement()},e.prototype.getData=function(){return this.innerRow.getData()},e}(s),u=function(t){function e(e,n,o,a,i){var r=t.call(this,e,n,o,i)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=o,r._innerRow=a,r.renderDetailActions=i,r.rowElement=a.node(),r.rowData=a.data(),r._innerRow=r._innerRow.row(r.rowElement),r}return Object(o.a)(e,t),Object.defineProperty(e.prototype,"innerRow",{get:function(){return this._innerRow.row(this.rowElement)},enumerable:!0,configurable:!0}),e.prototype.getElement=function(){return this.rowElement},e.prototype.getData=function(){return this.rowData},e}(s),d=function(){function t(t,e,n){this.targetNode=t,this.table=e,this.row=n,this.createDetailsBtn=function(t){var e=l.b.createSvgButton("detail");return e.title=i.a.getString("showMinorColumns"),e.onclick=function(){t.toggleDetails()},e},this.actions=[this.createDetailsBtn]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.row,t.table))}))},t}(),p=function(){function t(t,e,n,o){var a=this;this.table=t,this.row=e,this.targetNode=n,this.renderActions=o,this.createShowAsColumnButton=function(t){var e=document.createElement("button");return e.innerHTML=i.a.getString("showAsColumn"),e.className="sa-table__btn sa-table__btn--gray",e.onclick=function(e){e.stopPropagation(),a.table.setColumnLocation(t,r.c.Column)},e};var l=document.createElement("table");l.className="sa-table__detail-table",this.detailsTable=l,this.table.onColumnsLocationChanged.add((function(){a.close()}))}return t.prototype.setContainer=function(t){this.targetNode=t},t.prototype.open=function(){var t=this;this.detailsTable.innerHTML="";var e=[];if(this.table.columns.filter((function(t){return t.location===r.c.Row&&t})).forEach((function(n){var o=document.createElement("tr");o.className="sa-table__detail";var a=document.createElement("td");a.textContent=n.displayName;var i=document.createElement("td");i.textContent=t.row.getData()[n.name];var r=document.createElement("td");r.appendChild(t.createShowAsColumnButton(n.name)),o.appendChild(a),o.appendChild(i),o.appendChild(r),e.push(o)})),this.renderActions){var n=document.createElement("tr");n.className="sa-table__detail";var o=document.createElement("td");o.colSpan=3,n.appendChild(o),e.push(n),this.renderActions(o,this.row)}e.forEach((function(e){t.detailsTable.appendChild(e)})),this.targetNode.appendChild(this.detailsTable)},t.prototype.close=function(){this.detailsTable.remove()},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var o=n(2),a=n(0),i=n(1),r=function(){function t(t,e,n,o){this.targetNode=t,this.table=e,this.columnName=n,this.isTrustedAccess=o}return t.prototype.render=function(){this.targetNode.appendChild(this.createDragBtn()),this.targetNode.appendChild(this.createSortBtn()),this.targetNode.appendChild(this.createHideBtn()),this.isTrustedAccess&&this.targetNode.appendChild(this.createColumnPrivateButton()),this.targetNode.appendChild(this.createMoveToDetailsBtn()),this.targetNode.appendChild(this.createFilterInput())},t.prototype.createDragBtn=function(){var t=document.createElement("button");return t.className="sa-table__svg-button sa-table__drag-button",t.appendChild(o.b.createSvgElement("drag")),t.onclick=function(t){t.stopPropagation()},t},t.prototype.createSortBtn=function(){var t=this,e=a.a.getString("descOrder"),n=a.a.getString("ascOrder"),i=o.b.createSvgButton("sorting");i.title="";var r="asc";return i.onclick=function(o){"asc"==r?(i.title=e,r="desc"):(i.title=n,r="asc"),t.table.sortByColumn(t.columnName,r)},i.ondrag=function(t){t.stopPropagation()},i},t.prototype.createHideBtn=function(){var t=this,e=o.b.createSvgButton("hide");return e.title=a.a.getString("hideColumn"),e.onclick=function(){t.table.setColumnVisibility(t.columnName,i.b.Invisible)},e},t.prototype.createMoveToDetailsBtn=function(){var t=this,e=o.b.createSvgButton("movetodetails");return e.title=a.a.getString("moveToDetail"),e.onclick=function(e){e.stopPropagation(),t.table.setColumnLocation(t.columnName,i.c.Row)},e},t.prototype.createFilterInput=function(){var t=this,e=o.b.createInput("sa-table__filter","Search...");return e.onclick=function(t){return t.stopPropagation()},e.onchange=function(n){t.table.applyColumnFilter(t.columnName,e.value)},e},t.prototype.createColumnPrivateButton=function(){var t=this,e=document.createElement("button"),n=o.b.createSvgElement("makeprivate"),r=o.b.createSvgElement("makepublic"),l=this.table.getColumnVisibility(this.columnName);function s(t){t===i.b.PublicInvisible?(e.className="sa-table__svg-button sa-table__svg-button--active",e.title=a.a.getString("makePublicColumn"),n.style.display="block",r.style.display="none"):(e.className="sa-table__svg-button",e.title=a.a.getString("makePrivateColumn"),n.style.display="none",r.style.display="block")}return s(l),e.appendChild(n),e.appendChild(r),e.onclick=function(e){e.stopPropagation(),l=l===i.b.PublicInvisible?i.b.Visible:i.b.PublicInvisible,t.table.setColumnVisibility(t.columnName,l),s(l)},e},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var o=n(0),a=n(1),i=n(2),r=function(){function t(t,e){this.targetNode=t,this.table=e,this.createShowColumnDropdown=function(t){var e=document.createElement("select");function n(){var n=t.columns.filter((function(t){return t.visibility===a.b.Invisible}));if(0!=n.length){e.style.display="initial",e.innerHTML="";var i=document.createElement("option");i.text=o.a.getString("showColumn"),i.disabled=!0,i.selected=!0,e.appendChild(i),n.forEach((function(t){var n=document.createElement("option"),o=t.displayName;o.length>20&&(o=o.substring(0,20)+"..."),n.text=o,n.title=t.displayName,n.value=t.name,e.appendChild(n)}))}else e.style.display="none"}return e.classList.add("sa-table__show-column"),e.onchange=function(e){var n=e.target.value;e.stopPropagation(),n&&t.setColumnVisibility(n,a.b.Visible)},n(),t.onColumnsVisibilityChanged.add((function(){n()})),e},this.actions=[this.createFilterInput,this.createShowColumnDropdown,this.createEntriesSelector]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.table))}))},t.prototype.createFilterInput=function(t){var e=i.b.createInput("sa-table__global-filter","Search...");return e.onchange=function(e){t.applyFilter(e.target.value)},e},t.prototype.createEntriesSelector=function(t){var e=document.createElement("div");e.className="sa-table__entries";var n=document.createElement("span");n.innerHTML="Show";var o=document.createElement("span");return o.innerHTML="entries",o.className="sa-table__entries-label sa-table__entries-label--left",e.appendChild(n),n.className="sa-table__entries-label sa-table__entries-label--right",e.appendChild(function(t){var e=document.createElement("select");return["1","5","10","25","50","75","100"].forEach((function(t){var n=document.createElement("option");n.innerHTML=t,e.appendChild(n)})),e.value="5",e.onchange=function(){t.setPageSize(Number(e.value))},e}(t)),e.appendChild(o),e},t}()},function(t,e){t.exports='<svg style="display:none;"><symbol viewBox="0 0 16 16" id="sa-svg-detail"><circle class="st0" cx="1.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="8.5" r="1.5"></circle></symbol><symbol viewBox="0 0 16 16" id="sa-svg-drag"><path class="st0" d="M13 5l-1 1 1 1H9V3l1 1 1-1-3-3-3 3 1 1 1-1v4H3l1-1-1-1-3 3 3 3 1-1-1-1h4v4l-1-1-1 1 3 3 3-3-1-1-1 1V9h4l-1 1 1 1 3-3z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-hide"><path class="st1" d="M12.79 4.2L16 1l-1-1-3.32 3.32C10.57 2.55 9.32 2 8 2 3.63 2 0 7.97 0 7.97s1.27 2.1 3.21 3.82l-3.23 3.23.98.98 3.35-3.34C5.41 13.44 6.67 14 8 14c4.37 0 8-6 8-6s-1.27-2.09-3.21-3.8zM2 7.97c1.07-1.47 3.61-4 6-4 .8 0 1.6.27 2.35.68l-.78.78c-.46-.29-.99-.46-1.57-.46-1.66 0-3 1.34-3 3 0 .58.17 1.11.46 1.57l-.97.97A13.38 13.38 0 0 1 2 7.97zm6 4c-.8 0-1.59-.27-2.33-.67l.78-.77c.45.27.98.44 1.55.44 1.66 0 3-1.34 3-3 0-.57-.17-1.09-.44-1.55l.98-.98c1.11.87 2.01 1.91 2.46 2.52-1.07 1.48-3.61 4.01-6 4.01z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makeprivate"><circle class="st0" cx="8" cy="4" r="3"></circle><path class="st0" d="M8 8c-3.31 0-6 2.73-6 4.67S5.27 15 8 15s6-.4 6-2.33S11.31 8 8 8z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makepublic"><circle class="st0" cx="6" cy="5" r="3"></circle><path class="st0" d="M10 5c0 .34-.06.67-.14.99.05 0 .09.01.14.01 1.66 0 3-1.34 3-3s-1.34-3-3-3C8.97 0 8.07.52 7.53 1.3 8.98 1.91 10 3.33 10 5zM6 9c-3.31 0-6 2.73-6 4.67S3.27 16 6 16s6-.4 6-2.33S9.31 9 6 9zM10 7c-.19 0-.38.01-.57.03a4.14 4.14 0 0 1-1.37 1.39c3 .83 5.23 3.31 5.42 5.28 1.44-.31 2.52-.92 2.52-2.03C16 9.74 13.31 7 10 7z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-movetodetails"><circle class="st0" cx="1.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="14.5" r="1.5"></circle><path class="st0" d="M12 1h3v9h-3zM2.02 7.02L1 6 0 7l3 3 3-3-1-1-.94.94C4.33 4.73 6.21 3 8.5 3c.17 0 .33.03.5.05V1.03C8.83 1.01 8.67 1 8.5 1 5.08 1 2.27 3.66 2.02 7.02z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-sorting"><path class="st0" d="M8 3l2 2 1-1-3-3-3 3 1 1zM8 13l-2-2-1 1 3 3 3-3-1-1z"></path></symbol></svg>'},,,,function(t,e,n){},function(t,n){t.exports=e},,,,,,,function(t,e,n){"use strict";n.r(e),n.d(e,"localization",(function(){return o.a})),n.d(e,"surveyStrings",(function(){return o.b})),n.d(e,"defaultOptions",(function(){return m})),n.d(e,"Tabulator",(function(){return f}));var o=n(0),a=(n(5),n(6),n(3)),i=n(7),r=n(1),l=(n(15),n(2)),s=n(8),c=n(9),u=n(10),d=n(16);if(document){var p=n(11),h=document.createElement("div");h.style.display="none",h.innerHTML=p,document.head.appendChild(h)}var m={columnMinWidth:248,downloadOptions:{pdf:{isVisible:!0,orientation:"portrait",autoTable:{styles:{fillColor:[26,179,148]},columnStyles:{id:{fillColor:255}},margin:{top:60}}},csv:{isVisible:!0,delimiter:","},xlsx:{isVisible:!0,sheetName:"results"}},paginationButtonCount:3},f=function(t){function e(e,n,o,a,i){void 0===a&&(a=[]),void 0===i&&(i=!1);var l=t.call(this,e,n,o,a,i)||this;l.detailButtonCreators=[],l.COLUMN_MIN_WIDTH=155,l.tabulatorTables=null,l.tableContainer=null,l.render=function(t){t.className+=" sa-table sa-tabulator",t.innerHTML="";var e=l.getColumns(),n=l.tableData,o=l.createHeader(),a=l.createPaginationElement();l.tableContainer=document.createElement("div"),t.appendChild(o),t.appendChild(l.tableContainer),l.tabulatorTables=new d(l.tableContainer,{data:n,layout:"fitColumns",pagination:"local",paginationSize:5,movableColumns:!0,maxHeight:"100%",columns:e,rowFormatter:l.rowFormatter,paginationButtonCount:l.options.paginationButtonCount,paginationElement:a,columnMoved:l.columnMovedCallback});var i=l.createToolsContainer();o.appendChild(l.createDownloadsBar()),o.appendChild(i),o.appendChild(a),l.tableTools=new u.a(i,l),l.onTableToolsCreated.fire(l,{tools:l.tableTools}),l.tableTools.render(),l.renderResult=t},l.createToolsContainer=function(){var t=document.createElement("div");return t.classList.add("sa-tabulator__tools-container"),t},l.createHeader=function(){var t=document.createElement("div");return t.classList.add("sa-tabulator__header"),t},l.createPaginationElement=function(){var t=document.createElement("div");return t.classList.add("sa-tabulator__pagination-container"),t},l.destroy=function(){l.tabulatorTables.destroy(),l.renderResult.innerHTML="",l.renderResult=void 0},l.columnMovedCallback=function(t,e){var n=l._columns.indexOf(l._columns.filter((function(e){return e.name==t.getField()}))[0]),o=e.indexOf(t)-1,a=l._columns.splice(n,1);l._columns.splice(o,0,a[0])},l.rowFormatter=function(t){var e=new s.b(l,t.getCells()[0].getElement(),t.getElement(),t,l.renderDetailActions);e.onToggleDetails.add((function(){t.normalizeHeight(),l.update()})),l.onRowCreated.fire(l,{row:e}),e.render(),l._rows.push(e)},l.getTitleFormatter=function(t,e,n,o){var a=document.createElement("div"),i=l.getColumnTitle(t.getValue()),r=l.getHeaderActions(o);return a.appendChild(r),a.appendChild(i),a},l.getColumnTitle=function(t){var e=document.createElement("span");return e.innerHTML=t,e},l.getHeaderActions=function(t){var e=document.createElement("div");e.classList.add("sa-table__action-container");var n=new c.a(e,l,t,l.isTrustedAccess);return l.onColumnToolsCreated.fire(l,{tools:n}),n.render(),e},l.getColumns=function(){var t=l.getAvailableColumns(),e=l.COLUMN_MIN_WIDTH>l.options.columnMinWidth?l.COLUMN_MIN_WIDTH:l.options.columnMinWidth,n=t.map((function(t,n){var o=l.survey.getQuestionByName(t.name);return{field:t.name,title:o&&o.title||t.displayName,minWidth:e,widthShrink:1,visible:t.visibility!==r.b.Invisible,headerSort:!1,titleFormatter:function(e,n,o){return l.getTitleFormatter(e,n,o,t.name)}}}));return n.unshift({field:"",title:"",download:!1,resizable:!1,width:60}),n};var p=l;return l.options||(l.options=m),0===a.length&&(p._columns=p.buildColumns(e)),l}return Object(a.a)(e,t),e.prototype.createDownloadsBar=function(){var t=this,e=function(e,n){var o=l.b.createBtn(n);return o.onclick=function(){t.tabulatorTables.download(e)},o},n=document.createElement("div");return n.className="sa-tabulator__downloads-bar",this.options.downloadOptions.xlsx.isVisible&&n.appendChild(e("xlsx","Excel")),this.options.downloadOptions.pdf.isVisible&&n.appendChild(e("pdf","PDF")),n.appendChild(e("csv","CSV")),n},e.prototype.setColumnVisibility=function(e,n){t.prototype.setColumnVisibility.call(this,e,n),n==r.b.Invisible?this.tabulatorTables.hideColumn(e):this.tabulatorTables.showColumn(e),this.update()},e.prototype.setColumnLocation=function(e,n){t.prototype.setColumnLocation.call(this,e,n),n==r.c.Row?this.tabulatorTables.hideColumn(e):this.tabulatorTables.showColumn(e),this.update()},e.prototype.sortByColumn=function(t,e){this.tabulatorTables.setSort(t,e)},e.prototype.applyColumnFilter=function(t,e){this.tabulatorTables.setFilter(t,"like",e)},e.prototype.applyFilter=function(t){this.tabulatorTables.setFilter((function(t,e){for(var n in t)if(t[n].toLowerCase().includes(e.value.toLowerCase()))return!0;return!1}),{value:t})},e.prototype.setPageSize=function(t){this.tabulatorTables.setPageSize(t)},e.prototype.download=function(t){this.tabulatorTables.download(t,"results."+t,this.options.downloadOptions[t])},e.prototype.update=function(){this.tabulatorTables.redraw()},e}(i.a)}])}));
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("survey-core"),require("tabulator-tables")):"function"==typeof define&&define.amd?define("SurveyAnalyticsTabulator",["survey-core","tabulator-tables"],e):"object"==typeof exports?exports.SurveyAnalyticsTabulator=e(require("survey-core"),require("tabulator-tables")):t.SurveyAnalyticsTabulator=e(t.Survey,t.Tabulator)}(window,(function(t,e){return function(t){var e={};function n(o){if(e[o])return e[o].exports;var a=e[o]={i:o,l:!1,exports:{}};return t[o].call(a.exports,a,a.exports,n),a.l=!0,a.exports}return n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var a in t)n.d(o,a,function(e){return t[e]}.bind(null,a));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=23)}([function(t,e,n){"use strict";n.d(e,"a",(function(){return a})),n.d(e,"b",(function(){return i}));var o={groupButton:"Group By Me",ungroupButton:"Ungroup By Me",selectButton:"Select Me",hideColumn:"Hide column",showColumn:"Show column",makePrivateColumn:"Make column private",makePublicColumn:"Make column public",moveToDetail:"Move to Detail",showAsColumn:"Show as Column",visualizer_text:"Texts in table",visualizer_wordcloud:"Wordcloud",chartType_bar:"Bar",chartType_stackedbar:"Stacked Bar",chartType_doughnut:"Doughnut",chartType_pie:"Pie",chartType_scatter:"Scatter",chartType_gauge:"Gauge",chartType_bullet:"Bullet",hideButton:"Hide",showButton:"Show",resetFilter:"Reset Filter",changeLocale:"Change Locale",clearButton:"Clear",addElement:"Choose question to show...",defaultOrder:"Default",ascOrder:"Ascending",descOrder:"Descending",showMinorColumns:"Show minor columns",otherCommentTitle:"Other items and comments"},a={currentLocaleValue:"",defaultLocaleValue:"en",locales:{},localeNames:{},supportedLocales:[],get currentLocale(){return this.currentLocaleValue===this.defaultLocaleValue?"":this.currentLocaleValue},set currentLocale(t){this.currentLocaleValue=t},get defaultLocale(){return this.defaultLocaleValue},set defaultLocale(t){this.defaultLocaleValue=t},getString:function(t){var e=this.currentLocale?this.locales[this.currentLocale]:this.locales[this.defaultLocale];e&&e[t]||(e=this.locales[this.defaultLocale]);var n=e[t];return void 0===n&&(n=this.locales.en[t]||t),n},getLocales:function(){var t=[];if(t.push(""),this.supportedLocales&&this.supportedLocales.length>0)for(var e=0;e<this.supportedLocales.length;e++)t.push(this.supportedLocales[e]);else for(var n in this.locales)t.push(n);return t.sort(),t}},i=o;a.locales.en=o,a.localeNames.en="english"},function(t,e,n){"use strict";var o,a,i;n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return i})),function(t){t[t.Visible=0]="Visible",t[t.Invisible=1]="Invisible",t[t.PublicInvisible=2]="PublicInvisible"}(o||(o={})),function(t){t[t.Column=0]="Column",t[t.Row=1]="Row"}(a||(a={})),function(t){t[t.Text=0]="Text",t[t.FileLink=1]="FileLink",t[t.Image=2]="Image"}(i||(i={}))},function(t,e,n){"use strict";n.d(e,"c",(function(){return o})),n.d(e,"b",(function(){return a})),n.d(e,"d",(function(){return r})),n.d(e,"a",(function(){return l}));var o=function(){function t(){}return t.createSelector=function(t,e,n){var o=document.createElement("div");o.className="sa-question__select-wrapper";var a=document.createElement("select");return a.className="sa-question__select",t.forEach((function(t){var n=document.createElement("option");n.value=t.value,n.text=t.text,n.selected=e(t),a.appendChild(n)})),a.onchange=n,o.appendChild(a),o},t.createButton=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var o=document.createElement("span");return o.className="sa-toolbar__button "+n,o.innerText=e,o.onclick=t,o},t}(),a=function(){function t(){}return t.createSvgElement=function(t){var e=document.createElementNS("http://www.w3.org/2000/svg","svg"),n=document.createElementNS("http://www.w3.org/2000/svg","use");return n.setAttributeNS("http://www.w3.org/1999/xlink","href","#sa-svg-"+t),e.appendChild(n),e},t.createSvgButton=function(e){var n=document.createElement("button");return n.className="sa-table__svg-button",n.appendChild(t.createSvgElement(e)),n},t.createBtn=function(t){var e=document.createElement("button");return e.className="sa-table__btn sa-table__btn--small sa-table__btn--gray",e.innerHTML=t,e},t.createInput=function(t,e,n){void 0===e&&(e=""),void 0===n&&(n="");var o=document.createElement("input");return o.className=t,o.placeholder=e,o.defaultValue=n,o},t}(),i={runningInBrowser:"function"==typeof window.URL.createObjectURL};function r(){return i.runningInBrowser}var l=function(){function t(){}return t.zipArrays=function(t,e){for(var n=[],o=0;o<Math.min(t.length,e.length);o++)n[o]=[t[o],e[o]];return n},t.unzipArrays=function(t){var e={first:[],second:[]};return t.forEach((function(t,n){e.first[n]=t[0],e.second[n]=t[1]})),e},t.sortDictionary=function(t,e,n){var o=this.zipArrays(t,e),a=function(t,e,n){void 0===n&&(n=!0);var o=t[1]<e[1]?1:t[1]==e[1]?0:-1;return n?o:-1*o};o.sort((function(t,e){return n?a(t,e,!1):a(t,e)}));var i=this.unzipArrays(o);return{keys:i.first,values:i.second}},t.toPercentage=function(t,e){return t/e*100},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));Object.assign;function o(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);function o(){this.constructor=t}t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}},function(e,n){e.exports=t},function(t,e,n){"use strict";var o=n(0);o.a.locales.fa={groupButton:"گروه بندی با",ungroupButton:"حذف گروه",selectButton:"انتخاب",hideColumn:"مخفی کردن ستون",showColumn:"نمایش ستون",moveToDetail:"انتقال به جزئیات",showAsColumn:"نمایش به عنوان ستون",visualizer_text:"متون در جدول",visualizer_wordcloud:"ابر کلمات",chartType_bar:"میله ای",chartType_pie:"دابره ای(pie)",chartType_scatter:"پراکندگی(Scatter)",chartType_gauge:"عقربه ای",chartType_bullet:"Bullet",hideButton:"مخفی",resetFilter:"بازنشانی فیلترها",clearButton:"پاک کردن",addElement:"انتخاب سوال برای نمایش..."},o.a.localeNames.fa="Farsi(Persian)"},function(t,e,n){"use strict";var o=n(0);o.a.locales.fr={groupButton:"Grouper",ungroupButton:"Dissocier",selectButton:"Sélectionner",hideColumn:"Masquer colonne",showColumn:"Afficher colonne",makePrivateColumn:"Rendre la colonne privé",makePublicColumn:"Rendre la colonne public",moveToDetail:"Déplacer vers détails",showAsColumn:"Afficher en colonne",visualizer_text:"Textes en table",visualizer_wordcloud:"Nuages de mots",chartType_bar:"Barres",chartType_stackedbar:"Barres empilées",chartType_doughnut:"Anneau",chartType_pie:"Secteurs",chartType_scatter:"Nuages de points",chartType_gauge:"Gauge",chartType_bullet:"Bulles",hideButton:"Masquer",resetFilter:"Rafraichir Filtres",clearButton:"Rafraichir",addElement:"Choisir la question à afficher...",defaultOrder:"Defaut",ascOrder:"Ascendant",descOrder:"Descendant",showMinorColumns:"Afficher les colonnes mineures"},o.a.localeNames.fr="French"},function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var o=n(4),a=n(1),i=function(){function t(t,e,n,i,r){var l=this;void 0===i&&(i=[]),void 0===r&&(r=!1),this.survey=t,this.data=e,this.options=n,this._columns=i,this.isTrustedAccess=r,this._rows=[],this.onColumnsVisibilityChanged=new o.Event,this.onColumnsLocationChanged=new o.Event,this.onRowCreated=new o.Event,this.onTableToolsCreated=new o.Event,this.onColumnToolsCreated=new o.Event,this.buildColumns=function(t){return l.survey.getAllQuestions().map((function(t){return{name:t.name,displayName:(t.title||"").trim()||t.name,dataType:"file"!==t.getType()?a.a.Text:a.a.FileLink,visibility:"file"!==t.getType()?a.b.Visible:a.b.Invisible,location:a.c.Column}}))},this.isVisible=function(t){return l.isTrustedAccess&&t!==a.b.Invisible||!l.isTrustedAccess&&t===a.b.Visible},this.getAvailableColumns=function(){return l.columns.filter((function(t){return t.location===a.c.Column&&l.isVisible(t.visibility)}))},0===i.length&&(this._columns=this.buildColumns(t)),this.initTableData(e)}return t.prototype.getData=function(){return this.data},t.prototype.getCreatedRows=function(){return[].concat(this._rows)},Object.defineProperty(t.prototype,"columns",{get:function(){return[].concat(this._columns)},enumerable:!0,configurable:!0}),t.prototype.initTableData=function(t){var e=this;this.tableData=(t||[]).map((function(t){var n={};return e.survey.data=t,e._columns.forEach((function(o){var a=t[o.name],i=e.survey.getQuestionByName(o.name);i&&(a=i.displayValue),n[o.name]="string"==typeof a?a:JSON.stringify(a)||""})),n}))},t.prototype.setColumnLocation=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].location=e,this.onColumnsLocationChanged.fire(this,null)},t.prototype.setColumnVisibility=function(t,e){this.columns.filter((function(e){return e.name===t}))[0].visibility=e,this.onColumnsVisibilityChanged.fire(this,null)},t.prototype.getColumnVisibility=function(t){return this.columns.filter((function(e){return e.name===t}))[0].visibility},t.prototype.doStateSave=function(){this.stateSaveCallback({columns:this.columns},this.data)},t.prototype.stateSaveCallback=function(t,e){},t}()},function(t,e,n){"use strict";n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return u}));var o=n(3),a=n(4),i=n(0),r=n(1),l=n(2),s=function(){function t(t,e,n,o){var i=this;this.table=t,this.toolsContainer=e,this.detailsContainer=n,this.renderDetailActions=o,this.detailedRowClass="sa-table__detail-row",this.isDetailsExpanded=!1,this.onToggleDetails=new a.Event,this.details=new p(t,this,n,o),this.tools=new d(e,t,this),t.onColumnsLocationChanged.add((function(){i.closeDetails()}))}return t.prototype.getIsDetailsExpanded=function(){return!1},t.prototype.render=function(){this.tools.render()},t.prototype.openDetails=function(){this.details.open(),this.getElement().className+=" "+this.detailedRowClass,this.onToggleDetails.fire(this,{isExpanded:!0}),this.isDetailsExpanded=!0},t.prototype.closeDetails=function(){this.details.close(),this.getElement().classList.remove(this.detailedRowClass),this.onToggleDetails.fire(this,{isExpanded:!1}),this.isDetailsExpanded=!1},t.prototype.toggleDetails=function(){this.isDetailsExpanded?this.closeDetails():this.openDetails()},t}(),c=function(t){function e(e,n,o,a,i){var r=t.call(this,e,n,o,i)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=o,r.innerRow=a,r.renderDetailActions=i,r}return Object(o.a)(e,t),e.prototype.getElement=function(){return this.innerRow.getElement()},e.prototype.getData=function(){return this.innerRow.getData()},e}(s),u=function(t){function e(e,n,o,a,i){var r=t.call(this,e,n,o,i)||this;return r.table=e,r.toolsContainer=n,r.detailsContainer=o,r._innerRow=a,r.renderDetailActions=i,r.rowElement=a.node(),r.rowData=a.data(),r._innerRow=r._innerRow.row(r.rowElement),r}return Object(o.a)(e,t),Object.defineProperty(e.prototype,"innerRow",{get:function(){return this._innerRow.row(this.rowElement)},enumerable:!0,configurable:!0}),e.prototype.getElement=function(){return this.rowElement},e.prototype.getData=function(){return this.rowData},e}(s),d=function(){function t(t,e,n){this.targetNode=t,this.table=e,this.row=n,this.createDetailsBtn=function(t){var e=l.b.createSvgButton("detail");return e.title=i.a.getString("showMinorColumns"),e.onclick=function(){t.toggleDetails()},e},this.actions=[this.createDetailsBtn]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.row,t.table))}))},t}(),p=function(){function t(t,e,n,o){var a=this;this.table=t,this.row=e,this.targetNode=n,this.renderActions=o,this.createShowAsColumnButton=function(t){var e=document.createElement("button");return e.innerHTML=i.a.getString("showAsColumn"),e.className="sa-table__btn sa-table__btn--gray",e.onclick=function(e){e.stopPropagation(),a.table.setColumnLocation(t,r.c.Column)},e};var l=document.createElement("table");l.className="sa-table__detail-table",this.detailsTable=l,this.table.onColumnsLocationChanged.add((function(){a.close()}))}return t.prototype.setContainer=function(t){this.targetNode=t},t.prototype.open=function(){var t=this;this.detailsTable.innerHTML="";var e=[];if(this.table.columns.filter((function(t){return t.location===r.c.Row&&t})).forEach((function(n){var o=document.createElement("tr");o.className="sa-table__detail";var a=document.createElement("td");a.textContent=n.displayName;var i=document.createElement("td");i.textContent=t.row.getData()[n.name];var r=document.createElement("td");r.appendChild(t.createShowAsColumnButton(n.name)),o.appendChild(a),o.appendChild(i),o.appendChild(r),e.push(o)})),this.renderActions){var n=document.createElement("tr");n.className="sa-table__detail";var o=document.createElement("td");o.colSpan=3,n.appendChild(o),e.push(n),this.renderActions(o,this.row)}e.forEach((function(e){t.detailsTable.appendChild(e)})),this.targetNode.appendChild(this.detailsTable)},t.prototype.close=function(){this.detailsTable.remove()},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var o=n(2),a=n(0),i=n(1),r=function(){function t(t,e,n,o){this.targetNode=t,this.table=e,this.columnName=n,this.isTrustedAccess=o}return t.prototype.render=function(){this.targetNode.appendChild(this.createDragBtn()),this.targetNode.appendChild(this.createSortBtn()),this.targetNode.appendChild(this.createHideBtn()),this.isTrustedAccess&&this.targetNode.appendChild(this.createColumnPrivateButton()),this.targetNode.appendChild(this.createMoveToDetailsBtn()),this.targetNode.appendChild(this.createFilterInput())},t.prototype.createDragBtn=function(){var t=document.createElement("button");return t.className="sa-table__svg-button sa-table__drag-button",t.appendChild(o.b.createSvgElement("drag")),t.onclick=function(t){t.stopPropagation()},t},t.prototype.createSortBtn=function(){var t=this,e=a.a.getString("descOrder"),n=a.a.getString("ascOrder"),i=o.b.createSvgButton("sorting");i.title="";var r="asc";return i.onclick=function(o){"asc"==r?(i.title=e,r="desc"):(i.title=n,r="asc"),t.table.sortByColumn(t.columnName,r)},i.ondrag=function(t){t.stopPropagation()},i},t.prototype.createHideBtn=function(){var t=this,e=o.b.createSvgButton("hide");return e.title=a.a.getString("hideColumn"),e.onclick=function(){t.table.setColumnVisibility(t.columnName,i.b.Invisible)},e},t.prototype.createMoveToDetailsBtn=function(){var t=this,e=o.b.createSvgButton("movetodetails");return e.title=a.a.getString("moveToDetail"),e.onclick=function(e){e.stopPropagation(),t.table.setColumnLocation(t.columnName,i.c.Row)},e},t.prototype.createFilterInput=function(){var t=this,e=o.b.createInput("sa-table__filter","Search...");return e.onclick=function(t){return t.stopPropagation()},e.onchange=function(n){t.table.applyColumnFilter(t.columnName,e.value)},e},t.prototype.createColumnPrivateButton=function(){var t=this,e=document.createElement("button"),n=o.b.createSvgElement("makeprivate"),r=o.b.createSvgElement("makepublic"),l=this.table.getColumnVisibility(this.columnName);function s(t){t===i.b.PublicInvisible?(e.className="sa-table__svg-button sa-table__svg-button--active",e.title=a.a.getString("makePublicColumn"),n.style.display="block",r.style.display="none"):(e.className="sa-table__svg-button",e.title=a.a.getString("makePrivateColumn"),n.style.display="none",r.style.display="block")}return s(l),e.appendChild(n),e.appendChild(r),e.onclick=function(e){e.stopPropagation(),l=l===i.b.PublicInvisible?i.b.Visible:i.b.PublicInvisible,t.table.setColumnVisibility(t.columnName,l),s(l)},e},t}()},function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var o=n(0),a=n(1),i=n(2),r=function(){function t(t,e){this.targetNode=t,this.table=e,this.createShowColumnDropdown=function(t){var e=document.createElement("select");function n(){var n=t.columns.filter((function(t){return t.visibility===a.b.Invisible}));if(0!=n.length){e.style.display="initial",e.innerHTML="";var i=document.createElement("option");i.text=o.a.getString("showColumn"),i.disabled=!0,i.selected=!0,e.appendChild(i),n.forEach((function(t){var n=document.createElement("option"),o=t.displayName;o.length>20&&(o=o.substring(0,20)+"..."),n.text=o,n.title=t.displayName,n.value=t.name,e.appendChild(n)}))}else e.style.display="none"}return e.classList.add("sa-table__show-column"),e.onchange=function(e){var n=e.target.value;e.stopPropagation(),n&&t.setColumnVisibility(n,a.b.Visible)},n(),t.onColumnsVisibilityChanged.add((function(){n()})),e},this.actions=[this.createFilterInput,this.createShowColumnDropdown,this.createEntriesSelector]}return t.prototype.render=function(){var t=this;this.actions.forEach((function(e){t.targetNode.appendChild(e(t.table))}))},t.prototype.createFilterInput=function(t){var e=i.b.createInput("sa-table__global-filter","Search...");return e.onchange=function(e){t.applyFilter(e.target.value)},e},t.prototype.createEntriesSelector=function(t){var e=document.createElement("div");e.className="sa-table__entries";var n=document.createElement("span");n.innerHTML="Show";var o=document.createElement("span");return o.innerHTML="entries",o.className="sa-table__entries-label sa-table__entries-label--left",e.appendChild(n),n.className="sa-table__entries-label sa-table__entries-label--right",e.appendChild(function(t){var e=document.createElement("select");return["1","5","10","25","50","75","100"].forEach((function(t){var n=document.createElement("option");n.innerHTML=t,e.appendChild(n)})),e.value="5",e.onchange=function(){t.setPageSize(Number(e.value))},e}(t)),e.appendChild(o),e},t}()},function(t,e){t.exports='<svg style="display:none;"><symbol viewBox="0 0 16 16" id="sa-svg-detail"><circle class="st0" cx="1.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="8.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="8.5" r="1.5"></circle></symbol><symbol viewBox="0 0 16 16" id="sa-svg-drag"><path class="st0" d="M13 5l-1 1 1 1H9V3l1 1 1-1-3-3-3 3 1 1 1-1v4H3l1-1-1-1-3 3 3 3 1-1-1-1h4v4l-1-1-1 1 3 3 3-3-1-1-1 1V9h4l-1 1 1 1 3-3z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-hide"><path class="st1" d="M12.79 4.2L16 1l-1-1-3.32 3.32C10.57 2.55 9.32 2 8 2 3.63 2 0 7.97 0 7.97s1.27 2.1 3.21 3.82l-3.23 3.23.98.98 3.35-3.34C5.41 13.44 6.67 14 8 14c4.37 0 8-6 8-6s-1.27-2.09-3.21-3.8zM2 7.97c1.07-1.47 3.61-4 6-4 .8 0 1.6.27 2.35.68l-.78.78c-.46-.29-.99-.46-1.57-.46-1.66 0-3 1.34-3 3 0 .58.17 1.11.46 1.57l-.97.97A13.38 13.38 0 0 1 2 7.97zm6 4c-.8 0-1.59-.27-2.33-.67l.78-.77c.45.27.98.44 1.55.44 1.66 0 3-1.34 3-3 0-.57-.17-1.09-.44-1.55l.98-.98c1.11.87 2.01 1.91 2.46 2.52-1.07 1.48-3.61 4.01-6 4.01z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makeprivate"><circle class="st0" cx="8" cy="4" r="3"></circle><path class="st0" d="M8 8c-3.31 0-6 2.73-6 4.67S5.27 15 8 15s6-.4 6-2.33S11.31 8 8 8z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-makepublic"><circle class="st0" cx="6" cy="5" r="3"></circle><path class="st0" d="M10 5c0 .34-.06.67-.14.99.05 0 .09.01.14.01 1.66 0 3-1.34 3-3s-1.34-3-3-3C8.97 0 8.07.52 7.53 1.3 8.98 1.91 10 3.33 10 5zM6 9c-3.31 0-6 2.73-6 4.67S3.27 16 6 16s6-.4 6-2.33S9.31 9 6 9zM10 7c-.19 0-.38.01-.57.03a4.14 4.14 0 0 1-1.37 1.39c3 .83 5.23 3.31 5.42 5.28 1.44-.31 2.52-.92 2.52-2.03C16 9.74 13.31 7 10 7z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-movetodetails"><circle class="st0" cx="1.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="7.5" cy="14.5" r="1.5"></circle><circle class="st0" cx="13.5" cy="14.5" r="1.5"></circle><path class="st0" d="M12 1h3v9h-3zM2.02 7.02L1 6 0 7l3 3 3-3-1-1-.94.94C4.33 4.73 6.21 3 8.5 3c.17 0 .33.03.5.05V1.03C8.83 1.01 8.67 1 8.5 1 5.08 1 2.27 3.66 2.02 7.02z"></path></symbol><symbol viewBox="0 0 16 16" id="sa-svg-sorting"><path class="st0" d="M8 3l2 2 1-1-3-3-3 3 1 1zM8 13l-2-2-1 1 3 3 3-3-1-1z"></path></symbol></svg>'},,,,function(t,e,n){},function(t,n){t.exports=e},,,,,,,function(t,e,n){"use strict";n.r(e),n.d(e,"localization",(function(){return o.a})),n.d(e,"surveyStrings",(function(){return o.b})),n.d(e,"defaultOptions",(function(){return m})),n.d(e,"Tabulator",(function(){return f}));var o=n(0),a=(n(5),n(6),n(3)),i=n(7),r=n(1),l=(n(15),n(2)),s=n(8),c=n(9),u=n(10),d=n(16);if(document){var p=n(11),h=document.createElement("div");h.style.display="none",h.innerHTML=p,document.head.appendChild(h)}var m={columnMinWidth:248,downloadOptions:{pdf:{isVisible:!0,orientation:"portrait",autoTable:{styles:{fillColor:[26,179,148]},columnStyles:{id:{fillColor:255}},margin:{top:60}}},csv:{isVisible:!0,delimiter:","},xlsx:{isVisible:!0,sheetName:"results"}},paginationButtonCount:3},f=function(t){function e(e,n,o,a,i){void 0===a&&(a=[]),void 0===i&&(i=!1);var l=t.call(this,e,n,o,a,i)||this;l.detailButtonCreators=[],l.COLUMN_MIN_WIDTH=155,l.tabulatorTables=null,l.tableContainer=null,l.render=function(t){t.className+=" sa-table sa-tabulator",t.innerHTML="";var e=l.getColumns(),n=l.tableData,o=l.createHeader(),a=l.createPaginationElement();l.tableContainer=document.createElement("div"),t.appendChild(o),t.appendChild(l.tableContainer),l.tabulatorTables=new d(l.tableContainer,{data:n,layout:"fitColumns",pagination:"local",paginationSize:5,movableColumns:!0,maxHeight:"100%",columns:e,rowFormatter:l.rowFormatter,paginationButtonCount:l.options.paginationButtonCount,paginationElement:a,columnMoved:l.columnMovedCallback});var i=l.createToolsContainer();o.appendChild(l.createDownloadsBar()),o.appendChild(i),o.appendChild(a),l.tableTools=new u.a(i,l),l.onTableToolsCreated.fire(l,{tools:l.tableTools}),l.tableTools.render(),l.renderResult=t},l.createToolsContainer=function(){var t=document.createElement("div");return t.classList.add("sa-tabulator__tools-container"),t},l.createHeader=function(){var t=document.createElement("div");return t.classList.add("sa-tabulator__header"),t},l.createPaginationElement=function(){var t=document.createElement("div");return t.classList.add("sa-tabulator__pagination-container"),t},l.destroy=function(){l.tabulatorTables.destroy(),l.renderResult.innerHTML="",l.renderResult=void 0},l.columnMovedCallback=function(t,e){var n=l._columns.indexOf(l._columns.filter((function(e){return e.name==t.getField()}))[0]),o=e.indexOf(t)-1,a=l._columns.splice(n,1);l._columns.splice(o,0,a[0])},l.rowFormatter=function(t){var e=new s.b(l,t.getCells()[0].getElement(),t.getElement(),t,l.renderDetailActions);e.onToggleDetails.add((function(){t.normalizeHeight(),l.update()})),l.onRowCreated.fire(l,{row:e}),e.render(),l._rows.push(e)},l.getTitleFormatter=function(t,e,n,o){var a=document.createElement("div"),i=l.getColumnTitle(t.getValue()),r=l.getHeaderActions(o);return a.appendChild(r),a.appendChild(i),a},l.getColumnTitle=function(t){var e=document.createElement("span");return e.innerHTML=t,e},l.getHeaderActions=function(t){var e=document.createElement("div");e.classList.add("sa-table__action-container");var n=new c.a(e,l,t,l.isTrustedAccess);return l.onColumnToolsCreated.fire(l,{tools:n}),n.render(),e},l.getColumns=function(){var t=l.getAvailableColumns(),e=l.COLUMN_MIN_WIDTH>l.options.columnMinWidth?l.COLUMN_MIN_WIDTH:l.options.columnMinWidth,n=t.map((function(t,n){var o=l.survey.getQuestionByName(t.name);return{field:t.name,title:o&&o.title||t.displayName,minWidth:e,widthShrink:1,visible:t.visibility!==r.b.Invisible,headerSort:!1,titleFormatter:function(e,n,o){return l.getTitleFormatter(e,n,o,t.name)}}}));return n.unshift({field:"",title:"",download:!1,resizable:!1,width:60}),n};var p=l;return l.options||(l.options=m),0===a.length&&(p._columns=p.buildColumns(e)),l}return Object(a.a)(e,t),e.prototype.createDownloadsBar=function(){var t=this,e=function(e,n){var o=l.b.createBtn(n);return o.onclick=function(){t.tabulatorTables.download(e)},o},n=document.createElement("div");return n.className="sa-tabulator__downloads-bar",this.options.downloadOptions.xlsx.isVisible&&n.appendChild(e("xlsx","Excel")),this.options.downloadOptions.pdf.isVisible&&n.appendChild(e("pdf","PDF")),n.appendChild(e("csv","CSV")),n},e.prototype.setColumnVisibility=function(e,n){t.prototype.setColumnVisibility.call(this,e,n),n==r.b.Invisible?this.tabulatorTables.hideColumn(e):this.tabulatorTables.showColumn(e),this.update()},e.prototype.setColumnLocation=function(e,n){t.prototype.setColumnLocation.call(this,e,n),n==r.c.Row?this.tabulatorTables.hideColumn(e):this.tabulatorTables.showColumn(e),this.update()},e.prototype.sortByColumn=function(t,e){this.tabulatorTables.setSort(t,e)},e.prototype.applyColumnFilter=function(t,e){this.tabulatorTables.setFilter(t,"like",e)},e.prototype.applyFilter=function(t){this.tabulatorTables.setFilter((function(t,e){for(var n in t)if(t[n].toLowerCase().includes(e.value.toLowerCase()))return!0;return!1}),{value:t})},e.prototype.setPageSize=function(t){this.tabulatorTables.setPageSize(t)},e.prototype.download=function(t){this.tabulatorTables.download(t,"results."+t,this.options.downloadOptions[t])},e.prototype.update=function(){this.tabulatorTables.redraw()},e}(i.a)}])}));

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc