{"version":3,"sources":["webpack:///./node_modules/moment/locale/uz-latn.js","webpack:///./src/views/triggerAlerts/StatusAlert.vue?8a1a","webpack:///./node_modules/moment/locale/ml.js","webpack:///./node_modules/moment/locale/cv.js","webpack:///./node_modules/moment/locale/is.js","webpack:///./node_modules/moment/locale/fo.js","webpack:///./node_modules/moment/locale/ja.js","webpack:///./node_modules/@syncfusion/ej2-popups/src/tooltip/tooltip.js","webpack:///./node_modules/@syncfusion/ej2-calendars/src/datepicker/datepicker.js","webpack:///./node_modules/moment/locale/es-do.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/chart-series.js","webpack:///./node_modules/moment/locale/ar-ma.js","webpack:///./node_modules/moment/locale/gom-latn.js","webpack:///./node_modules/moment/locale/fr-ch.js","webpack:///./node_modules/moment/locale/en-au.js","webpack:///./node_modules/moment/locale/tr.js","webpack:///./node_modules/moment/locale/da.js","webpack:///./node_modules/moment/locale/tl-ph.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/model/chart-base.js","webpack:///./node_modules/moment/locale/eu.js","webpack:///./node_modules/moment/locale/th.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/axis/axis-helper.js","webpack:///./node_modules/moment/locale/sr-cyrl.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/line-base.js","webpack:///./node_modules/moment/locale/oc-lnc.js","webpack:///./node_modules/moment/locale/mt.js","webpack:///./node_modules/moment/locale/ar-ly.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/user-interaction/tooltip.js","webpack:///./node_modules/moment/locale/be.js","webpack:///./node_modules/moment/locale/ka.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/foreign-key.js","webpack:///./node_modules/moment/locale/ko.js","webpack:///./node_modules/moment/locale/ku.js","webpack:///./node_modules/moment/locale/bs.js","webpack:///./node_modules/moment/locale/lt.js","webpack:///./node_modules/@syncfusion/ej2-compression/src/compression-writer.js","webpack:///./node_modules/moment/locale/vi.js","webpack:///./node_modules/moment/locale/me.js","webpack:///./src/common/syncfusion.js","webpack:///./node_modules/moment/locale/af.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/data.js","webpack:///./node_modules/moment/locale/uz.js","webpack:///./node_modules/@syncfusion/ej2-calendars/src/calendar/calendar.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/axis/cartesian-panel.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/marker-explode.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/marker.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/technical-indicators/technical-indicator.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/chart.js","webpack:///./node_modules/@syncfusion/ej2-dropdowns/src/common/highlight-search.js","webpack:///./node_modules/@syncfusion/ej2-dropdowns/src/auto-complete/auto-complete.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/base/string-literals.js","webpack:///./node_modules/moment/locale/en-ca.js","webpack:///./node_modules/moment/locale/en-gb.js","webpack:///./node_modules/@syncfusion/ej2-buttons/src/radio-button/radio-button.js","webpack:///./node_modules/moment/locale/mr.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/axis/axis.js","webpack:///./node_modules/moment/locale/ne.js","webpack:///./node_modules/moment/locale/zh-mo.js","webpack:///./node_modules/moment/locale/tg.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/models/column.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/scroll.js","webpack:///./node_modules/moment/locale/cs.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/summary-model-generator.js","webpack:///./node_modules/moment/locale/ta.js","webpack:///./node_modules/moment/locale/kn.js","webpack:///./src/views/triggerAlerts/StatusAlert.vue?953c","webpack:///src/views/triggerAlerts/StatusAlert.vue","webpack:///./src/views/triggerAlerts/StatusAlert.vue?3b21","webpack:///./src/views/triggerAlerts/StatusAlert.vue","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/user-interaction/zooming-toolkit.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/user-interaction/zooming.js","webpack:///./node_modules/@syncfusion/ej2-vue-popups/src/dialog/buttons.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-popups/src/dialog/dialog.component.js","webpack:///./node_modules/moment/locale/ar-kw.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/worksheets.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/worksheet.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/cell-style.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/column.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/row.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/image.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/cell.js","webpack:///./node_modules/@syncfusion/ej2-compression/src/utils.js","webpack:///./node_modules/@syncfusion/ej2-compression/src/decompressor-huffman-tree.js","webpack:///./node_modules/@syncfusion/ej2-compression/src/checksum-calculator.js","webpack:///./node_modules/@syncfusion/ej2-compression/src/compression-reader.js","webpack:///./node_modules/@syncfusion/ej2-compression/src/zip-archive.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/value-formatter.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/csv-helper.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/blob-helper.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/auto-filters.js","webpack:///./node_modules/@syncfusion/ej2-excel-export/src/workbook.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/aria-service.js","webpack:///./node_modules/moment/locale/lb.js","webpack:///./node_modules/@syncfusion/ej2-navigations/src/toolbar/toolbar.js","webpack:///./node_modules/@syncfusion/ej2-navigations/src/common/h-scroll.js","webpack:///./node_modules/moment/locale sync ^\\.\\/.*$","webpack:///./node_modules/moment/locale/az.js","webpack:///./node_modules/moment/locale/zh-hk.js","webpack:///./node_modules/moment/locale/hr.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/reorder.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/command-column-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/command-column.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/legend/legend.js","webpack:///./node_modules/moment/locale/id.js","webpack:///./src/common/dates.js","webpack:///./node_modules/moment/locale/ga.js","webpack:///./node_modules/@syncfusion/ej2-svg-base/src/svg-render/svg-renderer.js","webpack:///./node_modules/@syncfusion/ej2-svg-base/src/svg-render/canvas-renderer.js","webpack:///./node_modules/@syncfusion/ej2-svg-base/src/tooltip/interface.js","webpack:///./node_modules/@syncfusion/ej2-svg-base/src/tooltip/helper.js","webpack:///./node_modules/@syncfusion/ej2-svg-base/src/tooltip/tooltip.js","webpack:///./node_modules/moment/locale/ur.js","webpack:///./node_modules/moment/locale/ss.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/column-base.js","webpack:///./node_modules/moment/locale/es-us.js","webpack:///./node_modules/moment/locale/tet.js","webpack:///./node_modules/moment/locale/dv.js","webpack:///./node_modules/moment/locale/tk.js","webpack:///./node_modules/moment/locale/hu.js","webpack:///./node_modules/moment/locale/zh-cn.js","webpack:///./node_modules/moment/locale/te.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/utils/get-data.js","webpack:///./node_modules/moment/locale/sv.js","webpack:///./node_modules/moment/locale/ug-cn.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/multi-colored-base.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/multi-colored-line-series.js","webpack:///(webpack)/buildin/module.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/model/constants.js","webpack:///./node_modules/moment/locale/ms-my.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/axis/category-axis.js","webpack:///./node_modules/moment/locale/eo.js","webpack:///./node_modules/moment/locale/sd.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/axis/strip-line.js","webpack:///./node_modules/moment/locale/br.js","webpack:///./node_modules/moment/locale/mi.js","webpack:///./node_modules/moment/locale/mk.js","webpack:///./node_modules/moment/locale/nb.js","webpack:///./node_modules/moment/locale/kk.js","webpack:///./node_modules/moment/locale/ar-tn.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/export-helper.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/excel-export.js","webpack:///./node_modules/moment/locale/it.js","webpack:///./node_modules/moment/locale/it-ch.js","webpack:///./node_modules/moment/locale/en-nz.js","webpack:///./node_modules/moment/locale/fy.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/print.js","webpack:///./node_modules/moment/locale/en-il.js","webpack:///./node_modules/@syncfusion/ej2-calendars/src/timepicker/timepicker.js","webpack:///./node_modules/@syncfusion/ej2-calendars/src/datetimepicker/datetimepicker.js","webpack:///./node_modules/moment/locale/sw.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/model/data.js","webpack:///./node_modules/moment/locale/sk.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/value-formatter.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/filter-cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/filter-menu-operator.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/string-filter-ui.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/number-filter-ui.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/boolean-filter-ui.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/date-filter-ui.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/filter-menu-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/checkbox-filter.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/common/excel-filter-base.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/excel-filter.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/filter.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/trendlines.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/segments.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/series.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/striplines.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/categories.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/multilevellabels.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/axes.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/rows.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/columns.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/rangecolorsettings.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/annotations.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/selecteddataindexes.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/indicators.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-charts/src/chart/chart.component.js","webpack:///./node_modules/moment/locale/yo.js","webpack:///./node_modules/@syncfusion/ej2-dropdowns/src/combo-box/combo-box.js","webpack:///./node_modules/moment/locale/sl.js","webpack:///./node_modules/moment/locale/fi.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/annotation/annotation.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/annotation/annotation.js","webpack:///./node_modules/moment/locale/ar-sa.js","webpack:///./node_modules/moment/locale/bg.js","webpack:///./node_modules/moment/locale/my.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/row-renderer.js","webpack:///./node_modules/moment/locale/gl.js","webpack:///./node_modules/moment/locale/es.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/column-series.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/row-model-generator.js","webpack:///./node_modules/moment/locale/el.js","webpack:///./node_modules/moment/locale/pl.js","webpack:///./node_modules/moment/locale/fa.js","webpack:///./node_modules/moment/locale/ar.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/line-series.js","webpack:///./node_modules/moment/locale/bn.js","webpack:///./node_modules/moment/locale/zh-tw.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/base/enum.js","webpack:///./node_modules/moment/locale/ru.js","webpack:///./node_modules/moment/locale/mn.js","webpack:///./node_modules/moment/locale/ky.js","webpack:///./node_modules/moment/locale/bn-bd.js","webpack:///./node_modules/moment/locale/ro.js","webpack:///./node_modules/@syncfusion/ej2-navigations/src/common/v-scroll.js","webpack:///./node_modules/moment/locale/cy.js","webpack:///./node_modules/@syncfusion/ej2-inputs/src/form-validator/form-validator.js","webpack:///./node_modules/@syncfusion/ej2-vue-buttons/src/button/button.component.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/header-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/header-cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/stacked-cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/indent-cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/caption-cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/expand-cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/header-indent-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/detail-header-indent-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/detail-expand-cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/row-drag-drop-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/row-drag-header-indent-render.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/render.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/cell-render-factory.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/service-locator.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/renderer-factory.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/models/page-settings.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/models/column-chooser-settings.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/search.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/show-hide.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/models/aggregate.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/clipboard.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/base/grid.js","webpack:///./node_modules/@syncfusion/ej2-buttons/src/check-box/check-box.js","webpack:///./node_modules/moment/locale/fr.js","webpack:///./node_modules/moment/locale/ar-dz.js","webpack:///./node_modules/@syncfusion/ej2-inputs/src/numerictextbox/numerictextbox.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/common/checkbox-filter-base.js","webpack:///./node_modules/moment/locale/bm.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/cell-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/inline-edit-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/batch-edit-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/dialog-edit-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/edit-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/edit-cell-base.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/boolean-edit-cell.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/dropdown-edit-cell.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/numeric-edit-cell.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/default-edit-cell.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/normal-edit.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/inline-edit.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/batch-edit.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/dialog-edit.js","webpack:///./node_modules/@syncfusion/ej2-calendars/src/maskbase/masked-date-time.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/datepicker-edit-cell.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/template-edit-cell.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/edit.js","webpack:///./node_modules/moment/locale/gom-deva.js","webpack:///./node_modules/moment/locale/uk.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/responsive-dialog-renderer.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/user-interaction/tooltip.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/pager/numeric-container.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/pager/pager-message.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/pager/pager.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/pager/pager-dropdown.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/pager/external-message.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/page.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/selection.js","webpack:///./node_modules/moment/locale/lo.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/width-controller.js","webpack:///./node_modules/moment/locale/de-at.js","webpack:///./node_modules/moment/locale/de.js","webpack:///./node_modules/moment/locale/tzm-latn.js","webpack:///./node_modules/moment/locale/jv.js","webpack:///./node_modules/moment/locale/es-mx.js","webpack:///./node_modules/@syncfusion/ej2-navigations/src/common/menu-scroll.js","webpack:///./node_modules/@syncfusion/ej2-navigations/src/common/menu-base.js","webpack:///./node_modules/moment/locale/en-sg.js","webpack:///./node_modules/moment/locale/nn.js","webpack:///./node_modules/moment/locale/lv.js","webpack:///./node_modules/moment/locale/de-ch.js","webpack:///./node_modules/@syncfusion/ej2-vue-grids/src/grid/stacked-column.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-grids/src/grid/columns.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-grids/src/grid/aggregate-columns.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-grids/src/grid/aggregates.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-grids/src/grid/grid.component.js","webpack:///./node_modules/moment/locale/tzm.js","webpack:///./node_modules/moment/moment.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/axis/date-time-axis.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/focus-strategy.js","webpack:///./node_modules/moment/locale/he.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/utils/print.js","webpack:///./node_modules/moment/locale/sq.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/model/base.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/axis/double-axis.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/base/constant.js","webpack:///./node_modules/moment/locale/sr.js","webpack:///./node_modules/moment/locale/tzl.js","webpack:///./node_modules/moment/locale/tlh.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/content-renderer.js","webpack:///./node_modules/moment/locale/bo.js","webpack:///./node_modules/moment/locale/pt-br.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/services/group-model-generator.js","webpack:///./node_modules/moment/locale/fil.js","webpack:///./node_modules/moment/locale/hy-am.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/model/theme.js","webpack:///./node_modules/moment/locale/ca.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/base/util.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/common/utils/helper.js","webpack:///./node_modules/moment/locale/fr-ca.js","webpack:///./node_modules/moment/locale/nl-be.js","webpack:///./node_modules/moment/locale/hi.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/renderer/cell-merge-renderer.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/toolbar.js","webpack:///./node_modules/moment/locale/gu.js","webpack:///./node_modules/@syncfusion/ej2-inputs/src/uploader/uploader.js","webpack:///./node_modules/@syncfusion/ej2-vue-inputs/src/uploader/files.directive.js","webpack:///./node_modules/@syncfusion/ej2-vue-inputs/src/uploader/uploader.component.js","webpack:///./node_modules/moment/locale/en-ie.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/sort.js","webpack:///./node_modules/moment/locale/km.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/utils/double-range.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/models/row.js","webpack:///./node_modules/moment/locale/ms.js","webpack:///./node_modules/moment/locale/et.js","webpack:///./node_modules/moment/locale/en-in.js","webpack:///./node_modules/moment/locale/si.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/models/cell.js","webpack:///./node_modules/@syncfusion/ej2-grids/src/grid/actions/resize.js","webpack:///./node_modules/@syncfusion/ej2-inputs/src/textbox/textbox.js","webpack:///./node_modules/moment/locale/pt.js","webpack:///./node_modules/@syncfusion/ej2-file-utils/src/save.js","webpack:///./node_modules/moment/locale/pa-in.js","webpack:///./node_modules/@syncfusion/ej2-file-utils/src/encoding.js","webpack:///./node_modules/moment/locale/gd.js","webpack:///./node_modules/@syncfusion/ej2-navigations/src/context-menu/context-menu.js","webpack:///./node_modules/moment/locale/nl.js","webpack:///./node_modules/@syncfusion/ej2-charts/src/chart/series/data-label.js","webpack:///./node_modules/moment/locale/x-pseudo.js","webpack:///./node_modules/moment/locale/se.js"],"names":["global","factory","this","moment","uzLatn","defineLocale","months","split","monthsShort","weekdays","weekdaysShort","weekdaysMin","longDateFormat","LT","LTS","L","LL","LLL","LLLL","calendar","sameDay","nextDay","nextWeek","lastDay","lastWeek","sameElse","relativeTime","future","past","s","ss","m","mm","h","hh","d","dd","M","MM","y","yy","week","dow","doy","ml","monthsParseExact","meridiemParse","meridiemHour","hour","meridiem","minute","isLower","cv","output","affix","exec","dayOfMonthOrdinalParse","ordinal","plural","n","translate","number","withoutSuffix","key","isFuture","result","is","fo","ja","eras","since","offset","name","narrow","abbr","until","Infinity","eraYearOrdinalRegex","eraYearOrdinalParse","input","match","parseInt","l","ll","lll","llll","isPM","now","period","__extends","extendStatics","b","Object","setPrototypeOf","__proto__","Array","p","hasOwnProperty","__","constructor","prototype","create","__decorate","decorators","target","desc","c","arguments","length","r","getOwnPropertyDescriptor","Reflect","decorate","i","defineProperty","TOUCHEND_HIDE_DELAY","TAPHOLD_THRESHOLD","SHOW_POINTER_TIP_GAP","HIDE_POINTER_TIP_GAP","MOUSE_TRAIL_GAP","POINTER_ADJUST","ROOT","RTL","DEVICE","ICON","CLOSE","TOOLTIP_WRAP","CONTENT","ARROW_TIP","ARROW_TIP_OUTER","ARROW_TIP_INNER","TIP_BOTTOM","TIP_TOP","TIP_LEFT","TIP_RIGHT","POPUP_ROOT","POPUP_OPEN","POPUP_CLOSE","POPUP_LIB","HIDE_POPUP","POPUP_CONTAINER","Animation","_super","apply","effect","duration","delay","Tooltip","options","element","_this","call","mouseMoveEvent","mouseMoveTarget","containerElement","isBodyContainer","initialize","formatPosition","_a","_b","position","indexOf","tooltipPositionY","tooltipPositionX","renderArrow","setTipClass","tip","createElement","className","tipClass","appendChild","tooltipEle","renderPopup","elePos","mouseTrail","top","left","getTooltipPosition","classList","remove","popupObj","height","width","X","Y","enableRtl","open","openPopupHandler","bind","close","closePopupHandler","getScalingFactor","x","scalingFactors","elementsWithTransform","closest","contains","computedStyle","window","getComputedStyle","transformValue","getPropertyValue","matrixValues","map","parseFloat","style","display","parentWithZoomStyle","zoom","pos","getBoundingClientRect","offsetPos","calculateTooltipOffset","collisionPosition","calculateElementPosition","collisionLeft","collisionTop","collisionFlipFit","windowResize","reposition","findTarget","dataBind","needTemplateReposition","trigger","tooltipEventArgs","isReact","opensOn","clearTemplate","clear","xScalingFactor","yScalingFactor","tipWidth","tipHeight","tooltipEleWidth","tooltipEleHeight","arrowEle","tipAdjust","tipHeightAdjust","tipWidthAdjust","tooltipEleRect","arrowEleRect","Math","round","showTipPointer","clientHeight","clientWidth","offsetWidth","offsetHeight","offsetX","offsetY","updateTipPosition","selEle","removeList","adjustArrow","leftValue","topValue","tooltipWidth","tooltipHeight","arrowInnerELe","tipPosExclude","tipPointerPosition","renderContent","tooltipContent","cssClass","getAttribute","setAttribute","removeAttribute","content","innerHTML","HTMLElement","enableHtmlSanitizer","setProperties","sanitize","enableHtmlParse","tempFunction","tempArr","id","undefined","root","templateFunction","renderReactTemplates","renderCloseIcon","isSticky","tipClose","add","touchStartEvent","onStickyClose","existingCloseIcon","querySelector","addDescribedBy","describedby","push","join","trim","removeDescribedBy","index","splice","orgdescribedby","tapHoldHandler","evt","clearTimeout","autoCloseTimer","targetHover","originalEvent","touchEndHandler","e","setTimeout","targetClick","hideTooltip","animation","closeDelay","targetList","slice","ctrlId","document","_i","targetList_1","target_1","restoreElement","showTooltip","mouseMoveBeforeOpen","mouseMoveBeforeRemove","showAnimation","showTimer","hideTimer","openDelay","type","cancel","event","isInteracted","observeCallback","beforeRenderArgs","beforeRenderCallback","isHidden","attrs","role","styles","tooltipBeforeRender","tooltipAfterRender","stop","appendContainer","ctrlObj","container","body","tagName","isDevice","maxWidth","observedArgs","beforeOpenCallback","openAnimation_1","timingFunction","show","onMouseMove","wireMouseEvents","tooltip","viewContainerRef","checkCollision","horizontal","vertical","affectedPos","checkCollideTarget","offsetLeft","pageXOffset","scrollLeft","offsetTop","pageYOffset","scrollTop","newpos","collidedPosition","elePosVertical","elePosHorizontal","getOffSetPosition","elePosition","eleOffset","windowCollision","arrowleft","toString","positionString","newPos","offsetType","hideAnimation","targetElement","hide","isTooltipOpen","tooltipHide","popupHide","closeAnimation","unwireMouseEvents","destroy","tooltipHover","tooltipMouseOut","onMouseOut","enteredElement","relatedTarget","checkForTooltipElement","tooltipElementMouseOut","eventPageX","eventPageY","preventDefault","touches","pageX","pageY","colpos","keyDown","keyCode","touchEnd","scrollHandler","render","wireEvents","renderComplete","preRender","triggerList","getTriggerList","triggerList_1","wireFocusEvents","touchModule","tapHoldThreshold","tapHold","touchEndEvent","targetsList","targetList_2","unwireEvents","triggerList_2","unwireFocusEvents","targetList_3","triggerList_3","getModuleName","getPersistData","addOnPersist","onPropertyChanged","newProp","oldProp","keys","prop","refresh","target_2","currentTarget","currentTarget_1","DATEWRAPPER","LIBRARY","CONTROL","POPUPWRAPPER","INPUTWRAPPER","POPUP","INPUTCONTAINER","INPUTFOCUS","INPUTROOT","ERROR","ACTIVE","OVERFLOW","DATEICON","ICONS","OPENDURATION","OFFSETVALUE","SELECTED","FOCUSEDDATE","NONEDIT","containerAttr","DatePicker","isDateIconClicked","isAltKeyPressed","invalidValueString","checkPreviousValue","maskedDateValue","isAngular","preventChange","isIconClicked","isDynamicValueChanged","moduleName","isFocused","isBlur","isKeyAction","datepickerOptions","bindEvents","floatLabelType","calculateWidth","inputElement","inputWrapper","buttons","getElementsByClassName","disabled","enabled","setTimeZone","serverTimezoneOffset","offsetValue","value","clientTimeZoneDiff","Date","getTimezoneOffset","serverTimezoneDiff","timeZoneDiff","isDayLightSaving","getTime","updateInput","firstOffset","getFullYear","secondOffset","max","setAllowEdit","allowEdit","readonly","updateIconState","checkInvalidValue","enableMask","notify","module","createInput","updateHtmlAttributeToWrapper","placeholder","updateInputValue","previousElementValue","previousDate","inputValueCopy","ariaAttrs","l10nLocale","globalize","locale","l10n","getConstant","fullScreenMode","updatedCssClassValues","replace","isBindClearAction","bindClearAction","properties","showClearButton","setWidth","tabIndex","addAttributes","isDynamic","formatOptions","isCalendar","disabledDates","isNaN","checkValue","strictMode","validateDate","minMaxUpdates","minMaxUpdate","dateValue","dateString","tempFormat","formatString","dateTimeFormat","calendarMode","formatDate","format","skeleton","min","changedArgs","errorClass","checkStringValue","val","returnDate","formatDateTime","culture","getDatePattern","checkDateValue","parseDate","valueDate","valueString","invalid","extISOString","basicISOString","test","bindInputEvent","inputHandler","dateIconHandler","mouseUpHandler","inputFocusHandler","inputBlurHandler","keyupHandler","keydownHandler","inputChangeHandler","clearButton","resetHandler","formElement","resetFormHandler","defaultKeyConfigs","keyConfigs","keyboardModules","eventName","keyAction","inputKeyActionHandle","code","unBindEvents","restoreValue","currentDate","stopPropagation","bindClearEvent","clearedArgs","popupUpdate","changeEvent","keyupEvent","createEvent","initEvent","dispatchEvent","preventEventBubbling","interopAdaptor","invokeMethodAsync","setValue","blur","focus","htmlAttributes","updatedClassValues","setStyle","charAt","updateHtmlAttributeToElement","updateCssClass","newCssClass","oldCssClass","setCssClass","popupWrapper","calendarKeyActionHandle","action","children","selectionStart","selectionEnd","focusArguments","model","openOnFocus","isPopupClicked","strictModeUpdate","changeTrigger","activeElement","blurArguments","calendarKeyboardModules","calendarElement","firstElementChild","documentHandler","parentElement","depth","toLowerCase","generateTodayVal","focusOut","clickedView","currentView","start","end","length_1","headerTitleElement","defaultAction","keyActionHandle","setActiveDescendant","previousDateTime","querySelectorAll","targetdate","navigateTo","dateOptions","date","pattern","charPattern","len","modifiedValue","toLocaleUpperCase","setFullYear","setHours","getHours","getMinutes","getSeconds","getMilliseconds","createCalendar","modelHeader","modal","relateTo","targetType","zIndex","collision","iconRight","marginRight","swipe","CalendarSwipeHandler","TouchStartHandler","resetCalendar","preventArgs","setAriaAttributes","targetExitViewport","direction","swipeDirection","touchStart","navigateNext","navigatePrevious","setAriaDisabled","yearHeading","h2","daySpan","monthSpan","textContent","modelCloseIcon","modelCloseHandler","modelTodayButton","insertBefore","valueOf","navigatedEvent","navigatedArgs","selectCalendar","requiredModules","modules","args","member","prevent_1","outOfRange","mobilePopupWrapper","popup","appendTo","eventArgs","refreshPosition","openAnimation","setOverlayIndex","tableBodyElement","dlgOverlay","prevent_2","closeEventCallback","prevent","keyboardModule","outerHTML","focusIn","triggerEvent","view","removeAttributes","inputElementCopy","ensureInputAttribute","ngTag","insertAdjacentElement","attributes","cloneNode","validationAttribute","getDefaultKeyConfig","checkHtmlAttributes","hasAttribute","altUpArrow","altDownArrow","escape","enter","controlUp","controlDown","moveDown","moveUp","moveLeft","moveRight","select","home","pageUp","pageDown","shiftPageUp","shiftPageDown","controlHome","controlEnd","shiftTab","tab","nameAttribute","attribute","attr","checkFormat","skeletonString","dynamic","checkView","attributes_1","valueCopy","previousValCopy","renderDayCell","inputVal","dateIdString","isDisabledDate","setMilliseconds","setPlaceholder","setReadonly","setEnabled","setLocale","setEnableRtl","setClearButton","removeFloating","addFloating","day","month","year","second","dayOfTheWeek","monthsShortDot","monthsParse","monthsRegex","esDo","monthsShortRegex","monthsStrictRegex","monthsShortStrictRegex","longMonthsParse","shortMonthsParse","weekdaysParseExact","hours","w","ww","DataLabelSettings","color","right","bottom","size","fontStyle","fontWeight","fontFamily","MarkerSettings","ParetoOptions","Points","symbolLocations","regions","percentage","regionData","isSelect","marker","visible","isPointInRange","verticalError","verticalNegativeError","horizontalError","horizontalNegativeError","verticalPositiveError","horizontalPositiveError","Trendline","clipRect","setDataSource","series","chart","points","trendLineModule","initDataSource","visibleSeriesCount","ErrorBarCapSettings","ChartSegment","ErrorBarSettings","SeriesBase","rangeColorPoints","isAdvancedColor","currentViewData","seriesType","isRectTypeSeries","processJsonData","point","xName","Series","textMappingName","dataLabel","processInternalData","category","paretoSeriesModule","performCumulativeCalculation","xMin","xMax","yMin","yMax","sizeMax","getSeriesType","xAxis","valueType","dataPoint","pushCategoryData","pushData","setEmptyPoint","rangeColorsInterior","option","dateParser","intl","getDateParser","dateFormatter","getDateFormat","parse","parseJson","xValue","isBlazor","stockChart","drawType","chartAreaType","isArea","isRange","findSplinePoint","maximum","minimum","calculateBinValues","histogramValues","binWidth","rangeColorSettings","visibleSeries","interior","yValue","xData","getObjectValueByMappingString","enableComplexProperty","getObjectValue","high","low","volume","pointColorMapping","errorBar","errorBarColor","errorBarColorMapping","yName","text","tooltipMappingName","isAdvancedColorSupported","rangeColorName","colorName","colorValue","getPointFillColor","pointFill","rangeMap","colors","mappingName","data","findVisibility","isEmpty","mode","emptyPointSettings","yData","getAverage","yValues","yAxisMin","yAxis","yAxisMax","setXYMinMax","setHiloMinMax","filter","sort","a","seriesMinY","isLogAxis","isNegativeValue","rangePadding","pointX","shared","isIndexed","labels","indexLabels","previous","next","refreshDataManager","dataSource","query","dataManager","dataModule","getData","generateQuery","requiresCount","then","dataManagerSuccess","count","isRemoteData","allowServerDataBinding","localData","argsData","fill","findCurrentData","recordsCount","refreshChart","refreshTechnicalIndicator","trendlines","trendline","refreshBound","initialRender","stockChartDataManagerSuccess","parent","propName","defaultValue","isArray","isRectSeries","drawPoints","lowDrawPoints","delayedAnimation","refreshAxisLabel","item","_c","findSeriesCollection","column","row","isStack","seriesCollection","axes","rowAxis","rowSeries","_d","_e","axis","_f","_g","rectSeriesInChart","calculateStackedValue","isStacking100","columns","columnItem","rows","calculateStackingValues","startValues","endValues","stackingGroup","lastValue","lastPositive","lastNegative","frequencies","findFrequencies","groupingValues","visiblePoints","k","stackingSeies","stackedValues","seriesCollection_2","seriesCollection_1","j","pointsLength","toFixed","abs","isColumnBarType","startFromZero","findPercentageOfStacking","values","stackingSeies_1","seriesCollection_3","isStack100","renderSeries","createSeriesElements","requireInvertedAxis","errorBarModule","dataLabelModule","appendSeriesElement","seriesElements","enableCanvas","performAnimation","elementId","explodeValue","border","svgRenderer","renderer","markerHeight","markerWidth","markerMaxValue","radius","clipRectElement","redraw","columnIndex","rowIndex","transform","symbolElement","seriesElement","createGroup","checkTabindex","errorBarElement","textElement","dataLabelElements","shapeElement","hasChildNodes","enable","animateSeries","isStockChartRendered","doAnimation","doErrorBarAnimation","markerRender","doMarkerAnimation","info","isIE","doDataLabelAnimation","setPointColor","setBorderColor","arMa","processRelativeTime","gomLatn","standalone","isFormat","frCh","enAu","suffixes","1","5","8","70","80","2","7","20","50","3","4","100","6","9","10","30","60","90","tr","minutes","da","tlPh","ChartAnnotationSettings","LabelBorder","MultiLevelCategories","StripLineSettings","MultiLevelLabels","ScrollbarSettingsRange","ScrollbarSettings","eu","th","NiceInterval","calculateDateTimeNiceInterval","isChart","interval","oneDay","startDate","endDate","totalDays","actualIntervalType","intervalType","calculateNumericNiceInterval","getSkeleton","currentValue","previousValue","isIntervalInDecimal","findCustomFormats","labelFormat","translator","words","correctGrammaticalCase","wordKey","word","srCyrl","lastWeekDays","LineBase","chartModule","tempPoint","tempPoints","tempPoints2","xVisibleRange","visibleRange","yVisibleRange","seriesPoints","areaBounds","xTolerance","delta","yTolerance","prevXValue","prevYValue","xVal","yVal","seriesPoints_1","currentPoint","getLineDirection","firstPoint","secondPoint","isInverted","getPointLocation","startPoint","point1","point2","appendLinePath","previousDirection","htmlObject","drawPath","Int32Array","pathElement","renderMarker","doProgressiveAnimation","currentTime","path","strokeDashArray","pathLength","getTotalLength","visibility","animate","progress","timeStamp","storePointLocation","getLocation","withinYRange","GetStepLineDirection","previousPoint","stepLineType","command","centerX","getFirstLastVisiblePoint","first","last","points_1","getBorderDirection","coordinates","stackingAreaSeriesModule","stackingStepAreaSeriesModule","removeEmptyPointsBorder","borderDirection","startIndex","doLinearAnimation","childNodes","animated","elementHeight","elementWidth","xCenter","yCenter","ocLnc","mt","symbolMap","0","pluralForm","plurals","pluralize","u","string","f","str","arLy","preparse","postformat","commonXvalues","addEventListener","isDestroyed","cancelEvent","isPointer","on","mouseLeaveHandler","longPress","touchMoveEvent","mouseMoveHandler","control","lierIndex","isTouch","isSelected","mouseX","mouseY","chartAxisLayoutPanel","seriesClipRect","crosshair","startMove","fadeOutMode","removeTooltip","fadeOutDuration","findData","previousPoints","scaleX","scaleY","onPanning","disableTrackTooltip","markerMove","svgElement","getElement","isStockSvg","firstChild","isTooltip","tooltipDiv","getTooltipElement","getElementById","renderGroupedTooltip","renderSeriesTooltip","findHeader","header","parseTemplate","findShapes","enableMarker","currentPoints","shape","isFirst","dataEditingModule","isPointDragging","triggerTooltipRender","getTooltipText","isRemove","mergeXvalues","getClosestX","findMouseValue","textCollection","headerText","tooltipTemplate","template","textStyle","pointY","seriesIndex","seriesName","pointIndex","pointText","borderWidth","padding","chartTooltipSuccess","removeHighlight","removeText","formattedText","concat","location_1","getSymbolLocation","location","createTooltip","findMarkerHeight","availableSize","getTemplateText","pointData","getBoxLocation","getWaterfallRegion","getRangeArea","inverted","getFormat","formatPointValue","valueY","rect","valueX","lastData","dataCollection","stopAnimation","pointXValue","pointYValue","tempData","extraPoints","closestXValue","Number","MAX_VALUE","closetYValue","argument","enableTooltip","commonXValue","showNearestPoint","collection","dataCollection_1","data_1","triggerSharedTooltip","toolbarHeight","titleHeight","enablePeriodSelector","title","titleStyle","themeStyle","tooltipLabelFont","sharedTooltip","location_2","findSharedLocation","outliers","textValue","dataValue","RegExp","source","getPrototypeOf","isXPoint","isYPoint","customLabelFormat","getNumberFormat","useGrouping","useGroupingSeparator","tooltipFormat","getIndicatorTooltipFormat","textX","toolTip","removeHighlightedMarker","fadeOut","data_2","num","forms","relativeTimeWithPlural","be","ka","$0","$1","$2","ForeignKey","serviceLocator","initForeignKeyColumns","getForeignKeyData","generateQueryFormData","eventfPromise","state","getStateEventArgument","def","deff","getDataModule","requestType","foreignKeyDataState","isDataChanged","setForeignKeyDataState","isPending","resolver","resolve","promise","setColumnData","setForeignKeyData","foreignColumns","getForeignKeyColumns","allPromise","_loop_1","isComplex","this_1","genarateColumnQuery","genarateQuery","params","ready","offline","executeQuery","Promise","all","responses","columnData","editType","edit","fields","foreignKeyField","field","foreignKeyValue","catch","log","reject","predicate","fromData","needQuery","gObj","predicates","allowPaging","enableVirtualization","allowGrouping","groupSettings","records","executeLocal","filteredValue","distinct","getDay","operator","matchCase","where","or","queryColumn","isFiltered","isTrue","filterQuery","searchSettings","sSettings","adaptor","searchQuery","search","ignoreCase","filterColumn","filterSettings","fColumn","uid","destroyEvent","off","ko","token","isUpper","numberMap","ku","bs","units","translateSeconds","translateSingular","special","lt","ARR_LITERAL_CODES","Int16Array","ARR_LITERAL_LENGTHS","Uint8Array","ARR_DISTANCE_CODES","ARR_DISTANCE_LENGTHS","CompressedStreamWriter","noWrap","pendingBuffer","pendingBufLength","pendingBufCache","pendingBufBitsInCache","bufferPosition","extraBits","currentHash","matchStart","matchLength","matchPrevAvail","blockStart","stringStart","lookAhead","totalBytesIn","inputOffset","inputEnd","windowSize","windowMask","hashSize","hashMask","hashShift","floor","maxDist","checkSum","isHuffmanTreeInitiated","initHuffmanTree","treeLiteral","CompressorHuffmanTree","treeDistances","treeCodeLengths","arrDistances","Uint16Array","arrLiterals","stream","dataWindow","hashHead","hashPrevious","writeZLibHeader","get","enumerable","configurable","compressedString","String","fromCharCode","write","Error","encode","getBytes","inputBuffer","ChecksumCalculator","checksumUpdate","pendingBufferFlush","compressData","headerDate","pendingBufferWriteShortBytes","finish","success","fillWindow","canFlush","compressSlow","flush","lookAheadCompleted","slideWindow","prevMatch","prevLen","discardMatch","matchPreviousBest","matchPreviousAvailable","huffmanIsFull","insertString","findLongestMatch","huffmanTallyLit","huffmanTallyDist","huffmanFlushBlock","lastBlock","more","set","subarray","updateHash","hash","curMatch","chainLen","niceLen","scan","bestEnd","bestLength","limit","stringEnd","scanEnd1","scanEnd","literal","codeFrequencies","dist","lc","huffmanLengthCode","dc","huffmanDistanceCode","stored","storedOffset","storedLength","buildTree","calculateBLFreq","blTreeCodes","codeLengths","huffCodeLengthOrders","opt_len","getEncodedLength","static_len","huffmanFlushStoredBlock","pendingBufferWriteBits","setStaticCodes","huffmanCompressBlock","huffmanReset","huffmanSendAllTrees","pendingBufferAlignToByte","pendingBufferWriteShort","pendingBufferWriteByteBlock","distance","buildCodes","treeLength","rank","writeTree","reset","literalLen","writeCodeToStream","bits","uint","Uint32Array","pendingBufferFlushBits","isClose","array","bitReverse","writer","elementCount","minCodes","maxLength","codeMinCount","codeFrequency","lengthCount","codeCount","codeLength","codes","lengths","temp","lengthTemp","nextCode","bitsCount","reverseBits","blTree","maxCount","minCount","curLen","nextLen","maxRepeatCount","minRepeatCount","currentRepeatCount","currentCodeLength","codesCount","arrTree","freq","pPos","leafsCount","nodesCount","child","node","iIndex","constructHuffmanTree","buildLength","lastVal","minDepth","numNodes","numLeafs","overflow","calculateOptimalCodeLength","iIncreasableLength","recreateTree","nodePtr","childPtr","childIndex","bitLength","checksum","buffer","checksum_uint","s1","s2","checkSumBitOffset","steps","checksumIterationCount","checksumBase","vi","me","CustomWebApiAdaptor","_WebApiAdaptor","_classCallCheck","_callSuper","_inherits","_createClass","dm","xhttp","p3","originalFail","onFailure","err","status","authToken","logger","apis","unprotectedApi","put","Token","resp","rules","getPermissions","checkUIPermissions","navigateToLogin","pathname","_superPropGet","WebApiAdaptor","SyncHelper","getDataManager","relativePath","queryString","DataManager","url","urls","apiBaseUrl","crossDomain","headers","Authorization","af","Data","dataState","group","initDataManager","addRows","reorderRows","removeRows","crudActions","refreshFilteredCols","json","toIndex","fromIndex","isQueryInvokedFromData","isVue","skipPage","isAutoCompleteCall","getQuery","clone","columnQueryMode","getColumns","isPrimaryKey","selectQueryFields","aggregateQuery","sortQuery","virtualGroupPageQuery","pageQuery","groupQuery","aggregates","cols","types","aggregate","fName","queries","enableInfiniteScrolling","pageSettings","currentPage","pageCount","pageSize","infiniteScrollModule","page","pagerModule","pagerObj","isAllPage","isManualRefresh","enableLazyLoading","lazyLoad","getColumnByField","columnName","isGrpFmt","enableGroupByFormat","formatGroupColumn","allowSorting","sortSettings","sortGrp","col","setSortDirection","fn","sortComparer","isRemote","isForeignColumn","sortByForeignKey","sortBy","getSortDirection","fcolumn","isForeignKey","getSearchColumnFieldNames","predicateList","needForeignKeySearch","some","fGeneratePredicate","ignoreAccent","predList","skipFoerign","foreignColEmpty","actualFilter","foreignColumn","allowFiltering","colType","foreignCols","defaultFltrCols","columns_1","gridColumn","getColumnByUid","grabColumnByFieldFromAllCols","excelPredicate","getPredicate","foreignCols_1","column_1","grabColumnByUidFromAllCols","and","fPredicate","getKey","foreignKeyData","getPrimaryKeyFieldNames","eventPromise","crud","fromTable","changes","addedRecords","deletedRecords","changedRecords","saveChanges","insert","deferred_1","getFormatter","formatVal","toView","pr","update","previousData","original","endEdit","setState","getState","getForeignKeyDataState","adaptr","processQuery","JSON","pvtData","dataArgs","disablePageWiseAggregates","editArgs_1","cancelEdit","colFieldNames","columns_2","allowSearching","uz","OTHERMONTH","OTHERDECADE","HEADER","CONTENTTABLE","YEAR","MONTH","DECADE","PREVICON","NEXTICON","PREVSPAN","NEXTSPAN","ICONCONTAINER","DISABLED","OVERLAY","WEEKEND","WEEKNUMBER","FOCUSEDCELL","OTHERMONTHROW","TODAY","TITLE","LINK","CELL","WEEKHEADER","ZOOMIN","FOOTER","BTN","FLAT","CSS","PRIMARY","DAYHEADERLONG","dayMilliSeconds","minutesMilliSeconds","CalendarBase","isDateSelected","isTodayClicked","previousDates","rangeValidation","calendarEleCopy","setSeconds","firstDayOfWeek","getFirstDayOfWeek","todayDisabled","todayDate","createHeader","createContent","spacebar","altRightArrow","altLeftArrow","popupElement","ariaPrevAttrs","ariaNextAttrs","ariaTitleAttrs","tabIndexAttr","headerElement","iconContainer","previousIcon","selector","isCenterRipple","nextIcon","adjustLongHeaderSize","contentElement","table","createContentHeader","createContentBody","showTodayButton","createContentFooter","addContentFocus","removeContentFocus","focusedDate","selectedDate","getCultureValues","cldrObj","culShortNames","dayFormat","dayHeaderFormat","getCultureObjects","obj","toCapitalize","toUpperCase","daysCount","html","tableHeadElement","weekNumber","shortNames","shiftArray","days","renderYears","renderDecades","renderMonths","updateFooter","todayElement","l10","today","footer","todayButtonClick","ref","keyConfig","navigateTitle","dateWireEvents","serverModuleName","isCustomDate","getViewNumber","renderDayCellArgs","multiSelection","depthValue","levelRestrict","keyboardNavigate","selectDate","contentClick","firstDay","addMonths","addYears","isMonthYearRange","addDay","isMinMaxRange","navigatePreviousHandler","navigateNextHandler","navigateHandler","triggerNavigate","minMaxDate","localDate","minDate","maxDate","tdEles","numCells","renderDays","islamicModule","islamicRenderDays","renderTemplate","islamicRenderTemplate","isTodayDate","cellsCount","getDate","timezone","currentMonth","getMonth","titleUpdate","setStartDate","weekEle","weekAnchor","numberOfDays","weekRule","finalDate","getWeek","dateFormatOptions","tdEle","dayCell","dayLink","isDisabled","isOutOfRange","renderDayCellEvent","argsDate","localDateString","tempDateString","otherMnthBool","disabledCls","clickHandler","getDateVal","tempValue","innerText","copyValues","type_1","formatOptions_1","localDateString_1","tempDateString_1","updateFocus","otherMonth","tableElement","removeTableHeadElement","valueUtil","curDate","mon","yr","curYrs","minYr","minMonth","maxYr","maxMonth","setMonth","setDate","localMonth","yearCell","localYr","startYr","endYr","startFullYr","endFullYr","startHdrYr","endHdrYr","startYear","rowIterator","lastDate","timeOffset","findLastDay","elements","classNm","trEle","weekNumCell","numberCell","otherMonthCell","iconHandler","islamicIconHandler","setAriaActiveDescendant","clickEventEmitter","eve","getIdValue","islamicPreviousHeader","islamicDate","getIslamicDate","toGregorian","switchView","keyEntity","validateValues","skipIndex","tempValueString","minFormatOption","minStringValue","minString","maxFormatOption","maxStringValue","maxString","setValueUpdate","dayFormatOptions","monthFormatOptions","focusedEle","selectedEle","previousIconHandler","compareMonth","nextIconHandler","compareYear","compareDecade","todayButtonEvent","stringVal","islamicPrevious","islamicNext","ld","gregorianFormat","islamicFormat","mainVal","ceil","time","tzOffset","tzOffsetDiff","setTime","getMaxDays","setDateDecade","setDateYear","checkPresentDate","tempElement","selectedElement","dates","checkPrevious","compare","modifier","findNextTD","rangeValue","tmpDate","inValue","toUTCString","toLocaleString","timeZone","Calendar","isMultiSelection","tempValues","copyDate","previousValues","setEnable","setClass","form","formResetHandler","setMinutes","changeHandler","triggerChange","isMultiSelect","tempDays","islamicRenderYears","islamicRenderDecade","storeView","tempDate","addDate","tempDates","removeDate","setTodayDate","NaN","axisPadding","CartesianAxisLayoutPanel","measureAxis","chartAreaWidth","chartArea","crossAt","initialClipRect","leftSize","rightSize","topSize","bottomSize","measureRowAxis","measureColumnAxis","delayRedraw","calculateAxisSize","calculateFixedChartArea","refreshAxis","margin","legendSettings","legendModule","legendBounds","farSizes","calculateRowSize","nearSizes","insideNearSizes","insideFarSizes","arrangeAxis","measureDefinition","computedHeight","calculateColumnSize","computedWidth","definition","ele","scrollbarSettings","scrollBarHeight","scrollBarModule","zoomModule","zoomSettings","enableScrollbar","enableScrollbarOnZooming","isZoomed","zoomFactor","zoomPosition","getModule","baseModule","calculateRangeAndInterval","computeSize","axisOffset","nearCount","farCount","len_1","plotOffset","len_2","span","computedTop","plotOffsetTop","getAxisOffsetValue","plotOffsetBottom","isAxisOpposedPosition","labelPosition","orientation","len_3","len_4","computedLeft","plotOffsetLeft","plotOffsetRight","measure","actualIndex","axisCollections","verticalAxes","getActualRow","pushAxis","horizontalAxes","getActualColumn","isRTLEnabled","setIsInversedAndOpposedPosition","position1","position2","rangeOffset","crossesAt","crossesInAxis","crossInAxis","updateCrossAt","primaryXAxis","primaryYAxis","logBase","axisCollection","actualLength","rowTop","remainingHeight","columnLeft","remainingWidth","renderAxes","outsideElement","isInside","axisElement","axisLineElement","axisVisibility","yAxisName","xAxisName","paretoOptions","showAxis","findAxisPosition","updateCrossValue","internalVisibility","lineStyle","drawAxisLine","updatedRect","majorGridLines","majorTickLines","minorTickLines","minorGridLines","drawXAxisGridLine","tickPosition","drawXAxisLabels","placeNextToAxisLine","drawXAxisBorder","drawXAxisTitle","drawYAxisGridLine","drawYAxisLabels","drawYAxisBorder","drawYAxisTitle","renderScrollbar","drawBottomLine","svgObject","zoomingScrollBar","isScrollUI","scrollElement","isRow","x1","x2","y1","y2","definitionName","optionsLine","drawLine","plotX","plotY","plotBottom","plotTop","plotLeft","plotRight","dashArray","axisLine","tempInterval","minorGridDirection","isCategoryAxis","majorGrid","majorTick","isOpposed","tickSize","axisLineSize","ticksbwtLabel","labelPlacement","isTickInside","ticks","visibleLabels","chartThemeStyle","isBorder","renderGridLine","majorGridLine","majorTickLine","minorTicksPerInterval","renderMinorGridOnZooming","drawAxisMinorLine","minorGridLine","minorTickLine","endIndex","label","elementSize","isAxisBreakLabel","RotatedWidth","labelSpace","labelPadding","isLabelInside","tickSpace","angle","isVerticalAngle","textHeight","textPadding","maxLineWidth","intervalLength","labelHeight","yAxisLabelX","labelElement","pixel","isInverse","isAxisInverse","previousEnd","isLabelOnAxisLineLeft","sizeWidth","breakLabelSizeWidth","breakLabelSize","LabelMaxWidth","breakLabelMaxWidth","cos","PI","originalText","labelIntersectAction","isInversed","opposedPosition","labelStyle","textAlignment","edgeLabelPlacement","previousYValue","currentYValue","axisLabelFont","createZoomingLabel","getAxisLabelXvalue","textWidth","anchor","lineBreakAlignment","startY","gap","dateTimeInterval","endY","maxLabelSize","labelBorder","endX","createAxisBorderElement","multiLevelLabels","multiLevelLabelModule","renderYAxisMultiLevelLabels","isRotated","labelRotation","titleRotation","titlePadding","multiLevelLabelHeight","titleSize","titleCollection","axisTitleFont","minorDirection","labelIndex","isFirstLabel","logStart","logEnd","coor","range","logInterval","logPosition","ticksX","ticksY","minorGird","minorTick","pow","findLogNumeric","labelWidth","isLeft","islabelInside","isHorizontalAngle","newPoints","isRotatedLabelIntersect","textPoints","rotatedLabelSize","isLabelUnderAxisLine","isEndAnchor","paddingForBreakLabel","getAnchor","isRtlEnabled","i_1","breakLabelWidth","getLabelText","xValue2","rect_1","xAdjustment","yAdjustment","rectCoordinates","getRectanglePoints","rectCenterX","rectCenterY","index_1","rotateAngle","textRect","textRectCoordinates","rectPoints","newRect","interSectPoint","calculateIntersection","rectPoint1","rectPoint2","trimValue","sqrt","p1","p2","p4","c2x","c3x","c2y","c3y","u1","u4","px","py","point3","point4","findAxisLabel","axisRect","startX","length_2","renderXAxisMultiLevelLabels","borderElement","pointerEvents","enableTrim","gridDirection","gridModel","gridId","gridIndex","themeColor","findParentNode","parentNode","zoomElement","replaceChild","MarkerExplode","removeEventListener","highlightMode","explodeSeries","chartSeries","tooltipModule","isPointMouseDown","markerExplode","allowHighlight","drawTrackBall","animationDuration","maxPointCount","svg","seriesMarker","highlightModule","generateStyle","selectionModule","selectionMode","symbolId","borderColor","markerShadow","g","markerElement","trackElement","createSvg","cssText","opacity","symbol","imageUrl","selectionId","seletionElem","endAnimate","rectElements","trackballAnimate","delays","durations","isLabel","centerY","clipX","clipY","point_1","trackballElements","markerShapes","Marker","previousLocation","previousPath","circlePath","shapeOption","isBoxPlot","isFilled","markerFill","markerBorder","markerOpacity","markerShape","imageURL","markerClipRect","getRangeLowPoint","region","markerElements","incFactor","lowPoint","TechnicalIndicator","targetSeries","RangeColorSetting","CrosshairSettings","ZoomSettings","Chart","rotatedDataLabelCollections","isScrolling","checkResize","clickCount","singleClickTimer","isCrosshair","chartid","isLegendClicked","previousTargetId","currentPointIndex","currentSeriesIndex","currentLegendIndex","previousPageX","previousPageY","allowPan","mergePersistChartData","localStorage","getItem","dataObj","isProtectedOnChange","keys_1","isIdHasSpecialCharacter","regex","numberRegex","childElementId","blazor","markerIndex","unWireEvents","initPrivateVariable","setCulture","dragY","refreshDefinition","description","elementid","svgId","loadEventData","theme","cartesianChartRendering","applyZoomkit","beforeRenderData","setTheme","createChartSvg","calculateAreaType","calculateVisibleSeries","initTechnicalIndicators","initTrendLines","calculateVisibleAxis","processData","getLocalizedLabel","localeObject","getLegendOptions","calculateStackValues","calculateBounds","rangeFound","enableSelector","renderElements","removeSelection","isCalculateStacking","rectCount","filterArray","calculateDragSelectedElements","renderBorder","renderTitle","renderAreaBorder","renderSeriesElements","renderLegend","performSelection","setSecondaryElementPosition","renderAnnotation","yAxisElements","stripLineModule","renderStripLine","legendCollections","calTotalPage","bounds","canvasClip","canvasRestore","chartObject","mainObject","svgRect","initializeModuleElements","dataLabelCollections","indicators","indicatorElements","hasTrendlines","trendLineElements","isTrendline","tooltipdiv","initializeIndicator","initializeTrendLine","appendElementsAfterSeries","sourceIndex","renderCanvasSeries","seriesSvg","indicator","createIndicatorElements","getTrendLineElements","childElementCount","calculateStockEvents","enablePan","performedUI","showToolbar","applyZoomToolkit","annotationModule","renderAnnotations","selectedDataIndexes","invokeSelection","invokeHighlight","redrawSelection","check","prevPointCount","initializeDataModule","techIndicator","subTitleHeight","elementSpacing","subTitleCollection","chartTitleFont","subTitle","subTitleStyle","chartSubTitleFont","marginTotal","stockLegendModule","calculateLegendBounds","print","exportChart","trendIndex","trendLine","initSeriesCollection","isTransposed","polarSeriesModule","radarSeriesModule","paretoAxes","isPanning","isAxisZoomed","scrollSettingEnabled","initAxis","injectTo","isSeries","targetIndicator","palettes","zOrder","isSecondaryAxis","initSeries","positionY","positionX","rotation","alignment","subtitleSize","borderOptions","cornerRadius","background","drawRectangle","renderSubTitle","titleWidth","titleText","subTitleElementSize","reduce","subTitleOptions","backGroundImage","backgroundImage","fillColor","image","drawImage","previousRect","areaBorder","addSeries","removeSeries","clearSeries","addAxes","axisCollection_1","desiredIntervals","removeAxis","highlightElement","removeSvg","startEvent","moveEvent","stopEvent","chartOnMouseDown","mouseMove","mouseEnd","chartOnMouseClick","chartOnDoubleClick","chartRightClick","mouseLeave","chartKeyDown","documentKeyHandler","chartKeyUp","resizeBound","touchObject","chartResize","longPressBound","crosshairModule","which","pointerType","zooming","disableScroll","enableSelectionZooming","enablePinchZooming","touchAction","msTouchAction","msContentZooming","msUserSelect","webkitUserSelect","isOrientation","changedTouches","setMouseXY","export","fileName","exportModule","afterExport","getDataUrl","arg","currentSize","previousSize","beforeResizeArgs","cancelResizedEvent","resizeTo","touchArg","clientX","clientY","chartOnMouseMove","chartOnMouseLeave","isChartDrag","actionKey","removeLegendHighlightStyles","ctrlKey","enableDeferredZooming","enableMouseWheelZooming","chartKeyboardNavigations","groupElement","markerGroup","targetId","titleElement","legendElement","pagingElement","previousElement","setTabIndex","focusChild","legendElement_1","getActualIndex","currentLegend","seriesIndexes","currentElement","totalLength","altKey","pointRegion","highlightChart","completeSelection","legendID","legendItemsId","legendSelection","click","calculateSelectedElements","toolkit","zoomInOutCalculation","performZoomRedraw","yArrowPadding","xArrowPadding","doPan","timeInterval","pointDoubleClick","observers","pointClick","triggerPointEvent","axisLabelClick","triggerAxisLabelClickEvent","clickEvt","axisIndex","currentAxis","labelID","pointMove","titleTooltip","axisTooltip","pointMouseMove","isTitleOrLegendEnabled","texts","categories","mouseDownX","previousMouseMoveX","mouseDownY","previousMouseMoveY","isDoubleTap","threshold","pointMouseDown","chartOnMouseUp","pointMouseUp","setLocaleConstants","defaultLocalConstants","setAnnotationValue","annotationIndex","annotation","annotations","processAnnotation","ZoomIn","Zoom","ZoomOut","Pan","Reset","ResetZoom","tabColor","enableAnnotation","errorBarVisible","isPointDrag","dataLabelEnable","isLegend","dragSettings","currentModule","findIndicatorModules","findTrendLineModules","findAxisModule","enableExport","allowExport","enableHighlight","datetimeEnabled","categoryEnabled","logarithmicEnabled","striplineEnabled","dateTimeCategoryEnabled","multiLevelEnabled","axisCollections_1","findStriplineVisibility","stripLines","macdEnable","bandEnable","isLine","isSpline","markerEnable","striplines","striplines_1","stripline","clearRect","removeLength","pinchTarget","containerCollection","removeChild","definitions","definitions_1","axisChange","getVisibleSeries","visibleSeries_1","refreshLiveData","removeStyles","mousemove","initMouseEvent","isPoint","showCrosshair","hideCrosshair","removeCrosshair","refreshBounds","crosshairTooltip","textOverflow","seriesRefresh","blazorProp","isClosed","boxPlotMode","showMean","binInterval","currentMode","styleId","highlightDataIndexes","highlightSearch","ignoreRegex","replaceQuery","findTextNode","nodeType","nodeValue","revertHighlightSearch","parent_1","createTextNode","icon","AutoComplete","_this_1","searchList","getLocaleName","getNgDirective","filterType","dataType","typeOfData","typeof","virtualGroupDataSource","mapping","suggestionCount","queryElements","take","takeValue","getTakeValue","skip","virtualItemStartIndex","searchLists","isTyped","isDataFetched","isSelectCustom","checkAndResetCache","list","renderList","filterInput","beforePopupOpen","resetList","activeIndex","preventDefaultAction","updateData","filterAction","isNoDataElement","minLength","isFiltering","isPreventScrollAction","previousStartIndex","virtualListInfo","getTransformValues","virualElement","GetVirtualTrackHeight","totalItemCount","getFilteringSkeletonCount","hidePopup","clearAll","property","onActionComplete","ulElement","isUpdated","fixedHeaderElement","li","postBackAction","autofill","liCollections","items","listData","searchItem","setAutoFill","setSelection","isValidLI","getFormattedValue","getIndexByValue","setHoverList","selectedLI","setScrollPosition","isPopupOpen","preventAutoFill","isKeyNavigate","listOption","fieldsSettings","itemCreated","highlight","itemTemplate","isHtmlElement","charCodeAt","itemCreated_1","isEditTextBox","isPopupButton","showPopupButton","isSelectFocusItem","setInputValue","oldValue","typedString","allowCustom","setOldText","setOldValue","checkFields_1_1","listLength_1","getItems","_this_2","addItem","updateValues","showPopup","refreshPopup","viewPortInfo","previousEndIndex","setUpdateInitial","button","appendSpan","dropDownClick","atcProps","getPropObject","newProperty","oldProperty","renderHightSearch","isHighlight","iconCss","groupBy","rowCell","gridHeader","gridContent","gridFooter","headerContent","movableContent","movableHeader","frozenContent","frozenHeader","gridChkBox","editedRow","addedRow","leftRight","frozenRight","frozenLeft","dataColIndex","ariaColIndex","dataRowIndex","ariaRowIndex","tbody","colGroup","change","beforeOpen","initialFrozenColumnIndex","enCa","enGb","LABEL","RIPPLE","WRAPPER","ATTRIBUTES","RadioButton","RadioButton_1","checked","updateChange","instance","radioGrp","getRadioGroup","angularValue","radioWrap","wrapper","forEach","refreshing","focusHandler","focusOutHandler","getLabel","getSelectedValue","getWrapper","nextElementSibling","initialCheckedValue","initWrapper","updateHtmlAttribute","setDisabled","rippleSpan","for","setText","keyUpHandler","labelMouseDownHandler","labelMouseLeaveHandler","rippleElem","labelMouseUpHandler","wrap","formControlName","textLabel","rippleLabel","getElementsByTagName","relativeTimeMr","mr","Row","innerPadding","findTickSize","findLabelSize","Column","MajorGridLines","MinorGridLines","AxisLine","MajorTickLines","MinorTickLines","CrosshairTooltip","Axis","axisBottomLine","intervalDivs","crossAxis","diff","isHorizontal","legendLabelFont","labelSize","findDifference","calculateVisibleRangeOnZooming","baseRange","actualRange","doubleRange","triggerRangeRender","getRangePadding","getMaxLabelWidth","isAxisLabelBreak","isIntersect","rotatedLabel","width1","findMultiRows","result1","height_1","getMultilevelLabelsHeight","currentX","currentLabel","isBreakLabels","width2","isMultiRows","store","isPolar","VisibleLabels","ne","zhMo","hm","12","13","40","tg","disableHtmlEncode","allowResizing","allowReordering","showColumnMenu","allowEditing","showInColumnChooser","autoFit","sortDirection","getEditTemplate","editTemplateFn","getFilterTemplate","filterTemplateFn","valueFormatter","setFormatter","getFormatFunction","setParser","getParserFunction","toJSON","commands","textAlign","commandsTemplate","templateFn","headerTemplate","headerTemplateFn","fltrTemplateFn","editTemplate","filterTemplate","ddEditedData","a_1","xObj","yObj","z","fnDescending","fnAscending","getFreezeTableName","freezeTable","refreshReactColumnTemplateByUid","refreshReactHeaderTemplateByUid","formatFn","getParser","parserFn","getColumnTemplate","getHeaderTemplate","getFilterItemTemplate","getDomSetter","GridColumn","CommandColumnModel","StackedColumn","Scroll","oneTimeReady","widthService","uiupdate","setWidthToColumns","toolbarModule","toolbar","tlbrElement","tlbrLeftElement","tlbrCenterElement","tlbrRightElement","tlbrItems","tlbrLeftWidth","tlbrCenterWidth","tlbrRightWidth","tlbrItemsWidth","tlbrWidth","enableAdaptiveUI","refreshOverflow","setHeight","mHdrHeight","getContent","enableColumnVirtualization","isFrozenGrid","getScrollBarWidth","frozenRows","getHeaderContent","getRowHeight","isInitialLoad","loadingIndicator","indicatorType","ensureOverflow","setPadding","scrollWidth","getThreshold","cssProps","getCssProperties","removePadding","rtl","hDiv","footerDiv","getFooterContent","getSiblingsHeight","appName","setScrollLeft","setPageXY","onTouchScroll","mScrollBar","onCustomScrollbarScroll","userAgent","contentScrollHandler","headerScrollHandler","onContentScroll","scrollTarget","isHeader","isPreventScrollEvent","errorFreeze","errorFixed","getVisibleFrozenLeftCount","widthVal","getVisibleFrozenRightCount","isEdit","isDown","scrollDown","isFooter","cont","hdr","isFrozen","pageXY","getPointXY","mHdr","mCont","scrollBar","getScrollbleParent","scrollingElement","overflowY","defaultView","scrollHeight","addStickyListener","isAdd","eventElement","makeStickyHeader","resizeFrozenRowBorder","div","frzCols","enableStickyHeader","sLeft","sHeight","getContentTable","setLastRowCell","css","contentRect","getClientRects","headerEle","toolbarEle","groupHeaderEle","parentTop","top_1","colMenuEle","elemTop","showDropArea","setSticky","ccDlg","topStyle","gridElement","cs","SummaryModelGenerator","footerTemplate","groupFooterTemplate","groupCaptionTemplate","columnSelector","detailTemplate","childGrid","isRowDragable","generateRows","buildSummaryData","getGeneratedRow","level","parentUid","summaryRow","raw","tmp","indents","getIndentByLevel","isDetailGridAlone","indentLength","getIndentCount","allowRowDragAndDrop","getGeneratedCell","getCellType","DetailFooterIntent","Indent","class","cells","isAggregateRow","cell","isDataCell","cellType","indent","sColumn","scolumn","opt","dummy","summaryRows","single","setTemplate","helper","disp","Summary","GroupSummaryModelGenerator","v","indx","GroupSummary","CaptionSummaryModelGenerator","initVal","prev","cur","CaptionSummary","ta","kn","_vm","_h","$createElement","_self","staticClass","staticStyle","commandClick","wrapSettings","gridQuery","toolbarClick","excelExportComplete","editSettings","actionComplete","actionBegin","actionFailure","filterOptions","customiseCell","percentageRules","numericParams","dateColumns","requiredRules","tradebalePeriodParams","tradebalePeriods","percentageParams","referenceTypeParams","referenceTypes","checkboxParams","multilineParams","alertDlgButtons","animationSettings","showCloseIcon","dialogOpen","dialogClose","alertWidth","draggable","_v","_s","alertType","triggerDate","alertText","client","country","pricingAreaName","utility","product","company","contractName","contractId","watchPeriod","triggerPrice","contractUnits","marketPrice","textRender","staticRenderFns","component","Toolkit","iconRectOverFill","iconRectSelectionFill","zoomCompleteEvtCollection","createPanButton","childElement","toolkitSelectionColor","toolkitFill","elementOpacity","panElements","toolkitIconRect","pan","createZoomButton","rectColor","toolkitIconRectSelectionFill","zoomElements","selectedID","createZoomInButton","polygonDirection","drawPolygon","zoomInElements","enableZoomButton","zoomIn","createZoomOutButton","zoomOutElements","zoomOut","createResetButton","process","icon2","icon3","hoveredID","toolkitIconRectOverFill","iconColor","zoomingEventArgs","toolkitElements","zoomedAxisCollection","previousZoomFactor","previousZoomPosition","currentZoomFactor","currentZoomPosition","previousVisibleRange","currentVisibleRange","axisName","axisRange","setDefferedZoom","touchMoveList","touchStartList","applySelection","scale","cumulative","zoomingEventArgs_1","zoomCancel","browserName","wheelEvent","zoomingRect","zoomAxes","zoomkitOpacity","isIOS","isIos","isIos7","renderZooming","calculateZoomAxesRange","drawZoomingRectangle","startLocation","endLocation","selectionRectFill","selectionRectStroke","xDifference","yDifference","currentScale","performDefferedZoom","redrawOnZooming","translateX","translateY","setTransform","doZoom","layout","zoomRect","zoomedAxisCollections","onZoomingEventArg","isRedraw","isMouseUp","zoomCompleteCollection","performMouseWheelZooming","origin","onZoomingEventArgs","performPinchZooming","elementOffset","touchDown","touchMove","touch0StartX","touch0StartY","touch0EndX","touch0EndY","touch1StartX","touch1StartY","touch1EndX","touch1EndY","pinchRect","translateXValue","translateYValue","calculatePinchZoomFactor","selectionMin","selectionMax","rangeMin","rangeMax","axisTrans","currentZF","currentZP","actualMin","actualDelta","transX","transY","isPinch","xAxisLoc","yAxisLoc","showZoomingToolkit","toolboxItems","toolbarItems","spacing","iconSize","xPosition","shadowElement","defElement","createDefs","zoomFillColor","currentItem","outerElement","panIcon","zoomDiv","zoomheight","zoomToolkitMove","zoomToolkitLeave","showToolkit","zoomCompleteEventCollection","zoomCompleteEvent","chartMouseWheel","mouseDownHandler","mouseCancelHandler","addTouchPointer","touchList","pointerId","ButtonsDirective","inject","custom","default","slots","$slots","updated","methods","getTag","ButtonsPlugin","install","Vue","DialogButtonDirective","DialogButtonPlugin","modelProps","testProp","props","watch","emitProbs","modelProps_1","props_1","DialogComponent","mixins","emits","provide","ej2Instances","propKeys","models","hasChildDirective","hasInjectedModules","tagMapper","tagNameMapper","isVue3","templateCollection","created","_trigger","bindProperties","_setProperties","templateNames","templateNames_1","tempName","elementCollection","elementCollection_1","__vue__","$destroy","muteOnChange","referModels","vueInstance","$emit","eventProp","successHandler","propKey","$props","isLazyUpdate","getButtons","getDimension","sanitizeHelper","isFullScreen","DialogPlugin","arKw","Worksheets","Worksheet","isSummaryRowBelow","showGridLines","HyperLink","Grouping","FreezePane","MergeCell","MergeCells","mergeCell","inserted","mCell","isIntersecting","intersectingCell","Width","Height","base","CellStyle","numFmtId","backColor","fontName","fontSize","fontColor","italic","bold","underline","strikeThrough","wrapText","hAlign","vAlign","numberFormat","borders","Borders","isGlobalStyle","Font","sz","strike","CellXfs","Alignment","CellStyleXfs","CellStyles","xfId","NumFmt","formatCode","Border","mLine","mColor","Rows","Image","Cell","Cells","Utils","bitConverterToInt32","bitConverterToInt16","bitConverterToUInt32","bitConverterToUInt16","bitConverterUintToInt32","bitConverterInt32ToUint","bitConverterInt32ToInt16","byteToString","byteIntToString","arrayCopy","destination","destinationIndex","dataToCopy","mergeArray","arrayOne","arrayTwo","mergedArray","encodedString","chr1","chr2","chr3","encode1","encode2","encode3","encode4","keyStr","resultIndex","DecompressorHuffmanTree","init","m_LengthTree","m_DistanceTree","prepareData","blCount","treeSize","MAX_BITLEN","treeFromData","tree","pointer","increment","revcode","subTree","treeLen","m_Tree","unpackSymbol","lookahead","peekBits","skipBits","subtree","bitlen","availableBits","ChecksumUpdate","checkSumUInt","DEF_CHECKSUM_BIT_OFFSET","DEF_CHECKSUM_ITERATIONSCOUNT","DEF_CHECKSUM_BASE","ChecksumGenerate","CompressedStreamReader","bNoWrap","defaultHuffmanDynamicTree","DEF_HEADER_METHOD_MASK","DEF_HEADER_INFO_MASK","DEF_HEADER_FLAGS_FCHECK","DEF_HEADER_FLAGS_FDICT","DEF_HEADER_FLAGS_FLEVEL","DEF_MAX_WINDOW_SIZE","DEF_HUFFMAN_REPEATE_MAX","DEF_HUFFMAN_END_BLOCK","DEF_HUFFMAN_LENGTH_MINIMUMCODE","DEF_HUFFMAN_LENGTH_MAXIMUMCODE","DEF_HUFFMAN_DISTANCE_MAXIMUMCODE","mCheckSum","tBuffer","mBufferedBits","mTempBuffer","mBlockBuffer","mbNoWrap","mWindowSize","mCurrentPosition","mDataLength","mbCanReadNextBlock","mbCanReadMoreData","mbCheckSumRead","DOMException","mInputStream","readZLibHeader","decodeBlockHeader","fillBuffer","bitMask","mBuffer","bytesRead","read","readInt16","readBits","bFinalBlock","blockType","mbReadingUncompressed","skipToBoundary","readInt16Inverted","lengthComplement","mUncompressedDataLength","mCurrentLengthTree","mCurrentDistanceTree","lengthTree","distanceTree","trees","decodeDynamicHeader","bLastSymbol","iLengthsCount","iDistancesCount","iCodeLengthsCount","iResultingCodeLengthsCount","arrResultingCodeLengths","arrDecoderCodeLengths","iCurrentCode","treeInternalDecoder","bNeedBreak","miRepSymbol","DEF_HUFFMAN_DYNTREE_REPEAT_BITS","DEF_HUFFMAN_DYNTREE_REPEAT_MINIMUMS","tempArray","readHuffman","free","dataRead","readdata","numDataRead","numReadMore","iRepeatLength","DEF_HUFFMAN_REPEAT_LENGTH_BASE","iRepeatExtraBits","DEF_HUFFMAN_REPEAT_LENGTH_EXTENSION","extra","DEF_HUFFMAN_REPEAT_DISTANCE_BASE","iRepeatDistance","DEF_HUFFMAN_REPEAT_DISTANCE_EXTENSION","initialLength","inBlockPosition","oldDataLength","dataToRead","readPackedBytes","readInt32","DEF_REVERSE_BITS","Stream","inputStream","byteLength","readByte","toByteArray","CRC32TABLE","INT_SIZE","SHORT_SIZE","CentralDirectoryEndSignature","CentralDirSizeOffset","CentralHeaderSignature","BufferSize","ZipArchive","initCrc32Table","files","isMicrosoftBrowser","navigator","msSaveBlob","file","ZipArchiveItem","addDirectory","directoryName","base64String","zipByteArray","lCentralDirEndPosition","findValueFromEnd","iCentralDirSize","ReadInt32","lCentralDirPosition","readCentralDirectoryDataAndExtractItems","itemHelper","readCentralDirectoryData","readData","checkCrc","decompressData","unCompressedStream","save","zipArchive","saveInternal","saveAsBlob","blob","skipFileSave","zipData","dirLength","compressedObject","getCompressedData","constructZippedObject","isDirectory","writeZippedContent","reader_1","FileReader","onload","crc32Value","compressedData","compressedSize","uncompressedDataSize","compressionType","calculateCrc32Value","readAsArrayBuffer","crc32Table","compressor","currentIndex","nextIndex","subArray","zipParts","extFileAttr","writeHeader","localHeader","centralDir","writeCentralDirectory","zipHeader","getModifiedTime","getModifiedDate","localDirLen","cenDirLen","getArrayBuffer","shift","writeFooter","Blob","externalFileAttribute","directoryHeader","centralLength","localLength","dirEnd","bytes","modTime","modiDate","lStreamSize","arrBuffer","lLastPos","lCurrentPosition","uiCurValue","bFound","ReadInt16","ReadUInt16","ZipArchiveItemHelper","headerSignature","crc32","compressionMethod","originalSize","iFileNameLength","iExtraFieldLenth","iCommentLength","externalAttributes","localHeaderOffset","m_strItemName","readLocalHeader","readCompressedData","decompressDataOld","decompressedData","reader","compressedStream","iReadBytes","iNameLength","iExtraLength","headerVal","dataStream","iBytesLeft","iBytesToRead","itemName","decompressedStream","ValueFormatter","cultureName","isServerRendered","displayText","CsvHelper","separator","csvStr","formatter","globalStyles","Map","worksheets","parseWorksheet","parseRows","rows_1","parseRow","parseCell","csv","parseCellValue","error","has","dataUrl_1","URL","createObjectURL","dwlLink","createElementNS","download","href","event_1","revokeObjectURL","encodingType","encoding","encodeString","BlobHelper","parts","append","part","getBlob","AutoFilters","Workbook","saveType","currencyString","sharedStringCount","unitsProportions","hyperlinkStyle","currency","mSaveType","mArchive","sharedString","mFonts","mBorders","mStyles","printTitles","cellStyles","mNumFmt","mFills","mCellXfs","mCellStyleXfs","drawingCount","imageCount","cellStyle","parserCellStyle","cellStylesIn","tFormat","parserWorksheets","builtInProperties","BuiltInProperties","parserBuiltInProperties","csvHelper","jsonBuiltInProperties","author","comments","manager","subject","createdDate","modifiedDate","tags","jsonSheet","sheet","mergeCells","mergedCellsStyle","mHyperLinks","parserColumns","parserRows","freeze","parserFreezePanes","printTitle","parserPrintTitle","pageSetup","images","parserImages","autoFilters","parseFilters","hyperLinks","mergeOptions","fromJson","toJson","applyProperties","sourceJson","destJson","getCellName","getColumnName","strColumnName","iCurrentDigit","titleRowName","titleColName","printTitleName","fromRow","toRow","fromColumn","toColumn","freezePanes","leftCell","columnsLength","rowsLength","rowId","parserRow","insertMergedCellsStyle","rowToInsert","createCell","insertIndex","styleIndex","cellToInsert","refName","grouping","parseGrouping","parseCells","outlineLevel","isCollapsed","cellsLength","spanMin","spanMax","cellId","jsonCell","rowSpan","colSpan","hyperlink","hyperLink","getCellValueType","rId","formula","parseCellType","processMergeCells","spans","GetColors","processColor","colorVal","rgbColors","processCellValue","cellValue","processedVal","startindex","processString","substring","subString","subSplit","subSplit_1","applyGlobalStyle","defStyleIndex","parserBorder","leftBorder","rightBorder","topBorder","bottomBorder","processCellStyle","switchNumberFormat","numFmt","cellStyleXfs","cellXfs","changeNumberFormats","returnFormat","getNumberPattern","processNumFormatId","compareResult","compareStyle","isNewFont","toCompareStyle","font","isNewBorder","bStyle","isAllBorder","toCompareBorder","allBorderStyle","baseStyle","toOADate","value_1","sstvalue","imagesLength","parserImage","lastRow","lastColumn","horizontalFlip","verticalFlip","blobSaveType","blobData","proxyUrl","xlsxMatch","csvMatch","saveWorkbook","saveWorksheets","saveSharedString","saveStyles","saveApp","saveCore","saveContentType","saveTopLevelRelation","saveWorkbookRelation","workbookTemp","sheets","sheetName","printTitle_1","addToArchive","saveWorksheet","sheetBlob","sheetString","saveSheetView","colString","pixelsToColumnWidth","rowString","pixelsToRowHeight","_j","hLink","saveDrawings","saveSheetRelations","drawings","sheetDrawingString","imgId","pic","updatelastRowOffset","updatelastColumnOffSet","lastRowOffset","lastColOffset","imageData","convertBase64toImage","saveDrawingRelations","picture","iCurHeight","iCurRow","iCurOffset","iRowHeight","convertToPixels","iSpaceInCell","rowHiddenHeight","iCurWidth","iCurCol","iColWidth","ColumnWidthToPixels","colHiddenWidth","img","byteStr","atob","ArrayBuffer","drawingRelation","pixels","dDigitWidth","trunc","fileWidth","relStr","paneString","sstStart","si","updateCellXfsStyleXfs","styleTemp","saveNumberFormats","saveFonts","saveFills","saveBorders","saveCellStyleXfs","saveCellXfs","saveCellStyles","compareFontResult","fontId","fillId","borderId","applyAlignment","numFmtStyle_1","fillsStyle","bordersStyle","cellStyleString","cellXfsStyle","cellStyleXf","saveAlignment","cellXf","alignString","appString","coreString","toISOString","topRelation","wbRelation","contentTypeString","sheetsOverride","drawingIndex","xmlString","archiveItem","startCell","endCell","updatedMergedCellStyles","sCell","eCell","dateToTicks","ticksPerDay","daysToMonth365","daysToMonth366","isLeapYear","timeToTicks","totalSeconds","daysTo1899","doubleDateOffset","oaDateMinAsTicks","millisPerDay","AriaService","setOptions","setStateAndProperties","config","setExpand","expand","setSort","setBusy","isBusy","busy","setGrabbed","isGrabbed","grabbed","setDropTarget","isTarget","dropeffect","datarole","selected","multiselectable","haspopup","colcount","rowcount","processFutureTime","substr","eifelerRegelAppliesToNumber","processPastTime","lastDigit","firstDigit","lb","CLS_VERTICAL","CLS_ITEMS","CLS_ITEM","CLS_RTL","CLS_SEPARATOR","CLS_POPUPICON","CLS_POPUPDOWN","CLS_POPUPOPEN","CLS_TEMPLATE","CLS_DISABLE","CLS_POPUPTEXT","CLS_TBARTEXT","CLS_TBAROVERFLOW","CLS_POPOVERFLOW","CLS_TBARBTN","CLS_TBARNAV","CLS_TBARSCRLNAV","CLS_TBARRIGHT","CLS_TBARLEFT","CLS_TBARCENTER","CLS_TBARPOS","CLS_HSCROLLCNT","CLS_VSCROLLCNT","CLS_HSCROLLBAR","CLS_POPUPNAV","CLS_POPUPCLASS","CLS_POPUP","CLS_TBARBTNTEXT","CLS_TBARNAVACT","CLS_TBARIGNORE","CLS_POPPRI","CLS_HIDDEN","CLS_MULTIROW","CLS_MULTIROWPOS","CLS_MULTIROW_SEPARATOR","CLS_EXTENDABLE_SEPARATOR","CLS_EXTEANDABLE_TOOLBAR","CLS_EXTENDABLECLASS","CLS_EXTENDPOPUP","CLS_EXTENDEDPOPOPEN","Item","Toolbar","resizeContext","resize","orientationChangeContext","orientationChange","popupOpen","popupClose","btnItems","el","ej2_instances","tempId","destroyItems","lastElementChild","trgtEle","ctrlTem","popObj","activeEle","tbarAlign","tbarItemsCol","attrb","enableCollision","scrollStep","scrollModule","isVertical","isExtendedOpen","popupPriCount","allowKeyboard","wireKeyboardEvent","keyModule","keyActionHandler","docKeyDown","updateTabIndex","dataTabIndex","unwireKeyboardEvent","popCheck","overflowMode","keyCheck","destroyScroll","docEvent","clearProperty","tbarEle","tbarAlgEle","lefts","centers","rights","popEle","tbarItems","destroyMode","tempEle","popupRefresh","elementFocus","fChild","activeEleSwitch","clstElement","tbrNavChk","trgt","clst","keyHandling","navChk","scrollChk","nodes","rootEle","popAnimate","eleFocus","popupCheck","extendedPopup","focusFirstVisibleEle","focusLastVisibleEle","popFrstEle","ele_1","activeEleRemove","tbarScrollChk","disable","eleContains","sib","skipEle","elem","tbrItems","itemObj","isPopupElement","clsList","popupNav","popupClickHandler","tempItem","clickedArgs","getElementOffsetY","minHeight","renderControl","portals","ariaAttr","renderItems","renderLayout","renderOverflowMode","itemPositioning","checkPopupRefresh","itemsAlign","itemEleDom","innerItem","innerPos","renderSubComponent","tbarItemAlign","align","showAlwaysInPopup","changeOrientation","initScroll","innerItems","checkOverflow","scrollEle","itemWidthCal","marginTop","marginBottom","marginLeft","getScrollCntEle","trgClass","eleWidth","itemWidth","popNav","scrollNav","navEleWidth","toolbarAlign","priorityCheck","offsetWid","removePositioning","setOverflowAttributes","createPopupEle","eleItem","multiVar","extendVar","eleInlineItem","innerEle","innerNav","createPopupIcon","innerNavDom","checkPriority","removeProperty","createPopup","pushingPoppedEle","tbarObj","popupPri","eleHeight","sepHeight","poppedEle","nodeIndex","nodePri","tbResize","tbarElement","sepItem","extendEle","popupEle","popupInit","maxHeight","eleStyles","borderRightWidth","tbarPopupHandler","isOpen","toolEle","popupElePos","popIcon","scrollVal","scrollY","innerHeight","overflowHeight","tbEleData","popupOffset","documentElement","inEle","pre","checkoffset","popPriority","eleWid","sepCheck","itemCount","itemPopCount","checkClass","rVal","cls","mrgn","compuStyle","fstEleCheck","tbarEleMrgn","eleWid_1","minWidth","sepEle","popedEle","nav","navItem","tbarPriRef","sepPri","des","elWid","wid","ig","ignoreCount","priEleCnt","eleSep","ignoreCheck","eleSepWidth","prevSep","previousElementSibling","isVer","dimension","popupEleWidth","popupEleRefresh","ignoreEleFetch","ignoreEle","ignoreInx","tbarWidth","tbarItemsWid","elWidth","btnText","btn","eleSplice","inlineStyles","sepBeforePri_1","state_1","refreshPositioning","tbarWid","popWid","itemEle","alignDiv","alignEle","leftAlign_1","ctrlTemplate","setAttr","keyVal","enableItems","isEnable","itemElement","getElementByIndex","addItems","extendedOpen","itemsDiv","itemsRerender","itemAgn","items_1","algIndex","removeItems","removeItemByIndex","eleIdx","indexAgn","clearToolbarTemplate","btnItem","templateRender","templateProp","isComponent","itemType","eleObj","regEx","tempStr","toolbarTemplateID","isStringTemplate","getDataTabindex","buttonRendering","dom","iconPos","textStr","btnTxt","prefixIcon","suffixIcon","btnObj","iconPosition","tempDom","tooltipText","itemClick","showTextOn","sTxt","curEle","multirowele","updateHideEleTabIndex","isElement","eleIndex","nextEle","templateEle","registeredTemplate","registeredTemplates","registeredItem","rootNodes","closestItem","portalItem","containerInfo","tEle","changedProb","popupPriCheck","booleanCheck","itemCol","hideItem","innerItems_1","CLS_ROOT","CLS_HSCROLLCON","CLS_NAVARROW","CLS_NAVRIGHTARROW","CLS_NAVLEFTARROW","CLS_HSCROLLNAV","CLS_HSCROLLNAVRIGHT","CLS_HSCROLLNAVLEFT","CLS_DEVICE","CLS_OVERLAY","CLS_RIGHTOVERLAY","CLS_LEFTOVERLAY","OVERLAY_MAXWID","HScroll","browser","browserCheck","customStep","ieCheck","uniqueId","scroll","touchHandler","swipeHandler","createOverlay","createNavIcon","setScrollState","scrollDiv","innerEle_1","overflowX","scrollItems","overlay","navEles","rightOverlayEle","clsRight","rightEle","leftEle","eventBinding","rightAttributes","clsLeft","leftAttributes","navEle","navLeftItem","onKeyPress","timeoutFun_1","keyTimeout","eleScrolling","keyTimer","onKeyUp","tabHoldHandler","repeatScroll","clickEventHandler","clearInterval","timeout","scrollDis","timeoutFun","setInterval","isContinuous","frameScrollRequest","swipeEle","velocity","distanceX","step","sin","cancelAnimationFrame","requestAnimationFrame","scrollUpdating","scrollValue","scrollDirection","arrowDisabling","addDisable","removeDisable","arrowIcon","navLeftEle","navRightEle","leftOverlay","rightOverlay","disEle","webpackContext","req","webpackContextResolve","__webpack_require__","o","exports","az","zhHk","hr","Reorder","idx","headerDrop","enableAfterRender","drag","dragStart","dragStop","createReorderElement","keyPressHandler","chkDropPosition","srcElem","destElem","bool","lockColumn","isEqualNode","targetParentContainerIndex","chkDropAllCols","isFound","getHeaderCells","pop","findColParent","cnt","getColumnsModel","isNotStackedHeader","columnModel","subCols","dropElement","uId","destElemDiv","destElemUid","destColumn","sourceUid_1","colMatchIndex_1","destUid_1","moveColumns","newIndex","destElement","oldIdx","isActionPrevent","destIndex","reorderByColumn","preventRefresh","handler","arg1","arg2","getColParent","srcIdx","lockcolPositionCount","frozenColumns","getFrozenLeftCount","getFrozenRightColumnsCount","toColumnUid","cols_1","refreshColumnIndex","stackedHdrColumn","getStackedColumns","stackedCols","getAllStackedheaderParentColumns","flatColumns","parents","reorderSingleColumn","fromFName","toFName","reorderMultipleColumns","fromFNames","getColumnIndexByField","getColumnByIndex","moveTargetColumn","reorderSingleColumnByTarget","fieldName","reorderMultipleColumnByTarget","reorderColumns","fromCol","reorderColumnByIndex","reorderColumnByTargetIndex","isXaxis","setDisplay","upArrow","downArrow","getColumnHeaderByField","focusModule","onClick","isMacLike","platform","metaKey","currentInfo","visibleCols","getVisibleColumns","toCol","cloneElement","getHeaderTable","stopTimer","updateScrollPostion","updateArrowPosition","draggableType","cliRect","cliRectBaseRight","cliRectBaseLeft","scrollElem","timer","cliRectBase","CommandColumnRenderer","locator","buttonElement","unbounDiv","childRefs","tabindex","destroyButtons","isVirtualEdit","localizer","tempID","renderTemplates","renderButton","setAttributes","buttonOption","onclick","buttonObj","commandType","CommandColumn","initiateRender","cellFac","getService","addCellRenderer","commandClickHandler","commandColumn","getRowObjectFromUID","commandCols","idInString","typeInString","findIndex","rowData","commandclickargs","editModule","startEdit","closeEdit","commandDelIndex","clearSelection","selectRow","deleteRecord","load","commandCol","LegendSettings","BaseLegend","maxItemHeight","rowHeights","pageHeights","columnHeights","pageXCollections","chartRowCount","legendTitleCollections","legendRegions","pagingRegions","legend","isChartControl","isAccChartControl","isBulletChartControl","isStockChartControl","bulletChart","fivePixel","rowCount","pageButtonSize","maxColumns","backwardArrowOpacity","forwardArrowOpacity","arrowWidth","arrowHeight","isTop","isTitle","currentPageNumber","getPosition","itemPadding","library","get3DLegendBounds","getLegendBounds","containerPadding","accumulation","setBounds","titlePosition","legendTitleSize","isPaging","enablePages","calculateLegendTitle","isBulletChart","labelIns","ticklIns","categoryFieldValue","categoryField","legendHeight","legendWidth","alignLegend","axisTextSize","legendSize","titlePlusArrowWidth","pagingLegendBounds","requireLegendBounds","firstLegend","findFirstLegendPosition","upArrowHeight","legendGroup","legendTranslateGroup","createLegendElements","totalPages","textSize","shapeHeight","isRtlEnable","getLinearLegend","legendSeriesGroup","previousLegend","startPadding","shapeWidth","xLocation","textOptions","shapePadding","legendIndex","leftSpace","bottomSapce","rightSpace","legendOption","isReverse","accessbilityText","generateId","getRenderPoint","renderSymbol","renderText","toggleVisibility","renderPagingElements","xmlns","nextLegend","gradientLegendCount","linerGradientEle","fillColors","numberItems","colorMap","diffValue","colorsLength","calculatedValue","full","stopEle","startLabelY","endLabelY","startLabelX","endLabelX","startLabel","endLabel","startTextSize","endTextSize","otherSpaces","linearBarWidth","linearBarHeight","diffWidth","diffHeight","hiddenColor","fontcolor","isCanvas","translatePage","gradientLegend","legendCollection","legendCollection_1","legendTitleFont","maximumTitleWidth","renderLegendTitle","topPadding","legendTitleTextOptions","legendItemsGroup","clippath","createClipPath","pagingClipRect","regionPadding","symbolColor","isStrokeWidth","isCustomBorder","strokewidth","seriesBorder","isLineShapemarker","symbolOption","markerVisibility","textOption","pageTextElement","paginggroup","grayColor","cursor","clipPathHeight","totalNoOfPages","getPageHeight","sum","pagingText","pageNumber","changePage","backwardArrow","forwardArrow","pageText","hideArrow","showArrow","arrowElement","prefix","move","clearTooltip","LegendOptions","addDays","getTradePeriodName","yearSuffix","ToString","Substring","numOfDays","getDateDiffInDays","tradeablePeriod","getQuarter","getBusinessDatesCount","dayOfWeek","ga","SvgRenderer","rootID","svgLink","rootId","getOptionValue","svgObj","setElementAttributes","setSVGSize","line","rectangle","drawCircle","circle","drawPolyline","polyline","drawEllipse","ellipse","polygon","setAttributeNS","preserveAspectRatio","createText","createTSpan","tSpan","createTitle","defs","clipPath","createForeignObject","foreignObject","createPattern","createRadialGradient","colorStop","newOptions","cx","cy","fx","fy","drawGradient","createLinearGradient","gradientType","gradient","stop_1","drawClipPath","drawCircularClipPath","createCanvas","CanvasRenderer","canvasObj","ctx","getContext","setCanvasSize","lineWidth","dashArrayString","setLineDash","strokeStyle","beginPath","stroke","moveTo","lineTo","restore","canvasTranslate","canvasCtx","rx","globalAlpha","drawCornerRadius","fillStyle","fillRect","arcTo","closePath","dataSplit","flag","innerR","q1","q2","quadraticCurveTo","c1","c2","c3","c4","bezierCurveTo","arc","counterClockWise","dy","isTSpan","baseline","textBaseline","txtlngth","rotate","fillText","circumference","ry","imageObj","src","myGradient","setGradientValues","newColorStop","stopColor","addColorStop","updateCanvasAttributes","dataUrl","img_1","clip","getTooltipThemeColor","tooltipFill","tooltipBoldLabel","tooltipLightLabel","tooltipHeaderLine","measureText","themeFontStyle","breakText","textArray","whiteSpace","lineHeight","Size","withInAreaBounds","findDirection","rX","rY","arrowLocation","arrowPadding","tipX","tipY","controlName","Rect","Side","isRight","isBottom","CustomizeOption","TextOption","baseLine","removeElement","drawSymbol","calculateShapes","functionName","renderOption","locX","locY","eq","PathOption","renderOptions","TooltipLocation","TextStyle","TooltipBorder","AreaBounds","ToolLocation","removeSVG","createTooltipElement","highlightPadding","areaMargin","markerPoint","templateObject","blazorTemplate","fadeOuted","updateTemplateFn","createTemplate","markerSide","renderTooltipElement","drawMarker","markerSize","textElements","enableRTL","shapes","marginX","palette","tipLocation","marginY","isFixed","sharedTooltipLocation","tooltipLocation","clipBounds","wrapPadding","wrapHeader","isWrap","wrappedText","headerSize","xLength","pathElement_1","pointRect","enableAnimation","updateDiv","animateTooltipDiv","tooltipPlacement","enableShadow","shadowId","shadow","changeText","revert","findFormattedText","isRender","lines","tspanElement","tspanOption","subWidth","tspanStyle","isBoldTag","headerWidth","isLeftSpace","isRightSpace","headerSpace","isColumn","subStringLength","markerPadding","spaceWidth","labelColor","contentWidth","withoutHeader","isTextWrap","reverse","isRTLText","textFont","getTooltipTextContent","width_1","renderContentRTL","contentWidthIndex","characterCollection","isRtlText","isValidHTMLElement","firstElement","templateElement","sharedTemplateElement","controlInstance","tooltipRect","tooltipRendered","rect1","thisObject_1","tooltipRect1","getCurrentPosition","symbolLocation","boundsX","boundsY","outOfBounds","currenDiff","transition","tooltipElement","tooltipGroup_1","Node","ELEMENT_NODE","opacity_1","progressAnimation","endAnimation","tooltipGroup","ur","ColumnBase","getSideBySideInfo","enableSideBySidePlacement","getSideBySidePositions","columnWidthInPixel","seriesSpacing","columnSpacing","pointSpacing","columnWidth","minimumPointDelta","groupName","mainColumnWidth_1","mainWidth","mainDoubleRange","difference","getRectangle","drawCylinder","cylinderSeriesOption","canvasRender","gradientColor","cx1","cx2","cy1","cy2","xl","yl","xPos","yPos","rxt","ryt","gx1","gx2","gy1","gy2","ini","stacking","isLastSeries","AEx","AEy","LX","LY","GX","GY","X1","Y1","X2","Y2","optiong","gradientElement","linearGradientElement","stopElement","findRectPosition","vSeries","updateSymbolLocation","updateYRegion","updateXRegion","getRegion","calculateRoundedRectPath","topLeft","topRight","bottomLeft","bottomRight","columnFacet","visiblePoints_1","animateRect","isPlot","halfValue","esUs","tet","dv","tk","weekEndings","hu","zhCn","te","ChartData","insideRegion","getRectPoint","fromCenterX","fromCenterY","clickAngle","startAngle","endAngle","distanceFromCenter","arcAngle","currentXPosition","atan2","innerRadius","isPointInThresholdRegion","checkRegionContainsPoint","regionRect","isBar","heightValue","getClosest","xvalues","leftSideNearest","rightSideNearest","isDataExist","binarySearch","middle","found","getDistinctValues","commonXValues","intial","sv","ugCn","MultiColoredSeries","getAreaPathDirection","startPath","getAreaEmptyDirection","isXSegment","segments","segment","getAxisValue","sortSegments","chartSegments","segmentAxis","applySegmentAxis","includeSegment","attributeOptions","areaBorderCount","createClipRect","multiColoredAreaSeriesModule","startValue","endValue","isX","isRequired","startPointLocation","endPointLocation","segmentValue","MultiColoredLineSeries","lastPoint","segmentPoint","webpackPolyfill","deprecate","paths","legendClick","legendRender","pointRender","sharedTooltipRender","seriesRender","axisLabelRender","axisRangeCalculated","tooltipRender","chartMouseMove","chartMouseClick","chartDoubleClick","chartMouseLeave","chartMouseDown","chartMouseUp","zoomComplete","resized","beforeResize","beforePrint","annotationRender","stockEventRender","regSub","regSup","beforeExport","onZooming","msMy","Category","calculateRange","getActualRange","applyRangePadding","calculateVisibleLabels","initializeDoubleRange","calculateVisibleRange","eo","sd","StripLine","measureStripLine","actualStart","actualEnd","isDateTimeAxis","isRepeat","dateToMilliSeconds","isCoreDate","getFromTovalue","startFromAxis","to","from","sizeType","isSegmented","segmentStart","segmentEnd","segRect","getToValue","findValue","isEnd","fromValue","dateParse","striplineGroup","axes_1","getSegmentAxis","repeatEvery","repeatUntil","renderStripLineElement","getStartValue","renderPath","strokeWidth","renderRectangle","stripLineLabelFont","isRotationNull","textMid","ty","tx","getTextStart","factor","horizontalAlignment","verticalAlignment","invertAlignment","segmentAxisName","pixelRect","xy","relativeTimeWithMutation","mutation","specialMutationForYears","lastNumber","softMutation","mutationTable","fullWeekdaysParse","shortWeekdaysParse","minWeekdaysParse","br","weekdaysParse","mi","mk","last2Digits","nb","kk","arTn","ExportHelper","hideColumnInclude","parentDetails","totalRecordsCount","getFData","getGridRowModel","isExpand","hierarchyPrintMode","expandedRows","generateCells","processColumns","childGridLevel","generateCell","getColumnData","gridObj","columnPromise","fColumns","colData","getHeaders","isHideColumnInclude","colDepth","processHeaderCells","generateActualColumns","getConvertedWidth","actualColumns","getCellCount","appendGridCells","gridRows","StackedHeader","isIgnoreFirstCell","Header","columnIndexes","getColumnIndexesInView","HeaderIndent","checkAndExport","gridPool","globalResolve","failureHandler","childGridObj","createChildGrid","exportType","detailRowModule","getGridModel","isPrinting","parentID","parentPrimaryKeys","parentKeyField","parentKeyFieldValue","parentRowData","exportId","isExportGrid","getGridExportColumns","actualGridColumns","gridColumns","ExportValueFormatter","internationalization","returnFormattedValue","customFormat","formatCellValue","cFormat","ExcelExport","book","workSheet","rowLength","expType","includeHiddenColumn","isCsvExport","isChild","isElementIdChanged","grpFooterTemplates","footerTemplates","aggIndex","totalAggregates","isExporting","exportValueFormatter","grid","exportProperties","isMultipleExport","workbook","isCsv","isBlob","isBlb","Child","workbk","isMultiEx","hierarchyExportMode","gridObject","processRecords","exportingSuccess","blobPromise","gridInstance","allPromise_1","processInnerRecords","getCurrentViewRecords","query_1","isCountRequired","groupedColLength","blankRows","isExportPropertiesPresent","multipleExport","processExcelHeader","stringify","processGridExport","organisedRows","organiseRows","processExcelFooter","enableFilter","headerRowLen","headerRows","initialIndex","childRows","excelRows","gColumns","headerRow","groupIndent","processHeaderContent","groupData","lazyloadData","acc","curr","lazQuery","contentModule","lazyLoadQuery","processRecordContent","capTemplate","returnType","currentViewRecords","excelRow","record","processRecordRows","processGroupedRows","GroupGuid","processAggregates","excelExportProperties","dataSource_1","cArgs","captionText","getCaptionThemeStyle","captionModelGen","groupCaptionSummaryRows","fillAggregates","childLevels","lIndex","hIndex","tCell","col_1","templateRowHeight","gCell","valueAccessor","arr","fkData","excelCellArgs","base64","setImage","getColumnStyle","parentRow","processDetailTemplate","returnVal","beforeDataBound","childGridCell","rowObj","templateData","detailCellIndex","detailIndent","columnHeader","processCell_1","currentCell","getHeaderThemeStyle","getRecordThemeStyle","excelHAlign","excelVAlign","excelRotation","excelBorders","excelNumberFormat","excelType","processRow","currentRow","excelDetailCells","detailCell","excelImage","excelExportProps","gRow","intent","rec","byGroup","summaryModel","aggregateModule","prepareSummaryInfo","groupSummaryModel","groupSummaryRows","sRows","customIndex","rows_2","columnsDetails","getAggreateValue","Sum","Average","Max","Min","Count","TrueCount","FalseCount","Custom","aggregateStyle","gridCellStyle","row_1","dummyOutlineLevel","dummyGrouping","txt","JSON1","JSON2","attrname","headerRotation","degree","spannedCells","parseStyles","currentCellIndex","gridCell","DetailHeader","getIndex","spannedCell","headerTextAlign","excelHeaderCellArgs","updateThemeStyle","themestyle","caption","noRows","updatedCellIndex","footerRows","spannedCells_1","it","itCh","enNz","monthsShortWithDots","monthsShortWithoutDots","getCloneProperties","Print","isAsyncPrint","defered","isContentReady","actionBeginFunction","onEmpty","hierarchyPrint","isPrintGrid","contentReady","removeColGroup","printGridObj","printModule","renderPrintGrid","printGrid","getFrozenColumns","getInjectedModules","injectedModues","setInjectedModules","printgrid","selectedRows","contentDiv","headerDiv","waitingPop","printGridElement","printWind","outerHeight","outerWidth","screen","availWidth","availHeight","groupCaption","colGroups","contentColGroups","footerColGroups","hideColGroup","printGridProp","enIl","WRAPPERCLASS","POPUPDIMENSION","DAY","HOVER","NAVIGATION","ICONANIMATION","FOCUS","LISTCLASS","HALFPOSITION","ANIMATIONDURATION","OFFSETVAL","EDITABLE","wrapperAttributes","TimePickerBase","createListItems","createdEl","timeFormat","listItems","timeCollections","listTag","createList","TimeMaskPlaceholder","TimePicker","disableItemCollection","timeOptions","keyConfigure","down","up","angularTag","openPopupEventArgs","createInputElement","setTimeAllowEdit","validateInterval","validateDisable","checkErrorState","inputEleValue","getDateObject","clearIconState","setMinMax","initMin","initMax","popupCreation","valueIsDisable","resetState","initValue","defaultCulture","checkTimeFormat","checkInValue","scrollTo","checkAttributes","localeText","isNavigate","isPreventBlur","isTextSelected","valueWithMinutes","prevDate","updatedCssClassesValue","isNullOrEmpty","inputStyle","getCldrDateTimeFormat","cldrTime","dateFormat","cldrFormat","isInvalid","valueExpression","valueExp","setCurrentDate","cldrDateTimeString","getCultureTimeObject","ariaAttribute","enableElement","rippleFn","propertyList","generateList","listWrapper","addSelection","getPopupHeight","popupHeight","wireListEvents","rippleModel","containerStyle","setPopupWidth","unWireListEvents","modelTitleSpan","timePopupCloseHandler","createDateObj","updatedClassesValue","timeStyle","cssClassNew","cssClassOld","removeErrorClass","validateState","disableTimeIcon","disableElement","selectInputText","setSelectionRange","setCursorToEnd","getMeridianText","meridian","getCursorSelection","getActiveElement","inputWidth","setScrollTo","findScrollTop","listHeight","liHeight","initialTime","scrollTime","getText","getValue","cldrTimeFormat","cldrDateFormat","cldrDate","getCultureDateObject","dateToNumeric","getExactDateTime","validateMinMax","compareFormatChange","updatePlaceHolder","popupHandler","closePopup","curPos","cursorDetails","focusSelection","isSeparator","keyHandler","updateValue","objToString","createMask","previousState","onMouseClick","animModel","documentClickHandler","mobileTimePopupWrap","disposeServerPopup","checkValueChange","isNavigation","valueProcess","prevValue","onMouseOver","currentLi","setHover","removeHover","onMouseLeave","minVal","maxVal","dateVal","strictOperation","maxValue","minValue","inputEventHandler","clearHandler","inputEvent","timeValue","raiseClearedEvent","setZIndex","getTextFormat","strArray","validateValue","newval","findNextElement","textVal","timeVal","collections","selectNextItem","validLiElement","elementValue","backward","elementIndex","isCheck","nextItem","isUpdate","hoveredItem","getHoverItem","setActiveClass","formatStr","timeParse","listBaseOptions","getProperty","popupAlignment","timePopupElement","formatValues","DATEPICKERROOT","DATETIMEWRAPPER","HOUR","MINUTE","SECOND","MILLISECOND","DATETIMEPOPUPWRAPPER","DateTimePicker","scrollInvoked","formatRegex","dateFormatString","dateTimeOptions","blurHandler","isTimePopupOpen","popupObject","dateTimeWrapper","keyboardHandler","unBindInputEvents","timeIcon","timekeyConfigure","cldrDateTimeFormat","bindInputEvents","validateMinMaxRange","isDateObject","disablePopupButton","checkValidState","isValidState","isDisable","renderTimeIcon","timeHandler","dateHandler","inputKeyAction","getCldrFormat","cldrDateTime","isDatePopupOpen","toggle","listCreation","dateObject","TimePopupFormat","startTime","endTime","listDetails","wireTimeListEvents","addTimeSelection","setTimeScrollPosition","openPopup","timeModal","timeKeyActionHandle","unWireTimeListEvents","modelWrapper","dateTimeCloseHandler","timeContent","setDimension","setTimeHover","removeTimeHover","nextElement","listContent","getFullDateTime","tempVal","combineDateTime","seconds","setTimeActiveClass","setTimeActiveDescendant","removeTimeSelection","getTimeHoverItem","calculateStartEnd","method","milliseconds","tempStartValue","tempMin","formatCount","proxy","formatValueSpecifier","formattext","tempEndValue","tempMax","getUTCFullYear","dateTimeCloseEventCallback","maskedDateModule","getTimeActiveElement","status_1","millisecond","findNextTimeElement","dateTimeVal","listCount","timeElementValue","setTimeValue","timeKeyHandler","nextItemValue","sw","dataQuery","dataManagerDeferred_1","sk","getNumberParser","fromView","FilterCellRenderer","getGui","innerDIV","fltrData","isReactCompiler","isReactChild","parentInstObj","filterBarTemplate","Element","clearIconElem","localeObj","appendHtml","showFilterBarOperator","operatorIconRender","templateWrite","innerHtml","operators","fbicon","filterModule","dropOptr","popupWidth","internalEvent","customOperators","spanElmt","FlMenuOptrUI","customFltrOperators","ddOpen","dropDownOpen","customFilterOperators","destroyDropDownList","renderOperatorUI","dlgConetntEle","dlgObj","dialogObj","optr","optrData","customOptr","dropDatasource","selectedValue","dropSelectedVal","optrDiv","optrInput","valInput","renderResponsiveDropDownList","selValue","selectedField","optrLen","getFlOperator","StringFilterUI","serLocator","processDataOperation","getAutoCompleteOptions","foreignColumnQuery","filteredData","getDistinct","enableCaseSensitivity","autoComplete","sortOrder","localizeText","acFocus","acComplete","acOpen","defObj","deffered","actObj","afterRenderFilterUI","struiObj","filterOptr","filterObj","actuiObj","filterValue","filterByColumn","getOptrInstance","mapObj","NumberFilterUI","keyEventHandler","numericTxtObj","numberuiObj","BooleanFilterUI","dropInstance","ddComplete","drpuiObj","DateFilterUI","dpOpen","fltrSettings","inputElem","datePickerObj","dateuiObj","FilterMenuRenderer","fltrObj","isDialogOpen","isMenuCheck","colTypes","flMuiObj","menuFilterBase","clearCustomFilter","clearBtnClick","applyCustomFilter","filterBtnClick","openDialog","renderDlgContent","closeDialog","columnType","filterModel","mainDiv","dlgDiv","responsiveCnt","closeOnEscape","dialogCreated","buttonModel","isPrimary","renderResponsiveDialog","isModal","currentDialogCreatedColumn","renderFilterUI","ui","writeMethod","renderFlValueUI","menuOperator","valueDiv","fObj","instanceofFilterUI","valueInString","compElement","cBox","getAllData","dlgContentEle","flValue","targ","flOptrValue","fltrValue","eControl","closeResponsiveDialog","removeFilteredColsByField","getFilterUIInfo","renderCheckBoxMenu","updateModel","getAndSetChkElem","btnClick","dlg","sBox","CheckBoxFilter","isresetFocus","checkBoxBase","actionPrevent","clearFilter","fltrBtnHandler","ExcelFilterBase","eventHandlers","focusedMenuItem","isExcel","getCMenuDS","datetime","dateonly","unwireExEvents","menuObj","destroyCMenu","removeDialog","createMenu","isCheckIcon","eleOptions","menu","ul","isResponsiveFilter","hdrele","getColumnHeaderByUid","colIsSort","isAsc","isDesc","ascName","descName","createMenuElem","ensureTextFilter","iconName","isSubMenu","wireExEvents","hoverHandler","clickExHandler","keyUp","menuItem","focusNextOrPrevElement","focusableElements","focusClassName","shiftKey","focusClass","excelSetFocus","prevElem","isCMenuOpen","contextKeyDownHandler","cmenu","focused","submenu","selectedMenu","menuOptions","selectHandler","onClose","beforeClose","preventClose","contextRect","getContextBounds","innerWidth","getCMenuYPosition","existingPredicate","isFilterBack","MouseEvent","contextWidth","targetPosition","leftPos","targetBorder","showDialog","filterLength","filteredColumns","renderDialogue","complexFieldName","overlayClick","dropDownList","templateField_1","createdDialog","rowResponsiveDlg","destroyTemplate","removeObjects","renderCustomFilter","dialog","dlgFields","fieldSet","displayName","checkBoxValue","colValue","fValue","fOperator","sValue","sOperator","checkBox","andRadio","firstOperator","firstValue","secondOperator","secondValue","mPredicate","fColl","arg3","arg4","arg5","arg6","arg7","arg8","filterCollection","ejpredicate","actualPredicate","foreignKeyFilter","elementID","fieldElement","xlfloptr","menuText","dropDownValueChange","removeHandlersFromComponent","includes","getSelectedText","renderRadioButton","td","radioDiv","frstpredicate","secndpredicate","renderMatchCase","orRadio","elements_1","isFilteredCol","fltrPredicates","columnObj","getExcelFilterData","valueInput","renderAutoComplete","renderNumericTextBox","renderDate","renderDateTime","predIndex","matchCaseDiv","matchCaseInput","checkbox","inputValue","isRtl","datePicker","dateTimePicker","completeAction","numericTextBox","colObj","acActionComplete","mapObject","columnvalue","ExcelFilter","excelFilterBase","isCustomFilter","Filter","contentRefresh","filterByMethod","cellText","nextFlMenuOpen","filterOperators","endsWith","equal","greaterThan","greaterThanOrEqual","lessThan","lessThanOrEqual","notEqual","startsWith","wildCard","isNull","notNull","like","fltrDlgDetails","skipNumberInput","skipStringInput","setFullScreenDialog","getObject","getLocalizedCustomOperators","fltrElem","rowRenderer","cellrender","generateRow","rowdrag","detail","gCells","case","showCustomFilter","responsiveDialogRenderer","isCustomDialog","showResponsiveDialog","renderResponsiveChangeAction","setFilterModel","updateFilterMsg","dropdownlist","filterBarElement","registerAdaptiveService","isFilter","getFrozenMode","RowDragHIcon","filterObjIndex","getFilteredColsIndexByField","prevFilterObject","arrayVal","isMenuNotEqual","currentFilterObject","actualFilterValue","actualOperator","currentFilteringColumn","keyUpHandlerImmediate","refreshFilterValue","refreshFilterValueFn","initialEnd","initialLoad","columnPositionChanged","filterMenuClose","docClickHandler","refreshClearIcon","columnMenuFilter","filterIconClickHandler","targetText","filterOperator","filterCell","getOperatorName","checkForSkipInput","filterStatusMsg","applyColumnFormat","predObj","checkAlreadyColFiltered","getFlvalue","setFormatForFlColumn","skipUid","colLen","actualData","checkboxPrevFilterObject","checkboxFilterObject","iconClass","filterIconElement","updateFilterIcon","refreshFilterSettings","updateFilter","updateExternalMessage","refreshHeader","filterElement","getFilterBarElement","fltrIconElement","refreshFilter","clearFiltering","renderModule","colUid","filteredcols","fltrElement","filterDialogOpen","createOptions","hideSearchbox","filterHandler","localizedStrings","getLocaleConstants","allowCaseSensitive","parentTotalDataCount","totalDataRecordsCount","getFilteredRecords","parentCurrentViewDataCount","parentFilteredLocalRecords","isClearFilterBar","fCell","filteredColsUid","currentPred","currentFilterColumn","closeHeaderEle","dropDownListInput","processFilter","openMenuByField","clearIndicator","updateCrossIcon","getFormatFlValue","showFilterBarStatus","formater","isSkip","operatorSymbols","startTimer","onTimerTick","immediateModeDelay","templateRead","validateFilterValue","skipInput","getOperator","singleOp","multipleOp","numOptr","stringOperator","numberOperator","dateOperator","datetimeOperator","dateonlyOperator","booleanOperator","gClient","fClient","filterOperatorElement","inputId","datepickerEle","hasDialog","hasDialogClosed","refreshFilterIcon","addFilteredClass","renderCheckboxOnFilterMenu","TrendlinesDirective","TrendlinesPlugin","TrendlineDirective","TrendlinePlugin","SegmentsDirective","SegmentsPlugin","SegmentDirective","SegmentPlugin","SeriesCollectionDirective","SeriesCollectionPlugin","SeriesDirective","SeriesPlugin","StripLinesDirective","StripLinesPlugin","StripLineDirective","StripLinePlugin","CategoriesDirective","CategoriesPlugin","CategoryDirective","CategoryPlugin","MultiLevelLabelsDirective","MultiLevelLabelsPlugin","MultiLevelLabelDirective","MultiLevelLabelPlugin","AxesDirective","AxesPlugin","AxisDirective","AxisPlugin","RowsDirective","RowsPlugin","RowDirective","RowPlugin","ColumnsDirective","ColumnsPlugin","ColumnDirective","ColumnPlugin","RangeColorSettingsDirective","RangeColorSettingsPlugin","RangeColorSettingDirective","RangeColorSettingPlugin","AnnotationsDirective","AnnotationsPlugin","AnnotationDirective","AnnotationPlugin","SelectedDataIndexesDirective","SelectedDataIndexesPlugin","SelectedDataIndexDirective","SelectedDataIndexPlugin","IndicatorsDirective","IndicatorsPlugin","IndicatorDirective","IndicatorPlugin","ChartComponent","ChartPlugin","yo","SPINNER_CLASS","inputObject","ComboBox","wireEvent","preventBlur","onBlurHandler","targetFocus","onInput","onFilterUp","onFilterDown","pasteHandler","bindCommonEvent","customValue","valueMuteChange","setHiddenValue","dataItem","itemData","detachChangeEvent","getElementByText","getElementByValue","isExistItem","getItemData","clearIconHide","getAriaAttributes","ariaAttributes","hiddenElement","incrementalSearch","setSearchBox","searchBoxContainer","inlineSearch","getFocusElement","isDropDownClick","sortedData","activeItem","updatingincrementalindex","incrementalEndIndex","incrementalStartIndex","updateIncrementalInfo","updateIncrementalView","incrementalLiCollections","skeletonCount","removeFocus","fixedHead","selectedLiOffsetTop","removeFillSelection","checkCustomValue","getDataByValue","showSpinner","spinnerElement","disableIcon","hideSpinner","isHover","getTextByValue","currentFillValue","updateSelectedItem","isAndroidAutoFill","setAutoFillSelection","isAndroid","getSelectionPoints","prevEnd","prevSelectPoints","curEnd","prevStart","curStart","focusItem","selection","getValueByText","unWireEvent","unBindCommonEvent","selectCurrentItem","onChangeEvent","preventFocus","onFocus","previousValue_1","initial","updateCustomValueCallback","changeData","checkData","setReadOnly","comboProps","itemIndex","isEscape","isEscapeKey","sl","numbersPast","numbersFuture","verbalNumber","fi","AnnotationBase","setAnnotationPixelValue","accumulationBound","setAnnotationPointValue","xAnnotation","setAccumulationPointValue","annotationElement","annotationRendered","coordinateUnits","setElementStyle","accPoint","elementRect","setAlignmentValue","ChartAnnotation","arSa","bg","my","RowRenderer","isSpan","rowTemplate","refreshRow","isChanged","refreshMergeCells","tempCells","cells_1","rowArgs","cellArgs","chekBoxEnable","selIndex","getSelectedRowIndexes","isDataRow","isCheckBoxSelection","checkAllRows","buildAttributeFromRow","cellRendererFact","_loop_2","isColumnSelected","cellRenderer","getCellRenderer","DetailExpand","requireTemplateRef","isTemplate","thisRef_1","requestTypeAction","isRowSpanned","rowsObject","getRowsObject","prevRowCells","uid_1","prevRowCell","rowSpanRange","cellSpan","cellMerge","isSpanned","emptyColspan","getFrozenLeftColumnsCount","freezeCells","oldColspan","colspan","rowHeight","eventArg_1","isSelectable","cellTemplate","thisRef_2","disableRowSelection","isDraggable","selectionSettings","persistSelection","primaryKey_1","pKey_1","SelectedRecords","partialSelectedRecords","disableSelectedRecords","lazyLoadCssClass","rowRenderingMode","allowTextWrap","textWrapSettings","wrapMode","vFTable","summarycell","lastSummaryCell","firstSummaryCell","thisRef","eventArg","isPartialSelection","selRowIndex","chkBox","isDrag","cellIdx","isDetail","classes","isAltRow","isCaptionRow","rowindex","dataUID","ariaSelected","gl","es","invalidDate","ColumnSeries","sideBySideInfo","pointColumn","RowModelGenerator","getInfiniteIndex","enableImmutableMode","ensureColumns","RowDragIcon","pid","tIndex","parentGid","enableAltRow","refreshForeignKeyRow","foreignKeyColumns","dummies","oIndex","refreshRows","isFunction","Function","monthsNominativeEl","monthsGenitiveEl","momentToFormat","_monthsGenitiveEl","_monthsNominativeEl","calendarEl","mom","_calendarEl","monthsNominative","monthsSubjective","pl","fa","ar","LineSeries","prevPoint","isDrop","getCoordinate","bn","zhTw","CellType","RenderType","ToolbarItem","ResponsiveDialogAction","ResponsiveToolbarAction","ru","mn","ky","bnBd","ro","CLS_VSCROLLBAR","CLS_VSCROLLCON","CLS_NAVUPARROW","CLS_NAVDOWNARROW","CLS_VSCROLLNAV","CLS_VSCROLLNAVUP","CLS_VSCROLLNAVDOWN","CLS_UPOVERLAY","CLS_DOWNOVERLAY","VScroll","scrollEventHandler","createOverlayElement","wheelEventHandler","scrollCnt","navs","overlays","downOverlayEle","clsDown","downEle","upEle","clsUp","navElement","navUpItem","ev","scrollDistance","deltaY","swipeElement","distanceY","addDisableCls","removeDisableCls","navUpEle","navDownEle","upOverlay","downOverlay","lookup","ErrorOption","EMAIL","DATE_ISO","DIGITS","PHONE","CREDITCARD","FormValidator","validated","errorRules","allowSubmit","required","infoElement","selectQuery","localyMessage","defaultMessages","email","dateIso","creditcard","digits","rangeLength","tel","equalTo","localeFunc","afterLocalization","inputElements","createHTML5Rules","FormValidator_1","addRules","removeRules","validate","validateRules","rules_1","name_1","clearForm","getInputElement","validClass","elements_2","inputParent","grandParent","getErrorElement","hideMessage","defRules","acceptedTypes","allRule","defRules_1","rule","defRule","annotationRule","ruleCon","ruleName","rulesList","ruleFirstName","ruleSecondName","minvalue","maxvalue","customMessage","message","annotationMessage","getErrorMessage","isCheckable","submitHandler","clearEvents","excludeKeys","hiddenType","validateHiddenType","vhPos","hPos","rules_2","errorMessage","errorRule","inputName","isValid","ignore","removeErrorRules","showMessage","createErrorElement","errorElement","optionalValidationStatus","refer","param","currentRule","checkValidator","ruleValue","formats","errorOption","Message","errorContainer","containerId","divElement","customPlacement","nextSibling","checkRequired","inputType","uNum","compareTo","Label","ButtonComponent","ButtonPlugin","HeaderRender","frzIdx","notfrzIdx","isFirstCol","isReplaceDragEle","currentStateTarget","parentEle","visualElement","headercelldiv","getStackedHeaderColumnByHeaderText","colIndex","drop","droppedElement","ariaService","setVisible","colPosRefresh","renderCustomToolbar","updateCustomResponsiveToolbar","renderPanel","isRendered","innerDiv","toggleStackClass","setPanel","renderTable","getPanel","createHeaderTable","setTable","initializeHeaderDrag","initializeHeaderDrop","headerPanel","panel","getTable","headerTable","getColGroup","colgroup","setColGroup","getRows","tHead","createTable","tableEle","tableName","cellspacing","findHeaderRow","createHeaderContent","thead","bodyCell","rowBody","updateColGroup","colHeader","indexes","enablePersistence","lockColsRendered","appendCells","isFirstObj","isLastCol","isMovable","isStackLastCol","lastCol","isLockColumn","getCellCnt","stackedLockColsCount","getStackedLockColsCount","isStackedLockColumn","getColSpan","isFirstCol_1","isLaststackedCol","getColumnIndexByUid","lockColsCount","displayVal","clen","getNormalizedColumnIndex","refreshUI","freezeReorder","appendContent","updateDefaultCursor","firstHeaderCell","stackedHdr","dragTarget","abort","droppableDestroy","droppable","accept","toolbarLeft","toolbarItem","showResponsiveCustomSort","showResponsiveCustomFilter","resToolbar","HeaderCellRenderer","hTxtEle","sortEle","gui","chkAllBox","fltrMenuEle","prepareHeader","clean","hValueAccer","elementDesc","headerValueAccessor","checkAllWrap","buildAttributeFromCell","matchFlColumns","customAttributes","extendPrepareHeader","headerTempID","isReactChild_1","copied","clipMode","titleElem","matchFilteredColumns","StackedHeaderCellRenderer","IndentCellRenderer","GroupCaptionCellRenderer","cellUid","fKeyValue","gTemplateValue","domSetter","gCaptionTemp","tempObj","getTemplate","tempValue_1","captionTemplate","GroupCaptionEmptyCellRenderer","ExpandCellRenderer","infiniteScrollSettings","enableCache","HeaderIndentCellRenderer","DetailHeaderIndentCellRenderer","DetailExpandCellRenderer","RowDragDropRenderer","nodeElement","RowDragDropHeaderRenderer","Render","emptyGrid","counter","headerRenderer","getRenderer","contentRenderer","Content","isLayoutRendered","emptyRow","flIcon","Columns","headerCell","allowSelection","searchString","pageSizes","checkAll","dataLength","prevPageMoving","lazyLoadRender","getGroupCache","refreshContentRows","resetTemplates","detailTemplateID","toolbarTemplate","guid","refreshComplete","maskRow","enableVirtualMaskRow","isCaptionCollapse","showMaskRow","virtualInfo","sentinelInfo","isFActon","isNeedForeignAction","deffered_1","validateGroupRecords","dataManagerFailure","deferred","foreignKey","fbool","sendBulkRequest","dmSuccess","dmFailure","renderEmptyRow","isTrigger","spanCount","rowDropSettings","targetID","emptyRecordTemplate","emptyRecordTemplateID","getEmptyRecordTemplate","renderEmpty","dynamicColumnChange","updateColumnType","fmtr","validationRules","isColTypeDef","actionArgs","isInfiniteDelete","isInfiniteEnd","prevCurrentView","removeMaskRow","updatesOnInitialRender","agg","immutableModeRendering","alert","setRowElements","setRowObjects","preventAdjustColumns","setRowCount","setFirstFocusableTabIndex","dataRowCount","isEmptyCol","buildColumns","isAutoGen","iterateComplexColumns","childKeys","complexCols","instantiateRenderer","addRenderer","GroupCaption","GroupCaptionEmpty","Expand","group0","groupN","addWhere","groups","curDm","curFilter","newQuery","rPredicate","updateGroupInfo","current","untouched","uGroup","itemGroup","uGroupItem","context","customAggregate","CellRendererFactory","cellRenderMap","ServiceLocator","services","register","isAdaptiveUI","RendererFactory","rendererMap","rName","PageSettings","ColumnChooserSettings","Search","refreshSearch","onSearchComplete","actionCompleteFunc","cancelBeginEvent","ShowHide","colName","isShowHide","evtHandlers","batchChanges","resetColumnState","changedCol","showBy","getToggleFields","hideBy","finalized","getKeyBy","batchActionPrevent","changedStateColumns","groupModule","visibleRows","showHideArgs","currentViewCols","emptyVcRows","getSelectedRecords","colsInCurrentView","col1","col2","isModeChg","AggregateColumn","setPropertiesSilent","AggregateRow","Clipboard","copyContent","keyDownHandler","selectedRowCellIndexes","getSelectedRowCellIndexes","copy","clipBoardTextArea","cellSelectionMode","x_1","scrollX","y_1","paste","cellIndexes","isAvail","cIdx","rIdx","getRowByIndex","getCellFromIndex","updateCell","selectCellsByRange","cellIndex","setCopyData","withHeader","getSelection","getDataRows","selectedIndexes","headerTextArray","getCopyData","leftCols","checkBoxSelection","colIndexes","getColumnHeaderByIndex","rowIndexes","isCell","splitKey","colIdx","queryCommandSupported","execCommand","removeAllRanges","rowCellIndxes","SortDescriptor","SortSettings","Predicate","InfiniteScrollSettings","FilterSettings","SelectionSettings","SearchSettings","RowDropSettings","TextWrapSettings","ResizeSettings","GroupSettings","EditSettings","LoadingIndicator","Grid","inViewIndexes","keyA","frozenRightCount","freezeColumnRefresh","rightcount","frozenLeftCount","leftcount","tablesCount","movableCount","movablecount","fixedcount","fixedCount","visibleFrozenLeft","visibleFrozenFixed","isPreparedFrozenColumns","visibleFrozenRight","visibleMovable","frozenLeftColumns","frozenRightColumns","movableColumns","fixedColumns","stackedLeft","stackedRight","stackedFixed","stackedMovable","stackedarrayLeft","stackedarrayRight","stackedarrayFixed","stackedarrayMovable","media","tableIndex","componentRefresh","isChangeDataSourceCall","mergedColumns","isVirtualAdaptive","vRows","vcRows","vGroupOffsets","rowUid","isAutoFitColumns","enableDeepCompare","islazyloadRequest","pageTemplateChange","isAutoGenerateColumns","mediaBindInstance","asyncTimeOut","enableLogger","needsID","Grid_1","Inject","mergePersistGridData","ignoreOnPersist","selectedRowIndex","scrollPosition","currentObject","settings","assign","pagerTemplate","persistData","setFrozenCount","enableInfiniteAggrgate","allowExcelExport","allowPdfExport","sortedColumns","isCommandColumn","allowAdding","allowDeleting","extendRequiredModules","contextMenuItems","showColumnChooser","isForeignKeyEnabled","initProperties","initializeServices","isInitial","mediaCol","ignoreCollectionWatch","isPersistSelection","defaultLocale","EmptyRecord","True","False","InvalidFilterMessage","GroupDropArea","UnGroup","UnGroupButton","GroupDisable","FilterbarTitle","EmptyDataSourceError","Add","Edit","Cancel","Update","Delete","Pdfexport","Excelexport","Wordexport","Csvexport","Columnchooser","Save","Items","EditOperationAlert","DeleteOperationAlert","SaveButton","OKButton","CancelButton","EditFormTitle","AddFormTitle","BatchSaveConfirm","BatchSaveLostChanges","ConfirmDelete","CancelEdit","ChooseColumns","ColumnMenu","SearchColumns","Matchs","FilterButton","ClearButton","StartsWith","NotStartsWith","Like","EndsWith","NotEndsWith","Contains","NotContains","IsNull","NotNull","IsEmpty","IsNotEmpty","Equal","NotEqual","LessThan","LessThanOrEqual","GreaterThan","GreaterThanOrEqual","ChooseDate","EnterValue","Copy","Group","Ungroup","GroupButton","UnGroupAria","GroupSeperator","UnGroupIcon","GroupedSortIcon","GroupedDrag","CheckBoxLabel","SelectAllCheckbox","SelectRow","autoFitAll","AutoFitAll","AutoFit","Export","FirstPage","LastPage","PreviousPage","NextPage","SortAscending","SortDescending","EditRecord","DeleteRecord","FilterMenu","SelectAll","AddCurrentSelection","Blanks","FilterTrue","FilterFalse","NoResult","ClearFilter","Clear","NumberFilter","TextFilter","DateFilter","DateTimeFilter","MatchCase","Between","CustomFilter","CustomFilterPlaceHolder","CustomFilterDatePlaceHolder","AND","OR","ShowRowsWhere","ToolbarMenuDialogARIA","FilterMenuDialogARIA","ExcelFilterDialogARIA","CheckBoxFilterDialogARIA","DialogEditARIA","ColumnMenuDialogARIA","CustomFilterDialogARIA","SortAtoZ","SortZtoA","SortByOldest","SortByNewest","SortSmallestToLargest","SortLargestToSmallest","Sort","FilterDescription","SortDescription","ColumnMenuDescription","GroupDescription","ColumnHeader","TemplateCell","CommandColumnAria","DialogEdit","ClipBoard","AscendingText","DescendingText","NoneText","Expanded","Collapsed","rightArrow","leftArrow","shiftDown","shiftUp","shiftRight","shiftLeft","ctrlHome","ctrlEnd","ctrlAltPageUp","ctrlAltPageDown","altPageUp","altPageDown","ctrlDownArrow","ctrlUpArrow","ctrlPlusA","ctrlPlusP","delete","f2","ctrlEnter","shiftEnter","space","ctrlPlusC","ctrlShiftPlusH","ctrlSpace","ctrlLeftArrow","ctrlRightArrow","searchModule","updateColumnModel","getMediaColumns","setInitialFrozenColumnIndex","checkLockColumns","processModel","gridRender","addListener","updateStackedFilter","refreshMaskRow","axisDirection","dialogElement","headerModule","dialogHolder","maskRowCount","maskTemplate","getShimmerTemplate","maskSpan","paddingRight","paddingLeft","contentHeight","maskTableHeight","contentRowCount","headerMaskTable","createEmptyMaskTable","contentMaskTable","maskRowContentScroll","createMaskTable","getContentMaskColumns","gridFooterContent","footerContentMaskTable","footerContent","translateMaskRow","maskElement","gridContentScrollHeight","maskTable","maskColgroup","createMaskRow","frzTd","maskTHead","maskTBody","rowCountElement","altRow","altNumber","rowsQuery","addEditRow","addEditRowIndex","applyMaskRow","addEditMaskRow","tfoot","maskTFoot","minScrollTop","maskCells","maskCell","displayAsCheckBoxCell","refColgroup","refColumns","localTD","displayAsCheckBox","addShimmerEffect","maskTables","refreshMaskRowColgroupWidth","gcol","getShowHideService","hideAtMedia","pushMediaColumn","updateFrozenColumnsWidth","matchMedia","mediaQueryUpdate","updateMediaColumns","mediaColumn","matches","invokedFromMedia","showHider","refreshMediaCol","checkboxColumn","checkboxMode","enableHover","removeMediaListener","removeListener","eventInitializer","hasGridChild","destroyDependentModules","toolTipObj","clipboardModule","enableBoxSelection","enableAutoFill","setCSSClass","oldCSSClass","checkCursor","requireRefresh","requireGridRefresh","freezeRefresh","childGridParent","parentInstance","isEllipsisTooltip","updateColumnObject","properties_1","isCancel","updateAutoFillPosition","rowTemplateFn","emptyRecordTemplateFn","detailTemplateFn","childGridObject","currentParent","currentParentInstance","currentChildObject","oldProperties","restoreAdjustColumns","extendedPropertyChange","maintainSelection","updateRTL","getToolbar","contextMenuModule","getContextMenu","columnMenuModule","getColumnMenu","updateResizeLines","updateGridLines","columnMenuItems","applyTextWrap","removeTextWrap","pending_1","deepWatch","pKeyField","setRowData","gResult","names","scrollRefresh","isSelectedRowIndexUpdating","setWidthToTable","enableVerticalRendering","fn_1","getTablesCount","headerCells","stdHdrCell","isRecursion","updateLockableColumns","frozenName","frozenCount","leftrightColumnWidth","getFrozenLeftColumns","getFrozenRightColumns","isRefresh","inview","vLen","movable","isLeftRightFrozen","stackedHeader","individualColumn","stackedColumn","setColumnIndexesInView","getCurrentVisibleColumns","setGridHeaderContent","setGridContentTable","setGridContent","setGridHeaderTable","footerElement","getFooterContentTable","getPager","gridPager","setGridPager","getMovableRowByIndex","getFrozenRowByIndex","getRowElements","getFrozenRightRowByIndex","getRowInfo","row_2","getMovableRows","getFrozenRightRows","getAllDataRows","includeAdd","hdrTbody","freezeRows","addMovableRows","dataRows","generateDataRows","fRows","mrows","includAdd","dRows","isCollapseStateEnabled","getMovableDataRows","getAllMovableDataRows","getFrozenDataRows","getAllFrozenDataRows","getFrozenRightDataRows","getAllFrozenRightDataRows","setCellValue","rowIdx","rowuID","pkName","fieldIdx","rowObjects","selectedRow","Idx","sRow","refreshTD","columnUid","isChildGrid","refreshReactTemplateTD","childIndent","isChildRow","rowsObj","refreshGroupCaptionFooterTemplate","dataUid","headerCellRenderer","selectRowEle","fRowTr","setFrozenRowData","fTr","getMovableCellFromIndex","getFrozenRightCellFromIndex","getMovableColumnHeaderByIndex","getFrozenRightColumnHeaderByIndex","getFrozenLeftColumnHeaderByIndex","rowObject","getMovableRowsObject","getFrozenRightRowsObject","getUidByColumnField","getColumnFieldNames","columnNames","getRowTemplate","getDetailTemplate","getEditHeaderTemplate","editHeaderTemplateFn","getEditFooterTemplate","editFooterTemplateFn","getSelectedRows","selectedRecords","selectedRowIndexes","getSelectedColumnsUid","selectedColumnsIndexes","showColumns","hideColumns","getFrozenCount","getMovableColumnsCount","isAutoWidth","autoCol_1","difference_1","autoWidth_1","tWidth_1","gWidth","this_2","isPercentageWidthGrid","refreshSplitFrozenColumn","splitFrozenCount","getVisibleMovableCount","getMovableColumns","splitStackedColumns","pushStackedColumns","stackedcol","stockCol","pushallcol","text1","resetStackedColumns","headercol","gridcolumns","tempHead","firstcol","changedProperties","removeBorder","frozenLeftBorderColumns","lastVisibleLeftCol","frozenRightBorderColumns","firstVisibleRightCol","isVisibleColumns","getVisibleFrozenColumns","getVisibleFrozenColumnsCount","getVisibleFrozenCount","visibleFrozenColumns","goToPage","pageNo","sortColumn","isMultiSort","sortModule","changeDataSource","clearSorting","removeSortColumn","clearGridActions","isToggle","selectRows","selectCell","fieldname","addRecord","deleteRow","editCell","saveCell","updateRow","getBatchChanges","enableToolbarItems","recalcIndentWidth","indentWidth","headerCol","contentCol","perPixel","parentOffset","applyWidth","newWidth","resetIndentWidth","tgridWidth","getTableWidth","setMinwidthBycalculation","refreshFrozenScrollbar","reorderModule","fromIndexes","rowDragAndDropModule","refreshDataSource","disableRowDD","contentTable","disValue","autoFitColumns","fieldNames","resizeModule","resizeSettings","tableWidth","percentageWidth","unit","widthUnit","defaultIndentWidth","indentWidthUnitFormat","headerIndentCol","contentIndentCol","setProperty","tableWidthUnitFormat","indentWidthUnitFormat_1","createColumnchooser","columnChooserModule","renderColumnChooser","valueFormatterService","gCols","sCols","_loop_3","sLen","this_3","isFromGroup","showGroupedColumn","initForeignColumn","rendererFactory","createGridPopUpElement","dataReady","gridLines","getTooltipStatus","headerDivTag","htable","ctable","prevElement","elemNames","innerElement","tag","myTableDiv","mySubDiv","myTable","myTr","mytd","onKeyPressed","mouseClickHandler","dblClickHandler","tapEvent","refreshFrozenPosition","dataBoundFunction","checkEdit","dataRow","filterClear","ariaOwns","keyPress","editFormValidate","persistedData","getLocalData","mergeColumns","storedColumn","storedColumns","_loop_4","localCol","tCol","this_4","presskey","stopImmediatePropagation","collapse","elementToFocus","focusContent","addOutline","injectedModules","refreshColumns","excelExport","exportGrids","gridIds","exportMultipleExcelGrids","excelExportModule","csvExport","pdfExport","pdfExportProperties","pdfDoc","exportMultiplePdfGrids","pdfExportModule","currentGridId","currentGridInstance","exportPromise","exportedGridResults","groupColumn","groupExpandAll","expandAll","groupCollapseAll","collapseAll","clearGrouping","ungroupColumn","openColumnChooser","detailCollapseAll","detailExpandAll","clearCellSelection","clearRowSelection","selectCells","rowCellIndexes","selectRowsByRange","isContextMenuOpen","ensureModuleInjected","propertyNames","loggerModule","applyBiggerTheme","getPreviousRowData","previousRowData","hideScroll","getRowIndexByPrimaryKey","isDetailRow","pKvalue","getUserAgent","getRowUid","getRowElementByUID","rowEle","cntRows","getHiddenColumns","calculatePageSizeByParentHeight","containerHeight","pagesize","nonContentHeight","getNoncontentHeight","getSummaryValues","summaryCol","summaryData","serverExcelExport","exportGrid","serverPdfExport","serverCsvExport","include","sorted","setHeaderText","gridInput","submit","isExpanded","updateRowValue","colpending","resetFilterDlgPosition","filterDlg","callBack","batchUpdate","processRowChanges","batchAsyncUpdate","processBulkRowChanges","dataToBeUpdated","loopstring","keyField","setNewData","oldValues","bulkRefresh","deleteRowElement","out_i_1","_loop_5","this_5","_loop_6","isRowExist","this_6","renderRowElement","modelData","addRowObject","updateVisibleExpandCollapseRows","getHeight","isInteger","getFrozenRightContent","getFrozenRightHeader","getMovableHeaderTbody","getMovableContentTbody","getFrozenHeaderTbody","getFrozenLeftContentTbody","getFrozenRightHeaderTbody","getFrozenRightContentTbody","isCustom","showCustomSort","showResponsiveCustomColumnChooser","showCustomColumnChooser","showAdaptiveFilterDialog","showAdaptiveSortDialog","isColVirtualization","gridCols","gridCols_1","CHECK","FRAME","INDETERMINATE","RIPPLECHECK","RIPPLEINDETERMINATE","CheckBox","isMouseClick","clickTriggered","validCheck","changeState","isInitialize","frameSpan","indeterminate","changeEventArgs","updateVueArrayModel","labelWrap","formElem","fr","arDz","SPINICON","SPINUP","SPINDOWN","INCREMENT","DECREMENT","INTREGEXP","DECIMALSEPARATOR","COMPONENT","NUMERIC_FOCUS","HIDDENELEMENT","selectionTimeOut","NumericTextBox","isDynamicChange","numericOptions","isPrevFocused","decimalSeparator","intRegExp","isCalled","ejInstance","angularTagName","formEle","attributeName","nodeName","incrementTitle","decrementTitle","cultureInfo","initCultureInfo","initCultureFunc","updateHTMLAttrToElement","validateStep","updatePlaceholder","createWrapper","showSpinButton","spinBtnCreation","setElementWidth","changeValue","decimals","roundNumber","hiddenInput","elementPrevValue","setNumber","stepValue","currencyCode","updatedCssClassValue","getNumericValidClassList","inputObj","updateHTMLAttrToWrapper","updateDataAttribute","pro","newClass","oldClass","numericClassName","updatedClassValue","numericStyle","spinDown","spinUp","wireSpinBtnEvents","formattedValue","maximumFractionDigits","minimumFractionDigits","operation","isInteract","performAction","raiseChangeEvent","checkErrorClass","setElementValue","setSpinButton","mouseDownOnSpinner","mouseUpOnSpinner","touchMoveOnSpinner","unwireSpinBtnEvents","parsedInput","isInteraction","beforeUpdate","numericRegex","preventHandler","iOS","currentPos","prevPos","valArray","numericObject","ignoreKeyCode","prevVal","lastIndexOf","cursorPosChanged","validateDecimalOnType","parseValue","numerictextboxObj","fireFox","parsedValue","localChange","nonZeroRegex","updatedValue","correctRounding","floatExp","floatValue","floatStep","valueCount","stepCount","roundValue","precision","divide","updateCurrency","propVal","numberOfDecimals","getNumberOfDecimals","modifyText","formatNumber","serverDecimalSeparator","EXPREGEXP","decimalPart","result2","version","currentChar","isAlterNumPadDecimalChar","fractionRule","mouseWheel","rawEvent","wheelDelta","focusEventArgs","formatValue_1","blurEventArgs","focusEvent","getElementData","mouseUpClick","timeOut","touchEvent","elementFromPoint","floatLabelTypeUpdate","decrement","attrArray","validateInputType","updateSpinButton","updateClearButton","propValue","CheckBoxFilterBase","isExecuteLocal","foreignKeyQuery","filterState","isCheckboxFilterTemplate","infiniteRenderMod","infiniteInitialLoad","infiniteSearchValChange","infinitePermenantLocalData","infiniteQueryExecutionPending","infiniteSkipCnt","infiniteScrollAppendDiff","prevInfiniteScrollDirection","infiniteLoadedElem","infiniteDataCount","infiniteLocalSelectAll","localInfiniteSelectAllClicked","localInfiniteSelectionInteracted","infiniteManualSelectMaintainPred","cBoxTrue","cBoxFalse","searchHandler","searchBoxKeyUp","fpred","foreignFilter","initalPredicate","searchBoxClick","sInput","refreshCheckboxes","updateSearchIcon","sIcon","updateDataSource","infiniteUnloadParentExistPred","searchBox","inputargs","spinner","renderResponsiveFilter","dialogLabel","showMask","getListHeight","isBlanks","filterTemplateCol","filterItemTemplate","searchInput","ddlValue","caseSen","defaults","isNotEqual","itemsCnt","coll","infiniteFltrBtnHandler","generateNullValuePredicates","notifyFilterPrevEvent","addCurrSelection","existingPredicate_1","initiateFilter","isClearFilter","pred","dummyDefaults","unshift","infiniteSearchPred","firstVal","foreignQuery","parsed","predicte","addDistinct","filterChoiceCount","itemsCount","filterargs","emptyValPredicte","generatePredicate","fullData","makeInfiniteScrollRequest","filterEvent","processSearch","getPredicateFromCols","isGrid","customQuery","distincts","queryGenerate","filteredColumn","dataSuccess","infiniteScrollMouseKeyDownHandler","infiniteScrollHandler","infiniteScrollMouseKeyUpHandler","listDiv","maskItemHeight","maskList","wrapperElem","removeMask","backgroundColor","borderStyle","insertAdjacentHTML","maskLists","maskParent","infiniteRemoveElements","infiniteAppendElements","removeElem","appendElem","infiniteQuery","existQuery","runArray","executeQueryOperations","args1","processDataSource","updateResult","createFilterItems","result_1","res","selectAll","updateAllCBoxes","previousSibling","updateInfiniteManualSelectPred","updateIndeterminatenBtn","setFocus","predmdl","focusNextOrPrev","cBoxes","cBoxes_1","createCheckbox","dummyData","checkboxUid","nullCounter","selectAllValue","isColFiltered","predicateCheckBox","predicateElement","checkBoxListElem","reduceHeight","increaseHeight","isRndere","args_1","updateInfiniteUnLoadedCheckboxExistPred","getCheckedState","lastChild","selectAllParent","addCurrSelectionParent","updatePredArr","checkState","checkboxFilter","ejValue","currentFilterValue","foreignDataObj","operate","updateDateFilter","getCaseValue","bm","CellRenderer","rowChkBox","evaluate","fData","CSPTemplate","literals_1","templateID","invokeFormatter","refreshCell","newTD","cloneAttributes","arialabelText","localeStr","fromFormatter","checkWrap","rowID","isCheckBoxType","colindex","InlineEditRender","addNew","newRowPosition","getEditElement","checkLastRow","tdElement","gLen","appendChildren","isCustomFormValidation","td_1","editTemplateID","BatchEditRender","columnObject","newTd","DialogEditRender","setLocaleObj","createDialog","createDialogHeader","responsiveDlgRenderer","renderResponsiveHeader","getDialogEditTemplateElement","primaryKeyValue","allowDragging","adaptiveDlgTarget","dialogEditTemplates","templateName","dialogTemp","tempDiv","setRules","formObj","checkColumnIsGrouped","dataCell","EditRender","getEditElements","convertWidget","focusElement","isFocus","preventScroll","tArgs","isInput","isIdentity","EditCellBase","removeEventHandler","BooleanEditCell","activeClasses","classNames","selectChkBox","chkState","editRow","cbChange","checkBoxChange","DropDownEditCell","isInline","dropDownClose","editCellDialogClose","ddCreated","dropdownCreated","ddBeforeOpen","dropdownBeforeOpen","ddActionComplete","dlgElement","NumericEditCell","instances","DefaultEditCell","Event","bubbles","cancelable","NormalEdit","currentVirtualData","allowEditOnDblClick","editComplete","editRowIndex","getEditArgs","editedData","isScroll","primaryKeys","primaryKeyValues","primaryKey","virtualRow","rObj","inlineEditHandler","prevData","argsCreator","begineditargs","editargs","applyFormValidation","edFail","validationArgs","editIdx","addIdx","addedRowIndex","isDlg","dlgWrapper","dlgForm","virtualData","getCurrentEditedData","eleLength","endEditArgs","destroyElements","destroyWidgets","destroyForm","editHandler","edSucc","editSuccess","editFailure","updateCurrentViewData","requestSuccess","stopEditStatus","isLastRow","dragRow","dragRowUid","dragRowObject_1","groupedColumn","comparer1","comparer2","dropRowObject","groupedRowReorder","checkboxOnly","getGroupAggregateTemplates","closeForm","cloneRow","originalRow","cloneFrozen","frozen","needRefresh","leftrightCells","closeEditArgs","isLazyLoad","inlineAddHandler","addArgs","dataLen","tmpRecord","contained","addElements","editElements","InlineEdit","BatchEdit","cellDetails","originalCell","cloneCell","editNext","preventSaveCell","validationColObj","addBatchRow","prevEditedBatchCell","onBeforeCellFocused","onCellFocused","editNextValCell","dataBound","batchCancelFunction","batchCancel","restoreFocus","mouseDownElement","setCellIdx","isAddRow","validateFormObj","byClick","keyArgs","clickArgs","isContent","active","matrix","prevEditedBatchCellMatrix","crtRowIndex","byKey","isLastCellPrimaryKey","editCellFromIndex","isAdded","isInsert","isDirty","removeBatchElementChanges","refreshRowIdx","isInstertedRemoved","bulkDelete","bulkAddRow","batchSave","checkAllBox","removeSelectedData","beforeBatchSaveArgs","removeRowObjectFromUID","rowClone","deleteRowUid","beforeBatchDeleteArgs","uniqueid","dataObjects","visibleColumns","defaultData","getDefaultData","beforeBatchAddArgs","forgetPrevious","btmIdx","getBottomIndex","findNextEditableCell","isValOnly","validation","dValues","editCellExtend","getDataByIndex","getColIndex","getCellIdx","cellEditArgs","isColored","rowObj_1","newReactTd_1","newReactTd","setChanges","rowcell","insertedRows","isSingleInsert","escapeCellEdit","generateCellArgs","successCallBack","cloneEditedData","isForceSave","cellSaveArgs","isEscapeCellEdit","editedBatchCellMatrix","editedBatchCell","addCancelWhilePaging","ARROWLEFT","ARROWRIGHT","ARROWUP","ARROWDOWN","TAB","SHIFTTAB","END","HOME","MaskedDateTime","mask","defaultConstant","hiddenMask","validCharacters","isDayPart","isMonthPart","isYearPart","isHourPart","isMinutePart","isSecondsPart","isMilliSecondsPart","monthCharacter","periodCharacter","isHiddenMask","isComplete","navigated","isDeletion","isShortYear","isDeleteKey","isDateZero","isMonthZero","isYearZero","isLeadingZero","dayTypeCount","monthTypeCount","hourTypeCount","minuteTypeCount","secondTypeCount","dateformat","getCulturedFormat","maskDateValue","validCharacterCheck","maskInputHandler","maskKeydownHandler","maskPlaceholder","getCUltureMaskFormat","formatCheck","previousHiddenMask","setDynamicValue","objectString","validChar","navigateSelection","formatText","dateAlteration","isPersist","differenceCheck","previousVal","newVal","newDateValue","handleDeletion","monthString","getCulturedValue","monthValue","monthValue_1","previousMaxDate","currentMaxDate","yearValue","periodString","periodkeys","daysAbbreviated","dayKeyAbbreviated","daysWide","dayKeyWide","daysNarrow","dayKeyNarrow","monthAbbreviated","monthWide","zeroCheck","roundOff","hiddenChar","isbackward","formatIndex","valueText","isZero","resultValue","isSegment","isDecrement","incrementValue","newMonth","DatePickerEditCell","dateanddatetimerender","datePickerEditCell","datePickerClose","TemplateEditCell","updateEditObj","createAlertDlg","createConfirmDlg","updateColTypeObj","templteCell","editCellType","alertDObj","lastTr","refreshToolbar","showConfirmDialog","showDeleteConfirmDialog","endEditing","form1","form2","mFormObj","form3","frFormObj","getCurrentEditCellData","getValueFromType","destroyToolTip","dlgWidget","dlgOk","dlgCancel","alertClick","btnOptions","isForceCancel","executeAction","destroyEditComponents","eventDetails","preventBatch","onActionBegin","actionCompleteFunction","actions","inputs","addRow","restrictedRequestTypes","isRestrict","isDestroyVirtualForm","formObjects","virtualFormObj","curretRowFocus","focusableEditCells","commandColCell","preventObj","newRule","mRules","frRules","createFormObj","validationComplete","valErrorPlacement","getElemTable","isFHdr","resetElemPosition","tdRight","elemRight","offSet","customForm","validationForBottomRowPos","gcontent","isFHdrLastRow","isBatchModeLastRow","viewPortRowCount","fHearderRows","insertRow","inputClient","arrow","getEditCell","gHeight","rowsCount","rowsHeight","AddEditors","editors","gomDeva","weekdaysCaseReplace","nounCase","nominative","accusative","genitive","processHoursFunction","uk","ResponsiveDialogRenderer","sortedCols","sortPredicate","closeCustomDialog","refreshCustomFilterOkBtn","renderResponsiveContextMenu","renderCustomFilterDiv","customExFilterClose","refreshCustomFilterClearBtn","onActionCompleteFn","editComplate","isCustomDlgRender","customResponsiveDlg","closeBtn","saveBtn","backBtn","customExcelFilterParent","filterClearBtn","getHeaderTitle","columnMenuResponsiveContent","cDiv","customColumnDiv","renderResponsiveContent","isColumnChooser","filterParent","isColMenu","sortColumns","sortBtnParent","filteredCols","isSort","getSortedFieldsAndDirections","buttonInnerText","sortButtonClickHandler","divIcon","iconSpan","customFilterColumnClickHandler","columndiv","allowMultiSorting","isSortApplied","resetSortButtons","directionTxt","setSortedCols","getCurrentSortedFields","menuCol","filteredCol","closeCustomFilter","isRowResponsive","colDiv","isDialogClose","removeCustomDlgFilterEle","renderCustomFilterDialog","setTopToChildDialog","dialogEle","colMenu","outerDiv","customFilterDlg","getDialogOptions","beforeDialogClose","sortField","getDialogName","getButtonText","titleDiv","dialogHdrBtnClickHandler","id_1","clearBtn","removeCustomFilterElement","custommenu","mainfilterdiv","destroyCustomFilterDialog","customEle","BaseTooltip","isStockChart","enable3D","highlightPoint","accumulationSelectionModule","isSelectedElement","highlightColor","highlightPoints","clipLocation","crosshairEnabled","templatePoint","customTemplate","tooltip3DModule","accumulationTooltipModule","svgTooltip","findPalette","isNegative","enableTextWrap","updatePreviousPoint","animationComplete","findColor","toolTipInterval","NumericContainer","pagerElement","renderNumericContainer","refreshNumericLinks","updateTotalPages","links","updateLinksHtml","refreshAriaAttrLabel","updateStyles","link","frag","createDocumentFragment","auxiliaryClickHandler","numericContainer","renderFirstNPrev","renderPrevPagerSet","renderNextPagerSet","renderNextNLast","pagerContainer","prevPager","PP","nextPager","NP","previousPageNo","currentPageSet","isLastSet","numItems","isPagerResized","focusedItem","focusedorTarget","prevFocused","nextFocused","firstFocused","lastFocused","numItemFocused","npFocused","ppFocused","classList_1","isPageAvailable","customText","ppIndex","avgNumItems","NPIndex","updateFirstNPrevStyles","updatePrevPagerSetStyles","updateNextPagerSetStyles","updateNextNLastStyles","currentPageIndex","firstPage","firstPageDisabled","prevPage","prevPageDisabled","lastPage","lastPageDisabled","nextPage","nextPageDisabled","PagerMessage","pageNoMsgElem","pageCountMsgElem","regx","Pager","hasParent","pageRefresh","firstPagerFocus","enableExternalMessage","checkpagesizes","defaultConstants","currentPageInfo","totalItemsInfo","totalItemInfo","firstPageTooltip","lastPageTooltip","nextPageTooltip","previousPageTooltip","nextPagerTooltip","previousPagerTooltip","pagerDropDown","pagerAllDropDown","CurrentPageInfo","TotalItemsInfo","FirstPageTooltip","LastPageTooltip","NextPageTooltip","PreviousPageTooltip","NextPagerTooltip","PreviousPagerTooltip","PagerDropDown","PagerAllDropDown","All","Container","Information","ExternalMsg","Page","Of","Pages","containerModule","pagerMessageModule","initLocalization","isReactTemplate","renderFirstPrevDivForDevice","enablePagerMessage","renderNextLastDivForDevice","pagerdropdownModule","addAriaLabel","externalMessageModule","checkGoToPage","currentPageChanged","setDropDownValue","compile","resizePager","onFocusIn","onFocusOut","focusedTabIndexElement","getFocusedTabindexElement","dropDownPage","getDropDownPage","focusablePagerElements","getFocusablePagerElements","addFocus","focusedElement","getFocusedElement","setTabIndexForFocusLastElement","checkPagerHasFocus","changePagerFocus","setPagerFocus","setPagerContainerFocus","setPagerFocusForActiveElement","currentActivePage","offsetParent","changeFocusByShiftTab","changeFocusByTab","navigateToPageByEnterOrSpace","navigateToPageByKey","tabindexElements","currentItemPagerFocus","incrementNumber","decrementNumber","lastCell","checkFirstPagerFocus","selectedClass","getClass","classElement","getElementByClass","checkFocusInAdaptiveMode","changeFocusInAdaptiveMode","actionClass","pagingItem","mPrev","removeTabindexLastElements","tabIndexElements","dropDownPageHolder","currentClass","previousElements","targetChildrens","pagerElements","element_1","tabindexElement","addFocusClass","removeFocusClass","setPageSize","newPageNo","oldPageNo","enableQueryString","updateQueryString","getPagerTemplate","updatedUrl","getUpdatedURL","history","pushState","uri","calculateActualWidth","actualWidth","isStyleApplied","pagerWidth","hiddenNumItems","hideFrom","showFrom","bufferWidth","detailItems","totDetailWidth_1","averageDetailWidth","totalWidth","numericItemWidth","numToHide","hideIndex","pagerDetailItemsWidth","detailtoHide","hiddenDetailItems","numToShow","lesserIndexItems","greaterIndexItems","showItems","showItem","pagerDropDownDiv","dropDownDiv","defaultTextDiv","pagerCons","pageSizesModule","pageSizesArray","convertValue","dropDownListObject","onChange","isPageSizeAll","beforeValueChange","pageSizeValue","pageSizeNum","isbeforeAll","ExternalMessage","externalMessage","isInitialRender","pagerDestroy","dropDownChanged","onSelect","addAriaAttr","renderReactPagerTemplate","numericContainerNew","numericContainerDiv","previousPage","keyActions","appendToElement","handlers","complete","updateLayout","inboundChange","Selection","checkBoxState","isMultiShiftRequest","isMultiCtrlRequest","isMultiCtrlRequestCell","enableSelectMultiTouch","clearRowCheck","selectRowCheck","selectedRowState","unSelectedRowState","chkAllCollec","isCheckedOnAdd","persistSelectedData","deSelectedData","isHdrSelectAllClicked","needColumnSelection","isCancelDeSelect","isPreventCellSelect","disableUI","isPersisted","cmdKeyPressed","cellselected","isAddRowsToSelection","initialRowSelection","isPrevRowSelection","isRowDragSelected","rmtHdrChkbxClicked","isCheckboxReset","autoFillRLselection","right_bottom","bottom_left","top_right","top_left","top_bottom","top_right_bottom","top_bottom_left","top_right_left","right_bottom_left","all_border","initializeSelection","fDataUpdate","getRowObj","hidePopUp","isEditing","getCurrentBatchRecordChanges","currentRecords","selectedGroupedData","enableSimpleMultiRowSelection","addRowsToSelection","selectData","isRemoved","selectedIndex","isAvailable","prevSelectedData","isRowType","isRowSelected","activeTarget","can","rowSelectingCallBack","isCtrlPressed","isShiftPressed","previousRow","prevRowIndex","previousRowIndex","actualTarget","isHeaderCheckboxClicked","removed","clearSelectedRow","selectRowCallBack","clearRow","disableInteracted","updateRowSelection","selectRowIndex","isHeaderCheckBoxClicked","updateRowProps","getCollectionFromIndexes","selectedDataUpdate","selectedData","selectableRowIndex","isSingleSel","prevRow","isDragged","selectRowFn","selectableRowIndex_1","rowIndexes_1","isUnSelected","enableToggle","rowDeselect","addRemoveClassesForRow","clearRowCallBack","updatePersistCollection","updateCheckBoxes","getPkValue","pkField","ensureCheckboxFieldSelection","updatePersistDelete","pKey","isPresent","checkedTarget","setCheckAllState","getPrevIndexes","mouseButton","checkSelectAllClicked","clearColumnSelection","prevCIdxs","prevECIdxs","rowIndex_1","foreignKeyData_1","isRowClicked","getCheckAllStatus","updatePersistSelectedData","mRow","rowDeselectCallBack","frozenRightRow","cancl_1","isSingleDeSel","rowDeselectObj","rowInString","rowidx","rowidxex","dataTxt","isHeaderCheckBxClick","isCellType","selectedCell","isCellSelected","previousRowCell","getCellIndex","previousRowCellIndex","cellSelectingArgs","cncl","clearCell","updateCellSelection","selectedRowCellIndex","updateCellProps","stIndex","edIndex","getLastColIndex","addAttribute","cellSelectedArgs","cellSelectArgs","cellLen","addRowCellIndex","prvRowCellIndex","addCellsToSelection","hideAutoFill","cellIndexes_1","selectedCellIdx","cellDeselect","cancl","rowCellIndex","isRowAvail","selectedCells","getSelectedCellsElement","cLen","bdrElement","showHideBorders","gBRect","isCellDrag","startAFCell","endAFCell","selectLikeExcel","startDIndex","updateScrollPosition","timer1","timer2","isAutoFillSel","findNextCell","e_1","colInd","rowInd","siblingEles","nextEleInd","showAFBorders","selectLikeAutoFill","startDCellIndex","drawBorders","setFrozenBorders","bdrStr","strCell","fixedCells","firstRowIdx","firstColIdx","lastRowIdx","lastColIdx","preCell","nextCell","refreshFrozenBorders","frcBdrElement","fhBdrElement","frhBdrElement","createBorders","positionBorders","isLastCell","isFirstRow","isFirstCell","setBorders","stOff","endOff","parentOff","topOffSet","leftOffset","rightOffset","selectDirection","updateStartEndCells","mcBdrElement","mhBdrElement","applyBorders","applyBothFrozenBorders","drawAFBorders","bdrAFBottom","createAFBorders","positionAFBorders","bdrAFLeft","firstCellTop","firstCellLeft","parentRect","sTop","totalHeight","scrolloffSet","bdrAFRight","bdrAFTop","leftRemove","topRemove","hideAFBorders","createBeforeAutoFill","getAutoFillCells","startCellIdx","isApply","startrowIdx","endrowIdx","endCellIdx","rowLen","startCellIndex","trIdx","mUPTarget","closeRowCell","updateStartCellsIndex","rindex","isFrozenRow","isFrozenRight","clientRect","colWidth","enableDrag","postion","clearSelAfterRefresh","isInfiniteScroll","pkValue","rowsRemoved","addEventListener_checkbox","removeEventListener_checkbox","isMacOS","beforeFragAppend","getCheckAllBox","initPerisistSelection","prevColIndex","checkBoxSelectionChanged","gobj","chkField","proxy_1","refreshPersistSelection","setRowSelection","selectedStateKeys","unSelectedRowStateKeys","rowData_1","selectedData_1","getAvailableSelectedData","filteredSearchedSelectedData","editChkBox","onDataBound","totalRecords","checkSelectAllAction","cRenderer","editForm","getVirtualRowIndex","checkSelectAll","stateStr","updateSelectedRowIndexes","triggerChkChangeEvent","checkSelect","rIndex","rowCellSelectionHandler","moveIntoUncheckCollection","rowObj_2","rowObj_3","updateSelectedRowIndex","selectedVal","isAllSelected","isSelectAllRowCount","someDataSelected","checkToSelectAll","checkedLen","spanEle","getRecord","targetHeadCell","targetRowCell","isCheckBox","allowColumnSelection","popUpClickHandler","chkSelect","headerSelectionHandler","find","checkboxColumnIndexCheck","isJump","headerAction","thLen","getKeyColIndex","targetLabel","applyDownUpKey","applyRightLeftKey","shiftDownKey","applyShiftLeftRightKey","applyHomeEndKey","applyCtrlHomeEndKey","writeText","applySpaceSelection","allowNextRowEdit","innerColumn","getstackedColumns","lastIndex","firstIndex","applyUpDown","selectColumn","cIndex","selectColumnsByRange","innerColumnIndexes","detailIndentCell","dragdropIndentCell","selectedCol","isColSelected","isMultiColumns","clearColDependency","previousColumnIndex","updateColSelection","selectedArgs","updateColProps","selectColumns","getselectedCols","selectingArgs","selectColumnWithExisting","newCol","clearIndex","deselectedArgs","isCanceled","columnDeselect","selectedHeader","getSelectedColumnCells","isRowTemplate","seletedcells","selectionString","onDataBoundFunction","setCheckAllForEmptyGrid","actionCompleteHandler","resizeEndFn","isInfinitecroll","lo","ColumnWidthService","wFlag","totalColumnsWidth","setColumnWidth","tWidth","tmWidth","collection_1","isWidthUndefined","setUndefinedColumnWidth","cWidth","getWidth","fWidth","editTableCol","movableScrollbar","movableWidth","placeHolder","getHeightFromDirection","sibling","isWidUndefCount","isAutoResize","deAt","de","tzmLatn","jv","esMx","addScrolling","scrollType","containerOffset","contentOffset","parentElem","createScrollbar","scrollObj","ENTER","ESCAPE","FOCUSED","SEPARATOR","UPARROW","DOWNARROW","LEFTARROW","RIGHTARROW","CARET","ITEM","HIDE","TEMPLATE_PROPERTY","FieldSettings","MenuItem","MenuAnimationSettings","MenuBase","navIdx","isTapHold","showSubMenuOn","isMenu","ejInst","clonedElement","refEle","enableScrolling","hamburgerMode","createHeaderContainer","defaultOption","showItemOnClick","createJsonFromElement","removeChildElement","createItems","setBlankIconStyle","targetElems","menuHeaderClickHandler","cmenuHandler","delegateMoverHandler","moverHandler","delegateMouseDownHandler","delegateClickHandler","downarrow","uparrow","leftarrow","rightarrow","keyBoardHandler","closeMenu","actionName","actionNeeded","removeLIStateByClass","upDownKeyHandler","rightEnterKeyHandler","leftEscKeyHandler","cul","getUlByNavIdx","defaultIdx","fliIdx","fli","getLIByClass","getIdx","cli","navIdxLen","popups_1","allPopup","keyType","openMenu","aEle","sli","isCMenu","canOpen","ulIndex","isIterated","isMenuVisible","item_1","wrapper_1","beforeCloseArgs","popups","getPopups","ul_1","liElem_1","getLI","parentItem","observedCloseArgs","closeArgs","trgtliId","closedLi","trgtLi","popupId","unWireKeyboardEvent","toggleAnimation","showSubMenu","updateReactTemplate","trgtpopUp","submenus","afterCloseMenu","isMenusClosed","sli_1","cliIdx","item_2","removeStateWrapper","getMenuItemModel","getFields","lItem","elemId","uList","getField","hdata","hli","isNestedOrVertical","generatePopup","calculateIndentSize","hoverDelay","triggerBeforeOpen","targetEvent","copyObject","srcElement","liStyle","liIndent","textIndent","blankIconElem","menuIconElem","menuIconElemStyle","blankIconIndent","actionOnScroll","triggerOpen","spanElem","tempTitle","spanTitle","spanIcon","openHamburgerMenu","closeHamburgerMenu","observedHamburgerCloseArgs","callFit","menuType","observedOpenArgs","checkScrollOffset","animationOptions","easing","setPosition","eventArgs_1","collide","offWidth","blankIconList","iconLi","cssProp","iconCssProps","offsetEle","offsetRight","toggleVisiblity","newTop","xCollision","isVisible","showIcon","hasField","itemNavigable","itemCreating","curData","liTrgt","ulId","hdrWrapper","isDifferentElem","cliWrapper","isInstLI","cliWrapperId","setLISelected","culIdx","classname","getItemIndex","isUniqueId","isText","setItem","newItem","setItems","newItems","skipHdr","updateItemsByNavIdx","updateItem","ul_2","ul_3","getChangedItemIndex","insertAfter","removeItem","wrapper1","ul1","lis","popStr","uls","targetSelctor","parent_2","isMenuOpen","pUlHeight","pElement","begin","nIndex","isCallBack","skipItem","showHideItems","hideItems","ishide","validUl","iitems","insertItems","isAfter","menuitem","itemId","parentId","enSg","nn","relativeTimeWithSingular","relativeSeconds","lv","deCh","StackedColumnsDirective","StackedColumnsPlugin","StackedColumnDirective","StackedColumnPlugin","AggregateColumnsDirective","AggregateColumnsPlugin","AggregateColumnDirective","AggregateColumnPlugin","AggregatesDirective","AggregatesPlugin","AggregateDirective","AggregatePlugin","GridComponent","GridPlugin","tzm","hookCallback","hooks","setHookCallback","callback","isObject","hasOwnProp","isObjectEmpty","getOwnPropertyNames","isUndefined","isNumber","isDate","arrLen","extend","createUTC","strict","createLocalOrUTC","utc","defaultParsingFlags","empty","unusedTokens","unusedInput","charsLeftOver","nullInput","invalidEra","invalidMonth","invalidFormat","userInvalidated","iso","parsedDateParts","era","rfc2822","weekdayMismatch","getParsingFlags","_pf","_isValid","flags","parsedParts","isNowValid","invalidWeekday","_strict","bigHour","createInvalid","fun","t","momentProperties","updateInProgress","copyConfig","momentPropertiesLen","_isAMomentObject","_l","_tzm","_isUTC","_offset","_locale","Moment","updateOffset","isMoment","warn","msg","suppressDeprecationWarnings","console","firstTime","deprecationHandler","argLen","stack","deprecations","deprecateSimple","_config","_dayOfMonthOrdinalParseLenient","_dayOfMonthOrdinalParse","_ordinalParse","mergeConfigs","parentConfig","childConfig","Locale","defaultCalendar","_calendar","zeroFill","targetLength","forceSign","absNumber","zerosToFill","sign","formattingTokens","localFormattingTokens","formatFunctions","formatTokenFunctions","addFormatToken","padded","func","localeData","removeFormattingTokens","makeFormatFunction","formatMoment","expandFormat","replaceLongDateFormatTokens","defaultLongDateFormat","_longDateFormat","formatUpper","tok","defaultInvalidDate","_invalidDate","defaultOrdinal","defaultDayOfMonthOrdinalParse","_ordinal","defaultRelativeTime","_relativeTime","pastFuture","aliases","addUnitAlias","shorthand","lowerCase","normalizeUnits","normalizeObjectUnits","normalizedProp","normalizedInput","priorities","addUnitPriority","priority","getPrioritizedUnits","unitsObj","absFloor","toInt","argumentForCoercion","coercedNumber","isFinite","makeGetSet","keepTime","set$1","daysInMonth","stringGet","stringSet","prioritized","prioritizedLen","regexes","match1","match2","match3","match4","match6","match1to2","match3to4","match5to6","match1to3","match1to4","match1to6","matchUnsigned","matchSigned","matchOffset","matchShortOffset","matchTimestamp","matchWord","addRegexToken","strictRegex","isStrict","getParseRegexForToken","unescapeFormat","regexEscape","matched","tokens","addParseToken","tokenLen","addWeekParseToken","_w","addTimeToArrayFromToken","DATE","WEEK","WEEKDAY","mod","modMonth","defaultLocaleMonths","defaultLocaleMonthsShort","MONTHS_IN_FORMAT","defaultMonthsShortRegex","defaultMonthsRegex","localeMonths","_months","localeMonthsShort","_monthsShort","handleStrictParse","monthName","ii","llc","toLocaleLowerCase","_monthsParse","_longMonthsParse","_shortMonthsParse","localeMonthsParse","_monthsParseExact","dayOfMonth","getSetMonth","getDaysInMonth","computeMonthsParse","_monthsShortStrictRegex","_monthsShortRegex","_monthsStrictRegex","_monthsRegex","cmpLenRev","shortPieces","longPieces","mixedPieces","daysInYear","parseTwoDigitYear","getSetYear","getIsLeapYear","createDate","ms","createUTCDate","UTC","setUTCFullYear","firstWeekOffset","fwd","fwdlw","getUTCDay","dayOfYearFromWeeks","weekday","resYear","resDayOfYear","localWeekday","weekOffset","dayOfYear","weekOfYear","resWeek","weeksInYear","weekOffsetNext","localeWeek","_week","defaultLocaleWeek","localeFirstDayOfWeek","localeFirstDayOfYear","getSetWeek","getSetISOWeek","parseWeekday","parseIsoWeekday","shiftWeekdays","ws","weekdaysMinRegex","weekdaysShortRegex","weekdaysRegex","defaultLocaleWeekdays","defaultLocaleWeekdaysShort","defaultLocaleWeekdaysMin","defaultWeekdaysRegex","defaultWeekdaysShortRegex","defaultWeekdaysMinRegex","localeWeekdays","_weekdays","localeWeekdaysShort","_weekdaysShort","localeWeekdaysMin","_weekdaysMin","handleStrictParse$1","weekdayName","_weekdaysParse","_shortWeekdaysParse","_minWeekdaysParse","localeWeekdaysParse","_weekdaysParseExact","_fullWeekdaysParse","getSetDayOfWeek","getSetLocaleDayOfWeek","getSetISODayOfWeek","computeWeekdaysParse","_weekdaysStrictRegex","_weekdaysRegex","_weekdaysShortStrictRegex","_weekdaysShortRegex","_weekdaysMinStrictRegex","_weekdaysMinRegex","minp","shortp","longp","minPieces","hFormat","kFormat","lowercase","matchMeridiem","_meridiemParse","localeIsPM","kInput","_isPm","_meridiem","pos1","pos2","defaultLocaleMeridiemParse","getSetHour","localeMeridiem","globalLocale","baseConfig","locales","localeFamilies","commonPrefix","arr1","arr2","minl","normalizeLocale","chooseLocale","loadLocale","isLocaleNameSane","oldLocale","_abbr","require","getSetGlobalLocale","getLocale","parentLocale","updateLocale","tmpLocale","listLocales","_overflowDayOfYear","_overflowWeeks","_overflowWeekday","extendedIsoRegex","basicIsoRegex","tzRegex","isoDates","isoTimes","aspNetJsonRegex","obsOffsets","UT","GMT","EDT","EST","CDT","CST","MDT","MST","PDT","PST","configFromISO","allowTime","tzFormat","isoDatesLen","isoTimesLen","configFromStringAndFormat","extractFromRFC2822Strings","yearStr","monthStr","dayStr","hourStr","minuteStr","secondStr","untruncateYear","preprocessRFC2822","checkWeekday","weekdayStr","weekdayProvided","weekdayActual","calculateOffset","obsOffset","militaryOffset","numOffset","configFromRFC2822","parsedArray","setUTCMinutes","getUTCMinutes","configFromString","createFromInputFallback","currentDateArray","nowValue","_useUTC","getUTCMonth","getUTCDate","configFromArray","expectedWeekday","yearToUse","dayOfYearFromWeekInfo","_dayOfYear","_nextDay","weekYear","weekdayOverflow","curWeek","GG","W","E","createLocal","gg","ISO_8601","RFC_2822","skipped","stringLength","totalParsedInputLength","meridiemFixWrap","erasConvertYear","isPm","configFromStringAndArray","tempConfig","bestMoment","scoreToBeat","currentScore","validFormatFound","bestFormatIsValid","configfLen","score","configFromObject","dayOrDate","createFromConfig","prepareConfig","configFromInput","isUTC","prototypeMin","other","prototypeMax","pickBy","moments","ordering","isDurationValid","unitHasDecimal","orderLen","isValid$1","createInvalid$1","createDuration","Duration","years","quarters","quarter","weeks","isoWeek","_milliseconds","_days","_data","_bubble","isDuration","absRound","compareArrays","array1","array2","dontConvert","lengthDiff","diffs","utcOffset","offsetFromString","chunkOffset","matcher","chunk","cloneWithOffset","local","getDateOffset","getSetOffset","keepLocalTime","keepMinutes","localAdjust","_changeInProgress","addSubtract","getSetZone","setOffsetToUTC","setOffsetToLocal","subtract","setOffsetToParsedOffset","tZone","hasAlignedHourOffset","isDaylightSavingTime","isDaylightSavingTimeShifted","_isDSTShifted","toArray","isLocal","isUtcOffset","isUtc","aspNetRegex","isoRegex","ret","diffRes","parseIso","momentsDifference","inp","positiveMomentsDifference","isBefore","createAdder","dur","isAdding","isString","isMomentInput","isNumberOrStringArray","isMomentInputObject","objectTest","propertyTest","propertyLen","arrayTest","dataTypeTest","isCalendarSpec","getCalendarFormat","myMoment","calendar$1","sod","startOf","calendarFormat","localInput","endOf","isBetween","inclusivity","localFrom","localTo","isSame","inputMs","isSameOrAfter","isSameOrBefore","asFloat","that","zoneDelta","monthDiff","anchor2","adjust","wholeMonthDiff","keepOffset","toDate","inspect","suffix","zone","inputString","defaultFormatUtc","defaultFormat","humanize","fromNow","toNow","newLocaleData","lang","MS_PER_SECOND","MS_PER_MINUTE","MS_PER_HOUR","MS_PER_400_YEARS","mod$1","dividend","divisor","localStartOfDate","utcStartOfDate","startOfDate","isoWeekday","unix","toObject","isValid$2","parsingFlags","invalidAt","creationData","localeEras","_eras","localeErasParse","eraName","localeErasConvertYear","dir","getEraName","getEraNarrow","getEraAbbr","getEraYear","erasNameRegex","computeErasParse","_erasNameRegex","_erasRegex","erasAbbrRegex","_erasAbbrRegex","erasNarrowRegex","_erasNarrowRegex","matchEraAbbr","matchEraName","matchEraNarrow","matchEraYearOrdinal","_eraYearOrdinalRegex","abbrPieces","namePieces","narrowPieces","addWeekYearFormatToken","getter","getSetWeekYear","getSetWeekYearHelper","getSetISOWeekYear","getISOWeeksInYear","getISOWeeksInISOWeekYear","isoWeekYear","getWeeksInYear","weekInfo","getWeeksInWeekYear","weeksTarget","setWeekAll","dayOfYearData","getSetQuarter","erasParse","getSetDayOfMonth","getSetDayOfYear","getSetMinute","getSetMillisecond","getSetSecond","parseMs","getZoneAbbr","getZoneName","proto","createUnix","createInZone","parseZone","preParsePostFormat","Symbol","eraNarrow","eraAbbr","eraYear","isoWeeks","weeksInWeekYear","isoWeeksInYear","isoWeeksInISOWeekYear","isDST","zoneAbbr","zoneName","isDSTShifted","proto$1","get$1","setter","listMonthsImpl","out","listWeekdaysImpl","localeSorted","listMonths","listMonthsShort","listWeekdays","listWeekdaysShort","listWeekdaysMin","firstDayOfYear","langData","mathAbs","addSubtract$1","add$1","subtract$1","absCeil","bubble","monthsFromDays","monthsToDays","daysToMonths","as","valueOf$1","makeAs","alias","asMilliseconds","asSeconds","asMinutes","asHours","asDays","asWeeks","asMonths","asQuarters","asYears","clone$1","get$2","makeGetter","thresholds","substituteTimeAgo","relativeTime$1","posNegDuration","getSetRelativeTimeRounding","roundingFunction","getSetRelativeTimeThreshold","argWithSuffix","argThresholds","withSuffix","abs$1","toISOString$1","totalSign","ymSign","daysSign","hmsSign","total","proto$2","toIsoString","relativeTimeRounding","relativeTimeThreshold","HTML5_FMT","DATETIME_LOCAL","DATETIME_LOCAL_SECONDS","DATETIME_LOCAL_MS","TIME","TIME_SECONDS","TIME_MS","DateTime","POSITIVE_INFINITY","NEGATIVE_INFINITY","datetimeInterval","getYear","getHour","endMinute","endSecond","endYear","endMonth","endDay","endHour","increaseDateTimeInterval","axisLabels","alignRangeStart","blazorCustomFormat","skeletonType","actualInterval","getDecimalInterval","sDate","intervalSize","sResult","decimalValue","sec","milliSec","FocusStrategy","oneTime","swap","forget","skipFocus","focusByClick","firstHeaderCellClick","prevIndexes","refMatrix","refreshMatrix","isVirtualScroll","rowModelGen","focusCheck","setActive","enableHeaderFocus","generate","validator","passiveFocus","firstHeaderCellIndex","skipAction","onBlur","isGantt","setLastContentCellTabIndex","focusableGroupedItems","getFocusableGroupedItems","toolbarElement","focusableToolbarItems","getFocusableToolbarItems","force","beforeArgs","clearOutline","handleFilterNavigation","inputSelector","buttonSelector","allowToPaging","lastHeaderCellIndex","isValidBatchEditCell","findBatchEditCell","parentCell","skipOn","setLastContentCellActive","focusOutFromChildGrid","focusFirstHeaderCell","activeKey","bValue","prevBatchValue","outline","swapInfo","jump","toHeader","getNextCurrent","setActiveByKey","lastIdxCell","nextHeaderCellIndex","firstContentCellIndex","previousCellIndex","focusOutFromHeader","cellColIndex","cellCol","limitRow","tempCellIndex","cellIndexObtain","prevTempCellIndex","lastContentCellIndex","parentTable","parentGrid","parentRows","parentRowIndex","nextFocusCell","rowCells","inputTarget","focusVirtualElement","isKeyFocus","setFocusedElement","getFocusInfo","cellElem","focusHeader","resetFocus","getInfo","focusedColumnUid","ContentFocus","HeaderFocus","cFocus","frozenRow","batchLen","matrixcs","hdrLen","handlerInstance","cellPosition","gridPosition","passiveHandler","filterfocus","restoreFocusWithAction","internalCellFocus","groupSortFocus","groupTextFocus","groupCancelFocus","toFrozen","focusEle","getFocusable","Matrix","allow","emptyTable","inValid","vector","columnsCount","rowColumns","currentColumnCount","indexesByKey","navigators","getCurrentFromAction","editNextRow","visibleIndex","shouldFocusChange","rN","cN","oRowIndex","oCellIndex","nextRowFocusValidate","previousRowFocusValidate","enterFrozen","headerSwap","isHeaderFocus","optionals","defaultLen","isData","isCellWidth","getGridSeletion","current1","checkFilterColumn","getHeaderType","SearchBox","searchFocus","searchBlur","he","PrintUtils","printWindow","htmlContent","getHTMLContent","actualBackgroundColor","isSVG","sq","Connector","titleBorder","titleSettings","Location","Offset","ChartArea","Margin","ContainerPadding","Indexes","CornerRadius","Index","EmptyPointSettings","DragSettings","TooltipSettings","CenterLabel","StockTooltipSettings","Periods","PeriodSelectorSettings","Double","isStacking","actualDesiredIntervalsCount","niceInterval","isAutoIntervalOnBothAxis","minInterval","currentInterval","enableAutoIntervalOnZooming","paddingInterval","maxPointLength","yAxisRange","findMinMax","findAdditional","findNormal","updateActualRange","remaining","duplicateTempInterval","isPolarRadar","intervalDigits","formatDigits","formatValue","labelValue","rowDataBound","queryCellInfo","headerCellInfo","rowSelecting","rowSelected","rowDeselecting","rowDeselected","cellSelecting","cellSelected","cellDeselecting","cellDeselected","columnSelecting","columnSelected","columnDeselecting","columnDeselected","columnDragStart","columnDrag","columnDrop","rowDragStartHelper","rowDragStart","rowDrag","rowDrop","printComplete","detailDataBound","batchAdd","batchDelete","beforeBatchAdd","beforeBatchDelete","beforeBatchSave","beginEdit","cellEdit","cellSave","cellSaved","recordDoubleClick","recordClick","beforeOpenColumnChooser","beforeOpenAdaptiveDialog","resizeStart","onResize","resizeStop","beforeCopy","beforePaste","beforeAutoFill","filterChoiceRequest","filterAfterOpen","filterBeforeOpen","filterSearchBegin","exportGroupCaption","uiUpdate","inBoundModelChanged","modelChanged","colGroupRefresh","headerRefreshed","pageComplete","sortComplete","filterComplete","searchComplete","reorderComplete","rowDragAndDropComplete","groupComplete","ungroupComplete","groupAggregates","refreshFooterRenderer","refreshAggregateCell","refreshAggregates","rowSelectionComplete","cellSelectionComplete","beforeCellFocused","cellFocused","keyPressed","columnVisibilityChanged","columnWidthChanged","rowsAdded","columnDragStop","dataSourceModified","dblclick","toolbarRefresh","bulkSave","autoCol","tooltipDestroy","saveComplete","deleteComplete","dialogDestroy","crudAction","addDeleteAction","doubleTap","beforeExcelExport","excelQueryCellInfo","excelHeaderQueryCellInfo","exportDetailDataBound","exportDetailTemplate","freezeRender","columnMenuClick","columnMenuOpen","filterOpen","filterDialogCreated","initForeignKeyColumn","showEmptyGrid","columnDataStateChange","dataStateChange","dataSourceChanged","rtlUpdated","textWrapRefresh","recordAdded","cancelBegin","expandChildGrid","printGridInit","exportRowDataBound","exportDataBound","rowPositionChanged","columnChooserOpened","batchForm","beforeStartEdit","beforeBatchCancel","batchEditFormRendered","partialRefresh","beforeCustomFilterOpen","selectVirtualRow","columnsPrepared","cBoxFltrBegin","cBoxFltrComplete","fltrPrevent","beforeFltrcMenuOpen","valCustomPlacement","filterCboxValue","detailIndentCellInfo","virtaulCellFocus","virtualScrollEditActionBegin","virtualScrollEditSuccess","virtualScrollEditCancel","virtualScrollEdit","refreshVirtualCache","editReset","virtualScrollAddActionBegin","getVirtualData","refreshInfiniteModeBlocks","resetInfiniteBlocks","infinitePageQuery","infiniteShowHide","appendInfiniteContent","removeInfiniteRows","setInfiniteCache","infiniteEditHandler","initialCollapse","closeFilterDialog","columnChooserCancelBtnClick","getFilterBarOperator","resetColumns","excelAggregateQueryCellInfo","setGroupCache","lazyLoadScrollHandler","groupCollapse","beforeCheckboxRenderer","refreshHandlers","refreshFrozenColumns","setReorderDestinationElement","setFreezeSelection","beforeRefreshOnDataChange","immutableBatchCancel","checkScrollReset","preventFrozenScrollRefresh","nextCellIndex","refreshInfiniteCurrentViewData","filterDialogClose","renderResponsiveCmenu","filterCmenuSelect","customFilterClose","refreshExpandandCollapse","rowModeChange","enterKeyHandler","refreshVirtualMaxPage","setVirtualPageQuery","pagerRefresh","closeInline","resetVirtualFocus","beforeCheckboxRendererQuery","createVirtualValidationForm","validateVirtualForm","destroyChildGrid","stickyScrollComplete","captionActionComplete","refreshInfinitePersistSelection","refreshInfiniteEditrowindex","afterFilterColumnMenuClose","beforeCheckboxfilterRenderer","commandColumnDestroy","batchCnfrmDlgCancel","refreshResizePosition","renderResponsiveColumnChooserDiv","sr","tzl","numbersNouns","translateFuture","translatePast","numberNoun","numberAsNoun","hundred","ten","one","tlh","ContentRender","movableRows","freezeRowElements","isLoaded","infiniteCache","visibleFrozenRows","rightFreezeRows","isAddRows","isInfiniteFreeze","useGroupCache","tempFreezeRows","rafCallback","setRowsInLazyGroup","maxBlock","maxBlocks","rowElements","startIdx","generator","getModelGenerator","pressedKey","renderHorizontalScrollbar","scrollbarHeight","setScrollbarHeight","virtualTable","virtualTrack","createContentTable","initializeContentDrop","currentMovableRows","initialPageRecords","refFrag","refHdrfrag","hdrfrag","trElement","tbdy","isGroupFrozenHdr","checkCache","isFrozenLeft","templatetoclear","templates","updateVirtualCells","blockLoad","offsets","offsets_1","bSize","isEndBlock","blockIndexes","contentPanel","isVFFrozenOnly","bIndex","mhdrData","vgenerator","virtualFrozenHdrRefresh","refRowsObj","setInfiniteVisibleRows","getBlockSize","rowTemplateID","isTR","isVFreorder","ensureFrozenHeaderRender","ensureVirtualFrozenHeaderRender","headerCellHeight","cellHeight","boxSizing","maintainRows","initialGroupRows","getCurrentBlockInfiniteRecords","getReorderedRows","getReorderedFrozenRows","fhdrData","getInfiniteRows","getInfiniteMovableRows","infiniteCacheRows","infiniteRows","testRow","needFullRefresh","infiniteData","infiniteRowVisibility","contentrows","setDisplayNone","isFreeze","getHeaderColGroup","canSkip","getInfiniteRowIndex","firstRowIndex","oldKeys","newKeys","newRowObjs","oldIndexes","oldRowObjs","batchChangeKeys","getBatchEditedRecords","newIndexes","hasBatch","oldRowElements","trs","currentLen","oldIndex","refreshImmutableContent","isEqual","objectEqualityChecker","setRowValue","old","updateCellIndex","bo","ptBr","GroupModelGenerator","infiniteChildCount","renderInfiniteAgg","summaryModelGen","getGroupedRecords","ensureRowVisibility","parentid","childId","preCaption","captionRow","generateCaptionRow","getPreCaption","isRenderAggregate","rowCnt","aggregatesCount","setInfiniteRowVisibility","preCap","getCaptionRowCells","visibles","groupedLen","generateIndentCell","captionCells","cIndex_1","tmpFlag","childID","childGid","gSummary","fkValue","cRow","childRow","fil","hyAm","Theme","getSeriesColor","getThemeColor","canvas","darkBackground","axisLabel","axisTitle","chartTitle","legendLabel","crosshairLine","crosshairFill","crosshairLabel","selectionCircleStroke","bearFillColor","bullFillColor","datalabelFont","crosshairLabelFont","histogram","stockEventFont","ca","doesImplementInterface","checkFor","getUpdateUsingRaf","updateFunction","isExportColumns","updateColumnTypeForExportColumns","exportColumns","updatecloneRow","nRows","actualRows","getCollapsedRowsCount","dataRowCnt","agrCnt","gLevel","recursive","rCount","nLevel","iterateArrayOrObject","iterateExtend","getActualProperties","templateCompiler","validSelector","setStyleAndAttributes","copyAttr","literals","exclude","moved","setColumnIndex","ind","prepareColumns","autoWidth","setCssInGridPopUp","popUp","popUpSpan","isBottomTail","getPopupLeftPosition","parentsUntil","isID","getElementIndex","inArray","getActualPropFromColl","getUid","calculateAggregate","Global","divNode","isComplexField","getComplexFieldID","getParsedFieldID","setComplexFieldID","isEditable","isOldRow","inst","clName","addRemoveActiveClasses","distinctStringValues","getFilterMenuPostion","elementVisible","dlgWidth","getZIndexCalcualtion","toogleCheckbox","setChecked","createCboxWithWrap","removeAddCboxClasses","refreshForeignData","getForeignData","lValue","fField","fdata","getDatePredicate","getColumnByForeignKeyValue","padZero","filterObject","datePredicate","nextDate","prevObj","nextObj","predicateSt","predicateEnd","dateOnlyString","isGroupAdaptive","object","splits","newCase","getCustomDateFormat","formatvalue","getExpandedState","printMode","getPrintGridModel","printGridModel","extendObjWithFn","deep","obj1","getPrototypesOfObj","cpy","cln","measureColumnDepth","checkDepth","indices","refreshFilteredColsUid","getColumnModelByFieldName","transformV","replacedTv","rootElement","getScrollWidth","resetColspanGroupCaption","gridWidth","groupCaptionRowLeftRightPos","applyStickyLeftRightPosition","newColspan","ispercentageWidth","percentageCol","undefinedWidthCol","resetRowIndex","rowElms","startRowIndex","compareChanges","newArray","isChildColumn","uids","pushuid","frozenDirection","addFixedColumnBorder","addStickyColumnPosition","getCellsByTableName","getCellByColAndRowIndex","setValidationRuels","patternRegex","mtch_1","'","addBiggerDialog","dialogs","performComplexDataOperation","returnObj","duplicateMap","setDisplayValue","addRemoveEventListener","isOn","evt_1","createEditElement","registerEventHandlers","evts","removeEventHandlers","clearReactVueTemplates","generateExpandPredicates","filterCols","getPredicates","findCellIndex","checkActiveMatrix","checkCellIndex","activeMatrix","currentCellIndexPass","capitalizeFirstLetter","isDescending","sortData","isBreakLabel","getVisiblePoints","rotateTextSize","labelText","box","angleInRadians","rotatedTextWidth","rotatedTextHeight","areaWidth","inside","withIn","logWithIn","withInRange","nextPoint","mX2","mX1","mX3","xStart","xEnd","values_1","subtractThickness","thickness","degreeToLocation","center","radian","ChartLocation","degreeToRadian","getRotatedRectangleCoordinates","actualPoints","coordinatesAfterRotation","tempX","tempY","rotatedX","rotatedY","isRotatedRectIntersect","minA","maxA","projected","i1","minB","maxB","polygons","i2","normal","getAccumulationLegend","cartesianlarge","cartesiansmall","valueToCoefficient","TransformToVisible","CoefficientToVector","valueToPolarCoefficient","coefficient","Mean","verticalStandardMean","verticalSquareRoot","horizontalStandardMean","horizontalSquareRoot","verticalMean","horizontalMean","PolarArc","createZoomingLabels","chartRect","findCrosshairDirection","withInBounds","getValueXByPoint","actualValue","getValueYByPoint","findClipRect","firstToLowerCase","getMinPointsDelta","xValues","seriesMin","minDelta","stackingGroups","getAnimationFunction","linear","markerAnimate","animateRectElement","currentRect","pathAnimation","animateDuration","currentDireciton","startDirections","splitDirections","endDirections","endPath","directions","appendClipElement","clipElement","redrawElement","triggerLabelRender","isLineBreakLabels","text_1","lineBreakLabelTrim","maximumLabelWidth","textTrim","setRange","isZoomSet","getActualDesiredIntervalsCount","desiredIntervalsCount","maximumLabels","templateAnimate","chartRenderer","drawElement","sizeBullet","targetWidth","lx","ly","calculateLegendShapes","getRectLocation","outerRect","minMax","getTemplateFunction","accReactTemplate","datalabelGroup","accumulationDataLabelModule","calculateLabelSize","chartReactTemplate","calculateTemplateLabelSize","dataLabelId","tempObject","templateId","elementData","reactCallback","getFontStyle","measureElementRect","isReactCallback","findlElement","getPoint","yLength","locationX","locationY","appendElement","appendChildElement","isAnimate","forceAnimate","isRect","scatterElement","existChild","animateRedrawElement","median","upperQuartile","lowerQuartile","liers","isCollide","isOverlap","calculateRect","convertToHexCode","componentToHex","hex","convertHexToColor","ColorValue","colorNameToHex","exp","isRGBValue","checkColorFormat","getSaturationColor","colorCode","rgb","applyZLight","RGB","textLength","labelCollection","breakLabels","stringToNumber","containerSize","isDiv","isMinus","isDataLabelWrap","dx","calculateSize","containerWidth","marginHeight","tooltipSpace","periodHeight","periodSelectorSettings","periods","enableGrouping","disableRangeSelector","scaleValue","selectorObject","getTitle","textWrap","titlePositionX","maximumWidth","wrapAnyWhere","textWrapAnyWhere","getUnicodeText","regexp","digit","digitSpecific","convertedText","unicodeSub","unicodeSup","blazorTemplatesReset","StackValues","RectOption","ImageOption","CircleOption","PolygonOption","Thickness","LabelLocation","PointData","ControlPoints","AccPointData","Point3D","controlPoint1","controlPoint2","getColorByValue","rbgColorValue","getGradientColor","midColor","previousColor","nextColor","previousOffset","nextOffset","percent","splitColorValueOffset","splitColor","getPercentageColor","prevColor","getPercentage","getTextAnchor","frCa","nlBe","hi","CellMergeRender","targetCell_1","colSpanLen","colSpanRange","spanText","containsKey","backupMergeCells","setMergeCells","generteKey","fname","getMergeCells","mCells","merge","getIndexFromAllColumns","vColumnIndices","predefinedItems","isSearched","isRightToolbarMenu","gridID","preItems","isAdaptive","excludingItems","preItems_1","itemStr","localeName","isResponsiveToolbarMenuItems","responsiveToolbarItems","ColumnChooser","responsiveFilter","responsiveSort","responsiveBack","createToolbar","responsiveToolbarMenu","renderResponsiveToolbarpopup","addReactToolbarPortals","bindSearchEvents","searchElement","refreshToolbarItems","updateSearchBox","toolbarCreated","isNormal","clicked","toolbarClickHandler","viewStr","registerTemp","ID","renderResponsiveSearch","refreshResponsiveToolbarItems","isSearch","searchBoxObj","disableItems","hasData","getItemObject","toolbarItems_1","itemObject","gID","openResponsiveToolbarMenuPopup","newArgs","toolbarargs","tarElement","targetEle","toolbarMenuElement","getMenuItems","toolbarItems_2","getLocaleText","ResponsiveToolbarMenuItemClick","setFocusToolbarItem","getFocusToolbarElements","getFocusToolbarItems","keyPressedHandler","targetParent","reRenderToolbar","removeResponsiveSearch","rowSelectedFunction","rowDeSelectedFunction","gu","CONTROL_WRAPPER","INPUT_WRAPPER","DROP_AREA","DROP_WRAPPER","LIST_PARENT","FILE","STATUS","ACTION_BUTTONS","UPLOAD_BUTTONS","CLEAR_BUTTONS","FILE_NAME","FILE_TYPE","FILE_SIZE","REMOVE_ICON","DELETE_ICON","SPINNER_PANE","ABORT_ICON","RETRY_ICON","DRAG_HOVER","PROGRESS_WRAPPER","PROGRESSBAR","PROGRESSBAR_TEXT","UPLOAD_INPROGRESS","UPLOAD_SUCCESS","UPLOAD_FAILED","TEXT_CONTAINER","VALIDATION_FAILS","RTL_CONTAINER","ICON_FOCUSED","PROGRESS_INNER_WRAPPER","PAUSE_UPLOAD","RESUME_UPLOAD","RESTRICT_RETRY","wrapperAttr","FORM_UPLOAD","HIDDEN_INPUT","INVALID_FILE","INFORMATION","FilesProp","ButtonsProps","AsyncSettings","Uploader","initialAttr","multiple","uploadedFilesData","isForm","allTypes","pausedData","uploadMetaData","btnTabIndex","disableKeyboardNavigation","actionCompleteCount","selectedFiles","uploaderName","fileStreams","newFileRef","isFirstFileOnSelection","dragCounter","fileList","filesData","uploaderOptions","setExtensions","allowedExtensions","setControlStatus","setMultipleSelection","setRTL","reRenderFileList","browse","upload","renderButtonTemplates","unBindDropEvents","updateDropArea","checkHTMLAttributes","renderPreLoadFiles","updateDirectoryAttributes","setLocalizedTexts","preLocaleObj","browseButton","localizedTexts","uploadWrapper","updateFileList","getKeyValue","keyValue","autoUpload","uploadButton","listParent","internalCreateFileList","actionButtons","removeActionButtons","renderActionButtons","checkActionButtonStatus","Browse","Upload","invalidFileName","dropFilesHint","invalidMaxFileSize","invalidMinFileSize","invalidFileType","uploadFailedMessage","uploadSuccessMessage","removedSuccessMessage","removedFailedMessage","inProgress","readyToUploadMessage","pauseUpload","pause","resume","retry","fileUploadCancel","invalidFileSelection","totalFiles","formRendered","isPureReactComponent","directoryUpload","renderBrowseButton","initializeUpload","isPreloadFiles","wireActionButtonEvents","serverActionButtonsEventBind","unwireActionButtonEvents","uploadButtonClick","clearButtonClick","uploadText","clearText","dropAreaWrapper","setDropArea","clearData","files_1","fileData","rawFile","validationMessages","minSize","maxSize","statusCode","allowUpload","showFileList","sequentialUpload","dropTextArea","dropArea","dropZoneElement","enableDropText","createDropTextHint","bindDropEvents","fileDropArea","uploadStyle","newAttr","createAttribute","setAttributeNode","checkAutoUpload","sequenceUpload","isFileListCreated","updatedOldCssClass","browseButtonClick","onSelectFiles","resetForm","metaData","getCurrentMetaData","abortUpload","resumeUpload","chunkUpload","removeFiles","fileInfo","targetMetaData","dragHover","onDragLeave","onPasteFile","onDragEnter","dropEffect","dataTransfer","clipboardData","pasteFile","kind","renderSelectedFiles","getAsFile","getSelectedFiles","liElement","allFiles","getFilesData","nameElements","formUpload","isFormUpload","getFilesInArray","spinnerTarget","uploadSequential","checkActionComplete","removeFilesData","getLiElement","removeUploadedFile","removeDirectly","ajax","asyncSettings","removeUrl","emitError","formData","FormData","beforeSend","currentRequest","httpRequest","removingEventCallback","onLoad","removeCompleted","onError","removeFailed","send","postRawFile","updateFormData","customFormData","customData","updateCustomheader","request","setRequestHeader","response","getResponse","readyState","updateStatus","statusElement","getFilesFromFolder","filesEntries","validDirectoryUpload","checkDirectoryUpload","webkitGetAsEntry","isFile","files_2","fileObj","fullPath","traverseFileTree","directoryReader","createReader","readFileFromDirectory","readEntries","entries","pushFilesEntries","targetFiles","sortFilesList","sortFileList","getBase64","fileReader","readAsDataURL","onerror","directory","isModified","modifiedFilesData","progressInterval","updateInitialFileDetails","sanitizeFile","beforeSanitize","sanitizeFileName","serializeValue","currentFileName","isUTF8","htmlTagRegex","hasHTMLString","encodedFileName","checkExtension","_internalRenderSelect","getFileType","webkitRelativePath","fileDetails","validatedFileSize","fileSource","dataFiles","updateSortedFileList","allowFormUpload","saveUrl","singleUpload","previousListClone","added","oldList","createParentUL","isBlank","dropFiles","extensions","extensions_1","extension","fileSize","minSizeError","maxSizeError","minFileSize","maxFileSize","isPreLoadFile","isPreload","createCustomfileList","fileData_1","listItem","listElement","uploadTemplateFn","templateComplier","liTempCompiler","fromElements","eventsArgs","formFileList","statusMessage","fileContainer","fileData_2","fileNameEle","getFileNameOnly","fileTypeEle","fileType","rtlContainer","truncateName","formValidateFileInfo","setListToFileInfo","infoEle","bytesToSize","getFileSize","createFormInput","iconElement","mergeFileInfo","addInvalidClass","typeValidationMessage","fileData_3","fileData_4","fileNames","fileData_5","statusForFormUpload","fileData_6","formCustomFileList","createFileList","fileData_7","textContainer","fileExtension","preventActionComplete","getSlicedName","nameElement","dataset","tail","fileData_8","setInitialAttributes","filterfileList","filterFiles","updateLiStatus","createProgressBar","progressbarWrapper","progressBar","progressbarInnerWrapper","progressbarText","updateProgressbar","loaded","changeProgressValue","progressValue","uploadInProgress","customUI","cancelUploadingFile","updateProgressBarClasses","iconEle","ajax_1","removecanceledFile","renderFailureState","requestResponse","removeProgressbar","deleteIcon","pauseButton","retryElement","reloadcanceledFile","uploadComplete","raiseSuccessEvent","uploadFailed","statusText","getAllResponseHeaders","withCredentials","spinnerEle","raiseActionComplete","getSelectedFileStatus","matchFiles","matchFilesIndex","selectFileIndex","selectedFileData","fileDataIndex","callType","animateProgressBar","uploadTemplate","exception","isMutiple","fileIndex","chunkSize","chunkIndex","retryCount","sendRequest","totalChunk","async","contentType","chunkUploadComplete","onUploadProgress","chunkUploadInProgress","currentChunkIndex","uploadingEventCallback","chunkUploadFailed","eventCancelByArgs","removeIcon","checkChunkUpload","updateMetaData","sendNextRequest","name_2","removeChunkFile","removeChunkProgressBar","pauseIcon","chunkCount","cancelButton","retryRequest","retryAfterDelay","file_1","failureMessage","checkPausePlayAction","retryUpload","fromcanceledStage","clearIcon","progressVal","totalChunks","abortIcon","sortedFileNames","sortedFilesData","sortedFileNames_1","name_3","attributes_2","uploadFiles_1","uploadFiles","serverReadFileBase64","totalCount","contents","uploadFileCount","getFileRead","fileCount","getFileInfo","uploadFilesRequest","chunkEnabled","name_4","spliceFiles","liIndex","beforeEventArgs","removingFiles","isLiRemoved","removingFiles_1","validUrl","fileUploadedIndex","removeFiles_1","fileDataFiles","pauseUploading","getFiles","resumeFiles","retryFailedFiles","cancelingFiles","cancelUpload","showHideUploadSpinner","FilesDirective","FilesPlugin","UploadedFilesDirective","UploadedFilesPlugin","UploaderComponent","UploaderPlugin","enIe","isModelChanged","aria","sortedColumn","getSortedColsIndexByField","sCol","getSortColumnFromField","lastSortedCol","backupSettings","removeSortIcons","updateSortedCols","lastSortedCols","lastCols","restoreSettings","refreshSortSettings","addSortIcons","refreshSortIcons","gObj_1","initiateSort","showPopUp","enableSortMultiTouch","allowUnsort","updateAriaAttr","km","DoubleRange","mStart","mEnd","isValDiff","makechanges","et","enIn","resizeClassList","suppress","Resize","tapped","isDblClk","resizeProcess","findColumn","newarray","resizeColumn","footerTable","footerTextClone","contentDivTag","footerDivTag","headerTextClone","contentTextClone","columnIndexByField","indentWidthClone","detailsElement","contentText","footerText","wHeader","wFooter","wContent","columnbyindex","colMaxWidth","calcTableWidth","contentwidth","refreshResizefrzCols","adaptiveClass","offsetWidthValue","refreshHeight","setHandlerHeight","getResizeHandlers","touchResizeStart","callAutoFit","getTargetColumn","refreshColumnWidth","refreshStackedColumnWidth","parentElementWidth","appendHelper","getPointX","minMove","removeHelper","cancelResizeAction","resizeEnd","resizing","updateCursor","removeEvents","updateResizeEleHeight","getColData","refreshResizeFixedCols","isAutoFitCol","frzHdrRefresh","width_2","columnsRight","refreshGroupCaptionRow","capRow","getParticularCol","setHelperHeight","finalColumns","getSubColumns","calulateColumnsWidth","finalColumns_1","updateHelper","subColumns","cTable","isFrozenColResized","doubleTapEvent","getStackedWidth","headerRows_1","calcPos","doc","ownerDocument","timeoutHandler","HIDE_CLEAR","TEXTBOX_FOCUS","TextBox","isHiddenInput","inputPreviousValue","textboxOptions","textboxWrapper","respectiveElement","prevOnChange","multiline","textarea","autocomplete","apiAttributes","attrs_1","autoCompleteTxt","getInputValidClassList","initialValue","setInitialValue","inputClassName","animationHandler","resetValue","textboxObj","interaction","resetInputHandler","addIcon","icons","pt","mimeType","getMimeType","downloadLink","hasDownloadAttribute","isPopupBlocked","onloadend","paIn","Encoding","includeBom","emitBOM","initBOM","getByteCount","chars","validateNullOrUndefined","byte","utf8Len","getByteCountInternal","codePoint","isHighSurrogate","codeUnit","toCodepoint","highCodeUnit","lowCodeUnit","charIndex","charCount","byteCount","isUtf8","charCode","RangeError","getBytesOfUtf8Encoding","getBytesOfUnicodeEncoding","getBytesOfAnsiEncoding","getString","byteCal","getStringOfUtf8Encoding","byteUnicode","getStringofUnicodeEncoding","bufview","charcode","uint16","byteUni","byte16","gd","ContextMenu","nl","DataLabel","errorHeight","initPrivateVariables","commonId","calculateErrorHeight","chartBackground","positiveHeight","negativeHeight","rgbValue","contrast","labelLocation","yAxisInversed","isDataLabelOverlap","showZero","labelLength","shapeRect","enableRotation","argsFont","fontBackground","isDataLabelShape","createDataLabelTemplate","calculateTextPosition","visibleAxisLabelRect","rectRegion","actualRect","isDataLabelOverlapWithChartBound","isShape","textAnchor","loc1","loc2","loc3","loc4","clipWidth","clipHeight","vAxis","hAxis","labelRegion","getLabelLocation","alignmentValue","calculateAlignment","calculateRectPosition","calculatePathPosition","calculatePolarRectPosition","dataLabelOutRegion","columnRadius","chartWidth","alignmentSign","extraSpace","calculateRectActualPosition","calculateTopAndOuterPosition","seriesLength","nextSeries","nextSeriesPoint","calculatePathActualPosition","labelRect","isOverLap","finalPosition","actualPosition","updateLabelLocation","yLocation","positionIndex","slope","intersectY","shapeElements","textNode","xPseudo","se"],"mappings":"sGAIE,SAAUA,EAAQC,GAEsBA,EAAQ,EAAQ,UAFzD,CAKCC,GAAM,SAAWC,GAAU;kCAIzB;IAAIC,EAASD,EAAOE,aAAa,UAAW,CACxCC,OAAQ,6EAA6EC,MACjF,KAEJC,YAAa,oDAAoDD,MAAM,KACvEE,SACI,+DAA+DF,MAC3D,KAERG,cAAe,kCAAkCH,MAAM,KACvDI,YAAa,yBAAyBJ,MAAM,KAC5CK,eAAgB,CACZC,GAAI,QACJC,IAAK,WACLC,EAAG,aACHC,GAAI,cACJC,IAAK,oBACLC,KAAM,2BAEVC,SAAU,CACNC,QAAS,uBACTC,QAAS,mBACTC,SAAU,2BACVC,QAAS,uBACTC,SAA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CAA+B,GAClDE,EAAW,CACP,eAAS,SACV42F,EAAK92F,UAAW,oBAAgB,GACnCE,EAAW,CACP,eAAS,WACV42F,EAAK92F,UAAW,iBAAa,GAChCE,EAAW,CACP,eAAS,SACV42F,EAAK92F,UAAW,0BAAsB,GACzCE,EAAW,CACP,eAAS,SACV42F,EAAK92F,UAAW,oBAAgB,GACnCE,EAAW,CACP,eAAS,iBACV42F,EAAK92F,UAAW,sBAAkB,GACrCE,EAAW,CACP,eAAS,YACV42F,EAAK92F,UAAW,oBAAgB,GACnCE,EAAW,CACP,eAAS,YACV42F,EAAK92F,UAAW,qBAAiB,GACpCE,EAAW,CACP,eAAS,KACV42F,EAAK92F,UAAW,YAAQ,GAC3BE,EAAW,CACP,gBAAS,IACV42F,EAAK92F,UAAW,eAAW,GAC9BE,EAAW,CACP,eAAS,IACV42F,EAAK92F,UAAW,6BAAyB,GAC5CE,EAAW,CACP,eAAS,IACV42F,EAAK92F,UAAW,qBAAiB,GACpCE,EAAW,CACP,eAAS,OACV42F,EAAK92F,UAAW,qBAAiB,GACpCE,EAAW,CACP,eAAS,OACV42F,EAAK92F,UAAW,iBAAa,GAChCE,EAAW,CACP,gBAAS,IACV42F,EAAK92F,UAAW,2BAAuB,GAC1CE,EAAW,CACP,eAAS,OACV42F,EAAK92F,UAAW,qBAAiB,GACpCE,EAAW,CACP,eAAS,OACV42F,EAAK92F,UAAW,eAAW,GAC9BE,EAAW,CACP,eAAS,OACV42F,EAAK92F,UAAW,eAAW,GAC9BE,EAAW,CACP,eAAS,OACV42F,EAAK92F,UAAW,gBAAY,GAC/BE,EAAW,CACP,eAAS,KACV42F,EAAK92F,UAAW,yBAAqB,GACxCE,EAAW,CACP,gBAAS,IACV42F,EAAK92F,UAAW,kBAAc,GACjCE,EAAW,CACP,eAAS,IACV42F,EAAK92F,UAAW,oBAAgB,GACnCE,EAAW,CACP,eAAS,IACV42F,EAAK92F,UAAW,oBAAgB,GACnCE,EAAW,CACP,eAAQ,GAAIy2F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A,6DACA,yDACA,iBACA,SACA,aACA,eACA,UACA,WACA,WACA,WACA,gBACA,cACA,eACA,gBACA,eACA,SACA,aACA,QACA,WACA,mBACA,iCACA,oEACA,mEACA,yEACA,oDACA,2CACA,uBACA,kBAEA,OADA,kCACA,GAEA,gBACA,gBAEA,mBACA,aAEA,kBACA,cACA,gEACA,8BACA,sEACA,+FACA,+BACA,wBACA,kBACA,mBACA,mBACA,eACA,sHAEA,YAEA,wBAEA,qBACA,wBACA,OACA,YACA,8GACA,qCAMA,gBAGA,qBACA,kBAEA,OADA,kCACA,GAEA,gBACA,gBAEA,mBACA,aAEA,kBACA,cACA,4BACA,sEACA,+FACA,6BACA,wBACA,kBACA,qBAEA,gBAGA,mBACA,kBAEA,OADA,kCACA,GAEA,gBACA,gBAEA,mBACA,aAEA,kBACA,cACA,+HACA,0BACA,sEACA,+FACA,2BACA,wBACA,kBACA,mBACA,mBACA,0BACA,mDACA,oDAEA,qDACA,oDAIA,gBAIA,gBACA,kBAEA,OADA,kCACA,GAEA,gBACA,kBAEA,mBACA,aAEA,kBACA,cACA,qBACA,kCACA,YAEA,6BACA,mBACA,4BACA,sHACA,0BAEA,OACA,YACA,8GACA,kCAIA,aACA,aAEA,gBAIA,gBAGA,iBACA,kBAEA,OADA,qCACA,GAEA,gBACA,gBAEA,mBACA,aAEA,kBACA,eACA,wCACA,wBACA,qCACA,eAGA,gBAIA,gEACA,cACA,qBACA,2BACA,gBACA,eACA,uEACA,eAEA,eACA,QACA,yBACA,WACA,cAGA,kBACA,QACA,yBACA,WACA,cAGA,iCACA,4BACA,wCACA,qCACA,0CACA,oCAEA,mCACA,cACA,yCACA,aACA,YACA,4BACA,8CAGA,aACA,CACA,cACA,YACA,4BACA,6CAEA,kBAEA,oBACA,cAOA,iBACA,kCAIA,SACA,4BACA,+BAEA,uBACA,iBAEA,sBACA,iBAEA,2BACA,yBAEA,uBAUA,WAEA,yBACA,+BACA,oCACA,0BAEA,qCACA,2CAGA,gCACA,wHACA,eACA,OACA,YACA,8GACA,mCAIA,iCACA,4HACA,iCACA,+BACA,+CACA,qBACA,mBACA,uDACA,kKACA,2FAEA,sEACA,eACA,CACA,4BAEA,0BACA,CACA,CACA,kIAEA,sUACA,sTAGA,4CACA,YACA,wBACA,kFACA,oFAGA,+EACA,sFAGA,0BACA,mCAEA,wBAEA,uBACA,+DACA,sBACA,sBACA,4BACA,wBACA,8BACA,oCACA,0BACA,oCACA,yCACA,uCACA,2BACA,wBACA,8BAEA,OACA,YACA,8GACA,mCAIA,yBACA,oCAEA,4CAEA,6CAEA,2DAEA,gCACA,8BAEA,4CAEA,6CAGA,wBAEA,GADA,sBACA,2BAEA,kCACA,sDACA,qDAIA,kDACA,gDAaA,GARA,uBAEA,uDAEA,0BAEA,uDAEA,mDACA,kDACA,2EACA,2CACA,yDAEA,uDADA,2CAGA,wDAEA,yDAEA,8DAHA,2CAKA,qDAEA,6DADA,2CAGA,4DAEA,0DAEA,2DAEA,yDAEA,mDAPA,2CASA,sDAEA,oDAEA,qDAHA,2CAKA,2DACA,6CAKA,sCAEA,GADA,oCACA,2BAEA,mCAEA,sDACA,gDAGA,aACA,aACA,aACA,aACA,aACA,aACA,kBAEA,CACA,kDACA,gDAIA,aACA,aACA,aACA,aACA,aACA,aACA,cAqDA,GA9CA,gCAEA,0BACA,yIACA,2BACA,uBACA,iBACA,wCAEA,mEACA,2GACA,qGAKA,kBACA,+HACA,2BACA,uBACA,iBACA,wCAEA,mEACA,2GACA,qGAKA,8BACA,oJACA,2BACA,uBACA,iBACA,wCAEA,mEACA,2GACA,iGAOA,oDAEA,8BACA,OAEA,cAGA,sBACA,qBACA,oCACA,wBACA,cACA,iBACA,6CAKA,kDACA,2EACA,2CACA,yDAEA,uDADA,2CAGA,wDAEA,yDAEA,8DAHA,2CAKA,qDAEA,6DADA,2CAGA,4DACA,2CACA,qCACA,0DAGA,0DAEA,2DAEA,yDAEA,mDARA,4CAUA,sDAEA,oDAEA,wDAHA,4CAOA,uBAEA,0BAC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GAAW,CACP,eAAW,GAAI,KAChB02N,EAAK12N,UAAW,kBAAc,GACjC,GAAW,CACP,gBAAS,IACV02N,EAAK12N,UAAW,yBAAqB,GACxC,GAAW,CACP,eAAQ,GAAI,KACb02N,EAAK12N,UAAW,6BAAyB,GAC5C,GAAW,CACP,gBAAS,IACV02N,EAAK12N,UAAW,yBAAqB,GACxC,GAAW,CACP,eAAS,SACV02N,EAAK12N,UAAW,cAAU,GAC7B,GAAW,CACP,eAAS,SACV02N,EAAK12N,UAAW,aAAS,GAC5B,GAAW,CACP,eAAS,YACV02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,2BAAuB,GAC1C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,eAAS,aACV02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,eAAS,aACV02N,EAAK12N,UAAW,0BAAsB,GACzC,GAAW,CACP,eAAS,KACV02N,EAAK12N,UAAW,kBAAc,GACjC,GAAW,CACP,eAAS,OACV02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,aAAS,GAC5B,GAAW,CACP,eAAS,QACV02N,EAAK12N,UAAW,oBAAgB,GACnC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,eAAW,GAC9B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,wBAAoB,GACvC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,eAAS,IACV02N,EAAK12N,UAAW,kBAAc,GACjC,GAAW,CACP,eAAS,IACV02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,eAAS,KACV02N,EAAK12N,UAAW,gBAAY,GAC/B,GAAW,CACP,eAAS,QACV02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,eAAS,KACV02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,eAAS,KACV02N,EAAK12N,UAAW,kCAA8B,GACjD,GAAW,CACP,kBACD02N,EAAK12N,UAAW,eAAW,GAC9B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,YAAQ,GAC3B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,oBAAgB,GACnC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,yBAAqB,GACxC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,oBAAgB,GACnC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,oBAAgB,GACnC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,yBAAqB,GACxC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,wBAAoB,GACvC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,kBAAc,GACjC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,kBAAc,GACjC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,qBAAiB,GACpC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,wBAAoB,GACvC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,8BAA0B,GAC7C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,iCAA6B,GAChD,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mCAA+B,GAClD,GAAW,CACP,kBACD02N,EAAK12N,UAAW,6BAAyB,GAC5C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,4BAAwB,GAC3C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,0BAAsB,GACzC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,gCAA4B,GAC/C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,yBAAqB,GACxC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,2BAAuB,GAC1C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,yBAAqB,GACxC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,0BAAsB,GACzC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,oBAAgB,GACnC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,eAAW,GAC9B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,eAAW,GAC9B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,oBAAgB,GACnC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,+BAA2B,GAC9C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,gCAA4B,GAC/C,GAAW,CACP,kBACD02N,EAAK12N,UAAW,gBAAY,GAC/B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,yBAAqB,GACxC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,oBAAgB,GACnC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,gBAAY,GAC/B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,gBAAY,GAC/B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,iBAAa,GAChC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,mBAAe,GAClC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,gBAAY,GAC/B,GAAW,CACP,kBACD02N,EAAK12N,UAAW,kBAAc,GACjC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,kBAAc,GACjC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,wBAAoB,GACvC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,uBAAmB,GACtC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,sBAAkB,GACrC,GAAW,CACP,kBACD02N,EAAK12N,UAAW,kBAAc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AAG,YACHC,GAAI,YACJC,EAAG,SACHC,GAAI,WACJC,EAAG,YACHC,GAAI,cACJC,EAAG,UACHC,GAAI,aAERgB,uBAAwB,uBACxBC,QAAS,SAAUI,GACf,IAAI8B,EAAI9B,EAAS,GACbR,EACgC,OAAxBQ,EAAS,IAAO,IACd,KACM,IAAN8B,EACA,KACM,IAANA,EACA,KACM,IAANA,EACA,KACA,KACd,OAAO9B,EAASR,GAEpBZ,KAAM,CACFC,IAAK,EACLC,IAAK,KAIb,OAAO6iX,M,sBC7ET,SAAUxlX,EAAQC,GAEsBA,EAAQ,EAAQ,UAFzD,CAKCC,GAAM,SAAWC,GAAU;kCAIzB;IAAIslX,EAAKtlX,EAAOE,aAAa,KAAM,CAC/BC,OAAQ,mJAAmJC,MACvJ,KAEJC,YACI,6DAA6DD,MAAM,KACvEE,SACI,6EAA6EF,MACzE,KAERG,cAAe,mCAAmCH,MAAM,KACxDI,YAAa,gBAAgBJ,MAAM,KACnCK,eAAgB,CACZC,GAAI,QACJC,IAAK,WACLC,EAAG,aACHC,GAAI,oBACJC,IAAK,gCACLC,KAAM,uCAEVC,SAAU,CACNC,QAAS,eACTC,QAAS,iBACTC,SAAU,eACVC,QAAS,eACTC,SAAU,wBACVC,SAAU,KAEdC,aAAc,CACVC,OAAQ,YACRC,KAAM,WACNC,EAAG,mBACHC,GAAI,eACJC,EAAG,eACHC,GAAI,cACJC,EAAG,cACHC,GAAI,aACJC,EAAG,cACHC,GAAI,cACJC,EAAG,aACHC,GAAI,WACJC,EAAG,aACHC,GAAI,YAERgB,uBAAwB,YACxBC,QAAS,MACThB,KAAM,CACFC,IAAK,EACLC,IAAK,KAIb,OAAO8iX","file":"js/chunk-4387bc52.4fe719f5.js","sourcesContent":["//! moment.js locale configuration\n//! locale : Uzbek Latin [uz-latn]\n//! author : Rasulbek Mirzayev : github.com/Rasulbeeek\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var uzLatn = moment.defineLocale('uz-latn', {\n months: 'Yanvar_Fevral_Mart_Aprel_May_Iyun_Iyul_Avgust_Sentabr_Oktabr_Noyabr_Dekabr'.split(\n '_'\n ),\n monthsShort: 'Yan_Fev_Mar_Apr_May_Iyun_Iyul_Avg_Sen_Okt_Noy_Dek'.split('_'),\n weekdays:\n 'Yakshanba_Dushanba_Seshanba_Chorshanba_Payshanba_Juma_Shanba'.split(\n '_'\n ),\n weekdaysShort: 'Yak_Dush_Sesh_Chor_Pay_Jum_Shan'.split('_'),\n weekdaysMin: 'Ya_Du_Se_Cho_Pa_Ju_Sha'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'D MMMM YYYY, dddd HH:mm',\n },\n calendar: {\n sameDay: '[Bugun soat] LT [da]',\n nextDay: '[Ertaga] LT [da]',\n nextWeek: 'dddd [kuni soat] LT [da]',\n lastDay: '[Kecha soat] LT [da]',\n lastWeek: \"[O'tgan] dddd [kuni soat] LT [da]\",\n sameElse: 'L',\n },\n relativeTime: {\n future: 'Yaqin %s ichida',\n past: 'Bir necha %s oldin',\n s: 'soniya',\n ss: '%d soniya',\n m: 'bir daqiqa',\n mm: '%d daqiqa',\n h: 'bir soat',\n hh: '%d soat',\n d: 'bir kun',\n dd: '%d kun',\n M: 'bir oy',\n MM: '%d oy',\n y: 'bir yil',\n yy: '%d yil',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return uzLatn;\n\n})));\n","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./StatusAlert.vue?vue&type=style&index=0&id=8cc5df1a&prod&lang=css\"","//! moment.js locale configuration\n//! locale : Malayalam [ml]\n//! author : Floyd Pink : https://github.com/floydpink\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ml = moment.defineLocale('ml', {\n months: 'ജനàµà´µà´°à´¿_ഫെബàµà´°àµà´µà´°à´¿_മാർചàµà´šàµ_à´à´ªàµà´°à´¿àµ½_മേയàµ_ജൂൺ_ജൂലൈ_à´“à´—à´¸àµà´±àµà´±àµ_സെപàµà´±àµà´±à´‚ബർ_à´’à´•àµà´Ÿàµ‹à´¬àµ¼_നവംബർ_ഡിസംബർ'.split(\n '_'\n ),\n monthsShort:\n 'ജനàµ._ഫെബàµà´°àµ._മാർ._à´à´ªàµà´°à´¿._മേയàµ_ജൂൺ_ജൂലൈ._à´“à´—._സെപàµà´±àµà´±._à´’à´•àµà´Ÿàµ‹._നവം._ഡിസം.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays:\n 'ഞായറാഴàµà´š_തിങàµà´•à´³à´¾à´´àµà´š_ചൊവàµà´µà´¾à´´àµà´š_à´¬àµà´§à´¨à´¾à´´àµà´š_à´µàµà´¯à´¾à´´à´¾à´´àµà´š_വെളàµà´³à´¿à´¯à´¾à´´àµà´š_ശനിയാഴàµà´š'.split(\n '_'\n ),\n weekdaysShort: 'ഞായർ_തിങàµà´•àµ¾_ചൊവàµà´µ_à´¬àµà´§àµ»_à´µàµà´¯à´¾à´´à´‚_വെളàµà´³à´¿_ശനി'.split('_'),\n weekdaysMin: 'à´žà´¾_തി_ചൊ_à´¬àµ_à´µàµà´¯à´¾_വെ_à´¶'.split('_'),\n longDateFormat: {\n LT: 'A h:mm -à´¨àµ',\n LTS: 'A h:mm:ss -à´¨àµ',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm -à´¨àµ',\n LLLL: 'dddd, D MMMM YYYY, A h:mm -à´¨àµ',\n },\n calendar: {\n sameDay: '[ഇനàµà´¨àµ] LT',\n nextDay: '[നാളെ] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[ഇനàµà´¨à´²àµ†] LT',\n lastWeek: '[à´•à´´à´¿à´žàµà´ž] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s à´•à´´à´¿à´žàµà´žàµ',\n past: '%s à´®àµàµ»à´ªàµ',\n s: 'അൽപ നിമിഷങàµà´™àµ¾',\n ss: '%d സെകàµà´•àµ»à´¡àµ',\n m: 'ഒരൠമിനിറàµà´±àµ',\n mm: '%d മിനിറàµà´±àµ',\n h: 'ഒരൠമണികàµà´•àµ‚ർ',\n hh: '%d മണികàµà´•àµ‚ർ',\n d: 'ഒരൠദിവസം',\n dd: '%d ദിവസം',\n M: 'ഒരൠമാസം',\n MM: '%d മാസം',\n y: 'ഒരൠവർഷം',\n yy: '%d വർഷം',\n },\n meridiemParse: /രാതàµà´°à´¿|രാവിലെ|ഉചàµà´š à´•à´´à´¿à´žàµà´žàµ|വൈകàµà´¨àµà´¨àµ‡à´°à´‚|രാതàµà´°à´¿/i,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (\n (meridiem === 'രാതàµà´°à´¿' && hour >= 4) ||\n meridiem === 'ഉചàµà´š à´•à´´à´¿à´žàµà´žàµ' ||\n meridiem === 'വൈകàµà´¨àµà´¨àµ‡à´°à´‚'\n ) {\n return hour + 12;\n } else {\n return hour;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'രാതàµà´°à´¿';\n } else if (hour < 12) {\n return 'രാവിലെ';\n } else if (hour < 17) {\n return 'ഉചàµà´š à´•à´´à´¿à´žàµà´žàµ';\n } else if (hour < 20) {\n return 'വൈകàµà´¨àµà´¨àµ‡à´°à´‚';\n } else {\n return 'രാതàµà´°à´¿';\n }\n },\n });\n\n return ml;\n\n})));\n","//! moment.js locale configuration\n//! locale : Chuvash [cv]\n//! author : Anatoly Mironov : https://github.com/mirontoli\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var cv = moment.defineLocale('cv', {\n months: 'кӑрлач_нарӑÑ_пуш_ака_май_ҫӗртме_утӑ_ҫурла_авӑн_юпа_чӳк_раштав'.split(\n '_'\n ),\n monthsShort: 'кӑр_нар_пуш_ака_май_Ò«Ó—Ñ€_утӑ_ҫур_авн_юпа_чӳк_раш'.split('_'),\n weekdays:\n 'вырÑарникун_тунтикун_ытларикун_юнкун_кӗҫнерникун_Ñрнекун_шӑматкун'.split(\n '_'\n ),\n weekdaysShort: 'выр_тун_ытл_юн_кӗҫ_Ñрн_шӑм'.split('_'),\n weekdaysMin: 'вр_тн_Ñ‹Ñ‚_юн_кҫ_ÑÑ€_шм'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD-MM-YYYY',\n LL: 'YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ]',\n LLL: 'YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm',\n LLLL: 'dddd, YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm',\n },\n calendar: {\n sameDay: '[ПаÑн] LT [Ñехетре]',\n nextDay: '[Ыран] LT [Ñехетре]',\n lastDay: '[Ӗнер] LT [Ñехетре]',\n nextWeek: '[ҪитеÑ] dddd LT [Ñехетре]',\n lastWeek: '[Иртнӗ] dddd LT [Ñехетре]',\n sameElse: 'L',\n },\n relativeTime: {\n future: function (output) {\n var affix = /Ñехет$/i.exec(output)\n ? 'рен'\n : /ҫул$/i.exec(output)\n ? 'тан'\n : 'ран';\n return output + affix;\n },\n past: '%s каÑлла',\n s: 'пӗр-ик ҫеккунт',\n ss: '%d ҫеккунт',\n m: 'пӗр минут',\n mm: '%d минут',\n h: 'пӗр Ñехет',\n hh: '%d Ñехет',\n d: 'пӗр кун',\n dd: '%d кун',\n M: 'пӗр уйӑх',\n MM: '%d уйӑх',\n y: 'пӗр ҫул',\n yy: '%d ҫул',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-мӗш/,\n ordinal: '%d-мӗш',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return cv;\n\n})));\n","//! moment.js locale configuration\n//! locale : Icelandic [is]\n//! author : Hinrik Örn Sigurðsson : https://github.com/hinrik\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function plural(n) {\n if (n % 100 === 11) {\n return true;\n } else if (n % 10 === 1) {\n return false;\n }\n return true;\n }\n function translate(number, withoutSuffix, key, isFuture) {\n var result = number + ' ';\n switch (key) {\n case 's':\n return withoutSuffix || isFuture\n ? 'nokkrar sekúndur'\n : 'nokkrum sekúndum';\n case 'ss':\n if (plural(number)) {\n return (\n result +\n (withoutSuffix || isFuture ? 'sekúndur' : 'sekúndum')\n );\n }\n return result + 'sekúnda';\n case 'm':\n return withoutSuffix ? 'mÃnúta' : 'mÃnútu';\n case 'mm':\n if (plural(number)) {\n return (\n result + (withoutSuffix || isFuture ? 'mÃnútur' : 'mÃnútum')\n );\n } else if (withoutSuffix) {\n return result + 'mÃnúta';\n }\n return result + 'mÃnútu';\n case 'hh':\n if (plural(number)) {\n return (\n result +\n (withoutSuffix || isFuture\n ? 'klukkustundir'\n : 'klukkustundum')\n );\n }\n return result + 'klukkustund';\n case 'd':\n if (withoutSuffix) {\n return 'dagur';\n }\n return isFuture ? 'dag' : 'degi';\n case 'dd':\n if (plural(number)) {\n if (withoutSuffix) {\n return result + 'dagar';\n }\n return result + (isFuture ? 'daga' : 'dögum');\n } else if (withoutSuffix) {\n return result + 'dagur';\n }\n return result + (isFuture ? 'dag' : 'degi');\n case 'M':\n if (withoutSuffix) {\n return 'mánuður';\n }\n return isFuture ? 'mánuð' : 'mánuði';\n case 'MM':\n if (plural(number)) {\n if (withoutSuffix) {\n return result + 'mánuðir';\n }\n return result + (isFuture ? 'mánuði' : 'mánuðum');\n } else if (withoutSuffix) {\n return result + 'mánuður';\n }\n return result + (isFuture ? 'mánuð' : 'mánuði');\n case 'y':\n return withoutSuffix || isFuture ? 'ár' : 'ári';\n case 'yy':\n if (plural(number)) {\n return result + (withoutSuffix || isFuture ? 'ár' : 'árum');\n }\n return result + (withoutSuffix || isFuture ? 'ár' : 'ári');\n }\n }\n\n var is = moment.defineLocale('is', {\n months: 'janúar_febrúar_mars_aprÃl_maÃ_júnÃ_júlÃ_ágúst_september_október_nóvember_desember'.split(\n '_'\n ),\n monthsShort: 'jan_feb_mar_apr_maÃ_jún_júl_ágú_sep_okt_nóv_des'.split('_'),\n weekdays:\n 'sunnudagur_mánudagur_þriðjudagur_miðvikudagur_fimmtudagur_föstudagur_laugardagur'.split(\n '_'\n ),\n weekdaysShort: 'sun_mán_þri_mið_fim_fös_lau'.split('_'),\n weekdaysMin: 'Su_Má_Þr_Mi_Fi_Fö_La'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY [kl.] H:mm',\n LLLL: 'dddd, D. MMMM YYYY [kl.] H:mm',\n },\n calendar: {\n sameDay: '[à dag kl.] LT',\n nextDay: '[á morgun kl.] LT',\n nextWeek: 'dddd [kl.] LT',\n lastDay: '[à gær kl.] LT',\n lastWeek: '[sÃðasta] dddd [kl.] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'eftir %s',\n past: 'fyrir %s sÃðan',\n s: translate,\n ss: translate,\n m: translate,\n mm: translate,\n h: 'klukkustund',\n hh: translate,\n d: translate,\n dd: translate,\n M: translate,\n MM: translate,\n y: translate,\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return is;\n\n})));\n","//! moment.js locale configuration\n//! locale : Faroese [fo]\n//! author : Ragnar Johannesen : https://github.com/ragnar123\n//! author : Kristian Sakarisson : https://github.com/sakarisson\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var fo = moment.defineLocale('fo', {\n months: 'januar_februar_mars_aprÃl_mai_juni_juli_august_september_oktober_november_desember'.split(\n '_'\n ),\n monthsShort: 'jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des'.split('_'),\n weekdays:\n 'sunnudagur_mánadagur_týsdagur_mikudagur_hósdagur_frÃggjadagur_leygardagur'.split(\n '_'\n ),\n weekdaysShort: 'sun_mán_týs_mik_hós_frÃ_ley'.split('_'),\n weekdaysMin: 'su_má_tý_mi_hó_fr_le'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D. MMMM, YYYY HH:mm',\n },\n calendar: {\n sameDay: '[à dag kl.] LT',\n nextDay: '[à morgin kl.] LT',\n nextWeek: 'dddd [kl.] LT',\n lastDay: '[à gjár kl.] LT',\n lastWeek: '[sÃðstu] dddd [kl] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'um %s',\n past: '%s sÃðani',\n s: 'fá sekund',\n ss: '%d sekundir',\n m: 'ein minuttur',\n mm: '%d minuttir',\n h: 'ein tÃmi',\n hh: '%d tÃmar',\n d: 'ein dagur',\n dd: '%d dagar',\n M: 'ein mánaður',\n MM: '%d mánaðir',\n y: 'eitt ár',\n yy: '%d ár',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return fo;\n\n})));\n","//! moment.js locale configuration\n//! locale : Japanese [ja]\n//! author : LI Long : https://github.com/baryon\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ja = moment.defineLocale('ja', {\n eras: [\n {\n since: '2019-05-01',\n offset: 1,\n name: '令和',\n narrow: 'ã‹¿',\n abbr: 'R',\n },\n {\n since: '1989-01-08',\n until: '2019-04-30',\n offset: 1,\n name: 'å¹³æˆ',\n narrow: 'ã»',\n abbr: 'H',\n },\n {\n since: '1926-12-25',\n until: '1989-01-07',\n offset: 1,\n name: 'æ˜å’Œ',\n narrow: 'ã¼',\n abbr: 'S',\n },\n {\n since: '1912-07-30',\n until: '1926-12-24',\n offset: 1,\n name: '大æ£',\n narrow: 'ã½',\n abbr: 'T',\n },\n {\n since: '1873-01-01',\n until: '1912-07-29',\n offset: 6,\n name: '明治',\n narrow: 'ã¾',\n abbr: 'M',\n },\n {\n since: '0001-01-01',\n until: '1873-12-31',\n offset: 1,\n name: '西暦',\n narrow: 'AD',\n abbr: 'AD',\n },\n {\n since: '0000-12-31',\n until: -Infinity,\n offset: 1,\n name: '紀元å‰',\n narrow: 'BC',\n abbr: 'BC',\n },\n ],\n eraYearOrdinalRegex: /(å…ƒ|\\d+)å¹´/,\n eraYearOrdinalParse: function (input, match) {\n return match[1] === 'å…ƒ' ? 1 : parseInt(match[1] || input, 10);\n },\n months: '1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月'.split('_'),\n monthsShort: '1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月'.split(\n '_'\n ),\n weekdays: '日曜日_月曜日_ç«æ›œæ—¥_水曜日_木曜日_金曜日_土曜日'.split('_'),\n weekdaysShort: 'æ—¥_月_ç«_æ°´_木_金_土'.split('_'),\n weekdaysMin: 'æ—¥_月_ç«_æ°´_木_金_土'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY/MM/DD',\n LL: 'YYYYå¹´M月Dæ—¥',\n LLL: 'YYYYå¹´M月Dæ—¥ HH:mm',\n LLLL: 'YYYYå¹´M月Dæ—¥ dddd HH:mm',\n l: 'YYYY/MM/DD',\n ll: 'YYYYå¹´M月Dæ—¥',\n lll: 'YYYYå¹´M月Dæ—¥ HH:mm',\n llll: 'YYYYå¹´M月Dæ—¥(ddd) HH:mm',\n },\n meridiemParse: /åˆå‰|åˆå¾Œ/i,\n isPM: function (input) {\n return input === 'åˆå¾Œ';\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'åˆå‰';\n } else {\n return 'åˆå¾Œ';\n }\n },\n calendar: {\n sameDay: '[今日] LT',\n nextDay: '[明日] LT',\n nextWeek: function (now) {\n if (now.week() !== this.week()) {\n return '[æ¥é€±]dddd LT';\n } else {\n return 'dddd LT';\n }\n },\n lastDay: '[昨日] LT',\n lastWeek: function (now) {\n if (this.week() !== now.week()) {\n return '[先週]dddd LT';\n } else {\n return 'dddd LT';\n }\n },\n sameElse: 'L',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}æ—¥/,\n ordinal: function (number, period) {\n switch (period) {\n case 'y':\n return number === 1 ? '元年' : number + 'å¹´';\n case 'd':\n case 'D':\n case 'DDD':\n return number + 'æ—¥';\n default:\n return number;\n }\n },\n relativeTime: {\n future: '%s後',\n past: '%så‰',\n s: '数秒',\n ss: '%d秒',\n m: '1分',\n mm: '%d分',\n h: '1時間',\n hh: '%d時間',\n d: '1æ—¥',\n dd: '%dæ—¥',\n M: '1ヶ月',\n MM: '%dヶ月',\n y: '1å¹´',\n yy: '%då¹´',\n },\n });\n\n return ja;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Component, Property, ChildProperty, Event, append, compile } from '@syncfusion/ej2-base';\nimport { EventHandler, Touch, Browser, Animation as PopupAnimation, animationMode } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, getUniqueID, formatUnit, select, selectAll } from '@syncfusion/ej2-base';\nimport { attributes, closest, removeClass, addClass, remove } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges, Complex, SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport { Popup } from '../popup/popup';\nimport { calculatePosition } from '../common/position';\nimport { isCollide, fit } from '../common/collision';\nvar TOUCHEND_HIDE_DELAY = 1500;\nvar TAPHOLD_THRESHOLD = 500;\nvar SHOW_POINTER_TIP_GAP = 0;\nvar HIDE_POINTER_TIP_GAP = 8;\nvar MOUSE_TRAIL_GAP = 2;\nvar POINTER_ADJUST = 2;\nvar ROOT = 'e-tooltip';\nvar RTL = 'e-rtl';\nvar DEVICE = 'e-bigger';\nvar ICON = 'e-icons';\nvar CLOSE = 'e-tooltip-close';\nvar TOOLTIP_WRAP = 'e-tooltip-wrap';\nvar CONTENT = 'e-tip-content';\nvar ARROW_TIP = 'e-arrow-tip';\nvar ARROW_TIP_OUTER = 'e-arrow-tip-outer';\nvar ARROW_TIP_INNER = 'e-arrow-tip-inner';\nvar TIP_BOTTOM = 'e-tip-bottom';\nvar TIP_TOP = 'e-tip-top';\nvar TIP_LEFT = 'e-tip-left';\nvar TIP_RIGHT = 'e-tip-right';\nvar POPUP_ROOT = 'e-popup';\nvar POPUP_OPEN = 'e-popup-open';\nvar POPUP_CLOSE = 'e-popup-close';\nvar POPUP_LIB = 'e-lib';\nvar HIDE_POPUP = 'e-hidden';\nvar POPUP_CONTAINER = 'e-tooltip-popup-container';\nvar Animation = /** @class */ (function (_super) {\n __extends(Animation, _super);\n function Animation() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property({ effect: 'FadeIn', duration: 150, delay: 0 })\n ], Animation.prototype, \"open\", void 0);\n __decorate([\n Property({ effect: 'FadeOut', duration: 150, delay: 0 })\n ], Animation.prototype, \"close\", void 0);\n return Animation;\n}(ChildProperty));\nexport { Animation };\n/**\n * Represents the Tooltip component that displays a piece of information about the target element on mouse hover.\n * ```html\n * <div id=\"tooltip\">Show Tooltip</div>\n * ```\n * ```typescript\n * <script>\n * var tooltipObj = new Tooltip({ content: 'Tooltip text' });\n * tooltipObj.appendTo(\"#tooltip\");\n * </script>\n * ```\n */\nvar Tooltip = /** @class */ (function (_super) {\n __extends(Tooltip, _super);\n /* eslint-enable */\n /**\n * Constructor for creating the Tooltip Component\n *\n * @param {TooltipModel} options - specifies the options for the constructor\n * @param {string| HTMLElement} element - specifies the element for the constructor\n *\n */\n function Tooltip(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.mouseMoveEvent = null;\n _this.mouseMoveTarget = null;\n _this.containerElement = null;\n _this.isBodyContainer = true;\n return _this;\n }\n Tooltip.prototype.initialize = function () {\n this.formatPosition();\n addClass([this.element], ROOT);\n };\n Tooltip.prototype.formatPosition = function () {\n var _a, _b;\n if (this.position.indexOf('Top') === 0 || this.position.indexOf('Bottom') === 0) {\n _a = this.position.split(/(?=[A-Z])/), this.tooltipPositionY = _a[0], this.tooltipPositionX = _a[1];\n }\n else {\n _b = this.position.split(/(?=[A-Z])/), this.tooltipPositionX = _b[0], this.tooltipPositionY = _b[1];\n }\n };\n Tooltip.prototype.renderArrow = function () {\n this.setTipClass(this.position);\n var tip = this.createElement('div', { className: ARROW_TIP + ' ' + this.tipClass });\n tip.appendChild(this.createElement('div', { className: ARROW_TIP_OUTER + ' ' + this.tipClass }));\n tip.appendChild(this.createElement('div', { className: ARROW_TIP_INNER + ' ' + this.tipClass }));\n this.tooltipEle.appendChild(tip);\n };\n Tooltip.prototype.setTipClass = function (position) {\n if (position.indexOf('Right') === 0) {\n this.tipClass = TIP_LEFT;\n }\n else if (position.indexOf('Bottom') === 0) {\n this.tipClass = TIP_TOP;\n }\n else if (position.indexOf('Left') === 0) {\n this.tipClass = TIP_RIGHT;\n }\n else {\n this.tipClass = TIP_BOTTOM;\n }\n };\n Tooltip.prototype.renderPopup = function (target) {\n var elePos = this.mouseTrail ? { top: 0, left: 0 } : this.getTooltipPosition(target);\n this.tooltipEle.classList.remove(POPUP_LIB);\n this.popupObj = new Popup(this.tooltipEle, {\n height: this.height,\n width: this.width,\n position: { X: elePos.left, Y: elePos.top },\n enableRtl: this.enableRtl,\n open: this.openPopupHandler.bind(this),\n close: this.closePopupHandler.bind(this)\n });\n };\n Tooltip.prototype.getScalingFactor = function (target) {\n if (!target) {\n return { x: 1, y: 1 };\n }\n var scalingFactors = { x: 1, y: 1 };\n var elementsWithTransform = target.closest('[style*=\"transform: scale\"]');\n if (elementsWithTransform && elementsWithTransform != this.tooltipEle && elementsWithTransform.contains(this.tooltipEle)) {\n var computedStyle = window.getComputedStyle(elementsWithTransform);\n var transformValue = computedStyle.getPropertyValue(\"transform\");\n var matrixValues = transformValue.match(/matrix\\(([^)]+)\\)/)[1].split(\",\").map(parseFloat);\n scalingFactors.x = matrixValues[0];\n scalingFactors.y = matrixValues[3];\n }\n return scalingFactors;\n };\n Tooltip.prototype.getTooltipPosition = function (target) {\n this.tooltipEle.style.display = 'block';\n var parentWithZoomStyle = this.element.closest('[style*=\"zoom\"]');\n if (parentWithZoomStyle) {\n if (!parentWithZoomStyle.contains(this.tooltipEle)) {\n this.tooltipEle.style.zoom = getComputedStyle(parentWithZoomStyle).zoom;\n }\n }\n var pos = calculatePosition(target, this.tooltipPositionX, this.tooltipPositionY, !this.isBodyContainer, this.isBodyContainer ? null : this.containerElement.getBoundingClientRect());\n var scalingFactors = this.getScalingFactor(target);\n var offsetPos = this.calculateTooltipOffset(this.position, scalingFactors.x, scalingFactors.y);\n var collisionPosition = this.calculateElementPosition(pos, offsetPos);\n var collisionLeft = collisionPosition[0];\n var collisionTop = collisionPosition[1];\n var elePos = this.collisionFlipFit(target, collisionLeft, collisionTop);\n if (!this.isBodyContainer) {\n elePos.top -= this.containerElement.getBoundingClientRect().top;\n }\n elePos.left = elePos.left / scalingFactors.x;\n elePos.top = elePos.top / scalingFactors.y;\n this.tooltipEle.style.display = '';\n return elePos;\n };\n Tooltip.prototype.windowResize = function () {\n this.reposition(this.findTarget());\n };\n Tooltip.prototype.reposition = function (target) {\n if (this.popupObj && target) {\n var elePos = this.getTooltipPosition(target);\n this.popupObj.position = { X: elePos.left, Y: elePos.top };\n this.popupObj.dataBind();\n }\n };\n Tooltip.prototype.openPopupHandler = function () {\n if (!this.mouseTrail && this.needTemplateReposition()) {\n this.reposition(this.findTarget());\n }\n this.trigger('afterOpen', this.tooltipEventArgs);\n this.tooltipEventArgs = null;\n };\n Tooltip.prototype.closePopupHandler = function () {\n if (this.isReact && !(this.opensOn === 'Click' && typeof (this.content) === 'function')) {\n this.clearTemplate(['content']);\n }\n this.clear();\n this.trigger('afterClose', this.tooltipEventArgs);\n this.tooltipEventArgs = null;\n };\n Tooltip.prototype.calculateTooltipOffset = function (position, xScalingFactor, yScalingFactor) {\n if (xScalingFactor === void 0) { xScalingFactor = 1; }\n if (yScalingFactor === void 0) { yScalingFactor = 1; }\n var pos = { top: 0, left: 0 };\n var tipWidth, tipHeight, tooltipEleWidth, tooltipEleHeight, arrowEle;\n var tipAdjust, tipHeightAdjust, tipWidthAdjust;\n if (xScalingFactor != 1 || yScalingFactor != 1) {\n var tooltipEleRect = this.tooltipEle.getBoundingClientRect();\n var arrowEleRect = void 0;\n tooltipEleWidth = Math.round(tooltipEleRect.width);\n tooltipEleHeight = Math.round(tooltipEleRect.height);\n arrowEle = select('.' + ARROW_TIP, this.tooltipEle);\n if (arrowEle) {\n arrowEleRect = arrowEle.getBoundingClientRect();\n }\n tipWidth = arrowEle ? Math.round(arrowEleRect.width) : 0;\n tipHeight = arrowEle ? Math.round(arrowEleRect.height) : 0;\n tipAdjust = (this.showTipPointer ? SHOW_POINTER_TIP_GAP : HIDE_POINTER_TIP_GAP);\n tipHeightAdjust = (tipHeight / 2) + POINTER_ADJUST + (tooltipEleHeight - (this.tooltipEle.clientHeight * yScalingFactor));\n tipWidthAdjust = (tipWidth / 2) + POINTER_ADJUST + (tooltipEleWidth - (this.tooltipEle.clientWidth * xScalingFactor));\n }\n else {\n tooltipEleWidth = this.tooltipEle.offsetWidth;\n tooltipEleHeight = this.tooltipEle.offsetHeight;\n arrowEle = select('.' + ARROW_TIP, this.tooltipEle);\n tipWidth = arrowEle ? arrowEle.offsetWidth : 0;\n tipHeight = arrowEle ? arrowEle.offsetHeight : 0;\n tipAdjust = (this.showTipPointer ? SHOW_POINTER_TIP_GAP : HIDE_POINTER_TIP_GAP);\n tipHeightAdjust = (tipHeight / 2) + POINTER_ADJUST + (this.tooltipEle.offsetHeight - this.tooltipEle.clientHeight);\n tipWidthAdjust = (tipWidth / 2) + POINTER_ADJUST + (this.tooltipEle.offsetWidth - this.tooltipEle.clientWidth);\n }\n if (this.mouseTrail) {\n tipAdjust += MOUSE_TRAIL_GAP;\n }\n switch (position) {\n case 'RightTop':\n pos.left += tipWidth + tipAdjust;\n pos.top -= tooltipEleHeight - tipHeightAdjust;\n break;\n case 'RightCenter':\n pos.left += tipWidth + tipAdjust;\n pos.top -= (tooltipEleHeight / 2);\n break;\n case 'RightBottom':\n pos.left += tipWidth + tipAdjust;\n pos.top -= (tipHeightAdjust);\n break;\n case 'BottomRight':\n pos.top += (tipHeight + tipAdjust);\n pos.left -= (tipWidthAdjust);\n break;\n case 'BottomCenter':\n pos.top += (tipHeight + tipAdjust);\n pos.left -= (tooltipEleWidth / 2);\n break;\n case 'BottomLeft':\n pos.top += (tipHeight + tipAdjust);\n pos.left -= (tooltipEleWidth - tipWidthAdjust);\n break;\n case 'LeftBottom':\n pos.left -= (tipWidth + tooltipEleWidth + tipAdjust);\n pos.top -= (tipHeightAdjust);\n break;\n case 'LeftCenter':\n pos.left -= (tipWidth + tooltipEleWidth + tipAdjust);\n pos.top -= (tooltipEleHeight / 2);\n break;\n case 'LeftTop':\n pos.left -= (tipWidth + tooltipEleWidth + tipAdjust);\n pos.top -= (tooltipEleHeight - tipHeightAdjust);\n break;\n case 'TopLeft':\n pos.top -= (tooltipEleHeight + tipHeight + tipAdjust);\n pos.left -= (tooltipEleWidth - tipWidthAdjust);\n break;\n case 'TopRight':\n pos.top -= (tooltipEleHeight + tipHeight + tipAdjust);\n pos.left -= (tipWidthAdjust);\n break;\n default:\n pos.top -= (tooltipEleHeight + tipHeight + tipAdjust);\n pos.left -= (tooltipEleWidth / 2);\n break;\n }\n pos.left += this.offsetX;\n pos.top += this.offsetY;\n return pos;\n };\n Tooltip.prototype.updateTipPosition = function (position) {\n var selEle = selectAll('.' + ARROW_TIP + ',.' + ARROW_TIP_OUTER + ',.' + ARROW_TIP_INNER, this.tooltipEle);\n var removeList = [TIP_BOTTOM, TIP_TOP, TIP_LEFT, TIP_RIGHT];\n removeClass(selEle, removeList);\n this.setTipClass(position);\n addClass(selEle, this.tipClass);\n };\n Tooltip.prototype.adjustArrow = function (target, position, tooltipPositionX, tooltipPositionY) {\n var arrowEle = select('.' + ARROW_TIP, this.tooltipEle);\n if (this.showTipPointer === false || arrowEle === null) {\n return;\n }\n this.updateTipPosition(position);\n var leftValue;\n var topValue;\n this.tooltipEle.style.display = 'block';\n var tooltipWidth = this.tooltipEle.clientWidth;\n var tooltipHeight = this.tooltipEle.clientHeight;\n var arrowInnerELe = select('.' + ARROW_TIP_INNER, this.tooltipEle);\n var tipWidth = arrowEle.offsetWidth;\n var tipHeight = arrowEle.offsetHeight;\n this.tooltipEle.style.display = '';\n if (this.tipClass === TIP_BOTTOM || this.tipClass === TIP_TOP) {\n if (this.tipClass === TIP_BOTTOM) {\n topValue = '99.9%';\n // Arrow icon aligned -2px height from ArrowOuterTip div\n arrowInnerELe.style.top = '-' + (tipHeight - 2) + 'px';\n }\n else {\n topValue = -(tipHeight - 1) + 'px';\n // Arrow icon aligned -6px height from ArrowOuterTip div\n arrowInnerELe.style.top = '-' + (tipHeight - 6) + 'px';\n }\n if (target) {\n var tipPosExclude = tooltipPositionX !== 'Center' || (tooltipWidth > target.offsetWidth) || this.mouseTrail;\n if ((tipPosExclude && tooltipPositionX === 'Left') || (!tipPosExclude && this.tipPointerPosition === 'End')) {\n leftValue = (tooltipWidth - tipWidth - POINTER_ADJUST) + 'px';\n }\n else if ((tipPosExclude && tooltipPositionX === 'Right') || (!tipPosExclude && this.tipPointerPosition === 'Start')) {\n leftValue = POINTER_ADJUST + 'px';\n }\n else if ((tipPosExclude) && (this.tipPointerPosition === 'End' || this.tipPointerPosition === 'Start')) {\n leftValue = (this.tipPointerPosition === 'End') ? ((target.offsetWidth + ((this.tooltipEle.offsetWidth - target.offsetWidth) / 2)) - (tipWidth / 2)) - POINTER_ADJUST + 'px'\n : ((this.tooltipEle.offsetWidth - target.offsetWidth) / 2) - (tipWidth / 2) + POINTER_ADJUST + 'px';\n }\n else {\n leftValue = ((tooltipWidth / 2) - (tipWidth / 2)) + 'px';\n }\n }\n }\n else {\n if (this.tipClass === TIP_RIGHT) {\n leftValue = '99.9%';\n // Arrow icon aligned -2px left from ArrowOuterTip div\n arrowInnerELe.style.left = '-' + (tipWidth - 2) + 'px';\n }\n else {\n leftValue = -(tipWidth - 1) + 'px';\n // Arrow icon aligned -2px from ArrowOuterTip width\n arrowInnerELe.style.left = (-(tipWidth) + (tipWidth - 2)) + 'px';\n }\n var tipPosExclude = tooltipPositionY !== 'Center' || (tooltipHeight > target.offsetHeight) || this.mouseTrail;\n if ((tipPosExclude && tooltipPositionY === 'Top') || (!tipPosExclude && this.tipPointerPosition === 'End')) {\n topValue = (tooltipHeight - tipHeight - POINTER_ADJUST) + 'px';\n }\n else if ((tipPosExclude && tooltipPositionY === 'Bottom') || (!tipPosExclude && this.tipPointerPosition === 'Start')) {\n topValue = POINTER_ADJUST + 'px';\n }\n else {\n topValue = ((tooltipHeight / 2) - (tipHeight / 2)) + 'px';\n }\n }\n arrowEle.style.top = topValue;\n arrowEle.style.left = leftValue;\n };\n Tooltip.prototype.renderContent = function (target) {\n var tooltipContent = select('.' + CONTENT, this.tooltipEle);\n if (this.cssClass) {\n addClass([this.tooltipEle], this.cssClass.split(' '));\n }\n if (target && !isNullOrUndefined(target.getAttribute('title'))) {\n target.setAttribute('data-content', target.getAttribute('title'));\n target.removeAttribute('title');\n }\n if (!isNullOrUndefined(this.content)) {\n tooltipContent.innerHTML = '';\n if (this.content instanceof HTMLElement) {\n tooltipContent.appendChild(this.content);\n }\n else if (typeof this.content === 'string') {\n if (this.enableHtmlSanitizer) {\n this.setProperties({ content: SanitizeHtmlHelper.sanitize(this.content) }, true);\n }\n if (this.enableHtmlParse) {\n var tempFunction = compile(this.content);\n var tempArr = tempFunction({}, this, 'content', this.element.id + 'content', undefined, undefined, tooltipContent, this.root);\n if (tempArr) {\n append(tempArr, tooltipContent);\n }\n }\n else {\n tooltipContent['textContent'] = this.content;\n }\n }\n else {\n var templateFunction = compile(this.content);\n var tempArr = templateFunction({}, this, 'content', this.element.id + 'content', undefined, undefined, tooltipContent);\n if (tempArr) {\n append(tempArr, tooltipContent);\n }\n this.renderReactTemplates();\n }\n }\n else {\n if (target && !isNullOrUndefined(target.getAttribute('data-content'))) {\n tooltipContent.innerHTML = target.getAttribute('data-content');\n }\n }\n };\n Tooltip.prototype.renderCloseIcon = function () {\n if (!this.isSticky) {\n var existingCloseIcon = this.tooltipEle.querySelector('.' + ICON + '.' + CLOSE);\n if (existingCloseIcon) {\n remove(existingCloseIcon);\n }\n return;\n }\n var tipClose = this.createElement('div', { className: ICON + ' ' + CLOSE });\n this.tooltipEle.appendChild(tipClose);\n EventHandler.add(tipClose, Browser.touchStartEvent, this.onStickyClose, this);\n };\n Tooltip.prototype.addDescribedBy = function (target, id) {\n var describedby = (target.getAttribute('aria-describedby') || '').split(/\\s+/);\n if (describedby.indexOf(id) < 0) {\n describedby.push(id);\n }\n attributes(target, { 'aria-describedby': describedby.join(' ').trim(), 'data-tooltip-id': id });\n };\n Tooltip.prototype.removeDescribedBy = function (target) {\n var id = target.getAttribute('data-tooltip-id');\n var describedby = (target.getAttribute('aria-describedby') || '').split(/\\s+/);\n var index = describedby.indexOf(id);\n if (index !== -1) {\n describedby.splice(index, 1);\n }\n target.removeAttribute('data-tooltip-id');\n var orgdescribedby = describedby.join(' ').trim();\n if (orgdescribedby) {\n target.setAttribute('aria-describedby', orgdescribedby);\n }\n else {\n target.removeAttribute('aria-describedby');\n }\n };\n Tooltip.prototype.tapHoldHandler = function (evt) {\n clearTimeout(this.autoCloseTimer);\n this.targetHover(evt.originalEvent);\n };\n Tooltip.prototype.touchEndHandler = function (e) {\n var _this = this;\n if (this.isSticky) {\n return;\n }\n var close = function () {\n _this.close();\n };\n this.autoCloseTimer = setTimeout(close, TOUCHEND_HIDE_DELAY);\n };\n Tooltip.prototype.targetClick = function (e) {\n var target;\n if (this.target) {\n target = closest(e.target, this.target);\n }\n else {\n target = this.element;\n }\n if (isNullOrUndefined(target)) {\n return;\n }\n if (target.getAttribute('data-tooltip-id') === null) {\n this.targetHover(e);\n }\n else if (!this.isSticky) {\n this.hideTooltip(this.animation.close, e, target);\n }\n };\n Tooltip.prototype.targetHover = function (e) {\n var target;\n if (this.target) {\n target = closest(e.target, this.target);\n }\n else {\n target = this.element;\n }\n if (isNullOrUndefined(target) || (target.getAttribute('data-tooltip-id') !== null && this.closeDelay === 0)) {\n return;\n }\n var targetList = [].slice.call(selectAll('[data-tooltip-id= \"' + this.ctrlId + '_content\"]', document));\n for (var _i = 0, targetList_1 = targetList; _i < targetList_1.length; _i++) {\n var target_1 = targetList_1[_i];\n this.restoreElement(target_1);\n }\n this.showTooltip(target, this.animation.open, e);\n };\n Tooltip.prototype.mouseMoveBeforeOpen = function (e) {\n this.mouseMoveEvent = e;\n };\n Tooltip.prototype.mouseMoveBeforeRemove = function () {\n if (this.mouseMoveTarget) {\n EventHandler.remove(this.mouseMoveTarget, 'mousemove touchstart', this.mouseMoveBeforeOpen);\n }\n };\n Tooltip.prototype.showTooltip = function (target, showAnimation, e) {\n var _this = this;\n clearTimeout(this.showTimer);\n clearTimeout(this.hideTimer);\n if (this.openDelay && this.mouseTrail) {\n this.mouseMoveBeforeRemove();\n this.mouseMoveTarget = target;\n EventHandler.add(this.mouseMoveTarget, 'mousemove touchstart', this.mouseMoveBeforeOpen, this);\n }\n this.tooltipEventArgs = {\n type: e ? e.type : null, cancel: false, target: target, event: e ? e : null,\n element: this.tooltipEle, isInteracted: !isNullOrUndefined(e)\n };\n var observeCallback = function (beforeRenderArgs) {\n _this.beforeRenderCallback(beforeRenderArgs, target, e, showAnimation);\n };\n this.trigger('beforeRender', this.tooltipEventArgs, observeCallback.bind(this));\n };\n Tooltip.prototype.beforeRenderCallback = function (beforeRenderArgs, target, e, showAnimation) {\n if (beforeRenderArgs.cancel) {\n this.isHidden = true;\n this.clear();\n this.mouseMoveBeforeRemove();\n }\n else {\n this.isHidden = false;\n if (isNullOrUndefined(this.tooltipEle)) {\n this.ctrlId = this.element.getAttribute('id') ?\n getUniqueID(this.element.getAttribute('id')) : getUniqueID('tooltip');\n this.tooltipEle = this.createElement('div', {\n className: TOOLTIP_WRAP + ' ' + POPUP_ROOT + ' ' + POPUP_LIB, attrs: {\n role: 'tooltip', 'aria-hidden': 'false', 'id': this.ctrlId + '_content'\n }, styles: 'width:' +\n formatUnit(this.width) + ';height:' + formatUnit(this.height) + ';position:absolute;'\n });\n this.tooltipBeforeRender(target, this);\n this.tooltipAfterRender(target, e, showAnimation, this);\n }\n else {\n if (target) {\n this.adjustArrow(target, this.position, this.tooltipPositionX, this.tooltipPositionY);\n this.addDescribedBy(target, this.ctrlId + '_content');\n this.renderContent(target);\n PopupAnimation.stop(this.tooltipEle);\n this.reposition(target);\n this.tooltipAfterRender(target, e, showAnimation, this);\n }\n }\n }\n };\n Tooltip.prototype.appendContainer = function (ctrlObj) {\n if (typeof this.container == 'string') {\n if (this.container === 'body') {\n this.containerElement = document.body;\n }\n else {\n this.isBodyContainer = false;\n this.containerElement = select(this.container, document);\n }\n }\n else if (this.container instanceof HTMLElement) {\n this.containerElement = this.container;\n this.isBodyContainer = this.containerElement.tagName === 'BODY';\n }\n if (!this.isBodyContainer) {\n addClass([this.containerElement], POPUP_CONTAINER);\n }\n this.containerElement.appendChild(ctrlObj.tooltipEle);\n };\n Tooltip.prototype.tooltipBeforeRender = function (target, ctrlObj) {\n if (target) {\n if (Browser.isDevice) {\n addClass([ctrlObj.tooltipEle], DEVICE);\n }\n if (ctrlObj.width !== 'auto') {\n ctrlObj.tooltipEle.style.maxWidth = formatUnit(ctrlObj.width);\n }\n ctrlObj.tooltipEle.appendChild(ctrlObj.createElement('div', { className: CONTENT }));\n this.appendContainer(ctrlObj);\n removeClass([ctrlObj.tooltipEle], HIDE_POPUP);\n ctrlObj.addDescribedBy(target, ctrlObj.ctrlId + '_content');\n ctrlObj.renderContent(target);\n addClass([ctrlObj.tooltipEle], POPUP_OPEN);\n if (ctrlObj.showTipPointer) {\n ctrlObj.renderArrow();\n }\n ctrlObj.renderCloseIcon();\n ctrlObj.renderPopup(target);\n ctrlObj.adjustArrow(target, ctrlObj.position, ctrlObj.tooltipPositionX, ctrlObj.tooltipPositionY);\n PopupAnimation.stop(ctrlObj.tooltipEle);\n ctrlObj.reposition(target);\n }\n };\n Tooltip.prototype.tooltipAfterRender = function (target, e, showAnimation, ctrlObj) {\n if (target) {\n removeClass([ctrlObj.tooltipEle], POPUP_OPEN);\n addClass([ctrlObj.tooltipEle], POPUP_CLOSE);\n ctrlObj.tooltipEventArgs = {\n type: e ? e.type : null, cancel: false, target: target, event: e ? e : null,\n element: ctrlObj.tooltipEle, isInteracted: !isNullOrUndefined(e)\n };\n if (ctrlObj.needTemplateReposition() && !ctrlObj.mouseTrail) {\n ctrlObj.tooltipEle.style.display = 'none';\n }\n var observeCallback = function (observedArgs) {\n ctrlObj.beforeOpenCallback(observedArgs, target, showAnimation, e);\n };\n ctrlObj.trigger('beforeOpen', ctrlObj.tooltipEventArgs, observeCallback.bind(ctrlObj));\n }\n };\n Tooltip.prototype.beforeOpenCallback = function (observedArgs, target, showAnimation, e) {\n var _this = this;\n if (observedArgs.cancel) {\n this.isHidden = true;\n this.clear();\n this.mouseMoveBeforeRemove();\n this.restoreElement(target);\n }\n else {\n var openAnimation_1 = {\n name: (showAnimation.effect === 'None' && animationMode === 'Enable') ? 'FadeIn' : this.animation.open.effect,\n duration: showAnimation.duration,\n delay: showAnimation.delay,\n timingFunction: 'easeOut'\n };\n if (showAnimation.effect === 'None') {\n openAnimation_1 = undefined;\n }\n if (this.openDelay > 0) {\n var show = function () {\n if (_this.mouseTrail) {\n EventHandler.add(target, 'mousemove touchstart mouseenter', _this.onMouseMove, _this);\n }\n if (_this.popupObj) {\n _this.popupObj.show(openAnimation_1, target);\n if (_this.mouseMoveEvent && _this.mouseTrail) {\n _this.onMouseMove(_this.mouseMoveEvent);\n }\n }\n };\n this.showTimer = setTimeout(show, this.openDelay);\n }\n else {\n if (this.popupObj) {\n this.popupObj.show(openAnimation_1, target);\n }\n }\n }\n if (e) {\n this.wireMouseEvents(e, target);\n }\n };\n Tooltip.prototype.needTemplateReposition = function () {\n // eslint-disable-next-line\n var tooltip = this;\n return !isNullOrUndefined(tooltip.viewContainerRef)\n && typeof tooltip.viewContainerRef !== 'string' || this.isReact;\n };\n Tooltip.prototype.checkCollision = function (target, x, y) {\n var elePos = {\n left: x, top: y, position: this.position,\n horizontal: this.tooltipPositionX, vertical: this.tooltipPositionY\n };\n var affectedPos = isCollide(this.tooltipEle, this.checkCollideTarget(), x, y);\n if (affectedPos.length > 0) {\n elePos.horizontal = affectedPos.indexOf('left') >= 0 ? 'Right' : affectedPos.indexOf('right') >= 0 ? 'Left' :\n this.tooltipPositionX;\n elePos.vertical = affectedPos.indexOf('top') >= 0 ? 'Bottom' : affectedPos.indexOf('bottom') >= 0 ? 'Top' :\n this.tooltipPositionY;\n }\n return elePos;\n };\n Tooltip.prototype.calculateElementPosition = function (pos, offsetPos) {\n return [this.isBodyContainer ? pos.left + offsetPos.left :\n (pos.left - this.containerElement.offsetLeft) + offsetPos.left + window.pageXOffset + this.containerElement.scrollLeft,\n this.isBodyContainer ? pos.top + offsetPos.top :\n (pos.top - this.containerElement.offsetTop) + offsetPos.top + window.pageYOffset + this.containerElement.scrollTop];\n };\n Tooltip.prototype.collisionFlipFit = function (target, x, y) {\n var elePos = this.checkCollision(target, x, y);\n var newpos = elePos.position;\n if (this.tooltipPositionY !== elePos.vertical) {\n newpos = ((this.position.indexOf('Bottom') === 0 || this.position.indexOf('Top') === 0) ?\n elePos.vertical + this.tooltipPositionX : this.tooltipPositionX + elePos.vertical);\n }\n if (this.tooltipPositionX !== elePos.horizontal) {\n if (newpos.indexOf('Left') === 0) {\n elePos.vertical = (newpos === 'LeftTop' || newpos === 'LeftCenter') ? 'Top' : 'Bottom';\n newpos = (elePos.vertical + 'Left');\n }\n if (newpos.indexOf('Right') === 0) {\n elePos.vertical = (newpos === 'RightTop' || newpos === 'RightCenter') ? 'Top' : 'Bottom';\n newpos = (elePos.vertical + 'Right');\n }\n elePos.horizontal = this.tooltipPositionX;\n }\n this.tooltipEventArgs = {\n type: null, cancel: false, target: target, event: null,\n element: this.tooltipEle, collidedPosition: newpos\n };\n this.trigger('beforeCollision', this.tooltipEventArgs);\n if (this.tooltipEventArgs.cancel) {\n newpos = this.position;\n }\n else {\n var elePosVertical = elePos.vertical;\n var elePosHorizontal = elePos.horizontal;\n if (elePos.position !== newpos) {\n var pos = calculatePosition(target, elePosHorizontal, elePosVertical, !this.isBodyContainer, this.isBodyContainer ? null : this.containerElement.getBoundingClientRect());\n this.adjustArrow(target, newpos, elePosHorizontal, elePosVertical);\n var scalingFactors = this.getScalingFactor(target);\n var offsetPos = this.calculateTooltipOffset(newpos, scalingFactors.x, scalingFactors.y);\n offsetPos.top -= this.getOffSetPosition('TopBottom', newpos, this.offsetY);\n offsetPos.left -= this.getOffSetPosition('RightLeft', newpos, this.offsetX);\n elePos.position = newpos;\n var elePosition = this.calculateElementPosition(pos, offsetPos);\n elePos.left = elePosition[0];\n elePos.top = elePosition[1];\n }\n else {\n this.adjustArrow(target, newpos, elePosHorizontal, elePosVertical);\n }\n }\n var eleOffset = { left: elePos.left, top: elePos.top };\n var position = fit(this.tooltipEle, this.checkCollideTarget(), { X: true, Y: this.windowCollision }, eleOffset);\n this.tooltipEle.style.display = 'block';\n var arrowEle = select('.' + ARROW_TIP, this.tooltipEle);\n if (this.showTipPointer && arrowEle != null && (newpos.indexOf('Bottom') === 0 || newpos.indexOf('Top') === 0)) {\n var arrowleft = parseInt(arrowEle.style.left, 10) - (position.left - elePos.left);\n if (arrowleft < 0) {\n arrowleft = 0;\n }\n else if ((arrowleft + arrowEle.offsetWidth) > this.tooltipEle.clientWidth) {\n arrowleft = this.tooltipEle.clientWidth - arrowEle.offsetWidth;\n }\n arrowEle.style.left = arrowleft.toString() + 'px';\n }\n this.tooltipEle.style.display = '';\n eleOffset.left = position.left;\n eleOffset.top = position.top;\n return eleOffset;\n };\n Tooltip.prototype.getOffSetPosition = function (positionString, newPos, offsetType) {\n return ((positionString.indexOf(this.position.split(/(?=[A-Z])/)[0]) !== -1) &&\n (positionString.indexOf(newPos.split(/(?=[A-Z])/)[0]) !== -1)) ? (2 * offsetType) : 0;\n };\n Tooltip.prototype.checkCollideTarget = function () {\n return !this.windowCollision && this.target ? this.element : null;\n };\n Tooltip.prototype.hideTooltip = function (hideAnimation, e, targetElement) {\n var _this = this;\n if (this.closeDelay > 0) {\n clearTimeout(this.hideTimer);\n clearTimeout(this.showTimer);\n var hide = function () {\n if (_this.closeDelay && _this.tooltipEle && _this.isTooltipOpen) {\n return;\n }\n _this.tooltipHide(hideAnimation, e, targetElement);\n };\n this.hideTimer = setTimeout(hide, this.closeDelay);\n }\n else {\n this.tooltipHide(hideAnimation, e, targetElement);\n }\n };\n Tooltip.prototype.tooltipHide = function (hideAnimation, e, targetElement) {\n var _this = this;\n var target;\n if (e) {\n target = this.target ? (targetElement || e.target) : this.element;\n }\n else {\n target = select('[data-tooltip-id= \"' + this.ctrlId + '_content\"]', document);\n }\n this.tooltipEventArgs = {\n type: e ? e.type : null, cancel: false, target: target, event: e ? e : null,\n element: this.tooltipEle, isInteracted: !isNullOrUndefined(e)\n };\n // this line commented for close the tooltip popup element even the target element destroyed in a page.\n //if (isNullOrUndefined(target)) { return; }\n this.trigger('beforeClose', this.tooltipEventArgs, function (observedArgs) {\n if (!observedArgs.cancel) {\n _this.mouseMoveBeforeRemove();\n _this.popupHide(hideAnimation, target, e);\n }\n else {\n _this.isHidden = false;\n }\n });\n this.tooltipEventArgs = null;\n };\n Tooltip.prototype.popupHide = function (hideAnimation, target, e) {\n if (target && e) {\n this.restoreElement(target);\n }\n this.isHidden = true;\n var closeAnimation = {\n name: (hideAnimation.effect === 'None' && animationMode === 'Enable') ? 'FadeOut' : this.animation.close.effect,\n duration: hideAnimation.duration,\n delay: hideAnimation.delay,\n timingFunction: 'easeIn'\n };\n if (hideAnimation.effect === 'None') {\n closeAnimation = undefined;\n }\n if (this.popupObj) {\n this.popupObj.hide(closeAnimation);\n }\n };\n Tooltip.prototype.restoreElement = function (target) {\n this.unwireMouseEvents(target);\n if (!isNullOrUndefined(target.getAttribute('data-content'))) {\n target.setAttribute('title', target.getAttribute('data-content'));\n target.removeAttribute('data-content');\n }\n this.removeDescribedBy(target);\n };\n Tooltip.prototype.clear = function () {\n var target = this.findTarget();\n if (target) {\n this.restoreElement(target);\n }\n if (this.tooltipEle) {\n removeClass([this.tooltipEle], POPUP_CLOSE);\n addClass([this.tooltipEle], POPUP_OPEN);\n }\n if (this.isHidden) {\n if (this.popupObj) {\n this.popupObj.destroy();\n }\n if (this.tooltipEle) {\n remove(this.tooltipEle);\n }\n this.tooltipEle = null;\n this.popupObj = null;\n }\n };\n Tooltip.prototype.tooltipHover = function (e) {\n if (this.tooltipEle) {\n this.isTooltipOpen = true;\n }\n };\n Tooltip.prototype.tooltipMouseOut = function (e) {\n this.isTooltipOpen = false;\n this.hideTooltip(this.animation.close, e, this.findTarget());\n };\n Tooltip.prototype.onMouseOut = function (e) {\n var enteredElement = e.relatedTarget;\n // don't close the tooltip only if it is tooltip content element\n if (enteredElement && !this.mouseTrail) {\n var checkForTooltipElement = closest(enteredElement, \".\" + TOOLTIP_WRAP + \".\" + POPUP_LIB + \".\" + POPUP_ROOT);\n if (checkForTooltipElement) {\n EventHandler.add(checkForTooltipElement, 'mouseleave', this.tooltipElementMouseOut, this);\n }\n else {\n this.hideTooltip(this.animation.close, e, this.findTarget());\n if (this.closeDelay === 0) {\n this.clear();\n }\n }\n }\n else {\n this.hideTooltip(this.animation.close, e, this.findTarget());\n this.clear();\n }\n };\n Tooltip.prototype.tooltipElementMouseOut = function (e) {\n this.hideTooltip(this.animation.close, e, this.findTarget());\n EventHandler.remove(this.element, 'mouseleave', this.tooltipElementMouseOut);\n this.clear();\n };\n Tooltip.prototype.onStickyClose = function (e) {\n this.close();\n };\n Tooltip.prototype.onMouseMove = function (event) {\n var eventPageX = 0;\n var eventPageY = 0;\n if (event.type.indexOf('touch') > -1) {\n event.preventDefault();\n eventPageX = event.touches[0].pageX;\n eventPageY = event.touches[0].pageY;\n }\n else {\n eventPageX = event.pageX;\n eventPageY = event.pageY;\n }\n PopupAnimation.stop(this.tooltipEle);\n removeClass([this.tooltipEle], POPUP_CLOSE);\n addClass([this.tooltipEle], POPUP_OPEN);\n this.adjustArrow(event.target, this.position, this.tooltipPositionX, this.tooltipPositionY);\n var scalingFactors = this.getScalingFactor(event.target);\n var pos = this.calculateTooltipOffset(this.position, scalingFactors.x, scalingFactors.y);\n var x = eventPageX + pos.left + this.offsetX;\n var y = eventPageY + pos.top + this.offsetY;\n var elePos = this.checkCollision(event.target, x, y);\n if (this.tooltipPositionX !== elePos.horizontal || this.tooltipPositionY !== elePos.vertical) {\n var newpos = (this.position.indexOf('Bottom') === 0 || this.position.indexOf('Top') === 0) ?\n elePos.vertical + elePos.horizontal : elePos.horizontal + elePos.vertical;\n elePos.position = newpos;\n this.adjustArrow(event.target, elePos.position, elePos.horizontal, elePos.vertical);\n var colpos = this.calculateTooltipOffset(elePos.position, scalingFactors.x, scalingFactors.y);\n elePos.left = eventPageX + colpos.left - this.offsetX;\n elePos.top = eventPageY + colpos.top - this.offsetY;\n }\n this.tooltipEle.style.left = elePos.left + 'px';\n this.tooltipEle.style.top = elePos.top + 'px';\n };\n Tooltip.prototype.keyDown = function (event) {\n if (this.tooltipEle && event.keyCode === 27) {\n this.close();\n }\n };\n Tooltip.prototype.touchEnd = function (e) {\n if (this.tooltipEle && closest(e.target, '.' + ROOT) === null && !this.isSticky) {\n this.close();\n }\n };\n Tooltip.prototype.scrollHandler = function (e) {\n if (this.tooltipEle && !this.isSticky) {\n if (!(closest(e.target, \".\" + TOOLTIP_WRAP + \".\" + POPUP_LIB + \".\" + POPUP_ROOT))) {\n this.close();\n }\n }\n };\n /**\n * Core method that initializes the control rendering.\n *\n * @private\n * @returns {void}\n */\n Tooltip.prototype.render = function () {\n this.initialize();\n this.wireEvents(this.opensOn);\n this.renderComplete();\n };\n /**\n * Initializes the values of private members.\n *\n * @private\n * @returns {void}\n */\n Tooltip.prototype.preRender = function () {\n this.tipClass = TIP_BOTTOM;\n this.tooltipPositionX = 'Center';\n this.tooltipPositionY = 'Top';\n this.isHidden = true;\n };\n /**\n * Binding events to the Tooltip element.\n *\n * @hidden\n * @param {string} trigger - specify the trigger string to the function\n * @returns {void}\n *\n */\n Tooltip.prototype.wireEvents = function (trigger) {\n var triggerList = this.getTriggerList(trigger);\n for (var _i = 0, triggerList_1 = triggerList; _i < triggerList_1.length; _i++) {\n var opensOn = triggerList_1[_i];\n if (opensOn === 'Custom') {\n return;\n }\n if (opensOn === 'Focus') {\n this.wireFocusEvents();\n }\n if (opensOn === 'Click') {\n EventHandler.add(this.element, Browser.touchStartEvent, this.targetClick, this);\n }\n if (opensOn === 'Hover') {\n if (Browser.isDevice) {\n this.touchModule = new Touch(this.element, {\n tapHoldThreshold: TAPHOLD_THRESHOLD,\n tapHold: this.tapHoldHandler.bind(this)\n });\n EventHandler.add(this.element, Browser.touchEndEvent, this.touchEndHandler, this);\n }\n else {\n EventHandler.add(this.element, 'mouseover', this.targetHover, this);\n }\n }\n }\n EventHandler.add(document, 'touchend', this.touchEnd, this);\n EventHandler.add(document, 'scroll wheel', this.scrollHandler, this);\n EventHandler.add(window, 'resize', this.windowResize, this);\n EventHandler.add(document, 'keydown', this.keyDown, this);\n };\n Tooltip.prototype.getTriggerList = function (trigger) {\n if (trigger === 'Auto') {\n trigger = (Browser.isDevice) ? 'Hover' : 'Hover Focus';\n }\n return trigger.split(' ');\n };\n Tooltip.prototype.wireFocusEvents = function () {\n if (!isNullOrUndefined(this.target)) {\n var targetList = [].slice.call(selectAll(this.target, this.element));\n this.targetsList = targetList;\n for (var _i = 0, targetList_2 = targetList; _i < targetList_2.length; _i++) {\n var target = targetList_2[_i];\n EventHandler.add(target, 'focus', this.targetHover, this);\n }\n }\n else {\n EventHandler.add(this.element, 'focusin', this.targetHover, this);\n }\n };\n Tooltip.prototype.wireMouseEvents = function (e, target) {\n if (this.tooltipEle) {\n if (!this.isSticky) {\n if (e.type === 'focus') {\n EventHandler.add(target, 'blur', this.onMouseOut, this);\n }\n if (e.type === 'focusin') {\n EventHandler.add(target, 'focusout', this.onMouseOut, this);\n }\n if (e.type === 'mouseover') {\n EventHandler.add(target, 'mouseleave', this.onMouseOut, this);\n }\n if (this.closeDelay) {\n EventHandler.add(this.tooltipEle, 'mouseenter', this.tooltipHover, this);\n EventHandler.add(this.tooltipEle, 'mouseleave', this.tooltipMouseOut, this);\n }\n }\n if (this.mouseTrail && this.openDelay === 0) {\n EventHandler.add(target, 'mousemove touchstart mouseenter', this.onMouseMove, this);\n }\n }\n };\n /**\n * Unbinding events from the element on widget destroy.\n *\n * @hidden\n *\n * @param {string} trigger - specify the trigger string to the function\n * @returns {void}\n *\n */\n Tooltip.prototype.unwireEvents = function (trigger) {\n var triggerList = this.getTriggerList(trigger);\n for (var _i = 0, triggerList_2 = triggerList; _i < triggerList_2.length; _i++) {\n var opensOn = triggerList_2[_i];\n if (opensOn === 'Custom') {\n return;\n }\n if (opensOn === 'Focus') {\n this.unwireFocusEvents();\n }\n if (opensOn === 'Click') {\n EventHandler.remove(this.element, Browser.touchStartEvent, this.targetClick);\n }\n if (opensOn === 'Hover') {\n if (Browser.isDevice) {\n if (this.touchModule) {\n this.touchModule.destroy();\n }\n EventHandler.remove(this.element, Browser.touchEndEvent, this.touchEndHandler);\n }\n else {\n EventHandler.remove(this.element, 'mouseover', this.targetHover);\n }\n }\n }\n EventHandler.remove(document, 'touchend', this.touchEnd);\n EventHandler.remove(document, 'scroll wheel', this.scrollHandler);\n EventHandler.remove(window, 'resize', this.windowResize);\n EventHandler.remove(document, 'keydown', this.keyDown);\n };\n Tooltip.prototype.unwireFocusEvents = function () {\n if (!isNullOrUndefined(this.target)) {\n var targetList = [].slice.call(selectAll(this.target, this.element));\n for (var _i = 0, targetList_3 = targetList; _i < targetList_3.length; _i++) {\n var target = targetList_3[_i];\n EventHandler.remove(target, 'focus', this.targetHover);\n }\n }\n else {\n EventHandler.remove(this.element, 'focusin', this.targetHover);\n }\n };\n Tooltip.prototype.unwireMouseEvents = function (target) {\n if (!this.isSticky) {\n var triggerList = this.getTriggerList(this.opensOn);\n for (var _i = 0, triggerList_3 = triggerList; _i < triggerList_3.length; _i++) {\n var opensOn = triggerList_3[_i];\n if (opensOn === 'Focus') {\n EventHandler.remove(target, 'blur', this.onMouseOut);\n EventHandler.remove(target, 'focusout', this.onMouseOut);\n }\n if (opensOn === 'Hover' && !Browser.isDevice) {\n EventHandler.remove(target, 'mouseleave', this.onMouseOut);\n }\n }\n if (this.closeDelay) {\n EventHandler.remove(target, 'mouseenter', this.tooltipHover);\n EventHandler.remove(target, 'mouseleave', this.tooltipMouseOut);\n }\n }\n if (this.mouseTrail) {\n EventHandler.remove(target, 'mousemove touchstart mouseenter', this.onMouseMove);\n }\n };\n Tooltip.prototype.findTarget = function () {\n var target = select('[data-tooltip-id= \"' + this.ctrlId + '_content\"]', document);\n return target;\n };\n /**\n * Core method to return the component name.\n *\n * @private\n *\n * @returns {string} - this method returns module name.\n */\n Tooltip.prototype.getModuleName = function () {\n return 'tooltip';\n };\n /**\n * Returns the properties to be maintained in the persisted state.\n *\n * @private\n *\n * @returns {string} - this method returns persisted data.\n */\n Tooltip.prototype.getPersistData = function () {\n return this.addOnPersist([]);\n };\n /**\n * Called internally, if any of the property value changed.\n *\n * @private\n *\n * @param {TooltipModel} newProp - this param gives new property values to the method\n * @param {TooltipModel} oldProp - this param gives old property values to the method\n * @returns {void}\n *\n */\n Tooltip.prototype.onPropertyChanged = function (newProp, oldProp) {\n var targetElement = this.findTarget();\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'width':\n if (this.tooltipEle && targetElement) {\n this.tooltipEle.style.width = this.tooltipEle.style.maxWidth = formatUnit(newProp.width);\n this.reposition(targetElement);\n }\n break;\n case 'height':\n if (this.tooltipEle && targetElement) {\n this.tooltipEle.style.height = formatUnit(newProp.height);\n this.reposition(targetElement);\n }\n break;\n case 'content':\n if (this.tooltipEle) {\n this.renderContent();\n }\n break;\n case 'opensOn':\n this.unwireEvents(oldProp.opensOn);\n this.wireEvents(newProp.opensOn);\n break;\n case 'position':\n this.formatPosition();\n if (this.tooltipEle && targetElement) {\n var arrowInnerELe = select('.' + ARROW_TIP_INNER, this.tooltipEle);\n if (arrowInnerELe) {\n arrowInnerELe.style.top = arrowInnerELe.style.left = null;\n }\n this.reposition(targetElement);\n }\n break;\n case 'tipPointerPosition':\n if (this.tooltipEle && targetElement) {\n this.reposition(targetElement);\n }\n break;\n case 'offsetX':\n if (this.tooltipEle) {\n var x = newProp.offsetX - oldProp.offsetX;\n this.tooltipEle.style.left = (parseInt(this.tooltipEle.style.left, 10) + (x)).toString() + 'px';\n }\n break;\n case 'offsetY':\n if (this.tooltipEle) {\n var y = newProp.offsetY - oldProp.offsetY;\n this.tooltipEle.style.top = (parseInt(this.tooltipEle.style.top, 10) + (y)).toString() + 'px';\n }\n break;\n case 'cssClass':\n if (this.tooltipEle) {\n if (oldProp.cssClass) {\n removeClass([this.tooltipEle], oldProp.cssClass.split(' '));\n }\n if (newProp.cssClass) {\n addClass([this.tooltipEle], newProp.cssClass.split(' '));\n }\n }\n break;\n case 'enableRtl':\n if (this.tooltipEle) {\n if (this.enableRtl) {\n addClass([this.tooltipEle], RTL);\n }\n else {\n removeClass([this.tooltipEle], RTL);\n }\n }\n break;\n case 'isSticky':\n if (this.tooltipEle && targetElement) {\n this.renderCloseIcon();\n this.reposition(targetElement);\n }\n break;\n case 'container':\n if (!isNullOrUndefined(this.containerElement)) {\n removeClass([this.containerElement], POPUP_CONTAINER);\n }\n this.container = newProp.container;\n if (this.tooltipEle && targetElement) {\n this.appendContainer(this);\n this.reposition(targetElement);\n }\n }\n }\n };\n /**\n * It is used to show the Tooltip on the specified target with specific animation settings.\n *\n * @param {HTMLElement} element - Target element where the Tooltip is to be displayed. (It is an optional parameter)\n * @param {TooltipAnimationSettings} animation - Sets the specific animation, while showing the Tooltip on the screen. (It is an optional parameter)\n * @returns {void}\n */\n Tooltip.prototype.open = function (element, animation) {\n if (isNullOrUndefined(animation)) {\n animation = this.animation.open;\n }\n if (isNullOrUndefined(element)) {\n element = this.element;\n }\n if (element.style.display === 'none') {\n return;\n }\n this.showTooltip(element, animation);\n };\n /**\n * It is used to hide the Tooltip with specific animation effect.\n *\n * @param {TooltipAnimationSettings} animation - Sets the specific animation when hiding Tooltip from the screen. (It is an optional parameter)\n * @returns {void}\n */\n Tooltip.prototype.close = function (animation) {\n if (!animation) {\n animation = this.animation.close;\n }\n this.hideTooltip(animation);\n };\n /**\n * It is used to refresh the Tooltip content and its position.\n *\n * @param {HTMLElement} target - Target element where the Tooltip content or position needs to be refreshed.\n * @returns {void}\n */\n Tooltip.prototype.refresh = function (target) {\n if (this.tooltipEle) {\n this.renderContent(target);\n }\n if (this.popupObj && target) {\n this.reposition(target);\n }\n if (!isNullOrUndefined(this.targetsList) && !isNullOrUndefined(this.target)) {\n var target_2 = selectAll(this.target, this.element);\n if (target_2.length !== this.targetsList.length) {\n this.unwireEvents(this.opensOn);\n this.wireEvents(this.opensOn);\n }\n }\n };\n /**\n * It is used to destroy the Tooltip component.\n * @method destroy\n * @returns {void}\n * @memberof Tooltip\n */\n Tooltip.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n if (this.tooltipEle) {\n remove(this.tooltipEle);\n }\n if (this.popupObj) {\n this.popupObj.destroy();\n }\n removeClass([this.element], ROOT);\n this.unwireEvents(this.opensOn);\n this.unwireMouseEvents(this.element);\n this.tooltipEle = null;\n this.popupObj = null;\n var currentTarget = selectAll('[data-tooltip-id= \"' + this.ctrlId + '_content\"]', this.element);\n for (var _i = 0, currentTarget_1 = currentTarget; _i < currentTarget_1.length; _i++) {\n var target = currentTarget_1[_i];\n this.restoreElement(target);\n }\n };\n __decorate([\n Property('auto')\n ], Tooltip.prototype, \"width\", void 0);\n __decorate([\n Property('auto')\n ], Tooltip.prototype, \"height\", void 0);\n __decorate([\n Property()\n ], Tooltip.prototype, \"content\", void 0);\n __decorate([\n Property('body')\n ], Tooltip.prototype, \"container\", void 0);\n __decorate([\n Property()\n ], Tooltip.prototype, \"target\", void 0);\n __decorate([\n Property('TopCenter')\n ], Tooltip.prototype, \"position\", void 0);\n __decorate([\n Property(0)\n ], Tooltip.prototype, \"offsetX\", void 0);\n __decorate([\n Property(0)\n ], Tooltip.prototype, \"offsetY\", void 0);\n __decorate([\n Property(true)\n ], Tooltip.prototype, \"showTipPointer\", void 0);\n __decorate([\n Property(true)\n ], Tooltip.prototype, \"enableHtmlParse\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"windowCollision\", void 0);\n __decorate([\n Property('Auto')\n ], Tooltip.prototype, \"tipPointerPosition\", void 0);\n __decorate([\n Property('Auto')\n ], Tooltip.prototype, \"opensOn\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"mouseTrail\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"isSticky\", void 0);\n __decorate([\n Complex({}, Animation)\n ], Tooltip.prototype, \"animation\", void 0);\n __decorate([\n Property(0)\n ], Tooltip.prototype, \"openDelay\", void 0);\n __decorate([\n Property(0)\n ], Tooltip.prototype, \"closeDelay\", void 0);\n __decorate([\n Property()\n ], Tooltip.prototype, \"cssClass\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"enableHtmlSanitizer\", void 0);\n __decorate([\n Property('')\n ], Tooltip.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"beforeRender\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"beforeOpen\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"afterOpen\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"beforeClose\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"afterClose\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"beforeCollision\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"destroyed\", void 0);\n Tooltip = __decorate([\n NotifyPropertyChanges\n ], Tooltip);\n return Tooltip;\n}(Component));\nexport { Tooltip };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n// eslint-disable-next-line @typescript-eslint/triple-slash-reference\n/// <reference path='../calendar/calendar-model.d.ts'/>\nimport { EventHandler, Property, Internationalization, NotifyPropertyChanges } from '@syncfusion/ej2-base';\nimport { KeyboardEvents, Animation, Event, extend, L10n, Browser, formatUnit } from '@syncfusion/ej2-base';\nimport { detach, addClass, removeClass, closest, attributes, Touch } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, setValue, getUniqueID } from '@syncfusion/ej2-base';\nimport { Popup } from '@syncfusion/ej2-popups';\nimport { Input } from '@syncfusion/ej2-inputs';\nimport { Calendar } from '../calendar/calendar';\n//class constant defination\nvar DATEWRAPPER = 'e-date-wrapper';\nvar ROOT = 'e-datepicker';\nvar LIBRARY = 'e-lib';\nvar CONTROL = 'e-control';\nvar POPUPWRAPPER = 'e-popup-wrapper';\nvar INPUTWRAPPER = 'e-input-group-icon';\nvar POPUP = 'e-popup';\nvar INPUTCONTAINER = 'e-input-group';\nvar INPUTFOCUS = 'e-input-focus';\nvar INPUTROOT = 'e-input';\nvar ERROR = 'e-error';\nvar ACTIVE = 'e-active';\nvar OVERFLOW = 'e-date-overflow';\nvar DATEICON = 'e-date-icon';\nvar CLEARICON = 'e-clear-icon';\nvar ICONS = 'e-icons';\nvar OPENDURATION = 300;\nvar OFFSETVALUE = 4;\nvar SELECTED = 'e-selected';\nvar FOCUSEDDATE = 'e-focused-date';\nvar NONEDIT = 'e-non-edit';\nvar containerAttr = ['title', 'class', 'style'];\n/**\n * Represents the DatePicker component that allows user to select\n * or enter a date value.\n * ```html\n * <input id='datepicker'/>\n * ```\n * ```typescript\n * <script>\n * let datePickerObject:DatePicker = new DatePicker({ value: new Date() });\n * datePickerObject.appendTo('#datepicker');\n * </script>\n * ```\n */\nvar DatePicker = /** @class */ (function (_super) {\n __extends(DatePicker, _super);\n /**\n * Constructor for creating the widget.\n *\n * @param {DatePickerModel} options - Specifies the DatePicker model.\n * @param {string | HTMLInputElement} element - Specifies the element to render as component.\n * @private\n */\n function DatePicker(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.isDateIconClicked = false;\n _this.isAltKeyPressed = false;\n _this.isInteracted = true;\n _this.invalidValueString = null;\n _this.checkPreviousValue = null;\n _this.maskedDateValue = '';\n _this.isAngular = false;\n _this.preventChange = false;\n _this.isIconClicked = false;\n _this.isDynamicValueChanged = false;\n _this.moduleName = _this.getModuleName();\n _this.isFocused = false;\n _this.isBlur = false;\n _this.isKeyAction = false;\n _this.datepickerOptions = options;\n return _this;\n }\n /**\n * To Initialize the control rendering.\n *\n * @returns {void}\n * @private\n */\n DatePicker.prototype.render = function () {\n this.initialize();\n this.bindEvents();\n if (this.floatLabelType === 'Auto') {\n Input.calculateWidth(this.inputElement, this.inputWrapper.container);\n }\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-icon');\n }\n if (!isNullOrUndefined(closest(this.element, 'fieldset')) && closest(this.element, 'fieldset').disabled) {\n this.enabled = false;\n }\n this.renderComplete();\n this.setTimeZone(this.serverTimezoneOffset);\n };\n DatePicker.prototype.setTimeZone = function (offsetValue) {\n if (!isNullOrUndefined(this.serverTimezoneOffset) && this.value) {\n var clientTimeZoneDiff = new Date().getTimezoneOffset() / 60;\n var serverTimezoneDiff = offsetValue;\n var timeZoneDiff = serverTimezoneDiff + clientTimeZoneDiff;\n timeZoneDiff = this.isDayLightSaving() ? timeZoneDiff-- : timeZoneDiff;\n this.value = new Date((this.value).getTime() + (timeZoneDiff * 60 * 60 * 1000));\n this.updateInput();\n }\n };\n DatePicker.prototype.isDayLightSaving = function () {\n var firstOffset = new Date(this.value.getFullYear(), 0, 1).getTimezoneOffset();\n var secondOffset = new Date(this.value.getFullYear(), 6, 1).getTimezoneOffset();\n return (this.value.getTimezoneOffset() < Math.max(firstOffset, secondOffset));\n };\n DatePicker.prototype.setAllowEdit = function () {\n if (this.allowEdit) {\n if (!this.readonly) {\n this.inputElement.removeAttribute('readonly');\n }\n }\n else {\n attributes(this.inputElement, { 'readonly': '' });\n }\n this.updateIconState();\n };\n DatePicker.prototype.updateIconState = function () {\n if (!this.allowEdit && this.inputWrapper && !this.readonly) {\n if (this.inputElement.value === '') {\n removeClass([this.inputWrapper.container], [NONEDIT]);\n }\n else {\n addClass([this.inputWrapper.container], [NONEDIT]);\n }\n }\n else if (this.inputWrapper) {\n removeClass([this.inputWrapper.container], [NONEDIT]);\n }\n };\n DatePicker.prototype.initialize = function () {\n this.checkInvalidValue(this.value);\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n this.createInput();\n this.updateHtmlAttributeToWrapper();\n this.setAllowEdit();\n if (this.enableMask && !this.value && this.maskedDateValue && (this.floatLabelType === 'Always' || !this.floatLabelType || !this.placeholder)) {\n this.updateInput(true);\n this.updateInputValue(this.maskedDateValue);\n }\n else if (!this.enableMask) {\n this.updateInput(true);\n }\n this.previousElementValue = this.inputElement.value;\n this.previousDate = !isNullOrUndefined(this.value) ? new Date(+this.value) : null;\n this.inputElement.setAttribute('value', this.inputElement.value);\n this.inputValueCopy = this.value;\n };\n DatePicker.prototype.createInput = function () {\n var ariaAttrs = {\n 'aria-atomic': 'true', 'aria-expanded': 'false',\n 'role': 'combobox', 'autocomplete': 'off', 'autocorrect': 'off',\n 'autocapitalize': 'off', 'spellcheck': 'false', 'aria-invalid': 'false', 'aria-label': this.getModuleName()\n };\n if (this.getModuleName() === 'datepicker') {\n var l10nLocale = { placeholder: this.placeholder };\n this.globalize = new Internationalization(this.locale);\n this.l10n = new L10n('datepicker', l10nLocale, this.locale);\n this.setProperties({ placeholder: this.placeholder || this.l10n.getConstant('placeholder') }, true);\n }\n if (this.fullScreenMode && Browser.isDevice) {\n this.cssClass += ' ' + \"e-popup-expand\";\n }\n var updatedCssClassValues = this.cssClass;\n if (!isNullOrUndefined(this.cssClass) && this.cssClass !== '') {\n updatedCssClassValues = (this.cssClass.replace(/\\s+/g, ' ')).trim();\n }\n var isBindClearAction = this.enableMask ? false : true;\n this.inputWrapper = Input.createInput({\n element: this.inputElement,\n floatLabelType: this.floatLabelType,\n bindClearAction: isBindClearAction,\n properties: {\n readonly: this.readonly,\n placeholder: this.placeholder,\n cssClass: updatedCssClassValues,\n enabled: this.enabled,\n enableRtl: this.enableRtl,\n showClearButton: this.showClearButton\n },\n buttons: [INPUTWRAPPER + ' ' + DATEICON + ' ' + ICONS]\n }, this.createElement);\n this.setWidth(this.width);\n if (this.inputElement.name !== '') {\n this.inputElement.setAttribute('name', '' + this.inputElement.getAttribute('name'));\n }\n else {\n this.inputElement.setAttribute('name', '' + this.element.id);\n }\n attributes(this.inputElement, ariaAttrs);\n if (!this.enabled) {\n this.inputElement.setAttribute('aria-disabled', 'true');\n this.inputElement.tabIndex = -1;\n }\n else {\n this.inputElement.setAttribute('aria-disabled', 'false');\n this.inputElement.setAttribute('tabindex', this.tabIndex);\n }\n Input.addAttributes({ 'aria-label': 'select', 'role': 'button' }, this.inputWrapper.buttons[0]);\n addClass([this.inputWrapper.container], DATEWRAPPER);\n };\n DatePicker.prototype.updateInput = function (isDynamic, isBlur) {\n if (isDynamic === void 0) { isDynamic = false; }\n if (isBlur === void 0) { isBlur = false; }\n var formatOptions;\n if (this.value && !this.isCalendar()) {\n this.disabledDates(isDynamic, isBlur);\n }\n if (isNaN(+new Date(this.checkValue(this.value)))) {\n this.setProperties({ value: null }, true);\n }\n if (this.strictMode) {\n //calls the Calendar processDate protected method to update the date value according to the strictMode true behaviour.\n _super.prototype.validateDate.call(this);\n this.minMaxUpdates();\n _super.prototype.minMaxUpdate.call(this);\n }\n if (!isNullOrUndefined(this.value)) {\n var dateValue = this.value;\n var dateString = void 0;\n var tempFormat = !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat;\n if (this.getModuleName() === 'datetimepicker') {\n if (this.calendarMode === 'Gregorian') {\n dateString = this.globalize.formatDate(this.value, {\n format: tempFormat, type: 'dateTime', skeleton: 'yMd'\n });\n }\n else {\n dateString = this.globalize.formatDate(this.value, {\n format: tempFormat, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic'\n });\n }\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n dateString = this.globalize.formatDate(this.value, formatOptions);\n }\n if ((+dateValue <= +this.max) && (+dateValue >= +this.min)) {\n this.updateInputValue(dateString);\n }\n else {\n var value = (+dateValue >= +this.max || !+this.value) || (!+this.value || +dateValue <= +this.min);\n if (!this.strictMode && value) {\n this.updateInputValue(dateString);\n }\n }\n }\n if (isNullOrUndefined(this.value) && this.strictMode) {\n if (!this.enableMask) {\n this.updateInputValue('');\n }\n else {\n this.updateInputValue(this.maskedDateValue);\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n }\n if (!this.strictMode && isNullOrUndefined(this.value) && this.invalidValueString) {\n this.updateInputValue(this.invalidValueString);\n }\n this.changedArgs = { value: this.value };\n this.errorClass();\n this.updateIconState();\n };\n DatePicker.prototype.minMaxUpdates = function () {\n if (!isNullOrUndefined(this.value) && this.value < this.min && this.min <= this.max && this.strictMode) {\n this.setProperties({ value: this.min }, true);\n this.changedArgs = { value: this.value };\n }\n else {\n if (!isNullOrUndefined(this.value) && this.value > this.max && this.min <= this.max && this.strictMode) {\n this.setProperties({ value: this.max }, true);\n this.changedArgs = { value: this.value };\n }\n }\n };\n DatePicker.prototype.checkStringValue = function (val) {\n var returnDate = null;\n var formatOptions = null;\n var formatDateTime = null;\n if (this.getModuleName() === 'datetimepicker') {\n var culture = new Internationalization(this.locale);\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: this.dateTimeFormat, type: 'dateTime', skeleton: 'yMd' };\n formatDateTime = { format: culture.getDatePattern({ skeleton: 'yMd' }), type: 'dateTime' };\n }\n else {\n formatOptions = { format: this.dateTimeFormat, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n formatDateTime = { format: culture.getDatePattern({ skeleton: 'yMd' }), type: 'dateTime', calendar: 'islamic' };\n }\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n }\n returnDate = this.checkDateValue(this.globalize.parseDate(val, formatOptions));\n if (isNullOrUndefined(returnDate) && (this.getModuleName() === 'datetimepicker')) {\n returnDate = this.checkDateValue(this.globalize.parseDate(val, formatDateTime));\n }\n return returnDate;\n };\n DatePicker.prototype.checkInvalidValue = function (value) {\n if (!(value instanceof Date) && !isNullOrUndefined(value)) {\n var valueDate = null;\n var valueString = value;\n if (typeof value === 'number') {\n valueString = value.toString();\n }\n var formatOptions = null;\n var formatDateTime = null;\n if (this.getModuleName() === 'datetimepicker') {\n var culture = new Internationalization(this.locale);\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: this.dateTimeFormat, type: 'dateTime', skeleton: 'yMd' };\n formatDateTime = { format: culture.getDatePattern({ skeleton: 'yMd' }), type: 'dateTime' };\n }\n else {\n formatOptions = { format: this.dateTimeFormat, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n formatDateTime = { format: culture.getDatePattern({ skeleton: 'yMd' }), type: 'dateTime', calendar: 'islamic' };\n }\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n }\n var invalid = false;\n if (typeof valueString !== 'string') {\n valueString = null;\n invalid = true;\n }\n else {\n if (typeof valueString === 'string') {\n valueString = valueString.trim();\n }\n valueDate = this.checkStringValue(valueString);\n if (!valueDate) {\n var extISOString = null;\n var basicISOString = null;\n // eslint-disable-next-line\n extISOString = /^\\s*((?:[+-]\\d{6}|\\d{4})-(?:\\d\\d-\\d\\d|W\\d\\d-\\d|W\\d\\d|\\d\\d\\d|\\d\\d))(?:(T| )(\\d\\d(?::\\d\\d(?::\\d\\d(?:[.,]\\d+)?)?)?)([\\+\\-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?/;\n // eslint-disable-next-line\n basicISOString = /^\\s*((?:[+-]\\d{6}|\\d{4})(?:\\d\\d\\d\\d|W\\d\\d\\d|W\\d\\d|\\d\\d\\d|\\d\\d))(?:(T| )(\\d\\d(?:\\d\\d(?:\\d\\d(?:[.,]\\d+)?)?)?)([\\+\\-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?/;\n if ((!extISOString.test(valueString) && !basicISOString.test(valueString))\n || (/^[a-zA-Z0-9- ]*$/).test(valueString) || isNaN(+new Date(this.checkValue(valueString)))) {\n invalid = true;\n }\n else {\n valueDate = new Date(valueString);\n }\n }\n }\n if (invalid) {\n if (!this.strictMode) {\n this.invalidValueString = valueString;\n }\n this.setProperties({ value: null }, true);\n }\n else {\n this.setProperties({ value: valueDate }, true);\n }\n }\n };\n DatePicker.prototype.bindInputEvent = function () {\n if (!isNullOrUndefined(this.formatString) || this.enableMask) {\n if (this.enableMask || this.formatString.indexOf('y') === -1) {\n EventHandler.add(this.inputElement, 'input', this.inputHandler, this);\n }\n else {\n EventHandler.remove(this.inputElement, 'input', this.inputHandler);\n }\n }\n };\n DatePicker.prototype.bindEvents = function () {\n EventHandler.add(this.inputWrapper.buttons[0], 'mousedown', this.dateIconHandler, this);\n EventHandler.add(this.inputElement, 'mouseup', this.mouseUpHandler, this);\n EventHandler.add(this.inputElement, 'focus', this.inputFocusHandler, this);\n EventHandler.add(this.inputElement, 'blur', this.inputBlurHandler, this);\n EventHandler.add(this.inputElement, 'keyup', this.keyupHandler, this);\n if (this.enableMask) {\n EventHandler.add(this.inputElement, 'keydown', this.keydownHandler, this);\n }\n this.bindInputEvent();\n // To prevent the twice triggering.\n EventHandler.add(this.inputElement, 'change', this.inputChangeHandler, this);\n if (this.showClearButton && this.inputWrapper.clearButton) {\n EventHandler.add(this.inputWrapper.clearButton, 'mousedown touchstart', this.resetHandler, this);\n }\n if (this.formElement) {\n EventHandler.add(this.formElement, 'reset', this.resetFormHandler, this);\n }\n this.defaultKeyConfigs = extend(this.defaultKeyConfigs, this.keyConfigs);\n this.keyboardModules = new KeyboardEvents(this.inputElement, {\n eventName: 'keydown',\n keyAction: this.inputKeyActionHandle.bind(this),\n keyConfigs: this.defaultKeyConfigs\n });\n };\n DatePicker.prototype.keydownHandler = function (e) {\n switch (e.code) {\n case 'ArrowLeft':\n case 'ArrowRight':\n case 'ArrowUp':\n case 'ArrowDown':\n case 'Home':\n case 'End':\n case 'Delete':\n if (this.enableMask && !this.popupObj && !this.readonly) {\n if (e.code !== 'Delete') {\n e.preventDefault();\n }\n this.notify('keyDownHandler', {\n module: 'MaskedDateTime',\n e: e\n });\n }\n break;\n default:\n break;\n }\n };\n DatePicker.prototype.unBindEvents = function () {\n if (!isNullOrUndefined(this.inputWrapper)) {\n EventHandler.remove(this.inputWrapper.buttons[0], 'mousedown', this.dateIconHandler);\n }\n EventHandler.remove(this.inputElement, 'mouseup', this.mouseUpHandler);\n EventHandler.remove(this.inputElement, 'focus', this.inputFocusHandler);\n EventHandler.remove(this.inputElement, 'blur', this.inputBlurHandler);\n EventHandler.remove(this.inputElement, 'change', this.inputChangeHandler);\n EventHandler.remove(this.inputElement, 'keyup', this.keyupHandler);\n if (this.enableMask) {\n EventHandler.remove(this.inputElement, 'keydown', this.keydownHandler);\n }\n if (this.showClearButton && this.inputWrapper.clearButton) {\n EventHandler.remove(this.inputWrapper.clearButton, 'mousedown touchstart', this.resetHandler);\n }\n if (this.formElement) {\n EventHandler.remove(this.formElement, 'reset', this.resetFormHandler);\n }\n };\n DatePicker.prototype.resetFormHandler = function () {\n if (!this.enabled) {\n return;\n }\n if (!this.inputElement.disabled) {\n var value = this.inputElement.getAttribute('value');\n if (this.element.tagName === 'EJS-DATEPICKER' || this.element.tagName === 'EJS-DATETIMEPICKER') {\n value = '';\n this.inputValueCopy = null;\n this.inputElement.setAttribute('value', '');\n }\n this.setProperties({ value: this.inputValueCopy }, true);\n this.restoreValue();\n if (this.inputElement) {\n this.updateInputValue(value);\n this.errorClass();\n }\n }\n };\n DatePicker.prototype.restoreValue = function () {\n this.currentDate = this.value ? this.value : new Date();\n this.previousDate = this.value;\n this.previousElementValue = (isNullOrUndefined(this.inputValueCopy)) ? '' :\n this.globalize.formatDate(this.inputValueCopy, {\n format: this.formatString, type: 'dateTime', skeleton: 'yMd'\n });\n };\n DatePicker.prototype.inputChangeHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n e.stopPropagation();\n };\n DatePicker.prototype.bindClearEvent = function () {\n if (this.showClearButton && this.inputWrapper.clearButton) {\n EventHandler.add(this.inputWrapper.clearButton, 'mousedown touchstart', this.resetHandler, this);\n }\n };\n DatePicker.prototype.resetHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n e.preventDefault();\n this.clear(e);\n };\n DatePicker.prototype.mouseUpHandler = function (e) {\n if (this.enableMask) {\n e.preventDefault();\n this.notify('setMaskSelection', {\n module: 'MaskedDateTime'\n });\n }\n };\n DatePicker.prototype.clear = function (event) {\n this.setProperties({ value: null }, true);\n if (!this.enableMask) {\n this.updateInputValue('');\n }\n var clearedArgs = {\n event: event\n };\n this.trigger('cleared', clearedArgs);\n this.invalidValueString = '';\n this.updateInput();\n this.popupUpdate();\n this.changeEvent(event);\n if (this.enableMask) {\n this.notify('clearHandler', {\n module: 'MaskedDateTime'\n });\n }\n if (closest(this.element, 'form')) {\n var element = this.element;\n var keyupEvent = document.createEvent('KeyboardEvent');\n keyupEvent.initEvent('keyup', false, true);\n element.dispatchEvent(keyupEvent);\n }\n };\n DatePicker.prototype.preventEventBubbling = function (e) {\n e.preventDefault();\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.interopAdaptor.invokeMethodAsync('OnDateIconClick');\n };\n DatePicker.prototype.updateInputValue = function (value) {\n Input.setValue(value, this.inputElement, this.floatLabelType, this.showClearButton);\n };\n DatePicker.prototype.dateIconHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n this.isIconClicked = true;\n if (Browser.isDevice) {\n this.inputElement.setAttribute('readonly', '');\n this.inputElement.blur();\n }\n e.preventDefault();\n if (!this.readonly) {\n if (this.isCalendar()) {\n this.hide(e);\n }\n else {\n this.isDateIconClicked = true;\n this.show(null, e);\n if (this.getModuleName() === 'datetimepicker') {\n this.inputElement.focus();\n }\n this.inputElement.focus();\n addClass([this.inputWrapper.container], [INPUTFOCUS]);\n addClass(this.inputWrapper.buttons, ACTIVE);\n }\n }\n this.isIconClicked = false;\n };\n DatePicker.prototype.updateHtmlAttributeToWrapper = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n if (!isNullOrUndefined(this.htmlAttributes[\"\" + key])) {\n if (containerAttr.indexOf(key) > -1) {\n if (key === 'class') {\n var updatedClassValues = (this.htmlAttributes[\"\" + key].replace(/\\s+/g, ' ')).trim();\n if (updatedClassValues !== '') {\n addClass([this.inputWrapper.container], updatedClassValues.split(' '));\n }\n }\n else if (key === 'style') {\n var setStyle = this.inputWrapper.container.getAttribute(key);\n if (!isNullOrUndefined(setStyle)) {\n if (setStyle.charAt(setStyle.length - 1) === ';') {\n setStyle = setStyle + this.htmlAttributes[\"\" + key];\n }\n else {\n setStyle = setStyle + ';' + this.htmlAttributes[\"\" + key];\n }\n }\n else {\n setStyle = this.htmlAttributes[\"\" + key];\n }\n this.inputWrapper.container.setAttribute(key, setStyle);\n }\n else {\n this.inputWrapper.container.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n }\n }\n };\n DatePicker.prototype.updateHtmlAttributeToElement = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n if (containerAttr.indexOf(key) < 0) {\n this.inputElement.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n };\n DatePicker.prototype.updateCssClass = function (newCssClass, oldCssClass) {\n if (!isNullOrUndefined(oldCssClass)) {\n oldCssClass = (oldCssClass.replace(/\\s+/g, ' ')).trim();\n }\n if (!isNullOrUndefined(newCssClass)) {\n newCssClass = (newCssClass.replace(/\\s+/g, ' ')).trim();\n }\n Input.setCssClass(newCssClass, [this.inputWrapper.container], oldCssClass);\n if (this.popupWrapper) {\n Input.setCssClass(newCssClass, [this.popupWrapper], oldCssClass);\n }\n };\n DatePicker.prototype.calendarKeyActionHandle = function (e) {\n switch (e.action) {\n case 'escape':\n if (this.isCalendar()) {\n this.hide(e);\n }\n else {\n this.inputWrapper.container.children[this.index].blur();\n }\n break;\n case 'enter':\n if (!this.isCalendar()) {\n this.show(null, e);\n }\n else {\n if (+this.value !== +this.currentDate && !this.isCalendar()) {\n this.inputWrapper.container.children[this.index].focus();\n }\n }\n if (this.getModuleName() === 'datetimepicker') {\n this.inputElement.focus();\n }\n break;\n }\n };\n DatePicker.prototype.inputFocusHandler = function () {\n this.isFocused = true;\n if (!this.enabled) {\n return;\n }\n if (this.enableMask && !this.inputElement.value && this.placeholder) {\n if (this.maskedDateValue && !this.value && (this.floatLabelType === 'Auto' || this.floatLabelType === 'Never' || this.placeholder)) {\n this.updateInputValue(this.maskedDateValue);\n this.inputElement.selectionStart = 0;\n this.inputElement.selectionEnd = this.inputElement.value.length;\n }\n }\n var focusArguments = {\n model: this\n };\n this.isDateIconClicked = false;\n this.trigger('focus', focusArguments);\n this.updateIconState();\n if (this.openOnFocus && !this.isIconClicked) {\n this.show();\n }\n };\n DatePicker.prototype.inputHandler = function () {\n this.isPopupClicked = false;\n if (this.enableMask) {\n this.notify('inputHandler', {\n module: 'MaskedDateTime'\n });\n }\n };\n DatePicker.prototype.inputBlurHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n this.strictModeUpdate();\n if (this.inputElement.value === '' && isNullOrUndefined(this.value)) {\n this.invalidValueString = null;\n this.updateInputValue('');\n }\n this.isBlur = true;\n this.updateInput(false, true);\n this.isBlur = false;\n this.popupUpdate();\n this.changeTrigger(e);\n if (this.enableMask && this.maskedDateValue && this.placeholder && this.floatLabelType !== 'Always') {\n if (this.inputElement.value === this.maskedDateValue && !this.value && (this.floatLabelType === 'Auto' || this.floatLabelType === 'Never' || this.placeholder)) {\n this.updateInputValue('');\n }\n }\n this.errorClass();\n if (this.isCalendar() && document.activeElement === this.inputElement) {\n this.hide(e);\n }\n if (this.getModuleName() === 'datepicker') {\n var blurArguments = {\n model: this\n };\n this.trigger('blur', blurArguments);\n }\n if (this.isCalendar()) {\n this.defaultKeyConfigs = extend(this.defaultKeyConfigs, this.keyConfigs);\n this.calendarKeyboardModules = new KeyboardEvents(this.calendarElement.children[1].firstElementChild, {\n eventName: 'keydown',\n keyAction: this.calendarKeyActionHandle.bind(this),\n keyConfigs: this.defaultKeyConfigs\n });\n }\n this.isPopupClicked = false;\n };\n DatePicker.prototype.documentHandler = function (e) {\n if ((!isNullOrUndefined(this.popupObj) && !isNullOrUndefined(this.inputWrapper) && (this.inputWrapper.container.contains(e.target) && e.type !== 'mousedown' ||\n (this.popupObj.element && this.popupObj.element.contains(e.target)))) && e.type !== 'touchstart') {\n e.preventDefault();\n }\n var target = e.target;\n if (!(closest(target, '.e-datepicker.e-popup-wrapper')) && !isNullOrUndefined(this.inputWrapper)\n && !(closest(target, '.' + INPUTCONTAINER) === this.inputWrapper.container)\n && (!target.classList.contains('e-day'))\n && (!target.classList.contains('e-dlg-overlay'))) {\n this.hide(e);\n this.focusOut();\n }\n else if (closest(target, '.e-datepicker.e-popup-wrapper')) {\n // Fix for close the popup when select the previously selected value.\n if (target.classList.contains('e-day')\n && !isNullOrUndefined(e.target.parentElement)\n && e.target.parentElement.classList.contains('e-selected')\n && closest(target, '.e-content')\n && closest(target, '.e-content').classList.contains('e-' + this.depth.toLowerCase())) {\n this.hide(e);\n }\n else if (closest(target, '.e-footer-container')\n && target.classList.contains('e-today')\n && target.classList.contains('e-btn')\n && (+new Date(+this.value) === +_super.prototype.generateTodayVal.call(this, this.value))) {\n this.hide(e);\n }\n }\n };\n DatePicker.prototype.inputKeyActionHandle = function (e) {\n var clickedView = this.currentView();\n switch (e.action) {\n case 'altUpArrow':\n this.isAltKeyPressed = false;\n this.hide(e);\n this.inputElement.focus();\n break;\n case 'altDownArrow':\n this.isAltKeyPressed = true;\n this.strictModeUpdate();\n this.updateInput();\n this.changeTrigger(e);\n if (this.getModuleName() === 'datepicker') {\n this.show(null, e);\n }\n break;\n case 'escape':\n this.hide(e);\n break;\n case 'enter':\n this.strictModeUpdate();\n this.updateInput();\n this.popupUpdate();\n this.changeTrigger(e);\n this.errorClass();\n if (!this.isCalendar() && document.activeElement === this.inputElement) {\n this.hide(e);\n }\n if (this.isCalendar()) {\n e.preventDefault();\n e.stopPropagation();\n }\n break;\n case 'tab':\n case 'shiftTab':\n {\n var start = this.inputElement.selectionStart;\n var end = this.inputElement.selectionEnd;\n if (this.enableMask && !this.popupObj && !this.readonly) {\n var length_1 = this.inputElement.value.length;\n if ((start === 0 && end === length_1) || (end !== length_1 && e.action === 'tab') || (start !== 0 && e.action === 'shiftTab')) {\n e.preventDefault();\n }\n this.notify('keyDownHandler', {\n module: 'MaskedDateTime',\n e: e\n });\n start = this.inputElement.selectionStart;\n end = this.inputElement.selectionEnd;\n }\n this.strictModeUpdate();\n this.updateInput();\n this.popupUpdate();\n this.changeTrigger(e);\n this.errorClass();\n if (this.enableMask) {\n this.inputElement.selectionStart = start;\n this.inputElement.selectionEnd = end;\n }\n if (e.action === 'tab' && e.target === this.inputElement && this.isCalendar() && document.activeElement === this.inputElement) {\n e.preventDefault();\n this.headerTitleElement.focus();\n }\n if (e.action === 'shiftTab' && e.target === this.inputElement && this.isCalendar() && document.activeElement === this.inputElement) {\n this.hide(e);\n }\n break;\n }\n default:\n this.defaultAction(e);\n // Fix for close the popup when select the previously selected value.\n if (e.action === 'select' && clickedView === this.depth) {\n this.hide(e);\n }\n }\n };\n DatePicker.prototype.defaultAction = function (e) {\n this.previousDate = ((!isNullOrUndefined(this.value) && new Date(+this.value)) || null);\n if (this.isCalendar()) {\n _super.prototype.keyActionHandle.call(this, e);\n if (this.isCalendar()) {\n attributes(this.inputElement, {\n 'aria-activedescendant': '' + this.setActiveDescendant()\n });\n }\n }\n };\n DatePicker.prototype.popupUpdate = function () {\n if ((isNullOrUndefined(this.value)) && (!isNullOrUndefined(this.previousDate)) ||\n (((this.getModuleName() !== 'datetimepicker') && (+this.value !== +this.previousDate)) || ((this.getModuleName() === 'datetimepicker') && (+this.value !== +this.previousDateTime)))) {\n if (this.popupObj) {\n if (this.popupObj.element.querySelectorAll('.' + SELECTED).length > 0) {\n removeClass(this.popupObj.element.querySelectorAll('.' + SELECTED), [SELECTED]);\n }\n }\n if (!isNullOrUndefined(this.value)) {\n if ((+this.value >= +this.min) && (+this.value <= +this.max)) {\n var targetdate = new Date(this.checkValue(this.value));\n _super.prototype.navigateTo.call(this, 'Month', targetdate);\n }\n }\n }\n };\n DatePicker.prototype.strictModeUpdate = function () {\n var format;\n var pattern = /^y/;\n var charPattern = /[^a-zA-Z]/;\n var formatOptions;\n if (this.getModuleName() === 'datetimepicker') {\n format = !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat;\n }\n else if (!pattern.test(this.formatString) || charPattern.test(this.formatString)) {\n format = isNullOrUndefined(this.formatString) ? this.formatString : this.formatString.replace('dd', 'd');\n }\n if (!isNullOrUndefined(format)) {\n var len = format.split('M').length - 1;\n if (len < 3) {\n format = format.replace('MM', 'M');\n }\n }\n else {\n format = this.formatString;\n }\n var dateOptions;\n if (this.getModuleName() === 'datetimepicker') {\n if (this.calendarMode === 'Gregorian') {\n dateOptions = {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat,\n type: 'dateTime', skeleton: 'yMd'\n };\n }\n else {\n dateOptions = {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat,\n type: 'dateTime', skeleton: 'yMd', calendar: 'islamic'\n };\n }\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: format, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n formatOptions = { format: format, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n dateOptions = formatOptions;\n }\n var date;\n if (typeof this.inputElement.value === 'string') {\n this.inputElement.value = this.inputElement.value.trim();\n }\n if ((this.getModuleName() === 'datetimepicker')) {\n if (this.checkDateValue(this.globalize.parseDate(this.inputElement.value, dateOptions))) {\n var modifiedValue = this.inputElement.value.replace(/(am|pm|Am|aM|pM|Pm)/g, function (match) { return match.toLocaleUpperCase(); });\n date = this.globalize.parseDate(modifiedValue, dateOptions);\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: format, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n formatOptions = { format: format, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n date = this.globalize.parseDate(this.inputElement.value, formatOptions);\n }\n }\n else {\n date = this.globalize.parseDate(this.inputElement.value, dateOptions);\n date = (!isNullOrUndefined(date) && isNaN(+date)) ? null : date;\n if (!isNullOrUndefined(this.formatString) && this.inputElement.value !== '' && this.strictMode) {\n if ((this.isPopupClicked || (!this.isPopupClicked && this.inputElement.value === this.previousElementValue))\n && this.formatString.indexOf('y') === -1) {\n date.setFullYear(this.value.getFullYear());\n }\n }\n }\n // EJ2-35061 - To prevent change event from triggering twice when using strictmode and format property\n if ((this.getModuleName() === 'datepicker') && (this.value && !isNaN(+this.value)) && date) {\n date.setHours(this.value.getHours(), this.value.getMinutes(), this.value.getSeconds(), this.value.getMilliseconds());\n }\n if (this.strictMode && date) {\n this.updateInputValue(this.globalize.formatDate(date, dateOptions));\n if (this.inputElement.value !== this.previousElementValue) {\n this.setProperties({ value: date }, true);\n }\n }\n else if (!this.strictMode) {\n if (this.inputElement.value !== this.previousElementValue) {\n this.setProperties({ value: date }, true);\n }\n }\n if (this.strictMode && !date && this.inputElement.value === (this.enableMask ? this.maskedDateValue : '')) {\n this.setProperties({ value: null }, true);\n }\n if (isNaN(+this.value)) {\n this.setProperties({ value: null }, true);\n }\n if (isNullOrUndefined(this.value)) {\n this.currentDate = new Date(new Date().setHours(0, 0, 0, 0));\n }\n };\n DatePicker.prototype.createCalendar = function () {\n var _this = this;\n this.popupWrapper = this.createElement('div', { className: '' + ROOT + ' ' + POPUPWRAPPER, id: this.inputElement.id + '_options' });\n this.popupWrapper.setAttribute('aria-label', this.element.id);\n this.popupWrapper.setAttribute('role', 'dialog');\n if (!isNullOrUndefined(this.cssClass)) {\n this.popupWrapper.className += ' ' + this.cssClass;\n }\n if (Browser.isDevice) {\n this.modelHeader();\n this.modal = this.createElement('div');\n this.modal.className = '' + ROOT + ' e-date-modal';\n document.body.className += ' ' + OVERFLOW;\n this.modal.style.display = 'block';\n document.body.appendChild(this.modal);\n }\n //this.calendarElement represent the Calendar object from the Calendar class.\n this.calendarElement.querySelector('table tbody').className = '';\n this.popupObj = new Popup(this.popupWrapper, {\n content: this.calendarElement,\n relateTo: Browser.isDevice ? document.body : this.inputWrapper.container,\n position: Browser.isDevice ? { X: 'center', Y: 'center' } : (this.enableRtl ? { X: 'right', Y: 'bottom' } : { X: 'left', Y: 'bottom' }),\n offsetY: OFFSETVALUE,\n targetType: 'container',\n enableRtl: this.enableRtl,\n zIndex: this.zIndex,\n collision: Browser.isDevice ? { X: 'fit', Y: 'fit' } : (this.enableRtl ? { X: 'fit', Y: 'flip' } : { X: 'flip', Y: 'flip' }),\n open: function () {\n if (Browser.isDevice && _this.fullScreenMode) {\n _this.iconRight = parseInt(window.getComputedStyle(_this.calendarElement.querySelector('.e-header.e-month .e-prev')).marginRight, 10) > 16 ? true : false;\n _this.touchModule = new Touch(_this.calendarElement.querySelector(\".e-content.e-month\"), {\n swipe: _this.CalendarSwipeHandler.bind(_this)\n });\n EventHandler.add(_this.calendarElement.querySelector(\".e-content.e-month\"), \"touchstart\", _this.TouchStartHandler, _this);\n }\n if (_this.getModuleName() !== 'datetimepicker') {\n if (document.activeElement !== _this.inputElement) {\n _this.defaultKeyConfigs = extend(_this.defaultKeyConfigs, _this.keyConfigs);\n _this.calendarElement.children[1].firstElementChild.focus();\n _this.calendarKeyboardModules = new KeyboardEvents(_this.calendarElement.children[1].firstElementChild, {\n eventName: 'keydown',\n keyAction: _this.calendarKeyActionHandle.bind(_this),\n keyConfigs: _this.defaultKeyConfigs\n });\n _this.calendarKeyboardModules = new KeyboardEvents(_this.inputWrapper.container.children[_this.index], {\n eventName: 'keydown',\n keyAction: _this.calendarKeyActionHandle.bind(_this),\n keyConfigs: _this.defaultKeyConfigs\n });\n }\n }\n }, close: function () {\n if (_this.isDateIconClicked) {\n _this.inputWrapper.container.children[_this.index].focus();\n }\n if (_this.value) {\n _this.disabledDates();\n }\n if (_this.popupObj) {\n _this.popupObj.destroy();\n }\n _this.resetCalendar();\n detach(_this.popupWrapper);\n _this.popupObj = _this.popupWrapper = null;\n _this.preventArgs = null;\n _this.calendarKeyboardModules = null;\n _this.setAriaAttributes();\n }, targetExitViewport: function () {\n if (!Browser.isDevice) {\n _this.hide();\n }\n }\n });\n this.popupObj.element.className += ' ' + this.cssClass;\n this.setAriaAttributes();\n };\n DatePicker.prototype.CalendarSwipeHandler = function (e) {\n var direction = 0;\n if (this.iconRight) {\n switch (e.swipeDirection) {\n case \"Left\":\n direction = 1;\n break;\n case \"Right\":\n direction = -1;\n break;\n default:\n break;\n }\n }\n else {\n switch (e.swipeDirection) {\n case \"Up\":\n direction = 1;\n break;\n case \"Down\":\n direction = -1;\n break;\n default:\n break;\n }\n }\n if (this.touchStart) {\n if (direction === 1) {\n this.navigateNext(e);\n }\n else if (direction === -1) {\n this.navigatePrevious(e);\n }\n this.touchStart = false;\n }\n };\n DatePicker.prototype.TouchStartHandler = function (e) {\n this.touchStart = true;\n };\n DatePicker.prototype.setAriaDisabled = function () {\n if (!this.enabled) {\n this.inputElement.setAttribute('aria-disabled', 'true');\n this.inputElement.tabIndex = -1;\n }\n else {\n this.inputElement.setAttribute('aria-disabled', 'false');\n this.inputElement.setAttribute('tabindex', this.tabIndex);\n }\n };\n DatePicker.prototype.modelHeader = function () {\n var dateOptions;\n var modelHeader = this.createElement('div', { className: 'e-model-header' });\n var yearHeading = this.createElement('h1', { className: 'e-model-year' });\n var h2 = this.createElement('div');\n var daySpan = this.createElement('span', { className: 'e-model-day' });\n var monthSpan = this.createElement('span', { className: 'e-model-month' });\n if (this.calendarMode === 'Gregorian') {\n dateOptions = { format: 'y', skeleton: 'dateTime' };\n }\n else {\n dateOptions = { format: 'y', skeleton: 'dateTime', calendar: 'islamic' };\n }\n yearHeading.textContent = '' + this.globalize.formatDate(this.value || new Date(), dateOptions);\n if (this.calendarMode === 'Gregorian') {\n dateOptions = { format: 'E', skeleton: 'dateTime' };\n }\n else {\n dateOptions = { format: 'E', skeleton: 'dateTime', calendar: 'islamic' };\n }\n daySpan.textContent = '' + this.globalize.formatDate(this.value || new Date(), dateOptions) + ', ';\n if (this.calendarMode === 'Gregorian') {\n dateOptions = { format: 'MMM d', skeleton: 'dateTime' };\n }\n else {\n dateOptions = { format: 'MMM d', skeleton: 'dateTime', calendar: 'islamic' };\n }\n monthSpan.textContent = '' + this.globalize.formatDate(this.value || new Date(), dateOptions);\n if (this.fullScreenMode) {\n var modelCloseIcon = this.createElement(\"span\", { className: \"e-popup-close\" });\n EventHandler.add(modelCloseIcon, 'mousedown touchstart', this.modelCloseHandler, this);\n var modelTodayButton = this.calendarElement.querySelector(\"button.e-today\");\n h2.classList.add(\"e-day-wrapper\");\n modelTodayButton.classList.add(\"e-outline\");\n modelHeader.appendChild(modelCloseIcon);\n modelHeader.appendChild(modelTodayButton);\n }\n if (!this.fullScreenMode)\n modelHeader.appendChild(yearHeading);\n h2.appendChild(daySpan);\n h2.appendChild(monthSpan);\n modelHeader.appendChild(h2);\n this.calendarElement.insertBefore(modelHeader, this.calendarElement.firstElementChild);\n };\n DatePicker.prototype.modelCloseHandler = function (e) {\n this.hide();\n };\n DatePicker.prototype.changeTrigger = function (event) {\n if (this.inputElement.value !== this.previousElementValue) {\n if (((this.previousDate && this.previousDate.valueOf()) !== (this.value && this.value.valueOf()))) {\n if (this.isDynamicValueChanged && this.isCalendar()) {\n this.popupUpdate();\n }\n this.changedArgs.value = this.value;\n this.changedArgs.event = event || null;\n this.changedArgs.element = this.element;\n this.changedArgs.isInteracted = !isNullOrUndefined(event);\n if (this.isAngular && this.preventChange) {\n this.preventChange = false;\n }\n else {\n this.trigger('change', this.changedArgs);\n }\n this.previousElementValue = this.inputElement.value;\n this.previousDate = !isNaN(+new Date(this.checkValue(this.value))) ? new Date(this.checkValue(this.value)) : null;\n this.isInteracted = true;\n }\n }\n this.isKeyAction = false;\n };\n DatePicker.prototype.navigatedEvent = function () {\n this.trigger('navigated', this.navigatedArgs);\n };\n DatePicker.prototype.keyupHandler = function (e) {\n this.isKeyAction = (this.inputElement.value !== this.previousElementValue) ? true : false;\n };\n DatePicker.prototype.changeEvent = function (event) {\n if (!this.isIconClicked && !(this.isBlur || this.isKeyAction)) {\n this.selectCalendar(event);\n }\n if (((this.previousDate && this.previousDate.valueOf()) !== (this.value && this.value.valueOf()))) {\n this.changedArgs.event = event ? event : null;\n this.changedArgs.element = this.element;\n this.changedArgs.isInteracted = this.isInteracted;\n if (!this.isDynamicValueChanged) {\n this.trigger('change', this.changedArgs);\n }\n this.previousDate = this.value && new Date(+this.value);\n if (!this.isDynamicValueChanged) {\n this.hide(event);\n }\n this.previousElementValue = this.inputElement.value;\n this.errorClass();\n }\n else if (event) {\n this.hide(event);\n }\n this.isKeyAction = false;\n };\n DatePicker.prototype.requiredModules = function () {\n var modules = [];\n if (this) {\n modules.push({ args: [this], member: 'islamic' });\n }\n if (this.enableMask) {\n modules.push({ args: [this], member: 'MaskedDateTime' });\n }\n return modules;\n };\n DatePicker.prototype.selectCalendar = function (e) {\n var date;\n var tempFormat;\n var formatOptions;\n if (this.getModuleName() === 'datetimepicker') {\n tempFormat = !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat;\n }\n else {\n tempFormat = this.formatString;\n }\n if (this.value) {\n if (this.getModuleName() === 'datetimepicker') {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: tempFormat, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n formatOptions = { format: tempFormat, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n date = this.globalize.formatDate(this.changedArgs.value, formatOptions);\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n date = this.globalize.formatDate(this.changedArgs.value, formatOptions);\n }\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n }\n if (!isNullOrUndefined(date)) {\n this.updateInputValue(date);\n if (this.enableMask) {\n this.notify('setMaskSelection', {\n module: 'MaskedDateTime'\n });\n }\n }\n };\n DatePicker.prototype.isCalendar = function () {\n if (this.popupWrapper && this.popupWrapper.classList.contains('' + POPUPWRAPPER)) {\n return true;\n }\n return false;\n };\n DatePicker.prototype.setWidth = function (width) {\n if (typeof width === 'number') {\n this.inputWrapper.container.style.width = formatUnit(this.width);\n }\n else if (typeof width === 'string') {\n this.inputWrapper.container.style.width = (width.match(/px|%|em/)) ? (this.width) : (formatUnit(this.width));\n }\n else {\n this.inputWrapper.container.style.width = '100%';\n }\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-param */\n /**\n * Shows the Calendar.\n *\n * @returns {void}\n\n */\n DatePicker.prototype.show = function (type, e) {\n var _this = this;\n if ((this.enabled && this.readonly) || !this.enabled || this.popupObj) {\n return;\n }\n else {\n var prevent_1 = true;\n var outOfRange = void 0;\n if (!isNullOrUndefined(this.value) && !(+this.value >= +new Date(this.checkValue(this.min))\n && +this.value <= +new Date(this.checkValue(this.max)))) {\n outOfRange = new Date(this.checkValue(this.value));\n this.setProperties({ 'value': null }, true);\n }\n else {\n outOfRange = this.value || null;\n }\n if (!this.isCalendar()) {\n _super.prototype.render.call(this);\n this.setProperties({ 'value': outOfRange || null }, true);\n this.previousDate = outOfRange;\n this.createCalendar();\n }\n if (Browser.isDevice) {\n this.mobilePopupWrapper = this.createElement('div', { className: 'e-datepick-mob-popup-wrap' });\n document.body.appendChild(this.mobilePopupWrapper);\n }\n this.preventArgs = {\n preventDefault: function () {\n prevent_1 = false;\n },\n popup: this.popupObj,\n event: e || null,\n cancel: false,\n appendTo: Browser.isDevice ? this.mobilePopupWrapper : document.body\n };\n var eventArgs = this.preventArgs;\n this.trigger('open', eventArgs, function (eventArgs) {\n _this.preventArgs = eventArgs;\n if (prevent_1 && !_this.preventArgs.cancel) {\n addClass(_this.inputWrapper.buttons, ACTIVE);\n _this.preventArgs.appendTo.appendChild(_this.popupWrapper);\n _this.popupObj.refreshPosition(_this.inputElement);\n var openAnimation = {\n name: 'FadeIn',\n duration: Browser.isDevice ? 0 : OPENDURATION\n };\n if (_this.zIndex === 1000) {\n _this.popupObj.show(new Animation(openAnimation), _this.element);\n }\n else {\n _this.popupObj.show(new Animation(openAnimation), null);\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n _super.prototype.setOverlayIndex.call(_this, _this.mobilePopupWrapper, _this.popupObj.element, _this.modal, Browser.isDevice);\n _this.setAriaAttributes();\n }\n else {\n _this.popupObj.destroy();\n _this.popupWrapper = _this.popupObj = null;\n }\n if (!isNullOrUndefined(_this.inputElement) && _this.inputElement.value === '') {\n if (!isNullOrUndefined(_this.tableBodyElement) && _this.tableBodyElement.querySelectorAll('td.e-selected').length > 0) {\n addClass([_this.tableBodyElement.querySelector('td.e-selected')], FOCUSEDDATE);\n removeClass(_this.tableBodyElement.querySelectorAll('td.e-selected'), SELECTED);\n }\n }\n EventHandler.add(document, 'mousedown touchstart', _this.documentHandler, _this);\n });\n if (Browser.isDevice) {\n var dlgOverlay = this.createElement('div', { className: 'e-dlg-overlay' });\n dlgOverlay.style.zIndex = (this.zIndex - 1).toString();\n this.mobilePopupWrapper.appendChild(dlgOverlay);\n }\n }\n };\n /**\n * Hide the Calendar.\n *\n * @returns {void}\n\n */\n DatePicker.prototype.hide = function (event) {\n var _this = this;\n if (!isNullOrUndefined(this.popupWrapper)) {\n var prevent_2 = true;\n this.preventArgs = {\n preventDefault: function () {\n prevent_2 = false;\n },\n popup: this.popupObj,\n event: event || null,\n cancel: false\n };\n removeClass(this.inputWrapper.buttons, ACTIVE);\n removeClass([document.body], OVERFLOW);\n var eventArgs = this.preventArgs;\n if (this.isCalendar()) {\n this.trigger('close', eventArgs, function (eventArgs) {\n _this.closeEventCallback(prevent_2, eventArgs);\n });\n }\n else {\n this.closeEventCallback(prevent_2, eventArgs);\n }\n }\n else {\n if (Browser.isDevice && this.allowEdit && !this.readonly) {\n this.inputElement.removeAttribute('readonly');\n }\n this.setAllowEdit();\n }\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-param */\n DatePicker.prototype.closeEventCallback = function (prevent, eventArgs) {\n this.preventArgs = eventArgs;\n if (this.isCalendar() && (prevent && !this.preventArgs.cancel)) {\n this.popupObj.hide();\n this.isAltKeyPressed = false;\n this.keyboardModule.destroy();\n removeClass(this.inputWrapper.buttons, ACTIVE);\n }\n this.setAriaAttributes();\n if (Browser.isDevice && this.modal) {\n this.modal.style.display = 'none';\n this.modal.outerHTML = '';\n this.modal = null;\n }\n if (Browser.isDevice) {\n if (!isNullOrUndefined(this.mobilePopupWrapper) && (prevent && (isNullOrUndefined(this.preventArgs) || !this.preventArgs.cancel))) {\n this.mobilePopupWrapper.remove();\n this.mobilePopupWrapper = null;\n }\n }\n EventHandler.remove(document, 'mousedown touchstart', this.documentHandler);\n if (Browser.isDevice && this.allowEdit && !this.readonly) {\n this.inputElement.removeAttribute('readonly');\n }\n this.setAllowEdit();\n };\n /* eslint-disable jsdoc/require-param */\n /**\n * Sets the focus to widget for interaction.\n *\n * @returns {void}\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n DatePicker.prototype.focusIn = function (triggerEvent) {\n if (document.activeElement !== this.inputElement && this.enabled) {\n this.inputElement.focus();\n addClass([this.inputWrapper.container], [INPUTFOCUS]);\n }\n };\n /* eslint-enable jsdoc/require-param */\n /**\n * Remove the focus from widget, if the widget is in focus state.\n *\n * @returns {void}\n */\n DatePicker.prototype.focusOut = function () {\n if (document.activeElement === this.inputElement) {\n removeClass([this.inputWrapper.container], [INPUTFOCUS]);\n this.inputElement.blur();\n }\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets the current view of the DatePicker.\n *\n * @returns {string}\n\n */\n DatePicker.prototype.currentView = function () {\n var currentView;\n if (this.calendarElement) {\n // calls the Calendar currentView public method\n currentView = _super.prototype.currentView.call(this);\n }\n return currentView;\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Navigates to specified month or year or decade view of the DatePicker.\n *\n * @param {string} view - Specifies the view of the calendar.\n * @param {Date} date - Specifies the focused date in a view.\n * @returns {void}\n\n */\n DatePicker.prototype.navigateTo = function (view, date) {\n if (this.calendarElement) {\n // calls the Calendar navigateTo public method\n _super.prototype.navigateTo.call(this, view, date);\n }\n };\n /**\n * To destroy the widget.\n *\n * @returns {void}\n */\n DatePicker.prototype.destroy = function () {\n this.unBindEvents();\n _super.prototype.destroy.call(this);\n if (!isNullOrUndefined(this.keyboardModules)) {\n this.keyboardModules.destroy();\n }\n if (this.popupObj && this.popupObj.element.classList.contains(POPUP)) {\n _super.prototype.destroy.call(this);\n }\n var ariaAttrs = {\n 'aria-atomic': 'true', 'aria-disabled': 'true',\n 'aria-expanded': 'false', 'role': 'combobox', 'autocomplete': 'off',\n 'autocorrect': 'off', 'autocapitalize': 'off', 'spellcheck': 'false', 'aria-label': this.getModuleName()\n };\n if (this.inputElement) {\n Input.removeAttributes(ariaAttrs, this.inputElement);\n if (!isNullOrUndefined(this.inputElementCopy.getAttribute('tabindex'))) {\n this.inputElement.setAttribute('tabindex', this.tabIndex);\n }\n else {\n this.inputElement.removeAttribute('tabindex');\n }\n EventHandler.remove(this.inputElement, 'blur', this.inputBlurHandler);\n EventHandler.remove(this.inputElement, 'focus', this.inputFocusHandler);\n this.ensureInputAttribute();\n }\n if (this.isCalendar()) {\n if (this.popupWrapper) {\n detach(this.popupWrapper);\n }\n this.popupObj = this.popupWrapper = null;\n this.keyboardModule.destroy();\n }\n if (this.ngTag === null) {\n if (this.inputElement) {\n if (!isNullOrUndefined(this.inputWrapper)) {\n this.inputWrapper.container.insertAdjacentElement('afterend', this.inputElement);\n }\n removeClass([this.inputElement], [INPUTROOT]);\n }\n removeClass([this.element], [ROOT]);\n if (!isNullOrUndefined(this.inputWrapper)) {\n detach(this.inputWrapper.container);\n }\n }\n if (this.formElement) {\n EventHandler.remove(this.formElement, 'reset', this.resetFormHandler);\n }\n this.inputWrapper = null;\n this.keyboardModules = null;\n };\n DatePicker.prototype.ensureInputAttribute = function () {\n var prop = [];\n for (var i = 0; i < this.inputElement.attributes.length; i++) {\n prop[i] = this.inputElement.attributes[i].name;\n }\n for (var i = 0; i < prop.length; i++) {\n if (isNullOrUndefined(this.inputElementCopy.getAttribute(prop[i]))) {\n if (prop[i].toLowerCase() === 'value') {\n this.inputElement.value = '';\n }\n this.inputElement.removeAttribute(prop[i]);\n }\n else {\n if (prop[i].toLowerCase() === 'value') {\n this.inputElement.value = this.inputElementCopy.getAttribute(prop[i]);\n }\n this.inputElement.setAttribute(prop[i], this.inputElementCopy.getAttribute(prop[i]));\n }\n }\n };\n /**\n * Initialize the event handler\n *\n * @returns {void}\n * @private\n */\n DatePicker.prototype.preRender = function () {\n this.inputElementCopy = this.element.cloneNode(true);\n removeClass([this.inputElementCopy], [ROOT, CONTROL, LIBRARY]);\n this.inputElement = this.element;\n this.formElement = closest(this.inputElement, 'form');\n this.index = this.showClearButton ? 2 : 1;\n this.ngTag = null;\n if (this.element.tagName === 'EJS-DATEPICKER' || this.element.tagName === 'EJS-DATETIMEPICKER') {\n this.ngTag = this.element.tagName;\n this.inputElement = this.createElement('input');\n this.element.appendChild(this.inputElement);\n }\n if (this.element.getAttribute('id')) {\n if (this.ngTag !== null) {\n this.inputElement.id = this.element.getAttribute('id') + '_input';\n }\n }\n else {\n if (this.getModuleName() === 'datetimepicker') {\n this.element.id = getUniqueID('ej2-datetimepicker');\n if (this.ngTag !== null) {\n attributes(this.inputElement, { 'id': this.element.id + '_input' });\n }\n }\n else {\n this.element.id = getUniqueID('ej2-datepicker');\n if (this.ngTag !== null) {\n attributes(this.inputElement, { 'id': this.element.id + '_input' });\n }\n }\n }\n if (this.ngTag !== null) {\n this.validationAttribute(this.element, this.inputElement);\n }\n this.updateHtmlAttributeToElement();\n this.defaultKeyConfigs = this.getDefaultKeyConfig();\n this.checkHtmlAttributes(false);\n this.tabIndex = this.element.hasAttribute('tabindex') ? this.element.getAttribute('tabindex') : '0';\n this.element.removeAttribute('tabindex');\n _super.prototype.preRender.call(this);\n };\n DatePicker.prototype.getDefaultKeyConfig = function () {\n this.defaultKeyConfigs = {\n altUpArrow: 'alt+uparrow',\n altDownArrow: 'alt+downarrow',\n escape: 'escape',\n enter: 'enter',\n controlUp: 'ctrl+38',\n controlDown: 'ctrl+40',\n moveDown: 'downarrow',\n moveUp: 'uparrow',\n moveLeft: 'leftarrow',\n moveRight: 'rightarrow',\n select: 'enter',\n home: 'home',\n end: 'end',\n pageUp: 'pageup',\n pageDown: 'pagedown',\n shiftPageUp: 'shift+pageup',\n shiftPageDown: 'shift+pagedown',\n controlHome: 'ctrl+home',\n controlEnd: 'ctrl+end',\n shiftTab: 'shift+tab',\n tab: 'tab'\n };\n return this.defaultKeyConfigs;\n };\n DatePicker.prototype.validationAttribute = function (target, inputElement) {\n var nameAttribute = target.getAttribute('name') ? target.getAttribute('name') : target.getAttribute('id');\n inputElement.setAttribute('name', nameAttribute);\n target.removeAttribute('name');\n var attribute = ['required', 'aria-required', 'form'];\n for (var i = 0; i < attribute.length; i++) {\n if (isNullOrUndefined(target.getAttribute(attribute[i]))) {\n continue;\n }\n var attr = target.getAttribute(attribute[i]);\n inputElement.setAttribute(attribute[i], attr);\n target.removeAttribute(attribute[i]);\n }\n };\n DatePicker.prototype.checkFormat = function () {\n var culture = new Internationalization(this.locale);\n if (this.format) {\n if (typeof this.format === 'string') {\n this.formatString = this.format;\n }\n else if (this.format.skeleton !== '' && !isNullOrUndefined(this.format.skeleton)) {\n var skeletonString = this.format.skeleton;\n if (this.getModuleName() === 'datetimepicker') {\n this.formatString = culture.getDatePattern({ skeleton: skeletonString, type: 'dateTime' });\n }\n else {\n this.formatString = culture.getDatePattern({ skeleton: skeletonString, type: 'date' });\n }\n }\n else {\n if (this.getModuleName() === 'datetimepicker') {\n this.formatString = this.dateTimeFormat;\n }\n else {\n this.formatString = null;\n }\n }\n }\n else {\n this.formatString = null;\n }\n };\n DatePicker.prototype.checkHtmlAttributes = function (dynamic) {\n this.globalize = new Internationalization(this.locale);\n this.checkFormat();\n this.checkView();\n var attributes = dynamic ? isNullOrUndefined(this.htmlAttributes) ? [] : Object.keys(this.htmlAttributes) :\n ['value', 'min', 'max', 'disabled', 'readonly', 'style', 'name', 'placeholder', 'type'];\n var options;\n if (this.getModuleName() === 'datetimepicker') {\n if (this.calendarMode === 'Gregorian') {\n options = {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat,\n type: 'dateTime', skeleton: 'yMd'\n };\n }\n else {\n options = {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat,\n type: 'dateTime', skeleton: 'yMd', calendar: 'islamic'\n };\n }\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n options = { format: this.formatString, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n options = { format: this.formatString, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n }\n for (var _i = 0, attributes_1 = attributes; _i < attributes_1.length; _i++) {\n var prop = attributes_1[_i];\n if (!isNullOrUndefined(this.inputElement.getAttribute(prop))) {\n switch (prop) {\n case 'disabled':\n if (((isNullOrUndefined(this.datepickerOptions) || (this.datepickerOptions['enabled'] === undefined)) || dynamic)) {\n var enabled = this.inputElement.getAttribute(prop) === 'disabled' ||\n this.inputElement.getAttribute(prop) === '' ||\n this.inputElement.getAttribute(prop) === 'true' ? false : true;\n this.setProperties({ enabled: enabled }, !dynamic);\n }\n break;\n case 'readonly':\n if (((isNullOrUndefined(this.datepickerOptions) || (this.datepickerOptions['readonly'] === undefined)) || dynamic)) {\n var readonly = this.inputElement.getAttribute(prop) === 'readonly' ||\n this.inputElement.getAttribute(prop) === '' || this.inputElement.getAttribute(prop) === 'true' ? true : false;\n this.setProperties({ readonly: readonly }, !dynamic);\n }\n break;\n case 'placeholder':\n if (((isNullOrUndefined(this.datepickerOptions) || (this.datepickerOptions['placeholder'] === undefined)) || dynamic)) {\n this.setProperties({ placeholder: this.inputElement.getAttribute(prop) }, !dynamic);\n }\n break;\n case 'style':\n this.inputElement.setAttribute('style', '' + this.inputElement.getAttribute(prop));\n break;\n case 'name':\n this.inputElement.setAttribute('name', '' + this.inputElement.getAttribute(prop));\n break;\n case 'value':\n if (((isNullOrUndefined(this.datepickerOptions) || (this.datepickerOptions['value'] === undefined)) || dynamic)) {\n var value = this.inputElement.getAttribute(prop);\n this.setProperties(setValue(prop, this.globalize.parseDate(value, options), {}), !dynamic);\n }\n break;\n case 'min':\n if ((+this.min === +new Date(1900, 0, 1)) || dynamic) {\n var min = this.inputElement.getAttribute(prop);\n this.setProperties(setValue(prop, this.globalize.parseDate(min), {}), !dynamic);\n }\n break;\n case 'max':\n if ((+this.max === +new Date(2099, 11, 31)) || dynamic) {\n var max = this.inputElement.getAttribute(prop);\n this.setProperties(setValue(prop, this.globalize.parseDate(max), {}), !dynamic);\n }\n break;\n case 'type':\n if (this.inputElement.getAttribute(prop) !== 'text') {\n this.inputElement.setAttribute('type', 'text');\n }\n break;\n }\n }\n }\n };\n /**\n * To get component name.\n *\n * @returns {string} Returns the component name.\n * @private\n */\n DatePicker.prototype.getModuleName = function () {\n return 'datepicker';\n };\n DatePicker.prototype.disabledDates = function (isDynamic, isBlur) {\n if (isDynamic === void 0) { isDynamic = false; }\n if (isBlur === void 0) { isBlur = false; }\n var formatOptions;\n var globalize;\n var valueCopy = this.checkDateValue(this.value) ? new Date(+this.value) : new Date(this.checkValue(this.value));\n var previousValCopy = this.previousDate;\n //calls the Calendar render method to check the disabled dates through renderDayCell event and update the input value accordingly.\n this.minMaxUpdates();\n if (!isDynamic || (isDynamic && !isNullOrUndefined(this.renderDayCell))) {\n _super.prototype.render.call(this);\n }\n this.previousDate = previousValCopy;\n var date = valueCopy && +(valueCopy);\n var dateIdString = '*[id^=\"/id\"]'.replace('/id', '' + date);\n if (!this.strictMode) {\n if (typeof this.value === 'string' || ((typeof this.value === 'object') && (+this.value) !== (+valueCopy))) {\n this.setProperties({ value: valueCopy }, true);\n }\n }\n if (!isNullOrUndefined(this.calendarElement) && !isNullOrUndefined(this.calendarElement.querySelectorAll(dateIdString)[0])) {\n if (this.calendarElement.querySelectorAll(dateIdString)[0].classList.contains('e-disabled')) {\n if (!this.strictMode) {\n this.currentDate = new Date(new Date().setHours(0, 0, 0, 0));\n }\n }\n }\n var inputVal;\n if (this.getModuleName() === 'datetimepicker') {\n if (this.calendarMode === 'Gregorian') {\n globalize = this.globalize.formatDate(valueCopy, {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat,\n type: 'dateTime', skeleton: 'yMd'\n });\n }\n else {\n globalize = this.globalize.formatDate(valueCopy, {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.dateTimeFormat,\n type: 'dateTime', skeleton: 'yMd', calendar: 'islamic'\n });\n }\n inputVal = globalize;\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n formatOptions = { format: this.formatString, type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n inputVal = this.globalize.formatDate(valueCopy, formatOptions);\n }\n if (!this.popupObj) {\n this.updateInputValue(inputVal);\n if (this.enableMask) {\n this.updateInputValue(this.maskedDateValue);\n this.notify('createMask', {\n module: 'MaskedDateTime', isBlur: isBlur\n });\n }\n }\n };\n DatePicker.prototype.setAriaAttributes = function () {\n if (this.isCalendar()) {\n Input.addAttributes({ 'aria-expanded': 'true' }, this.inputElement);\n attributes(this.inputElement, { 'aria-owns': this.inputElement.id + '_options' });\n attributes(this.inputElement, { 'aria-controls': this.inputElement.id });\n if (this.value) {\n attributes(this.inputElement, { 'aria-activedescendant': '' + this.setActiveDescendant() });\n }\n }\n else {\n Input.addAttributes({ 'aria-expanded': 'false' }, this.inputElement);\n this.inputElement.removeAttribute('aria-owns');\n this.inputElement.removeAttribute('aria-controls');\n this.inputElement.removeAttribute('aria-activedescendant');\n }\n };\n DatePicker.prototype.errorClass = function () {\n var dateIdString = '*[id^=\"/id\"]'.replace('/id', '' + (+this.value));\n var isDisabledDate = this.calendarElement &&\n this.calendarElement.querySelectorAll(dateIdString)[0] &&\n this.calendarElement.querySelectorAll(dateIdString)[0].classList.contains('e-disabled');\n if ((!isNullOrUndefined(this.value) && !isNullOrUndefined(this.min) &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !isNullOrUndefined(this.max) && !(new Date(this.value).setMilliseconds(0) >= new Date(this.min).setMilliseconds(0)\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n && new Date(this.value).setMilliseconds(0) <= new Date(this.max).setMilliseconds(0)))\n || (!this.strictMode && this.inputElement.value !== '' && this.inputElement.value !== this.maskedDateValue && isNullOrUndefined(this.value) || isDisabledDate)) {\n addClass([this.inputWrapper.container], ERROR);\n attributes(this.inputElement, { 'aria-invalid': 'true' });\n }\n else if (!isNullOrUndefined(this.inputWrapper)) {\n removeClass([this.inputWrapper.container], ERROR);\n attributes(this.inputElement, { 'aria-invalid': 'false' });\n }\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @param {DatePickerModel} newProp - Returns the dynamic property value of the component.\n * @param {DatePickerModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n * @private\n */\n DatePicker.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'value':\n this.isDynamicValueChanged = true;\n this.isInteracted = false;\n this.invalidValueString = null;\n this.checkInvalidValue(newProp.value);\n newProp.value = this.value;\n this.previousElementValue = this.inputElement.value;\n if (isNullOrUndefined(this.value)) {\n if (this.enableMask) {\n this.updateInputValue(this.maskedDateValue);\n }\n else {\n this.updateInputValue('');\n }\n this.currentDate = new Date(new Date().setHours(0, 0, 0, 0));\n }\n this.updateInput(true);\n if (+this.previousDate !== +this.value) {\n this.changeTrigger(null);\n }\n this.isInteracted = true;\n this.preventChange = this.isAngular && this.preventChange ? !this.preventChange : this.preventChange;\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n break;\n case 'format':\n this.checkFormat();\n this.bindInputEvent();\n this.updateInput();\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n if (!this.value) {\n this.updateInputValue(this.maskedDateValue);\n }\n }\n break;\n case 'allowEdit':\n this.setAllowEdit();\n break;\n case 'placeholder':\n Input.setPlaceholder(this.placeholder, this.inputElement);\n break;\n case 'readonly':\n Input.setReadonly(this.readonly, this.inputElement);\n break;\n case 'enabled':\n Input.setEnabled(this.enabled, this.inputElement);\n this.setAriaDisabled();\n break;\n case 'htmlAttributes':\n this.updateHtmlAttributeToElement();\n this.updateHtmlAttributeToWrapper();\n this.checkHtmlAttributes(true);\n break;\n case 'locale':\n this.globalize = new Internationalization(this.locale);\n this.l10n.setLocale(this.locale);\n if (this.datepickerOptions && this.datepickerOptions.placeholder == null) {\n this.setProperties({ placeholder: this.l10n.getConstant('placeholder') }, true);\n Input.setPlaceholder(this.placeholder, this.inputElement);\n }\n this.updateInput();\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n break;\n case 'enableRtl':\n Input.setEnableRtl(this.enableRtl, [this.inputWrapper.container]);\n break;\n case 'start':\n case 'depth':\n this.checkView();\n if (this.calendarElement) {\n _super.prototype.onPropertyChanged.call(this, newProp, oldProp);\n }\n break;\n case 'zIndex':\n this.setProperties({ zIndex: newProp.zIndex }, true);\n break;\n case 'cssClass':\n this.updateCssClass(newProp.cssClass, oldProp.cssClass);\n break;\n case 'showClearButton':\n Input.setClearButton(this.showClearButton, this.inputElement, this.inputWrapper);\n this.bindClearEvent();\n this.index = this.showClearButton ? 2 : 1;\n break;\n case 'strictMode':\n this.invalidValueString = null;\n this.updateInput();\n break;\n case 'width':\n this.setWidth(newProp.width);\n Input.calculateWidth(this.inputElement, this.inputWrapper.container);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-icon');\n }\n break;\n case 'floatLabelType':\n this.floatLabelType = newProp.floatLabelType;\n Input.removeFloating(this.inputWrapper);\n Input.addFloating(this.inputElement, this.floatLabelType, this.placeholder);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-icon');\n }\n break;\n case 'enableMask':\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n this.updateInputValue(this.maskedDateValue);\n this.bindInputEvent();\n }\n else {\n if (this.inputElement.value === this.maskedDateValue) {\n this.updateInputValue('');\n }\n }\n break;\n default:\n if (this.calendarElement && this.isCalendar()) {\n _super.prototype.onPropertyChanged.call(this, newProp, oldProp);\n }\n break;\n }\n if (!this.isDynamicValueChanged) {\n this.hide(null);\n }\n this.isDynamicValueChanged = false;\n }\n };\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"width\", void 0);\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"value\", void 0);\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"cssClass\", void 0);\n __decorate([\n Property(false)\n ], DatePicker.prototype, \"strictMode\", void 0);\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"format\", void 0);\n __decorate([\n Property(true)\n ], DatePicker.prototype, \"enabled\", void 0);\n __decorate([\n Property(false)\n ], DatePicker.prototype, \"fullScreenMode\", void 0);\n __decorate([\n Property({})\n ], DatePicker.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"values\", void 0);\n __decorate([\n Property(false)\n ], DatePicker.prototype, \"isMultiSelection\", void 0);\n __decorate([\n Property(true)\n ], DatePicker.prototype, \"showClearButton\", void 0);\n __decorate([\n Property(true)\n ], DatePicker.prototype, \"allowEdit\", void 0);\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"keyConfigs\", void 0);\n __decorate([\n Property(false)\n ], DatePicker.prototype, \"enablePersistence\", void 0);\n __decorate([\n Property(1000)\n ], DatePicker.prototype, \"zIndex\", void 0);\n __decorate([\n Property(false)\n ], DatePicker.prototype, \"readonly\", void 0);\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"placeholder\", void 0);\n __decorate([\n Property('Never')\n ], DatePicker.prototype, \"floatLabelType\", void 0);\n __decorate([\n Property(null)\n ], DatePicker.prototype, \"serverTimezoneOffset\", void 0);\n __decorate([\n Property(false)\n ], DatePicker.prototype, \"openOnFocus\", void 0);\n __decorate([\n Property(false)\n ], DatePicker.prototype, \"enableMask\", void 0);\n __decorate([\n Property({ day: 'day', month: 'month', year: 'year', hour: 'hour', minute: 'minute', second: 'second', dayOfTheWeek: 'day of the week' })\n ], DatePicker.prototype, \"maskPlaceholder\", void 0);\n __decorate([\n Event()\n ], DatePicker.prototype, \"open\", void 0);\n __decorate([\n Event()\n ], DatePicker.prototype, \"cleared\", void 0);\n __decorate([\n Event()\n ], DatePicker.prototype, \"close\", void 0);\n __decorate([\n Event()\n ], DatePicker.prototype, \"blur\", void 0);\n __decorate([\n Event()\n ], DatePicker.prototype, \"focus\", void 0);\n __decorate([\n Event()\n ], DatePicker.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], DatePicker.prototype, \"destroyed\", void 0);\n DatePicker = __decorate([\n NotifyPropertyChanges\n ], DatePicker);\n return DatePicker;\n}(Calendar));\nexport { DatePicker };\n","//! moment.js locale configuration\n//! locale : Spanish (Dominican Republic) [es-do]\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsShortDot =\n 'ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.'.split(\n '_'\n ),\n monthsShort = 'ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic'.split('_'),\n monthsParse = [\n /^ene/i,\n /^feb/i,\n /^mar/i,\n /^abr/i,\n /^may/i,\n /^jun/i,\n /^jul/i,\n /^ago/i,\n /^sep/i,\n /^oct/i,\n /^nov/i,\n /^dic/i,\n ],\n monthsRegex =\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i;\n\n var esDo = moment.defineLocale('es-do', {\n months: 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split(\n '_'\n ),\n monthsShort: function (m, format) {\n if (!m) {\n return monthsShortDot;\n } else if (/-MMM-/.test(format)) {\n return monthsShort[m.month()];\n } else {\n return monthsShortDot[m.month()];\n }\n },\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex:\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,\n monthsShortStrictRegex:\n /^(ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i,\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n weekdays: 'domingo_lunes_martes_miércoles_jueves_viernes_sábado'.split('_'),\n weekdaysShort: 'dom._lun._mar._mié._jue._vie._sáb.'.split('_'),\n weekdaysMin: 'do_lu_ma_mi_ju_vi_sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'DD/MM/YYYY',\n LL: 'D [de] MMMM [de] YYYY',\n LLL: 'D [de] MMMM [de] YYYY h:mm A',\n LLLL: 'dddd, D [de] MMMM [de] YYYY h:mm A',\n },\n calendar: {\n sameDay: function () {\n return '[hoy a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextDay: function () {\n return '[mañana a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextWeek: function () {\n return 'dddd [a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastDay: function () {\n return '[ayer a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastWeek: function () {\n return (\n '[el] dddd [pasado a la' +\n (this.hours() !== 1 ? 's' : '') +\n '] LT'\n );\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'en %s',\n past: 'hace %s',\n s: 'unos segundos',\n ss: '%d segundos',\n m: 'un minuto',\n mm: '%d minutos',\n h: 'una hora',\n hh: '%d horas',\n d: 'un dÃa',\n dd: '%d dÃas',\n w: 'una semana',\n ww: '%d semanas',\n M: 'un mes',\n MM: '%d meses',\n y: 'un año',\n yy: '%d años',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return esDo;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable max-len */\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable jsdoc/require-param */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable valid-jsdoc */\nimport { Property, ChildProperty, Complex, Collection, getValue, animationMode } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { StackValues, RectOption, appendChildElement, appendClipElement } from '../../common/utils/helper';\nimport { firstToLowerCase, CircleOption, getColorByValue } from '../../common/utils/helper';\nimport { Rect } from '@syncfusion/ej2-svg-base';\nimport { Border, Font, Margin, Animation, EmptyPointSettings, CornerRadius, Connector, DragSettings } from '../../common/model/base';\nimport { DataManager, DataUtil } from '@syncfusion/ej2-data';\nimport { Offset } from '../../common/model/base';\nimport { seriesRender } from '../../common/model/constants';\nimport { getVisiblePoints, setRange } from '../../common/utils/helper';\nimport { Browser } from '@syncfusion/ej2-base';\n/**\n * Configures the data label in the series.\n */\nvar DataLabelSettings = /** @class */ (function (_super) {\n __extends(DataLabelSettings, _super);\n function DataLabelSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], DataLabelSettings.prototype, \"visible\", void 0);\n __decorate([\n Property(true)\n ], DataLabelSettings.prototype, \"showZero\", void 0);\n __decorate([\n Property(null)\n ], DataLabelSettings.prototype, \"name\", void 0);\n __decorate([\n Property('transparent')\n ], DataLabelSettings.prototype, \"fill\", void 0);\n __decorate([\n Property(null)\n ], DataLabelSettings.prototype, \"format\", void 0);\n __decorate([\n Property(1)\n ], DataLabelSettings.prototype, \"opacity\", void 0);\n __decorate([\n Property(0)\n ], DataLabelSettings.prototype, \"angle\", void 0);\n __decorate([\n Property(false)\n ], DataLabelSettings.prototype, \"enableRotation\", void 0);\n __decorate([\n Property('Auto')\n ], DataLabelSettings.prototype, \"position\", void 0);\n __decorate([\n Property(5)\n ], DataLabelSettings.prototype, \"rx\", void 0);\n __decorate([\n Property(5)\n ], DataLabelSettings.prototype, \"ry\", void 0);\n __decorate([\n Property('Center')\n ], DataLabelSettings.prototype, \"alignment\", void 0);\n __decorate([\n Complex({ width: null, color: null }, Border)\n ], DataLabelSettings.prototype, \"border\", void 0);\n __decorate([\n Complex({ left: 5, right: 5, top: 5, bottom: 5 }, Margin)\n ], DataLabelSettings.prototype, \"margin\", void 0);\n __decorate([\n Complex({ size: '12px', color: null, fontStyle: 'Normal', fontWeight: '400', fontFamily: null }, Font)\n ], DataLabelSettings.prototype, \"font\", void 0);\n __decorate([\n Property(null)\n ], DataLabelSettings.prototype, \"template\", void 0);\n __decorate([\n Property('Hide')\n ], DataLabelSettings.prototype, \"labelIntersectAction\", void 0);\n return DataLabelSettings;\n}(ChildProperty));\nexport { DataLabelSettings };\n/**\n * Configures the marker in the series.\n */\nvar MarkerSettings = /** @class */ (function (_super) {\n __extends(MarkerSettings, _super);\n function MarkerSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], MarkerSettings.prototype, \"visible\", void 0);\n __decorate([\n Property(null)\n ], MarkerSettings.prototype, \"shape\", void 0);\n __decorate([\n Property('')\n ], MarkerSettings.prototype, \"imageUrl\", void 0);\n __decorate([\n Property(5)\n ], MarkerSettings.prototype, \"height\", void 0);\n __decorate([\n Property(false)\n ], MarkerSettings.prototype, \"isFilled\", void 0);\n __decorate([\n Property(5)\n ], MarkerSettings.prototype, \"width\", void 0);\n __decorate([\n Complex({ width: 2, color: null }, Border)\n ], MarkerSettings.prototype, \"border\", void 0);\n __decorate([\n Complex({ x: 0, y: 0 }, Offset)\n ], MarkerSettings.prototype, \"offset\", void 0);\n __decorate([\n Property(null)\n ], MarkerSettings.prototype, \"fill\", void 0);\n __decorate([\n Property(true)\n ], MarkerSettings.prototype, \"allowHighlight\", void 0);\n __decorate([\n Property(1)\n ], MarkerSettings.prototype, \"opacity\", void 0);\n __decorate([\n Complex({}, DataLabelSettings)\n ], MarkerSettings.prototype, \"dataLabel\", void 0);\n return MarkerSettings;\n}(ChildProperty));\nexport { MarkerSettings };\n/**\n * Configures the pareto in the series.\n */\nvar ParetoOptions = /** @class */ (function (_super) {\n __extends(ParetoOptions, _super);\n function ParetoOptions() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], ParetoOptions.prototype, \"fill\", void 0);\n __decorate([\n Property(1)\n ], ParetoOptions.prototype, \"width\", void 0);\n __decorate([\n Property('0')\n ], ParetoOptions.prototype, \"dashArray\", void 0);\n __decorate([\n Complex(null, MarkerSettings)\n ], ParetoOptions.prototype, \"marker\", void 0);\n __decorate([\n Property(true)\n ], ParetoOptions.prototype, \"showAxis\", void 0);\n return ParetoOptions;\n}(ChildProperty));\nexport { ParetoOptions };\n/**\n * Points model for the series.\n *\n * @public\n */\nvar Points = /** @class */ (function () {\n function Points() {\n /** point symbol location. */\n this.symbolLocations = null;\n /** point region. */\n this.regions = null;\n /** point percentage value. */\n this.percentage = null;\n /** point region data. */\n this.regionData = null;\n /** To know the point is selected. */\n this.isSelect = false;\n /** point marker. */\n this.marker = {\n visible: false\n };\n /**\n * To identify point y value with in the range.\n *\n * @private\n */\n this.isPointInRange = true;\n /** vertical error value for the point. */\n this.verticalError = null;\n /** vertical negative error value for the point. */\n this.verticalNegativeError = null;\n /** horizontal error value for the point. */\n this.horizontalError = null;\n /** horizontal negative error value for the point. */\n this.horizontalNegativeError = null;\n /** vertical positive error value for the point. */\n this.verticalPositiveError = null;\n /** horizontal positive error value for the point. */\n this.horizontalPositiveError = null;\n }\n return Points;\n}());\nexport { Points };\n/**\n * Defines the behavior of the Trendlines\n */\nvar Trendline = /** @class */ (function (_super) {\n __extends(Trendline, _super);\n function Trendline() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n /** @private */\n _this.clipRect = new Rect(0, 0, 0, 0);\n return _this;\n }\n /** @private */\n Trendline.prototype.setDataSource = function (series, chart) {\n if (series) {\n this.points = series.points;\n }\n chart.trendLineModule.initDataSource(this);\n chart.visibleSeriesCount++;\n };\n __decorate([\n Property('')\n ], Trendline.prototype, \"name\", void 0);\n __decorate([\n Property('')\n ], Trendline.prototype, \"dashArray\", void 0);\n __decorate([\n Property(true)\n ], Trendline.prototype, \"visible\", void 0);\n __decorate([\n Property('Linear')\n ], Trendline.prototype, \"type\", void 0);\n __decorate([\n Property(2)\n ], Trendline.prototype, \"period\", void 0);\n __decorate([\n Property(2)\n ], Trendline.prototype, \"polynomialOrder\", void 0);\n __decorate([\n Property(0)\n ], Trendline.prototype, \"backwardForecast\", void 0);\n __decorate([\n Property(0)\n ], Trendline.prototype, \"forwardForecast\", void 0);\n __decorate([\n Complex({}, Animation)\n ], Trendline.prototype, \"animation\", void 0);\n __decorate([\n Complex({}, MarkerSettings)\n ], Trendline.prototype, \"marker\", void 0);\n __decorate([\n Property(true)\n ], Trendline.prototype, \"enableTooltip\", void 0);\n __decorate([\n Property(null)\n ], Trendline.prototype, \"intercept\", void 0);\n __decorate([\n Property('')\n ], Trendline.prototype, \"fill\", void 0);\n __decorate([\n Property(1)\n ], Trendline.prototype, \"width\", void 0);\n __decorate([\n Property('SeriesType')\n ], Trendline.prototype, \"legendShape\", void 0);\n return Trendline;\n}(ChildProperty));\nexport { Trendline };\n/**\n * Configures Error bar in series.\n */\nvar ErrorBarCapSettings = /** @class */ (function (_super) {\n __extends(ErrorBarCapSettings, _super);\n function ErrorBarCapSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(1)\n ], ErrorBarCapSettings.prototype, \"width\", void 0);\n __decorate([\n Property(10)\n ], ErrorBarCapSettings.prototype, \"length\", void 0);\n __decorate([\n Property(null)\n ], ErrorBarCapSettings.prototype, \"color\", void 0);\n __decorate([\n Property(1)\n ], ErrorBarCapSettings.prototype, \"opacity\", void 0);\n return ErrorBarCapSettings;\n}(ChildProperty));\nexport { ErrorBarCapSettings };\nvar ChartSegment = /** @class */ (function (_super) {\n __extends(ChartSegment, _super);\n function ChartSegment() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], ChartSegment.prototype, \"value\", void 0);\n __decorate([\n Property(null)\n ], ChartSegment.prototype, \"color\", void 0);\n __decorate([\n Property('0')\n ], ChartSegment.prototype, \"dashArray\", void 0);\n return ChartSegment;\n}(ChildProperty));\nexport { ChartSegment };\n/**\n * Error bar settings\n *\n * @public\n */\nvar ErrorBarSettings = /** @class */ (function (_super) {\n __extends(ErrorBarSettings, _super);\n function ErrorBarSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], ErrorBarSettings.prototype, \"visible\", void 0);\n __decorate([\n Property('Fixed')\n ], ErrorBarSettings.prototype, \"type\", void 0);\n __decorate([\n Property('Both')\n ], ErrorBarSettings.prototype, \"direction\", void 0);\n __decorate([\n Property('Vertical')\n ], ErrorBarSettings.prototype, \"mode\", void 0);\n __decorate([\n Property(null)\n ], ErrorBarSettings.prototype, \"color\", void 0);\n __decorate([\n Property(1)\n ], ErrorBarSettings.prototype, \"verticalError\", void 0);\n __decorate([\n Property(1)\n ], ErrorBarSettings.prototype, \"width\", void 0);\n __decorate([\n Property(1)\n ], ErrorBarSettings.prototype, \"horizontalError\", void 0);\n __decorate([\n Property(3)\n ], ErrorBarSettings.prototype, \"verticalPositiveError\", void 0);\n __decorate([\n Property(3)\n ], ErrorBarSettings.prototype, \"verticalNegativeError\", void 0);\n __decorate([\n Property(1)\n ], ErrorBarSettings.prototype, \"horizontalPositiveError\", void 0);\n __decorate([\n Property(1)\n ], ErrorBarSettings.prototype, \"horizontalNegativeError\", void 0);\n __decorate([\n Complex(null, ErrorBarCapSettings)\n ], ErrorBarSettings.prototype, \"errorBarCap\", void 0);\n __decorate([\n Property('')\n ], ErrorBarSettings.prototype, \"errorBarColorMapping\", void 0);\n return ErrorBarSettings;\n}(ChildProperty));\nexport { ErrorBarSettings };\n/**\n * Defines the common behavior of Series and Technical Indicators\n */\nvar SeriesBase = /** @class */ (function (_super) {\n __extends(SeriesBase, _super);\n function SeriesBase() {\n /**\n * The DataSource field that contains the x value.\n * It is applicable for series and technical indicators\n *\n * @default ''\n */\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.rangeColorPoints = [];\n _this.isAdvancedColor = undefined;\n /** @private */\n _this.currentViewData = [];\n /** @private */\n _this.clipRect = new Rect(0, 0, 0, 0);\n /** @private */\n _this.seriesType = 'XY';\n _this.isRectTypeSeries = false;\n return _this;\n }\n /**\n * Process data for the series.\n *\n * @hidden\n */\n SeriesBase.prototype.processJsonData = function () {\n var i = 0;\n var point = new Points();\n var xName = (this instanceof Series && this.type === 'Histogram') ? 'x' : this.xName;\n var textMappingName = this instanceof Series && this.marker.dataLabel.name ?\n this.marker.dataLabel.name : '';\n if (this instanceof Series) {\n if ((this.type === 'Waterfall' || this.type === 'Histogram')) {\n this.currentViewData = this.chart[firstToLowerCase(this.type) + 'SeriesModule'].\n processInternalData(extend([], this.currentViewData, null, true), this);\n }\n if (this.category === 'Pareto') {\n if (this.type === 'Line') {\n this.currentViewData = this.chart.paretoSeriesModule.performCumulativeCalculation(this.currentViewData, this);\n }\n }\n this.isRectTypeSeries = this.type.indexOf('Column') > -1 || this.type.indexOf('Bar') > -1\n || this.type.indexOf('Histogram') > -1;\n }\n var len = (this.currentViewData || []).length;\n this.points = [];\n this.xMin = Infinity;\n this.xMax = -Infinity;\n this.yMin = Infinity;\n this.yMax = -Infinity;\n this.sizeMax = -Infinity;\n this.getSeriesType();\n if (this.xAxis.valueType === 'Category') {\n while (i < len) {\n point = this.dataPoint(i, textMappingName, xName);\n this.pushCategoryData(point, i, point.x);\n this.pushData(point, i);\n this.setEmptyPoint(point, i);\n this.rangeColorsInterior(point);\n i++;\n }\n }\n else if (this.xAxis.valueType.indexOf('DateTime') > -1) {\n var option = {\n skeleton: 'full',\n type: 'dateTime'\n };\n var dateParser = this.chart.intl.getDateParser(option);\n var dateFormatter = this.chart.intl.getDateFormat(option);\n while (i < len) {\n point = this.dataPoint(i, textMappingName, xName);\n if (!isNullOrUndefined(point.x) && point.x !== '') {\n point.x = new Date(DataUtil.parse.parseJson({ val: point.x }).val);\n if (this.xAxis.valueType === 'DateTime') {\n point.xValue = Date.parse(point.x.toString());\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-unused-expressions\n this.chart.isBlazor ? this.pushCategoryData(point, i, Date.parse(point.x.toString()).toString()) :\n this.pushCategoryData(point, i, Date.parse(dateParser(dateFormatter(point.x))).toString());\n }\n this.pushData(point, i);\n this.setEmptyPoint(point, i);\n //this.rangeColorsInterior(point);\n }\n else {\n point.visible = false;\n }\n i++;\n }\n }\n else {\n while (i < len) {\n point = this.dataPoint(i, textMappingName, xName);\n point.xValue = point.x;\n this.pushData(point, i);\n this.setEmptyPoint(point, i);\n i++;\n }\n }\n if (this instanceof Series && !(this.chart.stockChart && this.xAxis.valueType === 'DateTimeCategory')) {\n if (this.type.indexOf('Spline') > -1 || (this.drawType.indexOf('Spline') > -1 && this.chart.chartAreaType === 'PolarRadar')) {\n var isArea = (this.type.indexOf('Area') > -1 || this.drawType.indexOf('Area') > -1);\n var isRange = this.type.indexOf('Range') > -1;\n this.chart['spline' + (isArea ? isRange ? 'RangeArea' : 'Area' : '') + 'SeriesModule'].findSplinePoint(this);\n }\n else if (this.type.indexOf('Histogram') > -1 && (this.xAxis.maximum || this.xAxis.minimum)) {\n this.chart['histogramSeriesModule'].calculateBinValues(this);\n }\n if (this.type.indexOf('Histogram') > -1 && this.points.length === 1) {\n this.xMin = this.xMin - this.histogramValues.binWidth;\n this.xMax = this.xMax + this.histogramValues.binWidth;\n }\n }\n };\n SeriesBase.prototype.rangeColorsInterior = function (point) {\n if (this.chart.rangeColorSettings && this.chart.rangeColorSettings.length > 0 && this.chart.visibleSeries.length === 1 &&\n (this.chart.series[0].type === 'Column' || this.chart.series[0].type === 'Bar' ||\n this.chart.series[0].type === 'Scatter' || this.chart.series[0].type === 'Bubble')) {\n if (!this.rangeColorPoints[point.interior]) {\n this.rangeColorPoints[point.interior] = [];\n }\n else if (this.rangeColorPoints[point.interior] !== undefined) {\n this.rangeColorPoints[point.interior].push(point);\n }\n }\n };\n SeriesBase.prototype.pushData = function (point, i) {\n point.index = i;\n point.yValue = point.y;\n point.series = this;\n // To find the min, max for the axis range.\n this.xMin = Math.min(this.xMin, point.xValue);\n this.xMax = Math.max(this.xMax, point.xValue);\n this.xData.push(point.xValue);\n };\n /** @private */\n SeriesBase.prototype.dataPoint = function (i, textMappingName, xName) {\n this.points[i] = new Points();\n var point = this.points[i];\n var currentViewData = this.currentViewData[i];\n var getObjectValueByMappingString = this.enableComplexProperty ? getValue : this.getObjectValue;\n point.x = getObjectValueByMappingString(xName, currentViewData);\n point.high = getObjectValueByMappingString(this.high, currentViewData);\n point.low = getObjectValueByMappingString(this.low, currentViewData);\n point.open = getObjectValueByMappingString(this.open, currentViewData);\n point.close = getObjectValueByMappingString(this.close, currentViewData);\n point.volume = getObjectValueByMappingString(this.volume, currentViewData);\n point.interior = getObjectValueByMappingString(this.pointColorMapping, currentViewData);\n if (this instanceof Series) {\n if (this.errorBar.visible) {\n point.errorBarColor = getObjectValueByMappingString(this.errorBar.errorBarColorMapping, currentViewData);\n point.verticalError = typeof this.errorBar.verticalError == 'string' ? getObjectValueByMappingString(this.errorBar.verticalError, currentViewData) : this.errorBar.verticalError;\n point.horizontalError = typeof this.errorBar.horizontalError == 'string' ? getObjectValueByMappingString(this.errorBar.horizontalError, currentViewData) : this.errorBar.horizontalError;\n point.verticalNegativeError = typeof this.errorBar.verticalNegativeError == 'string' ? getObjectValueByMappingString(this.errorBar.verticalNegativeError, currentViewData) : this.errorBar.verticalNegativeError;\n point.verticalPositiveError = typeof this.errorBar.verticalPositiveError == 'string' ? getObjectValueByMappingString(this.errorBar.verticalPositiveError, currentViewData) : this.errorBar.verticalPositiveError;\n point.horizontalNegativeError = typeof this.errorBar.horizontalNegativeError == 'string' ? getObjectValueByMappingString(this.errorBar.horizontalNegativeError, currentViewData) : this.errorBar.horizontalNegativeError;\n point.horizontalPositiveError = typeof this.errorBar.horizontalPositiveError == 'string' ? getObjectValueByMappingString(this.errorBar.horizontalPositiveError, currentViewData) : this.errorBar.horizontalPositiveError;\n }\n point.y = getObjectValueByMappingString(this.yName, currentViewData);\n point.size = getObjectValueByMappingString(this.size, currentViewData);\n point.text = getObjectValueByMappingString(textMappingName, currentViewData);\n point.tooltip = getObjectValueByMappingString(this.tooltipMappingName, currentViewData);\n if (this.isAdvancedColorSupported()) {\n this.rangeColorName = this.colorName.length > 0 ? this.colorName : this.yName;\n point.colorValue = getObjectValueByMappingString(this.rangeColorName, currentViewData);\n point.interior = this.getPointFillColor(point.interior, point.colorValue);\n }\n }\n return point;\n };\n SeriesBase.prototype.isAdvancedColorSupported = function () {\n if (isNullOrUndefined(this.isAdvancedColor)) {\n if (this.chart.rangeColorSettings && this.chart.rangeColorSettings.length > 0 &&\n (this.chart.series[0].type === 'Column' || this.chart.series[0].type === 'Bar' ||\n this.chart.series[0].type === 'Scatter' || this.chart.series[0].type === 'Bubble')) {\n this.isAdvancedColor = true;\n }\n else {\n this.isAdvancedColor = false;\n }\n }\n return this.isAdvancedColor;\n };\n SeriesBase.prototype.getPointFillColor = function (pointFill, value) {\n var color = pointFill;\n if (value && this.chart.rangeColorSettings && this.chart.rangeColorSettings.length > 0) {\n for (var _i = 0, _a = this.chart.rangeColorSettings; _i < _a.length; _i++) {\n var rangeMap = _a[_i];\n if (value >= rangeMap.start && value <= rangeMap.end) {\n if (rangeMap.colors.length > 1) {\n color = getColorByValue(rangeMap, value);\n }\n else {\n color = rangeMap.colors[0];\n }\n }\n }\n }\n return color;\n };\n SeriesBase.prototype.getObjectValue = function (mappingName, data) {\n return data[mappingName];\n };\n /**\n * To set empty point value based on empty point mode\n *\n * @private\n */\n SeriesBase.prototype.setEmptyPoint = function (point, i) {\n if (!this.findVisibility(point)) {\n point.visible = true;\n return null;\n }\n point.isEmpty = true;\n var mode = this instanceof Series && point.isPointInRange ? this.emptyPointSettings.mode : 'Drop';\n switch (mode) {\n case 'Zero':\n point.visible = true;\n if (this instanceof Series && this.seriesType.indexOf('HighLow') > -1) {\n point.high = point.low = 0;\n if (this.seriesType.indexOf('HighLowOpenClose') > -1) {\n point.open = point.close = 0;\n }\n }\n else {\n point.y = point.yValue = this.yData[i] = 0;\n }\n break;\n case 'Average':\n if (this instanceof Series) {\n if (this.seriesType.indexOf('HighLow') > -1) {\n point.high = (isNullOrUndefined(point.high) || isNaN(+point.high)) ? this.getAverage(this.high, i) : point.high;\n point.low = (isNullOrUndefined(point.low) || isNaN(+point.low)) ? this.getAverage(this.low, i) : point.low;\n if (this.seriesType.indexOf('HighLowOpenClose') > -1) {\n point.open = (isNullOrUndefined(point.open) || isNaN(+point.open)) ? this.getAverage(this.open, i) : point.open;\n point.close = (isNullOrUndefined(point.close) || isNaN(+point.close)) ? this.getAverage(this.close, i) :\n point.close;\n }\n }\n else {\n point.y = point.yValue = this.yData[i] = this.getAverage(this.yName, i);\n }\n }\n point.visible = true;\n break;\n case 'Drop':\n case 'Gap':\n this.yData[i] = null;\n point.visible = false;\n break;\n }\n };\n SeriesBase.prototype.findVisibility = function (point) {\n var type = this instanceof Series ? this.seriesType : 'HighLowOpenClose';\n var yValues;\n var yAxisMin = this.yAxis.minimum;\n var yAxisMax = this.yAxis.maximum;\n switch (type) {\n case 'XY':\n if (this.chart.chartAreaType === 'PolarRadar' && ((!isNullOrUndefined(yAxisMin) && point.yValue < yAxisMin) ||\n (!isNullOrUndefined(yAxisMax) && point.yValue > yAxisMax))) {\n point.isPointInRange = false;\n return true;\n }\n this.setXYMinMax(point.yValue);\n this.yData.push(point.yValue);\n if (this instanceof Series && this.type === 'Bubble') {\n this.sizeMax = Math.max(this.sizeMax, (isNullOrUndefined(point.size) || isNaN(+point.size)) ? this.sizeMax\n : point.size);\n }\n return isNullOrUndefined(point.x) || (isNullOrUndefined(point.y) || isNaN(+point.y));\n case 'HighLow':\n this.setHiloMinMax(point.high, point.low);\n return isNullOrUndefined(point.x) || (isNullOrUndefined(point.low) || isNaN(+point.low)) ||\n (isNullOrUndefined(point.high) || isNaN(+point.high));\n case 'HighLowOpenClose':\n this.setHiloMinMax(point.high, point.low);\n return isNullOrUndefined(point.x) || (isNullOrUndefined(point.low) || isNaN(+point.low)) ||\n (isNullOrUndefined(point.open) || isNaN(+point.open)) || (isNullOrUndefined(point.close) || isNaN(+point.close))\n || (isNullOrUndefined(point.high) || isNaN(+point.high));\n case 'BoxPlot':\n yValues = (point.y || [null]).filter(function (value) {\n return !isNullOrUndefined(value) && !isNaN(value);\n }).sort(function (a, b) {\n return a - b;\n });\n point.y = yValues;\n this.yMin = Math.min(this.yMin, Math.min.apply(Math, yValues));\n this.yMax = Math.max(this.yMax, Math.max.apply(Math, yValues));\n return !yValues.length;\n }\n };\n /**\n * To get Y min max for the provided point seriesType XY\n */\n SeriesBase.prototype.setXYMinMax = function (yValue) {\n var isLogAxis = (this.yAxis.valueType === 'Logarithmic' || this.xAxis.valueType === 'Logarithmic');\n var isNegativeValue = yValue < 0 || this.yAxis.rangePadding === 'None';\n var seriesMinY;\n if (this.isRectTypeSeries && !setRange(this.yAxis)) {\n seriesMinY = ((isLogAxis ? (yValue) : isNegativeValue ? yValue : 0));\n }\n else {\n seriesMinY = yValue;\n }\n this.yMin = isLogAxis ?\n Math.min(this.yMin, (isNullOrUndefined(seriesMinY) || isNaN(seriesMinY) || (seriesMinY === 0) ||\n (seriesMinY.toString() === '0') || (seriesMinY.toString() === '')) ? this.yMin : seriesMinY) :\n Math.min(this.yMin, (isNullOrUndefined(seriesMinY) || isNaN(seriesMinY)) ? this.yMin : seriesMinY);\n this.yMax = Math.max(this.yMax, (isNullOrUndefined(yValue) || isNaN(yValue)) ? this.yMax : yValue);\n };\n /**\n * To get Y min max for the provided point seriesType XY\n */\n SeriesBase.prototype.setHiloMinMax = function (high, low) {\n this.yMin = Math.min(this.yMin, Math.min((isNullOrUndefined(low) || isNaN(low)) ? this.yMin : low, (isNullOrUndefined(high) || isNaN(high)) ? this.yMin : high));\n this.yMax = Math.max(this.yMax, Math.max((isNullOrUndefined(low) || isNaN(low)) ? this.yMax : low, (isNullOrUndefined(high) || isNaN(high)) ? this.yMax : high));\n };\n /**\n * Finds the type of the series\n *\n * @private\n */\n SeriesBase.prototype.getSeriesType = function () {\n var type;\n if (this instanceof Series) {\n var seriesType = this.chart.chartAreaType === 'PolarRadar' ? this.drawType : this.type;\n if (seriesType) {\n switch (seriesType) {\n case 'RangeColumn':\n case 'RangeArea':\n case 'RangeStepArea':\n case 'SplineRangeArea':\n case 'Hilo':\n type = 'HighLow';\n break;\n case 'HiloOpenClose':\n case 'Candle':\n type = 'HighLowOpenClose';\n break;\n case 'BoxAndWhisker':\n type = 'BoxPlot';\n break;\n default:\n type = 'XY';\n }\n }\n }\n this.seriesType = type;\n };\n /** @private */\n SeriesBase.prototype.pushCategoryData = function (point, index, pointX) {\n if (!this.chart.tooltip.shared) {\n if (!this.visible) {\n return null;\n }\n }\n if (!this.xAxis.isIndexed) {\n if (this.xAxis.indexLabels[pointX] === undefined) {\n this.xAxis.indexLabels[pointX] = this.xAxis.labels.length;\n this.xAxis.labels.push(pointX);\n }\n point.xValue = this.xAxis.indexLabels[pointX];\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-unused-expressions\n this.xAxis.labels[index] ? this.xAxis.labels[index] += ', ' + pointX :\n this.xAxis.labels.push(pointX);\n point.xValue = index;\n }\n };\n /**\n * To find average of given property\n */\n SeriesBase.prototype.getAverage = function (member, i, data) {\n if (data === void 0) { data = this.currentViewData; }\n var previous = data[i - 1] ? (data[i - 1][member] || 0) : 0;\n var next = data[i + 1] ? (data[i + 1][member] || 0) : 0;\n return (previous + next) / 2;\n };\n /**\n * To find the control points for spline.\n *\n * @returns {void}\n * @private\n */\n SeriesBase.prototype.refreshDataManager = function (chart) {\n var _this = this;\n this.chart = chart;\n var dataSource;\n var isAngular = 'isAngular';\n if (chart[isAngular]) {\n dataSource = Object.keys(this.dataSource).length ? this.dataSource : chart.dataSource;\n }\n else {\n dataSource = this.dataSource || chart.dataSource;\n }\n if (!(dataSource instanceof DataManager) && isNullOrUndefined(this.query)) {\n this.dataManagerSuccess({ result: dataSource, count: dataSource.length }, false);\n return;\n }\n var dataManager = this.dataModule.getData(this.dataModule.generateQuery().requiresCount());\n dataManager.then(function (e) { return _this.dataManagerSuccess(e); });\n };\n SeriesBase.prototype.dataManagerSuccess = function (e, isRemoteData) {\n if (isRemoteData === void 0) { isRemoteData = true; }\n this.currentViewData = e.count ? e.result : [];\n this.chart.allowServerDataBinding = false;\n if (this instanceof Series) {\n if (this.chart.stockChart) {\n this.chart.stockChart.series[this.index].localData = this.currentViewData;\n }\n var argsData = {\n name: seriesRender, series: this, data: this.currentViewData, fill: this.interior\n };\n this.chart.trigger(seriesRender, argsData);\n this.interior = argsData.fill;\n this.currentViewData = argsData.data;\n }\n if (this.chart.stockChart && !(this instanceof Series)) {\n this.currentViewData = this.chart.stockChart.findCurrentData(this.chart.stockChart.series[0].localData, this.chart.stockChart.series[0].xName);\n }\n this.processJsonData();\n this.recordsCount = e.count;\n this.refreshChart(isRemoteData);\n this.currentViewData = null;\n };\n SeriesBase.prototype.refreshChart = function (isRemoteData) {\n var chart = this.chart;\n if (this instanceof Series) {\n chart.visibleSeriesCount += isRemoteData ? 1 : 0;\n }\n chart.refreshTechnicalIndicator(this);\n if (this instanceof Series && this.category !== 'TrendLine') {\n for (var _i = 0, _a = this.trendlines; _i < _a.length; _i++) {\n var trendline = _a[_i];\n trendline.setDataSource(this, chart);\n }\n }\n //if (chart.visibleSeries.length === (chart.visibleSeriesCount - chart.indicators.length)) {\n if (chart.visibleSeries.length === (chart.visibleSeriesCount)) {\n chart.refreshBound();\n chart.trigger('loaded', { chart: chart.isBlazor ? {} : chart });\n if (this.chart.stockChart && this.chart.stockChart.initialRender) {\n this.chart.stockChart.initialRender = false;\n this.chart.stockChart.stockChartDataManagerSuccess();\n }\n }\n if (this instanceof Series) {\n chart.visibleSeriesCount += isRemoteData ? 0 : 1;\n }\n };\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"xName\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"colorName\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"high\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"low\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"open\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"close\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"volume\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"pointColorMapping\", void 0);\n __decorate([\n Property(true)\n ], SeriesBase.prototype, \"visible\", void 0);\n __decorate([\n Property(null)\n ], SeriesBase.prototype, \"xAxisName\", void 0);\n __decorate([\n Property(null)\n ], SeriesBase.prototype, \"yAxisName\", void 0);\n __decorate([\n Complex(null, Animation)\n ], SeriesBase.prototype, \"animation\", void 0);\n __decorate([\n Property(null)\n ], SeriesBase.prototype, \"fill\", void 0);\n __decorate([\n Property(1)\n ], SeriesBase.prototype, \"width\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"dashArray\", void 0);\n __decorate([\n Property('')\n ], SeriesBase.prototype, \"dataSource\", void 0);\n __decorate([\n Property()\n ], SeriesBase.prototype, \"query\", void 0);\n __decorate([\n Collection([], ChartSegment)\n ], SeriesBase.prototype, \"segments\", void 0);\n __decorate([\n Property('X')\n ], SeriesBase.prototype, \"segmentAxis\", void 0);\n __decorate([\n Property(false)\n ], SeriesBase.prototype, \"enableComplexProperty\", void 0);\n return SeriesBase;\n}(ChildProperty));\nexport { SeriesBase };\n/**\n * Configures the series in charts.\n *\n * @public\n */\nvar Series = /** @class */ (function (_super) {\n __extends(Series, _super);\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n function Series(parent, propName, defaultValue, isArray) {\n var _this = _super.call(this, parent, propName, defaultValue, isArray) || this;\n _this.visibleSeriesCount = 0;\n /** @private */\n _this.category = 'Series';\n /** @private */\n _this.isRectSeries = false;\n /** @private */\n _this.drawPoints = [];\n /** @private */\n _this.lowDrawPoints = [];\n /** @private */\n _this.delayedAnimation = false;\n /** @private */\n _this.rangeColorName = _this.colorName.length > 0 ? _this.colorName : _this.yName;\n return _this;\n }\n /**\n * Refresh the axis label.\n *\n * @returns {void}\n * @private\n */\n Series.prototype.refreshAxisLabel = function () {\n if (this.xAxis.valueType !== 'Category') {\n return null;\n }\n this.xAxis.labels = [];\n this.xAxis.indexLabels = {};\n for (var _i = 0, _a = this.xAxis.series; _i < _a.length; _i++) {\n var item = _a[_i];\n if (item.visible && item.category !== 'TrendLine') {\n item.xMin = Infinity;\n item.xMax = -Infinity;\n for (var _b = 0, _c = item.points; _b < _c.length; _b++) {\n var point = _c[_b];\n item.pushCategoryData(point, point.index, point.x);\n item.xMin = Math.min(item.xMin, point.xValue);\n item.xMax = Math.max(item.xMax, point.xValue);\n }\n }\n }\n };\n /**\n * To get the series collection.\n *\n * @returns {void}\n * @private\n */\n Series.prototype.findSeriesCollection = function (column, row, isStack) {\n var seriesCollection = [];\n for (var _i = 0, _a = row.axes; _i < _a.length; _i++) {\n var rowAxis = _a[_i];\n for (var _b = 0, _c = rowAxis.series; _b < _c.length; _b++) {\n var rowSeries = _c[_b];\n for (var _d = 0, _e = column.axes; _d < _e.length; _d++) {\n var axis = _e[_d];\n for (var _f = 0, _g = axis.series; _f < _g.length; _f++) {\n var series = _g[_f];\n if (series === rowSeries && series.visible && this.rectSeriesInChart(series, isStack)) {\n seriesCollection.push(series);\n }\n }\n }\n }\n }\n return seriesCollection;\n };\n /**\n * To get the column type series.\n *\n * @returns {void}\n * @private\n */\n Series.prototype.rectSeriesInChart = function (series, isStack) {\n var type = (series.type).toLowerCase();\n return (type.indexOf('column') !== -1 || type.indexOf('bar') !== -1 || type.indexOf('histogram') !== -1 ||\n type.indexOf('hiloopenclose') !== -1 || type.indexOf('candle') !== -1 || type.indexOf('pareto') !== -1 ||\n type.indexOf('hilo') !== -1 || series.drawType.indexOf('Column') !== -1 ||\n type.indexOf('waterfall') !== -1 || type.indexOf('boxandwhisker') !== -1 || isStack);\n };\n /**\n * To calculate the stacked values.\n *\n * @returns {void}\n * @private\n */\n Series.prototype.calculateStackedValue = function (isStacking100, chart) {\n for (var _i = 0, _a = chart.columns; _i < _a.length; _i++) {\n var columnItem = _a[_i];\n for (var _b = 0, _c = chart.rows; _b < _c.length; _b++) {\n var item = _c[_b];\n this.calculateStackingValues(this.findSeriesCollection(columnItem, item, true), isStacking100);\n }\n }\n };\n Series.prototype.calculateStackingValues = function (seriesCollection, isStacking100) {\n var startValues;\n var endValues;\n var yValues = [];\n var lastPositive = [];\n var lastNegative = [];\n var stackingGroup;\n var lastValue;\n var value;\n var frequencies = [];\n if (isStacking100) {\n frequencies = this.findFrequencies(seriesCollection);\n }\n var groupingValues = [];\n var visiblePoints = [];\n for (var i = 0; i < seriesCollection.length; i++) {\n var series = seriesCollection[i];\n if (!groupingValues[series.stackingGroup]) {\n groupingValues[series.stackingGroup] = [];\n groupingValues[series.stackingGroup].push(series);\n }\n else if (groupingValues[series.stackingGroup] !== undefined) {\n groupingValues[series.stackingGroup].push(series);\n }\n }\n var keys = Object.keys(groupingValues);\n for (var k = 0; k < keys.length; k++) {\n var stackingSeies = [];\n var stackedValues = [];\n var seriesCollection_2 = groupingValues[keys[k]];\n for (var _i = 0, seriesCollection_1 = seriesCollection_2; _i < seriesCollection_1.length; _i++) {\n var series = seriesCollection_1[_i];\n if (series.type.indexOf('Stacking') !== -1 || (series.drawType.indexOf('Stacking') !== -1 &&\n (series.chart.chartAreaType === 'PolarRadar'))) {\n stackingGroup = (series.type.indexOf('StackingArea') !== -1) ? 'StackingArea100' :\n (series.type.indexOf('StackingLine') !== -1) ? 'StackingLine100' : series.stackingGroup;\n if (!lastPositive[stackingGroup]) {\n lastPositive[stackingGroup] = [];\n lastNegative[stackingGroup] = [];\n }\n yValues = series.yData;\n startValues = [];\n endValues = [];\n stackingSeies.push(series);\n visiblePoints = getVisiblePoints(series);\n for (var j = 0, pointsLength = visiblePoints.length; j < pointsLength; j++) {\n lastValue = 0;\n value = +yValues[j]; // Fix for chart not rendering while y value is given as string issue\n if (lastPositive[stackingGroup][visiblePoints[j].xValue] === undefined) {\n lastPositive[stackingGroup][visiblePoints[j].xValue] = 0;\n }\n if (lastNegative[stackingGroup][visiblePoints[j].xValue] === undefined) {\n lastNegative[stackingGroup][visiblePoints[j].xValue] = 0;\n }\n if (isStacking100) {\n value = value / frequencies[stackingGroup][visiblePoints[j].xValue] * 100;\n value = !isNaN(value) ? value : 0;\n visiblePoints[j].percentage = +(value.toFixed(2));\n }\n else {\n stackedValues[j] = stackedValues[j] ? stackedValues[j] + Math.abs(value) : Math.abs(value);\n }\n if (value >= 0) {\n lastValue = lastPositive[stackingGroup][visiblePoints[j].xValue];\n lastPositive[stackingGroup][visiblePoints[j].xValue] += value;\n }\n else {\n lastValue = lastNegative[stackingGroup][visiblePoints[j].xValue];\n lastNegative[stackingGroup][visiblePoints[j].xValue] += value;\n }\n startValues.push(lastValue);\n endValues.push(value + lastValue);\n if (isStacking100 && (endValues[j] > 100)) {\n endValues[j] = 100;\n }\n }\n series.stackedValues = new StackValues(startValues, endValues);\n var isLogAxis = series.yAxis.valueType === 'Logarithmic';\n var isColumnBarType = (series.type.indexOf('Column') !== -1 || series.type.indexOf('Bar') !== -1);\n series.yMin = isLogAxis && isColumnBarType && series.yMin < 1 ? series.yMin : (series.yAxis.startFromZero && series.yAxis.rangePadding === 'Auto' && series.yMin >= 0) ? 0 : parseFloat((Math.min.apply(0, isStacking100 ? startValues : endValues)).toFixed(10));\n series.yMax = Math.max.apply(0, endValues);\n if (series.yMin > Math.min.apply(0, endValues)) {\n series.yMin = (isStacking100) ? -100 :\n isLogAxis && isColumnBarType && series.yMin < 1 ? series.yMin : Math.min.apply(0, endValues);\n }\n if (series.yMax < Math.max.apply(0, startValues)) {\n series.yMax = 0;\n }\n }\n }\n this.findPercentageOfStacking(stackingSeies, stackedValues, isStacking100);\n }\n };\n Series.prototype.findPercentageOfStacking = function (stackingSeies, values, isStacking100) {\n for (var _i = 0, stackingSeies_1 = stackingSeies; _i < stackingSeies_1.length; _i++) {\n var item = stackingSeies_1[_i];\n if (isStacking100) {\n return null;\n }\n for (var _a = 0, _b = getVisiblePoints(item); _a < _b.length; _a++) {\n var point = _b[_a];\n point.percentage = Math.abs(+(point.y / values[point.index] * 100).toFixed(2));\n }\n }\n };\n Series.prototype.findFrequencies = function (seriesCollection) {\n var frequencies = [];\n var stackingGroup;\n var visiblePoints = [];\n for (var _i = 0, seriesCollection_3 = seriesCollection; _i < seriesCollection_3.length; _i++) {\n var series = seriesCollection_3[_i];\n series.yAxis.isStack100 = series.type.indexOf('100') !== -1 ? true : false;\n visiblePoints = getVisiblePoints(series);\n if (series.type.indexOf('Stacking') !== -1) {\n stackingGroup = (series.type.indexOf('StackingArea') !== -1) ? 'StackingArea100' :\n (series.type.indexOf('StackingLine') !== -1) ? 'StackingLine100' : series.stackingGroup;\n if (!frequencies[stackingGroup]) {\n frequencies[stackingGroup] = [];\n }\n for (var j = 0, pointsLength = visiblePoints.length; j < pointsLength; j++) {\n if (frequencies[stackingGroup][visiblePoints[j].xValue] === undefined) {\n frequencies[stackingGroup][visiblePoints[j].xValue] = 0;\n }\n if (series.yData[j] > 0) {\n frequencies[stackingGroup][visiblePoints[j].xValue] += series.yData[j];\n }\n else {\n frequencies[stackingGroup][visiblePoints[j].xValue] -= series.yData[j];\n }\n }\n }\n }\n return frequencies;\n };\n /* private dataManagerFailure(e: { result: Object[] }): void {\n this.currentViewData = [];\n this.refreshChart();\n }*/\n /** @private */\n Series.prototype.renderSeries = function (chart) {\n if (this.chart.stockChart && this.xAxis.valueType === 'DateTimeCategory') {\n for (var i = 0; i < this.points.length; i++) {\n var index = this.xAxis.labels.indexOf(Date.parse(this.points[i].x.toString()).toString());\n this.points[i].xValue = index;\n if (chart.series.length > 1) {\n this.xData[i] = index;\n this.xMin = (this.xMin > index) ? index : this.xMin;\n this.xMax = (this.xMax < index) ? index : this.xMax;\n }\n }\n if (this instanceof Series && this.type.indexOf('Spline') > -1) {\n var isArea = this.type.indexOf('Area') > -1;\n var isRange = this.type.indexOf('Range') > -1;\n this.chart['spline' + (isArea ? isRange ? 'RangeArea' : 'Area' : '') + 'SeriesModule'].findSplinePoint(this);\n }\n }\n var seriesType = firstToLowerCase(this.type);\n seriesType = seriesType.replace('100', '');\n if (chart[seriesType + 'SeriesModule']) {\n if (this.category !== 'Indicator' && this.category !== 'TrendLine') {\n this.createSeriesElements(chart);\n }\n this.visiblePoints = getVisiblePoints(this);\n chart[seriesType + 'SeriesModule'].render(this, this.xAxis, this.yAxis, chart.requireInvertedAxis);\n if (this.category !== 'Indicator') {\n if (this.errorBar.visible) {\n this.chart.errorBarModule.render(this);\n }\n if (this.marker.dataLabel.visible) {\n chart.dataLabelModule.render(this, this.chart, this.marker.dataLabel);\n }\n this.appendSeriesElement(chart.seriesElements, chart);\n }\n if (!this.chart.enableCanvas) {\n this.performAnimation(chart, seriesType, this.errorBar, this.marker, this.marker.dataLabel);\n }\n }\n };\n /**\n * To create seris element.\n *\n * @returns {void}\n * @private\n */\n Series.prototype.createSeriesElements = function (chart) {\n if (this.category !== 'Indicator') {\n var elementId = chart.element.id;\n // 8 for extend border value 5 for extend size value\n var explodeValue = this.marker.border.width + 8 + 5;\n var render = (this.type === 'Bubble') || (!this.marker.visible && chart.tooltip.shared && chart.enableCanvas) ?\n chart.svgRenderer : chart.renderer;\n var index = this.index === undefined ? this.category : this.index;\n var markerHeight = void 0;\n var markerWidth = void 0;\n var options = void 0;\n if (this.type === 'Scatter' || this.drawType === 'Scatter') {\n markerHeight = (this.marker.height + explodeValue) / 2;\n markerWidth = (this.marker.width + explodeValue) / 2;\n }\n else {\n markerHeight = 0;\n markerWidth = 0;\n }\n if (chart.chartAreaType === 'PolarRadar') {\n var markerMaxValue = (this.drawType === 'Scatter') ? Math.max(this.marker.width, this.marker.height) : 0;\n options = new CircleOption(elementId + '_ChartSeriesClipRect_' + index, 'transparent', { width: 1, color: 'Gray' }, 1, this.clipRect.width / 2 + this.clipRect.x, this.clipRect.height / 2 + this.clipRect.y, chart.radius + markerMaxValue);\n this.clipRectElement = appendClipElement(chart.redraw, options, render, 'drawCircularClipPath');\n }\n else {\n options = new RectOption(elementId + '_ChartSeriesClipRect_' + index, 'transparent', { width: 1, color: 'Gray' }, 1, {\n x: (this.xAxis.columnIndex === 0) ? -markerWidth : 0, y: (this.yAxis.rowIndex === chart.rows.length - 1) ? -markerHeight : 0,\n width: this.clipRect.width + (this.xAxis.columnIndex === chart.columns.length - 1 ? markerWidth * 2 : markerWidth),\n height: this.clipRect.height + (this.yAxis.rowIndex === 0 ? markerHeight * 2 : markerHeight)\n });\n this.clipRectElement = appendClipElement(chart.redraw, options, render);\n }\n var transform = chart.chartAreaType === 'Cartesian' ? 'translate(' + this.clipRect.x + ',' + (this.clipRect.y) + ')' : '';\n this.symbolElement = null;\n this.seriesElement = render.createGroup({\n 'id': elementId + 'SeriesGroup' + index,\n 'transform': transform,\n 'clip-path': 'url(#' + elementId + '_ChartSeriesClipRect_' + index + ')'\n });\n if (this.seriesElement) {\n this.seriesElement.setAttribute('role', 'region');\n this.seriesElement.setAttribute('aria-label', (this.name + ',' + this.type + ' series with ' + this.points.length + ' data points'));\n this.seriesElement.setAttribute('aria-hidden', 'false');\n }\n if (!this.chart.enableCanvas || this.type === 'Bubble') {\n this.seriesElement.setAttribute('tabindex', index === 0 ? '0' : !this.checkTabindex(chart.visibleSeries, index) ? '0' : '');\n this.seriesElement.setAttribute('style', 'outline: none');\n this.seriesElement.appendChild(this.clipRectElement);\n }\n }\n };\n Series.prototype.checkTabindex = function (visibleSeries, index) {\n for (var i = 0; i < index; i++) {\n if (visibleSeries[i].visible)\n return true;\n }\n return false;\n };\n /**\n * To append the series.\n *\n * @returns {void}\n * @private\n */\n Series.prototype.appendSeriesElement = function (element, chart) {\n var marker = this.marker;\n var dataLabel = marker.dataLabel;\n var redraw = chart.redraw;\n if (this.category !== 'TrendLine') {\n appendChildElement(chart.enableCanvas, chart.seriesElements, this.seriesElement, redraw);\n var errorBar = this.errorBar;\n if (errorBar.visible) {\n if (chart.chartAreaType === 'PolarRadar') {\n appendChildElement(chart.enableCanvas, chart.seriesElements, this.seriesElement, redraw);\n }\n else {\n appendChildElement(chart.enableCanvas, chart.seriesElements, this.errorBarElement, redraw);\n }\n }\n }\n if (marker.visible && (chart.chartAreaType === 'Cartesian' ||\n ((this.drawType !== 'Scatter') && chart.chartAreaType === 'PolarRadar')) && this.type !== 'Scatter' &&\n this.type !== 'Bubble' && this.type !== 'Candle' && this.type !== 'Hilo' && this.type !== 'HiloOpenClose' && this.symbolElement) {\n appendChildElement(chart.enableCanvas, chart.seriesElements, this.symbolElement, redraw);\n }\n if (dataLabel.visible && this.textElement) {\n appendChildElement(chart.enableCanvas, chart.dataLabelElements, this.shapeElement, redraw);\n appendChildElement(chart.enableCanvas, chart.dataLabelElements, this.textElement, redraw);\n }\n if (!chart.enableCanvas && chart.dataLabelElements.hasChildNodes()) {\n chart.seriesElements.appendChild(chart.dataLabelElements);\n }\n };\n /**\n * To perform animation for chart series.\n *\n * @returns {void}\n * @private\n */\n Series.prototype.performAnimation = function (chart, type, errorBar, marker, dataLabel) {\n if (((this.animation.enable && animationMode != 'Disable') || animationMode === 'Enable') && chart.animateSeries && (!chart.stockChart || !chart.stockChart.isStockChartRendered)) {\n chart[type + 'SeriesModule'].doAnimation(this);\n if (errorBar.visible) {\n chart.errorBarModule.doErrorBarAnimation(this);\n }\n if (marker.visible) {\n chart.markerRender.doMarkerAnimation(this);\n }\n //to datalabel animation disabled for edge and IE\n if (dataLabel.visible && Browser.info.name !== 'edge' && !Browser.isIE) {\n chart.dataLabelModule.doDataLabelAnimation(this);\n }\n }\n };\n /**\n * To set border color for empty point\n *\n * @private\n */\n Series.prototype.setPointColor = function (point, color) {\n color = point.interior || color;\n return point.isEmpty ? (this.emptyPointSettings.fill || color) : color;\n };\n /**\n * To set border color for empty point\n *\n * @private\n */\n Series.prototype.setBorderColor = function (point, border) {\n border.width = point.isEmpty ? (this.emptyPointSettings.border.width || border.width) : border.width;\n border.color = point.isEmpty ? (this.emptyPointSettings.border.color || border.color) : border.color;\n return border;\n };\n __decorate([\n Property('')\n ], Series.prototype, \"name\", void 0);\n __decorate([\n Property('')\n ], Series.prototype, \"yName\", void 0);\n __decorate([\n Property('Line')\n ], Series.prototype, \"drawType\", void 0);\n __decorate([\n Property(true)\n ], Series.prototype, \"isClosed\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"bearFillColor\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"bullFillColor\", void 0);\n __decorate([\n Property(false)\n ], Series.prototype, \"enableSolidCandles\", void 0);\n __decorate([\n Property('')\n ], Series.prototype, \"size\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"binInterval\", void 0);\n __decorate([\n Property(false)\n ], Series.prototype, \"showNormalDistribution\", void 0);\n __decorate([\n Property('')\n ], Series.prototype, \"stackingGroup\", void 0);\n __decorate([\n Complex({ color: null, width: 0 }, Border)\n ], Series.prototype, \"border\", void 0);\n __decorate([\n Property(1)\n ], Series.prototype, \"opacity\", void 0);\n __decorate([\n Property(0)\n ], Series.prototype, \"zOrder\", void 0);\n __decorate([\n Property('')\n ], Series.prototype, \"groupName\", void 0);\n __decorate([\n Property('Line')\n ], Series.prototype, \"type\", void 0);\n __decorate([\n Complex(null, ErrorBarSettings)\n ], Series.prototype, \"errorBar\", void 0);\n __decorate([\n Complex(null, MarkerSettings)\n ], Series.prototype, \"marker\", void 0);\n __decorate([\n Complex(null, ParetoOptions)\n ], Series.prototype, \"paretoOptions\", void 0);\n __decorate([\n Complex({}, DragSettings)\n ], Series.prototype, \"dragSettings\", void 0);\n __decorate([\n Collection([], Trendline)\n ], Series.prototype, \"trendlines\", void 0);\n __decorate([\n Property(true)\n ], Series.prototype, \"enableTooltip\", void 0);\n __decorate([\n Property('')\n ], Series.prototype, \"tooltipFormat\", void 0);\n __decorate([\n Property('')\n ], Series.prototype, \"tooltipMappingName\", void 0);\n __decorate([\n Property('SeriesType')\n ], Series.prototype, \"legendShape\", void 0);\n __decorate([\n Property('')\n ], Series.prototype, \"legendImageUrl\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"selectionStyle\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"unSelectedStyle\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"nonHighlightStyle\", void 0);\n __decorate([\n Property(1)\n ], Series.prototype, \"minRadius\", void 0);\n __decorate([\n Property(3)\n ], Series.prototype, \"maxRadius\", void 0);\n __decorate([\n Property('Natural')\n ], Series.prototype, \"splineType\", void 0);\n __decorate([\n Property(0.5)\n ], Series.prototype, \"cardinalSplineTension\", void 0);\n __decorate([\n Complex(null, EmptyPointSettings)\n ], Series.prototype, \"emptyPointSettings\", void 0);\n __decorate([\n Property(true)\n ], Series.prototype, \"showMean\", void 0);\n __decorate([\n Property('Normal')\n ], Series.prototype, \"boxPlotMode\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"columnWidth\", void 0);\n __decorate([\n Property(null)\n ], Series.prototype, \"columnWidthInPixel\", void 0);\n __decorate([\n Property('Rectangle')\n ], Series.prototype, \"columnFacet\", void 0);\n __decorate([\n Property(0)\n ], Series.prototype, \"columnSpacing\", void 0);\n __decorate([\n Property('#C64E4A')\n ], Series.prototype, \"negativeFillColor\", void 0);\n __decorate([\n Property('#4E81BC')\n ], Series.prototype, \"summaryFillColor\", void 0);\n __decorate([\n Property()\n ], Series.prototype, \"intermediateSumIndexes\", void 0);\n __decorate([\n Property()\n ], Series.prototype, \"sumIndexes\", void 0);\n __decorate([\n Property('Left')\n ], Series.prototype, \"step\", void 0);\n __decorate([\n Complex({ color: 'black', width: 2 }, Connector)\n ], Series.prototype, \"connector\", void 0);\n __decorate([\n Complex(null, CornerRadius)\n ], Series.prototype, \"cornerRadius\", void 0);\n return Series;\n}(SeriesBase));\nexport { Series };\n","//! moment.js locale configuration\n//! locale : Arabic (Morocco) [ar-ma]\n//! author : ElFadili Yassine : https://github.com/ElFadiliY\n//! author : Abdel Said : https://github.com/abdelsaid\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var arMa = moment.defineLocale('ar-ma', {\n months: 'يناير_Ùبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split(\n '_'\n ),\n monthsShort:\n 'يناير_Ùبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split(\n '_'\n ),\n weekdays: 'الأØد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),\n weekdaysShort: 'اØد_اثنين_ثلاثاء_اربعاء_خميس_جمعة_سبت'.split('_'),\n weekdaysMin: 'Ø_Ù†_Ø«_ر_Ø®_ج_س'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[اليوم على الساعة] LT',\n nextDay: '[غدا على الساعة] LT',\n nextWeek: 'dddd [على الساعة] LT',\n lastDay: '[أمس على الساعة] LT',\n lastWeek: 'dddd [على الساعة] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'ÙÙŠ %s',\n past: 'منذ %s',\n s: 'ثوان',\n ss: '%d ثانية',\n m: 'دقيقة',\n mm: '%d دقائق',\n h: 'ساعة',\n hh: '%d ساعات',\n d: 'يوم',\n dd: '%d أيام',\n M: 'شهر',\n MM: '%d أشهر',\n y: 'سنة',\n yy: '%d سنوات',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return arMa;\n\n})));\n","//! moment.js locale configuration\n//! locale : Konkani Latin script [gom-latn]\n//! author : The Discoverer : https://github.com/WikiDiscoverer\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n s: ['thoddea sekondamni', 'thodde sekond'],\n ss: [number + ' sekondamni', number + ' sekond'],\n m: ['eka mintan', 'ek minut'],\n mm: [number + ' mintamni', number + ' mintam'],\n h: ['eka voran', 'ek vor'],\n hh: [number + ' voramni', number + ' voram'],\n d: ['eka disan', 'ek dis'],\n dd: [number + ' disamni', number + ' dis'],\n M: ['eka mhoinean', 'ek mhoino'],\n MM: [number + ' mhoineamni', number + ' mhoine'],\n y: ['eka vorsan', 'ek voros'],\n yy: [number + ' vorsamni', number + ' vorsam'],\n };\n return isFuture ? format[key][0] : format[key][1];\n }\n\n var gomLatn = moment.defineLocale('gom-latn', {\n months: {\n standalone:\n 'Janer_Febrer_Mars_Abril_Mai_Jun_Julai_Agost_Setembr_Otubr_Novembr_Dezembr'.split(\n '_'\n ),\n format: 'Janerachea_Febrerachea_Marsachea_Abrilachea_Maiachea_Junachea_Julaiachea_Agostachea_Setembrachea_Otubrachea_Novembrachea_Dezembrachea'.split(\n '_'\n ),\n isFormat: /MMMM(\\s)+D[oD]?/,\n },\n monthsShort:\n 'Jan._Feb._Mars_Abr._Mai_Jun_Jul._Ago._Set._Otu._Nov._Dez.'.split('_'),\n monthsParseExact: true,\n weekdays: \"Aitar_Somar_Mongllar_Budhvar_Birestar_Sukrar_Son'var\".split('_'),\n weekdaysShort: 'Ait._Som._Mon._Bud._Bre._Suk._Son.'.split('_'),\n weekdaysMin: 'Ai_Sm_Mo_Bu_Br_Su_Sn'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'A h:mm [vazta]',\n LTS: 'A h:mm:ss [vazta]',\n L: 'DD-MM-YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY A h:mm [vazta]',\n LLLL: 'dddd, MMMM Do, YYYY, A h:mm [vazta]',\n llll: 'ddd, D MMM YYYY, A h:mm [vazta]',\n },\n calendar: {\n sameDay: '[Aiz] LT',\n nextDay: '[Faleam] LT',\n nextWeek: '[Fuddlo] dddd[,] LT',\n lastDay: '[Kal] LT',\n lastWeek: '[Fattlo] dddd[,] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s',\n past: '%s adim',\n s: processRelativeTime,\n ss: processRelativeTime,\n m: processRelativeTime,\n mm: processRelativeTime,\n h: processRelativeTime,\n hh: processRelativeTime,\n d: processRelativeTime,\n dd: processRelativeTime,\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(er)/,\n ordinal: function (number, period) {\n switch (period) {\n // the ordinal 'er' only applies to day of the month\n case 'D':\n return number + 'er';\n default:\n case 'M':\n case 'Q':\n case 'DDD':\n case 'd':\n case 'w':\n case 'W':\n return number;\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week\n doy: 3, // The week that contains Jan 4th is the first week of the year (7 + 0 - 4)\n },\n meridiemParse: /rati|sokallim|donparam|sanje/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'rati') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'sokallim') {\n return hour;\n } else if (meridiem === 'donparam') {\n return hour > 12 ? hour : hour + 12;\n } else if (meridiem === 'sanje') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'rati';\n } else if (hour < 12) {\n return 'sokallim';\n } else if (hour < 16) {\n return 'donparam';\n } else if (hour < 20) {\n return 'sanje';\n } else {\n return 'rati';\n }\n },\n });\n\n return gomLatn;\n\n})));\n","//! moment.js locale configuration\n//! locale : French (Switzerland) [fr-ch]\n//! author : Gaspard Bucher : https://github.com/gaspard\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var frCh = moment.defineLocale('fr-ch', {\n months: 'janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre'.split(\n '_'\n ),\n monthsShort:\n 'janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),\n weekdaysShort: 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),\n weekdaysMin: 'di_lu_ma_me_je_ve_sa'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Aujourd’hui à ] LT',\n nextDay: '[Demain à ] LT',\n nextWeek: 'dddd [à ] LT',\n lastDay: '[Hier à ] LT',\n lastWeek: 'dddd [dernier à ] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'dans %s',\n past: 'il y a %s',\n s: 'quelques secondes',\n ss: '%d secondes',\n m: 'une minute',\n mm: '%d minutes',\n h: 'une heure',\n hh: '%d heures',\n d: 'un jour',\n dd: '%d jours',\n M: 'un mois',\n MM: '%d mois',\n y: 'un an',\n yy: '%d ans',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(er|e)/,\n ordinal: function (number, period) {\n switch (period) {\n // Words with masculine grammatical gender: mois, trimestre, jour\n default:\n case 'M':\n case 'Q':\n case 'D':\n case 'DDD':\n case 'd':\n return number + (number === 1 ? 'er' : 'e');\n\n // Words with feminine grammatical gender: semaine\n case 'w':\n case 'W':\n return number + (number === 1 ? 're' : 'e');\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return frCh;\n\n})));\n","//! moment.js locale configuration\n//! locale : English (Australia) [en-au]\n//! author : Jared Morse : https://github.com/jarcoal\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enAu = moment.defineLocale('en-au', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY h:mm A',\n LLLL: 'dddd, D MMMM YYYY h:mm A',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return enAu;\n\n})));\n","//! moment.js locale configuration\n//! locale : Turkish [tr]\n//! authors : Erhan Gundogan : https://github.com/erhangundogan,\n//! Burak YiÄŸit Kaya: https://github.com/BYK\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var suffixes = {\n 1: \"'inci\",\n 5: \"'inci\",\n 8: \"'inci\",\n 70: \"'inci\",\n 80: \"'inci\",\n 2: \"'nci\",\n 7: \"'nci\",\n 20: \"'nci\",\n 50: \"'nci\",\n 3: \"'üncü\",\n 4: \"'üncü\",\n 100: \"'üncü\",\n 6: \"'ncı\",\n 9: \"'uncu\",\n 10: \"'uncu\",\n 30: \"'uncu\",\n 60: \"'ıncı\",\n 90: \"'ıncı\",\n };\n\n var tr = moment.defineLocale('tr', {\n months: 'Ocak_Åžubat_Mart_Nisan_Mayıs_Haziran_Temmuz_AÄŸustos_Eylül_Ekim_Kasım_Aralık'.split(\n '_'\n ),\n monthsShort: 'Oca_Åžub_Mar_Nis_May_Haz_Tem_AÄŸu_Eyl_Eki_Kas_Ara'.split('_'),\n weekdays: 'Pazar_Pazartesi_Salı_ÇarÅŸamba_PerÅŸembe_Cuma_Cumartesi'.split(\n '_'\n ),\n weekdaysShort: 'Paz_Pzt_Sal_Çar_Per_Cum_Cmt'.split('_'),\n weekdaysMin: 'Pz_Pt_Sa_Ça_Pe_Cu_Ct'.split('_'),\n meridiem: function (hours, minutes, isLower) {\n if (hours < 12) {\n return isLower ? 'öö' : 'ÖÖ';\n } else {\n return isLower ? 'ös' : 'ÖS';\n }\n },\n meridiemParse: /öö|ÖÖ|ös|ÖS/,\n isPM: function (input) {\n return input === 'ös' || input === 'ÖS';\n },\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[bugün saat] LT',\n nextDay: '[yarın saat] LT',\n nextWeek: '[gelecek] dddd [saat] LT',\n lastDay: '[dün] LT',\n lastWeek: '[geçen] dddd [saat] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s sonra',\n past: '%s önce',\n s: 'birkaç saniye',\n ss: '%d saniye',\n m: 'bir dakika',\n mm: '%d dakika',\n h: 'bir saat',\n hh: '%d saat',\n d: 'bir gün',\n dd: '%d gün',\n w: 'bir hafta',\n ww: '%d hafta',\n M: 'bir ay',\n MM: '%d ay',\n y: 'bir yıl',\n yy: '%d yıl',\n },\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'Do':\n case 'DD':\n return number;\n default:\n if (number === 0) {\n // special case for zero\n return number + \"'ıncı\";\n }\n var a = number % 10,\n b = (number % 100) - a,\n c = number >= 100 ? 100 : null;\n return number + (suffixes[a] || suffixes[b] || suffixes[c]);\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return tr;\n\n})));\n","//! moment.js locale configuration\n//! locale : Danish [da]\n//! author : Ulrik Nielsen : https://github.com/mrbase\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var da = moment.defineLocale('da', {\n months: 'januar_februar_marts_april_maj_juni_juli_august_september_oktober_november_december'.split(\n '_'\n ),\n monthsShort: 'jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec'.split('_'),\n weekdays: 'søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag'.split('_'),\n weekdaysShort: 'søn_man_tir_ons_tor_fre_lør'.split('_'),\n weekdaysMin: 'sø_ma_ti_on_to_fr_lø'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY HH:mm',\n LLLL: 'dddd [d.] D. MMMM YYYY [kl.] HH:mm',\n },\n calendar: {\n sameDay: '[i dag kl.] LT',\n nextDay: '[i morgen kl.] LT',\n nextWeek: 'pÃ¥ dddd [kl.] LT',\n lastDay: '[i gÃ¥r kl.] LT',\n lastWeek: '[i] dddd[s kl.] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'om %s',\n past: '%s siden',\n s: 'fÃ¥ sekunder',\n ss: '%d sekunder',\n m: 'et minut',\n mm: '%d minutter',\n h: 'en time',\n hh: '%d timer',\n d: 'en dag',\n dd: '%d dage',\n M: 'en mÃ¥ned',\n MM: '%d mÃ¥neder',\n y: 'et Ã¥r',\n yy: '%d Ã¥r',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return da;\n\n})));\n","//! moment.js locale configuration\n//! locale : Tagalog (Philippines) [tl-ph]\n//! author : Dan Hagman : https://github.com/hagmandan\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var tlPh = moment.defineLocale('tl-ph', {\n months: 'Enero_Pebrero_Marso_Abril_Mayo_Hunyo_Hulyo_Agosto_Setyembre_Oktubre_Nobyembre_Disyembre'.split(\n '_'\n ),\n monthsShort: 'Ene_Peb_Mar_Abr_May_Hun_Hul_Ago_Set_Okt_Nob_Dis'.split('_'),\n weekdays: 'Linggo_Lunes_Martes_Miyerkules_Huwebes_Biyernes_Sabado'.split(\n '_'\n ),\n weekdaysShort: 'Lin_Lun_Mar_Miy_Huw_Biy_Sab'.split('_'),\n weekdaysMin: 'Li_Lu_Ma_Mi_Hu_Bi_Sab'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'MM/D/YYYY',\n LL: 'MMMM D, YYYY',\n LLL: 'MMMM D, YYYY HH:mm',\n LLLL: 'dddd, MMMM DD, YYYY HH:mm',\n },\n calendar: {\n sameDay: 'LT [ngayong araw]',\n nextDay: '[Bukas ng] LT',\n nextWeek: 'LT [sa susunod na] dddd',\n lastDay: 'LT [kahapon]',\n lastWeek: 'LT [noong nakaraang] dddd',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'sa loob ng %s',\n past: '%s ang nakalipas',\n s: 'ilang segundo',\n ss: '%d segundo',\n m: 'isang minuto',\n mm: '%d minuto',\n h: 'isang oras',\n hh: '%d oras',\n d: 'isang araw',\n dd: '%d araw',\n M: 'isang buwan',\n MM: '%d buwan',\n y: 'isang taon',\n yy: '%d taon',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}/,\n ordinal: function (number) {\n return number;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return tlPh;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { ChildProperty, Property, Complex, Collection } from '@syncfusion/ej2-base';\nimport { Font, Border } from '../../common/model/base';\n/**\n * Configures the Annotation for chart.\n */\nvar ChartAnnotationSettings = /** @class */ (function (_super) {\n __extends(ChartAnnotationSettings, _super);\n function ChartAnnotationSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('0')\n ], ChartAnnotationSettings.prototype, \"x\", void 0);\n __decorate([\n Property('0')\n ], ChartAnnotationSettings.prototype, \"y\", void 0);\n __decorate([\n Property(null)\n ], ChartAnnotationSettings.prototype, \"content\", void 0);\n __decorate([\n Property('Center')\n ], ChartAnnotationSettings.prototype, \"horizontalAlignment\", void 0);\n __decorate([\n Property('Pixel')\n ], ChartAnnotationSettings.prototype, \"coordinateUnits\", void 0);\n __decorate([\n Property('Chart')\n ], ChartAnnotationSettings.prototype, \"region\", void 0);\n __decorate([\n Property('Middle')\n ], ChartAnnotationSettings.prototype, \"verticalAlignment\", void 0);\n __decorate([\n Property(null)\n ], ChartAnnotationSettings.prototype, \"xAxisName\", void 0);\n __decorate([\n Property(null)\n ], ChartAnnotationSettings.prototype, \"yAxisName\", void 0);\n __decorate([\n Property(null)\n ], ChartAnnotationSettings.prototype, \"description\", void 0);\n return ChartAnnotationSettings;\n}(ChildProperty));\nexport { ChartAnnotationSettings };\n/**\n * label border properties.\n */\nvar LabelBorder = /** @class */ (function (_super) {\n __extends(LabelBorder, _super);\n function LabelBorder() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('')\n ], LabelBorder.prototype, \"color\", void 0);\n __decorate([\n Property(1)\n ], LabelBorder.prototype, \"width\", void 0);\n __decorate([\n Property('Rectangle')\n ], LabelBorder.prototype, \"type\", void 0);\n return LabelBorder;\n}(ChildProperty));\nexport { LabelBorder };\n/**\n * categories for multi level labels\n */\nvar MultiLevelCategories = /** @class */ (function (_super) {\n __extends(MultiLevelCategories, _super);\n function MultiLevelCategories() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], MultiLevelCategories.prototype, \"start\", void 0);\n __decorate([\n Property(null)\n ], MultiLevelCategories.prototype, \"end\", void 0);\n __decorate([\n Property('')\n ], MultiLevelCategories.prototype, \"text\", void 0);\n __decorate([\n Property(null)\n ], MultiLevelCategories.prototype, \"maximumTextWidth\", void 0);\n __decorate([\n Property(null)\n ], MultiLevelCategories.prototype, \"customAttributes\", void 0);\n __decorate([\n Property('')\n ], MultiLevelCategories.prototype, \"type\", void 0);\n return MultiLevelCategories;\n}(ChildProperty));\nexport { MultiLevelCategories };\n/**\n * Strip line properties\n */\nvar StripLineSettings = /** @class */ (function (_super) {\n __extends(StripLineSettings, _super);\n function StripLineSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(true)\n ], StripLineSettings.prototype, \"visible\", void 0);\n __decorate([\n Property(false)\n ], StripLineSettings.prototype, \"startFromAxis\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"start\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"end\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"size\", void 0);\n __decorate([\n Property('#808080')\n ], StripLineSettings.prototype, \"color\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"dashArray\", void 0);\n __decorate([\n Property('Auto')\n ], StripLineSettings.prototype, \"sizeType\", void 0);\n __decorate([\n Property(false)\n ], StripLineSettings.prototype, \"isRepeat\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"repeatEvery\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"repeatUntil\", void 0);\n __decorate([\n Property(false)\n ], StripLineSettings.prototype, \"isSegmented\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"segmentStart\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"segmentEnd\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"segmentAxisName\", void 0);\n __decorate([\n Complex({ color: 'transparent', width: 1 }, Border)\n ], StripLineSettings.prototype, \"border\", void 0);\n __decorate([\n Property('')\n ], StripLineSettings.prototype, \"text\", void 0);\n __decorate([\n Property(null)\n ], StripLineSettings.prototype, \"rotation\", void 0);\n __decorate([\n Property('Middle')\n ], StripLineSettings.prototype, \"horizontalAlignment\", void 0);\n __decorate([\n Property('Middle')\n ], StripLineSettings.prototype, \"verticalAlignment\", void 0);\n __decorate([\n Complex({ size: '12px', color: null, fontStyle: 'Normal', fontWeight: '400', fontFamily: null }, Font)\n ], StripLineSettings.prototype, \"textStyle\", void 0);\n __decorate([\n Property('Behind')\n ], StripLineSettings.prototype, \"zIndex\", void 0);\n __decorate([\n Property(1)\n ], StripLineSettings.prototype, \"opacity\", void 0);\n __decorate([\n Property('')\n ], StripLineSettings.prototype, \"imageUrl\", void 0);\n return StripLineSettings;\n}(ChildProperty));\nexport { StripLineSettings };\n/**\n * MultiLevelLabels properties\n */\nvar MultiLevelLabels = /** @class */ (function (_super) {\n __extends(MultiLevelLabels, _super);\n function MultiLevelLabels() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Center')\n ], MultiLevelLabels.prototype, \"alignment\", void 0);\n __decorate([\n Property('Wrap')\n ], MultiLevelLabels.prototype, \"overflow\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"12px\", fontStyle: 'Normal', fontWeight: '400', color: null }, Font)\n ], MultiLevelLabels.prototype, \"textStyle\", void 0);\n __decorate([\n Complex({ color: null, width: 1, type: 'Rectangle' }, LabelBorder)\n ], MultiLevelLabels.prototype, \"border\", void 0);\n __decorate([\n Collection([], MultiLevelCategories)\n ], MultiLevelLabels.prototype, \"categories\", void 0);\n return MultiLevelLabels;\n}(ChildProperty));\nexport { MultiLevelLabels };\n/**\n * Specifies range for scrollbarSettings property\n *\n * @public\n */\nvar ScrollbarSettingsRange = /** @class */ (function (_super) {\n __extends(ScrollbarSettingsRange, _super);\n function ScrollbarSettingsRange() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], ScrollbarSettingsRange.prototype, \"minimum\", void 0);\n __decorate([\n Property(null)\n ], ScrollbarSettingsRange.prototype, \"maximum\", void 0);\n return ScrollbarSettingsRange;\n}(ChildProperty));\nexport { ScrollbarSettingsRange };\n/**\n * Scrollbar Settings Properties for Lazy Loading\n */\nvar ScrollbarSettings = /** @class */ (function (_super) {\n __extends(ScrollbarSettings, _super);\n function ScrollbarSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], ScrollbarSettings.prototype, \"enable\", void 0);\n __decorate([\n Property(null)\n ], ScrollbarSettings.prototype, \"pointsLength\", void 0);\n __decorate([\n Complex({}, ScrollbarSettingsRange)\n ], ScrollbarSettings.prototype, \"range\", void 0);\n __decorate([\n Property(null)\n ], ScrollbarSettings.prototype, \"trackColor\", void 0);\n __decorate([\n Property(0)\n ], ScrollbarSettings.prototype, \"scrollbarRadius\", void 0);\n __decorate([\n Property(null)\n ], ScrollbarSettings.prototype, \"scrollbarColor\", void 0);\n __decorate([\n Property(0)\n ], ScrollbarSettings.prototype, \"trackRadius\", void 0);\n __decorate([\n Property(null)\n ], ScrollbarSettings.prototype, \"gripColor\", void 0);\n __decorate([\n Property(16)\n ], ScrollbarSettings.prototype, \"height\", void 0);\n __decorate([\n Property(true)\n ], ScrollbarSettings.prototype, \"enableZoom\", void 0);\n return ScrollbarSettings;\n}(ChildProperty));\nexport { ScrollbarSettings };\n","//! moment.js locale configuration\n//! locale : Basque [eu]\n//! author : Eneko Illarramendi : https://github.com/eillarra\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var eu = moment.defineLocale('eu', {\n months: 'urtarrila_otsaila_martxoa_apirila_maiatza_ekaina_uztaila_abuztua_iraila_urria_azaroa_abendua'.split(\n '_'\n ),\n monthsShort:\n 'urt._ots._mar._api._mai._eka._uzt._abu._ira._urr._aza._abe.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays:\n 'igandea_astelehena_asteartea_asteazkena_osteguna_ostirala_larunbata'.split(\n '_'\n ),\n weekdaysShort: 'ig._al._ar._az._og._ol._lr.'.split('_'),\n weekdaysMin: 'ig_al_ar_az_og_ol_lr'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY-MM-DD',\n LL: 'YYYY[ko] MMMM[ren] D[a]',\n LLL: 'YYYY[ko] MMMM[ren] D[a] HH:mm',\n LLLL: 'dddd, YYYY[ko] MMMM[ren] D[a] HH:mm',\n l: 'YYYY-M-D',\n ll: 'YYYY[ko] MMM D[a]',\n lll: 'YYYY[ko] MMM D[a] HH:mm',\n llll: 'ddd, YYYY[ko] MMM D[a] HH:mm',\n },\n calendar: {\n sameDay: '[gaur] LT[etan]',\n nextDay: '[bihar] LT[etan]',\n nextWeek: 'dddd LT[etan]',\n lastDay: '[atzo] LT[etan]',\n lastWeek: '[aurreko] dddd LT[etan]',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s barru',\n past: 'duela %s',\n s: 'segundo batzuk',\n ss: '%d segundo',\n m: 'minutu bat',\n mm: '%d minutu',\n h: 'ordu bat',\n hh: '%d ordu',\n d: 'egun bat',\n dd: '%d egun',\n M: 'hilabete bat',\n MM: '%d hilabete',\n y: 'urte bat',\n yy: '%d urte',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return eu;\n\n})));\n","//! moment.js locale configuration\n//! locale : Thai [th]\n//! author : Kridsada Thanabulpong : https://github.com/sirn\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var th = moment.defineLocale('th', {\n months: 'มà¸à¸£à¸²à¸„ม_à¸à¸¸à¸¡à¸ าพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_à¸à¸£à¸à¸Žà¸²à¸„ม_สิงหาคม_à¸à¸±à¸™à¸¢à¸²à¸¢à¸™_ตุลาคม_พฤศจิà¸à¸²à¸¢à¸™_ธันวาคม'.split(\n '_'\n ),\n monthsShort:\n 'ม.ค._à¸.พ._มี.ค._เม.ย._พ.ค._มิ.ย._à¸.ค._ส.ค._à¸.ย._ต.ค._พ.ย._ธ.ค.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'à¸à¸²à¸—ิตย์_จันทร์_à¸à¸±à¸‡à¸„าร_พุธ_พฤหัสบดี_ศุà¸à¸£à¹Œ_เสาร์'.split('_'),\n weekdaysShort: 'à¸à¸²à¸—ิตย์_จันทร์_à¸à¸±à¸‡à¸„าร_พุธ_พฤหัส_ศุà¸à¸£à¹Œ_เสาร์'.split('_'), // yes, three characters difference\n weekdaysMin: 'à¸à¸²._จ._à¸._พ._พฤ._ศ._ส.'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY เวลา H:mm',\n LLLL: 'วันddddที่ D MMMM YYYY เวลา H:mm',\n },\n meridiemParse: /à¸à¹ˆà¸à¸™à¹€à¸—ี่ยง|หลังเที่ยง/,\n isPM: function (input) {\n return input === 'หลังเที่ยง';\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'à¸à¹ˆà¸à¸™à¹€à¸—ี่ยง';\n } else {\n return 'หลังเที่ยง';\n }\n },\n calendar: {\n sameDay: '[วันนี้ เวลา] LT',\n nextDay: '[พรุ่งนี้ เวลา] LT',\n nextWeek: 'dddd[หน้า เวลา] LT',\n lastDay: '[เมื่à¸à¸§à¸²à¸™à¸™à¸µà¹‰ เวลา] LT',\n lastWeek: '[วัน]dddd[ที่à¹à¸¥à¹‰à¸§ เวลา] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'à¸à¸µà¸ %s',\n past: '%sที่à¹à¸¥à¹‰à¸§',\n s: 'ไม่à¸à¸µà¹ˆà¸§à¸´à¸™à¸²à¸—ี',\n ss: '%d วินาที',\n m: '1 นาที',\n mm: '%d นาที',\n h: '1 ชั่วโมง',\n hh: '%d ชั่วโมง',\n d: '1 วัน',\n dd: '%d วัน',\n w: '1 สัปดาห์',\n ww: '%d สัปดาห์',\n M: '1 เดืà¸à¸™',\n MM: '%d เดืà¸à¸™',\n y: '1 ปี',\n yy: '%d ปี',\n },\n });\n\n return th;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable jsdoc/require-param */\nimport { Double } from '../axis/double-axis';\n/**\n * Common axis classes\n *\n * @private\n */\nvar NiceInterval = /** @class */ (function (_super) {\n __extends(NiceInterval, _super);\n function NiceInterval() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * Method to calculate numeric datetime interval.\n */\n NiceInterval.prototype.calculateDateTimeNiceInterval = function (axis, size, start, end, isChart) {\n if (isChart === void 0) { isChart = true; }\n var oneDay = 24 * 60 * 60 * 1000;\n var startDate = new Date(start);\n var endDate = new Date(end);\n //var axisInterval ;\n var totalDays = (Math.abs((startDate.getTime() - endDate.getTime()) / (oneDay)));\n var interval;\n axis.actualIntervalType = axis.intervalType;\n var type = axis.intervalType;\n switch (type) {\n case 'Years':\n interval = this.calculateNumericNiceInterval(axis, totalDays / 365, size);\n break;\n case 'Quarter':\n interval = this.calculateNumericNiceInterval(axis, (totalDays / 365) * 4, size);\n break;\n case 'Months':\n interval = this.calculateNumericNiceInterval(axis, totalDays / 30, size);\n break;\n case 'Weeks':\n interval = this.calculateNumericNiceInterval(axis, totalDays / 7, size);\n break;\n case 'Days':\n interval = this.calculateNumericNiceInterval(axis, totalDays, size);\n break;\n case 'Hours':\n interval = this.calculateNumericNiceInterval(axis, totalDays * 24, size);\n break;\n case 'Minutes':\n interval = this.calculateNumericNiceInterval(axis, totalDays * 24 * 60, size);\n break;\n case 'Seconds':\n interval = this.calculateNumericNiceInterval(axis, totalDays * 24 * 60 * 60, size);\n break;\n case 'Auto':\n interval = this.calculateNumericNiceInterval(axis, totalDays / 365, size);\n if (interval >= 1) {\n axis.actualIntervalType = 'Years';\n return interval;\n }\n interval = this.calculateNumericNiceInterval(axis, totalDays / 30, size);\n if (interval >= 1) {\n axis.actualIntervalType = 'Months';\n return interval;\n }\n interval = this.calculateNumericNiceInterval(axis, totalDays / 7, size);\n if (interval >= 1 && !isChart) {\n axis.actualIntervalType = 'Weeks';\n return interval;\n }\n interval = this.calculateNumericNiceInterval(axis, totalDays, size);\n if (interval >= 1) {\n axis.actualIntervalType = 'Days';\n return interval;\n }\n interval = this.calculateNumericNiceInterval(axis, totalDays * 24, size);\n if (interval >= 1) {\n axis.actualIntervalType = 'Hours';\n return interval;\n }\n interval = this.calculateNumericNiceInterval(axis, totalDays * 24 * 60, size);\n if (interval >= 1) {\n axis.actualIntervalType = 'Minutes';\n return interval;\n }\n interval = this.calculateNumericNiceInterval(axis, totalDays * 24 * 60 * 60, size);\n axis.actualIntervalType = 'Seconds';\n return interval;\n }\n return interval;\n };\n /**\n * To get the skeleton for the DateTime axis.\n *\n * @returns {string} skeleton format\n * @private\n */\n NiceInterval.prototype.getSkeleton = function (axis, currentValue, previousValue, isBlazor) {\n var skeleton;\n var intervalType = axis.actualIntervalType;\n if (axis.skeleton) {\n return axis.skeleton;\n }\n if (intervalType === 'Years') {\n if (isBlazor) {\n skeleton = axis.isChart ? (axis.valueType === 'DateTime' ? 'y' : 'y') : 'y';\n }\n else {\n skeleton = axis.isChart ? ((axis.valueType === 'DateTime' && axis.isIntervalInDecimal) ? 'y' : 'yMMM') : 'y';\n }\n }\n else if (intervalType === 'Quarter') {\n skeleton = isBlazor ? 'y' : 'yMMM';\n }\n else if (intervalType === 'Months') {\n if (isBlazor) {\n skeleton = axis.isChart ? 'm' : 'm';\n }\n else {\n skeleton = axis.isChart ? 'MMMd' : 'MMM';\n }\n }\n else if (intervalType === 'Weeks') {\n skeleton = isBlazor ? 'm' : 'MEd';\n }\n else if (intervalType === 'Days') {\n if (isBlazor) {\n skeleton = 'd';\n }\n else {\n skeleton = axis.isChart ? (axis.valueType === 'DateTime' ? 'MMMd' : 'yMd') : 'MMMd';\n }\n }\n else if (intervalType === 'Hours') {\n if (isBlazor) {\n skeleton = 't';\n }\n else {\n skeleton = axis.isChart ? (axis.valueType === 'DateTime' ? 'Hm' : 'EHm') : 'h';\n }\n }\n else if (intervalType === 'Minutes') {\n if (isBlazor) {\n skeleton = 'T';\n }\n else {\n skeleton = axis.isChart ? 'Hms' : 'hm';\n }\n }\n else {\n if (isBlazor) {\n skeleton = 'T';\n }\n else {\n skeleton = axis.isChart ? 'Hms' : 'hms';\n }\n }\n return skeleton;\n };\n /**\n * Find label format for axis\n *\n * @param {Axis} axis axis\n * @param {number} currentValue currentValue\n * @param {number} previousValue previousValue\n * @private\n */\n NiceInterval.prototype.findCustomFormats = function (axis, currentValue, previousValue) {\n var labelFormat = axis.labelFormat ? axis.labelFormat : '';\n if (axis.isChart && !axis.skeleton && axis.actualIntervalType === 'Months' && !labelFormat) {\n labelFormat = axis.valueType === 'DateTime' ? 'MMM yyyy' : 'yMMM';\n }\n return labelFormat;\n };\n return NiceInterval;\n}(Double));\nexport { NiceInterval };\n","//! moment.js locale configuration\n//! locale : Serbian Cyrillic [sr-cyrl]\n//! author : Milan JanaÄković<milanjanackovic@gmail.com> : https://github.com/milan-j\n//! author : Stefan Crnjaković <stefan@hotmail.rs> : https://github.com/crnjakovic\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var translator = {\n words: {\n //Different grammatical cases\n ss: ['Ñекунда', 'Ñекунде', 'Ñекунди'],\n m: ['један минут', 'једног минута'],\n mm: ['минут', 'минута', 'минута'],\n h: ['један Ñат', 'једног Ñата'],\n hh: ['Ñат', 'Ñата', 'Ñати'],\n d: ['један дан', 'једног дана'],\n dd: ['дан', 'дана', 'дана'],\n M: ['један меÑец', 'једног меÑеца'],\n MM: ['меÑец', 'меÑеца', 'меÑеци'],\n y: ['једну годину', 'једне године'],\n yy: ['годину', 'године', 'година'],\n },\n correctGrammaticalCase: function (number, wordKey) {\n if (\n number % 10 >= 1 &&\n number % 10 <= 4 &&\n (number % 100 < 10 || number % 100 >= 20)\n ) {\n return number % 10 === 1 ? wordKey[0] : wordKey[1];\n }\n return wordKey[2];\n },\n translate: function (number, withoutSuffix, key, isFuture) {\n var wordKey = translator.words[key],\n word;\n\n if (key.length === 1) {\n // Nominativ\n if (key === 'y' && withoutSuffix) return 'једна година';\n return isFuture || withoutSuffix ? wordKey[0] : wordKey[1];\n }\n\n word = translator.correctGrammaticalCase(number, wordKey);\n // Nominativ\n if (key === 'yy' && withoutSuffix && word === 'годину') {\n return number + ' година';\n }\n\n return number + ' ' + word;\n },\n };\n\n var srCyrl = moment.defineLocale('sr-cyrl', {\n months: 'јануар_фебруар_март_април_мај_јун_јул_авгуÑÑ‚_Ñептембар_октобар_новембар_децембар'.split(\n '_'\n ),\n monthsShort:\n 'јан._феб._мар._апр._мај_јун_јул_авг._Ñеп._окт._нов._дец.'.split('_'),\n monthsParseExact: true,\n weekdays: 'недеља_понедељак_уторак_Ñреда_четвртак_петак_Ñубота'.split('_'),\n weekdaysShort: 'нед._пон._уто._Ñре._чет._пет._Ñуб.'.split('_'),\n weekdaysMin: 'не_по_ут_ÑÑ€_че_пе_Ñу'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'D. M. YYYY.',\n LL: 'D. MMMM YYYY.',\n LLL: 'D. MMMM YYYY. H:mm',\n LLLL: 'dddd, D. MMMM YYYY. H:mm',\n },\n calendar: {\n sameDay: '[Ð´Ð°Ð½Ð°Ñ Ñƒ] LT',\n nextDay: '[Ñутра у] LT',\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[у] [недељу] [у] LT';\n case 3:\n return '[у] [Ñреду] [у] LT';\n case 6:\n return '[у] [Ñуботу] [у] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[у] dddd [у] LT';\n }\n },\n lastDay: '[јуче у] LT',\n lastWeek: function () {\n var lastWeekDays = [\n '[прошле] [недеље] [у] LT',\n '[прошлог] [понедељка] [у] LT',\n '[прошлог] [уторка] [у] LT',\n '[прошле] [Ñреде] [у] LT',\n '[прошлог] [четвртка] [у] LT',\n '[прошлог] [петка] [у] LT',\n '[прошле] [Ñуботе] [у] LT',\n ];\n return lastWeekDays[this.day()];\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'за %s',\n past: 'пре %s',\n s: 'неколико Ñекунди',\n ss: translator.translate,\n m: translator.translate,\n mm: translator.translate,\n h: translator.translate,\n hh: translator.translate,\n d: translator.translate,\n dd: translator.translate,\n M: translator.translate,\n MM: translator.translate,\n y: translator.translate,\n yy: translator.translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 1st is the first week of the year.\n },\n });\n\n return srCyrl;\n\n})));\n","/* eslint-disable no-trailing-spaces */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { getAnimationFunction, pathAnimation, getElement } from '../../common/utils/helper';\nimport { Rect } from '@syncfusion/ej2-svg-base';\nimport { Animation, animationMode, isNullOrUndefined } from '@syncfusion/ej2-base';\n/**\n * Base for line type series.\n */\nvar LineBase = /** @class */ (function () {\n /** @private */\n function LineBase(chartModule) {\n this.chart = chartModule;\n }\n /**\n * To improve the chart performance.\n *\n * @returns {void}\n * @private\n */\n LineBase.prototype.enableComplexProperty = function (series) {\n var tempPoints = [];\n var tempPoints2 = [];\n var xVisibleRange = series.xAxis.visibleRange;\n var yVisibleRange = series.yAxis.visibleRange;\n var seriesPoints = series.points;\n var areaBounds = series.clipRect;\n var xTolerance = Math.abs(xVisibleRange.delta / areaBounds.width);\n var yTolerance = Math.abs(yVisibleRange.delta / areaBounds.height);\n var prevXValue = (seriesPoints[0] && seriesPoints[0].xValue > xTolerance) ? 0 : xTolerance;\n var prevYValue = (seriesPoints[0] && seriesPoints[0].y > yTolerance) ? 0 : yTolerance;\n var xVal = 0;\n var yVal = 0;\n for (var _i = 0, seriesPoints_1 = seriesPoints; _i < seriesPoints_1.length; _i++) {\n var currentPoint = seriesPoints_1[_i];\n currentPoint.symbolLocations = [];\n xVal = currentPoint.xValue ? currentPoint.xValue : xVisibleRange.min;\n yVal = currentPoint.yValue ? currentPoint.yValue : yVisibleRange.min;\n if (Math.abs(prevXValue - xVal) >= xTolerance || Math.abs(prevYValue - yVal) >= yTolerance) {\n tempPoints.push(currentPoint);\n prevXValue = xVal;\n prevYValue = yVal;\n }\n }\n var tempPoint;\n for (var i = 0; i < tempPoints.length; i++) {\n tempPoint = tempPoints[i];\n if (isNullOrUndefined(tempPoint.x) || (series.category === 'Indicator' && (isNaN(tempPoint.xValue) || isNaN(tempPoint.yValue)))) {\n continue;\n }\n else {\n tempPoints2.push(tempPoint);\n }\n }\n return tempPoints2;\n };\n /**\n * To generate the line path direction.\n *\n * @param {Points} firstPoint firstPoint\n * @param {Points} secondPoint secondPoint\n * @param {Series} series series\n * @param {boolean} isInverted isInverted\n * @param {Function} getPointLocation getPointLocation\n * @param {string} startPoint startPoint\n */\n LineBase.prototype.getLineDirection = function (firstPoint, secondPoint, series, isInverted, getPointLocation, startPoint) {\n var direction = '';\n if (firstPoint != null) {\n var point1 = getPointLocation(firstPoint.xValue, firstPoint.yValue, series.xAxis, series.yAxis, isInverted, series);\n var point2 = getPointLocation(secondPoint.xValue, secondPoint.yValue, series.xAxis, series.yAxis, isInverted, series);\n direction = startPoint + ' ' + (point1.x) + ' ' + (point1.y) + ' ' +\n 'L' + ' ' + (point2.x) + ' ' + (point2.y) + ' ';\n }\n return direction;\n };\n /**\n * To append the line path.\n *\n * @returns {void}\n * @private\n */\n LineBase.prototype.appendLinePath = function (options, series, clipRect) {\n var element = getElement(options.id);\n var chart = series.chart;\n var previousDirection = element ? element.getAttribute('d') : null;\n var htmlObject = series.chart.renderer.drawPath(options, new Int32Array([series.clipRect.x, series.clipRect.y]));\n if (htmlObject) {\n htmlObject.setAttribute('clip-path', clipRect);\n }\n series.pathElement = htmlObject;\n if (!series.chart.enableCanvas) {\n series.seriesElement.appendChild(htmlObject);\n }\n series.isRectSeries = false;\n pathAnimation(element, options.d, series.chart.redraw, previousDirection, chart.duration);\n };\n /**\n * To render the marker for the series.\n *\n * @returns {void}\n * @private\n */\n LineBase.prototype.renderMarker = function (series) {\n if (series.marker && series.marker.visible) {\n series.chart.markerRender.render(series);\n }\n };\n /**\n * To do the progressive animation.\n *\n * @returns {void}\n * @private\n */\n LineBase.prototype.doProgressiveAnimation = function (series, option) {\n var animation = new Animation({});\n var path = series.pathElement;\n var strokeDashArray = path.getAttribute('stroke-dasharray');\n var pathLength = series.pathElement.getTotalLength();\n var currentTime;\n path.style.visibility = 'hidden';\n animation.animate(path, {\n duration: (option.duration === 0 && animationMode === 'Enable') ? 1000 : option.duration,\n delay: option.delay,\n progress: function (args) {\n if (args.timeStamp >= args.delay) {\n path.style.visibility = 'visible';\n currentTime = Math.abs(Math.round(((args.timeStamp - args.delay) * pathLength) / args.duration));\n path.setAttribute('stroke-dasharray', currentTime + ',' + pathLength);\n }\n },\n end: function () {\n path.setAttribute('stroke-dasharray', strokeDashArray);\n series.chart.trigger('animationComplete', { series: series.chart.isBlazor ? {} : series });\n }\n });\n };\n /**\n * To store the symbol location and region.\n *\n * @param {Points} point point\n * @param {Series} series series\n * @param {boolean} isInverted isInverted\n * @param {Function} getLocation getLocation\n */\n LineBase.prototype.storePointLocation = function (point, series, isInverted, getLocation) {\n var markerWidth = (series.marker && series.marker.width) ? series.marker.width : 0;\n var markerHeight = (series.marker && series.marker.height) ? series.marker.height : 0;\n point.symbolLocations.push(getLocation(point.xValue, point.yValue, series.xAxis, series.yAxis, isInverted, series));\n point.regions.push(new Rect(point.symbolLocations[0].x - markerWidth, point.symbolLocations[0].y - markerHeight, 2 * markerWidth, 2 * markerHeight));\n };\n /**\n * To find point with in the visible range\n *\n * @param {Points} point point\n * @param {Axis} yAxis yAxis\n * @private\n */\n LineBase.prototype.withinYRange = function (point, yAxis) {\n return point.yValue >= yAxis.visibleRange.min && point.yValue <= yAxis.visibleRange.max;\n };\n LineBase.prototype.GetStepLineDirection = function (currentPoint, previousPoint, stepLineType, command) {\n if (command === void 0) { command = 'L'; }\n if (stepLineType === 'Right') {\n return (command + ' ' +\n (previousPoint.x) + ' ' + (currentPoint.y) + ' L ' + (currentPoint.x) + ' ' + (currentPoint.y) + ' ');\n }\n else if (stepLineType === 'Center') {\n var centerX = previousPoint.x + (currentPoint.x - previousPoint.x) / 2;\n return (command + ' ' +\n (centerX) + ' ' + (previousPoint.y) + ' L ' + (centerX) + ' ' + (currentPoint.y) + ' L ' + (currentPoint.x) + ' ' + (currentPoint.y) + ' ');\n }\n else {\n return (command + ' ' +\n (currentPoint.x) + ' ' + (previousPoint.y) + ' L ' + (currentPoint.x) + ' ' + (currentPoint.y) + ' ');\n }\n };\n /**\n * To get first and last visible points\n *\n * @private\n */\n LineBase.prototype.getFirstLastVisiblePoint = function (points) {\n var first = null;\n var last = null;\n for (var _i = 0, points_1 = points; _i < points_1.length; _i++) {\n var point = points_1[_i];\n if (first === null && point.visible) {\n first = last = point;\n }\n last = point.visible ? point : last;\n }\n return { first: first ? first : points[0], last: last ? last : points[points.length - 1] };\n };\n /**\n * To Generate the area series border path direction from area series main direction path.\n *\n * @param {string} direction direction\n *\n * */\n LineBase.prototype.getBorderDirection = function (direction) {\n var coordinates = direction.split(' ');\n if (coordinates.length > 3 && !(this.chart.stackingAreaSeriesModule) && !(this.chart.stackingStepAreaSeriesModule)) {\n coordinates.splice(coordinates.length - 4, 3);\n }\n else if (this.chart.stackingAreaSeriesModule || this.chart.stackingStepAreaSeriesModule) {\n coordinates.splice(coordinates.length / 2 + 1, coordinates.length / 2 + 1);\n if (coordinates[coordinates.length - 1] === 'L') {\n coordinates.splice(coordinates.length - 1, 1);\n }\n }\n return coordinates.join(' ');\n };\n /**\n * To remove empty point directions from series direction of area types.\n *\n * @param {string} borderDirection direction\n *\n * */\n LineBase.prototype.removeEmptyPointsBorder = function (borderDirection) {\n var startIndex = 0;\n var coordinates = borderDirection.split(' ');\n // eslint-disable-next-line @typescript-eslint/tslint/config\n var point;\n do {\n point = coordinates.indexOf('M', startIndex);\n if (point > -1) {\n coordinates.splice(point + 1, 3);\n startIndex = point + 1;\n if (point - 6 > 0) {\n coordinates.splice(point - 6, 6);\n startIndex -= 6;\n }\n }\n } while (point !== -1);\n return coordinates.join(' ');\n };\n /**\n * To do the linear animation.\n *\n * @returns {void}\n * @private\n */\n LineBase.prototype.doLinearAnimation = function (series, animation) {\n var clipRect = series.clipRectElement.childNodes[0].childNodes[0];\n var duration = series.chart.animated ? series.chart.duration : animation.duration;\n var effect = getAnimationFunction('Linear');\n var elementHeight = +clipRect.getAttribute('height');\n var elementWidth = +clipRect.getAttribute('width');\n var xCenter = +clipRect.getAttribute('x');\n var yCenter = series.chart.requireInvertedAxis ? +clipRect.getAttribute('height') + +clipRect.getAttribute('y') :\n +clipRect.getAttribute('y');\n var value;\n clipRect.style.visibility = 'hidden';\n new Animation({}).animate(clipRect, {\n duration: (duration === 0 && animationMode === 'Enable') ? 1000 : duration,\n delay: animation.delay,\n progress: function (args) {\n if (args.timeStamp >= args.delay) {\n clipRect.style.visibility = 'visible';\n if (series.chart.requireInvertedAxis) {\n value = effect(args.timeStamp - args.delay, 0, elementHeight, args.duration);\n clipRect.setAttribute('transform', 'translate(' + xCenter + ' ' + yCenter +\n ') scale(1,' + (value / elementHeight) + ') translate(' + (-xCenter) + ' ' + (-yCenter) + ')');\n }\n else {\n value = effect(args.timeStamp - args.delay, 0, elementWidth, args.duration);\n clipRect.setAttribute('transform', 'translate(' + xCenter + ' ' + yCenter +\n ') scale(' + (value / elementWidth) + ', 1) translate(' + (-xCenter) + ' ' + (-yCenter) + ')');\n }\n }\n },\n end: function () {\n clipRect.setAttribute('transform', 'translate(0,0)');\n series.chart.trigger('animationComplete', { series: series.chart.isBlazor ? {} : series });\n }\n });\n };\n return LineBase;\n}());\nexport { LineBase };\n","//! moment.js locale configuration\n//! locale : Occitan, lengadocian dialecte [oc-lnc]\n//! author : Quentin PAGÈS : https://github.com/Quenty31\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ocLnc = moment.defineLocale('oc-lnc', {\n months: {\n standalone:\n 'genièr_febrièr_març_abril_mai_junh_julhet_agost_setembre_octòbre_novembre_decembre'.split(\n '_'\n ),\n format: \"de genièr_de febrièr_de març_d'abril_de mai_de junh_de julhet_d'agost_de setembre_d'octòbre_de novembre_de decembre\".split(\n '_'\n ),\n isFormat: /D[oD]?(\\s)+MMMM/,\n },\n monthsShort:\n 'gen._febr._març_abr._mai_junh_julh._ago._set._oct._nov._dec.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'dimenge_diluns_dimars_dimècres_dijòus_divendres_dissabte'.split(\n '_'\n ),\n weekdaysShort: 'dg._dl._dm._dc._dj._dv._ds.'.split('_'),\n weekdaysMin: 'dg_dl_dm_dc_dj_dv_ds'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM [de] YYYY',\n ll: 'D MMM YYYY',\n LLL: 'D MMMM [de] YYYY [a] H:mm',\n lll: 'D MMM YYYY, H:mm',\n LLLL: 'dddd D MMMM [de] YYYY [a] H:mm',\n llll: 'ddd D MMM YYYY, H:mm',\n },\n calendar: {\n sameDay: '[uèi a] LT',\n nextDay: '[deman a] LT',\n nextWeek: 'dddd [a] LT',\n lastDay: '[ièr a] LT',\n lastWeek: 'dddd [passat a] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: \"d'aquà %s\",\n past: 'fa %s',\n s: 'unas segondas',\n ss: '%d segondas',\n m: 'una minuta',\n mm: '%d minutas',\n h: 'una ora',\n hh: '%d oras',\n d: 'un jorn',\n dd: '%d jorns',\n M: 'un mes',\n MM: '%d meses',\n y: 'un an',\n yy: '%d ans',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(r|n|t|è|a)/,\n ordinal: function (number, period) {\n var output =\n number === 1\n ? 'r'\n : number === 2\n ? 'n'\n : number === 3\n ? 'r'\n : number === 4\n ? 't'\n : 'è';\n if (period === 'w' || period === 'W') {\n output = 'a';\n }\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4,\n },\n });\n\n return ocLnc;\n\n})));\n","//! moment.js locale configuration\n//! locale : Maltese (Malta) [mt]\n//! author : Alessandro Maruccia : https://github.com/alesma\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var mt = moment.defineLocale('mt', {\n months: 'Jannar_Frar_Marzu_April_Mejju_Ä unju_Lulju_Awwissu_Settembru_Ottubru_Novembru_DiÄ‹embru'.split(\n '_'\n ),\n monthsShort: 'Jan_Fra_Mar_Apr_Mej_Ä un_Lul_Aww_Set_Ott_Nov_DiÄ‹'.split('_'),\n weekdays:\n 'Il-Ħadd_It-Tnejn_It-Tlieta_L-Erbgħa_Il-Ħamis_Il-Ä imgħa_Is-Sibt'.split(\n '_'\n ),\n weekdaysShort: 'Ħad_Tne_Tli_Erb_Ħam_Ä im_Sib'.split('_'),\n weekdaysMin: 'Ħa_Tn_Tl_Er_Ħa_Ä i_Si'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Illum fil-]LT',\n nextDay: '[Għada fil-]LT',\n nextWeek: 'dddd [fil-]LT',\n lastDay: '[Il-bieraħ fil-]LT',\n lastWeek: 'dddd [li għadda] [fil-]LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'f’ %s',\n past: '%s ilu',\n s: 'ftit sekondi',\n ss: '%d sekondi',\n m: 'minuta',\n mm: '%d minuti',\n h: 'siegħa',\n hh: '%d siegħat',\n d: 'Ä¡urnata',\n dd: '%d Ä¡ranet',\n M: 'xahar',\n MM: '%d xhur',\n y: 'sena',\n yy: '%d sni',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return mt;\n\n})));\n","//! moment.js locale configuration\n//! locale : Arabic (Libya) [ar-ly]\n//! author : Ali Hmer: https://github.com/kikoanis\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '1',\n 2: '2',\n 3: '3',\n 4: '4',\n 5: '5',\n 6: '6',\n 7: '7',\n 8: '8',\n 9: '9',\n 0: '0',\n },\n pluralForm = function (n) {\n return n === 0\n ? 0\n : n === 1\n ? 1\n : n === 2\n ? 2\n : n % 100 >= 3 && n % 100 <= 10\n ? 3\n : n % 100 >= 11\n ? 4\n : 5;\n },\n plurals = {\n s: [\n 'أقل من ثانية',\n 'ثانية واØدة',\n ['ثانيتان', 'ثانيتين'],\n '%d ثوان',\n '%d ثانية',\n '%d ثانية',\n ],\n m: [\n 'أقل من دقيقة',\n 'دقيقة واØدة',\n ['دقيقتان', 'دقيقتين'],\n '%d دقائق',\n '%d دقيقة',\n '%d دقيقة',\n ],\n h: [\n 'أقل من ساعة',\n 'ساعة واØدة',\n ['ساعتان', 'ساعتين'],\n '%d ساعات',\n '%d ساعة',\n '%d ساعة',\n ],\n d: [\n 'أقل من يوم',\n 'يوم واØد',\n ['يومان', 'يومين'],\n '%d أيام',\n '%d يومًا',\n '%d يوم',\n ],\n M: [\n 'أقل من شهر',\n 'شهر واØد',\n ['شهران', 'شهرين'],\n '%d أشهر',\n '%d شهرا',\n '%d شهر',\n ],\n y: [\n 'أقل من عام',\n 'عام واØد',\n ['عامان', 'عامين'],\n '%d أعوام',\n '%d عامًا',\n '%d عام',\n ],\n },\n pluralize = function (u) {\n return function (number, withoutSuffix, string, isFuture) {\n var f = pluralForm(number),\n str = plurals[u][pluralForm(number)];\n if (f === 2) {\n str = str[withoutSuffix ? 0 : 1];\n }\n return str.replace(/%d/i, number);\n };\n },\n months = [\n 'يناير',\n 'Ùبراير',\n 'مارس',\n 'أبريل',\n 'مايو',\n 'يونيو',\n 'يوليو',\n 'أغسطس',\n 'سبتمبر',\n 'أكتوبر',\n 'نوÙمبر',\n 'ديسمبر',\n ];\n\n var arLy = moment.defineLocale('ar-ly', {\n months: months,\n monthsShort: months,\n weekdays: 'الأØد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),\n weekdaysShort: 'Ø£Øد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت'.split('_'),\n weekdaysMin: 'Ø_Ù†_Ø«_ر_Ø®_ج_س'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'D/\\u200FM/\\u200FYYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n meridiemParse: /ص|Ù…/,\n isPM: function (input) {\n return 'Ù…' === input;\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'ص';\n } else {\n return 'Ù…';\n }\n },\n calendar: {\n sameDay: '[اليوم عند الساعة] LT',\n nextDay: '[غدًا عند الساعة] LT',\n nextWeek: 'dddd [عند الساعة] LT',\n lastDay: '[أمس عند الساعة] LT',\n lastWeek: 'dddd [عند الساعة] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'بعد %s',\n past: 'منذ %s',\n s: pluralize('s'),\n ss: pluralize('s'),\n m: pluralize('m'),\n mm: pluralize('m'),\n h: pluralize('h'),\n hh: pluralize('h'),\n d: pluralize('d'),\n dd: pluralize('d'),\n M: pluralize('M'),\n MM: pluralize('M'),\n y: pluralize('y'),\n yy: pluralize('y'),\n },\n preparse: function (string) {\n return string.replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string\n .replace(/\\d/g, function (match) {\n return symbolMap[match];\n })\n .replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 6, // Saturday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return arLy;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { extend, Browser, remove } from '@syncfusion/ej2-base';\nimport { PointData, ChartLocation } from '../../common/utils/helper';\nimport { getElement, measureText, Rect } from '@syncfusion/ej2-svg-base';\nimport { valueToCoefficient, removeElement, valueToPolarCoefficient, withInBounds } from '../../common/utils/helper';\nimport { BaseTooltip } from '../../common/user-interaction/tooltip';\nimport { tooltipRender, sharedTooltipRender } from '../../common/model/constants';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\n/**\n * `Tooltip` module is used to render the tooltip for chart series.\n */\nvar Tooltip = /** @class */ (function (_super) {\n __extends(Tooltip, _super);\n /**\n * Constructor for tooltip module.\n *\n * @private\n */\n function Tooltip(chart) {\n var _this = _super.call(this, chart) || this;\n _this.commonXvalues = [];\n _this.addEventListener();\n return _this;\n }\n /**\n * @hidden\n */\n Tooltip.prototype.addEventListener = function () {\n if (this.chart.isDestroyed) {\n return;\n }\n var cancelEvent = Browser.isPointer ? 'pointerleave' : 'mouseleave';\n this.chart.on(cancelEvent, this.mouseLeaveHandler, this);\n this.chart.on('tapHold', this.longPress, this);\n this.chart.on(Browser.touchMoveEvent, this.mouseMoveHandler, this);\n this.chart.on(Browser.touchEndEvent, this.mouseUpHandler, this);\n };\n Tooltip.prototype.mouseUpHandler = function () {\n var chart = this.control;\n var data = this.getData();\n data.lierIndex = this.lierIndex;\n if (chart.isTouch && !this.isSelected(chart) &&\n ((withInBounds(chart.mouseX, chart.mouseY, chart.chartAxisLayoutPanel.seriesClipRect) && chart.tooltip.shared)\n || !chart.tooltip.shared)) {\n if (!chart.crosshair.enable) {\n this.tooltip();\n if (chart.tooltip.fadeOutMode === 'Move') {\n this.removeTooltip(chart.tooltip.fadeOutDuration);\n }\n }\n else if (chart.startMove && chart.tooltip.fadeOutMode === 'Move') {\n this.removeTooltip(2000);\n }\n }\n else if (!this.findData(data, this.previousPoints[0]) && chart.tooltip.fadeOutMode === 'Click') {\n this.removeTooltip(0);\n }\n };\n Tooltip.prototype.mouseLeaveHandler = function () {\n this.removeTooltip(this.chart.tooltip.fadeOutDuration);\n };\n Tooltip.prototype.mouseMoveHandler = function () {\n var chart = this.chart;\n chart.mouseX = chart.mouseX / chart.scaleX;\n chart.mouseY = chart.mouseY / chart.scaleY;\n if (chart.stockChart && chart.stockChart.onPanning) {\n if (chart.mouseY < chart.chartAxisLayoutPanel.seriesClipRect.y) {\n chart.mouseY = chart.chartAxisLayoutPanel.seriesClipRect.y;\n }\n else if (chart.mouseY > chart.chartAxisLayoutPanel.seriesClipRect.y + chart.chartAxisLayoutPanel.seriesClipRect.height) {\n chart.mouseY = chart.chartAxisLayoutPanel.seriesClipRect.y + chart.chartAxisLayoutPanel.seriesClipRect.height;\n }\n }\n // Tooltip for chart series.\n if (!chart.disableTrackTooltip && !this.isSelected(chart)) {\n if (!chart.tooltip.shared && (!chart.isTouch || (chart.startMove))) {\n this.tooltip();\n }\n if (withInBounds(chart.mouseX, chart.mouseY, chart.chartAxisLayoutPanel.seriesClipRect)) {\n if (chart.tooltip.shared && (!chart.isTouch || (chart.startMove))) {\n this.tooltip();\n }\n }\n else {\n if (chart.tooltip.shared && chart.tooltip.fadeOutMode === 'Move') {\n this.removeTooltip(this.chart.tooltip.fadeOutDuration);\n }\n }\n }\n };\n /**\n * Handles the long press on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Tooltip.prototype.longPress = function () {\n var chart = this.chart;\n if (chart.crosshair.enable && withInBounds(chart.mouseX, chart.mouseY, chart.chartAxisLayoutPanel.seriesClipRect)) {\n this.tooltip();\n chart.markerRender.markerMove(false);\n }\n return false;\n };\n /**\n * Renders the tooltip.\n *\n * @returns {void}\n */\n Tooltip.prototype.tooltip = function () {\n var elementId = this.chart.enableCanvas ? this.element.id + '_tooltip_group' : this.element.id + '_tooltip_svg';\n var svgElement = this.getElement(elementId);\n // To prevent the disappearance of the tooltip, while resize the stock chart.\n var isStockSvg = this.chart.stockChart && svgElement && (svgElement.firstChild.childNodes.length > 1);\n var isTooltip = (svgElement && parseInt(svgElement.getAttribute('opacity'), 10) > 0 && !isStockSvg);\n var tooltipDiv = this.getTooltipElement(isTooltip);\n if (this.chart.enableCanvas && tooltipDiv) {\n document.getElementById(this.chart.element.id + '_Secondary_Element').appendChild(tooltipDiv);\n tooltipDiv.appendChild(document.getElementById(this.chart.element.id + '_tooltip_svg'));\n }\n if (!this.chart.tooltip.shared) {\n this.renderSeriesTooltip(this.chart, !isTooltip, tooltipDiv);\n }\n else {\n this.renderGroupedTooltip(this.chart, !isTooltip, tooltipDiv);\n }\n };\n Tooltip.prototype.findHeader = function (data) {\n if (this.header === '') {\n return '';\n }\n this.header = this.parseTemplate(data.point, data.series, this.header, data.series.xAxis, data.series.yAxis);\n if (this.header.replace(/<b>/g, '').replace(/<\\/b>/g, '').trim() !== '') {\n return this.header;\n }\n return '';\n };\n Tooltip.prototype.findShapes = function () {\n if (!this.chart.tooltip.enableMarker) {\n return [];\n }\n var marker = [];\n for (var _i = 0, _a = this.currentPoints; _i < _a.length; _i++) {\n var data = _a[_i];\n marker.push(data.point.marker.shape || data.series.marker.shape || 'Circle');\n }\n return marker;\n };\n Tooltip.prototype.renderSeriesTooltip = function (chart, isFirst, tooltipDiv) {\n var data = this.getData();\n data.lierIndex = this.lierIndex;\n this.currentPoints = [];\n if (this.findData(data, this.previousPoints[0])) {\n if (!(chart.dataEditingModule && chart.dataEditingModule.isPointDragging) && (this.previousPoints[0] &&\n data.point.index === this.previousPoints[0].point.index && data.series.index === this.previousPoints[0].series.index)) {\n return null;\n }\n if (this.pushData(data, isFirst, tooltipDiv, true)) {\n this.triggerTooltipRender(data, isFirst, this.getTooltipText(data), this.findHeader(data));\n }\n }\n else {\n if (!data.point && this.isRemove && chart.tooltip.fadeOutMode === 'Move') {\n this.removeTooltip(this.chart.tooltip.fadeOutDuration);\n this.isRemove = false;\n }\n else {\n var commonXvalues = this.mergeXvalues(this.chart.visibleSeries);\n for (var _i = 0, _a = chart.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n if (series.visible && !(series.category === 'TrendLine')) {\n data = this.getClosestX(chart, series, commonXvalues) || data;\n }\n }\n }\n }\n if (data && data.point) {\n this.findMouseValue(data, chart);\n }\n };\n Tooltip.prototype.triggerTooltipRender = function (point, isFirst, textCollection, headerText) {\n var _this = this;\n var tooltipTemplate;\n var argsData = {\n cancel: false, name: tooltipRender, text: textCollection, headerText: headerText, template: tooltipTemplate,\n series: this.chart.isBlazor ? {} : point.series, textStyle: this.textStyle, point: point.point,\n data: { pointX: point.point.x, pointY: point.point.y, seriesIndex: point.series.index, seriesName: point.series.name,\n pointIndex: point.point.index, pointText: point.point.text }\n };\n var borderWidth = this.chart.border.width;\n var padding = 3;\n var tooltip = this.chart.tooltip;\n var chartTooltipSuccess = function (argsData) {\n if (!argsData.cancel) {\n if (point.series.type === 'BoxAndWhisker') {\n _this.removeText();\n isFirst = true;\n }\n _this.headerText = argsData.headerText;\n _this.formattedText = _this.formattedText.concat(argsData.text);\n _this.text = _this.formattedText;\n var location_1 = _this.getSymbolLocation(point);\n location_1 = location_1 ? location_1 : new ChartLocation(null, null);\n location_1.x = tooltip.location.x !== null ? tooltip.location.x : location_1.x;\n location_1.y = tooltip.location.y !== null ? tooltip.location.y : location_1.y;\n location_1 = (location_1.x === null && location_1.y === null) ? null : location_1;\n _this.createTooltip(_this.chart, isFirst, location_1, point.series.clipRect, point.point, _this.findShapes(), _this.findMarkerHeight(_this.currentPoints[0]), new Rect(borderWidth, borderWidth, _this.chart.availableSize.width - padding - borderWidth * 2, _this.chart.availableSize.height - padding - borderWidth * 2), _this.chart.crosshair.enable, null, _this.getTemplateText(point), _this.template ? argsData.template : '');\n }\n else {\n _this.removeHighlight();\n remove(_this.getElement(_this.element.id + '_tooltip'));\n }\n _this.isRemove = true;\n };\n chartTooltipSuccess.bind(this, point);\n this.chart.trigger(tooltipRender, argsData, chartTooltipSuccess);\n };\n Tooltip.prototype.findMarkerHeight = function (pointData) {\n var markerHeight = 0;\n var series = pointData.series;\n markerHeight = ((series.marker.visible || (this.chart.tooltip.shared &&\n (!series.isRectSeries || series.marker.visible)) || series.type === 'Scatter' || series.drawType === 'Scatter')\n && !(series.type === 'Candle' || series.type === 'Hilo' || series.type === 'HiloOpenClose')) ?\n ((series.marker.height + 2) / 2 + (2 * series.marker.border.width)) : 0;\n return markerHeight;\n };\n Tooltip.prototype.findData = function (data, previous) {\n return data.point && ((!previous || (previous.point !== data.point)) ||\n (previous && previous.lierIndex > 3 && previous.lierIndex !== this.lierIndex) || (previous.point === data.point));\n };\n Tooltip.prototype.getSymbolLocation = function (data) {\n var location;\n if (data.series.type !== 'BoxAndWhisker') {\n if (!data.point.symbolLocations[0]) {\n return null;\n }\n location = new ChartLocation(data.point.symbolLocations[0].x, data.point.symbolLocations[0].y);\n }\n switch (data.series.type) {\n case 'BoxAndWhisker':\n return this.getBoxLocation(data);\n case 'Waterfall':\n return this.getWaterfallRegion(data, location);\n case 'RangeArea':\n case 'RangeStepArea':\n case 'SplineRangeArea':\n case 'RangeColumn':\n return this.getRangeArea(data, location);\n default:\n return location;\n }\n };\n Tooltip.prototype.getRangeArea = function (data, location) {\n if (data.point.regions[0]) {\n if (!this.inverted) {\n location.y = data.point.regions[0].y + data.point.regions[0].height / 2;\n }\n else {\n location.x = data.point.regions[0].x + data.point.regions[0].width / 2;\n }\n if (data.series.type === 'RangeStepArea') {\n location.y = data.point.regions[0].y + data.point.regions[0].height / 2 + data.point.regions[0].width;\n }\n }\n return location;\n };\n Tooltip.prototype.getWaterfallRegion = function (data, location) {\n if (!this.inverted) {\n location.y = (data.point.y < 0) ?\n location.y - data.point.regions[0].height : location.y;\n }\n else {\n location.x = (data.point.y < 0) ?\n location.x + data.point.regions[0].width : location.x;\n }\n return location;\n };\n Tooltip.prototype.getTooltipText = function (pointData) {\n var series = pointData.series;\n return this.parseTemplate(pointData.point, series, this.getFormat(this.chart, series), series.xAxis, series.yAxis);\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n Tooltip.prototype.getTemplateText = function (data) {\n if (this.template && this.chart.tooltip.shared) {\n var point = [];\n for (var i = 0; i < data.length; i++) {\n point[i] = extend({}, data[i].point);\n point[i].x = this.formatPointValue(data[i].point, data[i].series.xAxis, 'x', true, false);\n if ((data[i].series.seriesType === 'XY')) {\n point[i].y = this.formatPointValue(data[i].point, data[i].series.yAxis, 'y', false, true);\n }\n else {\n point[i].low = this.formatPointValue(data[i].point, data[i].series.yAxis, 'low', false, true);\n point[i].high = this.formatPointValue(data[i].point, data[i].series.yAxis, 'high', false, true);\n }\n }\n return point;\n }\n else if (this.template) {\n var point = extend({}, data.point);\n point.x = this.formatPointValue(data.point, data.series.xAxis, 'x', true, false);\n if ((data.series.seriesType === 'XY')) {\n point.y = this.formatPointValue(data.point, data.series.yAxis, 'y', false, true);\n }\n else {\n point.low = this.formatPointValue(data.point, data.series.yAxis, 'low', false, true);\n point.high = this.formatPointValue(data.point, data.series.yAxis, 'high', false, true);\n }\n return point;\n }\n else {\n return data.point;\n }\n };\n Tooltip.prototype.findMouseValue = function (data, chart) {\n if (!chart.requireInvertedAxis) {\n if (chart.chartAreaType === 'PolarRadar') {\n this.valueX = valueToPolarCoefficient(data.point.xValue, data.series.xAxis) * data.series.xAxis.rect.width\n + data.series.xAxis.rect.x;\n }\n else {\n this.valueX = (data.series.category === 'TrendLine' && chart.tooltip.shared) ? this.valueX :\n valueToCoefficient(data.point.xValue, data.series.xAxis) * data.series.xAxis.rect.width\n + data.series.xAxis.rect.x;\n }\n this.valueY = chart.mouseY;\n }\n else {\n this.valueY = (1 - valueToCoefficient(data.point.xValue, data.series.xAxis)) * data.series.xAxis.rect.height\n + data.series.xAxis.rect.y;\n this.valueX = chart.mouseX;\n }\n };\n Tooltip.prototype.renderGroupedTooltip = function (chart, isFirst, tooltipDiv) {\n var data;\n var dataCollection = [];\n var lastData;\n var pointData = chart.chartAreaType === 'PolarRadar' ? this.getData() : null;\n this.stopAnimation();\n this.removeHighlight();\n this.currentPoints = [];\n var extraPoints = [];\n var closestXValue = Number.MAX_VALUE;\n var closetYValue = Number.MAX_VALUE;\n var pointXValue;\n var pointYValue;\n var tempData;\n //let headerContent : string = '';\n if (isFirst) {\n if (!chart.stockChart) {\n if (tooltipDiv) {\n document.getElementById(this.element.id + '_Secondary_Element').appendChild(tooltipDiv);\n }\n }\n else {\n if (tooltipDiv && !getElement(tooltipDiv.id)) {\n document.getElementById(chart.stockChart.element.id + '_Secondary_Element').appendChild(tooltipDiv);\n }\n }\n }\n this.removeText();\n var argument = {\n text: [], cancel: false, name: sharedTooltipRender, data: [], point: [], series: [], headerText: '', textStyle: this.textStyle, template: ''\n };\n var i = 0;\n for (var _i = 0, _a = chart.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n if (!series.enableTooltip || !series.visible) {\n continue;\n }\n if (chart.chartAreaType === 'Cartesian' && series.visible) {\n data = this.getClosestX(chart, series, this.commonXValue(this.chart.visibleSeries));\n }\n else if (chart.chartAreaType === 'PolarRadar' && series.visible && pointData.point !== null) {\n data = new PointData(series.points[pointData.point.index], series);\n }\n // if (data && this.header !== '' && this.currentPoints.length === 0) {\n // headerContent = this.findHeader(data);\n // }\n if (chart.tooltip.showNearestPoint && !data) {\n data = this.getClosestX(chart, series, this.commonXValue([series]));\n }\n if (data) {\n argument.data.push({ pointX: data.point.x, pointY: data.point.y, seriesIndex: data.series.index,\n seriesName: data.series.name, pointIndex: data.point.index, pointText: data.point.text });\n argument.series[i] = data.series;\n argument.point[i] = data.point;\n argument.headerText = this.findHeader(data);\n this.currentPoints.push(data);\n argument.text.push(this.getTooltipText(data));\n pointXValue = (!chart.requireInvertedAxis) ? chart.mouseX - data.series.clipRect.x : chart.mouseY - data.series.clipRect.y;\n pointYValue = chart.mouseY - data.series.clipRect.y;\n if (data.point.symbolLocations && data.point.symbolLocations.length && Math.abs(pointXValue - data.point.symbolLocations[0].x) <= closestXValue &&\n Math.abs(data.point.symbolLocations[0].y - pointYValue) < Math.abs(closetYValue - pointYValue)) {\n closestXValue = Math.abs(pointXValue - data.point.symbolLocations[0].x);\n closetYValue = data.point.symbolLocations[0].y;\n tempData = data;\n }\n lastData = (data.series.category === 'TrendLine' && chart.tooltip.shared) ? lastData : tempData || data;\n dataCollection.push(data);\n }\n // if (data && this.triggerEvent(data, isFirst, this.getTooltipText(data)), this.findHeader(data)) {\n // this.findMouseValue(data, chart);\n // (<PointData[]>this.currentPoints).push(data);\n // data = null;\n // } else if (data) {\n // extraPoints.push(data);\n // }\n i++;\n }\n if (!chart.tooltip.showNearestPoint) {\n var collection = [];\n this.currentPoints = [];\n argument.point = [];\n argument.series = [];\n argument.data = [];\n argument.text = [];\n for (var _b = 0, dataCollection_1 = dataCollection; _b < dataCollection_1.length; _b++) {\n var data_1 = dataCollection_1[_b];\n if (data_1.point.symbolLocations[0].x === lastData.point.symbolLocations[0].x || ((data_1.series.type.indexOf('Column') !== -1 || lastData.series.type.indexOf('Column') !== -1) && (data_1.point.xValue === lastData.point.xValue))) {\n argument.point.push(data_1.point);\n argument.series.push(data_1.series);\n argument.text.push(this.getTooltipText(data_1));\n argument.headerText = this.findHeader(data_1);\n collection.push(data_1);\n argument.data.push({\n pointX: data_1.point.x, pointY: data_1.point.y, seriesIndex: data_1.series.index,\n seriesName: data_1.series.name, pointIndex: data_1.point.index, pointText: data_1.point.text\n });\n }\n }\n dataCollection = collection;\n this.currentPoints = collection;\n }\n if (dataCollection.length > 0 && this.currentPoints.length > 0) { // To avoid console error when we have empty chart with shared tooltip.\n this.triggerSharedTooltip(argument, lastData, extraPoints, chart, isFirst, dataCollection);\n }\n else if (this.getElement(this.element.id + '_tooltip_path')) {\n this.getElement(this.element.id + '_tooltip_path').setAttribute('d', '');\n }\n };\n Tooltip.prototype.triggerSharedTooltip = function (argument, point, extraPoints, chart, isFirst, dataCollection) {\n var _this = this;\n var tooltipTemplate;\n var argsData = {\n cancel: false, name: sharedTooltipRender, text: argument.text, headerText: argument.headerText,\n textStyle: argument.textStyle, template: tooltipTemplate,\n point: argument.point, series: argument.series,\n data: argument.data\n };\n var borderWidth = this.chart.border.width;\n var padding = 3;\n var toolbarHeight;\n var titleHeight;\n var currentPoints = [];\n if (chart.stockChart) {\n toolbarHeight = chart.stockChart.enablePeriodSelector ? chart.stockChart.toolbarHeight : 0;\n titleHeight = measureText(this.chart.stockChart.title, this.chart.stockChart.titleStyle, this.chart.themeStyle.tooltipLabelFont).height + 10;\n }\n var sharedTooltip = function (argsData) {\n if (!argsData.cancel) {\n if (point.series.type === 'BoxAndWhisker') {\n _this.removeText();\n isFirst = true;\n }\n for (var i = 0; i < argsData.text.length; i++) {\n if (argsData.text[i]) {\n currentPoints.push(_this.currentPoints[i]);\n }\n }\n _this.currentPoints = currentPoints;\n _this.formattedText = _this.formattedText.concat(argsData.text);\n _this.text = argsData.text;\n _this.headerText = argsData.headerText;\n var tooltip = _this.chart.tooltip;\n _this.findMouseValue(point, _this.chart);\n var location_2 = _this.findSharedLocation();\n location_2 = location_2 ? location_2 : new ChartLocation(null, null);\n location_2.x = tooltip.location.x !== null ? tooltip.location.x : location_2.x;\n location_2.y = tooltip.location.y !== null ? tooltip.location.y : location_2.y;\n location_2 = (location_2.x === null && location_2.y === null) ? null : location_2;\n _this.createTooltip(chart, isFirst, location_2, _this.currentPoints.length === 1 ? _this.currentPoints[0].series.clipRect : null, dataCollection.length === 1 ? dataCollection[0].point : null, _this.findShapes(), _this.findMarkerHeight(_this.currentPoints[0]), new Rect(borderWidth, (chart.stockChart ? (toolbarHeight + titleHeight + borderWidth) : borderWidth), _this.chart.availableSize.width - padding - borderWidth * 2, _this.chart.availableSize.height - padding - borderWidth * 2), _this.chart.crosshair.enable, extraPoints, _this.template ? _this.getTemplateText(dataCollection) : null, _this.template ? argsData.template : '');\n point = null;\n }\n else {\n extraPoints.push(point);\n }\n };\n sharedTooltip.bind(this, point, extraPoints);\n this.chart.trigger(sharedTooltipRender, argsData, sharedTooltip);\n };\n Tooltip.prototype.findSharedLocation = function () {\n var stockChart = this.chart.stockChart;\n if (stockChart) {\n if (this.text.length === 1) {\n this.text.push('');\n }\n var toolbarHeight = stockChart.enablePeriodSelector ? stockChart.toolbarHeight : 0;\n var element = document.getElementById(stockChart.element.id + '_ChartTitle');\n var titleHeight = stockChart.title !== '' ? element.getBoundingClientRect().height + 10 : 0;\n if (stockChart.tooltip.position === 'Nearest') {\n return new ChartLocation(this.valueX, this.valueY + toolbarHeight + titleHeight);\n }\n return new ChartLocation(this.chart.chartAxisLayoutPanel.seriesClipRect.x + 5, this.chart.chartAxisLayoutPanel.seriesClipRect.y + toolbarHeight + 5 + titleHeight);\n }\n else {\n if (this.currentPoints.length > 1) {\n return new ChartLocation(this.valueX, this.valueY);\n }\n else {\n return this.getSymbolLocation(this.currentPoints[0]);\n }\n }\n };\n Tooltip.prototype.getBoxLocation = function (data) {\n var location = this.lierIndex > 3 ? (data.point.outliers.length > 0 ? data.point.symbolLocations[this.lierIndex - 4] : null) :\n {\n x: data.point.regions[0].x + (data.point.regions[0].width / 2),\n y: data.point.regions[0].y + (data.point.regions[0].height / 2)\n };\n return location;\n };\n Tooltip.prototype.parseTemplate = function (point, series, format, xAxis, yAxis) {\n var val;\n var textValue;\n for (var _i = 0, _a = Object.keys(point); _i < _a.length; _i++) {\n var dataValue = _a[_i];\n val = new RegExp('${point' + '.' + dataValue + '}', 'gm');\n format = format.replace(val.source, this.formatPointValue(point, val.source === '${point.x}' ? xAxis : yAxis, dataValue, val.source === '${point.x}', (val.source === '${point.high}' ||\n val.source === '${point.open}' ||\n val.source === '${point.close}' ||\n val.source === '${point.low}' ||\n val.source === '${point.y}' ||\n val.source === '${point.minimum}' ||\n val.source === '${point.maximum}' ||\n val.source === '${point.outliers}' ||\n val.source === '${point.upperQuartile}' ||\n val.source === '${point.lowerQuartile}' ||\n val.source === '${point.median}')));\n }\n for (var _b = 0, _c = Object.keys(Object.getPrototypeOf(series)); _b < _c.length; _b++) {\n var dataValue = _c[_b];\n val = new RegExp('${series' + '.' + dataValue + '}', 'gm');\n textValue = series[dataValue];\n format = format.replace(val.source, textValue);\n }\n return format;\n };\n Tooltip.prototype.formatPointValue = function (point, axis, dataValue, isXPoint, isYPoint) {\n var textValue;\n var customLabelFormat;\n var value;\n if (axis.valueType !== 'Category' && isXPoint) {\n customLabelFormat = axis.labelFormat && axis.labelFormat.match('{value}') !== null;\n textValue = customLabelFormat ? axis.labelFormat.replace('{value}', axis.format(point[dataValue])) :\n axis.format(point[dataValue]);\n }\n else if (isYPoint && !isNullOrUndefined(point[dataValue])) {\n customLabelFormat = axis.labelFormat && axis.labelFormat.match('{value}') !== null;\n value = dataValue === 'outliers' ? axis.format(point[dataValue][this.lierIndex - 4]) :\n axis.format(point[dataValue]);\n textValue = customLabelFormat ? axis.labelFormat.replace('{value}', value) : value;\n }\n else if (dataValue === 'size') {\n var format = this.chart.intl.getNumberFormat({ format: '', useGrouping: this.chart.useGroupingSeparator });\n textValue = typeof point[dataValue] === 'number' ? format(point[dataValue]) : point[dataValue];\n }\n else {\n textValue = point[dataValue];\n }\n return textValue;\n };\n Tooltip.prototype.getFormat = function (chart, series) {\n if (series.tooltipFormat) {\n if (series.seriesType === 'XY' && series.category === 'Indicator') {\n return this.getIndicatorTooltipFormat(series, chart, chart.tooltip.format);\n }\n return series.tooltipFormat;\n }\n if (!series.tooltipFormat && chart.tooltip.format) {\n if (series.seriesType === 'XY' && series.category === 'Indicator') {\n return this.getIndicatorTooltipFormat(series, chart, chart.tooltip.format);\n }\n return chart.tooltip.format;\n }\n var textX = (series.type === 'Histogram') ? '${point.minimum}' + '-' + '${point.maximum}' : '${point.x}';\n var format = !chart.tooltip.shared ? textX : '${series.name}';\n switch (series.seriesType) {\n case 'XY':\n if (series.category === 'Indicator') {\n this.getIndicatorTooltipFormat(series, chart, chart.tooltip.format);\n }\n return format + ' : ' + ((series.type === 'Bubble') ? '<b>${point.y}</b> Size : <b>${point.size}</b>' :\n '<b>${point.y}</b>');\n case 'HighLow':\n return format + ('<br/>High : <b>${point.high}</b><br/>Low : <b>${point.low}</b>');\n case 'HighLowOpenClose':\n return format + ('<br/>High : <b>${point.high}</b><br/>Low : <b>${point.low}</b><br/>' +\n 'Open : <b>${point.open}</b><br/>Close : <b>${point.close}</b>');\n case 'BoxPlot': {\n return format + '<br/>' + (this.lierIndex > 3 ? 'Outliers : <b>${point.outliers}</b>' :\n 'Maximum : <b>${point.maximum}</b><br/>Q3 : <b>${point.upperQuartile}</b><br/>' +\n 'Median : <b>${point.median}</b><br/>Q1 : <b>${point.lowerQuartile}</b><br/>Minimum : <b>${point.minimum}</b>');\n }\n default: return '';\n }\n };\n Tooltip.prototype.getIndicatorTooltipFormat = function (series, chart, format) {\n var toolTip;\n if (series.seriesType === 'XY') {\n toolTip = series.name + ' : <b>${point.y}</b>';\n }\n else {\n toolTip = format;\n }\n return toolTip;\n };\n /*\n * @hidden\n */\n Tooltip.prototype.removeHighlightedMarker = function (data, fadeOut) {\n for (var _i = 0, data_2 = data; _i < data_2.length; _i++) {\n var item = data_2[_i];\n removeElement(this.element.id + '_Series_' + item.series.index +\n '_Point_' + item.point.index + '_Trackball');\n if (this.chart.markerRender) {\n this.chart.markerRender.removeHighlightedMarker(item.series, item.point, fadeOut);\n }\n }\n this.previousPoints = [];\n };\n /**\n * Get module name.\n */\n Tooltip.prototype.getModuleName = function () {\n /**\n * Returns the module name\n */\n return 'Tooltip';\n };\n /**\n * To destroy the tooltip.\n *\n * @returns {void}\n * @private\n */\n Tooltip.prototype.destroy = function () {\n /**\n * Destroy method performed here\n */\n };\n return Tooltip;\n}(BaseTooltip));\nexport { Tooltip };\n","//! moment.js locale configuration\n//! locale : Belarusian [be]\n//! author : Dmitry Demidov : https://github.com/demidov91\n//! author: Praleska: http://praleska.pro/\n//! Author : Menelion Elensúle : https://github.com/Oire\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function plural(word, num) {\n var forms = word.split('_');\n return num % 10 === 1 && num % 100 !== 11\n ? forms[0]\n : num % 10 >= 2 && num % 10 <= 4 && (num % 100 < 10 || num % 100 >= 20)\n ? forms[1]\n : forms[2];\n }\n function relativeTimeWithPlural(number, withoutSuffix, key) {\n var format = {\n ss: withoutSuffix ? 'Ñекунда_Ñекунды_Ñекунд' : 'Ñекунду_Ñекунды_Ñекунд',\n mm: withoutSuffix ? 'хвіліна_хвіліны_хвілін' : 'хвіліну_хвіліны_хвілін',\n hh: withoutSuffix ? 'гадзіна_гадзіны_гадзін' : 'гадзіну_гадзіны_гадзін',\n dd: 'дзень_дні_дзён',\n MM: 'меÑÑц_меÑÑцы_меÑÑцаў',\n yy: 'год_гады_гадоў',\n };\n if (key === 'm') {\n return withoutSuffix ? 'хвіліна' : 'хвіліну';\n } else if (key === 'h') {\n return withoutSuffix ? 'гадзіна' : 'гадзіну';\n } else {\n return number + ' ' + plural(format[key], +number);\n }\n }\n\n var be = moment.defineLocale('be', {\n months: {\n format: 'ÑтудзенÑ_лютага_Ñакавіка_краÑавіка_траўнÑ_чÑрвенÑ_ліпенÑ_жніўнÑ_вераÑнÑ_каÑтрычніка_ліÑтапада_ÑнежнÑ'.split(\n '_'\n ),\n standalone:\n 'Ñтудзень_люты_Ñакавік_краÑавік_травень_чÑрвень_ліпень_жнівень_вераÑень_каÑтрычнік_ліÑтапад_Ñнежань'.split(\n '_'\n ),\n },\n monthsShort:\n 'Ñтуд_лют_Ñак_краÑ_трав_чÑрв_ліп_жнів_вер_каÑÑ‚_ліÑÑ‚_Ñнеж'.split('_'),\n weekdays: {\n format: 'нÑдзелю_панÑдзелак_аўторак_Ñераду_чацвер_пÑтніцу_Ñуботу'.split(\n '_'\n ),\n standalone:\n 'нÑдзелÑ_панÑдзелак_аўторак_Ñерада_чацвер_пÑтніца_Ñубота'.split(\n '_'\n ),\n isFormat: /\\[ ?[Ууў] ?(?:мінулую|наÑтупную)? ?\\] ?dddd/,\n },\n weekdaysShort: 'нд_пн_ат_ÑÑ€_чц_пт_Ñб'.split('_'),\n weekdaysMin: 'нд_пн_ат_ÑÑ€_чц_пт_Ñб'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY г.',\n LLL: 'D MMMM YYYY г., HH:mm',\n LLLL: 'dddd, D MMMM YYYY г., HH:mm',\n },\n calendar: {\n sameDay: '[Ð¡Ñ‘Ð½Ð½Ñ Ñž] LT',\n nextDay: '[Заўтра Ñž] LT',\n lastDay: '[Учора Ñž] LT',\n nextWeek: function () {\n return '[У] dddd [Ñž] LT';\n },\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n case 3:\n case 5:\n case 6:\n return '[У мінулую] dddd [Ñž] LT';\n case 1:\n case 2:\n case 4:\n return '[У мінулы] dddd [Ñž] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'праз %s',\n past: '%s таму',\n s: 'некалькі Ñекунд',\n m: relativeTimeWithPlural,\n mm: relativeTimeWithPlural,\n h: relativeTimeWithPlural,\n hh: relativeTimeWithPlural,\n d: 'дзень',\n dd: relativeTimeWithPlural,\n M: 'меÑÑц',\n MM: relativeTimeWithPlural,\n y: 'год',\n yy: relativeTimeWithPlural,\n },\n meridiemParse: /ночы|раніцы|днÑ|вечара/,\n isPM: function (input) {\n return /^(днÑ|вечара)$/.test(input);\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'ночы';\n } else if (hour < 12) {\n return 'раніцы';\n } else if (hour < 17) {\n return 'днÑ';\n } else {\n return 'вечара';\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(Ñ–|Ñ‹|га)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'M':\n case 'd':\n case 'DDD':\n case 'w':\n case 'W':\n return (number % 10 === 2 || number % 10 === 3) &&\n number % 100 !== 12 &&\n number % 100 !== 13\n ? number + '-Ñ–'\n : number + '-Ñ‹';\n case 'D':\n return number + '-га';\n default:\n return number;\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return be;\n\n})));\n","//! moment.js locale configuration\n//! locale : Georgian [ka]\n//! author : Irakli Janiashvili : https://github.com/IrakliJani\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ka = moment.defineLocale('ka', {\n months: 'იáƒáƒœáƒ•áƒáƒ ი_თებერვáƒáƒšáƒ˜_მáƒáƒ ტი_áƒáƒžáƒ ილი_მáƒáƒ˜áƒ¡áƒ˜_ივნისი_ივლისი_áƒáƒ’ვისტáƒ_სექტემბერი_áƒáƒ¥áƒ¢áƒáƒ›áƒ‘ერი_ნáƒáƒ”მბერი_დეკემბერი'.split(\n '_'\n ),\n monthsShort: 'იáƒáƒœ_თებ_მáƒáƒ _áƒáƒžáƒ _მáƒáƒ˜_ივნ_ივლ_áƒáƒ’ვ_სექ_áƒáƒ¥áƒ¢_ნáƒáƒ”_დეკ'.split('_'),\n weekdays: {\n standalone:\n 'კვირáƒ_áƒáƒ შáƒáƒ‘áƒáƒ—ი_სáƒáƒ›áƒ¨áƒáƒ‘áƒáƒ—ი_áƒáƒ—ხშáƒáƒ‘áƒáƒ—ი_ხუთშáƒáƒ‘áƒáƒ—ი_პáƒáƒ áƒáƒ¡áƒ™áƒ”ვი_შáƒáƒ‘áƒáƒ—ი'.split(\n '_'\n ),\n format: 'კვირáƒáƒ¡_áƒáƒ შáƒáƒ‘áƒáƒ—ს_სáƒáƒ›áƒ¨áƒáƒ‘áƒáƒ—ს_áƒáƒ—ხშáƒáƒ‘áƒáƒ—ს_ხუთშáƒáƒ‘áƒáƒ—ს_პáƒáƒ áƒáƒ¡áƒ™áƒ”ვს_შáƒáƒ‘áƒáƒ—ს'.split(\n '_'\n ),\n isFormat: /(წინáƒ|შემდეგ)/,\n },\n weekdaysShort: 'კვი_áƒáƒ შ_სáƒáƒ›_áƒáƒ—ხ_ხუთ_პáƒáƒ _შáƒáƒ‘'.split('_'),\n weekdaysMin: 'კვ_áƒáƒ _სáƒ_áƒáƒ—_ხუ_პáƒ_შáƒ'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[დღეს] LT[-ზე]',\n nextDay: '[ხვáƒáƒš] LT[-ზე]',\n lastDay: '[გუშინ] LT[-ზე]',\n nextWeek: '[შემდეგ] dddd LT[-ზე]',\n lastWeek: '[წინáƒ] dddd LT-ზე',\n sameElse: 'L',\n },\n relativeTime: {\n future: function (s) {\n return s.replace(\n /(წáƒáƒ›|წუთ|სáƒáƒáƒ—|წელ|დღ|თვ)(ი|ე)/,\n function ($0, $1, $2) {\n return $2 === 'ი' ? $1 + 'ში' : $1 + $2 + 'ში';\n }\n );\n },\n past: function (s) {\n if (/(წáƒáƒ›áƒ˜|წუთი|სáƒáƒáƒ—ი|დღე|თვე)/.test(s)) {\n return s.replace(/(ი|ე)$/, 'ის წინ');\n }\n if (/წელი/.test(s)) {\n return s.replace(/წელი$/, 'წლის წინ');\n }\n return s;\n },\n s: 'რáƒáƒ›áƒ“ენიმე წáƒáƒ›áƒ˜',\n ss: '%d წáƒáƒ›áƒ˜',\n m: 'წუთი',\n mm: '%d წუთი',\n h: 'სáƒáƒáƒ—ი',\n hh: '%d სáƒáƒáƒ—ი',\n d: 'დღე',\n dd: '%d დღე',\n M: 'თვე',\n MM: '%d თვე',\n y: 'წელი',\n yy: '%d წელი',\n },\n dayOfMonthOrdinalParse: /0|1-ლი|მე-\\d{1,2}|\\d{1,2}-ე/,\n ordinal: function (number) {\n if (number === 0) {\n return number;\n }\n if (number === 1) {\n return number + '-ლი';\n }\n if (\n number < 20 ||\n (number <= 100 && number % 20 === 0) ||\n number % 100 === 0\n ) {\n return 'მე-' + number;\n }\n return number + '-ე';\n },\n week: {\n dow: 1,\n doy: 7,\n },\n });\n\n return ka;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { DataManager, Query, Deferred, Predicate, DataUtil } from '@syncfusion/ej2-data';\nimport { initForeignKeyColumn, getForeignKeyData, generateQuery } from '../base/constant';\nimport { getDatePredicate } from '../base/util';\nimport { Data } from './data';\nimport * as events from '../base/constant';\n/**\n * `ForeignKey` module is used to handle foreign key column's actions.\n */\nvar ForeignKey = /** @class */ (function (_super) {\n __extends(ForeignKey, _super);\n function ForeignKey(parent, serviceLocator) {\n var _this = _super.call(this, parent, serviceLocator) || this;\n _this.parent = parent;\n _this.serviceLocator = serviceLocator;\n _this.initEvent();\n return _this;\n }\n ForeignKey.prototype.initEvent = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(initForeignKeyColumn, this.initForeignKeyColumns, this);\n this.parent.on(getForeignKeyData, this.getForeignKeyData, this);\n this.parent.on(generateQuery, this.generateQueryFormData, this);\n };\n ForeignKey.prototype.initForeignKeyColumns = function (columns) {\n for (var i = 0; i < columns.length; i++) {\n columns[parseInt(i.toString(), 10)].dataSource = (columns[parseInt(i.toString(), 10)].dataSource instanceof DataManager ?\n columns[parseInt(i.toString(), 10)].dataSource :\n (isNullOrUndefined(columns[parseInt(i.toString(), 10)].dataSource) ? new DataManager() :\n 'result' in columns[parseInt(i.toString(), 10)].dataSource ? columns[parseInt(i.toString(), 10)].dataSource :\n new DataManager(columns[parseInt(i.toString(), 10)].dataSource)));\n }\n };\n ForeignKey.prototype.eventfPromise = function (args, query, key, column) {\n var state = this.getStateEventArgument(query);\n var def = new Deferred();\n var deff = new Deferred();\n state.action = args.action;\n var dataModule = this.parent.getDataModule();\n if (!isNullOrUndefined(args.action) && args.action.requestType && dataModule.foreignKeyDataState.isDataChanged !== false) {\n dataModule.setForeignKeyDataState({\n isPending: true, resolver: deff.resolve\n });\n deff.promise.then(function () {\n def.resolve(column.dataSource);\n });\n state.setColumnData = this.parent.setForeignKeyData.bind(this.parent);\n this.parent.trigger(events.columnDataStateChange, state);\n }\n else {\n dataModule.setForeignKeyDataState({});\n def.resolve(key);\n }\n return def;\n };\n ForeignKey.prototype.getForeignKeyData = function (args) {\n var _this = this;\n var foreignColumns = args.column ? [args.column] : this.parent.getForeignKeyColumns();\n var allPromise = [];\n var _loop_1 = function (i) {\n var promise = void 0;\n var query = args.isComplex ? this_1.genarateColumnQuery(foreignColumns[parseInt(i.toString(), 10)]) :\n this_1.genarateQuery(foreignColumns[parseInt(i.toString(), 10)], args.result.result, false, true);\n query.params = this_1.parent.query.params;\n var dataSource = foreignColumns[parseInt(i.toString(), 10)].dataSource;\n if (dataSource && 'result' in dataSource) {\n var def = this_1.eventfPromise(args, query, dataSource, foreignColumns[parseInt(i.toString(), 10)]);\n promise = def.promise;\n }\n else if (!dataSource.ready || dataSource.dataSource.offline) {\n promise = dataSource.executeQuery(query);\n }\n else {\n promise = dataSource.ready.then(function () {\n return dataSource.executeQuery(query);\n });\n }\n allPromise.push(promise);\n };\n var this_1 = this;\n for (var i = 0; i < foreignColumns.length; i++) {\n _loop_1(i);\n }\n Promise.all(allPromise).then(function (responses) {\n for (var i = 0; i < responses.length; i++) {\n foreignColumns[parseInt(i.toString(), 10)].columnData = responses[parseInt(i.toString(), 10)].result;\n if (foreignColumns[parseInt(i.toString(), 10)].editType === 'dropdownedit' && 'result' in foreignColumns[parseInt(i.toString(), 10)].dataSource) {\n foreignColumns[parseInt(i.toString(), 10)].edit.params = extend(foreignColumns[parseInt(i.toString(), 10)]\n .edit.params, {\n dataSource: responses[parseInt(i.toString(), 10)].result,\n query: new Query(), fields: {\n value: foreignColumns[parseInt(i.toString(), 10)].foreignKeyField ||\n foreignColumns[parseInt(i.toString(), 10)].field,\n text: foreignColumns[parseInt(i.toString(), 10)].foreignKeyValue\n }\n });\n }\n }\n args.promise.resolve(args.result);\n }).catch(function (e) {\n _this.parent.log(['actionfailure', 'foreign_key_failure']);\n if (args.promise && args.promise.reject) {\n args.promise.reject(e);\n }\n return e;\n });\n };\n ForeignKey.prototype.generateQueryFormData = function (args) {\n args.predicate.predicate = this.genarateQuery(args.column, args.column.columnData, true);\n };\n ForeignKey.prototype.genarateQuery = function (column, e, fromData, needQuery) {\n var gObj = this.parent;\n var predicates = [];\n var query = new Query();\n var field = fromData ? column.foreignKeyField : column.field;\n if (gObj.allowPaging || gObj.enableVirtualization || fromData) {\n e = new DataManager(((gObj.allowGrouping && gObj.groupSettings.columns.length && !fromData) ?\n e.records : e)).executeLocal(new Query().select(field));\n var filteredValue = DataUtil.distinct(e, field, false);\n field = fromData ? column.field : column.foreignKeyField;\n for (var i = 0; i < filteredValue.length; i++) {\n if (filteredValue[parseInt(i.toString(), 10)] && filteredValue[parseInt(i.toString(), 10)].getDay) {\n predicates.push(getDatePredicate({ field: field, operator: 'equal', value: filteredValue[parseInt(i.toString(), 10)], matchCase: false }));\n }\n else {\n predicates.push(new Predicate(field, 'equal', filteredValue[parseInt(i.toString(), 10)], false));\n }\n }\n }\n if (needQuery) {\n return predicates.length ? query.where(Predicate.or(predicates)) : query;\n }\n return (predicates.length ? Predicate.or(predicates) : { predicates: [] });\n };\n ForeignKey.prototype.genarateColumnQuery = function (column) {\n var gObj = this.parent;\n var query = new Query();\n var queryColumn = this.isFiltered(column);\n if (queryColumn.isTrue) {\n query = this.filterQuery(query, queryColumn.column, true);\n }\n if (gObj.searchSettings.key.length) {\n var sSettings = gObj.searchSettings;\n if (column.dataSource instanceof DataManager && (column.dataSource.adaptor.getModuleName &&\n column.dataSource.adaptor.getModuleName() === 'ODataV4Adaptor')) {\n query = this.searchQuery(query, column, true);\n }\n else {\n query.search(sSettings.key, column.foreignKeyValue, sSettings.operator, sSettings.ignoreCase);\n }\n }\n return query;\n };\n ForeignKey.prototype.isFiltered = function (column) {\n var filterColumn = this.parent.filterSettings.columns.filter(function (fColumn) {\n return (fColumn.field === column.foreignKeyValue && fColumn.uid === column.uid);\n });\n return {\n column: filterColumn, isTrue: !!filterColumn.length\n };\n };\n ForeignKey.prototype.getModuleName = function () {\n return 'foreignKey';\n };\n ForeignKey.prototype.destroy = function () {\n this.destroyEvent();\n };\n ForeignKey.prototype.destroyEvent = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(initForeignKeyColumn, this.initForeignKeyColumns);\n this.parent.off(getForeignKeyData, this.getForeignKeyData);\n this.parent.off(generateQuery, this.generateQueryFormData);\n };\n return ForeignKey;\n}(Data));\nexport { ForeignKey };\n","//! moment.js locale configuration\n//! locale : Korean [ko]\n//! author : Kyungwook, Park : https://github.com/kyungw00k\n//! author : Jeeeyul Lee <jeeeyul@gmail.com>\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ko = moment.defineLocale('ko', {\n months: '1ì›”_2ì›”_3ì›”_4ì›”_5ì›”_6ì›”_7ì›”_8ì›”_9ì›”_10ì›”_11ì›”_12ì›”'.split('_'),\n monthsShort: '1ì›”_2ì›”_3ì›”_4ì›”_5ì›”_6ì›”_7ì›”_8ì›”_9ì›”_10ì›”_11ì›”_12ì›”'.split(\n '_'\n ),\n weekdays: 'ì¼ìš”ì¼_월요ì¼_화요ì¼_수요ì¼_목요ì¼_금요ì¼_í† ìš”ì¼'.split('_'),\n weekdaysShort: 'ì¼_ì›”_í™”_수_목_금_í† '.split('_'),\n weekdaysMin: 'ì¼_ì›”_í™”_수_목_금_í† '.split('_'),\n longDateFormat: {\n LT: 'A h:mm',\n LTS: 'A h:mm:ss',\n L: 'YYYY.MM.DD.',\n LL: 'YYYYë…„ MMMM Dì¼',\n LLL: 'YYYYë…„ MMMM Dì¼ A h:mm',\n LLLL: 'YYYYë…„ MMMM Dì¼ dddd A h:mm',\n l: 'YYYY.MM.DD.',\n ll: 'YYYYë…„ MMMM Dì¼',\n lll: 'YYYYë…„ MMMM Dì¼ A h:mm',\n llll: 'YYYYë…„ MMMM Dì¼ dddd A h:mm',\n },\n calendar: {\n sameDay: '오늘 LT',\n nextDay: 'ë‚´ì¼ LT',\n nextWeek: 'dddd LT',\n lastDay: 'ì–´ì œ LT',\n lastWeek: '지난주 dddd LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s 후',\n past: '%s ì „',\n s: '몇 ì´ˆ',\n ss: '%dì´ˆ',\n m: '1분',\n mm: '%d분',\n h: 'í•œ 시간',\n hh: '%d시간',\n d: '하루',\n dd: '%dì¼',\n M: 'í•œ 달',\n MM: '%d달',\n y: 'ì¼ ë…„',\n yy: '%dë…„',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(ì¼|ì›”|주)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'DDD':\n return number + 'ì¼';\n case 'M':\n return number + 'ì›”';\n case 'w':\n case 'W':\n return number + '주';\n default:\n return number;\n }\n },\n meridiemParse: /ì˜¤ì „|오후/,\n isPM: function (token) {\n return token === '오후';\n },\n meridiem: function (hour, minute, isUpper) {\n return hour < 12 ? 'ì˜¤ì „' : '오후';\n },\n });\n\n return ko;\n\n})));\n","//! moment.js locale configuration\n//! locale : Kurdish [ku]\n//! author : Shahram Mebashar : https://github.com/ShahramMebashar\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: 'Ù¡',\n 2: 'Ù¢',\n 3: 'Ù£',\n 4: 'Ù¤',\n 5: 'Ù¥',\n 6: 'Ù¦',\n 7: 'Ù§',\n 8: 'Ù¨',\n 9: 'Ù©',\n 0: 'Ù ',\n },\n numberMap = {\n 'Ù¡': '1',\n 'Ù¢': '2',\n 'Ù£': '3',\n 'Ù¤': '4',\n 'Ù¥': '5',\n 'Ù¦': '6',\n 'Ù§': '7',\n 'Ù¨': '8',\n 'Ù©': '9',\n 'Ù ': '0',\n },\n months = [\n 'کانونی دووەم',\n 'شوبات',\n 'ئازار',\n 'نیسان',\n 'ئایار',\n 'Øوزەیران',\n 'تەمموز',\n 'ئاب',\n 'ئەیلوول',\n 'تشرینی یەكەم',\n 'تشرینی دووەم',\n 'كانونی یەکەم',\n ];\n\n var ku = moment.defineLocale('ku', {\n months: months,\n monthsShort: months,\n weekdays:\n 'یه‌كشه‌ممه‌_دووشه‌ممه‌_سێشه‌ممه‌_چوارشه‌ممه‌_پێنجشه‌ممه‌_هه‌ینی_شه‌ممه‌'.split(\n '_'\n ),\n weekdaysShort:\n 'یه‌كشه‌م_دووشه‌م_سێشه‌م_چوارشه‌م_پێنجشه‌م_هه‌ینی_شه‌ممه‌'.split('_'),\n weekdaysMin: 'ÛŒ_د_س_Ú†_Ù¾_Ù‡_Ø´'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n meridiemParse: /ئێواره‌|به‌یانی/,\n isPM: function (input) {\n return /ئێواره‌/.test(input);\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'به‌یانی';\n } else {\n return 'ئێواره‌';\n }\n },\n calendar: {\n sameDay: '[ئه‌مرۆ كاتژمێر] LT',\n nextDay: '[به‌یانی كاتژمێر] LT',\n nextWeek: 'dddd [كاتژمێر] LT',\n lastDay: '[دوێنێ كاتژمێر] LT',\n lastWeek: 'dddd [كاتژمێر] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'له‌ %s',\n past: '%s',\n s: 'چه‌ند چركه‌یه‌ك',\n ss: 'چركه‌ %d',\n m: 'یه‌ك خوله‌ك',\n mm: '%d خوله‌ك',\n h: 'یه‌ك كاتژمێر',\n hh: '%d كاتژمێر',\n d: 'یه‌ك Ú•Û†Ú˜',\n dd: '%d Ú•Û†Ú˜',\n M: 'یه‌ك مانگ',\n MM: '%d مانگ',\n y: 'یه‌ك ساڵ',\n yy: '%d ساڵ',\n },\n preparse: function (string) {\n return string\n .replace(/[١٢٣٤٥٦٧٨٩٠]/g, function (match) {\n return numberMap[match];\n })\n .replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string\n .replace(/\\d/g, function (match) {\n return symbolMap[match];\n })\n .replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 6, // Saturday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return ku;\n\n})));\n","//! moment.js locale configuration\n//! locale : Bosnian [bs]\n//! author : Nedim Cholich : https://github.com/frontyard\n//! based on (hr) translation by Bojan Marković\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function translate(number, withoutSuffix, key) {\n var result = number + ' ';\n switch (key) {\n case 'ss':\n if (number === 1) {\n result += 'sekunda';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'sekunde';\n } else {\n result += 'sekundi';\n }\n return result;\n case 'm':\n return withoutSuffix ? 'jedna minuta' : 'jedne minute';\n case 'mm':\n if (number === 1) {\n result += 'minuta';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'minute';\n } else {\n result += 'minuta';\n }\n return result;\n case 'h':\n return withoutSuffix ? 'jedan sat' : 'jednog sata';\n case 'hh':\n if (number === 1) {\n result += 'sat';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'sata';\n } else {\n result += 'sati';\n }\n return result;\n case 'dd':\n if (number === 1) {\n result += 'dan';\n } else {\n result += 'dana';\n }\n return result;\n case 'MM':\n if (number === 1) {\n result += 'mjesec';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'mjeseca';\n } else {\n result += 'mjeseci';\n }\n return result;\n case 'yy':\n if (number === 1) {\n result += 'godina';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'godine';\n } else {\n result += 'godina';\n }\n return result;\n }\n }\n\n var bs = moment.defineLocale('bs', {\n months: 'januar_februar_mart_april_maj_juni_juli_august_septembar_oktobar_novembar_decembar'.split(\n '_'\n ),\n monthsShort:\n 'jan._feb._mar._apr._maj._jun._jul._aug._sep._okt._nov._dec.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'nedjelja_ponedjeljak_utorak_srijeda_Äetvrtak_petak_subota'.split(\n '_'\n ),\n weekdaysShort: 'ned._pon._uto._sri._Äet._pet._sub.'.split('_'),\n weekdaysMin: 'ne_po_ut_sr_Äe_pe_su'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY H:mm',\n LLLL: 'dddd, D. MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[danas u] LT',\n nextDay: '[sutra u] LT',\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[u] [nedjelju] [u] LT';\n case 3:\n return '[u] [srijedu] [u] LT';\n case 6:\n return '[u] [subotu] [u] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[u] dddd [u] LT';\n }\n },\n lastDay: '[juÄer u] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n case 3:\n return '[proÅ¡lu] dddd [u] LT';\n case 6:\n return '[proÅ¡le] [subote] [u] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[proÅ¡li] dddd [u] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'za %s',\n past: 'prije %s',\n s: 'par sekundi',\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: 'dan',\n dd: translate,\n M: 'mjesec',\n MM: translate,\n y: 'godinu',\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return bs;\n\n})));\n","//! moment.js locale configuration\n//! locale : Lithuanian [lt]\n//! author : Mindaugas MozÅ«ras : https://github.com/mmozuras\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var units = {\n ss: 'sekundÄ—_sekundžių_sekundes',\n m: 'minutÄ—_minutÄ—s_minutÄ™',\n mm: 'minutÄ—s_minuÄių_minutes',\n h: 'valanda_valandos_valandÄ…',\n hh: 'valandos_valandų_valandas',\n d: 'diena_dienos_dienÄ…',\n dd: 'dienos_dienų_dienas',\n M: 'mÄ—nuo_mÄ—nesio_mÄ—nesį',\n MM: 'mÄ—nesiai_mÄ—nesių_mÄ—nesius',\n y: 'metai_metų_metus',\n yy: 'metai_metų_metus',\n };\n function translateSeconds(number, withoutSuffix, key, isFuture) {\n if (withoutSuffix) {\n return 'kelios sekundÄ—s';\n } else {\n return isFuture ? 'kelių sekundžių' : 'kelias sekundes';\n }\n }\n function translateSingular(number, withoutSuffix, key, isFuture) {\n return withoutSuffix\n ? forms(key)[0]\n : isFuture\n ? forms(key)[1]\n : forms(key)[2];\n }\n function special(number) {\n return number % 10 === 0 || (number > 10 && number < 20);\n }\n function forms(key) {\n return units[key].split('_');\n }\n function translate(number, withoutSuffix, key, isFuture) {\n var result = number + ' ';\n if (number === 1) {\n return (\n result + translateSingular(number, withoutSuffix, key[0], isFuture)\n );\n } else if (withoutSuffix) {\n return result + (special(number) ? forms(key)[1] : forms(key)[0]);\n } else {\n if (isFuture) {\n return result + forms(key)[1];\n } else {\n return result + (special(number) ? forms(key)[1] : forms(key)[2]);\n }\n }\n }\n var lt = moment.defineLocale('lt', {\n months: {\n format: 'sausio_vasario_kovo_balandžio_gegužės_birželio_liepos_rugpjÅ«Äio_rugsÄ—jo_spalio_lapkriÄio_gruodžio'.split(\n '_'\n ),\n standalone:\n 'sausis_vasaris_kovas_balandis_gegužė_birželis_liepa_rugpjÅ«tis_rugsÄ—jis_spalis_lapkritis_gruodis'.split(\n '_'\n ),\n isFormat: /D[oD]?(\\[[^\\[\\]]*\\]|\\s)+MMMM?|MMMM?(\\[[^\\[\\]]*\\]|\\s)+D[oD]?/,\n },\n monthsShort: 'sau_vas_kov_bal_geg_bir_lie_rgp_rgs_spa_lap_grd'.split('_'),\n weekdays: {\n format: 'sekmadienį_pirmadienį_antradienį_treÄiadienį_ketvirtadienį_penktadienį_Å¡eÅ¡tadienį'.split(\n '_'\n ),\n standalone:\n 'sekmadienis_pirmadienis_antradienis_treÄiadienis_ketvirtadienis_penktadienis_Å¡eÅ¡tadienis'.split(\n '_'\n ),\n isFormat: /dddd HH:mm/,\n },\n weekdaysShort: 'Sek_Pir_Ant_Tre_Ket_Pen_Å eÅ¡'.split('_'),\n weekdaysMin: 'S_P_A_T_K_Pn_Å '.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY-MM-DD',\n LL: 'YYYY [m.] MMMM D [d.]',\n LLL: 'YYYY [m.] MMMM D [d.], HH:mm [val.]',\n LLLL: 'YYYY [m.] MMMM D [d.], dddd, HH:mm [val.]',\n l: 'YYYY-MM-DD',\n ll: 'YYYY [m.] MMMM D [d.]',\n lll: 'YYYY [m.] MMMM D [d.], HH:mm [val.]',\n llll: 'YYYY [m.] MMMM D [d.], ddd, HH:mm [val.]',\n },\n calendar: {\n sameDay: '[Å iandien] LT',\n nextDay: '[Rytoj] LT',\n nextWeek: 'dddd LT',\n lastDay: '[Vakar] LT',\n lastWeek: '[PraÄ—jusį] dddd LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'po %s',\n past: 'prieÅ¡ %s',\n s: translateSeconds,\n ss: translate,\n m: translateSingular,\n mm: translate,\n h: translateSingular,\n hh: translate,\n d: translateSingular,\n dd: translate,\n M: translateSingular,\n MM: translate,\n y: translateSingular,\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-oji/,\n ordinal: function (number) {\n return number + '-oji';\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return lt;\n\n})));\n","/* eslint-disable */\nimport { Encoding } from '@syncfusion/ej2-file-utils';\n/**\n * array literal codes\n */\nvar ARR_LITERAL_CODES = new Int16Array(286);\nvar ARR_LITERAL_LENGTHS = new Uint8Array(286);\nvar ARR_DISTANCE_CODES = new Int16Array(30);\nvar ARR_DISTANCE_LENGTHS = new Uint8Array(30);\n/**\n * represent compression stream writer\n * ```typescript\n * let compressedWriter = new CompressedStreamWriter();\n * let text: string = 'Hello world!!!';\n * compressedWriter.write(text, 0, text.length);\n * compressedWriter.close();\n * ```\n */\nvar CompressedStreamWriter = /** @class */ (function () {\n /**\n * Initializes compressor and writes ZLib header if needed.\n * @param {boolean} noWrap - optional if true, ZLib header and checksum will not be written.\n */\n function CompressedStreamWriter(noWrap) {\n this.pendingBuffer = new Uint8Array(1 << 16);\n this.pendingBufLength = 0;\n this.pendingBufCache = 0;\n this.pendingBufBitsInCache = 0;\n this.bufferPosition = 0;\n this.extraBits = 0;\n this.currentHash = 0;\n this.matchStart = 0;\n this.matchLength = 0;\n this.matchPrevAvail = false;\n this.blockStart = 0;\n this.stringStart = 0;\n this.lookAhead = 0;\n this.totalBytesIn = 0;\n this.inputOffset = 0;\n this.inputEnd = 0;\n this.windowSize = 1 << 15;\n this.windowMask = this.windowSize - 1;\n this.hashSize = 1 << 15;\n this.hashMask = this.hashSize - 1;\n this.hashShift = Math.floor((15 + 3 - 1) / 3);\n this.maxDist = this.windowSize - 262;\n this.checkSum = 1;\n this.noWrap = false;\n if (!CompressedStreamWriter.isHuffmanTreeInitiated) {\n CompressedStreamWriter.initHuffmanTree();\n CompressedStreamWriter.isHuffmanTreeInitiated = true;\n }\n this.treeLiteral = new CompressorHuffmanTree(this, 286, 257, 15);\n this.treeDistances = new CompressorHuffmanTree(this, 30, 1, 15);\n this.treeCodeLengths = new CompressorHuffmanTree(this, 19, 4, 7);\n this.arrDistances = new Uint16Array((1 << 14));\n this.arrLiterals = new Uint8Array((1 << 14));\n this.stream = [];\n this.dataWindow = new Uint8Array(2 * this.windowSize);\n this.hashHead = new Int16Array(this.hashSize);\n this.hashPrevious = new Int16Array(this.windowSize);\n this.blockStart = this.stringStart = 1;\n this.noWrap = noWrap;\n if (!noWrap) {\n this.writeZLibHeader();\n }\n }\n Object.defineProperty(CompressedStreamWriter.prototype, \"compressedData\", {\n /**\n * get compressed data\n */\n get: function () {\n return this.stream;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(CompressedStreamWriter.prototype, \"getCompressedString\", {\n get: function () {\n var compressedString = '';\n if (this.stream !== undefined) {\n for (var i = 0; i < this.stream.length; i++) {\n compressedString += String.fromCharCode.apply(null, this.stream[i]);\n }\n }\n return compressedString;\n },\n enumerable: true,\n configurable: true\n });\n /**\n * Compresses data and writes it to the stream.\n * @param {Uint8Array} data - data to compress\n * @param {number} offset - offset in data\n * @param {number} length - length of the data\n * @returns {void}\n */\n CompressedStreamWriter.prototype.write = function (data, offset, length) {\n if (data === undefined || data === null) {\n throw new Error('ArgumentException: data cannot null or undefined');\n }\n var end = offset + length;\n if (0 > offset || offset > end || end > data.length) {\n throw new Error('ArgumentOutOfRangeException: Offset or length is incorrect');\n }\n if (typeof data === 'string') {\n var encode = new Encoding(false);\n encode.type = 'Utf8';\n data = new Uint8Array(encode.getBytes(data, 0, data.length));\n end = offset + data.length;\n }\n this.inputBuffer = data;\n this.inputOffset = offset;\n this.inputEnd = end;\n if (!this.noWrap) {\n this.checkSum = ChecksumCalculator.checksumUpdate(this.checkSum, this.inputBuffer, this.inputOffset, end);\n }\n while (!(this.inputEnd === this.inputOffset) || !(this.pendingBufLength === 0)) {\n this.pendingBufferFlush();\n this.compressData(false);\n }\n };\n /**\n * write ZLib header to the compressed data\n * @return {void}\n */\n CompressedStreamWriter.prototype.writeZLibHeader = function () {\n /* Initialize header.*/\n var headerDate = (8 + (7 << 4)) << 8;\n /* Save compression level.*/\n headerDate |= ((5 >> 2) & 3) << 6;\n /* Align header.*/\n headerDate += 31 - (headerDate % 31);\n /* Write header to stream.*/\n this.pendingBufferWriteShortBytes(headerDate);\n };\n /**\n * Write Most Significant Bytes in to stream\n * @param {number} s - check sum value\n */\n CompressedStreamWriter.prototype.pendingBufferWriteShortBytes = function (s) {\n this.pendingBuffer[this.pendingBufLength++] = s >> 8;\n this.pendingBuffer[this.pendingBufLength++] = s;\n };\n CompressedStreamWriter.prototype.compressData = function (finish) {\n var success;\n do {\n this.fillWindow();\n var canFlush = (finish && this.inputEnd === this.inputOffset);\n success = this.compressSlow(canFlush, finish);\n } while (this.pendingBufLength === 0 && success);\n return success;\n };\n CompressedStreamWriter.prototype.compressSlow = function (flush, finish) {\n if (this.lookAhead < 262 && !flush) {\n return false;\n }\n while (this.lookAhead >= 262 || flush) {\n if (this.lookAhead === 0) {\n return this.lookAheadCompleted(finish);\n }\n if (this.stringStart >= 2 * this.windowSize - 262) {\n this.slideWindow();\n }\n var prevMatch = this.matchStart;\n var prevLen = this.matchLength;\n if (this.lookAhead >= 3) {\n this.discardMatch();\n }\n if (prevLen >= 3 && this.matchLength <= prevLen) {\n prevLen = this.matchPreviousBest(prevMatch, prevLen);\n }\n else {\n this.matchPreviousAvailable();\n }\n if (this.bufferPosition >= (1 << 14)) {\n return this.huffmanIsFull(finish);\n }\n }\n return true;\n };\n CompressedStreamWriter.prototype.discardMatch = function () {\n var hashHead = this.insertString();\n if (hashHead !== 0 && this.stringStart - hashHead <= this.maxDist && this.findLongestMatch(hashHead)) {\n if (this.matchLength <= 5 && (this.matchLength === 3 && this.stringStart - this.matchStart > 4096)) {\n this.matchLength = 3 - 1;\n }\n }\n };\n CompressedStreamWriter.prototype.matchPreviousAvailable = function () {\n if (this.matchPrevAvail) {\n this.huffmanTallyLit(this.dataWindow[this.stringStart - 1] & 0xff);\n }\n this.matchPrevAvail = true;\n this.stringStart++;\n this.lookAhead--;\n };\n CompressedStreamWriter.prototype.matchPreviousBest = function (prevMatch, prevLen) {\n this.huffmanTallyDist(this.stringStart - 1 - prevMatch, prevLen);\n prevLen -= 2;\n do {\n this.stringStart++;\n this.lookAhead--;\n if (this.lookAhead >= 3) {\n this.insertString();\n }\n } while (--prevLen > 0);\n this.stringStart++;\n this.lookAhead--;\n this.matchPrevAvail = false;\n this.matchLength = 3 - 1;\n return prevLen;\n };\n CompressedStreamWriter.prototype.lookAheadCompleted = function (finish) {\n if (this.matchPrevAvail) {\n this.huffmanTallyLit(this.dataWindow[this.stringStart - 1] & 0xff);\n }\n this.matchPrevAvail = false;\n this.huffmanFlushBlock(this.dataWindow, this.blockStart, this.stringStart - this.blockStart, finish);\n this.blockStart = this.stringStart;\n return false;\n };\n CompressedStreamWriter.prototype.huffmanIsFull = function (finish) {\n var len = this.stringStart - this.blockStart;\n if (this.matchPrevAvail) {\n len--;\n }\n var lastBlock = (finish && this.lookAhead === 0 && !this.matchPrevAvail);\n this.huffmanFlushBlock(this.dataWindow, this.blockStart, len, lastBlock);\n this.blockStart += len;\n return !lastBlock;\n };\n CompressedStreamWriter.prototype.fillWindow = function () {\n if (this.stringStart >= this.windowSize + this.maxDist) {\n this.slideWindow();\n }\n while (this.lookAhead < 262 && this.inputOffset < this.inputEnd) {\n var more = 2 * this.windowSize - this.lookAhead - this.stringStart;\n if (more > this.inputEnd - this.inputOffset) {\n more = this.inputEnd - this.inputOffset;\n }\n this.dataWindow.set(this.inputBuffer.subarray(this.inputOffset, this.inputOffset + more), this.stringStart + this.lookAhead);\n this.inputOffset += more;\n this.totalBytesIn += more;\n this.lookAhead += more;\n }\n if (this.lookAhead >= 3) {\n this.updateHash();\n }\n };\n CompressedStreamWriter.prototype.slideWindow = function () {\n this.dataWindow.set(this.dataWindow.subarray(this.windowSize, this.windowSize + this.windowSize), 0);\n this.matchStart -= this.windowSize;\n this.stringStart -= this.windowSize;\n this.blockStart -= this.windowSize;\n for (var i = 0; i < this.hashSize; ++i) {\n var m = this.hashHead[i] & 0xffff;\n this.hashHead[i] = (((m >= this.windowSize) ? (m - this.windowSize) : 0));\n }\n for (var i = 0; i < this.windowSize; i++) {\n var m = this.hashPrevious[i] & 0xffff;\n this.hashPrevious[i] = ((m >= this.windowSize) ? (m - this.windowSize) : 0);\n }\n };\n CompressedStreamWriter.prototype.insertString = function () {\n var match;\n var hash = ((this.currentHash << this.hashShift) ^ this.dataWindow[this.stringStart + (3 - 1)]) & this.hashMask;\n this.hashPrevious[this.stringStart & this.windowMask] = match = this.hashHead[hash];\n this.hashHead[hash] = this.stringStart;\n this.currentHash = hash;\n return match & 0xffff;\n };\n CompressedStreamWriter.prototype.findLongestMatch = function (curMatch) {\n var chainLen = 4096;\n var niceLen = 258;\n var scan = this.stringStart;\n var match;\n var bestEnd = this.stringStart + this.matchLength;\n var bestLength = Math.max(this.matchLength, 3 - 1);\n var limit = Math.max(this.stringStart - this.maxDist, 0);\n var stringEnd = this.stringStart + 258 - 1;\n var scanEnd1 = this.dataWindow[bestEnd - 1];\n var scanEnd = this.dataWindow[bestEnd];\n var data = this.dataWindow;\n if (bestLength >= 32) {\n chainLen >>= 2;\n }\n if (niceLen > this.lookAhead) {\n niceLen = this.lookAhead;\n }\n do {\n if (data[curMatch + bestLength] !== scanEnd ||\n data[curMatch + bestLength - 1] !== scanEnd1 ||\n data[curMatch] !== data[scan] ||\n data[curMatch + 1] !== data[scan + 1]) {\n continue;\n }\n match = curMatch + 2;\n scan += 2;\n /* tslint:disable */\n while (data[++scan] === data[++match] && data[++scan] === data[++match] &&\n data[++scan] === data[++match] && data[++scan] === data[++match] &&\n data[++scan] === data[++match] && data[++scan] === data[++match] &&\n data[++scan] === data[++match] && data[++scan] === data[++match] && scan < stringEnd) {\n /* tslint:disable */\n }\n if (scan > bestEnd) {\n this.matchStart = curMatch;\n bestEnd = scan;\n bestLength = scan - this.stringStart;\n if (bestLength >= niceLen) {\n break;\n }\n scanEnd1 = data[bestEnd - 1];\n scanEnd = data[bestEnd];\n }\n scan = this.stringStart;\n } while ((curMatch = (this.hashPrevious[curMatch & this.windowMask] & 0xffff)) > limit && --chainLen !== 0);\n this.matchLength = Math.min(bestLength, this.lookAhead);\n return this.matchLength >= 3;\n };\n CompressedStreamWriter.prototype.updateHash = function () {\n this.currentHash = (this.dataWindow[this.stringStart] << this.hashShift) ^ this.dataWindow[this.stringStart + 1];\n };\n CompressedStreamWriter.prototype.huffmanTallyLit = function (literal) {\n this.arrDistances[this.bufferPosition] = 0;\n this.arrLiterals[this.bufferPosition++] = literal;\n this.treeLiteral.codeFrequencies[literal]++;\n return this.bufferPosition >= (1 << 14);\n };\n CompressedStreamWriter.prototype.huffmanTallyDist = function (dist, len) {\n this.arrDistances[this.bufferPosition] = dist;\n this.arrLiterals[this.bufferPosition++] = (len - 3);\n var lc = this.huffmanLengthCode(len - 3);\n this.treeLiteral.codeFrequencies[lc]++;\n if (lc >= 265 && lc < 285) {\n this.extraBits += Math.floor((lc - 261) / 4);\n }\n var dc = this.huffmanDistanceCode(dist - 1);\n this.treeDistances.codeFrequencies[dc]++;\n if (dc >= 4) {\n this.extraBits += Math.floor((dc / 2 - 1));\n }\n return this.bufferPosition >= (1 << 14);\n };\n CompressedStreamWriter.prototype.huffmanFlushBlock = function (stored, storedOffset, storedLength, lastBlock) {\n this.treeLiteral.codeFrequencies[256]++;\n this.treeLiteral.buildTree();\n this.treeDistances.buildTree();\n this.treeLiteral.calculateBLFreq(this.treeCodeLengths);\n this.treeDistances.calculateBLFreq(this.treeCodeLengths);\n this.treeCodeLengths.buildTree();\n var blTreeCodes = 4;\n for (var i = 18; i > blTreeCodes; i--) {\n if (this.treeCodeLengths.codeLengths[CompressorHuffmanTree.huffCodeLengthOrders[i]] > 0) {\n blTreeCodes = i + 1;\n }\n }\n var opt_len = 14 + blTreeCodes * 3 + this.treeCodeLengths.getEncodedLength() +\n this.treeLiteral.getEncodedLength() + this.treeDistances.getEncodedLength() + this.extraBits;\n var static_len = this.extraBits;\n for (var i = 0; i < 286; i++) {\n static_len += this.treeLiteral.codeFrequencies[i] * ARR_LITERAL_LENGTHS[i];\n }\n for (var i = 0; i < 30; i++) {\n static_len += this.treeDistances.codeFrequencies[i] * ARR_DISTANCE_LENGTHS[i];\n }\n if (opt_len >= static_len) {\n // Force static trees.\n opt_len = static_len;\n }\n if (storedOffset >= 0 && storedLength + 4 < opt_len >> 3) {\n this.huffmanFlushStoredBlock(stored, storedOffset, storedLength, lastBlock);\n }\n else if (opt_len == static_len) {\n // Encode with static tree.\n this.pendingBufferWriteBits((1 << 1) + (lastBlock ? 1 : 0), 3);\n this.treeLiteral.setStaticCodes(ARR_LITERAL_CODES, ARR_LITERAL_LENGTHS);\n this.treeDistances.setStaticCodes(ARR_DISTANCE_CODES, ARR_DISTANCE_LENGTHS);\n this.huffmanCompressBlock();\n this.huffmanReset();\n }\n else {\n this.pendingBufferWriteBits((2 << 1) + (lastBlock ? 1 : 0), 3);\n this.huffmanSendAllTrees(blTreeCodes);\n this.huffmanCompressBlock();\n this.huffmanReset();\n }\n };\n CompressedStreamWriter.prototype.huffmanFlushStoredBlock = function (stored, storedOffset, storedLength, lastBlock) {\n this.pendingBufferWriteBits((0 << 1) + (lastBlock ? 1 : 0), 3);\n this.pendingBufferAlignToByte();\n this.pendingBufferWriteShort(storedLength);\n this.pendingBufferWriteShort(~storedLength);\n this.pendingBufferWriteByteBlock(stored, storedOffset, storedLength);\n this.huffmanReset();\n };\n CompressedStreamWriter.prototype.huffmanLengthCode = function (len) {\n if (len === 255) {\n return 285;\n }\n var code = 257;\n while (len >= 8) {\n code += 4;\n len >>= 1;\n }\n return code + len;\n };\n CompressedStreamWriter.prototype.huffmanDistanceCode = function (distance) {\n var code = 0;\n while (distance >= 4) {\n code += 2;\n distance >>= 1;\n }\n return code + distance;\n };\n CompressedStreamWriter.prototype.huffmanSendAllTrees = function (blTreeCodes) {\n this.treeCodeLengths.buildCodes();\n this.treeLiteral.buildCodes();\n this.treeDistances.buildCodes();\n this.pendingBufferWriteBits(this.treeLiteral.treeLength - 257, 5);\n this.pendingBufferWriteBits(this.treeDistances.treeLength - 1, 5);\n this.pendingBufferWriteBits(blTreeCodes - 4, 4);\n for (var rank = 0; rank < blTreeCodes; rank++) {\n this.pendingBufferWriteBits(this.treeCodeLengths.codeLengths[CompressorHuffmanTree.huffCodeLengthOrders[rank]], 3);\n }\n this.treeLiteral.writeTree(this.treeCodeLengths);\n this.treeDistances.writeTree(this.treeCodeLengths);\n };\n CompressedStreamWriter.prototype.huffmanReset = function () {\n this.bufferPosition = 0;\n this.extraBits = 0;\n this.treeLiteral.reset();\n this.treeDistances.reset();\n this.treeCodeLengths.reset();\n };\n CompressedStreamWriter.prototype.huffmanCompressBlock = function () {\n for (var i = 0; i < this.bufferPosition; i++) {\n var literalLen = this.arrLiterals[i] & 255;\n var dist = this.arrDistances[i];\n if (dist-- !== 0) {\n var lc = this.huffmanLengthCode(literalLen);\n this.treeLiteral.writeCodeToStream(lc);\n var bits = Math.floor((lc - 261) / 4);\n if (bits > 0 && bits <= 5) {\n this.pendingBufferWriteBits(literalLen & ((1 << bits) - 1), bits);\n }\n var dc = this.huffmanDistanceCode(dist);\n this.treeDistances.writeCodeToStream(dc);\n bits = Math.floor(dc / 2 - 1);\n if (bits > 0) {\n this.pendingBufferWriteBits(dist & ((1 << bits) - 1), bits);\n }\n }\n else {\n this.treeLiteral.writeCodeToStream(literalLen);\n }\n }\n this.treeLiteral.writeCodeToStream(256);\n };\n /**\n * write bits in to internal buffer\n * @param {number} b - source of bits\n * @param {number} count - count of bits to write\n */\n CompressedStreamWriter.prototype.pendingBufferWriteBits = function (b, count) {\n var uint = new Uint32Array(1);\n uint[0] = this.pendingBufCache | (b << this.pendingBufBitsInCache);\n this.pendingBufCache = uint[0];\n this.pendingBufBitsInCache += count;\n this.pendingBufferFlushBits();\n };\n CompressedStreamWriter.prototype.pendingBufferFlush = function (isClose) {\n this.pendingBufferFlushBits();\n if (this.pendingBufLength > 0) {\n var array = new Uint8Array(this.pendingBufLength);\n array.set(this.pendingBuffer.subarray(0, this.pendingBufLength), 0);\n this.stream.push(array);\n }\n this.pendingBufLength = 0;\n };\n CompressedStreamWriter.prototype.pendingBufferFlushBits = function () {\n var result = 0;\n while (this.pendingBufBitsInCache >= 8 && this.pendingBufLength < (1 << 16)) {\n this.pendingBuffer[this.pendingBufLength++] = this.pendingBufCache;\n this.pendingBufCache >>= 8;\n this.pendingBufBitsInCache -= 8;\n result++;\n }\n return result;\n };\n CompressedStreamWriter.prototype.pendingBufferWriteByteBlock = function (data, offset, length) {\n var array = data.subarray(offset, offset + length);\n this.pendingBuffer.set(array, this.pendingBufLength);\n this.pendingBufLength += length;\n };\n CompressedStreamWriter.prototype.pendingBufferWriteShort = function (s) {\n this.pendingBuffer[this.pendingBufLength++] = s;\n this.pendingBuffer[this.pendingBufLength++] = (s >> 8);\n };\n CompressedStreamWriter.prototype.pendingBufferAlignToByte = function () {\n if (this.pendingBufBitsInCache > 0) {\n this.pendingBuffer[this.pendingBufLength++] = this.pendingBufCache;\n }\n this.pendingBufCache = 0;\n this.pendingBufBitsInCache = 0;\n };\n /**\n * Huffman Tree literal calculation\n * @private\n */\n CompressedStreamWriter.initHuffmanTree = function () {\n var i = 0;\n while (i < 144) {\n ARR_LITERAL_CODES[i] = CompressorHuffmanTree.bitReverse((0x030 + i) << 8);\n ARR_LITERAL_LENGTHS[i++] = 8;\n }\n while (i < 256) {\n ARR_LITERAL_CODES[i] = CompressorHuffmanTree.bitReverse((0x190 - 144 + i) << 7);\n ARR_LITERAL_LENGTHS[i++] = 9;\n }\n while (i < 280) {\n ARR_LITERAL_CODES[i] = CompressorHuffmanTree.bitReverse((0x000 - 256 + i) << 9);\n ARR_LITERAL_LENGTHS[i++] = 7;\n }\n while (i < 286) {\n ARR_LITERAL_CODES[i] = CompressorHuffmanTree.bitReverse((0x0c0 - 280 + i) << 8);\n ARR_LITERAL_LENGTHS[i++] = 8;\n }\n for (i = 0; i < 30; i++) {\n ARR_DISTANCE_CODES[i] = CompressorHuffmanTree.bitReverse(i << 11);\n ARR_DISTANCE_LENGTHS[i] = 5;\n }\n };\n /**\n * close the stream and write all pending buffer in to stream\n * @returns {void}\n */\n CompressedStreamWriter.prototype.close = function () {\n do {\n this.pendingBufferFlush(true);\n if (!this.compressData(true)) {\n this.pendingBufferFlush(true);\n this.pendingBufferAlignToByte();\n if (!this.noWrap) {\n this.pendingBufferWriteShortBytes(this.checkSum >> 16);\n this.pendingBufferWriteShortBytes(this.checkSum & 0xffff);\n }\n this.pendingBufferFlush(true);\n }\n } while (!(this.inputEnd === this.inputOffset) ||\n !(this.pendingBufLength === 0));\n };\n /**\n * release allocated un-managed resource\n * @returns {void}\n */\n CompressedStreamWriter.prototype.destroy = function () {\n this.stream = [];\n this.stream = undefined;\n this.pendingBuffer = undefined;\n this.treeLiteral = undefined;\n this.treeDistances = undefined;\n this.treeCodeLengths = undefined;\n this.arrLiterals = undefined;\n this.arrDistances = undefined;\n this.hashHead = undefined;\n this.hashPrevious = undefined;\n this.dataWindow = undefined;\n this.inputBuffer = undefined;\n this.pendingBufLength = undefined;\n this.pendingBufCache = undefined;\n this.pendingBufBitsInCache = undefined;\n this.bufferPosition = undefined;\n this.extraBits = undefined;\n this.currentHash = undefined;\n this.matchStart = undefined;\n this.matchLength = undefined;\n this.matchPrevAvail = undefined;\n this.blockStart = undefined;\n this.stringStart = undefined;\n this.lookAhead = undefined;\n this.totalBytesIn = undefined;\n this.inputOffset = undefined;\n this.inputEnd = undefined;\n this.windowSize = undefined;\n this.windowMask = undefined;\n this.hashSize = undefined;\n this.hashMask = undefined;\n this.hashShift = undefined;\n this.maxDist = undefined;\n this.checkSum = undefined;\n this.noWrap = undefined;\n };\n CompressedStreamWriter.isHuffmanTreeInitiated = false;\n return CompressedStreamWriter;\n}());\nexport { CompressedStreamWriter };\n/**\n * represent the Huffman Tree\n */\nvar CompressorHuffmanTree = /** @class */ (function () {\n /**\n * Create new Huffman Tree\n * @param {CompressedStreamWriter} writer instance\n * @param {number} elementCount - element count\n * @param {number} minCodes - minimum count\n * @param {number} maxLength - maximum count\n */\n function CompressorHuffmanTree(writer, elementCount, minCodes, maxLength) {\n this.writer = writer;\n this.codeMinCount = minCodes;\n this.maxLength = maxLength;\n this.codeFrequency = new Uint16Array(elementCount);\n this.lengthCount = new Int32Array(maxLength);\n }\n Object.defineProperty(CompressorHuffmanTree.prototype, \"treeLength\", {\n get: function () {\n return this.codeCount;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(CompressorHuffmanTree.prototype, \"codeLengths\", {\n get: function () {\n return this.codeLength;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(CompressorHuffmanTree.prototype, \"codeFrequencies\", {\n get: function () {\n return this.codeFrequency;\n },\n enumerable: true,\n configurable: true\n });\n CompressorHuffmanTree.prototype.setStaticCodes = function (codes, lengths) {\n var temp = new Int16Array(codes.length);\n temp.set(codes, 0);\n this.codes = temp;\n var lengthTemp = new Uint8Array(lengths.length);\n lengthTemp.set(lengths, 0);\n this.codeLength = lengthTemp;\n };\n /**\n * reset all code data in tree\n * @returns {void}\n */\n CompressorHuffmanTree.prototype.reset = function () {\n for (var i = 0; i < this.codeFrequency.length; i++) {\n this.codeFrequency[i] = 0;\n }\n this.codes = undefined;\n this.codeLength = undefined;\n };\n /**\n * write code to the compressor output stream\n * @param {number} code - code to be written\n * @returns {void}\n */\n CompressorHuffmanTree.prototype.writeCodeToStream = function (code) {\n this.writer.pendingBufferWriteBits(this.codes[code] & 0xffff, this.codeLength[code]);\n };\n /**\n * calculate code from their frequencies\n * @returns {void}\n */\n CompressorHuffmanTree.prototype.buildCodes = function () {\n var nextCode = new Int32Array(this.maxLength);\n this.codes = new Int16Array(this.codeCount);\n var code = 0;\n for (var bitsCount = 0; bitsCount < this.maxLength; bitsCount++) {\n nextCode[bitsCount] = code;\n code += this.lengthCount[bitsCount] << (15 - bitsCount);\n }\n for (var i = 0; i < this.codeCount; i++) {\n var bits = this.codeLength[i];\n if (bits > 0) {\n this.codes[i] = CompressorHuffmanTree.bitReverse(nextCode[bits - 1]);\n nextCode[bits - 1] += 1 << (16 - bits);\n }\n }\n };\n CompressorHuffmanTree.bitReverse = function (value) {\n return (CompressorHuffmanTree.reverseBits[value & 15] << 12\n | CompressorHuffmanTree.reverseBits[(value >> 4) & 15] << 8\n | CompressorHuffmanTree.reverseBits[(value >> 8) & 15] << 4\n | CompressorHuffmanTree.reverseBits[value >> 12]);\n };\n /**\n * calculate length of compressed data\n * @returns {number}\n */\n CompressorHuffmanTree.prototype.getEncodedLength = function () {\n var len = 0;\n for (var i = 0; i < this.codeFrequency.length; i++) {\n len += this.codeFrequency[i] * this.codeLength[i];\n }\n return len;\n };\n /**\n * calculate code frequencies\n * @param {CompressorHuffmanTree} blTree\n * @returns {void}\n */\n CompressorHuffmanTree.prototype.calculateBLFreq = function (blTree) {\n var maxCount;\n var minCount;\n var count;\n var curLen = -1;\n var i = 0;\n while (i < this.codeCount) {\n count = 1;\n var nextLen = this.codeLength[i];\n if (nextLen === 0) {\n maxCount = 138;\n minCount = 3;\n }\n else {\n maxCount = 6;\n minCount = 3;\n if (curLen !== nextLen) {\n blTree.codeFrequency[nextLen]++;\n count = 0;\n }\n }\n curLen = nextLen;\n i++;\n while (i < this.codeCount && curLen === this.codeLength[i]) {\n i++;\n if (++count >= maxCount) {\n break;\n }\n }\n if (count < minCount) {\n blTree.codeFrequency[curLen] += count;\n }\n else if (curLen !== 0) {\n blTree.codeFrequency[16]++;\n }\n else if (count <= 10) {\n blTree.codeFrequency[17]++;\n }\n else {\n blTree.codeFrequency[18]++;\n }\n }\n };\n /**\n * @param {CompressorHuffmanTree} blTree - write tree to output stream\n * @returns {void}\n */\n CompressorHuffmanTree.prototype.writeTree = function (blTree) {\n var maxRepeatCount;\n var minRepeatCount;\n var currentRepeatCount;\n var currentCodeLength = -1;\n var i = 0;\n while (i < this.codeCount) {\n currentRepeatCount = 1;\n var nextLen = this.codeLength[i];\n if (nextLen === 0) {\n maxRepeatCount = 138;\n minRepeatCount = 3;\n }\n else {\n maxRepeatCount = 6;\n minRepeatCount = 3;\n if (currentCodeLength !== nextLen) {\n blTree.writeCodeToStream(nextLen);\n currentRepeatCount = 0;\n }\n }\n currentCodeLength = nextLen;\n i++;\n while (i < this.codeCount && currentCodeLength === this.codeLength[i]) {\n i++;\n if (++currentRepeatCount >= maxRepeatCount) {\n break;\n }\n }\n if (currentRepeatCount < minRepeatCount) {\n while (currentRepeatCount-- > 0) {\n blTree.writeCodeToStream(currentCodeLength);\n }\n }\n else if (currentCodeLength !== 0) {\n blTree.writeCodeToStream(16);\n this.writer.pendingBufferWriteBits(currentRepeatCount - 3, 2);\n }\n else if (currentRepeatCount <= 10) {\n blTree.writeCodeToStream(17);\n this.writer.pendingBufferWriteBits(currentRepeatCount - 3, 3);\n }\n else {\n blTree.writeCodeToStream(18);\n this.writer.pendingBufferWriteBits(currentRepeatCount - 11, 7);\n }\n }\n };\n /**\n * Build huffman tree\n * @returns {void}\n */\n CompressorHuffmanTree.prototype.buildTree = function () {\n var codesCount = this.codeFrequency.length;\n var arrTree = new Int32Array(codesCount);\n var treeLength = 0;\n var maxCount = 0;\n for (var n = 0; n < codesCount; n++) {\n var freq = this.codeFrequency[n];\n if (freq !== 0) {\n var pos = treeLength++;\n var pPos = 0;\n while (pos > 0 && this.codeFrequency[arrTree[pPos = Math.floor((pos - 1) / 2)]] > freq) {\n arrTree[pos] = arrTree[pPos];\n pos = pPos;\n }\n arrTree[pos] = n;\n maxCount = n;\n }\n }\n while (treeLength < 2) {\n arrTree[treeLength++] =\n (maxCount < 2) ? ++maxCount : 0;\n }\n this.codeCount = Math.max(maxCount + 1, this.codeMinCount);\n var leafsCount = treeLength;\n var nodesCount = leafsCount;\n var child = new Int32Array(4 * treeLength - 2);\n var values = new Int32Array(2 * treeLength - 1);\n for (var i = 0; i < treeLength; i++) {\n var node = arrTree[i];\n var iIndex = 2 * i;\n child[iIndex] = node;\n child[iIndex + 1] = -1;\n values[i] = (this.codeFrequency[node] << 8);\n arrTree[i] = i;\n }\n this.constructHuffmanTree(arrTree, treeLength, values, nodesCount, child);\n this.buildLength(child);\n };\n CompressorHuffmanTree.prototype.constructHuffmanTree = function (arrTree, treeLength, values, nodesCount, child) {\n do {\n var first = arrTree[0];\n var last = arrTree[--treeLength];\n var lastVal = values[last];\n var pPos = 0;\n var path = 1;\n while (path < treeLength) {\n if (path + 1 < treeLength && values[arrTree[path]] > values[arrTree[path + 1]]) {\n path++;\n }\n arrTree[pPos] = arrTree[path];\n pPos = path;\n path = pPos * 2 + 1;\n }\n while ((path = pPos) > 0 && values[arrTree[pPos = Math.floor((path - 1) / 2)]] > lastVal) {\n arrTree[path] = arrTree[pPos];\n }\n arrTree[path] = last;\n var second = arrTree[0];\n last = nodesCount++;\n child[2 * last] = first;\n child[2 * last + 1] = second;\n var minDepth = Math.min(values[first] & 0xff, values[second] & 0xff);\n values[last] = lastVal = values[first] + values[second] - minDepth + 1;\n pPos = 0;\n path = 1;\n /* tslint:disable */\n while (path < treeLength) {\n if (path + 1 < treeLength && values[arrTree[path]] > values[arrTree[path + 1]]) {\n path++;\n }\n arrTree[pPos] = arrTree[path];\n pPos = path;\n path = pPos * 2 + 1;\n } /* tslint:disable */\n while ((path = pPos) > 0 && values[arrTree[pPos = Math.floor((path - 1) / 2)]] > lastVal) {\n arrTree[path] = arrTree[pPos];\n }\n arrTree[path] = last;\n } while (treeLength > 1);\n };\n CompressorHuffmanTree.prototype.buildLength = function (child) {\n this.codeLength = new Uint8Array(this.codeFrequency.length);\n var numNodes = Math.floor(child.length / 2);\n var numLeafs = Math.floor((numNodes + 1) / 2);\n var overflow = 0;\n for (var i = 0; i < this.maxLength; i++) {\n this.lengthCount[i] = 0;\n }\n overflow = this.calculateOptimalCodeLength(child, overflow, numNodes);\n if (overflow === 0) {\n return;\n }\n var iIncreasableLength = this.maxLength - 1;\n do {\n while (this.lengthCount[--iIncreasableLength] === 0) {\n /* tslint:disable */\n }\n do {\n this.lengthCount[iIncreasableLength]--;\n this.lengthCount[++iIncreasableLength]++;\n overflow -= (1 << (this.maxLength - 1 - iIncreasableLength));\n } while (overflow > 0 && iIncreasableLength < this.maxLength - 1);\n } while (overflow > 0);\n this.recreateTree(child, overflow, numLeafs);\n };\n CompressorHuffmanTree.prototype.recreateTree = function (child, overflow, numLeafs) {\n this.lengthCount[this.maxLength - 1] += overflow;\n this.lengthCount[this.maxLength - 2] -= overflow;\n var nodePtr = 2 * numLeafs;\n for (var bits = this.maxLength; bits !== 0; bits--) {\n var n = this.lengthCount[bits - 1];\n while (n > 0) {\n var childPtr = 2 * child[nodePtr++];\n if (child[childPtr + 1] === -1) {\n this.codeLength[child[childPtr]] = bits;\n n--;\n }\n }\n }\n };\n CompressorHuffmanTree.prototype.calculateOptimalCodeLength = function (child, overflow, numNodes) {\n var lengths = new Int32Array(numNodes);\n lengths[numNodes - 1] = 0;\n for (var i = numNodes - 1; i >= 0; i--) {\n var childIndex = 2 * i + 1;\n if (child[childIndex] !== -1) {\n var bitLength = lengths[i] + 1;\n if (bitLength > this.maxLength) {\n bitLength = this.maxLength;\n overflow++;\n }\n lengths[child[childIndex - 1]] = lengths[child[childIndex]] = bitLength;\n }\n else {\n var bitLength = lengths[i];\n this.lengthCount[bitLength - 1]++;\n this.codeLength[child[childIndex - 1]] = lengths[i];\n }\n }\n return overflow;\n };\n CompressorHuffmanTree.reverseBits = [0, 8, 4, 12, 2, 10, 6, 14, 1, 9, 5, 13, 3, 11, 7, 15];\n CompressorHuffmanTree.huffCodeLengthOrders = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];\n return CompressorHuffmanTree;\n}());\nexport { CompressorHuffmanTree };\n/**\n * Checksum calculator, based on Adler32 algorithm.\n */\nvar ChecksumCalculator = /** @class */ (function () {\n function ChecksumCalculator() {\n }\n /**\n * Updates checksum by calculating checksum of the\n * given buffer and adding it to current value.\n * @param {number} checksum - current checksum.\n * @param {Uint8Array} buffer - data byte array.\n * @param {number} offset - offset in the buffer.\n * @param {number} length - length of data to be used from the stream.\n * @returns {number}\n */\n ChecksumCalculator.checksumUpdate = function (checksum, buffer, offset, length) {\n var uint = new Uint32Array(1);\n uint[0] = checksum;\n var checksum_uint = uint[0];\n var s1 = uint[0] = checksum_uint & 65535;\n var s2 = uint[0] = checksum_uint >> ChecksumCalculator.checkSumBitOffset;\n while (length > 0) {\n var steps = Math.min(length, ChecksumCalculator.checksumIterationCount);\n length -= steps;\n while (--steps >= 0) {\n s1 = s1 + (uint[0] = (buffer[offset++] & 255));\n s2 = s2 + s1;\n }\n s1 %= ChecksumCalculator.checksumBase;\n s2 %= ChecksumCalculator.checksumBase;\n }\n checksum_uint = (s2 << ChecksumCalculator.checkSumBitOffset) | s1;\n return checksum_uint;\n };\n ChecksumCalculator.checkSumBitOffset = 16;\n ChecksumCalculator.checksumBase = 65521;\n ChecksumCalculator.checksumIterationCount = 3800;\n return ChecksumCalculator;\n}());\nexport { ChecksumCalculator };\n/* eslint-enable */ \n","//! moment.js locale configuration\n//! locale : Vietnamese [vi]\n//! author : Bang Nguyen : https://github.com/bangnk\n//! author : Chien Kira : https://github.com/chienkira\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var vi = moment.defineLocale('vi', {\n months: 'tháng 1_tháng 2_tháng 3_tháng 4_tháng 5_tháng 6_tháng 7_tháng 8_tháng 9_tháng 10_tháng 11_tháng 12'.split(\n '_'\n ),\n monthsShort:\n 'Thg 01_Thg 02_Thg 03_Thg 04_Thg 05_Thg 06_Thg 07_Thg 08_Thg 09_Thg 10_Thg 11_Thg 12'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'chủ nháºt_thứ hai_thứ ba_thứ tÆ°_thứ năm_thứ sáu_thứ bảy'.split(\n '_'\n ),\n weekdaysShort: 'CN_T2_T3_T4_T5_T6_T7'.split('_'),\n weekdaysMin: 'CN_T2_T3_T4_T5_T6_T7'.split('_'),\n weekdaysParseExact: true,\n meridiemParse: /sa|ch/i,\n isPM: function (input) {\n return /^ch$/i.test(input);\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours < 12) {\n return isLower ? 'sa' : 'SA';\n } else {\n return isLower ? 'ch' : 'CH';\n }\n },\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM [năm] YYYY',\n LLL: 'D MMMM [năm] YYYY HH:mm',\n LLLL: 'dddd, D MMMM [năm] YYYY HH:mm',\n l: 'DD/M/YYYY',\n ll: 'D MMM YYYY',\n lll: 'D MMM YYYY HH:mm',\n llll: 'ddd, D MMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Hôm nay lúc] LT',\n nextDay: '[Ngà y mai lúc] LT',\n nextWeek: 'dddd [tuần tá»›i lúc] LT',\n lastDay: '[Hôm qua lúc] LT',\n lastWeek: 'dddd [tuần trÆ°á»›c lúc] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s tá»›i',\n past: '%s trÆ°á»›c',\n s: 'và i giây',\n ss: '%d giây',\n m: 'má»™t phút',\n mm: '%d phút',\n h: 'má»™t giá»',\n hh: '%d giá»',\n d: 'má»™t ngà y',\n dd: '%d ngà y',\n w: 'má»™t tuần',\n ww: '%d tuần',\n M: 'má»™t tháng',\n MM: '%d tháng',\n y: 'má»™t năm',\n yy: '%d năm',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}/,\n ordinal: function (number) {\n return number;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return vi;\n\n})));\n","//! moment.js locale configuration\n//! locale : Montenegrin [me]\n//! author : Miodrag NikaÄ <miodrag@restartit.me> : https://github.com/miodragnikac\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var translator = {\n words: {\n //Different grammatical cases\n ss: ['sekund', 'sekunda', 'sekundi'],\n m: ['jedan minut', 'jednog minuta'],\n mm: ['minut', 'minuta', 'minuta'],\n h: ['jedan sat', 'jednog sata'],\n hh: ['sat', 'sata', 'sati'],\n dd: ['dan', 'dana', 'dana'],\n MM: ['mjesec', 'mjeseca', 'mjeseci'],\n yy: ['godina', 'godine', 'godina'],\n },\n correctGrammaticalCase: function (number, wordKey) {\n return number === 1\n ? wordKey[0]\n : number >= 2 && number <= 4\n ? wordKey[1]\n : wordKey[2];\n },\n translate: function (number, withoutSuffix, key) {\n var wordKey = translator.words[key];\n if (key.length === 1) {\n return withoutSuffix ? wordKey[0] : wordKey[1];\n } else {\n return (\n number +\n ' ' +\n translator.correctGrammaticalCase(number, wordKey)\n );\n }\n },\n };\n\n var me = moment.defineLocale('me', {\n months: 'januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar'.split(\n '_'\n ),\n monthsShort:\n 'jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.'.split('_'),\n monthsParseExact: true,\n weekdays: 'nedjelja_ponedjeljak_utorak_srijeda_Äetvrtak_petak_subota'.split(\n '_'\n ),\n weekdaysShort: 'ned._pon._uto._sri._Äet._pet._sub.'.split('_'),\n weekdaysMin: 'ne_po_ut_sr_Äe_pe_su'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY H:mm',\n LLLL: 'dddd, D. MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[danas u] LT',\n nextDay: '[sjutra u] LT',\n\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[u] [nedjelju] [u] LT';\n case 3:\n return '[u] [srijedu] [u] LT';\n case 6:\n return '[u] [subotu] [u] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[u] dddd [u] LT';\n }\n },\n lastDay: '[juÄe u] LT',\n lastWeek: function () {\n var lastWeekDays = [\n '[proÅ¡le] [nedjelje] [u] LT',\n '[proÅ¡log] [ponedjeljka] [u] LT',\n '[proÅ¡log] [utorka] [u] LT',\n '[proÅ¡le] [srijede] [u] LT',\n '[proÅ¡log] [Äetvrtka] [u] LT',\n '[proÅ¡log] [petka] [u] LT',\n '[proÅ¡le] [subote] [u] LT',\n ];\n return lastWeekDays[this.day()];\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'za %s',\n past: 'prije %s',\n s: 'nekoliko sekundi',\n ss: translator.translate,\n m: translator.translate,\n mm: translator.translate,\n h: translator.translate,\n hh: translator.translate,\n d: 'dan',\n dd: translator.translate,\n M: 'mjesec',\n MM: translator.translate,\n y: 'godinu',\n yy: translator.translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return me;\n\n})));\n","import urls from './urls'\r\nimport authToken from './authToken';\r\nimport { DataManager, WebApiAdaptor } from \"@syncfusion/ej2-data\";\r\nimport apis from './network'\r\nimport logger from './logger'\r\nimport rules from './permissions'\r\nimport checkUIPermissions from './UIPermissions'\r\n\r\nclass CustomWebApiAdaptor extends WebApiAdaptor {\r\n beforeSend(dm, xhttp, p3) {\r\n\r\n const originalFail = p3.onFailure;\r\n\r\n p3.onFailure = function (err) {\r\n if (err.status === 401) {\r\n const token = authToken.get();\r\n if (token) {\r\n logger.log(\"trying token refresh...\", err);\r\n apis.unprotectedApi.put(\r\n \"/auth\",\r\n {\r\n Token: token\r\n }\r\n ).then((r) => r.data).then((resp) => { \r\n authToken.set(resp.token || resp.Token);\r\n rules.getPermissions(resp.token || resp.Token);\r\n checkUIPermissions();\r\n logger.log(\"refreshed\");\r\n }).catch((err) => {\r\n logger.log(\"refresh token failed\", err)\r\n //navigate to login - some questions asked\r\n apis.navigateToLogin(window.location.pathname);\r\n });\r\n } else {\r\n logger.log(\"No token to refresh...\", err)\r\n apis.navigateToLogin(window.location.pathname);\r\n }\r\n }\r\n\r\n if (originalFail && typeof (originalFail) === \"function\") {\r\n try {\r\n originalFail(err);\r\n } catch (e) {\r\n logger.log(\"original error handler failed\", err);\r\n logger.log(\"new error\", e);\r\n }\r\n \r\n }\r\n }\r\n\r\n super.beforeSend(dm, xhttp, p3);\r\n }\r\n}\r\n\r\nconst SyncHelper = {\r\n getDataManager: (relativePath, queryString) => {\r\n return new DataManager({\r\n url: `${urls.apiBaseUrl}${relativePath}${(queryString ? ('?' + queryString) : '')}`,\r\n adaptor: new CustomWebApiAdaptor,\r\n crossDomain: true,\r\n headers: [{ Authorization: `Bearer ${authToken.get()}`}]\r\n });\r\n }\r\n};\r\n\r\nexport default SyncHelper;","//! moment.js locale configuration\n//! locale : Afrikaans [af]\n//! author : Werner Mollentze : https://github.com/wernerm\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var af = moment.defineLocale('af', {\n months: 'Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mrt_Apr_Mei_Jun_Jul_Aug_Sep_Okt_Nov_Des'.split('_'),\n weekdays: 'Sondag_Maandag_Dinsdag_Woensdag_Donderdag_Vrydag_Saterdag'.split(\n '_'\n ),\n weekdaysShort: 'Son_Maa_Din_Woe_Don_Vry_Sat'.split('_'),\n weekdaysMin: 'So_Ma_Di_Wo_Do_Vr_Sa'.split('_'),\n meridiemParse: /vm|nm/i,\n isPM: function (input) {\n return /^nm$/i.test(input);\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours < 12) {\n return isLower ? 'vm' : 'VM';\n } else {\n return isLower ? 'nm' : 'NM';\n }\n },\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Vandag om] LT',\n nextDay: '[Môre om] LT',\n nextWeek: 'dddd [om] LT',\n lastDay: '[Gister om] LT',\n lastWeek: '[Laas] dddd [om] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'oor %s',\n past: '%s gelede',\n s: \"'n paar sekondes\",\n ss: '%d sekondes',\n m: \"'n minuut\",\n mm: '%d minute',\n h: \"'n uur\",\n hh: '%d ure',\n d: \"'n dag\",\n dd: '%d dae',\n M: \"'n maand\",\n MM: '%d maande',\n y: \"'n jaar\",\n yy: '%d jaar',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(ste|de)/,\n ordinal: function (number) {\n return (\n number +\n (number === 1 || number === 8 || number >= 20 ? 'ste' : 'de')\n ); // Thanks to Joris Röling : https://github.com/jjupiter\n },\n week: {\n dow: 1, // Maandag is die eerste dag van die week.\n doy: 4, // Die week wat die 4de Januarie bevat is die eerste week van die jaar.\n },\n });\n\n return af;\n\n})));\n","import { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { Query, DataManager, Predicate, Deferred, UrlAdaptor, RemoteSaveAdaptor } from '@syncfusion/ej2-data';\nimport { setFormatter, isGroupAdaptive, getColumnByForeignKeyValue, refreshFilteredColsUid } from '../base/util';\nimport * as events from '../base/constant';\nimport { ValueFormatter } from '../services/value-formatter';\nimport { CheckBoxFilterBase } from '../common/checkbox-filter-base';\n/**\n * Grid data module is used to generate query and data source.\n *\n * @hidden\n */\nvar Data = /** @class */ (function () {\n /**\n * Constructor for data module.\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {ServiceLocator} serviceLocator - specifies the service locator\n * @hidden\n */\n function Data(parent, serviceLocator) {\n this.dataState = { isPending: false, resolver: null, group: [] };\n this.foreignKeyDataState = { isPending: false, resolver: null };\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.initDataManager();\n if (this.parent.isDestroyed || this.getModuleName() === 'foreignKey') {\n return;\n }\n this.parent.on(events.rowsAdded, this.addRows, this);\n this.parent.on(events.rowPositionChanged, this.reorderRows, this);\n this.parent.on(events.rowsRemoved, this.removeRows, this);\n this.parent.on(events.dataSourceModified, this.initDataManager, this);\n this.parent.on(events.destroy, this.destroy, this);\n this.parent.on(events.updateData, this.crudActions, this);\n this.parent.on(events.addDeleteAction, this.getData, this);\n this.parent.on(events.autoCol, this.refreshFilteredCols, this);\n this.parent.on(events.columnsPrepared, this.refreshFilteredCols, this);\n }\n Data.prototype.reorderRows = function (e) {\n this.dataManager.dataSource.json.splice(e.toIndex, 0, this.dataManager.dataSource.json.splice(e.fromIndex, 1)[0]);\n };\n Data.prototype.getModuleName = function () {\n return 'data';\n };\n /**\n * The function used to initialize dataManager and external query\n *\n * @returns {void}\n */\n Data.prototype.initDataManager = function () {\n var gObj = this.parent;\n this.dataManager = gObj.dataSource instanceof DataManager ? gObj.dataSource :\n (isNullOrUndefined(gObj.dataSource) ? new DataManager() : new DataManager(gObj.dataSource));\n if (gObj.isAngular && !(gObj.query instanceof Query)) {\n gObj.setProperties({ query: new Query() }, true);\n }\n else {\n this.isQueryInvokedFromData = true;\n if (gObj.isVue) {\n gObj.setProperties({ query: gObj.query instanceof Query ? gObj.query : new Query() }, true);\n }\n else {\n gObj.query = gObj.query instanceof Query ? gObj.query : new Query();\n }\n }\n };\n /**\n * The function is used to generate updated Query from Grid model.\n *\n * @param {boolean} skipPage - specifies the boolean to skip the page\n * @param {boolean} isAutoCompleteCall - specifies for auto complete call\n * @returns {Query} returns the Query\n * @hidden\n */\n Data.prototype.generateQuery = function (skipPage, isAutoCompleteCall) {\n var gObj = this.parent;\n var query = gObj.getQuery().clone();\n if (this.parent.columnQueryMode === 'ExcludeHidden') {\n query.select(this.parent.getColumns().filter(function (column) { return !(column.isPrimaryKey !== true && column.visible === false || column.field === undefined); }).map(function (column) { return column.field; }));\n }\n else if (this.parent.columnQueryMode === 'Schema') {\n var selectQueryFields = [];\n var columns = this.parent.columns;\n for (var i = 0; i < columns.length; i++) {\n selectQueryFields.push(columns[parseInt(i.toString(), 10)].field);\n }\n query.select(selectQueryFields);\n }\n this.filterQuery(query);\n this.searchQuery(query);\n this.aggregateQuery(query);\n this.sortQuery(query);\n if (isGroupAdaptive(this.parent)) {\n this.virtualGroupPageQuery(query);\n }\n else {\n this.pageQuery(query, skipPage);\n }\n if (isNullOrUndefined(isAutoCompleteCall) || !isAutoCompleteCall) {\n this.groupQuery(query);\n }\n return query;\n };\n /**\n * @param {Query} query - specifies the query\n * @returns {Query} - returns the query\n * @hidden\n */\n Data.prototype.aggregateQuery = function (query) {\n var rows = this.parent.aggregates;\n for (var i = 0; i < rows.length; i++) {\n var row = rows[parseInt(i.toString(), 10)];\n for (var j = 0; j < row.columns.length; j++) {\n var cols = row.columns[parseInt(j.toString(), 10)];\n var types = cols.type instanceof Array ? cols.type : [cols.type];\n for (var k = 0; k < types.length; k++) {\n query.aggregate(types[parseInt(k.toString(), 10)].toLowerCase(), cols.field);\n }\n }\n }\n return query;\n };\n Data.prototype.virtualGroupPageQuery = function (query) {\n var fName = 'fn';\n if (query.queries.length) {\n for (var i = 0; i < query.queries.length; i++) {\n if (query.queries[parseInt(i.toString(), 10)][\"\" + fName] === 'onPage') {\n query.queries.splice(i, 1);\n }\n }\n }\n return query;\n };\n Data.prototype.pageQuery = function (query, skipPage) {\n var gObj = this.parent;\n var fName = 'fn';\n var args = { query: query, skipPage: false };\n gObj.notify(events.setVirtualPageQuery, args);\n if (args.skipPage) {\n return query;\n }\n if ((gObj.allowPaging || gObj.enableVirtualization || gObj.enableInfiniteScrolling) && skipPage !== true) {\n gObj.pageSettings.currentPage = Math.max(1, gObj.pageSettings.currentPage);\n if (gObj.pageSettings.pageCount <= 0) {\n gObj.pageSettings.pageCount = 8;\n }\n if (gObj.pageSettings.pageSize <= 0) {\n gObj.pageSettings.pageSize = 12;\n }\n if (query.queries.length) {\n for (var i = 0; i < query.queries.length; i++) {\n if (query.queries[parseInt(i.toString(), 10)][\"\" + fName] === 'onPage') {\n query.queries.splice(i, 1);\n }\n }\n }\n if (!isNullOrUndefined(gObj.infiniteScrollModule) && gObj.enableInfiniteScrolling) {\n this.parent.notify(events.infinitePageQuery, query);\n }\n else {\n query.page(gObj.pageSettings.currentPage, gObj.allowPaging && gObj.pagerModule &&\n (gObj.pagerModule.pagerObj.isAllPage && !gObj.isManualRefresh) &&\n (!this.dataManager.dataSource.offline && !(this.dataManager.adaptor instanceof RemoteSaveAdaptor)) ?\n null : gObj.pageSettings.pageSize);\n }\n }\n return query;\n };\n Data.prototype.groupQuery = function (query) {\n var gObj = this.parent;\n if (gObj.allowGrouping && gObj.groupSettings.columns.length) {\n if (this.parent.groupSettings.enableLazyLoading) {\n query.lazyLoad.push({ key: 'isLazyLoad', value: this.parent.groupSettings.enableLazyLoading });\n }\n var columns = gObj.groupSettings.columns;\n for (var i = 0, len = columns.length; i < len; i++) {\n var column = this.getColumnByField(columns[parseInt(i.toString(), 10)]);\n if (!column) {\n this.parent.log('initial_action', { moduleName: 'group', columnName: columns[parseInt(i.toString(), 10)] });\n }\n var isGrpFmt = column.enableGroupByFormat;\n var format = column.format;\n if (isGrpFmt) {\n query.group(columns[parseInt(i.toString(), 10)], this.formatGroupColumn.bind(this), format);\n }\n else {\n query.group(columns[parseInt(i.toString(), 10)], null);\n }\n }\n }\n return query;\n };\n Data.prototype.sortQuery = function (query) {\n var gObj = this.parent;\n if ((gObj.allowSorting || gObj.allowGrouping) && gObj.sortSettings.columns.length) {\n var columns = gObj.sortSettings.columns;\n var sortGrp = [];\n for (var i = columns.length - 1; i > -1; i--) {\n var col = this.getColumnByField(columns[parseInt(i.toString(), 10)].field);\n if (col) {\n col.setSortDirection(columns[parseInt(i.toString(), 10)].direction);\n }\n else {\n this.parent.log('initial_action', { moduleName: 'sort', columnName: columns[parseInt(i.toString(), 10)].field });\n return query;\n }\n var fn = columns[parseInt(i.toString(), 10)].direction;\n if (col.sortComparer) {\n this.parent.log('grid_sort_comparer');\n fn = !this.isRemote() ? col.sortComparer.bind(col) : columns[parseInt(i.toString(), 10)].direction;\n }\n if (gObj.groupSettings.columns.indexOf(columns[parseInt(i.toString(), 10)].field) === -1) {\n if (col.isForeignColumn() || col.sortComparer) {\n query.sortByForeignKey(col.field, fn, undefined, columns[parseInt(i.toString(), 10)].direction.toLowerCase());\n }\n else {\n query.sortBy(col.field, fn);\n }\n }\n else {\n sortGrp.push({ direction: fn, field: col.field });\n }\n }\n for (var i = 0, len = sortGrp.length; i < len; i++) {\n if (typeof sortGrp[parseInt(i.toString(), 10)].direction === 'string') {\n query.sortBy(sortGrp[parseInt(i.toString(), 10)].field, sortGrp[parseInt(i.toString(), 10)].direction);\n }\n else {\n var col = this.getColumnByField(sortGrp[parseInt(i.toString(), 10)].field);\n query.sortByForeignKey(sortGrp[parseInt(i.toString(), 10)].field, sortGrp[parseInt(i.toString(), 10)].direction, undefined, col.getSortDirection().toLowerCase());\n }\n }\n }\n return query;\n };\n Data.prototype.searchQuery = function (query, fcolumn, isForeignKey) {\n var sSettings = this.parent.searchSettings;\n var fields = sSettings.fields.length ? sSettings.fields : this.getSearchColumnFieldNames();\n var predicateList = [];\n var needForeignKeySearch = false;\n if (this.parent.searchSettings.key.length) {\n needForeignKeySearch = this.parent.getForeignKeyColumns().some(function (col) { return fields.indexOf(col.field) > -1; });\n var adaptor = !isForeignKey ? this.dataManager.adaptor : fcolumn.dataSource.adaptor;\n if (needForeignKeySearch || (adaptor.getModuleName &&\n adaptor.getModuleName() === 'ODataV4Adaptor')) {\n fields = isForeignKey ? [fcolumn.foreignKeyValue] : fields;\n for (var i = 0; i < fields.length; i++) {\n var column = isForeignKey ? fcolumn : this.getColumnByField(fields[parseInt(i.toString(), 10)]);\n if (column.isForeignColumn() && !isForeignKey) {\n predicateList = this.fGeneratePredicate(column, predicateList);\n }\n else {\n predicateList.push(new Predicate(fields[parseInt(i.toString(), 10)], sSettings.operator, sSettings.key, sSettings.ignoreCase, sSettings.ignoreAccent));\n }\n }\n var predList = Predicate.or(predicateList);\n predList.key = sSettings.key;\n query.where(predList);\n }\n else {\n query.search(sSettings.key, fields, sSettings.operator, sSettings.ignoreCase, sSettings.ignoreAccent);\n }\n }\n return query;\n };\n Data.prototype.filterQuery = function (query, column, skipFoerign) {\n var gObj = this.parent;\n var predicateList = [];\n var actualFilter = [];\n var foreignColumn = this.parent.getForeignKeyColumns();\n var foreignColEmpty;\n if (gObj.allowFiltering && gObj.filterSettings.columns.length) {\n var columns = column ? column : gObj.filterSettings.columns;\n var colType = {};\n for (var _i = 0, _a = gObj.getColumns(); _i < _a.length; _i++) {\n var col = _a[_i];\n colType[col.field] = col.filter.type ? col.filter.type : gObj.filterSettings.type;\n }\n var foreignCols = [];\n var defaultFltrCols = [];\n for (var _b = 0, columns_1 = columns; _b < columns_1.length; _b++) {\n var col = columns_1[_b];\n var gridColumn = col.isForeignKey ? gObj.getColumnByUid(col.uid) : gObj.getColumnByField(col.field);\n if (isNullOrUndefined(col.type) && gridColumn && (gridColumn.type === 'date' || gridColumn.type === 'datetime' || gridColumn.type === 'dateonly')) {\n col.type = col.isForeignKey ? gObj.getColumnByUid(col.uid).type : gObj.getColumnByField(col.field).type;\n }\n if (col.isForeignKey) {\n foreignCols.push(col);\n }\n else {\n defaultFltrCols.push(col);\n }\n }\n if (defaultFltrCols.length) {\n for (var i = 0, len = defaultFltrCols.length; i < len; i++) {\n defaultFltrCols[parseInt(i.toString(), 10)].uid = defaultFltrCols[parseInt(i.toString(), 10)].uid ||\n this.parent.grabColumnByFieldFromAllCols(defaultFltrCols[parseInt(i.toString(), 10)].field, defaultFltrCols[parseInt(i.toString(), 10)].isForeignKey).uid;\n }\n var excelPredicate = CheckBoxFilterBase.getPredicate(defaultFltrCols);\n for (var _c = 0, _d = Object.keys(excelPredicate); _c < _d.length; _c++) {\n var prop = _d[_c];\n predicateList.push(excelPredicate[\"\" + prop]);\n }\n }\n if (foreignCols.length) {\n for (var _e = 0, foreignCols_1 = foreignCols; _e < foreignCols_1.length; _e++) {\n var col = foreignCols_1[_e];\n col.uid = col.uid || this.parent.grabColumnByFieldFromAllCols(col.field, col.isForeignKey).uid;\n var column_1 = this.parent.grabColumnByUidFromAllCols(col.uid);\n if (!column_1) {\n this.parent.log('initial_action', { moduleName: 'filter', columnName: col.field });\n }\n if (column_1.isForeignColumn() && getColumnByForeignKeyValue(col.field, foreignColumn) && !skipFoerign) {\n actualFilter.push(col);\n if (!column_1.columnData.length) {\n foreignColEmpty = true;\n }\n predicateList = this.fGeneratePredicate(column_1, predicateList);\n }\n else {\n var excelPredicate = CheckBoxFilterBase.getPredicate(columns);\n for (var _f = 0, _g = Object.keys(excelPredicate); _f < _g.length; _f++) {\n var prop = _g[_f];\n predicateList.push(excelPredicate[\"\" + prop]);\n }\n }\n }\n }\n if (predicateList.length && !foreignColEmpty) {\n query.where(Predicate.and(predicateList));\n }\n else {\n this.parent.notify(events.showEmptyGrid, {});\n }\n }\n return query;\n };\n Data.prototype.fGeneratePredicate = function (col, predicateList) {\n var fPredicate = {};\n if (col) {\n this.parent.notify(events.generateQuery, { predicate: fPredicate, column: col });\n if (fPredicate.predicate.predicates.length) {\n predicateList.push(fPredicate.predicate);\n }\n }\n return predicateList;\n };\n /**\n * The function is used to get dataManager promise by executing given Query.\n *\n * @param {object} args - specifies the object\n * @param {string} args.requestType - Defines the request type\n * @param {string[]} args.foreignKeyData - Defines the foreignKeyData.string\n * @param {Object} args.data - Defines the data.\n * @param {number} args.index - Defines the index .\n * @param {Query} query - Defines the query which will execute along with data processing.\n * @returns {Promise<Object>} - returns the object\n * @hidden\n */\n Data.prototype.getData = function (args, query) {\n var _this = this;\n if (args === void 0) { args = { requestType: '' }; }\n var key = this.getKey(args.foreignKeyData &&\n Object.keys(args.foreignKeyData).length ?\n args.foreignKeyData : this.parent.getPrimaryKeyFieldNames());\n this.parent.log('datasource_syntax_mismatch', { dataState: this.parent });\n if (this.parent.dataSource && 'result' in this.parent.dataSource) {\n var def = this.eventPromise(args, query, key);\n return def.promise;\n }\n else {\n var crud = void 0;\n switch (args.requestType) {\n case 'delete':\n query = query ? query : this.generateQuery();\n // eslint-disable-next-line no-case-declarations\n var len = Object.keys(args.data).length;\n if (len === 1) {\n crud = this.dataManager.remove(key, args.data[0], query.fromTable, query);\n }\n else {\n var changes = {\n addedRecords: [],\n deletedRecords: [],\n changedRecords: []\n };\n changes.deletedRecords = args.data;\n crud = this.dataManager.saveChanges(changes, key, query.fromTable, query.requiresCount());\n }\n break;\n case 'save':\n query = query ? query : this.generateQuery();\n args.index = isNullOrUndefined(args.index) ? 0 : args.index;\n crud = this.dataManager.insert(args.data, query.fromTable, query, args.index);\n break;\n }\n var promise = 'promise';\n args[\"\" + promise] = crud;\n // eslint-disable-next-line no-prototype-builtins\n if (crud && !Array.isArray(crud) && !crud.hasOwnProperty('deletedRecords')) {\n return crud.then(function () {\n return _this.insert(query, args);\n });\n }\n else {\n return this.insert(query, args);\n }\n }\n };\n Data.prototype.insert = function (query, args) {\n if (args.requestType === 'save') {\n this.parent.notify(events.recordAdded, args);\n }\n return this.executeQuery(query);\n };\n Data.prototype.executeQuery = function (query) {\n var _this = this;\n if (this.dataManager.ready) {\n var deferred_1 = new Deferred();\n var ready = this.dataManager.ready;\n ready.then(function () {\n _this.dataManager.executeQuery(query).then(function (result) {\n deferred_1.resolve(result);\n });\n }).catch(function (e) {\n deferred_1.reject(e);\n });\n return deferred_1.promise;\n }\n else {\n return this.dataManager.executeQuery(query);\n }\n };\n Data.prototype.formatGroupColumn = function (value, field) {\n var serviceLocator = this.serviceLocator;\n var column = this.getColumnByField(field);\n var date = value;\n if (!column.type) {\n column.type = date.getDay ? (date.getHours() > 0 || date.getMinutes() > 0 ||\n date.getSeconds() > 0 || date.getMilliseconds() > 0 ? 'datetime' : 'date') : typeof (value);\n }\n if (isNullOrUndefined(column.getFormatter())) {\n setFormatter(serviceLocator, column);\n }\n var formatVal = ValueFormatter.prototype.toView(value, column.getFormatter());\n return formatVal;\n };\n Data.prototype.crudActions = function (args) {\n var query = this.generateQuery();\n var promise = null;\n var pr = 'promise';\n var key = this.getKey(args.foreignKeyData &&\n Object.keys(args.foreignKeyData).length ? args.foreignKeyData :\n this.parent.getPrimaryKeyFieldNames());\n if (this.parent.dataSource && 'result' in this.parent.dataSource) {\n this.eventPromise(args, query, key);\n }\n switch (args.requestType) {\n case 'save':\n promise = this.dataManager.update(key, args.data, query.fromTable, query, args.previousData);\n break;\n }\n args[\"\" + pr] = promise ? promise : args[\"\" + pr];\n this.parent.notify(events.crudAction, args);\n };\n /**\n * @param {object} changes - specifies the changes\n * @param {string} key - specifies the key\n * @param {object} original - specifies the original data\n * @param {Query} query - specifies the query\n * @returns {Promise<Object>} returns the object\n * @hidden\n */\n Data.prototype.saveChanges = function (changes, key, original, query) {\n if (query === void 0) { query = this.generateQuery(); }\n query.requiresCount();\n if ('result' in this.parent.dataSource) {\n var deff = new Deferred();\n var args = {\n requestType: 'batchsave', changes: changes, key: key, query: query,\n endEdit: deff.resolve\n };\n this.setState({ isPending: true, resolver: deff.resolve });\n this.parent.trigger(events.dataSourceChanged, args);\n return deff.promise;\n }\n else {\n var promise = this.dataManager.saveChanges(changes, key, query.fromTable, query, original);\n return promise;\n }\n };\n Data.prototype.getKey = function (keys) {\n if (keys && keys.length) {\n return keys[0];\n }\n return undefined;\n };\n /**\n * @returns {boolean} returns whether its remote data\n * @hidden\n */\n Data.prototype.isRemote = function () {\n return this.dataManager.dataSource.offline !== true && this.dataManager.dataSource.url !== undefined &&\n this.dataManager.dataSource.url !== '';\n };\n Data.prototype.addRows = function (e) {\n for (var i = e.records.length; i > 0; i--) {\n if (this.parent.dataSource instanceof DataManager && this.dataManager.dataSource.offline) {\n this.dataManager.dataSource.json.splice(e.toIndex, 0, e.records[i - 1]);\n }\n else if (((!this.parent.getDataModule().isRemote()) && (!isNullOrUndefined(this.parent.dataSource))) &&\n (!this.parent.dataSource.result)) {\n this.parent.dataSource['splice'](e.toIndex, 0, e.records[i - 1]);\n }\n }\n };\n Data.prototype.removeRows = function (e) {\n var json = this.dataManager.dataSource.json;\n if (this.parent.dataSource instanceof DataManager && this.dataManager.dataSource.offline) {\n this.dataManager.dataSource.json = json.filter(function (value) { return e.records.indexOf(value) === -1; });\n }\n else if (((!this.parent.getDataModule().isRemote()) && (!isNullOrUndefined(this.parent.dataSource))) &&\n (!this.parent.dataSource.result)) {\n this.parent.dataSource = json.filter(function (value) { return e.records.indexOf(value) === -1; });\n }\n };\n Data.prototype.getColumnByField = function (field) {\n var col;\n return (this.parent.columnModel).some(function (column) {\n col = column;\n return column.field === field;\n }) && col;\n };\n Data.prototype.destroy = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.rowsAdded, this.addRows);\n this.parent.off(events.rowsRemoved, this.removeRows);\n this.parent.off(events.dataSourceModified, this.initDataManager);\n this.parent.off(events.destroy, this.destroy);\n this.parent.off(events.updateData, this.crudActions);\n this.parent.off(events.addDeleteAction, this.getData);\n this.parent.off(events.autoCol, this.refreshFilteredCols);\n this.parent.off(events.columnsPrepared, this.refreshFilteredCols);\n };\n Data.prototype.getState = function () {\n return this.dataState;\n };\n Data.prototype.setState = function (state) {\n return this.dataState = state;\n };\n Data.prototype.getForeignKeyDataState = function () {\n return this.foreignKeyDataState;\n };\n Data.prototype.setForeignKeyDataState = function (state) {\n this.foreignKeyDataState = state;\n };\n Data.prototype.getStateEventArgument = function (query) {\n var adaptr = new UrlAdaptor();\n var dm = new DataManager({ url: '', adaptor: new UrlAdaptor });\n var state = adaptr.processQuery(dm, query);\n var data = JSON.parse(state.data);\n return extend(data, state.pvtData);\n };\n Data.prototype.eventPromise = function (args, query, key) {\n var _this = this;\n var dataArgs = args;\n var state = this.getStateEventArgument(query);\n var def = new Deferred();\n var deff = new Deferred();\n if ((args.requestType !== undefined || (this.parent.groupSettings.disablePageWiseAggregates && query.queries.some(function (query) { return query.fn === 'onGroup'; })))\n && this.dataState.isDataChanged !== false) {\n state.action = args;\n if (args.requestType === 'save' || args.requestType === 'delete') {\n var editArgs_1 = args;\n editArgs_1.key = key;\n var promise = 'promise';\n editArgs_1[\"\" + promise] = deff.promise;\n editArgs_1.state = state;\n this.setState({ isPending: true, resolver: deff.resolve });\n dataArgs.endEdit = deff.resolve;\n dataArgs.cancelEdit = deff.reject;\n this.parent.trigger(events.dataSourceChanged, editArgs_1);\n deff.promise.then(function () {\n _this.setState({ isPending: true, resolver: def.resolve, group: state.group, aggregates: state.aggregates });\n if (editArgs_1.requestType === 'save') {\n _this.parent.notify(events.recordAdded, editArgs_1);\n }\n _this.parent.trigger(events.dataStateChange, state);\n })\n .catch(function () { return void 0; });\n }\n else {\n this.setState({ isPending: true, resolver: def.resolve, group: state.group, aggregates: state.aggregates });\n this.parent.trigger(events.dataStateChange, state);\n }\n }\n else {\n this.setState({});\n def.resolve(this.parent.dataSource);\n }\n return def;\n };\n /**\n * Gets the columns where searching needs to be performed from the Grid.\n *\n * @returns {string[]} returns the searched column field names\n */\n Data.prototype.getSearchColumnFieldNames = function () {\n var colFieldNames = [];\n var columns = this.parent.getColumns();\n for (var _i = 0, columns_2 = columns; _i < columns_2.length; _i++) {\n var col = columns_2[_i];\n if (col.allowSearching && !isNullOrUndefined(col.field)) {\n colFieldNames.push(col.field);\n }\n }\n return colFieldNames;\n };\n Data.prototype.refreshFilteredCols = function () {\n if (this.parent.allowFiltering && this.parent.filterSettings.columns.length) {\n refreshFilteredColsUid(this.parent, this.parent.filterSettings.columns);\n }\n };\n return Data;\n}());\nexport { Data };\n","//! moment.js locale configuration\n//! locale : Uzbek [uz]\n//! author : Sardor Muminov : https://github.com/muminoff\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var uz = moment.defineLocale('uz', {\n months: 'Ñнвар_феврал_март_апрел_май_июн_июл_авгуÑÑ‚_ÑентÑбр_октÑбр_ноÑбр_декабр'.split(\n '_'\n ),\n monthsShort: 'Ñнв_фев_мар_апр_май_июн_июл_авг_Ñен_окт_ноÑ_дек'.split('_'),\n weekdays: 'Якшанба_Душанба_Сешанба_Чоршанба_Пайшанба_Жума_Шанба'.split('_'),\n weekdaysShort: 'Якш_Душ_Сеш_Чор_Пай_Жум_Шан'.split('_'),\n weekdaysMin: 'Як_Ду_Се_Чо_Па_Жу_Ша'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'D MMMM YYYY, dddd HH:mm',\n },\n calendar: {\n sameDay: '[Бугун Ñоат] LT [да]',\n nextDay: '[Ðртага] LT [да]',\n nextWeek: 'dddd [куни Ñоат] LT [да]',\n lastDay: '[Кеча Ñоат] LT [да]',\n lastWeek: '[Утган] dddd [куни Ñоат] LT [да]',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'Якин %s ичида',\n past: 'Бир неча %s олдин',\n s: 'фурÑат',\n ss: '%d фурÑат',\n m: 'бир дакика',\n mm: '%d дакика',\n h: 'бир Ñоат',\n hh: '%d Ñоат',\n d: 'бир кун',\n dd: '%d кун',\n M: 'бир ой',\n MM: '%d ой',\n y: 'бир йил',\n yy: '%d йил',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return uz;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable @typescript-eslint/no-unused-expressions */\nimport { Component, EventHandler, Internationalization } from '@syncfusion/ej2-base';\nimport { KeyboardEvents, L10n } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges } from '@syncfusion/ej2-base';\nimport { cldrData, getDefaultDateObject, rippleEffect } from '@syncfusion/ej2-base';\nimport { removeClass, detach, closest, addClass, attributes } from '@syncfusion/ej2-base';\nimport { getValue, getUniqueID, extend, Browser } from '@syncfusion/ej2-base';\nimport { Property, Event, isNullOrUndefined, throwError } from '@syncfusion/ej2-base';\n//class constant defination.\nvar OTHERMONTH = 'e-other-month';\nvar OTHERDECADE = 'e-other-year';\nvar ROOT = 'e-calendar';\nvar DEVICE = 'e-device';\nvar HEADER = 'e-header';\nvar RTL = 'e-rtl';\nvar CONTENT = 'e-content';\nvar CONTENTTABLE = 'e-calandar-content-table';\nvar YEAR = 'e-year';\nvar MONTH = 'e-month';\nvar DECADE = 'e-decade';\nvar ICON = 'e-icons';\nvar PREVICON = 'e-prev';\nvar NEXTICON = 'e-next';\nvar PREVSPAN = 'e-date-icon-prev';\nvar NEXTSPAN = 'e-date-icon-next ';\nvar ICONCONTAINER = 'e-icon-container';\nvar DISABLED = 'e-disabled';\nvar OVERLAY = 'e-overlay';\nvar WEEKEND = 'e-weekend';\nvar WEEKNUMBER = 'e-week-number';\nvar SELECTED = 'e-selected';\nvar FOCUSEDDATE = 'e-focused-date';\nvar FOCUSEDCELL = 'e-focused-cell';\nvar OTHERMONTHROW = 'e-month-hide';\nvar TODAY = 'e-today';\nvar TITLE = 'e-title';\nvar LINK = 'e-day';\nvar CELL = 'e-cell';\nvar WEEKHEADER = 'e-week-header';\nvar ZOOMIN = 'e-zoomin';\nvar FOOTER = 'e-footer-container';\nvar BTN = 'e-btn';\nvar FLAT = 'e-flat';\nvar CSS = 'e-css';\nvar PRIMARY = 'e-primary';\nvar DAYHEADERLONG = 'e-calendar-day-header-lg';\nvar dayMilliSeconds = 86400000;\nvar minutesMilliSeconds = 60000;\n/**\n *\n * @private\n */\nvar CalendarBase = /** @class */ (function (_super) {\n __extends(CalendarBase, _super);\n /**\n * Initialized new instance of Calendar Class.\n * Constructor for creating the widget\n *\n * @param {CalendarBaseModel} options - Specifies the CalendarBase model.\n * @param {string | HTMLElement} element - Specifies the element to render as component.\n * @private\n */\n function CalendarBase(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.effect = '';\n _this.isPopupClicked = false;\n _this.isDateSelected = true;\n _this.isTodayClicked = false;\n _this.preventChange = false;\n _this.isAngular = false;\n _this.previousDates = false;\n return _this;\n }\n /**\n * To Initialize the control rendering.\n *\n * @returns {void}\n * @private\n */\n CalendarBase.prototype.render = function () {\n this.rangeValidation(this.min, this.max);\n this.calendarEleCopy = this.element.cloneNode(true);\n if (this.calendarMode === 'Islamic') {\n if (+(this.min.setSeconds(0)) === +new Date(1900, 0, 1, 0, 0, 0)) {\n this.min = new Date(1944, 2, 18);\n }\n if (+this.max === +new Date(2099, 11, 31)) {\n this.max = new Date(2069, 10, 16);\n }\n }\n this.globalize = new Internationalization(this.locale);\n if (isNullOrUndefined(this.firstDayOfWeek) || this.firstDayOfWeek > 6 || this.firstDayOfWeek < 0) {\n this.setProperties({ firstDayOfWeek: this.globalize.getFirstDayOfWeek() }, true);\n }\n this.todayDisabled = false;\n this.todayDate = new Date(new Date().setHours(0, 0, 0, 0));\n if (this.getModuleName() === 'calendar') {\n this.element.classList.add(ROOT);\n if (this.enableRtl) {\n this.element.classList.add(RTL);\n }\n if (Browser.isDevice) {\n this.element.classList.add(DEVICE);\n }\n attributes(this.element, {\n 'data-role': 'calendar'\n });\n this.tabIndex = this.element.hasAttribute('tabindex') ? this.element.getAttribute('tabindex') : '0';\n this.element.setAttribute('tabindex', this.tabIndex);\n }\n else {\n this.calendarElement = this.createElement('div');\n this.calendarElement.classList.add(ROOT);\n if (this.enableRtl) {\n this.calendarElement.classList.add(RTL);\n }\n if (Browser.isDevice) {\n this.calendarElement.classList.add(DEVICE);\n }\n attributes(this.calendarElement, {\n 'data-role': 'calendar'\n });\n }\n if (!isNullOrUndefined(closest(this.element, 'fieldset')) && closest(this.element, 'fieldset').disabled) {\n this.enabled = false;\n }\n this.createHeader();\n this.createContent();\n this.wireEvents();\n };\n CalendarBase.prototype.rangeValidation = function (min, max) {\n if (isNullOrUndefined(min)) {\n this.setProperties({ min: new Date(1900, 0, 1) }, true);\n }\n if (isNullOrUndefined(max)) {\n this.setProperties({ max: new Date(2099, 11, 31) }, true);\n }\n };\n CalendarBase.prototype.getDefaultKeyConfig = function () {\n this.defaultKeyConfigs = {\n controlUp: 'ctrl+38',\n controlDown: 'ctrl+40',\n moveDown: 'downarrow',\n moveUp: 'uparrow',\n moveLeft: 'leftarrow',\n moveRight: 'rightarrow',\n select: 'enter',\n home: 'home',\n end: 'end',\n pageUp: 'pageup',\n pageDown: 'pagedown',\n shiftPageUp: 'shift+pageup',\n shiftPageDown: 'shift+pagedown',\n controlHome: 'ctrl+home',\n controlEnd: 'ctrl+end',\n altUpArrow: 'alt+uparrow',\n spacebar: 'space',\n altRightArrow: 'alt+rightarrow',\n altLeftArrow: 'alt+leftarrow'\n };\n return this.defaultKeyConfigs;\n };\n CalendarBase.prototype.validateDate = function (value) {\n this.setProperties({ min: this.checkDateValue(new Date(this.checkValue(this.min))) }, true);\n this.setProperties({ max: this.checkDateValue(new Date(this.checkValue(this.max))) }, true);\n this.currentDate = this.currentDate ? this.currentDate : new Date(new Date().setHours(0, 0, 0, 0));\n if (!isNullOrUndefined(value) && this.min <= this.max && value >= this.min && value <= this.max) {\n this.currentDate = new Date(this.checkValue(value));\n }\n };\n CalendarBase.prototype.setOverlayIndex = function (popupWrapper, popupElement, modal, isDevice) {\n if (isDevice && !isNullOrUndefined(popupElement) && !isNullOrUndefined(modal) && !isNullOrUndefined(popupWrapper)) {\n var index = parseInt(popupElement.style.zIndex, 10) ? parseInt(popupElement.style.zIndex, 10) : 1000;\n modal.style.zIndex = (index - 1).toString();\n popupWrapper.style.zIndex = index.toString();\n }\n };\n CalendarBase.prototype.minMaxUpdate = function (value) {\n if (!(+this.min <= +this.max)) {\n this.setProperties({ min: this.min }, true);\n addClass([this.element], OVERLAY);\n }\n else {\n removeClass([this.element], OVERLAY);\n }\n this.min = isNullOrUndefined(this.min) || !(+this.min) ? this.min = new Date(1900, 0, 1) : this.min;\n this.max = isNullOrUndefined(this.max) || !(+this.max) ? this.max = new Date(2099, 11, 31) : this.max;\n if (+this.min <= +this.max && value && +value <= +this.max && +value >= +this.min) {\n this.currentDate = new Date(this.checkValue(value));\n }\n else {\n if (+this.min <= +this.max && !value && +this.currentDate > +this.max) {\n this.currentDate = new Date(this.checkValue(this.max));\n }\n else {\n if (+this.currentDate < +this.min) {\n this.currentDate = new Date(this.checkValue(this.min));\n }\n }\n }\n };\n CalendarBase.prototype.createHeader = function () {\n var ariaPrevAttrs = {\n 'aria-disabled': 'false',\n 'aria-label': 'previous month'\n };\n var ariaNextAttrs = {\n 'aria-disabled': 'false',\n 'aria-label': 'next month'\n };\n var ariaTitleAttrs = {\n 'aria-atomic': 'true', 'aria-live': 'assertive', 'aria-label': 'title'\n };\n var tabIndexAttr = { 'tabindex': '0' };\n this.headerElement = this.createElement('div', { className: HEADER });\n var iconContainer = this.createElement('div', { className: ICONCONTAINER });\n this.previousIcon = this.createElement('button', { className: '' + PREVICON, attrs: { type: 'button' } });\n rippleEffect(this.previousIcon, {\n duration: 400,\n selector: '.e-prev',\n isCenterRipple: true\n });\n attributes(this.previousIcon, ariaPrevAttrs);\n attributes(this.previousIcon, tabIndexAttr);\n this.nextIcon = this.createElement('button', { className: '' + NEXTICON, attrs: { type: 'button' } });\n rippleEffect(this.nextIcon, {\n selector: '.e-next',\n duration: 400,\n isCenterRipple: true\n });\n if (this.getModuleName() === 'daterangepicker') {\n attributes(this.previousIcon, { tabIndex: '-1' });\n attributes(this.nextIcon, { tabIndex: '-1' });\n }\n attributes(this.nextIcon, ariaNextAttrs);\n attributes(this.nextIcon, tabIndexAttr);\n this.headerTitleElement = this.createElement('div', { className: '' + LINK + ' ' + TITLE });\n attributes(this.headerTitleElement, ariaTitleAttrs);\n attributes(this.headerTitleElement, tabIndexAttr);\n this.headerElement.appendChild(this.headerTitleElement);\n this.previousIcon.appendChild(this.createElement('span', { className: '' + PREVSPAN + ' ' + ICON }));\n this.nextIcon.appendChild(this.createElement('span', { className: '' + NEXTSPAN + ' ' + ICON }));\n iconContainer.appendChild(this.previousIcon);\n iconContainer.appendChild(this.nextIcon);\n this.headerElement.appendChild(iconContainer);\n if (this.getModuleName() === 'calendar') {\n this.element.appendChild(this.headerElement);\n }\n else {\n this.calendarElement.appendChild(this.headerElement);\n }\n this.adjustLongHeaderSize();\n };\n CalendarBase.prototype.createContent = function () {\n this.contentElement = this.createElement('div', { className: CONTENT });\n this.table = this.createElement('table', { attrs: { 'class': CONTENTTABLE, 'tabIndex': '0', 'role': 'grid', 'aria-activedescendant': '', 'aria-labelledby': this.element.id } });\n if (this.getModuleName() === 'calendar') {\n this.element.appendChild(this.contentElement);\n }\n else {\n this.calendarElement.appendChild(this.contentElement);\n }\n this.contentElement.appendChild(this.table);\n this.createContentHeader();\n this.createContentBody();\n if (this.showTodayButton) {\n this.createContentFooter();\n }\n if (this.getModuleName() != 'daterangepicker') {\n EventHandler.add(this.table, 'focus', this.addContentFocus, this);\n EventHandler.add(this.table, 'blur', this.removeContentFocus, this);\n }\n };\n CalendarBase.prototype.addContentFocus = function (args) {\n var focusedDate = this.tableBodyElement.querySelector('tr td.e-focused-date');\n var selectedDate = this.tableBodyElement.querySelector('tr td.e-selected');\n if (!isNullOrUndefined(selectedDate)) {\n selectedDate.classList.add(FOCUSEDCELL);\n }\n else if (!isNullOrUndefined(focusedDate)) {\n focusedDate.classList.add(FOCUSEDCELL);\n }\n };\n CalendarBase.prototype.removeContentFocus = function (args) {\n var focusedDate = this.tableBodyElement.querySelector('tr td.e-focused-date');\n var selectedDate = this.tableBodyElement.querySelector('tr td.e-selected');\n if (!isNullOrUndefined(selectedDate)) {\n selectedDate.classList.remove(FOCUSEDCELL);\n }\n else if (!isNullOrUndefined(focusedDate)) {\n focusedDate.classList.remove(FOCUSEDCELL);\n }\n };\n CalendarBase.prototype.getCultureValues = function () {\n var culShortNames = [];\n var cldrObj;\n var dayFormat = 'days.stand-alone.' + this.dayHeaderFormat.toLowerCase();\n if (this.locale === 'en' || this.locale === 'en-US') {\n cldrObj = (getValue(dayFormat, getDefaultDateObject()));\n }\n else {\n cldrObj = (this.getCultureObjects(cldrData, '' + this.locale));\n }\n if (!isNullOrUndefined(cldrObj)) {\n for (var _i = 0, _a = Object.keys(cldrObj); _i < _a.length; _i++) {\n var obj = _a[_i];\n culShortNames.push(getValue(obj, cldrObj));\n }\n }\n return culShortNames;\n };\n CalendarBase.prototype.toCapitalize = function (text) {\n return !isNullOrUndefined(text) && text.length ? text[0].toUpperCase() + text.slice(1) : text;\n };\n CalendarBase.prototype.createContentHeader = function () {\n if (this.getModuleName() === 'calendar') {\n if (!isNullOrUndefined(this.element.querySelectorAll('.e-content .e-week-header')[0])) {\n detach(this.element.querySelectorAll('.e-content .e-week-header')[0]);\n }\n }\n else {\n if (!isNullOrUndefined(this.calendarElement.querySelectorAll('.e-content .e-week-header')[0])) {\n detach(this.calendarElement.querySelectorAll('.e-content .e-week-header')[0]);\n }\n }\n var daysCount = 6;\n var html = '';\n if (this.firstDayOfWeek > 6 || this.firstDayOfWeek < 0) {\n this.setProperties({ firstDayOfWeek: 0 }, true);\n }\n this.tableHeadElement = this.createElement('thead', { className: WEEKHEADER });\n if (this.weekNumber) {\n html += '<th class=\"e-week-number\" aria-hidden=\"true\"></th>';\n if (this.getModuleName() === 'calendar') {\n addClass([this.element], '' + WEEKNUMBER);\n }\n else {\n addClass([this.calendarElement], '' + WEEKNUMBER);\n }\n }\n // eslint-disable-next-line max-len\n var shortNames = this.getCultureValues().length > 0 && this.getCultureValues() ? this.shiftArray(((this.getCultureValues().length > 0 && this.getCultureValues())), this.firstDayOfWeek) : null;\n if (!isNullOrUndefined(shortNames)) {\n for (var days = 0; days <= daysCount; days++) {\n html += '<th class=\"\">' + this.toCapitalize(shortNames[days]) + '</th>';\n }\n }\n html = '<tr>' + html + '</tr>';\n this.tableHeadElement.innerHTML = html;\n this.table.appendChild(this.tableHeadElement);\n };\n CalendarBase.prototype.createContentBody = function () {\n if (this.getModuleName() === 'calendar') {\n if (!isNullOrUndefined(this.element.querySelectorAll('.e-content tbody')[0])) {\n detach(this.element.querySelectorAll('.e-content tbody')[0]);\n }\n }\n else {\n if (!isNullOrUndefined(this.calendarElement.querySelectorAll('.e-content tbody')[0])) {\n detach(this.calendarElement.querySelectorAll('.e-content tbody')[0]);\n }\n }\n switch (this.start) {\n case 'Year':\n this.renderYears();\n break;\n case 'Decade':\n this.renderDecades();\n break;\n default:\n this.renderMonths();\n }\n };\n CalendarBase.prototype.updateFooter = function () {\n this.todayElement.textContent = this.l10.getConstant('today');\n this.todayElement.setAttribute('aria-label', this.l10.getConstant('today'));\n this.todayElement.setAttribute('tabindex', '0');\n };\n CalendarBase.prototype.createContentFooter = function () {\n if (this.showTodayButton) {\n var minimum = new Date(+this.min);\n var maximum = new Date(+this.max);\n var l10nLocale = { today: 'Today' };\n this.globalize = new Internationalization(this.locale);\n this.l10 = new L10n(this.getModuleName(), l10nLocale, this.locale);\n this.todayElement = this.createElement('button', { attrs: { role: 'button' } });\n rippleEffect(this.todayElement);\n this.updateFooter();\n addClass([this.todayElement], [BTN, TODAY, FLAT, PRIMARY, CSS]);\n if ((!(+new Date(minimum.setHours(0, 0, 0, 0)) <= +this.todayDate &&\n +this.todayDate <= +new Date(maximum.setHours(0, 0, 0, 0)))) || (this.todayDisabled)) {\n addClass([this.todayElement], DISABLED);\n }\n this.footer = this.createElement('div', { className: FOOTER });\n this.footer.appendChild(this.todayElement);\n if (this.getModuleName() === 'calendar') {\n this.element.appendChild(this.footer);\n }\n if (this.getModuleName() === 'datepicker') {\n this.calendarElement.appendChild(this.footer);\n }\n if (this.getModuleName() === 'datetimepicker') {\n this.calendarElement.appendChild(this.footer);\n }\n if (!this.todayElement.classList.contains(DISABLED)) {\n EventHandler.add(this.todayElement, 'click', this.todayButtonClick, this);\n }\n }\n };\n CalendarBase.prototype.wireEvents = function (id, ref, keyConfig, moduleName) {\n EventHandler.add(this.headerTitleElement, 'click', this.navigateTitle, this);\n this.defaultKeyConfigs = extend(this.defaultKeyConfigs, this.keyConfigs);\n if (this.getModuleName() === 'calendar') {\n this.keyboardModule = new KeyboardEvents(this.element, {\n eventName: 'keydown',\n keyAction: this.keyActionHandle.bind(this),\n keyConfigs: this.defaultKeyConfigs\n });\n }\n else {\n this.keyboardModule = new KeyboardEvents(this.calendarElement, {\n eventName: 'keydown',\n keyAction: this.keyActionHandle.bind(this),\n keyConfigs: this.defaultKeyConfigs\n });\n }\n };\n CalendarBase.prototype.dateWireEvents = function (id, ref, keyConfig, moduleName) {\n this.defaultKeyConfigs = this.getDefaultKeyConfig();\n this.defaultKeyConfigs = extend(this.defaultKeyConfigs, keyConfig);\n this.serverModuleName = moduleName;\n };\n CalendarBase.prototype.todayButtonClick = function (e, value, isCustomDate) {\n if (this.showTodayButton) {\n if (this.currentView() === this.depth) {\n this.effect = '';\n }\n else {\n this.effect = 'e-zoomin';\n }\n if (this.getViewNumber(this.start) >= this.getViewNumber(this.depth)) {\n this.navigateTo(this.depth, new Date(this.checkValue(value)), isCustomDate);\n }\n else {\n this.navigateTo('Month', new Date(this.checkValue(value)), isCustomDate);\n }\n }\n };\n CalendarBase.prototype.resetCalendar = function () {\n this.calendarElement && detach(this.calendarElement);\n this.tableBodyElement && detach(this.tableBodyElement);\n this.table && detach(this.table);\n this.tableHeadElement && detach(this.tableHeadElement);\n this.nextIcon && detach(this.nextIcon);\n this.previousIcon && detach(this.previousIcon);\n this.footer && detach(this.footer);\n this.todayElement = null;\n this.renderDayCellArgs = null;\n this.calendarElement = this.tableBodyElement = this.footer = this.tableHeadElement =\n this.nextIcon = this.previousIcon = this.table = null;\n };\n CalendarBase.prototype.keyActionHandle = function (e, value, multiSelection) {\n var focusedDate = this.tableBodyElement.querySelector('tr td.e-focused-date');\n var selectedDate;\n if (multiSelection) {\n if (!isNullOrUndefined(focusedDate) && +value === parseInt(focusedDate.getAttribute('id').split('_')[0], 10)) {\n selectedDate = focusedDate;\n }\n else {\n selectedDate = this.tableBodyElement.querySelector('tr td.e-selected');\n }\n }\n else {\n selectedDate = this.tableBodyElement.querySelector('tr td.e-selected');\n }\n var view = this.getViewNumber(this.currentView());\n var depthValue = this.getViewNumber(this.depth);\n var levelRestrict = (view === depthValue && this.getViewNumber(this.start) >= depthValue);\n this.effect = '';\n switch (e.action) {\n case 'moveLeft':\n if (this.getModuleName() != 'daterangepicker' && !isNullOrUndefined(e.target) && e.target.classList.length > 0 && e.target.classList.contains(CONTENTTABLE)) {\n this.keyboardNavigate(-1, view, e, this.max, this.min);\n e.preventDefault();\n }\n break;\n case 'moveRight':\n if (this.getModuleName() != 'daterangepicker' && !isNullOrUndefined(e.target) && e.target.classList.length > 0 && e.target.classList.contains(CONTENTTABLE)) {\n this.keyboardNavigate(1, view, e, this.max, this.min);\n e.preventDefault();\n }\n break;\n case 'moveUp':\n if (this.getModuleName() != 'daterangepicker' && !isNullOrUndefined(e.target) && e.target.classList.length > 0 && e.target.classList.contains(CONTENTTABLE)) {\n if (view === 0) {\n this.keyboardNavigate(-7, view, e, this.max, this.min); // move the current date to the previous seven days.\n }\n else {\n this.keyboardNavigate(-4, view, e, this.max, this.min); // move the current year to the previous four days.\n }\n e.preventDefault();\n }\n break;\n case 'moveDown':\n if (this.getModuleName() != 'daterangepicker' && !isNullOrUndefined(e.target) && e.target.classList.length > 0 && e.target.classList.contains(CONTENTTABLE)) {\n if (view === 0) {\n this.keyboardNavigate(7, view, e, this.max, this.min);\n }\n else {\n this.keyboardNavigate(4, view, e, this.max, this.min);\n }\n e.preventDefault();\n }\n break;\n case 'select':\n if (e.target === this.headerTitleElement) {\n this.navigateTitle(e);\n }\n else if (e.target === this.previousIcon) {\n this.navigatePrevious(e);\n }\n else if (e.target === this.nextIcon) {\n this.navigateNext(e);\n }\n else if (e.target === this.todayElement) {\n this.todayButtonClick(e, value);\n if (this.getModuleName() === 'datepicker' || this.getModuleName() === 'datetimepicker') {\n this.element.focus();\n }\n }\n else {\n var element = !isNullOrUndefined(focusedDate) ? focusedDate : selectedDate;\n if (!isNullOrUndefined(element) && !element.classList.contains(DISABLED)) {\n if (levelRestrict) {\n // eslint-disable-next-line radix\n var d = new Date(parseInt('' + (element).id, 0));\n this.selectDate(e, d, (element));\n }\n else {\n this.contentClick(null, --view, (element), value);\n }\n if (this.getModuleName() === 'datepicker' || this.getModuleName() === 'datetimepicker') {\n this.element.focus();\n }\n }\n }\n break;\n case 'controlUp':\n this.title();\n e.preventDefault();\n break;\n case 'controlDown':\n if (!isNullOrUndefined(focusedDate) && !levelRestrict || !isNullOrUndefined(selectedDate) && !levelRestrict) {\n this.contentClick(null, --view, (focusedDate || selectedDate), value);\n }\n e.preventDefault();\n break;\n case 'home':\n this.currentDate = this.firstDay(this.currentDate);\n detach(this.tableBodyElement);\n if (view === 0) {\n this.renderMonths(e);\n }\n else if (view === 1) {\n this.renderYears(e);\n }\n else {\n this.renderDecades(e);\n }\n e.preventDefault();\n break;\n case 'end':\n this.currentDate = this.lastDay(this.currentDate, view);\n detach(this.tableBodyElement);\n if (view === 0) {\n this.renderMonths(e);\n }\n else if (view === 1) {\n this.renderYears(e);\n }\n else {\n this.renderDecades(e);\n }\n e.preventDefault();\n break;\n case 'pageUp':\n this.addMonths(this.currentDate, -1);\n this.navigateTo('Month', this.currentDate);\n e.preventDefault();\n break;\n case 'pageDown':\n this.addMonths(this.currentDate, 1);\n this.navigateTo('Month', this.currentDate);\n e.preventDefault();\n break;\n case 'shiftPageUp':\n this.addYears(this.currentDate, -1);\n this.navigateTo('Month', this.currentDate);\n e.preventDefault();\n break;\n case 'shiftPageDown':\n this.addYears(this.currentDate, 1);\n this.navigateTo('Month', this.currentDate);\n e.preventDefault();\n break;\n case 'controlHome':\n this.navigateTo('Month', new Date(this.currentDate.getFullYear(), 0, 1));\n e.preventDefault();\n break;\n case 'controlEnd':\n this.navigateTo('Month', new Date(this.currentDate.getFullYear(), 11, 31));\n e.preventDefault();\n break;\n case 'tab':\n if ((this.getModuleName() === 'datepicker' || this.getModuleName() === 'datetimepicker') && e.target === this.todayElement) {\n e.preventDefault();\n this.element.focus();\n this.hide();\n }\n break;\n case 'shiftTab':\n if ((this.getModuleName() === 'datepicker' || this.getModuleName() === 'datetimepicker') && e.target === this.headerTitleElement) {\n e.preventDefault();\n this.element.focus();\n this.hide();\n }\n break;\n }\n };\n CalendarBase.prototype.keyboardNavigate = function (number, currentView, e, max, min) {\n var date = new Date(this.checkValue(this.currentDate));\n switch (currentView) {\n case 2:\n this.addYears(this.currentDate, number);\n if (this.isMonthYearRange(this.currentDate)) {\n detach(this.tableBodyElement);\n this.renderDecades(e);\n }\n else {\n this.currentDate = date;\n }\n break;\n case 1:\n this.addMonths(this.currentDate, number);\n if (this.calendarMode === 'Gregorian') {\n if (this.isMonthYearRange(this.currentDate)) {\n detach(this.tableBodyElement);\n this.renderYears(e);\n }\n else {\n this.currentDate = date;\n }\n }\n else {\n if (this.isMonthYearRange(this.currentDate)) {\n detach(this.tableBodyElement);\n this.renderYears(e);\n }\n else {\n this.currentDate = date;\n }\n }\n break;\n case 0:\n this.addDay(this.currentDate, number, e, max, min);\n if (this.isMinMaxRange(this.currentDate)) {\n detach(this.tableBodyElement);\n this.renderMonths(e);\n }\n else {\n this.currentDate = date;\n }\n break;\n }\n };\n /**\n * Initialize the event handler\n *\n * @param {Date} value - Specifies value of date.\n * @returns {void}\n * @private\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n CalendarBase.prototype.preRender = function (value) {\n var _this = this;\n this.navigatePreviousHandler = this.navigatePrevious.bind(this);\n this.navigateNextHandler = this.navigateNext.bind(this);\n this.defaultKeyConfigs = this.getDefaultKeyConfig();\n this.navigateHandler = function (e) {\n _this.triggerNavigate(e);\n };\n };\n CalendarBase.prototype.minMaxDate = function (localDate) {\n var currentDate = new Date(new Date(+localDate).setHours(0, 0, 0, 0));\n var minDate = new Date(new Date(+this.min).setHours(0, 0, 0, 0));\n var maxDate = new Date(new Date(+this.max).setHours(0, 0, 0, 0));\n if (+currentDate === +minDate || +currentDate === +maxDate) {\n if (+localDate < +this.min) {\n localDate = new Date(+this.min);\n }\n if (+localDate > +this.max) {\n localDate = new Date(+this.max);\n }\n }\n return localDate;\n };\n CalendarBase.prototype.renderMonths = function (e, value, isCustomDate) {\n var numCells = this.weekNumber ? 8 : 7;\n var tdEles;\n if (this.calendarMode === 'Gregorian') {\n tdEles = this.renderDays(this.currentDate, value, null, null, isCustomDate, e);\n }\n else {\n tdEles = this.islamicModule.islamicRenderDays(this.currentDate, value);\n }\n this.createContentHeader();\n if (this.calendarMode === 'Gregorian') {\n this.renderTemplate(tdEles, numCells, MONTH, e, value);\n }\n else {\n this.islamicModule.islamicRenderTemplate(tdEles, numCells, MONTH, e, value);\n }\n };\n CalendarBase.prototype.renderDays = function (currentDate, value, multiSelection, values, isTodayDate, e) {\n var tdEles = [];\n var cellsCount = 42;\n var todayDate = isTodayDate ? new Date(+currentDate) : this.getDate(new Date(), this.timezone);\n var localDate = new Date(this.checkValue(currentDate));\n var minMaxDate;\n var currentMonth = localDate.getMonth();\n this.titleUpdate(currentDate, 'days');\n var d = localDate;\n localDate = new Date(d.getFullYear(), d.getMonth(), 0, d.getHours(), d.getMinutes(), d.getSeconds(), d.getMilliseconds());\n while (localDate.getDay() !== this.firstDayOfWeek) {\n this.setStartDate(localDate, -1 * dayMilliSeconds);\n }\n for (var day = 0; day < cellsCount; ++day) {\n var weekEle = this.createElement('td', { className: CELL });\n var weekAnchor = this.createElement('span');\n if (day % 7 === 0 && this.weekNumber) {\n // 6 days are added to get Last day of the week and 3 days are added to get middle day of the week.\n var numberOfDays = this.weekRule === 'FirstDay' ? 6 : (this.weekRule === 'FirstFourDayWeek' ? 3 : 0);\n var finalDate = new Date(localDate.getFullYear(), localDate.getMonth(), (localDate.getDate() + numberOfDays));\n weekAnchor.textContent = '' + this.getWeek(finalDate);\n weekEle.appendChild(weekAnchor);\n addClass([weekEle], '' + WEEKNUMBER);\n tdEles.push(weekEle);\n }\n minMaxDate = new Date(+localDate);\n localDate = this.minMaxDate(localDate);\n var dateFormatOptions = { type: 'dateTime', skeleton: 'full' };\n var date = this.globalize.parseDate(this.globalize.formatDate(localDate, dateFormatOptions), dateFormatOptions);\n var tdEle = this.dayCell(localDate);\n var title = this.globalize.formatDate(localDate, { type: 'date', skeleton: 'full' });\n var dayLink = this.createElement('span');\n dayLink.textContent = this.globalize.formatDate(localDate, { format: 'd', type: 'date', skeleton: 'yMd' });\n var disabled = (this.min > localDate) || (this.max < localDate);\n if (disabled) {\n addClass([tdEle], DISABLED);\n addClass([tdEle], OVERLAY);\n }\n else {\n dayLink.setAttribute('title', '' + title);\n }\n if (currentMonth !== localDate.getMonth()) {\n addClass([tdEle], OTHERMONTH);\n dayLink.setAttribute('aria-disabled', 'true');\n }\n if (localDate.getDay() === 0 || localDate.getDay() === 6) {\n addClass([tdEle], WEEKEND);\n }\n tdEle.appendChild(dayLink);\n this.renderDayCellArgs = {\n date: localDate,\n isDisabled: false,\n element: tdEle,\n isOutOfRange: disabled\n };\n var argument = this.renderDayCellArgs;\n this.renderDayCellEvent(argument);\n if (argument.isDisabled) {\n var selectDate = new Date(this.checkValue(value));\n var argsDate = new Date(this.checkValue(argument.date));\n if (multiSelection) {\n if (!isNullOrUndefined(values) && values.length > 0) {\n for (var index = 0; index < values.length; index++) {\n var localDateString = +new Date(this.globalize.formatDate(argument.date, { type: 'date', skeleton: 'yMd' }));\n var tempDateString = +new Date(this.globalize.formatDate(values[index], { type: 'date', skeleton: 'yMd' }));\n if (localDateString === tempDateString) {\n values.splice(index, 1);\n index = -1;\n }\n }\n }\n }\n else if (selectDate && +selectDate === +argsDate) {\n this.setProperties({ value: null }, true);\n }\n }\n if (this.renderDayCellArgs.isDisabled && !tdEle.classList.contains(SELECTED)) {\n addClass([tdEle], DISABLED);\n addClass([tdEle], OVERLAY);\n dayLink.setAttribute('aria-disabled', 'true');\n if (+this.renderDayCellArgs.date === +this.todayDate) {\n this.todayDisabled = true;\n }\n }\n var otherMnthBool = tdEle.classList.contains(OTHERMONTH);\n var disabledCls = tdEle.classList.contains(DISABLED);\n if (!disabledCls) {\n EventHandler.add(tdEle, 'click', this.clickHandler, this);\n }\n // to set the value as null while setting the disabled date onProperty change.\n // if (args.isDisabled && +this.value === +args.date) {\n // this.setProperties({ value: null }, true);\n // }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var currentTarget = void 0;\n if (!isNullOrUndefined(e) && e.type === 'click') {\n currentTarget = e.currentTarget;\n }\n if (multiSelection && !isNullOrUndefined(values) && !disabledCls) {\n for (var tempValue = 0; tempValue < values.length; tempValue++) {\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var formatOptions = { format: null, type: 'date', skeleton: 'short', calendar: type };\n var localDateString = this.globalize.formatDate(localDate, formatOptions);\n var tempDateString = this.globalize.formatDate(values[tempValue], formatOptions);\n if ((localDateString === tempDateString && this.getDateVal(localDate, values[tempValue]))\n || (this.getDateVal(localDate, value))) {\n addClass([tdEle], SELECTED);\n }\n if (!isNullOrUndefined(currentTarget) && currentTarget.innerText === tdEle.innerText &&\n this.previousDates && tdEle.classList.contains(SELECTED) && currentTarget.classList.contains(SELECTED)) {\n removeClass([tdEle], SELECTED);\n this.previousDates = false;\n var copyValues = this.copyValues(values);\n for (var i = 0; i < copyValues.length; i++) {\n var type_1 = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var formatOptions_1 = { format: null, type: 'date', skeleton: 'short', calendar: type_1 };\n var localDateString_1 = this.globalize.formatDate(date, formatOptions_1);\n var tempDateString_1 = this.globalize.formatDate(copyValues[i], formatOptions_1);\n if (localDateString_1 === tempDateString_1) {\n var index = copyValues.indexOf(copyValues[i]);\n copyValues.splice(index, 1);\n values.splice(index, 1);\n }\n }\n this.setProperties({ values: copyValues }, true);\n }\n else {\n this.updateFocus(otherMnthBool, disabledCls, localDate, tdEle, currentDate);\n }\n }\n if (values.length <= 0) {\n this.updateFocus(otherMnthBool, disabledCls, localDate, tdEle, currentDate);\n }\n }\n else if (!disabledCls && this.getDateVal(localDate, value)) {\n addClass([tdEle], SELECTED);\n }\n this.updateFocus(otherMnthBool, disabledCls, localDate, tdEle, currentDate);\n if (!isNullOrUndefined(date) && date.getFullYear() === todayDate.getFullYear() && date.getMonth() === todayDate.getMonth()\n && date.getDate() === todayDate.getDate()) {\n addClass([tdEle], TODAY);\n }\n tdEles.push(this.renderDayCellArgs.element);\n localDate = new Date(+minMaxDate);\n this.addDay(localDate, 1, null, this.max, this.min);\n }\n return tdEles;\n };\n CalendarBase.prototype.updateFocus = function (otherMonth, disabled, localDate, tableElement, currentDate) {\n if (currentDate.getDate() === localDate.getDate() && !otherMonth && !disabled) {\n addClass([tableElement], FOCUSEDDATE);\n }\n else {\n // eslint-disable-next-line radix\n if (currentDate >= this.max && parseInt(tableElement.id, 0) === +this.max && !otherMonth && !disabled) {\n addClass([tableElement], FOCUSEDDATE);\n }\n // eslint-disable-next-line radix\n if (currentDate <= this.min && parseInt(tableElement.id, 0) === +this.min && !otherMonth && !disabled) {\n addClass([tableElement], FOCUSEDDATE);\n }\n }\n };\n CalendarBase.prototype.renderYears = function (e, value) {\n this.removeTableHeadElement();\n var numCells = 4;\n var tdEles = [];\n var valueUtil = isNullOrUndefined(value);\n var curDate = new Date(this.checkValue(this.currentDate));\n var mon = curDate.getMonth();\n var yr = curDate.getFullYear();\n var localDate = curDate;\n var curYrs = localDate.getFullYear();\n var minYr = new Date(this.checkValue(this.min)).getFullYear();\n var minMonth = new Date(this.checkValue(this.min)).getMonth();\n var maxYr = new Date(this.checkValue(this.max)).getFullYear();\n var maxMonth = new Date(this.checkValue(this.max)).getMonth();\n localDate.setMonth(0);\n this.titleUpdate(this.currentDate, 'months');\n localDate.setDate(1);\n for (var month = 0; month < 12; ++month) {\n var tdEle = this.dayCell(localDate);\n var dayLink = this.createElement('span');\n var localMonth = (value && (value).getMonth() === localDate.getMonth());\n var select = (value && (value).getFullYear() === yr && localMonth);\n var title = this.globalize.formatDate(localDate, { type: 'date', format: 'MMM y' });\n dayLink.textContent = this.toCapitalize(this.globalize.formatDate(localDate, {\n format: null, type: 'dateTime', skeleton: 'MMM'\n }));\n if ((this.min && (curYrs < minYr || (month < minMonth && curYrs === minYr))) || (this.max && (curYrs > maxYr || (month > maxMonth && curYrs >= maxYr)))) {\n addClass([tdEle], DISABLED);\n }\n else if (!valueUtil && select) {\n addClass([tdEle], SELECTED);\n }\n else {\n if (localDate.getMonth() === mon && this.currentDate.getMonth() === mon) {\n addClass([tdEle], FOCUSEDDATE);\n }\n }\n localDate.setDate(1);\n localDate.setMonth(localDate.getMonth() + 1);\n if (!tdEle.classList.contains(DISABLED)) {\n EventHandler.add(tdEle, 'click', this.clickHandler, this);\n dayLink.setAttribute('title', '' + title);\n }\n tdEle.appendChild(dayLink);\n tdEles.push(tdEle);\n }\n this.renderTemplate(tdEles, numCells, YEAR, e, value);\n };\n CalendarBase.prototype.renderDecades = function (e, value) {\n this.removeTableHeadElement();\n var numCells = 4;\n var yearCell = 12;\n var tdEles = [];\n var localDate = new Date(this.checkValue(this.currentDate));\n localDate.setMonth(0);\n localDate.setDate(1);\n var localYr = localDate.getFullYear();\n var startYr = new Date(localDate.setFullYear((localYr - localYr % 10)));\n var endYr = new Date(localDate.setFullYear((localYr - localYr % 10 + (10 - 1))));\n var startFullYr = startYr.getFullYear();\n var endFullYr = endYr.getFullYear();\n var startHdrYr = this.globalize.formatDate(startYr, {\n format: null, type: 'dateTime', skeleton: 'y'\n });\n var endHdrYr = this.globalize.formatDate(endYr, { format: null, type: 'dateTime', skeleton: 'y' });\n this.headerTitleElement.textContent = startHdrYr + ' - ' + (endHdrYr);\n var start = new Date(localYr - (localYr % 10) - 1, 0, 1);\n var startYear = start.getFullYear();\n for (var rowIterator = 0; rowIterator < yearCell; ++rowIterator) {\n var year = startYear + rowIterator;\n localDate.setFullYear(year);\n var tdEle = this.dayCell(localDate);\n var dayLink = this.createElement('span');\n dayLink.textContent = this.globalize.formatDate(localDate, {\n format: null, type: 'dateTime', skeleton: 'y'\n });\n if ((year < startFullYr) || (year > endFullYr)) {\n addClass([tdEle], OTHERDECADE);\n dayLink.setAttribute('aria-disabled', 'true');\n if (!isNullOrUndefined(value) && localDate.getFullYear() === (value).getFullYear()) {\n addClass([tdEle], SELECTED);\n }\n if (year < new Date(this.checkValue(this.min)).getFullYear() ||\n year > new Date(this.checkValue(this.max)).getFullYear()) {\n addClass([tdEle], DISABLED);\n }\n }\n else if (year < new Date(this.checkValue(this.min)).getFullYear() ||\n year > new Date(this.checkValue(this.max)).getFullYear()) {\n addClass([tdEle], DISABLED);\n }\n else if (!isNullOrUndefined(value) && localDate.getFullYear() === (value).getFullYear()) {\n addClass([tdEle], SELECTED);\n }\n else {\n if (localDate.getFullYear() === this.currentDate.getFullYear() && !tdEle.classList.contains(DISABLED)) {\n addClass([tdEle], FOCUSEDDATE);\n }\n }\n if (!tdEle.classList.contains(DISABLED)) {\n EventHandler.add(tdEle, 'click', this.clickHandler, this);\n dayLink.setAttribute('title', '' + dayLink.textContent);\n }\n tdEle.appendChild(dayLink);\n tdEles.push(tdEle);\n }\n this.renderTemplate(tdEles, numCells, 'e-decade', e, value);\n };\n CalendarBase.prototype.dayCell = function (localDate) {\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var dateFormatOptions = { skeleton: 'full', type: 'dateTime', calendar: type };\n var date = this.globalize.parseDate(this.globalize.formatDate(localDate, dateFormatOptions), dateFormatOptions);\n var value;\n if (!isNullOrUndefined(date)) {\n value = date.valueOf();\n }\n var attrs = {\n className: CELL, attrs: { 'id': '' + getUniqueID('' + value), 'aria-selected': 'false' }\n };\n return this.createElement('td', attrs);\n };\n CalendarBase.prototype.firstDay = function (date) {\n var collection = this.currentView() !== 'Decade' ? this.tableBodyElement.querySelectorAll('td' + ':not(.' + OTHERMONTH + '') :\n this.tableBodyElement.querySelectorAll('td' + ':not(.' + OTHERDECADE + '');\n if (collection.length) {\n for (var i = 0; i < collection.length; i++) {\n if (!collection[i].classList.contains(DISABLED)) {\n // eslint-disable-next-line radix\n date = new Date(parseInt(collection[i].id, 0));\n break;\n }\n }\n }\n return date;\n };\n CalendarBase.prototype.lastDay = function (date, view) {\n var lastDate = new Date(date.getFullYear(), date.getMonth() + 1, 0);\n if (view !== 2) {\n var timeOffset = Math.abs(lastDate.getTimezoneOffset() - this.firstDay(date).getTimezoneOffset());\n if (timeOffset) {\n lastDate.setHours(this.firstDay(date).getHours() + (timeOffset / 60));\n }\n return this.findLastDay(lastDate);\n }\n else {\n return this.findLastDay(this.firstDay(lastDate));\n }\n };\n CalendarBase.prototype.checkDateValue = function (value) {\n return (!isNullOrUndefined(value) && value instanceof Date && !isNaN(+value)) ? value : null;\n };\n CalendarBase.prototype.findLastDay = function (date) {\n var collection = this.currentView() === 'Decade' ? this.tableBodyElement.querySelectorAll('td' + ':not(.' + OTHERDECADE + '') :\n this.tableBodyElement.querySelectorAll('td' + ':not(.' + OTHERMONTH + '');\n if (collection.length) {\n for (var i = collection.length - 1; i >= 0; i--) {\n if (!collection[i].classList.contains(DISABLED)) {\n // eslint-disable-next-line radix\n date = new Date(parseInt(collection[i].id, 0));\n break;\n }\n }\n }\n return date;\n };\n CalendarBase.prototype.removeTableHeadElement = function () {\n if (this.getModuleName() === 'calendar') {\n if (!isNullOrUndefined(this.element.querySelectorAll('.e-content table thead')[0])) {\n detach(this.tableHeadElement);\n }\n }\n else {\n if (!isNullOrUndefined(this.calendarElement.querySelectorAll('.e-content table thead')[0])) {\n detach(this.tableHeadElement);\n }\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n CalendarBase.prototype.renderTemplate = function (elements, count, classNm, e, value) {\n var view = this.getViewNumber(this.currentView());\n var trEle;\n this.tableBodyElement = this.createElement('tbody');\n this.table.appendChild(this.tableBodyElement);\n removeClass([this.contentElement, this.headerElement], [MONTH, DECADE, YEAR]);\n addClass([this.contentElement, this.headerElement], [classNm]);\n var weekNumCell = 41;\n var numberCell = 35;\n var otherMonthCell = 6;\n var row = count;\n var rowIterator = 0;\n for (var dayCell = 0; dayCell < elements.length / count; ++dayCell) {\n trEle = this.createElement('tr');\n for (rowIterator = 0 + rowIterator; rowIterator < row; rowIterator++) {\n if (!elements[rowIterator].classList.contains('e-week-number') && !isNullOrUndefined(elements[rowIterator].children[0])) {\n addClass([elements[rowIterator].children[0]], [LINK]);\n rippleEffect(elements[rowIterator].children[0], {\n duration: 600,\n isCenterRipple: true\n });\n }\n trEle.appendChild(elements[rowIterator]);\n if (this.weekNumber && rowIterator === otherMonthCell + 1 && elements[otherMonthCell + 1].classList.contains(OTHERMONTH)) {\n addClass([trEle], OTHERMONTHROW);\n }\n if (!this.weekNumber && rowIterator === otherMonthCell && elements[otherMonthCell].\n classList.contains(OTHERMONTH)) {\n addClass([trEle], OTHERMONTHROW);\n }\n if (this.weekNumber) {\n if (rowIterator === weekNumCell && elements[weekNumCell].classList.contains(OTHERMONTH)) {\n addClass([trEle], OTHERMONTHROW);\n }\n }\n else {\n if (rowIterator === numberCell && elements[numberCell].classList.contains(OTHERMONTH)) {\n addClass([trEle], OTHERMONTHROW);\n }\n }\n }\n row = row + count;\n rowIterator = rowIterator + 0;\n this.tableBodyElement.appendChild(trEle);\n }\n this.table.querySelector('tbody').className = this.effect;\n if (this.calendarMode === 'Gregorian') {\n this.iconHandler();\n }\n else {\n this.islamicModule.islamicIconHandler();\n }\n if (view !== this.getViewNumber(this.currentView()) || (view === 0 && view !== this.getViewNumber(this.currentView()))) {\n this.navigateHandler(e);\n }\n this.setAriaActiveDescendant();\n };\n CalendarBase.prototype.clickHandler = function (e, value) {\n this.clickEventEmitter(e);\n var eve = e.currentTarget;\n var view = this.getViewNumber(this.currentView());\n if (eve.classList.contains(OTHERMONTH)) {\n this.contentClick(e, 0, null, value);\n }\n else if (view === this.getViewNumber(this.depth) && this.getViewNumber(this.start) >= this.getViewNumber(this.depth)) {\n this.contentClick(e, 1, null, value);\n }\n else if (2 === view) {\n this.contentClick(e, 1, null, value);\n }\n else if (!eve.classList.contains(OTHERMONTH) && view === 0) {\n this.selectDate(e, this.getIdValue(e, null), null);\n }\n else {\n this.contentClick(e, 0, eve, value);\n }\n if (this.getModuleName() === 'calendar') {\n this.table.focus();\n }\n };\n // Content click event handler required for extended components\n CalendarBase.prototype.clickEventEmitter = function (e) {\n e.preventDefault();\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n CalendarBase.prototype.contentClick = function (e, view, element, value) {\n var currentView = this.getViewNumber(this.currentView());\n var d = this.getIdValue(e, element);\n switch (view) {\n case 0:\n if (currentView === this.getViewNumber(this.depth) && this.getViewNumber(this.start) >= this.getViewNumber(this.depth)) {\n detach(this.tableBodyElement);\n this.currentDate = d;\n this.effect = ZOOMIN;\n this.renderMonths(e);\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n this.currentDate.setMonth(d.getMonth());\n if (d.getMonth() > 0 && this.currentDate.getMonth() !== d.getMonth()) {\n this.currentDate.setDate(0);\n }\n this.currentDate.setFullYear(d.getFullYear());\n }\n else {\n this.currentDate = d;\n }\n this.effect = ZOOMIN;\n detach(this.tableBodyElement);\n this.renderMonths(e);\n }\n break;\n case 1:\n if (currentView === this.getViewNumber(this.depth) && this.getViewNumber(this.start) >= this.getViewNumber(this.depth)) {\n this.selectDate(e, d, null);\n }\n else {\n if (this.calendarMode === 'Gregorian') {\n this.currentDate.setFullYear(d.getFullYear());\n }\n else {\n this.islamicPreviousHeader = this.headerElement.textContent;\n var islamicDate = this.islamicModule.getIslamicDate(d);\n this.currentDate = this.islamicModule.toGregorian(islamicDate.year, islamicDate.month, 1);\n }\n this.effect = ZOOMIN;\n detach(this.tableBodyElement);\n this.renderYears(e);\n }\n }\n };\n CalendarBase.prototype.switchView = function (view, e, multiSelection, isCustomDate) {\n switch (view) {\n case 0:\n detach(this.tableBodyElement);\n this.renderMonths(e, null, isCustomDate);\n break;\n case 1:\n detach(this.tableBodyElement);\n this.renderYears(e);\n break;\n case 2:\n detach(this.tableBodyElement);\n this.renderDecades(e);\n }\n };\n /**\n * To get component name\n *\n * @returns {string} Returns the component name.\n * @private\n */\n CalendarBase.prototype.getModuleName = function () {\n return 'calendar';\n };\n /**\n *\n * @returns {void}\n\n */\n CalendarBase.prototype.requiredModules = function () {\n var modules = [];\n if (this) {\n modules.push({ args: [this], member: 'islamic' });\n }\n return modules;\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets the properties to be maintained upon browser refresh.\n *\n * @returns {string}\n */\n CalendarBase.prototype.getPersistData = function () {\n var keyEntity = ['value'];\n return this.addOnPersist(keyEntity);\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Called internally if any of the property value changed.\n *\n * @param {CalendarBaseModel} newProp - Returns the dynamic property value of the component.\n * @param {CalendarBaseModel} oldProp - Returns the previous property value of the component.\n * @param {boolean} multiSelection - - Specifies whether multiple date selection is enabled or not.\n * @param {Date[]} values - Specifies the dates.\n * @returns {void}\n * @private\n */\n CalendarBase.prototype.onPropertyChanged = function (newProp, oldProp, multiSelection, values) {\n this.effect = '';\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'enableRtl':\n if (newProp.enableRtl) {\n if (this.getModuleName() === 'calendar') {\n this.element.classList.add('e-rtl');\n }\n else {\n this.calendarElement.classList.add('e-rtl');\n }\n }\n else {\n if (this.getModuleName() === 'calendar') {\n this.element.classList.remove('e-rtl');\n }\n else {\n this.calendarElement.classList.remove('e-rtl');\n }\n }\n break;\n case 'dayHeaderFormat':\n this.getCultureValues();\n if (this.getModuleName() !== 'datepicker') {\n this.createContentHeader();\n }\n else if (this.calendarElement) {\n this.createContentHeader();\n }\n this.adjustLongHeaderSize();\n break;\n case 'min':\n case 'max':\n this.rangeValidation(this.min, this.max);\n if (prop === 'min') {\n this.setProperties({ min: this.checkDateValue(new Date(this.checkValue(newProp.min))) }, true);\n }\n else {\n this.setProperties({ max: this.checkDateValue(new Date(this.checkValue(newProp.max))) }, true);\n }\n this.setProperties({ start: this.currentView() }, true);\n if (this.tableBodyElement) {\n detach(this.tableBodyElement);\n }\n this.minMaxUpdate();\n if (multiSelection) {\n this.validateValues(multiSelection, values);\n }\n if (this.getModuleName() !== 'datepicker') {\n this.createContentBody();\n }\n else if (this.calendarElement) {\n this.createContentBody();\n }\n if ((this.todayDate < this.min || this.max < this.todayDate) && (this.footer) && (this.todayElement)) {\n detach(this.todayElement);\n detach(this.footer);\n this.todayElement = this.footer = null;\n this.createContentFooter();\n }\n else {\n if ((this.footer) && (this.todayElement) && this.todayElement.classList.contains('e-disabled')) {\n removeClass([this.todayElement], DISABLED);\n detach(this.todayElement);\n detach(this.footer);\n this.todayElement = this.footer = null;\n this.createContentFooter();\n }\n }\n break;\n case 'start':\n case 'depth':\n case 'weekNumber':\n case 'firstDayOfWeek':\n case 'weekRule':\n this.checkView();\n if (this.getModuleName() !== 'datepicker') {\n this.createContentHeader();\n this.createContentBody();\n }\n else if (this.calendarElement) {\n this.createContentHeader();\n this.createContentBody();\n }\n break;\n case 'locale':\n this.globalize = new Internationalization(this.locale);\n if (this.getModuleName() !== 'datepicker') {\n this.createContentHeader();\n this.createContentBody();\n }\n else if (this.calendarElement) {\n this.createContentHeader();\n this.createContentBody();\n }\n if (this.getModuleName() === 'calendar') {\n var l10nLocale = { today: 'Today' };\n this.l10 = new L10n(this.getModuleName(), l10nLocale, this.locale);\n }\n this.l10.setLocale(this.locale);\n if (this.showTodayButton) {\n this.updateFooter();\n }\n break;\n case 'showTodayButton':\n if (newProp.showTodayButton) {\n this.createContentFooter();\n }\n else {\n if (!isNullOrUndefined(this.todayElement) && !isNullOrUndefined(this.footer)) {\n detach(this.todayElement);\n detach(this.footer);\n this.todayElement = this.footer = undefined;\n }\n }\n this.setProperties({ showTodayButton: newProp.showTodayButton }, true);\n break;\n }\n }\n };\n /**\n * values property updated with considered disabled dates of the calendar.\n *\n * @param {boolean} multiSelection - Specifies whether multiple date selection is enabled.\n * @param {Date[]} values - Specifies the dates to validate.\n * @returns {void}\n */\n CalendarBase.prototype.validateValues = function (multiSelection, values) {\n if (multiSelection && !isNullOrUndefined(values) && values.length > 0) {\n var copyValues = this.copyValues(values);\n for (var skipIndex = 0; skipIndex < copyValues.length; skipIndex++) {\n var tempValue = copyValues[skipIndex];\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var tempValueString = void 0;\n if (this.calendarMode === 'Gregorian') {\n tempValueString = this.globalize.formatDate(tempValue, { type: 'date', skeleton: 'yMd' });\n }\n else {\n tempValueString = this.globalize.formatDate(tempValue, { type: 'dateTime', skeleton: 'full', calendar: 'islamic' });\n }\n var minFormatOption = { type: 'date', skeleton: 'yMd', calendar: type };\n var minStringValue = this.globalize.formatDate(this.min, minFormatOption);\n var minString = minStringValue;\n var maxFormatOption = { type: 'date', skeleton: 'yMd', calendar: type };\n var maxStringValue = this.globalize.formatDate(this.max, maxFormatOption);\n var maxString = maxStringValue;\n if (+new Date(tempValueString) < +new Date(minString) ||\n +new Date(tempValueString) > +new Date(maxString)) {\n copyValues.splice(skipIndex, 1);\n skipIndex = -1;\n }\n }\n this.setProperties({ values: copyValues }, true);\n }\n };\n CalendarBase.prototype.setValueUpdate = function () {\n if (!isNullOrUndefined(this.tableBodyElement)) {\n detach(this.tableBodyElement);\n this.setProperties({ start: this.currentView() }, true);\n this.createContentBody();\n }\n };\n CalendarBase.prototype.copyValues = function (values) {\n var copyValues = [];\n if (!isNullOrUndefined(values) && values.length > 0) {\n for (var index = 0; index < values.length; index++) {\n copyValues.push(new Date(+values[index]));\n }\n }\n return copyValues;\n };\n CalendarBase.prototype.titleUpdate = function (date, view) {\n var globalize = new Internationalization(this.locale);\n var dayFormatOptions;\n var monthFormatOptions;\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n if (this.calendarMode === 'Gregorian') {\n dayFormatOptions = globalize.formatDate(date, { type: 'dateTime', skeleton: 'yMMMM', calendar: type });\n monthFormatOptions = globalize.formatDate(date, {\n format: null, type: 'dateTime', skeleton: 'y', calendar: type\n });\n }\n else {\n dayFormatOptions = globalize.formatDate(date, { type: 'dateTime', format: 'MMMM y', calendar: type });\n monthFormatOptions = globalize.formatDate(date, { type: 'dateTime', format: 'y', calendar: type });\n }\n switch (view) {\n case 'days':\n this.headerTitleElement.textContent = this.toCapitalize(dayFormatOptions);\n break;\n case 'months':\n this.headerTitleElement.textContent = monthFormatOptions;\n }\n };\n CalendarBase.prototype.setActiveDescendant = function () {\n var id;\n var focusedEle = this.tableBodyElement.querySelector('tr td.e-focused-date');\n var selectedEle = this.tableBodyElement.querySelector('tr td.e-selected');\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var title;\n var view = this.currentView();\n if (view === 'Month') {\n title = this.globalize.formatDate(this.currentDate, { type: 'date', skeleton: 'full', calendar: type });\n }\n else if (view === 'Year') {\n if (type !== 'islamic') {\n title = this.globalize.formatDate(this.currentDate, { type: 'date', skeleton: 'yMMMM', calendar: type });\n }\n else {\n title = this.globalize.formatDate(this.currentDate, { type: 'date', skeleton: 'GyMMM', calendar: type });\n }\n }\n else {\n title = this.globalize.formatDate(this.currentDate, {\n format: null, type: 'date', skeleton: 'y', calendar: type\n });\n }\n if (selectedEle || focusedEle) {\n if (!isNullOrUndefined(selectedEle)) {\n selectedEle.setAttribute('aria-selected', 'true');\n }\n (focusedEle || selectedEle).setAttribute('aria-label', title);\n id = (focusedEle || selectedEle).getAttribute('id');\n }\n return id;\n };\n CalendarBase.prototype.iconHandler = function () {\n new Date(this.checkValue(this.currentDate)).setDate(1);\n switch (this.currentView()) {\n case 'Month':\n this.previousIconHandler(this.compareMonth(new Date(this.checkValue(this.currentDate)), this.min) < 1);\n this.nextIconHandler(this.compareMonth(new Date(this.checkValue(this.currentDate)), this.max) > -1);\n break;\n case 'Year':\n this.previousIconHandler(this.compareYear(new Date(this.checkValue(this.currentDate)), this.min) < 1);\n this.nextIconHandler(this.compareYear(new Date(this.checkValue(this.currentDate)), this.max) > -1);\n break;\n case 'Decade':\n this.previousIconHandler(this.compareDecade(new Date(this.checkValue(this.currentDate)), this.min) < 1);\n this.nextIconHandler(this.compareDecade(new Date(this.checkValue(this.currentDate)), this.max) > -1);\n }\n };\n /**\n * Destroys the widget.\n *\n * @returns {void}\n */\n CalendarBase.prototype.destroy = function () {\n if (this.getModuleName() === 'calendar' && this.element) {\n removeClass([this.element], [ROOT]);\n }\n else {\n if (this.calendarElement && this.element) {\n removeClass([this.element], [ROOT]);\n }\n }\n if (this.getModuleName() === 'calendar' && this.element) {\n if (!isNullOrUndefined(this.headerTitleElement)) {\n EventHandler.remove(this.headerTitleElement, 'click', this.navigateTitle);\n }\n if (this.todayElement) {\n EventHandler.remove(this.todayElement, 'click', this.todayButtonClick);\n }\n this.previousIconHandler(true);\n this.nextIconHandler(true);\n this.keyboardModule.destroy();\n this.element.removeAttribute('data-role');\n if (!isNullOrUndefined(this.calendarEleCopy.getAttribute('tabindex'))) {\n this.element.setAttribute('tabindex', this.tabIndex);\n }\n else {\n this.element.removeAttribute('tabindex');\n }\n }\n if (this.element) {\n this.element.innerHTML = '';\n }\n this.todayElement = null;\n this.tableBodyElement = null;\n this.todayButtonEvent = null;\n this.renderDayCellArgs = null;\n this.headerElement = null;\n this.nextIcon = null;\n this.table = null;\n this.tableHeadElement = null;\n this.previousIcon = null;\n this.headerTitleElement = null;\n this.footer = null;\n this.contentElement = null;\n _super.prototype.destroy.call(this);\n };\n CalendarBase.prototype.title = function (e) {\n var currentView = this.getViewNumber(this.currentView());\n this.effect = ZOOMIN;\n this.switchView(++currentView, e);\n };\n CalendarBase.prototype.getViewNumber = function (stringVal) {\n if (stringVal === 'Month') {\n return 0;\n }\n else if (stringVal === 'Year') {\n return 1;\n }\n else {\n return 2;\n }\n };\n CalendarBase.prototype.navigateTitle = function (e) {\n e.preventDefault();\n this.title(e);\n if (this.getModuleName() === 'calendar') {\n this.table.focus();\n }\n };\n CalendarBase.prototype.previous = function () {\n this.effect = '';\n var currentView = this.getViewNumber(this.currentView());\n switch (this.currentView()) {\n case 'Month':\n this.addMonths(this.currentDate, -1);\n this.switchView(currentView);\n break;\n case 'Year':\n this.addYears(this.currentDate, -1);\n this.switchView(currentView);\n break;\n case 'Decade':\n this.addYears(this.currentDate, -10);\n this.switchView(currentView);\n break;\n }\n };\n CalendarBase.prototype.navigatePrevious = function (e) {\n !Browser.isDevice && e.preventDefault();\n if (this.calendarMode === 'Gregorian') {\n this.previous();\n }\n else {\n this.islamicModule.islamicPrevious();\n }\n this.triggerNavigate(e);\n if (this.getModuleName() === 'calendar') {\n this.table.focus();\n }\n };\n CalendarBase.prototype.next = function () {\n this.effect = '';\n var currentView = this.getViewNumber(this.currentView());\n switch (this.currentView()) {\n case 'Month':\n this.addMonths(this.currentDate, 1);\n this.switchView(currentView);\n break;\n case 'Year':\n this.addYears(this.currentDate, 1);\n this.switchView(currentView);\n break;\n case 'Decade':\n this.addYears(this.currentDate, 10);\n this.switchView(currentView);\n break;\n }\n };\n CalendarBase.prototype.navigateNext = function (eve) {\n !Browser.isDevice && eve.preventDefault();\n if (this.calendarMode === 'Gregorian') {\n this.next();\n }\n else {\n this.islamicModule.islamicNext();\n }\n this.triggerNavigate(eve);\n if (this.getModuleName() === 'calendar') {\n this.table.focus();\n }\n };\n /**\n * This method is used to navigate to the month/year/decade view of the Calendar.\n *\n * @param {string} view - Specifies the view of the Calendar.\n * @param {Date} date - Specifies the focused date in a view.\n * @param {boolean} isCustomDate - Specifies whether the calendar is rendered with custom today date or not.\n * @returns {void}\n */\n CalendarBase.prototype.navigateTo = function (view, date, isCustomDate) {\n if (+date >= +this.min && +date <= +this.max) {\n this.currentDate = date;\n }\n if (+date <= +this.min) {\n this.currentDate = new Date(this.checkValue(this.min));\n }\n if (+date >= +this.max) {\n this.currentDate = new Date(this.checkValue(this.max));\n }\n if ((this.getViewNumber(this.depth) >= this.getViewNumber(view))) {\n if ((this.getViewNumber(this.depth) <= this.getViewNumber(this.start))\n || this.getViewNumber(this.depth) === this.getViewNumber(view)) {\n view = this.depth;\n }\n }\n this.switchView(this.getViewNumber(view), null, null, isCustomDate);\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets the current view of the Calendar.\n *\n * @returns {string}\n */\n CalendarBase.prototype.currentView = function () {\n if (!isNullOrUndefined(this.contentElement) && this.contentElement.classList.contains(YEAR)) {\n return 'Year';\n }\n else if (!isNullOrUndefined(this.contentElement) && this.contentElement.classList.contains(DECADE)) {\n return 'Decade';\n }\n else {\n return 'Month';\n }\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n CalendarBase.prototype.getDateVal = function (date, value) {\n return (!isNullOrUndefined(value) && date.getDate() === (value).getDate()\n && date.getMonth() === (value).getMonth() && date.getFullYear() === (value).getFullYear());\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n CalendarBase.prototype.getCultureObjects = function (ld, c) {\n var gregorianFormat = '.dates.calendars.gregorian.days.format.' + this.dayHeaderFormat.toLowerCase();\n var islamicFormat = '.dates.calendars.islamic.days.format.' + this.dayHeaderFormat.toLowerCase();\n var mainVal = 'main.';\n if (this.calendarMode === 'Gregorian') {\n return getValue(mainVal + '' + this.locale + gregorianFormat, ld);\n }\n else {\n return getValue('main.' + '' + this.locale + islamicFormat, ld);\n }\n };\n CalendarBase.prototype.getWeek = function (d) {\n var currentDate = new Date(this.checkValue(d)).valueOf();\n var date = new Date(d.getFullYear(), 0, 1).valueOf();\n return Math.ceil((((currentDate - date) + dayMilliSeconds) / dayMilliSeconds) / 7);\n };\n CalendarBase.prototype.setStartDate = function (date, time) {\n var tzOffset = date.getTimezoneOffset();\n var d = new Date(date.getTime() + time);\n var tzOffsetDiff = d.getTimezoneOffset() - tzOffset;\n date.setTime(d.getTime() + tzOffsetDiff * minutesMilliSeconds);\n };\n CalendarBase.prototype.addMonths = function (date, i) {\n if (this.calendarMode === 'Gregorian') {\n var day = date.getDate();\n date.setDate(1);\n date.setMonth(date.getMonth() + i);\n date.setDate(Math.min(day, this.getMaxDays(date)));\n }\n else {\n var islamicDate = this.islamicModule.getIslamicDate(date);\n this.currentDate = this.islamicModule.toGregorian(islamicDate.year, (islamicDate.month) + i, 1);\n }\n };\n CalendarBase.prototype.addYears = function (date, i) {\n if (this.calendarMode === 'Gregorian') {\n var day = date.getDate();\n date.setDate(1);\n date.setFullYear(date.getFullYear() + i);\n date.setDate(Math.min(day, this.getMaxDays(date)));\n }\n else {\n var islamicDate = this.islamicModule.getIslamicDate(date);\n this.currentDate = this.islamicModule.toGregorian(islamicDate.year + i, (islamicDate.month), 1);\n }\n };\n CalendarBase.prototype.getIdValue = function (e, element) {\n var eve;\n if (e) {\n eve = e.currentTarget;\n }\n else {\n eve = element;\n }\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var dateFormatOptions = { type: 'dateTime', skeleton: 'full', calendar: type };\n // eslint-disable-next-line radix\n var dateString = this.globalize.formatDate(new Date(parseInt('' + eve.getAttribute('id'), 0)), dateFormatOptions);\n var date = this.globalize.parseDate(dateString, dateFormatOptions);\n var value = date.valueOf() - date.valueOf() % 1000;\n return new Date(value);\n //return this.globalize.parseDate(dateString, dateFormatOptions);\n };\n CalendarBase.prototype.adjustLongHeaderSize = function () {\n removeClass([this.element], DAYHEADERLONG);\n if (this.dayHeaderFormat === 'Wide') {\n addClass([this.getModuleName() === 'calendar' ? this.element : this.calendarElement], DAYHEADERLONG);\n }\n };\n CalendarBase.prototype.selectDate = function (e, date, node, multiSelection, values) {\n var element = node || e.currentTarget;\n this.isDateSelected = false;\n if (this.currentView() === 'Decade') {\n this.setDateDecade(this.currentDate, date.getFullYear());\n }\n else if (this.currentView() === 'Year') {\n this.setDateYear(this.currentDate, date);\n }\n else {\n if (multiSelection && !this.checkPresentDate(date, values)) {\n var copyValues = this.copyValues(values);\n if (!isNullOrUndefined(values) && copyValues.length > 0) {\n copyValues.push(new Date(this.checkValue(date)));\n this.setProperties({ values: copyValues }, true);\n this.setProperties({ value: values[values.length - 1] }, true);\n }\n else {\n this.setProperties({ values: [new Date(this.checkValue(date))] }, true);\n }\n }\n else {\n this.setProperties({ value: new Date(this.checkValue(date)) }, true);\n }\n this.currentDate = new Date(this.checkValue(date));\n }\n var tableBodyElement = closest(element, '.' + ROOT);\n if (isNullOrUndefined(tableBodyElement)) {\n tableBodyElement = this.tableBodyElement;\n }\n if (!multiSelection && !isNullOrUndefined(tableBodyElement.querySelector('.' + SELECTED))) {\n removeClass([tableBodyElement.querySelector('.' + SELECTED)], SELECTED);\n }\n if (!multiSelection && !isNullOrUndefined(tableBodyElement.querySelector('.' + FOCUSEDDATE))) {\n removeClass([tableBodyElement.querySelector('.' + FOCUSEDDATE)], FOCUSEDDATE);\n }\n if (multiSelection) {\n var copyValues = this.copyValues(values);\n var collection = Array.prototype.slice.call(this.tableBodyElement.querySelectorAll('td'));\n for (var index = 0; index < collection.length; index++) {\n var tempElement = tableBodyElement.querySelectorAll('td' + '.' + FOCUSEDDATE)[0];\n var selectedElement = tableBodyElement.querySelectorAll('td' + '.' + SELECTED)[0];\n if (collection[index] === tempElement) {\n removeClass([collection[index]], FOCUSEDDATE);\n }\n if (collection[index] === selectedElement &&\n !this.checkPresentDate(new Date(parseInt(selectedElement.getAttribute('id').split('_')[0], 10)), values)) {\n removeClass([collection[index]], SELECTED);\n }\n }\n if (element.classList.contains(SELECTED)) {\n removeClass([element], SELECTED);\n for (var i = 0; i < copyValues.length; i++) {\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var formatOptions = { format: null, type: 'date', skeleton: 'short', calendar: type };\n var localDateString = this.globalize.formatDate(date, formatOptions);\n var tempDateString = this.globalize.formatDate(copyValues[i], formatOptions);\n if (localDateString === tempDateString) {\n var index = copyValues.indexOf(copyValues[i]);\n copyValues.splice(index, 1);\n addClass([element], FOCUSEDDATE);\n }\n }\n this.setProperties({ values: copyValues }, true);\n }\n else {\n addClass([element], SELECTED);\n }\n }\n else {\n addClass([element], SELECTED);\n }\n this.isDateSelected = true;\n };\n CalendarBase.prototype.checkPresentDate = function (dates, values) {\n var previousValue = false;\n if (!isNullOrUndefined(values)) {\n for (var checkPrevious = 0; checkPrevious < values.length; checkPrevious++) {\n var type = (this.calendarMode === 'Gregorian') ? 'gregorian' : 'islamic';\n var localDateString = this.globalize.formatDate(dates, {\n format: null, type: 'date', skeleton: 'short', calendar: type\n });\n var tempDateString = this.globalize.formatDate(values[checkPrevious], {\n format: null, type: 'date', skeleton: 'short', calendar: type\n });\n if (localDateString === tempDateString) {\n previousValue = true;\n }\n }\n }\n return previousValue;\n };\n CalendarBase.prototype.setAriaActiveDescendant = function () {\n attributes(this.table, {\n 'aria-activedescendant': '' + this.setActiveDescendant()\n });\n };\n CalendarBase.prototype.previousIconHandler = function (disabled) {\n if (disabled) {\n if (!isNullOrUndefined(this.previousIcon)) {\n EventHandler.remove(this.previousIcon, 'click', this.navigatePreviousHandler);\n addClass([this.previousIcon], '' + DISABLED);\n addClass([this.previousIcon], '' + OVERLAY);\n this.previousIcon.setAttribute('aria-disabled', 'true');\n }\n }\n else {\n EventHandler.add(this.previousIcon, 'click', this.navigatePreviousHandler);\n removeClass([this.previousIcon], '' + DISABLED);\n removeClass([this.previousIcon], '' + OVERLAY);\n this.previousIcon.setAttribute('aria-disabled', 'false');\n }\n };\n CalendarBase.prototype.renderDayCellEvent = function (args) {\n extend(this.renderDayCellArgs, { name: 'renderDayCell' });\n this.trigger('renderDayCell', args);\n };\n CalendarBase.prototype.navigatedEvent = function (eve) {\n extend(this.navigatedArgs, { name: 'navigated', event: eve });\n this.trigger('navigated', this.navigatedArgs);\n };\n CalendarBase.prototype.triggerNavigate = function (event) {\n this.navigatedArgs = { view: this.currentView(), date: this.currentDate };\n this.navigatedEvent(event);\n };\n CalendarBase.prototype.nextIconHandler = function (disabled) {\n if (disabled) {\n if (!isNullOrUndefined(this.previousIcon)) {\n EventHandler.remove(this.nextIcon, 'click', this.navigateNextHandler);\n addClass([this.nextIcon], DISABLED);\n addClass([this.nextIcon], OVERLAY);\n this.nextIcon.setAttribute('aria-disabled', 'true');\n }\n }\n else {\n EventHandler.add(this.nextIcon, 'click', this.navigateNextHandler);\n removeClass([this.nextIcon], DISABLED);\n removeClass([this.nextIcon], OVERLAY);\n this.nextIcon.setAttribute('aria-disabled', 'false');\n }\n };\n CalendarBase.prototype.compare = function (startDate, endDate, modifier) {\n var start = endDate.getFullYear();\n var end;\n var result;\n end = start;\n result = 0;\n if (modifier) {\n start = start - start % modifier;\n end = start - start % modifier + modifier - 1;\n }\n if (startDate.getFullYear() > end) {\n result = 1;\n }\n else if (startDate.getFullYear() < start) {\n result = -1;\n }\n return result;\n };\n CalendarBase.prototype.isMinMaxRange = function (date) {\n return +date >= +this.min && +date <= +this.max;\n };\n CalendarBase.prototype.isMonthYearRange = function (date) {\n if (this.calendarMode === 'Gregorian') {\n return date.getMonth() >= this.min.getMonth()\n && date.getFullYear() >= this.min.getFullYear()\n && date.getMonth() <= this.max.getMonth()\n && date.getFullYear() <= this.max.getFullYear();\n }\n else {\n var islamicDate = this.islamicModule.getIslamicDate(date);\n return islamicDate.month >= (this.islamicModule.getIslamicDate(new Date(1944, 1, 18))).month\n && islamicDate.year >= (this.islamicModule.getIslamicDate(new Date(1944, 1, 18))).year\n && islamicDate.month <= (this.islamicModule.getIslamicDate(new Date(2069, 1, 16))).month\n && islamicDate.year <= (this.islamicModule.getIslamicDate(new Date(2069, 1, 16))).year;\n }\n };\n CalendarBase.prototype.compareYear = function (start, end) {\n return this.compare(start, end, 0);\n };\n CalendarBase.prototype.compareDecade = function (start, end) {\n return this.compare(start, end, 10);\n };\n CalendarBase.prototype.shiftArray = function (array, i) {\n return array.slice(i).concat(array.slice(0, i));\n };\n CalendarBase.prototype.addDay = function (date, i, e, max, min) {\n var column = i;\n var value = new Date(+date);\n if (!isNullOrUndefined(this.tableBodyElement) && !isNullOrUndefined(e)) {\n while (this.findNextTD(new Date(+date), column, max, min)) {\n column += i;\n }\n var rangeValue = new Date(value.setDate(value.getDate() + column));\n column = (+rangeValue > +max || +rangeValue < +min) ? column === i ? i - i : i : column;\n }\n date.setDate(date.getDate() + column);\n };\n CalendarBase.prototype.findNextTD = function (date, column, max, min) {\n var value = new Date(date.setDate(date.getDate() + column));\n var collection = [];\n var isDisabled = false;\n if ((!isNullOrUndefined(value) && value.getMonth()) === (!isNullOrUndefined(this.currentDate) && this.currentDate.getMonth())) {\n var tdEles = void 0;\n if (this.calendarMode === 'Gregorian') {\n tdEles = this.renderDays(value);\n }\n else {\n tdEles = this.islamicModule.islamicRenderDays(this.currentDate, value);\n }\n collection = tdEles.filter(function (element) {\n return element.classList.contains(DISABLED);\n });\n }\n else {\n collection = this.tableBodyElement.querySelectorAll('td.' + DISABLED);\n }\n if (+value <= (+(max)) && +value >= (+(min))) {\n if (collection.length) {\n for (var i = 0; i < collection.length; i++) {\n // eslint-disable-next-line radix\n isDisabled = (+value === +new Date(parseInt(collection[i].id, 0))) ? true : false;\n if (isDisabled) {\n break;\n }\n }\n }\n }\n return isDisabled;\n };\n CalendarBase.prototype.getMaxDays = function (d) {\n var date;\n var tmpDate = new Date(this.checkValue(d));\n date = 28;\n var month = tmpDate.getMonth();\n while (tmpDate.getMonth() === month) {\n ++date;\n tmpDate.setDate(date);\n }\n return date - 1;\n };\n CalendarBase.prototype.setDateDecade = function (date, year) {\n date.setFullYear(year);\n this.setProperties({ value: new Date(this.checkValue(date)) }, true);\n };\n CalendarBase.prototype.setDateYear = function (date, value) {\n date.setFullYear(value.getFullYear(), value.getMonth(), date.getDate());\n if (value.getMonth() !== date.getMonth()) {\n date.setDate(0);\n this.currentDate = new Date(this.checkValue(value));\n }\n this.setProperties({ value: new Date(this.checkValue(date)) }, true);\n };\n CalendarBase.prototype.compareMonth = function (start, end) {\n var result;\n if (start.getFullYear() > end.getFullYear()) {\n result = 1;\n }\n else if (start.getFullYear() < end.getFullYear()) {\n result = -1;\n }\n else {\n result = start.getMonth() === end.getMonth() ? 0 : start.getMonth() > end.getMonth() ? 1 : -1;\n }\n return result;\n };\n CalendarBase.prototype.checkValue = function (inValue) {\n if (inValue instanceof Date) {\n return (inValue.toUTCString());\n }\n else {\n return ('' + inValue);\n }\n };\n CalendarBase.prototype.checkView = function () {\n if (this.start !== 'Decade' && this.start !== 'Year') {\n this.setProperties({ start: 'Month' }, true);\n }\n if (this.depth !== 'Decade' && this.depth !== 'Year') {\n this.setProperties({ depth: 'Month' }, true);\n }\n if (this.getViewNumber(this.depth) > this.getViewNumber(this.start)) {\n this.setProperties({ depth: 'Month' }, true);\n }\n };\n CalendarBase.prototype.getDate = function (date, timezone) {\n if (timezone) {\n date = new Date(date.toLocaleString('en-US', { timeZone: timezone }));\n }\n return date;\n };\n __decorate([\n Property(new Date(1900, 0, 1))\n ], CalendarBase.prototype, \"min\", void 0);\n __decorate([\n Property(true)\n ], CalendarBase.prototype, \"enabled\", void 0);\n __decorate([\n Property(null)\n ], CalendarBase.prototype, \"cssClass\", void 0);\n __decorate([\n Property(new Date(2099, 11, 31))\n ], CalendarBase.prototype, \"max\", void 0);\n __decorate([\n Property(null)\n ], CalendarBase.prototype, \"firstDayOfWeek\", void 0);\n __decorate([\n Property('Gregorian')\n ], CalendarBase.prototype, \"calendarMode\", void 0);\n __decorate([\n Property('Month')\n ], CalendarBase.prototype, \"start\", void 0);\n __decorate([\n Property('Month')\n ], CalendarBase.prototype, \"depth\", void 0);\n __decorate([\n Property(false)\n ], CalendarBase.prototype, \"weekNumber\", void 0);\n __decorate([\n Property('FirstDay')\n ], CalendarBase.prototype, \"weekRule\", void 0);\n __decorate([\n Property(true)\n ], CalendarBase.prototype, \"showTodayButton\", void 0);\n __decorate([\n Property('Short')\n ], CalendarBase.prototype, \"dayHeaderFormat\", void 0);\n __decorate([\n Property(false)\n ], CalendarBase.prototype, \"enablePersistence\", void 0);\n __decorate([\n Property(null)\n ], CalendarBase.prototype, \"keyConfigs\", void 0);\n __decorate([\n Property(null)\n ], CalendarBase.prototype, \"serverTimezoneOffset\", void 0);\n __decorate([\n Event()\n ], CalendarBase.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], CalendarBase.prototype, \"destroyed\", void 0);\n __decorate([\n Event()\n ], CalendarBase.prototype, \"navigated\", void 0);\n __decorate([\n Event()\n ], CalendarBase.prototype, \"renderDayCell\", void 0);\n CalendarBase = __decorate([\n NotifyPropertyChanges\n ], CalendarBase);\n return CalendarBase;\n}(Component));\nexport { CalendarBase };\n/**\n * Represents the Calendar component that allows the user to select a date.\n * ```html\n * <div id=\"calendar\"/>\n * ```\n * ```typescript\n * <script>\n * var calendarObj = new Calendar({ value: new Date() });\n * calendarObj.appendTo(\"#calendar\");\n * </script>\n * ```\n */\nvar Calendar = /** @class */ (function (_super) {\n __extends(Calendar, _super);\n /**\n * Initialized new instance of Calendar Class.\n * Constructor for creating the widget\n *\n * @param {CalendarModel} options - Specifies the Calendar model.\n * @param {string | HTMLElement} element - Specifies the element to render as component.\n * @private\n */\n function Calendar(options, element) {\n return _super.call(this, options, element) || this;\n }\n /**\n * To Initialize the control rendering.\n *\n * @returns {void}\n * @private\n */\n Calendar.prototype.render = function () {\n if (this.calendarMode === 'Islamic' && this.islamicModule === undefined) {\n throwError('Requires the injectable Islamic modules to render Calendar in Islamic mode');\n }\n if (this.isMultiSelection && typeof this.values === 'object' && !isNullOrUndefined(this.values) && this.values.length > 0) {\n var tempValues = [];\n var copyValues = [];\n for (var limit = 0; limit < this.values.length; limit++) {\n if (tempValues.indexOf(+this.values[limit]) === -1) {\n tempValues.push(+this.values[limit]);\n copyValues.push(this.values[limit]);\n }\n }\n this.setProperties({ values: copyValues }, true);\n for (var index = 0; index < this.values.length; index++) {\n if (!this.checkDateValue(this.values[index])) {\n if (typeof (this.values[index]) === 'string' && this.checkDateValue(new Date(this.checkValue(this.values[index])))) {\n var copyDate = new Date(this.checkValue(this.values[index]));\n this.values.splice(index, 1);\n this.values.splice(index, 0, copyDate);\n }\n else {\n this.values.splice(index, 1);\n }\n }\n }\n this.setProperties({ value: this.values[this.values.length - 1] }, true);\n this.previousValues = this.values.length;\n }\n this.validateDate();\n this.minMaxUpdate();\n if (this.getModuleName() === 'calendar') {\n this.setEnable(this.enabled);\n this.setClass(this.cssClass);\n }\n _super.prototype.render.call(this);\n if (this.getModuleName() === 'calendar') {\n var form = closest(this.element, 'form');\n if (form) {\n EventHandler.add(form, 'reset', this.formResetHandler.bind(this));\n }\n this.setTimeZone(this.serverTimezoneOffset);\n }\n this.renderComplete();\n };\n Calendar.prototype.setEnable = function (enable) {\n if (!enable) {\n addClass([this.element], DISABLED);\n }\n else {\n removeClass([this.element], DISABLED);\n }\n };\n Calendar.prototype.setClass = function (newCssClass, oldCssClass) {\n if (!isNullOrUndefined(oldCssClass)) {\n oldCssClass = (oldCssClass.replace(/\\s+/g, ' ')).trim();\n }\n if (!isNullOrUndefined(newCssClass)) {\n newCssClass = (newCssClass.replace(/\\s+/g, ' ')).trim();\n }\n if (!isNullOrUndefined(oldCssClass) && oldCssClass !== '') {\n removeClass([this.element], oldCssClass.split(' '));\n }\n if (!isNullOrUndefined(newCssClass)) {\n addClass([this.element], newCssClass.split(' '));\n }\n };\n Calendar.prototype.isDayLightSaving = function () {\n var secondOffset = new Date(this.value.getFullYear(), 6, 1).getTimezoneOffset();\n var firstOffset = new Date(this.value.getFullYear(), 0, 1).getTimezoneOffset();\n return (this.value.getTimezoneOffset() < Math.max(firstOffset, secondOffset));\n };\n Calendar.prototype.setTimeZone = function (offsetValue) {\n if (!isNullOrUndefined(this.serverTimezoneOffset) && this.value) {\n var serverTimezoneDiff = offsetValue;\n var clientTimeZoneDiff = new Date().getTimezoneOffset() / 60;\n var timeZoneDiff = serverTimezoneDiff + clientTimeZoneDiff;\n timeZoneDiff = this.isDayLightSaving() ? timeZoneDiff-- : timeZoneDiff;\n this.value = new Date(this.value.getTime() + (timeZoneDiff * 60 * 60 * 1000));\n }\n };\n Calendar.prototype.formResetHandler = function () {\n this.setProperties({ value: null }, true);\n };\n Calendar.prototype.validateDate = function () {\n if (typeof this.value === 'string') {\n this.setProperties({ value: this.checkDateValue(new Date(this.checkValue(this.value))) }, true); // persist the value property.\n }\n _super.prototype.validateDate.call(this, this.value);\n if (!isNullOrUndefined(this.value) && this.min <= this.max && this.value >= this.min && this.value <= this.max) {\n this.currentDate = new Date(this.checkValue(this.value));\n }\n if (isNaN(+this.value)) {\n this.setProperties({ value: null }, true);\n }\n };\n Calendar.prototype.minMaxUpdate = function () {\n if (this.getModuleName() === 'calendar') {\n if (!isNullOrUndefined(this.value) && this.value <= this.min && this.min <= this.max) {\n this.setProperties({ value: this.min }, true);\n this.changedArgs = { value: this.value };\n }\n else {\n if (!isNullOrUndefined(this.value) && this.value >= this.max && this.min <= this.max) {\n this.setProperties({ value: this.max }, true);\n this.changedArgs = { value: this.value };\n }\n }\n }\n if (this.getModuleName() !== 'calendar' && !isNullOrUndefined(this.value)) {\n if (!isNullOrUndefined(this.value) && this.value < this.min && this.min <= this.max) {\n _super.prototype.minMaxUpdate.call(this, this.min);\n }\n else {\n if (!isNullOrUndefined(this.value) && this.value > this.max && this.min <= this.max) {\n _super.prototype.minMaxUpdate.call(this, this.max);\n }\n }\n }\n else {\n _super.prototype.minMaxUpdate.call(this, this.value);\n }\n };\n Calendar.prototype.generateTodayVal = function (value) {\n var tempValue = new Date();\n if (!isNullOrUndefined(this.timezone)) {\n tempValue = _super.prototype.getDate.call(this, tempValue, this.timezone);\n }\n if (value && isNullOrUndefined(this.timezone)) {\n tempValue.setHours(value.getHours());\n tempValue.setMinutes(value.getMinutes());\n tempValue.setSeconds(value.getSeconds());\n tempValue.setMilliseconds(value.getMilliseconds());\n }\n else {\n tempValue = new Date(tempValue.getFullYear(), tempValue.getMonth(), tempValue.getDate(), 0, 0, 0, 0);\n }\n return tempValue;\n };\n Calendar.prototype.todayButtonClick = function (e) {\n if (this.showTodayButton) {\n var tempValue = this.generateTodayVal(this.value);\n this.setProperties({ value: tempValue }, true);\n this.isTodayClicked = true;\n this.todayButtonEvent = e;\n if (this.isMultiSelection) {\n var copyValues = this.copyValues(this.values);\n if (!_super.prototype.checkPresentDate.call(this, tempValue, this.values)) {\n copyValues.push(tempValue);\n this.setProperties({ values: copyValues });\n }\n }\n _super.prototype.todayButtonClick.call(this, e, new Date(+this.value));\n }\n };\n Calendar.prototype.keyActionHandle = function (e) {\n _super.prototype.keyActionHandle.call(this, e, this.value, this.isMultiSelection);\n };\n /**\n * Initialize the event handler\n *\n * @returns {void}\n * @private\n */\n Calendar.prototype.preRender = function () {\n var _this = this;\n this.changeHandler = function (e) {\n _this.triggerChange(e);\n };\n this.checkView();\n _super.prototype.preRender.call(this, this.value);\n };\n /**\n * @returns {void}\n\n */\n Calendar.prototype.createContent = function () {\n this.previousDate = this.value;\n this.previousDateTime = this.value;\n _super.prototype.createContent.call(this);\n };\n Calendar.prototype.minMaxDate = function (localDate) {\n return _super.prototype.minMaxDate.call(this, localDate);\n };\n Calendar.prototype.renderMonths = function (e, value, isCustomDate) {\n _super.prototype.renderMonths.call(this, e, this.value, isCustomDate);\n };\n Calendar.prototype.renderDays = function (currentDate, value, isMultiSelect, values, isCustomDate, e) {\n var tempDays = _super.prototype.renderDays.call(this, currentDate, this.value, this.isMultiSelection, this.values, isCustomDate, e);\n if (this.isMultiSelection) {\n _super.prototype.validateValues.call(this, this.isMultiSelection, this.values);\n }\n return tempDays;\n };\n Calendar.prototype.renderYears = function (e) {\n if (this.calendarMode === 'Gregorian') {\n _super.prototype.renderYears.call(this, e, this.value);\n }\n else {\n this.islamicModule.islamicRenderYears(e, this.value);\n }\n };\n Calendar.prototype.renderDecades = function (e) {\n if (this.calendarMode === 'Gregorian') {\n _super.prototype.renderDecades.call(this, e, this.value);\n }\n else {\n this.islamicModule.islamicRenderDecade(e, this.value);\n }\n };\n Calendar.prototype.renderTemplate = function (elements, count, classNm, e) {\n if (this.calendarMode === 'Gregorian') {\n _super.prototype.renderTemplate.call(this, elements, count, classNm, e, this.value);\n }\n else {\n this.islamicModule.islamicRenderTemplate(elements, count, classNm, e, this.value);\n }\n this.changedArgs = { value: this.value, values: this.values };\n e && e.type === 'click' && e.currentTarget.classList.contains(OTHERMONTH) ? this.changeHandler(e) : this.changeHandler();\n };\n Calendar.prototype.clickHandler = function (e) {\n var eve = e.currentTarget;\n this.isPopupClicked = true;\n if (eve.classList.contains(OTHERMONTH)) {\n if (this.isMultiSelection) {\n var copyValues = this.copyValues(this.values);\n if (copyValues.toString().indexOf(this.getIdValue(e, null).toString()) === -1) {\n copyValues.push(this.getIdValue(e, null));\n this.setProperties({ values: copyValues }, true);\n this.setProperties({ value: this.values[this.values.length - 1] }, true);\n }\n else {\n this.previousDates = true;\n }\n }\n else {\n this.setProperties({ value: this.getIdValue(e, null) }, true);\n }\n }\n var storeView = this.currentView();\n _super.prototype.clickHandler.call(this, e, this.value);\n if (this.isMultiSelection && this.currentDate !== this.value &&\n !isNullOrUndefined(this.tableBodyElement.querySelectorAll('.' + FOCUSEDDATE)[0]) && storeView === 'Year') {\n this.tableBodyElement.querySelectorAll('.' + FOCUSEDDATE)[0].classList.remove(FOCUSEDDATE);\n }\n };\n Calendar.prototype.switchView = function (view, e, isMultiSelection, isCustomDate) {\n _super.prototype.switchView.call(this, view, e, this.isMultiSelection, isCustomDate);\n };\n /**\n * To get component name\n *\n * @returns {string} Return the component name.\n * @private\n */\n Calendar.prototype.getModuleName = function () {\n _super.prototype.getModuleName.call(this);\n return 'calendar';\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets the properties to be maintained upon browser refresh.\n *\n * @returns {string}\n */\n Calendar.prototype.getPersistData = function () {\n _super.prototype.getPersistData.call(this);\n var keyEntity = ['value', 'values'];\n return this.addOnPersist(keyEntity);\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Called internally if any of the property value changed.\n *\n * @param {CalendarModel} newProp - Returns the dynamic property value of the component.\n * @param {CalendarModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n * @private\n */\n Calendar.prototype.onPropertyChanged = function (newProp, oldProp) {\n this.effect = '';\n this.rangeValidation(this.min, this.max);\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'value':\n if (this.isDateSelected) {\n if (typeof newProp.value === 'string') {\n this.setProperties({ value: new Date(this.checkValue(newProp.value)) }, true);\n }\n else {\n newProp.value = new Date(this.checkValue(newProp.value));\n }\n if (isNaN(+this.value)) {\n this.setProperties({ value: oldProp.value }, true);\n }\n this.update();\n }\n break;\n case 'values':\n if (this.isDateSelected) {\n if (typeof newProp.values === 'string' || typeof newProp.values === 'number') {\n this.setProperties({ values: null }, true);\n }\n else {\n var copyValues = this.copyValues(this.values);\n for (var index = 0; index < copyValues.length; index++) {\n var tempDate = copyValues[index];\n if (this.checkDateValue(tempDate) && !_super.prototype.checkPresentDate.call(this, tempDate, copyValues)) {\n copyValues.push(tempDate);\n }\n }\n this.setProperties({ values: copyValues }, true);\n if (this.values.length > 0) {\n this.setProperties({ value: newProp.values[newProp.values.length - 1] }, true);\n }\n }\n this.validateValues(this.isMultiSelection, this.values);\n this.update();\n }\n break;\n case 'isMultiSelection':\n if (this.isDateSelected) {\n this.setProperties({ isMultiSelection: newProp.isMultiSelection }, true);\n this.update();\n }\n break;\n case 'enabled':\n this.setEnable(this.enabled);\n break;\n case 'cssClass':\n if (this.getModuleName() === 'calendar') {\n this.setClass(newProp.cssClass, oldProp.cssClass);\n }\n break;\n default:\n _super.prototype.onPropertyChanged.call(this, newProp, oldProp, this.isMultiSelection, this.values);\n }\n }\n this.preventChange = this.isAngular && this.preventChange ? !this.preventChange : this.preventChange;\n };\n /**\n * Destroys the widget.\n *\n * @returns {void}\n */\n Calendar.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n if (this.getModuleName() === 'calendar') {\n this.changedArgs = null;\n var form = closest(this.element, 'form');\n if (form) {\n EventHandler.remove(form, 'reset', this.formResetHandler.bind(this));\n }\n }\n };\n /**\n * This method is used to navigate to the month/year/decade view of the Calendar.\n *\n * @param {string} view - Specifies the view of the Calendar.\n * @param {Date} date - Specifies the focused date in a view.\n * @param {boolean} isCustomDate - Specifies whether the calendar is rendered with custom today date or not.\n * @returns {void}\n\n */\n Calendar.prototype.navigateTo = function (view, date, isCustomDate) {\n this.minMaxUpdate();\n _super.prototype.navigateTo.call(this, view, date, isCustomDate);\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets the current view of the Calendar.\n *\n * @returns {string}\n\n */\n Calendar.prototype.currentView = function () {\n return _super.prototype.currentView.call(this);\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * This method is used to add the single or multiple dates to the values property of the Calendar.\n *\n * @param {Date | Date[]} dates - Specifies the date or dates to be added to the values property of the Calendar.\n * @returns {void}\n\n */\n Calendar.prototype.addDate = function (dates) {\n if (typeof dates !== 'string' && typeof dates !== 'number') {\n var copyValues = this.copyValues(this.values);\n if (typeof dates === 'object' && (dates).length > 0) {\n var tempDates = dates;\n for (var i = 0; i < tempDates.length; i++) {\n if (this.checkDateValue(tempDates[i]) && !_super.prototype.checkPresentDate.call(this, tempDates[i], copyValues)) {\n if (!isNullOrUndefined(copyValues) && copyValues.length > 0) {\n copyValues.push(tempDates[i]);\n }\n else {\n copyValues = [new Date(+tempDates[i])];\n }\n }\n }\n }\n else {\n if (this.checkDateValue(dates) && !_super.prototype.checkPresentDate.call(this, dates, copyValues)) {\n if (!isNullOrUndefined(copyValues) && copyValues.length > 0) {\n copyValues.push((dates));\n }\n else {\n copyValues = [new Date(+dates)];\n }\n }\n }\n this.setProperties({ values: copyValues }, true);\n if (this.isMultiSelection) {\n this.setProperties({ value: this.values[this.values.length - 1] }, true);\n }\n this.validateValues(this.isMultiSelection, copyValues);\n this.update();\n this.changedArgs = { value: this.value, values: this.values };\n this.changeHandler();\n }\n };\n /**\n * This method is used to remove the single or multiple dates from the values property of the Calendar.\n *\n * @param {Date | Date[]} dates - Specifies the date or dates which need to be removed from the values property of the Calendar.\n * @returns {void}\n\n */\n Calendar.prototype.removeDate = function (dates) {\n if (typeof dates !== 'string' && typeof dates !== 'number' && !isNullOrUndefined(this.values) && this.values.length > 0) {\n var copyValues = this.copyValues(this.values);\n if (typeof dates === 'object' && ((dates).length > 0)) {\n var tempDates = dates;\n for (var index = 0; index < tempDates.length; index++) {\n for (var i = 0; i < copyValues.length; i++) {\n if (+copyValues[i] === +tempDates[index]) {\n copyValues.splice(i, 1);\n }\n }\n }\n }\n else {\n for (var i = 0; i < copyValues.length; i++) {\n if (+copyValues[i] === +dates) {\n copyValues.splice(i, 1);\n }\n }\n }\n this.setProperties({ values: copyValues }, false);\n this.update();\n if (this.isMultiSelection) {\n this.setProperties({ value: this.values[this.values.length - 1] }, true);\n }\n this.changedArgs = { value: this.value, values: this.values };\n this.changeHandler();\n }\n };\n /**\n * To set custom today date in calendar\n *\n * @param {Date} date - Specifies date value to be set.\n * @private\n * @returns {void}\n */\n Calendar.prototype.setTodayDate = function (date) {\n var todayDate = new Date(+date);\n this.setProperties({ value: todayDate }, true);\n _super.prototype.todayButtonClick.call(this, null, todayDate, true);\n };\n Calendar.prototype.update = function () {\n this.validateDate();\n this.minMaxUpdate();\n _super.prototype.setValueUpdate.call(this);\n };\n Calendar.prototype.selectDate = function (e, date, element) {\n _super.prototype.selectDate.call(this, e, date, element, this.isMultiSelection, this.values);\n if (this.isMultiSelection && !isNullOrUndefined(this.values) && this.values.length > 0) {\n this.setProperties({ value: this.values[this.values.length - 1] }, true);\n }\n this.changedArgs = { value: this.value, values: this.values };\n this.changeHandler(e);\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Calendar.prototype.changeEvent = function (e) {\n if ((this.value && this.value.valueOf()) !== (this.previousDate && +this.previousDate.valueOf())\n || this.isMultiSelection) {\n if (this.isAngular && this.preventChange) {\n this.preventChange = false;\n }\n else {\n this.trigger('change', this.changedArgs);\n }\n this.previousDate = new Date(+this.value);\n }\n };\n Calendar.prototype.triggerChange = function (e) {\n if (!isNullOrUndefined(this.todayButtonEvent) && this.isTodayClicked) {\n e = this.todayButtonEvent;\n this.isTodayClicked = false;\n }\n this.changedArgs.event = e || null;\n this.changedArgs.isInteracted = !isNullOrUndefined(e);\n if (!isNullOrUndefined(this.value)) {\n this.setProperties({ value: this.value }, true);\n }\n // eslint-disable-next-line use-isnan\n if (!this.isMultiSelection && +this.value !== Number.NaN && (!isNullOrUndefined(this.value) &&\n !isNullOrUndefined(this.previousDate) || this.previousDate === null\n && !isNaN(+this.value))) {\n this.changeEvent(e);\n }\n else if (!isNullOrUndefined(this.values) && this.previousValues !== this.values.length) {\n this.changeEvent(e);\n this.previousValues = this.values.length;\n }\n };\n __decorate([\n Property(null)\n ], Calendar.prototype, \"value\", void 0);\n __decorate([\n Property(null)\n ], Calendar.prototype, \"values\", void 0);\n __decorate([\n Property(false)\n ], Calendar.prototype, \"isMultiSelection\", void 0);\n __decorate([\n Event()\n ], Calendar.prototype, \"change\", void 0);\n Calendar = __decorate([\n NotifyPropertyChanges\n ], Calendar);\n return Calendar;\n}(CalendarBase));\nexport { Calendar };\n","import { createElement, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { DataUtil } from '@syncfusion/ej2-data';\nimport { subtractThickness, valueToCoefficient, sum, redrawElement, isBreakLabel, ChartLocation, withInBounds, rotateTextSize } from '../../common/utils/helper';\nimport { subArray, inside, appendChildElement, stringToNumber } from '../../common/utils/helper';\nimport { Thickness, logBase, createZoomingLabels, getElement } from '../../common/utils/helper';\nimport { Size, Rect, measureText, TextOption, PathOption } from '@syncfusion/ej2-svg-base';\nimport { textElement, textTrim, getRotatedRectangleCoordinates, isRotatedRectIntersect, isZoomSet } from '../../common/utils/helper';\n/**\n * Specifies the Cartesian Axis Layout.\n */\nvar axisPadding = 10;\nvar CartesianAxisLayoutPanel = /** @class */ (function () {\n /** @private */\n function CartesianAxisLayoutPanel(chartModule) {\n this.chart = chartModule;\n this.padding = 5;\n }\n /**\n * Measure the axis size.\n *\n * @returns {void}\n * @private\n */\n CartesianAxisLayoutPanel.prototype.measureAxis = function (rect) {\n var chart = this.chart;\n var chartAreaWidth = chart.chartArea.width ? stringToNumber(chart.chartArea.width, chart.availableSize.width) : null;\n this.crossAt(chart);\n this.seriesClipRect = new Rect(rect.x, rect.y, rect.width, rect.height);\n this.initialClipRect = rect;\n this.leftSize = 0;\n this.rightSize = 0;\n this.topSize = 0;\n this.bottomSize = 0;\n //Measure Axis size with initial Rect\n this.measureRowAxis(chart, this.initialClipRect);\n this.initialClipRect = subtractThickness(this.initialClipRect, new Thickness(this.leftSize, this.rightSize, 0, 0));\n this.measureColumnAxis(chart, this.initialClipRect);\n this.initialClipRect = subtractThickness(this.initialClipRect, new Thickness(0, 0, this.topSize, this.bottomSize));\n if (!this.chart.delayRedraw) {\n this.calculateAxisSize(this.initialClipRect);\n }\n this.leftSize = 0;\n this.rightSize = 0;\n this.topSize = 0;\n this.bottomSize = 0;\n //Measure Axis size with series Rect\n this.measureRowAxis(chart, this.initialClipRect);\n this.seriesClipRect = subtractThickness(this.seriesClipRect, new Thickness(this.leftSize, this.rightSize, 0, 0));\n this.measureColumnAxis(chart, this.initialClipRect);\n this.seriesClipRect = subtractThickness(this.seriesClipRect, new Thickness(0, 0, this.topSize, this.bottomSize));\n if (chartAreaWidth) {\n this.calculateFixedChartArea(chart, chartAreaWidth);\n }\n if (!this.chart.delayRedraw) {\n chart.refreshAxis();\n this.calculateAxisSize(this.seriesClipRect);\n }\n };\n CartesianAxisLayoutPanel.prototype.calculateFixedChartArea = function (chart, chartAreaWidth) {\n this.seriesClipRect.width = chartAreaWidth;\n this.seriesClipRect.x = chart.availableSize.width - chart.margin.right - chartAreaWidth -\n (chart.legendSettings.position === 'Right' ? chart.legendModule.legendBounds.width : 0);\n for (var _i = 0, _a = chart.rows; _i < _a.length; _i++) {\n var item = _a[_i];\n this.seriesClipRect.x -= sum(item.farSizes);\n }\n };\n CartesianAxisLayoutPanel.prototype.measureRowAxis = function (chart, rect) {\n var row;\n this.calculateRowSize(rect);\n for (var _i = 0, _a = chart.rows; _i < _a.length; _i++) {\n var item = _a[_i];\n row = item;\n row.nearSizes = [];\n row.farSizes = [];\n row.insideNearSizes = [];\n row.insideFarSizes = [];\n this.arrangeAxis(row);\n this.measureDefinition(row, chart, new Size(chart.availableSize.width, row.computedHeight));\n if (this.leftSize < sum(row.nearSizes)) {\n this.leftSize = sum(row.nearSizes);\n }\n if (this.rightSize < sum(row.farSizes)) {\n this.rightSize = sum(row.farSizes);\n }\n }\n };\n CartesianAxisLayoutPanel.prototype.measureColumnAxis = function (chart, rect) {\n var column;\n this.calculateColumnSize(rect);\n for (var _i = 0, _a = chart.columns; _i < _a.length; _i++) {\n var item = _a[_i];\n column = item;\n column.farSizes = [];\n column.nearSizes = [];\n column.insideNearSizes = [];\n column.insideFarSizes = [];\n this.arrangeAxis(column);\n this.measureDefinition(column, chart, new Size(column.computedWidth, chart.availableSize.height));\n if (this.bottomSize < sum(column.nearSizes)) {\n this.bottomSize = sum(column.nearSizes);\n }\n if (this.topSize < sum(column.farSizes)) {\n this.topSize = sum(column.farSizes);\n }\n }\n };\n /**\n * Measure the column and row in chart.\n *\n * @returns {void}\n * @private\n */\n CartesianAxisLayoutPanel.prototype.measureDefinition = function (definition, chart, size) {\n var ele;\n for (var _i = 0, _a = definition.axes; _i < _a.length; _i++) {\n var axis = _a[_i];\n ele = axis.scrollbarSettings.height;\n axis.scrollBarHeight = chart.scrollBarModule && chart.zoomModule && chart.zoomSettings.enableScrollbar &&\n axis.enableScrollbarOnZooming && chart.zoomModule.isZoomed && (axis.zoomFactor < 1 || axis.zoomPosition > 0) ? ele : 0;\n axis.scrollBarHeight = chart.scrollBarModule && (chart.zoomModule && chart.zoomSettings.enableScrollbar &&\n axis.enableScrollbarOnZooming && chart.zoomModule.isZoomed && (axis.zoomFactor < 1 || axis.zoomPosition > 0)\n || axis.scrollbarSettings.enable) ? ele : 0;\n axis.getModule(chart);\n axis.baseModule.calculateRangeAndInterval(size, axis);\n definition.computeSize(axis, axis.scrollBarHeight, definition, chart);\n }\n if (definition.farSizes.length > 0) {\n definition.farSizes[definition.farSizes.length - 1] -= axisPadding;\n }\n if (definition.nearSizes.length > 0) {\n definition.nearSizes[definition.nearSizes.length - 1] -= axisPadding;\n }\n };\n /**\n * Measure the axis.\n *\n * @returns {void}\n * @private\n */\n CartesianAxisLayoutPanel.prototype.calculateAxisSize = function (rect) {\n var chart = this.chart;\n var row;\n var column;\n var definition;\n var axis;\n var nearCount = 0;\n var farCount = 0;\n var size = 0;\n var x;\n var y;\n var axisOffset;\n this.calculateRowSize(rect);\n for (var i = 0, len = chart.rows.length; i < len; i++) {\n row = chart.rows[i];\n nearCount = 0;\n farCount = 0;\n for (var j = 0, len_1 = row.axes.length; j < len_1; j++) {\n axis = row.axes[j];\n axisOffset = axis.plotOffset;\n if (axis.rect.height === 0) {\n axis.rect.height = row.computedHeight;\n size = 0;\n for (var k = i + 1, len_2 = i + axis.span; k < len_2; k++) {\n definition = chart.rows[k];\n size += definition.computedHeight;\n }\n axis.rect.y = (row.computedTop - size) + (axis.plotOffsetTop ? axis.plotOffsetTop : axisOffset);\n axis.rect.height = (axis.rect.height + size) -\n (this.getAxisOffsetValue(axis.plotOffsetTop, axis.plotOffsetBottom, axis.plotOffset));\n axis.rect.width = 0;\n }\n if (axis.isAxisOpposedPosition) {\n if (axis.labelPosition === 'Inside' && axis.orientation === 'Vertical') {\n x = rect.x + rect.width - sum(subArray(row.insideFarSizes, farCount));\n }\n else {\n x = rect.x + rect.width + sum(subArray(row.farSizes, farCount));\n }\n axis.rect.x = axis.rect.x >= x ? axis.rect.x : x;\n farCount++;\n }\n else {\n if (axis.labelPosition === 'Inside' && axis.orientation === 'Vertical') {\n x = rect.x + sum(subArray(row.insideNearSizes, nearCount));\n }\n else {\n x = rect.x - sum(subArray(row.nearSizes, nearCount));\n }\n axis.rect.x = axis.rect.x <= x ? axis.rect.x : x;\n nearCount++;\n }\n }\n }\n this.calculateColumnSize(rect);\n for (var i = 0, len = chart.columns.length; i < len; i++) {\n column = chart.columns[i];\n nearCount = 0;\n farCount = 0;\n for (var j = 0, len_3 = column.axes.length; j < len_3; j++) {\n axis = column.axes[j];\n axisOffset = axis.plotOffset;\n if (axis.rect.width === 0) {\n for (var k = i, len_4 = (i + axis.span); k < len_4; k++) {\n definition = chart.columns[k];\n axis.rect.width += definition.computedWidth;\n }\n axis.rect.x = column.computedLeft + (axis.plotOffsetLeft ? axis.plotOffsetLeft : axisOffset);\n axis.rect.width -= (this.getAxisOffsetValue(axis.plotOffsetLeft, axis.plotOffsetRight, axis.plotOffset));\n axis.rect.height = 0;\n }\n if (axis.isAxisOpposedPosition) {\n if (axis.labelPosition === 'Inside' && axis.orientation === 'Horizontal') {\n y = rect.y + sum(subArray(column.insideFarSizes, farCount));\n }\n else {\n y = rect.y - sum(subArray(column.farSizes, farCount));\n }\n axis.rect.y = axis.rect.y <= y ? axis.rect.y : y;\n farCount++;\n }\n else {\n if (axis.labelPosition === 'Inside' && axis.orientation === 'Horizontal') {\n y = rect.y + rect.height - sum(subArray(column.insideNearSizes, nearCount));\n }\n else {\n y = rect.y + rect.height + sum(subArray(column.nearSizes, nearCount));\n }\n axis.rect.y = axis.rect.y >= y ? axis.rect.y : y;\n nearCount++;\n }\n }\n }\n };\n /**\n * Measure the axis.\n *\n * @returns {void}\n * @private\n */\n CartesianAxisLayoutPanel.prototype.measure = function () {\n var chart = this.chart;\n var row;\n var column;\n var definition;\n var actualIndex;\n var span;\n for (var _i = 0, _a = chart.axisCollections; _i < _a.length; _i++) {\n var axis = _a[_i];\n //definition.Axes = axis;\n if (axis.orientation === 'Vertical') {\n chart.verticalAxes.push(axis);\n actualIndex = this.getActualRow(axis);\n row = chart.rows[actualIndex];\n this.pushAxis(row, axis);\n span = ((actualIndex + axis.span) > chart.rows.length ? chart.rows.length : (actualIndex + axis.span));\n for (var j = actualIndex + 1; j < span; j++) {\n definition = chart.rows[j];\n definition.axes[row.axes.length - 1] = axis;\n chart.rows[j] = definition;\n }\n chart.rows[actualIndex] = row;\n }\n else {\n chart.horizontalAxes.push(axis);\n actualIndex = this.getActualColumn(axis);\n column = chart.columns[actualIndex];\n this.pushAxis(column, axis);\n span = ((actualIndex + axis.span) > chart.columns.length ? chart.columns.length : (actualIndex + axis.span));\n for (var j = actualIndex + 1; j < span; j++) {\n definition = chart.columns[j];\n definition.axes[column.axes.length - 1] = axis;\n chart.columns[j] = definition;\n }\n chart.columns[actualIndex] = column;\n }\n axis.isRTLEnabled = chart.enableRtl;\n axis.setIsInversedAndOpposedPosition();\n }\n };\n CartesianAxisLayoutPanel.prototype.getAxisOffsetValue = function (position1, position2, plotOffset) {\n var rangeOffset = position1 ? (position1 + (position2 ? position2 :\n plotOffset)) : (position2 ? position2 + plotOffset : 2 * plotOffset);\n return rangeOffset;\n };\n CartesianAxisLayoutPanel.prototype.crossAt = function (chart) {\n for (var _i = 0, _a = chart.axisCollections; _i < _a.length; _i++) {\n var axis = _a[_i];\n if (axis.crossesAt === null) {\n continue;\n }\n if (!axis.crossesInAxis) {\n if (chart.requireInvertedAxis) {\n axis.crossInAxis = ((axis.orientation === 'Horizontal')) ? chart.primaryXAxis : chart.primaryYAxis;\n }\n else {\n axis.crossInAxis = ((axis.orientation === 'Horizontal')) ? chart.primaryYAxis : chart.primaryXAxis;\n }\n axis.crossAt = this.updateCrossAt(axis.crossInAxis, axis.crossesAt);\n continue;\n }\n else {\n for (var i = 2, len = chart.axisCollections.length; i < len; i++) {\n if (axis.crossesInAxis === chart.axisCollections[i].name) {\n axis.crossInAxis = chart.axisCollections[i];\n axis.crossAt = this.updateCrossAt(axis.crossInAxis, axis.crossesAt);\n continue;\n }\n }\n }\n }\n };\n CartesianAxisLayoutPanel.prototype.updateCrossAt = function (axis, crossAt) {\n switch (axis.valueType) {\n case 'DateTime':\n var option = {\n skeleton: 'full',\n type: 'dateTime'\n };\n var dateParser = this.chart.intl.getDateParser(option);\n var dateFormatter = this.chart.intl.getDateFormat(option);\n return Date.parse(dateParser(dateFormatter(new Date(DataUtil.parse.parseJson({ val: crossAt }).val))));\n case 'Category':\n return parseFloat(crossAt) ? parseFloat(crossAt) : axis.labels.indexOf(crossAt);\n case 'Logarithmic':\n return logBase(crossAt, axis.logBase);\n default:\n return crossAt;\n }\n };\n CartesianAxisLayoutPanel.prototype.pushAxis = function (definition, axis) {\n for (var i = 0, len = definition.axes.length; i <= len; i++) {\n if (!definition.axes[i]) {\n definition.axes[i] = axis;\n break;\n }\n }\n };\n CartesianAxisLayoutPanel.prototype.arrangeAxis = function (definition) {\n var axisCollection = [];\n for (var i = 0, len = definition.axes.length; i <= len; i++) {\n if (definition.axes[i]) {\n axisCollection.push(definition.axes[i]);\n }\n }\n definition.axes = axisCollection;\n };\n CartesianAxisLayoutPanel.prototype.getActualColumn = function (axis) {\n var actualLength = this.chart.columns.length;\n var pos = axis.columnIndex;\n var result = pos >= actualLength ? actualLength - 1 : (pos < 0 ? 0 : pos);\n return result;\n };\n CartesianAxisLayoutPanel.prototype.getActualRow = function (axis) {\n var actualLength = this.chart.rows.length;\n var pos = axis.rowIndex;\n var result = pos >= actualLength ? actualLength - 1 : (pos < 0 ? 0 : pos);\n return result;\n };\n /**\n * Measure the row size.\n *\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.calculateRowSize = function (rect) {\n /*! Calculate row size */\n var chart = this.chart;\n var row;\n var rowTop = rect.y + rect.height;\n var height = 0;\n var remainingHeight = Math.max(0, rect.height);\n for (var i = 0, len = chart.rows.length; i < len; i++) {\n row = chart.rows[i];\n if (row.height.indexOf('%') !== -1) {\n height = Math.min(remainingHeight, (rect.height * parseInt(row.height, 10) / 100));\n }\n else {\n height = Math.min(remainingHeight, parseInt(row.height, 10));\n }\n height = (i !== (len - 1)) ? height : remainingHeight;\n row.computedHeight = height;\n rowTop -= height;\n row.computedTop = rowTop;\n remainingHeight -= height;\n }\n };\n /**\n * Measure the row size.\n *\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.calculateColumnSize = function (rect) {\n /*! Calculate column size */\n var chart = this.chart;\n var column;\n var columnLeft = rect.x;\n var width = 0;\n var remainingWidth = Math.max(0, rect.width);\n for (var i = 0, len = chart.columns.length; i < len; i++) {\n column = chart.columns[i];\n if (column.width.indexOf('%') !== -1) {\n width = Math.min(remainingWidth, (rect.width * parseInt(column.width, 10) / 100));\n }\n else {\n width = Math.min(remainingWidth, parseInt(column.width, 10));\n }\n width = (i !== (len - 1)) ? width : remainingWidth;\n column.computedWidth = width;\n column.computedLeft = columnLeft;\n columnLeft += width;\n remainingWidth -= width;\n }\n };\n /**\n * To render the axis element.\n *\n * @returns {void}\n * @private\n */\n // tslint:disable-next-line:max-func-body-length\n CartesianAxisLayoutPanel.prototype.renderAxes = function () {\n var chart = this.chart;\n var axis;\n var axisElement = chart.renderer.createGroup({ id: chart.element.id + 'AxisInsideCollection' });\n var axisLineElement = chart.renderer.createGroup({ id: chart.element.id + 'AxisOutsideCollection' });\n if (axisLineElement) {\n axisLineElement.setAttribute('aria-hidden', 'true');\n }\n var outsideElement;\n var isInside;\n for (var i = 0, len = chart.axisCollections.length; i < len; i++) {\n var axisVisibility = true;\n axis = chart.axisCollections[i];\n this.element = chart.renderer.createGroup({ id: chart.element.id + 'AxisGroup' + i + 'Inside' });\n if (this.element) {\n this.element.setAttribute('aria-hidden', 'true');\n }\n outsideElement = chart.renderer.createGroup({ id: chart.element.id + 'AxisGroup' + i + 'Outside' });\n if (outsideElement) {\n outsideElement.setAttribute('aria-hidden', 'true');\n }\n for (var _i = 0, _a = axis.series; _i < _a.length; _i++) {\n var series = _a[_i];\n if (axis.name === series.yAxisName || axis.name === series.xAxisName) {\n axisVisibility = series.visible;\n if (series.category === 'Pareto' && !series.paretoOptions.showAxis && series.type === 'Line') {\n axisVisibility = false;\n }\n if (!axisVisibility) {\n continue;\n }\n else {\n break;\n }\n }\n }\n if (!axisVisibility) {\n continue;\n }\n isInside = this.findAxisPosition(axis);\n if (axis.orientation === 'Horizontal') {\n axis.updateCrossValue();\n if (axis.visible && axis.internalVisibility && axis.lineStyle.width > 0) {\n this.drawAxisLine(axis, i, axis.plotOffset, 0, 0, 0, axis.plotOffsetLeft, axis.plotOffsetRight, isInside ? outsideElement : this.element, axis.updatedRect);\n }\n if (axis.majorGridLines.width > 0 || axis.majorTickLines.width > 0 || axis.minorTickLines.width > 0 || axis.minorGridLines.width > 0) {\n this.drawXAxisGridLine(axis, i, (isInside || axis.tickPosition === 'Inside') ? outsideElement : this.element, axis.updatedRect);\n }\n if (axis.visible && axis.internalVisibility) {\n this.drawXAxisLabels(axis, i, (isInside || axis.labelPosition === 'Inside') ? outsideElement : this.element, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n this.drawXAxisBorder(axis, i, (isInside || axis.labelPosition === 'Inside') ? outsideElement : this.element, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n this.drawXAxisTitle(axis, i, isInside ? outsideElement : this.element, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n }\n }\n else {\n axis.updateCrossValue();\n if (axis.visible && axis.internalVisibility && axis.lineStyle.width > 0) {\n this.drawAxisLine(axis, i, 0, axis.plotOffset, axis.plotOffsetBottom, axis.plotOffsetTop, 0, 0, isInside ? outsideElement : this.element, axis.updatedRect);\n }\n if (axis.majorGridLines.width > 0 || axis.majorTickLines.width > 0 || axis.minorTickLines.width > 0 || axis.minorGridLines.width > 0) {\n this.drawYAxisGridLine(axis, i, (isInside || axis.tickPosition === 'Inside') ? outsideElement : this.element, axis.updatedRect);\n }\n if (axis.visible && axis.internalVisibility) {\n this.drawYAxisLabels(axis, i, (isInside || axis.labelPosition === 'Inside') ? outsideElement : this.element, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n this.drawYAxisBorder(axis, i, (isInside || axis.labelPosition === 'Inside') ? outsideElement : this.element, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n this.drawYAxisTitle(axis, i, isInside ? outsideElement : this.element, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n }\n }\n if (!this.chart.enableCanvas) {\n axisElement.appendChild(this.element);\n if (outsideElement && outsideElement.childNodes.length > 0) {\n axisLineElement.appendChild(outsideElement);\n }\n }\n if (chart.scrollBarModule && ((chart.zoomSettings.enableScrollbar && axis.enableScrollbarOnZooming) ||\n axis.scrollbarSettings.enable)) {\n this.renderScrollbar(chart, axis);\n }\n }\n this.element = chart.renderer.createGroup({ id: chart.element.id + 'DefinitionLine' });\n for (var j = 0, len = chart.rows.length; j < len; j++) {\n var row = chart.rows[j];\n if (row.border.color) {\n this.drawBottomLine(row, j, true);\n }\n }\n for (var j = 0, len = chart.columns.length; j < len; j++) {\n var column = chart.columns[j];\n if (column.border.color) {\n this.drawBottomLine(column, j, false);\n }\n }\n if (!this.chart.enableCanvas) {\n axisElement.appendChild(this.element);\n }\n appendChildElement(chart.enableCanvas, chart.svgObject, axisElement, chart.redraw);\n return axisLineElement;\n };\n /**\n * To render the axis scrollbar\n *\n * @param {Chart} chart chart\n * @param {Axis} axis axis\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.renderScrollbar = function (chart, axis) {\n var isZoomed = isNullOrUndefined(chart.zoomModule) ? false : chart.zoomModule.isZoomed;\n if (((isZoomed && (axis.zoomFactor < 1 || axis.zoomPosition > 0)) || (axis.scrollbarSettings.enable &&\n (axis.zoomFactor <= 1 || axis.zoomPosition >= 0))) &&\n (!axis.zoomingScrollBar.isScrollUI)) {\n if (!chart.scrollElement) {\n chart.scrollElement = redrawElement(chart.redraw, chart.element.id + '_scrollElement') || createElement('div', { id: chart.element.id + '_scrollElement' });\n }\n appendChildElement(false, chart.scrollElement, axis.zoomingScrollBar.render(true), true);\n }\n else if (axis.zoomFactor === 1 && axis.zoomPosition === 0 && axis.zoomingScrollBar.svgObject && !axis.scrollbarSettings.enable) {\n axis.zoomingScrollBar.destroy();\n }\n else if (axis.zoomingScrollBar.svgObject) {\n axis.zoomingScrollBar.svgObject.style.top = (axis.isAxisOpposedPosition && axis.orientation === 'Horizontal' ? -16 : 0)\n + axis.rect.y + Math.max(0.5, axis.lineStyle.width / 2) + 'px';\n axis.zoomingScrollBar.svgObject.style.left = (axis.isAxisOpposedPosition && axis.orientation !== 'Horizontal' ? 16 : 0)\n + axis.rect.x - (axis.orientation === 'Vertical' ? axis.scrollbarSettings.height : 0) + 'px';\n }\n if (axis.zoomingScrollBar.isScrollUI) {\n axis.zoomingScrollBar.isScrollUI = false;\n }\n };\n /**\n * To find the axis position\n *\n * @param {Axis} axis axis\n * @returns {boolean} axis position\n */\n CartesianAxisLayoutPanel.prototype.findAxisPosition = function (axis) {\n return axis.crossAt !== null && axis.isInside(axis.crossInAxis.visibleRange);\n };\n /**\n * To render the bootom line of the columns and rows\n *\n * @param {Row | Column} definition definition\n * @param {number} index index\n * @param {boolean} isRow isRow\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawBottomLine = function (definition, index, isRow) {\n var chart = this.chart;\n var optionsLine = {};\n var x1;\n var x2;\n var y1;\n var y2;\n var definitionName;\n if (isRow) {\n definition = definition;\n y1 = y2 = definition.computedTop + definition.computedHeight;\n x1 = this.seriesClipRect.x;\n x2 = x1 + this.seriesClipRect.width;\n definitionName = 'Row';\n }\n else {\n definition = definition;\n x1 = x2 = definition.computedLeft;\n y1 = this.seriesClipRect.y;\n y2 = y1 + this.seriesClipRect.height;\n definitionName = 'Column';\n }\n optionsLine = {\n 'id': chart.element.id + '_AxisBottom_' + definitionName + index,\n x1: x1,\n y1: y1,\n x2: x2,\n y2: y2,\n 'stroke-width': definition.border.width,\n 'stroke': definition.border.color\n };\n this.htmlObject = chart.renderer.drawLine(optionsLine);\n this.element.appendChild(this.htmlObject);\n };\n /**\n * To render the axis line\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {number} plotX plotX\n * @param {number} plotY plotY\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawAxisLine = function (axis, index, plotX, plotY, plotBottom, plotTop, plotLeft, plotRight, parent, rect) {\n var chart = this.chart;\n var optionsLine = {};\n var element = getElement(chart.element.id + 'AxisLine_' + index);\n var direction = element ? element.getAttribute('d') : '';\n element = null;\n optionsLine = {\n 'id': chart.element.id + 'AxisLine_' + index,\n 'd': 'M ' + (rect.x - plotX - plotLeft) + ' ' + (rect.y - plotY - plotTop) +\n ' L ' + (rect.x + rect.width + plotX + plotRight) + ' ' + (rect.y + rect.height + plotY + plotBottom),\n 'stroke-dasharray': axis.lineStyle.dashArray,\n 'stroke-width': axis.lineStyle.width,\n 'stroke': axis.lineStyle.color || chart.themeStyle.axisLine\n };\n this.htmlObject = chart.renderer.drawPath(optionsLine);\n appendChildElement(chart.enableCanvas, parent, this.htmlObject, chart.redraw, true, 'x', 'y', null, direction);\n };\n /**\n * To render the yAxis grid line\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawYAxisGridLine = function (axis, index, parent, rect) {\n var isLogAxis = axis.valueType === 'Logarithmic';\n var isCategoryAxis = axis.valueType.indexOf('Category') > -1;\n var tempInterval;\n var pointY = 0;\n var majorGrid = '';\n var majorTick = '';\n var minorGridDirection;\n var isOpposed = axis.isAxisOpposedPosition;\n var tickSize = isOpposed ? axis.majorTickLines.height : -axis.majorTickLines.height;\n var axisLineSize = (isOpposed) ? axis.lineStyle.width * 0.5 : -axis.lineStyle.width * 0.5;\n var ticksbwtLabel = (axis.valueType === 'Category' && axis.labelPlacement === 'BetweenTicks') ?\n 0.5 : 0;\n var scrollBarHeight = isNullOrUndefined(axis.crossesAt) ? isOpposed ? axis.scrollBarHeight :\n -axis.scrollBarHeight : 0;\n var isTickInside = axis.tickPosition === 'Inside';\n var ticks = isTickInside ? (rect.x - tickSize - axisLineSize) : (rect.x + tickSize + axisLineSize + scrollBarHeight);\n var length = axis.visibleLabels.length;\n var chartThemeStyle = this.chart.themeStyle;\n if (axis.valueType.indexOf('Category') > -1 && axis.labelPlacement === 'BetweenTicks' && length > 0 && !this.chart.stockChart) {\n length += 1;\n }\n var minorGridLines = axis.minorGridLines;\n var minorTickLines = axis.minorTickLines;\n //Gridlines\n for (var i = 0; i < length; i++) {\n tempInterval = !axis.visibleLabels[i] ? (axis.visibleLabels[i - 1].value + axis.visibleRange.interval) - ticksbwtLabel\n : axis.visibleLabels[i].value - ticksbwtLabel;\n pointY = valueToCoefficient(tempInterval, axis) * rect.height;\n pointY = (pointY * -1) + (rect.y + rect.height);\n if (pointY >= rect.y && (rect.y + rect.height) >= pointY) {\n if ((inside(tempInterval, axis.visibleRange)) || this.isBorder(axis, i, pointY)) {\n majorGrid = 'M ' + this.seriesClipRect.x + ' ' + (pointY) +\n ' L ' + (this.seriesClipRect.x + this.seriesClipRect.width) + ' ' + pointY;\n this.renderGridLine(axis, index, majorGrid, axis.majorGridLines, '_MajorGridLine_', i, this.element, chartThemeStyle.majorGridLine, axis.majorGridLines.dashArray);\n }\n majorTick = 'M ' + (rect.x + axisLineSize + (isTickInside ? scrollBarHeight : 0)) + ' ' + pointY +\n ' L ' + (ticks) + ' ' + pointY;\n this.renderGridLine(axis, index, majorTick, axis.majorTickLines, '_MajorTickLine_', i, parent, chartThemeStyle.majorTickLine);\n if ((minorGridLines.width > 0 || minorTickLines.width > 0) && axis.minorTicksPerInterval > 0) {\n if (i === 0 && isZoomSet(axis) && !isLogAxis && !isCategoryAxis) {\n this.renderMinorGridOnZooming(axis, tempInterval, rect, i, index, chartThemeStyle, parent);\n }\n minorGridDirection = this.drawAxisMinorLine(axis, tempInterval, rect, i);\n this.renderGridLine(axis, index, minorGridDirection[0], minorGridLines, '_MinorGridLine_', i, this.element, chartThemeStyle.minorGridLine, minorGridLines.dashArray);\n this.renderGridLine(axis, index, minorGridDirection[1], minorTickLines, '_MinorTickLine_', i, parent, chartThemeStyle.minorTickLine);\n if (i === length - 1 && isZoomSet(axis) && isLogAxis && !isCategoryAxis) {\n this.renderMinorGridOnZooming(axis, (tempInterval + axis.visibleRange.interval), rect, i, index, chartThemeStyle, parent);\n }\n }\n }\n }\n };\n /**\n * To check the border of the axis\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {number} value value\n * @returns {boolean} check the border of the axis\n */\n CartesianAxisLayoutPanel.prototype.isBorder = function (axis, index, value) {\n var border = this.chart.chartArea.border;\n var rect = this.seriesClipRect;\n var orientation = axis.orientation;\n var start = (orientation === 'Horizontal') ? rect.x : rect.y;\n var size = (orientation === 'Horizontal') ? rect.width : rect.height;\n var startIndex = (orientation === 'Horizontal') ? 0 : axis.visibleLabels.length - 1;\n var endIndex = (orientation === 'Horizontal') ? axis.visibleLabels.length - 1 : 0;\n if (axis.plotOffset > 0) {\n return true;\n }\n else if ((value === start || value === (start + size)) && (border.width <= 0 || border.color === 'transparent')) {\n return true;\n }\n else if ((value !== start && index === startIndex) || (value !== (start + size) && index === endIndex)) {\n return true;\n }\n return false;\n };\n /**\n * To render the yAxis label\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n * @private\n */\n CartesianAxisLayoutPanel.prototype.drawYAxisLabels = function (axis, index, parent, rect) {\n var chart = this.chart;\n var label;\n var pointX = 0;\n var pointY = 0;\n var elementSize;\n var labelSpace = axis.labelPadding;\n var options;\n var isAxisBreakLabel;\n var isLabelInside = axis.labelPosition === 'Inside';\n var isOpposed = axis.isAxisOpposedPosition;\n var RotatedWidth;\n var tickSpace = axis.labelPosition === axis.tickPosition ? axis.majorTickLines.height : 0;\n var padding = tickSpace + labelSpace + axis.lineStyle.width * 0.5;\n var angle = axis.angle % 360;\n var isVerticalAngle = (angle === -90 || angle === 90 || angle === 270 || angle === -270);\n padding += (isVerticalAngle) ? (isLabelInside ? 5 : -5) : 0;\n padding = (isOpposed) ? padding : -padding;\n var labelElement = chart.renderer.createGroup({ id: chart.element.id + 'AxisLabels' + index });\n var scrollBarHeight = isNullOrUndefined(axis.crossesAt) ? axis.scrollBarHeight * (isOpposed ? 1 : -1) : 0;\n var textHeight;\n var textPadding;\n var maxLineWidth;\n var pixel = 10;\n var isInverse = axis.isAxisInverse;\n var previousEnd = isInverse ? rect.y : (rect.y + rect.height);\n var labelPadding;\n var intervalLength;\n var labelHeight;\n var yAxisLabelX;\n var isLabelOnAxisLineLeft = ((!isOpposed && !isLabelInside) || (isOpposed && isLabelInside));\n if (isLabelInside) {\n labelPadding = !isLabelOnAxisLineLeft ? -padding : padding;\n }\n else {\n labelPadding = !isLabelOnAxisLineLeft ? -padding + (chart.enableRtl ? -scrollBarHeight : scrollBarHeight) : padding + (chart.enableRtl ? -scrollBarHeight : scrollBarHeight);\n }\n var sizeWidth = [];\n var breakLabelSizeWidth = [];\n axis.visibleLabels.map(function (item) {\n sizeWidth.push(item.size['width']);\n breakLabelSizeWidth.push(item.breakLabelSize['width']);\n });\n var LabelMaxWidth = Math.max.apply(Math, sizeWidth);\n var breakLabelMaxWidth = Math.max.apply(Math, breakLabelSizeWidth);\n RotatedWidth = LabelMaxWidth;\n if (angle >= -45 && angle <= 45 && angle !== 0) {\n RotatedWidth = LabelMaxWidth * Math.cos(angle * Math.PI / 180);\n if (RotatedWidth < 0) {\n RotatedWidth = -RotatedWidth;\n }\n }\n for (var i = 0, len = axis.visibleLabels.length; i < len; i++) {\n label = axis.visibleLabels[i];\n isAxisBreakLabel = isBreakLabel(axis.visibleLabels[i].originalText);\n elementSize = isAxisBreakLabel ? axis.visibleLabels[i].breakLabelSize : axis.visibleLabels[i].size;\n pointY = (valueToCoefficient(axis.visibleLabels[i].value, axis) * rect.height) + (chart.stockChart ? 7 : 0);\n pointY = Math.floor((pointY * -1) + (rect.y + rect.height));\n textHeight = ((elementSize.height / 8) * axis.visibleLabels[i].text.length / 2);\n textPadding = (chart.requireInvertedAxis && axis.labelPosition === 'Inside') ? 0 : ((elementSize.height / 4) * 3) + 3;\n intervalLength = rect.height / axis.visibleLabels.length;\n labelHeight = ((axis.labelIntersectAction === 'Trim' || axis.labelIntersectAction === 'Wrap') && angle !== 0 &&\n elementSize.width > intervalLength) ? intervalLength : elementSize.width;\n pointY = (isAxisBreakLabel ? (axis.labelPosition === 'Inside' ? (pointY - (elementSize.height / 2) - textHeight + textPadding)\n : (pointY - textHeight)) : (axis.labelPosition === 'Inside' ? pointY + textPadding : pointY));\n if (axis.labelPosition === 'Inside' && ((i === 0 && !axis.isInversed) || (i === len - 1 && axis.isInversed))) {\n if (chart.stockChart) {\n pointY -= (textPadding);\n }\n else {\n pointY -= (textPadding - ((chart.requireInvertedAxis && axis.labelPosition === 'Inside') ? 0 : (axis.opposedPosition ? -padding : padding)));\n }\n }\n if (axis.majorGridLines.width > axis.majorTickLines.width) {\n maxLineWidth = axis.majorGridLines.width;\n }\n else {\n maxLineWidth = axis.majorTickLines.width;\n }\n if (axis.labelStyle.textAlignment === 'Far') {\n pointY = pointY - maxLineWidth - pixel;\n }\n else if (axis.labelStyle.textAlignment === 'Near') {\n pointY = pointY + maxLineWidth + pixel;\n }\n else if (axis.labelStyle.textAlignment === 'Center') {\n // eslint-disable-next-line no-self-assign\n pointY = pointY;\n }\n // label X value adjustment (Start)\n if (isLabelInside) {\n yAxisLabelX = labelPadding + ((angle === 0 ? elementSize.width : (isAxisBreakLabel ? breakLabelMaxWidth : LabelMaxWidth)) / 2);\n }\n else {\n yAxisLabelX = labelPadding - ((angle === 0 ? elementSize.width : (isAxisBreakLabel ? breakLabelMaxWidth : RotatedWidth)) / 2);\n }\n pointX = isOpposed ? (rect.x - yAxisLabelX) : (rect.x + yAxisLabelX);\n if (isVerticalAngle) {\n pointX += (isOpposed) ? -10 : 10;\n }\n yAxisLabelX = labelPadding;\n options = new TextOption(chart.element.id + index + '_AxisLabel_' + i, pointX, pointY, 'middle', label.text, '', 'middle', angle);\n switch (axis.edgeLabelPlacement) {\n case 'None':\n break;\n case 'Hide':\n if (((i === 0 || (isInverse && i === len - 1)) && options.y > rect.y) ||\n (((i === len - 1) || (isInverse && i === 0)) && options.y - elementSize.height * 0.5 < rect.y)) {\n options.text = '';\n }\n break;\n case 'Shift':\n if ((i === 0 || (isInverse && i === len - 1)) && options.y > rect.y + rect.height) {\n options.y = pointY = rect.y + rect.height;\n }\n else if (((i === len - 1) || (isInverse && i === 0)) && (options.y < rect.y)) {\n options.y = pointY = rect.y + elementSize.height * 0.5;\n }\n break;\n }\n // ------- Hide Calculation (Start) -------------\n var previousYValue = options.y;\n var currentYValue = options.y - labelHeight;\n if (isAxisBreakLabel) {\n previousYValue = (options.y - (labelHeight / 2));\n currentYValue = options.y + (labelHeight / 2);\n }\n if ((angle === 90 || angle === 270) && axis.labelIntersectAction === 'Hide' && i !== 0 &&\n (!isInverse ? previousYValue >= previousEnd : currentYValue <= previousEnd)) {\n continue;\n }\n previousEnd = isInverse ? previousYValue : currentYValue;\n // ------- Hide Calculation (End) -------------\n options.transform = 'rotate(' + angle + ',' + pointX + ',' + pointY + ')';\n textElement(chart.renderer, options, label.labelStyle, label.labelStyle.color || chart.themeStyle.axisLabelFont.color, labelElement, false, chart.redraw, true, true, null, null, null, null, chart.enableCanvas, null, chart.themeStyle.axisLabelFont);\n }\n if (!this.chart.enableCanvas) {\n if (!chart.delayRedraw) {\n appendChildElement(chart.enableCanvas, parent, labelElement, chart.redraw);\n }\n else if (axis.visible && axis.internalVisibility) {\n this.createZoomingLabel(this.chart, labelElement, axis, index, rect);\n }\n }\n };\n /**\n * To get X value based on lineBreakAlignment for Y axis line break labels only.\n *\n * @param {number} x text x position\n * @param {Axis} axis y axis values\n * @param {number} textWidth axis label width\n * @returns {number} returns suitable axis label x position\n */\n CartesianAxisLayoutPanel.prototype.getAxisLabelXvalue = function (x, axis, textWidth) {\n var anchor = axis.lineBreakAlignment;\n var isLabelInside = axis.labelPosition === 'Inside';\n var isOpposed = axis.isAxisOpposedPosition;\n if ((isOpposed && isLabelInside) || (!isOpposed && !isLabelInside)) {\n return (anchor === 'Right' ? x : (anchor === 'Center' ? (x - textWidth / 2) : (x - textWidth)));\n }\n else {\n return (anchor === 'Left' ? x : (anchor === 'Center' ? (x + textWidth / 2) : (x + textWidth)));\n }\n };\n /**\n * To render the yAxis label border.\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawYAxisBorder = function (axis, index, parent, rect) {\n if (axis.border.width > 0) {\n var startY = void 0;\n var pointY = void 0;\n var scrollBarHeight = axis.labelPosition === 'Outside' ? axis.scrollBarHeight : 0;\n var isOpposed = axis.isAxisOpposedPosition;\n scrollBarHeight = (isOpposed ? 1 : -1) * scrollBarHeight;\n var gap = (rect.height / axis.visibleRange.delta) * (axis.valueType === 'DateTime' ? axis.dateTimeInterval\n : axis.visibleRange.interval);\n var endY = void 0;\n var length_1 = axis.maxLabelSize.width + 10 + ((axis.tickPosition === axis.labelPosition) ?\n axis.majorTickLines.height : 0);\n var labelBorder = '';\n var ticksbwtLabel = (axis.valueType === 'Category' && axis.labelPlacement === 'BetweenTicks') ? -0.5 : 0;\n var endX = ((isOpposed && axis.labelPosition === 'Inside') || (!isOpposed\n && axis.labelPosition === 'Outside')) ? rect.x - length_1 + scrollBarHeight : rect.x + length_1 + scrollBarHeight;\n for (var i = 0, len = axis.visibleLabels.length; i < len; i++) {\n pointY = valueToCoefficient(axis.visibleLabels[i].value + ticksbwtLabel, axis);\n pointY = (axis.isAxisInverse ? (1 - pointY) : pointY) * rect.height;\n if (axis.valueType === 'Category' && axis.labelPlacement === 'BetweenTicks') {\n startY = (pointY * -1) + (rect.y + rect.height);\n endY = (pointY * -1) - (gap) + (rect.y + rect.height);\n }\n else {\n startY = (pointY * -1) + gap / 2 + (rect.y + rect.height);\n endY = (pointY * -1) - gap / 2 + (rect.y + rect.height);\n }\n switch (axis.border.type) {\n case 'Rectangle':\n case 'WithoutTopBorder':\n if (startY > (rect.y + rect.height)) {\n labelBorder += ('M' + ' ' + endX + ' ' + (rect.y + rect.height) + ' ' + 'L' + ' ' + endX + ' ' + endY + ' ');\n }\n else if (Math.floor(rect.y) > (endY)) {\n labelBorder += ('M' + ' ' + (rect.x + scrollBarHeight) + ' ' + startY + ' ' + 'L' + ' ' + endX\n + ' ' + startY + ' ' + 'L' + ' ' + endX + ' ' + (rect.y) + ' ');\n }\n else {\n labelBorder += ('M' + ' ' + (rect.x + scrollBarHeight) + ' ' + startY + ' ' + 'L' + ' ' + endX +\n ' ' + startY + ' ' + 'L' + ' ' + endX + ' ' + endY + ' ');\n if (i === axis.visibleLabels.length - 1) {\n labelBorder += ('M' + ' ' + (rect.x + scrollBarHeight) + ' ' + endY + ' ' + 'L' + ' ' +\n endX + ' ' + endY + ' ');\n }\n }\n break;\n case 'WithoutTopandBottomBorder':\n if (!(startY > rect.y + rect.height) && !((endY) < Math.floor(rect.y))) {\n labelBorder += ('M' + ' ' + (rect.x + scrollBarHeight) + ' ' + startY + ' ' + 'L' + ' ' + endX +\n ' ' + startY + ' ' + 'M' + ' ' + endX + ' ' + endY + ' ' +\n 'L' + ' ' + (rect.x + scrollBarHeight) + ' ' + endY);\n }\n break;\n }\n }\n labelBorder += (axis.border.type === 'Rectangle') ? ('M' + ' ' + (rect.x + scrollBarHeight) + ' ' + rect.y + ' ' + 'L' + ' ' +\n (rect.x + scrollBarHeight) + ' ' + (rect.y + rect.height) + ' ') : '';\n if (labelBorder !== '') {\n this.createAxisBorderElement(axis, index, labelBorder, parent);\n }\n }\n for (var i = 0; i < this.chart.visibleSeries.length; i++) {\n if (axis.multiLevelLabels.length > 0 && this.chart.multiLevelLabelModule && this.chart.visibleSeries[i].visible) {\n this.chart.multiLevelLabelModule.renderYAxisMultiLevelLabels(axis, index, parent, rect);\n break;\n }\n }\n };\n /**\n * To render the yAxis title\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawYAxisTitle = function (axis, index, parent, rect) {\n if (axis.title) {\n var chart = this.chart;\n var isRotated = false;\n var isOpposed = axis.isAxisOpposedPosition;\n var labelRotation = (axis.titleRotation == null ? (isOpposed ? 90 : -90) : axis.titleRotation) % 360;\n var padding = (axis.tickPosition === 'Inside' ? 0 : axis.majorTickLines.height + axis.titlePadding) +\n (axis.labelPosition === 'Inside' ? 0 :\n (axis.maxLabelSize.width + axis.multiLevelLabelHeight + this.padding));\n padding = isOpposed ? padding + axis.scrollBarHeight : -padding - axis.scrollBarHeight;\n if ((labelRotation !== -90 && !isOpposed) || (labelRotation !== 90 && isOpposed)) {\n padding += axis.isAxisOpposedPosition ? axis.titleSize.width / 2 + axis.labelPadding : -axis.titleSize.width / 2 - axis.labelPadding;\n isRotated = true;\n }\n var x = rect.x + padding;\n var y = void 0;\n var anchor = void 0;\n if (axis.titleStyle.textAlignment === 'Center') {\n anchor = 'middle';\n y = rect.y + rect.height * 0.5;\n }\n else if (axis.titleStyle.textAlignment === 'Near') {\n anchor = axis.opposedPosition ? 'end' : 'start';\n y = rect.height + rect.y;\n }\n else {\n anchor = axis.opposedPosition ? 'start' : 'end';\n y = rect.y;\n }\n var titleSize = (axis.titleSize.height * (axis.titleCollection.length - 1));\n var options = new TextOption(chart.element.id + '_AxisTitle_' + index, x, y + (isRotated ? -titleSize : -axis.labelPadding - titleSize), anchor, axis.titleCollection, 'rotate(' + labelRotation + ',' + (x) + ',' + (y) + ')', null, labelRotation);\n var element = textElement(chart.renderer, options, axis.titleStyle, axis.titleStyle.color || chart.themeStyle.axisTitleFont.color, parent, null, null, null, null, null, null, null, null, chart.enableCanvas, null, chart.themeStyle.axisTitleFont);\n element.setAttribute('aria-hidden', 'true');\n }\n };\n /**\n * xAxis grid line calculation performed here\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawXAxisGridLine = function (axis, index, parent, rect) {\n var isLogAxis = axis.valueType === 'Logarithmic';\n var isCategoryAxis = axis.valueType.indexOf('Category') > -1;\n var tempInterval;\n var pointX = 0;\n var majorGrid = '';\n var majorTick = '';\n var minorDirection;\n var isOpposed = axis.isAxisOpposedPosition;\n var tickSize = (isOpposed) ? -axis.majorTickLines.height : axis.majorTickLines.height;\n var axisLineSize = (isOpposed) ? -axis.lineStyle.width * 0.5 : axis.lineStyle.width * 0.5;\n var scrollBarHeight = isNullOrUndefined(axis.crossesAt) ? isOpposed ? -axis.scrollBarHeight :\n axis.scrollBarHeight : 0;\n var ticksbwtLabel = (axis.valueType.indexOf('Category') > -1 && axis.labelPlacement === 'BetweenTicks' && !this.chart.stockChart) ?\n 0.5 : 0;\n var length = axis.visibleLabels.length;\n var isTickInside = axis.tickPosition === 'Inside';\n var ticks = isTickInside ? (rect.y - tickSize - axisLineSize) : (rect.y + tickSize + axisLineSize + scrollBarHeight);\n var chartThemeStyle = this.chart.themeStyle;\n if (axis.valueType.indexOf('Category') > -1 && length > 0 && axis.labelPlacement === 'BetweenTicks' && !this.chart.stockChart) {\n length += 1;\n }\n //Gridlines\n for (var i = 0; i < length; i++) {\n if (axis.valueType !== 'DateTimeCategory') {\n tempInterval = axis.visibleLabels[i] ? axis.visibleLabels[i].value - ticksbwtLabel\n : (axis.visibleLabels[i - 1].value + axis.visibleRange.interval) - ticksbwtLabel;\n }\n else {\n tempInterval = axis.visibleLabels[i] ?\n axis.visibleLabels[i].value - ticksbwtLabel : axis.visibleRange.max;\n }\n pointX = (valueToCoefficient(tempInterval, axis) * rect.width) + rect.x;\n if (pointX >= rect.x && (rect.x + rect.width) >= pointX) {\n if (inside(tempInterval, axis.visibleRange) || this.isBorder(axis, i, pointX)) {\n majorGrid = 'M ' + pointX + ' ' + (this.seriesClipRect.y + this.seriesClipRect.height) +\n ' L ' + pointX + ' ' + this.seriesClipRect.y;\n this.renderGridLine(axis, index, majorGrid, axis.majorGridLines, '_MajorGridLine_', i, this.element, chartThemeStyle.majorGridLine, axis.majorGridLines.dashArray);\n }\n majorTick = 'M ' + (pointX) + ' ' + (rect.y + axisLineSize + (isTickInside ? scrollBarHeight : 0))\n + ' L ' + (pointX) + ' ' + ticks;\n this.renderGridLine(axis, index, majorTick, axis.majorTickLines, '_MajorTickLine_', i, parent, chartThemeStyle.majorTickLine);\n if (axis.minorTicksPerInterval > 0 && (axis.minorGridLines.width > 0 || axis.minorTickLines.width > 0)) {\n if (i === 0 && isZoomSet(axis) && !isLogAxis && !isCategoryAxis) {\n this.renderMinorGridOnZooming(axis, tempInterval, rect, i, index, chartThemeStyle, parent);\n }\n minorDirection = this.drawAxisMinorLine(axis, tempInterval, rect, i);\n this.renderGridLine(axis, index, minorDirection[0], axis.minorGridLines, '_MinorGridLine_', i, this.element, chartThemeStyle.minorGridLine, axis.minorGridLines.dashArray);\n this.renderGridLine(axis, index, minorDirection[1], axis.minorTickLines, '_MinorTickLine_', i, parent, chartThemeStyle.minorTickLine);\n if (i === length - 1 && isZoomSet(axis) && isLogAxis && !isCategoryAxis) {\n this.renderMinorGridOnZooming(axis, (tempInterval + axis.visibleRange.interval), rect, i, index, chartThemeStyle, parent);\n }\n }\n }\n }\n };\n /**\n * To render missing minor grid lines while zooming\n *\n * @param {Axis} axis axis\n * @param {number} tempInterval tempInterval\n * @param {Rect} rect rect\n * @param {number} i i\n * @param {number} index index\n * @param {IThemeStyle} chartThemeStyle chartThemeStyle\n * @param {Element} parent parent\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.renderMinorGridOnZooming = function (axis, tempInterval, rect, i, index, chartThemeStyle, parent) {\n var minorDirection = this.drawAxisMinorLine(axis, tempInterval, rect, i, true);\n this.renderGridLine(axis, index, minorDirection[0], axis.minorGridLines, '_MinorGridLine_', -1, this.element, chartThemeStyle.minorGridLine, axis.minorGridLines.dashArray);\n this.renderGridLine(axis, index, minorDirection[1], axis.minorTickLines, '_MinorTickLine_', -1, parent, chartThemeStyle.minorTickLine);\n };\n /**\n * To calcualte the axis minor line\n *\n * @param {Axis} axis axis\n * @param {number} tempInterval tempInterval\n * @param {Rect} rect rect\n * @param {number} labelIndex labelIndex\n * @param {boolean} isFirstLabel isFirstLabel\n * @returns {string[]} axis minor line path\n */\n CartesianAxisLayoutPanel.prototype.drawAxisMinorLine = function (axis, tempInterval, rect, labelIndex, isFirstLabel) {\n var value = tempInterval;\n var coor = 0;\n var position = 0;\n var range = axis.visibleRange;\n var isTickInside = axis.tickPosition === 'Inside';\n var direction = [];\n var tickSize = axis.isAxisOpposedPosition ? -axis.minorTickLines.height : axis.minorTickLines.height;\n var logStart;\n var logEnd;\n var logInterval = 1;\n var logPosition = 1;\n var ticksX = isTickInside ? (rect.y - tickSize) : (rect.y + tickSize);\n var ticksY = isTickInside ? (rect.x + tickSize) : (rect.x - tickSize);\n var minorGird = '';\n var minorTick = '';\n var isInverse = axis.isAxisInverse;\n if (axis.valueType === 'Logarithmic') {\n logStart = Math.pow(axis.logBase, value - range.interval);\n logEnd = Math.pow(axis.logBase, value);\n logInterval = (logEnd - logStart) / (axis.minorTicksPerInterval + 1);\n logPosition = logStart + logInterval;\n }\n if (axis.orientation === 'Horizontal') {\n for (var j = 0; j < axis.minorTicksPerInterval; j++) {\n value = this.findLogNumeric(axis, logPosition, value, labelIndex, isFirstLabel);\n logPosition += logInterval;\n if (inside(value, range)) {\n position = ((value - range.min) / (range.max - range.min));\n position = Math.ceil((isInverse ? (1 - position) : position) * rect.width);\n coor = (Math.floor(position + rect.x));\n minorGird = minorGird.concat('M' + ' ' + coor + ' ' + (this.seriesClipRect.y)\n + 'L ' + coor + ' ' + (this.seriesClipRect.y + this.seriesClipRect.height));\n coor = (Math.floor(position + rect.x));\n minorTick = minorTick.concat('M' + ' ' + coor + ' ' + (rect.y)\n + 'L ' + coor + ' ' + (ticksX + axis.scrollBarHeight));\n }\n }\n }\n else {\n for (var j = 0; j < axis.minorTicksPerInterval; j++) {\n value = this.findLogNumeric(axis, logPosition, value, labelIndex, isFirstLabel);\n if (inside(value, range)) {\n position = ((value - range.min) / (range.max - range.min));\n position = Math.ceil(((isInverse ? (1 - position) : position)) * rect.height) * -1; // For inversed axis\n coor = (Math.floor(position + rect.y + rect.height));\n minorGird = minorGird.concat('M' + ' ' + (this.seriesClipRect.x) + ' ' + coor\n + 'L ' + (this.seriesClipRect.x + this.seriesClipRect.width) + ' ' + coor + ' ');\n coor = (Math.floor(position + rect.y + rect.height));\n minorTick = minorTick.concat('M' + ' ' + rect.x + ' ' + coor + 'L ' + (ticksY - axis.scrollBarHeight) +\n ' ' + coor + ' ');\n }\n logPosition += logInterval;\n }\n }\n direction.push(minorGird);\n direction.push(minorTick);\n return direction;\n };\n /**\n * To find the numeric value of the log\n *\n * @param {Axis} axis axis\n * @param {number} logPosition logPosition\n * @param {number} value value\n * @param {number} labelIndex labelIndex\n * @param {boolean} isFirstLabel isFirstLabel\n * @returns {number} value\n */\n CartesianAxisLayoutPanel.prototype.findLogNumeric = function (axis, logPosition, value, labelIndex, isFirstLabel) {\n var range = axis.visibleRange;\n var tempValue;\n if (axis.valueType === 'Logarithmic') {\n value = logBase(logPosition, axis.logBase);\n }\n else if (axis.valueType === 'DateTime') {\n tempValue = axis.dateTimeInterval / (axis.minorTicksPerInterval + 1);\n value = isFirstLabel ? (value - tempValue) : (value + tempValue);\n }\n else if (axis.valueType === 'DateTimeCategory') {\n var padding = axis.labelPlacement === 'BetweenTicks' ? 0.5 : 0;\n value += ((axis.visibleLabels[labelIndex + 1] ?\n axis.visibleLabels[labelIndex + 1].value - padding : axis.visibleRange.max) -\n (axis.visibleLabels[labelIndex] ?\n axis.visibleLabels[labelIndex].value - padding : axis.visibleRange.min)) /\n (axis.minorTicksPerInterval + 1);\n }\n else {\n tempValue = range.interval / (axis.minorTicksPerInterval + 1);\n value = isFirstLabel ? (value - tempValue) : (value + tempValue);\n }\n return value;\n };\n /**\n * To render the xAxis Labels\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n * @private\n */\n CartesianAxisLayoutPanel.prototype.drawXAxisLabels = function (axis, index, parent, rect) {\n var chart = this.chart;\n var pointX = 0;\n var pointY = 0;\n var labelSpace = axis.labelPadding;\n var labelHeight;\n var elementSize;\n var labelPadding;\n var anchor;\n var pixel = 10;\n var labelElement = chart.renderer.createGroup({ id: chart.element.id + 'AxisLabels' + index });\n var islabelInside = axis.labelPosition === 'Inside';\n var isOpposed = axis.isAxisOpposedPosition;\n var tickSpace = axis.labelPosition === axis.tickPosition ? axis.majorTickLines.height : 0;\n var padding = tickSpace + labelSpace + axis.lineStyle.width * 0.5;\n var angle = axis.angle % 360;\n var isHorizontalAngle = (angle === 0 || angle === -180 || angle === 180);\n var options;\n var labelWidth;\n var isInverse = axis.isAxisInverse;\n var isLeft;\n var previousEnd = isInverse ? (rect.x + rect.width) : rect.x;\n var width = 0;\n var length = axis.visibleLabels.length;\n var intervalLength;\n var label;\n var isAxisBreakLabel;\n var scrollBarHeight = axis.scrollbarSettings.enable || (!islabelInside && isNullOrUndefined(axis.crossesAt)\n && (axis.zoomFactor < 1 || axis.zoomPosition > 0)) ? axis.scrollBarHeight : 0;\n var newPoints = [];\n var isRotatedLabelIntersect = false;\n var textPoints = [];\n var rotatedLabelSize = new Size(0, 0);\n padding += (angle === 90 || angle === 270 || angle === -90 || angle === -270) ? (islabelInside ? 5 : -5) : 0;\n var isLabelUnderAxisLine = ((!isOpposed && !islabelInside) || (isOpposed && islabelInside));\n var isEndAnchor = isLabelUnderAxisLine ?\n ((360 >= angle && angle >= 180) || (-1 >= angle && angle >= -180)) :\n ((1 <= angle && angle <= 180) || (-181 >= angle && angle >= -360));\n for (var i = 0, len = length; i < len; i++) {\n label = axis.visibleLabels[i];\n isAxisBreakLabel = isBreakLabel(label.originalText) || (axis.labelIntersectAction === 'Wrap' && label.text.length > 1);\n pointX = (valueToCoefficient(label.value, axis) * rect.width) + rect.x;\n elementSize = label.size;\n intervalLength = rect.width / length;\n labelWidth = isAxisBreakLabel ? label.breakLabelSize.width : elementSize.width;\n width = ((axis.labelIntersectAction === 'Trim' || axis.labelIntersectAction === 'Wrap') && angle === 0 &&\n labelWidth > intervalLength) ? intervalLength : labelWidth;\n labelHeight = elementSize.height / 4;\n pointX -= (isAxisBreakLabel || angle !== 0) ? 0 : (width / 2);\n // label X value adjustment for label rotation (Start)\n if (angle !== 0) {\n if (isAxisBreakLabel) {\n pointX -= axis.lineBreakAlignment === 'Left' ? (label.breakLabelSize.width / 2) : axis.lineBreakAlignment === 'Right' ?\n -(label.breakLabelSize.width / 2) : 0;\n }\n else {\n pointX -= (angle === -90 || angle === 270 ? -labelHeight : (angle === 90 || angle === -270) ? labelHeight : 0);\n }\n }\n // label X value adjustment for label rotation (End)\n if (axis.labelStyle.textAlignment === 'Far') {\n pointX = pointX + width - pixel;\n }\n else if (axis.labelStyle.textAlignment === 'Near') {\n pointX = pointX - width + pixel;\n }\n else if (axis.labelStyle.textAlignment === 'Center') {\n // eslint-disable-next-line no-self-assign\n pointX = pointX;\n }\n // For line break label alignment like left, right & center in angle 0\n if (isAxisBreakLabel && axis.lineBreakAlignment !== 'Center' && angle === 0) {\n pointX += axis.lineBreakAlignment === 'Left' ? -(width / 2) : (width / 2);\n }\n var paddingForBreakLabel = isAxisBreakLabel ?\n (isHorizontalAngle ? (axis.opposedPosition || islabelInside ? 0 : elementSize.height) : (label.breakLabelSize.width / 2)) : 0;\n padding = isAxisBreakLabel ? (tickSpace + labelSpace + axis.lineStyle.width * 0.5) : padding;\n // label Y value adjustment (Start)\n if (islabelInside && angle) {\n if (isAxisBreakLabel) {\n pointY = isOpposed ? (rect.y + padding + (paddingForBreakLabel)) : (rect.y - padding - (paddingForBreakLabel));\n }\n else {\n pointY = isOpposed ? (rect.y + padding + labelHeight) : (rect.y - padding - labelHeight);\n }\n }\n else {\n if (isAxisBreakLabel) {\n labelPadding = !isLabelUnderAxisLine ? -(padding + scrollBarHeight + (paddingForBreakLabel)) :\n padding + scrollBarHeight + (angle ? paddingForBreakLabel : (3 * labelHeight));\n }\n else {\n labelPadding = !isLabelUnderAxisLine ?\n -(padding + scrollBarHeight + (angle ? labelHeight : (label.index > 1 ? (2 * labelHeight) : 0))) :\n padding + scrollBarHeight + ((angle ? 1 : 3) * labelHeight);\n }\n pointY = (rect.y + (labelPadding * label.index));\n }\n // label Y value adjustment (End)\n if (isAxisBreakLabel) {\n anchor = this.getAnchor(axis); // for break label self alignment\n }\n else {\n anchor = (chart.enableRtl) ? ((isEndAnchor) ? '' : 'end') : (chart.isRtlEnabled || isEndAnchor) ? 'end' : '';\n }\n options = new TextOption(chart.element.id + index + '_AxisLabel_' + i, pointX, pointY, anchor);\n if (angle !== 0) {\n rotatedLabelSize = rotateTextSize(label.labelStyle, label.originalText, angle, chart);\n isLeft = ((angle < 0 && angle > -90) || (angle < -180 && angle > -270) || (angle > 90 && angle < 180) || (angle > 270 && angle < 360));\n }\n if (axis.edgeLabelPlacement) {\n switch (axis.edgeLabelPlacement) {\n case 'None':\n break;\n case 'Hide':\n if (((i === 0 || (isInverse && i === len - 1)) && options.x < rect.x) ||\n ((i === len - 1 || (isInverse && i === 0)) && (options.x + (angle === 0 ? width : rotatedLabelSize.width) > rect.x + rect.width))) {\n continue;\n }\n break;\n case 'Shift':\n if ((i === 0 || (isInverse && i === len - 1)) && (options.x < rect.x || (angle !== 0 && isLeft && options.x - rotatedLabelSize.width <= rect.x) || (axis.lineBreakAlignment === 'Center' && options.x - (label.size.width / label.text.length) / 2 < rect.x && angle === 0))) {\n intervalLength -= (rect.x - options.x);\n if (anchor === '' && !isInverse && angle === 0) {\n if (options.x <= 0) {\n pointX = options.x = 0;\n }\n else {\n pointX = options.x;\n }\n intervalLength = rect.width / length;\n }\n else if (isLeft && angle !== 0) {\n intervalLength = rect.width / length;\n if (intervalLength > rect.x + rotatedLabelSize.width) {\n options.x = pointX = rect.x + rotatedLabelSize.width;\n }\n else {\n options.x = pointX = rect.x + intervalLength - padding;\n }\n }\n else if (isAxisBreakLabel && axis.lineBreakAlignment === 'Center' && axis.labelPlacement === 'OnTicks' && angle === 0) {\n var maxWidth = 0;\n for (var i_1 = 0; i_1 < label.text.length; i_1++) {\n var breakLabelWidth = measureText(label.text[i_1], axis.labelStyle, chart.themeStyle.axisLabelFont).width;\n if (breakLabelWidth > maxWidth) {\n maxWidth = breakLabelWidth;\n }\n }\n options.x = pointX = rect.x + maxWidth / 2;\n }\n else if (!(anchor === 'start' && options.x > 0)) {\n options.x = pointX = !isHorizontalAngle ? rect.x + padding : rect.x;\n }\n }\n else if ((i === len - 1 || (isInverse && i === 0)) && (((options.x + width) > rect.x + rect.width && anchor !== 'end' && angle === 0) || (angle !== 0 && !isLeft && (options.x + rotatedLabelSize.width) > rect.x + rect.width) || (anchor === 'end' && options.x > rect.x + rect.width))) {\n if (elementSize.width > intervalLength && axis.labelIntersectAction === 'Trim' && angle === 0) {\n intervalLength -= (options.x + width - (rect.x + rect.width));\n }\n else if (angle !== 0) {\n if (rotatedLabelSize.width < intervalLength) {\n intervalLength = rotatedLabelSize.width;\n }\n }\n else {\n intervalLength = width;\n }\n if (angle !== 0) {\n options.x = pointX = rect.x + rect.width - intervalLength + padding;\n }\n else {\n options.x = pointX = !isHorizontalAngle ? rect.x + rect.width - intervalLength / 2 : rect.x + rect.width - intervalLength;\n }\n }\n break;\n }\n }\n options.text = this.getLabelText(label, axis, intervalLength);\n options.labelRotation = angle;\n // ------- Hide Calculation (Start) -------------\n // Currect label actual start value (Start)\n var xValue = void 0;\n var xValue2 = void 0;\n if (isAxisBreakLabel && angle === 0) {\n if (axis.lineBreakAlignment === 'Right') {\n xValue = (options.x - width);\n xValue2 = options.x;\n }\n else if (axis.lineBreakAlignment === 'Center') {\n xValue = (options.x - (width / 2));\n xValue2 = options.x + (width / 2);\n }\n else {\n xValue = options.x;\n xValue2 = options.x + width;\n }\n }\n else {\n xValue = options.x;\n xValue2 = options.x + width;\n }\n // Currect label actual start value (End)\n if (angle === 0 && axis.labelIntersectAction === 'Hide' && i !== 0 &&\n (!isInverse ? xValue <= previousEnd : xValue2 >= previousEnd)) {\n continue;\n }\n // Previous label actual end value (Start)\n if (isAxisBreakLabel) {\n if (axis.lineBreakAlignment === 'Right') {\n previousEnd = isInverse ? (options.x - width) : options.x;\n }\n else if (axis.lineBreakAlignment === 'Center') {\n previousEnd = isInverse ? (options.x - (width / 2)) : options.x + (width / 2);\n }\n else {\n previousEnd = isInverse ? options.x : options.x + width;\n }\n }\n else {\n previousEnd = isInverse ? options.x : options.x + width;\n }\n // Previous label actual end value (End)\n // ------- Hide Calculation (End) -------------\n // label Rotataion calculation (Start)\n if (angle !== 0) {\n var height = void 0;\n var rect_1 = void 0;\n if (isAxisBreakLabel) {\n var xAdjustment = 0;\n var yAdjustment = 0;\n height = (label.breakLabelSize.height);\n yAdjustment = (label.breakLabelSize.height) - 4; // 4 for label bound correction\n // xAdjustment (Start)\n if (axis.lineBreakAlignment === 'Center') {\n xAdjustment = -(label.breakLabelSize.width / 2);\n }\n else if (axis.lineBreakAlignment === 'Right') {\n xAdjustment = -label.breakLabelSize.width;\n }\n // xAdjustment (End)\n if (isLabelUnderAxisLine) {\n yAdjustment = (label.breakLabelSize.height) / (options.text.length + 1);\n }\n rect_1 = new Rect(options.x + xAdjustment, options.y - (yAdjustment), label.breakLabelSize.width, height);\n }\n else {\n height = (pointY) - (options.y - ((label.size.height / 2)));\n rect_1 = new Rect(options.x, options.y - ((label.size.height / 2) - 5), label.size.width, height);\n }\n var rectCoordinates = this.getRectanglePoints(rect_1);\n var rectCenterX = isAxisBreakLabel ? rect_1.x + (rect_1.width / 2) : pointX;\n var rectCenterY = isAxisBreakLabel ? rect_1.y + (rect_1.height / 2) : (pointY - (height / 2));\n if (isAxisBreakLabel) {\n options.transform = 'rotate(' + angle + ',' + rectCenterX + ',' + rectCenterY + ')';\n }\n else {\n options.transform = 'rotate(' + angle + ',' + pointX + ',' + pointY + ')';\n }\n newPoints.push(getRotatedRectangleCoordinates(rectCoordinates, rectCenterX, rectCenterY, angle));\n isRotatedLabelIntersect = false;\n if (axis.labelIntersectAction !== 'None') {\n for (var index_1 = i; index_1 > 0; index_1--) {\n if (newPoints[i] && newPoints[index_1 - 1] && isRotatedRectIntersect(newPoints[i], newPoints[index_1 - 1])) {\n isRotatedLabelIntersect = true;\n newPoints[i] = null;\n break;\n }\n }\n }\n var rotateAngle = ((angle > 0 && angle < 90) || (angle > 180 && angle < 270) || (angle < -90 && angle > -180) || (angle < -270 && angle > -360));\n var textRect = new Rect(options.x, options.y - (elementSize.height / 2 + padding / 2), label.size.width, height);\n var textRectCoordinates = this.getRectanglePoints(textRect);\n var rectPoints = [];\n rectPoints.push(new ChartLocation(rotateAngle ? this.chart.availableSize.width : this.padding, axis.rect.y));\n rectPoints.push(new ChartLocation(rotateAngle ? this.chart.availableSize.width : this.padding, axis.rect.y + axis.maxLabelSize.height));\n textPoints.push(getRotatedRectangleCoordinates(textRectCoordinates, rectCenterX, rectCenterY, angle));\n var newRect = new Rect(0, axis.rect.y, this.chart.availableSize.width, axis.maxLabelSize.height * 2);\n for (var k = 0; k < textPoints[i].length; k++) {\n if (!axis.opposedPosition && !withInBounds(textPoints[i][k].x, textPoints[i][k].y, newRect) && typeof options.text === 'string') {\n var interSectPoint = this.calculateIntersection(textPoints[i][0], textPoints[i][1], rectPoints[0], rectPoints[1]);\n var rectPoint1 = rotateAngle ? this.chart.availableSize.width - pointX : pointX;\n var rectPoint2 = interSectPoint.y - axis.rect.y;\n var trimValue = Math.sqrt((rectPoint1 * rectPoint1) + (rectPoint2 * rectPoint2));\n options.text = textTrim(trimValue, label.text, label.labelStyle, chart.enableRtl, chart.themeStyle.axisLabelFont);\n }\n }\n }\n // label Rotataion calculation (End)\n textElement(chart.renderer, options, label.labelStyle, label.labelStyle.color || chart.themeStyle.axisLabelFont.color, labelElement, (axis.isAxisOpposedPosition !== (axis.labelPosition === 'Inside')), chart.redraw, true, null, null, null, label.size, isRotatedLabelIntersect, chart.enableCanvas, null, chart.themeStyle.axisLabelFont);\n }\n if (!this.chart.enableCanvas) {\n if (!chart.delayRedraw) {\n parent.appendChild(labelElement);\n }\n else if (axis.visible && axis.internalVisibility) {\n this.createZoomingLabel(this.chart, labelElement, axis, index, rect);\n }\n }\n };\n CartesianAxisLayoutPanel.prototype.calculateIntersection = function (p1, p2, p3, p4) {\n var c2x = p3.x - p4.x;\n var c3x = p1.x - p2.x;\n var c2y = p3.y - p4.y;\n var c3y = p1.y - p2.y;\n var d = c3x * c2y - c3y * c2x;\n var u1 = p1.x * p2.y - p1.y * p2.x;\n var u4 = p3.x * p4.y - p3.y * p4.x;\n var px = (u1 * c2x - c3x * u4) / d;\n var py = (u1 * c2y - c3y * u4) / d;\n var p = { x: px, y: py };\n return p;\n };\n /**\n * To get text anchor value for line break labels.\n *\n * @param {Axis} axis axis model\n * @returns {string} returns text anchor\n */\n CartesianAxisLayoutPanel.prototype.getAnchor = function (axis) {\n return (axis.lineBreakAlignment === 'Center' ? 'middle' : (this.chart.enableRtl) ? (axis.lineBreakAlignment === 'Left' ? 'end' : 'start') : (axis.lineBreakAlignment === 'Left' ? 'start' : 'end'));\n };\n /**\n * Get rect coordinates\n *\n * @param {Rect} rect rect\n * @returns {ChartLocation[]} rectangle points\n */\n CartesianAxisLayoutPanel.prototype.getRectanglePoints = function (rect) {\n var point1 = new ChartLocation(rect.x, rect.y);\n var point2 = new ChartLocation(rect.x + rect.width, rect.y);\n var point3 = new ChartLocation(rect.x + rect.width, rect.y + rect.height);\n var point4 = new ChartLocation(rect.x, rect.y + rect.height);\n return [point1, point2, point3, point4];\n };\n /**\n * To get axis label text\n *\n * @param {VisibleLabels} label label\n * @param {Axis} axis axis\n * @param {number} intervalLength intervalLength\n * @returns {string | string[]} label or label collection\n */\n CartesianAxisLayoutPanel.prototype.getLabelText = function (label, axis, intervalLength) {\n if (isBreakLabel(label.originalText)) {\n var result = [];\n var str = void 0;\n for (var index = 0; index < label.text.length; index++) {\n str = this.findAxisLabel(axis, label.text[index], intervalLength);\n result.push(str);\n }\n return result;\n }\n else {\n return this.findAxisLabel(axis, label.text, intervalLength);\n }\n };\n /**\n * To render the x-axis label border.\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} axisRect axisRect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawXAxisBorder = function (axis, index, parent, axisRect) {\n if (axis.border.width > 0) {\n var scrollBarHeight = axis.labelPosition === 'Outside' ? axis.scrollBarHeight : 0;\n var isOpposed = axis.isAxisOpposedPosition;\n var startX = void 0;\n var startY = axisRect.y + ((isOpposed ? -1 : 1) * scrollBarHeight);\n var padding = 10;\n var pointX = void 0;\n var gap = (axisRect.width / axis.visibleRange.delta) * (axis.valueType === 'DateTime' ? axis.dateTimeInterval\n : axis.visibleRange.interval);\n var endX = void 0;\n var length_2 = axis.maxLabelSize.height +\n ((axis.tickPosition === axis.labelPosition) ? axis.majorTickLines.height : 0);\n var labelBorder = '';\n var ticksbwtLabel = (axis.valueType === 'Category' && axis.labelPlacement === 'BetweenTicks') ? -0.5 : 0;\n var endY = ((isOpposed && axis.labelPosition === 'Inside') ||\n (!isOpposed && axis.labelPosition === 'Outside')) ?\n (axisRect.y + length_2 + padding + scrollBarHeight) : (axisRect.y - length_2 - padding - scrollBarHeight);\n for (var i = 0, len = axis.visibleLabels.length; i < len; i++) {\n pointX = valueToCoefficient(axis.visibleLabels[i].value + ticksbwtLabel, axis);\n pointX = (axis.isAxisInverse ? (1 - pointX) : pointX) * axisRect.width;\n if (axis.valueType === 'Category' && axis.labelPlacement === 'BetweenTicks') {\n startX = pointX + axisRect.x;\n endX = pointX + (gap) + axisRect.x;\n }\n else {\n startX = pointX - gap * 0.5 + axisRect.x;\n endX = pointX + gap * 0.5 + axisRect.x;\n }\n switch (axis.border.type) {\n case 'Rectangle':\n case 'WithoutTopBorder':\n if (startX < axisRect.x && axis.labelPlacement !== 'OnTicks') {\n labelBorder += ('M' + ' ' + axisRect.x + ' ' + endY + ' ' + 'L' + ' ' + endX + ' ' + endY + ' ');\n }\n else if (Math.floor(endX) > axisRect.width + axisRect.x && !(axis.visibleLabels.length === 1) && !(i === axis.visibleLabels.length - 1)) {\n labelBorder += ('M' + ' ' + startX + ' ' + startY + ' ' + 'L' + ' ' + startX + ' ' + endY + ' ' +\n 'L' + ' ' + (axisRect.width + axisRect.x) + ' ' + endY + ' ');\n }\n else {\n startX = (i === 0 && axis.labelPlacement === 'OnTicks') ? axisRect.x : startX;\n endX = ((i === axis.visibleLabels.length - 1) && axis.labelPlacement === 'OnTicks') ? endX - gap * 0.5 : endX;\n labelBorder += ('M' + ' ' + startX + ' ' + startY + ' ' + 'L' + ' ' + startX + ' ' +\n endY + ' ' + 'L' + ' ' + endX + ' ' + endY + ' ');\n if (i === 0) {\n labelBorder += ('M' + ' ' + startX + ' ' + startY + ' ' + 'L' + ' ' + startX + ' ' + endY + ' ' +\n 'M ' + startX + ' ' + endY + ' L ' + (axisRect.x) + ' ' + endY);\n }\n if (i === axis.visibleLabels.length - 1) {\n labelBorder += ('M' + ' ' + endX + ' ' + startY + ' ' + 'L' + ' ' + endX + ' ' + endY + ' ' +\n 'M ' + endX + ' ' + endY + ' L ' + (axisRect.width + axisRect.x) + ' ' + endY);\n }\n }\n break;\n case 'WithoutTopandBottomBorder':\n if (!(startX < axisRect.x) && !(Math.floor(endX) > axisRect.width + axisRect.x)) {\n labelBorder += ('M' + ' ' + startX + ' ' + startY + ' ' + 'L' + ' ' + startX + ' ' + endY + ' ' +\n 'M ' + endX + ' ' + startY + ' L ' + endX + ' ' + endY);\n }\n break;\n }\n }\n labelBorder += (axis.border.type === 'Rectangle' ? ('M ' + ' ' + axisRect.x + ' ' + startY + 'L' + ' ' +\n (axisRect.x + axisRect.width) + ' ' + startY) : '');\n if (labelBorder !== '') {\n this.createAxisBorderElement(axis, index, labelBorder, parent);\n }\n }\n for (var i = 0; i < this.chart.visibleSeries.length; i++) {\n if (this.chart.multiLevelLabelModule && axis.multiLevelLabels.length > 0 && this.chart.visibleSeries[i].visible) {\n this.chart.multiLevelLabelModule.renderXAxisMultiLevelLabels(axis, index, parent, axisRect);\n break;\n }\n }\n };\n /**\n * To create border element of the axis\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {string} labelBorder labelBorder\n * @param {Element} parent parent\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.createAxisBorderElement = function (axis, index, labelBorder, parent) {\n var element = getElement(this.chart.element.id + '_BorderLine_' + index);\n var direction = element ? element.getAttribute('d') : '';\n var borderElement = this.chart.renderer.drawPath(new PathOption(this.chart.element.id + '_BorderLine_' + index, 'transparent', axis.border.width, axis.border.color || this.chart.themeStyle.axisLine, 1, '', labelBorder));\n borderElement.style.pointerEvents = 'none';\n appendChildElement(this.chart.enableCanvas, parent, borderElement, this.chart.redraw, false, 'x', 'y', null, direction, true);\n };\n /**\n * To find the axis label of the intersect action\n *\n * @param {Axis} axis axis\n * @param {string} label label\n * @param {number} width width\n * @returns {string} label\n */\n CartesianAxisLayoutPanel.prototype.findAxisLabel = function (axis, label, width) {\n return (axis.labelIntersectAction === 'Trim' ?\n ((axis.angle % 360 === 0 && !axis.enableTrim) ? textTrim(width, label, axis.labelStyle, this.chart.enableRtl, this.chart.themeStyle.axisLabelFont) : label) : label);\n };\n /**\n * X-Axis Title function performed\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Element} parent parent\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.drawXAxisTitle = function (axis, index, parent, rect) {\n if (axis.title) {\n var chart = this.chart;\n var elementSize = measureText(axis.title, axis.titleStyle, this.chart.themeStyle.axisTitleFont);\n var scrollBarHeight = isNullOrUndefined(axis.crossesAt) ? axis.scrollBarHeight : 0;\n var padding = (axis.tickPosition === 'Inside' ? 0 : axis.majorTickLines.height + axis.titlePadding) +\n (axis.labelPosition === 'Inside' ? 0 :\n axis.maxLabelSize.height + axis.multiLevelLabelHeight + axis.labelPadding);\n var titleSize = (axis.titleSize.height * (axis.titleCollection.length - 1));\n padding = axis.isAxisOpposedPosition ? -(padding + elementSize.height / 4 + scrollBarHeight + titleSize) : (padding + (3 *\n elementSize.height / 4) + scrollBarHeight);\n var labelRotation = axis.titleRotation ? axis.titleRotation : 0;\n var x = void 0;\n var y = rect.y + padding;\n var anchor = void 0;\n if (axis.titleStyle.textAlignment === 'Center') {\n anchor = 'middle';\n x = rect.x + rect.width * 0.5;\n }\n else if (axis.titleStyle.textAlignment === 'Near') {\n anchor = 'start';\n x = rect.x;\n }\n else {\n anchor = 'end';\n x = rect.x + rect.width;\n }\n if (labelRotation !== 0) {\n y += axis.opposedPosition ? -(axis.titleSize.height / 2 + elementSize.height / 4) :\n axis.titleSize.height / 2 - elementSize.height / 4;\n }\n var options = new TextOption(chart.element.id + '_AxisTitle_' + index, x, y, anchor, axis.titleCollection, 'rotate(' + labelRotation + ',' + (x) + ',' + (y) + ')', null, labelRotation);\n var element = textElement(chart.renderer, options, axis.titleStyle, axis.titleStyle.color || chart.themeStyle.axisTitleFont.color, parent, null, null, null, null, null, null, null, null, chart.enableCanvas, null, chart.themeStyle.axisTitleFont);\n element.setAttribute('aria-hidden', 'true');\n }\n };\n /**\n * To render the axis grid and tick lines(Both Major and Minor)\n *\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {string} gridDirection gridDirection\n * @param {MajorTickLinesModel | MinorTickLinesModel | MajorGridLinesModel | MinorGridLinesModel} gridModel gridModel\n * @param {string} gridId gridId\n * @param {number} gridIndex gridIndex\n * @param {Element} parent parent\n * @param {string} themeColor themeColor\n * @param {string} dashArray dashArray\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.renderGridLine = function (axis, index, gridDirection, gridModel, gridId, gridIndex, parent, themeColor, dashArray) {\n if (dashArray === void 0) { dashArray = null; }\n var chart = this.chart;\n var direction;\n var element;\n if (gridModel.width > 0 && axis.visible && axis.internalVisibility && gridDirection) {\n element = getElement(chart.element.id + gridId + index + '_' + gridIndex);\n direction = element ? element.getAttribute('d') : null;\n element = null;\n this.htmlObject = chart.renderer.drawPath(new PathOption(chart.element.id + gridId + index + '_' + gridIndex, 'transparent', gridModel.width, gridModel.color || themeColor, null, dashArray, gridDirection));\n appendChildElement(chart.enableCanvas, parent, this.htmlObject, chart.redraw, true, 'x', 'y', null, direction, true);\n }\n };\n /**\n * To Find the parent node of the axis\n *\n * @param {string} elementId elementId\n * @param {Element} label label\n * @param {number} index index\n * @returns {Element} parent node of the axis\n */\n CartesianAxisLayoutPanel.prototype.findParentNode = function (elementId, label, index) {\n if (document.getElementById(elementId + 'AxisGroup' + index + 'Inside').contains(document.getElementById(label.id))) {\n return document.getElementById(elementId + 'AxisGroup' + index + 'Inside');\n }\n else {\n return document.getElementById(elementId + 'AxisGroup' + index + 'Outside');\n }\n };\n /**\n * Create Zooming Labels Function Called here\n *\n * @param {Chart} chart chart\n * @param {Element} labelElement labelElement\n * @param {Axis} axis axis\n * @param {number} index index\n * @param {Rect} rect rect\n * @returns {void}\n */\n CartesianAxisLayoutPanel.prototype.createZoomingLabel = function (chart, labelElement, axis, index, rect) {\n var parentNode = this.findParentNode(chart.element.id, labelElement, index);\n labelElement.setAttribute('opacity', '0.3');\n var zoomElement = chart.renderer.createGroup({\n id: chart.element.id + 'AxisLabels_Zoom' + index\n });\n zoomElement = createZoomingLabels(chart, axis, zoomElement, index, axis.orientation === 'Vertical', rect);\n parentNode.replaceChild(labelElement, document.getElementById(labelElement.id));\n if (getElement(chart.element.id + 'AxisLabels_Zoom' + index)) {\n parentNode.replaceChild(zoomElement, document.getElementById(zoomElement.id));\n }\n else {\n parentNode.appendChild(zoomElement);\n }\n };\n return CartesianAxisLayoutPanel;\n}());\nexport { CartesianAxisLayoutPanel };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable jsdoc/check-param-names */\n/* eslint-disable jsdoc/require-param-type */\n/* eslint-disable jsdoc/require-param */\n/* eslint-disable jsdoc/require-param-description */\n/* eslint-disable valid-jsdoc */\nimport { drawSymbol } from '../../common/utils/helper';\nimport { PathOption, Size } from '@syncfusion/ej2-svg-base';\nimport { Browser, extend, remove, isNullOrUndefined, Animation } from '@syncfusion/ej2-base';\nimport { ChartData } from '../../chart/utils/get-data';\nimport { withInBounds, PointData, stopTimer } from '../../common/utils/helper';\nimport { colorNameToHex, convertHexToColor } from '../../common/utils/helper';\n/**\n * Marker Module used to render the marker for line type series.\n */\nvar MarkerExplode = /** @class */ (function (_super) {\n __extends(MarkerExplode, _super);\n /**\n * Constructor for the marker module.\n *\n * @private\n */\n function MarkerExplode(chart) {\n var _this = _super.call(this, chart) || this;\n _this.elementId = chart.element.id;\n _this.commonXvalues = [];\n return _this;\n }\n /**\n * @hidden\n */\n MarkerExplode.prototype.addEventListener = function () {\n if (this.chart.isDestroyed) {\n return;\n }\n this.chart.on(Browser.touchMoveEvent, this.mouseMoveHandler, this);\n this.chart.on(Browser.touchEndEvent, this.mouseUpHandler, this);\n };\n /**\n * @hidden\n */\n MarkerExplode.prototype.removeEventListener = function () {\n if (this.chart.isDestroyed) {\n return;\n }\n this.chart.off(Browser.touchMoveEvent, this.mouseMoveHandler);\n this.chart.off(Browser.touchEndEvent, this.mouseUpHandler);\n };\n /**\n * @hidden\n */\n MarkerExplode.prototype.mouseUpHandler = function () {\n var chart = this.chart;\n if (chart.isTouch && !chart.crosshair.enable && !this.isSelected(chart)) {\n this.markerMove(true);\n }\n };\n /**\n * @hidden\n */\n MarkerExplode.prototype.mouseMoveHandler = function () {\n var chart = this.chart;\n if ((chart.highlightMode !== 'None' || (chart.tooltip.enable)) && (!chart.isTouch || chart.startMove) && !this.isSelected(chart)) {\n this.markerMove(false);\n }\n };\n MarkerExplode.prototype.markerMove = function (remove) {\n var _this = this;\n var chart = this.chart;\n this.currentPoints = [];\n var data;\n var previous;\n var explodeSeries;\n var series;\n if (!chart.tooltip.shared || !chart.tooltip.enable) {\n data = this.getData();\n series = data.series;\n previous = this.previousPoints[0];\n explodeSeries = series && ((series.type === 'Bubble' || series.drawType === 'Scatter' || series.type === 'Scatter') ||\n (((series.type !== 'Candle') && (series.type !== 'Hilo') && (series.type !== 'HiloOpenClose')) &&\n (series.marker.visible && series.marker.width !== 0 && series.marker.height !== 0)));\n data.lierIndex = this.lierIndex;\n if (data.point && explodeSeries && ((!previous || (previous.point !== data.point)) ||\n (previous && previous.lierIndex > 3 && previous.lierIndex !== this.lierIndex))) {\n this.currentPoints.push(data);\n }\n if (data.point && explodeSeries && chart.isPointMouseDown) {\n this.currentPoints.push(data);\n }\n }\n else {\n if (!withInBounds(chart.mouseX, chart.mouseY, chart.chartAxisLayoutPanel.seriesClipRect)) {\n return null;\n }\n if (chart.tooltip.enable) {\n var pointData = chart.chartAreaType === 'PolarRadar' ? this.getData() : null;\n if (!this.chart.tooltip.showNearestPoint) {\n this.currentPoints = this.chart.tooltipModule.currentPoints;\n }\n else {\n for (var _i = 0, _a = chart.visibleSeries; _i < _a.length; _i++) {\n var chartSeries = _a[_i];\n if (!chartSeries.enableTooltip || chartSeries.category === 'Indicator') {\n continue;\n }\n if (chart.chartAreaType === 'Cartesian' && chartSeries.visible) {\n data = this.getClosestX(chart, chartSeries, this.commonXValue(this.chart.visibleSeries));\n }\n else if (chart.chartAreaType === 'PolarRadar' && chartSeries.visible && pointData.point !== null) {\n data = new PointData(chartSeries.points[pointData.point.index], chartSeries);\n }\n if (data) {\n this.currentPoints.push(data);\n data = null;\n }\n }\n }\n }\n }\n var length = this.previousPoints.length;\n if (this.currentPoints.length > 0 || (length > 0 && chart.tooltip.shared)) {\n if (length === 0 || chart.isPointMouseDown || (length > 0 && (this.currentPoints.length == 0 || (this.previousPoints[0].point !== this.currentPoints[0].point)))) {\n if (length > 0) {\n for (var _b = 0, _c = this.previousPoints; _b < _c.length; _b++) {\n var previousPoint = _c[_b];\n if (!isNullOrUndefined(previousPoint)) {\n this.removeHighlightedMarker(previousPoint.series, previousPoint.point);\n }\n }\n }\n var _loop_1 = function (data_1) {\n if ((data_1 && data_1.point) || ((series.type !== 'Candle') &&\n (series.type !== 'Hilo') && (series.type !== 'HiloOpenClose'))) {\n stopTimer(this_1.markerExplode);\n this_1.isRemove = true;\n data_1.point.symbolLocations.map(function (location, index) {\n if (data_1.series.marker.allowHighlight && (!data_1.series.isRectSeries || data_1.point.marker.visible)) {\n _this.drawTrackBall(data_1.series, data_1.point, location, index);\n }\n });\n }\n };\n var this_1 = this;\n for (var _d = 0, _e = this.currentPoints; _d < _e.length; _d++) {\n var data_1 = _e[_d];\n _loop_1(data_1);\n }\n this.previousPoints = extend([], this.currentPoints, null, true);\n }\n }\n if (!chart.tooltip.enable && ((this.currentPoints.length === 0 && this.isRemove) || (remove && this.isRemove) ||\n !withInBounds(chart.mouseX, chart.mouseY, chart.chartAxisLayoutPanel.seriesClipRect))) {\n this.isRemove = false;\n if (!isNullOrUndefined(this.previousPoints[0])) {\n this.markerExplode = +setTimeout(function () {\n if (_this.previousPoints[0]) {\n _this.removeHighlightedMarker(_this.previousPoints[0].series, _this.previousPoints[0].point);\n }\n }, 2000);\n }\n }\n this.currentPoints = [];\n };\n MarkerExplode.prototype.animationDuration = function () {\n var duration = 200;\n if (this.chart.maxPointCount > 100) {\n duration = 10;\n }\n else if (this.chart.maxPointCount > 50) {\n duration = 100;\n }\n return duration;\n };\n MarkerExplode.prototype.drawTrackBall = function (series, point, location, index) {\n var marker = point.marker;\n var seriesMarker = series.marker;\n var shape = marker.shape || seriesMarker.shape || 'Circle';\n var svg;\n if (shape === 'None' || shape === 'Image') {\n return null;\n }\n var element = series.symbolElement || series.seriesElement;\n var className;\n if (this.chart.highlightModule && this.chart.highlightMode !== 'None') {\n className = this.chart.highlightModule.generateStyle(series);\n }\n if (this.chart.selectionModule && this.chart.selectionMode !== 'None') {\n className = this.chart.selectionModule.generateStyle(series);\n }\n var symbolId = this.elementId + '_Series_' + series.index + '_Point_' + point.index + '_Trackball' +\n (index ? index : '');\n var size = new Size((marker.width || seriesMarker.width) + 3, (marker.height || seriesMarker.height) + 3);\n var border = (marker.border || series.border);\n var explodeSeries = (series.type === 'BoxAndWhisker' || series.type === 'Bubble' || series.type === 'Scatter');\n var borderColor = (border.color && border.color !== 'transparent') ? border.color :\n marker.fill || point.interior || (explodeSeries ? point.color : series.interior);\n var colorValue = convertHexToColor(colorNameToHex(borderColor));\n var borderWidth = marker.border ? marker.border.width : seriesMarker.border.width;\n var markerShadow = series.chart.themeStyle.markerShadow ||\n 'rgba(' + colorValue.r + ',' + colorValue.g + ',' + colorValue.b + ',0.2)';\n var markerElement = document.getElementById(this.elementId + '_Series_' + series.index + '_Point_' +\n point.index + '_Symbol');\n if (!isNullOrUndefined(markerElement)) {\n markerElement.setAttribute('visibility', 'hidden');\n }\n if (this.chart.enableCanvas) {\n var trackElement = document.getElementById(this.chart.element.id + '_Secondary_Element');\n svg = this.chart.svgRenderer.createSvg({\n id: this.chart.element.id + '_trackball_svg',\n width: this.chart.availableSize.width,\n height: this.chart.availableSize.height\n });\n svg.style.cssText = 'position: absolute; pointer-events: none';\n trackElement.appendChild(svg);\n }\n for (var i = 0; i < 2; i++) {\n var options = new PathOption(symbolId + '_' + i, i ? (marker.fill || point.color || (explodeSeries ? series.interior : '#ffffff')) : 'transparent', borderWidth + (i ? 0 : 8), i ? borderColor : markerShadow, (marker.opacity || seriesMarker.opacity), null, null);\n var symbol = drawSymbol(location, shape, size, marker.imageUrl, options, '', this.chart.svgRenderer, series.clipRect);\n // incident: 252450 point click selection not working while maker explode\n //symbol.setAttribute('style', 'pointer-events:none');\n symbol.setAttribute('class', this.elementId + '_EJ2-Trackball_Series_' + series.index + '_Point_' + point.index);\n var selectionId = element.id.indexOf('Symbol') !== -1 ? '_Symbol' : '';\n var seletionElem = document.getElementById(this.elementId + '_Series_' + series.index + '_Point_' +\n point.index + selectionId);\n if (className !== '' && !isNullOrUndefined(className) && !isNullOrUndefined(seletionElem) &&\n seletionElem.hasAttribute('class') && (className === seletionElem.getAttribute('class'))) {\n symbol.classList.add(className);\n }\n symbol.setAttribute('clip-path', element.getAttribute('clip-path'));\n symbol.setAttribute('transform', element.getAttribute('transform'));\n if (this.chart.enableCanvas) {\n svg.appendChild(symbol);\n }\n else {\n this.chart.svgObject.appendChild(symbol);\n }\n }\n this.doAnimation(series, point, false);\n };\n /**\n * Animates the series.\n *\n * @param {Series} series - Defines the series to animate.\n * @returns {void}\n */\n MarkerExplode.prototype.doAnimation = function (series, point, endAnimate) {\n if (endAnimate === void 0) { endAnimate = false; }\n var duration = this.animationDuration();\n var delay = series.animation.delay;\n var rectElements = document.getElementsByClassName(this.elementId + '_EJ2-Trackball_Series_' + series.index + '_Point_' + point.index);\n for (var i = 0, len = rectElements.length; i < len; i++) {\n this.trackballAnimate(rectElements[i], delay, duration, series, point.index, point.symbolLocations[0], false, endAnimate);\n }\n };\n /**\n * Animation Effect Calculation End\n *\n * @private\n */\n MarkerExplode.prototype.trackballAnimate = function (elements, delays, durations, series, pointIndex, point, isLabel, endAnimate) {\n var centerX = point.x;\n var centerY = point.y;\n var clipX = (series.type !== 'Polar' && series.type !== 'Radar') ? series.clipRect.x : 0;\n var clipY = (series.type !== 'Polar' && series.type !== 'Radar') ? series.clipRect.y : 0;\n var height = 0;\n //(<HTMLElement>elements).style.visibility = 'hidden';\n var reducedHeight = endAnimate ? -8 : 1;\n var transform = elements.getAttribute('transform');\n new Animation({}).animate(elements, {\n duration: durations,\n delay: delays,\n progress: function (args) {\n if (args.timeStamp > args.delay) {\n args.element.style.visibility = 'visible';\n height = ((args.timeStamp - args.delay) / args.duration);\n elements.setAttribute('transform', 'translate(' + (centerX + clipX)\n + ' ' + (centerY + clipY) + ') scale(1) translate(' + (-centerX) + ' ' + (-centerY) + ')');\n }\n },\n end: function () {\n elements.style.visibility = '';\n elements.setAttribute('transform', transform);\n if (!isLabel && (pointIndex === series.points.length - 1)) {\n series.chart.trigger('animationComplete', { series: series.chart.isBlazor ? {} : series });\n }\n if (endAnimate) {\n remove(elements);\n }\n }\n });\n };\n /**\n * @param series\n * @param point\n * @param fadeOut\n * @param series\n * @param point\n * @param fadeOut\n * @param series\n * @param point\n * @param fadeOut\n * @hidden\n */\n MarkerExplode.prototype.removeHighlightedMarker = function (series, point, fadeOut) {\n if (series === void 0) { series = null; }\n if (point === void 0) { point = null; }\n if (fadeOut === void 0) { fadeOut = false; }\n if (!isNullOrUndefined(series) && !isNullOrUndefined(point)) {\n var markerElement = document.getElementById(this.elementId + '_Series_' + series.index + '_Point_' +\n point.index + '_Symbol');\n var trackballElements = document.getElementsByClassName(this.elementId + '_EJ2-Trackball_Series_' + series.index + '_Point_' + point.index);\n for (var i = 0, len = trackballElements.length; i < len; i++) {\n remove(trackballElements[0]);\n }\n if (!isNullOrUndefined(markerElement)) {\n markerElement.setAttribute('visibility', 'visible');\n }\n }\n else {\n for (var _i = 0, _a = series.points; _i < _a.length; _i++) {\n var point_1 = _a[_i];\n var elements = document.getElementsByClassName(this.elementId + '_EJ2-Trackball_Series_' + series.index + '_Point_' + point_1.index);\n var markerElement = document.getElementById(this.elementId + '_Series_' + series.index + '_Point_' +\n point_1.index + '_Symbol');\n for (var i = 0, len = elements.length; i < len; i++) {\n if (!isNullOrUndefined(markerElement)) {\n markerElement.setAttribute('visibility', 'visible');\n }\n remove(elements[0]);\n }\n }\n }\n if (fadeOut) {\n this.previousPoints = [];\n }\n };\n return MarkerExplode;\n}(ChartData));\nexport { MarkerExplode };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { RectOption, appendChildElement, getElement, appendClipElement } from '../../common/utils/helper';\nimport { findlElement, drawSymbol, markerAnimate, CircleOption } from '../../common/utils/helper';\nimport { PathOption, Size } from '@syncfusion/ej2-svg-base';\nimport { animationMode, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { pointRender } from '../../common/model/constants';\nimport { MarkerExplode } from './marker-explode';\nimport { getSaturationColor } from '../../common/utils/helper';\nexport var markerShapes = [\"Circle\", \"Triangle\", \"Diamond\", \"Rectangle\", \"Pentagon\", \"InvertedTriangle\", \"VerticalLine\", \"Cross\", \"Plus\", \"HorizontalLine\"];\n/**\n * Marker module used to render the marker for line type series.\n */\nvar Marker = /** @class */ (function (_super) {\n __extends(Marker, _super);\n /**\n * Constructor for the marker module.\n *\n * @private\n */\n function Marker(chart) {\n var _this = _super.call(this, chart) || this;\n _this.addEventListener();\n return _this;\n }\n /**\n * Render the marker for series.\n *\n * @returns {void}\n * @private\n */\n Marker.prototype.render = function (series) {\n var _this = this;\n var redraw = series.chart.redraw;\n this.createElement(series, redraw);\n var _loop_1 = function (point) {\n if (point.visible && point.symbolLocations && point.symbolLocations.length) {\n point.symbolLocations.map(function (location, index) {\n if (series.marker.shape !== 'None') {\n _this.renderMarker(series, point, location, index, redraw);\n }\n });\n }\n };\n for (var _i = 0, _a = series.points; _i < _a.length; _i++) {\n var point = _a[_i];\n _loop_1(point);\n }\n };\n Marker.prototype.renderMarker = function (series, point, location, index, redraw) {\n var seriesIndex = series.index === undefined ? series.category : series.index;\n var marker = series.marker;\n series.marker.shape = series.marker.shape ? series.marker.shape : markerShapes[seriesIndex % 10];\n var border = {\n color: marker.border.color,\n width: marker.border.width\n };\n var borderColor = marker.border.color;\n var previousLocation;\n var previousPath;\n var circlePath;\n var shapeOption;\n location.x = location.x + marker.offset.x;\n location.y = location.y - marker.offset.y;\n var isBoxPlot = series.type === 'BoxAndWhisker';\n var fill = marker.fill || ((isBoxPlot || series.marker.isFilled) ? point.interior || series.interior : '#ffffff');\n var markerElement;\n var parentElement = isBoxPlot ?\n findlElement(series.seriesElement.childNodes, 'Series_' + series.index + '_Point_' + point.index)\n : series.symbolElement;\n border.color = borderColor || series.setPointColor(point, series.interior);\n var symbolId = this.elementId + '_Series_' + seriesIndex + '_Point_' + point.index + '_Symbol' +\n (index ? index : '');\n var argsData = {\n cancel: false, name: pointRender, series: series, point: point,\n fill: point.isEmpty ? (series.emptyPointSettings.fill || fill) : fill,\n border: {\n color: series.type === 'BoxAndWhisker' ?\n (!isNullOrUndefined(borderColor) && borderColor !== 'transparent') ? borderColor :\n getSaturationColor(fill, -0.6)\n : border.color,\n width: border.width\n },\n height: marker.height, width: marker.width, shape: marker.shape\n };\n argsData.border = series.setBorderColor(point, { width: argsData.border.width, color: argsData.border.color });\n if (!series.isRectSeries || series.type === 'BoxAndWhisker') {\n this.chart.trigger(pointRender, argsData);\n point.color = argsData.fill;\n }\n point.color = argsData.fill;\n if (!argsData.cancel) {\n var y = void 0;\n if (series.type === 'RangeArea' || series.type === 'RangeColumn' || series.drawType === 'RangeColumn'\n || series.type === 'SplineRangeArea' || series.type === 'RangeStepArea') {\n y = index ? point.low : point.high;\n }\n else if (isBoxPlot) {\n y = point.outliers[index];\n }\n else {\n y = point.y;\n }\n var markerFill = argsData.point.marker.fill || argsData.fill;\n var markerBorder = void 0;\n if (!isNullOrUndefined(argsData.point.marker.border)) {\n markerBorder = {\n color: argsData.point.marker.border.color || argsData.border.color,\n width: argsData.point.marker.border.width || argsData.border.width\n };\n }\n else {\n markerBorder = { color: argsData.border.color, width: argsData.border.width };\n }\n var markerWidth = argsData.point.marker.width || argsData.width;\n var markerHeight = argsData.point.marker.height || argsData.height;\n var markerOpacity = argsData.point.marker.opacity || marker.opacity;\n var markerShape = argsData.point.marker.shape || argsData.shape;\n var imageURL = argsData.point.marker.imageUrl || marker.imageUrl;\n shapeOption = new PathOption(symbolId, markerFill, markerBorder.width, markerBorder.color, markerOpacity, null);\n if ((parentElement !== undefined && parentElement !== null) || this.chart.enableCanvas) {\n if (redraw && getElement(shapeOption.id)) {\n markerElement = getElement(shapeOption.id);\n circlePath = markerShape === 'Circle' ? 'c' : '';\n previousLocation = {\n x: +markerElement.getAttribute(circlePath + 'x'), y: +markerElement.getAttribute(circlePath + 'y')\n };\n previousPath = markerElement.getAttribute('d');\n }\n markerElement = drawSymbol(location, markerShape, new Size(markerWidth, markerHeight), imageURL, shapeOption, point.x.toString() + ':' + y.toString(), this.chart.renderer, series.clipRect);\n if (markerElement) {\n markerElement.setAttribute('role', 'img');\n markerElement.setAttribute('aria-label', (point.x + ': ' + point.y + ', ' + series.name));\n }\n appendChildElement(this.chart.enableCanvas, parentElement, markerElement, redraw, true, circlePath + 'x', circlePath + 'y', previousLocation, previousPath, false, false, null, series.chart.duration);\n }\n point.marker = {\n border: markerBorder, fill: markerFill, height: markerHeight,\n visible: true, shape: markerShape, width: markerWidth, imageUrl: imageURL\n };\n }\n else {\n location = null;\n point.marker = {\n visible: false\n };\n }\n };\n Marker.prototype.createElement = function (series, redraw) {\n var markerClipRect;\n var marker = series.marker;\n // 8 for extend border value 5 for extend size value\n var explodeValue = marker.border.width + 8 + 5;\n var render = series.chart.svgRenderer;\n var index = series.index === undefined ? series.category : series.index;\n var options;\n var transform = series.chart.chartAreaType === 'Cartesian' ? 'translate(' + series.clipRect.x + ',' + (series.clipRect.y) + ')' : '';\n if (marker.visible) {\n var markerHeight = (marker.height + explodeValue) / 2;\n var markerWidth = (marker.width + explodeValue) / 2;\n if (series.chart.chartAreaType === 'Cartesian') {\n var isZoomed = series.xAxis.zoomFactor < 1 || series.xAxis.zoomPosition > 0;\n options = new RectOption(this.elementId + '_ChartMarkerClipRect_' + index, 'transparent', { width: 1, color: 'Gray' }, 1, {\n x: isZoomed ? 0 : -markerWidth, y: -markerHeight,\n width: series.clipRect.width + (isZoomed ? 0 : markerWidth * 2),\n height: series.clipRect.height + markerHeight * 2\n });\n markerClipRect = appendClipElement(redraw, options, render);\n }\n else {\n options = new CircleOption(this.elementId + '_ChartMarkerClipRect_' + index, 'transparent', { width: 1, color: 'Gray' }, 1, series.clipRect.width / 2 + series.clipRect.x, series.clipRect.height / 2 + series.clipRect.y, series.chart.radius + Math.max(markerHeight, markerWidth));\n markerClipRect = appendClipElement(redraw, options, render, 'drawCircularClipPath');\n }\n options = {\n 'id': this.elementId + 'SymbolGroup' + index,\n 'transform': transform,\n 'clip-path': 'url(#' + this.elementId + '_ChartMarkerClipRect_' + index + ')'\n };\n series.symbolElement = render.createGroup(options);\n series.symbolElement.appendChild(markerClipRect);\n if (this.chart.enableCanvas) {\n var element = document.getElementById(this.chart.element.id + '_tooltip_svg');\n element.appendChild(series.symbolElement);\n }\n }\n };\n Marker.prototype.getRangeLowPoint = function (region, series) {\n var x = region.x;\n var y = region.y;\n if (series.chart.requireInvertedAxis) {\n y += region.height / 2;\n x += series.yAxis.isAxisInverse ? region.width : 0;\n }\n else {\n y += series.yAxis.isAxisInverse ? 0 : region.height;\n x += region.width / 2;\n }\n return { x: x, y: y };\n };\n /**\n * Animates the marker.\n *\n * @returns {void}\n * @private\n */\n Marker.prototype.doMarkerAnimation = function (series) {\n if (!(series.type === 'Scatter' || series.type === 'Bubble' || series.type === 'Candle' || series.type === 'Hilo' ||\n series.type === 'HiloOpenClose' || (series.chart.chartAreaType === 'PolarRadar' && (series.drawType === 'Scatter')))) {\n var markerElements = series.symbolElement.childNodes;\n var delay = series.animation.delay + (series.animation.duration === 0 && animationMode === 'Enable' ? 1000 : series.animation.duration);\n var duration = series.chart.animated ? series.chart.duration : 200;\n var j = 1;\n var incFactor = (series.type === 'RangeArea' || series.type === 'RangeColumn' || series.type === 'SplineRangeArea' || series.type === 'RangeStepArea') ? 2 : 1;\n for (var i = 0; i < series.points.length; i++) {\n if (series.points[i].symbolLocations) {\n if (!series.points[i].symbolLocations.length || !markerElements[j]) {\n continue;\n }\n markerAnimate(markerElements[j], delay, duration, series, i, series.points[i].symbolLocations[0], false);\n if (incFactor === 2) {\n var lowPoint = this.getRangeLowPoint(series.points[i].regions[0], series);\n markerAnimate(markerElements[j + 1], delay, duration, series, i, lowPoint, false);\n }\n j += incFactor;\n }\n }\n }\n };\n return Marker;\n}(MarkerExplode));\nexport { Marker };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\n// eslint-disable-next-line @typescript-eslint/triple-slash-reference\n/// <reference path='../series/chart-series-model.d.ts' />\nimport { Property, Complex } from '@syncfusion/ej2-base';\nimport { Connector } from '../../common/model/base';\nimport { SeriesBase } from '../series/chart-series';\nimport { firstToLowerCase } from '../../common/utils/helper';\nimport { Rect } from '@syncfusion/ej2-svg-base';\n/**\n * Defines how to represent the market trend using technical indicators\n */\nvar TechnicalIndicator = /** @class */ (function (_super) {\n __extends(TechnicalIndicator, _super);\n function TechnicalIndicator() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n /** @private */\n _this.clipRect = new Rect(0, 0, 0, 0);\n return _this;\n }\n /** @private */\n TechnicalIndicator.prototype.setDataSource = function (series, chart) {\n if (series) {\n this.xData = series.xData;\n this.yData = series.yData;\n this.points = series.points;\n }\n var type = firstToLowerCase(this.type);\n if (this.visible) {\n chart[type + 'IndicatorModule'].initDataSource(this, chart);\n }\n chart.visibleSeriesCount += this.targetSeries.length;\n };\n __decorate([\n Property('Sma')\n ], TechnicalIndicator.prototype, \"type\", void 0);\n __decorate([\n Property(14)\n ], TechnicalIndicator.prototype, \"period\", void 0);\n __decorate([\n Property(14)\n ], TechnicalIndicator.prototype, \"kPeriod\", void 0);\n __decorate([\n Property(3)\n ], TechnicalIndicator.prototype, \"dPeriod\", void 0);\n __decorate([\n Property(80)\n ], TechnicalIndicator.prototype, \"overBought\", void 0);\n __decorate([\n Property(20)\n ], TechnicalIndicator.prototype, \"overSold\", void 0);\n __decorate([\n Property(2)\n ], TechnicalIndicator.prototype, \"standardDeviation\", void 0);\n __decorate([\n Property('Close')\n ], TechnicalIndicator.prototype, \"field\", void 0);\n __decorate([\n Property(12)\n ], TechnicalIndicator.prototype, \"slowPeriod\", void 0);\n __decorate([\n Property(26)\n ], TechnicalIndicator.prototype, \"fastPeriod\", void 0);\n __decorate([\n Property(true)\n ], TechnicalIndicator.prototype, \"showZones\", void 0);\n __decorate([\n Complex({ color: '#ff9933', width: 2 }, Connector)\n ], TechnicalIndicator.prototype, \"macdLine\", void 0);\n __decorate([\n Property('Both')\n ], TechnicalIndicator.prototype, \"macdType\", void 0);\n __decorate([\n Property('#2ecd71')\n ], TechnicalIndicator.prototype, \"macdPositiveColor\", void 0);\n __decorate([\n Property('#e74c3d')\n ], TechnicalIndicator.prototype, \"macdNegativeColor\", void 0);\n __decorate([\n Property('rgba(211,211,211,0.25)')\n ], TechnicalIndicator.prototype, \"bandColor\", void 0);\n __decorate([\n Complex({ color: '#ffb735', width: 1 }, Connector)\n ], TechnicalIndicator.prototype, \"upperLine\", void 0);\n __decorate([\n Complex({ color: '#f2ec2f', width: 1 }, Connector)\n ], TechnicalIndicator.prototype, \"lowerLine\", void 0);\n __decorate([\n Complex({ color: '#f2ec2f', width: 1 }, Connector)\n ], TechnicalIndicator.prototype, \"periodLine\", void 0);\n __decorate([\n Property('')\n ], TechnicalIndicator.prototype, \"seriesName\", void 0);\n return TechnicalIndicator;\n}(SeriesBase));\nexport { TechnicalIndicator };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable jsdoc/valid-types */\n/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable jsdoc/require-param-type */\n/* eslint-disable jsdoc/require-returns-description */\n/* eslint-disable @typescript-eslint/no-this-alias */\n/* eslint-disable curly */\n/* eslint-disable @typescript-eslint/tslint/config */\n/* eslint-disable no-case-declarations */\n/* eslint-disable max-len */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable jsdoc/require-param */\n/* eslint-disable valid-jsdoc */\nimport { Component, Property, NotifyPropertyChanges, Internationalization } from '@syncfusion/ej2-base';\nimport { L10n, setValue, isNullOrUndefined, updateBlazorTemplate } from '@syncfusion/ej2-base';\nimport { ChildProperty } from '@syncfusion/ej2-base';\nimport { remove, extend } from '@syncfusion/ej2-base';\nimport { Browser, Touch } from '@syncfusion/ej2-base';\nimport { Event, EventHandler, Complex, Collection } from '@syncfusion/ej2-base';\nimport { findClipRect, showTooltip, ImageOption, removeElement, appendChildElement, blazorTemplatesReset, withInBounds } from '../common/utils/helper';\nimport { textElement, RectOption, createSvg, firstToLowerCase, titlePositionX, redrawElement, getTextAnchor } from '../common/utils/helper';\nimport { appendClipElement, ChartLocation } from '../common/utils/helper';\nimport { getSeriesColor, getThemeColor } from '../common/model/theme';\nimport { Margin, Border, ChartArea, Indexes, TooltipSettings, titleSettings } from '../common/model/base';\nimport { Row, Column, Axis } from './axis/axis';\nimport { CartesianAxisLayoutPanel } from './axis/cartesian-panel';\nimport { Rect, measureText, TextOption, Size, SvgRenderer } from '@syncfusion/ej2-svg-base';\nimport { ChartData } from './utils/get-data';\nimport { Series } from './series/chart-series';\nimport { Data } from '../common/model/data';\nimport { Marker, markerShapes } from './series/marker';\nimport { LegendSettings } from '../common/legend/legend';\nimport { TechnicalIndicator } from './technical-indicators/technical-indicator';\nimport { chartMouseClick, chartDoubleClick, pointClick, pointDoubleClick, axisLabelClick, beforeResize } from '../common/model/constants';\nimport { chartMouseDown, chartMouseMove, chartMouseUp, load, pointMove, chartMouseLeave, resized } from '../common/model/constants';\nimport { ChartAnnotationSettings } from './model/chart-base';\nimport { getElement, getTitle } from '../common/utils/helper';\nimport { PrintUtils } from '../common/utils/print';\n/**\n * Configures the RangeColorSetting in the chart.\n */\nvar RangeColorSetting = /** @class */ (function (_super) {\n __extends(RangeColorSetting, _super);\n function RangeColorSetting() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property()\n ], RangeColorSetting.prototype, \"start\", void 0);\n __decorate([\n Property()\n ], RangeColorSetting.prototype, \"end\", void 0);\n __decorate([\n Property([])\n ], RangeColorSetting.prototype, \"colors\", void 0);\n __decorate([\n Property('')\n ], RangeColorSetting.prototype, \"label\", void 0);\n return RangeColorSetting;\n}(ChildProperty));\nexport { RangeColorSetting };\n/**\n * Configures the crosshair in the chart.\n */\nvar CrosshairSettings = /** @class */ (function (_super) {\n __extends(CrosshairSettings, _super);\n function CrosshairSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], CrosshairSettings.prototype, \"enable\", void 0);\n __decorate([\n Property('')\n ], CrosshairSettings.prototype, \"dashArray\", void 0);\n __decorate([\n Complex({ color: null, width: 1 }, Border)\n ], CrosshairSettings.prototype, \"line\", void 0);\n __decorate([\n Property('Both')\n ], CrosshairSettings.prototype, \"lineType\", void 0);\n __decorate([\n Property('')\n ], CrosshairSettings.prototype, \"verticalLineColor\", void 0);\n __decorate([\n Property('')\n ], CrosshairSettings.prototype, \"horizontalLineColor\", void 0);\n __decorate([\n Property(1)\n ], CrosshairSettings.prototype, \"opacity\", void 0);\n return CrosshairSettings;\n}(ChildProperty));\nexport { CrosshairSettings };\n/**\n * Configures the zooming behavior for the chart.\n */\nvar ZoomSettings = /** @class */ (function (_super) {\n __extends(ZoomSettings, _super);\n function ZoomSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], ZoomSettings.prototype, \"enableSelectionZooming\", void 0);\n __decorate([\n Property(false)\n ], ZoomSettings.prototype, \"enablePinchZooming\", void 0);\n __decorate([\n Property(false)\n ], ZoomSettings.prototype, \"showToolbar\", void 0);\n __decorate([\n Property(false)\n ], ZoomSettings.prototype, \"enableMouseWheelZooming\", void 0);\n __decorate([\n Property(true)\n ], ZoomSettings.prototype, \"enableDeferredZooming\", void 0);\n __decorate([\n Property('XY')\n ], ZoomSettings.prototype, \"mode\", void 0);\n __decorate([\n Property(['Zoom', 'ZoomIn', 'ZoomOut', 'Pan', 'Reset'])\n ], ZoomSettings.prototype, \"toolbarItems\", void 0);\n __decorate([\n Property(false)\n ], ZoomSettings.prototype, \"enablePan\", void 0);\n __decorate([\n Property(false)\n ], ZoomSettings.prototype, \"enableScrollbar\", void 0);\n return ZoomSettings;\n}(ChildProperty));\nexport { ZoomSettings };\n/**\n * Represents the Chart control.\n * ```html\n * <div id=\"chart\"/>\n * <script>\n * var chartObj = new Chart({ isResponsive : true });\n * chartObj.appendTo(\"#chart\");\n * </script>\n * ```\n *\n * @public\n */\nvar Chart = /** @class */ (function (_super) {\n __extends(Chart, _super);\n /**\n * Constructor for creating the widget\n *\n * @hidden\n */\n function Chart(options, element) {\n var _this = _super.call(this, options, element) || this;\n /** @private */\n _this.rotatedDataLabelCollections = [];\n /** @public */\n _this.animated = false;\n /** @private */\n _this.isPointMouseDown = false;\n /** @private */\n _this.isScrolling = false;\n /** @private */\n _this.checkResize = 0;\n /** @private */\n _this.visible = 0;\n /** @private */\n _this.clickCount = 0;\n /** @private */\n _this.maxPointCount = 0;\n /** @private */\n _this.singleClickTimer = 0;\n /** @private */\n _this.chartAreaType = 'Cartesian';\n /** @private */\n _this.isRtlEnabled = false;\n /** @private */\n _this.scaleX = 1;\n /** @private */\n _this.scaleY = 1;\n _this.isCrosshair = true;\n _this.chartid = 57723;\n /** @private */\n _this.isLegendClicked = false;\n _this.isZoomed = false;\n _this.previousTargetId = '';\n _this.currentPointIndex = 0;\n _this.currentSeriesIndex = 0;\n _this.currentLegendIndex = 0;\n _this.previousPageX = null;\n _this.previousPageY = null;\n _this.allowPan = false;\n setValue('mergePersistData', _this.mergePersistChartData, _this);\n return _this;\n }\n /**\n * To manage persist chart data\n */\n Chart.prototype.mergePersistChartData = function () {\n var data = window.localStorage.getItem(this.getModuleName() + this.element.id);\n if (!(isNullOrUndefined(data) || (data === ''))) {\n var dataObj = JSON.parse(data);\n var keys = Object.keys(dataObj);\n this.isProtectedOnChange = true;\n for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) {\n var key = keys_1[_i];\n if ((typeof this[key] === 'object') && !isNullOrUndefined(this[key])) {\n extend(this[key], dataObj[key]);\n }\n else {\n this[key] = dataObj[key];\n }\n }\n this.isProtectedOnChange = false;\n }\n };\n /**\n *\n * @param elementId\n * Return the proper ID when the special character exist in the ID\n */\n Chart.prototype.isIdHasSpecialCharacter = function (elementId) {\n var regex = /^[A-Za-z ]+$/;\n var numberRegex = /^[0-9 ]+$/;\n var childElementId = '';\n if (!regex.test(elementId)) {\n var start = 0;\n if (numberRegex.test(elementId[0])) {\n childElementId += ('\\\\3' + elementId[0]);\n start = 1;\n }\n for (var i = start; i < elementId.length; i++) {\n if (!regex.test(elementId[i]) && elementId.indexOf('-') === -1 &&\n elementId.indexOf('_') === -1 && elementId.indexOf('\\\\') === -1 && !numberRegex.test(elementId[i])) {\n childElementId += ('\\\\' + elementId[i]);\n }\n else {\n childElementId += elementId[i];\n }\n }\n return childElementId;\n }\n else {\n return elementId;\n }\n };\n /**\n * Initialize the event handler.\n */\n Chart.prototype.preRender = function () {\n this.element.id = this.isIdHasSpecialCharacter(this.element.id);\n // It is used for checking blazor framework or not.\n var blazor = 'Blazor';\n this.isBlazor = window[blazor];\n this.allowServerDataBinding = false;\n this.markerIndex = 0;\n this.unWireEvents();\n this.initPrivateVariable();\n this.setCulture();\n this.wireEvents();\n if (this.stockChart) {\n if (this.stockChart.tooltip.header === null) {\n this.tooltip.header = '<b>${point.x}</b>';\n }\n if (this.stockChart.tooltip.format === null) {\n this.tooltip.format = 'High : <b>${point.high}</b><br/>Low :' +\n ' <b>${point.low}</b><br/>Open : <b>${point.open}</b><br/>Close : <b>${point.close}</b>';\n }\n }\n this.element.setAttribute('dir', this.enableRtl ? 'rtl' : '');\n };\n Chart.prototype.initPrivateVariable = function () {\n this.animateSeries = true;\n this.delayRedraw = false;\n this.dragY = null;\n this.horizontalAxes = [];\n this.verticalAxes = [];\n this.refreshAxis();\n this.refreshDefinition(this.rows);\n this.refreshDefinition(this.columns);\n if (this.tooltipModule) {\n this.tooltipModule.previousPoints = [];\n }\n this.element.setAttribute('role', 'region');\n this.element.setAttribute('tabindex', '0');\n this.element.setAttribute('aria-label', this.description || this.title + '. Syncfusion interactive chart.');\n if (!(this.element.classList.contains(\"e-chart-focused\"))) {\n this.element.setAttribute('class', this.element.getAttribute('class') + ' e-chart-focused');\n }\n if (this.element.id === '') {\n var collection = document.getElementsByClassName('e-chart').length;\n var elementid = 'chart_' + this.chartid + '_' + collection;\n while (document.getElementById(elementid)) {\n collection++;\n elementid = 'chart_' + this.chartid + '_' + collection;\n }\n this.element.id = 'chart_' + this.chartid + '_' + collection;\n }\n //seperate ID to differentiate chart and stock chart\n this.svgId = this.stockChart ? this.stockChart.element.id + '_stockChart_chart' :\n this.element.id + (this.enableCanvas ? '_canvas' : '_svg');\n };\n /**\n * To Initialize the control rendering.\n */\n Chart.prototype.render = function () {\n var _this = this;\n this.svgRenderer = new SvgRenderer(this.element.id);\n var loadEventData = {\n chart: this.isBlazor ? {} : this, theme: this.theme, name: load, cancel: false\n };\n if (!this.stockChart) {\n /**\n * Load event for the chart will be triggered only chart componet, if this is stock chart, load event did not triggered.\n */\n this.trigger(load, loadEventData, function () {\n if (!loadEventData.cancel) {\n _this.cartesianChartRendering(loadEventData);\n }\n });\n }\n else {\n // The fix is specific for nextjs app, as window is set as not defined for server side application like nextjs.\n this.isRtlEnabled = (window.getComputedStyle(document.querySelector('body')).direction === 'rtl');\n this.cartesianChartRendering(loadEventData);\n }\n this.applyZoomkit();\n };\n Chart.prototype.cartesianChartRendering = function (beforeRenderData) {\n this.theme = this.isBlazor ? beforeRenderData.theme : this.theme;\n this.setTheme();\n this.createChartSvg();\n this.markerRender = new Marker(this);\n this.calculateAreaType();\n this.calculateVisibleSeries();\n this.initTechnicalIndicators();\n this.initTrendLines();\n this.calculateVisibleAxis();\n this.processData();\n this.renderComplete();\n this.mouseMoveEvent();\n this.allowServerDataBinding = true;\n };\n /**\n * Gets the localized label by locale keyword.\n *\n * @param {string} key key\n * @returns {string} localized label\n */\n Chart.prototype.getLocalizedLabel = function (key) {\n return this.localeObject.getConstant(key);\n };\n /**\n * Animate the series bounds.\n *\n * @private\n */\n Chart.prototype.animate = function (duration) {\n this.redraw = true;\n this.animated = true; //used to set duration as 1000 for animation at default 300\n this.duration = duration ? duration : 1000;\n if (this.tooltipModule) {\n this.tooltipModule.removeHighlightedMarker(this.tooltipModule.previousPoints, true);\n }\n else if (this.markerRender.previousPoints) {\n for (var previousPoint = 0; previousPoint < this.markerRender.previousPoints.length; previousPoint++)\n this.markerRender.removeHighlightedMarker(this.markerRender.previousPoints[previousPoint].series, this.markerRender.previousPoints[previousPoint].point);\n }\n };\n /**\n * Refresh the chart bounds.\n *\n * @private\n */\n Chart.prototype.refreshBound = function () {\n this.rotatedDataLabelCollections = [];\n if (this.legendModule && this.legendSettings.visible) {\n this.legendModule.getLegendOptions(this.visibleSeries, this);\n }\n /**\n * I264230, EJ2-36761\n * Issue: Tooltip doesnot appears after zooming and hovering on same point\n * Root cause: While performing zoom, previous points in tooltip restore.\n * Fix: previous points set to empty array\n */\n if (this.tooltip.enable && this.tooltipModule) {\n this.tooltipModule.previousPoints = [];\n }\n this.calculateStackValues();\n this.calculateBounds();\n //this prevents the initial rendering of stock chart\n if (this.stockChart && !this.stockChart.rangeFound) {\n if (this.stockChart.enablePeriodSelector || this.stockChart.enableSelector) {\n return null;\n }\n }\n this.renderElements();\n removeElement('chartmeasuretext');\n this.removeSelection();\n if (this.markerRender) {\n this.markerRender.mergeXvalues(this.visibleSeries);\n }\n };\n /**\n * To calcualte the stack values\n */\n Chart.prototype.calculateStackValues = function () {\n var series;\n var isCalculateStacking = false;\n for (var i = 0, len = this.visibleSeries.length; i < len; i++) {\n series = this.visibleSeries[i];\n series.position = series.rectCount = undefined;\n if (((series.type.indexOf('Stacking') !== -1) || (series.drawType.indexOf('Stacking') !== -1\n && this.chartAreaType === 'PolarRadar')) && !isCalculateStacking) {\n series.calculateStackedValue(series.type.indexOf('100') > -1, this);\n isCalculateStacking = true;\n }\n }\n };\n Chart.prototype.removeSelection = function () {\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n if (series.visible) {\n for (var _b = 0, _c = series.points; _b < _c.length; _b++) {\n var point = _c[_b];\n point.isSelect = false;\n }\n }\n }\n if (getElement(this.element.id + '_ej2_drag_multi_group')) {\n if (this.selectionMode.indexOf('Drag') > -1) {\n this.selectionModule.filterArray = [];\n }\n removeElement(this.element.id + '_ej2_drag_multi_group');\n this.selectionModule.calculateDragSelectedElements(this, new Rect(0, 0, 0, 0), true);\n }\n else if (getElement(this.element.id + '_ej2_drag_group')) {\n if (this.selectionMode !== 'Lasso') {\n this.selectionModule.filterArray = [];\n }\n removeElement(this.element.id + '_ej2_drag_group');\n this.selectionModule.calculateDragSelectedElements(this, new Rect(0, 0, 0, 0), true);\n }\n };\n Chart.prototype.renderElements = function () {\n this.renderBorder();\n this.renderTitle();\n this.renderAreaBorder();\n this.renderSeriesElements(this.renderAxes());\n this.renderLegend();\n this.applyZoomkit();\n this.performSelection();\n this.setSecondaryElementPosition();\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var value = _a[_i];\n updateBlazorTemplate(this.element.id + '_DataLabel', 'Template', value.marker.dataLabel);\n }\n this.renderAnnotation();\n };\n /**\n * To render the legend\n *\n * @private\n */\n Chart.prototype.renderAxes = function () {\n this.yAxisElements = this.renderer.createGroup({ id: this.element.id + 'yAxisCollection' });\n var axisElement;\n if (this.rows.length > 0 && this.columns.length > 0) {\n axisElement = this.chartAxisLayoutPanel.renderAxes();\n }\n if (this.stripLineModule) {\n this.stripLineModule.renderStripLine(this, 'Behind', this.axisCollections);\n }\n return axisElement;\n };\n /**\n * To render the legend\n */\n Chart.prototype.renderLegend = function () {\n if (this.legendModule && this.legendModule.legendCollections.length && this.legendSettings.visible) {\n this.legendModule.calTotalPage = true;\n var borderWidth = this.legendSettings.border.width;\n var bounds = this.legendModule.legendBounds;\n var rect = new Rect(bounds.x, bounds.y, bounds.width, bounds.height);\n if (this.enableCanvas) {\n rect = new Rect(rect.x - borderWidth / 2, rect.y - borderWidth / 2, rect.width + borderWidth, rect.height + borderWidth);\n this.renderer.canvasClip(rect);\n }\n this.legendModule.renderLegend(this, this.legendSettings, bounds);\n if (this.enableCanvas) {\n this.renderer.canvasRestore();\n }\n }\n if (!this.redraw) {\n if (!this.stockChart) {\n this.element.appendChild(this.svgObject);\n }\n else {\n if (!getElement(this.stockChart.chartObject.id)) {\n this.stockChart.mainObject.appendChild(this.svgObject);\n }\n }\n }\n };\n /**\n * To set the left and top position for data label template for center aligned chart\n */\n Chart.prototype.setSecondaryElementPosition = function () {\n var element = getElement(this.element.id + '_Secondary_Element');\n if (!element) {\n return;\n }\n var rect = this.element.getBoundingClientRect();\n var svgRect = getElement(this.svgId).getBoundingClientRect();\n element.style.left = Math.max(svgRect.left - rect.left, 0) + 'px';\n element.style.top = Math.max(svgRect.top - rect.top, 0) + 'px';\n };\n Chart.prototype.initializeModuleElements = function () {\n this.dataLabelCollections = [];\n var elementId = this.element.id;\n if (this.series.length) {\n this.seriesElements = this.svgRenderer.createGroup({ id: elementId + 'SeriesCollection' });\n }\n if (this.indicators.length) {\n this.indicatorElements = this.renderer.createGroup({ id: elementId + 'IndicatorCollection' });\n }\n if (this.hasTrendlines()) {\n this.trendLineElements = this.renderer.createGroup({ id: elementId + 'TrendLineCollection' });\n }\n this.dataLabelElements = this.renderer.createGroup({ id: elementId + 'DataLabelCollection' });\n };\n Chart.prototype.hasTrendlines = function () {\n var isTrendline;\n for (var _i = 0, _a = this.series; _i < _a.length; _i++) {\n var series = _a[_i];\n isTrendline = series.trendlines.length ? true : false;\n if (isTrendline) {\n break;\n }\n }\n return isTrendline;\n };\n Chart.prototype.renderSeriesElements = function (axisElement) {\n // Initialize the series elements values\n this.initializeModuleElements();\n var elementId = this.element.id;\n if (this.element.tagName !== 'g') {\n var tooltipDiv = redrawElement(this.redraw, elementId + '_Secondary_Element') ||\n this.createElement('div');\n tooltipDiv.id = elementId + '_Secondary_Element';\n tooltipDiv.style.cssText = 'position: relative';\n appendChildElement(false, this.element, tooltipDiv, this.redraw);\n }\n // For canvas\n if (this.enableCanvas) {\n var tooltipdiv = document.getElementById(elementId + '_Secondary_Element');\n tooltipdiv = !tooltipdiv ? this.createElement('div', { id: elementId + '_Secondary_Element',\n attrs: { 'style': 'position: relative; left:0px; top:0px' } }) : tooltipdiv;\n var svg = this.svgRenderer.createSvg({\n id: elementId + '_tooltip_svg',\n width: this.availableSize.width,\n height: this.availableSize.height\n });\n svg.style.cssText = 'position: absolute; pointer-events: none';\n tooltipdiv.appendChild(svg);\n }\n // For userInteraction\n if (this.tooltip.enable) {\n appendChildElement(this.enableCanvas, this.svgObject, this.renderer.createGroup({ id: elementId + '_UserInteraction', style: 'pointer-events:none;' }), this.redraw);\n }\n if (this.rows.length > 0 && this.columns.length > 0) {\n this.initializeIndicator();\n this.initializeTrendLine();\n this.renderSeries();\n // Trendline is append to DOM after the series\n if (this.trendLineElements) {\n appendChildElement(this.enableCanvas, this.svgObject, this.trendLineElements, this.redraw);\n }\n this.appendElementsAfterSeries(axisElement);\n }\n };\n /**\n * @private\n */\n Chart.prototype.renderSeries = function () {\n var visibility;\n if (this.enableCanvas) {\n // To clip the series rect for canvas\n this.renderer.canvasClip(this.chartAxisLayoutPanel.seriesClipRect);\n }\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var item = _a[_i];\n if (item.category === 'TrendLine') {\n visibility = this.series[item.sourceIndex].trendlines[item.index].visible;\n }\n else {\n visibility = item.visible;\n }\n if (visibility) {\n this.visible++;\n findClipRect(item, this.enableCanvas);\n if (this.enableCanvas) {\n // To render scatter and bubble series in canvas\n this.renderCanvasSeries(item);\n }\n item.renderSeries(this);\n }\n }\n if (this.enableCanvas) {\n this.renderer.canvasRestore();\n }\n this.visible = 0;\n var options = {\n 'id': this.element.id + '_ChartAreaClipRect_',\n 'x': this.chartAxisLayoutPanel.seriesClipRect.x,\n 'y': this.chartAxisLayoutPanel.seriesClipRect.y,\n 'width': this.chartAxisLayoutPanel.seriesClipRect.width,\n 'height': this.chartAxisLayoutPanel.seriesClipRect.height,\n 'fill': 'transparent',\n 'stroke-width': 1,\n 'stroke': 'Gray'\n };\n if (!this.seriesElements) {\n return;\n }\n var clipRectElement;\n if (this.chartAreaType === 'PolarRadar') {\n clipRectElement = appendClipElement(this.redraw, options, this.renderer, 'drawCircularClipPath');\n }\n else {\n clipRectElement = appendClipElement(this.redraw, options, this.renderer);\n }\n if (!this.enableCanvas) {\n this.seriesElements.appendChild(clipRectElement);\n }\n var seriesSvg = document.getElementById(this.element.id + '_series_svg');\n if (seriesSvg) {\n appendChildElement(false, seriesSvg, this.seriesElements, this.redraw);\n }\n else {\n appendChildElement(this.enableCanvas, this.svgObject, this.seriesElements, this.redraw);\n }\n };\n Chart.prototype.renderCanvasSeries = function (item) {\n var svgElement;\n // eslint-disable-next-line prefer-const\n svgElement = (this.enableCanvas) ?\n svgElement : this.svgObject;\n var canvas = (this.enableCanvas) ?\n false : this.enableCanvas;\n };\n Chart.prototype.initializeIndicator = function () {\n for (var _i = 0, _a = this.indicators; _i < _a.length; _i++) {\n var indicator = _a[_i];\n if (this[firstToLowerCase(indicator.type) + 'IndicatorModule']) {\n this[firstToLowerCase(indicator.type) + 'IndicatorModule'].createIndicatorElements(this, indicator, indicator.index);\n }\n }\n if (this.indicatorElements) {\n appendChildElement(this.enableCanvas, this.svgObject, this.indicatorElements, this.redraw);\n }\n };\n Chart.prototype.initializeTrendLine = function () {\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n if (series.trendlines.length) {\n this.trendLineModule.getTrendLineElements(series, this);\n }\n }\n };\n Chart.prototype.appendElementsAfterSeries = function (axisElement) {\n if (this.chartAreaType === 'PolarRadar') {\n appendChildElement(this.enableCanvas, this.svgObject, this.yAxisElements, this.redraw);\n }\n appendChildElement(this.enableCanvas, this.svgObject, axisElement, this.redraw);\n if ((this.zoomModule && this.zoomSettings.enableScrollbar && this.scrollElement.childElementCount) ||\n (this.scrollElement && this.scrollElement.childElementCount)) {\n appendChildElement(false, getElement(this.element.id + '_Secondary_Element'), this.scrollElement, this.redraw);\n }\n if (this.stripLineModule) {\n this.stripLineModule.renderStripLine(this, 'Over', this.axisCollections);\n }\n if (!this.tooltip.enable) {\n appendChildElement(this.enableCanvas, this.svgObject, this.renderer.createGroup({ id: this.element.id + '_UserInteraction', style: 'pointer-events:none;' }), this.redraw);\n }\n if (this.stockChart) {\n this.stockChart.calculateStockEvents();\n }\n };\n Chart.prototype.applyZoomkit = function () {\n /**\n * Issue: Zoomkit not visible after performing refresh()\n * Fix: this method called without checking `zoomModule.isZoomed`\n */\n if (this.chartAreaType === 'PolarRadar') {\n return;\n }\n if (!this.redraw && this.zoomModule && (!this.zoomSettings.enablePan || this.zoomModule.performedUI || this.zoomSettings.showToolbar)) {\n this.zoomModule.applyZoomToolkit(this, this.axisCollections);\n }\n };\n /**\n * Render annotation perform here\n *\n * @private\n */\n Chart.prototype.renderAnnotation = function () {\n if (this.annotationModule) {\n //for stock chart, stock chart's id is added to render the annotations\n this.annotationModule.renderAnnotations(getElement((this.stockChart ? this.stockChart.element.id : this.element.id) + '_Secondary_Element'));\n }\n };\n Chart.prototype.performSelection = function () {\n var selectedDataIndexes = [];\n if (this.selectionModule) {\n selectedDataIndexes = extend([], this.selectionModule.selectedDataIndexes, null, true);\n this.selectionModule.invokeSelection(this);\n }\n if (this.highlightModule) {\n this.highlightModule.invokeHighlight(this);\n }\n if (selectedDataIndexes.length > 0) {\n this.selectionModule.selectedDataIndexes = selectedDataIndexes;\n this.selectionModule.redrawSelection(this, this.selectionMode);\n }\n };\n Chart.prototype.processData = function (render) {\n if (render === void 0) { render = true; }\n this.visibleSeriesCount = 0;\n var check = true;\n var prevPointCount = 0;\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n if (!series.visible && !this.legendSettings.visible) {\n this.visibleSeriesCount++;\n continue;\n }\n if (series.category !== 'Indicator' && series.category !== 'TrendLine') {\n this.initializeDataModule(series);\n }\n }\n for (var _b = 0, _c = this.indicators; _b < _c.length; _b++) {\n var indicator = _c[_b];\n if (indicator.dataSource) {\n var techIndicator = indicator;\n this.initializeDataModule(techIndicator);\n check = false;\n }\n }\n if (render && (!this.visibleSeries.length || this.visibleSeriesCount === this.visibleSeries.length && check)) {\n this.refreshBound();\n this.trigger('loaded', { chart: this.isBlazor ? {} : this });\n }\n if (!this.stockChart && this.visibleSeries.length > 0) {\n for (var _d = 0, _e = this.visibleSeries; _d < _e.length; _d++) {\n var series = _e[_d];\n if (!isNullOrUndefined(series.points)) {\n this.maxPointCount = Math.max(prevPointCount, series.points.length);\n prevPointCount = series.points.length;\n }\n }\n }\n };\n Chart.prototype.initializeDataModule = function (series) {\n series.xData = [];\n series.yData = [];\n var dataSource;\n var isAngular = 'isAngular';\n if (this[isAngular]) {\n dataSource = Object.keys(series.dataSource).length ? series.dataSource : this.dataSource;\n }\n else {\n dataSource = series.dataSource || this.dataSource;\n }\n series.dataModule = new Data(dataSource, series.query);\n series.points = [];\n series.refreshDataManager(this);\n };\n Chart.prototype.calculateBounds = function () {\n var margin = this.margin;\n // Title Height;\n var titleHeight = 0;\n var subTitleHeight = 0;\n var titleWidth = 0;\n var padding = this.titleStyle.position === 'Top' || (this.titleStyle.position === 'Bottom' && !this.legendSettings.visible) ? 15 : 5;\n var left = margin.left + this.border.width;\n var width = this.availableSize.width - left - margin.right - this.border.width;\n var elementSpacing = 0;\n this.titleCollection = [];\n this.subTitleCollection = [];\n if (this.title) {\n this.titleCollection = getTitle(this.title, this.titleStyle, width, this.enableRtl, this.themeStyle.chartTitleFont);\n titleHeight = (measureText(this.title, this.titleStyle, this.themeStyle.chartTitleFont).height * this.titleCollection.length) + padding;\n if (this.subTitle) {\n this.subTitleCollection = getTitle(this.subTitle, this.subTitleStyle, width, this.enableRtl, this.themeStyle.chartSubTitleFont);\n subTitleHeight = (measureText(this.subTitle, this.subTitleStyle, this.themeStyle.chartSubTitleFont).height * this.subTitleCollection.length) +\n padding;\n }\n }\n else if (this.legendSettings.position !== 'Top' && this.border.width) {\n elementSpacing = 10;\n }\n var top = margin.top + elementSpacing + this.border.width + this.chartArea.border.width * 0.5;\n var height = this.availableSize.height - top - this.border.width - margin.bottom;\n var marginTotal = subTitleHeight + titleHeight + this.titleStyle.border.width + this.subTitleStyle.border.width;\n switch (this.titleStyle.position) {\n case 'Top':\n top += marginTotal;\n height -= marginTotal;\n break;\n case 'Bottom':\n height -= marginTotal;\n break;\n case 'Left':\n left += marginTotal;\n width -= marginTotal;\n break;\n case 'Right':\n left -= (this.titleStyle.border.width + this.subTitleStyle.border.width);\n width -= marginTotal;\n break;\n }\n if (this.stockChart && this.stockChart.legendSettings.visible && this.stockChart.stockLegendModule) {\n if (this.stockChart.legendSettings.position === 'Top') {\n top += this.stockChart.stockLegendModule.legendBounds.height;\n }\n else if (this.stockChart.legendSettings.position === 'Left') {\n left += this.stockChart.stockLegendModule.legendBounds.width;\n }\n }\n this.initialClipRect = new Rect(left, top, width, height);\n if (this.legendModule && this.legendSettings.visible) {\n this.legendModule.calculateLegendBounds(this.initialClipRect, this.availableSize, null);\n }\n this.chartAxisLayoutPanel.measureAxis(this.initialClipRect);\n };\n /**\n * Handles the print method for chart control.\n */\n Chart.prototype.print = function (id) {\n var exportChart = new PrintUtils(this);\n var width = this.width;\n if (this.getModuleName() == 'chart' && parseInt(this.width) >= 80 && this.width.indexOf('%') > -1) {\n this.width = '80%';\n this.dataBind();\n }\n exportChart.print(id);\n if (this.getModuleName() == 'chart' && parseInt(this.width) >= 80 && this.width.indexOf('%') > -1) {\n this.width = width;\n this.dataBind();\n }\n };\n /**\n * Defines the trendline initialization\n */\n Chart.prototype.initTrendLines = function () {\n this.isProtectedOnChange = true;\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n var trendIndex = 0;\n for (var _b = 0, _c = series.trendlines; _b < _c.length; _b++) {\n var trendline = _c[_b];\n var trendLine = trendline;\n if (this.trendLineModule) {\n trendLine.index = trendIndex;\n trendLine.sourceIndex = series.index;\n this.trendLineModule.initSeriesCollection(trendLine, this);\n if (trendLine.targetSeries) {\n trendLine.targetSeries.xAxisName = series.xAxisName;\n trendLine.targetSeries.yAxisName = series.yAxisName;\n this.visibleSeries.push(trendLine.targetSeries);\n }\n }\n trendIndex++;\n }\n }\n this.isProtectedOnChange = false;\n };\n Chart.prototype.calculateAreaType = function () {\n var series = this.series[0];\n this.chartArea.border.width = this.stockChart ? 0 : this.chartArea.border.width;\n if (series) {\n this.requireInvertedAxis = ((series.type.indexOf('Bar') !== -1) && !this.isTransposed) ||\n ((series.type.indexOf('Bar') === -1) && this.isTransposed && this.chartAreaType !== 'PolarRadar');\n }\n this.chartAxisLayoutPanel = this.chartAreaType === 'PolarRadar' ? (this.polarSeriesModule || this.radarSeriesModule)\n : new CartesianAxisLayoutPanel(this);\n };\n /**\n * Calculate the visible axis\n *\n * @private\n */\n Chart.prototype.calculateVisibleAxis = function () {\n var axis;\n var axes = [this.primaryXAxis, this.primaryYAxis];\n axes = this.chartAreaType === 'Cartesian' ? axes.concat(this.axes) : axes;\n if (this.paretoSeriesModule && this.series[0].type === 'Pareto') {\n axes = axes.concat(this.paretoSeriesModule.paretoAxes);\n }\n this.axisCollections = [];\n if (this.zoomModule) {\n this.zoomModule.isPanning = this.zoomModule.isAxisZoomed(axes) && this.zoomSettings.enablePan;\n this.svgObject.setAttribute('cursor', this.zoomModule.isPanning ? 'pointer' : 'auto');\n if (this.scrollBarModule) {\n this.scrollBarModule.axes = axes;\n }\n }\n if (this.scrollSettingEnabled) {\n if (this.scrollBarModule) {\n this.scrollBarModule.axes = axes;\n }\n }\n for (var i = 0, len = axes.length; i < len; i++) {\n axis = axes[i];\n axis.series = [];\n axis.labels = [];\n axis.indexLabels = {};\n axis.orientation = (i == 0) ? (this.requireInvertedAxis ? 'Vertical' : 'Horizontal') :\n (i == 1) ? (this.requireInvertedAxis ? 'Horizontal' : 'Vertical') : axis.orientation;\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n this.initAxis(series, axis, true);\n if (series.category == 'Pareto' && series.type == 'Line' && series.yAxis) {\n series.yAxis.internalVisibility = series.paretoOptions.showAxis;\n }\n }\n for (var _b = 0, _c = this.indicators; _b < _c.length; _b++) {\n var indicator = _c[_b];\n this.initAxis(indicator, axis, false);\n }\n if (this.scrollBarModule && !axis.zoomingScrollBar) {\n this.scrollBarModule.injectTo(axis, this);\n }\n if (axis.orientation != null) {\n this.axisCollections.push(axis);\n }\n }\n if (this.rows.length > 0 && this.columns.length > 0) {\n this.chartAxisLayoutPanel.measure();\n }\n };\n Chart.prototype.initAxis = function (series, axis, isSeries) {\n if (series.xAxisName === axis.name || (series.xAxisName == null && axis.name === 'primaryXAxis')) {\n axis.orientation = this.requireInvertedAxis ? 'Vertical' : 'Horizontal';\n series.xAxis = axis;\n if (isSeries) {\n axis.series.push(series);\n }\n }\n else if (series.yAxisName === axis.name || (series.yAxisName == null && axis.name === 'primaryYAxis')) {\n axis.orientation = this.requireInvertedAxis ? 'Horizontal' : 'Vertical';\n series.yAxis = axis;\n if (isSeries) {\n axis.series.push(series);\n }\n }\n };\n Chart.prototype.initTechnicalIndicators = function () {\n var i = 0;\n for (var _i = 0, _a = this.indicators; _i < _a.length; _i++) {\n var indicator = _a[_i];\n var techIndicator = indicator;\n var type = firstToLowerCase(techIndicator.type);\n if (this[type + 'IndicatorModule']) {\n techIndicator.index = i;\n this[type + 'IndicatorModule'].initSeriesCollection(techIndicator, this);\n for (var _b = 0, _c = techIndicator.targetSeries; _b < _c.length; _b++) {\n var targetSeries = _c[_b];\n if (indicator.seriesName || indicator.dataSource) {\n this.visibleSeries.push(targetSeries);\n }\n }\n }\n i++;\n }\n };\n /** @private */\n Chart.prototype.refreshTechnicalIndicator = function (series) {\n if (this.indicators.length) {\n var targetIndicator = null;\n if (series instanceof Series && series.category !== 'Indicator') {\n for (var _i = 0, _a = this.indicators; _i < _a.length; _i++) {\n var indicator = _a[_i];\n if (indicator.seriesName === series.name && !indicator.dataSource) {\n targetIndicator = indicator;\n targetIndicator.setDataSource(series, this);\n }\n }\n }\n else if (series instanceof TechnicalIndicator) {\n targetIndicator = series;\n targetIndicator.setDataSource(series instanceof Series ? series : null, this);\n }\n }\n };\n Chart.prototype.calculateVisibleSeries = function () {\n var series;\n this.visibleSeries = [];\n var colors = this.palettes.length ? this.palettes : getSeriesColor(this.theme);\n var count = colors.length;\n var seriesCollection = this.series.sort(function (a, b) { return a.zOrder - b.zOrder; });\n for (var i = 0, len = seriesCollection.length; i < len; i++) {\n series = seriesCollection[i];\n // for y axis label issue during chart navigation\n series.category = seriesCollection[0].type === 'Pareto' ? 'Pareto' : 'Series';\n series.index = i;\n series.interior = series.fill || colors[i % count];\n if (!series.marker.shape && (series.marker.visible || series.type === 'Scatter' || series.drawType === 'Scatter')) {\n series.marker.shape = markerShapes[this.markerIndex % 10];\n this.markerIndex++;\n }\n if (this.isSecondaryAxis(series.xAxis)) {\n series.xAxis.internalVisibility = series.xAxis.series.some(function (value) { return (value.visible); });\n }\n if (this.isSecondaryAxis(series.yAxis)) {\n series.yAxis.internalVisibility = series.yAxis.series.some(function (value) { return (value.visible); });\n }\n switch (series.type) {\n case 'Bar':\n case 'StackingBar':\n case 'StackingBar100':\n if (seriesCollection[0].type.indexOf('Bar') === -1) {\n continue;\n }\n break;\n case 'Polar':\n case 'Radar':\n if (this.chartAreaType !== 'PolarRadar') {\n continue;\n }\n if (this.chartAreaType === 'PolarRadar' && ((series.xAxisName !== null && (this.primaryXAxis.name !== series.xAxisName)) ||\n (series.yAxisName !== null && (this.primaryYAxis.name !== series.yAxisName)))) {\n continue;\n }\n break;\n case 'Pareto':\n this.visibleSeries.push(series);\n this.paretoSeriesModule.initSeries(series, this);\n continue;\n default:\n if (this.chartAreaType === 'PolarRadar' || seriesCollection[0].type.indexOf('Bar') > -1) {\n continue;\n }\n break;\n }\n this.visibleSeries.push(series);\n seriesCollection[i] = series;\n }\n };\n Chart.prototype.isSecondaryAxis = function (axis) {\n return (this.axes.indexOf(axis) > -1);\n };\n Chart.prototype.renderTitle = function () {\n var rect;\n var margin = this.margin;\n var elementSpacing = 5;\n if (this.title) {\n var getAnchor = getTextAnchor(this.titleStyle.textAlignment, this.enableRtl);\n var elementSize = measureText(this.title, this.titleStyle, this.themeStyle.chartTitleFont);\n rect = new Rect(margin.left, 0, this.availableSize.width - margin.left - margin.right, 0);\n var borderWidth = this.titleStyle.border.width;\n var positionY = this.margin.top + ((elementSize.height) * 3 / 4);\n var positionX = titlePositionX(rect, this.titleStyle || this.themeStyle.chartTitleFont) + borderWidth;\n var rotation = void 0;\n var alignment = this.titleStyle.textAlignment;\n var subtitleSize = measureText(this.subTitle, this.subTitleStyle, this.themeStyle.chartSubTitleFont);\n switch (this.titleStyle.position) {\n case 'Top':\n positionY += borderWidth * 0.5;\n positionX += getAnchor === 'start' ? borderWidth * 0.5 + this.border.width :\n getAnchor === 'end' ? ((-borderWidth * 2) - this.border.width) : 0;\n break;\n case 'Bottom':\n positionX += getAnchor === 'start' ? (borderWidth * 0.5) + this.border.width :\n getAnchor === 'end' ? (-borderWidth * 2) - this.border.width : 0;\n positionY = this.availableSize.height - this.margin.bottom - subtitleSize.height - (elementSize.height / 2) -\n (borderWidth * 0.5) - (this.subTitleStyle.border.width * 0.5);\n break;\n case 'Left':\n positionX = this.margin.left + ((elementSize.height) * 3 / 4) + (borderWidth * 0.5);\n positionY = alignment == 'Near' ? margin.bottom + (borderWidth * 0.5) + this.border.width :\n alignment == 'Far' ? this.availableSize.height - margin.bottom - (borderWidth * 0.5) - this.border.width : this.availableSize.height / 2;\n getAnchor = alignment == 'Near' ? 'end' : alignment == 'Far' ? 'start' : 'middle';\n getAnchor = this.enableRtl ? (getAnchor === 'end' ? 'start' : getAnchor === 'start' ? 'end' : getAnchor) : getAnchor;\n rotation = 'rotate(' + -90 + ',' + positionX + ',' + positionY + ')';\n break;\n case 'Right':\n positionX = this.availableSize.width - this.margin.right - ((elementSize.height) * 3 / 4) - (borderWidth * 0.5);\n positionY = alignment == 'Near' ? margin.bottom + (borderWidth * 0.5) + this.border.width :\n alignment == 'Far' ? this.availableSize.height - margin.bottom - (borderWidth * 0.5) - this.border.width : this.availableSize.height / 2;\n getAnchor = alignment == 'Near' ? 'start' : alignment == 'Far' ? 'end' : 'middle';\n getAnchor = this.enableRtl ? (getAnchor === 'end' ? 'start' : getAnchor === 'start' ? 'end' : getAnchor) : getAnchor;\n rotation = 'rotate(' + 90 + ',' + positionX + ',' + positionY + ')';\n break;\n case 'Custom':\n positionX = this.titleStyle.x;\n positionY = this.titleStyle.y;\n getAnchor = 'middle';\n break;\n }\n var borderOptions = {\n 'id': this.element.id + '_ChartTitleBorder',\n 'x': positionX - (getAnchor === 'middle' ? (elementSize.width / 2) + elementSpacing : getAnchor === 'end' ? elementSize.width + elementSpacing : elementSpacing),\n 'y': positionY - elementSize.height + (elementSize.height / 4),\n 'rx': this.titleStyle.border.cornerRadius,\n 'ry': this.titleStyle.border.cornerRadius,\n 'width': elementSize.width + (elementSpacing * 2),\n 'height': elementSize.height * this.titleCollection.length,\n 'fill': this.titleStyle.background,\n 'stroke-width': borderWidth,\n 'stroke': this.titleStyle.border.color,\n 'transform': rotation ? rotation : '',\n 'd': ''\n };\n var htmlObject = redrawElement(this.redraw, this.element.id + '_ChartTitleBorder', borderOptions, this.renderer)\n || this.renderer.drawRectangle(borderOptions);\n appendChildElement(this.enableCanvas, this.svgObject, htmlObject, this.redraw);\n var options = new TextOption(this.element.id + '_ChartTitle', positionX, positionY, getAnchor, this.titleCollection, rotation, 'auto');\n var element = redrawElement(this.redraw, this.element.id + '_ChartTitle', options, this.renderer) ||\n textElement(this.renderer, options, this.titleStyle, this.titleStyle.color || this.themeStyle.chartTitleFont.color, this.svgObject, null, null, null, null, null, null, null, null, this.enableCanvas, null, this.themeStyle.chartTitleFont);\n if (element) {\n element.setAttribute('tabindex', '0');\n element.setAttribute('class', 'e-chart-focused');\n }\n if (this.subTitle) {\n this.renderSubTitle(options);\n }\n }\n };\n Chart.prototype.renderSubTitle = function (options) {\n var maxWidth = 0;\n var titleWidth = 0;\n var padding = 10;\n var alignment = this.titleStyle.textAlignment;\n for (var _i = 0, _a = this.titleCollection; _i < _a.length; _i++) {\n var titleText = _a[_i];\n titleWidth = measureText(titleText, this.titleStyle, this.themeStyle.chartSubTitleFont).width;\n maxWidth = titleWidth > maxWidth ? titleWidth : maxWidth;\n }\n var subTitleElementSize = measureText(this.subTitleCollection.reduce(function (a, b) { return (a.length > b.length ? a : b); }), this.subTitleStyle, this.themeStyle.chartSubTitleFont);\n var getAnchor = getTextAnchor(this.subTitleStyle.textAlignment, this.enableRtl);\n var rect = new Rect(alignment === 'Center' ? (options.x - maxWidth * 0.5) : alignment === 'Far' ? options.x - maxWidth : options.x, 0, maxWidth, 0);\n if (this.titleStyle.position === 'Left') {\n rect.x = alignment === 'Center' ? (options.x - maxWidth * 0.5) : alignment == 'Far' ? this.margin.left + ((subTitleElementSize.height) * 3 / 4) : (options.x - maxWidth);\n }\n var elementSize = measureText(this.title, this.titleStyle, this.themeStyle.chartTitleFont);\n var positionY = options.y * options.text.length + subTitleElementSize.height + (padding / 2) + this.titleStyle.border.width + (this.subTitleStyle.border.width * 0.5);\n if (this.titleStyle.position === 'Bottom') {\n positionY = options.y * options.text.length + (padding / 2) + (elementSize.height / 2) + (subTitleElementSize.height / 2);\n }\n var borderOptions = {\n 'id': this.element.id + '_ChartSubTitleBorder',\n 'x': titlePositionX(rect, this.subTitleStyle) - (getAnchor === 'middle' ? (subTitleElementSize.width / 2) + padding / 2 : getAnchor === 'end' ? subTitleElementSize.width + padding / 2 : padding / 2),\n 'y': positionY - subTitleElementSize.height + (subTitleElementSize.height / 4),\n 'rx': this.subTitleStyle.border.cornerRadius,\n 'ry': this.subTitleStyle.border.cornerRadius,\n 'width': subTitleElementSize.width + padding,\n 'height': subTitleElementSize.height * this.subTitleCollection.length,\n 'fill': this.subTitleStyle.background,\n 'stroke-width': this.subTitleStyle.border.width,\n 'stroke': this.subTitleStyle.border.color,\n 'transform': options.transform,\n 'd': ''\n };\n var htmlObject = redrawElement(this.redraw, this.element.id + '_ChartSubTitleBorder', borderOptions, this.renderer)\n || this.renderer.drawRectangle(borderOptions);\n appendChildElement(this.enableCanvas, this.svgObject, htmlObject, this.redraw);\n var subTitleOptions = new TextOption(this.element.id + '_ChartSubTitle', titlePositionX(rect, this.subTitleStyle), positionY, getTextAnchor(this.subTitleStyle.textAlignment, this.enableRtl), this.subTitleCollection, options.transform, 'auto');\n var element = redrawElement(this.redraw, this.element.id + '_ChartSubTitle', subTitleOptions, this.renderer) ||\n textElement(this.renderer, subTitleOptions, this.subTitleStyle, this.subTitleStyle.color || this.themeStyle.chartSubTitleFont.color, this.svgObject, null, null, null, null, null, null, null, null, this.enableCanvas, null, this.themeStyle.chartSubTitleFont);\n };\n Chart.prototype.renderBorder = function () {\n var x = 0;\n var y = 0;\n var width = this.border.width;\n var backGroundImage = this.backgroundImage;\n var fillColor = backGroundImage ? 'transparent' : (this.background || this.themeStyle.background);\n if (this.stockChart && this.stockChart.legendSettings.visible && this.stockChart.stockLegendModule) {\n if (this.stockChart.legendSettings.position === 'Top') {\n y += this.stockChart.stockLegendModule.legendBounds.height;\n }\n else if (this.stockChart.legendSettings.position === 'Left') {\n x += this.stockChart.stockLegendModule.legendBounds.width;\n }\n }\n var rect = new RectOption(this.element.id + '_ChartBorder', fillColor, this.border, 1, new Rect(width * 0.5 + x, width * 0.5 + y, this.availableSize.width - width, this.availableSize.height - width));\n this.htmlObject = redrawElement(this.redraw, this.element.id + '_ChartBorder', rect, this.renderer)\n || this.renderer.drawRectangle(rect);\n this.htmlObject.setAttribute('aria-hidden', 'true');\n appendChildElement(this.enableCanvas, this.svgObject, this.htmlObject, this.redraw);\n // to draw back ground image for chart\n if (backGroundImage) {\n var image = new ImageOption(this.availableSize.height - width, this.availableSize.width - width, backGroundImage, 0, 0, this.element.id + '_ChartBackground', 'visible', 'none');\n this.htmlObject = redrawElement(this.redraw, this.element.id + '_ChartBackground', image, this.renderer)\n || this.renderer.drawImage(image);\n appendChildElement(this.enableCanvas, this.svgObject, this.htmlObject, this.redraw);\n }\n };\n /**\n * @private\n */\n Chart.prototype.renderAreaBorder = function () {\n if (this.chartAreaType === 'PolarRadar') {\n return null;\n }\n else {\n var element = getElement(this.element.id + '_ChartAreaBorder');\n var previousRect = element ?\n new Rect(+element.getAttribute('x'), +element.getAttribute('y'), +element.getAttribute('width'), +element.getAttribute('height')) : null;\n var rect = new RectOption(this.element.id + '_ChartAreaBorder', this.chartArea.background, { width: this.chartArea.border.width, color: this.chartArea.border.color || this.themeStyle.areaBorder }, this.chartArea.opacity, this.chartAxisLayoutPanel.seriesClipRect);\n this.htmlObject = this.renderer.drawRectangle(rect);\n this.htmlObject.setAttribute('aria-hidden', 'true');\n appendChildElement(this.enableCanvas, this.svgObject, this.htmlObject, this.redraw, true, 'x', 'y', null, null, true, true, previousRect);\n this.htmlObject = null;\n }\n // to draw back ground image for chart area\n var backGroundImage = this.chartArea.backgroundImage;\n if (backGroundImage) {\n var width = this.chartArea.border.width;\n var image = new ImageOption(this.initialClipRect.height - width, this.initialClipRect.width - width, backGroundImage, this.initialClipRect.x, this.initialClipRect.y, this.element.id + '_ChartAreaBackground', 'visible', 'none');\n this.htmlObject = this.renderer.drawImage(image);\n appendChildElement(this.enableCanvas, this.svgObject, this.htmlObject, this.redraw, true, 'x', 'y', null, null, true, true);\n }\n };\n /**\n * To add series for the chart\n *\n * @param {SeriesModel[]} seriesCollection - Defines the series collection to be added in chart.\n * @returns {void}.\n */\n Chart.prototype.addSeries = function (seriesCollection) {\n for (var _i = 0, seriesCollection_1 = seriesCollection; _i < seriesCollection_1.length; _i++) {\n var series = seriesCollection_1[_i];\n series = new Series(this, 'series', series);\n this.series.push(series);\n }\n this.refresh();\n };\n /**\n * To Remove series for the chart\n *\n * @param {number} index - Defines the series index to be remove in chart series\n * @returns {void}\n */\n Chart.prototype.removeSeries = function (index) {\n this.redraw = false; //fix for remove svg not working when use animatemethod.\n if (this.visibleSeries[index]) {\n this.visibleSeries[index].xAxis.orientation = null;\n this.visibleSeries[index].yAxis.orientation = null;\n }\n for (var i = 0; i < this.axes.length; i++) {\n if (this.axes[i].orientation === null) {\n this.axes.splice(i, 1);\n }\n }\n this.series.splice(index, 1);\n this.refresh();\n };\n /**\n * To Clear all series for the chart\n *\n * @returns {void}.\n */\n Chart.prototype.clearSeries = function () {\n this.series = [];\n this.refresh();\n };\n /**\n * To add secondary axis for the chart\n *\n * @param {AxisModel[]} axisCollection - Defines the axis collection to be added in chart.\n * @returns {void}.\n */\n Chart.prototype.addAxes = function (axisCollection) {\n for (var _i = 0, axisCollection_1 = axisCollection; _i < axisCollection_1.length; _i++) {\n var axis = axisCollection_1[_i];\n axis = new Axis(this, 'axes', axis);\n if (this.isBlazor) {\n axis.interval = isNaN(axis.interval) ? null : axis.interval;\n axis.desiredIntervals = isNaN(axis.desiredIntervals) ? null : axis.desiredIntervals;\n }\n this.axes.push(axis);\n }\n this.refresh();\n };\n /**\n * To remove secondary axis for the chart\n *\n * @param {number} index - Defines the axis collection to be removed in chart.\n * @returns {void}\n */\n Chart.prototype.removeAxis = function (index) {\n this.redraw = false;\n this.axes.splice(index, 1);\n this.refresh();\n };\n /**\n * To destroy the widget\n *\n * @function destroy\n * @returns {void}.\n * @member of Chart\n */\n Chart.prototype.destroy = function () {\n if (this.scrollBarModule) {\n this.scrollBarModule.destroy();\n }\n if (this.markerRender) {\n this.markerRender.removeEventListener();\n this.markerRender = null;\n }\n this.horizontalAxes = [];\n this.verticalAxes = [];\n this.visibleSeries = [];\n this.axisCollections = [];\n this.rotatedDataLabelCollections = [];\n this.seriesElements = null;\n this.chartAxisLayoutPanel = null;\n this.dataLabelCollections = null;\n this.dataLabelElements = null;\n this.yAxisElements = null;\n var element = document.getElementById(this.element.id + 'Keyboard_chart_focus');\n if (element) {\n element.remove();\n }\n var highlightElement = document.getElementById(this.element.id + '_ej2_chart_highlight');\n if (highlightElement) {\n highlightElement.remove();\n }\n removeElement('chartmeasuretext');\n /**\n * To fix react timeout destroy issue.\n */\n if (this.element) {\n this.unWireEvents();\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this.isReact) {\n this.clearTemplate();\n }\n _super.prototype.destroy.call(this);\n if (!this.enableCanvas) {\n this.removeSvg();\n this.svgObject = null;\n }\n }\n };\n /**\n * Get component name\n */\n Chart.prototype.getModuleName = function () {\n return 'chart';\n };\n /**\n * Get the properties to be maintained in the persisted state.\n *\n * @private\n */\n Chart.prototype.getPersistData = function () {\n var keyEntity = ['loaded', 'animationComplete', 'primaryXAxis', 'primaryYAxis'];\n return this.addOnPersist(keyEntity);\n };\n /**\n * Method to create SVG element.\n */\n Chart.prototype.createChartSvg = function () {\n this.removeSvg();\n createSvg(this);\n };\n /**\n * Method to bind events for chart\n */\n Chart.prototype.unWireEvents = function () {\n var startEvent = Browser.touchStartEvent;\n var moveEvent = Browser.touchMoveEvent;\n var stopEvent = Browser.touchEndEvent;\n var cancelEvent = Browser.isPointer ? 'pointerleave' : 'mouseleave';\n /*! UnBind the Event handler */\n EventHandler.remove(this.element, startEvent, this.chartOnMouseDown);\n EventHandler.remove(this.element, moveEvent, this.mouseMove);\n EventHandler.remove(this.element, stopEvent, this.mouseEnd);\n EventHandler.remove(this.element, 'click', this.chartOnMouseClick);\n EventHandler.remove(this.element, 'dblclick', this.chartOnDoubleClick);\n EventHandler.remove(this.element, 'contextmenu', this.chartRightClick);\n EventHandler.remove(this.element, cancelEvent, this.mouseLeave);\n EventHandler.remove(this.element, 'keydown', this.chartKeyDown);\n EventHandler.remove(document.body, 'keydown', this.documentKeyHandler);\n EventHandler.remove(this.element, 'keyup', this.chartKeyUp);\n window.removeEventListener((Browser.isTouch && ('orientation' in window && 'onorientationchange' in window)) ? 'orientationchange' : 'resize', this.resizeBound);\n /**\n * To fix memory issue\n */\n if (this.touchObject) {\n this.touchObject.destroy();\n this.touchObject = null;\n }\n };\n Chart.prototype.wireEvents = function () {\n /**\n * To fix react timeout destroy issue.\n */\n if (!this.element) {\n return;\n }\n /*! Find the Events type */\n var cancelEvent = Browser.isPointer ? 'pointerleave' : 'mouseleave';\n /*! Bind the Event handler */\n EventHandler.add(this.element, Browser.touchStartEvent, this.chartOnMouseDown, this);\n EventHandler.add(this.element, Browser.touchMoveEvent, this.mouseMove, this);\n EventHandler.add(this.element, Browser.touchEndEvent, this.mouseEnd, this);\n EventHandler.add(this.element, 'click', this.chartOnMouseClick, this);\n EventHandler.add(this.element, 'dblclick', this.chartOnDoubleClick, this);\n EventHandler.add(this.element, 'contextmenu', this.chartRightClick, this);\n EventHandler.add(this.element, cancelEvent, this.mouseLeave, this);\n EventHandler.add(this.element, 'keydown', this.chartKeyDown, this);\n EventHandler.add(document.body, 'keydown', this.documentKeyHandler, this);\n EventHandler.add(this.element, 'keyup', this.chartKeyUp, this);\n this.resizeBound = this.chartResize.bind(this);\n window.addEventListener((Browser.isTouch && ('orientation' in window && 'onorientationchange' in window)) ? 'orientationchange' : 'resize', this.resizeBound);\n this.longPressBound = this.longPress.bind(this);\n this.touchObject = new Touch(this.element, { tapHold: this.longPressBound, tapHoldThreshold: 500 });\n /*! Apply the style for chart */\n this.setStyle(this.element);\n };\n Chart.prototype.chartRightClick = function (event) {\n if (this.crosshair.enable && this.crosshairModule &&\n (event.buttons === 2 || event.which === 0 || event.pointerType === 'touch')) {\n event.preventDefault();\n event.stopPropagation();\n return false;\n }\n return true;\n };\n Chart.prototype.setStyle = function (element) {\n var zooming = this.zoomSettings;\n var disableScroll = zooming.enableSelectionZooming || zooming.enablePinchZooming ||\n this.selectionMode !== 'None' || this.crosshair.enable || this.highlightMode !== 'None';\n element.style.touchAction = disableScroll ? 'none' : 'element';\n element.style.msTouchAction = disableScroll ? 'none' : 'element';\n element.style.msContentZooming = 'none';\n element.style.msUserSelect = 'none';\n element.style.webkitUserSelect = 'none';\n element.style.position = 'relative';\n element.style.display = 'block';\n // To fix angular and react tooltip div scrollbar issue\n element.style.overflow = 'hidden';\n element.style.height = (element.style.height || (this.height && this.height.indexOf('%') === -1)) ? element.style.height : 'inherit';\n };\n /**\n * Finds the orientation.\n *\n * @returns {boolean}\n * @private\n */\n Chart.prototype.isOrientation = function () {\n return ('orientation' in window && 'onorientationchange' in window);\n };\n /**\n * Handles the long press on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.longPress = function (e) {\n this.mouseX = (e && e.originalEvent.changedTouches) ? (e.originalEvent.changedTouches[0].clientX) : 0;\n this.mouseY = (e && e.originalEvent.changedTouches) ? (e.originalEvent.changedTouches[0].clientY) : 0;\n this.startMove = true;\n this.allowPan = this.stockChart ? false : this.allowPan;\n this.setMouseXY(this.mouseX, this.mouseY);\n this.notify('tapHold', e);\n return false;\n };\n /**\n * To find mouse x, y for aligned chart element svg position\n */\n Chart.prototype.setMouseXY = function (pageX, pageY) {\n if (getElement(this.svgId)) {\n var svgRect = getElement(this.svgId).getBoundingClientRect();\n var rect = this.element.getBoundingClientRect();\n this.mouseY = ((pageY - rect.top) - Math.max(svgRect.top - rect.top, 0) / this.scaleX);\n this.mouseX = ((pageX - rect.left) - Math.max(svgRect.left - rect.left, 0) / this.scaleY);\n if (this.stockChart) {\n this.mouseX += this.stockChart.legendSettings.position === 'Left' ? this.stockChart.stockLegendModule.legendBounds.width : 0;\n this.mouseY += this.stockChart.legendSettings.position === 'Top' ? this.stockChart.stockLegendModule.legendBounds.height : 0;\n }\n }\n };\n /**\n * Export method for the chart.\n */\n Chart.prototype.export = function (type, fileName) {\n if (this.exportModule) {\n this.exportModule.export(type, fileName);\n if (this.afterExport) {\n this.exportModule.getDataUrl(this);\n }\n }\n };\n /**\n * Handles the chart resize.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartResize = function () {\n var _this = this;\n this.animateSeries = false;\n var arg = {\n chart: this,\n name: resized,\n currentSize: new Size(0, 0),\n previousSize: new Size(this.availableSize.width, this.availableSize.height)\n };\n var beforeResizeArgs = { name: 'beforeResize', cancelResizedEvent: false };\n if (this.resizeTo) {\n clearTimeout(this.resizeTo);\n }\n this.trigger(beforeResize, beforeResizeArgs);\n if (!beforeResizeArgs.cancelResizedEvent) {\n this.resizeTo = +setTimeout(function () {\n if (_this.isDestroyed || _this.stockChart) {\n clearTimeout(_this.resizeTo);\n return;\n }\n _this.createChartSvg();\n arg.currentSize = _this.availableSize;\n _this.trigger(resized, arg);\n _this.refreshAxis();\n _this.refreshBound();\n _this.trigger('loaded', { chart: _this.isBlazor ? {} : _this });\n }, 500);\n }\n return false;\n };\n /**\n * Handles the mouse move.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.mouseMove = function (e) {\n var pageX;\n var pageY;\n var touchArg;\n if (this.allowPan) {\n return false;\n }\n if (e.type === 'touchmove') {\n this.isTouch = true;\n touchArg = e;\n pageX = touchArg.changedTouches[0].clientX;\n pageY = touchArg.changedTouches[0].clientY;\n }\n else {\n this.isTouch = e.pointerType === 'touch' || e.pointerType === '2' || this.isTouch;\n pageX = e.clientX;\n pageY = e.clientY;\n }\n this.previousPageX = pageX;\n this.previousPageY = pageY;\n if (getElement(this.svgId)) {\n this.setMouseXY(pageX, pageY);\n this.chartOnMouseMove(e);\n }\n return false;\n };\n /**\n * Handles the mouse leave.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.mouseLeave = function (e) {\n var pageX;\n var pageY;\n var touchArg;\n if (this.stockChart && this.stockChart.onPanning) {\n return false;\n }\n if (e.type === 'touchleave') {\n this.isTouch = true;\n touchArg = e;\n pageX = touchArg.changedTouches[0].clientX;\n pageY = touchArg.changedTouches[0].clientY;\n }\n else {\n this.isTouch = e.pointerType === 'touch' || e.pointerType === '2';\n pageX = e.clientX;\n pageY = e.clientY;\n }\n this.previousPageX = null;\n this.previousPageY = null;\n this.setMouseXY(pageX, pageY);\n this.chartOnMouseLeave(e);\n return false;\n };\n /**\n * Handles the mouse leave on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartOnMouseLeave = function (e) {\n var element = e.target;\n var cancelEvent = Browser.isPointer ? 'pointerleave' : 'mouseleave';\n this.trigger(chartMouseLeave, { target: element.id, x: this.mouseX, y: this.mouseY });\n removeElement(this.element.id + '_EJ2_AxisLabel_Tooltip');\n this.isChartDrag = this.isPointMouseDown = false;\n this.notify(cancelEvent, e);\n return false;\n };\n /**\n * Handles the mouse double click on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartOnDoubleClick = function (e) {\n var element = e.target;\n this.trigger(chartDoubleClick, { target: element.id, x: this.mouseX, y: this.mouseY });\n return false;\n };\n /**\n * Handles the keyboard onkeydown on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartKeyDown = function (e) {\n var actionKey = '';\n if ((this.isZoomed && e.code === 'Tab') || e.code === 'Space') {\n e.preventDefault();\n }\n if (this.tooltip.enable && ((e.code === 'Tab' && this.previousTargetId.indexOf('Series') > -1) || e.code === 'Escape')) {\n actionKey = 'ESC';\n }\n if (this.highlightMode !== 'None' && e.code === 'Tab' && this.previousTargetId.indexOf('_chart_legend_') > -1) {\n if (this.highlightModule) {\n this.highlightModule.removeLegendHighlightStyles();\n }\n }\n if (e.ctrlKey && (e.key === '+' || e.code === 'Equal' || e.key === '-' || e.code === 'Minus')) {\n e.preventDefault();\n this.isZoomed = this.zoomModule && (this.zoomSettings.enableDeferredZooming || this.zoomSettings.enableSelectionZooming ||\n this.zoomSettings.enablePinchZooming || this.zoomSettings.enableMouseWheelZooming);\n //this.tooltipModule.fadeOut(this.element);\n actionKey = this.isZoomed ? e.code : '';\n }\n else if (e['keyCode'] === 82 && this.isZoomed) { // KeyCode 82 (R) for reseting\n e.preventDefault();\n this.isZoomed = false;\n actionKey = 'R';\n }\n else if (e.code.indexOf('Arrow') > -1) {\n e.preventDefault();\n actionKey = this.isZoomed ? e.code : '';\n }\n if (e.ctrlKey && (e.key === 'p')) {\n e.preventDefault();\n actionKey = 'CtrlP';\n }\n if (actionKey !== '')\n this.chartKeyboardNavigations(e, e.target.id, actionKey);\n return false;\n };\n /**\n * Handles the keyboard onkeydown on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartKeyUp = function (e) {\n var actionKey = '';\n var targetId = e.target['id'];\n var groupElement;\n var markerGroup;\n var targetElement = e.target;\n var titleElement = getElement(this.element.id + '_ChartTitle');\n var seriesElement = getElement(this.element.id + 'SeriesCollection');\n var legendElement = getElement(this.element.id + '_chart_legend_translate_g');\n var pagingElement = getElement(this.element.id + '_chart_legend_pageup');\n if (titleElement) {\n titleElement.setAttribute('class', 'e-chart-focused');\n }\n if (seriesElement && seriesElement.firstElementChild && seriesElement.firstElementChild.children[1]) {\n var firstChild = seriesElement.firstElementChild.children[1];\n var className = firstChild.getAttribute('class');\n if (className && className.indexOf('e-chart-focused') === -1) {\n className = className + ' e-chart-focused';\n }\n else if (!className) {\n className = 'e-chart-focused';\n }\n firstChild.setAttribute('class', className);\n }\n if (legendElement) {\n var firstChild = legendElement.firstElementChild;\n var className = firstChild.getAttribute('class');\n if (className && className.indexOf('e-chart-focused') === -1) {\n className = className + ' e-chart-focused';\n }\n else if (!className) {\n className = 'e-chart-focused';\n }\n firstChild.setAttribute('class', className);\n }\n if (pagingElement) {\n pagingElement.setAttribute('class', 'e-chart-focused');\n }\n if (e.code === 'Tab') {\n if (this.previousTargetId !== '') {\n if ((this.previousTargetId.indexOf('_Series_') > -1 && targetId.indexOf('_Series_') === -1)) {\n groupElement = getElement(this.element.id + 'SeriesCollection');\n var previousElement = this.previousTargetId.indexOf('_Symbol') > -1 ?\n getElement(this.element.id + 'SymbolGroup' + this.currentSeriesIndex).children[this.currentPointIndex + 1] :\n (this.previousTargetId.indexOf('_Point_') > -1 ?\n groupElement.children[this.currentSeriesIndex].children[this.currentPointIndex + 1] :\n groupElement.children[this.currentSeriesIndex]);\n this.setTabIndex(previousElement, groupElement.firstElementChild);\n this.currentPointIndex = 0;\n this.currentSeriesIndex = 0;\n }\n else if (this.previousTargetId.indexOf('_chart_legend_page') > -1 && targetId.indexOf('_chart_legend_page') === -1\n && targetId.indexOf('_chart_legend_g_') === -1) {\n this.setTabIndex(e.target, getElement(this.element.id + '_chart_legend_pageup'));\n }\n else if (this.previousTargetId.indexOf('_chart_legend_g_') > -1 && targetId.indexOf('_chart_legend_g_') === -1) {\n groupElement = getElement(this.element.id + '_chart_legend_translate_g');\n this.setTabIndex(groupElement.children[this.currentLegendIndex], groupElement.firstElementChild);\n }\n }\n this.previousTargetId = targetId;\n if (targetId.indexOf('SeriesGroup') > -1) {\n this.currentSeriesIndex = +targetId.split('SeriesGroup')[1];\n targetElement.removeAttribute('tabindex');\n targetElement.blur();\n if (targetElement.children[1].id.indexOf('_Point_') === -1) {\n markerGroup = getElement(this.element.id + 'SymbolGroup' + targetId.split('SeriesGroup')[1]);\n }\n targetId = this.focusChild((markerGroup != null ? markerGroup.children[1] : targetElement.children[1]));\n }\n actionKey = this.highlightMode !== 'None' || this.tooltip.enable ? 'Tab' : '';\n }\n else if (e.code.indexOf('Arrow') > -1) {\n e.preventDefault();\n this.previousTargetId = targetId;\n if (targetId.indexOf('_chart_legend_page') > -1) {\n if (e.code === 'ArrowLeft') {\n getElement(this.element.id + '_chart_legend_pagedown').removeAttribute('tabindex');\n this.focusChild(getElement(this.element.id + '_chart_legend_pageup'));\n }\n else if (e.code === 'ArrowRight') {\n getElement(this.element.id + '_chart_legend_pageup').removeAttribute('tabindex');\n this.focusChild(getElement(this.element.id + '_chart_legend_pagedown'));\n }\n }\n else if ((targetId.indexOf('_chart_legend_') > -1)) {\n var legendElement_1 = targetElement.parentElement.children;\n legendElement_1[this.currentLegendIndex].removeAttribute('tabindex');\n this.currentLegendIndex += (e.code === 'ArrowUp' || e.code === 'ArrowRight') ? +1 : -1;\n this.currentLegendIndex = this.getActualIndex(this.currentLegendIndex, legendElement_1.length);\n var currentLegend = legendElement_1[this.currentLegendIndex];\n this.focusChild(currentLegend);\n targetId = currentLegend.children[1].id;\n actionKey = this.highlightMode !== 'None' ? 'ArrowMove' : '';\n }\n else if (targetId.indexOf('_Series_') > -1) {\n groupElement = targetElement.parentElement.parentElement;\n var currentPoint = e.target;\n targetElement.removeAttribute('tabindex');\n targetElement.blur();\n if (e.code === 'ArrowRight' || e.code === 'ArrowLeft') {\n var seriesIndexes = [];\n for (var i = 0; i < groupElement.children.length; i++) {\n if (groupElement.children[i].id.indexOf('SeriesGroup') > -1) {\n seriesIndexes.push(+groupElement.children[i].id.split('SeriesGroup')[1]);\n }\n }\n this.currentSeriesIndex = seriesIndexes.indexOf(this.currentSeriesIndex) + (e.code === 'ArrowRight' ? 1 : -1);\n this.currentSeriesIndex = seriesIndexes[this.getActualIndex(this.currentSeriesIndex, seriesIndexes.length)];\n }\n else {\n this.currentPointIndex += e.code === 'ArrowUp' ? 1 : -1;\n }\n if (targetId.indexOf('_Symbol') > -1) {\n this.currentPointIndex = this.getActualIndex(this.currentPointIndex, getElement(this.element.id + 'SymbolGroup' + this.currentSeriesIndex).childElementCount - 1);\n currentPoint = getElement(this.element.id + '_Series_' + this.currentSeriesIndex + '_Point_' +\n this.currentPointIndex + '_Symbol');\n }\n else if (targetId.indexOf('_Point_') > -1) {\n this.currentPointIndex = this.getActualIndex(this.currentPointIndex, getElement(this.element.id + 'SeriesGroup' + this.currentSeriesIndex).childElementCount - 1);\n currentPoint = getElement(this.element.id + '_Series_' + this.currentSeriesIndex + '_Point_' +\n this.currentPointIndex);\n }\n targetId = this.focusChild(currentPoint);\n actionKey = this.tooltip.enable || this.highlightMode !== 'None' ? 'ArrowMove' : '';\n }\n }\n else if ((e.code === 'Enter' || e.code === 'Space') && ((targetId.indexOf('_chart_legend_') > -1) ||\n (targetId.indexOf('_Point_') > -1))) {\n targetId = (targetId.indexOf('_chart_legend_page') > -1) ? targetId : ((targetId.indexOf('_chart_legend_') > -1) ?\n targetElement.children[1].id : targetId);\n actionKey = 'Enter';\n }\n if (actionKey !== '') {\n this.chartKeyboardNavigations(e, targetId, actionKey);\n }\n return false;\n };\n Chart.prototype.setTabIndex = function (previousElement, currentElement) {\n if (previousElement) {\n previousElement.removeAttribute('tabindex');\n }\n if (currentElement) {\n currentElement.setAttribute('tabindex', '0');\n }\n };\n Chart.prototype.getActualIndex = function (index, totalLength) {\n return index > totalLength - 1 ? 0 : (index < 0 ? totalLength - 1 : index);\n };\n Chart.prototype.focusChild = function (element) {\n element.setAttribute('tabindex', '0');\n var className = element.getAttribute('class');\n element.setAttribute('tabindex', '0');\n if (className && className.indexOf('e-chart-focused') === -1) {\n className = 'e-chart-focused ' + className;\n }\n else if (!className) {\n className = 'e-chart-focused';\n }\n element.setAttribute('class', className);\n element.focus();\n return element.id;\n };\n /**\n * Handles the document onkey.\n *\n * @private\n */\n Chart.prototype.documentKeyHandler = function (e) {\n // 74 - J\n if (e.altKey && e.keyCode === 74 && !isNullOrUndefined(this.element)) {\n this.element.focus();\n }\n };\n Chart.prototype.chartKeyboardNavigations = function (e, targetId, actionKey) {\n this.isLegendClicked = false;\n switch (actionKey) {\n case 'Tab':\n case 'ArrowMove':\n if (this.highlightModule) {\n this.highlightModule.removeLegendHighlightStyles();\n }\n if (targetId.indexOf('_Point_') > -1) {\n var seriesIndex = +(targetId.split('_Series_')[1].split('_Point_')[0]);\n var pointIndex = +(targetId.split('_Series_')[1].replace('_Symbol', '').split('_Point_')[1]);\n var pointRegion = this.visibleSeries[seriesIndex].points[pointIndex].symbolLocations[0];\n this.mouseX = pointRegion.x + this.initialClipRect.x;\n this.mouseY = pointRegion.y + this.initialClipRect.y;\n if (this.highlightModule) {\n this.highlightModule.highlightChart(document.getElementById(targetId), 'mousemove');\n this.highlightModule.completeSelection(document.getElementById(targetId), 'mousemove');\n }\n if (this.tooltipModule) {\n this.tooltipModule.tooltip();\n }\n }\n if (this.highlightModule && this.highlightMode !== 'None') {\n targetId = targetId.indexOf('_chart_legend_g_') > -1 ? document.getElementById(targetId).firstChild['id'] : targetId;\n var legendID = this.element.id + '_chart_legend';\n var legendItemsId = [legendID + '_text_', legendID + '_shape_marker_',\n legendID + '_shape_'];\n for (var i = 0; i < legendItemsId.length; i++) {\n var id = legendItemsId[i];\n if (targetId.indexOf(id) > -1) {\n document.getElementById(targetId).setAttribute('class', '');\n this.highlightModule.legendSelection(this, parseInt(targetId.split(id)[1], 10), document.getElementById(targetId), 'mousemove');\n break;\n }\n }\n }\n break;\n case 'Enter':\n case 'Space':\n if (targetId.indexOf('_chart_legend_') > -1) {\n this.isLegendClicked = true;\n this.legendModule.click(e);\n this.focusChild(document.getElementById(targetId).parentElement);\n }\n else {\n this.selectionModule.calculateSelectedElements(document.getElementById(targetId), 'click');\n }\n break;\n case 'CtrlP':\n this.print();\n break;\n case 'ESC':\n this.tooltipModule.removeTooltip(1);\n break;\n case 'Equal':\n case 'Minus':\n this.zoomModule.isZoomed = this.zoomModule.performedUI = true;\n this.zoomModule.isPanning = this.isChartDrag = false;\n if (actionKey === 'Equal') {\n this.zoomModule.toolkit.zoomInOutCalculation(1, this, this.axisCollections, this.zoomSettings.mode);\n }\n else {\n this.zoomModule.toolkit.zoomInOutCalculation(-1, this, this.axisCollections, this.zoomSettings.mode);\n }\n this.zoomModule.performZoomRedraw(this);\n this.element.focus();\n break;\n case 'ArrowUp':\n case 'ArrowDown':\n case 'ArrowLeft':\n case 'ArrowRight':\n var yArrowPadding = actionKey === 'ArrowUp' ? 10 : (actionKey === 'ArrowDown' ? -10 : 0);\n var xArrowPadding = actionKey === 'ArrowLeft' ? -10 : (actionKey === 'ArrowRight' ? 10 : 0);\n this.zoomModule.isPanning = this.isChartDrag = true;\n this.zoomModule.doPan(this, this.axisCollections, xArrowPadding, yArrowPadding);\n this.zoomModule.performZoomRedraw(this);\n this.element.focus();\n break;\n case 'R':\n this.zoomModule.toolkit.reset(e);\n break;\n }\n };\n /**\n * Handles the mouse click on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartOnMouseClick = function (e) {\n var _this = this;\n var element = e.target;\n var chart = this;\n this.clickCount++;\n var timeInterval = 400;\n if (this.clickCount === 1) {\n this.singleClickTimer = +setTimeout(function () {\n chart.clickCount = 0;\n chart.trigger(chartMouseClick, { target: element.id, x: chart.mouseX, y: chart.mouseY });\n }, timeInterval);\n }\n else if (this.clickCount === 2 && !this.pointDoubleClick) {\n clearTimeout(this.singleClickTimer);\n this.clickCount = 0;\n }\n var isAngular = 'isAngular';\n if (this[isAngular]) {\n var observers = 'observers';\n timeInterval = this.pointDoubleClick[observers].length > 0 ? 400 : 0;\n }\n else {\n timeInterval = this.pointDoubleClick ? 400 : 0;\n }\n if (this.clickCount === 1 && this.pointClick) {\n this.singleClickTimer = +setTimeout(function () {\n _this.clickCount = 0;\n _this.triggerPointEvent(pointClick, e);\n }, timeInterval);\n }\n else if (this.clickCount === 2 && this.pointDoubleClick) {\n clearTimeout(this.singleClickTimer);\n this.clickCount = 0;\n this.triggerPointEvent(pointDoubleClick, e);\n }\n if (this.axisLabelClick) {\n this.triggerAxisLabelClickEvent(axisLabelClick, e);\n }\n this.notify('click', e);\n return false;\n };\n Chart.prototype.triggerPointEvent = function (event, e) {\n var evt = e;\n var data = new ChartData(this);\n var pointData = data.getData();\n if (pointData.series && pointData.point) {\n this.trigger(event, {\n series: this.isBlazor ? {} : pointData.series,\n point: pointData.point,\n seriesIndex: pointData.series.index, pointIndex: pointData.point.index,\n x: this.mouseX, y: this.mouseY, pageX: evt.pageX, pageY: evt.pageY\n });\n }\n };\n Chart.prototype.triggerAxisLabelClickEvent = function (event, e) {\n var targetElement = e.target;\n var clickEvt = e;\n if (targetElement.id.indexOf('_AxisLabel_') !== -1) {\n var index = targetElement.id.split('_AxisLabel_');\n var axisIndex = +index[0].slice(-1);\n var labelIndex = +index[1];\n var currentAxis = this.axisCollections[axisIndex];\n if (currentAxis.visible && (axisIndex === 0 || axisIndex === 1)) {\n this.trigger(event, {\n chart: this,\n axis: currentAxis,\n text: currentAxis.visibleLabels[labelIndex].text,\n labelID: targetElement.id,\n index: labelIndex,\n location: new ChartLocation(clickEvt.pageX, clickEvt.pageY),\n value: currentAxis.visibleLabels[labelIndex].value\n });\n }\n }\n };\n /**\n * Handles the mouse move on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartOnMouseMove = function (e) {\n var element = e.target;\n this.trigger(chartMouseMove, { target: element.id, x: this.mouseX, y: this.mouseY });\n if (this.pointMove) {\n this.triggerPointEvent(pointMove, e);\n }\n // Tooltip for chart series.\n if (!this.isTouch) {\n this.titleTooltip(e, this.mouseX, this.mouseY);\n this.axisTooltip(e, this.mouseX, this.mouseY);\n }\n if (this.dataEditingModule) {\n this.dataEditingModule.pointMouseMove(e);\n }\n this.notify(Browser.touchMoveEvent, e);\n this.isTouch = false;\n return false;\n };\n Chart.prototype.titleTooltip = function (event, x, y, isTouch) {\n var targetId = event.target.id;\n var id = (targetId === (this.element.id + '_ChartTitle') || targetId === (this.element.id + '_ChartSubTitle') ||\n targetId.indexOf('_AxisTitle') > -1 || targetId.indexOf('_legend_title') > -1);\n var index = 0;\n if (targetId.indexOf('_AxisTitle') > -1) {\n index = parseInt(((targetId.replace(this.element.id, '')).replace('AxisLabel_', '')).split('_')[2], 10);\n }\n if (id && (event.target.textContent.indexOf('...') > -1)) {\n var title = (targetId === (this.element.id + '_ChartTitle')) ? this.title :\n targetId.indexOf('_AxisTitle') > -1 ? this.axisCollections[index].title :\n targetId.indexOf('_ChartSubTitle') > -1 ? this.subTitle : this.legendSettings.title;\n showTooltip(title, x, y, this.element.offsetWidth, this.element.id + '_EJ2_Title_Tooltip', getElement(this.element.id + '_Secondary_Element'), isTouch);\n }\n else {\n removeElement(this.element.id + '_EJ2_Title_Tooltip');\n }\n };\n Chart.prototype.axisTooltip = function (event, x, y, isTouch) {\n var targetId = event.target.id;\n if (((targetId.indexOf('AxisLabel') > -1) || targetId.indexOf('Axis_MultiLevelLabel') > -1) &&\n (event.target.textContent.indexOf('...') > -1)) {\n var isTitleOrLegendEnabled = (this.legendSettings.visible || this.primaryXAxis.title === '');\n showTooltip(this.findAxisLabel(targetId), x, y, this.element.offsetWidth, this.element.id + '_EJ2_AxisLabel_Tooltip', getElement(this.element.id + '_Secondary_Element'), isTouch, isTitleOrLegendEnabled);\n }\n else {\n removeElement(this.element.id + '_EJ2_AxisLabel_Tooltip');\n }\n };\n Chart.prototype.findAxisLabel = function (text) {\n var texts;\n if (text.indexOf('AxisLabel') > -1) {\n texts = ((text.replace(this.element.id, '')).replace('AxisLabel_', '')).split('_');\n return this.axisCollections[parseInt(texts[0], 10)].visibleLabels[parseInt(texts[1], 10)].originalText;\n }\n else {\n texts = ((text.replace(this.element.id, '')).replace('Axis_MultiLevelLabel_Level_', '').replace('Text_', '')).split('_');\n return (this.axisCollections[parseInt(texts[0], 10)].multiLevelLabels[parseInt(texts[1], 10)]\n .categories[parseInt(texts[2], 10)].text);\n }\n };\n /**\n * Handles the mouse down on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.chartOnMouseDown = function (e) {\n var pageX;\n var pageY;\n var target;\n var touchArg;\n var offset = Browser.isDevice ? 20 : 30;\n var rect = this.element.getBoundingClientRect();\n var element = e.target;\n if (this.stockChart && this.stockChart.zoomSettings.enablePan) {\n this.allowPan = true;\n }\n this.trigger(chartMouseDown, { target: element.id, x: this.mouseX, y: this.mouseY });\n if (e.type === 'touchstart') {\n this.isTouch = true;\n touchArg = e;\n pageX = touchArg.changedTouches[0].clientX;\n pageY = touchArg.changedTouches[0].clientY;\n target = touchArg.target;\n }\n else {\n this.isTouch = e.pointerType === 'touch';\n pageX = e.clientX;\n pageY = e.clientY;\n target = e.target;\n }\n var svgRect = getElement(this.svgId).getBoundingClientRect();\n this.mouseDownX = this.previousMouseMoveX = (pageX - rect.left) - Math.max(svgRect.left - rect.left, 0);\n this.mouseDownY = this.previousMouseMoveY = (pageY - rect.top) - Math.max(svgRect.top - rect.top, 0);\n if (this.isTouch) {\n this.isDoubleTap = (new Date().getTime() < this.threshold && target.id.indexOf(this.element.id + '_Zooming_') === -1 &&\n (this.mouseDownX - offset >= this.mouseX || this.mouseDownX + offset >= this.mouseX) &&\n (this.mouseDownY - offset >= this.mouseY || this.mouseDownY + offset >= this.mouseY) &&\n (this.mouseX - offset >= this.mouseDownX || this.mouseX + offset >= this.mouseDownX) &&\n (this.mouseY - offset >= this.mouseDownY || this.mouseY + offset >= this.mouseDownY));\n }\n if (this.dataEditingModule) {\n this.dataEditingModule.pointMouseDown();\n }\n this.notify(Browser.touchStartEvent, e);\n return false;\n };\n /**\n * Handles the mouse up.\n *\n * @returns {boolean} false\n * @private\n */\n Chart.prototype.mouseEnd = function (e) {\n var pageY;\n var pageX;\n var touchArg;\n if (e.type === 'touchend') {\n touchArg = e;\n pageX = touchArg.changedTouches[0].clientX;\n this.isTouch = true;\n pageY = touchArg.changedTouches[0].clientY;\n }\n else {\n pageY = e.clientY;\n pageX = e.clientX;\n this.isTouch = e.pointerType === 'touch' || e.pointerType === '2';\n }\n this.setMouseXY(pageX, pageY);\n this.chartOnMouseUp(e);\n return false;\n };\n /**\n * Handles the mouse up.\n *\n * @returns {boolean}\n * @private\n */\n Chart.prototype.chartOnMouseUp = function (e) {\n var element = e.target;\n this.trigger(chartMouseUp, { target: element.id, x: this.mouseX, y: this.mouseY });\n this.isChartDrag = false;\n this.allowPan = false;\n if (this.isTouch) {\n this.titleTooltip(e, this.mouseX, this.mouseY, this.isTouch);\n this.axisTooltip(e, this.mouseX, this.mouseY, this.isTouch);\n this.threshold = new Date().getTime() + 300;\n }\n if (this.dataEditingModule) {\n this.dataEditingModule.pointMouseUp();\n }\n if (!this.enableCanvas && this.seriesElements) {\n this.seriesElements.removeAttribute('clip-path');\n }\n this.notify(Browser.touchEndEvent, e);\n return false;\n };\n /**\n * Method to set culture for chart\n */\n Chart.prototype.setCulture = function () {\n this.intl = new Internationalization();\n this.setLocaleConstants();\n this.localeObject = new L10n(this.getModuleName(), this.defaultLocalConstants, this.locale);\n };\n /**\n * Method to set the annotation content dynamically for chart.\n */\n Chart.prototype.setAnnotationValue = function (annotationIndex, content) {\n var parentNode = getElement(this.element.id + '_Annotation_Collections');\n var annotation = this.annotations[annotationIndex];\n var element;\n if (content !== null) {\n annotation.content = content;\n if (parentNode) {\n removeElement(this.element.id + '_Annotation_' + annotationIndex);\n element = this.createElement('div');\n this.annotationModule.processAnnotation(annotation, annotationIndex, element);\n parentNode.appendChild(element.children[0]);\n }\n else {\n this.annotationModule.renderAnnotations(getElement(this.element.id + '_Secondary_Element'));\n }\n }\n };\n /**\n * Method to set locale constants\n */\n Chart.prototype.setLocaleConstants = function () {\n this.defaultLocalConstants = {\n ZoomIn: 'Zoom in',\n Zoom: 'Zoom',\n ZoomOut: 'Zoom out',\n Pan: 'Pan',\n Reset: 'Reset',\n ResetZoom: 'Reset Zoom'\n };\n };\n /**\n * Theming for chart\n */\n Chart.prototype.setTheme = function () {\n /*! Set theme */\n this.themeStyle = getThemeColor(this.theme, this.enableCanvas);\n if (!(document.getElementById(this.element.id + 'Keyboard_chart_focus'))) {\n var style = document.createElement('style');\n style.setAttribute('id', this.element.id + 'Keyboard_chart_focus');\n style.innerText = '.e-chart-focused:focus, path[class*=_ej2_chart_selection_series]:focus,' +\n 'path[id*=_Point_]:focus, text[id*=_ChartTitle]:focus {outline: none } .e-chart-focused:focus-visible, path[class*=_ej2_chart_selection_series]:focus-visible,' +\n 'path[id*=_Point_]:focus-visible, text[id*=_ChartTitle]:focus-visible {outline: 1.5px ' + this.themeStyle.tabColor + ' solid}';\n document.body.appendChild(style);\n }\n };\n /**\n * To provide the array of modules needed for control rendering\n *\n * @returns {ModuleDeclaration[]}\n * @private\n */\n /* eslint-disable */\n Chart.prototype.requiredModules = function () {\n var _this = this;\n var modules = [];\n var series = this.series;\n var enableAnnotation = false;\n var moduleName;\n var errorBarVisible = false;\n var isPointDrag = false;\n var dataLabelEnable = false;\n var zooming = this.zoomSettings;\n this.chartAreaType = (series.length > 0 && (series[0].type === 'Polar' || series[0].type === 'Radar')) ? 'PolarRadar' : 'Cartesian';\n if (this.tooltip.enable) {\n modules.push({\n member: 'Tooltip',\n args: [this]\n });\n }\n series.map(function (value) {\n _this.isLegend = (_this.legendSettings.visible && ((value.name !== '') || !!_this.isLegend));\n moduleName = value.type.indexOf('100') !== -1 ? value.type.replace('100', '') + 'Series' : value.type + 'Series';\n errorBarVisible = value.errorBar.visible || errorBarVisible;\n dataLabelEnable = value.marker.dataLabel.visible || dataLabelEnable || (value.type == 'Pareto' && value.paretoOptions.marker.dataLabel.visible);\n isPointDrag = value.dragSettings.enable || isPointDrag;\n if (!modules.some(function (currentModule) {\n return currentModule.member === moduleName;\n })) {\n modules.push({\n member: moduleName,\n args: [_this, series]\n });\n }\n if (_this.chartAreaType === 'PolarRadar') {\n modules.push({\n member: value.drawType + 'Series',\n args: [_this, series]\n });\n }\n if (value.type === 'Pareto') {\n modules.push({\n member: 'ColumnSeries',\n args: [_this, series]\n });\n modules.push({\n member: 'LineSeries',\n args: [_this, series]\n });\n }\n });\n this.findIndicatorModules(modules);\n this.findTrendLineModules(modules);\n modules = this.findAxisModule(modules);\n enableAnnotation = this.annotations.some(function (value) {\n return (value.content !== null);\n });\n if (errorBarVisible) {\n modules.push({\n member: 'ErrorBar',\n args: [this, series]\n });\n }\n if (this.isLegend) {\n modules.push({\n member: 'Legend',\n args: [this]\n });\n }\n if (this.enableExport || this.allowExport) {\n modules.push({\n member: 'Export',\n args: [this]\n });\n }\n if (this.chartAreaType !== 'PolarRadar' && this.crosshair.enable) {\n modules.push({\n member: 'Crosshair',\n args: [this]\n });\n }\n if (this.chartAreaType !== 'PolarRadar' && !this.scrollSettingEnabled && (zooming.enableSelectionZooming\n || zooming.enableMouseWheelZooming || zooming.enablePinchZooming || zooming.enablePan || zooming.enableScrollbar || zooming.showToolbar)) {\n modules.push({\n member: 'Zoom',\n args: [this, this.zoomSettings]\n });\n if (zooming.enableScrollbar) {\n modules.push({\n member: 'ScrollBar',\n args: [this]\n });\n }\n }\n if (this.selectionMode !== 'None' && !(this.chartAreaType === 'PolarRadar' &&\n this.selectionMode.indexOf('Drag') > -1)) {\n modules.push({\n member: 'Selection',\n args: [this]\n });\n }\n if (this.highlightMode !== 'None' || this.legendSettings.enableHighlight) {\n modules.push({\n member: 'Highlight',\n args: [this]\n });\n }\n if (dataLabelEnable) {\n modules.push({\n member: 'DataLabel',\n args: [this, series]\n });\n }\n if (isPointDrag) {\n modules.push({\n member: 'DataEditing',\n args: [this]\n });\n }\n if (enableAnnotation) {\n modules.push({\n member: 'Annotation',\n args: [this]\n });\n }\n return modules;\n };\n Chart.prototype.findAxisModule = function (modules) {\n var axisCollections = [];\n axisCollections.push(this.primaryXAxis);\n axisCollections.push(this.primaryYAxis);\n axisCollections = axisCollections.concat(this.axes);\n var datetimeEnabled = false;\n var categoryEnabled = false;\n var logarithmicEnabled = false;\n var striplineEnabled = false;\n var dateTimeCategoryEnabled = false;\n var multiLevelEnabled = false;\n for (var _i = 0, axisCollections_1 = axisCollections; _i < axisCollections_1.length; _i++) {\n var axis = axisCollections_1[_i];\n datetimeEnabled = axis.valueType === 'DateTime' || datetimeEnabled;\n categoryEnabled = axis.valueType === 'Category' || categoryEnabled;\n logarithmicEnabled = axis.valueType === 'Logarithmic' || logarithmicEnabled;\n dateTimeCategoryEnabled = axis.valueType === 'DateTimeCategory' || dateTimeCategoryEnabled;\n striplineEnabled = this.findStriplineVisibility(axis.stripLines) || striplineEnabled;\n multiLevelEnabled = axis.multiLevelLabels.length > 0 || multiLevelEnabled;\n this.scrollSettingEnabled = axis.scrollbarSettings.enable ? true : this.scrollSettingEnabled;\n }\n if (datetimeEnabled) {\n modules.push({\n member: 'DateTime',\n args: [this]\n });\n }\n if (categoryEnabled) {\n modules.push({\n member: 'Category',\n args: [this]\n });\n }\n if (logarithmicEnabled) {\n modules.push({\n member: 'Logarithmic',\n args: [this]\n });\n }\n if (striplineEnabled) {\n modules.push({\n member: 'StripLine',\n args: [this]\n });\n }\n if (multiLevelEnabled) {\n modules.push({\n member: 'MultiLevelLabel',\n args: [this]\n });\n }\n if (dateTimeCategoryEnabled) {\n modules.push({\n member: 'DateTimeCategory',\n args: [this]\n });\n }\n if (this.scrollSettingEnabled) {\n modules.push({\n member: 'ScrollBar',\n args: [this]\n });\n }\n return modules;\n };\n Chart.prototype.findIndicatorModules = function (modules) {\n var macdEnable;\n var bandEnable;\n var indicators = this.indicators;\n if (this.indicators.length) {\n modules.push({\n member: 'LineSeries',\n args: [this]\n });\n indicators.map(function (indicator) {\n macdEnable = macdEnable || indicator.type === 'Macd';\n bandEnable = bandEnable || indicator.type === 'BollingerBands';\n });\n if (macdEnable) {\n modules.push({\n member: 'ColumnSeries',\n args: [this]\n });\n }\n if (bandEnable) {\n modules.push({\n member: 'RangeAreaSeries',\n args: [this]\n });\n }\n if (bandEnable) {\n modules.push({\n member: 'SplineRangeAreaSeries',\n args: [this]\n });\n }\n for (var _i = 0, _a = this.indicators; _i < _a.length; _i++) {\n var indicator = _a[_i];\n modules.push({\n member: indicator.type + 'Indicator',\n args: [this]\n });\n }\n }\n };\n Chart.prototype.findTrendLineModules = function (modules) {\n var isLine;\n var isSpline;\n var _loop_1 = function (series) {\n var markerEnable;\n series.trendlines.map(function (trendline) {\n markerEnable = markerEnable || trendline.marker.visible;\n isLine = isLine || (trendline.type === 'Linear' || trendline.type === 'MovingAverage') ? true : false;\n isSpline = isSpline || (!isLine || (trendline.type === 'Exponential' || trendline.type === 'Logarithmic' || trendline.type === 'Power' || trendline.type === 'Polynomial')) ? true : false;\n });\n if (markerEnable) {\n modules.push({\n member: 'Marker',\n args: [this_1, series]\n });\n }\n };\n var this_1 = this;\n for (var _i = 0, _a = this.series; _i < _a.length; _i++) {\n var series = _a[_i];\n _loop_1(series);\n }\n if (isLine || isSpline) {\n modules.push({\n member: 'TrendLine',\n args: [this]\n });\n }\n if (isLine) {\n modules.push({\n member: 'LineSeries',\n args: [this]\n });\n }\n if (isSpline) {\n modules.push({\n member: 'SplineSeries',\n args: [this]\n });\n }\n };\n Chart.prototype.findStriplineVisibility = function (striplines) {\n var visible = false;\n for (var _i = 0, striplines_1 = striplines; _i < striplines_1.length; _i++) {\n var stripline = striplines_1[_i];\n if (stripline.visible) {\n visible = true;\n break;\n }\n }\n return visible;\n };\n /**\n * To Remove the SVG.\n * @return {boolean}\n * @private\n */\n Chart.prototype.removeSvg = function () {\n if (this.redraw) {\n return null;\n }\n blazorTemplatesReset(this);\n if (this.enableCanvas && this.svgObject && this.svgObject.tagName === 'CANVAS') {\n this.renderer.clearRect(new Rect(0, 0, this.availableSize.width, this.availableSize.height));\n if (this.svgObject.parentNode) {\n remove(this.svgObject);\n }\n return null;\n }\n removeElement(this.element.id + '_Secondary_Element');\n if (this.isReact) {\n this.clearTemplate();\n }\n var removeLength = 0;\n if (this.zoomModule && this.zoomModule.pinchTarget) {\n this.zoomModule.pinchTarget.id = '';\n this.zoomModule.pinchTarget.setAttribute('opacity', '0');\n this.svgObject.appendChild(this.zoomModule.pinchTarget);\n removeLength = 1;\n }\n // Fix for blazor resize issue\n if (!isNullOrUndefined(this.resizeTo)) {\n if (this.resizeTo !== this.checkResize && this.isBlazor && this.element.childElementCount) {\n var containerCollection = document.querySelectorAll('.e-chart');\n for (var index = 0; index < containerCollection.length; index++) {\n var container = containerCollection[index];\n while (container.firstChild) {\n remove(container.firstChild);\n }\n }\n }\n this.checkResize = this.resizeTo;\n }\n if (this.svgObject) {\n while (this.svgObject.childNodes.length > removeLength) {\n this.svgObject.removeChild(this.svgObject.firstChild);\n }\n if (!this.svgObject.hasChildNodes() && this.svgObject.parentNode && !(this.stockChart)) {\n remove(this.svgObject);\n }\n }\n };\n Chart.prototype.refreshDefinition = function (definitions) {\n for (var _i = 0, definitions_1 = definitions; _i < definitions_1.length; _i++) {\n var item = definitions_1[_i];\n item.axes = [];\n }\n };\n /**\n * Refresh the axis default value.\n *\n * @returns {boolean}\n * @private\n */\n Chart.prototype.refreshAxis = function () {\n var axis = this.primaryXAxis;\n axis.rect = new Rect(undefined, undefined, 0, 0);\n axis = this.primaryYAxis;\n axis.isStack100 = false;\n axis.rect = new Rect(undefined, undefined, 0, 0);\n for (var _i = 0, _a = this.axes; _i < _a.length; _i++) {\n var item = _a[_i];\n axis = item;\n axis.rect = new Rect(undefined, undefined, 0, 0);\n axis.isStack100 = false;\n }\n if (this.paretoSeriesModule && this.series[0].type === 'Pareto') {\n for (var _b = 0, _c = this.paretoSeriesModule.paretoAxes; _b < _c.length; _b++) {\n var item = _c[_b];\n axis = item;\n axis.rect = new Rect(undefined, undefined, 0, 0);\n axis.isStack100 = false;\n }\n }\n };\n Chart.prototype.axisChange = function (axis) {\n if (!axis.name && !axis.valueType) {\n return false;\n }\n this.refreshDefinition(this.columns);\n this.refreshDefinition(this.rows);\n this.calculateVisibleAxis();\n this.processData();\n return true;\n };\n /**\n * Get visible series by index\n */\n Chart.prototype.getVisibleSeries = function (visibleSeries, index) {\n for (var _i = 0, visibleSeries_1 = visibleSeries; _i < visibleSeries_1.length; _i++) {\n var series = visibleSeries_1[_i];\n if (index === series.index) {\n return series;\n }\n }\n return null;\n };\n /**\n * Fix for live data update flicker issue\n */\n Chart.prototype.refreshLiveData = function () {\n this.calculateVisibleSeries();\n this.initTechnicalIndicators();\n this.initTrendLines();\n this.refreshDefinition(this.columns);\n this.refreshDefinition(this.rows);\n this.calculateVisibleAxis();\n this.processData(false);\n if (!this.isBlazor) {\n this.enableCanvas ? this.createChartSvg() : this.removeSvg();\n this.refreshAxis();\n this.refreshBound();\n this.trigger('loaded', { chart: this.isBlazor ? {} : this });\n }\n };\n /**\n * To remove style element\n */\n Chart.prototype.removeStyles = function () {\n removeElement(this.element.id + '_ej2_chart_selection');\n removeElement(this.element.id + '_ej2_chart_highlight');\n };\n /**\n * To trigger the manual mouse move event for live chart tooltip\n */\n Chart.prototype.mouseMoveEvent = function () {\n if (this.tooltip.enable && this.previousPageX !== null && this.previousPageY !== null) {\n var mousemove = document.createEvent('MouseEvent');\n mousemove.initMouseEvent('mousemove', true, false, window, 1, 100, 100, this.previousPageX, this.previousPageY, false, false, false, false, 0, null);\n this.element.dispatchEvent(mousemove);\n }\n };\n /**\n * Displays a tooltip for the data points.\n *\n * @param {object} x - Specifies the x value of the point or x coordinate.\n * @param {number} y - Specifies the x value of the point or y coordinate.\n * @param {boolean} isPoint - Specifies whether x and y are data point or chart coordinates.\n * @returns {void}\n */\n Chart.prototype.showTooltip = function (x, y, isPoint) {\n if (isPoint === void 0) { isPoint = false; }\n if (isPoint) {\n for (var _i = 0, _a = this.visibleSeries; _i < _a.length; _i++) {\n var series = _a[_i];\n for (var _b = 0, _c = series.points; _b < _c.length; _b++) {\n var point = _c[_b];\n var pointX = series.xAxis.valueType == 'DateTime' ? point.xValue : point.x;\n var xValue = x;\n if (series.xAxis.valueType == 'DateTime') {\n xValue = new Date(xValue).getTime();\n }\n if (x == pointX && y === point.yValue) {\n this.mouseX = point.regions[0].x + this.chartAxisLayoutPanel.seriesClipRect.x;\n this.mouseY = point.regions[0].y + this.chartAxisLayoutPanel.seriesClipRect.y;\n this.tooltipModule.tooltip();\n this.markerRender.mouseMoveHandler();\n break;\n }\n }\n }\n }\n else {\n if (this.isTouch) {\n this.startMove = true;\n }\n this.mouseX = x;\n this.mouseY = y;\n this.tooltipModule.mouseMoveHandler();\n this.markerRender.mouseMoveHandler();\n }\n };\n /**\n * Hides a tooltip in the chart.\n *\n * @returns {void}\n */\n Chart.prototype.hideTooltip = function () {\n this.tooltipModule.removeTooltip(Browser.isDevice ? 2000 : 1000);\n };\n /**\n * Displays a crosshair for the chart.\n *\n * @param {object} x - Specifies the x value of the point or x coordinate.\n * @param {number} y - Specifies the x value of the point or y coordinate.\n * @returns {void}\n */\n Chart.prototype.showCrosshair = function (x, y) {\n this.mouseX = x;\n this.mouseY = y;\n this.isCrosshair = false;\n if (withInBounds(this.mouseX, this.mouseY, this.chartAxisLayoutPanel.seriesClipRect)) {\n this.crosshairModule.crosshair();\n }\n else {\n this.hideCrosshair();\n }\n this.isCrosshair = true;\n };\n /**\n * Hides a tooltip in the chart.\n *\n * @returns {void}\n */\n Chart.prototype.hideCrosshair = function () {\n this.crosshairModule.removeCrosshair(Browser.isDevice ? 2000 : 1000);\n };\n /**\n * Called internally if any of the property value changed.\n * @private\n */\n // tslint:disable-next-line:max-func-body-length\n Chart.prototype.onPropertyChanged = function (newProp, oldProp) {\n var renderer = false;\n var refreshBounds = false;\n this.animateSeries = false;\n var axis;\n if (!this.delayRedraw) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'primaryXAxis':\n axis = newProp.primaryXAxis;\n refreshBounds = this.axisChange(axis);\n if (newProp.primaryXAxis.edgeLabelPlacement) {\n renderer = true;\n }\n if (!newProp.primaryXAxis.crosshairTooltip) {\n refreshBounds = true;\n }\n if (!isNullOrUndefined(axis.isInversed) || !isNullOrUndefined(axis.opposedPosition)) {\n this.primaryXAxis.setIsInversedAndOpposedPosition();\n }\n break;\n case 'primaryYAxis':\n axis = newProp.primaryYAxis;\n refreshBounds = this.axisChange(axis);\n if (newProp.primaryYAxis.edgeLabelPlacement) {\n renderer = true;\n }\n if (!newProp.primaryYAxis.crosshairTooltip) {\n refreshBounds = true;\n }\n if (!isNullOrUndefined(axis.isInversed) || !isNullOrUndefined(axis.opposedPosition)) {\n this.primaryYAxis.setIsInversedAndOpposedPosition();\n }\n break;\n case 'axes':\n for (var _b = 0, _c = Object.keys(newProp.axes); _b < _c.length; _b++) {\n var index = _c[_b];\n axis = newProp.axes[index];\n refreshBounds = refreshBounds || this.axisChange(axis);\n if (!axis.crosshairTooltip) {\n refreshBounds = true;\n }\n if (!isNullOrUndefined(axis.isInversed) || !isNullOrUndefined(axis.opposedPosition)) {\n this.axes[index].setIsInversedAndOpposedPosition();\n }\n }\n break;\n case 'height':\n case 'width':\n this.createChartSvg();\n refreshBounds = true;\n break;\n case 'subTitle':\n case 'title':\n refreshBounds = true;\n break;\n case 'titleStyle':\n if (newProp.titleStyle && (newProp.titleStyle.size || newProp.titleStyle.textOverflow)) {\n refreshBounds = true;\n }\n else {\n renderer = true;\n }\n break;\n case 'subTitleStyle':\n if (newProp.subTitleStyle && (newProp.subTitleStyle.size || newProp.subTitleStyle.textOverflow)) {\n refreshBounds = true;\n }\n else {\n renderer = true;\n }\n break;\n case 'border':\n renderer = true;\n break;\n case 'dataSource':\n this.processData(false);\n refreshBounds = true;\n break;\n case 'enableCanvas':\n this.refresh();\n break;\n case 'series':\n var len = this.series.length;\n var seriesRefresh = false;\n var series = void 0;\n var blazorProp = void 0;\n for (var i = 0; i < len; i++) {\n series = newProp.series[i];\n // I264774 blazor series visible property binding not working issue fixed.\n if (this.isBlazor && series && ((series.visible !== oldProp.series[i].visible) || series.isClosed ||\n series.marker || series.emptyPointSettings || series.type || series.boxPlotMode || series.showMean)) {\n blazorProp = true;\n }\n if (!isNullOrUndefined(series) && (series.dataSource || series.query || series.errorBar || series.xName ||\n series.yName || series.size || series.high || series.low || series.open || series.close || series.trendlines ||\n series.fill || series.name || series.marker || series.width || series.binInterval || series.type || (series.visible !== oldProp.series[i].visible) || blazorProp)) {\n extend(this.getVisibleSeries(this.visibleSeries, i), series, null, true);\n seriesRefresh = true;\n }\n }\n if (seriesRefresh) {\n this.calculateVisibleSeries();\n this.initTechnicalIndicators();\n this.initTrendLines();\n this.refreshDefinition(this.columns);\n this.refreshDefinition(this.rows);\n this.calculateVisibleAxis();\n this.processData(false);\n refreshBounds = true;\n }\n break;\n case 'indicators':\n refreshBounds = true;\n break;\n case 'zoomSettings':\n if (newProp.zoomSettings.enableScrollbar || oldProp.zoomSettings.enableScrollbar) {\n refreshBounds = true;\n }\n renderer = true;\n break;\n case 'background':\n renderer = true;\n break;\n case 'chartArea':\n if (newProp.chartArea.border && newProp.chartArea.border.width) {\n refreshBounds = true;\n }\n renderer = true;\n break;\n case 'legendSettings':\n if (!newProp.legendSettings.background || !newProp.legendSettings.opacity) {\n refreshBounds = true;\n }\n renderer = true;\n break;\n case 'palettes':\n this.calculateVisibleSeries();\n renderer = true;\n break;\n case 'selectedDataIndexes':\n if (this.selectionModule) {\n this.selectionModule.currentMode = this.selectionMode;\n this.selectionModule.selectedDataIndexes = this.selectedDataIndexes;\n this.selectionModule.styleId = this.element.id + '_ej2_chart_selection';\n this.selectionModule.redrawSelection(this, oldProp.selectionMode, true);\n }\n else if (this.highlightModule) {\n this.highlightModule.currentMode = this.highlightMode;\n this.highlightModule.highlightDataIndexes = this.selectedDataIndexes;\n this.highlightModule.styleId = this.element.id + '_ej2_chart_highlight';\n this.highlightModule.redrawSelection(this, oldProp.selectionMode, true);\n }\n break;\n case 'selectionMode':\n if (this.selectionModule && newProp.selectionMode && newProp.selectionMode.indexOf('Drag') === -1) {\n this.selectionModule.currentMode = this.selectionMode;\n this.selectionModule.styleId = this.element.id + '_ej2_chart_selection';\n this.selectionModule.redrawSelection(this, oldProp.selectionMode, true);\n }\n break;\n case 'isMultiSelect':\n if (this.selectionModule && !newProp.isMultiSelect && this.selectionModule.selectedDataIndexes.length > 1) {\n this.selectionModule.currentMode = this.selectionMode;\n this.selectionModule.styleId = this.element.id + '_ej2_chart_selection';\n this.selectionModule.redrawSelection(this, oldProp.selectionMode);\n }\n break;\n case 'highlightMode':\n case 'selectionPattern':\n case 'highlightPattern':\n this.removeStyles();\n renderer = true;\n break;\n case 'theme':\n this.animateSeries = true;\n break;\n case 'enableRtl':\n case 'locale':\n case 'currencyCode':\n if (this.isBlazor) {\n this.setCulture();\n renderer = true;\n }\n else {\n this.refresh();\n }\n break;\n case 'tooltip':\n if (this.tooltipModule) { // To check the tooltip enable is true.\n this.tooltipModule.previousPoints = [];\n if (this.tooltip.template) {\n this.tooltipModule.template = this.tooltip.template;\n }\n }\n break;\n }\n }\n if (!refreshBounds && renderer) {\n this.rotatedDataLabelCollections = [];\n this.removeSvg();\n this.renderElements();\n this.trigger('loaded', { chart: this.isBlazor ? {} : this });\n }\n if (refreshBounds) {\n this.enableCanvas ? this.createChartSvg() : this.removeSvg();\n if (this.isReact) {\n this.clearTemplate();\n }\n this.dragY = null;\n this.refreshAxis();\n this.refreshBound();\n this.trigger('loaded', { chart: this.isBlazor ? {} : this });\n this.redraw = false;\n this.animated = false;\n }\n }\n };\n __decorate([\n Property(null)\n ], Chart.prototype, \"width\", void 0);\n __decorate([\n Property(null)\n ], Chart.prototype, \"height\", void 0);\n __decorate([\n Property('')\n ], Chart.prototype, \"title\", void 0);\n __decorate([\n Property('')\n ], Chart.prototype, \"dataSource\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"16px\", fontStyle: 'Normal', fontWeight: '600', color: null }, titleSettings)\n ], Chart.prototype, \"titleStyle\", void 0);\n __decorate([\n Property('')\n ], Chart.prototype, \"subTitle\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"14px\", fontStyle: 'Normal', fontWeight: '400', color: null }, titleSettings)\n ], Chart.prototype, \"subTitleStyle\", void 0);\n __decorate([\n Complex({}, Margin)\n ], Chart.prototype, \"margin\", void 0);\n __decorate([\n Complex({ color: '#DDDDDD', width: 0 }, Border)\n ], Chart.prototype, \"border\", void 0);\n __decorate([\n Property(null)\n ], Chart.prototype, \"background\", void 0);\n __decorate([\n Complex({ border: { color: null, width: 0.5 }, background: 'transparent' }, ChartArea)\n ], Chart.prototype, \"chartArea\", void 0);\n __decorate([\n Complex({ name: 'primaryXAxis' }, Axis)\n ], Chart.prototype, \"primaryXAxis\", void 0);\n __decorate([\n Complex({ name: 'primaryYAxis' }, Axis)\n ], Chart.prototype, \"primaryYAxis\", void 0);\n __decorate([\n Collection([{}], Row)\n ], Chart.prototype, \"rows\", void 0);\n __decorate([\n Collection([{}], Column)\n ], Chart.prototype, \"columns\", void 0);\n __decorate([\n Collection([{}], Axis)\n ], Chart.prototype, \"axes\", void 0);\n __decorate([\n Collection([{}], Series)\n ], Chart.prototype, \"series\", void 0);\n __decorate([\n Collection([{}], ChartAnnotationSettings)\n ], Chart.prototype, \"annotations\", void 0);\n __decorate([\n Property([])\n ], Chart.prototype, \"palettes\", void 0);\n __decorate([\n Property('Material')\n ], Chart.prototype, \"theme\", void 0);\n __decorate([\n Complex({}, TooltipSettings)\n ], Chart.prototype, \"tooltip\", void 0);\n __decorate([\n Complex({}, CrosshairSettings)\n ], Chart.prototype, \"crosshair\", void 0);\n __decorate([\n Complex({}, LegendSettings)\n ], Chart.prototype, \"legendSettings\", void 0);\n __decorate([\n Collection([{}], RangeColorSetting)\n ], Chart.prototype, \"rangeColorSettings\", void 0);\n __decorate([\n Complex({}, ZoomSettings)\n ], Chart.prototype, \"zoomSettings\", void 0);\n __decorate([\n Property('')\n ], Chart.prototype, \"highlightColor\", void 0);\n __decorate([\n Property('None')\n ], Chart.prototype, \"selectionMode\", void 0);\n __decorate([\n Property('None')\n ], Chart.prototype, \"highlightMode\", void 0);\n __decorate([\n Property('None')\n ], Chart.prototype, \"selectionPattern\", void 0);\n __decorate([\n Property('None')\n ], Chart.prototype, \"highlightPattern\", void 0);\n __decorate([\n Property(false)\n ], Chart.prototype, \"isMultiSelect\", void 0);\n __decorate([\n Property(false)\n ], Chart.prototype, \"allowMultiSelection\", void 0);\n __decorate([\n Property(true)\n ], Chart.prototype, \"enableExport\", void 0);\n __decorate([\n Property(false)\n ], Chart.prototype, \"allowExport\", void 0);\n __decorate([\n Collection([], Indexes)\n ], Chart.prototype, \"selectedDataIndexes\", void 0);\n __decorate([\n Property(false)\n ], Chart.prototype, \"useGroupingSeparator\", void 0);\n __decorate([\n Property(false)\n ], Chart.prototype, \"enableAutoIntervalOnBothAxis\", void 0);\n __decorate([\n Property(false)\n ], Chart.prototype, \"isTransposed\", void 0);\n __decorate([\n Property(false)\n ], Chart.prototype, \"enableCanvas\", void 0);\n __decorate([\n Property(null)\n ], Chart.prototype, \"backgroundImage\", void 0);\n __decorate([\n Collection([], TechnicalIndicator)\n ], Chart.prototype, \"indicators\", void 0);\n __decorate([\n Property(true)\n ], Chart.prototype, \"enableAnimation\", void 0);\n __decorate([\n Property(null)\n ], Chart.prototype, \"description\", void 0);\n __decorate([\n Property(1)\n ], Chart.prototype, \"tabIndex\", void 0);\n __decorate([\n Property(true)\n ], Chart.prototype, \"enableSideBySidePlacement\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"resized\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"beforeResize\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"annotationRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"beforePrint\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"loaded\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"beforeExport\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"afterExport\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"load\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"animationComplete\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"legendRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"textRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"pointRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"seriesRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"axisLabelRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"axisLabelClick\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"axisRangeCalculated\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"axisMultiLabelRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"legendClick\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"multiLevelLabelClick\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"tooltipRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"sharedTooltipRender\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"chartMouseMove\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"chartMouseClick\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"chartDoubleClick\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"pointClick\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"pointDoubleClick\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"pointMove\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"chartMouseLeave\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"chartMouseDown\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"chartMouseUp\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"dragComplete\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"selectionComplete\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"zoomComplete\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"onZooming\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"scrollStart\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"scrollEnd\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"scrollChanged\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"dragStart\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"drag\", void 0);\n __decorate([\n Event()\n ], Chart.prototype, \"dragEnd\", void 0);\n __decorate([\n Property('USD')\n ], Chart.prototype, \"currencyCode\", void 0);\n Chart = __decorate([\n NotifyPropertyChanges\n ], Chart);\n return Chart;\n}(Component));\nexport { Chart };\n","/**\n * Function helps to find which highlightSearch is to call based on your data.\n *\n * @param {HTMLElement} element - Specifies an li element.\n * @param {string} query - Specifies the string to be highlighted.\n * @param {boolean} ignoreCase - Specifies the ignoreCase option.\n * @param {HightLightType} type - Specifies the type of highlight.\n * @returns {void}\n */\nexport function highlightSearch(element, query, ignoreCase, type) {\n if (query === '') {\n return;\n }\n else {\n var ignoreRegex = ignoreCase ? 'gim' : 'gm';\n // eslint-disable-next-line\n query = /^[a-zA-Z0-9- ]*$/.test(query) ? query : query.replace(/[\\-\\[\\]\\/\\{\\}\\(\\)\\*\\+\\?\\.\\\\\\^\\$\\|]/g, '\\\\$&');\n var replaceQuery = type === 'StartsWith' ? '^(' + query + ')' : type === 'EndsWith' ?\n '(' + query + ')$' : '(' + query + ')';\n // eslint-disable-next-line security/detect-non-literal-regexp\n findTextNode(element, new RegExp(replaceQuery, ignoreRegex));\n }\n}\n/* eslint-enable jsdoc/require-param, valid-jsdoc */\n/**\n *\n * @param {HTMLElement} element - Specifies the element.\n * @param {RegExp} pattern - Specifies the regex to match the searched text.\n * @returns {void}\n */\nfunction findTextNode(element, pattern) {\n for (var index = 0; element.childNodes && (index < element.childNodes.length); index++) {\n if (element.childNodes[index].nodeType === 3 && element.childNodes[index].textContent.trim() !== '') {\n var value = element.childNodes[index].nodeValue.trim().replace(pattern, '<span class=\"e-highlight\">$1</span>');\n element.childNodes[index].nodeValue = '';\n element.innerHTML = element.innerHTML.trim() + value;\n break;\n }\n else {\n findTextNode(element.childNodes[index], pattern);\n }\n }\n}\n/**\n * Function helps to remove highlighted element based on your data.\n *\n * @param {HTMLElement} content - Specifies an content element.\n * @returns {void}\n */\nexport function revertHighlightSearch(content) {\n var contentElement = content.querySelectorAll('.e-highlight');\n for (var i = contentElement.length - 1; i >= 0; i--) {\n var parent_1 = contentElement[i].parentNode;\n var text = document.createTextNode(contentElement[i].textContent);\n parent_1.replaceChild(text, contentElement[i]);\n }\n}\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n// eslint-disable-next-line @typescript-eslint/triple-slash-reference\n/// <reference path='../combo-box/combo-box-model.d.ts'/>\nimport { Property, EventHandler, isNullOrUndefined, detach } from '@syncfusion/ej2-base';\nimport { Event, Complex } from '@syncfusion/ej2-base';\nimport { removeClass, NotifyPropertyChanges } from '@syncfusion/ej2-base';\nimport { dropDownListClasses } from '../drop-down-list/drop-down-list';\nimport { ComboBox } from '../combo-box/combo-box';\nimport { highlightSearch, revertHighlightSearch } from '../common/highlight-search';\nimport { Search } from '../common/incremental-search';\nimport { FieldSettings } from '../drop-down-base/drop-down-base';\nimport { Input } from '@syncfusion/ej2-inputs';\nimport { DataManager, Predicate, Query } from '@syncfusion/ej2-data';\ndropDownListClasses.root = 'e-autocomplete';\ndropDownListClasses.icon = 'e-input-group-icon e-ddl-icon e-search-icon';\n/**\n * The AutoComplete component provides the matched suggestion list when type into the input,\n * from which the user can select one.\n * ```html\n * <input id=\"list\" type=\"text\"/>\n * ```\n * ```typescript\n * let atcObj:AutoComplete = new AutoComplete();\n * atcObj.appendTo(\"#list\");\n * ```\n */\nvar AutoComplete = /** @class */ (function (_super) {\n __extends(AutoComplete, _super);\n /**\n * * Constructor for creating the widget\n *\n * @param {AutoCompleteModel} options - Specifies the AutoComplete model.\n * @param {string | HTMLElement} element - Specifies the element to render as component.\n * @private\n */\n function AutoComplete(options, element) {\n var _this_1 = _super.call(this, options, element) || this;\n _this_1.isFiltered = false;\n _this_1.searchList = false;\n return _this_1;\n }\n /**\n * Initialize the event handler\n *\n * @private\n * @returns {void}\n */\n AutoComplete.prototype.preRender = function () {\n _super.prototype.preRender.call(this);\n };\n AutoComplete.prototype.getLocaleName = function () {\n return 'auto-complete';\n };\n AutoComplete.prototype.getNgDirective = function () {\n return 'EJS-AUTOCOMPLETE';\n };\n AutoComplete.prototype.getQuery = function (query) {\n var filterQuery = query ? query.clone() : this.query ? this.query.clone() : new Query();\n var filterType = (this.queryString === '' && !isNullOrUndefined(this.value)) ? 'equal' : this.filterType;\n var queryString = (this.queryString === '' && !isNullOrUndefined(this.value)) ? this.value : this.queryString;\n if (this.isFiltered) {\n return filterQuery;\n }\n if (this.queryString !== null && this.queryString !== '') {\n var dataType = this.typeOfData(this.dataSource).typeof;\n if (!(this.dataSource instanceof DataManager) && dataType === 'string' || dataType === 'number') {\n filterQuery.where('', filterType, queryString, this.ignoreCase, this.ignoreAccent);\n }\n else if ((!this.enableVirtualization) || (this.enableVirtualization && (!(this.dataSource instanceof DataManager) || (this.dataSource instanceof DataManager && this.virtualGroupDataSource)))) {\n var mapping = !isNullOrUndefined(this.fields.value) ? this.fields.value : '';\n filterQuery.where(mapping, filterType, queryString, this.ignoreCase, this.ignoreAccent);\n }\n }\n if (!isNullOrUndefined(this.suggestionCount) && !this.enableVirtualization) {\n // Since defualt value of suggestioncount is 20, checked the condition\n if (this.suggestionCount !== 20) {\n for (var queryElements = 0; queryElements < filterQuery.queries.length; queryElements++) {\n if (filterQuery.queries[queryElements].fn === 'onTake') {\n filterQuery.queries.splice(queryElements, 1);\n }\n }\n }\n filterQuery.take(this.suggestionCount);\n }\n if (this.enableVirtualization && (!(this.dataSource instanceof DataManager) || (this.dataSource instanceof DataManager && this.virtualGroupDataSource))) {\n var takeValue = this.getTakeValue();\n filterQuery.skip(this.virtualItemStartIndex);\n filterQuery.take(takeValue);\n filterQuery.requiresCount();\n }\n return filterQuery;\n };\n AutoComplete.prototype.searchLists = function (e) {\n var _this_1 = this;\n this.isTyped = true;\n this.isDataFetched = this.isSelectCustom = false;\n this.checkAndResetCache();\n if (isNullOrUndefined(this.list)) {\n _super.prototype.renderList.call(this, e, true);\n }\n this.queryString = this.filterInput.value;\n if (e.type !== 'mousedown' && (e.keyCode === 40 || e.keyCode === 38)) {\n this.queryString = this.queryString === '' ? null : this.queryString;\n this.beforePopupOpen = true;\n this.resetList(this.dataSource, this.fields, null, e);\n return;\n }\n this.isSelected = false;\n this.activeIndex = null;\n var eventArgs = {\n preventDefaultAction: false,\n text: this.filterInput.value,\n updateData: function (dataSource, query, fields) {\n if (eventArgs.cancel) {\n return;\n }\n _this_1.isFiltered = true;\n _this_1.filterAction(dataSource, query, fields);\n },\n cancel: false\n };\n this.trigger('filtering', eventArgs, function (eventArgs) {\n if (!eventArgs.cancel && !_this_1.isFiltered && !eventArgs.preventDefaultAction) {\n _this_1.searchList = true;\n _this_1.filterAction(_this_1.dataSource, null, _this_1.fields, e);\n }\n });\n };\n /**\n * To filter the data from given data source by using query\n *\n * @param {Object[] | DataManager } dataSource - Set the data source to filter.\n * @param {Query} query - Specify the query to filter the data.\n * @param {FieldSettingsModel} fields - Specify the fields to map the column in the data table.\n * @returns {void}\n\n */\n AutoComplete.prototype.filter = function (dataSource, query, fields) {\n this.isFiltered = true;\n this.filterAction(dataSource, query, fields);\n };\n AutoComplete.prototype.filterAction = function (dataSource, query, fields, e) {\n this.beforePopupOpen = true;\n var isNoDataElement = this.list.classList.contains('e-nodata');\n if (this.queryString !== '' && (this.queryString.length >= this.minLength)) {\n if (this.enableVirtualization && this.isFiltering() && this.isTyped) {\n this.isPreventScrollAction = true;\n this.list.scrollTop = 0;\n this.previousStartIndex = 0;\n this.virtualListInfo = null;\n }\n this.resetList(dataSource, fields, query, e);\n if (this.enableVirtualization && isNoDataElement && !this.list.classList.contains('e-nodata')) {\n if (!this.list.querySelector('.e-virtual-ddl-content')) {\n this.list.appendChild(this.createElement('div', {\n className: 'e-virtual-ddl-content',\n styles: this.getTransformValues()\n })).appendChild(this.list.querySelector('.e-list-parent'));\n }\n if (!this.list.querySelector('.e-virtual-ddl')) {\n var virualElement = this.createElement('div', {\n id: this.element.id + '_popup', className: 'e-virtual-ddl', styles: this.GetVirtualTrackHeight()\n });\n document.getElementsByClassName('e-popup')[0].querySelector('.e-dropdownbase').appendChild(virualElement);\n }\n }\n if ((this.getModuleName() === 'autocomplete' && !(this.dataSource instanceof DataManager)) || (this.getModuleName() === 'autocomplete' && (this.dataSource instanceof DataManager) && this.totalItemCount != 0)) {\n this.getFilteringSkeletonCount();\n }\n }\n else {\n this.hidePopup(e);\n this.beforePopupOpen = false;\n }\n this.renderReactTemplates();\n };\n AutoComplete.prototype.clearAll = function (e, property) {\n if (isNullOrUndefined(property) || (!isNullOrUndefined(property) && isNullOrUndefined(property.dataSource))) {\n _super.prototype.clearAll.call(this, e);\n this.checkAndResetCache();\n }\n if (this.beforePopupOpen) {\n this.hidePopup();\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n AutoComplete.prototype.onActionComplete = function (ulElement, list, e, isUpdated) {\n if (!this.enableVirtualization) {\n this.fixedHeaderElement = null;\n }\n if ((this.getModuleName() === 'autocomplete' && !(this.dataSource instanceof DataManager)) || (this.getModuleName() === 'autocomplete' && (this.dataSource instanceof DataManager) && this.totalItemCount != 0)) {\n this.getFilteringSkeletonCount();\n }\n _super.prototype.onActionComplete.call(this, ulElement, list, e);\n var item = this.list.querySelector('.' + dropDownListClasses.li);\n if (!isNullOrUndefined(item)) {\n removeClass([item], dropDownListClasses.focus);\n }\n this.postBackAction();\n };\n AutoComplete.prototype.postBackAction = function () {\n if (this.autofill && !isNullOrUndefined(this.liCollections[0]) && this.searchList) {\n var items = [this.liCollections[0]];\n var dataSource = this.listData;\n var type = this.typeOfData(dataSource).typeof;\n var searchItem = Search(this.inputElement.value, items, 'StartsWith', this.ignoreCase, dataSource, this.fields, type);\n this.searchList = false;\n if (!isNullOrUndefined(searchItem.item)) {\n _super.prototype.setAutoFill.call(this, this.liCollections[0], true);\n }\n }\n };\n AutoComplete.prototype.setSelection = function (li, e) {\n if (!this.isValidLI(li)) {\n this.selectedLI = li;\n return;\n }\n if (!isNullOrUndefined(e) && e.type === 'keydown' && e.action !== 'enter'\n && e.action !== 'tab' && this.isValidLI(li)) {\n var value = this.getFormattedValue(li.getAttribute('data-value'));\n this.activeIndex = this.getIndexByValue(value);\n this.setHoverList(li);\n this.selectedLI = li;\n this.setScrollPosition(e);\n if (this.autofill && this.isPopupOpen) {\n this.preventAutoFill = false;\n var isKeyNavigate = (e && e.action === 'down' || e.action === 'up' ||\n e.action === 'home' || e.action === 'end' || e.action === 'pageUp' || e.action === 'pageDown');\n _super.prototype.setAutoFill.call(this, li, isKeyNavigate);\n }\n }\n else {\n _super.prototype.setSelection.call(this, li, e);\n }\n };\n AutoComplete.prototype.listOption = function (dataSource, fieldsSettings) {\n var _this_1 = this;\n var fields = _super.prototype.listOption.call(this, dataSource, fieldsSettings);\n if (isNullOrUndefined(fields.itemCreated)) {\n fields.itemCreated = function (e) {\n if (_this_1.highlight) {\n if (_this_1.element.tagName === _this_1.getNgDirective() && _this_1.itemTemplate) {\n setTimeout(function () {\n highlightSearch(e.item, _this_1.queryString, _this_1.ignoreCase, _this_1.filterType);\n }, 0);\n }\n else {\n var isHtmlElement = /<[^>]*>/g.test(e.item.innerText);\n if (isHtmlElement) {\n e.item.innerText = e.item.innerText.replace(/[\\u00A0-\\u9999<>&]/g, function (match) { return \"&#\" + match.charCodeAt(0) + \";\"; });\n }\n highlightSearch(e.item, _this_1.queryString, _this_1.ignoreCase, _this_1.filterType);\n }\n }\n };\n }\n else {\n var itemCreated_1 = fields.itemCreated;\n fields.itemCreated = function (e) {\n if (_this_1.highlight) {\n highlightSearch(e.item, _this_1.queryString, _this_1.ignoreCase, _this_1.filterType);\n }\n itemCreated_1.apply(_this_1, [e]);\n };\n }\n return fields;\n };\n AutoComplete.prototype.isFiltering = function () {\n return true;\n };\n AutoComplete.prototype.renderPopup = function (e) {\n if (!this.enableVirtualization) {\n this.list.scrollTop = 0;\n }\n _super.prototype.renderPopup.call(this, e);\n };\n AutoComplete.prototype.isEditTextBox = function () {\n return false;\n };\n AutoComplete.prototype.isPopupButton = function () {\n return this.showPopupButton;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n AutoComplete.prototype.isSelectFocusItem = function (element) {\n return false;\n };\n AutoComplete.prototype.setInputValue = function (newProp, oldProp) {\n var oldValue = oldProp && oldProp.text ? oldProp.text : oldProp ? oldProp.value : oldProp;\n var value = newProp && newProp.text ? newProp.text : newProp && newProp.value ? newProp.value : this.value;\n if (value && this.typedString === '' && !this.allowCustom && !(this.dataSource instanceof DataManager)) {\n var checkFields_1_1 = this.typeOfData(this.dataSource).typeof === 'string' ? '' : this.fields.value;\n var listLength_1 = this.getItems().length;\n var query = new Query();\n var _this_2 = this;\n new DataManager(this.dataSource).executeQuery(query.where(new Predicate(checkFields_1_1, 'equal', value)))\n .then(function (e) {\n if (e.result.length > 0) {\n _this_2.value = checkFields_1_1 !== '' ? e.result[0][_this_2.fields.value].toString() : e.result[0].toString();\n _this_2.addItem(e.result, listLength_1);\n _this_2.updateValues();\n }\n else {\n newProp && newProp.text ? _this_2.setOldText(oldValue) : newProp && newProp.value ? _this_2.setOldValue(oldValue) : _this_2.updateValues();\n }\n });\n }\n else if (newProp) {\n newProp.text ? this.setOldText(oldValue) : this.setOldValue(oldValue);\n }\n };\n /**\n * Search the entered text and show it in the suggestion list if available.\n *\n * @returns {void}\n\n */\n AutoComplete.prototype.showPopup = function (e) {\n if (!this.enabled) {\n return;\n }\n if (this.beforePopupOpen) {\n this.refreshPopup();\n return;\n }\n this.beforePopupOpen = true;\n this.preventAutoFill = true;\n if (isNullOrUndefined(this.list)) {\n this.renderList(e);\n }\n else {\n this.resetList(this.dataSource, this.fields, null, e);\n }\n };\n /**\n * Hides the popup if it is in open state.\n *\n * @returns {void}\n */\n AutoComplete.prototype.hidePopup = function (e) {\n _super.prototype.hidePopup.call(this, e);\n this.activeIndex = null;\n this.virtualListInfo = this.viewPortInfo;\n this.previousStartIndex = this.viewPortInfo.startIndex;\n this.startIndex = this.viewPortInfo.startIndex;\n this.previousEndIndex = this.viewPortInfo.endIndex;\n };\n /**\n * Dynamically change the value of properties.\n *\n * @param {AutoCompleteModel} newProp - Returns the dynamic property value of the component.\n * @param {AutoCompleteModel} oldProp - Returns the previous property value of the component.\n * @private\n * @returns {void}\n */\n AutoComplete.prototype.onPropertyChanged = function (newProp, oldProp) {\n if (this.getModuleName() === 'autocomplete') {\n this.setUpdateInitial(['fields', 'query', 'dataSource'], newProp);\n }\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'showPopupButton':\n if (this.showPopupButton) {\n var button = Input.appendSpan(dropDownListClasses.icon, this.inputWrapper.container, this.createElement);\n this.inputWrapper.buttons[0] = button;\n Input.calculateWidth(this.inputElement, this.inputWrapper.container);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-icon');\n }\n if (this.inputWrapper && this.inputWrapper.buttons && this.inputWrapper.buttons[0]) {\n EventHandler.add(this.inputWrapper.buttons[0], 'click', this.dropDownClick, this);\n }\n }\n else {\n detach(this.inputWrapper.buttons[0]);\n this.inputWrapper.buttons[0] = null;\n }\n break;\n default: {\n // eslint-disable-next-line max-len\n var atcProps = this.getPropObject(prop, newProp, oldProp);\n _super.prototype.onPropertyChanged.call(this, atcProps.newProperty, atcProps.oldProperty);\n break;\n }\n }\n }\n };\n AutoComplete.prototype.renderHightSearch = function () {\n if (this.highlight) {\n for (var i = 0; i < this.liCollections.length; i++) {\n var isHighlight = this.ulElement.querySelector('.e-active');\n if (!isHighlight) {\n revertHighlightSearch(this.liCollections[i]);\n highlightSearch(this.liCollections[i], this.queryString, this.ignoreCase, this.filterType);\n }\n }\n }\n };\n /**\n * Return the module name of this component.\n *\n * @private\n * @returns {string} Return the module name of this component.\n */\n AutoComplete.prototype.getModuleName = function () {\n return 'autocomplete';\n };\n /**\n * To initialize the control rendering\n *\n * @private\n * @returns {void}\n */\n AutoComplete.prototype.render = function () {\n _super.prototype.render.call(this);\n };\n __decorate([\n Complex({ value: null, iconCss: null, groupBy: null }, FieldSettings)\n ], AutoComplete.prototype, \"fields\", void 0);\n __decorate([\n Property(true)\n ], AutoComplete.prototype, \"ignoreCase\", void 0);\n __decorate([\n Property(false)\n ], AutoComplete.prototype, \"showPopupButton\", void 0);\n __decorate([\n Property(false)\n ], AutoComplete.prototype, \"highlight\", void 0);\n __decorate([\n Property(20)\n ], AutoComplete.prototype, \"suggestionCount\", void 0);\n __decorate([\n Property({})\n ], AutoComplete.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property(null)\n ], AutoComplete.prototype, \"query\", void 0);\n __decorate([\n Property(1)\n ], AutoComplete.prototype, \"minLength\", void 0);\n __decorate([\n Property('Contains')\n ], AutoComplete.prototype, \"filterType\", void 0);\n __decorate([\n Event()\n ], AutoComplete.prototype, \"filtering\", void 0);\n __decorate([\n Property(null)\n ], AutoComplete.prototype, \"index\", void 0);\n __decorate([\n Property('Never')\n ], AutoComplete.prototype, \"floatLabelType\", void 0);\n __decorate([\n Property(null)\n ], AutoComplete.prototype, \"valueTemplate\", void 0);\n __decorate([\n Property(null)\n ], AutoComplete.prototype, \"filterBarPlaceholder\", void 0);\n __decorate([\n Property(false)\n ], AutoComplete.prototype, \"allowFiltering\", void 0);\n __decorate([\n Property(null)\n ], AutoComplete.prototype, \"text\", void 0);\n AutoComplete = __decorate([\n NotifyPropertyChanges\n ], AutoComplete);\n return AutoComplete;\n}(ComboBox));\nexport { AutoComplete };\n","/**\n * Specifies class names\n */\n/** @hidden */\nexport var rowCell = 'e-rowcell';\n/** @hidden */\nexport var gridHeader = 'e-gridheader';\n/** @hidden */\nexport var gridContent = 'e-gridcontent';\n/** @hidden */\nexport var gridFooter = 'e-gridfooter';\n/** @hidden */\nexport var headerContent = 'e-headercontent';\n/** @hidden */\nexport var movableContent = 'e-movablecontent';\n/** @hidden */\nexport var movableHeader = 'e-movableheader';\n/** @hidden */\nexport var frozenContent = 'e-frozencontent';\n/** @hidden */\nexport var frozenHeader = 'e-frozenheader';\n/** @hidden */\nexport var content = 'e-content';\n/** @hidden */\nexport var table = 'e-table';\n/** @hidden */\nexport var row = 'e-row';\n/** @hidden */\nexport var gridChkBox = 'e-gridchkbox';\n/** @hidden */\nexport var editedRow = 'e-editedrow';\n/** @hidden */\nexport var addedRow = 'e-addedrow';\n/**\n * Specifies repeated strings\n */\n/** @hidden */\nexport var changedRecords = 'changedRecords';\n/** @hidden */\nexport var addedRecords = 'addedRecords';\n/** @hidden */\nexport var deletedRecords = 'deletedRecords';\n/** @hidden */\nexport var leftRight = 'Left-Right';\n/** @hidden */\nexport var frozenRight = 'frozen-right';\n/** @hidden */\nexport var frozenLeft = 'frozen-left';\n/** @hidden */\nexport var dataColIndex = 'data-colindex';\n/** @hidden */\nexport var ariaColIndex = 'aria-colindex';\n/** @hidden */\nexport var dataRowIndex = 'data-rowindex';\n/** @hidden */\nexport var ariaRowIndex = 'aria-rowindex';\n/** @hidden */\nexport var tbody = 'tbody';\n/** @hidden */\nexport var colGroup = 'colgroup';\n/** @hidden */\nexport var open = 'open';\n/** @hidden */\nexport var change = 'change';\n/** @hidden */\nexport var focus = 'focus';\n/** @hidden */\nexport var create = 'created';\n/** @hidden */\nexport var beforeOpen = 'beforeOpen';\n/** @hidden */\nexport var downArrow = 'downArrow';\n/** @hidden */\nexport var upArrow = 'upArrow';\n/** @hidden */\nexport var pageUp = 'PageUp';\n/** @hidden */\nexport var pageDown = 'PageDown';\n/** @hidden */\nexport var enter = 'enter';\n/** @hidden */\nexport var shiftEnter = 'shiftEnter';\n/** @hidden */\nexport var tab = 'tab';\n/** @hidden */\nexport var shiftTab = 'shiftTab';\n/** @hidden */\nexport var initialFrozenColumnIndex = 'initialFrozenColumnIndex';\n","//! moment.js locale configuration\n//! locale : English (Canada) [en-ca]\n//! author : Jonathan Abourbih : https://github.com/jonbca\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enCa = moment.defineLocale('en-ca', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'YYYY-MM-DD',\n LL: 'MMMM D, YYYY',\n LLL: 'MMMM D, YYYY h:mm A',\n LLLL: 'dddd, MMMM D, YYYY h:mm A',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n });\n\n return enCa;\n\n})));\n","//! moment.js locale configuration\n//! locale : English (United Kingdom) [en-gb]\n//! author : Chris Gedrim : https://github.com/chrisgedrim\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enGb = moment.defineLocale('en-gb', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return enGb;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Component, rippleEffect, NotifyPropertyChanges, Property, closest, setValue } from '@syncfusion/ej2-base';\nimport { addClass, getInstance, getUniqueID, isRippleEnabled, removeClass, attributes, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { detach, Event, EventHandler, SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport { wrapperInitialize, rippleMouseHandler } from './../common/common';\nvar LABEL = 'e-label';\nvar RIPPLE = 'e-ripple-container';\nvar RTL = 'e-rtl';\nvar WRAPPER = 'e-radio-wrapper';\nvar ATTRIBUTES = ['title', 'class', 'style', 'disabled', 'readonly', 'name', 'value', 'id'];\n/**\n * The RadioButton is a graphical user interface element that allows you to select one option from the choices.\n * It contains checked and unchecked states.\n * ```html\n * <input type=\"radio\" id=\"radio\"/>\n * <script>\n * var radioObj = new RadioButton({ label: \"Default\" });\n * radioObj.appendTo(\"#radio\");\n * </script>\n * ```\n */\nvar RadioButton = /** @class */ (function (_super) {\n __extends(RadioButton, _super);\n /**\n * Constructor for creating the widget\n *\n * @private\n * @param {RadioButtonModel} options - Specifies Radio button model\n * @param {string | HTMLInputElement} element - Specifies target element\n */\n function RadioButton(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.isFocused = false;\n return _this;\n }\n RadioButton_1 = RadioButton;\n RadioButton.prototype.changeHandler = function (event) {\n this.checked = true;\n this.dataBind();\n var value = this.element.getAttribute('value');\n value = this.isVue && value ? this.element.value : this.value;\n var type = typeof this.value;\n if (this.isVue && type === 'boolean') {\n value = value === 'true' ? true : false;\n }\n this.trigger('change', { value: value, event: event });\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this.isAngular) {\n event.stopPropagation();\n }\n };\n RadioButton.prototype.updateChange = function () {\n var input;\n var instance;\n var radioGrp = this.getRadioGroup();\n for (var i = 0; i < radioGrp.length; i++) {\n input = radioGrp[i];\n if (input !== this.element) {\n instance = getInstance(input, RadioButton_1);\n instance.checked = false;\n if (this.tagName === 'EJS-RADIOBUTTON') {\n instance.angularValue = this.value;\n }\n }\n }\n };\n /**\n * Destroys the widget.\n *\n * @returns {void}\n */\n RadioButton.prototype.destroy = function () {\n var _this = this;\n var radioWrap = this.wrapper;\n _super.prototype.destroy.call(this);\n if (radioWrap) {\n if (!this.disabled) {\n this.unWireEvents();\n }\n if (this.tagName === 'INPUT') {\n if (radioWrap.parentNode) {\n radioWrap.parentNode.insertBefore(this.element, radioWrap);\n }\n detach(radioWrap);\n this.element.checked = false;\n ['name', 'value', 'disabled'].forEach(function (key) {\n _this.element.removeAttribute(key);\n });\n }\n else {\n ['role', 'aria-checked', 'class'].forEach(function (key) {\n radioWrap.removeAttribute(key);\n });\n radioWrap.innerHTML = '';\n this.element = this.wrapper;\n if (this.refreshing) {\n ['e-control', 'e-radio', 'e-lib'].forEach(function (key) {\n _this.element.classList.add(key);\n });\n setValue('ej2_instances', [this], this.element);\n }\n }\n }\n };\n RadioButton.prototype.focusHandler = function () {\n this.isFocused = true;\n };\n RadioButton.prototype.focusOutHandler = function () {\n var label = this.getLabel();\n if (label) {\n label.classList.remove('e-focus');\n }\n };\n RadioButton.prototype.getModuleName = function () {\n return 'radio';\n };\n /**\n * To get the value of selected radio button in a group.\n *\n * @method getSelectedValue\n * @returns {string} - Selected Value\n */\n RadioButton.prototype.getSelectedValue = function () {\n var input;\n var radioGrp = this.getRadioGroup();\n for (var i = 0, len = radioGrp.length; i < len; i++) {\n input = radioGrp[i];\n if (input.checked) {\n return input.value;\n }\n }\n return '';\n };\n RadioButton.prototype.getRadioGroup = function () {\n return document.querySelectorAll('input.e-radio[name=\"' + this.element.getAttribute('name') + '\"]');\n };\n /**\n * Gets the properties to be maintained in the persistence state.\n *\n * @private\n * @returns {string} - Persist Data\n */\n RadioButton.prototype.getPersistData = function () {\n return this.addOnPersist(['checked']);\n };\n RadioButton.prototype.getWrapper = function () {\n if (this.element) {\n return this.element.parentElement;\n }\n else {\n return null;\n }\n };\n RadioButton.prototype.getLabel = function () {\n if (this.element) {\n return this.element.nextElementSibling;\n }\n else {\n return null;\n }\n };\n RadioButton.prototype.initialize = function () {\n if (isNullOrUndefined(this.initialCheckedValue)) {\n this.initialCheckedValue = this.checked;\n }\n this.initWrapper();\n this.updateHtmlAttribute();\n if (this.name) {\n this.element.setAttribute('name', this.name);\n }\n var value = this.element.getAttribute('value');\n var type = typeof this.value;\n if (this.isVue && type === 'boolean') {\n value = value === 'true' ? true : false;\n }\n if (this.isVue ? this.value && type !== 'boolean' && !value : this.value) {\n this.element.setAttribute('value', this.value);\n }\n if (this.checked) {\n this.element.checked = true;\n }\n if (this.disabled) {\n this.setDisabled();\n }\n };\n RadioButton.prototype.initWrapper = function () {\n var rippleSpan;\n var wrapper = this.element.parentElement;\n if (!wrapper.classList.contains(WRAPPER)) {\n wrapper = this.createElement('div', { className: WRAPPER });\n this.element.parentNode.insertBefore(wrapper, this.element);\n }\n var label = this.createElement('label', { attrs: { for: this.element.id } });\n wrapper.appendChild(this.element);\n wrapper.appendChild(label);\n if (isRippleEnabled) {\n rippleSpan = this.createElement('span', { className: (RIPPLE) });\n label.appendChild(rippleSpan);\n rippleEffect(rippleSpan, {\n duration: 400,\n isCenterRipple: true\n });\n }\n wrapper.classList.add('e-wrapper');\n if (this.enableRtl) {\n label.classList.add(RTL);\n }\n if (this.cssClass) {\n addClass([wrapper], this.cssClass.replace(/\\s+/g, ' ').trim().split(' '));\n }\n if (this.label) {\n this.setText(this.label);\n }\n };\n RadioButton.prototype.keyUpHandler = function () {\n if (this.isFocused) {\n this.getLabel().classList.add('e-focus');\n }\n };\n RadioButton.prototype.labelMouseDownHandler = function (e) {\n var rippleSpan = this.getLabel().getElementsByClassName(RIPPLE)[0];\n rippleMouseHandler(e, rippleSpan);\n };\n RadioButton.prototype.labelMouseLeaveHandler = function (e) {\n var rippleSpan = this.getLabel().getElementsByClassName(RIPPLE)[0];\n if (rippleSpan) {\n var rippleElem = rippleSpan.querySelectorAll('.e-ripple-element');\n for (var i = rippleElem.length - 1; i > 0; i--) {\n rippleSpan.removeChild(rippleSpan.childNodes[i]);\n }\n rippleMouseHandler(e, rippleSpan);\n }\n };\n RadioButton.prototype.labelMouseUpHandler = function (e) {\n var rippleSpan = this.getLabel().getElementsByClassName(RIPPLE)[0];\n if (rippleSpan) {\n var rippleElem = rippleSpan.querySelectorAll('.e-ripple-element');\n for (var i = rippleElem.length - 1; i > 0; i--) {\n rippleSpan.removeChild(rippleSpan.childNodes[i]);\n }\n rippleMouseHandler(e, rippleSpan);\n }\n };\n RadioButton.prototype.formResetHandler = function () {\n this.checked = this.initialCheckedValue;\n if (this.initialCheckedValue) {\n attributes(this.element, { 'checked': 'true' });\n }\n };\n /**\n * Called internally if any of the property value changes.\n *\n * @private\n * @param {RadioButtonModel} newProp - Specifies New Properties\n * @param {RadioButtonModel} oldProp - Specifies Old Properties\n * @returns {void}\n */\n RadioButton.prototype.onPropertyChanged = function (newProp, oldProp) {\n var wrap = this.getWrapper();\n var label = this.getLabel();\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'checked':\n if (newProp.checked) {\n this.updateChange();\n }\n this.element.checked = newProp.checked;\n break;\n case 'disabled':\n if (newProp.disabled) {\n this.setDisabled();\n this.unWireEvents();\n }\n else {\n this.element.disabled = false;\n this.wireEvents();\n }\n break;\n case 'cssClass':\n if (oldProp.cssClass) {\n removeClass([wrap], oldProp.cssClass.split(' '));\n }\n if (newProp.cssClass) {\n addClass([wrap], newProp.cssClass.replace(/\\s+/g, ' ').trim().split(' '));\n }\n break;\n case 'enableRtl':\n if (newProp.enableRtl) {\n label.classList.add(RTL);\n }\n else {\n label.classList.remove(RTL);\n }\n break;\n case 'label':\n this.setText(newProp.label);\n break;\n case 'labelPosition':\n if (newProp.labelPosition === 'Before') {\n label.classList.add('e-right');\n }\n else {\n label.classList.remove('e-right');\n }\n break;\n case 'name':\n this.element.setAttribute('name', newProp.name);\n break;\n case 'value':\n var type = typeof this.htmlAttributes.value;\n if (!isNullOrUndefined(this.htmlAttributes) && (this.htmlAttributes.value || type === 'boolean' && !this.htmlAttributes.value)) {\n break;\n }\n this.element.setAttribute('value', newProp.value);\n break;\n case 'htmlAttributes':\n this.updateHtmlAttribute();\n break;\n }\n }\n };\n /**\n * Initialize checked Property, Angular and React and Unique ID support.\n *\n * @private\n * @returns {void}\n */\n RadioButton.prototype.preRender = function () {\n var element = this.element;\n this.formElement = closest(this.element, 'form');\n this.tagName = this.element.tagName;\n element = wrapperInitialize(this.createElement, 'EJS-RADIOBUTTON', 'radio', element, WRAPPER, 'radio');\n this.element = element;\n if (this.element.getAttribute('type') !== 'radio') {\n this.element.setAttribute('type', 'radio');\n }\n if (!this.element.id) {\n this.element.id = getUniqueID('e-' + this.getModuleName());\n }\n if (this.tagName === 'EJS-RADIOBUTTON') {\n var formControlName = this.element.getAttribute('formcontrolname');\n if (formControlName) {\n this.setProperties({ 'name': formControlName }, true);\n this.element.setAttribute('name', formControlName);\n }\n }\n };\n /**\n * Initialize the control rendering\n *\n * @private\n * @returns {void}\n */\n RadioButton.prototype.render = function () {\n this.initialize();\n if (!this.disabled) {\n this.wireEvents();\n }\n this.renderComplete();\n this.wrapper = this.getWrapper();\n };\n RadioButton.prototype.setDisabled = function () {\n this.element.disabled = true;\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n RadioButton.prototype.setText = function (text) {\n var label = this.getLabel();\n var textLabel = label.getElementsByClassName(LABEL)[0];\n if (textLabel) {\n textLabel.textContent = text;\n }\n else {\n text = (this.enableHtmlSanitizer) ? SanitizeHtmlHelper.sanitize(text) : text;\n textLabel = this.createElement('span', { className: LABEL, innerHTML: text });\n label.appendChild(textLabel);\n }\n if (this.labelPosition === 'Before') {\n this.getLabel().classList.add('e-right');\n }\n else {\n this.getLabel().classList.remove('e-right');\n }\n };\n RadioButton.prototype.updateHtmlAttribute = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n var wrapper = this.element.parentElement;\n if (ATTRIBUTES.indexOf(key) > -1) {\n if (key === 'class') {\n addClass([wrapper], this.htmlAttributes[\"\" + key].replace(/\\s+/g, ' ').trim().split(' '));\n }\n else if (key === 'title' || key === 'style') {\n wrapper.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n else {\n this.element.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n else {\n wrapper.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n };\n RadioButton.prototype.unWireEvents = function () {\n var label = this.wrapper;\n EventHandler.remove(this.element, 'change', this.changeHandler);\n EventHandler.remove(this.element, 'focus', this.focusHandler);\n EventHandler.remove(this.element, 'focusout', this.focusOutHandler);\n EventHandler.remove(this.element, 'keyup', this.keyUpHandler);\n var rippleLabel = label.getElementsByTagName('label')[0];\n if (rippleLabel) {\n EventHandler.remove(rippleLabel, 'mousedown', this.labelMouseDownHandler);\n EventHandler.remove(rippleLabel, 'mouseup', this.labelMouseUpHandler);\n EventHandler.remove(rippleLabel, 'mouseleave', this.labelMouseLeaveHandler);\n }\n if (this.formElement) {\n EventHandler.remove(this.formElement, 'reset', this.formResetHandler);\n }\n };\n RadioButton.prototype.wireEvents = function () {\n var label = this.getLabel();\n EventHandler.add(this.element, 'change', this.changeHandler, this);\n EventHandler.add(this.element, 'keyup', this.keyUpHandler, this);\n EventHandler.add(this.element, 'focus', this.focusHandler, this);\n EventHandler.add(this.element, 'focusout', this.focusOutHandler, this);\n var rippleLabel = label.getElementsByClassName(LABEL)[0];\n if (rippleLabel) {\n EventHandler.add(rippleLabel, 'mousedown', this.labelMouseDownHandler, this);\n EventHandler.add(rippleLabel, 'mouseup', this.labelMouseUpHandler, this);\n EventHandler.add(rippleLabel, 'mouseleave', this.labelMouseLeaveHandler, this);\n }\n if (this.formElement) {\n EventHandler.add(this.formElement, 'reset', this.formResetHandler, this);\n }\n };\n /**\n * Click the RadioButton element\n * its native method\n *\n * @public\n * @returns {void}\n */\n RadioButton.prototype.click = function () {\n this.element.click();\n };\n /**\n * Sets the focus to RadioButton\n * its native method\n *\n * @public\n * @returns {void}\n */\n RadioButton.prototype.focusIn = function () {\n this.element.focus();\n };\n var RadioButton_1;\n __decorate([\n Event()\n ], RadioButton.prototype, \"change\", void 0);\n __decorate([\n Event()\n ], RadioButton.prototype, \"created\", void 0);\n __decorate([\n Property(false)\n ], RadioButton.prototype, \"checked\", void 0);\n __decorate([\n Property('')\n ], RadioButton.prototype, \"cssClass\", void 0);\n __decorate([\n Property(false)\n ], RadioButton.prototype, \"disabled\", void 0);\n __decorate([\n Property('')\n ], RadioButton.prototype, \"label\", void 0);\n __decorate([\n Property('After')\n ], RadioButton.prototype, \"labelPosition\", void 0);\n __decorate([\n Property('')\n ], RadioButton.prototype, \"name\", void 0);\n __decorate([\n Property('')\n ], RadioButton.prototype, \"value\", void 0);\n __decorate([\n Property(false)\n ], RadioButton.prototype, \"enableHtmlSanitizer\", void 0);\n __decorate([\n Property({})\n ], RadioButton.prototype, \"htmlAttributes\", void 0);\n RadioButton = RadioButton_1 = __decorate([\n NotifyPropertyChanges\n ], RadioButton);\n return RadioButton;\n}(Component));\nexport { RadioButton };\n","//! moment.js locale configuration\n//! locale : Marathi [mr]\n//! author : Harshad Kale : https://github.com/kalehv\n//! author : Vivek Athalye : https://github.com/vnathalye\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '१',\n 2: '२',\n 3: '३',\n 4: '४',\n 5: '५',\n 6: '६',\n 7: 'à¥',\n 8: '८',\n 9: '९',\n 0: '०',\n },\n numberMap = {\n '१': '1',\n '२': '2',\n '३': '3',\n '४': '4',\n '५': '5',\n '६': '6',\n 'à¥': '7',\n '८': '8',\n '९': '9',\n '०': '0',\n };\n\n function relativeTimeMr(number, withoutSuffix, string, isFuture) {\n var output = '';\n if (withoutSuffix) {\n switch (string) {\n case 's':\n output = 'काही सेकंद';\n break;\n case 'ss':\n output = '%d सेकंद';\n break;\n case 'm':\n output = 'à¤à¤• मिनिट';\n break;\n case 'mm':\n output = '%d मिनिटे';\n break;\n case 'h':\n output = 'à¤à¤• तास';\n break;\n case 'hh':\n output = '%d तास';\n break;\n case 'd':\n output = 'à¤à¤• दिवस';\n break;\n case 'dd':\n output = '%d दिवस';\n break;\n case 'M':\n output = 'à¤à¤• महिना';\n break;\n case 'MM':\n output = '%d महिने';\n break;\n case 'y':\n output = 'à¤à¤• वरà¥à¤·';\n break;\n case 'yy':\n output = '%d वरà¥à¤·à¥‡';\n break;\n }\n } else {\n switch (string) {\n case 's':\n output = 'काही सेकंदां';\n break;\n case 'ss':\n output = '%d सेकंदां';\n break;\n case 'm':\n output = 'à¤à¤•à¤¾ मिनिटा';\n break;\n case 'mm':\n output = '%d मिनिटां';\n break;\n case 'h':\n output = 'à¤à¤•à¤¾ तासा';\n break;\n case 'hh':\n output = '%d तासां';\n break;\n case 'd':\n output = 'à¤à¤•à¤¾ दिवसा';\n break;\n case 'dd':\n output = '%d दिवसां';\n break;\n case 'M':\n output = 'à¤à¤•à¤¾ महिनà¥à¤¯à¤¾';\n break;\n case 'MM':\n output = '%d महिनà¥à¤¯à¤¾à¤‚';\n break;\n case 'y':\n output = 'à¤à¤•à¤¾ वरà¥à¤·à¤¾';\n break;\n case 'yy':\n output = '%d वरà¥à¤·à¤¾à¤‚';\n break;\n }\n }\n return output.replace(/%d/i, number);\n }\n\n var mr = moment.defineLocale('mr', {\n months: 'जानेवारी_फेबà¥à¤°à¥à¤µà¤¾à¤°à¥€_मारà¥à¤š_à¤à¤ªà¥à¤°à¤¿à¤²_मे_जून_जà¥à¤²à¥ˆ_ऑगसà¥à¤Ÿ_सपà¥à¤Ÿà¥‡à¤‚बर_ऑकà¥à¤Ÿà¥‹à¤¬à¤°_नोवà¥à¤¹à¥‡à¤‚बर_डिसेंबर'.split(\n '_'\n ),\n monthsShort:\n 'जाने._फेबà¥à¤°à¥._मारà¥à¤š._à¤à¤ªà¥à¤°à¤¿._मे._जून._जà¥à¤²à¥ˆ._ऑग._सपà¥à¤Ÿà¥‡à¤‚._ऑकà¥à¤Ÿà¥‹._नोवà¥à¤¹à¥‡à¤‚._डिसें.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'रविवार_सोमवार_मंगळवार_बà¥à¤§à¤µà¤¾à¤°_गà¥à¤°à¥‚वार_शà¥à¤•à¥à¤°à¤µà¤¾à¤°_शनिवार'.split('_'),\n weekdaysShort: 'रवि_सोम_मंगळ_बà¥à¤§_गà¥à¤°à¥‚_शà¥à¤•à¥à¤°_शनि'.split('_'),\n weekdaysMin: 'र_सो_मं_बà¥_गà¥_शà¥_श'.split('_'),\n longDateFormat: {\n LT: 'A h:mm वाजता',\n LTS: 'A h:mm:ss वाजता',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm वाजता',\n LLLL: 'dddd, D MMMM YYYY, A h:mm वाजता',\n },\n calendar: {\n sameDay: '[आज] LT',\n nextDay: '[उदà¥à¤¯à¤¾] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[काल] LT',\n lastWeek: '[मागील] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%sमधà¥à¤¯à¥‡',\n past: '%sपूरà¥à¤µà¥€',\n s: relativeTimeMr,\n ss: relativeTimeMr,\n m: relativeTimeMr,\n mm: relativeTimeMr,\n h: relativeTimeMr,\n hh: relativeTimeMr,\n d: relativeTimeMr,\n dd: relativeTimeMr,\n M: relativeTimeMr,\n MM: relativeTimeMr,\n y: relativeTimeMr,\n yy: relativeTimeMr,\n },\n preparse: function (string) {\n return string.replace(/[१२३४५६à¥à¥®à¥¯à¥¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n meridiemParse: /पहाटे|सकाळी|दà¥à¤ªà¤¾à¤°à¥€|सायंकाळी|रातà¥à¤°à¥€/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'पहाटे' || meridiem === 'सकाळी') {\n return hour;\n } else if (\n meridiem === 'दà¥à¤ªà¤¾à¤°à¥€' ||\n meridiem === 'सायंकाळी' ||\n meridiem === 'रातà¥à¤°à¥€'\n ) {\n return hour >= 12 ? hour : hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour >= 0 && hour < 6) {\n return 'पहाटे';\n } else if (hour < 12) {\n return 'सकाळी';\n } else if (hour < 17) {\n return 'दà¥à¤ªà¤¾à¤°à¥€';\n } else if (hour < 20) {\n return 'सायंकाळी';\n } else {\n return 'रातà¥à¤°à¥€';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return mr;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { Property, Complex, ChildProperty, Collection, extend, Browser } from '@syncfusion/ej2-base';\nimport { Font, Border } from '../../common/model/base';\nimport { rotateTextSize, firstToLowerCase, valueToCoefficient, inside, isBreakLabel, isZoomSet, getTitle } from '../../common/utils/helper';\nimport { Size, Rect, measureText } from '@syncfusion/ej2-svg-base';\nimport { DoubleRange } from '../utils/double-range';\nimport { Double } from '../axis/double-axis';\nimport { axisRangeCalculated } from '../../common/model/constants';\nimport { StripLineSettings, MultiLevelLabels, LabelBorder, ScrollbarSettings } from '../model/chart-base';\nimport { textWrap } from '../../common/utils/helper';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\n/**\n * Configures the `rows` of the chart.\n */\nvar Row = /** @class */ (function (_super) {\n __extends(Row, _super);\n function Row() {\n /**\n * The height of the row as a string accept input both as '100px' and '100%'.\n * If specified as '100%, row renders to the full height of its chart.\n *\n * @default '100%'\n */\n var _this = _super !== null && _super.apply(this, arguments) || this;\n /** @private */\n _this.axes = [];\n /** @private */\n _this.nearSizes = [];\n /** @private */\n _this.farSizes = [];\n /** @private */\n _this.insideFarSizes = [];\n /** @private */\n _this.insideNearSizes = [];\n return _this;\n }\n /**\n * Measure the row size\n *\n * @returns {void}\n * @private\n */\n Row.prototype.computeSize = function (axis, scrollBarHeight, definition, chart) {\n var width = 0;\n var innerPadding = (axis.labelPosition === 'Inside' && (chart.axes.indexOf(axis) > -1)) ? -5 : 5;\n if (axis.visible && axis.internalVisibility) {\n width += (axis.findTickSize(axis.crossInAxis) + scrollBarHeight +\n axis.findLabelSize(axis.crossInAxis, innerPadding, definition, chart) + axis.lineStyle.width * 0.5);\n }\n if (axis.isAxisOpposedPosition) {\n this.farSizes.push(width);\n }\n else {\n this.nearSizes.push(width);\n }\n };\n __decorate([\n Property('100%')\n ], Row.prototype, \"height\", void 0);\n __decorate([\n Complex({}, Border)\n ], Row.prototype, \"border\", void 0);\n return Row;\n}(ChildProperty));\nexport { Row };\n/**\n * Configures the `columns` of the chart.\n */\nvar Column = /** @class */ (function (_super) {\n __extends(Column, _super);\n function Column() {\n /**\n * The width of the column as a string accepts input both as like '100px' or '100%'.\n * If specified as '100%, column renders to the full width of its chart.\n *\n * @default '100%'\n */\n var _this = _super !== null && _super.apply(this, arguments) || this;\n /** @private */\n _this.axes = [];\n /** @private */\n _this.nearSizes = [];\n /** @private */\n _this.farSizes = [];\n /** @private */\n _this.insideFarSizes = [];\n /** @private */\n _this.insideNearSizes = [];\n /** @private */\n _this.padding = 0;\n return _this;\n }\n /**\n * Measure the column size\n *\n * @returns {void}\n * @private\n */\n Column.prototype.computeSize = function (axis, scrollBarHeight, definition, chart) {\n var height = 0;\n var innerPadding = 5;\n if (axis.visible && axis.internalVisibility) {\n height += (axis.findTickSize(axis.crossInAxis) + scrollBarHeight +\n axis.findLabelSize(axis.crossInAxis, innerPadding, definition, chart) + axis.lineStyle.width * 0.5);\n }\n if (axis.isAxisOpposedPosition) {\n this.farSizes.push(height);\n }\n else {\n this.nearSizes.push(height);\n }\n };\n __decorate([\n Property('100%')\n ], Column.prototype, \"width\", void 0);\n __decorate([\n Complex({}, Border)\n ], Column.prototype, \"border\", void 0);\n return Column;\n}(ChildProperty));\nexport { Column };\n/**\n * Configures the major grid lines in the `axis`.\n */\nvar MajorGridLines = /** @class */ (function (_super) {\n __extends(MajorGridLines, _super);\n function MajorGridLines() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(1)\n ], MajorGridLines.prototype, \"width\", void 0);\n __decorate([\n Property('')\n ], MajorGridLines.prototype, \"dashArray\", void 0);\n __decorate([\n Property(null)\n ], MajorGridLines.prototype, \"color\", void 0);\n return MajorGridLines;\n}(ChildProperty));\nexport { MajorGridLines };\n/**\n * Configures the minor grid lines in the `axis`.\n */\nvar MinorGridLines = /** @class */ (function (_super) {\n __extends(MinorGridLines, _super);\n function MinorGridLines() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0.7)\n ], MinorGridLines.prototype, \"width\", void 0);\n __decorate([\n Property('')\n ], MinorGridLines.prototype, \"dashArray\", void 0);\n __decorate([\n Property(null)\n ], MinorGridLines.prototype, \"color\", void 0);\n return MinorGridLines;\n}(ChildProperty));\nexport { MinorGridLines };\n/**\n * Configures the axis line of a chart.\n */\nvar AxisLine = /** @class */ (function (_super) {\n __extends(AxisLine, _super);\n function AxisLine() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(1)\n ], AxisLine.prototype, \"width\", void 0);\n __decorate([\n Property('')\n ], AxisLine.prototype, \"dashArray\", void 0);\n __decorate([\n Property(null)\n ], AxisLine.prototype, \"color\", void 0);\n return AxisLine;\n}(ChildProperty));\nexport { AxisLine };\n/**\n * Configures the major tick lines.\n */\nvar MajorTickLines = /** @class */ (function (_super) {\n __extends(MajorTickLines, _super);\n function MajorTickLines() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(1)\n ], MajorTickLines.prototype, \"width\", void 0);\n __decorate([\n Property(5)\n ], MajorTickLines.prototype, \"height\", void 0);\n __decorate([\n Property(null)\n ], MajorTickLines.prototype, \"color\", void 0);\n return MajorTickLines;\n}(ChildProperty));\nexport { MajorTickLines };\n/**\n * Configures the minor tick lines.\n */\nvar MinorTickLines = /** @class */ (function (_super) {\n __extends(MinorTickLines, _super);\n function MinorTickLines() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0.7)\n ], MinorTickLines.prototype, \"width\", void 0);\n __decorate([\n Property(5)\n ], MinorTickLines.prototype, \"height\", void 0);\n __decorate([\n Property(null)\n ], MinorTickLines.prototype, \"color\", void 0);\n return MinorTickLines;\n}(ChildProperty));\nexport { MinorTickLines };\n/**\n * Configures the crosshair ToolTip.\n */\nvar CrosshairTooltip = /** @class */ (function (_super) {\n __extends(CrosshairTooltip, _super);\n function CrosshairTooltip() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], CrosshairTooltip.prototype, \"enable\", void 0);\n __decorate([\n Property(null)\n ], CrosshairTooltip.prototype, \"fill\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"12px\", fontStyle: 'Normal', fontWeight: '400', color: null }, Font)\n ], CrosshairTooltip.prototype, \"textStyle\", void 0);\n return CrosshairTooltip;\n}(ChildProperty));\nexport { CrosshairTooltip };\n/**\n * Configures the axes in the chart.\n *\n * @public\n */\nvar Axis = /** @class */ (function (_super) {\n __extends(Axis, _super);\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n function Axis(parent, propName, defaultValue, isArray) {\n var _this = _super.call(this, parent, propName, defaultValue, isArray) || this;\n /** @private */\n _this.visibleLabels = [];\n /** @private */\n _this.series = [];\n /** @private */\n _this.rect = new Rect(undefined, undefined, 0, 0);\n /** @private */\n _this.axisBottomLine = null;\n /** @private */\n _this.intervalDivs = [10, 5, 2, 1];\n /** @private */\n _this.isStack100 = false;\n /** @private */\n _this.crossAt = null;\n /** @private */\n _this.updatedRect = null;\n /** @private */\n _this.multiLevelLabelHeight = 0;\n /** @private */\n _this.isChart = true;\n /** @private */\n _this.isIntervalInDecimal = true;\n /** @private */\n _this.titleCollection = [];\n /** @private */\n _this.titleSize = new Size(0, 0);\n /**\n * Task: BLAZ-2044\n * This property used to hide the axis when series hide from legend click\n *\n * @private\n */\n _this.internalVisibility = true;\n /**\n * This property is used to place the vertical axis in opposed position and horizontal axis in inversed\n * when RTL is enabled in chart\n *\n * @private */\n _this.isRTLEnabled = false;\n _this.angle = _this.labelRotation;\n return _this;\n }\n /**\n * The function used to find tick size.\n *\n * @returns {number} tick line size\n * @private\n */\n Axis.prototype.findTickSize = function (crossAxis) {\n if (this.tickPosition === 'Inside') {\n return 0;\n }\n if (crossAxis && (!crossAxis.visibleRange || this.isInside(crossAxis.visibleRange))) {\n return 0;\n }\n return this.majorTickLines.height;\n };\n /**\n * The function used to find axis position.\n *\n * @returns {number}\n * @private\n */\n Axis.prototype.isInside = function (range) {\n return (inside(this.crossAt, range) ||\n (!this.isAxisOpposedPosition && this.crossAt >= range.max) || (this.isAxisOpposedPosition && this.crossAt <= range.min));\n };\n /**\n * The function used to find label Size.\n *\n * @returns {number} labelSize\n * @private\n */\n Axis.prototype.findLabelSize = function (crossAxis, innerPadding, definition, chart) {\n var titleSize = 0;\n var isHorizontal = this.orientation === 'Horizontal';\n if (this.title) {\n var angle = this.titleRotation;\n if ((isNullOrUndefined(angle))) {\n this.titleSize = measureText(this.title, this.titleStyle, chart.themeStyle.axisTitleFont);\n titleSize = this.titleSize.height + innerPadding;\n }\n else {\n this.titleSize = rotateTextSize(this.titleStyle, this.title, angle, chart);\n titleSize = (this.orientation === 'Vertical' ? this.titleSize.width : this.titleSize.height) + innerPadding;\n }\n if (this.rect.width || this.rect.height) {\n var length_1 = isHorizontal ? this.rect.width : this.rect.height;\n this.titleCollection = getTitle(this.title, this.titleStyle, length_1, chart.enableRtl, chart.themeStyle.legendLabelFont);\n titleSize = (titleSize * this.titleCollection.length);\n }\n }\n var diff;\n var value;\n var labelSize = titleSize + innerPadding + this.titlePadding + this.labelPadding +\n ((this.orientation === 'Vertical') ? this.maxLabelSize.width : this.maxLabelSize.height) + this.multiLevelLabelHeight;\n if (crossAxis && this.placeNextToAxisLine) {\n var range = crossAxis.visibleRange;\n var size = (crossAxis.orientation === 'Horizontal') ? crossAxis.rect.width : crossAxis.rect.height;\n if (!range || !size) {\n return 0;\n }\n else if (this.isInside(range)) {\n value = this.findDifference(crossAxis);\n diff = (value) * (size / range.delta);\n diff = (value) * ((size - (diff < labelSize ? (labelSize - diff) : 0)) / range.delta);\n labelSize = (diff < labelSize) ? (labelSize - diff) : 0;\n }\n }\n if (this.isAxisOpposedPosition) {\n definition.insideFarSizes.push(labelSize);\n }\n else {\n definition.insideNearSizes.push(labelSize);\n }\n if (this.labelPosition === 'Inside') {\n return titleSize + innerPadding;\n }\n return labelSize;\n };\n /**\n * The function used to find axis position.\n *\n * @returns {void}\n * @private\n */\n Axis.prototype.updateCrossValue = function () {\n var value = this.crossAt;\n if (value === null || !this.isInside(this.crossInAxis.visibleRange)) {\n this.updatedRect = this.rect;\n return null;\n }\n var range = this.crossInAxis.visibleRange;\n if (!this.isAxisOpposedPosition) {\n if (this.crossAt > range.max) {\n value = range.max;\n }\n }\n else {\n if (this.crossAt < range.min) {\n value = range.min;\n }\n }\n this.updatedRect = extend({}, this.rect, null, true);\n if (this.orientation === 'Horizontal') {\n value = this.crossInAxis.rect.height - (valueToCoefficient(value, this.crossInAxis) * this.crossInAxis.rect.height);\n this.updatedRect.y = this.crossInAxis.rect.y + value;\n }\n else {\n value = valueToCoefficient(value, this.crossInAxis) * this.crossInAxis.rect.width;\n this.updatedRect.x = this.crossInAxis.rect.x + value;\n }\n };\n Axis.prototype.findDifference = function (crossAxis) {\n var value = 0;\n if (this.isAxisOpposedPosition) {\n value = crossAxis.isAxisInverse ? crossAxis.visibleRange.min : crossAxis.visibleRange.max;\n }\n else {\n value = crossAxis.isAxisInverse ? crossAxis.visibleRange.max : crossAxis.visibleRange.min;\n }\n return Math.abs(this.crossAt - value);\n };\n /**\n * Calculate visible range for axis.\n *\n * @returns {void}\n * @private\n */\n Axis.prototype.calculateVisibleRangeOnZooming = function (size) {\n if (isZoomSet(this)) {\n var baseRange = this.actualRange;\n var start = void 0;\n var end = void 0;\n if (!this.isAxisInverse) {\n start = this.actualRange.min + this.zoomPosition * this.actualRange.delta;\n end = start + this.zoomFactor * this.actualRange.delta;\n }\n else {\n start = this.actualRange.max - (this.zoomPosition * this.actualRange.delta);\n end = start - (this.zoomFactor * this.actualRange.delta);\n }\n if (start < baseRange.min) {\n end = end + (baseRange.min - start);\n start = baseRange.min;\n }\n if (end > baseRange.max) {\n start = start - (end - baseRange.max);\n end = baseRange.max;\n }\n this.doubleRange = new DoubleRange(start, end);\n this.visibleRange = { min: this.doubleRange.start, max: this.doubleRange.end,\n delta: this.doubleRange.delta, interval: this.visibleRange.interval };\n }\n };\n /**\n * Triggers the event.\n *\n * @returns {void}\n * @private\n */\n Axis.prototype.triggerRangeRender = function (chart, minimum, maximum, interval) {\n var argsData = {\n cancel: false, name: axisRangeCalculated, axis: this,\n minimum: minimum, maximum: maximum, interval: interval\n };\n chart.trigger(axisRangeCalculated, argsData);\n if (!argsData.cancel) {\n this.visibleRange = { min: argsData.minimum, max: argsData.maximum, interval: argsData.interval,\n delta: argsData.maximum - argsData.minimum };\n }\n };\n /**\n * Calculate padding for the axis.\n *\n * @returns {string}\n * @private\n */\n Axis.prototype.getRangePadding = function (chart) {\n var padding = this.rangePadding;\n if (padding !== 'Auto') {\n return padding;\n }\n switch (this.orientation) {\n case 'Horizontal':\n if (chart.requireInvertedAxis) {\n padding = (this.isStack100 || this.baseModule.chart.stockChart ? 'Round' : 'Normal');\n }\n else {\n padding = 'None';\n }\n break;\n case 'Vertical':\n if (!chart.requireInvertedAxis) {\n padding = (this.isStack100 || this.baseModule.chart.stockChart ? 'Round' : 'Normal');\n }\n else {\n padding = 'None';\n }\n break;\n }\n return padding;\n };\n /**\n * Calculate maximum label width for the axis.\n *\n * @returns {void}\n * @private\n */\n Axis.prototype.getMaxLabelWidth = function (chart) {\n var pointX;\n var previousEnd = 0;\n var isIntersect = false;\n var isAxisLabelBreak;\n this.angle = this.labelRotation;\n this.maxLabelSize = new Size(0, 0);\n var action = this.labelIntersectAction;\n var label;\n for (var i = 0, len = this.visibleLabels.length; i < len; i++) {\n label = this.visibleLabels[i];\n isAxisLabelBreak = isBreakLabel(label.originalText);\n if (isAxisLabelBreak) {\n label.size = measureText(label.originalText.replace(/<br>/g, ' '), this.labelStyle, chart.themeStyle.axisLabelFont);\n label.breakLabelSize = measureText(this.enableTrim ? label.text.join('<br>') : label.originalText, this.labelStyle, chart.themeStyle.axisLabelFont);\n }\n else {\n label.size = measureText(label.text, this.labelStyle, chart.themeStyle.axisLabelFont);\n }\n var width = isAxisLabelBreak ? label.breakLabelSize.width : label.size.width;\n if (width > this.maxLabelSize.width) {\n this.maxLabelSize.width = width;\n this.rotatedLabel = label.text;\n }\n var height = isAxisLabelBreak ? label.breakLabelSize.height : label.size.height;\n if (height > this.maxLabelSize.height) {\n this.maxLabelSize.height = height;\n }\n if (isAxisLabelBreak) {\n label.text = this.enableTrim ? label.text : label.originalText.split('<br>');\n }\n if (action === 'None' || action === 'Hide' || action === 'Trim') {\n continue;\n }\n if ((action !== 'None' || this.angle % 360 === 0) && this.orientation === 'Horizontal' &&\n this.rect.width > 0 && !isIntersect) {\n var width1 = isAxisLabelBreak ? label.breakLabelSize.width : label.size.width;\n pointX = (valueToCoefficient(label.value, this) * this.rect.width) + this.rect.x;\n pointX -= width1 / 2;\n if (this.edgeLabelPlacement === 'Shift') {\n if (i === 0 && pointX < this.rect.x) {\n pointX = this.rect.x;\n }\n if (i === this.visibleLabels.length - 1 && ((pointX + width1) > (this.rect.x + this.rect.width))) {\n pointX = this.rect.x + this.rect.width - width1;\n }\n }\n switch (action) {\n case 'MultipleRows':\n if (i > 0) {\n this.findMultiRows(i, pointX, label, isAxisLabelBreak);\n }\n break;\n case 'Rotate45':\n case 'Rotate90':\n if (i > 0 && (!this.isAxisInverse ? pointX <= previousEnd : pointX + width1 >= previousEnd)) {\n this.angle = (action === 'Rotate45') ? 45 : 90;\n isIntersect = true;\n }\n break;\n default:\n if (isAxisLabelBreak) {\n var result = void 0;\n var result1 = [];\n var str = void 0;\n for (var index = 0; index < label.text.length; index++) {\n result = textWrap(label.text[index], this.rect.width / this.visibleLabels.length, this.labelStyle, chart.enableRtl, null, null, chart.themeStyle.axisLabelFont);\n if (result.length > 1) {\n for (var j = 0; j < result.length; j++) {\n str = result[j];\n result1.push(str);\n }\n }\n else {\n result1.push(result[0]);\n }\n }\n label.text = result1;\n }\n else {\n label.text = textWrap(label.text, this.rect.width / this.visibleLabels.length, this.labelStyle, chart.enableRtl, null, null, chart.themeStyle.axisLabelFont);\n }\n // eslint-disable-next-line no-case-declarations\n var height_1 = (label.size.height * label.text.length);\n if (height_1 > this.maxLabelSize.height) {\n this.maxLabelSize.height = height_1;\n }\n break;\n }\n previousEnd = this.isAxisInverse ? pointX : pointX + width1;\n }\n }\n if (this.angle !== 0 && this.orientation === 'Horizontal') {\n //I264474: Fix for datasource bind im mounted console error ocurred\n this.rotatedLabel = isNullOrUndefined(this.rotatedLabel) ? '' : this.rotatedLabel;\n var isHorizontalAngle = this.angle === -360 || this.angle === 0 || this.angle === -180 ||\n this.angle === 180 || this.angle === 360;\n // To avoid overlap axis label with chart title or chart legend when it is outside.\n if (this.labelPosition === 'Outside' && !isHorizontalAngle && isBreakLabel(this.rotatedLabel)) {\n this.maxLabelSize = new Size(this.maxLabelSize.height, this.maxLabelSize.width);\n }\n else {\n this.maxLabelSize = rotateTextSize(this.labelStyle, this.rotatedLabel, this.angle, chart);\n }\n }\n else if (this.angle !== 0 && this.orientation === 'Vertical') {\n //I264474: Fix for datasource bind im mounted console error ocurred\n this.rotatedLabel = isNullOrUndefined(this.rotatedLabel) ? '' : this.rotatedLabel;\n var isHorizontalAngle = this.angle === -360 || this.angle === 0 || this.angle === -180 ||\n this.angle === 180 || this.angle === 360;\n // To avoid overlap axis label with chart title or chart legend when it is outside.\n if (this.labelPosition === 'Outside' && !isHorizontalAngle && isBreakLabel(this.rotatedLabel)) {\n this.maxLabelSize = new Size(this.maxLabelSize.height, this.maxLabelSize.width);\n }\n else {\n this.maxLabelSize = rotateTextSize(this.labelStyle, this.rotatedLabel, this.angle, chart);\n }\n }\n if (chart.multiLevelLabelModule && this.multiLevelLabels.length > 0) {\n chart.multiLevelLabelModule.getMultilevelLabelsHeight(this);\n }\n };\n /**\n * Finds the multiple rows for axis.\n *\n * @returns {void}\n */\n Axis.prototype.findMultiRows = function (length, currentX, currentLabel, isBreakLabels) {\n var label;\n var pointX;\n var width2;\n var store = [];\n var isMultiRows;\n for (var i = length - 1; i >= 0; i--) {\n label = this.visibleLabels[i];\n width2 = isBreakLabels ? label.breakLabelSize.width : label.size.width;\n pointX = (valueToCoefficient(label.value, this) * this.rect.width) + this.rect.x;\n isMultiRows = !this.isAxisInverse ? currentX < (pointX + width2 * 0.5) :\n currentX + currentLabel.size.width > (pointX - width2 * 0.5);\n if (isMultiRows) {\n store.push(label.index);\n currentLabel.index = (currentLabel.index > label.index) ? currentLabel.index : label.index + 1;\n }\n else {\n currentLabel.index = store.indexOf(label.index) > -1 ? currentLabel.index : label.index;\n }\n }\n var height = ((isBreakLabels ? currentLabel.breakLabelSize.height : currentLabel.size.height) * currentLabel.index) +\n (5 * (currentLabel.index - 1));\n if (height > this.maxLabelSize.height) {\n this.maxLabelSize.height = height;\n }\n };\n /**\n * Finds the default module for axis.\n *\n * @returns {void}\n * @private\n */\n Axis.prototype.getModule = function (chart) {\n if (this.valueType === 'Double') {\n this.baseModule = new Double(chart);\n }\n else {\n this.baseModule = chart[firstToLowerCase(this.valueType) + 'Module'];\n }\n };\n /**\n * Set the axis `opposedPosition` and `isInversed` properties.\n *\n * @returns {void}\n * @private\n */\n Axis.prototype.setIsInversedAndOpposedPosition = function (isPolar) {\n if (isPolar === void 0) { isPolar = false; }\n this.isAxisOpposedPosition = this.opposedPosition || (!isPolar && this.isRTLEnabled && this.orientation === 'Vertical');\n if (this.opposedPosition && (!isPolar && this.isRTLEnabled && this.orientation === 'Vertical')) {\n this.isAxisOpposedPosition = false;\n }\n this.isAxisInverse = this.isInversed || (this.isRTLEnabled && this.orientation === 'Horizontal');\n if (this.isInversed && (!isPolar && this.isRTLEnabled && this.orientation === 'Horizontal')) {\n this.isAxisInverse = false;\n }\n };\n __decorate([\n Complex({ fontFamily: null, size: \"12px\", fontStyle: 'Normal', fontWeight: '400', color: null }, Font)\n ], Axis.prototype, \"labelStyle\", void 0);\n __decorate([\n Complex({}, CrosshairTooltip)\n ], Axis.prototype, \"crosshairTooltip\", void 0);\n __decorate([\n Property('')\n ], Axis.prototype, \"title\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"14px\", fontStyle: 'Normal', fontWeight: '600', color: null }, Font)\n ], Axis.prototype, \"titleStyle\", void 0);\n __decorate([\n Property('')\n ], Axis.prototype, \"labelFormat\", void 0);\n __decorate([\n Property('')\n ], Axis.prototype, \"skeleton\", void 0);\n __decorate([\n Property('DateTime')\n ], Axis.prototype, \"skeletonType\", void 0);\n __decorate([\n Property('Center')\n ], Axis.prototype, \"lineBreakAlignment\", void 0);\n __decorate([\n Property(0)\n ], Axis.prototype, \"plotOffset\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"plotOffsetLeft\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"plotOffsetTop\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"plotOffsetRight\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"plotOffsetBottom\", void 0);\n __decorate([\n Property(false)\n ], Axis.prototype, \"isIndexed\", void 0);\n __decorate([\n Property(10)\n ], Axis.prototype, \"logBase\", void 0);\n __decorate([\n Property(0)\n ], Axis.prototype, \"columnIndex\", void 0);\n __decorate([\n Property(0)\n ], Axis.prototype, \"rowIndex\", void 0);\n __decorate([\n Property(1)\n ], Axis.prototype, \"span\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"desiredIntervals\", void 0);\n __decorate([\n Property(3)\n ], Axis.prototype, \"maximumLabels\", void 0);\n __decorate([\n Property(1)\n ], Axis.prototype, \"zoomFactor\", void 0);\n __decorate([\n Property(0)\n ], Axis.prototype, \"zoomPosition\", void 0);\n __decorate([\n Property(true)\n ], Axis.prototype, \"enableScrollbarOnZooming\", void 0);\n __decorate([\n Property(false)\n ], Axis.prototype, \"opposedPosition\", void 0);\n __decorate([\n Property(true)\n ], Axis.prototype, \"enableAutoIntervalOnZooming\", void 0);\n __decorate([\n Property('Auto')\n ], Axis.prototype, \"rangePadding\", void 0);\n __decorate([\n Property('Double')\n ], Axis.prototype, \"valueType\", void 0);\n __decorate([\n Property('None')\n ], Axis.prototype, \"edgeLabelPlacement\", void 0);\n __decorate([\n Property('Auto')\n ], Axis.prototype, \"intervalType\", void 0);\n __decorate([\n Property('BetweenTicks')\n ], Axis.prototype, \"labelPlacement\", void 0);\n __decorate([\n Property('Outside')\n ], Axis.prototype, \"tickPosition\", void 0);\n __decorate([\n Property('Outside')\n ], Axis.prototype, \"labelPosition\", void 0);\n __decorate([\n Property('')\n ], Axis.prototype, \"name\", void 0);\n __decorate([\n Property(true)\n ], Axis.prototype, \"visible\", void 0);\n __decorate([\n Property(0)\n ], Axis.prototype, \"minorTicksPerInterval\", void 0);\n __decorate([\n Property(0)\n ], Axis.prototype, \"labelRotation\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"titleRotation\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"crossesAt\", void 0);\n __decorate([\n Property(true)\n ], Axis.prototype, \"placeNextToAxisLine\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"crossesInAxis\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"minimum\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"maximum\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"interval\", void 0);\n __decorate([\n Property(34)\n ], Axis.prototype, \"maximumLabelWidth\", void 0);\n __decorate([\n Property(false)\n ], Axis.prototype, \"enableTrim\", void 0);\n __decorate([\n Property(5)\n ], Axis.prototype, \"labelPadding\", void 0);\n __decorate([\n Property(5)\n ], Axis.prototype, \"titlePadding\", void 0);\n __decorate([\n Complex({}, MajorTickLines)\n ], Axis.prototype, \"majorTickLines\", void 0);\n __decorate([\n Complex({}, MinorTickLines)\n ], Axis.prototype, \"minorTickLines\", void 0);\n __decorate([\n Complex({}, MajorGridLines)\n ], Axis.prototype, \"majorGridLines\", void 0);\n __decorate([\n Complex({}, MinorGridLines)\n ], Axis.prototype, \"minorGridLines\", void 0);\n __decorate([\n Complex({}, AxisLine)\n ], Axis.prototype, \"lineStyle\", void 0);\n __decorate([\n Property(Browser.isDevice ? 'Rotate45' : 'Trim')\n ], Axis.prototype, \"labelIntersectAction\", void 0);\n __decorate([\n Property(false)\n ], Axis.prototype, \"isInversed\", void 0);\n __decorate([\n Property(100)\n ], Axis.prototype, \"coefficient\", void 0);\n __decorate([\n Property(0)\n ], Axis.prototype, \"startAngle\", void 0);\n __decorate([\n Property(true)\n ], Axis.prototype, \"startFromZero\", void 0);\n __decorate([\n Property(null)\n ], Axis.prototype, \"description\", void 0);\n __decorate([\n Property(2)\n ], Axis.prototype, \"tabIndex\", void 0);\n __decorate([\n Collection([], StripLineSettings)\n ], Axis.prototype, \"stripLines\", void 0);\n __decorate([\n Collection([], MultiLevelLabels)\n ], Axis.prototype, \"multiLevelLabels\", void 0);\n __decorate([\n Complex({ color: null, width: 0, type: 'Rectangle' }, LabelBorder)\n ], Axis.prototype, \"border\", void 0);\n __decorate([\n Complex({}, ScrollbarSettings)\n ], Axis.prototype, \"scrollbarSettings\", void 0);\n return Axis;\n}(ChildProperty));\nexport { Axis };\n/** @private */\nvar VisibleLabels = /** @class */ (function () {\n function VisibleLabels(text, value, labelStyle, originalText, size, breakLabelSize, index) {\n if (size === void 0) { size = new Size(0, 0); }\n if (breakLabelSize === void 0) { breakLabelSize = new Size(0, 0); }\n if (index === void 0) { index = 1; }\n this.text = text;\n this.originalText = originalText;\n this.value = value;\n this.labelStyle = labelStyle;\n this.size = size;\n this.breakLabelSize = breakLabelSize;\n this.index = index;\n }\n return VisibleLabels;\n}());\nexport { VisibleLabels };\n","//! moment.js locale configuration\n//! locale : Nepalese [ne]\n//! author : suvash : https://github.com/suvash\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '१',\n 2: '२',\n 3: '३',\n 4: '४',\n 5: '५',\n 6: '६',\n 7: 'à¥',\n 8: '८',\n 9: '९',\n 0: '०',\n },\n numberMap = {\n '१': '1',\n '२': '2',\n '३': '3',\n '४': '4',\n '५': '5',\n '६': '6',\n 'à¥': '7',\n '८': '8',\n '९': '9',\n '०': '0',\n };\n\n var ne = moment.defineLocale('ne', {\n months: 'जनवरी_फेबà¥à¤°à¥à¤µà¤°à¥€_मारà¥à¤š_अपà¥à¤°à¤¿à¤²_मई_जà¥à¤¨_जà¥à¤²à¤¾à¤ˆ_अगषà¥à¤Ÿ_सेपà¥à¤Ÿà¥‡à¤®à¥à¤¬à¤°_अकà¥à¤Ÿà¥‹à¤¬à¤°_नोà¤à¥‡à¤®à¥à¤¬à¤°_डिसेमà¥à¤¬à¤°'.split(\n '_'\n ),\n monthsShort:\n 'जन._फेबà¥à¤°à¥._मारà¥à¤š_अपà¥à¤°à¤¿._मई_जà¥à¤¨_जà¥à¤²à¤¾à¤ˆ._अग._सेपà¥à¤Ÿ._अकà¥à¤Ÿà¥‹._नोà¤à¥‡._डिसे.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'आइतबार_सोमबार_मङà¥à¤—लबार_बà¥à¤§à¤¬à¤¾à¤°_बिहिबार_शà¥à¤•à¥à¤°à¤¬à¤¾à¤°_शनिबार'.split(\n '_'\n ),\n weekdaysShort: 'आइत._सोम._मङà¥à¤—ल._बà¥à¤§._बिहि._शà¥à¤•à¥à¤°._शनि.'.split('_'),\n weekdaysMin: 'आ._सो._मं._बà¥._बि._शà¥._श.'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'Aको h:mm बजे',\n LTS: 'Aको h:mm:ss बजे',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, Aको h:mm बजे',\n LLLL: 'dddd, D MMMM YYYY, Aको h:mm बजे',\n },\n preparse: function (string) {\n return string.replace(/[१२३४५६à¥à¥®à¥¯à¥¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n meridiemParse: /राति|बिहान|दिउà¤à¤¸à¥‹|साà¤à¤/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'राति') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'बिहान') {\n return hour;\n } else if (meridiem === 'दिउà¤à¤¸à¥‹') {\n return hour >= 10 ? hour : hour + 12;\n } else if (meridiem === 'साà¤à¤') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 3) {\n return 'राति';\n } else if (hour < 12) {\n return 'बिहान';\n } else if (hour < 16) {\n return 'दिउà¤à¤¸à¥‹';\n } else if (hour < 20) {\n return 'साà¤à¤';\n } else {\n return 'राति';\n }\n },\n calendar: {\n sameDay: '[आज] LT',\n nextDay: '[à¤à¥‹à¤²à¤¿] LT',\n nextWeek: '[आउà¤à¤¦à¥‹] dddd[,] LT',\n lastDay: '[हिजो] LT',\n lastWeek: '[गà¤à¤•à¥‹] dddd[,] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%sमा',\n past: '%s अगाडि',\n s: 'केही कà¥à¤·à¤£',\n ss: '%d सेकेणà¥à¤¡',\n m: 'à¤à¤• मिनेट',\n mm: '%d मिनेट',\n h: 'à¤à¤• घणà¥à¤Ÿà¤¾',\n hh: '%d घणà¥à¤Ÿà¤¾',\n d: 'à¤à¤• दिन',\n dd: '%d दिन',\n M: 'à¤à¤• महिना',\n MM: '%d महिना',\n y: 'à¤à¤• बरà¥à¤·',\n yy: '%d बरà¥à¤·',\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return ne;\n\n})));\n","//! moment.js locale configuration\n//! locale : Chinese (Macau) [zh-mo]\n//! author : Ben : https://github.com/ben-lin\n//! author : Chris Lam : https://github.com/hehachris\n//! author : Tan Yuanhong : https://github.com/le0tan\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var zhMo = moment.defineLocale('zh-mo', {\n months: '一月_二月_三月_四月_五月_å…月_七月_八月_ä¹æœˆ_å月_å一月_å二月'.split(\n '_'\n ),\n monthsShort: '1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月'.split(\n '_'\n ),\n weekdays: '星期日_星期一_星期二_星期三_星期四_星期五_星期å…'.split('_'),\n weekdaysShort: '週日_週一_週二_週三_週四_週五_週å…'.split('_'),\n weekdaysMin: 'æ—¥_一_二_三_å››_五_å…'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'YYYYå¹´M月Dæ—¥',\n LLL: 'YYYYå¹´M月Dæ—¥ HH:mm',\n LLLL: 'YYYYå¹´M月Dæ—¥dddd HH:mm',\n l: 'D/M/YYYY',\n ll: 'YYYYå¹´M月Dæ—¥',\n lll: 'YYYYå¹´M月Dæ—¥ HH:mm',\n llll: 'YYYYå¹´M月Dæ—¥dddd HH:mm',\n },\n meridiemParse: /凌晨|早上|上åˆ|ä¸åˆ|下åˆ|晚上/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === '凌晨' || meridiem === '早上' || meridiem === '上åˆ') {\n return hour;\n } else if (meridiem === 'ä¸åˆ') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === '下åˆ' || meridiem === '晚上') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n var hm = hour * 100 + minute;\n if (hm < 600) {\n return '凌晨';\n } else if (hm < 900) {\n return '早上';\n } else if (hm < 1130) {\n return '上åˆ';\n } else if (hm < 1230) {\n return 'ä¸åˆ';\n } else if (hm < 1800) {\n return '下åˆ';\n } else {\n return '晚上';\n }\n },\n calendar: {\n sameDay: '[今天] LT',\n nextDay: '[明天] LT',\n nextWeek: '[下]dddd LT',\n lastDay: '[昨天] LT',\n lastWeek: '[上]dddd LT',\n sameElse: 'L',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(æ—¥|月|週)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'DDD':\n return number + 'æ—¥';\n case 'M':\n return number + '月';\n case 'w':\n case 'W':\n return number + '週';\n default:\n return number;\n }\n },\n relativeTime: {\n future: '%så…§',\n past: '%så‰',\n s: '幾秒',\n ss: '%d 秒',\n m: '1 分é˜',\n mm: '%d 分é˜',\n h: '1 å°æ™‚',\n hh: '%d å°æ™‚',\n d: '1 天',\n dd: '%d 天',\n M: '1 個月',\n MM: '%d 個月',\n y: '1 å¹´',\n yy: '%d å¹´',\n },\n });\n\n return zhMo;\n\n})));\n","//! moment.js locale configuration\n//! locale : Tajik [tg]\n//! author : Orif N. Jr. : https://github.com/orif-jr\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var suffixes = {\n 0: '-ум',\n 1: '-ум',\n 2: '-юм',\n 3: '-юм',\n 4: '-ум',\n 5: '-ум',\n 6: '-ум',\n 7: '-ум',\n 8: '-ум',\n 9: '-ум',\n 10: '-ум',\n 12: '-ум',\n 13: '-ум',\n 20: '-ум',\n 30: '-юм',\n 40: '-ум',\n 50: '-ум',\n 60: '-ум',\n 70: '-ум',\n 80: '-ум',\n 90: '-ум',\n 100: '-ум',\n };\n\n var tg = moment.defineLocale('tg', {\n months: {\n format: 'Ñнвари_феврали_марти_апрели_майи_июни_июли_авгуÑти_ÑентÑбри_октÑбри_ноÑбри_декабри'.split(\n '_'\n ),\n standalone:\n 'Ñнвар_феврал_март_апрел_май_июн_июл_авгуÑÑ‚_ÑентÑбр_октÑбр_ноÑбр_декабр'.split(\n '_'\n ),\n },\n monthsShort: 'Ñнв_фев_мар_апр_май_июн_июл_авг_Ñен_окт_ноÑ_дек'.split('_'),\n weekdays: 'Ñкшанбе_душанбе_Ñешанбе_чоршанбе_панҷшанбе_ҷумъа_шанбе'.split(\n '_'\n ),\n weekdaysShort: 'Ñшб_дшб_Ñшб_чшб_пшб_ҷум_шнб'.split('_'),\n weekdaysMin: 'Ñш_дш_Ñш_чш_пш_ҷм_шб'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Имрӯз Ñоати] LT',\n nextDay: '[Фардо Ñоати] LT',\n lastDay: '[Дирӯз Ñоати] LT',\n nextWeek: 'dddd[и] [ҳафтаи оÑнда Ñоати] LT',\n lastWeek: 'dddd[и] [ҳафтаи гузашта Ñоати] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'баъди %s',\n past: '%s пеш',\n s: 'Ñкчанд ÑониÑ',\n m: 'Ñк дақиқа',\n mm: '%d дақиқа',\n h: 'Ñк Ñоат',\n hh: '%d Ñоат',\n d: 'Ñк рӯз',\n dd: '%d рӯз',\n M: 'Ñк моҳ',\n MM: '%d моҳ',\n y: 'Ñк Ñол',\n yy: '%d Ñол',\n },\n meridiemParse: /шаб|Ñубҳ|рӯз|бегоҳ/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'шаб') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'Ñубҳ') {\n return hour;\n } else if (meridiem === 'рӯз') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === 'бегоҳ') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'шаб';\n } else if (hour < 11) {\n return 'Ñубҳ';\n } else if (hour < 16) {\n return 'рӯз';\n } else if (hour < 19) {\n return 'бегоҳ';\n } else {\n return 'шаб';\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(ум|юм)/,\n ordinal: function (number) {\n var a = number % 10,\n b = number >= 100 ? 100 : null;\n return number + (suffixes[number] || suffixes[a] || suffixes[b]);\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 1th is the first week of the year.\n },\n });\n\n return tg;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { merge, isNullOrUndefined, extend, Property } from '@syncfusion/ej2-base';\nimport { Query, DataUtil } from '@syncfusion/ej2-data';\nimport { ValueFormatter } from '../services/value-formatter';\nimport { getUid, templateCompiler, getForeignData, getObject } from '../base/util';\n/**\n * Represents Grid `Column` model class.\n */\nvar Column = /** @class */ (function () {\n function Column(options, parent) {\n var _this = this;\n /**\n * If `disableHtmlEncode` is set to true, it encodes the HTML of the header and content cells.\n *\n * @default true\n */\n this.disableHtmlEncode = true;\n /**\n * If `allowSorting` set to false, then it disables sorting option of a particular column.\n * By default all columns are sortable.\n *\n * @default true\n */\n this.allowSorting = true;\n /**\n * If `allowResizing` is set to false, it disables resize option of a particular column.\n * By default all the columns can be resized.\n *\n * @default true\n */\n this.allowResizing = true;\n /**\n * If `allowFiltering` set to false, then it disables filtering option and filter bar element of a particular column.\n * By default all columns are filterable.\n *\n * @default true\n */\n this.allowFiltering = true;\n /**\n * If `allowGrouping` set to false, then it disables grouping of a particular column.\n * By default all columns are groupable.\n *\n * @default true\n */\n this.allowGrouping = true;\n /**\n * If `allowReordering` set to false, then it disables reorder of a particular column.\n * By default all columns can be reorder.\n *\n * @default true\n */\n this.allowReordering = true;\n /**\n * If `showColumnMenu` set to false, then it disable the column menu of a particular column.\n * By default column menu will show for all columns\n *\n * @default true\n */\n this.showColumnMenu = true;\n /**\n * If `enableGroupByFormat` set to true, then it groups the particular column by formatted values.\n *\n * @default true\n */\n this.enableGroupByFormat = false;\n /**\n * If `allowEditing` set to false, then it disables editing of a particular column.\n * By default all columns are editable.\n *\n * @default true\n */\n this.allowEditing = true;\n /**\n * It is used to customize the default filter options for a specific columns.\n * * type - Specifies the filter type as menu or checkbox.\n * * ui - to render custom component for specific column it has following functions.\n * * ui.create – It is used for creating custom components.\n * * ui.read - It is used for read the value from the component.\n * * ui.write - It is used to apply component model as dynamically.\n * {% codeBlock src=\"grid/filter-menu-api/index.ts\" %}{% endcodeBlock %}\n *\n * > Check the [`Filter UI`](../../grid/filtering/filter-menu/#custom-component-in-filter-menu) for its customization.\n *\n * @default {}\n */\n this.filter = {};\n /**\n * If `showInColumnChooser` set to false, then hide the particular column in column chooser.\n * By default all columns are displayed in column Chooser.\n *\n * @default true\n */\n this.showInColumnChooser = true;\n /**\n * Defines the `IEditCell` object to customize default edit cell.\n *\n * @default {}\n */\n this.edit = {};\n /**\n * If `allowSearching` set to false, then it disables Searching of a particular column.\n * By default all columns allow Searching.\n *\n * @default true\n */\n this.allowSearching = true;\n /**\n * If `autoFit` set to true, then the particular column content width will be\n * adjusted based on its content in the initial rendering itself.\n * Setting this property as true is equivalent to calling `autoFitColumns` method in the `dataBound` event.\n *\n * @default false\n */\n this.autoFit = false;\n this.sortDirection = 'Descending';\n /**\n * @returns {Function} returns the edit template\n * @hidden */\n this.getEditTemplate = function () { return _this.editTemplateFn; };\n /**\n * @returns {Function} returns the filter template\n * @hidden */\n this.getFilterTemplate = function () { return _this.filterTemplateFn; };\n merge(this, options);\n this.parent = parent;\n if (this.type === 'none') {\n this.type = null;\n }\n else if (this.type) {\n this.type = typeof (this.type) === 'string' ? this.type.toLowerCase() : undefined;\n }\n if (this.editType) {\n this.editType = this.editType.toLowerCase();\n }\n if (isNullOrUndefined(this.uid)) {\n this.uid = getUid('grid-column');\n }\n var valueFormatter = new ValueFormatter();\n if (options.format && (options.format.skeleton || (options.format.format &&\n typeof options.format.format === 'string'))) {\n this.setFormatter(valueFormatter.getFormatFunction(extend({}, options.format)));\n this.setParser(valueFormatter.getParserFunction(options.format));\n }\n this.toJSON = function () {\n var col = {};\n var skip = ['filter', 'dataSource', 'headerText', 'template', 'headerTemplate', 'edit',\n 'editTemplate', 'filterTemplate', 'commandsTemplate', 'parent'];\n var keys = Object.keys(_this);\n for (var i = 0; i < keys.length; i++) {\n if (keys[parseInt(i.toString(), 10)] === 'columns') {\n col[keys[parseInt(i.toString(), 10)]] = [];\n for (var j = 0; j < _this[keys[parseInt(i.toString(), 10)]].length; j++) {\n col[keys[parseInt(i.toString(), 10)]].push(_this[keys[parseInt(i.toString(), 10)]][parseInt(j.toString(), 10)].toJSON());\n }\n }\n else if (skip.indexOf(keys[parseInt(i.toString(), 10)]) < 0) {\n col[keys[parseInt(i.toString(), 10)]] = _this[keys[parseInt(i.toString(), 10)]];\n }\n }\n return col;\n };\n if (!this.field) {\n this.allowFiltering = false;\n this.allowGrouping = false;\n this.allowSorting = false;\n if (this.columns) {\n this.allowResizing = this.columns.some(function (col) {\n return col.allowResizing;\n });\n }\n }\n if (this.commands && !this.textAlign) {\n this.textAlign = 'Right';\n }\n if (this.template || this.commandsTemplate) {\n this.templateFn = templateCompiler(this.template || this.commandsTemplate);\n }\n if (this.headerTemplate) {\n this.headerTemplateFn = templateCompiler(this.headerTemplate);\n }\n if (!isNullOrUndefined(this.filter) && this.filter.itemTemplate) {\n this.fltrTemplateFn = templateCompiler(this.filter.itemTemplate);\n }\n if (this.editTemplate) {\n this.editTemplateFn = templateCompiler(this.editTemplate);\n }\n if (this.filterTemplate) {\n this.filterTemplateFn = templateCompiler(this.filterTemplate);\n }\n if (this.isForeignColumn() &&\n (isNullOrUndefined(this.editType) || this.editType === 'dropdownedit' || this.editType === 'defaultedit')) {\n this.editType = 'dropdownedit';\n if (this.edit.params && this.edit.params.dataSource) {\n this.edit.params.ddEditedData = true;\n }\n this.edit.params = extend({\n dataSource: this.dataSource,\n query: new Query(), fields: { value: this.foreignKeyField || this.field, text: this.foreignKeyValue }\n }, this.edit.params);\n }\n if (this.sortComparer) {\n var a_1 = this.sortComparer;\n this.sortComparer = function (x, y, xObj, yObj) {\n if (typeof a_1 === 'string') {\n a_1 = getObject(a_1, window);\n }\n if (_this.sortDirection === 'Descending') {\n var z = x;\n x = y;\n y = z;\n var obj = xObj;\n xObj = yObj;\n yObj = obj;\n }\n return a_1(x, y, xObj, yObj);\n };\n }\n if (!this.sortComparer && this.isForeignColumn()) {\n this.sortComparer = function (x, y) {\n x = getObject(_this.foreignKeyValue, getForeignData(_this, {}, x)[0]);\n y = getObject(_this.foreignKeyValue, getForeignData(_this, {}, y)[0]);\n return _this.sortDirection === 'Descending' ? DataUtil.fnDescending(x, y) : DataUtil.fnAscending(x, y);\n };\n }\n }\n /**\n * @returns {string} returns the sort direction\n * @hidden */\n Column.prototype.getSortDirection = function () {\n return this.sortDirection;\n };\n /**\n * @param {string} direction - specifies the direction\n * @returns {void}\n * @hidden\n */\n Column.prototype.setSortDirection = function (direction) {\n this.sortDirection = direction;\n };\n /**\n * @returns {freezeTable} returns the FreezeTable\n * @hidden */\n Column.prototype.getFreezeTableName = function () {\n return this.freezeTable;\n };\n /**\n * @param {Column} column - specifies the column\n * @returns {void}\n * @hidden\n */\n Column.prototype.setProperties = function (column) {\n //Angular two way binding\n var keys = Object.keys(column);\n for (var i = 0; i < keys.length; i++) {\n this[keys[parseInt(i.toString(), 10)]] = column[keys[parseInt(i.toString(), 10)]];\n //Refresh the react columnTemplates on state change\n if (this.parent && this.parent.isReact) {\n if (keys[parseInt(i.toString(), 10)] === 'template') {\n this.templateFn = templateCompiler(column[keys[parseInt(i.toString(), 10)]]);\n this.parent.refreshReactColumnTemplateByUid(this.uid, true);\n }\n else if (keys[parseInt(i.toString(), 10)] === 'headerTemplate') {\n this.headerTemplateFn = templateCompiler(column[keys[parseInt(i.toString(), 10)]]);\n this.parent.refreshReactHeaderTemplateByUid(this.uid);\n }\n else if (keys[parseInt(i.toString(), 10)] === 'editTemplate') {\n this.editTemplateFn = templateCompiler(column[keys[parseInt(i.toString(), 10)]]);\n }\n }\n }\n };\n /**\n * @returns {boolean} returns true for foreign column\n * @hidden\n * It defines the column is foreign key column or not.\n */\n Column.prototype.isForeignColumn = function () {\n return !!(this.dataSource && this.foreignKeyValue);\n };\n /**\n * @returns {Function} returns the function\n * @hidden\n */\n Column.prototype.getFormatter = function () {\n return this.formatFn;\n };\n /**\n * @param {Function} value - specifies the value\n * @returns {void}\n * @hidden\n */\n Column.prototype.setFormatter = function (value) {\n this.formatFn = value;\n };\n /**\n * @returns {Function} returns the function\n * @hidden */\n Column.prototype.getParser = function () {\n return this.parserFn;\n };\n /**\n * @param {Function} value - specifies the value\n * @returns {void}\n * @hidden\n */\n Column.prototype.setParser = function (value) {\n this.parserFn = value;\n };\n /**\n * @returns {Function} returns the function\n * @hidden */\n Column.prototype.getColumnTemplate = function () {\n return this.templateFn;\n };\n /**\n * @returns {Function} returns the function\n * @hidden */\n Column.prototype.getHeaderTemplate = function () {\n return this.headerTemplateFn;\n };\n /**\n * @returns {Function} returns the function\n * @hidden */\n Column.prototype.getFilterItemTemplate = function () {\n return this.fltrTemplateFn;\n };\n /**\n * @returns {string} returns the string\n * @hidden */\n Column.prototype.getDomSetter = function () {\n return this.disableHtmlEncode ? 'textContent' : 'innerHTML';\n };\n return Column;\n}());\nexport { Column };\n/**\n * Define options for custom command buttons.\n */\nvar CommandColumnModel = /** @class */ (function () {\n function CommandColumnModel() {\n }\n __decorate([\n Property()\n ], CommandColumnModel.prototype, \"title\", void 0);\n __decorate([\n Property()\n ], CommandColumnModel.prototype, \"type\", void 0);\n __decorate([\n Property()\n ], CommandColumnModel.prototype, \"buttonOption\", void 0);\n return CommandColumnModel;\n}());\nexport { CommandColumnModel };\n/**\n * Defines Grid column\n */\nvar GridColumn = /** @class */ (function (_super) {\n __extends(GridColumn, _super);\n function GridColumn() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], GridColumn.prototype, \"columns\", void 0);\n return GridColumn;\n}(Column));\nexport { GridColumn };\n/**\n * Defines stacked grid column\n */\nvar StackedColumn = /** @class */ (function (_super) {\n __extends(StackedColumn, _super);\n function StackedColumn() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n return StackedColumn;\n}(GridColumn));\nexport { StackedColumn };\n","import { Browser, EventHandler } from '@syncfusion/ej2-base';\nimport { addClass, removeClass } from '@syncfusion/ej2-base';\nimport { formatUnit, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { getScrollBarWidth, getUpdateUsingRaf } from '../base/util';\nimport { scroll, contentReady, uiUpdate, onEmpty, headerRefreshed, textWrapRefresh, virtualScrollEdit, infiniteScrollHandler, closeFilterDialog } from '../base/constant';\nimport { lazyLoadScrollHandler, checkScrollReset } from '../base/constant';\nimport { ColumnWidthService } from '../services/width-controller';\nimport * as literals from '../base/string-literals';\nimport * as events from '../base/constant';\n/**\n * The `Scroll` module is used to handle scrolling behaviour.\n */\nvar Scroll = /** @class */ (function () {\n /**\n * Constructor for the Grid scrolling.\n *\n * @param {IGrid} parent - specifies the IGrid\n * @hidden\n */\n function Scroll(parent) {\n //To maintain scroll state on grid actions.\n this.previousValues = { top: 0, left: 0 };\n this.oneTimeReady = true;\n this.parent = parent;\n this.widthService = new ColumnWidthService(parent);\n this.addEventListener();\n }\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Scroll.prototype.getModuleName = function () {\n return 'scroll';\n };\n /**\n * @param {boolean} uiupdate - specifies the uiupdate\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.setWidth = function (uiupdate) {\n this.parent.element.style.width = formatUnit(this.parent.width);\n if (uiupdate) {\n this.widthService.setWidthToColumns();\n }\n if (this.parent.toolbarModule && this.parent.toolbarModule.toolbar &&\n this.parent.toolbarModule.toolbar.element) {\n var tlbrElement = this.parent.toolbarModule.toolbar.element;\n var tlbrLeftElement = tlbrElement.querySelector('.e-toolbar-left');\n var tlbrCenterElement = tlbrElement.querySelector('.e-toolbar-center');\n var tlbrRightElement = tlbrElement.querySelector('.e-toolbar-right');\n var tlbrItems = tlbrElement.querySelector('.e-toolbar-items');\n var tlbrLeftWidth = tlbrLeftElement ? tlbrLeftElement.clientWidth : 0;\n var tlbrCenterWidth = tlbrCenterElement ? tlbrCenterElement.clientWidth : 0;\n var tlbrRightWidth = tlbrRightElement ? tlbrRightElement.clientWidth : 0;\n var tlbrItemsWidth = tlbrItems ? tlbrItems.clientWidth : 0;\n var tlbrWidth = tlbrElement ? tlbrElement.clientWidth : 0;\n if (!this.parent.enableAdaptiveUI || tlbrLeftWidth > tlbrWidth || tlbrCenterWidth > tlbrWidth || tlbrRightWidth > tlbrWidth ||\n tlbrItemsWidth > tlbrWidth) {\n this.parent.toolbarModule.toolbar.refreshOverflow();\n }\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.setHeight = function () {\n var mHdrHeight = 0;\n var content = this.parent.getContent().querySelector('.' + literals.content);\n var height = this.parent.height;\n if (this.parent.enableColumnVirtualization && this.parent.isFrozenGrid() && this.parent.height !== 'auto'\n && this.parent.height.toString().indexOf('%') < 0) {\n height = parseInt(height, 10) - Scroll.getScrollBarWidth();\n }\n if (!this.parent.enableVirtualization && this.parent.frozenRows && this.parent.height !== 'auto') {\n var tbody = this.parent.getHeaderContent()\n .querySelector(literals.tbody + ':not(.e-masked-tbody)');\n mHdrHeight = tbody ? tbody.offsetHeight : 0;\n if (tbody && mHdrHeight) {\n var add = tbody.getElementsByClassName(literals.addedRow).length;\n var height_1 = add * this.parent.getRowHeight();\n mHdrHeight -= height_1;\n }\n else if (!this.parent.isInitialLoad && this.parent.loadingIndicator.indicatorType === 'Shimmer'\n && this.parent.getHeaderContent().querySelector('.e-masked-table')) {\n height = parseInt(height, 10) - (this.parent.frozenRows * this.parent.getRowHeight());\n }\n content.style.height = formatUnit(height - mHdrHeight);\n }\n else {\n content.style.height = formatUnit(height);\n }\n this.ensureOverflow(content);\n if (this.parent.isFrozenGrid()) {\n this.refresh();\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.setPadding = function () {\n var content = this.parent.getHeaderContent();\n var scrollWidth = Scroll.getScrollBarWidth() - this.getThreshold();\n var cssProps = this.getCssProperties();\n content.querySelector('.' + literals.headerContent).style[cssProps.border] = scrollWidth > 0 ? '1px' : '0px';\n content.style[cssProps.padding] = scrollWidth > 0 ? scrollWidth + 'px' : '0px';\n };\n /**\n * @param {boolean} rtl - specifies the rtl\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.removePadding = function (rtl) {\n var cssProps = this.getCssProperties(rtl);\n var hDiv = this.parent.getHeaderContent().querySelector('.' + literals.headerContent);\n hDiv.style[cssProps.border] = '';\n hDiv.parentElement.style[cssProps.padding] = '';\n var footerDiv = this.parent.getFooterContent();\n if (footerDiv && footerDiv.classList.contains('e-footerpadding')) {\n footerDiv.classList.remove('e-footerpadding');\n }\n };\n /**\n * Refresh makes the Grid adoptable with the height of parent container.\n *\n * > The [`height`](./#height) must be set to 100%.\n *\n * @returns {void}\n */\n Scroll.prototype.refresh = function () {\n if (this.parent.height !== '100%') {\n return;\n }\n var content = this.parent.getContent();\n this.parent.element.style.height = '100%';\n var height = this.widthService.getSiblingsHeight(content);\n content.style.height = 'calc(100% - ' + height + 'px)'; //Set the height to the '.' + literals.gridContent;\n };\n Scroll.prototype.getThreshold = function () {\n /* Some browsers places the scroller outside the content,\n * hence the padding should be adjusted.*/\n var appName = Browser.info.name;\n if (appName === 'mozilla') {\n return 0.5;\n }\n return 1;\n };\n /**\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(onEmpty, this.wireEvents, this);\n this.parent.on(contentReady, this.wireEvents, this);\n this.parent.on(uiUpdate, this.onPropertyChanged, this);\n this.parent.on(textWrapRefresh, this.wireEvents, this);\n this.parent.on(headerRefreshed, this.setScrollLeft, this);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(onEmpty, this.wireEvents);\n this.parent.off(contentReady, this.wireEvents);\n this.parent.off(uiUpdate, this.onPropertyChanged);\n this.parent.off(textWrapRefresh, this.wireEvents);\n this.parent.off(headerRefreshed, this.setScrollLeft);\n this.unwireEvents();\n };\n Scroll.prototype.unwireEvents = function () {\n if (this.parent.frozenRows && this.header) {\n EventHandler.remove(this.header, 'touchstart pointerdown', this.setPageXY);\n EventHandler.remove(this.header, 'touchmove pointermove', this.onTouchScroll);\n }\n var mScrollBar = this.parent.getContent() ? this.parent.getContent().querySelector('.e-movablescrollbar') : null;\n if (this.parent.isFrozenGrid() && this.parent.enableColumnVirtualization) {\n if (mScrollBar) {\n EventHandler.remove(mScrollBar, 'scroll', this.onCustomScrollbarScroll);\n }\n if (this.content) {\n EventHandler.remove(this.content, 'scroll', this.onCustomScrollbarScroll);\n EventHandler.remove(this.content, 'touchstart pointerdown', this.setPageXY);\n if (!(/macintosh|ipad/.test(Browser.userAgent.toLowerCase()) && Browser.isDevice)) {\n EventHandler.remove(this.content, 'touchmove pointermove', this.onTouchScroll);\n }\n }\n if (this.header) {\n EventHandler.remove(this.header, 'scroll', this.onCustomScrollbarScroll);\n EventHandler.remove(this.header, 'touchstart pointerdown', this.setPageXY);\n EventHandler.remove(this.header, 'touchmove pointermove', this.onTouchScroll);\n }\n }\n if (this.content) {\n EventHandler.remove(this.content, 'scroll', this.contentScrollHandler);\n }\n if (this.header) {\n EventHandler.remove(this.header, 'scroll', this.headerScrollHandler);\n }\n this.contentScrollHandler = null;\n this.headerScrollHandler = null;\n if (this.parent.aggregates.length && this.parent.getFooterContent()) {\n EventHandler.remove(this.parent.getFooterContent().firstChild, 'scroll', this.onContentScroll);\n }\n };\n Scroll.prototype.setScrollLeft = function () {\n this.parent.getHeaderContent().querySelector('.' + literals.headerContent).scrollLeft = this.previousValues.left;\n };\n Scroll.prototype.onContentScroll = function (scrollTarget) {\n var _this = this;\n var element = scrollTarget;\n var isHeader = element.classList.contains(literals.headerContent);\n return function (e) {\n if (_this.content.querySelector(literals.tbody) === null || _this.parent.isPreventScrollEvent) {\n return;\n }\n var target = e.target;\n if (_this.parent.frozenRows) {\n if (_this.content.scrollTop > 0 && _this.parent.frozenRows) {\n addClass([_this.parent.element], 'e-top-shadow');\n }\n else {\n removeClass([_this.parent.element], 'e-top-shadow');\n }\n }\n if (_this.parent.element.querySelectorAll('.e-leftfreeze,.e-fixedfreeze,.e-rightfreeze').length) {\n var errorFreeze = _this.parent.getContent().querySelectorAll('.e-freezeerror:not([style*=\"display: none\"])');\n var errorFixed = _this.parent.getContent().querySelectorAll('.e-fixederror:not([style*=\"display: none\"])');\n if (target.scrollLeft !== 0 && _this.parent.getVisibleFrozenLeftCount()) {\n addClass([_this.parent.element], 'e-left-shadow');\n }\n else {\n removeClass([_this.parent.element], 'e-left-shadow');\n }\n var widthVal = Math.round((_this.parent.enableRtl ? target.scrollWidth + target.scrollLeft : target.scrollWidth - target.scrollLeft) +\n (_this.parent.height === 'auto' ? 0 : 1));\n if (widthVal === target.offsetWidth && _this.parent.getVisibleFrozenRightCount()) {\n removeClass([_this.parent.element], 'e-right-shadow');\n }\n else {\n addClass([_this.parent.element], 'e-right-shadow');\n }\n var rows = [].slice.call(_this.parent.getContent().querySelectorAll('.e-row:not(.e-hiddenrow)'));\n if (((rows.length === 1 && errorFreeze.length) ||\n (_this.parent.element.querySelector('.e-freeze-autofill:not([style*=\"display: none\"])')) ||\n errorFixed.length) && target.scrollLeft !== _this.previousValues.left) {\n target.scrollLeft = _this.previousValues.left;\n return;\n }\n if (rows.length !== 1 && (errorFreeze.length || errorFixed.length) && target.scrollTop !== _this.previousValues.top) {\n target.scrollTop = _this.previousValues.top;\n return;\n }\n }\n var left = target.scrollLeft;\n if (!isNullOrUndefined(_this.parent.infiniteScrollModule) && _this.parent.enableInfiniteScrolling && !_this.parent.isEdit) {\n _this.parent.notify(infiniteScrollHandler, { target: e.target, isLeft: _this.previousValues.left !== left });\n }\n if (_this.parent.groupSettings.columns.length && _this.parent.groupSettings.enableLazyLoading) {\n var isDown = _this.previousValues.top < _this.parent.getContent().firstElementChild.scrollTop;\n _this.parent.notify(lazyLoadScrollHandler, { scrollDown: isDown });\n }\n _this.parent.notify(virtualScrollEdit, {});\n var isFooter = target.classList.contains('e-summarycontent');\n if (_this.previousValues.left === left) {\n _this.previousValues.top = !isHeader ? _this.previousValues.top : target.scrollTop;\n return;\n }\n _this.parent.notify(closeFilterDialog, e);\n element.scrollLeft = left;\n if (isFooter) {\n _this.header.scrollLeft = left;\n }\n _this.previousValues.left = left;\n _this.parent.notify(scroll, { left: left });\n };\n };\n Scroll.prototype.onCustomScrollbarScroll = function (cont, hdr) {\n var _this = this;\n var content = cont;\n var header = hdr;\n return function (e) {\n if (_this.content.querySelector(literals.tbody) === null) {\n return;\n }\n var target = e.target;\n var left = target.scrollLeft;\n if (_this.previousValues.left === left) {\n return;\n }\n content.scrollLeft = left;\n header.scrollLeft = left;\n _this.previousValues.left = left;\n _this.parent.notify(scroll, { left: left });\n if (_this.parent.isDestroyed) {\n return;\n }\n };\n };\n Scroll.prototype.onTouchScroll = function (scrollTarget) {\n var _this = this;\n var element = scrollTarget;\n return function (e) {\n if (e.pointerType === 'mouse') {\n return;\n }\n var isFrozen = _this.parent.isFrozenGrid();\n var pageXY = _this.getPointXY(e);\n var left = element.scrollLeft + (_this.pageXY.x - pageXY.x);\n var mHdr = _this.parent.getHeaderContent().querySelector('.' + literals.headerContent);\n var mCont = _this.parent.getContent().querySelector('.' + literals.content);\n if (_this.previousValues.left === left || (left < 0 || (mHdr.scrollWidth - mHdr.clientWidth) < left)) {\n return;\n }\n e.preventDefault();\n mHdr.scrollLeft = left;\n mCont.scrollLeft = left;\n if (isFrozen && _this.parent.enableColumnVirtualization) {\n var scrollBar = _this.parent.getContent().querySelector('.e-movablescrollbar');\n scrollBar.scrollLeft = left;\n }\n _this.pageXY.x = pageXY.x;\n _this.previousValues.left = left;\n };\n };\n Scroll.prototype.setPageXY = function () {\n var _this = this;\n return function (e) {\n if (e.pointerType === 'mouse') {\n return;\n }\n _this.pageXY = _this.getPointXY(e);\n };\n };\n Scroll.prototype.getPointXY = function (e) {\n var pageXY = { x: 0, y: 0 };\n if (e.touches && e.touches.length) {\n pageXY.x = e.touches[0].pageX;\n pageXY.y = e.touches[0].pageY;\n }\n else {\n pageXY.x = e.pageX;\n pageXY.y = e.pageY;\n }\n return pageXY;\n };\n Scroll.prototype.getScrollbleParent = function (node) {\n if (node === null) {\n return null;\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var parent = isNullOrUndefined(node.tagName) ? node.scrollingElement : node;\n var overflowY = document.defaultView.getComputedStyle(parent, null).overflowY;\n if (parent.scrollHeight > parent.clientHeight && overflowY !== 'hidden'\n && overflowY !== 'visible' || node.tagName === 'HTML' || node.tagName === 'BODY') {\n return node;\n }\n else {\n return this.getScrollbleParent(node.parentNode);\n }\n };\n /**\n * @param {boolean} isAdd - specifies whether adding/removing the event\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.addStickyListener = function (isAdd) {\n this.parentElement = this.getScrollbleParent(this.parent.element.parentElement);\n if (isAdd && this.parentElement) {\n this.eventElement = this.parentElement.tagName === 'HTML' || this.parentElement.tagName === 'BODY' ? document :\n this.parentElement;\n EventHandler.add(this.eventElement, 'scroll', this.makeStickyHeader, this);\n }\n else if (this.eventElement) {\n EventHandler.remove(this.eventElement, 'scroll', this.makeStickyHeader);\n this.eventElement = null;\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.resizeFrozenRowBorder = function () {\n var div;\n if (!this.parent.element.querySelector('.e-frozenrow-border')) {\n div = this.parent.createElement('div', { className: 'e-frozenrow-border' });\n this.parent.element.insertBefore(div, this.parent.element.querySelector('.e-gridcontent'));\n }\n else {\n div = this.parent.element.querySelector('.e-frozenrow-border');\n }\n var scrollWidth = this.parent.height !== 'auto' ? Scroll.getScrollBarWidth() : 0;\n div.style.width = (this.parent.element.offsetWidth - scrollWidth) - 0.5 + 'px';\n };\n Scroll.prototype.wireEvents = function () {\n var _this = this;\n if (this.oneTimeReady) {\n var frzCols = this.parent.isFrozenGrid();\n this.content = this.parent.getContent().querySelector('.' + literals.content);\n this.header = this.parent.getHeaderContent().querySelector('.' + literals.headerContent);\n var mScrollBar = this.parent.getContent().querySelector('.e-movablescrollbar');\n if (this.parent.frozenRows && this.header && this.content) {\n EventHandler.add(this.header, 'touchstart pointerdown', this.setPageXY(), this);\n EventHandler.add(this.header, 'touchmove pointermove', this.onTouchScroll(this.content), this);\n }\n if (frzCols && mScrollBar && this.parent.enableColumnVirtualization) {\n EventHandler.add(mScrollBar, 'scroll', this.onCustomScrollbarScroll(this.content, this.header), this);\n EventHandler.add(this.content, 'scroll', this.onCustomScrollbarScroll(mScrollBar, this.header), this);\n EventHandler.add(this.header, 'scroll', this.onCustomScrollbarScroll(mScrollBar, this.content), this);\n EventHandler.add(this.header, 'touchstart pointerdown', this.setPageXY(), this);\n EventHandler.add(this.header, 'touchmove pointermove', this.onTouchScroll(this.content), this);\n EventHandler.add(this.content, 'touchstart pointerdown', this.setPageXY(), this);\n if (!(/macintosh|ipad/.test(Browser.userAgent.toLowerCase()) && Browser.isDevice)) {\n EventHandler.add(this.content, 'touchmove pointermove', this.onTouchScroll(this.header), this);\n }\n }\n this.contentScrollHandler = this.onContentScroll(this.header);\n this.headerScrollHandler = this.onContentScroll(this.content);\n EventHandler.add(this.content, 'scroll', this.contentScrollHandler, this);\n EventHandler.add(this.header, 'scroll', this.headerScrollHandler, this);\n if (this.parent.aggregates.length) {\n EventHandler.add(this.parent.getFooterContent().firstChild, 'scroll', this.onContentScroll(this.content), this);\n }\n if (this.parent.enableStickyHeader) {\n this.addStickyListener(true);\n }\n this.refresh();\n this.oneTimeReady = false;\n }\n var table = this.parent.getContentTable();\n var sLeft;\n var sHeight;\n var clientHeight;\n getUpdateUsingRaf(function () {\n sLeft = _this.header.scrollLeft;\n sHeight = table.scrollHeight;\n clientHeight = _this.parent.getContent().clientHeight;\n }, function () {\n var args = { cancel: false };\n _this.parent.notify(checkScrollReset, args);\n if (sHeight < clientHeight && _this.parent.height !== 'auto') {\n _this.setLastRowCell();\n }\n if (_this.parent.frozenRows) {\n _this.resizeFrozenRowBorder();\n }\n if (!_this.parent.enableVirtualization && !_this.parent.enableInfiniteScrolling) {\n if (!args.cancel) {\n _this.header.scrollLeft = _this.previousValues.left;\n _this.content.scrollLeft = _this.previousValues.left;\n _this.content.scrollTop = _this.previousValues.top;\n }\n }\n if (!_this.parent.enableColumnVirtualization) {\n _this.content.scrollLeft = sLeft;\n if (_this.parent.isFrozenGrid()) {\n _this.previousValues.left = sLeft;\n }\n }\n });\n this.parent.isPreventScrollEvent = false;\n };\n /**\n * @returns {void} returns void\n * @hidden\n */\n Scroll.prototype.setLastRowCell = function () {\n var table = this.parent.getContentTable();\n if (table.querySelector('tr:nth-last-child(2)')) {\n removeClass(table.querySelector('tr:nth-last-child(2)').querySelectorAll('td'), 'e-lastrowcell');\n }\n addClass(table.querySelectorAll('tr:last-child td'), 'e-lastrowcell');\n };\n /**\n * @param {boolean} rtl - specifies the rtl\n * @returns {ScrollCss} returns the ScrollCss\n * @hidden\n */\n Scroll.prototype.getCssProperties = function (rtl) {\n var css = {};\n var enableRtl = isNullOrUndefined(rtl) ? this.parent.enableRtl : rtl;\n css.border = enableRtl ? 'borderLeftWidth' : 'borderRightWidth';\n css.padding = enableRtl ? 'paddingLeft' : 'paddingRight';\n return css;\n };\n Scroll.prototype.ensureOverflow = function (content) {\n content.style.overflowY = this.parent.height === 'auto' ? 'auto' : 'scroll';\n };\n Scroll.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName()) {\n return;\n }\n this.setPadding();\n this.oneTimeReady = true;\n if (this.parent.height === 'auto') {\n this.removePadding();\n }\n this.wireEvents();\n this.setHeight();\n var width = 'width';\n this.setWidth(!isNullOrUndefined(e.properties[\"\" + width]));\n };\n Scroll.prototype.makeStickyHeader = function () {\n if (this.parent.enableStickyHeader && this.parent.element && this.parent.getContent()) {\n var contentRect = this.parent.getContent().getClientRects()[0];\n if (contentRect) {\n var headerEle = this.parent.getHeaderContent();\n var toolbarEle = this.parent.element.querySelector('.e-toolbar');\n var groupHeaderEle = this.parent.element.querySelector('.e-groupdroparea');\n var height = headerEle.offsetHeight + (toolbarEle ? toolbarEle.offsetHeight : 0) +\n (groupHeaderEle ? groupHeaderEle.offsetHeight : 0);\n var parentTop = this.parentElement.getClientRects()[0].top;\n var top_1 = contentRect.top - (parentTop < 0 ? 0 : parentTop);\n var left = contentRect.left;\n var colMenuEle = document.body.querySelector('#' + this.parent.element.id + '_columnmenu');\n if (top_1 < height && contentRect.bottom > 0) {\n headerEle.classList.add('e-sticky');\n var elemTop = 0;\n if (groupHeaderEle && this.parent.groupSettings.showDropArea) {\n this.setSticky(groupHeaderEle, elemTop, contentRect.width, left, true);\n elemTop += groupHeaderEle.getClientRects()[0].height;\n }\n if (toolbarEle) {\n this.setSticky(toolbarEle, elemTop, contentRect.width, left, true);\n elemTop += toolbarEle.getClientRects()[0].height;\n }\n this.setSticky(headerEle, elemTop, contentRect.width, left, true);\n if (!isNullOrUndefined(colMenuEle)) {\n colMenuEle.style.position = 'fixed';\n colMenuEle.style.top = height + 'px';\n }\n }\n else {\n if (headerEle.classList.contains('e-sticky')) {\n this.setSticky(headerEle, null, null, null, false);\n if (toolbarEle) {\n this.setSticky(toolbarEle, null, null, null, false);\n }\n if (groupHeaderEle) {\n this.setSticky(groupHeaderEle, null, null, null, false);\n }\n var ccDlg = this.parent.element.querySelector('.e-ccdlg');\n if (ccDlg) {\n ccDlg.classList.remove('e-sticky');\n }\n if (!isNullOrUndefined(colMenuEle)) {\n colMenuEle.style.position = 'absolute';\n var topStyle = contentRect.top - parentTop;\n colMenuEle.style.top = topStyle + 'px';\n }\n }\n }\n this.parent.notify(events.stickyScrollComplete, {});\n }\n }\n };\n Scroll.prototype.setSticky = function (ele, top, width, left, isAdd) {\n if (isAdd) {\n ele.style.width = width + 'px';\n ele.classList.add('e-sticky');\n }\n else {\n ele.classList.remove('e-sticky');\n }\n ele.style.top = top != null ? top + 'px' : '';\n ele.style.left = left !== null ? parseInt(ele.style.left, 10) !== left ? left + 'px' : ele.style.left : '';\n };\n /**\n * @returns {void}\n * @hidden\n */\n Scroll.prototype.destroy = function () {\n var gridElement = this.parent.element;\n if (!gridElement || (!gridElement.querySelector('.' + literals.gridHeader) && !gridElement.querySelector('.' + literals.gridContent))) {\n return;\n }\n this.removeEventListener();\n //Remove Dom event\n var cont = this.parent.getContent().querySelector('.' + literals.content);\n EventHandler.remove(cont, 'scroll', this.onContentScroll);\n if (this.parent.enableStickyHeader) {\n this.addStickyListener(false);\n }\n //Remove padding\n this.removePadding();\n removeClass([this.parent.getHeaderContent().querySelector('.' + literals.headerContent)], literals.headerContent);\n removeClass([cont], literals.content);\n //Remove height\n cont.style.height = '';\n //Remove width\n this.parent.element.style.width = '';\n };\n /**\n * Function to get the scrollbar width of the browser.\n *\n * @returns {number} return the width\n * @hidden\n */\n Scroll.getScrollBarWidth = function () {\n return getScrollBarWidth();\n };\n return Scroll;\n}());\nexport { Scroll };\n","//! moment.js locale configuration\n//! locale : Czech [cs]\n//! author : petrbela : https://github.com/petrbela\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var months = {\n format: 'leden_únor_bÅ™ezen_duben_kvÄ›ten_Äerven_Äervenec_srpen_zářÃ_Å™Ãjen_listopad_prosinec'.split(\n '_'\n ),\n standalone:\n 'ledna_února_bÅ™ezna_dubna_kvÄ›tna_Äervna_Äervence_srpna_zářÃ_Å™Ãjna_listopadu_prosince'.split(\n '_'\n ),\n },\n monthsShort = 'led_úno_bÅ™e_dub_kvÄ›_Ävn_Ävc_srp_zář_Å™Ãj_lis_pro'.split('_'),\n monthsParse = [\n /^led/i,\n /^úno/i,\n /^bÅ™e/i,\n /^dub/i,\n /^kvÄ›/i,\n /^(Ävn|Äerven$|Äervna)/i,\n /^(Ävc|Äervenec|Äervence)/i,\n /^srp/i,\n /^zář/i,\n /^Å™Ãj/i,\n /^lis/i,\n /^pro/i,\n ],\n // NOTE: 'Äerven' is substring of 'Äervenec'; therefore 'Äervenec' must precede 'Äerven' in the regex to be fully matched.\n // Otherwise parser matches '1. Äervenec' as '1. Äerven' + 'ec'.\n monthsRegex =\n /^(leden|únor|bÅ™ezen|duben|kvÄ›ten|Äervenec|Äervence|Äerven|Äervna|srpen|zářÃ|Å™Ãjen|listopad|prosinec|led|úno|bÅ™e|dub|kvÄ›|Ävn|Ävc|srp|zář|Å™Ãj|lis|pro)/i;\n\n function plural(n) {\n return n > 1 && n < 5 && ~~(n / 10) !== 1;\n }\n function translate(number, withoutSuffix, key, isFuture) {\n var result = number + ' ';\n switch (key) {\n case 's': // a few seconds / in a few seconds / a few seconds ago\n return withoutSuffix || isFuture ? 'pár sekund' : 'pár sekundami';\n case 'ss': // 9 seconds / in 9 seconds / 9 seconds ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'sekundy' : 'sekund');\n } else {\n return result + 'sekundami';\n }\n case 'm': // a minute / in a minute / a minute ago\n return withoutSuffix ? 'minuta' : isFuture ? 'minutu' : 'minutou';\n case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'minuty' : 'minut');\n } else {\n return result + 'minutami';\n }\n case 'h': // an hour / in an hour / an hour ago\n return withoutSuffix ? 'hodina' : isFuture ? 'hodinu' : 'hodinou';\n case 'hh': // 9 hours / in 9 hours / 9 hours ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'hodiny' : 'hodin');\n } else {\n return result + 'hodinami';\n }\n case 'd': // a day / in a day / a day ago\n return withoutSuffix || isFuture ? 'den' : 'dnem';\n case 'dd': // 9 days / in 9 days / 9 days ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'dny' : 'dnÃ');\n } else {\n return result + 'dny';\n }\n case 'M': // a month / in a month / a month ago\n return withoutSuffix || isFuture ? 'mÄ›sÃc' : 'mÄ›sÃcem';\n case 'MM': // 9 months / in 9 months / 9 months ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'mÄ›sÃce' : 'mÄ›sÃců');\n } else {\n return result + 'mÄ›sÃci';\n }\n case 'y': // a year / in a year / a year ago\n return withoutSuffix || isFuture ? 'rok' : 'rokem';\n case 'yy': // 9 years / in 9 years / 9 years ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'roky' : 'let');\n } else {\n return result + 'lety';\n }\n }\n }\n\n var cs = moment.defineLocale('cs', {\n months: months,\n monthsShort: monthsShort,\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n // NOTE: 'Äerven' is substring of 'Äervenec'; therefore 'Äervenec' must precede 'Äerven' in the regex to be fully matched.\n // Otherwise parser matches '1. Äervenec' as '1. Äerven' + 'ec'.\n monthsStrictRegex:\n /^(leden|ledna|února|únor|bÅ™ezen|bÅ™ezna|duben|dubna|kvÄ›ten|kvÄ›tna|Äervenec|Äervence|Äerven|Äervna|srpen|srpna|zářÃ|Å™Ãjen|Å™Ãjna|listopadu|listopad|prosinec|prosince)/i,\n monthsShortStrictRegex:\n /^(led|úno|bÅ™e|dub|kvÄ›|Ävn|Ävc|srp|zář|Å™Ãj|lis|pro)/i,\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n weekdays: 'nedÄ›le_pondÄ›lÃ_úterý_stÅ™eda_Ätvrtek_pátek_sobota'.split('_'),\n weekdaysShort: 'ne_po_út_st_Ät_pá_so'.split('_'),\n weekdaysMin: 'ne_po_út_st_Ät_pá_so'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY H:mm',\n LLLL: 'dddd D. MMMM YYYY H:mm',\n l: 'D. M. YYYY',\n },\n calendar: {\n sameDay: '[dnes v] LT',\n nextDay: '[zÃtra v] LT',\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[v nedÄ›li v] LT';\n case 1:\n case 2:\n return '[v] dddd [v] LT';\n case 3:\n return '[ve stÅ™edu v] LT';\n case 4:\n return '[ve Ätvrtek v] LT';\n case 5:\n return '[v pátek v] LT';\n case 6:\n return '[v sobotu v] LT';\n }\n },\n lastDay: '[vÄera v] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n return '[minulou nedÄ›li v] LT';\n case 1:\n case 2:\n return '[minulé] dddd [v] LT';\n case 3:\n return '[minulou stÅ™edu v] LT';\n case 4:\n case 5:\n return '[minulý] dddd [v] LT';\n case 6:\n return '[minulou sobotu v] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'za %s',\n past: 'pÅ™ed %s',\n s: translate,\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: translate,\n dd: translate,\n M: translate,\n MM: translate,\n y: translate,\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return cs;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { Row } from '../models/row';\nimport { Column } from '../models/column';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { calculateAggregate, getUid } from '../base/util';\nimport { CellType } from '../base/enum';\nimport { Cell } from '../models/cell';\n/**\n * Summary row model generator\n *\n * @hidden\n */\nvar SummaryModelGenerator = /** @class */ (function () {\n /**\n * Constructor for Summary row model generator\n *\n * @param {IGrid} parent - specifies the IGrid\n */\n function SummaryModelGenerator(parent) {\n this.parent = parent;\n }\n SummaryModelGenerator.prototype.getData = function () {\n var _this = this;\n var rows = [];\n var row = this.parent.aggregates.slice();\n for (var i = 0; i < row.length; i++) {\n var columns = row[parseInt(i.toString(), 10)].columns.filter(function (column) {\n return !(column.footerTemplate || column.groupFooterTemplate || column.groupCaptionTemplate)\n || _this.columnSelector(column);\n });\n if (columns.length) {\n rows.push({ columns: columns });\n }\n }\n return rows;\n };\n SummaryModelGenerator.prototype.columnSelector = function (column) {\n return column.footerTemplate !== undefined;\n };\n SummaryModelGenerator.prototype.getColumns = function (start) {\n var columns = [];\n if (this.parent.detailTemplate || !isNullOrUndefined(this.parent.childGrid)) {\n columns.push(new Column({}));\n }\n if (this.parent.allowGrouping) {\n for (var i = 0; i < this.parent.groupSettings.columns.length; i++) {\n columns.push(new Column({}));\n }\n }\n if (this.parent.isRowDragable() && !start) {\n columns.push(new Column({}));\n }\n columns.push.apply(columns, this.parent.getColumns());\n return columns;\n };\n SummaryModelGenerator.prototype.generateRows = function (input, args, start, end, columns) {\n if (input.length === 0) {\n if (args === undefined || !args.count) {\n return [];\n }\n }\n var data = this.buildSummaryData(input, args);\n var rows = [];\n var row = this.getData();\n for (var i = 0; i < row.length; i++) {\n rows.push(this.getGeneratedRow(row[parseInt(i.toString(), 10)], data[parseInt(i.toString(), 10)], args ? args.level : undefined, start, end, args ? args.parentUid : undefined, columns));\n }\n return rows;\n };\n SummaryModelGenerator.prototype.getGeneratedRow = function (summaryRow, data, raw, start, end, parentUid, columns) {\n var tmp = [];\n var indents = this.getIndentByLevel();\n var isDetailGridAlone = !isNullOrUndefined(this.parent.childGrid);\n var indentLength = this.parent.getIndentCount();\n if (this.parent.groupSettings.columns.length && this.parent.allowRowDragAndDrop) {\n indents.push('e-indentcelltop');\n }\n else if (this.parent.isRowDragable() && !start) {\n indents = ['e-indentcelltop'];\n }\n var values = columns ? columns : this.getColumns(start);\n for (var i = 0; i < values.length; i++) {\n tmp.push(this.getGeneratedCell(values[parseInt(i.toString(), 10)], summaryRow, i >= indentLength ? this.getCellType() :\n i === 0 && this.parent.childGrid ? CellType.DetailFooterIntent : CellType.Indent, indents[parseInt(i.toString(), 10)], isDetailGridAlone));\n }\n var row = new Row({ data: data, attributes: { class: 'e-summaryrow' } });\n row.cells = tmp;\n row.uid = getUid('grid-row');\n row.parentUid = parentUid;\n row.isAggregateRow = true;\n row.visible = tmp.some(function (cell) { return cell.isDataCell && cell.visible; });\n return row;\n };\n SummaryModelGenerator.prototype.getGeneratedCell = function (column, summaryRow, cellType, indent, isDetailGridAlone) {\n //Get the summary column by display\n var sColumn = summaryRow.columns.filter(function (scolumn) { return scolumn.columnName === column.field; })[0];\n var attrs = {\n 'style': { 'textAlign': column.textAlign },\n 'e-mappinguid': column.uid, index: column.index\n };\n if (indent) {\n attrs.class = indent;\n }\n if (isNullOrUndefined(indent) && isDetailGridAlone) {\n attrs.class = 'e-detailindentcelltop';\n }\n var opt = {\n 'visible': column.visible,\n 'isDataCell': !isNullOrUndefined(sColumn),\n 'isTemplate': sColumn && !isNullOrUndefined(sColumn.footerTemplate\n || sColumn.groupFooterTemplate || sColumn.groupCaptionTemplate),\n 'column': sColumn || {},\n 'attributes': attrs,\n 'cellType': cellType\n };\n opt.column.headerText = column.headerText;\n return new Cell(opt);\n };\n SummaryModelGenerator.prototype.buildSummaryData = function (data, args) {\n var dummy = [];\n var summaryRows = this.getData();\n var single = {};\n for (var i = 0; i < summaryRows.length; i++) {\n single = {};\n var column = summaryRows[parseInt(i.toString(), 10)].columns;\n for (var j = 0; j < column.length; j++) {\n single = this.setTemplate(column[parseInt(j.toString(), 10)], (args && args.aggregates) ? args : data, single);\n }\n dummy.push(single);\n }\n return dummy;\n };\n SummaryModelGenerator.prototype.getIndentByLevel = function () {\n return this.parent.groupSettings.columns.map(function () { return 'e-indentcelltop'; });\n };\n SummaryModelGenerator.prototype.setTemplate = function (column, data, single) {\n var types = column.type;\n var helper = {};\n var formatFn = column.getFormatter() || (function () { return function (a) { return a; }; })();\n var group = data;\n if (!(types instanceof Array)) {\n types = [column.type];\n }\n for (var i = 0; i < types.length; i++) {\n var key = column.field + ' - ' + types[parseInt(i.toString(), 10)].toLowerCase();\n var disp = column.columnName;\n var val = types[parseInt(i.toString(), 10)] !== 'Custom' && group.aggregates && key in group.aggregates ? group.aggregates[\"\" + key] :\n calculateAggregate(types[parseInt(i.toString(), 10)], group.aggregates ? group : data, column, this.parent);\n single[\"\" + disp] = single[\"\" + disp] || {};\n single[\"\" + disp][\"\" + key] = val;\n single[\"\" + disp][types[parseInt(i.toString(), 10)]] = !isNullOrUndefined(val) ? formatFn(val) : ' ';\n if (group.field) {\n single[\"\" + disp].field = group.field;\n single[\"\" + disp].key = group.key;\n }\n }\n helper.format = column.getFormatter();\n column.setTemplate(helper);\n return single;\n };\n SummaryModelGenerator.prototype.getCellType = function () {\n return CellType.Summary;\n };\n return SummaryModelGenerator;\n}());\nexport { SummaryModelGenerator };\nvar GroupSummaryModelGenerator = /** @class */ (function (_super) {\n __extends(GroupSummaryModelGenerator, _super);\n function GroupSummaryModelGenerator() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n GroupSummaryModelGenerator.prototype.columnSelector = function (column) {\n return column.groupFooterTemplate !== undefined;\n };\n GroupSummaryModelGenerator.prototype.getIndentByLevel = function (level) {\n if (level === void 0) { level = this.parent.groupSettings.columns.length; }\n if (this.parent.allowRowDragAndDrop && this.parent.groupSettings.columns.length) {\n level -= 1;\n }\n return this.parent.groupSettings.columns.map(function (v, indx) { return indx <= level - 1 ? '' : 'e-indentcelltop'; });\n };\n GroupSummaryModelGenerator.prototype.getCellType = function () {\n return CellType.GroupSummary;\n };\n return GroupSummaryModelGenerator;\n}(SummaryModelGenerator));\nexport { GroupSummaryModelGenerator };\nvar CaptionSummaryModelGenerator = /** @class */ (function (_super) {\n __extends(CaptionSummaryModelGenerator, _super);\n function CaptionSummaryModelGenerator() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n CaptionSummaryModelGenerator.prototype.columnSelector = function (column) {\n return column.groupCaptionTemplate !== undefined;\n };\n CaptionSummaryModelGenerator.prototype.getData = function () {\n var initVal = { columns: [] };\n return [_super.prototype.getData.call(this).reduce(function (prev, cur) {\n prev.columns = prev.columns.concat(cur.columns);\n return prev;\n }, initVal)];\n };\n CaptionSummaryModelGenerator.prototype.isEmpty = function () {\n return (this.getData()[0].columns || []).length === 0;\n };\n CaptionSummaryModelGenerator.prototype.getCellType = function () {\n return CellType.CaptionSummary;\n };\n return CaptionSummaryModelGenerator;\n}(SummaryModelGenerator));\nexport { CaptionSummaryModelGenerator };\n","//! moment.js locale configuration\n//! locale : Tamil [ta]\n//! author : Arjunkumar Krishnamoorthy : https://github.com/tk120404\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '௧',\n 2: '௨',\n 3: '௩',\n 4: '௪',\n 5: '௫',\n 6: '௬',\n 7: 'à¯',\n 8: '௮',\n 9: '௯',\n 0: '௦',\n },\n numberMap = {\n '௧': '1',\n '௨': '2',\n '௩': '3',\n '௪': '4',\n '௫': '5',\n '௬': '6',\n 'à¯': '7',\n '௮': '8',\n '௯': '9',\n '௦': '0',\n };\n\n var ta = moment.defineLocale('ta', {\n months: 'ஜனவரி_பிபà¯à®°à®µà®°à®¿_மாரà¯à®šà¯_à®à®ªà¯à®°à®²à¯_மே_ஜூனà¯_ஜூலை_ஆகஸà¯à®Ÿà¯_செபà¯à®Ÿà¯†à®®à¯à®ªà®°à¯_அகà¯à®Ÿà¯‡à®¾à®ªà®°à¯_நவமà¯à®ªà®°à¯_டிசமà¯à®ªà®°à¯'.split(\n '_'\n ),\n monthsShort:\n 'ஜனவரி_பிபà¯à®°à®µà®°à®¿_மாரà¯à®šà¯_à®à®ªà¯à®°à®²à¯_மே_ஜூனà¯_ஜூலை_ஆகஸà¯à®Ÿà¯_செபà¯à®Ÿà¯†à®®à¯à®ªà®°à¯_அகà¯à®Ÿà¯‡à®¾à®ªà®°à¯_நவமà¯à®ªà®°à¯_டிசமà¯à®ªà®°à¯'.split(\n '_'\n ),\n weekdays:\n 'ஞாயிறà¯à®±à¯à®•à¯à®•à®¿à®´à®®à¯ˆ_திஙà¯à®•à®Ÿà¯à®•à®¿à®´à®®à¯ˆ_செவà¯à®µà®¾à®¯à¯à®•à®¿à®´à®®à¯ˆ_பà¯à®¤à®©à¯à®•à®¿à®´à®®à¯ˆ_வியாழகà¯à®•à®¿à®´à®®à¯ˆ_வெளà¯à®³à®¿à®•à¯à®•à®¿à®´à®®à¯ˆ_சனிகà¯à®•à®¿à®´à®®à¯ˆ'.split(\n '_'\n ),\n weekdaysShort: 'ஞாயிறà¯_திஙà¯à®•à®³à¯_செவà¯à®µà®¾à®¯à¯_பà¯à®¤à®©à¯_வியாழனà¯_வெளà¯à®³à®¿_சனி'.split(\n '_'\n ),\n weekdaysMin: 'ஞா_தி_செ_பà¯_வி_வெ_ச'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, HH:mm',\n LLLL: 'dddd, D MMMM YYYY, HH:mm',\n },\n calendar: {\n sameDay: '[இனà¯à®±à¯] LT',\n nextDay: '[நாளை] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[நேறà¯à®±à¯] LT',\n lastWeek: '[கடநà¯à®¤ வாரமà¯] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s இலà¯',\n past: '%s à®®à¯à®©à¯',\n s: 'ஒர௠சில விநாடிகளà¯',\n ss: '%d விநாடிகளà¯',\n m: 'ஒர௠நிமிடமà¯',\n mm: '%d நிமிடஙà¯à®•à®³à¯',\n h: 'ஒர௠மணி நேரமà¯',\n hh: '%d மணி நேரமà¯',\n d: 'ஒர௠நாளà¯',\n dd: '%d நாடà¯à®•à®³à¯',\n M: 'ஒர௠மாதமà¯',\n MM: '%d மாதஙà¯à®•à®³à¯',\n y: 'ஒர௠வரà¯à®Ÿà®®à¯',\n yy: '%d ஆணà¯à®Ÿà¯à®•à®³à¯',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}வதà¯/,\n ordinal: function (number) {\n return number + 'வதà¯';\n },\n preparse: function (string) {\n return string.replace(/[௧௨௩௪௫௬à¯à¯®à¯¯à¯¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n // refer http://ta.wikipedia.org/s/1er1\n meridiemParse: /யாமமà¯|வைகறை|காலை|நணà¯à®ªà®•à®²à¯|எறà¯à®ªà®¾à®Ÿà¯|மாலை/,\n meridiem: function (hour, minute, isLower) {\n if (hour < 2) {\n return ' யாமமà¯';\n } else if (hour < 6) {\n return ' வைகறை'; // வைகறை\n } else if (hour < 10) {\n return ' காலை'; // காலை\n } else if (hour < 14) {\n return ' நணà¯à®ªà®•à®²à¯'; // நணà¯à®ªà®•à®²à¯\n } else if (hour < 18) {\n return ' எறà¯à®ªà®¾à®Ÿà¯'; // எறà¯à®ªà®¾à®Ÿà¯\n } else if (hour < 22) {\n return ' மாலை'; // மாலை\n } else {\n return ' யாமமà¯';\n }\n },\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'யாமமà¯') {\n return hour < 2 ? hour : hour + 12;\n } else if (meridiem === 'வைகறை' || meridiem === 'காலை') {\n return hour;\n } else if (meridiem === 'நணà¯à®ªà®•à®²à¯') {\n return hour >= 10 ? hour : hour + 12;\n } else {\n return hour + 12;\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return ta;\n\n})));\n","//! moment.js locale configuration\n//! locale : Kannada [kn]\n//! author : Rajeev Naik : https://github.com/rajeevnaikte\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '೧',\n 2: '೨',\n 3: '೩',\n 4: '೪',\n 5: '೫',\n 6: '೬',\n 7: 'à³',\n 8: 'à³®',\n 9: '೯',\n 0: '೦',\n },\n numberMap = {\n '೧': '1',\n '೨': '2',\n '೩': '3',\n '೪': '4',\n '೫': '5',\n '೬': '6',\n 'à³': '7',\n 'à³®': '8',\n '೯': '9',\n '೦': '0',\n };\n\n var kn = moment.defineLocale('kn', {\n months: 'ಜನವರಿ_ಫೆಬà³à²°à²µà²°à²¿_ಮಾರà³à²šà³_à²à²ªà³à²°à²¿à²²à³_ಮೇ_ಜೂನà³_ಜà³à²²à³†à³–_ಆಗಸà³à²Ÿà³_ಸೆಪà³à²Ÿà³†à²‚ಬರà³_ಅಕà³à²Ÿà³†à³‚ೕಬರà³_ನವೆಂಬರà³_ಡಿಸೆಂಬರà³'.split(\n '_'\n ),\n monthsShort:\n 'ಜನ_ಫೆಬà³à²°_ಮಾರà³à²šà³_à²à²ªà³à²°à²¿à²²à³_ಮೇ_ಜೂನà³_ಜà³à²²à³†à³–_ಆಗಸà³à²Ÿà³_ಸೆಪà³à²Ÿà³†à²‚_ಅಕà³à²Ÿà³†à³‚ೕ_ನವೆಂ_ಡಿಸೆಂ'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'à²à²¾à²¨à³à²µà²¾à²°_ಸೋಮವಾರ_ಮಂಗಳವಾರ_ಬà³à²§à²µà²¾à²°_ಗà³à²°à³à²µà²¾à²°_ಶà³à²•à³à²°à²µà²¾à²°_ಶನಿವಾರ'.split(\n '_'\n ),\n weekdaysShort: 'à²à²¾à²¨à³_ಸೋಮ_ಮಂಗಳ_ಬà³à²§_ಗà³à²°à³_ಶà³à²•à³à²°_ಶನಿ'.split('_'),\n weekdaysMin: 'à²à²¾_ಸೋ_ಮಂ_ಬà³_ಗà³_ಶà³_ಶ'.split('_'),\n longDateFormat: {\n LT: 'A h:mm',\n LTS: 'A h:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm',\n LLLL: 'dddd, D MMMM YYYY, A h:mm',\n },\n calendar: {\n sameDay: '[ಇಂದà³] LT',\n nextDay: '[ನಾಳೆ] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[ನಿನà³à²¨à³†] LT',\n lastWeek: '[ಕೊನೆಯ] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s ನಂತರ',\n past: '%s ಹಿಂದೆ',\n s: 'ಕೆಲವೠಕà³à²·à²£à²—ಳà³',\n ss: '%d ಸೆಕೆಂಡà³à²—ಳà³',\n m: 'ಒಂದೠನಿಮಿಷ',\n mm: '%d ನಿಮಿಷ',\n h: 'ಒಂದೠಗಂಟೆ',\n hh: '%d ಗಂಟೆ',\n d: 'ಒಂದೠದಿನ',\n dd: '%d ದಿನ',\n M: 'ಒಂದೠತಿಂಗಳà³',\n MM: '%d ತಿಂಗಳà³',\n y: 'ಒಂದೠವರà³à²·',\n yy: '%d ವರà³à²·',\n },\n preparse: function (string) {\n return string.replace(/[೧೨೩೪೫೬à³à³®à³¯à³¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n meridiemParse: /ರಾತà³à²°à²¿|ಬೆಳಿಗà³à²—ೆ|ಮಧà³à²¯à²¾à²¹à³à²¨|ಸಂಜೆ/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'ರಾತà³à²°à²¿') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'ಬೆಳಿಗà³à²—ೆ') {\n return hour;\n } else if (meridiem === 'ಮಧà³à²¯à²¾à²¹à³à²¨') {\n return hour >= 10 ? hour : hour + 12;\n } else if (meridiem === 'ಸಂಜೆ') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'ರಾತà³à²°à²¿';\n } else if (hour < 10) {\n return 'ಬೆಳಿಗà³à²—ೆ';\n } else if (hour < 17) {\n return 'ಮಧà³à²¯à²¾à²¹à³à²¨';\n } else if (hour < 20) {\n return 'ಸಂಜೆ';\n } else {\n return 'ರಾತà³à²°à²¿';\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(ನೇ)/,\n ordinal: function (number) {\n return number + 'ನೇ';\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return kn;\n\n})));\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('CRow',[_c('CCol',{attrs:{\"col\":\"\"}},[_c('div',{staticClass:\"col-lg-12 control-section\",staticStyle:{\"padding\":\"10px\",\"position\":\"relative\"}},[_c('div',{staticStyle:{\"width\":\"100%\"}},[_c('ejs-grid',{ref:\"grid\",attrs:{\"id\":\"statusAlertGridId\",\"dataSource\":_vm.data,\"allowFiltering\":true,\"commandClick\":_vm.commandClick,\"allowPaging\":true,\"allowTextWrap\":true,\"textWrapSettings\":_vm.wrapSettings,\"allowResizing\":true,\"query\":_vm.gridQuery,\"toolbarClick\":_vm.toolbarClick,\"allowExcelExport\":true,\"excelExportComplete\":_vm.excelExportComplete,\"allowReordering\":true,\"allowSorting\":true,\"editSettings\":_vm.editSettings,\"toolbar\":_vm.toolbar,\"pageSettings\":_vm.pageSettings,\"actionComplete\":_vm.actionComplete,\"actionBegin\":_vm.actionBegin,\"actionFailure\":_vm.actionFailure,\"filterSettings\":_vm.filterOptions,\"queryCellInfo\":_vm.customiseCell,\"width\":\"100%\",\"height\":\"100%\"}},[_c('e-columns',[_c('e-column',{attrs:{\"field\":\"triggerAlertId\",\"headerText\":\"Id\",\"width\":\"120\",\"isPrimaryKey\":true,\"visible\":false}}),_c('e-column',{attrs:{\"field\":\"triggerDate\",\"headerText\":\"Alert Date\",\"textAlign\":\"Right\",\"format\":_vm.dateFormatOptions,\"type\":\"date\",\"width\":\"150\"}}),_c('e-column',{attrs:{\"field\":\"alertType\",\"headerText\":\"Alert\",\"width\":\"120\"}}),_c('e-column',{attrs:{\"field\":\"clientName\",\"headerText\":\"Client\",\"allowEditing\":false,\"width\":\"210\"}}),_c('e-column',{attrs:{\"field\":\"stateName\",\"headerText\":\"Country\",\"allowEditing\":false,\"width\":\"150\"}}),_c('e-column',{attrs:{\"field\":\"companyName\",\"headerText\":\"Company\",\"allowEditing\":false,\"width\":\"210\"}}),_c('e-column',{attrs:{\"field\":\"contractName\",\"headerText\":\"Contract\",\"allowEditing\":false,\"width\":\"300\"}}),_c('e-column',{attrs:{\"field\":\"productName\",\"headerText\":\"Product\",\"allowEditing\":false,\"width\":\"150\"}}),_c('e-column',{attrs:{\"field\":\"pricingAreaName\",\"headerText\":\"Price Area\",\"textAlign\":\"Left\",\"width\":\"150\",\"type\":\"string\"}}),_c('e-column',{attrs:{\"field\":\"tradeablePeriodName\",\"headerText\":\"Period\",\"width\":\"120\"}}),_c('e-column',{attrs:{\"field\":\"triggerTypeName\",\"headerText\":\"Trigger Type\",\"visible\":true,\"width\":\"150\",\"textAlign\":\"Right\"}}),_c('e-column',{attrs:{\"field\":\"triggerPrice\",\"headerText\":\"Price\",\"textAlign\":\"Right\",\"validationRules\":_vm.percentageRules,\"type\":\"number\",\"format\":\"n3\",\"editType\":\"numericedit\",\"edit\":_vm.numericParams,\"width\":\"150\"}}),_c('e-column',{attrs:{\"headerText\":\"Watched Window\",\"columns\":_vm.dateColumns,\"textAlign\":\"Center\"}}),_c('e-column',{attrs:{\"field\":\"alertStatus\",\"headerText\":\"Status\",\"width\":\"120\"}}),_c('e-column',{attrs:{\"headerText\":\"Actions\",\"width\":\"230\",\"textAlign\":\"left\",\"commands\":_vm.commands}}),_c('e-column',{attrs:{\"field\":\"utilityTypeName\",\"headerText\":\"Commodity\",\"allowEditing\":false,\"visible\":false,\"width\":\"90\"}}),_c('e-column',{attrs:{\"field\":\"tradeablePeriodId\",\"headerText\":\"Watched Period\",\"textAlign\":\"Right\",\"visible\":false,\"validationRules\":_vm.requiredRules,\"editType\":\"dropdownedit\",\"edit\":_vm.tradebalePeriodParams,\"foreignKeyField\":\"id\",\"foreignKeyValue\":\"name\",\"dataSource\":_vm.tradebalePeriods,\"width\":\"50\"}}),_c('e-column',{attrs:{\"field\":\"unit\",\"headerText\":\"Unit\",\"visible\":false,\"width\":\"60\"}}),_c('e-column',{attrs:{\"field\":\"tolerance\",\"headerText\":\"Tolerance\",\"visible\":false,\"textAlign\":\"Right\",\"validationRules\":_vm.percentageRules,\"type\":\"number\",\"format\":\"n1\",\"editType\":\"numericedit\",\"edit\":_vm.percentageParams,\"width\":\"70\"}}),_c('e-column',{attrs:{\"field\":\"referenceTypeId\",\"headerText\":\"Reference Type\",\"textAlign\":\"Right\",\"visible\":false,\"validationRules\":_vm.requiredRules,\"editType\":\"dropdownedit\",\"edit\":_vm.referenceTypeParams,\"foreignKeyField\":\"id\",\"foreignKeyValue\":\"name\",\"dataSource\":_vm.referenceTypes,\"width\":\"110\"}}),_c('e-column',{attrs:{\"field\":\"referenceTypeName\",\"headerText\":\"Reference Type\",\"visible\":false,\"width\":\"120\"}}),_c('e-column',{attrs:{\"field\":\"applyUntilEnd\",\"headerText\":\"Apply until Default Deadline\",\"displayAsCheckBox\":\"true\",\"visible\":false,\"edit\":_vm.checkboxParams,\"editType\":\"booleanedit\",\"type\":\"boolean\",\"width\":\"120\"}}),_c('e-column',{attrs:{\"field\":\"notifyOnSystem\",\"headerText\":\"Notify On System\",\"defaultValue\":\"true\",\"displayAsCheckBox\":\"true\",\"visible\":false,\"allowEditing\":false,\"editType\":\"booleanedit\",\"type\":\"boolean\",\"width\":\"120\"}}),_c('e-column',{attrs:{\"field\":\"notifyEmailAddresses\",\"headerText\":\"Notify Email Addresses\",\"multiline\":\"true\",\"edit\":_vm.multilineParams,\"visible\":false,\"width\":\"120\"}})],1)],1)],1),_c('ejs-dialog',{ref:\"alertDialog\",attrs:{\"buttons\":_vm.alertDlgButtons,\"cssClass\":\"greyBackground\",\"id\":\"statusAlertDialog\",\"visible\":false,\"animationSettings\":_vm.animationSettings,\"showCloseIcon\":_vm.showCloseIcon,\"open\":_vm.dialogOpen,\"close\":_vm.dialogClose,\"width\":_vm.alertWidth,\"header\":_vm.header,\"allowDragging\":_vm.draggable,\"position\":_vm.position}},[_c('h5',{staticClass:\"ml-5\",attrs:{\"id\":\"graphHeader\"}},[_vm._v(\" \"+_vm._s(_vm.alertType)+\" Trigger\")]),_c('br'),_c('label',{staticClass:\"mr-5 float-right\"},[_vm._v(\"Alert issued on : \"+_vm._s(_vm.triggerDate))]),_c('br'),_c('br'),_c('label',{staticClass:\"ml-5\"},[_vm._v(_vm._s(_vm.alertText))]),_c('br'),_c('br'),_c('div',{staticClass:\"row\"},[_c('div',{staticClass:\"column ml-3\"},[_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Client\")]),_vm._v(\": \"+_vm._s(_vm.client))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Country\")]),_vm._v(\": \"+_vm._s(_vm.country))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Price Area\")]),_vm._v(\": \"+_vm._s(_vm.pricingAreaName))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Utility\")]),_vm._v(\": \"+_vm._s(_vm.utility))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Product\")]),_vm._v(\": \"+_vm._s(_vm.product))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Company\")]),_vm._v(\": \"+_vm._s(_vm.company))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Contract Name\")]),_vm._v(\": \"+_vm._s(_vm.contractName))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Contract ID\")]),_vm._v(\": \"+_vm._s(_vm.contractId))]),_c('br'),_c('br')]),_c('div',{staticClass:\"column ml-5\"},[_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Watch Period\")]),_vm._v(\": \"+_vm._s(_vm.watchPeriod))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Trigger Type\")]),_vm._v(\": \"+_vm._s(_vm.type))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Trigger Price\")]),_vm._v(\": \"+_vm._s(_vm.triggerPrice)+\" \"+_vm._s(_vm.contractUnits))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Market Price\")]),_vm._v(\": \"+_vm._s(_vm.marketPrice)+\" \"+_vm._s(_vm.contractUnits))]),_c('br'),_c('label',{staticClass:\"ml-5\"},[_c('b',[_vm._v(\"Delta to Trigger\")]),_vm._v(\": \"+_vm._s(_vm.delta)+\" \"+_vm._s(_vm.contractUnits))]),_c('br'),_c('br')])]),_c('ejs-chart',{attrs:{\"id\":\"alertChartContainer\",\"title\":_vm.title,\"zoomSettings\":_vm.zoom,\"primaryXAxis\":_vm.primaryXAxis,\"primaryYAxis\":_vm.primaryYAxis,\"tooltip\":_vm.tooltip,\"textRender\":_vm.textRender,\"titleStyle\":_vm.titleStyle,\"width\":\"700px\",\"height\":\"350px\"}},[_c('e-series-collection',[_c('e-series',{attrs:{\"xName\":\"x\",\"yName\":\"y\",\"name\":\"Market Price\",\"type\":\"MultiColoredLine\",\"pointColorMapping\":\"color\",\"marker\":_vm.marker}})],1)],1)],1)],1)])],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<template>\r\n <CRow>\r\n <CCol col>\r\n <div class=\"col-lg-12 control-section\" style=\"padding:10px;position:relative;\">\r\n <div style=\"width:100%;\">\r\n <ejs-grid ref='grid' id=\"statusAlertGridId\" :dataSource=\"data\" :allowFiltering='true' :commandClick='commandClick' :allowPaging=\"true\"\r\n :allowTextWrap='true' :textWrapSettings='wrapSettings' :allowResizing='true' :query='gridQuery'\r\n :toolbarClick='toolbarClick' :allowExcelExport='true' :excelExportComplete='excelExportComplete'\r\n :allowReordering='true' :allowSorting='true' :editSettings='editSettings' :toolbar='toolbar' \r\n :pageSettings='pageSettings' :actionComplete='actionComplete' :actionBegin=\"actionBegin\"\r\n :actionFailure=\"actionFailure\" :filterSettings='filterOptions' :queryCellInfo='customiseCell' width=\"100%\" height=\"100%\">\r\n <e-columns>\r\n <e-column field='triggerAlertId' headerText='Id' width=120 :isPrimaryKey='true' :visible='false'></e-column>\r\n <e-column field='triggerDate' headerText='Alert Date' textAlign='Right' :format='dateFormatOptions' type='date' width=150></e-column>\r\n <e-column field='alertType' headerText='Alert' width=120></e-column>\r\n <e-column field='clientName' headerText='Client' :allowEditing=\"false\" width=210></e-column>\r\n <e-column field='stateName' headerText='Country' :allowEditing=\"false\" width=150></e-column>\r\n <e-column field='companyName' headerText='Company' :allowEditing=\"false\" width=210></e-column>\r\n <e-column field='contractName' headerText='Contract' :allowEditing=\"false\" width=300></e-column>\r\n <e-column field='productName' headerText='Product' :allowEditing=\"false\" width=150></e-column>\r\n <e-column field='pricingAreaName' headerText='Price Area' textAlign='Left' width=150 type=\"string\"></e-column>\r\n <e-column field='tradeablePeriodName' headerText='Period' width=120></e-column>\r\n <!--<e-column field='triggerTypeId' headerText='Trigger Type' textAlign='Right' :validationRules=\"requiredRules\" editType='dropdownedit' :edit='triggerTypeParams' foreignKeyField=\"id\" foreignKeyValue='name' :dataSource='triggerTypes' width=150></e-column>-->\r\n <e-column field='triggerTypeName' headerText='Trigger Type' :visible='true' width=150 textAlign='Right'></e-column>\r\n <e-column field='triggerPrice' headerText='Price' textAlign='Right' :validationRules=\"percentageRules\" type=\"number\" format=\"n3\" editType='numericedit' :edit='numericParams' width=150></e-column>\r\n <e-column headerText='Watched Window' :columns='dateColumns' textAlign=\"Center\"></e-column>\r\n <e-column field='alertStatus' headerText='Status' width=120></e-column>\r\n <e-column headerText='Actions' width=230 textAlign='left' :commands='commands'></e-column>\r\n <e-column field='utilityTypeName' headerText='Commodity' :allowEditing=\"false\" :visible='false' width=90></e-column>\r\n <e-column field='tradeablePeriodId' headerText='Watched Period' textAlign='Right' :visible='false' :validationRules=\"requiredRules\" editType='dropdownedit' :edit='tradebalePeriodParams' foreignKeyField=\"id\" foreignKeyValue='name' :dataSource='tradebalePeriods' width=50></e-column>\r\n <e-column field='unit' headerText='Unit' :visible='false' width=60></e-column>\r\n <e-column field='tolerance' headerText='Tolerance' :visible='false' textAlign='Right' :validationRules=\"percentageRules\" type=\"number\" format=\"n1\" editType='numericedit' :edit='percentageParams' width=70></e-column>\r\n <e-column field='referenceTypeId' headerText='Reference Type' textAlign='Right' :visible='false' :validationRules=\"requiredRules\" editType='dropdownedit' :edit='referenceTypeParams' foreignKeyField=\"id\" foreignKeyValue='name' :dataSource='referenceTypes' width=110></e-column>\r\n <e-column field='referenceTypeName' headerText='Reference Type' :visible='false' width=120></e-column>\r\n <e-column field='applyUntilEnd' headerText='Apply until Default Deadline' displayAsCheckBox='true' :visible='false' :edit='checkboxParams' editType='booleanedit' type='boolean' width=120></e-column>\r\n <e-column field='notifyOnSystem' headerText='Notify On System' defaultValue='true' displayAsCheckBox='true' :visible='false' :allowEditing=\"false\" editType='booleanedit' type='boolean' width=120></e-column>\r\n <e-column field='notifyEmailAddresses' headerText='Notify Email Addresses' multiline=\"true\" :edit=\"multilineParams\" :visible='false' width=120></e-column>\r\n </e-columns>\r\n </ejs-grid>\r\n </div>\r\n <ejs-dialog :buttons='alertDlgButtons' cssClass=\"greyBackground\" ref=\"alertDialog\" id=\"statusAlertDialog\" v-bind:visible=\"false\" :animationSettings='animationSettings' :showCloseIcon='showCloseIcon' :open=\"dialogOpen\" :close=\"dialogClose\" :width='alertWidth' :header=\"header\" :allowDragging=\"draggable\" :position=\"position\">\r\n <h5 class=\"ml-5\" id=\"graphHeader\"> {{alertType}} Trigger</h5><br />\r\n <label class=\"mr-5 float-right\">Alert issued on : {{triggerDate}}</label><br />\r\n <br />\r\n <label class=\"ml-5\">{{alertText}}</label><br />\r\n <br />\r\n <div class=\"row\">\r\n <div class=\"column ml-3\">\r\n <label class=\"ml-5\"><b>Client</b>: {{client}}</label><br />\r\n <label class=\"ml-5\"><b>Country</b>: {{country}}</label><br />\r\n <label class=\"ml-5\"><b>Price Area</b>: {{pricingAreaName}}</label><br />\r\n <label class=\"ml-5\"><b>Utility</b>: {{utility}}</label><br />\r\n <label class=\"ml-5\"><b>Product</b>: {{product}}</label><br />\r\n <label class=\"ml-5\"><b>Company</b>: {{company}}</label><br />\r\n <label class=\"ml-5\"><b>Contract Name</b>: {{contractName}}</label><br />\r\n <label class=\"ml-5\"><b>Contract ID</b>: {{contractId}}</label><br />\r\n <br />\r\n\r\n </div>\r\n <div class=\"column ml-5\">\r\n <label class=\"ml-5\"><b>Watch Period</b>: {{watchPeriod}}</label><br />\r\n <label class=\"ml-5\"><b>Trigger Type</b>: {{type}}</label><br />\r\n <label class=\"ml-5\"><b>Trigger Price</b>: {{triggerPrice}} {{contractUnits}}</label><br />\r\n <label class=\"ml-5\"><b>Market Price</b>: {{marketPrice}} {{contractUnits}}</label><br />\r\n <label class=\"ml-5\"><b>Delta to Trigger</b>: {{delta}} {{contractUnits}}</label><br />\r\n <br />\r\n </div>\r\n </div>\r\n <!--<h1 class=\"expiredTriggerHeader\"> </h1>-->\r\n <ejs-chart id=\"alertChartContainer\" :title='title' :zoomSettings='zoom' :primaryXAxis='primaryXAxis' :primaryYAxis='primaryYAxis' :tooltip='tooltip' :textRender='textRender' :titleStyle=\"titleStyle\" width=\"700px\" height=\"350px\">\r\n <e-series-collection>\r\n <e-series xName='x' yName='y' name='Market Price' type='MultiColoredLine' pointColorMapping='color' :marker='marker'> </e-series>\r\n </e-series-collection>\r\n </ejs-chart>\r\n </ejs-dialog>\r\n </div>\r\n</CCol>\r\n </CRow>\r\n</template>\r\n\r\n<script>\r\n import Vue from \"vue\";\r\n import { GridPlugin, Edit, Page, Toolbar, Sort, Filter, Reorder, Resize, ExcelExport, ForeignKey, CommandColumn } from \"@syncfusion/ej2-vue-grids\";\r\n import { DropDownList } from \"@syncfusion/ej2-dropdowns\";\r\n import { UploaderPlugin } from '@syncfusion/ej2-vue-inputs';\r\n import { DialogUtility } from '@syncfusion/ej2-popups';\r\n import SyncHelper from '../../common/syncfusion';\r\n import { Query } from '@syncfusion/ej2-data';\r\n import gridOptions from '../../common/gridOptions'\r\n import dates from '../../common/dates'\r\n import urls from '../../common/urls';\r\n import apis from '../../common/network'\r\n import { DatePickerPlugin, DatePicker } from '@syncfusion/ej2-vue-calendars';\r\n import { CheckBoxPlugin, CheckBox } from \"@syncfusion/ej2-vue-buttons\";\r\n import { ChartPlugin, ColumnSeries, StripLine, LineSeries, DataLabel, Category, DateTime, Tooltip, ChartAnnotation, Zoom, MultiColoredLineSeries } from \"@syncfusion/ej2-vue-charts\";\r\n import { createSpinner, showSpinner, hideSpinner } from '@syncfusion/ej2-popups';\r\n import { DialogPlugin } from '@syncfusion/ej2-vue-popups';\r\n import { ButtonPlugin } from '@syncfusion/ej2-vue-buttons';\r\n import { enableRipple } from '@syncfusion/ej2-base';\r\n import { TextBox } from \"@syncfusion/ej2-inputs\";\r\n import store from '../../store';\r\n import moment from 'moment';\r\n\r\n Vue.use(ChartPlugin);\r\n Vue.use(UploaderPlugin);\r\n Vue.use(DialogUtility);\r\n Vue.use(GridPlugin);\r\n\r\n Vue.use(ButtonPlugin);\r\n Vue.use(DialogPlugin);\r\n enableRipple(true);\r\n\r\n \r\n let tradebalePeriodObj, tradebalePeriodElem, triggerTypeObj, triggerTypeElem, referenceTypeObj, referenceTypeElem, datePickerObj, elem, startDatePickerObj, startDateElem, checkboxElem, checkBoxObj;\r\n let multilineElem, multilineObj;\r\n export default {\r\n props: ['reportContractId', 'clientId', 'reportTradingGroupId'],\r\n mounted() {\r\n createSpinner({\r\n target: document.getElementById('mainSpinner'),\r\n width: '50',\r\n type: 'Material',\r\n label: 'Loading data...',\r\n cssClass: 'loading'\r\n });\r\n },\r\n data() {\r\n return {\r\n // needed because of form being loaded from tab,in such cases this isnt available and store is loaded from import\r\n store: store,\r\n // needed for vieweing dialog,initally not there then appears\r\n showCloseIcon: false,\r\n statusAlertcontractId: parseInt(this.reportContractId),// when form is loaded from contracts reporting ui, when not it will be undefined\r\n alertWidth: '750px',\r\n position: { X: 'center', Y: 'center' },\r\n animationSettings: { effect: 'Zoom' },\r\n alertDlgButtons: [{ click: this.alertDlgBtnClick, buttonModel: { content: 'Dismiss', isPrimary: true } }],\r\n ShowBtn: true,\r\n draggable: true,\r\n header: \" \",\r\n zoom:\r\n {\r\n enableMouseWheelZooming: false,\r\n enablePinchZooming: false,\r\n enableSelectionZooming: true\r\n },\r\n gridQuery: new Query().addParams(\"triggerAlert\", \"status\").addParams(\"contractId\", this.reportContractId).addParams(\"clientId\", this.clientId).addParams(\"tradingGroupId\", this.reportTradingGroupId),\r\n // this is done due to header column\r\n dateColumns: [\r\n {\r\n field: 'triggerStartDate',\r\n headerText: 'Start Date',\r\n width: 150,\r\n textAlign: 'Right',\r\n minWidth: 10,\r\n format: { type: 'date', format: 'dd/MM/yyyy' },\r\n type: 'date',\r\n validationRules: { required: true },\r\n edit: {\r\n create: function () {\r\n startDateElem = document.createElement('input');\r\n return startDateElem;\r\n },\r\n read: () => {\r\n return startDatePickerObj.value;\r\n },\r\n destroy: () => {\r\n startDatePickerObj.destroy();\r\n },\r\n // start date cant be before today,as trigger can start at least from today,cant set it up to start from yesterday as the job wont do data retroactivly\r\n // max will be later set in the code to the last day of the period prior to the one chosen,as trading can be done until a period starts,and having trigger when you cant trade doesnt make sense\r\n write: (args) => {\r\n startDatePickerObj = new DatePicker({\r\n value: new Date(args.rowData[args.column.field]),\r\n floatLabelType: 'Always',\r\n format: 'dd/MM/yyyy',\r\n //sets the min.\r\n min: dates.addDays(new Date(), 1),\r\n placeholder: 'Start Date',\r\n firstDayOfWeek: 1,\r\n });\r\n startDatePickerObj.appendTo(startDateElem);\r\n }\r\n }\r\n },\r\n {\r\n field: 'triggerEndDate',\r\n headerText: 'End Date',\r\n width: 150,\r\n textAlign: 'Right',\r\n minWidth: 10,\r\n format: { type: 'date', format: 'dd/MM/yyyy' },\r\n type: 'date',\r\n validationRules: { required: true, minlength: [(args) => { return this.dateValidation(args) }, 'End Date must be greater than Start Date.'] },\r\n edit: {\r\n create: function () {\r\n elem = document.createElement('input');\r\n return elem;\r\n },\r\n read: () => {\r\n return datePickerObj.value;\r\n },\r\n destroy: () => {\r\n datePickerObj.destroy();\r\n },\r\n // end date cant be before tomorow,as trigger can start at least from today,cant set it up to start from yesterday as the job wont do data retroactivly,and it must last for at least a day\r\n // max will be later set in the code to the last day of the period prior to the one chosen,as trading can be done until a period starts,and having trigger when you cant trade doesnt make sense\r\n write: (args) => {\r\n datePickerObj = new DatePicker({\r\n value: new Date(args.rowData[args.column.field]),\r\n floatLabelType: 'Always',\r\n format: 'dd/MM/yyyy',\r\n //sets the min after the startdate.\r\n min: dates.addDays(new Date(), 1),\r\n placeholder: 'End Date',\r\n firstDayOfWeek: 1,\r\n });\r\n datePickerObj.appendTo(elem);\r\n }\r\n }\r\n }\r\n ],\r\n referenceTypes: SyncHelper.getDataManager('Utils/referenceTypes'),\r\n triggerTypes: SyncHelper.getDataManager('Utils/triggerTypes'),\r\n contractUnits: \"\",\r\n units: \"\",\r\n alertType: \"\",\r\n triggerDate: \"\",\r\n client: \"\",\r\n country: \"\",\r\n utility: \"\",\r\n company: \"\",\r\n contractName: \"\",\r\n contractId: \"\",\r\n watchPeriod: \"\",\r\n triggerPrice: \"\",\r\n marketPrice: \"\",\r\n delta: \"\",\r\n alertText: \"\",\r\n type: \"\",\r\n product: \"\",\r\n pricingAreaName: \"\",\r\n wrapSettings: { wrapMode: 'Header' },\r\n commands: [{ buttonOption: { cssClass: 'e-primary view', content: 'View' } },\r\n { buttonOption: { cssClass: 'secondary mark', content: 'Mark as Seen' } }],\r\n tradebalePeriods: SyncHelper.getDataManager('Utils/contractTradeablePeriods'),\r\n dateFormatOptions: { type: 'date', format: 'dd/MM/yyyy' },\r\n data: SyncHelper.getDataManager(\"TriggerAlert\"),\r\n tradebalePeriodParams: {\r\n create: () => {\r\n tradebalePeriodElem = document.createElement('input');\r\n return tradebalePeriodElem;\r\n },\r\n read: () => {\r\n return tradebalePeriodObj.value;\r\n },\r\n destroy: () => {\r\n tradebalePeriodObj.destroy();\r\n },\r\n write: (args) => {\r\n tradebalePeriodObj = new DropDownList({\r\n query: new Query().addParams(\"contractId\", args.rowData.contractId),\r\n dataSource: this.tradebalePeriods,\r\n fields: { text: args.column.foreignKeyValue, value: args.column.foreignKeyField },\r\n value: ((args.foreignKeyData && args.foreignKeyData[0]) ? args.foreignKeyData[0][args.column.foreignKeyField] : null),\r\n placeholder: 'Tradeable Period',\r\n floatLabelType: 'Always',\r\n allowFiltering: true,\r\n showClearButton: true,\r\n change: (args) => {\r\n if (args.value != null) {\r\n apis.protectedApi(`${urls.apiBaseUrl}ContractTrigger/PeriodDeadline/${args.value}`).then(it => {\r\n\r\n if (checkBoxObj.checked) {\r\n\r\n datePickerObj.value = it.data.lastDay;\r\n }\r\n startDatePickerObj.max = it.data.lastDay;\r\n datePickerObj.max = it.data.lastDay;\r\n }).catch(\r\n response => {\r\n var message = response.response.data.message != undefined ? response.response.data.message : \"Error invoking service,please contact support\";\r\n gridOptions.errorAlert(\"Error: \" + message);\r\n }\r\n );\r\n }\r\n }\r\n });\r\n tradebalePeriodObj.appendTo(tradebalePeriodElem);\r\n }\r\n },\r\n referenceTypeParams: {\r\n create: () => {\r\n referenceTypeElem = document.createElement('input');\r\n return referenceTypeElem;\r\n },\r\n read: () => {\r\n return referenceTypeObj.value;\r\n },\r\n destroy: () => {\r\n referenceTypeObj.destroy();\r\n },\r\n write: (args) => {\r\n referenceTypeObj = new DropDownList({\r\n dataSource: this.referenceTypes,\r\n fields: { text: args.column.foreignKeyValue, value: args.column.foreignKeyField },\r\n value: ((args.foreignKeyData && args.foreignKeyData[0]) ? args.foreignKeyData[0][args.column.foreignKeyField] : null),\r\n placeholder: 'Reference Type',\r\n floatLabelType: 'Always',\r\n allowFiltering: true,\r\n showClearButton: true,\r\n });\r\n referenceTypeObj.appendTo(referenceTypeElem);\r\n }\r\n },\r\n triggerTypeParams: {\r\n create: () => {\r\n triggerTypeElem = document.createElement('input');\r\n return triggerTypeElem;\r\n },\r\n read: () => {\r\n return triggerTypeObj.value;\r\n },\r\n destroy: () => {\r\n triggerTypeObj.destroy();\r\n },\r\n write: (args) => {\r\n triggerTypeObj = new DropDownList({\r\n cssClass: ((args.foreignKeyData && args.foreignKeyData[0]) ? args.foreignKeyData[0][args.column.foreignKeyValue] == 'Lower' ? 'greenBox' : 'redBox' : null),\r\n dataSource: this.triggerTypes,\r\n fields: { text: args.column.foreignKeyValue, value: args.column.foreignKeyField },\r\n value: ((args.foreignKeyData && args.foreignKeyData[0]) ? args.foreignKeyData[0][args.column.foreignKeyField] : null),\r\n placeholder: 'Trigger Type',\r\n floatLabelType: 'Always',\r\n allowFiltering: true,\r\n showClearButton: true,\r\n change: (args) => {\r\n if (args.itemData.name == 'Lower') {\r\n args.element.parentElement.classList.remove('redBox');\r\n args.element.parentElement.classList.add('greenBox');\r\n } else {\r\n args.element.parentElement.classList.remove('greenBox');\r\n args.element.parentElement.classList.add('redBox');\r\n }\r\n }\r\n });\r\n triggerTypeObj.appendTo(triggerTypeElem);\r\n\r\n }\r\n },\r\n checkboxParams: {\r\n create: function () {\r\n checkboxElem = document.createElement('input');\r\n return checkboxElem;\r\n },\r\n read: () => {\r\n return checkBoxObj.checked;\r\n },\r\n destroy: () => {\r\n checkBoxObj.destroy();\r\n },\r\n write: (args) => {\r\n checkBoxObj = new CheckBox({\r\n cssClass: 'e-primary',\r\n checked: args.rowData[args.column.field],\r\n disabled: false,\r\n //value: args.rowData[args.column.field],\r\n label: \"Apply until End Date\",\r\n change: (args) => {\r\n if (args.checked && tradebalePeriodObj.value != undefined) {\r\n apis.protectedApi(`${urls.apiBaseUrl}ContractTrigger/PeriodDeadline/${tradebalePeriodObj.value}`).then(it => {\r\n datePickerObj.value = it.data.lastDay;\r\n }\r\n ).catch(\r\n response => {\r\n var message = response.response.data.message != undefined ? response.response.data.message : \"Error invoking service,please contact support\";\r\n gridOptions.errorAlert(\"Error: \" + message);\r\n }\r\n );\r\n }\r\n if (args.checked == true) {\r\n datePickerObj.enabled = false;\r\n } else {\r\n datePickerObj.enabled = true;\r\n }\r\n }\r\n });\r\n checkBoxObj.appendTo(checkboxElem);\r\n }\r\n },\r\n multilineParams: {\r\n create: function () {\r\n multilineElem = document.createElement(\"textarea\");\r\n return multilineElem;\r\n },\r\n read: () => {\r\n return multilineObj.value;\r\n },\r\n destroy: () => {\r\n multilineObj.destroy();\r\n },\r\n write: args => {\r\n multilineObj = new TextBox({\r\n value: args.rowData[\"notifyEmailAddresses\"],\r\n floatLabelType: \"Always\",\r\n placeholder: 'Notify Email Addresses',\r\n multiline: true,\r\n\r\n });\r\n multilineObj.appendTo(multilineElem);\r\n }\r\n },\r\n //pageSettings: gridOptions.pageSettings,\r\n pageSettings: { pageSizes: [10, 20, 50, 100], pageSize: 10, pageCount: 4 },\r\n editSettings: {\r\n showConfirmDialog: true,\r\n showDeleteConfirmDialog: true,\r\n allowEditing: false,\r\n allowAdding: false,\r\n allowDeleting: store.state.permissions[\"Permissions.Triggers.Delete\"],\r\n mode: 'Dialog'\r\n },\r\n numericParams: {\r\n params: {\r\n validateDecimalOnType: true,\r\n decimals: 4,\r\n format: \"n4\"\r\n }\r\n },\r\n percentageParams: {\r\n params: {\r\n validateDecimalOnType: true,\r\n decimals: 1,\r\n format: \"n1\"\r\n }\r\n },\r\n toolbar: ['Delete', 'ExcelExport'],\r\n requiredRules: { required: true },\r\n percentageRules: { required: true, number: true },\r\n nameRules: { required: true, maxLength: 50 },\r\n editparams: { params: { popupHeight: '300px' } },\r\n filterOptions: gridOptions.filterSettings,\r\n\r\n seriesData: this.marketPricesPerDay,\r\n primaryXAxis: {\r\n valueType: 'DateTime', intervalType: 'Days',\r\n title: 'Date',\r\n titleStyle: {\r\n size: '16px', color: '#4d4d4d',\r\n fontFamily: 'Arial Narrow', fontWeight: 'bold'\r\n }\r\n },\r\n primaryYAxis:\r\n {\r\n title: 'Price',\r\n titleStyle: {\r\n size: '16px', color: '#4d4d4d',\r\n fontFamily: 'Arial Narrow', fontWeight: 'bold'\r\n },\r\n labelFormat: 'n3'\r\n },\r\n tooltip: { enable: true },\r\n titleStyle: {\r\n //fontFamily: \"Arial\",\r\n //fontStyle: 'italic',\r\n //fontWeight: 'regular',\r\n //color: \"#E27F2D\",\r\n //size: '23px'\r\n },\r\n title: this.title,\r\n marker: { dataLabel: { visible: true } },\r\n\r\n };\r\n },\r\n methods: {\r\n alertDlgBtnClick: function () {\r\n this.$refs.alertDialog.hide();\r\n },\r\n dialogClose: function () {\r\n this.ShowBtn = true;\r\n },\r\n dialogOpen: function () {\r\n this.ShowBtn = false;\r\n },\r\n dateValidation: function (args) {\r\n return startDatePickerObj.value <= datePickerObj.value;\r\n },\r\n textRender: function (args) {\r\n //if (this.type != \"Lower\" && args.point.y >= this.lowerPrice) {\r\n // args.text = args.text + ' Trigger Hit';\r\n // args.color = 'yellow';\r\n //}\r\n //else if (this.type == \"Lower\" && args.point.y <= this.higherPrice) {\r\n // args.text = args.text + ' Trigger Hit';\r\n // args.color = 'yellow';\r\n //}\r\n //else { args.text = \"\"; }\r\n args.text = \"\";\r\n },\r\n commandClick: function (args) {\r\n var triggerAlertId = args.rowData.triggerAlertId;\r\n if (args.target.classList.contains(\"view\")) {\r\n this.loadGraph(args.rowData);\r\n }\r\n else if (args.target.classList.contains(\"mark\")) {\r\n this.changeAlertStatus(triggerAlertId, this.$refs.grid);\r\n }\r\n },\r\n changeAlertStatus: function (args, grid) {\r\n apis.protectedApi.put(`${urls.apiBaseUrl}TriggerAlert/UpdateStatus/`, { triggerAlertId: args }).then(it => {\r\n grid.refresh();\r\n }).catch(\r\n response => {\r\n var message = response.response.data.message != undefined ? response.response.data.message : \"Error invoking service,please contact support\";\r\n gridOptions.errorAlert(\"Error: \" + message);\r\n }\r\n );\r\n },\r\n loadGraph: function (args) {\r\n apis.protectedApi(`${urls.apiBaseUrl}ContractTrigger/TriggerGraphData/${args.triggerId}`).then(it => {\r\n this.higherPrice = it.data.higherPrice;\r\n this.lowerPrice = it.data.lowerPrice;\r\n this.marketPricesPerDay = it.data.marketPricesPerDay;\r\n this.title = it.data.title;\r\n this.type = it.data.type;\r\n args.triggerEndDate.setDate(args.triggerEndDate.getDate() + 1);\r\n this.alertText = args.alertType == \"Expired\" ? \"Your Trigger has expired on the \" + moment(String(args.triggerEndDate)).format('DD/MM/YYYY') +\". Reset your Watched Window End Date.\":\r\n \"Your Trigger has gone live on the \" + moment(String(args.triggerStartDate)).format('DD/MM/YYYY'); \r\n\r\n var chart = document.getElementById('alertChartContainer').ej2_instances[0];\r\n chart.primaryYAxis =\r\n {\r\n title: 'Price' + ' ' + it.data.unit\r\n };\r\n chart.primaryYAxis.stripLines =\r\n [//striplines are for the green/red part lines on the grid, we have one that is the span,and the upper and lower one that deffer depending on type\r\n {\r\n start: this.lowerPrice, end: this.higherPrice, text: this.type, color: this.type == \"Lower\" ? \"#1a9470\" : '#f25c54', visible: true, zIndex: 'Behind', opacity: 0.5 },\r\n\r\n { start: this.type == \"Lower\" ? this.higherPrice : this.lowerPrice, size: 1, text: this.type == \"Lower\" ? \"\" + this.higherPrice : \"\" + this.lowerPrice, textStyle: { size: 15, color: this.type == \"Lower\" ? '#1a9470' : '#f25c54' }, verticalAlignment: this.type == \"Lower\" ? \"End\" : \"Start\", horizontalAlignment: \"Start\", sizeType: 'Pixel', dashArray: \"10,5\", color: this.type == \"Lower\" ? \"#1a9470\" : '#f25c54' },\r\n { start: this.type == \"Lower\" ? this.lowerPrice : this.higherPrice, size: 1, text: this.type == \"Lower\" ? \"\" + this.lowerPrice : \"\" + this.higherPrice, textStyle: { size: 15, color: this.type == \"Lower\" ? \"#1a9470\" : '#f25c54' }, verticalAlignment: this.type == \"Lower\" ? \"Start\" : \"End\", horizontalAlignment: \"Start\", sizeType: 'Pixel', color: this.type == \"Lower\" ? \"#1a9470\" : '#f25c54' },\r\n\r\n ];\r\n chart.series[0].dataSource = this.marketPricesPerDay;\r\n chart.refresh();\r\n if (args.alertType == \"Expired\") {\r\n document.getElementById('graphHeader').classList.add('alertExpiredTriggerHeader');\r\n document.getElementById('graphHeader').classList.remove('alertLiveTriggerHeader');\r\n }\r\n else {\r\n document.getElementById('graphHeader').classList.add('alertLiveTriggerHeader');\r\n document.getElementById('graphHeader').classList.remove('alertExpiredTriggerHeader');\r\n }\r\n //aditional data on dialog above graph\r\n if (args.alertType == \"Watch Zone\") {\r\n this.alertType = args.alertType + \" \" + \"Entered\";\r\n } else {\r\n this.alertType = args.alertType;\r\n }\r\n this.contractUnits = args.unit;\r\n this.triggerDate = moment(String(args.triggerDate)).format('DD/MM/YYYY');\r\n this.client = args.clientName;\r\n this.country = args.stateName;\r\n this.utility = args.utilityTypeName;\r\n this.company = args.companyName;\r\n this.contractName = args.contractName;\r\n this.pricingAreaName = args.pricingAreaName;\r\n this.contractId = args.contractId;\r\n this.watchPeriod = args.tradeablePeriodName;\r\n this.triggerPrice = args.triggerPrice.toFixed(3);\r\n this.marketPrice = args.marketPrice.toFixed(3);\r\n this.delta = args.delta.toFixed(3);\r\n this.product = args.productName;\r\n this.$refs.alertDialog.show();\r\n }\r\n ).catch(\r\n response => {\r\n var message = response.response.data.message != undefined ? response.response.data.message : \"Error invoking service,please contact support\";\r\n gridOptions.errorAlert(\"Error: \" + message);\r\n }\r\n );\r\n },\r\n toolbarClick(args) {\r\n if (args.item.id.includes('excelexport')) {\r\n // hide and show dropdown columns and show text columns as they always have value but dropdowns if not on the page will not have values\r\n this.$refs.grid.getColumns()[11].visible = false;\r\n\r\n this.$refs.grid.getColumns()[12].visible = true;\r\n }\r\n gridOptions.excelExport(args, \"Contract Triggers.xlsx\", this.$refs);\r\n },\r\n excelExportComplete(args) {\r\n this.$refs.grid.hideSpinner();\r\n // hide and show dropdown columns and show text columns as they always have value but dropdowns if not on the page will not have values,and return to the state before export\r\n this.$refs.grid.getColumns()[11].visible = true;\r\n\r\n this.$refs.grid.getColumns()[12].visible = false;\r\n },\r\n\r\n actionBegin(args) {\r\n gridOptions.actionBegin(args);\r\n if (args.requestType == 'beginEdit') {\r\n\r\n if (args.rowData.alertType == 'Expired') {\r\n for (var i = 0; i < this.$refs.grid.getColumns().length; i++) {\r\n this.$refs.grid.getColumns()[i].isPrimaryKey = true;\r\n\r\n }\r\n } else {\r\n for (var i = 0; i < this.$refs.grid.getColumns().length; i++) {\r\n this.$refs.grid.getColumns()[i].isPrimaryKey = false;\r\n\r\n }\r\n }\r\n }\r\n if (args.requestType == 'save') {\r\n //args.dialog.dialogOpen = false;\r\n showSpinner(document.getElementById('mainSpinner'));\r\n }\r\n if (args.requestType == 'refresh') {\r\n\r\n hideSpinner(document.getElementById('mainSpinner'));\r\n }\r\n if ((args.requestType === 'beginEdit' || args.requestType === 'add')) {\r\n for (var i = 0; i < this.$refs.grid.getColumns().length; i++) {\r\n if (this.$refs.grid.getColumns()[i].headerText == \"Apply until Default Deadline\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerActions\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerStatus\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"applyUntilEnd\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"notifyOnSystem\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"notifyEmailAddresses\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"statusDate\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"tradeablePeriodName\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"tradeablePeriodId\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"referenceTypeId\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerStartDate\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerEndDate\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"tolerance\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerDate\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"alertType\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"alertStatus\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"utilityTypeName\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } \r\n }\r\n }\r\n },\r\n actionComplete(args) {\r\n gridOptions.actionComplete(args, this.$refs);\r\n if (args.requestType == 'beginEdit') {\r\n\r\n if (args.rowData.alertType == 'Expired') {\r\n\r\n for (var i = 0; i < this.$refs.grid.getColumns().length; i++) {\r\n this.$refs.grid.getColumns()[i].isPrimaryKey = true;\r\n\r\n }\r\n referenceTypeObj.enabled = false;\r\n tradebalePeriodObj.enabled = false;\r\n startDatePickerObj.enabled = false;\r\n triggerTypeObj.enabled = false;\r\n referenceTypeObj.enabled = false;\r\n multilineObj.enabled = false;\r\n checkBoxObj.disabled = true;\r\n \r\n } else {\r\n for (var i = 0; i < this.$refs.grid.getColumns().length; i++) {\r\n this.$refs.grid.getColumns()[i].isPrimaryKey = false;\r\n\r\n }\r\n\r\n referenceTypeObj.enabled = true;\r\n tradebalePeriodObj.enabled = true;\r\n startDatePickerObj.enabled = true;\r\n triggerTypeObj.enabled = true;\r\n referenceTypeObj.enabled = true;\r\n multilineObj.enabled = true;\r\n checkBoxObj.disabled = false;\r\n \r\n }\r\n }\r\n\r\n\r\n\r\n if (args.requestType == \"refresh\") {\r\n \r\n if (this.reportContractId != undefined) {\r\n apis.protectedApi(`${urls.apiBaseUrl}TriggerAlert/GroupCounts?contractId=${this.reportContractId}`).then(it => {\r\n this.deadline = it.data.deadline;\r\n this.status = it.data.status;\r\n this.hit = it.data.hit;\r\n this.AlertsCount = this.hit + this.deadline + this.status;\r\n //this is for counter in header, count unseen alerts\r\n if (document.getElementsByClassName('dueLiveTriggerHeader').length > 0) {\r\n document.getElementsByClassName('dueLiveTriggerHeader')[0].innerHTML = \"<u>TRIGGERS STATUS\" + \" \" + this.status + \"</u>\";\r\n document.querySelectorAll('[role=\"presentation\"]')[6].innerHTML = \"Alerts\" + \"(\" + this.AlertsCount + \")\";\r\n }\r\n });\r\n\r\n }\r\n if (this.clientId != undefined) {\r\n apis.protectedApi(`${urls.apiBaseUrl}TriggerAlert/GroupCounts?clientId=${this.clientId}`).then(it => {\r\n this.deadline = it.data.deadline;\r\n this.status = it.data.status;\r\n this.hit = it.data.hit;\r\n this.AlertsCount = this.hit + this.deadline + this.status;\r\n //this is for counter in header, count unseen alerts\r\n if (document.getElementsByClassName('dueLiveTriggerHeader').length > 0) {\r\n document.getElementsByClassName('dueLiveTriggerHeader')[0].innerHTML = \"<u>TRIGGERS STATUS\" + \" \" + this.status + \"</u>\";\r\n document.querySelectorAll('[role=\"presentation\"]')[5].innerHTML = \"Alerts\" + \"(\" + this.AlertsCount + \")\";\r\n }\r\n });\r\n\r\n }\r\n if (this.reportTradingGroupId != undefined) {\r\n apis.protectedApi(`${urls.apiBaseUrl}TriggerAlert/GroupCountsATG?tradingGroupId=${this.reportTradingGroupId}`).then(it => {\r\n this.deadline = it.data.deadline;\r\n this.status = it.data.status;\r\n this.hit = it.data.hit;\r\n this.AlertsCount = this.hit + this.deadline + this.status;\r\n //this is for counter in header, count unseen alerts\r\n if (document.getElementsByClassName('dueLiveTriggerHeader').length > 0) {\r\n document.getElementsByClassName('dueLiveTriggerHeader')[0].innerHTML = \"<u>TRIGGERS STATUS\" + \" \" + this.status + \"</u>\";\r\n document.querySelectorAll('[role=\"presentation\"]')[6].innerHTML = \"Alerts\" + \"(\" + this.AlertsCount + \")\";\r\n }\r\n });\r\n }\r\n\r\n }\r\n\r\n if ((args.requestType === 'beginEdit' || args.requestType === 'add')) {\r\n\r\n var applyEnd = args.rowData.applyUntilEnd;\r\n if (applyEnd == true) {\r\n\r\n datePickerObj.enabled = false;\r\n }\r\n\r\n args.dialog.height = \"80%\";\r\n args.dialog.width = \"50%\";\r\n let rows = args.form.querySelectorAll(\"tr\");\r\n for (var i = 0; i < rows.length; i = i + 2) {\r\n if (rows.length > i + 1) {\r\n rows[i].appendChild(\r\n args.form.querySelectorAll(\"tr\")[i + 1].cells[0]\r\n );\r\n }\r\n }\r\n \r\n for (var i = 0; i < this.$refs.grid.getColumns().length; i++) {\r\n if (this.$refs.grid.getColumns()[i].headerText == \"Apply until Default Deadline\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerActions\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerStatus\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"applyUntilEnd\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"notifyOnSystem\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"notifyEmailAddresses\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"statusDate\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"tradeablePeriodName\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"tradeablePeriodId\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n tradebalePeriodObj.value = args.rowData.tradeablePeriodId;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"utilityTypeName\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } \r\n else if (this.$refs.grid.getColumns()[i].field == \"referenceTypeId\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerStartDate\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerEndDate\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"tolerance\") {\r\n this.$refs.grid.getColumns()[i].visible = false;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"triggerDate\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"alertType\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } else if (this.$refs.grid.getColumns()[i].field == \"alertStatus\") {\r\n this.$refs.grid.getColumns()[i].visible = true;\r\n } \r\n }\r\n if (args.requestType != 'add') {\r\n // this.contractUnits = args.rowData.unit;\r\n this.units = args.rowData.unit;\r\n args.form[12].value = args.form[12].value + \"%\";\r\n args.form[10].value = args.form[10].value + \" [\" + this.units + \"]\";\r\n }\r\n \r\n args.form[12].addEventListener(\"focusout\", e => {\r\n if (e.target.classList.contains(\"e-numerictextbox\")) {\r\n e.target.value = e.target.value + \"%\";\r\n }\r\n });\r\n\r\n \r\n args.form[10].addEventListener(\"focusout\", e => {\r\n if (e.target.classList.contains(\"e-numerictextbox\")) {\r\n e.target.value = e.target.value + \" [\" + this.units + \"]\";\r\n }\r\n });\r\n }\r\n },\r\n actionFailure(args) {\r\n gridOptions.actionFailure(args);\r\n hideSpinner(document.getElementById('mainSpinner'));\r\n },\r\n customiseCell: function (args) { // when setting up the grid this is rendering each column on its own\r\n if (args.column.field === 'triggerTypeName') {\r\n if (args.data['triggerTypeName'] == 'Lower') {\r\n args.cell.classList.add('greenBox');\r\n } else {\r\n args.cell.classList.add('redBox');\r\n }\r\n } else if (args.column.field === 'triggerPrice') {\r\n args.cell.textContent = args.cell.textContent + \" [\" + args.data['unit'] + \"]\";\r\n } else if (args.column.field === 'tolerance') {\r\n args.cell.textContent = args.cell.textContent + \"%\";\r\n } else if (args.column.headerText === \"Actions\") {\r\n if (args.data['alertStatus'] == 'Seen') {\r\n args.cell.querySelector(\"button[title='Mark as Seen']\").textContent = 'Mark as Unseen';\r\n args.cell.querySelector(\"button[title='Mark as Seen']\").title = 'Mark as Unseen';\r\n }\r\n }\r\n },\r\n fetchUnit(id) {\r\n apis.protectedApi(`${urls.apiBaseUrl}Contract/AditionalTriggerData/${id}`).then(it => {\r\n this.units = it.data.units;\r\n this.riskManager = it.data.riskManager;\r\n }).catch(\r\n response => {\r\n var message = response.response.data.message != undefined ? response.response.data.message : \"Error invoking service,please contact support\";\r\n gridOptions.errorAlert(\"Error: \" + message);\r\n }\r\n );\r\n\r\n }\r\n\r\n },\r\n provide: {\r\n grid: [Page, Edit, Toolbar, Sort, Filter, Reorder, Resize, ExcelExport, ForeignKey, CommandColumn],\r\n chart: [ColumnSeries, StripLine, LineSeries, Category, DataLabel, DateTime, Tooltip, ChartAnnotation, Zoom, MultiColoredLineSeries]\r\n }\r\n };\r\n\r\n</script>\r\n<style>\r\n/* .e-dialog {\r\n max-height: 900px !important;\r\n top: 0px !important;\r\n }*/\r\n /*@import \"../node_modules/@syncfusion/ej2-vue-grids/styles/material.css\";*/\r\n .greenBox {\r\n background-color: #7FB7BE !important;\r\n }\r\n\r\n .redBox {\r\n background-color: #f78764 !important;\r\n }\r\n\r\n e-notFunctional {\r\n background-color: grey;\r\n }\r\n\r\n .alertExpiredTriggerHeader {\r\n text-transform: uppercase;\r\n color: #f25c54;\r\n }\r\n .greyBackground{\r\n background-color: lightgrey;\r\n }\r\n .alertLiveTriggerHeader {\r\n text-transform: uppercase;\r\n color: #001c55;\r\n }\r\n #alertChartContainer {\r\n height: 350px;\r\n }\r\n #statusAlertDialog .e-dlg-content {\r\n color: #4d4d4d !important;\r\n font-family: 'Arial', Arial, sans-serif !important;\r\n font-size: 14px;\r\n }\r\n\r\n #alertChartContainer_Series_0 {\r\n stroke: #001c55 !important;\r\n }\r\n\r\n text[id=\"alertChartContainer_ChartTitle\"] {\r\n fill: #4d4d4d !important;\r\n font-family: 'Arial', Arial, sans-serif !important;\r\n font-size: 16px;\r\n }\r\n [id^=\"alertChartContainer_EJ-Trackball_Series_0\"] {\r\n color: #001c55 !important;\r\n }\r\n\r\n #alertChartContainer_tooltip_Trackball_0 {\r\n fill: #001C55 !important;\r\n }\r\n #statusAlertGridId .e-content {\r\n min-height: 0px !important;\r\n }\r\n #statusAlertDialog {\r\n max-height: 100% !important;\r\n z-index: 10000 !important;\r\n height: 100vh !important;\r\n position: fixed!important;\r\n top: 0%!important;\r\n }\r\n\r\n</style>\r\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./StatusAlert.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./StatusAlert.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./StatusAlert.vue?vue&type=template&id=8cc5df1a\"\nimport script from \"./StatusAlert.vue?vue&type=script&lang=js\"\nexport * from \"./StatusAlert.vue?vue&type=script&lang=js\"\nimport style0 from \"./StatusAlert.vue?vue&type=style&index=0&id=8cc5df1a&prod&lang=css\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { EventHandler } from '@syncfusion/ej2-base';\nimport { remove } from '@syncfusion/ej2-base';\nimport { removeElement, RectOption, PolygonOption, createTooltip, minMax, getElement } from '../../common/utils/helper';\nimport { textElement } from '../../common/utils/helper';\nimport { PathOption, Rect, measureText, TextOption, SvgRenderer } from '@syncfusion/ej2-svg-base';\nimport { Zoom } from './zooming';\nimport { zoomComplete, onZooming } from '../../common/model/constants';\n/**\n * Zooming Toolkit created here\n *\n * @private\n */\nvar Toolkit = /** @class */ (function () {\n /** @private */\n function Toolkit(chart) {\n this.iconRectOverFill = 'transparent';\n this.iconRectSelectionFill = 'transparent';\n /** @private */\n this.zoomCompleteEvtCollection = [];\n this.chart = chart;\n this.elementId = chart.element.id;\n this.chart.svgRenderer = new SvgRenderer(this.elementId);\n }\n /**\n * To create the pan button.\n *\n * @returns {void}\n * @private\n */\n Toolkit.prototype.createPanButton = function (childElement, parentElement) {\n var render = this.chart.svgRenderer;\n var fillColor = this.chart.zoomModule.isPanning ? this.chart.themeStyle.toolkitSelectionColor : this.chart.themeStyle.toolkitFill;\n var direction = 'M5,3h2.3L7.275,5.875h1.4L8.65,3H11L8,0L5,3z M3,11V8.7l2.875,0.025v-1.4L3,7.35V5L0,8L3,';\n direction += '11z M11,13H8.7l0.025-2.875h-1.4L7.35,13H5l3,3L11,13z M13,5v2.3l-2.875-0.025v1.4L13,8.65V11l3-3L13,5z';\n //This is for setting low opacity to PAN Button\n this.elementOpacity = !this.chart.zoomModule.isZoomed && this.chart.zoomSettings.showToolbar ? '0.2' : '1';\n childElement.setAttribute('opacity', this.elementOpacity);\n childElement.id = this.elementId + '_Zooming_Pan';\n childElement.setAttribute('role', 'button');\n childElement.setAttribute('aria-label', this.chart.getLocalizedLabel('Pan'));\n this.panElements = childElement;\n childElement.appendChild(render.drawRectangle(new RectOption(this.elementId + '_Zooming_Pan_1', 'transparent', {}, 1, this.chart.themeStyle.toolkitIconRect)));\n childElement.appendChild(render.drawPath(new PathOption(this.elementId + '_Zooming_Pan_2', fillColor, null, null, 1, null, direction)));\n parentElement.appendChild(childElement);\n this.wireEvents(childElement, this.pan);\n };\n /**\n * To create the zoom button.\n *\n * @returns {void}\n * @private\n */\n Toolkit.prototype.createZoomButton = function (childElement, parentElement) {\n var render = this.chart.svgRenderer;\n //This is for selecting initial fill color to ZOOM button\n var fillColor = this.chart.zoomModule.isPanning || (!this.chart.zoomModule.isZoomed &&\n this.chart.zoomSettings.showToolbar) ? this.chart.themeStyle.toolkitFill : this.chart.themeStyle.toolkitSelectionColor;\n this.elementOpacity = !this.chart.zoomModule.isPanning && !this.chart.zoomModule.isZoomed && this.chart.zoomSettings.showToolbar ? '0.2' : '1';\n var rectColor = this.chart.zoomModule.isPanning ? 'transparent' : this.chart.themeStyle.toolkitIconRectSelectionFill;\n var direction = 'M0.001,14.629L1.372,16l4.571-4.571v-0.685l0.228-0.274c1.051,0.868,2.423,1.417,3.885,1.417c3.291,0,';\n direction += '5.943-2.651,5.943-5.943S13.395,0,10.103,0S4.16,2.651,4.16,5.943c0,1.508,0.503,2.834,1.417,3.885l-0.274,0.228H4.571';\n direction = direction + 'L0.001,14.629L0.001,14.629z M5.943,5.943c0-2.285,1.828-4.114,4.114-4.114s4.114,1.828,4.114,';\n childElement.id = this.elementId + '_Zooming_Zoom';\n childElement.setAttribute('role', 'button');\n childElement.setAttribute('aria-label', this.chart.getLocalizedLabel('Zoom'));\n childElement.setAttribute('opacity', this.elementOpacity);\n this.zoomElements = childElement;\n this.selectedID = this.chart.zoomModule.isPanning ? this.chart.element.id + '_Zooming_Pan_1' : this.elementId + '_Zooming_Zoom_1';\n childElement.appendChild(render.drawRectangle(new RectOption(this.elementId + '_Zooming_Zoom_1', rectColor, {}, 1, this.chart.themeStyle.toolkitIconRect)));\n childElement.appendChild(render.drawPath(new PathOption(this.elementId + '_Zooming_Zoom_3', fillColor, null, null, 1, null, direction + '4.114s-1.828,4.114-4.114,4.114S5.943,8.229,5.943,5.943z')));\n parentElement.appendChild(childElement);\n this.wireEvents(childElement, this.zoom);\n };\n /**\n * To create the ZoomIn button.\n *\n * @returns {void}\n * @private\n */\n Toolkit.prototype.createZoomInButton = function (childElement, parentElement, chart) {\n var render = this.chart.svgRenderer;\n var fillColor = this.chart.themeStyle.toolkitFill;\n var direction = 'M10.103,0C6.812,0,4.16,2.651,4.16,5.943c0,1.509,0.503,2.834,1.417,3.885l-0.274,0.229H4.571L0,';\n direction += '14.628l0,0L1.372,16l4.571-4.572v-0.685l0.228-0.275c1.052,0.868,2.423,1.417,3.885,1.417c3.291,0,5.943-2.651,';\n direction += '5.943-5.943C16,2.651,13.395,0,10.103,0z M10.058,10.058c-2.286,0-4.114-1.828-4.114-4.114c0-2.286,1.828-4.114,';\n childElement.id = this.elementId + '_Zooming_ZoomIn';\n childElement.setAttribute('role', 'button');\n childElement.setAttribute('aria-label', this.chart.getLocalizedLabel('ZoomIn'));\n var polygonDirection = '12.749,5.466 10.749,5.466 10.749,3.466 9.749,3.466 9.749,5.466 7.749,5.466 7.749,6.466';\n childElement.appendChild(render.drawRectangle(new RectOption(this.elementId + '_Zooming_ZoomIn_1', 'transparent', {}, 1, this.chart.themeStyle.toolkitIconRect)));\n childElement.appendChild(render.drawPath(new PathOption(this.elementId + '_Zooming_ZoomIn_2', fillColor, null, null, 1, null, direction + '4.114-4.114c2.286,0,4.114,1.828,4.114,4.114C14.172,8.229,12.344,10.058,10.058,10.058z')));\n childElement.appendChild(render.drawPolygon(new PolygonOption(this.elementId + '_Zooming_ZoomIn_3', polygonDirection + ' 9.749,6.466 9.749,8.466 10.749,8.466 10.749,6.466 12.749,6.466', fillColor)));\n this.zoomInElements = childElement;\n //This is for low opacity to ZOOM IN button\n this.elementOpacity = chart.zoomModule.isPanning || (!chart.zoomModule.isZoomed && !chart.zoomSettings.showToolbar && !this.enableZoomButton) ? '0.2' : '1';\n childElement.setAttribute('opacity', this.elementOpacity);\n parentElement.appendChild(childElement);\n this.wireEvents(childElement, this.zoomIn);\n };\n /**\n * To create the ZoomOut button.\n *\n * @returns {void}\n * @private\n */\n Toolkit.prototype.createZoomOutButton = function (childElement, parentElement, chart) {\n var render = this.chart.svgRenderer;\n var fillColor = this.chart.themeStyle.toolkitFill;\n var direction = 'M0,14.622L1.378,16l4.533-4.533v-0.711l0.266-0.266c1.022,0.889,2.4,1.422,3.866,';\n direction += '1.422c3.289,0,5.955-2.666,5.955-5.955S13.333,0,10.044,0S4.089,2.667,4.134,5.911c0,1.466,0.533,2.844,';\n direction += '1.422,3.866l-0.266,0.266H4.578L0,14.622L0,14.622z M5.911,5.911c0-2.311,1.822-4.133,4.133-4.133s4.133,1.822,4.133,';\n childElement.id = this.elementId + '_Zooming_ZoomOut';\n childElement.setAttribute('role', 'button');\n childElement.setAttribute('aria-label', this.chart.getLocalizedLabel('ZoomOut'));\n childElement.appendChild(render.drawRectangle(new RectOption(this.elementId + '_Zooming_ZoomOut_1', 'transparent', {}, 1, this.chart.themeStyle.toolkitIconRect)));\n childElement.appendChild(render.drawPath(new PathOption(this.elementId + '_Zooming_ZoomOut_2', fillColor, null, null, 1, null, direction + '4.133s-1.866,4.133-4.133,4.133S5.911,8.222,5.911,5.911z M12.567,6.466h-5v-1h5V6.466z')));\n this.zoomOutElements = childElement;\n //This is for low opacity of ZOOM OUT button\n this.elementOpacity = chart.zoomModule.isPanning || (!chart.zoomModule.isZoomed && chart.zoomSettings.showToolbar && !this.enableZoomButton) ? '0.2' : '1';\n childElement.setAttribute('opacity', this.elementOpacity);\n parentElement.appendChild(childElement);\n this.wireEvents(childElement, this.zoomOut);\n };\n /**\n * To create the Reset button.\n *\n * @returns {void}\n * @private\n */\n Toolkit.prototype.createResetButton = function (childElement, parentElement, chart, isDevice) {\n var render = this.chart.svgRenderer;\n var fillColor = this.chart.themeStyle.toolkitFill;\n var size;\n var direction = 'M12.364,8h-2.182l2.909,3.25L16,8h-2.182c0-3.575-2.618-6.5-5.818-6.5c-1.128,0-2.218,0.366-3.091,';\n direction += '1.016l1.055,1.178C6.581,3.328,7.272,3.125,8,3.125C10.4,3.125,12.363,5.319,12.364,8L12.364,8z M11.091,';\n direction += '13.484l-1.055-1.178C9.419,12.672,8.728,12.875,8,12.875c-2.4,0-4.364-2.194-4.364-4.875h2.182L2.909,4.75L0,8h2.182c0,';\n childElement.id = this.elementId + '_Zooming_Reset';\n childElement.setAttribute('role', 'button');\n childElement.setAttribute('aria-label', this.chart.getLocalizedLabel('Reset'));\n //This is for low opacity to RESET button\n this.elementOpacity = !chart.zoomModule.isZoomed && chart.zoomSettings.showToolbar ? '0.2' : '1';\n childElement.setAttribute('opacity', this.elementOpacity);\n if (!isDevice) {\n childElement.appendChild(render.drawRectangle(new RectOption(this.elementId + '_Zooming_Reset_1', 'transparent', {}, 1, this.chart.themeStyle.toolkitIconRect)));\n childElement.appendChild(render.drawPath(new PathOption(this.elementId + '_Zooming_Reset_2', fillColor, null, null, 1, null, direction + '3.575,2.618,6.5,5.818,6.5C9.128,14.5,10.219,14.134,11.091,13.484L11.091,13.484z')));\n }\n else {\n size = measureText(this.chart.getLocalizedLabel('ResetZoom'), { size: '12px' }, { size: '12px', fontStyle: 'Normal', fontWeight: '400', fontFamily: 'Segoe UI' });\n childElement.appendChild(render.drawRectangle(new RectOption(this.elementId + '_Zooming_Reset_1', 'transparent', {}, 1, new Rect(0, 0, size.width, size.height))));\n textElement(chart.renderer, new TextOption(this.elementId + '_Zooming_Reset_2', 0 + size.width / 2, 0 + size.height * 3 / 4, 'middle', this.chart.getLocalizedLabel('ResetZoom'), 'rotate(0,' + (0) + ',' + (0) + ')', 'auto'), { size: '12px' }, this.chart.theme === 'Material3Dark' ? 'White' : 'black', childElement, null, null, null, null, null, null, null, null, chart.enableCanvas, null, { size: '12px', fontStyle: 'Normal', fontWeight: '400', fontFamily: 'Segoe UI' });\n }\n parentElement.appendChild(childElement);\n this.wireEvents(childElement, this.reset);\n };\n /**\n * To bind events.\n *\n * @returns {void}\n * @private\n */\n Toolkit.prototype.wireEvents = function (element, process) {\n EventHandler.add(element, 'mousedown touchstart', process, this);\n EventHandler.add(element, 'mouseover', this.showTooltip, this);\n EventHandler.add(element, 'mouseout', this.removeTooltip, this);\n };\n /**\n * To show tooltip.\n *\n * @returns {void}\n * @private\n */\n Toolkit.prototype.showTooltip = function (event) {\n var text = event.currentTarget.id.split('_Zooming_')[1];\n var left = (event.pageX - (measureText(text, { size: '10px' }, { size: '10px', fontStyle: 'Normal', fontWeight: '400', fontFamily: 'Segoe UI' }).width + 5));\n var rect = getElement(event.currentTarget.id + '_1');\n var icon2 = getElement(event.currentTarget.id + '_2');\n var icon3 = getElement(event.currentTarget.id + '_3');\n if (event.currentTarget.getAttribute('opacity') === '1') {\n event.currentTarget.setAttribute('cursor', 'pointer');\n }\n else {\n event.currentTarget.setAttribute('cursor', 'auto');\n }\n if (rect) {\n this.hoveredID = rect.id;\n rect.setAttribute('fill', this.chart.themeStyle.toolkitIconRectOverFill);\n }\n if (icon2) {\n icon2.setAttribute('fill', this.chart.themeStyle.toolkitSelectionColor);\n }\n if (icon3) {\n icon3.setAttribute('fill', this.chart.themeStyle.toolkitSelectionColor);\n }\n if (!this.chart.isTouch) {\n createTooltip('EJ2_Chart_ZoomTip', this.chart.getLocalizedLabel(text), (event.pageY + 10), left, '10px');\n }\n };\n /** @private */\n /* eslint-disable */\n Toolkit.prototype.removeTooltip = function () {\n if (this.hoveredID && getElement(this.hoveredID)) {\n var rectColor = this.chart.zoomModule.isPanning ? (this.hoveredID.indexOf('_Pan_') > -1) ? this.chart.themeStyle.toolkitIconRectSelectionFill : 'transparent' : (this.hoveredID.indexOf('_Zoom_') > -1) ? this.chart.themeStyle.toolkitIconRectSelectionFill : 'transparent';\n getElement(this.hoveredID).setAttribute('fill', rectColor);\n }\n var icon2 = this.hoveredID ? getElement(this.hoveredID.replace('_1', '_2')) : null;\n var icon3 = this.hoveredID ? getElement(this.hoveredID.replace('_1', '_3')) : null;\n if (icon2) {\n var iconColor = this.chart.zoomModule.isPanning ? (this.hoveredID.indexOf('_Pan_') > -1) ? this.chart.themeStyle.toolkitSelectionColor : this.chart.themeStyle.toolkitFill : (this.hoveredID.indexOf('_Zoom_') > -1) ? this.chart.themeStyle.toolkitSelectionColor : this.chart.themeStyle.toolkitFill;\n icon2.setAttribute('fill', iconColor);\n }\n if (icon3) {\n //This is used for change color while hover on ZOOM button\n var iconColor = this.chart.zoomModule.isPanning || (!this.chart.isZoomed && this.chart.zoomSettings.showToolbar) ? this.chart.themeStyle.toolkitFill : (this.hoveredID.indexOf('_Zoom_') > -1) ? this.chart.themeStyle.toolkitSelectionColor : this.chart.themeStyle.toolkitFill;\n icon3.setAttribute('fill', iconColor);\n }\n removeElement('EJ2_Chart_ZoomTip');\n };\n // Toolkit events function calculation here.\n /** @private */\n Toolkit.prototype.reset = function (event) {\n var _this = this;\n if (!this.chart.zoomModule.isZoomed) {\n return false;\n }\n var chart = this.chart;\n this.enableZoomButton = false;\n if (!chart.zoomModule.isDevice) {\n remove(chart.zoomModule.toolkitElements);\n }\n else if (event.type == 'touchstart') {\n event.stopPropagation();\n }\n var argsData;\n this.removeTooltip();\n chart.svgObject.setAttribute('cursor', 'auto');\n var zoomingEventArgs;\n var zoomedAxisCollection = [];\n this.zoomCompleteEvtCollection = [];\n for (var _i = 0, _a = chart.axisCollections; _i < _a.length; _i++) {\n var axis = _a[_i];\n argsData = {\n cancel: false, name: zoomComplete, axis: axis, previousZoomFactor: axis.zoomFactor,\n previousZoomPosition: axis.zoomPosition, currentZoomFactor: 1, currentZoomPosition: 0,\n previousVisibleRange: axis.visibleRange, currentVisibleRange: null\n };\n axis.zoomFactor = 1;\n axis.zoomPosition = 0;\n if (axis.zoomingScrollBar) {\n axis.zoomingScrollBar.isScrollUI = false;\n }\n if (!argsData.cancel) {\n axis.zoomFactor = argsData.currentZoomFactor;\n axis.zoomPosition = argsData.currentZoomPosition;\n this.zoomCompleteEvtCollection.push(argsData);\n }\n zoomedAxisCollection.push({\n zoomFactor: axis.zoomFactor, zoomPosition: axis.zoomFactor, axisName: axis.name,\n axisRange: axis.visibleRange\n });\n if (chart.zoomModule.isDevice && !this.chart.isBlazor) {\n chart.trigger(zoomComplete, argsData);\n }\n }\n zoomingEventArgs = { cancel: false, axisCollection: zoomedAxisCollection, name: onZooming };\n if (!zoomingEventArgs.cancel && this.chart.isBlazor) {\n this.chart.trigger(onZooming, zoomingEventArgs, function () {\n _this.setDefferedZoom(chart);\n });\n return false;\n }\n else {\n return (this.setDefferedZoom(chart));\n }\n };\n Toolkit.prototype.setDefferedZoom = function (chart) {\n chart.disableTrackTooltip = false;\n chart.zoomModule.isZoomed = chart.zoomModule.isPanning = chart.isChartDrag = chart.delayRedraw = false;\n chart.zoomModule.touchMoveList = chart.zoomModule.touchStartList = [];\n chart.zoomModule.pinchTarget = null;\n chart.removeSvg();\n chart.refreshAxis();\n chart.refreshBound();\n this.elementOpacity = '1';\n return false;\n };\n Toolkit.prototype.zoomIn = function (e) {\n this.zoomInOutCalculation(1, this.chart, this.chart.axisCollections, this.chart.zoomSettings.mode);\n return false;\n };\n Toolkit.prototype.zoomOut = function (e) {\n this.enableZoomButton = false;\n this.zoomInOutCalculation(-1, this.chart, this.chart.axisCollections, this.chart.zoomSettings.mode);\n return false;\n };\n Toolkit.prototype.zoom = function (e) {\n this.chart.zoomModule.isPanning = false;\n var zoomModule = this.chart.zoomModule;\n this.elementOpacity = '1';\n this.chart.svgObject.setAttribute('cursor', 'auto');\n this.zoomInElements.setAttribute('opacity', this.elementOpacity);\n this.elementOpacity = (!this.chart.zoomModule.isZoomed && this.chart.zoomSettings.showToolbar) ? '0.2' : '1';\n this.zoomOutElements.setAttribute('opacity', this.elementOpacity);\n this.applySelection(this.zoomElements.childNodes, this.chart.themeStyle.toolkitSelectionColor);\n this.applySelection(this.panElements.childNodes, '#737373');\n if (getElement(this.selectedID)) {\n getElement(this.selectedID).setAttribute('fill', 'transparent');\n }\n this.selectedID = this.chart.element.id + '_Zooming_Zoom_1';\n getElement(this.selectedID).setAttribute('fill', this.chart.themeStyle.toolkitIconRectSelectionFill);\n return false;\n };\n /** @private */\n Toolkit.prototype.pan = function () {\n if (!this.chart.zoomModule.isZoomed) {\n return false;\n }\n var element;\n this.chart.zoomModule.isPanning = true;\n this.chart.svgObject.setAttribute('cursor', 'pointer');\n this.elementOpacity = '0.2';\n element = this.zoomInElements ? this.zoomInElements.setAttribute('opacity', this.elementOpacity) : null;\n element = this.zoomOutElements ? this.zoomOutElements.setAttribute('opacity', this.elementOpacity) : null;\n element = this.panElements ? this.applySelection(this.panElements.childNodes, this.chart.themeStyle.toolkitSelectionColor) : null;\n element = this.zoomElements ? this.applySelection(this.zoomElements.childNodes, '#737373') : null;\n if (getElement(this.selectedID)) {\n getElement(this.selectedID).setAttribute('fill', 'transparent');\n }\n this.selectedID = this.chart.element.id + '_Zooming_Pan_1';\n getElement(this.selectedID).setAttribute('fill', this.chart.themeStyle.toolkitIconRectSelectionFill);\n return false;\n };\n Toolkit.prototype.zoomInOutCalculation = function (scale, chart, axes, mode) {\n var _this = this;\n if (chart.zoomSettings.showToolbar) {\n this.elementOpacity = this.zoomInElements.getAttribute('opacity');\n }\n if (!chart.zoomModule.isPanning && this.elementOpacity !== '0.2') {\n if ((chart.zoomSettings.showToolbar && !chart.isZoomed)) {\n chart.zoomModule.isZoomed = true;\n }\n var zoomFactor = void 0;\n var zoomPosition = void 0;\n var cumulative = void 0;\n chart.disableTrackTooltip = true;\n chart.delayRedraw = true;\n var argsData = void 0;\n this.zoomCompleteEvtCollection = [];\n var zoomedAxisCollection = [];\n for (var _i = 0, _a = axes; _i < _a.length; _i++) {\n var axis = _a[_i];\n argsData = {\n cancel: false, name: zoomComplete, axis: axis, previousZoomFactor: axis.zoomFactor,\n previousZoomPosition: axis.zoomPosition, currentZoomFactor: axis.zoomFactor, currentZoomPosition: axis.zoomPosition,\n previousVisibleRange: axis.visibleRange, currentVisibleRange: null\n };\n if ((axis.orientation === 'Horizontal' && mode !== 'Y') ||\n (axis.orientation === 'Vertical')) {\n cumulative = Math.max(Math.max(1 / minMax(axis.zoomFactor, 0, 1), 1) + (0.25 * scale), 1);\n zoomFactor = (cumulative === 1) ? 1 : minMax(1 / cumulative, 0, 1);\n zoomPosition = (cumulative === 1) ? 0 : axis.zoomPosition + ((axis.zoomFactor - zoomFactor) * 0.5);\n if (axis.zoomPosition !== zoomPosition || axis.zoomFactor !== zoomFactor) {\n zoomFactor = (zoomPosition + zoomFactor) > 1 ? (1 - zoomPosition) : zoomFactor;\n }\n argsData.currentZoomFactor = zoomFactor;\n argsData.currentZoomPosition = zoomPosition;\n if (!argsData.cancel) {\n axis.zoomFactor = argsData.currentZoomFactor;\n axis.zoomPosition = argsData.currentZoomPosition;\n this.zoomCompleteEvtCollection.push(argsData);\n }\n zoomedAxisCollection.push({\n zoomFactor: axis.zoomFactor, zoomPosition: axis.zoomFactor, axisName: axis.name,\n axisRange: axis.visibleRange\n });\n }\n }\n var zoomingEventArgs_1 = { cancel: false, axisCollection: zoomedAxisCollection, name: onZooming };\n this.chart.trigger(onZooming, zoomingEventArgs_1, function () {\n if (zoomingEventArgs_1.cancel) {\n var zoom = new Zoom(chart);\n zoom.zoomCancel(axes, _this.zoomCompleteEvtCollection);\n }\n });\n }\n };\n Toolkit.prototype.applySelection = function (elements, color) {\n for (var i = 1, length_1 = elements.length; i < length_1; i++) {\n elements[i].setAttribute('fill', color);\n }\n };\n return Toolkit;\n}());\nexport { Toolkit };\n","import { EventHandler, Browser, createElement } from '@syncfusion/ej2-base';\nimport { getRectLocation, minMax, getElement, ChartLocation, RectOption } from '../../common/utils/helper';\nimport { Rect, measureText } from '@syncfusion/ej2-svg-base';\nimport { Toolkit } from './zooming-toolkit';\nimport { zoomComplete, onZooming } from '../../common/model/constants';\nimport { withInBounds } from '../../common/utils/helper';\n/**\n * `Zooming` module handles the zooming for chart.\n */\nvar Zoom = /** @class */ (function () {\n /**\n * Constructor for Zooming module.\n *\n * @private\n */\n function Zoom(chart) {\n this.zoomCompleteEvtCollection = [];\n this.chart = chart;\n this.isPointer = Browser.isPointer;\n this.browserName = Browser.info.name;\n this.wheelEvent = this.browserName === 'mozilla' ? (this.isPointer ? 'mousewheel' : 'DOMMouseScroll') : 'mousewheel';\n this.cancelEvent = this.isPointer ? 'pointerleave' : 'mouseleave';\n this.addEventListener();\n this.isDevice = Browser.isDevice;\n var zooming = chart.zoomSettings;\n this.toolkit = new Toolkit(chart);\n this.zooming = zooming;\n this.elementId = chart.element.id;\n this.zoomingRect = new Rect(0, 0, 0, 0);\n this.zoomAxes = [];\n this.zoomkitOpacity = 1;\n this.isIOS = Browser.isIos || Browser.isIos7;\n this.isZoomed = this.performedUI = this.zooming.enablePan ||\n ((this.chart.primaryXAxis.zoomFactor < 1 && this.chart.primaryXAxis.zoomPosition > 0) ||\n (this.chart.primaryYAxis.zoomFactor < 1 && this.chart.primaryYAxis.zoomPosition > 0) || this.isAxisZoomed(this.chart.axes));\n if (zooming.enableScrollbar) {\n chart.scrollElement = createElement('div', { id: chart.element.id + '_scrollElement' });\n }\n }\n /**\n * Function that handles the Rectangular zooming.\n *\n * @returns {void}\n */\n Zoom.prototype.renderZooming = function (e, chart, isTouch) {\n this.calculateZoomAxesRange(chart);\n if (this.zooming.enableSelectionZooming && (!isTouch\n || (chart.isDoubleTap && this.touchStartList.length === 1)) && (!this.isPanning || chart.isDoubleTap)) {\n this.isPanning = this.isDevice ? true : this.isPanning;\n this.performedUI = true;\n this.drawZoomingRectangle(chart);\n }\n else if (this.isPanning && chart.isChartDrag) {\n if (!isTouch || (isTouch && this.touchStartList.length === 1)) {\n this.pinchTarget = isTouch ? e.target : null;\n this.doPan(chart, chart.axisCollections);\n }\n }\n };\n // Zooming rectangle drawn here\n Zoom.prototype.drawZoomingRectangle = function (chart) {\n var areaBounds = chart.chartAxisLayoutPanel.seriesClipRect;\n var startLocation = new ChartLocation(chart.previousMouseMoveX, chart.previousMouseMoveY);\n var endLocation = new ChartLocation(chart.mouseX, chart.mouseY);\n var rect = this.zoomingRect = getRectLocation(startLocation, endLocation, areaBounds);\n if (rect.width > 0 && rect.height > 0) {\n this.isZoomed = true;\n chart.disableTrackTooltip = true;\n chart.svgObject.setAttribute('cursor', 'crosshair');\n if (this.zooming.mode === 'Y') {\n rect.width = areaBounds.width;\n rect.x = areaBounds.x;\n }\n var svg = chart.enableCanvas ? document.getElementById(this.elementId + '_tooltip_svg') : chart.svgObject;\n svg.appendChild(chart.svgRenderer.drawRectangle(new RectOption(this.elementId + '_ZoomArea', chart.themeStyle.selectionRectFill, { color: chart.themeStyle.selectionRectStroke, width: 1 }, 1, rect, 0, 0, '', '3')));\n }\n };\n // Panning performed here\n Zoom.prototype.doPan = function (chart, axes, xDifference, yDifference) {\n var _this = this;\n if (xDifference === void 0) { xDifference = 0; }\n if (yDifference === void 0) { yDifference = 0; }\n if (chart.startMove && chart.crosshair.enable) {\n return null;\n }\n var currentScale;\n var offset;\n this.isZoomed = true;\n this.offset = !chart.delayRedraw ? chart.chartAxisLayoutPanel.seriesClipRect : this.offset;\n chart.delayRedraw = true;\n this.zoomCompleteEvtCollection = [];\n chart.disableTrackTooltip = true;\n var argsData;\n var zoomedAxisCollection = [];\n for (var _i = 0, _a = axes; _i < _a.length; _i++) {\n var axis = _a[_i];\n argsData = {\n cancel: false, name: zoomComplete, axis: axis, previousZoomFactor: axis.zoomFactor,\n previousZoomPosition: axis.zoomPosition, currentZoomFactor: axis.zoomFactor,\n currentZoomPosition: axis.zoomPosition, previousVisibleRange: axis.visibleRange,\n currentVisibleRange: null\n };\n currentScale = Math.max(1 / minMax(axis.zoomFactor, 0, 1), 1);\n if (axis.orientation === 'Horizontal') {\n offset = (xDifference !== 0 ? xDifference : (chart.previousMouseMoveX - chart.mouseX)) / axis.rect.width / currentScale;\n argsData.currentZoomPosition = minMax(axis.zoomPosition + offset, 0, (1 - axis.zoomFactor));\n }\n else {\n offset = (yDifference !== 0 ? yDifference : (chart.previousMouseMoveY - chart.mouseY)) / axis.rect.height / currentScale;\n argsData.currentZoomPosition = minMax(axis.zoomPosition - offset, 0, (1 - axis.zoomFactor));\n }\n if (!argsData.cancel) {\n axis.zoomFactor = argsData.currentZoomFactor;\n axis.zoomPosition = argsData.currentZoomPosition;\n this.zoomCompleteEvtCollection.push(argsData);\n }\n zoomedAxisCollection.push({\n zoomFactor: axis.zoomFactor, zoomPosition: axis.zoomFactor, axisName: axis.name,\n axisRange: axis.visibleRange\n });\n }\n var zoomingEventArgs = { cancel: false, axisCollection: zoomedAxisCollection, name: onZooming };\n if (!zoomingEventArgs.cancel && this.chart.isBlazor) {\n this.chart.trigger(onZooming, zoomingEventArgs, function () {\n if (zoomingEventArgs.cancel) {\n _this.zoomCancel(axes, _this.zoomCompleteEvtCollection);\n }\n else {\n _this.performDefferedZoom(chart);\n }\n });\n }\n else {\n this.chart.trigger(onZooming, zoomingEventArgs, function () {\n if (zoomingEventArgs.cancel) {\n _this.zoomCancel(axes, _this.zoomCompleteEvtCollection);\n }\n else {\n _this.performDefferedZoom(chart);\n _this.redrawOnZooming(chart, false);\n }\n });\n }\n };\n Zoom.prototype.performDefferedZoom = function (chart) {\n var translateX;\n var translateY;\n if (this.zooming.enableDeferredZooming) {\n translateX = chart.mouseX - chart.mouseDownX;\n translateY = chart.mouseY - chart.mouseDownY;\n switch (this.zooming.mode) {\n case 'Y':\n translateX = 0;\n break;\n }\n this.setTransform(translateX, translateY, null, null, chart, false);\n this.refreshAxis(chart.chartAxisLayoutPanel, chart, chart.axisCollections);\n if (chart.enableCanvas) {\n this.performZoomRedraw(chart);\n }\n }\n else {\n this.performZoomRedraw(chart);\n }\n chart.previousMouseMoveX = chart.mouseX;\n chart.previousMouseMoveY = chart.mouseY;\n };\n /**\n * Redraw the chart on zooming.\n *\n * @returns {void}\n * @private\n */\n Zoom.prototype.performZoomRedraw = function (chart) {\n var rect = this.zoomingRect;\n chart.animateSeries = false;\n if (this.isZoomed) {\n if (rect.width > 0 && rect.height > 0) {\n this.performedUI = true;\n chart.svgObject.setAttribute('cursor', 'auto');\n this.doZoom(chart, chart.axisCollections, chart.chartAxisLayoutPanel.seriesClipRect);\n chart.isDoubleTap = false;\n }\n else if (chart.disableTrackTooltip) {\n chart.disableTrackTooltip = false;\n chart.delayRedraw = false;\n chart.enableCanvas ? chart.createChartSvg() : chart.removeSvg();\n chart.refreshAxis();\n chart.refreshBound();\n }\n }\n };\n Zoom.prototype.refreshAxis = function (layout, chart, axes) {\n var mode = chart.zoomSettings.mode;\n layout.measureAxis(new Rect(chart.initialClipRect.x, chart.initialClipRect.y, chart.initialClipRect.width, chart.initialClipRect.height));\n axes.map(function (axis, index) {\n if (axis.orientation === 'Horizontal' && mode !== 'Y') {\n layout.drawXAxisLabels(axis, index, null, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n }\n if (axis.orientation === 'Vertical') {\n layout.drawYAxisLabels(axis, index, null, (axis.placeNextToAxisLine ? axis.updatedRect : axis.rect));\n }\n });\n };\n // Rectangular zoom calculated here performed here\n Zoom.prototype.doZoom = function (chart, axes, bounds) {\n var _this = this;\n var zoomRect = this.zoomingRect;\n var mode = this.zooming.mode;\n var argsData;\n this.isPanning = chart.zoomSettings.enablePan || this.isPanning;\n var zoomedAxisCollections = [];\n this.zoomCompleteEvtCollection = [];\n for (var _i = 0, _a = axes; _i < _a.length; _i++) {\n var axis = _a[_i];\n argsData = {\n cancel: false, name: zoomComplete, axis: axis,\n previousZoomFactor: axis.zoomFactor,\n previousZoomPosition: axis.zoomPosition,\n currentZoomFactor: axis.zoomFactor,\n currentZoomPosition: axis.zoomPosition,\n previousVisibleRange: axis.visibleRange, currentVisibleRange: null\n };\n if (axis.orientation === 'Horizontal') {\n if (mode !== 'Y') {\n argsData.currentZoomPosition += Math.abs((zoomRect.x - bounds.x) / (bounds.width)) * axis.zoomFactor;\n argsData.currentZoomFactor *= (zoomRect.width / bounds.width);\n }\n }\n else {\n argsData.currentZoomPosition += (1 - Math.abs((zoomRect.height + (zoomRect.y - bounds.y)) / (bounds.height)))\n * axis.zoomFactor;\n argsData.currentZoomFactor *= (zoomRect.height / bounds.height);\n }\n if (parseFloat(argsData.currentZoomFactor.toFixed(3)) <= 0.001) {\n argsData.currentZoomFactor = argsData.previousZoomFactor;\n argsData.currentZoomPosition = argsData.previousZoomPosition;\n }\n if (!argsData.cancel) {\n axis.zoomFactor = argsData.currentZoomFactor;\n axis.zoomPosition = argsData.currentZoomPosition;\n this.zoomCompleteEvtCollection.push(argsData);\n }\n zoomedAxisCollections.push({\n zoomFactor: axis.zoomFactor, zoomPosition: axis.zoomFactor, axisName: axis.name,\n axisRange: axis.visibleRange\n });\n }\n var onZoomingEventArg = { cancel: false, axisCollection: zoomedAxisCollections, name: onZooming };\n if (!onZoomingEventArg.cancel && this.chart.isBlazor) {\n this.chart.trigger(onZooming, onZoomingEventArg, function () {\n if (onZoomingEventArg.cancel) {\n _this.zoomCancel(axes, _this.zoomCompleteEvtCollection);\n }\n else {\n _this.zoomingRect = new Rect(0, 0, 0, 0);\n _this.performZoomRedraw(chart);\n }\n });\n }\n else {\n this.chart.trigger(onZooming, onZoomingEventArg, function () {\n if (onZoomingEventArg.cancel) {\n _this.zoomCancel(axes, _this.zoomCompleteEvtCollection);\n }\n else {\n _this.zoomingRect = new Rect(0, 0, 0, 0);\n _this.redrawOnZooming(chart);\n }\n });\n }\n };\n /** It is used to redraw the chart and trigger zoomComplete event */\n Zoom.prototype.redrawOnZooming = function (chart, isRedraw, isMouseUp) {\n if (isRedraw === void 0) { isRedraw = true; }\n if (isMouseUp === void 0) { isMouseUp = false; }\n var zoomCompleteCollection = isMouseUp ? this.toolkit.zoomCompleteEvtCollection :\n this.zoomCompleteEvtCollection;\n if (isRedraw) {\n this.performZoomRedraw(chart);\n }\n var argsData;\n for (var i = 0; i < zoomCompleteCollection.length; i++) {\n if (!zoomCompleteCollection[i].cancel) {\n argsData = {\n cancel: false, name: zoomComplete,\n axis: chart.axisCollections[i],\n previousZoomFactor: zoomCompleteCollection[i].previousZoomFactor,\n previousZoomPosition: zoomCompleteCollection[i].previousZoomPosition,\n currentZoomFactor: chart.axisCollections[i].zoomFactor,\n currentZoomPosition: chart.axisCollections[i].zoomPosition,\n currentVisibleRange: chart.axisCollections[i].visibleRange,\n previousVisibleRange: zoomCompleteCollection[i].previousVisibleRange\n };\n chart.trigger(zoomComplete, argsData);\n }\n }\n };\n /**\n * Function that handles the Mouse wheel zooming.\n *\n * @returns {void}\n * @private\n */\n Zoom.prototype.performMouseWheelZooming = function (e, mouseX, mouseY, chart, axes) {\n var _this = this;\n var direction = (this.browserName === 'mozilla' && !this.isPointer) ?\n -(e.detail) / 3 > 0 ? 1 : -1 : (e['wheelDelta'] > 0 ? 1 : -1);\n var mode = this.zooming.mode;\n var origin = 0.5;\n var cumulative;\n var zoomFactor;\n var zoomPosition;\n this.isZoomed = true;\n this.calculateZoomAxesRange(chart);\n chart.disableTrackTooltip = true;\n this.performedUI = true;\n this.isPanning = chart.zoomSettings.enablePan || this.isPanning;\n this.zoomCompleteEvtCollection = [];\n var argsData;\n var zoomedAxisCollection = [];\n for (var _i = 0, _a = axes; _i < _a.length; _i++) {\n var axis = _a[_i];\n argsData = {\n cancel: false, name: zoomComplete, axis: axis, previousZoomFactor: axis.zoomFactor,\n previousZoomPosition: axis.zoomPosition,\n currentZoomFactor: axis.zoomFactor,\n currentZoomPosition: axis.zoomPosition, currentVisibleRange: null,\n previousVisibleRange: axis.visibleRange\n };\n if ((axis.orientation === 'Vertical') ||\n (axis.orientation === 'Horizontal' && mode !== 'Y')) {\n cumulative = Math.max(Math.max(1 / minMax(axis.zoomFactor, 0, 1), 1) + (0.25 * direction), 1);\n cumulative = (cumulative > 50000000000) ? 50000000000 : cumulative;\n if (cumulative >= 1) {\n origin = axis.orientation === 'Horizontal' ? mouseX / axis.rect.width : 1 - (mouseY / axis.rect.height);\n origin = origin > 1 ? 1 : origin < 0 ? 0 : origin;\n zoomFactor = (cumulative === 1) ? 1 : minMax((direction > 0 ? 0.9 : 1.1) / cumulative, 0, 1);\n zoomPosition = (cumulative === 1) ? 0 : axis.zoomPosition + ((axis.zoomFactor - zoomFactor) * origin);\n if (axis.zoomPosition !== zoomPosition || axis.zoomFactor !== zoomFactor) {\n zoomFactor = (zoomPosition + zoomFactor) > 1 ? (1 - zoomPosition) : zoomFactor;\n }\n argsData.currentZoomFactor = zoomFactor;\n argsData.currentZoomPosition = zoomPosition;\n }\n if (argsData.currentZoomFactor === argsData.previousZoomFactor && argsData.currentZoomPosition === argsData.previousZoomPosition) {\n chart.disableTrackTooltip = false;\n }\n if (!argsData.cancel) {\n axis.zoomFactor = argsData.currentZoomFactor;\n axis.zoomPosition = argsData.currentZoomPosition;\n this.zoomCompleteEvtCollection.push(argsData);\n }\n }\n zoomedAxisCollection.push({\n zoomFactor: axis.zoomFactor, zoomPosition: axis.zoomFactor, axisName: axis.name,\n axisRange: axis.visibleRange\n });\n }\n var onZoomingEventArgs = { cancel: false, axisCollection: zoomedAxisCollection, name: onZooming };\n if (!onZoomingEventArgs.cancel && this.chart.isBlazor) {\n this.chart.trigger(onZooming, onZoomingEventArgs, function () {\n if (onZoomingEventArgs.cancel) {\n _this.zoomCancel(axes, _this.zoomCompleteEvtCollection);\n }\n else {\n _this.performZoomRedraw(chart);\n }\n });\n }\n else {\n this.chart.trigger(onZooming, onZoomingEventArgs, function () {\n if (onZoomingEventArgs.cancel) {\n _this.zoomCancel(axes, _this.zoomCompleteEvtCollection);\n }\n else {\n _this.redrawOnZooming(chart);\n }\n });\n }\n };\n /**\n * Function that handles the Pinch zooming.\n *\n * @returns {void}\n * @private\n */\n Zoom.prototype.performPinchZooming = function (e, chart) {\n if ((this.zoomingRect.width > 0 && this.zoomingRect.height > 0) || (chart.startMove && chart.crosshair.enable)) {\n return false;\n }\n this.calculateZoomAxesRange(chart);\n this.isZoomed = true;\n this.isPanning = true;\n this.performedUI = true;\n this.offset = !chart.delayRedraw ? chart.chartAxisLayoutPanel.seriesClipRect : this.offset;\n chart.delayRedraw = true;\n chart.disableTrackTooltip = true;\n var elementOffset = chart.element.getBoundingClientRect();\n var touchDown = this.touchStartList;\n var touchMove = this.touchMoveList;\n var touch0StartX = touchDown[0].pageX - elementOffset.left;\n var touch0StartY = touchDown[0].pageY - elementOffset.top;\n var touch0EndX = touchMove[0].pageX - elementOffset.left;\n var touch0EndY = touchMove[0].pageY - elementOffset.top;\n var touch1StartX = touchDown[1].pageX - elementOffset.left;\n var touch1StartY = touchDown[1].pageY - elementOffset.top;\n var touch1EndX = touchMove[1].pageX - elementOffset.left;\n var touch1EndY = touchMove[1].pageY - elementOffset.top;\n var scaleX = Math.abs(touch0EndX - touch1EndX) / Math.abs(touch0StartX - touch1StartX);\n var scaleY = Math.abs(touch0EndY - touch1EndY) / Math.abs(touch0StartY - touch1StartY);\n var clipX = ((this.offset.x - touch0EndX) / scaleX) + touch0StartX;\n var clipY = ((this.offset.y - touch0EndY) / scaleY) + touch0StartY;\n var pinchRect = new Rect(clipX, clipY, this.offset.width / scaleX, this.offset.height / scaleY);\n var translateXValue = (touch0EndX - (scaleX * touch0StartX));\n var translateYValue = (touch0EndY - (scaleY * touch0StartY));\n if (!isNaN(scaleX - scaleX) && !isNaN(scaleY - scaleY)) {\n switch (this.zooming.mode) {\n case 'XY':\n case 'X':\n this.setTransform(translateXValue, translateYValue, scaleX, scaleY, chart, true);\n break;\n case 'Y':\n this.setTransform(0, translateYValue, 1, scaleY, chart, true);\n break;\n }\n }\n if (!this.calculatePinchZoomFactor(chart, pinchRect)) {\n this.refreshAxis(chart.chartAxisLayoutPanel, chart, chart.axisCollections);\n this.redrawOnZooming(chart, false);\n }\n return true;\n };\n Zoom.prototype.calculatePinchZoomFactor = function (chart, pinchRect) {\n var mode = this.zooming.mode;\n var selectionMin;\n var selectionMax;\n var rangeMin;\n var rangeMax;\n var value;\n var axisTrans;\n var argsData;\n var currentZF;\n var currentZP;\n var zoomedAxisCollection = [];\n this.zoomCompleteEvtCollection = [];\n for (var index = 0; index < chart.axisCollections.length; index++) {\n var axis = chart.axisCollections[index];\n if ((axis.orientation === 'Horizontal' && mode !== 'Y') ||\n (axis.orientation === 'Vertical')) {\n currentZF = axis.zoomFactor;\n currentZP = axis.zoomPosition;\n argsData = {\n cancel: false, name: zoomComplete, axis: axis, previousZoomFactor: axis.zoomFactor,\n previousZoomPosition: axis.zoomPosition, currentZoomFactor: currentZF,\n currentZoomPosition: currentZP, previousVisibleRange: axis.visibleRange,\n currentVisibleRange: null\n };\n if (axis.orientation === 'Horizontal') {\n value = pinchRect.x - this.offset.x;\n axisTrans = axis.rect.width / this.zoomAxes[index].delta;\n rangeMin = value / axisTrans + this.zoomAxes[index].min;\n value = pinchRect.x + pinchRect.width - this.offset.x;\n rangeMax = value / axisTrans + this.zoomAxes[index].min;\n }\n else {\n value = pinchRect.y - this.offset.y;\n axisTrans = axis.rect.height / this.zoomAxes[index].delta;\n rangeMin = (value * -1 + axis.rect.height) / axisTrans + this.zoomAxes[index].min;\n value = pinchRect.y + pinchRect.height - this.offset.y;\n rangeMax = (value * -1 + axis.rect.height) / axisTrans + this.zoomAxes[index].min;\n }\n selectionMin = Math.min(rangeMin, rangeMax);\n selectionMax = Math.max(rangeMin, rangeMax);\n currentZP = (selectionMin - this.zoomAxes[index].actualMin) / this.zoomAxes[index].actualDelta;\n currentZF = (selectionMax - selectionMin) / this.zoomAxes[index].actualDelta;\n argsData.currentZoomPosition = currentZP < 0 ? 0 : currentZP;\n argsData.currentZoomFactor = currentZF > 1 ? 1 : (currentZF < 0.03) ? 0.03 : currentZF;\n if (!argsData.cancel) {\n axis.zoomFactor = argsData.currentZoomFactor;\n axis.zoomPosition = argsData.currentZoomPosition;\n this.zoomCompleteEvtCollection.push(argsData);\n }\n zoomedAxisCollection.push({\n zoomFactor: axis.zoomFactor, zoomPosition: axis.zoomFactor, axisName: axis.name,\n axisRange: axis.visibleRange\n });\n }\n }\n var onZoomingEventArgs = { cancel: false, axisCollection: zoomedAxisCollection, name: onZooming };\n if (!onZoomingEventArgs.cancel) {\n this.chart.trigger(onZooming, onZoomingEventArgs);\n if (onZoomingEventArgs.cancel) {\n this.zoomCancel(chart.axisCollections, this.zoomCompleteEvtCollection);\n return true;\n }\n }\n return false;\n };\n // Series transformation style applied here.\n Zoom.prototype.setTransform = function (transX, transY, scaleX, scaleY, chart, isPinch) {\n if (!chart.enableCanvas) {\n chart.seriesElements.setAttribute('clip-path', 'url(#' + this.elementId + '_ChartAreaClipRect_)');\n }\n if (chart.indicatorElements) {\n chart.indicatorElements.setAttribute('clip-path', 'url(#' + this.elementId + '_ChartAreaClipRect_)');\n }\n var translate;\n var xAxisLoc;\n var yAxisLoc;\n var element;\n if (transX !== null && transY !== null) {\n for (var _i = 0, _a = chart.visibleSeries; _i < _a.length; _i++) {\n var value = _a[_i];\n xAxisLoc = chart.requireInvertedAxis ? value.yAxis.rect.x : value.xAxis.rect.x;\n yAxisLoc = chart.requireInvertedAxis ? value.xAxis.rect.y : value.yAxis.rect.y;\n translate = 'translate(' + (transX + (isPinch ? (scaleX * xAxisLoc) : xAxisLoc)) +\n ',' + (transY + (isPinch ? (scaleY * yAxisLoc) : yAxisLoc)) + ')';\n translate = (scaleX || scaleY) ? translate + ' scale(' + scaleX + ' ' + scaleY + ')' : translate;\n if (value.visible) {\n if (value.category === 'Indicator') {\n value.seriesElement.parentNode.setAttribute('transform', translate);\n }\n else {\n if (!chart.enableCanvas) {\n value.seriesElement.setAttribute('transform', translate);\n }\n }\n element = getElement(chart.element.id + '_Series_' + value.index + '_DataLabelCollections');\n if (value.errorBarElement) {\n value.errorBarElement.setAttribute('transform', translate);\n }\n if (value.symbolElement) {\n value.symbolElement.setAttribute('transform', translate);\n }\n if (value.textElement) {\n value.textElement.setAttribute('visibility', 'hidden');\n value.shapeElement.setAttribute('visibility', 'hidden');\n }\n if (element) {\n element.style.visibility = 'hidden';\n }\n }\n }\n }\n };\n Zoom.prototype.calculateZoomAxesRange = function (chart) {\n var range;\n var axisRange;\n for (var index = 0; index < chart.axisCollections.length; index++) {\n var axis = chart.axisCollections[index];\n axisRange = axis.visibleRange;\n if (this.zoomAxes[index]) {\n if (!chart.delayRedraw) {\n this.zoomAxes[index].min = axisRange.min;\n this.zoomAxes[index].delta = axisRange.delta;\n }\n }\n else {\n range = {\n actualMin: axis.actualRange.min,\n actualDelta: axis.actualRange.delta,\n min: axisRange.min,\n delta: axisRange.delta\n };\n this.zoomAxes[index] = range;\n }\n }\n };\n // Zooming Toolkit created here\n Zoom.prototype.showZoomingToolkit = function (chart) {\n var toolboxItems = this.zooming.toolbarItems;\n var areaBounds = chart.chartAxisLayoutPanel.seriesClipRect;\n var spacing = 10;\n var render = chart.svgRenderer;\n var length = this.isDevice ? 1 : toolboxItems.length;\n var iconSize = this.isDevice ? measureText('Reset Zoom', { size: '12px' }, { size: '12px', fontStyle: 'Normal', fontWeight: '400', fontFamily: 'Segoe UI' }).width : 16;\n var height = this.isDevice ? measureText('Reset Zoom', { size: '12px' }, { size: '12px', fontStyle: 'Normal', fontWeight: '400', fontFamily: 'Segoe UI' }).height : 22;\n var width = (length * iconSize) + ((length + 1) * spacing) + ((length - 1) * spacing);\n var transX = areaBounds.x + areaBounds.width - width - spacing;\n var transY = (areaBounds.y + spacing);\n var xPosition = spacing;\n var toolkit = this.toolkit;\n var element;\n var shadowElement = '<filter id=\"chart_shadow\" height=\"130%\"><feGaussianBlur in=\"SourceAlpha\" stdDeviation=\"5\"/>';\n shadowElement += '<feOffset dx=\"-3\" dy=\"4\" result=\"offsetblur\"/><feComponentTransfer><feFuncA type=\"linear\" slope=\"1\"/>';\n shadowElement += '</feComponentTransfer><feMerge><feMergeNode/><feMergeNode in=\"SourceGraphic\"/></feMerge></filter>';\n if (length === 0 || getElement(this.elementId + '_Zooming_KitCollection')) {\n return false;\n }\n var defElement = render.createDefs();\n toolboxItems = this.isDevice ? ['Reset'] : toolboxItems;\n defElement.innerHTML = shadowElement;\n this.toolkitElements = render.createGroup({\n id: this.elementId + '_Zooming_KitCollection',\n transform: 'translate(' + transX + ',' + transY + ')'\n });\n this.toolkitElements.appendChild(defElement);\n var zoomFillColor = this.chart.theme === 'Tailwind' ? '#F3F4F6' : this.chart.theme === 'Fluent' ? '#F3F2F1' :\n (this.chart.theme === 'Material3' ? '#FFFFFF' : this.chart.theme === 'Material3Dark' ? '#1C1B1F' : '#fafafa');\n this.toolkitElements.appendChild(render.drawRectangle(new RectOption(this.elementId + '_Zooming_Rect', zoomFillColor, { color: 'transparent', width: 1 }, 1, new Rect(0, 0, width, (height + (spacing * 2))), 4, 4)));\n var outerElement = render.drawRectangle(new RectOption(this.elementId + '_Zooming_Rect', zoomFillColor, { color: 'transparent', width: 1 }, 0.1, new Rect(0, 0, width, (height + (spacing * 2))), 4, 4));\n if (this.chart.theme === 'Tailwind' || this.chart.theme === 'TailwindDark') {\n outerElement.setAttribute('box-shadow', '0px 1px 2px rgba(0, 0, 0, 0.06), 0px 1px 3px rgba(0, 0, 0, 0.1)');\n }\n else if (this.chart.theme === 'Material3' || this.chart.theme === 'Material3Dark') {\n outerElement.setAttribute('filter', 'drop-shadow(0px 1px 3px rgba(0, 0, 0, 0.15)) drop-shadow(0px 1px 2px rgba(0, 0, 0, 0.3))');\n outerElement.setAttribute('fill', this.chart.theme === 'Material3' ? '#FFFFFF' : '#1C1B1F');\n outerElement.setAttribute('rx', '4px');\n outerElement.setAttribute('ry', '4px');\n outerElement.setAttribute('opacity', '1');\n }\n else {\n outerElement.setAttribute('filter', 'url(#chart_shadow)');\n }\n this.toolkitElements.appendChild(outerElement);\n var currentItem;\n var panIcon = false;\n for (var i = 1; i <= length; i++) {\n currentItem = toolboxItems[i - 1];\n element = render.createGroup({\n transform: 'translate(' + xPosition + ',' + (this.isDevice ? spacing : (spacing + 3)) + ')'\n });\n // for desktop toolkit hight is 32 and top padding is 8 icon size 16\n switch (currentItem) {\n case 'Pan':\n toolkit.createPanButton(element, this.toolkitElements);\n panIcon = true;\n break;\n case 'Zoom':\n toolkit.createZoomButton(element, this.toolkitElements);\n break;\n case 'ZoomIn':\n toolkit.createZoomInButton(element, this.toolkitElements, chart);\n break;\n case 'ZoomOut':\n toolkit.createZoomOutButton(element, this.toolkitElements, chart);\n break;\n case 'Reset':\n toolkit.createResetButton(element, this.toolkitElements, chart, this.isDevice);\n break;\n }\n xPosition += iconSize + (spacing * 2);\n }\n this.toolkitElements.setAttribute('opacity', this.isDevice ? '1' : '' + this.zoomkitOpacity);\n this.toolkitElements.setAttribute('cursor', 'auto');\n if (chart.enableCanvas) {\n var zoomDiv = document.createElement('div');\n zoomDiv.id = chart.element.id + '_zoom';\n zoomDiv.style.cssText = 'position:absolute; z-index:1';\n var zoomheight = chart.availableSize.height / 2;\n var svg = chart.svgRenderer.createSvg({\n id: chart.element.id + '_zoomkit_svg',\n width: chart.availableSize.width,\n height: zoomheight\n });\n svg.style.position = 'absolute';\n svg.appendChild(this.toolkitElements);\n zoomDiv.appendChild(svg);\n document.getElementById(this.elementId + '_Secondary_Element').appendChild(zoomDiv);\n }\n else {\n chart.svgObject.appendChild(this.toolkitElements);\n }\n if (!this.isDevice) {\n EventHandler.add(this.toolkitElements, 'mousemove touchstart', this.zoomToolkitMove, this);\n EventHandler.add(this.toolkitElements, 'mouseleave touchend', this.zoomToolkitLeave, this);\n if (this.isPanning && panIcon) {\n toolkit.pan();\n }\n }\n return true;\n };\n /**\n * To the show the zooming toolkit.\n *\n * @returns {void}\n * @private\n */\n Zoom.prototype.applyZoomToolkit = function (chart, axes) {\n var showToolkit = this.isAxisZoomed(axes);\n if (showToolkit) {\n this.showZoomingToolkit(chart);\n this.isZoomed = true;\n }\n else if (chart.zoomSettings.showToolbar) {\n this.isZoomed = showToolkit;\n this.showZoomingToolkit(chart);\n }\n else {\n this.toolkit.removeTooltip();\n this.isPanning = false;\n this.isZoomed = false;\n chart.isZoomed = false;\n chart.svgObject.setAttribute('cursor', 'auto');\n }\n };\n /**\n * To cancel zoom event.\n *\n * @returns {void}\n * @public\n */\n Zoom.prototype.zoomCancel = function (axes, zoomCompleteEventCollection) {\n for (var _i = 0, _a = zoomCompleteEventCollection; _i < _a.length; _i++) {\n var zoomCompleteEvent = _a[_i];\n for (var _b = 0, _c = axes; _b < _c.length; _b++) {\n var axis = _c[_b];\n if (axis.name === zoomCompleteEvent.axis.name) {\n axis.zoomFactor = zoomCompleteEvent.previousZoomFactor;\n axis.zoomPosition = zoomCompleteEvent.previousZoomPosition;\n axis.visibleRange = zoomCompleteEvent.previousVisibleRange;\n break;\n }\n }\n }\n };\n /**\n * Return boolean property to show zooming toolkit.\n *\n * @returns {void}\n * @private\n */\n Zoom.prototype.isAxisZoomed = function (axes) {\n var showToolkit = false;\n for (var _i = 0, _a = axes; _i < _a.length; _i++) {\n var axis = _a[_i];\n showToolkit = (showToolkit || (axis.zoomFactor !== 1 || axis.zoomPosition !== 0));\n }\n return showToolkit;\n };\n Zoom.prototype.zoomToolkitMove = function () {\n var element = this.toolkitElements;\n this.zoomkitOpacity = 1;\n element.setAttribute('opacity', '' + this.zoomkitOpacity);\n return false;\n };\n Zoom.prototype.zoomToolkitLeave = function () {\n var element = this.toolkitElements;\n this.zoomkitOpacity = 1;\n element.setAttribute('opacity', '' + this.zoomkitOpacity);\n return false;\n };\n /**\n * @hidden\n */\n Zoom.prototype.addEventListener = function () {\n if (this.chart.isDestroyed) {\n return;\n }\n EventHandler.add(this.chart.element, this.wheelEvent, this.chartMouseWheel, this);\n this.chart.on(Browser.touchMoveEvent, this.mouseMoveHandler, this);\n this.chart.on(Browser.touchStartEvent, this.mouseDownHandler, this);\n this.chart.on(Browser.touchEndEvent, this.mouseUpHandler, this);\n this.chart.on(this.cancelEvent, this.mouseCancelHandler, this);\n };\n /**\n * @hidden\n */\n Zoom.prototype.removeEventListener = function () {\n if (this.chart.isDestroyed) {\n return;\n }\n EventHandler.remove(this.chart.element, this.wheelEvent, this.chartMouseWheel);\n this.chart.off(Browser.touchMoveEvent, this.mouseMoveHandler);\n this.chart.off(Browser.touchStartEvent, this.mouseDownHandler);\n this.chart.off(Browser.touchEndEvent, this.mouseUpHandler);\n this.chart.off(this.cancelEvent, this.mouseCancelHandler);\n };\n /**\n * Handles the mouse wheel on chart.\n *\n * @returns {boolean} false\n * @private\n */\n Zoom.prototype.chartMouseWheel = function (e) {\n var chart = this.chart;\n var offset = chart.element.getBoundingClientRect();\n var svgRect = getElement(chart.svgId).getBoundingClientRect();\n var mouseX = (e.clientX - offset.left) - Math.max(svgRect.left - offset.left, 0);\n var mouseY = (e.clientY - offset.top) - Math.max(svgRect.top - offset.top, 0);\n if (this.zooming.enableMouseWheelZooming &&\n withInBounds(mouseX, mouseY, chart.chartAxisLayoutPanel.seriesClipRect)) {\n e.preventDefault();\n this.performMouseWheelZooming(e, mouseX, mouseY, chart, chart.axisCollections);\n }\n return false;\n };\n /**\n * @hidden\n */\n Zoom.prototype.mouseMoveHandler = function (e) {\n //Zooming for chart\n var chart = this.chart;\n var touches = null;\n if (e.type === 'touchmove') {\n if (e.preventDefault && this.isIOS &&\n (this.isPanning || (chart.isDoubleTap)\n || (this.zooming.enablePinchZooming && this.touchStartList.length > 1))) {\n e.preventDefault();\n }\n touches = e.touches;\n }\n if (chart.isChartDrag) {\n if (chart.isTouch) {\n this.touchMoveList = this.addTouchPointer(this.touchMoveList, e, touches);\n if (this.zooming.enablePinchZooming && this.touchMoveList.length > 1\n && this.touchStartList.length > 1) {\n this.performPinchZooming(e, chart);\n }\n }\n this.renderZooming(e, chart, chart.isTouch);\n }\n };\n /**\n * @hidden\n */\n Zoom.prototype.mouseDownHandler = function (e) {\n //Zooming for chart\n var chart = this.chart;\n var touches = null;\n var target;\n if (e.type === 'touchstart') {\n touches = e.touches;\n target = e.target;\n }\n else {\n target = e.target;\n }\n if (target.id.indexOf(chart.element.id + '_Zooming_') === -1 &&\n (chart.zoomSettings.enablePinchZooming || chart.zoomSettings.enableSelectionZooming) &&\n withInBounds(chart.previousMouseMoveX, chart.previousMouseMoveY, chart.chartAxisLayoutPanel.seriesClipRect)) {\n chart.isChartDrag = true;\n }\n if (chart.isTouch) {\n this.touchStartList = this.addTouchPointer(this.touchStartList, e, touches);\n }\n };\n /**\n * @hidden\n */\n Zoom.prototype.mouseUpHandler = function (e) {\n var chart = this.chart;\n var performZoomRedraw = e.target.id.indexOf(chart.element.id + '_ZoomOut_') === -1 ||\n e.target.id.indexOf(chart.element.id + '_ZoomIn_') === -1;\n if (chart.isChartDrag || performZoomRedraw) {\n this.redrawOnZooming(chart, true, true);\n }\n if (chart.isTouch) {\n if (chart.isDoubleTap && withInBounds(chart.mouseX, chart.mouseY, chart.chartAxisLayoutPanel.seriesClipRect)\n && this.touchStartList.length === 1 && this.isZoomed) {\n this.toolkit.reset(e);\n }\n this.touchStartList = [];\n chart.isDoubleTap = false;\n }\n };\n /**\n * @hidden\n */\n Zoom.prototype.mouseCancelHandler = function () {\n if (this.isZoomed) {\n this.performZoomRedraw(this.chart);\n }\n this.pinchTarget = null;\n this.touchStartList = [];\n this.touchMoveList = [];\n };\n /**\n * Handles the touch pointer.\n *\n * @returns {ITouches[]} touchList collection\n * @private\n */\n Zoom.prototype.addTouchPointer = function (touchList, e, touches) {\n if (touches) {\n touchList = [];\n for (var i = 0, length_1 = touches.length; i < length_1; i++) {\n touchList.push({ pageX: touches[i].clientX, pageY: touches[i].clientY, pointerId: null });\n }\n }\n else {\n touchList = touchList ? touchList : [];\n if (touchList.length === 0) {\n touchList.push({ pageX: e.clientX, pageY: e.clientY, pointerId: e.pointerId });\n }\n else {\n for (var i = 0, length_2 = touchList.length; i < length_2; i++) {\n if (touchList[i].pointerId === e.pointerId) {\n touchList[i] = { pageX: e.clientX, pageY: e.clientY, pointerId: e.pointerId };\n }\n else {\n touchList.push({ pageX: e.clientX, pageY: e.clientY, pointerId: e.pointerId });\n }\n }\n }\n }\n return touchList;\n };\n /**\n * Get module name.\n */\n Zoom.prototype.getModuleName = function () {\n // Returns te module name\n return 'Zoom';\n };\n /**\n * To destroy the zooming.\n *\n * @returns {void}\n * @private\n */\n Zoom.prototype.destroy = function () {\n // Destroy method performed here\n this.removeEventListener();\n };\n return Zoom;\n}());\nexport { Zoom };\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var ButtonsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-buttons';\n }\n }\n});\nexport var ButtonsPlugin = {\n name: 'e-buttons',\n install: function (Vue) {\n Vue.component(ButtonsPlugin.name, ButtonsDirective);\n }\n};\n/**\n * 'e-button' directive represent a button of Vue Dialog\n * It must be contained in a Dialog component(`ejs-dialog`).\n * ```html\n * <ejs-Dialog id='dialog' :showCloseIcon=true>\n * <e-buttons>\n * <e-dialogbutton :buttonModal='okButton'></e-dialogbutton>\n * <e-dialogbutton :buttonModal='cancelButton'></e-dialogbutton>\n * </e-buttons>\n * </ejs-Dialog>\n * ```\n */\nexport var DialogButtonDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-dialogbutton';\n }\n }\n});\nexport var DialogButtonPlugin = {\n name: 'e-dialogbutton',\n install: function (Vue) {\n Vue.component(DialogButtonPlugin.name, DialogButtonDirective);\n }\n};\n","import { ComponentBase, gh, getProps, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined, getValue } from '@syncfusion/ej2-base';\nimport { isUndefined } from '@syncfusion/ej2-base';\nimport { Dialog } from '@syncfusion/ej2-popups';\nimport { ButtonsDirective, DialogButtonDirective, ButtonsPlugin, DialogButtonPlugin } from './buttons.directive';\nexport var properties = ['isLazyUpdate', 'plugins', 'allowDragging', 'animationSettings', 'buttons', 'closeOnEscape', 'content', 'cssClass', 'enableHtmlSanitizer', 'enablePersistence', 'enableResize', 'enableRtl', 'footerTemplate', 'header', 'height', 'isModal', 'locale', 'minHeight', 'position', 'resizeHandles', 'showCloseIcon', 'target', 'visible', 'width', 'zIndex', 'beforeClose', 'beforeOpen', 'beforeSanitizeHtml', 'close', 'created', 'destroyed', 'drag', 'dragStart', 'dragStop', 'open', 'overlayClick', 'resizeStart', 'resizeStop', 'resizing'];\nexport var modelProps = ['visible'];\nexport var testProp = getProps({ props: properties });\nexport var props = testProp[0], watch = testProp[1], emitProbs = Object.keys(watch);\nemitProbs.push('modelchanged', 'update:modelValue');\nfor (var _i = 0, modelProps_1 = modelProps; _i < modelProps_1.length; _i++) {\n var props_1 = modelProps_1[_i];\n emitProbs.push('update:' + props_1);\n}\n/**\n * Represents the VueJS Dialog component\n * ```html\n * <ejs-dialog></ejs-dialog>\n * ```\n */\nexport var DialogComponent = vueDefineComponent({\n name: 'DialogComponent',\n mixins: [ComponentBase],\n props: props,\n watch: watch,\n emits: emitProbs,\n model: { event: 'modelchanged' },\n provide: function () { return { custom: this.custom }; },\n data: function () {\n return {\n ej2Instances: new Dialog({}),\n propKeys: properties,\n models: modelProps,\n hasChildDirective: true,\n hasInjectedModules: false,\n tagMapper: { \"e-buttons\": \"e-dialogbutton\" },\n tagNameMapper: {},\n isVue3: !isExecute,\n templateCollection: {},\n };\n },\n created: function () {\n this.ej2Instances._trigger = this.ej2Instances.trigger;\n this.ej2Instances.trigger = this.trigger;\n this.bindProperties();\n this.ej2Instances._setProperties = this.ej2Instances.setProperties;\n this.ej2Instances.setProperties = this.setProperties;\n this.ej2Instances.clearTemplate = this.clearTemplate;\n this.updated = this.updated;\n },\n render: function (createElement) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', slots);\n },\n methods: {\n clearTemplate: function (templateNames) {\n if (!templateNames) {\n templateNames = Object.keys(this.templateCollection || {});\n }\n if (templateNames.length && this.templateCollection) {\n for (var _i = 0, templateNames_1 = templateNames; _i < templateNames_1.length; _i++) {\n var tempName = templateNames_1[_i];\n var elementCollection = this.templateCollection[tempName];\n if (elementCollection && elementCollection.length) {\n for (var _a = 0, elementCollection_1 = elementCollection; _a < elementCollection_1.length; _a++) {\n var ele = elementCollection_1[_a];\n var destroy = getValue('__vue__.$destroy', ele);\n if (destroy) {\n ele.__vue__.$destroy();\n }\n if (ele.innerHTML) {\n ele.innerHTML = '';\n }\n }\n delete this.templateCollection[tempName];\n }\n }\n }\n },\n setProperties: function (prop, muteOnChange) {\n var _this = this;\n if (this.isVue3) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if (this.ej2Instances && this.ej2Instances._setProperties) {\n this.ej2Instances._setProperties(prop, muteOnChange);\n }\n if (prop && this.models && this.models.length) {\n Object.keys(prop).map(function (key) {\n _this.models.map(function (model) {\n if ((key === model) && !(/datasource/i.test(key))) {\n if (_this.isVue3) {\n _this.ej2Instances.vueInstance.$emit('update:' + key, prop[key]);\n }\n else {\n _this.$emit('update:' + key, prop[key]);\n _this.$emit('modelchanged', prop[key]);\n }\n }\n });\n });\n }\n },\n trigger: function (eventName, eventProp, successHandler) {\n if (!isExecute) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if ((eventName === 'change' || eventName === 'input') && this.models && (this.models.length !== 0)) {\n var key = this.models.toString().match(/checked|value/) || [];\n var propKey = key[0];\n if (eventProp && key && !isUndefined(eventProp[propKey])) {\n if (!isExecute) {\n this.ej2Instances.vueInstance.$emit('update:' + propKey, eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('modelchanged', eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('update:modelValue', eventProp[propKey]);\n }\n else {\n if (eventName === 'change' || (this.$props && !this.$props.isLazyUpdate)) {\n this.$emit('update:' + propKey, eventProp[propKey]);\n this.$emit('modelchanged', eventProp[propKey]);\n }\n }\n }\n }\n else if ((eventName === 'actionBegin' && eventProp.requestType === 'dateNavigate') && this.models && (this.models.length !== 0)) {\n var key = this.models.toString().match(/currentView|selectedDate/) || [];\n var propKey = key[0];\n if (eventProp && key && !isUndefined(eventProp[propKey])) {\n if (!isExecute) {\n this.ej2Instances.vueInstance.$emit('update:' + propKey, eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('modelchanged', eventProp[propKey]);\n }\n else {\n this.$emit('update:' + propKey, eventProp[propKey]);\n this.$emit('modelchanged', eventProp[propKey]);\n }\n }\n }\n if ((this.ej2Instances && this.ej2Instances._trigger)) {\n this.ej2Instances._trigger(eventName, eventProp, successHandler);\n }\n },\n custom: function () {\n this.updated();\n },\n getButtons: function (index) {\n return this.ej2Instances.getButtons(index);\n },\n getDimension: function () {\n return this.ej2Instances.getDimension();\n },\n hide: function (event) {\n return this.ej2Instances.hide(event);\n },\n refreshPosition: function () {\n return this.ej2Instances.refreshPosition();\n },\n sanitizeHelper: function (value) {\n return this.ej2Instances.sanitizeHelper(value);\n },\n show: function (isFullScreen) {\n return this.ej2Instances.show(isFullScreen);\n },\n }\n});\nexport var DialogPlugin = {\n name: 'ejs-dialog',\n install: function (Vue) {\n Vue.component(DialogPlugin.name, DialogComponent);\n Vue.component(DialogButtonPlugin.name, DialogButtonDirective);\n Vue.component(ButtonsPlugin.name, ButtonsDirective);\n }\n};\n","//! moment.js locale configuration\n//! locale : Arabic (Kuwait) [ar-kw]\n//! author : Nusret Parlak: https://github.com/nusretparlak\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var arKw = moment.defineLocale('ar-kw', {\n months: 'يناير_Ùبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split(\n '_'\n ),\n monthsShort:\n 'يناير_Ùبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split(\n '_'\n ),\n weekdays: 'الأØد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),\n weekdaysShort: 'اØد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت'.split('_'),\n weekdaysMin: 'Ø_Ù†_Ø«_ر_Ø®_ج_س'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[اليوم على الساعة] LT',\n nextDay: '[غدا على الساعة] LT',\n nextWeek: 'dddd [على الساعة] LT',\n lastDay: '[أمس على الساعة] LT',\n lastWeek: 'dddd [على الساعة] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'ÙÙŠ %s',\n past: 'منذ %s',\n s: 'ثوان',\n ss: '%d ثانية',\n m: 'دقيقة',\n mm: '%d دقائق',\n h: 'ساعة',\n hh: '%d ساعات',\n d: 'يوم',\n dd: '%d أيام',\n M: 'شهر',\n MM: '%d أشهر',\n y: 'سنة',\n yy: '%d سنوات',\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return arKw;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/**\n * Worksheets class\n * @private\n */\nvar Worksheets = /** @class */ (function (_super) {\n __extends(Worksheets, _super);\n function Worksheets() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n return Worksheets;\n}(Array));\nexport { Worksheets };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/**\n * Worksheet class\n * @private\n */\nvar Worksheet = /** @class */ (function () {\n function Worksheet() {\n this.isSummaryRowBelow = true;\n this.showGridLines = true;\n this.enableRtl = false;\n }\n return Worksheet;\n}());\nexport { Worksheet };\n/**\n * Hyperlink class\n * @private\n */\nvar HyperLink = /** @class */ (function () {\n function HyperLink() {\n }\n return HyperLink;\n}());\nexport { HyperLink };\n/**\n * Grouping class\n * @private\n */\nvar Grouping = /** @class */ (function () {\n function Grouping() {\n }\n return Grouping;\n}());\nexport { Grouping };\n/**\n * FreezePane class\n * @private\n */\nvar FreezePane = /** @class */ (function () {\n function FreezePane() {\n }\n return FreezePane;\n}());\nexport { FreezePane };\n/**\n * MergeCell\n * @private\n */\nvar MergeCell = /** @class */ (function () {\n function MergeCell() {\n }\n return MergeCell;\n}());\nexport { MergeCell };\n/**\n * MergeCells class\n * @private\n */\nvar MergeCells = /** @class */ (function (_super) {\n __extends(MergeCells, _super);\n function MergeCells() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.add = function (mergeCell) {\n var inserted = false;\n var count = 0;\n for (var _i = 0, _a = _this; _i < _a.length; _i++) {\n var mCell = _a[_i];\n if (MergeCells.isIntersecting(mCell, mergeCell)) {\n var intersectingCell = new MergeCell();\n intersectingCell.x = Math.min(mCell.x, mergeCell.x);\n intersectingCell.y = Math.min(mCell.Y, mergeCell.y);\n intersectingCell.width = Math.max(mCell.Width + mCell.X, mergeCell.width + mergeCell.x);\n intersectingCell.height = Math.max(mCell.Height + mCell.Y, mergeCell.height + mergeCell.y);\n intersectingCell.ref = (_this[count].ref.split(':')[0]) + ':' + (mergeCell.ref.split(':')[1]);\n _this[count] = intersectingCell;\n mergeCell = intersectingCell;\n inserted = true;\n }\n count++;\n }\n if (!inserted) {\n _this.push(mergeCell);\n }\n return mergeCell;\n };\n return _this;\n }\n MergeCells.isIntersecting = function (base, compare) {\n return (base.x <= compare.x + compare.width)\n && (compare.x <= base.x + base.width)\n && (base.y <= compare.y + compare.height)\n && (compare.y <= base.y + base.height);\n };\n return MergeCells;\n}(Array));\nexport { MergeCells };\n","/**\n * CellStyle class\n * @private\n */\nvar CellStyle = /** @class */ (function () {\n function CellStyle() {\n this.numFmtId = 0;\n this.backColor = 'none';\n this.fontName = 'Calibri';\n this.fontSize = 10.5;\n this.fontColor = '#000000';\n this.italic = false;\n this.bold = false;\n this.underline = false;\n this.strikeThrough = false;\n this.wrapText = false;\n this.hAlign = 'general';\n this.vAlign = 'bottom';\n this.indent = 0;\n this.rotation = 0;\n this.numberFormat = 'GENERAL';\n this.type = 'datetime';\n this.borders = new Borders();\n this.isGlobalStyle = false;\n }\n return CellStyle;\n}());\nexport { CellStyle };\n/**\n * Font Class\n * @private\n */\nvar Font = /** @class */ (function () {\n function Font() {\n this.sz = 10.5;\n this.name = 'Calibri';\n this.u = false;\n this.b = false;\n this.i = false;\n this.color = 'FF000000';\n this.strike = false;\n }\n return Font;\n}());\nexport { Font };\n/**\n * CellXfs class\n * @private\n */\nvar CellXfs = /** @class */ (function () {\n function CellXfs() {\n }\n return CellXfs;\n}());\nexport { CellXfs };\n/**\n * Alignment class\n * @private\n */\nvar Alignment = /** @class */ (function () {\n function Alignment() {\n }\n return Alignment;\n}());\nexport { Alignment };\n/**\n * CellStyleXfs class\n * @private\n */\nvar CellStyleXfs = /** @class */ (function () {\n function CellStyleXfs() {\n }\n return CellStyleXfs;\n}());\nexport { CellStyleXfs };\n/**\n * CellStyles class\n * @private\n */\nvar CellStyles = /** @class */ (function () {\n function CellStyles() {\n this.name = 'Normal';\n this.xfId = 0;\n }\n return CellStyles;\n}());\nexport { CellStyles };\n/**\n * NumFmt class\n * @private\n */\nvar NumFmt = /** @class */ (function () {\n function NumFmt(id, code) {\n this.numFmtId = id;\n this.formatCode = code;\n }\n return NumFmt;\n}());\nexport { NumFmt };\n/**\n * Border class\n * @private\n */\nvar Border = /** @class */ (function () {\n function Border(mLine, mColor) {\n this.lineStyle = mLine;\n this.color = mColor;\n }\n return Border;\n}());\nexport { Border };\n/**\n * Borders class\n * @private\n */\nvar Borders = /** @class */ (function () {\n function Borders() {\n this.left = new Border('none', '#FFFFFF');\n this.right = new Border('none', '#FFFFFF');\n this.top = new Border('none', '#FFFFFF');\n this.bottom = new Border('none', '#FFFFFF');\n this.all = new Border('none', '#FFFFFF');\n }\n return Borders;\n}());\nexport { Borders };\n","/**\n * Column class\n * @private\n */\nvar Column = /** @class */ (function () {\n function Column() {\n }\n return Column;\n}());\nexport { Column };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/**\n * Row class\n * @private\n */\nvar Row = /** @class */ (function () {\n function Row() {\n }\n return Row;\n}());\nexport { Row };\n/**\n * Rows class\n * @private\n */\nvar Rows = /** @class */ (function (_super) {\n __extends(Rows, _super);\n function Rows() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.add = function (row) {\n _this.push(row);\n };\n return _this;\n }\n return Rows;\n}(Array));\nexport { Rows };\n","/**\n * Image class\n * @private\n */\nvar Image = /** @class */ (function () {\n function Image() {\n }\n return Image;\n}());\nexport { Image };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/**\n * Worksheet class\n * @private\n */\nvar Cell = /** @class */ (function () {\n function Cell() {\n }\n return Cell;\n}());\nexport { Cell };\n/**\n * Cells class\n * @private\n */\nvar Cells = /** @class */ (function (_super) {\n __extends(Cells, _super);\n function Cells() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.add = function (cell) {\n var inserted = false;\n var count = 0;\n for (var _i = 0, _a = _this; _i < _a.length; _i++) {\n var c = _a[_i];\n if (c.index === cell.index) {\n _this[count] = cell;\n inserted = true;\n }\n count++;\n }\n if (!inserted) {\n _this.push(cell);\n }\n };\n return _this;\n }\n return Cells;\n}(Array));\nexport { Cells };\n","/* eslint-disable */\nvar Utils = /** @class */ (function () {\n function Utils() {\n }\n Utils.bitReverse = function (value) {\n return (Utils.reverseBits[value & 15] << 12\n | Utils.reverseBits[(value >> 4) & 15] << 8\n | Utils.reverseBits[(value >> 8) & 15] << 4\n | Utils.reverseBits[value >> 12]);\n };\n Utils.bitConverterToInt32 = function (value, index) {\n return value[index] | value[index + 1] << 8 | value[index + 2] << 16 | value[index + 3] << 24;\n };\n Utils.bitConverterToInt16 = function (value, index) {\n return value[index] | value[index + 1] << 8;\n };\n Utils.bitConverterToUInt32 = function (value) {\n var uint = new Uint32Array(1);\n uint[0] = value;\n return uint[0];\n };\n Utils.bitConverterToUInt16 = function (value, index) {\n var uint = new Uint16Array(1);\n uint[0] = (value[index] | value[index + 1] << 8);\n return uint[0];\n };\n Utils.bitConverterUintToInt32 = function (value) {\n var uint = new Int32Array(1);\n uint[0] = value;\n return uint[0];\n };\n Utils.bitConverterInt32ToUint = function (value) {\n var uint = new Uint32Array(1);\n uint[0] = value;\n return uint[0];\n };\n Utils.bitConverterInt32ToInt16 = function (value) {\n var uint = new Int16Array(1);\n uint[0] = value;\n return uint[0];\n };\n Utils.byteToString = function (value) {\n var str = '';\n for (var i = 0; i < value.length; i++) {\n str += String.fromCharCode(value[i]);\n }\n return str;\n };\n Utils.byteIntToString = function (value) {\n var str = '';\n for (var i = 0; i < value.length; i++) {\n str += String.fromCharCode(value[i]);\n }\n return str;\n };\n Utils.arrayCopy = function (source, sourceIndex, destination, destinationIndex, dataToCopy) {\n var temp = new Uint8Array(source.buffer, sourceIndex);\n var data = temp.subarray(0, dataToCopy);\n destination.set(data, destinationIndex);\n };\n Utils.mergeArray = function (arrayOne, arrayTwo) {\n var mergedArray = new Uint8Array(arrayOne.length + arrayTwo.length);\n mergedArray.set(arrayOne);\n mergedArray.set(arrayTwo, arrayOne.length);\n return mergedArray;\n };\n /**\n * @private\n */\n Utils.encodedString = function (input) {\n var keyStr = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\n var chr1;\n var chr2;\n var chr3;\n var encode1;\n var encode2;\n var encode3;\n var encode4;\n var count = 0;\n var resultIndex = 0;\n /*let dataUrlPrefix: string = 'data:';*/\n input = input.replace(/[^A-Za-z0-9\\+\\/\\=]/g, '');\n var totalLength = input.length * 3 / 4;\n if (input.charAt(input.length - 1) === keyStr.charAt(64)) {\n totalLength--;\n }\n if (input.charAt(input.length - 2) === keyStr.charAt(64)) {\n totalLength--;\n }\n if (totalLength % 1 !== 0) {\n // totalLength is not an integer, the length does not match a valid\n // base64 content. That can happen if:\n // - the input is not a base64 content\n // - the input is *almost* a base64 content, with a extra chars at the\n // beginning or at the end\n // - the input uses a base64 variant (base64url for example)\n throw new Error('Invalid base64 input, bad content length.');\n }\n var output = new Uint8Array(totalLength | 0);\n while (count < input.length) {\n encode1 = keyStr.indexOf(input.charAt(count++));\n encode2 = keyStr.indexOf(input.charAt(count++));\n encode3 = keyStr.indexOf(input.charAt(count++));\n encode4 = keyStr.indexOf(input.charAt(count++));\n chr1 = (encode1 << 2) | (encode2 >> 4);\n chr2 = ((encode2 & 15) << 4) | (encode3 >> 2);\n chr3 = ((encode3 & 3) << 6) | encode4;\n output[resultIndex++] = chr1;\n if (encode3 !== 64) {\n output[resultIndex++] = chr2;\n }\n if (encode4 !== 64) {\n output[resultIndex++] = chr3;\n }\n }\n return output;\n };\n Utils.reverseBits = [0, 8, 4, 12, 2, 10, 6, 14, 1, 9, 5, 13, 3, 11, 7, 15];\n Utils.huffCodeLengthOrders = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];\n return Utils;\n}());\nexport { Utils };\n/* eslint-enable */ \n","/* eslint-disable */\nimport { Utils } from './index';\nvar DecompressorHuffmanTree = /** @class */ (function () {\n function DecompressorHuffmanTree(lengths) {\n this.buildTree(lengths);\n }\n DecompressorHuffmanTree.init = function () {\n var lengths;\n var index;\n // Generate huffman tree for lengths.\n lengths = new Uint8Array(288);\n index = 0;\n while (index < 144) {\n lengths[index++] = 8;\n }\n while (index < 256) {\n lengths[index++] = 9;\n }\n while (index < 280) {\n lengths[index++] = 7;\n }\n while (index < 288) {\n lengths[index++] = 8;\n }\n DecompressorHuffmanTree.m_LengthTree = new DecompressorHuffmanTree(lengths);\n // Generate huffman tree for distances.\n lengths = new Uint8Array(32);\n index = 0;\n while (index < 32) {\n lengths[index++] = 5;\n }\n DecompressorHuffmanTree.m_DistanceTree = new DecompressorHuffmanTree(lengths);\n };\n /// <summary>\n /// Prepares data for generating huffman tree.\n /// </summary>\n /// <param name=\"blCount\">Array of counts of each code length.</param>\n /// <param name=\"nextCode\">Numerical values of the smallest code for each code length.</param>\n /// <param name=\"lengths\">Array of code lengths.</param>\n /// <param name=\"treeSize\">Calculated tree size.</param>\n /// <returns>Code.</returns>\n DecompressorHuffmanTree.prototype.prepareData = function (blCount, nextCode, lengths) {\n var code = 0;\n var treeSize = 512;\n // Count number of codes for each code length.\n for (var i = 0; i < lengths.length; i++) {\n var length_1 = lengths[i];\n if (length_1 > 0) {\n blCount[length_1]++;\n }\n }\n for (var bits = 1; bits <= DecompressorHuffmanTree.MAX_BITLEN; bits++) {\n nextCode[bits] = code;\n code += blCount[bits] << (16 - bits);\n if (bits >= 10) {\n var start = nextCode[bits] & 0x1ff80;\n var end = code & 0x1ff80;\n treeSize += (end - start) >> (16 - bits);\n }\n }\n /* if( code != 65536 )\n throw new ZipException( \"Code lengths don't add up properly.\" );*/\n return { 'code': code, 'treeSize': treeSize };\n };\n /// <summary>\n /// Generates huffman tree.\n /// </summary>\n /// <param name=\"blCount\">Array of counts of each code length.</param>\n /// <param name=\"nextCode\">Numerical values of the smallest code for each code length.</param>\n /// <param name=\"code\">Precalculated code.</param>\n /// <param name=\"lengths\">Array of code lengths.</param>\n /// <param name=\"treeSize\">Calculated size of the tree.</param>\n /// <returns>Generated tree.</returns>\n DecompressorHuffmanTree.prototype.treeFromData = function (blCount, nextCode, lengths, code, treeSize) {\n var tree = new Int16Array(treeSize);\n var pointer = 512;\n var increment = 1 << 7;\n for (var bits = DecompressorHuffmanTree.MAX_BITLEN; bits >= 10; bits--) {\n var end = code & 0x1ff80;\n code -= blCount[bits] << (16 - bits);\n var start = code & 0x1ff80;\n for (var i = start; i < end; i += increment) {\n tree[Utils.bitReverse(i)] = Utils.bitConverterInt32ToInt16((-pointer << 4) | bits);\n pointer += 1 << (bits - 9);\n }\n }\n for (var i = 0; i < lengths.length; i++) {\n var bits = lengths[i];\n if (bits == 0) {\n continue;\n }\n code = nextCode[bits];\n var revcode = Utils.bitReverse(code);\n if (bits <= 9) {\n do {\n tree[revcode] = Utils.bitConverterInt32ToInt16((i << 4) | bits);\n revcode += 1 << bits;\n } while (revcode < 512);\n }\n else {\n var subTree = tree[revcode & 511];\n var treeLen = 1 << (subTree & 15);\n subTree = -(subTree >> 4);\n do {\n tree[subTree | (revcode >> 9)] = Utils.bitConverterInt32ToInt16((i << 4) | bits);\n revcode += 1 << bits;\n } while (revcode < treeLen);\n }\n nextCode[bits] = code + (1 << (16 - bits));\n }\n return tree;\n };\n /// <summary>\n /// Builds huffman tree from array of code lengths.\n /// </summary>\n /// <param name=\"lengths\">Array of code lengths.</param>\n DecompressorHuffmanTree.prototype.buildTree = function (lengths) {\n // Count of codes for each code length.\n var blCount = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];\n // Numerical value of the smallest code for each code length.\n var nextCode = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];\n var prepareData = this.prepareData(blCount, nextCode, lengths);\n this.m_Tree = this.treeFromData(blCount, nextCode, lengths, prepareData.code, prepareData.treeSize);\n };\n /// <summary>\n /// Reads and decompresses one symbol.\n /// </summary>\n /// <param name=\"input\"></param>\n /// <returns></returns>\n DecompressorHuffmanTree.prototype.unpackSymbol = function (input) {\n var lookahead;\n var symbol;\n if ((lookahead = input.peekBits(9)) >= 0) {\n if ((symbol = this.m_Tree[lookahead]) >= 0) {\n input.skipBits((symbol & 15));\n return symbol >> 4;\n }\n var subtree = -(symbol >> 4);\n var bitlen = symbol & 15;\n if ((lookahead = input.peekBits(bitlen)) >= 0) {\n symbol = this.m_Tree[subtree | (lookahead >> 9)];\n input.skipBits((symbol & 15));\n return symbol >> 4;\n }\n else {\n var bits = input.availableBits;\n lookahead = input.peekBits(bits);\n symbol = this.m_Tree[subtree | (lookahead >> 9)];\n if ((symbol & 15) <= bits) {\n input.skipBits((symbol & 15));\n return symbol >> 4;\n }\n else {\n return -1;\n }\n }\n }\n else {\n var bits = input.availableBits;\n lookahead = input.peekBits(bits);\n symbol = this.m_Tree[lookahead];\n if (symbol >= 0 && (symbol & 15) <= bits) {\n input.skipBits((symbol & 15));\n return symbol >> 4;\n }\n else {\n return -1;\n }\n }\n };\n Object.defineProperty(DecompressorHuffmanTree, \"lengthTree\", {\n /// <summary>\n /// GET huffman tree for encoding and decoding lengths.\n /// </summary>\n get: function () {\n return this.m_LengthTree;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(DecompressorHuffmanTree, \"distanceTree\", {\n /// <summary>\n /// GET huffman tree for encoding and decoding distances.\n /// </summary>\n get: function () {\n return this.m_DistanceTree;\n },\n enumerable: true,\n configurable: true\n });\n /// <summary>\n /// Maximum count of bits.\n /// </summary>\n DecompressorHuffmanTree.MAX_BITLEN = 15;\n return DecompressorHuffmanTree;\n}());\nexport { DecompressorHuffmanTree };\n/* eslint-enable */ \n","/* eslint-disable */\n/// <summary>\n/// Checksum calculator, based on Adler32 algorithm.\n/// </summary>\nvar ChecksumCalculator = /** @class */ (function () {\n function ChecksumCalculator() {\n }\n /// <summary>\n /// Updates checksum by calculating checksum of the\n /// given buffer and adding it to current value.\n /// </summary>\n /// <param name=\"checksum\">Current checksum.</param>\n /// <param name=\"buffer\">Data byte array.</param>\n /// <param name=\"offset\">Offset in the buffer.</param>\n /// <param name=\"length\">Length of data to be used from the stream.</param>\n ChecksumCalculator.ChecksumUpdate = function (checksum, buffer, offset, length) {\n var checkSumUInt = checksum;\n var s1 = checkSumUInt & 65535;\n var s2 = checkSumUInt >> this.DEF_CHECKSUM_BIT_OFFSET;\n while (length > 0) {\n var steps = Math.min(length, this.DEF_CHECKSUM_ITERATIONSCOUNT);\n length -= steps;\n while (--steps >= 0) {\n s1 = s1 + (buffer[offset++] & 255);\n s2 = s2 + s1;\n }\n s1 %= this.DEF_CHECKSUM_BASE;\n s2 %= this.DEF_CHECKSUM_BASE;\n }\n checkSumUInt = (s2 << this.DEF_CHECKSUM_BIT_OFFSET) | s1;\n checksum = checkSumUInt;\n };\n /// <summary>\n /// Generates checksum by calculating checksum of the\n /// given buffer.\n /// </summary>\n /// <param name=\"buffer\">Data byte array.</param>\n /// <param name=\"offset\">Offset in the buffer.</param>\n /// <param name=\"length\">Length of data to be used from the stream.</param>\n ChecksumCalculator.ChecksumGenerate = function (buffer, offset, length) {\n var result = 1;\n ChecksumCalculator.ChecksumUpdate(result, buffer, offset, length);\n return result;\n };\n /// <summary>\n /// Bits offset, used in adler checksum calculation.\n /// </summary>\n ChecksumCalculator.DEF_CHECKSUM_BIT_OFFSET = 16;\n /// <summary>\n /// Lagrest prime, less than 65535\n /// </summary>\n ChecksumCalculator.DEF_CHECKSUM_BASE = 65521;\n /// <summary>\n /// Count of iteration used in calculated of the adler checksumm.\n /// </summary>\n ChecksumCalculator.DEF_CHECKSUM_ITERATIONSCOUNT = 3800;\n return ChecksumCalculator;\n}());\nexport { ChecksumCalculator };\n/* eslint-enable */ \n","/* eslint-disable */\nimport { DecompressorHuffmanTree } from './decompressor-huffman-tree';\nimport { Utils } from './utils';\nimport { ChecksumCalculator } from './checksum-calculator';\nvar CompressedStreamReader = /** @class */ (function () {\n function CompressedStreamReader(stream, bNoWrap) {\n /// <summary>\n /// Code lengths for the code length alphabet.\n /// </summary>\n this.defaultHuffmanDynamicTree = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];\n /// <summary>\n /// Mask for compression method to be decoded from 16-bit header.\n /// </summary>\n this.DEF_HEADER_METHOD_MASK = 15 << 8;\n /// <summary>\n /// Mask for compression info to be decoded from 16-bit header.\n /// </summary>\n this.DEF_HEADER_INFO_MASK = 240 << 8;\n /// <summary>\n /// Mask for check bits to be decoded from 16-bit header.\n /// </summary>\n this.DEF_HEADER_FLAGS_FCHECK = 31;\n /// <summary>\n /// Mask for dictionary presence to be decoded from 16-bit header.\n /// </summary>\n this.DEF_HEADER_FLAGS_FDICT = 32;\n /// <summary>\n /// Mask for compression level to be decoded from 16-bit header.\n /// </summary>\n this.DEF_HEADER_FLAGS_FLEVEL = 192;\n /// <summary>\n /// Maximum size of the data window.\n /// </summary>\n this.DEF_MAX_WINDOW_SIZE = 65535;\n /// <summary>\n /// Maximum length of the repeatable block.\n /// </summary>\n this.DEF_HUFFMAN_REPEATE_MAX = 258;\n /// <summary>\n /// End of the block sign.\n /// </summary>\n this.DEF_HUFFMAN_END_BLOCK = 256;\n /// <summary>\n /// Minimal length code.\n /// </summary>\n this.DEF_HUFFMAN_LENGTH_MINIMUMCODE = 257;\n /// <summary>\n /// Maximal length code.\n /// </summary>\n this.DEF_HUFFMAN_LENGTH_MAXIMUMCODE = 285;\n /// <summary>\n /// Maximal distance code.\n /// </summary>\n this.DEF_HUFFMAN_DISTANCE_MAXIMUMCODE = 29;\n /// <summary>\n /// Currently calculated checksum,\n /// based on Adler32 algorithm.\n /// </summary>\n this.mCheckSum = 1;\n /// <summary>\n /// Currently read 4 bytes.\n /// </summary>\n this.tBuffer = 0;\n /// <summary>\n /// Count of bits that are in buffer.\n /// </summary>\n this.mBufferedBits = 0;\n /// <summary>\n /// Temporary buffer.\n /// </summary>\n this.mTempBuffer = new Uint8Array(4);\n /// <summary>\n /// 32k buffer for unpacked data.\n /// </summary>\n this.mBlockBuffer = new Uint8Array(this.DEF_MAX_WINDOW_SIZE);\n /// <summary>\n /// No wrap mode.\n /// </summary>\n this.mbNoWrap = false;\n /// <summary>\n /// Window size, can not be larger than 32k.\n /// </summary>\n this.mWindowSize = 0;\n /// <summary>\n /// Current position in output stream.\n /// Current in-block position can be extracted by applying Int16.MaxValue mask.\n /// </summary>\n this.mCurrentPosition = 0;\n /// <summary>\n /// Data length.\n /// Current in-block position can be extracted by applying Int16.MaxValue mask.\n /// </summary>\n this.mDataLength = 0;\n /// <summary>\n /// Specifies wheather next block can to be read.\n /// Reading can be denied because the header of the last block have been read.\n /// </summary>\n this.mbCanReadNextBlock = true;\n /// <summary>\n /// Specifies wheather user can read more data from stream.\n /// </summary>\n this.mbCanReadMoreData = true;\n /// <summary>\n /// Specifies wheather checksum has been read.\n /// </summary>\n this.mbCheckSumRead = false;\n if (stream == null) {\n throw new DOMException('stream');\n }\n if (stream.length === 0) {\n throw new DOMException('stream - string can not be empty');\n }\n DecompressorHuffmanTree.init();\n this.mInputStream = new Stream(stream);\n this.mbNoWrap = bNoWrap;\n if (!this.mbNoWrap) {\n this.readZLibHeader();\n }\n this.decodeBlockHeader();\n }\n Object.defineProperty(CompressedStreamReader.prototype, \"mBuffer\", {\n get: function () {\n return this.tBuffer;\n },\n set: function (value) {\n this.tBuffer = value;\n },\n enumerable: true,\n configurable: true\n });\n /**\n * Initializes compressor and writes ZLib header if needed.\n * @param {boolean} noWrap - optional if true, ZLib header and checksum will not be written.\n */\n /// <summary>\n /// Reads specified count of bits without adjusting position.\n /// </summary>\n /// <param name=\"count\">Count of bits to be read.</param>\n /// <returns>Read value.</returns>\n CompressedStreamReader.prototype.peekBits = function (count) {\n if (count < 0) {\n throw new DOMException('count', 'Bits count can not be less than zero.');\n }\n if (count > 32) {\n throw new DOMException('count', 'Count of bits is too large.');\n }\n // If buffered data is not enough to give result,\n // fill buffer.\n if (this.mBufferedBits < count) {\n this.fillBuffer();\n }\n // If you want to read 4 bytes and there is partial data in\n // buffer, than you will fail.\n if (this.mBufferedBits < count) {\n return -1;\n }\n // Create bitmask for reading of count bits\n var bitMask = ~(4294967295 << count);\n var result = Utils.bitConverterUintToInt32(this.mBuffer & bitMask);\n //Debug.WriteLine( /*new string( ' ', 32 - mBufferedBits + (int)( ( 32 - mBufferedBits ) / 8 ) ) + BitsToString( (int)mBuffer, mBufferedBits ) + \" \" + BitsToString( result, count ) +*/ \" \" + result.ToString() );\n return result;\n };\n CompressedStreamReader.prototype.fillBuffer = function () {\n var length = 4 - (this.mBufferedBits >> 3) -\n (((this.mBufferedBits & 7) !== 0) ? 1 : 0);\n if (length === 0) {\n return;\n }\n //TODO: fix this\n var bytesRead = this.mInputStream.read(this.mTempBuffer, 0, length);\n for (var i = 0; i < bytesRead; i++) {\n this.mBuffer = Utils.bitConverterInt32ToUint(this.mBuffer |\n (Utils.bitConverterInt32ToUint(this.mTempBuffer[i] << this.mBufferedBits)));\n this.mBufferedBits += 8;\n }\n //TODO: fix this\n };\n /// <summary>\n /// Skips specified count of bits.\n /// </summary>\n /// <param name=\"count\">Count of bits to be skipped.</param>\n CompressedStreamReader.prototype.skipBits = function (count) {\n if (count < 0) {\n throw new DOMException('count', 'Bits count can not be less than zero.');\n }\n if (count === 0) {\n return;\n }\n if (count >= this.mBufferedBits) {\n count -= this.mBufferedBits;\n this.mBufferedBits = 0;\n this.mBuffer = 0;\n // if something left, skip it.\n if (count > 0) {\n // Skip entire bytes.\n this.mInputStream.position += (count >> 3); //TODO: fix this\n count &= 7;\n // Skip bits.\n if (count > 0) {\n this.fillBuffer();\n this.mBufferedBits -= count;\n this.mBuffer = Utils.bitConverterInt32ToUint(this.mBuffer >>> count);\n }\n }\n }\n else {\n this.mBufferedBits -= count;\n this.mBuffer = Utils.bitConverterInt32ToUint(this.mBuffer >>> count);\n }\n };\n Object.defineProperty(CompressedStreamReader.prototype, \"availableBits\", {\n get: function () {\n return this.mBufferedBits;\n },\n enumerable: true,\n configurable: true\n });\n /// <summary>\n /// Reads ZLib header with compression method and flags.\n /// </summary>\n CompressedStreamReader.prototype.readZLibHeader = function () {\n // first 8 bits - compression Method and flags\n // 8 other - flags\n var header = this.readInt16();\n //Debug.WriteLine( BitsToString( header ) );\n if (header === -1) {\n throw new DOMException('Header of the stream can not be read.');\n }\n if (header % 31 !== 0) {\n throw new DOMException('Header checksum illegal');\n }\n if ((header & this.DEF_HEADER_METHOD_MASK) !== (8 << 8)) {\n throw new DOMException('Unsupported compression method.');\n }\n this.mWindowSize = Math.pow(2, ((header & this.DEF_HEADER_INFO_MASK) >> 12) + 8);\n if (this.mWindowSize > 65535) {\n throw new DOMException('Unsupported window size for deflate compression method.');\n }\n if ((header & this.DEF_HEADER_FLAGS_FDICT) >> 5 === 1) {\n // Get dictionary.\n throw new DOMException('Custom dictionary is not supported at the moment.');\n }\n };\n /// <summary>\n /// TODO: place correct comment here\n /// </summary>\n /// <returns>\n /// TODO: place correct comment here\n /// </returns>\n CompressedStreamReader.prototype.readInt16 = function () {\n var result = (this.readBits(8) << 8);\n result |= this.readBits(8);\n return result;\n };\n /// <summary>\n /// Reads specified count of bits from stream.\n /// </summary>\n /// <param name=\"count\">Count of bits to be read.</param>\n /// <returns>\n /// TODO: place correct comment here\n /// </returns>\n CompressedStreamReader.prototype.readBits = function (count) {\n var result = this.peekBits(count);\n if (result === -1) {\n return -1;\n }\n this.mBufferedBits -= count;\n this.mBuffer = Utils.bitConverterInt32ToUint(this.mBuffer >>> count);\n return result;\n };\n /// <summary>\n /// Reads and decodes block of data.\n /// </summary>\n /// <returns>True if buffer was empty and new data was read, otherwise - False.</returns>\n CompressedStreamReader.prototype.decodeBlockHeader = function () {\n if (!this.mbCanReadNextBlock) {\n return false;\n }\n var bFinalBlock = this.readBits(1);\n if (bFinalBlock === -1) {\n return false;\n }\n var blockType = this.readBits(2);\n if (blockType === -1) {\n return false;\n }\n this.mbCanReadNextBlock = (bFinalBlock === 0);\n // ChecksumReset();\n switch (blockType) {\n case 0:\n // Uncompressed data\n this.mbReadingUncompressed = true;\n this.skipToBoundary();\n var length_1 = this.readInt16Inverted();\n var lengthComplement = this.readInt16Inverted();\n if (length_1 !== (lengthComplement ^ 0xffff)) {\n throw new DOMException('Wrong block length.');\n }\n if (length_1 > 65535) {\n throw new DOMException('Uncompressed block length can not be more than 65535.');\n }\n this.mUncompressedDataLength = length_1;\n this.mCurrentLengthTree = null;\n this.mCurrentDistanceTree = null;\n break;\n case 1:\n // Compressed data with fixed huffman codes.\n this.mbReadingUncompressed = false;\n this.mUncompressedDataLength = -1;\n this.mCurrentLengthTree = DecompressorHuffmanTree.lengthTree;\n this.mCurrentDistanceTree = DecompressorHuffmanTree.distanceTree;\n break;\n case 2:\n // Compressed data with dynamic huffman codes.\n this.mbReadingUncompressed = false;\n this.mUncompressedDataLength = -1;\n var trees = this.decodeDynamicHeader(this.mCurrentLengthTree, this.mCurrentDistanceTree);\n this.mCurrentLengthTree = trees.lengthTree;\n this.mCurrentDistanceTree = trees.distanceTree;\n break;\n default:\n throw new DOMException('Wrong block type.');\n }\n return true;\n };\n /// <summary>\n /// Discards left-most partially used byte.\n /// </summary>\n CompressedStreamReader.prototype.skipToBoundary = function () {\n this.mBuffer = Utils.bitConverterInt32ToUint(this.mBuffer >>> (this.mBufferedBits & 7));\n this.mBufferedBits &= ~7;\n };\n /// <summary>\n /// TODO: place correct comment here\n /// </summary>\n /// <returns>\n /// TODO: place correct comment here\n /// </returns>\n CompressedStreamReader.prototype.readInt16Inverted = function () {\n var result = (this.readBits(8));\n result |= this.readBits(8) << 8;\n return result;\n };\n /// <summary>\n /// Reades dynamic huffman codes from block header.\n /// </summary>\n /// <param name=\"lengthTree\">Literals/Lengths tree.</param>\n /// <param name=\"distanceTree\">Distances tree.</param>\n CompressedStreamReader.prototype.decodeDynamicHeader = function (lengthTree, distanceTree) {\n var bLastSymbol = 0;\n var iLengthsCount = this.readBits(5);\n var iDistancesCount = this.readBits(5);\n var iCodeLengthsCount = this.readBits(4);\n if (iLengthsCount < 0 || iDistancesCount < 0 || iCodeLengthsCount < 0) {\n throw new DOMException('Wrong dynamic huffman codes.');\n }\n iLengthsCount += 257;\n iDistancesCount += 1;\n var iResultingCodeLengthsCount = iLengthsCount + iDistancesCount;\n var arrResultingCodeLengths = new Uint8Array(iResultingCodeLengthsCount);\n var arrDecoderCodeLengths = new Uint8Array(19);\n iCodeLengthsCount += 4;\n var iCurrentCode = 0;\n while (iCurrentCode < iCodeLengthsCount) {\n var len = this.readBits(3);\n if (len < 0) {\n throw new DOMException('Wrong dynamic huffman codes.');\n }\n arrDecoderCodeLengths[this.defaultHuffmanDynamicTree[iCurrentCode++]] = len;\n }\n var treeInternalDecoder = new DecompressorHuffmanTree(arrDecoderCodeLengths);\n iCurrentCode = 0;\n for (;;) {\n var symbol = void 0;\n var bNeedBreak = false;\n symbol = treeInternalDecoder.unpackSymbol(this);\n while ((symbol & ~15) === 0) {\n arrResultingCodeLengths[iCurrentCode++] = bLastSymbol = symbol;\n if (iCurrentCode === iResultingCodeLengthsCount) {\n bNeedBreak = true;\n break;\n }\n symbol = treeInternalDecoder.unpackSymbol(this);\n }\n if (bNeedBreak) {\n break;\n }\n if (symbol < 0) {\n throw new DOMException('Wrong dynamic huffman codes.');\n }\n if (symbol >= 17) {\n bLastSymbol = 0;\n }\n else if (iCurrentCode === 0) {\n throw new DOMException('Wrong dynamic huffman codes.');\n }\n var miRepSymbol = symbol - 16;\n var bits = CompressedStreamReader.DEF_HUFFMAN_DYNTREE_REPEAT_BITS[miRepSymbol];\n var count = this.readBits(bits);\n if (count < 0) {\n throw new DOMException('Wrong dynamic huffman codes.');\n }\n count += CompressedStreamReader.DEF_HUFFMAN_DYNTREE_REPEAT_MINIMUMS[miRepSymbol];\n if (iCurrentCode + count > iResultingCodeLengthsCount) {\n throw new DOMException('Wrong dynamic huffman codes.');\n }\n while (count-- > 0) {\n arrResultingCodeLengths[iCurrentCode++] = bLastSymbol;\n }\n if (iCurrentCode === iResultingCodeLengthsCount) {\n break;\n }\n }\n var tempArray = new Uint8Array(iLengthsCount);\n tempArray.set(arrResultingCodeLengths.subarray(0, iLengthsCount), 0);\n //sourceArray, sourceIndex, destinationArray, destinationIndex, length\n //Array.copy( arrResultingCodeLengths, 0, tempArray, 0, iLengthsCount );\n lengthTree = new DecompressorHuffmanTree(tempArray);\n tempArray = arrResultingCodeLengths.slice(iLengthsCount, iLengthsCount + iDistancesCount);\n //Array.copy( arrResultingCodeLengths, iLengthsCount, tempArray, 0, iDistancesCount );\n distanceTree = new DecompressorHuffmanTree(tempArray);\n return { 'lengthTree': lengthTree, 'distanceTree': distanceTree };\n };\n /// <summary>\n /// Decodes huffman codes.\n /// </summary>\n /// <returns>True if some data was read.</returns>\n CompressedStreamReader.prototype.readHuffman = function () {\n var free = this.DEF_MAX_WINDOW_SIZE - (this.mDataLength - this.mCurrentPosition);\n var dataRead = false;\n //long maxdistance = DEF_MAX_WINDOW_SIZE >> 1;\n var readdata = {};\n // DEF_HUFFMAN_REPEATE_MAX - longest repeatable block, we should always reserve space for it because\n // if we should not, we will have buffer overrun.\n while (free >= this.DEF_HUFFMAN_REPEATE_MAX) {\n var symbol = void 0;\n symbol = this.mCurrentLengthTree.unpackSymbol(this);\n // Only codes 0..255 are valid independent symbols.\n while (((symbol) & ~0xff) === 0) {\n readdata[(this.mDataLength + 1) % this.DEF_MAX_WINDOW_SIZE] = symbol;\n this.mBlockBuffer[this.mDataLength++ % this.DEF_MAX_WINDOW_SIZE] = symbol;\n dataRead = true;\n if (--free < this.DEF_HUFFMAN_REPEATE_MAX) {\n return true;\n }\n //if( (mDataLength - mCurrentPosition ) < maxdistance ) return true;\n symbol = this.mCurrentLengthTree.unpackSymbol(this);\n }\n if (symbol < this.DEF_HUFFMAN_LENGTH_MINIMUMCODE) {\n if (symbol < this.DEF_HUFFMAN_END_BLOCK) {\n throw new DOMException('Illegal code.');\n }\n var numDataRead = dataRead ? 1 : 0;\n this.mbCanReadMoreData = this.decodeBlockHeader();\n var numReadMore = (this.mbCanReadMoreData) ? 1 : 0;\n return (numDataRead | numReadMore) ? true : false;\n }\n if (symbol > this.DEF_HUFFMAN_LENGTH_MAXIMUMCODE) {\n throw new DOMException('Illegal repeat code length.');\n }\n var iRepeatLength = CompressedStreamReader.DEF_HUFFMAN_REPEAT_LENGTH_BASE[symbol -\n this.DEF_HUFFMAN_LENGTH_MINIMUMCODE];\n var iRepeatExtraBits = CompressedStreamReader.DEF_HUFFMAN_REPEAT_LENGTH_EXTENSION[symbol -\n this.DEF_HUFFMAN_LENGTH_MINIMUMCODE];\n if (iRepeatExtraBits > 0) {\n var extra = this.readBits(iRepeatExtraBits);\n if (extra < 0) {\n throw new DOMException('Wrong data.');\n }\n iRepeatLength += extra;\n }\n // Unpack repeat distance.\n symbol = this.mCurrentDistanceTree.unpackSymbol(this);\n if (symbol < 0 || symbol > CompressedStreamReader.DEF_HUFFMAN_REPEAT_DISTANCE_BASE.length) {\n throw new DOMException('Wrong distance code.');\n }\n var iRepeatDistance = CompressedStreamReader.DEF_HUFFMAN_REPEAT_DISTANCE_BASE[symbol];\n iRepeatExtraBits = CompressedStreamReader.DEF_HUFFMAN_REPEAT_DISTANCE_EXTENSION[symbol];\n if (iRepeatExtraBits > 0) {\n var extra = this.readBits(iRepeatExtraBits);\n if (extra < 0) {\n throw new DOMException('Wrong data.');\n }\n iRepeatDistance += extra;\n }\n // Copy data in slow repeat mode\n for (var i = 0; i < iRepeatLength; i++) {\n this.mBlockBuffer[this.mDataLength % this.DEF_MAX_WINDOW_SIZE] =\n this.mBlockBuffer[(this.mDataLength - iRepeatDistance) % this.DEF_MAX_WINDOW_SIZE];\n this.mDataLength++;\n free--;\n }\n dataRead = true;\n }\n return dataRead;\n };\n /// <summary>\n /// Reads data to buffer.\n /// </summary>\n /// <param name=\"buffer\">Output buffer for data.</param>\n /// <param name=\"offset\">Offset in output data.</param>\n /// <param name=\"length\">Length of the data to be read.</param>\n /// <returns>Count of bytes actually read.</returns>\n CompressedStreamReader.prototype.read = function (buffer, offset, length) {\n if (buffer == null) {\n throw new DOMException('buffer');\n }\n if (offset < 0 || offset > buffer.length - 1) {\n throw new DOMException('offset', 'Offset does not belong to specified buffer.');\n }\n if (length < 0 || length > buffer.length - offset) {\n throw new DOMException('length', 'Length is illegal.');\n }\n var initialLength = length;\n while (length > 0) {\n // Read from internal buffer.\n if (this.mCurrentPosition < this.mDataLength) {\n // Position in buffer array.\n var inBlockPosition = (this.mCurrentPosition % this.DEF_MAX_WINDOW_SIZE);\n // We can not read more than we have in buffer at once,\n // and we not read more than till the array end.\n var dataToCopy = Math.min(this.DEF_MAX_WINDOW_SIZE - inBlockPosition, (this.mDataLength - this.mCurrentPosition));\n // Reading not more, than the rest of the buffer.\n dataToCopy = Math.min(dataToCopy, length);\n //sourceArray, sourceIndex, destinationArray, destinationIndex, length\n // Copy data.\n //Array.Copy( mBlockBuffer, inBlockPosition, buffer, offset, dataToCopy );\n //buffer.set(this.mBlockBuffer.slice(inBlockPosition, dataToCopy), offset);\n Utils.arrayCopy(this.mBlockBuffer, inBlockPosition, buffer, offset, dataToCopy);\n // Correct position, length,\n this.mCurrentPosition += dataToCopy;\n offset += dataToCopy;\n length -= dataToCopy;\n }\n else {\n if (!this.mbCanReadMoreData) {\n break;\n }\n var oldDataLength = this.mDataLength;\n if (!this.mbReadingUncompressed) {\n if (!this.readHuffman()) {\n break;\n }\n }\n else {\n if (this.mUncompressedDataLength === 0) {\n // If there is no more data in stream, just exit.\n this.mbCanReadMoreData = this.decodeBlockHeader();\n if (!(this.mbCanReadMoreData)) {\n break;\n }\n }\n else {\n // Position of the data end in block buffer.\n var inBlockPosition = (this.mDataLength % this.DEF_MAX_WINDOW_SIZE);\n var dataToRead = Math.min(this.mUncompressedDataLength, this.DEF_MAX_WINDOW_SIZE - inBlockPosition);\n var dataRead = this.readPackedBytes(this.mBlockBuffer, inBlockPosition, dataToRead);\n if (dataToRead !== dataRead) {\n throw new DOMException('Not enough data in stream.');\n }\n this.mUncompressedDataLength -= dataRead;\n this.mDataLength += dataRead;\n }\n }\n if (oldDataLength < this.mDataLength) {\n var start = (oldDataLength % this.DEF_MAX_WINDOW_SIZE);\n var end = (this.mDataLength % this.DEF_MAX_WINDOW_SIZE);\n if (start < end) {\n this.checksumUpdate(this.mBlockBuffer, start, end - start);\n }\n else {\n this.checksumUpdate(this.mBlockBuffer, start, this.DEF_MAX_WINDOW_SIZE - start);\n if (end > 0) {\n this.checksumUpdate(this.mBlockBuffer, 0, end);\n }\n }\n }\n }\n }\n if (!this.mbCanReadMoreData && !this.mbCheckSumRead && !this.mbNoWrap) {\n this.skipToBoundary();\n var checkSum = this.readInt32();\n //Debug.Assert( checkSum == mCheckSum, \"\" );\n if (checkSum !== this.mCheckSum) {\n throw new DOMException('Checksum check failed.');\n }\n this.mbCheckSumRead = true;\n }\n return initialLength - length;\n };\n /// <summary>\n /// Reads array of bytes.\n /// </summary>\n /// <param name=\"buffer\">Output buffer.</param>\n /// <param name=\"offset\">Offset in output buffer.</param>\n /// <param name=\"length\">Length of the data to be read.</param>\n /// <returns>Count of bytes actually read to the buffer.</returns>\n CompressedStreamReader.prototype.readPackedBytes = function (buffer, offset, length) {\n if (buffer == null) {\n throw new DOMException('buffer');\n }\n if (offset < 0 || offset > buffer.length - 1) {\n throw new DOMException('offset\", \"Offset can not be less than zero or greater than buffer length - 1.');\n }\n if (length < 0) {\n throw new DOMException('length\", \"Length can not be less than zero.');\n }\n if (length > buffer.length - offset) {\n throw new DOMException('length\", \"Length is too large.');\n }\n if ((this.mBufferedBits & 7) !== 0) {\n throw new DOMException('Reading of unalligned data is not supported.');\n }\n if (length === 0) {\n return 0;\n }\n var result = 0;\n while (this.mBufferedBits > 0 && length > 0) {\n buffer[offset++] = (this.mBuffer);\n this.mBufferedBits -= 8;\n this.mBuffer = Utils.bitConverterInt32ToUint(this.mBuffer >>> 8);\n length--;\n result++;\n }\n if (length > 0) {\n //TODO: Fix this.\n result += this.mInputStream.read(buffer, offset, length);\n }\n return result;\n };\n /// <summary>\n /// TODO: place correct comment here\n /// </summary>\n /// <returns>\n /// TODO: place correct comment here\n /// </returns>\n CompressedStreamReader.prototype.readInt32 = function () {\n var result = this.readBits(8) << 24;\n result |= this.readBits(8) << 16;\n result |= this.readBits(8) << 8;\n result |= this.readBits(8);\n return result;\n };\n /// <summary>\n /// Updates checksum by calculating checksum of the\n /// given buffer and adding it to current value.\n /// </summary>\n /// <param name=\"buffer\">Data byte array.</param>\n /// <param name=\"offset\">Offset in the buffer.</param>\n /// <param name=\"length\">Length of data to be used from the stream.</param>\n CompressedStreamReader.prototype.checksumUpdate = function (buffer, offset, length) {\n ChecksumCalculator.ChecksumUpdate(this.mCheckSum, buffer, offset, length);\n };\n CompressedStreamReader.DEF_REVERSE_BITS = new Uint8Array([0, 8, 4, 12, 2, 10, 6, 14, 1, 9, 5, 13, 3, 11, 7, 15]);\n /// <summary>\n /// Minimum count of repetions.\n /// </summary>\n CompressedStreamReader.DEF_HUFFMAN_DYNTREE_REPEAT_MINIMUMS = [3, 3, 11];\n /// <summary>\n /// Bits, that responds for different repetion modes.\n /// </summary>\n CompressedStreamReader.DEF_HUFFMAN_DYNTREE_REPEAT_BITS = [2, 3, 7];\n /// <summary>\n /// Length bases.\n /// </summary>\n CompressedStreamReader.DEF_HUFFMAN_REPEAT_LENGTH_BASE = [\n 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 27, 31,\n 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258\n ];\n /// <summary>\n /// Length extended bits count.\n /// </summary>\n CompressedStreamReader.DEF_HUFFMAN_REPEAT_LENGTH_EXTENSION = [\n 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2,\n 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0\n ];\n /// <summary>\n /// Distance bases.\n /// </summary>\n CompressedStreamReader.DEF_HUFFMAN_REPEAT_DISTANCE_BASE = [\n 1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193,\n 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145,\n 8193, 12289, 16385, 24577\n ];\n /// <summary>\n /// Distance extanded bits count.\n /// </summary>\n CompressedStreamReader.DEF_HUFFMAN_REPEAT_DISTANCE_EXTENSION = [\n 0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6,\n 7, 7, 8, 8, 9, 9, 10, 10, 11, 11,\n 12, 12, 13, 13\n ];\n return CompressedStreamReader;\n}());\nexport { CompressedStreamReader };\nvar Stream = /** @class */ (function () {\n function Stream(input) {\n this.position = 0;\n this.inputStream = new Uint8Array(input.buffer);\n }\n Object.defineProperty(Stream.prototype, \"length\", {\n get: function () {\n return this.inputStream.buffer.byteLength;\n },\n enumerable: true,\n configurable: true\n });\n Stream.prototype.read = function (buffer, start, length) {\n var temp = new Uint8Array(this.inputStream.buffer, this.position + start);\n var data = temp.subarray(0, length);\n buffer.set(data, 0);\n this.position += data.byteLength;\n return data.byteLength;\n };\n Stream.prototype.readByte = function () {\n return this.inputStream[this.position++];\n };\n Stream.prototype.write = function (inputBuffer, offset, count) {\n Utils.arrayCopy(inputBuffer, 0, this.inputStream, this.position + offset, count);\n // this.inputStream = new Uint8Array(this.inputStream.buffer, this.position + offset);\n // this.inputStream.set(inputBuffer, offset);\n this.position += count;\n };\n Stream.prototype.toByteArray = function () {\n return new Uint8Array(this.inputStream.buffer);\n };\n return Stream;\n}());\nexport { Stream };\n/* eslint-enable */ \n","/* eslint-disable */\nimport { CompressedStreamWriter, Stream, CompressedStreamReader } from './index';\nimport { Save } from '@syncfusion/ej2-file-utils';\nimport { Utils } from './utils';\nvar CRC32TABLE = [];\n/// <summary>\n/// Size of the int value in bytes.\n/// </summary>\nvar INT_SIZE = 4;\n/// <summary>\n/// Size of the short value in bytes.\n/// </summary>\nvar SHORT_SIZE = 2;\n/// <summary>\n/// End of central directory signature.\n/// </summary>\nvar CentralDirectoryEndSignature = 0x06054b50;\n/// <summary>\n/// Offset to the size field in the End of central directory record.\n/// </summary>\nvar CentralDirSizeOffset = 12;\n/// <summary>\n/// Central header signature.\n/// </summary>\nvar CentralHeaderSignature = 0x02014b50;\n/// <summary>\n/// Buffer size.\n/// </summary>\nvar BufferSize = 4096;\n/**\n * class provide compression library\n * ```typescript\n * let archive = new ZipArchive();\n * archive.compressionLevel = 'Normal';\n * let archiveItem = new ZipArchiveItem(archive, 'directoryName\\fileName.txt');\n * archive.addItem(archiveItem);\n * archive.save(fileName.zip);\n * ```\n */\nvar ZipArchive = /** @class */ (function () {\n /**\n * constructor for creating ZipArchive instance\n */\n function ZipArchive() {\n if (CRC32TABLE.length === 0) {\n ZipArchive.initCrc32Table();\n }\n this.files = [];\n this.level = 'Normal';\n Save.isMicrosoftBrowser = !(!navigator.msSaveBlob);\n }\n Object.defineProperty(ZipArchive.prototype, \"items\", {\n get: function () {\n return this.files;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ZipArchive.prototype, \"compressionLevel\", {\n /**\n * gets compression level\n */\n get: function () {\n return this.level;\n },\n /**\n * sets compression level\n */\n set: function (level) {\n this.level = level;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ZipArchive.prototype, \"length\", {\n /**\n * gets items count\n */\n get: function () {\n if (this.files === undefined) {\n return 0;\n }\n return this.files.length;\n },\n enumerable: true,\n configurable: true\n });\n /**\n * add new item to archive\n * @param {ZipArchiveItem} item - item to be added\n * @returns {void}\n */\n ZipArchive.prototype.addItem = function (item) {\n if (item === null || item === undefined) {\n throw new Error('ArgumentException: item cannot be null or undefined');\n }\n for (var i = 0; i < this.files.length; i++) {\n var file = this.files[i];\n if (file instanceof ZipArchiveItem) {\n if (file.name === item.name) {\n throw new Error('item with same name already exist');\n }\n }\n }\n this.files.push(item);\n };\n /**\n * add new directory to archive\n * @param directoryName directoryName to be created\n * @returns {void}\n */\n ZipArchive.prototype.addDirectory = function (directoryName) {\n if (directoryName === null || directoryName === undefined) {\n throw new Error('ArgumentException: string cannot be null or undefined');\n }\n if (directoryName.length === 0) {\n throw new Error('ArgumentException: string cannot be empty');\n }\n if (directoryName.slice(-1) !== '/') {\n directoryName += '/';\n }\n if (this.files.indexOf(directoryName) !== -1) {\n throw new Error('item with same name already exist');\n }\n this.files.push(directoryName);\n };\n /**\n * gets item at specified index\n * @param {number} index - item index\n * @returns {ZipArchiveItem}\n */\n ZipArchive.prototype.getItem = function (index) {\n if (index >= 0 && index < this.files.length) {\n return this.files[index];\n }\n return undefined;\n };\n /**\n * determines whether an element is in the collection\n * @param {string | ZipArchiveItem} item - item to search\n * @returns {boolean}\n */\n ZipArchive.prototype.contains = function (item) {\n return this.files.indexOf(item) !== -1 ? true : false;\n };\n ZipArchive.prototype.open = function (base64String) {\n //return promise = new Promise((resolve: Function, reject: Function) => {\n var zipArchive = this;\n var zipByteArray = Utils.encodedString(base64String);\n if (zipByteArray.length == 0)\n throw new DOMException(\"stream\");\n var stream = new Stream(zipByteArray);\n //let lCentralDirEndPosition = this.findValueFromEnd( arrBuffer, Constants.CentralDirectoryEndSignature, 65557 );\n var lCentralDirEndPosition = ZipArchive.findValueFromEnd(stream, CentralDirectoryEndSignature, 65557);\n if (lCentralDirEndPosition < 0)\n throw new DOMException(\"Can't locate end of central directory record. Possible wrong file format or archive is corrupt.\");\n // Step2. Locate central directory and iterate through all items\n stream.position = lCentralDirEndPosition + CentralDirSizeOffset;\n var iCentralDirSize = ZipArchive.ReadInt32(stream);\n var lCentralDirPosition = lCentralDirEndPosition - iCentralDirSize;\n // verify that this is really central directory\n stream.position = lCentralDirPosition;\n this.readCentralDirectoryDataAndExtractItems(stream);\n //});\n // let zipArchive: ZipArchive = this;\n //let promise: Promise<ZipArchive>;\n // return promise = new Promise((resolve: Function, reject: Function) => {\n // let reader: FileReader = new FileReader();\n // reader.onload = (e: Event) => {\n // let data: Uint8Array = new Uint8Array((e.target as any).result);\n // let zipReader: ZipReader = new ZipReader(data);\n // zipReader.readEntries().then((entries: ZipEntry[]) => {\n // for (let i: number = 0; i < entries.length; i++) {\n // let entry: ZipEntry = entries[i];\n // let item: ZipArchiveItem = new ZipArchiveItem(zipArchive, entry.fileName);\n // item.data = entry.data;\n // item.compressionMethod = entry.compressionMethod;\n // item.crc = entry.crc;\n // item.lastModified = entry.lastModified;\n // item.lastModifiedDate = entry.lastModifiedDate;\n // item.size = entry.size;\n // item.uncompressedSize = entry.uncompressedSize;\n // zipArchive.addItem(item);\n // }\n // resolve(zipArchive);\n // });\n // };\n // reader.readAsArrayBuffer(fileName);\n // });\n };\n /// <summary>\n /// Read central directory record from the stream.\n /// </summary>\n /// <param name=\"stream\">Stream to read from.</param>\n ZipArchive.prototype.readCentralDirectoryDataAndExtractItems = function (stream) {\n if (stream == null)\n throw new DOMException(\"stream\");\n var itemHelper;\n while (ZipArchive.ReadInt32(stream) == CentralHeaderSignature) {\n itemHelper = new ZipArchiveItemHelper();\n itemHelper.readCentralDirectoryData(stream);\n itemHelper;\n // let item: ZipArchiveItem = new ZipArchiveItem(this);\n // item.ReadCentralDirectoryData(stream);\n // m_arrItems.Add(item);\n }\n itemHelper.readData(stream, itemHelper.checkCrc);\n itemHelper.decompressData();\n this.files.push(new ZipArchiveItem(itemHelper.unCompressedStream.buffer, itemHelper.name));\n };\n /**\n * save archive with specified file name\n * @param {string} fileName save archive with specified file name\n * @returns {Promise<ZipArchive>}\n */\n ZipArchive.prototype.save = function (fileName) {\n if (fileName === null || fileName === undefined || fileName.length === 0) {\n throw new Error('ArgumentException: fileName cannot be null or undefined');\n }\n if (this.files.length === 0) {\n throw new Error('InvalidOperation');\n }\n var zipArchive = this;\n var promise;\n return promise = new Promise(function (resolve, reject) {\n zipArchive.saveInternal(fileName, false).then(function () {\n resolve(zipArchive);\n });\n });\n };\n /**\n * Save archive as blob\n * @return {Promise<Blob>}\n */\n ZipArchive.prototype.saveAsBlob = function () {\n var zipArchive = this;\n var promise;\n return promise = new Promise(function (resolve, reject) {\n zipArchive.saveInternal('', true).then(function (blob) {\n resolve(blob);\n });\n });\n };\n ZipArchive.prototype.saveInternal = function (fileName, skipFileSave) {\n var _this = this;\n var zipArchive = this;\n var promise;\n return promise = new Promise(function (resolve, reject) {\n var zipData = [];\n var dirLength = 0;\n for (var i = 0; i < zipArchive.files.length; i++) {\n var compressedObject = _this.getCompressedData(_this.files[i]);\n compressedObject.then(function (data) {\n dirLength = zipArchive.constructZippedObject(zipData, data, dirLength, data.isDirectory);\n if (zipData.length === zipArchive.files.length) {\n var blob = zipArchive.writeZippedContent(fileName, zipData, dirLength, skipFileSave);\n resolve(blob);\n }\n });\n }\n });\n };\n /**\n * release allocated un-managed resource\n * @returns {void}\n */\n ZipArchive.prototype.destroy = function () {\n if (this.files !== undefined && this.files.length > 0) {\n for (var i = 0; i < this.files.length; i++) {\n var file = this.files[i];\n if (file instanceof ZipArchiveItem) {\n file.destroy();\n }\n file = undefined;\n }\n this.files = [];\n }\n this.files = undefined;\n this.level = undefined;\n };\n ZipArchive.prototype.getCompressedData = function (item) {\n var zipArchive = this;\n var promise = new Promise(function (resolve, reject) {\n if (item instanceof ZipArchiveItem) {\n var reader_1 = new FileReader();\n reader_1.onload = function () {\n var input = new Uint8Array(reader_1.result);\n var data = {\n fileName: item.name, crc32Value: 0, compressedData: [],\n compressedSize: undefined, uncompressedDataSize: input.length, compressionType: undefined,\n isDirectory: false\n };\n if (zipArchive.level === 'Normal') {\n zipArchive.compressData(input, data, CRC32TABLE);\n var length_1 = 0;\n for (var i = 0; i < data.compressedData.length; i++) {\n length_1 += data.compressedData[i].length;\n }\n data.compressedSize = length_1;\n data.compressionType = '\\x08\\x00'; //Deflated = 8\n }\n else {\n data.compressedSize = input.length;\n data.crc32Value = zipArchive.calculateCrc32Value(0, input, CRC32TABLE);\n data.compressionType = '\\x00\\x00'; // Stored = 0\n data.compressedData.push(input);\n }\n resolve(data);\n };\n reader_1.readAsArrayBuffer(item.data);\n }\n else {\n var data = {\n fileName: item, crc32Value: 0, compressedData: '', compressedSize: 0, uncompressedDataSize: 0,\n compressionType: '\\x00\\x00', isDirectory: true\n };\n resolve(data);\n }\n });\n return promise;\n };\n ZipArchive.prototype.compressData = function (input, data, crc32Table) {\n var compressor = new CompressedStreamWriter(true);\n var currentIndex = 0;\n var nextIndex = 0;\n do {\n if (currentIndex >= input.length) {\n compressor.close();\n break;\n }\n nextIndex = Math.min(input.length, currentIndex + 16384);\n var subArray = input.subarray(currentIndex, nextIndex);\n data.crc32Value = this.calculateCrc32Value(data.crc32Value, subArray, crc32Table);\n compressor.write(subArray, 0, nextIndex - currentIndex);\n currentIndex = nextIndex;\n } while (currentIndex <= input.length);\n data.compressedData = compressor.compressedData;\n compressor.destroy();\n };\n ZipArchive.prototype.constructZippedObject = function (zipParts, data, dirLength, isDirectory) {\n var extFileAttr = 0;\n var date = new Date();\n if (isDirectory) {\n extFileAttr = extFileAttr | 0x00010; // directory flag\n }\n extFileAttr = extFileAttr | (0 & 0x3F);\n var header = this.writeHeader(data, date);\n var localHeader = 'PK\\x03\\x04' + header + data.fileName;\n var centralDir = this.writeCentralDirectory(data, header, dirLength, extFileAttr);\n zipParts.push({ localHeader: localHeader, centralDir: centralDir, compressedData: data });\n return dirLength + localHeader.length + data.compressedSize;\n };\n ZipArchive.prototype.writeHeader = function (data, date) {\n var zipHeader = '';\n zipHeader += '\\x0A\\x00' + '\\x00\\x00'; // version needed to extract & general purpose bit flag\n zipHeader += data.compressionType; // compression method Deflate=8,Stored=0\n zipHeader += this.getBytes(this.getModifiedTime(date), 2); // last modified Time\n zipHeader += this.getBytes(this.getModifiedDate(date), 2); // last modified date\n zipHeader += this.getBytes(data.crc32Value, 4); // crc-32 value\n zipHeader += this.getBytes(data.compressedSize, 4); // compressed file size\n zipHeader += this.getBytes(data.uncompressedDataSize, 4); // uncompressed file size\n zipHeader += this.getBytes(data.fileName.length, 2); // file name length\n zipHeader += this.getBytes(0, 2); // extra field length\n return zipHeader;\n };\n ZipArchive.prototype.writeZippedContent = function (fileName, zipData, localDirLen, skipFileSave) {\n var cenDirLen = 0;\n var buffer = [];\n for (var i = 0; i < zipData.length; i++) {\n var item = zipData[i];\n cenDirLen += item.centralDir.length;\n buffer.push(this.getArrayBuffer(item.localHeader));\n while (item.compressedData.compressedData.length) {\n buffer.push(item.compressedData.compressedData.shift().buffer);\n }\n }\n for (var i = 0; i < zipData.length; i++) {\n buffer.push(this.getArrayBuffer(zipData[i].centralDir));\n }\n buffer.push(this.getArrayBuffer(this.writeFooter(zipData, cenDirLen, localDirLen)));\n var blob = new Blob(buffer, { type: 'application/zip' });\n if (!skipFileSave) {\n Save.save(fileName, blob);\n }\n return blob;\n };\n ZipArchive.prototype.writeCentralDirectory = function (data, localHeader, offset, externalFileAttribute) {\n var directoryHeader = 'PK\\x01\\x02' +\n this.getBytes(0x0014, 2) + localHeader + // inherit from file header\n this.getBytes(0, 2) + // comment length\n '\\x00\\x00' + '\\x00\\x00' + // internal file attributes \n this.getBytes(externalFileAttribute, 4) + // external file attributes\n this.getBytes(offset, 4) + // local fileHeader relative offset\n data.fileName;\n return directoryHeader;\n };\n ZipArchive.prototype.writeFooter = function (zipData, centralLength, localLength) {\n var dirEnd = 'PK\\x05\\x06' + '\\x00\\x00' + '\\x00\\x00' +\n this.getBytes(zipData.length, 2) + this.getBytes(zipData.length, 2) +\n this.getBytes(centralLength, 4) + this.getBytes(localLength, 4) +\n this.getBytes(0, 2);\n return dirEnd;\n };\n ZipArchive.prototype.getArrayBuffer = function (input) {\n var a = new Uint8Array(input.length);\n for (var j = 0; j < input.length; ++j) {\n a[j] = input.charCodeAt(j) & 0xFF;\n }\n return a.buffer;\n };\n ZipArchive.prototype.getBytes = function (value, offset) {\n var bytes = '';\n for (var i = 0; i < offset; i++) {\n bytes += String.fromCharCode(value & 0xff);\n value = value >>> 8;\n }\n return bytes;\n };\n ZipArchive.prototype.getModifiedTime = function (date) {\n var modTime = date.getHours();\n modTime = modTime << 6;\n modTime = modTime | date.getMinutes();\n modTime = modTime << 5;\n return modTime = modTime | date.getSeconds() / 2;\n };\n ZipArchive.prototype.getModifiedDate = function (date) {\n var modiDate = date.getFullYear() - 1980;\n modiDate = modiDate << 4;\n modiDate = modiDate | (date.getMonth() + 1);\n modiDate = modiDate << 5;\n return modiDate = modiDate | date.getDate();\n };\n ZipArchive.prototype.calculateCrc32Value = function (crc32Value, input, crc32Table) {\n crc32Value ^= -1;\n for (var i = 0; i < input.length; i++) {\n crc32Value = (crc32Value >>> 8) ^ crc32Table[(crc32Value ^ input[i]) & 0xFF];\n }\n return (crc32Value ^ (-1));\n };\n /**\n * construct cyclic redundancy code table\n * @private\n */\n ZipArchive.initCrc32Table = function () {\n var i;\n for (var j = 0; j < 256; j++) {\n i = j;\n for (var k = 0; k < 8; k++) {\n i = ((i & 1) ? (0xEDB88320 ^ (i >>> 1)) : (i >>> 1));\n }\n CRC32TABLE[j] = i;\n }\n };\n ZipArchive.findValueFromEnd = function (stream, value, maxCount) {\n if (stream == null)\n throw new DOMException(\"stream\");\n // if( !stream.CanSeek || !stream.CanRead )\n // throw new ArgumentOutOfRangeException( \"We need to have seekable and readable stream.\" );\n // read last 4 bytes and compare with required value\n var lStreamSize = stream.inputStream.buffer.byteLength;\n if (lStreamSize < 4)\n return -1;\n var arrBuffer = new Uint8Array(4);\n var lLastPos = Math.max(0, lStreamSize - maxCount);\n var lCurrentPosition = lStreamSize - 1 - INT_SIZE;\n stream.position = lCurrentPosition;\n stream.read(arrBuffer, 0, INT_SIZE);\n var uiCurValue = arrBuffer[0];\n var bFound = (uiCurValue == value);\n if (!bFound) {\n while (lCurrentPosition > lLastPos) {\n // remove unnecessary byte and replace it with new value.\n uiCurValue <<= 8;\n lCurrentPosition--;\n stream.position = lCurrentPosition;\n uiCurValue += stream.readByte();\n if (uiCurValue == value) {\n bFound = true;\n break;\n }\n }\n }\n return bFound ? lCurrentPosition : -1;\n };\n /// <summary>\n /// Extracts Int32 value from the stream.\n /// </summary>\n /// <param name=\"stream\">Stream to read data from.</param>\n /// <returns>Extracted value.</returns>\n ZipArchive.ReadInt32 = function (stream) {\n var buffer = new Uint8Array(INT_SIZE);\n if (stream.read(buffer, 0, INT_SIZE) != INT_SIZE) {\n throw new DOMException(\"Unable to read value at the specified position - end of stream was reached.\");\n }\n return Utils.bitConverterToInt32(buffer, 0);\n };\n /// <summary>\n /// Extracts Int16 value from the stream.\n /// </summary>\n /// <param name=\"stream\">Stream to read data from.</param>\n /// <returns>Extracted value.</returns>\n ZipArchive.ReadInt16 = function (stream) {\n var buffer = new Uint8Array(SHORT_SIZE);\n if (stream.read(buffer, 0, SHORT_SIZE) != SHORT_SIZE) {\n throw new DOMException(\"Unable to read value at the specified position - end of stream was reached.\");\n }\n return Utils.bitConverterToInt16(buffer, 0);\n };\n /// <summary>\n /// Extracts unsigned Int16 value from the stream.\n /// </summary>\n /// <param name=\"stream\">Stream to read data from.</param>\n /// <returns>Extracted value.</returns>\n ZipArchive.ReadUInt16 = function (stream) {\n {\n var buffer = new Uint8Array(SHORT_SIZE);\n if (stream.read(buffer, 0, SHORT_SIZE) != SHORT_SIZE) {\n throw new DOMException(\"Unable to read value at the specified position - end of stream was reached.\");\n }\n return Utils.bitConverterToInt16(buffer, 0);\n }\n };\n return ZipArchive;\n}());\nexport { ZipArchive };\nvar ZipArchiveItemHelper = /** @class */ (function () {\n function ZipArchiveItemHelper() {\n /// <summary>\n /// Zip header signature.\n /// </summary>\n this.headerSignature = 0x04034b50;\n /// <summary>\n /// Indicates whether we should check Crc value when reading item's data. Check\n /// is performed when user gets access to decompressed data for the first time.\n /// </summary>\n this.checkCrc = true;\n /// <summary>\n /// Crc.\n /// </summary>\n this.crc32 = 0;\n }\n /// <summary>\n /// Read data from the stream based on the central directory.\n /// </summary>\n /// <param name=\"stream\">Stream to read data from, stream.Position must point at just after correct file header.</param>\n ZipArchiveItemHelper.prototype.readCentralDirectoryData = function (stream) {\n // on the current moment we ignore \"version made by\" and \"version needed to extract\" fields.\n stream.position += 4;\n this.options = ZipArchive.ReadInt16(stream);\n this.compressionMethod = ZipArchive.ReadInt16(stream);\n this.checkCrc = (this.compressionMethod != 99); //COmpression.Defalte != SecurityConstants.AES\n //m_bCompressed = true;\n // on the current moment we ignore \"last mod file time\" and \"last mod file date\" fields.\n var lastModified = ZipArchive.ReadInt32(stream);\n //LastModified = ConvertToDateTime(lastModified);\n this.crc32 = Utils.bitConverterToUInt32(ZipArchive.ReadInt32(stream));\n this.compressedSize = ZipArchive.ReadInt32(stream);\n this.originalSize = ZipArchive.ReadInt32(stream);\n var iFileNameLength = ZipArchive.ReadInt16(stream);\n var iExtraFieldLenth = ZipArchive.ReadInt16(stream);\n var iCommentLength = ZipArchive.ReadInt16(stream);\n // on the current moment we ignore and \"disk number start\" (2 bytes),\n // \"internal file attributes\" (2 bytes).\n stream.position += 4;\n this.externalAttributes = ZipArchive.ReadInt32(stream);\n this.localHeaderOffset = ZipArchive.ReadInt32(stream);\n var arrBuffer = new Uint8Array(iFileNameLength);\n stream.read(arrBuffer, 0, iFileNameLength);\n var m_strItemName = Utils.byteToString(arrBuffer);\n m_strItemName = m_strItemName.replace(\"\\\\\", \"/\");\n this.name = m_strItemName;\n stream.position += iExtraFieldLenth + iCommentLength;\n if (this.options != 0)\n this.options = 0;\n };\n /// <summary>\n /// Reads zipped data from the stream.\n /// </summary>\n /// <param name=\"stream\">Stream to read data from.</param>\n /// <param name=\"checkCrc\">Indicates whether we should check crc value after data decompression.</param>\n ZipArchiveItemHelper.prototype.readData = function (stream, checkCrc) {\n if (stream.length == 0)\n throw new DOMException(\"stream\");\n stream.position = this.localHeaderOffset;\n this.checkCrc = checkCrc;\n this.readLocalHeader(stream);\n this.readCompressedData(stream);\n };\n ZipArchiveItemHelper.prototype.decompressData = function () {\n if (this.compressionMethod == 8) {\n if (this.originalSize > 0) {\n this.decompressDataOld();\n }\n }\n };\n ZipArchiveItemHelper.prototype.decompressDataOld = function () {\n var reader = new CompressedStreamReader(this.compressedStream, true);\n var decompressedData;\n if (this.originalSize > 0)\n decompressedData = new Stream(new Uint8Array(this.originalSize));\n var arrBuffer = new Uint8Array(BufferSize);\n var iReadBytes;\n var past = new Uint8Array(0);\n while ((iReadBytes = reader.read(arrBuffer, 0, BufferSize)) > 0) {\n // past = new Uint8Array(decompressedData.length);\n // let currentBlock: Uint8Array = arrBuffer.subarray(0, iReadBytes);\n decompressedData.write(arrBuffer.subarray(0, iReadBytes), 0, iReadBytes);\n }\n this.unCompressedStream = decompressedData.toByteArray();\n // this.originalSize = decompressedData.Length;\n // m_bControlStream = true;\n // m_streamData = decompressedData;\n // decompressedData.SetLength( m_lOriginalSize );\n // decompressedData.Capacity = ( int )m_lOriginalSize;\n if (this.checkCrc) {\n //TODO: fix this\n //CheckCrc(decompressedData.ToArray());\n }\n //m_streamData.Position = 0;\n };\n /// <summary>\n /// Extracts local header from the stream.\n /// </summary>\n /// <param name=\"stream\">Stream to read data from.</param>\n ZipArchiveItemHelper.prototype.readLocalHeader = function (stream) {\n if (stream.length == 0)\n throw new DOMException(\"stream\");\n if (ZipArchive.ReadInt32(stream) != this.headerSignature)\n throw new DOMException(\"Can't find local header signature - wrong file format or file is corrupt.\");\n // TODO: it is good to verify data read from the central directory record,\n // but on the current moment we simply skip it.\n stream.position += 22;\n var iNameLength = ZipArchive.ReadInt16(stream);\n var iExtraLength = ZipArchive.ReadUInt16(stream);\n if (this.compressionMethod == 99) //SecurityConstants.AES\n {\n // stream.Position += iNameLength + 8;\n // m_archive.EncryptionAlgorithm = (EncryptionAlgorithm)stream.ReadByte();\n // m_actualCompression = new byte[2];\n // stream.Read(m_actualCompression, 0, 2);\n }\n else if (iExtraLength > 2) {\n stream.position += iNameLength;\n var headerVal = ZipArchive.ReadInt16(stream);\n if (headerVal == 0x0017) //PKZipEncryptionHeader\n throw new DOMException(\"UnSupported\");\n else\n stream.position += iExtraLength - 2;\n }\n else\n stream.position += iNameLength + iExtraLength;\n };\n /// <summary>\n /// Extracts compressed data from the stream.\n /// </summary>\n /// <param name=\"stream\">Stream to read data from.</param>\n ZipArchiveItemHelper.prototype.readCompressedData = function (stream) {\n var dataStream;\n if (this.compressedSize > 0) {\n var iBytesLeft = this.compressedSize;\n dataStream = new Stream(new Uint8Array(iBytesLeft));\n var arrBuffer = new Uint8Array(BufferSize);\n while (iBytesLeft > 0) {\n var iBytesToRead = Math.min(iBytesLeft, BufferSize);\n if (stream.read(arrBuffer, 0, iBytesToRead) != iBytesToRead)\n throw new DOMException(\"End of file reached - wrong file format or file is corrupt.\");\n dataStream.write(arrBuffer.subarray(0, iBytesToRead), 0, iBytesToRead);\n iBytesLeft -= iBytesToRead;\n }\n // if(m_archive.Password != null)\n // {\n // byte[] dataBuffer = new byte[dataStream.Length];\n // dataBuffer = dataStream.ToArray();\n // dataStream=new MemoryStream( Decrypt(dataBuffer));\n // }\n this.compressedStream = new Uint8Array(dataStream.inputStream);\n // m_bControlStream = true;\n }\n else if (this.compressedSize < 0) //If compression size is negative, then read until the next header signature reached.\n {\n // MemoryStream dataStream = new MemoryStream();\n // int bt = 0;\n // bool proceed=true;\n // while (proceed)\n // {\n // if ((bt = stream.ReadByte()) == Constants.HeaderSignatureStartByteValue)\n // {\n // stream.Position -= 1;\n // int headerSignature = ZipArchive.ReadInt32(stream);\n // if (headerSignature==Constants.CentralHeaderSignature || headerSignature==Constants.CentralHeaderSignature)\n // {\n // proceed = false;\n // }\n // stream.Position -= 3;\n // }\n // if (proceed)\n // dataStream.WriteByte((byte)bt);\n // }\n // m_streamData = dataStream;\n // m_lCompressedSize = m_streamData.Length;\n // m_bControlStream = true;\n }\n else if (this.compressedSize == 0) {\n // m_streamData = new MemoryStream();\n }\n };\n return ZipArchiveItemHelper;\n}());\nexport { ZipArchiveItemHelper };\n/**\n * Class represent unique ZipArchive item\n * ```typescript\n * let archiveItem = new ZipArchiveItem(archive, 'directoryName\\fileName.txt');\n * ```\n */\nvar ZipArchiveItem = /** @class */ (function () {\n /**\n * constructor for creating {ZipArchiveItem} instance\n * @param {Blob|ArrayBuffer} data file data\n * @param {itemName} itemName absolute file path\n */\n function ZipArchiveItem(data, itemName) {\n if (data === null || data === undefined) {\n throw new Error('ArgumentException: data cannot be null or undefined');\n }\n if (itemName === null || itemName === undefined) {\n throw new Error('ArgumentException: string cannot be null or undefined');\n }\n if (itemName.length === 0) {\n throw new Error('string cannot be empty');\n }\n this.data = data;\n this.name = itemName;\n }\n Object.defineProperty(ZipArchiveItem.prototype, \"dataStream\", {\n get: function () {\n return this.decompressedStream;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(ZipArchiveItem.prototype, \"name\", {\n /**\n * Get the name of archive item\n * @returns string\n */\n get: function () {\n return this.fileName;\n },\n /**\n * Set the name of archive item\n * @param {string} value\n */\n set: function (value) {\n this.fileName = value;\n },\n enumerable: true,\n configurable: true\n });\n /**\n * release allocated un-managed resource\n * @returns {void}\n */\n ZipArchiveItem.prototype.destroy = function () {\n this.fileName = undefined;\n this.data = undefined;\n };\n return ZipArchiveItem;\n}());\nexport { ZipArchiveItem };\n/* eslint-enable */ \n","import { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { Internationalization } from '@syncfusion/ej2-base';\n// import { IValueFormatter } from '../base/interface';\n/**\n * ValueFormatter class to globalize the value.\n * @private\n */\nvar ValueFormatter = /** @class */ (function () {\n function ValueFormatter(cultureName) {\n this.intl = new Internationalization();\n // if (!isNullOrUndefined(cultureName)) {\n // this.intl.culture = cultureName;\n // }\n }\n ValueFormatter.prototype.getFormatFunction = function (format, isServerRendered) {\n if (format.type) {\n if (isServerRendered) {\n format.isServerRendered = true;\n }\n return this.intl.getDateFormat(format);\n }\n else {\n return this.intl.getNumberFormat(format);\n }\n };\n // public getParserFunction(format: NumberFormatOptions | DateFormatOptions): Function {\n // if ((<DateFormatOptions>format).type) {\n // return this.intl.getDateParser(<DateFormatOptions>format);\n // } else {\n // return this.intl.getNumberParser(<DateFormatOptions>format);\n // }\n // }\n // public fromView(value: string, format: Function, type?: string): string | number | Date {\n // if (type === 'date' || type === 'datetime' || type === 'number') {\n // return format(value);\n // } else {\n // return value;\n // }\n // }\n ValueFormatter.prototype.toView = function (value, format) {\n var result = value;\n if (!isNullOrUndefined(format) && !isNullOrUndefined(value)) {\n result = format(value);\n }\n return result;\n };\n // public setCulture(cultureName: string): void {\n // if (!isNullOrUndefined(cultureName)) {\n // setCulture(cultureName);\n // }\n // }\n /* tslint:disable:no-any */\n ValueFormatter.prototype.displayText = function (value, format, isServerRendered) {\n return this.toView(value, this.getFormatFunction(format, isServerRendered));\n };\n return ValueFormatter;\n}());\nexport { ValueFormatter };\n","import { ValueFormatter } from './value-formatter';\nimport { Encoding } from '@syncfusion/ej2-file-utils';\n/**\n * CsvHelper class\n * @private\n */\nvar CsvHelper = /** @class */ (function () {\n /* tslint:disable:no-any */\n function CsvHelper(json, separator) {\n this.csvStr = '';\n if (separator === null || separator === undefined) {\n this.separator = ',';\n }\n else {\n this.separator = separator;\n }\n this.formatter = new ValueFormatter();\n this.isMicrosoftBrowser = !(!navigator.msSaveBlob);\n if (json.isServerRendered !== null && json.isServerRendered !== undefined) {\n this.isServerRendered = json.isServerRendered;\n }\n if (json.styles !== null && json.styles !== undefined) {\n this.globalStyles = new Map();\n for (var i = 0; i < json.styles.length; i++) {\n if (json.styles[i].name !== undefined && json.styles[i].numberFormat !== undefined) {\n this.globalStyles.set(json.styles[i].name, json.styles[i].numberFormat);\n }\n }\n }\n // Parses Worksheets data to DOM. \n if (json.worksheets !== null && json.worksheets !== undefined) {\n this.parseWorksheet(json.worksheets[0]);\n }\n //this.csvStr = 'a1,a2,a3\\nb1,b2,b3';\n }\n CsvHelper.prototype.parseWorksheet = function (json) {\n //Rows\n if (json.rows !== null && json.rows !== undefined) {\n this.parseRows(json.rows);\n }\n };\n /* tslint:disable:no-any */\n CsvHelper.prototype.parseRows = function (rows) {\n var count = 1;\n for (var _i = 0, rows_1 = rows; _i < rows_1.length; _i++) {\n var row = rows_1[_i];\n //Row index\n if (row.index !== null && row.index !== undefined) {\n while (count < row.index) {\n this.csvStr += '\\r\\n';\n count++;\n }\n this.parseRow(row);\n }\n else {\n throw Error('Row index is missing.');\n }\n }\n this.csvStr += '\\r\\n';\n };\n /* tslint:disable:no-any */\n CsvHelper.prototype.parseRow = function (row) {\n if (row.cells !== null && row.cells !== undefined) {\n var count = 1;\n for (var _i = 0, _a = row.cells; _i < _a.length; _i++) {\n var cell = _a[_i];\n //cell index\n if (cell.index !== null && cell.index !== undefined) {\n while (count < cell.index) {\n this.csvStr += this.separator;\n count++;\n }\n this.parseCell(cell);\n }\n else {\n throw Error('Cell index is missing.');\n }\n }\n }\n };\n /* tslint:disable:no-any */\n CsvHelper.prototype.parseCell = function (cell) {\n var csv = this.csvStr;\n if (cell.value !== undefined) {\n if (cell.value instanceof Date) {\n if (cell.style !== undefined && cell.style.numberFormat !== undefined) {\n /* tslint:disable-next-line:max-line-length */\n try {\n csv += this.parseCellValue(this.formatter.displayText(cell.value, { type: 'dateTime', skeleton: cell.style.numberFormat }, this.isServerRendered));\n }\n catch (error) {\n /* tslint:disable-next-line:max-line-length */\n csv += this.parseCellValue(this.formatter.displayText(cell.value, { type: 'dateTime', format: cell.style.numberFormat }, this.isServerRendered));\n }\n }\n else if (cell.style !== undefined && cell.style.name !== undefined && this.globalStyles.has(cell.style.name)) {\n /* tslint:disable-next-line:max-line-length */\n try {\n csv += this.parseCellValue(this.formatter.displayText(cell.value, { type: 'dateTime', skeleton: this.globalStyles.get(cell.style.name) }, this.isServerRendered));\n }\n catch (error) {\n /* tslint:disable-next-line:max-line-length */\n csv += this.parseCellValue(this.formatter.displayText(cell.value, { type: 'dateTime', format: this.globalStyles.get(cell.style.name) }, this.isServerRendered));\n }\n }\n else {\n csv += cell.value;\n }\n }\n else if (typeof (cell.value) === 'boolean') {\n csv += cell.value ? 'TRUE' : 'FALSE';\n }\n else if (typeof (cell.value) === 'number') {\n if (cell.style !== undefined && cell.style.numberFormat !== undefined) {\n /* tslint:disable-next-line:max-line-length */\n csv += this.parseCellValue(this.formatter.displayText(cell.value, { format: cell.style.numberFormat }, this.isServerRendered));\n }\n else if (cell.style !== undefined && cell.style.name !== undefined && this.globalStyles.has(cell.style.name)) {\n /* tslint:disable-next-line:max-line-length */\n csv += this.parseCellValue(this.formatter.displayText(cell.value, { format: this.globalStyles.get(cell.style.name) }, this.isServerRendered));\n }\n else {\n csv += cell.value;\n }\n }\n else {\n csv += this.parseCellValue(cell.value);\n }\n }\n this.csvStr = csv;\n };\n CsvHelper.prototype.parseCellValue = function (value) {\n var val = '';\n var length = value.length;\n for (var start = 0; start < length; start++) {\n if (value[start] === '\\\"') {\n val += value[start].replace('\\\"', '\\\"\\\"');\n }\n else {\n val += value[start];\n }\n }\n value = val;\n if (value.indexOf(this.separator) !== -1 || value.indexOf('\\n') !== -1 || value.indexOf('\\\"') !== -1) {\n return value = '\\\"' + value + '\\\"';\n }\n else {\n return value;\n }\n };\n /**\n * Saves the file with specified name and sends the file to client browser\n * @param {string} fileName- file name to save.\n * @param {Blob} buffer- the content to write in file\n */\n CsvHelper.prototype.save = function (fileName) {\n this.buffer = new Blob(['\\ufeff' + this.csvStr], { type: 'text/csv;charset=UTF-8' });\n if (this.isMicrosoftBrowser) {\n navigator.msSaveBlob(this.buffer, fileName);\n }\n else {\n var dataUrl_1 = window.URL.createObjectURL(this.buffer);\n var dwlLink = document.createElementNS('http://www.w3.org/1999/xhtml', 'a');\n dwlLink.download = fileName;\n dwlLink.href = dataUrl_1;\n var event_1 = document.createEvent('MouseEvent');\n event_1.initEvent('click', true, true);\n dwlLink.dispatchEvent(event_1);\n setTimeout(function () {\n window.URL.revokeObjectURL(dataUrl_1);\n });\n }\n };\n /**\n * Returns a Blob object containing CSV data with optional encoding.\n * @param {string} [encodingType] - The supported encoding types are \"ansi\", \"unicode\" and \"utf8\".\n */\n /* tslint:disable:no-any */\n CsvHelper.prototype.saveAsBlob = function (encodingType) {\n if (encodingType != undefined) {\n var encoding = new Encoding();\n var encodeString = 'UTF-8';\n if (encodingType.toUpperCase() == \"ANSI\") {\n encoding.type = 'Ansi';\n encodeString = 'ANSI';\n }\n else if (encodingType.toUpperCase() == \"UNICODE\") {\n encoding.type = 'Unicode';\n encodeString = 'UNICODE';\n }\n else {\n encoding.type = 'Utf8';\n encodeString = 'UTF-8';\n }\n var buffer = encoding.getBytes(this.csvStr, 0, this.csvStr.length);\n return new Blob([buffer], { type: 'text/csv;charset=' + encodeString });\n }\n else\n return new Blob(['\\ufeff' + this.csvStr], { type: 'text/csv;charset=UTF-8' });\n };\n return CsvHelper;\n}());\nexport { CsvHelper };\n","/**\n * BlobHelper class\n * @private\n */\nvar BlobHelper = /** @class */ (function () {\n function BlobHelper() {\n /* tslint:disable:no-any */\n this.parts = [];\n }\n /* tslint:disable:no-any */\n BlobHelper.prototype.append = function (part) {\n this.parts.push(part);\n this.blob = undefined; // Invalidate the blob\n };\n BlobHelper.prototype.getBlob = function () {\n return new Blob(this.parts, { type: 'text/plain' });\n };\n return BlobHelper;\n}());\nexport { BlobHelper };\n","/**\n * AutoFilters class\n * @private\n */\nvar AutoFilters = /** @class */ (function () {\n function AutoFilters() {\n }\n return AutoFilters;\n}());\nexport { AutoFilters };\n","import { Worksheets } from './worksheets';\nimport { Worksheet, FreezePane, MergeCell, MergeCells, HyperLink, Grouping } from './worksheet';\nimport { CellStyle, Font, Borders, CellXfs, Alignment, NumFmt, CellStyleXfs, CellStyles } from './cell-style';\nimport { Column } from './column';\nimport { Row, Rows } from './row';\nimport { Image } from './image';\nimport { Cell, Cells } from './cell';\nimport { ZipArchive, ZipArchiveItem } from '@syncfusion/ej2-compression';\nimport { CsvHelper } from './csv-helper';\nimport { Internationalization, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { BlobHelper } from './blob-helper';\nimport { AutoFilters } from './auto-filters';\n/**\n * Workbook class\n */\nvar Workbook = /** @class */ (function () {\n /* tslint:disable:no-any */\n function Workbook(json, saveType, culture, currencyString, separator) {\n this.sharedStringCount = 0;\n this.unitsProportions = [\n 96 / 75.0,\n 96 / 300.0,\n 96,\n 96 / 25.4,\n 96 / 2.54,\n 1,\n 96 / 72.0,\n 96 / 72.0 / 12700,\n ];\n /* tslint:disable:no-any */\n this.hyperlinkStyle = { fontColor: '#0000FF', underline: true };\n if (culture !== undefined) {\n this.culture = culture;\n }\n else {\n this.culture = 'en-US';\n }\n if (currencyString !== undefined) {\n this.currency = currencyString;\n }\n else {\n this.currency = 'USD';\n }\n this.intl = new Internationalization(this.culture);\n this.mSaveType = saveType;\n if (saveType === 'xlsx') {\n this.mArchive = new ZipArchive();\n this.sharedString = [];\n this.mFonts = [];\n this.mBorders = [];\n this.mStyles = [];\n this.printTitles = new Map();\n this.cellStyles = new Map();\n this.mNumFmt = new Map();\n this.mFills = new Map();\n this.mStyles.push(new CellStyle());\n this.mFonts.push(new Font());\n /* tslint:disable */\n this.cellStyles.set('Normal', new CellStyles());\n /* tslint:enable */\n this.mCellXfs = [];\n this.mCellStyleXfs = [];\n this.drawingCount = 0;\n this.imageCount = 0;\n if (json.styles !== null && json.styles !== undefined) {\n /* tslint:disable-next-line:no-any */\n this.globalStyles = new Map();\n for (var i = 0; i < json.styles.length; i++) {\n if (json.styles[i].name !== undefined) {\n if (!this.cellStyles.has(json.styles[i].name)) {\n var cellStyle = new CellStyle();\n cellStyle.isGlobalStyle = true;\n this.parserCellStyle(json.styles[i], cellStyle, 'none');\n var cellStylesIn = new CellStyles();\n cellStylesIn.name = cellStyle.name;\n cellStylesIn.xfId = (cellStyle.index - 1);\n this.cellStyles.set(cellStylesIn.name, cellStylesIn);\n /* tslint:disable-next-line:no-any */\n var tFormat = {};\n if (json.styles[i].numberFormat !== undefined) {\n tFormat.format = json.styles[i].numberFormat;\n }\n if (json.styles[i].type !== undefined) {\n tFormat.type = json.styles[i].type;\n }\n else {\n tFormat.type = 'datetime';\n }\n if (tFormat.format !== undefined) {\n this.globalStyles.set(json.styles[i].name, tFormat);\n }\n }\n else {\n throw Error('Style name ' + json.styles[i].name + ' is already existed');\n }\n }\n }\n }\n // Parses Worksheets data to DOM. \n if (json.worksheets !== null && json.worksheets !== undefined) {\n this.parserWorksheets(json.worksheets);\n }\n else {\n throw Error('Worksheet is expected.');\n }\n // Parses the BuiltInProperties data to DOM. \n if (json.builtInProperties !== null && json.builtInProperties !== undefined) {\n this.builtInProperties = new BuiltInProperties();\n this.parserBuiltInProperties(json.builtInProperties, this.builtInProperties);\n }\n }\n else {\n this.csvHelper = new CsvHelper(json, separator);\n }\n }\n /* tslint:disable:no-any */\n Workbook.prototype.parserBuiltInProperties = function (jsonBuiltInProperties, builtInProperties) {\n //Author\n if (jsonBuiltInProperties.author !== null && jsonBuiltInProperties.author !== undefined) {\n builtInProperties.author = jsonBuiltInProperties.author;\n }\n //Comments\n if (jsonBuiltInProperties.comments !== null && jsonBuiltInProperties.comments !== undefined) {\n builtInProperties.comments = jsonBuiltInProperties.comments;\n }\n //Category\n if (jsonBuiltInProperties.category !== null && jsonBuiltInProperties.category !== undefined) {\n builtInProperties.category = jsonBuiltInProperties.category;\n }\n //Company\n if (jsonBuiltInProperties.company !== null && jsonBuiltInProperties.company !== undefined) {\n builtInProperties.company = jsonBuiltInProperties.company;\n }\n //Manager\n if (jsonBuiltInProperties.manager !== null && jsonBuiltInProperties.manager !== undefined) {\n builtInProperties.manager = jsonBuiltInProperties.manager;\n }\n //Subject\n if (jsonBuiltInProperties.subject !== null && jsonBuiltInProperties.subject !== undefined) {\n builtInProperties.subject = jsonBuiltInProperties.subject;\n }\n //Title\n if (jsonBuiltInProperties.title !== null && jsonBuiltInProperties.title !== undefined) {\n builtInProperties.title = jsonBuiltInProperties.title;\n }\n //Creation date\n if (jsonBuiltInProperties.createdDate !== null && jsonBuiltInProperties.createdDate !== undefined) {\n builtInProperties.createdDate = jsonBuiltInProperties.createdDate;\n }\n //Modified date\n if (jsonBuiltInProperties.modifiedDate !== null && jsonBuiltInProperties.modifiedDate !== undefined) {\n builtInProperties.modifiedDate = jsonBuiltInProperties.modifiedDate;\n }\n //Tags\n if (jsonBuiltInProperties.tags !== null && jsonBuiltInProperties.tags !== undefined) {\n builtInProperties.tags = jsonBuiltInProperties.tags;\n }\n //Status\n if (jsonBuiltInProperties.status !== null && jsonBuiltInProperties.status !== undefined) {\n builtInProperties.status = jsonBuiltInProperties.status;\n }\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserWorksheets = function (json) {\n this.worksheets = new Worksheets();\n var length = json.length;\n for (var i = 0; i < length; i++) {\n var jsonSheet = json[i];\n var sheet = new Worksheet();\n this.mergeCells = new MergeCells();\n this.mergedCellsStyle = new Map();\n this.mHyperLinks = [];\n //Name\n if (jsonSheet.name !== null && jsonSheet.name !== undefined) {\n sheet.name = jsonSheet.name;\n }\n else {\n sheet.name = 'Sheet' + (i + 1).toString();\n }\n if (jsonSheet.enableRtl !== null && jsonSheet.enableRtl !== undefined) {\n sheet.enableRtl = jsonSheet.enableRtl;\n }\n sheet.index = (i + 1);\n //Columns\n if (jsonSheet.columns !== null && jsonSheet.columns !== undefined) {\n this.parserColumns(jsonSheet.columns, sheet);\n }\n //Rows\n if (jsonSheet.rows !== null && jsonSheet.rows !== undefined) {\n this.parserRows(jsonSheet.rows, sheet);\n }\n //showGridLines\n if (jsonSheet.showGridLines !== null && jsonSheet.showGridLines !== undefined) {\n sheet.showGridLines = jsonSheet.showGridLines;\n }\n //FreezePanes\n if (jsonSheet.freeze !== null && jsonSheet.freeze !== undefined) {\n this.parserFreezePanes(jsonSheet.freeze, sheet);\n }\n //Print Title\n if (jsonSheet.printTitle !== null && jsonSheet.printTitle !== undefined) {\n this.parserPrintTitle(jsonSheet.printTitle, sheet);\n }\n if (jsonSheet.pageSetup !== undefined) {\n if (jsonSheet.pageSetup.isSummaryRowBelow !== undefined) {\n sheet.isSummaryRowBelow = jsonSheet.pageSetup.isSummaryRowBelow;\n }\n }\n if (jsonSheet.images !== undefined) {\n this.parserImages(jsonSheet.images, sheet);\n }\n if (jsonSheet.autoFilters !== null && jsonSheet.autoFilters !== undefined) {\n this.parseFilters(jsonSheet.autoFilters, sheet);\n }\n sheet.index = (i + 1);\n sheet.mergeCells = this.mergeCells;\n sheet.hyperLinks = this.mHyperLinks;\n this.worksheets.push(sheet);\n }\n };\n /* tslint:disable:no-any */\n Workbook.prototype.mergeOptions = function (fromJson, toJson) {\n /* tslint:disable:no-any */\n var result = {};\n this.applyProperties(fromJson, result);\n this.applyProperties(toJson, result);\n return result;\n };\n /* tslint:disable:no-any */\n Workbook.prototype.applyProperties = function (sourceJson, destJson) {\n var keys = Object.keys(sourceJson);\n for (var index = 0; index < keys.length; index++) {\n if (keys[index] !== 'name') {\n destJson[keys[index]] = sourceJson[keys[index]];\n }\n }\n };\n Workbook.prototype.getCellName = function (row, column) {\n return this.getColumnName(column) + row.toString();\n };\n Workbook.prototype.getColumnName = function (col) {\n col--;\n var strColumnName = '';\n do {\n var iCurrentDigit = col % 26;\n col = col / 26 - 1;\n strColumnName = String.fromCharCode(65 + iCurrentDigit) + strColumnName;\n } while (col >= 0);\n return strColumnName;\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserPrintTitle = function (json, sheet) {\n var printTitleName = '';\n var titleRowName;\n if (json.fromRow !== null && json.fromRow !== undefined) {\n var fromRow = json.fromRow;\n var toRow = void 0;\n if (json.toRow !== null && json.toRow !== undefined) {\n toRow = json.toRow;\n }\n else {\n toRow = json.fromRow;\n }\n titleRowName = '$' + fromRow + ':$' + toRow;\n }\n var titleColName;\n if (json.fromColumn !== null && json.fromColumn !== undefined) {\n var fromColumn = json.fromColumn;\n var toColumn = void 0;\n if (json.toColumn !== null && json.toColumn !== undefined) {\n toColumn = json.toColumn;\n }\n else {\n toColumn = json.fromColumn;\n }\n titleColName = '$' + this.getColumnName(fromColumn) + ':$' + this.getColumnName(toColumn);\n }\n if (titleRowName !== undefined) {\n printTitleName += (sheet.name + '!' + titleRowName);\n }\n if (titleColName !== undefined && titleRowName !== undefined) {\n printTitleName += ',' + (sheet.name + '!' + titleColName);\n }\n else if (titleColName !== undefined) {\n printTitleName += (sheet.name + '!' + titleColName);\n }\n if (printTitleName !== '') {\n this.printTitles.set(sheet.index - 1, printTitleName);\n }\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserFreezePanes = function (json, sheet) {\n sheet.freezePanes = new FreezePane();\n if (json.row !== null && json.row !== undefined) {\n sheet.freezePanes.row = json.row;\n }\n else {\n sheet.freezePanes.row = 0;\n }\n if (json.column !== null && json.column !== undefined) {\n sheet.freezePanes.column = json.column;\n }\n else {\n sheet.freezePanes.column = 0;\n }\n sheet.freezePanes.leftCell = this.getCellName(sheet.freezePanes.row + 1, sheet.freezePanes.column + 1);\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserColumns = function (json, sheet) {\n var columnsLength = json.length;\n sheet.columns = [];\n for (var column = 0; column < columnsLength; column++) {\n var col = new Column();\n if (json[column].index !== null && json[column].index !== undefined) {\n col.index = json[column].index;\n }\n else {\n throw Error('Column index is missing.');\n }\n if (json[column].width !== null && json[column].width !== undefined) {\n col.width = json[column].width;\n }\n sheet.columns.push(col);\n }\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserRows = function (json, sheet) {\n var rowsLength = json.length;\n sheet.rows = new Rows();\n var rowId = 0;\n for (var r = 0; r < rowsLength; r++) {\n var row = this.parserRow(json[r], rowId);\n rowId = row.index;\n sheet.rows.add(row);\n }\n this.insertMergedCellsStyle(sheet);\n };\n Workbook.prototype.insertMergedCellsStyle = function (sheet) {\n var _this = this;\n if (this.mergeCells.length > 0) {\n this.mergedCellsStyle.forEach(function (value, key) {\n var row = sheet.rows.filter(function (item) {\n return item.index === value.y;\n })[0];\n if (!isNullOrUndefined(row)) {\n var cell = row.cells.filter(function (item) {\n return item.index === value.x;\n })[0];\n if (!isNullOrUndefined(cell)) {\n cell.styleIndex = value.styleIndex;\n }\n else {\n var cells = row.cells.filter(function (item) {\n return item.index <= value.x;\n });\n var insertIndex = 0;\n if (cells.length > 0) {\n insertIndex = row.cells.indexOf(cells[cells.length - 1]) + 1;\n }\n row.cells.splice(insertIndex, 0, _this.createCell(value, key));\n }\n }\n else {\n var rows = sheet.rows.filter(function (item) {\n return item.index <= value.y;\n });\n var rowToInsert = new Row();\n rowToInsert.index = value.y;\n rowToInsert.cells = new Cells();\n rowToInsert.cells.add(_this.createCell(value, key));\n var insertIndex = 0;\n if (rows.length > 0) {\n insertIndex = sheet.rows.indexOf(rows[rows.length - 1]) + 1;\n }\n sheet.rows.splice(insertIndex, 0, rowToInsert);\n }\n });\n }\n };\n Workbook.prototype.createCell = function (value, key) {\n var cellToInsert = new Cell();\n cellToInsert.refName = key;\n cellToInsert.index = value.x;\n cellToInsert.cellStyle = new CellStyle();\n cellToInsert.styleIndex = value.styleIndex;\n return cellToInsert;\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserRow = function (json, rowIndex) {\n var row = new Row();\n //Row Height\n if (json.height !== null && json.height !== undefined) {\n row.height = json.height;\n }\n //Row index\n if (json.index !== null && json.index !== undefined) {\n row.index = json.index;\n }\n else {\n throw Error('Row index is missing.');\n }\n if (json.grouping !== null && json.grouping !== undefined) {\n this.parseGrouping(json.grouping, row);\n }\n this.parseCells(json.cells, row);\n return row;\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parseGrouping = function (json, row) {\n row.grouping = new Grouping();\n if (json.outlineLevel !== undefined) {\n row.grouping.outlineLevel = json.outlineLevel;\n }\n if (json.isCollapsed !== undefined) {\n row.grouping.isCollapsed = json.isCollapsed;\n }\n if (json.isHidden !== undefined) {\n row.grouping.isHidden = json.isHidden;\n }\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parseCells = function (json, row) {\n row.cells = new Cells();\n var cellsLength = json !== undefined ? json.length : 0;\n var spanMin = 1;\n var spanMax = 1;\n var curCellIndex = 0;\n for (var cellId = 0; cellId < cellsLength; cellId++) {\n /* tslint:disable:no-any */\n var jsonCell = json[cellId];\n var cell = new Cell();\n //cell index\n if (jsonCell.index !== null && jsonCell.index !== undefined) {\n cell.index = jsonCell.index;\n }\n else {\n throw Error('Cell index is missing.');\n }\n if (cell.index < spanMin) {\n spanMin = cell.index;\n }\n else if (cell.index > spanMax) {\n spanMax = cell.index;\n }\n //Update the Cell name\n cell.refName = this.getCellName(row.index, cell.index);\n //Row span\n if (jsonCell.rowSpan !== null && jsonCell.rowSpan !== undefined) {\n cell.rowSpan = jsonCell.rowSpan - 1;\n }\n else {\n cell.rowSpan = 0;\n }\n //Column span\n if (jsonCell.colSpan !== null && jsonCell.colSpan !== undefined) {\n cell.colSpan = jsonCell.colSpan - 1;\n }\n else {\n cell.colSpan = 0;\n }\n //Hyperlink\n if (jsonCell.hyperlink !== null && jsonCell.hyperlink !== undefined) {\n var hyperLink = new HyperLink();\n if (jsonCell.hyperlink.target !== undefined) {\n hyperLink.target = jsonCell.hyperlink.target;\n if (jsonCell.hyperlink.displayText !== undefined) {\n cell.value = jsonCell.hyperlink.displayText;\n }\n else {\n cell.value = jsonCell.hyperlink.target;\n }\n cell.type = this.getCellValueType(cell.value);\n hyperLink.ref = cell.refName;\n hyperLink.rId = (this.mHyperLinks.length + 1);\n this.mHyperLinks.push(hyperLink);\n cell.cellStyle = new CellStyle();\n /* tslint:disable-next-line:max-line-length */\n this.parserCellStyle((jsonCell.style !== undefined ? this.mergeOptions(jsonCell.style, this.hyperlinkStyle) : this.hyperlinkStyle), cell.cellStyle, 'string');\n cell.styleIndex = cell.cellStyle.index;\n }\n }\n // formulas\n if (jsonCell.formula !== null && jsonCell.formula !== undefined) {\n cell.formula = jsonCell.formula;\n cell.type = 'formula';\n }\n //Cell value\n if (jsonCell.value !== null && jsonCell.value !== undefined) {\n if (cell.formula !== undefined) {\n cell.value = 0;\n }\n else {\n cell.value = jsonCell.value;\n cell.type = this.getCellValueType(cell.value);\n }\n }\n if (jsonCell.style !== null && jsonCell.style !== undefined && cell.styleIndex === undefined) {\n cell.cellStyle = new CellStyle();\n if (cell.value instanceof Date) {\n this.parserCellStyle(jsonCell.style, cell.cellStyle, cell.type, 14);\n }\n else {\n this.parserCellStyle(jsonCell.style, cell.cellStyle, cell.type);\n }\n cell.styleIndex = cell.cellStyle.index;\n }\n else if (cell.value instanceof Date) {\n cell.cellStyle = new CellStyle();\n this.parserCellStyle({}, cell.cellStyle, cell.type, 14);\n cell.styleIndex = cell.cellStyle.index;\n }\n this.parseCellType(cell);\n this.mergeCells = this.processMergeCells(cell, row.index, this.mergeCells);\n row.cells.add(cell);\n curCellIndex = (cell.index + 1);\n }\n row.spans = (spanMin) + ':' + (spanMax);\n };\n Workbook.prototype.GetColors = function () {\n var colors;\n colors = new Map();\n /* tslint:disable */\n colors.set('WHITE', 'FFFFFFFF');\n /* tslint:disable */\n colors.set('SILVER', 'FFC0C0C0');\n /* tslint:disable */\n colors.set('GRAY', 'FF808080');\n /* tslint:disable */\n colors.set('BLACK', 'FF000000');\n /* tslint:disable */\n colors.set('RED', 'FFFF0000');\n /* tslint:disable */\n colors.set('MAROON', 'FF800000');\n /* tslint:disable */\n colors.set('YELLOW', 'FFFFFF00');\n /* tslint:disable */\n colors.set('OLIVE', 'FF808000');\n /* tslint:disable */\n colors.set('LIME', 'FF00FF00');\n /* tslint:disable */\n colors.set('GREEN', 'FF008000');\n /* tslint:disable */\n colors.set('AQUA', 'FF00FFFF');\n /* tslint:disable */\n colors.set('TEAL', 'FF008080');\n /* tslint:disable */\n colors.set('BLUE', 'FF0000FF');\n /* tslint:disable */\n colors.set('NAVY', 'FF000080');\n /* tslint:disable */\n colors.set('FUCHSIA', 'FFFF00FF');\n /* tslint:disable */\n colors.set('PURPLE', 'FF800080');\n return colors;\n };\n Workbook.prototype.processColor = function (colorVal) {\n if (colorVal.indexOf('#') === 0) {\n return colorVal.replace('#', 'FF');\n }\n colorVal = colorVal.toUpperCase();\n this.rgbColors = this.GetColors();\n if (this.rgbColors.has(colorVal)) {\n colorVal = this.rgbColors.get(colorVal);\n }\n else {\n colorVal = 'FF000000';\n }\n return colorVal;\n };\n Workbook.prototype.processCellValue = function (value, cell) {\n var cellValue = value;\n if (value.indexOf(\"<font\") !== -1 || value.indexOf(\"<a\") !== -1 || value.indexOf(\"<b>\") !== -1 ||\n value.indexOf(\"<i>\") !== -1 || value.indexOf(\"<u>\") !== -1) {\n var processedVal = '';\n var startindex = value.indexOf('<', 0);\n var endIndex = value.indexOf('>', startindex + 1);\n if (startindex >= 0 && endIndex >= 0) {\n if (startindex !== 0) {\n processedVal += '<r><t xml:space=\"preserve\">' + this.processString(value.substring(0, startindex)) + '</t></r>';\n }\n while (startindex >= 0 && endIndex >= 0) {\n endIndex = value.indexOf('>', startindex + 1);\n if (endIndex >= 0) {\n var subString = value.substring(startindex + 1, endIndex);\n startindex = value.indexOf('<', endIndex + 1);\n if (startindex < 0) {\n startindex = cellValue.length;\n }\n var text = cellValue.substring(endIndex + 1, startindex);\n if (text.length !== 0) {\n var subSplit = subString.split(' ');\n if (subSplit.length > 0) {\n processedVal += '<r><rPr>';\n }\n if (subSplit.length > 1) {\n for (var _i = 0, subSplit_1 = subSplit; _i < subSplit_1.length; _i++) {\n var element = subSplit_1[_i];\n var start = element.trim().substring(0, 5);\n switch (start) {\n case 'size=':\n processedVal += '<sz val=\"' + element.substring(6, element.length - 1) + '\"/>';\n break;\n case 'face=':\n processedVal += '<rFont val=\"' + element.substring(6, element.length - 1) + '\"/>';\n break;\n case 'color':\n processedVal += '<color rgb=\"' + this.processColor(element.substring(7, element.length - 1)) + '\"/>';\n break;\n case 'href=':\n var hyperLink = new HyperLink();\n hyperLink.target = element.substring(6, element.length - 1).trim();\n hyperLink.ref = cell.refName;\n hyperLink.rId = (this.mHyperLinks.length + 1);\n this.mHyperLinks.push(hyperLink);\n processedVal += '<color rgb=\"FF0000FF\"/><u/><b/>';\n break;\n }\n }\n }\n else if (subSplit.length === 1) {\n var style = subSplit[0].trim();\n switch (style) {\n case 'b':\n processedVal += '<b/>';\n break;\n case 'i':\n processedVal += '<i/>';\n break;\n case 'u':\n processedVal += '<u/>';\n break;\n }\n }\n processedVal += '</rPr><t xml:space=\"preserve\">' + this.processString(text) + '</t></r>';\n }\n }\n }\n if (processedVal === '') {\n return cellValue;\n }\n return processedVal;\n }\n else {\n return cellValue;\n }\n }\n else {\n return cellValue;\n }\n };\n Workbook.prototype.applyGlobalStyle = function (json, cellStyle) {\n var index = 0;\n if (this.cellStyles.has(json.name)) {\n cellStyle.index = this.mStyles.filter(function (a) { return (a.name === json.name); })[0].index;\n cellStyle.name = json.name;\n }\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserCellStyle = function (json, cellStyle, cellType, defStyleIndex) {\n //name\n if (json.name !== null && json.name !== undefined) {\n if (cellStyle.isGlobalStyle) {\n cellStyle.name = json.name;\n }\n else {\n this.applyGlobalStyle(json, cellStyle);\n return;\n }\n }\n //background color\n if (json.backColor !== null && json.backColor !== undefined) {\n cellStyle.backColor = json.backColor;\n }\n //borders\n //leftBorder\n cellStyle.borders = new Borders();\n //AllBorder\n if (json.borders !== null && json.borders !== undefined) {\n this.parserBorder(json.borders, cellStyle.borders.all);\n }\n //leftborder\n if (json.leftBorder !== null && json.leftBorder !== undefined) {\n this.parserBorder(json.leftBorder, cellStyle.borders.left);\n }\n //rightBorder\n if (json.rightBorder !== null && json.rightBorder !== undefined) {\n this.parserBorder(json.rightBorder, cellStyle.borders.right);\n }\n //topBorder\n if (json.topBorder !== null && json.topBorder !== undefined) {\n this.parserBorder(json.topBorder, cellStyle.borders.top);\n }\n //bottomBorder\n if (json.bottomBorder !== null && json.bottomBorder !== undefined) {\n this.parserBorder(json.bottomBorder, cellStyle.borders.bottom);\n }\n //fontName\n if (json.fontName !== null && json.fontName !== undefined) {\n cellStyle.fontName = json.fontName;\n }\n //fontSize\n if (json.fontSize !== null && json.fontSize !== undefined) {\n cellStyle.fontSize = json.fontSize;\n }\n //fontColor\n if (json.fontColor !== null && json.fontColor !== undefined) {\n cellStyle.fontColor = json.fontColor;\n }\n //italic\n if (json.italic !== null && json.italic !== undefined) {\n cellStyle.italic = json.italic;\n }\n //bold\n if (json.bold !== null && json.bold !== undefined) {\n cellStyle.bold = json.bold;\n }\n //hAlign\n if (json.hAlign !== null && json.hAlign !== undefined) {\n cellStyle.hAlign = json.hAlign.toLowerCase();\n }\n //indent\n if (json.indent !== null && json.indent !== undefined) {\n cellStyle.indent = json.indent;\n if (!(cellStyle.hAlign === 'left' || cellStyle.hAlign === 'right')) {\n cellStyle.hAlign = 'left';\n }\n }\n if (json.rotation !== null && json.rotation !== undefined) {\n cellStyle.rotation = json.rotation;\n }\n //vAlign\n if (json.vAlign !== null && json.vAlign !== undefined) {\n cellStyle.vAlign = json.vAlign.toLowerCase();\n }\n //underline\n if (json.underline !== null && json.underline !== undefined) {\n cellStyle.underline = json.underline;\n }\n //strikeThrough\n if (json.strikeThrough !== null && json.strikeThrough !== undefined) {\n cellStyle.strikeThrough = json.strikeThrough;\n }\n //wrapText\n if (json.wrapText !== null && json.wrapText !== undefined) {\n cellStyle.wrapText = json.wrapText;\n }\n //numberFormat\n if (json.numberFormat !== null && json.numberFormat !== undefined) {\n if (json.type !== null && json.type !== undefined) {\n cellStyle.numberFormat = this.getNumberFormat(json.numberFormat, json.type);\n }\n else {\n cellStyle.numberFormat = this.getNumberFormat(json.numberFormat, cellType);\n }\n }\n else if (defStyleIndex !== undefined) {\n cellStyle.numFmtId = 14;\n cellStyle.numberFormat = 'GENERAL';\n }\n else {\n cellStyle.numberFormat = 'GENERAL';\n }\n cellStyle.index = this.processCellStyle(cellStyle);\n };\n Workbook.prototype.switchNumberFormat = function (numberFormat, type) {\n var format = this.getNumberFormat(numberFormat, type);\n if (format !== numberFormat) {\n var numFmt = this.mNumFmt.get(numberFormat);\n if (numFmt !== undefined) {\n numFmt.formatCode = format;\n if (this.mNumFmt.has(format)) {\n for (var _i = 0, _a = this.mCellStyleXfs; _i < _a.length; _i++) {\n var cellStyleXfs = _a[_i];\n if (cellStyleXfs.numFmtId === numFmt.numFmtId) {\n cellStyleXfs.numFmtId = this.mNumFmt.get(format).numFmtId;\n }\n }\n for (var _b = 0, _c = this.mCellXfs; _b < _c.length; _b++) {\n var cellXfs = _c[_b];\n if (cellXfs.numFmtId === numFmt.numFmtId) {\n cellXfs.numFmtId = this.mNumFmt.get(format).numFmtId;\n }\n }\n }\n }\n }\n };\n Workbook.prototype.changeNumberFormats = function (value) {\n if (typeof value == \"string\") {\n var regex = new RegExp(this.currency, 'g');\n value = value.replace(regex, '[$' + this.currency + ']');\n }\n else if (typeof value == \"object\") {\n for (var i = 0; i < value.length; i++) {\n value[i] = value[i].replace(this.currency, '[$' + this.currency + ']');\n }\n }\n return value;\n };\n Workbook.prototype.getNumberFormat = function (numberFormat, type) {\n var returnFormat;\n switch (type) {\n case 'number':\n try {\n returnFormat = this.intl.getNumberPattern({ format: numberFormat, currency: this.currency, useGrouping: true }, true);\n if (this.currency.length > 1) {\n returnFormat = this.changeNumberFormats(returnFormat);\n }\n }\n catch (error) {\n returnFormat = numberFormat;\n }\n break;\n case 'datetime':\n try {\n returnFormat = this.intl.getDatePattern({ skeleton: numberFormat, type: 'dateTime' }, true);\n }\n catch (error) {\n try {\n returnFormat = this.intl.getDatePattern({ format: numberFormat, type: 'dateTime' }, true);\n }\n catch (error) {\n returnFormat = numberFormat;\n }\n }\n break;\n case 'date':\n try {\n returnFormat = this.intl.getDatePattern({ skeleton: numberFormat, type: 'date' }, true);\n }\n catch (error) {\n try {\n returnFormat = this.intl.getDatePattern({ format: numberFormat, type: 'date' }, true);\n }\n catch (error) {\n returnFormat = numberFormat;\n }\n }\n break;\n case 'time':\n try {\n returnFormat = this.intl.getDatePattern({ skeleton: numberFormat, type: 'time' }, true);\n }\n catch (error) {\n try {\n returnFormat = this.intl.getDatePattern({ format: numberFormat, type: 'time' }, true);\n }\n catch (error) {\n returnFormat = numberFormat;\n }\n }\n break;\n default:\n returnFormat = numberFormat;\n break;\n }\n return returnFormat;\n };\n /* tslint:disable:no-any */\n Workbook.prototype.parserBorder = function (json, border) {\n if (json.color !== null && json.color !== undefined) {\n border.color = json.color;\n }\n else {\n border.color = '#000000';\n }\n if (json.lineStyle !== null && json.lineStyle !== undefined) {\n border.lineStyle = json.lineStyle;\n }\n else {\n border.lineStyle = 'thin';\n }\n };\n Workbook.prototype.processCellStyle = function (style) {\n if (style.isGlobalStyle) {\n this.processNumFormatId(style);\n this.mStyles.push(style);\n return this.mStyles.length;\n }\n else {\n var compareResult = this.compareStyle(style);\n if (!compareResult.result) {\n this.processNumFormatId(style);\n this.mStyles.push(style);\n return this.mStyles.length;\n }\n else {\n //Return the index of the already existing style.\n return compareResult.index;\n }\n }\n };\n Workbook.prototype.processNumFormatId = function (style) {\n if (style.numberFormat !== 'GENERAL' && !this.mNumFmt.has(style.numberFormat)) {\n var id = this.mNumFmt.size + 164;\n this.mNumFmt.set(style.numberFormat, new NumFmt(id, style.numberFormat));\n }\n };\n Workbook.prototype.isNewFont = function (toCompareStyle) {\n var result = false;\n var index = 0;\n for (var _i = 0, _a = this.mFonts; _i < _a.length; _i++) {\n var font = _a[_i];\n index++;\n var fontColor = undefined;\n if (toCompareStyle.fontColor !== undefined) {\n fontColor = ('FF' + toCompareStyle.fontColor.replace('#', ''));\n }\n result = font.color === fontColor &&\n font.b === toCompareStyle.bold &&\n font.i === toCompareStyle.italic &&\n font.u === toCompareStyle.underline &&\n font.strike === toCompareStyle.strikeThrough &&\n font.name === toCompareStyle.fontName &&\n font.sz === toCompareStyle.fontSize;\n if (result) {\n break;\n }\n }\n index = index - 1;\n return { index: index, result: result };\n };\n Workbook.prototype.isNewBorder = function (toCompareStyle) {\n var bStyle = new CellStyle();\n if (this.isAllBorder(toCompareStyle.borders)) {\n return (bStyle.borders.all.color === toCompareStyle.borders.all.color &&\n bStyle.borders.all.lineStyle === toCompareStyle.borders.all.lineStyle);\n }\n else {\n return (bStyle.borders.left.color === toCompareStyle.borders.left.color &&\n bStyle.borders.left.lineStyle === toCompareStyle.borders.left.lineStyle &&\n bStyle.borders.right.color === toCompareStyle.borders.right.color &&\n bStyle.borders.right.lineStyle === toCompareStyle.borders.right.lineStyle &&\n bStyle.borders.top.color === toCompareStyle.borders.top.color &&\n bStyle.borders.top.lineStyle === toCompareStyle.borders.top.lineStyle &&\n bStyle.borders.bottom.color === toCompareStyle.borders.bottom.color &&\n bStyle.borders.bottom.lineStyle === toCompareStyle.borders.bottom.lineStyle);\n }\n };\n Workbook.prototype.isAllBorder = function (toCompareBorder) {\n var allBorderStyle = new CellStyle();\n return allBorderStyle.borders.all.color !== toCompareBorder.all.color &&\n allBorderStyle.borders.all.lineStyle !== toCompareBorder.all.lineStyle;\n };\n Workbook.prototype.compareStyle = function (toCompareStyle) {\n var result = true;\n var index = 0;\n var globalStyleIndex = 0;\n for (var _i = 0, _a = this.mStyles; _i < _a.length; _i++) {\n var baseStyle = _a[_i];\n result = baseStyle.isGlobalStyle ? false : (baseStyle.backColor === toCompareStyle.backColor &&\n baseStyle.bold === toCompareStyle.bold &&\n baseStyle.numFmtId === toCompareStyle.numFmtId &&\n baseStyle.numberFormat === toCompareStyle.numberFormat &&\n baseStyle.type === toCompareStyle.type &&\n baseStyle.fontColor === toCompareStyle.fontColor &&\n baseStyle.fontName === toCompareStyle.fontName &&\n baseStyle.fontSize === toCompareStyle.fontSize &&\n baseStyle.hAlign === toCompareStyle.hAlign &&\n baseStyle.italic === toCompareStyle.italic &&\n baseStyle.underline === toCompareStyle.underline &&\n baseStyle.strikeThrough === toCompareStyle.strikeThrough &&\n baseStyle.vAlign === toCompareStyle.vAlign &&\n baseStyle.indent === toCompareStyle.indent &&\n baseStyle.rotation === toCompareStyle.rotation &&\n baseStyle.wrapText === toCompareStyle.wrapText &&\n (baseStyle.borders.all.color === toCompareStyle.borders.all.color &&\n baseStyle.borders.all.lineStyle === toCompareStyle.borders.all.lineStyle) &&\n (baseStyle.borders.left.color === toCompareStyle.borders.left.color &&\n baseStyle.borders.left.lineStyle === toCompareStyle.borders.left.lineStyle &&\n baseStyle.borders.right.color === toCompareStyle.borders.right.color &&\n baseStyle.borders.right.lineStyle === toCompareStyle.borders.right.lineStyle &&\n baseStyle.borders.top.color === toCompareStyle.borders.top.color &&\n baseStyle.borders.top.lineStyle === toCompareStyle.borders.top.lineStyle &&\n baseStyle.borders.bottom.color === toCompareStyle.borders.bottom.color &&\n baseStyle.borders.bottom.lineStyle === toCompareStyle.borders.bottom.lineStyle));\n if (result) {\n index = baseStyle.index;\n break;\n }\n }\n return { index: index, result: result };\n };\n Workbook.prototype.contains = function (array, item) {\n var index = array.indexOf(item);\n return index > -1 && index < array.length;\n };\n Workbook.prototype.getCellValueType = function (value) {\n if (value instanceof Date) {\n return 'datetime';\n }\n else if (typeof (value) === 'boolean') {\n return 'boolean';\n }\n else if (typeof (value) === 'number') {\n return 'number';\n }\n else {\n return 'string';\n }\n };\n Workbook.prototype.parseCellType = function (cell) {\n var type = cell.type;\n var saveType;\n var value = cell.value;\n switch (type) {\n case 'datetime':\n value = this.toOADate(value);\n if (cell.cellStyle !== undefined && cell.cellStyle.name !== undefined) {\n if (this.globalStyles.has(cell.cellStyle.name)) {\n var value_1 = this.globalStyles.get(cell.cellStyle.name);\n this.switchNumberFormat(value_1.format, value_1.type);\n }\n }\n saveType = 'n';\n break;\n //TODO: Update the number format index and style\n case 'boolean':\n value = value ? 1 : 0;\n saveType = 'b';\n break;\n case 'number':\n saveType = 'n';\n if (cell.cellStyle !== undefined && cell.cellStyle.name !== undefined) {\n if (this.globalStyles.has(cell.cellStyle.name)) {\n this.switchNumberFormat(this.globalStyles.get(cell.cellStyle.name).format, 'number');\n }\n }\n break;\n case 'string':\n this.sharedStringCount++;\n saveType = 's';\n var sstvalue = this.processCellValue(value, cell);\n if (!this.contains(this.sharedString, sstvalue)) {\n this.sharedString.push(sstvalue);\n }\n value = this.sharedString.indexOf(sstvalue);\n break;\n default:\n break;\n }\n cell.saveType = saveType;\n cell.value = value;\n };\n Workbook.prototype.parserImages = function (json, sheet) {\n var imagesLength = json.length;\n sheet.images = [];\n var imageId = 0;\n for (var p = 0; p < imagesLength; p++) {\n var image = this.parserImage(json[p]);\n sheet.images.push(image);\n }\n };\n Workbook.prototype.parseFilters = function (json, sheet) {\n sheet.autoFilters = new AutoFilters();\n if (json.row !== null && json.row !== undefined)\n sheet.autoFilters.row = json.row;\n else\n throw new Error('Argument Null Exception: row null or empty');\n if (json.lastRow !== null && json.lastRow !== undefined)\n sheet.autoFilters.lastRow = json.lastRow;\n else\n throw new Error('Argument Null Exception: lastRow cannot be null or empty');\n if (json.column !== null && json.column !== undefined)\n sheet.autoFilters.column = json.column;\n else\n throw new Error('Argument Null Exception: column cannot be null or empty');\n if (json.lastColumn !== null && json.row !== undefined)\n sheet.autoFilters.lastColumn = json.lastColumn;\n else\n throw new Error('Argument Null Exception: lastColumn cannot be null or empty');\n };\n Workbook.prototype.parserImage = function (json) {\n var image = new Image();\n if (json.image !== null && json.image !== undefined) {\n image.image = json.image;\n }\n if (json.row !== null && json.row !== undefined) {\n image.row = json.row;\n }\n if (json.column !== null && json.column !== undefined) {\n image.column = json.column;\n }\n if (json.lastRow !== null && json.lastRow !== undefined) {\n image.lastRow = json.lastRow;\n }\n if (json.lastColumn !== null && json.lastColumn !== undefined) {\n image.lastColumn = json.lastColumn;\n }\n if (json.width !== null && json.width !== undefined) {\n image.width = json.width;\n }\n if (json.height !== null && json.height !== undefined) {\n image.height = json.height;\n }\n if (json.horizontalFlip !== null && json.horizontalFlip !== undefined) {\n image.horizontalFlip = json.horizontalFlip;\n }\n if (json.verticalFlip !== null && json.verticalFlip !== undefined) {\n image.verticalFlip = json.verticalFlip;\n }\n if (json.rotation !== null && json.rotation !== undefined) {\n image.rotation = json.rotation;\n }\n return image;\n };\n /**\n * Returns a Promise with a Blob based on the specified BlobSaveType and optional encoding.\n * @param {BlobSaveType} blobSaveType - A string indicating the type of Blob to generate ('text/csv' or other).\n * @param {string} [encodingType] - The supported encoding types are \"ansi\", \"unicode\" and \"utf8\".\n */\n /* tslint:disable:no-any */\n Workbook.prototype.saveAsBlob = function (blobSaveType, encodingType) {\n var _this = this;\n switch (blobSaveType) {\n case 'text/csv':\n return new Promise(function (resolve, reject) {\n var obj = {};\n obj.blobData = _this.csvHelper.saveAsBlob(encodingType);\n resolve(obj);\n });\n default:\n return new Promise(function (resolve, reject) {\n _this.saveInternal();\n _this.mArchive.saveAsBlob().then(function (blob) {\n var obj = {};\n obj.blobData = new Blob([blob], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' });\n resolve(obj);\n });\n });\n }\n };\n Workbook.prototype.save = function (fileName, proxyUrl) {\n var _this = this;\n if (fileName === null || fileName === undefined || fileName === '') {\n throw new Error('Argument Null Exception: fileName cannot be null or empty');\n }\n var xlsxMatch = fileName.match('.xlsx$');\n var csvMatch = fileName.match('.csv$');\n if (xlsxMatch !== null && xlsxMatch[0] === ('.' + this.mSaveType)) {\n this.saveInternal();\n this.mArchive.save(fileName).then(function () {\n _this.mArchive.destroy();\n });\n }\n else if (csvMatch !== null && csvMatch[0] === ('.' + this.mSaveType)) {\n this.csvHelper.save(fileName);\n }\n else {\n throw Error('Save type and file extension is different.');\n }\n };\n Workbook.prototype.saveInternal = function () {\n this.saveWorkbook();\n this.saveWorksheets();\n this.saveSharedString();\n this.saveStyles();\n this.saveApp(this.builtInProperties);\n this.saveCore(this.builtInProperties);\n this.saveContentType();\n this.saveTopLevelRelation();\n this.saveWorkbookRelation();\n };\n Workbook.prototype.saveWorkbook = function () {\n /* tslint:disable-next-line:max-line-length */\n var workbookTemp = '<?xml version=\"1.0\" encoding=\"utf-8\"?><workbook xmlns:r = \"http://schemas.openxmlformats.org/officeDocument/2006/relationships\" xmlns= \"http://schemas.openxmlformats.org/spreadsheetml/2006/main\"><workbookPr codeName=\"ThisWorkbook\" defaultThemeVersion= \"153222\"/><bookViews><workbookView activeTab=\"0\"/></bookViews>';\n var sheets = '<sheets>';\n var length = this.worksheets.length;\n for (var i = 0; i < length; i++) {\n /* tslint:disable-next-line:max-line-length */\n var sheetName = this.worksheets[i].name;\n sheetName = sheetName.replace(\"&\", \"&\");\n sheetName = sheetName.replace(\"<\", \"<\");\n sheetName = sheetName.replace(\">\", \">\");\n sheetName = sheetName.replace(\"\\\"\", \""\");\n sheets += '<sheet name=\"' + sheetName + '\" sheetId=\"' + (i + 1).toString() + '\" r:id =\"rId' + (i + 1).toString() + '\" />';\n }\n sheets += '</sheets>';\n workbookTemp += sheets;\n if (this.printTitles.size > 0) {\n var printTitle_1 = '<definedNames>';\n this.printTitles.forEach(function (value, key) {\n printTitle_1 += '<definedName name=\"_xlnm.Print_Titles\" localSheetId=\"' + key + '\">' + value + '</definedName>';\n });\n printTitle_1 += '</definedNames>';\n workbookTemp += printTitle_1;\n }\n this.addToArchive(workbookTemp + '</workbook>', 'xl/workbook.xml');\n };\n Workbook.prototype.saveWorksheets = function () {\n var length = this.worksheets.length;\n for (var i = 0; i < length; i++) {\n this.saveWorksheet(this.worksheets[i], i);\n }\n };\n Workbook.prototype.saveWorksheet = function (sheet, index) {\n var sheetBlob = new BlobHelper();\n /* tslint:disable-next-line:max-line-length */\n var sheetString = '<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?><worksheet xmlns:r=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships\" xmlns:x14=\"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main\" xmlns:mc=\"http://schemas.openxmlformats.org/markup-compatibility/2006\" xmlns=\"http://schemas.openxmlformats.org/spreadsheetml/2006/main\">';\n if (!sheet.isSummaryRowBelow) {\n sheetString += ('<sheetPr>' + '<outlinePr ' + 'summaryBelow=\"0\" >' + '</outlinePr>' + '</sheetPr>');\n }\n else {\n sheetString += ('<sheetPr />');\n }\n sheetString += this.saveSheetView(sheet);\n if (sheet.columns !== undefined) {\n var colString = '<cols>';\n for (var _i = 0, _a = sheet.columns; _i < _a.length; _i++) {\n var column = _a[_i];\n /* tslint:disable-next-line:max-line-length */\n if (column.width !== undefined) {\n colString += '<col min=\"' + (column.index) + '\" max=\"' + (column.index) + '\" width=\"' + this.pixelsToColumnWidth(column.width) + '\" customWidth=\"1\" />';\n }\n else {\n colString += '<col min=\"' + (column.index) + '\" max=\"' + (column.index) + '\" width=\"' + '8.43' + '\" customWidth=\"1\" />';\n }\n }\n sheetString += (colString + '</cols>');\n }\n sheetString += ('<sheetData>');\n sheetBlob.append(sheetString);\n sheetString = '';\n if (sheet.rows !== undefined) {\n for (var _b = 0, _c = sheet.rows; _b < _c.length; _b++) {\n var row = _c[_b];\n var rowString = '<row r=\"' + (row.index) + '\" ';\n if (!isNullOrUndefined(row.spans)) {\n rowString += 'spans=\"' + row.spans + '\" ';\n }\n if (row.height !== undefined) {\n rowString += ('ht=\"' + this.pixelsToRowHeight(row.height) + '\" customHeight=\"1\" ');\n }\n if (row.grouping !== undefined) {\n if (row.grouping.isHidden) {\n rowString += ('hidden=\"1\" ');\n }\n if (row.grouping.outlineLevel !== undefined) {\n rowString += ('outlineLevel=\"' + row.grouping.outlineLevel + '\" ');\n }\n if (row.grouping.isCollapsed) {\n rowString += ('collapsed=\"1\" ');\n }\n }\n rowString += ('>');\n for (var _d = 0, _e = row.cells; _d < _e.length; _d++) {\n var cell = _e[_d];\n if (cell !== undefined && (cell.value !== undefined || cell.cellStyle !== undefined)) {\n rowString += ('<c r=\"' + cell.refName + '\" ');\n if (cell.saveType !== undefined) {\n rowString += ('t=\"' + cell.saveType + '\" ');\n }\n if (cell.styleIndex !== undefined) {\n rowString += ('s=\"' + cell.styleIndex + '\" ');\n }\n rowString += (' >');\n if (cell.formula !== undefined) {\n rowString += ('<f>' + cell.formula + '</f>');\n }\n if (cell.value !== undefined) {\n rowString += ('<v>' + cell.value + '</v></c>');\n }\n else {\n rowString += ('</c>');\n }\n }\n }\n rowString += ('</row>');\n sheetBlob.append(rowString);\n }\n }\n sheetString += ('</sheetData>');\n /* tslint:disable-next-line:max-line-length */\n if (sheet.autoFilters !== null && sheet.autoFilters !== undefined)\n sheetString += ('<autoFilter ref=\"' + this.getCellName(sheet.autoFilters.row, sheet.autoFilters.column) + ':' + this.getCellName(sheet.autoFilters.lastRow, sheet.autoFilters.lastColumn) + '\"/>');\n if (sheet.mergeCells.length > 0) {\n sheetString += ('<mergeCells count=\"' + sheet.mergeCells.length + '\">');\n for (var _f = 0, _g = sheet.mergeCells; _f < _g.length; _f++) {\n var mCell = _g[_f];\n sheetString += ('<mergeCell ref=\"' + mCell.ref + '\" />');\n }\n sheetString += ('</mergeCells>');\n }\n if (sheet.hyperLinks.length > 0) {\n sheetString += ('<hyperlinks>');\n for (var _h = 0, _j = sheet.hyperLinks; _h < _j.length; _h++) {\n var hLink = _j[_h];\n sheetString += ('<hyperlink ref=\"' + hLink.ref + '\" r:id=\"rId' + hLink.rId + '\" />');\n }\n sheetString += ('</hyperlinks>');\n }\n /* tslint:disable-next-line:max-line-length */\n sheetString += ('<pageMargins left=\"0.75\" right=\"0.75\" top=\"1\" bottom=\"1\" header=\"0.5\" footer=\"0.5\" /><headerFooter scaleWithDoc=\"1\" alignWithMargins=\"0\" differentFirst=\"0\" differentOddEven=\"0\" />');\n if (sheet.images != undefined && sheet.images.length > 0) {\n this.drawingCount++;\n this.saveDrawings(sheet, sheet.index);\n sheetString += '<drawing r:id=\"rId' + (sheet.hyperLinks.length + 1) + '\"/>';\n }\n this.addToArchive(this.saveSheetRelations(sheet), ('xl/worksheets/_rels/sheet' + sheet.index + '.xml.rels'));\n sheetBlob.append(sheetString + '</worksheet>');\n this.addToArchive(sheetBlob.getBlob(), 'xl/worksheets' + '/sheet' + (index + 1) + '.xml');\n };\n Workbook.prototype.saveDrawings = function (sheet, index) {\n var drawings = new BlobHelper();\n /* tslint:disable-next-line:max-line-length */\n var sheetDrawingString = '<xdr:wsDr xmlns:xdr=\"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing\" xmlns:a=\"http://schemas.openxmlformats.org/drawingml/2006/main\">';\n if (sheet.images !== undefined) {\n var imgId = 0;\n for (var _i = 0, _a = sheet.images; _i < _a.length; _i++) {\n var pic = _a[_i];\n if (pic.height !== undefined && pic.width !== undefined) {\n this.updatelastRowOffset(sheet, pic);\n this.updatelastColumnOffSet(sheet, pic);\n pic.lastRow -= 1;\n pic.lastColumn -= 1;\n }\n else if (pic.lastRow !== undefined && pic.lastColumn !== undefined) {\n pic.lastRowOffset = 0;\n pic.lastColOffset = 0;\n }\n imgId++;\n sheetDrawingString += '<xdr:twoCellAnchor editAs=\"oneCell\">';\n sheetDrawingString += '<xdr:from><xdr:col>';\n //col\n sheetDrawingString += pic.column - 1;\n sheetDrawingString += '</xdr:col><xdr:colOff>';\n //colOff\n sheetDrawingString += 0;\n sheetDrawingString += '</xdr:colOff><xdr:row>';\n //row\n sheetDrawingString += pic.row - 1;\n sheetDrawingString += '</xdr:row><xdr:rowOff>';\n //rowOff\n sheetDrawingString += 0;\n sheetDrawingString += '</xdr:rowOff></xdr:from>';\n sheetDrawingString += '<xdr:to><xdr:col>';\n //col\n sheetDrawingString += pic.lastColumn;\n sheetDrawingString += '</xdr:col><xdr:colOff>';\n //colOff\n sheetDrawingString += pic.lastColOffset;\n sheetDrawingString += '</xdr:colOff><xdr:row>';\n //row\n sheetDrawingString += pic.lastRow;\n sheetDrawingString += '</xdr:row><xdr:rowOff>';\n //rowOff\n sheetDrawingString += pic.lastRowOffset;\n sheetDrawingString += '</xdr:rowOff></xdr:to>';\n sheetDrawingString += '<xdr:pic>';\n sheetDrawingString += '<xdr:nvPicPr>';\n sheetDrawingString += '<xdr:cNvPr id=\"' + imgId + '\" name=\"Picture ' + imgId + '\"> </xdr:cNvPr>';\n sheetDrawingString += '<xdr:cNvPicPr><a:picLocks noChangeAspect=\"1\"/></xdr:cNvPicPr> </xdr:nvPicPr>';\n sheetDrawingString += '<xdr:blipFill>';\n /* tslint:disable-next-line:max-line-length */\n sheetDrawingString += '<a:blip xmlns:r=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships\" r:embed=\"rId' + imgId + '\" cstate=\"print\">';\n sheetDrawingString += '</a:blip><a:stretch><a:fillRect /></a:stretch></xdr:blipFill>';\n sheetDrawingString += '<xdr:spPr>';\n sheetDrawingString += '<a:xfrm';\n if (pic.rotation != undefined && pic.rotation <= 3600 && pic.rotation >= -3600) {\n sheetDrawingString += ' rot=\"' + (pic.rotation * 60000) + '\"';\n }\n if (pic.verticalFlip != undefined && pic.verticalFlip != false) {\n sheetDrawingString += ' flipV=\"1\"';\n }\n if (pic.horizontalFlip != undefined && pic.horizontalFlip != false) {\n sheetDrawingString += ' flipH=\"1\"';\n }\n sheetDrawingString += '/>';\n sheetDrawingString += '<a:prstGeom prst=\"rect\"><a:avLst /></a:prstGeom></xdr:spPr>';\n sheetDrawingString += '</xdr:pic><xdr:clientData /></xdr:twoCellAnchor>';\n var imageFile = new BlobHelper();\n var imageData = this.convertBase64toImage(pic.image);\n this.imageCount += 1;\n this.addToArchive(imageData, 'xl/media/image' + this.imageCount + '.png');\n }\n drawings.append(sheetDrawingString);\n drawings.append('</xdr:wsDr>');\n this.saveDrawingRelations(sheet);\n this.addToArchive(drawings.getBlob(), 'xl/drawings/drawing' + this.drawingCount + '.xml');\n }\n };\n Workbook.prototype.updatelastRowOffset = function (sheet, picture) {\n var iCurHeight = picture.height;\n var iCurRow = picture.row;\n var iCurOffset = 0;\n while (iCurHeight >= 0) {\n var iRowHeight = 0;\n if (sheet.rows !== undefined && sheet.rows[iCurRow - 1] !== undefined)\n iRowHeight = this.convertToPixels(sheet.rows[iCurRow - 1].height === undefined ? 15 : sheet.rows[iCurRow - 1].height);\n else\n iRowHeight = this.convertToPixels(15);\n var iSpaceInCell = iRowHeight - (iCurOffset * iRowHeight / 256);\n if (iSpaceInCell > iCurHeight) {\n picture.lastRow = iCurRow;\n picture.lastRowOffset = iCurOffset + (iCurHeight * 256 / iRowHeight);\n var rowHiddenHeight = 0;\n if (sheet.rows !== undefined && sheet.rows[iCurRow - 1] !== undefined)\n rowHiddenHeight = this.convertToPixels(sheet.rows[iCurRow - 1].height === undefined ? 15 : sheet.rows[iCurRow - 1].height);\n else\n rowHiddenHeight = this.convertToPixels(15);\n picture.lastRowOffset = (rowHiddenHeight * picture.lastRowOffset) / 256;\n picture.lastRowOffset = Math.round(picture.lastRowOffset / this.unitsProportions[7]);\n break;\n }\n else {\n iCurHeight -= iSpaceInCell;\n iCurRow++;\n iCurOffset = 0;\n }\n }\n };\n Workbook.prototype.updatelastColumnOffSet = function (sheet, picture) {\n var iCurWidth = picture.width;\n var iCurCol = picture.column;\n var iCurOffset = 0;\n while (iCurWidth >= 0) {\n var iColWidth = 0;\n if (sheet.columns !== undefined && sheet.columns[iCurCol - 1] !== undefined)\n iColWidth = this.ColumnWidthToPixels(sheet.columns[iCurCol - 1].width === undefined ? 8.43 : sheet.columns[iCurCol - 1].width);\n else\n iColWidth = this.ColumnWidthToPixels(8.43);\n var iSpaceInCell = iColWidth - (iCurOffset * iColWidth / 1024);\n if (iSpaceInCell > iCurWidth) {\n picture.lastColumn = iCurCol;\n picture.lastColOffset = iCurOffset + (iCurWidth * 1024 / iColWidth);\n var colHiddenWidth = 0;\n if (sheet.columns !== undefined && sheet.columns[iCurCol - 1] !== undefined)\n colHiddenWidth = this.ColumnWidthToPixels(sheet.columns[iCurCol - 1].width === undefined ? 8.43 : sheet.columns[iCurCol - 1].width);\n else\n colHiddenWidth = this.ColumnWidthToPixels(8.43);\n picture.lastColOffset = (colHiddenWidth * picture.lastColOffset) / 1024;\n picture.lastColOffset = Math.round(picture.lastColOffset / this.unitsProportions[7]);\n break;\n }\n else {\n iCurWidth -= iSpaceInCell;\n iCurCol++;\n iCurOffset = 0;\n }\n }\n };\n Workbook.prototype.convertToPixels = function (value) {\n return value * this.unitsProportions[6];\n };\n Workbook.prototype.convertBase64toImage = function (img) {\n var byteStr = window.atob(img);\n var buffer = new ArrayBuffer(byteStr.length);\n var data = new Uint8Array(buffer);\n for (var i = 0; i < byteStr.length; i++) {\n data[i] = byteStr.charCodeAt(i);\n }\n var blob = new Blob([data], { type: 'image/png' });\n return blob;\n };\n Workbook.prototype.saveDrawingRelations = function (sheet) {\n /* tslint:disable-next-line:max-line-length */\n var drawingRelation = '<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?><Relationships xmlns=\"http://schemas.openxmlformats.org/package/2006/relationships\">';\n var length = sheet.images.length;\n var id = this.imageCount - sheet.images.length;\n for (var i = 1; i <= length; i++) {\n id++;\n /* tslint:disable-next-line:max-line-length */\n drawingRelation += '<Relationship Id=\"rId' + i + '\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image\" Target=\"../media/image' + id + '.png\" />';\n }\n this.addToArchive((drawingRelation + '</Relationships>'), 'xl/drawings/_rels/drawing' + this.drawingCount + '.xml.rels');\n };\n Workbook.prototype.pixelsToColumnWidth = function (pixels) {\n var dDigitWidth = 7;\n var val = (pixels > dDigitWidth + 5) ?\n this.trunc((pixels - 5) / dDigitWidth * 100 + 0.5) / 100 :\n pixels / (dDigitWidth + 5);\n return (val > 1) ?\n ((val * dDigitWidth + 5) / dDigitWidth * 256.0) / 256.0 :\n (val * (dDigitWidth + 5) / dDigitWidth * 256.0) / 256.0;\n };\n Workbook.prototype.ColumnWidthToPixels = function (val) {\n var dDigitWidth = 7;\n var fileWidth = (val > 1) ?\n ((val * dDigitWidth + 5) / dDigitWidth * 256.0) / 256.0 :\n (val * (dDigitWidth + 5) / dDigitWidth * 256.0) / 256.0;\n return this.trunc(((256 * fileWidth + this.trunc(128 / dDigitWidth)) / 256) * dDigitWidth);\n };\n Workbook.prototype.trunc = function (x) {\n var n = x - x % 1;\n return n === 0 && (x < 0 || (x === 0 && (1 / x !== 1 / 0))) ? -0 : n;\n };\n Workbook.prototype.pixelsToRowHeight = function (pixels) {\n return (pixels * this.unitsProportions[5] / this.unitsProportions[6]);\n };\n Workbook.prototype.saveSheetRelations = function (sheet) {\n /* tslint:disable-next-line:max-line-length */\n var relStr = '<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?><Relationships xmlns=\"http://schemas.openxmlformats.org/package/2006/relationships\">';\n for (var _i = 0, _a = sheet.hyperLinks; _i < _a.length; _i++) {\n var hLink = _a[_i];\n /* tslint:disable-next-line:max-line-length */\n relStr += '<Relationship Id=\"rId' + hLink.rId + '\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink\" Target=\"' + this.processString(hLink.target) + '\" TargetMode=\"External\" />';\n }\n if (sheet.images != undefined && sheet.images.length > 0) {\n /* tslint:disable-next-line:max-line-length */\n relStr += '<Relationship Id=\"rId' + (sheet.hyperLinks.length + 1) + '\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing\" Target=\"../drawings/drawing' + this.drawingCount + '.xml\" />';\n }\n relStr += '</Relationships>';\n return relStr;\n };\n Workbook.prototype.saveSheetView = function (sheet) {\n var paneString = '<sheetViews><sheetView workbookViewId=\"0\" ';\n if (sheet.enableRtl === true) {\n paneString += 'rightToLeft=\"1\"';\n }\n if (sheet.showGridLines === false) {\n paneString += 'showGridLines=\"0\" >';\n }\n else {\n paneString += '>';\n }\n if (sheet.freezePanes !== undefined) {\n paneString += '<pane state=\"frozen\"' +\n ' topLeftCell=\"' + sheet.freezePanes.leftCell + '\" ';\n if (sheet.freezePanes.row !== 0) {\n paneString += 'ySplit=\"' + sheet.freezePanes.row + '\" ';\n }\n if (sheet.freezePanes.column !== 0) {\n paneString += 'xSplit=\"' + sheet.freezePanes.column + '\" ';\n }\n paneString += '/>';\n }\n paneString += '</sheetView></sheetViews > ';\n return paneString;\n };\n Workbook.prototype.saveSharedString = function () {\n var length = this.sharedString.length;\n if (length > 0) {\n /* tslint:disable-next-line:max-line-length */\n var sstStart = '<?xml version=\"1.0\" encoding=\"utf-8\"?><sst uniqueCount=\"' + length + '\" count=\"' + this.sharedStringCount + '\" xmlns=\"http://schemas.openxmlformats.org/spreadsheetml/2006/main\">';\n var si = '';\n for (var i = 0; i < length; i++) {\n if (this.sharedString[i].indexOf('<r>') !== 0) {\n si += '<si><t>';\n si += this.processString(this.sharedString[i]);\n si += '</t></si>';\n }\n else {\n si += '<si>';\n si += this.sharedString[i];\n si += '</si>';\n }\n }\n si += '</sst>';\n this.addToArchive(sstStart + si, 'xl/sharedStrings.xml');\n }\n };\n Workbook.prototype.processString = function (value) {\n if (typeof value == \"string\") {\n if (value.indexOf('&') !== -1) {\n value = value.replace(/&/g, '&');\n }\n if (value.indexOf('<') !== -1) {\n value = value.replace(/</g, '<');\n }\n if (value.indexOf('>') !== -1) {\n value = value.replace(/>/g, '>');\n }\n if (value.indexOf('\\v') !== -1) {\n value = value.replace(/\\v/g, '_x000B_');\n }\n }\n else if (typeof value == \"object\") {\n for (var i = 0; i < value.length; i++) {\n if (value[i].indexOf('&') !== -1) {\n value[i] = value[i].replace(/&/g, '&');\n }\n if (value[i].indexOf('<') !== -1) {\n value[i] = value[i].replace(/</g, '<');\n }\n if (value[i].indexOf('>') !== -1) {\n value[i] = value[i].replace(/>/g, '>');\n }\n if (value[i].indexOf('\\v') !== -1) {\n value[i] = value[i].replace(/\\v/g, '_x000B_');\n }\n }\n }\n return value;\n };\n Workbook.prototype.saveStyles = function () {\n this.updateCellXfsStyleXfs();\n /* tslint:disable-next-line:max-line-length */\n var styleTemp = '<?xml version=\"1.0\" encoding=\"utf-8\"?><styleSheet xmlns:mc=\"http://schemas.openxmlformats.org/markup-compatibility/2006\" mc:Ignorable=\"x14ac\" xmlns:x14ac=\"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac\" xmlns=\"http://schemas.openxmlformats.org/spreadsheetml/2006/main\">';\n styleTemp += this.saveNumberFormats();\n styleTemp += this.saveFonts();\n styleTemp += this.saveFills();\n styleTemp += this.saveBorders();\n styleTemp += this.saveCellStyleXfs();\n styleTemp += this.saveCellXfs();\n styleTemp += this.saveCellStyles();\n this.addToArchive(styleTemp + '</styleSheet>', 'xl/styles.xml');\n };\n Workbook.prototype.updateCellXfsStyleXfs = function () {\n for (var _i = 0, _a = this.mStyles; _i < _a.length; _i++) {\n var style = _a[_i];\n var cellXfs = undefined;\n if (style.isGlobalStyle) {\n cellXfs = new CellStyleXfs();\n cellXfs.xfId = (style.index - 1);\n }\n else {\n cellXfs = new CellXfs();\n cellXfs.xfId = 0;\n }\n //Add font\n var compareFontResult = this.isNewFont(style);\n if (!compareFontResult.result) {\n var font = new Font();\n font.b = style.bold;\n font.i = style.italic;\n font.name = style.fontName;\n font.sz = style.fontSize;\n font.u = style.underline;\n font.strike = style.strikeThrough;\n font.color = ('FF' + style.fontColor.replace('#', ''));\n this.mFonts.push(font);\n cellXfs.fontId = this.mFonts.length - 1;\n }\n else {\n cellXfs.fontId = compareFontResult.index;\n }\n //Add fill\n if (style.backColor !== 'none') {\n var backColor = 'FF' + style.backColor.replace('#', '');\n if (this.mFills.has(backColor)) {\n var fillId = this.mFills.get(backColor);\n cellXfs.fillId = fillId;\n }\n else {\n var fillId = this.mFills.size + 2;\n this.mFills.set(backColor, fillId);\n cellXfs.fillId = (fillId);\n }\n }\n else {\n cellXfs.fillId = 0;\n }\n //Add border \n if (!this.isNewBorder(style)) {\n this.mBorders.push(style.borders);\n cellXfs.borderId = this.mBorders.length;\n }\n else {\n cellXfs.borderId = 0;\n }\n //Add Number Format \n if (style.numberFormat !== 'GENERAL') {\n if (this.mNumFmt.has(style.numberFormat)) {\n var numFmt = this.mNumFmt.get(style.numberFormat);\n cellXfs.numFmtId = numFmt.numFmtId;\n }\n else {\n var id = this.mNumFmt.size + 164;\n this.mNumFmt.set(style.numberFormat, new NumFmt(id, style.numberFormat));\n cellXfs.numFmtId = id;\n }\n }\n else {\n if (style.numberFormat === 'GENERAL' && style.numFmtId === 14) {\n cellXfs.numFmtId = 14;\n }\n else {\n cellXfs.numFmtId = 0;\n }\n }\n //Add alignment \n if (!style.isGlobalStyle) {\n cellXfs.applyAlignment = 1;\n }\n cellXfs.alignment = new Alignment();\n cellXfs.alignment.indent = style.indent;\n cellXfs.alignment.horizontal = style.hAlign;\n cellXfs.alignment.vertical = style.vAlign;\n cellXfs.alignment.wrapText = style.wrapText ? 1 : 0;\n cellXfs.alignment.rotation = style.rotation;\n if (style.isGlobalStyle) {\n this.mCellStyleXfs.push(cellXfs);\n this.mCellXfs.push(cellXfs);\n }\n else {\n //Add cellxfs\n this.mCellXfs.push(cellXfs);\n }\n }\n };\n Workbook.prototype.saveNumberFormats = function () {\n if (this.mNumFmt.size >= 1) {\n var numFmtStyle_1 = '<numFmts count=\"' + (this.mNumFmt.size) + '\">';\n this.mNumFmt.forEach(function (value, key) {\n numFmtStyle_1 += '<numFmt numFmtId=\"' + value.numFmtId + '\" formatCode=\"' + value.formatCode.replace(/\"/g, '"') + '\" />';\n });\n return (numFmtStyle_1 += '</numFmts>');\n }\n else {\n return '';\n }\n };\n Workbook.prototype.saveFonts = function () {\n /* tslint:disable-next-line:max-line-length */\n var fontStyle = '<fonts count=\"' + (this.mFonts.length) + '\">';\n if (this.mFonts.length >= 1) {\n for (var _i = 0, _a = this.mFonts; _i < _a.length; _i++) {\n var font = _a[_i];\n fontStyle += '<font>';\n if (font.b) {\n fontStyle += '<b />';\n }\n if (font.i) {\n fontStyle += '<i />';\n }\n if (font.u) {\n fontStyle += '<u />';\n }\n if (font.strike) {\n fontStyle += '<strike />';\n }\n fontStyle += '<sz val=\"' + font.sz + '\" />';\n fontStyle += '<color rgb=\"' + font.color + '\" />';\n fontStyle += '<name val=\"' + font.name + '\" /></font>';\n }\n }\n return fontStyle + '</fonts>';\n };\n Workbook.prototype.saveFills = function () {\n /* tslint:disable-next-line:max-line-length */\n var fillsStyle = '<fills count=\"' + (this.mFills.size + 2) + '\"><fill><patternFill patternType=\"none\"></patternFill></fill><fill><patternFill patternType=\"gray125\"></patternFill></fill>';\n if (this.mFills.size >= 1) {\n this.mFills.forEach(function (value, key) {\n /* tslint:disable-next-line:max-line-length */\n fillsStyle += '<fill><patternFill patternType=\"solid\"><fgColor rgb=\"' + key + '\" /><bgColor rgb=\"FFFFFFFF\" /></patternFill></fill>';\n });\n }\n return fillsStyle + '</fills>';\n };\n Workbook.prototype.saveBorders = function () {\n /* tslint:disable-next-line:max-line-length */\n var bordersStyle = '<borders count=\"' + (this.mBorders.length + 1) + '\"><border><left /><right /><top /><bottom /><diagonal /></border>';\n if (this.mBorders.length >= 1) {\n for (var _i = 0, _a = this.mBorders; _i < _a.length; _i++) {\n var borders = _a[_i];\n if (this.isAllBorder(borders)) {\n var color = borders.all.color.replace('#', '');\n var lineStyle = borders.all.lineStyle;\n /* tslint:disable-next-line:max-line-length */\n bordersStyle += '<border><left style=\"' + lineStyle + '\"><color rgb=\"FF' + color + '\" /></left><right style=\"' + lineStyle + '\"><color rgb=\"FF' + color + '\" /></right><top style=\"' + lineStyle + '\"><color rgb=\"FF' + color + '\" /></top><bottom style=\"' + lineStyle + '\"><color rgb=\"FF' + color + '\" /></bottom></border>';\n }\n else {\n /* tslint:disable-next-line:max-line-length */\n bordersStyle += '<border><left style=\"' + borders.left.lineStyle + '\"><color rgb=\"FF' + borders.left.color.replace('#', '') + '\" /></left><right style=\"' + borders.right.lineStyle + '\"><color rgb=\"FF' + borders.right.color.replace('#', '') + '\" /></right><top style=\"' + borders.top.lineStyle + '\"><color rgb=\"FF' + borders.top.color.replace('#', '') + '\" /></top><bottom style=\"' + borders.bottom.lineStyle + '\"><color rgb=\"FF' + borders.bottom.color.replace('#', '') + '\" /></bottom></border>';\n }\n }\n }\n return bordersStyle + '</borders>';\n };\n Workbook.prototype.saveCellStyles = function () {\n var _this = this;\n var cellStyleString = '<cellStyles count=\"' + (this.cellStyles.size) + '\">';\n this.cellStyles.forEach(function (value, key) {\n cellStyleString += '<cellStyle name=\"' + key + '\" xfId=\"' + _this.cellStyles.get(key).xfId + '\"';\n if (key === 'Normal') {\n cellStyleString += ' builtinId=\"0\"';\n }\n cellStyleString += ' />';\n });\n return cellStyleString += '</cellStyles>';\n };\n Workbook.prototype.saveCellStyleXfs = function () {\n /* tslint:disable-next-line:max-line-length */\n var cellXfsStyle = '<cellStyleXfs count=\"' + (this.mCellStyleXfs.length + 1) + '\"><xf numFmtId=\"0\" fontId=\"0\" fillId=\"0\" borderId=\"0\" />';\n if (this.mCellStyleXfs.length >= 1) {\n for (var _i = 0, _a = this.mCellStyleXfs; _i < _a.length; _i++) {\n var cellStyleXf = _a[_i];\n /* tslint:disable-next-line:max-line-length */\n cellXfsStyle += '<xf numFmtId=\"' + cellStyleXf.numFmtId + '\" fontId=\"' + cellStyleXf.fontId + '\" fillId=\"' + cellStyleXf.fillId + '\" borderId=\"' + cellStyleXf.borderId + '\" ';\n if (cellStyleXf.alignment !== undefined) {\n cellXfsStyle += '>' + this.saveAlignment(cellStyleXf) + '</xf>';\n }\n else {\n cellXfsStyle += ' />';\n }\n }\n }\n return cellXfsStyle + '</cellStyleXfs>';\n };\n Workbook.prototype.saveCellXfs = function () {\n /* tslint:disable-next-line:max-line-length */\n var cellXfsStyle = '<cellXfs count=\"' + (this.mCellXfs.length + 1) + '\"><xf numFmtId=\"0\" fontId=\"0\" fillId=\"0\" borderId=\"0\" xfId=\"0\" />';\n if (this.mCellXfs.length >= 1) {\n for (var _i = 0, _a = this.mCellXfs; _i < _a.length; _i++) {\n var cellXf = _a[_i];\n /* tslint:disable-next-line:max-line-length */\n cellXfsStyle += '<xf numFmtId=\"' + cellXf.numFmtId + '\" fontId=\"' + cellXf.fontId + '\" fillId=\"' + cellXf.fillId + '\" borderId=\"' + cellXf.borderId + '\" xfId=\"' + cellXf.xfId + '\" ';\n if (cellXf.applyAlignment === 1) {\n cellXfsStyle += 'applyAlignment=\"1\"';\n }\n cellXfsStyle += '>' + this.saveAlignment(cellXf) + '</xf>';\n }\n }\n return cellXfsStyle + '</cellXfs>';\n };\n Workbook.prototype.saveAlignment = function (cellXf) {\n var alignString = '<alignment ';\n if (cellXf.alignment.horizontal !== undefined) {\n alignString += 'horizontal=\"' + cellXf.alignment.horizontal + '\" ';\n }\n if (cellXf.alignment.indent !== undefined && cellXf.alignment.indent !== 0) {\n alignString += 'indent=\"' + cellXf.alignment.indent + '\" ';\n }\n else if (cellXf.alignment.rotation !== undefined && cellXf.alignment.rotation !== 0) {\n alignString += 'textRotation=\"' + cellXf.alignment.rotation + '\" ';\n }\n if (cellXf.alignment.vertical !== undefined) {\n alignString += 'vertical=\"' + cellXf.alignment.vertical + '\" ';\n }\n alignString += 'wrapText=\"' + cellXf.alignment.wrapText + '\" />';\n return alignString;\n };\n Workbook.prototype.saveApp = function (builtInProperties) {\n /* tslint:disable-next-line:max-line-length */\n var appString = '<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?><Properties xmlns=\"http://schemas.openxmlformats.org/officeDocument/2006/extended-properties\"><Application>Essential XlsIO</Application>';\n if (builtInProperties !== undefined) {\n if (builtInProperties.manager !== undefined) {\n appString += '<Manager>' + builtInProperties.manager + '</Manager>';\n }\n if (builtInProperties.company !== undefined) {\n appString += '<Company>' + builtInProperties.company + '</Company>';\n }\n }\n this.addToArchive((appString + '</Properties>'), 'docProps/app.xml');\n };\n Workbook.prototype.saveCore = function (builtInProperties) {\n var createdDate = new Date();\n /* tslint:disable-next-line:max-line-length */\n var coreString = '<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?><cp:coreProperties xmlns:dc=\"http://purl.org/dc/elements/1.1/\" xmlns:dcterms=\"http://purl.org/dc/terms/\" xmlns:dcmitype=\"http://purl.org/dc/dcmitype/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:cp=\"http://schemas.openxmlformats.org/package/2006/metadata/core-properties\">';\n if (this.builtInProperties !== undefined) {\n if (builtInProperties.author !== undefined) {\n coreString += '<dc:creator>' + builtInProperties.author + '</dc:creator>';\n }\n if (builtInProperties.subject !== undefined) {\n coreString += '<dc:subject>' + builtInProperties.subject + '</dc:subject>';\n }\n if (builtInProperties.category !== undefined) {\n coreString += '<cp:category>' + builtInProperties.category + '</cp:category>';\n }\n if (builtInProperties.comments !== undefined) {\n coreString += '<dc:description>' + builtInProperties.comments + '</dc:description>';\n }\n if (builtInProperties.title !== undefined) {\n coreString += '<dc:title>' + builtInProperties.title + '</dc:title>';\n }\n if (builtInProperties.tags !== undefined) {\n coreString += '<cp:keywords>' + builtInProperties.tags + '</cp:keywords>';\n }\n if (builtInProperties.status !== undefined) {\n coreString += '<cp:contentStatus>' + builtInProperties.status + '</cp:contentStatus>';\n }\n if (builtInProperties.createdDate !== undefined) {\n /* tslint:disable-next-line:max-line-length */\n coreString += '<dcterms:created xsi:type=\"dcterms:W3CDTF\">' + builtInProperties.createdDate.toISOString() + '</dcterms:created>';\n }\n else {\n coreString += '<dcterms:created xsi:type=\"dcterms:W3CDTF\">' + createdDate.toISOString() + '</dcterms:created>';\n }\n if (builtInProperties.modifiedDate !== undefined) {\n /* tslint:disable-next-line:max-line-length */\n coreString += '<dcterms:modified xsi:type=\"dcterms:W3CDTF\">' + builtInProperties.modifiedDate.toISOString() + '</dcterms:modified>';\n }\n else {\n coreString += '<dcterms:modified xsi:type=\"dcterms:W3CDTF\">' + createdDate.toISOString() + '</dcterms:modified>';\n }\n }\n else {\n coreString += '<dcterms:created xsi:type=\"dcterms:W3CDTF\">' + createdDate.toISOString() + '</dcterms:created>';\n coreString += '<dcterms:modified xsi:type=\"dcterms:W3CDTF\">' + createdDate.toISOString() + '</dcterms:modified>';\n }\n /* tslint:disable-next-line:max-line-length */\n coreString += '</cp:coreProperties>';\n this.addToArchive(coreString, 'docProps/core.xml');\n };\n Workbook.prototype.saveTopLevelRelation = function () {\n /* tslint:disable-next-line:max-line-length */\n var topRelation = '<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?><Relationships xmlns=\"http://schemas.openxmlformats.org/package/2006/relationships\"><Relationship Id=\"rId1\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument\" Target=\"xl/workbook.xml\" /><Relationship Id=\"rId2\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties\" Target=\"docProps/app.xml\" /><Relationship Id=\"rId3\" Type=\"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties\" Target=\"docProps/core.xml\" /></Relationships>';\n this.addToArchive(topRelation, '_rels/.rels');\n };\n Workbook.prototype.saveWorkbookRelation = function () {\n /* tslint:disable-next-line:max-line-length */\n var wbRelation = '<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?><Relationships xmlns=\"http://schemas.openxmlformats.org/package/2006/relationships\">';\n var length = this.worksheets.length;\n var count = 0;\n for (var i = 0; i < length; i++, count++) {\n /* tslint:disable-next-line:max-line-length */\n wbRelation += '<Relationship Id=\"rId' + (i + 1).toString() + '\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet\" Target=\"worksheets/sheet' + (i + 1).toString() + '.xml\" />';\n }\n /* tslint:disable-next-line:max-line-length */\n wbRelation += '<Relationship Id=\"rId' + (++count).toString() + '\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles\" Target=\"styles.xml\" />';\n if (this.sharedStringCount > 0) {\n /* tslint:disable-next-line:max-line-length */\n wbRelation += '<Relationship Id=\"rId' + (++count).toString() + '\" Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings\" Target=\"sharedStrings.xml\" />';\n }\n this.addToArchive((wbRelation + '</Relationships>'), 'xl/_rels/workbook.xml.rels');\n };\n Workbook.prototype.saveContentType = function () {\n /* tslint:disable-next-line:max-line-length */\n var contentTypeString = '<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?><Types xmlns=\"http://schemas.openxmlformats.org/package/2006/content-types\"><Default Extension=\"xml\" ContentType=\"application/xml\" /><Default Extension=\"rels\" ContentType=\"application/vnd.openxmlformats-package.relationships+xml\" /><Override PartName=\"/xl/styles.xml\" ContentType=\"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml\" /><Override PartName=\"/xl/workbook.xml\" ContentType=\"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml\" /><Override PartName=\"/docProps/app.xml\" ContentType=\"application/vnd.openxmlformats-officedocument.extended-properties+xml\" /><Override PartName=\"/docProps/core.xml\" ContentType=\"application/vnd.openxmlformats-package.core-properties+xml\" />';\n var sheetsOverride = '';\n var length = this.worksheets.length;\n var drawingIndex = 0;\n for (var i = 0; i < length; i++) {\n /* tslint:disable-next-line:max-line-length */\n sheetsOverride += '<Override PartName=\"/xl/worksheets/sheet' + (i + 1).toString() + '.xml\" ContentType=\"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml\" />';\n if (this.worksheets[i].images != undefined && this.worksheets[i].images.length > 0) {\n drawingIndex++;\n /* tslint:disable-next-line:max-line-length */\n sheetsOverride += '<Override PartName=\"/xl/drawings/drawing' + (drawingIndex).toString() + '.xml\" ContentType=\"application/vnd.openxmlformats-officedocument.drawing+xml\" />';\n }\n }\n if (this.imageCount > 0)\n sheetsOverride += '<Default Extension=\"png\" ContentType=\"image/png\" />';\n if (this.sharedStringCount > 0) {\n /* tslint:disable-next-line:max-line-length */\n contentTypeString += '<Override PartName=\"/xl/sharedStrings.xml\" ContentType=\"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml\" />';\n }\n this.addToArchive((contentTypeString + sheetsOverride + '</Types>'), '[Content_Types].xml');\n };\n Workbook.prototype.addToArchive = function (xmlString, itemName) {\n if (typeof (xmlString) === 'string') {\n var blob = new Blob([xmlString], { type: 'text/plain' });\n var archiveItem = new ZipArchiveItem(blob, itemName);\n this.mArchive.addItem(archiveItem);\n }\n else {\n var archiveItem = new ZipArchiveItem(xmlString, itemName);\n this.mArchive.addItem(archiveItem);\n }\n };\n Workbook.prototype.processMergeCells = function (cell, rowIndex, mergeCells) {\n if (cell.rowSpan !== 0 || cell.colSpan !== 0) {\n var mCell = new MergeCell();\n mCell.x = cell.index;\n mCell.width = cell.colSpan;\n mCell.y = rowIndex;\n mCell.height = cell.rowSpan;\n var startCell = this.getCellName(mCell.y, mCell.x);\n var endCell = this.getCellName(rowIndex + mCell.height, cell.index + mCell.width);\n mCell.ref = startCell + ':' + endCell;\n var mergedCell = mergeCells.add(mCell);\n var start = { x: mCell.x, y: mCell.y };\n var end = {\n x: (cell.index + mCell.width), y: (rowIndex + mCell.height)\n };\n this.updatedMergedCellStyles(start, end, cell);\n }\n return mergeCells;\n };\n Workbook.prototype.updatedMergedCellStyles = function (sCell, eCell, cell) {\n for (var x = sCell.x; x <= eCell.x; x++) {\n for (var y = sCell.y; y <= eCell.y; y++) {\n this.mergedCellsStyle.set(this.getCellName(y, x), { x: x, y: y, styleIndex: cell.styleIndex });\n }\n }\n };\n /**\n * Returns the tick count corresponding to the given year, month, and day.\n * @param year number value of year\n * @param month number value of month\n * @param day number value of day\n */\n Workbook.prototype.dateToTicks = function (year, month, day) {\n var ticksPerDay = 10000 * 1000 * 60 * 60 * 24;\n var daysToMonth365 = [0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365];\n var daysToMonth366 = [0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366];\n if (year >= 1 && year <= 9999 && month >= 1 && month <= 12) {\n var days = this.isLeapYear(year) ? daysToMonth366 : daysToMonth365;\n var y = year - 1;\n var n = y * 365 + ((y / 4) | 0) - ((y / 100) | 0) + ((y / 400) | 0) + days[month - 1] + day - 1;\n return n * ticksPerDay;\n }\n throw new Error('Not a valid date');\n };\n /**\n * Return the tick count corresponding to the given hour, minute, second.\n * @param hour number value of hour\n * @param minute number value if minute\n * @param second number value of second\n */\n Workbook.prototype.timeToTicks = function (hour, minute, second) {\n if (hour >= 0 && hour < 24 && minute >= 0 && minute < 60 && second >= 0 && second < 60) {\n var totalSeconds = hour * 3600 + minute * 60 + second;\n return totalSeconds * 10000 * 1000;\n }\n throw new Error('Not valid time');\n };\n /**\n * Checks if given year is a leap year.\n * @param year Year value.\n */\n Workbook.prototype.isLeapYear = function (year) {\n return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);\n };\n /**\n * Converts `DateTime` to the equivalent OLE Automation date.\n */\n Workbook.prototype.toOADate = function (date) {\n var ticks = 0;\n /* tslint:disable-next-line:max-line-length */\n ticks = this.dateToTicks(date.getFullYear(), (date.getMonth() + 1), date.getDate()) + this.timeToTicks(date.getHours(), date.getMinutes(), date.getSeconds());\n if (ticks === 0) {\n return 0.0;\n }\n var ticksPerDay = 10000 * 1000 * 60 * 60 * 24;\n var daysTo1899 = (((365 * 4 + 1) * 25 - 1) * 4 + 1) * 4 + ((365 * 4 + 1) * 25 - 1) * 3 - 367;\n var doubleDateOffset = daysTo1899 * ticksPerDay;\n var oaDateMinAsTicks = (((365 * 4 + 1) * 25 - 1) - 365) * ticksPerDay;\n if (ticks < oaDateMinAsTicks) {\n throw new Error('Arg_OleAutDateInvalid');\n }\n var millisPerDay = 1000 * 60 * 60 * 24;\n return ((ticks - doubleDateOffset) / 10000) / millisPerDay;\n };\n return Workbook;\n}());\nexport { Workbook };\n/**\n * BuiltInProperties Class\n * @private\n */\nvar BuiltInProperties = /** @class */ (function () {\n function BuiltInProperties() {\n }\n return BuiltInProperties;\n}());\nexport { BuiltInProperties };\n","/**\n * AriaService\n *\n * @hidden\n */\nvar AriaService = /** @class */ (function () {\n function AriaService() {\n }\n AriaService.prototype.setOptions = function (target, options) {\n var props = Object.keys(options);\n for (var i = 0; i < props.length; i++) {\n setStateAndProperties(target, config[props[parseInt(i.toString(), 10)]], options[props[parseInt(i.toString(), 10)]]);\n }\n };\n AriaService.prototype.setExpand = function (target, expand) {\n setStateAndProperties(target, config.expand, expand);\n };\n AriaService.prototype.setSort = function (target, direction) {\n setStateAndProperties(target, config.sort, direction, typeof direction === 'boolean');\n };\n AriaService.prototype.setBusy = function (target, isBusy) {\n setStateAndProperties(target, config.busy, isBusy);\n setStateAndProperties(target, config.invalid, null, true);\n };\n AriaService.prototype.setGrabbed = function (target, isGrabbed, remove) {\n setStateAndProperties(target, config.grabbed, isGrabbed, remove);\n };\n AriaService.prototype.setDropTarget = function (target, isTarget) {\n setStateAndProperties(target, config.dropeffect, 'copy', !isTarget);\n };\n return AriaService;\n}());\nexport { AriaService };\n/**\n * @param {HTMLElement} target - specifies the target\n * @param {string} attribute - specifies the attribute\n * @param {ValueType} value - specifies the value\n * @param {boolean} remove - specifies the boolean for remove\n * @returns {void}\n * @hidden\n */\nfunction setStateAndProperties(target, attribute, value, remove) {\n if (remove && target) {\n target.removeAttribute(attribute);\n return;\n }\n if (target) {\n target.setAttribute(attribute, value);\n }\n}\nvar config = {\n expand: 'aria-expanded',\n role: 'role',\n datarole: 'data-role',\n selected: 'aria-selected',\n multiselectable: 'aria-multiselectable',\n sort: 'aria-sort',\n busy: 'aria-busy',\n invalid: 'aria-invalid',\n grabbed: 'aria-grabbed',\n dropeffect: 'aria-dropeffect',\n haspopup: 'aria-haspopup',\n level: 'aria-level',\n colcount: 'aria-colcount',\n rowcount: 'aria-rowcount'\n};\n","//! moment.js locale configuration\n//! locale : Luxembourgish [lb]\n//! author : mweimerskirch : https://github.com/mweimerskirch\n//! author : David Raison : https://github.com/kwisatz\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n m: ['eng Minutt', 'enger Minutt'],\n h: ['eng Stonn', 'enger Stonn'],\n d: ['een Dag', 'engem Dag'],\n M: ['ee Mount', 'engem Mount'],\n y: ['ee Joer', 'engem Joer'],\n };\n return withoutSuffix ? format[key][0] : format[key][1];\n }\n function processFutureTime(string) {\n var number = string.substr(0, string.indexOf(' '));\n if (eifelerRegelAppliesToNumber(number)) {\n return 'a ' + string;\n }\n return 'an ' + string;\n }\n function processPastTime(string) {\n var number = string.substr(0, string.indexOf(' '));\n if (eifelerRegelAppliesToNumber(number)) {\n return 'viru ' + string;\n }\n return 'virun ' + string;\n }\n /**\n * Returns true if the word before the given number loses the '-n' ending.\n * e.g. 'an 10 Deeg' but 'a 5 Deeg'\n *\n * @param number {integer}\n * @returns {boolean}\n */\n function eifelerRegelAppliesToNumber(number) {\n number = parseInt(number, 10);\n if (isNaN(number)) {\n return false;\n }\n if (number < 0) {\n // Negative Number --> always true\n return true;\n } else if (number < 10) {\n // Only 1 digit\n if (4 <= number && number <= 7) {\n return true;\n }\n return false;\n } else if (number < 100) {\n // 2 digits\n var lastDigit = number % 10,\n firstDigit = number / 10;\n if (lastDigit === 0) {\n return eifelerRegelAppliesToNumber(firstDigit);\n }\n return eifelerRegelAppliesToNumber(lastDigit);\n } else if (number < 10000) {\n // 3 or 4 digits --> recursively check first digit\n while (number >= 10) {\n number = number / 10;\n }\n return eifelerRegelAppliesToNumber(number);\n } else {\n // Anything larger than 4 digits: recursively check first n-3 digits\n number = number / 1000;\n return eifelerRegelAppliesToNumber(number);\n }\n }\n\n var lb = moment.defineLocale('lb', {\n months: 'Januar_Februar_Mäerz_Abrëll_Mee_Juni_Juli_August_September_Oktober_November_Dezember'.split(\n '_'\n ),\n monthsShort:\n 'Jan._Febr._Mrz._Abr._Mee_Jun._Jul._Aug._Sept._Okt._Nov._Dez.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays:\n 'Sonndeg_Méindeg_Dënschdeg_Mëttwoch_Donneschdeg_Freideg_Samschdeg'.split(\n '_'\n ),\n weekdaysShort: 'So._Mé._Dë._Më._Do._Fr._Sa.'.split('_'),\n weekdaysMin: 'So_Mé_Dë_Më_Do_Fr_Sa'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm [Auer]',\n LTS: 'H:mm:ss [Auer]',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY H:mm [Auer]',\n LLLL: 'dddd, D. MMMM YYYY H:mm [Auer]',\n },\n calendar: {\n sameDay: '[Haut um] LT',\n sameElse: 'L',\n nextDay: '[Muer um] LT',\n nextWeek: 'dddd [um] LT',\n lastDay: '[Gëschter um] LT',\n lastWeek: function () {\n // Different date string for 'Dënschdeg' (Tuesday) and 'Donneschdeg' (Thursday) due to phonological rule\n switch (this.day()) {\n case 2:\n case 4:\n return '[Leschten] dddd [um] LT';\n default:\n return '[Leschte] dddd [um] LT';\n }\n },\n },\n relativeTime: {\n future: processFutureTime,\n past: processPastTime,\n s: 'e puer Sekonnen',\n ss: '%d Sekonnen',\n m: processRelativeTime,\n mm: '%d Minutten',\n h: processRelativeTime,\n hh: '%d Stonnen',\n d: processRelativeTime,\n dd: '%d Deeg',\n M: processRelativeTime,\n MM: '%d Méint',\n y: processRelativeTime,\n yy: '%d Joer',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return lb;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { Component, EventHandler, Property, Event } from '@syncfusion/ej2-base';\nimport { addClass, removeClass, isVisible, closest, attributes, detach, classList, KeyboardEvents } from '@syncfusion/ej2-base';\nimport { selectAll, setStyleAttribute as setStyle, select } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined as isNOU, getUniqueID, formatUnit, Collection, compile as templateCompiler } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges, ChildProperty, Browser, SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport { Popup } from '@syncfusion/ej2-popups';\nimport { calculatePosition } from '@syncfusion/ej2-popups';\nimport { Button } from '@syncfusion/ej2-buttons';\nimport { HScroll } from '../common/h-scroll';\nimport { VScroll } from '../common/v-scroll';\nvar CLS_VERTICAL = 'e-vertical';\nvar CLS_ITEMS = 'e-toolbar-items';\nvar CLS_ITEM = 'e-toolbar-item';\nvar CLS_RTL = 'e-rtl';\nvar CLS_SEPARATOR = 'e-separator';\nvar CLS_POPUPICON = 'e-popup-up-icon';\nvar CLS_POPUPDOWN = 'e-popup-down-icon';\nvar CLS_POPUPOPEN = 'e-popup-open';\nvar CLS_TEMPLATE = 'e-template';\nvar CLS_DISABLE = 'e-overlay';\nvar CLS_POPUPTEXT = 'e-toolbar-text';\nvar CLS_TBARTEXT = 'e-popup-text';\nvar CLS_TBAROVERFLOW = 'e-overflow-show';\nvar CLS_POPOVERFLOW = 'e-overflow-hide';\nvar CLS_TBARBTN = 'e-tbar-btn';\nvar CLS_TBARNAV = 'e-hor-nav';\nvar CLS_TBARSCRLNAV = 'e-scroll-nav';\nvar CLS_TBARRIGHT = 'e-toolbar-right';\nvar CLS_TBARLEFT = 'e-toolbar-left';\nvar CLS_TBARCENTER = 'e-toolbar-center';\nvar CLS_TBARPOS = 'e-tbar-pos';\nvar CLS_HSCROLLCNT = 'e-hscroll-content';\nvar CLS_VSCROLLCNT = 'e-vscroll-content';\nvar CLS_HSCROLLBAR = 'e-hscroll-bar';\nvar CLS_POPUPNAV = 'e-hor-nav';\nvar CLS_POPUPCLASS = 'e-toolbar-pop';\nvar CLS_POPUP = 'e-toolbar-popup';\nvar CLS_TBARBTNTEXT = 'e-tbar-btn-text';\nvar CLS_TBARNAVACT = 'e-nav-active';\nvar CLS_TBARIGNORE = 'e-ignore';\nvar CLS_POPPRI = 'e-popup-alone';\nvar CLS_HIDDEN = 'e-hidden';\nvar CLS_MULTIROW = 'e-toolbar-multirow';\nvar CLS_MULTIROWPOS = 'e-multirow-pos';\nvar CLS_MULTIROW_SEPARATOR = 'e-multirow-separator';\nvar CLS_EXTENDABLE_SEPARATOR = 'e-extended-separator';\nvar CLS_EXTEANDABLE_TOOLBAR = 'e-extended-toolbar';\nvar CLS_EXTENDABLECLASS = 'e-toolbar-extended';\nvar CLS_EXTENDPOPUP = 'e-expended-nav';\nvar CLS_EXTENDEDPOPOPEN = 'e-tbar-extended';\n/**\n * An item object that is used to configure Toolbar commands.\n */\nvar Item = /** @class */ (function (_super) {\n __extends(Item, _super);\n function Item() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('')\n ], Item.prototype, \"id\", void 0);\n __decorate([\n Property('')\n ], Item.prototype, \"text\", void 0);\n __decorate([\n Property('auto')\n ], Item.prototype, \"width\", void 0);\n __decorate([\n Property('')\n ], Item.prototype, \"cssClass\", void 0);\n __decorate([\n Property(false)\n ], Item.prototype, \"showAlwaysInPopup\", void 0);\n __decorate([\n Property(false)\n ], Item.prototype, \"disabled\", void 0);\n __decorate([\n Property('')\n ], Item.prototype, \"prefixIcon\", void 0);\n __decorate([\n Property('')\n ], Item.prototype, \"suffixIcon\", void 0);\n __decorate([\n Property(true)\n ], Item.prototype, \"visible\", void 0);\n __decorate([\n Property('None')\n ], Item.prototype, \"overflow\", void 0);\n __decorate([\n Property('')\n ], Item.prototype, \"template\", void 0);\n __decorate([\n Property('Button')\n ], Item.prototype, \"type\", void 0);\n __decorate([\n Property('Both')\n ], Item.prototype, \"showTextOn\", void 0);\n __decorate([\n Property(null)\n ], Item.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property('')\n ], Item.prototype, \"tooltipText\", void 0);\n __decorate([\n Property('Left')\n ], Item.prototype, \"align\", void 0);\n __decorate([\n Event()\n ], Item.prototype, \"click\", void 0);\n __decorate([\n Property(-1)\n ], Item.prototype, \"tabIndex\", void 0);\n return Item;\n}(ChildProperty));\nexport { Item };\n/**\n * The Toolbar control contains a group of commands that are aligned horizontally.\n * ```html\n * <div id=\"toolbar\"/>\n * <script>\n * var toolbarObj = new Toolbar();\n * toolbarObj.appendTo(\"#toolbar\");\n * </script>\n * ```\n */\nvar Toolbar = /** @class */ (function (_super) {\n __extends(Toolbar, _super);\n /**\n * Initializes a new instance of the Toolbar class.\n *\n * @param {ToolbarModel} options - Specifies Toolbar model properties as options.\n * @param { string | HTMLElement} element - Specifies the element that is rendered as a Toolbar.\n */\n function Toolbar(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.resizeContext = _this.resize.bind(_this);\n _this.orientationChangeContext = _this.orientationChange.bind(_this);\n /**\n * Contains the keyboard configuration of the Toolbar.\n */\n _this.keyConfigs = {\n moveLeft: 'leftarrow',\n moveRight: 'rightarrow',\n moveUp: 'uparrow',\n moveDown: 'downarrow',\n popupOpen: 'enter',\n popupClose: 'escape',\n tab: 'tab',\n home: 'home',\n end: 'end'\n };\n return _this;\n }\n /**\n * Removes the control from the DOM and also removes all its related events.\n *\n * @returns {void}.\n */\n Toolbar.prototype.destroy = function () {\n var _this = this;\n if (this.isReact || this.isAngular) {\n this.clearTemplate();\n }\n var btnItems = this.element.querySelectorAll('.e-control.e-btn');\n [].slice.call(btnItems).forEach(function (el) {\n if (!isNOU(el) && !isNOU(el.ej2_instances) && !isNOU(el.ej2_instances[0]) && !(el.ej2_instances[0].isDestroyed)) {\n el.ej2_instances[0].destroy();\n }\n });\n this.unwireEvents();\n this.tempId.forEach(function (ele) {\n if (!isNOU(_this.element.querySelector(ele))) {\n document.body.appendChild(_this.element.querySelector(ele)).style.display = 'none';\n }\n });\n this.destroyItems();\n while (this.element.lastElementChild) {\n this.element.removeChild(this.element.lastElementChild);\n }\n if (this.trgtEle) {\n this.element.appendChild(this.ctrlTem);\n this.trgtEle = null;\n this.ctrlTem = null;\n }\n if (this.popObj) {\n this.popObj.destroy();\n detach(this.popObj.element);\n }\n if (this.activeEle) {\n this.activeEle = null;\n }\n this.popObj = null;\n this.tbarAlign = null;\n this.tbarItemsCol = [];\n this.remove(this.element, 'e-toolpop');\n if (this.cssClass) {\n removeClass([this.element], this.cssClass.split(' '));\n }\n this.element.removeAttribute('style');\n ['aria-disabled', 'aria-orientation', 'role'].forEach(function (attrb) {\n return _this.element.removeAttribute(attrb);\n });\n _super.prototype.destroy.call(this);\n };\n /**\n * Initialize the event handler\n *\n * @private\n * @returns {void}\n */\n Toolbar.prototype.preRender = function () {\n var eventArgs = { enableCollision: this.enableCollision, scrollStep: this.scrollStep };\n this.trigger('beforeCreate', eventArgs);\n this.enableCollision = eventArgs.enableCollision;\n this.scrollStep = eventArgs.scrollStep;\n this.scrollModule = null;\n this.popObj = null;\n this.tempId = [];\n this.tbarItemsCol = this.items;\n this.isVertical = this.element.classList.contains(CLS_VERTICAL) ? true : false;\n this.isExtendedOpen = false;\n this.popupPriCount = 0;\n if (this.enableRtl) {\n this.add(this.element, CLS_RTL);\n }\n };\n Toolbar.prototype.wireEvents = function () {\n EventHandler.add(this.element, 'click', this.clickHandler, this);\n window.addEventListener('resize', this.resizeContext);\n window.addEventListener('orientationchange', this.orientationChangeContext);\n if (this.allowKeyboard) {\n this.wireKeyboardEvent();\n }\n };\n Toolbar.prototype.wireKeyboardEvent = function () {\n this.keyModule = new KeyboardEvents(this.element, {\n keyAction: this.keyActionHandler.bind(this),\n keyConfigs: this.keyConfigs\n });\n EventHandler.add(this.element, 'keydown', this.docKeyDown, this);\n this.updateTabIndex('0');\n };\n Toolbar.prototype.updateTabIndex = function (tabIndex) {\n var ele = this.element.querySelector('.' + CLS_ITEM + ':not(.' + CLS_DISABLE + ' ):not(.' + CLS_SEPARATOR + ' ):not(.' + CLS_HIDDEN + ' )');\n if (!isNOU(ele) && !isNOU(ele.firstElementChild)) {\n var dataTabIndex = ele.firstElementChild.getAttribute('data-tabindex');\n if (dataTabIndex && dataTabIndex === '-1' && ele.firstElementChild.tagName !== 'INPUT') {\n ele.firstElementChild.setAttribute('tabindex', tabIndex);\n }\n }\n };\n Toolbar.prototype.unwireKeyboardEvent = function () {\n if (this.keyModule) {\n EventHandler.remove(this.element, 'keydown', this.docKeyDown);\n this.keyModule.destroy();\n this.keyModule = null;\n }\n };\n Toolbar.prototype.docKeyDown = function (e) {\n if (e.target.tagName === 'INPUT') {\n return;\n }\n var popCheck = !isNOU(this.popObj) && isVisible(this.popObj.element) && this.overflowMode !== 'Extended';\n if (e.keyCode === 9 && e.target.classList.contains('e-hor-nav') === true && popCheck) {\n this.popObj.hide({ name: 'FadeOut', duration: 100 });\n }\n var keyCheck = (e.keyCode === 40 || e.keyCode === 38 || e.keyCode === 35 || e.keyCode === 36);\n if (keyCheck) {\n e.preventDefault();\n }\n };\n Toolbar.prototype.unwireEvents = function () {\n EventHandler.remove(this.element, 'click', this.clickHandler);\n this.destroyScroll();\n this.unwireKeyboardEvent();\n window.removeEventListener('resize', this.resizeContext);\n window.removeEventListener('orientationchange', this.orientationChangeContext);\n EventHandler.remove(document, 'scroll', this.docEvent);\n EventHandler.remove(document, 'click', this.docEvent);\n };\n Toolbar.prototype.clearProperty = function () {\n this.tbarEle = [];\n this.tbarAlgEle = { lefts: [], centers: [], rights: [] };\n };\n Toolbar.prototype.docEvent = function (e) {\n var popEle = closest(e.target, '.e-popup');\n if (this.popObj && isVisible(this.popObj.element) && !popEle && this.overflowMode === 'Popup') {\n this.popObj.hide({ name: 'FadeOut', duration: 100 });\n }\n };\n Toolbar.prototype.destroyScroll = function () {\n if (this.scrollModule) {\n if (this.tbarAlign) {\n this.add(this.scrollModule.element, CLS_TBARPOS);\n }\n this.scrollModule.destroy();\n this.scrollModule = null;\n }\n };\n Toolbar.prototype.destroyItems = function () {\n if (this.element) {\n [].slice.call(this.element.querySelectorAll('.' + CLS_ITEM)).forEach(function (el) { detach(el); });\n }\n if (this.tbarAlign) {\n var tbarItems = this.element.querySelector('.' + CLS_ITEMS);\n [].slice.call(tbarItems.children).forEach(function (el) {\n detach(el);\n });\n this.tbarAlign = false;\n this.remove(tbarItems, CLS_TBARPOS);\n }\n this.clearProperty();\n };\n Toolbar.prototype.destroyMode = function () {\n if (this.scrollModule) {\n this.remove(this.scrollModule.element, CLS_RTL);\n this.destroyScroll();\n }\n this.remove(this.element, CLS_EXTENDEDPOPOPEN);\n this.remove(this.element, CLS_EXTEANDABLE_TOOLBAR);\n var tempEle = this.element.querySelector('.e-toolbar-multirow');\n if (tempEle) {\n this.remove(tempEle, CLS_MULTIROW);\n }\n if (this.popObj) {\n this.popupRefresh(this.popObj.element, true);\n }\n };\n Toolbar.prototype.add = function (ele, val) {\n ele.classList.add(val);\n };\n Toolbar.prototype.remove = function (ele, val) {\n ele.classList.remove(val);\n };\n Toolbar.prototype.elementFocus = function (ele) {\n var fChild = ele.firstElementChild;\n if (fChild) {\n fChild.focus();\n this.activeEleSwitch(ele);\n }\n else {\n ele.focus();\n }\n };\n Toolbar.prototype.clstElement = function (tbrNavChk, trgt) {\n var clst;\n if (tbrNavChk && this.popObj && isVisible(this.popObj.element)) {\n clst = this.popObj.element.querySelector('.' + CLS_ITEM);\n }\n else if (this.element === trgt || tbrNavChk) {\n clst = this.element.querySelector('.' + CLS_ITEM + ':not(.' + CLS_DISABLE + ' ):not(.' + CLS_SEPARATOR + ' ):not(.' + CLS_HIDDEN + ' )');\n }\n else {\n clst = closest(trgt, '.' + CLS_ITEM);\n }\n return clst;\n };\n Toolbar.prototype.keyHandling = function (clst, e, trgt, navChk, scrollChk) {\n var popObj = this.popObj;\n var rootEle = this.element;\n var popAnimate = { name: 'FadeOut', duration: 100 };\n var value = e.action === 'moveUp' ? 'previous' : 'next';\n var ele;\n var nodes;\n switch (e.action) {\n case 'moveRight':\n if (this.isVertical) {\n return;\n }\n if (rootEle === trgt) {\n this.elementFocus(clst);\n }\n else if (!navChk) {\n this.eleFocus(clst, 'next');\n }\n break;\n case 'moveLeft':\n if (this.isVertical) {\n return;\n }\n if (!navChk) {\n this.eleFocus(clst, 'previous');\n }\n break;\n case 'home':\n case 'end':\n if (clst) {\n var popupCheck = closest(clst, '.e-popup');\n var extendedPopup = this.element.querySelector('.' + CLS_EXTENDABLECLASS);\n if (this.overflowMode === 'Extended' && extendedPopup && extendedPopup.classList.contains('e-popup-open')) {\n popupCheck = e.action === 'end' ? extendedPopup : null;\n }\n if (popupCheck) {\n if (isVisible(this.popObj.element)) {\n nodes = [].slice.call(popupCheck.children);\n if (e.action === 'home') {\n ele = this.focusFirstVisibleEle(nodes);\n }\n else {\n ele = this.focusLastVisibleEle(nodes);\n }\n }\n }\n else {\n nodes = this.element.querySelectorAll('.' + CLS_ITEMS + ' .' + CLS_ITEM + ':not(.' + CLS_SEPARATOR + ')');\n if (e.action === 'home') {\n ele = this.focusFirstVisibleEle(nodes);\n }\n else {\n ele = this.focusLastVisibleEle(nodes);\n }\n }\n if (ele) {\n this.elementFocus(ele);\n }\n }\n break;\n case 'moveUp':\n case 'moveDown':\n if (!this.isVertical) {\n if (popObj && closest(trgt, '.e-popup')) {\n var popEle = popObj.element;\n var popFrstEle = popEle.firstElementChild;\n if ((value === 'previous' && popFrstEle === clst)) {\n popEle.lastElementChild.firstChild.focus();\n }\n else if (value === 'next' && popEle.lastElementChild === clst) {\n popFrstEle.firstChild.focus();\n }\n else {\n this.eleFocus(clst, value);\n }\n }\n else if (e.action === 'moveDown' && popObj && isVisible(popObj.element)) {\n this.elementFocus(clst);\n }\n }\n else {\n if (e.action === 'moveUp') {\n this.eleFocus(clst, 'previous');\n }\n else {\n this.eleFocus(clst, 'next');\n }\n }\n break;\n case 'tab':\n if (!scrollChk && !navChk) {\n var ele_1 = clst.firstElementChild;\n if (rootEle === trgt) {\n if (this.activeEle) {\n this.activeEle.focus();\n }\n else {\n this.activeEleRemove(ele_1);\n ele_1.focus();\n }\n }\n }\n break;\n case 'popupClose':\n if (popObj && this.overflowMode !== 'Extended') {\n popObj.hide(popAnimate);\n }\n break;\n case 'popupOpen':\n if (!navChk) {\n return;\n }\n if (popObj && !isVisible(popObj.element)) {\n popObj.element.style.top = rootEle.offsetHeight + 'px';\n popObj.show({ name: 'FadeIn', duration: 100 });\n }\n else {\n popObj.hide(popAnimate);\n }\n break;\n }\n };\n Toolbar.prototype.keyActionHandler = function (e) {\n var trgt = e.target;\n if (trgt.tagName === 'INPUT' || trgt.tagName === 'TEXTAREA' || this.element.classList.contains(CLS_DISABLE)) {\n return;\n }\n e.preventDefault();\n var tbrNavChk = trgt.classList.contains(CLS_TBARNAV);\n var tbarScrollChk = trgt.classList.contains(CLS_TBARSCRLNAV);\n var clst = this.clstElement(tbrNavChk, trgt);\n if (clst || tbarScrollChk) {\n this.keyHandling(clst, e, trgt, tbrNavChk, tbarScrollChk);\n }\n };\n /**\n * Specifies the value to disable/enable the Toolbar component.\n * When set to `true`, the component will be disabled.\n *\n * @param {boolean} value - Based on this Boolean value, Toolbar will be enabled (false) or disabled (true).\n * @returns {void}.\n */\n Toolbar.prototype.disable = function (value) {\n var rootEle = this.element;\n if (value) {\n rootEle.classList.add(CLS_DISABLE);\n }\n else {\n rootEle.classList.remove(CLS_DISABLE);\n }\n if (this.activeEle) {\n this.activeEle.setAttribute('tabindex', this.activeEle.getAttribute('data-tabindex'));\n }\n if (this.scrollModule) {\n this.scrollModule.disable(value);\n }\n if (this.popObj) {\n if (isVisible(this.popObj.element) && this.overflowMode !== 'Extended') {\n this.popObj.hide();\n }\n rootEle.querySelector('#' + rootEle.id + '_nav').setAttribute('tabindex', !value ? '0' : '-1');\n }\n };\n Toolbar.prototype.eleContains = function (el) {\n return el.classList.contains(CLS_SEPARATOR) || el.classList.contains(CLS_DISABLE) || el.getAttribute('disabled') || el.classList.contains(CLS_HIDDEN) || !isVisible(el) || !el.classList.contains(CLS_ITEM);\n };\n Toolbar.prototype.focusFirstVisibleEle = function (nodes) {\n var element;\n var index = 0;\n while (index < nodes.length) {\n var ele = nodes[parseInt(index.toString(), 10)];\n if (!ele.classList.contains(CLS_HIDDEN) && !ele.classList.contains(CLS_DISABLE)) {\n return ele;\n }\n index++;\n }\n return element;\n };\n Toolbar.prototype.focusLastVisibleEle = function (nodes) {\n var element;\n var index = nodes.length - 1;\n while (index >= 0) {\n var ele = nodes[parseInt(index.toString(), 10)];\n if (!ele.classList.contains(CLS_HIDDEN) && !ele.classList.contains(CLS_DISABLE)) {\n return ele;\n }\n index--;\n }\n return element;\n };\n Toolbar.prototype.eleFocus = function (closest, pos) {\n var sib = Object(closest)[pos + 'ElementSibling'];\n if (sib) {\n var skipEle = this.eleContains(sib);\n if (skipEle) {\n this.eleFocus(sib, pos);\n return;\n }\n this.elementFocus(sib);\n }\n else if (this.tbarAlign) {\n var elem = Object(closest.parentElement)[pos + 'ElementSibling'];\n if (!isNOU(elem) && elem.children.length === 0) {\n elem = Object(elem)[pos + 'ElementSibling'];\n }\n if (!isNOU(elem) && elem.children.length > 0) {\n if (pos === 'next') {\n var el = elem.querySelector('.' + CLS_ITEM);\n if (this.eleContains(el)) {\n this.eleFocus(el, pos);\n }\n else {\n el.firstElementChild.focus();\n this.activeEleSwitch(el);\n }\n }\n else {\n var el = elem.lastElementChild;\n if (this.eleContains(el)) {\n this.eleFocus(el, pos);\n }\n else {\n this.elementFocus(el);\n }\n }\n }\n }\n else if (!isNOU(closest)) {\n var tbrItems = this.element.querySelectorAll('.' + CLS_ITEMS + ' .' + CLS_ITEM + ':not(.' + CLS_SEPARATOR + ')' + ':not(.' + CLS_DISABLE + ')' + ':not(.' + CLS_HIDDEN + ')');\n if (pos === 'next' && tbrItems) {\n this.elementFocus(tbrItems[0]);\n }\n else if (pos === 'previous' && tbrItems) {\n this.elementFocus(tbrItems[tbrItems.length - 1]);\n }\n }\n };\n Toolbar.prototype.clickHandler = function (e) {\n var _this = this;\n var trgt = e.target;\n var ele = this.element;\n var isPopupElement = !isNOU(closest(trgt, '.' + CLS_POPUPCLASS));\n var clsList = trgt.classList;\n var popupNav = closest(trgt, ('.' + CLS_TBARNAV));\n if (!popupNav) {\n popupNav = trgt;\n }\n if (!ele.children[0].classList.contains('e-hscroll') && !ele.children[0].classList.contains('e-vscroll')\n && (clsList.contains(CLS_TBARNAV))) {\n clsList = trgt.querySelector('.e-icons').classList;\n }\n if (clsList.contains(CLS_POPUPICON) || clsList.contains(CLS_POPUPDOWN)) {\n this.popupClickHandler(ele, popupNav, CLS_RTL);\n }\n var itemObj;\n var clst = closest(e.target, '.' + CLS_ITEM);\n if ((isNOU(clst) || clst.classList.contains(CLS_DISABLE)) && !popupNav.classList.contains(CLS_TBARNAV)) {\n return;\n }\n if (clst) {\n var tempItem = this.items[this.tbarEle.indexOf(clst)];\n itemObj = tempItem;\n }\n var eventArgs = { originalEvent: e, item: itemObj };\n if (itemObj && !isNOU(itemObj.click)) {\n this.trigger('items[' + this.tbarEle.indexOf(clst) + '].click', eventArgs);\n }\n if (!eventArgs.cancel) {\n this.trigger('clicked', eventArgs, function (clickedArgs) {\n if (!isNOU(_this.popObj) && isPopupElement && !clickedArgs.cancel && _this.overflowMode === 'Popup' &&\n clickedArgs.item && clickedArgs.item.type !== 'Input') {\n _this.popObj.hide({ name: 'FadeOut', duration: 100 });\n }\n });\n }\n };\n Toolbar.prototype.popupClickHandler = function (ele, popupNav, CLS_RTL) {\n var popObj = this.popObj;\n if (isVisible(popObj.element)) {\n popupNav.classList.remove(CLS_TBARNAVACT);\n popObj.hide({ name: 'FadeOut', duration: 100 });\n }\n else {\n if (ele.classList.contains(CLS_RTL)) {\n popObj.enableRtl = true;\n popObj.position = { X: 'left', Y: 'top' };\n }\n if (popObj.offsetX === 0 && !ele.classList.contains(CLS_RTL)) {\n popObj.enableRtl = false;\n popObj.position = { X: 'right', Y: 'top' };\n }\n popObj.dataBind();\n popObj.refreshPosition();\n popObj.element.style.top = this.getElementOffsetY() + 'px';\n if (this.overflowMode === 'Extended') {\n popObj.element.style.minHeight = '0px';\n }\n popupNav.classList.add(CLS_TBARNAVACT);\n popObj.show({ name: 'FadeIn', duration: 100 });\n }\n };\n /**\n * To Initialize the control rendering\n *\n * @private\n * @returns {void}\n */\n Toolbar.prototype.render = function () {\n var _this = this;\n this.initialize();\n this.renderControl();\n this.wireEvents();\n this.renderComplete();\n if (this.isReact && this.portals && this.portals.length > 0) {\n this.renderReactTemplates(function () {\n _this.refreshOverflow();\n });\n }\n };\n Toolbar.prototype.initialize = function () {\n var width = formatUnit(this.width);\n var height = formatUnit(this.height);\n if (Browser.info.name !== 'msie' || this.height !== 'auto' || this.overflowMode === 'MultiRow') {\n setStyle(this.element, { 'height': height });\n }\n setStyle(this.element, { 'width': width });\n var ariaAttr = {\n 'role': 'toolbar', 'aria-disabled': 'false',\n 'aria-orientation': !this.isVertical ? 'horizontal' : 'vertical'\n };\n attributes(this.element, ariaAttr);\n if (this.cssClass) {\n addClass([this.element], this.cssClass.split(' '));\n }\n };\n Toolbar.prototype.renderControl = function () {\n var ele = this.element;\n this.trgtEle = (ele.children.length > 0) ? ele.querySelector('div') : null;\n this.tbarAlgEle = { lefts: [], centers: [], rights: [] };\n this.renderItems();\n this.renderLayout();\n };\n Toolbar.prototype.renderLayout = function () {\n this.renderOverflowMode();\n if (this.tbarAlign) {\n this.itemPositioning();\n }\n if (this.popObj && this.popObj.element.childElementCount > 1 && this.checkPopupRefresh(this.element, this.popObj.element)) {\n this.popupRefresh(this.popObj.element, false);\n }\n this.separator();\n };\n Toolbar.prototype.itemsAlign = function (items, itemEleDom) {\n var innerItem;\n var innerPos;\n if (!this.tbarEle) {\n this.tbarEle = [];\n }\n for (var i = 0; i < items.length; i++) {\n innerItem = this.renderSubComponent(items[parseInt(i.toString(), 10)], i);\n if (this.tbarEle.indexOf(innerItem) === -1) {\n this.tbarEle.push(innerItem);\n }\n if (!this.tbarAlign) {\n this.tbarItemAlign(items[parseInt(i.toString(), 10)], itemEleDom, i);\n }\n innerPos = itemEleDom.querySelector('.e-toolbar-' + items[parseInt(i.toString(), 10)].align.toLowerCase());\n if (innerPos) {\n if (!(items[parseInt(i.toString(), 10)].showAlwaysInPopup && items[parseInt(i.toString(), 10)].overflow !== 'Show')) {\n this.tbarAlgEle[(items[parseInt(i.toString(), 10)].align + 's').toLowerCase()].push(innerItem);\n }\n innerPos.appendChild(innerItem);\n }\n else {\n itemEleDom.appendChild(innerItem);\n }\n }\n if (this.isReact) {\n var portals = 'portals';\n this.notify('render-react-toolbar-template', this[\"\" + portals]);\n this.renderReactTemplates();\n }\n };\n /**\n * @hidden\n * @returns {void}\n */\n Toolbar.prototype.changeOrientation = function () {\n var ele = this.element;\n if (this.isVertical) {\n ele.classList.remove(CLS_VERTICAL);\n this.isVertical = false;\n if (this.height === 'auto' || this.height === '100%') {\n ele.style.height = this.height;\n }\n ele.setAttribute('aria-orientation', 'horizontal');\n }\n else {\n ele.classList.add(CLS_VERTICAL);\n this.isVertical = true;\n ele.setAttribute('aria-orientation', 'vertical');\n setStyle(this.element, { 'height': formatUnit(this.height), 'width': formatUnit(this.width) });\n }\n this.destroyMode();\n this.refreshOverflow();\n };\n Toolbar.prototype.initScroll = function (element, innerItems) {\n if (!this.scrollModule && this.checkOverflow(element, innerItems[0])) {\n if (this.tbarAlign) {\n this.element.querySelector('.' + CLS_ITEMS + ' .' + CLS_TBARCENTER).removeAttribute('style');\n }\n if (this.isVertical) {\n this.scrollModule = new VScroll({ scrollStep: this.scrollStep, enableRtl: this.enableRtl }, innerItems[0]);\n }\n else {\n this.scrollModule = new HScroll({ scrollStep: this.scrollStep, enableRtl: this.enableRtl }, innerItems[0]);\n }\n if (this.cssClass) {\n addClass([innerItems[0]], this.cssClass.split(' '));\n }\n var scrollEle = this.scrollModule.element.querySelector('.' + CLS_HSCROLLBAR + ', .' + 'e-vscroll-bar');\n if (scrollEle) {\n scrollEle.removeAttribute('tabindex');\n }\n this.remove(this.scrollModule.element, CLS_TBARPOS);\n setStyle(this.element, { overflow: 'hidden' });\n }\n };\n Toolbar.prototype.itemWidthCal = function (items) {\n var _this = this;\n var width = 0;\n var style;\n [].slice.call(selectAll('.' + CLS_ITEM, items)).forEach(function (el) {\n if (isVisible(el)) {\n style = window.getComputedStyle(el);\n width += _this.isVertical ? el.offsetHeight : el.offsetWidth;\n width += parseFloat(_this.isVertical ? style.marginTop : style.marginRight);\n width += parseFloat(_this.isVertical ? style.marginBottom : style.marginLeft);\n }\n });\n return width;\n };\n Toolbar.prototype.getScrollCntEle = function (innerItem) {\n var trgClass = (this.isVertical) ? '.e-vscroll-content' : '.e-hscroll-content';\n return innerItem.querySelector(trgClass);\n };\n Toolbar.prototype.checkOverflow = function (element, innerItem) {\n if (isNOU(element) || isNOU(innerItem) || !isVisible(element)) {\n return false;\n }\n var eleWidth = this.isVertical ? element.offsetHeight : element.offsetWidth;\n var itemWidth = this.isVertical ? innerItem.offsetHeight : innerItem.offsetWidth;\n if (this.tbarAlign || this.scrollModule || (eleWidth === itemWidth)) {\n itemWidth = this.itemWidthCal(this.scrollModule ? this.getScrollCntEle(innerItem) : innerItem);\n }\n var popNav = element.querySelector('.' + CLS_TBARNAV);\n var scrollNav = element.querySelector('.' + CLS_TBARSCRLNAV);\n var navEleWidth = 0;\n if (popNav) {\n navEleWidth = this.isVertical ? popNav.offsetHeight : popNav.offsetWidth;\n }\n else if (scrollNav) {\n navEleWidth = this.isVertical ? (scrollNav.offsetHeight * (2)) : (scrollNav.offsetWidth * 2);\n }\n if (itemWidth > eleWidth - navEleWidth) {\n return true;\n }\n else {\n return false;\n }\n };\n /**\n * Refresh the whole Toolbar component without re-rendering.\n * - It is used to manually refresh the Toolbar overflow modes such as scrollable, popup, multi row, and extended.\n * - It will refresh the Toolbar component after loading items dynamically.\n *\n * @returns {void}.\n */\n Toolbar.prototype.refreshOverflow = function () {\n this.resize();\n };\n Toolbar.prototype.toolbarAlign = function (innerItems) {\n if (this.tbarAlign) {\n this.add(innerItems, CLS_TBARPOS);\n this.itemPositioning();\n }\n };\n Toolbar.prototype.renderOverflowMode = function () {\n var ele = this.element;\n var innerItems = ele.querySelector('.' + CLS_ITEMS);\n var priorityCheck = this.popupPriCount > 0;\n if (ele && ele.children.length > 0) {\n this.offsetWid = ele.offsetWidth;\n this.remove(this.element, 'e-toolpop');\n if (Browser.info.name === 'msie' && this.height === 'auto') {\n ele.style.height = '';\n }\n switch (this.overflowMode) {\n case 'Scrollable':\n if (isNOU(this.scrollModule)) {\n this.initScroll(ele, [].slice.call(ele.getElementsByClassName(CLS_ITEMS)));\n }\n break;\n case 'Popup':\n this.add(this.element, 'e-toolpop');\n if (this.tbarAlign) {\n this.removePositioning();\n }\n if (this.checkOverflow(ele, innerItems) || priorityCheck) {\n this.setOverflowAttributes(ele);\n }\n this.toolbarAlign(innerItems);\n break;\n case 'MultiRow':\n this.add(innerItems, CLS_MULTIROW);\n if (this.checkOverflow(ele, innerItems) && this.tbarAlign) {\n this.removePositioning();\n this.add(innerItems, CLS_MULTIROWPOS);\n }\n if (ele.style.overflow === 'hidden') {\n ele.style.overflow = '';\n }\n if (Browser.info.name === 'msie' || ele.style.height !== 'auto') {\n ele.style.height = 'auto';\n }\n break;\n case 'Extended':\n this.add(this.element, CLS_EXTEANDABLE_TOOLBAR);\n if (this.checkOverflow(ele, innerItems) || priorityCheck) {\n if (this.tbarAlign) {\n this.removePositioning();\n }\n this.setOverflowAttributes(ele);\n }\n this.toolbarAlign(innerItems);\n }\n }\n };\n Toolbar.prototype.setOverflowAttributes = function (ele) {\n this.createPopupEle(ele, [].slice.call(selectAll('.' + CLS_ITEMS + ' .' + CLS_ITEM, ele)));\n var ariaAttr = {\n 'tabindex': '0', 'role': 'button', 'aria-haspopup': 'true',\n 'aria-label': 'overflow'\n };\n attributes(this.element.querySelector('.' + CLS_TBARNAV), ariaAttr);\n };\n Toolbar.prototype.separator = function () {\n var element = this.element;\n var eleItem = [].slice.call(element.querySelectorAll('.' + CLS_SEPARATOR));\n var multiVar = element.querySelector('.' + CLS_MULTIROW_SEPARATOR);\n var extendVar = element.querySelector('.' + CLS_EXTENDABLE_SEPARATOR);\n var eleInlineItem = this.overflowMode === 'MultiRow' ? multiVar : extendVar;\n if (eleInlineItem !== null) {\n if (this.overflowMode === 'MultiRow') {\n eleInlineItem.classList.remove(CLS_MULTIROW_SEPARATOR);\n }\n else if (this.overflowMode === 'Extended') {\n eleInlineItem.classList.remove(CLS_EXTENDABLE_SEPARATOR);\n }\n }\n for (var i = 0; i <= eleItem.length - 1; i++) {\n if (eleItem[parseInt(i.toString(), 10)].offsetLeft < 30 && eleItem[parseInt(i.toString(), 10)].offsetLeft !== 0) {\n if (this.overflowMode === 'MultiRow') {\n eleItem[parseInt(i.toString(), 10)].classList.add(CLS_MULTIROW_SEPARATOR);\n }\n else if (this.overflowMode === 'Extended') {\n eleItem[parseInt(i.toString(), 10)].classList.add(CLS_EXTENDABLE_SEPARATOR);\n }\n }\n }\n };\n Toolbar.prototype.createPopupEle = function (ele, innerEle) {\n var innerNav = ele.querySelector('.' + CLS_TBARNAV);\n var vertical = this.isVertical;\n if (!innerNav) {\n this.createPopupIcon(ele);\n }\n innerNav = ele.querySelector('.' + CLS_TBARNAV);\n var innerNavDom = (vertical ? innerNav.offsetHeight : innerNav.offsetWidth);\n var eleWidth = ((vertical ? ele.offsetHeight : ele.offsetWidth) - (innerNavDom));\n this.element.classList.remove('e-rtl');\n setStyle(this.element, { direction: 'initial' });\n this.checkPriority(ele, innerEle, eleWidth, true);\n if (this.enableRtl) {\n this.element.classList.add('e-rtl');\n }\n this.element.style.removeProperty('direction');\n this.createPopup();\n };\n Toolbar.prototype.pushingPoppedEle = function (tbarObj, popupPri, ele, eleHeight, sepHeight) {\n var element = tbarObj.element;\n var poppedEle = [].slice.call(selectAll('.' + CLS_POPUP, element.querySelector('.' + CLS_ITEMS)));\n var nodes = selectAll('.' + CLS_TBAROVERFLOW, ele);\n var nodeIndex = 0;\n var nodePri = 0;\n poppedEle.forEach(function (el, index) {\n nodes = selectAll('.' + CLS_TBAROVERFLOW, ele);\n if (el.classList.contains(CLS_TBAROVERFLOW) && nodes.length > 0) {\n if (tbarObj.tbResize && nodes.length > index) {\n ele.insertBefore(el, nodes[parseInt(index.toString(), 10)]);\n ++nodePri;\n }\n else {\n ele.insertBefore(el, ele.children[nodes.length]);\n ++nodePri;\n }\n }\n else if (el.classList.contains(CLS_TBAROVERFLOW)) {\n ele.insertBefore(el, ele.firstChild);\n ++nodePri;\n }\n else if (tbarObj.tbResize && el.classList.contains(CLS_POPOVERFLOW) && ele.children.length > 0 && nodes.length === 0) {\n ele.insertBefore(el, ele.firstChild);\n ++nodePri;\n }\n else if (el.classList.contains(CLS_POPOVERFLOW)) {\n popupPri.push(el);\n }\n else if (tbarObj.tbResize) {\n ele.insertBefore(el, ele.childNodes[nodeIndex + nodePri]);\n ++nodeIndex;\n }\n else {\n ele.appendChild(el);\n }\n if (el.classList.contains(CLS_SEPARATOR)) {\n setStyle(el, { display: '', height: sepHeight + 'px' });\n }\n else {\n setStyle(el, { display: '', height: eleHeight + 'px' });\n }\n });\n popupPri.forEach(function (el) {\n ele.appendChild(el);\n });\n var tbarEle = selectAll('.' + CLS_ITEM, element.querySelector('.' + CLS_ITEMS));\n for (var i = tbarEle.length - 1; i >= 0; i--) {\n var tbarElement = tbarEle[parseInt(i.toString(), 10)];\n if (tbarElement.classList.contains(CLS_SEPARATOR) && this.overflowMode !== 'Extended') {\n setStyle(tbarElement, { display: 'none' });\n }\n else {\n break;\n }\n }\n };\n Toolbar.prototype.createPopup = function () {\n var element = this.element;\n var sepHeight;\n var sepItem;\n if (this.overflowMode === 'Extended') {\n sepItem = element.querySelector('.' + CLS_SEPARATOR);\n sepHeight =\n (element.style.height === 'auto' || element.style.height === '') ? null : (sepItem && sepItem.offsetHeight);\n }\n var eleItem = element.querySelector('.' + CLS_ITEM + ':not(.' + CLS_SEPARATOR + '):not(.' + CLS_POPUP + ')');\n var eleHeight = (element.style.height === 'auto' || element.style.height === '') ? null : (eleItem && eleItem.offsetHeight);\n var ele;\n var popupPri = [];\n if (select('#' + element.id + '_popup.' + CLS_POPUPCLASS, element)) {\n ele = select('#' + element.id + '_popup.' + CLS_POPUPCLASS, element);\n }\n else {\n var extendEle = this.createElement('div', {\n id: element.id + '_popup', className: CLS_POPUPCLASS + ' ' + CLS_EXTENDABLECLASS\n });\n var popupEle = this.createElement('div', { id: element.id + '_popup', className: CLS_POPUPCLASS });\n ele = this.overflowMode === 'Extended' ? extendEle : popupEle;\n }\n this.pushingPoppedEle(this, popupPri, ele, eleHeight, sepHeight);\n this.popupInit(element, ele);\n };\n Toolbar.prototype.getElementOffsetY = function () {\n return (this.overflowMode === 'Extended' && window.getComputedStyle(this.element).getPropertyValue('box-sizing') === 'border-box' ?\n this.element.clientHeight : this.element.offsetHeight);\n };\n Toolbar.prototype.popupInit = function (element, ele) {\n if (!this.popObj) {\n element.appendChild(ele);\n if (this.cssClass) {\n addClass([ele], this.cssClass.split(' '));\n }\n setStyle(this.element, { overflow: '' });\n var eleStyles = window.getComputedStyle(this.element);\n var popup = new Popup(null, {\n relateTo: this.element,\n offsetY: (this.isVertical) ? 0 : this.getElementOffsetY(),\n enableRtl: this.enableRtl,\n open: this.popupOpen.bind(this),\n close: this.popupClose.bind(this),\n collision: { Y: this.enableCollision ? 'flip' : 'none' },\n position: this.enableRtl ? { X: 'left', Y: 'top' } : { X: 'right', Y: 'top' }\n });\n if (this.overflowMode === 'Extended') {\n popup.width = parseFloat(eleStyles.width) + ((parseFloat(eleStyles.borderRightWidth)) * 2);\n popup.offsetX = 0;\n }\n popup.appendTo(ele);\n EventHandler.add(document, 'scroll', this.docEvent.bind(this));\n EventHandler.add(document, 'click ', this.docEvent.bind(this));\n popup.element.style.maxHeight = popup.element.offsetHeight + 'px';\n if (this.isVertical) {\n popup.element.style.visibility = 'hidden';\n }\n if (this.isExtendedOpen) {\n var popupNav = this.element.querySelector('.' + CLS_TBARNAV);\n popupNav.classList.add(CLS_TBARNAVACT);\n classList(popupNav.firstElementChild, [CLS_POPUPICON], [CLS_POPUPDOWN]);\n this.element.querySelector('.' + CLS_EXTENDABLECLASS).classList.add(CLS_POPUPOPEN);\n }\n else {\n popup.hide();\n }\n this.popObj = popup;\n }\n else {\n var popupEle = this.popObj.element;\n setStyle(popupEle, { maxHeight: '', display: 'block' });\n setStyle(popupEle, { maxHeight: popupEle.offsetHeight + 'px', display: '' });\n }\n };\n Toolbar.prototype.tbarPopupHandler = function (isOpen) {\n if (this.overflowMode === 'Extended') {\n if (isOpen) {\n this.add(this.element, CLS_EXTENDEDPOPOPEN);\n }\n else {\n this.remove(this.element, CLS_EXTENDEDPOPOPEN);\n }\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Toolbar.prototype.popupOpen = function (e) {\n var popObj = this.popObj;\n if (!this.isVertical) {\n popObj.offsetY = this.getElementOffsetY();\n popObj.dataBind();\n }\n var popupEle = this.popObj.element;\n var toolEle = this.popObj.element.parentElement;\n var popupNav = toolEle.querySelector('.' + CLS_TBARNAV);\n popupNav.setAttribute('aria-expanded', 'true');\n setStyle(popObj.element, { height: 'auto', maxHeight: '' });\n popObj.element.style.maxHeight = popObj.element.offsetHeight + 'px';\n if (this.overflowMode === 'Extended') {\n popObj.element.style.minHeight = '';\n }\n var popupElePos = popupEle.offsetTop + popupEle.offsetHeight + calculatePosition(toolEle).top;\n var popIcon = popupNav.firstElementChild;\n popupNav.classList.add(CLS_TBARNAVACT);\n classList(popIcon, [CLS_POPUPICON], [CLS_POPUPDOWN]);\n this.tbarPopupHandler(true);\n var scrollVal = isNOU(window.scrollY) ? 0 : window.scrollY;\n if (!this.isVertical && ((window.innerHeight + scrollVal) < popupElePos) && (this.element.offsetTop < popupEle.offsetHeight)) {\n var overflowHeight = (popupEle.offsetHeight - ((popupElePos - window.innerHeight - scrollVal) + 5));\n popObj.height = overflowHeight + 'px';\n for (var i = 0; i <= popupEle.childElementCount; i++) {\n var ele = popupEle.children[parseInt(i.toString(), 10)];\n if (ele.offsetTop + ele.offsetHeight > overflowHeight) {\n overflowHeight = ele.offsetTop;\n break;\n }\n }\n setStyle(popObj.element, { maxHeight: overflowHeight + 'px' });\n }\n else if (this.isVertical) {\n var tbEleData = this.element.getBoundingClientRect();\n setStyle(popObj.element, { maxHeight: (tbEleData.top + this.element.offsetHeight) + 'px', bottom: 0, visibility: '' });\n }\n if (popObj) {\n var popupOffset = popupEle.getBoundingClientRect();\n if (popupOffset.right > document.documentElement.clientWidth && popupOffset.width > toolEle.getBoundingClientRect().width) {\n popObj.collision = { Y: 'none' };\n popObj.dataBind();\n }\n popObj.refreshPosition();\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Toolbar.prototype.popupClose = function (e) {\n var element = this.element;\n var popupNav = element.querySelector('.' + CLS_TBARNAV);\n popupNav.setAttribute('aria-expanded', 'false');\n var popIcon = popupNav.firstElementChild;\n popupNav.classList.remove(CLS_TBARNAVACT);\n classList(popIcon, [CLS_POPUPDOWN], [CLS_POPUPICON]);\n this.tbarPopupHandler(false);\n };\n Toolbar.prototype.checkPriority = function (ele, inEle, eleWidth, pre) {\n var popPriority = this.popupPriCount > 0;\n var len = inEle.length;\n var eleWid = eleWidth;\n var eleOffset;\n var checkoffset;\n var sepCheck = 0;\n var itemCount = 0;\n var itemPopCount = 0;\n var checkClass = function (ele, val) {\n var rVal = false;\n val.forEach(function (cls) {\n if (ele.classList.contains(cls)) {\n rVal = true;\n }\n });\n return rVal;\n };\n for (var i = len - 1; i >= 0; i--) {\n var mrgn = void 0;\n var compuStyle = window.getComputedStyle(inEle[parseInt(i.toString(), 10)]);\n if (this.isVertical) {\n mrgn = parseFloat((compuStyle).marginTop);\n mrgn += parseFloat((compuStyle).marginBottom);\n }\n else {\n mrgn = parseFloat((compuStyle).marginRight);\n mrgn += parseFloat((compuStyle).marginLeft);\n }\n var fstEleCheck = inEle[parseInt(i.toString(), 10)] === this.tbarEle[0];\n if (fstEleCheck) {\n this.tbarEleMrgn = mrgn;\n }\n eleOffset = this.isVertical ? inEle[parseInt(i.toString(), 10)].offsetHeight : inEle[parseInt(i.toString(), 10)].offsetWidth;\n var eleWid_1 = fstEleCheck ? (eleOffset + mrgn) : eleOffset;\n if (checkClass(inEle[parseInt(i.toString(), 10)], [CLS_POPPRI]) && popPriority) {\n inEle[parseInt(i.toString(), 10)].classList.add(CLS_POPUP);\n if (this.isVertical) {\n setStyle(inEle[parseInt(i.toString(), 10)], { display: 'none', minHeight: eleWid_1 + 'px' });\n }\n else {\n setStyle(inEle[parseInt(i.toString(), 10)], { display: 'none', minWidth: eleWid_1 + 'px' });\n }\n itemPopCount++;\n }\n if (this.isVertical) {\n checkoffset =\n (inEle[parseInt(i.toString(), 10)].offsetTop + inEle[parseInt(i.toString(), 10)].offsetHeight + mrgn) > eleWidth;\n }\n else {\n checkoffset =\n (inEle[parseInt(i.toString(), 10)].offsetLeft + inEle[parseInt(i.toString(), 10)].offsetWidth + mrgn) > eleWidth;\n }\n if (checkoffset) {\n if (inEle[parseInt(i.toString(), 10)].classList.contains(CLS_SEPARATOR)) {\n if (this.overflowMode === 'Extended') {\n var sepEle = inEle[parseInt(i.toString(), 10)];\n if (checkClass(sepEle, [CLS_SEPARATOR, CLS_TBARIGNORE])) {\n inEle[parseInt(i.toString(), 10)].classList.add(CLS_POPUP);\n itemPopCount++;\n }\n itemCount++;\n }\n else if (this.overflowMode === 'Popup') {\n if (sepCheck > 0 && itemCount === itemPopCount) {\n var sepEle = inEle[i + itemCount + (sepCheck - 1)];\n if (checkClass(sepEle, [CLS_SEPARATOR, CLS_TBARIGNORE])) {\n setStyle(sepEle, { display: 'none' });\n }\n }\n sepCheck++;\n itemCount = 0;\n itemPopCount = 0;\n }\n }\n else {\n itemCount++;\n }\n if (inEle[parseInt(i.toString(), 10)].classList.contains(CLS_TBAROVERFLOW) && pre) {\n eleWidth -= ((this.isVertical ? inEle[parseInt(i.toString(), 10)].offsetHeight :\n inEle[parseInt(i.toString(), 10)].offsetWidth) + (mrgn));\n }\n else if (!checkClass(inEle[parseInt(i.toString(), 10)], [CLS_SEPARATOR, CLS_TBARIGNORE])) {\n inEle[parseInt(i.toString(), 10)].classList.add(CLS_POPUP);\n if (this.isVertical) {\n setStyle(inEle[parseInt(i.toString(), 10)], { display: 'none', minHeight: eleWid_1 + 'px' });\n }\n else {\n setStyle(inEle[parseInt(i.toString(), 10)], { display: 'none', minWidth: eleWid_1 + 'px' });\n }\n itemPopCount++;\n }\n else {\n eleWidth -= ((this.isVertical ? inEle[parseInt(i.toString(), 10)].offsetHeight :\n inEle[parseInt(i.toString(), 10)].offsetWidth) + (mrgn));\n }\n }\n }\n if (pre) {\n var popedEle = selectAll('.' + CLS_ITEM + ':not(.' + CLS_POPUP + ')', this.element);\n this.checkPriority(ele, popedEle, eleWid, false);\n }\n };\n Toolbar.prototype.createPopupIcon = function (element) {\n var id = element.id.concat('_nav');\n var className = 'e-' + element.id.concat('_nav ' + CLS_POPUPNAV);\n className = this.overflowMode === 'Extended' ? className + ' ' + CLS_EXTENDPOPUP : className;\n var nav = this.createElement('div', { id: id, className: className });\n if (Browser.info.name === 'msie' || Browser.info.name === 'edge') {\n nav.classList.add('e-ie-align');\n }\n var navItem = this.createElement('div', { className: CLS_POPUPDOWN + ' e-icons' });\n nav.appendChild(navItem);\n nav.setAttribute('tabindex', '0');\n nav.setAttribute('role', 'button');\n element.appendChild(nav);\n };\n Toolbar.prototype.tbarPriRef = function (inEle, indx, sepPri, el, des, elWid, wid, ig, eleStyles) {\n var ignoreCount = ig;\n var popEle = this.popObj.element;\n var query = '.' + CLS_ITEM + ':not(.' + CLS_SEPARATOR + '):not(.' + CLS_TBAROVERFLOW + ')';\n var priEleCnt = selectAll('.' + CLS_POPUP + ':not(.' + CLS_TBAROVERFLOW + ')', popEle).length;\n var checkClass = function (ele, val) {\n return ele.classList.contains(val);\n };\n if (selectAll(query, inEle).length === 0) {\n var eleSep = inEle.children[indx - (indx - sepPri) - 1];\n var ignoreCheck = (!isNOU(eleSep) && checkClass(eleSep, CLS_TBARIGNORE));\n if ((!isNOU(eleSep) && checkClass(eleSep, CLS_SEPARATOR) && !isVisible(eleSep)) || ignoreCheck) {\n eleSep.style.display = 'unset';\n var eleSepWidth = eleSep.offsetWidth + (parseFloat(window.getComputedStyle(eleSep).marginRight) * 2);\n var prevSep = eleSep.previousElementSibling;\n if ((elWid + eleSepWidth) < wid || des) {\n inEle.insertBefore(el, inEle.children[(indx + ignoreCount) - (indx - sepPri)]);\n if (!isNOU(prevSep)) {\n prevSep.style.display = '';\n }\n }\n else {\n setStyle(el, eleStyles);\n if (prevSep.classList.contains(CLS_SEPARATOR)) {\n prevSep.style.display = 'none';\n }\n }\n eleSep.style.display = '';\n }\n else {\n inEle.insertBefore(el, inEle.children[(indx + ignoreCount) - (indx - sepPri)]);\n }\n }\n else {\n inEle.insertBefore(el, inEle.children[(indx + ignoreCount) - priEleCnt]);\n }\n };\n Toolbar.prototype.popupRefresh = function (popupEle, destroy) {\n var _this = this;\n var ele = this.element;\n var isVer = this.isVertical;\n var innerEle = ele.querySelector('.' + CLS_ITEMS);\n var popNav = ele.querySelector('.' + CLS_TBARNAV);\n if (isNOU(popNav)) {\n return;\n }\n innerEle.removeAttribute('style');\n popupEle.style.display = 'block';\n var dimension;\n if (isVer) {\n dimension = ele.offsetHeight - (popNav.offsetHeight + innerEle.offsetHeight);\n }\n else {\n dimension = ele.offsetWidth - (popNav.offsetWidth + innerEle.offsetWidth);\n }\n var popupEleWidth = 0;\n [].slice.call(popupEle.children).forEach(function (el) {\n popupEleWidth += _this.popupEleWidth(el);\n setStyle(el, { 'position': '' });\n });\n if ((dimension + (isVer ? popNav.offsetHeight : popNav.offsetWidth)) > (popupEleWidth) && this.popupPriCount === 0) {\n destroy = true;\n }\n this.popupEleRefresh(dimension, popupEle, destroy);\n popupEle.style.display = '';\n if (popupEle.children.length === 0 && popNav && this.popObj) {\n detach(popNav);\n popNav = null;\n this.popObj.destroy();\n detach(this.popObj.element);\n this.popObj = null;\n }\n };\n Toolbar.prototype.ignoreEleFetch = function (index, innerEle) {\n var ignoreEle = [].slice.call(innerEle.querySelectorAll('.' + CLS_TBARIGNORE));\n var ignoreInx = [];\n var count = 0;\n if (ignoreEle.length > 0) {\n ignoreEle.forEach(function (ele) {\n ignoreInx.push([].slice.call(innerEle.children).indexOf(ele));\n });\n }\n else {\n return 0;\n }\n ignoreInx.forEach(function (val) {\n if (val <= index) {\n count++;\n }\n });\n return count;\n };\n Toolbar.prototype.checkPopupRefresh = function (root, popEle) {\n popEle.style.display = 'block';\n var elWid = this.popupEleWidth(popEle.firstElementChild);\n popEle.firstElementChild.style.removeProperty('Position');\n var tbarWidth = root.offsetWidth - root.querySelector('.' + CLS_TBARNAV).offsetWidth;\n var tbarItemsWid = root.querySelector('.' + CLS_ITEMS).offsetWidth;\n popEle.style.removeProperty('display');\n if (tbarWidth > (elWid + tbarItemsWid)) {\n return true;\n }\n return false;\n };\n Toolbar.prototype.popupEleWidth = function (el) {\n el.style.position = 'absolute';\n var elWidth = this.isVertical ? el.offsetHeight : el.offsetWidth;\n var btnText = el.querySelector('.' + CLS_TBARBTNTEXT);\n if (el.classList.contains('e-tbtn-align') || el.classList.contains(CLS_TBARTEXT)) {\n var btn = el.children[0];\n if (!isNOU(btnText) && el.classList.contains(CLS_TBARTEXT)) {\n btnText.style.display = 'none';\n }\n else if (!isNOU(btnText) && el.classList.contains(CLS_POPUPTEXT)) {\n btnText.style.display = 'block';\n }\n btn.style.minWidth = '0%';\n elWidth = parseFloat(!this.isVertical ? el.style.minWidth : el.style.minHeight);\n btn.style.minWidth = '';\n btn.style.minHeight = '';\n if (!isNOU(btnText)) {\n btnText.style.display = '';\n }\n }\n return elWidth;\n };\n Toolbar.prototype.popupEleRefresh = function (width, popupEle, destroy) {\n var popPriority = this.popupPriCount > 0;\n var eleSplice = this.tbarEle;\n var priEleCnt;\n var index;\n var innerEle = this.element.querySelector('.' + CLS_ITEMS);\n var ignoreCount = 0;\n var _loop_1 = function (el) {\n if (el.classList.contains(CLS_POPPRI) && popPriority && !destroy) {\n return \"continue\";\n }\n var elWidth = this_1.popupEleWidth(el);\n if (el === this_1.tbarEle[0]) {\n elWidth += this_1.tbarEleMrgn;\n }\n el.style.position = '';\n if (elWidth < width || destroy) {\n var inlineStyles = { minWidth: el.style.minWidth, height: el.style.height, minHeight: el.style.minHeight };\n setStyle(el, { minWidth: '', height: '', minHeight: '' });\n if (!el.classList.contains(CLS_POPOVERFLOW)) {\n el.classList.remove(CLS_POPUP);\n }\n index = this_1.tbarEle.indexOf(el);\n if (this_1.tbarAlign) {\n var pos = this_1.items[parseInt(index.toString(), 10)].align;\n index = this_1.tbarAlgEle[(pos + 's').toLowerCase()].indexOf(el);\n eleSplice = this_1.tbarAlgEle[(pos + 's').toLowerCase()];\n innerEle = this_1.element.querySelector('.' + CLS_ITEMS + ' .' + 'e-toolbar-' + pos.toLowerCase());\n }\n var sepBeforePri_1 = 0;\n if (this_1.overflowMode !== 'Extended') {\n eleSplice.slice(0, index).forEach(function (el) {\n if (el.classList.contains(CLS_TBAROVERFLOW) || el.classList.contains(CLS_SEPARATOR)) {\n if (el.classList.contains(CLS_SEPARATOR)) {\n el.style.display = '';\n width -= el.offsetWidth;\n }\n sepBeforePri_1++;\n }\n });\n }\n ignoreCount = this_1.ignoreEleFetch(index, innerEle);\n if (el.classList.contains(CLS_TBAROVERFLOW)) {\n this_1.tbarPriRef(innerEle, index, sepBeforePri_1, el, destroy, elWidth, width, ignoreCount, inlineStyles);\n width -= el.offsetWidth;\n }\n else if (index === 0) {\n innerEle.insertBefore(el, innerEle.firstChild);\n width -= el.offsetWidth;\n }\n else {\n priEleCnt = selectAll('.' + CLS_TBAROVERFLOW, this_1.popObj.element).length;\n innerEle.insertBefore(el, innerEle.children[(index + ignoreCount) - priEleCnt]);\n width -= el.offsetWidth;\n }\n el.style.height = '';\n }\n else {\n return \"break\";\n }\n };\n var this_1 = this;\n for (var _i = 0, _a = [].slice.call(popupEle.children); _i < _a.length; _i++) {\n var el = _a[_i];\n var state_1 = _loop_1(el);\n if (state_1 === \"break\")\n break;\n }\n var checkOverflow = this.checkOverflow(this.element, this.element.getElementsByClassName(CLS_ITEMS)[0]);\n if (checkOverflow && !destroy) {\n this.renderOverflowMode();\n }\n };\n Toolbar.prototype.removePositioning = function () {\n var item = this.element.querySelector('.' + CLS_ITEMS);\n if (isNOU(item) || !item.classList.contains(CLS_TBARPOS)) {\n return;\n }\n this.remove(item, CLS_TBARPOS);\n var innerItem = [].slice.call(item.childNodes);\n innerItem[1].removeAttribute('style');\n innerItem[2].removeAttribute('style');\n };\n Toolbar.prototype.refreshPositioning = function () {\n var item = this.element.querySelector('.' + CLS_ITEMS);\n this.add(item, CLS_TBARPOS);\n this.itemPositioning();\n };\n Toolbar.prototype.itemPositioning = function () {\n var item = this.element.querySelector('.' + CLS_ITEMS);\n var margin;\n if (isNOU(item) || !item.classList.contains(CLS_TBARPOS)) {\n return;\n }\n var popupNav = this.element.querySelector('.' + CLS_TBARNAV);\n var innerItem;\n if (this.scrollModule) {\n var trgClass = (this.isVertical) ? CLS_VSCROLLCNT : CLS_HSCROLLCNT;\n innerItem = [].slice.call(item.querySelector('.' + trgClass).children);\n }\n else {\n innerItem = [].slice.call(item.childNodes);\n }\n if (this.isVertical) {\n margin = innerItem[0].offsetHeight + innerItem[2].offsetHeight;\n }\n else {\n margin = innerItem[0].offsetWidth + innerItem[2].offsetWidth;\n }\n var tbarWid = this.isVertical ? this.element.offsetHeight : this.element.offsetWidth;\n if (popupNav) {\n tbarWid -= (this.isVertical ? popupNav.offsetHeight : popupNav.offsetWidth);\n var popWid = (this.isVertical ? popupNav.offsetHeight : popupNav.offsetWidth) + 'px';\n innerItem[2].removeAttribute('style');\n if (this.isVertical) {\n if (this.enableRtl) {\n innerItem[2].style.top = popWid;\n }\n else {\n innerItem[2].style.bottom = popWid;\n }\n }\n else {\n if (this.enableRtl) {\n innerItem[2].style.left = popWid;\n }\n else {\n innerItem[2].style.right = popWid;\n }\n }\n }\n if (tbarWid <= margin) {\n return;\n }\n var value = (((tbarWid - margin)) - (!this.isVertical ? innerItem[1].offsetWidth : innerItem[1].offsetHeight)) / 2;\n innerItem[1].removeAttribute('style');\n var mrgn = ((!this.isVertical ? innerItem[0].offsetWidth : innerItem[0].offsetHeight) + value) + 'px';\n if (this.isVertical) {\n if (this.enableRtl) {\n innerItem[1].style.marginBottom = mrgn;\n }\n else {\n innerItem[1].style.marginTop = mrgn;\n }\n }\n else {\n if (this.enableRtl) {\n innerItem[1].style.marginRight = mrgn;\n }\n else {\n innerItem[1].style.marginLeft = mrgn;\n }\n }\n };\n Toolbar.prototype.tbarItemAlign = function (item, itemEle, pos) {\n var _this = this;\n if (item.showAlwaysInPopup && item.overflow !== 'Show') {\n return;\n }\n var alignDiv = [];\n alignDiv.push(this.createElement('div', { className: CLS_TBARLEFT }));\n alignDiv.push(this.createElement('div', { className: CLS_TBARCENTER }));\n alignDiv.push(this.createElement('div', { className: CLS_TBARRIGHT }));\n if (pos === 0 && item.align !== 'Left') {\n alignDiv.forEach(function (ele) {\n itemEle.appendChild(ele);\n });\n this.tbarAlign = true;\n this.add(itemEle, CLS_TBARPOS);\n }\n else if (item.align !== 'Left') {\n var alignEle = itemEle.childNodes;\n var leftAlign_1 = alignDiv[0];\n [].slice.call(alignEle).forEach(function (el) {\n _this.tbarAlgEle.lefts.push(el);\n leftAlign_1.appendChild(el);\n });\n itemEle.appendChild(leftAlign_1);\n itemEle.appendChild(alignDiv[1]);\n itemEle.appendChild(alignDiv[2]);\n this.tbarAlign = true;\n this.add(itemEle, CLS_TBARPOS);\n }\n };\n Toolbar.prototype.ctrlTemplate = function () {\n var _this = this;\n this.ctrlTem = this.trgtEle.cloneNode(true);\n this.add(this.trgtEle, CLS_ITEMS);\n this.tbarEle = [];\n var innerEle = [].slice.call(this.trgtEle.children);\n innerEle.forEach(function (ele) {\n if (ele.tagName === 'DIV') {\n _this.tbarEle.push(ele);\n if (!isNOU(ele.firstElementChild)) {\n ele.firstElementChild.setAttribute('aria-disabled', 'false');\n }\n _this.add(ele, CLS_ITEM);\n }\n });\n };\n Toolbar.prototype.renderItems = function () {\n var ele = this.element;\n var items = this.items;\n if (this.trgtEle != null) {\n this.ctrlTemplate();\n }\n else if (ele && items.length > 0) {\n var itemEleDom = void 0;\n if (ele && ele.children.length > 0) {\n itemEleDom = ele.querySelector('.' + CLS_ITEMS);\n }\n if (!itemEleDom) {\n itemEleDom = this.createElement('div', { className: CLS_ITEMS });\n }\n this.itemsAlign(items, itemEleDom);\n ele.appendChild(itemEleDom);\n }\n };\n Toolbar.prototype.setAttr = function (attr, element) {\n var key = Object.keys(attr);\n var keyVal;\n for (var i = 0; i < key.length; i++) {\n keyVal = key[parseInt(i.toString(), 10)];\n if (keyVal === 'class') {\n this.add(element, attr[\"\" + keyVal]);\n }\n else {\n element.setAttribute(keyVal, attr[\"\" + keyVal]);\n }\n }\n };\n /**\n * Enables or disables the specified Toolbar item.\n *\n * @param {number|HTMLElement|NodeList} items - DOM element or an array of items to be enabled or disabled.\n * @param {boolean} isEnable - Boolean value that determines whether the command should be enabled or disabled.\n * By default, `isEnable` is set to true.\n * @returns {void}.\n */\n Toolbar.prototype.enableItems = function (items, isEnable) {\n var elements = items;\n var len = elements.length;\n var ele;\n if (isNOU(isEnable)) {\n isEnable = true;\n }\n var enable = function (isEnable, ele) {\n if (isEnable) {\n ele.classList.remove(CLS_DISABLE);\n if (!isNOU(ele.firstElementChild)) {\n ele.firstElementChild.setAttribute('aria-disabled', 'false');\n }\n }\n else {\n ele.classList.add(CLS_DISABLE);\n if (!isNOU(ele.firstElementChild)) {\n ele.firstElementChild.setAttribute('aria-disabled', 'true');\n }\n }\n };\n if (!isNOU(len) && len >= 1) {\n for (var a = 0, element = [].slice.call(elements); a < len; a++) {\n var itemElement = element[parseInt(a.toString(), 10)];\n if (typeof (itemElement) === 'number') {\n ele = this.getElementByIndex(itemElement);\n if (isNOU(ele)) {\n return;\n }\n else {\n elements[parseInt(a.toString(), 10)] = ele;\n }\n }\n else {\n ele = itemElement;\n }\n enable(isEnable, ele);\n }\n if (isEnable) {\n removeClass(elements, CLS_DISABLE);\n }\n else {\n addClass(elements, CLS_DISABLE);\n }\n }\n else {\n if (typeof (elements) === 'number') {\n ele = this.getElementByIndex(elements);\n if (isNOU(ele)) {\n return;\n }\n }\n else {\n ele = items;\n }\n enable(isEnable, ele);\n }\n };\n Toolbar.prototype.getElementByIndex = function (index) {\n if (this.tbarEle[parseInt(index.toString(), 10)]) {\n return this.tbarEle[parseInt(index.toString(), 10)];\n }\n return null;\n };\n /**\n * Adds new items to the Toolbar that accepts an array as Toolbar items.\n *\n * @param {ItemModel[]} items - DOM element or an array of items to be added to the Toolbar.\n * @param {number} index - Number value that determines where the command is to be added. By default, index is 0.\n * @returns {void}.\n */\n Toolbar.prototype.addItems = function (items, index) {\n var innerItems;\n this.extendedOpen();\n var itemsDiv = this.element.querySelector('.' + CLS_ITEMS);\n if (isNOU(itemsDiv)) {\n this.itemsRerender(items);\n return;\n }\n var innerEle;\n var itemAgn = 'Left';\n if (isNOU(index)) {\n index = 0;\n }\n items.forEach(function (e) {\n if (!isNOU(e.align) && e.align !== 'Left' && itemAgn === 'Left') {\n itemAgn = e.align;\n }\n });\n for (var _i = 0, items_1 = items; _i < items_1.length; _i++) {\n var item = items_1[_i];\n if (isNOU(item.type)) {\n item.type = 'Button';\n }\n innerItems = selectAll('.' + CLS_ITEM, this.element);\n item.align = itemAgn;\n innerEle = this.renderSubComponent(item, index);\n if (this.tbarEle.length >= index && innerItems.length >= 0) {\n if (isNOU(this.scrollModule)) {\n this.destroyMode();\n }\n var algIndex = item.align[0] === 'L' ? 0 : item.align[0] === 'C' ? 1 : 2;\n var ele = void 0;\n if (!this.tbarAlign && itemAgn !== 'Left') {\n this.tbarItemAlign(item, itemsDiv, 1);\n this.tbarAlign = true;\n ele = closest(innerItems[0], '.' + CLS_ITEMS).children[parseInt(algIndex.toString(), 10)];\n ele.appendChild(innerEle);\n this.tbarAlgEle[(item.align + 's').toLowerCase()].push(innerEle);\n this.refreshPositioning();\n }\n else if (this.tbarAlign) {\n ele = closest(innerItems[0], '.' + CLS_ITEMS).children[parseInt(algIndex.toString(), 10)];\n ele.insertBefore(innerEle, ele.children[parseInt(index.toString(), 10)]);\n this.tbarAlgEle[(item.align + 's').toLowerCase()].splice(index, 0, innerEle);\n this.refreshPositioning();\n }\n else if (innerItems.length === 0) {\n innerItems = selectAll('.' + CLS_ITEMS, this.element);\n innerItems[0].appendChild(innerEle);\n }\n else {\n innerItems[0].parentNode.insertBefore(innerEle, innerItems[parseInt(index.toString(), 10)]);\n }\n this.items.splice(index, 0, item);\n if (item.template) {\n this.tbarEle.splice(this.tbarEle.length - 1, 1);\n }\n this.tbarEle.splice(index, 0, innerEle);\n index++;\n this.offsetWid = itemsDiv.offsetWidth;\n }\n }\n itemsDiv.style.width = '';\n this.renderOverflowMode();\n if (this.isReact) {\n this.renderReactTemplates();\n }\n };\n /**\n * Removes the items from the Toolbar. Acceptable arguments are index of item/HTMLElement/node list.\n *\n * @param {number|HTMLElement|NodeList|HTMLElement[]} args\n * Index or DOM element or an Array of item which is to be removed from the Toolbar.\n * @returns {void}.\n */\n Toolbar.prototype.removeItems = function (args) {\n var elements = args;\n var index;\n var innerItems = [].slice.call(selectAll('.' + CLS_ITEM, this.element));\n if (typeof (elements) === 'number') {\n index = parseInt(args.toString(), 10);\n this.removeItemByIndex(index, innerItems);\n }\n else {\n if (elements && elements.length > 1) {\n for (var _i = 0, _a = [].slice.call(elements); _i < _a.length; _i++) {\n var ele = _a[_i];\n index = this.tbarEle.indexOf(ele);\n this.removeItemByIndex(index, innerItems);\n innerItems = selectAll('.' + CLS_ITEM, this.element);\n }\n }\n else {\n var ele = (elements && elements.length && elements.length === 1) ? elements[0] : args;\n index = innerItems.indexOf(ele);\n this.removeItemByIndex(index, innerItems);\n }\n }\n this.resize();\n };\n Toolbar.prototype.removeItemByIndex = function (index, innerItems) {\n if (this.tbarEle[parseInt(index.toString(), 10)] && innerItems[parseInt(index.toString(), 10)]) {\n var eleIdx = this.tbarEle.indexOf(innerItems[parseInt(index.toString(), 10)]);\n if (this.tbarAlign) {\n var indexAgn = this.tbarAlgEle[(this.items[parseInt(eleIdx.toString(), 10)].align + 's').toLowerCase()].indexOf(this.tbarEle[parseInt(eleIdx.toString(), 10)]);\n this.tbarAlgEle[(this.items[parseInt(eleIdx.toString(), 10)].align + 's').toLowerCase()].splice(parseInt(indexAgn.toString(), 10), 1);\n }\n if (this.isReact) {\n this.clearToolbarTemplate(innerItems[parseInt(index.toString(), 10)]);\n }\n var btnItem = innerItems[parseInt(index.toString(), 10)].querySelector('.e-control.e-btn');\n if (!isNOU(btnItem) && !isNOU(btnItem.ej2_instances[0]) && !(btnItem.ej2_instances[0].isDestroyed)) {\n btnItem.ej2_instances[0].destroy();\n }\n detach(innerItems[parseInt(index.toString(), 10)]);\n this.items.splice(eleIdx, 1);\n this.tbarEle.splice(eleIdx, 1);\n }\n };\n Toolbar.prototype.templateRender = function (templateProp, innerEle, item, index) {\n var itemType = item.type;\n var eleObj = templateProp;\n var isComponent;\n if (typeof (templateProp) === 'object') {\n isComponent = typeof (eleObj.appendTo) === 'function';\n }\n if (typeof (templateProp) === 'string' || !isComponent) {\n var templateFn = void 0;\n var val = templateProp;\n var regEx = new RegExp(/<(?=.*? .*?\\/ ?>|br|hr|input|!--|wbr)[a-z]+.*?>|<([a-z]+).*?<\\/\\1>/i);\n val = (typeof (templateProp) === 'string') ? templateProp.trim() : templateProp;\n try {\n if (typeof (templateProp) === 'object' && !isNOU(templateProp.tagName)) {\n innerEle.appendChild(templateProp);\n }\n else if (typeof (templateProp) === 'string' && regEx.test(val)) {\n innerEle.innerHTML = val;\n }\n else if (document.querySelectorAll(val).length) {\n var ele = document.querySelector(val);\n var tempStr = ele.outerHTML.trim();\n innerEle.appendChild(ele);\n ele.style.display = '';\n if (!isNOU(tempStr)) {\n this.tempId.push(val);\n }\n }\n else {\n templateFn = templateCompiler(val);\n }\n }\n catch (e) {\n templateFn = templateCompiler(val);\n }\n var tempArray = void 0;\n if (!isNOU(templateFn)) {\n var toolbarTemplateID = this.element.id + index + '_template';\n tempArray = templateFn({}, this, 'template', toolbarTemplateID, this.isStringTemplate, undefined, undefined, this.root);\n }\n if (!isNOU(tempArray) && tempArray.length > 0) {\n [].slice.call(tempArray).forEach(function (ele) {\n if (!isNOU(ele.tagName)) {\n ele.style.display = '';\n }\n innerEle.appendChild(ele);\n });\n }\n }\n else if (itemType === 'Input') {\n var ele = this.createElement('input');\n if (item.id) {\n ele.id = item.id;\n }\n else {\n ele.id = getUniqueID('tbr-ipt');\n }\n innerEle.appendChild(ele);\n eleObj.appendTo(ele);\n }\n this.add(innerEle, CLS_TEMPLATE);\n var firstChild = innerEle.firstElementChild;\n if (!isNOU(firstChild)) {\n firstChild.setAttribute('tabindex', isNOU(firstChild.getAttribute(\"tabIndex\")) ? '-1' : this.getDataTabindex(firstChild));\n firstChild.setAttribute('data-tabindex', isNOU(firstChild.getAttribute(\"tabIndex\")) ? '-1' : this.getDataTabindex(firstChild));\n }\n this.tbarEle.push(innerEle);\n };\n Toolbar.prototype.buttonRendering = function (item, innerEle) {\n var dom = this.createElement('button', { className: CLS_TBARBTN });\n dom.setAttribute('type', 'button');\n var textStr = item.text;\n var iconCss;\n var iconPos;\n if (item.id) {\n dom.id = item.id;\n }\n else {\n dom.id = getUniqueID('e-tbr-btn');\n }\n var btnTxt = this.createElement('span', { className: 'e-tbar-btn-text' });\n if (textStr) {\n btnTxt.innerHTML = this.enableHtmlSanitizer ? SanitizeHtmlHelper.sanitize(textStr) : textStr;\n dom.appendChild(btnTxt);\n dom.classList.add('e-tbtn-txt');\n }\n else {\n this.add(innerEle, 'e-tbtn-align');\n }\n if (item.prefixIcon || item.suffixIcon) {\n if ((item.prefixIcon && item.suffixIcon) || item.prefixIcon) {\n iconCss = item.prefixIcon + ' e-icons';\n iconPos = 'Left';\n }\n else {\n iconCss = item.suffixIcon + ' e-icons';\n iconPos = 'Right';\n }\n }\n var btnObj = new Button({ iconCss: iconCss, iconPosition: iconPos });\n btnObj.createElement = this.createElement;\n btnObj.appendTo(dom);\n if (item.width) {\n setStyle(dom, { 'width': formatUnit(item.width) });\n }\n return dom;\n };\n Toolbar.prototype.renderSubComponent = function (item, index) {\n var dom;\n var innerEle = this.createElement('div', { className: CLS_ITEM });\n var tempDom = this.createElement('div', {\n innerHTML: this.enableHtmlSanitizer && !isNOU(item.tooltipText) ?\n SanitizeHtmlHelper.sanitize(item.tooltipText) : item.tooltipText\n });\n if (!this.tbarEle) {\n this.tbarEle = [];\n }\n if (item.htmlAttributes) {\n this.setAttr(item.htmlAttributes, innerEle);\n }\n if (item.tooltipText) {\n innerEle.setAttribute('title', tempDom.textContent);\n }\n if (item.cssClass) {\n innerEle.className = innerEle.className + ' ' + item.cssClass;\n }\n if (item.template) {\n this.templateRender(item.template, innerEle, item, index);\n }\n else {\n switch (item.type) {\n case 'Button':\n dom = this.buttonRendering(item, innerEle);\n dom.setAttribute('tabindex', isNOU(item.tabIndex) ? '-1' : item.tabIndex.toString());\n dom.setAttribute('data-tabindex', isNOU(item.tabIndex) ? '-1' : item.tabIndex.toString());\n dom.setAttribute('aria-label', (item.text || item.tooltipText));\n dom.setAttribute('aria-disabled', 'false');\n innerEle.appendChild(dom);\n innerEle.addEventListener('click', this.itemClick.bind(this));\n break;\n case 'Separator':\n this.add(innerEle, CLS_SEPARATOR);\n break;\n }\n }\n if (item.showTextOn) {\n var sTxt = item.showTextOn;\n if (sTxt === 'Toolbar') {\n this.add(innerEle, CLS_POPUPTEXT);\n this.add(innerEle, 'e-tbtn-align');\n }\n else if (sTxt === 'Overflow') {\n this.add(innerEle, CLS_TBARTEXT);\n }\n }\n if (item.overflow) {\n var overflow = item.overflow;\n if (overflow === 'Show') {\n this.add(innerEle, CLS_TBAROVERFLOW);\n }\n else if (overflow === 'Hide') {\n if (!innerEle.classList.contains(CLS_SEPARATOR)) {\n this.add(innerEle, CLS_POPOVERFLOW);\n }\n }\n }\n if (item.overflow !== 'Show' && item.showAlwaysInPopup && !innerEle.classList.contains(CLS_SEPARATOR)) {\n this.add(innerEle, CLS_POPPRI);\n this.popupPriCount++;\n }\n if (item.disabled) {\n this.add(innerEle, CLS_DISABLE);\n }\n if (item.visible === false) {\n this.add(innerEle, CLS_HIDDEN);\n }\n return innerEle;\n };\n Toolbar.prototype.getDataTabindex = function (ele) {\n return isNOU(ele.getAttribute('data-tabindex')) ? '-1' : ele.getAttribute('data-tabindex');\n };\n Toolbar.prototype.itemClick = function (e) {\n this.activeEleSwitch(e.currentTarget);\n };\n Toolbar.prototype.activeEleSwitch = function (ele) {\n this.activeEleRemove(ele.firstElementChild);\n this.activeEle.focus();\n };\n Toolbar.prototype.activeEleRemove = function (curEle) {\n if (!isNOU(this.activeEle)) {\n this.activeEle.setAttribute('tabindex', this.getDataTabindex(this.activeEle));\n }\n this.activeEle = curEle;\n if (this.getDataTabindex(this.activeEle) === '-1') {\n if (isNOU(this.trgtEle) && !curEle.parentElement.classList.contains(CLS_TEMPLATE)) {\n this.updateTabIndex('-1');\n curEle.removeAttribute('tabindex');\n }\n else {\n var tabIndex = parseInt(this.getDataTabindex(this.activeEle)) + 1;\n this.activeEle.setAttribute('tabindex', tabIndex.toString());\n }\n }\n };\n Toolbar.prototype.getPersistData = function () {\n return this.addOnPersist([]);\n };\n /**\n * Returns the current module name.\n *\n * @returns {string} - Returns the module name as string.\n * @private\n */\n Toolbar.prototype.getModuleName = function () {\n return 'toolbar';\n };\n Toolbar.prototype.itemsRerender = function (newProp) {\n this.items = this.tbarItemsCol;\n if (this.isReact || this.isAngular) {\n this.clearTemplate();\n }\n this.destroyMode();\n this.destroyItems();\n this.items = newProp;\n this.tbarItemsCol = this.items;\n this.renderItems();\n this.renderOverflowMode();\n if (this.isReact) {\n this.renderReactTemplates();\n }\n };\n Toolbar.prototype.resize = function () {\n var ele = this.element;\n this.tbResize = true;\n if (this.tbarAlign) {\n this.itemPositioning();\n }\n if (this.popObj && this.overflowMode === 'Popup') {\n this.popObj.hide();\n }\n var checkOverflow = this.checkOverflow(ele, ele.getElementsByClassName(CLS_ITEMS)[0]);\n if (!checkOverflow) {\n this.destroyScroll();\n var multirowele = ele.querySelector('.' + CLS_ITEMS);\n if (!isNOU(multirowele)) {\n this.remove(multirowele, CLS_MULTIROWPOS);\n if (this.tbarAlign) {\n this.add(multirowele, CLS_TBARPOS);\n }\n }\n }\n if (checkOverflow && this.scrollModule && (this.offsetWid === ele.offsetWidth)) {\n return;\n }\n if (this.offsetWid > ele.offsetWidth || checkOverflow) {\n this.renderOverflowMode();\n }\n if (this.popObj) {\n if (this.overflowMode === 'Extended') {\n var eleStyles = window.getComputedStyle(this.element);\n this.popObj.width = parseFloat(eleStyles.width) + ((parseFloat(eleStyles.borderRightWidth)) * 2);\n }\n if (this.tbarAlign) {\n this.removePositioning();\n }\n this.popupRefresh(this.popObj.element, false);\n if (this.tbarAlign) {\n this.refreshPositioning();\n }\n }\n if (this.element.querySelector('.' + CLS_HSCROLLBAR)) {\n this.scrollStep = this.element.querySelector('.' + CLS_HSCROLLBAR).offsetWidth;\n }\n this.offsetWid = ele.offsetWidth;\n this.tbResize = false;\n this.separator();\n };\n Toolbar.prototype.orientationChange = function () {\n var _this = this;\n setTimeout(function () {\n _this.resize();\n }, 500);\n };\n Toolbar.prototype.extendedOpen = function () {\n var sib = this.element.querySelector('.' + CLS_EXTENDABLECLASS);\n if (this.overflowMode === 'Extended' && sib) {\n this.isExtendedOpen = sib.classList.contains(CLS_POPUPOPEN);\n }\n };\n Toolbar.prototype.updateHideEleTabIndex = function (ele, isHidden, isElement, eleIndex, innerItems) {\n if (isElement) {\n eleIndex = innerItems.indexOf(ele);\n }\n var nextEle = innerItems[++eleIndex];\n while (nextEle) {\n var skipEle = this.eleContains(nextEle);\n if (!skipEle) {\n var dataTabIndex = nextEle.firstElementChild.getAttribute('data-tabindex');\n if (isHidden && dataTabIndex === '-1') {\n nextEle.firstElementChild.setAttribute('tabindex', '0');\n }\n else if (dataTabIndex !== nextEle.firstElementChild.getAttribute('tabindex')) {\n nextEle.firstElementChild.setAttribute('tabindex', dataTabIndex);\n }\n break;\n }\n nextEle = innerItems[++eleIndex];\n }\n };\n Toolbar.prototype.clearToolbarTemplate = function (templateEle) {\n if (this.registeredTemplate && this.registeredTemplate[\"\" + 'template']) {\n var registeredTemplates = this.registeredTemplate;\n for (var index = 0; index < registeredTemplates[\"\" + 'template'].length; index++) {\n var registeredItem = registeredTemplates[\"\" + 'template'][parseInt(index.toString(), 10)].rootNodes[0];\n var closestItem = closest(registeredItem, '.' + CLS_ITEM);\n if (!isNOU(closestItem) && closestItem === templateEle) {\n this.clearTemplate(['template'], [registeredTemplates[\"\" + 'template'][parseInt(index.toString(), 10)]]);\n break;\n }\n }\n }\n else if (this.portals && this.portals.length > 0) {\n var portals = this.portals;\n for (var index = 0; index < portals.length; index++) {\n var portalItem = portals[parseInt(index.toString(), 10)];\n var closestItem = closest(portalItem.containerInfo, '.' + CLS_ITEM);\n if (!isNOU(closestItem) && closestItem === templateEle) {\n this.clearTemplate(['template'], index);\n break;\n }\n }\n }\n };\n /**\n * Gets called when the model property changes.The data that describes the old and new values of the property that changed.\n *\n * @param {ToolbarModel} newProp - It contains new value of the data.\n * @param {ToolbarModel} oldProp - It contains old value of the data.\n * @returns {void}\n * @private\n */\n Toolbar.prototype.onPropertyChanged = function (newProp, oldProp) {\n var tEle = this.element;\n var wid = tEle.offsetWidth;\n this.extendedOpen();\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'items':\n if (!(newProp.items instanceof Array && oldProp.items instanceof Array)) {\n var changedProb = Object.keys(newProp.items);\n for (var i = 0; i < changedProb.length; i++) {\n var index = parseInt(Object.keys(newProp.items)[parseInt(i.toString(), 10)], 10);\n var property = Object.keys(newProp.items[parseInt(index.toString(), 10)])[0];\n var newProperty = Object(newProp.items[parseInt(index.toString(), 10)])[\"\" + property];\n if (this.tbarAlign || property === 'align') {\n this.refresh();\n this.trigger('created');\n break;\n }\n var popupPriCheck = property === 'showAlwaysInPopup' && !newProperty;\n var booleanCheck = property === 'overflow' && this.popupPriCount !== 0;\n if ((popupPriCheck) || (this.items[parseInt(index.toString(), 10)].showAlwaysInPopup) && booleanCheck) {\n --this.popupPriCount;\n }\n if (isNOU(this.scrollModule)) {\n this.destroyMode();\n }\n var itemCol = [].slice.call(selectAll('.' + CLS_ITEMS + ' .' + CLS_ITEM, tEle));\n if (this.isReact && this.items[parseInt(index.toString(), 10)].template) {\n this.clearToolbarTemplate(itemCol[parseInt(index.toString(), 10)]);\n }\n detach(itemCol[parseInt(index.toString(), 10)]);\n this.tbarEle.splice(index, 1);\n this.addItems([this.items[parseInt(index.toString(), 10)]], index);\n this.items.splice(index, 1);\n if (this.items[parseInt(index.toString(), 10)].template) {\n this.tbarEle.splice(this.items.length, 1);\n }\n }\n }\n else {\n this.itemsRerender(newProp.items);\n }\n break;\n case 'width':\n setStyle(tEle, { 'width': formatUnit(newProp.width) });\n this.refreshOverflow();\n break;\n case 'height':\n setStyle(this.element, { 'height': formatUnit(newProp.height) });\n break;\n case 'overflowMode':\n this.destroyMode();\n this.renderOverflowMode();\n if (this.enableRtl) {\n this.add(tEle, CLS_RTL);\n }\n this.refreshOverflow();\n break;\n case 'enableRtl':\n if (newProp.enableRtl) {\n this.add(tEle, CLS_RTL);\n }\n else {\n this.remove(tEle, CLS_RTL);\n }\n if (!isNOU(this.scrollModule)) {\n if (newProp.enableRtl) {\n this.add(this.scrollModule.element, CLS_RTL);\n }\n else {\n this.remove(this.scrollModule.element, CLS_RTL);\n }\n }\n if (!isNOU(this.popObj)) {\n if (newProp.enableRtl) {\n this.add(this.popObj.element, CLS_RTL);\n }\n else {\n this.remove(this.popObj.element, CLS_RTL);\n }\n }\n if (this.tbarAlign) {\n this.itemPositioning();\n }\n break;\n case 'scrollStep':\n if (this.scrollModule) {\n this.scrollModule.scrollStep = this.scrollStep;\n }\n break;\n case 'enableCollision':\n if (this.popObj) {\n this.popObj.collision = { Y: this.enableCollision ? 'flip' : 'none' };\n }\n break;\n case 'cssClass':\n if (oldProp.cssClass) {\n removeClass([this.element], oldProp.cssClass.split(' '));\n }\n if (newProp.cssClass) {\n addClass([this.element], newProp.cssClass.split(' '));\n }\n break;\n case 'allowKeyboard':\n this.unwireKeyboardEvent();\n if (newProp.allowKeyboard) {\n this.wireKeyboardEvent();\n }\n break;\n }\n }\n };\n /**\n * Shows or hides the Toolbar item that is in the specified index.\n *\n * @param {number | HTMLElement} index - Index value of target item or DOM element of items to be hidden or shown.\n * @param {boolean} value - Based on this Boolean value, item will be hide (true) or show (false). By default, value is false.\n * @returns {void}.\n */\n Toolbar.prototype.hideItem = function (index, value) {\n var isElement = (typeof (index) === 'object') ? true : false;\n var eleIndex = index;\n var ele;\n if (!isElement && isNOU(eleIndex)) {\n return;\n }\n var innerItems = [].slice.call(selectAll('.' + CLS_ITEM, this.element));\n if (isElement) {\n ele = index;\n }\n else if (this.tbarEle[parseInt(eleIndex.toString(), 10)]) {\n var innerItems_1 = [].slice.call(selectAll('.' + CLS_ITEM, this.element));\n ele = innerItems_1[parseInt(eleIndex.toString(), 10)];\n }\n if (ele) {\n if (value) {\n ele.classList.add(CLS_HIDDEN);\n if (!ele.classList.contains(CLS_SEPARATOR)) {\n if (isNOU(ele.firstElementChild.getAttribute('tabindex')) ||\n ele.firstElementChild.getAttribute('tabindex') !== '-1') {\n this.updateHideEleTabIndex(ele, value, isElement, eleIndex, innerItems);\n }\n }\n }\n else {\n ele.classList.remove(CLS_HIDDEN);\n if (!ele.classList.contains(CLS_SEPARATOR)) {\n this.updateHideEleTabIndex(ele, value, isElement, eleIndex, innerItems);\n }\n }\n this.refreshOverflow();\n }\n };\n __decorate([\n Collection([], Item)\n ], Toolbar.prototype, \"items\", void 0);\n __decorate([\n Property('auto')\n ], Toolbar.prototype, \"width\", void 0);\n __decorate([\n Property('auto')\n ], Toolbar.prototype, \"height\", void 0);\n __decorate([\n Property('')\n ], Toolbar.prototype, \"cssClass\", void 0);\n __decorate([\n Property('Scrollable')\n ], Toolbar.prototype, \"overflowMode\", void 0);\n __decorate([\n Property()\n ], Toolbar.prototype, \"scrollStep\", void 0);\n __decorate([\n Property(true)\n ], Toolbar.prototype, \"enableCollision\", void 0);\n __decorate([\n Property(true)\n ], Toolbar.prototype, \"enableHtmlSanitizer\", void 0);\n __decorate([\n Property(true)\n ], Toolbar.prototype, \"allowKeyboard\", void 0);\n __decorate([\n Event()\n ], Toolbar.prototype, \"clicked\", void 0);\n __decorate([\n Event()\n ], Toolbar.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], Toolbar.prototype, \"destroyed\", void 0);\n __decorate([\n Event()\n ], Toolbar.prototype, \"beforeCreate\", void 0);\n Toolbar = __decorate([\n NotifyPropertyChanges\n ], Toolbar);\n return Toolbar;\n}(Component));\nexport { Toolbar };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Touch, Component, EventHandler, selectAll, getUniqueID } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges, Property, Browser, detach } from '@syncfusion/ej2-base';\nimport { classList, isNullOrUndefined } from '@syncfusion/ej2-base';\nvar CLS_ROOT = 'e-hscroll';\nvar CLS_RTL = 'e-rtl';\nvar CLS_DISABLE = 'e-overlay';\nvar CLS_HSCROLLBAR = 'e-hscroll-bar';\nvar CLS_HSCROLLCON = 'e-hscroll-content';\nvar CLS_NAVARROW = 'e-nav-arrow';\nvar CLS_NAVRIGHTARROW = 'e-nav-right-arrow';\nvar CLS_NAVLEFTARROW = 'e-nav-left-arrow';\nvar CLS_HSCROLLNAV = 'e-scroll-nav';\nvar CLS_HSCROLLNAVRIGHT = 'e-scroll-right-nav';\nvar CLS_HSCROLLNAVLEFT = 'e-scroll-left-nav';\nvar CLS_DEVICE = 'e-scroll-device';\nvar CLS_OVERLAY = 'e-scroll-overlay';\nvar CLS_RIGHTOVERLAY = 'e-scroll-right-overlay';\nvar CLS_LEFTOVERLAY = 'e-scroll-left-overlay';\nvar OVERLAY_MAXWID = 40;\n/**\n * HScroll module is introduces horizontal scroller when content exceeds the current viewing area.\n * It can be useful for the components like Toolbar, Tab which needs horizontal scrolling alone.\n * Hidden content can be view by touch moving or icon click.\n * ```html\n * <div id=\"scroll\"/>\n * <script>\n * var scrollObj = new HScroll();\n * scrollObj.appendTo(\"#scroll\");\n * </script>\n * ```\n */\nvar HScroll = /** @class */ (function (_super) {\n __extends(HScroll, _super);\n /**\n * Initializes a new instance of the HScroll class.\n *\n * @param {HScrollModel} options - Specifies HScroll model properties as options.\n * @param {string | HTMLElement} element - Specifies the element for which horizontal scrolling applies.\n */\n function HScroll(options, element) {\n return _super.call(this, options, element) || this;\n }\n /**\n * Initialize the event handler\n *\n * @private\n * @returns {void}\n */\n HScroll.prototype.preRender = function () {\n this.browser = Browser.info.name;\n this.browserCheck = this.browser === 'mozilla';\n this.isDevice = Browser.isDevice;\n this.customStep = true;\n var element = this.element;\n this.ieCheck = this.browser === 'edge' || this.browser === 'msie';\n this.initialize();\n if (element.id === '') {\n element.id = getUniqueID('hscroll');\n this.uniqueId = true;\n }\n element.style.display = 'block';\n if (this.enableRtl) {\n element.classList.add(CLS_RTL);\n }\n };\n /**\n * To Initialize the horizontal scroll rendering\n *\n * @private\n * @returns {void}\n */\n HScroll.prototype.render = function () {\n this.touchModule = new Touch(this.element, { scroll: this.touchHandler.bind(this), swipe: this.swipeHandler.bind(this) });\n EventHandler.add(this.scrollEle, 'scroll', this.scrollHandler, this);\n if (!this.isDevice) {\n this.createNavIcon(this.element);\n }\n else {\n this.element.classList.add(CLS_DEVICE);\n this.createOverlay(this.element);\n }\n this.setScrollState();\n };\n HScroll.prototype.setScrollState = function () {\n if (isNullOrUndefined(this.scrollStep) || this.scrollStep < 0) {\n this.scrollStep = this.scrollEle.offsetWidth;\n this.customStep = false;\n }\n else {\n this.customStep = true;\n }\n };\n HScroll.prototype.initialize = function () {\n var scrollEle = this.createElement('div', { className: CLS_HSCROLLCON });\n var scrollDiv = this.createElement('div', { className: CLS_HSCROLLBAR });\n scrollDiv.setAttribute('tabindex', '-1');\n var ele = this.element;\n var innerEle = [].slice.call(ele.children);\n for (var _i = 0, innerEle_1 = innerEle; _i < innerEle_1.length; _i++) {\n var ele_1 = innerEle_1[_i];\n scrollEle.appendChild(ele_1);\n }\n scrollDiv.appendChild(scrollEle);\n ele.appendChild(scrollDiv);\n scrollDiv.style.overflowX = 'hidden';\n this.scrollEle = scrollDiv;\n this.scrollItems = scrollEle;\n };\n HScroll.prototype.getPersistData = function () {\n var keyEntity = ['scrollStep'];\n return this.addOnPersist(keyEntity);\n };\n /**\n * Returns the current module name.\n *\n * @returns {string} - It returns the current module name.\n * @private\n */\n HScroll.prototype.getModuleName = function () {\n return 'hScroll';\n };\n /**\n * Removes the control from the DOM and also removes all its related events.\n *\n * @returns {void}\n */\n HScroll.prototype.destroy = function () {\n var ele = this.element;\n ele.style.display = '';\n ele.classList.remove(CLS_ROOT);\n ele.classList.remove(CLS_DEVICE);\n ele.classList.remove(CLS_RTL);\n var nav = selectAll('.e-' + ele.id + '_nav.' + CLS_HSCROLLNAV, ele);\n var overlay = selectAll('.' + CLS_OVERLAY, ele);\n [].slice.call(overlay).forEach(function (ele) {\n detach(ele);\n });\n for (var _i = 0, _a = [].slice.call(this.scrollItems.children); _i < _a.length; _i++) {\n var elem = _a[_i];\n ele.appendChild(elem);\n }\n if (this.uniqueId) {\n this.element.removeAttribute('id');\n }\n detach(this.scrollEle);\n if (nav.length > 0) {\n detach(nav[0]);\n if (!isNullOrUndefined(nav[1])) {\n detach(nav[1]);\n }\n }\n EventHandler.remove(this.scrollEle, 'scroll', this.scrollHandler);\n this.touchModule.destroy();\n this.touchModule = null;\n _super.prototype.destroy.call(this);\n };\n /**\n * Specifies the value to disable/enable the HScroll component.\n * When set to `true` , the component will be disabled.\n *\n * @param {boolean} value - Based on this Boolean value, HScroll will be enabled (false) or disabled (true).\n * @returns {void}.\n */\n HScroll.prototype.disable = function (value) {\n var navEles = selectAll('.e-scroll-nav:not(.' + CLS_DISABLE + ')', this.element);\n if (value) {\n this.element.classList.add(CLS_DISABLE);\n }\n else {\n this.element.classList.remove(CLS_DISABLE);\n }\n [].slice.call(navEles).forEach(function (el) {\n el.setAttribute('tabindex', !value ? '0' : '-1');\n });\n };\n HScroll.prototype.createOverlay = function (element) {\n var id = element.id.concat('_nav');\n var rightOverlayEle = this.createElement('div', { className: CLS_OVERLAY + ' ' + CLS_RIGHTOVERLAY });\n var clsRight = 'e-' + element.id.concat('_nav ' + CLS_HSCROLLNAV + ' ' + CLS_HSCROLLNAVRIGHT);\n var rightEle = this.createElement('div', { id: id.concat('_right'), className: clsRight });\n var navItem = this.createElement('div', { className: CLS_NAVRIGHTARROW + ' ' + CLS_NAVARROW + ' e-icons' });\n rightEle.appendChild(navItem);\n var leftEle = this.createElement('div', { className: CLS_OVERLAY + ' ' + CLS_LEFTOVERLAY });\n if (this.ieCheck) {\n rightEle.classList.add('e-ie-align');\n }\n element.appendChild(rightOverlayEle);\n element.appendChild(rightEle);\n element.insertBefore(leftEle, element.firstChild);\n this.eventBinding([rightEle]);\n };\n HScroll.prototype.createNavIcon = function (element) {\n var id = element.id.concat('_nav');\n var clsRight = 'e-' + element.id.concat('_nav ' + CLS_HSCROLLNAV + ' ' + CLS_HSCROLLNAVRIGHT);\n var rightAttributes = { 'role': 'button', 'id': id.concat('_right'), 'aria-label': 'Scroll right' };\n var nav = this.createElement('div', { className: clsRight, attrs: rightAttributes });\n nav.setAttribute('aria-disabled', 'false');\n var navItem = this.createElement('div', { className: CLS_NAVRIGHTARROW + ' ' + CLS_NAVARROW + ' e-icons' });\n var clsLeft = 'e-' + element.id.concat('_nav ' + CLS_HSCROLLNAV + ' ' + CLS_HSCROLLNAVLEFT);\n var leftAttributes = { 'role': 'button', 'id': id.concat('_left'), 'aria-label': 'Scroll left' };\n var navEle = this.createElement('div', { className: clsLeft + ' ' + CLS_DISABLE, attrs: leftAttributes });\n navEle.setAttribute('aria-disabled', 'true');\n var navLeftItem = this.createElement('div', { className: CLS_NAVLEFTARROW + ' ' + CLS_NAVARROW + ' e-icons' });\n navEle.appendChild(navLeftItem);\n nav.appendChild(navItem);\n element.appendChild(nav);\n element.insertBefore(navEle, element.firstChild);\n if (this.ieCheck) {\n nav.classList.add('e-ie-align');\n navEle.classList.add('e-ie-align');\n }\n this.eventBinding([nav, navEle]);\n };\n HScroll.prototype.onKeyPress = function (e) {\n var _this = this;\n if (e.key === 'Enter') {\n var timeoutFun_1 = function () {\n _this.keyTimeout = true;\n _this.eleScrolling(10, e.target, true);\n };\n this.keyTimer = window.setTimeout(function () {\n timeoutFun_1();\n }, 100);\n }\n };\n HScroll.prototype.onKeyUp = function (e) {\n if (e.key !== 'Enter') {\n return;\n }\n if (this.keyTimeout) {\n this.keyTimeout = false;\n }\n else {\n e.target.click();\n }\n clearTimeout(this.keyTimer);\n };\n HScroll.prototype.eventBinding = function (ele) {\n var _this = this;\n [].slice.call(ele).forEach(function (el) {\n new Touch(el, { tapHold: _this.tabHoldHandler.bind(_this), tapHoldThreshold: 500 });\n el.addEventListener('keydown', _this.onKeyPress.bind(_this));\n el.addEventListener('keyup', _this.onKeyUp.bind(_this));\n el.addEventListener('mouseup', _this.repeatScroll.bind(_this));\n el.addEventListener('touchend', _this.repeatScroll.bind(_this));\n el.addEventListener('contextmenu', function (e) {\n e.preventDefault();\n });\n EventHandler.add(el, 'click', _this.clickEventHandler, _this);\n });\n };\n HScroll.prototype.repeatScroll = function () {\n clearInterval(this.timeout);\n };\n HScroll.prototype.tabHoldHandler = function (e) {\n var _this = this;\n var trgt = e.originalEvent.target;\n trgt = this.contains(trgt, CLS_HSCROLLNAV) ? trgt.firstElementChild : trgt;\n var scrollDis = 10;\n var timeoutFun = function () {\n _this.eleScrolling(scrollDis, trgt, true);\n };\n this.timeout = window.setInterval(function () {\n timeoutFun();\n }, 50);\n };\n HScroll.prototype.contains = function (ele, className) {\n return ele.classList.contains(className);\n };\n HScroll.prototype.eleScrolling = function (scrollDis, trgt, isContinuous) {\n var rootEle = this.element;\n var classList = trgt.classList;\n if (classList.contains(CLS_HSCROLLNAV)) {\n classList = trgt.querySelector('.' + CLS_NAVARROW).classList;\n }\n if (this.contains(rootEle, CLS_RTL) && this.browserCheck) {\n scrollDis = -scrollDis;\n }\n if ((!this.contains(rootEle, CLS_RTL) || this.browserCheck) || this.ieCheck) {\n if (classList.contains(CLS_NAVRIGHTARROW)) {\n this.frameScrollRequest(scrollDis, 'add', isContinuous);\n }\n else {\n this.frameScrollRequest(scrollDis, '', isContinuous);\n }\n }\n else {\n if (classList.contains(CLS_NAVLEFTARROW)) {\n this.frameScrollRequest(scrollDis, 'add', isContinuous);\n }\n else {\n this.frameScrollRequest(scrollDis, '', isContinuous);\n }\n }\n };\n HScroll.prototype.clickEventHandler = function (e) {\n this.eleScrolling(this.scrollStep, e.target, false);\n };\n HScroll.prototype.swipeHandler = function (e) {\n var swipeEle = this.scrollEle;\n var distance;\n if (e.velocity <= 1) {\n distance = e.distanceX / (e.velocity * 10);\n }\n else {\n distance = e.distanceX / e.velocity;\n }\n var start = 0.5;\n var animate = function () {\n var step = Math.sin(start);\n if (step <= 0) {\n window.cancelAnimationFrame(step);\n }\n else {\n if (e.swipeDirection === 'Left') {\n swipeEle.scrollLeft += distance * step;\n }\n else if (e.swipeDirection === 'Right') {\n swipeEle.scrollLeft -= distance * step;\n }\n start -= 0.5;\n window.requestAnimationFrame(animate);\n }\n };\n animate();\n };\n HScroll.prototype.scrollUpdating = function (scrollVal, action) {\n if (action === 'add') {\n this.scrollEle.scrollLeft += scrollVal;\n }\n else {\n this.scrollEle.scrollLeft -= scrollVal;\n }\n if (this.enableRtl && this.scrollEle.scrollLeft > 0) {\n this.scrollEle.scrollLeft = 0;\n }\n };\n HScroll.prototype.frameScrollRequest = function (scrollVal, action, isContinuous) {\n var _this = this;\n var step = 10;\n if (isContinuous) {\n this.scrollUpdating(scrollVal, action);\n return;\n }\n if (!this.customStep) {\n [].slice.call(selectAll('.' + CLS_OVERLAY, this.element)).forEach(function (el) {\n scrollVal -= el.offsetWidth;\n });\n }\n var animate = function () {\n var scrollValue;\n var scrollStep;\n if (_this.contains(_this.element, CLS_RTL) && _this.browserCheck) {\n scrollValue = -scrollVal;\n scrollStep = -step;\n }\n else {\n scrollValue = scrollVal;\n scrollStep = step;\n }\n if (scrollValue < step) {\n window.cancelAnimationFrame(scrollStep);\n }\n else {\n _this.scrollUpdating(scrollStep, action);\n scrollVal -= scrollStep;\n window.requestAnimationFrame(animate);\n }\n };\n animate();\n };\n HScroll.prototype.touchHandler = function (e) {\n var ele = this.scrollEle;\n var distance = e.distanceX;\n if ((this.ieCheck) && this.contains(this.element, CLS_RTL)) {\n distance = -distance;\n }\n if (e.scrollDirection === 'Left') {\n ele.scrollLeft = ele.scrollLeft + distance;\n }\n else if (e.scrollDirection === 'Right') {\n ele.scrollLeft = ele.scrollLeft - distance;\n }\n };\n HScroll.prototype.arrowDisabling = function (addDisable, removeDisable) {\n if (this.isDevice) {\n var arrowEle = isNullOrUndefined(addDisable) ? removeDisable : addDisable;\n var arrowIcon = arrowEle.querySelector('.' + CLS_NAVARROW);\n if (isNullOrUndefined(addDisable)) {\n classList(arrowIcon, [CLS_NAVRIGHTARROW], [CLS_NAVLEFTARROW]);\n }\n else {\n classList(arrowIcon, [CLS_NAVLEFTARROW], [CLS_NAVRIGHTARROW]);\n }\n }\n else if (addDisable && removeDisable) {\n addDisable.classList.add(CLS_DISABLE);\n addDisable.setAttribute('aria-disabled', 'true');\n addDisable.removeAttribute('tabindex');\n removeDisable.classList.remove(CLS_DISABLE);\n removeDisable.setAttribute('aria-disabled', 'false');\n removeDisable.setAttribute('tabindex', '0');\n }\n this.repeatScroll();\n };\n HScroll.prototype.scrollHandler = function (e) {\n var target = e.target;\n var width = target.offsetWidth;\n var rootEle = this.element;\n var navLeftEle = this.element.querySelector('.' + CLS_HSCROLLNAVLEFT);\n var navRightEle = this.element.querySelector('.' + CLS_HSCROLLNAVRIGHT);\n var leftOverlay = this.element.querySelector('.' + CLS_LEFTOVERLAY);\n var rightOverlay = this.element.querySelector('.' + CLS_RIGHTOVERLAY);\n var scrollLeft = target.scrollLeft;\n if (scrollLeft <= 0) {\n scrollLeft = -scrollLeft;\n }\n if (this.isDevice) {\n if (this.enableRtl && !(this.browserCheck || this.ieCheck)) {\n leftOverlay = this.element.querySelector('.' + CLS_RIGHTOVERLAY);\n rightOverlay = this.element.querySelector('.' + CLS_LEFTOVERLAY);\n }\n if (scrollLeft < OVERLAY_MAXWID) {\n leftOverlay.style.width = scrollLeft + 'px';\n }\n else {\n leftOverlay.style.width = '40px';\n }\n if ((target.scrollWidth - Math.ceil(width + scrollLeft)) < OVERLAY_MAXWID) {\n rightOverlay.style.width = (target.scrollWidth - Math.ceil(width + scrollLeft)) + 'px';\n }\n else {\n rightOverlay.style.width = '40px';\n }\n }\n if (scrollLeft === 0) {\n this.arrowDisabling(navLeftEle, navRightEle);\n }\n else if (Math.ceil(width + scrollLeft + .1) >= target.scrollWidth) {\n this.arrowDisabling(navRightEle, navLeftEle);\n }\n else {\n var disEle = this.element.querySelector('.' + CLS_HSCROLLNAV + '.' + CLS_DISABLE);\n if (disEle) {\n disEle.classList.remove(CLS_DISABLE);\n disEle.setAttribute('aria-disabled', 'false');\n disEle.setAttribute('tabindex', '0');\n }\n }\n };\n /**\n * Gets called when the model property changes.The data that describes the old and new values of property that changed.\n *\n * @param {HScrollModel} newProp - It contains the new value of data.\n * @param {HScrollModel} oldProp - It contains the old value of data.\n * @returns {void}\n * @private\n */\n HScroll.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'scrollStep':\n this.setScrollState();\n break;\n case 'enableRtl':\n newProp.enableRtl ? this.element.classList.add(CLS_RTL) : this.element.classList.remove(CLS_RTL);\n break;\n }\n }\n };\n __decorate([\n Property(null)\n ], HScroll.prototype, \"scrollStep\", void 0);\n HScroll = __decorate([\n NotifyPropertyChanges\n ], HScroll);\n return HScroll;\n}(Component));\nexport { HScroll };\n","var map = {\n\t\"./af\": \"2bfb\",\n\t\"./af.js\": \"2bfb\",\n\t\"./ar\": \"8e73\",\n\t\"./ar-dz\": \"a356\",\n\t\"./ar-dz.js\": \"a356\",\n\t\"./ar-kw\": \"423e\",\n\t\"./ar-kw.js\": \"423e\",\n\t\"./ar-ly\": \"1cfd\",\n\t\"./ar-ly.js\": \"1cfd\",\n\t\"./ar-ma\": \"0a84\",\n\t\"./ar-ma.js\": \"0a84\",\n\t\"./ar-sa\": \"8230\",\n\t\"./ar-sa.js\": \"8230\",\n\t\"./ar-tn\": \"6d83\",\n\t\"./ar-tn.js\": \"6d83\",\n\t\"./ar.js\": \"8e73\",\n\t\"./az\": \"485c\",\n\t\"./az.js\": \"485c\",\n\t\"./be\": \"1fc1\",\n\t\"./be.js\": \"1fc1\",\n\t\"./bg\": \"84aa\",\n\t\"./bg.js\": \"84aa\",\n\t\"./bm\": \"a7fa\",\n\t\"./bm.js\": \"a7fa\",\n\t\"./bn\": \"9043\",\n\t\"./bn-bd\": \"9686\",\n\t\"./bn-bd.js\": \"9686\",\n\t\"./bn.js\": \"9043\",\n\t\"./bo\": \"d26a\",\n\t\"./bo.js\": \"d26a\",\n\t\"./br\": \"6887\",\n\t\"./br.js\": \"6887\",\n\t\"./bs\": \"2554\",\n\t\"./bs.js\": \"2554\",\n\t\"./ca\": \"d716\",\n\t\"./ca.js\": \"d716\",\n\t\"./cs\": \"3c0d\",\n\t\"./cs.js\": \"3c0d\",\n\t\"./cv\": \"03ec\",\n\t\"./cv.js\": \"03ec\",\n\t\"./cy\": \"9797\",\n\t\"./cy.js\": \"9797\",\n\t\"./da\": \"0f14\",\n\t\"./da.js\": \"0f14\",\n\t\"./de\": \"b469\",\n\t\"./de-at\": \"b3eb\",\n\t\"./de-at.js\": \"b3eb\",\n\t\"./de-ch\": \"bb71\",\n\t\"./de-ch.js\": \"bb71\",\n\t\"./de.js\": \"b469\",\n\t\"./dv\": \"598a\",\n\t\"./dv.js\": \"598a\",\n\t\"./el\": \"8d47\",\n\t\"./el.js\": \"8d47\",\n\t\"./en-au\": \"0e6b\",\n\t\"./en-au.js\": \"0e6b\",\n\t\"./en-ca\": \"3886\",\n\t\"./en-ca.js\": \"3886\",\n\t\"./en-gb\": \"39a6\",\n\t\"./en-gb.js\": \"39a6\",\n\t\"./en-ie\": \"e1d3\",\n\t\"./en-ie.js\": \"e1d3\",\n\t\"./en-il\": \"7333\",\n\t\"./en-il.js\": \"7333\",\n\t\"./en-in\": \"ec2e\",\n\t\"./en-in.js\": \"ec2e\",\n\t\"./en-nz\": \"6f50\",\n\t\"./en-nz.js\": \"6f50\",\n\t\"./en-sg\": \"b7e9\",\n\t\"./en-sg.js\": \"b7e9\",\n\t\"./eo\": \"65db\",\n\t\"./eo.js\": \"65db\",\n\t\"./es\": \"898b\",\n\t\"./es-do\": \"0a3c\",\n\t\"./es-do.js\": \"0a3c\",\n\t\"./es-mx\": \"b5b7\",\n\t\"./es-mx.js\": \"b5b7\",\n\t\"./es-us\": \"55c9\",\n\t\"./es-us.js\": \"55c9\",\n\t\"./es.js\": \"898b\",\n\t\"./et\": \"ec18\",\n\t\"./et.js\": \"ec18\",\n\t\"./eu\": \"0ff2\",\n\t\"./eu.js\": \"0ff2\",\n\t\"./fa\": \"8df4\",\n\t\"./fa.js\": \"8df4\",\n\t\"./fi\": \"81e9\",\n\t\"./fi.js\": \"81e9\",\n\t\"./fil\": \"d69a\",\n\t\"./fil.js\": \"d69a\",\n\t\"./fo\": \"0721\",\n\t\"./fo.js\": \"0721\",\n\t\"./fr\": \"9f26\",\n\t\"./fr-ca\": \"d9f8\",\n\t\"./fr-ca.js\": \"d9f8\",\n\t\"./fr-ch\": \"0e49\",\n\t\"./fr-ch.js\": \"0e49\",\n\t\"./fr.js\": \"9f26\",\n\t\"./fy\": \"7118\",\n\t\"./fy.js\": \"7118\",\n\t\"./ga\": \"5120\",\n\t\"./ga.js\": \"5120\",\n\t\"./gd\": \"f6b4\",\n\t\"./gd.js\": \"f6b4\",\n\t\"./gl\": \"8840\",\n\t\"./gl.js\": \"8840\",\n\t\"./gom-deva\": \"aaf2\",\n\t\"./gom-deva.js\": \"aaf2\",\n\t\"./gom-latn\": \"0caa\",\n\t\"./gom-latn.js\": \"0caa\",\n\t\"./gu\": \"e0c5\",\n\t\"./gu.js\": \"e0c5\",\n\t\"./he\": \"c7aa\",\n\t\"./he.js\": \"c7aa\",\n\t\"./hi\": \"dc4d\",\n\t\"./hi.js\": \"dc4d\",\n\t\"./hr\": \"4ba9\",\n\t\"./hr.js\": \"4ba9\",\n\t\"./hu\": \"5b14\",\n\t\"./hu.js\": \"5b14\",\n\t\"./hy-am\": \"d6b6\",\n\t\"./hy-am.js\": \"d6b6\",\n\t\"./id\": \"5038\",\n\t\"./id.js\": \"5038\",\n\t\"./is\": \"0558\",\n\t\"./is.js\": \"0558\",\n\t\"./it\": \"6e98\",\n\t\"./it-ch\": \"6f12\",\n\t\"./it-ch.js\": \"6f12\",\n\t\"./it.js\": \"6e98\",\n\t\"./ja\": \"079e\",\n\t\"./ja.js\": \"079e\",\n\t\"./jv\": \"b540\",\n\t\"./jv.js\": \"b540\",\n\t\"./ka\": \"201b\",\n\t\"./ka.js\": \"201b\",\n\t\"./kk\": \"6d79\",\n\t\"./kk.js\": \"6d79\",\n\t\"./km\": \"e81d\",\n\t\"./km.js\": \"e81d\",\n\t\"./kn\": \"3e92\",\n\t\"./kn.js\": \"3e92\",\n\t\"./ko\": \"22f8\",\n\t\"./ko.js\": \"22f8\",\n\t\"./ku\": \"2421\",\n\t\"./ku.js\": \"2421\",\n\t\"./ky\": \"9609\",\n\t\"./ky.js\": \"9609\",\n\t\"./lb\": \"440c\",\n\t\"./lb.js\": \"440c\",\n\t\"./lo\": \"b29d\",\n\t\"./lo.js\": \"b29d\",\n\t\"./lt\": \"26f9\",\n\t\"./lt.js\": \"26f9\",\n\t\"./lv\": \"b97c\",\n\t\"./lv.js\": \"b97c\",\n\t\"./me\": \"293c\",\n\t\"./me.js\": \"293c\",\n\t\"./mi\": \"688b\",\n\t\"./mi.js\": \"688b\",\n\t\"./mk\": \"6909\",\n\t\"./mk.js\": \"6909\",\n\t\"./ml\": \"02fb\",\n\t\"./ml.js\": \"02fb\",\n\t\"./mn\": \"958b\",\n\t\"./mn.js\": \"958b\",\n\t\"./mr\": \"39bd\",\n\t\"./mr.js\": \"39bd\",\n\t\"./ms\": \"ebe4\",\n\t\"./ms-my\": \"6403\",\n\t\"./ms-my.js\": \"6403\",\n\t\"./ms.js\": \"ebe4\",\n\t\"./mt\": \"1b45\",\n\t\"./mt.js\": \"1b45\",\n\t\"./my\": \"8689\",\n\t\"./my.js\": \"8689\",\n\t\"./nb\": \"6ce3\",\n\t\"./nb.js\": \"6ce3\",\n\t\"./ne\": \"3a39\",\n\t\"./ne.js\": \"3a39\",\n\t\"./nl\": \"facd\",\n\t\"./nl-be\": \"db29\",\n\t\"./nl-be.js\": \"db29\",\n\t\"./nl.js\": \"facd\",\n\t\"./nn\": \"b84c\",\n\t\"./nn.js\": \"b84c\",\n\t\"./oc-lnc\": \"167b\",\n\t\"./oc-lnc.js\": \"167b\",\n\t\"./pa-in\": \"f3ff\",\n\t\"./pa-in.js\": \"f3ff\",\n\t\"./pl\": \"8d57\",\n\t\"./pl.js\": \"8d57\",\n\t\"./pt\": \"f260\",\n\t\"./pt-br\": \"d2d4\",\n\t\"./pt-br.js\": \"d2d4\",\n\t\"./pt.js\": \"f260\",\n\t\"./ro\": \"972c\",\n\t\"./ro.js\": \"972c\",\n\t\"./ru\": \"957c\",\n\t\"./ru.js\": \"957c\",\n\t\"./sd\": \"6784\",\n\t\"./sd.js\": \"6784\",\n\t\"./se\": \"ffff\",\n\t\"./se.js\": \"ffff\",\n\t\"./si\": \"eda5\",\n\t\"./si.js\": \"eda5\",\n\t\"./sk\": \"7be6\",\n\t\"./sk.js\": \"7be6\",\n\t\"./sl\": \"8155\",\n\t\"./sl.js\": \"8155\",\n\t\"./sq\": \"c8f3\",\n\t\"./sq.js\": \"c8f3\",\n\t\"./sr\": \"cf1e\",\n\t\"./sr-cyrl\": \"13e9\",\n\t\"./sr-cyrl.js\": \"13e9\",\n\t\"./sr.js\": \"cf1e\",\n\t\"./ss\": \"52bd\",\n\t\"./ss.js\": \"52bd\",\n\t\"./sv\": \"5fbd\",\n\t\"./sv.js\": \"5fbd\",\n\t\"./sw\": \"74dc\",\n\t\"./sw.js\": \"74dc\",\n\t\"./ta\": \"3de5\",\n\t\"./ta.js\": \"3de5\",\n\t\"./te\": \"5cbb\",\n\t\"./te.js\": \"5cbb\",\n\t\"./tet\": \"576c\",\n\t\"./tet.js\": \"576c\",\n\t\"./tg\": \"3b1b\",\n\t\"./tg.js\": \"3b1b\",\n\t\"./th\": \"10e8\",\n\t\"./th.js\": \"10e8\",\n\t\"./tk\": \"5aff\",\n\t\"./tk.js\": \"5aff\",\n\t\"./tl-ph\": \"0f38\",\n\t\"./tl-ph.js\": \"0f38\",\n\t\"./tlh\": \"cf75\",\n\t\"./tlh.js\": \"cf75\",\n\t\"./tr\": \"0e81\",\n\t\"./tr.js\": \"0e81\",\n\t\"./tzl\": \"cf51\",\n\t\"./tzl.js\": \"cf51\",\n\t\"./tzm\": \"c109\",\n\t\"./tzm-latn\": \"b53d\",\n\t\"./tzm-latn.js\": \"b53d\",\n\t\"./tzm.js\": \"c109\",\n\t\"./ug-cn\": \"6117\",\n\t\"./ug-cn.js\": \"6117\",\n\t\"./uk\": \"ada2\",\n\t\"./uk.js\": \"ada2\",\n\t\"./ur\": \"5294\",\n\t\"./ur.js\": \"5294\",\n\t\"./uz\": \"2e8c\",\n\t\"./uz-latn\": \"010e\",\n\t\"./uz-latn.js\": \"010e\",\n\t\"./uz.js\": \"2e8c\",\n\t\"./vi\": \"2921\",\n\t\"./vi.js\": \"2921\",\n\t\"./x-pseudo\": \"fd7e\",\n\t\"./x-pseudo.js\": \"fd7e\",\n\t\"./yo\": \"7f33\",\n\t\"./yo.js\": \"7f33\",\n\t\"./zh-cn\": \"5c3a\",\n\t\"./zh-cn.js\": \"5c3a\",\n\t\"./zh-hk\": \"49ab\",\n\t\"./zh-hk.js\": \"49ab\",\n\t\"./zh-mo\": \"3a6c\",\n\t\"./zh-mo.js\": \"3a6c\",\n\t\"./zh-tw\": \"90ea\",\n\t\"./zh-tw.js\": \"90ea\"\n};\n\n\nfunction webpackContext(req) {\n\tvar id = webpackContextResolve(req);\n\treturn __webpack_require__(id);\n}\nfunction webpackContextResolve(req) {\n\tif(!__webpack_require__.o(map, req)) {\n\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\te.code = 'MODULE_NOT_FOUND';\n\t\tthrow e;\n\t}\n\treturn map[req];\n}\nwebpackContext.keys = function webpackContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackContext.resolve = webpackContextResolve;\nmodule.exports = webpackContext;\nwebpackContext.id = \"4678\";","//! moment.js locale configuration\n//! locale : Azerbaijani [az]\n//! author : topchiyev : https://github.com/topchiyev\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var suffixes = {\n 1: '-inci',\n 5: '-inci',\n 8: '-inci',\n 70: '-inci',\n 80: '-inci',\n 2: '-nci',\n 7: '-nci',\n 20: '-nci',\n 50: '-nci',\n 3: '-üncü',\n 4: '-üncü',\n 100: '-üncü',\n 6: '-ncı',\n 9: '-uncu',\n 10: '-uncu',\n 30: '-uncu',\n 60: '-ıncı',\n 90: '-ıncı',\n };\n\n var az = moment.defineLocale('az', {\n months: 'yanvar_fevral_mart_aprel_may_iyun_iyul_avqust_sentyabr_oktyabr_noyabr_dekabr'.split(\n '_'\n ),\n monthsShort: 'yan_fev_mar_apr_may_iyn_iyl_avq_sen_okt_noy_dek'.split('_'),\n weekdays:\n 'Bazar_Bazar ertÉ™si_ÇərÅŸÉ™nbÉ™ axÅŸamı_ÇərÅŸÉ™nbÉ™_CümÉ™ axÅŸamı_CümÉ™_ŞənbÉ™'.split(\n '_'\n ),\n weekdaysShort: 'Baz_BzE_ÇAx_Çər_CAx_Cüm_Şən'.split('_'),\n weekdaysMin: 'Bz_BE_ÇA_Çə_CA_Cü_Şə'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[bugün saat] LT',\n nextDay: '[sabah saat] LT',\n nextWeek: '[gÉ™lÉ™n hÉ™ftÉ™] dddd [saat] LT',\n lastDay: '[dünÉ™n] LT',\n lastWeek: '[keçən hÉ™ftÉ™] dddd [saat] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s sonra',\n past: '%s É™vvÉ™l',\n s: 'bir neçə saniyÉ™',\n ss: '%d saniyÉ™',\n m: 'bir dÉ™qiqÉ™',\n mm: '%d dÉ™qiqÉ™',\n h: 'bir saat',\n hh: '%d saat',\n d: 'bir gün',\n dd: '%d gün',\n M: 'bir ay',\n MM: '%d ay',\n y: 'bir il',\n yy: '%d il',\n },\n meridiemParse: /gecÉ™|sÉ™hÉ™r|gündüz|axÅŸam/,\n isPM: function (input) {\n return /^(gündüz|axÅŸam)$/.test(input);\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'gecÉ™';\n } else if (hour < 12) {\n return 'sÉ™hÉ™r';\n } else if (hour < 17) {\n return 'gündüz';\n } else {\n return 'axÅŸam';\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(ıncı|inci|nci|üncü|ncı|uncu)/,\n ordinal: function (number) {\n if (number === 0) {\n // special case for zero\n return number + '-ıncı';\n }\n var a = number % 10,\n b = (number % 100) - a,\n c = number >= 100 ? 100 : null;\n return number + (suffixes[a] || suffixes[b] || suffixes[c]);\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return az;\n\n})));\n","//! moment.js locale configuration\n//! locale : Chinese (Hong Kong) [zh-hk]\n//! author : Ben : https://github.com/ben-lin\n//! author : Chris Lam : https://github.com/hehachris\n//! author : Konstantin : https://github.com/skfd\n//! author : Anthony : https://github.com/anthonylau\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var zhHk = moment.defineLocale('zh-hk', {\n months: '一月_二月_三月_四月_五月_å…月_七月_八月_ä¹æœˆ_å月_å一月_å二月'.split(\n '_'\n ),\n monthsShort: '1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月'.split(\n '_'\n ),\n weekdays: '星期日_星期一_星期二_星期三_星期四_星期五_星期å…'.split('_'),\n weekdaysShort: '週日_週一_週二_週三_週四_週五_週å…'.split('_'),\n weekdaysMin: 'æ—¥_一_二_三_å››_五_å…'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY/MM/DD',\n LL: 'YYYYå¹´M月Dæ—¥',\n LLL: 'YYYYå¹´M月Dæ—¥ HH:mm',\n LLLL: 'YYYYå¹´M月Dæ—¥dddd HH:mm',\n l: 'YYYY/M/D',\n ll: 'YYYYå¹´M月Dæ—¥',\n lll: 'YYYYå¹´M月Dæ—¥ HH:mm',\n llll: 'YYYYå¹´M月Dæ—¥dddd HH:mm',\n },\n meridiemParse: /凌晨|早上|上åˆ|ä¸åˆ|下åˆ|晚上/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === '凌晨' || meridiem === '早上' || meridiem === '上åˆ') {\n return hour;\n } else if (meridiem === 'ä¸åˆ') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === '下åˆ' || meridiem === '晚上') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n var hm = hour * 100 + minute;\n if (hm < 600) {\n return '凌晨';\n } else if (hm < 900) {\n return '早上';\n } else if (hm < 1200) {\n return '上åˆ';\n } else if (hm === 1200) {\n return 'ä¸åˆ';\n } else if (hm < 1800) {\n return '下åˆ';\n } else {\n return '晚上';\n }\n },\n calendar: {\n sameDay: '[今天]LT',\n nextDay: '[明天]LT',\n nextWeek: '[下]ddddLT',\n lastDay: '[昨天]LT',\n lastWeek: '[上]ddddLT',\n sameElse: 'L',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(æ—¥|月|週)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'DDD':\n return number + 'æ—¥';\n case 'M':\n return number + '月';\n case 'w':\n case 'W':\n return number + '週';\n default:\n return number;\n }\n },\n relativeTime: {\n future: '%s後',\n past: '%så‰',\n s: '幾秒',\n ss: '%d 秒',\n m: '1 分é˜',\n mm: '%d 分é˜',\n h: '1 å°æ™‚',\n hh: '%d å°æ™‚',\n d: '1 天',\n dd: '%d 天',\n M: '1 個月',\n MM: '%d 個月',\n y: '1 å¹´',\n yy: '%d å¹´',\n },\n });\n\n return zhHk;\n\n})));\n","//! moment.js locale configuration\n//! locale : Croatian [hr]\n//! author : Bojan Marković : https://github.com/bmarkovic\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function translate(number, withoutSuffix, key) {\n var result = number + ' ';\n switch (key) {\n case 'ss':\n if (number === 1) {\n result += 'sekunda';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'sekunde';\n } else {\n result += 'sekundi';\n }\n return result;\n case 'm':\n return withoutSuffix ? 'jedna minuta' : 'jedne minute';\n case 'mm':\n if (number === 1) {\n result += 'minuta';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'minute';\n } else {\n result += 'minuta';\n }\n return result;\n case 'h':\n return withoutSuffix ? 'jedan sat' : 'jednog sata';\n case 'hh':\n if (number === 1) {\n result += 'sat';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'sata';\n } else {\n result += 'sati';\n }\n return result;\n case 'dd':\n if (number === 1) {\n result += 'dan';\n } else {\n result += 'dana';\n }\n return result;\n case 'MM':\n if (number === 1) {\n result += 'mjesec';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'mjeseca';\n } else {\n result += 'mjeseci';\n }\n return result;\n case 'yy':\n if (number === 1) {\n result += 'godina';\n } else if (number === 2 || number === 3 || number === 4) {\n result += 'godine';\n } else {\n result += 'godina';\n }\n return result;\n }\n }\n\n var hr = moment.defineLocale('hr', {\n months: {\n format: 'sijeÄnja_veljaÄe_ožujka_travnja_svibnja_lipnja_srpnja_kolovoza_rujna_listopada_studenoga_prosinca'.split(\n '_'\n ),\n standalone:\n 'sijeÄanj_veljaÄa_ožujak_travanj_svibanj_lipanj_srpanj_kolovoz_rujan_listopad_studeni_prosinac'.split(\n '_'\n ),\n },\n monthsShort:\n 'sij._velj._ožu._tra._svi._lip._srp._kol._ruj._lis._stu._pro.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'nedjelja_ponedjeljak_utorak_srijeda_Äetvrtak_petak_subota'.split(\n '_'\n ),\n weekdaysShort: 'ned._pon._uto._sri._Äet._pet._sub.'.split('_'),\n weekdaysMin: 'ne_po_ut_sr_Äe_pe_su'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'Do MMMM YYYY',\n LLL: 'Do MMMM YYYY H:mm',\n LLLL: 'dddd, Do MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[danas u] LT',\n nextDay: '[sutra u] LT',\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[u] [nedjelju] [u] LT';\n case 3:\n return '[u] [srijedu] [u] LT';\n case 6:\n return '[u] [subotu] [u] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[u] dddd [u] LT';\n }\n },\n lastDay: '[juÄer u] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n return '[proÅ¡lu] [nedjelju] [u] LT';\n case 3:\n return '[proÅ¡lu] [srijedu] [u] LT';\n case 6:\n return '[proÅ¡le] [subote] [u] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[proÅ¡li] dddd [u] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'za %s',\n past: 'prije %s',\n s: 'par sekundi',\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: 'dan',\n dd: translate,\n M: 'mjesec',\n MM: translate,\n y: 'godinu',\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return hr;\n\n})));\n","import { extend, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { closest as closestElement, removeClass, classList, remove } from '@syncfusion/ej2-base';\nimport { getElementIndex, inArray, parentsUntil, getPosition, isActionPrevent } from '../base/util';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\n/**\n *\n * The `Reorder` module is used for reordering columns.\n */\nvar Reorder = /** @class */ (function () {\n /**\n * Constructor for the Grid reorder module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @hidden\n */\n function Reorder(parent) {\n this.idx = 0;\n this.parent = parent;\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.headerDrop, this.headerDrop, this);\n this.parent.on(events.uiUpdate, this.enableAfterRender, this);\n this.parent.on(events.reorderComplete, this.onActionComplete, this);\n this.parent.on(events.columnDrag, this.drag, this);\n this.parent.on(events.columnDragStart, this.dragStart, this);\n this.parent.on(events.columnDragStop, this.dragStop, this);\n this.parent.on(events.headerDrop, this.headerDrop, this);\n this.parent.on(events.headerRefreshed, this.createReorderElement, this);\n this.parent.on(events.keyPressed, this.keyPressHandler, this);\n this.parent.on(events.destroy, this.destroy, this);\n }\n Reorder.prototype.chkDropPosition = function (srcElem, destElem) {\n var col = this.parent.getColumnByUid(destElem.firstElementChild.getAttribute('e-mappinguid'));\n var bool = col ? !col.lockColumn : true;\n return ((srcElem.parentElement.isEqualNode(destElem.parentElement) || this.parent.enableColumnVirtualization)\n || (this.parent.isFrozenGrid()\n && Array.prototype.indexOf.call(closestElement(srcElem, 'thead').children, srcElem.parentElement)\n === Array.prototype.indexOf.call(closestElement(destElem, 'thead').children, destElem.parentElement)))\n && this.targetParentContainerIndex(srcElem, destElem) > -1 && bool;\n };\n Reorder.prototype.chkDropAllCols = function (srcElem, destElem) {\n var isFound;\n var headers = this.getHeaderCells();\n var header;\n while (!isFound && headers.length > 0) {\n header = headers.pop();\n isFound = srcElem !== header && this.targetParentContainerIndex(srcElem, destElem) > -1;\n }\n return isFound;\n };\n Reorder.prototype.findColParent = function (col, cols, parent) {\n // eslint-disable-next-line no-self-assign\n parent = parent;\n for (var i = 0, len = cols.length; i < len; i++) {\n if (col === cols[parseInt(i.toString(), 10)]) {\n return true;\n }\n else if (cols[parseInt(i.toString(), 10)].columns) {\n var cnt = parent.length;\n parent.push(cols[parseInt(i.toString(), 10)]);\n if (!this.findColParent(col, cols[parseInt(i.toString(), 10)].columns, parent)) {\n parent.splice(cnt, parent.length - cnt);\n }\n else {\n return true;\n }\n }\n }\n return false;\n };\n Reorder.prototype.getColumnsModel = function (cols, isNotStackedHeader) {\n var columnModel = [];\n var subCols = [];\n for (var i = 0, len = cols.length; i < len; i++) {\n if (!isNullOrUndefined(cols[parseInt(i.toString(), 10)])) {\n if (cols[parseInt(i.toString(), 10)].visible) {\n columnModel.push(cols[parseInt(i.toString(), 10)]);\n }\n else if (isNotStackedHeader) {\n columnModel.push(cols[parseInt(i.toString(), 10)]);\n }\n if (cols[parseInt(i.toString(), 10)].columns) {\n subCols = subCols.concat(cols[parseInt(i.toString(), 10)].columns);\n }\n }\n }\n if (subCols.length) {\n columnModel = columnModel.concat(this.getColumnsModel(subCols));\n }\n return columnModel;\n };\n Reorder.prototype.headerDrop = function (e) {\n var gObj = this.parent;\n var dropElement = this.element.querySelector('.e-headercelldiv') || this.element.querySelector('.e-stackedheadercelldiv');\n var uId = dropElement.getAttribute('e-mappinguid');\n var column = gObj.getColumnByUid(uId);\n if (!closestElement(e.target, 'th') || (!isNullOrUndefined(column) && (!column.allowReordering || column.lockColumn))) {\n this.parent.log('action_disabled_column', { moduleName: this.getModuleName(), column: column });\n return;\n }\n var destElem = closestElement(e.target, '.e-headercell');\n var destElemDiv = destElem.querySelector('.e-headercelldiv') || destElem.querySelector('.e-stackedheadercelldiv');\n var destElemUid = destElemDiv.getAttribute('e-mappinguid');\n if (!isNullOrUndefined(destElemUid)) {\n var destColumn = gObj.getColumnByUid(destElemUid);\n if (isNullOrUndefined(destColumn) || !destColumn.allowReordering || destColumn.lockColumn) {\n this.parent.log('action_disabled_column', { moduleName: this.getModuleName(), column: column, destColumn: destColumn });\n return;\n }\n }\n if (destElem && !(!this.chkDropPosition(this.element, destElem) || !this.chkDropAllCols(this.element, destElem))) {\n if (this.parent.enableColumnVirtualization) {\n var columns = this.parent.columns;\n var sourceUid_1 = this.element.querySelector('.e-headercelldiv').getAttribute('e-mappinguid');\n var col = this.parent.columns.filter(function (col) { return col.uid === sourceUid_1; });\n var colMatchIndex_1 = null;\n var column_1 = col[0];\n var destUid_1 = destElem.querySelector('.e-headercelldiv').getAttribute('e-mappinguid');\n columns.some(function (col, index) {\n if (col.uid === destUid_1) {\n colMatchIndex_1 = index;\n return col.uid === destUid_1;\n }\n return false;\n });\n if (!isNullOrUndefined(colMatchIndex_1)) {\n this.moveColumns(colMatchIndex_1, column_1);\n }\n }\n else {\n var newIndex = this.targetParentContainerIndex(this.element, destElem);\n var uid = this.element.firstElementChild.getAttribute('e-mappinguid');\n this.destElement = destElem;\n this.parent.notify(events.setReorderDestinationElement, { ele: destElem });\n if (uid) {\n this.moveColumns(newIndex, this.parent.getColumnByUid(uid));\n }\n else {\n var headers = this.getHeaderCells();\n var oldIdx = getElementIndex(this.element, headers);\n var columns = this.getColumnsModel(this.parent.columns);\n this.moveColumns(newIndex, columns[parseInt(oldIdx.toString(), 10)]);\n }\n }\n }\n };\n Reorder.prototype.isActionPrevent = function (gObj) {\n return isActionPrevent(gObj);\n };\n Reorder.prototype.moveColumns = function (destIndex, column, reorderByColumn, preventRefresh) {\n var gObj = this.parent;\n if (this.isActionPrevent(gObj)) {\n gObj.notify(events.preventBatch, { instance: this, handler: this.moveColumns, arg1: destIndex, arg2: column });\n return;\n }\n var parent = this.getColParent(column, this.parent.columns);\n var cols = parent ? parent.columns : this.parent.columns;\n var srcIdx = inArray(column, cols);\n if ((parent || this.parent.lockcolPositionCount) && !reorderByColumn &&\n !this.parent.enableColumnVirtualization) {\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].field === column.field) {\n srcIdx = i;\n break;\n }\n }\n var col = this.parent.getColumnByUid(this.destElement.firstElementChild.getAttribute('e-mappinguid'));\n if (col) {\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].field === col.field) {\n destIndex = i;\n break;\n }\n }\n }\n else {\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].headerText === this.destElement.innerText.trim()) {\n destIndex = i;\n }\n }\n }\n }\n if (!gObj.allowReordering || srcIdx === destIndex || srcIdx === -1 || destIndex === -1) {\n return;\n }\n cols.splice(destIndex, 0, cols.splice(srcIdx, 1)[0]);\n var args = { column: column, destIndex: destIndex, columns: cols, parent: parent, cancel: false };\n gObj.notify(events.refreshFrozenColumns, args);\n if (args.cancel) {\n return;\n }\n if (this.parent.isFrozenGrid()) {\n if (this.parent.frozenColumns) {\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].freeze === 'Left') {\n cols[parseInt(i.toString(), 10)].freeze = undefined;\n }\n }\n }\n else {\n if (this.parent.getFrozenLeftCount() > destIndex) {\n column.freeze = 'Left';\n }\n else if ((cols.length - this.parent.getFrozenRightColumnsCount()) <= destIndex) {\n column.freeze = 'Right';\n }\n else {\n column.freeze = column.freeze === 'Fixed' ? 'Fixed' : undefined;\n }\n }\n }\n gObj.getColumns(true);\n gObj.notify(events.columnPositionChanged, { fromIndex: destIndex, toIndex: srcIdx });\n if (preventRefresh !== false) {\n gObj.notify(events.modelChanged, {\n type: events.actionBegin, requestType: 'reorder', fromIndex: destIndex, toIndex: srcIdx, toColumnUid: column.uid\n });\n }\n if (this.parent.isFrozenGrid()) {\n var cols_1 = this.parent.columns;\n this.idx = 0;\n this.refreshColumnIndex(cols_1);\n this.parent.notify(events.refreshFrozenPosition, {});\n }\n };\n Reorder.prototype.refreshColumnIndex = function (cols) {\n for (var i = 0; i < cols.length; i++) {\n cols[parseInt(i.toString(), 10)].index = this.idx;\n this.idx++;\n if (cols[parseInt(i.toString(), 10)].columns && cols[parseInt(i.toString(), 10)].columns.length) {\n this.refreshColumnIndex(cols[parseInt(i.toString(), 10)].columns);\n }\n }\n };\n Reorder.prototype.targetParentContainerIndex = function (srcElem, destElem) {\n var cols = this.parent.columns;\n var headers = this.getHeaderCells();\n var stackedHdrColumn = this.parent.getStackedColumns(cols);\n var stackedCols = [];\n if (stackedHdrColumn.length) {\n stackedCols = this.getAllStackedheaderParentColumns(headers);\n }\n var flatColumns = stackedHdrColumn.length && stackedCols.length ?\n this.getColumnsModel(stackedCols) : this.getColumnsModel(cols, true);\n var parent = this.getColParent(flatColumns[getElementIndex(srcElem, headers)], cols);\n cols = parent ? parent.columns : cols;\n return inArray(flatColumns[getElementIndex(destElem, headers)], cols);\n };\n Reorder.prototype.getAllStackedheaderParentColumns = function (headers) {\n var stackedCols = [];\n for (var i = 0; i < headers.length; i++) {\n if (headers[parseInt(i.toString(), 10)].classList.contains('e-hide')) {\n headers.splice(i, 1);\n i--;\n }\n else if (headers[parseInt(i.toString(), 10)].closest('thead').firstChild === headers[parseInt(i.toString(), 10)].parentElement) {\n stackedCols.push(this.parent.getColumnByUid(headers[parseInt(i.toString(), 10)].firstElementChild.getAttribute('e-mappinguid')));\n }\n }\n return stackedCols;\n };\n Reorder.prototype.getHeaderCells = function () {\n return [].slice.call(this.parent.element.getElementsByClassName('e-headercell'));\n };\n Reorder.prototype.getColParent = function (column, columns) {\n var parents = [];\n this.findColParent(column, columns, parents);\n return parents[parents.length - 1];\n };\n Reorder.prototype.reorderSingleColumn = function (fromFName, toFName) {\n var fColumn = this.parent.enableColumnVirtualization ?\n this.parent.columns.filter(function (col) { return col.field === fromFName; })[0]\n : this.parent.getColumnByField(fromFName);\n var toColumn = this.parent.enableColumnVirtualization ?\n this.parent.columns.filter(function (col) { return col.field === toFName; })[0]\n : this.parent.getColumnByField(toFName);\n if ((!isNullOrUndefined(fColumn) && (!fColumn.allowReordering || fColumn.lockColumn)) ||\n (!isNullOrUndefined(toColumn) && (!toColumn.allowReordering || toColumn.lockColumn))) {\n this.parent.log('action_disabled_column', { moduleName: this.getModuleName(), column: fColumn, destColumn: toColumn });\n return;\n }\n var column = toColumn;\n var parent = this.getColParent(column, this.parent.columns);\n var columns = parent ? parent.columns : this.parent.columns;\n var destIndex = inArray(column, columns);\n if (destIndex > -1) {\n this.moveColumns(destIndex, fColumn, true);\n }\n };\n Reorder.prototype.reorderMultipleColumns = function (fromFNames, toFName) {\n var toIndex = this.parent.getColumnIndexByField(toFName);\n var toColumn = this.parent.getColumnByField(toFName);\n if (toIndex < 0 || (!isNullOrUndefined(toColumn) && (!toColumn.allowReordering || toColumn.lockColumn))) {\n return;\n }\n for (var i = 0; i < fromFNames.length; i++) {\n var column = this.parent.getColumnByField(fromFNames[parseInt(i.toString(), 10)]);\n if (!isNullOrUndefined(column) && (!column.allowReordering || column.lockColumn)) {\n return;\n }\n }\n for (var i = 0; i < fromFNames.length; i++) {\n var column = this.parent.getColumnByIndex(toIndex);\n var parent_1 = this.getColParent(column, this.parent.columns);\n var columns = parent_1 ? parent_1.columns : this.parent.columns;\n var destIndex = inArray(column, columns);\n if (destIndex > -1) {\n this.moveColumns(destIndex, this.parent.getColumnByField(fromFNames[parseInt(i.toString(), 10)]), true, true);\n }\n if (this.parent.getColumnIndexByField(fromFNames[i + 1]) >= destIndex) {\n toIndex++; //R to L\n }\n }\n };\n Reorder.prototype.moveTargetColumn = function (column, toIndex) {\n if (toIndex > -1) {\n this.moveColumns(toIndex, column, true);\n }\n };\n Reorder.prototype.reorderSingleColumnByTarget = function (fieldName, toIndex) {\n this.moveTargetColumn(this.parent.getColumnByField(fieldName), toIndex);\n };\n Reorder.prototype.reorderMultipleColumnByTarget = function (fieldName, toIndex) {\n for (var i = 0; i < fieldName.length; i++) {\n this.reorderSingleColumnByTarget(fieldName[parseInt(i.toString(), 10)], toIndex);\n }\n };\n /**\n * Changes the position of the Grid columns by field names.\n *\n * @param {string | string[]} fromFName - Defines the origin field names.\n * @param {string} toFName - Defines the destination field name.\n * @returns {void}\n */\n Reorder.prototype.reorderColumns = function (fromFName, toFName) {\n if (typeof fromFName === 'string') {\n this.reorderSingleColumn(fromFName, toFName);\n this.fromCol = fromFName;\n }\n else {\n this.reorderMultipleColumns(fromFName, toFName);\n this.fromCol = fromFName[0];\n }\n };\n /**\n * Changes the position of the Grid columns by field index.\n *\n * @param {number} fromIndex - Defines the origin field index.\n * @param {number} toIndex - Defines the destination field index.\n * @returns {void}\n */\n Reorder.prototype.reorderColumnByIndex = function (fromIndex, toIndex) {\n this.moveTargetColumn(this.parent.getColumnByIndex(fromIndex), toIndex);\n };\n /**\n * Changes the position of the Grid columns by field index.\n *\n * @param {string | string[]} fieldName - Defines the field name.\n * @param {number} toIndex - Defines the destination field index.\n * @returns {void}\n */\n Reorder.prototype.reorderColumnByTargetIndex = function (fieldName, toIndex) {\n if (typeof fieldName === 'string') {\n this.reorderSingleColumnByTarget(fieldName, toIndex);\n }\n else {\n this.reorderMultipleColumnByTarget(fieldName, toIndex);\n }\n };\n Reorder.prototype.enableAfterRender = function (e) {\n if (e.module === this.getModuleName() && e.enable) {\n this.createReorderElement();\n }\n };\n Reorder.prototype.createReorderElement = function (e) {\n if (e && e.args && e.args.isXaxis) {\n this.setDisplay('none');\n }\n var header = this.parent.element.querySelector('.' + literals.headerContent);\n this.upArrow = header.appendChild(this.parent\n .createElement('div', { className: 'e-icons e-icon-reorderuparrow e-reorderuparrow', attrs: { style: 'display:none' } }));\n this.downArrow = header.appendChild(this.parent\n .createElement('div', { className: 'e-icons e-icon-reorderdownarrow e-reorderdownarrow', attrs: { style: 'display:none' } }));\n };\n /**\n * The function used to trigger onActionComplete\n *\n * @param {NotifyArgs} e - specified the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Reorder.prototype.onActionComplete = function (e) {\n this.parent.trigger(events.actionComplete, extend(e, { type: events.actionComplete }));\n var target = this.fromCol && this.parent.getColumnHeaderByField(this.fromCol);\n if (target) {\n this.parent.focusModule.onClick({ target: target }, true);\n }\n };\n /**\n * To destroy the reorder\n *\n * @returns {void}\n * @hidden\n */\n Reorder.prototype.destroy = function () {\n var gridElement = this.parent.element;\n if (this.parent.isDestroyed || !gridElement || (!gridElement.querySelector('.' + literals.gridHeader) &&\n !gridElement.querySelector('.' + literals.gridContent))) {\n return;\n }\n if (this.upArrow.parentNode) {\n remove(this.upArrow);\n }\n if (this.downArrow.parentNode) {\n remove(this.downArrow);\n }\n this.parent.off(events.headerDrop, this.headerDrop);\n this.parent.off(events.uiUpdate, this.enableAfterRender);\n this.parent.off(events.reorderComplete, this.onActionComplete);\n this.parent.off(events.columnDrag, this.drag);\n this.parent.off(events.columnDragStart, this.dragStart);\n this.parent.off(events.columnDragStop, this.dragStop);\n this.parent.off(events.headerRefreshed, this.createReorderElement);\n this.parent.off(events.keyPressed, this.keyPressHandler);\n this.parent.off(events.destroy, this.destroy);\n //call ejdrag and drop destroy\n };\n Reorder.prototype.keyPressHandler = function (e) {\n var gObj = this.parent;\n var isMacLike = /(Mac)/i.test(navigator.platform);\n if (isMacLike && e.metaKey) {\n if (e.action === 'leftArrow') {\n e.action = 'ctrlLeftArrow';\n }\n else if (e.action === 'rightArrow') {\n e.action = 'ctrlRightArrow';\n }\n }\n switch (e.action) {\n case 'ctrlLeftArrow':\n case 'ctrlRightArrow':\n // eslint-disable-next-line no-case-declarations\n var element = gObj.focusModule.currentInfo.element;\n if (element && element.classList.contains('e-headercell')) {\n var column = gObj.getColumnByUid(element.firstElementChild.getAttribute('e-mappinguid'));\n var visibleCols = gObj.getVisibleColumns();\n var index = visibleCols.indexOf(column);\n var toCol = e.action === 'ctrlLeftArrow' ? visibleCols[index - 1] : visibleCols[index + 1];\n if (toCol && toCol.field && column.field) {\n this.reorderColumns(column.field, toCol.field);\n }\n }\n break;\n }\n };\n Reorder.prototype.drag = function (e) {\n var gObj = this.parent;\n var target = e.target;\n var closest = closestElement(target, '.e-headercell:not(.e-stackedHeaderCell)');\n var cloneElement = gObj.element.querySelector('.e-cloneproperties');\n var content = gObj.getContent().firstElementChild;\n var isLeft = this.x > getPosition(e.event).x + content.scrollLeft;\n removeClass([].slice.call(gObj.getHeaderTable().getElementsByClassName('e-reorderindicate')), ['e-reorderindicate']);\n this.setDisplay('none');\n this.stopTimer();\n classList(cloneElement, ['e-defaultcur'], ['e-notallowedcur']);\n this.updateScrollPostion(e.event);\n if (closest && !closest.isEqualNode(this.element)) {\n target = closest;\n //consider stacked, detail header cell\n var uid = target.querySelector('.e-headercelldiv, .e-stackedheadercelldiv').getAttribute('e-mappinguid');\n if (!(!this.chkDropPosition(this.element, target) || !this.chkDropAllCols(this.element, target)) &&\n gObj.getColumnByUid(uid).allowReordering && e.column.allowReordering) {\n this.updateArrowPosition(target, isLeft);\n classList(target, ['e-allowDrop', 'e-reorderindicate'], []);\n }\n else if (!(gObj.allowGrouping && parentsUntil(e.target, 'e-groupdroparea'))) {\n classList(cloneElement, ['e-notallowedcur'], ['e-defaultcur']);\n }\n }\n else {\n if (closest && closest.isEqualNode(this.element) &&\n !((gObj.allowGrouping && e.column.allowGrouping) || e.column.allowReordering)) {\n classList(cloneElement, ['e-notallowedcur'], ['e-defaultcur']);\n }\n else if (!closest && !(gObj.allowGrouping && parentsUntil(e.target, 'e-groupdroparea'))) {\n classList(cloneElement, ['e-notallowedcur'], ['e-defaultcur']);\n }\n }\n if (!e.column.allowReordering || e.column.lockColumn) {\n return;\n }\n gObj.trigger(events.columnDrag, { target: target, draggableType: 'headercell', column: e.column });\n };\n Reorder.prototype.updateScrollPostion = function (e) {\n var _this = this;\n var x = getPosition(e).x;\n var cliRect = this.parent.element.getBoundingClientRect();\n var cliRectBaseRight = cliRect.right;\n var cliRectBaseLeft = cliRect.left;\n var scrollElem = this.parent.getContent().firstElementChild;\n if (x > cliRectBaseLeft && x < cliRectBaseLeft + 35) {\n this.timer = window.setInterval(function () { _this.setScrollLeft(scrollElem, true); }, 50);\n }\n else if (x < cliRectBaseRight && x > cliRectBaseRight - 35) {\n this.timer = window.setInterval(function () { _this.setScrollLeft(scrollElem, false); }, 50);\n }\n };\n Reorder.prototype.setScrollLeft = function (scrollElem, isLeft) {\n var scrollLeft = scrollElem.scrollLeft;\n scrollElem.scrollLeft = scrollElem.scrollLeft + (isLeft ? -5 : 5);\n if (scrollLeft !== scrollElem.scrollLeft) {\n this.setDisplay('none');\n }\n };\n Reorder.prototype.stopTimer = function () {\n window.clearInterval(this.timer);\n };\n Reorder.prototype.updateArrowPosition = function (target, isLeft) {\n var cliRect = target.getBoundingClientRect();\n var cliRectBase = this.parent.element.getBoundingClientRect();\n if ((isLeft && cliRect.left < cliRectBase.left) || (!isLeft && cliRect.right > cliRectBase.right)) {\n return;\n }\n var isSticky = this.parent.getHeaderContent().classList.contains('e-sticky');\n this.upArrow.style.top = isSticky ? cliRect.top + cliRect.height + 'px' : cliRect.top + cliRect.height - cliRectBase.top + 'px';\n this.downArrow.style.top = isSticky ? cliRect.top - 7 + 'px' : cliRect.top - cliRectBase.top - 7 + 'px';\n this.upArrow.style.left = this.downArrow.style.left = isSticky ? (isLeft ? cliRect.left : cliRect.right) - 4 + 'px' :\n (isLeft ? cliRect.left : cliRect.right) - cliRectBase.left - 4 + 'px';\n this.setDisplay('');\n };\n Reorder.prototype.dragStart = function (e) {\n var gObj = this.parent;\n var target = e.target;\n this.element = target.classList.contains('e-headercell') ? target :\n parentsUntil(target, 'e-headercell');\n if (!e.column.allowReordering || e.column.lockColumn) {\n return;\n }\n var content = gObj.getContent().firstElementChild;\n this.x = getPosition(e.event).x + content.scrollLeft;\n gObj.trigger(events.columnDragStart, {\n target: target, draggableType: 'headercell', column: e.column\n });\n };\n Reorder.prototype.dragStop = function (e) {\n var gObj = this.parent;\n this.setDisplay('none');\n this.stopTimer();\n if (!e.cancel) {\n gObj.trigger(events.columnDrop, { target: e.target, draggableType: 'headercell', column: e.column });\n }\n removeClass([].slice.call(gObj.getHeaderTable().getElementsByClassName('e-reorderindicate')), ['e-reorderindicate']);\n };\n Reorder.prototype.setDisplay = function (display) {\n this.upArrow.style.display = display;\n this.downArrow.style.display = display;\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} return the module name\n * @private\n */\n Reorder.prototype.getModuleName = function () {\n return 'reorder';\n };\n return Reorder;\n}());\nexport { Reorder };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { addClass, removeClass, attributes, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { Button } from '@syncfusion/ej2-buttons';\nimport { CellRenderer } from './cell-renderer';\nimport { addStickyColumnPosition, appendChildren } from '../base/util';\nimport { destroy, commandColumnDestroy } from '../base/constant';\n/**\n * `CommandColumn` used to render command column in grid\n *\n * @hidden\n */\nvar CommandColumnRenderer = /** @class */ (function (_super) {\n __extends(CommandColumnRenderer, _super);\n function CommandColumnRenderer(parent, locator) {\n var _this = _super.call(this, parent, locator) || this;\n _this.buttonElement = _this.parent.createElement('button', {});\n _this.unbounDiv = _this.parent.createElement('div', { className: 'e-unboundcelldiv', styles: 'display: inline-block' });\n _this.childRefs = [];\n _this.element = _this.parent.createElement('TD', {\n className: 'e-rowcell e-unboundcell', attrs: {\n tabindex: '-1', role: 'gridcell'\n }\n });\n _this.parent.on(destroy, _this.destroyButtons, _this);\n _this.parent.on(commandColumnDestroy, _this.destroyButtons, _this);\n return _this;\n }\n CommandColumnRenderer.prototype.destroyButtons = function (args) {\n for (var i = 0; i < this.childRefs.length; i++) {\n if (this.childRefs[parseInt(i.toString(), 10)] && !this.childRefs[parseInt(i.toString(), 10)].isDestroyed) {\n this.childRefs[parseInt(i.toString(), 10)].destroy();\n if (this.childRefs[parseInt(i.toString(), 10)].element) {\n this.childRefs[parseInt(i.toString(), 10)].element.innerHTML = '';\n }\n }\n }\n this.childRefs = [];\n if (args.type === 'refreshCommandColumn') {\n var elem = this.parent.element.querySelectorAll('.e-unboundcell');\n if (elem.length) {\n for (var i = 0; i < elem.length; i++) {\n if (elem[parseInt(i.toString(), 10)]) {\n if (elem[parseInt(i.toString(), 10)].querySelector('.e-unboundcelldiv')) {\n elem[parseInt(i.toString(), 10)].querySelector('.e-unboundcelldiv').innerHTML = '';\n }\n elem[parseInt(i.toString(), 10)].innerHTML = '';\n }\n }\n elem = null;\n }\n }\n else {\n this.parent.off(destroy, this.destroyButtons);\n this.parent.off(commandColumnDestroy, this.destroyButtons);\n }\n };\n /**\n * Function to render the cell content based on Column object.\n *\n * @param {cell<Column>} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @param {Object} attributes - specifies the attributes\n * @param {boolean} isVirtualEdit - specifies virtual scroll editing\n * @returns {Element} returns the element\n */\n CommandColumnRenderer.prototype.render = function (cell, data, attributes, isVirtualEdit) {\n var node = this.element.cloneNode();\n var uid = 'uid';\n node.appendChild(this.unbounDiv.cloneNode());\n node.setAttribute('aria-label', this.localizer.getConstant('CommandColumnAria') + cell.column.headerText);\n if (cell.column.commandsTemplate) {\n if (this.parent.isReact && typeof (cell.column.commandsTemplate) !== 'string') {\n var tempID = this.parent + 'commandsTemplate';\n cell.column.getColumnTemplate()(data, this.parent, 'commandsTemplate', tempID, null, null, node.firstElementChild);\n this.parent.renderTemplates();\n }\n else {\n appendChildren(node.firstElementChild, cell.column.getColumnTemplate()(data));\n }\n }\n else {\n for (var _i = 0, _a = cell.commands; _i < _a.length; _i++) {\n var command = _a[_i];\n node = this.renderButton(node, command, attributes.index, command[\"\" + uid]);\n }\n }\n this.setAttributes(node, cell, attributes);\n if ((!this.parent.enableVirtualization && this.parent.isEdit) || isVirtualEdit) {\n addClass([].slice.call(node.getElementsByClassName('e-edit-delete')), 'e-hide');\n removeClass([].slice.call(node.getElementsByClassName('e-save-cancel')), 'e-hide');\n }\n else {\n addClass([].slice.call(node.getElementsByClassName('e-save-cancel')), 'e-hide');\n removeClass([].slice.call(node.getElementsByClassName('e-edit-delete')), 'e-hide');\n }\n if (this.parent.isFrozenGrid()) {\n addStickyColumnPosition(this.parent, cell.column, node);\n }\n return node;\n };\n CommandColumnRenderer.prototype.renderButton = function (node, buttonOption, index, uid) {\n var button = this.buttonElement.cloneNode();\n attributes(button, {\n 'id': this.parent.element.id + (buttonOption.type || '') + '_' + index + '_' + uid, 'type': 'button',\n title: !isNullOrUndefined(buttonOption.title) ? buttonOption.title :\n buttonOption.buttonOption.content || this.localizer.getConstant(buttonOption.type) || buttonOption.type,\n 'data-uid': uid\n });\n button.onclick = buttonOption.buttonOption.click;\n buttonOption.buttonOption.cssClass = this.parent.cssClass ?\n buttonOption.buttonOption.cssClass + ' ' + this.parent.cssClass : buttonOption.buttonOption.cssClass;\n var buttonObj = new Button(buttonOption.buttonOption, button);\n this.childRefs.push(buttonObj);\n buttonObj.commandType = buttonOption.type;\n node.firstElementChild.appendChild(buttonObj.element);\n switch (buttonOption.type) {\n case 'Edit':\n case 'Delete':\n addClass([button], ['e-edit-delete', 'e-' + buttonOption.type.toLowerCase() + 'button']);\n break;\n case 'Cancel':\n case 'Save':\n addClass([button], ['e-save-cancel', 'e-' + buttonOption.type.toLowerCase() + 'button']);\n break;\n }\n return node;\n };\n return CommandColumnRenderer;\n}(CellRenderer));\nexport { CommandColumnRenderer };\n","import { closest, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { click, keyPressed, commandClick, initialEnd, destroy } from '../base/constant';\nimport { CellType } from '../base/enum';\nimport { CommandColumnRenderer } from '../renderer/command-column-renderer';\nimport { getUid } from '../base/util';\nimport * as literals from '../base/string-literals';\n/**\n * `CommandColumn` used to handle the command column actions.\n *\n * @hidden\n */\nvar CommandColumn = /** @class */ (function () {\n function CommandColumn(parent, locator) {\n this.parent = parent;\n this.locator = locator;\n this.initiateRender();\n this.addEventListener();\n }\n CommandColumn.prototype.initiateRender = function () {\n var cellFac = this.locator.getService('cellRendererFactory');\n cellFac.addCellRenderer(CellType.CommandColumn, new CommandColumnRenderer(this.parent, this.locator));\n };\n CommandColumn.prototype.commandClickHandler = function (e) {\n var gObj = this.parent;\n var target = closest(e.target, 'button');\n if (!target || !closest(e.target, '.e-unboundcell')) {\n return;\n }\n var buttonObj = target.ej2_instances[0];\n var type = buttonObj.commandType;\n var uid = target.getAttribute('data-uid');\n var commandColumn;\n var row = gObj.getRowObjectFromUID(closest(target, '.' + literals.row).getAttribute('data-uid'));\n var cols = this.parent.columnModel;\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].commands) {\n var commandCols = cols[parseInt(i.toString(), 10)].commands;\n for (var j = 0; j < commandCols.length; j++) {\n var idInString = 'uid';\n var typeInString = 'type';\n if (commandCols[parseInt(j.toString(), 10)][\"\" + idInString] === uid && commandCols[parseInt(j.toString(), 10)][\"\" + typeInString] === type) {\n commandColumn = commandCols[parseInt(j.toString(), 10)];\n }\n else {\n var buttons = [].slice.call(closest(target, '.e-unboundcell').querySelectorAll('button'));\n var index = buttons.findIndex(function (ele) { return ele === target; });\n if (index < commandCols.length && commandCols[parseInt(index.toString(), 10)][\"\" + typeInString] === type &&\n String(commandCols[parseInt(j.toString(), 10)][\"\" + idInString]) === uid) {\n commandColumn = commandCols[parseInt(index.toString(), 10)];\n }\n }\n }\n }\n }\n var args = {\n cancel: false,\n target: target,\n commandColumn: commandColumn,\n rowData: isNullOrUndefined(row) ? undefined : row.data\n };\n this.parent.trigger(commandClick, args, function (commandclickargs) {\n if (buttonObj.disabled || !gObj.editModule || commandclickargs.cancel) {\n return;\n }\n switch (type) {\n case 'Edit':\n gObj.editModule.endEdit();\n gObj.editModule.startEdit(closest(target, 'tr'));\n break;\n case 'Cancel':\n gObj.editModule.closeEdit();\n break;\n case 'Save':\n gObj.editModule.endEdit();\n break;\n case 'Delete':\n if (gObj.editSettings.mode !== 'Batch') {\n gObj.editModule.endEdit();\n }\n gObj.commandDelIndex = parseInt(closest(target, 'tr').getAttribute(literals.dataRowIndex), 10);\n gObj.clearSelection();\n //for toogle issue when dbl click\n gObj.selectRow(gObj.commandDelIndex, false);\n gObj.editModule.deleteRecord();\n gObj.commandDelIndex = undefined;\n break;\n }\n });\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n */\n CommandColumn.prototype.getModuleName = function () {\n return 'commandColumn';\n };\n /**\n * To destroy CommandColumn.\n *\n * @function destroy\n * @returns {void}\n */\n CommandColumn.prototype.destroy = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.removeEventListener();\n };\n CommandColumn.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(click, this.commandClickHandler);\n this.parent.off(keyPressed, this.keyPressHandler);\n this.parent.off(initialEnd, this.load);\n this.parent.off(destroy, this.destroy);\n };\n CommandColumn.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(click, this.commandClickHandler, this);\n this.parent.on(keyPressed, this.keyPressHandler, this);\n this.parent.on(initialEnd, this.load, this);\n this.parent.on(destroy, this.destroy, this);\n };\n CommandColumn.prototype.keyPressHandler = function (e) {\n if (e.action === 'enter' && closest(e.target, '.e-unboundcelldiv')) {\n this.commandClickHandler(e);\n e.preventDefault();\n }\n };\n CommandColumn.prototype.load = function () {\n var uid = 'uid';\n var col = this.parent.columnModel;\n for (var i = 0; i < col.length; i++) {\n if (col[parseInt(i.toString(), 10)].commands) {\n var commandCol = col[parseInt(i.toString(), 10)].commands;\n for (var j = 0; j < commandCol.length; j++) {\n commandCol[parseInt(j.toString(), 10)][\"\" + uid] = getUid('gridcommand');\n }\n }\n }\n };\n return CommandColumn;\n}());\nexport { CommandColumn };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable max-len */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { Property, Complex, ChildProperty } from '@syncfusion/ej2-base';\nimport { measureText, Rect, TextOption, Size, PathOption } from '@syncfusion/ej2-svg-base';\nimport { Font, Border, Margin, ContainerPadding, Location } from '../model/base';\nimport { subtractThickness, Thickness, drawSymbol, ChartLocation, titlePositionX, getTitle, textTrim, getTextAnchor } from '../utils/helper';\nimport { RectOption, textElement, stringToNumber } from '../utils/helper';\nimport { removeElement, showTooltip, getElement, appendChildElement } from '../utils/helper';\n/**\n * Configures the legends in charts.\n */\nvar LegendSettings = /** @class */ (function (_super) {\n __extends(LegendSettings, _super);\n function LegendSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(true)\n ], LegendSettings.prototype, \"visible\", void 0);\n __decorate([\n Property(null)\n ], LegendSettings.prototype, \"height\", void 0);\n __decorate([\n Property(null)\n ], LegendSettings.prototype, \"width\", void 0);\n __decorate([\n Complex({ x: 0, y: 0 }, Location)\n ], LegendSettings.prototype, \"location\", void 0);\n __decorate([\n Property('Auto')\n ], LegendSettings.prototype, \"position\", void 0);\n __decorate([\n Property('Series')\n ], LegendSettings.prototype, \"mode\", void 0);\n __decorate([\n Property(8)\n ], LegendSettings.prototype, \"padding\", void 0);\n __decorate([\n Property(null)\n ], LegendSettings.prototype, \"itemPadding\", void 0);\n __decorate([\n Property('Center')\n ], LegendSettings.prototype, \"alignment\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"14px\", fontStyle: 'Normal', fontWeight: '400', color: null }, Font)\n ], LegendSettings.prototype, \"textStyle\", void 0);\n __decorate([\n Property(10)\n ], LegendSettings.prototype, \"shapeHeight\", void 0);\n __decorate([\n Property(10)\n ], LegendSettings.prototype, \"shapeWidth\", void 0);\n __decorate([\n Complex({}, Border)\n ], LegendSettings.prototype, \"border\", void 0);\n __decorate([\n Complex({ left: 0, right: 0, top: 0, bottom: 0 }, Margin)\n ], LegendSettings.prototype, \"margin\", void 0);\n __decorate([\n Complex({ left: 0, right: 0, top: 0, bottom: 0 }, ContainerPadding)\n ], LegendSettings.prototype, \"containerPadding\", void 0);\n __decorate([\n Property(8)\n ], LegendSettings.prototype, \"shapePadding\", void 0);\n __decorate([\n Property('transparent')\n ], LegendSettings.prototype, \"background\", void 0);\n __decorate([\n Property(1)\n ], LegendSettings.prototype, \"opacity\", void 0);\n __decorate([\n Property(true)\n ], LegendSettings.prototype, \"toggleVisibility\", void 0);\n __decorate([\n Property(false)\n ], LegendSettings.prototype, \"enableHighlight\", void 0);\n __decorate([\n Property(null)\n ], LegendSettings.prototype, \"description\", void 0);\n __decorate([\n Property(3)\n ], LegendSettings.prototype, \"tabIndex\", void 0);\n __decorate([\n Property(null)\n ], LegendSettings.prototype, \"title\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"14px\", fontStyle: 'Normal', fontWeight: '600', color: null }, Font)\n ], LegendSettings.prototype, \"titleStyle\", void 0);\n __decorate([\n Property('Top')\n ], LegendSettings.prototype, \"titlePosition\", void 0);\n __decorate([\n Property('Normal')\n ], LegendSettings.prototype, \"textWrap\", void 0);\n __decorate([\n Property('Ellipsis')\n ], LegendSettings.prototype, \"textOverflow\", void 0);\n __decorate([\n Property(100)\n ], LegendSettings.prototype, \"maximumTitleWidth\", void 0);\n __decorate([\n Property(null)\n ], LegendSettings.prototype, \"maximumLabelWidth\", void 0);\n __decorate([\n Property(true)\n ], LegendSettings.prototype, \"enablePages\", void 0);\n __decorate([\n Property(false)\n ], LegendSettings.prototype, \"isInversed\", void 0);\n __decorate([\n Property(false)\n ], LegendSettings.prototype, \"reverse\", void 0);\n return LegendSettings;\n}(ChildProperty));\nexport { LegendSettings };\n/**\n * Legend base class for Chart and Accumulation chart.\n *\n * @private\n */\nvar BaseLegend = /** @class */ (function () {\n /**\n * Constructor for the dateTime module.\n *\n * @private\n */\n function BaseLegend(chart) {\n this.maxItemHeight = 0;\n this.rowHeights = [];\n this.pageHeights = [];\n this.columnHeights = [];\n this.pageXCollections = []; // pages of x locations\n this.chartRowCount = 1;\n this.legendTitleCollections = [];\n this.legendRegions = [];\n this.pagingRegions = [];\n this.chart = chart;\n this.legend = chart.legendSettings;\n this.legendID = chart.element.id + '_chart_legend';\n this.isChartControl = (chart.getModuleName() === 'chart' || chart.getModuleName() === 'chart3d');\n this.isAccChartControl = (chart.getModuleName() === 'accumulationchart');\n this.isBulletChartControl = (chart.getModuleName() === 'bulletChart');\n this.isStockChartControl = (chart.getModuleName() === 'stockChart');\n this.bulletChart = this.chart;\n this.fivePixel = 5;\n this.rowCount = 0;\n this.pageButtonSize = 8;\n this.maxColumns = 0;\n this.maxWidth = 0;\n this.currentPage = 1;\n this.backwardArrowOpacity = 0;\n this.forwardArrowOpacity = 1;\n this.arrowWidth = (2 * (this.fivePixel + this.pageButtonSize + this.fivePixel));\n this.arrowHeight = this.arrowWidth;\n this.isTop = false;\n this.isTitle = false;\n this.currentPageNumber = 1;\n }\n ;\n /**\n * Calculate the bounds for the legends.\n *\n * @returns {void}\n * @private\n */\n BaseLegend.prototype.calculateLegendBounds = function (rect, availableSize, maxLabelSize) {\n var legend = this.legend;\n var defaultValue = (this.isBulletChartControl) ? '40%' : '20%';\n this.getPosition(legend.position, availableSize);\n this.legendBounds = new Rect(rect.x, rect.y, 0, 0);\n this.isVertical = (this.position === 'Left' || this.position === 'Right');\n this.itemPadding = this.legend.itemPadding ? this.legend.itemPadding : this.isVertical ? this.legend.padding : 20;\n if (this.isVertical) {\n this.legendBounds.height = stringToNumber(legend.height, availableSize.height - (rect.y - this.chart.margin.top)) || rect.height;\n this.legendBounds.width = stringToNumber(legend.width || defaultValue, availableSize.width);\n }\n else {\n this.legendBounds.width = stringToNumber(legend.width, availableSize.width) || rect.width;\n this.legendBounds.height = stringToNumber(legend.height || defaultValue, availableSize.height);\n }\n if (this.chart.getModuleName() === 'chart3d') {\n this.library.get3DLegendBounds(availableSize, this.legendBounds, legend);\n }\n else {\n this.library.getLegendBounds(availableSize, this.legendBounds, legend);\n }\n if (!this.isBulletChartControl) {\n this.legendBounds.width += (this.legend.containerPadding.left + this.legend.containerPadding.right);\n this.legendBounds.height += (this.legend.containerPadding.top + this.legend.containerPadding.bottom);\n }\n this.getLocation(this.position, legend.alignment, this.legendBounds, rect, availableSize, maxLabelSize);\n };\n /**\n * To find legend position based on available size for chart and accumulation chart\n *\n * @param position\n * @param availableSize\n * @param position\n * @param availableSize\n * @returns {void}\n */\n BaseLegend.prototype.getPosition = function (position, availableSize) {\n var chart = this.chart;\n var accumulation = this.chart;\n if (this.isChartControl || this.isBulletChartControl || this.isStockChartControl) {\n this.position = (position !== 'Auto') ? position : 'Bottom';\n }\n else {\n if (position === 'Auto' && ((chart || accumulation).visibleSeries && (chart || accumulation).visibleSeries[0].type === 'Funnel' || (chart || accumulation).visibleSeries[0].type === 'Pyramid')) {\n position = 'Top';\n }\n this.position = (position !== 'Auto') ? position :\n (availableSize.width > availableSize.height ? 'Right' : 'Bottom');\n }\n };\n /**\n * To set bounds for chart and accumulation chart\n *\n * @param computedWidth\n * @param computedHeight\n * @param legend\n * @param legendBounds\n * @param computedWidth\n * @param computedHeight\n * @param legend\n * @param legendBounds\n * @param computedWidth\n * @param computedHeight\n * @param legend\n * @param legendBounds\n * @param computedWidth\n * @param computedHeight\n * @param legend\n * @param legendBounds\n * @returns {void}\n */\n BaseLegend.prototype.setBounds = function (computedWidth, computedHeight, legend, legendBounds) {\n var titleHeight = legend.title && legend.titlePosition === 'Top' ? this.legendTitleSize.height + this.fivePixel : 0;\n if (this.isVertical && this.isPaging && !legend.enablePages && !this.isBulletChartControl) {\n titleHeight = legend.title && legend.titlePosition === 'Top' ? this.legendTitleSize.height + this.fivePixel : 0;\n titleHeight += (this.pageButtonSize + this.fivePixel);\n }\n computedWidth = Math.min(computedWidth, legendBounds.width);\n computedHeight = Math.min(computedHeight, legendBounds.height);\n if (legend.mode === 'Gradient') {\n legendBounds.width = legend.width ? legendBounds.width : this.isVertical ? computedWidth : 0.75 * legendBounds.width;\n legendBounds.height = legend.height ? legendBounds.height : this.isVertical ? 0.75 * legendBounds.height : computedHeight;\n }\n else {\n legendBounds.width = !legend.width ? computedWidth : legendBounds.width;\n legendBounds.height = !legend.height ? computedHeight : legendBounds.height;\n }\n if (!this.isBulletChartControl) {\n if (this.isTop && legend.titleStyle.textOverflow !== 'None') {\n this.calculateLegendTitle(legend, legendBounds);\n legendBounds.height += legend.titleStyle.textOverflow === 'Wrap' && this.legendTitleCollections.length > 1 ?\n (this.legendTitleSize.height - (this.legendTitleSize.height / this.legendTitleCollections.length)) : 0;\n }\n }\n this.rowCount = Math.max(1, Math.ceil((legendBounds.height - legend.padding - titleHeight) /\n (this.maxItemHeight + legend.padding)));\n };\n /**\n * To find legend location based on position, alignment for chart and accumulation chart\n *\n * @param position\n * @param alignment\n * @param legendBounds\n * @param rect\n * @param availableSize\n * @param maxLabelSize\n * @param position\n * @param alignment\n * @param legendBounds\n * @param rect\n * @param availableSize\n * @param maxLabelSize\n * @param position\n * @param alignment\n * @param legendBounds\n * @param rect\n * @param availableSize\n * @param maxLabelSize\n * @param position\n * @param alignment\n * @param legendBounds\n * @param rect\n * @param availableSize\n * @param maxLabelSize\n * @param position\n * @param alignment\n * @param legendBounds\n * @param rect\n * @param availableSize\n * @param maxLabelSize\n * @param position\n * @param alignment\n * @param legendBounds\n * @param rect\n * @param availableSize\n * @param maxLabelSize\n */\n BaseLegend.prototype.getLocation = function (position, alignment, legendBounds, rect, availableSize, maxLabelSize) {\n var padding = this.legend.border.width;\n var isBulletChart = this.isBulletChartControl;\n var bulletChart = this.bulletChart;\n var labelIns = bulletChart.labelPosition === 'Inside';\n var ticklIns = bulletChart.tickPosition === 'Inside';\n var isVertical = bulletChart.orientation === 'Vertical';\n var categoryFieldValue = (isBulletChart && bulletChart.categoryField !== '') ?\n maxLabelSize.width + this.chart.border.width + padding * 3 : 0;\n var marginBottom = this.chart.margin.bottom;\n var legendHeight = legendBounds.height + padding + this.legend.margin.top + this.legend.margin.bottom;\n var legendWidth = legendBounds.width + padding + this.legend.margin.left + this.legend.margin.right;\n if (position === 'Bottom') {\n legendBounds.x = this.alignLegend(legendBounds.x, availableSize.width, legendBounds.width, alignment);\n legendBounds.y = rect.y + (rect.height - legendHeight) + padding + this.legend.margin.top;\n legendBounds.y += (isBulletChart && !bulletChart.opposedPosition && !labelIns && !ticklIns\n && !isVertical) ? bulletChart.majorTickLines.height + marginBottom + this.legend.border.width + padding * 2 :\n (isVertical && bulletChart.categoryField !== '') ? maxLabelSize.height + padding * 2 : 0;\n subtractThickness(rect, new Thickness(0, 0, 0, legendHeight));\n }\n else if (position === 'Top') {\n var axisTextSize = void 0;\n if (this.isChartControl) {\n axisTextSize = measureText('100', this.chart.verticalAxes[0].labelStyle, this.chart.themeStyle.legendLabelFont);\n }\n legendBounds.x = this.alignLegend(legendBounds.x, availableSize.width, legendBounds.width, alignment);\n legendBounds.y = rect.y + padding + this.legend.margin.top;\n legendBounds.y -= (isBulletChart && bulletChart.opposedPosition && !labelIns && !ticklIns &&\n !isVertical) ? bulletChart.majorTickLines.height + this.chart.margin.top : 0;\n legendHeight -= (isBulletChart) ? -padding * 2 : (this.isChartControl ? -padding * 2 - axisTextSize.height / 2 : 0);\n subtractThickness(rect, new Thickness(0, 0, legendHeight, 0));\n }\n else if (position === 'Right') {\n legendBounds.x = rect.x + (rect.width - legendBounds.width) - this.legend.margin.right;\n legendBounds.y = rect.y + this.alignLegend(0, availableSize.height - (rect.y + marginBottom), legendBounds.height, alignment);\n legendWidth += (isBulletChart && bulletChart.opposedPosition && !labelIns && !ticklIns &&\n isVertical) ? (this.chart.margin.left + this.chart.margin.right + bulletChart.majorTickLines.height) : 0;\n subtractThickness(rect, new Thickness(0, legendWidth, 0, 0));\n }\n else if (position === 'Left') {\n legendBounds.x = legendBounds.x + this.legend.margin.left;\n legendBounds.y = rect.y + this.alignLegend(0, availableSize.height - (rect.y + marginBottom), legendBounds.height, alignment);\n legendWidth += (isBulletChart && !bulletChart.opposedPosition && !labelIns && !ticklIns &&\n isVertical) ? (legendBounds.x - this.chart.margin.left + padding + bulletChart.majorTickLines.height) :\n (bulletChart.orientation !== 'Vertical' && bulletChart.categoryField !== '') ? categoryFieldValue : 0;\n subtractThickness(rect, new Thickness(legendWidth, 0, 0, 0));\n }\n else {\n legendBounds.x = this.legend.location.x;\n legendBounds.y = this.legend.location.y;\n subtractThickness(rect, new Thickness(0, 0, 0, 0));\n }\n };\n /**\n * To find legend alignment for chart and accumulation chart\n *\n * @param start\n * @param size\n * @param legendSize\n * @param alignment\n * @param start\n * @param size\n * @param legendSize\n * @param alignment\n * @param start\n * @param size\n * @param legendSize\n * @param alignment\n * @param start\n * @param size\n * @param legendSize\n * @param alignment\n */\n BaseLegend.prototype.alignLegend = function (start, size, legendSize, alignment) {\n switch (alignment) {\n case 'Far':\n start = (size - legendSize) - start;\n break;\n case 'Center':\n start = ((size - legendSize) / 2);\n break;\n }\n return start;\n };\n /**\n * Renders the legend.\n *\n * @param chart\n * @param legend\n * @param legendBounds\n * @param redraw\n * @param chart\n * @param legend\n * @param legendBounds\n * @param redraw\n * @param chart\n * @param legend\n * @param legendBounds\n * @param redraw\n * @param chart\n * @param legend\n * @param legendBounds\n * @param redraw\n * @returns {void}\n * @private\n */\n BaseLegend.prototype.renderLegend = function (chart, legend, legendBounds, redraw) {\n var titleHeight = 0;\n var titlePlusArrowWidth = 0;\n var pagingLegendBounds = new Rect(0, 0, 0, 0);\n var requireLegendBounds = new Rect(0, 0, 0, 0);\n var firstLegend = this.findFirstLegendPosition(this.legendCollections);\n var padding = legend.padding;\n this.itemPadding = this.isBulletChartControl ? legend.padding : this.itemPadding;\n var isPaging = legend.enablePages;\n var titlePosition = legend.titlePosition;\n var upArrowHeight = this.isPaging && !legend.enablePages && this.isVertical ? this.pageButtonSize : 0;\n var legendGroup = chart.renderer.createGroup({ id: this.legendID + '_g' });\n var legendTranslateGroup = this.createLegendElements(chart, legendBounds, legendGroup, legend, this.legendID, redraw);\n this.legendRegions = [];\n this.chartRowCount = 1;\n var maxHeight = 0;\n titleHeight = !this.isTitle ? 0 : (this.isTop || this.isVertical ? this.legendTitleSize.height : 0);\n if (this.isChartControl || (this.isAccChartControl && !this.isVertical)) {\n var pageCount = 1;\n var rowHeights = this.rowHeights[0] + padding;\n for (var i = 1; i < this.rowHeights.length; i++) {\n if ((rowHeights + this.rowHeights[i] + padding) > (this.legendBounds.height - this.pageButtonSize - this.maxItemHeight / 2)) {\n this.pageHeights[pageCount - 1] = rowHeights + titleHeight;\n pageCount++;\n rowHeights = 0;\n }\n rowHeights += (this.rowHeights[i] + (this.isVertical ? this.itemPadding : padding));\n }\n this.pageHeights[pageCount - 1] = rowHeights + titleHeight;\n this.totalPages = pageCount;\n }\n for (var i = 0; i < this.legendCollections.length; i++) {\n if (this.legendCollections[i].text !== '') {\n maxHeight = Math.max(this.legendCollections[i].textSize.height, maxHeight);\n break;\n }\n else {\n continue;\n }\n }\n if (!this.isChartControl && !this.isAccChartControl) {\n this.maxItemHeight = Math.max(maxHeight, legend.shapeHeight);\n }\n // For new legend navigation\n if (!isPaging && this.isPaging && !this.isVertical) {\n titlePlusArrowWidth = !this.isTitle ? 0 : titlePosition === 'Left' ? this.legendTitleSize.width : 0;\n titlePlusArrowWidth += (this.pageButtonSize + (2 * this.fivePixel));\n }\n else if (this.isTitle && !this.isPaging && !this.isVertical) {\n titlePlusArrowWidth = titlePosition === ((!this.isRtlEnable) ? 'Left' : 'Right') ? (this.fivePixel + this.legendTitleSize.width) : 0;\n }\n if (chart.legendSettings.mode === 'Gradient' && this.legendCollections.length > 1) {\n this.getLinearLegend(legendBounds, chart, legend, legendTranslateGroup);\n this.totalPages = 1;\n }\n else if (firstLegend !== this.legendCollections.length) {\n var legendSeriesGroup = void 0; // legendItem group for each series group element\n var count = 0;\n var previousLegend = this.legendCollections[firstLegend];\n // starting shape center x,y position && to resolve lint error used new line for declaration\n var startPadding = this.isBulletChartControl ? 0 : titlePlusArrowWidth + padding + (legend.shapeWidth / 2) + legend.containerPadding.left;\n var xLocation = this.isBulletChartControl ? legendBounds.x + titlePlusArrowWidth + padding + (legend.shapeWidth / 2) :\n (!this.isRtlEnable) ? legendBounds.x + startPadding : legendBounds.x + ((this.chart.getModuleName() === 'accumulationchart' && this.isVertical) ? this.maxWidth : legendBounds.width) - startPadding;\n var start = new ChartLocation(xLocation, this.isBulletChartControl ? legendBounds.y + titleHeight + upArrowHeight + padding + (this.maxItemHeight / 2) :\n legendBounds.y + titleHeight + upArrowHeight + padding + (this.maxItemHeight / 2) + legend.containerPadding.top);\n var anchor = chart.isRtlEnabled || chart.enableRtl ? 'end' : 'start';\n var textOptions = new TextOption('', start.x, start.y, anchor);\n var textPadding = legend.shapePadding + this.itemPadding + legend.shapeWidth;\n // initialization for totalPages legend click totalpage again calculate\n this.totalPages = this.totalPages = (this.isAccChartControl || this.isChartControl || this.isBulletChartControl || this.isStockChartControl) ? this.totalPages : 0;\n this.pageXCollections = [];\n this.legendCollections[firstLegend].location = start;\n var legendIndex = void 0;\n if (!legend.enablePages && this.isPaging) {\n var x = start.x - this.fivePixel;\n var y = start.y - this.fivePixel;\n var leftSpace = this.isTitle && !this.isVertical && titlePosition === 'Left' ?\n this.legendTitleSize.width + this.fivePixel : 0;\n var bottomSapce = this.isVertical ? (this.pageButtonSize) + Math.abs(y - legendBounds.y) : 0;\n var rightSpace = this.isTitle && !this.isVertical && titlePosition === 'Right' ?\n this.legendTitleSize.width + this.fivePixel : 0;\n rightSpace += this.isVertical ? 0 : (this.fivePixel + this.pageButtonSize + this.fivePixel);\n pagingLegendBounds = new Rect(x, y, legendBounds.width - rightSpace - leftSpace, legendBounds.height - bottomSapce);\n requireLegendBounds = pagingLegendBounds;\n }\n else {\n requireLegendBounds = legendBounds;\n }\n var legendOption = void 0;\n for (var i = 0; i < this.legendCollections.length; i++) {\n legendOption = this.legendCollections[i];\n legendIndex = !this.isReverse ? count : (this.legendCollections.length - 1) - count;\n if (this.chart.getModuleName() === 'accumulationchart') {\n legendOption.fill = (this.chart || this.chart || this.chart || this.chart).visibleSeries[0].points[legendOption.pointIndex].color;\n }\n if (this.chart.getModuleName() === 'stockChart') {\n legendOption.type = this.chart.visibleSeries[count].type;\n }\n this.accessbilityText = (this.isBulletChartControl) ? 'Legend of bullet chart' + '' + legendOption.text\n : 'Click to show or hide the ' + legendOption.text + ' series';\n if (legendOption.render && legendOption.text && legendOption.text !== '') {\n legendSeriesGroup = chart.renderer.createGroup({\n id: this.legendID + this.generateId(legendOption, '_g_', legendIndex)\n });\n if (legendSeriesGroup) {\n legendSeriesGroup.setAttribute('tabindex', i === 0 ? '0' : '');\n legendSeriesGroup.setAttribute('aria-label', legend.description || (legendOption.text + ' series is ' + (legendOption.visible ? 'showing, press enter to hide the ' : 'hidden, press enter to show the ') + legendOption.text + ' series'));\n legendSeriesGroup.setAttribute('role', 'button');\n legendSeriesGroup.setAttribute('aria-pressed', legendOption.visible ? 'true' : 'false');\n }\n this.library.getRenderPoint(legendOption, start, textPadding, previousLegend, requireLegendBounds, count, firstLegend);\n this.renderSymbol(legendOption, legendSeriesGroup, legendIndex);\n this.renderText(chart, legendOption, legendSeriesGroup, textOptions, count, legendIndex);\n if (legendSeriesGroup) {\n legendSeriesGroup.style.cssText =\n 'pointer-events: bounding-box; cursor: ' + ((!legend.toggleVisibility && (chart.selectionMode === 'None' ||\n chart.highlightMode === 'None' ||\n chart.selectionMode === 'None') || this.isBulletChartControl) ? 'auto' : 'pointer');\n }\n if (legendTranslateGroup) {\n legendTranslateGroup.appendChild(legendSeriesGroup);\n }\n previousLegend = legendOption;\n }\n count++;\n }\n this.totalPages = (this.isPaging && !this.isBulletChartControl && !this.legend.enablePages && !this.isVertical &&\n this.totalPages > this.chartRowCount) ? this.chartRowCount : this.totalPages;\n if (this.isPaging && this.totalPages > 1) {\n this.renderPagingElements(chart, legendBounds, textOptions, legendGroup);\n }\n else {\n this.totalPages = 1;\n }\n }\n appendChildElement(chart.enableCanvas, chart.svgObject, legendGroup, redraw);\n };\n /** @private */\n BaseLegend.prototype.getLinearLegend = function (legendBounds, chart, legend, legendTranslateGroup) {\n var xmlns = 'http://www.w3.org/2000/svg';\n var previousLegend = this.legendCollections[0];\n var nextLegend = this.legendCollections[1];\n var defElement = this.chart.renderer.createDefs();\n var gradientLegendCount = 0;\n var linerGradientEle = document.createElementNS(xmlns, 'linearGradient');\n var opacity = 1;\n var fillColors = [];\n var numberItems = [];\n if (legend.title) {\n if (!this.isVertical) {\n if (legend.titlePosition === 'Left') {\n legendBounds.x += this.legendTitleSize.width;\n legendBounds.width -= this.legendTitleSize.width;\n }\n else if (legend.titlePosition === 'Right') {\n legendBounds.width -= this.legendTitleSize.width;\n }\n else if (legend.titlePosition === 'Top') {\n legendBounds.y += this.legendTitleSize.height;\n legendBounds.height -= this.legendTitleSize.height;\n }\n }\n else {\n legendBounds.y += this.legendTitleSize.height;\n legendBounds.height -= this.legendTitleSize.height;\n }\n }\n for (var _i = 0, _a = this.chart.rangeColorSettings; _i < _a.length; _i++) {\n var colorMap = _a[_i];\n if (numberItems.indexOf(colorMap.start) < 0) {\n numberItems.push(colorMap.start);\n }\n if (colorMap.colors.length > 2) {\n var diffValue = (colorMap.end - colorMap.start);\n var colorsLength = colorMap.colors.length - 1;\n if (diffValue > 0) {\n diffValue = diffValue / colorsLength;\n for (var index = 1; index < colorsLength; index++) {\n var calculatedValue = colorMap.start + (diffValue * index);\n numberItems.push(calculatedValue);\n }\n }\n else {\n for (var index = 1; index < colorsLength; index++) {\n numberItems.push(colorMap.start);\n }\n }\n }\n if (numberItems.indexOf(colorMap.end) < 0) {\n numberItems.push(colorMap.end);\n }\n for (var _b = 0, _c = colorMap.colors; _b < _c.length; _b++) {\n var fillColor = _c[_b];\n if (fillColors.indexOf(fillColor) < 0) {\n fillColors.push(fillColor);\n }\n }\n if (colorMap.colors.length > 0 && colorMap.colors.length < 2) {\n fillColors.push(colorMap.colors[0]);\n }\n }\n var x1 = this.isRtlEnable && !this.isVertical ? '100%' : '0%';\n var x2 = this.isVertical || this.isRtlEnable ? '0%' : '100%';\n var y2 = this.isVertical ? '100%' : '0%';\n linerGradientEle.setAttribute('id', this.generateId(previousLegend, 'linearGradient', gradientLegendCount));\n linerGradientEle.setAttribute('x1', x1);\n linerGradientEle.setAttribute('y1', '0%');\n linerGradientEle.setAttribute('x2', x2);\n linerGradientEle.setAttribute('y2', y2);\n var full = numberItems[numberItems.length - 1] - numberItems[0];\n for (var b = 0; b < fillColors.length; b++) {\n var offsetValue = numberItems[b] - numberItems[0];\n offsetValue = offsetValue / full;\n var stopEle = document.createElementNS(xmlns, 'stop');\n stopEle.setAttribute('offset', offsetValue.toString());\n stopEle.setAttribute('stop-color', fillColors[b]);\n stopEle.setAttribute('stop-opacity', opacity.toString());\n linerGradientEle.appendChild(stopEle);\n }\n var startLabel = previousLegend.text.toString();\n var endLabel = nextLegend.text.toString();\n var startTextSize = measureText(startLabel, legend.textStyle, this.chart.themeStyle.legendLabelFont);\n var endTextSize = measureText(endLabel, legend.textStyle, this.chart.themeStyle.legendLabelFont);\n var textWidth = startTextSize.width > endTextSize.width ? startTextSize.width : endTextSize.width;\n var textHeight = startTextSize.height > endTextSize.height ? startTextSize.height : endTextSize.height;\n var otherSpaces = (2 * textWidth) + (4 * legend.padding);\n var linearBarWidth = legendBounds.width;\n var linearBarHeight = legendBounds.height;\n var xValue = legendBounds.x + textWidth + (2 * legend.padding);\n var yValue = legendBounds.y + legend.padding;\n var startLabelY;\n var endLabelY;\n var startLabelX;\n var endLabelX;\n if (this.isVertical) {\n otherSpaces = (2 * textHeight) + (4 * legend.padding);\n linearBarWidth = legendBounds.width - (2 * legend.padding);\n linearBarHeight = legendBounds.height - otherSpaces;\n xValue = legendBounds.x + legend.padding;\n yValue = legendBounds.y + textHeight + (2 * legend.padding);\n startLabelY = legendBounds.y + legend.padding + textHeight;\n endLabelY = yValue + linearBarHeight + textHeight;\n startLabelX = (legendBounds.x + (legendBounds.width * 0.5)) - (textWidth * 0.5);\n endLabelX = startLabelX;\n if (linearBarWidth > 30) {\n var diffWidth = linearBarWidth - 30;\n linearBarWidth = 30;\n xValue = xValue + (diffWidth / 2);\n }\n }\n else {\n linearBarWidth = legendBounds.width - otherSpaces;\n linearBarHeight = legendBounds.height - (2 * legend.padding);\n startLabelX = legendBounds.x + ((!this.isRtlEnable) ? legend.padding + (textWidth - startTextSize.width) :\n linearBarWidth + (3 * legend.padding) + textWidth);\n endLabelX = legendBounds.x + ((!this.isRtlEnable) ? linearBarWidth + (3 * legend.padding) + textWidth :\n legend.padding + (textWidth - endTextSize.width));\n startLabelY = legendBounds.y + (legendBounds.height * 0.5) + (textHeight * 0.25);\n endLabelY = startLabelY;\n if (linearBarHeight > 30) {\n var diffHeight = linearBarHeight - 30;\n linearBarHeight = 30;\n yValue = yValue + (diffHeight / 2);\n }\n }\n var anchor = chart.enableRtl ? 'end' : '';\n var textOptions = new TextOption('', startLabelX, startLabelY, anchor, startLabel);\n var hiddenColor = '#D3D3D3';\n textOptions.id = this.legendID + this.generateId(previousLegend, '_text_', 1);\n var fontcolor = previousLegend.visible ? legend.textStyle.color || chart.themeStyle.legendLabelFont.color : hiddenColor;\n var isCanvas = this.isStockChartControl ? false : this.chart.enableCanvas;\n textElement(chart.renderer, textOptions, legend.textStyle, fontcolor, legendTranslateGroup, false, false, false, false, \n // tslint:disable-next-line:align\n null, this.currentPageNumber && isCanvas ?\n new Rect(0, -this.translatePage(isCanvas, null, this.currentPageNumber - 1, this.currentPageNumber), 0, 0) : null, null, null, null, null, this.chart.themeStyle.legendLabelFont);\n textOptions = new TextOption('', endLabelX, endLabelY, anchor, endLabel);\n textOptions.id = this.legendID + this.generateId(previousLegend, '_text_', 2);\n textElement(chart.renderer, textOptions, legend.textStyle, fontcolor, legendTranslateGroup, false, false, false, false, \n // tslint:disable-next-line:align\n null, this.currentPageNumber && isCanvas ?\n new Rect(0, -this.translatePage(isCanvas, null, this.currentPageNumber - 1, this.currentPageNumber), 0, 0) : null, null, null, null, null, this.chart.themeStyle.legendLabelFont);\n var gradientLegend = chart.renderer.drawRectangle({\n width: linearBarWidth,\n height: linearBarHeight,\n x: xValue,\n y: yValue,\n fill: 'url(#' + this.generateId(previousLegend, 'linearGradient', gradientLegendCount) + ')'\n });\n defElement.appendChild(linerGradientEle);\n legendTranslateGroup.appendChild(defElement);\n legendTranslateGroup.appendChild(gradientLegend);\n };\n /**\n * To find first valid legend text index for chart and accumulation chart\n *\n * @param legendCollection\n * @returns {number}\n * @private\n */\n BaseLegend.prototype.findFirstLegendPosition = function (legendCollection) {\n var count = 0;\n for (var _i = 0, legendCollection_1 = legendCollection; _i < legendCollection_1.length; _i++) {\n var legend = legendCollection_1[_i];\n if (legend.render && legend.text && legend.text !== '') {\n break;\n }\n count++;\n }\n return count;\n };\n /**\n * To get the legend title text width and height.\n *\n * @param legend\n * @param legendBounds\n */\n BaseLegend.prototype.calculateLegendTitle = function (legend, legendBounds) {\n if (legend.title) {\n this.isTop = legend.titlePosition === 'Top';\n var padding = legend.titleStyle.textOverflow === 'Trim' ? 2 * legend.padding : 0;\n if (this.isTop || this.isVertical) {\n this.legendTitleCollections = getTitle(legend.title, legend.titleStyle, (legendBounds.width - padding), this.chart.enableRtl, this.chart.themeStyle.legendTitleFont);\n }\n else {\n this.legendTitleCollections[0] = textTrim(legend.maximumTitleWidth, legend.title, legend.titleStyle, this.chart.enableRtl, this.chart.themeStyle.legendTitleFont);\n }\n var text = this.isTop ? legend.title : this.legendTitleCollections[0];\n this.legendTitleSize = measureText(text, legend.titleStyle, this.chart.themeStyle.legendTitleFont);\n this.legendTitleSize.height *= this.legendTitleCollections.length;\n }\n else {\n this.legendTitleSize = new Size(0, 0);\n }\n };\n /**\n * Render the legend title\n *\n * @param chart\n * @param legend\n * @param legendBounds\n * @param legendGroup\n */\n BaseLegend.prototype.renderLegendTitle = function (chart, legend, legendBounds, legendGroup) {\n var padding = legend.padding;\n var alignment = legend.titleStyle.textAlignment;\n this.isTop = legend.titlePosition === 'Top';\n var anchor = getTextAnchor(legend.titleStyle.textAlignment, chart.enableRtl);\n var x = titlePositionX(legendBounds, legend.titleStyle);\n anchor = this.isTop || this.isVertical ? anchor : (chart.enableRtl) ? 'end' : '';\n x = alignment === 'Near' ? (x + padding) : alignment === 'Far' ? (x - padding) : x;\n x = (this.isTop || this.isVertical) ? x : ((legendBounds.x) + (legend.titlePosition === 'Left' ? 5 :\n (legendBounds.width - this.legendTitleSize.width - 5)));\n var topPadding = (legendBounds.height / 2) + (this.legendTitleSize.height / 4);\n var y = legendBounds.y + (!this.isTop && !this.isVertical ? topPadding :\n (this.legendTitleSize.height / this.legendTitleCollections.length));\n var legendTitleTextOptions = new TextOption(this.legendID + '_title', x, y, anchor, this.legendTitleCollections);\n textElement(chart.renderer, legendTitleTextOptions, legend.titleStyle, legend.titleStyle.color || this.chart.themeStyle.legendTitleFont.color, legendGroup, null, null, null, null, null, null, null, null, null, null, this.chart.themeStyle.legendTitleFont);\n };\n /**\n * To create legend rendering elements for chart and accumulation chart\n *\n * @param chart\n * @param legendBounds\n * @param legendGroup\n * @param legend\n * @param id\n * @param redraw\n */\n BaseLegend.prototype.createLegendElements = function (chart, legendBounds, legendGroup, legend, id, redraw) {\n var padding = legend.padding;\n var options = new RectOption(id + '_element', legend.background, legend.border, legend.opacity, legendBounds);\n var legendItemsGroup = chart.renderer.createGroup({ id: id + '_collections' });\n var isCanvas = this.isStockChartControl ? false : chart.enableCanvas;\n var clippath = chart.renderer.createClipPath({ id: id + '_clipPath' });\n options.width = (this.isRtlEnable && this.chart.getModuleName() === 'accumulationchart' && this.isVertical) ? this.maxWidth : legendBounds.width;\n if (legendGroup) {\n legendGroup.appendChild(chart.renderer.drawRectangle(options));\n }\n else {\n chart.renderer.drawRectangle(options);\n }\n if (legend.title) {\n this.renderLegendTitle(chart, legend, legendBounds, legendGroup);\n }\n if (!isCanvas) {\n legendGroup.appendChild(legendItemsGroup);\n }\n this.legendTranslateGroup = chart.renderer.createGroup({ id: id + '_translate_g' });\n if (!isCanvas) {\n legendItemsGroup.appendChild(this.legendTranslateGroup);\n }\n options.y += (this.isTop ? this.legendTitleSize.height : 0);\n options.id += '_clipPath_rect';\n options.width = ((!this.isChartControl && chart.getModuleName() !== 'bulletChart' && !this.isStockChartControl) && this.isVertical) ? this.maxWidth - padding + legend.containerPadding.left + legend.containerPadding.right\n : legendBounds.width;\n if (!isCanvas) {\n this.clipRect = chart.renderer.drawRectangle(options);\n clippath.appendChild(this.clipRect);\n }\n else {\n this.pagingClipRect = options;\n }\n appendChildElement(isCanvas, chart.svgObject, clippath, redraw);\n if (!isCanvas) {\n legendItemsGroup.style.cssText = 'clip-path:url(#' + clippath.id + ')';\n }\n return this.legendTranslateGroup;\n };\n /**\n * To render legend symbols for chart and accumulation chart\n *\n * @param legendOption\n * @param group\n * @param i\n * @param legendOption\n * @param group\n * @param i\n * @param legendOption\n * @param group\n * @param i\n */\n BaseLegend.prototype.renderSymbol = function (legendOption, group, legendIndex) {\n var control = this.isBulletChartControl ? this.chart : null;\n var symbolColor = legendOption.visible ? legendOption.fill : '#D3D3D3';\n var isStrokeWidth = (this.chart.getModuleName() === 'chart' || this.chart.getModuleName() === 'stockChart') && (((legendOption.shape === 'SeriesType') &&\n (legendOption.type.toLowerCase().indexOf('line') > -1) && (legendOption.type.toLowerCase().indexOf('area') === -1)) ||\n ((legendOption.shape === 'HorizontalLine') || (legendOption.shape === 'VerticalLine') || (legendOption.shape === 'Cross')));\n var isCustomBorder = (this.chart.getModuleName() === 'chart' || this.chart.getModuleName() === 'stockChart') &&\n (legendOption.type === 'Scatter' || legendOption.type === 'Bubble');\n var isCanvas = this.isStockChartControl ? false : this.chart.enableCanvas;\n var borderColor;\n var shape = (legendOption.shape === 'SeriesType') ? legendOption.type : legendOption.shape;\n var strokewidth = isStrokeWidth ? (this.legend.mode === 'Series' ?\n this.chart.visibleSeries[legendIndex].width : this.chart.visibleSeries[0].width) :\n (this.isBulletChartControl && legendOption.shape === 'Multiply') ? 4 : 1;\n var regionPadding;\n shape = shape === 'Scatter' ? legendOption.markerShape : shape;\n if (isCustomBorder && legendIndex < this.chart.visibleSeries.length) {\n var series = this.chart.visibleSeries[legendIndex];\n var seriesBorder = series.border;\n var isLineShapemarker = shape === 'HorizontalLine' || shape === 'VerticalLine';\n borderColor = isLineShapemarker ? symbolColor : seriesBorder.color ? seriesBorder.color : symbolColor;\n strokewidth = isLineShapemarker ? series.width : seriesBorder.width ? seriesBorder.width : 1;\n }\n var symbolOption = new PathOption(this.legendID + this.generateId(legendOption, '_shape_', legendIndex), symbolColor, strokewidth, (isCustomBorder ? borderColor : symbolColor), this.legend.opacity, legendOption.dashArray, '');\n var textSize = measureText(legendOption.text, this.legend.textStyle, this.chart.themeStyle.legendLabelFont);\n var x = this.legend.isInversed && !this.isRtlEnable ? legendOption.location.x + textSize.width + this.legend.shapePadding\n : legendOption.location.x;\n var y = legendOption.location.y;\n if (!isCanvas) {\n group.appendChild(drawSymbol({ x: x, y: y }, shape, new Size(this.legend.shapeWidth, this.legend.shapeHeight), legendOption.url, symbolOption, this.accessbilityText, this.chart.renderer, null, this.isBulletChartControl, control));\n }\n else {\n regionPadding = -this.translatePage(isCanvas, null, this.currentPageNumber - 1, this.currentPageNumber);\n drawSymbol({ x: x, y: y }, shape, new Size(this.legend.shapeWidth, this.legend.shapeHeight), '', symbolOption, this.accessbilityText, this.chart.renderer, this.currentPageNumber ? new Rect(0, regionPadding, 0, 0) : null, this.isBulletChartControl, control);\n this.legendRegions.push({\n rect: new Rect(legendOption.location.x, legendOption.location.y, this.legend.shapeWidth, this.legend.shapeHeight + regionPadding), index: legendIndex\n });\n }\n if (shape === 'Line' && legendOption.markerVisibility && legendOption.markerShape !== 'Image' ||\n (legendOption.type === 'Doughnut' && shape === 'Doughnut')) {\n symbolOption.id = this.legendID + this.generateId(legendOption, '_shape_marker_', legendIndex);\n shape = legendOption.type === 'Doughnut' ? 'Circle' : legendOption.markerShape;\n symbolOption.fill = legendOption.type === 'Doughnut' ? '#FFFFFF' : symbolOption.fill;\n if (!isCanvas) {\n group.appendChild(drawSymbol({ x: x, y: y }, shape, new Size(this.legend.shapeWidth / 2, this.legend.shapeHeight / 2), '', symbolOption, this.accessbilityText, null, null, this.isBulletChartControl, control));\n }\n else {\n drawSymbol({ x: x, y: y }, shape, new Size(this.legend.shapeWidth / 2, this.legend.shapeHeight / 2), '', symbolOption, this.accessbilityText, this.chart.renderer, this.currentPageNumber ?\n new Rect(0, -this.translatePage(isCanvas, null, this.currentPageNumber - 1, this.currentPageNumber), 0, 0) : null, this.isBulletChartControl, control);\n }\n }\n };\n /**\n * To render legend text for chart and accumulation chart\n *\n * @param chart\n * @param legendOption\n * @param group\n * @param textOptions\n * @param i\n * @param chart\n * @param legendOption\n * @param group\n * @param textOptions\n * @param i\n * @param chart\n * @param legendOption\n * @param group\n * @param textOptions\n * @param i\n * @param chart\n * @param legendOption\n * @param group\n * @param textOptions\n * @param i\n * @param chart\n * @param legendOption\n * @param group\n * @param textOptions\n * @param i\n */\n BaseLegend.prototype.renderText = function (chart, legendOption, group, textOptions, i, legendIndex) {\n var legend = chart.legendSettings;\n var hiddenColor = '#D3D3D3';\n var fontcolor = legendOption.visible ? legend.textStyle.color || chart.themeStyle.legendLabelFont.color : hiddenColor;\n var isCanvas = this.isStockChartControl ? false : this.chart.enableCanvas;\n textOptions.id = this.legendID + this.generateId(legendOption, '_text_', legendIndex);\n textOptions.text = legendOption.textCollection.length > 0 ? legendOption.textCollection : legendOption.text;\n if (legend.isInversed && !this.isRtlEnable) {\n textOptions.x = legendOption.location.x - (legend.shapeWidth / 2);\n }\n else if (this.isRtlEnable) {\n var textWidth = measureText(legendOption.text, legend.textStyle, this.chart.themeStyle.legendLabelFont).width;\n textOptions.x = legendOption.location.x - ((legendOption.textCollection.length > 1 ? textWidth / legendOption.textCollection.length : textWidth) + legend.shapeWidth / 2 + legend.shapePadding);\n }\n else {\n textOptions.x = legendOption.location.x + (legend.shapeWidth / 2) + legend.shapePadding;\n }\n textOptions.y = legendOption.location.y + this.maxItemHeight / 4;\n var element = textElement(chart.renderer, textOptions, legend.textStyle, fontcolor, group, false, false, false, false, null, this.currentPageNumber && isCanvas ?\n new Rect(0, -this.translatePage(isCanvas, null, this.currentPageNumber - 1, this.currentPageNumber), 0, 0) : null, null, null, null, null, this.chart.themeStyle.legendLabelFont);\n if (isCanvas) {\n var textSize = measureText(legendOption.text, legend.textStyle, this.chart.themeStyle.legendLabelFont);\n this.legendRegions[i].rect.y = textOptions.y < this.legendRegions[i].rect.y ? textOptions.y : this.legendRegions[i].rect.y;\n this.legendRegions[i].rect.width += textSize.width;\n this.legendRegions[i].rect.height = textSize.height;\n this.legendRegions[i].rect.y -= textSize.height * 0.5;\n this.legendRegions[i].rect.x -= (this.isRtlEnable) ? this.legendRegions[i].rect.width : 0;\n }\n };\n /**\n * To render legend paging elements for chart and accumulation chart\n *\n * @param chart\n * @param bounds\n * @param textOption\n * @param legendGroup\n * @param chart\n * @param bounds\n * @param textOption\n * @param legendGroup\n * @param chart\n * @param bounds\n * @param textOption\n * @param legendGroup\n * @param chart\n * @param bounds\n * @param textOption\n * @param legendGroup\n */\n // tslint:disable-next-line:max-func-body-length\n BaseLegend.prototype.renderPagingElements = function (chart, bounds, textOption, legendGroup) {\n var paginggroup = chart.renderer.createGroup({ id: this.legendID + '_navigation' });\n var isCanvas = this.isStockChartControl ? false : chart.enableCanvas;\n var titleHeight = this.isBulletChartControl ? 0 : this.legendTitleSize.height;\n var grayColor = (this.chart.theme.indexOf('Dark') > -1 || this.chart.theme.indexOf('Contrast') > -1) ? '#FFFFFF' : '#545454';\n var legend = chart.legendSettings; // to solve parameter lint error, legend declaration is here\n var padding = 8; // const padding for paging elements\n var pageUp = this.legendID + (!this.isRtlEnable ? '_pageup' : '_pagedown');\n var pageDown = this.legendID + (!this.isRtlEnable ? '_pagedown' : '_pageup');\n var symbolOption = new PathOption(pageUp, 'transparent', 5, grayColor, 1, '', '');\n var iconSize = this.pageButtonSize;\n // Page left arrow drawing calculation started here\n var rowCount = !legend.enablePages && this.isPaging && !this.isVertical && !this.isBulletChartControl ? 1 :\n (this.rowCount - 1);\n var titleWidth = this.isTitle && legend.titlePosition === 'Left' ? this.legendTitleSize.width : 0;\n this.pagingRegions = [];\n this.backwardArrowOpacity = this.currentPage !== 1 ? 1 : 0;\n this.forwardArrowOpacity = this.currentPage === this.totalPages ? 0 : 1;\n if (!isCanvas) {\n legendGroup.appendChild(paginggroup);\n }\n if (!this.isChartControl && !this.isAccChartControl) {\n if (this.isBulletChartControl || this.isStockChartControl || !this.isVertical) {\n this.totalPages = Math.ceil(this.totalPages / Math.max(1, this.rowCount - 1));\n }\n else {\n this.totalPages = Math.ceil(this.totalPages / this.maxColumns);\n }\n }\n if (paginggroup) {\n paginggroup.style.cursor = 'pointer';\n }\n if ((this.isChartControl || this.isAccChartControl) && !(!legend.enablePages && this.isPaging)) {\n this.clipPathHeight = this.pageHeights[0];\n }\n else {\n this.clipPathHeight = (rowCount * (this.maxItemHeight + legend.padding));\n }\n //this.clipPathHeight = !(this.isChartControl) ? (rowCount * (this.maxItemHeight + legend.padding)) : this.columnHeights[0];\n if (!isCanvas) {\n this.clipRect.setAttribute('height', this.clipPathHeight.toString());\n }\n else {\n //paging clipRect only for canvas mode\n this.pagingClipRect.height = this.legendBounds.height - this.clipPathHeight -\n (this.pagingClipRect.y - this.legendBounds.y) - legend.border.width;\n this.pagingClipRect.y = this.pagingClipRect.y + this.clipPathHeight;\n this.pagingClipRect.x += legend.border.width;\n this.pagingClipRect.width -= (legend.border.width + legend.border.width / 2);\n this.chart.renderer.clearRect(new Rect(this.pagingClipRect.x, this.pagingClipRect.y, this.pagingClipRect.width, this.pagingClipRect.height));\n }\n var pageTextElement;\n var x = (bounds.x + iconSize / 2);\n var y = bounds.y + this.clipPathHeight + ((titleHeight + bounds.height - this.clipPathHeight) / 2);\n if (this.isPaging && !legend.enablePages && !this.isVertical && !this.isBulletChartControl) {\n x = (bounds.x + this.pageButtonSize + titleWidth);\n y = legend.title && this.isTop ? (bounds.y + padding + titleHeight + (iconSize / 1) + 0.5) :\n (bounds.y + padding + iconSize + 0.5);\n }\n var size = measureText(this.totalPages + '/' + this.totalPages, legend.textStyle, this.chart.themeStyle.legendLabelFont);\n var translateX = (this.isRtlEnable) ? legend.border.width + (iconSize / 2) : bounds.width - (2 * (iconSize + padding) + padding + size.width);\n if (!isCanvas) {\n if (this.isVertical && !legend.enablePages && !this.isBulletChartControl) {\n x = bounds.x + (bounds.width / 2);\n y = bounds.y + (iconSize / 2) + (padding / 2) + titleHeight;\n symbolOption.opacity = this.backwardArrowOpacity;\n paginggroup.appendChild(drawSymbol({ x: x, y: y }, 'UpArrow', new Size(iconSize, iconSize), '', symbolOption, 'UpArrow'));\n }\n else {\n symbolOption.opacity = this.isBulletChartControl ? symbolOption.opacity :\n (legend.enablePages ? 1 : !this.isRtlEnable ? this.backwardArrowOpacity : this.forwardArrowOpacity);\n paginggroup.appendChild(drawSymbol({ x: x, y: y }, 'LeftArrow', new Size(iconSize, iconSize), '', symbolOption, 'LeftArrow'));\n }\n }\n else {\n drawSymbol({ x: x, y: y }, 'LeftArrow', new Size(iconSize, iconSize), '', symbolOption, 'LeftArrow', this.chart.renderer, new Rect(translateX, 0, 0, 0));\n }\n this.pagingRegions.push(new Rect(!this.isRtlEnable ? x + bounds.width - (2 * (iconSize + padding) + padding + size.width) - iconSize * 0.5 : x, y - iconSize * 0.5, iconSize, iconSize));\n // Page numbering rendering calculation started here\n textOption.x = x + (iconSize / 2) + padding;\n textOption.y = y + (size.height / 4);\n textOption.id = this.legendID + '_pagenumber';\n textOption.text = !this.isRtlEnable ? '1/' + this.totalPages : this.totalPages + '/1';\n var color = (this.chart.theme.indexOf('Dark') > -1 || this.chart.theme.indexOf('Contrast') > -1) ? '#FFFFFF' : legend.textStyle.color || this.chart.themeStyle.legendLabelFont.color;\n if (isCanvas && this.totalNoOfPages) {\n textOption.text = !this.isRtlEnable ? this.currentPageNumber + '/' + this.totalNoOfPages : this.totalNoOfPages + '/' + this.currentPageNumber;\n }\n if (legend.enablePages || this.isBulletChartControl) {\n pageTextElement = textElement(chart.renderer, textOption, legend.textStyle, color, paginggroup, false, false, false, false, null, new Rect(translateX, 0, 0, 0), null, null, null, null, this.chart.themeStyle.legendLabelFont);\n }\n // Page right arrow rendering calculation started here\n x = textOption.x + padding + (iconSize / 2) + size.width;\n if (this.isPaging && !legend.enablePages && !this.isVertical) {\n x = (bounds.x + bounds.width - (this.isBulletChartControl ? this.fivePixel : 0) - this.pageButtonSize - (legend.title && legend.titlePosition === 'Right' ?\n this.legendTitleSize.width + this.fivePixel : 0));\n }\n symbolOption.id = pageDown;\n symbolOption.opacity = !legend.enablePages ? !this.isRtlEnable ? this.forwardArrowOpacity : this.backwardArrowOpacity : 1;\n if (!isCanvas) {\n if (this.isVertical && !legend.enablePages && !this.isBulletChartControl) {\n x = bounds.x + (bounds.width / 2);\n y = bounds.y + bounds.height - (iconSize / 2);\n paginggroup.appendChild(drawSymbol({ x: x, y: y }, 'DownArrow', new Size(iconSize, iconSize), '', symbolOption, 'DownArrow'));\n }\n else {\n paginggroup.appendChild(drawSymbol({ x: x, y: y }, 'RightArrow', new Size(iconSize, iconSize), '', symbolOption, 'RightArrow'));\n }\n }\n else {\n drawSymbol({ x: x, y: y }, 'RightArrow', new Size(iconSize, iconSize), '', symbolOption, 'RightArrow', this.chart.renderer, new Rect(translateX, 0, 0, 0));\n }\n this.pagingRegions.push(new Rect(!this.isRtlEnable ? x + (bounds.width - (2 * (iconSize + padding) + padding + size.width) - iconSize * 0.5) : x, y - iconSize * 0.5, iconSize, iconSize));\n if (!isCanvas && (legend.enablePages || this.isBulletChartControl)) {\n //placing the navigation buttons and page numbering in legend right corner\n paginggroup.setAttribute('transform', 'translate(' + translateX + ', ' + 0 + ')');\n }\n else {\n if (this.currentPageNumber === 1 && this.calTotalPage && (legend.enablePages || this.isBulletChartControl)) {\n this.totalNoOfPages = this.totalPages;\n this.calTotalPage = false;\n }\n if (!legend.enablePages && !this.isBulletChartControl) { // For new legend page navigation\n this.translatePage(isCanvas, null, this.currentPage - 1, this.currentPage, legend);\n }\n }\n if (legend.enablePages || this.isBulletChartControl) {\n this.translatePage(isCanvas, pageTextElement, this.currentPage - 1, this.currentPage, legend);\n }\n };\n BaseLegend.prototype.getPageHeight = function (pageHeights, pageCount) {\n var sum = 0;\n for (var i = 0; i < pageCount; i++) {\n sum += pageHeights[i];\n }\n return sum;\n };\n /**\n * To translate legend pages for chart and accumulation chart\n *\n * @param pagingText\n * @param page\n * @param pageNumber\n * @param legend\n * @param pagingText\n * @param page\n * @param pageNumber\n * @param legend\n * @param pagingText\n * @param page\n * @param pageNumber\n * @param legend\n * @param pagingText\n * @param page\n * @param pageNumber\n * @param legend\n */\n BaseLegend.prototype.translatePage = function (isCanvas, pagingText, page, pageNumber, legend) {\n var size = (this.isChartControl || this.isAccChartControl) ? (page ? this.getPageHeight(this.pageHeights, page) : 0) : ((this.clipPathHeight) * page);\n if (!isCanvas && (this.isChartControl || this.isAccChartControl)) {\n this.clipRect.setAttribute('height', this.pageHeights[page].toString());\n if (this.isAccChartControl && this.isPaging && !legend.enablePages && this.isVertical) {\n this.clipRect.setAttribute('height', this.legendBounds.height.toString());\n }\n }\n var translate = 'translate(0,-' + size + ')';\n if (!this.isChartControl && !this.isBulletChartControl && !this.isStockChartControl && this.isVertical) {\n var pageX = this.pageXCollections[page * this.maxColumns];\n size = (!this.isRtlEnable) ? pageX - this.legendBounds.x : (this.legendBounds.x + this.maxWidth) - pageX;\n size = size < 0 ? 0 : size; // to avoid small pixel variation\n translate = ((!this.isRtlEnable) ? 'translate(-' : 'translate(') + size + ',0)';\n }\n if (!this.chart.enableCanvas) {\n this.legendTranslateGroup.setAttribute('transform', translate);\n }\n if (!this.chart.enableCanvas && (legend.enablePages || this.isBulletChartControl)) {\n pagingText.textContent = (pageNumber) + '/' + this.totalPages;\n }\n this.currentPage = pageNumber;\n return size;\n };\n /**\n * To change legend pages for chart and accumulation chart\n *\n * @param event\n * @param pageUp\n * @param event\n * @param pageUp\n */\n BaseLegend.prototype.changePage = function (event, pageUp) {\n var legend = this.chart.legendSettings;\n var backwardArrow = document.getElementById(this.legendID + '_pageup');\n var forwardArrow = document.getElementById(this.legendID + '_pagedown');\n var isCanvas = this.isStockChartControl ? false : this.chart.enableCanvas;\n var pageText = (legend.enablePages || this.isBulletChartControl) ?\n document.getElementById(this.legendID + '_pagenumber') : null;\n var page = (legend.enablePages || this.isBulletChartControl) ? parseInt(pageText.textContent.split('/')[0], 10) :\n this.currentPage;\n if (pageUp && page > 1) {\n this.translatePage(isCanvas, pageText, (page - 2), (page - 1), legend);\n }\n else if (!pageUp && page < this.totalPages) {\n this.translatePage(isCanvas, pageText, page, (page + 1), legend);\n }\n if (this.isPaging && !legend.enablePages && !this.isBulletChartControl) {\n // eslint-disable-next-line @typescript-eslint/no-unused-expressions\n this.currentPage === this.totalPages ? this.hideArrow(forwardArrow) : this.showArrow(forwardArrow);\n // eslint-disable-next-line @typescript-eslint/no-unused-expressions\n this.currentPage === 1 ? this.hideArrow(backwardArrow) : this.showArrow(backwardArrow);\n }\n };\n /**\n * To hide the backward and forward arrow\n *\n * @param arrowElement\n */\n BaseLegend.prototype.hideArrow = function (arrowElement) {\n arrowElement.setAttribute('opacity', '0');\n };\n /**\n * To show the backward and forward arrow\n *\n * @param arrowElement\n */\n BaseLegend.prototype.showArrow = function (arrowElement) {\n arrowElement.setAttribute('opacity', '1');\n };\n /**\n * To find legend elements id based on chart or accumulation chart\n *\n * @param option\n * @param prefix\n * @param count\n * @param option\n * @param prefix\n * @param count\n * @param option\n * @param prefix\n * @param count\n * @private\n */\n BaseLegend.prototype.generateId = function (option, prefix, count) {\n if (this.isChartControl || this.isStockChartControl) {\n return prefix + count;\n }\n else {\n return prefix + option.pointIndex;\n }\n };\n /**\n * To show or hide trimmed text tooltip for legend.\n *\n * @param event\n * @returns {void}\n * @private\n */\n BaseLegend.prototype.move = function (event) {\n var _this = this;\n var x = this.chart.mouseX;\n var y = this.chart.mouseY;\n if (event.target.textContent.indexOf('...') > -1) {\n var targetId = event.target.id.split(this.legendID + '_text_');\n if (targetId.length === 2) {\n var index = parseInt(targetId[1], 10);\n var element = this.chart.element;\n if (!isNaN(index)) {\n if (this.chart.isTouch) {\n removeElement(this.chart.element.id + '_EJ2_Legend_Tooltip');\n }\n if (this.isChartControl) {\n showTooltip(this.chart.series[index].name, x, y, element.offsetWidth, element.id + '_EJ2_Legend_Tooltip', getElement(this.chart.element.id + '_Secondary_Element'));\n }\n else {\n showTooltip(this.chart.visibleSeries[0].points[index].x.toString(), x + 10, y + 10, element.offsetWidth, element.id + '_EJ2_Legend_Tooltip', getElement(this.chart.element.id + '_Secondary_Element'));\n }\n }\n }\n }\n else {\n removeElement(this.chart.element.id + '_EJ2_Legend_Tooltip');\n }\n if (this.chart.isTouch) {\n clearTimeout(this.clearTooltip);\n this.clearTooltip = +setTimeout(function () { removeElement(_this.chart.element.id + '_EJ2_Legend_Tooltip'); }, 1000);\n }\n };\n return BaseLegend;\n}());\nexport { BaseLegend };\n/**\n * Class for legend options\n *\n * @private\n */\nvar LegendOptions = /** @class */ (function () {\n function LegendOptions(text, fill, shape, visible, type, url, markerShape, markerVisibility, pointIndex, seriesIndex, dashArray) {\n this.location = { x: 0, y: 0 };\n this.textCollection = [];\n this.text = text;\n this.fill = fill;\n this.shape = shape;\n this.url = url;\n this.visible = visible;\n this.type = type;\n this.markerVisibility = markerVisibility;\n this.markerShape = markerShape;\n this.pointIndex = pointIndex;\n this.seriesIndex = seriesIndex;\n this.dashArray = dashArray;\n }\n return LegendOptions;\n}());\nexport { LegendOptions };\n","//! moment.js locale configuration\n//! locale : Indonesian [id]\n//! author : Mohammad Satrio Utomo : https://github.com/tyok\n//! reference: http://id.wikisource.org/wiki/Pedoman_Umum_Ejaan_Bahasa_Indonesia_yang_Disempurnakan\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var id = moment.defineLocale('id', {\n months: 'Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_Mei_Jun_Jul_Agt_Sep_Okt_Nov_Des'.split('_'),\n weekdays: 'Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu'.split('_'),\n weekdaysShort: 'Min_Sen_Sel_Rab_Kam_Jum_Sab'.split('_'),\n weekdaysMin: 'Mg_Sn_Sl_Rb_Km_Jm_Sb'.split('_'),\n longDateFormat: {\n LT: 'HH.mm',\n LTS: 'HH.mm.ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY [pukul] HH.mm',\n LLLL: 'dddd, D MMMM YYYY [pukul] HH.mm',\n },\n meridiemParse: /pagi|siang|sore|malam/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'pagi') {\n return hour;\n } else if (meridiem === 'siang') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === 'sore' || meridiem === 'malam') {\n return hour + 12;\n }\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours < 11) {\n return 'pagi';\n } else if (hours < 15) {\n return 'siang';\n } else if (hours < 19) {\n return 'sore';\n } else {\n return 'malam';\n }\n },\n calendar: {\n sameDay: '[Hari ini pukul] LT',\n nextDay: '[Besok pukul] LT',\n nextWeek: 'dddd [pukul] LT',\n lastDay: '[Kemarin pukul] LT',\n lastWeek: 'dddd [lalu pukul] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'dalam %s',\n past: '%s yang lalu',\n s: 'beberapa detik',\n ss: '%d detik',\n m: 'semenit',\n mm: '%d menit',\n h: 'sejam',\n hh: '%d jam',\n d: 'sehari',\n dd: '%d hari',\n M: 'sebulan',\n MM: '%d bulan',\n y: 'setahun',\n yy: '%d tahun',\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return id;\n\n})));\n","const dates = {\r\n addDays: function (date, days) {\r\n date.setDate(date.getDate() + days);\r\n return date;\r\n },\r\n\r\n getTradePeriodName: function (startDate, endDate) {\r\n if (Date.parse(startDate) >= Date.parse(endDate)) {\r\n throw new Error(\"'startDate' must be earlier than the 'endDate'. Please correct the dates.\");\r\n }\r\n\r\n startDate = new Date(startDate);\r\n endDate = new Date(endDate)\r\n\r\n var yearSuffix = startDate.getFullYear().ToString().Substring(2);\r\n var numOfDays = this.getDateDiffInDays(startDate, endDate);\r\n var tradeablePeriod = null;\r\n\r\n // potential M, Q, or CAL periods\r\n if (startDate.getFullYear() === endDate.getFullYear()) {\r\n // month\r\n if (numOfDays <= 31 && numOfDays >= 28) {\r\n startDate = this.addDays(startDate, 1);\r\n tradeablePeriod = startDate.toLocaleString('default', { month: 'short' }) + \"-\" + yearSuffix;\r\n }\r\n\r\n //quarter\r\n if (numOfDays <= 92 && numOfDays >= 90) {\r\n startDate = this.addDays(startDate, 1);\r\n\r\n if (this.getQuarter(startDate) === 1) {\r\n tradeablePeriod = \"Q1-\" + yearSuffix;\r\n } else if (this.getQuarter(startDate) === 2) {\r\n tradeablePeriod = \"Q2-\" + yearSuffix;\r\n } else if (this.getQuarter(startDate) === 3) {\r\n tradeablePeriod = \"Q3-\" + yearSuffix;\r\n } else {\r\n tradeablePeriod = \"Q4-\" + yearSuffix;\r\n }\r\n }\r\n\r\n // summer season\r\n if (numOfDays >= 182 && numOfDays <= 183) {\r\n startDate = this.addDays(startDate, 1);\r\n\r\n if (startDate.toLocaleString('default', { month: 'short' }) === \"Apr\") {\r\n tradeablePeriod = \"Sum-\" + yearSuffix;\r\n }\r\n }\r\n\r\n // calendar\r\n if (numOfDays >= 364 && numOfDays <= 366) {\r\n tradeablePeriod = \"Cal-\" + yearSuffix;\r\n }\r\n } else if (startDate.getFullYear() + 1 === endDate.getFullYear()) {\r\n if (numOfDays >= 182 && numOfDays <= 183) {\r\n startDate = this.addDays(startDate, 1);\r\n\r\n if (startDate.toLocaleString('default', { month: 'short' }) === \"Oct\") {\r\n tradeablePeriod = \"Win-\" + yearSuffix;\r\n }\r\n }\r\n }\r\n\r\n return tradeablePeriod;\r\n },\r\n\r\n getDateDiffInDays: function (startDate, endDate) {\r\n var result = Math.round(Math.abs((startDate - endDate) / (24 * 60 * 60 * 1000))) + 1;\r\n return result;\r\n },\r\n getBusinessDatesCount: function (startDate, endDate) {\r\n if (startDate == undefined || endDate == undefined)\r\n return 0;\r\n\r\n let count = 0;\r\n //set dates to have 0 hours,minutes... as otherwise for october it does the matching and due to daylight saving change it doesnt match the last day and we dont calculate it.\r\n startDate.setHours(0, 0, 0, 0);\r\n endDate.setHours(0, 0, 0, 0);\r\n\r\n const curDate = new Date(startDate.getTime());\r\n while (curDate <= endDate) {\r\n const dayOfWeek = curDate.getDay();\r\n if (dayOfWeek !== 0 && dayOfWeek !== 6) count++;\r\n curDate.setDate(curDate.getDate() + 1);\r\n }\r\n return count;\r\n },\r\n getQuarter: function (date) {\r\n date = new Date(date);\r\n\r\n return Math.floor((date.getMonth() + 3) / 3);\r\n }\r\n}\r\n\r\nexport default dates;","//! moment.js locale configuration\n//! locale : Irish or Irish Gaelic [ga]\n//! author : André Silva : https://github.com/askpt\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var months = [\n 'Eanáir',\n 'Feabhra',\n 'Márta',\n 'Aibreán',\n 'Bealtaine',\n 'Meitheamh',\n 'Iúil',\n 'Lúnasa',\n 'Meán Fómhair',\n 'Deireadh Fómhair',\n 'Samhain',\n 'Nollaig',\n ],\n monthsShort = [\n 'Ean',\n 'Feabh',\n 'Márt',\n 'Aib',\n 'Beal',\n 'Meith',\n 'Iúil',\n 'Lún',\n 'M.F.',\n 'D.F.',\n 'Samh',\n 'Noll',\n ],\n weekdays = [\n 'Dé Domhnaigh',\n 'Dé Luain',\n 'Dé Máirt',\n 'Dé Céadaoin',\n 'Déardaoin',\n 'Dé hAoine',\n 'Dé Sathairn',\n ],\n weekdaysShort = ['Domh', 'Luan', 'Máirt', 'Céad', 'Déar', 'Aoine', 'Sath'],\n weekdaysMin = ['Do', 'Lu', 'Má', 'Cé', 'Dé', 'A', 'Sa'];\n\n var ga = moment.defineLocale('ga', {\n months: months,\n monthsShort: monthsShort,\n monthsParseExact: true,\n weekdays: weekdays,\n weekdaysShort: weekdaysShort,\n weekdaysMin: weekdaysMin,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Inniu ag] LT',\n nextDay: '[Amárach ag] LT',\n nextWeek: 'dddd [ag] LT',\n lastDay: '[Inné ag] LT',\n lastWeek: 'dddd [seo caite] [ag] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'i %s',\n past: '%s ó shin',\n s: 'cúpla soicind',\n ss: '%d soicind',\n m: 'nóiméad',\n mm: '%d nóiméad',\n h: 'uair an chloig',\n hh: '%d uair an chloig',\n d: 'lá',\n dd: '%d lá',\n M: 'mÃ',\n MM: '%d mÃonna',\n y: 'bliain',\n yy: '%d bliain',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(d|na|mh)/,\n ordinal: function (number) {\n var output = number === 1 ? 'd' : number % 10 === 2 ? 'na' : 'mh';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return ga;\n\n})));\n","/* eslint-disable jsdoc/require-returns */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/**\n * To import utils\n */\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nvar SvgRenderer = /** @class */ (function () {\n /* End-Properties */\n function SvgRenderer(rootID) {\n //Internal Variables\n this.svgLink = 'http://www.w3.org/2000/svg';\n this.rootId = rootID;\n }\n // method to get the attributes value\n // tslint:disable-next-line:no-any\n SvgRenderer.prototype.getOptionValue = function (options, key) {\n return options[key];\n }; /* tslint:enable */\n /**\n * To create a Html5 SVG element\n *\n * @param {SVGAttributes} options - Options to create SVG\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createSvg = function (options) {\n if (isNullOrUndefined(options.id)) {\n options.id = this.rootId + '_svg';\n }\n this.svgObj = document.getElementById(options.id);\n if (isNullOrUndefined(document.getElementById(options.id))) {\n this.svgObj = document.createElementNS(this.svgLink, 'svg');\n }\n this.svgObj = this.setElementAttributes(options, this.svgObj);\n this.setSVGSize(options.width, options.height);\n return this.svgObj;\n };\n // method to set the height and width for the SVG element\n SvgRenderer.prototype.setSVGSize = function (width, height) {\n var element = document.getElementById(this.rootId);\n var size = !isNullOrUndefined(element) ? element.getBoundingClientRect() : null;\n if (isNullOrUndefined(this.width) || this.width <= 0) {\n this.svgObj.setAttribute('width', width ? width.toString() : size.width.toString());\n }\n else {\n this.svgObj.setAttribute('width', this.width.toString());\n }\n if (isNullOrUndefined(this.height) || this.height <= 0) {\n this.svgObj.setAttribute('height', height ? height.toString() : '450');\n }\n else {\n this.svgObj.setAttribute('height', this.height.toString());\n }\n };\n /**\n * To draw a path\n *\n * @param {PathAttributes} options - Options to draw a path in SVG\n * @returns {Element} It returns a appropriate path\n */\n SvgRenderer.prototype.drawPath = function (options) {\n var path = document.getElementById(options.id);\n if (path === null) {\n path = document.createElementNS(this.svgLink, 'path');\n }\n path = this.setElementAttributes(options, path);\n return path;\n };\n /**\n * To draw a line\n *\n * @param {LineAttributes} options - Options to draw a line in SVG\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawLine = function (options) {\n var line = document.getElementById(options.id);\n if (line === null) {\n line = document.createElementNS(this.svgLink, 'line');\n }\n line = this.setElementAttributes(options, line);\n return line;\n };\n /**\n * To draw a rectangle\n *\n * @param {BaseAttibutes} options - Required options to draw a rectangle in SVG\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawRectangle = function (options) {\n var rectangle = document.getElementById(options.id);\n if (rectangle === null) {\n rectangle = document.createElementNS(this.svgLink, 'rect');\n }\n rectangle = this.setElementAttributes(options, rectangle);\n return rectangle;\n };\n /**\n * To draw a circle\n *\n * @param {CircleAttributes} options - Required options to draw a circle in SVG\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawCircle = function (options) {\n var circle = document.getElementById(options.id);\n if (circle === null) {\n circle = document.createElementNS(this.svgLink, 'circle');\n }\n circle = this.setElementAttributes(options, circle);\n return circle;\n };\n /**\n * To draw a polyline\n *\n * @param {PolylineAttributes} options - Options required to draw a polyline\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawPolyline = function (options) {\n var polyline = document.getElementById(options.id);\n if (polyline === null) {\n polyline = document.createElementNS(this.svgLink, 'polyline');\n }\n polyline = this.setElementAttributes(options, polyline);\n return polyline;\n };\n /**\n * To draw an ellipse\n *\n * @param {EllipseAttributes} options - Options required to draw an ellipse\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawEllipse = function (options) {\n var ellipse = document.getElementById(options.id);\n if (ellipse === null) {\n ellipse = document.createElementNS(this.svgLink, 'ellipse');\n }\n ellipse = this.setElementAttributes(options, ellipse);\n return ellipse;\n };\n /**\n * To draw a polygon\n *\n * @param {PolylineAttributes} options - Options needed to draw a polygon in SVG\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawPolygon = function (options) {\n var polygon = document.getElementById(options.id);\n if (polygon === null) {\n polygon = document.createElementNS(this.svgLink, 'polygon');\n }\n polygon = this.setElementAttributes(options, polygon);\n return polygon;\n };\n /**\n * To draw an image\n *\n * @param {ImageAttributes} options - Required options to draw an image in SVG\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawImage = function (options) {\n var img = document.createElementNS(this.svgLink, 'image');\n img.setAttributeNS(null, 'height', options.height.toString());\n img.setAttributeNS(null, 'width', options.width.toString());\n img.setAttributeNS('http://www.w3.org/1999/xlink', 'href', options.href);\n img.setAttributeNS(null, 'x', options.x.toString());\n img.setAttributeNS(null, 'y', options.y.toString());\n img.setAttributeNS(null, 'id', options.id);\n img.setAttributeNS(null, 'visibility', options.visibility);\n if (!isNullOrUndefined(this.getOptionValue(options, 'clip-path'))) {\n img.setAttributeNS(null, 'clip-path', this.getOptionValue(options, 'clip-path'));\n }\n if (!isNullOrUndefined(options.preserveAspectRatio)) {\n img.setAttributeNS(null, 'preserveAspectRatio', options.preserveAspectRatio);\n }\n return img;\n };\n /**\n * To draw a text\n *\n * @param {TextAttributes} options - Options needed to draw a text in SVG\n * @param {string} label - Label of the text\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createText = function (options, label) {\n var text = document.createElementNS(this.svgLink, 'text');\n text = this.setElementAttributes(options, text);\n if (!isNullOrUndefined(label)) {\n text.textContent = label;\n }\n return text;\n };\n /**\n * To create a tSpan\n *\n * @param {TextAttributes} options - Options to create tSpan\n * @param {string} label - The text content which is to be rendered in the tSpan\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createTSpan = function (options, label) {\n var tSpan = document.createElementNS(this.svgLink, 'tspan');\n tSpan = this.setElementAttributes(options, tSpan);\n if (!isNullOrUndefined(label)) {\n tSpan.textContent = label;\n }\n return tSpan;\n };\n /**\n * To create a title\n *\n * @param {string} text - The text content which is to be rendered in the title\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createTitle = function (text) {\n var title = document.createElementNS(this.svgLink, 'title');\n title.textContent = text;\n return title;\n };\n /**\n * To create defs element in SVG\n *\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createDefs = function () {\n var defs = document.createElementNS(this.svgLink, 'defs');\n return defs;\n };\n /**\n * To create clip path in SVG\n *\n * @param {BaseAttibutes} options - Options needed to create clip path\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createClipPath = function (options) {\n var clipPath = document.createElementNS(this.svgLink, 'clipPath');\n clipPath = this.setElementAttributes(options, clipPath);\n return clipPath;\n };\n /**\n * To create foreign object in SVG\n *\n * @param {BaseAttibutes} options - Options needed to create foreign object\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createForeignObject = function (options) {\n var foreignObject = document.createElementNS(this.svgLink, 'foreignObject');\n foreignObject = this.setElementAttributes(options, foreignObject);\n return foreignObject;\n };\n /**\n * To create group element in SVG\n *\n * @param {BaseAttibutes} options - Options needed to create group\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createGroup = function (options) {\n var group = document.createElementNS(this.svgLink, 'g');\n group = this.setElementAttributes(options, group);\n return group;\n };\n /**\n * To create pattern in SVG\n *\n * @param {PatternAttributes} options - Required options to create pattern in SVG\n * @param {string} element - Specifies the name of the pattern\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.createPattern = function (options, element) {\n var pattern = document.createElementNS(this.svgLink, element);\n pattern = this.setElementAttributes(options, pattern);\n return pattern;\n };\n /**\n * To create radial gradient in SVG\n *\n * @param {string[]} colors - Specifies the colors required to create radial gradient\n * @param {string} name - Specifies the name of the gradient\n * @param {RadialGradient} options - value for radial gradient\n * @returns {string} It returns color name\n */\n SvgRenderer.prototype.createRadialGradient = function (colors, name, options) {\n var colorName;\n if (!isNullOrUndefined(colors[0].colorStop)) {\n var newOptions = {\n 'id': this.rootId + '_' + name + 'radialGradient',\n 'cx': options.cx + '%',\n 'cy': options.cy + '%',\n 'r': options.r + '%',\n 'fx': options.fx + '%',\n 'fy': options.fy + '%'\n };\n this.drawGradient('radialGradient', newOptions, colors);\n colorName = 'url(#' + this.rootId + '_' + name + 'radialGradient)';\n }\n else {\n colorName = colors[0].color.toString();\n }\n return colorName;\n };\n /**\n * To create linear gradient in SVG\n *\n * @param {GradientColor[]} colors - Array of string specifies the values for color\n * @param {string} name - Specifies the name of the gradient\n * @param {LinearGradient} options - Specifies the options for gradient\n * @returns {string} It returns color name\n */\n SvgRenderer.prototype.createLinearGradient = function (colors, name, options) {\n var colorName;\n if (!isNullOrUndefined(colors[0].colorStop)) {\n var newOptions = {\n 'id': this.rootId + '_' + name + 'linearGradient',\n 'x1': options.x1 + '%',\n 'y1': options.y1 + '%',\n 'x2': options.x2 + '%',\n 'y2': options.y2 + '%'\n };\n this.drawGradient('linearGradient', newOptions, colors);\n colorName = 'url(#' + this.rootId + '_' + name + 'linearGradient)';\n }\n else {\n colorName = colors[0].color.toString();\n }\n return colorName;\n };\n /**\n * To render the gradient element in SVG\n *\n * @param {string} gradientType - Specifies the type of the gradient\n * @param {RadialGradient | LinearGradient} options - Options required to render a gradient\n * @param {string[]} colors - Array of string specifies the values for color\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawGradient = function (gradientType, options, colors) {\n var defs = this.createDefs();\n var gradient = document.createElementNS(this.svgLink, gradientType);\n gradient = this.setElementAttributes(options, gradient);\n for (var i = 0; i < colors.length; i++) {\n var stop_1 = document.createElementNS(this.svgLink, 'stop');\n stop_1.setAttribute('offset', colors[i].colorStop);\n stop_1.setAttribute('stop-color', colors[i].color);\n stop_1.setAttribute('stop-opacity', colors[i].opacity ? (colors[i].opacity) : '1');\n if (!isNullOrUndefined(colors[i].style)) {\n stop_1.style.cssText = colors[i].style;\n }\n gradient.appendChild(stop_1);\n }\n defs.appendChild(gradient);\n return defs;\n };\n /**\n * To render a clip path\n *\n * @param {BaseAttibutes} options - Options required to render a clip path\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawClipPath = function (options) {\n var defs = this.createDefs();\n var clipPath = this.createClipPath({ 'id': options.id });\n options.id = options.id + '_Rect';\n var rect = this.drawRectangle(options);\n clipPath.appendChild(rect);\n defs.appendChild(clipPath);\n return defs;\n };\n /**\n * To create circular clip path in SVG\n *\n * @param {CircleAttributes} options - Options required to create circular clip path\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.drawCircularClipPath = function (options) {\n var defs = this.createDefs();\n var clipPath = this.createClipPath({ 'id': options.id });\n options.id = options.id + '_Circle';\n var circle = this.drawCircle(options);\n clipPath.appendChild(circle);\n defs.appendChild(clipPath);\n return defs;\n };\n /**\n * To set the attributes to the element\n *\n * @param {SVGCanvasAttributes} options - Attributes to set for the element\n * @param {Element} element - The element to which the attributes need to be set\n * @returns {Element} It returns a appropriate element\n */\n SvgRenderer.prototype.setElementAttributes = function (options, element) {\n var keys = Object.keys(options);\n for (var i = 0; i < keys.length; i++) {\n if (keys[i] === 'style') {\n element.style.cssText = options[keys[i]];\n }\n else {\n element.setAttribute(keys[i], options[keys[i]]);\n }\n }\n return element;\n };\n /**\n * To create a Html5 canvas element\n * Dummy method for using canvas/svg render in the same variable name in chart control\n */\n SvgRenderer.prototype.createCanvas = function () {\n return null;\n };\n return SvgRenderer;\n}());\nexport { SvgRenderer };\n","/* eslint-disable no-case-declarations */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/**\n * To import utils.\n */\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\n/**\n * @private\n */\nvar CanvasRenderer = /** @class */ (function () {\n /* End-Properties */\n function CanvasRenderer(rootID) {\n this.rootId = rootID;\n }\n // method to get the attributes value\n // tslint:disable-next-line:no-any\n CanvasRenderer.prototype.getOptionValue = function (options, key) {\n return options[key];\n };\n /* tslint:enable */\n /**\n * To create a Html5 canvas element\n *\n * @param {BaseAttibutes} options - Options to create canvas\n * @returns {HTMLCanvasElement} Creating a canvas\n */\n CanvasRenderer.prototype.createCanvas = function (options) {\n var canvasObj = document.createElement('canvas');\n canvasObj.setAttribute('id', this.rootId + '_canvas');\n this.ctx = canvasObj.getContext('2d');\n this.canvasObj = canvasObj;\n this.setCanvasSize(options.width, options.height);\n return this.canvasObj;\n };\n /**\n * To set the width and height for the Html5 canvas element\n *\n * @param {number} width - width of the canvas\n * @param {number} height - height of the canvas\n * @returns {void} Setting canvas size\n */\n CanvasRenderer.prototype.setCanvasSize = function (width, height) {\n var element = document.getElementById(this.rootId);\n var size = !isNullOrUndefined(element) ? element.getBoundingClientRect() : null;\n if (isNullOrUndefined(this.width)) {\n this.canvasObj.setAttribute('width', width ? width.toString() : size.width.toString());\n }\n else {\n this.canvasObj.setAttribute('width', this.width.toString());\n }\n if (isNullOrUndefined(this.height)) {\n this.canvasObj.setAttribute('height', height ? height.toString() : '450');\n }\n else {\n this.canvasObj.setAttribute('height', this.height.toString());\n }\n };\n // To set the values to the attributes\n CanvasRenderer.prototype.setAttributes = function (options) {\n this.ctx.lineWidth = this.getOptionValue(options, 'stroke-width');\n var dashArray = this.getOptionValue(options, 'stroke-dasharray');\n if (!isNullOrUndefined(dashArray)) {\n var dashArrayString = dashArray.split(',');\n this.ctx.setLineDash([parseInt(dashArrayString[0], 10), parseInt(dashArrayString[1], 10)]);\n }\n this.ctx.strokeStyle = this.getOptionValue(options, 'stroke');\n };\n /**\n * To draw a line\n *\n * @param {LineAttributes} options - required options to draw a line on the canvas\n * @returns {void} To draw a line\n */\n CanvasRenderer.prototype.drawLine = function (options) {\n this.ctx.save();\n this.ctx.beginPath();\n this.ctx.lineWidth = this.getOptionValue(options, 'stroke-width');\n this.ctx.strokeStyle = options.stroke;\n this.ctx.moveTo(options.x1, options.y1);\n this.ctx.lineTo(options.x2, options.y2);\n this.ctx.stroke();\n this.ctx.restore();\n };\n /**\n * To draw a rectangle\n *\n * @param {RectAttributes} options - required options to draw a rectangle on the canvas.\n * @param {Int32Array} canvasTranslate TO get a translate value of canvas.\n * @returns {void} To draw rectangle.\n */\n CanvasRenderer.prototype.drawRectangle = function (options, canvasTranslate) {\n var canvasCtx = this.ctx;\n var cornerRadius = options.rx;\n this.ctx.save();\n this.ctx.beginPath();\n if (canvasTranslate) {\n this.ctx.translate(canvasTranslate[0], canvasTranslate[1]);\n }\n this.ctx.globalAlpha = this.getOptionValue(options, 'opacity');\n this.setAttributes(options);\n this.ctx.rect(options.x, options.y, options.width, options.height);\n if (cornerRadius !== null && cornerRadius >= 0) {\n this.drawCornerRadius(options);\n }\n else {\n if (options.fill === 'none') {\n options.fill = 'transparent';\n }\n this.ctx.fillStyle = options.fill;\n this.ctx.fillRect(options.x, options.y, options.width, options.height);\n this.ctx.stroke();\n }\n this.ctx.restore();\n this.ctx = canvasCtx;\n return (this.canvasObj);\n };\n // To draw the corner of a rectangle\n CanvasRenderer.prototype.drawCornerRadius = function (options) {\n var cornerRadius = options.rx;\n var x = options.x;\n var y = options.y;\n var width = options.width;\n var height = options.height;\n if (options.fill === 'none') {\n options.fill = 'transparent';\n }\n this.ctx.fillStyle = options.fill;\n if (width < 2 * cornerRadius) {\n cornerRadius = width / 2;\n }\n if (height < 2 * cornerRadius) {\n cornerRadius = height / 2;\n }\n this.ctx.beginPath();\n this.ctx.moveTo(x + width - cornerRadius, y);\n this.ctx.arcTo(x + width, y, x + width, y + height, cornerRadius);\n this.ctx.arcTo(x + width, y + height, x, y + height, cornerRadius);\n this.ctx.arcTo(x, y + height, x, y, cornerRadius);\n this.ctx.arcTo(x, y, x + width, y, cornerRadius);\n this.ctx.closePath();\n this.ctx.fill();\n this.ctx.stroke();\n };\n /**\n * To draw a path on the canvas\n *\n * @param {PathAttributes} options - options needed to draw path.\n * @param {Int32Array} canvasTranslate - Array of numbers to translate the canvas.\n * @returns {Element} To draw a path.\n */\n CanvasRenderer.prototype.drawPath = function (options, canvasTranslate) {\n var path = options.d;\n var dataSplit = path.split(' ');\n var borderWidth = this.getOptionValue(options, 'stroke-width');\n var canvasCtx = this.ctx;\n var flag = true;\n this.ctx.save();\n this.ctx.beginPath();\n if (canvasTranslate) {\n this.ctx.translate(canvasTranslate[0], canvasTranslate[1]);\n }\n this.ctx.globalAlpha = options.opacity ? options.opacity : this.getOptionValue(options, 'fill-opacity');\n this.setAttributes(options);\n for (var i = 0; i < dataSplit.length; i = i + 3) {\n var x1 = parseFloat(dataSplit[i + 1]);\n var y1 = parseFloat(dataSplit[i + 2]);\n switch (dataSplit[i]) {\n case 'M':\n if (!options.innerR && !options.cx) {\n this.ctx.moveTo(x1, y1);\n }\n break;\n case 'L':\n if (!options.innerR) {\n this.ctx.lineTo(x1, y1);\n }\n break;\n case 'Q':\n var q1 = parseFloat(dataSplit[i + 3]);\n var q2 = parseFloat(dataSplit[i + 4]);\n this.ctx.quadraticCurveTo(x1, y1, q1, q2);\n i = i + 2;\n break;\n case 'C':\n var c1 = parseFloat(dataSplit[i + 3]);\n var c2 = parseFloat(dataSplit[i + 4]);\n var c3 = parseFloat(dataSplit[i + 5]);\n var c4 = parseFloat(dataSplit[i + 6]);\n this.ctx.bezierCurveTo(x1, y1, c1, c2, c3, c4);\n i = i + 4;\n break;\n case 'A':\n if (!options.innerR) {\n if (options.cx) {\n this.ctx.arc(options.cx, options.cy, options.radius, 0, 2 * Math.PI, options.counterClockWise);\n }\n else {\n this.ctx.moveTo(options.x, options.y);\n this.ctx.arc(options.x, options.y, options.radius, options.start, options.end, options.counterClockWise);\n this.ctx.lineTo(options.x, options.y);\n }\n }\n else if (flag) {\n this.ctx.arc(options.x, options.y, options.radius, options.start, options.end, options.counterClockWise);\n this.ctx.arc(options.x, options.y, options.innerR, options.end, options.start, !options.counterClockWise);\n flag = false;\n }\n i = i + 5;\n break;\n case 'z':\n case 'Z':\n this.ctx.closePath();\n //since for loop is incremented by 3, to get next value after 'z' i is decremented for 2.\n i = i - 2;\n break;\n }\n }\n if (options.fill !== 'none' && options.fill !== undefined) {\n this.ctx.fillStyle = options.fill;\n this.ctx.fill();\n }\n if (borderWidth > 0) {\n this.ctx.stroke();\n }\n this.ctx.restore();\n this.ctx = canvasCtx;\n return this.canvasObj;\n };\n /**\n * To draw a text\n *\n * @param {TextAttributes} options - options required to draw text\n * @param {string} label - Specifies the text which has to be drawn on the canvas\n * @param {number} transX - Specifies the text of translate X\n * @param {number} transY - Specifies the text of translate Y\n * @param {number} dy - Specifies the text of translate dy\n * @param {boolean} isTSpan - Specifies the boolean value of span value\n * @returns {void}\n */\n CanvasRenderer.prototype.createText = function (options, label, transX, transY, dy, isTSpan) {\n var fontWeight = this.getOptionValue(options, 'font-weight');\n if (!isNullOrUndefined(fontWeight) && fontWeight.toLowerCase() === 'regular') {\n fontWeight = 'normal';\n }\n var fontSize = this.getOptionValue(options, 'font-size');\n var fontFamily = this.getOptionValue(options, 'font-family');\n var fontStyle = this.getOptionValue(options, 'font-style').toLowerCase();\n var font = (fontStyle + ' ' + fontWeight + ' ' + fontSize + ' ' + fontFamily);\n var anchor = this.getOptionValue(options, 'text-anchor');\n var opacity = options.opacity !== undefined ? options.opacity : 1;\n if (anchor === 'middle') {\n anchor = 'center';\n }\n this.ctx.save();\n this.ctx.fillStyle = options.fill;\n this.ctx.font = font;\n this.ctx.textAlign = anchor;\n this.ctx.globalAlpha = opacity;\n if (options.baseline) {\n this.ctx.textBaseline = options.baseline;\n }\n if (!isTSpan) {\n var txtlngth = 0;\n this.ctx.translate(options.x + (txtlngth / 2) + (transX ? transX : 0), options.y + (transY ? transY : 0));\n this.ctx.rotate(options.labelRotation * Math.PI / 180);\n }\n this.ctx.fillText(label, isTSpan ? options.x : 0, isTSpan ? dy : 0);\n this.ctx.restore();\n return this.canvasObj;\n };\n /**\n * To draw circle on the canvas\n *\n * @param {CircleAttributes} options - required options to draw the circle\n * @param {Int32Array} canvasTranslate Translate value of canvas\n * @returns {void}\n */\n CanvasRenderer.prototype.drawCircle = function (options, canvasTranslate) {\n var canvasCtx = this.ctx;\n this.ctx.save();\n this.ctx.beginPath();\n this.ctx.arc(options.cx, options.cy, options.r, 0, 2 * Math.PI);\n this.ctx.fillStyle = options.fill;\n this.ctx.globalAlpha = options.opacity;\n this.ctx.fill();\n if (canvasTranslate) {\n this.ctx.translate(canvasTranslate[0], canvasTranslate[1]);\n }\n this.setAttributes(options);\n this.ctx.stroke();\n this.ctx.restore();\n this.ctx = canvasCtx;\n return this.canvasObj;\n };\n /**\n * To draw polyline\n *\n * @param {PolylineAttributes} options - options needed to draw polyline\n * @returns {void}\n */\n CanvasRenderer.prototype.drawPolyline = function (options) {\n this.ctx.save();\n this.ctx.beginPath();\n var points = options.points.split(' ');\n for (var i = 0; i < points.length - 1; i++) {\n var point = points[i].split(',');\n var x = parseFloat(point[0]);\n var y = parseFloat(point[1]);\n if (i === 0) {\n this.ctx.moveTo(x, y);\n }\n else {\n this.ctx.lineTo(x, y);\n }\n }\n this.ctx.lineWidth = this.getOptionValue(options, 'stroke-width');\n this.ctx.strokeStyle = options.stroke;\n this.ctx.stroke();\n this.ctx.restore();\n };\n /**\n * To draw an ellipse on the canvas\n *\n * @param {EllipseAttributes} options - options needed to draw ellipse\n * @param {Int32Array} canvasTranslate Translate value of canvas\n * @returns {void}\n */\n CanvasRenderer.prototype.drawEllipse = function (options, canvasTranslate) {\n var canvasCtx = this.ctx;\n var circumference = Math.max(options.rx, options.ry);\n var scaleX = options.rx / circumference;\n var scaleY = options.ry / circumference;\n this.ctx.save();\n this.ctx.beginPath();\n this.ctx.translate(options.cx, options.cy);\n if (canvasTranslate) {\n this.ctx.translate(canvasTranslate[0], canvasTranslate[1]);\n }\n this.ctx.save();\n this.ctx.scale(scaleX, scaleY);\n this.ctx.arc(0, 0, circumference, 0, 2 * Math.PI, false);\n this.ctx.fillStyle = options.fill;\n this.ctx.fill();\n this.ctx.restore();\n this.ctx.lineWidth = this.getOptionValue(options, 'stroke-width');\n this.ctx.strokeStyle = options.stroke;\n this.ctx.stroke();\n this.ctx.restore();\n this.ctx = canvasCtx;\n };\n /**\n * To draw an image\n *\n * @param {ImageAttributes} options - options required to draw an image on the canvas\n * @returns {void}\n */\n CanvasRenderer.prototype.drawImage = function (options) {\n this.ctx.save();\n var imageObj = new Image();\n if (!isNullOrUndefined(options.href)) {\n imageObj.src = options.href;\n this.ctx.drawImage(imageObj, options.x, options.y, options.width, options.height);\n }\n this.ctx.restore();\n };\n /**\n * To create a linear gradient\n *\n * @param {string[]} colors - Specifies the colors required to create linear gradient\n * @returns {string} It returns color\n */\n CanvasRenderer.prototype.createLinearGradient = function (colors) {\n var myGradient;\n if (!isNullOrUndefined(colors[0].colorStop)) {\n myGradient = this.ctx.createLinearGradient(0, 0, 0, this.canvasObj.height);\n }\n var color = this.setGradientValues(colors, myGradient);\n return color;\n };\n /**\n * To create a radial gradient\n *\n * @param {string[]} colors - Specifies the colors required to create linear gradient\n * @returns {string} It returns gradient color\n */\n CanvasRenderer.prototype.createRadialGradient = function (colors) {\n var myGradient;\n if (!isNullOrUndefined(colors[0].colorStop)) {\n myGradient = this.ctx.createRadialGradient(0, 0, 0, 0, 0, this.canvasObj.height);\n }\n var colorName = this.setGradientValues(colors, myGradient);\n return colorName;\n };\n // To set the gradient values\n CanvasRenderer.prototype.setGradientValues = function (colors, myGradient) {\n var colorName;\n if (!isNullOrUndefined(colors[0].colorStop)) {\n for (var i = 0; i <= colors.length - 1; i++) {\n var color = colors[i].color;\n var newColorStop = (colors[i].colorStop).slice(0, -1);\n var stopColor = parseInt(newColorStop, 10) / 100;\n myGradient.addColorStop(stopColor, color);\n }\n colorName = myGradient.toString();\n }\n else {\n colorName = colors[0].color.toString();\n }\n return colorName;\n };\n /**\n * To set the attributes to the element\n *\n * @param {SVGCanvasAttributes} options - Attributes to set for the element\n * @param {HTMLElement} element - The element to which the attributes need to be set\n * @returns {HTMLElement} It returns null value\n */\n CanvasRenderer.prototype.setElementAttributes = function (options, element) {\n var keys = Object.keys(options);\n var values = Object.keys(options).map(function (key) { return options[key]; });\n for (var i = 0; i < keys.length; i++) {\n element.setAttribute(keys[i], values[i]);\n }\n return null;\n };\n /**\n * To update the values of the canvas element attributes\n *\n * @param {SVGCanvasAttributes} options - Specifies the colors required to create gradient\n * @returns {void}\n */\n CanvasRenderer.prototype.updateCanvasAttributes = function (options) {\n this.setElementAttributes(options, this.canvasObj);\n var ctx = this.ctx;\n if (!isNullOrUndefined(this.dataUrl)) {\n var img_1 = new Image;\n img_1.onload = function () {\n ctx.drawImage(img_1, 0, 0);\n };\n img_1.src = this.dataUrl;\n }\n };\n /**\n * This method clears the given rectangle region\n *\n * @param {Rect} rect The rect parameter as passed\n */\n CanvasRenderer.prototype.clearRect = function (rect) {\n this.ctx.restore();\n this.ctx.clearRect(rect.x, rect.y, rect.width, rect.height);\n };\n /**\n * For canvas rendering in chart\n * Dummy method for using canvas/svg render in the same variable name in chart control\n */\n CanvasRenderer.prototype.createGroup = function () {\n return null;\n };\n /**\n * To render a clip path\n *\n * Dummy method for using canvas/svg render in the same variable name in chart control\n */\n CanvasRenderer.prototype.drawClipPath = function () {\n return null;\n };\n /**\n * To render a Circular clip path\n *\n * Dummy method for using canvas/svg render in the same variable name in chart control\n */\n CanvasRenderer.prototype.drawCircularClipPath = function () {\n return null;\n };\n /**\n * Clip method to perform clip in canvas mode\n *\n * @param {BaseAttibutes} options The canvas clip of options\n */\n CanvasRenderer.prototype.canvasClip = function (options) {\n this.ctx.save();\n this.ctx.fillStyle = 'transparent';\n this.ctx.rect(options.x, options.y, options.width, options.height);\n this.ctx.fill();\n this.ctx.clip();\n };\n /**\n * Tp restore the canvas\n */\n CanvasRenderer.prototype.canvasRestore = function () {\n this.ctx.restore();\n };\n /**\n * To draw a polygon\n * Dummy method for using canvas/svg render in the same variable name in chart control\n */\n CanvasRenderer.prototype.drawPolygon = function () {\n return null;\n };\n /**\n * To create defs element in SVG\n * Dummy method for using canvas/svg render in the same variable name in chart control\n *\n * @returns {Element} It returns null\n */\n CanvasRenderer.prototype.createDefs = function () {\n return null;\n };\n /**\n * To create clip path in SVG\n * Dummy method for using canvas/svg render in the same variable name in chart control\n */\n CanvasRenderer.prototype.createClipPath = function () {\n return null;\n };\n /**\n * To create a Html5 SVG element\n * Dummy method for using canvas/svg render in the same variable name in chart control\n *\n * @returns {Element} It returns null\n */\n CanvasRenderer.prototype.createSvg = function () {\n return null;\n };\n return CanvasRenderer;\n}());\nexport { CanvasRenderer };\n","/** @private */\nexport function getTooltipThemeColor(theme) {\n var style;\n switch (theme) {\n case 'Highcontrast':\n case 'HighContrast':\n style = {\n tooltipFill: '#ffffff',\n tooltipBoldLabel: '#000000',\n tooltipLightLabel: '#000000',\n tooltipHeaderLine: '#969696',\n textStyle: { fontFamily: 'Segoe UI', color: '#000000' }\n };\n break;\n case 'MaterialDark':\n case 'FabricDark':\n case 'BootstrapDark':\n style = {\n tooltipFill: theme === 'MaterialDark' ? '#F4F4F4' : theme === 'FabricDark' ? '#A19F9D' : '#F0F0F0',\n tooltipBoldLabel: theme === 'MaterialDark' ? 'rgba(18, 18, 18, 1)' : theme === 'FabricDark' ? '#DADADA' : '#1A1A1A',\n tooltipLightLabel: theme === 'MaterialDark' ? 'rgba(18, 18, 18, 1)' : theme === 'FabricDark' ? '#DADADA' : '#1A1A1A',\n tooltipHeaderLine: '#9A9A9A',\n textStyle: theme === 'MaterialDark' ? { fontFamily: 'Roboto', color: 'rgba(18, 18, 18, 1)' } : theme === 'FabricDark' ? { fontFamily: 'Segoe UI', color: '#DADADA' } : { fontFamily: 'Helvetica', color: '#1A1A1A' }\n };\n break;\n case 'Bootstrap4':\n style = {\n tooltipFill: '#212529',\n tooltipBoldLabel: '#F9FAFB',\n tooltipLightLabel: '#F9FAFB',\n tooltipHeaderLine: 'rgba(255, 255, 255, 0.2)',\n textStyle: { fontFamily: 'Helvetica', color: '#F9FAFB' }\n };\n break;\n case 'Tailwind':\n style = {\n tooltipFill: '#111827',\n tooltipBoldLabel: '#F9FAFB',\n tooltipLightLabel: '#F9FAFB',\n tooltipHeaderLine: '#6B7280',\n textStyle: { fontFamily: 'Inter', color: '#F9FAFB' }\n };\n break;\n case 'TailwindDark':\n style = {\n tooltipFill: '#E9ECEF',\n tooltipBoldLabel: '#1F2937',\n tooltipLightLabel: '#1F2937',\n tooltipHeaderLine: '#9CA3AF',\n textStyle: { fontFamily: 'Inter', color: '#1F2937' }\n };\n break;\n case 'Bootstrap5':\n style = {\n tooltipFill: '#212529',\n tooltipBoldLabel: '#F9FAFB',\n tooltipLightLabel: '#F9FAFB',\n tooltipHeaderLine: '#9CA3AF',\n textStyle: { fontFamily: 'Helvetica', color: '#F9FAFB' }\n };\n break;\n case 'Bootstrap5Dark':\n style = {\n tooltipFill: '#E9ECEF',\n tooltipBoldLabel: '#212529',\n tooltipLightLabel: '#212529',\n tooltipHeaderLine: '#ADB5BD',\n textStyle: { fontFamily: 'Helvetica', color: '#212529' }\n };\n break;\n case 'Fluent':\n style = {\n tooltipFill: '#FFFFFF',\n tooltipBoldLabel: '#323130',\n tooltipLightLabel: '#323130',\n tooltipHeaderLine: '#D2D0CE',\n textStyle: { fontFamily: 'Segoe UI', color: '#323130' }\n };\n break;\n case 'FluentDark':\n style = {\n tooltipFill: '#323130',\n tooltipBoldLabel: '#F3F2F2',\n tooltipLightLabel: '#F3F2F1',\n tooltipHeaderLine: '#3B3A39',\n textStyle: { fontFamily: 'Segoe UI', color: '#F3F2F1' }\n };\n break;\n case 'Material3':\n style = {\n tooltipFill: '#313033',\n tooltipBoldLabel: '#F4EFF4',\n tooltipLightLabel: '#F4EFF4',\n tooltipHeaderLine: '#F4EFF4',\n textStyle: { fontFamily: 'Roboto', color: '#F4EFF4' }\n };\n break;\n case 'Material3Dark':\n style = {\n tooltipFill: '#E6E1E5',\n tooltipBoldLabel: '#313033',\n tooltipLightLabel: '#313033',\n tooltipHeaderLine: '#313033',\n textStyle: { fontFamily: 'Roboto', color: '#313033' }\n };\n break;\n default:\n style = {\n tooltipFill: theme === 'Material' ? '#000816' : theme === 'Fabric' ? '#FFFFFF' : '#212529',\n tooltipBoldLabel: theme === 'Material' ? 'rgba(249, 250, 251, 1)' : theme === 'Fabric' ? '#333333' : '#F9FAFB',\n tooltipLightLabel: theme === 'Material' ? 'rgba(249, 250, 251, 1)' : theme === 'Fabric' ? '#333333' : '#F9FAFB',\n tooltipHeaderLine: theme === 'Fabric' ? '#D2D0CE' : '#ffffff',\n textStyle: theme === 'Material' ? { fontFamily: 'Roboto', color: 'rgba(249, 250, 251, 1)' } : theme === 'Fabric' ? { fontFamily: 'Segoe UI', color: '#333333' } : { fontFamily: 'Helvetica', color: '#F9FAFB' }\n };\n break;\n }\n return style;\n}\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { SvgRenderer } from '../svg-render/index';\nimport { createElement, remove, merge } from '@syncfusion/ej2-base';\n/**\n * Function to measure the height and width of the text.\n *\n * @private\n * @param {string} text To get a text\n * @param {FontModel} font To get a font of the text\n * @returns {Size} measureText\n */\nexport function measureText(text, font, themeFontStyle) {\n var breakText = text || ''; // For avoid NuLL value\n var htmlObject = document.getElementById('chartmeasuretext');\n if (htmlObject === null) {\n htmlObject = createElement('text', { id: 'chartmeasuretext' });\n document.body.appendChild(htmlObject);\n }\n if (typeof (text) === 'string' && (text.indexOf('<') > -1 || text.indexOf('>') > -1)) {\n var textArray = text.split(' ');\n for (var i = 0; i < textArray.length; i++) {\n if (textArray[i].indexOf('<br/>') === -1) {\n textArray[i] = textArray[i].replace(/[<>]/g, '&');\n }\n }\n text = textArray.join(' ');\n }\n htmlObject.innerHTML = (breakText.indexOf('<br>') > -1 || breakText.indexOf('<br/>') > -1) ? breakText : text;\n htmlObject.style.position = 'fixed';\n htmlObject.style.fontSize = font.size;\n htmlObject.style.fontWeight = font.fontWeight;\n htmlObject.style.fontStyle = font.fontStyle;\n htmlObject.style.fontFamily = font.fontFamily || themeFontStyle.fontFamily;\n htmlObject.style.visibility = 'hidden';\n htmlObject.style.top = '-100';\n htmlObject.style.left = '0';\n htmlObject.style.whiteSpace = 'nowrap';\n // For bootstrap line height issue\n htmlObject.style.lineHeight = 'normal';\n return new Size(htmlObject.clientWidth, htmlObject.clientHeight);\n}\n/** @private */\nexport function withInAreaBounds(x, y, areaBounds, width, height) {\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n return (x >= areaBounds.x - width && x <= areaBounds.x + areaBounds.width + width && y >= areaBounds.y - height\n && y <= areaBounds.y + areaBounds.height + height);\n}\n/** @private */\nexport function findDirection(rX, rY, rect, arrowLocation, arrowPadding, top, bottom, left, tipX, tipY, controlName) {\n if (controlName === void 0) { controlName = ''; }\n var direction = '';\n var startX = rect.x;\n var startY = rect.y;\n var width = rect.x + rect.width;\n var height = rect.y + rect.height;\n if (top) {\n direction = direction.concat('M' + ' ' + (startX) + ' ' + (startY + rY) + ' Q ' + startX + ' '\n + startY + ' ' + (startX + rX) + ' ' + startY + ' ' +\n ' L' + ' ' + (width - rX) + ' ' + (startY) + ' Q ' + width + ' '\n + startY + ' ' + (width) + ' ' + (startY + rY));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (height - rY) + ' Q ' + width + ' '\n + (height) + ' ' + (width - rX) + ' ' + (height));\n if (arrowPadding !== 0) {\n if (controlName === 'RangeNavigator') {\n if ((arrowLocation.x - arrowPadding) > width / 2) {\n direction = direction.concat(' L' + ' ' + (arrowLocation.x + arrowPadding) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (tipX + arrowPadding) + ' ' + (height + arrowPadding)\n + ' L' + ' ' + (arrowLocation.x) + ' ' + height);\n }\n else {\n direction = direction.concat(' L' + ' ' + (arrowLocation.x) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (tipX - arrowPadding) + ' ' + (height + arrowPadding)\n + ' L' + ' ' + (arrowLocation.x - arrowPadding) + ' ' + height);\n }\n }\n else {\n direction = direction.concat(' L' + ' ' + (arrowLocation.x + arrowPadding) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (tipX) + ' ' + (height + arrowPadding)\n + ' L' + ' ' + (arrowLocation.x - arrowPadding) + ' ' + height);\n }\n }\n if ((arrowLocation.x - arrowPadding) > startX) {\n direction = direction.concat(' L' + ' ' + (startX + rX) + ' ' + height + ' Q ' + startX + ' '\n + height + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else {\n if (arrowPadding === 0) {\n direction = direction.concat(' L' + ' ' + (startX + rX) + ' ' + height + ' Q ' + startX + ' '\n + height + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else {\n direction = direction.concat(' L' + ' ' + (startX) + ' ' + (height + rY) + ' z');\n }\n }\n }\n else if (bottom) {\n direction = direction.concat('M' + ' ' + (startX) + ' ' + (startY + rY) + ' Q ' + startX + ' '\n + (startY) + ' ' + (startX + rX) + ' ' + (startY) + ' L' + ' ' + (arrowLocation.x - arrowPadding) + ' ' + (startY));\n direction = direction.concat(' L' + ' ' + (tipX) + ' ' + (arrowLocation.y));\n direction = direction.concat(' L' + ' ' + (arrowLocation.x + arrowPadding) + ' ' + (startY));\n direction = direction.concat(' L' + ' ' + (width - rX) + ' ' + (startY)\n + ' Q ' + (width) + ' ' + (startY) + ' ' + (width) + ' ' + (startY + rY));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (height - rY) + ' Q ' + (width) + ' '\n + (height) + ' ' + (width - rX) + ' ' + (height) +\n ' L' + ' ' + (startX + rX) + ' ' + (height) + ' Q ' + (startX) + ' '\n + (height) + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else if (left) {\n direction = direction.concat('M' + ' ' + (startX) + ' ' + (startY + rY) + ' Q ' + startX + ' '\n + (startY) + ' ' + (startX + rX) + ' ' + (startY));\n direction = direction.concat(' L' + ' ' + (width - rX) + ' ' + (startY) + ' Q ' + (width) + ' '\n + (startY) + ' ' + (width) + ' ' + ((controlName === 'RangeNavigator' ? 0 : (startY + rY)) + ' L' + ' ' + (width) + ' ' + (controlName === 'RangeNavigator' ? 0 : (arrowLocation.y - arrowPadding))));\n direction = (controlName === 'RangeNavigator') ? direction.concat(' L' + ' ' + (width + arrowPadding) + ' ' + 0) :\n direction.concat(' L' + ' ' + (width + arrowPadding) + ' ' + (tipY));\n direction = (controlName === 'RangeNavigator') ? direction.concat(' L' + ' ' + (width) + ' ' + (arrowLocation.y - rY)) :\n direction.concat(' L' + ' ' + (width) + ' ' + (arrowLocation.y + arrowPadding));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (height - rY) + ' Q ' + width + ' ' + (height) + ' ' + (width - rX) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (startX + rX) + ' ' + (height) + ' Q ' + startX + ' '\n + (height) + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else {\n direction = direction.concat('M' + ' ' + (startX + rX) + ' ' + (startY) + ' Q ' + (startX) + ' '\n + (startY) + ' ' + (startX) + ' ' + ((controlName === 'RangeNavigator' ? 0 : (startY + rY)) + ' L' + ' ' + (startX) + ' ' + (controlName === 'RangeNavigator' ? 0 : (arrowLocation.y - arrowPadding))));\n direction = (controlName === 'RangeNavigator') ? direction.concat(' L' + ' ' + (startX - arrowPadding) + ' ' + 0) :\n direction.concat(' L' + ' ' + (startX - arrowPadding) + ' ' + (tipY));\n direction = (controlName === 'RangeNavigator') ? direction.concat(' L' + ' ' + (startX) + ' ' + (arrowLocation.y - rY)) :\n direction.concat(' L' + ' ' + (startX) + ' ' + (arrowLocation.y + arrowPadding));\n direction = direction.concat(' L' + ' ' + (startX) + ' ' + (height - rY) + ' Q ' + startX + ' '\n + (height) + ' ' + (startX + rX) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (width - rX) + ' ' + (height) + ' Q ' + width + ' '\n + (height) + ' ' + (width) + ' ' + (height - rY) +\n ' L' + ' ' + (width) + ' ' + (startY + rY) + ' Q ' + width + ' '\n + (startY) + ' ' + (width - rX) + ' ' + (startY) + ' z');\n }\n return direction;\n}\n/** @private */\nvar Size = /** @class */ (function () {\n function Size(width, height) {\n this.width = width;\n this.height = height;\n }\n return Size;\n}());\nexport { Size };\n/** @private */\nvar Rect = /** @class */ (function () {\n function Rect(x, y, width, height) {\n this.x = x;\n this.y = y;\n this.width = width;\n this.height = height;\n }\n return Rect;\n}());\nexport { Rect };\nvar Side = /** @class */ (function () {\n function Side(bottom, right) {\n this.isRight = right;\n this.isBottom = bottom;\n }\n return Side;\n}());\nexport { Side };\n/** @private */\nvar CustomizeOption = /** @class */ (function () {\n function CustomizeOption(id) {\n this.id = id;\n }\n return CustomizeOption;\n}());\nexport { CustomizeOption };\n/** @private */\nvar TextOption = /** @class */ (function (_super) {\n __extends(TextOption, _super);\n function TextOption(id, x, y, anchor, text, transform, baseLine, labelRotation) {\n if (transform === void 0) { transform = ''; }\n var _this = _super.call(this, id) || this;\n _this.transform = '';\n _this.baseLine = 'auto';\n _this.labelRotation = 0;\n _this.x = x;\n _this.y = y;\n _this.anchor = anchor;\n _this.text = text;\n _this.transform = transform;\n _this.baseLine = baseLine;\n _this.labelRotation = labelRotation;\n return _this;\n }\n return TextOption;\n}(CustomizeOption));\nexport { TextOption };\n/** @private */\nexport function getElement(id) {\n return document.getElementById(id);\n}\n/** @private */\nexport function removeElement(id) {\n var element = getElement(id);\n if (element) {\n remove(element);\n }\n}\n/** @private */\nexport function drawSymbol(location, shape, size, url, options, label) {\n var renderer = new SvgRenderer('');\n var temp = calculateShapes(location, size, shape, options, url);\n var htmlObject = renderer['draw' + temp.functionName](temp.renderOption);\n htmlObject.setAttribute('aria-label', label);\n return htmlObject;\n}\n/** @private */\nexport function calculateShapes(location, size, shape, options, url) {\n var path;\n var functionName = 'Path';\n var width = size.width;\n var height = size.height;\n var locX = location.x;\n var locY = location.y;\n var x = location.x + (-width / 2);\n var y = location.y + (-height / 2);\n switch (shape) {\n case 'Circle':\n case 'Bubble':\n functionName = 'Ellipse';\n merge(options, { 'rx': width / 2, 'ry': height / 2, 'cx': locX, 'cy': locY });\n break;\n case 'Plus':\n path = 'M' + ' ' + x + ' ' + locY + ' ' + 'L' + ' ' + (locX + (width / 2)) + ' ' + locY + ' ' +\n 'M' + ' ' + locX + ' ' + (locY + (height / 2)) + ' ' + 'L' + ' ' + locX + ' ' +\n (locY + (-height / 2));\n merge(options, { 'd': path, stroke: options.fill });\n break;\n case 'Cross':\n path = 'M' + ' ' + x + ' ' + (locY + (-height / 2)) + ' ' + 'L' + ' ' + (locX + (width / 2)) + ' ' + (locY + (height / 2)) + ' ' +\n 'M' + ' ' + x + ' ' + (locY + (height / 2)) + ' ' + 'L' + ' ' + (locX + (width / 2)) + ' ' +\n (locY + (-height / 2));\n merge(options, { 'd': path, stroke: options.fill });\n break;\n case 'HorizontalLine':\n path = 'M' + ' ' + x + ' ' + locY + ' ' + 'L' + ' ' + (locX + (width / 2)) + ' ' + locY;\n merge(options, { 'd': path, stroke: options.fill });\n break;\n case 'VerticalLine':\n path = 'M' + ' ' + locX + ' ' + (locY + (height / 2)) + ' ' + 'L' + ' ' + locX + ' ' + (locY + (-height / 2));\n merge(options, { 'd': path, stroke: options.fill });\n break;\n case 'Diamond':\n path = 'M' + ' ' + x + ' ' + locY + ' ' +\n 'L' + ' ' + locX + ' ' + (locY + (-height / 2)) + ' ' +\n 'L' + ' ' + (locX + (width / 2)) + ' ' + locY + ' ' +\n 'L' + ' ' + locX + ' ' + (locY + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + locY + ' z';\n merge(options, { 'd': path });\n break;\n case 'Rectangle':\n path = 'M' + ' ' + x + ' ' + (locY + (-height / 2)) + ' ' +\n 'L' + ' ' + (locX + (width / 2)) + ' ' + (locY + (-height / 2)) + ' ' +\n 'L' + ' ' + (locX + (width / 2)) + ' ' + (locY + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + (locY + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + (locY + (-height / 2)) + ' z';\n merge(options, { 'd': path });\n break;\n case 'Triangle':\n path = 'M' + ' ' + x + ' ' + (locY + (height / 2)) + ' ' +\n 'L' + ' ' + locX + ' ' + (locY + (-height / 2)) + ' ' +\n 'L' + ' ' + (locX + (width / 2)) + ' ' + (locY + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + (locY + (height / 2)) + ' z';\n merge(options, { 'd': path });\n break;\n case 'InvertedTriangle':\n path = 'M' + ' ' + (locX + (width / 2)) + ' ' + (locY - (height / 2)) + ' ' +\n 'L' + ' ' + locX + ' ' + (locY + (height / 2)) + ' ' +\n 'L' + ' ' + (locX - (width / 2)) + ' ' + (locY - (height / 2)) + ' ' +\n 'L' + ' ' + (locX + (width / 2)) + ' ' + (locY - (height / 2)) + ' z';\n merge(options, { 'd': path });\n break;\n case 'Pentagon':\n var eq = 72;\n var xValue = void 0;\n var yValue = void 0;\n for (var i = 0; i <= 5; i++) {\n xValue = (width / 2) * Math.cos((Math.PI / 180) * (i * eq));\n yValue = (height / 2) * Math.sin((Math.PI / 180) * (i * eq));\n if (i === 0) {\n path = 'M' + ' ' + (locX + xValue) + ' ' + (locY + yValue) + ' ';\n }\n else {\n path = path.concat('L' + ' ' + (locX + xValue) + ' ' + (locY + yValue) + ' ');\n }\n }\n path = path.concat('Z');\n merge(options, { 'd': path });\n break;\n case 'Image':\n functionName = 'Image';\n merge(options, { 'href': url, 'height': height, 'width': width, x: x, y: y });\n break;\n }\n return { renderOption: options, functionName: functionName };\n}\n/** @private */\nvar PathOption = /** @class */ (function (_super) {\n __extends(PathOption, _super);\n function PathOption(id, fill, width, color, opacity, dashArray, d) {\n var _this = _super.call(this, id) || this;\n _this.opacity = opacity;\n _this.fill = fill;\n _this.stroke = color;\n _this['stroke-width'] = width;\n _this['stroke-dasharray'] = dashArray;\n _this.d = d;\n return _this;\n }\n return PathOption;\n}(CustomizeOption));\nexport { PathOption };\n/** @private */\nexport function textElement(options, font, color, parent, themeStyle) {\n var renderOptions = {};\n var renderer = new SvgRenderer('');\n renderOptions = {\n 'id': options.id,\n 'x': options.x,\n 'y': options.y,\n 'fill': color,\n 'font-size': font.size,\n 'font-style': font.fontStyle,\n 'font-family': font.fontFamily || themeStyle.fontFamily,\n 'font-weight': font.fontWeight,\n 'text-anchor': options.anchor,\n 'transform': options.transform,\n 'opacity': font.opacity,\n 'dominant-baseline': options.baseLine\n };\n var text = typeof options.text === 'string' ? options.text : options.text[0];\n var htmlObject = renderer.createText(renderOptions, text);\n if (parent) {\n parent.appendChild(htmlObject);\n }\n return htmlObject;\n}\nvar TooltipLocation = /** @class */ (function () {\n function TooltipLocation(x, y) {\n this.x = x;\n this.y = y;\n }\n return TooltipLocation;\n}());\nexport { TooltipLocation };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable security/detect-object-injection */\n/* eslint-disable no-useless-escape */\n/* eslint-disable security/detect-non-literal-regexp */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable jsdoc/require-param */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable valid-jsdoc */\nimport { NotifyPropertyChanges, Property, Event, Complex, updateBlazorTemplate } from '@syncfusion/ej2-base';\nimport { extend, compile as templateComplier, Component, resetBlazorTemplate, isBlazor, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { SvgRenderer } from '../svg-render/index';\nimport { ChildProperty, createElement, remove, Browser, Animation, animationMode } from '@syncfusion/ej2-base';\nimport { getTooltipThemeColor } from './interface';\nimport { Size, Rect, Side, measureText, getElement, findDirection, drawSymbol, textElement } from './helper';\nimport { removeElement, TextOption, TooltipLocation, PathOption, withInAreaBounds } from './helper';\n/**\n * Configures the fonts in charts.\n *\n * @private\n */\nvar TextStyle = /** @class */ (function (_super) {\n __extends(TextStyle, _super);\n function TextStyle() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], TextStyle.prototype, \"size\", void 0);\n __decorate([\n Property('')\n ], TextStyle.prototype, \"color\", void 0);\n __decorate([\n Property('Segoe UI')\n ], TextStyle.prototype, \"fontFamily\", void 0);\n __decorate([\n Property('Normal')\n ], TextStyle.prototype, \"fontWeight\", void 0);\n __decorate([\n Property('Normal')\n ], TextStyle.prototype, \"fontStyle\", void 0);\n __decorate([\n Property(1)\n ], TextStyle.prototype, \"opacity\", void 0);\n return TextStyle;\n}(ChildProperty));\nexport { TextStyle };\n/**\n * Configures the borders in the chart.\n *\n * @private\n */\nvar TooltipBorder = /** @class */ (function (_super) {\n __extends(TooltipBorder, _super);\n function TooltipBorder() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('')\n ], TooltipBorder.prototype, \"color\", void 0);\n __decorate([\n Property(1)\n ], TooltipBorder.prototype, \"width\", void 0);\n __decorate([\n Property('')\n ], TooltipBorder.prototype, \"dashArray\", void 0);\n return TooltipBorder;\n}(ChildProperty));\nexport { TooltipBorder };\n/**\n * Configures the borders in the chart.\n *\n * @private\n */\nvar AreaBounds = /** @class */ (function (_super) {\n __extends(AreaBounds, _super);\n function AreaBounds() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0)\n ], AreaBounds.prototype, \"x\", void 0);\n __decorate([\n Property(0)\n ], AreaBounds.prototype, \"y\", void 0);\n __decorate([\n Property(0)\n ], AreaBounds.prototype, \"width\", void 0);\n __decorate([\n Property(0)\n ], AreaBounds.prototype, \"height\", void 0);\n return AreaBounds;\n}(ChildProperty));\nexport { AreaBounds };\n/**\n * Configures the borders in the chart.\n *\n * @private\n */\nvar ToolLocation = /** @class */ (function (_super) {\n __extends(ToolLocation, _super);\n function ToolLocation() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0)\n ], ToolLocation.prototype, \"x\", void 0);\n __decorate([\n Property(0)\n ], ToolLocation.prototype, \"y\", void 0);\n return ToolLocation;\n}(ChildProperty));\nexport { ToolLocation };\n/**\n * Represents the Tooltip control.\n * ```html\n * <div id=\"tooltip\"/>\n * <script>\n * var tooltipObj = new Tooltip({ isResponsive : true });\n * tooltipObj.appendTo(\"#tooltip\");\n * </script>\n * ```\n *\n * @private\n */\nvar Tooltip = /** @class */ (function (_super) {\n __extends(Tooltip, _super);\n /**\n * Constructor for creating the widget\n *\n * @hidden\n */\n function Tooltip(options, element) {\n return _super.call(this, options, element) || this;\n }\n /**\n * Initialize the event handler.\n *\n * @private\n */\n Tooltip.prototype.preRender = function () {\n this.allowServerDataBinding = false;\n this.initPrivateVariable();\n if (!this.isCanvas) {\n this.removeSVG();\n }\n this.createTooltipElement();\n };\n Tooltip.prototype.initPrivateVariable = function () {\n this.renderer = new SvgRenderer(this.element.id);\n this.themeStyle = getTooltipThemeColor(this.theme);\n this.formattedText = [];\n this.padding = 5;\n this.highlightPadding = 3;\n this.areaMargin = 10;\n this.isFirst = true;\n this.markerPoint = [];\n };\n Tooltip.prototype.removeSVG = function () {\n var svgObject = document.getElementById(this.element.id + '_svg');\n var templateObject = document.getElementById(this.element.id + 'parent_template');\n if (this.blazorTemplate) {\n resetBlazorTemplate(this.element.id + 'parent_template' + '_blazorTemplate');\n }\n if (svgObject && svgObject.parentNode) {\n remove(svgObject);\n }\n if (templateObject && templateObject.parentNode) {\n remove(templateObject);\n }\n };\n /**\n * To Initialize the control rendering.\n */\n Tooltip.prototype.render = function () {\n this.fadeOuted = false;\n if (!this.template) {\n this.renderText(this.isFirst);\n var argsData = {\n cancel: false, name: 'tooltipRender', tooltip: this\n };\n this.trigger('tooltipRender', argsData);\n var markerSide = this.renderTooltipElement(this.areaBounds, this.location);\n this.drawMarker(markerSide.isBottom, markerSide.isRight, this.markerSize);\n }\n else {\n this.updateTemplateFn();\n this.createTemplate(this.areaBounds, this.location);\n }\n this.trigger('loaded', { tooltip: this });\n var element = document.getElementById('chartmeasuretext');\n if (element) {\n remove(element);\n }\n this.allowServerDataBinding = true;\n };\n Tooltip.prototype.createTooltipElement = function () {\n this.textElements = [];\n if (!this.template || this.shared) {\n // SVG element for tooltip\n if (this.enableRTL) {\n this.element.setAttribute('dir', 'ltr');\n }\n var svgObject = this.renderer.createSvg({ id: this.element.id + '_svg' });\n this.element.appendChild(svgObject);\n // Group to hold text and path.\n var groupElement = document.getElementById(this.element.id + '_group');\n if (!groupElement) {\n groupElement = this.renderer.createGroup({ id: this.element.id + '_group' });\n groupElement.setAttribute('transform', 'translate(0,0)');\n }\n svgObject.appendChild(groupElement);\n var pathElement = this.renderer.drawPath({\n 'id': this.element.id + '_path', 'stroke-width': ((this.theme === 'Fabric' || this.theme === 'Fluent') && !this.border.width) ? 1 : this.border.width,\n 'fill': this.fill || this.themeStyle.tooltipFill, 'opacity': ((this.theme === 'TailwindDark' || this.theme === 'Tailwind' || this.theme === 'Bootstrap5' || this.theme === 'Bootstrap5Dark') && this.opacity === 0.75) ?\n 1 : this.opacity,\n 'stroke': this.border.color || (this.theme === 'Fabric' || this.theme === 'Fluent' ? '#D2D0CE' : this.border.color)\n });\n groupElement.appendChild(pathElement);\n }\n };\n Tooltip.prototype.drawMarker = function (isBottom, isRight, size) {\n if (this.shapes.length <= 0) {\n return null;\n }\n var shapeOption;\n var count = 0;\n var markerGroup = this.renderer.createGroup({ id: this.element.id + '_trackball_group' });\n var groupElement = getElement(this.element.id + '_group');\n if (!groupElement) {\n return null;\n }\n var x = ((this.enableRTL) ? this.elementSize.width - (size / 2) :\n (this.marginX * 2) + (size / 2)) + (isRight ? this.arrowPadding : 0);\n for (var _i = 0, _a = this.shapes; _i < _a.length; _i++) {\n var shape = _a[_i];\n if (shape !== 'None') {\n shapeOption = new PathOption(this.element.id + '_Trackball_' + count, this.palette[count], 1, '#cccccc', 1, null);\n if (this.markerPoint[count]) {\n var padding = 0;\n if (this.header.indexOf('<br') > -1) {\n padding = this.header.split(/<br.*?>/g).length + count;\n }\n markerGroup.appendChild(drawSymbol(new TooltipLocation(x, this.markerPoint[count] - this.padding + (isBottom ? this.arrowPadding : padding)), shape, new Size(size, size), '', shapeOption, null));\n }\n count++;\n }\n }\n groupElement.appendChild(markerGroup);\n };\n Tooltip.prototype.renderTooltipElement = function (areaBounds, location) {\n var tooltipDiv = getElement(this.element.id);\n var arrowLocation = new TooltipLocation(0, 0);\n var tipLocation = new TooltipLocation(0, 0);\n var svgObject = getElement(this.element.id + '_svg');\n var groupElement = getElement(this.element.id + '_group');\n var pathElement = getElement(this.element.id + '_path');\n var rect;\n var isTop = false;\n var isLeft = false;\n var isBottom = false;\n var x = 0;\n var y = 0;\n if (!isNullOrUndefined(groupElement)) {\n if (this.header !== '') {\n this.elementSize.height += this.marginY;\n }\n if (this.isFixed) {\n var width = this.elementSize.width + (2 * this.marginX);\n var height = this.elementSize.height + (2 * this.marginY);\n rect = new Rect(location.x, location.y, width, height);\n }\n else if (this.content.length > 1) {\n rect = this.sharedTooltipLocation(areaBounds, this.location.x, this.location.y);\n isTop = true;\n }\n else {\n rect = this.tooltipLocation(areaBounds, location, arrowLocation, tipLocation);\n if (!this.inverted) {\n isTop = (rect.y < (location.y + this.clipBounds.y));\n isBottom = !isTop;\n y = (isTop ? 0 : this.arrowPadding);\n }\n else {\n isLeft = (rect.x < (location.x + this.clipBounds.x));\n x = (isLeft ? 0 : this.arrowPadding);\n if (this.allowHighlight) {\n rect.x += isLeft ? this.highlightPadding : -(2 * this.highlightPadding);\n }\n }\n }\n if (this.header !== '') {\n var wrapPadding = 2;\n var padding = 0;\n var wrapHeader = this.isWrap ? this.wrappedText : this.header;\n if (this.isWrap && typeof (wrapHeader) === 'string' && (wrapHeader.indexOf('<') > -1 || wrapHeader.indexOf('>') > -1)) {\n var textArray = wrapHeader.split('<br>');\n wrapPadding = textArray.length;\n }\n if (this.header.indexOf('<br') > -1) {\n padding = 5 * (this.header.split(/<br.*?>/g).length - 1);\n }\n var key = 'properties';\n var font = extend({}, this.textStyle, null, true)[key];\n var headerSize = measureText(this.isWrap ? this.wrappedText : this.header, font, this.themeStyle.textStyle).height +\n (this.marginY * wrapPadding) + (isBottom ? this.arrowPadding : 0) + (this.isWrap ? 5 : padding); //header padding;\n var xLength = (this.marginX * 3) + (!isLeft && !isTop && !isBottom ? this.arrowPadding : 0);\n var direction = 'M ' + xLength + ' ' + headerSize +\n 'L ' + (rect.width + (!isLeft && !isTop && !isBottom ? this.arrowPadding : 0) - (this.marginX * 2)) +\n ' ' + headerSize;\n var pathElement_1 = this.renderer.drawPath({\n 'id': this.element.id + '_header_path', 'stroke-width': 1,\n 'fill': null, 'opacity': this.theme === ('Material3' || 'Material3Dark') ? 0.2 : 0.8, 'stroke': this.themeStyle.tooltipHeaderLine, 'd': direction\n });\n groupElement.appendChild(pathElement_1);\n }\n var start = this.border.width / 2;\n var pointRect = new Rect(start + x, start + y, rect.width - start, rect.height - start);\n groupElement.setAttribute('opacity', '1');\n if (this.enableAnimation && !this.isFirst && !this.crosshair) {\n this.animateTooltipDiv(tooltipDiv, rect);\n }\n else {\n this.updateDiv(tooltipDiv, rect.x, rect.y);\n }\n // eslint-disable-next-line no-extra-boolean-cast\n svgObject.setAttribute('height', (rect.height + this.border.width + (!((!this.inverted)) ? 0 : this.arrowPadding) + 5).toString());\n svgObject.setAttribute('width', (rect.width + this.border.width + (((!this.inverted)) ? 0 : this.arrowPadding) + 5).toString());\n svgObject.setAttribute('opacity', '1');\n if (!isNullOrUndefined(this.tooltipPlacement)) {\n isTop = this.tooltipPlacement.indexOf('Top') > -1;\n isBottom = this.tooltipPlacement.indexOf('Bottom') > -1;\n isLeft = this.tooltipPlacement.indexOf('Left') > -1;\n }\n pathElement.setAttribute('d', findDirection(this.rx, this.ry, pointRect, arrowLocation, this.arrowPadding, isTop, isBottom, isLeft, tipLocation.x, tipLocation.y, this.controlName));\n if (this.enableShadow && this.theme !== 'Bootstrap4') {\n // To fix next chart initial tooltip opacity issue in tab control\n var shadowId = this.element.id + '_shadow';\n if (this.theme === 'Tailwind' || this.theme === 'TailwindDark'\n || this.theme === 'Bootstrap5' || this.theme === 'Bootstrap5Dark') {\n pathElement.setAttribute('box-shadow', '0px 1px 2px rgba(0, 0, 0, 0.06), 0px 1px 3px rgba(0, 0, 0, 0.1)');\n }\n else {\n pathElement.setAttribute('filter', Browser.isIE ? '' : 'url(#' + shadowId + ')');\n }\n var shadow = '<filter id=\"' + shadowId + '\" height=\"130%\"><feGaussianBlur in=\"SourceAlpha\" stdDeviation=\"3\"/>';\n shadow += '<feOffset dx=\"3\" dy=\"3\" result=\"offsetblur\"/><feComponentTransfer><feFuncA type=\"linear\" slope=\"0.5\"/>';\n shadow += '</feComponentTransfer><feMerge><feMergeNode/><feMergeNode in=\"SourceGraphic\"/></feMerge></filter>';\n var defElement = this.renderer.createDefs();\n defElement.setAttribute('id', this.element.id + 'SVG_tooltip_definition');\n groupElement.appendChild(defElement);\n defElement.innerHTML = shadow;\n }\n var borderColor = ((this.theme === 'Fabric' || this.theme === 'Fluent') && !this.border.color) ? '#D2D0CE' : this.border.color;\n pathElement.setAttribute('stroke', borderColor);\n if (!isNullOrUndefined(this.border.dashArray)) {\n pathElement.setAttribute('stroke-dasharray', this.border.dashArray);\n }\n this.changeText(new TooltipLocation(x, y), isBottom, !isLeft && !isTop && !isBottom);\n if (this.revert) {\n this.inverted = !this.inverted;\n this.revert = false;\n }\n }\n return new Side(isBottom, !isLeft && !isTop && !isBottom);\n };\n Tooltip.prototype.changeText = function (point, isBottom, isRight) {\n var element = document.getElementById(this.element.id + '_text');\n if (isBottom) {\n element.setAttribute('transform', 'translate(0,' + this.arrowPadding + ')');\n }\n if (isRight) {\n element.setAttribute('transform', 'translate(' + this.arrowPadding + ' 0)');\n }\n };\n Tooltip.prototype.findFormattedText = function () {\n this.formattedText = [];\n if (this.header.replace(/<b>/g, '').replace(/<\\/b>/g, '').trim() !== '') {\n this.formattedText = this.formattedText.concat(this.header);\n }\n this.formattedText = this.formattedText.concat(this.content);\n };\n // tslint:disable-next-line:max-func-body-length\n Tooltip.prototype.renderText = function (isRender) {\n var height = 0;\n var width = 0; // Padding for text;\n var subWidth = 0;\n var lines;\n var key = 'properties';\n var font = extend({}, this.textStyle, null, true)[key];\n var groupElement = getElement(this.element.id + '_group');\n var tspanElement;\n var textCollection;\n var tspanStyle = '';\n var line;\n var tspanOption;\n this.findFormattedText();\n this.isWrap = false;\n var isRtlEnabled = document.body.getAttribute('dir') === 'rtl';\n var anchor = isRtlEnabled && !this.enableRTL ? 'end' : 'start';\n this.leftSpace = this.areaBounds.x + this.location.x;\n this.rightSpace = (this.areaBounds.x + this.areaBounds.width) - this.leftSpace;\n var headerContent = this.header.replace(/<b>/g, '').replace(/<\\/b>/g, '').trim();\n var isBoldTag = this.header.indexOf('<b>') > -1 && this.header.indexOf('</b>') > -1;\n var headerWidth = measureText(this.formattedText[0], font, this.themeStyle.textStyle).width\n + (2 * this.marginX) + this.arrowPadding;\n var isLeftSpace = (this.location.x - headerWidth) < this.location.x;\n var isRightSpace = (this.areaBounds.x + this.areaBounds.width) < (this.location.x + headerWidth);\n var header;\n var headerSpace = (headerContent !== '') ? this.marginY : 0;\n var isRow = true;\n var isColumn = true;\n this.markerPoint = [];\n var markerSize = (this.shapes.length > 0) ? 10 : 0;\n var markerPadding = (this.shapes.length > 0) ? 5 : 0;\n var spaceWidth = 4;\n var subStringLength;\n var fontSize = '12px';\n var fontWeight = '400';\n var labelColor = this.themeStyle.tooltipLightLabel;\n var dy = (22 / parseFloat(fontSize)) * (parseFloat(font.size));\n var contentWidth = [];\n var textHeight = 0;\n if (!isRender || this.isCanvas) {\n removeElement(this.element.id + '_text');\n removeElement(this.element.id + '_header_path');\n removeElement(this.element.id + '_trackball_group');\n removeElement(this.element.id + 'SVG_tooltip_definition');\n }\n // Condition to resolve the text size issue only in chart.\n if (this.controlName === 'Chart' && parseFloat(fontSize) < parseFloat(font.size)) {\n textHeight = (parseFloat(font.size) - parseFloat(fontSize));\n }\n var options = new TextOption(this.element.id + '_text', this.marginX * 2, (textHeight + this.marginY * 2 + this.padding * 2 + (this.marginY === 2 ? this.controlName === 'RangeNavigator' ? 5 : 3 : 0)), anchor, '');\n var parentElement = textElement(options, font, font.color || this.themeStyle.tooltipBoldLabel, groupElement, this.themeStyle.textStyle);\n var withoutHeader = this.formattedText.length === 1 && this.formattedText[0].indexOf(' : <b>') > -1;\n var isHeader = this.header !== '';\n var size = isHeader && isBoldTag ? 16 : 13;\n for (var k = 0, pointsLength = this.formattedText.length; k < pointsLength; k++) {\n textCollection = this.formattedText[k].replace(/<(b|strong)>/g, '<b>')\n .replace(/<\\/(b|strong)>/g, '</b>')\n .split(/<br.*?>/g);\n if (this.isTextWrap && this.header !== this.formattedText[k] && this.formattedText[k].indexOf('<br') === -1) {\n subStringLength = Math.round(this.leftSpace > this.rightSpace ? (this.leftSpace / size) : (this.rightSpace / size));\n textCollection = this.formattedText[k].match(new RegExp('.{1,' + subStringLength + '}', 'g'));\n }\n if (k === 0 && !withoutHeader && this.isTextWrap &&\n (this.leftSpace < headerWidth || isLeftSpace) &&\n (this.rightSpace < headerWidth || isRightSpace)) {\n subStringLength = Math.round(this.leftSpace > this.rightSpace ? (this.leftSpace / size) : (this.rightSpace / size));\n header = headerContent !== '' ? headerContent : this.formattedText[k];\n textCollection = header.match(new RegExp('.{1,' + subStringLength + '}', 'g'));\n this.wrappedText = isBoldTag ? '<b>' + textCollection.join('<br>') + '</b>' : textCollection.join('<br>');\n this.isWrap = textCollection.length > 1;\n }\n if (textCollection[0] === '') {\n continue;\n }\n if ((k !== 0) || (headerContent === '')) {\n this.markerPoint.push((headerContent !== '' ? (this.marginY) : 0) + options.y + height - (textHeight !== 0 ? ((textHeight / this.markerSize) * (parseFloat(font.size) / this.markerSize)) : 0));\n }\n for (var i = 0, len = textCollection.length; i < len; i++) { // string value of unicode for LTR is \\u200E\n lines = textCollection[i].replace(/<b>/g, '<br><b>').replace(/<\\/b>/g, '</b><br>').replace(/:/g, (this.enableRTL) ? '<br>\\u200E: <br>' : '<br>\\u200E:<br>')\n .split('<br>');\n if (this.enableRTL && lines.length > 0 && textCollection[i].match(/:/g)) {\n lines[0] = lines[0].trim();\n lines.reverse();\n }\n subWidth = 0;\n isColumn = true;\n height += dy;\n for (var j = 0, len_1 = lines.length; j < len_1; j++) {\n line = lines[j];\n if (this.enableRTL && line !== '' && this.isRTLText(line)) {\n line = line.concat('\\u200E');\n }\n if (!/\\S/.test(line) && line !== '') {\n line = ' '; //to trim multiple white spaces to single white space\n }\n if ((!isColumn && line === ' ') || (line.replace(/<b>/g, '').replace(/<\\/b>/g, '').trim() !== '')) {\n subWidth += line !== ' ' ? spaceWidth : 0;\n if (isColumn && !isRow) {\n if (this.header.indexOf('<br') > -1 && k !== 0) {\n headerSpace += this.header.split(/<br.*?>/g).length;\n }\n tspanOption = {\n x: (this.marginX * 2) + (markerSize + markerPadding),\n dy: dy + ((isColumn) ? headerSpace : 0), fill: ''\n };\n headerSpace = null;\n }\n else {\n if (isRow && isColumn) {\n tspanOption = {\n x: (headerContent === '') ? ((this.marginX * 2) + (markerSize + markerPadding))\n : (this.marginX * 2) + (this.isWrap ? (markerSize + markerPadding) : 0)\n };\n }\n else {\n tspanOption = {};\n }\n }\n isColumn = false;\n tspanElement = this.renderer.createTSpan(tspanOption, '');\n parentElement.appendChild(tspanElement);\n if (line.indexOf('<b>') > -1 || ((isBoldTag && j === 0 && k === 0) && (isHeader || this.isWrap))) {\n fontWeight = '600';\n labelColor = this.themeStyle.tooltipBoldLabel;\n tspanStyle = 'font-weight:' + fontWeight;\n font.fontWeight = fontWeight;\n (tspanElement).setAttribute('fill', this.textStyle.color || labelColor);\n }\n else {\n tspanStyle = fontWeight === '600' ? 'font-weight:' + fontWeight : '';\n font.fontWeight = fontWeight;\n (tspanElement).setAttribute('fill', this.textStyle.color || labelColor);\n }\n if (line.indexOf('</b>') > -1 || ((isBoldTag && j === len_1 - 1 && k === 0) && (isHeader || this.isWrap))) {\n fontWeight = 'Normal';\n labelColor = this.themeStyle.tooltipLightLabel;\n }\n // eslint-disable-next-line no-useless-escape\n if (tspanStyle !== '') {\n tspanElement.style.fontWeight = tspanStyle.split('font-weight:')[1];\n tspanElement.style.color = tspanElement.getAttribute('fill');\n }\n // 'inherit' will apply css style from parent element.\n tspanElement.style.fontFamily = 'inherit';\n tspanElement.style.fontStyle = 'inherit';\n tspanElement.style.fontSize = (this.header === this.formattedText[k]) ? font.size : this.textStyle.size;\n tspanElement.style.fontWeight = (this.header === this.formattedText[k] && (this.header.indexOf('<b>') || this.header.indexOf('</b>')) === -1) ? (this.textStyle.fontWeight || '600') : line.indexOf('<b>') > -1 || line.indexOf('</b>') > -1 ? 'bold' : (this.textStyle.fontWeight || font.fontWeight);\n var textFont = extend({}, this.textStyle, null, true)[key];\n textFont.fontWeight = tspanElement.style.fontWeight;\n isRow = false;\n (tspanElement).textContent = line = this.getTooltipTextContent(line);\n subWidth += measureText(line, textFont, this.themeStyle.textStyle).width;\n }\n }\n subWidth -= spaceWidth;\n width = Math.max(width, subWidth);\n contentWidth.push(subWidth);\n }\n }\n this.elementSize = new Size(width + (width > 0 ? (2 * this.marginX) : 0), height);\n this.elementSize.width += (markerSize + markerPadding); // marker size + marker Spacing\n var element = (parentElement.childNodes[0]);\n if (headerContent !== '' && element && !this.isWrap) {\n font.fontWeight = '600';\n var width_1 = (this.elementSize.width + (2 * this.padding)) / 2 - measureText(headerContent, font, this.themeStyle.textStyle).width / 2;\n element.setAttribute('x', width_1.toString());\n }\n this.renderContentRTL(parentElement, isHeader, markerSize + markerPadding, contentWidth);\n };\n Tooltip.prototype.renderContentRTL = function (textElement, isHeader, markerSize, contentWidth) {\n if (this.enableRTL) {\n var tspanElement = void 0;\n var contentWidthIndex = isHeader ? 1 : 0;\n for (var i = 0; i < textElement.childNodes.length; i++) {\n tspanElement = (textElement.childNodes[i]);\n if ((!isHeader || i > 0) && !isNullOrUndefined(tspanElement.getAttribute('x'))) {\n tspanElement.setAttribute('x', (this.elementSize.width - (markerSize + contentWidth[contentWidthIndex])).toString());\n contentWidthIndex++;\n }\n }\n }\n };\n Tooltip.prototype.getTooltipTextContent = function (tooltipText) {\n var characterCollection = tooltipText.match(/<[a-zA-Z\\/](.|\\n)*?>/g);\n if (isNullOrUndefined(characterCollection)) {\n return tooltipText;\n }\n var isRtlText = this.isRTLText(tooltipText);\n for (var i = 0; i < characterCollection.length; i++) {\n if (this.isValidHTMLElement(characterCollection[i].replace('<', '').replace('/', '').replace('>', '').trim())) {\n tooltipText = tooltipText.replace(characterCollection[i], isRtlText ? '\\u200E' : '');\n }\n }\n return tooltipText;\n };\n Tooltip.prototype.isValidHTMLElement = function (element) {\n return document.createElement(element).toString() !== '[object HTMLUnknownElement]';\n };\n Tooltip.prototype.isRTLText = function (tooltipContent) {\n return /[\\u0590-\\u07FF\\u200F\\u202B\\u202E\\uFB1D-\\uFDFD\\uFE70-\\uFEFC]/.test(tooltipContent);\n };\n Tooltip.prototype.createTemplate = function (areaBounds, location) {\n var argsData = { cancel: false, name: 'tooltipRender', tooltip: this };\n this.trigger('tooltipRender', argsData);\n var parent = document.getElementById(this.element.id);\n if (this.isCanvas) {\n this.removeSVG();\n }\n var firstElement = parent.firstElementChild;\n if (firstElement) {\n remove(firstElement);\n }\n if (!argsData.cancel) {\n var elem = createElement('div', { id: this.element.id + 'parent_template' });\n var templateElement = void 0;\n if (this.controlName === 'Chart' && this.shared) {\n for (var i = 0; i < this.data.length; i++) {\n var sharedTemplateElement = this.templateFn(this.data[i], this.controlInstance, elem.id, elem.id + '_blazorTemplate', '');\n if (i === 0) {\n templateElement = sharedTemplateElement;\n }\n else {\n templateElement[templateElement.length - 1].outerHTML += sharedTemplateElement[0].outerHTML;\n }\n }\n }\n else {\n templateElement = this.templateFn(this.data, this.controlInstance, elem.id, elem.id + '_blazorTemplate', '');\n }\n while (templateElement && templateElement.length > 0) {\n if (isBlazor() || templateElement.length === 1) {\n elem.appendChild(templateElement[0]);\n templateElement = null;\n }\n else {\n elem.appendChild(templateElement[0]);\n }\n }\n parent.appendChild(elem);\n var element = this.isCanvas ? elem : this.element;\n var rect = element.getBoundingClientRect();\n this.padding = 0;\n this.elementSize = new Size(rect.width, rect.height);\n var tooltipRect = this.shared ? this.sharedTooltipLocation(areaBounds, this.location.x, this.location.y)\n : this.tooltipLocation(areaBounds, location, new TooltipLocation(0, 0), new TooltipLocation(0, 0));\n if (this.enableAnimation && !this.isFirst && !this.crosshair) {\n this.animateTooltipDiv(this.element, tooltipRect);\n }\n else {\n this.updateDiv(element, tooltipRect.x, tooltipRect.y);\n }\n if (this.blazorTemplate) {\n //Customer issue - F149037 Call back function to handle the blazor tooltip alignment issues\n var tooltipRendered = function () {\n var rect1 = getElement(thisObject_1.element.id).getBoundingClientRect();\n thisObject_1.elementSize = new Size(rect1.width, rect1.height);\n var tooltipRect1 = thisObject_1.tooltipLocation(areaBounds, location, new TooltipLocation(0, 0), new TooltipLocation(0, 0));\n thisObject_1.updateDiv(getElement(thisObject_1.element.id), tooltipRect1.x, tooltipRect1.y);\n };\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var thisObject_1 = this;\n tooltipRendered.bind(thisObject_1, areaBounds, location);\n updateBlazorTemplate(this.element.id + 'parent_template' + '_blazorTemplate', this.blazorTemplate.name, this.blazorTemplate.parent, undefined, tooltipRendered);\n }\n }\n else {\n remove(getElement(this.element.id + '_tooltip'));\n }\n };\n Tooltip.prototype.sharedTooltipLocation = function (bounds, x, y) {\n var width = this.elementSize.width + (2 * this.marginX);\n var height = this.elementSize.height + (2 * this.marginY);\n var tooltipRect = new Rect(x + 2 * this.padding, y - height - this.padding, width, height);\n if (tooltipRect.y < bounds.y) {\n tooltipRect.y += (tooltipRect.height + 2 * this.padding);\n }\n if (tooltipRect.y + tooltipRect.height > bounds.y + bounds.height) {\n tooltipRect.y = Math.max((bounds.y + bounds.height) - (tooltipRect.height + 2 * this.padding), bounds.y);\n }\n if (tooltipRect.x + tooltipRect.width > bounds.x + bounds.width) {\n tooltipRect.x = (bounds.x + this.location.x) - (tooltipRect.width + 4 * this.padding);\n }\n if (tooltipRect.x < bounds.x) {\n tooltipRect.x = bounds.x;\n }\n return tooltipRect;\n };\n Tooltip.prototype.getCurrentPosition = function (bounds, symbolLocation, arrowLocation, tipLocation) {\n var position = this.tooltipPlacement;\n var clipX = this.clipBounds.x;\n var clipY = this.clipBounds.y;\n var markerHeight = this.offset;\n var width = this.elementSize.width + (2 * this.marginX);\n var height = this.elementSize.height + (2 * this.marginY);\n var location = new TooltipLocation(symbolLocation.x, symbolLocation.y);\n if (position === 'Top' || position === 'Bottom') {\n location = new TooltipLocation(location.x + clipX - this.elementSize.width / 2 - this.padding, location.y + clipY - this.elementSize.height - (2 * this.padding) - this.arrowPadding - markerHeight);\n arrowLocation.x = tipLocation.x = width / 2;\n if (position === 'Bottom') {\n location.y = symbolLocation.y + clipY + markerHeight;\n }\n if (bounds.x + bounds.width < location.x + width) {\n location.x = (bounds.width > width) ? ((bounds.x + bounds.width) - width + 6) : bounds.x;\n arrowLocation.x = tipLocation.x = (bounds.width > width) ? (bounds.x + symbolLocation.x - location.x) : symbolLocation.x;\n }\n else if (bounds.x > location.x) {\n location.x = bounds.x;\n arrowLocation.x = tipLocation.x = symbolLocation.x;\n }\n }\n else {\n location = new TooltipLocation(location.x + clipX + markerHeight, location.y + clipY - this.elementSize.height / 2 - (this.padding));\n arrowLocation.y = tipLocation.y = height / 2;\n if (position === 'Left') {\n location.x = symbolLocation.x + clipX - markerHeight - (width + this.arrowPadding);\n }\n if (bounds.y + bounds.height < location.y + height) {\n location.y = (bounds.height > height) ? ((bounds.y + bounds.height) - height + 6) : bounds.y;\n arrowLocation.y = tipLocation.y = (bounds.height > height) ? (bounds.y + symbolLocation.y - location.y) : symbolLocation.y;\n }\n else if (bounds.y > location.y) {\n location.y = bounds.y;\n arrowLocation.y = tipLocation.y = symbolLocation.y;\n }\n }\n return new Rect(location.x, location.y, width, height);\n };\n // tslint:disable-next-line:max-func-body-length\n Tooltip.prototype.tooltipLocation = function (bounds, symbolLocation, arrowLocation, tipLocation) {\n if (!isNullOrUndefined(this.tooltipPlacement)) {\n var tooltipRect = this.getCurrentPosition(bounds, symbolLocation, arrowLocation, tipLocation);\n return tooltipRect;\n }\n var location = new TooltipLocation(symbolLocation.x, symbolLocation.y);\n var width = this.elementSize.width + (2 * this.marginX);\n var height = this.elementSize.height + (2 * this.marginY);\n var markerHeight = this.offset;\n var clipX = this.clipBounds.x;\n var clipY = this.clipBounds.y;\n var boundsX = bounds.x;\n var boundsY = bounds.y;\n this.outOfBounds = false;\n if (!this.inverted) {\n location = new TooltipLocation(location.x + clipX - this.elementSize.width / 2 - this.padding, location.y + clipY - this.elementSize.height - (2 * (this.allowHighlight ? this.highlightPadding : this.padding)) -\n this.arrowPadding - markerHeight);\n arrowLocation.x = tipLocation.x = width / 2;\n if ((location.y < boundsY || (this.isNegative)) && !(this.controlName === 'Progressbar')) {\n location.y = (symbolLocation.y < 0 ? 0 : symbolLocation.y) + clipY + markerHeight;\n }\n if (location.y + height + this.arrowPadding > boundsY + bounds.height) {\n location.y = Math.min(symbolLocation.y, boundsY + bounds.height) + clipY\n - this.elementSize.height - (2 * this.padding) - this.arrowPadding - markerHeight;\n }\n if (((location.x + width > boundsX + bounds.width) && location.y < boundsY || (this.isNegative)) && !(this.controlName === 'Progressbar')) {\n location.y = (symbolLocation.y < 0 ? 0 : symbolLocation.y) + clipY + markerHeight;\n }\n tipLocation.x = width / 2;\n if (location.x < boundsX && !(this.controlName === 'Progressbar')) {\n arrowLocation.x -= (boundsX - location.x);\n tipLocation.x -= (boundsX - location.x);\n location.x = boundsX;\n }\n if (location.x + width > boundsX + bounds.width && !(this.controlName === 'Progressbar')) {\n arrowLocation.x += ((location.x + width) - (boundsX + bounds.width));\n tipLocation.x += ((location.x + width) - (boundsX + bounds.width));\n location.x -= ((location.x + width) - (boundsX + bounds.width));\n }\n if (location.x < boundsX && !(this.controlName === 'Progressbar')) {\n arrowLocation.x -= (boundsX - location.x);\n tipLocation.x -= (boundsX - location.x);\n location.x = boundsX;\n }\n if (arrowLocation.x + this.arrowPadding > width - this.rx) {\n arrowLocation.x = width - this.rx - this.arrowPadding;\n tipLocation.x = width - this.rx - this.arrowPadding;\n }\n if (arrowLocation.x - this.arrowPadding < this.rx) {\n arrowLocation.x = tipLocation.x = this.rx + this.arrowPadding;\n }\n if (this.controlName === 'Chart') {\n if (((bounds.x + bounds.width) - (location.x + arrowLocation.x)) < this.areaMargin + this.arrowPadding ||\n (location.x + arrowLocation.x) < this.areaMargin + this.arrowPadding) {\n this.outOfBounds = true;\n }\n if (!withInAreaBounds(location.x, location.y, bounds) || this.outOfBounds) {\n this.inverted = !this.inverted;\n this.revert = true;\n location = new TooltipLocation(symbolLocation.x + markerHeight + clipX, symbolLocation.y + clipY - this.elementSize.height / 2 - (this.padding));\n tipLocation.x = arrowLocation.x = 0;\n tipLocation.y = arrowLocation.y = height / 2;\n if ((location.x + this.arrowPadding + width > boundsX + bounds.width) || (this.isNegative)) {\n location.x = (symbolLocation.x > boundsX + bounds.width ? bounds.width : symbolLocation.x)\n + clipX - markerHeight - (this.arrowPadding + width);\n }\n if (location.x < boundsX) {\n location.x = (symbolLocation.x < 0 ? 0 : symbolLocation.x) + markerHeight + clipX;\n }\n if (location.y <= boundsY) {\n tipLocation.y -= (boundsY - location.y);\n arrowLocation.y -= (boundsY - location.y);\n location.y = boundsY;\n }\n if (location.y + height >= bounds.height + boundsY) {\n arrowLocation.y += ((location.y + height) - (bounds.height + boundsY));\n tipLocation.y += ((location.y + height) - (bounds.height + boundsY));\n location.y -= ((location.y + height) - (bounds.height + boundsY));\n }\n if ((this.arrowPadding) + arrowLocation.y > height - this.ry) {\n arrowLocation.y = height - this.arrowPadding - this.ry;\n tipLocation.y = height;\n }\n if (arrowLocation.y - this.arrowPadding < this.ry) {\n arrowLocation.y = (this.arrowPadding) + this.ry;\n tipLocation.y = 0;\n }\n }\n }\n }\n else {\n location = new TooltipLocation(location.x + clipX + markerHeight, location.y + clipY - this.elementSize.height / 2 - (this.padding));\n arrowLocation.y = tipLocation.y = height / 2;\n if ((location.x + width + this.arrowPadding > boundsX + bounds.width) || (this.isNegative)) {\n location.x = (symbolLocation.x > bounds.width + bounds.x ? bounds.width : symbolLocation.x)\n + clipX - markerHeight - (width + this.arrowPadding);\n }\n if (location.x < boundsX) {\n location.x = (symbolLocation.x < 0 ? 0 : symbolLocation.x) + clipX + markerHeight;\n }\n if ((location.x + width + this.arrowPadding > boundsX + bounds.width)) {\n location.x = (symbolLocation.x > bounds.width + bounds.x ? bounds.width : symbolLocation.x)\n + clipX - markerHeight - (width + this.arrowPadding);\n }\n if (location.y <= boundsY) {\n arrowLocation.y -= (boundsY - location.y);\n tipLocation.y -= (boundsY - location.y);\n location.y = boundsY;\n }\n if (location.y + height >= boundsY + bounds.height) {\n arrowLocation.y += ((location.y + height) - (boundsY + bounds.height));\n tipLocation.y += ((location.y + height) - (boundsY + bounds.height));\n location.y -= ((location.y + height) - (boundsY + bounds.height));\n }\n if (arrowLocation.y + this.arrowPadding > height - this.ry) {\n arrowLocation.y = height - this.ry - this.arrowPadding;\n tipLocation.y = height;\n }\n if (arrowLocation.y - this.arrowPadding < this.ry) {\n arrowLocation.y = tipLocation.y = this.ry + this.arrowPadding;\n }\n if (this.controlName === 'Chart') {\n if ((location.y + arrowLocation.y) < this.areaMargin + this.arrowPadding ||\n ((bounds.y + bounds.height) - (location.y + arrowLocation.y)) < this.areaMargin + this.arrowPadding) {\n this.outOfBounds = true;\n }\n if (!withInAreaBounds(location.x, location.y, bounds) || this.outOfBounds) {\n this.inverted = !this.inverted;\n location = new TooltipLocation(symbolLocation.x + clipX - this.padding - this.elementSize.width / 2, symbolLocation.y + clipY - this.elementSize.height - (2 * this.padding) - markerHeight - this.arrowPadding);\n this.revert = true;\n tipLocation.x = arrowLocation.x = width / 2;\n tipLocation.y = arrowLocation.y = 0;\n if (location.y < boundsY || (this.isNegative)) {\n location.y = (symbolLocation.y < 0 ? 0 : symbolLocation.y) + markerHeight + clipY;\n }\n if (location.y + this.arrowPadding + height > boundsY + bounds.height) {\n location.y = Math.min(symbolLocation.y, boundsY + bounds.height) + clipY\n - this.elementSize.height - (2 * this.padding) - markerHeight - this.arrowPadding;\n }\n tipLocation.x = width / 2;\n if (location.x < boundsX) {\n tipLocation.x -= (boundsX - location.x);\n arrowLocation.x -= (boundsX - location.x);\n location.x = boundsX;\n }\n if (location.x + width > bounds.width + boundsX) {\n arrowLocation.x += ((location.x + width) - (bounds.width + boundsX));\n tipLocation.x += ((location.x + width) - (bounds.width + boundsX));\n location.x -= ((location.x + width) - (bounds.width + boundsX));\n }\n if ((this.arrowPadding) + arrowLocation.x > width - this.rx) {\n tipLocation.x = width - this.rx - (this.arrowPadding);\n arrowLocation.x = width - this.rx - (this.arrowPadding);\n }\n if (arrowLocation.x - (this.arrowPadding) < this.rx) {\n arrowLocation.x = tipLocation.x = this.rx + (this.arrowPadding);\n }\n }\n }\n }\n return new Rect(location.x, location.y, width, height);\n };\n Tooltip.prototype.animateTooltipDiv = function (tooltipDiv, rect) {\n var _this = this;\n var x = parseFloat(tooltipDiv.style.left);\n var y = parseFloat(tooltipDiv.style.top);\n var currenDiff;\n new Animation({}).animate(tooltipDiv, {\n duration: (this.duration === 0 && animationMode === 'Enable') ? 300 : this.duration,\n progress: function (args) {\n currenDiff = (args.timeStamp / args.duration);\n tooltipDiv.style.animation = null;\n if ((_this.controlName === 'Chart' && _this.shared) && !_this.enableRTL) {\n tooltipDiv.style.transition = isBlazor() ? 'transform 0.3s' : 'transform 0.1s';\n tooltipDiv.style.transform = 'translate(' + (x + currenDiff * (rect.x - x)) + 'px,' + (y + currenDiff * (rect.y - y)) + 'px)';\n tooltipDiv.style.left = '';\n tooltipDiv.style.top = '';\n }\n else {\n tooltipDiv.style.left = (x + currenDiff * (rect.x - x)) + 'px';\n tooltipDiv.style.top = (y + currenDiff * (rect.y - y)) + 'px';\n tooltipDiv.style.transform = _this.controlName === 'RangeNavigator' ? tooltipDiv.style.transform : '';\n }\n },\n end: function (model) {\n _this.updateDiv(tooltipDiv, rect.x, rect.y);\n _this.trigger('animationComplete', { tooltip: _this });\n }\n });\n };\n Tooltip.prototype.updateDiv = function (tooltipDiv, x, y) {\n if ((this.controlName === 'Chart' && this.shared && !this.crosshair) && !this.enableRTL) {\n tooltipDiv.style.transform = 'translate(' + x + 'px,' + y + 'px)';\n tooltipDiv.style.left = '';\n tooltipDiv.style.top = '';\n }\n else {\n tooltipDiv.style.left = x + 'px';\n tooltipDiv.style.top = y + 'px';\n tooltipDiv.style.transform = this.controlName === 'RangeNavigator' ? tooltipDiv.style.transform : '';\n }\n };\n Tooltip.prototype.updateTemplateFn = function () {\n if (this.template) {\n try {\n if (typeof this.template !== 'function' && document.querySelectorAll(this.template).length) {\n this.templateFn = templateComplier(document.querySelector(this.template).innerHTML.trim());\n }\n else {\n this.templateFn = templateComplier(this.template);\n }\n }\n catch (e) {\n this.templateFn = templateComplier(this.template);\n }\n }\n };\n /** @private */\n Tooltip.prototype.fadeOut = function () {\n var _this = this;\n var tooltipElement = (this.isCanvas && !this.template) ? getElement(this.element.id + '_svg') :\n getElement(this.element.id);\n var tooltipDiv = getElement(this.element.id);\n if (tooltipElement) {\n var tooltipGroup_1 = tooltipElement.firstChild;\n if (tooltipGroup_1.nodeType !== Node.ELEMENT_NODE) {\n tooltipGroup_1 = tooltipElement.firstElementChild;\n }\n if (this.isCanvas && !this.template) {\n tooltipGroup_1 = document.getElementById(this.element.id + '_group') ? document.getElementById(this.element.id + '_group') :\n tooltipGroup_1;\n }\n if (!tooltipGroup_1) {\n return null;\n }\n var opacity_1 = parseFloat(tooltipGroup_1.getAttribute('opacity'));\n opacity_1 = !isNullOrUndefined(opacity_1) ? opacity_1 : 1;\n new Animation({}).animate(tooltipGroup_1, {\n duration: 200,\n progress: function (args) {\n // tooltipGroup.removeAttribute('e-animate');\n _this.progressAnimation(tooltipGroup_1, opacity_1, (args.timeStamp / args.duration));\n },\n end: function () {\n _this.fadeOuted = true;\n _this.endAnimation(tooltipGroup_1);\n tooltipDiv.style.transition = '';\n }\n });\n }\n };\n Tooltip.prototype.progressAnimation = function (tooltipGroup, opacity, timeStamp) {\n tooltipGroup.style.animation = '';\n tooltipGroup.setAttribute('opacity', (opacity - timeStamp).toString());\n };\n /*\n * @hidden\n */\n Tooltip.prototype.endAnimation = function (tooltipGroup) {\n tooltipGroup.setAttribute('opacity', '0');\n if (this.template) {\n tooltipGroup.style.display = 'none';\n }\n this.trigger('animationComplete', { tooltip: this });\n };\n /**\n * Get the properties to be maintained in the persisted state.\n *\n * @private\n */\n Tooltip.prototype.getPersistData = function () {\n var keyEntity = [];\n return this.addOnPersist(keyEntity);\n };\n /**\n * Get component name\n *\n * @private\n */\n Tooltip.prototype.getModuleName = function () {\n return 'tooltip';\n };\n /**\n * To destroy the accumulationcharts\n *\n * @private\n */\n Tooltip.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n this.element.classList.remove('e-tooltip');\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @returns {void}\n * @private\n */\n Tooltip.prototype.onPropertyChanged = function (newProp, oldProp) {\n if (this.blazorTemplate) {\n resetBlazorTemplate(this.element.id + 'parent_template' + '_blazorTemplate');\n }\n this.isFirst = false;\n this.render();\n };\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"enable\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"shared\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"crosshair\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"enableShadow\", void 0);\n __decorate([\n Property(null)\n ], Tooltip.prototype, \"fill\", void 0);\n __decorate([\n Property('')\n ], Tooltip.prototype, \"header\", void 0);\n __decorate([\n Property(0.75)\n ], Tooltip.prototype, \"opacity\", void 0);\n __decorate([\n Complex({ size: '12px', fontWeight: null, color: null, fontStyle: 'Normal', fontFamily: null }, TextStyle)\n ], Tooltip.prototype, \"textStyle\", void 0);\n __decorate([\n Property(null)\n ], Tooltip.prototype, \"template\", void 0);\n __decorate([\n Property(true)\n ], Tooltip.prototype, \"enableAnimation\", void 0);\n __decorate([\n Property(300)\n ], Tooltip.prototype, \"duration\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"inverted\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"isNegative\", void 0);\n __decorate([\n Complex({ color: null, width: null }, TooltipBorder)\n ], Tooltip.prototype, \"border\", void 0);\n __decorate([\n Property([])\n ], Tooltip.prototype, \"content\", void 0);\n __decorate([\n Property(10)\n ], Tooltip.prototype, \"markerSize\", void 0);\n __decorate([\n Complex({ x: 0, y: 0 }, ToolLocation)\n ], Tooltip.prototype, \"clipBounds\", void 0);\n __decorate([\n Property([])\n ], Tooltip.prototype, \"palette\", void 0);\n __decorate([\n Property([])\n ], Tooltip.prototype, \"shapes\", void 0);\n __decorate([\n Complex({ x: 0, y: 0 }, ToolLocation)\n ], Tooltip.prototype, \"location\", void 0);\n __decorate([\n Property(0)\n ], Tooltip.prototype, \"offset\", void 0);\n __decorate([\n Property(4)\n ], Tooltip.prototype, \"rx\", void 0);\n __decorate([\n Property(4)\n ], Tooltip.prototype, \"ry\", void 0);\n __decorate([\n Property(5)\n ], Tooltip.prototype, \"marginX\", void 0);\n __decorate([\n Property(5)\n ], Tooltip.prototype, \"marginY\", void 0);\n __decorate([\n Property(7)\n ], Tooltip.prototype, \"arrowPadding\", void 0);\n __decorate([\n Property(null)\n ], Tooltip.prototype, \"data\", void 0);\n __decorate([\n Property('Material')\n ], Tooltip.prototype, \"theme\", void 0);\n __decorate([\n Complex({ x: 0, y: 0, width: 0, height: 0 }, AreaBounds)\n ], Tooltip.prototype, \"areaBounds\", void 0);\n __decorate([\n Property(null)\n ], Tooltip.prototype, \"availableSize\", void 0);\n __decorate([\n Property()\n ], Tooltip.prototype, \"blazorTemplate\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"isCanvas\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"isTextWrap\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"isFixed\", void 0);\n __decorate([\n Property(null)\n ], Tooltip.prototype, \"tooltipPlacement\", void 0);\n __decorate([\n Property(null)\n ], Tooltip.prototype, \"controlInstance\", void 0);\n __decorate([\n Property('')\n ], Tooltip.prototype, \"controlName\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"tooltipRender\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"loaded\", void 0);\n __decorate([\n Event()\n ], Tooltip.prototype, \"animationComplete\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"enableRTL\", void 0);\n __decorate([\n Property(false)\n ], Tooltip.prototype, \"allowHighlight\", void 0);\n Tooltip = __decorate([\n NotifyPropertyChanges\n ], Tooltip);\n return Tooltip;\n}(Component));\nexport { Tooltip };\n","//! moment.js locale configuration\n//! locale : Urdu [ur]\n//! author : Sawood Alam : https://github.com/ibnesayeed\n//! author : Zack : https://github.com/ZackVision\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var months = [\n 'جنوری',\n 'Ùروری',\n 'مارچ',\n 'اپریل',\n 'مئی',\n 'جون',\n 'جولائی',\n 'اگست',\n 'ستمبر',\n 'اکتوبر',\n 'نومبر',\n 'دسمبر',\n ],\n days = ['اتوار', 'پیر', 'منگل', 'بدھ', 'جمعرات', 'جمعÛ', 'ÛÙتÛ'];\n\n var ur = moment.defineLocale('ur', {\n months: months,\n monthsShort: months,\n weekdays: days,\n weekdaysShort: days,\n weekdaysMin: days,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'ddddØŒ D MMMM YYYY HH:mm',\n },\n meridiemParse: /صبØ|شام/,\n isPM: function (input) {\n return 'شام' === input;\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'صبØ';\n }\n return 'شام';\n },\n calendar: {\n sameDay: '[آج بوقت] LT',\n nextDay: '[Ú©Ù„ بوقت] LT',\n nextWeek: 'dddd [بوقت] LT',\n lastDay: '[Ú¯Ø°Ø´ØªÛ Ø±ÙˆØ² بوقت] LT',\n lastWeek: '[گذشتÛ] dddd [بوقت] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s بعد',\n past: '%s قبل',\n s: 'چند سیکنڈ',\n ss: '%d سیکنڈ',\n m: 'ایک منٹ',\n mm: '%d منٹ',\n h: 'ایک گھنٹÛ',\n hh: '%d گھنٹے',\n d: 'ایک دن',\n dd: '%d دن',\n M: 'ایک ماÛ',\n MM: '%d ماÛ',\n y: 'ایک سال',\n yy: '%d سال',\n },\n preparse: function (string) {\n return string.replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string.replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return ur;\n\n})));\n","//! moment.js locale configuration\n//! locale : siSwati [ss]\n//! author : Nicolai Davies<mail@nicolai.io> : https://github.com/nicolaidavies\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ss = moment.defineLocale('ss', {\n months: \"Bhimbidvwane_Indlovana_Indlov'lenkhulu_Mabasa_Inkhwekhweti_Inhlaba_Kholwane_Ingci_Inyoni_Imphala_Lweti_Ingongoni\".split(\n '_'\n ),\n monthsShort: 'Bhi_Ina_Inu_Mab_Ink_Inh_Kho_Igc_Iny_Imp_Lwe_Igo'.split('_'),\n weekdays:\n 'Lisontfo_Umsombuluko_Lesibili_Lesitsatfu_Lesine_Lesihlanu_Umgcibelo'.split(\n '_'\n ),\n weekdaysShort: 'Lis_Umb_Lsb_Les_Lsi_Lsh_Umg'.split('_'),\n weekdaysMin: 'Li_Us_Lb_Lt_Ls_Lh_Ug'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY h:mm A',\n LLLL: 'dddd, D MMMM YYYY h:mm A',\n },\n calendar: {\n sameDay: '[Namuhla nga] LT',\n nextDay: '[Kusasa nga] LT',\n nextWeek: 'dddd [nga] LT',\n lastDay: '[Itolo nga] LT',\n lastWeek: 'dddd [leliphelile] [nga] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'nga %s',\n past: 'wenteka nga %s',\n s: 'emizuzwana lomcane',\n ss: '%d mzuzwana',\n m: 'umzuzu',\n mm: '%d emizuzu',\n h: 'lihora',\n hh: '%d emahora',\n d: 'lilanga',\n dd: '%d emalanga',\n M: 'inyanga',\n MM: '%d tinyanga',\n y: 'umnyaka',\n yy: '%d iminyaka',\n },\n meridiemParse: /ekuseni|emini|entsambama|ebusuku/,\n meridiem: function (hours, minutes, isLower) {\n if (hours < 11) {\n return 'ekuseni';\n } else if (hours < 15) {\n return 'emini';\n } else if (hours < 19) {\n return 'entsambama';\n } else {\n return 'ebusuku';\n }\n },\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'ekuseni') {\n return hour;\n } else if (meridiem === 'emini') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === 'entsambama' || meridiem === 'ebusuku') {\n if (hour === 0) {\n return 0;\n }\n return hour + 12;\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}/,\n ordinal: '%d',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return ss;\n\n})));\n","/* eslint-disable @typescript-eslint/tslint/config */\n/* eslint-disable max-len */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable jsdoc/require-param */\nimport { Animation, animationMode, isNullOrUndefined, remove } from '@syncfusion/ej2-base';\nimport { DoubleRange } from '../utils/double-range';\nimport { appendChildElement, redrawElement, pathAnimation, valueToCoefficient, getVisiblePoints, colorNameToHex, checkColorFormat, applyZLight } from '../../common/utils/helper';\nimport { getAnimationFunction, getPoint, getMinPointsDelta } from '../../common/utils/helper';\nimport { PathOption, Rect } from '@syncfusion/ej2-svg-base';\nimport { pointRender } from '../../common/model/constants';\n/**\n * Column Series Base\n */\nvar ColumnBase = /** @class */ (function () {\n function ColumnBase() {\n }\n ColumnBase.prototype.getSideBySideInfo = function (series) {\n if (series.chart.enableSideBySidePlacement && !series.position) {\n this.getSideBySidePositions(series);\n }\n if (series.columnWidthInPixel) {\n return new DoubleRange(0, 0);\n }\n var position = series.type === 'Histogram' || !series.chart.enableSideBySidePlacement ? 0 : series.position;\n var rectCount = series.type === 'Histogram' || !series.chart.enableSideBySidePlacement ? 1 : series.rectCount;\n series.isRectSeries = true;\n var visibleSeries = series.chart.visibleSeries;\n var seriesSpacing = series.chart.enableSideBySidePlacement ? series.columnSpacing : 0; // Column Spacing\n var pointSpacing = (series.columnWidth === null || isNaN(+series.columnWidth)) ? ((series.type === 'Histogram') ? 1 : 0.7) :\n Math.min(series.columnWidth, 1); // Column width\n var minimumPointDelta = getMinPointsDelta(series.xAxis, visibleSeries);\n var width = minimumPointDelta * pointSpacing;\n var radius;\n var location = (position) / rectCount - 0.5;\n var doubleRange = new DoubleRange(location, location + (1 / rectCount));\n if (!(isNaN(doubleRange.start) || isNaN(doubleRange.end))) {\n if (series.groupName && series.type.indexOf('Stacking') === -1) {\n var mainColumnWidth_1 = 0.7;\n series.chart.series.filter(function (series) { if (series.columnWidth > mainColumnWidth_1) {\n mainColumnWidth_1 = series.columnWidth;\n } });\n var mainWidth = minimumPointDelta * mainColumnWidth_1;\n var mainDoubleRange = new DoubleRange(doubleRange.start * mainWidth, doubleRange.end * mainWidth);\n var difference = ((mainDoubleRange.delta) - (doubleRange.end * width - doubleRange.start * width)) / 2;\n doubleRange = new DoubleRange(mainDoubleRange.start + difference, mainDoubleRange.end - difference);\n }\n else {\n doubleRange = new DoubleRange(doubleRange.start * width, doubleRange.end * width);\n }\n radius = seriesSpacing * doubleRange.delta;\n doubleRange = new DoubleRange(doubleRange.start + radius / 2, doubleRange.end - radius / 2);\n }\n return doubleRange;\n };\n /**\n * To get the rect values.\n *\n * @returns {Rect} rect region values\n * @private\n */\n ColumnBase.prototype.getRectangle = function (x1, y1, x2, y2, series) {\n var point1 = getPoint(x1, y1, series.xAxis, series.yAxis, series.chart.requireInvertedAxis);\n var point2 = getPoint(x2, y2, series.xAxis, series.yAxis, series.chart.requireInvertedAxis);\n return new Rect(Math.min(point1.x, point2.x), Math.min(point1.y, point2.y), Math.abs(point2.x - point1.x), Math.abs(point2.y - point1.y));\n };\n /**\n * To draw the cylindrical shape for points.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.drawCylinder = function (options, element, cylinderSeriesOption, rect, series) {\n var width = rect.width;\n var height = rect.height;\n if (series.chart.enableCanvas) {\n var ctx = series.chart.canvasRender.ctx;\n var canvasCtx = ctx;\n ctx.save();\n var gradientColor = colorNameToHex(options.fill);\n var x = rect.x + series.clipRect.x;\n var y = rect.y + series.clipRect.y;\n var arc = 2 * Math.PI + 0.1;\n var rx = void 0, ry = void 0, cx1 = void 0, cx2 = void 0, cy1 = void 0, cy2 = void 0, x1 = void 0, x2 = void 0, y1 = void 0, y2 = void 0, cx = void 0, cy = void 0, xl = void 0, yl = void 0, xPos = void 0, yPos = void 0, step = void 0, rxt = void 0, ryt = void 0;\n var gx1 = 0;\n var gx2 = 0;\n var gy1 = 0;\n var gy2 = 0;\n var ini = 0;\n ctx.fillStyle = applyZLight(gradientColor, 0.9);\n ctx.lineWidth = 0;\n ctx.strokeStyle = applyZLight(gradientColor, 0.9);\n ctx.globalAlpha = options.opacity;\n if (cylinderSeriesOption.isColumn) {\n gx1 = x;\n gx2 = width + x;\n rx = width / 2;\n ry = rx / 4;\n cx2 = cx1 = x + rx;\n y2 = cy1 = y - ry;\n x2 = x;\n x1 = x + width;\n cy2 = y1 = y + height - ry;\n step = Math.PI;\n rxt = -rx;\n ryt = ry;\n if (cylinderSeriesOption.stacking) {\n if (!cylinderSeriesOption.isLastSeries) {\n y2 = cy1 = y + ry;\n }\n }\n }\n else {\n gy2 = height + y;\n gy1 = y;\n ry = height / 2;\n rx = ry / 4;\n x2 = cx1 = x + rx;\n x1 = cx2 = x + width + rx;\n y1 = y + height;\n y2 = y;\n cy2 = cy1 = y + ry;\n ini = Math.PI / 2;\n step = Math.PI * 1.5;\n if (cylinderSeriesOption.stacking) {\n if (!cylinderSeriesOption.isLastSeries) {\n x1 = cx2 = x + width - rx;\n }\n }\n ry = -ry;\n rx = -rx;\n rxt = rx;\n ryt = -ry;\n }\n var color = applyZLight(gradientColor, 0.7);\n var gradient = ctx.createLinearGradient(gx1, gy1, gx2, gy2);\n gradient.addColorStop(0, gradientColor);\n gradient.addColorStop(0.3, color);\n gradient.addColorStop(0.7, color);\n gradient.addColorStop(1, gradientColor);\n for (var j = 1; j <= 4; j++) {\n var i = 0;\n if (j < 4) {\n ctx.beginPath();\n }\n if (j % 2 === 0) {\n cx = cx2;\n cy = cy2;\n xl = x2;\n yl = y2;\n }\n else {\n cx = cx1;\n cy = cy1;\n xl = x1;\n yl = y1;\n }\n if (j === 4) {\n rx = rxt;\n ry = ryt;\n ctx.fillStyle = gradient;\n }\n if (j > 2) {\n i = ini;\n arc = step;\n }\n for (; i <= arc; i += 0.1) {\n xPos = cx - (rx * Math.cos(i));\n yPos = cy + (ry * Math.sin(i));\n if (i === 0) {\n ctx.moveTo(xPos, yPos);\n }\n else {\n ctx.lineTo(xPos, yPos);\n }\n }\n if (j > 2) {\n ctx.lineTo(xl, yl);\n }\n if (j !== 3) {\n ctx.stroke();\n ctx.fill();\n }\n }\n if (options.id.indexOf('Series') >= 0) {\n ctx.clip();\n ctx.restore();\n ctx = canvasCtx;\n }\n }\n else {\n var chart = series.chart;\n var x = rect.x;\n var y = rect.y;\n var id = options.id;\n var gradientColor = options.fill;\n var fillColor = gradientColor;\n var format = checkColorFormat(gradientColor);\n if (!format) {\n gradientColor = colorNameToHex(gradientColor);\n }\n var AEx = 0;\n var AEy = 0;\n var LX = 0;\n var LY = 0;\n var GX = 0;\n var GY = 0;\n var X = void 0, Y = void 0, X1 = void 0, Y1 = void 0, X2 = void 0, Y2 = void 0, rx = void 0, ry = void 0;\n var i = 2;\n if (cylinderSeriesOption.isColumn) {\n rx = width / 2;\n ry = rx / 4;\n X = X1 = x;\n Y = ry < y ? y - ry : cylinderSeriesOption.stacking ? y + ry : (y - ry);\n Y1 = Y;\n AEx = 2 * rx;\n LY = ry < y ? height : (height < 2 * ry ? height : cylinderSeriesOption.stacking ? height - (2 * ry) : height);\n X2 = X;\n Y2 = ry < y ? Y + height : (height < Y ? height + Y : cylinderSeriesOption.stacking ? height + (y - ry) : height + Y);\n GX = 100;\n if (cylinderSeriesOption.stacking) {\n if (!cylinderSeriesOption.isLastSeries) {\n Y = Y1 = y + ry;\n LY = height < rx / 2 ? height : height - rx / 2;\n }\n }\n }\n else {\n ry = height / 2;\n rx = ry / 4;\n Y = Y1 = y;\n X = X1 = Math.abs(x - rx);\n AEy = 2 * ry;\n LX = width;\n X2 = X + width;\n Y2 = Y;\n GY = 100;\n if (cylinderSeriesOption.stacking) {\n if (!cylinderSeriesOption.isLastSeries) {\n X2 = (X + width - rx * 2);\n LX = width - rx * 2;\n }\n }\n }\n remove(this.element);\n while (i--) {\n options.d = 'M' + X.toString() + ',' + Y.toString() + 'a' + rx.toString() + ',' + ry.toString() + ' 0 1,0 ' + AEx.toString() + ',' + AEy.toString() + 'a' + rx.toString() + ',' + ry.toString() + ' 0 1,0 ' + (-1 * AEx).toString() + ',' + (-1 * AEy).toString();\n options.id = id + '_' + 'Region_' + i;\n options.fill = applyZLight(gradientColor, 0.9);\n if (i % 2 === 0 && series.type !== 'StackingBar100' && series.type !== 'StackingBar' && series.type !== 'Bar') {\n options.fill = options.fill + '10';\n }\n this.element = chart.renderer.drawPath(this.options, new Int32Array([series.clipRect.x, series.clipRect.y]));\n appendChildElement(series.chart.enableCanvas, series.seriesElement, this.element, chart.redraw);\n X = X2;\n Y = Y2;\n }\n options.d = 'M' + X1.toString() + ',' + Y1.toString() + 'a' + rx.toString() + ',' + ry.toString() + ' 0 1,0 ' + AEx.toString() + ',' + AEy.toString() + 'l' + LX.toString() + ' ' + LY.toString() + 'a' + rx.toString() + ',' + ry.toString() + ' 0 1,1 ' + (-1 * AEx).toString() + ',' + (-1 * AEy).toString() + ' z';\n options.id = id + '_' + 'Region_2';\n options.fill = applyZLight(gradientColor, 0.7);\n var optiong = void 0;\n if (fillColor.indexOf('url') === -1) {\n if (!document.getElementById(id)) {\n optiong = { 'id': id, x1: '0%', y1: '0%', x2: GX.toString() + '%', y2: GY.toString() + '%' };\n var gradientElement = [{ colorStop: '0%', color: gradientColor }, { colorStop: '30%', color: applyZLight(gradientColor, 0.7) }, { colorStop: '70%', color: applyZLight(gradientColor, 0.7) }, { colorStop: '100%', color: gradientColor }];\n this.drawGradient(optiong, gradientElement, series);\n }\n options.fill = 'url(#' + optiong.id + ')';\n }\n this.element = chart.renderer.drawPath(this.options, new Int32Array([series.clipRect.x, series.clipRect.y]));\n appendChildElement(series.chart.enableCanvas, series.seriesElement, this.element, chart.redraw);\n }\n };\n /**\n * To get the gradient of each points.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.drawGradient = function (optiong, gradientElement, series) {\n var chart = series.chart;\n var defElement = chart.renderer.createDefs();\n var xmlns = 'http://www.w3.org/2000/svg';\n var linearGradientElement = document.createElementNS(xmlns, 'linearGradient');\n linearGradientElement.setAttribute('id', optiong.id);\n linearGradientElement.setAttribute('x1', optiong.x1);\n linearGradientElement.setAttribute('y1', optiong.y1);\n linearGradientElement.setAttribute('x2', optiong.x2);\n linearGradientElement.setAttribute('y2', optiong.y2);\n for (var i = 0; i < gradientElement.length; i++) {\n var stopElement = document.createElementNS(xmlns, 'stop');\n stopElement.setAttribute('offset', gradientElement[i].colorStop);\n stopElement.setAttribute('stop-color', gradientElement[i].color);\n stopElement.setAttribute('stop-opacity', '1');\n linearGradientElement.appendChild(stopElement);\n }\n series.seriesElement.appendChild(defElement);\n defElement.appendChild(linearGradientElement);\n };\n /**\n * To get the position of each series.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.getSideBySidePositions = function (series) {\n var chart = series.chart;\n for (var _i = 0, _a = chart.columns; _i < _a.length; _i++) {\n var columnItem = _a[_i];\n for (var _b = 0, _c = chart.rows; _b < _c.length; _b++) {\n var item = _c[_b];\n this.findRectPosition(series.findSeriesCollection(columnItem, item, false));\n }\n }\n };\n ColumnBase.prototype.findRectPosition = function (seriesCollection) {\n var groupingValues = [];\n var vSeries = { rectCount: 0, position: null };\n for (var i = 0; i < seriesCollection.length; i++) {\n var value = seriesCollection[i];\n if (value.type.indexOf('Stacking') !== -1 || value.groupName !== '') {\n var groupName = value.type.indexOf('Stacking') !== -1 ? value.stackingGroup : value.type + value.groupName;\n if (groupName) {\n if (groupingValues[groupName] === undefined) {\n value.position = vSeries.rectCount;\n groupingValues[groupName] = vSeries.rectCount++;\n }\n else {\n value.position = groupingValues[groupName];\n }\n }\n else {\n if (vSeries.position === null) {\n value.position = vSeries.rectCount;\n vSeries.position = vSeries.rectCount++;\n }\n else {\n value.position = vSeries.position;\n }\n }\n }\n else {\n value.position = vSeries.rectCount++;\n }\n }\n for (var i = 0; i < seriesCollection.length; i++) {\n var value = seriesCollection[i];\n value.rectCount = vSeries.rectCount;\n }\n };\n /**\n * Updates the symbollocation for points\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.updateSymbolLocation = function (point, rect, series) {\n if (!series.chart.requireInvertedAxis) {\n this.updateXRegion(point, rect, series);\n }\n else {\n this.updateYRegion(point, rect, series);\n }\n if (series.type === 'Histogram') {\n point.minimum = +point.x - series.histogramValues.binWidth / 2;\n point.maximum = +point.x + series.histogramValues.binWidth / 2;\n }\n };\n /**\n * Update the region for the point.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.updateXRegion = function (point, rect, series) {\n point.symbolLocations.push({\n x: rect.x + (rect.width) / 2,\n y: (series.seriesType === 'BoxPlot' || series.seriesType.indexOf('HighLow') !== -1 ||\n (point.yValue >= 0 === !series.yAxis.isAxisInverse)) ? rect.y : (rect.y + rect.height)\n });\n this.getRegion(point, rect, series);\n if (series.type === 'RangeColumn') {\n point.symbolLocations.push({\n x: rect.x + (rect.width) / 2,\n y: rect.y + rect.height\n });\n }\n };\n /**\n * Update the region for the point in bar series.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.updateYRegion = function (point, rect, series) {\n point.symbolLocations.push({\n x: (series.seriesType === 'BoxPlot' || series.seriesType.indexOf('HighLow') !== -1 ||\n (point.yValue >= 0 === !series.yAxis.isAxisInverse)) ? rect.x + rect.width : rect.x,\n y: rect.y + rect.height / 2\n });\n this.getRegion(point, rect, series);\n if (series.type === 'RangeColumn') {\n point.symbolLocations.push({\n x: rect.x,\n y: rect.y + rect.height / 2\n });\n }\n };\n /**\n * To render the marker for the series.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.renderMarker = function (series) {\n if (series.marker && series.marker.visible) {\n series.chart.markerRender.render(series);\n }\n };\n /**\n * To get the marker region when Y value is 0\n *\n * @param {Points} point point\n * @param {rect} rect rect\n * @param {Series} series series\n */\n ColumnBase.prototype.getRegion = function (point, rect, series) {\n if (point.y === 0) {\n var markerWidth = (series.marker && series.marker.width) ? series.marker.width : 0;\n var markerHeight = (series.marker && series.marker.height) ? series.marker.height : 0;\n point.regions.push(new Rect(point.symbolLocations[0].x - markerWidth, point.symbolLocations[0].y - markerHeight, 2 * markerWidth, 2 * markerHeight));\n }\n else {\n point.regions.push(rect);\n }\n };\n /**\n * To trigger the point rendering event.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.triggerEvent = function (series, point, fill, border) {\n var argsData = {\n cancel: false, name: pointRender, series: series, point: point,\n fill: series.setPointColor(point, fill),\n border: series.setBorderColor(point, border)\n };\n series.chart.trigger(pointRender, argsData);\n point.color = argsData.fill;\n return argsData;\n };\n /**\n * To draw the rectangle for points.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.drawRectangle = function (series, point, rect, argsData) {\n var chart = series.chart;\n var check = chart.requireInvertedAxis ? rect.height : rect.width;\n if (check <= 0) {\n return null;\n }\n var direction;\n if (point.y === 0) {\n // For 0 values corner radius will not calculate\n direction = this.calculateRoundedRectPath(rect, 0, 0, 0, 0);\n }\n else {\n direction = this.calculateRoundedRectPath(rect, series.cornerRadius.topLeft, series.cornerRadius.topRight, series.cornerRadius.bottomLeft, series.cornerRadius.bottomRight, chart.requireInvertedAxis);\n }\n var name = series.category === 'Indicator' ? chart.element.id + '_Indicator_' + series.index + '_' + series.name +\n '_Point_' + point.index : chart.element.id + '_Series_' + series.index + '_Point_' + point.index;\n var previousElement = redrawElement(chart.redraw, name);\n var previousDirection = previousElement ? previousElement.getAttribute('d') : '';\n this.options = new PathOption(name, argsData.fill, argsData.border.width, argsData.border.color, series.opacity, series.dashArray, (series.columnFacet === 'Cylinder') ? '' : direction);\n this.element = chart.renderer.drawPath(this.options, new Int32Array([series.clipRect.x, series.clipRect.y]));\n switch (series.seriesType) {\n case 'XY':\n this.element.setAttribute('role', 'img');\n this.element.setAttribute('aria-label', point.x + ':' + point.yValue + ', ' + series.name);\n break;\n case 'HighLow':\n this.element.setAttribute('role', 'img');\n this.element.setAttribute('aria-label', point.x + ':' + point.high + ', ' + point.low + ', ' + series.name);\n break;\n }\n appendChildElement(series.chart.enableCanvas, series.seriesElement, this.element, chart.redraw);\n if (!series.chart.enableCanvas) {\n pathAnimation(this.element, (series.columnFacet === 'Cylinder') ? '' : direction, chart.redraw, previousDirection, chart.duration);\n }\n };\n /**\n * To animate the series.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.animate = function (series) {\n var rectElements = series.seriesElement.childNodes;\n var count = series.category === 'Indicator' ? 0 : 1;\n var visiblePoints = getVisiblePoints(series);\n for (var _i = 0, visiblePoints_1 = visiblePoints; _i < visiblePoints_1.length; _i++) {\n var point = visiblePoints_1[_i];\n if (!point.symbolLocations.length && !(series.type === 'BoxAndWhisker' && point.regions.length)) {\n continue;\n }\n if ((series.type === 'Column' || series.type === 'Bar' || series.type === 'StackingColumn' || series.type === 'StackingColumn100' || series.type === 'StackingBar' || series.type === 'StackingBar100') && series.columnFacet === 'Cylinder') {\n for (var j = 0; j < rectElements.length; j++) {\n this.animateRect(rectElements[j], series, point);\n }\n }\n else {\n this.animateRect(rectElements[count], series, point);\n count++;\n }\n }\n };\n /**\n * To animate the series.\n *\n * @returns {void}\n * @private\n */\n ColumnBase.prototype.animateRect = function (element, series, point) {\n var option = series.animation;\n var duration = series.chart.animated ? series.chart.duration : option.duration;\n var effect = getAnimationFunction('Linear');\n var isPlot = point.yValue < 0;\n var x;\n var y;\n var elementHeight = +point.regions[0].height;\n var elementWidth = +point.regions[0].width;\n var centerX;\n var centerY;\n if (!series.chart.requireInvertedAxis) {\n x = +point.regions[0].x;\n if (series.type.indexOf('Stacking') > -1) {\n y = (1 - valueToCoefficient(0, series.yAxis)) * (series.yAxis.rect.height);\n centerX = x;\n centerY = y;\n }\n else {\n y = +point.regions[0].y;\n centerY = (series.seriesType.indexOf('HighLow') !== -1 || series.type.indexOf('Waterfall') !== -1) ? y + elementHeight / 2 :\n (isPlot !== series.yAxis.isAxisInverse) ? y : y + elementHeight;\n centerX = isPlot ? x : x + elementWidth;\n }\n }\n else {\n y = +point.regions[0].y;\n if (series.type.indexOf('Stacking') > -1) {\n x = (valueToCoefficient(0, series.yAxis)) * series.yAxis.rect.width;\n centerX = x;\n centerY = y;\n }\n else {\n x = +point.regions[0].x;\n centerY = isPlot ? y : y + elementHeight;\n centerX = (series.seriesType.indexOf('HighLow') !== -1 || series.type.indexOf('Waterfall') !== -1) ? x + elementWidth / 2 :\n (isPlot !== series.yAxis.isAxisInverse) ? x + elementWidth : x;\n }\n }\n var value;\n if (!isNullOrUndefined(element)) {\n element.style.visibility = 'hidden';\n new Animation({}).animate(element, {\n duration: (duration === 0 && animationMode === 'Enable') ? 1000 : duration,\n delay: option.delay,\n progress: function (args) {\n if (args.timeStamp >= args.delay) {\n element.style.visibility = 'visible';\n if (!series.chart.requireInvertedAxis) {\n elementHeight = elementHeight ? elementHeight : 1;\n value = effect(args.timeStamp - args.delay, 0, elementHeight, args.duration);\n element.setAttribute('transform', 'translate(' + centerX + ' ' + centerY +\n ') scale(1,' + (value / elementHeight) + ') translate(' + (-centerX) + ' ' + (-centerY) + ')');\n }\n else {\n elementWidth = elementWidth ? elementWidth : 1;\n value = effect(args.timeStamp - args.delay, 0, elementWidth, args.duration);\n element.setAttribute('transform', 'translate(' + centerX + ' ' + centerY +\n ') scale(' + (value / elementWidth) + ', 1) translate(' + (-centerX) + ' ' + (-centerY) + ')');\n }\n }\n },\n end: function () {\n element.setAttribute('transform', 'translate(0,0)');\n var seriesElement = series.seriesElement;\n if (element === seriesElement.lastElementChild || point.index === series.points.length - 1 ||\n (series.type === 'Waterfall' && element === seriesElement.children[seriesElement.childElementCount - 2])) {\n series.chart.trigger('animationComplete', { series: series.chart.isBlazor ? {} : series });\n if (series.type === 'Waterfall') {\n var rectElements = seriesElement.childNodes;\n for (var i = 0; i < rectElements.length; i++) {\n if (rectElements[i].id.indexOf('Connector') !== -1) {\n rectElements[i].style.visibility = 'visible';\n rectElements[i].setAttribute('transform', 'translate(0,0)');\n }\n }\n }\n }\n }\n });\n }\n };\n /**\n * To get rounded rect path direction.\n */\n ColumnBase.prototype.calculateRoundedRectPath = function (rect, topLeft, topRight, bottomLeft, bottomRight, inverted) {\n if (inverted === void 0) { inverted = false; }\n var halfValue = inverted ? rect.width / 2 : rect.height / 2;\n topLeft = Math.min(topLeft, halfValue);\n topRight = Math.min(topRight, halfValue);\n bottomLeft = Math.min(bottomLeft, halfValue);\n bottomRight = Math.min(bottomRight, halfValue);\n return 'M' + ' ' + rect.x + ' ' + (topLeft + rect.y) +\n ' Q ' + rect.x + ' ' + rect.y + ' ' + (rect.x + topLeft) + ' ' +\n rect.y + ' ' + 'L' + ' ' + (rect.x + rect.width - topRight) + ' ' + rect.y +\n ' Q ' + (rect.x + rect.width) + ' ' + rect.y + ' ' +\n (rect.x + rect.width) + ' ' + (rect.y + topRight) + ' ' + 'L ' +\n (rect.x + rect.width) + ' ' + (rect.y + rect.height - bottomRight)\n + ' Q ' + (rect.x + rect.width) + ' ' + (rect.y + rect.height) + ' ' + (rect.x + rect.width - bottomRight) + ' ' +\n (rect.y + rect.height) + ' ' + 'L ' + (rect.x + bottomLeft) + ' ' + (rect.y + rect.height) + ' Q ' + rect.x + ' ' +\n (rect.y + rect.height) + ' ' + rect.x + ' ' + (rect.y + rect.height - bottomLeft) + ' ' + 'L' + ' ' + rect.x + ' ' +\n (topLeft + rect.y) + ' ' + 'Z';\n };\n return ColumnBase;\n}());\nexport { ColumnBase };\n","//! moment.js locale configuration\n//! locale : Spanish (United States) [es-us]\n//! author : bustta : https://github.com/bustta\n//! author : chrisrodz : https://github.com/chrisrodz\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsShortDot =\n 'ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.'.split(\n '_'\n ),\n monthsShort = 'ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic'.split('_'),\n monthsParse = [\n /^ene/i,\n /^feb/i,\n /^mar/i,\n /^abr/i,\n /^may/i,\n /^jun/i,\n /^jul/i,\n /^ago/i,\n /^sep/i,\n /^oct/i,\n /^nov/i,\n /^dic/i,\n ],\n monthsRegex =\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i;\n\n var esUs = moment.defineLocale('es-us', {\n months: 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split(\n '_'\n ),\n monthsShort: function (m, format) {\n if (!m) {\n return monthsShortDot;\n } else if (/-MMM-/.test(format)) {\n return monthsShort[m.month()];\n } else {\n return monthsShortDot[m.month()];\n }\n },\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex:\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,\n monthsShortStrictRegex:\n /^(ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i,\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n weekdays: 'domingo_lunes_martes_miércoles_jueves_viernes_sábado'.split('_'),\n weekdaysShort: 'dom._lun._mar._mié._jue._vie._sáb.'.split('_'),\n weekdaysMin: 'do_lu_ma_mi_ju_vi_sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'MM/DD/YYYY',\n LL: 'D [de] MMMM [de] YYYY',\n LLL: 'D [de] MMMM [de] YYYY h:mm A',\n LLLL: 'dddd, D [de] MMMM [de] YYYY h:mm A',\n },\n calendar: {\n sameDay: function () {\n return '[hoy a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextDay: function () {\n return '[mañana a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextWeek: function () {\n return 'dddd [a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastDay: function () {\n return '[ayer a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastWeek: function () {\n return (\n '[el] dddd [pasado a la' +\n (this.hours() !== 1 ? 's' : '') +\n '] LT'\n );\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'en %s',\n past: 'hace %s',\n s: 'unos segundos',\n ss: '%d segundos',\n m: 'un minuto',\n mm: '%d minutos',\n h: 'una hora',\n hh: '%d horas',\n d: 'un dÃa',\n dd: '%d dÃas',\n w: 'una semana',\n ww: '%d semanas',\n M: 'un mes',\n MM: '%d meses',\n y: 'un año',\n yy: '%d años',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return esUs;\n\n})));\n","//! moment.js locale configuration\n//! locale : Tetun Dili (East Timor) [tet]\n//! author : Joshua Brooks : https://github.com/joshbrooks\n//! author : Onorio De J. Afonso : https://github.com/marobo\n//! author : Sonia Simoes : https://github.com/soniasimoes\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var tet = moment.defineLocale('tet', {\n months: 'Janeiru_Fevereiru_Marsu_Abril_Maiu_Juñu_Jullu_Agustu_Setembru_Outubru_Novembru_Dezembru'.split(\n '_'\n ),\n monthsShort: 'Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez'.split('_'),\n weekdays: 'Domingu_Segunda_Tersa_Kuarta_Kinta_Sesta_Sabadu'.split('_'),\n weekdaysShort: 'Dom_Seg_Ters_Kua_Kint_Sest_Sab'.split('_'),\n weekdaysMin: 'Do_Seg_Te_Ku_Ki_Ses_Sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Ohin iha] LT',\n nextDay: '[Aban iha] LT',\n nextWeek: 'dddd [iha] LT',\n lastDay: '[Horiseik iha] LT',\n lastWeek: 'dddd [semana kotuk] [iha] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'iha %s',\n past: '%s liuba',\n s: 'segundu balun',\n ss: 'segundu %d',\n m: 'minutu ida',\n mm: 'minutu %d',\n h: 'oras ida',\n hh: 'oras %d',\n d: 'loron ida',\n dd: 'loron %d',\n M: 'fulan ida',\n MM: 'fulan %d',\n y: 'tinan ida',\n yy: 'tinan %d',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return tet;\n\n})));\n","//! moment.js locale configuration\n//! locale : Maldivian [dv]\n//! author : Jawish Hameed : https://github.com/jawish\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var months = [\n 'Þ–Þ¬Þ‚ÞªÞ‡Þ¦ÞƒÞ©',\n 'ÞŠÞ¬Þ„Þ°ÞƒÞªÞ‡Þ¦ÞƒÞ©',\n 'Þ‰Þ§ÞƒÞ¨Þ—Þª',\n 'Þ‡ÞÞ•Þ°ÞƒÞ©ÞÞª',\n 'Þ‰Þ',\n 'Þ–Þ«Þ‚Þ°',\n 'Þ–ÞªÞÞ¦Þ‡Þ¨',\n 'Þ‡Þ¯ÞŽÞ¦ÞÞ°Þ“Þª',\n 'ÞÞ¬Þ•Þ°Þ“Þ¬Þ‰Þ°Þ„Þ¦ÞƒÞª',\n 'Þ‡Þ®Þ†Þ°Þ“Þ¯Þ„Þ¦ÞƒÞª',\n 'Þ‚Þ®ÞˆÞ¬Þ‰Þ°Þ„Þ¦ÞƒÞª',\n 'Þ‘Þ¨ÞÞ¬Þ‰Þ°Þ„Þ¦ÞƒÞª',\n ],\n weekdays = [\n 'އާދިއްތަ',\n 'Þ€Þ¯Þ‰Þ¦',\n 'Þ‡Þ¦Þ‚Þ°ÞŽÞ§ÞƒÞ¦',\n 'Þ„ÞªÞ‹Þ¦',\n 'Þ„ÞªÞƒÞ§Þްފަތި',\n 'Þ€ÞªÞ†ÞªÞƒÞª',\n 'Þ€Þ®Þ‚Þ¨Þ€Þ¨ÞƒÞª',\n ];\n\n var dv = moment.defineLocale('dv', {\n months: months,\n monthsShort: months,\n weekdays: weekdays,\n weekdaysShort: weekdays,\n weekdaysMin: 'Þ‡Þ§Þ‹Þ¨_Þ€Þ¯Þ‰Þ¦_Þ‡Þ¦Þ‚Þ°_Þ„ÞªÞ‹Þ¦_Þ„ÞªÞƒÞ§_Þ€ÞªÞ†Þª_Þ€Þ®Þ‚Þ¨'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'D/M/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n meridiemParse: /Þ‰Þ†|Þ‰ÞŠ/,\n isPM: function (input) {\n return 'Þ‰ÞŠ' === input;\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'Þ‰Þ†';\n } else {\n return 'Þ‰ÞŠ';\n }\n },\n calendar: {\n sameDay: '[Þ‰Þ¨Þ‡Þ¦Þ‹Þª] LT',\n nextDay: '[Þ‰Þ§Þ‹Þ¦Þ‰Þ§] LT',\n nextWeek: 'dddd LT',\n lastDay: '[Þ‡Þ¨Þ‡Þ°Þ”Þ¬] LT',\n lastWeek: '[ފާއިތުވި] dddd LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'ތެރÞÞŽÞ¦Þ‡Þ¨ %s',\n past: 'Þ†ÞªÞƒÞ¨Þ‚Þ° %s',\n s: 'Þިކުންތުކޮޅެއް',\n ss: 'd% Þިކުންތު',\n m: 'Þ‰Þ¨Þ‚Þ¨Þ“Þ¬Þ‡Þ°',\n mm: 'Þ‰Þ¨Þ‚Þ¨Þ“Þª %d',\n h: 'ÞŽÞ¦Þ‘Þ¨Þ‡Þ¨ÞƒÞ¬Þ‡Þ°',\n hh: 'ÞŽÞ¦Þ‘Þ¨Þ‡Þ¨ÞƒÞª %d',\n d: 'Þ‹ÞªÞˆÞ¦Þ€Þ¬Þ‡Þ°',\n dd: 'Þ‹ÞªÞˆÞ¦ÞÞ° %d',\n M: 'Þ‰Þ¦Þ€Þ¬Þ‡Þ°',\n MM: 'Þ‰Þ¦ÞÞ° %d',\n y: 'Þ‡Þ¦Þ€Þ¦ÞƒÞ¬Þ‡Þ°',\n yy: 'Þ‡Þ¦Þ€Þ¦ÞƒÞª %d',\n },\n preparse: function (string) {\n return string.replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string.replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 7, // Sunday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return dv;\n\n})));\n","//! moment.js locale configuration\n//! locale : Turkmen [tk]\n//! author : Atamyrat Abdyrahmanov : https://github.com/atamyratabdy\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var suffixes = {\n 1: \"'inji\",\n 5: \"'inji\",\n 8: \"'inji\",\n 70: \"'inji\",\n 80: \"'inji\",\n 2: \"'nji\",\n 7: \"'nji\",\n 20: \"'nji\",\n 50: \"'nji\",\n 3: \"'ünji\",\n 4: \"'ünji\",\n 100: \"'ünji\",\n 6: \"'njy\",\n 9: \"'unjy\",\n 10: \"'unjy\",\n 30: \"'unjy\",\n 60: \"'ynjy\",\n 90: \"'ynjy\",\n };\n\n var tk = moment.defineLocale('tk', {\n months: 'Ãanwar_Fewral_Mart_Aprel_Maý_Iýun_Iýul_Awgust_Sentýabr_Oktýabr_Noýabr_Dekabr'.split(\n '_'\n ),\n monthsShort: 'Ãan_Few_Mar_Apr_Maý_Iýn_Iýl_Awg_Sen_Okt_Noý_Dek'.split('_'),\n weekdays: 'ÃekÅŸenbe_DuÅŸenbe_SiÅŸenbe_ÇarÅŸenbe_PenÅŸenbe_Anna_Åženbe'.split(\n '_'\n ),\n weekdaysShort: 'Ãek_DuÅŸ_SiÅŸ_Çar_Pen_Ann_Åžen'.split('_'),\n weekdaysMin: 'Ãk_DÅŸ_SÅŸ_Çr_Pn_An_Åžn'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[bugün sagat] LT',\n nextDay: '[ertir sagat] LT',\n nextWeek: '[indiki] dddd [sagat] LT',\n lastDay: '[düýn] LT',\n lastWeek: '[geçen] dddd [sagat] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s soň',\n past: '%s öň',\n s: 'birnäçe sekunt',\n m: 'bir minut',\n mm: '%d minut',\n h: 'bir sagat',\n hh: '%d sagat',\n d: 'bir gün',\n dd: '%d gün',\n M: 'bir aý',\n MM: '%d aý',\n y: 'bir ýyl',\n yy: '%d ýyl',\n },\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'Do':\n case 'DD':\n return number;\n default:\n if (number === 0) {\n // special case for zero\n return number + \"'unjy\";\n }\n var a = number % 10,\n b = (number % 100) - a,\n c = number >= 100 ? 100 : null;\n return number + (suffixes[a] || suffixes[b] || suffixes[c]);\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return tk;\n\n})));\n","//! moment.js locale configuration\n//! locale : Hungarian [hu]\n//! author : Adam Brunner : https://github.com/adambrunner\n//! author : Peter Viszt : https://github.com/passatgt\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var weekEndings =\n 'vasárnap hétfÅ‘n kedden szerdán csütörtökön pénteken szombaton'.split(' ');\n function translate(number, withoutSuffix, key, isFuture) {\n var num = number;\n switch (key) {\n case 's':\n return isFuture || withoutSuffix\n ? 'néhány másodperc'\n : 'néhány másodperce';\n case 'ss':\n return num + (isFuture || withoutSuffix)\n ? ' másodperc'\n : ' másodperce';\n case 'm':\n return 'egy' + (isFuture || withoutSuffix ? ' perc' : ' perce');\n case 'mm':\n return num + (isFuture || withoutSuffix ? ' perc' : ' perce');\n case 'h':\n return 'egy' + (isFuture || withoutSuffix ? ' óra' : ' órája');\n case 'hh':\n return num + (isFuture || withoutSuffix ? ' óra' : ' órája');\n case 'd':\n return 'egy' + (isFuture || withoutSuffix ? ' nap' : ' napja');\n case 'dd':\n return num + (isFuture || withoutSuffix ? ' nap' : ' napja');\n case 'M':\n return 'egy' + (isFuture || withoutSuffix ? ' hónap' : ' hónapja');\n case 'MM':\n return num + (isFuture || withoutSuffix ? ' hónap' : ' hónapja');\n case 'y':\n return 'egy' + (isFuture || withoutSuffix ? ' év' : ' éve');\n case 'yy':\n return num + (isFuture || withoutSuffix ? ' év' : ' éve');\n }\n return '';\n }\n function week(isFuture) {\n return (\n (isFuture ? '' : '[múlt] ') +\n '[' +\n weekEndings[this.day()] +\n '] LT[-kor]'\n );\n }\n\n var hu = moment.defineLocale('hu', {\n months: 'január_február_március_április_május_június_július_augusztus_szeptember_október_november_december'.split(\n '_'\n ),\n monthsShort:\n 'jan._feb._márc._ápr._máj._jún._júl._aug._szept._okt._nov._dec.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'vasárnap_hétfÅ‘_kedd_szerda_csütörtök_péntek_szombat'.split('_'),\n weekdaysShort: 'vas_hét_kedd_sze_csüt_pén_szo'.split('_'),\n weekdaysMin: 'v_h_k_sze_cs_p_szo'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'YYYY.MM.DD.',\n LL: 'YYYY. MMMM D.',\n LLL: 'YYYY. MMMM D. H:mm',\n LLLL: 'YYYY. MMMM D., dddd H:mm',\n },\n meridiemParse: /de|du/i,\n isPM: function (input) {\n return input.charAt(1).toLowerCase() === 'u';\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours < 12) {\n return isLower === true ? 'de' : 'DE';\n } else {\n return isLower === true ? 'du' : 'DU';\n }\n },\n calendar: {\n sameDay: '[ma] LT[-kor]',\n nextDay: '[holnap] LT[-kor]',\n nextWeek: function () {\n return week.call(this, true);\n },\n lastDay: '[tegnap] LT[-kor]',\n lastWeek: function () {\n return week.call(this, false);\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s múlva',\n past: '%s',\n s: translate,\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: translate,\n dd: translate,\n M: translate,\n MM: translate,\n y: translate,\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return hu;\n\n})));\n","//! moment.js locale configuration\n//! locale : Chinese (China) [zh-cn]\n//! author : suupic : https://github.com/suupic\n//! author : Zeno Zeng : https://github.com/zenozeng\n//! author : uu109 : https://github.com/uu109\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var zhCn = moment.defineLocale('zh-cn', {\n months: '一月_二月_三月_四月_五月_å…月_七月_八月_ä¹æœˆ_å月_å一月_å二月'.split(\n '_'\n ),\n monthsShort: '1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月'.split(\n '_'\n ),\n weekdays: '星期日_星期一_星期二_星期三_星期四_星期五_星期å…'.split('_'),\n weekdaysShort: '周日_周一_周二_周三_周四_周五_周å…'.split('_'),\n weekdaysMin: 'æ—¥_一_二_三_å››_五_å…'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY/MM/DD',\n LL: 'YYYYå¹´M月Dæ—¥',\n LLL: 'YYYYå¹´M月Dæ—¥Ah点mm分',\n LLLL: 'YYYYå¹´M月Dæ—¥ddddAh点mm分',\n l: 'YYYY/M/D',\n ll: 'YYYYå¹´M月Dæ—¥',\n lll: 'YYYYå¹´M月Dæ—¥ HH:mm',\n llll: 'YYYYå¹´M月Dæ—¥dddd HH:mm',\n },\n meridiemParse: /凌晨|早上|上åˆ|ä¸åˆ|下åˆ|晚上/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === '凌晨' || meridiem === '早上' || meridiem === '上åˆ') {\n return hour;\n } else if (meridiem === '下åˆ' || meridiem === '晚上') {\n return hour + 12;\n } else {\n // 'ä¸åˆ'\n return hour >= 11 ? hour : hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n var hm = hour * 100 + minute;\n if (hm < 600) {\n return '凌晨';\n } else if (hm < 900) {\n return '早上';\n } else if (hm < 1130) {\n return '上åˆ';\n } else if (hm < 1230) {\n return 'ä¸åˆ';\n } else if (hm < 1800) {\n return '下åˆ';\n } else {\n return '晚上';\n }\n },\n calendar: {\n sameDay: '[今天]LT',\n nextDay: '[明天]LT',\n nextWeek: function (now) {\n if (now.week() !== this.week()) {\n return '[下]dddLT';\n } else {\n return '[本]dddLT';\n }\n },\n lastDay: '[昨天]LT',\n lastWeek: function (now) {\n if (this.week() !== now.week()) {\n return '[上]dddLT';\n } else {\n return '[本]dddLT';\n }\n },\n sameElse: 'L',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(æ—¥|月|周)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'DDD':\n return number + 'æ—¥';\n case 'M':\n return number + '月';\n case 'w':\n case 'W':\n return number + '周';\n default:\n return number;\n }\n },\n relativeTime: {\n future: '%såŽ',\n past: '%så‰',\n s: 'å‡ ç§’',\n ss: '%d 秒',\n m: '1 分钟',\n mm: '%d 分钟',\n h: '1 å°æ—¶',\n hh: '%d å°æ—¶',\n d: '1 天',\n dd: '%d 天',\n w: '1 周',\n ww: '%d 周',\n M: '1 个月',\n MM: '%d 个月',\n y: '1 å¹´',\n yy: '%d å¹´',\n },\n week: {\n // GB/T 7408-1994《数æ®å…ƒå’Œäº¤æ¢æ ¼å¼Â·ä¿¡æ¯äº¤æ¢Â·æ—¥æœŸå’Œæ—¶é—´è¡¨ç¤ºæ³•ã€‹ä¸ŽISO 8601:1988ç‰æ•ˆ\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return zhCn;\n\n})));\n","//! moment.js locale configuration\n//! locale : Telugu [te]\n//! author : Krishna Chaitanya Thota : https://github.com/kcthota\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var te = moment.defineLocale('te', {\n months: 'జనవరి_à°«à°¿à°¬à±à°°à°µà°°à°¿_మారà±à°šà°¿_à°à°ªà±à°°à°¿à°²à±_మే_జూనà±_à°œà±à°²à±ˆ_ఆగసà±à°Ÿà±_సెపà±à°Ÿà±†à°‚బరà±_à°…à°•à±à°Ÿà±‹à°¬à°°à±_నవంబరà±_డిసెంబరà±'.split(\n '_'\n ),\n monthsShort:\n 'జన._à°«à°¿à°¬à±à°°._మారà±à°šà°¿_à°à°ªà±à°°à°¿._మే_జూనà±_à°œà±à°²à±ˆ_ఆగ._సెపà±._à°…à°•à±à°Ÿà±‹._నవ._డిసె.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays:\n 'ఆదివారం_సోమవారం_మంగళవారం_à°¬à±à°§à°µà°¾à°°à°‚_à°—à±à°°à±à°µà°¾à°°à°‚_à°¶à±à°•à±à°°à°µà°¾à°°à°‚_శనివారం'.split(\n '_'\n ),\n weekdaysShort: 'ఆది_సోమ_మంగళ_à°¬à±à°§_à°—à±à°°à±_à°¶à±à°•à±à°°_శని'.split('_'),\n weekdaysMin: 'à°†_సో_మం_à°¬à±_à°—à±_à°¶à±_à°¶'.split('_'),\n longDateFormat: {\n LT: 'A h:mm',\n LTS: 'A h:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm',\n LLLL: 'dddd, D MMMM YYYY, A h:mm',\n },\n calendar: {\n sameDay: '[నేడà±] LT',\n nextDay: '[రేపà±] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[నినà±à°¨] LT',\n lastWeek: '[à°—à°¤] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s లో',\n past: '%s à°•à±à°°à°¿à°¤à°‚',\n s: 'కొనà±à°¨à°¿ à°•à±à°·à°£à°¾à°²à±',\n ss: '%d సెకనà±à°²à±',\n m: 'à°’à°• నిమిషం',\n mm: '%d నిమిషాలà±',\n h: 'à°’à°• à°—à°‚à°Ÿ',\n hh: '%d à°—à°‚à°Ÿà°²à±',\n d: 'à°’à°• రోజà±',\n dd: '%d రోజà±à°²à±',\n M: 'à°’à°• నెల',\n MM: '%d నెలలà±',\n y: 'à°’à°• సంవతà±à°¸à°°à°‚',\n yy: '%d సంవతà±à°¸à°°à°¾à°²à±',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}à°µ/,\n ordinal: '%dà°µ',\n meridiemParse: /రాతà±à°°à°¿|ఉదయం|మధà±à°¯à°¾à°¹à±à°¨à°‚|సాయంతà±à°°à°‚/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'రాతà±à°°à°¿') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'ఉదయం') {\n return hour;\n } else if (meridiem === 'మధà±à°¯à°¾à°¹à±à°¨à°‚') {\n return hour >= 10 ? hour : hour + 12;\n } else if (meridiem === 'సాయంతà±à°°à°‚') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'రాతà±à°°à°¿';\n } else if (hour < 10) {\n return 'ఉదయం';\n } else if (hour < 17) {\n return 'మధà±à°¯à°¾à°¹à±à°¨à°‚';\n } else if (hour < 20) {\n return 'సాయంతà±à°°à°‚';\n } else {\n return 'రాతà±à°°à°¿';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return te;\n\n})));\n","import { withInBounds, PointData, getValueXByPoint, getValueYByPoint, sort } from '../../common/utils/helper';\nimport { Rect } from '@syncfusion/ej2-svg-base';\n/**\n * To get the data on mouse move.\n *\n * @private\n */\nvar ChartData = /** @class */ (function () {\n /**\n * Constructor for the data.\n *\n * @private\n */\n function ChartData(chart) {\n /** @private */\n this.currentPoints = [];\n /** @private */\n this.previousPoints = [];\n this.insideRegion = false;\n this.commonXvalues = [];\n this.chart = chart;\n this.lierIndex = 0;\n }\n /**\n * Method to get the Data.\n *\n * @private\n */\n ChartData.prototype.getData = function () {\n var chart = this.chart;\n var point = null;\n var series = null;\n var width;\n var height;\n var mouseX;\n var mouseY;\n for (var len = chart.visibleSeries.length, i = len - 1; i >= 0; i--) {\n series = chart.visibleSeries[i];\n width = (series.type === 'Scatter' || series.drawType === 'Scatter' || (series.marker.visible))\n ? (series.marker.height + 5) / 2 : 0;\n height = (series.type === 'Scatter' || series.drawType === 'Scatter' || (series.marker.visible))\n ? (series.marker.width + 5) / 2 : 0;\n mouseX = chart.mouseX;\n mouseY = chart.mouseY;\n if (series.dragSettings.enable && series.isRectSeries) {\n if (!(series.type === 'Bar' && chart.isTransposed) && (chart.isTransposed || series.type === 'Bar')) {\n var markerWidth = series.marker.width / 2;\n mouseX = series.yAxis.isAxisInverse ? mouseX + markerWidth : mouseX - markerWidth;\n }\n else {\n var markerHeight = series.marker.height / 2;\n mouseY = series.yAxis.isAxisInverse ? mouseY - markerHeight : mouseY + markerHeight;\n }\n }\n if (series.visible && withInBounds(mouseX, mouseY, series.clipRect, width, height)) {\n point = this.getRectPoint(series, series.clipRect, mouseX, mouseY);\n }\n if (point) {\n return new PointData(point, series);\n }\n }\n return new PointData(point, series);\n };\n ChartData.prototype.isSelected = function (chart) {\n return ((chart.selectionMode.indexOf('Drag') > -1 || chart.selectionMode.indexOf('Lasso') > -1) && chart.selectionModule &&\n chart.selectionModule.rectPoints !== null);\n };\n ChartData.prototype.getRectPoint = function (series, rect, x, y) {\n var chart = this.chart;\n var fromCenterX;\n var fromCenterY;\n var clickAngle;\n var arcAngle = 0;\n var startAngle;\n var endAngle;\n var distanceFromCenter;\n if (chart.isScrolling) {\n return null;\n }\n for (var _i = 0, _a = series.points; _i < _a.length; _i++) {\n var point = _a[_i];\n if (!point.regionData) {\n if (!point.regions || !point.regions.length) {\n continue;\n }\n }\n if (point.regionData && this.chart.chartAreaType === 'PolarRadar' && series.drawType.indexOf('Column') > -1) {\n fromCenterX = x - (series.clipRect.width / 2 + series.clipRect.x);\n fromCenterY = y - (series.clipRect.height / 2 + series.clipRect.y);\n arcAngle = 2 * Math.PI * (point.regionData.currentXPosition < 0 ? 1 + point.regionData.currentXPosition\n : point.regionData.currentXPosition);\n clickAngle = (Math.atan2(fromCenterY, fromCenterX) + 0.5 * Math.PI - arcAngle) % (2 * Math.PI);\n clickAngle = clickAngle < 0 ? 2 * Math.PI + clickAngle : clickAngle;\n clickAngle = clickAngle + 2 * Math.PI * series.chart.primaryXAxis.startAngle;\n startAngle = point.regionData.startAngle;\n startAngle -= arcAngle;\n startAngle = startAngle < 0 ? 2 * Math.PI + startAngle : startAngle;\n endAngle = point.regionData.endAngle;\n endAngle -= arcAngle;\n endAngle = endAngle < 0 ? 2 * Math.PI + endAngle : endAngle;\n distanceFromCenter = Math.sqrt(Math.pow(Math.abs(fromCenterX), 2) + Math.pow(Math.abs(fromCenterY), 2));\n if (clickAngle >= startAngle && clickAngle <= endAngle &&\n (((distanceFromCenter >= point.regionData.innerRadius && distanceFromCenter <= point.regionData.radius) ||\n (distanceFromCenter <= point.regionData.innerRadius && distanceFromCenter >= point.regionData.radius))\n && distanceFromCenter <= series.chart.radius)) {\n return point;\n }\n }\n if ((series.dragSettings.enable && series.isRectSeries) || (series.isRectSeries && series.marker.visible)) {\n if (this.isPointInThresholdRegion(x, y, point, rect, series)) {\n this.insideRegion = true;\n return point;\n }\n }\n if (!this.insideRegion && this.checkRegionContainsPoint(point.regions, rect, x, y)) {\n return point;\n }\n else if (this.insideRegion && this.checkRegionContainsPoint(point.regions, rect, x, y)) {\n return point;\n }\n }\n return null;\n };\n /**\n * Checks whether the region contains a point\n */\n ChartData.prototype.checkRegionContainsPoint = function (regionRect, rect, x, y) {\n var _this = this;\n return regionRect.some(function (region, index) {\n _this.lierIndex = index;\n return withInBounds(x, y, new Rect((_this.chart.chartAreaType === 'Cartesian' ? rect.x : 0) + region.x, (_this.chart.chartAreaType === 'Cartesian' ? rect.y : 0) + region.y, region.width, region.height));\n });\n };\n /**\n * To check the point in threshold region for column and bar series\n *\n * @param {number} x X coordinate\n * @param {number} y Y coodinate\n * @param {Points} point point\n * @param {Rect} rect point rect region\n * @param {Series} series series\n */\n ChartData.prototype.isPointInThresholdRegion = function (x, y, point, rect, series) {\n var _this = this;\n var isBar = series.type === 'Bar';\n var isInversed = series.yAxis.isAxisInverse;\n var isTransposed = series.chart.isTransposed;\n var heightValue = 10;\n var yValue = 0;\n var xValue = 0;\n var width;\n var height = width = 2 * heightValue;\n if (isInversed && isTransposed) {\n if (isBar) {\n yValue = point.regions[0].height - heightValue;\n width = point.regions[0].width;\n }\n else {\n xValue = -heightValue;\n height = point.regions[0].height;\n }\n }\n else if (isInversed || point.yValue < 0) {\n if (isBar) {\n xValue = -heightValue;\n height = point.regions[0].height;\n }\n else {\n yValue = point.regions[0].height - heightValue;\n width = point.regions[0].width;\n }\n }\n else if (isTransposed) {\n if (isBar) {\n yValue = -heightValue;\n width = point.regions[0].width;\n }\n else {\n xValue = point.regions[0].width - heightValue;\n height = point.regions[0].height;\n }\n }\n else {\n if (isBar) {\n xValue = point.regions[0].width - heightValue;\n height = point.regions[0].height;\n }\n else {\n yValue = -heightValue;\n width = point.regions[0].width;\n }\n }\n return point.regions.some(function (region) {\n return withInBounds(x, y, new Rect((_this.chart.chartAreaType === 'Cartesian' ? rect.x : 0) + region.x + xValue, (_this.chart.chartAreaType === 'Cartesian' ? rect.y : 0) + region.y + yValue, width, height));\n });\n };\n /**\n * @private\n */\n ChartData.prototype.getClosest = function (series, value, xvalues) {\n var closest;\n var data;\n var xData = xvalues ? xvalues : series.xData;\n var xLength = xData.length;\n var leftSideNearest = 0.5;\n var rightSideNearest = 0.5;\n if (series.xAxis.valueType === 'DateTime' && series.points.length === 1) {\n leftSideNearest = series.xAxis.visibleRange.min;\n rightSideNearest = series.xAxis.visibleRange.max;\n for (var index = 0; index < series.chart.visibleSeries.length; index++) {\n var visibleSeries = series.chart.visibleSeries[index];\n if (visibleSeries.xMin >= leftSideNearest && visibleSeries.xMin < series.xMin) {\n leftSideNearest = visibleSeries.xMin + 0.1;\n }\n if (visibleSeries.xMax <= rightSideNearest && visibleSeries.xMax > series.xMax) {\n rightSideNearest = visibleSeries.xMax - 0.1;\n }\n if (visibleSeries.points.length > 1) {\n if (visibleSeries.xMax >= leftSideNearest && visibleSeries.xMax < series.xMin) {\n leftSideNearest = visibleSeries.xMax + 0.1;\n }\n if (visibleSeries.xMin <= rightSideNearest && visibleSeries.xMin > series.xMax) {\n rightSideNearest = visibleSeries.xMin - 0.1;\n }\n }\n }\n if (leftSideNearest !== series.xAxis.visibleRange.min) {\n leftSideNearest = Math.abs(series.xMin - leftSideNearest) / 2;\n }\n if (rightSideNearest !== series.xAxis.visibleRange.max) {\n rightSideNearest = Math.abs(series.xMax - rightSideNearest) / 2;\n }\n }\n if (value >= series.xMin - leftSideNearest && value <= series.xMax + rightSideNearest) {\n for (var i = 0; i < xLength; i++) {\n data = xData[i];\n if (closest == null || Math.abs(data - value) < Math.abs(closest - value)) {\n closest = data;\n }\n }\n }\n var isDataExist = series.xData.indexOf(closest) !== -1;\n if (isDataExist) {\n return closest;\n }\n else {\n return null;\n }\n };\n ChartData.prototype.binarySearch = function (target, list) {\n var first = 0;\n var last = list.length;\n var position = -1;\n var found = false;\n var middle;\n while (found === false && first <= last) {\n middle = Math.floor((first + last) / 2);\n if (list[middle].xValue === target) {\n found = true;\n position = middle;\n }\n else if (list[middle].xValue > target) {\n last = middle - 1;\n }\n else {\n first = middle + 1;\n }\n }\n return position !== -1 ? list[position] : null;\n };\n ChartData.prototype.getClosestX = function (chart, series, xvalues) {\n var value;\n var rect = series.clipRect;\n if (chart.mouseX <= rect.x + rect.width && chart.mouseX >= rect.x) {\n if (!chart.requireInvertedAxis) {\n value = getValueXByPoint(chart.mouseX - rect.x, rect.width, series.xAxis);\n }\n else {\n value = getValueYByPoint(chart.mouseY - rect.y, rect.height, series.xAxis);\n }\n }\n var closest = this.getClosest(series, value, xvalues);\n var point = ((closest || closest === 0) && series.points.length > 0) ? this.binarySearch(closest, sort(series.points, ['xValue'])) : null;\n if (point && point.visible) {\n if (!(this.chart.chartAreaType === 'Cartesian' && ((series.category == 'Indicator' && series.name == 'Histogram') ||\n (point.symbolLocations && point.symbolLocations.length > 0 && point.symbolLocations[0].x >= 0 && point.symbolLocations[0].x <= rect.width)))) {\n return null;\n }\n return new PointData(point, series);\n }\n return null;\n };\n /**\n * Merge all visible series X values for shared tooltip (EJ2-47072)\n *\n * @param visibleSeries\n * @private\n */\n ChartData.prototype.mergeXvalues = function (visibleSeries) {\n if (visibleSeries.length && (!this.commonXvalues.length || (this.commonXvalues.length !== visibleSeries[0].xData.length))) {\n this.commonXvalues = visibleSeries[0].xData;\n for (var index = 1; index < visibleSeries.length; index++) {\n this.commonXvalues = this.getDistinctValues(this.commonXvalues, visibleSeries[index].xData);\n }\n }\n return this.commonXvalues;\n };\n ChartData.prototype.commonXValue = function (visibleSeries) {\n var commonXValues = [];\n for (var j = 0; j < visibleSeries.length; j++) {\n for (var i = 0; (visibleSeries[j].points && i < visibleSeries[j].points.length); i++) {\n var point = visibleSeries[j].points[i];\n if (point && (point.index === 0 || point.index === visibleSeries[j].points.length - 1 ||\n (point.symbolLocations && point.symbolLocations.length > 0))) {\n commonXValues.push(point.xValue);\n }\n }\n }\n return commonXValues;\n };\n ChartData.prototype.getDistinctValues = function (first, second) {\n if (first === void 0) { first = []; }\n if (second === void 0) { second = []; }\n var intial = {};\n var result = [];\n var index;\n for (index = 0; index < first.length; index++) {\n var temp = first[index];\n if (!intial[temp]) {\n intial[temp] = true;\n result.push(temp);\n }\n }\n for (index = 0; index < second.length; index++) {\n var temp = second[index];\n if (!intial[temp]) {\n intial[temp] = true;\n result.push(temp);\n }\n }\n return result;\n };\n return ChartData;\n}());\nexport { ChartData };\n","//! moment.js locale configuration\n//! locale : Swedish [sv]\n//! author : Jens Alm : https://github.com/ulmus\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var sv = moment.defineLocale('sv', {\n months: 'januari_februari_mars_april_maj_juni_juli_augusti_september_oktober_november_december'.split(\n '_'\n ),\n monthsShort: 'jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec'.split('_'),\n weekdays: 'söndag_mÃ¥ndag_tisdag_onsdag_torsdag_fredag_lördag'.split('_'),\n weekdaysShort: 'sön_mÃ¥n_tis_ons_tor_fre_lör'.split('_'),\n weekdaysMin: 'sö_mÃ¥_ti_on_to_fr_lö'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY-MM-DD',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY [kl.] HH:mm',\n LLLL: 'dddd D MMMM YYYY [kl.] HH:mm',\n lll: 'D MMM YYYY HH:mm',\n llll: 'ddd D MMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Idag] LT',\n nextDay: '[Imorgon] LT',\n lastDay: '[IgÃ¥r] LT',\n nextWeek: '[PÃ¥] dddd LT',\n lastWeek: '[I] dddd[s] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'om %s',\n past: 'för %s sedan',\n s: 'nÃ¥gra sekunder',\n ss: '%d sekunder',\n m: 'en minut',\n mm: '%d minuter',\n h: 'en timme',\n hh: '%d timmar',\n d: 'en dag',\n dd: '%d dagar',\n M: 'en mÃ¥nad',\n MM: '%d mÃ¥nader',\n y: 'ett Ã¥r',\n yy: '%d Ã¥r',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(\\:e|\\:a)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? ':e'\n : b === 1\n ? ':a'\n : b === 2\n ? ':a'\n : b === 3\n ? ':e'\n : ':e';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return sv;\n\n})));\n","//! moment.js locale configuration\n//! locale : Uyghur (China) [ug-cn]\n//! author: boyaq : https://github.com/boyaq\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ugCn = moment.defineLocale('ug-cn', {\n months: 'يانۋار_ÙÛۋرال_مارت_ئاپرÛÙ„_ماي_ئىيۇن_ئىيۇل_ئاۋغۇست_سÛنتەبىر_ئۆكتەبىر_نويابىر_دÛكابىر'.split(\n '_'\n ),\n monthsShort:\n 'يانۋار_ÙÛۋرال_مارت_ئاپرÛÙ„_ماي_ئىيۇن_ئىيۇل_ئاۋغۇست_سÛنتەبىر_ئۆكتەبىر_نويابىر_دÛكابىر'.split(\n '_'\n ),\n weekdays: 'يەكشەنبە_دۈشەنبە_سەيشەنبە_چارشەنبە_پەيشەنبە_جۈمە_شەنبە'.split(\n '_'\n ),\n weekdaysShort: 'ÙŠÛ•_دۈ_سە_چا_Ù¾Û•_جۈ_Ø´Û•'.split('_'),\n weekdaysMin: 'ÙŠÛ•_دۈ_سە_چا_Ù¾Û•_جۈ_Ø´Û•'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY-MM-DD',\n LL: 'YYYY-يىلىM-ئاينىÚD-كۈنى',\n LLL: 'YYYY-يىلىM-ئاينىÚD-كۈنى، HH:mm',\n LLLL: 'ddddØŒ YYYY-يىلىM-ئاينىÚD-كۈنى، HH:mm',\n },\n meridiemParse: /ÙŠÛرىم ÙƒÛÚ†Û•|سەھەر|چۈشتىن بۇرۇن|چۈش|چۈشتىن ÙƒÛيىن|ÙƒÛ•Ú†/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (\n meridiem === 'ÙŠÛرىم ÙƒÛÚ†Û•' ||\n meridiem === 'سەھەر' ||\n meridiem === 'چۈشتىن بۇرۇن'\n ) {\n return hour;\n } else if (meridiem === 'چۈشتىن ÙƒÛيىن' || meridiem === 'ÙƒÛ•Ú†') {\n return hour + 12;\n } else {\n return hour >= 11 ? hour : hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n var hm = hour * 100 + minute;\n if (hm < 600) {\n return 'ÙŠÛرىم ÙƒÛÚ†Û•';\n } else if (hm < 900) {\n return 'سەھەر';\n } else if (hm < 1130) {\n return 'چۈشتىن بۇرۇن';\n } else if (hm < 1230) {\n return 'چۈش';\n } else if (hm < 1800) {\n return 'چۈشتىن ÙƒÛيىن';\n } else {\n return 'ÙƒÛ•Ú†';\n }\n },\n calendar: {\n sameDay: '[بۈگۈن سائەت] LT',\n nextDay: '[ئەتە سائەت] LT',\n nextWeek: '[ÙƒÛلەركى] dddd [سائەت] LT',\n lastDay: '[تۆنۈگۈن] LT',\n lastWeek: '[ئالدىنقى] dddd [سائەت] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s ÙƒÛيىن',\n past: '%s بۇرۇن',\n s: 'Ù†Û•Ú†Ú†Û• سÛكونت',\n ss: '%d سÛكونت',\n m: 'بىر مىنۇت',\n mm: '%d مىنۇت',\n h: 'بىر سائەت',\n hh: '%d سائەت',\n d: 'بىر ÙƒÛˆÙ†',\n dd: '%d ÙƒÛˆÙ†',\n M: 'بىر ئاي',\n MM: '%d ئاي',\n y: 'بىر يىل',\n yy: '%d يىل',\n },\n\n dayOfMonthOrdinalParse: /\\d{1,2}(-كۈنى|-ئاي|-ھەپتە)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'DDD':\n return number + '-كۈنى';\n case 'w':\n case 'W':\n return number + '-ھەپتە';\n default:\n return number;\n }\n },\n preparse: function (string) {\n return string.replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string.replace(/,/g, 'ØŒ');\n },\n week: {\n // GB/T 7408-1994《数æ®å…ƒå’Œäº¤æ¢æ ¼å¼Â·ä¿¡æ¯äº¤æ¢Â·æ—¥æœŸå’Œæ—¶é—´è¡¨ç¤ºæ³•ã€‹ä¸ŽISO 8601:1988ç‰æ•ˆ\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 1st is the first week of the year.\n },\n });\n\n return ugCn;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable jsdoc/require-param */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-returns */\nimport { getPoint, appendClipElement, pathAnimation } from '../../common/utils/helper';\nimport { LineBase } from './line-base';\nimport { RectOption, getElement } from '../../common/utils/helper';\nimport { DataUtil } from '@syncfusion/ej2-data';\n/**\n * Base class for multi colored series\n */\nvar MultiColoredSeries = /** @class */ (function (_super) {\n __extends(MultiColoredSeries, _super);\n function MultiColoredSeries() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * To Generate the area path direction.\n *\n * @param {number} xValue xValue\n * @param {number} yValue yValue\n * @param {Series} series series\n * @param {boolean} isInverted isInverted\n * @param {Function} getPointLocation getPointLocation\n * @param {ChartLocation} startPoint startPoint\n * @param {string} startPath startPath\n */\n MultiColoredSeries.prototype.getAreaPathDirection = function (xValue, yValue, series, isInverted, getPointLocation, startPoint, startPath) {\n var direction = '';\n var firstPoint;\n if (startPoint === null) {\n firstPoint = getPointLocation(xValue, yValue, series.xAxis, series.yAxis, isInverted, series);\n direction += (startPath + ' ' + (firstPoint.x) + ' ' + (firstPoint.y) + ' ');\n }\n return direction;\n };\n /**\n * To Generate the empty point direction.\n *\n * @param {ChartLocation} firstPoint firstPoint\n * @param {ChartLocation} secondPoint secondPoint\n * @param {Series} series series\n * @param {boolean} isInverted isInverted\n * @param {Function} getPointLocation getPointLocation\n */\n MultiColoredSeries.prototype.getAreaEmptyDirection = function (firstPoint, secondPoint, series, isInverted, getPointLocation) {\n var direction = '';\n direction += this.getAreaPathDirection(firstPoint.x, firstPoint.y, series, isInverted, getPointLocation, null, 'L');\n direction += this.getAreaPathDirection(secondPoint.x, secondPoint.y, series, isInverted, getPointLocation, null, 'L');\n return direction;\n };\n /**\n * To set point color.\n */\n MultiColoredSeries.prototype.setPointColor = function (currentPoint, previous, series, isXSegment, segments) {\n if (series.pointColorMapping === '') {\n var segment = void 0;\n var value = void 0;\n for (var i = 0; i < segments.length; i++) {\n segment = segments[i];\n value = isXSegment ? currentPoint.xValue : currentPoint.yValue;\n if (value <= this.getAxisValue(segment.value, isXSegment ? series.xAxis : series.yAxis, series.chart) ||\n (!segment.value && segment.value !== 0)) {\n currentPoint.interior = segment.color;\n break;\n }\n }\n if (currentPoint.interior == null) {\n currentPoint.interior = series.interior;\n }\n return false;\n }\n else {\n if (previous) {\n return series.setPointColor(currentPoint, series.interior) !== series.setPointColor(previous, series.interior);\n }\n else {\n return false;\n }\n }\n };\n MultiColoredSeries.prototype.sortSegments = function (series, chartSegments) {\n var _this = this;\n var axis = series.segmentAxis === 'X' ? series.xAxis : series.yAxis;\n var segments = [].concat(chartSegments);\n return segments.sort(function (a, b) {\n return _this.getAxisValue(a.value, axis, series.chart) - _this.getAxisValue(b.value, axis, series.chart);\n });\n };\n /**\n * Segment calculation performed here.\n *\n * @param {Series} series series\n * @param {PathOption[]} options options\n * @param {ChartSegmentModel[]} segments chartSegments\n */\n MultiColoredSeries.prototype.applySegmentAxis = function (series, options, segments) {\n var _this = this;\n if (series.pointColorMapping !== '') {\n options.map(function (option) {\n _this.appendLinePath(option, series, '');\n });\n return null;\n }\n var isXSegment = series.segmentAxis === 'X';\n var axis = isXSegment ? series.xAxis : series.yAxis;\n var chart = series.chart;\n var segment;\n this.includeSegment(segments, axis, series, segments.length);\n var length = segments.length;\n var value;\n var clipPath;\n var attributeOptions;\n var areaBorderCount = 0;\n var _loop_1 = function (index) {\n segment = segments[index];\n value = this_1.getAxisValue(segment.value, axis, series.chart);\n clipPath = this_1.createClipRect(index ? this_1.getAxisValue(segments[index - 1].value, axis, series.chart)\n : axis.visibleRange.min, value, series, index, isXSegment);\n if (clipPath) {\n options.map(function (option) {\n areaBorderCount += 1;\n attributeOptions = {\n 'clip-path': clipPath,\n 'stroke-dasharray': segment.dashArray,\n 'opacity': option.opacity,\n 'stroke': series.type.indexOf('Line') > -1 ? segment.color || series.interior : option['stroke'],\n 'stroke-width': option['stroke-width'],\n 'fill': series.type.indexOf('Line') > -1 ? 'none' : segment.color || series.interior,\n 'id': option.id + '_Segment_' + index,\n 'd': option.d\n };\n if (areaBorderCount % 2 === 0 && _this.chart.multiColoredAreaSeriesModule && series.border.color !== 'transparent' && attributeOptions['stroke-width'] !== 0) {\n attributeOptions.fill = 'transparent';\n }\n pathAnimation(getElement(attributeOptions.id), attributeOptions.d, chart.redraw);\n series.pathElement = chart.renderer.drawPath(attributeOptions);\n if (!series.chart.enableCanvas) {\n series.seriesElement.appendChild(chart.renderer.drawPath(attributeOptions));\n }\n });\n }\n };\n var this_1 = this;\n for (var index = 0; index < length; index++) {\n _loop_1(index);\n }\n };\n MultiColoredSeries.prototype.includeSegment = function (segments, axis, series, length) {\n if (length <= 0) {\n segments.push({ value: axis.visibleRange.max, color: series.interior });\n return null;\n }\n if (this.getAxisValue(segments[length - 1].value, axis, series.chart) < axis.visibleRange.max) {\n segments.push({ value: axis.visibleRange.max, color: series.interior });\n }\n };\n /**\n * To create clip rect for segment axis.\n *\n * @param {number} startValue startValue\n * @param {number} endValue endValue\n * @param {Series} series series\n * @param {number} index index\n * @param {boolean} isX isX\n */\n MultiColoredSeries.prototype.createClipRect = function (startValue, endValue, series, index, isX) {\n var isRequired = series.chart.requireInvertedAxis;\n var startPointLocation = getPoint(isX ? startValue : series.xAxis.visibleRange.min, isX ? series.yAxis.visibleRange.max : endValue, series.xAxis, series.yAxis, isRequired);\n var endPointLocation = getPoint(isX ? endValue : series.xAxis.visibleRange.max, isX ? series.yAxis.visibleRange.min : startValue, series.xAxis, series.yAxis, isRequired);\n endPointLocation = isRequired ?\n [startPointLocation, startPointLocation = endPointLocation][0] : endPointLocation;\n var options;\n if (((series.xAxis.isInversed || series.xAxis.isAxisInverse) ? startPointLocation.x - endPointLocation.x > 0 : endPointLocation.x - startPointLocation.x > 0) &&\n (series.yAxis.isInversed ? startPointLocation.y - endPointLocation.y > 0 : endPointLocation.y - startPointLocation.y > 0)) {\n options = new RectOption(series.chart.element.id + '_ChartSegment' + series.index + 'ClipRect_' + index, 'transparent', { width: 1, color: 'Gray' }, 1, {\n x: (series.xAxis.isInversed || series.xAxis.isAxisInverse) ? endPointLocation.x : startPointLocation.x,\n y: series.yAxis.isInversed ? endPointLocation.y : startPointLocation.y,\n width: (series.xAxis.isInversed || series.xAxis.isAxisInverse) ? startPointLocation.x - endPointLocation.x : endPointLocation.x - startPointLocation.x,\n height: series.yAxis.isInversed ? startPointLocation.y - endPointLocation.y : endPointLocation.y - startPointLocation.y\n });\n if (!series.chart.enableCanvas) {\n series.seriesElement.appendChild(appendClipElement(series.chart.redraw, options, series.chart.renderer));\n }\n return 'url(#' + series.chart.element.id + '_ChartSegment' + series.index + 'ClipRect_' + index + ')';\n }\n return null;\n };\n /**\n * To get exact value from segment value.\n *\n * @param {Object} segmentValue segmentValue\n * @param {Axis} axis axis\n * @param {Chart} chart chart\n */\n MultiColoredSeries.prototype.getAxisValue = function (segmentValue, axis, chart) {\n if (segmentValue === null) {\n segmentValue = axis.visibleRange.max;\n }\n if (axis.valueType === 'DateTime') {\n var option = { skeleton: 'full', type: 'dateTime' };\n return Date.parse(chart.intl.getDateParser(option)(chart.intl.getDateFormat(option)(new Date(DataUtil.parse.parseJson({ val: segmentValue }).val))));\n }\n else if (axis.valueType.indexOf('Category') > -1) {\n var xValue = axis.valueType === 'DateTimeCategory' ?\n (segmentValue.getTime()).toString() :\n segmentValue;\n return (axis.labels.indexOf(xValue) < 0) ? +segmentValue : axis.labels.indexOf(xValue);\n }\n else {\n return +segmentValue;\n }\n };\n return MultiColoredSeries;\n}(LineBase));\nexport { MultiColoredSeries };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { withInRange, getPoint } from '../../common/utils/helper';\nimport { PathOption } from '@syncfusion/ej2-svg-base';\nimport { MultiColoredSeries } from './multi-colored-base';\n/**\n * `MultiColoredLineSeries` used to render the line series with multi color.\n */\nvar MultiColoredLineSeries = /** @class */ (function (_super) {\n __extends(MultiColoredLineSeries, _super);\n function MultiColoredLineSeries() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * Render Line Series.\n *\n * @returns {void}\n * @private\n */\n MultiColoredLineSeries.prototype.render = function (series, xAxis, yAxis, isInverted) {\n var previous = null;\n var startPoint = 'M';\n var visiblePoints = this.enableComplexProperty(series);\n var options = [];\n var direction = '';\n var lastPoint;\n var segmentPoint = null;\n var segments = this.sortSegments(series, series.segments);\n for (var _i = 0, visiblePoints_1 = visiblePoints; _i < visiblePoints_1.length; _i++) {\n var point = visiblePoints_1[_i];\n point.regions = [];\n if (point.visible && withInRange(visiblePoints[point.index - 1], point, visiblePoints[point.index + 1], series)) {\n lastPoint = point;\n direction += this.getLineDirection(previous, point, series, isInverted, getPoint, startPoint);\n if (previous != null) {\n if (this.setPointColor(point, previous, series, series.segmentAxis === 'X', segments)) {\n options.push(new PathOption(series.chart.element.id + '_Series_' + series.index + '_Point_' + previous.index, 'none', series.width, series.setPointColor(previous, series.interior), series.opacity, series.dashArray, direction));\n startPoint = 'M';\n direction = '';\n }\n else {\n startPoint = 'L';\n }\n }\n else {\n if (this.setPointColor(point, segmentPoint, series, series.segmentAxis === 'X', segments) && direction !== '') {\n options.push(new PathOption(series.chart.element.id + '_Series_' + series.index + '_Point_' + segmentPoint.index, 'none', series.width, series.setPointColor(segmentPoint, series.interior), series.opacity, series.dashArray, direction));\n startPoint = 'M';\n direction = '';\n }\n }\n previous = point;\n segmentPoint = point;\n this.storePointLocation(point, series, isInverted, getPoint);\n }\n else {\n previous = (series.emptyPointSettings.mode === 'Drop') ? previous : null;\n startPoint = (series.emptyPointSettings.mode === 'Drop') ? startPoint : 'M';\n point.symbolLocations = [];\n }\n }\n if (direction !== '') {\n options.push(new PathOption(series.chart.element.id + '_Series_' + series.index, 'none', series.width, series.setPointColor(lastPoint, series.interior), series.opacity, series.dashArray, direction));\n }\n this.applySegmentAxis(series, options, segments);\n this.renderMarker(series);\n };\n /**\n * Animates the series.\n *\n * @param {Series} series - Defines the series to animate.\n * @returns {void}\n */\n MultiColoredLineSeries.prototype.doAnimation = function (series) {\n this.doLinearAnimation(series, series.animation);\n };\n /**\n * Get module name.\n */\n MultiColoredLineSeries.prototype.getModuleName = function () {\n /**\n * Returns the module name of the series\n */\n return 'MultiColoredLineSeries';\n };\n /**\n * To destroy the line series.\n *\n * @returns {void}\n * @private\n */\n MultiColoredLineSeries.prototype.destroy = function () {\n /**\n * Destroy method performed here\n */\n };\n return MultiColoredLineSeries;\n}(MultiColoredSeries));\nexport { MultiColoredLineSeries };\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","/**\n * Specifies the chart constant value\n */\n/** @private */\nexport var loaded = 'loaded';\n/** @private */\nexport var legendClick = 'legendClick';\n/** @private */\nexport var load = 'load';\n/** @private */\nexport var animationComplete = 'animationComplete';\n/** @private */\nexport var legendRender = 'legendRender';\n/** @private */\nexport var textRender = 'textRender';\n/** @private */\nexport var pointRender = 'pointRender';\n/** @private */\nexport var sharedTooltipRender = 'sharedTooltipRender';\n/** @private */\nexport var seriesRender = 'seriesRender';\n/** @private */\nexport var axisLabelRender = 'axisLabelRender';\n/** @private */\nexport var axisLabelClick = 'axisLabelClick';\n/** @private */\nexport var axisRangeCalculated = 'axisRangeCalculated';\n/** @private */\nexport var axisMultiLabelRender = 'axisMultiLabelRender';\n/** @private */\nexport var tooltipRender = 'tooltipRender';\n/** @private */\nexport var chartMouseMove = 'chartMouseMove';\n/** @private */\nexport var chartMouseClick = 'chartMouseClick';\n/** @private */\nexport var chartDoubleClick = 'chartDoubleClick';\n/** @private */\nexport var pointClick = 'pointClick';\n/** @private */\nexport var pointDoubleClick = 'pointDoubleClick';\n/** @private */\nexport var pointMove = 'pointMove';\n/** @private */\nexport var chartMouseLeave = 'chartMouseLeave';\n/** @private */\nexport var chartMouseDown = 'chartMouseDown';\n/** @private */\nexport var chartMouseUp = 'chartMouseUp';\n/** @private */\nexport var zoomComplete = 'zoomComplete';\n/** @private */\nexport var dragComplete = 'dragComplete';\n/** @private */\nexport var selectionComplete = 'selectionComplete';\n/** @private */\nexport var resized = 'resized';\n/** @private */\nexport var beforeResize = 'beforeResize';\n/** @private */\nexport var beforePrint = 'beforePrint';\n/** @private */\nexport var annotationRender = 'annotationRender';\n/** @private */\nexport var scrollStart = 'scrollStart';\n/** @private */\nexport var scrollEnd = 'scrollEnd';\n/** @private */\nexport var scrollChanged = 'scrollChanged';\n/** @private */\nexport var stockEventRender = 'stockEventRender';\n/** @private */\nexport var multiLevelLabelClick = 'multiLevelLabelClick';\n/** @private */\nexport var dragStart = 'dragStart';\n/** @private */\nexport var drag = 'drag';\n/** @private */\nexport var dragEnd = 'dragEnd';\n/*** @private*/\nexport var regSub = /~\\d+~/g;\n/*** @private*/\nexport var regSup = /\\^\\d+\\^/g;\n/** @private */\nexport var beforeExport = 'beforeExport';\n/** @private */\nexport var afterExport = 'afterExport';\n/** @private */\nexport var bulletChartMouseClick = 'bulletChartMouseClick';\n/** @private */\nexport var onZooming = 'onZooming';\n","//! moment.js locale configuration\n//! locale : Malay [ms-my]\n//! note : DEPRECATED, the correct one is [ms]\n//! author : Weldan Jamili : https://github.com/weldan\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var msMy = moment.defineLocale('ms-my', {\n months: 'Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis'.split('_'),\n weekdays: 'Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu'.split('_'),\n weekdaysShort: 'Ahd_Isn_Sel_Rab_Kha_Jum_Sab'.split('_'),\n weekdaysMin: 'Ah_Is_Sl_Rb_Km_Jm_Sb'.split('_'),\n longDateFormat: {\n LT: 'HH.mm',\n LTS: 'HH.mm.ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY [pukul] HH.mm',\n LLLL: 'dddd, D MMMM YYYY [pukul] HH.mm',\n },\n meridiemParse: /pagi|tengahari|petang|malam/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'pagi') {\n return hour;\n } else if (meridiem === 'tengahari') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === 'petang' || meridiem === 'malam') {\n return hour + 12;\n }\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours < 11) {\n return 'pagi';\n } else if (hours < 15) {\n return 'tengahari';\n } else if (hours < 19) {\n return 'petang';\n } else {\n return 'malam';\n }\n },\n calendar: {\n sameDay: '[Hari ini pukul] LT',\n nextDay: '[Esok pukul] LT',\n nextWeek: 'dddd [pukul] LT',\n lastDay: '[Kelmarin pukul] LT',\n lastWeek: 'dddd [lepas pukul] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'dalam %s',\n past: '%s yang lepas',\n s: 'beberapa saat',\n ss: '%d saat',\n m: 'seminit',\n mm: '%d minit',\n h: 'sejam',\n hh: '%d jam',\n d: 'sehari',\n dd: '%d hari',\n M: 'sebulan',\n MM: '%d bulan',\n y: 'setahun',\n yy: '%d tahun',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return msMy;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { getActualDesiredIntervalsCount, triggerLabelRender } from '../../common/utils/helper';\nimport { DoubleRange } from '../utils/double-range';\nimport { withIn } from '../../common/utils/helper';\nimport { extend, getValue, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { NiceInterval } from '../axis/axis-helper';\n/**\n * `Category` module is used to render category axis.\n */\nvar Category = /** @class */ (function (_super) {\n __extends(Category, _super);\n /**\n * Constructor for the category module.\n *\n * @private\n */\n function Category(chart) {\n return _super.call(this, chart) || this;\n }\n /**\n * The function to calculate the range and labels for the axis.\n *\n * @returns {void}\n */\n Category.prototype.calculateRangeAndInterval = function (size, axis) {\n this.calculateRange(axis);\n this.getActualRange(axis, size);\n this.applyRangePadding(axis, size);\n this.calculateVisibleLabels(axis);\n };\n /**\n * Actual Range for the axis.\n *\n * @private\n */\n Category.prototype.getActualRange = function (axis, size) {\n this.initializeDoubleRange(axis);\n // axis.doubleRange = new DoubleRange(<number>this.min, <number>this.max);\n axis.actualRange = {};\n if (!axis.interval) {\n axis.actualRange.interval = Math.max(1, Math.floor(axis.doubleRange.delta / getActualDesiredIntervalsCount(size, axis)));\n }\n else {\n axis.actualRange.interval = Math.ceil(axis.interval);\n }\n axis.actualRange.min = axis.doubleRange.start;\n axis.actualRange.max = axis.doubleRange.end;\n axis.actualRange.delta = axis.doubleRange.delta;\n };\n /**\n * Padding for the axis.\n *\n * @private\n */\n Category.prototype.applyRangePadding = function (axis, size) {\n var isColumn;\n axis.series.forEach(function (element) {\n if (!isColumn) {\n isColumn = element.type.indexOf('Column') > -1 && !(axis.zoomFactor < 1 || axis.zoomPosition > 0) && isNullOrUndefined(axis.minimum) && isNullOrUndefined(axis.maximum);\n }\n });\n var ticks = ((axis.labelPlacement === 'BetweenTicks' || isColumn) && !this.chart.stockChart && this.chart.chartAreaType !== 'PolarRadar') ? 0.5 : 0;\n if (ticks > 0) {\n axis.actualRange.min -= ticks;\n axis.actualRange.max += ticks;\n }\n else {\n axis.actualRange.max += axis.actualRange.max ? 0 : 0.5;\n }\n axis.doubleRange = new DoubleRange(axis.actualRange.min, axis.actualRange.max);\n axis.actualRange.delta = axis.doubleRange.delta;\n this.calculateVisibleRange(size, axis);\n };\n /**\n * Calculate label for the axis.\n *\n * @private\n */\n Category.prototype.calculateVisibleLabels = function (axis) {\n /*! Generate axis labels */\n axis.visibleLabels = [];\n axis.visibleRange.interval = axis.visibleRange.interval < 1 ? 1 : axis.visibleRange.interval;\n var tempInterval = Math.ceil(axis.visibleRange.min);\n var labelStyle;\n if (axis.zoomFactor < 1 || axis.zoomPosition > 0) {\n tempInterval = axis.visibleRange.min - (axis.visibleRange.min % axis.visibleRange.interval);\n }\n var position;\n axis.startLabel = axis.labels[Math.round(axis.visibleRange.min)];\n axis.endLabel = axis.labels[Math.floor(axis.visibleRange.max)];\n for (; tempInterval <= axis.visibleRange.max; tempInterval += axis.visibleRange.interval) {\n labelStyle = (extend({}, getValue('properties', axis.labelStyle), null, true));\n if (withIn(tempInterval, axis.visibleRange) && axis.labels.length > 0) {\n position = Math.round(tempInterval);\n triggerLabelRender(this.chart, position, axis.labels[position] ? axis.labels[position].toString() : '', labelStyle, axis);\n }\n }\n if (axis.getMaxLabelWidth) {\n axis.getMaxLabelWidth(this.chart);\n }\n };\n /**\n * Get module name\n */\n Category.prototype.getModuleName = function () {\n /**\n * Returns the module name\n */\n return 'Category';\n };\n /**\n * To destroy the category axis.\n *\n * @returns {void}\n * @private\n */\n Category.prototype.destroy = function () {\n /**\n * Destroy method performed here\n */\n };\n return Category;\n}(NiceInterval));\nexport { Category };\n","//! moment.js locale configuration\n//! locale : Esperanto [eo]\n//! author : Colin Dean : https://github.com/colindean\n//! author : Mia Nordentoft Imperatori : https://github.com/miestasmia\n//! comment : miestasmia corrected the translation by colindean\n//! comment : Vivakvo corrected the translation by colindean and miestasmia\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var eo = moment.defineLocale('eo', {\n months: 'januaro_februaro_marto_aprilo_majo_junio_julio_aÅgusto_septembro_oktobro_novembro_decembro'.split(\n '_'\n ),\n monthsShort: 'jan_feb_mart_apr_maj_jun_jul_aÅg_sept_okt_nov_dec'.split('_'),\n weekdays: 'dimanĉo_lundo_mardo_merkredo_ĵaÅdo_vendredo_sabato'.split('_'),\n weekdaysShort: 'dim_lun_mard_merk_ĵaÅ_ven_sab'.split('_'),\n weekdaysMin: 'di_lu_ma_me_ĵa_ve_sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY-MM-DD',\n LL: '[la] D[-an de] MMMM, YYYY',\n LLL: '[la] D[-an de] MMMM, YYYY HH:mm',\n LLLL: 'dddd[n], [la] D[-an de] MMMM, YYYY HH:mm',\n llll: 'ddd, [la] D[-an de] MMM, YYYY HH:mm',\n },\n meridiemParse: /[ap]\\.t\\.m/i,\n isPM: function (input) {\n return input.charAt(0).toLowerCase() === 'p';\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours > 11) {\n return isLower ? 'p.t.m.' : 'P.T.M.';\n } else {\n return isLower ? 'a.t.m.' : 'A.T.M.';\n }\n },\n calendar: {\n sameDay: '[HodiaÅ je] LT',\n nextDay: '[MorgaÅ je] LT',\n nextWeek: 'dddd[n je] LT',\n lastDay: '[HieraÅ je] LT',\n lastWeek: '[pasintan] dddd[n je] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'post %s',\n past: 'antaÅ %s',\n s: 'kelkaj sekundoj',\n ss: '%d sekundoj',\n m: 'unu minuto',\n mm: '%d minutoj',\n h: 'unu horo',\n hh: '%d horoj',\n d: 'unu tago', //ne 'diurno', ĉar estas uzita por proksimumo\n dd: '%d tagoj',\n M: 'unu monato',\n MM: '%d monatoj',\n y: 'unu jaro',\n yy: '%d jaroj',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}a/,\n ordinal: '%da',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return eo;\n\n})));\n","//! moment.js locale configuration\n//! locale : Sindhi [sd]\n//! author : Narain Sagar : https://github.com/narainsagar\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var months = [\n 'جنوري',\n 'Ùيبروري',\n 'مارچ',\n 'اپريل',\n 'مئي',\n 'جون',\n 'جولاءÙ',\n 'آگسٽ',\n 'سيپٽمبر',\n 'آڪٽوبر',\n 'نومبر',\n 'ڊسمبر',\n ],\n days = ['آچر', 'سومر', 'اڱارو', 'اربع', 'خميس', 'جمع', 'ڇنڇر'];\n\n var sd = moment.defineLocale('sd', {\n months: months,\n monthsShort: months,\n weekdays: days,\n weekdaysShort: days,\n weekdaysMin: days,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'ddddØŒ D MMMM YYYY HH:mm',\n },\n meridiemParse: /صبØ|شام/,\n isPM: function (input) {\n return 'شام' === input;\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'صبØ';\n }\n return 'شام';\n },\n calendar: {\n sameDay: '[اڄ] LT',\n nextDay: '[سڀاڻي] LT',\n nextWeek: 'dddd [اڳين Ù‡Ùتي تي] LT',\n lastDay: '[ڪالهه] LT',\n lastWeek: '[گزريل Ù‡Ùتي] dddd [تي] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s پوء',\n past: '%s اڳ',\n s: 'چند سيڪنڊ',\n ss: '%d سيڪنڊ',\n m: 'Ù‡Úª منٽ',\n mm: '%d منٽ',\n h: 'Ù‡Úª ڪلاڪ',\n hh: '%d ڪلاڪ',\n d: 'Ù‡Úª Úينهن',\n dd: '%d Úينهن',\n M: 'Ù‡Úª مهينو',\n MM: '%d مهينا',\n y: 'Ù‡Úª سال',\n yy: '%d سال',\n },\n preparse: function (string) {\n return string.replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string.replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return sd;\n\n})));\n","/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable max-len */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable valid-jsdoc */\n/**\n * StripLine src\n */\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { valueToCoefficient, textElement, RectOption, appendChildElement, appendClipElement, withIn, getElement, ImageOption } from '../../common/utils/helper';\nimport { measureText, TextOption, PathOption, Rect } from '@syncfusion/ej2-svg-base';\nimport { DataUtil } from '@syncfusion/ej2-data';\n/**\n * `StripLine` module is used to render the stripLine in chart.\n */\nvar StripLine = /** @class */ (function () {\n function StripLine() {\n }\n /**\n * Finding x, y, width and height of the strip line\n *\n * @param {Axis} axis axis\n * @param {StripLineSettingsModel} stripline stripline\n * @param {Rect} seriesClipRect seriesClipRect\n * @param {number} startValue startValue\n * @param {Axis} segmentAxis segmentAxis\n * @param {Chart} chart chart instance\n */\n StripLine.prototype.measureStripLine = function (axis, stripline, seriesClipRect, startValue, segmentAxis, chart) {\n var actualStart;\n var actualEnd;\n var orientation = axis.orientation;\n var isDateTimeAxis = axis.valueType === 'DateTime';\n if (stripline.isRepeat && stripline.size !== null) {\n actualStart = startValue;\n actualEnd = null;\n }\n else {\n if (axis.valueType === 'DateTimeCategory') {\n var start = stripline.start;\n var end = stripline.end;\n actualStart = (start != null && typeof start !== 'number') ?\n axis.labels.indexOf(this.dateToMilliSeconds(start, chart).toString()) : start;\n actualEnd = (end != null && typeof end !== 'number') ?\n axis.labels.indexOf(this.dateToMilliSeconds(end, chart).toString()) : end;\n }\n else {\n actualStart = stripline.start === null ? null : isDateTimeAxis && this.isCoreDate(stripline.start) ?\n this.dateToMilliSeconds(stripline.start, chart) : +stripline.start;\n actualEnd = stripline.end === null ? null : isDateTimeAxis && this.isCoreDate(stripline.start) ?\n this.dateToMilliSeconds(stripline.end, chart) : +stripline.end;\n }\n }\n var rect = this.getFromTovalue(actualStart, actualEnd, stripline.size, stripline.startFromAxis, axis, stripline);\n var height = (orientation === 'Vertical') ? (rect.to - rect.from) * axis.rect.height : seriesClipRect.height;\n var width = (orientation === 'Horizontal') ? (rect.to - rect.from) * axis.rect.width : seriesClipRect.width;\n var x = (orientation === 'Vertical') ? seriesClipRect.x : ((rect.from * axis.rect.width) + axis.rect.x);\n var y = (orientation === 'Horizontal') ? seriesClipRect.y : (axis.rect.y + axis.rect.height -\n ((stripline.sizeType === 'Pixel' ? rect.from : rect.to) * axis.rect.height));\n if (stripline.isSegmented && stripline.segmentStart != null && stripline.segmentEnd != null && stripline.sizeType !== 'Pixel') {\n var start = isDateTimeAxis && this.isCoreDate(stripline.segmentStart) ?\n this.dateToMilliSeconds(stripline.segmentStart, chart) : +stripline.segmentStart;\n var end = isDateTimeAxis && this.isCoreDate(stripline.segmentEnd) ?\n this.dateToMilliSeconds(stripline.segmentEnd, chart) : +stripline.segmentEnd;\n var segRect = this.getFromTovalue(start, end, null, null, segmentAxis, stripline);\n if (segmentAxis.orientation === 'Vertical') {\n y = (segmentAxis.rect.y + segmentAxis.rect.height -\n (segRect.to * segmentAxis.rect.height));\n height = (segRect.to - segRect.from) * segmentAxis.rect.height;\n }\n else {\n x = ((segRect.from * segmentAxis.rect.width) + segmentAxis.rect.x);\n width = (segRect.to - segRect.from) * segmentAxis.rect.width;\n }\n }\n if ((height !== 0 && width !== 0) || (stripline.sizeType === 'Pixel' && (stripline.start !== null || stripline.startFromAxis))) {\n return new Rect(x, y, width, height);\n }\n return new Rect(0, 0, 0, 0);\n };\n /**\n * To get from to value from start, end, size, start from axis\n *\n * @param {number} start start\n * @param {number} end end\n * @param {number} size size\n * @param {boolean} startFromAxis startFromAxis\n * @param {Axis} axis axis\n * @param {StripLineSettingsModel} stripline stripline\n */\n StripLine.prototype.getFromTovalue = function (start, end, size, startFromAxis, axis, stripline) {\n var from = (!stripline.isRepeat && startFromAxis) ? axis.visibleRange.min : start;\n if (axis.valueType === 'Double' && size !== null && !startFromAxis && stripline.start == null) {\n from += size;\n }\n var to = this.getToValue(Math.max(start, isNullOrUndefined(end) ? start : end), from, size, axis, end, stripline);\n from = this.findValue(from, axis);\n to = this.findValue(to, axis);\n return { from: valueToCoefficient(axis.isAxisInverse ? to : from, axis), to: valueToCoefficient(axis.isAxisInverse ? from : to, axis) };\n };\n /**\n * Finding end value of the strip line\n *\n * @param {number} to to\n * @param {number} from from\n * @param {number} size size\n * @param {Axis} axis axis\n * @param {number} end end\n * @param {StripLineSettingsModel} stripline stripline\n */\n StripLine.prototype.getToValue = function (to, from, size, axis, end, stripline) {\n var sizeType = stripline.sizeType;\n var isEnd = (end === null);\n if (axis.valueType === 'DateTime') {\n var fromValue = new Date(from);\n if (sizeType === 'Auto') {\n sizeType = axis.actualIntervalType;\n size *= axis.visibleRange.interval;\n }\n switch (sizeType) {\n case 'Years':\n return (isEnd ? new Date(fromValue.setFullYear(fromValue.getFullYear() + size)) : to);\n case 'Months':\n return (isEnd ? new Date(fromValue.setMonth(fromValue.getMonth() + size)) : to);\n case 'Days':\n return (isEnd ? new Date(fromValue.setDate(fromValue.getDate() + size)) : to);\n case 'Hours':\n return (isEnd ? new Date(fromValue.setHours(fromValue.getHours() + size)) : to);\n case 'Minutes':\n return (isEnd ? new Date(fromValue.setMinutes(fromValue.getMinutes() + size)) : to);\n case 'Seconds':\n return (isEnd ? new Date(fromValue.setSeconds(fromValue.getSeconds() + size)) : to);\n default:\n return from;\n }\n }\n else {\n return stripline.sizeType === 'Pixel' ? from : (isEnd ? (from + size) : to);\n }\n };\n /**\n * To check the strip line values within range\n *\n * @param {number} value value\n * @param {Axis} axis axis\n */\n StripLine.prototype.findValue = function (value, axis) {\n if (value < axis.visibleRange.min) {\n value = axis.visibleRange.min;\n }\n else if (value > axis.visibleRange.max) {\n value = axis.visibleRange.max;\n }\n return value;\n };\n /**\n * Date parse\n *\n * @param {Date} value date\n * @param {Chart} chart chart instance\n * @returns {Date} parsed date\n */\n StripLine.prototype.dateParse = function (value, chart) {\n var dateParser = chart.intl.getDateParser({ skeleton: 'full', type: 'dateTime' });\n var dateFormatter = chart.intl.getDateFormat({ skeleton: 'full', type: 'dateTime' });\n return new Date((Date.parse(dateParser(dateFormatter(new Date(DataUtil.parse.parseJson({ val: value }).val))))));\n };\n /**\n * To render strip lines based start and end.\n *\n * @param {Chart} chart chart\n * @param {ZIndex} position position\n * @param {Axis[]} axes axes\n * @private\n */\n StripLine.prototype.renderStripLine = function (chart, position, axes) {\n var id = chart.element.id + '_stripline_' + position + '_';\n var seriesClipRect = chart.chartAxisLayoutPanel.seriesClipRect;\n var end = 0;\n var limit = 0;\n var startValue = 0;\n var segmentAxis = null;\n var range;\n var options = new RectOption(id + 'ClipRect', 'transparent', { width: 1, color: 'Gray' }, 1, {\n x: seriesClipRect.x, y: seriesClipRect.y,\n width: seriesClipRect.width,\n height: seriesClipRect.height\n });\n var striplineGroup = chart.renderer.createGroup({\n id: id + 'collections',\n 'clip-path': 'url(#' + id + 'ClipRect' + ')'\n });\n if (!chart.enableCanvas) {\n striplineGroup.appendChild(appendClipElement(chart.redraw, options, chart.renderer));\n }\n for (var _i = 0, axes_1 = axes; _i < axes_1.length; _i++) {\n var axis = axes_1[_i];\n var count = 0;\n for (var _a = 0, _b = axis.stripLines; _a < _b.length; _a++) {\n var stripline = _b[_a];\n if (stripline.visible && stripline.zIndex === position) {\n if (stripline.isSegmented && stripline.segmentStart != null && stripline.segmentEnd != null &&\n stripline.sizeType !== 'Pixel') {\n segmentAxis = this.getSegmentAxis(axes, axis, stripline);\n }\n if (stripline.isRepeat && stripline.repeatEvery != null && stripline.size !== null && stripline.sizeType !== 'Pixel') {\n limit = (stripline.repeatUntil != null) ? ((axis.valueType === 'DateTime') ?\n this.dateToMilliSeconds(stripline.repeatUntil, chart) : +stripline.repeatUntil) : axis.actualRange.max;\n startValue = axis.valueType === 'DateTime' && this.isCoreDate(stripline.start) ?\n this.dateToMilliSeconds(stripline.start, chart) : stripline.start;\n if ((stripline.startFromAxis && axis.valueType === 'DateTime' && stripline.sizeType === 'Auto') ||\n (stripline.start < axis.visibleRange.min)) {\n startValue = axis.visibleLabels[0].value === axis.visibleRange.min ? axis.visibleRange.min :\n axis.visibleLabels[0].value - (axis.valueType === 'DateTime' ? axis.dateTimeInterval :\n axis.visibleRange.interval);\n }\n startValue = stripline.startFromAxis && axis.valueType !== 'DateTime' ? axis.visibleRange.min : startValue;\n while (startValue < limit) {\n end = (startValue + (axis.valueType === 'DateTime' ? axis.dateTimeInterval * +stripline.size : stripline.size));\n range = withIn(end, axis.visibleRange);\n if ((startValue >= axis.visibleRange.min && startValue < axis.visibleRange.max) || range) {\n this.renderStripLineElement(axis, stripline, seriesClipRect, id, striplineGroup, chart, startValue, segmentAxis, count);\n }\n count++;\n startValue = this.getStartValue(axis, stripline, startValue, chart);\n }\n }\n else {\n this.renderStripLineElement(axis, stripline, seriesClipRect, id, striplineGroup, chart, null, segmentAxis, count);\n count++;\n }\n }\n }\n }\n appendChildElement(chart.enableCanvas, chart.svgObject, striplineGroup, chart.redraw);\n };\n /**\n * To convert the C# date to js date\n *\n * @param {string | number | Object} value date value\n * @returns {boolean} returns true if datetime value type is string(for asp platform)\n */\n StripLine.prototype.isCoreDate = function (value) {\n return typeof value === 'string' ? true : false;\n };\n /**\n * To get the total milli seconds\n *\n * @param {Date | number | Object} value date value\n * @param {Chart} chart chart instance\n * @returns {number} returns milliseconds\n */\n StripLine.prototype.dateToMilliSeconds = function (value, chart) {\n return this.dateParse(value, chart).getTime();\n };\n /**\n * To draw the single line strip line\n *\n * @param {StripLineSettingsModel} stripline stripline\n * @param {Rect} rect rect\n * @param {string} id id\n * @param {Element} parent parent\n * @param {Chart} chart chart\n * @param {Axis} axis axis\n */\n StripLine.prototype.renderPath = function (stripline, rect, id, parent, chart, axis) {\n var element = getElement(id);\n var direction = element ? element.getAttribute('d') : '';\n var strokeWidth = stripline.size;\n var d = (axis.orientation === 'Vertical') ? ('M ' + rect.x + ' ' + rect.y + ' ' + 'L ' + (rect.x + rect.width)\n + ' ' + rect.y) :\n ('M ' + rect.x + ' ' + rect.y + ' ' + 'L ' + rect.x + ' ' + (rect.y + rect.height));\n if (stripline.sizeType !== 'Pixel') {\n d = (axis.orientation === 'Vertical') ? ('M ' + rect.x + ' ' + (rect.y + (rect.height / 2)) + ' ' + 'L ' + (rect.x + rect.width)\n + ' ' + (rect.y + (rect.height / 2))) :\n ('M ' + (rect.x + (rect.width / 2)) + ' ' + rect.y + ' ' + 'L ' + (rect.x + (rect.width / 2)) + ' ' + (rect.y + rect.height));\n strokeWidth = axis.orientation === 'Vertical' ? rect.height : rect.width;\n }\n appendChildElement(chart.enableCanvas, parent, chart.renderer.drawPath(new PathOption(id, 'none', strokeWidth, stripline.color, stripline.opacity, stripline.dashArray, d)), chart.redraw, true, 'x', 'y', null, direction, true);\n };\n /**\n * To draw the rectangle\n *\n * @param {StripLineSettingsModel} stripline stripline\n * @param {Rect} rect rect\n * @param {string} id id\n * @param {Element} parent parent\n * @param {Chart} chart chart\n */\n StripLine.prototype.renderRectangle = function (stripline, rect, id, parent, chart) {\n var element = getElement(id);\n var previousRect = element ? new Rect(+element.getAttribute('x'), +element.getAttribute('y'), +element.getAttribute('width'), +element.getAttribute('height')) : null;\n appendChildElement(chart.enableCanvas, parent, chart.renderer.drawRectangle(new RectOption(id, 'none', stripline.border, stripline.opacity, rect, 0, 0, '', null)), chart.redraw, true, 'x', 'y', null, null, true, true, previousRect);\n };\n /**\n * To draw the Image\n *\n * @param {StripLineSettingsModel} stripline stripline\n * @param {Rect} rect rect\n * @param {string} id id\n * @param {Element} parent parent\n * @param {Chart} chart chart\n */\n StripLine.prototype.drawImage = function (stripline, rect, id, parent, chart) {\n if (stripline.sizeType === 'Pixel') {\n rect.width = rect.width ? rect.width : stripline.size;\n rect.height = rect.height ? rect.height : stripline.size;\n }\n var image = new ImageOption(rect.height, rect.width, stripline.imageUrl, rect.x, rect.y, id, 'visible', 'none');\n var htmlObject = chart.renderer.drawImage(image);\n appendChildElement(chart.enableCanvas, parent, htmlObject, chart.redraw, true, 'x', 'y', null, null, true, true);\n };\n /**\n * To create the text on strip line\n *\n * @param {StripLineSettingsModel} stripline stripline\n * @param {Rect} rect rect\n * @param {string} id id\n * @param {Element} parent parent\n * @param {Chart} chart chart\n * @param {Axis} axis axis\n */\n StripLine.prototype.renderText = function (stripline, rect, id, parent, chart, axis) {\n var textSize = measureText(stripline.text, stripline.textStyle, chart.themeStyle.stripLineLabelFont);\n var isRotationNull = (stripline.rotation === null);\n var textMid = isRotationNull ? 3 * (textSize.height / 8) : 0;\n var ty = rect.y + (rect.height / 2) + textMid;\n var rotation = isRotationNull ? ((axis.orientation === 'Vertical') ? 0 : -90) : stripline.rotation;\n var tx = rect.x + (rect.width / 2);\n var anchor;\n var padding = 5;\n if (axis.orientation === 'Horizontal') {\n tx = this.getTextStart(tx + (textMid * this.factor(stripline.horizontalAlignment)), rect.width, stripline.horizontalAlignment);\n ty = this.getTextStart(ty - textMid, rect.height, stripline.verticalAlignment) +\n (stripline.verticalAlignment === 'Start' && !isRotationNull ? (textSize.height / 4) : 0);\n anchor = isRotationNull ? this.invertAlignment(stripline.verticalAlignment) : stripline.horizontalAlignment;\n anchor = tx - textSize.width / 2 < axis.rect.x ? 'Start' : tx + textSize.width / 2 > axis.rect.width ? 'End' : anchor;\n }\n else {\n tx = this.getTextStart(tx, rect.width, stripline.horizontalAlignment);\n ty = this.getTextStart(ty + (textMid * this.factor(stripline.verticalAlignment)) - padding, rect.height, stripline.verticalAlignment);\n anchor = stripline.horizontalAlignment;\n anchor = chart.enableRtl ? (anchor === 'End' ? 'Start' : anchor === 'Start' ? 'End' : anchor) : anchor;\n }\n textElement(chart.renderer, new TextOption(id, tx, ty, anchor, stripline.text, 'rotate(' + rotation + ' ' + tx + ',' + ty + ')', 'middle'), stripline.textStyle, stripline.textStyle.color || chart.themeStyle.stripLineLabelFont.color, parent, null, null, null, null, null, null, null, null, chart.enableCanvas, null, chart.themeStyle.stripLineLabelFont);\n };\n StripLine.prototype.invertAlignment = function (anchor) {\n switch (anchor) {\n case 'Start':\n anchor = 'End';\n break;\n case 'End':\n anchor = 'Start';\n break;\n }\n return anchor;\n };\n /**\n * To find the next value of the recurrence strip line\n *\n * @param {Axis} axis axis\n * @param {StripLineSettingsModel} stripline stripline\n * @param {number} startValue startValue\n * @param {Chart} chart chart instance\n * @returns {number} next start value of the recurrence strip line\n */\n StripLine.prototype.getStartValue = function (axis, stripline, startValue, chart) {\n if (axis.valueType === 'DateTime') {\n return (this.getToValue(null, startValue, +stripline.repeatEvery, axis, null, stripline));\n }\n else {\n return startValue + (+stripline.repeatEvery);\n }\n };\n /**\n * Finding segment axis for segmented strip line\n *\n * @param {Axis[]} axes axes collection\n * @param {Axis} axis axis\n * @param {StripLineSettingsModel} stripline stripline\n */\n StripLine.prototype.getSegmentAxis = function (axes, axis, stripline) {\n var segment;\n if (stripline.segmentAxisName == null) {\n return (axis.orientation === 'Horizontal') ? axes[1] : axes[0];\n }\n else {\n for (var i = 0; i < axes.length; i++) {\n if (stripline.segmentAxisName === axes[i].name) {\n segment = axes[i];\n }\n }\n return segment;\n }\n };\n /**\n * To render strip line on chart\n *\n * @param {Axis} axis axis\n * @param {StripLineSettingsModel} stripline stripline\n * @param {Rect} seriesClipRect seriesClipRect\n * @param {string} id id\n * @param {Element} striplineGroup striplineGroup\n * @param {Chart} chart chart\n * @param {number} startValue startValue\n * @param {Axis} segmentAxis segmentAxis\n * @param {number} count count\n */\n StripLine.prototype.renderStripLineElement = function (axis, stripline, seriesClipRect, id, striplineGroup, chart, startValue, segmentAxis, count) {\n var rect = this.measureStripLine(axis, stripline, seriesClipRect, startValue, segmentAxis, chart);\n if (stripline.imageUrl) {\n this.drawImage(stripline, rect, id + 'rect_' + axis.name + '_' + count, striplineGroup, chart);\n }\n else {\n this.renderPath(stripline, rect, id + (stripline.sizeType === 'Pixel' ? 'path_' : 'rect_') + axis.name + '_' + count, striplineGroup, chart, axis);\n var pixelRect = new Rect(axis.orientation === 'Horizontal' ? (rect.x - stripline.size / 2) : rect.x, axis.orientation === 'Vertical' ? (rect.y - stripline.size / 2) : rect.y, rect.width ? rect.width : stripline.size, rect.height ? rect.height : stripline.size);\n this.renderRectangle(stripline, stripline.sizeType === 'Pixel' ? pixelRect : rect, id + 'border_' + axis.name + '_' + count, striplineGroup, chart);\n }\n if (stripline.text !== '') {\n this.renderText(stripline, rect, id + 'text_' + axis.name + '_' + count, striplineGroup, chart, axis);\n }\n };\n /**\n * To find the factor of the text\n *\n * @param {Anchor} anchor text anchor\n */\n StripLine.prototype.factor = function (anchor) {\n var factor = 0;\n switch (anchor) {\n case 'Start':\n factor = 1;\n break;\n case 'End':\n factor = -1;\n break;\n }\n return factor;\n };\n /**\n * To find the start value of the text\n *\n * @param {number} xy xy values\n * @param {number} size text size\n * @param {Anchor} textAlignment text alignment\n */\n StripLine.prototype.getTextStart = function (xy, size, textAlignment) {\n var padding = 5;\n switch (textAlignment) {\n case 'Start':\n xy = xy - (size / 2) + padding;\n break;\n case 'End':\n xy = xy + (size / 2) - padding;\n break;\n }\n return xy;\n };\n /**\n * To get the module name for `StripLine`.\n *\n * @private\n */\n StripLine.prototype.getModuleName = function () {\n return 'StripLine';\n };\n /**\n * To destroy the `StripLine` module.\n *\n * @private\n */\n StripLine.prototype.destroy = function () {\n // destroy peform here\n };\n return StripLine;\n}());\nexport { StripLine };\n","//! moment.js locale configuration\n//! locale : Breton [br]\n//! author : Jean-Baptiste Le Duigou : https://github.com/jbleduigou\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function relativeTimeWithMutation(number, withoutSuffix, key) {\n var format = {\n mm: 'munutenn',\n MM: 'miz',\n dd: 'devezh',\n };\n return number + ' ' + mutation(format[key], number);\n }\n function specialMutationForYears(number) {\n switch (lastNumber(number)) {\n case 1:\n case 3:\n case 4:\n case 5:\n case 9:\n return number + ' bloaz';\n default:\n return number + ' vloaz';\n }\n }\n function lastNumber(number) {\n if (number > 9) {\n return lastNumber(number % 10);\n }\n return number;\n }\n function mutation(text, number) {\n if (number === 2) {\n return softMutation(text);\n }\n return text;\n }\n function softMutation(text) {\n var mutationTable = {\n m: 'v',\n b: 'v',\n d: 'z',\n };\n if (mutationTable[text.charAt(0)] === undefined) {\n return text;\n }\n return mutationTable[text.charAt(0)] + text.substring(1);\n }\n\n var monthsParse = [\n /^gen/i,\n /^c[ʼ\\']hwe/i,\n /^meu/i,\n /^ebr/i,\n /^mae/i,\n /^(mez|eve)/i,\n /^gou/i,\n /^eos/i,\n /^gwe/i,\n /^her/i,\n /^du/i,\n /^ker/i,\n ],\n monthsRegex =\n /^(genver|c[ʼ\\']hwevrer|meurzh|ebrel|mae|mezheven|gouere|eost|gwengolo|here|du|kerzu|gen|c[ʼ\\']hwe|meu|ebr|mae|eve|gou|eos|gwe|her|du|ker)/i,\n monthsStrictRegex =\n /^(genver|c[ʼ\\']hwevrer|meurzh|ebrel|mae|mezheven|gouere|eost|gwengolo|here|du|kerzu)/i,\n monthsShortStrictRegex =\n /^(gen|c[ʼ\\']hwe|meu|ebr|mae|eve|gou|eos|gwe|her|du|ker)/i,\n fullWeekdaysParse = [\n /^sul/i,\n /^lun/i,\n /^meurzh/i,\n /^merc[ʼ\\']her/i,\n /^yaou/i,\n /^gwener/i,\n /^sadorn/i,\n ],\n shortWeekdaysParse = [\n /^Sul/i,\n /^Lun/i,\n /^Meu/i,\n /^Mer/i,\n /^Yao/i,\n /^Gwe/i,\n /^Sad/i,\n ],\n minWeekdaysParse = [\n /^Su/i,\n /^Lu/i,\n /^Me([^r]|$)/i,\n /^Mer/i,\n /^Ya/i,\n /^Gw/i,\n /^Sa/i,\n ];\n\n var br = moment.defineLocale('br', {\n months: 'Genver_Cʼhwevrer_Meurzh_Ebrel_Mae_Mezheven_Gouere_Eost_Gwengolo_Here_Du_Kerzu'.split(\n '_'\n ),\n monthsShort: 'Gen_Cʼhwe_Meu_Ebr_Mae_Eve_Gou_Eos_Gwe_Her_Du_Ker'.split('_'),\n weekdays: 'Sul_Lun_Meurzh_Mercʼher_Yaou_Gwener_Sadorn'.split('_'),\n weekdaysShort: 'Sul_Lun_Meu_Mer_Yao_Gwe_Sad'.split('_'),\n weekdaysMin: 'Su_Lu_Me_Mer_Ya_Gw_Sa'.split('_'),\n weekdaysParse: minWeekdaysParse,\n fullWeekdaysParse: fullWeekdaysParse,\n shortWeekdaysParse: shortWeekdaysParse,\n minWeekdaysParse: minWeekdaysParse,\n\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex: monthsStrictRegex,\n monthsShortStrictRegex: monthsShortStrictRegex,\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D [a viz] MMMM YYYY',\n LLL: 'D [a viz] MMMM YYYY HH:mm',\n LLLL: 'dddd, D [a viz] MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Hiziv da] LT',\n nextDay: '[Warcʼhoazh da] LT',\n nextWeek: 'dddd [da] LT',\n lastDay: '[Decʼh da] LT',\n lastWeek: 'dddd [paset da] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'a-benn %s',\n past: '%s ʼzo',\n s: 'un nebeud segondennoù',\n ss: '%d eilenn',\n m: 'ur vunutenn',\n mm: relativeTimeWithMutation,\n h: 'un eur',\n hh: '%d eur',\n d: 'un devezh',\n dd: relativeTimeWithMutation,\n M: 'ur miz',\n MM: relativeTimeWithMutation,\n y: 'ur bloaz',\n yy: specialMutationForYears,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(añ|vet)/,\n ordinal: function (number) {\n var output = number === 1 ? 'añ' : 'vet';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n meridiemParse: /a.m.|g.m./, // goude merenn | a-raok merenn\n isPM: function (token) {\n return token === 'g.m.';\n },\n meridiem: function (hour, minute, isLower) {\n return hour < 12 ? 'a.m.' : 'g.m.';\n },\n });\n\n return br;\n\n})));\n","//! moment.js locale configuration\n//! locale : Maori [mi]\n//! author : John Corrigan <robbiecloset@gmail.com> : https://github.com/johnideal\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var mi = moment.defineLocale('mi', {\n months: 'Kohi-tÄte_Hui-tanguru_PoutÅ«-te-rangi_Paenga-whÄwhÄ_Haratua_Pipiri_HÅngoingoi_Here-turi-kÅkÄ_Mahuru_Whiringa-Ä-nuku_Whiringa-Ä-rangi_Hakihea'.split(\n '_'\n ),\n monthsShort:\n 'Kohi_Hui_Pou_Pae_Hara_Pipi_HÅngoi_Here_Mahu_Whi-nu_Whi-ra_Haki'.split(\n '_'\n ),\n monthsRegex: /(?:['a-z\\u0101\\u014D\\u016B]+\\-?){1,3}/i,\n monthsStrictRegex: /(?:['a-z\\u0101\\u014D\\u016B]+\\-?){1,3}/i,\n monthsShortRegex: /(?:['a-z\\u0101\\u014D\\u016B]+\\-?){1,3}/i,\n monthsShortStrictRegex: /(?:['a-z\\u0101\\u014D\\u016B]+\\-?){1,2}/i,\n weekdays: 'RÄtapu_Mane_TÅ«rei_Wenerei_TÄite_Paraire_HÄtarei'.split('_'),\n weekdaysShort: 'Ta_Ma_TÅ«_We_TÄi_Pa_HÄ'.split('_'),\n weekdaysMin: 'Ta_Ma_TÅ«_We_TÄi_Pa_HÄ'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY [i] HH:mm',\n LLLL: 'dddd, D MMMM YYYY [i] HH:mm',\n },\n calendar: {\n sameDay: '[i teie mahana, i] LT',\n nextDay: '[apopo i] LT',\n nextWeek: 'dddd [i] LT',\n lastDay: '[inanahi i] LT',\n lastWeek: 'dddd [whakamutunga i] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'i roto i %s',\n past: '%s i mua',\n s: 'te hÄ“kona ruarua',\n ss: '%d hÄ“kona',\n m: 'he meneti',\n mm: '%d meneti',\n h: 'te haora',\n hh: '%d haora',\n d: 'he ra',\n dd: '%d ra',\n M: 'he marama',\n MM: '%d marama',\n y: 'he tau',\n yy: '%d tau',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return mi;\n\n})));\n","//! moment.js locale configuration\n//! locale : Macedonian [mk]\n//! author : Borislav Mickov : https://github.com/B0k0\n//! author : Sashko Todorov : https://github.com/bkyceh\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var mk = moment.defineLocale('mk', {\n months: 'јануари_февруари_март_април_мај_јуни_јули_авгуÑÑ‚_Ñептември_октомври_ноември_декември'.split(\n '_'\n ),\n monthsShort: 'јан_фев_мар_апр_мај_јун_јул_авг_Ñеп_окт_ное_дек'.split('_'),\n weekdays: 'недела_понеделник_вторник_Ñреда_четврток_петок_Ñабота'.split(\n '_'\n ),\n weekdaysShort: 'нед_пон_вто_Ñре_чет_пет_Ñаб'.split('_'),\n weekdaysMin: 'нe_пo_вт_ÑÑ€_че_пе_Ña'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'D.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY H:mm',\n LLLL: 'dddd, D MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[Ð”ÐµÐ½ÐµÑ Ð²Ð¾] LT',\n nextDay: '[Утре во] LT',\n nextWeek: '[Во] dddd [во] LT',\n lastDay: '[Вчера во] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n case 3:\n case 6:\n return '[Изминатата] dddd [во] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[Изминатиот] dddd [во] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'за %s',\n past: 'пред %s',\n s: 'неколку Ñекунди',\n ss: '%d Ñекунди',\n m: 'една минута',\n mm: '%d минути',\n h: 'еден чаÑ',\n hh: '%d чаÑа',\n d: 'еден ден',\n dd: '%d дена',\n M: 'еден меÑец',\n MM: '%d меÑеци',\n y: 'една година',\n yy: '%d години',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(ев|ен|ти|ви|ри|ми)/,\n ordinal: function (number) {\n var lastDigit = number % 10,\n last2Digits = number % 100;\n if (number === 0) {\n return number + '-ев';\n } else if (last2Digits === 0) {\n return number + '-ен';\n } else if (last2Digits > 10 && last2Digits < 20) {\n return number + '-ти';\n } else if (lastDigit === 1) {\n return number + '-ви';\n } else if (lastDigit === 2) {\n return number + '-ри';\n } else if (lastDigit === 7 || lastDigit === 8) {\n return number + '-ми';\n } else {\n return number + '-ти';\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return mk;\n\n})));\n","//! moment.js locale configuration\n//! locale : Norwegian BokmÃ¥l [nb]\n//! authors : Espen Hovlandsdal : https://github.com/rexxars\n//! Sigurd Gartmann : https://github.com/sigurdga\n//! Stephen Ramthun : https://github.com/stephenramthun\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var nb = moment.defineLocale('nb', {\n months: 'januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember'.split(\n '_'\n ),\n monthsShort:\n 'jan._feb._mars_apr._mai_juni_juli_aug._sep._okt._nov._des.'.split('_'),\n monthsParseExact: true,\n weekdays: 'søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag'.split('_'),\n weekdaysShort: 'sø._ma._ti._on._to._fr._lø.'.split('_'),\n weekdaysMin: 'sø_ma_ti_on_to_fr_lø'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY [kl.] HH:mm',\n LLLL: 'dddd D. MMMM YYYY [kl.] HH:mm',\n },\n calendar: {\n sameDay: '[i dag kl.] LT',\n nextDay: '[i morgen kl.] LT',\n nextWeek: 'dddd [kl.] LT',\n lastDay: '[i gÃ¥r kl.] LT',\n lastWeek: '[forrige] dddd [kl.] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'om %s',\n past: '%s siden',\n s: 'noen sekunder',\n ss: '%d sekunder',\n m: 'ett minutt',\n mm: '%d minutter',\n h: 'en time',\n hh: '%d timer',\n d: 'en dag',\n dd: '%d dager',\n w: 'en uke',\n ww: '%d uker',\n M: 'en mÃ¥ned',\n MM: '%d mÃ¥neder',\n y: 'ett Ã¥r',\n yy: '%d Ã¥r',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return nb;\n\n})));\n","//! moment.js locale configuration\n//! locale : Kazakh [kk]\n//! authors : Nurlan Rakhimzhanov : https://github.com/nurlan\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var suffixes = {\n 0: '-ші',\n 1: '-ші',\n 2: '-ші',\n 3: '-ші',\n 4: '-ші',\n 5: '-ші',\n 6: '-шы',\n 7: '-ші',\n 8: '-ші',\n 9: '-шы',\n 10: '-шы',\n 20: '-шы',\n 30: '-шы',\n 40: '-шы',\n 50: '-ші',\n 60: '-шы',\n 70: '-ші',\n 80: '-ші',\n 90: '-шы',\n 100: '-ші',\n };\n\n var kk = moment.defineLocale('kk', {\n months: 'қаңтар_ақпан_наурыз_Ñәуір_мамыр_мауÑым_шілде_тамыз_қыркүйек_қазан_қараша_желтоқÑан'.split(\n '_'\n ),\n monthsShort: 'қаң_ақп_нау_Ñәу_мам_мау_шіл_там_қыр_қаз_қар_жел'.split('_'),\n weekdays: 'жекÑенбі_дүйÑенбі_ÑейÑенбі_ÑәрÑенбі_бейÑенбі_жұма_Ñенбі'.split(\n '_'\n ),\n weekdaysShort: 'жек_дүй_Ñей_Ñәр_бей_жұм_Ñен'.split('_'),\n weekdaysMin: 'жк_дй_Ñй_ÑÑ€_бй_жм_Ñн'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Бүгін Ñағат] LT',\n nextDay: '[Ертең Ñағат] LT',\n nextWeek: 'dddd [Ñағат] LT',\n lastDay: '[Кеше Ñағат] LT',\n lastWeek: '[Өткен аптаның] dddd [Ñағат] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s ішінде',\n past: '%s бұрын',\n s: 'бірнеше Ñекунд',\n ss: '%d Ñекунд',\n m: 'бір минут',\n mm: '%d минут',\n h: 'бір Ñағат',\n hh: '%d Ñағат',\n d: 'бір күн',\n dd: '%d күн',\n M: 'бір ай',\n MM: '%d ай',\n y: 'бір жыл',\n yy: '%d жыл',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(ші|шы)/,\n ordinal: function (number) {\n var a = number % 10,\n b = number >= 100 ? 100 : null;\n return number + (suffixes[number] || suffixes[a] || suffixes[b]);\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return kk;\n\n})));\n","//! moment.js locale configuration\n//! locale : Arabic (Tunisia) [ar-tn]\n//! author : Nader Toukabri : https://github.com/naderio\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var arTn = moment.defineLocale('ar-tn', {\n months: 'جانÙÙŠ_ÙÙŠÙري_مارس_Ø£Ùريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوÙمبر_ديسمبر'.split(\n '_'\n ),\n monthsShort:\n 'جانÙÙŠ_ÙÙŠÙري_مارس_Ø£Ùريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوÙمبر_ديسمبر'.split(\n '_'\n ),\n weekdays: 'الأØد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),\n weekdaysShort: 'Ø£Øد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت'.split('_'),\n weekdaysMin: 'Ø_Ù†_Ø«_ر_Ø®_ج_س'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[اليوم على الساعة] LT',\n nextDay: '[غدا على الساعة] LT',\n nextWeek: 'dddd [على الساعة] LT',\n lastDay: '[أمس على الساعة] LT',\n lastWeek: 'dddd [على الساعة] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'ÙÙŠ %s',\n past: 'منذ %s',\n s: 'ثوان',\n ss: '%d ثانية',\n m: 'دقيقة',\n mm: '%d دقائق',\n h: 'ساعة',\n hh: '%d ساعات',\n d: 'يوم',\n dd: '%d أيام',\n M: 'شهر',\n MM: '%d أشهر',\n y: 'سنة',\n yy: '%d سنوات',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return arTn;\n\n})));\n","import { Row } from './../models/row';\nimport { CellType } from '../base/enum';\nimport { isNullOrUndefined, Internationalization, getValue, createElement } from '@syncfusion/ej2-base';\nimport { Cell } from '../models/cell';\nimport { ValueFormatter } from './../services/value-formatter';\nimport { Query, DataManager } from '@syncfusion/ej2-data';\nimport { getForeignData, measureColumnDepth, getUid } from '../base/util';\nimport { Grid } from '../base/grid';\n/**\n * @hidden\n * `ExportHelper` for `PdfExport` & `ExcelExport`\n */\nvar ExportHelper = /** @class */ (function () {\n function ExportHelper(parent, foreignKeyData) {\n this.hideColumnInclude = false;\n this.foreignKeyData = {};\n this.parent = parent;\n if (!parent.parentDetails && foreignKeyData) {\n this.foreignKeyData = foreignKeyData;\n }\n }\n ExportHelper.getQuery = function (parent, data) {\n var query = data.generateQuery(true).requiresCount();\n if (data.isRemote()) {\n if (parent.groupSettings.enableLazyLoading && parent.groupSettings.columns.length) {\n query.lazyLoad = [];\n }\n else {\n query.take(parent.pageSettings.totalRecordsCount);\n }\n }\n return query;\n };\n ExportHelper.prototype.getFData = function (value, column) {\n var foreignKeyData = getForeignData(column, {}, value, this.foreignKeyData[column.field])[0];\n return foreignKeyData;\n };\n ExportHelper.prototype.getGridRowModel = function (columns, dataSource, gObj, startIndex) {\n if (startIndex === void 0) { startIndex = 0; }\n var rows = [];\n var length = dataSource.length;\n if (length) {\n for (var i = 0; i < length; i++, startIndex++) {\n var options = { isExpand: false };\n options.data = dataSource[parseInt(i.toString(), 10)];\n options.index = startIndex;\n if (gObj.childGrid || gObj.detailTemplate) {\n if (gObj.hierarchyPrintMode === 'All') {\n options.isExpand = true;\n }\n else if (gObj.hierarchyPrintMode === 'Expanded' &&\n this.parent.expandedRows && this.parent.expandedRows[parseInt(startIndex.toString(), 10)]) {\n options.isExpand = gObj.expandedRows[parseInt(startIndex.toString(), 10)].isExpand;\n }\n }\n var row = new Row(options);\n row.cells = this.generateCells(columns, gObj);\n rows.push(row);\n }\n this.processColumns(rows);\n }\n return rows;\n };\n ExportHelper.prototype.generateCells = function (columns, gObj) {\n var cells = [];\n if (gObj.childGridLevel) {\n var len = gObj.childGridLevel;\n for (var i = 0; len > i; i++) {\n cells.push(this.generateCell({}, CellType.Indent));\n }\n }\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var col = columns_1[_i];\n cells.push(this.generateCell(col, CellType.Data));\n }\n return cells;\n };\n ExportHelper.prototype.getColumnData = function (gridObj) {\n var _this = this;\n var columnPromise = [];\n var promise;\n var fColumns = gridObj.getForeignKeyColumns();\n if (fColumns.length) {\n for (var i = 0; i < fColumns.length; i++) {\n var colData = ('result' in fColumns[parseInt(i.toString(), 10)].dataSource) ?\n new DataManager(fColumns[parseInt(i.toString(), 10)].dataSource.result) :\n fColumns[parseInt(i.toString(), 10)].dataSource;\n columnPromise.push(colData.executeQuery(new Query()));\n }\n promise = Promise.all(columnPromise).then(function (e) {\n for (var j = 0; j < fColumns.length; j++) {\n _this.foreignKeyData[fColumns[parseInt(j.toString(), 10)].field] = e[parseInt(j.toString(), 10)].result;\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n });\n }\n return promise;\n };\n ExportHelper.prototype.getHeaders = function (columns, isHideColumnInclude) {\n if (isHideColumnInclude) {\n this.hideColumnInclude = true;\n }\n else {\n this.hideColumnInclude = false;\n }\n this.colDepth = measureColumnDepth(columns);\n var rows = [];\n for (var i = 0; i < this.colDepth; i++) {\n rows[parseInt(i.toString(), 10)] = new Row({});\n rows[parseInt(i.toString(), 10)].cells = [];\n }\n rows = this.processColumns(rows);\n rows = this.processHeaderCells(rows, columns);\n return { rows: rows, columns: this.generateActualColumns(columns) };\n };\n ExportHelper.prototype.getConvertedWidth = function (input) {\n var value = parseFloat(input);\n return (input.indexOf('%') !== -1) ? (this.parent.element.getBoundingClientRect().width * value / 100) : value;\n };\n ExportHelper.prototype.generateActualColumns = function (columns, actualColumns) {\n if (actualColumns === void 0) { actualColumns = []; }\n for (var _i = 0, columns_2 = columns; _i < columns_2.length; _i++) {\n var column = columns_2[_i];\n if (column.commands) {\n continue;\n }\n if (!column.columns) {\n if (column.visible || this.hideColumnInclude) {\n actualColumns.push(column);\n }\n }\n else {\n if (column.visible || this.hideColumnInclude) {\n var colSpan = this.getCellCount(column, 0);\n if (colSpan !== 0) {\n this.generateActualColumns(column.columns, actualColumns);\n }\n }\n }\n }\n return actualColumns;\n };\n ExportHelper.prototype.processHeaderCells = function (rows, cols) {\n var columns = cols;\n for (var i = 0; i < columns.length; i++) {\n if (!columns[parseInt(i.toString(), 10)].commands) {\n rows = this.appendGridCells(columns[parseInt(i.toString(), 10)], rows, 0);\n }\n }\n return rows;\n };\n ExportHelper.prototype.appendGridCells = function (cols, gridRows, index) {\n if (!cols.columns && (cols.visible !== false || this.hideColumnInclude) && !cols.commands) {\n gridRows[parseInt(index.toString(), 10)].cells.push(this.generateCell(cols, CellType.Header, this.colDepth - index, index));\n }\n else if (cols.columns) {\n var colSpan = this.getCellCount(cols, 0);\n if (colSpan) {\n gridRows[parseInt(index.toString(), 10)].cells.push(new Cell({\n cellType: CellType.StackedHeader, column: cols, colSpan: colSpan\n }));\n }\n var isIgnoreFirstCell = void 0;\n for (var i = 0, len = cols.columns.length; i < len; i++) {\n if (cols.columns[parseInt(i.toString(), 10)].visible && !isIgnoreFirstCell) {\n isIgnoreFirstCell = true;\n }\n gridRows = this.appendGridCells(cols.columns[parseInt(i.toString(), 10)], gridRows, index + 1);\n }\n }\n return gridRows;\n };\n ExportHelper.prototype.generateCell = function (gridColumn, cellType, rowSpan, rowIndex) {\n var option = {\n 'visible': gridColumn.visible,\n 'isDataCell': cellType === CellType.Data,\n 'column': gridColumn,\n 'cellType': cellType,\n 'rowSpan': rowSpan,\n 'index': rowIndex\n };\n if (!option.rowSpan || option.rowSpan < 2) {\n delete option.rowSpan;\n }\n return new Cell(option);\n };\n ExportHelper.prototype.processColumns = function (rows) {\n //TODO: generate dummy column for group, detail, stacked row here; ensureColumns here\n var gridObj = this.parent;\n var columnIndexes = [];\n if (gridObj.enableColumnVirtualization) {\n columnIndexes = gridObj.getColumnIndexesInView();\n }\n for (var i = 0, len = rows.length; i < len; i++) {\n if (gridObj.allowGrouping) {\n for (var j = 0, len_1 = gridObj.groupSettings.columns.length - 1; j < len_1; j++) {\n if (gridObj.enableColumnVirtualization && columnIndexes.indexOf(j) === -1) {\n continue;\n }\n rows[parseInt(i.toString(), 10)].cells.splice(0, 0, this.generateCell({}, CellType.HeaderIndent));\n }\n }\n }\n return rows;\n };\n ExportHelper.prototype.getCellCount = function (column, count) {\n if (column.columns) {\n for (var i = 0; i < column.columns.length; i++) {\n count = this.getCellCount(column.columns[parseInt(i.toString(), 10)], count);\n }\n }\n else {\n if (column.visible || this.hideColumnInclude) {\n count++;\n }\n }\n return count;\n };\n ExportHelper.prototype.checkAndExport = function (gridPool, globalResolve) {\n var bool = Object.keys(gridPool).some(function (key) {\n return !gridPool[\"\" + key];\n });\n if (!bool) {\n globalResolve();\n }\n };\n ExportHelper.prototype.failureHandler = function (gridPool, childGridObj, resolve) {\n var _this = this;\n return function () {\n gridPool[childGridObj.id] = true;\n _this.checkAndExport(gridPool, resolve);\n };\n };\n ExportHelper.prototype.createChildGrid = function (gObj, row, exportType, gridPool) {\n var childGridObj = new Grid(this.parent.detailRowModule.getGridModel(gObj, row, exportType));\n gObj.isPrinting = false;\n var parent = 'parentDetails';\n childGridObj[\"\" + parent] = {\n parentID: gObj.element.id,\n parentPrimaryKeys: gObj.getPrimaryKeyFieldNames(),\n parentKeyField: gObj.childGrid.queryString,\n parentKeyFieldValue: getValue(childGridObj.queryString, row.data),\n parentRowData: row.data\n };\n var exportId = getUid('child-grid');\n var element = createElement('div', {\n id: exportId, styles: 'display: none'\n });\n document.body.appendChild(element);\n childGridObj.id = exportId;\n gridPool[\"\" + exportId] = false;\n childGridObj.isExportGrid = true;\n return { childGrid: childGridObj, element: element };\n };\n ExportHelper.prototype.getGridExportColumns = function (columns) {\n var actualGridColumns = [];\n for (var i = 0, gridColumns = columns; i < gridColumns.length; i++) {\n if (gridColumns[parseInt(i.toString(), 10)].type !== 'checkbox') {\n actualGridColumns.push(gridColumns[parseInt(i.toString(), 10)]);\n }\n }\n return actualGridColumns;\n };\n /**\n * Gets the foreignkey data.\n *\n * @returns {ForeignKeyFormat} returns the foreignkey data\n * @hidden\n */\n ExportHelper.prototype.getForeignKeyData = function () {\n return this.foreignKeyData;\n };\n return ExportHelper;\n}());\nexport { ExportHelper };\n/**\n * @hidden\n * `ExportValueFormatter` for `PdfExport` & `ExcelExport`\n */\nvar ExportValueFormatter = /** @class */ (function () {\n function ExportValueFormatter(culture) {\n this.valueFormatter = new ValueFormatter(culture);\n this.internationalization = new Internationalization(culture);\n }\n ExportValueFormatter.prototype.returnFormattedValue = function (args, customFormat) {\n if (!isNullOrUndefined(args.value) && args.value) {\n return this.valueFormatter.getFormatFunction(customFormat)(args.value);\n }\n else {\n return '';\n }\n };\n /**\n * Used to format the exporting cell value\n *\n * @param {ExportHelperArgs} args - Specifies cell details.\n * @returns {string} returns formated value\n * @hidden\n */\n ExportValueFormatter.prototype.formatCellValue = function (args) {\n if (args.isForeignKey) {\n args.value = getValue(args.column.foreignKeyValue, getForeignData(args.column, {}, args.value)[0]);\n }\n if (args.column.type === 'number' && args.column.format !== undefined && args.column.format !== '') {\n if (typeof args.column.format === 'string') {\n args.column.format = { format: args.column.format };\n }\n return args.value || args.value === 0 ?\n this.internationalization.getNumberFormat(args.column.format)(args.value) : '';\n }\n else if (args.column.type === 'boolean' && args.value !== '') {\n return args.value ? 'true' : 'false';\n /* tslint:disable-next-line:max-line-length */\n }\n else if ((args.column.type === 'date' || args.column.type === 'dateonly' || args.column.type === 'datetime' || args.column.type === 'time') && args.column.format !== undefined) {\n if (typeof args.value === 'string') {\n args.value = new Date(args.value);\n }\n if (typeof args.column.format === 'string') {\n var format = void 0;\n var cFormat = args.column.format;\n if (args.column.type === 'date' || args.column.type === 'dateonly') {\n format = { type: 'date', skeleton: cFormat };\n }\n else if (args.column.type === 'time') {\n format = { type: 'time', skeleton: cFormat };\n }\n else {\n format = { type: 'dateTime', skeleton: cFormat };\n }\n return this.returnFormattedValue(args, format);\n }\n else {\n if (args.column.format instanceof Object && args.column.format.type === undefined) {\n return (args.value.toString());\n }\n else {\n var customFormat = void 0;\n if (args.column.type === 'date' || args.column.type === 'dateonly') {\n customFormat = {\n type: args.column.format.type,\n format: args.column.format.format, skeleton: args.column.format.skeleton\n };\n }\n else if (args.column.type === 'time') {\n customFormat = { type: 'time', format: args.column.format.format, skeleton: args.column.format.skeleton };\n }\n else {\n customFormat = { type: 'dateTime', format: args.column.format.format, skeleton: args.column.format.skeleton };\n }\n return this.returnFormattedValue(args, customFormat);\n }\n }\n }\n else {\n if ((!isNullOrUndefined(args.column.type) && !isNullOrUndefined(args.value)) || !isNullOrUndefined(args.value)) {\n return (args.value).toString();\n }\n else {\n return '';\n }\n }\n };\n return ExportValueFormatter;\n}());\nexport { ExportValueFormatter };\n","import * as events from '../base/constant';\nimport { Workbook } from '@syncfusion/ej2-excel-export';\nimport { isNullOrUndefined, getEnumValue, compile, getValue, detach, extend } from '@syncfusion/ej2-base';\nimport { Data } from '../actions/data';\nimport { ExportHelper, ExportValueFormatter } from './export-helper';\nimport { SummaryModelGenerator, GroupSummaryModelGenerator, CaptionSummaryModelGenerator } from '../services/summary-model-generator';\nimport { CellType } from '../base/enum';\nimport { Query, DataManager } from '@syncfusion/ej2-data';\nimport { getPrintGridModel, getUid, isExportColumns, updateColumnTypeForExportColumns, prepareColumns, measureColumnDepth } from '../base/util';\nimport { defaultCurrencyCode } from '@syncfusion/ej2-base';\n/**\n * @hidden\n * `ExcelExport` module is used to handle the Excel export action.\n */\nvar ExcelExport = /** @class */ (function () {\n /**\n * Constructor for the Grid Excel Export module.\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {ServiceLocator} locator - specifies the ServiceLocator\n * @hidden\n */\n function ExcelExport(parent, locator) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.book = {};\n this.workSheet = [];\n this.rows = [];\n this.columns = [];\n this.styles = [];\n this.rowLength = 1;\n this.expType = 'AppendToSheet';\n this.includeHiddenColumn = false;\n this.isCsvExport = false;\n this.isChild = false;\n this.isElementIdChanged = false;\n this.gridPool = {};\n this.sheet = {};\n this.grpFooterTemplates = [];\n this.footerTemplates = [];\n this.aggIndex = 0;\n this.totalAggregates = 0;\n this.parent = parent;\n this.helper = new ExportHelper(parent);\n this.locator = locator;\n this.l10n = this.locator.getService('localization');\n }\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n */\n ExcelExport.prototype.getModuleName = function () {\n return 'ExcelExport';\n };\n ExcelExport.prototype.init = function (gObj) {\n if (gObj.element !== null && gObj.element.id === '') {\n gObj.element.id = new Date().toISOString();\n this.isElementIdChanged = true;\n }\n this.parent = gObj;\n if (this.parent.isDestroyed) {\n return;\n }\n this.isExporting = undefined;\n this.book = {};\n this.workSheet = [];\n this.rows = [];\n this.columns = [];\n this.styles = [];\n this.rowLength = 1;\n this.footer = undefined;\n this.expType = 'AppendToSheet';\n this.includeHiddenColumn = false;\n this.exportValueFormatter = new ExportValueFormatter(gObj.locale);\n gObj.id = getUid('main-grid');\n this.gridPool[gObj.id] = false;\n };\n /**\n * Export Grid to Excel file.\n *\n * @param {IGrid} grid - Defines the grid.\n * @param {exportProperties} exportProperties - Defines the export properties of the Grid.\n * @param {isMultipleExport} isMultipleExport - Defines is multiple Grid's are exported.\n * @param {Workbook} workbook - Defined the Workbook if multiple Grid is exported.\n * @param {boolean} isCsv - true if export to CSV.\n * @param {boolean} isBlob - true if isBlob is enabled.\n * @returns {Promise<any>} - Returns the map for export.\n */\n // eslint-disable-next-line\n ExcelExport.prototype.Map = function (grid, exportProperties, isMultipleExport, workbook, isCsv, isBlob) {\n var gObj = grid;\n var cancel = 'cancel';\n var isBlb = 'isBlob';\n var Child = 'isChild';\n var csv = 'isCsv';\n var workbk = 'workbook';\n var isMultiEx = 'isMultipleExport';\n this.gridPool = {};\n if ((grid.childGrid || grid.detailTemplate) && !(!isNullOrUndefined(exportProperties) && exportProperties.hierarchyExportMode === 'None')) {\n grid.expandedRows = getPrintGridModel(grid).expandedRows;\n }\n var args = {\n requestType: 'beforeExcelExport', gridObject: gObj, cancel: false,\n isMultipleExport: isMultipleExport, workbook: workbook, isCsv: isCsv, isBlob: isBlob, isChild: this.isChild,\n grpFooterTemplates: this.grpFooterTemplates\n };\n gObj.trigger(events.beforeExcelExport, args);\n if (args[\"\" + cancel]) {\n return new Promise(function (resolve) {\n return resolve();\n });\n }\n this.parent.log('exporting_begin', this.getModuleName());\n this.data = new Data(gObj);\n this.isExporting = true;\n this.isBlob = args[\"\" + isBlb];\n this.isChild = args[\"\" + Child];\n this.grpFooterTemplates = args['grpFooterTemplates'];\n if (args[\"\" + csv]) {\n this.isCsvExport = args[\"\" + csv];\n }\n else {\n this.isCsvExport = false;\n }\n if (isExportColumns(exportProperties)) {\n updateColumnTypeForExportColumns(exportProperties, gObj);\n }\n return this.processRecords(gObj, exportProperties, args[\"\" + isMultiEx], args[\"\" + workbk]);\n };\n ExcelExport.prototype.exportingSuccess = function (resolve) {\n this.isExporting = false;\n this.parent.trigger(events.excelExportComplete, this.isBlob ? { promise: this.blobPromise } : { gridInstance: this.parent });\n this.parent.log('exporting_complete', this.getModuleName());\n resolve(this.book);\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ExcelExport.prototype.processRecords = function (gObj, exportProperties, isMultipleExport, workbook) {\n var _this = this;\n if (gObj.allowGrouping && gObj.groupSettings.enableLazyLoading && gObj.groupSettings.columns.length) {\n if (isNullOrUndefined(exportProperties)) {\n exportProperties = { hierarchyExportMode: 'All' };\n }\n else {\n exportProperties.hierarchyExportMode = exportProperties.hierarchyExportMode || 'All';\n }\n }\n if (!isNullOrUndefined(exportProperties) && !isNullOrUndefined(exportProperties.dataSource)) {\n exportProperties.dataSource = exportProperties.dataSource instanceof DataManager ?\n exportProperties.dataSource : new DataManager(exportProperties.dataSource);\n var query_1 = exportProperties.query ? exportProperties.query : new Query();\n if (isNullOrUndefined(query_1.isCountRequired) || gObj.aggregates) {\n query_1.isCountRequired = true;\n }\n return new Promise(function (resolve) {\n var dataManager = exportProperties.dataSource.executeQuery(query_1);\n dataManager.then(function (r) {\n _this.init(gObj);\n _this.processInnerRecords(gObj, exportProperties, isMultipleExport, workbook, r).then(function () {\n _this.exportingSuccess(resolve);\n });\n });\n });\n }\n else if (!isNullOrUndefined(exportProperties) && exportProperties.exportType === 'CurrentPage') {\n return new Promise(function (resolve) {\n _this.init(gObj);\n _this.processInnerRecords(gObj, exportProperties, isMultipleExport, workbook, _this.parent.getCurrentViewRecords());\n _this.exportingSuccess(resolve);\n });\n }\n else {\n var allPromise_1 = [];\n allPromise_1.push(this.data.getData({}, ExportHelper.getQuery(gObj, this.data)));\n allPromise_1.push(this.helper.getColumnData(gObj));\n return new Promise(function (resolve, reject) {\n Promise.all(allPromise_1).then(function (e) {\n _this.init(gObj);\n _this.processInnerRecords(gObj, exportProperties, isMultipleExport, workbook, e[0]).then(function () {\n _this.exportingSuccess(resolve);\n });\n }).catch(function (e) {\n reject(_this.book);\n _this.parent.trigger(events.actionFailure, e);\n });\n });\n }\n };\n ExcelExport.prototype.processInnerRecords = function (gObj, exportProperties, \n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n isMultipleExport, workbook, r) {\n var _this = this;\n this.groupedColLength = gObj.groupSettings.columns.length;\n var blankRows = 5;\n var separator;\n var rows = [];\n var colDepth = measureColumnDepth(gObj.columns);\n var isExportPropertiesPresent = !isNullOrUndefined(exportProperties);\n if (isExportPropertiesPresent && !isNullOrUndefined(exportProperties.multipleExport)) {\n this.expType = (!isNullOrUndefined(exportProperties.multipleExport.type) ? exportProperties.multipleExport.type : 'AppendToSheet');\n if (!isNullOrUndefined(exportProperties.multipleExport.blankRows)) {\n blankRows = exportProperties.multipleExport.blankRows;\n }\n }\n if (isNullOrUndefined(workbook)) {\n this.workSheet = [];\n this.rows = [];\n this.columns = [];\n this.styles = [];\n this.sheet.images = [];\n }\n else if (this.expType === 'NewSheet') {\n this.workSheet = workbook.worksheets;\n this.rows = [];\n this.columns = [];\n this.sheet.images = [];\n this.styles = workbook.styles;\n }\n else {\n this.workSheet = [];\n this.rows = workbook.worksheets[0].rows;\n this.columns = workbook.worksheets[0].columns;\n this.styles = workbook.styles;\n this.sheet.images = workbook.worksheets[0].images;\n this.rowLength = (this.rows[this.rows.length - 1].index + blankRows);\n this.rowLength++;\n }\n if (isExportPropertiesPresent) {\n if (!isNullOrUndefined(isMultipleExport)) {\n if (!isNullOrUndefined(exportProperties.header) && (isMultipleExport || this.expType === 'NewSheet')) {\n this.processExcelHeader(JSON.parse(JSON.stringify(exportProperties.header)));\n }\n if (!isNullOrUndefined(exportProperties.footer)) {\n if (this.expType === 'AppendToSheet') {\n if (!isMultipleExport) {\n this.footer = JSON.parse(JSON.stringify(exportProperties.footer));\n }\n }\n else {\n this.footer = JSON.parse(JSON.stringify(exportProperties.footer));\n }\n }\n }\n else {\n if (!isNullOrUndefined(exportProperties.header)) {\n this.processExcelHeader(JSON.parse(JSON.stringify(exportProperties.header)));\n }\n if (!isNullOrUndefined(exportProperties.footer)) {\n this.footer = JSON.parse(JSON.stringify(exportProperties.footer));\n }\n }\n }\n this.includeHiddenColumn = (isExportPropertiesPresent ? exportProperties.includeHiddenColumn : false);\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n return new Promise(function (resolve, reject) {\n gObj.childGridLevel = 0;\n rows = _this.processGridExport(gObj, exportProperties, r);\n _this.globalResolve = resolve;\n _this.gridPool[gObj.id] = true;\n _this.helper.checkAndExport(_this.gridPool, _this.globalResolve);\n }).then(function () {\n var organisedRows = [];\n _this.organiseRows(rows, rows[0].index, organisedRows);\n _this.rows = _this.rows.concat(organisedRows);\n //footer template add\n if (!isNullOrUndefined(_this.footer)) {\n if ((_this.expType === 'AppendToSheet' && !isMultipleExport) || (_this.expType === 'NewSheet')) {\n _this.processExcelFooter(_this.footer);\n }\n }\n if (_this.columns.length > 0) {\n _this.sheet.columns = _this.columns;\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n _this.sheet.rows = _this.rows;\n _this.sheet.enableRtl = _this.parent.enableRtl;\n if (_this.parent.allowFiltering && gObj.getVisibleColumns().length && isExportPropertiesPresent &&\n exportProperties.enableFilter) {\n var headerRowLen = exportProperties.header ? exportProperties.header.headerRows ||\n exportProperties.header.rows.length : 0;\n var autoFilters = {\n row: colDepth + headerRowLen, column: _this.groupedColLength ? _this.groupedColLength + 1 :\n _this.sheet.columns[0].index, lastRow: _this.sheet.rows.length, lastColumn: _this.sheet.columns.length\n };\n _this.sheet.autoFilters = autoFilters;\n }\n _this.workSheet.push(_this.sheet);\n _this.book.worksheets = _this.workSheet;\n _this.book.styles = _this.styles;\n gObj.notify('finalPageSetup', _this.book);\n if (!isMultipleExport) {\n if (_this.isCsvExport) {\n if (isExportPropertiesPresent && !isNullOrUndefined(exportProperties.separator)\n && exportProperties.separator !== ',') {\n separator = exportProperties.separator;\n }\n var book = new Workbook(_this.book, 'csv', gObj.locale, defaultCurrencyCode, separator);\n if (!_this.isBlob) {\n if (isExportPropertiesPresent && exportProperties.fileName) {\n book.save(exportProperties.fileName);\n }\n else {\n book.save('Export.csv');\n }\n }\n else {\n _this.blobPromise = book.saveAsBlob('text/csv');\n }\n }\n else {\n var book = new Workbook(_this.book, 'xlsx', gObj.locale, defaultCurrencyCode);\n if (!_this.isBlob) {\n if (isExportPropertiesPresent && exportProperties.fileName) {\n book.save(exportProperties.fileName);\n }\n else {\n book.save('Export.xlsx');\n }\n }\n else {\n _this.blobPromise = book.saveAsBlob('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n }\n }\n if (_this.isElementIdChanged) {\n gObj.element.id = '';\n }\n delete gObj.expandedRows;\n }\n return workbook;\n });\n };\n ExcelExport.prototype.organiseRows = function (rows, initialIndex, organisedRows) {\n if (!rows.length) {\n return initialIndex;\n }\n for (var i = 0; i < rows.length; i++) {\n var row = rows[parseInt(i.toString(), 10)];\n var childRows = row.childRows;\n if (childRows) {\n row.index = initialIndex++;\n delete row.childRows;\n organisedRows.push(row);\n initialIndex = this.organiseRows(childRows, initialIndex, organisedRows);\n }\n else {\n row.index = initialIndex++;\n organisedRows.push(row);\n }\n }\n return initialIndex;\n };\n ExcelExport.prototype.processGridExport = function (gObj, exportProperties, r) {\n var excelRows = [];\n if (!isNullOrUndefined(exportProperties) && !isNullOrUndefined(exportProperties.theme)) {\n this.theme = exportProperties.theme;\n }\n if ((gObj.childGrid || gObj.detailTemplate) && !isNullOrUndefined(exportProperties)) {\n gObj.hierarchyPrintMode = exportProperties.hierarchyExportMode || 'Expanded';\n }\n var helper = new ExportHelper(gObj, this.helper.getForeignKeyData());\n var gColumns = isExportColumns(exportProperties) ?\n prepareColumns(exportProperties.columns, gObj.enableColumnVirtualization) :\n helper.getGridExportColumns(gObj.columns);\n var headerRow = helper.getHeaders(gColumns, this.includeHiddenColumn);\n var groupIndent = gObj.groupSettings.columns.length ? gObj.groupSettings.columns.length - 1 : 0;\n excelRows = this.processHeaderContent(gObj, headerRow, groupIndent, excelRows);\n if (!isNullOrUndefined(exportProperties) && Object.keys(exportProperties).length &&\n isNullOrUndefined(exportProperties.dataSource)) {\n if (exportProperties.exportType === 'CurrentPage' && (!gObj.groupSettings.enableLazyLoading\n || gObj.getDataModule().isRemote())) {\n excelRows = this.processRecordContent(gObj, r, headerRow, exportProperties, gObj.currentViewData, excelRows, helper);\n }\n else if (gObj.groupSettings.enableLazyLoading && !gObj.getDataModule().isRemote()) {\n var groupData = void 0;\n if (!isNullOrUndefined(exportProperties) && Object.keys(exportProperties).length) {\n var isAllPage = exportProperties.exportType === 'CurrentPage'\n ? false : true;\n var groupQuery = gObj.getDataModule().generateQuery(isAllPage);\n var lazyloadData = gObj.getDataModule().dataManager.executeLocal(groupQuery);\n groupQuery.lazyLoad = [];\n var fName = 'fn';\n if (!isAllPage) {\n for (var i = 0; i < groupQuery.queries.length; i++) {\n if (groupQuery.queries[parseInt(i.toString(), 10)]['' + fName] === 'onPage') {\n groupQuery.queries[parseInt(i.toString(), 10)].e.pageSize = lazyloadData.reduce(function (acc, curr) { return acc + curr['count']; }, 0);\n }\n }\n }\n if (exportProperties.hierarchyExportMode === 'All') {\n groupData = gObj.getDataModule().dataManager.executeLocal(groupQuery);\n }\n else if (exportProperties.hierarchyExportMode === 'Expanded' || exportProperties.hierarchyExportMode === 'None' ||\n isNullOrUndefined(exportProperties.hierarchyExportMode)) {\n groupData = gObj.getDataModule().dataManager.executeLocal(groupQuery);\n var lazQuery = this.parent.contentModule.lazyLoadQuery;\n for (var i = 0; i < lazQuery.length; i++) {\n var query = lazQuery[parseInt(i.toString(), 10)];\n var where = query[0];\n for (var j = 0; j < groupData.length; j++) {\n var data = groupData[parseInt(j.toString(), 10)];\n if (data['key'] === where['value']) {\n lazyloadData[parseInt(i.toString(), 10)] = groupData[parseInt(j.toString(), 10)];\n }\n }\n }\n groupData = lazyloadData;\n }\n }\n else {\n groupData = gObj.currentViewData;\n }\n excelRows = this.processRecordContent(gObj, r, headerRow, exportProperties, groupData, excelRows, helper);\n }\n else {\n excelRows = this.processRecordContent(gObj, r, headerRow, exportProperties, undefined, excelRows, helper);\n }\n }\n else {\n excelRows = this.processRecordContent(gObj, r, headerRow, exportProperties, undefined, excelRows, helper);\n }\n gObj.notify(events.exportDataBound, { excelRows: excelRows, type: 'excel' });\n this.capTemplate = undefined;\n this.footerTemplates = [];\n this.grpFooterTemplates = [];\n this.aggIndex = 0;\n this.totalAggregates = 0;\n return excelRows;\n };\n ExcelExport.prototype.processRecordContent = function (gObj, returnType, headerRow, exportProperties, currentViewRecords, excelRow, helper) {\n var record;\n if (!isNullOrUndefined(currentViewRecords) && currentViewRecords.length) {\n record = currentViewRecords;\n }\n else {\n record = returnType.result;\n }\n if (!isNullOrUndefined(record.level)) {\n this.processGroupedRows(gObj, record, headerRow, record.level, 0, exportProperties, excelRow, helper);\n }\n else {\n this.processRecordRows(gObj, record, headerRow, 0, 0, exportProperties, excelRow, helper);\n }\n if (!isNullOrUndefined(returnType.aggregates)) {\n if (!isNullOrUndefined(currentViewRecords) && !this.parent.groupSettings.enableLazyLoading) {\n this.processAggregates(gObj, returnType.result, excelRow, currentViewRecords);\n }\n else {\n var result = returnType.result.GroupGuid ?\n returnType.result.records : returnType.result;\n this.processAggregates(gObj, result, excelRow);\n }\n }\n return excelRow;\n };\n ExcelExport.prototype.processGroupedRows = function (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n gObj, dataSource, headerRow, level, startIndex, excelExportProperties, excelRows, helper) {\n for (var _i = 0, dataSource_1 = dataSource; _i < dataSource_1.length; _i++) {\n var item = dataSource_1[_i];\n var cells = [];\n var index = 1;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var cell = {};\n cell.index = (index + level) - 1;\n var col = gObj.getColumnByField(item.field);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var args = {\n value: item.key,\n column: col,\n style: undefined,\n isForeignKey: col.isForeignColumn()\n };\n var value = gObj.getColumnByField(item.field).headerText +\n ': ' + (!col.enableGroupByFormat ? this.exportValueFormatter.formatCellValue(args) : item.key) + ' - ';\n if (item.count > 1) {\n value += item.count + ' items';\n }\n else {\n value += item.count + ' item';\n }\n var cArgs = { captionText: value, type: this.isCsvExport ? 'CSV' : 'Excel', data: item };\n this.parent.trigger(events.exportGroupCaption, cArgs);\n cell.value = cArgs.captionText;\n cell.style = this.getCaptionThemeStyle(this.theme);\n if (!isNullOrUndefined(cArgs.style)) {\n cell.style = this.mergeOptions(cell.style, cArgs.style);\n }\n var captionModelGen = new CaptionSummaryModelGenerator(gObj);\n var groupCaptionSummaryRows = captionModelGen.generateRows(item);\n this.fillAggregates(gObj, groupCaptionSummaryRows, (dataSource.level + dataSource.childLevels) - 1, excelRows, this.rowLength);\n cells.push(cell);\n if (excelRows[excelRows.length - 1].cells.length > 0) {\n var lIndex = dataSource.level + dataSource.childLevels + groupCaptionSummaryRows[0].cells.length;\n var hIndex = 0;\n for (var _a = 0, _b = excelRows[excelRows.length - 1].cells; _a < _b.length; _a++) {\n var tCell = _b[_a];\n if (tCell.index < lIndex) {\n lIndex = tCell.index;\n }\n if (tCell.index > hIndex) {\n hIndex = tCell.index;\n }\n if (cells[cells.length - 1].index !== tCell.index) {\n cells.push(tCell);\n }\n }\n if ((lIndex - cell.index) > 1) {\n cell.colSpan = lIndex - cell.index;\n }\n while (hIndex < (headerRow.columns.length + level + dataSource.childLevels)) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var sCell = {};\n sCell.index = (hIndex + 1);\n sCell.style = this.getCaptionThemeStyle(this.theme);\n cells.push(sCell);\n hIndex++;\n }\n }\n else {\n var span = 0;\n //Calculation for column span when group caption dont have aggregates\n for (var _c = 0, _d = headerRow.columns; _c < _d.length; _c++) {\n var col_1 = _d[_c];\n if (col_1.visible) {\n span++;\n }\n }\n cell.colSpan = (dataSource.childLevels + span);\n }\n excelRows[excelRows.length - 1].cells = cells;\n this.rowLength++;\n if (this.groupedColLength < 8 && level > 1) {\n var grouping = { outlineLevel: level - 1, isCollapsed: true };\n excelRows[excelRows.length - 1].grouping = grouping;\n }\n if (!isNullOrUndefined(dataSource.childLevels) && dataSource.childLevels > 0) {\n this.processGroupedRows(gObj, item.items, headerRow, item.items.level, startIndex, excelExportProperties, excelRows, helper);\n this.processAggregates(gObj, item, excelRows, undefined, (level - 1) + dataSource.childLevels, true);\n }\n else {\n startIndex = this.processRecordRows(gObj, item.items, headerRow, (level - 1), startIndex, excelExportProperties, excelRows, helper);\n this.processAggregates(gObj, item, excelRows, undefined, (level - 1), true);\n }\n }\n };\n ExcelExport.prototype.processRecordRows = function (gObj, record, headerRow, level, startIndex, excelExportProperties, excelRows, helper) {\n var index = 1;\n var cells = [];\n var columns = headerRow.columns;\n var rows = helper.getGridRowModel(columns, record, gObj, startIndex);\n for (var _i = 0, rows_1 = rows; _i < rows_1.length; _i++) {\n var row = rows_1[_i];\n cells = [];\n startIndex++;\n index = 1;\n var templateRowHeight = void 0;\n for (var c = 0, len = row.cells.length; c < len; c++) {\n var gCell = row.cells[parseInt(c.toString(), 10)];\n if (gCell.cellType !== CellType.Data) {\n continue;\n }\n var column = gCell.column;\n var field = column.field;\n var cellValue = !isNullOrUndefined(field) ? column.valueAccessor(field, row.data, column) : '';\n var value = !isNullOrUndefined(cellValue) ? cellValue : '';\n if (column.type === 'dateonly' && typeof value === 'string' && value) {\n var arr = value.split(/[^0-9.]/);\n value = new Date(parseInt(arr[0], 10), parseInt(arr[1], 10) - 1, parseInt(arr[2], 10));\n }\n var fkData = void 0;\n if (column.isForeignColumn && column.isForeignColumn()) {\n fkData = helper.getFData(value, column);\n value = getValue(column.foreignKeyValue, fkData);\n }\n if (!isNullOrUndefined(value)) {\n var cell = {};\n var idx = index + level + gObj.childGridLevel;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var excelCellArgs = {\n data: row.data, column: column, foreignKeyData: fkData,\n value: value, style: undefined, colSpan: 1, cell: cell\n };\n gObj.trigger(events.excelQueryCellInfo, excelCellArgs);\n if (!isNullOrUndefined(excelCellArgs.image) && !isNullOrUndefined(excelCellArgs.image.base64)) {\n templateRowHeight = this.setImage(excelCellArgs, idx);\n if (excelCellArgs.image.height && excelCellArgs.value !== '') {\n templateRowHeight += 30;\n }\n }\n if (!isNullOrUndefined(excelCellArgs.hyperLink)) {\n excelCellArgs.cell.hyperlink = { target: excelCellArgs.hyperLink.target };\n excelCellArgs.value = excelCellArgs.hyperLink.displayText || excelCellArgs.value;\n }\n cell = excelCellArgs.cell;\n cell.index = idx;\n cell.value = excelCellArgs.value;\n if (excelCellArgs.data === '' && gObj.childGridLevel && index === 1) {\n var style = {};\n style.hAlign = 'left';\n excelCellArgs = { style: style };\n cell.colSpan = gObj.getVisibleColumns().length;\n cell.value = this.l10n.getConstant('EmptyRecord');\n }\n if (excelCellArgs.colSpan > 1) {\n cell.colSpan = excelCellArgs.colSpan;\n }\n if (!isNullOrUndefined(excelCellArgs.style)) {\n var styleIndex = this.getColumnStyle(gObj, index + level);\n cell.style = this.mergeOptions(this.styles[parseInt(styleIndex.toString(), 10)], excelCellArgs.style);\n }\n else {\n cell.style = { name: gObj.element.id + 'column' + (index + level) };\n }\n cells.push(cell);\n }\n index++;\n }\n var excelRow = { index: this.rowLength++, cells: cells };\n if (!isNullOrUndefined(templateRowHeight)) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n excelRow.height = templateRowHeight;\n }\n if (this.groupedColLength && this.groupedColLength < 8 && (level + 1) > 0) {\n excelRow.grouping = { outlineLevel: (level + 1), isCollapsed: true };\n excelRows.push(excelRow);\n }\n else {\n excelRows.push(excelRow);\n }\n if ((row.isExpand || this.isChild) && (!isNullOrUndefined(gObj.childGrid) || !isNullOrUndefined(gObj.detailTemplate))) {\n if (!isNullOrUndefined(gObj.childGrid)) {\n gObj.isPrinting = true;\n var exportType = (!isNullOrUndefined(excelExportProperties) && excelExportProperties.exportType) ?\n excelExportProperties.exportType : 'AllPages';\n var returnVal = this.helper.createChildGrid(gObj, row, exportType, this.gridPool);\n var childGridObj = returnVal.childGrid;\n var element = returnVal.element;\n childGridObj.actionFailure =\n helper.failureHandler(this.gridPool, childGridObj, this.globalResolve);\n childGridObj.childGridLevel = gObj.childGridLevel + 1;\n var args = { childGrid: childGridObj, row: row, exportProperties: excelExportProperties };\n this.parent.trigger(events.exportDetailDataBound, args);\n childGridObj.beforeDataBound = this.childGridCell(excelRow, childGridObj, excelExportProperties, row);\n childGridObj.appendTo(element);\n }\n else {\n var args = { parentRow: row, row: excelRow, value: {}, action: 'excelexport', gridInstance: gObj };\n this.parent.trigger(events.exportDetailTemplate, args);\n excelRow.childRows = this.processDetailTemplate(args);\n }\n }\n gObj.notify(events.exportRowDataBound, { rowObj: row, type: 'excel', excelRows: excelRows });\n }\n return startIndex;\n };\n ExcelExport.prototype.processDetailTemplate = function (templateData) {\n var _this = this;\n var rows = [];\n var templateRowHeight;\n var detailIndent = 2;\n var detailCellIndex;\n if (templateData.value.columnHeader || templateData.value.rows) {\n var processCell_1 = function (currentCell, isHeader) {\n var cell = {};\n if (isNullOrUndefined(currentCell.index)) {\n currentCell.index = detailCellIndex;\n detailCellIndex++;\n }\n cell.index = currentCell.index + detailIndent;\n if (!isNullOrUndefined(currentCell.value)) {\n cell.value = currentCell.value;\n }\n if (!isNullOrUndefined(currentCell.colSpan)) {\n cell.colSpan = currentCell.colSpan;\n }\n if (!isNullOrUndefined(currentCell.rowSpan)) {\n cell.rowSpan = currentCell.rowSpan;\n }\n if (isHeader) {\n cell.style = _this.getHeaderThemeStyle(_this.theme);\n }\n else {\n cell.style = _this.getRecordThemeStyle(_this.theme);\n }\n if (!isNullOrUndefined(currentCell.style)) {\n var cellStyle = {\n fontColor: currentCell.style.fontColor,\n fontName: currentCell.style.fontName,\n fontSize: currentCell.style.fontSize,\n hAlign: currentCell.style.excelHAlign,\n vAlign: currentCell.style.excelVAlign,\n rotation: currentCell.style.excelRotation,\n bold: currentCell.style.bold,\n indent: currentCell.style.indent,\n italic: currentCell.style.italic,\n underline: currentCell.style.underline,\n backColor: currentCell.style.backColor,\n wrapText: currentCell.style.wrapText,\n borders: currentCell.style.excelBorders,\n numberFormat: currentCell.style.excelNumberFormat,\n type: currentCell.style.excelType,\n strikeThrough: currentCell.style.strikeThrough\n };\n cell.style = _this.mergeOptions(cellStyle, cell.style);\n }\n if (!isNullOrUndefined(currentCell.image) && !isNullOrUndefined(currentCell.image.base64)) {\n if (currentCell.rowSpan > 1) {\n _this.setImage(currentCell, cell.index);\n }\n else {\n templateRowHeight = _this.setImage(currentCell, cell.index);\n if (currentCell.image.height && currentCell.value !== '') {\n templateRowHeight += 30;\n }\n }\n }\n if (!isNullOrUndefined(currentCell.hyperLink)) {\n cell.hyperlink = { target: currentCell.hyperLink.target };\n cell.value = currentCell.hyperLink.displayText;\n }\n return cell;\n };\n var processRow = function (currentRow, isHeader) {\n var excelDetailCells = [];\n detailCellIndex = 0;\n for (var j = 0; j < currentRow.cells.length; j++) {\n var currentCell = currentRow.cells[parseInt(j.toString(), 10)];\n var detailCell = processCell_1(currentCell, isHeader);\n excelDetailCells.push(detailCell);\n }\n var row = { index: _this.rowLength++, cells: excelDetailCells };\n if (!isNullOrUndefined(templateRowHeight)) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n row.height = templateRowHeight;\n templateRowHeight = null;\n }\n rows.push(row);\n };\n if (templateData.value.columnHeader) {\n for (var i = 0; i < templateData.value.columnHeader.length; i++) {\n processRow(templateData.value.columnHeader[parseInt(i.toString(), 10)], true);\n }\n }\n if (templateData.value.rows) {\n for (var i = 0; i < templateData.value.rows.length; i++) {\n processRow(templateData.value.rows[parseInt(i.toString(), 10)]);\n }\n }\n }\n else if (templateData.value.image) {\n templateRowHeight = this.setImage(templateData.value, detailIndent);\n var row = {\n index: this.rowLength++,\n cells: [{\n index: detailIndent,\n style: this.getRecordThemeStyle(this.theme)\n }]\n };\n if (!isNullOrUndefined(templateRowHeight)) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n row.height = templateRowHeight;\n templateRowHeight = null;\n }\n rows.push(row);\n }\n else if (templateData.value.text) {\n var row = {\n index: this.rowLength++,\n cells: [{\n index: detailIndent,\n value: templateData.value.text,\n style: this.getRecordThemeStyle(this.theme)\n }]\n };\n rows.push(row);\n }\n else if (templateData.value.hyperLink) {\n var row = {\n index: this.rowLength++,\n cells: [{\n index: 2,\n hyperlink: { target: templateData.value.hyperLink.target },\n value: templateData.value.hyperLink.displayText,\n style: this.getRecordThemeStyle(this.theme)\n }]\n };\n rows.push(row);\n }\n for (var i = 0; i < rows.length; i++) {\n rows[parseInt(i.toString(), 10)].grouping = {\n outlineLevel: 1, isCollapsed: !templateData.parentRow.isExpand, isHidden: !templateData.parentRow.isExpand\n };\n }\n return rows;\n };\n ExcelExport.prototype.setImage = function (args, idx) {\n if (isNullOrUndefined(this.sheet.images)) {\n this.sheet.images = [];\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var excelImage = {\n image: args.image.base64, row: this.rowLength, column: idx,\n lastRow: this.rowLength, lastColumn: idx\n };\n if (args.image.width && args.image.height) {\n excelImage.width = args.image.width;\n excelImage.height = args.image.height;\n }\n this.sheet.images.push(excelImage);\n this.columns[idx - 1].width = args.image.width || this.columns[idx - 1].width;\n return args.image.height || 50;\n };\n ExcelExport.prototype.childGridCell = function (excelRow, childGridObj, excelExportProps, gRow) {\n var _this = this;\n return function (result) {\n childGridObj.beforeDataBound = null;\n result.cancel = true;\n if (result.result.length === 0) {\n result.result = [''];\n }\n excelRow.childRows = _this.processGridExport(childGridObj, excelExportProps, result);\n var intent = _this.parent.groupSettings.columns.length;\n var rows = excelRow.childRows;\n for (var i = 0; i < rows.length; i++) {\n rows[parseInt(i.toString(), 10)].grouping = { outlineLevel: intent + childGridObj\n .childGridLevel, isCollapsed: !gRow.isExpand, isHidden: !gRow.isExpand };\n }\n childGridObj.destroy();\n detach(childGridObj.element);\n _this.gridPool[childGridObj.id] = true;\n _this.helper.checkAndExport(_this.gridPool, _this.globalResolve);\n return excelRow;\n };\n };\n ExcelExport.prototype.processAggregates = function (gObj, rec, excelRows, currentViewRecords, indent, byGroup) {\n var summaryModel = new SummaryModelGenerator(gObj);\n var columns = summaryModel.getColumns();\n columns = columns.filter(function (col) { return isNullOrUndefined(col.commands) && col.type !== 'checkbox'; });\n if (gObj.aggregates.length && this.parent !== gObj) {\n gObj.aggregateModule.prepareSummaryInfo();\n }\n var data = undefined;\n if (!isNullOrUndefined(currentViewRecords)) {\n data = currentViewRecords;\n }\n else {\n data = rec;\n }\n if (indent === undefined) {\n indent = 0;\n }\n if (gObj.groupSettings.columns.length > 0 && byGroup) {\n var groupSummaryModel = new GroupSummaryModelGenerator(gObj);\n var groupSummaryRows = groupSummaryModel.generateRows(data, { level: data.level });\n if (groupSummaryRows.length > 0) {\n excelRows = this.fillAggregates(gObj, groupSummaryRows, indent, excelRows);\n }\n }\n else {\n indent = gObj.groupSettings.columns.length > 0 && !byGroup ? gObj.groupSettings.columns.length : indent;\n var sRows = summaryModel.generateRows(data, rec.aggregates, null, null, columns);\n if (sRows.length > 0 && !byGroup) {\n indent = gObj.groupSettings.columns.length ? indent - 1 : indent;\n excelRows = this.fillAggregates(gObj, sRows, indent, excelRows);\n }\n }\n return excelRows;\n };\n ExcelExport.prototype.fillAggregates = function (gObj, rows, indent, excelRows, customIndex) {\n for (var _i = 0, rows_2 = rows; _i < rows_2.length; _i++) {\n var row = rows_2[_i];\n var cells = [];\n var isEmpty = true;\n var index = 0;\n for (var _a = 0, _b = row.cells; _a < _b.length; _a++) {\n var cell = _b[_a];\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var eCell = {};\n var columnsDetails = {};\n if (!isNullOrUndefined(cell.attributes.index)) {\n columnsDetails = this.parent.getColumnByIndex(cell.attributes.index);\n }\n if (cell.cellType === CellType.DetailFooterIntent || columnsDetails.type === 'checkbox') {\n continue;\n }\n if ((cell.visible || this.includeHiddenColumn)) {\n index++;\n if (cell.isDataCell) {\n isEmpty = false;\n var footerTemplate = !isNullOrUndefined(cell.column.footerTemplate);\n var groupFooterTemplate = !isNullOrUndefined(cell.column.groupFooterTemplate);\n var groupCaptionTemplate = !isNullOrUndefined(cell.column.groupCaptionTemplate);\n eCell.index = index + indent + gObj.childGridLevel;\n if (footerTemplate) {\n eCell.value = this.getAggreateValue(gObj, CellType.Summary, cell.column.footerTemplate, cell, row);\n }\n else if (groupFooterTemplate) {\n eCell.value = this.getAggreateValue(gObj, CellType.GroupSummary, cell.column.groupFooterTemplate, cell, row);\n }\n else if (groupCaptionTemplate) {\n eCell.value = this.getAggreateValue(gObj, CellType.CaptionSummary, cell.column.groupCaptionTemplate, cell, row);\n }\n else {\n for (var _c = 0, _d = Object.keys(row.data[cell.column.field]); _c < _d.length; _c++) {\n var key = _d[_c];\n if (key === cell.column.type) {\n if (!isNullOrUndefined(row.data[cell.column.field].Sum)) {\n eCell.value = row.data[cell.column.field][cell.column.field + \" - sum\"];\n }\n else if (!isNullOrUndefined(row.data[cell.column.field].Average)) {\n eCell.value = row.data[cell.column.field][cell.column.field + \" - average\"];\n }\n else if (!isNullOrUndefined(row.data[cell.column.field].Max)) {\n eCell.value = row.data[cell.column.field][cell.column.field + \" - max\"];\n }\n else if (!isNullOrUndefined(row.data[cell.column.field].Min)) {\n eCell.value = row.data[cell.column.field][cell.column.field + \" - min\"];\n }\n else if (!isNullOrUndefined(row.data[cell.column.field].Count)) {\n eCell.value = row.data[cell.column.field][cell.column.field + \" - count\"];\n }\n else if (!isNullOrUndefined(row.data[cell.column.field].TrueCount)) {\n eCell.value = row.data[cell.column.field][cell.column.field + \" - truecount\"];\n }\n else if (!isNullOrUndefined(row.data[cell.column.field].FalseCount)) {\n eCell.value = row.data[cell.column.field][cell.column.field + \" - falsecount\"];\n }\n else if (!isNullOrUndefined(row.data[cell.column.field].Custom)) {\n eCell.value = row.data[cell.column.field].Custom;\n }\n }\n }\n }\n eCell.style = this.getCaptionThemeStyle(this.theme); //{ name: gObj.element.id + 'column' + index };\n this.aggregateStyle(cell.column, eCell.style, cell.column.field);\n var gridCellStyle = cell.attributes.style;\n if (gridCellStyle.textAlign) {\n eCell.style.hAlign = gridCellStyle.textAlign.toLowerCase();\n }\n var args = {\n row: row,\n type: footerTemplate ? 'Footer' : groupFooterTemplate ? 'GroupFooter' : 'GroupCaption',\n style: eCell,\n cell: cell\n };\n this.parent.trigger(events.excelAggregateQueryCellInfo, args);\n cells.push(eCell);\n }\n else {\n if (customIndex === undefined) {\n eCell.index = index + indent + gObj.childGridLevel;\n eCell.style = this.getCaptionThemeStyle(this.theme); //{ name: gObj.element.id + 'column' + index };\n cells.push(eCell);\n }\n }\n }\n }\n if (!isNullOrUndefined(customIndex)) {\n excelRows.push({ index: customIndex, cells: cells });\n }\n else {\n var row_1 = {};\n var dummyOutlineLevel = 'outlineLevel';\n var dummyGrouping = 'grouping';\n if (this.groupedColLength < 8 && this.groupedColLength > 0 && !(gObj.groupSettings.enableLazyLoading && isNullOrUndefined(excelRows[excelRows.length - 1][\"\" + dummyGrouping]))) {\n var level = excelRows[excelRows.length - 1][\"\" + dummyGrouping][\"\" + dummyOutlineLevel];\n var grouping = { outlineLevel: level, isCollapsed: true };\n row_1 = { index: this.rowLength++, cells: cells, grouping: grouping };\n }\n else {\n row_1 = { index: this.rowLength++, cells: cells };\n }\n if (!isEmpty) {\n excelRows.push(row_1);\n }\n }\n }\n return excelRows;\n };\n ExcelExport.prototype.aggregateStyle = function (col, style, field) {\n var column = this.parent.getColumnByField(field);\n if (typeof col.format === 'object') {\n var format = col.format;\n style.numberFormat = !isNullOrUndefined(format.format) ? format.format : format.skeleton;\n if (!isNullOrUndefined(format.type)) {\n style.type = format.type.toLowerCase();\n }\n }\n else {\n style.numberFormat = col.format;\n }\n if (!isNullOrUndefined(column) && isNullOrUndefined(style.type)) {\n style.type = column.type.toLowerCase();\n }\n };\n ExcelExport.prototype.getAggreateValue = function (gObj, cellType, template, cell, row) {\n var templateFn = {};\n templateFn[getEnumValue(CellType, cell.cellType)] = compile(template);\n var txt;\n var data = row.data[cell.column.field ? cell.column.field : cell.column.columnName];\n if ((this.parent.isReact || this.parent.isVue || this.parent.isVue3 || this.parent.isAngular) &&\n !(typeof cell.column.footerTemplate === 'string' || typeof cell.column.groupFooterTemplate === 'string' || typeof cell.column.groupCaptionTemplate === 'string')) {\n txt = data[(cell.column.type)];\n return !isNullOrUndefined(txt) ? (txt) : '';\n }\n else {\n txt = (templateFn[getEnumValue(CellType, cell.cellType)](data));\n }\n return !isNullOrUndefined(txt[0]) ? txt[0].textContent : '';\n };\n ExcelExport.prototype.mergeOptions = function (JSON1, JSON2) {\n var result = {};\n var attrname = Object.keys(JSON1);\n for (var index = 0; index < attrname.length; index++) {\n if (attrname[parseInt(index.toString(), 10)] !== 'name') {\n result[attrname[parseInt(index.toString(), 10)]] = JSON1[attrname[parseInt(index.toString(), 10)]];\n }\n }\n attrname = Object.keys(JSON2);\n for (var index = 0; index < attrname.length; index++) {\n if (attrname[parseInt(index.toString(), 10)] !== 'name') {\n result[attrname[parseInt(index.toString(), 10)]] = JSON2[attrname[parseInt(index.toString(), 10)]];\n }\n }\n return result;\n };\n ExcelExport.prototype.getColumnStyle = function (gObj, columnIndex) {\n var index = 0;\n for (var _i = 0, _a = this.styles; _i < _a.length; _i++) {\n var style = _a[_i];\n if (style.name === gObj.element.id + 'column' + columnIndex) {\n return index;\n }\n index++;\n }\n return undefined;\n };\n ExcelExport.prototype.headerRotation = function (args) {\n var degree = args.style.rotation;\n if (degree <= 90 && degree >= 0) {\n args.style.hAlign = 'Left';\n }\n else if (degree > 90 && degree <= 180) {\n args.style.hAlign = 'Right';\n }\n else {\n degree = 180;\n args.style.hAlign = 'Right';\n }\n args.style.rotation = degree;\n };\n ExcelExport.prototype.processHeaderContent = function (gObj, headerRow, indent, excelRows) {\n var rowIndex = 1;\n var gridRows = headerRow.rows;\n // Column collection with respect to the records in the grid\n var gridColumns = headerRow.columns;\n var spannedCells = [];\n if (indent > 0) {\n var index = 0;\n while (index !== indent) {\n this.columns.push({ index: index + 1, width: 30 });\n index++;\n }\n }\n for (var col = 0; col < gridColumns.length; col++) {\n this.parseStyles(gObj, gridColumns[parseInt(col.toString(), 10)], this.getRecordThemeStyle(this.theme), indent + col + 1);\n }\n var templateRowHeight;\n for (var row = 0; row < gridRows.length; row++) {\n var currentCellIndex = 1 + indent;\n var cells = [];\n for (var column = 0; column < gridRows[parseInt(row.toString(), 10)].cells.length; column++) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var style = {};\n var cell = {};\n var gridCell = gridRows[parseInt(row.toString(), 10)].cells[parseInt(column.toString(), 10)];\n if (gridCell.cellType === CellType.HeaderIndent || gridCell.cellType === CellType.DetailHeader) {\n continue;\n }\n var result = { contains: true, index: 1 };\n while (result.contains) {\n result = this.getIndex(spannedCells, rowIndex, currentCellIndex);\n currentCellIndex = result.index;\n if (!result.contains) {\n cell.index = result.index + gObj.childGridLevel;\n break;\n }\n }\n if (!isNullOrUndefined(gridCell.rowSpan) && gridCell.rowSpan !== 1) {\n cell.rowSpan = gridCell.rowSpan;\n for (var i = rowIndex; i < gridCell.rowSpan + rowIndex; i++) {\n var spannedCell = { rowIndex: 0, columnIndex: 0 };\n spannedCell.rowIndex = i;\n spannedCell.columnIndex = currentCellIndex;\n spannedCells.push(spannedCell);\n }\n }\n if (!isNullOrUndefined(gridCell.colSpan) && gridCell.colSpan !== 1) {\n cell.colSpan = gridCell.colSpan;\n currentCellIndex = currentCellIndex + cell.colSpan - 1;\n }\n cell.value = gridCell.column.headerText;\n style = this.getHeaderThemeStyle(this.theme);\n if (!isNullOrUndefined(gridCell.column.textAlign)) {\n style.hAlign = gridCell.column.textAlign.toLowerCase();\n }\n if (!isNullOrUndefined(gridCell.column.headerTextAlign)) {\n style.hAlign = gridCell.column.headerTextAlign.toLowerCase();\n }\n var excelHeaderCellArgs = { cell: cell, gridCell: gridCell, style: style };\n gObj.trigger(events.excelHeaderQueryCellInfo, excelHeaderCellArgs);\n if (excelHeaderCellArgs.style.rotation) {\n this.headerRotation(excelHeaderCellArgs);\n }\n if (!isNullOrUndefined(excelHeaderCellArgs.image) && !isNullOrUndefined(excelHeaderCellArgs.image.base64)) {\n templateRowHeight = this.setImage(excelHeaderCellArgs, currentCellIndex);\n }\n if (!isNullOrUndefined(excelHeaderCellArgs.hyperLink)) {\n excelHeaderCellArgs.cell.hyperlink = { target: excelHeaderCellArgs.hyperLink.target };\n cell.value = excelHeaderCellArgs.hyperLink.displayText || cell.value;\n }\n cell.style = excelHeaderCellArgs.style;\n cells.push(cell);\n currentCellIndex++;\n }\n var excelRow = { index: this.rowLength++, cells: cells };\n if (!isNullOrUndefined(templateRowHeight)) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n excelRow.height = templateRowHeight;\n }\n excelRows.push(excelRow);\n }\n return excelRows;\n };\n ExcelExport.prototype.getHeaderThemeStyle = function (theme) {\n var style = {};\n style.fontSize = 12;\n style.borders = { color: '#E0E0E0' };\n style.bold = true;\n if (!isNullOrUndefined(theme) && !isNullOrUndefined(theme.header)) {\n style = this.updateThemeStyle(theme.header, style);\n }\n return style;\n };\n ExcelExport.prototype.updateThemeStyle = function (themestyle, style) {\n return extend(style, themestyle);\n };\n ExcelExport.prototype.getCaptionThemeStyle = function (theme) {\n var style = {};\n style.fontSize = 13;\n style.backColor = '#F6F6F6';\n if (!isNullOrUndefined(theme) && !isNullOrUndefined(theme.caption)) {\n style = this.updateThemeStyle(theme.caption, style);\n }\n return style;\n };\n ExcelExport.prototype.getRecordThemeStyle = function (theme) {\n var style = {};\n style.fontSize = 13;\n style.borders = { color: '#E0E0E0' };\n if (!isNullOrUndefined(theme) && !isNullOrUndefined(theme.record)) {\n style = this.updateThemeStyle(theme.record, style);\n }\n return style;\n };\n ExcelExport.prototype.processExcelHeader = function (header) {\n if (!isNullOrUndefined(header.rows) && (this.expType === 'NewSheet' || this.rowLength === 1)) {\n var noRows = void 0;\n if (header.headerRows === undefined) {\n this.rowLength = header.rows.length;\n }\n else {\n this.rowLength = header.headerRows;\n }\n if (this.rowLength < header.rows.length) {\n noRows = this.rowLength;\n }\n else {\n noRows = header.rows.length;\n }\n this.rowLength++;\n for (var row = 0; row < noRows; row++) {\n var json = header.rows[parseInt(row.toString(), 10)];\n //Row index\n if (!(json.index !== null && !isNullOrUndefined(json.index))) {\n json.index = (row + 1);\n }\n this.updatedCellIndex(json);\n }\n }\n };\n ExcelExport.prototype.updatedCellIndex = function (json) {\n var cellsLength = json.cells.length;\n for (var cellId = 0; cellId < cellsLength; cellId++) {\n var jsonCell = json.cells[parseInt(cellId.toString(), 10)];\n //cell index\n if (!(jsonCell.index !== null && !isNullOrUndefined(jsonCell.index))) {\n jsonCell.index = (cellId + 1);\n }\n }\n this.rows.push(json);\n };\n ExcelExport.prototype.processExcelFooter = function (footer) {\n if (!isNullOrUndefined(footer.rows)) {\n var noRows = void 0;\n if (footer.footerRows === undefined) {\n this.rowLength += footer.rows.length;\n }\n else {\n if (footer.footerRows > footer.rows.length) {\n this.rowLength += (footer.footerRows - footer.rows.length);\n noRows = footer.rows.length;\n }\n else {\n noRows = footer.footerRows;\n }\n }\n for (var row = 0; row < noRows; row++) {\n var json = footer.rows[parseInt(row.toString(), 10)];\n //Row index\n if (json.index === null || json.index === undefined) {\n json.index = this.rowLength++;\n }\n else {\n json.index += this.rowLength;\n }\n this.updatedCellIndex(json);\n }\n }\n };\n ExcelExport.prototype.getIndex = function (spannedCells, rowIndex, columnIndex) {\n for (var _i = 0, spannedCells_1 = spannedCells; _i < spannedCells_1.length; _i++) {\n var spannedCell = spannedCells_1[_i];\n if ((spannedCell.rowIndex === rowIndex) && (spannedCell.columnIndex === columnIndex)) {\n columnIndex = columnIndex + 1;\n return { contains: true, index: columnIndex };\n }\n }\n return { contains: false, index: columnIndex };\n };\n ExcelExport.prototype.parseStyles = function (gObj, col, style, index) {\n if (!isNullOrUndefined(col.format)) {\n if (typeof col.format === 'object') {\n var format = col.format;\n style.numberFormat = !isNullOrUndefined(format.format) ? format.format : format.skeleton;\n if (!isNullOrUndefined(format.type)) {\n style.type = format.type === 'dateonly' ? 'date' : format.type.toLowerCase();\n }\n }\n else {\n style.numberFormat = col.format;\n style.type = col.type === 'dateonly' ? 'date' : col.type;\n }\n }\n if (!isNullOrUndefined(col.textAlign)) {\n style.hAlign = col.textAlign.toLowerCase();\n }\n if (Object.keys(style).length > 0) {\n style.name = gObj.element.id + 'column' + index;\n this.styles.push(style);\n }\n if (!isNullOrUndefined(col.width) && col.width !== 'auto' && !gObj.childGridLevel) {\n this.columns.push({ index: index + gObj.childGridLevel, width: typeof col.width === 'number' ?\n col.width : this.helper.getConvertedWidth(col.width) });\n }\n };\n ExcelExport.prototype.destroy = function () {\n //destroy for exporting\n };\n return ExcelExport;\n}());\nexport { ExcelExport };\n","//! moment.js locale configuration\n//! locale : Italian [it]\n//! author : Lorenzo : https://github.com/aliem\n//! author: Mattia Larentis: https://github.com/nostalgiaz\n//! author: Marco : https://github.com/Manfre98\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var it = moment.defineLocale('it', {\n months: 'gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre'.split(\n '_'\n ),\n monthsShort: 'gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic'.split('_'),\n weekdays: 'domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato'.split(\n '_'\n ),\n weekdaysShort: 'dom_lun_mar_mer_gio_ven_sab'.split('_'),\n weekdaysMin: 'do_lu_ma_me_gi_ve_sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: function () {\n return (\n '[Oggi a' +\n (this.hours() > 1 ? 'lle ' : this.hours() === 0 ? ' ' : \"ll'\") +\n ']LT'\n );\n },\n nextDay: function () {\n return (\n '[Domani a' +\n (this.hours() > 1 ? 'lle ' : this.hours() === 0 ? ' ' : \"ll'\") +\n ']LT'\n );\n },\n nextWeek: function () {\n return (\n 'dddd [a' +\n (this.hours() > 1 ? 'lle ' : this.hours() === 0 ? ' ' : \"ll'\") +\n ']LT'\n );\n },\n lastDay: function () {\n return (\n '[Ieri a' +\n (this.hours() > 1 ? 'lle ' : this.hours() === 0 ? ' ' : \"ll'\") +\n ']LT'\n );\n },\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n return (\n '[La scorsa] dddd [a' +\n (this.hours() > 1\n ? 'lle '\n : this.hours() === 0\n ? ' '\n : \"ll'\") +\n ']LT'\n );\n default:\n return (\n '[Lo scorso] dddd [a' +\n (this.hours() > 1\n ? 'lle '\n : this.hours() === 0\n ? ' '\n : \"ll'\") +\n ']LT'\n );\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'tra %s',\n past: '%s fa',\n s: 'alcuni secondi',\n ss: '%d secondi',\n m: 'un minuto',\n mm: '%d minuti',\n h: \"un'ora\",\n hh: '%d ore',\n d: 'un giorno',\n dd: '%d giorni',\n w: 'una settimana',\n ww: '%d settimane',\n M: 'un mese',\n MM: '%d mesi',\n y: 'un anno',\n yy: '%d anni',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return it;\n\n})));\n","//! moment.js locale configuration\n//! locale : Italian (Switzerland) [it-ch]\n//! author : xfh : https://github.com/xfh\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var itCh = moment.defineLocale('it-ch', {\n months: 'gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre'.split(\n '_'\n ),\n monthsShort: 'gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic'.split('_'),\n weekdays: 'domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato'.split(\n '_'\n ),\n weekdaysShort: 'dom_lun_mar_mer_gio_ven_sab'.split('_'),\n weekdaysMin: 'do_lu_ma_me_gi_ve_sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Oggi alle] LT',\n nextDay: '[Domani alle] LT',\n nextWeek: 'dddd [alle] LT',\n lastDay: '[Ieri alle] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n return '[la scorsa] dddd [alle] LT';\n default:\n return '[lo scorso] dddd [alle] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: function (s) {\n return (/^[0-9].+$/.test(s) ? 'tra' : 'in') + ' ' + s;\n },\n past: '%s fa',\n s: 'alcuni secondi',\n ss: '%d secondi',\n m: 'un minuto',\n mm: '%d minuti',\n h: \"un'ora\",\n hh: '%d ore',\n d: 'un giorno',\n dd: '%d giorni',\n M: 'un mese',\n MM: '%d mesi',\n y: 'un anno',\n yy: '%d anni',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return itCh;\n\n})));\n","//! moment.js locale configuration\n//! locale : English (New Zealand) [en-nz]\n//! author : Luke McGregor : https://github.com/lukemcgregor\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enNz = moment.defineLocale('en-nz', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY h:mm A',\n LLLL: 'dddd, D MMMM YYYY h:mm A',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return enNz;\n\n})));\n","//! moment.js locale configuration\n//! locale : Frisian [fy]\n//! author : Robin van der Vliet : https://github.com/robin0van0der0v\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsShortWithDots =\n 'jan._feb._mrt._apr._mai_jun._jul._aug._sep._okt._nov._des.'.split('_'),\n monthsShortWithoutDots =\n 'jan_feb_mrt_apr_mai_jun_jul_aug_sep_okt_nov_des'.split('_');\n\n var fy = moment.defineLocale('fy', {\n months: 'jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber'.split(\n '_'\n ),\n monthsShort: function (m, format) {\n if (!m) {\n return monthsShortWithDots;\n } else if (/-MMM-/.test(format)) {\n return monthsShortWithoutDots[m.month()];\n } else {\n return monthsShortWithDots[m.month()];\n }\n },\n monthsParseExact: true,\n weekdays: 'snein_moandei_tiisdei_woansdei_tongersdei_freed_sneon'.split(\n '_'\n ),\n weekdaysShort: 'si._mo._ti._wo._to._fr._so.'.split('_'),\n weekdaysMin: 'Si_Mo_Ti_Wo_To_Fr_So'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD-MM-YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[hjoed om] LT',\n nextDay: '[moarn om] LT',\n nextWeek: 'dddd [om] LT',\n lastDay: '[juster om] LT',\n lastWeek: '[ôfrûne] dddd [om] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'oer %s',\n past: '%s lyn',\n s: 'in pear sekonden',\n ss: '%d sekonden',\n m: 'ien minút',\n mm: '%d minuten',\n h: 'ien oere',\n hh: '%d oeren',\n d: 'ien dei',\n dd: '%d dagen',\n M: 'ien moanne',\n MM: '%d moannen',\n y: 'ien jier',\n yy: '%d jierren',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(ste|de)/,\n ordinal: function (number) {\n return (\n number +\n (number === 1 || number === 8 || number >= 20 ? 'ste' : 'de')\n );\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return fy;\n\n})));\n","import { print as printWindow, createElement, detach, classList, selectAll, extend } from '@syncfusion/ej2-base';\nimport { getPrintGridModel } from '../base/util';\nimport { Grid } from '../base/grid';\nimport * as events from '../base/constant';\nimport { Deferred } from '@syncfusion/ej2-data';\nimport * as literals from '../base/string-literals';\n/**\n * @returns {string[]} returns the cloned property\n * @hidden\n */\nexport function getCloneProperties() {\n return ['aggregates', 'allowGrouping', 'allowFiltering', 'allowMultiSorting', 'allowReordering', 'allowSorting',\n 'allowTextWrap', 'childGrid', 'columns', 'currentViewData', 'dataSource', 'detailTemplate', 'enableAltRow',\n 'enableColumnVirtualization', 'filterSettings', 'gridLines',\n 'groupSettings', 'height', 'locale', 'pageSettings', 'printMode', 'query', 'queryString', 'enableRtl',\n 'rowHeight', 'rowTemplate', 'sortSettings', 'textWrapSettings', 'allowPaging', 'hierarchyPrintMode', 'searchSettings',\n 'queryCellInfo', 'beforeDataBound'];\n}\n/**\n *\n * The `Print` module is used to handle print action.\n */\nvar Print = /** @class */ (function () {\n /**\n * Constructor for the Grid print module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {Scroll} scrollModule - specifies the scroll module\n * @hidden\n */\n function Print(parent, scrollModule) {\n this.isAsyncPrint = false;\n this.defered = new Deferred();\n this.parent = parent;\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.contentReady, this.isContentReady(), this);\n this.actionBeginFunction = this.actionBegin.bind(this);\n this.parent.addEventListener(events.actionBegin, this.actionBeginFunction);\n this.parent.on(events.onEmpty, this.onEmpty.bind(this));\n this.parent.on(events.hierarchyPrint, this.hierarchyPrint, this);\n this.scrollModule = scrollModule;\n }\n Print.prototype.isContentReady = function () {\n var _this = this;\n if (this.isPrintGrid() && (this.parent.hierarchyPrintMode === 'None' || !this.parent.childGrid)) {\n return this.contentReady;\n }\n return function () {\n _this.defered.promise.then(function () {\n _this.contentReady();\n });\n if (_this.isPrintGrid()) {\n _this.hierarchyPrint();\n }\n };\n };\n Print.prototype.hierarchyPrint = function () {\n this.removeColGroup(this.parent);\n var printGridObj = window.printGridObj;\n if (printGridObj && !printGridObj.element.querySelector('[aria-busy=true')) {\n printGridObj.printModule.defered.resolve();\n }\n };\n /**\n * By default, prints all the Grid pages and hides the pager.\n * > You can customize print options using the\n * [`printMode`](./printmode/).\n *\n * @returns {void}\n */\n Print.prototype.print = function () {\n this.renderPrintGrid();\n };\n Print.prototype.onEmpty = function () {\n if (this.isPrintGrid()) {\n this.contentReady();\n }\n };\n Print.prototype.actionBegin = function () {\n if (this.isPrintGrid()) {\n this.isAsyncPrint = true;\n }\n };\n Print.prototype.renderPrintGrid = function () {\n var gObj = this.parent;\n var element = createElement('div', {\n id: this.parent.element.id + '_print', className: gObj.element.className + ' e-print-grid'\n });\n element.classList.remove('e-gridhover');\n document.body.appendChild(element);\n var printGrid = new Grid(getPrintGridModel(gObj, gObj.hierarchyPrintMode));\n for (var i = 0; i < printGrid.columns.length; i++) {\n printGrid.columns[parseInt(i.toString(), 10)] = extend({}, printGrid.columns[parseInt(i.toString(), 10)]);\n if (gObj.isFrozenGrid() && !gObj.getFrozenColumns()) {\n printGrid.columns[parseInt(i.toString(), 10)].freeze = undefined;\n }\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this.parent.isAngular) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n printGrid.viewContainerRef = this.parent.viewContainerRef;\n }\n // eslint-disable-next-line @typescript-eslint/no-empty-function\n printGrid.load = function () { };\n printGrid.query = gObj.getQuery().clone();\n window.printGridObj = printGrid;\n printGrid.isPrinting = true;\n var modules = printGrid.getInjectedModules();\n var injectedModues = gObj.getInjectedModules();\n if (!modules || modules.length !== injectedModues.length) {\n printGrid.setInjectedModules(injectedModues);\n }\n gObj.notify(events.printGridInit, { element: element, printgrid: printGrid });\n this.parent.log('exporting_begin', this.getModuleName());\n printGrid.registeredTemplate = this.parent.registeredTemplate;\n printGrid.isVue = this.parent.isVue;\n printGrid.appendTo(element);\n if (!gObj.isVue3) {\n printGrid.trigger = gObj.trigger;\n }\n };\n Print.prototype.contentReady = function () {\n if (this.isPrintGrid()) {\n var gObj = this.parent;\n if (this.isAsyncPrint) {\n this.printGrid();\n return;\n }\n var args = {\n requestType: 'print',\n element: gObj.element,\n selectedRows: gObj.getContentTable().querySelectorAll('tr[aria-selected=\"true\"]'),\n cancel: false,\n hierarchyPrintMode: gObj.hierarchyPrintMode\n };\n if (!this.isAsyncPrint) {\n gObj.trigger(events.beforePrint, args);\n }\n if (args.cancel) {\n detach(gObj.element);\n return;\n }\n if (!this.isAsyncPrint) {\n this.printGrid();\n }\n }\n };\n Print.prototype.printGrid = function () {\n var gObj = this.parent;\n // Height adjustment on print grid\n if (gObj.height !== 'auto') { // if scroller enabled\n var cssProps = this.scrollModule.getCssProperties();\n var contentDiv = gObj.element.querySelector('.' + literals.content);\n var headerDiv = gObj.element.querySelector('.' + literals.gridHeader);\n contentDiv.style.height = 'auto';\n contentDiv.style.overflowY = 'auto';\n headerDiv.style[cssProps.padding] = '';\n headerDiv.firstElementChild.style[cssProps.border] = '';\n }\n // Grid alignment adjustment on grouping\n if (gObj.allowGrouping) {\n if (!gObj.groupSettings.columns.length) {\n gObj.element.querySelector('.e-groupdroparea').style.display = 'none';\n }\n else {\n this.removeColGroup(gObj);\n }\n }\n // hide horizontal scroll\n for (var _i = 0, _a = [].slice.call(gObj.element.getElementsByClassName(literals.content)); _i < _a.length; _i++) {\n var element = _a[_i];\n element.style.overflowX = 'hidden';\n }\n // Hide the waiting popup\n var waitingPop = [].slice.call(gObj.element.getElementsByClassName('e-spin-show'));\n for (var _b = 0, _c = [].slice.call(waitingPop); _b < _c.length; _b++) {\n var element = _c[_b];\n classList(element, ['e-spin-hide'], ['e-spin-show']);\n }\n this.printGridElement(gObj);\n gObj.isPrinting = false;\n delete window.printGridObj;\n var args = {\n element: gObj.element\n };\n gObj.trigger(events.printComplete, args);\n gObj.destroy();\n this.parent.log('exporting_complete', this.getModuleName());\n };\n Print.prototype.printGridElement = function (gObj) {\n classList(gObj.element, ['e-print-grid-layout'], ['e-print-grid']);\n if (gObj.isPrinting) {\n detach(gObj.element);\n }\n this.printWind = window.open('', 'print', 'height=' + window.outerHeight + ',width=' + window.outerWidth + ',tabbar=no');\n this.printWind.moveTo(0, 0);\n this.printWind.resizeTo(screen.availWidth, screen.availHeight);\n this.printWind = printWindow(gObj.element, this.printWind);\n };\n Print.prototype.removeColGroup = function (gObj) {\n var depth = gObj.groupSettings.columns.length;\n var element = gObj.element;\n var id = '#' + gObj.element.id;\n if (!depth) {\n return;\n }\n var groupCaption = selectAll('.e-groupcaption', element);\n var colSpan = groupCaption[depth - 1].getAttribute('colspan');\n for (var i = 0; i < groupCaption.length; i++) {\n groupCaption[parseInt(i.toString(), 10)].setAttribute('colspan', colSpan);\n }\n var colGroups = selectAll(\"colgroup\" + id + \"colgroup\", element);\n var contentColGroups = selectAll('.e-content colgroup', element);\n var footerColGroups = selectAll('.e-summarycontent colgroup', element);\n this.hideColGroup(colGroups, depth);\n this.hideColGroup(contentColGroups, depth);\n this.hideColGroup(footerColGroups, depth);\n };\n Print.prototype.hideColGroup = function (colGroups, depth) {\n for (var i = 0; i < colGroups.length; i++) {\n for (var j = 0; j < depth; j++) {\n colGroups[parseInt(i.toString(), 10)].children[parseInt(j.toString(), 10)].style.display = 'none';\n }\n }\n };\n /**\n * To destroy the print\n *\n * @returns {boolean} returns the isPrintGrid or not\n * @hidden\n */\n Print.prototype.isPrintGrid = function () {\n return this.parent.element.id.indexOf('_print') > 0 && this.parent.isPrinting;\n };\n /**\n * To destroy the print\n *\n * @returns {void}\n * @hidden\n */\n Print.prototype.destroy = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.contentReady, this.contentReady.bind(this));\n this.parent.removeEventListener(events.actionBegin, this.actionBeginFunction);\n this.parent.off(events.onEmpty, this.onEmpty.bind(this));\n this.parent.off(events.hierarchyPrint, this.hierarchyPrint);\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Print.prototype.getModuleName = function () {\n return 'print';\n };\n Print.printGridProp = getCloneProperties().concat([events.beforePrint, events.printComplete, events.load]);\n return Print;\n}());\nexport { Print };\n","//! moment.js locale configuration\n//! locale : English (Israel) [en-il]\n//! author : Chris Gedrim : https://github.com/chrisgedrim\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enIl = moment.defineLocale('en-il', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n });\n\n return enIl;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { EventHandler, Property, Internationalization, NotifyPropertyChanges } from '@syncfusion/ej2-base';\nimport { KeyboardEvents, Animation, Browser } from '@syncfusion/ej2-base';\nimport { cldrData, L10n, Component, getDefaultDateObject, rippleEffect, Event } from '@syncfusion/ej2-base';\nimport { remove, addClass, detach, removeClass, closest, append, attributes, setStyleAttribute } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, formatUnit, getValue, extend, getUniqueID, ChildProperty } from '@syncfusion/ej2-base';\nimport { Popup } from '@syncfusion/ej2-popups';\nimport { Input } from '@syncfusion/ej2-inputs';\nimport { ListBase } from '@syncfusion/ej2-lists';\nvar WRAPPERCLASS = 'e-time-wrapper';\nvar POPUP = 'e-popup';\nvar ERROR = 'e-error';\nvar POPUPDIMENSION = '240px';\nvar DAY = new Date().getDate();\nvar MONTH = new Date().getMonth();\nvar YEAR = new Date().getFullYear();\nvar ROOT = 'e-timepicker';\nvar LIBRARY = 'e-lib';\nvar CONTROL = 'e-control';\nvar CONTENT = 'e-content';\nvar SELECTED = 'e-active';\nvar HOVER = 'e-hover';\nvar NAVIGATION = 'e-navigation';\nvar DISABLED = 'e-disabled';\nvar ICONANIMATION = 'e-icon-anim';\nvar TIMEICON = 'e-time-icon';\nvar CLEARICON = 'e-clear-icon';\nvar FOCUS = 'e-input-focus';\nvar LISTCLASS = 'e-list-item';\nvar HALFPOSITION = 2;\nvar ANIMATIONDURATION = 50;\nvar OVERFLOW = 'e-time-overflow';\nvar OFFSETVAL = 4;\nvar EDITABLE = 'e-non-edit';\nvar wrapperAttributes = ['title', 'class', 'style'];\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport var TimePickerBase;\n(function (TimePickerBase) {\n // eslint-disable-next-line max-len, jsdoc/require-jsdoc\n function createListItems(createdEl, min, max, globalize, timeFormat, step) {\n var formatOptions;\n if (this.calendarMode === 'Gregorian') {\n formatOptions = { format: timeFormat, type: 'time' };\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n formatOptions = { format: timeFormat, type: 'time', calendar: 'islamic' };\n }\n var start;\n var interval = step * 60000;\n var listItems = [];\n var timeCollections = [];\n start = +(min.setMilliseconds(0));\n var end = +(max.setMilliseconds(0));\n while (end >= start) {\n timeCollections.push(start);\n listItems.push(globalize.formatDate(new Date(start), { format: timeFormat, type: 'time' }));\n start += interval;\n }\n var listTag = ListBase.createList(createdEl, listItems, null, true);\n return { collection: timeCollections, list: listTag };\n }\n TimePickerBase.createListItems = createListItems;\n})(TimePickerBase || (TimePickerBase = {}));\nvar TimeMaskPlaceholder = /** @class */ (function (_super) {\n __extends(TimeMaskPlaceholder, _super);\n function TimeMaskPlaceholder() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('day')\n ], TimeMaskPlaceholder.prototype, \"day\", void 0);\n __decorate([\n Property('month')\n ], TimeMaskPlaceholder.prototype, \"month\", void 0);\n __decorate([\n Property('year')\n ], TimeMaskPlaceholder.prototype, \"year\", void 0);\n __decorate([\n Property('day of the week')\n ], TimeMaskPlaceholder.prototype, \"dayOfTheWeek\", void 0);\n __decorate([\n Property('hour')\n ], TimeMaskPlaceholder.prototype, \"hour\", void 0);\n __decorate([\n Property('minute')\n ], TimeMaskPlaceholder.prototype, \"minute\", void 0);\n __decorate([\n Property('second')\n ], TimeMaskPlaceholder.prototype, \"second\", void 0);\n return TimeMaskPlaceholder;\n}(ChildProperty));\nexport { TimeMaskPlaceholder };\n/**\n * TimePicker is an intuitive interface component which provides an options to select a time value\n * from popup list or to set a desired time value.\n * ```\n * <input id='timepicker' type='text'/>\n * <script>\n * var timePickerObj = new TimePicker({ value: new Date() });\n * timePickerObj.appendTo('#timepicker');\n * </script>\n * ```\n */\nvar TimePicker = /** @class */ (function (_super) {\n __extends(TimePicker, _super);\n /**\n * Constructor for creating the widget\n *\n * @param {TimePickerModel} options - Specifies the TimePicker model.\n * @param {string | HTMLInputElement} element - Specifies the element to render as component.\n * @private\n */\n function TimePicker(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.liCollections = [];\n _this.timeCollections = [];\n _this.disableItemCollection = [];\n _this.invalidValueString = null;\n _this.isAngular = false;\n _this.preventChange = false;\n _this.maskedDateValue = '';\n _this.moduleName = _this.getModuleName();\n _this.timeOptions = options;\n return _this;\n }\n /**\n * Initialize the event handler\n *\n * @returns {void}\n * @private\n */\n TimePicker.prototype.preRender = function () {\n this.keyConfigure = {\n enter: 'enter',\n escape: 'escape',\n end: 'end',\n tab: 'tab',\n home: 'home',\n down: 'downarrow',\n up: 'uparrow',\n left: 'leftarrow',\n right: 'rightarrow',\n open: 'alt+downarrow',\n close: 'alt+uparrow'\n };\n this.cloneElement = this.element.cloneNode(true);\n removeClass([this.cloneElement], [ROOT, CONTROL, LIBRARY]);\n this.inputElement = this.element;\n this.angularTag = null;\n this.formElement = closest(this.element, 'form');\n if (this.element.tagName === 'EJS-TIMEPICKER') {\n this.angularTag = this.element.tagName;\n this.inputElement = this.createElement('input');\n this.element.appendChild(this.inputElement);\n }\n this.tabIndex = this.element.hasAttribute('tabindex') ? this.element.getAttribute('tabindex') : '0';\n this.element.removeAttribute('tabindex');\n this.openPopupEventArgs = {\n appendTo: document.body\n };\n };\n // element creation\n TimePicker.prototype.render = function () {\n this.initialize();\n this.createInputElement();\n this.updateHtmlAttributeToWrapper();\n this.setTimeAllowEdit();\n this.setEnable();\n this.validateInterval();\n this.bindEvents();\n this.validateDisable();\n this.setTimeZone();\n this.setValue(this.getFormattedValue(this.value));\n if (this.enableMask && !this.value && this.maskedDateValue && (this.floatLabelType === 'Always' || !this.floatLabelType || !this.placeholder)) {\n this.updateInputValue(this.maskedDateValue);\n this.checkErrorState(this.maskedDateValue);\n }\n this.anchor = this.inputElement;\n this.inputElement.setAttribute('value', this.inputElement.value);\n this.inputEleValue = this.getDateObject(this.inputElement.value);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-icon');\n }\n if (!isNullOrUndefined(closest(this.element, 'fieldset')) && closest(this.element, 'fieldset').disabled) {\n this.enabled = false;\n }\n this.renderComplete();\n };\n TimePicker.prototype.setTimeZone = function () {\n if (!isNullOrUndefined(this.serverTimezoneOffset) && this.value) {\n var clientTimeZoneDiff = new Date().getTimezoneOffset() / 60;\n var serverTimezoneDiff = this.serverTimezoneOffset;\n var timeZoneDiff = serverTimezoneDiff + clientTimeZoneDiff;\n timeZoneDiff = this.isDayLightSaving() ? timeZoneDiff-- : timeZoneDiff;\n this.value = new Date((this.value).getTime() + (timeZoneDiff * 60 * 60 * 1000));\n }\n };\n TimePicker.prototype.isDayLightSaving = function () {\n var firstOffset = new Date(this.value.getFullYear(), 0, 1).getTimezoneOffset();\n var secondOffset = new Date(this.value.getFullYear(), 6, 1).getTimezoneOffset();\n return (this.value.getTimezoneOffset() < Math.max(firstOffset, secondOffset));\n };\n TimePicker.prototype.setTimeAllowEdit = function () {\n if (this.allowEdit) {\n if (!this.readonly) {\n this.inputElement.removeAttribute('readonly');\n }\n }\n else {\n attributes(this.inputElement, { 'readonly': '' });\n }\n this.clearIconState();\n };\n TimePicker.prototype.clearIconState = function () {\n if (!this.allowEdit && this.inputWrapper && !this.readonly) {\n if (this.inputElement.value === '') {\n removeClass([this.inputWrapper.container], [EDITABLE]);\n }\n else {\n addClass([this.inputWrapper.container], [EDITABLE]);\n }\n }\n else if (this.inputWrapper) {\n removeClass([this.inputWrapper.container], [EDITABLE]);\n }\n };\n TimePicker.prototype.validateDisable = function () {\n this.setMinMax(this.initMin, this.initMax);\n if (!isNullOrUndefined(this.value)) {\n this.popupCreation();\n this.popupObj.destroy();\n this.popupWrapper = this.popupObj = null;\n }\n if ((!isNaN(+this.value) && this.value !== null)) {\n if (!this.valueIsDisable(this.value)) {\n //disable value given in value property so reset the date based on current date\n if (this.strictMode) {\n this.resetState();\n }\n this.initValue = null;\n this.initMax = this.getDateObject(this.initMax);\n this.initMin = this.getDateObject(this.initMin);\n this.timeCollections = this.liCollections = [];\n this.setMinMax(this.initMin, this.initMax);\n }\n }\n };\n TimePicker.prototype.validationAttribute = function (target, input) {\n var name = target.getAttribute('name') ? target.getAttribute('name') : target.getAttribute('id');\n input.setAttribute('name', name);\n target.removeAttribute('name');\n var attributes = ['required', 'aria-required', 'form'];\n for (var i = 0; i < attributes.length; i++) {\n if (isNullOrUndefined(target.getAttribute(attributes[i]))) {\n continue;\n }\n var attr = target.getAttribute(attributes[i]);\n input.setAttribute(attributes[i], attr);\n target.removeAttribute(attributes[i]);\n }\n };\n TimePicker.prototype.initialize = function () {\n this.globalize = new Internationalization(this.locale);\n this.defaultCulture = new Internationalization('en');\n this.checkTimeFormat();\n this.checkInvalidValue(this.value);\n // persist the value property.\n this.setProperties({ value: this.checkDateValue(new Date(this.checkInValue(this.value))) }, true);\n this.setProperties({ min: this.checkDateValue(new Date(this.checkInValue(this.min))) }, true);\n this.setProperties({ max: this.checkDateValue(new Date(this.checkInValue(this.max))) }, true);\n this.setProperties({ scrollTo: this.checkDateValue(new Date(this.checkInValue(this.scrollTo))) }, true);\n if (this.angularTag !== null) {\n this.validationAttribute(this.element, this.inputElement);\n }\n this.updateHtmlAttributeToElement();\n this.checkAttributes(false); //check the input element attributes\n var localeText = { placeholder: this.placeholder };\n this.l10n = new L10n('timepicker', localeText, this.locale);\n this.setProperties({ placeholder: this.placeholder || this.l10n.getConstant('placeholder') }, true);\n this.initValue = this.checkDateValue(this.value);\n this.initMin = this.checkDateValue(this.min);\n this.initMax = this.checkDateValue(this.max);\n this.isNavigate = this.isPreventBlur = this.isTextSelected = false;\n this.activeIndex = this.valueWithMinutes = this.prevDate = null;\n if (!isNullOrUndefined(this.element.getAttribute('id'))) {\n if (this.angularTag !== null) {\n this.inputElement.id = this.element.getAttribute('id') + '_input';\n }\n }\n else {\n //for angular case\n this.element.id = getUniqueID('ej2_timepicker');\n if (this.angularTag !== null) {\n attributes(this.inputElement, { 'id': this.element.id + '_input' });\n }\n }\n if (isNullOrUndefined(this.inputElement.getAttribute('name'))) {\n attributes(this.inputElement, { 'name': this.element.id });\n }\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n };\n TimePicker.prototype.checkTimeFormat = function () {\n if (this.format) {\n if (typeof this.format === 'string') {\n this.formatString = this.format;\n }\n else if (!isNullOrUndefined(this.format.skeleton) && this.format.skeleton !== '') {\n var skeletonString = this.format.skeleton;\n this.formatString = this.globalize.getDatePattern({ type: 'time', skeleton: skeletonString });\n }\n else {\n this.formatString = this.globalize.getDatePattern({ type: 'time', skeleton: 'short' });\n }\n }\n else {\n this.formatString = null;\n }\n };\n TimePicker.prototype.checkDateValue = function (value) {\n return (!isNullOrUndefined(value) && value instanceof Date && !isNaN(+value)) ? value : null;\n };\n TimePicker.prototype.createInputElement = function () {\n if (this.fullScreenMode && Browser.isDevice) {\n this.cssClass += ' ' + \"e-popup-expand\";\n }\n var updatedCssClassesValue = this.cssClass;\n var isBindClearAction = this.enableMask ? false : true;\n if (!isNullOrUndefined(this.cssClass) && this.cssClass !== '') {\n updatedCssClassesValue = (this.cssClass.replace(/\\s+/g, ' ')).trim();\n }\n this.inputWrapper = Input.createInput({\n element: this.inputElement,\n bindClearAction: isBindClearAction,\n floatLabelType: this.floatLabelType,\n properties: {\n readonly: this.readonly,\n placeholder: this.placeholder,\n cssClass: updatedCssClassesValue,\n enabled: this.enabled,\n enableRtl: this.enableRtl,\n showClearButton: this.showClearButton\n },\n buttons: [' e-input-group-icon e-time-icon e-icons']\n }, this.createElement);\n this.inputWrapper.container.style.width = this.setWidth(this.width);\n attributes(this.inputElement, {\n 'aria-autocomplete': 'list', 'tabindex': '0',\n 'aria-expanded': 'false', 'role': 'combobox', 'autocomplete': 'off',\n 'autocorrect': 'off', 'autocapitalize': 'off', 'spellcheck': 'false',\n 'aria-disabled': 'false', 'aria-invalid': 'false'\n });\n if (!this.isNullOrEmpty(this.inputStyle)) {\n Input.addAttributes({ 'style': this.inputStyle }, this.inputElement);\n }\n addClass([this.inputWrapper.container], WRAPPERCLASS);\n };\n TimePicker.prototype.getCldrDateTimeFormat = function () {\n var culture = new Internationalization(this.locale);\n var cldrTime;\n var dateFormat = culture.getDatePattern({ skeleton: 'yMd' });\n if (this.isNullOrEmpty(this.formatString)) {\n cldrTime = dateFormat + ' ' + this.cldrFormat('time');\n }\n else {\n cldrTime = this.formatString;\n }\n return cldrTime;\n };\n TimePicker.prototype.checkInvalidValue = function (value) {\n var isInvalid = false;\n if (typeof value !== 'object' && !isNullOrUndefined(value)) {\n var valueString = value;\n if (typeof valueString === 'string') {\n valueString = valueString.trim();\n }\n var valueExpression = null;\n var valueExp = null;\n if (typeof value === 'number') {\n valueString = value.toString();\n }\n else if (typeof value === 'string') {\n if (!(/^[a-zA-Z0-9- ]*$/).test(value)) {\n valueExpression = this.setCurrentDate(this.getDateObject(value));\n if (isNullOrUndefined(valueExpression)) {\n valueExpression = this.checkDateValue(this.globalize.parseDate(valueString, {\n format: this.getCldrDateTimeFormat(), type: 'datetime'\n }));\n if (isNullOrUndefined(valueExpression)) {\n valueExpression = this.checkDateValue(this.globalize.parseDate(valueString, {\n format: this.formatString, type: 'dateTime', skeleton: 'yMd'\n }));\n }\n }\n }\n }\n valueExp = this.globalize.parseDate(valueString, {\n format: this.getCldrDateTimeFormat(), type: 'datetime'\n });\n valueExpression = (!isNullOrUndefined(valueExp) && valueExp instanceof Date && !isNaN(+valueExp)) ? valueExp : null;\n if (isNullOrUndefined(valueExpression) && valueString.replace(/\\s/g, '').length) {\n var extISOString = null;\n var basicISOString = null;\n // eslint-disable-next-line\n extISOString = /^\\s*((?:[+-]\\d{6}|\\d{4})-(?:\\d\\d-\\d\\d|W\\d\\d-\\d|W\\d\\d|\\d\\d\\d|\\d\\d))(?:(T| )(\\d\\d(?::\\d\\d(?::\\d\\d(?:[.,]\\d+)?)?)?)([\\+\\-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?/;\n // eslint-disable-next-line\n basicISOString = /^\\s*((?:[+-]\\d{6}|\\d{4})(?:\\d\\d\\d\\d|W\\d\\d\\d|W\\d\\d|\\d\\d\\d|\\d\\d))(?:(T| )(\\d\\d(?:\\d\\d(?:\\d\\d(?:[.,]\\d+)?)?)?)([\\+\\-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?/;\n if ((!extISOString.test(valueString) && !basicISOString.test(valueString))\n || ((/^[a-zA-Z0-9- ]*$/).test(value)) || isNaN(+new Date('' + valueString))) {\n isInvalid = true;\n }\n else {\n valueExpression = new Date('' + valueString);\n }\n }\n if (isInvalid) {\n if (!this.strictMode) {\n this.invalidValueString = valueString;\n }\n this.setProperties({ value: null }, true);\n this.initValue = null;\n }\n else {\n this.setProperties({ value: valueExpression }, true);\n this.initValue = this.value;\n }\n }\n };\n TimePicker.prototype.requiredModules = function () {\n var modules = [];\n if (this.enableMask) {\n modules.push({ args: [this], member: 'MaskedDateTime' });\n }\n return modules;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n TimePicker.prototype.cldrFormat = function (type) {\n var cldrDateTimeString;\n if (this.locale === 'en' || this.locale === 'en-US') {\n cldrDateTimeString = (getValue('timeFormats.short', getDefaultDateObject()));\n }\n else {\n cldrDateTimeString = (this.getCultureTimeObject(cldrData, '' + this.locale));\n }\n return cldrDateTimeString;\n };\n // destroy function\n TimePicker.prototype.destroy = function () {\n this.hide();\n this.unBindEvents();\n var ariaAttribute = {\n 'aria-autocomplete': 'list', 'tabindex': '0',\n 'aria-expanded': 'false', 'role': 'combobox', 'autocomplete': 'off',\n 'autocorrect': 'off', 'autocapitalize': 'off', 'spellcheck': 'false',\n 'aria-disabled': 'true', 'aria-invalid': 'false'\n };\n if (this.inputElement) {\n Input.removeAttributes(ariaAttribute, this.inputElement);\n if (this.angularTag === null) {\n this.inputWrapper.container.parentElement.appendChild(this.inputElement);\n }\n if (!isNullOrUndefined(this.cloneElement.getAttribute('tabindex'))) {\n this.inputElement.setAttribute('tabindex', this.tabIndex);\n }\n else {\n this.inputElement.removeAttribute('tabindex');\n }\n this.ensureInputAttribute();\n this.enableElement([this.inputElement]);\n this.inputElement.classList.remove('e-input');\n if (isNullOrUndefined(this.cloneElement.getAttribute('disabled'))) {\n Input.setEnabled(true, this.inputElement, this.floatLabelType);\n }\n }\n if (this.inputWrapper.container) {\n detach(this.inputWrapper.container);\n }\n this.inputWrapper = this.popupWrapper = this.cloneElement = undefined;\n this.liCollections = this.timeCollections = this.disableItemCollection = [];\n if (!isNullOrUndefined(this.rippleFn)) {\n this.rippleFn();\n }\n _super.prototype.destroy.call(this);\n if (this.formElement) {\n EventHandler.remove(this.formElement, 'reset', this.formResetHandler);\n }\n this.rippleFn = null;\n this.openPopupEventArgs = null;\n this.selectedElement = null;\n this.listTag = null;\n this.liCollections = null;\n };\n TimePicker.prototype.ensureInputAttribute = function () {\n var propertyList = [];\n for (var i = 0; i < this.inputElement.attributes.length; i++) {\n propertyList[i] = this.inputElement.attributes[i].name;\n }\n for (var i = 0; i < propertyList.length; i++) {\n if (!isNullOrUndefined(this.cloneElement.getAttribute(propertyList[i]))) {\n this.inputElement.setAttribute(propertyList[i], this.cloneElement.getAttribute(propertyList[i]));\n if (propertyList[i].toLowerCase() === 'value') {\n this.inputElement.value = this.cloneElement.getAttribute(propertyList[i]);\n }\n }\n else {\n this.inputElement.removeAttribute(propertyList[i]);\n if (propertyList[i].toLowerCase() === 'value') {\n this.inputElement.value = '';\n }\n }\n }\n };\n //popup creation\n TimePicker.prototype.popupCreation = function () {\n this.popupWrapper = this.createElement('div', {\n className: ROOT + ' ' + POPUP,\n attrs: { 'id': this.element.id + '_popup', 'style': 'visibility:hidden' }\n });\n this.popupWrapper.setAttribute('aria-label', this.element.id);\n this.popupWrapper.setAttribute('role', 'dialog');\n if (!isNullOrUndefined(this.cssClass)) {\n this.popupWrapper.className += ' ' + this.cssClass;\n }\n if (!isNullOrUndefined(this.step) && this.step > 0) {\n this.generateList();\n append([this.listWrapper], this.popupWrapper);\n }\n this.addSelection();\n this.renderPopup();\n detach(this.popupWrapper);\n };\n TimePicker.prototype.getPopupHeight = function () {\n var height = parseInt(POPUPDIMENSION, 10);\n var popupHeight = this.popupWrapper.getBoundingClientRect().height;\n return popupHeight > height ? height : popupHeight;\n };\n TimePicker.prototype.generateList = function () {\n this.createListItems();\n this.wireListEvents();\n var rippleModel = { duration: 300, selector: '.' + LISTCLASS };\n this.rippleFn = rippleEffect(this.listWrapper, rippleModel);\n this.liCollections = this.listWrapper.querySelectorAll('.' + LISTCLASS);\n };\n TimePicker.prototype.renderPopup = function () {\n var _this = this;\n this.containerStyle = this.inputWrapper.container.getBoundingClientRect();\n this.popupObj = new Popup(this.popupWrapper, {\n width: this.setPopupWidth(this.width),\n zIndex: this.zIndex,\n targetType: 'relative',\n position: Browser.isDevice ? { X: 'center', Y: 'center' } : { X: 'left', Y: 'bottom' },\n collision: Browser.isDevice ? { X: 'fit', Y: 'fit' } : { X: 'flip', Y: 'flip' },\n enableRtl: this.enableRtl,\n relateTo: Browser.isDevice ? document.body : this.inputWrapper.container,\n offsetY: OFFSETVAL,\n open: function () {\n _this.popupWrapper.style.visibility = 'visible';\n addClass([_this.inputWrapper.buttons[0]], SELECTED);\n }, close: function () {\n removeClass([_this.inputWrapper.buttons[0]], SELECTED);\n _this.unWireListEvents();\n _this.inputElement.removeAttribute('aria-activedescendant');\n remove(_this.popupObj.element);\n _this.popupObj.destroy();\n _this.popupWrapper.innerHTML = '';\n _this.listWrapper = _this.popupWrapper = _this.listTag = undefined;\n }, targetExitViewport: function () {\n if (!Browser.isDevice) {\n _this.hide();\n }\n }\n });\n if (!Browser.isDevice) {\n this.popupObj.collision = { X: 'none', Y: 'flip' };\n }\n if (Browser.isDevice && this.fullScreenMode) {\n this.popupObj.element.style.maxHeight = \"100%\";\n this.popupObj.element.style.width = \"100%\";\n }\n else {\n this.popupObj.element.style.maxHeight = POPUPDIMENSION;\n }\n if (Browser.isDevice && this.fullScreenMode) {\n var modelHeader = this.createElement('div', { className: 'e-model-header' });\n var modelTitleSpan = this.createElement(\"span\", { className: \"e-model-title\" });\n modelTitleSpan.textContent = \"Select time\";\n var modelCloseIcon = this.createElement(\"span\", { className: \"e-popup-close\" });\n EventHandler.add(modelCloseIcon, 'mousedown touchstart', this.timePopupCloseHandler, this);\n modelHeader.appendChild(modelCloseIcon);\n modelHeader.appendChild(modelTitleSpan);\n this.popupWrapper.insertBefore(modelHeader, this.popupWrapper.firstElementChild);\n }\n };\n TimePicker.prototype.timePopupCloseHandler = function (e) {\n this.hide();\n };\n //util function\n TimePicker.prototype.getFormattedValue = function (value) {\n if (isNullOrUndefined(this.checkDateValue(value))) {\n return null;\n }\n else {\n return this.globalize.formatDate(value, { skeleton: 'medium', type: 'time' });\n }\n };\n TimePicker.prototype.getDateObject = function (text) {\n if (!this.isNullOrEmpty(text)) {\n var dateValue = this.createDateObj(text);\n var value = !this.isNullOrEmpty(this.initValue);\n if (this.checkDateValue(dateValue)) {\n var date = value ? this.initValue.getDate() : DAY;\n var month = value ? this.initValue.getMonth() : MONTH;\n var year = value ? this.initValue.getFullYear() : YEAR;\n return new Date(year, month, date, dateValue.getHours(), dateValue.getMinutes(), dateValue.getSeconds());\n }\n }\n return null;\n };\n TimePicker.prototype.updateHtmlAttributeToWrapper = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n if (wrapperAttributes.indexOf(key) > -1) {\n if (key === 'class') {\n var updatedClassesValue = (this.htmlAttributes[\"\" + key].replace(/\\s+/g, ' ')).trim();\n if (updatedClassesValue !== '') {\n addClass([this.inputWrapper.container], updatedClassesValue.split(' '));\n }\n }\n else if (key === 'style') {\n var timeStyle = this.inputWrapper.container.getAttribute(key);\n timeStyle = !isNullOrUndefined(timeStyle) ? (timeStyle + this.htmlAttributes[\"\" + key]) :\n this.htmlAttributes[\"\" + key];\n this.inputWrapper.container.setAttribute(key, timeStyle);\n }\n else {\n this.inputWrapper.container.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n }\n };\n TimePicker.prototype.updateHtmlAttributeToElement = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n if (wrapperAttributes.indexOf(key) < 0) {\n this.inputElement.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n };\n TimePicker.prototype.updateCssClass = function (cssClassNew, cssClassOld) {\n if (!isNullOrUndefined(cssClassOld)) {\n cssClassOld = (cssClassOld.replace(/\\s+/g, ' ')).trim();\n }\n if (!isNullOrUndefined(cssClassNew)) {\n cssClassNew = (cssClassNew.replace(/\\s+/g, ' ')).trim();\n }\n Input.setCssClass(cssClassNew, [this.inputWrapper.container], cssClassOld);\n if (this.popupWrapper) {\n Input.setCssClass(cssClassNew, [this.popupWrapper], cssClassOld);\n }\n };\n TimePicker.prototype.removeErrorClass = function () {\n removeClass([this.inputWrapper.container], ERROR);\n attributes(this.inputElement, { 'aria-invalid': 'false' });\n };\n TimePicker.prototype.checkErrorState = function (val) {\n var value = this.getDateObject(val);\n if ((this.validateState(value) && !this.invalidValueString) ||\n (this.enableMask && this.inputElement.value === this.maskedDateValue)) {\n this.removeErrorClass();\n }\n else {\n addClass([this.inputWrapper.container], ERROR);\n attributes(this.inputElement, { 'aria-invalid': 'true' });\n }\n };\n TimePicker.prototype.validateInterval = function () {\n if (!isNullOrUndefined(this.step) && this.step > 0) {\n this.enableElement([this.inputWrapper.buttons[0]]);\n }\n else {\n this.disableTimeIcon();\n }\n };\n TimePicker.prototype.disableTimeIcon = function () {\n this.disableElement([this.inputWrapper.buttons[0]]);\n this.hide();\n };\n TimePicker.prototype.disableElement = function (element) {\n addClass(element, DISABLED);\n };\n TimePicker.prototype.enableElement = function (element) {\n removeClass(element, DISABLED);\n };\n TimePicker.prototype.selectInputText = function () {\n this.inputElement.setSelectionRange(0, (this.inputElement).value.length);\n };\n TimePicker.prototype.setCursorToEnd = function () {\n this.inputElement.setSelectionRange((this.inputElement).value.length, (this.inputElement).value.length);\n };\n TimePicker.prototype.getMeridianText = function () {\n var meridian;\n if (this.locale === 'en' || this.locale === 'en-US') {\n meridian = getValue('dayPeriods.format.wide', getDefaultDateObject());\n }\n else {\n var gregorianFormat = '.dates.calendars.gregorian.dayPeriods.format.abbreviated';\n var mainVal = 'main.';\n meridian = getValue(mainVal + '' + this.locale + gregorianFormat, cldrData);\n }\n return meridian;\n };\n TimePicker.prototype.getCursorSelection = function () {\n var input = (this.inputElement);\n var start = 0;\n var end = 0;\n if (!isNaN(input.selectionStart)) {\n start = input.selectionStart;\n end = input.selectionEnd;\n }\n return { start: Math.abs(start), end: Math.abs(end) };\n };\n TimePicker.prototype.getActiveElement = function () {\n if (!isNullOrUndefined(this.popupWrapper)) {\n return this.popupWrapper.querySelectorAll('.' + SELECTED);\n }\n else {\n return null;\n }\n };\n TimePicker.prototype.isNullOrEmpty = function (value) {\n if (isNullOrUndefined(value) || (typeof value === 'string' && value.trim() === '')) {\n return true;\n }\n else {\n return false;\n }\n };\n TimePicker.prototype.setWidth = function (width) {\n if (typeof width === 'number') {\n width = formatUnit(width);\n }\n else if (typeof width === 'string') {\n width = (width.match(/px|%|em/)) ? width : formatUnit(width);\n }\n else {\n width = '100%';\n }\n return width;\n };\n TimePicker.prototype.setPopupWidth = function (width) {\n width = this.setWidth(width);\n if (width.indexOf('%') > -1) {\n var inputWidth = this.containerStyle.width * parseFloat(width) / 100;\n width = inputWidth.toString() + 'px';\n }\n return width;\n };\n TimePicker.prototype.setScrollPosition = function () {\n var element = this.selectedElement;\n if (!isNullOrUndefined(element)) {\n this.findScrollTop(element);\n }\n else if (this.popupWrapper && this.checkDateValue(this.scrollTo)) {\n this.setScrollTo();\n }\n };\n TimePicker.prototype.findScrollTop = function (element) {\n var listHeight = this.getPopupHeight();\n var nextEle = element.nextElementSibling;\n var height = nextEle ? nextEle.offsetTop : element.offsetTop;\n var liHeight = element.getBoundingClientRect().height;\n if ((height + element.offsetTop) > listHeight) {\n this.popupWrapper.scrollTop = nextEle ? (height - (listHeight / HALFPOSITION + liHeight / HALFPOSITION)) : height;\n }\n else {\n this.popupWrapper.scrollTop = 0;\n }\n };\n TimePicker.prototype.setScrollTo = function () {\n var element;\n if (!isNullOrUndefined(this.popupWrapper)) {\n var items = this.popupWrapper.querySelectorAll('.' + LISTCLASS);\n if (items.length) {\n var initialTime = this.timeCollections[0];\n var scrollTime = this.getDateObject(this.checkDateValue(this.scrollTo)).getTime();\n element = items[Math.round((scrollTime - initialTime) / (this.step * 60000))];\n }\n }\n else {\n this.popupWrapper.scrollTop = 0;\n }\n if (!isNullOrUndefined(element)) {\n this.findScrollTop(element);\n }\n else {\n this.popupWrapper.scrollTop = 0;\n }\n };\n TimePicker.prototype.getText = function () {\n return (isNullOrUndefined(this.checkDateValue(this.value))) ? '' : this.getValue(this.value);\n };\n TimePicker.prototype.getValue = function (value) {\n return (isNullOrUndefined(this.checkDateValue(value))) ? null : this.globalize.formatDate(value, {\n format: this.cldrTimeFormat(), type: 'time'\n });\n };\n TimePicker.prototype.cldrDateFormat = function () {\n var cldrDate;\n if (this.locale === 'en' || this.locale === 'en-US') {\n cldrDate = (getValue('dateFormats.short', getDefaultDateObject()));\n }\n else {\n cldrDate = (this.getCultureDateObject(cldrData, '' + this.locale));\n }\n return cldrDate;\n };\n TimePicker.prototype.cldrTimeFormat = function () {\n var cldrTime;\n if (this.isNullOrEmpty(this.formatString)) {\n if (this.locale === 'en' || this.locale === 'en-US') {\n cldrTime = (getValue('timeFormats.short', getDefaultDateObject()));\n }\n else {\n cldrTime = (this.getCultureTimeObject(cldrData, '' + this.locale));\n }\n }\n else {\n cldrTime = this.formatString;\n }\n return cldrTime;\n };\n TimePicker.prototype.dateToNumeric = function () {\n var cldrTime;\n if (this.locale === 'en' || this.locale === 'en-US') {\n cldrTime = (getValue('timeFormats.medium', getDefaultDateObject()));\n }\n else {\n cldrTime = (getValue('main.' + '' + this.locale + '.dates.calendars.gregorian.timeFormats.medium', cldrData));\n }\n return cldrTime;\n };\n TimePicker.prototype.getExactDateTime = function (value) {\n if (isNullOrUndefined(this.checkDateValue(value))) {\n return null;\n }\n else {\n return this.globalize.formatDate(value, { format: this.dateToNumeric(), type: 'time' });\n }\n };\n TimePicker.prototype.setValue = function (value) {\n var time = this.checkValue(value);\n if (!this.strictMode && !this.validateState(time)) {\n if (this.checkDateValue(this.valueWithMinutes) === null) {\n this.initValue = this.valueWithMinutes = null;\n }\n this.validateMinMax(this.value, this.min, this.max);\n }\n else {\n if (this.isNullOrEmpty(time)) {\n this.initValue = null;\n this.validateMinMax(this.value, this.min, this.max);\n }\n else {\n this.initValue = this.compareFormatChange(time);\n }\n }\n this.updateInput(true, this.initValue);\n };\n TimePicker.prototype.compareFormatChange = function (value) {\n if (isNullOrUndefined(value)) {\n return null;\n }\n return (value !== this.getText()) ? this.getDateObject(value) : this.getDateObject(this.value);\n };\n TimePicker.prototype.updatePlaceHolder = function () {\n Input.setPlaceholder(this.l10n.getConstant('placeholder'), this.inputElement);\n };\n //event related functions\n TimePicker.prototype.updateInputValue = function (value) {\n Input.setValue(value, this.inputElement, this.floatLabelType, this.showClearButton);\n };\n TimePicker.prototype.preventEventBubbling = function (e) {\n e.preventDefault();\n this.interopAdaptor.invokeMethodAsync('OnTimeIconClick');\n };\n TimePicker.prototype.popupHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n if (Browser.isDevice) {\n this.inputElement.setAttribute('readonly', '');\n }\n e.preventDefault();\n if (this.isPopupOpen()) {\n this.closePopup(0, e);\n }\n else {\n this.inputElement.focus();\n this.show(e);\n }\n };\n TimePicker.prototype.mouseDownHandler = function () {\n if (!this.enabled) {\n return;\n }\n if (!this.readonly) {\n this.inputElement.setSelectionRange(0, 0);\n EventHandler.add(this.inputElement, 'mouseup', this.mouseUpHandler, this);\n }\n };\n TimePicker.prototype.mouseUpHandler = function (event) {\n if (!this.readonly) {\n event.preventDefault();\n if (this.enableMask) {\n event.preventDefault();\n this.notify('setMaskSelection', {\n module: 'MaskedDateTime'\n });\n return;\n }\n else {\n EventHandler.remove(this.inputElement, 'mouseup', this.mouseUpHandler);\n var curPos = this.getCursorSelection();\n if (!(curPos.start === 0 && curPos.end === this.inputElement.value.length)) {\n if (this.inputElement.value.length > 0) {\n this.cursorDetails = this.focusSelection();\n }\n this.inputElement.setSelectionRange(this.cursorDetails.start, this.cursorDetails.end);\n }\n }\n }\n };\n TimePicker.prototype.focusSelection = function () {\n var regex = new RegExp('^[a-zA-Z0-9]+$');\n var split = this.inputElement.value.split('');\n split.push(' ');\n var curPos = this.getCursorSelection();\n var start = 0;\n var end = 0;\n var isSeparator = false;\n if (!this.isTextSelected) {\n for (var i = 0; i < split.length; i++) {\n if (!regex.test(split[i])) {\n end = i;\n isSeparator = true;\n }\n if (isSeparator) {\n if (curPos.start >= start && curPos.end <= end) {\n // eslint-disable-next-line no-self-assign\n end = end;\n this.isTextSelected = true;\n break;\n }\n else {\n start = i + 1;\n isSeparator = false;\n }\n }\n }\n }\n else {\n start = curPos.start;\n end = curPos.end;\n this.isTextSelected = false;\n }\n return { start: start, end: end };\n };\n TimePicker.prototype.inputHandler = function (event) {\n if (!this.readonly && this.enabled) {\n if (!((event.action == 'right' || event.action == 'left' || event.action == 'tab') || ((event.action == 'home' || event.action == 'end' || event.action == 'up' || event.action == 'down') && !this.isPopupOpen() && !this.enableMask))) {\n event.preventDefault();\n }\n switch (event.action) {\n case 'home':\n case 'end':\n case 'up':\n case 'down':\n if (!this.isPopupOpen()) {\n this.popupCreation();\n this.popupObj.destroy();\n this.popupObj = this.popupWrapper = null;\n }\n if (this.enableMask && !this.readonly && !this.isPopupOpen()) {\n event.preventDefault();\n this.notify('keyDownHandler', {\n module: 'MaskedDateTime',\n e: event\n });\n }\n if (this.isPopupOpen()) {\n this.keyHandler(event);\n }\n break;\n case 'enter':\n if (this.isNavigate) {\n this.selectedElement = this.liCollections[this.activeIndex];\n this.valueWithMinutes = new Date(this.timeCollections[this.activeIndex]);\n this.updateValue(this.valueWithMinutes, event);\n }\n else {\n this.updateValue(this.inputElement.value, event);\n }\n this.hide();\n this.isNavigate = false;\n if (this.isPopupOpen()) {\n event.stopPropagation();\n }\n break;\n case 'open':\n this.show(event);\n break;\n case 'escape':\n this.updateInputValue(this.objToString(this.value));\n if (this.enableMask) {\n if (!this.value) {\n this.updateInputValue(this.maskedDateValue);\n }\n this.createMask();\n }\n this.previousState(this.value);\n this.hide();\n break;\n case 'close':\n this.hide();\n break;\n case 'right':\n case 'left':\n case 'tab':\n case 'shiftTab':\n if (!this.isPopupOpen() && this.enableMask && !this.readonly) {\n if ((this.inputElement.selectionStart === 0 && this.inputElement.selectionEnd === this.inputElement.value.length) ||\n (this.inputElement.selectionEnd !== this.inputElement.value.length && event.action === 'tab') ||\n (this.inputElement.selectionStart !== 0 && event.action === 'shiftTab') || (event.action === 'left' || event.action === 'right')) {\n event.preventDefault();\n }\n this.notify('keyDownHandler', { module: 'MaskedDateTime',\n e: event\n });\n }\n break;\n default:\n this.isNavigate = false;\n break;\n }\n }\n };\n TimePicker.prototype.onMouseClick = function (event) {\n var target = event.target;\n var li = this.selectedElement = closest(target, '.' + LISTCLASS);\n this.setSelection(li, event);\n if (li && li.classList.contains(LISTCLASS)) {\n this.hide();\n }\n };\n TimePicker.prototype.closePopup = function (delay, e) {\n var _this = this;\n if (this.isPopupOpen() && this.popupWrapper) {\n var args = {\n popup: this.popupObj,\n event: e || null,\n cancel: false,\n name: 'open'\n };\n removeClass([document.body], OVERFLOW);\n this.trigger('close', args, function (args) {\n if (!args.cancel) {\n var animModel = {\n name: 'FadeOut',\n duration: ANIMATIONDURATION,\n delay: delay ? delay : 0\n };\n _this.popupObj.hide(new Animation(animModel));\n removeClass([_this.inputWrapper.container], [ICONANIMATION]);\n attributes(_this.inputElement, { 'aria-expanded': 'false' });\n _this.inputElement.removeAttribute('aria-owns');\n _this.inputElement.removeAttribute('aria-controls');\n _this.inputElement.removeAttribute('aria-activedescendant');\n EventHandler.remove(document, 'mousedown touchstart', _this.documentClickHandler);\n }\n if (Browser.isDevice && _this.modal) {\n _this.modal.style.display = 'none';\n _this.modal.outerHTML = '';\n _this.modal = null;\n }\n if (Browser.isDevice) {\n if (!isNullOrUndefined(_this.mobileTimePopupWrap)) {\n _this.mobileTimePopupWrap.remove();\n _this.mobileTimePopupWrap = null;\n }\n }\n if (Browser.isDevice && _this.allowEdit && !_this.readonly) {\n _this.inputElement.removeAttribute('readonly');\n }\n });\n }\n else {\n if (Browser.isDevice && this.allowEdit && !this.readonly) {\n this.inputElement.removeAttribute('readonly');\n }\n }\n };\n TimePicker.prototype.disposeServerPopup = function () {\n if (this.popupWrapper) {\n this.popupWrapper.style.visibility = 'hidden';\n this.popupWrapper.style.top = '-9999px';\n this.popupWrapper.style.left = '-9999px';\n this.popupWrapper.style.width = '0px';\n this.popupWrapper.style.height = '0px';\n }\n };\n TimePicker.prototype.checkValueChange = function (event, isNavigation) {\n if (!this.strictMode && !this.validateState(this.valueWithMinutes)) {\n if (this.checkDateValue(this.valueWithMinutes) === null) {\n this.initValue = this.valueWithMinutes = null;\n }\n this.setProperties({ value: this.compareFormatChange(this.inputElement.value) }, true);\n this.initValue = this.valueWithMinutes = this.compareFormatChange(this.inputElement.value);\n this.prevValue = this.inputElement.value;\n if (+this.prevDate !== +this.value) {\n this.changeEvent(event);\n }\n }\n else {\n if (!isNavigation) {\n if ((this.prevValue !== this.inputElement.value) || isNullOrUndefined(this.checkDateValue(this.value))) {\n this.valueProcess(event, this.compareFormatChange(this.inputElement.value));\n }\n }\n else {\n var value = this.getDateObject(new Date(this.timeCollections[this.activeIndex]));\n if (+this.prevDate !== +value) {\n this.valueProcess(event, value);\n }\n }\n }\n };\n TimePicker.prototype.onMouseOver = function (event) {\n var currentLi = closest(event.target, '.' + LISTCLASS);\n this.setHover(currentLi, HOVER);\n };\n TimePicker.prototype.setHover = function (li, className) {\n if (this.enabled && this.isValidLI(li) && !li.classList.contains(className)) {\n this.removeHover(className);\n addClass([li], className);\n if (className === NAVIGATION) {\n li.setAttribute('aria-selected', 'true');\n }\n }\n };\n TimePicker.prototype.setSelection = function (li, event) {\n if (this.isValidLI(li)) {\n this.checkValue(li.getAttribute('data-value'));\n if (this.enableMask) {\n this.createMask();\n }\n this.selectedElement = li;\n this.activeIndex = Array.prototype.slice.call(this.liCollections).indexOf(li);\n this.valueWithMinutes = new Date(this.timeCollections[this.activeIndex]);\n addClass([this.selectedElement], SELECTED);\n this.selectedElement.setAttribute('aria-selected', 'true');\n this.checkValueChange(event, true);\n }\n };\n TimePicker.prototype.onMouseLeave = function () {\n this.removeHover(HOVER);\n };\n TimePicker.prototype.scrollHandler = function () {\n if (this.getModuleName() === 'timepicker' && Browser.isDevice) {\n return;\n }\n else {\n this.hide();\n }\n };\n TimePicker.prototype.setMinMax = function (minVal, maxVal) {\n if (isNullOrUndefined(this.checkDateValue(minVal))) {\n this.initMin = this.getDateObject('12:00:00 AM');\n }\n if (isNullOrUndefined(this.checkDateValue(maxVal))) {\n this.initMax = this.getDateObject('11:59:59 PM');\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n TimePicker.prototype.validateMinMax = function (dateVal, minVal, maxVal) {\n var value = dateVal instanceof Date ? dateVal : this.getDateObject(dateVal);\n if (!isNullOrUndefined(this.checkDateValue(value))) {\n dateVal = this.strictOperation(this.initMin, this.initMax, dateVal, value);\n }\n else if (+(this.createDateObj(this.getFormattedValue(this.initMin))) >\n +(this.createDateObj(this.getFormattedValue(this.initMax)))) {\n this.disableTimeIcon();\n }\n if (this.strictMode) {\n dateVal = this.valueIsDisable(dateVal) ? dateVal : null;\n }\n this.checkErrorState(dateVal);\n return dateVal;\n };\n TimePicker.prototype.valueIsDisable = function (value) {\n if (this.disableItemCollection.length > 0) {\n if (this.disableItemCollection.length === this.timeCollections.length) {\n return false;\n }\n var time = value instanceof Date ? this.objToString(value) : value;\n for (var index = 0; index < this.disableItemCollection.length; index++) {\n if (time === this.disableItemCollection[index]) {\n return false;\n }\n }\n }\n return true;\n };\n TimePicker.prototype.validateState = function (val) {\n if (!this.strictMode) {\n if (this.valueIsDisable(val)) {\n var value = typeof val === 'string' ? this.setCurrentDate(this.getDateObject(val)) :\n this.setCurrentDate(this.getDateObject(val));\n var maxValue = this.setCurrentDate(this.getDateObject(this.initMax));\n var minValue = this.setCurrentDate(this.getDateObject(this.initMin));\n if (!isNullOrUndefined(this.checkDateValue(value))) {\n if ((+(value) > +(maxValue)) || (+(value) < +(minValue))) {\n return false;\n }\n }\n else {\n if ((+(maxValue) < +(minValue)) || this.inputElement.value !== '') {\n return false;\n }\n }\n }\n else {\n return false;\n }\n }\n return true;\n };\n TimePicker.prototype.strictOperation = function (minimum, maximum, dateVal, val) {\n var maxValue = this.createDateObj(this.getFormattedValue(maximum));\n var minValue = this.createDateObj(this.getFormattedValue(minimum));\n var value = this.createDateObj(this.getFormattedValue(val));\n if (this.strictMode) {\n if (+minValue > +maxValue) {\n this.disableTimeIcon();\n this.initValue = this.getDateObject(maxValue);\n this.updateInputValue(this.getValue(this.initValue));\n if (this.enableMask) {\n this.createMask();\n }\n return this.inputElement.value;\n }\n else if (+minValue >= +value) {\n return this.getDateObject(minValue);\n }\n else if (+value >= +maxValue || +minValue === +maxValue) {\n return this.getDateObject(maxValue);\n }\n }\n else {\n if (+minValue > +maxValue) {\n this.disableTimeIcon();\n if (!isNaN(+this.createDateObj(dateVal))) {\n return dateVal;\n }\n }\n }\n return dateVal;\n };\n TimePicker.prototype.bindEvents = function () {\n EventHandler.add(this.inputWrapper.buttons[0], 'mousedown', this.popupHandler, this);\n EventHandler.add(this.inputElement, 'blur', this.inputBlurHandler, this);\n EventHandler.add(this.inputElement, 'focus', this.inputFocusHandler, this);\n EventHandler.add(this.inputElement, 'change', this.inputChangeHandler, this);\n EventHandler.add(this.inputElement, 'input', this.inputEventHandler, this);\n if (this.enableMask) {\n EventHandler.add(this.inputElement, 'keydown', this.keydownHandler, this);\n }\n if (this.showClearButton && this.inputWrapper.clearButton) {\n EventHandler.add(this.inputWrapper.clearButton, 'mousedown', this.clearHandler, this);\n }\n if (this.formElement) {\n EventHandler.add(this.formElement, 'reset', this.formResetHandler, this);\n }\n if (!Browser.isDevice) {\n this.keyConfigure = extend(this.keyConfigure, this.keyConfigs);\n this.inputEvent = new KeyboardEvents(this.inputWrapper.container, {\n keyAction: this.inputHandler.bind(this),\n keyConfigs: this.keyConfigure,\n eventName: 'keydown'\n });\n if (this.showClearButton && this.inputElement) {\n EventHandler.add(this.inputElement, 'mousedown', this.mouseDownHandler, this);\n }\n }\n };\n TimePicker.prototype.keydownHandler = function (e) {\n switch (e.code) {\n case 'Delete':\n if (this.enableMask && !this.popupObj && !this.readonly) {\n this.notify('keyDownHandler', {\n module: 'MaskedDateTime',\n e: e\n });\n }\n break;\n default:\n break;\n }\n };\n TimePicker.prototype.formResetHandler = function () {\n if (!this.enabled) {\n return;\n }\n if (!this.inputElement.disabled) {\n var timeValue = this.inputElement.getAttribute('value');\n var val = this.checkDateValue(this.inputEleValue);\n if (this.element.tagName === 'EJS-TIMEPICKER') {\n val = null;\n timeValue = '';\n this.inputElement.setAttribute('value', '');\n }\n this.setProperties({ value: val }, true);\n this.prevDate = this.value;\n this.valueWithMinutes = this.value;\n this.initValue = this.value;\n if (this.inputElement) {\n this.updateInputValue(timeValue);\n if (this.enableMask) {\n if (!timeValue) {\n this.updateInputValue(this.maskedDateValue);\n }\n this.createMask();\n }\n this.checkErrorState(timeValue);\n this.prevValue = this.inputElement.value;\n }\n }\n };\n TimePicker.prototype.inputChangeHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n e.stopPropagation();\n };\n TimePicker.prototype.inputEventHandler = function () {\n if (this.enableMask) {\n this.notify('inputHandler', {\n module: 'MaskedDateTime'\n });\n }\n };\n TimePicker.prototype.unBindEvents = function () {\n if (this.inputWrapper) {\n EventHandler.remove(this.inputWrapper.buttons[0], 'mousedown touchstart', this.popupHandler);\n }\n EventHandler.remove(this.inputElement, 'blur', this.inputBlurHandler);\n EventHandler.remove(this.inputElement, 'focus', this.inputFocusHandler);\n EventHandler.remove(this.inputElement, 'change', this.inputChangeHandler);\n EventHandler.remove(this.inputElement, 'input', this.inputEventHandler);\n if (this.inputEvent) {\n this.inputEvent.destroy();\n }\n EventHandler.remove(this.inputElement, 'mousedown touchstart', this.mouseDownHandler);\n if (this.showClearButton && !isNullOrUndefined(this.inputWrapper) && !isNullOrUndefined(this.inputWrapper.clearButton)) {\n EventHandler.remove(this.inputWrapper.clearButton, 'mousedown touchstart', this.clearHandler);\n }\n if (this.formElement) {\n EventHandler.remove(this.formElement, 'reset', this.formResetHandler);\n }\n };\n TimePicker.prototype.bindClearEvent = function () {\n if (this.showClearButton && this.inputWrapper.clearButton) {\n EventHandler.add(this.inputWrapper.clearButton, 'mousedown', this.clearHandler, this);\n }\n };\n TimePicker.prototype.raiseClearedEvent = function (e) {\n var clearedArgs = {\n event: e\n };\n this.trigger('cleared', clearedArgs);\n };\n TimePicker.prototype.clearHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n e.preventDefault();\n if (!isNullOrUndefined(this.value)) {\n this.clear(e);\n }\n else {\n this.resetState();\n this.raiseClearedEvent(e);\n }\n if (this.popupWrapper) {\n this.popupWrapper.scrollTop = 0;\n }\n if (this.enableMask) {\n this.notify('clearHandler', {\n module: 'MaskedDateTime'\n });\n }\n if (closest(this.element, 'form')) {\n var element = this.element;\n var keyupEvent = document.createEvent('KeyboardEvent');\n keyupEvent.initEvent('keyup', false, true);\n element.dispatchEvent(keyupEvent);\n }\n };\n TimePicker.prototype.clear = function (event) {\n this.setProperties({ value: null }, true);\n this.initValue = null;\n this.resetState();\n this.raiseClearedEvent(event);\n this.changeEvent(event);\n };\n TimePicker.prototype.setZIndex = function () {\n if (this.popupObj) {\n this.popupObj.zIndex = this.zIndex;\n this.popupObj.dataBind();\n }\n };\n TimePicker.prototype.checkAttributes = function (isDynamic) {\n var attributes = isDynamic ? isNullOrUndefined(this.htmlAttributes) ? [] : Object.keys(this.htmlAttributes) :\n ['step', 'disabled', 'readonly', 'style', 'name', 'value', 'min', 'max', 'placeholder'];\n var value;\n for (var _i = 0, attributes_1 = attributes; _i < attributes_1.length; _i++) {\n var prop = attributes_1[_i];\n if (!isNullOrUndefined(this.inputElement.getAttribute(prop))) {\n switch (prop) {\n case 'disabled':\n if ((isNullOrUndefined(this.timeOptions) || (this.timeOptions['enabled'] === undefined)) || isDynamic) {\n var enabled = this.inputElement.getAttribute(prop) === 'disabled' ||\n this.inputElement.getAttribute(prop) === '' || this.inputElement.getAttribute(prop) === 'true' ? false : true;\n this.setProperties({ enabled: enabled }, !isDynamic);\n }\n break;\n case 'style':\n this.inputStyle = this.inputElement.getAttribute(prop);\n break;\n case 'readonly':\n if ((isNullOrUndefined(this.timeOptions) || (this.timeOptions['readonly'] === undefined)) || isDynamic) {\n var readonly = this.inputElement.getAttribute(prop) === 'readonly' ||\n this.inputElement.getAttribute(prop) === '' || this.inputElement.getAttribute(prop) === 'true' ? true : false;\n this.setProperties({ readonly: readonly }, !isDynamic);\n }\n break;\n case 'name':\n this.inputElement.setAttribute('name', this.inputElement.getAttribute(prop));\n break;\n case 'step':\n this.step = parseInt(this.inputElement.getAttribute(prop), 10);\n break;\n case 'placeholder':\n if ((isNullOrUndefined(this.timeOptions) || (this.timeOptions['placeholder'] === undefined)) || isDynamic) {\n this.setProperties({ placeholder: this.inputElement.getAttribute(prop) }, !isDynamic);\n }\n break;\n case 'min':\n if ((isNullOrUndefined(this.timeOptions) || (this.timeOptions['min'] === undefined)) || isDynamic) {\n value = new Date(this.inputElement.getAttribute(prop));\n if (!isNullOrUndefined(this.checkDateValue(value))) {\n this.setProperties({ min: value }, !isDynamic);\n }\n }\n break;\n case 'max':\n if ((isNullOrUndefined(this.timeOptions) || (this.timeOptions['max'] === undefined)) || isDynamic) {\n value = new Date(this.inputElement.getAttribute(prop));\n if (!isNullOrUndefined(this.checkDateValue(value))) {\n this.setProperties({ max: value }, !isDynamic);\n }\n }\n break;\n case 'value':\n if ((isNullOrUndefined(this.timeOptions) || (this.timeOptions['value'] === undefined)) || isDynamic) {\n value = new Date(this.inputElement.getAttribute(prop));\n if (!isNullOrUndefined(this.checkDateValue(value))) {\n this.initValue = value;\n this.updateInput(false, this.initValue);\n this.setProperties({ value: value }, !isDynamic);\n }\n }\n break;\n }\n }\n }\n };\n TimePicker.prototype.setCurrentDate = function (value) {\n if (isNullOrUndefined(this.checkDateValue(value))) {\n return null;\n }\n return new Date(YEAR, MONTH, DAY, value.getHours(), value.getMinutes(), value.getSeconds());\n };\n TimePicker.prototype.getTextFormat = function () {\n var time = 0;\n if (this.cldrTimeFormat().split(' ')[0] === 'a' || this.cldrTimeFormat().indexOf('a') === 0) {\n time = 1;\n }\n else if (this.cldrTimeFormat().indexOf('a') < 0) {\n var strArray = this.cldrTimeFormat().split(' ');\n for (var i = 0; i < strArray.length; i++) {\n if (strArray[i].toLowerCase().indexOf('h') >= 0) {\n time = i;\n break;\n }\n }\n }\n return time;\n };\n TimePicker.prototype.updateValue = function (value, event) {\n var val;\n if (this.isNullOrEmpty(value)) {\n this.resetState();\n }\n else {\n val = this.checkValue(value);\n if (this.strictMode) {\n // this case set previous value to the text box when set invalid date\n var inputVal = (val === null && value.trim().length > 0) ?\n this.previousState(this.prevDate) : this.inputElement.value;\n this.updateInputValue(inputVal);\n if (this.enableMask) {\n if (!inputVal) {\n this.updateInputValue(this.maskedDateValue);\n }\n if (isNullOrUndefined(val) && value !== this.maskedDateValue) {\n this.createMask();\n }\n if (isNullOrUndefined(val) && value === this.maskedDateValue) {\n this.updateInputValue(this.maskedDateValue);\n }\n }\n }\n }\n this.checkValueChange(event, typeof value === 'string' ? false : true);\n };\n TimePicker.prototype.previousState = function (date) {\n var value = this.getDateObject(date);\n for (var i = 0; i < this.timeCollections.length; i++) {\n if (+value === this.timeCollections[i]) {\n this.activeIndex = i;\n this.selectedElement = this.liCollections[i];\n this.valueWithMinutes = new Date(this.timeCollections[i]);\n break;\n }\n }\n return this.prevValue;\n };\n TimePicker.prototype.resetState = function () {\n this.removeSelection();\n Input.setValue('', this.inputElement, this.floatLabelType, false);\n this.valueWithMinutes = this.activeIndex = null;\n if (!this.strictMode) {\n this.checkErrorState(null);\n }\n };\n TimePicker.prototype.objToString = function (val) {\n if (isNullOrUndefined(this.checkDateValue(val))) {\n return null;\n }\n else {\n return this.globalize.formatDate(val, { format: this.cldrTimeFormat(), type: 'time' });\n }\n };\n TimePicker.prototype.checkValue = function (value) {\n if (!this.isNullOrEmpty(value)) {\n var date = value instanceof Date ? value : this.getDateObject(value);\n return this.validateValue(date, value);\n }\n this.resetState();\n return this.valueWithMinutes = null;\n };\n TimePicker.prototype.validateValue = function (date, value) {\n var time;\n var val = this.validateMinMax(value, this.min, this.max);\n var newval = this.getDateObject(val);\n if (this.getFormattedValue(newval) !== this.getFormattedValue(this.value)) {\n this.valueWithMinutes = isNullOrUndefined(newval) ? null : newval;\n time = this.objToString(this.valueWithMinutes);\n }\n else {\n if (this.strictMode) {\n //for strict mode case, when value not present within a range. Reset the nearest range value.\n date = newval;\n }\n this.valueWithMinutes = this.checkDateValue(date);\n time = this.objToString(this.valueWithMinutes);\n }\n if (!this.strictMode && isNullOrUndefined(time)) {\n var value_1 = val.trim().length > 0 ? val : '';\n this.updateInputValue(value_1);\n if (this.enableMask) {\n if (!value_1) {\n this.updateInputValue(this.maskedDateValue);\n }\n }\n }\n else {\n this.updateInputValue(time);\n if (this.enableMask) {\n if (time === '') {\n this.updateInputValue(this.maskedDateValue);\n }\n if (isNullOrUndefined(time) && value !== this.maskedDateValue) {\n this.createMask();\n }\n if (isNullOrUndefined(time) && value === this.maskedDateValue) {\n this.updateInputValue(this.maskedDateValue);\n }\n }\n }\n return time;\n };\n TimePicker.prototype.createMask = function () {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n };\n TimePicker.prototype.findNextElement = function (event) {\n var textVal = (this.inputElement).value;\n var value = isNullOrUndefined(this.valueWithMinutes) ? this.createDateObj(textVal) :\n this.getDateObject(this.valueWithMinutes);\n var timeVal = null;\n var count = this.liCollections.length;\n var collections = this.timeCollections;\n if (!isNullOrUndefined(this.checkDateValue(value)) || !isNullOrUndefined(this.activeIndex)) {\n if (event.action === 'home') {\n var index = this.validLiElement(0);\n timeVal = +(this.createDateObj(new Date(this.timeCollections[index])));\n this.activeIndex = index;\n }\n else if (event.action === 'end') {\n var index = this.validLiElement(collections.length - 1, true);\n timeVal = +(this.createDateObj(new Date(this.timeCollections[index])));\n this.activeIndex = index;\n }\n else {\n if (event.action === 'down') {\n for (var i = 0; i < count; i++) {\n if (+value < this.timeCollections[i]) {\n var index = this.validLiElement(i);\n timeVal = +(this.createDateObj(new Date(this.timeCollections[index])));\n this.activeIndex = index;\n break;\n }\n else if (i === count - 1) {\n var index = this.validLiElement(0);\n timeVal = +(this.createDateObj(new Date(this.timeCollections[index])));\n this.activeIndex = index;\n break;\n }\n }\n }\n else {\n for (var i = count - 1; i >= 0; i--) {\n if (+value > this.timeCollections[i]) {\n var index = this.validLiElement(i, true);\n timeVal = +(this.createDateObj(new Date(this.timeCollections[index])));\n this.activeIndex = index;\n break;\n }\n else if (i === 0) {\n var index = this.validLiElement(count - 1);\n timeVal = +(this.createDateObj(new Date(this.timeCollections[index])));\n this.activeIndex = index;\n break;\n }\n }\n }\n }\n this.selectedElement = this.liCollections[this.activeIndex];\n this.elementValue(isNullOrUndefined(timeVal) ? null : new Date(timeVal));\n }\n else {\n this.selectNextItem(event);\n }\n };\n TimePicker.prototype.selectNextItem = function (event) {\n var index = this.validLiElement(0, event.action === 'down' ? false : true);\n this.activeIndex = index;\n this.selectedElement = this.liCollections[index];\n this.elementValue(new Date(this.timeCollections[index]));\n };\n TimePicker.prototype.elementValue = function (value) {\n if (!isNullOrUndefined(this.checkDateValue(value))) {\n this.checkValue(value);\n }\n };\n TimePicker.prototype.validLiElement = function (index, backward) {\n var elementIndex = null;\n var items = isNullOrUndefined(this.popupWrapper) ? this.liCollections :\n this.popupWrapper.querySelectorAll('.' + LISTCLASS);\n var isCheck = true;\n if (items.length) {\n if (backward) {\n for (var i = index; i >= 0; i--) {\n if (!items[i].classList.contains(DISABLED)) {\n elementIndex = i;\n break;\n }\n else if (i === 0) {\n if (isCheck) {\n index = i = items.length;\n isCheck = false;\n }\n }\n }\n }\n else {\n for (var i = index; i <= items.length - 1; i++) {\n if (!items[i].classList.contains(DISABLED)) {\n elementIndex = i;\n break;\n }\n else if (i === items.length - 1) {\n if (isCheck) {\n index = i = -1;\n isCheck = false;\n }\n }\n }\n }\n }\n return elementIndex;\n };\n TimePicker.prototype.keyHandler = function (event) {\n if (isNullOrUndefined(this.step) || this.step <= 0 || !isNullOrUndefined(this.inputWrapper)\n && this.inputWrapper.buttons[0].classList.contains(DISABLED)) {\n return;\n }\n var count = this.timeCollections.length;\n if (isNullOrUndefined(this.getActiveElement()) || this.getActiveElement().length === 0) {\n if (this.liCollections.length > 0) {\n if (isNullOrUndefined(this.value) && isNullOrUndefined(this.activeIndex)) {\n var index = this.validLiElement(0, event.action === 'down' ? false : true);\n this.activeIndex = index;\n this.selectedElement = this.liCollections[index];\n this.elementValue(new Date(this.timeCollections[index]));\n }\n else {\n this.findNextElement(event);\n }\n }\n else {\n this.findNextElement(event);\n }\n }\n else {\n var nextItem = void 0;\n if ((event.keyCode >= 37) && (event.keyCode <= 40)) {\n var index = (event.keyCode === 40 || event.keyCode === 39) ? ++this.activeIndex : --this.activeIndex;\n this.activeIndex = index = this.activeIndex === (count) ? 0 : this.activeIndex;\n this.activeIndex = index = this.activeIndex < 0 ? (count - 1) : this.activeIndex;\n this.activeIndex = index = this.validLiElement(this.activeIndex, (event.keyCode === 40 || event.keyCode === 39) ?\n false : true);\n nextItem = isNullOrUndefined(this.timeCollections[index]) ?\n this.timeCollections[0] : this.timeCollections[index];\n }\n else if (event.action === 'home') {\n var index = this.validLiElement(0);\n this.activeIndex = index;\n nextItem = this.timeCollections[index];\n }\n else if (event.action === 'end') {\n var index = this.validLiElement(count - 1, true);\n this.activeIndex = index;\n nextItem = this.timeCollections[index];\n }\n this.selectedElement = this.liCollections[this.activeIndex];\n this.elementValue(new Date(nextItem));\n }\n this.isNavigate = true;\n this.setHover(this.selectedElement, NAVIGATION);\n this.setActiveDescendant();\n if (this.enableMask) {\n this.selectInputText();\n }\n if (this.isPopupOpen() && this.selectedElement !== null && (!event || event.type !== 'click')) {\n this.setScrollPosition();\n }\n };\n TimePicker.prototype.getCultureTimeObject = function (ld, c) {\n return getValue('main.' + c + '.dates.calendars.gregorian.timeFormats.short', ld);\n };\n TimePicker.prototype.getCultureDateObject = function (ld, c) {\n return getValue('main.' + c + '.dates.calendars.gregorian.dateFormats.short', ld);\n };\n TimePicker.prototype.wireListEvents = function () {\n EventHandler.add(this.listWrapper, 'click', this.onMouseClick, this);\n if (!Browser.isDevice) {\n EventHandler.add(this.listWrapper, 'mouseover', this.onMouseOver, this);\n EventHandler.add(this.listWrapper, 'mouseout', this.onMouseLeave, this);\n }\n };\n TimePicker.prototype.unWireListEvents = function () {\n if (this.listWrapper) {\n EventHandler.remove(this.listWrapper, 'click', this.onMouseClick);\n if (!Browser.isDevice) {\n EventHandler.remove(this.listWrapper, 'mouseover', this.onMouseOver);\n EventHandler.remove(this.listWrapper, 'mouseout', this.onMouseLeave);\n }\n }\n };\n TimePicker.prototype.valueProcess = function (event, value) {\n var result = (isNullOrUndefined(this.checkDateValue(value))) ? null : value;\n if (+this.prevDate !== +result) {\n this.initValue = result;\n this.changeEvent(event);\n }\n };\n TimePicker.prototype.changeEvent = function (e) {\n this.addSelection();\n this.updateInput(true, this.initValue);\n var eventArgs = {\n event: (e || null),\n value: this.value,\n text: (this.inputElement).value,\n isInteracted: !isNullOrUndefined(e),\n element: this.element\n };\n eventArgs.value = this.valueWithMinutes || this.getDateObject(this.inputElement.value);\n this.prevDate = this.valueWithMinutes || this.getDateObject(this.inputElement.value);\n if (this.isAngular && this.preventChange) {\n this.preventChange = false;\n }\n else {\n this.trigger('change', eventArgs);\n }\n this.invalidValueString = null;\n this.checkErrorState(this.value);\n };\n TimePicker.prototype.updateInput = function (isUpdate, date) {\n if (isUpdate) {\n this.prevValue = this.getValue(date);\n }\n this.prevDate = this.valueWithMinutes = date;\n if ((typeof date !== 'number') || (this.value && +new Date(+this.value).setMilliseconds(0)) !== +date) {\n this.setProperties({ value: date }, true);\n if (this.enableMask && this.value) {\n this.createMask();\n }\n }\n if (!this.strictMode && isNullOrUndefined(this.value) && this.invalidValueString) {\n this.checkErrorState(this.invalidValueString);\n this.updateInputValue(this.invalidValueString);\n }\n this.clearIconState();\n };\n TimePicker.prototype.setActiveDescendant = function () {\n if (!isNullOrUndefined(this.selectedElement) && this.value) {\n attributes(this.inputElement, { 'aria-activedescendant': this.selectedElement.getAttribute('id') });\n }\n else {\n this.inputElement.removeAttribute('aria-activedescendant');\n }\n };\n TimePicker.prototype.removeSelection = function () {\n this.removeHover(HOVER);\n if (!isNullOrUndefined(this.popupWrapper)) {\n var items = this.popupWrapper.querySelectorAll('.' + SELECTED);\n if (items.length) {\n removeClass(items, SELECTED);\n items[0].removeAttribute('aria-selected');\n }\n }\n };\n TimePicker.prototype.removeHover = function (className) {\n var hoveredItem = this.getHoverItem(className);\n if (hoveredItem && hoveredItem.length) {\n removeClass(hoveredItem, className);\n if (className === NAVIGATION) {\n hoveredItem[0].removeAttribute('aria-selected');\n }\n }\n };\n TimePicker.prototype.getHoverItem = function (className) {\n var hoveredItem;\n if (!isNullOrUndefined(this.popupWrapper)) {\n hoveredItem = this.popupWrapper.querySelectorAll('.' + className);\n }\n return hoveredItem;\n };\n TimePicker.prototype.setActiveClass = function () {\n if (!isNullOrUndefined(this.popupWrapper)) {\n var items = this.popupWrapper.querySelectorAll('.' + LISTCLASS);\n if (items.length) {\n for (var i = 0; i < items.length; i++) {\n if ((this.timeCollections[i] === +this.getDateObject(this.valueWithMinutes))) {\n items[i].setAttribute('aria-selected', 'true');\n this.selectedElement = items[i];\n this.activeIndex = i;\n break;\n }\n }\n }\n }\n };\n TimePicker.prototype.addSelection = function () {\n this.selectedElement = null;\n this.removeSelection();\n this.setActiveClass();\n if (!isNullOrUndefined(this.selectedElement)) {\n addClass([this.selectedElement], SELECTED);\n this.selectedElement.setAttribute('aria-selected', 'true');\n }\n };\n TimePicker.prototype.isValidLI = function (li) {\n return (li && li.classList.contains(LISTCLASS) && !li.classList.contains(DISABLED));\n };\n TimePicker.prototype.createDateObj = function (val) {\n var formatStr = null;\n var today = this.globalize.formatDate(new Date(), { format: formatStr, skeleton: 'short', type: 'date' });\n var value = null;\n if (typeof val === 'string') {\n if (val.toUpperCase().indexOf('AM') > -1 || val.toUpperCase().indexOf('PM') > -1) {\n today = this.defaultCulture.formatDate(new Date(), { format: formatStr, skeleton: 'short', type: 'date' });\n value = isNaN(+new Date(today + ' ' + val)) ? null : new Date(new Date(today + ' ' + val).setMilliseconds(0));\n if (isNullOrUndefined(value)) {\n value = this.timeParse(today, val);\n }\n }\n else {\n value = this.timeParse(today, val);\n }\n }\n else if (val instanceof Date) {\n value = val;\n }\n return value;\n };\n TimePicker.prototype.timeParse = function (today, val) {\n var value;\n value = this.globalize.parseDate(today + ' ' + val, {\n format: this.cldrDateFormat() + ' ' + this.cldrTimeFormat(), type: 'datetime'\n });\n value = isNullOrUndefined(value) ? this.globalize.parseDate(today + ' ' + val, {\n format: this.cldrDateFormat() + ' ' + this.dateToNumeric(), type: 'datetime'\n }) : value;\n value = isNullOrUndefined(value) ? value : new Date(value.setMilliseconds(0));\n return value;\n };\n TimePicker.prototype.createListItems = function () {\n var _this = this;\n this.listWrapper = this.createElement('div', { className: CONTENT, attrs: { 'tabindex': '-1' } });\n var start;\n var interval = this.step * 60000;\n var listItems = [];\n this.timeCollections = [];\n this.disableItemCollection = [];\n start = +(this.getDateObject(this.initMin).setMilliseconds(0));\n var end = +(this.getDateObject(this.initMax).setMilliseconds(0));\n while (end >= start) {\n this.timeCollections.push(start);\n listItems.push(this.globalize.formatDate(new Date(start), { format: this.cldrTimeFormat(), type: 'time' }));\n start += interval;\n }\n var listBaseOptions = {\n itemCreated: function (args) {\n var eventArgs = {\n element: args.item,\n text: args.text, value: _this.getDateObject(args.text), isDisabled: false\n };\n _this.trigger('itemRender', eventArgs, function (eventArgs) {\n if (eventArgs.isDisabled) {\n eventArgs.element.classList.add(DISABLED);\n }\n if (eventArgs.element.classList.contains(DISABLED)) {\n _this.disableItemCollection.push(eventArgs.element.getAttribute('data-value'));\n }\n });\n }\n };\n this.listTag = ListBase.createList(this.createElement, listItems, listBaseOptions, true);\n attributes(this.listTag, { 'role': 'listbox', 'aria-hidden': 'false', 'id': this.element.id + '_options', 'tabindex': '0' });\n append([this.listTag], this.listWrapper);\n };\n TimePicker.prototype.documentClickHandler = function (event) {\n var target = event.target;\n if ((!isNullOrUndefined(this.popupObj) && !isNullOrUndefined(this.inputWrapper) && (this.inputWrapper.container.contains(target) && event.type !== 'mousedown' ||\n (this.popupObj.element && this.popupObj.element.contains(target)))) && event.type !== 'touchstart') {\n event.preventDefault();\n }\n if (!(closest(target, '[id=\"' + this.popupObj.element.id + '\"]')) && target !== this.inputElement\n && target !== (this.inputWrapper && this.inputWrapper.buttons[0]) &&\n target !== (this.inputWrapper && this.inputWrapper.clearButton) &&\n target !== (this.inputWrapper && this.inputWrapper.container)\n && (!target.classList.contains('e-dlg-overlay'))) {\n if (this.isPopupOpen()) {\n this.hide();\n this.focusOut();\n }\n }\n else if (target !== this.inputElement) {\n if (!Browser.isDevice) {\n this.isPreventBlur = (Browser.isIE || Browser.info.name === 'edge') && (document.activeElement === this.inputElement)\n && (target === this.popupWrapper);\n }\n }\n };\n TimePicker.prototype.setEnableRtl = function () {\n Input.setEnableRtl(this.enableRtl, [this.inputWrapper.container]);\n if (this.popupObj) {\n this.popupObj.enableRtl = this.enableRtl;\n this.popupObj.dataBind();\n }\n };\n TimePicker.prototype.setEnable = function () {\n Input.setEnabled(this.enabled, this.inputElement, this.floatLabelType);\n if (this.enabled) {\n removeClass([this.inputWrapper.container], DISABLED);\n attributes(this.inputElement, { 'aria-disabled': 'false' });\n this.inputElement.setAttribute('tabindex', this.tabIndex);\n }\n else {\n this.hide();\n addClass([this.inputWrapper.container], DISABLED);\n attributes(this.inputElement, { 'aria-disabled': 'true' });\n this.inputElement.tabIndex = -1;\n }\n };\n TimePicker.prototype.getProperty = function (date, val) {\n if (val === 'min') {\n this.initMin = this.checkDateValue(new Date(this.checkInValue(date.min)));\n this.setProperties({ min: this.initMin }, true);\n }\n else {\n this.initMax = this.checkDateValue(new Date(this.checkInValue(date.max)));\n this.setProperties({ max: this.initMax }, true);\n }\n if (this.inputElement.value === '') {\n this.validateMinMax(this.value, this.min, this.max);\n }\n else {\n this.checkValue(this.inputElement.value);\n }\n this.checkValueChange(null, false);\n };\n TimePicker.prototype.inputBlurHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n // IE popup closing issue when click over the scrollbar\n if (this.isPreventBlur && this.isPopupOpen()) {\n this.inputElement.focus();\n return;\n }\n this.closePopup(0, e);\n if (this.enableMask && this.maskedDateValue && this.placeholder && this.floatLabelType !== 'Always') {\n if (this.inputElement.value === this.maskedDateValue && !this.value && (this.floatLabelType === 'Auto' || this.floatLabelType === 'Never' || this.placeholder)) {\n this.updateInputValue('');\n }\n }\n removeClass([this.inputWrapper.container], [FOCUS]);\n if (this.getText() !== this.inputElement.value) {\n this.updateValue((this.inputElement).value, e);\n }\n else if (this.inputElement.value.trim().length === 0) {\n this.resetState();\n }\n this.cursorDetails = null;\n this.isNavigate = false;\n if (this.inputElement.value === '') {\n this.invalidValueString = null;\n }\n var blurArguments = {\n model: this\n };\n this.trigger('blur', blurArguments);\n };\n /**\n * Focuses out the TimePicker textbox element.\n *\n * @returns {void}\n */\n TimePicker.prototype.focusOut = function () {\n if (document.activeElement === this.inputElement) {\n this.inputElement.blur();\n removeClass([this.inputWrapper.container], [FOCUS]);\n var blurArguments = {\n model: this\n };\n this.trigger('blur', blurArguments);\n }\n };\n TimePicker.prototype.isPopupOpen = function () {\n if (this.popupWrapper && this.popupWrapper.classList.contains('' + ROOT)) {\n return true;\n }\n return false;\n };\n TimePicker.prototype.inputFocusHandler = function () {\n if (!this.enabled) {\n return;\n }\n var focusArguments = {\n model: this\n };\n if (!this.readonly && !Browser.isDevice && !this.enableMask) {\n this.selectInputText();\n }\n if (this.enableMask && !this.inputElement.value && this.placeholder) {\n if (this.maskedDateValue && !this.value && (this.floatLabelType === 'Auto' || this.floatLabelType === 'Never' || this.placeholder)) {\n this.updateInputValue(this.maskedDateValue);\n this.inputElement.selectionStart = 0;\n this.inputElement.selectionEnd = this.inputElement.value.length;\n }\n }\n this.trigger('focus', focusArguments);\n this.clearIconState();\n if (this.openOnFocus) {\n this.show();\n }\n };\n /**\n * Focused the TimePicker textbox element.\n *\n * @returns {void}\n */\n TimePicker.prototype.focusIn = function () {\n if (document.activeElement !== this.inputElement && this.enabled) {\n this.inputElement.focus();\n }\n };\n /**\n * Hides the TimePicker popup.\n *\n * @returns {void}\n\n */\n TimePicker.prototype.hide = function () {\n this.closePopup(100, null);\n this.clearIconState();\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-param */\n /**\n * Opens the popup to show the list items.\n *\n * @returns {void}\n\n */\n TimePicker.prototype.show = function (event) {\n var _this = this;\n if ((this.enabled && this.readonly) || !this.enabled || this.popupWrapper) {\n return;\n }\n else {\n this.popupCreation();\n if (Browser.isDevice && this.listWrapper) {\n this.modal = this.createElement('div');\n this.modal.className = '' + ROOT + ' e-time-modal';\n document.body.className += ' ' + OVERFLOW;\n document.body.appendChild(this.modal);\n }\n if (Browser.isDevice) {\n this.mobileTimePopupWrap = this.createElement('div', { className: 'e-timepicker-mob-popup-wrap' });\n document.body.appendChild(this.mobileTimePopupWrap);\n }\n this.openPopupEventArgs = {\n popup: this.popupObj || null,\n cancel: false,\n event: event || null,\n name: 'open',\n appendTo: Browser.isDevice ? this.mobileTimePopupWrap : document.body\n };\n var eventArgs = this.openPopupEventArgs;\n this.trigger('open', eventArgs, function (eventArgs) {\n _this.openPopupEventArgs = eventArgs;\n if (!_this.openPopupEventArgs.cancel && !_this.inputWrapper.buttons[0].classList.contains(DISABLED)) {\n _this.openPopupEventArgs.appendTo.appendChild(_this.popupWrapper);\n _this.popupAlignment(_this.openPopupEventArgs);\n _this.setScrollPosition();\n if (!Browser.isDevice) {\n _this.inputElement.focus();\n }\n var openAnimation = {\n name: 'FadeIn',\n duration: ANIMATIONDURATION\n };\n _this.popupObj.refreshPosition(_this.anchor);\n if (_this.zIndex === 1000) {\n _this.popupObj.show(new Animation(openAnimation), _this.element);\n }\n else {\n _this.popupObj.show(new Animation(openAnimation), null);\n }\n _this.setActiveDescendant();\n attributes(_this.inputElement, { 'aria-expanded': 'true' });\n attributes(_this.inputElement, { 'aria-owns': _this.inputElement.id + '_options' });\n attributes(_this.inputElement, { 'aria-controls': _this.inputElement.id });\n addClass([_this.inputWrapper.container], FOCUS);\n EventHandler.add(document, 'mousedown touchstart', _this.documentClickHandler, _this);\n _this.setOverlayIndex(_this.mobileTimePopupWrap, _this.popupObj.element, _this.modal, Browser.isDevice);\n }\n else {\n _this.popupObj.destroy();\n _this.popupWrapper = _this.listTag = undefined;\n _this.liCollections = _this.timeCollections = _this.disableItemCollection = [];\n _this.popupObj = null;\n }\n });\n if (Browser.isDevice) {\n var dlgOverlay = this.createElement('div', { className: 'e-dlg-overlay' });\n dlgOverlay.style.zIndex = (this.zIndex - 1).toString();\n this.mobileTimePopupWrap.appendChild(dlgOverlay);\n }\n }\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-param */\n TimePicker.prototype.setOverlayIndex = function (popupWrapper, timePopupElement, modal, isDevice) {\n if (isDevice && !isNullOrUndefined(timePopupElement) && !isNullOrUndefined(modal) && !isNullOrUndefined(popupWrapper)) {\n var index = parseInt(timePopupElement.style.zIndex, 10) ? parseInt(timePopupElement.style.zIndex, 10) : 1000;\n modal.style.zIndex = (index - 1).toString();\n popupWrapper.style.zIndex = index.toString();\n }\n };\n TimePicker.prototype.formatValues = function (type) {\n var value;\n if (typeof type === 'number') {\n value = formatUnit(type);\n }\n else if (typeof type === 'string') {\n value = (type.match(/px|%|em/)) ? type : isNaN(parseInt(type, 10)) ? type : formatUnit(type);\n }\n return value;\n };\n TimePicker.prototype.popupAlignment = function (args) {\n args.popup.position.X = this.formatValues(args.popup.position.X);\n args.popup.position.Y = this.formatValues(args.popup.position.Y);\n if (!isNaN(parseFloat(args.popup.position.X)) || !isNaN(parseFloat(args.popup.position.Y))) {\n this.popupObj.relateTo = this.anchor = document.body;\n this.popupObj.targetType = 'container';\n }\n if (!isNaN(parseFloat(args.popup.position.X))) {\n this.popupObj.offsetX = parseFloat(args.popup.position.X);\n }\n if (!isNaN(parseFloat(args.popup.position.Y))) {\n this.popupObj.offsetY = parseFloat(args.popup.position.Y);\n }\n if (!Browser.isDevice) {\n switch (args.popup.position.X) {\n case 'left':\n break;\n case 'right':\n args.popup.offsetX = this.containerStyle.width;\n break;\n case 'center':\n args.popup.offsetX = -(this.containerStyle.width / 2);\n break;\n }\n switch (args.popup.position.Y) {\n case 'top':\n break;\n case 'bottom':\n break;\n case 'center':\n args.popup.offsetY = -(this.containerStyle.height / 2);\n break;\n }\n if (args.popup.position.X === 'center' && args.popup.position.Y === 'center') {\n this.popupObj.relateTo = this.inputWrapper.container;\n this.anchor = this.inputElement;\n this.popupObj.targetType = 'relative';\n }\n }\n else {\n if (args.popup.position.X === 'center' && args.popup.position.Y === 'center') {\n this.popupObj.relateTo = this.anchor = document.body;\n this.popupObj.offsetY = 0;\n this.popupObj.targetType = 'container';\n this.popupObj.collision = { X: 'fit', Y: 'fit' };\n }\n }\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets the properties to be maintained upon browser refresh.\n *\n * @returns {string}\n */\n TimePicker.prototype.getPersistData = function () {\n var keyEntity = ['value'];\n return this.addOnPersist(keyEntity);\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * To get component name\n *\n * @returns {string} Returns the component name.\n * @private\n */\n TimePicker.prototype.getModuleName = function () {\n return 'timepicker';\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @param {TimePickerModel} newProp - Returns the dynamic property value of the component.\n * @param {TimePickerModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n * @private\n */\n TimePicker.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'placeholder':\n Input.setPlaceholder(newProp.placeholder, this.inputElement);\n break;\n case 'readonly':\n Input.setReadonly(this.readonly, this.inputElement, this.floatLabelType);\n if (this.readonly) {\n this.hide();\n }\n this.setTimeAllowEdit();\n break;\n case 'enabled':\n this.setProperties({ enabled: newProp.enabled }, true);\n this.setEnable();\n break;\n case 'allowEdit':\n this.setTimeAllowEdit();\n break;\n case 'enableRtl':\n this.setProperties({ enableRtl: newProp.enableRtl }, true);\n this.setEnableRtl();\n break;\n case 'cssClass':\n this.updateCssClass(newProp.cssClass, oldProp.cssClass);\n break;\n case 'zIndex':\n this.setProperties({ zIndex: newProp.zIndex }, true);\n this.setZIndex();\n break;\n case 'htmlAttributes':\n this.updateHtmlAttributeToElement();\n this.updateHtmlAttributeToWrapper();\n this.checkAttributes(true);\n break;\n case 'min':\n case 'max':\n this.getProperty(newProp, prop);\n break;\n case 'showClearButton':\n Input.setClearButton(this.showClearButton, this.inputElement, this.inputWrapper);\n this.bindClearEvent();\n break;\n case 'locale':\n this.setProperties({ locale: newProp.locale }, true);\n this.globalize = new Internationalization(this.locale);\n this.l10n.setLocale(this.locale);\n if (this.timeOptions && this.timeOptions.placeholder == null) {\n this.updatePlaceHolder();\n }\n this.setValue(this.value);\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n break;\n case 'width':\n setStyleAttribute(this.inputWrapper.container, { 'width': this.setWidth(newProp.width) });\n this.containerStyle = this.inputWrapper.container.getBoundingClientRect();\n Input.calculateWidth(this.inputElement, this.inputWrapper.container);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-icon');\n }\n break;\n case 'format':\n this.setProperties({ format: newProp.format }, true);\n this.checkTimeFormat();\n this.setValue(this.value);\n if (this.enableMask) {\n this.createMask();\n if (!this.value) {\n this.updateInputValue(this.maskedDateValue);\n }\n }\n break;\n case 'value':\n this.invalidValueString = null;\n this.checkInvalidValue(newProp.value);\n newProp.value = this.value;\n if (!this.invalidValueString) {\n if (typeof newProp.value === 'string') {\n this.setProperties({ value: this.checkDateValue(new Date(newProp.value)) }, true);\n newProp.value = this.value;\n }\n else {\n if ((newProp.value && +new Date(+newProp.value).setMilliseconds(0)) !== +this.value) {\n newProp.value = this.checkDateValue(new Date('' + newProp.value));\n }\n }\n this.initValue = newProp.value;\n newProp.value = this.compareFormatChange(this.checkValue(newProp.value));\n }\n else {\n this.updateInputValue(this.invalidValueString);\n this.checkErrorState(this.invalidValueString);\n }\n if (this.enableMask && isNullOrUndefined(newProp.value)) {\n this.updateInputValue(this.maskedDateValue);\n this.checkErrorState(this.maskedDateValue);\n }\n this.checkValueChange(null, false);\n if (this.isPopupOpen()) {\n this.setScrollPosition();\n }\n if (this.isAngular && this.preventChange) {\n this.preventChange = false;\n }\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n break;\n case 'floatLabelType':\n this.floatLabelType = newProp.floatLabelType;\n Input.removeFloating(this.inputWrapper);\n Input.addFloating(this.inputElement, this.floatLabelType, this.placeholder);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-icon');\n }\n break;\n case 'strictMode':\n this.invalidValueString = null;\n if (newProp.strictMode) {\n this.checkErrorState(null);\n }\n this.setProperties({ strictMode: newProp.strictMode }, true);\n this.checkValue((this.inputElement).value);\n this.checkValueChange(null, false);\n break;\n case 'scrollTo':\n if (this.checkDateValue(new Date(this.checkInValue(newProp.scrollTo)))) {\n if (this.popupWrapper) {\n this.setScrollTo();\n }\n this.setProperties({ scrollTo: this.checkDateValue(new Date(this.checkInValue(newProp.scrollTo))) }, true);\n }\n else {\n this.setProperties({ scrollTo: null }, true);\n }\n break;\n case 'enableMask':\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n this.updateInputValue(this.maskedDateValue);\n }\n else {\n if (this.inputElement.value === this.maskedDateValue) {\n this.updateInputValue('');\n }\n }\n break;\n }\n }\n };\n TimePicker.prototype.checkInValue = function (inValue) {\n if (inValue instanceof Date) {\n return (inValue.toUTCString());\n }\n else {\n return ('' + inValue);\n }\n };\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"width\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"cssClass\", void 0);\n __decorate([\n Property(false)\n ], TimePicker.prototype, \"strictMode\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"keyConfigs\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"format\", void 0);\n __decorate([\n Property(true)\n ], TimePicker.prototype, \"enabled\", void 0);\n __decorate([\n Property(false)\n ], TimePicker.prototype, \"fullScreenMode\", void 0);\n __decorate([\n Property(false)\n ], TimePicker.prototype, \"readonly\", void 0);\n __decorate([\n Property({})\n ], TimePicker.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property('Never')\n ], TimePicker.prototype, \"floatLabelType\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"placeholder\", void 0);\n __decorate([\n Property(1000)\n ], TimePicker.prototype, \"zIndex\", void 0);\n __decorate([\n Property(false)\n ], TimePicker.prototype, \"enablePersistence\", void 0);\n __decorate([\n Property(true)\n ], TimePicker.prototype, \"showClearButton\", void 0);\n __decorate([\n Property(30)\n ], TimePicker.prototype, \"step\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"scrollTo\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"value\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"min\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"max\", void 0);\n __decorate([\n Property(true)\n ], TimePicker.prototype, \"allowEdit\", void 0);\n __decorate([\n Property(false)\n ], TimePicker.prototype, \"openOnFocus\", void 0);\n __decorate([\n Property(false)\n ], TimePicker.prototype, \"enableMask\", void 0);\n __decorate([\n Property({ day: 'day', month: 'month', year: 'year', hour: 'hour', minute: 'minute', second: 'second', dayOfTheWeek: 'day of the week' })\n ], TimePicker.prototype, \"maskPlaceholder\", void 0);\n __decorate([\n Property(null)\n ], TimePicker.prototype, \"serverTimezoneOffset\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"change\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"destroyed\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"open\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"itemRender\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"close\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"cleared\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"blur\", void 0);\n __decorate([\n Event()\n ], TimePicker.prototype, \"focus\", void 0);\n TimePicker = __decorate([\n NotifyPropertyChanges\n ], TimePicker);\n return TimePicker;\n}(Component));\nexport { TimePicker };\n/* eslint-enable @typescript-eslint/no-explicit-any */\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n// eslint-disable-next-line @typescript-eslint/triple-slash-reference\n///<reference path='../datepicker/datepicker-model.d.ts'/>\nimport { EventHandler, Internationalization, Property, NotifyPropertyChanges, Browser } from '@syncfusion/ej2-base';\nimport { Animation, Event, cldrData, getDefaultDateObject, detach } from '@syncfusion/ej2-base';\nimport { createElement, remove, addClass, L10n, removeClass, closest, append, attributes } from '@syncfusion/ej2-base';\nimport { KeyboardEvents, isNullOrUndefined, formatUnit, getValue, rippleEffect } from '@syncfusion/ej2-base';\nimport { extend } from '@syncfusion/ej2-base';\nimport { Popup } from '@syncfusion/ej2-popups';\nimport { Input } from '@syncfusion/ej2-inputs';\nimport { DatePicker } from '../datepicker/datepicker';\nimport { TimePickerBase } from '../timepicker/timepicker';\n//class constant defination\nvar DATEWRAPPER = 'e-date-wrapper';\nvar DATEPICKERROOT = 'e-datepicker';\nvar DATETIMEWRAPPER = 'e-datetime-wrapper';\nvar DAY = new Date().getDate();\nvar MONTH = new Date().getMonth();\nvar YEAR = new Date().getFullYear();\nvar HOUR = new Date().getHours();\nvar MINUTE = new Date().getMinutes();\nvar SECOND = new Date().getSeconds();\nvar MILLISECOND = new Date().getMilliseconds();\nvar ROOT = 'e-datetimepicker';\nvar DATETIMEPOPUPWRAPPER = 'e-datetimepopup-wrapper';\nvar INPUTWRAPPER = 'e-input-group-icon';\nvar POPUP = 'e-popup';\nvar TIMEICON = 'e-time-icon';\nvar INPUTFOCUS = 'e-input-focus';\nvar POPUPDIMENSION = '250px';\nvar ICONANIMATION = 'e-icon-anim';\nvar DISABLED = 'e-disabled';\nvar ERROR = 'e-error';\nvar CONTENT = 'e-content';\nvar NAVIGATION = 'e-navigation';\nvar ACTIVE = 'e-active';\nvar HOVER = 'e-hover';\nvar ICONS = 'e-icons';\nvar HALFPOSITION = 2;\nvar LISTCLASS = 'e-list-item';\nvar ANIMATIONDURATION = 100;\nvar OVERFLOW = 'e-time-overflow';\n/**\n * Represents the DateTimePicker component that allows user to select\n * or enter a date time value.\n * ```html\n * <input id=\"dateTimePicker\"/>\n * ```\n * ```typescript\n * <script>\n * let dateTimePickerObject:DateTimePicker = new DateTimePicker({ value: new Date() });\n * dateTimePickerObject.appendTo(\"#dateTimePicker\");\n * </script>\n * ```\n */\nvar DateTimePicker = /** @class */ (function (_super) {\n __extends(DateTimePicker, _super);\n /**\n * Constructor for creating the widget\n *\n * @param {DateTimePickerModel} options - Specifies the DateTimePicker model.\n * @param {string | HTMLInputElement} element - Specifies the element to render as component.\n * @private\n */\n function DateTimePicker(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.valueWithMinutes = null;\n _this.scrollInvoked = false;\n _this.moduleName = _this.getModuleName();\n _this.formatRegex = /dddd|ddd|dd|d|MMMM|MMM|MM|M|yyyy|yyy|yy|y|'[^']*'|'[^']*'/g;\n _this.dateFormatString = '';\n _this.dateTimeOptions = options;\n return _this;\n }\n DateTimePicker.prototype.focusHandler = function () {\n if (!this.enabled) {\n return;\n }\n addClass([this.inputWrapper.container], INPUTFOCUS);\n };\n /**\n * Sets the focus to widget for interaction.\n *\n * @returns {void}\n */\n DateTimePicker.prototype.focusIn = function () {\n _super.prototype.focusIn.call(this);\n };\n /**\n * Remove the focus from widget, if the widget is in focus state.\n *\n * @returns {void}\n */\n DateTimePicker.prototype.focusOut = function () {\n if (document.activeElement === this.inputElement) {\n this.inputElement.blur();\n removeClass([this.inputWrapper.container], [INPUTFOCUS]);\n }\n };\n DateTimePicker.prototype.blurHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n // IE popup closing issue when click over the scrollbar\n if (this.isTimePopupOpen() && this.isPreventBlur) {\n this.inputElement.focus();\n return;\n }\n removeClass([this.inputWrapper.container], INPUTFOCUS);\n var blurArguments = {\n model: this\n };\n if (this.isTimePopupOpen()) {\n this.hide(e);\n }\n this.trigger('blur', blurArguments);\n };\n /**\n * To destroy the widget.\n *\n * @returns {void}\n */\n DateTimePicker.prototype.destroy = function () {\n if (this.popupObject && this.popupObject.element.classList.contains(POPUP)) {\n this.popupObject.destroy();\n detach(this.dateTimeWrapper);\n this.dateTimeWrapper = undefined;\n this.liCollections = this.timeCollections = [];\n if (!isNullOrUndefined(this.rippleFn)) {\n this.rippleFn();\n }\n }\n var ariaAttribute = {\n 'aria-live': 'assertive', 'aria-atomic': 'true', 'aria-invalid': 'false',\n 'autocorrect': 'off', 'autocapitalize': 'off', 'spellcheck': 'false',\n 'aria-expanded': 'false', 'role': 'combobox', 'autocomplete': 'off'\n };\n if (this.inputElement) {\n Input.removeAttributes(ariaAttribute, this.inputElement);\n }\n if (this.isCalendar()) {\n if (this.popupWrapper) {\n detach(this.popupWrapper);\n }\n this.popupObject = this.popupWrapper = null;\n this.keyboardHandler.destroy();\n }\n this.unBindInputEvents();\n this.liCollections = null;\n this.rippleFn = null;\n this.selectedElement = null;\n this.listTag = null;\n this.timeIcon = null;\n this.popupObject = null;\n this.preventArgs = null;\n this.keyboardModule = null;\n _super.prototype.destroy.call(this);\n };\n /**\n * To Initialize the control rendering.\n *\n * @returns {void}\n * @private\n */\n DateTimePicker.prototype.render = function () {\n this.timekeyConfigure = {\n enter: 'enter',\n escape: 'escape',\n end: 'end',\n tab: 'tab',\n home: 'home',\n down: 'downarrow',\n up: 'uparrow',\n left: 'leftarrow',\n right: 'rightarrow',\n open: 'alt+downarrow',\n close: 'alt+uparrow'\n };\n this.valueWithMinutes = null;\n this.previousDateTime = null;\n this.isPreventBlur = false;\n this.cloneElement = this.element.cloneNode(true);\n this.dateTimeFormat = this.cldrDateTimeFormat();\n this.initValue = this.value;\n if (typeof (this.min) === 'string') {\n this.min = this.checkDateValue(new Date(this.min));\n }\n if (typeof (this.max) === 'string') {\n this.max = this.checkDateValue(new Date(this.max));\n }\n if (!isNullOrUndefined(closest(this.element, 'fieldset')) && closest(this.element, 'fieldset').disabled) {\n this.enabled = false;\n }\n _super.prototype.updateHtmlAttributeToElement.call(this);\n this.checkAttributes(false);\n var localeText = { placeholder: this.placeholder };\n this.l10n = new L10n('datetimepicker', localeText, this.locale);\n this.setProperties({ placeholder: this.placeholder || this.l10n.getConstant('placeholder') }, true);\n _super.prototype.render.call(this);\n this.createInputElement();\n _super.prototype.updateHtmlAttributeToWrapper.call(this);\n this.bindInputEvents();\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n this.setValue(true);\n if (this.enableMask && !this.value && this.maskedDateValue && (this.floatLabelType === 'Always' || !this.floatLabelType || !this.placeholder)) {\n Input.setValue(this.maskedDateValue, this.inputElement, this.floatLabelType, this.showClearButton);\n }\n this.setProperties({ scrollTo: this.checkDateValue(new Date(this.checkValue(this.scrollTo))) }, true);\n this.previousDateTime = this.value && new Date(+this.value);\n if (this.element.tagName === 'EJS-DATETIMEPICKER') {\n this.tabIndex = this.element.hasAttribute('tabindex') ? this.element.getAttribute('tabindex') : '0';\n this.element.removeAttribute('tabindex');\n if (!this.enabled) {\n this.inputElement.tabIndex = -1;\n }\n }\n if (this.floatLabelType === 'Auto') {\n Input.calculateWidth(this.inputElement, this.inputWrapper.container);\n }\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-date-time-icon');\n }\n this.renderComplete();\n };\n DateTimePicker.prototype.setValue = function (isDynamic) {\n if (isDynamic === void 0) { isDynamic = false; }\n this.initValue = this.validateMinMaxRange(this.value);\n if (!this.strictMode && this.isDateObject(this.initValue)) {\n var value = this.validateMinMaxRange(this.initValue);\n Input.setValue(this.getFormattedValue(value), this.inputElement, this.floatLabelType, this.showClearButton);\n this.setProperties({ value: value }, true);\n }\n else {\n if (isNullOrUndefined(this.value)) {\n this.initValue = null;\n this.setProperties({ value: null }, true);\n }\n }\n this.valueWithMinutes = this.value;\n _super.prototype.updateInput.call(this, isDynamic);\n };\n DateTimePicker.prototype.validateMinMaxRange = function (value) {\n var result = value;\n if (this.isDateObject(value)) {\n result = this.validateValue(value);\n }\n else {\n if (+this.min > +this.max) {\n this.disablePopupButton(true);\n }\n }\n this.checkValidState(result);\n return result;\n };\n DateTimePicker.prototype.checkValidState = function (value) {\n this.isValidState = true;\n if (!this.strictMode) {\n if ((+(value) > +(this.max)) || (+(value) < +(this.min))) {\n this.isValidState = false;\n }\n }\n this.checkErrorState();\n };\n DateTimePicker.prototype.checkErrorState = function () {\n if (this.isValidState) {\n removeClass([this.inputWrapper.container], ERROR);\n }\n else {\n addClass([this.inputWrapper.container], ERROR);\n }\n attributes(this.inputElement, { 'aria-invalid': this.isValidState ? 'false' : 'true' });\n };\n DateTimePicker.prototype.validateValue = function (value) {\n var dateVal = value;\n if (this.strictMode) {\n if (+this.min > +this.max) {\n this.disablePopupButton(true);\n dateVal = this.max;\n }\n else if (+value < +this.min) {\n dateVal = this.min;\n }\n else if (+value > +this.max) {\n dateVal = this.max;\n }\n }\n else {\n if (+this.min > +this.max) {\n this.disablePopupButton(true);\n dateVal = value;\n }\n }\n return dateVal;\n };\n DateTimePicker.prototype.disablePopupButton = function (isDisable) {\n if (isDisable) {\n addClass([this.inputWrapper.buttons[0], this.timeIcon], DISABLED);\n this.hide();\n }\n else {\n removeClass([this.inputWrapper.buttons[0], this.timeIcon], DISABLED);\n }\n };\n DateTimePicker.prototype.getFormattedValue = function (value) {\n var dateOptions;\n if (!isNullOrUndefined(value)) {\n if (this.calendarMode === 'Gregorian') {\n dateOptions = { format: this.cldrDateTimeFormat(), type: 'dateTime', skeleton: 'yMd' };\n }\n else {\n dateOptions = { format: this.cldrDateTimeFormat(), type: 'dateTime', skeleton: 'yMd', calendar: 'islamic' };\n }\n return this.globalize.formatDate(value, dateOptions);\n }\n else {\n return null;\n }\n };\n DateTimePicker.prototype.isDateObject = function (value) {\n return (!isNullOrUndefined(value) && !isNaN(+value)) ? true : false;\n };\n DateTimePicker.prototype.createInputElement = function () {\n removeClass([this.inputElement], DATEPICKERROOT);\n removeClass([this.inputWrapper.container], DATEWRAPPER);\n addClass([this.inputWrapper.container], DATETIMEWRAPPER);\n addClass([this.inputElement], ROOT);\n this.renderTimeIcon();\n };\n DateTimePicker.prototype.renderTimeIcon = function () {\n this.timeIcon = Input.appendSpan(INPUTWRAPPER + ' ' + TIMEICON + ' ' + ICONS, this.inputWrapper.container);\n };\n DateTimePicker.prototype.bindInputEvents = function () {\n EventHandler.add(this.timeIcon, 'mousedown', this.timeHandler, this);\n EventHandler.add(this.inputWrapper.buttons[0], 'mousedown', this.dateHandler, this);\n EventHandler.add(this.inputElement, 'blur', this.blurHandler, this);\n EventHandler.add(this.inputElement, 'focus', this.focusHandler, this);\n this.defaultKeyConfigs = extend(this.defaultKeyConfigs, this.keyConfigs);\n this.keyboardHandler = new KeyboardEvents(this.inputElement, {\n eventName: 'keydown',\n keyAction: this.inputKeyAction.bind(this),\n keyConfigs: this.defaultKeyConfigs\n });\n };\n DateTimePicker.prototype.unBindInputEvents = function () {\n EventHandler.remove(this.timeIcon, 'mousedown touchstart', this.timeHandler);\n EventHandler.remove(this.inputWrapper.buttons[0], 'mousedown touchstart', this.dateHandler);\n if (this.inputElement) {\n EventHandler.remove(this.inputElement, 'blur', this.blurHandler);\n EventHandler.remove(this.inputElement, 'focus', this.focusHandler);\n }\n if (this.keyboardHandler) {\n this.keyboardHandler.destroy();\n }\n };\n DateTimePicker.prototype.cldrTimeFormat = function () {\n var cldrTime;\n if (this.isNullOrEmpty(this.timeFormat)) {\n if (this.locale === 'en' || this.locale === 'en-US') {\n cldrTime = (getValue('timeFormats.short', getDefaultDateObject()));\n }\n else {\n cldrTime = (this.getCultureTimeObject(cldrData, '' + this.locale));\n }\n }\n else {\n cldrTime = this.timeFormat;\n }\n return cldrTime;\n };\n DateTimePicker.prototype.cldrDateTimeFormat = function () {\n var cldrTime;\n var culture = new Internationalization(this.locale);\n var dateFormat = culture.getDatePattern({ skeleton: 'yMd' });\n if (this.isNullOrEmpty(this.formatString)) {\n cldrTime = dateFormat + ' ' + this.getCldrFormat('time');\n }\n else {\n cldrTime = this.formatString;\n }\n return cldrTime;\n };\n DateTimePicker.prototype.getCldrFormat = function (type) {\n var cldrDateTime;\n if (this.locale === 'en' || this.locale === 'en-US') {\n cldrDateTime = (getValue('timeFormats.short', getDefaultDateObject()));\n }\n else {\n cldrDateTime = (this.getCultureTimeObject(cldrData, '' + this.locale));\n }\n return cldrDateTime;\n };\n DateTimePicker.prototype.isNullOrEmpty = function (value) {\n if (isNullOrUndefined(value) || (typeof value === 'string' && value.trim() === '')) {\n return true;\n }\n else {\n return false;\n }\n };\n DateTimePicker.prototype.getCultureTimeObject = function (ld, c) {\n if (this.calendarMode === 'Gregorian') {\n return getValue('main.' + '' + this.locale + '.dates.calendars.gregorian.timeFormats.short', ld);\n }\n else {\n return getValue('main.' + '' + this.locale + '.dates.calendars.islamic.timeFormats.short', ld);\n }\n };\n DateTimePicker.prototype.timeHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n this.isIconClicked = true;\n if (Browser.isDevice) {\n this.inputElement.setAttribute('readonly', '');\n }\n if (e.currentTarget === this.timeIcon) {\n e.preventDefault();\n }\n if (this.enabled && !this.readonly) {\n if (this.isDatePopupOpen()) {\n _super.prototype.hide.call(this, e);\n }\n if (this.isTimePopupOpen()) {\n this.closePopup(e);\n }\n else {\n this.inputElement.focus();\n this.popupCreation('time', e);\n addClass([this.inputWrapper.container], [INPUTFOCUS]);\n }\n }\n this.isIconClicked = false;\n };\n DateTimePicker.prototype.dateHandler = function (e) {\n if (!this.enabled) {\n return;\n }\n if (e.currentTarget === this.inputWrapper.buttons[0]) {\n e.preventDefault();\n }\n if (this.enabled && !this.readonly) {\n if (this.isTimePopupOpen()) {\n this.closePopup(e);\n }\n if (!isNullOrUndefined(this.popupWrapper)) {\n this.popupCreation('date', e);\n }\n }\n };\n DateTimePicker.prototype.show = function (type, e) {\n if ((this.enabled && this.readonly) || !this.enabled) {\n return;\n }\n else {\n if (type === 'time' && !this.dateTimeWrapper) {\n if (this.isDatePopupOpen()) {\n this.hide(e);\n }\n this.popupCreation('time', e);\n }\n else if (!this.popupObj) {\n if (this.isTimePopupOpen()) {\n this.hide(e);\n }\n _super.prototype.show.call(this);\n this.popupCreation('date', e);\n }\n }\n };\n DateTimePicker.prototype.toggle = function (e) {\n if (this.isDatePopupOpen()) {\n _super.prototype.hide.call(this, e);\n this.show('time', null);\n }\n else if (this.isTimePopupOpen()) {\n this.hide(e);\n _super.prototype.show.call(this, null, e);\n this.popupCreation('date', null);\n }\n else {\n this.show(null, e);\n }\n };\n DateTimePicker.prototype.listCreation = function () {\n var dateObject;\n if (this.calendarMode === 'Gregorian') {\n this.cldrDateTimeFormat().replace(this.formatRegex, this.TimePopupFormat());\n dateObject = this.globalize.parseDate(this.inputElement.value, {\n format: this.dateFormatString, type: 'datetime'\n });\n }\n else {\n dateObject = this.globalize.parseDate(this.inputElement.value, {\n format: this.cldrDateTimeFormat(), type: 'datetime', calendar: 'islamic'\n });\n }\n var value = isNullOrUndefined(this.value) ? this.inputElement.value !== '' ?\n dateObject : new Date() : this.value;\n this.valueWithMinutes = value;\n this.listWrapper = createElement('div', { className: CONTENT, attrs: { 'tabindex': '0' } });\n var min = this.startTime(value);\n var max = this.endTime(value);\n var listDetails = TimePickerBase.createListItems(this.createElement, min, max, this.globalize, this.cldrTimeFormat(), this.step);\n this.timeCollections = listDetails.collection;\n this.listTag = listDetails.list;\n attributes(this.listTag, { 'role': 'listbox', 'aria-hidden': 'false', 'id': this.element.id + '_options' });\n append([listDetails.list], this.listWrapper);\n this.wireTimeListEvents();\n var rippleModel = { duration: 300, selector: '.' + LISTCLASS };\n this.rippleFn = rippleEffect(this.listWrapper, rippleModel);\n this.liCollections = this.listWrapper.querySelectorAll('.' + LISTCLASS);\n };\n DateTimePicker.prototype.popupCreation = function (type, e) {\n if (Browser.isDevice) {\n this.element.setAttribute('readonly', 'readonly');\n }\n if (type === 'date') {\n if (!this.readonly && this.popupWrapper) {\n addClass([this.popupWrapper], DATETIMEPOPUPWRAPPER);\n attributes(this.popupWrapper, { 'id': this.element.id + '_options' });\n }\n }\n else {\n if (!this.readonly) {\n this.dateTimeWrapper = createElement('div', {\n className: ROOT + ' ' + POPUP,\n attrs: { 'id': this.element.id + '_timepopup', 'style': 'visibility:hidden ; display:block' }\n });\n if (!isNullOrUndefined(this.cssClass)) {\n this.dateTimeWrapper.className += ' ' + this.cssClass;\n }\n if (!isNullOrUndefined(this.step) && this.step > 0) {\n this.listCreation();\n append([this.listWrapper], this.dateTimeWrapper);\n }\n document.body.appendChild(this.dateTimeWrapper);\n this.addTimeSelection();\n this.renderPopup();\n this.setTimeScrollPosition();\n this.openPopup(e);\n if (!Browser.isDevice || (Browser.isDevice && !this.fullScreenMode)) {\n this.popupObject.refreshPosition(this.inputElement);\n }\n if (Browser.isDevice && this.fullScreenMode) {\n this.dateTimeWrapper.style.left = '0px';\n }\n if (Browser.isDevice) {\n var dlgOverlay = this.createElement('div', { className: 'e-dlg-overlay' });\n dlgOverlay.style.zIndex = (this.zIndex - 1).toString();\n this.timeModal.appendChild(dlgOverlay);\n }\n }\n }\n };\n DateTimePicker.prototype.openPopup = function (e) {\n var _this = this;\n this.preventArgs = {\n cancel: false,\n popup: this.popupObject,\n event: e || null\n };\n var eventArgs = this.preventArgs;\n this.trigger('open', eventArgs, function (eventArgs) {\n _this.preventArgs = eventArgs;\n if (!_this.preventArgs.cancel && !_this.readonly) {\n var openAnimation = {\n name: 'FadeIn',\n duration: ANIMATIONDURATION,\n };\n if (_this.zIndex === 1000) {\n _this.popupObject.show(new Animation(openAnimation), _this.element);\n }\n else {\n _this.popupObject.show(new Animation(openAnimation), null);\n }\n addClass([_this.inputWrapper.container], [ICONANIMATION]);\n attributes(_this.inputElement, { 'aria-expanded': 'true' });\n attributes(_this.inputElement, { 'aria-owns': _this.inputElement.id + '_options' });\n attributes(_this.inputElement, { 'aria-controls': _this.inputElement.id });\n EventHandler.add(document, 'mousedown touchstart', _this.documentClickHandler, _this);\n }\n });\n };\n DateTimePicker.prototype.documentClickHandler = function (event) {\n var target = event.target;\n if ((!isNullOrUndefined(this.popupObject) && (this.inputWrapper.container.contains(target) && event.type !== 'mousedown' ||\n (this.popupObject.element && this.popupObject.element.contains(target)))) && event.type !== 'touchstart') {\n event.preventDefault();\n }\n if (!(closest(target, '[id=\"' + (this.popupObject && this.popupObject.element.id + '\"]'))) && target !== this.inputElement\n && target !== this.timeIcon && !isNullOrUndefined(this.inputWrapper) && target !== this.inputWrapper.container && !target.classList.contains('e-dlg-overlay')) {\n if (this.isTimePopupOpen()) {\n this.hide(event);\n this.focusOut();\n }\n }\n else if (target !== this.inputElement) {\n if (!Browser.isDevice) {\n this.isPreventBlur = ((document.activeElement === this.inputElement) && (Browser.isIE || Browser.info.name === 'edge')\n && target === this.popupObject.element);\n }\n }\n };\n DateTimePicker.prototype.isTimePopupOpen = function () {\n return (this.dateTimeWrapper && this.dateTimeWrapper.classList.contains('' + ROOT)) ? true : false;\n };\n DateTimePicker.prototype.isDatePopupOpen = function () {\n return (this.popupWrapper && this.popupWrapper.classList.contains('' + DATETIMEPOPUPWRAPPER)) ? true : false;\n };\n DateTimePicker.prototype.renderPopup = function () {\n var _this = this;\n this.containerStyle = this.inputWrapper.container.getBoundingClientRect();\n if (Browser.isDevice) {\n this.timeModal = createElement('div');\n this.timeModal.className = '' + ROOT + ' e-time-modal';\n document.body.className += ' ' + OVERFLOW;\n this.timeModal.style.display = 'block';\n document.body.appendChild(this.timeModal);\n }\n var offset = 4;\n this.popupObject = new Popup(this.dateTimeWrapper, {\n width: this.setPopupWidth(),\n zIndex: this.zIndex,\n targetType: 'container',\n collision: Browser.isDevice ? { X: 'fit', Y: 'fit' } : { X: 'flip', Y: 'flip' },\n relateTo: Browser.isDevice ? document.body : this.inputWrapper.container,\n position: Browser.isDevice ? { X: 'center', Y: 'center' } : { X: 'left', Y: 'bottom' },\n enableRtl: this.enableRtl,\n offsetY: offset,\n open: function () {\n _this.dateTimeWrapper.style.visibility = 'visible';\n addClass([_this.timeIcon], ACTIVE);\n if (!Browser.isDevice) {\n _this.timekeyConfigure = extend(_this.timekeyConfigure, _this.keyConfigs);\n _this.inputEvent = new KeyboardEvents(_this.inputWrapper.container, {\n keyAction: _this.timeKeyActionHandle.bind(_this),\n keyConfigs: _this.timekeyConfigure,\n eventName: 'keydown'\n });\n }\n }, close: function () {\n removeClass([_this.timeIcon], ACTIVE);\n _this.unWireTimeListEvents();\n _this.inputElement.removeAttribute('aria-activedescendant');\n remove(_this.popupObject.element);\n _this.popupObject.destroy();\n _this.dateTimeWrapper.innerHTML = '';\n _this.listWrapper = _this.dateTimeWrapper = undefined;\n if (_this.inputEvent) {\n _this.inputEvent.destroy();\n }\n }, targetExitViewport: function () {\n if (!Browser.isDevice) {\n _this.hide();\n }\n }\n });\n if (Browser.isDevice && this.fullScreenMode) {\n this.popupObject.element.style.display = \"flex\";\n this.popupObject.element.style.maxHeight = \"100%\";\n this.popupObject.element.style.width = \"100%\";\n }\n else {\n this.popupObject.element.style.maxHeight = POPUPDIMENSION;\n }\n if (Browser.isDevice && this.fullScreenMode) {\n var modelWrapper = createElement('div', { className: 'e-datetime-mob-popup-wrap' });\n var modelHeader = this.createElement('div', { className: 'e-model-header' });\n var modelTitleSpan = this.createElement(\"span\", { className: \"e-model-title\" });\n modelTitleSpan.textContent = \"Select time\";\n var modelCloseIcon = this.createElement(\"span\", { className: \"e-popup-close\" });\n EventHandler.add(modelCloseIcon, 'mousedown touchstart', this.dateTimeCloseHandler, this);\n var timeContent = this.dateTimeWrapper.querySelector(\".e-content\");\n modelHeader.appendChild(modelCloseIcon);\n modelHeader.appendChild(modelTitleSpan);\n modelWrapper.appendChild(modelHeader);\n modelWrapper.appendChild(timeContent);\n this.dateTimeWrapper.insertBefore(modelWrapper, this.dateTimeWrapper.firstElementChild);\n }\n };\n DateTimePicker.prototype.dateTimeCloseHandler = function (e) {\n this.hide();\n };\n DateTimePicker.prototype.setDimension = function (width) {\n if (typeof width === 'number') {\n width = formatUnit(width);\n }\n else if (typeof width === 'string') {\n // eslint-disable-next-line no-self-assign\n width = width;\n }\n else {\n width = '100%';\n }\n return width;\n };\n DateTimePicker.prototype.setPopupWidth = function () {\n var width = this.setDimension(this.width);\n if (width.indexOf('%') > -1) {\n var inputWidth = this.containerStyle.width * parseFloat(width) / 100;\n width = inputWidth.toString() + 'px';\n }\n return width;\n };\n DateTimePicker.prototype.wireTimeListEvents = function () {\n EventHandler.add(this.listWrapper, 'click', this.onMouseClick, this);\n if (!Browser.isDevice) {\n EventHandler.add(this.listWrapper, 'mouseover', this.onMouseOver, this);\n EventHandler.add(this.listWrapper, 'mouseout', this.onMouseLeave, this);\n }\n };\n DateTimePicker.prototype.unWireTimeListEvents = function () {\n if (this.listWrapper) {\n EventHandler.remove(this.listWrapper, 'click', this.onMouseClick);\n EventHandler.remove(document, 'mousedown touchstart', this.documentClickHandler);\n if (!Browser.isDevice) {\n EventHandler.add(this.listWrapper, 'mouseover', this.onMouseOver, this);\n EventHandler.add(this.listWrapper, 'mouseout', this.onMouseLeave, this);\n }\n }\n };\n DateTimePicker.prototype.onMouseOver = function (event) {\n var currentLi = closest(event.target, '.' + LISTCLASS);\n this.setTimeHover(currentLi, HOVER);\n };\n DateTimePicker.prototype.onMouseLeave = function () {\n this.removeTimeHover(HOVER);\n };\n DateTimePicker.prototype.setTimeHover = function (li, className) {\n if (this.enabled && this.isValidLI(li) && !li.classList.contains(className)) {\n this.removeTimeHover(className);\n addClass([li], className);\n }\n };\n DateTimePicker.prototype.getPopupHeight = function () {\n var height = parseInt(POPUPDIMENSION, 10);\n var popupHeight = this.dateTimeWrapper.getBoundingClientRect().height;\n if (Browser.isDevice && this.fullScreenMode) {\n return popupHeight;\n }\n else {\n return popupHeight > height ? height : popupHeight;\n }\n };\n DateTimePicker.prototype.changeEvent = function (e) {\n _super.prototype.changeEvent.call(this, e);\n if ((this.value && this.value.valueOf()) !== (this.previousDateTime && +this.previousDateTime.valueOf())) {\n this.valueWithMinutes = this.value;\n this.setInputValue('date');\n this.previousDateTime = this.value && new Date(+this.value);\n }\n };\n DateTimePicker.prototype.updateValue = function (e) {\n this.setInputValue('time');\n if (+this.previousDateTime !== +this.value) {\n this.changedArgs = {\n value: this.value, event: e || null,\n isInteracted: !isNullOrUndefined(e),\n element: this.element\n };\n this.addTimeSelection();\n this.trigger('change', this.changedArgs);\n this.previousDateTime = this.previousDate = this.value;\n }\n };\n DateTimePicker.prototype.setTimeScrollPosition = function () {\n var popupElement = this.selectedElement;\n if (!isNullOrUndefined(popupElement)) {\n this.findScrollTop(popupElement);\n }\n else if (this.dateTimeWrapper && this.checkDateValue(this.scrollTo)) {\n this.setScrollTo();\n }\n };\n DateTimePicker.prototype.findScrollTop = function (element) {\n var listHeight = this.getPopupHeight();\n var nextElement = element.nextElementSibling;\n var height = nextElement ? nextElement.offsetTop : element.offsetTop;\n var lineHeight = element.getBoundingClientRect().height;\n if ((height + element.offsetTop) > listHeight) {\n if (Browser.isDevice && this.fullScreenMode) {\n var listContent = this.dateTimeWrapper.querySelector('.e-content');\n listContent.scrollTop = nextElement ? (height - (listHeight / HALFPOSITION + lineHeight / HALFPOSITION)) : height;\n }\n else {\n this.dateTimeWrapper.scrollTop = nextElement ? (height - (listHeight / HALFPOSITION + lineHeight / HALFPOSITION)) : height;\n }\n }\n else {\n this.dateTimeWrapper.scrollTop = 0;\n }\n };\n DateTimePicker.prototype.setScrollTo = function () {\n var element;\n var items = this.dateTimeWrapper.querySelectorAll('.' + LISTCLASS);\n if (items.length >= 0) {\n this.scrollInvoked = true;\n var initialTime = this.timeCollections[0];\n var scrollTime = this.getDateObject(this.checkDateValue(this.scrollTo)).getTime();\n element = items[Math.round((scrollTime - initialTime) / (this.step * 60000))];\n }\n else {\n this.dateTimeWrapper.scrollTop = 0;\n }\n if (!isNullOrUndefined(element)) {\n this.findScrollTop(element);\n }\n else {\n this.dateTimeWrapper.scrollTop = 0;\n }\n };\n DateTimePicker.prototype.setInputValue = function (type) {\n if (type === 'date') {\n this.inputElement.value = this.previousElementValue = this.getFormattedValue(this.getFullDateTime());\n this.setProperties({ value: this.getFullDateTime() }, true);\n }\n else {\n var tempVal = this.getFormattedValue(new Date(this.timeCollections[this.activeIndex]));\n Input.setValue(tempVal, this.inputElement, this.floatLabelType, this.showClearButton);\n this.previousElementValue = this.inputElement.value;\n this.setProperties({ value: new Date(this.timeCollections[this.activeIndex]) }, true);\n if (this.enableMask) {\n this.createMask();\n }\n }\n this.updateIconState();\n };\n DateTimePicker.prototype.getFullDateTime = function () {\n var value = null;\n if (this.isDateObject(this.valueWithMinutes)) {\n value = this.combineDateTime(this.valueWithMinutes);\n }\n else {\n value = this.previousDate;\n }\n return this.validateMinMaxRange(value);\n };\n DateTimePicker.prototype.createMask = function () {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n };\n DateTimePicker.prototype.combineDateTime = function (value) {\n if (this.isDateObject(value)) {\n var day = this.previousDate.getDate();\n var month = this.previousDate.getMonth();\n var year = this.previousDate.getFullYear();\n var hour = value.getHours();\n var minutes = value.getMinutes();\n var seconds = value.getSeconds();\n return new Date(year, month, day, hour, minutes, seconds);\n }\n else {\n return this.previousDate;\n }\n };\n DateTimePicker.prototype.onMouseClick = function (event) {\n var target = event.target;\n var li = this.selectedElement = closest(target, '.' + LISTCLASS);\n if (li && li.classList.contains(LISTCLASS)) {\n this.timeValue = li.getAttribute('data-value');\n this.hide(event);\n }\n this.setSelection(li, event);\n };\n DateTimePicker.prototype.setSelection = function (li, event) {\n if (this.isValidLI(li) && !li.classList.contains(ACTIVE)) {\n this.selectedElement = li;\n var index = Array.prototype.slice.call(this.liCollections).indexOf(li);\n this.activeIndex = index;\n this.valueWithMinutes = new Date(this.timeCollections[this.activeIndex]);\n addClass([this.selectedElement], ACTIVE);\n this.selectedElement.setAttribute('aria-selected', 'true');\n this.updateValue(event);\n }\n };\n DateTimePicker.prototype.setTimeActiveClass = function () {\n var collections = isNullOrUndefined(this.dateTimeWrapper) ? this.listWrapper : this.dateTimeWrapper;\n if (!isNullOrUndefined(collections)) {\n var items = collections.querySelectorAll('.' + LISTCLASS);\n if (items.length) {\n for (var i = 0; i < items.length; i++) {\n if (this.timeCollections[i] === +(this.valueWithMinutes)) {\n items[i].setAttribute('aria-selected', 'true');\n this.selectedElement = items[i];\n this.activeIndex = i;\n this.setTimeActiveDescendant();\n break;\n }\n }\n }\n }\n };\n DateTimePicker.prototype.setTimeActiveDescendant = function () {\n if (!isNullOrUndefined(this.selectedElement) && this.value) {\n attributes(this.inputElement, { 'aria-activedescendant': this.selectedElement.getAttribute('id') });\n }\n else {\n this.inputElement.removeAttribute('aria-activedescendant');\n }\n };\n DateTimePicker.prototype.addTimeSelection = function () {\n this.selectedElement = null;\n this.removeTimeSelection();\n this.setTimeActiveClass();\n if (!isNullOrUndefined(this.selectedElement)) {\n addClass([this.selectedElement], ACTIVE);\n this.selectedElement.setAttribute('aria-selected', 'true');\n }\n };\n DateTimePicker.prototype.removeTimeSelection = function () {\n this.removeTimeHover(HOVER);\n if (!isNullOrUndefined(this.dateTimeWrapper)) {\n var items = this.dateTimeWrapper.querySelectorAll('.' + ACTIVE);\n if (items.length) {\n removeClass(items, ACTIVE);\n items[0].removeAttribute('aria-selected');\n }\n }\n };\n DateTimePicker.prototype.removeTimeHover = function (className) {\n var hoveredItem = this.getTimeHoverItem(className);\n if (hoveredItem && hoveredItem.length) {\n removeClass(hoveredItem, className);\n }\n };\n DateTimePicker.prototype.getTimeHoverItem = function (className) {\n var collections = isNullOrUndefined(this.dateTimeWrapper) ? this.listWrapper : this.dateTimeWrapper;\n var hoveredItem;\n if (!isNullOrUndefined(collections)) {\n hoveredItem = collections.querySelectorAll('.' + className);\n }\n return hoveredItem;\n };\n DateTimePicker.prototype.isValidLI = function (li) {\n return (li && li.classList.contains(LISTCLASS) && !li.classList.contains(DISABLED));\n };\n DateTimePicker.prototype.calculateStartEnd = function (value, range, method) {\n var day = value.getDate();\n var month = value.getMonth();\n var year = value.getFullYear();\n var hours = value.getHours();\n var minutes = value.getMinutes();\n var seconds = value.getSeconds();\n var milliseconds = value.getMilliseconds();\n if (range) {\n if (method === 'starttime') {\n return new Date(year, month, day, 0, 0, 0);\n }\n else {\n return new Date(year, month, day, 23, 59, 59);\n }\n }\n else {\n return new Date(year, month, day, hours, minutes, seconds, milliseconds);\n }\n };\n DateTimePicker.prototype.startTime = function (date) {\n var tempStartValue;\n var start;\n var tempMin = this.min;\n var value = date === null ? new Date() : date;\n if ((+value.getDate() === +tempMin.getDate() && +value.getMonth() === +tempMin.getMonth() &&\n +value.getFullYear() === +tempMin.getFullYear()) || ((+new Date(value.getFullYear(), value.getMonth(), value.getDate())) <=\n +new Date(tempMin.getFullYear(), tempMin.getMonth(), tempMin.getDate()))) {\n start = false;\n tempStartValue = this.min;\n }\n else if (+value < +this.max && +value > +this.min) {\n start = true;\n tempStartValue = value;\n }\n else if (+value >= +this.max) {\n start = true;\n tempStartValue = this.max;\n }\n return this.calculateStartEnd(tempStartValue, start, 'starttime');\n };\n DateTimePicker.prototype.TimePopupFormat = function () {\n var format = '';\n var formatCount = 0;\n var proxy = this;\n function formatValueSpecifier(formattext) {\n switch (formattext) {\n case 'd':\n case 'dd':\n case 'ddd':\n case 'dddd':\n case 'M':\n case 'MM':\n case 'MMM':\n case 'MMMM':\n case 'y':\n case 'yy':\n case 'yyy':\n case 'yyyy':\n if (format == '') {\n format = format + formattext;\n }\n else {\n format = format + \"/\" + formattext;\n }\n formatCount = formatCount + 1;\n break;\n }\n if (formatCount > 2) {\n proxy.dateFormatString = format;\n }\n return format;\n }\n return formatValueSpecifier;\n };\n DateTimePicker.prototype.endTime = function (date) {\n var tempEndValue;\n var end;\n var tempMax = this.max;\n var value = date === null ? new Date() : date;\n if ((+value.getDate() === +tempMax.getDate() && +value.getMonth() === +tempMax.getMonth() &&\n +value.getFullYear() === +tempMax.getFullYear()) || (+new Date(value.getUTCFullYear(), value.getMonth(), value.getDate()) >=\n +new Date(tempMax.getFullYear(), tempMax.getMonth(), tempMax.getDate()))) {\n end = false;\n tempEndValue = this.max;\n }\n else if (+value < +this.max && +value > +this.min) {\n end = true;\n tempEndValue = value;\n }\n else if (+value <= +this.min) {\n end = true;\n tempEndValue = this.min;\n }\n return this.calculateStartEnd(tempEndValue, end, 'endtime');\n };\n DateTimePicker.prototype.hide = function (e) {\n var _this = this;\n if (this.popupObj || this.dateTimeWrapper) {\n this.preventArgs = {\n cancel: false,\n popup: this.popupObj || this.popupObject,\n event: e || null\n };\n var eventArgs = this.preventArgs;\n if (isNullOrUndefined(this.popupObj)) {\n this.trigger('close', eventArgs, function (eventArgs) {\n _this.dateTimeCloseEventCallback(e, eventArgs);\n });\n }\n else {\n this.dateTimeCloseEventCallback(e, eventArgs);\n }\n }\n else {\n if (Browser.isDevice && this.allowEdit && !this.readonly) {\n this.inputElement.removeAttribute('readonly');\n }\n this.setAllowEdit();\n }\n };\n DateTimePicker.prototype.dateTimeCloseEventCallback = function (e, eventArgs) {\n this.preventArgs = eventArgs;\n if (!this.preventArgs.cancel) {\n if (this.isDatePopupOpen()) {\n _super.prototype.hide.call(this, e);\n }\n else if (this.isTimePopupOpen()) {\n this.closePopup(e);\n removeClass([document.body], OVERFLOW);\n if (Browser.isDevice && this.timeModal) {\n this.timeModal.style.display = 'none';\n this.timeModal.outerHTML = '';\n this.timeModal = null;\n }\n this.setTimeActiveDescendant();\n }\n }\n if (Browser.isDevice && this.allowEdit && !this.readonly) {\n this.inputElement.removeAttribute('readonly');\n }\n this.setAllowEdit();\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n DateTimePicker.prototype.closePopup = function (e) {\n if (this.isTimePopupOpen() && this.popupObject) {\n var animModel = {\n name: 'FadeOut',\n duration: ANIMATIONDURATION,\n delay: 0\n };\n this.popupObject.hide(new Animation(animModel));\n this.inputWrapper.container.classList.remove(ICONANIMATION);\n attributes(this.inputElement, { 'aria-expanded': 'false' });\n this.inputElement.removeAttribute('aria-owns');\n this.inputElement.removeAttribute('aria-controls');\n EventHandler.remove(document, 'mousedown touchstart', this.documentClickHandler);\n }\n };\n DateTimePicker.prototype.preRender = function () {\n this.checkFormat();\n this.dateTimeFormat = this.cldrDateTimeFormat();\n _super.prototype.preRender.call(this);\n removeClass([this.inputElementCopy], [ROOT]);\n };\n DateTimePicker.prototype.getProperty = function (date, val) {\n if (val === 'min') {\n this.setProperties({ min: this.validateValue(date.min) }, true);\n }\n else {\n this.setProperties({ max: this.validateValue(date.max) }, true);\n }\n };\n DateTimePicker.prototype.checkAttributes = function (isDynamic) {\n var attributes = isDynamic ? isNullOrUndefined(this.htmlAttributes) ? [] : Object.keys(this.htmlAttributes) :\n ['style', 'name', 'step', 'disabled', 'readonly', 'value', 'min', 'max', 'placeholder', 'type'];\n var value;\n for (var _i = 0, attributes_1 = attributes; _i < attributes_1.length; _i++) {\n var prop = attributes_1[_i];\n if (!isNullOrUndefined(this.inputElement.getAttribute(prop))) {\n switch (prop) {\n case 'name':\n this.inputElement.setAttribute('name', this.inputElement.getAttribute(prop));\n break;\n case 'step':\n this.step = parseInt(this.inputElement.getAttribute(prop), 10);\n break;\n case 'readonly':\n if ((isNullOrUndefined(this.dateTimeOptions) || (this.dateTimeOptions['readonly'] === undefined)) || isDynamic) {\n var readonly = this.inputElement.getAttribute(prop) === 'disabled' ||\n this.inputElement.getAttribute(prop) === '' ||\n this.inputElement.getAttribute(prop) === 'true' ? true : false;\n this.setProperties({ readonly: readonly }, !isDynamic);\n }\n break;\n case 'placeholder':\n if ((isNullOrUndefined(this.dateTimeOptions) || (this.dateTimeOptions['placeholder'] === undefined)) || isDynamic) {\n this.setProperties({ placeholder: this.inputElement.getAttribute(prop) }, !isDynamic);\n }\n break;\n case 'min':\n if ((isNullOrUndefined(this.dateTimeOptions) || (this.dateTimeOptions['min'] === undefined)) || isDynamic) {\n value = new Date(this.inputElement.getAttribute(prop));\n if (!this.isNullOrEmpty(value) && !isNaN(+value)) {\n this.setProperties({ min: value }, !isDynamic);\n }\n }\n break;\n case 'disabled':\n if ((isNullOrUndefined(this.dateTimeOptions) || (this.dateTimeOptions['enabled'] === undefined)) || isDynamic) {\n var enabled = this.inputElement.getAttribute(prop) === 'disabled' ||\n this.inputElement.getAttribute(prop) === 'true' ||\n this.inputElement.getAttribute(prop) === '' ? false : true;\n this.setProperties({ enabled: enabled }, !isDynamic);\n }\n break;\n case 'value':\n if ((isNullOrUndefined(this.dateTimeOptions) || (this.dateTimeOptions['value'] === undefined)) || isDynamic) {\n value = new Date(this.inputElement.getAttribute(prop));\n if (!this.isNullOrEmpty(value) && !isNaN(+value)) {\n this.setProperties({ value: value }, !isDynamic);\n }\n }\n break;\n case 'max':\n if ((isNullOrUndefined(this.dateTimeOptions) || (this.dateTimeOptions['max'] === undefined)) || isDynamic) {\n value = new Date(this.inputElement.getAttribute(prop));\n if (!this.isNullOrEmpty(value) && !isNaN(+value)) {\n this.setProperties({ max: value }, !isDynamic);\n }\n }\n break;\n }\n }\n }\n };\n DateTimePicker.prototype.requiredModules = function () {\n var modules = [];\n if (this) {\n modules.push({ args: [this], member: 'islamic' });\n }\n if (this.enableMask) {\n modules.push(this.maskedDateModule());\n }\n return modules;\n };\n DateTimePicker.prototype.maskedDateModule = function () {\n var modules = { args: [this], member: 'MaskedDateTime' };\n return modules;\n };\n DateTimePicker.prototype.getTimeActiveElement = function () {\n if (!isNullOrUndefined(this.dateTimeWrapper)) {\n return this.dateTimeWrapper.querySelectorAll('.' + ACTIVE);\n }\n else {\n return null;\n }\n };\n DateTimePicker.prototype.createDateObj = function (val) {\n return val instanceof Date ? val : null;\n };\n DateTimePicker.prototype.getDateObject = function (text) {\n if (!this.isNullOrEmpty(text)) {\n var dateValue = this.createDateObj(text);\n var value = this.valueWithMinutes;\n var status_1 = !isNullOrUndefined(value);\n if (this.checkDateValue(dateValue)) {\n var date = status_1 ? value.getDate() : DAY;\n var month = status_1 ? value.getMonth() : MONTH;\n var year = status_1 ? value.getFullYear() : YEAR;\n var hour = status_1 ? value.getHours() : HOUR;\n var minute = status_1 ? value.getMinutes() : MINUTE;\n var second = status_1 ? value.getSeconds() : SECOND;\n var millisecond = status_1 ? value.getMilliseconds() : MILLISECOND;\n if (!this.scrollInvoked) {\n return new Date(year, month, date, hour, minute, second, millisecond);\n }\n else {\n this.scrollInvoked = false;\n return new Date(year, month, date, dateValue.getHours(), dateValue.getMinutes(), dateValue.getSeconds(), dateValue.getMilliseconds());\n }\n }\n }\n return null;\n };\n DateTimePicker.prototype.findNextTimeElement = function (event) {\n var textVal = (this.inputElement).value;\n var value = isNullOrUndefined(this.valueWithMinutes) ? this.createDateObj(textVal) :\n this.getDateObject(this.valueWithMinutes);\n var dateTimeVal = null;\n var listCount = this.liCollections.length;\n if (!isNullOrUndefined(this.activeIndex) || !isNullOrUndefined(this.checkDateValue(value))) {\n if (event.action === 'home') {\n dateTimeVal = +(this.createDateObj(new Date(this.timeCollections[0])));\n this.activeIndex = 0;\n }\n else if (event.action === 'end') {\n dateTimeVal = +(this.createDateObj(new Date(this.timeCollections[this.timeCollections.length - 1])));\n this.activeIndex = this.timeCollections.length - 1;\n }\n else {\n if (event.action === 'down') {\n for (var i = 0; i < listCount; i++) {\n if (+value < this.timeCollections[i]) {\n dateTimeVal = +(this.createDateObj(new Date(this.timeCollections[i])));\n this.activeIndex = i;\n break;\n }\n }\n }\n else {\n for (var i = listCount - 1; i >= 0; i--) {\n if (+value > this.timeCollections[i]) {\n dateTimeVal = +(this.createDateObj(new Date(this.timeCollections[i])));\n this.activeIndex = i;\n break;\n }\n }\n }\n }\n this.selectedElement = this.liCollections[this.activeIndex];\n this.timeElementValue(isNullOrUndefined(dateTimeVal) ? null : new Date(dateTimeVal));\n }\n };\n DateTimePicker.prototype.setTimeValue = function (date, value) {\n var dateString;\n var time;\n var val = this.validateMinMaxRange(value);\n var newval = this.createDateObj(val);\n if (this.getFormattedValue(newval) !== (!isNullOrUndefined(this.value) ? this.getFormattedValue(this.value) : null)) {\n this.valueWithMinutes = isNullOrUndefined(newval) ? null : newval;\n time = new Date(+this.valueWithMinutes);\n }\n else {\n if (this.strictMode) {\n //for strict mode case, when value not present within a range. Reset the nearest range value.\n date = newval;\n }\n this.valueWithMinutes = this.checkDateValue(date);\n time = new Date(+this.valueWithMinutes);\n }\n if (this.calendarMode === 'Gregorian') {\n dateString = this.globalize.formatDate(time, {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.cldrDateTimeFormat(),\n type: 'dateTime', skeleton: 'yMd'\n });\n }\n else {\n dateString = this.globalize.formatDate(time, {\n format: !isNullOrUndefined(this.formatString) ? this.formatString : this.cldrDateTimeFormat(),\n type: 'dateTime', skeleton: 'yMd', calendar: 'islamic'\n });\n }\n if (!this.strictMode && isNullOrUndefined(time)) {\n Input.setValue(dateString, this.inputElement, this.floatLabelType, this.showClearButton);\n }\n else {\n Input.setValue(dateString, this.inputElement, this.floatLabelType, this.showClearButton);\n }\n return time;\n };\n DateTimePicker.prototype.timeElementValue = function (value) {\n if (!isNullOrUndefined(this.checkDateValue(value)) && !this.isNullOrEmpty(value)) {\n var date = value instanceof Date ? value : this.getDateObject(value);\n return this.setTimeValue(date, value);\n }\n return null;\n };\n DateTimePicker.prototype.timeKeyHandler = function (event) {\n if (isNullOrUndefined(this.step) || this.step <= 0) {\n return;\n }\n var listCount = this.timeCollections.length;\n if (isNullOrUndefined(this.getTimeActiveElement()) || this.getTimeActiveElement().length === 0) {\n if (this.liCollections.length > 0) {\n if (isNullOrUndefined(this.value) && isNullOrUndefined(this.activeIndex)) {\n this.activeIndex = 0;\n this.selectedElement = this.liCollections[0];\n this.timeElementValue(new Date(this.timeCollections[0]));\n }\n else {\n this.findNextTimeElement(event);\n }\n }\n }\n else {\n var nextItemValue = void 0;\n if ((event.keyCode >= 37) && (event.keyCode <= 40)) {\n var index = (event.keyCode === 40 || event.keyCode === 39) ? ++this.activeIndex : --this.activeIndex;\n this.activeIndex = index = this.activeIndex === (listCount) ? 0 : this.activeIndex;\n this.activeIndex = index = this.activeIndex < 0 ? (listCount - 1) : this.activeIndex;\n nextItemValue = isNullOrUndefined(this.timeCollections[index]) ?\n this.timeCollections[0] : this.timeCollections[index];\n }\n else if (event.action === 'home') {\n this.activeIndex = 0;\n nextItemValue = this.timeCollections[0];\n }\n else if (event.action === 'end') {\n this.activeIndex = listCount - 1;\n nextItemValue = this.timeCollections[listCount - 1];\n }\n this.selectedElement = this.liCollections[this.activeIndex];\n this.timeElementValue(new Date(nextItemValue));\n }\n this.isNavigate = true;\n this.setTimeHover(this.selectedElement, NAVIGATION);\n this.setTimeActiveDescendant();\n if (this.isTimePopupOpen() && this.selectedElement !== null && (!event || event.type !== 'click')) {\n this.setTimeScrollPosition();\n }\n };\n DateTimePicker.prototype.timeKeyActionHandle = function (event) {\n if (this.enabled) {\n if (event.action !== 'right' && event.action !== 'left' && event.action !== 'tab') {\n event.preventDefault();\n }\n switch (event.action) {\n case 'up':\n case 'down':\n case 'home':\n case 'end':\n this.timeKeyHandler(event);\n break;\n case 'enter':\n if (this.isNavigate) {\n this.selectedElement = this.liCollections[this.activeIndex];\n this.valueWithMinutes = new Date(this.timeCollections[this.activeIndex]);\n this.setInputValue('time');\n if (+this.previousDateTime !== +this.value) {\n this.changedArgs.value = this.value;\n this.addTimeSelection();\n this.previousDateTime = this.value;\n }\n }\n else {\n this.updateValue(event);\n }\n this.hide(event);\n addClass([this.inputWrapper.container], INPUTFOCUS);\n this.isNavigate = false;\n event.stopPropagation();\n break;\n case 'escape':\n this.hide(event);\n break;\n default:\n this.isNavigate = false;\n break;\n }\n }\n };\n DateTimePicker.prototype.inputKeyAction = function (event) {\n switch (event.action) {\n case 'altDownArrow':\n this.strictModeUpdate();\n this.updateInput();\n this.toggle(event);\n break;\n }\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @param {DateTimePickerModel} newProp - Returns the dynamic property value of the component.\n * @param {DateTimePickerModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n\n */\n DateTimePicker.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'value':\n this.isDynamicValueChanged = true;\n this.invalidValueString = null;\n this.checkInvalidValue(newProp.value);\n newProp.value = this.value;\n newProp.value = this.validateValue(newProp.value);\n if (this.enableMask) {\n Input.setValue(this.maskedDateValue, this.inputElement, this.floatLabelType, this.showClearButton);\n }\n else {\n Input.setValue(this.getFormattedValue(newProp.value), this.inputElement, this.floatLabelType, this.showClearButton);\n }\n this.valueWithMinutes = newProp.value;\n this.setProperties({ value: newProp.value }, true);\n if (this.popupObj) {\n this.popupUpdate();\n }\n this.previousDateTime = new Date(this.inputElement.value);\n this.updateInput();\n this.changeTrigger(null);\n this.preventChange = this.isAngular && this.preventChange ? !this.preventChange : this.preventChange;\n if (this.enableMask && this.value) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n }\n break;\n case 'min':\n case 'max':\n this.getProperty(newProp, prop);\n this.updateInput();\n break;\n case 'enableRtl':\n Input.setEnableRtl(this.enableRtl, [this.inputWrapper.container]);\n break;\n case 'cssClass':\n if (!isNullOrUndefined(oldProp.cssClass)) {\n oldProp.cssClass = (oldProp.cssClass.replace(/\\s+/g, ' ')).trim();\n }\n if (!isNullOrUndefined(newProp.cssClass)) {\n newProp.cssClass = (newProp.cssClass.replace(/\\s+/g, ' ')).trim();\n }\n Input.setCssClass(newProp.cssClass, [this.inputWrapper.container], oldProp.cssClass);\n if (this.dateTimeWrapper) {\n Input.setCssClass(newProp.cssClass, [this.dateTimeWrapper], oldProp.cssClass);\n }\n break;\n case 'locale':\n this.globalize = new Internationalization(this.locale);\n this.l10n.setLocale(this.locale);\n if (this.dateTimeOptions && this.dateTimeOptions.placeholder == null) {\n this.setProperties({ placeholder: this.l10n.getConstant('placeholder') }, true);\n Input.setPlaceholder(this.l10n.getConstant('placeholder'), this.inputElement);\n }\n this.dateTimeFormat = this.cldrDateTimeFormat();\n _super.prototype.updateInput.call(this);\n break;\n case 'htmlAttributes':\n this.updateHtmlAttributeToElement();\n this.updateHtmlAttributeToWrapper();\n this.checkAttributes(true);\n break;\n case 'format':\n this.setProperties({ format: newProp.format }, true);\n this.checkFormat();\n this.dateTimeFormat = this.formatString;\n this.setValue();\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n if (!this.value) {\n Input.setValue(this.maskedDateValue, this.inputElement, this.floatLabelType, this.showClearButton);\n }\n }\n break;\n case 'placeholder':\n Input.setPlaceholder(newProp.placeholder, this.inputElement);\n break;\n case 'enabled':\n Input.setEnabled(this.enabled, this.inputElement);\n if (this.enabled) {\n this.inputElement.setAttribute('tabindex', this.tabIndex);\n }\n else {\n this.inputElement.tabIndex = -1;\n }\n break;\n case 'strictMode':\n this.invalidValueString = null;\n this.updateInput();\n break;\n case 'width':\n this.setWidth(newProp.width);\n Input.calculateWidth(this.inputElement, this.inputWrapper.container);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-date-time-icon');\n }\n break;\n case 'readonly':\n Input.setReadonly(this.readonly, this.inputElement);\n break;\n case 'floatLabelType':\n this.floatLabelType = newProp.floatLabelType;\n Input.removeFloating(this.inputWrapper);\n Input.addFloating(this.inputElement, this.floatLabelType, this.placeholder);\n if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && !isNullOrUndefined(this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0]) && this.floatLabelType !== 'Never') {\n this.inputWrapper.container.getElementsByClassName('e-float-text-overflow')[0].classList.add('e-date-time-icon');\n }\n break;\n case 'scrollTo':\n if (this.checkDateValue(new Date(this.checkValue(newProp.scrollTo)))) {\n if (this.dateTimeWrapper) {\n this.setScrollTo();\n }\n this.setProperties({ scrollTo: this.checkDateValue(new Date(this.checkValue(newProp.scrollTo))) }, true);\n }\n else {\n this.setProperties({ scrollTo: null }, true);\n }\n break;\n case 'enableMask':\n if (this.enableMask) {\n this.notify('createMask', {\n module: 'MaskedDateTime'\n });\n Input.setValue(this.maskedDateValue, this.inputElement, this.floatLabelType, this.showClearButton);\n }\n else {\n if (this.inputElement.value === this.maskedDateValue) {\n this.maskedDateValue = '';\n Input.setValue(this.maskedDateValue, this.inputElement, this.floatLabelType, this.showClearButton);\n }\n }\n break;\n default:\n _super.prototype.onPropertyChanged.call(this, newProp, oldProp);\n break;\n }\n if (!this.isDynamicValueChanged) {\n this.hide(null);\n }\n this.isDynamicValueChanged = false;\n }\n };\n /**\n * To get component name.\n *\n * @returns {string} Returns the component name.\n * @private\n */\n DateTimePicker.prototype.getModuleName = function () {\n return 'datetimepicker';\n };\n DateTimePicker.prototype.restoreValue = function () {\n this.previousDateTime = this.previousDate;\n this.currentDate = this.value ? this.value : new Date();\n this.valueWithMinutes = this.value;\n this.previousDate = this.value;\n this.previousElementValue = this.previousElementValue = (isNullOrUndefined(this.inputValueCopy)) ? '' :\n this.getFormattedValue(this.inputValueCopy);\n };\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"timeFormat\", void 0);\n __decorate([\n Property(30)\n ], DateTimePicker.prototype, \"step\", void 0);\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"scrollTo\", void 0);\n __decorate([\n Property(1000)\n ], DateTimePicker.prototype, \"zIndex\", void 0);\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"value\", void 0);\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"keyConfigs\", void 0);\n __decorate([\n Property({})\n ], DateTimePicker.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property(false)\n ], DateTimePicker.prototype, \"enablePersistence\", void 0);\n __decorate([\n Property(true)\n ], DateTimePicker.prototype, \"allowEdit\", void 0);\n __decorate([\n Property(false)\n ], DateTimePicker.prototype, \"isMultiSelection\", void 0);\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"values\", void 0);\n __decorate([\n Property(true)\n ], DateTimePicker.prototype, \"showClearButton\", void 0);\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"placeholder\", void 0);\n __decorate([\n Property(false)\n ], DateTimePicker.prototype, \"strictMode\", void 0);\n __decorate([\n Property(false)\n ], DateTimePicker.prototype, \"fullScreenMode\", void 0);\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"serverTimezoneOffset\", void 0);\n __decorate([\n Property(new Date(1900, 0, 1))\n ], DateTimePicker.prototype, \"min\", void 0);\n __decorate([\n Property(new Date(2099, 11, 31))\n ], DateTimePicker.prototype, \"max\", void 0);\n __decorate([\n Property(null)\n ], DateTimePicker.prototype, \"firstDayOfWeek\", void 0);\n __decorate([\n Property('Gregorian')\n ], DateTimePicker.prototype, \"calendarMode\", void 0);\n __decorate([\n Property('Month')\n ], DateTimePicker.prototype, \"start\", void 0);\n __decorate([\n Property('Month')\n ], DateTimePicker.prototype, \"depth\", void 0);\n __decorate([\n Property(false)\n ], DateTimePicker.prototype, \"weekNumber\", void 0);\n __decorate([\n Property(true)\n ], DateTimePicker.prototype, \"showTodayButton\", void 0);\n __decorate([\n Property('Short')\n ], DateTimePicker.prototype, \"dayHeaderFormat\", void 0);\n __decorate([\n Property(false)\n ], DateTimePicker.prototype, \"openOnFocus\", void 0);\n __decorate([\n Property(false)\n ], DateTimePicker.prototype, \"enableMask\", void 0);\n __decorate([\n Property({ day: 'day', month: 'month', year: 'year', hour: 'hour', minute: 'minute', second: 'second', dayOfTheWeek: 'day of the week' })\n ], DateTimePicker.prototype, \"maskPlaceholder\", void 0);\n __decorate([\n Event()\n ], DateTimePicker.prototype, \"open\", void 0);\n __decorate([\n Event()\n ], DateTimePicker.prototype, \"close\", void 0);\n __decorate([\n Event()\n ], DateTimePicker.prototype, \"cleared\", void 0);\n __decorate([\n Event()\n ], DateTimePicker.prototype, \"blur\", void 0);\n __decorate([\n Event()\n ], DateTimePicker.prototype, \"focus\", void 0);\n __decorate([\n Event()\n ], DateTimePicker.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], DateTimePicker.prototype, \"destroyed\", void 0);\n DateTimePicker = __decorate([\n NotifyPropertyChanges\n ], DateTimePicker);\n return DateTimePicker;\n}(DatePicker));\nexport { DateTimePicker };\n","//! moment.js locale configuration\n//! locale : Swahili [sw]\n//! author : Fahad Kassim : https://github.com/fadsel\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var sw = moment.defineLocale('sw', {\n months: 'Januari_Februari_Machi_Aprili_Mei_Juni_Julai_Agosti_Septemba_Oktoba_Novemba_Desemba'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ago_Sep_Okt_Nov_Des'.split('_'),\n weekdays:\n 'Jumapili_Jumatatu_Jumanne_Jumatano_Alhamisi_Ijumaa_Jumamosi'.split(\n '_'\n ),\n weekdaysShort: 'Jpl_Jtat_Jnne_Jtan_Alh_Ijm_Jmos'.split('_'),\n weekdaysMin: 'J2_J3_J4_J5_Al_Ij_J1'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'hh:mm A',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[leo saa] LT',\n nextDay: '[kesho saa] LT',\n nextWeek: '[wiki ijayo] dddd [saat] LT',\n lastDay: '[jana] LT',\n lastWeek: '[wiki iliyopita] dddd [saat] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s baadaye',\n past: 'tokea %s',\n s: 'hivi punde',\n ss: 'sekunde %d',\n m: 'dakika moja',\n mm: 'dakika %d',\n h: 'saa limoja',\n hh: 'masaa %d',\n d: 'siku moja',\n dd: 'siku %d',\n M: 'mwezi mmoja',\n MM: 'miezi %d',\n y: 'mwaka mmoja',\n yy: 'miaka %d',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return sw;\n\n})));\n","import { Query, DataManager, Deferred } from '@syncfusion/ej2-data';\n/**\n * data module is used to generate query and dataSource\n */\nvar Data = /** @class */ (function () {\n /**\n * Constructor for data module\n *\n * @param dataSource\n * @param query\n * @param dataSource\n * @param query\n * @private\n */\n function Data(dataSource, query) {\n this.initDataManager(dataSource, query);\n }\n /**\n * The function used to initialize dataManager and query\n *\n * @param dataSource\n * @param query\n * @param dataSource\n * @param query\n * @returns {void}\n * @private\n */\n Data.prototype.initDataManager = function (dataSource, query) {\n this.dataManager = dataSource instanceof DataManager ? dataSource : new DataManager(dataSource);\n this.query = query instanceof Query ? query : new Query();\n };\n /**\n * The function used to generate updated Query from chart model\n *\n * @returns {void}\n * @private\n */\n Data.prototype.generateQuery = function () {\n var query = this.query.clone();\n return query;\n };\n /**\n * The function used to get dataSource by executing given Query\n *\n * @param {Query} query - A Query that specifies to generate dataSource\n * @returns {void}\n * @private\n */\n Data.prototype.getData = function (dataQuery) {\n var _this = this;\n if (this.dataManager.ready) {\n var dataManagerDeferred_1 = new Deferred();\n var ready = this.dataManager.ready;\n ready.then(function () {\n _this.dataManager.executeQuery(dataQuery).then(function (result) {\n dataManagerDeferred_1.resolve(result);\n });\n }).catch(function (e) { dataManagerDeferred_1.reject(e); });\n return dataManagerDeferred_1.promise;\n }\n else {\n return this.dataManager.executeQuery(dataQuery);\n }\n };\n return Data;\n}());\nexport { Data };\n","//! moment.js locale configuration\n//! locale : Slovak [sk]\n//! author : Martin Minka : https://github.com/k2s\n//! based on work of petrbela : https://github.com/petrbela\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var months =\n 'január_február_marec_aprÃl_máj_jún_júl_august_september_október_november_december'.split(\n '_'\n ),\n monthsShort = 'jan_feb_mar_apr_máj_jún_júl_aug_sep_okt_nov_dec'.split('_');\n function plural(n) {\n return n > 1 && n < 5;\n }\n function translate(number, withoutSuffix, key, isFuture) {\n var result = number + ' ';\n switch (key) {\n case 's': // a few seconds / in a few seconds / a few seconds ago\n return withoutSuffix || isFuture ? 'pár sekúnd' : 'pár sekundami';\n case 'ss': // 9 seconds / in 9 seconds / 9 seconds ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'sekundy' : 'sekúnd');\n } else {\n return result + 'sekundami';\n }\n case 'm': // a minute / in a minute / a minute ago\n return withoutSuffix ? 'minúta' : isFuture ? 'minútu' : 'minútou';\n case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'minúty' : 'minút');\n } else {\n return result + 'minútami';\n }\n case 'h': // an hour / in an hour / an hour ago\n return withoutSuffix ? 'hodina' : isFuture ? 'hodinu' : 'hodinou';\n case 'hh': // 9 hours / in 9 hours / 9 hours ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'hodiny' : 'hodÃn');\n } else {\n return result + 'hodinami';\n }\n case 'd': // a day / in a day / a day ago\n return withoutSuffix || isFuture ? 'deň' : 'dňom';\n case 'dd': // 9 days / in 9 days / 9 days ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'dni' : 'dnÃ');\n } else {\n return result + 'dňami';\n }\n case 'M': // a month / in a month / a month ago\n return withoutSuffix || isFuture ? 'mesiac' : 'mesiacom';\n case 'MM': // 9 months / in 9 months / 9 months ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'mesiace' : 'mesiacov');\n } else {\n return result + 'mesiacmi';\n }\n case 'y': // a year / in a year / a year ago\n return withoutSuffix || isFuture ? 'rok' : 'rokom';\n case 'yy': // 9 years / in 9 years / 9 years ago\n if (withoutSuffix || isFuture) {\n return result + (plural(number) ? 'roky' : 'rokov');\n } else {\n return result + 'rokmi';\n }\n }\n }\n\n var sk = moment.defineLocale('sk', {\n months: months,\n monthsShort: monthsShort,\n weekdays: 'nedeľa_pondelok_utorok_streda_Å¡tvrtok_piatok_sobota'.split('_'),\n weekdaysShort: 'ne_po_ut_st_Å¡t_pi_so'.split('_'),\n weekdaysMin: 'ne_po_ut_st_Å¡t_pi_so'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY H:mm',\n LLLL: 'dddd D. MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[dnes o] LT',\n nextDay: '[zajtra o] LT',\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[v nedeľu o] LT';\n case 1:\n case 2:\n return '[v] dddd [o] LT';\n case 3:\n return '[v stredu o] LT';\n case 4:\n return '[vo Å¡tvrtok o] LT';\n case 5:\n return '[v piatok o] LT';\n case 6:\n return '[v sobotu o] LT';\n }\n },\n lastDay: '[vÄera o] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n return '[minulú nedeľu o] LT';\n case 1:\n case 2:\n return '[minulý] dddd [o] LT';\n case 3:\n return '[minulú stredu o] LT';\n case 4:\n case 5:\n return '[minulý] dddd [o] LT';\n case 6:\n return '[minulú sobotu o] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'za %s',\n past: 'pred %s',\n s: translate,\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: translate,\n dd: translate,\n M: translate,\n MM: translate,\n y: translate,\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return sk;\n\n})));\n","import { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { Internationalization, setCulture } from '@syncfusion/ej2-base';\n/**\n * ValueFormatter class to globalize the value.\n *\n * @hidden\n */\nvar ValueFormatter = /** @class */ (function () {\n function ValueFormatter(cultureName) {\n this.intl = new Internationalization();\n if (!isNullOrUndefined(cultureName)) {\n this.intl.culture = cultureName;\n }\n }\n ValueFormatter.prototype.getFormatFunction = function (format) {\n if (format.type) {\n return this.intl.getDateFormat(format);\n }\n else {\n return this.intl.getNumberFormat(format);\n }\n };\n ValueFormatter.prototype.getParserFunction = function (format) {\n if (format.type) {\n return this.intl.getDateParser(format);\n }\n else {\n return this.intl.getNumberParser(format);\n }\n };\n ValueFormatter.prototype.fromView = function (value, format, type) {\n if ((type === 'date' || type === 'datetime' || type === 'number') && (!isNullOrUndefined(format))) {\n return format(value);\n }\n else {\n return value;\n }\n };\n ValueFormatter.prototype.toView = function (value, format) {\n var result = value;\n if (!isNullOrUndefined(format) && !isNullOrUndefined(value)) {\n result = format(value);\n }\n return result;\n };\n ValueFormatter.prototype.setCulture = function (cultureName) {\n if (!isNullOrUndefined(cultureName)) {\n setCulture(cultureName);\n }\n };\n return ValueFormatter;\n}());\nexport { ValueFormatter };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined, getValue, closest } from '@syncfusion/ej2-base';\nimport { attributes } from '@syncfusion/ej2-base';\nimport { CellRenderer } from './cell-renderer';\nimport { Input } from '@syncfusion/ej2-inputs';\nimport { appendChildren, addStickyColumnPosition } from '../base/util';\nimport { DropDownList } from '@syncfusion/ej2-dropdowns';\nimport * as events from '../base/constant';\n/**\n * FilterCellRenderer class which responsible for building filter cell.\n *\n * @hidden\n */\nvar FilterCellRenderer = /** @class */ (function (_super) {\n __extends(FilterCellRenderer, _super);\n function FilterCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TH', { className: 'e-filterbarcell', attrs: { role: 'columnheader' } });\n return _this;\n }\n /**\n * Function to return the wrapper for the TH content.\n *\n * @returns {string} returns the gui\n */\n FilterCellRenderer.prototype.getGui = function () {\n return this.parent.createElement('div');\n };\n /**\n * Function to render the cell content based on Column object.\n *\n * @param {Cell} cell\n * @param {Object} data\n */\n /* tslint:disable-next-line:max-func-body-length */\n FilterCellRenderer.prototype.render = function (cell, data) {\n var tr = this.parent.element.querySelector('.e-filterbar');\n var node = this.element.cloneNode();\n var innerDIV = this.getGui();\n var input;\n var column = cell.column;\n tr.appendChild(node);\n node.setAttribute('e-mappinguid', column.uid);\n if (column.filterTemplate) {\n var fltrData = {};\n if (data) {\n fltrData[column.field] = data[column.field];\n }\n var col = 'column';\n fltrData[\"\" + col] = column;\n if (column.visible) {\n var isReactCompiler = this.parent.isReact && typeof (column.filterTemplate) !== 'string';\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n var tempID = this.parent.element.id + column.uid + 'filterTemplate';\n if (isReactCompiler || isReactChild) {\n column.getFilterTemplate()(fltrData, this.parent, 'filterTemplate', tempID, null, null, node);\n this.parent.renderTemplates();\n }\n else {\n var element = column.getFilterTemplate()(fltrData, this.parent, 'filterTemplate', tempID);\n appendChildren(node, element);\n }\n }\n else {\n node.classList.add('e-hide');\n }\n }\n else {\n if (column.type !== 'checkbox') {\n if ((isNullOrUndefined(column.allowFiltering) || column.allowFiltering) && !isNullOrUndefined(column.filterBarTemplate)) {\n node.classList.add('e-fltrtemp');\n attributes(innerDIV, {\n 'class': 'e-fltrtempdiv'\n });\n if (isNullOrUndefined(column.filterBarTemplate.create)) {\n input = this.parent.createElement('input', {\n id: column.field + '_filterBarcell', className: 'e-filterUi_input e-filtertext e-fltrTemp',\n attrs: { type: 'search', title: column.headerText }\n });\n innerDIV.appendChild(input);\n }\n else {\n var args = { column: column, node: Element };\n var temp = column.filterBarTemplate.create;\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n }\n input = temp(args);\n if (typeof input === 'string') {\n var div = this.parent.createElement('div');\n div.innerHTML = input;\n input = div.firstChild;\n }\n attributes(innerDIV, {\n class: 'e-filterUi_input e-filtertext e-fltrTemp',\n title: column.headerText,\n id: column.field + '_filterBarcell'\n });\n innerDIV.appendChild(input);\n }\n }\n else {\n attributes(innerDIV, {\n 'class': 'e-filterdiv e-fltrinputdiv'\n });\n input = this.parent.createElement('input', {\n id: column.field + '_filterBarcell', className: 'e-filtertext',\n attrs: {\n type: 'search', title: column.headerText + cell.attributes.title,\n value: data[cell.column.field] ? data[cell.column.field] : ''\n }\n });\n innerDIV.appendChild(input);\n var args = {\n element: input, floatLabelType: 'Never',\n properties: {\n enableRtl: this.parent.enableRtl, showClearButton: true, cssClass: this.parent.cssClass\n }\n };\n Input.createInput(args, this.parent.createElement);\n }\n //TODO: apply intial filtering\n if (column.allowFiltering === false || column.field === '' || isNullOrUndefined(column.field)) {\n input.setAttribute('disabled', 'true');\n input.classList.add('e-disable');\n }\n var clearIconElem = innerDIV.querySelector('.e-clear-icon');\n if (clearIconElem) {\n clearIconElem.setAttribute('title', this.parent.localeObj.getConstant('ClearButton'));\n }\n if (!column.visible) {\n node.classList.add('e-hide');\n }\n this.appendHtml(node, innerDIV);\n // render's the dropdownlist component if showFilterBarOperator sets to true\n if (this.parent.filterSettings.showFilterBarOperator && this.parent.filterSettings.type === 'FilterBar' &&\n !this.parent.isPrinting && isNullOrUndefined(column.filterTemplate) && isNullOrUndefined(column.filterBarTemplate)) {\n this.operatorIconRender(innerDIV, column, cell);\n }\n if ((isNullOrUndefined(column.allowFiltering) || column.allowFiltering) && !isNullOrUndefined(column.filterBarTemplate)) {\n var templateWrite = column.filterBarTemplate.write;\n var args = { element: input, column: column };\n if (typeof templateWrite === 'string') {\n templateWrite = getValue(templateWrite, window);\n }\n templateWrite.call(this, args);\n }\n }\n }\n if (this.parent.isFrozenGrid()) {\n addStickyColumnPosition(this.parent, column, node);\n }\n return node;\n };\n /**\n * Function to specifies how the result content to be placed in the cell.\n *\n * @param {Element} node - specifies the node\n * @param {string|Element} innerHtml - specifies the innerHTML\n * @returns {Element} retruns the element\n */\n FilterCellRenderer.prototype.appendHtml = function (node, innerHtml) {\n node.appendChild(innerHtml);\n return node;\n };\n FilterCellRenderer.prototype.operatorIconRender = function (innerDIV, column, cell) {\n var gObj = this.parent;\n var operators;\n var fbicon = this.parent.createElement('input', {\n className: ' e-filterbaroperator e-icons e-icon-filter',\n id: cell.column.uid\n });\n innerDIV.querySelector('span').appendChild(fbicon);\n if (column.filter && column.filter.operator) {\n operators = column.filter.operator;\n }\n else if (gObj.filterSettings.columns.length) {\n for (var i = 0, a = gObj.filterSettings.columns; i < a.length; i++) {\n var col = a[parseInt(i.toString(), 10)];\n if (col.field === column.field) {\n operators = col.operator;\n break;\n }\n else {\n operators = 'equal';\n }\n }\n }\n else {\n operators = 'equal';\n }\n if (!isNullOrUndefined(gObj.filterModule.operators[column.field])) {\n operators = gObj.filterModule.operators[column.field];\n }\n this.dropOptr = new DropDownList({\n fields: { text: 'text', value: 'value' },\n popupHeight: 'auto',\n value: operators,\n width: '0px',\n enabled: column.allowFiltering,\n popupWidth: 'auto',\n enableRtl: this.parent.enableRtl,\n change: this.internalEvent.bind(this),\n beforeOpen: function () {\n var operator = gObj.filterModule.customOperators;\n this.dataSource = operator[gObj.getColumnByUid(this.element.id).type + 'Operator'];\n for (var i = 0; i < this.dataSource.length; i++) {\n if (column.filter && column.filter.operator && isNullOrUndefined(gObj.filterModule.operators[column.field]) &&\n this.dataSource[parseInt(i.toString(), 10)].value === column.filter.operator) {\n this.value = column.filter.operator;\n }\n }\n },\n cssClass: this.parent.cssClass ? 'e-popup-flbar' + ' ' + this.parent.cssClass : 'e-popup-flbar'\n });\n this.dropOptr.appendTo(fbicon);\n var spanElmt = closest(this.dropOptr.element, 'span');\n spanElmt.classList.add('e-filterbardropdown');\n spanElmt.removeAttribute('tabindex');\n };\n FilterCellRenderer.prototype.internalEvent = function (e) {\n var gObj = this.parent;\n var col = gObj.getColumnByUid(e.element.getAttribute('id'));\n e.column = col;\n gObj.filterModule.operators[col.field] = e.value;\n gObj.notify(events.getFilterBarOperator, e);\n };\n return FilterCellRenderer;\n}(CellRenderer));\nexport { FilterCellRenderer };\n","import { DropDownList } from '@syncfusion/ej2-dropdowns';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { Query, DataManager } from '@syncfusion/ej2-data';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\n/**\n * `filter operators` render boolean column.\n *\n * @hidden\n */\nvar FlMenuOptrUI = /** @class */ (function () {\n function FlMenuOptrUI(parent, customFltrOperators, serviceLocator, filterSettings) {\n this.ddOpen = this.dropDownOpen.bind(this);\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.filterSettings = filterSettings;\n this.customFilterOperators = customFltrOperators;\n if (this.parent) {\n this.parent.on(events.filterMenuClose, this.destroyDropDownList, this);\n this.parent.on(events.destroy, this.destroyDropDownList, this);\n }\n }\n /**\n * @param {Element} dlgConetntEle - specifies the content element\n * @param {Element} target - specifies the target\n * @param {Column} column - specifies the column\n * @param {Dialog} dlgObj - specifies the dialog\n * @param {Object[]} operator - specifies the operator list\n * @returns {void}\n * @hidden\n */\n // eslint-disable-next-line max-len\n FlMenuOptrUI.prototype.renderOperatorUI = function (dlgConetntEle, target, column, dlgObj, operator) {\n this.dialogObj = dlgObj;\n var optr = column.type + 'Operator';\n this.optrData = this.customOptr = !isNullOrUndefined(operator) ? operator :\n (!isNullOrUndefined(this.parent.filterSettings.operators) && !isNullOrUndefined(this.parent.filterSettings.operators[\"\" + optr])) ?\n this.parent.filterSettings.operators[\"\" + optr] : this.customFilterOperators[\"\" + optr];\n var dropDatasource = this.customOptr;\n var selectedValue = this.dropSelectedVal(column, optr);\n var optrDiv = this.parent.createElement('div', { className: 'e-flm_optrdiv' });\n dlgConetntEle.appendChild(optrDiv);\n var optrInput = this.parent.createElement('input', { id: column.uid + '-floptr' });\n optrDiv.appendChild(optrInput);\n this.dropOptr = new DropDownList({\n dataSource: dropDatasource,\n fields: { text: 'text', value: 'value' },\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n enableRtl: this.parent.enableRtl,\n text: selectedValue,\n // eslint-disable-next-line @typescript-eslint/tslint/config\n change: function () {\n var valInput = document.querySelector('.e-flmenu-valuediv').querySelector('input');\n if (this.value === 'isempty' || this.value === 'isnotempty' ||\n this.value === 'isnull' || this.value === 'isnotnull') {\n valInput['ej2_instances'][0]['enabled'] = false;\n }\n else if (!isNullOrUndefined(valInput.getAttribute('disabled'))) {\n valInput['ej2_instances'][0]['enabled'] = true;\n }\n }\n });\n this.dropOptr.addEventListener(literals['open'], this.ddOpen);\n this.dropOptr.appendTo('#' + column.uid + '-floptr');\n };\n FlMenuOptrUI.prototype.renderResponsiveDropDownList = function (args) {\n args.popup.element.style.width = '100%';\n };\n FlMenuOptrUI.prototype.dropDownOpen = function (args) {\n args.popup.element.style.zIndex = (this.dialogObj.zIndex + 1).toString();\n if (this.parent.enableAdaptiveUI) {\n this.renderResponsiveDropDownList(args);\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n FlMenuOptrUI.prototype.dropSelectedVal = function (col, optr) {\n var selValue = '';\n var columns = this.parent.filterSettings.columns;\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var column = columns_1[_i];\n if (col.field === column.field || (col.isForeignColumn() && col.foreignKeyValue === column.field)) {\n var selectedField = new DataManager(this.optrData).executeLocal(new Query().where('value', 'equal', column.operator));\n selValue = !isNullOrUndefined(selectedField[0]) ? selectedField[0].text : '';\n }\n }\n if (selValue === '') { // rewuired or not\n if (col.filter.operator) {\n var optrLen = Object.keys(this.optrData).length;\n for (var i = 0; i < optrLen; i++) {\n if (this.optrData[parseInt(i.toString(), 10)].value === col.filter.operator) {\n selValue = this.optrData[parseInt(i.toString(), 10)].text;\n }\n }\n }\n else {\n selValue = this.optrData[0].text;\n }\n }\n return selValue;\n };\n /**\n * @returns {string} returns the operator\n * @hidden\n */\n FlMenuOptrUI.prototype.getFlOperator = function () {\n return this.dropOptr.value;\n };\n FlMenuOptrUI.prototype.destroyDropDownList = function () {\n if (this.dropOptr.isDestroyed) {\n return;\n }\n this.dropOptr.removeEventListener(literals['open'], this.ddOpen);\n this.dropOptr.destroy();\n this.parent.off(events.filterMenuClose, this.destroyDropDownList);\n this.parent.off(events.destroy, this.destroyDropDownList);\n };\n return FlMenuOptrUI;\n}());\nexport { FlMenuOptrUI };\n","import { AutoComplete } from '@syncfusion/ej2-dropdowns';\nimport { DataManager, Query, Predicate } from '@syncfusion/ej2-data';\nimport { Browser, isNullOrUndefined, extend, getValue } from '@syncfusion/ej2-base';\nimport { getZIndexCalcualtion, eventPromise } from '../base/util';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\nimport { CheckBoxFilterBase } from '../common/checkbox-filter-base';\n/**\n * `string filterui` render string column.\n *\n * @hidden\n */\nvar StringFilterUI = /** @class */ (function () {\n function StringFilterUI(parent, serviceLocator, filterSettings) {\n this.parent = parent;\n this.serLocator = serviceLocator;\n this.filterSettings = filterSettings;\n if (this.parent) {\n this.parent.on(events.filterMenuClose, this.destroy, this);\n this.parent.on(events.destroy, this.destroy, this);\n }\n }\n StringFilterUI.prototype.create = function (args) {\n this.instance = this.parent.createElement('input', { className: 'e-flmenu-input', id: 'strui-' + args.column.uid });\n args.target.appendChild(this.instance);\n this.dialogObj = args.dialogObj;\n this.processDataOperation(args);\n };\n StringFilterUI.prototype.processDataOperation = function (args) {\n var _this = this;\n if (args.column.isForeignColumn()) {\n this.parent.getDataModule().dataManager.executeQuery(this.parent.getDataModule().generateQuery(true))\n .then(function (result) { _this.getAutoCompleteOptions(args, result); });\n return;\n }\n this.getAutoCompleteOptions(args);\n };\n StringFilterUI.prototype.getAutoCompleteOptions = function (args, result) {\n var isForeignColumn = args.column.isForeignColumn();\n var foreignColumnQuery;\n if (isForeignColumn) {\n var filteredData = CheckBoxFilterBase.getDistinct(result.result, args.column.field)\n .records || [];\n var filterQuery = void 0;\n for (var i = 0; i < filteredData.length; i++) {\n if (filterQuery) {\n filterQuery = filterQuery.or(args.column.field, 'contains', filteredData[parseInt(i.toString(), 10)][args.column.field], this.parent\n .filterSettings.enableCaseSensitivity, this.parent.filterSettings.ignoreAccent);\n }\n else {\n filterQuery = new Predicate(args.column.field, 'contains', filteredData[parseInt(i.toString(), 10)][args.column.field], this.parent\n .filterSettings.enableCaseSensitivity, this.parent.filterSettings.ignoreAccent);\n }\n }\n foreignColumnQuery = new Query().where(filterQuery);\n foreignColumnQuery.params = this.parent.query.params;\n }\n var dataSource = isForeignColumn ? args.column.dataSource : this.parent.dataSource;\n var fields = { value: isForeignColumn ? args.column.foreignKeyValue : args.column.field };\n var autoComplete = new AutoComplete(extend({\n dataSource: dataSource instanceof DataManager ? dataSource : new DataManager(dataSource),\n fields: fields,\n locale: this.parent.locale,\n enableRtl: this.parent.enableRtl,\n query: isForeignColumn ? foreignColumnQuery : this.parent.getDataModule().generateQuery(true, true),\n sortOrder: 'Ascending',\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n autofill: true,\n placeholder: args.localizeText.getConstant('EnterValue'),\n actionBegin: function () {\n if (this.query.queries.length && this.query.queries[0].fn === 'onWhere' && this.query.queries[0].e\n && this.query.queries[0].e.predicates) {\n for (var i = 0; i < this.query.queries[0].e.predicates.length; i++) {\n if (this.properties.fields.value === this.query.queries[0].e.predicates[\"\" + i].field) {\n this.query.queries[0].e.predicates.splice(i, 1);\n i = i - 1;\n }\n }\n if (!this.query.queries[0].e.predicates.length) {\n this.query.queries.splice(0, 1);\n }\n }\n }\n }, args.column.filter.params));\n this.acFocus = this.focus(autoComplete, args);\n this.acComplete = this.actionComplete(autoComplete);\n this.acOpen = this.openPopup.bind(this);\n autoComplete.addEventListener(literals.focus, this.acFocus);\n autoComplete.addEventListener(literals['open'], this.acOpen);\n autoComplete.addEventListener(events.actionComplete, this.acComplete);\n if (dataSource && 'result' in dataSource) {\n var query = this.parent.getQuery ? this.parent.getQuery().clone() : new Query();\n var defObj = eventPromise({ requestType: 'stringfilterrequest' }, query);\n this.parent.trigger(events.dataStateChange, defObj.state);\n var def = defObj.deffered;\n def.promise.then(function (e) {\n autoComplete.dataSource = new DataManager(e);\n });\n }\n this.actObj = autoComplete;\n this.actObj.appendTo(this.instance);\n if (isForeignColumn) {\n this.parent.filterModule.filterModule.afterRenderFilterUI();\n }\n };\n StringFilterUI.prototype.write = function (args) {\n if (args.filteredValue !== '' && !isNullOrUndefined(args.filteredValue)) {\n var struiObj = document.querySelector('#strui-' + args.column.uid).ej2_instances[0];\n struiObj.value = args.filteredValue;\n }\n };\n StringFilterUI.prototype.read = function (element, column, filterOptr, filterObj) {\n var actuiObj = document.querySelector('#strui-' + column.uid).ej2_instances[0];\n if (Browser.isDevice) {\n actuiObj.hidePopup();\n actuiObj.focusOut();\n }\n var filterValue = actuiObj.value;\n if (isNullOrUndefined(filterValue) || filterValue === '') {\n filterValue = null;\n }\n filterObj.filterByColumn(column.field, filterOptr, filterValue, 'and', this.parent.filterSettings.enableCaseSensitivity);\n };\n StringFilterUI.prototype.openPopup = function (args) {\n getZIndexCalcualtion(args, this.dialogObj);\n };\n StringFilterUI.prototype.focus = function (actObj, args) {\n return function () {\n actObj.filterType = args.getOptrInstance.getFlOperator();\n };\n };\n StringFilterUI.prototype.actionComplete = function (actObj) {\n return function (e) {\n e.result = e.result.filter(function (obj, index, arr) {\n return arr.map(function (mapObj) {\n return (getValue(actObj.fields.value, mapObj));\n }).indexOf(getValue((actObj.fields.value), obj)) === index;\n });\n };\n };\n StringFilterUI.prototype.destroy = function () {\n if (!this.actObj || this.actObj.isDestroyed) {\n return;\n }\n this.actObj.removeEventListener(literals.focus, this.acFocus);\n this.actObj.removeEventListener(literals['open'], this.acOpen);\n this.actObj.removeEventListener(events.actionComplete, this.acComplete);\n this.actObj.destroy();\n this.parent.off(events.filterMenuClose, this.destroy);\n this.parent.off(events.destroy, this.destroy);\n };\n return StringFilterUI;\n}());\nexport { StringFilterUI };\n","import { NumericTextBox } from '@syncfusion/ej2-inputs';\nimport { extend, isUndefined } from '@syncfusion/ej2-base';\nimport * as events from '../base/constant';\n/**\n * `numberfilterui` render number column.\n *\n * @hidden\n */\nvar NumberFilterUI = /** @class */ (function () {\n function NumberFilterUI(parent, serviceLocator, filterSettings) {\n this.filterSettings = filterSettings;\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n if (this.parent) {\n this.parent.on(events.filterMenuClose, this.destroy, this);\n this.parent.on(events.destroy, this.destroy, this);\n }\n }\n NumberFilterUI.prototype.keyEventHandler = function (args) {\n if (args.keyCode === 13 || args.keyCode === 9) {\n var evt = document.createEvent('HTMLEvents');\n evt.initEvent('change', false, true);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.dispatchEvent(evt);\n }\n };\n NumberFilterUI.prototype.create = function (args) {\n this.instance = this.parent.createElement('input', { className: 'e-flmenu-input', id: 'numberui-' + args.column.uid });\n args.target.appendChild(this.instance);\n this.numericTxtObj = new NumericTextBox(extend({\n format: typeof (args.column.format) === 'string' || isUndefined(args.column.format) ? args.column.format :\n args.column.format.format,\n locale: this.parent.locale,\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n placeholder: args.localizeText.getConstant('EnterValue'),\n enableRtl: this.parent.enableRtl\n }, args.column.filter.params));\n this.numericTxtObj.appendTo(this.instance);\n };\n NumberFilterUI.prototype.write = function (args) {\n var numberuiObj = document.querySelector('#numberui-' + args.column.uid).ej2_instances[0];\n numberuiObj.element.addEventListener('keydown', this.keyEventHandler);\n numberuiObj.value = args.filteredValue;\n };\n NumberFilterUI.prototype.read = function (element, column, filterOptr, filterObj) {\n var numberuiObj = document.querySelector('#numberui-' + column.uid).ej2_instances[0];\n var filterValue = numberuiObj.value;\n filterObj.filterByColumn(column.field, filterOptr, filterValue, 'and', true);\n };\n NumberFilterUI.prototype.destroy = function () {\n if (!this.numericTxtObj || this.numericTxtObj.isDestroyed) {\n return;\n }\n this.numericTxtObj.destroy();\n this.parent.off(events.filterMenuClose, this.destroy);\n this.parent.off(events.destroy, this.destroy);\n };\n return NumberFilterUI;\n}());\nexport { NumberFilterUI };\n","import { getZIndexCalcualtion } from '../base/util';\nimport { Query, DataManager, DataUtil } from '@syncfusion/ej2-data';\nimport { DropDownList } from '@syncfusion/ej2-dropdowns';\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\n/**\n * `boolfilterui` render boolean column.\n *\n * @hidden\n */\nvar BooleanFilterUI = /** @class */ (function () {\n function BooleanFilterUI(parent, serviceLocator, filterSettings) {\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.filterSettings = filterSettings;\n if (this.parent) {\n this.parent.on(events.filterMenuClose, this.destroy, this);\n this.parent.on(events.destroy, this.destroy, this);\n }\n }\n BooleanFilterUI.prototype.create = function (args) {\n var isForeignColumn = args.column.isForeignColumn();\n var dataSource = isForeignColumn ? args.column.dataSource : this.parent.dataSource;\n var fields = isForeignColumn ? args.column.foreignKeyValue : args.column.field;\n this.elem = this.parent.createElement('input', { className: 'e-flmenu-input', id: 'bool-ui-' + args.column.uid });\n args.target.appendChild(this.elem);\n this.dialogObj = args.dialogObj;\n this.dropInstance = new DropDownList(extend({\n dataSource: dataSource instanceof DataManager ?\n dataSource : new DataManager(dataSource),\n query: new Query().select(fields),\n fields: { text: fields, value: fields },\n placeholder: args.localizeText.getConstant('SelectValue'),\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n locale: this.parent.locale,\n enableRtl: this.parent.enableRtl\n }, args.column.filter.params));\n this.ddOpen = this.openPopup.bind(this);\n this.ddComplete = this.actionComplete(fields);\n this.dropInstance.addEventListener(literals['open'], this.ddOpen);\n this.dropInstance.addEventListener(events.actionComplete, this.ddComplete);\n this.dropInstance.appendTo(this.elem);\n };\n BooleanFilterUI.prototype.write = function (args) {\n var drpuiObj = document.querySelector('#bool-ui-' + args.column.uid).ej2_instances[0];\n if (!isNullOrUndefined(args.filteredValue)) {\n drpuiObj.value = args.filteredValue;\n }\n };\n BooleanFilterUI.prototype.read = function (element, column, filterOptr, filterObj) {\n var drpuiObj = document.querySelector('#bool-ui-' + column.uid).ej2_instances[0];\n var filterValue = drpuiObj.value;\n filterObj.filterByColumn(column.field, filterOptr, filterValue, 'and', false);\n };\n BooleanFilterUI.prototype.openPopup = function (args) {\n getZIndexCalcualtion(args, this.dialogObj);\n };\n BooleanFilterUI.prototype.actionComplete = function (fields) {\n return function (e) {\n e.result = DataUtil.distinct(e.result, fields, true);\n };\n };\n BooleanFilterUI.prototype.destroy = function () {\n if (!this.dropInstance || this.dropInstance.isDestroyed) {\n return;\n }\n this.dropInstance.removeEventListener(literals['open'], this.ddOpen);\n this.dropInstance.removeEventListener(events.actionComplete, this.ddComplete);\n this.dropInstance.destroy();\n this.parent.off(events.filterMenuClose, this.destroy);\n this.parent.off(events.destroy, this.destroy);\n };\n return BooleanFilterUI;\n}());\nexport { BooleanFilterUI };\n","import { DatePicker, DateTimePicker } from '@syncfusion/ej2-calendars';\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { getCustomDateFormat } from '../base/util';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\n/**\n * `datefilterui` render date column.\n *\n * @hidden\n */\nvar DateFilterUI = /** @class */ (function () {\n function DateFilterUI(parent, serviceLocator, filterSettings) {\n this.dpOpen = this.openPopup.bind(this);\n this.parent = parent;\n this.locator = serviceLocator;\n this.fltrSettings = filterSettings;\n if (this.parent) {\n this.parent.on(events.filterMenuClose, this.destroy, this);\n this.parent.on(events.destroy, this.destroy, this);\n }\n }\n DateFilterUI.prototype.create = function (args) {\n var format = getCustomDateFormat(args.column.format, args.column.type);\n this.dialogObj = args.dialogObj;\n this.inputElem = this.parent.createElement('input', { className: 'e-flmenu-input', id: 'dateui-' + args.column.uid });\n args.target.appendChild(this.inputElem);\n if (args.column.type === 'date' || args.column.type === 'dateonly') {\n this.datePickerObj = new DatePicker(extend({\n format: format,\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n placeholder: args.localizeText.getConstant('ChooseDate'),\n width: '100%',\n locale: this.parent.locale,\n enableRtl: this.parent.enableRtl\n }, args.column.filter.params));\n }\n else if (args.column.type === 'datetime') {\n this.datePickerObj = new DateTimePicker(extend({\n format: format,\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n placeholder: args.localizeText.getConstant('ChooseDate'),\n width: '100%',\n locale: this.parent.locale,\n enableRtl: this.parent.enableRtl\n }, args.column.filter.params));\n }\n this.datePickerObj.addEventListener(literals['open'], this.dpOpen);\n this.datePickerObj.appendTo(this.inputElem);\n };\n DateFilterUI.prototype.write = function (args) {\n var dateuiObj = document.querySelector('#dateui-' + args.column.uid).ej2_instances[0];\n dateuiObj.value = !isNullOrUndefined(args.filteredValue) ? new Date(args.filteredValue) : null;\n };\n DateFilterUI.prototype.read = function (element, column, filterOptr, filterObj) {\n var dateuiObj = document.querySelector('#dateui-' + column.uid).ej2_instances[0];\n var filterValue = dateuiObj.value;\n filterValue = isNullOrUndefined(filterValue) ? null : filterValue;\n filterObj.filterByColumn(column.field, filterOptr, filterValue, 'and', true);\n };\n DateFilterUI.prototype.openPopup = function (args) {\n args.popup.element.style.zIndex = (this.dialogObj.zIndex + 1).toString();\n };\n DateFilterUI.prototype.destroy = function () {\n this.parent.off(events.filterMenuClose, this.destroy);\n this.parent.off(events.destroy, this.destroy);\n if (isNullOrUndefined(this.datePickerObj) || this.datePickerObj.isDestroyed) {\n return;\n }\n this.datePickerObj.removeEventListener(literals['open'], this.dpOpen);\n this.datePickerObj.destroy();\n };\n return DateFilterUI;\n}());\nexport { DateFilterUI };\n","import { isNullOrUndefined, getValue, remove } from '@syncfusion/ej2-base';\nimport { Browser } from '@syncfusion/ej2-base';\nimport { Dialog } from '@syncfusion/ej2-popups';\nimport { FlMenuOptrUI } from './filter-menu-operator';\nimport { StringFilterUI } from './string-filter-ui';\nimport { NumberFilterUI } from './number-filter-ui';\nimport { BooleanFilterUI } from './boolean-filter-ui';\nimport { DateFilterUI } from './date-filter-ui';\nimport { getFilterMenuPostion, parentsUntil, appendChildren, clearReactVueTemplates } from '../base/util';\nimport * as events from '../base/constant';\nimport { CheckBoxFilterBase } from '../common/checkbox-filter-base';\n/**\n * `filter menu` render boolean column.\n *\n * @hidden\n */\nvar FilterMenuRenderer = /** @class */ (function () {\n function FilterMenuRenderer(parent, filterSettings, serviceLocator, customFltrOperators, fltrObj) {\n this.isDialogOpen = false;\n this.maxHeight = '350px';\n this.isMenuCheck = false;\n this.colTypes = {\n 'string': StringFilterUI, 'number': NumberFilterUI, 'date': DateFilterUI, 'dateonly': DateFilterUI, 'boolean': BooleanFilterUI, 'datetime': DateFilterUI\n };\n this.parent = parent;\n this.filterSettings = filterSettings;\n this.serviceLocator = serviceLocator;\n this.customFilterOperators = customFltrOperators;\n this.filterObj = fltrObj;\n this.flMuiObj = new FlMenuOptrUI(this.parent, this.customFilterOperators, this.serviceLocator);\n this.l10n = this.serviceLocator.getService('localization');\n this.menuFilterBase = new CheckBoxFilterBase(parent);\n }\n FilterMenuRenderer.prototype.clearCustomFilter = function (col) {\n this.clearBtnClick(col);\n };\n FilterMenuRenderer.prototype.applyCustomFilter = function (args) {\n this.filterBtnClick(args.col);\n };\n FilterMenuRenderer.prototype.openDialog = function (args) {\n this.options = args;\n this.col = this.parent.getColumnByField(args.field);\n if (isNullOrUndefined(this.col.filter) || (isNullOrUndefined(this.col.filter.type) || this.col.filter.type === 'Menu')) { ///\n this.renderDlgContent(args.target, this.col);\n }\n };\n FilterMenuRenderer.prototype.closeDialog = function (target) {\n if (!this.dlgObj) {\n return;\n }\n if (this.parent.isReact || this.parent.isVue) {\n clearReactVueTemplates(this.parent, ['filterTemplate']);\n }\n var elem = document.getElementById(this.dlgObj.element.id);\n if (this.dlgObj && !this.dlgObj.isDestroyed && elem) {\n var argument = { cancel: false, column: this.col, target: target, element: elem };\n this.parent.notify(events.filterMenuClose, argument);\n if (argument.cancel) {\n return;\n }\n this.isDialogOpen = false;\n if (this.isMenuCheck) {\n this.menuFilterBase.unWireEvents();\n this.parent.off(events.cBoxFltrComplete, this.actionComplete);\n this.isMenuCheck = false;\n }\n this.dlgObj.destroy();\n remove(elem);\n }\n this.parent.notify(events.filterDialogClose, {});\n };\n FilterMenuRenderer.prototype.renderDlgContent = function (target, column) {\n var args = {\n requestType: events.filterBeforeOpen,\n columnName: column.field, columnType: column.type\n };\n var filterModel = 'filterModel';\n args[\"\" + filterModel] = this;\n this.parent.trigger(events.actionBegin, args);\n var mainDiv = this.parent.createElement('div', { className: 'e-flmenu-maindiv', id: column.uid + '-flmenu' });\n this.dlgDiv = this.parent.createElement('div', { className: 'e-flmenu', id: column.uid + '-flmdlg' });\n this.dlgDiv.setAttribute('aria-label', this.l10n.getConstant('FilterMenuDialogARIA'));\n if (this.parent.enableAdaptiveUI) {\n var responsiveCnt = document.querySelector('.e-resfilter > .e-dlg-content > .e-mainfilterdiv');\n responsiveCnt.appendChild(this.dlgDiv);\n }\n else {\n this.parent.element.appendChild(this.dlgDiv);\n }\n this.dlgObj = new Dialog({\n showCloseIcon: false,\n closeOnEscape: false,\n locale: this.parent.locale,\n visible: false,\n enableRtl: this.parent.enableRtl,\n created: this.dialogCreated.bind(this, target, column),\n position: this.parent.element.classList.contains('e-device') ? { X: 'center', Y: 'center' } : { X: '', Y: '' },\n target: this.parent.element.classList.contains('e-device') ? document.body : this.parent.element,\n buttons: [{\n click: this.filterBtnClick.bind(this, column),\n buttonModel: {\n content: this.l10n.getConstant('FilterButton'), isPrimary: true,\n cssClass: this.parent.cssClass ? 'e-flmenu-okbtn' + ' ' + this.parent.cssClass : 'e-flmenu-okbtn'\n }\n },\n {\n click: this.clearBtnClick.bind(this, column),\n buttonModel: { content: this.l10n.getConstant('ClearButton'),\n cssClass: this.parent.cssClass ? 'e-flmenu-cancelbtn' + ' ' + this.parent.cssClass : 'e-flmenu-cancelbtn' }\n }],\n content: mainDiv,\n width: (!isNullOrUndefined(parentsUntil(target, 'e-bigger'))) || this.parent.element.classList.contains('e-device') ? 260 : 250,\n animationSettings: { effect: 'None' },\n cssClass: this.parent.cssClass ? 'e-filter-popup' + ' ' + this.parent.cssClass : 'e-filter-popup'\n });\n var isStringTemplate = 'isStringTemplate';\n this.dlgObj[\"\" + isStringTemplate] = true;\n this.renderResponsiveDialog();\n this.dlgObj.appendTo(this.dlgDiv);\n };\n FilterMenuRenderer.prototype.renderResponsiveDialog = function () {\n var gObj = this.parent;\n if (gObj.enableAdaptiveUI) {\n this.dlgObj.position = { X: '', Y: '' };\n this.dlgObj.target = document.querySelector('.e-resfilter > .e-dlg-content > .e-mainfilterdiv');\n this.dlgObj.width = '100%';\n this.dlgObj.isModal = false;\n this.dlgObj.buttons = [{}];\n }\n };\n FilterMenuRenderer.prototype.dialogCreated = function (target, column) {\n if (!Browser.isDevice && target) {\n getFilterMenuPostion(target, this.dlgObj);\n }\n this.currentDialogCreatedColumn = column;\n this.renderFilterUI(target, column);\n if (!(column.isForeignColumn() && !(!isNullOrUndefined(column.filter) && !isNullOrUndefined(column.filter.ui)\n && !isNullOrUndefined(column.filter.ui.create)))) {\n this.afterRenderFilterUI();\n }\n if (!isNullOrUndefined(column.filterTemplate)) {\n this.dlgDiv.querySelector('.e-flmenu-valuediv').firstElementChild.focus();\n this.dlgDiv.querySelector('.e-flmenu-valuediv').firstElementChild.classList.add('e-input-focus');\n }\n else if (!isNullOrUndefined(this.dlgDiv.querySelector('.e-flmenu-input'))) {\n this.dlgDiv.querySelector('.e-flmenu-input').focus();\n this.dlgDiv.querySelector('.e-flmenu-input').parentElement.classList.add('e-input-focus');\n }\n };\n /**\n * Function to notify filterDialogCreated and trigger actionComplete\n *\n * @returns {void}\n * @hidden\n */\n FilterMenuRenderer.prototype.afterRenderFilterUI = function () {\n var column = this.currentDialogCreatedColumn;\n if (column.showColumnMenu) {\n this.parent.notify(events.filterDialogCreated, {});\n }\n if (this.parent.enableAdaptiveUI) {\n this.dlgObj.element.style.left = '0px';\n this.dlgObj.element.style.maxHeight = 'none';\n }\n else {\n this.dlgObj.element.style.maxHeight = this.maxHeight;\n }\n this.dlgObj.show();\n var optrInput = this.dlgObj.element.querySelector('.e-flm_optrdiv').querySelector('input');\n var valInput = this.dlgObj.element.querySelector('.e-flmenu-valuediv').querySelector('input');\n if (optrInput.value === 'Empty' || optrInput.value === 'Not Empty' ||\n optrInput.value === 'Null' || optrInput.value === 'Not Null') {\n valInput['ej2_instances'][0]['enabled'] = false;\n }\n else if (!isNullOrUndefined(valInput && valInput.getAttribute('disabled'))) {\n valInput['ej2_instances'][0]['enabled'] = true;\n }\n if (!column.filterTemplate) {\n this.writeMethod(column, this.dlgObj.element.querySelector('#' + column.uid + '-flmenu'));\n }\n var args = {\n requestType: events.filterAfterOpen,\n columnName: column.field, columnType: column.type\n };\n var filterModel = 'filterModel';\n args[\"\" + filterModel] = this;\n this.isDialogOpen = true;\n if (!this.isMenuCheck) {\n this.parent.trigger(events.actionComplete, args);\n }\n };\n FilterMenuRenderer.prototype.renderFilterUI = function (target, col) {\n var dlgConetntEle = this.dlgObj.element.querySelector('.e-flmenu-maindiv');\n this.parent.log('column_type_missing', { column: col });\n this.renderOperatorUI(dlgConetntEle, target, col);\n this.renderFlValueUI(dlgConetntEle, target, col);\n };\n FilterMenuRenderer.prototype.renderOperatorUI = function (dlgConetntEle, target, column) {\n this.flMuiObj.renderOperatorUI(dlgConetntEle, target, column, this.dlgObj, this.filterObj.menuOperator);\n };\n FilterMenuRenderer.prototype.renderFlValueUI = function (dlgConetntEle, target, column) {\n var valueDiv = this.parent.createElement('div', { className: 'e-flmenu-valuediv' });\n var fObj = this.filterObj;\n dlgConetntEle.appendChild(valueDiv);\n var instanceofFilterUI = new this.colTypes[column.type](this.parent, this.serviceLocator, this.parent.filterSettings);\n if (column.filterTemplate) {\n var fltrData = {};\n var valueInString = 'value';\n fltrData[column.field] = fltrData[\"\" + valueInString] = fObj.values[column.field];\n if (column.foreignKeyValue) {\n fltrData[column.foreignKeyValue] = fObj.values[column.field];\n fltrData[column.field] = undefined;\n }\n var col = 'column';\n fltrData[\"\" + col] = column;\n var isReactCompiler = this.parent.isReact && typeof (column.filterTemplate) !== 'string';\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n var tempID = this.parent.element.id + column.uid + 'filterTemplate';\n if (isReactCompiler || isReactChild) {\n column.getFilterTemplate()(fltrData, this.parent, 'filterTemplate', tempID, null, null, valueDiv);\n this.parent.renderTemplates();\n }\n else {\n var compElement = column.getFilterTemplate()(fltrData, this.parent, 'filterTemplate', tempID);\n appendChildren(valueDiv, compElement);\n }\n if (this.isMenuCheck) {\n this.menuFilterBase.cBox = this.dlgObj.element.querySelector('.e-checkboxlist.e-fields');\n this.menuFilterBase.wireEvents();\n this.parent.on(events.cBoxFltrComplete, this.actionComplete, this);\n this.menuFilterBase.getAllData();\n }\n }\n else {\n if (!isNullOrUndefined(column.filter) && !isNullOrUndefined(column.filter.ui)\n && !isNullOrUndefined(column.filter.ui.create)) {\n var temp = column.filter.ui.create;\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n }\n temp({\n column: column, target: valueDiv,\n getOptrInstance: this.flMuiObj, dialogObj: this.dlgObj\n });\n }\n else {\n instanceofFilterUI.create({\n column: column, target: valueDiv,\n getOptrInstance: this.flMuiObj, localizeText: this.l10n, dialogObj: this.dlgObj\n });\n }\n }\n };\n FilterMenuRenderer.prototype.writeMethod = function (col, dlgContentEle) {\n var flValue;\n var target = dlgContentEle.querySelector('.e-flmenu-valinput');\n var instanceofFilterUI = new this.colTypes[col.type](this.parent, this.serviceLocator, this.parent.filterSettings);\n var columns = this.filterSettings.columns;\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var column = columns_1[_i];\n if (col.uid === column.uid) {\n flValue = column.value;\n }\n }\n if (!isNullOrUndefined(col.filter) && !isNullOrUndefined(col.filter.ui)\n && !isNullOrUndefined(col.filter.ui.write)) {\n var temp = col.filter.ui.write;\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n }\n temp({ column: col, target: target, parent: this.parent, filteredValue: flValue });\n }\n else {\n instanceofFilterUI.write({ column: col, target: target, parent: this.parent, filteredValue: flValue });\n }\n };\n FilterMenuRenderer.prototype.filterBtnClick = function (col) {\n var flValue;\n var targ = this.dlgObj.element.querySelector('.e-flmenu-valuediv input');\n var flOptrValue = this.flMuiObj.getFlOperator();\n var instanceofFilterUI = new this.colTypes[col.type](this.parent, this.serviceLocator, this.parent.filterSettings);\n if (col.filterTemplate) {\n var element = this.dlgDiv.querySelector('.e-flmenu-valuediv');\n var fltrValue = void 0;\n if (element.children[0].value) {\n fltrValue = element.children[0].value;\n }\n else {\n if (!isNullOrUndefined(element.children[0].ej2_instances)) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n fltrValue = (this.parent.isAngular ? element.children[0] :\n element.querySelector('input')).ej2_instances[0].value;\n }\n else {\n var eControl = element.querySelector('.e-control');\n if (!isNullOrUndefined(eControl)) {\n fltrValue = col.type === 'boolean' ? eControl.checked :\n !isNullOrUndefined(eControl.ej2_instances) ?\n eControl.ej2_instances[0].value :\n eControl.value;\n }\n }\n }\n this.filterObj.filterByColumn(col.field, flOptrValue, fltrValue);\n }\n else {\n if (!isNullOrUndefined(col.filter) &&\n !isNullOrUndefined(col.filter.ui) && !isNullOrUndefined(col.filter.ui.read)) {\n var temp = col.filter.ui.read;\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n }\n // eslint-disable-next-line\n flValue = temp({ element: targ, column: col, operator: flOptrValue, fltrObj: this.filterObj });\n }\n else {\n instanceofFilterUI.read(targ, col, flOptrValue, this.filterObj);\n }\n }\n this.closeDialog();\n if (this.parent.showColumnMenu) {\n this.parent.notify(events.afterFilterColumnMenuClose, {});\n }\n };\n FilterMenuRenderer.prototype.closeResponsiveDialog = function () {\n this.closeDialog();\n };\n FilterMenuRenderer.prototype.clearBtnClick = function (column) {\n this.filterObj.removeFilteredColsByField(column.field);\n this.closeDialog();\n };\n FilterMenuRenderer.prototype.destroy = function () {\n this.closeDialog();\n };\n /**\n * @returns {FilterUI} returns the filterUI\n * @hidden\n */\n FilterMenuRenderer.prototype.getFilterUIInfo = function () {\n return { field: this.col.field, operator: this.flMuiObj.getFlOperator() };\n };\n FilterMenuRenderer.prototype.renderCheckBoxMenu = function () {\n this.isMenuCheck = true;\n this.menuFilterBase.updateModel(this.options);\n this.menuFilterBase.getAndSetChkElem(this.options);\n this.dlgObj.buttons = [{\n click: this.menuFilterBase.btnClick.bind(this.menuFilterBase),\n buttonModel: {\n content: this.menuFilterBase.getLocalizedLabel('FilterButton'),\n cssClass: 'e-primary', isPrimary: true\n }\n },\n {\n click: this.menuFilterBase.btnClick.bind(this.menuFilterBase),\n buttonModel: { cssClass: 'e-flat', content: this.menuFilterBase.getLocalizedLabel('ClearButton') }\n }];\n this.menuFilterBase.dialogObj = this.dlgObj;\n this.menuFilterBase.dlg = this.dlgObj.element;\n this.menuFilterBase.dlg.classList.add('e-menucheckbox');\n this.menuFilterBase.dlg.classList.remove('e-checkboxfilter');\n this.maxHeight = '800px';\n return this.menuFilterBase.sBox.innerHTML;\n };\n FilterMenuRenderer.prototype.actionComplete = function (args) {\n if (this.isMenuCheck) {\n this.parent.trigger(events.actionComplete, args);\n }\n };\n return FilterMenuRenderer;\n}());\nexport { FilterMenuRenderer };\n","import * as events from '../base/constant';\nimport { isActionPrevent } from '../base/util';\nimport { CheckBoxFilterBase } from '../common/checkbox-filter-base';\n/**\n * @hidden\n * `CheckBoxFilter` module is used to handle filtering action.\n */\nvar CheckBoxFilter = /** @class */ (function () {\n /**\n * Constructor for checkbox filtering module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {FilterSettings} filterSettings - specifies the filtersettings\n * @param {ServiceLocator} serviceLocator - specifies the ServiceLocator\n * @hidden\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n function CheckBoxFilter(parent, filterSettings, serviceLocator) {\n this.parent = parent;\n this.isresetFocus = true;\n this.checkBoxBase = new CheckBoxFilterBase(parent);\n this.addEventListener();\n }\n /**\n * To destroy the check box filter.\n *\n * @returns {void}\n * @hidden\n */\n CheckBoxFilter.prototype.destroy = function () {\n this.removeEventListener();\n this.checkBoxBase.closeDialog();\n };\n CheckBoxFilter.prototype.openDialog = function (options) {\n this.checkBoxBase.openDialog(options);\n this.parent.log('column_type_missing', { column: options.column });\n };\n CheckBoxFilter.prototype.closeDialog = function () {\n this.destroy();\n if (this.isresetFocus) {\n this.parent.notify(events.restoreFocus, {});\n }\n };\n CheckBoxFilter.prototype.closeResponsiveDialog = function () {\n this.checkBoxBase.closeDialog();\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} - returns the module name\n * @private\n */\n CheckBoxFilter.prototype.getModuleName = function () {\n return 'checkboxFilter';\n };\n CheckBoxFilter.prototype.actionBegin = function (args) {\n this.parent.trigger(events.actionBegin, args);\n };\n CheckBoxFilter.prototype.actionComplete = function (args) {\n this.parent.trigger(events.actionComplete, args);\n };\n CheckBoxFilter.prototype.actionPrevent = function (args) {\n if (isActionPrevent(this.parent)) {\n this.parent.notify(events.preventBatch, args);\n args.cancel = true;\n }\n };\n CheckBoxFilter.prototype.clearCustomFilter = function (col) {\n this.checkBoxBase.clearFilter(col);\n };\n CheckBoxFilter.prototype.applyCustomFilter = function () {\n this.checkBoxBase.fltrBtnHandler();\n this.checkBoxBase.closeDialog();\n };\n CheckBoxFilter.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.cBoxFltrBegin, this.actionBegin, this);\n this.parent.on(events.cBoxFltrComplete, this.actionComplete, this);\n this.parent.on(events.fltrPrevent, this.actionPrevent, this);\n };\n CheckBoxFilter.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.cBoxFltrBegin, this.actionBegin);\n this.parent.off(events.cBoxFltrComplete, this.actionComplete);\n this.parent.off(events.fltrPrevent, this.actionPrevent);\n };\n return CheckBoxFilter;\n}());\nexport { CheckBoxFilter };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { EventHandler, remove, Browser } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { Query, DataManager, Predicate } from '@syncfusion/ej2-data';\nimport { Dialog } from '@syncfusion/ej2-popups';\nimport { DropDownList, AutoComplete } from '@syncfusion/ej2-dropdowns';\nimport { NumericTextBox } from '@syncfusion/ej2-inputs';\nimport { RadioButton, CheckBox } from '@syncfusion/ej2-buttons';\nimport { distinctStringValues, isComplexField, getComplexFieldID, getCustomDateFormat, applyBiggerTheme, performComplexDataOperation, registerEventHandlers, removeEventHandlers, clearReactVueTemplates } from '../base/util';\nimport { DatePicker, DateTimePicker } from '@syncfusion/ej2-calendars';\nimport { parentsUntil, appendChildren, extend, eventPromise } from '../base/util';\nimport * as events from '../base/constant';\nimport { ContextMenu } from '@syncfusion/ej2-navigations';\nimport { CheckBoxFilterBase } from '../common/checkbox-filter-base';\nimport * as literals from '../base/string-literals';\n/**\n * @hidden\n * `ExcelFilter` module is used to handle filtering action.\n */\nvar ExcelFilterBase = /** @class */ (function (_super) {\n __extends(ExcelFilterBase, _super);\n /**\n * Constructor for excel filtering module\n *\n * @param {IXLFilter} parent - parent details\n * @param {Object} customFltrOperators - operator details\n * @hidden\n */\n function ExcelFilterBase(parent, customFltrOperators) {\n var _this = _super.call(this, parent) || this;\n _this.childRefs = [];\n _this.eventHandlers = {};\n _this.isDevice = false;\n _this.focusedMenuItem = null;\n _this.customFilterOperators = customFltrOperators;\n _this.isExcel = true;\n return _this;\n }\n ExcelFilterBase.prototype.getCMenuDS = function (type, operator) {\n var options = {\n number: ['Equal', 'NotEqual', '', 'LessThan', 'LessThanOrEqual', 'GreaterThan',\n 'GreaterThanOrEqual', 'Between', '', 'CustomFilter'],\n string: ['Equal', 'NotEqual', '', 'StartsWith', 'EndsWith', '', 'Contains', 'NotContains', '', 'CustomFilter']\n };\n options.date = options.number;\n options.datetime = options.number;\n options.dateonly = options.number;\n var model = [];\n for (var i = 0; i < options[\"\" + type].length; i++) {\n if (options[\"\" + type][parseInt(i.toString(), 10)].length) {\n if (operator) {\n model.push({\n text: this.getLocalizedLabel(options[\"\" + type][parseInt(i.toString(), 10)]) + '...',\n iconCss: 'e-icons e-icon-check ' + (operator === options[\"\" + type][parseInt(i.toString(), 10)].toLowerCase() ? '' : 'e-emptyicon')\n });\n }\n else {\n model.push({\n text: this.getLocalizedLabel(options[\"\" + type][parseInt(i.toString(), 10)]) + '...'\n });\n }\n }\n else {\n model.push({ separator: true });\n }\n }\n return model;\n };\n /**\n * To destroy the filter bar.\n *\n * @returns {void}\n * @hidden\n */\n ExcelFilterBase.prototype.destroy = function () {\n if (this.dlg) {\n this.unwireExEvents();\n _super.prototype.closeDialog.call(this);\n }\n if (!this.isDevice && this.menuObj) {\n var li = this.menuObj.element.querySelector('li.e-focused');\n if (!(li && parentsUntil(li, 'e-excel-menu'))) {\n this.destroyCMenu();\n }\n }\n if (this.dlgObj && !this.dlgObj.isDestroyed) {\n this.removeDialog();\n }\n };\n ExcelFilterBase.prototype.createMenu = function (type, isFiltered, isCheckIcon, eleOptions) {\n var options = { string: 'TextFilter', date: 'DateFilter', dateonly: 'DateFilter', datetime: 'DateTimeFilter', number: 'NumberFilter' };\n this.menu = this.parent.createElement('div', { className: 'e-contextmenu-wrapper' });\n if (this.parent.enableRtl) {\n this.menu.classList.add('e-rtl');\n }\n else {\n this.menu.classList.remove('e-rtl');\n }\n if (this.parent.cssClass) {\n this.menu.classList.add(this.parent.cssClass);\n }\n var ul = this.parent.createElement('ul');\n var icon = isFiltered ? 'e-excl-filter-icon e-filtered' : 'e-excl-filter-icon';\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this.parent.allowSorting && this.parent.getModuleName() === 'grid'\n && !this.options.isResponsiveFilter) {\n var hdrele = this.parent.getColumnHeaderByUid(eleOptions.uid).getAttribute('aria-sort');\n var colIsSort = this.parent.getColumnByField(eleOptions.field).allowSorting;\n var isAsc = (!colIsSort || hdrele === 'ascending') ? 'e-disabled e-excel-ascending' : 'e-excel-ascending';\n var isDesc = (!colIsSort || hdrele === 'descending') ? 'e-disabled e-excel-descending' : 'e-excel-descending';\n var ascName = (type === 'string') ? this.getLocalizedLabel('SortAtoZ') : (type === 'datetime' || type === 'date') ?\n this.getLocalizedLabel('SortByOldest') : this.getLocalizedLabel('SortSmallestToLargest');\n var descName = (type === 'string') ? this.getLocalizedLabel('SortZtoA') : (type === 'datetime' || type === 'date') ?\n this.getLocalizedLabel('SortByNewest') : this.getLocalizedLabel('SortLargestToSmallest');\n ul.appendChild(this.createMenuElem(ascName, isAsc, 'e-sortascending'));\n ul.appendChild(this.createMenuElem(descName, isDesc, 'e-sortdescending'));\n var separator = this.parent.createElement('li', { className: 'e-separator e-menu-item e-excel-separator' });\n ul.appendChild(separator);\n }\n if (!this.options.isResponsiveFilter) {\n ul.appendChild(this.createMenuElem(this.getLocalizedLabel('ClearFilter'), isFiltered ? '' : 'e-disabled', icon));\n }\n if (type !== 'boolean') {\n ul.appendChild(this.createMenuElem(this.getLocalizedLabel(options[\"\" + type]), 'e-submenu', isCheckIcon && this.ensureTextFilter() ? 'e-icon-check' : icon + ' e-emptyicon', true));\n }\n this.menu.appendChild(ul);\n this.parent.notify(events.beforeFltrcMenuOpen, { element: this.menu });\n this.parent.notify(events.refreshCustomFilterClearBtn, { isFiltered: isFiltered });\n };\n ExcelFilterBase.prototype.createMenuElem = function (val, className, iconName, isSubMenu) {\n var li = this.parent.createElement('li', { className: className + ' e-menu-item' });\n li.innerHTML = val;\n li.tabIndex = li.classList.contains('e-disabled') ? -1 : 0;\n li.insertBefore(this.parent.createElement('span', { className: 'e-menu-icon e-icons ' + iconName, attrs: { 'aria-hidden': 'true' } }), li.firstChild);\n if (isSubMenu) {\n li.appendChild(this.parent.createElement('span', { className: 'e-icons e-caret' }));\n }\n return li;\n };\n ExcelFilterBase.prototype.wireExEvents = function () {\n if (!Browser.isDevice) {\n EventHandler.add(this.dlg, 'mouseover', this.hoverHandler, this);\n }\n EventHandler.add(this.dlg, 'click', this.clickExHandler, this);\n EventHandler.add(this.dlg, 'keyup', this.keyUp, this);\n EventHandler.add(this.dlg, 'keydown', this.keyDown, this);\n };\n ExcelFilterBase.prototype.unwireExEvents = function () {\n if (!Browser.isDevice) {\n EventHandler.remove(this.dlg, 'mouseover', this.hoverHandler);\n }\n EventHandler.remove(this.dlg, 'click', this.clickExHandler);\n EventHandler.remove(this.dlg, 'keyup', this.keyUp);\n EventHandler.remove(this.dlg, 'keydown', this.keyDown);\n };\n ExcelFilterBase.prototype.clickExHandler = function (e) {\n var options = { string: 'TextFilter', date: 'DateFilter', datetime: 'DateTimeFilter', number: 'NumberFilter' };\n var menuItem = parentsUntil(e.target, 'e-menu-item');\n if (menuItem) {\n if (this.getLocalizedLabel('ClearFilter') === menuItem.innerText.trim()) {\n this.clearFilter();\n this.closeDialog();\n }\n else if ((this.options.isResponsiveFilter || Browser.isDevice)\n && this.getLocalizedLabel(options[this.options.type]) === menuItem.innerText.trim()) {\n this.hoverHandler(e);\n }\n }\n };\n ExcelFilterBase.prototype.focusNextOrPrevElement = function (e, focusableElements, focusClassName) {\n var nextIndex = (e.key === 'ArrowUp' || (e.key === 'Tab' && e.shiftKey)) ? focusableElements.indexOf(document.activeElement) - 1\n : focusableElements.indexOf(document.activeElement) + 1;\n var nextElement = focusableElements[((nextIndex + focusableElements.length) % focusableElements.length)];\n // Set focus on the next / previous element\n if (nextElement) {\n nextElement.focus();\n var focusClass = nextElement.classList.contains('e-chk-hidden') ? 'e-chkfocus' : focusClassName;\n var target = nextElement.classList.contains('e-chk-hidden') ? parentsUntil(nextElement, 'e-ftrchk') : parentsUntil(nextElement, 'e-menu-item');\n this.excelSetFocus(target, focusClass);\n }\n };\n ExcelFilterBase.prototype.keyUp = function (e) {\n if ((e.key === 'Tab' && e.shiftKey) || e.key === 'Tab') {\n var focusClass = e.target.classList.contains('e-chk-hidden') ? 'e-chkfocus' : 'e-menufocus';\n var target = e.target.classList.contains('e-menu-item')\n ? parentsUntil(e.target, 'e-menu-item') : parentsUntil(e.target, 'e-ftrchk');\n this.excelSetFocus(target, focusClass);\n }\n else if ((e.key === 'ArrowUp' || e.key === 'ArrowDown') && !e.altKey) {\n e.preventDefault();\n var focusableElements = Array.from(this.dlg.querySelectorAll('input, button, [tabindex]:not([tabindex=\"-1\"]), .e-menu-item:not(.e-disabled):not(.e-separator)'));\n this.focusNextOrPrevElement(e, focusableElements, 'e-menufocus');\n }\n else if ((e.key === 'Enter' || e.code === 'ArrowRight') && e.target.classList.contains('e-menu-item')) {\n e.preventDefault();\n e.target.click();\n if (e.target.classList.contains('e-submenu')) {\n this.hoverHandler(e);\n this.menuObj.element.querySelector('.e-menu-item').focus();\n this.excelSetFocus(parentsUntil(this.menuObj.element.querySelector('.e-menu-item'), 'e-menu-item'), 'e-focused');\n this.focusedMenuItem = this.menuObj.element.querySelector('.e-menu-item');\n }\n }\n };\n ExcelFilterBase.prototype.keyDown = function (e) {\n //prevented up and down arrow key press default functionality to prevent the browser scroll when performing keyboard navigation in excel filter element.\n if (e.key === 'ArrowUp' || e.key === 'ArrowDown') {\n e.preventDefault();\n }\n };\n ExcelFilterBase.prototype.excelSetFocus = function (elem, className) {\n var prevElem = document.querySelector('.' + className);\n if (prevElem) {\n prevElem.classList.remove(className);\n }\n if (elem) {\n elem.classList.add(className);\n }\n };\n ExcelFilterBase.prototype.destroyCMenu = function () {\n this.isCMenuOpen = false;\n if (this.menuObj && !this.menuObj.isDestroyed) {\n this.menuObj.destroy();\n EventHandler.remove(this.menuObj.element, 'keydown', this.contextKeyDownHandler);\n remove(this.cmenu);\n this.parent.notify(events.renderResponsiveCmenu, { target: null, header: '', isOpen: false, col: this.options.column });\n }\n };\n ExcelFilterBase.prototype.hoverHandler = function (e) {\n if (this.options.isResponsiveFilter && e.type === 'mouseover') {\n return;\n }\n var target = e.target.querySelector('.e-contextmenu');\n var li = parentsUntil(e.target, 'e-menu-item');\n var focused = this.menu.querySelector('.e-focused');\n var isSubMenu;\n if (focused) {\n focused.classList.remove('e-focused');\n }\n if (li) {\n li.classList.add('e-focused');\n isSubMenu = li.classList.contains('e-submenu');\n }\n if (target) {\n return;\n }\n if (!isSubMenu) {\n var submenu = this.menu.querySelector('.e-submenu');\n if (!isNullOrUndefined(submenu)) {\n submenu.classList.remove('e-selected');\n }\n this.destroyCMenu();\n }\n var selectedMenu = this.ensureTextFilter();\n if (!this.isCMenuOpen && isSubMenu) {\n li.classList.add('e-selected');\n this.isCMenuOpen = true;\n var menuOptions = {\n items: this.getCMenuDS(this.options.type, selectedMenu ? selectedMenu.replace(/\\s/g, '') : undefined),\n select: this.selectHandler.bind(this),\n onClose: this.destroyCMenu.bind(this),\n enableRtl: this.parent.enableRtl,\n animationSettings: { effect: 'None' },\n beforeClose: this.preventClose.bind(this),\n cssClass: this.options.isResponsiveFilter && this.parent.cssClass ?\n 'e-res-contextmenu-wrapper' + ' ' + this.parent.cssClass : this.options.isResponsiveFilter ?\n 'e-res-contextmenu-wrapper' : this.parent.cssClass ? this.parent.cssClass : ''\n };\n this.parent.element.appendChild(this.cmenu);\n this.menuObj = new ContextMenu(menuOptions, this.cmenu);\n EventHandler.add(this.menuObj.element, 'keydown', this.contextKeyDownHandler, this);\n var client = this.menu.querySelector('.e-submenu').getBoundingClientRect();\n var pos = { top: 0, left: 0 };\n if (this.options.isResponsiveFilter) {\n var options = { string: 'TextFilter', date: 'DateFilter', datetime: 'DateTimeFilter', number: 'NumberFilter' };\n var content = document.querySelector('.e-responsive-dialog > .e-dlg-header-content');\n var height = content.offsetHeight + 4;\n this.menuObj.element.style.height = 'calc(100% - ' + height + 'px)';\n this.menuObj['open'](height, 0, document.body);\n var header = this.getLocalizedLabel(options[this.options.type]);\n this.parent.notify(events.renderResponsiveCmenu, {\n target: this.menuObj.element.parentElement, header: header, isOpen: true\n });\n }\n else {\n if (Browser.isDevice) {\n this.isDevice = true;\n var contextRect = this.getContextBounds();\n pos.top = (window.innerHeight - contextRect.height) / 2;\n pos.left = (window.innerWidth - contextRect.width) / 2;\n this.closeDialog();\n this.isDevice = false;\n }\n else {\n pos.top = Browser.isIE ? window.pageYOffset + client.top : window.scrollY + client.top;\n pos.left = this.getCMenuYPosition(this.dlg);\n }\n this.menuObj['open'](pos.top, pos.left, e.target);\n }\n applyBiggerTheme(this.parent.element, this.menuObj.element.parentElement);\n }\n };\n ExcelFilterBase.prototype.contextKeyDownHandler = function (e) {\n if ((e.key === 'Tab' && e.shiftKey) || e.key === 'Tab') {\n e.preventDefault();\n var focusableElements = Array.from(this.menuObj.element.querySelectorAll('[tabindex]:not([tabindex=\"-1\"]), .e-menu-item:not(.e-disabled):not(.e-separator)'));\n // Focus the next / previous context menu item\n this.focusNextOrPrevElement(e, focusableElements, 'e-focused');\n }\n else if (e.key === 'ArrowLeft' || e.key === 'Escape') {\n e.preventDefault();\n this.menuObj.close();\n this.focusedMenuItem = null;\n document.querySelector('.e-submenu.e-menu-item').classList.remove('e-selected');\n document.querySelector('.e-submenu.e-menu-item').focus();\n }\n };\n ExcelFilterBase.prototype.ensureTextFilter = function () {\n var selectedMenu;\n var predicates = this.existingPredicate[this.options.field];\n if (predicates && predicates.length === 2) {\n if (predicates[0].operator === 'greaterthanorequal' && predicates[1].operator === 'lessthanorequal') {\n selectedMenu = 'between';\n }\n else {\n selectedMenu = 'customfilter';\n }\n }\n else {\n if (predicates && predicates.length === 1) {\n this.optrData = this.customFilterOperators[this.options.type + 'Operator'];\n selectedMenu = predicates[0].operator;\n }\n }\n return selectedMenu;\n };\n ExcelFilterBase.prototype.preventClose = function (args) {\n if (this.options && this.options.isResponsiveFilter && args.event) {\n var target = args.event.target;\n var isFilterBack = target.classList.contains('e-resfilterback')\n || target.classList.contains('e-res-back-btn') || target.classList.contains('e-menu-item');\n args.cancel = !isFilterBack;\n }\n else {\n if (args.event instanceof MouseEvent && args.event.target.classList.contains('e-submenu')) {\n args.cancel = true;\n }\n }\n };\n ExcelFilterBase.prototype.getContextBounds = function () {\n this.menuObj.element.style.display = 'block';\n return this.menuObj.element.getBoundingClientRect();\n };\n ExcelFilterBase.prototype.getCMenuYPosition = function (target) {\n var contextWidth = this.getContextBounds().width;\n var targetPosition = target.getBoundingClientRect();\n var leftPos = targetPosition.right + contextWidth - this.parent.element.clientWidth;\n var targetBorder = target.offsetWidth - target.clientWidth;\n targetBorder = targetBorder ? targetBorder + 1 : 0;\n return (leftPos < 1) ? (targetPosition.right + 1 - targetBorder) : (targetPosition.left - contextWidth - 1 + targetBorder);\n };\n ExcelFilterBase.prototype.openDialog = function (options) {\n var _this = this;\n this.updateModel(options);\n this.getAndSetChkElem(options);\n this.showDialog(options);\n if (options.cancel) {\n return;\n }\n this.dialogObj.dataBind();\n var filterLength = (this.existingPredicate[options.field] && this.existingPredicate[options.field].length) ||\n this.options.filteredColumns.filter(function (col) {\n return _this.options.field === col.field;\n }).length;\n this.createMenu(options.type, filterLength > 0, (filterLength === 1 || filterLength === 2), options);\n this.dlg.insertBefore(this.menu, this.dlg.firstChild);\n this.dlg.classList.add('e-excelfilter');\n if (this.parent.enableRtl) {\n this.dlg.classList.add('e-rtl');\n }\n this.dlg.classList.remove('e-checkboxfilter');\n this.cmenu = this.parent.createElement('ul', { className: 'e-excel-menu' });\n if (options.column.showColumnMenu) {\n this.parent.notify(events.filterDialogCreated, {});\n }\n this.wireExEvents();\n };\n ExcelFilterBase.prototype.closeDialog = function () {\n this.destroy();\n };\n ExcelFilterBase.prototype.selectHandler = function (e) {\n if (e.item) {\n this.parent.notify(events.filterCmenuSelect, {});\n this.menuItem = e.item;\n this.closeDialog();\n this.renderDialogue(e);\n }\n };\n /**\n * @hidden\n * @param {MenuEventArgs} e - event args\n * @returns {void}\n */\n ExcelFilterBase.prototype.renderDialogue = function (e) {\n var _this = this;\n var target = e ? e.element : undefined;\n var column = this.options.field;\n var isComplex = !isNullOrUndefined(column) && isComplexField(column);\n var complexFieldName = !isNullOrUndefined(column) && getComplexFieldID(column);\n var mainDiv = this.parent.createElement('div', {\n className: 'e-xlfl-maindiv',\n id: isComplex ? complexFieldName + '-xlflmenu' : column + '-xlflmenu'\n });\n this.dlgDiv = this.parent.createElement('div', {\n className: 'e-xlflmenu',\n id: isComplex ? complexFieldName + '-xlfldlg' : column + '-xlfldlg'\n });\n if (this.options.isResponsiveFilter) {\n var responsiveCnt = document.querySelector('.e-resfilter > .e-dlg-content > .e-xl-customfilterdiv');\n responsiveCnt.appendChild(this.dlgDiv);\n }\n else {\n this.parent.element.appendChild(this.dlgDiv);\n }\n this.dlgObj = new Dialog({\n header: this.getLocalizedLabel('CustomFilter'),\n isModal: true,\n overlayClick: this.removeDialog.bind(this),\n showCloseIcon: true,\n locale: this.parent.locale,\n closeOnEscape: true,\n target: document.body,\n // target: this.parent.element,\n visible: false,\n enableRtl: this.parent.enableRtl,\n open: function () {\n var rows = [].slice.call(_this.dlgObj.element.querySelectorAll('table.e-xlfl-table tr.e-xlfl-fields'));\n for (var i = 0; i < rows.length; i++) {\n var valInput = rows[i].children[1].querySelector('.e-control');\n var dropDownList = rows[i]\n .querySelector('.e-dropdownlist.e-control')['ej2_instances'][0];\n if (dropDownList.value === 'isempty' || dropDownList.value === 'isnotempty' ||\n dropDownList.value === 'isnull' || dropDownList.value === 'isnotnull') {\n valInput['ej2_instances'][0]['enabled'] = false;\n }\n else if (valInput && !isNullOrUndefined(valInput.getAttribute('disabled'))) {\n valInput['ej2_instances'][0]['enabled'] = true;\n }\n }\n var row = _this.dlgObj.element.querySelector('table.e-xlfl-table>tr');\n if (_this.options.column.filterTemplate) {\n var templateField_1 = isComplexField(_this.options.column.field) ?\n getComplexFieldID(_this.options.column.field) : _this.options.column.field;\n var isReactCompiler = _this.parent.isReact && typeof (_this.options.column.filterTemplate) !== 'string';\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var isReactChild = _this.parent.parentDetails && _this.parent.parentDetails.parentInstObj &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n _this.parent.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild) {\n _this.parent.renderTemplates(function () {\n row.querySelector('#' + templateField_1 + '-xlfl-frstvalue').focus();\n });\n }\n else {\n row.querySelector('#' + templateField_1 + '-xlfl-frstvalue').focus();\n }\n }\n else {\n //(row.cells[1].querySelector('input:not([type=hidden])') as HTMLElement).focus();\n }\n },\n close: this.removeDialog.bind(this),\n created: this.createdDialog.bind(this, target, column),\n buttons: [{\n click: this.filterBtnClick.bind(this, column),\n buttonModel: {\n content: this.getLocalizedLabel('OKButton'), isPrimary: true,\n cssClass: this.parent.cssClass ? 'e-xlfl-okbtn' + ' ' + this.parent.cssClass : 'e-xlfl-okbtn'\n }\n },\n {\n click: this.removeDialog.bind(this),\n buttonModel: { content: this.getLocalizedLabel('CancelButton'),\n cssClass: this.parent.cssClass ? 'e-xlfl-cancelbtn' + ' ' + this.parent.cssClass : 'e-xlfl-cancelbtn' }\n }],\n content: mainDiv,\n width: 430,\n animationSettings: { effect: 'None' },\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n var isStringTemplate = 'isStringTemplate';\n this.dlgObj[\"\" + isStringTemplate] = true;\n this.renderResponsiveDialog();\n this.dlgDiv.setAttribute('aria-label', this.getLocalizedLabel('CustomFilterDialogARIA'));\n this.childRefs.push(this.dlgObj);\n this.dlgObj.appendTo(this.dlgDiv);\n };\n ExcelFilterBase.prototype.renderResponsiveDialog = function () {\n if (this.options.isResponsiveFilter) {\n var rowResponsiveDlg = document.querySelector('.e-row-responsive-filter');\n if (rowResponsiveDlg) {\n rowResponsiveDlg.classList.remove('e-row-responsive-filter');\n }\n this.dlgObj.buttons = [{}];\n this.dlgObj.header = undefined;\n this.dlgObj.position = { X: '', Y: '' };\n this.dlgObj.target = document.querySelector('.e-resfilter > .e-dlg-content > .e-xl-customfilterdiv');\n this.dlgObj.width = '100%';\n this.dlgObj.isModal = false;\n this.dlgObj.showCloseIcon = false;\n }\n };\n /**\n * @hidden\n * @returns {void}\n */\n ExcelFilterBase.prototype.removeDialog = function () {\n this.parent.notify(events.customFilterClose, {});\n if ((this.parent.isReact || this.parent.isVue) && this.parent.destroyTemplate !== undefined) {\n clearReactVueTemplates(this.parent, ['filterTemplate']);\n }\n this.removeObjects(this.childRefs);\n remove(this.dlgDiv);\n this.parent.notify(events.filterDialogClose, {});\n };\n ExcelFilterBase.prototype.createdDialog = function (target, column) {\n this.renderCustomFilter(target, column);\n this.dlgObj.element.style.left = '0px';\n if (!this.options.isResponsiveFilter) {\n this.dlgObj.element.style.top = '0px';\n }\n else {\n var content = document.querySelector('.e-responsive-dialog > .e-dlg-header-content');\n var height = content.offsetHeight + 4;\n this.dlgObj.element.style.top = height + 'px';\n }\n if (!this.options.isResponsiveFilter && Browser.isDevice && window.innerWidth < 440) {\n this.dlgObj.element.style.width = '90%';\n }\n this.parent.notify(events.beforeCustomFilterOpen, { column: column, dialog: this.dialogObj });\n this.dlgObj.show();\n applyBiggerTheme(this.parent.element, this.dlgObj.element.parentElement);\n };\n ExcelFilterBase.prototype.renderCustomFilter = function (target, column) {\n var dlgConetntEle = this.dlgObj.element.querySelector('.e-xlfl-maindiv');\n var dlgFields = this.parent.createElement('div', { innerHTML: this.getLocalizedLabel('ShowRowsWhere'), className: 'e-xlfl-dlgfields' });\n dlgConetntEle.appendChild(dlgFields);\n //column name\n var fieldSet = this.parent.createElement('div', { innerHTML: this.options.displayName, className: 'e-xlfl-fieldset' });\n dlgConetntEle.appendChild(fieldSet);\n this.renderFilterUI(column, dlgConetntEle);\n };\n /**\n * @hidden\n * @param {string} col - Defines column details\n * @returns {void}\n */\n ExcelFilterBase.prototype.filterBtnClick = function (col) {\n var isComplex = !isNullOrUndefined(col) && isComplexField(col);\n var complexFieldName = !isNullOrUndefined(col) && getComplexFieldID(col);\n var colValue = isComplex ? complexFieldName : col;\n var fValue = this.dlgDiv.querySelector('#' + colValue + '-xlfl-frstvalue').ej2_instances[0];\n var fOperator = this.dlgDiv.querySelector('#' + colValue + '-xlfl-frstoptr').ej2_instances[0];\n var sValue = this.dlgDiv.querySelector('#' + colValue + '-xlfl-secndvalue').ej2_instances[0];\n var sOperator = this.dlgDiv.querySelector('#' + colValue + '-xlfl-secndoptr').ej2_instances[0];\n var checkBoxValue;\n if (this.options.type === 'string') {\n var checkBox = this.dlgDiv.querySelector('#' + colValue + '-xlflmtcase').ej2_instances[0];\n checkBoxValue = checkBox.checked;\n }\n var andRadio = this.dlgDiv.querySelector('#' + colValue + 'e-xlfl-frstpredicate').ej2_instances[0];\n var predicate = (andRadio.checked ? 'and' : 'or');\n if (sValue.value === null) {\n predicate = 'or';\n }\n this.filterByColumn(this.options.field, fOperator.value, fValue.value, predicate, checkBoxValue, this.options.ignoreAccent, sOperator.value, sValue.value);\n this.removeDialog();\n };\n /**\n * @hidden\n * Filters grid row by column name with given options.\n *\n * @param {string} fieldName - Defines the field name of the filter column.\n * @param {string} firstOperator - Defines the first operator by how to filter records.\n * @param {string | number | Date | boolean} firstValue - Defines the first value which is used to filter records.\n * @param {string} predicate - Defines the relationship between one filter query with another by using AND or OR predicate.\n * @param {boolean} matchCase - If ignore case set to true, then filter records with exact match or else\n * filter records with case insensitive(uppercase and lowercase letters treated as same).\n * @param {boolean} ignoreAccent - If ignoreAccent set to true, then ignores the diacritic characters or accents when filtering.\n * @param {string} secondOperator - Defines the second operator by how to filter records.\n * @param {string | number | Date | boolean} secondValue - Defines the first value which is used to filter records.\n * @returns {void}\n */\n ExcelFilterBase.prototype.filterByColumn = function (fieldName, firstOperator, firstValue, predicate, matchCase, ignoreAccent, secondOperator, secondValue) {\n var col = this.parent.getColumnByField ? this.parent.getColumnByField(fieldName) : this.options.column;\n var field = this.isForeignColumn(col) ? col.foreignKeyValue : fieldName;\n var fColl = [];\n var mPredicate;\n var arg = {\n instance: this, handler: this.filterByColumn, arg1: fieldName, arg2: firstOperator, arg3: firstValue, arg4: predicate,\n arg5: matchCase, arg6: ignoreAccent, arg7: secondOperator, arg8: secondValue, cancel: false\n };\n this.parent.notify(events.fltrPrevent, arg);\n if (arg.cancel) {\n return;\n }\n fColl.push({\n field: field,\n predicate: predicate,\n matchCase: matchCase,\n ignoreAccent: ignoreAccent,\n operator: firstOperator,\n value: arg.arg3,\n type: this.options.type\n });\n mPredicate = new Predicate(field, firstOperator.toLowerCase(), arg.arg3, !matchCase, ignoreAccent);\n if (!isNullOrUndefined(secondValue) && !isNullOrUndefined(secondOperator)) {\n fColl.push({\n field: field,\n predicate: predicate,\n matchCase: matchCase,\n ignoreAccent: ignoreAccent,\n operator: secondOperator,\n value: arg.arg8,\n type: this.options.type\n });\n mPredicate = mPredicate[\"\" + predicate](field, secondOperator.toLowerCase(), secondValue, !matchCase, ignoreAccent);\n }\n var args = {\n action: 'filtering', filterCollection: fColl, field: this.options.field,\n ejpredicate: mPredicate, actualPredicate: fColl\n };\n if (this.isForeignColumn(col)) {\n this.foreignKeyFilter(args, fColl, mPredicate);\n }\n else {\n this.options.handler(args);\n }\n };\n // eslint-disable-next-line max-len\n ExcelFilterBase.prototype.renderOperatorUI = function (column, table, elementID, predicates, isFirst) {\n var fieldElement = this.parent.createElement('tr', { className: 'e-xlfl-fields', attrs: { role: 'row' } });\n table.appendChild(fieldElement);\n var xlfloptr = this.parent.createElement('td', { className: 'e-xlfl-optr' });\n fieldElement.appendChild(xlfloptr);\n var optrDiv = this.parent.createElement('div', { className: 'e-xlfl-optrdiv' });\n var isComplex = !isNullOrUndefined(column) && isComplexField(column);\n var complexFieldName = !isNullOrUndefined(column) && getComplexFieldID(column);\n var optrInput = this.parent\n .createElement('input', { id: isComplex ? complexFieldName + elementID : column + elementID });\n optrDiv.appendChild(optrInput);\n xlfloptr.appendChild(optrDiv);\n var optr = this.options.type + 'Operator';\n var dropDatasource = this.customFilterOperators[\"\" + optr];\n this.optrData = dropDatasource;\n var selectedValue = this.dropSelectedVal(this.options.column, predicates, isFirst);\n //Trailing three dots are sliced.\n var menuText = '';\n if (this.menuItem) {\n menuText = this.menuItem.text.slice(0, -3);\n if (menuText !== this.getLocalizedLabel('CustomFilter')) {\n selectedValue = isFirst ? menuText : undefined;\n }\n if (menuText === this.getLocalizedLabel('Between')) {\n selectedValue = this.getLocalizedLabel(isFirst ? 'GreaterThanOrEqual' : 'LessThanOrEqual');\n }\n }\n var col = this.options.column;\n var dropOptr = new DropDownList(extend({\n dataSource: dropDatasource,\n fields: { text: 'text', value: 'value' },\n text: selectedValue,\n enableRtl: this.parent.enableRtl,\n cssClass: this.parent.cssClass ? this.parent.cssClass : null\n }, col.filter.params));\n this.childRefs.push(dropOptr);\n var evt = { 'open': this.dropDownOpen.bind(this), 'change': this.dropDownValueChange.bind(this) };\n registerEventHandlers(optrInput.id, [literals.open, literals.change], evt, this);\n dropOptr.addEventListener(literals['open'], this.eventHandlers[optrInput.id][literals.open]);\n dropOptr.addEventListener(literals.change, this.eventHandlers[optrInput.id][literals.change]);\n dropOptr.appendTo(optrInput);\n var operator = this.getSelectedValue(selectedValue);\n return { fieldElement: fieldElement, operator: operator };\n };\n ExcelFilterBase.prototype.removeHandlersFromComponent = function (component) {\n if (component.element.classList.contains('e-dropdownlist')) {\n removeEventHandlers(component, [literals.open, literals.change], this);\n }\n else if (component.element.classList.contains('e-autocomplete')) {\n removeEventHandlers(component, [events.actionComplete, literals.focus], this);\n }\n };\n ExcelFilterBase.prototype.dropDownOpen = function (args) {\n args.popup.element.style.zIndex = (this.dialogObj.zIndex + 1).toString();\n };\n ExcelFilterBase.prototype.dropDownValueChange = function (args) {\n if (args.element.id.includes('-xlfl-frstoptr')) {\n this.firstOperator = args.value.toString();\n }\n else {\n this.secondOperator = args.value.toString();\n }\n var valInput = args.element.closest('.e-xlfl-fields').children[1].querySelector('.e-control');\n var dropDownList = args.element['ej2_instances'][0];\n if (dropDownList.value === 'isempty' || dropDownList.value === 'isnotempty' ||\n dropDownList.value === 'isnull' || dropDownList.value === 'isnotnull') {\n valInput['ej2_instances'][0]['enabled'] = false;\n }\n else if (!isNullOrUndefined(valInput.getAttribute('disabled'))) {\n valInput['ej2_instances'][0]['enabled'] = true;\n }\n };\n /**\n * @hidden\n * @returns {FilterUI} returns filter UI\n */\n ExcelFilterBase.prototype.getFilterUIInfo = function () {\n return { firstOperator: this.firstOperator, secondOperator: this.secondOperator, field: this.options.field };\n };\n ExcelFilterBase.prototype.getSelectedValue = function (text) {\n var selectedField = new DataManager(this.optrData).executeLocal(new Query().where('text', 'equal', text));\n return !isNullOrUndefined(selectedField[0]) ? selectedField[0].value : '';\n };\n ExcelFilterBase.prototype.dropSelectedVal = function (col, predicates, isFirst) {\n var operator;\n if (predicates && predicates.length > 0) {\n operator = predicates.length === 2 ?\n (isFirst ? predicates[0].operator : predicates[1].operator) :\n (isFirst ? predicates[0].operator : undefined);\n }\n else if (isFirst && col.type === 'string' && !col.filter.operator) {\n operator = 'startswith';\n }\n else {\n operator = isFirst ? col.filter.operator || 'equal' : undefined;\n }\n return this.getSelectedText(operator);\n };\n ExcelFilterBase.prototype.getSelectedText = function (operator) {\n var selectedField = new DataManager(this.optrData).executeLocal(new Query().where('value', 'equal', operator));\n return !isNullOrUndefined(selectedField[0]) ? selectedField[0].text : '';\n };\n ExcelFilterBase.prototype.renderFilterUI = function (column, dlgConetntEle) {\n var predicates = this.existingPredicate[\"\" + column];\n var table = this.parent.createElement('table', { className: 'e-xlfl-table', attrs: { role: 'grid' } });\n dlgConetntEle.appendChild(table);\n var colGroup = this.parent.createElement(literals.colGroup);\n colGroup.innerHTML = '<col style=\"width: 50%\"></col><col style=\"width: 50%\"></col>';\n table.appendChild(colGroup);\n //Renders first dropdown\n var optr = this.renderOperatorUI(column, table, '-xlfl-frstoptr', predicates, true);\n this.firstOperator = optr.operator;\n //Renders first value\n this.renderFlValueUI(column, optr, '-xlfl-frstvalue', predicates, true);\n var predicate = this.parent.createElement('tr', { className: 'e-xlfl-predicate', attrs: { role: 'row' } });\n table.appendChild(predicate);\n //Renders first radion button\n this.renderRadioButton(column, predicate, predicates);\n //Renders second dropdown\n optr = this.renderOperatorUI(column, table, '-xlfl-secndoptr', predicates, false);\n this.secondOperator = optr.operator;\n //Renders second text box\n this.renderFlValueUI(column, optr, '-xlfl-secndvalue', predicates, false);\n };\n ExcelFilterBase.prototype.renderRadioButton = function (column, tr, predicates) {\n var td = this.parent.createElement('td', { className: 'e-xlfl-radio', attrs: { 'colSpan': '2' } });\n tr.appendChild(td);\n var radioDiv = this.parent\n .createElement('div', { className: 'e-xlfl-radiodiv', attrs: { 'style': 'display: inline-block' } });\n var isComplex = !isNullOrUndefined(column) && isComplexField(column);\n var complexFieldName = !isNullOrUndefined(column) && getComplexFieldID(column);\n var frstpredicate = this.parent.createElement('input', { id: isComplex ? complexFieldName + 'e-xlfl-frstpredicate' : column + 'e-xlfl-frstpredicate', attrs: { 'type': 'radio' } });\n var secndpredicate = this.parent.createElement('input', { id: isComplex ? complexFieldName + 'e-xlfl-secndpredicate' : column + 'e-xlfl-secndpredicate', attrs: { 'type': 'radio' } });\n //appends into div\n radioDiv.appendChild(frstpredicate);\n radioDiv.appendChild(secndpredicate);\n td.appendChild(radioDiv);\n if (this.options.type === 'string') {\n this.renderMatchCase(column, tr, td, '-xlflmtcase', predicates);\n }\n // Initialize AND RadioButton component.\n var andRadio = new RadioButton({\n label: this.getLocalizedLabel('AND'),\n name: 'default', checked: true,\n enableRtl: this.parent.enableRtl,\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n this.childRefs.push(andRadio);\n // Initialize OR RadioButton component.\n var orRadio = new RadioButton({\n label: this.getLocalizedLabel('OR'),\n name: 'default',\n enableRtl: this.parent.enableRtl,\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n this.childRefs.push(orRadio);\n var flValue = predicates && predicates.length === 2 ? predicates[1].predicate : 'and';\n if (flValue === 'and') {\n andRadio.checked = true;\n orRadio.checked = false;\n }\n else {\n orRadio.checked = true;\n andRadio.checked = false;\n }\n // Render initialized RadioButton.\n andRadio.appendTo(frstpredicate);\n orRadio.appendTo(secndpredicate);\n andRadio.element.nextElementSibling.classList.add('e-xlfl-radio-and');\n orRadio.element.nextElementSibling.classList.add('e-xlfl-radio-or');\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ExcelFilterBase.prototype.removeObjects = function (elements) {\n for (var _i = 0, elements_1 = elements; _i < elements_1.length; _i++) {\n var obj = elements_1[_i];\n if (obj && !obj.isDestroyed) {\n this.removeHandlersFromComponent(obj);\n obj.destroy();\n }\n }\n };\n // eslint-disable-next-line max-len\n ExcelFilterBase.prototype.renderFlValueUI = function (column, optr, elementId, predicates, isFirst) {\n var value = this.parent.createElement('td', { className: 'e-xlfl-value' });\n optr.fieldElement.appendChild(value);\n var isComplex = !isNullOrUndefined(column) && isComplexField(column);\n var complexFieldName = !isNullOrUndefined(column) && getComplexFieldID(column);\n var valueDiv = this.parent.createElement('div', { className: 'e-xlfl-valuediv' });\n var isFilteredCol = this.options.filteredColumns.some(function (col) { return column === col.field; });\n var fltrPredicates = this.options.filteredColumns.filter(function (col) { return col.field === column; });\n if (this.options.column.filterTemplate) {\n var data = {};\n var columnObj = this.options.column;\n if (isFilteredCol && elementId) {\n data = this.getExcelFilterData(elementId, data, columnObj, predicates, fltrPredicates);\n }\n var isReactCompiler = this.parent.isReact && typeof (this.options.column.filterTemplate) !== 'string';\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.parent.parentDetails.parentInstObj.isReact;\n var tempID = this.parent.element.id + columnObj.uid + 'filterTemplate';\n if (isReactCompiler || isReactChild) {\n this.options.column.getFilterTemplate()(data, this.parent, 'filterTemplate', tempID, null, null, valueDiv);\n }\n else {\n var element = this.options.column.getFilterTemplate()(data, this.parent, 'filterTemplate', tempID);\n appendChildren(valueDiv, element);\n }\n if (isReactCompiler || isReactChild) {\n this.parent.renderTemplates(function () {\n valueDiv.querySelector('input').id = isComplex ? complexFieldName + elementId : column + elementId;\n value.appendChild(valueDiv);\n });\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (this.parent.isAngular ? valueDiv.children[0] : valueDiv.querySelector('input')).id = isComplex ?\n complexFieldName + elementId : column + elementId;\n value.appendChild(valueDiv);\n }\n }\n else {\n var valueInput = this.parent\n .createElement('input', { id: isComplex ? complexFieldName + elementId : column + elementId });\n valueDiv.appendChild(valueInput);\n value.appendChild(valueDiv);\n var flValue = void 0;\n var predicate = void 0;\n if (predicates && predicates.length > 0) {\n predicate = predicates.length === 2 ?\n (isFirst ? predicates[0] : predicates[1]) :\n (isFirst ? predicates[0] : undefined);\n flValue = (predicate && predicate.operator === optr.operator) ? predicate.value : undefined;\n if (isNullOrUndefined(flValue)) {\n flValue = undefined;\n }\n }\n var types = {\n 'string': this.renderAutoComplete.bind(this),\n 'number': this.renderNumericTextBox.bind(this),\n 'date': this.renderDate.bind(this),\n 'dateonly': this.renderDate.bind(this),\n 'datetime': this.renderDateTime.bind(this)\n };\n types[this.options.type](this.options, column, valueInput, flValue, this.parent.enableRtl);\n }\n };\n ExcelFilterBase.prototype.getExcelFilterData = function (elementId, data, columnObj, predicates, fltrPredicates) {\n var predIndex = elementId === '-xlfl-frstvalue' ? 0 : 1;\n if (elementId === '-xlfl-frstvalue' || fltrPredicates.length > 1) {\n data = { column: predicates instanceof Array ? predicates[parseInt(predIndex.toString(), 10)] : predicates };\n var indx = this.options.column.columnData && fltrPredicates.length > 1 ?\n (this.options.column.columnData.length === 1 ? 0 : 1) : predIndex;\n data[this.options.field] = columnObj.foreignKeyValue ?\n this.options.column.columnData[parseInt(indx.toString(), 10)][columnObj.foreignKeyValue] :\n fltrPredicates[parseInt(indx.toString(), 10)].value;\n if (this.options.foreignKeyValue) {\n data[this.options.foreignKeyValue] = this.options.column\n .columnData[parseInt(indx.toString(), 10)][columnObj.foreignKeyValue];\n }\n }\n return data;\n };\n // eslint-disable-next-line max-len\n ExcelFilterBase.prototype.renderMatchCase = function (column, tr, matchCase, elementId, predicates) {\n var matchCaseDiv = this.parent.createElement('div', { className: 'e-xlfl-matchcasediv', attrs: { 'style': 'display: inline-block' } });\n var isComplex = !isNullOrUndefined(column) && isComplexField(column);\n var complexFieldName = !isNullOrUndefined(column) && getComplexFieldID(column);\n var matchCaseInput = this.parent.createElement('input', { id: isComplex ? complexFieldName + elementId : column + elementId, attrs: { 'type': 'checkbox' } });\n matchCaseDiv.appendChild(matchCaseInput);\n matchCase.appendChild(matchCaseDiv);\n var flValue = predicates && predicates.length > 0 ?\n (predicates && predicates.length === 2 ? predicates[1].matchCase : predicates[0].matchCase) :\n false;\n // Initialize Match Case check box.\n var checkbox = new CheckBox({\n label: this.getLocalizedLabel('MatchCase'),\n enableRtl: this.parent.enableRtl, checked: flValue,\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n this.childRefs.push(checkbox);\n // Render initialized CheckBox.\n checkbox.appendTo(matchCaseInput);\n };\n // eslint-disable-next-line max-len\n ExcelFilterBase.prototype.renderDate = function (options, column, inputValue, fValue, isRtl) {\n var format = getCustomDateFormat(options.format, options.type) || options.format;\n var datePicker = new DatePicker(extend({\n format: format,\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n placeholder: this.getLocalizedLabel('CustomFilterDatePlaceHolder'),\n width: '100%',\n enableRtl: isRtl,\n value: new Date(fValue),\n locale: this.parent.locale\n }, options.column.filter.params));\n this.childRefs.push(datePicker);\n datePicker.appendTo(inputValue);\n };\n // eslint-disable-next-line max-len\n ExcelFilterBase.prototype.renderDateTime = function (options, column, inputValue, fValue, isRtl) {\n var format = getCustomDateFormat(options.format, options.type);\n var dateTimePicker = new DateTimePicker(extend({\n format: format,\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n placeholder: this.getLocalizedLabel('CustomFilterDatePlaceHolder'),\n width: '100%',\n enableRtl: isRtl,\n value: new Date(fValue),\n locale: this.parent.locale\n }, options.column.filter.params));\n this.childRefs.push(dateTimePicker);\n dateTimePicker.appendTo(inputValue);\n };\n ExcelFilterBase.prototype.completeAction = function (e) {\n e.result = distinctStringValues(e.result);\n };\n // eslint-disable-next-line max-len\n ExcelFilterBase.prototype.renderNumericTextBox = function (options, column, inputValue, fValue, isRtl) {\n var numericTextBox = new NumericTextBox(extend({\n format: options.format,\n placeholder: this.getLocalizedLabel('CustomFilterPlaceHolder'),\n enableRtl: isRtl,\n value: fValue,\n locale: this.parent.locale,\n cssClass: this.parent.cssClass ? this.parent.cssClass : null\n }, options.column.filter.params));\n this.childRefs.push(numericTextBox);\n numericTextBox.appendTo(inputValue);\n };\n // eslint-disable-next-line max-len\n ExcelFilterBase.prototype.renderAutoComplete = function (options, column, inputValue, fValue, isRtl) {\n var colObj = this.options.column;\n var isForeignColumn = this.isForeignColumn(colObj);\n var dataSource = isForeignColumn ? colObj.dataSource : options.dataSource;\n var fields = { value: isForeignColumn ? colObj.foreignKeyValue : column };\n var actObj = new AutoComplete(extend({\n dataSource: dataSource instanceof DataManager ? dataSource : new DataManager(dataSource),\n fields: fields,\n query: this.getQuery(),\n sortOrder: 'Ascending',\n locale: this.parent.locale,\n cssClass: this.parent.cssClass ? 'e-popup-flmenu' + ' ' + this.parent.cssClass : 'e-popup-flmenu',\n autofill: true,\n placeholder: this.getLocalizedLabel('CustomFilterPlaceHolder'),\n enableRtl: isRtl,\n text: fValue\n }, colObj.filter.params));\n if (dataSource && 'result' in dataSource) {\n var defObj = eventPromise({ requestType: 'stringfilterrequest' }, this.getQuery());\n this.parent.trigger(events.dataStateChange, defObj.state);\n var def = defObj.deffered;\n def.promise.then(function (e) {\n actObj.dataSource = new DataManager(e);\n });\n }\n this.childRefs.push(actObj);\n var evt = { 'actionComplete': this.acActionComplete(actObj, column), 'focus': this.acFocus(actObj, column, options, inputValue) };\n registerEventHandlers(inputValue.id, [events.actionComplete, literals.focus], evt, this);\n actObj.addEventListener(literals.focus, this.eventHandlers[inputValue.id][literals.focus]);\n actObj.addEventListener(events.actionComplete, this.eventHandlers[inputValue.id][events.actionComplete]);\n actObj.appendTo(inputValue);\n };\n ExcelFilterBase.prototype.acActionComplete = function (actObj, column) {\n return function (e) {\n var isComplex = !isNullOrUndefined(column) && isComplexField(column);\n e.result = e.result.filter(function (obj, index, arr) {\n return arr.map(function (mapObject) {\n return isComplex ? performComplexDataOperation(actObj.fields.value, mapObject)\n : mapObject[actObj.fields.value];\n }).indexOf(isComplex ? performComplexDataOperation(actObj.fields.value, obj) :\n obj[actObj.fields.value]) === index;\n });\n };\n };\n ExcelFilterBase.prototype.acFocus = function (actObj, column, options, inputValue) {\n var _this = this;\n return function () {\n var isComplex = !isNullOrUndefined(column) && isComplexField(column);\n var complexFieldName = !isNullOrUndefined(column) && getComplexFieldID(column);\n var columnvalue = isComplex ? complexFieldName : column;\n actObj.filterType = _this.dlgDiv.querySelector('#' + columnvalue +\n (inputValue.id === (columnvalue + '-xlfl-frstvalue') ?\n '-xlfl-frstoptr' :\n '-xlfl-secndoptr')).ej2_instances[0].value;\n actObj.ignoreCase = options.type === 'string' ?\n !_this.dlgDiv.querySelector('#' + columnvalue + '-xlflmtcase').ej2_instances[0].checked :\n true;\n actObj.filterType = !isNullOrUndefined(actObj.filterType) ? actObj.filterType :\n 'equal';\n };\n };\n return ExcelFilterBase;\n}(CheckBoxFilterBase));\nexport { ExcelFilterBase };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { ExcelFilterBase } from '../common/excel-filter-base';\nimport { CheckBoxFilter } from './checkbox-filter';\nimport * as events from '../base/constant';\n/**\n * @hidden\n * `ExcelFilter` module is used to handle filtering action.\n */\nvar ExcelFilter = /** @class */ (function (_super) {\n __extends(ExcelFilter, _super);\n /**\n * Constructor for excelbox filtering module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {FilterSettings} filterSettings - specifies the Filtersettings\n * @param {ServiceLocator} serviceLocator - specifies the serviceLocator\n * @param {object} customFltrOperators - specifies the customFltrOperators\n * @hidden\n */\n function ExcelFilter(parent, filterSettings, serviceLocator, customFltrOperators) {\n var _this = _super.call(this, parent, filterSettings, serviceLocator) || this;\n _this.parent = parent;\n _this.isresetFocus = true;\n _this.excelFilterBase = new ExcelFilterBase(parent, customFltrOperators);\n return _this;\n }\n /**\n * To destroy the excel filter.\n *\n * @returns {void}\n * @hidden\n */\n ExcelFilter.prototype.destroy = function () {\n this.excelFilterBase.closeDialog();\n };\n ExcelFilter.prototype.openDialog = function (options) {\n this.excelFilterBase.openDialog(options);\n };\n ExcelFilter.prototype.closeDialog = function () {\n this.excelFilterBase.closeDialog();\n if (this.isresetFocus) {\n this.parent.notify(events.restoreFocus, {});\n }\n };\n ExcelFilter.prototype.clearCustomFilter = function (col) {\n this.excelFilterBase.clearFilter(col);\n };\n ExcelFilter.prototype.closeResponsiveDialog = function (isCustomFilter) {\n if (isCustomFilter) {\n this.excelFilterBase.removeDialog();\n }\n else {\n this.closeDialog();\n }\n };\n ExcelFilter.prototype.applyCustomFilter = function (args) {\n if (!args.isCustomFilter) {\n this.excelFilterBase.fltrBtnHandler();\n this.excelFilterBase.closeDialog();\n }\n else {\n this.excelFilterBase.filterBtnClick(args.col.field);\n }\n };\n ExcelFilter.prototype.filterByColumn = function (fieldName, firstOperator, firstValue, predicate, matchCase, ignoreAccent, secondOperator, secondValue) {\n this.excelFilterBase.filterByColumn(fieldName, firstOperator, firstValue, predicate, matchCase, ignoreAccent, secondOperator, secondValue);\n };\n /**\n * @returns {FilterUI} returns the filterUI\n * @hidden\n */\n ExcelFilter.prototype.getFilterUIInfo = function () {\n return this.excelFilterBase.getFilterUIInfo();\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n ExcelFilter.prototype.getModuleName = function () {\n return 'excelFilter';\n };\n return ExcelFilter;\n}(CheckBoxFilter));\nexport { ExcelFilter };\n","import { EventHandler, isNullOrUndefined, extend, closest, getValue } from '@syncfusion/ej2-base';\nimport { getActualPropFromColl, isActionPrevent, getColumnByForeignKeyValue } from '../base/util';\nimport { remove, matches } from '@syncfusion/ej2-base';\nimport { DataUtil, Query, DataManager } from '@syncfusion/ej2-data';\nimport * as events from '../base/constant';\nimport { CellType, ResponsiveDialogAction } from '../base/enum';\nimport { RowRenderer } from '../renderer/row-renderer';\nimport { Cell } from '../models/cell';\nimport { Row } from '../models/row';\nimport { FilterCellRenderer } from '../renderer/filter-cell-renderer';\nimport { parentsUntil, addFixedColumnBorder, applyStickyLeftRightPosition } from '../base/util';\nimport { FilterMenuRenderer } from '../renderer/filter-menu-renderer';\nimport { CheckBoxFilter } from '../actions/checkbox-filter';\nimport { ExcelFilter } from '../actions/excel-filter';\nimport * as literals from '../base/string-literals';\nimport { Input } from '@syncfusion/ej2-inputs';\n/**\n *\n * The `Filter` module is used to handle filtering action.\n */\nvar Filter = /** @class */ (function () {\n /**\n * Constructor for Grid filtering module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {FilterSettings} filterSettings - specifies the filterSettings\n * @param {ServiceLocator} serviceLocator - specifes the serviceLocator\n * @hidden\n */\n function Filter(parent, filterSettings, serviceLocator) {\n this.predicate = 'and';\n this.contentRefresh = true;\n this.filterByMethod = true;\n this.refresh = true;\n this.values = {};\n this.operators = {};\n this.cellText = {};\n this.nextFlMenuOpen = '';\n this.type = { 'Menu': FilterMenuRenderer, 'CheckBox': CheckBoxFilter, 'Excel': ExcelFilter };\n /** @hidden */\n this.filterOperators = {\n contains: 'contains', endsWith: 'endswith', equal: 'equal', greaterThan: 'greaterthan', greaterThanOrEqual: 'greaterthanorequal',\n lessThan: 'lessthan', lessThanOrEqual: 'lessthanorequal', notEqual: 'notequal', startsWith: 'startswith', wildCard: 'wildcard',\n isNull: 'isnull', notNull: 'notnull', like: 'like'\n };\n this.fltrDlgDetails = { field: '', isOpen: false };\n /** @hidden */\n this.skipNumberInput = ['=', ' ', '!'];\n this.skipStringInput = ['>', '<', '='];\n this.actualPredicate = {};\n this.parent = parent;\n this.filterSettings = filterSettings;\n this.serviceLocator = serviceLocator;\n this.addEventListener();\n this.setFullScreenDialog();\n }\n /**\n * To render filter bar when filtering enabled.\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Filter.prototype.render = function (e) {\n if (DataUtil.getObject('args.isFrozen', e)) {\n return;\n }\n var gObj = this.parent;\n this.l10n = this.serviceLocator.getService('localization');\n this.getLocalizedCustomOperators();\n if (this.parent.filterSettings.type === 'FilterBar') {\n if (gObj.columns.length) {\n var fltrElem = this.parent.element.querySelector('.e-filterbar');\n if (fltrElem) {\n remove(fltrElem);\n }\n var rowRenderer = new RowRenderer(this.serviceLocator, CellType.Filter, gObj);\n var cellrender = this.serviceLocator.getService('cellRendererFactory');\n cellrender.addCellRenderer(CellType.Filter, new FilterCellRenderer(this.parent, this.serviceLocator));\n this.valueFormatter = this.serviceLocator.getService('valueFormatter');\n rowRenderer.element = this.parent.createElement('tr', { className: 'e-filterbar', attrs: { role: 'row' } });\n var row = this.generateRow();\n row.data = this.values;\n this.parent.getHeaderContent().querySelector('thead:not(.e-masked-thead)').appendChild(rowRenderer.element);\n var rowdrag = this.parent.element.querySelector('.e-rowdragheader');\n this.element = rowRenderer.render(row, gObj.getColumns(), null, null, rowRenderer.element);\n if (this.element.querySelectorAll('.e-leftfreeze').length &&\n (this.element.querySelectorAll('.e-indentcell').length || this.element.querySelectorAll('.e-grouptopleftcell').length)) {\n var td = this.element.querySelectorAll('.e-indentcell, .e-grouptopleftcell');\n for (var i = 0; i < td.length; i++) {\n td[parseInt(i.toString(), 10)].classList.add('e-leftfreeze');\n applyStickyLeftRightPosition(td[parseInt(i.toString(), 10)], i * 30, this.parent.enableRtl, 'Left');\n }\n }\n addFixedColumnBorder(this.element);\n var detail = this.element.querySelector('.e-detailheadercell');\n if (detail) {\n detail.className = 'e-filterbarcell e-mastercell';\n }\n if (rowdrag) {\n if (rowdrag.classList.contains('e-leftfreeze')) {\n rowdrag.className = 'e-dragheadercell e-mastercell e-leftfreeze';\n }\n else {\n rowdrag.className = 'e-filterbarcell e-mastercell';\n }\n }\n var gCells = [].slice.call(this.element.getElementsByClassName('e-grouptopleftcell'));\n if (gCells.length) {\n gCells[gCells.length - 1].classList.add('e-lastgrouptopleftcell');\n }\n this.wireEvents();\n this.parent.notify(events.freezeRender, { case: 'filter' });\n }\n }\n };\n /**\n * To show the responsive custom filter dialog\n *\n * @param {boolean} enable - specifes dialog open\n * @returns {void}\n * @hidden\n */\n Filter.prototype.showCustomFilter = function (enable) {\n this.responsiveDialogRenderer.isCustomDialog = enable;\n this.responsiveDialogRenderer.showResponsiveDialog(this.column);\n };\n Filter.prototype.renderResponsiveChangeAction = function (args) {\n this.responsiveDialogRenderer.action = args.action;\n };\n /**\n * To create the filter module.\n *\n * @param {Column} col - specifies the filtering column name\n * @returns {void}\n * @hidden\n */\n Filter.prototype.setFilterModel = function (col) {\n var type = col.filter.type || this.parent.filterSettings.type;\n this.filterModule = new this.type[\"\" + type](this.parent, this.parent.filterSettings, this.serviceLocator, this.customOperators, this);\n };\n /**\n * To destroy the filter bar.\n *\n * @returns {void}\n * @hidden\n */\n Filter.prototype.destroy = function () {\n var gridElement = this.parent.element;\n if (!gridElement || (!gridElement.querySelector('.' + literals.gridHeader) && !gridElement.querySelector('.' + literals.gridContent))) {\n return;\n }\n if (this.filterModule) {\n this.filterModule.destroy();\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (!this.parent.refreshing && (this.parent.isDestroyed || !this.parent.allowFiltering)) {\n this.filterSettings.columns = [];\n }\n this.updateFilterMsg();\n this.removeEventListener();\n this.unWireEvents();\n if (this.filterSettings.type === 'FilterBar' && this.filterSettings.showFilterBarOperator) {\n var dropdownlist = [].slice.call(this.element.getElementsByClassName('e-filterbaroperator'));\n for (var i = 0; i < dropdownlist.length; i++) {\n if (dropdownlist[parseInt(i.toString(), 10)].ej2_instances[0]) {\n dropdownlist[parseInt(i.toString(), 10)].ej2_instances[0].destroy();\n }\n }\n }\n if (this.element) {\n if (this.element.parentElement) {\n remove(this.element);\n }\n var filterBarElement = this.parent.getHeaderContent().querySelector('.e-filterbar');\n if (filterBarElement) {\n remove(filterBarElement);\n }\n }\n };\n Filter.prototype.setFullScreenDialog = function () {\n if (this.serviceLocator) {\n this.serviceLocator.registerAdaptiveService(this, this.parent.enableAdaptiveUI, ResponsiveDialogAction.isFilter);\n }\n };\n Filter.prototype.generateRow = function () {\n var options = {};\n var row = new Row(options);\n row.cells = this.generateCells();\n return row;\n };\n Filter.prototype.generateCells = function () {\n //TODO: generate dummy column for group, detail, stacked row here for filtering;\n var cells = [];\n if (this.parent.allowGrouping) {\n for (var c = 0, len = this.parent.groupSettings.columns.length; c < len; c++) {\n cells.push(this.generateCell({}, CellType.HeaderIndent));\n }\n }\n if (this.parent.detailTemplate || this.parent.childGrid) {\n cells.push(this.generateCell({}, CellType.DetailHeader));\n }\n if (this.parent.isRowDragable() && this.parent.getFrozenMode() !== 'Right') {\n cells.push(this.generateCell({}, CellType.RowDragHIcon));\n }\n for (var _i = 0, _a = this.parent.getColumns(); _i < _a.length; _i++) {\n var dummy = _a[_i];\n cells.push(this.generateCell(dummy));\n }\n if (this.parent.isRowDragable() && this.parent.getFrozenMode() === 'Right') {\n cells.push(this.generateCell({}, CellType.RowDragHIcon));\n }\n return cells;\n };\n Filter.prototype.generateCell = function (column, cellType) {\n var opt = {\n 'visible': column.visible,\n 'isDataCell': false,\n 'rowId': '',\n 'column': column,\n 'cellType': cellType ? cellType : CellType.Filter,\n 'attributes': { title: this.l10n.getConstant('FilterbarTitle') }\n };\n return new Cell(opt);\n };\n /**\n * To update filterSettings when applying filter.\n *\n * @returns {void}\n * @hidden\n */\n Filter.prototype.updateModel = function () {\n var col = this.column.isForeignColumn() ? this.parent.getColumnByUid(this.column.uid) :\n this.parent.getColumnByField(this.fieldName);\n this.filterObjIndex = this.getFilteredColsIndexByField(col);\n this.prevFilterObject = this.filterSettings.columns[this.filterObjIndex];\n var arrayVal = Array.isArray(this.value) ? this.value : [this.value];\n var moduleName = this.parent.dataSource.adaptor && this.parent.dataSource.adaptor.getModuleName ? this.parent.dataSource.adaptor.getModuleName() : undefined;\n for (var i = 0, len = arrayVal.length; i < len; i++) {\n var field = col.isForeignColumn() ? col.foreignKeyValue : this.fieldName;\n var isMenuNotEqual = this.operator === 'notequal';\n this.currentFilterObject = {\n field: field, uid: col.uid, isForeignKey: col.isForeignColumn(), operator: this.operator,\n value: arrayVal[parseInt(i.toString(), 10)], predicate: this.predicate,\n matchCase: this.matchCase, ignoreAccent: this.ignoreAccent, actualFilterValue: {}, actualOperator: {}\n };\n var index = this.getFilteredColsIndexByField(col);\n if (index > -1 && !Array.isArray(this.value)) {\n this.filterSettings.columns[parseInt(index.toString(), 10)] = this.currentFilterObject;\n }\n else {\n this.filterSettings.columns.push(this.currentFilterObject);\n }\n if (!this.column.isForeignColumn() && isNullOrUndefined(this.value) && (this.operator === 'equal' ||\n this.operator === 'notequal') && (moduleName !== 'ODataAdaptor' && moduleName !== 'ODataV4Adaptor')) {\n for (var i_1 = 0; i_1 < this.filterSettings.columns.length; i_1++) {\n if (this.filterSettings.columns[\"\" + i_1].field === field &&\n (this.filterSettings.columns[\"\" + i_1].operator === 'equal' || this.filterSettings.columns[\"\" + i_1].operator === 'notequal')\n && isNullOrUndefined(this.filterSettings.columns[\"\" + i_1].value)) {\n this.filterSettings.columns.splice(i_1, 1);\n i_1 = i_1 - 1;\n }\n }\n if (col.type === 'string') {\n this.filterSettings.columns.push({\n field: field, ignoreAccent: this.ignoreAccent, matchCase: this.matchCase,\n operator: this.operator, predicate: isMenuNotEqual ? 'and' : 'or', value: ''\n });\n }\n this.filterSettings.columns.push({\n field: field, ignoreAccent: this.ignoreAccent, matchCase: this.matchCase,\n operator: this.operator, predicate: isMenuNotEqual ? 'and' : 'or', value: undefined\n });\n this.filterSettings.columns.push({\n field: field, ignoreAccent: this.ignoreAccent, matchCase: this.matchCase,\n operator: this.operator, predicate: isMenuNotEqual ? 'and' : 'or', value: null\n });\n }\n }\n // eslint-disable-next-line no-self-assign\n this.filterSettings.columns = this.filterSettings.columns;\n this.parent.dataBind();\n };\n Filter.prototype.getFilteredColsIndexByField = function (col) {\n var cols = this.filterSettings.columns;\n for (var i = 0, len = cols.length; i < len; i++) {\n if (cols[parseInt(i.toString(), 10)].uid === col.uid || (col.isForeignColumn()\n && this.parent.getColumnByUid(col.uid).field === col.foreignKeyValue)) {\n return i;\n }\n }\n return -1;\n };\n /**\n * To trigger action complete event.\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Filter.prototype.onActionComplete = function (e) {\n var args = !this.isRemove ? {\n currentFilterObject: this.currentFilterObject,\n /* tslint:disable:no-string-literal */\n currentFilteringColumn: !isNullOrUndefined(this.column) ? this.column.field : undefined,\n /* tslint:enable:no-string-literal */\n columns: this.filterSettings.columns, requestType: 'filtering', type: events.actionComplete\n } : {\n requestType: 'filtering', type: events.actionComplete\n };\n this.parent.trigger(events.actionComplete, extend(e, args));\n this.isRemove = false;\n };\n Filter.prototype.wireEvents = function () {\n EventHandler.add(this.parent.getHeaderContent(), 'keyup', this.keyUpHandlerImmediate, this);\n };\n Filter.prototype.unWireEvents = function () {\n EventHandler.remove(this.parent.getHeaderContent(), 'keyup', this.keyUpHandlerImmediate);\n };\n Filter.prototype.enableAfterRender = function (e) {\n if (e.module === this.getModuleName() && e.enable) {\n this.parent.getHeaderTable().classList.add('e-sortfilter');\n this.render();\n }\n };\n Filter.prototype.refreshFilterValue = function () {\n this.parent.removeEventListener(events.beforeDataBound, this.refreshFilterValueFn);\n if (this.filterSettings.type === 'FilterBar' && this.filterSettings.columns.length &&\n !this.parent.getCurrentViewRecords().length) {\n this.initialEnd();\n }\n };\n Filter.prototype.initialEnd = function () {\n this.parent.off(events.contentReady, this.initialEnd);\n if (this.parent.getColumns().length && this.filterSettings.columns.length) {\n var gObj = this.parent;\n this.contentRefresh = false;\n this.initialLoad = true;\n for (var _i = 0, _a = gObj.filterSettings.columns; _i < _a.length; _i++) {\n var col = _a[_i];\n this.filterByColumn(col.field, col.operator, col.value, col.predicate, col.matchCase, col.ignoreAccent, col.actualFilterValue, col.actualOperator, col.isForeignKey);\n }\n this.initialLoad = false;\n this.updateFilterMsg();\n this.contentRefresh = true;\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Filter.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.setFullScreenDialog, this.setFullScreenDialog, this);\n this.parent.on(events.uiUpdate, this.enableAfterRender, this);\n this.parent.on(events.filterComplete, this.onActionComplete, this);\n this.parent.on(events.inBoundModelChanged, this.onPropertyChanged, this);\n this.parent.on(events.keyPressed, this.keyUpHandler, this);\n this.parent.on(events.columnPositionChanged, this.columnPositionChanged, this);\n this.parent.on(events.headerRefreshed, this.render, this);\n this.parent.on(events.contentReady, this.initialEnd, this);\n this.parent.on(events.filterMenuClose, this.filterMenuClose, this);\n this.parent.on(events.renderResponsiveChangeAction, this.renderResponsiveChangeAction, this);\n this.docClickHandler = this.clickHandler.bind(this);\n EventHandler.add(document, 'click', this.docClickHandler, this);\n EventHandler.add(this.parent.element, 'mousedown', this.refreshClearIcon, this);\n this.parent.on(events.filterOpen, this.columnMenuFilter, this);\n this.parent.on(events.click, this.filterIconClickHandler, this);\n this.parent.on('persist-data-changed', this.initialEnd, this);\n this.parent.on(events.closeFilterDialog, this.clickHandler, this);\n this.parent.on(events.destroy, this.destroy, this);\n this.refreshFilterValueFn = this.refreshFilterValue.bind(this);\n this.parent.addEventListener(events.beforeDataBound, this.refreshFilterValueFn);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Filter.prototype.removeEventListener = function () {\n EventHandler.remove(document, 'click', this.docClickHandler);\n EventHandler.remove(this.parent.element, 'mousedown', this.refreshClearIcon);\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.setFullScreenDialog, this.setFullScreenDialog);\n this.parent.off(events.uiUpdate, this.enableAfterRender);\n this.parent.off(events.filterComplete, this.onActionComplete);\n this.parent.off(events.inBoundModelChanged, this.onPropertyChanged);\n this.parent.off(events.keyPressed, this.keyUpHandler);\n this.parent.off(events.columnPositionChanged, this.columnPositionChanged);\n this.parent.off(events.headerRefreshed, this.render);\n this.parent.off(events.filterOpen, this.columnMenuFilter);\n this.parent.off(events.filterMenuClose, this.filterMenuClose);\n this.parent.off(events.renderResponsiveChangeAction, this.renderResponsiveChangeAction);\n this.parent.off(events.click, this.filterIconClickHandler);\n this.parent.off(events.closeFilterDialog, this.clickHandler);\n this.parent.off(events.destroy, this.destroy);\n };\n Filter.prototype.refreshClearIcon = function (e) {\n if (this.parent.allowFiltering && this.parent.filterSettings.type === 'FilterBar' &&\n e.target.closest('th') && e.target.closest('th').classList.contains('e-filterbarcell') &&\n e.target.classList.contains('e-clear-icon')) {\n var targetText = e.target.previousElementSibling;\n Input.setValue(null, targetText, 'Never', true);\n if (this.filterSettings.mode === 'Immediate') {\n this.removeFilteredColsByField(targetText.id.slice(0, -14)); //Length of _filterBarcell = 14\n }\n }\n };\n Filter.prototype.filterMenuClose = function () {\n this.fltrDlgDetails.isOpen = false;\n };\n /**\n * Filters the Grid row by fieldName, filterOperator, and filterValue.\n *\n * @param {string} fieldName - Defines the field name of the filter column.\n * @param {string} filterOperator - Defines the operator to filter records.\n * @param {string | number | Date | boolean} filterValue - Defines the value which is used to filter records.\n * @param {string} predicate - Defines the relationship of one filter query with another by using AND or OR predicate.\n * @param {boolean} matchCase - If match case is set to true, then the filter records\n * the exact match or <br> filters records that are case insensitive (uppercase and lowercase letters treated the same).\n * @param {boolean} ignoreAccent - If ignoreAccent set to true, then filter ignores the diacritic characters or accents while filtering.\n * @param {string} actualFilterValue - Defines the actual filter value for the filter column.\n * @param {string} actualOperator - Defines the actual filter operator for the filter column.\n * @param {boolean} isForeignColumn - Defines whether it is a foreign key column.\n * @returns {void}\n */\n Filter.prototype.filterByColumn = function (fieldName, filterOperator, filterValue, predicate, matchCase, ignoreAccent, actualFilterValue, actualOperator, isForeignColumn) {\n var _this = this;\n var gObj = this.parent;\n var filterCell;\n this.column = gObj.grabColumnByFieldFromAllCols(fieldName, isForeignColumn);\n if (this.filterSettings.type === 'FilterBar' && this.filterSettings.showFilterBarOperator\n && isNullOrUndefined(this.column.filterBarTemplate) && isNullOrUndefined(this.column.filterTemplate)) {\n filterOperator = this.getOperatorName(fieldName);\n }\n if (filterOperator === 'like' && filterValue && filterValue.indexOf('%') === -1) {\n filterValue = '%' + filterValue + '%';\n }\n if (!this.column) {\n return;\n }\n if (this.filterSettings.type === 'FilterBar') {\n filterCell = gObj.getHeaderContent().querySelector('[id=\\'' + this.column.field + '_filterBarcell\\']');\n }\n if (!isNullOrUndefined(this.column.allowFiltering) && !this.column.allowFiltering) {\n this.parent.log('action_disabled_column', { moduleName: this.getModuleName(), columnName: this.column.headerText });\n return;\n }\n if (isActionPrevent(gObj)) {\n gObj.notify(events.preventBatch, {\n instance: this, handler: this.filterByColumn, arg1: fieldName, arg2: filterOperator, arg3: filterValue, arg4: predicate,\n arg5: matchCase, arg6: ignoreAccent, arg7: actualFilterValue, arg8: actualOperator\n });\n return;\n }\n this.predicate = predicate ? predicate : Array.isArray(filterValue) ? 'or' : 'and';\n this.value = filterValue;\n this.matchCase = matchCase || false;\n this.ignoreAccent = this.ignoreAccent = !isNullOrUndefined(ignoreAccent) ? ignoreAccent : this.parent.filterSettings.ignoreAccent;\n this.fieldName = fieldName;\n this.operator = filterOperator;\n filterValue = !isNullOrUndefined(filterValue) ? filterValue.toString() : filterValue;\n if (filterValue === '') {\n filterValue = null;\n }\n if (this.column.type === 'number' || this.column.type === 'date') {\n this.matchCase = true;\n }\n if (filterCell && this.filterSettings.type === 'FilterBar') {\n if ((filterValue && filterValue.length < 1) || (!this.filterByMethod &&\n this.checkForSkipInput(this.column, filterValue))) {\n this.filterStatusMsg = (filterValue && filterValue.length < 1) ? '' : this.l10n.getConstant('InvalidFilterMessage');\n this.updateFilterMsg();\n return;\n }\n if (filterCell.value !== filterValue) {\n filterCell.value = filterValue;\n }\n }\n if (!isNullOrUndefined(this.column.format)) {\n this.applyColumnFormat(filterValue);\n if (this.initialLoad && this.filterSettings.type === 'FilterBar') {\n filterCell.value = this.values[this.column.field];\n }\n }\n else {\n this.values[this.column.field] = filterValue; //this line should be above updateModel\n }\n var predObj = {\n field: this.fieldName,\n predicate: predicate,\n matchCase: matchCase,\n ignoreAccent: ignoreAccent,\n operator: this.operator,\n value: this.value,\n type: this.column.type\n };\n var filterColumn = this.parent.filterSettings.columns.filter(function (fColumn) {\n return (fColumn.field === _this.fieldName);\n });\n if (filterColumn.length > 1 && !isNullOrUndefined(this.actualPredicate[this.fieldName])) {\n this.actualPredicate[this.fieldName].push(predObj);\n }\n else {\n this.actualPredicate[this.fieldName] = [predObj];\n }\n if (this.checkAlreadyColFiltered(this.column.field)) {\n return;\n }\n this.updateModel();\n };\n Filter.prototype.applyColumnFormat = function (filterValue) {\n var _this = this;\n var getFlvalue = (this.column.type === 'date' || this.column.type === 'datetime' || this.column.type === 'dateonly') ?\n new Date(filterValue) : parseFloat(filterValue);\n if ((this.column.type === 'date' || this.column.type === 'datetime' || this.column.type === 'dateonly') && filterValue &&\n Array.isArray(this.value) && filterValue.split(',').length > 1) {\n this.values[this.column.field] = ((filterValue).split(',')).map(function (val) {\n if (val === '') {\n val = null;\n }\n return _this.setFormatForFlColumn(new Date(val), _this.column);\n });\n }\n else {\n this.values[this.column.field] = this.setFormatForFlColumn(getFlvalue, this.column);\n }\n };\n // To skip the second time request to server while applying initial filtering - EJ2-44361\n Filter.prototype.skipUid = function (col) {\n var flag = true;\n var colLen = Object.keys((col));\n for (var i = 0; i < colLen.length; i++) {\n var key = Object.keys(col[colLen[parseInt(i.toString(), 10)]]);\n if (key.length === 1 && key[0] === 'uid') {\n flag = false;\n }\n }\n return flag;\n };\n Filter.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName()) {\n return;\n }\n for (var _i = 0, _a = Object.keys(e.properties); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'columns':\n // eslint-disable-next-line no-case-declarations\n var col = 'columns';\n // eslint-disable-next-line no-case-declarations\n var args = {\n currentFilterObject: this.currentFilterObject, currentFilteringColumn: this.column ?\n this.column.field : undefined, action: 'filter', columns: this.filterSettings.columns,\n requestType: 'filtering', type: events.actionBegin, cancel: false\n };\n if (this.contentRefresh && this.skipUid(e.properties[\"\" + col])) {\n this.parent.notify(events.modelChanged, args);\n if (args.cancel) {\n if ((this.filterSettings.type === 'CheckBox' || this.filterSettings.type === 'Excel')) {\n this.filterSettings.columns = (this.actualData.length <= 1) ? this.checkboxPrevFilterObject :\n this.checkboxFilterObject;\n this.actualPredicate[this.column.field] = this.filterSettings.columns;\n var col_1 = this.parent.getColumnByField(this.column.field);\n var iconClass = this.parent.showColumnMenu && col_1.showColumnMenu ? '.e-columnmenu' : '.e-icon-filter';\n var filterIconElement = this.parent.getColumnHeaderByField(this.column.field)\n .querySelector(iconClass);\n if (this.checkboxPrevFilterObject.length === 0) {\n filterIconElement.classList.remove('e-filtered');\n }\n else {\n filterIconElement.classList.add('e-filtered');\n }\n }\n else {\n if (isNullOrUndefined(this.prevFilterObject)) {\n this.filterSettings.columns.splice(this.filterSettings.columns.length - 1, 1);\n }\n else {\n this.filterSettings.columns[this.filterObjIndex] = this.prevFilterObject;\n }\n }\n return;\n }\n this.updateFilterIcon();\n this.refreshFilterSettings();\n this.updateFilterMsg();\n this.updateFilter();\n }\n break;\n case 'showFilterBarStatus':\n if (e.properties[\"\" + prop]) {\n this.updateFilterMsg();\n }\n else if (this.parent.allowPaging) {\n this.parent.updateExternalMessage('');\n }\n break;\n case 'showFilterBarOperator':\n case 'type':\n this.parent.refreshHeader();\n this.refreshFilterSettings();\n if (this.parent.height === '100%') {\n this.parent.scrollModule.refresh();\n }\n break;\n }\n }\n };\n Filter.prototype.refreshFilterSettings = function () {\n if (this.filterSettings.type === 'FilterBar') {\n for (var i = 0; i < this.filterSettings.columns.length; i++) {\n this.column = this.parent.grabColumnByUidFromAllCols(this.filterSettings.columns[parseInt(i.toString(), 10)].uid);\n var filterValue = this.filterSettings.columns[parseInt(i.toString(), 10)].value;\n filterValue = !isNullOrUndefined(filterValue) && filterValue.toString();\n if (!isNullOrUndefined(this.column.format)) {\n this.applyColumnFormat(filterValue);\n }\n else {\n var key = this.filterSettings.columns[parseInt(i.toString(), 10)].field;\n this.values[\"\" + key] = this.filterSettings.columns[parseInt(i.toString(), 10)].value;\n }\n var filterElement = this.getFilterBarElement(this.column.field);\n if (filterElement) {\n if (this.cellText[this.filterSettings.columns[parseInt(i.toString(), 10)].field] !== ''\n && !isNullOrUndefined(this.cellText[this.filterSettings.columns[parseInt(i.toString(), 10)].field])) {\n filterElement.value = this.cellText[this.column.field];\n }\n else {\n filterElement.value = this.filterSettings.columns[parseInt(i.toString(), 10)].value;\n }\n }\n }\n if (this.filterSettings.columns.length === 0) {\n var col = this.parent.getColumns();\n for (var i = 0; i < col.length; i++) {\n var filterElement = this.getFilterBarElement(col[parseInt(i.toString(), 10)].field);\n if (filterElement && filterElement.value !== '') {\n filterElement.value = '';\n delete this.values[col[parseInt(i.toString(), 10)].field];\n }\n }\n }\n }\n };\n Filter.prototype.updateFilterIcon = function () {\n if (this.filterSettings.columns.length === 0 && this.parent.element.querySelector('.e-filtered')) {\n var fltrIconElement = [].slice.call(this.parent.element.getElementsByClassName('e-filtered'));\n for (var i = 0, len = fltrIconElement.length; i < len; i++) {\n fltrIconElement[parseInt(i.toString(), 10)].classList.remove('e-filtered');\n }\n }\n };\n Filter.prototype.getFilterBarElement = function (col) {\n var selector = '[id=\\'' + col + '_filterBarcell\\']';\n var filterElement;\n if (selector && !isNullOrUndefined(this.element)) {\n filterElement = this.element.querySelector(selector);\n }\n return filterElement;\n };\n /**\n * @private\n * @returns {void}\n */\n Filter.prototype.refreshFilter = function () {\n this.refreshFilterSettings();\n this.updateFilterMsg();\n };\n /**\n * Clears all the filtered rows of the Grid.\n *\n * @param {string[]} fields - returns the fields\n * @returns {void}\n */\n Filter.prototype.clearFiltering = function (fields) {\n var _this = this;\n var cols = getActualPropFromColl(this.filterSettings.columns);\n if (!isNullOrUndefined(fields)) {\n this.refresh = false;\n fields.forEach(function (field) { _this.removeFilteredColsByField(field, false); });\n this.parent.setProperties({ filterSettings: { columns: this.filterSettings.columns } }, true);\n this.parent.renderModule.refresh();\n this.refresh = true;\n return;\n }\n if (isActionPrevent(this.parent)) {\n this.parent.notify(events.preventBatch, { instance: this, handler: this.clearFiltering });\n return;\n }\n for (var i = 0; i < cols.length; i++) {\n cols[parseInt(i.toString(), 10)].uid = cols[parseInt(i.toString(), 10)].uid\n || this.parent.getColumnByField(cols[parseInt(i.toString(), 10)].field).uid;\n }\n var colUid = cols.map(function (f) { return f.uid; });\n var filteredcols = colUid.filter(function (item, pos) { return colUid.indexOf(item) === pos; });\n this.refresh = false;\n for (var i = 0, len = filteredcols.length; i < len; i++) {\n this.removeFilteredColsByField(this.parent.getColumnByUid(filteredcols[parseInt(i.toString(), 10)]).field, false);\n }\n this.refresh = true;\n if (filteredcols.length) {\n this.parent.renderModule.refresh();\n }\n if (this.parent.filterSettings.columns.length === 0 && this.parent.element.querySelector('.e-filtered')) {\n var fltrElement = [].slice.call(this.parent.element.getElementsByClassName('e-filtered'));\n for (var i = 0, len = fltrElement.length; i < len; i++) {\n fltrElement[0].classList.remove('e-filtered');\n }\n }\n this.isRemove = true;\n this.filterStatusMsg = '';\n this.updateFilterMsg();\n };\n Filter.prototype.checkAlreadyColFiltered = function (field) {\n var columns = this.filterSettings.columns;\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var col = columns_1[_i];\n if (col.field === field && col.value === this.value &&\n col.operator === this.operator && col.predicate === this.predicate) {\n return true;\n }\n }\n return false;\n };\n Filter.prototype.columnMenuFilter = function (args) {\n this.column = args.col;\n var ele = closest(args.target, '#' + args.id);\n if (args.isClose && !ele) {\n this.filterModule.closeDialog();\n }\n else if (ele) {\n this.filterDialogOpen(this.column, args.target);\n }\n };\n Filter.prototype.filterDialogOpen = function (col, target, left, top) {\n if (this.filterModule) {\n this.filterModule.isresetFocus = false;\n this.filterModule.closeDialog();\n }\n this.setFilterModel(col);\n this.filterModule.openDialog(this.createOptions(col, target, left, top));\n };\n /**\n * Create filter dialog options\n *\n * @param {Column} col - Filtering column detail.\n * @param {Element} target - Filter dialog target.\n * @param {number} left - Filter dialog left position.\n * @param {number} top - Filter dialog top position.\n * @returns {Object} returns the created dialog options\n * @hidden\n */\n Filter.prototype.createOptions = function (col, target, left, top) {\n var gObj = this.parent;\n var dataSource = col.filter.dataSource || gObj.dataSource && 'result' in gObj.dataSource ? gObj.dataSource :\n gObj.getDataModule().dataManager;\n var type = col.filter.type || this.parent.filterSettings.type;\n var options = {\n type: col.type, field: col.field, displayName: col.headerText,\n dataSource: dataSource, format: col.format, height: 800, columns: gObj.getColumns(),\n filteredColumns: gObj.filterSettings.columns, target: target, dataManager: gObj.getDataModule().dataManager,\n formatFn: col.getFormatter(), ignoreAccent: gObj.filterSettings.ignoreAccent,\n parserFn: col.getParser(), query: gObj.query, template: col.getFilterItemTemplate(),\n hideSearchbox: isNullOrUndefined(col.filter.hideSearchbox) ? false : col.filter.hideSearchbox,\n handler: this.filterHandler.bind(this), localizedStrings: gObj.getLocaleConstants(),\n position: { X: left, Y: top }, column: col, foreignKeyValue: col.foreignKeyValue,\n actualPredicate: this.actualPredicate, localeObj: gObj.localeObj,\n isRemote: gObj.getDataModule().isRemote(), allowCaseSensitive: this.filterSettings.enableCaseSensitivity,\n isResponsiveFilter: this.parent.enableAdaptiveUI,\n operator: this.actualPredicate[col.field] && type === 'Menu' ? this.actualPredicate[col.field][0].operator : 'equal',\n parentTotalDataCount: gObj.getDataModule().isRemote() && gObj.allowPaging ? gObj.pagerModule.pagerObj.totalRecordsCount :\n gObj.getDataModule().isRemote() ? gObj.totalDataRecordsCount : gObj.getFilteredRecords().length,\n parentCurrentViewDataCount: gObj.currentViewData.length,\n parentFilteredLocalRecords: !gObj.getDataModule().isRemote() ? gObj.getFilteredRecords() : []\n };\n return options;\n };\n /**\n * Removes filtered column by field name.\n *\n * @param {string} field - Defines column field name to remove filter.\n * @param {boolean} isClearFilterBar - Specifies whether the filter bar value needs to be cleared.\n * @returns {void}\n * @hidden\n */\n Filter.prototype.removeFilteredColsByField = function (field, isClearFilterBar) {\n var fCell;\n var cols = this.filterSettings.columns;\n if (isActionPrevent(this.parent)) {\n var args = { instance: this, handler: this.removeFilteredColsByField, arg1: field, arg2: isClearFilterBar };\n this.parent.notify(events.preventBatch, args);\n return;\n }\n var colUid = cols.map(function (f) { return f.uid; });\n var filteredColsUid = colUid.filter(function (item, pos) { return colUid.indexOf(item) === pos; });\n if (!isNullOrUndefined(this.column)) {\n var col = this.column.isForeignColumn() ? this.parent.getColumnByUid(this.column.uid) :\n this.parent.getColumnByField(field);\n this.filterObjIndex = this.getFilteredColsIndexByField(col);\n this.prevFilterObject = this.filterSettings.columns[this.filterObjIndex];\n }\n var _loop_1 = function (i, len) {\n cols[parseInt(i.toString(), 10)].uid = cols[parseInt(i.toString(), 10)].uid\n || this_1.parent.getColumnByField(cols[parseInt(i.toString(), 10)].field).uid;\n var len_1 = cols.length;\n var column = this_1.parent.grabColumnByUidFromAllCols(filteredColsUid[parseInt(i.toString(), 10)]);\n if (column.field === field || (column.field === column.foreignKeyValue && column.isForeignColumn())) {\n var currentPred = this_1.filterSettings.columns.filter(function (e) {\n return e.uid === column.uid;\n })[0];\n if (this_1.filterSettings.type === 'FilterBar' && !isClearFilterBar) {\n var selector = '[id=\\'' + column.field + '_filterBarcell\\']';\n fCell = this_1.parent.getHeaderContent().querySelector(selector);\n if (fCell) {\n fCell.value = '';\n delete this_1.values[\"\" + field];\n }\n }\n while (len_1--) {\n if (cols[parseInt(len_1.toString(), 10)].uid === column.uid) {\n cols.splice(len_1, 1);\n }\n }\n var fltrElement = this_1.parent.getColumnHeaderByField(column.field);\n if (this_1.filterSettings.type !== 'FilterBar' || this_1.parent.showColumnMenu) {\n var iconClass = this_1.parent.showColumnMenu && column.showColumnMenu ? '.e-columnmenu' : '.e-icon-filter';\n fltrElement.querySelector(iconClass).classList.remove('e-filtered');\n }\n this_1.isRemove = true;\n if (this_1.actualPredicate[\"\" + field]) {\n delete this_1.actualPredicate[\"\" + field];\n }\n if (this_1.values[\"\" + field]) {\n delete this_1.values[\"\" + field];\n }\n if (this_1.refresh) {\n this_1.parent.notify(events.modelChanged, {\n requestType: 'filtering', type: events.actionBegin, currentFilterObject: currentPred,\n currentFilterColumn: column, action: 'clearFilter'\n });\n }\n return \"break\";\n }\n };\n var this_1 = this;\n for (var i = 0, len = filteredColsUid.length; i < len; i++) {\n var state_1 = _loop_1(i, len);\n if (state_1 === \"break\")\n break;\n }\n this.updateFilterMsg();\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Filter.prototype.getModuleName = function () {\n return 'filter';\n };\n Filter.prototype.keyUpHandlerImmediate = function (e) {\n if (e.keyCode !== 13) {\n this.keyUpHandler(e);\n }\n };\n Filter.prototype.keyUpHandler = function (e) {\n var gObj = this.parent;\n var target = e.target;\n if (target && matches(target, '.e-filterbar input')) {\n var closeHeaderEle = closest(target, 'th.e-filterbarcell');\n this.column = gObj.getColumnByUid(closeHeaderEle.getAttribute('e-mappinguid'));\n if (!this.column) {\n return;\n }\n if (e.action === 'altDownArrow' && this.parent.filterSettings.showFilterBarOperator) {\n var dropDownListInput = closest(target, 'span').querySelector('.e-filterbaroperator');\n dropDownListInput.ej2_instances[0].showPopup();\n dropDownListInput.focus();\n }\n if ((this.filterSettings.mode === 'Immediate' || (e.keyCode === 13 &&\n !e.target.classList.contains('e-filterbaroperator')))\n && e.keyCode !== 9 && !this.column.filterTemplate) {\n this.value = target.value.trim();\n this.processFilter(e);\n }\n }\n if (e.action === 'altDownArrow' && this.filterSettings.type !== 'FilterBar' && !parentsUntil(e.target, 'e-toolbar')\n && isNullOrUndefined(this.parent.element.querySelector('.e-filter-popup'))) {\n var element = gObj.focusModule.currentInfo.element;\n if (element && element.classList.contains('e-headercell')) {\n var column = gObj.getColumnByUid(element.firstElementChild.getAttribute('e-mappinguid'));\n this.openMenuByField(column.field);\n this.parent.focusModule.clearIndicator();\n }\n }\n if (e.action === 'escape' && this.filterSettings.type === 'Menu' && this.filterModule) {\n this.filterModule.closeDialog();\n gObj.notify(events.restoreFocus, {});\n }\n };\n Filter.prototype.updateCrossIcon = function (element) {\n if (element.value.length) {\n element.nextElementSibling.classList.remove('e-hide');\n }\n };\n Filter.prototype.updateFilterMsg = function () {\n if (this.filterSettings.type === 'FilterBar') {\n var gObj = this.parent;\n var getFormatFlValue = void 0;\n var columns = this.filterSettings.columns;\n var column = void 0;\n if (!this.filterSettings.showFilterBarStatus) {\n return;\n }\n if (columns.length > 0 && this.filterStatusMsg !== this.l10n.getConstant('InvalidFilterMessage')) {\n this.filterStatusMsg = '';\n for (var index = 0; index < columns.length; index++) {\n column = gObj.grabColumnByUidFromAllCols(columns[parseInt(index.toString(), 10)].uid)\n || gObj.grabColumnByFieldFromAllCols(columns[parseInt(index.toString(), 10)].field, columns[parseInt(index.toString(), 10)].isForeignKey);\n if (index) {\n this.filterStatusMsg += ' && ';\n }\n if (!isNullOrUndefined(column.format)) {\n var flValue = (column.type === 'date' || column.type === 'datetime' || column.type === 'dateonly') ?\n this.valueFormatter.fromView(this.values[column.field], column.getParser(), (column.type === 'dateonly' ? 'date' : column.type)) :\n this.values[column.field];\n if (!(column.type === 'date' || column.type === 'datetime' || column.type === 'dateonly')) {\n var formater = this.serviceLocator.getService('valueFormatter');\n getFormatFlValue = formater.toView(flValue, column.getParser()).toString();\n }\n else {\n getFormatFlValue = this.setFormatForFlColumn(flValue, column);\n }\n this.filterStatusMsg += column.headerText + ': ' + getFormatFlValue;\n }\n else {\n this.filterStatusMsg += column.headerText + ': ' + this.values[column.field];\n }\n }\n }\n if (gObj.allowPaging) {\n gObj.updateExternalMessage(this.filterStatusMsg);\n }\n //TODO: virtual paging\n this.filterStatusMsg = '';\n }\n };\n Filter.prototype.setFormatForFlColumn = function (value, column) {\n var formater = this.serviceLocator.getService('valueFormatter');\n return formater.toView(value, column.getFormatter()).toString();\n };\n Filter.prototype.checkForSkipInput = function (column, value) {\n var isSkip;\n if (column.type === 'number') {\n if (DataUtil.operatorSymbols[\"\" + value] || this.skipNumberInput.indexOf(value) > -1) {\n isSkip = true;\n }\n }\n else if (column.type === 'string') {\n for (var _i = 0, value_1 = value; _i < value_1.length; _i++) {\n var val = value_1[_i];\n if (this.skipStringInput.indexOf(val) > -1) {\n isSkip = true;\n }\n }\n }\n return isSkip;\n };\n Filter.prototype.processFilter = function (e) {\n this.stopTimer();\n this.startTimer(e);\n };\n Filter.prototype.startTimer = function (e) {\n var _this = this;\n this.timer = window.setInterval(function () { _this.onTimerTick(); }, e.keyCode === 13 ? 0 : this.filterSettings.immediateModeDelay);\n };\n Filter.prototype.stopTimer = function () {\n window.clearInterval(this.timer);\n };\n Filter.prototype.onTimerTick = function () {\n var selector = '[id=\\'' + this.column.field + '_filterBarcell\\']';\n var filterElement = this.element.querySelector(selector);\n if (!filterElement) {\n filterElement = this.parent.getHeaderContent().querySelector(selector);\n }\n var filterValue;\n this.cellText[this.column.field] = filterElement.value;\n this.stopTimer();\n if (!isNullOrUndefined(this.column.filterBarTemplate)) {\n var templateRead = this.column.filterBarTemplate.read;\n if (typeof templateRead === 'string') {\n templateRead = getValue(templateRead, window);\n }\n if (!isNullOrUndefined(templateRead)) {\n this.value = templateRead.call(this, filterElement);\n }\n }\n else {\n filterValue = JSON.parse(JSON.stringify(filterElement.value));\n }\n if (isNullOrUndefined(this.value) || this.value === '') {\n this.removeFilteredColsByField(this.column.field);\n return;\n }\n this.validateFilterValue(this.value);\n this.filterByMethod = false;\n this.filterByColumn(this.column.field, this.operator, this.value, this.predicate, this.filterSettings.enableCaseSensitivity, this.ignoreAccent, this.column.isForeignColumn());\n this.filterByMethod = true;\n filterElement.value = filterValue;\n this.updateFilterMsg();\n };\n Filter.prototype.validateFilterValue = function (value) {\n var skipInput;\n var index;\n this.matchCase = this.filterSettings.enableCaseSensitivity;\n switch (this.column.type) {\n case 'number':\n if (this.column.filter.operator) {\n this.operator = this.column.filter.operator;\n }\n else {\n this.operator = this.filterOperators.equal;\n }\n skipInput = ['>', '<', '=', '!'];\n for (var i = 0; i < value.length; i++) {\n if (skipInput.indexOf(value[parseInt(i.toString(), 10)]) > -1) {\n index = i;\n break;\n }\n }\n this.getOperator(value.substring(index));\n if (index !== 0) {\n this.value = value.substring(0, index);\n }\n if (this.value !== '' && value.length >= 1) {\n this.value = this.valueFormatter.fromView(this.value, this.column.getParser(), this.column.type);\n }\n if (isNaN(this.value)) {\n this.filterStatusMsg = this.l10n.getConstant('InvalidFilterMessage');\n }\n break;\n case 'date':\n case 'datetime':\n this.operator = this.filterOperators.equal;\n if (this.value !== '' && !(this.value instanceof Date)) {\n this.getOperator(value);\n this.value = this.valueFormatter.fromView(this.value, this.column.getParser(), this.column.type);\n if (isNullOrUndefined(this.value)) {\n this.filterStatusMsg = this.l10n.getConstant('InvalidFilterMessage');\n }\n }\n break;\n case 'string':\n this.matchCase = false;\n if (this.column.filter.operator) {\n this.operator = this.column.filter.operator;\n }\n else {\n if (value.indexOf('*') !== -1 || value.indexOf('?') !== -1 || value.indexOf('%3f') !== -1) {\n this.operator = this.filterOperators.wildCard;\n }\n else if (value.indexOf('%') !== -1) {\n this.operator = this.filterOperators.like;\n }\n else {\n this.operator = this.filterOperators.startsWith;\n }\n }\n break;\n case 'boolean':\n if (value.toLowerCase() === 'true' || value === '1') {\n this.value = true;\n }\n else if (value.toLowerCase() === 'false' || value === '0') {\n this.value = false;\n }\n else if (value.length) {\n this.filterStatusMsg = this.l10n.getConstant('InvalidFilterMessage');\n }\n this.operator = this.filterOperators.equal;\n break;\n default:\n if (this.column.filter.operator) {\n this.operator = this.column.filter.operator;\n }\n else {\n this.operator = this.filterOperators.equal;\n }\n }\n };\n Filter.prototype.getOperator = function (value) {\n var singleOp = value.charAt(0);\n var multipleOp = value.slice(0, 2);\n var operators = extend({ '=': this.filterOperators.equal, '!': this.filterOperators.notEqual }, DataUtil.operatorSymbols);\n // eslint-disable-next-line no-prototype-builtins\n if (operators.hasOwnProperty(singleOp) || operators.hasOwnProperty(multipleOp)) {\n this.operator = operators[\"\" + singleOp];\n this.value = value.substring(1);\n if (!this.operator) {\n this.operator = operators[\"\" + multipleOp];\n this.value = value.substring(2);\n }\n }\n if (this.operator === this.filterOperators.lessThan || this.operator === this.filterOperators.greaterThan) {\n if (this.value.charAt(0) === '=') {\n this.operator = this.operator + 'orequal';\n this.value = this.value.substring(1);\n }\n }\n };\n Filter.prototype.columnPositionChanged = function () {\n if (this.parent.filterSettings.type !== 'FilterBar') {\n return;\n }\n };\n Filter.prototype.getLocalizedCustomOperators = function () {\n var numOptr = [\n { value: 'equal', text: this.l10n.getConstant('Equal') },\n { value: 'greaterthan', text: this.l10n.getConstant('GreaterThan') },\n { value: 'greaterthanorequal', text: this.l10n.getConstant('GreaterThanOrEqual') },\n { value: 'lessthan', text: this.l10n.getConstant('LessThan') },\n { value: 'lessthanorequal', text: this.l10n.getConstant('LessThanOrEqual') },\n { value: 'notequal', text: this.l10n.getConstant('NotEqual') },\n { value: 'isnull', text: this.l10n.getConstant('IsNull') },\n { value: 'isnotnull', text: this.l10n.getConstant('NotNull') }\n ];\n this.customOperators = {\n stringOperator: [\n { value: 'startswith', text: this.l10n.getConstant('StartsWith') },\n { value: 'endswith', text: this.l10n.getConstant('EndsWith') },\n { value: 'contains', text: this.l10n.getConstant('Contains') },\n { value: 'equal', text: this.l10n.getConstant('Equal') },\n { value: 'isempty', text: this.l10n.getConstant('IsEmpty') },\n { value: 'doesnotstartwith', text: this.l10n.getConstant('NotStartsWith') },\n { value: 'doesnotendwith', text: this.l10n.getConstant('NotEndsWith') },\n { value: 'doesnotcontain', text: this.l10n.getConstant('NotContains') },\n { value: 'notequal', text: this.l10n.getConstant('NotEqual') },\n { value: 'isnotempty', text: this.l10n.getConstant('IsNotEmpty') },\n { value: 'like', text: this.l10n.getConstant('Like') }\n ],\n numberOperator: numOptr,\n dateOperator: numOptr,\n datetimeOperator: numOptr,\n dateonlyOperator: numOptr,\n booleanOperator: [\n { value: 'equal', text: this.l10n.getConstant('Equal') },\n { value: 'notequal', text: this.l10n.getConstant('NotEqual') }\n ]\n };\n };\n /**\n * @param {string} field - specifies the field name\n * @returns {void}\n * @hidden\n */\n Filter.prototype.openMenuByField = function (field) {\n var gObj = this.parent;\n if (gObj.enableAdaptiveUI) {\n this.showCustomFilter(false);\n return;\n }\n var column = gObj.getColumnByField(field);\n var header = gObj.getColumnHeaderByField(field);\n var target = header.querySelector('.e-filtermenudiv');\n if (!target) {\n return;\n }\n var gClient = gObj.element.getBoundingClientRect();\n var fClient = target.getBoundingClientRect();\n this.filterDialogOpen(column, target, fClient.right - gClient.left, fClient.bottom - gClient.top);\n };\n Filter.prototype.filterIconClickHandler = function (e) {\n var target = e.target;\n if (target.classList.contains('e-filtermenudiv') && (this.parent.filterSettings.type === 'Menu' ||\n this.parent.filterSettings.type === 'CheckBox' || this.parent.filterSettings.type === 'Excel')) {\n var gObj = this.parent;\n var col = gObj.getColumnByUid(parentsUntil(target, 'e-headercell').firstElementChild.getAttribute('e-mappinguid'));\n this.column = col;\n if (this.fltrDlgDetails.field === col.field && this.fltrDlgDetails.isOpen) {\n return;\n }\n if (this.filterModule) {\n this.filterModule.closeDialog();\n }\n this.fltrDlgDetails = { field: col.field, isOpen: true };\n this.openMenuByField(col.field);\n }\n };\n Filter.prototype.clickHandler = function (e) {\n if (this.filterSettings.type === 'FilterBar' && this.filterSettings.showFilterBarOperator) {\n if (parentsUntil(e.target, 'e-filterbarcell') &&\n e.target.classList.contains('e-input-group-icon')) {\n var filterOperatorElement = closest(e.target, 'div').\n querySelector('.e-filterbaroperator');\n if (filterOperatorElement) {\n filterOperatorElement.focus();\n }\n else {\n e.target.focus();\n }\n }\n if (e.target.classList.contains('e-list-item')) {\n var inputId = document.querySelector('.e-popup-open').getAttribute('id').replace('_popup', '');\n if (inputId.indexOf('grid-column') !== -1) {\n closest(document.getElementById(inputId), 'div').querySelector('.e-filtertext').focus();\n }\n }\n }\n if (this.filterSettings.mode === 'Immediate' || this.parent.filterSettings.type === 'Menu' ||\n this.parent.filterSettings.type === 'CheckBox' || this.parent.filterSettings.type === 'Excel') {\n var target = e.target;\n var datepickerEle = target.classList.contains('e-day'); // due to datepicker popup cause\n var dialog = parentsUntil(this.parent.element, 'e-dialog');\n var hasDialog = false;\n var popupEle = parentsUntil(target, 'e-popup');\n var hasDialogClosed = this.parent.element.classList.contains('e-device') ? document.querySelector('.e-filter-popup')\n : this.parent.element.querySelector('.e-filter-popup');\n if (dialog && popupEle) {\n hasDialog = dialog.id === popupEle.id;\n }\n if ((this.filterModule && hasDialogClosed && (parentsUntil(target, 'e-excel-ascending') ||\n parentsUntil(target, 'e-excel-descending')))) {\n this.filterModule.closeDialog(target);\n }\n if (parentsUntil(target, 'e-filter-popup') || target.classList.contains('e-filtermenudiv')) {\n return;\n }\n else if (this.filterModule && !parentsUntil(target, 'e-date-overflow') && (!parentsUntil(target, 'e-popup-wrapper')\n && (!closest(target, '.e-filter-item.e-menu-item'))) && !datepickerEle\n && !(parentsUntil(target, 'e-search-wrapper') && !hasDialogClosed)) {\n if ((hasDialog && (!parentsUntil(target, 'e-filter-popup'))\n && (!parentsUntil(target, 'e-popup-flmenu'))) || (!popupEle && hasDialogClosed)) {\n this.filterModule.isresetFocus = parentsUntil(target, 'e-grid') &&\n parentsUntil(target, 'e-grid').id === this.parent.element.id && !(parentsUntil(target, 'e-search-wrapper')\n && hasDialogClosed);\n this.filterModule.closeDialog(target);\n }\n }\n }\n };\n Filter.prototype.filterHandler = function (args) {\n this.actualPredicate[args.field] = args.actualPredicate;\n this.actualData = Object.keys(this.actualPredicate);\n var dataManager = new DataManager(this.filterSettings.columns);\n var query = new Query().where('field', this.filterOperators.equal, args.field);\n this.checkboxFilterObject = dataManager.dataSource.json;\n this.checkboxPrevFilterObject = dataManager.executeLocal(query);\n for (var i = 0; i < this.checkboxPrevFilterObject.length; i++) {\n var index = -1;\n for (var j = 0; j < this.filterSettings.columns.length; j++) {\n if (this.checkboxPrevFilterObject[parseInt(i.toString(), 10)].field ===\n this.filterSettings.columns[parseInt(j.toString(), 10)].field) {\n index = j;\n break;\n }\n }\n if (index !== -1) {\n this.filterSettings.columns.splice(index, 1);\n }\n }\n if (this.values[args.field]) {\n delete this.values[args.field];\n }\n var col = this.parent.getColumnByField(args.field);\n var iconClass = this.parent.showColumnMenu && col.showColumnMenu ? '.e-columnmenu' : '.e-icon-filter';\n var filterIconElement = this.parent.getColumnHeaderByField(args.field).querySelector(iconClass);\n if (args.action === 'filtering') {\n this.filterSettings.columns = this.filterSettings.columns.concat(args.filterCollection);\n if (this.filterSettings.columns.length && filterIconElement) {\n filterIconElement.classList.add('e-filtered');\n }\n }\n else {\n if (filterIconElement) {\n filterIconElement.classList.remove('e-filtered');\n }\n args.requestType = 'filtering';\n this.parent.renderModule.refresh(args); //hot-fix onpropertychanged not working for object { array }\n }\n this.parent.dataBind();\n };\n Filter.prototype.updateFilter = function () {\n var cols = this.filterSettings.columns;\n this.actualPredicate = {};\n for (var i = 0; i < cols.length; i++) {\n this.column = this.parent.getColumnByField(cols[parseInt(i.toString(), 10)].field) ||\n getColumnByForeignKeyValue(cols[parseInt(i.toString(), 10)].field, this.parent.getForeignKeyColumns());\n var fieldName = cols[parseInt(i.toString(), 10)].field;\n if (!this.parent.getColumnByField(cols[parseInt(i.toString(), 10)].field)) {\n fieldName = getColumnByForeignKeyValue(cols[parseInt(i.toString(), 10)].field, this.parent.getForeignKeyColumns()).field;\n }\n this.refreshFilterIcon(fieldName, cols[parseInt(i.toString(), 10)].operator, cols[parseInt(i.toString(), 10)].value, cols[parseInt(i.toString(), 10)].type, cols[parseInt(i.toString(), 10)].predicate, cols[parseInt(i.toString(), 10)].matchCase, cols[parseInt(i.toString(), 10)].ignoreAccent, cols[parseInt(i.toString(), 10)].uid);\n }\n };\n Filter.prototype.refreshFilterIcon = function (fieldName, operator, value, type, predicate, matchCase, ignoreAccent, uid) {\n var obj = {\n field: fieldName,\n predicate: predicate,\n matchCase: matchCase,\n ignoreAccent: ignoreAccent,\n operator: operator,\n value: value,\n type: type\n };\n if (this.actualPredicate[\"\" + fieldName]) {\n this.actualPredicate[\"\" + fieldName].push(obj);\n }\n else {\n this.actualPredicate[\"\" + fieldName] = [obj];\n }\n var field = uid ? this.parent.grabColumnByUidFromAllCols(uid).field : fieldName;\n this.addFilteredClass(field);\n };\n Filter.prototype.addFilteredClass = function (fieldName) {\n var filterIconElement;\n var col = this.parent.getColumnByField(fieldName);\n if (this.parent.showColumnMenu && col.showColumnMenu) {\n filterIconElement = this.parent.getColumnHeaderByField(fieldName).querySelector('.e-columnmenu');\n }\n else if (col) {\n filterIconElement = this.parent.getColumnHeaderByField(fieldName).querySelector('.e-icon-filter');\n }\n if (filterIconElement) {\n filterIconElement.classList.add('e-filtered');\n }\n };\n /**\n * @hidden\n * @returns {FilterUI} returns the FilterUI\n */\n Filter.prototype.getFilterUIInfo = function () {\n return this.filterModule ? this.filterModule.getFilterUIInfo() : {};\n };\n /**\n * @param {string} field - specifies the field name\n * @returns {string} returns the operator name\n * @hidden\n */\n Filter.prototype.getOperatorName = function (field) {\n return document.getElementById(this.parent.getColumnByField(field).uid).ej2_instances[0].value;\n };\n /**\n * Renders checkbox items in Menu filter dialog.\n *\n * @returns {void}\n */\n Filter.prototype.renderCheckboxOnFilterMenu = function () {\n return this.filterModule.renderCheckBoxMenu();\n };\n return Filter;\n}());\nexport { Filter };\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var TrendlinesDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-trendlines';\n }\n }\n});\nexport var TrendlinesPlugin = {\n name: 'e-trendlines',\n install: function (Vue) {\n Vue.component(TrendlinesPlugin.name, TrendlinesDirective);\n }\n};\nexport var TrendlineDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-trendline';\n }\n }\n});\nexport var TrendlinePlugin = {\n name: 'e-trendline',\n install: function (Vue) {\n Vue.component(TrendlinePlugin.name, TrendlineDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var SegmentsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-segments';\n }\n }\n});\nexport var SegmentsPlugin = {\n name: 'e-segments',\n install: function (Vue) {\n Vue.component(SegmentsPlugin.name, SegmentsDirective);\n }\n};\nexport var SegmentDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-segment';\n }\n }\n});\nexport var SegmentPlugin = {\n name: 'e-segment',\n install: function (Vue) {\n Vue.component(SegmentPlugin.name, SegmentDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var SeriesCollectionDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-series-collection';\n }\n }\n});\nexport var SeriesCollectionPlugin = {\n name: 'e-series-collection',\n install: function (Vue) {\n Vue.component(SeriesCollectionPlugin.name, SeriesCollectionDirective);\n }\n};\nexport var SeriesDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-series';\n }\n }\n});\nexport var SeriesPlugin = {\n name: 'e-series',\n install: function (Vue) {\n Vue.component(SeriesPlugin.name, SeriesDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var StripLinesDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-striplines';\n }\n }\n});\nexport var StripLinesPlugin = {\n name: 'e-striplines',\n install: function (Vue) {\n Vue.component(StripLinesPlugin.name, StripLinesDirective);\n }\n};\nexport var StripLineDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-stripline';\n }\n }\n});\nexport var StripLinePlugin = {\n name: 'e-stripline',\n install: function (Vue) {\n Vue.component(StripLinePlugin.name, StripLineDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var CategoriesDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-categories';\n }\n }\n});\nexport var CategoriesPlugin = {\n name: 'e-categories',\n install: function (Vue) {\n Vue.component(CategoriesPlugin.name, CategoriesDirective);\n }\n};\nexport var CategoryDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-category';\n }\n }\n});\nexport var CategoryPlugin = {\n name: 'e-category',\n install: function (Vue) {\n Vue.component(CategoryPlugin.name, CategoryDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var MultiLevelLabelsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-multilevellabels';\n }\n }\n});\nexport var MultiLevelLabelsPlugin = {\n name: 'e-multilevellabels',\n install: function (Vue) {\n Vue.component(MultiLevelLabelsPlugin.name, MultiLevelLabelsDirective);\n }\n};\nexport var MultiLevelLabelDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-multilevellabel';\n }\n }\n});\nexport var MultiLevelLabelPlugin = {\n name: 'e-multilevellabel',\n install: function (Vue) {\n Vue.component(MultiLevelLabelPlugin.name, MultiLevelLabelDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var AxesDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-axes';\n }\n }\n});\nexport var AxesPlugin = {\n name: 'e-axes',\n install: function (Vue) {\n Vue.component(AxesPlugin.name, AxesDirective);\n }\n};\nexport var AxisDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-axis';\n }\n }\n});\nexport var AxisPlugin = {\n name: 'e-axis',\n install: function (Vue) {\n Vue.component(AxisPlugin.name, AxisDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var RowsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-rows';\n }\n }\n});\nexport var RowsPlugin = {\n name: 'e-rows',\n install: function (Vue) {\n Vue.component(RowsPlugin.name, RowsDirective);\n }\n};\nexport var RowDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-row';\n }\n }\n});\nexport var RowPlugin = {\n name: 'e-row',\n install: function (Vue) {\n Vue.component(RowPlugin.name, RowDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var ColumnsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-columns';\n }\n }\n});\nexport var ColumnsPlugin = {\n name: 'e-columns',\n install: function (Vue) {\n Vue.component(ColumnsPlugin.name, ColumnsDirective);\n }\n};\nexport var ColumnDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-column';\n }\n }\n});\nexport var ColumnPlugin = {\n name: 'e-column',\n install: function (Vue) {\n Vue.component(ColumnPlugin.name, ColumnDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var RangeColorSettingsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-rangecolorsettings';\n }\n }\n});\nexport var RangeColorSettingsPlugin = {\n name: 'e-rangecolorsettings',\n install: function (Vue) {\n Vue.component(RangeColorSettingsPlugin.name, RangeColorSettingsDirective);\n }\n};\nexport var RangeColorSettingDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-rangecolorsetting';\n }\n }\n});\nexport var RangeColorSettingPlugin = {\n name: 'e-rangecolorsetting',\n install: function (Vue) {\n Vue.component(RangeColorSettingPlugin.name, RangeColorSettingDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var AnnotationsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-annotations';\n }\n }\n});\nexport var AnnotationsPlugin = {\n name: 'e-annotations',\n install: function (Vue) {\n Vue.component(AnnotationsPlugin.name, AnnotationsDirective);\n }\n};\n/**\n * `e-annotation` directive represent a annotation of the VueJS Chart.\n * It must be contained in a Chart component(`ejs-chart`).\n * ```vue\n * <ejs-chart>\n * <e-annotations>\n * <e-annotation content='ID' />\n * <e-annotation content='ID' />\n * </e-annotations>\n * </ejs-chart>\n * ```\n */\nexport var AnnotationDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-annotation';\n }\n }\n});\nexport var AnnotationPlugin = {\n name: 'e-annotation',\n install: function (Vue) {\n Vue.component(AnnotationPlugin.name, AnnotationDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var SelectedDataIndexesDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-selecteddataindexes';\n }\n }\n});\nexport var SelectedDataIndexesPlugin = {\n name: 'e-selecteddataindexes',\n install: function (Vue) {\n Vue.component(SelectedDataIndexesPlugin.name, SelectedDataIndexesDirective);\n }\n};\nexport var SelectedDataIndexDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-selecteddataindex';\n }\n }\n});\nexport var SelectedDataIndexPlugin = {\n name: 'e-selecteddataindex',\n install: function (Vue) {\n Vue.component(SelectedDataIndexPlugin.name, SelectedDataIndexDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var IndicatorsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-indicators';\n }\n }\n});\nexport var IndicatorsPlugin = {\n name: 'e-indicators',\n install: function (Vue) {\n Vue.component(IndicatorsPlugin.name, IndicatorsDirective);\n }\n};\nexport var IndicatorDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-indicator';\n }\n }\n});\nexport var IndicatorPlugin = {\n name: 'e-indicator',\n install: function (Vue) {\n Vue.component(IndicatorPlugin.name, IndicatorDirective);\n }\n};\n","import { ComponentBase, gh, getProps, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined, getValue } from '@syncfusion/ej2-base';\nimport { isUndefined } from '@syncfusion/ej2-base';\nimport { Chart } from '@syncfusion/ej2-charts';\nimport { TrendlinesDirective, TrendlineDirective, TrendlinesPlugin, TrendlinePlugin } from './trendlines.directive';\nimport { SegmentsDirective, SegmentDirective, SegmentsPlugin, SegmentPlugin } from './segments.directive';\nimport { SeriesCollectionDirective, SeriesDirective, SeriesCollectionPlugin, SeriesPlugin } from './series.directive';\nimport { StripLinesDirective, StripLineDirective, StripLinesPlugin, StripLinePlugin } from './striplines.directive';\nimport { CategoriesDirective, CategoryDirective, CategoriesPlugin, CategoryPlugin } from './categories.directive';\nimport { MultiLevelLabelsDirective, MultiLevelLabelDirective, MultiLevelLabelsPlugin, MultiLevelLabelPlugin } from './multilevellabels.directive';\nimport { AxesDirective, AxisDirective, AxesPlugin, AxisPlugin } from './axes.directive';\nimport { RowsDirective, RowDirective, RowsPlugin, RowPlugin } from './rows.directive';\nimport { ColumnsDirective, ColumnDirective, ColumnsPlugin, ColumnPlugin } from './columns.directive';\nimport { RangeColorSettingsDirective, RangeColorSettingDirective, RangeColorSettingsPlugin, RangeColorSettingPlugin } from './rangecolorsettings.directive';\nimport { AnnotationsDirective, AnnotationDirective, AnnotationsPlugin, AnnotationPlugin } from './annotations.directive';\nimport { SelectedDataIndexesDirective, SelectedDataIndexDirective, SelectedDataIndexesPlugin, SelectedDataIndexPlugin } from './selecteddataindexes.directive';\nimport { IndicatorsDirective, IndicatorDirective, IndicatorsPlugin, IndicatorPlugin } from './indicators.directive';\nexport var properties = ['isLazyUpdate', 'plugins', 'allowExport', 'allowMultiSelection', 'annotations', 'axes', 'background', 'backgroundImage', 'border', 'chartArea', 'columns', 'crosshair', 'currencyCode', 'dataSource', 'description', 'enableAnimation', 'enableAutoIntervalOnBothAxis', 'enableCanvas', 'enableExport', 'enablePersistence', 'enableRtl', 'enableSideBySidePlacement', 'height', 'highlightColor', 'highlightMode', 'highlightPattern', 'indicators', 'isMultiSelect', 'isTransposed', 'legendSettings', 'locale', 'margin', 'palettes', 'primaryXAxis', 'primaryYAxis', 'rangeColorSettings', 'rows', 'selectedDataIndexes', 'selectionMode', 'selectionPattern', 'series', 'subTitle', 'subTitleStyle', 'tabIndex', 'theme', 'title', 'titleStyle', 'tooltip', 'useGroupingSeparator', 'width', 'zoomSettings', 'afterExport', 'animationComplete', 'annotationRender', 'axisLabelClick', 'axisLabelRender', 'axisMultiLabelRender', 'axisRangeCalculated', 'beforeExport', 'beforePrint', 'beforeResize', 'chartDoubleClick', 'chartMouseClick', 'chartMouseDown', 'chartMouseLeave', 'chartMouseMove', 'chartMouseUp', 'drag', 'dragComplete', 'dragEnd', 'dragStart', 'legendClick', 'legendRender', 'load', 'loaded', 'multiLevelLabelClick', 'onZooming', 'pointClick', 'pointDoubleClick', 'pointMove', 'pointRender', 'resized', 'scrollChanged', 'scrollEnd', 'scrollStart', 'selectionComplete', 'seriesRender', 'sharedTooltipRender', 'textRender', 'tooltipRender', 'zoomComplete'];\nexport var modelProps = ['dataSource'];\nexport var testProp = getProps({ props: properties });\nexport var props = testProp[0], watch = testProp[1], emitProbs = Object.keys(watch);\nemitProbs.push('modelchanged', 'update:modelValue');\nfor (var _i = 0, modelProps_1 = modelProps; _i < modelProps_1.length; _i++) {\n var props_1 = modelProps_1[_i];\n emitProbs.push('update:' + props_1);\n}\n/**\n * Represents Vuejs chart Component\n * ```vue\n * <ejs-chart></ejs-chart>\n * ```\n */\nexport var ChartComponent = vueDefineComponent({\n name: 'ChartComponent',\n mixins: [ComponentBase],\n props: props,\n watch: watch,\n emits: emitProbs,\n model: { event: 'modelchanged' },\n provide: function () { return { custom: this.custom }; },\n data: function () {\n return {\n ej2Instances: new Chart({}),\n propKeys: properties,\n models: modelProps,\n hasChildDirective: true,\n hasInjectedModules: true,\n tagMapper: { \"e-series-collection\": { \"e-series\": { \"e-trendlines\": \"e-trendline\", \"e-segments\": \"e-segment\" } }, \"e-axes\": { \"e-axis\": { \"e-striplines\": \"e-stripline\", \"e-multilevellabels\": { \"e-multilevellabel\": { \"e-categories\": \"e-category\" } } } }, \"e-rows\": \"e-row\", \"e-columns\": \"e-column\", \"e-rangecolorsettings\": \"e-rangecolorsetting\", \"e-annotations\": \"e-annotation\", \"e-selecteddataindexes\": \"e-selecteddataindex\", \"e-indicators\": \"e-indicator\" },\n tagNameMapper: { \"e-series-collection\": \"e-series\", \"e-striplines\": \"e-stripLines\", \"e-multilevellabels\": \"e-multiLevelLabels\", \"e-rangecolorsettings\": \"e-rangeColorSettings\", \"e-selecteddataindexes\": \"e-selectedDataIndexes\" },\n isVue3: !isExecute,\n templateCollection: {},\n };\n },\n created: function () {\n this.ej2Instances._trigger = this.ej2Instances.trigger;\n this.ej2Instances.trigger = this.trigger;\n this.bindProperties();\n this.ej2Instances._setProperties = this.ej2Instances.setProperties;\n this.ej2Instances.setProperties = this.setProperties;\n this.ej2Instances.clearTemplate = this.clearTemplate;\n this.updated = this.updated;\n },\n render: function (createElement) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', slots);\n },\n methods: {\n clearTemplate: function (templateNames) {\n if (!templateNames) {\n templateNames = Object.keys(this.templateCollection || {});\n }\n if (templateNames.length && this.templateCollection) {\n for (var _i = 0, templateNames_1 = templateNames; _i < templateNames_1.length; _i++) {\n var tempName = templateNames_1[_i];\n var elementCollection = this.templateCollection[tempName];\n if (elementCollection && elementCollection.length) {\n for (var _a = 0, elementCollection_1 = elementCollection; _a < elementCollection_1.length; _a++) {\n var ele = elementCollection_1[_a];\n var destroy = getValue('__vue__.$destroy', ele);\n if (destroy) {\n ele.__vue__.$destroy();\n }\n if (ele.innerHTML) {\n ele.innerHTML = '';\n }\n }\n delete this.templateCollection[tempName];\n }\n }\n }\n },\n setProperties: function (prop, muteOnChange) {\n var _this = this;\n if (this.isVue3) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if (this.ej2Instances && this.ej2Instances._setProperties) {\n this.ej2Instances._setProperties(prop, muteOnChange);\n }\n if (prop && this.models && this.models.length) {\n Object.keys(prop).map(function (key) {\n _this.models.map(function (model) {\n if ((key === model) && !(/datasource/i.test(key))) {\n if (_this.isVue3) {\n _this.ej2Instances.vueInstance.$emit('update:' + key, prop[key]);\n }\n else {\n _this.$emit('update:' + key, prop[key]);\n _this.$emit('modelchanged', prop[key]);\n }\n }\n });\n });\n }\n },\n trigger: function (eventName, eventProp, successHandler) {\n if (!isExecute) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if ((eventName === 'change' || eventName === 'input') && this.models && (this.models.length !== 0)) {\n var key = this.models.toString().match(/checked|value/) || [];\n var propKey = key[0];\n if (eventProp && key && !isUndefined(eventProp[propKey])) {\n if (!isExecute) {\n this.ej2Instances.vueInstance.$emit('update:' + propKey, eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('modelchanged', eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('update:modelValue', eventProp[propKey]);\n }\n else {\n if (eventName === 'change' || (this.$props && !this.$props.isLazyUpdate)) {\n this.$emit('update:' + propKey, eventProp[propKey]);\n this.$emit('modelchanged', eventProp[propKey]);\n }\n }\n }\n }\n else if ((eventName === 'actionBegin' && eventProp.requestType === 'dateNavigate') && this.models && (this.models.length !== 0)) {\n var key = this.models.toString().match(/currentView|selectedDate/) || [];\n var propKey = key[0];\n if (eventProp && key && !isUndefined(eventProp[propKey])) {\n if (!isExecute) {\n this.ej2Instances.vueInstance.$emit('update:' + propKey, eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('modelchanged', eventProp[propKey]);\n }\n else {\n this.$emit('update:' + propKey, eventProp[propKey]);\n this.$emit('modelchanged', eventProp[propKey]);\n }\n }\n }\n if ((this.ej2Instances && this.ej2Instances._trigger)) {\n this.ej2Instances._trigger(eventName, eventProp, successHandler);\n }\n },\n custom: function () {\n this.updated();\n },\n addAxes: function (axisCollection) {\n return this.ej2Instances.addAxes(axisCollection);\n },\n addSeries: function (seriesCollection) {\n return this.ej2Instances.addSeries(seriesCollection);\n },\n clearSeries: function () {\n return this.ej2Instances.clearSeries();\n },\n createChartSvg: function () {\n return this.ej2Instances.createChartSvg();\n },\n export: function (type, fileName) {\n return this.ej2Instances.export(type, fileName);\n },\n getLocalizedLabel: function (key) {\n return this.ej2Instances.getLocalizedLabel(key);\n },\n hideCrosshair: function () {\n return this.ej2Instances.hideCrosshair();\n },\n hideTooltip: function () {\n return this.ej2Instances.hideTooltip();\n },\n isSecondaryAxis: function (axis) {\n return this.ej2Instances.isSecondaryAxis(axis);\n },\n print: function (id) {\n return this.ej2Instances.print(id);\n },\n processData: function (render) {\n return this.ej2Instances.processData(render);\n },\n refreshLiveData: function () {\n return this.ej2Instances.refreshLiveData();\n },\n removeAxis: function (index) {\n return this.ej2Instances.removeAxis(index);\n },\n removeSeries: function (index) {\n return this.ej2Instances.removeSeries(index);\n },\n setAnnotationValue: function (annotationIndex, content) {\n return this.ej2Instances.setAnnotationValue(annotationIndex, content);\n },\n showCrosshair: function (x, y) {\n return this.ej2Instances.showCrosshair(x, y);\n },\n showTooltip: function (x, y, isPoint) {\n return this.ej2Instances.showTooltip(x, y, isPoint);\n },\n }\n});\nexport var ChartPlugin = {\n name: 'ejs-chart',\n install: function (Vue) {\n Vue.component(ChartPlugin.name, ChartComponent);\n Vue.component(SeriesPlugin.name, SeriesDirective);\n Vue.component(SeriesCollectionPlugin.name, SeriesCollectionDirective);\n Vue.component(TrendlinePlugin.name, TrendlineDirective);\n Vue.component(TrendlinesPlugin.name, TrendlinesDirective);\n Vue.component(SegmentPlugin.name, SegmentDirective);\n Vue.component(SegmentsPlugin.name, SegmentsDirective);\n Vue.component(AxisPlugin.name, AxisDirective);\n Vue.component(AxesPlugin.name, AxesDirective);\n Vue.component(StripLinePlugin.name, StripLineDirective);\n Vue.component(StripLinesPlugin.name, StripLinesDirective);\n Vue.component(MultiLevelLabelPlugin.name, MultiLevelLabelDirective);\n Vue.component(MultiLevelLabelsPlugin.name, MultiLevelLabelsDirective);\n Vue.component(CategoryPlugin.name, CategoryDirective);\n Vue.component(CategoriesPlugin.name, CategoriesDirective);\n Vue.component(RowPlugin.name, RowDirective);\n Vue.component(RowsPlugin.name, RowsDirective);\n Vue.component(ColumnPlugin.name, ColumnDirective);\n Vue.component(ColumnsPlugin.name, ColumnsDirective);\n Vue.component(RangeColorSettingPlugin.name, RangeColorSettingDirective);\n Vue.component(RangeColorSettingsPlugin.name, RangeColorSettingsDirective);\n Vue.component(AnnotationPlugin.name, AnnotationDirective);\n Vue.component(AnnotationsPlugin.name, AnnotationsDirective);\n Vue.component(SelectedDataIndexPlugin.name, SelectedDataIndexDirective);\n Vue.component(SelectedDataIndexesPlugin.name, SelectedDataIndexesDirective);\n Vue.component(IndicatorPlugin.name, IndicatorDirective);\n Vue.component(IndicatorsPlugin.name, IndicatorsDirective);\n }\n};\n","//! moment.js locale configuration\n//! locale : Yoruba Nigeria [yo]\n//! author : Atolagbe Abisoye : https://github.com/andela-batolagbe\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var yo = moment.defineLocale('yo', {\n months: 'SẹÌrẹÌ_EÌ€reÌ€leÌ€_Ẹrẹ̀naÌ€_IÌ€gbeÌ_EÌ€bibi_OÌ€kuÌ€du_Agẹmo_OÌ€guÌn_Owewe_Ọ̀waÌ€raÌ€_BeÌluÌ_Ọ̀pẹ̀̀'.split(\n '_'\n ),\n monthsShort: 'SẹÌr_EÌ€rl_Ẹrn_IÌ€gb_EÌ€bi_OÌ€kuÌ€_Agẹ_OÌ€guÌ_Owe_Ọ̀waÌ€_BeÌl_Ọ̀pẹ̀̀'.split('_'),\n weekdays: 'AÌ€iÌ€kuÌ_AjeÌ_IÌ€sẹÌgun_Ọjá»ÌruÌ_Ọjá»Ìbá»_ẸtiÌ€_AÌ€baÌmẹÌta'.split('_'),\n weekdaysShort: 'AÌ€iÌ€k_AjeÌ_IÌ€sẹÌ_Ọjr_Ọjb_ẸtiÌ€_AÌ€baÌ'.split('_'),\n weekdaysMin: 'AÌ€iÌ€_Aj_IÌ€s_Ọr_Ọb_Ẹt_AÌ€b'.split('_'),\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY h:mm A',\n LLLL: 'dddd, D MMMM YYYY h:mm A',\n },\n calendar: {\n sameDay: '[OÌ€niÌ€ ni] LT',\n nextDay: '[Ọ̀la ni] LT',\n nextWeek: \"dddd [Ọsẹ̀ toÌn'bá»] [ni] LT\",\n lastDay: '[AÌ€na ni] LT',\n lastWeek: 'dddd [Ọsẹ̀ toÌlá»Ì] [ni] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'niÌ %s',\n past: '%s ká»jaÌ',\n s: 'iÌ€sẹjuÌ aayaÌ die',\n ss: 'aayaÌ %d',\n m: 'iÌ€sẹjuÌ kan',\n mm: 'iÌ€sẹjuÌ %d',\n h: 'waÌkati kan',\n hh: 'waÌkati %d',\n d: 'á»já»Ì kan',\n dd: 'á»já»Ì %d',\n M: 'osuÌ€ kan',\n MM: 'osuÌ€ %d',\n y: 'á»duÌn kan',\n yy: 'á»duÌn %d',\n },\n dayOfMonthOrdinalParse: /á»já»Ì\\s\\d{1,2}/,\n ordinal: 'á»já»Ì %d',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return yo;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n// eslint-disable-next-line @typescript-eslint/triple-slash-reference\n/// <reference path='../drop-down-list/drop-down-list-model.d.ts'/>\nimport { EventHandler, Property, Event, addClass, Browser, removeClass, detach } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, NotifyPropertyChanges, getValue, setValue } from '@syncfusion/ej2-base';\nimport { DropDownList, dropDownListClasses } from '../drop-down-list/drop-down-list';\nimport { Search } from '../common/incremental-search';\nimport { createSpinner, showSpinner, hideSpinner } from '@syncfusion/ej2-popups';\nimport { Input } from '@syncfusion/ej2-inputs';\nimport { DataManager, Predicate, Query } from '@syncfusion/ej2-data';\nvar SPINNER_CLASS = 'e-atc-spinner-icon';\ndropDownListClasses.root = 'e-combobox';\nvar inputObject = {\n container: null,\n buttons: []\n};\n/**\n * The ComboBox component allows the user to type a value or choose an option from the list of predefined options.\n * ```html\n * <select id=\"list\">\n * <option value='1'>Badminton</option>\n * <option value='2'>Basketball</option>\n * <option value='3'>Cricket</option>\n * <option value='4'>Football</option>\n * <option value='5'>Tennis</option>\n * </select>\n * ```\n * ```typescript\n * let games:ComboBox = new ComboBox();\n * games.appendTo(\"#list\");\n * ```\n */\nvar ComboBox = /** @class */ (function (_super) {\n __extends(ComboBox, _super);\n /**\n * *Constructor for creating the component\n *\n * @param {ComboBoxModel} options - Specifies the ComboBox model.\n * @param {string | HTMLElement} element - Specifies the element to render as component.\n * @private\n */\n function ComboBox(options, element) {\n return _super.call(this, options, element) || this;\n }\n /**\n * Initialize the event handler\n *\n * @private\n * @returns {void}\n */\n ComboBox.prototype.preRender = function () {\n _super.prototype.preRender.call(this);\n };\n ComboBox.prototype.getLocaleName = function () {\n return 'combo-box';\n };\n ComboBox.prototype.wireEvent = function () {\n if (this.getModuleName() === 'combobox') {\n EventHandler.add(this.inputWrapper.buttons[0], 'mousedown', this.preventBlur, this);\n EventHandler.add(this.inputWrapper.container, 'blur', this.onBlurHandler, this);\n }\n if (!isNullOrUndefined(this.inputWrapper.buttons[0])) {\n EventHandler.add(this.inputWrapper.buttons[0], 'mousedown', this.dropDownClick, this);\n }\n EventHandler.add(this.inputElement, 'focus', this.targetFocus, this);\n if (!this.readonly) {\n EventHandler.add(this.inputElement, 'input', this.onInput, this);\n EventHandler.add(this.inputElement, 'keyup', this.onFilterUp, this);\n EventHandler.add(this.inputElement, 'keydown', this.onFilterDown, this);\n EventHandler.add(this.inputElement, 'paste', this.pasteHandler, this);\n EventHandler.add(window, 'resize', this.windowResize, this);\n }\n this.bindCommonEvent();\n };\n ComboBox.prototype.preventBlur = function (e) {\n if ((!this.allowFiltering && document.activeElement !== this.inputElement &&\n !document.activeElement.classList.contains(dropDownListClasses.input) && Browser.isDevice || !Browser.isDevice)) {\n e.preventDefault();\n }\n };\n ComboBox.prototype.onBlurHandler = function (e) {\n var inputValue = this.inputElement && this.inputElement.value === '' ?\n null : this.inputElement && this.inputElement.value;\n if (!isNullOrUndefined(this.listData) && !isNullOrUndefined(inputValue) && inputValue !== this.text) {\n this.customValue(e);\n }\n _super.prototype.onBlurHandler.call(this, e);\n };\n ComboBox.prototype.targetElement = function () {\n return this.inputElement;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n ComboBox.prototype.setOldText = function (text) {\n Input.setValue(this.text, this.inputElement, this.floatLabelType, this.showClearButton);\n this.customValue();\n this.removeSelection();\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n ComboBox.prototype.setOldValue = function (value) {\n if (this.allowCustom) {\n this.valueMuteChange(this.value);\n }\n else {\n this.valueMuteChange(null);\n }\n this.removeSelection();\n this.setHiddenValue();\n };\n ComboBox.prototype.valueMuteChange = function (value) {\n var inputValue = isNullOrUndefined(value) ? null : value.toString();\n Input.setValue(inputValue, this.inputElement, this.floatLabelType, this.showClearButton);\n this.setProperties({ value: value, text: value, index: null }, true);\n this.activeIndex = this.index;\n var fields = this.fields;\n var dataItem = {};\n dataItem[fields.text] = isNullOrUndefined(value) ? null : value.toString();\n dataItem[fields.value] = isNullOrUndefined(value) ? null : value.toString();\n this.itemData = dataItem;\n this.item = null;\n if (this.previousValue !== this.value) {\n this.detachChangeEvent(null);\n }\n };\n ComboBox.prototype.updateValues = function () {\n if (!isNullOrUndefined(this.value)) {\n var li = this.getElementByValue(this.value);\n var isExistItem = !isNullOrUndefined(li) ? true : false;\n if (this.enableVirtualization && this.value) {\n var fields = (this.fields.value) ? this.fields.value : '';\n if (this.dataSource instanceof DataManager && this.virtualGroupDataSource) {\n var getItem = new DataManager(this.virtualGroupDataSource).executeLocal(new Query().where(new Predicate(fields, 'equal', this.value)));\n if (getItem && getItem.length > 0) {\n this.itemData = getItem[0];\n isExistItem = true;\n var dataItem = this.getItemData();\n if ((this.value === dataItem.value && this.text !== dataItem.text) || (this.value !== dataItem.value && this.text === dataItem.text)) {\n this.setProperties({ 'text': dataItem.text, 'value': dataItem.value });\n }\n }\n }\n else {\n var getItem = new DataManager(this.dataSource).executeLocal(new Query().where(new Predicate(fields, 'equal', this.value)));\n if (getItem && getItem.length > 0) {\n this.itemData = getItem[0];\n isExistItem = true;\n var dataItem = this.getItemData();\n if ((this.value === dataItem.value && this.text !== dataItem.text) || (this.value !== dataItem.value && this.text === dataItem.text)) {\n this.setProperties({ 'text': dataItem.text, 'value': dataItem.value });\n }\n }\n }\n }\n if (li) {\n this.setSelection(li, null);\n }\n else if ((!this.enableVirtualization && this.allowCustom) || (this.allowCustom && this.enableVirtualization && !isExistItem)) {\n this.valueMuteChange(this.value);\n }\n else if (!this.enableVirtualization || (this.enableVirtualization && !isExistItem)) {\n this.valueMuteChange(null);\n }\n }\n else if (this.text && isNullOrUndefined(this.value)) {\n var li = this.getElementByText(this.text);\n if (li) {\n this.setSelection(li, null);\n }\n else {\n Input.setValue(this.text, this.inputElement, this.floatLabelType, this.showClearButton);\n this.customValue();\n }\n }\n else {\n this.setSelection(this.liCollections[this.activeIndex], null);\n }\n this.setHiddenValue();\n Input.setValue(this.text, this.inputElement, this.floatLabelType, this.showClearButton);\n };\n ComboBox.prototype.updateIconState = function () {\n if (this.showClearButton) {\n if (this.inputElement && this.inputElement.value !== '' && !this.readonly) {\n removeClass([this.inputWrapper.clearButton], dropDownListClasses.clearIconHide);\n }\n else {\n addClass([this.inputWrapper.clearButton], dropDownListClasses.clearIconHide);\n }\n }\n };\n ComboBox.prototype.getAriaAttributes = function () {\n var ariaAttributes = {\n 'role': 'combobox',\n 'aria-autocomplete': 'both',\n 'aria-labelledby': this.hiddenElement.id,\n 'aria-expanded': 'false',\n 'aria-readonly': this.readonly.toString(),\n 'autocomplete': 'off',\n 'autocapitalize': 'off',\n 'spellcheck': 'false'\n };\n return ariaAttributes;\n };\n ComboBox.prototype.searchLists = function (e) {\n this.isTyped = true;\n if (this.isFiltering()) {\n _super.prototype.searchLists.call(this, e);\n if (this.ulElement && this.filterInput.value.trim() === '') {\n this.setHoverList(this.ulElement.querySelector('.' + dropDownListClasses.li));\n }\n }\n else {\n if (this.ulElement && this.inputElement.value === '' && this.preventAutoFill) {\n this.setHoverList(this.ulElement.querySelector('.' + dropDownListClasses.li));\n }\n this.incrementalSearch(e);\n }\n };\n ComboBox.prototype.getNgDirective = function () {\n return 'EJS-COMBOBOX';\n };\n ComboBox.prototype.setSearchBox = function () {\n this.filterInput = this.inputElement;\n var searchBoxContainer = (this.isFiltering() || (this.isReact && this.getModuleName() === 'combobox')) ? this.inputWrapper : inputObject;\n return searchBoxContainer;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n ComboBox.prototype.onActionComplete = function (ulElement, list, e, isUpdated) {\n var _this = this;\n _super.prototype.onActionComplete.call(this, ulElement, list, e);\n if (this.isSelectCustom) {\n this.removeSelection();\n }\n if (!this.preventAutoFill && this.getModuleName() === 'combobox' && this.isTyped && !this.enableVirtualization) {\n setTimeout(function () {\n _this.inlineSearch();\n });\n }\n };\n ComboBox.prototype.getFocusElement = function () {\n var dataItem = this.isSelectCustom ? { text: '' } : this.getItemData();\n var selected = !isNullOrUndefined(this.list) ? this.list.querySelector('.' + dropDownListClasses.selected) : this.list;\n var isSelected = dataItem.text && dataItem.text.toString() === this.inputElement.value && !isNullOrUndefined(selected);\n if (isSelected) {\n return selected;\n }\n if ((Browser.isDevice && !this.isDropDownClick || !Browser.isDevice) &&\n !isNullOrUndefined(this.liCollections) && this.liCollections.length > 0) {\n var inputValue = this.inputElement.value;\n var dataSource = this.sortedData;\n var type = this.typeOfData(dataSource).typeof;\n var activeItem = Search(inputValue, this.liCollections, this.filterType, true, dataSource, this.fields, type);\n if (this.enableVirtualization && inputValue !== '' && this.getModuleName() !== 'autocomplete' && this.isTyped && !this.allowFiltering) {\n var updatingincrementalindex = false;\n if ((this.viewPortInfo.endIndex >= this.incrementalEndIndex && this.incrementalEndIndex <= this.totalItemCount) || this.incrementalEndIndex == 0) {\n updatingincrementalindex = true;\n this.incrementalStartIndex = this.incrementalEndIndex;\n if (this.incrementalEndIndex == 0) {\n this.incrementalEndIndex = 100 > this.totalItemCount ? this.totalItemCount : 100;\n }\n else {\n this.incrementalEndIndex = this.incrementalEndIndex + 100 > this.totalItemCount ? this.totalItemCount : this.incrementalEndIndex + 100;\n }\n this.updateIncrementalInfo(this.incrementalStartIndex, this.incrementalEndIndex);\n updatingincrementalindex = true;\n }\n if (this.viewPortInfo.startIndex !== 0 || updatingincrementalindex) {\n this.updateIncrementalView(0, this.itemCount);\n }\n activeItem = Search(inputValue, this.incrementalLiCollections, this.filterType, true, dataSource, this.fields, type);\n while (isNullOrUndefined(activeItem) && this.incrementalEndIndex < this.totalItemCount) {\n this.incrementalStartIndex = this.incrementalEndIndex;\n this.incrementalEndIndex = this.incrementalEndIndex + 100 > this.totalItemCount ? this.totalItemCount : this.incrementalEndIndex + 100;\n this.updateIncrementalInfo(this.incrementalStartIndex, this.incrementalEndIndex);\n updatingincrementalindex = true;\n if (this.viewPortInfo.startIndex !== 0 || updatingincrementalindex) {\n this.updateIncrementalView(0, this.itemCount);\n }\n activeItem = Search(inputValue, this.incrementalLiCollections, this.filterType, true, dataSource, this.fields, type);\n if (!isNullOrUndefined(activeItem)) {\n break;\n }\n if (isNullOrUndefined(activeItem) && this.incrementalEndIndex >= this.totalItemCount) {\n this.incrementalStartIndex = 0;\n this.incrementalEndIndex = 100 > this.totalItemCount ? this.totalItemCount : 100;\n break;\n }\n }\n if (activeItem.index) {\n if ((!(this.viewPortInfo.startIndex >= activeItem.index)) || (!(activeItem.index >= this.viewPortInfo.endIndex))) {\n var startIndex = activeItem.index - ((this.itemCount / 2) - 2) > 0 ? activeItem.index - ((this.itemCount / 2) - 2) : 0;\n var endIndex = this.viewPortInfo.startIndex + this.itemCount > this.totalItemCount ? this.totalItemCount : this.viewPortInfo.startIndex + this.itemCount;\n if (startIndex != this.viewPortInfo.startIndex) {\n this.updateIncrementalView(startIndex, endIndex);\n }\n }\n }\n if (!isNullOrUndefined(activeItem.item)) {\n var index_1 = this.getIndexByValue(activeItem.item.getAttribute('data-value')) - this.skeletonCount;\n if (index_1 > this.itemCount / 2) {\n var startIndex = this.viewPortInfo.startIndex + ((this.itemCount / 2) - 2) < this.totalItemCount ? this.viewPortInfo.startIndex + ((this.itemCount / 2) - 2) : this.totalItemCount;\n var endIndex = this.viewPortInfo.startIndex + this.itemCount > this.totalItemCount ? this.totalItemCount : this.viewPortInfo.startIndex + this.itemCount;\n this.updateIncrementalView(startIndex, endIndex);\n }\n activeItem.item = this.getElementByValue(activeItem.item.getAttribute('data-value'));\n }\n else {\n this.updateIncrementalView(0, this.itemCount);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.list.getElementsByClassName('e-virtual-ddl-content')[0].style = this.getTransformValues();\n this.list.scrollTop = 0;\n }\n if (activeItem && activeItem.item) {\n activeItem.item = this.getElementByValue(activeItem.item.getAttribute('data-value'));\n }\n }\n var activeElement = activeItem.item;\n if (!isNullOrUndefined(activeElement)) {\n var count = this.getIndexByValue(activeElement.getAttribute('data-value')) - 1;\n var height = parseInt(getComputedStyle(this.liCollections[0], null).getPropertyValue('height'), 10);\n if (!isNaN(height) && this.getModuleName() !== 'autocomplete') {\n this.removeFocus();\n var fixedHead = this.fields.groupBy ? this.liCollections[0].offsetHeight : 0;\n if (!this.enableVirtualization) {\n this.list.scrollTop = count * height + fixedHead;\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.list.getElementsByClassName('e-virtual-ddl-content')[0].style = this.getTransformValues();\n if (this.enableVirtualization && !this.fields.groupBy) {\n var selectedLiOffsetTop = this.virtualListInfo && this.virtualListInfo.startIndex ? activeElement.offsetTop + (this.virtualListInfo.startIndex * activeElement.offsetHeight) : activeElement.offsetTop;\n this.list.scrollTop = selectedLiOffsetTop - (this.list.querySelectorAll('.e-virtual-list').length * activeElement.offsetHeight);\n }\n }\n addClass([activeElement], dropDownListClasses.focus);\n }\n }\n else {\n if (this.isSelectCustom && this.inputElement.value.trim() !== '') {\n this.removeFocus();\n if (!this.enableVirtualization) {\n this.list.scrollTop = 0;\n }\n }\n }\n return activeElement;\n }\n else {\n return null;\n }\n };\n ComboBox.prototype.setValue = function (e) {\n if (e && e.type === 'keydown' && e.action === 'enter') {\n this.removeFillSelection();\n }\n if (this.autofill && this.getModuleName() === 'combobox' && e && e.type === 'keydown' && e.action !== 'enter') {\n this.preventAutoFill = false;\n this.inlineSearch(e);\n return false;\n }\n else {\n return _super.prototype.setValue.call(this, e);\n }\n };\n ComboBox.prototype.checkCustomValue = function () {\n this.itemData = this.getDataByValue(this.value);\n var dataItem = this.getItemData();\n if (!(this.allowCustom && isNullOrUndefined(dataItem.value) && isNullOrUndefined(dataItem.text))) {\n this.setProperties({ 'value': dataItem.value }, !this.allowCustom);\n }\n };\n /**\n * Shows the spinner loader.\n *\n * @returns {void}\n\n */\n ComboBox.prototype.showSpinner = function () {\n if (isNullOrUndefined(this.spinnerElement)) {\n this.spinnerElement = (this.getModuleName() === 'autocomplete') ? (this.inputWrapper.buttons[0] ||\n this.inputWrapper.clearButton ||\n Input.appendSpan('e-input-group-icon ' + SPINNER_CLASS, this.inputWrapper.container, this.createElement)) :\n (this.inputWrapper.buttons[0] || this.inputWrapper.clearButton);\n addClass([this.spinnerElement], dropDownListClasses.disableIcon);\n createSpinner({\n target: this.spinnerElement,\n width: Browser.isDevice ? '16px' : '14px'\n }, this.createElement);\n showSpinner(this.spinnerElement);\n }\n };\n /**\n * Hides the spinner loader.\n *\n * @returns {void}\n\n */\n ComboBox.prototype.hideSpinner = function () {\n if (!isNullOrUndefined(this.spinnerElement)) {\n hideSpinner(this.spinnerElement);\n removeClass([this.spinnerElement], dropDownListClasses.disableIcon);\n if (this.spinnerElement.classList.contains(SPINNER_CLASS)) {\n detach(this.spinnerElement);\n }\n else {\n this.spinnerElement.innerHTML = '';\n }\n this.spinnerElement = null;\n }\n };\n ComboBox.prototype.setAutoFill = function (activeElement, isHover) {\n if (!isHover) {\n this.setHoverList(activeElement);\n }\n if (this.autofill && !this.preventAutoFill) {\n var currentValue = this.getTextByValue(activeElement.getAttribute('data-value')).toString();\n var currentFillValue = this.getFormattedValue(activeElement.getAttribute('data-value'));\n if (this.getModuleName() === 'combobox') {\n if (!this.isSelected && this.previousValue !== currentFillValue) {\n this.updateSelectedItem(activeElement, null);\n this.isSelected = true;\n this.previousValue = this.getFormattedValue(activeElement.getAttribute('data-value'));\n }\n else {\n this.updateSelectedItem(activeElement, null, true);\n }\n }\n if (!this.isAndroidAutoFill(currentValue)) {\n this.setAutoFillSelection(currentValue, isHover);\n }\n }\n };\n ComboBox.prototype.isAndroidAutoFill = function (value) {\n if (Browser.isAndroid) {\n var currentPoints = this.getSelectionPoints();\n var prevEnd = this.prevSelectPoints.end;\n var curEnd = currentPoints.end;\n var prevStart = this.prevSelectPoints.start;\n var curStart = currentPoints.start;\n if (prevEnd !== 0 && ((prevEnd === value.length && prevStart === value.length) ||\n (prevStart > curStart && prevEnd > curEnd) || (prevEnd === curEnd && prevStart === curStart))) {\n return true;\n }\n else {\n return false;\n }\n }\n else {\n return false;\n }\n };\n ComboBox.prototype.clearAll = function (e, property) {\n if (isNullOrUndefined(property) || (!isNullOrUndefined(property) && isNullOrUndefined(property.dataSource))) {\n _super.prototype.clearAll.call(this, e);\n }\n if (this.isFiltering() && !isNullOrUndefined(e) && e.target === this.inputWrapper.clearButton) {\n this.searchLists(e);\n }\n };\n ComboBox.prototype.isSelectFocusItem = function (element) {\n return !isNullOrUndefined(element);\n };\n ComboBox.prototype.inlineSearch = function (e) {\n var isKeyNavigate = (e && (e.action === 'down' || e.action === 'up' ||\n e.action === 'home' || e.action === 'end' || e.action === 'pageUp' || e.action === 'pageDown'));\n var activeElement = isKeyNavigate ? this.liCollections[this.activeIndex] : this.getFocusElement();\n if (!isNullOrUndefined(activeElement)) {\n if (!isKeyNavigate) {\n var value = this.getFormattedValue(activeElement.getAttribute('data-value'));\n this.activeIndex = this.getIndexByValue(value);\n this.activeIndex = !isNullOrUndefined(this.activeIndex) ? this.activeIndex : null;\n }\n this.preventAutoFill = this.inputElement.value === '' ? false : this.preventAutoFill;\n this.setAutoFill(activeElement, isKeyNavigate);\n }\n else if (this.inputElement.value === '') {\n this.activeIndex = null;\n if (!isNullOrUndefined(this.list)) {\n if (!this.enableVirtualization) {\n this.list.scrollTop = 0;\n }\n var focusItem = this.list.querySelector('.' + dropDownListClasses.li);\n this.setHoverList(focusItem);\n }\n }\n else {\n this.activeIndex = null;\n this.removeSelection();\n if (this.liCollections && this.liCollections.length > 0 && !this.isCustomFilter) {\n this.removeFocus();\n }\n }\n };\n ComboBox.prototype.incrementalSearch = function (e) {\n this.showPopup(e);\n if (!isNullOrUndefined(this.listData)) {\n this.inlineSearch(e);\n e.preventDefault();\n }\n };\n ComboBox.prototype.setAutoFillSelection = function (currentValue, isKeyNavigate) {\n if (isKeyNavigate === void 0) { isKeyNavigate = false; }\n var selection = this.getSelectionPoints();\n var value = this.inputElement.value.substr(0, selection.start);\n if (value && (value.toLowerCase() === currentValue.substr(0, selection.start).toLowerCase())) {\n var inputValue = value + currentValue.substr(value.length, currentValue.length);\n Input.setValue(inputValue, this.inputElement, this.floatLabelType, this.showClearButton);\n this.inputElement.setSelectionRange(selection.start, this.inputElement.value.length);\n }\n else if (isKeyNavigate) {\n Input.setValue(currentValue, this.inputElement, this.floatLabelType, this.showClearButton);\n this.inputElement.setSelectionRange(0, this.inputElement.value.length);\n }\n };\n ComboBox.prototype.getValueByText = function (text) {\n return _super.prototype.getValueByText.call(this, text, true, this.ignoreAccent);\n };\n ComboBox.prototype.unWireEvent = function () {\n if (this.getModuleName() === 'combobox') {\n EventHandler.remove(this.inputWrapper.buttons[0], 'mousedown', this.preventBlur);\n EventHandler.remove(this.inputWrapper.container, 'blur', this.onBlurHandler);\n }\n if (!isNullOrUndefined(this.inputWrapper.buttons[0])) {\n EventHandler.remove(this.inputWrapper.buttons[0], 'mousedown', this.dropDownClick);\n }\n if (this.inputElement) {\n EventHandler.remove(this.inputElement, 'focus', this.targetFocus);\n if (!this.readonly) {\n EventHandler.remove(this.inputElement, 'input', this.onInput);\n EventHandler.remove(this.inputElement, 'keyup', this.onFilterUp);\n EventHandler.remove(this.inputElement, 'keydown', this.onFilterDown);\n EventHandler.remove(this.inputElement, 'paste', this.pasteHandler);\n EventHandler.remove(window, 'resize', this.windowResize);\n }\n }\n this.unBindCommonEvent();\n };\n ComboBox.prototype.setSelection = function (li, e) {\n _super.prototype.setSelection.call(this, li, e);\n if (!isNullOrUndefined(li) && !this.autofill && !this.isDropDownClick) {\n this.removeFocus();\n }\n };\n ComboBox.prototype.selectCurrentItem = function (e) {\n var li;\n if (this.isPopupOpen) {\n if (this.isSelected) {\n li = this.list.querySelector('.' + dropDownListClasses.selected);\n }\n else {\n li = this.list.querySelector('.' + dropDownListClasses.focus);\n }\n if (li) {\n this.setSelection(li, e);\n this.isTyped = false;\n }\n if (this.isSelected) {\n this.isSelectCustom = false;\n this.onChangeEvent(e);\n }\n }\n if (e.action === 'enter' && this.inputElement.value.trim() === '') {\n this.clearAll(e);\n }\n else if (this.isTyped && !this.isSelected && isNullOrUndefined(li)) {\n this.customValue(e);\n }\n this.hidePopup(e);\n };\n ComboBox.prototype.setHoverList = function (li) {\n this.removeSelection();\n if (this.isValidLI(li) && !li.classList.contains(dropDownListClasses.selected)) {\n this.removeFocus();\n li.classList.add(dropDownListClasses.focus);\n }\n };\n ComboBox.prototype.targetFocus = function (e) {\n if (Browser.isDevice && !this.allowFiltering) {\n this.preventFocus = false;\n }\n this.onFocus(e);\n Input.calculateWidth(this.inputElement, this.inputWrapper.container);\n };\n ComboBox.prototype.dropDownClick = function (e) {\n e.preventDefault();\n if (Browser.isDevice && !this.isFiltering()) {\n this.preventFocus = true;\n }\n _super.prototype.dropDownClick.call(this, e);\n };\n ComboBox.prototype.customValue = function (e) {\n var _this = this;\n var value = this.getValueByText(this.inputElement.value);\n if (!this.allowCustom && this.inputElement.value !== '') {\n var previousValue = this.previousValue;\n var currentValue = this.value;\n this.setProperties({ value: value });\n if (isNullOrUndefined(this.value)) {\n Input.setValue('', this.inputElement, this.floatLabelType, this.showClearButton);\n }\n if (this.autofill && previousValue === this.value && currentValue !== this.value) {\n this.onChangeEvent(null);\n }\n }\n else if (this.inputElement.value.trim() !== '') {\n var previousValue_1 = this.value;\n if (isNullOrUndefined(value)) {\n var value_1 = this.inputElement.value === '' ? null : this.inputElement.value;\n // eslint-disable-next-line max-len\n var eventArgs = { text: value_1, item: {} };\n if (!this.initial) {\n this.trigger('customValueSpecifier', eventArgs, function (eventArgs) {\n _this.updateCustomValueCallback(value_1, eventArgs, previousValue_1, e);\n });\n }\n else {\n this.updateCustomValueCallback(value_1, eventArgs, previousValue_1);\n }\n }\n else {\n this.isSelectCustom = false;\n this.setProperties({ value: value });\n if (previousValue_1 !== this.value) {\n this.onChangeEvent(e);\n }\n }\n }\n else if (this.allowCustom) {\n this.isSelectCustom = true;\n }\n };\n ComboBox.prototype.updateCustomValueCallback = function (value, eventArgs, previousValue, e) {\n var fields = this.fields;\n var item = eventArgs.item;\n var dataItem = {};\n if (item && getValue(fields.text, item) && getValue(fields.value, item)) {\n dataItem = item;\n }\n else {\n setValue(fields.text, value, dataItem);\n setValue(fields.value, value, dataItem);\n }\n this.itemData = dataItem;\n var changeData = {\n text: getValue(fields.text, this.itemData),\n value: getValue(fields.value, this.itemData),\n index: null\n };\n this.setProperties(changeData, true);\n this.setSelection(null, null);\n this.isSelectCustom = true;\n if (previousValue !== this.value) {\n this.onChangeEvent(e);\n }\n };\n /**\n * Dynamically change the value of properties.\n *\n * @param {ComboBoxModel} newProp - Returns the dynamic property value of the component.\n * @param {ComboBoxModel} oldProp - Returns the previous property value of the component.\n * @private\n * @returns {void}\n */\n ComboBox.prototype.onPropertyChanged = function (newProp, oldProp) {\n if (this.getModuleName() === 'combobox') {\n this.checkData(newProp);\n this.setUpdateInitial(['fields', 'query', 'dataSource'], newProp);\n }\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'readonly':\n Input.setReadonly(this.readonly, this.inputElement);\n if (this.readonly) {\n EventHandler.remove(this.inputElement, 'input', this.onInput);\n EventHandler.remove(this.inputElement, 'keyup', this.onFilterUp);\n EventHandler.remove(this.inputElement, 'keydown', this.onFilterDown);\n }\n else {\n EventHandler.add(this.inputElement, 'input', this.onInput, this);\n EventHandler.add(this.inputElement, 'keyup', this.onFilterUp, this);\n EventHandler.add(this.inputElement, 'keydown', this.onFilterDown, this);\n }\n this.setReadOnly();\n break;\n case 'allowFiltering':\n this.setSearchBox();\n if (this.isFiltering() && this.getModuleName() === 'combobox' && isNullOrUndefined(this.list)) {\n _super.prototype.renderList.call(this);\n }\n break;\n case 'allowCustom':\n break;\n default: {\n // eslint-disable-next-line max-len\n var comboProps = this.getPropObject(prop, newProp, oldProp);\n _super.prototype.onPropertyChanged.call(this, comboProps.newProperty, comboProps.oldProperty);\n if (this.isFiltering() && prop === 'dataSource' && isNullOrUndefined(this.list) && this.itemTemplate &&\n this.getModuleName() === 'combobox') {\n _super.prototype.renderList.call(this);\n }\n break;\n }\n }\n }\n };\n /**\n * To initialize the control rendering.\n *\n * @private\n * @returns {void}\n */\n ComboBox.prototype.render = function () {\n _super.prototype.render.call(this);\n this.setSearchBox();\n if (this.isFiltering() && this.getModuleName() === 'combobox' && isNullOrUndefined(this.list)) {\n _super.prototype.renderList.call(this);\n }\n this.renderComplete();\n };\n /**\n * Return the module name of this component.\n *\n * @private\n * @returns {string} Return the module name of this component.\n */\n ComboBox.prototype.getModuleName = function () {\n return 'combobox';\n };\n /**\n * Adds a new item to the combobox popup list. By default, new item appends to the list as the last item,\n * but you can insert based on the index parameter.\n *\n * @param { Object[] } items - Specifies an array of JSON data or a JSON data.\n * @param { number } itemIndex - Specifies the index to place the newly added item in the popup list.\n * @returns {void}\n\n */\n ComboBox.prototype.addItem = function (items, itemIndex) {\n _super.prototype.addItem.call(this, items, itemIndex);\n };\n /**\n * To filter the data from given data source by using query\n *\n * @param {Object[] | DataManager } dataSource - Set the data source to filter.\n * @param {Query} query - Specify the query to filter the data.\n * @param {FieldSettingsModel} fields - Specify the fields to map the column in the data table.\n * @returns {void}\n\n */\n ComboBox.prototype.filter = function (dataSource, query, fields) {\n _super.prototype.filter.call(this, dataSource, query, fields);\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-param */\n /**\n * Opens the popup that displays the list of items.\n *\n * @returns {void}\n\n */\n ComboBox.prototype.showPopup = function (e) {\n /* eslint-enable valid-jsdoc, jsdoc/require-param */\n _super.prototype.showPopup.call(this, e);\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-param */\n /**\n * Hides the popup if it is in open state.\n *\n * @returns {void}\n\n */\n ComboBox.prototype.hidePopup = function (e) {\n /* eslint-enable valid-jsdoc, jsdoc/require-param */\n var inputValue = this.inputElement && this.inputElement.value === '' ? null\n : this.inputElement && this.inputElement.value;\n if (!isNullOrUndefined(this.listData)) {\n var isEscape = this.isEscapeKey;\n if (this.isEscapeKey) {\n Input.setValue(this.typedString, this.inputElement, this.floatLabelType, this.showClearButton);\n this.isEscapeKey = false;\n }\n if (this.autofill) {\n this.removeFillSelection();\n }\n var dataItem = this.isSelectCustom ? { text: '' } : this.getItemData();\n var selected = !isNullOrUndefined(this.list) ? this.list.querySelector('.' + dropDownListClasses.selected) : null;\n if (this.inputElement && dataItem.text === this.inputElement.value && !isNullOrUndefined(selected)) {\n if (this.isSelected) {\n this.onChangeEvent(e);\n this.isSelectCustom = false;\n }\n _super.prototype.hidePopup.call(this, e);\n return;\n }\n if (this.getModuleName() === 'combobox' && this.inputElement.value.trim() !== '') {\n var dataSource = this.sortedData;\n var type = this.typeOfData(dataSource).typeof;\n var searchItem = Search(this.inputElement.value, this.liCollections, 'Equal', true, dataSource, this.fields, type);\n this.selectedLI = searchItem.item;\n if (isNullOrUndefined(searchItem.index)) {\n searchItem.index = Search(this.inputElement.value, this.liCollections, 'StartsWith', true, dataSource, this.fields, type).index;\n }\n this.activeIndex = searchItem.index;\n if (!isNullOrUndefined(this.selectedLI)) {\n this.updateSelectedItem(this.selectedLI, null, true);\n }\n else if (isEscape) {\n this.isSelectCustom = true;\n this.removeSelection();\n }\n }\n if (!this.isEscapeKey && this.isTyped && !this.isInteracted) {\n this.customValue(e);\n }\n }\n if (isNullOrUndefined(this.listData) && this.allowCustom && !isNullOrUndefined(inputValue) && inputValue !== this.value) {\n this.customValue();\n }\n _super.prototype.hidePopup.call(this, e);\n };\n /**\n * Sets the focus to the component for interaction.\n *\n * @returns {void}\n */\n ComboBox.prototype.focusIn = function () {\n if (!this.enabled) {\n return;\n }\n if (Browser.isDevice && !this.isFiltering()) {\n this.preventFocus = true;\n }\n _super.prototype.focusIn.call(this);\n };\n /**\n * Allows you to clear the selected values from the component.\n *\n * @returns {void}\n\n */\n ComboBox.prototype.clear = function () {\n this.value = null;\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-param */\n /**\n * Moves the focus from the component if the component is already focused.\n *\n * @returns {void}\n\n */\n ComboBox.prototype.focusOut = function (e) {\n /* eslint-enable valid-jsdoc, jsdoc/require-param */\n _super.prototype.focusOut.call(this, e);\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets all the list items bound on this component.\n *\n * @returns {Element[]}\n\n */\n ComboBox.prototype.getItems = function () {\n return _super.prototype.getItems.call(this);\n };\n /**\n * Gets the data Object that matches the given value.\n *\n * @param { string | number } value - Specifies the value of the list item.\n * @returns {Object}\n\n */\n ComboBox.prototype.getDataByValue = function (value) {\n return _super.prototype.getDataByValue.call(this, value);\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n ComboBox.prototype.renderHightSearch = function () {\n // update high light search\n };\n __decorate([\n Property(false)\n ], ComboBox.prototype, \"autofill\", void 0);\n __decorate([\n Property(true)\n ], ComboBox.prototype, \"allowCustom\", void 0);\n __decorate([\n Property({})\n ], ComboBox.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property(false)\n ], ComboBox.prototype, \"allowFiltering\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"query\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"index\", void 0);\n __decorate([\n Property(true)\n ], ComboBox.prototype, \"showClearButton\", void 0);\n __decorate([\n Property(false)\n ], ComboBox.prototype, \"enableRtl\", void 0);\n __decorate([\n Event()\n ], ComboBox.prototype, \"customValueSpecifier\", void 0);\n __decorate([\n Event()\n ], ComboBox.prototype, \"filtering\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"valueTemplate\", void 0);\n __decorate([\n Property('Never')\n ], ComboBox.prototype, \"floatLabelType\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"filterBarPlaceholder\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"cssClass\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"headerTemplate\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"footerTemplate\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"placeholder\", void 0);\n __decorate([\n Property('100%')\n ], ComboBox.prototype, \"width\", void 0);\n __decorate([\n Property('300px')\n ], ComboBox.prototype, \"popupHeight\", void 0);\n __decorate([\n Property('100%')\n ], ComboBox.prototype, \"popupWidth\", void 0);\n __decorate([\n Property(false)\n ], ComboBox.prototype, \"readonly\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"text\", void 0);\n __decorate([\n Property(null)\n ], ComboBox.prototype, \"value\", void 0);\n ComboBox = __decorate([\n NotifyPropertyChanges\n ], ComboBox);\n return ComboBox;\n}(DropDownList));\nexport { ComboBox };\n","//! moment.js locale configuration\n//! locale : Slovenian [sl]\n//! author : Robert SedovÅ¡ek : https://github.com/sedovsek\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var result = number + ' ';\n switch (key) {\n case 's':\n return withoutSuffix || isFuture\n ? 'nekaj sekund'\n : 'nekaj sekundami';\n case 'ss':\n if (number === 1) {\n result += withoutSuffix ? 'sekundo' : 'sekundi';\n } else if (number === 2) {\n result += withoutSuffix || isFuture ? 'sekundi' : 'sekundah';\n } else if (number < 5) {\n result += withoutSuffix || isFuture ? 'sekunde' : 'sekundah';\n } else {\n result += 'sekund';\n }\n return result;\n case 'm':\n return withoutSuffix ? 'ena minuta' : 'eno minuto';\n case 'mm':\n if (number === 1) {\n result += withoutSuffix ? 'minuta' : 'minuto';\n } else if (number === 2) {\n result += withoutSuffix || isFuture ? 'minuti' : 'minutama';\n } else if (number < 5) {\n result += withoutSuffix || isFuture ? 'minute' : 'minutami';\n } else {\n result += withoutSuffix || isFuture ? 'minut' : 'minutami';\n }\n return result;\n case 'h':\n return withoutSuffix ? 'ena ura' : 'eno uro';\n case 'hh':\n if (number === 1) {\n result += withoutSuffix ? 'ura' : 'uro';\n } else if (number === 2) {\n result += withoutSuffix || isFuture ? 'uri' : 'urama';\n } else if (number < 5) {\n result += withoutSuffix || isFuture ? 'ure' : 'urami';\n } else {\n result += withoutSuffix || isFuture ? 'ur' : 'urami';\n }\n return result;\n case 'd':\n return withoutSuffix || isFuture ? 'en dan' : 'enim dnem';\n case 'dd':\n if (number === 1) {\n result += withoutSuffix || isFuture ? 'dan' : 'dnem';\n } else if (number === 2) {\n result += withoutSuffix || isFuture ? 'dni' : 'dnevoma';\n } else {\n result += withoutSuffix || isFuture ? 'dni' : 'dnevi';\n }\n return result;\n case 'M':\n return withoutSuffix || isFuture ? 'en mesec' : 'enim mesecem';\n case 'MM':\n if (number === 1) {\n result += withoutSuffix || isFuture ? 'mesec' : 'mesecem';\n } else if (number === 2) {\n result += withoutSuffix || isFuture ? 'meseca' : 'mesecema';\n } else if (number < 5) {\n result += withoutSuffix || isFuture ? 'mesece' : 'meseci';\n } else {\n result += withoutSuffix || isFuture ? 'mesecev' : 'meseci';\n }\n return result;\n case 'y':\n return withoutSuffix || isFuture ? 'eno leto' : 'enim letom';\n case 'yy':\n if (number === 1) {\n result += withoutSuffix || isFuture ? 'leto' : 'letom';\n } else if (number === 2) {\n result += withoutSuffix || isFuture ? 'leti' : 'letoma';\n } else if (number < 5) {\n result += withoutSuffix || isFuture ? 'leta' : 'leti';\n } else {\n result += withoutSuffix || isFuture ? 'let' : 'leti';\n }\n return result;\n }\n }\n\n var sl = moment.defineLocale('sl', {\n months: 'januar_februar_marec_april_maj_junij_julij_avgust_september_oktober_november_december'.split(\n '_'\n ),\n monthsShort:\n 'jan._feb._mar._apr._maj._jun._jul._avg._sep._okt._nov._dec.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'nedelja_ponedeljek_torek_sreda_Äetrtek_petek_sobota'.split('_'),\n weekdaysShort: 'ned._pon._tor._sre._Äet._pet._sob.'.split('_'),\n weekdaysMin: 'ne_po_to_sr_Äe_pe_so'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD. MM. YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY H:mm',\n LLLL: 'dddd, D. MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[danes ob] LT',\n nextDay: '[jutri ob] LT',\n\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[v] [nedeljo] [ob] LT';\n case 3:\n return '[v] [sredo] [ob] LT';\n case 6:\n return '[v] [soboto] [ob] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[v] dddd [ob] LT';\n }\n },\n lastDay: '[vÄeraj ob] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n return '[prejÅ¡njo] [nedeljo] [ob] LT';\n case 3:\n return '[prejÅ¡njo] [sredo] [ob] LT';\n case 6:\n return '[prejÅ¡njo] [soboto] [ob] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[prejÅ¡nji] dddd [ob] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'Äez %s',\n past: 'pred %s',\n s: processRelativeTime,\n ss: processRelativeTime,\n m: processRelativeTime,\n mm: processRelativeTime,\n h: processRelativeTime,\n hh: processRelativeTime,\n d: processRelativeTime,\n dd: processRelativeTime,\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return sl;\n\n})));\n","//! moment.js locale configuration\n//! locale : Finnish [fi]\n//! author : Tarmo Aidantausta : https://github.com/bleadof\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var numbersPast =\n 'nolla yksi kaksi kolme neljä viisi kuusi seitsemän kahdeksan yhdeksän'.split(\n ' '\n ),\n numbersFuture = [\n 'nolla',\n 'yhden',\n 'kahden',\n 'kolmen',\n 'neljän',\n 'viiden',\n 'kuuden',\n numbersPast[7],\n numbersPast[8],\n numbersPast[9],\n ];\n function translate(number, withoutSuffix, key, isFuture) {\n var result = '';\n switch (key) {\n case 's':\n return isFuture ? 'muutaman sekunnin' : 'muutama sekunti';\n case 'ss':\n result = isFuture ? 'sekunnin' : 'sekuntia';\n break;\n case 'm':\n return isFuture ? 'minuutin' : 'minuutti';\n case 'mm':\n result = isFuture ? 'minuutin' : 'minuuttia';\n break;\n case 'h':\n return isFuture ? 'tunnin' : 'tunti';\n case 'hh':\n result = isFuture ? 'tunnin' : 'tuntia';\n break;\n case 'd':\n return isFuture ? 'päivän' : 'päivä';\n case 'dd':\n result = isFuture ? 'päivän' : 'päivää';\n break;\n case 'M':\n return isFuture ? 'kuukauden' : 'kuukausi';\n case 'MM':\n result = isFuture ? 'kuukauden' : 'kuukautta';\n break;\n case 'y':\n return isFuture ? 'vuoden' : 'vuosi';\n case 'yy':\n result = isFuture ? 'vuoden' : 'vuotta';\n break;\n }\n result = verbalNumber(number, isFuture) + ' ' + result;\n return result;\n }\n function verbalNumber(number, isFuture) {\n return number < 10\n ? isFuture\n ? numbersFuture[number]\n : numbersPast[number]\n : number;\n }\n\n var fi = moment.defineLocale('fi', {\n months: 'tammikuu_helmikuu_maaliskuu_huhtikuu_toukokuu_kesäkuu_heinäkuu_elokuu_syyskuu_lokakuu_marraskuu_joulukuu'.split(\n '_'\n ),\n monthsShort:\n 'tammi_helmi_maalis_huhti_touko_kesä_heinä_elo_syys_loka_marras_joulu'.split(\n '_'\n ),\n weekdays:\n 'sunnuntai_maanantai_tiistai_keskiviikko_torstai_perjantai_lauantai'.split(\n '_'\n ),\n weekdaysShort: 'su_ma_ti_ke_to_pe_la'.split('_'),\n weekdaysMin: 'su_ma_ti_ke_to_pe_la'.split('_'),\n longDateFormat: {\n LT: 'HH.mm',\n LTS: 'HH.mm.ss',\n L: 'DD.MM.YYYY',\n LL: 'Do MMMM[ta] YYYY',\n LLL: 'Do MMMM[ta] YYYY, [klo] HH.mm',\n LLLL: 'dddd, Do MMMM[ta] YYYY, [klo] HH.mm',\n l: 'D.M.YYYY',\n ll: 'Do MMM YYYY',\n lll: 'Do MMM YYYY, [klo] HH.mm',\n llll: 'ddd, Do MMM YYYY, [klo] HH.mm',\n },\n calendar: {\n sameDay: '[tänään] [klo] LT',\n nextDay: '[huomenna] [klo] LT',\n nextWeek: 'dddd [klo] LT',\n lastDay: '[eilen] [klo] LT',\n lastWeek: '[viime] dddd[na] [klo] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s päästä',\n past: '%s sitten',\n s: translate,\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: translate,\n dd: translate,\n M: translate,\n MM: translate,\n y: translate,\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return fi;\n\n})));\n","import { createTemplate, measureElementRect, logBase, removeElement } from '../utils/helper';\nimport { ChartLocation, stringToNumber, appendElement, withIn } from '../utils/helper';\nimport { Rect } from '@syncfusion/ej2-svg-base';\nimport { getPoint } from '../utils/helper';\nimport { createElement, updateBlazorTemplate } from '@syncfusion/ej2-base';\nimport { annotationRender } from '../model/constants';\nimport { DataUtil } from '@syncfusion/ej2-data';\n/**\n * Annotation Module handles the Annotation for chart and accumulation series.\n */\nvar AnnotationBase = /** @class */ (function () {\n /**\n * Constructor for chart and accumulation annotation\n *\n * @param control\n */\n function AnnotationBase(control) {\n this.control = control;\n }\n /**\n * Method to render the annotation for chart and accumulation series.\n *\n * @private\n * @param annotation\n * @param index\n */\n AnnotationBase.prototype.render = function (annotation, index) {\n this.isChart = this.control.getModuleName() === 'chart';\n this.annotation = annotation;\n var childElement = createTemplate(createElement('div', {\n id: this.control.element.id + '_Annotation_' + index,\n styles: 'position: absolute; z-index: 1' //by default z-index set for annotation elements\n }), index, annotation.content, this.control);\n return childElement;\n };\n /**\n * Method to calculate the location for annotation - coordinate unit as pixel.\n *\n * @private\n * @param location\n */\n AnnotationBase.prototype.setAnnotationPixelValue = function (location) {\n var rect = this.annotation.region === 'Chart' ?\n new Rect(0, 0, this.control.availableSize.width, this.control.availableSize.height) :\n this.isChart ?\n this.control.chartAxisLayoutPanel.seriesClipRect :\n this.control.series[0].accumulationBound;\n location.x = ((typeof this.annotation.x !== 'string') ?\n ((typeof this.annotation.x === 'number') ? this.annotation.x : 0) :\n stringToNumber(this.annotation.x, rect.width)) + rect.x;\n location.y = ((typeof this.annotation.y === 'number') ? this.annotation.y :\n stringToNumber(this.annotation.y, rect.height)) + rect.y;\n return true;\n };\n /**\n * Method to calculate the location for annotation - coordinate unit as point.\n *\n * @private\n * @param location\n */\n AnnotationBase.prototype.setAnnotationPointValue = function (location) {\n var symbolLocation = new ChartLocation(0, 0);\n if (this.isChart) {\n var chart = this.control;\n var annotation = this.annotation;\n var xAxisName = annotation.xAxisName;\n var yAxisName = annotation.yAxisName;\n var isInverted = chart.requireInvertedAxis;\n var stockChart = this.control.stockChart;\n var xAxis = void 0;\n var yAxis = void 0;\n var xValue = void 0;\n for (var _i = 0, _a = chart.axisCollections; _i < _a.length; _i++) {\n var axis = _a[_i];\n if (xAxisName === axis.name || (xAxisName == null && axis.name === 'primaryXAxis')) {\n xAxis = axis;\n if (xAxis.valueType.indexOf('Category') > -1) {\n var xAnnotation = xAxis.valueType === 'DateTimeCategory' ? (annotation.x.getTime()).toString() :\n annotation.x;\n if (xAxis.labels.indexOf(xAnnotation) < 0) {\n return false;\n }\n else {\n xValue = xAxis.labels.indexOf(xAnnotation);\n }\n }\n else if (xAxis.valueType === 'DateTime') {\n var option = { skeleton: 'full', type: 'dateTime' };\n xValue = (typeof this.annotation.x === 'object' || typeof new Date(this.annotation.x) === 'object') ?\n Date.parse(chart.intl.getDateParser(option)(chart.intl.getDateFormat(option)(new Date(DataUtil.parse.parseJson({ val: annotation.x }).val)))) : 0;\n }\n else {\n xValue = +annotation.x;\n }\n }\n else if (yAxisName === axis.name || (yAxisName == null && axis.name === 'primaryYAxis')) {\n yAxis = axis;\n }\n }\n if (xAxis && yAxis && withIn(xAxis.valueType === 'Logarithmic' ? logBase(xValue, xAxis.logBase) : xValue, xAxis.visibleRange) && withIn(yAxis.valueType === 'Logarithmic' ? logBase(+annotation.y, yAxis.logBase) : +annotation.y, yAxis.visibleRange)) {\n symbolLocation = getPoint(xValue, +annotation.y, xAxis, yAxis, isInverted);\n location.x = symbolLocation.x + (isInverted ? yAxis.rect.x : xAxis.rect.x);\n // for stockchart, stockchart's toolbar height and title size is added for annotation content\n location.y = symbolLocation.y + (isInverted ? xAxis.rect.y : yAxis.rect.y) +\n ((stockChart && stockChart.enablePeriodSelector) ? stockChart.toolbarHeight + stockChart.titleSize.height : 0);\n }\n else {\n return false;\n }\n return true;\n }\n else {\n return this.setAccumulationPointValue(location);\n }\n };\n /**\n * To process the annotation for accumulation chart.\n *\n * @param annotation\n * @param index\n * @param parentElement\n */\n AnnotationBase.prototype.processAnnotation = function (annotation, index, parentElement) {\n var chart = this.control;\n var location = new ChartLocation(0, 0);\n var annotationElement = this.render(annotation, index);\n var annotationRendered = function () {\n annotationElement.style.transform = 'translate(-50%, -50%)';\n };\n annotationRendered.bind(location, this);\n if (this['setAnnotation' + annotation.coordinateUnits + 'Value'](location)) {\n this.setElementStyle(location, annotationElement, parentElement);\n }\n else if (this.control.redraw) {\n removeElement(annotationElement.id);\n }\n updateBlazorTemplate((this.control.element.id + 'Annotation' + index).replace(/[^a-zA-Z0-9]/g, ''), 'ContentTemplate', chart.stockChart ? chart.stockChart.annotations[index] : this.control.annotations[index], undefined, annotationRendered);\n };\n /**\n * Method to calculate the location for annotation - coordinate unit as point in accumulation chart.\n *\n * @private\n * @param location\n */\n AnnotationBase.prototype.setAccumulationPointValue = function (location) {\n var accumulation = this.control;\n var point;\n for (var _i = 0, _a = accumulation.visibleSeries[0].points; _i < _a.length; _i++) {\n var accPoint = _a[_i];\n if (typeof accPoint.x === 'object') {\n if (Date.parse(accPoint.x) === Date.parse(this.annotation.x) &&\n accPoint.y === this.annotation.y) {\n point = accPoint;\n break;\n }\n }\n else {\n if (accPoint.x === this.annotation.x && accPoint.y === this.annotation.y) {\n point = accPoint;\n break;\n }\n }\n }\n if (point && point.visible) {\n location.x = point.symbolLocation.x;\n location.y = point.symbolLocation.y;\n return true;\n }\n else {\n return false;\n }\n };\n /**\n * Method to set the element style for accumulation / chart annotation.\n *\n * @private\n * @param location\n * @param element\n * @param parentElement\n */\n AnnotationBase.prototype.setElementStyle = function (location, element, parentElement) {\n var elementRect = measureElementRect(element, this.control.redraw);\n var argsData = {\n cancel: false, name: annotationRender, content: element,\n location: location\n };\n this.control.trigger(annotationRender, argsData);\n if (!argsData.cancel) {\n argsData.content.style.left = this.setAlignmentValue(this.annotation.horizontalAlignment, elementRect.width, argsData.location.x) + 'px';\n argsData.content.style.top = this.setAlignmentValue(this.annotation.verticalAlignment, elementRect.height, argsData.location.y) + 'px';\n argsData.content.setAttribute('aria-label', this.annotation.description || 'Annotation');\n appendElement(argsData.content, parentElement, this.control.redraw, true, 'left', 'top');\n }\n };\n /**\n * Method to calculate the alignment value for annotation.\n *\n * @private\n * @param alignment\n * @param size\n * @param value\n */\n AnnotationBase.prototype.setAlignmentValue = function (alignment, size, value) {\n switch (alignment) {\n case 'Top':\n case 'Near':\n value -= size;\n break;\n case 'Bottom':\n case 'Far':\n value += 0;\n break;\n case 'Middle':\n case 'Center':\n value -= (size / 2);\n break;\n }\n return value;\n };\n return AnnotationBase;\n}());\nexport { AnnotationBase };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { AnnotationBase } from '../../common/annotation/annotation';\nimport { appendElement, redrawElement } from '../../common/utils/helper';\nimport { createElement } from '@syncfusion/ej2-base';\n/**\n * `ChartAnnotation` module handles the annotation for chart.\n */\nvar ChartAnnotation = /** @class */ (function (_super) {\n __extends(ChartAnnotation, _super);\n /**\n * Constructor for chart annotation.\n *\n * @private\n */\n function ChartAnnotation(control, annotations) {\n var _this = _super.call(this, control) || this;\n _this.chart = control;\n _this.annotations = annotations;\n return _this;\n }\n /**\n * Method to render the annotation for chart\n *\n * @param {Element} element annotation element\n * @private\n */\n ChartAnnotation.prototype.renderAnnotations = function (element) {\n var _this = this;\n this.annotations = this.chart.annotations;\n this.parentElement = redrawElement(this.chart.redraw, this.chart.element.id + '_Annotation_Collections') ||\n createElement('div', {\n id: this.chart.element.id + '_Annotation_Collections'\n });\n this.annotations.map(function (annotation, index) {\n _this.processAnnotation(annotation, index, _this.parentElement);\n });\n appendElement(this.parentElement, element, this.chart.redraw);\n };\n /**\n * To destroy the annotation.\n *\n * @returns {void}\n * @private\n */\n ChartAnnotation.prototype.destroy = function () {\n // Destroy method performed here\n };\n /**\n * Get module name.\n */\n ChartAnnotation.prototype.getModuleName = function () {\n // Returns te module name\n return 'Annotation';\n };\n return ChartAnnotation;\n}(AnnotationBase));\nexport { ChartAnnotation };\n","//! moment.js locale configuration\n//! locale : Arabic (Saudi Arabia) [ar-sa]\n//! author : Suhail Alkowaileet : https://github.com/xsoh\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: 'Ù¡',\n 2: 'Ù¢',\n 3: 'Ù£',\n 4: 'Ù¤',\n 5: 'Ù¥',\n 6: 'Ù¦',\n 7: 'Ù§',\n 8: 'Ù¨',\n 9: 'Ù©',\n 0: 'Ù ',\n },\n numberMap = {\n 'Ù¡': '1',\n 'Ù¢': '2',\n 'Ù£': '3',\n 'Ù¤': '4',\n 'Ù¥': '5',\n 'Ù¦': '6',\n 'Ù§': '7',\n 'Ù¨': '8',\n 'Ù©': '9',\n 'Ù ': '0',\n };\n\n var arSa = moment.defineLocale('ar-sa', {\n months: 'يناير_Ùبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوÙمبر_ديسمبر'.split(\n '_'\n ),\n monthsShort:\n 'يناير_Ùبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوÙمبر_ديسمبر'.split(\n '_'\n ),\n weekdays: 'الأØد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),\n weekdaysShort: 'Ø£Øد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت'.split('_'),\n weekdaysMin: 'Ø_Ù†_Ø«_ر_Ø®_ج_س'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n meridiemParse: /ص|Ù…/,\n isPM: function (input) {\n return 'Ù…' === input;\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'ص';\n } else {\n return 'Ù…';\n }\n },\n calendar: {\n sameDay: '[اليوم على الساعة] LT',\n nextDay: '[غدا على الساعة] LT',\n nextWeek: 'dddd [على الساعة] LT',\n lastDay: '[أمس على الساعة] LT',\n lastWeek: 'dddd [على الساعة] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'ÙÙŠ %s',\n past: 'منذ %s',\n s: 'ثوان',\n ss: '%d ثانية',\n m: 'دقيقة',\n mm: '%d دقائق',\n h: 'ساعة',\n hh: '%d ساعات',\n d: 'يوم',\n dd: '%d أيام',\n M: 'شهر',\n MM: '%d أشهر',\n y: 'سنة',\n yy: '%d سنوات',\n },\n preparse: function (string) {\n return string\n .replace(/[١٢٣٤٥٦٧٨٩٠]/g, function (match) {\n return numberMap[match];\n })\n .replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string\n .replace(/\\d/g, function (match) {\n return symbolMap[match];\n })\n .replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return arSa;\n\n})));\n","//! moment.js locale configuration\n//! locale : Bulgarian [bg]\n//! author : Krasen Borisov : https://github.com/kraz\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var bg = moment.defineLocale('bg', {\n months: 'Ñнуари_февруари_март_април_май_юни_юли_авгуÑÑ‚_Ñептември_октомври_ноември_декември'.split(\n '_'\n ),\n monthsShort: 'Ñну_фев_мар_апр_май_юни_юли_авг_Ñеп_окт_ное_дек'.split('_'),\n weekdays: 'неделÑ_понеделник_вторник_ÑÑ€Ñда_четвъртък_петък_Ñъбота'.split(\n '_'\n ),\n weekdaysShort: 'нед_пон_вто_ÑÑ€Ñ_чет_пет_Ñъб'.split('_'),\n weekdaysMin: 'нд_пн_вт_ÑÑ€_чт_пт_Ñб'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'D.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY H:mm',\n LLLL: 'dddd, D MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[Ð”Ð½ÐµÑ Ð²] LT',\n nextDay: '[Утре в] LT',\n nextWeek: 'dddd [в] LT',\n lastDay: '[Вчера в] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n case 3:\n case 6:\n return '[Миналата] dddd [в] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[МиналиÑ] dddd [в] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'Ñлед %s',\n past: 'преди %s',\n s: 'нÑколко Ñекунди',\n ss: '%d Ñекунди',\n m: 'минута',\n mm: '%d минути',\n h: 'чаÑ',\n hh: '%d чаÑа',\n d: 'ден',\n dd: '%d дена',\n w: 'Ñедмица',\n ww: '%d Ñедмици',\n M: 'меÑец',\n MM: '%d меÑеца',\n y: 'година',\n yy: '%d години',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(ев|ен|ти|ви|ри|ми)/,\n ordinal: function (number) {\n var lastDigit = number % 10,\n last2Digits = number % 100;\n if (number === 0) {\n return number + '-ев';\n } else if (last2Digits === 0) {\n return number + '-ен';\n } else if (last2Digits > 10 && last2Digits < 20) {\n return number + '-ти';\n } else if (lastDigit === 1) {\n return number + '-ви';\n } else if (lastDigit === 2) {\n return number + '-ри';\n } else if (lastDigit === 7 || lastDigit === 8) {\n return number + '-ми';\n } else {\n return number + '-ти';\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return bg;\n\n})));\n","//! moment.js locale configuration\n//! locale : Burmese [my]\n//! author : Squar team, mysquar.com\n//! author : David Rossellat : https://github.com/gholadr\n//! author : Tin Aung Lin : https://github.com/thanyawzinmin\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: 'á',\n 2: 'á‚',\n 3: 'áƒ',\n 4: 'á„',\n 5: 'á…',\n 6: 'á†',\n 7: 'á‡',\n 8: 'áˆ',\n 9: 'á‰',\n 0: 'á€',\n },\n numberMap = {\n 'á': '1',\n 'á‚': '2',\n 'áƒ': '3',\n 'á„': '4',\n 'á…': '5',\n 'á†': '6',\n 'á‡': '7',\n 'áˆ': '8',\n 'á‰': '9',\n 'á€': '0',\n };\n\n var my = moment.defineLocale('my', {\n months: 'ဇန်နá€á€«á€›á€®_ဖေဖော်á€á€«á€›á€®_မá€á€º_ဧပြီ_မေ_ဇွန်_ဇူလá€á€¯á€„်_သြဂုá€á€º_စက်á€á€„်ဘာ_အောက်á€á€á€¯á€˜á€¬_နá€á€¯á€á€„်ဘာ_ဒီဇင်ဘာ'.split(\n '_'\n ),\n monthsShort: 'ဇန်_ဖေ_မá€á€º_ပြီ_မေ_ဇွန်_လá€á€¯á€„်_သြ_စက်_အောက်_နá€á€¯_ဒီ'.split('_'),\n weekdays: 'á€á€”င်္ဂနွေ_á€á€”င်္လာ_အင်္ဂါ_ဗုဒ္ဓဟူး_ကြာသပá€á€±á€¸_သောကြာ_စနေ'.split(\n '_'\n ),\n weekdaysShort: 'နွေ_လာ_ဂါ_ဟူး_ကြာ_သော_နေ'.split('_'),\n weekdaysMin: 'နွေ_လာ_ဂါ_ဟူး_ကြာ_သော_နေ'.split('_'),\n\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[ယနေ.] LT [မှာ]',\n nextDay: '[မနက်ဖြန်] LT [မှာ]',\n nextWeek: 'dddd LT [မှာ]',\n lastDay: '[မနေ.က] LT [မှာ]',\n lastWeek: '[ပြီးá€á€²á€·á€žá€±á€¬] dddd LT [မှာ]',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'လာမည့် %s မှာ',\n past: 'လွန်á€á€²á€·á€žá€±á€¬ %s က',\n s: 'စက္ကန်.အနည်းငယ်',\n ss: '%d စက္ကန့်',\n m: 'á€á€…်မá€á€”စ်',\n mm: '%d မá€á€”စ်',\n h: 'á€á€…်နာရီ',\n hh: '%d နာရီ',\n d: 'á€á€…်ရက်',\n dd: '%d ရက်',\n M: 'á€á€…်လ',\n MM: '%d လ',\n y: 'á€á€…်နှစ်',\n yy: '%d နှစ်',\n },\n preparse: function (string) {\n return string.replace(/[áá‚áƒá„á…á†á‡áˆá‰á€]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return my;\n\n})));\n","import { isNullOrUndefined, extend, addClass, removeClass } from '@syncfusion/ej2-base';\nimport { attributes as addAttributes } from '@syncfusion/ej2-base';\nimport { rowDataBound, queryCellInfo } from '../base/constant';\nimport { setStyleAndAttributes, getObject, extendObjWithFn, applyStickyLeftRightPosition, groupCaptionRowLeftRightPos, resetColspanGroupCaption } from '../base/util';\nimport { CellType } from '../base/enum';\nimport { CellMergeRender } from './cell-merge-renderer';\nimport * as literals from '../base/string-literals';\n/**\n * RowRenderer class which responsible for building row content.\n *\n * @hidden\n */\nvar RowRenderer = /** @class */ (function () {\n function RowRenderer(serviceLocator, cellType, parent) {\n this.isSpan = false;\n this.cellType = cellType;\n this.serviceLocator = serviceLocator;\n this.parent = parent;\n this.element = this.parent.createElement('tr', { attrs: { role: 'row' } });\n }\n /* eslint-disable */\n /**\n * Function to render the row content based on Column[] and data.\n *\n * @param {Row<T>} row - specifies the row\n * @param {Column[]} columns - specifies the columns\n * @param {Object} attributes - specifies the attributes\n * @param {string} rowTemplate - specifies the rowTemplate\n * @param {Element} cloneNode - specifies the cloneNode\n * @returns {Element} returns the element\n */\n /* eslint-enable */\n RowRenderer.prototype.render = function (row, columns, attributes, rowTemplate, cloneNode) {\n return this.refreshRow(row, columns, attributes, rowTemplate, cloneNode);\n };\n /* eslint-disable */\n /**\n * Function to refresh the row content based on Column[] and data.\n *\n * @param {Row<T>} row - specifies the row\n * @param {Column[]} columns - specifies the column\n * @param {boolean} isChanged - specifies isChanged\n * @param {Object} attributes - specifies the attributes\n * @param {string} rowTemplate - specifies the rowTemplate\n * @returns {void}\n */\n /* eslint-enable */\n RowRenderer.prototype.refresh = function (row, columns, isChanged, attributes, rowTemplate) {\n var _this = this;\n if (isChanged) {\n row.data = extendObjWithFn({}, row.changes);\n this.refreshMergeCells(row);\n }\n var node = this.parent.element.querySelector('[data-uid=' + row.uid + ']');\n var tr = this.refreshRow(row, columns, attributes, rowTemplate, null, isChanged);\n var cells = [].slice.call(tr.cells);\n var tempCells = [].slice.call(node.querySelectorAll('.e-templatecell'));\n if (this.parent.isReact && tempCells.length) {\n var _loop_1 = function (col) {\n if (col.template) {\n setTimeout(function () {\n _this.parent.refreshReactColumnTemplateByUid(col.uid, true);\n }, 0);\n return \"break\";\n }\n };\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var col = columns_1[_i];\n var state_1 = _loop_1(col);\n if (state_1 === \"break\")\n break;\n }\n }\n var attr = [].slice.call(tr.attributes);\n attr.map(function (item) {\n node.setAttribute(item['name'], item['value']);\n });\n node.innerHTML = '';\n for (var _a = 0, cells_1 = cells; _a < cells_1.length; _a++) {\n var cell = cells_1[_a];\n node.appendChild(cell);\n }\n };\n // tslint:disable-next-line:max-func-body-length\n RowRenderer.prototype.refreshRow = function (row, columns, attributes, rowTemplate, cloneNode, isEdit) {\n var tr = !isNullOrUndefined(cloneNode) ? cloneNode : this.element.cloneNode();\n var rowArgs = { data: row.data };\n var cellArgs = { data: row.data };\n var chekBoxEnable = this.parent.getColumns().filter(function (col) { return col.type === 'checkbox' && col.field; })[0];\n var value = false;\n if (chekBoxEnable) {\n value = getObject(chekBoxEnable.field, rowArgs.data);\n }\n var selIndex = this.parent.getSelectedRowIndexes();\n if (row.isDataRow) {\n row.isSelected = selIndex.indexOf(row.index) > -1 || value;\n }\n if (row.isDataRow && this.parent.isCheckBoxSelection\n && this.parent.checkAllRows === 'Check' && (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling)) {\n row.isSelected = true;\n if (selIndex.indexOf(row.index) === -1) {\n selIndex.push(row.index);\n }\n }\n this.buildAttributeFromRow(tr, row);\n addAttributes(tr, extend({}, attributes, {}));\n setStyleAndAttributes(tr, row.attributes);\n var cellRendererFact = this.serviceLocator.getService('cellRendererFactory');\n var _loop_2 = function (i, len) {\n var cell = row.cells[parseInt(i.toString(), 10)];\n cell.isSelected = row.isSelected;\n cell.isColumnSelected = cell.column.isSelected;\n var cellRenderer = cellRendererFact.getCellRenderer(row.cells[parseInt(i.toString(), 10)].cellType\n || CellType.Data);\n var attrs = { 'index': !isNullOrUndefined(row.index) ? row.index.toString() : '' };\n if (row.isExpand && row.cells[parseInt(i.toString(), 10)].cellType === CellType.DetailExpand) {\n attrs['class'] = this_1.parent.isPrinting ? 'e-detailrowcollapse' : 'e-detailrowexpand';\n }\n var td = cellRenderer.render(row.cells[parseInt(i.toString(), 10)], row.data, attrs, row.isExpand, isEdit);\n if (row.cells[parseInt(i.toString(), 10)].cellType !== CellType.Filter) {\n if (row.cells[parseInt(i.toString(), 10)].cellType === CellType.Data\n || row.cells[parseInt(i.toString(), 10)].cellType === CellType.CommandColumn) {\n var isReactChild = this_1.parent.parentDetails && this_1.parent.parentDetails.parentInstObj &&\n this_1.parent.parentDetails.parentInstObj.isReact;\n if (((this_1.parent.isReact && this_1.parent.requireTemplateRef) || (isReactChild &&\n this_1.parent.parentDetails.parentInstObj.requireTemplateRef)) && cell.isTemplate) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var thisRef_1 = this_1;\n thisRef_1.parent.renderTemplates(function () {\n if (typeof (cell.column.template) !== 'string') {\n var ariaAttr = td.getAttribute('aria-label');\n td.setAttribute('aria-label', td.innerText + ariaAttr);\n }\n thisRef_1.parent.trigger(queryCellInfo, extend(cellArgs, {\n cell: td, column: cell.column, colSpan: 1,\n rowSpan: 1, foreignKeyData: row.cells[parseInt(i.toString(), 10)].foreignKeyData,\n requestType: thisRef_1.parent.requestTypeAction\n }));\n });\n }\n else {\n this_1.parent.trigger(queryCellInfo, extend(cellArgs, {\n cell: td, column: cell.column, colSpan: 1,\n rowSpan: 1, foreignKeyData: row.cells[parseInt(i.toString(), 10)].foreignKeyData,\n requestType: this_1.parent.requestTypeAction\n }));\n }\n var isRowSpanned = false;\n if (row.index > 0 && this_1.isSpan) {\n var rowsObject = this_1.parent.getRowsObject();\n var prevRowCells = this_1.parent.groupSettings.columns.length > 0 &&\n !rowsObject[row.index - 1].isDataRow ? rowsObject[row.index].cells : rowsObject[row.index - 1].cells;\n var uid_1 = 'uid';\n var prevRowCell = prevRowCells.filter(function (cell) {\n return cell.column.uid === row.cells[parseInt(i.toString(), 10)].column[\"\" + uid_1];\n })[0];\n isRowSpanned = prevRowCell.isRowSpanned ? prevRowCell.isRowSpanned : prevRowCell.rowSpanRange > 1;\n }\n if (cellArgs.colSpan > 1 || row.cells[parseInt(i.toString(), 10)].cellSpan > 1 || cellArgs.rowSpan > 1\n || isRowSpanned) {\n this_1.isSpan = true;\n var cellMerge = new CellMergeRender(this_1.serviceLocator, this_1.parent);\n td = cellMerge.render(cellArgs, row, i, td);\n }\n }\n if (!row.cells[parseInt(i.toString(), 10)].isSpanned) {\n tr.appendChild(td);\n }\n }\n };\n var this_1 = this;\n for (var i = 0, len = row.cells.length; i < len; i++) {\n _loop_2(i, len);\n }\n var emptyColspan = 0;\n if (this.parent.groupSettings.columns.length && this.parent.getFrozenLeftColumnsCount()) {\n if (tr.classList.contains('e-groupcaptionrow')) {\n var freezeCells = [].slice.call(tr.querySelectorAll('.e-leftfreeze,.e-unfreeze,.e-rightfreeze,.e-fixedfreeze,.e-freezerightborder,.e-freezeleftborder'));\n if (freezeCells.length) {\n removeClass(freezeCells, ['e-leftfreeze', 'e-unfreeze', 'e-rightfreeze', 'e-fixedfreeze', 'e-freezerightborder', 'e-freezeleftborder']);\n }\n if (tr.querySelector('.e-summarycell')) {\n groupCaptionRowLeftRightPos(tr, this.parent);\n }\n else {\n for (var j = 0; j < tr.childNodes.length; j++) {\n var td = tr.childNodes[parseInt(j.toString(), 10)];\n td.classList.add('e-leftfreeze');\n applyStickyLeftRightPosition(td, j * 30, this.parent.enableRtl, 'Left');\n if (td.classList.contains('e-groupcaption')) {\n var oldColspan = parseInt(td.getAttribute('colspan'), 10);\n var colspan = resetColspanGroupCaption(this.parent, j);\n td.setAttribute('colspan', colspan.toString());\n emptyColspan = oldColspan - colspan;\n }\n }\n if (emptyColspan) {\n var td = this.parent.createElement('TD', {\n className: 'e-groupcaption',\n attrs: { colspan: emptyColspan.toString(), id: this.parent.element.id + 'captioncell', tabindex: '-1' }\n });\n tr.appendChild(td);\n }\n }\n }\n if (tr.querySelectorAll('.e-leftfreeze').length &&\n (tr.querySelectorAll('.e-indentcell').length || tr.querySelectorAll('.e-grouptopleftcell').length)) {\n var td = tr.querySelectorAll('.e-indentcell, .e-grouptopleftcell');\n for (var i = 0; i < td.length; i++) {\n td[parseInt(i.toString(), 10)].classList.add('e-leftfreeze');\n applyStickyLeftRightPosition(td[parseInt(i.toString(), 10)], i * 30, this.parent.enableRtl, 'Left');\n }\n }\n }\n var args = { row: tr, rowHeight: this.parent.rowHeight };\n if (row.isDataRow) {\n var eventArg_1 = extend(rowArgs, args);\n eventArg_1.isSelectable = true;\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n var cellTemplate = eventArg_1.row.querySelectorAll('.e-templatecell');\n if (((this.parent.isReact && this.parent.requireTemplateRef) || (isReactChild &&\n this.parent.parentDetails.parentInstObj.requireTemplateRef)) && cellTemplate.length) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var thisRef_2 = this;\n thisRef_2.parent.renderTemplates(function () {\n thisRef_2.parent.trigger(rowDataBound, eventArg_1);\n if (!eventArg_1.isSelectable) {\n row.isSelectable = eventArg_1.isSelectable;\n thisRef_2.disableRowSelection(thisRef_2, row, args, eventArg_1);\n }\n });\n }\n else {\n this.parent.trigger(rowDataBound, eventArg_1);\n }\n row.isSelectable = eventArg_1.isSelectable;\n var isDraggable = this.parent.isRowDragable();\n if (this.parent.allowPaging && this.parent.selectionSettings.persistSelection) {\n var primaryKey_1 = this.parent.getPrimaryKeyFieldNames()[0];\n var pKey_1 = row.data ? row.data[\"\" + primaryKey_1] : null;\n var SelectedRecords = eventArg_1.isSelectable ? this.parent.partialSelectedRecords :\n this.parent.disableSelectedRecords;\n if (!SelectedRecords.some(function (data) { return data[\"\" + primaryKey_1] === pKey_1; })) {\n SelectedRecords.push(row.data);\n }\n }\n if (!eventArg_1.isSelectable) {\n this.disableRowSelection(this, row, args, eventArg_1);\n }\n if (this.parent.childGrid || isDraggable || this.parent.detailTemplate) {\n var td = tr.querySelectorAll('.e-rowcell:not(.e-hide)')[0];\n if (td) {\n td.classList.add('e-detailrowvisible');\n }\n }\n }\n if (this.parent.enableVirtualization) {\n rowArgs.rowHeight = this.parent.rowHeight;\n }\n if (rowArgs.rowHeight) {\n tr.style.height = rowArgs.rowHeight + 'px';\n }\n else if (this.parent.rowHeight && (tr.querySelector('.e-headercell') || tr.querySelector('.e-groupcaption'))) {\n tr.style.height = this.parent.rowHeight + 'px';\n }\n if (row.cssClass) {\n tr.classList.add(row.cssClass);\n }\n if (row.lazyLoadCssClass) {\n tr.classList.add(row.lazyLoadCssClass);\n }\n if (this.parent.rowRenderingMode === 'Vertical' && this.parent.allowTextWrap && (this.parent.textWrapSettings.wrapMode === 'Header'\n || this.parent.textWrapSettings.wrapMode === 'Both')) {\n tr.classList.add('e-verticalwrap');\n }\n var vFTable = this.parent.enableColumnVirtualization;\n if (!vFTable && this.parent.aggregates.length && this.parent.element.scrollHeight > this.parent.height) {\n for (var i = 0; i < this.parent.aggregates.length; i++) {\n var property = 'properties';\n var column = 'columns';\n if (this.parent.aggregates[parseInt(i.toString(), 10)][\"\" + property][\"\" + column][0].footerTemplate) {\n var summarycell = [].slice.call(tr.getElementsByClassName('e-summarycell'));\n if (summarycell.length) {\n var lastSummaryCell = (summarycell[summarycell.length - 1]);\n addClass([lastSummaryCell], ['e-lastsummarycell']);\n var firstSummaryCell = (summarycell[0]);\n addClass([firstSummaryCell], ['e-firstsummarycell']);\n }\n }\n }\n }\n return tr;\n };\n RowRenderer.prototype.disableRowSelection = function (thisRef, row, args, eventArg) {\n var selIndex = this.parent.getSelectedRowIndexes();\n this.parent.selectionModule.isPartialSelection = true;\n row.isSelected = false;\n var selRowIndex = selIndex.indexOf(row.index);\n if (selRowIndex > -1) {\n selIndex.splice(selRowIndex, 1);\n }\n var chkBox = args.row.querySelectorAll('.e-rowcell.e-gridchkbox');\n var isDrag = eventArg.row.querySelector('.e-rowdragdrop');\n var cellIdx = thisRef.parent.groupSettings.columns.length + (isDrag || thisRef.parent.isDetail() ? 1 : 0);\n for (var i = 0; i < chkBox.length; i++) {\n chkBox[parseInt(i.toString(), 10)].firstElementChild.classList.add('e-checkbox-disabled');\n chkBox[parseInt(i.toString(), 10)].querySelector('.e-frame').classList.remove('e-check');\n }\n if (row.cells.length) {\n for (var i = cellIdx; i < row.cells.length; i++) {\n var cell = eventArg.row.querySelector('.e-rowcell[data-colindex=\"' + row.cells[parseInt(i.toString(), 10)].index + '\"]');\n if (cell) {\n removeClass([cell], ['e-selectionbackground', 'e-active']);\n }\n }\n }\n if (isDrag) {\n removeClass([isDrag], ['e-selectionbackground', 'e-active']);\n }\n };\n ;\n RowRenderer.prototype.refreshMergeCells = function (row) {\n for (var _i = 0, _a = row.cells; _i < _a.length; _i++) {\n var cell = _a[_i];\n cell.isSpanned = false;\n }\n return row;\n };\n /* eslint-disable */\n /**\n * Function to check and add alternative row css class.\n *\n * @param {Element} tr - specifies the tr element\n * @param {Row<T>} row - specifies the row\n * @returns {void}\n */\n /* eslint-enable */\n RowRenderer.prototype.buildAttributeFromRow = function (tr, row) {\n var attr = {};\n var prop = { 'rowindex': literals.dataRowIndex, 'dataUID': 'data-uid', 'ariaSelected': 'aria-selected' };\n var classes = [];\n if (row.isDataRow) {\n classes.push(literals.row);\n }\n if (row.isAltRow) {\n classes.push('e-altrow');\n }\n if (row.isCaptionRow) {\n classes.push('e-groupcaptionrow');\n }\n if (row.isAggregateRow && row.parentUid) {\n classes.push('e-groupfooterrow');\n }\n if (!isNullOrUndefined(row.index)) {\n attr[literals.ariaRowIndex] = row.index + 1;\n attr[prop.rowindex] = row.index;\n }\n if (row.rowSpan) {\n attr.rowSpan = row.rowSpan;\n }\n if (row.uid) {\n attr[prop.dataUID] = row.uid;\n }\n if (row.isSelected) {\n attr[prop.ariaSelected] = true;\n }\n if (row.visible === false) {\n classes.push('e-hide');\n }\n attr.class = classes;\n setStyleAndAttributes(tr, attr);\n };\n return RowRenderer;\n}());\nexport { RowRenderer };\n","//! moment.js locale configuration\n//! locale : Galician [gl]\n//! author : Juan G. Hurtado : https://github.com/juanghurtado\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var gl = moment.defineLocale('gl', {\n months: 'xaneiro_febreiro_marzo_abril_maio_xuño_xullo_agosto_setembro_outubro_novembro_decembro'.split(\n '_'\n ),\n monthsShort:\n 'xan._feb._mar._abr._mai._xuñ._xul._ago._set._out._nov._dec.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'domingo_luns_martes_mércores_xoves_venres_sábado'.split('_'),\n weekdaysShort: 'dom._lun._mar._mér._xov._ven._sáb.'.split('_'),\n weekdaysMin: 'do_lu_ma_mé_xo_ve_sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D [de] MMMM [de] YYYY',\n LLL: 'D [de] MMMM [de] YYYY H:mm',\n LLLL: 'dddd, D [de] MMMM [de] YYYY H:mm',\n },\n calendar: {\n sameDay: function () {\n return '[hoxe ' + (this.hours() !== 1 ? 'ás' : 'á') + '] LT';\n },\n nextDay: function () {\n return '[mañá ' + (this.hours() !== 1 ? 'ás' : 'á') + '] LT';\n },\n nextWeek: function () {\n return 'dddd [' + (this.hours() !== 1 ? 'ás' : 'a') + '] LT';\n },\n lastDay: function () {\n return '[onte ' + (this.hours() !== 1 ? 'á' : 'a') + '] LT';\n },\n lastWeek: function () {\n return (\n '[o] dddd [pasado ' + (this.hours() !== 1 ? 'ás' : 'a') + '] LT'\n );\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: function (str) {\n if (str.indexOf('un') === 0) {\n return 'n' + str;\n }\n return 'en ' + str;\n },\n past: 'hai %s',\n s: 'uns segundos',\n ss: '%d segundos',\n m: 'un minuto',\n mm: '%d minutos',\n h: 'unha hora',\n hh: '%d horas',\n d: 'un dÃa',\n dd: '%d dÃas',\n M: 'un mes',\n MM: '%d meses',\n y: 'un ano',\n yy: '%d anos',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return gl;\n\n})));\n","//! moment.js locale configuration\n//! locale : Spanish [es]\n//! author : Julio Napurà : https://github.com/julionc\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsShortDot =\n 'ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.'.split(\n '_'\n ),\n monthsShort = 'ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic'.split('_'),\n monthsParse = [\n /^ene/i,\n /^feb/i,\n /^mar/i,\n /^abr/i,\n /^may/i,\n /^jun/i,\n /^jul/i,\n /^ago/i,\n /^sep/i,\n /^oct/i,\n /^nov/i,\n /^dic/i,\n ],\n monthsRegex =\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i;\n\n var es = moment.defineLocale('es', {\n months: 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split(\n '_'\n ),\n monthsShort: function (m, format) {\n if (!m) {\n return monthsShortDot;\n } else if (/-MMM-/.test(format)) {\n return monthsShort[m.month()];\n } else {\n return monthsShortDot[m.month()];\n }\n },\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex:\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,\n monthsShortStrictRegex:\n /^(ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i,\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n weekdays: 'domingo_lunes_martes_miércoles_jueves_viernes_sábado'.split('_'),\n weekdaysShort: 'dom._lun._mar._mié._jue._vie._sáb.'.split('_'),\n weekdaysMin: 'do_lu_ma_mi_ju_vi_sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D [de] MMMM [de] YYYY',\n LLL: 'D [de] MMMM [de] YYYY H:mm',\n LLLL: 'dddd, D [de] MMMM [de] YYYY H:mm',\n },\n calendar: {\n sameDay: function () {\n return '[hoy a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextDay: function () {\n return '[mañana a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextWeek: function () {\n return 'dddd [a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastDay: function () {\n return '[ayer a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastWeek: function () {\n return (\n '[el] dddd [pasado a la' +\n (this.hours() !== 1 ? 's' : '') +\n '] LT'\n );\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'en %s',\n past: 'hace %s',\n s: 'unos segundos',\n ss: '%d segundos',\n m: 'un minuto',\n mm: '%d minutos',\n h: 'una hora',\n hh: '%d horas',\n d: 'un dÃa',\n dd: '%d dÃas',\n w: 'una semana',\n ww: '%d semanas',\n M: 'un mes',\n MM: '%d meses',\n y: 'un año',\n yy: '%d años',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n invalidDate: 'Fecha inválida',\n });\n\n return es;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-returns */\nimport { withInRange } from '../../common/utils/helper';\nimport { ColumnBase } from './column-base';\n/**\n * `ColumnSeries` Module used to render the column series.\n */\nvar ColumnSeries = /** @class */ (function (_super) {\n __extends(ColumnSeries, _super);\n function ColumnSeries() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n ColumnSeries.prototype.render = function (series) {\n var sideBySideInfo = this.getSideBySideInfo(series);\n var origin = Math.max(series.yAxis.visibleRange.min, 0);\n var argsData;\n for (var _i = 0, _a = series.points; _i < _a.length; _i++) {\n var pointColumn = _a[_i];\n pointColumn.symbolLocations = [];\n pointColumn.regions = [];\n if (pointColumn.visible && withInRange(series.points[pointColumn.index - 1], pointColumn, series.points[pointColumn.index + 1], series)) {\n this.rect = this.getRectangle(pointColumn.xValue + sideBySideInfo.start, pointColumn.yValue, pointColumn.xValue + sideBySideInfo.end, origin, series);\n this.rect.width = series.columnWidthInPixel ? (series.columnWidthInPixel - (series.chart.enableSideBySidePlacement ? series.columnWidthInPixel * series.columnSpacing : 0)) : this.rect.width;\n this.rect.x = series.columnWidthInPixel ? this.rect.x - (((series.columnWidthInPixel / 2) * series.rectCount) -\n (series.columnWidthInPixel * series.index)) : this.rect.x;\n var color = series.category === 'Indicator' ? pointColumn.color : series.interior;\n argsData = this.triggerEvent(series, pointColumn, color, { width: series.border.width, color: series.border.color });\n if (!argsData.cancel) {\n this.updateSymbolLocation(pointColumn, this.rect, series);\n this.drawRectangle(series, pointColumn, this.rect, argsData);\n if (series.columnFacet === 'Cylinder') {\n var cylinderSeriesOption = {\n 'isColumn': true,\n 'stacking': false,\n 'isLastSeries': true\n };\n this.drawCylinder(this.options, this.element, cylinderSeriesOption, this.rect, series);\n }\n }\n }\n }\n this.renderMarker(series);\n };\n /**\n * Animates the series.\n *\n * @param {Series} series - Defines the series to animate.\n * @returns {void}\n */\n ColumnSeries.prototype.doAnimation = function (series) {\n this.animate(series);\n };\n /**\n * Get module name.\n */\n ColumnSeries.prototype.getModuleName = function () {\n return 'ColumnSeries';\n /**\n * return the module name\n */\n };\n /**\n * To destroy the column series.\n *\n * @returns {void}\n * @private\n */\n ColumnSeries.prototype.destroy = function () {\n /**\n * Destroy method performed here\n */\n };\n return ColumnSeries;\n}(ColumnBase));\nexport { ColumnSeries };\n","import { isNullOrUndefined, getValue, setValue } from '@syncfusion/ej2-base';\nimport { Row } from '../models/row';\nimport { CellType } from '../base/enum';\nimport { Cell } from '../models/cell';\nimport { getUid } from '../base/util';\nimport { getForeignData } from '../../grid/base/util';\nimport * as events from '../base/constant';\n/**\n * RowModelGenerator is used to generate grid data rows.\n *\n * @hidden\n */\nvar RowModelGenerator = /** @class */ (function () {\n /**\n * Constructor for header renderer module\n *\n * @param {IGrid} parent - specifies the IGrid\n */\n function RowModelGenerator(parent) {\n this.parent = parent;\n }\n RowModelGenerator.prototype.generateRows = function (data, args) {\n var rows = [];\n var startIndex = this.parent.enableVirtualization && args ? args.startIndex : 0;\n startIndex = this.parent.enableInfiniteScrolling && args ? this.getInfiniteIndex(args) : startIndex;\n if (this.parent.enableImmutableMode && args && args.startIndex) {\n startIndex = args.startIndex;\n }\n for (var i = 0, len = Object.keys(data).length; i < len; i++, startIndex++) {\n rows[parseInt(i.toString(), 10)] = this.generateRow(data[parseInt(i.toString(), 10)], startIndex);\n }\n return rows;\n };\n RowModelGenerator.prototype.ensureColumns = function () {\n //TODO: generate dummy column for group, detail here;\n var cols = [];\n if (this.parent.detailTemplate || this.parent.childGrid) {\n var args = {};\n this.parent.notify(events.detailIndentCellInfo, args);\n cols.push(this.generateCell(args, null, CellType.DetailExpand));\n }\n if (this.parent.isRowDragable()) {\n cols.push(this.generateCell({}, null, CellType.RowDragIcon));\n }\n return cols;\n };\n RowModelGenerator.prototype.generateRow = function (data, index, cssClass, indent, pid, tIndex, parentUid) {\n var options = {};\n options.foreignKeyData = {};\n options.uid = getUid('grid-row');\n options.data = data;\n options.index = index;\n options.indent = indent;\n options.tIndex = tIndex;\n options.isDataRow = true;\n options.parentGid = pid;\n options.parentUid = parentUid;\n if (this.parent.isPrinting) {\n if (this.parent.hierarchyPrintMode === 'All') {\n options.isExpand = true;\n }\n else if (this.parent.hierarchyPrintMode === 'Expanded' && this.parent.expandedRows && this.parent.expandedRows[parseInt(index.toString(), 10)]) {\n options.isExpand = this.parent.expandedRows[parseInt(index.toString(), 10)].isExpand;\n }\n }\n options.cssClass = cssClass;\n options.isAltRow = this.parent.enableAltRow ? index % 2 !== 0 : false;\n options.isAltRow = this.parent.enableAltRow ? index % 2 !== 0 : false;\n options.isSelected = this.parent.getSelectedRowIndexes().indexOf(index) > -1;\n this.refreshForeignKeyRow(options);\n var cells = this.ensureColumns();\n var row = new Row(options, this.parent);\n row.cells = this.parent.getFrozenMode() === 'Right' ? this.generateCells(options).concat(cells)\n : cells.concat(this.generateCells(options));\n return row;\n };\n RowModelGenerator.prototype.refreshForeignKeyRow = function (options) {\n var foreignKeyColumns = this.parent.getForeignKeyColumns();\n for (var i = 0; i < foreignKeyColumns.length; i++) {\n setValue(foreignKeyColumns[parseInt(i.toString(), 10)].field, getForeignData(foreignKeyColumns[parseInt(i.toString(), 10)], options.data), options.foreignKeyData);\n }\n };\n RowModelGenerator.prototype.generateCells = function (options) {\n var dummies = this.parent.getColumns();\n var tmp = [];\n for (var i = 0; i < dummies.length; i++) {\n tmp.push(this.generateCell(dummies[parseInt(i.toString(), 10)], options.uid, isNullOrUndefined(dummies[parseInt(i.toString(), 10)].commands) ? undefined : CellType.CommandColumn, null, i, options.foreignKeyData));\n }\n return tmp;\n };\n /**\n *\n * @param {Column} column - Defines column details\n * @param {string} rowId - Defines row id\n * @param {CellType} cellType - Defines cell type\n * @param {number} colSpan - Defines colSpan\n * @param {number} oIndex - Defines index\n * @param {Object} foreignKeyData - Defines foreign key data\n * @returns {Cell<Column>} returns cell model\n * @hidden\n */\n RowModelGenerator.prototype.generateCell = function (column, rowId, cellType, colSpan, oIndex, foreignKeyData) {\n var opt = {\n 'visible': column.visible,\n 'isDataCell': !isNullOrUndefined(column.field || column.template),\n 'isTemplate': !isNullOrUndefined(column.template),\n 'rowID': rowId,\n 'column': column,\n 'cellType': !isNullOrUndefined(cellType) ? cellType : CellType.Data,\n 'colSpan': colSpan,\n 'commands': column.commands,\n 'isForeignKey': column.isForeignColumn && column.isForeignColumn(),\n 'foreignKeyData': column.isForeignColumn && column.isForeignColumn() && getValue(column.field, foreignKeyData)\n };\n if (opt.isDataCell || opt.column.type === 'checkbox' || opt.commands) {\n opt.index = oIndex;\n }\n return new Cell(opt);\n };\n RowModelGenerator.prototype.refreshRows = function (input) {\n for (var i = 0; i < input.length; i++) {\n this.refreshForeignKeyRow(input[parseInt(i.toString(), 10)]);\n input[parseInt(i.toString(), 10)].cells = this.generateCells(input[parseInt(i.toString(), 10)]);\n }\n return input;\n };\n RowModelGenerator.prototype.getInfiniteIndex = function (args) {\n return args.requestType === 'infiniteScroll' || args.requestType === 'delete' || args.action === 'add'\n ? (isNullOrUndefined(args.startIndex) ? args['index'] : args.startIndex) : 0;\n };\n return RowModelGenerator;\n}());\nexport { RowModelGenerator };\n","//! moment.js locale configuration\n//! locale : Greek [el]\n//! author : Aggelos Karalias : https://github.com/mehiel\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function isFunction(input) {\n return (\n (typeof Function !== 'undefined' && input instanceof Function) ||\n Object.prototype.toString.call(input) === '[object Function]'\n );\n }\n\n var el = moment.defineLocale('el', {\n monthsNominativeEl:\n 'ΙανουάÏιος_ΦεβÏουάÏιος_ΜάÏτιος_ΑπÏίλιος_Μάιος_ΙοÏνιος_ΙοÏλιος_ΑÏγουστος_ΣεπτÎμβÏιος_ΟκτώβÏιος_ÎοÎμβÏιος_ΔεκÎμβÏιος'.split(\n '_'\n ),\n monthsGenitiveEl:\n 'ΙανουαÏίου_ΦεβÏουαÏίου_ΜαÏτίου_ΑπÏιλίου_ΜαÎου_Ιουνίου_Ιουλίου_ΑυγοÏστου_ΣεπτεμβÏίου_ΟκτωβÏίου_ÎοεμβÏίου_ΔεκεμβÏίου'.split(\n '_'\n ),\n months: function (momentToFormat, format) {\n if (!momentToFormat) {\n return this._monthsNominativeEl;\n } else if (\n typeof format === 'string' &&\n /D/.test(format.substring(0, format.indexOf('MMMM')))\n ) {\n // if there is a day number before 'MMMM'\n return this._monthsGenitiveEl[momentToFormat.month()];\n } else {\n return this._monthsNominativeEl[momentToFormat.month()];\n }\n },\n monthsShort: 'Ιαν_Φεβ_ΜαÏ_ΑπÏ_Μαϊ_Ιουν_Ιουλ_Αυγ_Σεπ_Οκτ_Îοε_Δεκ'.split('_'),\n weekdays: 'ΚυÏιακή_ΔευτÎÏα_ΤÏίτη_ΤετάÏτη_Î Îμπτη_ΠαÏασκευή_Σάββατο'.split(\n '_'\n ),\n weekdaysShort: 'ΚυÏ_Δευ_ΤÏι_Τετ_Πεμ_ΠαÏ_Σαβ'.split('_'),\n weekdaysMin: 'Κυ_Δε_ΤÏ_Τε_Πε_Πα_Σα'.split('_'),\n meridiem: function (hours, minutes, isLower) {\n if (hours > 11) {\n return isLower ? 'μμ' : 'ΜΜ';\n } else {\n return isLower ? 'πμ' : 'Î Îœ';\n }\n },\n isPM: function (input) {\n return (input + '').toLowerCase()[0] === 'μ';\n },\n meridiemParse: /[Î Îœ]\\.?Îœ?\\.?/i,\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY h:mm A',\n LLLL: 'dddd, D MMMM YYYY h:mm A',\n },\n calendarEl: {\n sameDay: '[ΣήμεÏα {}] LT',\n nextDay: '[ΑÏÏιο {}] LT',\n nextWeek: 'dddd [{}] LT',\n lastDay: '[Χθες {}] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 6:\n return '[το Ï€ÏοηγοÏμενο] dddd [{}] LT';\n default:\n return '[την Ï€ÏοηγοÏμενη] dddd [{}] LT';\n }\n },\n sameElse: 'L',\n },\n calendar: function (key, mom) {\n var output = this._calendarEl[key],\n hours = mom && mom.hours();\n if (isFunction(output)) {\n output = output.apply(mom);\n }\n return output.replace('{}', hours % 12 === 1 ? 'στη' : 'στις');\n },\n relativeTime: {\n future: 'σε %s',\n past: '%s Ï€Ïιν',\n s: 'λίγα δευτεÏόλεπτα',\n ss: '%d δευτεÏόλεπτα',\n m: 'Îνα λεπτό',\n mm: '%d λεπτά',\n h: 'μία ÏŽÏα',\n hh: '%d ÏŽÏες',\n d: 'μία μÎÏα',\n dd: '%d μÎÏες',\n M: 'Îνας μήνας',\n MM: '%d μήνες',\n y: 'Îνας χÏόνος',\n yy: '%d χÏόνια',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}η/,\n ordinal: '%dη',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4st is the first week of the year.\n },\n });\n\n return el;\n\n})));\n","//! moment.js locale configuration\n//! locale : Polish [pl]\n//! author : Rafal Hirsz : https://github.com/evoL\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsNominative =\n 'styczeÅ„_luty_marzec_kwiecieÅ„_maj_czerwiec_lipiec_sierpieÅ„_wrzesieÅ„_październik_listopad_grudzieÅ„'.split(\n '_'\n ),\n monthsSubjective =\n 'stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_wrzeÅ›nia_października_listopada_grudnia'.split(\n '_'\n ),\n monthsParse = [\n /^sty/i,\n /^lut/i,\n /^mar/i,\n /^kwi/i,\n /^maj/i,\n /^cze/i,\n /^lip/i,\n /^sie/i,\n /^wrz/i,\n /^paź/i,\n /^lis/i,\n /^gru/i,\n ];\n function plural(n) {\n return n % 10 < 5 && n % 10 > 1 && ~~(n / 10) % 10 !== 1;\n }\n function translate(number, withoutSuffix, key) {\n var result = number + ' ';\n switch (key) {\n case 'ss':\n return result + (plural(number) ? 'sekundy' : 'sekund');\n case 'm':\n return withoutSuffix ? 'minuta' : 'minutÄ™';\n case 'mm':\n return result + (plural(number) ? 'minuty' : 'minut');\n case 'h':\n return withoutSuffix ? 'godzina' : 'godzinÄ™';\n case 'hh':\n return result + (plural(number) ? 'godziny' : 'godzin');\n case 'ww':\n return result + (plural(number) ? 'tygodnie' : 'tygodni');\n case 'MM':\n return result + (plural(number) ? 'miesiÄ…ce' : 'miesiÄ™cy');\n case 'yy':\n return result + (plural(number) ? 'lata' : 'lat');\n }\n }\n\n var pl = moment.defineLocale('pl', {\n months: function (momentToFormat, format) {\n if (!momentToFormat) {\n return monthsNominative;\n } else if (/D MMMM/.test(format)) {\n return monthsSubjective[momentToFormat.month()];\n } else {\n return monthsNominative[momentToFormat.month()];\n }\n },\n monthsShort: 'sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru'.split('_'),\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n weekdays:\n 'niedziela_poniedziaÅ‚ek_wtorek_Å›roda_czwartek_piÄ…tek_sobota'.split('_'),\n weekdaysShort: 'ndz_pon_wt_Å›r_czw_pt_sob'.split('_'),\n weekdaysMin: 'Nd_Pn_Wt_Åšr_Cz_Pt_So'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[DziÅ› o] LT',\n nextDay: '[Jutro o] LT',\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[W niedzielÄ™ o] LT';\n\n case 2:\n return '[We wtorek o] LT';\n\n case 3:\n return '[W Å›rodÄ™ o] LT';\n\n case 6:\n return '[W sobotÄ™ o] LT';\n\n default:\n return '[W] dddd [o] LT';\n }\n },\n lastDay: '[Wczoraj o] LT',\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n return '[W zeszÅ‚Ä… niedzielÄ™ o] LT';\n case 3:\n return '[W zeszÅ‚Ä… Å›rodÄ™ o] LT';\n case 6:\n return '[W zeszÅ‚Ä… sobotÄ™ o] LT';\n default:\n return '[W zeszÅ‚y] dddd [o] LT';\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'za %s',\n past: '%s temu',\n s: 'kilka sekund',\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: '1 dzieÅ„',\n dd: '%d dni',\n w: 'tydzieÅ„',\n ww: translate,\n M: 'miesiÄ…c',\n MM: translate,\n y: 'rok',\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return pl;\n\n})));\n","//! moment.js locale configuration\n//! locale : Persian [fa]\n//! author : Ebrahim Byagowi : https://github.com/ebraminio\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: 'Û±',\n 2: 'Û²',\n 3: 'Û³',\n 4: 'Û´',\n 5: 'Ûµ',\n 6: 'Û¶',\n 7: 'Û·',\n 8: 'Û¸',\n 9: 'Û¹',\n 0: 'Û°',\n },\n numberMap = {\n 'Û±': '1',\n 'Û²': '2',\n 'Û³': '3',\n 'Û´': '4',\n 'Ûµ': '5',\n 'Û¶': '6',\n 'Û·': '7',\n 'Û¸': '8',\n 'Û¹': '9',\n 'Û°': '0',\n };\n\n var fa = moment.defineLocale('fa', {\n months: 'ژانویه_Ùوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر'.split(\n '_'\n ),\n monthsShort:\n 'ژانویه_Ùوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر'.split(\n '_'\n ),\n weekdays:\n 'یک\\u200cشنبه_دوشنبه_سه\\u200cشنبه_چهارشنبه_پنج\\u200cشنبه_جمعه_شنبه'.split(\n '_'\n ),\n weekdaysShort:\n 'یک\\u200cشنبه_دوشنبه_سه\\u200cشنبه_چهارشنبه_پنج\\u200cشنبه_جمعه_شنبه'.split(\n '_'\n ),\n weekdaysMin: 'ÛŒ_د_س_Ú†_Ù¾_ج_Ø´'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n meridiemParse: /قبل از ظهر|بعد از ظهر/,\n isPM: function (input) {\n return /بعد از ظهر/.test(input);\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'قبل از ظهر';\n } else {\n return 'بعد از ظهر';\n }\n },\n calendar: {\n sameDay: '[امروز ساعت] LT',\n nextDay: '[Ùردا ساعت] LT',\n nextWeek: 'dddd [ساعت] LT',\n lastDay: '[دیروز ساعت] LT',\n lastWeek: 'dddd [پیش] [ساعت] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'در %s',\n past: '%s پیش',\n s: 'چند ثانیه',\n ss: '%d ثانیه',\n m: 'یک دقیقه',\n mm: '%d دقیقه',\n h: 'یک ساعت',\n hh: '%d ساعت',\n d: 'یک روز',\n dd: '%d روز',\n M: 'یک ماه',\n MM: '%d ماه',\n y: 'یک سال',\n yy: '%d سال',\n },\n preparse: function (string) {\n return string\n .replace(/[Û°-Û¹]/g, function (match) {\n return numberMap[match];\n })\n .replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string\n .replace(/\\d/g, function (match) {\n return symbolMap[match];\n })\n .replace(/,/g, 'ØŒ');\n },\n dayOfMonthOrdinalParse: /\\d{1,2}Ù…/,\n ordinal: '%dÙ…',\n week: {\n dow: 6, // Saturday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return fa;\n\n})));\n","//! moment.js locale configuration\n//! locale : Arabic [ar]\n//! author : Abdel Said: https://github.com/abdelsaid\n//! author : Ahmed Elkhatib\n//! author : forabi https://github.com/forabi\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: 'Ù¡',\n 2: 'Ù¢',\n 3: 'Ù£',\n 4: 'Ù¤',\n 5: 'Ù¥',\n 6: 'Ù¦',\n 7: 'Ù§',\n 8: 'Ù¨',\n 9: 'Ù©',\n 0: 'Ù ',\n },\n numberMap = {\n 'Ù¡': '1',\n 'Ù¢': '2',\n 'Ù£': '3',\n 'Ù¤': '4',\n 'Ù¥': '5',\n 'Ù¦': '6',\n 'Ù§': '7',\n 'Ù¨': '8',\n 'Ù©': '9',\n 'Ù ': '0',\n },\n pluralForm = function (n) {\n return n === 0\n ? 0\n : n === 1\n ? 1\n : n === 2\n ? 2\n : n % 100 >= 3 && n % 100 <= 10\n ? 3\n : n % 100 >= 11\n ? 4\n : 5;\n },\n plurals = {\n s: [\n 'أقل من ثانية',\n 'ثانية واØدة',\n ['ثانيتان', 'ثانيتين'],\n '%d ثوان',\n '%d ثانية',\n '%d ثانية',\n ],\n m: [\n 'أقل من دقيقة',\n 'دقيقة واØدة',\n ['دقيقتان', 'دقيقتين'],\n '%d دقائق',\n '%d دقيقة',\n '%d دقيقة',\n ],\n h: [\n 'أقل من ساعة',\n 'ساعة واØدة',\n ['ساعتان', 'ساعتين'],\n '%d ساعات',\n '%d ساعة',\n '%d ساعة',\n ],\n d: [\n 'أقل من يوم',\n 'يوم واØد',\n ['يومان', 'يومين'],\n '%d أيام',\n '%d يومًا',\n '%d يوم',\n ],\n M: [\n 'أقل من شهر',\n 'شهر واØد',\n ['شهران', 'شهرين'],\n '%d أشهر',\n '%d شهرا',\n '%d شهر',\n ],\n y: [\n 'أقل من عام',\n 'عام واØد',\n ['عامان', 'عامين'],\n '%d أعوام',\n '%d عامًا',\n '%d عام',\n ],\n },\n pluralize = function (u) {\n return function (number, withoutSuffix, string, isFuture) {\n var f = pluralForm(number),\n str = plurals[u][pluralForm(number)];\n if (f === 2) {\n str = str[withoutSuffix ? 0 : 1];\n }\n return str.replace(/%d/i, number);\n };\n },\n months = [\n 'يناير',\n 'Ùبراير',\n 'مارس',\n 'أبريل',\n 'مايو',\n 'يونيو',\n 'يوليو',\n 'أغسطس',\n 'سبتمبر',\n 'أكتوبر',\n 'نوÙمبر',\n 'ديسمبر',\n ];\n\n var ar = moment.defineLocale('ar', {\n months: months,\n monthsShort: months,\n weekdays: 'الأØد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),\n weekdaysShort: 'Ø£Øد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت'.split('_'),\n weekdaysMin: 'Ø_Ù†_Ø«_ر_Ø®_ج_س'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'D/\\u200FM/\\u200FYYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n meridiemParse: /ص|Ù…/,\n isPM: function (input) {\n return 'Ù…' === input;\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'ص';\n } else {\n return 'Ù…';\n }\n },\n calendar: {\n sameDay: '[اليوم عند الساعة] LT',\n nextDay: '[غدًا عند الساعة] LT',\n nextWeek: 'dddd [عند الساعة] LT',\n lastDay: '[أمس عند الساعة] LT',\n lastWeek: 'dddd [عند الساعة] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'بعد %s',\n past: 'منذ %s',\n s: pluralize('s'),\n ss: pluralize('s'),\n m: pluralize('m'),\n mm: pluralize('m'),\n h: pluralize('h'),\n hh: pluralize('h'),\n d: pluralize('d'),\n dd: pluralize('d'),\n M: pluralize('M'),\n MM: pluralize('M'),\n y: pluralize('y'),\n yy: pluralize('y'),\n },\n preparse: function (string) {\n return string\n .replace(/[١٢٣٤٥٦٧٨٩٠]/g, function (match) {\n return numberMap[match];\n })\n .replace(/ØŒ/g, ',');\n },\n postformat: function (string) {\n return string\n .replace(/\\d/g, function (match) {\n return symbolMap[match];\n })\n .replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 6, // Saturday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return ar;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { withInRange, getPoint, TransformToVisible } from '../../common/utils/helper';\nimport { PathOption } from '@syncfusion/ej2-svg-base';\nimport { LineBase } from './line-base';\n/**\n * `LineSeries` module used to render the line series.\n */\nvar LineSeries = /** @class */ (function (_super) {\n __extends(LineSeries, _super);\n function LineSeries() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * Render Line Series.\n *\n * @returns {void}\n * @private\n */\n LineSeries.prototype.render = function (series, xAxis, yAxis, isInverted) {\n var point1;\n var point2;\n var direction = '';\n var prevPoint = null;\n var startPoint = 'M';\n var isPolar = (series.chart && series.chart.chartAreaType === 'PolarRadar');\n var isDrop = (series.emptyPointSettings && series.emptyPointSettings.mode === 'Drop');\n var getCoordinate = isPolar ? TransformToVisible : getPoint;\n var visiblePoints = series.category === 'TrendLine' ? series.points : this.enableComplexProperty(series);\n for (var _i = 0, visiblePoints_1 = visiblePoints; _i < visiblePoints_1.length; _i++) {\n var point = visiblePoints_1[_i];\n point.regions = [];\n point.symbolLocations = [];\n if (point.visible && withInRange(visiblePoints[point.index - 1], point, visiblePoints[point.index + 1], series)) {\n direction += this.getLineDirection(prevPoint, point, series, isInverted, getCoordinate, startPoint);\n startPoint = prevPoint ? 'L' : startPoint;\n prevPoint = point;\n this.storePointLocation(point, series, isInverted, getCoordinate);\n }\n else {\n prevPoint = isDrop ? prevPoint : null;\n startPoint = isDrop ? startPoint : 'M';\n }\n }\n if (isPolar) {\n if (series.isClosed) {\n var points = this.getFirstLastVisiblePoint(visiblePoints);\n point2 = getCoordinate(points.last.xValue, points.last.yValue, xAxis, yAxis, isInverted, series);\n point1 = getCoordinate(points.first.xValue, points.first.yValue, xAxis, yAxis, isInverted, series);\n direction = direction.concat(startPoint + ' ' + point2.x + ' ' + point2.y + ' ' + 'L' + ' ' + point1.x + ' ' + point1.y);\n }\n }\n var name = series.category === 'Indicator' ? series.chart.element.id + '_Indicator_' + series.index + '_' + series.name :\n series.category === 'TrendLine' ? series.chart.element.id + '_Series_' + series.sourceIndex + '_TrendLine_' + series.index :\n series.chart.element.id + '_Series_' + (series.index === undefined ? series.category : series.index);\n var options = new PathOption(name, 'none', series.width, series.interior, series.opacity, series.dashArray, direction);\n this.appendLinePath(options, series, '');\n this.renderMarker(series);\n };\n /**\n * Animates the series.\n *\n * @param {Series} series - Defines the series to animate.\n * @returns {void}\n */\n LineSeries.prototype.doAnimation = function (series) {\n var option = series.animation;\n this.doProgressiveAnimation(series, option);\n };\n /**\n * Get module name.\n */\n LineSeries.prototype.getModuleName = function () {\n /**\n * Returns the module name of the series\n */\n return 'LineSeries';\n };\n /**\n * To destroy the line series.\n *\n * @returns {void}\n * @private\n */\n LineSeries.prototype.destroy = function () {\n /**\n * Destroy method performed here\n */\n };\n return LineSeries;\n}(LineBase));\nexport { LineSeries };\n","//! moment.js locale configuration\n//! locale : Bengali [bn]\n//! author : Kaushik Gandhi : https://github.com/kaushikgandhi\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '১',\n 2: '২',\n 3: '৩',\n 4: '৪',\n 5: '৫',\n 6: '৬',\n 7: 'à§',\n 8: '৮',\n 9: '৯',\n 0: '০',\n },\n numberMap = {\n '১': '1',\n '২': '2',\n '৩': '3',\n '৪': '4',\n '৫': '5',\n '৬': '6',\n 'à§': '7',\n '৮': '8',\n '৯': '9',\n '০': '0',\n };\n\n var bn = moment.defineLocale('bn', {\n months: 'জানà§à§Ÿà¦¾à¦°à¦¿_ফেবà§à¦°à§à§Ÿà¦¾à¦°à¦¿_মারà§à¦š_à¦à¦ªà§à¦°à¦¿à¦²_মে_জà§à¦¨_জà§à¦²à¦¾à¦‡_আগসà§à¦Ÿ_সেপà§à¦Ÿà§‡à¦®à§à¦¬à¦°_অকà§à¦Ÿà§‹à¦¬à¦°_নà¦à§‡à¦®à§à¦¬à¦°_ডিসেমà§à¦¬à¦°'.split(\n '_'\n ),\n monthsShort:\n 'জানà§_ফেবà§à¦°à§_মারà§à¦š_à¦à¦ªà§à¦°à¦¿à¦²_মে_জà§à¦¨_জà§à¦²à¦¾à¦‡_আগসà§à¦Ÿ_সেপà§à¦Ÿ_অকà§à¦Ÿà§‹_নà¦à§‡_ডিসে'.split(\n '_'\n ),\n weekdays: 'রবিবার_সোমবার_মঙà§à¦—লবার_বà§à¦§à¦¬à¦¾à¦°_বৃহসà§à¦ªà¦¤à¦¿à¦¬à¦¾à¦°_শà§à¦•à§à¦°à¦¬à¦¾à¦°_শনিবার'.split(\n '_'\n ),\n weekdaysShort: 'রবি_সোম_মঙà§à¦—ল_বà§à¦§_বৃহসà§à¦ªà¦¤à¦¿_শà§à¦•à§à¦°_শনি'.split('_'),\n weekdaysMin: 'রবি_সোম_মঙà§à¦—ল_বà§à¦§_বৃহ_শà§à¦•à§à¦°_শনি'.split('_'),\n longDateFormat: {\n LT: 'A h:mm সময়',\n LTS: 'A h:mm:ss সময়',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm সময়',\n LLLL: 'dddd, D MMMM YYYY, A h:mm সময়',\n },\n calendar: {\n sameDay: '[আজ] LT',\n nextDay: '[আগামীকাল] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[গতকাল] LT',\n lastWeek: '[গত] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s পরে',\n past: '%s আগে',\n s: 'কয়েক সেকেনà§à¦¡',\n ss: '%d সেকেনà§à¦¡',\n m: 'à¦à¦• মিনিট',\n mm: '%d মিনিট',\n h: 'à¦à¦• ঘনà§à¦Ÿà¦¾',\n hh: '%d ঘনà§à¦Ÿà¦¾',\n d: 'à¦à¦• দিন',\n dd: '%d দিন',\n M: 'à¦à¦• মাস',\n MM: '%d মাস',\n y: 'à¦à¦• বছর',\n yy: '%d বছর',\n },\n preparse: function (string) {\n return string.replace(/[১২৩৪৫৬à§à§®à§¯à§¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n meridiemParse: /রাত|সকাল|দà§à¦ªà§à¦°|বিকাল|রাত/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (\n (meridiem === 'রাত' && hour >= 4) ||\n (meridiem === 'দà§à¦ªà§à¦°' && hour < 5) ||\n meridiem === 'বিকাল'\n ) {\n return hour + 12;\n } else {\n return hour;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'রাত';\n } else if (hour < 10) {\n return 'সকাল';\n } else if (hour < 17) {\n return 'দà§à¦ªà§à¦°';\n } else if (hour < 20) {\n return 'বিকাল';\n } else {\n return 'রাত';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return bn;\n\n})));\n","//! moment.js locale configuration\n//! locale : Chinese (Taiwan) [zh-tw]\n//! author : Ben : https://github.com/ben-lin\n//! author : Chris Lam : https://github.com/hehachris\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var zhTw = moment.defineLocale('zh-tw', {\n months: '一月_二月_三月_四月_五月_å…月_七月_八月_ä¹æœˆ_å月_å一月_å二月'.split(\n '_'\n ),\n monthsShort: '1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月'.split(\n '_'\n ),\n weekdays: '星期日_星期一_星期二_星期三_星期四_星期五_星期å…'.split('_'),\n weekdaysShort: '週日_週一_週二_週三_週四_週五_週å…'.split('_'),\n weekdaysMin: 'æ—¥_一_二_三_å››_五_å…'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY/MM/DD',\n LL: 'YYYYå¹´M月Dæ—¥',\n LLL: 'YYYYå¹´M月Dæ—¥ HH:mm',\n LLLL: 'YYYYå¹´M月Dæ—¥dddd HH:mm',\n l: 'YYYY/M/D',\n ll: 'YYYYå¹´M月Dæ—¥',\n lll: 'YYYYå¹´M月Dæ—¥ HH:mm',\n llll: 'YYYYå¹´M月Dæ—¥dddd HH:mm',\n },\n meridiemParse: /凌晨|早上|上åˆ|ä¸åˆ|下åˆ|晚上/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === '凌晨' || meridiem === '早上' || meridiem === '上åˆ') {\n return hour;\n } else if (meridiem === 'ä¸åˆ') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === '下åˆ' || meridiem === '晚上') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n var hm = hour * 100 + minute;\n if (hm < 600) {\n return '凌晨';\n } else if (hm < 900) {\n return '早上';\n } else if (hm < 1130) {\n return '上åˆ';\n } else if (hm < 1230) {\n return 'ä¸åˆ';\n } else if (hm < 1800) {\n return '下åˆ';\n } else {\n return '晚上';\n }\n },\n calendar: {\n sameDay: '[今天] LT',\n nextDay: '[明天] LT',\n nextWeek: '[下]dddd LT',\n lastDay: '[昨天] LT',\n lastWeek: '[上]dddd LT',\n sameElse: 'L',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(æ—¥|月|週)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'DDD':\n return number + 'æ—¥';\n case 'M':\n return number + '月';\n case 'w':\n case 'W':\n return number + '週';\n default:\n return number;\n }\n },\n relativeTime: {\n future: '%s後',\n past: '%så‰',\n s: '幾秒',\n ss: '%d 秒',\n m: '1 分é˜',\n mm: '%d 分é˜',\n h: '1 å°æ™‚',\n hh: '%d å°æ™‚',\n d: '1 天',\n dd: '%d 天',\n M: '1 個月',\n MM: '%d 個月',\n y: '1 å¹´',\n yy: '%d å¹´',\n },\n });\n\n return zhTw;\n\n})));\n","/**\n * Defines types of Cell\n *\n * @hidden\n */\nexport var CellType;\n(function (CellType) {\n /** Defines CellType as Data */\n CellType[CellType[\"Data\"] = 0] = \"Data\";\n /** Defines CellType as Header */\n CellType[CellType[\"Header\"] = 1] = \"Header\";\n /** Defines CellType as Summary */\n CellType[CellType[\"Summary\"] = 2] = \"Summary\";\n /** Defines CellType as GroupSummary */\n CellType[CellType[\"GroupSummary\"] = 3] = \"GroupSummary\";\n /** Defines CellType as CaptionSummary */\n CellType[CellType[\"CaptionSummary\"] = 4] = \"CaptionSummary\";\n /** Defines CellType as Filter */\n CellType[CellType[\"Filter\"] = 5] = \"Filter\";\n /** Defines CellType as Indent */\n CellType[CellType[\"Indent\"] = 6] = \"Indent\";\n /** Defines CellType as GroupCaption */\n CellType[CellType[\"GroupCaption\"] = 7] = \"GroupCaption\";\n /** Defines CellType as GroupCaptionEmpty */\n CellType[CellType[\"GroupCaptionEmpty\"] = 8] = \"GroupCaptionEmpty\";\n /** Defines CellType as Expand */\n CellType[CellType[\"Expand\"] = 9] = \"Expand\";\n /** Defines CellType as HeaderIndent */\n CellType[CellType[\"HeaderIndent\"] = 10] = \"HeaderIndent\";\n /** Defines CellType as StackedHeader */\n CellType[CellType[\"StackedHeader\"] = 11] = \"StackedHeader\";\n /** Defines CellType as DetailHeader */\n CellType[CellType[\"DetailHeader\"] = 12] = \"DetailHeader\";\n /** Defines CellType as DetailExpand */\n CellType[CellType[\"DetailExpand\"] = 13] = \"DetailExpand\";\n /** Defines CellType as CommandColumn */\n CellType[CellType[\"CommandColumn\"] = 14] = \"CommandColumn\";\n /** Defines CellType as DetailFooterIntent */\n CellType[CellType[\"DetailFooterIntent\"] = 15] = \"DetailFooterIntent\";\n /** Defines CellType as RowDrag */\n CellType[CellType[\"RowDragIcon\"] = 16] = \"RowDragIcon\";\n /** Defines CellType as RowDragHeader */\n CellType[CellType[\"RowDragHIcon\"] = 17] = \"RowDragHIcon\";\n})(CellType || (CellType = {}));\n/**\n * Defines types of Render\n *\n * @hidden\n */\nexport var RenderType;\n(function (RenderType) {\n /** Defines RenderType as Header */\n RenderType[RenderType[\"Header\"] = 0] = \"Header\";\n /** Defines RenderType as Content */\n RenderType[RenderType[\"Content\"] = 1] = \"Content\";\n /** Defines RenderType as Summary */\n RenderType[RenderType[\"Summary\"] = 2] = \"Summary\";\n})(RenderType || (RenderType = {}));\n/**\n * Defines Predefined toolbar items.\n *\n * @hidden\n */\nexport var ToolbarItem;\n(function (ToolbarItem) {\n ToolbarItem[ToolbarItem[\"Add\"] = 0] = \"Add\";\n ToolbarItem[ToolbarItem[\"Edit\"] = 1] = \"Edit\";\n ToolbarItem[ToolbarItem[\"Update\"] = 2] = \"Update\";\n ToolbarItem[ToolbarItem[\"Delete\"] = 3] = \"Delete\";\n ToolbarItem[ToolbarItem[\"Cancel\"] = 4] = \"Cancel\";\n ToolbarItem[ToolbarItem[\"Print\"] = 5] = \"Print\";\n ToolbarItem[ToolbarItem[\"Search\"] = 6] = \"Search\";\n ToolbarItem[ToolbarItem[\"ColumnChooser\"] = 7] = \"ColumnChooser\";\n ToolbarItem[ToolbarItem[\"PdfExport\"] = 8] = \"PdfExport\";\n ToolbarItem[ToolbarItem[\"ExcelExport\"] = 9] = \"ExcelExport\";\n ToolbarItem[ToolbarItem[\"CsvExport\"] = 10] = \"CsvExport\";\n ToolbarItem[ToolbarItem[\"WordExport\"] = 11] = \"WordExport\";\n})(ToolbarItem || (ToolbarItem = {}));\n/**\n * Defines types of responsive dialogs\n *\n * @hidden\n */\nexport var ResponsiveDialogAction;\n(function (ResponsiveDialogAction) {\n /** Defines dialog type as Edit */\n ResponsiveDialogAction[ResponsiveDialogAction[\"isEdit\"] = 0] = \"isEdit\";\n /** Defines dialog type as Add */\n ResponsiveDialogAction[ResponsiveDialogAction[\"isAdd\"] = 1] = \"isAdd\";\n /** Defines dialog type as Sort */\n ResponsiveDialogAction[ResponsiveDialogAction[\"isSort\"] = 2] = \"isSort\";\n /** Defines dialog type as Filter */\n ResponsiveDialogAction[ResponsiveDialogAction[\"isFilter\"] = 3] = \"isFilter\";\n /** Defines dialog type as ColMenu */\n ResponsiveDialogAction[ResponsiveDialogAction[\"isColMenu\"] = 4] = \"isColMenu\";\n /** Defines dialog type as ColumChooser */\n ResponsiveDialogAction[ResponsiveDialogAction[\"isColumnChooser\"] = 5] = \"isColumnChooser\";\n})(ResponsiveDialogAction || (ResponsiveDialogAction = {}));\n/**\n * Defines responsive toolbar actions\n *\n * @hidden\n */\nexport var ResponsiveToolbarAction;\n(function (ResponsiveToolbarAction) {\n /** Defines initial responsive toolbar buttons */\n ResponsiveToolbarAction[ResponsiveToolbarAction[\"isInitial\"] = 0] = \"isInitial\";\n /** Defines responsive toolbar search */\n ResponsiveToolbarAction[ResponsiveToolbarAction[\"isSearch\"] = 1] = \"isSearch\";\n})(ResponsiveToolbarAction || (ResponsiveToolbarAction = {}));\n","//! moment.js locale configuration\n//! locale : Russian [ru]\n//! author : Viktorminator : https://github.com/Viktorminator\n//! author : Menelion Elensúle : https://github.com/Oire\n//! author : Коренберг Марк : https://github.com/socketpair\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function plural(word, num) {\n var forms = word.split('_');\n return num % 10 === 1 && num % 100 !== 11\n ? forms[0]\n : num % 10 >= 2 && num % 10 <= 4 && (num % 100 < 10 || num % 100 >= 20)\n ? forms[1]\n : forms[2];\n }\n function relativeTimeWithPlural(number, withoutSuffix, key) {\n var format = {\n ss: withoutSuffix ? 'Ñекунда_Ñекунды_Ñекунд' : 'Ñекунду_Ñекунды_Ñекунд',\n mm: withoutSuffix ? 'минута_минуты_минут' : 'минуту_минуты_минут',\n hh: 'чаÑ_чаÑа_чаÑов',\n dd: 'день_днÑ_дней',\n ww: 'неделÑ_недели_недель',\n MM: 'меÑÑц_меÑÑца_меÑÑцев',\n yy: 'год_года_лет',\n };\n if (key === 'm') {\n return withoutSuffix ? 'минута' : 'минуту';\n } else {\n return number + ' ' + plural(format[key], +number);\n }\n }\n var monthsParse = [\n /^Ñнв/i,\n /^фев/i,\n /^мар/i,\n /^апр/i,\n /^ма[йÑ]/i,\n /^июн/i,\n /^июл/i,\n /^авг/i,\n /^Ñен/i,\n /^окт/i,\n /^ноÑ/i,\n /^дек/i,\n ];\n\n // http://new.gramota.ru/spravka/rules/139-prop : § 103\n // Ð¡Ð¾ÐºÑ€Ð°Ñ‰ÐµÐ½Ð¸Ñ Ð¼ÐµÑÑцев: http://new.gramota.ru/spravka/buro/search-answer?s=242637\n // CLDR data: http://www.unicode.org/cldr/charts/28/summary/ru.html#1753\n var ru = moment.defineLocale('ru', {\n months: {\n format: 'ÑнварÑ_февралÑ_марта_апрелÑ_маÑ_июнÑ_июлÑ_авгуÑта_ÑентÑбрÑ_октÑбрÑ_ноÑбрÑ_декабрÑ'.split(\n '_'\n ),\n standalone:\n 'Ñнварь_февраль_март_апрель_май_июнь_июль_авгуÑÑ‚_ÑентÑбрь_октÑбрь_ноÑбрь_декабрь'.split(\n '_'\n ),\n },\n monthsShort: {\n // по CLDR именно \"июл.\" и \"июн.\", но какой ÑмыÑл менÑÑ‚ÑŒ букву на точку?\n format: 'Ñнв._февр._мар._апр._маÑ_июнÑ_июлÑ_авг._Ñент._окт._ноÑб._дек.'.split(\n '_'\n ),\n standalone:\n 'Ñнв._февр._март_апр._май_июнь_июль_авг._Ñент._окт._ноÑб._дек.'.split(\n '_'\n ),\n },\n weekdays: {\n standalone:\n 'воÑкреÑенье_понедельник_вторник_Ñреда_четверг_пÑтница_Ñуббота'.split(\n '_'\n ),\n format: 'воÑкреÑенье_понедельник_вторник_Ñреду_четверг_пÑтницу_Ñубботу'.split(\n '_'\n ),\n isFormat: /\\[ ?[Вв] ?(?:прошлую|Ñледующую|Ñту)? ?] ?dddd/,\n },\n weekdaysShort: 'вÑ_пн_вт_ÑÑ€_чт_пт_Ñб'.split('_'),\n weekdaysMin: 'вÑ_пн_вт_ÑÑ€_чт_пт_Ñб'.split('_'),\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n\n // полные Ð½Ð°Ð·Ð²Ð°Ð½Ð¸Ñ Ñ Ð¿Ð°Ð´ÐµÐ¶Ð°Ð¼Ð¸, по три буквы, Ð´Ð»Ñ Ð½ÐµÐºÐ¾Ñ‚Ð¾Ñ€Ñ‹Ñ…, по 4 буквы, ÑÐ¾ÐºÑ€Ð°Ñ‰ÐµÐ½Ð¸Ñ Ñ Ñ‚Ð¾Ñ‡ÐºÐ¾Ð¹ и без точки\n monthsRegex:\n /^(Ñнвар[ÑŒÑ]|Ñнв\\.?|феврал[ÑŒÑ]|февр?\\.?|марта?|мар\\.?|апрел[ÑŒÑ]|апр\\.?|ма[йÑ]|июн[ÑŒÑ]|июн\\.?|июл[ÑŒÑ]|июл\\.?|авгуÑта?|авг\\.?|ÑентÑбр[ÑŒÑ]|Ñент?\\.?|октÑбр[ÑŒÑ]|окт\\.?|ноÑбр[ÑŒÑ]|ноÑб?\\.?|декабр[ÑŒÑ]|дек\\.?)/i,\n\n // ÐºÐ¾Ð¿Ð¸Ñ Ð¿Ñ€ÐµÐ´Ñ‹Ð´ÑƒÑ‰ÐµÐ³Ð¾\n monthsShortRegex:\n /^(Ñнвар[ÑŒÑ]|Ñнв\\.?|феврал[ÑŒÑ]|февр?\\.?|марта?|мар\\.?|апрел[ÑŒÑ]|апр\\.?|ма[йÑ]|июн[ÑŒÑ]|июн\\.?|июл[ÑŒÑ]|июл\\.?|авгуÑта?|авг\\.?|ÑентÑбр[ÑŒÑ]|Ñент?\\.?|октÑбр[ÑŒÑ]|окт\\.?|ноÑбр[ÑŒÑ]|ноÑб?\\.?|декабр[ÑŒÑ]|дек\\.?)/i,\n\n // полные Ð½Ð°Ð·Ð²Ð°Ð½Ð¸Ñ Ñ Ð¿Ð°Ð´ÐµÐ¶Ð°Ð¼Ð¸\n monthsStrictRegex:\n /^(Ñнвар[ÑÑŒ]|феврал[ÑÑŒ]|марта?|апрел[ÑÑŒ]|ма[Ñй]|июн[ÑÑŒ]|июл[ÑÑŒ]|авгуÑта?|ÑентÑбр[ÑÑŒ]|октÑбр[ÑÑŒ]|ноÑбр[ÑÑŒ]|декабр[ÑÑŒ])/i,\n\n // Выражение, которое ÑоответÑтвует только Ñокращённым формам\n monthsShortStrictRegex:\n /^(Ñнв\\.|февр?\\.|мар[Ñ‚.]|апр\\.|ма[Ñй]|июн[ÑŒÑ.]|июл[ÑŒÑ.]|авг\\.|Ñент?\\.|окт\\.|ноÑб?\\.|дек\\.)/i,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY г.',\n LLL: 'D MMMM YYYY г., H:mm',\n LLLL: 'dddd, D MMMM YYYY г., H:mm',\n },\n calendar: {\n sameDay: '[СегоднÑ, в] LT',\n nextDay: '[Завтра, в] LT',\n lastDay: '[Вчера, в] LT',\n nextWeek: function (now) {\n if (now.week() !== this.week()) {\n switch (this.day()) {\n case 0:\n return '[Ð’ Ñледующее] dddd, [в] LT';\n case 1:\n case 2:\n case 4:\n return '[Ð’ Ñледующий] dddd, [в] LT';\n case 3:\n case 5:\n case 6:\n return '[Ð’ Ñледующую] dddd, [в] LT';\n }\n } else {\n if (this.day() === 2) {\n return '[Во] dddd, [в] LT';\n } else {\n return '[Ð’] dddd, [в] LT';\n }\n }\n },\n lastWeek: function (now) {\n if (now.week() !== this.week()) {\n switch (this.day()) {\n case 0:\n return '[Ð’ прошлое] dddd, [в] LT';\n case 1:\n case 2:\n case 4:\n return '[Ð’ прошлый] dddd, [в] LT';\n case 3:\n case 5:\n case 6:\n return '[Ð’ прошлую] dddd, [в] LT';\n }\n } else {\n if (this.day() === 2) {\n return '[Во] dddd, [в] LT';\n } else {\n return '[Ð’] dddd, [в] LT';\n }\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'через %s',\n past: '%s назад',\n s: 'неÑколько Ñекунд',\n ss: relativeTimeWithPlural,\n m: relativeTimeWithPlural,\n mm: relativeTimeWithPlural,\n h: 'чаÑ',\n hh: relativeTimeWithPlural,\n d: 'день',\n dd: relativeTimeWithPlural,\n w: 'неделÑ',\n ww: relativeTimeWithPlural,\n M: 'меÑÑц',\n MM: relativeTimeWithPlural,\n y: 'год',\n yy: relativeTimeWithPlural,\n },\n meridiemParse: /ночи|утра|днÑ|вечера/i,\n isPM: function (input) {\n return /^(днÑ|вечера)$/.test(input);\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'ночи';\n } else if (hour < 12) {\n return 'утра';\n } else if (hour < 17) {\n return 'днÑ';\n } else {\n return 'вечера';\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(й|го|Ñ)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'M':\n case 'd':\n case 'DDD':\n return number + '-й';\n case 'D':\n return number + '-го';\n case 'w':\n case 'W':\n return number + '-Ñ';\n default:\n return number;\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return ru;\n\n})));\n","//! moment.js locale configuration\n//! locale : Mongolian [mn]\n//! author : Javkhlantugs Nyamdorj : https://github.com/javkhaanj7\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function translate(number, withoutSuffix, key, isFuture) {\n switch (key) {\n case 's':\n return withoutSuffix ? 'Ñ…ÑдхÑн Ñекунд' : 'Ñ…ÑдхÑн Ñекундын';\n case 'ss':\n return number + (withoutSuffix ? ' Ñекунд' : ' Ñекундын');\n case 'm':\n case 'mm':\n return number + (withoutSuffix ? ' минут' : ' минутын');\n case 'h':\n case 'hh':\n return number + (withoutSuffix ? ' цаг' : ' цагийн');\n case 'd':\n case 'dd':\n return number + (withoutSuffix ? ' өдөр' : ' өдрийн');\n case 'M':\n case 'MM':\n return number + (withoutSuffix ? ' Ñар' : ' Ñарын');\n case 'y':\n case 'yy':\n return number + (withoutSuffix ? ' жил' : ' жилийн');\n default:\n return number;\n }\n }\n\n var mn = moment.defineLocale('mn', {\n months: 'ÐÑгдүгÑÑÑ€ Ñар_Хоёрдугаар Ñар_Гуравдугаар Ñар_ДөрөвдүгÑÑÑ€ Ñар_Тавдугаар Ñар_Зургадугаар Ñар_Долдугаар Ñар_Ðаймдугаар Ñар_ЕÑдүгÑÑÑ€ Ñар_Ðравдугаар Ñар_Ðрван нÑгдүгÑÑÑ€ Ñар_Ðрван хоёрдугаар Ñар'.split(\n '_'\n ),\n monthsShort:\n '1 Ñар_2 Ñар_3 Ñар_4 Ñар_5 Ñар_6 Ñар_7 Ñар_8 Ñар_9 Ñар_10 Ñар_11 Ñар_12 Ñар'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'ÐÑм_Даваа_ÐœÑгмар_Лхагва_ПүрÑв_БааÑан_БÑмба'.split('_'),\n weekdaysShort: 'ÐÑм_Дав_ÐœÑг_Лха_Пүр_Баа_БÑм'.split('_'),\n weekdaysMin: 'ÐÑ_Да_ÐœÑ_Лх_Пү_Ба_БÑ'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY-MM-DD',\n LL: 'YYYY оны MMMMын D',\n LLL: 'YYYY оны MMMMын D HH:mm',\n LLLL: 'dddd, YYYY оны MMMMын D HH:mm',\n },\n meridiemParse: /Ò®Ó¨|ҮХ/i,\n isPM: function (input) {\n return input === 'ҮХ';\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'Ò®Ó¨';\n } else {\n return 'ҮХ';\n }\n },\n calendar: {\n sameDay: '[Өнөөдөр] LT',\n nextDay: '[Маргааш] LT',\n nextWeek: '[ИрÑÑ…] dddd LT',\n lastDay: '[Өчигдөр] LT',\n lastWeek: '[ӨнгөрÑөн] dddd LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s дараа',\n past: '%s өмнө',\n s: translate,\n ss: translate,\n m: translate,\n mm: translate,\n h: translate,\n hh: translate,\n d: translate,\n dd: translate,\n M: translate,\n MM: translate,\n y: translate,\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2} өдөр/,\n ordinal: function (number, period) {\n switch (period) {\n case 'd':\n case 'D':\n case 'DDD':\n return number + ' өдөр';\n default:\n return number;\n }\n },\n });\n\n return mn;\n\n})));\n","//! moment.js locale configuration\n//! locale : Kyrgyz [ky]\n//! author : Chyngyz Arystan uulu : https://github.com/chyngyz\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var suffixes = {\n 0: '-чү',\n 1: '-чи',\n 2: '-чи',\n 3: '-чү',\n 4: '-чү',\n 5: '-чи',\n 6: '-чы',\n 7: '-чи',\n 8: '-чи',\n 9: '-чу',\n 10: '-чу',\n 20: '-чы',\n 30: '-чу',\n 40: '-чы',\n 50: '-чү',\n 60: '-чы',\n 70: '-чи',\n 80: '-чи',\n 90: '-чу',\n 100: '-чү',\n };\n\n var ky = moment.defineLocale('ky', {\n months: 'Ñнварь_февраль_март_апрель_май_июнь_июль_авгуÑÑ‚_ÑентÑбрь_октÑбрь_ноÑбрь_декабрь'.split(\n '_'\n ),\n monthsShort: 'Ñнв_фев_март_апр_май_июнь_июль_авг_Ñен_окт_ноÑ_дек'.split(\n '_'\n ),\n weekdays: 'Жекшемби_Дүйшөмбү_Шейшемби_Шаршемби_Бейшемби_Жума_Ишемби'.split(\n '_'\n ),\n weekdaysShort: 'Жек_Дүй_Шей_Шар_Бей_Жум_Ише'.split('_'),\n weekdaysMin: 'Жк_Дй_Шй_Шр_Бй_Жм_Иш'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Бүгүн Ñаат] LT',\n nextDay: '[Ðртең Ñаат] LT',\n nextWeek: 'dddd [Ñаат] LT',\n lastDay: '[КечÑÑ Ñаат] LT',\n lastWeek: '[Өткөн аптанын] dddd [күнү] [Ñаат] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s ичинде',\n past: '%s мурун',\n s: 'бирнече Ñекунд',\n ss: '%d Ñекунд',\n m: 'бир мүнөт',\n mm: '%d мүнөт',\n h: 'бир Ñаат',\n hh: '%d Ñаат',\n d: 'бир күн',\n dd: '%d күн',\n M: 'бир ай',\n MM: '%d ай',\n y: 'бир жыл',\n yy: '%d жыл',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(чи|чы|чү|чу)/,\n ordinal: function (number) {\n var a = number % 10,\n b = number >= 100 ? 100 : null;\n return number + (suffixes[number] || suffixes[a] || suffixes[b]);\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return ky;\n\n})));\n","//! moment.js locale configuration\n//! locale : Bengali (Bangladesh) [bn-bd]\n//! author : Asraf Hossain Patoary : https://github.com/ashwoolford\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '১',\n 2: '২',\n 3: '৩',\n 4: '৪',\n 5: '৫',\n 6: '৬',\n 7: 'à§',\n 8: '৮',\n 9: '৯',\n 0: '০',\n },\n numberMap = {\n '১': '1',\n '২': '2',\n '৩': '3',\n '৪': '4',\n '৫': '5',\n '৬': '6',\n 'à§': '7',\n '৮': '8',\n '৯': '9',\n '০': '0',\n };\n\n var bnBd = moment.defineLocale('bn-bd', {\n months: 'জানà§à§Ÿà¦¾à¦°à¦¿_ফেবà§à¦°à§à§Ÿà¦¾à¦°à¦¿_মারà§à¦š_à¦à¦ªà§à¦°à¦¿à¦²_মে_জà§à¦¨_জà§à¦²à¦¾à¦‡_আগসà§à¦Ÿ_সেপà§à¦Ÿà§‡à¦®à§à¦¬à¦°_অকà§à¦Ÿà§‹à¦¬à¦°_নà¦à§‡à¦®à§à¦¬à¦°_ডিসেমà§à¦¬à¦°'.split(\n '_'\n ),\n monthsShort:\n 'জানà§_ফেবà§à¦°à§_মারà§à¦š_à¦à¦ªà§à¦°à¦¿à¦²_মে_জà§à¦¨_জà§à¦²à¦¾à¦‡_আগসà§à¦Ÿ_সেপà§à¦Ÿ_অকà§à¦Ÿà§‹_নà¦à§‡_ডিসে'.split(\n '_'\n ),\n weekdays: 'রবিবার_সোমবার_মঙà§à¦—লবার_বà§à¦§à¦¬à¦¾à¦°_বৃহসà§à¦ªà¦¤à¦¿à¦¬à¦¾à¦°_শà§à¦•à§à¦°à¦¬à¦¾à¦°_শনিবার'.split(\n '_'\n ),\n weekdaysShort: 'রবি_সোম_মঙà§à¦—ল_বà§à¦§_বৃহসà§à¦ªà¦¤à¦¿_শà§à¦•à§à¦°_শনি'.split('_'),\n weekdaysMin: 'রবি_সোম_মঙà§à¦—ল_বà§à¦§_বৃহ_শà§à¦•à§à¦°_শনি'.split('_'),\n longDateFormat: {\n LT: 'A h:mm সময়',\n LTS: 'A h:mm:ss সময়',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm সময়',\n LLLL: 'dddd, D MMMM YYYY, A h:mm সময়',\n },\n calendar: {\n sameDay: '[আজ] LT',\n nextDay: '[আগামীকাল] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[গতকাল] LT',\n lastWeek: '[গত] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s পরে',\n past: '%s আগে',\n s: 'কয়েক সেকেনà§à¦¡',\n ss: '%d সেকেনà§à¦¡',\n m: 'à¦à¦• মিনিট',\n mm: '%d মিনিট',\n h: 'à¦à¦• ঘনà§à¦Ÿà¦¾',\n hh: '%d ঘনà§à¦Ÿà¦¾',\n d: 'à¦à¦• দিন',\n dd: '%d দিন',\n M: 'à¦à¦• মাস',\n MM: '%d মাস',\n y: 'à¦à¦• বছর',\n yy: '%d বছর',\n },\n preparse: function (string) {\n return string.replace(/[১২৩৪৫৬à§à§®à§¯à§¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n\n meridiemParse: /রাত|à¦à§‹à¦°|সকাল|দà§à¦ªà§à¦°|বিকাল|সনà§à¦§à§à¦¯à¦¾|রাত/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'রাত') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'à¦à§‹à¦°') {\n return hour;\n } else if (meridiem === 'সকাল') {\n return hour;\n } else if (meridiem === 'দà§à¦ªà§à¦°') {\n return hour >= 3 ? hour : hour + 12;\n } else if (meridiem === 'বিকাল') {\n return hour + 12;\n } else if (meridiem === 'সনà§à¦§à§à¦¯à¦¾') {\n return hour + 12;\n }\n },\n\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'রাত';\n } else if (hour < 6) {\n return 'à¦à§‹à¦°';\n } else if (hour < 12) {\n return 'সকাল';\n } else if (hour < 15) {\n return 'দà§à¦ªà§à¦°';\n } else if (hour < 18) {\n return 'বিকাল';\n } else if (hour < 20) {\n return 'সনà§à¦§à§à¦¯à¦¾';\n } else {\n return 'রাত';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return bnBd;\n\n})));\n","//! moment.js locale configuration\n//! locale : Romanian [ro]\n//! author : Vlad Gurdiga : https://github.com/gurdiga\n//! author : Valentin Agachi : https://github.com/avaly\n//! author : Emanuel Cepoi : https://github.com/cepem\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function relativeTimeWithPlural(number, withoutSuffix, key) {\n var format = {\n ss: 'secunde',\n mm: 'minute',\n hh: 'ore',\n dd: 'zile',\n ww: 'săptămâni',\n MM: 'luni',\n yy: 'ani',\n },\n separator = ' ';\n if (number % 100 >= 20 || (number >= 100 && number % 100 === 0)) {\n separator = ' de ';\n }\n return number + separator + format[key];\n }\n\n var ro = moment.defineLocale('ro', {\n months: 'ianuarie_februarie_martie_aprilie_mai_iunie_iulie_august_septembrie_octombrie_noiembrie_decembrie'.split(\n '_'\n ),\n monthsShort:\n 'ian._feb._mart._apr._mai_iun._iul._aug._sept._oct._nov._dec.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'duminică_luni_marÈ›i_miercuri_joi_vineri_sâmbătă'.split('_'),\n weekdaysShort: 'Dum_Lun_Mar_Mie_Joi_Vin_Sâm'.split('_'),\n weekdaysMin: 'Du_Lu_Ma_Mi_Jo_Vi_Sâ'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY H:mm',\n LLLL: 'dddd, D MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[azi la] LT',\n nextDay: '[mâine la] LT',\n nextWeek: 'dddd [la] LT',\n lastDay: '[ieri la] LT',\n lastWeek: '[fosta] dddd [la] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'peste %s',\n past: '%s în urmă',\n s: 'câteva secunde',\n ss: relativeTimeWithPlural,\n m: 'un minut',\n mm: relativeTimeWithPlural,\n h: 'o oră',\n hh: relativeTimeWithPlural,\n d: 'o zi',\n dd: relativeTimeWithPlural,\n w: 'o săptămână',\n ww: relativeTimeWithPlural,\n M: 'o lună',\n MM: relativeTimeWithPlural,\n y: 'un an',\n yy: relativeTimeWithPlural,\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return ro;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Touch, Component, EventHandler, selectAll, getUniqueID, removeClass } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges, Property, Browser, detach, createElement as buildTag } from '@syncfusion/ej2-base';\nimport { classList, isNullOrUndefined } from '@syncfusion/ej2-base';\nvar CLS_ROOT = 'e-vscroll';\nvar CLS_RTL = 'e-rtl';\nvar CLS_DISABLE = 'e-overlay';\nvar CLS_VSCROLLBAR = 'e-vscroll-bar';\nvar CLS_VSCROLLCON = 'e-vscroll-content';\nvar CLS_NAVARROW = 'e-nav-arrow';\nvar CLS_NAVUPARROW = 'e-nav-up-arrow';\nvar CLS_NAVDOWNARROW = 'e-nav-down-arrow';\nvar CLS_VSCROLLNAV = 'e-scroll-nav';\nvar CLS_VSCROLLNAVUP = 'e-scroll-up-nav';\nvar CLS_VSCROLLNAVDOWN = 'e-scroll-down-nav';\nvar CLS_DEVICE = 'e-scroll-device';\nvar CLS_OVERLAY = 'e-scroll-overlay';\nvar CLS_UPOVERLAY = 'e-scroll-up-overlay';\nvar CLS_DOWNOVERLAY = 'e-scroll-down-overlay';\nvar OVERLAY_MAXWID = 40;\n/**\n * VScroll module is introduces vertical scroller when content exceeds the current viewing area.\n * It can be useful for the components like Toolbar, Tab which needs vertical scrolling alone.\n * Hidden content can be view by touch moving or icon click.\n * ```html\n * <div id=\"scroll\"/>\n * <script>\n * var scrollObj = new VScroll();\n * scrollObj.appendTo(\"#scroll\");\n * </script>\n * ```\n */\nvar VScroll = /** @class */ (function (_super) {\n __extends(VScroll, _super);\n /**\n * Initializes a new instance of the VScroll class.\n *\n * @param {VScrollModel} options - Specifies VScroll model properties as options.\n * @param {string | HTMLElement} element - Specifies the element for which vertical scrolling applies.\n */\n function VScroll(options, element) {\n return _super.call(this, options, element) || this;\n }\n /**\n * Initialize the event handler\n *\n * @private\n * @returns {void}\n */\n VScroll.prototype.preRender = function () {\n this.browser = Browser.info.name;\n this.browserCheck = this.browser === 'mozilla';\n this.isDevice = Browser.isDevice;\n this.customStep = true;\n var ele = this.element;\n this.ieCheck = this.browser === 'edge' || this.browser === 'msie';\n this.initialize();\n if (ele.id === '') {\n ele.id = getUniqueID('vscroll');\n this.uniqueId = true;\n }\n ele.style.display = 'block';\n if (this.enableRtl) {\n ele.classList.add(CLS_RTL);\n }\n };\n /**\n * To Initialize the vertical scroll rendering\n *\n * @private\n * @returns {void}\n */\n VScroll.prototype.render = function () {\n this.touchModule = new Touch(this.element, { scroll: this.touchHandler.bind(this), swipe: this.swipeHandler.bind(this) });\n EventHandler.add(this.scrollEle, 'scroll', this.scrollEventHandler, this);\n if (!this.isDevice) {\n this.createNavIcon(this.element);\n }\n else {\n this.element.classList.add(CLS_DEVICE);\n this.createOverlayElement(this.element);\n }\n this.setScrollState();\n EventHandler.add(this.element, 'wheel', this.wheelEventHandler, this);\n };\n VScroll.prototype.setScrollState = function () {\n if (isNullOrUndefined(this.scrollStep) || this.scrollStep < 0) {\n this.scrollStep = this.scrollEle.offsetHeight;\n this.customStep = false;\n }\n else {\n this.customStep = true;\n }\n };\n VScroll.prototype.initialize = function () {\n var scrollCnt = buildTag('div', { className: CLS_VSCROLLCON });\n var scrollBar = buildTag('div', { className: CLS_VSCROLLBAR });\n scrollBar.setAttribute('tabindex', '-1');\n var ele = this.element;\n var innerEle = [].slice.call(ele.children);\n for (var _i = 0, innerEle_1 = innerEle; _i < innerEle_1.length; _i++) {\n var ele_1 = innerEle_1[_i];\n scrollCnt.appendChild(ele_1);\n }\n scrollBar.appendChild(scrollCnt);\n ele.appendChild(scrollBar);\n scrollBar.style.overflow = 'hidden';\n this.scrollEle = scrollBar;\n this.scrollItems = scrollCnt;\n };\n VScroll.prototype.getPersistData = function () {\n var keyEntity = ['scrollStep'];\n return this.addOnPersist(keyEntity);\n };\n /**\n * Returns the current module name.\n *\n * @returns {string} - It returns the current module name.\n * @private\n */\n VScroll.prototype.getModuleName = function () {\n return 'vScroll';\n };\n /**\n * Removes the control from the DOM and also removes all its related events.\n *\n * @returns {void}\n */\n VScroll.prototype.destroy = function () {\n var el = this.element;\n el.style.display = '';\n removeClass([this.element], [CLS_ROOT, CLS_DEVICE, CLS_RTL]);\n var navs = selectAll('.e-' + el.id + '_nav.' + CLS_VSCROLLNAV, el);\n var overlays = selectAll('.' + CLS_OVERLAY, el);\n [].slice.call(overlays).forEach(function (ele) {\n detach(ele);\n });\n for (var _i = 0, _a = [].slice.call(this.scrollItems.children); _i < _a.length; _i++) {\n var elem = _a[_i];\n el.appendChild(elem);\n }\n if (this.uniqueId) {\n this.element.removeAttribute('id');\n }\n detach(this.scrollEle);\n if (navs.length > 0) {\n detach(navs[0]);\n if (!isNullOrUndefined(navs[1])) {\n detach(navs[1]);\n }\n }\n EventHandler.remove(this.scrollEle, 'scroll', this.scrollEventHandler);\n this.touchModule.destroy();\n this.touchModule = null;\n _super.prototype.destroy.call(this);\n };\n /**\n * Specifies the value to disable/enable the VScroll component.\n * When set to `true` , the component will be disabled.\n *\n * @param {boolean} value - Based on this Boolean value, VScroll will be enabled (false) or disabled (true).\n * @returns {void}.\n */\n VScroll.prototype.disable = function (value) {\n var navEle = selectAll('.e-scroll-nav:not(.' + CLS_DISABLE + ')', this.element);\n if (value) {\n this.element.classList.add(CLS_DISABLE);\n }\n else {\n this.element.classList.remove(CLS_DISABLE);\n }\n [].slice.call(navEle).forEach(function (el) {\n el.setAttribute('tabindex', !value ? '0' : '-1');\n });\n };\n VScroll.prototype.createOverlayElement = function (element) {\n var id = element.id.concat('_nav');\n var downOverlayEle = buildTag('div', { className: CLS_OVERLAY + ' ' + CLS_DOWNOVERLAY });\n var clsDown = 'e-' + element.id.concat('_nav ' + CLS_VSCROLLNAV + ' ' + CLS_VSCROLLNAVDOWN);\n var downEle = buildTag('div', { id: id.concat('down'), className: clsDown });\n var navItem = buildTag('div', { className: CLS_NAVDOWNARROW + ' ' + CLS_NAVARROW + ' e-icons' });\n downEle.appendChild(navItem);\n var upEle = buildTag('div', { className: CLS_OVERLAY + ' ' + CLS_UPOVERLAY });\n if (this.ieCheck) {\n downEle.classList.add('e-ie-align');\n }\n element.appendChild(downOverlayEle);\n element.appendChild(downEle);\n element.insertBefore(upEle, element.firstChild);\n this.eventBinding([downEle]);\n };\n VScroll.prototype.createNavIcon = function (element) {\n var id = element.id.concat('_nav');\n var clsDown = 'e-' + element.id.concat('_nav ' + CLS_VSCROLLNAV + ' ' + CLS_VSCROLLNAVDOWN);\n var nav = buildTag('div', { id: id.concat('_down'), className: clsDown });\n nav.setAttribute('aria-disabled', 'false');\n var navItem = buildTag('div', { className: CLS_NAVDOWNARROW + ' ' + CLS_NAVARROW + ' e-icons' });\n var clsUp = 'e-' + element.id.concat('_nav ' + CLS_VSCROLLNAV + ' ' + CLS_VSCROLLNAVUP);\n var navElement = buildTag('div', { id: id.concat('_up'), className: clsUp + ' ' + CLS_DISABLE });\n navElement.setAttribute('aria-disabled', 'true');\n var navUpItem = buildTag('div', { className: CLS_NAVUPARROW + ' ' + CLS_NAVARROW + ' e-icons' });\n navElement.appendChild(navUpItem);\n nav.appendChild(navItem);\n nav.setAttribute('tabindex', '0');\n element.appendChild(nav);\n element.insertBefore(navElement, element.firstChild);\n if (this.ieCheck) {\n nav.classList.add('e-ie-align');\n navElement.classList.add('e-ie-align');\n }\n this.eventBinding([nav, navElement]);\n };\n VScroll.prototype.onKeyPress = function (ev) {\n var _this = this;\n if (ev.key === 'Enter') {\n var timeoutFun_1 = function () {\n _this.keyTimeout = true;\n _this.eleScrolling(10, ev.target, true);\n };\n this.keyTimer = window.setTimeout(function () {\n timeoutFun_1();\n }, 100);\n }\n };\n VScroll.prototype.onKeyUp = function (ev) {\n if (ev.key !== 'Enter') {\n return;\n }\n if (this.keyTimeout) {\n this.keyTimeout = false;\n }\n else {\n ev.target.click();\n }\n clearTimeout(this.keyTimer);\n };\n VScroll.prototype.eventBinding = function (element) {\n var _this = this;\n [].slice.call(element).forEach(function (ele) {\n new Touch(ele, { tapHold: _this.tabHoldHandler.bind(_this), tapHoldThreshold: 500 });\n ele.addEventListener('keydown', _this.onKeyPress.bind(_this));\n ele.addEventListener('keyup', _this.onKeyUp.bind(_this));\n ele.addEventListener('mouseup', _this.repeatScroll.bind(_this));\n ele.addEventListener('touchend', _this.repeatScroll.bind(_this));\n ele.addEventListener('contextmenu', function (e) {\n e.preventDefault();\n });\n EventHandler.add(ele, 'click', _this.clickEventHandler, _this);\n });\n };\n VScroll.prototype.repeatScroll = function () {\n clearInterval(this.timeout);\n };\n VScroll.prototype.tabHoldHandler = function (ev) {\n var _this = this;\n var trgt = ev.originalEvent.target;\n trgt = this.contains(trgt, CLS_VSCROLLNAV) ? trgt.firstElementChild : trgt;\n var scrollDistance = 10;\n var timeoutFun = function () {\n _this.eleScrolling(scrollDistance, trgt, true);\n };\n this.timeout = window.setInterval(function () {\n timeoutFun();\n }, 50);\n };\n VScroll.prototype.contains = function (element, className) {\n return element.classList.contains(className);\n };\n VScroll.prototype.eleScrolling = function (scrollDis, trgt, isContinuous) {\n var classList = trgt.classList;\n if (classList.contains(CLS_VSCROLLNAV)) {\n classList = trgt.querySelector('.' + CLS_NAVARROW).classList;\n }\n if (classList.contains(CLS_NAVDOWNARROW)) {\n this.frameScrollRequest(scrollDis, 'add', isContinuous);\n }\n else if (classList.contains(CLS_NAVUPARROW)) {\n this.frameScrollRequest(scrollDis, '', isContinuous);\n }\n };\n VScroll.prototype.clickEventHandler = function (event) {\n this.eleScrolling(this.scrollStep, event.target, false);\n };\n VScroll.prototype.wheelEventHandler = function (e) {\n e.preventDefault();\n this.frameScrollRequest(this.scrollStep, (e.deltaY > 0 ? 'add' : ''), false);\n };\n VScroll.prototype.swipeHandler = function (e) {\n var swipeElement = this.scrollEle;\n var distance;\n if (e.velocity <= 1) {\n distance = e.distanceY / (e.velocity * 10);\n }\n else {\n distance = e.distanceY / e.velocity;\n }\n var start = 0.5;\n var animate = function () {\n var step = Math.sin(start);\n if (step <= 0) {\n window.cancelAnimationFrame(step);\n }\n else {\n if (e.swipeDirection === 'Up') {\n swipeElement.scrollTop += distance * step;\n }\n else if (e.swipeDirection === 'Down') {\n swipeElement.scrollTop -= distance * step;\n }\n start -= 0.02;\n window.requestAnimationFrame(animate);\n }\n };\n animate();\n };\n VScroll.prototype.scrollUpdating = function (scrollVal, action) {\n if (action === 'add') {\n this.scrollEle.scrollTop += scrollVal;\n }\n else {\n this.scrollEle.scrollTop -= scrollVal;\n }\n };\n VScroll.prototype.frameScrollRequest = function (scrollValue, action, isContinuous) {\n var _this = this;\n var step = 10;\n if (isContinuous) {\n this.scrollUpdating(scrollValue, action);\n return;\n }\n if (!this.customStep) {\n [].slice.call(selectAll('.' + CLS_OVERLAY, this.element)).forEach(function (el) {\n scrollValue -= el.offsetHeight;\n });\n }\n var animate = function () {\n if (scrollValue < step) {\n window.cancelAnimationFrame(step);\n }\n else {\n _this.scrollUpdating(step, action);\n scrollValue -= step;\n window.requestAnimationFrame(animate);\n }\n };\n animate();\n };\n VScroll.prototype.touchHandler = function (e) {\n var el = this.scrollEle;\n var distance = e.distanceY;\n if (e.scrollDirection === 'Up') {\n el.scrollTop = el.scrollTop + distance;\n }\n else if (e.scrollDirection === 'Down') {\n el.scrollTop = el.scrollTop - distance;\n }\n };\n VScroll.prototype.arrowDisabling = function (addDisableCls, removeDisableCls) {\n if (this.isDevice) {\n var arrowEle = isNullOrUndefined(addDisableCls) ? removeDisableCls : addDisableCls;\n var arrowIcon = arrowEle.querySelector('.' + CLS_NAVARROW);\n if (isNullOrUndefined(addDisableCls)) {\n classList(arrowIcon, [CLS_NAVDOWNARROW], [CLS_NAVUPARROW]);\n }\n else {\n classList(arrowIcon, [CLS_NAVUPARROW], [CLS_NAVDOWNARROW]);\n }\n }\n else {\n addDisableCls.classList.add(CLS_DISABLE);\n addDisableCls.setAttribute('aria-disabled', 'true');\n addDisableCls.removeAttribute('tabindex');\n removeDisableCls.classList.remove(CLS_DISABLE);\n removeDisableCls.setAttribute('aria-disabled', 'false');\n removeDisableCls.setAttribute('tabindex', '0');\n }\n this.repeatScroll();\n };\n VScroll.prototype.scrollEventHandler = function (e) {\n var target = e.target;\n var height = target.offsetHeight;\n var navUpEle = this.element.querySelector('.' + CLS_VSCROLLNAVUP);\n var navDownEle = this.element.querySelector('.' + CLS_VSCROLLNAVDOWN);\n var upOverlay = this.element.querySelector('.' + CLS_UPOVERLAY);\n var downOverlay = this.element.querySelector('.' + CLS_DOWNOVERLAY);\n var scrollTop = target.scrollTop;\n if (scrollTop <= 0) {\n scrollTop = -scrollTop;\n }\n if (this.isDevice) {\n if (scrollTop < OVERLAY_MAXWID) {\n upOverlay.style.height = scrollTop + 'px';\n }\n else {\n upOverlay.style.height = '40px';\n }\n if ((target.scrollHeight - Math.ceil(height + scrollTop)) < OVERLAY_MAXWID) {\n downOverlay.style.height = (target.scrollHeight - Math.ceil(height + scrollTop)) + 'px';\n }\n else {\n downOverlay.style.height = '40px';\n }\n }\n if (scrollTop === 0) {\n this.arrowDisabling(navUpEle, navDownEle);\n }\n else if (Math.ceil(height + scrollTop + .1) >= target.scrollHeight) {\n this.arrowDisabling(navDownEle, navUpEle);\n }\n else {\n var disEle = this.element.querySelector('.' + CLS_VSCROLLNAV + '.' + CLS_DISABLE);\n if (disEle) {\n disEle.classList.remove(CLS_DISABLE);\n disEle.setAttribute('aria-disabled', 'false');\n disEle.setAttribute('tabindex', '0');\n }\n }\n };\n /**\n * Gets called when the model property changes.The data that describes the old and new values of property that changed.\n *\n * @param {VScrollModel} newProp - It contains the new value of data.\n * @param {VScrollModel} oldProp - It contains the old value of data.\n * @returns {void}\n * @private\n */\n VScroll.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'scrollStep':\n this.setScrollState();\n break;\n case 'enableRtl':\n if (newProp.enableRtl) {\n this.element.classList.add(CLS_RTL);\n }\n else {\n this.element.classList.remove(CLS_RTL);\n }\n break;\n }\n }\n };\n __decorate([\n Property(null)\n ], VScroll.prototype, \"scrollStep\", void 0);\n VScroll = __decorate([\n NotifyPropertyChanges\n ], VScroll);\n return VScroll;\n}(Component));\nexport { VScroll };\n","//! moment.js locale configuration\n//! locale : Welsh [cy]\n//! author : Robert Allen : https://github.com/robgallen\n//! author : https://github.com/ryangreaves\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var cy = moment.defineLocale('cy', {\n months: 'Ionawr_Chwefror_Mawrth_Ebrill_Mai_Mehefin_Gorffennaf_Awst_Medi_Hydref_Tachwedd_Rhagfyr'.split(\n '_'\n ),\n monthsShort: 'Ion_Chwe_Maw_Ebr_Mai_Meh_Gor_Aws_Med_Hyd_Tach_Rhag'.split(\n '_'\n ),\n weekdays:\n 'Dydd Sul_Dydd Llun_Dydd Mawrth_Dydd Mercher_Dydd Iau_Dydd Gwener_Dydd Sadwrn'.split(\n '_'\n ),\n weekdaysShort: 'Sul_Llun_Maw_Mer_Iau_Gwe_Sad'.split('_'),\n weekdaysMin: 'Su_Ll_Ma_Me_Ia_Gw_Sa'.split('_'),\n weekdaysParseExact: true,\n // time formats are the same as en-gb\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Heddiw am] LT',\n nextDay: '[Yfory am] LT',\n nextWeek: 'dddd [am] LT',\n lastDay: '[Ddoe am] LT',\n lastWeek: 'dddd [diwethaf am] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'mewn %s',\n past: '%s yn ôl',\n s: 'ychydig eiliadau',\n ss: '%d eiliad',\n m: 'munud',\n mm: '%d munud',\n h: 'awr',\n hh: '%d awr',\n d: 'diwrnod',\n dd: '%d diwrnod',\n M: 'mis',\n MM: '%d mis',\n y: 'blwyddyn',\n yy: '%d flynedd',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(fed|ain|af|il|ydd|ed|eg)/,\n // traditional ordinal numbers above 31 are not commonly used in colloquial Welsh\n ordinal: function (number) {\n var b = number,\n output = '',\n lookup = [\n '',\n 'af',\n 'il',\n 'ydd',\n 'ydd',\n 'ed',\n 'ed',\n 'ed',\n 'fed',\n 'fed',\n 'fed', // 1af to 10fed\n 'eg',\n 'fed',\n 'eg',\n 'eg',\n 'fed',\n 'eg',\n 'eg',\n 'fed',\n 'eg',\n 'fed', // 11eg to 20fed\n ];\n if (b > 20) {\n if (b === 40 || b === 50 || b === 60 || b === 80 || b === 100) {\n output = 'fed'; // not 30ain, 70ain or 90ain\n } else {\n output = 'ain';\n }\n } else if (b > 0) {\n output = lookup[b];\n }\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return cy;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { selectAll, select, createElement, Base, detach } from '@syncfusion/ej2-base';\nimport { extend, isNullOrUndefined, EventHandler } from '@syncfusion/ej2-base';\nimport { Property, NotifyPropertyChanges, Event, onIntlChange } from '@syncfusion/ej2-base';\nimport { Internationalization, L10n } from '@syncfusion/ej2-base';\n/**\n * global declarations\n */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport var regex = {\n /* eslint-disable no-useless-escape */\n EMAIL: new RegExp('^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}' +\n '|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$'),\n /* eslint-disable-next-line security/detect-unsafe-regex */\n URL: /^(?:http(s)?:\\/\\/)?[\\w.-]+(?:\\.[\\w\\.-]+)+[\\w\\-\\._~:/?#[\\]@!\\$&'\\(\\)\\*\\+,;=.]+$/m,\n DATE_ISO: new RegExp('^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$'),\n DIGITS: new RegExp('^[0-9]*$'),\n PHONE: new RegExp('^[+]?[0-9]{9,13}$'),\n CREDITCARD: new RegExp('^\\\\d{13,16}$')\n /* eslint-enable no-useless-escape */\n};\n/**\n * ErrorOption values\n *\n * @private\n */\nexport var ErrorOption;\n(function (ErrorOption) {\n /**\n * Defines the error message.\n */\n ErrorOption[ErrorOption[\"Message\"] = 0] = \"Message\";\n /**\n * Defines the error element type.\n */\n ErrorOption[ErrorOption[\"Label\"] = 1] = \"Label\";\n})(ErrorOption || (ErrorOption = {}));\n/**\n * FormValidator class enables you to validate the form fields based on your defined rules\n * ```html\n * <form id='formId'>\n * <input type='text' name='Name' />\n * <input type='text' name='Age' />\n * </form>\n * <script>\n * let formObject = new FormValidator('#formId', {\n * rules: { Name: { required: true }, Age: { range: [18, 30] } };\n * });\n * formObject.validate();\n * </script>\n * ```\n */\nvar FormValidator = /** @class */ (function (_super) {\n __extends(FormValidator, _super);\n /**\n * Initializes the FormValidator.\n *\n * @param {string | HTMLFormElement} element - Specifies the element to render as component.\n * @param {FormValidatorModel} options - Specifies the FormValidator model.\n * @private\n */\n function FormValidator(element, options) {\n var _this = _super.call(this, options, element) || this;\n _this.validated = [];\n _this.errorRules = [];\n _this.allowSubmit = false;\n _this.required = 'required';\n _this.infoElement = null;\n _this.inputElement = null;\n _this.selectQuery = 'input:not([type=reset]):not([type=button]), select, textarea';\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n _this.localyMessage = {};\n /**\n * Specifies the default messages for validation rules.\n *\n * @default { List of validation message }\n */\n _this.defaultMessages = {\n required: 'This field is required.',\n email: 'Please enter a valid email address.',\n url: 'Please enter a valid URL.',\n date: 'Please enter a valid date.',\n dateIso: 'Please enter a valid date ( ISO ).',\n creditcard: 'Please enter valid card number',\n number: 'Please enter a valid number.',\n digits: 'Please enter only digits.',\n maxLength: 'Please enter no more than {0} characters.',\n minLength: 'Please enter at least {0} characters.',\n rangeLength: 'Please enter a value between {0} and {1} characters long.',\n range: 'Please enter a value between {0} and {1}.',\n max: 'Please enter a value less than or equal to {0}.',\n min: 'Please enter a value greater than or equal to {0}.',\n regex: 'Please enter a correct value.',\n tel: 'Please enter a valid phone number.',\n pattern: 'Please enter a correct pattern value.',\n equalTo: 'Please enter the valid match text'\n };\n if (typeof _this.rules === 'undefined') {\n _this.rules = {};\n }\n _this.l10n = new L10n('formValidator', _this.defaultMessages, _this.locale);\n if (_this.locale) {\n _this.localeFunc();\n }\n onIntlChange.on('notifyExternalChange', _this.afterLocalization, _this);\n element = typeof element === 'string' ? select(element, document) : element;\n // Set novalidate to prevent default HTML5 form validation\n if (_this.element != null) {\n _this.element.setAttribute('novalidate', '');\n _this.inputElements = selectAll(_this.selectQuery, _this.element);\n _this.createHTML5Rules();\n _this.wireEvents();\n }\n else {\n return undefined;\n }\n return _this;\n }\n FormValidator_1 = FormValidator;\n /* eslint-enable @typescript-eslint/no-explicit-any */\n /**\n * Add validation rules to the corresponding input element based on `name` attribute.\n *\n * @param {string} name `name` of form field.\n * @param {Object} rules Validation rules for the corresponding element.\n * @returns {void}\n */\n FormValidator.prototype.addRules = function (name, rules) {\n if (name) {\n // eslint-disable-next-line no-prototype-builtins\n if (this.rules.hasOwnProperty(name)) {\n extend(this.rules[\"\" + name], rules, {});\n }\n else {\n this.rules[\"\" + name] = rules;\n }\n }\n };\n /**\n * Remove validation to the corresponding field based on name attribute.\n * When no parameter is passed, remove all the validations in the form.\n *\n * @param {string} name Input name attribute value.\n * @param {string[]} rules List of validation rules need to be remove from the corresponding element.\n * @returns {void}\n */\n FormValidator.prototype.removeRules = function (name, rules) {\n if (!name && !rules) {\n this.rules = {};\n }\n else if (this.rules[\"\" + name] && !rules) {\n delete this.rules[\"\" + name];\n }\n else if (!isNullOrUndefined(this.rules[\"\" + name] && rules)) {\n for (var i = 0; i < rules.length; i++) {\n delete this.rules[\"\" + name][rules[parseInt(i.toString())]];\n }\n }\n else {\n return;\n }\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Validate the current form values using defined rules.\n * Returns `true` when the form is valid otherwise `false`\n *\n * @param {string} selected - Optional parameter to validate specified element.\n * @returns {boolean}\n */\n FormValidator.prototype.validate = function (selected) {\n var rules = Object.keys(this.rules);\n if (selected && rules.length) {\n this.validateRules(selected);\n //filter the selected element it don't have any valid input element\n return rules.indexOf(selected) !== -1 && this.errorRules.filter(function (data) {\n return data.name === selected;\n }).length === 0;\n }\n else {\n this.errorRules = [];\n for (var _i = 0, rules_1 = rules; _i < rules_1.length; _i++) {\n var name_1 = rules_1[_i];\n this.validateRules(name_1);\n }\n return this.errorRules.length === 0;\n }\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Reset the value of all the fields in form.\n *\n * @returns {void}\n */\n FormValidator.prototype.reset = function () {\n this.element.reset();\n this.clearForm();\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Get input element by name.\n *\n * @param {string} name - Input element name attribute value.\n * @returns {HTMLInputElement}\n */\n FormValidator.prototype.getInputElement = function (name) {\n this.inputElement = (select('[name=\"' + name + '\"]', this.element));\n return this.inputElement;\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Destroy the form validator object and error elements.\n *\n * @returns {void}\n */\n FormValidator.prototype.destroy = function () {\n this.reset();\n this.unwireEvents();\n this.rules = {};\n var elements = selectAll('.' + this.errorClass + ', .' + this.validClass, this.element);\n for (var _i = 0, elements_1 = elements; _i < elements_1.length; _i++) {\n var element = elements_1[_i];\n detach(element);\n }\n _super.prototype.destroy.call(this);\n this.infoElement = null;\n onIntlChange.off('notifyExternalChange', this.afterLocalization);\n };\n /**\n * @param {FormValidatorModel} newProp - Returns the dynamic property value of the component.\n * @param {FormValidatorModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n * @private\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n FormValidator.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'locale':\n this.localeFunc();\n break;\n }\n }\n };\n /**\n * @private\n * @returns {void}\n */\n FormValidator.prototype.localeFunc = function () {\n for (var _i = 0, _a = Object.keys(this.defaultMessages); _i < _a.length; _i++) {\n var key = _a[_i];\n this.l10n.setLocale(this.locale);\n var value = this.l10n.getConstant(key);\n this.localyMessage[\"\" + key] = value;\n }\n };\n /**\n * @private\n * @returns {string} - Returns the component name.\n */\n FormValidator.prototype.getModuleName = function () {\n return 'formvalidator';\n };\n /**\n * @param {any} args - Specifies the culture name.\n * @private\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/explicit-module-boundary-types\n FormValidator.prototype.afterLocalization = function (args) {\n this.locale = args.locale;\n this.localeFunc();\n };\n /**\n * Allows you to refresh the form validator base events to the elements inside the form.\n *\n * @returns {void}\n */\n FormValidator.prototype.refresh = function () {\n this.unwireEvents();\n this.inputElements = selectAll(this.selectQuery, this.element);\n this.wireEvents();\n };\n FormValidator.prototype.clearForm = function () {\n this.errorRules = [];\n this.validated = [];\n var elements = selectAll(this.selectQuery, this.element);\n for (var _i = 0, elements_2 = elements; _i < elements_2.length; _i++) {\n var element = elements_2[_i];\n var input = element;\n input.removeAttribute('aria-invalid');\n var inputParent = input.parentElement;\n var grandParent = inputParent.parentElement;\n if (inputParent.classList.contains('e-control-wrapper') || inputParent.classList.contains('e-wrapper') || (input.classList.contains('e-input') && inputParent.classList.contains('e-input-group'))) {\n inputParent.classList.remove(this.errorClass);\n }\n else if ((grandParent != null) && (grandParent.classList.contains('e-control-wrapper') || grandParent.classList.contains('e-wrapper'))) {\n grandParent.classList.remove(this.errorClass);\n }\n else {\n input.classList.remove(this.errorClass);\n }\n if (input.name.length > 0) {\n this.getInputElement(input.name);\n this.getErrorElement(input.name);\n this.hideMessage(input.name);\n }\n if (inputParent.classList.contains('e-control-wrapper') || inputParent.classList.contains('e-wrapper') || (input.classList.contains('e-input') && inputParent.classList.contains('e-input-group'))) {\n inputParent.classList.remove(this.validClass);\n }\n else if ((grandParent != null) && (grandParent.classList.contains('e-control-wrapper') || grandParent.classList.contains('e-wrapper'))) {\n grandParent.classList.remove(this.validClass);\n }\n else {\n input.classList.remove(this.validClass);\n }\n }\n };\n FormValidator.prototype.createHTML5Rules = function () {\n var defRules = ['required', 'validateHidden', 'regex', 'rangeLength', 'maxLength', 'minLength', 'dateIso', 'digits',\n 'pattern', 'data-val-required', 'type', 'data-validation', 'min', 'max', 'range', 'equalTo', 'data-val-minlength-min',\n 'data-val-equalto-other', 'data-val-maxlength-max', 'data-val-range-min', 'data-val-regex-pattern', 'data-val-length-max',\n 'data-val-creditcard', 'data-val-phone'];\n var acceptedTypes = ['hidden', 'email', 'url', 'date', 'number', 'tel'];\n for (var _i = 0, _a = (this.inputElements); _i < _a.length; _i++) {\n var input = _a[_i];\n // Default attribute rules\n var allRule = {};\n for (var _b = 0, defRules_1 = defRules; _b < defRules_1.length; _b++) {\n var rule = defRules_1[_b];\n if (input.getAttribute(rule) !== null) {\n switch (rule) {\n case 'required':\n this.defRule(input, allRule, rule, input.required);\n break;\n case 'data-validation':\n rule = input.getAttribute(rule);\n this.defRule(input, allRule, rule, true);\n break;\n case 'type':\n if (acceptedTypes.indexOf(input.type) !== -1) {\n this.defRule(input, allRule, input.type, true);\n }\n break;\n case 'rangeLength':\n case 'range':\n this.defRule(input, allRule, rule, JSON.parse(input.getAttribute(rule)));\n break;\n case 'equalTo':\n {\n var id = input.getAttribute(rule);\n this.defRule(input, allRule, rule, id);\n }\n break;\n default:\n if (input.getAttribute('data-val') === 'true') {\n this.annotationRule(input, allRule, rule, input.getAttribute(rule));\n }\n else {\n this.defRule(input, allRule, rule, input.getAttribute(rule));\n }\n }\n }\n }\n //adding pattern type validation\n if (Object.keys(allRule).length !== 0) {\n this.addRules(input.name, allRule);\n }\n }\n };\n FormValidator.prototype.annotationRule = function (input, ruleCon, ruleName, value) {\n var annotationRule = ruleName.split('-');\n var rulesList = ['required', 'creditcard', 'phone', 'maxlength', 'minlength', 'range', 'regex', 'equalto'];\n var ruleFirstName = annotationRule[annotationRule.length - 1];\n var ruleSecondName = annotationRule[annotationRule.length - 2];\n if (rulesList.indexOf(ruleFirstName) !== -1) {\n switch (ruleFirstName) {\n case 'required':\n this.defRule(input, ruleCon, 'required', value);\n break;\n case 'creditcard':\n this.defRule(input, ruleCon, 'creditcard', value);\n break;\n case 'phone':\n this.defRule(input, ruleCon, 'tel', value);\n break;\n }\n }\n else if (rulesList.indexOf(ruleSecondName) !== -1) {\n switch (ruleSecondName) {\n case 'maxlength':\n this.defRule(input, ruleCon, 'maxLength', value);\n break;\n case 'minlength':\n this.defRule(input, ruleCon, 'minLength', value);\n break;\n case 'range':\n {\n var minvalue = input.getAttribute('data-val-range-min');\n var maxvalue = input.getAttribute('data-val-range-max');\n this.defRule(input, ruleCon, 'range', [minvalue, maxvalue]);\n }\n break;\n case 'equalto':\n {\n var id = input.getAttribute(ruleName).split('.');\n this.defRule(input, ruleCon, 'equalTo', id[id.length - 1]);\n }\n break;\n case 'regex':\n this.defRule(input, ruleCon, 'regex', value);\n break;\n }\n }\n };\n FormValidator.prototype.defRule = function (input, ruleCon, ruleName, value) {\n var message = input.getAttribute('data-' + ruleName + '-message');\n var annotationMessage = input.getAttribute('data-val-' + ruleName);\n var customMessage;\n if (this.rules[input.name] && ruleName !== 'validateHidden' && ruleName !== 'hidden') {\n this.getInputElement(input.name);\n customMessage = this.getErrorMessage(this.rules[input.name][\"\" + ruleName], ruleName);\n }\n if (message) {\n value = [value, message];\n }\n else if (annotationMessage) {\n value = [value, annotationMessage];\n }\n else if (customMessage) {\n value = [value, customMessage];\n }\n ruleCon[\"\" + ruleName] = value;\n };\n // Wire events to the form elements\n FormValidator.prototype.wireEvents = function () {\n for (var _i = 0, _a = (this.inputElements); _i < _a.length; _i++) {\n var input = _a[_i];\n if (FormValidator_1.isCheckable(input)) {\n EventHandler.add(input, 'click', this.clickHandler, this);\n }\n else if (input.tagName === 'SELECT') {\n EventHandler.add(input, 'change', this.changeHandler, this);\n }\n else {\n EventHandler.add(input, 'focusout', this.focusOutHandler, this);\n EventHandler.add(input, 'keyup', this.keyUpHandler, this);\n }\n }\n EventHandler.add(this.element, 'submit', this.submitHandler, this);\n EventHandler.add(this.element, 'reset', this.resetHandler, this);\n };\n // UnWire events to the form elements\n FormValidator.prototype.unwireEvents = function () {\n for (var _i = 0, _a = (this.inputElements); _i < _a.length; _i++) {\n var input = _a[_i];\n EventHandler.clearEvents(input);\n }\n EventHandler.remove(this.element, 'submit', this.submitHandler);\n EventHandler.remove(this.element, 'reset', this.resetHandler);\n };\n // Handle input element focusout event\n FormValidator.prototype.focusOutHandler = function (e) {\n this.trigger('focusout', e);\n //FormValidator.triggerCallback(this.focusout, e);\n var element = e.target;\n if (this.rules[element.name]) {\n if (this.rules[element.name][this.required] || element.value.length > 0) {\n this.validate(element.name);\n }\n else if (this.validated.indexOf(element.name) === -1) {\n this.validated.push(element.name);\n }\n }\n };\n // Handle input element keyup event\n FormValidator.prototype.keyUpHandler = function (e) {\n this.trigger('keyup', e);\n var element = e.target;\n // List of keys need to prevent while validation\n var excludeKeys = [16, 17, 18, 20, 35, 36, 37, 38, 39, 40, 45, 144, 225];\n if (e.which === 9 && (!this.rules[element.name] || (this.rules[element.name] && !this.rules[element.name][this.required]))) {\n return;\n }\n if (this.validated.indexOf(element.name) !== -1 && this.rules[element.name] && excludeKeys.indexOf(e.which) === -1) {\n this.validate(element.name);\n }\n };\n // Handle input click event\n FormValidator.prototype.clickHandler = function (e) {\n this.trigger('click', e);\n var element = e.target;\n // If element type is not submit allow validation\n if (element.type !== 'submit') {\n this.validate(element.name);\n }\n else if (element.getAttribute('formnovalidate') !== null) {\n // Prevent form validation, if submit button has formnovalidate attribute\n this.allowSubmit = true;\n }\n };\n // Handle input change event\n FormValidator.prototype.changeHandler = function (e) {\n this.trigger('change', e);\n var element = e.target;\n this.validate(element.name);\n };\n // Handle form submit event\n FormValidator.prototype.submitHandler = function (e) {\n this.trigger('submit', e);\n //FormValidator.triggerCallback(this.submit, e);\n // Prevent form submit if validation failed\n if (!this.allowSubmit && !this.validate()) {\n e.preventDefault();\n }\n else {\n this.allowSubmit = false;\n }\n };\n // Handle form reset\n FormValidator.prototype.resetHandler = function () {\n this.clearForm();\n };\n // Validate each rule based on input element name\n FormValidator.prototype.validateRules = function (name) {\n if (!this.rules[\"\" + name]) {\n return;\n }\n var rules = Object.keys(this.rules[\"\" + name]);\n var hiddenType = false;\n var validateHiddenType = false;\n var vhPos = rules.indexOf('validateHidden');\n var hPos = rules.indexOf('hidden');\n this.getInputElement(name);\n if (hPos !== -1) {\n hiddenType = true;\n }\n if (vhPos !== -1) {\n validateHiddenType = true;\n }\n if (!hiddenType || (hiddenType && validateHiddenType)) {\n if (vhPos !== -1) {\n rules.splice(vhPos, 1);\n }\n if (hPos !== -1) {\n rules.splice((hPos - 1), 1);\n }\n this.getErrorElement(name);\n for (var _i = 0, rules_2 = rules; _i < rules_2.length; _i++) {\n var rule = rules_2[_i];\n var errorMessage = this.getErrorMessage(this.rules[\"\" + name][\"\" + rule], rule);\n var errorRule = { name: name, message: errorMessage };\n var eventArgs = {\n inputName: name,\n element: this.inputElement,\n message: errorMessage\n };\n if (!this.isValid(name, rule) && !this.inputElement.classList.contains(this.ignore)) {\n this.removeErrorRules(name);\n this.errorRules.push(errorRule);\n // Set aria attributes to invalid elements\n this.inputElement.setAttribute('aria-invalid', 'true');\n this.inputElement.setAttribute('aria-describedby', this.inputElement.id + '-info');\n var inputParent = this.inputElement.parentElement;\n var grandParent = inputParent.parentElement;\n if (inputParent.classList.contains('e-control-wrapper') || inputParent.classList.contains('e-wrapper') || (this.inputElement.classList.contains('e-input') && inputParent.classList.contains('e-input-group'))) {\n inputParent.classList.add(this.errorClass);\n inputParent.classList.remove(this.validClass);\n }\n else if ((grandParent != null) && (grandParent.classList.contains('e-control-wrapper') || grandParent.classList.contains('e-wrapper'))) {\n grandParent.classList.add(this.errorClass);\n grandParent.classList.remove(this.validClass);\n }\n else {\n this.inputElement.classList.add(this.errorClass);\n this.inputElement.classList.remove(this.validClass);\n }\n if (!this.infoElement) {\n this.createErrorElement(name, errorRule.message, this.inputElement);\n }\n else {\n this.showMessage(errorRule);\n }\n eventArgs.errorElement = this.infoElement;\n eventArgs.status = 'failure';\n if (inputParent.classList.contains('e-control-wrapper') || inputParent.classList.contains('e-wrapper') || (this.inputElement.classList.contains('e-input') && inputParent.classList.contains('e-input-group'))) {\n inputParent.classList.add(this.errorClass);\n inputParent.classList.remove(this.validClass);\n }\n else if ((grandParent != null) && (grandParent.classList.contains('e-control-wrapper') || grandParent.classList.contains('e-wrapper'))) {\n grandParent.classList.add(this.errorClass);\n grandParent.classList.remove(this.validClass);\n }\n else {\n this.inputElement.classList.add(this.errorClass);\n this.inputElement.classList.remove(this.validClass);\n }\n this.optionalValidationStatus(name, eventArgs);\n this.trigger('validationComplete', eventArgs);\n // Set aria-required to required rule elements\n if (rule === 'required') {\n this.inputElement.setAttribute('aria-required', 'true');\n }\n break;\n }\n else {\n this.hideMessage(name);\n eventArgs.status = 'success';\n this.trigger('validationComplete', eventArgs);\n }\n }\n }\n else {\n return;\n }\n };\n // Update the optional validation status\n FormValidator.prototype.optionalValidationStatus = function (name, refer) {\n if (!this.rules[\"\" + name][this.required] && !this.inputElement.value.length && !isNullOrUndefined(this.infoElement)) {\n this.infoElement.innerHTML = this.inputElement.value;\n this.infoElement.setAttribute('aria-invalid', 'false');\n refer.status = '';\n this.hideMessage(name);\n }\n };\n // Check the input element whether it's value satisfy the validation rule or not\n FormValidator.prototype.isValid = function (name, rule) {\n var params = this.rules[\"\" + name][\"\" + rule];\n var param = (params instanceof Array && typeof params[1] === 'string') ? params[0] : params;\n var currentRule = this.rules[\"\" + name][\"\" + rule];\n var args = { value: this.inputElement.value, param: param, element: this.inputElement, formElement: this.element };\n this.trigger('validationBegin', args);\n if (!args.param && rule === 'required') {\n return true;\n }\n if (currentRule && typeof currentRule[0] === 'function') {\n var fn = currentRule[0];\n return fn.call(this, { element: this.inputElement, value: this.inputElement.value });\n }\n else if (FormValidator_1.isCheckable(this.inputElement)) {\n if (rule !== 'required') {\n return true;\n }\n return selectAll('input[name=\"' + name + '\"]:checked', this.element).length > 0;\n }\n else {\n return FormValidator_1.checkValidator[\"\" + rule](args);\n }\n };\n // Return default error message or custom error message\n FormValidator.prototype.getErrorMessage = function (ruleValue, rule) {\n var message = this.inputElement.getAttribute('data-' + rule + '-message') ?\n this.inputElement.getAttribute('data-' + rule + '-message') :\n (ruleValue instanceof Array && typeof ruleValue[1] === 'string') ? ruleValue[1] :\n (Object.keys(this.localyMessage).length !== 0) ? this.localyMessage[\"\" + rule] : this.defaultMessages[\"\" + rule];\n var formats = message.match(/{(\\d)}/g);\n if (!isNullOrUndefined(formats)) {\n for (var i = 0; i < formats.length; i++) {\n var value = ruleValue instanceof Array ? ruleValue[parseInt(i.toString())] : ruleValue;\n message = message.replace(formats[parseInt(i.toString())], value);\n }\n }\n return message;\n };\n // Create error element based on name and error message\n FormValidator.prototype.createErrorElement = function (name, message, input) {\n var errorElement = createElement(this.errorElement, {\n className: this.errorClass,\n innerHTML: message,\n attrs: { for: name }\n });\n // Create message design if errorOption is message\n if (this.errorOption === ErrorOption.Message) {\n errorElement.classList.remove(this.errorClass);\n errorElement.classList.add('e-message');\n errorElement = createElement(this.errorContainer, { className: this.errorClass, innerHTML: errorElement.outerHTML });\n }\n errorElement.id = this.inputElement.name + '-info';\n // Append error message into MVC error message element\n if (this.element.querySelector('[data-valmsg-for=\"' + input.id + '\"]')) {\n this.element.querySelector('[data-valmsg-for=\"' + input.id + '\"]').appendChild(errorElement);\n }\n else if (input.hasAttribute('data-msg-containerid') === true) {\n // Append error message into custom div element\n var containerId = input.getAttribute('data-msg-containerid');\n var divElement = select('#' + containerId, this.element);\n divElement.appendChild(errorElement);\n }\n else if (this.customPlacement != null) {\n // Call custom placement function if customPlacement is not null\n this.customPlacement.call(this, this.inputElement, errorElement);\n }\n else {\n var inputParent = this.inputElement.parentElement;\n var grandParent = inputParent.parentElement;\n if (inputParent.classList.contains('e-control-wrapper') || inputParent.classList.contains('e-wrapper')) {\n grandParent.insertBefore(errorElement, inputParent.nextSibling);\n }\n else if (grandParent.classList.contains('e-control-wrapper') || grandParent.classList.contains('e-wrapper')) {\n grandParent.parentElement.insertBefore(errorElement, grandParent.nextSibling);\n }\n else {\n inputParent.insertBefore(errorElement, this.inputElement.nextSibling);\n }\n }\n errorElement.style.display = 'block';\n this.getErrorElement(name);\n this.validated.push(name);\n this.checkRequired(name);\n };\n // Get error element by name\n FormValidator.prototype.getErrorElement = function (name) {\n this.infoElement = select(this.errorElement + '.' + this.errorClass, this.inputElement.parentElement);\n if (!this.infoElement) {\n this.infoElement = select(this.errorElement + '.' + this.errorClass + '[for=\"' + name + '\"]', this.element);\n }\n return this.infoElement;\n };\n // Remove existing rule from errorRules object\n FormValidator.prototype.removeErrorRules = function (name) {\n for (var i = 0; i < this.errorRules.length; i++) {\n var rule = this.errorRules[parseInt(i.toString())];\n if (rule.name === name) {\n this.errorRules.splice(i, 1);\n }\n }\n };\n // Show error message to the input element\n FormValidator.prototype.showMessage = function (errorRule) {\n this.infoElement.style.display = 'block';\n this.infoElement.innerHTML = errorRule.message;\n this.checkRequired(errorRule.name);\n };\n // Hide error message based on input name\n FormValidator.prototype.hideMessage = function (name) {\n if (this.infoElement) {\n this.infoElement.style.display = 'none';\n this.removeErrorRules(name);\n var inputParent = this.inputElement.parentElement;\n var grandParent = inputParent.parentElement;\n if (inputParent.classList.contains('e-control-wrapper') || inputParent.classList.contains('e-wrapper') || (this.inputElement.classList.contains('e-input') && inputParent.classList.contains('e-input-group'))) {\n inputParent.classList.add(this.validClass);\n inputParent.classList.remove(this.errorClass);\n }\n else if ((grandParent != null) && (grandParent.classList.contains('e-control-wrapper') || grandParent.classList.contains('e-wrapper'))) {\n grandParent.classList.add(this.validClass);\n grandParent.classList.remove(this.errorClass);\n }\n else {\n this.inputElement.classList.add(this.validClass);\n this.inputElement.classList.remove(this.errorClass);\n }\n this.inputElement.setAttribute('aria-invalid', 'false');\n }\n };\n // Check whether the input element have required rule and its value is not empty\n FormValidator.prototype.checkRequired = function (name) {\n if (!this.rules[\"\" + name][this.required] && !this.inputElement.value.length && !isNullOrUndefined(this.infoElement)) {\n this.infoElement.innerHTML = this.inputElement.value;\n this.infoElement.setAttribute('aria-invalid', 'false');\n this.hideMessage(name);\n }\n };\n // Return boolean result if the input have chekcable or submit types\n FormValidator.isCheckable = function (input) {\n var inputType = input.getAttribute('type');\n return inputType && (inputType === 'checkbox' || inputType === 'radio' || inputType === 'submit');\n };\n var FormValidator_1;\n // List of function to validate the rules\n FormValidator.checkValidator = {\n required: function (option) {\n return !isNaN(Date.parse(option.value)) ? !isNaN(new Date(option.value).getTime()) : option.value.toString().length > 0;\n },\n email: function (option) {\n return regex.EMAIL.test(option.value);\n },\n url: function (option) {\n return regex.URL.test(option.value);\n },\n dateIso: function (option) {\n return regex.DATE_ISO.test(option.value);\n },\n tel: function (option) {\n return regex.PHONE.test(option.value);\n },\n creditcard: function (option) {\n return regex.CREDITCARD.test(option.value);\n },\n number: function (option) {\n return !isNaN(Number(option.value)) && option.value.indexOf(' ') === -1;\n },\n digits: function (option) {\n return regex.DIGITS.test(option.value);\n },\n maxLength: function (option) {\n return option.value.length <= option.param;\n },\n minLength: function (option) {\n return option.value.length >= option.param;\n },\n rangeLength: function (option) {\n var param = option.param;\n return option.value.length >= param[0] && option.value.length <= param[1];\n },\n range: function (option) {\n var param = option.param;\n return !isNaN(Number(option.value)) && Number(option.value) >= param[0] && Number(option.value) <= param[1];\n },\n date: function (option) {\n if (!isNullOrUndefined(option.param) && (typeof (option.param) === 'string' && option.param !== '')) {\n var globalize = new Internationalization;\n var dateOptions = { format: option.param.toString(), type: 'dateTime', skeleton: 'yMd' };\n var dateValue = globalize.parseDate(option.value, dateOptions);\n return (!isNullOrUndefined(dateValue) && dateValue instanceof Date && !isNaN(+dateValue));\n }\n else {\n return !isNaN(new Date(option.value).getTime());\n }\n },\n max: function (option) {\n if (!isNaN(Number(option.value))) {\n // Maximum rule validation for number\n return +option.value <= option.param;\n }\n // Maximum rule validation for date\n return new Date(option.value).getTime() <= new Date(JSON.parse(JSON.stringify(option.param))).getTime();\n },\n min: function (option) {\n if (!isNaN(Number(option.value))) {\n // Minimum rule validation for number\n return +option.value >= option.param;\n }\n else if ((option.value).indexOf(',') !== -1) {\n var uNum = (option.value).replace(/,/g, '');\n return parseFloat(uNum) >= option.param;\n }\n else {\n // Minimum rule validation for date\n return new Date(option.value).getTime() >= new Date(JSON.parse(JSON.stringify(option.param))).getTime();\n }\n },\n regex: function (option) {\n /* eslint-disable-next-line security/detect-non-literal-regexp */\n return new RegExp(option.param).test(option.value);\n },\n equalTo: function (option) {\n var compareTo = option.formElement.querySelector('#' + option.param);\n option.param = compareTo.value;\n return option.param === option.value;\n }\n };\n __decorate([\n Property('')\n ], FormValidator.prototype, \"locale\", void 0);\n __decorate([\n Property('e-hidden')\n ], FormValidator.prototype, \"ignore\", void 0);\n __decorate([\n Property()\n ], FormValidator.prototype, \"rules\", void 0);\n __decorate([\n Property('e-error')\n ], FormValidator.prototype, \"errorClass\", void 0);\n __decorate([\n Property('e-valid')\n ], FormValidator.prototype, \"validClass\", void 0);\n __decorate([\n Property('label')\n ], FormValidator.prototype, \"errorElement\", void 0);\n __decorate([\n Property('div')\n ], FormValidator.prototype, \"errorContainer\", void 0);\n __decorate([\n Property(ErrorOption.Label)\n ], FormValidator.prototype, \"errorOption\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"focusout\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"keyup\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"click\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"change\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"submit\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"validationBegin\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"validationComplete\", void 0);\n __decorate([\n Event()\n ], FormValidator.prototype, \"customPlacement\", void 0);\n FormValidator = FormValidator_1 = __decorate([\n NotifyPropertyChanges\n ], FormValidator);\n return FormValidator;\n}(Base));\nexport { FormValidator };\n","import { ComponentBase, gh, getProps, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined, getValue } from '@syncfusion/ej2-base';\nimport { Button } from '@syncfusion/ej2-buttons';\nexport var properties = ['isLazyUpdate', 'plugins', 'content', 'cssClass', 'disabled', 'enableHtmlSanitizer', 'enablePersistence', 'enableRtl', 'iconCss', 'iconPosition', 'isPrimary', 'isToggle', 'locale', 'created'];\nexport var modelProps = [];\nexport var testProp = getProps({ props: properties });\nexport var props = testProp[0], watch = testProp[1], emitProbs = Object.keys(watch);\nemitProbs.push('modelchanged', 'update:modelValue');\nfor (var _i = 0, modelProps_1 = modelProps; _i < modelProps_1.length; _i++) {\n var props_1 = modelProps_1[_i];\n emitProbs.push('update:' + props_1);\n}\n/**\n * Represents the Essential JS 2 VueJS Button Component\n * ```html\n * <ejs-button>Button</ejs-button>\n * ```\n */\nexport var ButtonComponent = vueDefineComponent({\n name: 'ButtonComponent',\n mixins: [ComponentBase],\n props: props,\n watch: watch,\n emits: emitProbs,\n provide: function () { return { custom: this.custom }; },\n data: function () {\n return {\n ej2Instances: new Button({}),\n propKeys: properties,\n models: modelProps,\n hasChildDirective: false,\n hasInjectedModules: false,\n tagMapper: {},\n tagNameMapper: {},\n isVue3: !isExecute,\n templateCollection: {},\n };\n },\n created: function () {\n this.bindProperties();\n this.ej2Instances._setProperties = this.ej2Instances.setProperties;\n this.ej2Instances.setProperties = this.setProperties;\n this.ej2Instances.clearTemplate = this.clearTemplate;\n this.updated = this.updated;\n },\n render: function (createElement) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('button', slots);\n },\n methods: {\n clearTemplate: function (templateNames) {\n if (!templateNames) {\n templateNames = Object.keys(this.templateCollection || {});\n }\n if (templateNames.length && this.templateCollection) {\n for (var _i = 0, templateNames_1 = templateNames; _i < templateNames_1.length; _i++) {\n var tempName = templateNames_1[_i];\n var elementCollection = this.templateCollection[tempName];\n if (elementCollection && elementCollection.length) {\n for (var _a = 0, elementCollection_1 = elementCollection; _a < elementCollection_1.length; _a++) {\n var ele = elementCollection_1[_a];\n var destroy = getValue('__vue__.$destroy', ele);\n if (destroy) {\n ele.__vue__.$destroy();\n }\n if (ele.innerHTML) {\n ele.innerHTML = '';\n }\n }\n delete this.templateCollection[tempName];\n }\n }\n }\n },\n setProperties: function (prop, muteOnChange) {\n var _this = this;\n if (this.isVue3) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if (this.ej2Instances && this.ej2Instances._setProperties) {\n this.ej2Instances._setProperties(prop, muteOnChange);\n }\n if (prop && this.models && this.models.length) {\n Object.keys(prop).map(function (key) {\n _this.models.map(function (model) {\n if ((key === model) && !(/datasource/i.test(key))) {\n if (_this.isVue3) {\n _this.ej2Instances.vueInstance.$emit('update:' + key, prop[key]);\n }\n else {\n _this.$emit('update:' + key, prop[key]);\n _this.$emit('modelchanged', prop[key]);\n }\n }\n });\n });\n }\n },\n custom: function () {\n this.updated();\n },\n click: function () {\n return this.ej2Instances.click();\n },\n focusIn: function () {\n return this.ej2Instances.focusIn();\n },\n }\n});\nexport var ButtonPlugin = {\n name: 'ejs-button',\n install: function (Vue) {\n Vue.component(ButtonPlugin.name, ButtonComponent);\n }\n};\n","import { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { setStyleAttribute, closest as getClosest, remove } from '@syncfusion/ej2-base';\nimport { classList } from '@syncfusion/ej2-base';\nimport { CellType } from '../base/enum';\nimport { RowRenderer } from './row-renderer';\nimport { Cell } from '../models/cell';\nimport { Row } from '../models/row';\nimport * as events from '../base/constant';\nimport { Draggable, Droppable } from '@syncfusion/ej2-base';\nimport { Button } from '@syncfusion/ej2-buttons';\nimport { parentsUntil, wrap, measureColumnDepth, appendChildren, addFixedColumnBorder } from '../base/util';\nimport * as literals from '../base/string-literals';\n// eslint-disable-next-line valid-jsdoc\n/**\n * Content module is used to render grid content\n *\n * @hidden\n */\nvar HeaderRender = /** @class */ (function () {\n /**\n * Constructor for header renderer module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {ServiceLocator} serviceLocator - specifies the serviceLocator\n */\n function HeaderRender(parent, serviceLocator) {\n var _this = this;\n this.frzIdx = 0;\n this.notfrzIdx = 0;\n this.isFirstCol = false;\n this.isReplaceDragEle = true;\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n this.helper = function (e) {\n var gObj = _this.parent;\n var target = _this.draggable.currentStateTarget;\n var parentEle = parentsUntil(target, 'e-headercell');\n if (!(gObj.allowReordering || gObj.allowGrouping) || (!isNullOrUndefined(parentEle)\n && parentEle.getElementsByClassName('e-checkselectall').length > 0)) {\n return false;\n }\n var visualElement = _this.parent.createElement('div', { className: 'e-cloneproperties e-dragclone e-headerclone' });\n var element = target.classList.contains('e-headercell') ? target : parentEle;\n if (!element || (!gObj.allowReordering && element.classList.contains('e-stackedheadercell'))) {\n return false;\n }\n var height = element.offsetHeight;\n var headercelldiv = element.querySelector('.e-headercelldiv') || element.querySelector('.e-stackedheadercelldiv');\n var col;\n if (headercelldiv) {\n if (element.querySelector('.e-stackedheadercelldiv')) {\n col = gObj.getStackedHeaderColumnByHeaderText(headercelldiv.innerText.trim(), gObj.columns);\n }\n else {\n col = gObj.getColumnByUid(headercelldiv.getAttribute('e-mappinguid'));\n }\n _this.column = col;\n if (_this.column.lockColumn) {\n return false;\n }\n visualElement.setAttribute('e-mappinguid', _this.column.uid);\n }\n if (col && !isNullOrUndefined(col.headerTemplate)) {\n if (!isNullOrUndefined(col.headerTemplate)) {\n var colIndex = gObj.getColumnIndexByField(col.field);\n var result = col.getHeaderTemplate()(extend({ 'index': colIndex }, col), gObj, 'headerTemplate');\n var isReactCompiler = gObj.isReact && typeof (col.headerTemplate) !== 'string';\n var isReactChild = gObj.parentDetails && gObj.parentDetails.parentInstObj &&\n gObj.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild) {\n gObj.renderTemplates();\n }\n appendChildren(visualElement, result);\n }\n else {\n visualElement.innerHTML = col.headerTemplate;\n }\n if (!isNullOrUndefined(visualElement.firstChild) && visualElement.firstChild.nodeType === 1) {\n visualElement.firstChild.style.pointerEvents = 'none';\n }\n }\n else {\n visualElement.innerHTML = headercelldiv ?\n col.headerText : element.firstElementChild.innerHTML;\n }\n visualElement.style.width = element.offsetWidth + 'px';\n visualElement.style.height = element.offsetHeight + 'px';\n visualElement.style.lineHeight = (height - 6).toString() + 'px';\n gObj.element.appendChild(visualElement);\n return visualElement;\n };\n this.dragStart = function (e) {\n var gObj = _this.parent;\n gObj.element.querySelector('.e-gridpopup').style.display = 'none';\n gObj.notify(events.columnDragStart, { target: _this.draggable.currentStateTarget, column: _this.column, event: e.event });\n };\n this.drag = function (e) {\n var gObj = _this.parent;\n var target = e.target;\n if (target) {\n var closest = getClosest(target, '.e-grid');\n var cloneElement = _this.parent.element.querySelector('.e-cloneproperties');\n if (!closest || closest.getAttribute('id') !== gObj.element.getAttribute('id')) {\n classList(cloneElement, ['e-notallowedcur'], ['e-defaultcur']);\n if (gObj.allowReordering) {\n gObj.element.querySelector('.e-reorderuparrow').style.display = 'none';\n gObj.element.querySelector('.e-reorderdownarrow').style.display = 'none';\n }\n if (!gObj.groupSettings.allowReordering) {\n return;\n }\n }\n gObj.notify(events.columnDrag, { target: e.target, column: _this.column, event: e.event });\n }\n };\n this.dragStop = function (e) {\n var gObj = _this.parent;\n var cancel;\n gObj.element.querySelector('.e-gridpopup').style.display = 'none';\n if ((!parentsUntil(e.target, 'e-headercell') && !parentsUntil(e.target, 'e-groupdroparea')) ||\n (!gObj.allowReordering && parentsUntil(e.target, 'e-headercell')) ||\n (!e.helper.getAttribute('e-mappinguid') && parentsUntil(e.target, 'e-groupdroparea'))) {\n remove(e.helper);\n cancel = true;\n }\n gObj.notify(events.columnDragStop, { target: e.target, event: e.event, column: _this.column, cancel: cancel });\n };\n this.drop = function (e) {\n var gObj = _this.parent;\n var uid = e.droppedElement.getAttribute('e-mappinguid');\n var closest = getClosest(e.target, '.e-grid');\n remove(e.droppedElement);\n if (closest && closest.getAttribute('id') !== gObj.element.getAttribute('id') ||\n !(gObj.allowReordering || gObj.allowGrouping)) {\n return;\n }\n gObj.notify(events.headerDrop, { target: e.target, uid: uid, droppedElement: e.droppedElement });\n };\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.ariaService = this.serviceLocator.getService('ariaService');\n this.widthService = this.serviceLocator.getService('widthService');\n if (this.parent.isDestroyed) {\n return;\n }\n if (!this.parent.enableColumnVirtualization) {\n this.parent.on(events.columnVisibilityChanged, this.setVisible, this);\n }\n this.parent.on(events.columnPositionChanged, this.colPosRefresh, this);\n this.parent.on(events.initialEnd, this.renderCustomToolbar, this);\n if (this.parent.rowRenderingMode === 'Vertical') {\n this.parent.on(events.uiUpdate, this.updateCustomResponsiveToolbar, this);\n }\n }\n /**\n * The function is used to render grid header div\n *\n * @returns {void}\n */\n HeaderRender.prototype.renderPanel = function () {\n var div = this.parent.element.querySelector('.' + literals.gridHeader);\n var isRendered = (div != null);\n div = isRendered ? div : this.parent.createElement('div', { className: 'e-gridheader' });\n var innerDiv = isRendered ? div.querySelector('.' + literals.headerContent) :\n this.parent.createElement('div', { className: literals.headerContent });\n this.toggleStackClass(div);\n div.appendChild(innerDiv);\n this.setPanel(div);\n if (!isRendered) {\n this.parent.element.appendChild(div);\n }\n };\n /**\n * The function is used to render grid header div\n *\n * @returns {void}\n */\n HeaderRender.prototype.renderTable = function () {\n var headerDiv = this.getPanel();\n headerDiv.appendChild(this.createHeaderTable());\n this.setTable(headerDiv.querySelector('.' + literals.table));\n this.initializeHeaderDrag();\n this.initializeHeaderDrop();\n this.parent.notify(events.headerRefreshed, { rows: this.rows });\n };\n /**\n * Get the header content div element of grid\n *\n * @returns {Element} returns the element\n */\n HeaderRender.prototype.getPanel = function () {\n return this.headerPanel;\n };\n /**\n * Set the header content div element of grid\n *\n * @param {Element} panel - specifies the panel element\n * @returns {void}\n */\n HeaderRender.prototype.setPanel = function (panel) {\n this.headerPanel = panel;\n };\n /**\n * Get the header table element of grid\n *\n * @returns {Element} returns the element\n */\n HeaderRender.prototype.getTable = function () {\n return this.headerTable;\n };\n /**\n * Set the header table element of grid\n *\n * @param {Element} table - specifies the table element\n * @returns {void}\n */\n HeaderRender.prototype.setTable = function (table) {\n this.headerTable = table;\n };\n /**\n * Get the header colgroup element\n *\n * @returns {Element} returns the element\n */\n HeaderRender.prototype.getColGroup = function () {\n return this.colgroup;\n };\n /**\n * Set the header colgroup element\n *\n * @param {Element} colGroup - specifies the colgroup\n * @returns {Element} returns the element\n */\n HeaderRender.prototype.setColGroup = function (colGroup) {\n return this.colgroup = colGroup;\n };\n /**\n * Get the header row element collection.\n *\n * @returns {Element[]} returns the element\n */\n HeaderRender.prototype.getRows = function () {\n var table = this.getTable();\n return table.tHead.rows;\n };\n /**\n * The function is used to create header table elements\n *\n * @returns {Element} returns the element\n * @hidden\n */\n HeaderRender.prototype.createHeaderTable = function () {\n var table = this.createTable();\n var innerDiv = this.getPanel().querySelector('.' + literals.headerContent);\n innerDiv.appendChild(table);\n return innerDiv;\n };\n /**\n * The function is used to create header table elements\n *\n * @param {Element} tableEle - specifies the table Element\n * @param {freezeTable} tableName - specifies the table name\n * @returns {Element} returns the element\n * @hidden\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n HeaderRender.prototype.createHeader = function (tableEle, tableName) {\n if (tableEle === void 0) { tableEle = null; }\n var gObj = this.parent;\n if (this.getTable()) {\n remove(this.getTable());\n }\n var table = this.parent.createElement('table', { className: literals.table, attrs: { cellspacing: '0.25px', role: 'presentation' } });\n var findHeaderRow = this.createHeaderContent(tableName);\n var thead = findHeaderRow.thead;\n var tbody = this.parent.createElement(literals.tbody, { className: this.parent.frozenRows ? '' : 'e-hide', attrs: { role: 'rowgroup' } });\n this.caption = this.parent.createElement('caption', { innerHTML: this.parent.element.id + '_header_table', className: 'e-hide' });\n var colGroup = this.parent.createElement(literals.colGroup);\n var rowBody = this.parent.createElement('tr', { attrs: { role: 'row' } });\n var bodyCell;\n var rows = this.rows = findHeaderRow.rows;\n for (var i = 0, len = rows.length; i < len; i++) {\n for (var j = 0, len_1 = rows[parseInt(i.toString(), 10)].cells.length; j < len_1; j++) {\n bodyCell = this.parent.createElement('td');\n rowBody.appendChild(bodyCell);\n }\n }\n if (gObj.allowFiltering || gObj.allowSorting || gObj.allowGrouping) {\n table.classList.add('e-sortfilter');\n }\n this.updateColGroup(colGroup);\n tbody.appendChild(rowBody);\n table.appendChild(this.setColGroup(colGroup));\n table.appendChild(thead);\n table.appendChild(tbody);\n table.appendChild(this.caption);\n return table;\n };\n /**\n * @param {Element} tableEle - specifies the column\n * @returns {Element} returns the element\n * @hidden\n */\n HeaderRender.prototype.createTable = function (tableEle) {\n if (tableEle === void 0) { tableEle = null; }\n return this.createHeader(tableEle);\n };\n HeaderRender.prototype.createHeaderContent = function (tableName) {\n var gObj = this.parent;\n var columns = gObj.getColumns();\n var thead = this.parent.createElement('thead', { attrs: { 'role': 'rowgroup' } });\n var colHeader = this.parent.createElement('tr', { className: 'e-columnheader', attrs: { role: 'row' } });\n var rowRenderer = new RowRenderer(this.serviceLocator, CellType.Header, gObj);\n rowRenderer.element = colHeader;\n var rows = [];\n var headerRow;\n this.colDepth = measureColumnDepth(gObj.columns);\n for (var i = 0, len = this.colDepth; i < len; i++) {\n rows[parseInt(i.toString(), 10)] = this.generateRow(i);\n rows[parseInt(i.toString(), 10)].cells = [];\n }\n rows = this.ensureColumns(rows);\n rows = this.getHeaderCells(rows, tableName);\n if (gObj.isRowDragable() && this.parent.getFrozenMode() === 'Right') {\n for (var i = 0, len = rows.length; i < len; i++) {\n rows[parseInt(i.toString(), 10)].cells.push(this.generateCell({}, CellType.RowDragHIcon));\n }\n }\n for (var i = 0, len = this.colDepth; i < len; i++) {\n headerRow = rowRenderer.render(rows[parseInt(i.toString(), 10)], columns);\n if (this.parent.rowHeight && headerRow.querySelector('.e-headercell')) {\n headerRow.style.height = this.parent.rowHeight + 'px';\n }\n addFixedColumnBorder(headerRow);\n thead.appendChild(headerRow);\n }\n var findHeaderRow = {\n thead: thead,\n rows: rows\n };\n return findHeaderRow;\n };\n HeaderRender.prototype.updateColGroup = function (colGroup) {\n var cols = this.parent.getColumns();\n var col;\n var indexes = this.parent.getColumnIndexesInView();\n colGroup.id = this.parent.element.id + literals.colGroup;\n if (this.parent.allowGrouping) {\n for (var i = 0, len = this.parent.groupSettings.columns.length; i < len; i++) {\n if (this.parent.enableColumnVirtualization && indexes.indexOf(i) === -1) {\n continue;\n }\n col = this.parent.createElement('col', { className: 'e-group-intent' });\n colGroup.appendChild(col);\n }\n }\n if (this.parent.detailTemplate || this.parent.childGrid) {\n col = this.parent.createElement('col', { className: 'e-detail-intent' });\n colGroup.appendChild(col);\n }\n if (this.parent.isRowDragable() && this.parent.getFrozenMode() !== 'Right') {\n col = this.parent.createElement('col', { className: 'e-drag-intent' });\n colGroup.appendChild(col);\n }\n for (var i = 0, len = cols.length; i < len; i++) {\n col = this.parent.createElement('col');\n if (cols[parseInt(i.toString(), 10)].visible === false) {\n setStyleAttribute(col, { 'display': 'none' });\n }\n colGroup.appendChild(col);\n }\n if (this.parent.isRowDragable() && this.parent.getFrozenMode() === 'Right') {\n col = this.parent.createElement('col', { className: 'e-drag-intent' });\n colGroup.appendChild(col);\n }\n return colGroup;\n };\n HeaderRender.prototype.ensureColumns = function (rows) {\n //TODO: generate dummy column for group, detail, stacked row here; ensureColumns here\n var gObj = this.parent;\n var indexes = this.parent.getColumnIndexesInView();\n for (var i = 0, len = rows.length; i < len; i++) {\n if (gObj.allowGrouping) {\n for (var c = 0, len_2 = gObj.groupSettings.columns.length; c < len_2; c++) {\n if (this.parent.enableColumnVirtualization && indexes.indexOf(c) === -1) {\n continue;\n }\n rows[parseInt(i.toString(), 10)].cells.push(this.generateCell({}, CellType.HeaderIndent));\n }\n }\n if (gObj.detailTemplate || gObj.childGrid) {\n var args = {};\n this.parent.notify(events.detailIndentCellInfo, args);\n rows[parseInt(i.toString(), 10)].cells.push(this.generateCell(args, CellType.DetailHeader));\n }\n if (gObj.isRowDragable() && this.parent.getFrozenMode() !== 'Right') {\n rows[parseInt(i.toString(), 10)].cells.push(this.generateCell({}, CellType.RowDragHIcon));\n }\n }\n return rows;\n };\n HeaderRender.prototype.getHeaderCells = function (rows, tableName) {\n var thead = this.parent.getHeaderTable() && this.parent.getHeaderTable().querySelector('thead');\n var cols = this.parent.enableColumnVirtualization ?\n this.parent.getColumns(this.parent.enablePersistence) : this.parent.columns;\n this.frzIdx = 0;\n this.notfrzIdx = 0;\n if (this.parent.lockcolPositionCount) {\n for (var i = 0; i < cols.length; i++) {\n this.lockColsRendered = false;\n rows = this.appendCells(cols[parseInt(i.toString(), 10)], rows, 0, i === 0, false, i === (cols.length - 1), thead, tableName, false);\n }\n }\n for (var i = 0, len = cols.length; i < len; i++) {\n this.notfrzIdx = 0;\n this.lockColsRendered = true;\n rows = this.appendCells(cols[parseInt(i.toString(), 10)], rows, 0, i === 0, false, i === (len - 1), thead, tableName, false);\n }\n return rows;\n };\n HeaderRender.prototype.appendCells = function (cols, rows, index, isFirstObj, isFirstCol, isLastCol, isMovable, tableName, isStackLastCol) {\n var lastCol = isLastCol ? isStackLastCol ? 'e-laststackcell' : 'e-lastcell' : '';\n var isLockColumn = !this.parent.lockcolPositionCount\n || (cols.lockColumn && !this.lockColsRendered) || (!cols.lockColumn && this.lockColsRendered);\n if (!cols.columns) {\n if (isLockColumn) {\n rows[parseInt(index.toString(), 10)].cells.push(this.generateCell(cols, CellType.Header, this.colDepth - index, (isFirstObj ? '' : (isFirstCol ? 'e-firstcell' : '')) + lastCol, index, this.parent.getColumnIndexByUid(cols.uid)));\n }\n if (this.parent.lockcolPositionCount) {\n if ((this.frzIdx + this.notfrzIdx < this.parent.frozenColumns) &&\n ((cols.lockColumn && !this.lockColsRendered) || (!cols.lockColumn && this.lockColsRendered))) {\n this.frzIdx++;\n }\n else {\n this.notfrzIdx++;\n }\n }\n else {\n this.frzIdx++;\n }\n }\n else {\n this.isFirstCol = false;\n var colSpan = this.getCellCnt(cols, 0);\n if (colSpan) {\n var stackedLockColsCount = this.getStackedLockColsCount(cols, 0);\n var isStackedLockColumn = this.parent.lockcolPositionCount === 0\n || (!this.lockColsRendered && stackedLockColsCount !== 0)\n || (this.lockColsRendered && (colSpan - stackedLockColsCount) !== 0);\n if (isStackedLockColumn) {\n rows[parseInt(index.toString(), 10)].cells.push(new Cell({\n cellType: CellType.StackedHeader, column: cols,\n colSpan: this.getColSpan(colSpan, stackedLockColsCount),\n className: isFirstObj ? '' : (isFirstCol ? 'e-firstcell' : '')\n }));\n }\n }\n if (this.parent.lockcolPositionCount && !this.lockColsRendered) {\n for (var i = 0; i < cols.columns.length; i++) {\n rows = this.appendCells(cols.columns[parseInt(i.toString(), 10)], rows, index + 1, isFirstObj, i === 0, i === (cols.columns.length - 1) && isLastCol, isMovable, tableName, false);\n }\n }\n if (this.lockColsRendered) {\n for (var i = 0, len = cols.columns.length; i < len; i++) {\n isFirstObj = isFirstObj && i === 0;\n var isFirstCol_1 = this.isFirstCol = cols.columns[parseInt(i.toString(), 10)].visible\n && !isFirstObj;\n var isLaststackedCol = i === (len - 1) && isLastCol;\n rows = this.appendCells(cols.columns[parseInt(i.toString(), 10)], rows, index + 1, isFirstObj, isFirstCol_1 && !isLaststackedCol, isLaststackedCol, isMovable, tableName, true);\n }\n }\n }\n return rows;\n };\n HeaderRender.prototype.getStackedLockColsCount = function (col, lockColsCount) {\n if (col.columns) {\n for (var i = 0; i < col.columns.length; i++) {\n lockColsCount = this.getStackedLockColsCount(col.columns[parseInt(i.toString(), 10)], lockColsCount);\n }\n }\n else if (col.lockColumn) {\n lockColsCount++;\n }\n return lockColsCount;\n };\n HeaderRender.prototype.getColSpan = function (colSpan, stackedLockColsCount) {\n colSpan = !this.lockColsRendered ? stackedLockColsCount : colSpan - stackedLockColsCount;\n return colSpan;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n HeaderRender.prototype.generateRow = function (index) {\n return new Row({});\n };\n HeaderRender.prototype.generateCell = function (column, cellType, rowSpan, className, rowIndex, colIndex) {\n var opt = {\n 'visible': column.visible,\n 'isDataCell': false,\n 'isTemplate': !isNullOrUndefined(column.headerTemplate),\n 'rowID': '',\n 'column': column,\n 'cellType': cellType,\n 'rowSpan': rowSpan,\n 'className': className,\n 'index': rowIndex,\n 'colIndex': colIndex\n };\n if (!opt.rowSpan || opt.rowSpan < 2) {\n delete opt.rowSpan;\n }\n return new Cell(opt);\n };\n /**\n * Function to hide header table column based on visible property\n *\n * @param {Column[]} columns - specifies the column\n * @returns {void}\n */\n HeaderRender.prototype.setVisible = function (columns) {\n var gObj = this.parent;\n var displayVal;\n var idx;\n for (var c = 0, clen = columns.length; c < clen; c++) {\n var column = columns[parseInt(c.toString(), 10)];\n idx = gObj.getNormalizedColumnIndex(column.uid);\n displayVal = column.visible ? '' : 'none';\n setStyleAttribute(this.getColGroup().children[parseInt(idx.toString(), 10)], { 'display': displayVal });\n }\n this.refreshUI();\n };\n HeaderRender.prototype.colPosRefresh = function () {\n this.refreshUI();\n };\n /**\n * Refresh the header of the Grid.\n *\n * @returns {void}\n */\n HeaderRender.prototype.refreshUI = function () {\n var headerDiv = this.getPanel();\n this.toggleStackClass(headerDiv);\n var table = this.freezeReorder ? this.headerPanel.querySelector('.' + literals.movableHeader).querySelector('.' + literals.table)\n : this.getTable();\n var tableName = undefined;\n if (table) {\n remove(table);\n table.removeChild(table.firstChild);\n table.removeChild(table.childNodes[0]);\n var colGroup = this.parent.createElement(literals.colGroup);\n var findHeaderRow = this.createHeaderContent(tableName);\n this.rows = findHeaderRow.rows;\n table.insertBefore(findHeaderRow.thead, table.firstChild);\n this.updateColGroup(colGroup);\n table.insertBefore(this.setColGroup(colGroup), table.firstChild);\n this.appendContent(table);\n this.parent.notify(events.colGroupRefresh, {});\n this.widthService.setWidthToColumns();\n this.parent.updateDefaultCursor();\n this.initializeHeaderDrag();\n var rows = [].slice.call(headerDiv.querySelectorAll('tr.e-columnheader'));\n for (var _i = 0, rows_1 = rows; _i < rows_1.length; _i++) {\n var row = rows_1[_i];\n var gCells = [].slice.call(row.getElementsByClassName('e-grouptopleftcell'));\n if (gCells.length) {\n gCells[gCells.length - 1].classList.add('e-lastgrouptopleftcell');\n }\n }\n this.parent.notify(events.headerRefreshed, { rows: this.rows });\n if (this.parent.enableColumnVirtualization && parentsUntil(table, literals.movableHeader)) {\n this.parent.notify(events.headerRefreshed, { rows: this.rows, args: { isFrozen: false, isXaxis: true } });\n }\n if (this.parent.allowTextWrap && this.parent.textWrapSettings.wrapMode === 'Header') {\n wrap(rows, true);\n }\n }\n var firstHeaderCell = this.parent.getHeaderContent().querySelector('.e-headercell:not(.e-hide)');\n if (!isNullOrUndefined(firstHeaderCell)) {\n firstHeaderCell.tabIndex = 0;\n }\n };\n HeaderRender.prototype.toggleStackClass = function (div) {\n var column = this.parent.columns;\n var stackedHdr = column.some(function (column) { return !isNullOrUndefined(column.columns); });\n if (stackedHdr) {\n div.classList.add('e-stackedheader');\n }\n else {\n div.classList.remove('e-stackedheader');\n }\n };\n HeaderRender.prototype.appendContent = function (table) {\n this.getPanel().querySelector('.' + literals.headerContent).appendChild(table);\n };\n HeaderRender.prototype.getCellCnt = function (col, cnt) {\n if (col.columns) {\n for (var i = 0, len = col.columns.length; i < len; i++) {\n cnt = this.getCellCnt(col.columns[parseInt(i.toString(), 10)], cnt);\n }\n }\n else {\n if (col.visible) {\n cnt++;\n }\n }\n return cnt;\n };\n HeaderRender.prototype.initializeHeaderDrag = function () {\n var gObj = this.parent;\n if (!(this.parent.allowReordering || (this.parent.allowGrouping && this.parent.groupSettings.showDropArea))) {\n return;\n }\n this.draggable = new Draggable(gObj.getHeaderContent(), {\n dragTarget: '.e-headercell',\n distance: 5,\n helper: this.helper,\n dragStart: this.dragStart,\n drag: this.drag,\n dragStop: this.dragStop,\n abort: '.e-rhandler',\n isReplaceDragEle: this.isReplaceDragEle\n });\n this.parent.on(events.destroy, this.droppableDestroy, this);\n };\n HeaderRender.prototype.initializeHeaderDrop = function () {\n var gObj = this.parent;\n this.droppable = new Droppable(gObj.getHeaderContent(), {\n accept: '.e-dragclone',\n drop: this.drop\n });\n this.parent.on(events.destroy, this.droppableDestroy, this);\n };\n HeaderRender.prototype.droppableDestroy = function () {\n if (this.droppable && !this.droppable.isDestroyed) {\n this.droppable.destroy();\n }\n if (this.draggable && !this.draggable.isDestroyed) {\n this.draggable.destroy();\n }\n };\n HeaderRender.prototype.renderCustomToolbar = function () {\n var _this = this;\n var gObj = this.parent;\n if (gObj.rowRenderingMode === 'Vertical' && !gObj.toolbar\n && (gObj.allowSorting || (gObj.allowFiltering && gObj.filterSettings.type !== 'FilterBar'))) {\n var div = gObj.createElement('div', { className: 'e-res-toolbar e-toolbar' });\n var toolbarItems = gObj.createElement('div', { className: 'e-toolbar-items' });\n var toolbarLeft = gObj.createElement('div', { className: 'e-toolbar-left' });\n var count = this.parent.allowFiltering && this.parent.allowSorting ? 2 : 1;\n for (var i = 0; i < count; i++) {\n var toolbarItem = gObj.createElement('div', { className: 'e-toolbar-item e-gridresponsiveicons e-icons e-tbtn-align' });\n var cls = count === 1 ? this.parent.allowSorting ? 'sort'\n : 'filter' : i === 1 ? 'sort' : 'filter';\n var button = gObj.createElement('button', { className: 'e-tbar-btn e-control e-btn e-lib e-icon-btn' });\n var span = gObj.createElement('span', { className: 'e-btn-icon e-res' + cls + '-icon e-icons' });\n button.appendChild(span);\n var btnObj = new Button({\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n btnObj.appendTo(button);\n button.onclick = function (e) {\n if (e.target.classList.contains('e-ressort-btn')\n || e.target.classList.contains('e-ressort-icon')) {\n _this.parent.showResponsiveCustomSort();\n }\n else {\n _this.parent.showResponsiveCustomFilter();\n }\n };\n toolbarItem.appendChild(button);\n toolbarLeft.appendChild(toolbarItem);\n }\n toolbarItems.appendChild(toolbarLeft);\n div.appendChild(toolbarItems);\n gObj.element.insertBefore(div, this.parent.element.querySelector('.' + literals.gridHeader));\n }\n else {\n if (gObj.enableAdaptiveUI && !gObj.toolbar) {\n gObj.getContent().classList.add('e-responsive-header');\n }\n }\n };\n HeaderRender.prototype.updateCustomResponsiveToolbar = function (args) {\n var resToolbar = this.parent.element.querySelector('.e-responsive-toolbar');\n if (args.module === 'toolbar') {\n if (resToolbar) {\n remove(resToolbar);\n }\n else {\n this.renderCustomToolbar();\n }\n }\n };\n return HeaderRender;\n}());\nexport { HeaderRender };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined, extend, addClass } from '@syncfusion/ej2-base';\nimport { attributes } from '@syncfusion/ej2-base';\nimport { setStyleAndAttributes, appendChildren, addStickyColumnPosition } from '../base/util';\nimport { CellRenderer } from './cell-renderer';\nimport { AriaService } from '../services/aria-service';\nimport { createCheckBox } from '@syncfusion/ej2-buttons';\nimport { headerCellInfo } from '../base/constant';\n/**\n * HeaderCellRenderer class which responsible for building header cell content.\n *\n * @hidden\n */\nvar HeaderCellRenderer = /** @class */ (function (_super) {\n __extends(HeaderCellRenderer, _super);\n function HeaderCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent\n .createElement('TH', { className: 'e-headercell', attrs: { tabindex: '-1', role: 'columnheader' } });\n _this.ariaService = new AriaService();\n _this.hTxtEle = _this.parent.createElement('span', { className: 'e-headertext' });\n _this.sortEle = _this.parent.createElement('div', { className: 'e-sortfilterdiv e-icons', attrs: { 'aria-hidden': 'true' } });\n _this.gui = _this.parent.createElement('div');\n _this.chkAllBox = _this.parent.createElement('input', { className: 'e-checkselectall', attrs: { 'type': 'checkbox', 'aria-label': _this.localizer.getConstant('SelectAllCheckbox') } });\n return _this;\n }\n /**\n * Function to return the wrapper for the TH content.\n *\n * @returns {string | Element} returns the element\n */\n HeaderCellRenderer.prototype.getGui = function () {\n return this.gui.cloneNode();\n };\n /**\n * Function to render the cell content based on Column object.\n *\n * @param {Cell} cell - specifies the column\n * @param {Object} data - specifies the data\n * @param {object} attributes - specifies the aattributes\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n HeaderCellRenderer.prototype.render = function (cell, data, attributes) {\n var node = this.element.cloneNode();\n var fltrMenuEle = this.parent.createElement('div', { className: 'e-filtermenudiv e-icons e-icon-filter', attrs: { 'aria-hidden': 'true' } });\n return this.prepareHeader(cell, node, fltrMenuEle);\n };\n /**\n * Function to refresh the cell content based on Column object.\n *\n * @param {Cell} cell - specifies the cell\n * @param {Element} node - specifies the noe\n * @returns {Element} returns the element\n */\n HeaderCellRenderer.prototype.refresh = function (cell, node) {\n this.clean(node);\n var fltrMenuEle = this.parent.createElement('div', { className: 'e-filtermenudiv e-icons e-icon-filter', attrs: { 'aria-hidden': 'true' } });\n return this.prepareHeader(cell, node, fltrMenuEle);\n };\n HeaderCellRenderer.prototype.clean = function (node) {\n node.innerHTML = '';\n };\n /* tslint:disable-next-line:max-func-body-length */\n HeaderCellRenderer.prototype.prepareHeader = function (cell, node, fltrMenuEle) {\n var column = cell.column;\n var ariaAttr = {};\n var elementDesc = '';\n //Prepare innerHtml\n var innerDIV = this.getGui();\n var hValueAccer;\n attributes(innerDIV, {\n 'e-mappinguid': column.uid,\n 'class': 'e-headercelldiv'\n });\n if (!isNullOrUndefined(column.headerValueAccessor)) {\n hValueAccer = this.getValue(column.headerText, column);\n }\n if (column.type !== 'checkbox') {\n var value = column.headerText;\n if (!isNullOrUndefined(hValueAccer)) {\n value = hValueAccer;\n }\n var headerText = this.hTxtEle.cloneNode();\n headerText[column.getDomSetter()] = this.parent.sanitize(value);\n innerDIV.appendChild(headerText);\n }\n else {\n column.editType = 'booleanedit';\n var checkAllWrap = createCheckBox(this.parent.createElement, false, { checked: false, label: ' ' });\n this.chkAllBox.id = 'checkbox-' + column.uid;\n checkAllWrap.insertBefore(this.chkAllBox.cloneNode(), checkAllWrap.firstChild);\n if (this.parent.cssClass) {\n addClass([checkAllWrap], [this.parent.cssClass]);\n }\n innerDIV.appendChild(checkAllWrap);\n innerDIV.classList.add('e-headerchkcelldiv');\n }\n this.buildAttributeFromCell(node, cell);\n this.appendHtml(node, innerDIV);\n node.appendChild(this.sortEle.cloneNode());\n if ((this.parent.allowFiltering && this.parent.filterSettings.type !== 'FilterBar') &&\n (column.allowFiltering && !isNullOrUndefined(column.field)) &&\n !(this.parent.showColumnMenu && column.showColumnMenu)) {\n attributes(fltrMenuEle, {\n 'e-mappinguid': 'e-flmenu-' + column.uid\n });\n elementDesc = elementDesc.length ? elementDesc + '. ' + this.localizer.getConstant('FilterDescription') : this.localizer.getConstant('FilterDescription');\n node.classList.add('e-fltr-icon');\n var matchFlColumns = [];\n if (this.parent.filterSettings.columns.length && this.parent.filterSettings.columns.length !== matchFlColumns.length) {\n var foreignColumn = this.parent.getForeignKeyColumns();\n for (var index = 0; index < this.parent.columns.length; index++) {\n for (var count = 0; count < this.parent.filterSettings.columns.length; count++) {\n if (this.parent.filterSettings.columns[parseInt(count.toString(), 10)].field === column.field\n || (foreignColumn.length\n && column.foreignKeyValue === this.parent.filterSettings.columns[parseInt(count.toString(), 10)].field)) {\n fltrMenuEle.classList.add('e-filtered');\n matchFlColumns.push(column.field);\n break;\n }\n }\n }\n }\n node.appendChild(fltrMenuEle.cloneNode());\n }\n if (cell.className) {\n node.classList.add(cell.className);\n }\n if (column.customAttributes) {\n setStyleAndAttributes(node, column.customAttributes);\n }\n if (this.parent.allowSorting && column.allowSorting) {\n ariaAttr.sort = 'none';\n elementDesc = elementDesc.length ? elementDesc + '. ' + this.localizer.getConstant('SortDescription') : this.localizer.getConstant('SortDescription');\n }\n if ((this.parent.allowGrouping && column.allowGrouping) || this.parent.allowReordering && column.allowReordering) {\n ariaAttr.grabbed = false;\n elementDesc = elementDesc.length ? elementDesc + '. ' + this.localizer.getConstant('GroupDescription') : this.localizer.getConstant('GroupDescription');\n }\n if (this.parent.showColumnMenu && column.type !== 'checkbox' && !column.template) {\n elementDesc = elementDesc.length ? elementDesc + '. ' + this.localizer.getConstant('ColumnMenuDescription') : this.localizer.getConstant('ColumnMenuDescription');\n }\n node = this.extendPrepareHeader(column, node);\n var result;\n var gridObj = this.parent;\n var colIndex = gridObj.getColumnIndexByField(column.field);\n if (!isNullOrUndefined(column.headerTemplate)) {\n //need to pass the template id for blazor headertemplate\n var headerTempID = gridObj.element.id + column.uid + 'headerTemplate';\n var str = 'isStringTemplate';\n var col = column;\n var isReactCompiler = this.parent.isReact && typeof (column.headerTemplate) !== 'string';\n var isReactChild_1 = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild_1) {\n var copied = { 'index': colIndex };\n node.firstElementChild.innerHTML = '';\n column.getHeaderTemplate()(extend(copied, col), gridObj, 'headerTemplate', headerTempID, this.parent[\"\" + str], null, node.firstElementChild);\n this.parent.renderTemplates();\n }\n else {\n result = column.getHeaderTemplate()(extend({ 'index': colIndex }, col), gridObj, 'headerTemplate', headerTempID, this.parent[\"\" + str], undefined, undefined, this.parent['root']);\n node.firstElementChild.innerHTML = '';\n appendChildren(node.firstElementChild, result);\n }\n }\n this.ariaService.setOptions(node, ariaAttr);\n if (!isNullOrUndefined(column.headerTextAlign) || !isNullOrUndefined(column.textAlign)) {\n var alignment = column.headerTextAlign || column.textAlign;\n innerDIV.style.textAlign = alignment;\n if (alignment === 'Right' || alignment === 'Left') {\n node.classList.add(alignment === 'Right' ? 'e-rightalign' : 'e-leftalign');\n }\n else if (alignment === 'Center') {\n node.classList.add('e-centeralign');\n }\n }\n if (column.clipMode === 'Clip' || (!column.clipMode && this.parent.clipMode === 'Clip')) {\n node.classList.add('e-gridclip');\n }\n else if ((column.clipMode === 'EllipsisWithTooltip' || (!column.clipMode && this.parent.clipMode === 'EllipsisWithTooltip'))\n && !(gridObj.allowTextWrap && (gridObj.textWrapSettings.wrapMode === 'Header'\n || gridObj.textWrapSettings.wrapMode === 'Both'))) {\n if (column.type !== 'checkbox') {\n node.classList.add('e-ellipsistooltip');\n }\n }\n if (elementDesc) {\n var titleElem = (this.parent.createElement('span', { id: 'headerTitle-' + column.uid, innerHTML: elementDesc, attrs: { style: 'display:none' } }));\n node.appendChild(titleElem);\n node.setAttribute('aria-describedby', titleElem.id);\n }\n node.setAttribute('aria-rowspan', (!isNullOrUndefined(cell.rowSpan) ? cell.rowSpan : 1).toString());\n node.setAttribute('aria-colspan', '1');\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n if (((this.parent.isReact && this.parent.requireTemplateRef)\n || (isReactChild && this.parent.parentDetails.parentInstObj.requireTemplateRef))\n && !isNullOrUndefined(column.headerTemplate)) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var thisRef_1 = this;\n thisRef_1.parent.renderTemplates(function () {\n thisRef_1.parent.trigger(headerCellInfo, { cell: cell, node: node });\n });\n }\n else {\n this.parent.trigger(headerCellInfo, { cell: cell, node: node });\n }\n if (this.parent.isFrozenGrid()) {\n addStickyColumnPosition(this.parent, column, node);\n }\n return node;\n };\n HeaderCellRenderer.prototype.getValue = function (field, column) {\n return column.headerValueAccessor(field, column);\n };\n HeaderCellRenderer.prototype.extendPrepareHeader = function (column, node) {\n if (this.parent.showColumnMenu && column.showColumnMenu && !isNullOrUndefined(column.field)) {\n var element = (this.parent.createElement('div', { className: 'e-icons e-columnmenu', attrs: { 'aria-hidden': 'true' } }));\n var matchFilteredColumns = [];\n if (this.parent.filterSettings.columns.length && this.parent.filterSettings.columns.length !== matchFilteredColumns.length) {\n for (var i = 0; i < this.parent.columns.length; i++) {\n for (var j = 0; j < this.parent.filterSettings.columns.length; j++) {\n if (this.parent.filterSettings.columns[parseInt(j.toString(), 10)].field === column.field) {\n element.classList.add('e-filtered');\n matchFilteredColumns.push(column.field);\n break;\n }\n }\n }\n }\n node.classList.add('e-fltr-icon');\n node.appendChild(element);\n }\n if (this.parent.allowResizing) {\n var handler = this.parent.createElement('div');\n handler.className = column.allowResizing ? 'e-rhandler e-rcursor' : 'e-rsuppress';\n node.appendChild(handler);\n }\n return node;\n };\n /**\n * Function to specifies how the result content to be placed in the cell.\n *\n * @param {Element} node - specifies the node\n * @param {string|Element} innerHtml - specifies the innerHtml\n * @returns {Element} returns the element\n */\n HeaderCellRenderer.prototype.appendHtml = function (node, innerHtml) {\n node.appendChild(innerHtml);\n return node;\n };\n return HeaderCellRenderer;\n}(CellRenderer));\nexport { HeaderCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { CellRenderer } from './cell-renderer';\nimport { headerCellInfo } from '../base/constant';\nimport { setStyleAndAttributes, appendChildren, frozenDirection, isChildColumn, applyStickyLeftRightPosition } from '../base/util';\n/**\n * StackedHeaderCellRenderer class which responsible for building stacked header cell content.\n *\n * @hidden\n */\nvar StackedHeaderCellRenderer = /** @class */ (function (_super) {\n __extends(StackedHeaderCellRenderer, _super);\n function StackedHeaderCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TH', {\n className: 'e-headercell e-stackedheadercell', attrs: {\n tabindex: '-1', role: 'columnheader'\n }\n });\n return _this;\n }\n /**\n * Function to render the cell content based on Column object.\n *\n * @param {Cell<Column>} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @param {object} attributes - specifies the attributes\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n StackedHeaderCellRenderer.prototype.render = function (cell, data, attributes) {\n var node = this.element.cloneNode();\n var div = this.parent.createElement('div', {\n className: 'e-stackedheadercelldiv',\n attrs: { 'e-mappinguid': cell.column.uid }\n });\n var column = cell.column;\n node.appendChild(div);\n if (!isNullOrUndefined(column.headerTemplate)) {\n appendChildren(div, column.getHeaderTemplate()(column, this.parent, 'headerTemplate'));\n }\n else {\n this.appendHtml(div, this.parent.sanitize(column.headerText), column.getDomSetter());\n }\n if (cell.column.toolTip) {\n node.setAttribute('title', cell.column.toolTip);\n }\n if (column.clipMode === 'Clip' || (!column.clipMode && this.parent.clipMode === 'Clip')) {\n node.classList.add('e-gridclip');\n }\n else if (column.clipMode === 'EllipsisWithTooltip' || (!column.clipMode && this.parent.clipMode === 'EllipsisWithTooltip')) {\n node.classList.add('e-ellipsistooltip');\n }\n if (!isNullOrUndefined(cell.column.textAlign)) {\n div.style.textAlign = cell.column.textAlign;\n }\n if (cell.column.customAttributes) {\n setStyleAndAttributes(node, cell.column.customAttributes);\n }\n node.setAttribute('colspan', cell.colSpan.toString());\n node.setAttribute('aria-colspan', cell.colSpan.toString());\n node.setAttribute('aria-rowspan', '1');\n if (this.parent.allowResizing) {\n var handler = this.parent.createElement('div');\n handler.className = cell.column.allowResizing ? 'e-rhandler e-rcursor' : 'e-rsuppress';\n node.appendChild(handler);\n }\n if (cell.className) {\n node.classList.add(cell.className);\n }\n this.parent.trigger(headerCellInfo, { cell: cell, node: node });\n if (frozenDirection(column) === 'Left') {\n node.classList.add('e-leftfreeze');\n if (column.border === 'Left') {\n node.classList.add('e-freezeleftborder');\n }\n if (column.index === 0) {\n applyStickyLeftRightPosition(node, (this.parent.getIndentCount() * 30), this.parent.enableRtl, 'Left');\n }\n else {\n var cols = this.parent.getColumns();\n var width = this.parent.getIndentCount() * 30;\n for (var i = 0; i < cols.length; i++) {\n if (column.index < cols[parseInt(i.toString(), 10)].index) {\n break;\n }\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n applyStickyLeftRightPosition(node, width, this.parent.enableRtl, 'Left');\n }\n }\n else if (frozenDirection(column) === 'Right') {\n node.classList.add('e-rightfreeze');\n var cols = this.parent.getColumns();\n var width = this.parent.getFrozenMode() === 'Right' && this.parent.isRowDragable() ? 30 : 0;\n for (var i = cols.length - 1; i >= 0; i--) {\n if (isChildColumn(column, cols[parseInt(i.toString(), 10)].uid) || column.index > cols[parseInt(i.toString(), 10)].index) {\n break;\n }\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n applyStickyLeftRightPosition(node, width, this.parent.enableRtl, 'Right');\n if (column.border === 'Right') {\n node.classList.add('e-freezerightborder');\n }\n }\n else if (frozenDirection(column) === 'Fixed') {\n node.classList.add('e-fixedfreeze');\n var cols = this.parent.getColumns();\n var width = 0;\n if (this.parent.getVisibleFrozenLeftCount()) {\n width = this.parent.getIndentCount() * 30;\n }\n else if (this.parent.getFrozenMode() === 'Right') {\n width = this.parent.groupSettings.columns.length * 30;\n }\n for (var i = 0; i < cols.length; i++) {\n if (column.index > cols[parseInt(i.toString(), 10)].index) {\n if ((cols[parseInt(i.toString(), 10)].freeze === 'Left' || cols[parseInt(i.toString(), 10)].isFrozen) ||\n cols[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n }\n }\n applyStickyLeftRightPosition(node, width - 1, this.parent.enableRtl, 'Left');\n width = this.parent.getFrozenMode() === 'Right' && this.parent.isRowDragable() ? 30 : 0;\n for (var i = cols.length - 1; i >= 0; i--) {\n if (column.index < cols[parseInt(i.toString(), 10)].index) {\n if (isChildColumn(column, cols[parseInt(i.toString(), 10)].uid) ||\n column.index > cols[parseInt(i.toString(), 10)].index) {\n break;\n }\n if (cols[parseInt(i.toString(), 10)].freeze === 'Right' || cols[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n }\n }\n applyStickyLeftRightPosition(node, width - 1, this.parent.enableRtl, 'Right');\n }\n else {\n node.classList.add('e-unfreeze');\n }\n return node;\n };\n return StackedHeaderCellRenderer;\n}(CellRenderer));\nexport { StackedHeaderCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { setStyleAndAttributes } from '../base/util';\nimport { CellRenderer } from './cell-renderer';\n/**\n * IndentCellRenderer class which responsible for building group indent cell.\n *\n * @hidden\n */\nvar IndentCellRenderer = /** @class */ (function (_super) {\n __extends(IndentCellRenderer, _super);\n function IndentCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TD', { className: 'e-indentcell' });\n return _this;\n }\n /**\n * Function to render the indent cell\n *\n * @param {Cell} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n IndentCellRenderer.prototype.render = function (cell, data) {\n var node = this.element.cloneNode();\n setStyleAndAttributes(node, cell.attributes);\n return node;\n };\n return IndentCellRenderer;\n}(CellRenderer));\nexport { IndentCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { CellRenderer } from './cell-renderer';\nimport { appendChildren, templateCompiler } from '../base/util';\nimport { CellType } from '../base/enum';\n/**\n * GroupCaptionCellRenderer class which responsible for building group caption cell.\n *\n * @hidden\n */\nvar GroupCaptionCellRenderer = /** @class */ (function (_super) {\n __extends(GroupCaptionCellRenderer, _super);\n function GroupCaptionCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.cellUid = 0;\n _this.element = _this.parent\n .createElement('TD', { className: 'e-groupcaption',\n attrs: { id: _this.parent.element.id + 'captioncell', tabindex: '-1' } });\n return _this;\n }\n /**\n * Function to render the cell content based on Column object.\n *\n * @param {Cell} cell - specifies the cell\n * @param {Object} data - specifies the GroupedData\n * @returns {Element} returns the element\n */\n GroupCaptionCellRenderer.prototype.render = function (cell, data) {\n this.element.id = this.parent.element.id + 'captioncell' + this.cellUid++;\n var node = this.element.cloneNode();\n var gObj = this.parent;\n var column = cell.column;\n var domSetter = column.getDomSetter ? column.getDomSetter() : 'innerHTML';\n var result;\n var fKeyValue;\n var gTemplateValue;\n data.headerText = cell.column.headerText;\n if (cell.isForeignKey) {\n fKeyValue = this.format(cell.column, cell.column.valueAccessor('foreignKey', data, cell.column));\n }\n var value = cell.isForeignKey ? fKeyValue : cell.column.enableGroupByFormat ? data.key :\n this.format(cell.column, cell.column.valueAccessor('key', data, cell.column));\n for (var j = 0; j < gObj.aggregates.length; j++) {\n var _loop_1 = function (i) {\n if (gObj.getVisibleColumns()[0].field === gObj.aggregates[parseInt(j.toString(), 10)].columns[parseInt(i.toString(), 10)]\n .field && gObj.aggregates[parseInt(j.toString(), 10)].columns[parseInt(i.toString(), 10)].groupCaptionTemplate) {\n var gCaptionTemp = gObj.aggregates[parseInt(j.toString(), 10)]\n .columns[parseInt(i.toString(), 10)].groupCaptionTemplate;\n if (typeof gCaptionTemp === 'string' && gCaptionTemp.includes('$')) {\n gTemplateValue = gObj.aggregates[parseInt(j.toString(), 10)].columns[parseInt(i.toString(), 10)]\n .groupCaptionTemplate.split('$')[0] + data[gObj.getVisibleColumns()[0].field][gObj\n .aggregates[parseInt(j.toString(), 10)].columns[parseInt(i.toString(), 10)].type] +\n gObj.aggregates[parseInt(j.toString(), 10)].columns[parseInt(i.toString(), 10)]\n .groupCaptionTemplate.split('}')[1];\n }\n else {\n var column_1 = (gObj.aggregates[parseInt(j.toString(), 10)]\n .columns[parseInt(i.toString(), 10)]);\n var tempObj = column_1.getTemplate(CellType.CaptionSummary);\n var tempID = '';\n if (!isNullOrUndefined(tempObj)) {\n var tempValue_1 = tempObj.fn(data[column_1.columnName], this_1.parent, tempObj.property, tempID);\n if (this_1.parent.isReact && typeof column_1.groupCaptionTemplate !== 'string') {\n this_1.parent.renderTemplates(function () {\n if (tempValue_1 && tempValue_1.length) {\n if (!isNullOrUndefined(gObj.groupSettings.captionTemplate)) {\n node.appendChild(tempValue_1[0]);\n }\n else {\n node.innerText += ' ' + tempValue_1[0].textContent;\n }\n }\n });\n }\n else {\n if (tempValue_1 && tempValue_1.length) {\n if (!isNullOrUndefined(gObj.groupSettings.captionTemplate)) {\n gTemplateValue = tempValue_1;\n }\n else {\n gTemplateValue = tempValue_1[0].textContent;\n }\n }\n }\n }\n }\n return \"break\";\n }\n };\n var this_1 = this;\n for (var i = 0; i < gObj.aggregates[parseInt(j.toString(), 10)].columns.length; i++) {\n var state_1 = _loop_1(i);\n if (state_1 === \"break\")\n break;\n }\n }\n if (!isNullOrUndefined(gObj.groupSettings.captionTemplate)) {\n var isReactCompiler = this.parent.isReact && typeof (gObj.groupSettings.captionTemplate) !== 'string';\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild) {\n var tempID = gObj.element.id + 'captionTemplate';\n templateCompiler(gObj.groupSettings.captionTemplate)(data, this.parent, 'captionTemplate', tempID, null, null, node);\n this.parent.renderTemplates();\n }\n else if (this.parent.isVue) {\n result = templateCompiler(gObj.groupSettings.captionTemplate)(data, this.parent);\n }\n else {\n result = templateCompiler(gObj.groupSettings.captionTemplate)(data);\n }\n if (!isReactCompiler && !isReactChild) {\n appendChildren(node, result);\n if (gTemplateValue && gTemplateValue.length && gTemplateValue[0].textContent) {\n node.appendChild(gTemplateValue[0]);\n }\n }\n }\n else {\n if (gObj.groupSettings.enableLazyLoading) {\n node[\"\" + domSetter] = this.parent.sanitize(cell.column.headerText) + ': ' + this.parent.sanitize(value) +\n (gTemplateValue ? ' ' + gTemplateValue : '');\n }\n else {\n node[\"\" + domSetter] = this.parent.sanitize(cell.column.headerText) + ': ' + this.parent.sanitize(value) +\n ' - ' + data.count + ' ' + (data.count < 2 ? this.localizer.getConstant('Item') : this.localizer.getConstant('Items'))\n + (gTemplateValue ? ' ' + gTemplateValue : '');\n }\n }\n node.setAttribute('colspan', cell.colSpan.toString());\n node.setAttribute('aria-label', node.innerHTML + this.localizer.getConstant('GroupCaption'));\n node.setAttribute('title', node.textContent);\n return node;\n };\n return GroupCaptionCellRenderer;\n}(CellRenderer));\nexport { GroupCaptionCellRenderer };\n/**\n * GroupCaptionEmptyCellRenderer class which responsible for building group caption empty cell.\n *\n * @hidden\n */\nvar GroupCaptionEmptyCellRenderer = /** @class */ (function (_super) {\n __extends(GroupCaptionEmptyCellRenderer, _super);\n function GroupCaptionEmptyCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TD', { className: 'e-groupcaption' });\n return _this;\n }\n /**\n * Function to render the cell content based on Column object.\n *\n * @param {Cell} cell - specifies the cell\n * @param {Object} data - specifies the Object\n * @param {string} data.field - Defines the field\n * @param {string} data.key - Defines the key\n * @param {number} data.count - Defines the count\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n GroupCaptionEmptyCellRenderer.prototype.render = function (cell, data) {\n var node = this.element.cloneNode();\n node.innerHTML = ' ';\n node.setAttribute('colspan', cell.colSpan.toString());\n return node;\n };\n return GroupCaptionEmptyCellRenderer;\n}(CellRenderer));\nexport { GroupCaptionEmptyCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { IndentCellRenderer } from './indent-cell-renderer';\nimport { CellType } from '../base/enum';\n/**\n * ExpandCellRenderer class which responsible for building group expand cell.\n *\n * @hidden\n */\nvar ExpandCellRenderer = /** @class */ (function (_super) {\n __extends(ExpandCellRenderer, _super);\n function ExpandCellRenderer() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * Function to render the expand cell\n *\n * @param {Cell} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @param {string} data.field - Defines the field\n * @param {string} data.key - Defines the key\n * @param {Object} attr - specifies the attribute\n * @param {boolean} isExpand - specifies isexpand\n * @returns {Element} returns the element\n */\n ExpandCellRenderer.prototype.render = function (cell, data, attr, isExpand) {\n var node = this.element.cloneNode();\n node.setAttribute('ej-mappingname', data.field);\n node.setAttribute('ej-mappingvalue', data.key);\n node.setAttribute('aria-expanded', isExpand ? 'true' : 'false');\n node.setAttribute('tabindex', '-1');\n if (this.parent.infiniteScrollSettings && this.parent.infiniteScrollSettings.enableCache) {\n cell.cellType = CellType.Indent;\n node.className = isExpand ? 'e-recordplusexpand e-disablepointer' : 'e-recordpluscollapse e-disablepointer';\n }\n else {\n node.className = isExpand ? 'e-recordplusexpand' : 'e-recordpluscollapse';\n node.appendChild(this.parent.createElement('a', {\n className: isExpand ? 'e-icons e-gdiagonaldown e-icon-gdownarrow' : 'e-icons e-gnextforward e-icon-grightarrow',\n attrs: { href: '#', 'title': isExpand ? 'expanded' : 'collapsed' }\n }));\n }\n return node;\n };\n return ExpandCellRenderer;\n}(IndentCellRenderer));\nexport { ExpandCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { CellRenderer } from './cell-renderer';\n/**\n * HeaderIndentCellRenderer class which responsible for building header indent cell.\n *\n * @hidden\n */\nvar HeaderIndentCellRenderer = /** @class */ (function (_super) {\n __extends(HeaderIndentCellRenderer, _super);\n function HeaderIndentCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TH', { className: 'e-grouptopleftcell' });\n return _this;\n }\n /**\n * Function to render the indent cell\n *\n * @param {Cell} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n HeaderIndentCellRenderer.prototype.render = function (cell, data) {\n var node = this.element.cloneNode();\n node.appendChild(this.parent.createElement('div', { className: 'e-headercelldiv e-emptycell', innerHTML: '' }));\n return node;\n };\n return HeaderIndentCellRenderer;\n}(CellRenderer));\nexport { HeaderIndentCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { CellRenderer } from './cell-renderer';\n/**\n * DetailHeaderIndentCellRenderer class which responsible for building detail header indent cell.\n *\n * @hidden\n */\nvar DetailHeaderIndentCellRenderer = /** @class */ (function (_super) {\n __extends(DetailHeaderIndentCellRenderer, _super);\n function DetailHeaderIndentCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TH', { className: 'e-detailheadercell' });\n return _this;\n }\n /**\n * Function to render the detail indent cell\n *\n * @param {Cell} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n DetailHeaderIndentCellRenderer.prototype.render = function (cell, data) {\n var node = this.element.cloneNode();\n node.appendChild(this.parent.createElement('div', { className: 'e-emptycell' }));\n return node;\n };\n return DetailHeaderIndentCellRenderer;\n}(CellRenderer));\nexport { DetailHeaderIndentCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { CellRenderer } from './cell-renderer';\n/**\n * ExpandCellRenderer class which responsible for building group expand cell.\n *\n * @hidden\n */\nvar DetailExpandCellRenderer = /** @class */ (function (_super) {\n __extends(DetailExpandCellRenderer, _super);\n function DetailExpandCellRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TD', {\n className: 'e-detailrowcollapse',\n attrs: { 'aria-expanded': 'false', tabindex: '-1' }\n });\n return _this;\n }\n /**\n * Function to render the detail expand cell\n *\n * @param {Cell<Column>} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @param {Object} attributes - specifies the attributes\n * @returns {Element} returns the element\n */\n DetailExpandCellRenderer.prototype.render = function (cell, data, attributes) {\n var node = this.element.cloneNode();\n if (attributes && !isNullOrUndefined(attributes['class'])) {\n node.className = '';\n node.className = attributes['class'];\n node.appendChild(this.parent.createElement('a', { className: 'e-icons e-dtdiagonaldown e-icon-gdownarrow', attrs: {\n href: '#', 'title': this.localizer.getConstant('Expanded')\n } }));\n }\n else {\n node.appendChild(this.parent.createElement('a', { className: 'e-icons e-dtdiagonalright e-icon-grightarrow', attrs: {\n href: '#', 'title': this.localizer.getConstant('Collapsed')\n } }));\n }\n if (cell.isSelected) {\n node.classList.add('e-selectionbackground', 'e-active');\n }\n return node;\n };\n return DetailExpandCellRenderer;\n}(CellRenderer));\nexport { DetailExpandCellRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { CellRenderer } from './cell-renderer';\nimport { applyStickyLeftRightPosition } from '../base/util';\n/**\n * ExpandCellRenderer class which responsible for building group expand cell.\n *\n * @hidden\n */\nvar RowDragDropRenderer = /** @class */ (function (_super) {\n __extends(RowDragDropRenderer, _super);\n function RowDragDropRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TD', {\n className: 'e-rowdragdrop e-rowdragdropcell',\n attrs: { tabindex: '-1', role: 'gridcell' }\n });\n return _this;\n }\n /**\n * Function to render the detail expand cell\n *\n * @param {Cell<Column>} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n RowDragDropRenderer.prototype.render = function (cell, data) {\n var nodeElement = this.element.cloneNode();\n nodeElement.appendChild(this.parent.createElement('div', {\n className: 'e-icons e-rowcelldrag e-dtdiagonalright e-icon-rowdragicon',\n attrs: { 'aria-hidden': 'true' }\n }));\n if (cell.isSelected) {\n nodeElement.classList.add('e-selectionbackground');\n nodeElement.classList.add('e-active');\n }\n if (this.parent.getVisibleFrozenRightCount() || this.parent.getVisibleFrozenLeftCount()) {\n nodeElement.classList.add('e-leftfreeze');\n var width = this.parent.getFrozenMode() === 'Right' ? 0 : this.parent.groupSettings.columns.length * 30;\n applyStickyLeftRightPosition(nodeElement, width, this.parent.enableRtl, this.parent.getFrozenMode() === 'Right' ? 'Right' : 'Left');\n }\n return nodeElement;\n };\n return RowDragDropRenderer;\n}(CellRenderer));\nexport { RowDragDropRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { createElement } from '@syncfusion/ej2-base';\nimport { CellRenderer } from './cell-renderer';\nimport { applyStickyLeftRightPosition } from '../base/util';\n/**\n * DetailHeaderIndentCellRenderer class which responsible for building detail header indent cell.\n *\n * @hidden\n */\nvar RowDragDropHeaderRenderer = /** @class */ (function (_super) {\n __extends(RowDragDropHeaderRenderer, _super);\n function RowDragDropHeaderRenderer() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.element = _this.parent.createElement('TH', { className: 'e-rowdragheader' });\n return _this;\n }\n /**\n * Function to render the detail indent cell\n *\n * @param {Cell} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @returns {Element} returns the element\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n RowDragDropHeaderRenderer.prototype.render = function (cell, data) {\n var node = this.element.cloneNode();\n node.appendChild(createElement('div', { className: 'e-emptycell' }));\n if (this.parent.getVisibleFrozenRightCount() || this.parent.getVisibleFrozenLeftCount()) {\n node.classList.add('e-leftfreeze');\n var width = this.parent.getFrozenMode() === 'Right' ? 0 : this.parent.groupSettings.columns.length * 30;\n applyStickyLeftRightPosition(node, width, this.parent.enableRtl, this.parent.getFrozenMode() === 'Right' ? 'Right' : 'Left');\n }\n return node;\n };\n return RowDragDropHeaderRenderer;\n}(CellRenderer));\nexport { RowDragDropHeaderRenderer };\n","import { remove, resetBlazorTemplate, blazorTemplates, getValue } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { DataManager, Query, Deferred, Predicate, DataUtil } from '@syncfusion/ej2-data';\nimport { ValueFormatter } from '../services/value-formatter';\nimport { RenderType, CellType } from '../base/enum';\nimport { Data } from '../actions/data';\nimport { Column } from '../models/column';\nimport { Row } from '../models/row';\nimport { Cell } from '../models/cell';\nimport * as events from '../base/constant';\nimport { prepareColumns, setFormatter, isGroupAdaptive, getDatePredicate, getObject, clearReactVueTemplates } from '../base/util';\nimport { ContentRender } from '../renderer/content-renderer';\nimport { HeaderRender } from '../renderer/header-renderer';\nimport { CellRenderer } from '../renderer/cell-renderer';\nimport { HeaderCellRenderer } from '../renderer/header-cell-renderer';\nimport { StackedHeaderCellRenderer } from '../renderer/stacked-cell-renderer';\nimport { IndentCellRenderer } from '../renderer/indent-cell-renderer';\nimport { GroupCaptionCellRenderer, GroupCaptionEmptyCellRenderer } from '../renderer/caption-cell-renderer';\nimport { ExpandCellRenderer } from '../renderer/expand-cell-renderer';\nimport { HeaderIndentCellRenderer } from '../renderer/header-indent-renderer';\nimport { DetailHeaderIndentCellRenderer } from '../renderer/detail-header-indent-renderer';\nimport { DetailExpandCellRenderer } from '../renderer/detail-expand-cell-renderer';\nimport { RowDragDropRenderer } from './row-drag-drop-renderer';\nimport { RowDragDropHeaderRenderer } from '../renderer/row-drag-header-indent-render';\nimport * as literals from '../base/string-literals';\n/**\n * Content module is used to render grid content\n *\n * @hidden\n */\nvar Render = /** @class */ (function () {\n /**\n * Constructor for render module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {ServiceLocator} locator - specifies the serviceLocator\n */\n function Render(parent, locator) {\n this.emptyGrid = false;\n this.counter = 0;\n this.parent = parent;\n this.locator = locator;\n this.data = new Data(parent, locator);\n this.l10n = locator.getService('localization');\n this.ariaService = this.locator.getService('ariaService');\n this.renderer = this.locator.getService('rendererFactory');\n this.addEventListener();\n }\n /**\n * To initialize grid header, content and footer rendering\n *\n * @returns {void}\n */\n Render.prototype.render = function () {\n var gObj = this.parent;\n this.headerRenderer = this.renderer.getRenderer(RenderType.Header);\n this.contentRenderer = this.renderer.getRenderer(RenderType.Content);\n this.headerRenderer.renderPanel();\n this.contentRenderer.renderPanel();\n if (gObj.getColumns().length) {\n this.isLayoutRendered = true;\n this.headerRenderer.renderTable();\n this.contentRenderer.renderTable();\n this.emptyRow(false);\n }\n this.parent.scrollModule.setWidth();\n this.parent.scrollModule.setHeight();\n if (this.parent.height !== 'auto') {\n this.parent.scrollModule.setPadding();\n }\n this.refreshDataManager();\n };\n /**\n * Refresh the entire Grid.\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n */\n Render.prototype.refresh = function (e) {\n var _this = this;\n if (e === void 0) { e = { requestType: 'refresh' }; }\n var gObj = this.parent;\n gObj.notify(e.requestType + \"-begin\", e);\n gObj.trigger(events.actionBegin, e, function (args) {\n if (args === void 0) { args = { requestType: 'refresh' }; }\n if (args.cancel) {\n gObj.notify(events.cancelBegin, args);\n if (args.action === 'clearFilter' && _this.parent.filterSettings.type === 'Menu') {\n _this.parent.filterSettings.columns[_this.parent.filterModule.filterObjIndex] = _this.parent.filterModule.prevFilterObject;\n var iconClass = _this.parent.showColumnMenu && _this.parent.filterModule['column'].showColumnMenu ? '.e-columnmenu' : '.e-icon-filter';\n var col = _this.parent.element.querySelector('[e-mappinguid=\"' + _this.parent.filterModule['column'].uid + '\"]').parentElement;\n var flIcon = col.querySelector(iconClass);\n if (!isNullOrUndefined(_this.parent.filterModule.prevFilterObject)) {\n flIcon.classList.add('e-filtered');\n }\n }\n if (args.action === 'clear-filter' && (_this.parent.filterSettings.type === 'CheckBox' || _this.parent.filterSettings.type === 'Excel')) {\n _this.parent.filterSettings.columns = _this.parent.filterModule.checkboxPrevFilterObject;\n }\n if (args.requestType === 'grouping') {\n // Remove the dropped column name from groupsettings.columns if args.cancel is true \n var index = gObj.groupSettings.columns.indexOf(args.columnName);\n if (index !== -1) {\n gObj.setProperties({ groupSettings: { Columns: gObj.groupSettings.columns.splice(index, 1) } }, true);\n gObj.setProperties({ sortSettings: { Columns: gObj.sortSettings.columns.splice(index, 1) } }, true);\n var column = gObj.getColumnByField(args.columnName);\n var headerCell = gObj.getColumnHeaderByField(column.field);\n column.visible = (!isNullOrUndefined(headerCell) && !headerCell.classList.contains('e-hide'));\n }\n }\n return;\n }\n if (gObj.allowSelection && (args.action === 'clearFilter' || args.action === 'clear-filter' ||\n (args.requestType === 'searching' && args.searchString === '') || args.action === 'add')) {\n gObj.selectionModule['rmtHdrChkbxClicked'] = false;\n }\n if (gObj.allowPaging && gObj.pageSettings.pageSizes && gObj.pagerModule.pagerObj.isAllPage &&\n (args.action === 'add' && args.requestType === 'save') && gObj.pagerModule.pagerObj.checkAll) {\n gObj.setProperties({ pageSettings: { pageSize: gObj.pageSettings.pageSize + 1 } }, true);\n }\n if (args.requestType === 'delete' && gObj.allowPaging) {\n var dataLength = args.data.length;\n var count = gObj.pageSettings.totalRecordsCount - dataLength;\n var currentViewData = gObj.getCurrentViewRecords().length;\n // eslint-disable-next-line max-len\n if ((!(currentViewData - dataLength) && count && ((gObj.pageSettings.currentPage - 1) * gObj.pageSettings.pageSize) === count) || (count && count <= dataLength)) {\n gObj.prevPageMoving = true;\n gObj.setProperties({\n pageSettings: {\n totalRecordsCount: count, currentPage: Math.ceil(count / gObj.pageSettings.pageSize)\n }\n }, true);\n gObj.pagerModule.pagerObj.totalRecordsCount = count;\n }\n }\n if (args.requestType === 'reorder' && _this.parent.dataSource && 'result' in _this.parent.dataSource) {\n _this.contentRenderer.refreshContentRows(args);\n }\n else if ((args.requestType === 'paging' || args.requestType === 'columnstate' || args.requestType === 'reorder')\n && _this.parent.groupSettings.enableLazyLoading && _this.parent.groupSettings.columns.length\n && (_this.parent.enableVirtualization ? _this.parent.lazyLoadRender :\n _this.parent.contentModule).getGroupCache()[_this.parent.pageSettings.currentPage]) {\n _this.contentRenderer.refreshContentRows(args);\n }\n else {\n _this.refreshDataManager(args);\n }\n });\n };\n /**\n * @returns {void}\n * @hidden\n */\n Render.prototype.resetTemplates = function () {\n var gObj = this.parent;\n var gridColumns = gObj.getColumns();\n if (gObj.detailTemplate) {\n var detailTemplateID = gObj.element.id + 'detailTemplate';\n blazorTemplates[\"\" + detailTemplateID] = [];\n resetBlazorTemplate(detailTemplateID, 'DetailTemplate');\n }\n if (gObj.groupSettings.captionTemplate) {\n resetBlazorTemplate(gObj.element.id + 'captionTemplate', 'CaptionTemplate');\n }\n if (gObj.rowTemplate) {\n resetBlazorTemplate(gObj.element.id + 'rowTemplate', 'RowTemplate');\n }\n if (gObj.toolbarTemplate) {\n resetBlazorTemplate(gObj.element.id + 'toolbarTemplate', 'ToolbarTemplate');\n }\n if (gObj.pageSettings.template) {\n resetBlazorTemplate(gObj.element.id + '_template', 'pageSettings');\n }\n for (var i = 0; i < gridColumns.length; i++) {\n if (gridColumns[parseInt(i.toString(), 10)].template) {\n blazorTemplates[gObj.element.id + gridColumns[parseInt(i.toString(), 10)].uid] = [];\n resetBlazorTemplate(gObj.element.id + gridColumns[parseInt(i.toString(), 10)].uid, 'Template');\n }\n if (gridColumns[parseInt(i.toString(), 10)].headerTemplate) {\n resetBlazorTemplate(gObj.element.id + gridColumns[parseInt(i.toString(), 10)].uid + 'headerTemplate', 'HeaderTemplate');\n }\n if (gridColumns[parseInt(i.toString(), 10)].filterTemplate) {\n resetBlazorTemplate(gObj.element.id + gridColumns[parseInt(i.toString(), 10)].uid + 'filterTemplate', 'FilterTemplate');\n }\n }\n var guid = 'guid';\n for (var k = 0; k < gObj.aggregates.length; k++) {\n for (var j = 0; j < gObj.aggregates[parseInt(k.toString(), 10)].columns.length; j++) {\n if (gObj.aggregates[parseInt(k.toString(), 10)].columns[parseInt(j.toString(), 10)].footerTemplate) {\n var tempID = gObj.element.id + gObj.aggregates[parseInt(k.toString(), 10)].columns[parseInt(j.toString(), 10)][\"\" + guid] + 'footerTemplate';\n resetBlazorTemplate(tempID, 'FooterTemplate');\n }\n if (gObj.aggregates[parseInt(k.toString(), 10)].columns[parseInt(j.toString(), 10)].groupFooterTemplate) {\n var tempID = gObj.element.id + gObj.aggregates[parseInt(k.toString(), 10)].columns[parseInt(j.toString(), 10)][\"\" + guid] + 'groupFooterTemplate';\n resetBlazorTemplate(tempID, 'GroupFooterTemplate');\n }\n if (gObj.aggregates[parseInt(k.toString(), 10)].columns[parseInt(j.toString(), 10)].groupCaptionTemplate) {\n var tempID = gObj.element.id + gObj.aggregates[parseInt(k.toString(), 10)].columns[parseInt(j.toString(), 10)][\"\" + guid] + 'groupCaptionTemplate';\n resetBlazorTemplate(tempID, 'GroupCaptionTemplate');\n }\n }\n }\n };\n Render.prototype.refreshComplete = function (e) {\n this.parent.trigger(events.actionComplete, e);\n };\n /**\n * The function is used to refresh the dataManager\n *\n * @param {NotifyArgs} args - specifies the args\n * @returns {void}\n */\n Render.prototype.refreshDataManager = function (args) {\n var _this = this;\n if (args === void 0) { args = {}; }\n var gObj = this.parent;\n var maskRow = (gObj.loadingIndicator.indicatorType === 'Shimmer' && args.requestType !== 'virtualscroll'\n && args.requestType !== 'infiniteScroll') || ((args.requestType === 'virtualscroll' || args.requestType === 'infiniteScroll')\n && gObj.enableVirtualMaskRow);\n if (args.requestType !== 'virtualscroll' && !args.isCaptionCollapse && !maskRow) {\n this.parent.showSpinner();\n }\n if (maskRow) {\n gObj.showMaskRow(args.requestType === 'virtualscroll' ? args.virtualInfo.sentinelInfo.axis\n : args.requestType === 'infiniteScroll' ? args.direction : undefined);\n }\n this.parent.notify(events.resetInfiniteBlocks, args);\n this.emptyGrid = false;\n var dataManager;\n var isFActon = this.isNeedForeignAction();\n this.ariaService.setBusy(this.parent.getContent().querySelector('.' + literals.content), true);\n if (isFActon) {\n var deffered = new Deferred();\n dataManager = this.getFData(deffered, args);\n }\n if (!dataManager) {\n if (gObj.allowPaging && !gObj.getDataModule().dataManager.dataSource.offline && gObj.pageSettings\n && gObj.pageSettings.pageSizes && gObj.pagerModule && gObj.pagerModule.pagerObj && gObj.pagerModule.pagerObj.isAllPage) {\n gObj.pagerModule.pagerObj.isAllPage = undefined;\n }\n dataManager = this.data.getData(args, this.data.generateQuery().requiresCount());\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n dataManager = dataManager.then(function (e) {\n var query = _this.data.generateQuery().requiresCount();\n if (_this.emptyGrid) {\n var def = new Deferred();\n def.resolve({ result: [], count: 0 });\n return def.promise;\n }\n return _this.data.getData(args, query);\n });\n }\n if (this.parent.getForeignKeyColumns().length && (!isFActon || this.parent.searchSettings.key.length)) {\n var deffered_1 = new Deferred();\n dataManager = dataManager.then(function (e) {\n _this.parent.notify(events.getForeignKeyData, { dataManager: dataManager, result: e, promise: deffered_1, action: args });\n return deffered_1.promise;\n });\n }\n if (this.parent.groupSettings.disablePageWiseAggregates && this.parent.groupSettings.columns.length) {\n dataManager = dataManager.then(function (e) { return _this.validateGroupRecords(e); });\n }\n dataManager.then(function (e) { return _this.dataManagerSuccess(e, args); })\n .catch(function (e) { return _this.dataManagerFailure(e, args); });\n };\n Render.prototype.getFData = function (deferred, args) {\n this.parent.notify(events.getForeignKeyData, { isComplex: true, promise: deferred, action: args });\n return deferred.promise;\n };\n Render.prototype.isNeedForeignAction = function () {\n var gObj = this.parent;\n return !!((gObj.allowFiltering && gObj.filterSettings.columns.length) ||\n (gObj.searchSettings.key.length)) && this.foreignKey(this.parent.getForeignKeyColumns());\n };\n Render.prototype.foreignKey = function (columns) {\n var _this = this;\n return columns.some(function (col) {\n var fbool = false;\n fbool = _this.parent.filterSettings.columns.some(function (value) {\n return col.uid === value.uid;\n });\n return !!(fbool || _this.parent.searchSettings.key.length);\n });\n };\n Render.prototype.sendBulkRequest = function (args) {\n var _this = this;\n args.requestType = 'batchsave';\n var gObj = this.parent;\n if (gObj.allowPaging && gObj.pageSettings.pageSizes && gObj.pagerModule.pagerObj.isAllPage && gObj.pagerModule.pagerObj.checkAll) {\n var dataLength = args['changes'].addedRecords.length;\n if (dataLength) {\n gObj.setProperties({ pageSettings: { pageSize: gObj.pageSettings.pageSize + dataLength } }, true);\n }\n }\n if (gObj.allowPaging && (args.changes.addedRecords.length ||\n args.changes.deletedRecords.length ||\n args.changes.changedRecords.length) && gObj.pageSettings\n && gObj.pageSettings.pageSizes && gObj.pagerModule && gObj.pagerModule.pagerObj\n && !gObj.getDataModule().dataManager.dataSource.offline && gObj.pagerModule.pagerObj.isAllPage) {\n gObj.pagerModule.pagerObj.isAllPage = undefined;\n }\n var promise = this.data.saveChanges(args.changes, this.parent.getPrimaryKeyFieldNames()[0], args.original);\n var query = this.data.generateQuery().requiresCount();\n if (this.data.dataManager.dataSource.offline) {\n this.refreshDataManager({ requestType: 'batchsave' });\n return;\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n promise.then(function (e) {\n _this.data.getData(args, query)\n .then(function (e) { return _this.dmSuccess(e, args); })\n .catch(function (e) { return _this.dmFailure(e, args); });\n })\n .catch(function (e) { return _this.dmFailure(e, args); });\n }\n };\n Render.prototype.dmSuccess = function (e, args) {\n this.dataManagerSuccess(e, args);\n };\n Render.prototype.dmFailure = function (e, args) {\n this.dataManagerFailure(e, args);\n };\n /**\n * Render empty row to Grid which is used at the time to represent to no records.\n *\n * @returns {void}\n * @hidden\n */\n Render.prototype.renderEmptyRow = function () {\n this.emptyRow(true);\n };\n Render.prototype.emptyRow = function (isTrigger) {\n var gObj = this.parent;\n var tbody = this.contentRenderer.getTable().querySelector(literals.tbody);\n if (!isNullOrUndefined(tbody)) {\n remove(tbody);\n }\n tbody = this.parent.createElement(literals.tbody, { attrs: { role: 'rowgroup' } });\n var spanCount = gObj.allowRowDragAndDrop && isNullOrUndefined(gObj.rowDropSettings.targetID) ? 1 : 0;\n if (gObj.detailTemplate || gObj.childGrid) {\n ++spanCount;\n }\n var tr = this.parent.createElement('tr', { className: 'e-emptyrow', attrs: { role: 'row' } });\n var td;\n if (gObj.emptyRecordTemplate) {\n var emptyRecordTemplateID = gObj.element.id + 'emptyRecordTemplate';\n td = this.parent.createElement('td', { attrs: { colspan: (gObj.getVisibleColumns().length + spanCount + gObj.groupSettings.columns.length).toString() } });\n if (gObj.isVue) {\n td.appendChild(gObj.getEmptyRecordTemplate()(gObj.dataSource, gObj, 'emptyRecordTemplate', emptyRecordTemplateID, undefined, undefined, undefined, this.parent['root'])[1]);\n }\n else {\n td.appendChild(gObj.getEmptyRecordTemplate()(gObj.dataSource, gObj, 'emptyRecordTemplate', emptyRecordTemplateID, undefined, undefined, undefined, this.parent['root'])[0]);\n }\n if (gObj.isReact) {\n this.parent.renderTemplates();\n }\n }\n else {\n td = this.parent.createElement('td', {\n innerHTML: this.l10n.getConstant('EmptyRecord'),\n attrs: { colspan: (gObj.getVisibleColumns().length + spanCount + gObj.groupSettings.columns.length).toString() }\n });\n }\n if (gObj.isFrozenGrid()) {\n td.classList.add('e-leftfreeze');\n td.style.left = 0 + 'px';\n }\n if (gObj.frozenRows && gObj.element.querySelector('.e-frozenrow-border')) {\n this.parent.element.querySelector('.e-frozenrow-border').classList.add('e-frozenrow-empty');\n }\n tr.appendChild(td);\n tbody.appendChild(tr);\n this.contentRenderer.renderEmpty(tbody);\n if (isTrigger) {\n this.parent.trigger(events.dataBound, {});\n this.parent.notify(events.onEmpty, { rows: [new Row({ isDataRow: true, cells: [new Cell({ isDataCell: true, visible: true })] })] });\n }\n };\n Render.prototype.dynamicColumnChange = function () {\n if (this.parent.getCurrentViewRecords().length) {\n this.updateColumnType(this.parent.getCurrentViewRecords()[0]);\n }\n };\n Render.prototype.updateColumnType = function (record) {\n var columns = this.parent.getColumns();\n var value;\n var cFormat = 'customFormat';\n var equalTo = 'equalTo';\n var data = record && record.items ? record.items[0] : record;\n var fmtr = this.locator.getService('valueFormatter');\n for (var i = 0, len = columns.length; i < len; i++) {\n value = getObject(columns[parseInt(i.toString(), 10)].field || '', data);\n if (!isNullOrUndefined(columns[parseInt(i.toString(), 10)][\"\" + cFormat])) {\n columns[parseInt(i.toString(), 10)].format = columns[parseInt(i.toString(), 10)][\"\" + cFormat];\n }\n if (!isNullOrUndefined(columns[parseInt(i.toString(), 10)].validationRules)\n && !isNullOrUndefined(columns[parseInt(i.toString(), 10)].validationRules[\"\" + equalTo])) {\n columns[parseInt(i.toString(), 10)].validationRules[\"\" + equalTo][0] = this.parent.element.id + columns[parseInt(i.toString(), 10)].validationRules[\"\" + equalTo][0];\n }\n if (columns[parseInt(i.toString(), 10)].isForeignColumn() && columns[parseInt(i.toString(), 10)].columnData) {\n value = getObject(columns[parseInt(i.toString(), 10)].foreignKeyValue || '', columns[parseInt(i.toString(), 10)].columnData[0]);\n }\n if (!isNullOrUndefined(value)) {\n this.isColTypeDef = true;\n if (!columns[parseInt(i.toString(), 10)].type) {\n columns[parseInt(i.toString(), 10)].type = value.getDay ? (value.getHours() > 0 || value.getMinutes() > 0 ||\n value.getSeconds() > 0 || value.getMilliseconds() > 0 ? 'datetime' : 'date') : typeof (value);\n }\n }\n else {\n columns[parseInt(i.toString(), 10)].type = columns[parseInt(i.toString(), 10)].type || null;\n }\n var valueFormatter = new ValueFormatter();\n if (columns[parseInt(i.toString(), 10)].format && (columns[parseInt(i.toString(), 10)].format.skeleton\n || (columns[parseInt(i.toString(), 10)].format.format &&\n typeof columns[parseInt(i.toString(), 10)].format.format === 'string'))) {\n columns[parseInt(i.toString(), 10)].setFormatter(valueFormatter.getFormatFunction(extend({}, columns[parseInt(i.toString(), 10)].format)));\n columns[parseInt(i.toString(), 10)].setParser(valueFormatter.getParserFunction(columns[parseInt(i.toString(), 10)].format));\n }\n if (typeof (columns[parseInt(i.toString(), 10)].format) === 'string') {\n setFormatter(this.locator, columns[parseInt(i.toString(), 10)]);\n }\n else if (!columns[parseInt(i.toString(), 10)].format && columns[parseInt(i.toString(), 10)].type === 'number') {\n columns[parseInt(i.toString(), 10)].setParser(fmtr.getParserFunction({ format: 'n2' }));\n }\n if (columns[parseInt(i.toString(), 10)].type === 'dateonly' && !columns[parseInt(i.toString(), 10)].format) {\n columns[parseInt(i.toString(), 10)].format = 'yMd';\n setFormatter(this.locator, columns[parseInt(i.toString(), 10)]);\n }\n }\n };\n /**\n * @param {ReturnType} e - specifies the return type\n * @param {NotifyArgs} args - specifies the Notifyargs\n * @returns {void}\n * @hidden\n */\n // tslint:disable-next-line:max-func-body-length\n Render.prototype.dataManagerSuccess = function (e, args) {\n var _this = this;\n var gObj = this.parent;\n this.contentRenderer = this.renderer.getRenderer(RenderType.Content);\n this.headerRenderer = this.renderer.getRenderer(RenderType.Header);\n e.actionArgs = args;\n var isInfiniteDelete = this.parent.enableInfiniteScrolling && !this.parent.infiniteScrollSettings.enableCache &&\n !gObj.groupSettings.enableLazyLoading && (args.requestType === 'delete' || (args.requestType === 'save' &&\n this.parent.infiniteScrollModule.requestType === 'add' && !(gObj.sortSettings.columns.length ||\n gObj.filterSettings.columns.length || this.parent.groupSettings.columns.length || gObj.searchSettings.key)));\n // tslint:disable-next-line:max-func-body-length\n gObj.trigger(events.beforeDataBound, e, function (dataArgs) {\n if (dataArgs.cancel) {\n return;\n }\n dataArgs.result = isNullOrUndefined(dataArgs.result) ? [] : dataArgs.result;\n var len = Object.keys(dataArgs.result).length;\n if (_this.parent.isDestroyed) {\n return;\n }\n if ((!gObj.getColumns().length && !len) && !(gObj.columns.length && gObj.columns[0] instanceof Column)) {\n gObj.hideSpinner();\n return;\n }\n if (_this.isInfiniteEnd(args) && !len) {\n _this.parent.notify(events.infiniteEditHandler, { e: args, result: e.result, count: e.count, agg: e.aggregates });\n return;\n }\n _this.parent.isEdit = false;\n _this.parent.notify(events.editReset, {});\n _this.parent.notify(events.tooltipDestroy, {});\n if (args && args.requestType !== 'infiniteScroll') {\n _this.parent.notify(events.commandColumnDestroy, { type: 'refreshCommandColumn' });\n }\n _this.contentRenderer.prevCurrentView = _this.parent.currentViewData.slice();\n gObj.currentViewData = dataArgs.result;\n gObj.notify(events.refreshInfiniteCurrentViewData, { args: args, data: dataArgs.result });\n if (dataArgs.count && !gObj.allowPaging && (gObj.enableVirtualization || gObj.enableInfiniteScrolling)) {\n gObj.totalDataRecordsCount = dataArgs.count;\n }\n if (!len && dataArgs.count && gObj.allowPaging && args && args.requestType !== 'delete') {\n if (_this.parent.groupSettings.enableLazyLoading\n && (args.requestType === 'grouping' || args.requestType === 'ungrouping')) {\n _this.parent.notify(events.groupComplete, args);\n }\n gObj.prevPageMoving = true;\n gObj.pageSettings.totalRecordsCount = dataArgs.count;\n if (args.requestType !== 'paging') {\n gObj.pageSettings.currentPage = Math.ceil(dataArgs.count / gObj.pageSettings.pageSize);\n }\n gObj.dataBind();\n return;\n }\n if ((!gObj.getColumns().length && len || !_this.isLayoutRendered) && !isGroupAdaptive(gObj)) {\n gObj.removeMaskRow();\n _this.updatesOnInitialRender(dataArgs);\n }\n if (!_this.isColTypeDef && gObj.getCurrentViewRecords()) {\n if (_this.data.dataManager.dataSource.offline && gObj.dataSource && gObj.dataSource.length) {\n _this.updateColumnType(gObj.dataSource[0]);\n }\n else {\n _this.updateColumnType(gObj.getCurrentViewRecords()[0]);\n }\n }\n if (!_this.parent.isInitialLoad && _this.parent.groupSettings.disablePageWiseAggregates &&\n !_this.parent.groupSettings.columns.length) {\n dataArgs.result = _this.parent.dataSource instanceof Array ? _this.parent.dataSource : _this.parent.currentViewData;\n }\n if ((_this.parent.isReact || _this.parent.isVue) && !isNullOrUndefined(args) && args.requestType !== 'infiniteScroll' && !args.isFrozen) {\n clearReactVueTemplates(_this.parent, ['footerTemplate']);\n }\n if (_this.parent.isAngular && _this.parent.allowGrouping && _this.parent.groupSettings.captionTemplate\n && !(!isNullOrUndefined(args) && args.requestType === 'infiniteScroll')) {\n _this.parent.destroyTemplate(['groupSettings_captionTemplate']);\n }\n _this.parent.notify(events.dataReady, extend({ count: dataArgs.count, result: dataArgs.result, aggregates: dataArgs.aggregates }, args));\n if ((gObj.groupSettings.columns.length || (args && args.requestType === 'ungrouping'))\n && (args && args.requestType !== 'filtering')) {\n _this.headerRenderer.refreshUI();\n }\n if (len) {\n if (isGroupAdaptive(gObj)) {\n var content = 'content';\n args.scrollTop = { top: _this.contentRenderer[\"\" + content].scrollTop };\n }\n if (!isInfiniteDelete) {\n if (_this.parent.enableImmutableMode) {\n _this.contentRenderer.immutableModeRendering(args);\n }\n else {\n _this.contentRenderer.refreshContentRows(args);\n }\n }\n else {\n _this.parent.notify(events.infiniteEditHandler, { e: args, result: e.result, count: e.count, agg: e.aggregates });\n }\n }\n else {\n if (args && args.isCaptionCollapse) {\n return;\n }\n if (!gObj.getColumns().length) {\n gObj.element.innerHTML = '';\n alert(_this.l10n.getConstant('EmptyDataSourceError')); //ToDO: change this alert as dialog\n return;\n }\n _this.contentRenderer.setRowElements([]);\n _this.contentRenderer.setRowObjects([]);\n _this.ariaService.setBusy(_this.parent.getContent().querySelector('.' + literals.content), false);\n gObj.removeMaskRow();\n _this.renderEmptyRow();\n if (gObj.enableColumnVirtualization && !len) {\n _this.parent.notify(events.contentReady, { rows: gObj.getRowsObject(), args: {} });\n }\n if (args) {\n var action = (args.requestType || '').toLowerCase() + '-complete';\n _this.parent.notify(action, args);\n if (args.requestType === 'batchsave') {\n args.cancel = false;\n args.rows = [];\n args.isFrozen = !args.isFrozen;\n _this.parent.trigger(events.actionComplete, args);\n }\n }\n if (_this.parent.autoFit) {\n _this.parent.preventAdjustColumns();\n }\n _this.parent.hideSpinner();\n }\n _this.parent.notify(events.toolbarRefresh, {});\n _this.setRowCount(_this.parent.getCurrentViewRecords().length);\n if ('query' in e) {\n _this.parent.getDataModule().isQueryInvokedFromData = false;\n }\n });\n };\n /**\n * @param {object} e - specifies the object\n * @param {Object[]} e.result - specifies the result\n * @param {NotifyArgs} args - specifies the args\n * @returns {void}\n * @hidden\n */\n Render.prototype.dataManagerFailure = function (e, args) {\n if (!isNullOrUndefined(this.parent.contentModule)) {\n this.ariaService.setOptions(this.parent.getContent().querySelector('.' + literals.content), { busy: false, invalid: true });\n this.setRowCount(1);\n }\n this.parent.trigger(events.actionFailure, { error: e });\n this.parent.hideSpinner();\n this.parent.removeMaskRow();\n if (args.requestType === 'save' || args.requestType === 'delete'\n || args.name === 'bulk-save') {\n return;\n }\n this.parent.currentViewData = [];\n this.renderEmptyRow();\n if (!this.parent.isInitialLoad) {\n this.parent.focusModule.setFirstFocusableTabIndex();\n }\n this.parent.log('actionfailure', { error: e });\n };\n Render.prototype.setRowCount = function (dataRowCount) {\n this.ariaService.setOptions(this.parent.element, {\n rowcount: dataRowCount ? dataRowCount.toString() : '1'\n });\n };\n Render.prototype.isInfiniteEnd = function (args) {\n return this.parent.enableInfiniteScrolling && !this.parent.infiniteScrollSettings.enableCache && args.requestType === 'delete';\n };\n Render.prototype.updatesOnInitialRender = function (e) {\n this.isLayoutRendered = true;\n var isEmptyCol = false;\n if (this.parent.columns.length < 1) {\n this.buildColumns(e.result[0]);\n isEmptyCol = true;\n }\n prepareColumns(this.parent.columns, null, this.parent);\n if (isEmptyCol) {\n this.parent.notify(events.refreshSplitFrozenColumn, {});\n }\n this.headerRenderer.renderTable();\n this.contentRenderer.renderTable();\n this.parent.isAutoGen = true;\n this.parent.notify(events.autoCol, {});\n };\n Render.prototype.iterateComplexColumns = function (obj, field, split) {\n var keys = Object.keys(obj);\n for (var i = 0; i < keys.length; i++) {\n var childKeys = typeof obj[keys[parseInt(i.toString(), 10)]] === 'object'\n && obj[keys[parseInt(i.toString(), 10)]] && !(obj[keys[parseInt(i.toString(), 10)]] instanceof Date) ?\n Object.keys(obj[keys[parseInt(i.toString(), 10)]]) : [];\n if (childKeys.length) {\n this.iterateComplexColumns(obj[keys[parseInt(i.toString(), 10)]], field + (keys[parseInt(i.toString(), 10)] + '.'), split);\n }\n else {\n split[this.counter] = field + keys[parseInt(i.toString(), 10)];\n this.counter++;\n }\n }\n };\n Render.prototype.buildColumns = function (record) {\n var cols = [];\n var complexCols = {};\n this.iterateComplexColumns(record, '', complexCols);\n var columns = Object.keys(complexCols).filter(function (e) { return complexCols[\"\" + e] !== 'BlazId'; }).\n map(function (field) { return complexCols[\"\" + field]; });\n for (var i = 0, len = columns.length; i < len; i++) {\n cols[parseInt(i.toString(), 10)] = { 'field': columns[parseInt(i.toString(), 10)] };\n if (this.parent.enableColumnVirtualization) {\n cols[parseInt(i.toString(), 10)].width = !isNullOrUndefined(cols[parseInt(i.toString(), 10)].width) ?\n cols[parseInt(i.toString(), 10)].width : 200;\n }\n }\n this.parent.setProperties({ 'columns': cols }, true);\n };\n Render.prototype.instantiateRenderer = function () {\n this.renderer.addRenderer(RenderType.Header, new HeaderRender(this.parent, this.locator));\n this.renderer.addRenderer(RenderType.Content, new ContentRender(this.parent, this.locator));\n var cellrender = this.locator.getService('cellRendererFactory');\n cellrender.addCellRenderer(CellType.Header, new HeaderCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.Data, new CellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.StackedHeader, new StackedHeaderCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.Indent, new IndentCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.GroupCaption, new GroupCaptionCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.GroupCaptionEmpty, new GroupCaptionEmptyCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.Expand, new ExpandCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.HeaderIndent, new HeaderIndentCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.StackedHeader, new StackedHeaderCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.DetailHeader, new DetailHeaderIndentCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.RowDragHIcon, new RowDragDropHeaderRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.DetailExpand, new DetailExpandCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.DetailFooterIntent, new IndentCellRenderer(this.parent, this.locator));\n cellrender.addCellRenderer(CellType.RowDragIcon, new RowDragDropRenderer(this.parent, this.locator));\n };\n Render.prototype.addEventListener = function () {\n var _this = this;\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.initialLoad, this.instantiateRenderer, this);\n this.parent.on('refreshdataSource', this.dataManagerSuccess, this);\n this.parent.on(events.modelChanged, this.refresh, this);\n this.parent.on(events.refreshComplete, this.refreshComplete, this);\n this.parent.on(events.bulkSave, this.sendBulkRequest, this);\n this.parent.on(events.showEmptyGrid, function () { _this.emptyGrid = true; }, this);\n this.parent.on(events.autoCol, this.dynamicColumnChange, this);\n };\n /**\n * @param {ReturnType} e - specifies the Return type\n * @returns {Promise<Object>} returns the object\n * @hidden\n */\n Render.prototype.validateGroupRecords = function (e) {\n var _this = this;\n var index = e.result.length - 1;\n if (index < 0) {\n return Promise.resolve(e);\n }\n var group0 = e.result[0];\n var groupN = e.result[parseInt(index.toString(), 10)];\n var predicate = [];\n var addWhere = function (input) {\n var groups = [group0, groupN];\n for (var i = 0; i < groups.length; i++) {\n predicate.push(new Predicate('field', '==', groups[parseInt(i.toString(), 10)].field).and(_this.getPredicate('key', 'equal', groups[parseInt(i.toString(), 10)].key)));\n }\n input.where(Predicate.or(predicate));\n };\n var query = new Query();\n addWhere(query);\n var curDm = new DataManager(e.result);\n var curFilter = curDm.executeLocal(query);\n var newQuery = this.data.generateQuery(true);\n var rPredicate = [];\n if (this.data.isRemote()) {\n var groups = [group0, groupN];\n for (var i = 0; i < groups.length; i++) {\n rPredicate.push(this.getPredicate(groups[parseInt(i.toString(), 10)].field, 'equal', groups[parseInt(i.toString(), 10)].key));\n }\n newQuery.where(Predicate.or(rPredicate));\n }\n else {\n addWhere(newQuery);\n }\n var deferred = new Deferred();\n this.data.getData({}, newQuery).then(function (r) {\n _this.updateGroupInfo(curFilter, r.result);\n deferred.resolve(e);\n }).catch(function (e) { return deferred.reject(e); });\n return deferred.promise;\n };\n Render.prototype.getPredicate = function (key, operator, value) {\n if (value instanceof Date) {\n return getDatePredicate({ field: key, operator: operator, value: value });\n }\n return new Predicate(key, operator, value);\n };\n Render.prototype.updateGroupInfo = function (current, untouched) {\n var dm = new DataManager(untouched);\n var elements = current;\n for (var i = 0; i < elements.length; i++) {\n var uGroup = dm.executeLocal(new Query()\n .where(new Predicate('field', '==', elements[parseInt(i.toString(), 10)].field).and(this.getPredicate('key', 'equal', elements[parseInt(i.toString(), 10)].key))))[0];\n elements[parseInt(i.toString(), 10)].count = uGroup.count;\n var itemGroup = elements[parseInt(i.toString(), 10)].items;\n var uGroupItem = uGroup.items;\n if (itemGroup.GroupGuid) {\n elements[parseInt(i.toString(), 10)].items =\n this.updateGroupInfo(elements[parseInt(i.toString(), 10)].items, uGroup.items);\n }\n var rows = this.parent.aggregates;\n for (var j = 0; j < rows.length; j++) {\n var row = rows[parseInt(j.toString(), 10)];\n for (var k = 0; k < row.columns.length; k++) {\n var types = row.columns[parseInt(k.toString(), 10)].type instanceof Array ?\n (row.columns[parseInt(k.toString(), 10)].type) :\n [(row.columns[parseInt(k.toString(), 10)].type)];\n for (var l = 0; l < types.length; l++) {\n var key = row.columns[parseInt(k.toString(), 10)].field + ' - ' + types[parseInt(l.toString(), 10)].toLowerCase();\n var data = itemGroup.level ? uGroupItem.records : uGroup.items;\n var context = this.parent;\n if (types[parseInt(l.toString(), 10)] === 'Custom') {\n var data_1 = itemGroup.level ? uGroupItem : uGroup;\n var temp = row.columns[parseInt(k.toString(), 10)]\n .customAggregate;\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n }\n elements[parseInt(i.toString(), 10)].aggregates[\"\" + key] = temp ? temp.call(context, data_1, row.columns[parseInt(k.toString(), 10)]) : '';\n }\n else {\n elements[parseInt(i.toString(), 10)].aggregates[\"\" + key] = DataUtil.aggregates[types[parseInt(l.toString(), 10)].toLowerCase()](data, row.columns[parseInt(k.toString(), 10)].field);\n }\n }\n }\n }\n }\n return current;\n };\n return Render;\n}());\nexport { Render };\n","import { isNullOrUndefined, getEnumValue } from '@syncfusion/ej2-base';\nimport { CellType } from '../base/enum';\n/**\n * CellRendererFactory\n *\n * @hidden\n */\nvar CellRendererFactory = /** @class */ (function () {\n function CellRendererFactory() {\n this.cellRenderMap = {};\n }\n CellRendererFactory.prototype.addCellRenderer = function (name, type) {\n name = typeof name === 'string' ? name : getEnumValue(CellType, name);\n if (isNullOrUndefined(this.cellRenderMap[\"\" + name])) {\n this.cellRenderMap[\"\" + name] = type;\n }\n };\n CellRendererFactory.prototype.getCellRenderer = function (name) {\n name = typeof name === 'string' ? name : getEnumValue(CellType, name);\n if (isNullOrUndefined(this.cellRenderMap[\"\" + name])) {\n // eslint-disable-next-line no-throw-literal\n throw \"The cellRenderer \" + name + \" is not found\";\n }\n else {\n return this.cellRenderMap[\"\" + name];\n }\n };\n return CellRendererFactory;\n}());\nexport { CellRendererFactory };\n","import { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { ResponsiveDialogRenderer } from '../renderer/responsive-dialog-renderer';\n/**\n * ServiceLocator\n *\n * @hidden\n */\nvar ServiceLocator = /** @class */ (function () {\n function ServiceLocator() {\n this.services = {};\n }\n ServiceLocator.prototype.register = function (name, type) {\n if (isNullOrUndefined(this.services[\"\" + name])) {\n this.services[\"\" + name] = type;\n }\n };\n ServiceLocator.prototype.getService = function (name) {\n if (isNullOrUndefined(this.services[\"\" + name])) {\n // eslint-disable-next-line no-throw-literal\n throw \"The service \" + name + \" is not registered\";\n }\n return this.services[\"\" + name];\n };\n ServiceLocator.prototype.registerAdaptiveService = function (type, isAdaptiveUI, action) {\n if (isAdaptiveUI) {\n type.responsiveDialogRenderer = new ResponsiveDialogRenderer(type.parent, type.serviceLocator);\n type.responsiveDialogRenderer.action = action;\n }\n else {\n if (type.responsiveDialogRenderer) {\n type.responsiveDialogRenderer.removeEventListener();\n type.responsiveDialogRenderer = undefined;\n }\n }\n };\n return ServiceLocator;\n}());\nexport { ServiceLocator };\n","import { isNullOrUndefined, getEnumValue } from '@syncfusion/ej2-base';\nimport { RenderType } from '../base/enum';\n/**\n * RendererFactory\n *\n * @hidden\n */\nvar RendererFactory = /** @class */ (function () {\n function RendererFactory() {\n this.rendererMap = {};\n }\n RendererFactory.prototype.addRenderer = function (name, type) {\n var rName = getEnumValue(RenderType, name);\n if (isNullOrUndefined(this.rendererMap[\"\" + rName])) {\n this.rendererMap[\"\" + rName] = type;\n }\n };\n RendererFactory.prototype.getRenderer = function (name) {\n var rName = getEnumValue(RenderType, name);\n if (isNullOrUndefined(this.rendererMap[\"\" + rName])) {\n // eslint-disable-next-line no-throw-literal\n throw \"The renderer \" + rName + \" is not found\";\n }\n else {\n return this.rendererMap[\"\" + rName];\n }\n };\n return RendererFactory;\n}());\nexport { RendererFactory };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Property, ChildProperty } from '@syncfusion/ej2-base';\n/**\n * Configures the paging behavior of the Grid.\n */\nvar PageSettings = /** @class */ (function (_super) {\n __extends(PageSettings, _super);\n function PageSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(12)\n ], PageSettings.prototype, \"pageSize\", void 0);\n __decorate([\n Property(8)\n ], PageSettings.prototype, \"pageCount\", void 0);\n __decorate([\n Property(1)\n ], PageSettings.prototype, \"currentPage\", void 0);\n __decorate([\n Property()\n ], PageSettings.prototype, \"totalRecordsCount\", void 0);\n __decorate([\n Property(false)\n ], PageSettings.prototype, \"enableQueryString\", void 0);\n __decorate([\n Property(false)\n ], PageSettings.prototype, \"pageSizes\", void 0);\n __decorate([\n Property(null)\n ], PageSettings.prototype, \"template\", void 0);\n return PageSettings;\n}(ChildProperty));\nexport { PageSettings };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Property, ChildProperty } from '@syncfusion/ej2-base';\n/**\n * Configures the column chooser behavior of the Grid.\n */\nvar ColumnChooserSettings = /** @class */ (function (_super) {\n __extends(ColumnChooserSettings, _super);\n function ColumnChooserSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('startsWith')\n ], ColumnChooserSettings.prototype, \"operator\", void 0);\n __decorate([\n Property(false)\n ], ColumnChooserSettings.prototype, \"ignoreAccent\", void 0);\n return ColumnChooserSettings;\n}(ChildProperty));\nexport { ColumnChooserSettings };\n","import { extend, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport * as events from '../base/constant';\nimport { isActionPrevent } from '../base/util';\n/**\n * The `Search` module is used to handle search action.\n */\nvar Search = /** @class */ (function () {\n /**\n * Constructor for Grid search module.\n *\n * @param {IGrid} parent - specifies the IGrid\n * @hidden\n */\n function Search(parent) {\n this.parent = parent;\n this.addEventListener();\n }\n /**\n * Searches Grid records by given key.\n *\n * > You can customize the default search action by using [`searchSettings`](./searchsettings/).\n *\n * @param {string} searchString - Defines the key.\n * @returns {void}\n */\n Search.prototype.search = function (searchString) {\n var gObj = this.parent;\n searchString = isNullOrUndefined(searchString) ? '' : searchString;\n if (isActionPrevent(gObj)) {\n gObj.notify(events.preventBatch, { instance: this, handler: this.search, arg1: searchString });\n return;\n }\n if (searchString !== gObj.searchSettings.key) {\n // Check searchString is decimal or integer and parseFloat to remove trailing zeros\n /* eslint-disable-next-line */\n gObj.searchSettings.key = /^\\d+(\\.\\d+)?$/.test(searchString) ? parseFloat(searchString).toString() : searchString.toString();\n gObj.dataBind();\n }\n else if (this.refreshSearch) {\n gObj.refresh();\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Search.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.inBoundModelChanged, this.onPropertyChanged, this);\n this.parent.on(events.searchComplete, this.onSearchComplete, this);\n this.parent.on(events.destroy, this.destroy, this);\n this.actionCompleteFunc = this.onActionComplete.bind(this);\n this.parent.addEventListener(events.actionComplete, this.actionCompleteFunc);\n this.parent.on(events.cancelBegin, this.cancelBeginEvent, this);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Search.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.inBoundModelChanged, this.onPropertyChanged);\n this.parent.off(events.searchComplete, this.onSearchComplete);\n this.parent.off(events.destroy, this.destroy);\n this.parent.removeEventListener(events.actionComplete, this.actionCompleteFunc);\n this.parent.off(events.cancelBegin, this.cancelBeginEvent);\n };\n /**\n * To destroy the print\n *\n * @returns {void}\n * @hidden\n */\n Search.prototype.destroy = function () {\n this.removeEventListener();\n };\n /**\n * @param {NotifyArgs} e - specfies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Search.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName()) {\n return;\n }\n if (!isNullOrUndefined(e.properties.key)) {\n this.parent.notify(events.modelChanged, {\n requestType: 'searching', type: events.actionBegin, searchString: this.parent.searchSettings.key\n });\n }\n else {\n this.parent.notify(events.modelChanged, {\n requestType: 'searching', type: events.actionBegin\n });\n }\n };\n /**\n * The function used to trigger onActionComplete\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Search.prototype.onSearchComplete = function (e) {\n this.parent.trigger(events.actionComplete, extend(e, {\n searchString: this.parent.searchSettings.key, requestType: 'searching', type: events.actionComplete\n }));\n };\n /**\n * The function used to store the requestType\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Search.prototype.onActionComplete = function (e) {\n this.refreshSearch = e.requestType !== 'searching';\n };\n Search.prototype.cancelBeginEvent = function (e) {\n if (e.requestType === 'searching') {\n this.parent.setProperties({ searchSettings: { key: '' } }, true);\n }\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Search.prototype.getModuleName = function () {\n return 'search';\n };\n return Search;\n}());\nexport { Search };\n","import { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { iterateArrayOrObject, isGroupAdaptive, isActionPrevent, addRemoveEventListener } from '../base/util';\nimport * as events from '../base/constant';\n/**\n * The `ShowHide` module is used to control column visibility.\n */\nvar ShowHide = /** @class */ (function () {\n /**\n * Constructor for the show hide module.\n *\n * @param {IGrid} parent - specifies the IGrid\n * @hidden\n */\n function ShowHide(parent) {\n this.colName = [];\n this.isShowHide = false;\n this.parent = parent;\n this.addEventListener();\n }\n ShowHide.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.evtHandlers = [{ event: events.batchCancel, handler: this.batchChanges },\n { event: events.batchCnfrmDlgCancel, handler: this.resetColumnState }\n ];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n };\n /**\n * @returns {void}\n * @hidden\n */\n ShowHide.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n };\n ShowHide.prototype.batchChanges = function () {\n if (this.isShowHide) {\n this.isShowHide = false;\n this.setVisible(this.colName, this.changedCol);\n this.changedCol = this.colName = [];\n }\n };\n /**\n * Shows a column by column name.\n *\n * @param {string|string[]} columnName - Defines a single or collection of column names to show.\n * @param {string} showBy - Defines the column key either as field name or header text.\n * @returns {void}\n */\n ShowHide.prototype.show = function (columnName, showBy) {\n var keys = this.getToggleFields(columnName);\n var columns = this.getColumns(keys, showBy);\n this.parent.notify(events.tooltipDestroy, { module: 'edit' });\n for (var i = 0; i < columns.length; i++) {\n columns[parseInt(i.toString(), 10)].visible = true;\n }\n this.setVisible(columns);\n };\n /**\n * Hides a column by column name.\n *\n * @param {string|string[]} columnName - Defines a single or collection of column names to hide.\n * @param {string} hideBy - Defines the column key either as field name or header text.\n * @returns {void}\n */\n ShowHide.prototype.hide = function (columnName, hideBy) {\n var keys = this.getToggleFields(columnName);\n var columns = this.getColumns(keys, hideBy);\n this.parent.notify(events.tooltipDestroy, { module: 'edit' });\n for (var i = 0; i < columns.length; i++) {\n columns[parseInt(i.toString(), 10)].visible = false;\n }\n this.setVisible(columns);\n };\n ShowHide.prototype.getToggleFields = function (key) {\n var finalized = [];\n if (typeof key === 'string') {\n finalized = [key];\n }\n else {\n finalized = key;\n }\n return finalized;\n };\n ShowHide.prototype.getColumns = function (keys, getKeyBy) {\n var _this = this;\n var columns = iterateArrayOrObject(keys, function (key) {\n return iterateArrayOrObject(_this.parent.columnModel, function (item) {\n if (item[\"\" + getKeyBy] === key) {\n return item;\n }\n return undefined;\n })[0];\n });\n return columns;\n };\n ShowHide.prototype.batchActionPrevent = function (columns, changedStateColumns) {\n if (changedStateColumns === void 0) { changedStateColumns = []; }\n if (isActionPrevent(this.parent)) {\n this.colName = columns;\n this.changedCol = changedStateColumns;\n this.parent.closeEdit();\n return false;\n }\n return true;\n };\n ShowHide.prototype.resetColumnState = function () {\n if (this.isShowHide) {\n for (var i = 0; i < this.colName.length; i++) {\n this.colName[parseInt(i.toString(), 10)].visible = !this.colName[parseInt(i.toString(), 10)].visible;\n }\n }\n };\n /**\n * Shows or hides columns by given column collection.\n *\n * @private\n * @param {Column[]} columns - Specifies the columns.\n * @param {Column[]} changedStateColumns - specifies the changedStateColumns\n * @returns {void}\n */\n ShowHide.prototype.setVisible = function (columns, changedStateColumns) {\n var _this = this;\n if (changedStateColumns === void 0) { changedStateColumns = []; }\n this.isShowHide = true;\n if (!this.batchActionPrevent(columns, changedStateColumns)) {\n return;\n }\n changedStateColumns = (changedStateColumns.length > 0) ? changedStateColumns : columns;\n var args = {\n requestType: 'columnstate',\n cancel: false,\n columns: changedStateColumns\n };\n var cancel = 'cancel';\n if (this.parent.enableInfiniteScrolling && this.parent.allowGrouping\n && this.parent.groupModule.groupSettings.columns.length > 0) {\n this.parent.contentModule.visibleRows = [];\n }\n this.parent.trigger(events.actionBegin, args, function (showHideArgs) {\n var currentViewCols = _this.parent.getColumns();\n columns = isNullOrUndefined(columns) ? currentViewCols : columns;\n if (showHideArgs[\"\" + cancel]) {\n _this.parent.notify(events.resetColumns, { showHideArgs: showHideArgs });\n if (columns.length > 0) {\n columns[0].visible = true;\n }\n return;\n }\n if (isGroupAdaptive(_this.parent)) {\n _this.parent.contentModule.emptyVcRows();\n }\n if (_this.parent.allowSelection && _this.parent.getSelectedRecords().length &&\n !_this.parent.selectionSettings.persistSelection) {\n _this.parent.clearSelection();\n }\n if (_this.parent.enableColumnVirtualization) {\n var colsInCurrentView = columns.filter(function (col1) { return (currentViewCols.some(function (col2) { return col1.field === col2.field; })); });\n if (colsInCurrentView.length) {\n _this.parent.notify(events.columnVisibilityChanged, columns);\n }\n }\n else {\n if (_this.parent.isFrozenGrid() && columns.length) {\n _this.parent.notify(events.refreshFrozenPosition, { isModeChg: true });\n }\n _this.parent.notify(events.columnVisibilityChanged, columns);\n }\n var params = {\n requestType: 'columnstate',\n columns: changedStateColumns\n };\n _this.parent.trigger(events.actionComplete, params);\n if (_this.parent.columnQueryMode !== 'All') {\n _this.parent.refresh();\n }\n });\n if (this.parent.autoFit && !this.parent.groupSettings.columns.length) {\n this.parent.preventAdjustColumns();\n }\n };\n return ShowHide;\n}());\nexport { ShowHide };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { compile } from '@syncfusion/ej2-base';\nimport { getEnumValue } from '@syncfusion/ej2-base';\nimport { CellType } from '../base/enum';\nimport { Property, Collection, ChildProperty } from '@syncfusion/ej2-base';\n/**\n * Configures the Grid's aggregate column.\n */\nvar AggregateColumn = /** @class */ (function (_super) {\n __extends(AggregateColumn, _super);\n function AggregateColumn() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.templateFn = {};\n return _this;\n }\n /**\n * @param {Function} value - specifies the value\n * @returns {void}\n * @hidden\n */\n AggregateColumn.prototype.setFormatter = function (value) {\n this.formatFn = value;\n };\n /**\n * @returns {Function} returns the Function\n * @hidden\n */\n AggregateColumn.prototype.getFormatter = function () {\n return this.formatFn;\n };\n /**\n * @param {Object} helper - specifies the helper\n * @returns {void}\n * @hidden\n */\n AggregateColumn.prototype.setTemplate = function (helper) {\n if (helper === void 0) { helper = {}; }\n if (this.footerTemplate !== undefined) {\n this.templateFn[getEnumValue(CellType, CellType.Summary)] = { fn: compile(this.footerTemplate, helper),\n property: 'footerTemplate' };\n }\n if (this.groupFooterTemplate !== undefined) {\n this.templateFn[getEnumValue(CellType, CellType.GroupSummary)] = { fn: compile(this.groupFooterTemplate, helper),\n property: 'groupFooterTemplate' };\n }\n if (this.groupCaptionTemplate !== undefined) {\n this.templateFn[getEnumValue(CellType, CellType.CaptionSummary)] = { fn: compile(this.groupCaptionTemplate, helper),\n property: 'groupCaptionTemplate' };\n }\n };\n /**\n * @param {CellType} type - specifies the cell type\n * @returns {Object} returns the object\n * @hidden\n */\n AggregateColumn.prototype.getTemplate = function (type) {\n return this.templateFn[getEnumValue(CellType, type)];\n };\n /**\n * @param {Object} prop - returns the Object\n * @returns {void}\n * @hidden\n */\n AggregateColumn.prototype.setPropertiesSilent = function (prop) {\n this.setProperties(prop, true);\n };\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"type\", void 0);\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"field\", void 0);\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"columnName\", void 0);\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"format\", void 0);\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"footerTemplate\", void 0);\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"groupFooterTemplate\", void 0);\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"groupCaptionTemplate\", void 0);\n __decorate([\n Property()\n ], AggregateColumn.prototype, \"customAggregate\", void 0);\n return AggregateColumn;\n}(ChildProperty));\nexport { AggregateColumn };\n/**\n * Configures the aggregate rows.\n */\nvar AggregateRow = /** @class */ (function (_super) {\n __extends(AggregateRow, _super);\n function AggregateRow() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Collection([], AggregateColumn)\n ], AggregateRow.prototype, \"columns\", void 0);\n return AggregateRow;\n}(ChildProperty));\nexport { AggregateRow };\n","import { Browser, remove, EventHandler, isUndefined, closest, classList } from '@syncfusion/ej2-base';\nimport { parentsUntil, isGroupAdaptive } from '../base/util';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\n/**\n * The `Clipboard` module is used to handle clipboard copy action.\n */\nvar Clipboard = /** @class */ (function () {\n /**\n * Constructor for the Grid clipboard module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {ServiceLocator} serviceLocator - specifies the serviceLocator\n * @hidden\n */\n function Clipboard(parent, serviceLocator) {\n this.copyContent = '';\n this.isSelect = false;\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.addEventListener();\n }\n /**\n * @returns {void}\n * @hidden\n */\n Clipboard.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.contentReady, this.initialEnd, this);\n this.parent.on(events.keyPressed, this.keyDownHandler, this);\n this.parent.on(events.click, this.clickHandler, this);\n this.parent.on(events.onEmpty, this.initialEnd, this);\n EventHandler.add(this.parent.element, 'keydown', this.pasteHandler, this);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Clipboard.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.keyPressed, this.keyDownHandler);\n this.parent.off(events.contentReady, this.initialEnd);\n this.parent.off(events.click, this.clickHandler);\n this.parent.off(events.onEmpty, this.initialEnd);\n EventHandler.remove(this.parent.element, 'keydown', this.pasteHandler);\n };\n Clipboard.prototype.clickHandler = function (e) {\n var target = e.target;\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n target = parentsUntil(target, 'e-rowcell');\n };\n Clipboard.prototype.pasteHandler = function (e) {\n var _this = this;\n var grid = this.parent;\n var isMacLike = /(Mac)/i.test(navigator.platform);\n var selectedRowCellIndexes = this.parent.getSelectedRowCellIndexes();\n if (e.keyCode === 67 && isMacLike && e.metaKey && !grid.isEdit) {\n this.copy();\n }\n if (selectedRowCellIndexes.length && e.keyCode === 86 && ((!isMacLike && e.ctrlKey) || (isMacLike && e.metaKey)) && !grid.isEdit) {\n var target = closest(document.activeElement, '.' + literals.rowCell);\n if (!this.clipBoardTextArea || !target || !grid.editSettings.allowEditing || grid.editSettings.mode !== 'Batch' ||\n grid.selectionSettings.mode !== 'Cell' || grid.selectionSettings.cellSelectionMode === 'Flow') {\n return;\n }\n this.activeElement = document.activeElement;\n var x_1 = window.scrollX;\n var y_1 = window.scrollY;\n this.clipBoardTextArea.focus();\n setTimeout(function () {\n _this.activeElement.focus();\n window.scrollTo(x_1, y_1);\n _this.paste(_this.clipBoardTextArea.value, selectedRowCellIndexes[0].rowIndex, selectedRowCellIndexes[0].cellIndexes[0]);\n }, isMacLike ? 100 : 10);\n }\n };\n /**\n * Paste data from clipboard to selected cells.\n *\n * @param {boolean} data - Specifies the date for paste.\n * @param {boolean} rowIndex - Specifies the row index.\n * @param {boolean} colIndex - Specifies the column index.\n * @returns {void}\n */\n Clipboard.prototype.paste = function (data, rowIndex, colIndex) {\n var grid = this.parent;\n var cIdx = colIndex;\n var rIdx = rowIndex;\n var col;\n var value;\n var isAvail;\n var rows = data.split('\\n');\n var cols;\n for (var r = 0; r < rows.length; r++) {\n cols = rows[parseInt(r.toString(), 10)].split('\\t');\n cIdx = colIndex;\n if ((r === rows.length - 1 && rows[parseInt(r.toString(), 10)] === '') || isUndefined(grid.getRowByIndex(rIdx))) {\n cIdx++;\n break;\n }\n for (var c = 0; c < cols.length; c++) {\n isAvail = grid.getCellFromIndex(rIdx, cIdx);\n if (!isAvail) {\n cIdx++;\n break;\n }\n col = grid.getColumnByIndex(cIdx);\n value = col.getParser() ? col.getParser()(cols[parseInt(c.toString(), 10)]) : cols[parseInt(c.toString(), 10)];\n if (col.allowEditing && !col.isPrimaryKey && !col.template) {\n var args = {\n column: col,\n data: value,\n rowIndex: rIdx\n };\n this.parent.trigger(events.beforePaste, args);\n rIdx = args.rowIndex;\n if (!args.cancel) {\n if (grid.editModule) {\n if (col.type === 'number') {\n this.parent.editModule.updateCell(rIdx, col.field, parseFloat(args.data));\n }\n else {\n grid.editModule.updateCell(rIdx, col.field, args.data);\n }\n }\n }\n }\n cIdx++;\n }\n rIdx++;\n }\n grid.selectionModule.selectCellsByRange({ rowIndex: rowIndex, cellIndex: colIndex }, { rowIndex: rIdx - 1, cellIndex: cIdx - 1 });\n var cell = this.parent.getCellFromIndex(rIdx - 1, cIdx - 1);\n if (cell) {\n classList(cell, ['e-focus', 'e-focused'], []);\n }\n this.clipBoardTextArea.value = '';\n };\n Clipboard.prototype.initialEnd = function () {\n this.l10n = this.serviceLocator.getService('localization');\n this.parent.off(events.contentReady, this.initialEnd);\n this.clipBoardTextArea = this.parent.createElement('textarea', {\n className: 'e-clipboard',\n styles: 'opacity: 0',\n attrs: { tabindex: '-1', 'aria-label': this.l10n.getConstant('ClipBoard') }\n });\n this.parent.element.appendChild(this.clipBoardTextArea);\n };\n Clipboard.prototype.keyDownHandler = function (e) {\n if (e.action === 'ctrlPlusC') {\n this.copy();\n }\n else if (e.action === 'ctrlShiftPlusH') {\n this.copy(true);\n }\n };\n Clipboard.prototype.setCopyData = function (withHeader) {\n if (window.getSelection().toString() === '') {\n this.clipBoardTextArea.value = this.copyContent = '';\n var rows = this.parent.getDataRows();\n if (this.parent.selectionSettings.mode !== 'Cell') {\n var selectedIndexes = this.parent.getSelectedRowIndexes().sort(function (a, b) { return a - b; });\n if (withHeader) {\n var headerTextArray = [];\n for (var i = 0; i < this.parent.getVisibleColumns().length; i++) {\n headerTextArray[parseInt(i.toString(), 10)] = this.parent\n .getVisibleColumns()[parseInt(i.toString(), 10)].headerText;\n }\n this.getCopyData(headerTextArray, false, '\\t', withHeader);\n this.copyContent += '\\n';\n }\n for (var i = 0; i < selectedIndexes.length; i++) {\n if (i > 0) {\n this.copyContent += '\\n';\n }\n var leftCols = [];\n var idx = selectedIndexes[parseInt(i.toString(), 10)];\n if (!isGroupAdaptive(this.parent) && (this.parent.enableVirtualization ||\n (this.parent.enableInfiniteScrolling && this.parent.infiniteScrollSettings.enableCache) ||\n (this.parent.groupSettings.columns.length && this.parent.groupSettings.enableLazyLoading))) {\n idx = rows.map(function (m) { return m.getAttribute('data-rowindex'); }).indexOf(selectedIndexes[parseInt(i.toString(), 10)].toString());\n }\n leftCols.push.apply(leftCols, [].slice.call(rows[parseInt(idx.toString(), 10)].querySelectorAll('.e-rowcell:not(.e-hide)')));\n this.getCopyData(leftCols, false, '\\t', withHeader);\n }\n }\n else {\n var obj = this.checkBoxSelection();\n if (obj.status) {\n if (withHeader) {\n var headers = [];\n for (var i = 0; i < obj.colIndexes.length; i++) {\n var colHeader = this.parent.getColumnHeaderByIndex(obj.colIndexes[parseInt(i.toString(), 10)]);\n if (!colHeader.classList.contains('e-hide')) {\n headers.push(colHeader);\n }\n }\n this.getCopyData(headers, false, '\\t', withHeader);\n this.copyContent += '\\n';\n }\n for (var i = 0; i < obj.rowIndexes.length; i++) {\n if (i > 0) {\n this.copyContent += '\\n';\n }\n var cells = [].slice.call(rows[obj.rowIndexes[parseInt(i.toString(), 10)]].\n querySelectorAll('.e-cellselectionbackground:not(.e-hide)'));\n this.getCopyData(cells, false, '\\t', withHeader);\n }\n }\n else {\n this.getCopyData([].slice.call(this.parent.element.getElementsByClassName('e-cellselectionbackground')), true, '\\n', withHeader);\n }\n }\n var args = {\n data: this.copyContent,\n cancel: false\n };\n this.parent.trigger(events.beforeCopy, args);\n if (args.cancel) {\n return;\n }\n this.clipBoardTextArea.value = this.copyContent = args.data;\n if (!Browser.userAgent.match(/ipad|ipod|iphone/i)) {\n this.clipBoardTextArea.select();\n }\n else {\n this.clipBoardTextArea.setSelectionRange(0, this.clipBoardTextArea.value.length);\n }\n this.isSelect = true;\n }\n };\n Clipboard.prototype.getCopyData = function (cells, isCell, splitKey, withHeader) {\n var isElement = typeof cells[0] !== 'string';\n for (var j = 0; j < cells.length; j++) {\n if (withHeader && isCell) {\n var colIdx = parseInt(cells[parseInt(j.toString(), 10)].getAttribute(literals.dataColIndex), 10);\n this.copyContent += this.parent.getColumns()[parseInt(colIdx.toString(), 10)].headerText + '\\n';\n }\n if (isElement) {\n if (!cells[parseInt(j.toString(), 10)].classList.contains('e-hide')) {\n this.copyContent += cells[parseInt(j.toString(), 10)].innerText;\n }\n }\n else {\n this.copyContent += cells[parseInt(j.toString(), 10)];\n }\n if (j < cells.length - 1) {\n this.copyContent += splitKey;\n }\n }\n };\n /**\n * Copy selected rows or cells data into clipboard.\n *\n * @returns {void}\n * @param {boolean} withHeader - Specifies whether the column header data need to be copied or not.\n */\n Clipboard.prototype.copy = function (withHeader) {\n if (document.queryCommandSupported('copy') && this.clipBoardTextArea) {\n this.setCopyData(withHeader);\n document.execCommand('copy');\n this.clipBoardTextArea.blur();\n }\n if (this.isSelect) {\n window.getSelection().removeAllRanges();\n this.isSelect = false;\n }\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Clipboard.prototype.getModuleName = function () {\n return 'clipboard';\n };\n /**\n * To destroy the clipboard\n *\n * @returns {void}\n * @hidden\n */\n Clipboard.prototype.destroy = function () {\n this.removeEventListener();\n if (this.clipBoardTextArea) {\n remove(this.clipBoardTextArea);\n }\n };\n Clipboard.prototype.checkBoxSelection = function () {\n var gridObj = this.parent;\n var obj = { status: false };\n if (gridObj.selectionSettings.mode === 'Cell') {\n var rowCellIndxes = gridObj.getSelectedRowCellIndexes();\n var str = void 0;\n var rowIndexes = [];\n var i = void 0;\n for (i = 0; i < rowCellIndxes.length; i++) {\n if (rowCellIndxes[parseInt(i.toString(), 10)].cellIndexes.length) {\n rowIndexes.push(rowCellIndxes[parseInt(i.toString(), 10)].rowIndex);\n }\n if (rowCellIndxes[parseInt(i.toString(), 10)].cellIndexes.length) {\n if (!str) {\n str = JSON.stringify(rowCellIndxes[parseInt(i.toString(), 10)].cellIndexes.sort());\n }\n if (str !== JSON.stringify(rowCellIndxes[parseInt(i.toString(), 10)].cellIndexes.sort())) {\n break;\n }\n }\n }\n rowIndexes.sort(function (a, b) { return a - b; });\n if (i === rowCellIndxes.length) {\n obj = { status: true, rowIndexes: rowIndexes, colIndexes: rowCellIndxes[0].cellIndexes };\n }\n }\n return obj;\n };\n return Clipboard;\n}());\nexport { Clipboard };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { isNullOrUndefined, setValue, getValue, defaultCurrencyCode } from '@syncfusion/ej2-base';\nimport { Component, ChildProperty, Browser, closest, extend } from '@syncfusion/ej2-base';\nimport { addClass, removeClass, append, remove, classList, setStyleAttribute } from '@syncfusion/ej2-base';\nimport { Property, Collection, Complex, Event, NotifyPropertyChanges, L10n } from '@syncfusion/ej2-base';\nimport { EventHandler, KeyboardEvents } from '@syncfusion/ej2-base';\nimport { DataManager, DataUtil, UrlAdaptor } from '@syncfusion/ej2-data';\nimport { createSpinner, hideSpinner, showSpinner, Tooltip } from '@syncfusion/ej2-popups';\nimport { iterateArrayOrObject, prepareColumns, parentsUntil, wrap, templateCompiler, isGroupAdaptive, refreshForeignData, getScrollBarWidth } from './util';\nimport { getRowHeight, setColumnIndex, Global, ispercentageWidth, getNumberFormat, getTransformValues } from './util';\nimport { setRowElements, resetRowIndex, compareChanges, getCellByColAndRowIndex, performComplexDataOperation } from './util';\nimport * as events from '../base/constant';\nimport { Render } from '../renderer/render';\nimport { Column } from '../models/column';\nimport { RenderType } from './enum';\nimport { RowRenderer } from '../renderer/row-renderer';\nimport { CellRenderer } from '../renderer/cell-renderer';\nimport { CellRendererFactory } from '../services/cell-render-factory';\nimport { ServiceLocator } from '../services/service-locator';\nimport { ValueFormatter } from '../services/value-formatter';\nimport { RendererFactory } from '../services/renderer-factory';\nimport { ColumnWidthService } from '../services/width-controller';\nimport { AriaService } from '../services/aria-service';\nimport { FocusStrategy } from '../services/focus-strategy';\nimport { PageSettings } from '../models/page-settings';\nimport { ColumnChooserSettings } from '../models/column-chooser-settings';\nimport { Selection } from '../actions/selection';\nimport { Search } from '../actions/search';\nimport { ShowHide } from '../actions/show-hide';\nimport { Scroll } from '../actions/scroll';\nimport { Print } from '../actions/print';\nimport { AggregateRow } from '../models/aggregate';\nimport { Clipboard } from '../actions/clipboard';\nimport { RowModelGenerator } from '../services/row-model-generator';\nimport { SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport * as literals from '../base/string-literals';\nimport { HeaderCellRenderer } from '../renderer/header-cell-renderer';\n/**\n * Represents the field name and direction of sort column.\n */\nvar SortDescriptor = /** @class */ (function (_super) {\n __extends(SortDescriptor, _super);\n function SortDescriptor() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property()\n ], SortDescriptor.prototype, \"field\", void 0);\n __decorate([\n Property()\n ], SortDescriptor.prototype, \"direction\", void 0);\n __decorate([\n Property(false)\n ], SortDescriptor.prototype, \"isFromGroup\", void 0);\n return SortDescriptor;\n}(ChildProperty));\nexport { SortDescriptor };\n/**\n * Configures the sorting behavior of Grid.\n */\nvar SortSettings = /** @class */ (function (_super) {\n __extends(SortSettings, _super);\n function SortSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Collection([], SortDescriptor)\n ], SortSettings.prototype, \"columns\", void 0);\n __decorate([\n Property(true)\n ], SortSettings.prototype, \"allowUnsort\", void 0);\n return SortSettings;\n}(ChildProperty));\nexport { SortSettings };\n/**\n * Represents the predicate for the filter column.\n */\nvar Predicate = /** @class */ (function (_super) {\n __extends(Predicate, _super);\n function Predicate() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property()\n ], Predicate.prototype, \"field\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"operator\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"value\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"matchCase\", void 0);\n __decorate([\n Property(false)\n ], Predicate.prototype, \"ignoreAccent\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"predicate\", void 0);\n __decorate([\n Property({})\n ], Predicate.prototype, \"actualFilterValue\", void 0);\n __decorate([\n Property({})\n ], Predicate.prototype, \"actualOperator\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"type\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"ejpredicate\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"uid\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"isForeignKey\", void 0);\n __decorate([\n Property()\n ], Predicate.prototype, \"condition\", void 0);\n return Predicate;\n}(ChildProperty));\nexport { Predicate };\n/**\n * Configures the infinite scroll behavior of Grid.\n */\nvar InfiniteScrollSettings = /** @class */ (function (_super) {\n __extends(InfiniteScrollSettings, _super);\n function InfiniteScrollSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], InfiniteScrollSettings.prototype, \"enableCache\", void 0);\n __decorate([\n Property(3)\n ], InfiniteScrollSettings.prototype, \"maxBlocks\", void 0);\n __decorate([\n Property(3)\n ], InfiniteScrollSettings.prototype, \"initialBlocks\", void 0);\n return InfiniteScrollSettings;\n}(ChildProperty));\nexport { InfiniteScrollSettings };\n/**\n * Configures the filtering behavior of the Grid.\n */\nvar FilterSettings = /** @class */ (function (_super) {\n __extends(FilterSettings, _super);\n function FilterSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Collection([], Predicate)\n ], FilterSettings.prototype, \"columns\", void 0);\n __decorate([\n Property('FilterBar')\n ], FilterSettings.prototype, \"type\", void 0);\n __decorate([\n Property('OnEnter')\n ], FilterSettings.prototype, \"mode\", void 0);\n __decorate([\n Property(true)\n ], FilterSettings.prototype, \"showFilterBarStatus\", void 0);\n __decorate([\n Property(1500)\n ], FilterSettings.prototype, \"immediateModeDelay\", void 0);\n __decorate([\n Property()\n ], FilterSettings.prototype, \"operators\", void 0);\n __decorate([\n Property(false)\n ], FilterSettings.prototype, \"ignoreAccent\", void 0);\n __decorate([\n Property(false)\n ], FilterSettings.prototype, \"enableInfiniteScrolling\", void 0);\n __decorate([\n Property(50)\n ], FilterSettings.prototype, \"itemsCount\", void 0);\n __decorate([\n Property('Shimmer')\n ], FilterSettings.prototype, \"loadingIndicator\", void 0);\n __decorate([\n Property(false)\n ], FilterSettings.prototype, \"enableCaseSensitivity\", void 0);\n __decorate([\n Property(false)\n ], FilterSettings.prototype, \"showFilterBarOperator\", void 0);\n return FilterSettings;\n}(ChildProperty));\nexport { FilterSettings };\n/**\n * Configures the selection behavior of the Grid.\n */\nvar SelectionSettings = /** @class */ (function (_super) {\n __extends(SelectionSettings, _super);\n function SelectionSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Row')\n ], SelectionSettings.prototype, \"mode\", void 0);\n __decorate([\n Property('Flow')\n ], SelectionSettings.prototype, \"cellSelectionMode\", void 0);\n __decorate([\n Property('Single')\n ], SelectionSettings.prototype, \"type\", void 0);\n __decorate([\n Property(false)\n ], SelectionSettings.prototype, \"checkboxOnly\", void 0);\n __decorate([\n Property(false)\n ], SelectionSettings.prototype, \"persistSelection\", void 0);\n __decorate([\n Property('Default')\n ], SelectionSettings.prototype, \"checkboxMode\", void 0);\n __decorate([\n Property(false)\n ], SelectionSettings.prototype, \"enableSimpleMultiRowSelection\", void 0);\n __decorate([\n Property(true)\n ], SelectionSettings.prototype, \"enableToggle\", void 0);\n __decorate([\n Property(false)\n ], SelectionSettings.prototype, \"allowColumnSelection\", void 0);\n return SelectionSettings;\n}(ChildProperty));\nexport { SelectionSettings };\n/**\n * Configures the search behavior of the Grid.\n */\nvar SearchSettings = /** @class */ (function (_super) {\n __extends(SearchSettings, _super);\n function SearchSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property([])\n ], SearchSettings.prototype, \"fields\", void 0);\n __decorate([\n Property('')\n ], SearchSettings.prototype, \"key\", void 0);\n __decorate([\n Property('contains')\n ], SearchSettings.prototype, \"operator\", void 0);\n __decorate([\n Property(true)\n ], SearchSettings.prototype, \"ignoreCase\", void 0);\n __decorate([\n Property(false)\n ], SearchSettings.prototype, \"ignoreAccent\", void 0);\n return SearchSettings;\n}(ChildProperty));\nexport { SearchSettings };\n/**\n * Configures the row drop settings of the Grid.\n */\nvar RowDropSettings = /** @class */ (function (_super) {\n __extends(RowDropSettings, _super);\n function RowDropSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property()\n ], RowDropSettings.prototype, \"targetID\", void 0);\n return RowDropSettings;\n}(ChildProperty));\nexport { RowDropSettings };\n/**\n * Configures the text wrap settings of the Grid.\n */\nvar TextWrapSettings = /** @class */ (function (_super) {\n __extends(TextWrapSettings, _super);\n function TextWrapSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Both')\n ], TextWrapSettings.prototype, \"wrapMode\", void 0);\n return TextWrapSettings;\n}(ChildProperty));\nexport { TextWrapSettings };\n/**\n * Configures the resize behavior of the Grid.\n */\nvar ResizeSettings = /** @class */ (function (_super) {\n __extends(ResizeSettings, _super);\n function ResizeSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Normal')\n ], ResizeSettings.prototype, \"mode\", void 0);\n return ResizeSettings;\n}(ChildProperty));\nexport { ResizeSettings };\n/**\n * Configures the group behavior of the Grid.\n */\nvar GroupSettings = /** @class */ (function (_super) {\n __extends(GroupSettings, _super);\n function GroupSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(true)\n ], GroupSettings.prototype, \"showDropArea\", void 0);\n __decorate([\n Property(false)\n ], GroupSettings.prototype, \"allowReordering\", void 0);\n __decorate([\n Property(false)\n ], GroupSettings.prototype, \"showToggleButton\", void 0);\n __decorate([\n Property(false)\n ], GroupSettings.prototype, \"showGroupedColumn\", void 0);\n __decorate([\n Property(true)\n ], GroupSettings.prototype, \"showUngroupButton\", void 0);\n __decorate([\n Property(false)\n ], GroupSettings.prototype, \"disablePageWiseAggregates\", void 0);\n __decorate([\n Property([])\n ], GroupSettings.prototype, \"columns\", void 0);\n __decorate([\n Property()\n ], GroupSettings.prototype, \"captionTemplate\", void 0);\n __decorate([\n Property(false)\n ], GroupSettings.prototype, \"enableLazyLoading\", void 0);\n return GroupSettings;\n}(ChildProperty));\nexport { GroupSettings };\n/**\n * Configures the edit behavior of the Grid.\n */\nvar EditSettings = /** @class */ (function (_super) {\n __extends(EditSettings, _super);\n function EditSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], EditSettings.prototype, \"allowAdding\", void 0);\n __decorate([\n Property(false)\n ], EditSettings.prototype, \"allowEditing\", void 0);\n __decorate([\n Property(false)\n ], EditSettings.prototype, \"allowDeleting\", void 0);\n __decorate([\n Property('Normal')\n ], EditSettings.prototype, \"mode\", void 0);\n __decorate([\n Property(true)\n ], EditSettings.prototype, \"allowEditOnDblClick\", void 0);\n __decorate([\n Property(true)\n ], EditSettings.prototype, \"showConfirmDialog\", void 0);\n __decorate([\n Property(false)\n ], EditSettings.prototype, \"showDeleteConfirmDialog\", void 0);\n __decorate([\n Property()\n ], EditSettings.prototype, \"template\", void 0);\n __decorate([\n Property()\n ], EditSettings.prototype, \"headerTemplate\", void 0);\n __decorate([\n Property()\n ], EditSettings.prototype, \"footerTemplate\", void 0);\n __decorate([\n Property('Top')\n ], EditSettings.prototype, \"newRowPosition\", void 0);\n __decorate([\n Property({})\n ], EditSettings.prototype, \"dialog\", void 0);\n __decorate([\n Property(false)\n ], EditSettings.prototype, \"allowNextRowEdit\", void 0);\n return EditSettings;\n}(ChildProperty));\nexport { EditSettings };\n/**\n * Configures the Loading Indicator of the Grid.\n */\nvar LoadingIndicator = /** @class */ (function (_super) {\n __extends(LoadingIndicator, _super);\n function LoadingIndicator() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Spinner')\n ], LoadingIndicator.prototype, \"indicatorType\", void 0);\n return LoadingIndicator;\n}(ChildProperty));\nexport { LoadingIndicator };\n/**\n * Represents the Grid component.\n * ```html\n * <div id=\"grid\"></div>\n * <script>\n * var gridObj = new Grid({ allowPaging: true });\n * gridObj.appendTo(\"#grid\");\n * </script>\n * ```\n */\nvar Grid = /** @class */ (function (_super) {\n __extends(Grid, _super);\n /**\n * Constructor for creating the component\n *\n * @param {GridModel} options - specifies the options\n * @param {string | HTMLElement} element - specifies the element\n * @hidden\n */\n function Grid(options, element) {\n var _this_1 = _super.call(this, options, element) || this;\n _this_1.isPreventScrollEvent = false;\n _this_1.inViewIndexes = [];\n _this_1.keyA = false;\n _this_1.frozenRightCount = 0;\n _this_1.freezeColumnRefresh = true;\n _this_1.rightcount = 0;\n _this_1.frozenLeftCount = 0;\n _this_1.leftcount = 0;\n _this_1.tablesCount = 1;\n _this_1.movableCount = 0;\n _this_1.movablecount = 0;\n _this_1.fixedcount = 0;\n _this_1.fixedCount = 0;\n _this_1.visibleFrozenLeft = 0;\n _this_1.visibleFrozenFixed = 0;\n _this_1.isPreparedFrozenColumns = false;\n _this_1.visibleFrozenRight = 0;\n _this_1.visibleMovable = 0;\n _this_1.frozenLeftColumns = [];\n _this_1.frozenRightColumns = [];\n _this_1.movableColumns = [];\n _this_1.fixedColumns = [];\n _this_1.stackedLeft = [];\n _this_1.stackedRight = [];\n _this_1.stackedFixed = [];\n _this_1.stackedMovable = [];\n _this_1.stackedarrayLeft = [];\n _this_1.stackedarrayRight = [];\n _this_1.stackedarrayFixed = [];\n _this_1.stackedarrayMovable = [];\n _this_1.media = {};\n /** @hidden */\n _this_1.tableIndex = 0;\n _this_1.componentRefresh = Component.prototype.refresh;\n _this_1.isChangeDataSourceCall = false;\n _this_1.mergedColumns = false;\n /** @hidden */\n _this_1.isVirtualAdaptive = false;\n /** @hidden */\n /**\n * * If `requireTemplateRef` is set to false in the load event, then the template element can't be accessed in grid queryCellInfo, and rowDataBound events.\n * * By default, React's grid queryCellInfo and rowDataBound events allow access to the template element.\n * * Avoid accessing the template elements in the grid queryCellInfo and rowDataBound events to improve rendering performance by setting this value as false.\n *\n * @default true\n */\n _this_1.requireTemplateRef = true;\n /** @hidden */\n _this_1.vRows = [];\n /** @hidden */\n _this_1.vcRows = [];\n /** @hidden */\n _this_1.vGroupOffsets = {};\n /** @hidden */\n _this_1.rowUid = 0;\n /** @hidden */\n _this_1.translateX = 0;\n /** @hidden */\n _this_1.isManualRefresh = false;\n /** @hidden */\n _this_1.isAutoFitColumns = false;\n /** @hidden */\n _this_1.enableDeepCompare = false;\n /** @hidden */\n _this_1.totalDataRecordsCount = 0;\n /** @hidden */\n _this_1.disableSelectedRecords = [];\n /** @hidden */\n _this_1.partialSelectedRecords = [];\n /** @hidden */\n _this_1.islazyloadRequest = false;\n /** @hidden */\n _this_1.lockcolPositionCount = 0;\n /** @hidden */\n _this_1.prevPageMoving = false;\n /** @hidden */\n _this_1.pageTemplateChange = false;\n /** @hidden */\n _this_1.isAutoGen = false;\n /** @hidden */\n _this_1.isAutoGenerateColumns = false;\n _this_1.mediaBindInstance = {};\n /** @hidden */\n _this_1.commandDelIndex = undefined;\n /** @hidden */\n _this_1.asyncTimeOut = 50;\n /** @hidden */\n _this_1.isExportGrid = false;\n // enable/disable logger for MVC & Core\n _this_1.enableLogger = true;\n _this_1.needsID = true;\n Grid_1.Inject(Selection);\n setValue('mergePersistData', _this_1.mergePersistGridData, _this_1);\n return _this_1;\n }\n Grid_1 = Grid;\n /**\n * Get the properties to be maintained in the persisted state.\n *\n * @returns {string} returns the persist data\n */\n Grid.prototype.getPersistData = function () {\n var keyEntity = ['pageSettings', 'sortSettings',\n 'filterSettings', 'groupSettings', 'columns', 'searchSettings', 'selectedRowIndex', 'scrollPosition'];\n var ignoreOnPersist = {\n pageSettings: ['template', 'pageSizes', 'enableQueryString', 'totalRecordsCount', 'pageCount'],\n filterSettings: ['type', 'mode', 'showFilterBarStatus', 'immediateModeDelay', 'ignoreAccent'],\n groupSettings: ['showDropArea', 'showToggleButton', 'showGroupedColumn', 'showUngroupButton',\n 'disablePageWiseAggregates', 'hideCaptionCount'],\n searchSettings: ['fields', 'operator', 'ignoreCase'],\n sortSettings: [], columns: [], selectedRowIndex: [], scrollPosition: []\n };\n for (var i = 0; i < keyEntity.length; i++) {\n var currentObject = this[keyEntity[parseInt(i.toString(), 10)]];\n for (var _i = 0, _a = ignoreOnPersist[keyEntity[parseInt(i.toString(), 10)]]; _i < _a.length; _i++) {\n var val = _a[_i];\n delete currentObject[\"\" + val];\n }\n }\n var temp = this.pageSettings.template;\n var settings = Object.assign({ template: undefined }, this.pageSettings);\n this.setProperties({ pageSettings: settings }, true);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this.isAngular) {\n delete this.groupSettings['properties']['captionTemplate'];\n }\n this.pageTemplateChange = !isNullOrUndefined(this.pagerTemplate);\n var persistData = this.addOnPersist(keyEntity);\n settings.template = temp;\n this.setProperties({ pageSettings: settings }, true);\n return persistData;\n };\n /**\n * To provide the array of modules needed for component rendering\n *\n * @returns {ModuleDeclaration[]} Returns the module Declaration\n * @hidden\n */\n Grid.prototype.requiredModules = function () {\n this.setFrozenCount();\n this.enableInfiniteAggrgate();\n var modules = [];\n if (this.isDestroyed) {\n return modules;\n }\n if (this.allowFiltering) {\n modules.push({\n member: 'filter',\n args: [this, this.filterSettings, this.serviceLocator]\n });\n }\n if (this.allowExcelExport) {\n modules.push({\n member: 'ExcelExport',\n args: [this, this.serviceLocator]\n });\n }\n if (this.allowPdfExport) {\n modules.push({\n member: 'PdfExport',\n args: [this]\n });\n }\n if (this.allowSorting) {\n modules.push({\n member: 'sort',\n args: [this, this.sortSettings, this.sortedColumns, this.serviceLocator]\n });\n }\n if (this.allowPaging) {\n modules.push({\n member: 'pager',\n args: [this, this.pageSettings]\n });\n }\n if (this.allowSelection) {\n modules.push({\n member: 'selection',\n args: [this, this.selectionSettings, this.serviceLocator]\n });\n }\n modules.push({\n member: 'resize',\n args: [this]\n });\n if (this.allowReordering) {\n modules.push({\n member: 'reorder',\n args: [this]\n });\n }\n if (this.allowRowDragAndDrop) {\n modules.push({\n member: 'rowDragAndDrop',\n args: [this]\n });\n }\n if (this.allowGrouping) {\n modules.push({\n member: 'group',\n args: [this, this.groupSettings, this.sortedColumns, this.serviceLocator]\n });\n }\n if (this.aggregates.length) {\n modules.push({ member: 'aggregate', args: [this, this.serviceLocator] });\n }\n if (this.isDetail()) {\n modules.push({\n member: 'detailRow',\n args: [this, this.serviceLocator]\n });\n }\n if (this.toolbar || this.toolbarTemplate) {\n modules.push({\n member: 'toolbar',\n args: [this, this.serviceLocator]\n });\n }\n if (this.enableVirtualization || this.enableColumnVirtualization) {\n modules.push({\n member: 'virtualscroll',\n args: [this, this.serviceLocator]\n });\n }\n if (this.getFrozenColumns() || this.frozenRows || this.frozenRightCount || this.frozenLeftCount) {\n modules.push({ member: 'freeze', args: [this, this.serviceLocator] });\n }\n if (this.isCommandColumn(this.columns)) {\n modules.push({\n member: 'commandColumn',\n args: [this, this.serviceLocator]\n });\n }\n if (this.editSettings.allowAdding || this.editSettings.allowDeleting || this.editSettings.allowEditing) {\n modules.push({\n member: 'edit',\n args: [this, this.serviceLocator]\n });\n }\n this.extendRequiredModules(modules);\n return modules;\n };\n Grid.prototype.extendRequiredModules = function (modules) {\n if (this.enableInfiniteScrolling) {\n modules.push({\n member: 'infiniteScroll',\n args: [this, this.serviceLocator]\n });\n }\n if (this.groupSettings.enableLazyLoading) {\n modules.push({\n member: 'lazyLoadGroup',\n args: [this, this.serviceLocator]\n });\n }\n if (this.contextMenuItems) {\n modules.push({\n member: 'contextMenu',\n args: [this, this.serviceLocator]\n });\n }\n if (this.showColumnMenu) {\n modules.push({\n member: 'columnMenu',\n args: [this, this.serviceLocator]\n });\n }\n if (this.showColumnChooser) {\n modules.push({\n member: 'columnChooser',\n args: [this, this.serviceLocator]\n });\n }\n if (this.isForeignKeyEnabled(this.columns)) {\n modules.push({ member: 'foreignKey', args: [this, this.serviceLocator] });\n }\n if (this.enableLogger) {\n modules.push({ member: 'logger', args: [this] });\n }\n };\n /**\n * For internal use only - Initialize the event handler;\n *\n * @returns {void}\n * @private\n */\n Grid.prototype.preRender = function () {\n this.serviceLocator = new ServiceLocator;\n this.initProperties();\n this.initializeServices();\n };\n Grid.prototype.initProperties = function () {\n this.isInitial = true;\n this.sortedColumns = [];\n this.inViewIndexes = [];\n this.mediaCol = [];\n this.isInitialLoad = false;\n this.allowServerDataBinding = false;\n this.ignoreCollectionWatch = true;\n this.mergeCells = {};\n this.isEdit = false;\n this.checkAllRows = 'None';\n this.isCheckBoxSelection = false;\n this.isPersistSelection = false;\n this.componentRefresh = Component.prototype.refresh;\n this.filterOperators = {\n contains: 'contains', endsWith: 'endswith', equal: 'equal', greaterThan: 'greaterthan', greaterThanOrEqual: 'greaterthanorequal',\n lessThan: 'lessthan', lessThanOrEqual: 'lessthanorequal', notEqual: 'notequal', startsWith: 'startswith', wildCard: 'wildcard',\n isNull: 'isnull', notNull: 'notnull', like: 'like'\n };\n this.defaultLocale = {\n EmptyRecord: 'No records to display',\n True: 'true',\n False: 'false',\n InvalidFilterMessage: 'Invalid Filter Data',\n GroupDropArea: 'Drag a column header here to group its column',\n UnGroup: 'Click here to ungroup',\n UnGroupButton: 'Click here to ungroup',\n GroupDisable: 'Grouping is disabled for this column',\n FilterbarTitle: '\\'s filter bar cell',\n EmptyDataSourceError: 'DataSource must not be empty at initial load since columns are generated from dataSource in AutoGenerate Column Grid',\n // Toolbar Items\n Add: 'Add',\n Edit: 'Edit',\n Cancel: 'Cancel',\n Update: 'Update',\n Delete: 'Delete',\n Print: 'Print',\n Pdfexport: 'PDF Export',\n Excelexport: 'Excel Export',\n Wordexport: 'Word Export',\n Csvexport: 'CSV Export',\n Search: 'Search',\n Columnchooser: 'Columns',\n Save: 'Save',\n Item: 'item',\n Items: 'items',\n EditOperationAlert: 'No records selected for edit operation',\n DeleteOperationAlert: 'No records selected for delete operation',\n SaveButton: 'Save',\n OKButton: 'OK',\n CancelButton: 'Cancel',\n EditFormTitle: 'Details of ',\n AddFormTitle: 'Add New Record',\n BatchSaveConfirm: 'Are you sure you want to save changes?',\n BatchSaveLostChanges: 'Unsaved changes will be lost. Are you sure you want to continue?',\n ConfirmDelete: 'Are you sure you want to Delete Record?',\n CancelEdit: 'Are you sure you want to Cancel the changes?',\n ChooseColumns: 'Choose Column',\n ColumnMenu: 'Column Menu',\n SearchColumns: 'search columns',\n Matchs: 'No matches found',\n FilterButton: 'Filter',\n ClearButton: 'Clear',\n StartsWith: 'Starts With',\n NotStartsWith: 'Does Not Start With',\n Like: 'Like',\n EndsWith: 'Ends With',\n NotEndsWith: 'Does Not End With',\n Contains: 'Contains',\n NotContains: 'Does Not Contain',\n IsNull: 'Null',\n NotNull: 'Not Null',\n IsEmpty: 'Empty',\n IsNotEmpty: 'Not Empty',\n Equal: 'Equal',\n NotEqual: 'Not Equal',\n LessThan: 'Less Than',\n LessThanOrEqual: 'Less Than Or Equal',\n GreaterThan: 'Greater Than',\n GreaterThanOrEqual: 'Greater Than Or Equal',\n ChooseDate: 'Choose a Date',\n EnterValue: 'Enter the value',\n Copy: 'Copy',\n Group: 'Group by this column',\n Ungroup: 'Ungroup by this column',\n GroupButton: 'Group button',\n UnGroupAria: 'ungroup button',\n GroupSeperator: 'Separator for the grouped columns',\n UnGroupIcon: 'ungroup the grouped column ',\n GroupedSortIcon: 'sort the grouped column ',\n GroupedDrag: 'Drag the grouped column',\n GroupCaption: ' is groupcaption cell',\n CheckBoxLabel: 'checkbox',\n SelectAllCheckbox: 'Select all checkbox',\n SelectRow: 'Select row',\n autoFitAll: 'Autofit all columns',\n autoFit: 'Autofit this column',\n AutoFitAll: 'Autofit all columns',\n AutoFit: 'Autofit this column',\n Export: 'Export',\n FirstPage: 'First Page',\n LastPage: 'Last Page',\n PreviousPage: 'Previous Page',\n NextPage: 'Next Page',\n SortAscending: 'Sort Ascending',\n SortDescending: 'Sort Descending',\n EditRecord: 'Edit Record',\n DeleteRecord: 'Delete Record',\n FilterMenu: 'Filter',\n SelectAll: 'Select All',\n AddCurrentSelection: 'Add current selection to filter',\n Blanks: 'Blanks',\n FilterTrue: 'True',\n FilterFalse: 'False',\n NoResult: 'No matches found',\n ClearFilter: 'Clear Filter',\n Clear: 'Clear',\n NumberFilter: 'Number Filters',\n TextFilter: 'Text Filters',\n DateFilter: 'Date Filters',\n DateTimeFilter: 'DateTime Filters',\n MatchCase: 'Match Case',\n Between: 'Between',\n CustomFilter: 'Custom Filter',\n CustomFilterPlaceHolder: 'Enter the value',\n CustomFilterDatePlaceHolder: 'Choose a date',\n AND: 'AND',\n OR: 'OR',\n ShowRowsWhere: 'Show rows where:',\n ToolbarMenuDialogARIA: 'Toolbar menu dialog',\n FilterMenuDialogARIA: 'Filter menu',\n ExcelFilterDialogARIA: 'Excel filter',\n CheckBoxFilterDialogARIA: 'Checkbox filter',\n DialogEditARIA: 'Edit dialog',\n ColumnMenuDialogARIA: 'Column menu dialog',\n CustomFilterDialogARIA: 'Customer filter dialog',\n SortAtoZ: 'Sort A to Z',\n SortZtoA: 'Sort Z to A',\n SortByOldest: 'Sort by Oldest',\n SortByNewest: 'Sort by Newest',\n SortSmallestToLargest: 'Sort Smallest to Largest',\n SortLargestToSmallest: 'Sort Largest to Smallest',\n Sort: 'Sort',\n FilterDescription: 'Press Alt Down to open filter Menu',\n SortDescription: 'Press Enter to sort',\n ColumnMenuDescription: 'Press Alt Down to open Column Menu',\n GroupDescription: 'Press Ctrl space to group',\n ColumnHeader: ' column header ',\n TemplateCell: ' is template cell',\n CommandColumnAria: 'is Command column column header ',\n DialogEdit: 'Dialog edit',\n ClipBoard: 'clipboard',\n AscendingText: 'Ascending',\n DescendingText: 'Descending',\n NoneText: 'None',\n Expanded: 'Expanded',\n Collapsed: 'Collapsed'\n };\n this.keyConfigs = {\n downArrow: 'downarrow',\n upArrow: 'uparrow',\n rightArrow: 'rightarrow',\n leftArrow: 'leftarrow',\n shiftDown: 'shift+downarrow',\n shiftUp: 'shift+uparrow',\n shiftRight: 'shift+rightarrow',\n shiftLeft: 'shift+leftarrow',\n home: 'home',\n end: 'end',\n escape: 'escape',\n ctrlHome: 'ctrl+home',\n ctrlEnd: 'ctrl+end',\n pageUp: 'pageup',\n pageDown: 'pagedown',\n ctrlAltPageUp: 'ctrl+alt+pageup',\n ctrlAltPageDown: 'ctrl+alt+pagedown',\n altPageUp: 'alt+pageup',\n altPageDown: 'alt+pagedown',\n altDownArrow: 'alt+downarrow',\n altUpArrow: 'alt+uparrow',\n ctrlDownArrow: 'ctrl+downarrow',\n ctrlUpArrow: 'ctrl+uparrow',\n ctrlPlusA: 'ctrl+A',\n ctrlPlusP: 'ctrl+P',\n insert: 'insert',\n delete: 'delete',\n f2: 'f2',\n enter: 'enter',\n ctrlEnter: 'ctrl+enter',\n shiftEnter: 'shift+enter',\n tab: 'tab',\n shiftTab: 'shift+tab',\n space: 'space',\n ctrlPlusC: 'ctrl+C',\n ctrlShiftPlusH: 'ctrl+shift+H',\n ctrlSpace: 'ctrl+space',\n ctrlLeftArrow: 'ctrl+leftarrow',\n ctrlRightArrow: 'ctrl+rightarrow'\n };\n };\n /**\n * For internal use only - To Initialize the component rendering.\n *\n * @returns {void}\n * @private\n */\n Grid.prototype.render = function () {\n this.log(['module_missing', 'promise_enabled', 'locale_missing', 'check_datasource_columns']);\n this.ariaService.setOptions(this.element, { role: 'grid' });\n createSpinner({ target: this.element, cssClass: this.cssClass ? this.cssClass : null }, this.createElement);\n this.renderModule = new Render(this, this.serviceLocator);\n this.searchModule = new Search(this);\n this.scrollModule = new Scroll(this);\n this.notify(events.initialLoad, {});\n if ((this.getDataModule().dataManager.dataSource.offline === true || this.getDataModule().dataManager.dataSource.url === undefined) &&\n !(!isNullOrUndefined(this.dataSource) && this.dataSource.result)) {\n this.isVirtualAdaptive = true;\n }\n if (this.isReact) {\n var args = { requireTemplateRef: this.requireTemplateRef };\n this.trigger(events.load, args);\n if (!args.requireTemplateRef) {\n this.requireTemplateRef = args.requireTemplateRef;\n }\n }\n else {\n this.trigger(events.load);\n }\n prepareColumns(this.columns, this.enableColumnVirtualization, this);\n if (this.enableColumnVirtualization && this.isChangeDataSourceCall && this.columnModel) {\n this.columnModel = [];\n this.updateColumnModel(this.columns);\n }\n this.isPreparedFrozenColumns = true;\n if (this.enablePersistence) {\n this.notify(events.columnsPrepared, {});\n }\n this.getMediaColumns();\n setColumnIndex(this.columns);\n if (this.isFrozenGrid() && !this.mergedColumns) {\n this.setInitialFrozenColumnIndex(this.columns);\n }\n this.checkLockColumns(this.columns);\n this.getColumns();\n this.processModel();\n this.gridRender();\n this.wireEvents();\n this.addListener();\n this.updateDefaultCursor();\n this.updateStackedFilter();\n if (this.loadingIndicator.indicatorType === 'Spinner') {\n this.showSpinner();\n }\n this.notify(events.initialEnd, {});\n if (this.loadingIndicator.indicatorType === 'Shimmer') {\n this.refreshMaskRow();\n }\n if (this.refreshing) {\n this.trigger('created');\n }\n };\n Grid.prototype.setInitialFrozenColumnIndex = function (columns) {\n for (var i = 0; i < columns.length; i++) {\n var column = columns[parseInt(i.toString(), 10)];\n column[\"\" + literals.initialFrozenColumnIndex] = column.index;\n if (column.columns) {\n this.setInitialFrozenColumnIndex(column.columns);\n }\n }\n };\n /**\n * By default, grid shows the spinner for all its actions. You can use this method to show spinner at your needed time.\n *\n * @returns {void}\n */\n Grid.prototype.showSpinner = function () {\n if (!this.isExportGrid) {\n showSpinner(this.element);\n }\n };\n /**\n * By default, grid shows the spinner for all its actions. You can use this method to show spinner at your needed time.\n *\n * @returns {void}\n */\n Grid.prototype.hideSpinner = function () {\n if (!this.isExportGrid) {\n hideSpinner(this.element);\n }\n };\n Grid.prototype.showMaskRow = function (axisDirection, dialogElement) {\n if (isNullOrUndefined(this.headerModule) || isNullOrUndefined(this.contentModule)) {\n return;\n }\n var gridHeader = this.getHeaderContent().firstChild;\n var gridContent = this.getContent().firstChild;\n var gridFooter = this.getFooterContent();\n if (dialogElement) {\n var dialogHolder = dialogElement.querySelector('.e-checkboxlist');\n var maskRowCount = Math.floor(dialogHolder.getBoundingClientRect().height / this.getRowHeight());\n var maskTemplate = '<div class=\"e-ftrchk e-mask-ftrchk\" style=\"width: 100%;\">'\n + '<div class=\"e-checkbox-wrapper\" style=\"width: 100%;\"><input class=\"e-chk-hidden\">'\n + this.getShimmerTemplate() + this.getShimmerTemplate() + '</div></div>';\n dialogHolder.innerHTML = '';\n for (var i = 0; i < maskRowCount; i++) {\n dialogHolder.innerHTML += maskTemplate;\n var maskSpan = [].slice.call(dialogHolder\n .querySelectorAll('.e-mask:not(.e-mask-checkbox-filter-intent):not(.e-mask-checkbox-filter-span-intent)'));\n maskSpan[0].classList.add('e-mask-checkbox-filter-intent');\n maskSpan[1].classList.add('e-mask-checkbox-filter-span-intent');\n }\n return;\n }\n if ((!this.enableRtl && !this.getHeaderContent().style.paddingRight)\n || (this.enableRtl && !this.getHeaderContent().style.paddingLeft)) {\n gridContent.style.overflowY = 'hidden';\n }\n if (!this.isInitialLoad && !this.getColumns().length) {\n var contentHeight = gridContent.getBoundingClientRect().height;\n var maskTableHeight = contentHeight === 0 ? this.allowPaging ? this.pageSettings.pageSize * this.getRowHeight()\n : window.innerHeight : contentHeight;\n var contentRowCount = Math.ceil(maskTableHeight / this.getRowHeight());\n if (this.rowRenderingMode !== 'Vertical') {\n this.headerMaskTable = this.createEmptyMaskTable(gridHeader, 1);\n }\n this.contentMaskTable = this.createEmptyMaskTable(gridContent, contentRowCount);\n return;\n }\n this.maskRowContentScroll = (this.enableVirtualization || this.enableColumnVirtualization) && axisDirection ? true : false;\n if (!this.contentMaskTable) {\n var content = gridContent;\n if (this.enableVirtualization || this.enableColumnVirtualization) {\n content = content.querySelector('.e-virtualtable');\n }\n if (!isNullOrUndefined(content.querySelector('tbody'))) {\n this.contentMaskTable = this.createMaskTable(content, this.getContentMaskColumns(), axisDirection);\n }\n }\n if (!this.headerMaskTable && (this.isFrozenGrid() || (this.enableColumnVirtualization && axisDirection === 'X'))) {\n var content = gridHeader;\n if (this.enableColumnVirtualization && axisDirection === 'X') {\n content = content.querySelector('.e-virtualtable');\n }\n this.headerMaskTable = this.createMaskTable(content, this.getContentMaskColumns(), axisDirection);\n }\n if (gridFooter && gridFooter.querySelector('.e-summaryrow')) {\n var gridFooterContent = gridFooter.firstChild;\n if (!this.footerContentMaskTable) {\n var footerContent = gridFooterContent;\n this.footerContentMaskTable = this.createMaskTable(footerContent);\n }\n }\n if (!(this.enableVirtualization && axisDirection)) {\n EventHandler.add(gridContent, 'scroll', this.translateMaskRow, this);\n }\n };\n Grid.prototype.getContentMaskColumns = function () {\n return this.getColumns();\n };\n Grid.prototype.createEmptyMaskTable = function (maskElement, rowCount) {\n var table = this.createElement('table', { className: 'e-table e-masked-table' });\n var tbody = this.createElement('tbody', { className: 'e-masked-tbody' });\n var row = this.createElement('tr', { className: 'e-masked-row e-row', attrs: {\n style: 'height: ' + this.getRowHeight() + 'px;'\n } });\n var cell = this.createElement('td', { className: 'e-masked-cell e-rowcell' });\n cell.innerHTML = this.getShimmerTemplate();\n row.appendChild(cell);\n for (var i = 0; i < rowCount; i++) {\n tbody.appendChild(row.cloneNode(true));\n }\n table.appendChild(tbody);\n maskElement.appendChild(table);\n return table;\n };\n Grid.prototype.createMaskTable = function (element, columns, axisDirection) {\n var parentElement = element;\n var header = closest(parentElement, '.e-gridheader') ? true : false;\n var content = closest(parentElement, '.e-gridcontent') ? true : false;\n var footer = closest(parentElement, '.e-gridfooter') ? true : false;\n var gridContent = this.getContent().firstChild;\n var gridContentScrollHeight = gridContent.scrollHeight;\n var table = parentElement.querySelector('table');\n var maskTable = table.cloneNode();\n maskTable.removeAttribute('role');\n maskTable.removeAttribute('id');\n maskTable.style.position = 'absolute';\n maskTable.style.zIndex = '5';\n maskTable.style.width = table.getBoundingClientRect().width + 'px';\n if (header && !(this.enableColumnVirtualization && axisDirection === 'X')) {\n maskTable.style.transform = 'translate(0px,'\n + table.querySelector('thead').getBoundingClientRect().height + 'px)';\n }\n maskTable.setAttribute('class', 'e-table e-masked-table');\n var maskColgroup = table.querySelector('colgroup').cloneNode(true);\n maskColgroup.removeAttribute('id');\n maskColgroup.setAttribute('class', 'e-masked-colgroup');\n maskTable.appendChild(maskColgroup);\n if (header && this.enableColumnVirtualization && axisDirection === 'X') {\n var row = this.createMaskRow(maskColgroup, columns);\n if (this.isFrozenGrid()) {\n var frzTd = [].slice.call(row.querySelectorAll('.e-rowcell'));\n for (var i = 0; i < frzTd.length; i++) {\n if (i < this.frozenLeftCount) {\n if (this.frozenLeftCount - 1 === i) {\n frzTd[parseInt(i.toString(), 10)].classList.add('e-freezeleftborder');\n }\n frzTd[parseInt(i.toString(), 10)].classList.add('e-leftfreeze');\n frzTd[parseInt(i.toString(), 10)].setAttribute('data-colindex', i.toString());\n frzTd[parseInt(i.toString(), 10)].style.left = (columns[parseInt(i.toString(), 10)].valueX -\n this.translateX) + 'px';\n }\n else if ((frzTd.length - this.frozenRightCount) <= i && columns[parseInt(i.toString(), 10)]) {\n if ((frzTd.length - this.frozenRightCount) === i) {\n frzTd[parseInt(i.toString(), 10)].classList.add('e-freezerightborder');\n }\n frzTd[parseInt(i.toString(), 10)].classList.add('e-rightfreeze');\n frzTd[parseInt(i.toString(), 10)].setAttribute('data-colindex', i.toString());\n frzTd[parseInt(i.toString(), 10)].style.right = (this.translateX +\n columns[parseInt(i.toString(), 10)].valueX) + 'px';\n }\n }\n }\n var thead = table.querySelector('thead');\n var rows = [].slice.call(thead.querySelectorAll('tr'));\n var maskTHead = thead.cloneNode();\n maskTHead.removeAttribute('role');\n maskTHead.setAttribute('class', 'e-masked-thead');\n var rowCount = rows.length;\n for (var i = 0; i < rowCount; i++) {\n maskTHead.appendChild(row.cloneNode(true));\n maskTHead.childNodes[parseInt(i.toString(), 10)].style\n .height = rows[parseInt(i.toString(), 10)].getBoundingClientRect().height + 'px';\n }\n maskTable.appendChild(maskTHead);\n }\n var maskTBody = table.querySelector('tbody').cloneNode();\n maskTBody.removeAttribute('role');\n maskTBody.setAttribute('class', 'e-masked-tbody');\n var tbody = table.querySelector('tbody');\n if (content || header) {\n var rowCountElement = gridContent;\n var rowCount = Math.ceil(rowCountElement.getBoundingClientRect().height / this.getRowHeight());\n if (tbody.querySelector('.e-emptyrow') || !tbody.childNodes.length || (content && this.childGrid)) {\n var row = this.createMaskRow(maskColgroup, columns);\n var altRow = row.cloneNode(true);\n altRow.classList.add('e-altrow');\n for (var i = 0; i < rowCount; i++) {\n var altNumber = 1;\n maskTBody.appendChild((i + altNumber) % 2 === 0 ? altRow.cloneNode(true) : row.cloneNode(true));\n }\n }\n else {\n var rowsQuery = 'tr:not([style*=\"display:none\"]):not([style*=\"display: none\"])';\n var rows = [].slice.call(tbody.querySelectorAll(rowsQuery));\n var addEditRow = tbody.querySelector('.e-addedrow, .e-editedrow');\n var addEditRowIndex = void 0;\n if (addEditRow) {\n addEditRowIndex = rows.indexOf(addEditRow);\n if (this.isFrozenGrid() && this.enableColumnVirtualization) {\n var frzTd = [].slice.call(rows[addEditRowIndex + 1].querySelectorAll('.e-rowcell'));\n for (var i = 0; i < frzTd.length; i++) {\n if (i < this.frozenLeftCount) {\n frzTd[parseInt(i.toString(), 10)].classList.add('e-leftfreeze');\n frzTd[parseInt(i.toString(), 10)].setAttribute('data-colindex', i.toString());\n frzTd[parseInt(i.toString(), 10)].style.left = (columns[parseInt(i.toString(), 10)].valueX - this.translateX) + 'px';\n }\n else if ((frzTd.length - this.frozenRightCount) <= i && columns[parseInt(i.toString(), 10)]) {\n frzTd[parseInt(i.toString(), 10)].classList.add('e-rightfreeze');\n frzTd[parseInt(i.toString(), 10)].setAttribute('data-colindex', i.toString());\n frzTd[parseInt(i.toString(), 10)].style.right = (this.translateX +\n columns[parseInt(i.toString(), 10)].valueX) + 'px';\n }\n }\n }\n if (addEditRow.classList.contains('e-addedrow')) {\n rows.splice(addEditRowIndex, 2);\n }\n else {\n rows.splice(addEditRowIndex, 1);\n }\n }\n rowCount = (this.enableVirtualization || this.enableColumnVirtualization) && axisDirection ? rows.length\n : rowCount <= rows.length ? rowCount : rows.length;\n for (var i = 0; i < rowCount; i++) {\n maskTBody.appendChild(this.applyMaskRow(rows[parseInt(i.toString(), 10)].cloneNode(true), rows[parseInt(i.toString(), 10)].getBoundingClientRect().height));\n }\n if (addEditRow && addEditRow.classList.contains('e-editedrow') && addEditRowIndex < rowCount) {\n var addEditMaskRow = maskTBody.childNodes[parseInt(addEditRowIndex.toString(), 10)];\n addEditMaskRow.style.height = this.getRowHeight() + 'px';\n addEditMaskRow.classList.add('e-row');\n if (addEditRow.classList.contains('e-altrow')) {\n addEditMaskRow.classList.add('e-altrow');\n }\n }\n }\n }\n maskTable.appendChild(maskTBody);\n if (footer) {\n var tfoot = table.querySelector('tfoot');\n var maskTFoot = tfoot.cloneNode();\n maskTFoot.setAttribute('class', 'e-masked-tfoot');\n var rows = [].slice.call(tfoot.querySelectorAll('tr'));\n for (var i = 0; i < rows.length; i++) {\n maskTFoot.appendChild(this.applyMaskRow(rows[parseInt(i.toString(), 10)].cloneNode(true), rows[parseInt(i.toString(), 10)].getBoundingClientRect().height));\n }\n maskTable.appendChild(maskTFoot);\n }\n if (header && this.isFrozenGrid() && !this.enableColumnVirtualization) {\n this.getHeaderContent().querySelector('.' + literals.headerContent).style.position = 'relative';\n }\n parentElement.insertBefore(maskTable, parentElement.firstChild);\n if (content && !(this.enableVirtualization && axisDirection)) {\n var minScrollTop = gridContentScrollHeight - maskTable.getBoundingClientRect().height;\n minScrollTop = minScrollTop < 0 ? 0 : minScrollTop;\n var scrollTop = gridContent.scrollTop <= minScrollTop ? gridContent.scrollTop : minScrollTop;\n if (this.enableVirtualization) {\n scrollTop -= getTransformValues(closest(parentElement, '.e-virtualtable')).height;\n }\n maskTable.style.transform = 'translate(0px,' + scrollTop + 'px)';\n }\n return maskTable;\n };\n Grid.prototype.applyMaskRow = function (row, rowHeight) {\n var maskRow = row;\n maskRow.removeAttribute('role');\n maskRow.removeAttribute('aria-rowindex');\n maskRow.removeAttribute('data-rowindex');\n maskRow.removeAttribute('data-uid');\n maskRow.classList.add('e-masked-row');\n maskRow.style.height = rowHeight + 'px';\n var maskCells = [].slice.call(maskRow.childNodes);\n for (var i = 0; i < maskCells.length; i++) {\n var maskCell = maskCells[parseInt(i.toString(), 10)];\n var displayAsCheckBoxCell = maskCell.firstChild && maskCell.firstChild.classList\n && maskCell.firstChild.classList.contains('e-checkbox-wrapper');\n maskCell.removeAttribute('role');\n maskCell.removeAttribute('tabindex');\n maskCell.removeAttribute('aria-label');\n if (this.enableColumnVirtualization && maskCell.classList.contains('e-fixedfreeze')) {\n removeClass([maskCell], ['e-fixedfreeze', 'e-freezeleftborder', 'e-freezerightborder']);\n addClass([maskCell], ['e-unfreeze']);\n }\n if (!(this.enableColumnVirtualization && (maskCell.classList.contains('e-leftfreeze') ||\n maskCell.classList.contains('e-rightfreeze')))) {\n maskCell.removeAttribute('data-colindex');\n }\n maskCell.removeAttribute('aria-colindex');\n maskCell.removeAttribute('index');\n maskCell.removeAttribute('ej-mappingname');\n maskCell.removeAttribute('ej-mappingvalue');\n maskCell.removeAttribute('e-mappinguid');\n maskCell.removeAttribute('aria-expanded');\n maskCell.classList.add('e-masked-cell');\n maskCell.innerHTML = this.getShimmerTemplate();\n if (maskCell.classList.contains('e-recordplusexpand') || maskCell.classList.contains('e-recordpluscollapse')) {\n maskCell.firstChild.classList.add('e-mask-group-intent');\n }\n else if (maskCell.classList.contains('e-gridchkbox') || displayAsCheckBoxCell) {\n maskCell.firstChild.classList.add('e-mask-checkbox-intent');\n }\n else if (maskCell.classList.contains('e-rowdragdrop')) {\n maskCell.firstChild.classList.add('e-mask-drag-intent');\n }\n else if (maskCell.classList.contains('e-indentcell')) {\n maskCell.innerHTML = '';\n }\n }\n return maskRow;\n };\n Grid.prototype.createMaskRow = function (refColgroup, refColumns) {\n var colgroup = refColgroup;\n var columns = refColumns;\n var row = this.createElement('tr', { className: 'e-masked-row e-row' });\n if (this.rowRenderingMode !== 'Vertical') {\n row.style.height = this.getRowHeight() + 'px';\n }\n var td = this.createElement('td', { className: 'e-masked-cell e-rowcell' });\n for (var i = 0, colIndex = 0; i < colgroup.childNodes.length; i++) {\n var col = colgroup.childNodes[parseInt(i.toString(), 10)];\n var localTD = td.cloneNode();\n localTD.innerHTML = this.getShimmerTemplate();\n if (!(col.classList.contains('e-group-intent') || col.classList.contains('e-detail-intent')\n || col.classList.contains('e-drag-intent'))) {\n if (this.rowRenderingMode === 'Vertical' && columns[parseInt(colIndex.toString(), 10)]) {\n localTD.setAttribute('data-cell', columns[parseInt(colIndex.toString(), 10)].headerText ?\n columns[parseInt(colIndex.toString(), 10)].headerText : columns[parseInt(colIndex.toString(), 10)].field);\n }\n if (col.style.display === 'none') {\n localTD.classList.add('e-hide');\n }\n else {\n localTD.style.textAlign = columns[parseInt(colIndex.toString(), 10)]\n && columns[parseInt(colIndex.toString(), 10)].textAlign ?\n columns[parseInt(colIndex.toString(), 10)].textAlign.toLowerCase()\n : this.enableRtl ? 'right' : 'left';\n if (columns[parseInt(colIndex.toString(), 10)] && (columns[parseInt(colIndex.toString(), 10)].type === 'checkbox'\n || columns[parseInt(colIndex.toString(), 10)].displayAsCheckBox)) {\n localTD.firstChild.classList.add('e-mask-checkbox-intent');\n }\n }\n colIndex++;\n }\n else {\n if (col.classList.contains('e-group-intent')) {\n localTD.firstChild.classList.add('e-mask-group-intent');\n }\n else if (col.classList.contains('e-detail-intent')) {\n localTD.firstChild.classList.add('e-mask-detail-intent');\n }\n else if (col.classList.contains('e-drag-intent')) {\n localTD.firstChild.classList.add('e-mask-drag-intent');\n }\n }\n row.appendChild(localTD);\n }\n return row;\n };\n Grid.prototype.getShimmerTemplate = function () {\n if (this.maskRowContentScroll) {\n return '<span class=\"e-mask e-skeleton e-skeleton-text\"></span>';\n }\n return '<span class=\"e-mask e-skeleton e-skeleton-text e-shimmer-wave\"></span>';\n };\n Grid.prototype.addShimmerEffect = function () {\n this.maskRowContentScroll = false;\n var maskSpan = [].slice.call(this.element.querySelectorAll('.e-mask:not(.e-shimmer-wave)'));\n for (var i = 0; i < maskSpan.length; i++) {\n if (maskSpan[parseInt(i.toString(), 10)]) {\n maskSpan[parseInt(i.toString(), 10)].classList.add('e-shimmer-wave');\n }\n }\n };\n Grid.prototype.translateMaskRow = function (e) {\n var target = e.target;\n var maskTables = target.querySelectorAll('.e-masked-table');\n for (var i = 0; i < maskTables.length; i++) {\n var maskTable = maskTables[parseInt(i.toString(), 10)];\n if (maskTable) {\n var minScrollTop = target.scrollHeight - maskTable.getBoundingClientRect().height;\n minScrollTop = minScrollTop < 0 ? 0 : minScrollTop;\n var scrollTop = target.scrollTop <= minScrollTop ? target.scrollTop : minScrollTop;\n if (this.enableVirtualization) {\n scrollTop -= getTransformValues(closest(maskTable, '.e-virtualtable')).height;\n }\n maskTable.style.transform = 'translate(0px,' + scrollTop + 'px)';\n }\n }\n };\n Grid.prototype.removeMaskRow = function () {\n if (!isNullOrUndefined(this.contentModule)) {\n var gridContent = this.getContent().firstChild;\n EventHandler.remove(gridContent, 'scroll', this.translateMaskRow);\n }\n if (this.headerMaskTable && this.isFrozenGrid() && !this.enableColumnVirtualization) {\n this.getHeaderContent().querySelector('.' + literals.headerContent).style.position = '';\n }\n var maskTables = [this.headerMaskTable,\n this.contentMaskTable, this.footerContentMaskTable];\n for (var i = 0; i < maskTables.length; i++) {\n var maskTable = maskTables[parseInt(i.toString(), 10)];\n if (maskTable) {\n remove(maskTable);\n }\n }\n this.headerMaskTable = null;\n this.contentMaskTable = null;\n this.footerContentMaskTable = null;\n };\n Grid.prototype.refreshMaskRow = function () {\n var gridContent = this.getContent().firstChild;\n if (!this.isInitialLoad && !this.getColumns().length) {\n return;\n }\n if (this.contentMaskTable && gridContent.querySelector('.e-masked-table')) {\n var content = gridContent;\n if (this.enableVirtualization) {\n content = content.querySelector('.e-virtualtable');\n }\n this.refreshMaskRowColgroupWidth(content);\n }\n };\n Grid.prototype.refreshMaskRowColgroupWidth = function (content) {\n var table = content.querySelector('table:not(.e-masked-table)');\n var colgroup = table.querySelector(literals.colGroup).cloneNode(true);\n var maskTable = content.querySelector('.e-masked-table');\n colgroup.removeAttribute('id');\n colgroup.setAttribute('class', 'e-masked-colgroup');\n for (var i = 0; i < colgroup.childNodes.length; i++) {\n colgroup.childNodes[parseInt(i.toString(), 10)].removeAttribute('class');\n }\n remove(maskTable.querySelector('.e-masked-colgroup'));\n maskTable.insertBefore(colgroup, maskTable.firstChild);\n maskTable.style.width = table.getBoundingClientRect().width + 'px';\n };\n Grid.prototype.updateStackedFilter = function () {\n if (this.allowFiltering && this.filterSettings.type === 'FilterBar' &&\n this.getHeaderContent().getElementsByClassName('e-stackedheadercell').length) {\n this.getHeaderContent().classList.add('e-stackedfilter');\n }\n else {\n this.getHeaderContent().classList.remove('e-stackedfilter');\n }\n };\n Grid.prototype.getMediaColumns = function () {\n if (!this.enableColumnVirtualization) {\n var gcol = this.getColumns();\n this.getShowHideService = this.serviceLocator.getService('showHideService');\n if (!isNullOrUndefined(gcol)) {\n for (var index = 0; index < gcol.length; index++) {\n if (!isNullOrUndefined(gcol[parseInt(index.toString(), 10)].hideAtMedia)\n && (isNullOrUndefined(gcol[parseInt(index.toString(), 10)].visible)\n || gcol[parseInt(index.toString(), 10)].visible)) {\n this.pushMediaColumn(gcol[parseInt(index.toString(), 10)], index);\n }\n }\n }\n }\n this.updateFrozenColumnsWidth();\n };\n Grid.prototype.pushMediaColumn = function (col, index) {\n this.mediaCol.push(col);\n this.media[col.uid] = window.matchMedia(col.hideAtMedia);\n this.mediaQueryUpdate(index, this.media[col.uid]);\n this.mediaBindInstance[parseInt(index.toString(), 10)] = this.mediaQueryUpdate.bind(this, index);\n this.media[col.uid].addListener(this.mediaBindInstance[parseInt(index.toString(), 10)]);\n };\n /**\n * @param {Column} col - specifies the column\n * @returns {void}\n * @hidden\n */\n Grid.prototype.updateMediaColumns = function (col) {\n if (!this.enableColumnVirtualization) {\n var index = this.getColumnIndexByUid(col.uid);\n for (var i = 0; i < this.mediaCol.length; i++) {\n if (col.uid === this.mediaCol[parseInt(i.toString(), 10)].uid) {\n this.mediaCol.splice(i, 1);\n return;\n }\n }\n this.pushMediaColumn(col, index);\n }\n };\n /**\n * @param {number} columnIndex - specifies the column index\n * @param {MediaQueryList} e - specifies the MediaQueryList\n * @returns {void}\n * @hidden\n */\n Grid.prototype.mediaQueryUpdate = function (columnIndex, e) {\n var col = this.getColumns()[parseInt(columnIndex.toString(), 10)];\n if (this.mediaCol.some(function (mediaColumn) { return mediaColumn.uid === col.uid; })) {\n col.visible = e.matches;\n if (this.isInitialLoad) {\n this.invokedFromMedia = true;\n if (col.visible) {\n this.showHider.show(col.headerText, 'headerText');\n }\n else {\n this.showHider.hide(col.headerText, 'headerText');\n }\n }\n }\n };\n Grid.prototype.refreshMediaCol = function () {\n this.isInitialLoad = true;\n var footerContent = this.element.querySelector('.' + literals.gridFooter);\n if (this.aggregates.length && this.element.scrollHeight > parseInt(this.height.toString(), 10) && footerContent) {\n addClass([footerContent], ['e-footerpadding']);\n }\n var checkboxColumn = this.getColumns().filter(function (col) { return col.type === 'checkbox'; });\n if (checkboxColumn.length === 0 || checkboxColumn.length && this.selectionSettings.checkboxMode === 'ResetOnRowClick') {\n this.isCheckBoxSelection = false;\n }\n if (this.rowRenderingMode === 'Vertical') {\n if (this.enableHover) {\n this.setProperties({ enableAdaptiveUI: true, enableHover: false }, true);\n removeClass([this.element], 'e-gridhover');\n }\n }\n if (this.enableAdaptiveUI && this.scrollModule) {\n this.scrollModule.refresh();\n }\n if (this.isFrozenGrid() && this.isAutoGenerateColumns) {\n this.widthService.setWidthToColumns();\n this.isAutoGenerateColumns = false;\n }\n };\n Grid.prototype.removeMediaListener = function () {\n for (var i = 0; i < this.mediaCol.length; i++) {\n this.media[this.mediaCol[parseInt(i.toString(), 10)].uid]\n .removeListener(this.mediaBindInstance[this.mediaCol[parseInt(i.toString(), 10)].index]);\n }\n };\n /**\n * For internal use only - Initialize the event handler\n *\n * @returns {void}\n * @private\n */\n Grid.prototype.eventInitializer = function () {\n //eventInitializer\n };\n /**\n * Destroys the component (detaches/removes all event handlers, attributes, classes, and empties the component element).\n *\n * @function destroy\n * @returns {void}\n */\n Grid.prototype.destroy = function () {\n var gridElement = this.element;\n if (!gridElement) {\n return;\n }\n var hasGridChild = gridElement.querySelector('.' + literals.gridHeader) &&\n gridElement.querySelector('.' + literals.gridContent) ? true : false;\n if (hasGridChild) {\n this.unwireEvents();\n }\n this.removeListener();\n this.removeMediaListener();\n this.notify(events.destroy, {});\n this.destroyDependentModules();\n if (this.isReact) {\n this.destroyTemplate(['template']);\n }\n if (this.isVue) {\n this.destroyTemplate();\n }\n if (hasGridChild) {\n _super.prototype.destroy.call(this);\n }\n this.toolTipObj.destroy();\n if (this.isReact && !Browser.isIE) {\n this.element.innerHTML = '';\n }\n var modules = ['renderModule', 'headerModule', 'contentModule', 'valueFormatterService',\n 'serviceLocator', 'ariaService', 'keyboardModule', 'widthService', 'searchModule', 'showHider',\n 'scrollModule', 'printModule', 'clipboardModule', 'focusModule'];\n for (var i = 0; i < modules.length; i++) {\n if (this[modules[parseInt(i.toString(), 10)]]) {\n this[modules[parseInt(i.toString(), 10)]] = null;\n }\n }\n this.element.innerHTML = '';\n classList(this.element, [], ['e-rtl', 'e-gridhover', 'e-responsive', 'e-default', 'e-device', 'e-grid-min-height']);\n };\n Grid.prototype.destroyDependentModules = function () {\n var gridElement = this.element;\n if (!gridElement || (!gridElement.querySelector('.' + literals.gridHeader) && !gridElement.querySelector('.' + literals.gridContent))) {\n return;\n }\n this.scrollModule.destroy();\n this.keyboardModule.destroy();\n this.focusModule.destroy();\n this.clipboardModule.destroy();\n this.printModule.destroy();\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Grid.prototype.getModuleName = function () {\n return 'grid';\n };\n Grid.prototype.enableBoxSelection = function () {\n if (this.enableAutoFill) {\n this.selectionSettings.cellSelectionMode = 'BoxWithBorder';\n this.element.classList.add('e-afenabled');\n }\n else {\n this.element.classList.remove('e-afenabled');\n }\n };\n Grid.prototype.setCSSClass = function (oldCSSClass) {\n if (this.cssClass) {\n addClass([this.element], this.cssClass.split(' '));\n }\n if (oldCSSClass) {\n removeClass([this.element], oldCSSClass.split(' '));\n }\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @param {GridModel} newProp - Defines new properties\n * @param {GridModel} oldProp - Defines old properties\n * @returns {void}\n * @hidden\n */\n Grid.prototype.onPropertyChanged = function (newProp, oldProp) {\n var requireRefresh = false;\n var requireGridRefresh = false;\n var freezeRefresh = false;\n var checkCursor;\n var args = { requestType: 'refresh' };\n var childGridParent = null;\n var parentInstance = null;\n if (this.isDestroyed) {\n return;\n }\n this.log('module_missing');\n if (this.isEllipsisTooltip()) {\n this.toolTipObj.close();\n }\n var properties = Object.keys(newProp);\n if (properties.indexOf('columns') > -1) {\n if (this.enableColumnVirtualization) {\n this.columnModel = [];\n }\n this.updateColumnObject();\n requireGridRefresh = true;\n }\n for (var _i = 0, properties_1 = properties; _i < properties_1.length; _i++) {\n var prop = properties_1[_i];\n switch (prop) {\n case 'allowPaging':\n this.notify(events.uiUpdate, { module: 'pager', enable: this.allowPaging });\n requireRefresh = true;\n if (this.height === '100%') {\n this.scrollModule.refresh();\n }\n break;\n case 'pageSettings':\n if (this.pageTemplateChange) {\n this.pageTemplateChange = false;\n this.notify(events.inBoundModelChanged, { module: 'pager', properties: newProp.pageSettings });\n break;\n }\n if (this.pagerModule && this.pagerModule.isCancel) {\n this.pagerModule.isCancel = false;\n return;\n }\n this.notify(events.inBoundModelChanged, { module: 'pager', properties: newProp.pageSettings });\n if (isNullOrUndefined(newProp.pageSettings.currentPage) && isNullOrUndefined(newProp.pageSettings.pageSize)\n && isNullOrUndefined(newProp.pageSettings.totalRecordsCount)\n || !isNullOrUndefined(oldProp.pageSettings) &&\n ((newProp.pageSettings.currentPage !== oldProp.pageSettings.currentPage)\n && !this.enableColumnVirtualization && !this.enableVirtualization\n && this.pageSettings.totalRecordsCount <= this.pageSettings.pageSize)) {\n requireRefresh = true;\n }\n if (this.pagerModule && this.pagerModule.isCancel) {\n this.pagerModule.isCancel = false;\n }\n break;\n case 'allowSorting':\n this.notify(events.uiUpdate, { module: 'sort', enable: this.allowSorting });\n requireRefresh = true;\n checkCursor = true;\n break;\n case 'allowFiltering':\n this.updateStackedFilter();\n this.notify(events.uiUpdate, { module: 'filter', enable: this.allowFiltering });\n requireRefresh = true;\n if (this.filterSettings.type !== 'FilterBar') {\n this.refreshHeader();\n }\n else {\n if (this.height === '100%') {\n this.scrollModule.refresh();\n }\n }\n break;\n case 'height':\n case 'width':\n this.notify(events.uiUpdate, { module: 'scroll', properties: { width: newProp.width, height: newProp.height } });\n if (this.allowPaging) {\n this.pagerModule.refresh();\n }\n break;\n case 'allowReordering':\n this.headerModule.refreshUI();\n checkCursor = true;\n break;\n case 'allowRowDragAndDrop':\n this.notify(events.uiUpdate, { module: 'rowDragAndDrop', enable: this.allowRowDragAndDrop });\n this.renderModule.refresh();\n this.headerModule.refreshUI();\n break;\n case 'allowSelection':\n this.notify(events.uiUpdate, { module: 'selection', enable: this.allowSelection });\n break;\n case 'cssClass':\n this.setCSSClass(oldProp.cssClass);\n break;\n case 'enableAutoFill':\n if (this.selectionModule) {\n this.enableBoxSelection();\n this.selectionModule.updateAutoFillPosition();\n }\n break;\n case 'rowTemplate':\n this.rowTemplateFn = templateCompiler(this.rowTemplate);\n requireRefresh = true;\n break;\n case 'emptyRecordTemplate':\n this.emptyRecordTemplateFn = templateCompiler(this.emptyRecordTemplate);\n requireRefresh = true;\n break;\n case 'detailTemplate':\n this.detailTemplateFn = templateCompiler(this.detailTemplate);\n requireRefresh = true;\n break;\n case 'allowGrouping':\n this.notify(events.uiUpdate, { module: 'group', enable: this.allowGrouping });\n this.headerModule.refreshUI();\n requireRefresh = true;\n checkCursor = true;\n if (this.height === '100%') {\n this.scrollModule.refresh();\n }\n break;\n case 'enableInfiniteScrolling':\n case 'childGrid':\n requireRefresh = true;\n childGridParent = this.parentDetails ? document.querySelector(\"#\" + this.parentDetails.parentID) : null;\n parentInstance = childGridParent ? childGridParent.ej2_instances[0] : null;\n if (this.childGrid && parentInstance && isNullOrUndefined(parentInstance.childGrid.childGrid)) {\n var childGridObject = Object.assign({}, parentInstance.childGrid, { childGrid: newProp.childGrid });\n parentInstance.setProperties({ childGrid: childGridObject }, true);\n while (!isNullOrUndefined(parentInstance.parentDetails)) {\n var currentParent = document.querySelector(\"#\" + parentInstance.parentDetails.parentID);\n var currentParentInstance = currentParent ? currentParent.ej2_instances[0] : null;\n if (currentParentInstance) {\n var currentChildObject = Object.assign({}, currentParentInstance.childGrid);\n currentChildObject.childGrid = parentInstance.childGrid;\n currentParentInstance.setProperties({ childGrid: currentChildObject }, true);\n }\n parentInstance = currentParentInstance;\n }\n }\n this.headerModule.refreshUI();\n break;\n case 'toolbar':\n this.notify(events.uiUpdate, { module: 'toolbar' });\n if (this.height === '100%') {\n this.scrollModule.refresh();\n }\n break;\n case 'groupSettings':\n this.notify(events.inBoundModelChanged, {\n module: 'group', properties: newProp.groupSettings,\n oldProperties: oldProp.groupSettings\n });\n break;\n case 'aggregates':\n if (!this.aggregates.length && this.allowGrouping && this.groupSettings.columns.length) {\n requireRefresh = true;\n }\n this.notify(events.uiUpdate, { module: 'aggregate', properties: newProp });\n if (this.height === '100%') {\n this.scrollModule.refresh();\n }\n break;\n case 'frozenColumns':\n case 'frozenRows':\n case 'enableVirtualization':\n case 'enableColumnVirtualization':\n case 'currencyCode':\n case 'locale':\n this.log('frozen_rows_columns');\n freezeRefresh = true;\n requireGridRefresh = true;\n break;\n case 'query':\n if (!this.getDataModule().isQueryInvokedFromData) {\n requireRefresh = true;\n }\n this.getDataModule().isQueryInvokedFromData = false;\n break;\n case 'autoFit':\n if (this.autoFit) {\n this.preventAdjustColumns();\n }\n else {\n this.restoreAdjustColumns();\n }\n break;\n default:\n this.extendedPropertyChange(prop, newProp, requireGridRefresh);\n }\n }\n if (checkCursor) {\n this.updateDefaultCursor();\n }\n if (requireGridRefresh) {\n if (freezeRefresh || this.getFrozenColumns() || this.frozenRows) {\n this.freezeRefresh();\n }\n else {\n this.refresh();\n }\n }\n else if (requireRefresh) {\n this.notify(events.modelChanged, args);\n requireRefresh = false;\n this.maintainSelection(newProp.selectedRowIndex);\n }\n };\n Grid.prototype.extendedPropertyChange = function (prop, newProp, requireGridRefresh) {\n switch (prop) {\n case 'enableRtl':\n this.updateRTL();\n if (this.allowPaging) {\n this.element.querySelector('.e-gridpager').ej2_instances[0].enableRtl = newProp.enableRtl;\n this.element.querySelector('.e-gridpager').ej2_instances[0].dataBind();\n }\n if (this.height !== 'auto') {\n this.scrollModule.removePadding(!newProp.enableRtl);\n this.scrollModule.setPadding();\n }\n if (this.toolbar && this.toolbarModule) {\n this.toolbarModule.getToolbar().ej2_instances[0].enableRtl = newProp.enableRtl;\n this.toolbarModule.getToolbar().ej2_instances[0].dataBind();\n }\n if (this.contextMenuItems && this.contextMenuModule) {\n this.contextMenuModule.getContextMenu().ej2_instances[0].enableRtl = newProp.enableRtl;\n this.contextMenuModule.getContextMenu().ej2_instances[0].dataBind();\n }\n if (this.showColumnMenu && this.columnMenuModule && !this.enableAdaptiveUI) {\n this.columnMenuModule.getColumnMenu().ej2_instances[0].enableRtl = newProp.enableRtl;\n this.columnMenuModule.getColumnMenu().ej2_instances[0].dataBind();\n }\n if (this.filterSettings.type === 'FilterBar' && this.filterSettings.showFilterBarOperator) {\n this.refreshHeader();\n }\n this.notify(events.rtlUpdated, {});\n break;\n case 'enableAltRow':\n this.renderModule.refresh();\n break;\n case 'allowResizing':\n this.headerModule.refreshUI();\n this.updateResizeLines();\n break;\n case 'rowHeight':\n if (this.rowHeight) {\n addClass([this.element], 'e-grid-min-height');\n }\n else {\n removeClass([this.element], 'e-grid-min-height');\n }\n this.renderModule.refresh();\n this.headerModule.refreshUI();\n break;\n case 'gridLines':\n this.updateGridLines();\n break;\n case 'showColumnMenu':\n this.headerModule.refreshUI();\n this.notify(events.uiUpdate, { module: 'columnMenu', enable: true });\n break;\n case 'columnMenuItems':\n this.notify(events.uiUpdate, { module: 'columnMenu', enable: this.columnMenuItems });\n break;\n case 'contextMenuItems':\n this.notify(events.uiUpdate, { module: 'contextMenu', enable: this.contextMenuItems });\n break;\n case 'showColumnChooser':\n this.notify(events.uiUpdate, { module: 'columnChooser', enable: this.showColumnChooser });\n break;\n case 'filterSettings':\n this.updateStackedFilter();\n this.notify(events.inBoundModelChanged, { module: 'filter', properties: newProp.filterSettings });\n break;\n case 'searchSettings':\n this.notify(events.inBoundModelChanged, { module: 'search', properties: newProp.searchSettings });\n break;\n case 'sortSettings':\n this.notify(events.inBoundModelChanged, { module: 'sort' });\n break;\n case 'selectionSettings':\n this.notify(events.inBoundModelChanged, { module: 'selection', properties: newProp.selectionSettings });\n break;\n case 'editSettings':\n this.notify(events.inBoundModelChanged, { module: 'edit', properties: newProp.editSettings });\n break;\n case 'allowTextWrap':\n case 'textWrapSettings':\n if (this.allowTextWrap) {\n this.applyTextWrap();\n }\n else {\n this.removeTextWrap();\n }\n this.notify(events.freezeRender, { case: 'textwrap', isModeChg: (prop === 'textWrapSettings') });\n break;\n case 'dataSource':\n // eslint-disable-next-line no-case-declarations\n var pending_1 = this.getDataModule().getState();\n if (this.allowSelection && this.isPersistSelection && !(pending_1 && pending_1.isPending)) {\n this.clearSelection();\n }\n if (!isNullOrUndefined(this.dataSource) && this.dataSource.result) {\n this.isVirtualAdaptive = false;\n }\n if (Object.getPrototypeOf(newProp).deepWatch) {\n var pKeyField = this.getPrimaryKeyFieldNames()[0];\n for (var i = 0, props = Object.keys(newProp.dataSource); i < props.length; i++) {\n this.setRowData(getValue(pKeyField, this.dataSource[props[parseInt(i.toString(), 10)]]), this.dataSource[props[parseInt(i.toString(), 10)]]);\n }\n }\n else if (pending_1.isPending) {\n var gResult = !isNullOrUndefined(this.dataSource) ? this.dataSource.result : [];\n var names = (pending_1.group || []);\n if (names.length && !this.groupSettings.enableLazyLoading && !(gResult.length && gResult[0].field)) {\n for (var i = 0; i < names.length; i++) {\n gResult = DataUtil.group(gResult, names[parseInt(i.toString(), 10)], pending_1.aggregates || []);\n }\n }\n this.dataSource = {\n result: gResult, count: this.dataSource.count,\n aggregates: this.dataSource.aggregates\n };\n this.getDataModule().setState({});\n pending_1.resolver(this.dataSource);\n }\n else {\n this.getDataModule().setState({ isDataChanged: false });\n this.notify(events.dataSourceModified, {});\n if (!requireGridRefresh) {\n this.renderModule.refresh();\n if (this.isCheckBoxSelection) {\n this.notify(events.beforeRefreshOnDataChange, {});\n }\n }\n }\n this.scrollRefresh();\n break;\n case 'enableHover':\n // eslint-disable-next-line no-case-declarations\n var action = newProp.enableHover ? addClass : removeClass;\n action([this.element], 'e-gridhover');\n break;\n case 'selectedRowIndex':\n if (!this.isSelectedRowIndexUpdating) {\n this.selectRow(newProp.selectedRowIndex);\n }\n this.isSelectedRowIndexUpdating = false;\n break;\n case 'resizeSettings':\n this.widthService.setWidthToTable();\n break;\n case 'enableAdaptiveUI':\n this.notify(events.setFullScreenDialog, {});\n break;\n case 'rowRenderingMode':\n this.enableVerticalRendering();\n this.notify(events.rowModeChange, {});\n this.refresh();\n break;\n case 'enableStickyHeader':\n this.scrollModule.addStickyListener(newProp.enableStickyHeader);\n break;\n }\n };\n Grid.prototype.maintainSelection = function (index) {\n var _this_1 = this;\n if (index !== -1) {\n var fn_1 = function () {\n _this_1.selectRow(index);\n _this_1.off(events.contentReady, fn_1);\n };\n this.on(events.contentReady, fn_1, this);\n }\n };\n /**\n * @param {Object} prop - Defines the property\n * @param {boolean} muteOnChange - Defines the mute on change\n * @returns {void}\n * @private\n */\n Grid.prototype.setProperties = function (prop, muteOnChange) {\n _super.prototype.setProperties.call(this, prop, muteOnChange);\n var filterSettings = 'filterSettings';\n if (prop[\"\" + filterSettings] && this.filterModule && muteOnChange) {\n this.filterModule.refreshFilter();\n }\n };\n /**\n * @hidden\n * @returns {number} - Returns the tables count\n */\n Grid.prototype.getTablesCount = function () {\n return this.tablesCount;\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.updateDefaultCursor = function () {\n var headerCells = [].slice.call(this.getHeaderContent().querySelectorAll('.e-headercell:not(.e-stackedheadercell)'));\n var stdHdrCell = [].slice.call(this.getHeaderContent().getElementsByClassName('e-stackedheadercell'));\n var cols = this.getColumns();\n for (var i = 0; i < headerCells.length; i++) {\n var cell = headerCells[parseInt(i.toString(), 10)];\n if (this.allowGrouping || this.allowReordering || this.allowSorting) {\n if (!cols[parseInt(i.toString(), 10)].allowReordering || !cols[parseInt(i.toString(), 10)].allowSorting\n || !cols[parseInt(i.toString(), 10)].allowGrouping) {\n cell.classList.add('e-defaultcursor');\n }\n else {\n cell.classList.add('e-mousepointer');\n }\n }\n }\n for (var count = 0; count < stdHdrCell.length; count++) {\n if (this.allowReordering) {\n stdHdrCell[parseInt(count.toString(), 10)].classList.add('e-mousepointer');\n }\n }\n };\n Grid.prototype.updateColumnModel = function (columns, isRecursion) {\n for (var i = 0, len = columns.length; i < len; i++) {\n if (columns[parseInt(i.toString(), 10)].columns) {\n this.updateColumnModel(columns[parseInt(i.toString(), 10)].columns, true);\n }\n else {\n this.columnModel.push(columns[parseInt(i.toString(), 10)]);\n }\n }\n if (isNullOrUndefined(isRecursion) || !isRecursion) {\n this.updateLockableColumns();\n }\n };\n Grid.prototype.getFrozenLeftCount = function () {\n return this.getFrozenColumns() || this.getFrozenLeftColumnsCount();\n };\n Grid.prototype.isFrozenGrid = function () {\n return this.getFrozenColumns() !== 0 || this.frozenLeftColumns.length !== 0 || this.frozenRightColumns.length !== 0 ||\n this.fixedColumns.length !== 0;\n };\n Grid.prototype.getFrozenMode = function () {\n return this.frozenName;\n };\n Grid.prototype.updateLockableColumns = function () {\n var cols = this.columnModel;\n var frozenCount = 0;\n var movableCount = 0;\n var frozenColumns = this.getFrozenColumns();\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].lockColumn) {\n if (i < frozenColumns) {\n cols.splice(frozenCount, 0, cols.splice(i, 1)[0]);\n frozenCount++;\n }\n else {\n cols.splice(frozenColumns + movableCount, 0, cols.splice(i, 1)[0]);\n movableCount++;\n }\n }\n }\n };\n Grid.prototype.checkLockColumns = function (cols) {\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].columns) {\n this.checkLockColumns(cols[parseInt(i.toString(), 10)].columns);\n }\n else if (cols[parseInt(i.toString(), 10)].lockColumn) {\n this.lockcolPositionCount++;\n }\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Grid.prototype.leftrightColumnWidth = function (position) {\n var cols = position === 'left' ? this.getFrozenLeftColumns() : position === 'right' ? this.getFrozenRightColumns() : [];\n var width = 0;\n cols.filter(function (col) {\n if (col.visible) {\n width += parseInt(col.width.toString(), 10);\n }\n });\n return width;\n };\n /**\n * Gets the columns from the Grid.\n *\n * @param {boolean} isRefresh - Defines the boolean whether to refresh\n * @returns {Column[]} - returns the column\n */\n Grid.prototype.getColumns = function (isRefresh) {\n var _this_1 = this;\n var inview = this.inViewIndexes.map(function (v) { return v - _this_1.groupSettings.columns.length; }).filter(function (v) { return v > -1; });\n var vLen = inview.length;\n if (!this.enableColumnVirtualization || isNullOrUndefined(this.columnModel) || this.columnModel.length === 0 || isRefresh) {\n this.columnModel = [];\n this.updateColumnModel(this.columns);\n }\n var columns = vLen === 0 ? this.columnModel :\n this.columnModel.slice(inview[0], inview[vLen - 1] + 1);\n var left = [];\n var right = [];\n var movable = [];\n var isLeftRightFrozen = this.enableColumnVirtualization && this.isPreparedFrozenColumns && vLen === 0;\n if (isLeftRightFrozen) {\n this.frozenRightColumns = [];\n this.frozenLeftColumns = [];\n }\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].freeze === 'Left' || columns[parseInt(i.toString(), 10)].isFrozen) {\n left.push(columns[parseInt(i.toString(), 10)]);\n if (isLeftRightFrozen) {\n this.frozenLeftColumns.push(columns[parseInt(i.toString(), 10)]);\n }\n }\n else if (columns[parseInt(i.toString(), 10)].freeze === 'Right') {\n right.push(columns[parseInt(i.toString(), 10)]);\n if (isLeftRightFrozen) {\n this.frozenRightColumns.push(columns[parseInt(i.toString(), 10)]);\n }\n }\n else {\n movable.push(columns[parseInt(i.toString(), 10)]);\n }\n }\n if (this.enableColumnVirtualization && this.isFrozenGrid()) {\n if (this.frozenLeftColumns.length) {\n left = this.frozenLeftColumns;\n }\n if (this.frozenRightColumns.length) {\n right = this.frozenRightColumns;\n }\n }\n return left.concat(movable).concat(right);\n };\n /**\n * @private\n * @param {string} stackedHeader - Defines the stacked header\n * @param {Column[]} col - Defines the column\n * @returns {Column} Returns the Column\n */\n Grid.prototype.getStackedHeaderColumnByHeaderText = function (stackedHeader, col) {\n for (var i = 0; i < col.length; i++) {\n var individualColumn = col[parseInt(i.toString(), 10)];\n if (individualColumn.field === stackedHeader || individualColumn.headerText === stackedHeader) {\n this.stackedColumn = individualColumn;\n break;\n }\n else if (individualColumn.columns) {\n this.getStackedHeaderColumnByHeaderText(stackedHeader, individualColumn.columns);\n }\n }\n return this.stackedColumn;\n };\n /**\n * @private\n * @returns {number[]} Returns the column indexes\n */\n Grid.prototype.getColumnIndexesInView = function () {\n return this.inViewIndexes;\n };\n /**\n * @private\n * @returns {Query} - returns the query\n */\n Grid.prototype.getQuery = function () {\n return this.query;\n };\n /**\n * @private\n * @returns {object} - returns the locale constants\n */\n Grid.prototype.getLocaleConstants = function () {\n return this.defaultLocale;\n };\n /**\n * @param {number[]} indexes - specifies the indexes\n * @returns {void}\n * @private\n */\n Grid.prototype.setColumnIndexesInView = function (indexes) {\n this.inViewIndexes = indexes;\n };\n /**\n * Gets the visible columns from the Grid.\n *\n * @returns {Column[]} returns the column\n */\n Grid.prototype.getVisibleColumns = function () {\n return this.getCurrentVisibleColumns();\n };\n /**\n * Gets the header div of the Grid.\n *\n * @returns {Element} - Returns the element\n */\n Grid.prototype.getHeaderContent = function () {\n return this.headerModule.getPanel();\n };\n /**\n * Sets the header div of the Grid to replace the old header.\n *\n * @param {Element} element - Specifies the Grid header.\n *\n * @returns {void}\n */\n Grid.prototype.setGridHeaderContent = function (element) {\n this.headerModule.setPanel(element);\n };\n /**\n * Gets the content table of the Grid.\n *\n * @returns {Element} - Returns the element\n */\n Grid.prototype.getContentTable = function () {\n return this.contentModule.getTable();\n };\n /**\n * Sets the content table of the Grid to replace the old content table.\n *\n * @param {Element} element - Specifies the Grid content table.\n *\n * @returns {void}\n */\n Grid.prototype.setGridContentTable = function (element) {\n this.contentModule.setTable(element);\n };\n /**\n * Gets the content div of the Grid.\n *\n * @returns {Element} Returns the element\n */\n Grid.prototype.getContent = function () {\n return this.contentModule.getPanel();\n };\n /**\n * Sets the content div of the Grid to replace the old Grid content.\n *\n * @param {Element} element - Specifies the Grid content.\n *\n * @returns {void}\n */\n Grid.prototype.setGridContent = function (element) {\n this.contentModule.setPanel(element);\n };\n /**\n * Gets the header table element of the Grid.\n *\n * @returns {Element} returns the element\n */\n Grid.prototype.getHeaderTable = function () {\n return this.headerModule.getTable();\n };\n /**\n * Sets the header table of the Grid to replace the old one.\n *\n * @param {Element} element - Specifies the Grid header table.\n *\n * @returns {void}\n */\n Grid.prototype.setGridHeaderTable = function (element) {\n this.headerModule.setTable(element);\n };\n /**\n * Gets the footer div of the Grid.\n *\n * @returns {Element} returns the element\n */\n Grid.prototype.getFooterContent = function () {\n this.footerElement = this.element.getElementsByClassName(literals.gridFooter)[0];\n return this.footerElement;\n };\n /**\n * Gets the footer table element of the Grid.\n *\n * @returns {Element} returns the element\n */\n Grid.prototype.getFooterContentTable = function () {\n this.footerElement = this.element.getElementsByClassName(literals.gridFooter)[0];\n return this.footerElement.firstChild.firstChild;\n };\n /**\n * Gets the pager of the Grid.\n *\n * @returns {Element} returns the element\n */\n Grid.prototype.getPager = function () {\n return this.gridPager; //get element from pager\n };\n /**\n * Sets the pager of the Grid to replace the old pager.\n *\n * @param {Element} element - Specifies the Grid pager.\n *\n * @returns {void}\n */\n Grid.prototype.setGridPager = function (element) {\n this.gridPager = element;\n };\n /**\n * Gets a row by index.\n *\n * @param {number} index - Specifies the row index.\n *\n * @returns {Element} returns the element\n */\n Grid.prototype.getRowByIndex = function (index) {\n if (this.enableVirtualization && this.groupSettings.enableLazyLoading) {\n return this.lazyLoadRender.getRowByIndex(index);\n }\n else {\n return this.contentModule.getRowByIndex(index);\n }\n };\n /**\n * Gets a movable tables row by index.\n *\n * @param {number} index - Specifies the row index.\n *\n * @returns {Element} returns the element\n\n */\n Grid.prototype.getMovableRowByIndex = function (index) {\n return this.contentModule.getRowByIndex(index);\n };\n /**\n * Gets a frozen tables row by index.\n *\n * @param {number} index - Specifies the row index.\n * @returns {Element} returns the element\n\n */\n Grid.prototype.getFrozenRowByIndex = function (index) {\n return this.contentModule.getRowByIndex(index);\n };\n /**\n * Gets all the data rows of the Grid.\n *\n * @returns {Element[]} returns the element\n */\n Grid.prototype.getRows = function () {\n return this.contentModule.getRowElements();\n };\n /**\n * Gets a frozen right tables row element by index.\n *\n * @param {number} index - Specifies the row index.\n * @returns {Element} returns the element\n\n */\n Grid.prototype.getFrozenRightRowByIndex = function (index) {\n return this.contentModule.getRowByIndex(index);\n };\n /**\n * Get a row information based on cell\n *\n * @param {Element | EventTarget} target - specifies the element\n *\n * @returns {RowInfo} returns the row info\n */\n Grid.prototype.getRowInfo = function (target) {\n var ele = target;\n var args = { target: target };\n if (!isNullOrUndefined(target) && isNullOrUndefined(parentsUntil(ele, 'e-detailrowcollapse')\n && isNullOrUndefined(parentsUntil(ele, 'e-recordplusexpand')))) {\n var cell = closest(ele, '.' + literals.rowCell);\n if (!cell) {\n var row_1 = closest(ele, '.' + literals.row);\n if (!isNullOrUndefined(row_1) && !row_1.classList.contains('e-addedrow')) {\n var rowObj = this.getRowObjectFromUID(row_1.getAttribute('data-uid'));\n var rowIndex = parseInt(row_1.getAttribute(literals.dataRowIndex), 10);\n args = { row: row_1, rowData: rowObj.data, rowIndex: rowIndex };\n }\n return args;\n }\n var cellIndex = parseInt(cell.getAttribute(literals.dataColIndex), 10);\n var row_2 = closest(cell, '.' + literals.row);\n if (!isNullOrUndefined(cell) && !isNaN(cellIndex) && !isNullOrUndefined(row_2)) {\n var rowIndex = parseInt(row_2.getAttribute(literals.dataRowIndex), 10);\n var rows = this.contentModule.getRows();\n var index = cellIndex + this.getIndentCount();\n var rowsObject = rows.filter(function (r) { return r.uid === row_2.getAttribute('data-uid'); });\n var rowData = {};\n var column = void 0;\n if (Object.keys(rowsObject).length) {\n rowData = rowsObject[0].data;\n column = rowsObject[0].cells[parseInt(index.toString(), 10)].column;\n }\n args = { cell: cell, cellIndex: cellIndex, row: row_2, rowIndex: rowIndex, rowData: rowData, column: column, target: target };\n }\n }\n return args;\n };\n /**\n * Gets the Grid's movable content rows from frozen grid.\n *\n * @returns {Element[]} returns the element\n\n */\n Grid.prototype.getMovableRows = function () {\n return this.contentModule.getRowElements();\n };\n /**\n * Gets the Grid's frozen right content rows from frozen grid.\n *\n * @returns {Element[]} returns the element\n\n */\n Grid.prototype.getFrozenRightRows = function () {\n return this.contentModule.getRowElements();\n };\n /**\n * Gets all the Grid's data rows.\n *\n * @returns {Element[]} returns the element\n */\n Grid.prototype.getDataRows = function () {\n return this.getAllDataRows();\n };\n /**\n * @param {boolean} includeAdd - specifies includeAdd\n * @returns {Element[]} returns the element\n * @hidden\n */\n Grid.prototype.getAllDataRows = function (includeAdd) {\n if (isNullOrUndefined(this.getContentTable().querySelector(literals.tbody))) {\n return [];\n }\n var tbody = this.getContentTable().querySelector(literals.tbody);\n var rows = [].slice.call(tbody.children);\n if (this.frozenRows) {\n var hdrTbody = this.getHeaderTable().querySelector(literals.tbody);\n var freezeRows = [].slice.call(hdrTbody.children);\n rows = this.addMovableRows(freezeRows, rows);\n }\n var dataRows = this.generateDataRows(rows, includeAdd);\n return dataRows;\n };\n /**\n * @param {HTMLElement[]} fRows - Defines the frozen Rows\n * @param {HTMLElement[]} mrows - Defines the movable Rows\n * @returns {HTMLElement[]} Returns the element\n * @hidden\n */\n Grid.prototype.addMovableRows = function (fRows, mrows) {\n for (var i = 0, len = mrows.length; i < len; i++) {\n fRows.push(mrows[parseInt(i.toString(), 10)]);\n }\n return fRows;\n };\n Grid.prototype.generateDataRows = function (rows, includAdd) {\n var dRows = [];\n for (var i = 0, len = rows.length; i < len; i++) {\n if (rows[parseInt(i.toString(), 10)].classList.contains(literals.row)\n && (!rows[parseInt(i.toString(), 10)].classList.contains('e-hiddenrow') || includAdd)) {\n if (this.isCollapseStateEnabled()) {\n dRows[parseInt(rows[parseInt(i.toString(), 10)].getAttribute('data-rowindex'), 10)] = rows[parseInt(i.toString(), 10)];\n }\n else {\n dRows.push(rows[parseInt(i.toString(), 10)]);\n }\n }\n }\n return dRows;\n };\n /**\n * Gets all the Grid's movable table data rows.\n *\n * @returns {Element[]} Returns the element\n\n */\n Grid.prototype.getMovableDataRows = function () {\n return this.getAllMovableDataRows();\n };\n /**\n * @param {boolean} includeAdd Defines the include add in boolean\n * @returns {Element[]} Returns the element\n\n * @hidden\n */\n Grid.prototype.getAllMovableDataRows = function (includeAdd) {\n return this.getAllDataRows(includeAdd);\n };\n /**\n * Gets all the Grid's frozen table data rows.\n *\n * @returns {Element[]} returns the element\n\n */\n Grid.prototype.getFrozenDataRows = function () {\n return this.getAllFrozenDataRows();\n };\n /**\n * @param {boolean} includeAdd Defines the include add in boolean\n * @returns {Element[]} Returns the element\n\n * @hidden\n */\n Grid.prototype.getAllFrozenDataRows = function (includeAdd) {\n return this.getAllDataRows(includeAdd);\n };\n /**\n * Gets all the Grid's frozen right table data rows.\n *\n * @returns {Element[]} Returns the Element\n\n */\n Grid.prototype.getFrozenRightDataRows = function () {\n return this.getAllFrozenRightDataRows();\n };\n /**\n * @param {boolean} includeAdd Defines the include add in boolean\n * @returns {Element[]} Returns the element\n\n * @hidden\n */\n Grid.prototype.getAllFrozenRightDataRows = function (includeAdd) {\n return this.getAllDataRows(includeAdd);\n };\n /**\n * Updates particular cell value based on the given primary key value.\n * > Primary key column must be specified using `columns.isPrimaryKey` property.\n *\n * @param {string| number} key - Specifies the PrimaryKey value of dataSource.\n * @param {string } field - Specifies the field name which you want to update.\n * @param {string | number | boolean | Date} value - To update new value for the particular cell.\n *\n * @returns {void}\n */\n Grid.prototype.setCellValue = function (key, field, value) {\n var cells = 'cells';\n var rowData = 'data';\n var rowIdx = 'index';\n var rowuID = 'uid';\n var pkName = this.getPrimaryKeyFieldNames()[0];\n var cell = new CellRenderer(this, this.serviceLocator);\n var fieldIdx = this.getColumnIndexByField(field);\n var col = this.getColumnByField(field);\n var rowObjects = this.contentModule.getRows();\n var selectedRow = rowObjects.filter(function (r) {\n return getValue(pkName, r.data) === key;\n })[0];\n var tr = selectedRow ? this.element.querySelector('[data-uid=' + selectedRow[\"\" + rowuID] + ']') : null;\n if (!isNullOrUndefined(tr)) {\n if (typeof value === 'string') {\n value = this.sanitize(value);\n }\n setValue(field, value, selectedRow[\"\" + rowData]);\n var left = 0;\n if (this.isRowDragable()) {\n left++;\n }\n var td = this.enableVirtualization ? tr.children[parseInt(fieldIdx.toString(), 10)]\n : this.getCellFromIndex(selectedRow[\"\" + rowIdx], fieldIdx);\n if (!isNullOrUndefined(td)) {\n var Idx = 0;\n if (this.groupSettings.columns.length) {\n fieldIdx = fieldIdx + this.groupSettings.columns.length;\n }\n if (this.childGrid || this.detailTemplate) {\n fieldIdx++;\n }\n if (this.isRowDragable()) {\n fieldIdx++;\n }\n var sRow = selectedRow[\"\" + cells][fieldIdx - Idx];\n cell.refreshTD(td, sRow, selectedRow[\"\" + rowData], { index: selectedRow[\"\" + rowIdx] });\n if (this.isReact) {\n td = this.enableVirtualization ? tr.children[parseInt(fieldIdx.toString(), 10)]\n : this.getCellFromIndex(selectedRow[\"\" + rowIdx], fieldIdx);\n }\n if (this.aggregates.length > 0) {\n this.notify(events.refreshFooterRenderer, {});\n if (this.groupSettings.columns.length > 0) {\n this.notify(events.groupAggregates, {});\n }\n }\n /* tslint:disable:no-string-literal */\n if (!isNullOrUndefined(selectedRow) && !isNullOrUndefined(selectedRow['changes'])) {\n selectedRow['changes'][\"\" + field] = value;\n }\n /* tslint:disable:no-string-literal */\n this.trigger(events.queryCellInfo, {\n cell: td, column: col, data: selectedRow[\"\" + rowData]\n });\n if (this.isReact && td.getAttribute('tabindex') === '0' && td.classList.contains('e-focused')) {\n td.focus();\n }\n }\n }\n else {\n return;\n }\n };\n /**\n * @param {string} columnUid - Defines column uid\n * @param {boolean} renderTemplates - Defines renderTemplates need to invoke\n * @returns {void}\n * @hidden\n */\n Grid.prototype.refreshReactColumnTemplateByUid = function (columnUid, renderTemplates) {\n var _this_1 = this;\n if (this.isReact) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.clearTemplate(['columnTemplate'], undefined, function () {\n var isChildGrid = _this_1.childGrid && _this_1.element.querySelectorAll('.e-childgrid').length ? true : false;\n var rows = isChildGrid ? _this_1.getContentTable().querySelectorAll('.e-row') :\n _this_1.getDataRows();\n _this_1.refreshReactTemplateTD(rows, isChildGrid);\n if (renderTemplates) {\n _this_1.renderTemplates();\n }\n });\n }\n };\n /**\n * @param {Element[] | NodeListOf<Element>} rows - Defines the rows\n * @param {boolean} isChildGrid - Defines whether it is a Hierarchy Grid.\n * @param {boolean} isFrozen - Defines whether it is a Frozen Grid\n * @returns {void}\n * @hidden\n */\n Grid.prototype.refreshReactTemplateTD = function (rows, isChildGrid, isFrozen) {\n var cells = 'cells';\n var rowIdx = 'index';\n var indent = this.getIndentCount();\n var childIndent = 0;\n var isChildRow = false;\n for (var j = 0; j < rows.length; j++) {\n var rowsObj = this.getRowObjectFromUID(rows[parseInt(j.toString(), 10)].getAttribute('data-uid'));\n if (isChildGrid && !rowsObj && parentsUntil(rows[parseInt(j.toString(), 10)], 'e-childgrid')) {\n var gridObj = parentsUntil(rows[parseInt(j.toString(), 10)], 'e-childgrid').ej2_instances[0];\n rowsObj = gridObj.getRowObjectFromUID(rows[parseInt(j.toString(), 10)].getAttribute('data-uid'));\n childIndent = gridObj.getIndentCount();\n isChildRow = true;\n }\n if (rowsObj && rowsObj.isDataRow && !isNullOrUndefined(rowsObj.index) &&\n !rows[parseInt(j.toString(), 10)].classList.contains('e-editedrow')) {\n for (var i = 0; i < rowsObj[\"\" + cells].length; i++) {\n var cell = rowsObj[\"\" + cells][parseInt(i.toString(), 10)];\n if (cell.isTemplate) {\n var cellRenderer = new CellRenderer(this, this.serviceLocator);\n var td = isChildGrid ? rows[parseInt(j.toString(), 10)]\n .children[cell.index + (isChildRow ? childIndent : indent)] : this.getCellFromIndex(j, isFrozen ? cell.index : i - indent);\n cellRenderer.refreshTD(td, cell, rowsObj.data, { index: rowsObj[\"\" + rowIdx] });\n }\n }\n }\n isChildRow = false;\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Grid.prototype.refreshGroupCaptionFooterTemplate = function () {\n var isChildGrid = this.childGrid && this.element.querySelectorAll('.e-childgrid').length ? true : false;\n var rows = this.getContentTable().querySelectorAll('.e-groupcaptionrow, .e-groupfooterrow');\n for (var i = 0; i < rows.length; i++) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var gridObj = this;\n var rowsObj = this.getRowObjectFromUID(rows[parseInt(i.toString(), 10)].getAttribute('data-uid'));\n if (isChildGrid && !rowsObj && parentsUntil(rows[parseInt(i.toString(), 10)], 'e-childgrid')) {\n gridObj = parentsUntil(rows[parseInt(i.toString(), 10)], 'e-childgrid').ej2_instances[0];\n rowsObj = gridObj.getRowObjectFromUID(rows[parseInt(i.toString(), 10)].getAttribute('data-uid'));\n }\n if (rowsObj) {\n var cells = rowsObj.cells.filter(function (cell) { return cell.isDataCell; });\n var args = { cells: cells, data: rowsObj.data, dataUid: rowsObj.uid };\n gridObj.notify(events.refreshAggregateCell, args);\n }\n }\n };\n /**\n * @param {string} columnUid - Defines column uid\n * @returns {void}\n * @hidden\n */\n Grid.prototype.refreshReactHeaderTemplateByUid = function (columnUid) {\n if (this.isReact) {\n var cells = 'cells';\n var rowsObj = this.headerModule.rows;\n var cellIndex = this.getNormalizedColumnIndex(columnUid);\n var _loop_1 = function (j) {\n var cell = rowsObj[parseInt(j.toString(), 10)][\"\" + cells][parseInt(cellIndex.toString(), 10)];\n if (cell && cell.column.uid === columnUid) {\n var headerCellRenderer = new HeaderCellRenderer(this_1, this_1.serviceLocator);\n var td = parentsUntil(this_1.element.querySelectorAll('[e-mappinguid=' + columnUid + ']')[0], 'e-templatecell');\n headerCellRenderer.refresh(cell, td);\n var cols = this_1.sortSettings.columns;\n var columnIndex = cols.findIndex(function (col) { return col.field === cell.column.field; });\n if (columnIndex !== -1) {\n var header = this_1.getColumnHeaderByField(cell.column.field);\n this_1.ariaService.setSort(header, (cols[parseInt(columnIndex.toString(), 10)].direction).toLowerCase());\n if (cols.length > 1) {\n header.querySelector('.e-headercelldiv').insertBefore(this_1.createElement('span', { className: 'e-sortnumber', innerHTML: (columnIndex + 1).toString() }), header.querySelector('.e-headertext'));\n }\n var filterElement = header.querySelector('.e-sortfilterdiv');\n if (cols[parseInt(columnIndex.toString(), 10)].direction === 'Ascending') {\n classList(filterElement, ['e-ascending', 'e-icon-ascending'], []);\n }\n else {\n classList(filterElement, ['e-descending', 'e-icon-descending'], []);\n }\n }\n }\n };\n var this_1 = this;\n for (var j = 0; j < rowsObj.length; j++) {\n _loop_1(j);\n }\n }\n };\n /**\n * Updates and refresh the particular row values based on the given primary key value.\n * > Primary key column must be specified using `columns.isPrimaryKey` property.\n *\n * @param {string| number} key - Specifies the PrimaryKey value of dataSource.\n * @param {Object} rowData - To update new data for the particular row.\n *\n * @returns {void}\n */\n Grid.prototype.setRowData = function (key, rowData) {\n var rowuID = 'uid';\n var rowObjects = this.contentModule.getRows();\n var pkName = this.getPrimaryKeyFieldNames()[0];\n if (this.groupSettings.columns.length > 0 && this.aggregates.length > 0) {\n rowObjects = rowObjects.filter(function (row) { return row.isDataRow; });\n }\n var selectedRow = rowObjects.filter(function (r) {\n return getValue(pkName, r.data) === key;\n })[0];\n var selectRowEle = selectedRow ? [].slice.call(this.element.querySelectorAll('[data-uid=' + selectedRow[\"\" + rowuID] + ']')) : undefined;\n if (!isNullOrUndefined(selectedRow) && selectRowEle.length) {\n selectedRow.changes = rowData;\n if (this.frozenRows) {\n var fRowTr = this.getRowsObject()[selectedRow.index];\n this.setFrozenRowData(fRowTr, rowData);\n }\n else {\n this.setFrozenRowData(selectedRow, rowData);\n }\n if (this.aggregates.length > 0) {\n this.notify(events.refreshFooterRenderer, {});\n if (this.groupSettings.columns.length > 0) {\n this.notify(events.groupAggregates, {});\n }\n }\n }\n else {\n return;\n }\n };\n Grid.prototype.setFrozenRowData = function (fTr, rowData) {\n var rowRenderer = new RowRenderer(this.serviceLocator, null, this);\n fTr.changes = rowData;\n refreshForeignData(fTr, this.getForeignKeyColumns(), fTr.changes);\n rowRenderer.refresh(fTr, this.getColumns(), true);\n };\n /**\n * Gets a cell by row and column index.\n *\n * @param {number} rowIndex - Specifies the row index.\n * @param {number} columnIndex - Specifies the column index.\n *\n * @returns {Element} Returns the Element\n */\n Grid.prototype.getCellFromIndex = function (rowIndex, columnIndex) {\n var col = this.getColumnByIndex(columnIndex);\n return getCellByColAndRowIndex(this, col, rowIndex, columnIndex);\n };\n /**\n * Gets a movable table cell by row and column index.\n *\n * @param {number} rowIndex - Specifies the row index.\n * @param {number} columnIndex - Specifies the column index.\n *\n * @returns {Element} Returns the Element\n\n */\n Grid.prototype.getMovableCellFromIndex = function (rowIndex, columnIndex) {\n return this.getCellFromIndex(rowIndex, columnIndex);\n };\n /**\n * Gets a frozen right table cell by row and column index.\n *\n * @param {number} rowIndex - Specifies the row index.\n * @param {number} columnIndex - Specifies the column index.\n * @returns {Element} Returns the Element\n\n */\n Grid.prototype.getFrozenRightCellFromIndex = function (rowIndex, columnIndex) {\n return this.getCellFromIndex(rowIndex, columnIndex);\n };\n /**\n * Gets a column header by column index.\n *\n * @param {number} index - Specifies the column index.\n *\n * @returns {Element} Returns the Element\n */\n Grid.prototype.getColumnHeaderByIndex = function (index) {\n return this.getHeaderTable().getElementsByClassName('e-headercell')[parseInt(index.toString(), 10)];\n };\n /**\n * Gets a movable column header by column index.\n *\n * @param {number} index - Specifies the column index.\n * @returns {Element} Returns the Element\n\n */\n Grid.prototype.getMovableColumnHeaderByIndex = function (index) {\n return this.getColumnHeaderByIndex(index);\n };\n /**\n * Gets a frozen right column header by column index.\n *\n * @param {number} index - Specifies the column index.\n * @returns {Element} Returns the Element\n\n */\n Grid.prototype.getFrozenRightColumnHeaderByIndex = function (index) {\n return this.getColumnHeaderByIndex(index);\n };\n /**\n * Gets a frozen left column header by column index.\n *\n * @param {number} index - Specifies the column index.\n * @returns {Element} Returns the Element\n\n */\n Grid.prototype.getFrozenLeftColumnHeaderByIndex = function (index) {\n return this.getColumnHeaderByIndex(index);\n };\n /**\n * @param {string} uid - Defines the uid\n * @param {boolean} isMovable - Defines isMovable\n * @param {boolean} isFrozenRight - Defines isFrozenRight\n * @returns {Row<Column>} Returns the row object\n * @hidden\n */\n Grid.prototype.getRowObjectFromUID = function (uid) {\n var rows = this.contentModule.getRows();\n var row = this.rowObject(rows, uid);\n if (isNullOrUndefined(row) && this.enableVirtualization && this.groupSettings.columns.length > 0) {\n row = this.rowObject(this.vRows, uid);\n return row;\n }\n return row;\n };\n Grid.prototype.rowObject = function (rows, uid) {\n if (rows) {\n for (var _i = 0, rows_1 = rows; _i < rows_1.length; _i++) {\n var row = rows_1[_i];\n if (row.uid === uid) {\n return row;\n }\n }\n }\n return null;\n };\n /**\n * @hidden\n * @returns {Row<Column>[]} Returns the Row object\n */\n Grid.prototype.getRowsObject = function () {\n return this.contentModule.getRows();\n };\n /**\n * @hidden\n * @returns {Row<Column>[]} Returns the Row object\n\n */\n Grid.prototype.getMovableRowsObject = function () {\n return this.contentModule.getRows();\n };\n /**\n * @hidden\n * @returns {Row<Column>[]} Returns the Row object\n\n */\n Grid.prototype.getFrozenRightRowsObject = function () {\n return this.contentModule.getRows();\n };\n /**\n * Gets a column header by column name.\n *\n * @param {string} field - Specifies the column name.\n *\n * @returns {Element} - Returns the element\n */\n Grid.prototype.getColumnHeaderByField = function (field) {\n var column = this.getColumnByField(field);\n return column ? this.getColumnHeaderByUid(column.uid) : undefined;\n };\n /**\n * Gets a column header by UID.\n *\n * @param {string} uid - Specifies the column uid.\n *\n * @returns {Element} - Returns the element\n */\n Grid.prototype.getColumnHeaderByUid = function (uid) {\n var element = this.getHeaderContent().querySelector('[e-mappinguid=' + uid + ']');\n return element ? element.parentElement : undefined;\n };\n /**\n * @hidden\n * @param {number} index - Defines the index\n * @returns {Column} Returns the column\n */\n Grid.prototype.getColumnByIndex = function (index) {\n var column;\n this.getColumns().some(function (col, i) {\n column = col;\n return i === index;\n });\n return column;\n };\n /**\n * Gets a Column by column name.\n *\n * @param {string} field - Specifies the column name.\n *\n * @returns {Column} Returns the column\n */\n Grid.prototype.getColumnByField = function (field) {\n return iterateArrayOrObject(this.getColumns(), function (item) {\n if (item.field === field) {\n return item;\n }\n return undefined;\n })[0];\n };\n /**\n * Gets a column index by column name.\n *\n * @param {string} field - Specifies the column name.\n *\n * @returns {number} Returns the index by field\n */\n Grid.prototype.getColumnIndexByField = function (field) {\n var cols = this.getColumns();\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].field === field) {\n return i;\n }\n }\n return -1;\n };\n /**\n * Gets a column by UID.\n *\n * @param {string} uid - Specifies the column UID.\n *\n * @returns {Column} Returns the column\n */\n Grid.prototype.getColumnByUid = function (uid) {\n return iterateArrayOrObject(this.getColumns().concat(this.getStackedColumns(this.columns)), function (item) {\n if (item.uid === uid) {\n return item;\n }\n return undefined;\n })[0];\n };\n /**\n * @param {Column[]} columns - Defines the columns\n * @param {Column[]} stackedColumn - Defines the stacked columns\n * @returns {Column[]} Returns the columns\n * @hidden\n */\n Grid.prototype.getStackedColumns = function (columns, stackedColumn) {\n if (stackedColumn === void 0) { stackedColumn = []; }\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var column = columns_1[_i];\n if (column.columns) {\n stackedColumn.push(column);\n this.getStackedColumns(column.columns, stackedColumn);\n }\n }\n return stackedColumn;\n };\n /**\n * Gets a column index by UID.\n *\n * @param {string} uid - Specifies the column UID.\n *\n * @returns {number} Returns the column by index\n */\n Grid.prototype.getColumnIndexByUid = function (uid) {\n var index = iterateArrayOrObject(this.getColumns(), function (item, index) {\n if (item.uid === uid) {\n return index;\n }\n return undefined;\n })[0];\n return !isNullOrUndefined(index) ? index : -1;\n };\n /**\n * Gets UID by column name.\n *\n * @param {string} field - Specifies the column name.\n *\n * @returns {string} Returns the column by field\n */\n Grid.prototype.getUidByColumnField = function (field) {\n return iterateArrayOrObject(this.getColumns(), function (item) {\n if (item.field === field) {\n return item.uid;\n }\n return undefined;\n })[0];\n };\n /**\n * Gets column index by column uid value.\n *\n * @private\n * @param {string} uid - Specifies the column uid.\n * @returns {number} Returns the column by field\n */\n Grid.prototype.getNormalizedColumnIndex = function (uid) {\n var index = this.getColumnIndexByUid(uid);\n return index + this.getIndentCount();\n };\n /**\n * Gets indent cell count.\n *\n * @private\n * @returns {number} Returns the indent count\n */\n Grid.prototype.getIndentCount = function () {\n var index = 0;\n if (this.allowGrouping) {\n index += this.groupSettings.columns.length;\n }\n if (this.isDetail()) {\n index++;\n }\n if (this.isRowDragable() && isNullOrUndefined(this.rowDropSettings.targetID)) {\n index++;\n }\n /**\n * TODO: index normalization based on the stacked header, grouping and detailTemplate\n * and frozen should be handled here\n */\n return index;\n };\n /**\n * Gets the collection of column fields.\n *\n * @returns {string[]} Returns the Field names\n */\n Grid.prototype.getColumnFieldNames = function () {\n var columnNames = [];\n var column;\n for (var i = 0, len = this.getColumns().length; i < len; i++) {\n column = this.getColumns()[parseInt(i.toString(), 10)];\n if (column.visible) {\n columnNames.push(column.field);\n }\n }\n return columnNames;\n };\n /**\n * Gets a compiled row template.\n *\n * @returns {Function} Returns the row TEmplate\n * @private\n */\n Grid.prototype.getRowTemplate = function () {\n return this.rowTemplateFn;\n };\n /**\n * Gets a compiled empty Record template.\n *\n * @returns {Function} Returns the empty Record template\n * @private\n */\n Grid.prototype.getEmptyRecordTemplate = function () {\n return this.emptyRecordTemplateFn;\n };\n /**\n * Gets a compiled detail row template.\n *\n * @private\n * @returns {Function} Returns the Detail template\n */\n Grid.prototype.getDetailTemplate = function () {\n return this.detailTemplateFn;\n };\n /**\n * Gets a compiled detail row template.\n *\n * @private\n * @returns {Function}Returns the Edit template\n */\n Grid.prototype.getEditTemplate = function () {\n return this.editTemplateFn;\n };\n /**\n * Gets a compiled dialog edit header template.\n *\n * @private\n * @returns {Function} returns template function\n */\n Grid.prototype.getEditHeaderTemplate = function () {\n return this.editHeaderTemplateFn;\n };\n /**\n * Gets a compiled dialog edit footer template.\n *\n * @private\n * @returns {Function} Returns the Footer template\n */\n Grid.prototype.getEditFooterTemplate = function () {\n return this.editFooterTemplateFn;\n };\n /**\n * Get the names of the primary key columns of the Grid.\n *\n * @returns {string[]} Returns the field names\n */\n Grid.prototype.getPrimaryKeyFieldNames = function () {\n var keys = [];\n for (var k = 0; k < this.columnModel.length; k++) {\n if (this.columnModel[parseInt(k.toString(), 10)].isPrimaryKey) {\n keys.push(this.columnModel[parseInt(k.toString(), 10)].field);\n }\n }\n return keys;\n };\n /**\n * Refreshes the Grid header and content.\n *\n * @returns {void}\n */\n Grid.prototype.refresh = function () {\n if (!this.isDestroyed) {\n this.isManualRefresh = true;\n this.headerModule.refreshUI();\n this.updateStackedFilter();\n this.renderModule.refresh();\n }\n };\n /**\n * Refreshes the Grid header.\n *\n * @returns {void}\n */\n Grid.prototype.refreshHeader = function () {\n this.headerModule.refreshUI();\n };\n /**\n * Gets the collection of selected rows.\n *\n * @returns {Element[]} Returns the element\n */\n Grid.prototype.getSelectedRows = function () {\n return this.selectionModule ? this.selectionModule.selectedRecords : [];\n };\n /**\n * Gets the collection of selected row indexes.\n *\n * @returns {number[]} Returns the Selected row indexes\n */\n Grid.prototype.getSelectedRowIndexes = function () {\n return this.selectionModule ? this.selectionModule.selectedRowIndexes : [];\n };\n /**\n * Gets the collection of selected row and cell indexes.\n *\n * @returns {number[]} Returns the Selected row cell indexes\n */\n Grid.prototype.getSelectedRowCellIndexes = function () {\n return this.selectionModule ? this.selectionModule.selectedRowCellIndexes : [];\n };\n /**\n * Gets the collection of selected records.\n *\n * @returns {Object[]} Returns the selected records\n * @isGenericType true\n */\n Grid.prototype.getSelectedRecords = function () {\n return this.selectionModule ? this.selectionModule.getSelectedRecords() : [];\n };\n /**\n * Gets the collection of selected columns uid.\n *\n * @returns {string[]} Returns the selected column uid\n * @isGenericType true\n */\n Grid.prototype.getSelectedColumnsUid = function () {\n var _this_1 = this;\n var uid = [];\n if (this.selectionModule) {\n this.selectionModule.selectedColumnsIndexes.filter(function (i) { return uid.push(_this_1.getColumns()[parseInt(i.toString(), 10)].uid); });\n }\n return uid;\n };\n /**\n * Gets the data module.\n *\n * @returns {Data} Returns the data\n */\n Grid.prototype.getDataModule = function () {\n return this.renderModule.data;\n };\n /**\n * Shows a column by its column name.\n *\n * @param {string|string[]} keys - Defines a single or collection of column names.\n * @param {string} showBy - Defines the column key either as field name or header text.\n *\n * @returns {void}\n */\n Grid.prototype.showColumns = function (keys, showBy) {\n showBy = showBy ? showBy : 'headerText';\n this.showHider.show(keys, showBy);\n };\n /**\n * Hides a column by column name.\n *\n * @param {string|string[]} keys - Defines a single or collection of column names.\n * @param {string} hideBy - Defines the column key either as field name or header text.\n *\n * @returns {void}\n */\n Grid.prototype.hideColumns = function (keys, hideBy) {\n hideBy = hideBy ? hideBy : 'headerText';\n this.showHider.hide(keys, hideBy);\n };\n /**\n * @hidden\n * @returns {number} Returns the Frozen column\n */\n Grid.prototype.getFrozenColumns = function () {\n return this.frozenColumns + this.getFrozenCount(this.columns, 0, 0);\n };\n /**\n * @hidden\n * @returns {number} Returns the Frozen Right column count\n */\n Grid.prototype.getFrozenRightColumnsCount = function () {\n return this.frozenRightCount || this.rightcount;\n };\n /**\n * @hidden\n * @returns {number} Returns the Frozen Left column\n */\n Grid.prototype.getFrozenLeftColumnsCount = function () {\n return this.frozenLeftCount || this.leftcount;\n };\n /**\n * @hidden\n * @returns {number} Returns the movable column count\n */\n Grid.prototype.getMovableColumnsCount = function () {\n return this.movableCount || this.movablecount;\n };\n Grid.prototype.updateFrozenColumnsWidth = function () {\n if (this.isFrozenGrid() && !this.enableColumnVirtualization) {\n var gcol = this.getColumns();\n var isAutoWidth = true;\n var autoCol_1 = 0;\n var difference_1 = 0;\n var autoWidth_1 = 0;\n var _loop_2 = function (i) {\n var col = gcol[parseInt(i.toString(), 10)];\n if (isNullOrUndefined(col.width) && (col.freeze === 'Left' || col.freeze === 'Right' || col.freeze === 'Fixed' || col.isFrozen)) {\n col.width = Math.max(200, col.minWidth ? parseFloat(col.minWidth.toString()) : 0);\n }\n if (col.width === 'auto' && (col.freeze === 'Left' || col.freeze === 'Right' || col.freeze === 'Fixed' || col.isFrozen)) {\n var tWidth_1 = 0;\n if (isAutoWidth) {\n gcol.filter(function (cols) {\n if (cols.visible) {\n if (cols.width === 'auto') {\n autoCol_1++;\n }\n if (cols.width !== 'auto') {\n var width = !isNullOrUndefined(cols.width) ? parseFloat(cols.width.toString()) :\n Math.max(200, cols.minWidth ? parseFloat(cols.minWidth.toString()) : 0);\n tWidth_1 += width;\n }\n }\n });\n var gWidth = this_2.isPercentageWidthGrid() || this_2.width === 'auto' ? this_2.element.getBoundingClientRect().width :\n parseFloat(this_2.width.toString());\n difference_1 = this_2.height === 'auto' ? gWidth - tWidth_1 : ((gWidth - tWidth_1) - getScrollBarWidth());\n if (difference_1 < 0) {\n difference_1 = 0;\n }\n autoWidth_1 = parseFloat((difference_1 / autoCol_1).toString());\n gcol.filter(function (col) {\n if (col.visible) {\n if (col.minWidth && parseFloat(col.minWidth.toString()) > autoWidth_1) {\n difference_1 = difference_1 - parseFloat(col.minWidth.toString());\n autoCol_1--;\n }\n }\n });\n isAutoWidth = false;\n }\n if (col.minWidth && parseFloat(col.minWidth.toString()) > autoWidth_1) {\n col.width = parseFloat(col.minWidth.toString());\n }\n else {\n col.width = difference_1 / autoCol_1;\n }\n }\n };\n var this_2 = this;\n for (var i = 0; i < gcol.length; i++) {\n _loop_2(i);\n }\n }\n };\n Grid.prototype.refreshSplitFrozenColumn = function () {\n this.splitFrozenCount(this.columns);\n this.updateFrozenColumnsWidth();\n this.isAutoGenerateColumns = true;\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.setFrozenCount = function () {\n this.frozenLeftCount = this.frozenRightCount = this.movableCount = 0;\n this.visibleFrozenLeft = this.visibleFrozenRight = this.visibleMovable = 0;\n this.frozenLeftColumns = [];\n this.frozenRightColumns = [];\n this.movableColumns = [];\n this.fixedColumns = [];\n this.splitFrozenCount(this.columns);\n this.leftcount = this.frozenLeftCount;\n this.rightcount = this.frozenRightCount;\n this.movablecount = this.movableCount;\n // if (this.frozenColumns && (this.frozenLeftCount || this.frozenRightCount)) {\n // this.setProperties({ frozenColumns: 0 }, true);\n // }\n if (this.frozenLeftCount && !this.frozenRightCount) {\n this.frozenName = 'Left';\n }\n else if (this.frozenRightCount && !this.frozenLeftCount) {\n this.frozenName = 'Right';\n }\n else if (this.frozenLeftCount && this.frozenRightCount) {\n this.frozenName = 'Left-Right';\n }\n else if (this.frozenColumns || this.frozenRows) {\n this.frozenName = 'Left';\n }\n else {\n this.frozenName = undefined;\n }\n };\n /**\n * @hidden\n * @returns {number} Returns the visible Frozen left count\n */\n Grid.prototype.getVisibleFrozenLeftCount = function () {\n return this.visibleFrozenLeft;\n };\n /**\n * @hidden\n * @returns {number} Returns the visible Frozen Right count\n */\n Grid.prototype.getVisibleFrozenRightCount = function () {\n return this.visibleFrozenRight;\n };\n /**\n * @hidden\n * @returns {number} Returns the visible movable count\n */\n Grid.prototype.getVisibleMovableCount = function () {\n return this.visibleMovable;\n };\n /**\n * @hidden\n * @returns {Column[]} Returns the column\n */\n Grid.prototype.getFrozenRightColumns = function () {\n return this.frozenRightColumns;\n };\n /**\n * @hidden\n * @returns {Column[]} Returns the column\n */\n Grid.prototype.getFrozenLeftColumns = function () {\n return this.frozenLeftColumns;\n };\n /**\n * @hidden\n * @returns {Column[]} Returns the column\n */\n Grid.prototype.getMovableColumns = function () {\n return this.movableColumns;\n };\n Grid.prototype.splitStackedColumns = function (columns) {\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].columns) {\n this.splitStackedColumns(columns[parseInt(i.toString(), 10)].columns);\n }\n else {\n if (columns[parseInt(i.toString(), 10)].freeze === 'Left' || columns[parseInt(i.toString(), 10)].isFrozen) {\n if (columns[parseInt(i.toString(), 10)].visible !== false) {\n this.visibleFrozenLeft++;\n }\n this.leftcount++;\n }\n else if (columns[parseInt(i.toString(), 10)].freeze === 'Right') {\n if (columns[parseInt(i.toString(), 10)].visible !== false) {\n this.visibleFrozenRight++;\n }\n this.rightcount++;\n }\n else if (columns[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n if (columns[parseInt(i.toString(), 10)].visible !== false) {\n this.visibleFrozenFixed++;\n }\n this.fixedcount++;\n }\n else {\n if (columns[parseInt(i.toString(), 10)].visible !== false) {\n this.visibleMovable++;\n }\n this.movablecount++;\n }\n }\n }\n };\n Grid.prototype.pushStackedColumns = function (columns, index, arr, col, stackedcol) {\n arr[parseInt(index.toString(), 10)] = col.headerText;\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].columns) {\n index = index + 1;\n this.pushStackedColumns(columns[parseInt(i.toString(), 10)].columns, index, arr, columns[parseInt(i.toString(), 10)], stackedcol);\n index = index - 1;\n }\n else {\n var stockCol = [];\n stockCol = arr.slice().slice(0, index + 1);\n if (columns[parseInt(i.toString(), 10)].freeze === 'Left' || columns[parseInt(i.toString(), 10)].isFrozen) {\n this.stackedLeft.push(stockCol);\n this.stackedarrayLeft.push(columns[parseInt(i.toString(), 10)]);\n }\n else if (columns[parseInt(i.toString(), 10)].freeze === 'Right') {\n this.stackedRight.push(stockCol);\n this.stackedarrayRight.push(columns[parseInt(i.toString(), 10)]);\n }\n else if (columns[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n this.stackedFixed.push(stockCol);\n this.stackedarrayFixed.push(columns[parseInt(i.toString(), 10)]);\n }\n else {\n this.stackedMovable.push(stockCol);\n this.stackedarrayMovable.push(columns[parseInt(i.toString(), 10)]);\n }\n }\n }\n };\n Grid.prototype.pushallcol = function (text, text1, col, columns, isTrue) {\n if (col.headerText === text1) {\n if (isTrue) {\n col.columns.push(columns);\n }\n else {\n col.columns.push({ headerText: text, columns: [] });\n }\n }\n else {\n if (col.columns && col.columns.length) {\n for (var i = 0; i < col.columns.length; i++) {\n this.pushallcol(text, text1, col.columns[parseInt(i.toString(), 10)], columns, isTrue);\n }\n }\n }\n };\n Grid.prototype.resetStackedColumns = function (headercol, gridcolumns, freeze) {\n var col = {};\n var tempHead = [];\n for (var i = 1; i <= headercol.length; i++) {\n var firstcol = headercol[i - 1];\n for (var j = 0; j < firstcol.length; j++) {\n if (!col.columns && i === 1) {\n col = { headerText: firstcol[parseInt(j.toString(), 10)], columns: [] };\n tempHead.push(firstcol[parseInt(j.toString(), 10)]);\n }\n else {\n if (tempHead.indexOf(firstcol[parseInt(j.toString(), 10)]) === -1) {\n this.pushallcol(firstcol[parseInt(j.toString(), 10)], firstcol[j - 1], col);\n tempHead.push(firstcol[parseInt(j.toString(), 10)]);\n }\n }\n if (j === firstcol.length - 1) {\n this.pushallcol(null, firstcol[parseInt(j.toString(), 10)], col, gridcolumns[i - 1], true);\n var count = 0;\n while (count !== headercol.length - 1 && i !== headercol.length) {\n if (firstcol.toString() === headercol[parseInt(i.toString(), 10)].toString()) {\n i++;\n this.pushallcol(null, firstcol[parseInt(j.toString(), 10)], col, gridcolumns[i - 1], true);\n }\n count++;\n }\n }\n }\n }\n if (freeze === 'Left') {\n this.frozenLeftColumns.push(col);\n }\n else if (freeze === 'Right') {\n this.frozenRightColumns.push(col);\n }\n else {\n this.movableColumns.push(col);\n }\n };\n Grid.prototype.splitFrozenCount = function (columns) {\n if (this.frozenColumns || (this.changedProperties && this.changedProperties.frozenColumns === 0)) {\n var cols = !this.enableColumnVirtualization || (this.enableColumnVirtualization && this.isPreparedFrozenColumns) ?\n this.enableColumnVirtualization && this.columnModel && this.columnModel.length ? this.columnModel :\n this.getColumns() : this.columns;\n if (!this.changedProperties || (this.changedProperties && !this.changedProperties.frozenColumns)) {\n for (var i = 0; i < cols.length; i++) {\n if (this.frozenColumns > i) {\n cols[parseInt(i.toString(), 10)].freeze = 'Left';\n }\n else if (cols[parseInt(i.toString(), 10)].freeze === 'Right' || cols[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n cols[parseInt(i.toString(), 10)].freeze = cols[parseInt(i.toString(), 10)].freeze;\n }\n else {\n cols[parseInt(i.toString(), 10)].freeze = undefined;\n }\n }\n }\n }\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].columns) {\n this.leftcount = 0;\n this.rightcount = 0;\n this.movablecount = 0;\n this.fixedcount = 0;\n var arr = [];\n this.splitStackedColumns(columns[parseInt(i.toString(), 10)].columns);\n if (this.leftcount && !this.rightcount && !this.movablecount && !this.fixedcount) {\n this.frozenLeftCount += this.leftcount;\n this.frozenLeftColumns.push(columns[parseInt(i.toString(), 10)]);\n }\n else if (this.rightcount && !this.leftcount && !this.movablecount && !this.fixedcount) {\n this.frozenRightCount += this.rightcount;\n this.frozenRightColumns.push(columns[parseInt(i.toString(), 10)]);\n }\n else if (this.movablecount && !this.leftcount && !this.rightcount && !this.fixedcount) {\n this.movableCount += this.movablecount;\n this.movableColumns.push(columns[parseInt(i.toString(), 10)]);\n }\n else if (this.fixedcount && !this.leftcount && !this.rightcount && !this.movablecount) {\n this.fixedCount += this.fixedcount;\n this.fixedColumns.push(columns[parseInt(i.toString(), 10)]);\n this.movableCount += this.movablecount;\n this.movableColumns.push(columns[parseInt(i.toString(), 10)]);\n }\n else {\n this.frozenLeftCount += this.leftcount;\n this.frozenRightCount += this.rightcount;\n this.movableCount += this.movablecount;\n this.fixedCount += this.fixedcount;\n this.leftcount = 0;\n this.rightcount = 0;\n this.movablecount = 0;\n this.fixedcount = 0;\n this.stackedLeft = [];\n this.stackedRight = [];\n this.stackedFixed = [];\n this.stackedMovable = [];\n this.stackedarrayLeft = [];\n this.stackedarrayRight = [];\n this.stackedarrayFixed = [];\n this.stackedarrayMovable = [];\n this.pushStackedColumns(columns[parseInt(i.toString(), 10)].columns, 0, arr, columns[parseInt(i.toString(), 10)], { headerText: columns[parseInt(i.toString(), 10)].headerText, columns: [] });\n if (this.stackedarrayLeft.length) {\n this.resetStackedColumns(this.stackedLeft, this.stackedarrayLeft, 'Left');\n }\n if (this.stackedarrayRight.length) {\n this.resetStackedColumns(this.stackedRight, this.stackedarrayRight, 'Right');\n }\n if (this.stackedarrayFixed.length) {\n this.resetStackedColumns(this.stackedFixed, this.stackedarrayFixed, 'Fixed');\n }\n if (this.stackedarrayMovable.length) {\n this.resetStackedColumns(this.stackedMovable, this.stackedarrayMovable, 'Movable');\n }\n this.stackedLeft = [];\n this.stackedRight = [];\n this.stackedMovable = [];\n this.stackedFixed = [];\n this.stackedarrayLeft = [];\n this.stackedarrayRight = [];\n this.stackedarrayMovable = [];\n this.stackedarrayFixed = [];\n }\n }\n else {\n if (columns[parseInt(i.toString(), 10)].freeze === 'Right') {\n if (columns[parseInt(i.toString(), 10)].visible !== false) {\n this.visibleFrozenRight++;\n }\n this.frozenRightColumns.push(columns[parseInt(i.toString(), 10)]);\n this.frozenRightCount++;\n }\n else if (columns[parseInt(i.toString(), 10)].freeze === 'Left' || columns[parseInt(i.toString(), 10)].isFrozen) {\n if (columns[parseInt(i.toString(), 10)].visible !== false) {\n this.visibleFrozenLeft++;\n }\n this.frozenLeftColumns.push(columns[parseInt(i.toString(), 10)]);\n this.frozenLeftCount++;\n }\n else if (columns[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n this.fixedColumns.push(columns[parseInt(i.toString(), 10)]);\n this.fixedCount++;\n this.movableColumns.push(columns[parseInt(i.toString(), 10)]);\n this.movableCount++;\n }\n else {\n if (columns[parseInt(i.toString(), 10)].visible !== false) {\n this.visibleMovable++;\n }\n this.movableColumns.push(columns[parseInt(i.toString(), 10)]);\n this.movableCount++;\n }\n }\n }\n if (this.frozenLeftColumns.length) {\n var cols = this.frozenLeftColumns[this.frozenLeftColumns.length - 1];\n this.removeBorder(this.frozenLeftColumns);\n this.frozenLeftBorderColumns(cols instanceof Column ? this.lastVisibleLeftCol(this.frozenLeftColumns) : cols);\n }\n if (this.frozenRightColumns.length) {\n var cols = this.frozenRightColumns[0];\n this.removeBorder(this.frozenRightColumns);\n this.frozenRightBorderColumns(cols instanceof Column ? this.firstVisibleRightCol(this.frozenRightColumns) : cols);\n }\n if ((this.frozenLeftColumns.length || this.frozenRightColumns.length) && this.freezeColumnRefresh) {\n var cols = (this.frozenLeftColumns.concat(this.movableColumns)).concat(this.frozenRightColumns);\n this.setProperties({ columns: cols }, true);\n this.freezeColumnRefresh = false;\n }\n };\n Grid.prototype.removeBorder = function (columns) {\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].columns && columns[parseInt(i.toString(), 10)].columns.length) {\n if (columns[parseInt(i.toString(), 10)].border === 'Right' ||\n columns[parseInt(i.toString(), 10)].border === 'Left') {\n columns[parseInt(i.toString(), 10)].border = undefined;\n }\n this.removeBorder(columns[parseInt(i.toString(), 10)].columns);\n }\n else {\n if (columns[parseInt(i.toString(), 10)].border === 'Right' ||\n columns[parseInt(i.toString(), 10)].border === 'Left') {\n columns[parseInt(i.toString(), 10)].border = undefined;\n }\n }\n }\n };\n Grid.prototype.isVisibleColumns = function (column, arr) {\n if (column.columns && column.columns.length) {\n for (var i = 0; i < column.columns.length; i++) {\n this.isVisibleColumns(column.columns[parseInt(i.toString(), 10)], arr);\n if (column.columns[parseInt(i.toString(), 10)].visible &&\n isNullOrUndefined(column.columns[parseInt(i.toString(), 10)].columns) &&\n (!isNullOrUndefined(column.columns[parseInt(i.toString(), 10)].freeze) ||\n column.columns[parseInt(i.toString(), 10)].isFrozen)) {\n arr.push('true');\n }\n }\n }\n else {\n if (column.visible && (!isNullOrUndefined(column.freeze) || column.isFrozen)) {\n arr.push('true');\n }\n }\n };\n Grid.prototype.lastVisibleLeftCol = function (columns) {\n var column;\n for (var i = columns.length - 1; i >= 0; i--) {\n var arr = [];\n this.isVisibleColumns(columns[parseInt(i.toString(), 10)], arr);\n if (columns[parseInt(i.toString(), 10)].visible && arr.indexOf('true') !== -1) {\n column = columns[parseInt(i.toString(), 10)];\n break;\n }\n }\n return column;\n };\n Grid.prototype.firstVisibleRightCol = function (columns) {\n var column;\n for (var i = 0; i < columns.length; i++) {\n var arr = [];\n this.isVisibleColumns(columns[parseInt(i.toString(), 10)], arr);\n if (columns[parseInt(i.toString(), 10)].visible && arr.indexOf('true') !== -1) {\n column = columns[parseInt(i.toString(), 10)];\n break;\n }\n }\n return column;\n };\n Grid.prototype.frozenLeftBorderColumns = function (columns) {\n if (isNullOrUndefined(columns)) {\n return;\n }\n if (columns.columns && columns.columns.length) {\n columns.border = 'Left';\n var cols = columns.columns[columns.columns.length - 1];\n this.frozenLeftBorderColumns(cols instanceof Column && cols.columns ? this.lastVisibleLeftCol(columns.columns) : cols);\n }\n else {\n columns.border = 'Left';\n }\n };\n Grid.prototype.frozenRightBorderColumns = function (columns) {\n if (isNullOrUndefined(columns)) {\n return;\n }\n if (columns.columns && columns.columns.length) {\n columns.border = 'Right';\n var cols = columns.columns[0];\n this.frozenRightBorderColumns(cols instanceof Column && cols.columns ? this.firstVisibleRightCol(columns.columns) : cols);\n }\n else {\n columns.border = 'Right';\n }\n };\n /**\n * @hidden\n * @returns {number} Returns the visible frozen columns count\n */\n Grid.prototype.getVisibleFrozenColumns = function () {\n return this.getVisibleFrozenColumnsCount() + this.getVisibleFrozenCount(this.columns, 0);\n };\n /**\n * Get the current Filter operator and field.\n *\n * @returns {FilterUI} Returns the filter UI\n */\n Grid.prototype.getFilterUIInfo = function () {\n return this.filterModule ? this.filterModule.getFilterUIInfo() : {};\n };\n Grid.prototype.getVisibleFrozenColumnsCount = function () {\n var visibleFrozenColumns = 0;\n var columns = this.columnModel;\n for (var i = 0; i < this.frozenColumns; i++) {\n if (columns[parseInt(i.toString(), 10)].visible) {\n visibleFrozenColumns++;\n }\n }\n if ((this.frozenLeftCount || this.leftcount) || (this.frozenRightCount || this.rightcount)) {\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].visible && (columns[parseInt(i.toString(), 10)].freeze === 'Left'\n || columns[parseInt(i.toString(), 10)].freeze === 'Right')) {\n visibleFrozenColumns++;\n }\n }\n }\n return visibleFrozenColumns;\n };\n Grid.prototype.getVisibleFrozenCount = function (cols, cnt) {\n if ((!this.frozenLeftCount && !this.leftcount) && (!this.frozenRightCount || !this.rightcount)) {\n for (var i = 0, len = cols.length; i < len; i++) {\n if (cols[parseInt(i.toString(), 10)].columns) {\n cnt = this.getVisibleFrozenCount(cols[parseInt(i.toString(), 10)].columns, cnt);\n }\n else {\n if (cols[parseInt(i.toString(), 10)].isFrozen && cols[parseInt(i.toString(), 10)].visible) {\n cnt++;\n }\n }\n }\n }\n return cnt;\n };\n Grid.prototype.getFrozenCount = function (cols, cnt, index) {\n for (var i = 0, len = cols.length; i < len; i++) {\n if (cols[parseInt(i.toString(), 10)].columns) {\n cnt = this.getFrozenCount(cols[parseInt(i.toString(), 10)].columns, cnt, index);\n }\n else {\n if (cols[parseInt(i.toString(), 10)].isFrozen && index > this.frozenColumns - 1) {\n cnt++;\n }\n index++;\n }\n }\n return cnt;\n };\n /**\n * Navigates to the specified target page.\n *\n * @param {number} pageNo - Defines the page number to navigate.\n *\n * @returns {void}\n */\n Grid.prototype.goToPage = function (pageNo) {\n if (this.pagerModule) {\n this.pagerModule.goToPage(pageNo);\n }\n };\n /**\n * Defines the text of external message.\n *\n * @param {string} message - Defines the message to update.\n *\n * @returns {void}\n */\n Grid.prototype.updateExternalMessage = function (message) {\n if (this.pagerModule && !this.pagerTemplate) {\n this.pagerModule.updateExternalMessage(message);\n }\n };\n /**\n * Sorts a column with the given options.\n *\n * @param {string} columnName - Defines the column name to be sorted.\n * @param {SortDirection} direction - Defines the direction of sorting field.\n * @param {boolean} isMultiSort - Specifies whether the previous sorted columns are to be maintained.\n *\n * @returns {void}\n */\n Grid.prototype.sortColumn = function (columnName, direction, isMultiSort) {\n if (this.sortModule) {\n this.sortModule.sortColumn(columnName, direction, isMultiSort);\n }\n };\n /**\n * Remove the existing columns along with the grid actions like sorting, filtering, searching, grouping, aggregate, etc., and grid will refresh with new columns based on the updated new data source.\n * > * If no columns are specified while changing the data source, then the columns are auto generated in the Grid based on the list of columns in the updated data source.\n *\n * @param {Object | DataManager | DataResult} dataSource - Assign the new datasource.\n * @param {Column[] | string[] | ColumnModel[]} columns - Defines columns.\n * @returns {void}\n *\n *\n * ```typescript\n * <button id=\"btn\">change dataSource </button>\n * <div id=\"Grid\"></div>\n * <script>\n * let gridObj: Grid = new Grid({\n * dataSource: employeeData, // you can define the datamanager here if you are binding a data through datamanager\n * columns: [\n * { field: 'OrderID', headerText: 'Order ID', width:100 },\n * { field: 'EmployeeID', headerText: 'Employee ID' }],\n * });\n * gridObj.appendTo('#Grid');\n * document.getElementById('btn').addEventListener(\"click\", function(){\n * let newColumn: [\n * { field: 'CustomerID', headerText: 'Customer ID', width:100 },\n * { field: 'FirstName', headerText: 'Name' }];\n * gridObj.changeDataSource(customerData, newColumn);\n * });\n * </script>\n * ```\n *\n */\n Grid.prototype.changeDataSource = function (dataSource, columns) {\n this.isChangeDataSourceCall = true;\n this.setProperties({ sortSettings: { columns: [] } }, true);\n this.setProperties({ filterSettings: { columns: [] } }, true);\n this.setProperties({ searchSettings: { key: '' } }, true);\n if (this.allowGrouping) {\n this.setProperties({ groupSettings: { columns: [] } }, true);\n }\n if (columns && columns.length) {\n this.setProperties({ columns: columns }, true);\n }\n if (dataSource) {\n if (isNullOrUndefined(columns)) {\n this.setProperties({ columns: [] }, true);\n }\n this.setProperties({ dataSource: dataSource }, true);\n }\n this.freezeRefresh();\n this.isChangeDataSourceCall = false;\n };\n /**\n * Clears all the sorted columns of the Grid.\n *\n * @returns {void}\n */\n Grid.prototype.clearSorting = function () {\n if (this.sortModule) {\n this.sortModule.clearSorting();\n }\n };\n /**\n * Remove sorted column by field name.\n *\n * @param {string} field - Defines the column field name to remove sort.\n * @returns {void}\n * @hidden\n */\n Grid.prototype.removeSortColumn = function (field) {\n if (this.sortModule) {\n this.sortModule.removeSortColumn(field);\n }\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.clearGridActions = function () {\n this.setProperties({ sortSettings: { columns: [] } }, true);\n this.setProperties({ filterSettings: { columns: [] } }, true);\n this.setProperties({ searchSettings: { key: '' } }, true);\n if (this.allowGrouping) {\n this.setProperties({ groupSettings: { columns: [] } }, false);\n }\n else {\n this.freezeRefresh();\n }\n };\n /**\n * Filters grid row by column name with the given options.\n *\n * @param {string} fieldName - Defines the field name of the column.\n * @param {string} filterOperator - Defines the operator to filter records.\n * @param {string | number | Date | boolean} filterValue - Defines the value used to filter records.\n * @param {string} predicate - Defines the relationship between one filter query and another by using AND or OR predicate.\n * @param {boolean} matchCase - If match case is set to true, the grid filters the records with exact match. if false, it filters case\n * insensitive records (uppercase and lowercase letters treated the same).\n * @param {boolean} ignoreAccent - If ignoreAccent set to true,\n * then filter ignores the diacritic characters or accents while filtering.\n * @param {string} actualFilterValue - Defines the actual filter value for the filter column.\n * @param {string} actualOperator - Defines the actual filter operator for the filter column.\n *\n * @returns {void}\n */\n Grid.prototype.filterByColumn = function (fieldName, filterOperator, filterValue, predicate, matchCase, ignoreAccent, actualFilterValue, actualOperator) {\n if (this.filterModule) {\n this.filterModule.filterByColumn(fieldName, filterOperator, filterValue, predicate, matchCase, ignoreAccent, actualFilterValue, actualOperator);\n }\n };\n /**\n * Clears all the filtered rows of the Grid.\n *\n * @param {string[]} fields - Defines the Fields\n * @returns {void}\n */\n Grid.prototype.clearFiltering = function (fields) {\n if (this.filterModule) {\n this.filterModule.clearFiltering(fields);\n }\n };\n /**\n * Removes filtered column by field name.\n *\n * @param {string} field - Defines column field name to remove filter.\n * @param {boolean} isClearFilterBar - Specifies whether the filter bar value needs to be cleared.\n * @returns {void}\n * @hidden\n */\n Grid.prototype.removeFilteredColsByField = function (field, isClearFilterBar) {\n if (this.filterModule) {\n this.filterModule.removeFilteredColsByField(field, isClearFilterBar);\n }\n };\n /**\n * Selects a row by given index.\n *\n * @param {number} index - Defines the row index.\n * @param {boolean} isToggle - If set to true, then it toggles the selection.\n *\n * @returns {void}\n */\n Grid.prototype.selectRow = function (index, isToggle) {\n if (this.selectionModule) {\n this.selectionModule.selectRow(index, isToggle);\n }\n };\n /**\n * Selects a collection of rows by indexes.\n *\n * @param {number[]} rowIndexes - Specifies the row indexes.\n *\n * @returns {void}\n */\n Grid.prototype.selectRows = function (rowIndexes) {\n if (this.selectionModule) {\n this.selectionModule.selectRows(rowIndexes);\n }\n };\n /**\n * Deselects the current selected rows and cells.\n *\n * @returns {void}\n */\n Grid.prototype.clearSelection = function () {\n if (this.selectionModule) {\n this.selectionModule.clearSelection();\n }\n };\n /**\n * Selects a cell by the given index.\n *\n * @param {IIndex} cellIndex - Defines the row and column indexes.\n * @param {boolean} isToggle - If set to true, then it toggles the selection.\n *\n * @returns {void}\n */\n Grid.prototype.selectCell = function (cellIndex, isToggle) {\n if (this.selectionModule) {\n this.selectionModule.selectCell(cellIndex, isToggle);\n }\n };\n /**\n * Selects a range of cells from start and end indexes.\n *\n * @param {IIndex} startIndex - Specifies the row and column's start index.\n * @param {IIndex} endIndex - Specifies the row and column's end index.\n *\n * @returns {void}\n */\n Grid.prototype.selectCellsByRange = function (startIndex, endIndex) {\n this.selectionModule.selectCellsByRange(startIndex, endIndex);\n };\n /**\n * Searches Grid records using the given key.\n * You can customize the default search option by using the\n * [`searchSettings`](./#searchsettings/).\n *\n * @param {string} searchString - Defines the key.\n *\n * @returns {void}\n */\n Grid.prototype.search = function (searchString) {\n if (this.searchModule) {\n this.searchModule.search(searchString);\n }\n };\n /**\n * By default, prints all the pages of the Grid and hides the pager.\n * > You can customize print options using the\n * [`printMode`](./#printmode).\n *\n * @returns {void}\n */\n Grid.prototype.print = function () {\n if (this.printModule) {\n this.printModule.print();\n }\n };\n /**\n * Delete a record with Given options. If fieldname and data is not given then grid will delete the selected record.\n * > `editSettings.allowDeleting` should be true.\n *\n * @param {string} fieldname - Defines the primary key field, 'Name of the column'.\n * @param {Object} data - Defines the JSON data of the record to be deleted.\n * @returns {void}\n */\n Grid.prototype.deleteRecord = function (fieldname, data) {\n if (this.editModule) {\n this.editModule.deleteRecord(fieldname, data);\n }\n };\n /**\n * Starts edit the selected row. At least one row must be selected before invoking this method.\n * `editSettings.allowEditing` should be true.\n * {% codeBlock src='grid/startEdit/index.md' %}{% endcodeBlock %}\n *\n * @returns {void}\n */\n Grid.prototype.startEdit = function () {\n if (this.editModule) {\n this.editModule.startEdit();\n }\n };\n /**\n * If Grid is in editable state, you can save a record by invoking endEdit.\n *\n * @returns {void}\n */\n Grid.prototype.endEdit = function () {\n if (this.editModule) {\n this.editModule.endEdit();\n }\n };\n /**\n * Cancels edited state.\n *\n * @returns {void}\n */\n Grid.prototype.closeEdit = function () {\n if (this.editModule) {\n this.editModule.closeEdit();\n }\n };\n /**\n * Adds a new record to the Grid. Without passing parameters, it adds empty rows.\n * > `editSettings.allowEditing` should be true.\n *\n * @param {Object} data - Defines the new add record data.\n * @param {number} index - Defines the row index to be added\n * @returns {void}\n */\n Grid.prototype.addRecord = function (data, index) {\n if (this.editModule) {\n this.editModule.addRecord(data, index);\n }\n };\n /**\n * Delete any visible row by TR element.\n *\n * @param {HTMLTableRowElement} tr - Defines the table row element.\n * @returns {void}\n */\n Grid.prototype.deleteRow = function (tr) {\n if (this.editModule) {\n this.editModule.deleteRow(tr);\n }\n };\n /**\n * Changes a particular cell into edited state based on the row index and field name provided in the `batch` mode.\n *\n * @param {number} index - Defines row index to edit a particular cell.\n * @param {string} field - Defines the field name of the column to perform batch edit.\n *\n * @returns {void}\n */\n Grid.prototype.editCell = function (index, field) {\n if (this.editModule) {\n this.editModule.editCell(index, field);\n }\n };\n /**\n * Saves the cell that is currently edited. It does not save the value to the DataSource.\n *\n * @returns {void}\n * {% codeBlock src='grid/saveCell/index.md' %}{% endcodeBlock %}\n */\n Grid.prototype.saveCell = function () {\n if (this.editModule) {\n this.editModule.saveCell();\n }\n };\n /**\n * To update the specified cell by given value without changing into edited state.\n *\n * @param {number} rowIndex Defines the row index.\n * @param {string} field Defines the column field.\n * @param {string | number | boolean | Date} value - Defines the value to be changed.\n *\n * @returns {void}\n */\n Grid.prototype.updateCell = function (rowIndex, field, value) {\n if (this.editModule) {\n this.editModule.updateCell(rowIndex, field, value);\n }\n };\n /**\n * To update the specified row by given values without changing into edited state.\n *\n * {% codeBlock src='grid/updateRow/index.md' %}{% endcodeBlock %}\n *\n * @param {number} index Defines the row index.\n * @param {Object} data Defines the data object to be updated.\n *\n * @returns {void}\n */\n Grid.prototype.updateRow = function (index, data) {\n if (this.editModule) {\n this.editModule.updateRow(index, data);\n }\n };\n /**\n * Gets the added, edited,and deleted data before bulk save to the DataSource in batch mode.\n *\n * @returns {Object} Returns the batch changes\n */\n Grid.prototype.getBatchChanges = function () {\n if (this.editModule) {\n return this.editModule.getBatchChanges();\n }\n return {};\n };\n /**\n * Enables or disables ToolBar items.\n *\n * @param {string[]} items - Defines the collection of itemID of ToolBar items.\n * @param {boolean} isEnable - Defines the items to be enabled or disabled.\n *\n * @returns {void}\n */\n Grid.prototype.enableToolbarItems = function (items, isEnable) {\n if (this.toolbarModule) {\n this.toolbarModule.enableItems(items, isEnable);\n }\n };\n /**\n * Copy the selected rows or cells data into clipboard.\n *\n * @param {boolean} withHeader - Specifies whether the column header text needs to be copied along with rows or cells.\n * @returns {void}\n */\n Grid.prototype.copy = function (withHeader) {\n if (this.clipboardModule) {\n this.clipboardModule.copy(withHeader);\n }\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.recalcIndentWidth = function () {\n var _this_1 = this;\n if (!this.getHeaderTable().querySelector('.e-emptycell')) {\n return;\n }\n if ((!this.groupSettings.columns.length && !this.isDetail() && !this.isRowDragable()) ||\n this.getHeaderTable().querySelector('.e-emptycell').getAttribute('indentRefreshed') ||\n !this.getContentTable()) {\n return;\n }\n var indentWidth = this.getHeaderTable().querySelector('.e-emptycell').parentElement.offsetWidth;\n var headerCol = [].slice.call(this.getHeaderTable().querySelector(literals.colGroup).childNodes);\n var contentCol = [].slice.call(this.getContentTable().querySelector(literals.colGroup).childNodes);\n var perPixel = indentWidth / 30;\n var i = this.getFrozenMode() === 'Right' ? this.groupSettings.columns.length + this.getColumns().length : 0;\n var parentOffset = this.element.offsetWidth;\n var applyWidth = function (index, width) {\n if (ispercentageWidth(_this_1)) {\n var newWidth = (width / parentOffset * 100).toFixed(1) + '%';\n headerCol[parseInt(index.toString(), 10)].style.width = newWidth;\n contentCol[parseInt(index.toString(), 10)].style.width = newWidth;\n }\n else {\n headerCol[parseInt(index.toString(), 10)].style.width = width + 'px';\n contentCol[parseInt(index.toString(), 10)].style.width = width + 'px';\n }\n _this_1.notify(events.columnWidthChanged, { index: index, width: width });\n };\n if (perPixel >= 1) {\n indentWidth = (30 / perPixel);\n }\n if (indentWidth < 1) {\n indentWidth = 1;\n }\n if (this.enableColumnVirtualization || this.isAutoGen || (this.columns.length === this.groupSettings.columns.length)) {\n indentWidth = 30;\n }\n while (i < this.groupSettings.columns.length) {\n applyWidth(i, indentWidth);\n i++;\n }\n if (this.isDetail()) {\n applyWidth(i, indentWidth);\n i++;\n }\n if (this.isRowDragable()) {\n applyWidth(i, indentWidth);\n }\n this.isAutoGen = false;\n this.getHeaderTable().querySelector('.e-emptycell').setAttribute('indentRefreshed', 'true');\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.resetIndentWidth = function () {\n if (ispercentageWidth(this)) {\n this.getHeaderTable().querySelector('.e-emptycell').removeAttribute('indentRefreshed');\n this.widthService.setWidthToColumns();\n this.recalcIndentWidth();\n if (this.autoFit) {\n this.preventAdjustColumns();\n }\n }\n if ((this.width === 'auto' || typeof (this.width) === 'string' && this.width.indexOf('%') !== -1)\n && this.getColumns().filter(function (col) { return (!col.width || col.width === 'auto') && col.minWidth; }).length > 0) {\n var tgridWidth = this.widthService.getTableWidth(this.getColumns());\n this.widthService.setMinwidthBycalculation(tgridWidth);\n }\n if (this.isFrozenGrid() && this.enableColumnVirtualization && this.widthService) {\n this.widthService.refreshFrozenScrollbar();\n }\n if (this.allowTextWrap && this.textWrapSettings.wrapMode !== 'Content') {\n this.notify(events.refreshHandlers, {});\n }\n if (this.frozenRows && this.scrollModule) {\n this.scrollModule.resizeFrozenRowBorder();\n }\n };\n /**\n * @hidden\n * @returns {boolean} Returns isRowDragable\n */\n Grid.prototype.isRowDragable = function () {\n return this.allowRowDragAndDrop && !this.rowDropSettings.targetID;\n };\n /**\n * Changes the Grid column positions by field names.\n *\n * @param {string} fromFName - Defines the origin field name.\n * @param {string} toFName - Defines the destination field name.\n *\n * @returns {void}\n */\n Grid.prototype.reorderColumns = function (fromFName, toFName) {\n if (this.reorderModule) {\n this.reorderModule.reorderColumns(fromFName, toFName);\n }\n };\n /**\n * Changes the Grid column positions by field index. If you invoke reorderColumnByIndex multiple times,\n * then you won't get the same results every time.\n *\n * @param {number} fromIndex - Defines the origin field index.\n * @param {number} toIndex - Defines the destination field index.\n *\n * @returns {void}\n */\n Grid.prototype.reorderColumnByIndex = function (fromIndex, toIndex) {\n if (this.reorderModule) {\n this.reorderModule.reorderColumnByIndex(fromIndex, toIndex);\n }\n };\n /**\n * Changes the Grid column positions by field index. If you invoke reorderColumnByTargetIndex multiple times,\n * then you will get the same results every time.\n *\n * @param {string} fieldName - Defines the field name.\n * @param {number} toIndex - Defines the destination field index.\n *\n * @returns {void}\n */\n Grid.prototype.reorderColumnByTargetIndex = function (fieldName, toIndex) {\n if (this.reorderModule) {\n this.reorderModule.reorderColumnByTargetIndex(fieldName, toIndex);\n }\n };\n /**\n * Changes the Grid Row position with given indexes.\n *\n * @param {number} fromIndexes - Defines the origin Indexes.\n * @param {number} toIndex - Defines the destination Index.\n *\n * @returns {void}\n */\n Grid.prototype.reorderRows = function (fromIndexes, toIndex) {\n if (this.rowDragAndDropModule) {\n this.rowDragAndDropModule.reorderRows(fromIndexes, toIndex);\n }\n };\n /**\n * @param {ReturnType} e - Defines the Return type\n * @returns {void}\n * @hidden\n */\n Grid.prototype.refreshDataSource = function (e) {\n this.notify('refreshdataSource', e);\n };\n /**\n * @param {boolean} enable -Defines the enable\n * @returns {void}\n * @hidden\n */\n Grid.prototype.disableRowDD = function (enable) {\n var headerTable = this.getHeaderTable();\n var contentTable = this.getContentTable();\n var headerRows = headerTable.querySelectorAll('th.e-rowdragheader, th.e-mastercell');\n var rows = this.getRows();\n var disValue = enable ? 'none' : '';\n setStyleAttribute(headerTable.querySelector(literals.colGroup).childNodes[0], { 'display': disValue });\n setStyleAttribute(contentTable.querySelector(literals.colGroup).childNodes[0], { 'display': disValue });\n for (var i = 0; i < this.getRows().length; i++) {\n var ele = rows[parseInt(i.toString(), 10)].firstElementChild;\n if (enable) {\n addClass([ele], 'e-hide');\n }\n else {\n removeClass([ele], ['e-hide']);\n }\n }\n for (var j = 0; j < headerTable.querySelectorAll('th.e-rowdragheader, th.e-mastercell').length; j++) {\n var ele = headerRows[parseInt(j.toString(), 10)];\n if (enable) {\n addClass([ele], 'e-hide');\n }\n else {\n removeClass([ele], ['e-hide']);\n }\n }\n };\n /**\n * Changes the column width to automatically fit its content to ensure that the width shows the content without wrapping/hiding.\n * > * This method ignores the hidden columns.\n * > * Uses the `autoFitColumns` method in the `dataBound` event to resize at initial rendering.\n *\n * @param {string |string[]} fieldNames - Defines the column names.\n * @returns {void}\n *\n *\n * ```typescript\n * <div id=\"Grid\"></div>\n * <script>\n * let gridObj: Grid = new Grid({\n * dataSource: employeeData,\n * columns: [\n * { field: 'OrderID', headerText: 'Order ID', width:100 },\n * { field: 'EmployeeID', headerText: 'Employee ID' }],\n * dataBound: () => gridObj.autoFitColumns('EmployeeID')\n * });\n * gridObj.appendTo('#Grid');\n * </script>\n * ```\n *\n */\n Grid.prototype.autoFitColumns = function (fieldNames) {\n if (this.resizeModule) {\n this.resizeModule.autoFitColumns(fieldNames);\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Grid.prototype.preventAdjustColumns = function () {\n if ((this.enableAdaptiveUI && this.rowRenderingMode === 'Vertical')\n || (this.allowResizing && this.resizeSettings.mode === 'Auto')) {\n return;\n }\n var columns = this.getColumns();\n var headerTable = this.getHeaderTable();\n var tableWidth = 0;\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].visible) {\n if (this.groupSettings.columns.length\n && this.groupSettings.columns.indexOf(columns[parseInt(i.toString(), 10)].field) > -1) {\n var headerCol = [].slice.call(headerTable.querySelector('colgroup')\n .querySelectorAll(':not(.e-group-intent):not(.e-detail-intent):not(.e-drag-intent)'));\n if (headerCol[parseInt(i.toString(), 10)].style.display === 'none') {\n continue;\n }\n }\n if (columns[parseInt(i.toString(), 10)].width) {\n tableWidth += parseFloat(columns[parseInt(i.toString(), 10)].width.toString());\n }\n else {\n tableWidth = 0;\n break;\n }\n }\n }\n if (tableWidth) {\n var percentageWidth = this.isPercentageWidthGrid();\n var unit = this.widthUnit(percentageWidth);\n var contentTable = this.getContentTable();\n if (this.groupSettings.columns.length || this.isDetail() || this.isRowDragable()) {\n var indentWidth = this.defaultIndentWidth(percentageWidth);\n var indentWidthUnitFormat = indentWidth.toString() + unit;\n var headerIndentCol = [].slice.call(headerTable.querySelector('colgroup')\n .querySelectorAll('.e-group-intent, .e-detail-intent, .e-drag-intent'));\n var contentIndentCol = [].slice.call(contentTable.querySelector('colgroup')\n .querySelectorAll('.e-group-intent, .e-detail-intent, .e-drag-intent'));\n for (var i = 0; i < headerIndentCol.length; i++) {\n headerIndentCol[parseInt(i.toString(), 10)].style.setProperty('width', indentWidthUnitFormat);\n contentIndentCol[parseInt(i.toString(), 10)].style.setProperty('width', indentWidthUnitFormat);\n tableWidth += indentWidth;\n }\n }\n if ((percentageWidth && tableWidth < 100)\n || (!percentageWidth && tableWidth < contentTable.parentElement.clientWidth)) {\n if (!isNullOrUndefined(contentTable.querySelector('.e-emptyrow'))) {\n addClass([headerTable], ['e-tableborder']);\n removeClass([contentTable], ['e-tableborder']);\n }\n else {\n addClass([headerTable, contentTable], ['e-tableborder']);\n }\n }\n var tableWidthUnitFormat = tableWidth.toString() + unit;\n headerTable.style.setProperty('width', tableWidthUnitFormat);\n contentTable.style.setProperty('width', tableWidthUnitFormat);\n }\n else {\n this.restoreAdjustColumns();\n }\n };\n Grid.prototype.restoreAdjustColumns = function () {\n if ((this.enableAdaptiveUI && this.rowRenderingMode === 'Vertical')\n || (this.allowResizing && this.resizeSettings.mode === 'Auto')) {\n return;\n }\n var headerTable = this.getHeaderTable();\n var contentTable = this.getContentTable();\n removeClass([headerTable, contentTable], ['e-tableborder']);\n headerTable.style.removeProperty('width');\n contentTable.style.removeProperty('width');\n if (this.groupSettings.columns.length || this.isDetail() || this.isRowDragable()) {\n var percentageWidth = this.isPercentageWidthGrid();\n var indentWidthUnitFormat_1 = this.defaultIndentWidth(percentageWidth).toString() + this.widthUnit(percentageWidth);\n var headerIndentCol = [].slice.call(headerTable.querySelector('colgroup')\n .querySelectorAll('.e-group-intent, .e-detail-intent, .e-drag-intent'));\n headerIndentCol.forEach(function (element) {\n element.style.setProperty('width', indentWidthUnitFormat_1);\n });\n headerTable.querySelector('.e-emptycell').removeAttribute('indentRefreshed');\n this.recalcIndentWidth();\n }\n };\n Grid.prototype.widthUnit = function (percentageWidth) {\n return percentageWidth ? '%' : 'px';\n };\n Grid.prototype.defaultIndentWidth = function (percentageWidth) {\n return percentageWidth ? parseFloat((30 / this.element.offsetWidth * 100).toFixed(1)) : 30;\n };\n Grid.prototype.isPercentageWidthGrid = function () {\n return this.getColumns()[0].width.toString().indexOf('%') > -1;\n };\n /**\n * @param {number} x - Defines the number\n * @param {number} y - Defines the number\n * @param {Element} target - Defines the Element\n * @returns {void}\n * @hidden\n */\n Grid.prototype.createColumnchooser = function (x, y, target) {\n if (this.columnChooserModule) {\n this.columnChooserModule.renderColumnChooser(x, y, target);\n }\n };\n Grid.prototype.initializeServices = function () {\n this.serviceLocator.register('widthService', this.widthService = new ColumnWidthService(this));\n this.serviceLocator.register('cellRendererFactory', new CellRendererFactory);\n this.serviceLocator.register('rendererFactory', new RendererFactory);\n this.serviceLocator.register('localization', this.localeObj = new L10n(this.getModuleName(), this.defaultLocale, this.locale));\n this.serviceLocator.register('valueFormatter', this.valueFormatterService = new ValueFormatter(this.locale));\n this.serviceLocator.register('showHideService', this.showHider = new ShowHide(this));\n this.serviceLocator.register('ariaService', this.ariaService = new AriaService());\n this.serviceLocator.register('focus', this.focusModule = new FocusStrategy(this));\n };\n Grid.prototype.processModel = function () {\n var gCols = this.groupSettings.columns;\n var sCols = this.sortSettings.columns;\n var flag;\n var j;\n if (this.allowGrouping) {\n var _loop_3 = function (i, len) {\n j = 0;\n for (var sLen = sCols.length; j < sLen; j++) {\n if (sCols[parseInt(j.toString(), 10)].field === gCols[parseInt(i.toString(), 10)]) {\n flag = true;\n break;\n }\n }\n if (!flag) {\n sCols.push({ field: gCols[parseInt(i.toString(), 10)], direction: 'Ascending', isFromGroup: true });\n }\n else {\n if (this_3.allowSorting) {\n this_3.sortedColumns.push(sCols[parseInt(j.toString(), 10)].field);\n }\n else {\n sCols[parseInt(j.toString(), 10)].direction = 'Ascending';\n }\n }\n if (!this_3.groupSettings.showGroupedColumn) {\n var column = this_3.enableColumnVirtualization ?\n this_3.columns.filter(function (c) { return c.field === gCols[parseInt(i.toString(), 10)]; })[0]\n : this_3.getColumnByField(gCols[parseInt(i.toString(), 10)]);\n if (column) {\n column.visible = false;\n }\n else {\n this_3.log('initial_action', { moduleName: 'group', columnName: gCols[parseInt(i.toString(), 10)] });\n }\n }\n };\n var this_3 = this;\n for (var i = 0, len = gCols.length; i < len; i++) {\n _loop_3(i, len);\n }\n }\n if (!gCols.length) {\n for (var i = 0; i < sCols.length; i++) {\n this.sortedColumns.push(sCols[parseInt(i.toString(), 10)].field);\n }\n }\n this.rowTemplateFn = templateCompiler(this.rowTemplate);\n this.emptyRecordTemplateFn = templateCompiler(this.emptyRecordTemplate);\n this.detailTemplateFn = templateCompiler(this.detailTemplate);\n this.editTemplateFn = templateCompiler(this.editSettings.template);\n this.editHeaderTemplateFn = templateCompiler(this.editSettings.headerTemplate);\n this.editFooterTemplateFn = templateCompiler(this.editSettings.footerTemplate);\n if (!isNullOrUndefined(this.parentDetails)) {\n var value = isNullOrUndefined(this.parentDetails.parentKeyFieldValue) ? 'undefined' :\n this.parentDetails.parentKeyFieldValue;\n this.query.where(this.queryString, 'equal', value, true);\n }\n this.initForeignColumn();\n };\n Grid.prototype.initForeignColumn = function () {\n if (this.isForeignKeyEnabled(this.getColumns())) {\n this.notify(events.initForeignKeyColumn, this.getForeignKeyColumns());\n }\n };\n Grid.prototype.enableVerticalRendering = function () {\n if (this.rowRenderingMode === 'Vertical') {\n this.element.classList.add('e-row-responsive');\n }\n else {\n this.element.classList.remove('e-row-responsive');\n }\n };\n Grid.prototype.gridRender = function () {\n var _a;\n this.updateRTL();\n if (this.rowRenderingMode === 'Vertical') {\n this.element.classList.add('e-row-responsive');\n }\n if (this.enableHover) {\n this.element.classList.add('e-gridhover');\n }\n if (Browser.isDevice) {\n this.element.classList.add('e-device');\n }\n if (this.rowHeight) {\n this.element.classList.add('e-grid-min-height');\n }\n if (this.cssClass) {\n if (this.cssClass.indexOf(' ') !== -1) {\n (_a = this.element.classList).add.apply(_a, this.cssClass.split(' '));\n }\n else {\n this.element.classList.add(this.cssClass);\n }\n }\n // If the below if statement is removed, then drag and drop between grids will not work in firefox browser.\n if (this.allowRowDragAndDrop && this.rowDropSettings.targetID && Browser.info.name === 'mozilla') {\n this.element.classList.add('e-disableuserselect');\n }\n classList(this.element, ['e-responsive', 'e-default'], []);\n var rendererFactory = this.serviceLocator.getService('rendererFactory');\n this.headerModule = rendererFactory.getRenderer(RenderType.Header);\n this.contentModule = rendererFactory.getRenderer(RenderType.Content);\n this.printModule = new Print(this, this.scrollModule);\n this.clipboardModule = new Clipboard(this, this.serviceLocator);\n this.renderModule.render();\n this.eventInitializer();\n this.createGridPopUpElement();\n this.widthService.setWidthToColumns();\n this.updateGridLines();\n this.applyTextWrap();\n this.createTooltip(); //for clip mode ellipsis\n this.enableBoxSelection();\n };\n Grid.prototype.dataReady = function () {\n this.scrollModule.setWidth();\n this.scrollModule.setHeight();\n if (this.height !== 'auto') {\n this.scrollModule.setPadding();\n }\n };\n Grid.prototype.updateRTL = function () {\n if (this.enableRtl) {\n this.element.classList.add('e-rtl');\n }\n else {\n this.element.classList.remove('e-rtl');\n }\n };\n Grid.prototype.createGridPopUpElement = function () {\n var popup = this.createElement('div', { className: 'e-gridpopup', styles: 'display:none;' });\n var content = this.createElement('div', { className: literals.content, attrs: { tabIndex: '-1' } });\n append([content, this.createElement('div', { className: 'e-uptail e-tail' })], popup);\n content.appendChild(this.createElement('span'));\n append([content, this.createElement('div', { className: 'e-downtail e-tail' })], popup);\n this.element.appendChild(popup);\n };\n Grid.prototype.updateGridLines = function () {\n classList(this.element, [], ['e-verticallines', 'e-horizontallines', 'e-hidelines', 'e-bothlines']);\n switch (this.gridLines) {\n case 'Horizontal':\n this.element.classList.add('e-horizontallines');\n break;\n case 'Vertical':\n this.element.classList.add('e-verticallines');\n break;\n case 'None':\n this.element.classList.add('e-hidelines');\n break;\n case 'Both':\n this.element.classList.add('e-bothlines');\n break;\n }\n this.updateResizeLines();\n };\n Grid.prototype.updateResizeLines = function () {\n if (this.allowResizing &&\n !(this.gridLines === 'Vertical' || this.gridLines === 'Both')) {\n this.element.classList.add('e-resize-lines');\n }\n else {\n this.element.classList.remove('e-resize-lines');\n }\n };\n /**\n * The function is used to apply text wrap\n *\n * @returns {void}\n * @hidden\n */\n Grid.prototype.applyTextWrap = function () {\n if (this.allowTextWrap) {\n var headerRows = [].slice.call(this.element.getElementsByClassName('e-columnheader'));\n switch (this.textWrapSettings.wrapMode) {\n case 'Header':\n wrap(this.element, false);\n wrap(this.getContent(), false);\n wrap(headerRows, true);\n break;\n case 'Content':\n wrap(this.getContent(), true);\n wrap(this.element, false);\n wrap(headerRows, false);\n break;\n default:\n wrap(this.element, true);\n wrap(this.getContent(), false);\n wrap(headerRows, false);\n }\n if (this.textWrapSettings.wrapMode !== 'Content') {\n this.notify(events.refreshHandlers, {});\n }\n }\n };\n /**\n * The function is used to remove text wrap\n *\n * @returns {void}\n * @hidden\n */\n Grid.prototype.removeTextWrap = function () {\n wrap(this.element, false);\n var headerRows = [].slice.call(this.element.getElementsByClassName('e-columnheader'));\n wrap(headerRows, false);\n wrap(this.getContent(), false);\n if (this.textWrapSettings.wrapMode !== 'Content') {\n this.notify(events.refreshHandlers, {});\n }\n };\n /**\n * The function is used to add Tooltip to the grid cell that has ellipsiswithtooltip clip mode.\n *\n * @returns {void}\n * @hidden\n */\n Grid.prototype.createTooltip = function () {\n this.toolTipObj = new Tooltip({\n opensOn: 'custom',\n content: '',\n cssClass: this.cssClass ? this.cssClass : null\n }, this.element);\n };\n /** @hidden\n * @returns {void}\n */\n Grid.prototype.freezeRefresh = function () {\n if (this.enableVirtualization || this.enableInfiniteScrolling) {\n this.pageSettings.currentPage = 1;\n }\n this.componentRefresh();\n };\n Grid.prototype.getTooltipStatus = function (element) {\n var headerTable = this.getHeaderTable();\n var headerDivTag = this.enableAdaptiveUI && this.rowRenderingMode === 'Vertical' ? 'e-gridcontent' : 'e-gridheader';\n var htable = this.createTable(headerTable, headerDivTag, 'header');\n var ctable = this.createTable(headerTable, headerDivTag, 'content');\n var table = element.classList.contains('e-headercell') ? htable : ctable;\n var ele = element.classList.contains('e-headercell') ? 'th' : 'tr';\n table.querySelector(ele).className = element.className;\n table.querySelector(ele).innerHTML = element.innerHTML;\n var width = table.querySelector(ele).getBoundingClientRect().width;\n document.body.removeChild(htable);\n document.body.removeChild(ctable);\n if ((width > element.getBoundingClientRect().width && !element.classList.contains('e-editedbatchcell')) ||\n (this.enableAdaptiveUI && this.rowRenderingMode === 'Vertical' &&\n width > (element.getBoundingClientRect().width * 0.55) - (this.height !== 'auto' ? 16 : 0))) {\n return true;\n }\n return false;\n };\n Grid.prototype.mouseMoveHandler = function (e) {\n if (this.isEllipsisTooltip()) {\n var element = parentsUntil(e.target, 'e-ellipsistooltip');\n if (this.prevElement !== element || e.type === 'mouseout') {\n this.toolTipObj.close();\n }\n var tagName = e.target.tagName;\n var elemNames = ['A', 'BUTTON', 'INPUT'];\n if (element && e.type !== 'mouseout' && !(Browser.isDevice && elemNames.indexOf(tagName) !== -1)) {\n if (this.getTooltipStatus(element)) {\n var col = this.getColumns()[parseInt(element.getAttribute(literals.dataColIndex), 10)];\n var domSetter = col.disableHtmlEncode ? 'innerText' : 'innerHTML';\n var contentDiv = this.createElement('div');\n if (element.getElementsByClassName('e-headertext').length) {\n var innerElement = element.getElementsByClassName('e-headertext')[0];\n contentDiv[\"\" + domSetter] = this.sanitize(innerElement.innerText);\n this.toolTipObj.content = contentDiv;\n }\n else {\n contentDiv[\"\" + domSetter] = this.sanitize(element.innerText);\n this.toolTipObj.content = contentDiv;\n }\n this.prevElement = element;\n if (this.enableHtmlSanitizer) {\n this.toolTipObj.enableHtmlSanitizer = true;\n }\n if (col.disableHtmlEncode) {\n this.toolTipObj.enableHtmlParse = false;\n }\n this.toolTipObj['open'](element);\n }\n }\n }\n };\n Grid.prototype.isEllipsisTooltip = function () {\n var cols = this.getColumns();\n if (this.clipMode === 'EllipsisWithTooltip') {\n return true;\n }\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].clipMode === 'EllipsisWithTooltip') {\n return true;\n }\n }\n return false;\n };\n Grid.prototype.scrollHandler = function () {\n if (this.isEllipsisTooltip()) {\n this.toolTipObj.close();\n }\n };\n /**\n * To create table for ellipsiswithtooltip\n *\n * @param {Element} table - Defines the table\n * @param {string} tag - Defines the tag\n * @param {string} type - Defines the type\n * @returns {HTMLDivElement} Returns the HTML div ELement\n * @hidden\n */\n Grid.prototype.createTable = function (table, tag, type) {\n var myTableDiv = this.createElement('div');\n myTableDiv.className = this.element.className;\n myTableDiv.style.cssText = 'display: inline-block;visibility:hidden;position:absolute';\n var mySubDiv = this.createElement('div');\n mySubDiv.className = tag;\n var myTable = this.createElement('table');\n myTable.className = table.className;\n myTable.style.cssText = 'table-layout: auto;width: auto';\n var ele = (type === 'header') ? 'th' : 'td';\n var myTr = this.createElement('tr', { attrs: { role: 'row' } });\n var mytd = this.createElement(ele);\n myTr.appendChild(mytd);\n myTable.appendChild(myTr);\n mySubDiv.appendChild(myTable);\n myTableDiv.appendChild(mySubDiv);\n document.body.appendChild(myTableDiv);\n return myTableDiv;\n };\n Grid.prototype.onKeyPressed = function (e) {\n if (e.action === 'tab' || e.action === 'shiftTab') {\n this.toolTipObj.close();\n }\n };\n /**\n * Binding events to the element while component creation.\n *\n * @hidden\n * @returns {void}\n */\n Grid.prototype.wireEvents = function () {\n EventHandler.add(this.element, 'click', this.mouseClickHandler, this);\n EventHandler.add(this.element, 'touchend', this.mouseClickHandler, this);\n EventHandler.add(this.element, 'focusout', this.focusOutHandler, this);\n EventHandler.add(this.element, 'dblclick', this.dblClickHandler, this);\n EventHandler.add(this.element, 'keydown', this.keyPressHandler, this);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n EventHandler.add(window, 'resize', this.resetIndentWidth, this);\n if (this.allowKeyboard) {\n this.element.tabIndex = this.element.tabIndex === -1 ? 0 : this.element.tabIndex;\n }\n this.keyboardModule = new KeyboardEvents(this.element, {\n keyAction: this.keyActionHandler.bind(this),\n keyConfigs: this.keyConfigs,\n eventName: 'keydown'\n });\n EventHandler.add(this.getContent().firstElementChild, 'scroll', this.scrollHandler, this);\n EventHandler.add(this.element, 'mouseover', this.mouseMoveHandler, this);\n EventHandler.add(this.element, 'mouseout', this.mouseMoveHandler, this);\n EventHandler.add(this.getContent(), 'touchstart', this.tapEvent, this);\n EventHandler.add(document.body, 'keydown', this.keyDownHandler, this);\n };\n /**\n * Unbinding events from the element while component destroy.\n *\n * @hidden\n * @returns {void}\n */\n Grid.prototype.unwireEvents = function () {\n EventHandler.remove(this.element, 'click', this.mouseClickHandler);\n EventHandler.remove(this.element, 'touchend', this.mouseClickHandler);\n EventHandler.remove(this.element, 'focusout', this.focusOutHandler);\n EventHandler.remove(this.element, 'dblclick', this.dblClickHandler);\n EventHandler.remove(this.getContent().firstElementChild, 'scroll', this.scrollHandler);\n EventHandler.remove(this.element, 'mouseover', this.mouseMoveHandler);\n EventHandler.remove(this.element, 'mouseout', this.mouseMoveHandler);\n EventHandler.remove(this.element, 'keydown', this.keyPressHandler);\n EventHandler.remove(this.getContent(), 'touchstart', this.tapEvent);\n EventHandler.remove(document.body, 'keydown', this.keyDownHandler);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n EventHandler.remove(window, 'resize', this.resetIndentWidth);\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.addListener = function () {\n if (this.isDestroyed) {\n return;\n }\n this.on(events.dataReady, this.dataReady, this);\n this.on(events.contentReady, this.recalcIndentWidth, this);\n this.on(events.headerRefreshed, this.recalcIndentWidth, this);\n this.on(events.refreshFrozenPosition, this.refreshFrozenPosition, this);\n this.on(events.refreshSplitFrozenColumn, this.refreshSplitFrozenColumn, this);\n this.dataBoundFunction = this.refreshMediaCol.bind(this);\n this.addEventListener(events.dataBound, this.dataBoundFunction);\n this.on(events.keyPressed, this.onKeyPressed, this);\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.removeListener = function () {\n if (this.isDestroyed) {\n return;\n }\n this.off(events.dataReady, this.dataReady);\n this.off(events.contentReady, this.recalcIndentWidth);\n this.off(events.headerRefreshed, this.recalcIndentWidth);\n this.on(events.refreshFrozenPosition, this.refreshFrozenPosition, this);\n this.on(events.refreshSplitFrozenColumn, this.refreshSplitFrozenColumn, this);\n this.removeEventListener(events.dataBound, this.dataBoundFunction);\n this.off(events.keyPressed, this.onKeyPressed);\n };\n /**\n * Get current visible data of grid.\n *\n * @returns {Object[]} Returns the current view records\n *\n * @isGenericType true\n */\n Grid.prototype.getCurrentViewRecords = function () {\n if (isGroupAdaptive(this)) {\n return isNullOrUndefined(this.currentViewData.records) ?\n this.currentViewData : this.currentViewData.records;\n }\n if (this.groupSettings.enableLazyLoading) {\n return this.currentViewData;\n }\n return (this.allowGrouping && this.groupSettings.columns.length && this.currentViewData.length\n && this.currentViewData.records) ? this.currentViewData.records\n : this.currentViewData;\n };\n Grid.prototype.mouseClickHandler = function (e) {\n if (this.isChildGrid(e) || (parentsUntil(e.target, 'e-gridpopup') && e.touches) ||\n this.element.getElementsByClassName('e-cloneproperties').length || this.checkEdit(e)) {\n return;\n }\n if (((!this.allowRowDragAndDrop && (parentsUntil(e.target, literals.gridContent) ||\n e.target.tagName === 'TD')) || (!(this.allowGrouping || this.allowReordering) &&\n parentsUntil(e.target, 'e-gridheader'))) && e.touches) {\n return;\n }\n if (parentsUntil(e.target, 'e-gridheader') && this.allowRowDragAndDrop &&\n !(parentsUntil(e.target, 'e-filterbarcell')) && (e.target &&\n ['A', 'BUTTON', 'INPUT'].indexOf(e.target.tagName) === -1)) {\n e.preventDefault();\n }\n var args = this.getRowInfo(e.target);\n var cancel = 'cancel';\n args[\"\" + cancel] = false;\n var isDataRow = false;\n var tr = closest(e.target, 'tr');\n if (tr && tr.getAttribute('data-uid')) {\n var rowObj = this.getRowObjectFromUID(tr.getAttribute('data-uid'));\n isDataRow = rowObj ? rowObj.isDataRow : false;\n }\n if (isDataRow) {\n this.trigger(events.recordClick, args);\n }\n this.notify(events.click, e);\n };\n Grid.prototype.checkEdit = function (e) {\n var tr = parentsUntil(e.target, literals.row);\n var isEdit = this.editSettings.mode !== 'Batch' &&\n this.isEdit && tr && (tr.classList.contains(literals.editedRow) || tr.classList.contains(literals.addedRow));\n return !parentsUntil(e.target, 'e-unboundcelldiv') && (isEdit || (parentsUntil(e.target, literals.rowCell) &&\n parentsUntil(e.target, literals.rowCell).classList.contains('e-editedbatchcell')));\n };\n Grid.prototype.dblClickHandler = function (e) {\n var grid = parentsUntil(e.target, 'e-grid');\n if (isNullOrUndefined(grid) || grid.id !== this.element.id || closest(e.target, '.e-unboundcelldiv')) {\n return;\n }\n var dataRow = false;\n var tr = closest(e.target, 'tr');\n if (tr && tr.getAttribute('data-uid')) {\n var rowObj = this.getRowObjectFromUID(tr.getAttribute('data-uid'));\n dataRow = rowObj ? rowObj.isDataRow : false;\n }\n var args = this.getRowInfo(e.target);\n args.target = e.target;\n if (dataRow) {\n this.trigger(events.recordDoubleClick, args);\n }\n this.notify(events.dblclick, e);\n };\n Grid.prototype.focusOutHandler = function (e) {\n if (this.isChildGrid(e)) {\n return;\n }\n if (!parentsUntil(e.target, 'e-grid')) {\n this.element.querySelector('.e-gridpopup').style.display = 'None';\n }\n var filterClear = this.element.querySelector('.e-cancel:not(.e-hide)');\n if (filterClear && !filterClear.parentElement.classList.contains('e-tbar-btn')) {\n filterClear.classList.add('e-hide');\n }\n var relatedTarget = e.relatedTarget;\n var ariaOwns = relatedTarget ? relatedTarget.getAttribute('aria-owns') : null;\n if ((!relatedTarget || (!parentsUntil(relatedTarget, 'e-grid') &&\n (!isNullOrUndefined(ariaOwns) &&\n (ariaOwns)) !== e.target.getAttribute('aria-owns')))\n && !this.keyPress && this.isEdit && !Browser.isDevice) {\n if (this.editSettings.mode === 'Batch' && !(((parentsUntil(relatedTarget, 'e-ddl') || parentsUntil(relatedTarget, 'e-ddt')) &&\n parentsUntil(relatedTarget, 'e-multi-select-list-wrapper')) && parentsUntil(relatedTarget, 'e-input-group'))\n && (parentsUntil(relatedTarget, 'e-uploader') || !(relatedTarget &&\n isNullOrUndefined(parentsUntil(relatedTarget, 'e-input-group'))))) {\n this.editModule.saveCell();\n this.notify(events.editNextValCell, {});\n }\n if (this.editSettings.mode === 'Normal') {\n this.editModule.editFormValidate();\n }\n }\n this.keyPress = false;\n };\n Grid.prototype.isChildGrid = function (e) {\n var gridElement = parentsUntil(e.target, 'e-grid');\n if ((gridElement && gridElement.id !== this.element.id) || (parentsUntil(e.target, 'e-unboundcelldiv') &&\n isNullOrUndefined(gridElement))) {\n return true;\n }\n return false;\n };\n /**\n * @param {Object} persistedData - Defines the persisted data\n * @returns {void}\n * @hidden\n */\n Grid.prototype.mergePersistGridData = function (persistedData) {\n var data = this.getLocalData();\n if (!(isNullOrUndefined(data) || (data === '')) || !isNullOrUndefined(persistedData)) {\n var dataObj = !isNullOrUndefined(persistedData) ? persistedData : JSON.parse(data);\n if (this.enableVirtualization && dataObj.pageSettings) {\n dataObj.pageSettings.currentPage = 1;\n }\n var keys = Object.keys(dataObj);\n this.isProtectedOnChange = true;\n for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) {\n var key = keys_1[_i];\n if ((typeof this[\"\" + key] === 'object') && !isNullOrUndefined(this[\"\" + key])) {\n if (Array.isArray(this[\"\" + key]) && key === 'columns') {\n this.setFrozenCount();\n setColumnIndex(this[\"\" + key]);\n this.mergeColumns(dataObj[\"\" + key], this[\"\" + key]);\n this.mergedColumns = true;\n this[\"\" + key] = dataObj[\"\" + key];\n }\n else {\n extend(this[\"\" + key], dataObj[\"\" + key]);\n }\n }\n else {\n this[\"\" + key] = dataObj[\"\" + key];\n }\n }\n this.isProtectedOnChange = false;\n }\n };\n Grid.prototype.mergeColumns = function (storedColumn, columns) {\n var storedColumns = storedColumn;\n var isFrozenGrid = this.isFrozenGrid();\n var _loop_4 = function (i) {\n var localCol = columns.filter(function (tCol) { return isFrozenGrid ?\n tCol.index === storedColumns[parseInt(i.toString(), 10)][\"\" + literals.initialFrozenColumnIndex] :\n tCol.index === storedColumns[parseInt(i.toString(), 10)].index; })[0];\n if (!isNullOrUndefined(localCol)) {\n if (isFrozenGrid) {\n localCol = extend({}, localCol, {}, true);\n localCol.freeze = storedColumns[parseInt(i.toString(), 10)].freeze;\n }\n if (localCol.columns && localCol.columns.length) {\n this_4.mergeColumns(storedColumns[parseInt(i.toString(), 10)].columns, localCol.columns);\n storedColumns[parseInt(i.toString(), 10)] = extend(localCol, storedColumns[parseInt(i.toString(), 10)], {}, true);\n }\n else {\n storedColumns[parseInt(i.toString(), 10)] = extend(localCol, storedColumns[parseInt(i.toString(), 10)], {}, true);\n }\n }\n };\n var this_4 = this;\n for (var i = 0; i < storedColumns.length; i++) {\n _loop_4(i);\n }\n };\n /**\n * @hidden\n * @returns {boolean} Returns the isDetail\n */\n Grid.prototype.isDetail = function () {\n return !isNullOrUndefined(this.detailTemplate) || !isNullOrUndefined(this.childGrid);\n };\n Grid.prototype.isCommandColumn = function (columns) {\n var _this_1 = this;\n return columns.some(function (col) {\n if (col.columns) {\n return _this_1.isCommandColumn(col.columns);\n }\n return !!(col.commands || col.commandsTemplate);\n });\n };\n Grid.prototype.isForeignKeyEnabled = function (columns) {\n var _this_1 = this;\n return columns.some(function (col) {\n if (col.columns) {\n return _this_1.isForeignKeyEnabled(col.columns);\n }\n return !!(col.dataSource && col.foreignKeyValue);\n });\n };\n Grid.prototype.keyPressHandler = function (e) {\n var presskey = extend(e, { cancel: false });\n this.trigger('keyPressed', presskey);\n if (presskey.cancel === true) {\n e.stopImmediatePropagation();\n }\n };\n Grid.prototype.keyDownHandler = function (e) {\n if (e.altKey) {\n if (e.keyCode === 74) { //alt j\n if (this.keyA) { //alt A J\n this.notify(events.groupCollapse, { target: e.target, collapse: false });\n this.keyA = false;\n }\n else {\n if (this.focusModule && this.focusModule.currentInfo && this.focusModule.currentInfo.element) {\n removeClass([this.focusModule.currentInfo.element, this.focusModule.currentInfo.elementToFocus], ['e-focused', 'e-focus']);\n this.focusModule.currentInfo.element.tabIndex = -1;\n }\n if (!this.element.classList.contains('e-childgrid')) {\n this.element.focus();\n }\n }\n }\n if (e.keyCode === 87) { //alt w\n var focusModule = this.focusModule;\n if (focusModule) {\n if (!this.currentViewData.length) {\n return;\n }\n focusModule.focusContent();\n focusModule.addOutline();\n }\n }\n if (e.keyCode === 65) { //alt A\n this.keyA = true;\n }\n if (e.keyCode === 72 && this.keyA) { //alt A H\n this.notify(events.groupCollapse, { target: e.target, collapse: true });\n this.keyA = false;\n }\n }\n if (e.keyCode === 13) {\n this.notify(events.enterKeyHandler, e);\n }\n };\n Grid.prototype.keyActionHandler = function (e) {\n if (this.isChildGrid(e) ||\n (this.isEdit && e.action !== 'escape' && e.action !== 'enter' && e.action !== 'shiftEnter'\n && e.action !== 'tab' && e.action !== 'shiftTab')) {\n return;\n }\n else {\n this.keyPress = true;\n }\n if (this.allowKeyboard) {\n if (e.action === 'ctrlPlusP') {\n e.preventDefault();\n this.print();\n }\n this.notify(events.keyPressed, e);\n }\n };\n /**\n * @param {Function[]} modules - Defines the modules\n * @returns {void}\n * @hidden\n */\n Grid.prototype.setInjectedModules = function (modules) {\n this.injectedModules = modules;\n };\n Grid.prototype.updateColumnObject = function () {\n prepareColumns(this.columns, this.enableColumnVirtualization, this);\n setColumnIndex(this.columns);\n this.initForeignColumn();\n this.notify(events.autoCol, {});\n };\n Grid.prototype.refreshFrozenPosition = function (obj) {\n if (obj && obj.isModeChg) {\n this.refreshColumns();\n this.notify(events.refreshResizePosition, {});\n }\n else {\n this.refreshColumns();\n }\n };\n /**\n * Gets the foreign columns from Grid.\n *\n * @returns {Column[]} Returns Foreign key column\n */\n Grid.prototype.getForeignKeyColumns = function () {\n return this.getColumns().filter(function (col) {\n return col.isForeignColumn();\n });\n };\n /**\n * @hidden\n * @returns {number} Returns row height\n */\n Grid.prototype.getRowHeight = function () {\n return this.rowHeight ? this.rowHeight : getRowHeight(this.element);\n };\n /**\n * Refreshes the Grid column changes.\n *\n * @returns {void}\n */\n Grid.prototype.refreshColumns = function () {\n this.freezeColumnRefresh = true;\n this.setFrozenCount();\n this.updateFrozenColumnsWidth();\n if (this.isFrozenGrid()) {\n this.isPreventScrollEvent = true;\n }\n this.updateColumnObject();\n this.checkLockColumns(this.getColumns());\n this.refresh();\n if (this.isFrozenGrid() && this.enableColumnVirtualization) {\n var left = this.getContent().querySelector('.e-movablescrollbar').scrollLeft;\n this.getHeaderContent().querySelector('.' + literals.headerContent).scrollLeft = left;\n this.getContent().querySelector('.' + literals.content).scrollLeft = left;\n }\n };\n /**\n * Export Grid data to Excel file(.xlsx).\n *\n * @param {ExcelExportProperties} excelExportProperties - Defines the export properties of the Grid.\n * @param {boolean} isMultipleExport - Define to enable multiple export.\n * @param {Workbook} workbook - Defines the Workbook if multiple export is enabled.\n * @param {boolean} isBlob - If 'isBlob' set to true, then it will be returned as blob data.\n * @returns {Promise<any>} Returns the excelexport\n */\n Grid.prototype.excelExport = function (excelExportProperties, isMultipleExport, \n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n workbook, isBlob) {\n if (this.exportGrids && this.exportGrids.length) {\n var gridIds = this.exportGrids.slice();\n return this.exportMultipleExcelGrids(gridIds, excelExportProperties, isMultipleExport, workbook, isBlob);\n }\n else {\n return this.excelExportModule ?\n this.excelExportModule.Map(this, excelExportProperties, isMultipleExport, workbook, false, isBlob) : null;\n }\n };\n /**\n * Export Grid data to CSV file.\n *\n * @param {ExcelExportProperties} excelExportProperties - Defines the export properties of the Grid.\n * @param {boolean} isMultipleExport - Define to enable multiple export.\n * @param {Workbook} workbook - Defines the Workbook if multiple export is enabled.\n * @param {boolean} isBlob - If 'isBlob' set to true, then it will be returned as blob data.\n * @returns {Promise<any>} Returns csv export\n */\n Grid.prototype.csvExport = function (excelExportProperties, \n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n isMultipleExport, workbook, isBlob) {\n return this.excelExportModule ?\n this.excelExportModule.Map(this, excelExportProperties, isMultipleExport, workbook, true, isBlob) : null;\n };\n /**\n * Export Grid data to PDF document.\n *\n * @param {pdfExportProperties} pdfExportProperties - Defines the export properties of the Grid.\n * @param {isMultipleExport} isMultipleExport - Define to enable multiple export.\n * @param {pdfDoc} pdfDoc - Defined the Pdf Document if multiple export is enabled.\n * @param {boolean} isBlob - If 'isBlob' set to true, then it will be returned as blob data.\n *\n * @returns {Promise<any>} Returns pdfexport\n */\n Grid.prototype.pdfExport = function (pdfExportProperties, isMultipleExport, pdfDoc, isBlob) {\n if (this.exportGrids && this.exportGrids.length) {\n var gridIds = this.exportGrids.slice();\n return this.exportMultiplePdfGrids(gridIds, pdfExportProperties, isMultipleExport, pdfDoc, isBlob);\n }\n else {\n return this.pdfExportModule ? this.pdfExportModule.Map(this, pdfExportProperties, isMultipleExport, pdfDoc, isBlob) : null;\n }\n };\n Grid.prototype.exportMultiplePdfGrids = function (gridIds, pdfExportProperties, isMultipleExport, \n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n pdfDoc, isBlob) {\n var _this = this;\n if (gridIds.length !== 0) {\n var currentGridId = gridIds.shift();\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var currentGridInstance = document.getElementById(currentGridId).ej2_instances[0];\n var exportPromise = currentGridInstance.pdfExportModule ?\n currentGridInstance.pdfExportModule.Map(currentGridInstance, pdfExportProperties, isMultipleExport, pdfDoc, isBlob)\n : Promise.resolve();\n return exportPromise.then(function (exportedGridResults) {\n isMultipleExport = gridIds.length === 1 ? false : true;\n return _this.exportMultiplePdfGrids(gridIds, pdfExportProperties, isMultipleExport, exportedGridResults, isBlob);\n });\n }\n return null;\n };\n Grid.prototype.exportMultipleExcelGrids = function (gridIds, excelExportProperties, isMultipleExport, \n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n workbook, isBlob) {\n var _this = this;\n if (gridIds.length !== 0) {\n var currentGridId = gridIds.shift();\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var currentGridInstance = document.getElementById(currentGridId).ej2_instances[0];\n var exportPromise = currentGridInstance.excelExportModule ?\n currentGridInstance.excelExportModule.Map(currentGridInstance, excelExportProperties, isMultipleExport, workbook, false, isBlob) : null;\n return exportPromise.then(function (exportedGridResults) {\n isMultipleExport = gridIds.length === 1 ? false : true;\n return _this.exportMultipleExcelGrids(gridIds, excelExportProperties, isMultipleExport, exportedGridResults, isBlob);\n });\n }\n return null;\n };\n /**\n * Groups a column by column name.\n *\n * @param {string} columnName - Defines the column name to group.\n *\n * @returns {void}\n */\n Grid.prototype.groupColumn = function (columnName) {\n if (this.groupModule) {\n this.groupModule.groupColumn(columnName);\n }\n };\n /**\n * Expands all the grouped rows of the Grid.\n *\n * @returns {void}\n */\n Grid.prototype.groupExpandAll = function () {\n if (this.groupModule) {\n this.groupModule.expandAll();\n }\n };\n /**\n * Collapses all the grouped rows of the Grid.\n *\n * @returns {void}\n */\n Grid.prototype.groupCollapseAll = function () {\n if (this.groupModule) {\n this.groupModule.collapseAll();\n }\n };\n /**\n * Expands or collapses grouped rows by target element.\n *\n * @param {Element} target - Defines the target element of the grouped row.\n * @returns {void}\n */\n // public expandCollapseRows(target: Element): void {\n // if (this.groupModule) {\n // this.groupModule.expandCollapseRows(target);\n // }\n // }\n /**\n * Clears all the grouped columns of the Grid.\n *\n * @returns {void}\n */\n Grid.prototype.clearGrouping = function () {\n if (this.groupModule) {\n this.groupModule.clearGrouping();\n }\n };\n /**\n * Ungroups a column by column name.\n *\n * {% codeBlock src='grid/ungroupColumn/index.md' %}{% endcodeBlock %}\n *\n * @param {string} columnName - Defines the column name to ungroup.\n *\n * @returns {void}\n */\n Grid.prototype.ungroupColumn = function (columnName) {\n if (this.groupModule) {\n this.groupModule.ungroupColumn(columnName);\n }\n };\n /**\n * Column chooser can be displayed on screen by given position(X and Y axis).\n *\n * @param {number} x - Defines the X axis.\n * @param {number} y - Defines the Y axis.\n *\n * @returns {void}\n */\n Grid.prototype.openColumnChooser = function (x, y) {\n if (this.columnChooserModule) {\n this.columnChooserModule.openColumnChooser(x, y);\n }\n };\n Grid.prototype.scrollRefresh = function () {\n var _this_1 = this;\n var refresh = function () {\n _this_1.scrollModule.refresh();\n _this_1.off(events.contentReady, refresh);\n };\n this.on(events.contentReady, refresh, this);\n };\n /**\n * Collapses a detail row with the given target.\n *\n * @param {Element} target - Defines the expanded element to collapse.\n * @returns {void}\n */\n // public detailCollapse(target: number | Element): void {\n // if (this.detailRowModule) {\n // this.detailRowModule.collapse(target);\n // }\n // }\n /**\n * Collapses all the detail rows of the Grid.\n *\n * @returns {void}\n */\n Grid.prototype.detailCollapseAll = function () {\n if (this.detailRowModule) {\n this.detailRowModule.collapseAll();\n }\n };\n /**\n * Expands a detail row with the given target.\n *\n * @param {Element} target - Defines the collapsed element to expand.\n * @returns {void}\n */\n // public detailExpand(target: number | Element): void {\n // if (this.detailRowModule) {\n // this.detailRowModule.expand(target);\n // }\n // }\n /**\n * Expands all the detail rows of the Grid.\n *\n * @returns {void}\n */\n Grid.prototype.detailExpandAll = function () {\n if (this.detailRowModule) {\n this.detailRowModule.expandAll();\n }\n };\n /**\n * Deselects the currently selected cells.\n *\n * @returns {void}\n */\n Grid.prototype.clearCellSelection = function () {\n if (this.selectionModule) {\n this.selectionModule.clearCellSelection();\n }\n };\n /**\n * Deselects the currently selected rows.\n *\n * @returns {void}\n */\n Grid.prototype.clearRowSelection = function () {\n if (this.selectionModule) {\n this.selectionModule.clearRowSelection();\n }\n };\n /**\n * Selects a collection of cells by row and column indexes.\n *\n * @param {ISelectedCell[]} rowCellIndexes - Specifies the row and column indexes.\n *\n * @returns {void}\n */\n Grid.prototype.selectCells = function (rowCellIndexes) {\n if (this.selectionModule) {\n this.selectionModule.selectCells(rowCellIndexes);\n }\n };\n /**\n * Selects a range of rows from start and end row indexes.\n *\n * @param {number} startIndex - Specifies the start row index.\n * @param {number} endIndex - Specifies the end row index.\n *\n * @returns {void}\n */\n Grid.prototype.selectRowsByRange = function (startIndex, endIndex) {\n if (this.selectionModule) {\n this.selectionModule.selectRowsByRange(startIndex, endIndex);\n }\n };\n /**\n * @hidden\n * @returns {boolean} Returns whether context menu is open or not\n */\n Grid.prototype.isContextMenuOpen = function () {\n return this.contextMenuModule && this.contextMenuModule.isOpen;\n };\n /**\n * @param {Function} module - Defines the module\n * @returns {boolean} return the injected modules\n * @hidden\n */\n Grid.prototype.ensureModuleInjected = function (module) {\n return this.getInjectedModules().indexOf(module) >= 0;\n };\n /**\n * Destroys the given template reference.\n *\n * @param {string[]} propertyNames - Defines the collection of template name.\n * @param {any} index - specifies the index\n *\n * @returns {void}\n */\n // eslint-disable-next-line\n Grid.prototype.destroyTemplate = function (propertyNames, index) {\n this.clearTemplate(propertyNames, index);\n };\n /**\n * @param {string | string[]} type - Defines the type\n * @param {Object} args - Defines the arguments\n * @returns {void}\n * @hidden\n * @private\n */\n Grid.prototype.log = function (type, args) {\n // eslint-disable-next-line\n this.loggerModule ? this.loggerModule.log(type, args) : (function () { return 0; })();\n };\n /**\n * @param {Element} element - Defines the element\n * @returns {void}\n * @hidden\n */\n Grid.prototype.applyBiggerTheme = function (element) {\n if (this.element.classList.contains('e-bigger')) {\n element.classList.add('e-bigger');\n }\n };\n /**\n * @hidden\n * @returns {Object} Returns the previous row data\n */\n Grid.prototype.getPreviousRowData = function () {\n var previousRowData = this.getRowsObject()[this.getRows().length - 1].data;\n return previousRowData;\n };\n /**\n * Hides the scrollbar placeholder of Grid content when grid content is not overflown.\n *\n * @returns {void}\n */\n Grid.prototype.hideScroll = function () {\n var content = this.getContent().querySelector('.' + literals.content);\n if (content.scrollHeight <= content.clientHeight) {\n this.scrollModule.removePadding();\n content.style.overflowY = 'auto';\n }\n };\n /**\n * Get row index by primary key or row data.\n *\n * @param {string | Object} value - Defines the primary key value.\n *\n * @returns {number} Returns the index\n */\n Grid.prototype.getRowIndexByPrimaryKey = function (value) {\n var pkName = this.getPrimaryKeyFieldNames()[0];\n value = typeof value === 'object' ? value[\"\" + pkName] : value;\n var rows = this.getRowsObject();\n for (var i = 0; i < rows.length; i++) {\n if (rows[parseInt(i.toString(), 10)].isDetailRow || rows[parseInt(i.toString(), 10)].isCaptionRow) {\n continue;\n }\n var pKvalue = rows[parseInt(i.toString(), 10)].data[\"\" + pkName];\n if (pkName.split('.').length > 1) {\n pKvalue = performComplexDataOperation(pkName, rows[parseInt(i.toString(), 10)].data);\n }\n if (pKvalue === value) {\n return rows[parseInt(i.toString(), 10)].index;\n }\n }\n return -1;\n };\n /**\n * @param {string} field - Defines the field name\n * @returns {Column} returns the column\n * @hidden\n */\n // Need to have all columns while filtering with ColumnVirtualization.\n Grid.prototype.grabColumnByFieldFromAllCols = function (field, isForeignKey) {\n var column;\n this.columnModel = [];\n this.updateColumnModel(this.columns);\n var gCols = this.columnModel;\n for (var i = 0; i < gCols.length; i++) {\n if ((!isForeignKey && field === gCols[parseInt(i.toString(), 10)].field) ||\n (isForeignKey && gCols[parseInt(i.toString(), 10)].isForeignColumn() &&\n field === gCols[parseInt(i.toString(), 10)].foreignKeyValue)) {\n column = gCols[parseInt(i.toString(), 10)];\n break;\n }\n }\n return column;\n };\n /**\n * @param {string} uid - Defines the uid\n * @returns {Column} returns the column\n * @hidden\n */\n // Need to have all columns while filtering with ColumnVirtualization.\n Grid.prototype.grabColumnByUidFromAllCols = function (uid) {\n var column;\n this.columnModel = [];\n this.updateColumnModel(this.columns);\n var gCols = this.columnModel;\n for (var i = 0; i < gCols.length; i++) {\n if (uid === gCols[parseInt(i.toString(), 10)].uid) {\n column = gCols[parseInt(i.toString(), 10)];\n }\n }\n return column;\n };\n /**\n * Get all filtered records from the Grid and it returns array of objects for the local dataSource, returns a promise object if the Grid has remote data.\n *\n * @returns {Object[] | Promise<Object>} Returns the filtered records\n */\n Grid.prototype.getFilteredRecords = function () {\n if ((this.allowFiltering && this.filterSettings.columns.length) || this.searchSettings.key.length) {\n var query = this.renderModule.data.generateQuery(true);\n if (this.dataSource && this.renderModule.data.isRemote() && this.dataSource instanceof DataManager) {\n return this.renderModule.data.getData(this.dataSource, query);\n }\n else {\n if (this.dataSource instanceof DataManager) {\n return this.dataSource.executeLocal(query);\n }\n else {\n return new DataManager(this.dataSource, query).executeLocal(query);\n }\n }\n }\n return [];\n };\n Grid.prototype.getUserAgent = function () {\n var userAgent = Browser.userAgent.toLowerCase();\n return /iphone|ipod|ipad|macintosh/.test(userAgent);\n };\n /**\n * @param {TouchEventArgs} e - Defines the TouchEventArgs\n * @returns {void}\n * @hidden\n */\n // Need to have all columns while filtering with ColumnVirtualization.\n // eslint-disable-next-line\n Grid.prototype.tapEvent = function (e) {\n if (this.getUserAgent()) {\n if (!Global.timer) {\n Global.timer = setTimeout(function () {\n Global.timer = null;\n }, 300);\n }\n else {\n clearTimeout(Global.timer);\n Global.timer = null;\n this.dblClickHandler(e);\n this.notify(events.doubleTap, e);\n }\n }\n };\n /**\n * @param {string} prefix - specifies the prefix\n * @returns {string} returns the row uid\n * @hidden\n */\n Grid.prototype.getRowUid = function (prefix) {\n return \"\" + prefix + this.rowUid++;\n };\n /**\n * @param {string} uid - specifies the uid\n * @returns {Element} returns the element\n * @hidden\n */\n Grid.prototype.getRowElementByUID = function (uid) {\n var rowEle;\n var rows = [];\n var cntRows = [].slice.call(this.getContent().querySelector(literals.tbody).children);\n if (this.frozenRows) {\n rows = [].slice.call(this.getHeaderContent().querySelector(literals.tbody).children);\n rows = rows.concat(cntRows);\n }\n else {\n rows = cntRows;\n }\n for (var _i = 0, rows_2 = rows; _i < rows_2.length; _i++) {\n var row = rows_2[_i];\n if (row.getAttribute('data-uid') === uid) {\n rowEle = row;\n break;\n }\n }\n return rowEle;\n };\n /**\n * Gets the hidden columns from the Grid.\n *\n * @returns {Column[]} Returns the Column\n */\n Grid.prototype.getHiddenColumns = function () {\n var cols = [];\n for (var _i = 0, _a = this.columnModel; _i < _a.length; _i++) {\n var col = _a[_i];\n if (col.visible === false) {\n cols.push(col);\n }\n }\n return cols;\n };\n /**\n * Calculates the page size by parent element height\n *\n * @param {number | string } containerHeight - specifies the container height\n * @returns {number} returns the page size\n */\n Grid.prototype.calculatePageSizeByParentHeight = function (containerHeight) {\n if (this.allowPaging) {\n if ((this.allowTextWrap && this.textWrapSettings.wrapMode === 'Header') || (!this.allowTextWrap)) {\n var pagesize = 0;\n if (containerHeight.indexOf('%') !== -1) {\n containerHeight = parseInt(containerHeight, 10) / 100 * this.element.clientHeight;\n }\n var nonContentHeight = this.getNoncontentHeight() + this.getRowHeight();\n if (containerHeight > nonContentHeight) {\n var contentHeight = 0;\n contentHeight = containerHeight - this.getNoncontentHeight();\n pagesize = (contentHeight / this.getRowHeight());\n }\n if (pagesize > 0) {\n return Math.floor(pagesize);\n }\n }\n }\n return 0;\n };\n Grid.prototype.getNoncontentHeight = function () {\n var height = 0;\n if (!isNullOrUndefined(this.getHeaderContent().clientHeight)) {\n height += this.getHeaderContent().clientHeight;\n }\n if (this.toolbar && !isNullOrUndefined(this.element.querySelector('.e-toolbar').clientHeight)) {\n height += this.element.querySelector('.e-toolbar').clientHeight;\n }\n if (this.allowPaging && !isNullOrUndefined(this.element.querySelector('.e-gridpager').clientHeight)) {\n height += this.element.querySelector('.e-gridpager').clientHeight;\n }\n if (this.showColumnChooser && !isNullOrUndefined(this.element.querySelector('.e-columnheader').clientHeight)) {\n height += this.element.querySelector('.e-columnheader').clientHeight;\n }\n if (this.allowGrouping && this.groupSettings.showDropArea && !isNullOrUndefined(this.element.querySelector('.e-groupdroparea').clientHeight)) {\n height += this.element.querySelector('.e-groupdroparea').clientHeight;\n }\n if (this.aggregates.length > 0 && !isNullOrUndefined(this.element.querySelector('.e-summaryrow').clientHeight)) {\n for (var i = 0; i < this.element.getElementsByClassName('e-summaryrow').length; i++) {\n height += this.element.getElementsByClassName('e-summaryrow')[parseInt(i.toString(), 10)].clientHeight;\n }\n }\n return height;\n };\n /**\n *To perform aggregate operation on a column.\n *\n * @param {AggregateColumnModel} summaryCol - Pass Aggregate Column details.\n * @param {Object} summaryData - Pass JSON Array for which its field values to be calculated.\n *\n * @returns {number} returns the summary values\n */\n Grid.prototype.getSummaryValues = function (summaryCol, summaryData) {\n return DataUtil.aggregates[summaryCol.type.toLowerCase()](summaryData, summaryCol.field);\n };\n /**\n * Sends a Post request to export Grid to Excel file in server side.\n *\n * @param {string} url - Pass Url for server side excel export action.\n *\n * @returns {void}\n */\n Grid.prototype.serverExcelExport = function (url) {\n this.isExcel = true;\n this.exportGrid(url);\n };\n /**\n * Sends a Post request to export Grid to Pdf file in server side.\n *\n * @param {string} url - Pass Url for server side pdf export action.\n *\n * @returns {void}\n */\n Grid.prototype.serverPdfExport = function (url) {\n this.isExcel = false;\n this.exportGrid(url);\n };\n /**\n * Sends a Post request to export Grid to CSV file in server side.\n *\n * @param {string} url - Pass Url for server side pdf export action.\n *\n * @returns {void}\n */\n Grid.prototype.serverCsvExport = function (url) {\n this.isExcel = true;\n this.exportGrid(url);\n };\n /**\n * @param {string} url - Defines exporting url\n * @returns {void}\n * @hidden\n */\n Grid.prototype.exportGrid = function (url) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var grid = this;\n var query = grid.getDataModule().generateQuery(true);\n var state = new UrlAdaptor().processQuery(new DataManager({ url: '' }), query);\n var queries = JSON.parse(state.data);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var gridModel = JSON.parse(this.addOnPersist(['allowGrouping', 'allowPaging', 'pageSettings', 'sortSettings', 'allowPdfExport', 'allowExcelExport', 'aggregates',\n 'filterSettings', 'groupSettings', 'columns', 'locale', 'searchSettings']));\n var include = ['field', 'headerText', 'type', 'format', 'visible', 'foreignKeyValue', 'foreignKeyField',\n 'template', 'index', 'width', 'textAlign', 'headerTextAlign', 'columns'];\n gridModel.filterSettings.columns = queries.where;\n gridModel.searchSettings.fields = queries.search && queries.search[0]['fields'] || [];\n gridModel.sortSettings.columns = queries.sorted;\n gridModel.columns = this.setHeaderText(gridModel.columns, include);\n var form = this.createElement('form', { id: 'ExportForm', styles: 'display:none;' });\n var gridInput = this.createElement('input', { id: 'gridInput', attrs: { name: 'gridModel' } });\n gridInput.value = JSON.stringify(gridModel);\n form.method = 'POST';\n form.action = url;\n form.appendChild(gridInput);\n document.body.appendChild(form);\n form.submit();\n form.remove();\n };\n /**\n * @param {Column[]} columns - Defines array of columns\n * @param {string[]} include - Defines array of sting\n * @returns {Column[]} returns array of columns\n * @hidden\n */\n Grid.prototype.setHeaderText = function (columns, include) {\n for (var i = 0; i < columns.length; i++) {\n var column = this.getColumnByUid(columns[parseInt(i.toString(), 10)].uid);\n columns[parseInt(i.toString(), 10)].headerText = column.headerText;\n if (!isNullOrUndefined(column.template)) {\n columns[parseInt(i.toString(), 10)].template = 'true';\n }\n if (columns[parseInt(i.toString(), 10)].format) {\n columns[parseInt(i.toString(), 10)].format = getNumberFormat(this.getFormat(columns[parseInt(i.toString(), 10)].format), columns[parseInt(i.toString(), 10)].type, this.isExcel, defaultCurrencyCode);\n }\n if (columns[parseInt(i.toString(), 10)].columns) {\n this.setHeaderText(columns[parseInt(i.toString(), 10)].columns, include);\n }\n var keys = Object.keys(columns[parseInt(i.toString(), 10)]);\n for (var j = 0; j < keys.length; j++) {\n if (include.indexOf(keys[parseInt(j.toString(), 10)]) < 0) {\n delete columns[parseInt(i.toString(), 10)][keys[parseInt(j.toString(), 10)]];\n }\n }\n }\n return columns;\n };\n Grid.prototype.getFormat = function (format) {\n return typeof (format) === 'object' ? !isNullOrUndefined(format.format) ?\n format.format : format.skeleton : format;\n };\n /**\n * @hidden\n * @returns {boolean} returns the isCollapseStateEnabled\n */\n Grid.prototype.isCollapseStateEnabled = function () {\n var isExpanded = 'isExpanded';\n return this[\"\" + isExpanded] === false;\n };\n /**\n * @param {number} key - Defines the primary key value.\n * @param {Object} rowData - Defines the rowData\n * @returns {void}\n */\n Grid.prototype.updateRowValue = function (key, rowData) {\n var args = {\n requestType: 'save', data: rowData\n };\n this.showSpinner();\n this.notify(events.updateData, args);\n this.refresh();\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.setForeignKeyData = function () {\n this.dataBind();\n var colpending = this.getDataModule().getForeignKeyDataState();\n if (colpending.isPending) {\n this.getDataModule().setForeignKeyDataState({});\n colpending.resolver();\n }\n else {\n this.getDataModule().setForeignKeyDataState({ isDataChanged: false });\n if (this.contentModule || this.headerModule) {\n this.renderModule.render();\n }\n }\n };\n /**\n * @param {string} field - specifies the field\n * @returns {void}\n * @hidden\n */\n Grid.prototype.resetFilterDlgPosition = function (field) {\n var header = this.getColumnHeaderByField(field);\n if (header) {\n var target = header.querySelector('.e-filtermenudiv');\n var filterDlg = this.element.querySelector('.e-filter-popup');\n if (target && filterDlg) {\n var gClient = this.element.getBoundingClientRect();\n var fClient = target.getBoundingClientRect();\n if (filterDlg) {\n if ((filterDlg.offsetWidth + fClient.right) > gClient.right) {\n filterDlg.style.left = ((fClient.right - filterDlg.offsetWidth) - gClient.left).toString() + 'px';\n }\n else {\n filterDlg.style.left = (fClient.right - gClient.left).toString() + 'px';\n }\n }\n }\n }\n };\n /**\n * @param {any} callBack - specifies the callBack method\n * @returns {void}\n * @hidden\n */\n // eslint-disable-next-line\n Grid.prototype.renderTemplates = function (callBack) {\n var isReactChild = this.parentDetails && this.parentDetails.parentInstObj && this.parentDetails.parentInstObj.isReact;\n if (isReactChild && this['portals']) {\n this.parentDetails.parentInstObj['portals'] = this.parentDetails.parentInstObj['portals']\n .concat(this['portals']);\n this.parentDetails.parentInstObj.renderTemplates(callBack);\n this['portals'] = undefined;\n }\n else {\n var portals = 'portals';\n this.notify('reactTemplateRender', this[\"\" + portals]);\n this.renderReactTemplates(callBack);\n }\n };\n /**\n * Apply the changes to the Grid without refreshing the rows.\n *\n * @param {BatchChanges} changes - Defines changes to be updated.\n * @returns {void}\n */\n Grid.prototype.batchUpdate = function (changes) {\n this.processRowChanges(changes);\n };\n /**\n * Apply the changes to the Grid in one batch after 50ms without refreshing the rows.\n *\n * @param {BatchChanges} changes - Defines changes to be updated.\n * @returns {void}\n */\n Grid.prototype.batchAsyncUpdate = function (changes) {\n this.processBulkRowChanges(changes);\n };\n Grid.prototype.processBulkRowChanges = function (changes) {\n var _this_1 = this;\n if (!this.dataToBeUpdated) {\n this.dataToBeUpdated = Object.assign({ addedRecords: [], changedRecords: [], deletedRecords: [] }, changes);\n setTimeout(function () {\n _this_1.processRowChanges(_this_1.dataToBeUpdated);\n _this_1.dataToBeUpdated = null;\n }, this.asyncTimeOut);\n }\n else {\n var loopstring = [literals.addedRecords, literals.changedRecords, literals.deletedRecords];\n var keyField = this.getPrimaryKeyFieldNames()[0];\n for (var i = 0; i < loopstring.length; i++) {\n if (changes[loopstring[parseInt(i.toString(), 10)]]) {\n compareChanges(this, changes, loopstring[parseInt(i.toString(), 10)], keyField);\n }\n }\n }\n };\n Grid.prototype.processRowChanges = function (changes) {\n var _this_1 = this;\n var keyField = this.getPrimaryKeyFieldNames()[0];\n changes = Object.assign({ addedRecords: [], changedRecords: [], deletedRecords: [] }, changes);\n var promise = this.getDataModule().saveChanges(changes, keyField, {}, this.getDataModule().generateQuery().requiresCount());\n if (this.getDataModule().isRemote()) {\n promise.then(function () {\n _this_1.setNewData();\n });\n }\n else {\n this.setNewData();\n }\n };\n Grid.prototype.setNewData = function () {\n var _this_1 = this;\n var oldValues = JSON.parse(JSON.stringify(this.getCurrentViewRecords()));\n var getData = this.getDataModule().getData({}, this.getDataModule().generateQuery().requiresCount());\n getData.then(function (e) {\n _this_1.bulkRefresh(e.result, oldValues, e.count);\n });\n };\n Grid.prototype.deleteRowElement = function (row) {\n var tr = this.getRowElementByUID(row.uid);\n remove(tr);\n };\n Grid.prototype.bulkRefresh = function (result, oldValues, count) {\n var _this_1 = this;\n var rowObj = this.getRowsObject();\n var keyField = this.getPrimaryKeyFieldNames()[0];\n var _loop_5 = function (i) {\n if (!result.filter(function (e) { return e[\"\" + keyField] === rowObj[parseInt(i.toString(), 10)].data[\"\" + keyField]; }).length) {\n this_5.deleteRowElement(rowObj[parseInt(i.toString(), 10)]);\n rowObj.splice(i, 1);\n i--;\n }\n out_i_1 = i;\n };\n var this_5 = this, out_i_1;\n for (var i = 0; i < rowObj.length; i++) {\n _loop_5(i);\n i = out_i_1;\n }\n var _loop_6 = function (i) {\n var isRowExist;\n oldValues.filter(function (e) {\n if (e[\"\" + keyField] === result[parseInt(i.toString(), 10)][\"\" + keyField]) {\n if (e !== result[parseInt(i.toString(), 10)]) {\n _this_1.setRowData(result[parseInt(i.toString(), 10)][\"\" + keyField], result[parseInt(i.toString(), 10)]);\n }\n isRowExist = true;\n }\n });\n if (!isRowExist) {\n this_6.renderRowElement(result[parseInt(i.toString(), 10)], i);\n }\n };\n var this_6 = this;\n for (var i = 0; i < result.length; i++) {\n _loop_6(i);\n }\n this.currentViewData = result;\n var rows = [].slice.call(this.getContentTable().getElementsByClassName(literals.row));\n resetRowIndex(this, this.getRowsObject(), rows);\n setRowElements(this);\n if (this.allowPaging) {\n this.notify(events.inBoundModelChanged, { module: 'pager', properties: { totalRecordsCount: count } });\n }\n };\n Grid.prototype.renderRowElement = function (data, index) {\n var row = new RowRenderer(this.serviceLocator, null, this);\n var model = new RowModelGenerator(this);\n var modelData = model.generateRows([data]);\n var tr = row.render(modelData[0], this.getColumns());\n this.addRowObject(modelData[0], index);\n var tbody = this.getContentTable().querySelector(literals.tbody);\n if (tbody.querySelector('.e-emptyrow')) {\n var emptyRow = tbody.querySelector('.e-emptyrow');\n emptyRow.parentNode.removeChild(emptyRow);\n if (this.frozenRows && this.element.querySelector('.e-frozenrow-empty')) {\n this.element.querySelector('.e-frozenrow-empty').classList.remove('e-frozenrow-empty');\n }\n }\n if (this.frozenRows && index < this.frozenRows) {\n tbody = this.getHeaderContent().querySelector(literals.tbody);\n }\n else {\n tbody = this.getContent().querySelector(literals.tbody);\n }\n tbody = this.getContent().querySelector(literals.tbody);\n tbody.appendChild(tr);\n };\n Grid.prototype.addRowObject = function (row, index) {\n this.getRowsObject().splice(index, 1, row);\n };\n /**\n * @hidden\n * @returns {void}\n */\n Grid.prototype.updateVisibleExpandCollapseRows = function () {\n var rows = this.getRowsObject();\n for (var i = 0, len = rows.length; i < len; i++) {\n if ((rows[parseInt(i.toString(), 10)].isDataRow || rows[parseInt(i.toString(), 10)].isAggregateRow)\n && this.getRowElementByUID(rows[parseInt(i.toString(), 10)].uid).style.display === 'none') {\n rows[parseInt(i.toString(), 10)].visible = false;\n }\n else {\n rows[parseInt(i.toString(), 10)].visible = true;\n }\n }\n };\n /**\n * Method to sanitize any suspected untrusted strings and scripts before rendering them.\n *\n * @param {string} value - Specifies the html value to sanitize\n * @returns {string} Returns the sanitized html string\n * @hidden\n */\n Grid.prototype.sanitize = function (value) {\n if (this.enableHtmlSanitizer) {\n return SanitizeHtmlHelper.sanitize(value);\n }\n return value;\n };\n /**\n * @param {string | number} height - specifies the height\n * @returns {number | string} - specifies the height number\n * @hidden\n */\n Grid.prototype.getHeight = function (height) {\n if (!Number.isInteger(height) && height.indexOf('%') !== -1) {\n height = parseInt(height, 10) / 100 * this.element.clientHeight;\n }\n else if (!Number.isInteger(height) && this.height !== 'auto') {\n height = parseInt(height, 10);\n }\n else {\n height = this.height;\n }\n return height;\n };\n /**\n * @hidden\n * @returns {Element} - returns frozen right content\n\n */\n Grid.prototype.getFrozenRightContent = function () {\n return this.contentModule.getPanel();\n };\n /**\n * @hidden\n * @returns {Element} - returns frozen right header\n\n */\n Grid.prototype.getFrozenRightHeader = function () {\n return this.headerModule.getPanel();\n };\n /**\n * @hidden\n * @returns {Element} - returns movable header tbody\n\n */\n Grid.prototype.getMovableHeaderTbody = function () {\n return this.getHeaderContent().querySelector(literals.tbody);\n };\n /**\n * @hidden\n * @returns {Element} - returns movable content tbody\n\n */\n Grid.prototype.getMovableContentTbody = function () {\n return this.getContent().querySelector(literals.tbody);\n };\n /**\n * @hidden\n * @returns {Element} - returns frozen header tbody\n\n */\n Grid.prototype.getFrozenHeaderTbody = function () {\n return this.getHeaderContent().querySelector(literals.tbody);\n };\n /**\n * @hidden\n * @returns {Element} - returns frozen left content tbody\n\n */\n Grid.prototype.getFrozenLeftContentTbody = function () {\n return this.getContent().querySelector(literals.tbody);\n };\n /**\n * @hidden\n * @returns {Element} - returns frozen right header tbody\n\n */\n Grid.prototype.getFrozenRightHeaderTbody = function () {\n return this.getHeaderContent().querySelector(literals.tbody);\n };\n /**\n * @returns {Element} returns frozen right content tbody\n\n * @hidden\n */\n Grid.prototype.getFrozenRightContentTbody = function () {\n return this.getContent().querySelector(literals.tbody);\n };\n /**\n * @param {boolean} isCustom - Defines custom filter dialog open\n * @returns {void}\n * @hidden\n */\n Grid.prototype.showResponsiveCustomFilter = function (isCustom) {\n if (this.filterModule) {\n this.filterModule.showCustomFilter(isCustom || this.rowRenderingMode === 'Vertical');\n }\n };\n /**\n * @param {boolean} isCustom - Defines custom sort dialog open\n * @returns {void}\n * @hidden\n */\n Grid.prototype.showResponsiveCustomSort = function (isCustom) {\n if (this.sortModule) {\n this.sortModule.showCustomSort(isCustom || this.rowRenderingMode === 'Vertical');\n }\n };\n /**\n * @param {boolean} isCustom - Defines custom column chooser dialog open\n * @returns {void}\n * @hidden\n */\n Grid.prototype.showResponsiveCustomColumnChooser = function (isCustom) {\n if (this.columnChooserModule) {\n this.columnChooserModule.showCustomColumnChooser(isCustom || this.rowRenderingMode === 'Vertical');\n }\n };\n /**\n * To manually show the vertical row mode filter dialog\n *\n * @returns {void}\n */\n Grid.prototype.showAdaptiveFilterDialog = function () {\n if (this.enableAdaptiveUI) {\n this.showResponsiveCustomFilter(true);\n }\n };\n /**\n * To manually show the vertical row sort filter dialog\n *\n * @returns {void}\n */\n Grid.prototype.showAdaptiveSortDialog = function () {\n if (this.enableAdaptiveUI) {\n this.showResponsiveCustomSort(true);\n }\n };\n /**\n * @param {boolean} isColVirtualization - Defines column virtualization\n * @returns {Column[]} returns array of column models\n * @hidden\n */\n Grid.prototype.getCurrentVisibleColumns = function (isColVirtualization) {\n var cols = [];\n var gridCols = isColVirtualization ? this.getColumns() : this.columnModel;\n for (var _i = 0, gridCols_1 = gridCols; _i < gridCols_1.length; _i++) {\n var col = gridCols_1[_i];\n if (col.visible) {\n cols.push(col);\n }\n }\n return cols;\n };\n Grid.prototype.enableInfiniteAggrgate = function () {\n if (this.enableInfiniteScrolling && this.groupSettings.columns.length && !this.groupSettings.disablePageWiseAggregates\n && !this.groupSettings.enableLazyLoading) {\n this.setProperties({ groupSettings: { disablePageWiseAggregates: true } }, true);\n }\n };\n var Grid_1;\n __decorate([\n Property([])\n ], Grid.prototype, \"currentViewData\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"parentDetails\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"showHider\", void 0);\n __decorate([\n Property([])\n ], Grid.prototype, \"columns\", void 0);\n __decorate([\n Property(true)\n ], Grid.prototype, \"enableAltRow\", void 0);\n __decorate([\n Property(true)\n ], Grid.prototype, \"enableHover\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableAutoFill\", void 0);\n __decorate([\n Property(true)\n ], Grid.prototype, \"allowKeyboard\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableStickyHeader\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableHtmlSanitizer\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowTextWrap\", void 0);\n __decorate([\n Complex({}, TextWrapSettings)\n ], Grid.prototype, \"textWrapSettings\", void 0);\n __decorate([\n Complex({}, ResizeSettings)\n ], Grid.prototype, \"resizeSettings\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowPaging\", void 0);\n __decorate([\n Complex({}, PageSettings)\n ], Grid.prototype, \"pageSettings\", void 0);\n __decorate([\n Complex({}, LoadingIndicator)\n ], Grid.prototype, \"loadingIndicator\", void 0);\n __decorate([\n Property(true)\n ], Grid.prototype, \"enableVirtualMaskRow\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableVirtualization\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableColumnVirtualization\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableInfiniteScrolling\", void 0);\n __decorate([\n Complex({}, SearchSettings)\n ], Grid.prototype, \"searchSettings\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowSorting\", void 0);\n __decorate([\n Property('Ellipsis')\n ], Grid.prototype, \"clipMode\", void 0);\n __decorate([\n Property(true)\n ], Grid.prototype, \"allowMultiSorting\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowExcelExport\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowPdfExport\", void 0);\n __decorate([\n Complex({}, SortSettings)\n ], Grid.prototype, \"sortSettings\", void 0);\n __decorate([\n Complex({}, InfiniteScrollSettings)\n ], Grid.prototype, \"infiniteScrollSettings\", void 0);\n __decorate([\n Property(true)\n ], Grid.prototype, \"allowSelection\", void 0);\n __decorate([\n Property(-1)\n ], Grid.prototype, \"selectedRowIndex\", void 0);\n __decorate([\n Complex({}, SelectionSettings)\n ], Grid.prototype, \"selectionSettings\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowFiltering\", void 0);\n __decorate([\n Property('Horizontal')\n ], Grid.prototype, \"rowRenderingMode\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableAdaptiveUI\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowReordering\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowResizing\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowRowDragAndDrop\", void 0);\n __decorate([\n Complex({}, RowDropSettings)\n ], Grid.prototype, \"rowDropSettings\", void 0);\n __decorate([\n Complex({}, FilterSettings)\n ], Grid.prototype, \"filterSettings\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"allowGrouping\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableImmutableMode\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"showColumnMenu\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"autoFit\", void 0);\n __decorate([\n Complex({}, GroupSettings)\n ], Grid.prototype, \"groupSettings\", void 0);\n __decorate([\n Complex({}, EditSettings)\n ], Grid.prototype, \"editSettings\", void 0);\n __decorate([\n Collection([], AggregateRow)\n ], Grid.prototype, \"aggregates\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"showColumnChooser\", void 0);\n __decorate([\n Complex({}, ColumnChooserSettings)\n ], Grid.prototype, \"columnChooserSettings\", void 0);\n __decorate([\n Property(false)\n ], Grid.prototype, \"enableHeaderFocus\", void 0);\n __decorate([\n Property('auto')\n ], Grid.prototype, \"height\", void 0);\n __decorate([\n Property('auto')\n ], Grid.prototype, \"width\", void 0);\n __decorate([\n Property('Default')\n ], Grid.prototype, \"gridLines\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"rowTemplate\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"emptyRecordTemplate\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"detailTemplate\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"childGrid\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"queryString\", void 0);\n __decorate([\n Property('AllPages')\n ], Grid.prototype, \"printMode\", void 0);\n __decorate([\n Property('Expanded')\n ], Grid.prototype, \"hierarchyPrintMode\", void 0);\n __decorate([\n Property([])\n ], Grid.prototype, \"dataSource\", void 0);\n __decorate([\n Property(null)\n ], Grid.prototype, \"rowHeight\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"query\", void 0);\n __decorate([\n Property('USD')\n ], Grid.prototype, \"currencyCode\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"exportGrids\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"toolbar\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"contextMenuItems\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"columnMenuItems\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"toolbarTemplate\", void 0);\n __decorate([\n Property()\n ], Grid.prototype, \"pagerTemplate\", void 0);\n __decorate([\n Property(0)\n ], Grid.prototype, \"frozenRows\", void 0);\n __decorate([\n Property(0)\n ], Grid.prototype, \"frozenColumns\", void 0);\n __decorate([\n Property('')\n ], Grid.prototype, \"cssClass\", void 0);\n __decorate([\n Property('All')\n ], Grid.prototype, \"columnQueryMode\", void 0);\n __decorate([\n Property({})\n ], Grid.prototype, \"currentAction\", void 0);\n __decorate([\n Property('')\n ], Grid.prototype, \"ej2StatePersistenceVersion\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"destroyed\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"load\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowDataBound\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"queryCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"headerCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"actionBegin\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"actionComplete\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"actionFailure\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"dataBound\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"recordDoubleClick\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"recordClick\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowSelecting\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowSelected\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowDeselecting\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowDeselected\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"cellSelecting\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"cellSelected\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"cellDeselecting\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"cellDeselected\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnSelecting\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnSelected\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnDeselecting\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnDeselected\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnDragStart\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnDrag\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnDrop\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"printComplete\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforePrint\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"pdfQueryCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"pdfHeaderQueryCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"pdfAggregateQueryCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"excelAggregateQueryCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"exportDetailDataBound\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"exportDetailTemplate\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"excelQueryCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"excelHeaderQueryCellInfo\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeExcelExport\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"excelExportComplete\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforePdfExport\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"pdfExportComplete\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowDragStartHelper\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"detailDataBound\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowDragStart\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowDrag\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"rowDrop\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"toolbarClick\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeOpenColumnChooser\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeOpenAdaptiveDialog\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"batchAdd\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"batchDelete\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"batchCancel\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeBatchAdd\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeBatchDelete\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeBatchSave\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beginEdit\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"commandClick\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"cellEdit\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"cellSave\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"cellSaved\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"resizeStart\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"resizing\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"resizeStop\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"keyPressed\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeDataBound\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"contextMenuOpen\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"contextMenuClick\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnMenuOpen\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnMenuClick\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"checkBoxChange\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeCopy\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforePaste\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"beforeAutoFill\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"columnDataStateChange\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"dataStateChange\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"dataSourceChanged\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"exportGroupCaption\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"lazyLoadGroupExpand\", void 0);\n __decorate([\n Event()\n ], Grid.prototype, \"lazyLoadGroupCollapse\", void 0);\n Grid = Grid_1 = __decorate([\n NotifyPropertyChanges\n ], Grid);\n return Grid;\n}(Component));\nexport { Grid };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Component, NotifyPropertyChanges, Property, setValue } from '@syncfusion/ej2-base';\nimport { Event, EventHandler, isNullOrUndefined, SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport { addClass, detach, getUniqueID, isRippleEnabled, removeClass, rippleEffect, closest } from '@syncfusion/ej2-base';\nimport { wrapperInitialize, rippleMouseHandler, setHiddenInput } from './../common/common';\nvar CHECK = 'e-check';\nvar DISABLED = 'e-checkbox-disabled';\nvar FRAME = 'e-frame';\nvar INDETERMINATE = 'e-stop';\nvar LABEL = 'e-label';\nvar RIPPLE = 'e-ripple-container';\nvar RIPPLECHECK = 'e-ripple-check';\nvar RIPPLEINDETERMINATE = 'e-ripple-stop';\nvar RTL = 'e-rtl';\nvar WRAPPER = 'e-checkbox-wrapper';\nvar containerAttr = ['title', 'class', 'style', 'disabled', 'readonly', 'name', 'value', 'id'];\n/**\n * The CheckBox is a graphical user interface element that allows you to select one or more options from the choices.\n * It contains checked, unchecked, and indeterminate states.\n * ```html\n * <input type=\"checkbox\" id=\"checkbox\"/>\n * <script>\n * var checkboxObj = new CheckBox({ label: \"Default\" });\n * checkboxObj.appendTo(\"#checkbox\");\n * </script>\n * ```\n */\nvar CheckBox = /** @class */ (function (_super) {\n __extends(CheckBox, _super);\n /**\n * Constructor for creating the widget\n *\n * @private\n * @param {CheckBoxModel} options - Specifies checkbox model\n * @param {string | HTMLInputElement} element - Specifies target element\n */\n function CheckBox(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.isFocused = false;\n _this.isMouseClick = false;\n _this.clickTriggered = false;\n _this.validCheck = true;\n return _this;\n }\n CheckBox.prototype.changeState = function (state, isInitialize) {\n var ariaState;\n var rippleSpan;\n var frameSpan = this.getWrapper().getElementsByClassName(FRAME)[0];\n if (isRippleEnabled) {\n rippleSpan = this.getWrapper().getElementsByClassName(RIPPLE)[0];\n }\n if (state === 'check') {\n if (frameSpan) {\n frameSpan.classList.remove(INDETERMINATE);\n frameSpan.classList.add(CHECK);\n }\n if (rippleSpan) {\n rippleSpan.classList.remove(RIPPLEINDETERMINATE);\n rippleSpan.classList.add(RIPPLECHECK);\n }\n ariaState = 'true';\n this.element.checked = true;\n if ((this.element.required || closest(this.element, 'form') && closest(this.element, 'form').classList.contains('e-formvalidator')) && this.validCheck && !isInitialize) {\n this.element.checked = false;\n this.validCheck = false;\n }\n else if (this.element.required || closest(this.element, 'form') && closest(this.element, 'form').classList.contains('e-formvalidator')) {\n this.validCheck = true;\n }\n }\n else if (state === 'uncheck') {\n if (frameSpan) {\n removeClass([frameSpan], [CHECK, INDETERMINATE]);\n }\n if (rippleSpan) {\n removeClass([rippleSpan], [RIPPLECHECK, RIPPLEINDETERMINATE]);\n }\n ariaState = 'false';\n this.element.checked = false;\n if ((this.element.required || closest(this.element, 'form') && closest(this.element, 'form').classList.contains('e-formvalidator')) && this.validCheck && !isInitialize) {\n this.element.checked = true;\n this.validCheck = false;\n }\n else if (this.element.required || closest(this.element, 'form') && closest(this.element, 'form').classList.contains('e-formvalidator')) {\n this.validCheck = true;\n }\n }\n else {\n if (frameSpan) {\n frameSpan.classList.remove(CHECK);\n frameSpan.classList.add(INDETERMINATE);\n }\n if (rippleSpan) {\n rippleSpan.classList.remove(RIPPLECHECK);\n rippleSpan.classList.add(RIPPLEINDETERMINATE);\n }\n ariaState = 'mixed';\n this.element.indeterminate = true;\n this.indeterminate = true;\n }\n };\n CheckBox.prototype.clickHandler = function (event) {\n if (event.target.tagName === 'INPUT' && this.clickTriggered) {\n if (this.isVue) {\n this.changeState(this.checked ? 'check' : 'uncheck');\n }\n this.clickTriggered = false;\n return;\n }\n if (event.target.tagName === 'SPAN' || event.target.tagName === 'LABEL') {\n this.clickTriggered = true;\n }\n if (this.isMouseClick) {\n this.focusOutHandler();\n this.isMouseClick = false;\n }\n if (this.indeterminate) {\n this.changeState(this.checked ? 'check' : 'uncheck');\n this.indeterminate = false;\n this.element.indeterminate = false;\n }\n else if (this.checked) {\n this.changeState('uncheck');\n this.checked = false;\n }\n else {\n this.changeState('check');\n this.checked = true;\n }\n var changeEventArgs = { checked: this.updateVueArrayModel(false), event: event };\n this.trigger('change', changeEventArgs);\n event.stopPropagation();\n };\n /**\n * Destroys the widget.\n *\n * @returns {void}\n */\n CheckBox.prototype.destroy = function () {\n var _this = this;\n var wrapper = this.getWrapper();\n _super.prototype.destroy.call(this);\n if (this.wrapper) {\n wrapper = this.wrapper;\n if (!this.disabled) {\n this.unWireEvents();\n }\n if (this.tagName === 'INPUT') {\n if (this.getWrapper() && wrapper.parentNode) {\n wrapper.parentNode.insertBefore(this.element, wrapper);\n }\n detach(wrapper);\n this.element.checked = false;\n if (this.indeterminate) {\n this.element.indeterminate = false;\n }\n ['name', 'value', 'disabled'].forEach(function (key) {\n _this.element.removeAttribute(key);\n });\n }\n else {\n ['class'].forEach(function (key) {\n wrapper.removeAttribute(key);\n });\n wrapper.innerHTML = '';\n this.element = wrapper;\n if (this.refreshing) {\n ['e-control', 'e-checkbox', 'e-lib'].forEach(function (key) {\n _this.element.classList.add(key);\n });\n setValue('ej2_instances', [this], this.element);\n }\n }\n }\n };\n CheckBox.prototype.focusHandler = function () {\n this.isFocused = true;\n };\n CheckBox.prototype.focusOutHandler = function () {\n var wrapper = this.getWrapper();\n if (wrapper) {\n wrapper.classList.remove('e-focus');\n }\n this.isFocused = false;\n };\n /**\n * Gets the module name.\n *\n * @private\n * @returns {string} - Module Name\n */\n CheckBox.prototype.getModuleName = function () {\n return 'checkbox';\n };\n /**\n * Gets the properties to be maintained in the persistence state.\n *\n * @private\n * @returns {string} - Persist Data\n */\n CheckBox.prototype.getPersistData = function () {\n return this.addOnPersist(['checked', 'indeterminate']);\n };\n CheckBox.prototype.getWrapper = function () {\n if (this.element && this.element.parentElement) {\n return this.element.parentElement.parentElement;\n }\n else {\n return null;\n }\n };\n CheckBox.prototype.getLabel = function () {\n if (this.element) {\n return this.element.parentElement;\n }\n else {\n return null;\n }\n };\n CheckBox.prototype.initialize = function () {\n if (isNullOrUndefined(this.initialCheckedValue)) {\n this.initialCheckedValue = this.checked;\n }\n if (this.name) {\n this.element.setAttribute('name', this.name);\n }\n if (this.value) {\n this.element.setAttribute('value', this.value);\n if (this.isVue && typeof this.value === 'boolean' && this.value === true) {\n this.setProperties({ 'checked': true }, true);\n }\n }\n if (this.checked) {\n this.changeState('check', true);\n }\n if (this.indeterminate) {\n this.changeState();\n }\n if (this.disabled) {\n this.setDisabled();\n }\n };\n CheckBox.prototype.initWrapper = function () {\n var wrapper = this.element.parentElement;\n if (!wrapper.classList.contains(WRAPPER)) {\n wrapper = this.createElement('div', {\n className: WRAPPER\n });\n this.element.parentNode.insertBefore(wrapper, this.element);\n }\n var label = this.createElement('label', { attrs: { for: this.element.id } });\n var frameSpan = this.createElement('span', { className: 'e-icons ' + FRAME });\n wrapper.classList.add('e-wrapper');\n if (this.enableRtl) {\n wrapper.classList.add(RTL);\n }\n if (this.cssClass) {\n addClass([wrapper], this.cssClass.replace(/\\s+/g, ' ').trim().split(' '));\n }\n wrapper.appendChild(label);\n label.appendChild(this.element);\n setHiddenInput(this, label);\n label.appendChild(frameSpan);\n if (isRippleEnabled) {\n var rippleSpan = this.createElement('span', { className: RIPPLE });\n if (this.labelPosition === 'Before') {\n label.appendChild(rippleSpan);\n }\n else {\n label.insertBefore(rippleSpan, frameSpan);\n }\n rippleEffect(rippleSpan, { duration: 400, isCenterRipple: true });\n }\n if (this.label) {\n this.setText(this.label);\n }\n };\n CheckBox.prototype.keyUpHandler = function () {\n if (this.isFocused) {\n this.getWrapper().classList.add('e-focus');\n }\n };\n CheckBox.prototype.labelMouseDownHandler = function (e) {\n this.isMouseClick = true;\n var rippleSpan = this.getWrapper().getElementsByClassName(RIPPLE)[0];\n rippleMouseHandler(e, rippleSpan);\n };\n CheckBox.prototype.labelMouseLeaveHandler = function (e) {\n var rippleSpan = this.getLabel().getElementsByClassName(RIPPLE)[0];\n if (rippleSpan) {\n var rippleElem = rippleSpan.querySelectorAll('.e-ripple-element');\n for (var i = rippleElem.length - 1; i > 0; i--) {\n rippleSpan.removeChild(rippleSpan.childNodes[i]);\n }\n rippleMouseHandler(e, rippleSpan);\n }\n };\n CheckBox.prototype.labelMouseUpHandler = function (e) {\n this.isMouseClick = true;\n var rippleSpan = this.getWrapper().getElementsByClassName(RIPPLE)[0];\n if (rippleSpan) {\n var rippleElem = rippleSpan.querySelectorAll('.e-ripple-element');\n for (var i = 0; i < rippleElem.length - 1; i++) {\n rippleSpan.removeChild(rippleSpan.childNodes[i]);\n }\n rippleMouseHandler(e, rippleSpan);\n }\n };\n /**\n * Called internally if any of the property value changes.\n *\n * @private\n * @param {CheckBoxModel} newProp - Specifies new Properties\n * @param {CheckBoxModel} oldProp - Specifies old Properties\n *\n * @returns {void}\n */\n CheckBox.prototype.onPropertyChanged = function (newProp, oldProp) {\n var wrapper = this.getWrapper();\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'checked':\n this.indeterminate = false;\n this.element.indeterminate = false;\n this.changeState(newProp.checked ? 'check' : 'uncheck');\n break;\n case 'indeterminate':\n if (newProp.indeterminate) {\n this.changeState();\n }\n else {\n this.element.indeterminate = false;\n this.changeState(this.checked ? 'check' : 'uncheck');\n }\n break;\n case 'disabled':\n if (newProp.disabled) {\n this.setDisabled();\n this.wrapper = this.getWrapper();\n this.unWireEvents();\n }\n else {\n this.element.disabled = false;\n wrapper.classList.remove(DISABLED);\n wrapper.setAttribute('aria-disabled', 'false');\n this.wireEvents();\n }\n break;\n case 'cssClass':\n if (oldProp.cssClass) {\n removeClass([wrapper], oldProp.cssClass.split(' '));\n }\n if (newProp.cssClass) {\n addClass([wrapper], newProp.cssClass.replace(/\\s+/g, ' ').trim().split(' '));\n }\n break;\n case 'enableRtl':\n if (newProp.enableRtl) {\n wrapper.classList.add(RTL);\n }\n else {\n wrapper.classList.remove(RTL);\n }\n break;\n case 'label':\n this.setText(newProp.label);\n break;\n case 'labelPosition': {\n var label = wrapper.getElementsByClassName(LABEL)[0];\n var labelWrap = wrapper.getElementsByTagName('label')[0];\n detach(label);\n if (newProp.labelPosition === 'After') {\n labelWrap.appendChild(label);\n }\n else {\n labelWrap.insertBefore(label, wrapper.getElementsByClassName(FRAME)[0]);\n }\n break;\n }\n case 'name':\n this.element.setAttribute('name', newProp.name);\n break;\n case 'value':\n if (this.isVue && typeof newProp.value === 'object') {\n break;\n }\n this.element.setAttribute('value', newProp.value);\n break;\n case 'htmlAttributes':\n this.updateHtmlAttributeToWrapper();\n break;\n }\n }\n };\n /**\n * Initialize Angular, React and Unique ID support.\n *\n * @private\n * @returns {void}\n */\n CheckBox.prototype.preRender = function () {\n var element = this.element;\n this.tagName = this.element.tagName;\n element = wrapperInitialize(this.createElement, 'EJS-CHECKBOX', 'checkbox', element, WRAPPER, 'checkbox');\n this.element = element;\n if (this.element.getAttribute('type') !== 'checkbox') {\n this.element.setAttribute('type', 'checkbox');\n }\n if (!this.element.id) {\n this.element.id = getUniqueID('e-' + this.getModuleName());\n }\n };\n /**\n * Initialize the control rendering.\n *\n * @private\n * @returns {void}\n */\n CheckBox.prototype.render = function () {\n this.initWrapper();\n this.initialize();\n if (!this.disabled) {\n this.wireEvents();\n }\n this.updateHtmlAttributeToWrapper();\n this.updateVueArrayModel(true);\n this.renderComplete();\n this.wrapper = this.getWrapper();\n };\n CheckBox.prototype.setDisabled = function () {\n var wrapper = this.getWrapper();\n this.element.disabled = true;\n wrapper.classList.add(DISABLED);\n wrapper.setAttribute('aria-disabled', 'true');\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n CheckBox.prototype.setText = function (text) {\n var wrapper = this.getWrapper();\n if (!wrapper) {\n return;\n }\n var label = wrapper.getElementsByClassName(LABEL)[0];\n if (label) {\n label.textContent = text;\n }\n else {\n text = (this.enableHtmlSanitizer) ? SanitizeHtmlHelper.sanitize(text) : text;\n label = this.createElement('span', { className: LABEL, innerHTML: text });\n var labelWrap = wrapper.getElementsByTagName('label')[0];\n if (this.labelPosition === 'Before') {\n labelWrap.insertBefore(label, wrapper.getElementsByClassName(FRAME)[0]);\n }\n else {\n labelWrap.appendChild(label);\n }\n }\n };\n CheckBox.prototype.changeHandler = function (e) {\n e.stopPropagation();\n };\n CheckBox.prototype.formResetHandler = function () {\n this.checked = this.initialCheckedValue;\n this.element.checked = this.initialCheckedValue;\n };\n CheckBox.prototype.unWireEvents = function () {\n var wrapper = this.wrapper;\n EventHandler.remove(wrapper, 'click', this.clickHandler);\n EventHandler.remove(this.element, 'keyup', this.keyUpHandler);\n EventHandler.remove(this.element, 'focus', this.focusHandler);\n EventHandler.remove(this.element, 'focusout', this.focusOutHandler);\n var label = wrapper.getElementsByTagName('label')[0];\n EventHandler.remove(label, 'mousedown', this.labelMouseDownHandler);\n EventHandler.remove(label, 'mouseup', this.labelMouseUpHandler);\n EventHandler.remove(label, 'mouseleave', this.labelMouseLeaveHandler);\n var formElem = closest(this.element, 'form');\n if (formElem) {\n EventHandler.remove(formElem, 'reset', this.formResetHandler);\n }\n if (this.tagName === 'EJS-CHECKBOX') {\n EventHandler.remove(this.element, 'change', this.changeHandler);\n }\n };\n CheckBox.prototype.wireEvents = function () {\n var wrapper = this.getWrapper();\n EventHandler.add(wrapper, 'click', this.clickHandler, this);\n EventHandler.add(this.element, 'keyup', this.keyUpHandler, this);\n EventHandler.add(this.element, 'focus', this.focusHandler, this);\n EventHandler.add(this.element, 'focusout', this.focusOutHandler, this);\n var label = wrapper.getElementsByTagName('label')[0];\n EventHandler.add(label, 'mousedown', this.labelMouseDownHandler, this);\n EventHandler.add(label, 'mouseup', this.labelMouseUpHandler, this);\n EventHandler.add(label, 'mouseleave', this.labelMouseLeaveHandler, this);\n var formElem = closest(this.element, 'form');\n if (formElem) {\n EventHandler.add(formElem, 'reset', this.formResetHandler, this);\n }\n if (this.tagName === 'EJS-CHECKBOX') {\n EventHandler.add(this.element, 'change', this.changeHandler, this);\n }\n };\n CheckBox.prototype.updateVueArrayModel = function (init) {\n if (this.isVue && typeof this.value === 'object') {\n var value = this.element.value;\n if (value && this.value) {\n if (init) {\n for (var i = 0; i < this.value.length; i++) {\n if (value === this.value[i]) {\n this.changeState('check');\n this.setProperties({ 'checked': true }, true);\n }\n }\n }\n else {\n var index = this.value.indexOf(value);\n if (this.checked) {\n if (index < 0) {\n this.value.push(value);\n }\n }\n else {\n if (index > -1) {\n this.value.splice(index, 1);\n }\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n return this.value;\n }\n }\n }\n return this.validCheck ? this.element.checked : !this.element.checked;\n };\n CheckBox.prototype.updateHtmlAttributeToWrapper = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n var wrapper = this.getWrapper();\n if (containerAttr.indexOf(key) > -1) {\n if (key === 'class') {\n addClass([wrapper], this.htmlAttributes[\"\" + key].split(' '));\n }\n else if (key === 'title') {\n wrapper.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n else if (key === 'style') {\n var frameSpan = this.getWrapper().getElementsByClassName(FRAME)[0];\n frameSpan.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n else if (key === 'disabled') {\n if (this.htmlAttributes[\"\" + key] === 'true') {\n this.setDisabled();\n }\n this.element.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n else {\n this.element.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n else {\n wrapper.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n };\n /**\n * Click the CheckBox element\n * its native method\n *\n * @public\n * @returns {void}\n */\n CheckBox.prototype.click = function () {\n this.element.click();\n };\n /**\n * Sets the focus to CheckBox\n * its native method\n *\n * @public\n * @returns {void}\n */\n CheckBox.prototype.focusIn = function () {\n this.element.focus();\n };\n __decorate([\n Event()\n ], CheckBox.prototype, \"change\", void 0);\n __decorate([\n Event()\n ], CheckBox.prototype, \"created\", void 0);\n __decorate([\n Property(false)\n ], CheckBox.prototype, \"checked\", void 0);\n __decorate([\n Property('')\n ], CheckBox.prototype, \"cssClass\", void 0);\n __decorate([\n Property(false)\n ], CheckBox.prototype, \"disabled\", void 0);\n __decorate([\n Property(false)\n ], CheckBox.prototype, \"indeterminate\", void 0);\n __decorate([\n Property('')\n ], CheckBox.prototype, \"label\", void 0);\n __decorate([\n Property('After')\n ], CheckBox.prototype, \"labelPosition\", void 0);\n __decorate([\n Property('')\n ], CheckBox.prototype, \"name\", void 0);\n __decorate([\n Property('')\n ], CheckBox.prototype, \"value\", void 0);\n __decorate([\n Property(false)\n ], CheckBox.prototype, \"enableHtmlSanitizer\", void 0);\n __decorate([\n Property({})\n ], CheckBox.prototype, \"htmlAttributes\", void 0);\n CheckBox = __decorate([\n NotifyPropertyChanges\n ], CheckBox);\n return CheckBox;\n}(Component));\nexport { CheckBox };\n","//! moment.js locale configuration\n//! locale : French [fr]\n//! author : John Fischer : https://github.com/jfroffice\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsStrictRegex =\n /^(janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i,\n monthsShortStrictRegex =\n /(janv\\.?|févr\\.?|mars|avr\\.?|mai|juin|juil\\.?|août|sept\\.?|oct\\.?|nov\\.?|déc\\.?)/i,\n monthsRegex =\n /(janv\\.?|févr\\.?|mars|avr\\.?|mai|juin|juil\\.?|août|sept\\.?|oct\\.?|nov\\.?|déc\\.?|janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i,\n monthsParse = [\n /^janv/i,\n /^févr/i,\n /^mars/i,\n /^avr/i,\n /^mai/i,\n /^juin/i,\n /^juil/i,\n /^août/i,\n /^sept/i,\n /^oct/i,\n /^nov/i,\n /^déc/i,\n ];\n\n var fr = moment.defineLocale('fr', {\n months: 'janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre'.split(\n '_'\n ),\n monthsShort:\n 'janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.'.split(\n '_'\n ),\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex: monthsStrictRegex,\n monthsShortStrictRegex: monthsShortStrictRegex,\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n weekdays: 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),\n weekdaysShort: 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),\n weekdaysMin: 'di_lu_ma_me_je_ve_sa'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Aujourd’hui à ] LT',\n nextDay: '[Demain à ] LT',\n nextWeek: 'dddd [à ] LT',\n lastDay: '[Hier à ] LT',\n lastWeek: 'dddd [dernier à ] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'dans %s',\n past: 'il y a %s',\n s: 'quelques secondes',\n ss: '%d secondes',\n m: 'une minute',\n mm: '%d minutes',\n h: 'une heure',\n hh: '%d heures',\n d: 'un jour',\n dd: '%d jours',\n w: 'une semaine',\n ww: '%d semaines',\n M: 'un mois',\n MM: '%d mois',\n y: 'un an',\n yy: '%d ans',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(er|)/,\n ordinal: function (number, period) {\n switch (period) {\n // TODO: Return 'e' when day of month > 1. Move this case inside\n // block for masculine words below.\n // See https://github.com/moment/moment/issues/3375\n case 'D':\n return number + (number === 1 ? 'er' : '');\n\n // Words with masculine grammatical gender: mois, trimestre, jour\n default:\n case 'M':\n case 'Q':\n case 'DDD':\n case 'd':\n return number + (number === 1 ? 'er' : 'e');\n\n // Words with feminine grammatical gender: semaine\n case 'w':\n case 'W':\n return number + (number === 1 ? 're' : 'e');\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return fr;\n\n})));\n","//! moment.js locale configuration\n//! locale : Arabic (Algeria) [ar-dz]\n//! author : Amine Roukh: https://github.com/Amine27\n//! author : Abdel Said: https://github.com/abdelsaid\n//! author : Ahmed Elkhatib\n//! author : forabi https://github.com/forabi\n//! author : Noureddine LOUAHEDJ : https://github.com/noureddinem\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var pluralForm = function (n) {\n return n === 0\n ? 0\n : n === 1\n ? 1\n : n === 2\n ? 2\n : n % 100 >= 3 && n % 100 <= 10\n ? 3\n : n % 100 >= 11\n ? 4\n : 5;\n },\n plurals = {\n s: [\n 'أقل من ثانية',\n 'ثانية واØدة',\n ['ثانيتان', 'ثانيتين'],\n '%d ثوان',\n '%d ثانية',\n '%d ثانية',\n ],\n m: [\n 'أقل من دقيقة',\n 'دقيقة واØدة',\n ['دقيقتان', 'دقيقتين'],\n '%d دقائق',\n '%d دقيقة',\n '%d دقيقة',\n ],\n h: [\n 'أقل من ساعة',\n 'ساعة واØدة',\n ['ساعتان', 'ساعتين'],\n '%d ساعات',\n '%d ساعة',\n '%d ساعة',\n ],\n d: [\n 'أقل من يوم',\n 'يوم واØد',\n ['يومان', 'يومين'],\n '%d أيام',\n '%d يومًا',\n '%d يوم',\n ],\n M: [\n 'أقل من شهر',\n 'شهر واØد',\n ['شهران', 'شهرين'],\n '%d أشهر',\n '%d شهرا',\n '%d شهر',\n ],\n y: [\n 'أقل من عام',\n 'عام واØد',\n ['عامان', 'عامين'],\n '%d أعوام',\n '%d عامًا',\n '%d عام',\n ],\n },\n pluralize = function (u) {\n return function (number, withoutSuffix, string, isFuture) {\n var f = pluralForm(number),\n str = plurals[u][pluralForm(number)];\n if (f === 2) {\n str = str[withoutSuffix ? 0 : 1];\n }\n return str.replace(/%d/i, number);\n };\n },\n months = [\n 'جانÙÙŠ',\n 'ÙÙŠÙري',\n 'مارس',\n 'Ø£Ùريل',\n 'ماي',\n 'جوان',\n 'جويلية',\n 'أوت',\n 'سبتمبر',\n 'أكتوبر',\n 'نوÙمبر',\n 'ديسمبر',\n ];\n\n var arDz = moment.defineLocale('ar-dz', {\n months: months,\n monthsShort: months,\n weekdays: 'الأØد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),\n weekdaysShort: 'Ø£Øد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت'.split('_'),\n weekdaysMin: 'Ø_Ù†_Ø«_ر_Ø®_ج_س'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'D/\\u200FM/\\u200FYYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n meridiemParse: /ص|Ù…/,\n isPM: function (input) {\n return 'Ù…' === input;\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'ص';\n } else {\n return 'Ù…';\n }\n },\n calendar: {\n sameDay: '[اليوم عند الساعة] LT',\n nextDay: '[غدًا عند الساعة] LT',\n nextWeek: 'dddd [عند الساعة] LT',\n lastDay: '[أمس عند الساعة] LT',\n lastWeek: 'dddd [عند الساعة] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'بعد %s',\n past: 'منذ %s',\n s: pluralize('s'),\n ss: pluralize('s'),\n m: pluralize('m'),\n mm: pluralize('m'),\n h: pluralize('h'),\n hh: pluralize('h'),\n d: pluralize('d'),\n dd: pluralize('d'),\n M: pluralize('M'),\n MM: pluralize('M'),\n y: pluralize('y'),\n yy: pluralize('y'),\n },\n postformat: function (string) {\n return string.replace(/,/g, 'ØŒ');\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return arDz;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Component, EventHandler, Property, Event, Browser, L10n, getUniqueID } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges } from '@syncfusion/ej2-base';\nimport { attributes, addClass, removeClass, detach, closest } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, getValue, formatUnit, setValue, merge } from '@syncfusion/ej2-base';\nimport { Internationalization, getNumericObject } from '@syncfusion/ej2-base';\nimport { Input } from '../input/input';\nvar ROOT = 'e-control-wrapper e-numeric';\nvar SPINICON = 'e-input-group-icon';\nvar SPINUP = 'e-spin-up';\nvar SPINDOWN = 'e-spin-down';\nvar ERROR = 'e-error';\nvar INCREMENT = 'increment';\nvar DECREMENT = 'decrement';\nvar INTREGEXP = new RegExp('^(-)?(\\\\d*)$');\nvar DECIMALSEPARATOR = '.';\nvar COMPONENT = 'e-numerictextbox';\nvar CONTROL = 'e-control';\nvar NUMERIC_FOCUS = 'e-input-focus';\nvar HIDDENELEMENT = 'e-numeric-hidden';\nvar wrapperAttributes = ['title', 'style', 'class'];\nvar selectionTimeOut = 0;\n/**\n * Represents the NumericTextBox component that allows the user to enter only numeric values.\n * ```html\n * <input type='text' id=\"numeric\"/>\n * ```\n * ```typescript\n * <script>\n * var numericObj = new NumericTextBox({ value: 10 });\n * numericObj.appendTo(\"#numeric\");\n * </script>\n * ```\n */\nvar NumericTextBox = /** @class */ (function (_super) {\n __extends(NumericTextBox, _super);\n /**\n *\n * @param {NumericTextBoxModel} options - Specifies the NumericTextBox model.\n * @param {string | HTMLInputElement} element - Specifies the element to render as component.\n * @private\n */\n function NumericTextBox(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.isVue = false;\n _this.preventChange = false;\n _this.isAngular = false;\n _this.isDynamicChange = false;\n _this.numericOptions = options;\n return _this;\n }\n NumericTextBox.prototype.preRender = function () {\n this.isPrevFocused = false;\n this.decimalSeparator = '.';\n // eslint-disable-next-line no-useless-escape\n this.intRegExp = new RegExp('/^(-)?(\\d*)$/');\n this.isCalled = false;\n var ejInstance = getValue('ej2_instances', this.element);\n this.cloneElement = this.element.cloneNode(true);\n removeClass([this.cloneElement], [CONTROL, COMPONENT, 'e-lib']);\n this.angularTagName = null;\n this.formEle = closest(this.element, 'form');\n if (this.element.tagName === 'EJS-NUMERICTEXTBOX') {\n this.angularTagName = this.element.tagName;\n var input = this.createElement('input');\n var index = 0;\n for (index; index < this.element.attributes.length; index++) {\n var attributeName = this.element.attributes[index].nodeName;\n if (attributeName !== 'id' && attributeName !== 'class') {\n input.setAttribute(this.element.attributes[index].nodeName, this.element.attributes[index].nodeValue);\n input.innerHTML = this.element.innerHTML;\n }\n else if (attributeName === 'class') {\n input.setAttribute(attributeName, this.element.className.split(' ').filter(function (item) { return item.indexOf('ng-') !== 0; }).join(' '));\n }\n }\n if (this.element.hasAttribute('name')) {\n this.element.removeAttribute('name');\n }\n this.element.classList.remove('e-control', 'e-numerictextbox');\n this.element.appendChild(input);\n this.element = input;\n setValue('ej2_instances', ejInstance, this.element);\n }\n attributes(this.element, { 'role': 'spinbutton', 'tabindex': '0', 'autocomplete': 'off' });\n var localeText = {\n incrementTitle: 'Increment value', decrementTitle: 'Decrement value', placeholder: this.placeholder\n };\n this.l10n = new L10n('numerictextbox', localeText, this.locale);\n if (this.l10n.getConstant('placeholder') !== '') {\n this.setProperties({ placeholder: this.placeholder || this.l10n.getConstant('placeholder') }, true);\n }\n if (!this.element.hasAttribute('id')) {\n this.element.setAttribute('id', getUniqueID('numerictextbox'));\n }\n this.isValidState = true;\n this.inputStyle = null;\n this.inputName = null;\n this.cultureInfo = {};\n this.initCultureInfo();\n this.initCultureFunc();\n this.prevValue = this.value;\n this.updateHTMLAttrToElement();\n this.checkAttributes(false);\n if (this.formEle) {\n this.inputEleValue = this.value;\n }\n this.validateMinMax();\n this.validateStep();\n if (this.placeholder === null) {\n this.updatePlaceholder();\n }\n };\n /**\n * To Initialize the control rendering\n *\n * @returns {void}\n * @private\n */\n NumericTextBox.prototype.render = function () {\n if (this.element.tagName.toLowerCase() === 'input') {\n this.createWrapper();\n if (this.showSpinButton) {\n this.spinBtnCreation();\n }\n this.setElementWidth(this.width);\n if (!this.container.classList.contains('e-input-group')) {\n this.container.classList.add('e-input-group');\n }\n this.changeValue(this.value === null || isNaN(this.value) ?\n null : this.strictMode ? this.trimValue(this.value) : this.value);\n this.wireEvents();\n if (this.value !== null && !isNaN(this.value)) {\n if (this.decimals) {\n this.setProperties({ value: this.roundNumber(this.value, this.decimals) }, true);\n }\n }\n if (this.element.getAttribute('value') || this.value) {\n this.element.setAttribute('value', this.element.value);\n this.hiddenInput.setAttribute('value', this.hiddenInput.value);\n }\n this.elementPrevValue = this.element.value;\n if (this.element.hasAttribute('data-val')) {\n this.element.setAttribute('data-val', 'false');\n }\n if (!isNullOrUndefined(closest(this.element, 'fieldset')) && closest(this.element, 'fieldset').disabled) {\n this.enabled = false;\n }\n this.renderComplete();\n }\n };\n NumericTextBox.prototype.checkAttributes = function (isDynamic) {\n var attributes = isDynamic ? isNullOrUndefined(this.htmlAttributes) ? [] : Object.keys(this.htmlAttributes) :\n ['value', 'min', 'max', 'step', 'disabled', 'readonly', 'style', 'name', 'placeholder'];\n for (var _i = 0, attributes_1 = attributes; _i < attributes_1.length; _i++) {\n var prop = attributes_1[_i];\n if (!isNullOrUndefined(this.element.getAttribute(prop))) {\n switch (prop) {\n case 'disabled':\n if ((isNullOrUndefined(this.numericOptions) || (this.numericOptions['enabled'] === undefined)) || isDynamic) {\n var enabled = this.element.getAttribute(prop) === 'disabled' || this.element.getAttribute(prop) === ''\n || this.element.getAttribute(prop) === 'true' ? false : true;\n this.setProperties({ enabled: enabled }, !isDynamic);\n }\n break;\n case 'readonly':\n if ((isNullOrUndefined(this.numericOptions) || (this.numericOptions['readonly'] === undefined)) || isDynamic) {\n var readonly = this.element.getAttribute(prop) === 'readonly' || this.element.getAttribute(prop) === ''\n || this.element.getAttribute(prop) === 'true' ? true : false;\n this.setProperties({ readonly: readonly }, !isDynamic);\n }\n break;\n case 'placeholder':\n if ((isNullOrUndefined(this.numericOptions) || (this.numericOptions['placeholder'] === undefined)) || isDynamic) {\n this.setProperties({ placeholder: this.element.placeholder }, !isDynamic);\n }\n break;\n case 'value':\n if ((isNullOrUndefined(this.numericOptions) || (this.numericOptions['value'] === undefined)) || isDynamic) {\n var setNumber = this.instance.getNumberParser({ format: 'n' })(this.element.getAttribute(prop));\n this.setProperties(setValue(prop, setNumber, {}), !isDynamic);\n }\n break;\n case 'min':\n if ((isNullOrUndefined(this.numericOptions) || (this.numericOptions['min'] === undefined)) || isDynamic) {\n var minValue = this.instance.getNumberParser({ format: 'n' })(this.element.getAttribute(prop));\n if (minValue !== null && !isNaN(minValue)) {\n this.setProperties(setValue(prop, minValue, {}), !isDynamic);\n }\n }\n break;\n case 'max':\n if ((isNullOrUndefined(this.numericOptions) || (this.numericOptions['max'] === undefined)) || isDynamic) {\n var maxValue = this.instance.getNumberParser({ format: 'n' })(this.element.getAttribute(prop));\n if (maxValue !== null && !isNaN(maxValue)) {\n this.setProperties(setValue(prop, maxValue, {}), !isDynamic);\n }\n }\n break;\n case 'step':\n if ((isNullOrUndefined(this.numericOptions) || (this.numericOptions['step'] === undefined)) || isDynamic) {\n var stepValue = this.instance.getNumberParser({ format: 'n' })(this.element.getAttribute(prop));\n if (stepValue !== null && !isNaN(stepValue)) {\n this.setProperties(setValue(prop, stepValue, {}), !isDynamic);\n }\n }\n break;\n case 'style':\n this.inputStyle = this.element.getAttribute(prop);\n break;\n case 'name':\n this.inputName = this.element.getAttribute(prop);\n break;\n default:\n {\n var value = this.instance.getNumberParser({ format: 'n' })(this.element.getAttribute(prop));\n if ((value !== null && !isNaN(value)) || (prop === 'value')) {\n this.setProperties(setValue(prop, value, {}), true);\n }\n }\n break;\n }\n }\n }\n };\n NumericTextBox.prototype.updatePlaceholder = function () {\n this.setProperties({ placeholder: this.l10n.getConstant('placeholder') }, true);\n };\n NumericTextBox.prototype.initCultureFunc = function () {\n this.instance = new Internationalization(this.locale);\n };\n NumericTextBox.prototype.initCultureInfo = function () {\n this.cultureInfo.format = this.format;\n if (getValue('currency', this) !== null) {\n setValue('currency', this.currency, this.cultureInfo);\n this.setProperties({ currencyCode: this.currency }, true);\n }\n };\n /* Wrapper creation */\n NumericTextBox.prototype.createWrapper = function () {\n var updatedCssClassValue = this.cssClass;\n if (!isNullOrUndefined(this.cssClass) && this.cssClass !== '') {\n updatedCssClassValue = this.getNumericValidClassList(this.cssClass);\n }\n var inputObj = Input.createInput({\n element: this.element,\n floatLabelType: this.floatLabelType,\n properties: {\n readonly: this.readonly,\n placeholder: this.placeholder,\n cssClass: updatedCssClassValue,\n enableRtl: this.enableRtl,\n showClearButton: this.showClearButton,\n enabled: this.enabled\n }\n }, this.createElement);\n this.inputWrapper = inputObj;\n this.container = inputObj.container;\n this.container.setAttribute('class', ROOT + ' ' + this.container.getAttribute('class'));\n this.updateHTMLAttrToWrapper();\n if (this.readonly) {\n attributes(this.element, { 'aria-readonly': 'true' });\n }\n this.hiddenInput = (this.createElement('input', { attrs: { type: 'text',\n 'validateHidden': 'true', 'aria-label': 'hidden', 'class': HIDDENELEMENT } }));\n this.inputName = this.inputName !== null ? this.inputName : this.element.id;\n this.element.removeAttribute('name');\n if (this.isAngular && this.angularTagName === 'EJS-NUMERICTEXTBOX' && this.cloneElement.id.length > 0) {\n attributes(this.hiddenInput, { 'name': this.cloneElement.id });\n }\n else {\n attributes(this.hiddenInput, { 'name': this.inputName });\n }\n this.container.insertBefore(this.hiddenInput, this.container.childNodes[1]);\n this.updateDataAttribute(false);\n if (this.inputStyle !== null) {\n attributes(this.container, { 'style': this.inputStyle });\n }\n };\n NumericTextBox.prototype.updateDataAttribute = function (isDynamic) {\n var attr = {};\n if (!isDynamic) {\n for (var a = 0; a < this.element.attributes.length; a++) {\n attr[this.element.attributes[a].name] = this.element.getAttribute(this.element.attributes[a].name);\n }\n }\n else {\n attr = this.htmlAttributes;\n }\n for (var _i = 0, _a = Object.keys(attr); _i < _a.length; _i++) {\n var key = _a[_i];\n if (key.indexOf('data') === 0) {\n this.hiddenInput.setAttribute(key, attr[\"\" + key]);\n }\n }\n };\n NumericTextBox.prototype.updateHTMLAttrToElement = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var pro = _a[_i];\n if (wrapperAttributes.indexOf(pro) < 0) {\n this.element.setAttribute(pro, this.htmlAttributes[\"\" + pro]);\n }\n }\n }\n };\n NumericTextBox.prototype.updateCssClass = function (newClass, oldClass) {\n Input.setCssClass(this.getNumericValidClassList(newClass), [this.container], this.getNumericValidClassList(oldClass));\n };\n NumericTextBox.prototype.getNumericValidClassList = function (numericClassName) {\n var result = numericClassName;\n if (!isNullOrUndefined(numericClassName) && numericClassName !== '') {\n result = (numericClassName.replace(/\\s+/g, ' ')).trim();\n }\n return result;\n };\n NumericTextBox.prototype.updateHTMLAttrToWrapper = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var pro = _a[_i];\n if (wrapperAttributes.indexOf(pro) > -1) {\n if (pro === 'class') {\n var updatedClassValue = this.getNumericValidClassList(this.htmlAttributes[\"\" + pro]);\n if (updatedClassValue !== '') {\n addClass([this.container], updatedClassValue.split(' '));\n }\n }\n else if (pro === 'style') {\n var numericStyle = this.container.getAttribute(pro);\n numericStyle = !isNullOrUndefined(numericStyle) ? (numericStyle + this.htmlAttributes[\"\" + pro]) :\n this.htmlAttributes[\"\" + pro];\n this.container.setAttribute(pro, numericStyle);\n }\n else {\n this.container.setAttribute(pro, this.htmlAttributes[\"\" + pro]);\n }\n }\n }\n }\n };\n NumericTextBox.prototype.setElementWidth = function (width) {\n if (!isNullOrUndefined(width)) {\n if (typeof width === 'number') {\n this.container.style.width = formatUnit(width);\n }\n else if (typeof width === 'string') {\n this.container.style.width = (width.match(/px|%|em/)) ? (width) : (formatUnit(width));\n }\n }\n };\n /* Spinner creation */\n NumericTextBox.prototype.spinBtnCreation = function () {\n this.spinDown = Input.appendSpan(SPINICON + ' ' + SPINDOWN, this.container, this.createElement);\n attributes(this.spinDown, {\n 'title': this.l10n.getConstant('decrementTitle')\n });\n this.spinUp = Input.appendSpan(SPINICON + ' ' + SPINUP, this.container, this.createElement);\n attributes(this.spinUp, {\n 'title': this.l10n.getConstant('incrementTitle')\n });\n this.wireSpinBtnEvents();\n };\n NumericTextBox.prototype.validateMinMax = function () {\n if (!(typeof (this.min) === 'number' && !isNaN(this.min))) {\n this.setProperties({ min: -(Number.MAX_VALUE) }, true);\n }\n if (!(typeof (this.max) === 'number' && !isNaN(this.max))) {\n this.setProperties({ max: Number.MAX_VALUE }, true);\n }\n if (this.decimals !== null) {\n if (this.min !== -(Number.MAX_VALUE)) {\n this.setProperties({ min: this.instance.getNumberParser({ format: 'n' })(this.formattedValue(this.decimals, this.min)) }, true);\n }\n if (this.max !== (Number.MAX_VALUE)) {\n this.setProperties({ max: this.instance.getNumberParser({ format: 'n' })(this.formattedValue(this.decimals, this.max)) }, true);\n }\n }\n this.setProperties({ min: this.min > this.max ? this.max : this.min }, true);\n if (this.min !== -(Number.MAX_VALUE)) {\n attributes(this.element, { 'aria-valuemin': this.min.toString() });\n }\n if (this.max !== (Number.MAX_VALUE)) {\n attributes(this.element, { 'aria-valuemax': this.max.toString() });\n }\n };\n NumericTextBox.prototype.formattedValue = function (decimals, value) {\n return this.instance.getNumberFormat({\n maximumFractionDigits: decimals,\n minimumFractionDigits: decimals, useGrouping: false\n })(value);\n };\n NumericTextBox.prototype.validateStep = function () {\n if (this.decimals !== null) {\n this.setProperties({ step: this.instance.getNumberParser({ format: 'n' })(this.formattedValue(this.decimals, this.step)) }, true);\n }\n };\n NumericTextBox.prototype.action = function (operation, event) {\n this.isInteract = true;\n var value = this.isFocused ? this.instance.getNumberParser({ format: 'n' })(this.element.value) : this.value;\n this.changeValue(this.performAction(value, this.step, operation));\n this.raiseChangeEvent(event);\n };\n NumericTextBox.prototype.checkErrorClass = function () {\n if (this.isValidState) {\n removeClass([this.container], ERROR);\n }\n else {\n addClass([this.container], ERROR);\n }\n attributes(this.element, { 'aria-invalid': this.isValidState ? 'false' : 'true' });\n };\n NumericTextBox.prototype.bindClearEvent = function () {\n if (this.showClearButton) {\n EventHandler.add(this.inputWrapper.clearButton, 'mousedown touchstart', this.resetHandler, this);\n }\n };\n NumericTextBox.prototype.resetHandler = function (e) {\n e.preventDefault();\n if (!(this.inputWrapper.clearButton.classList.contains('e-clear-icon-hide')) || this.inputWrapper.container.classList.contains('e-static-clear')) {\n this.clear(e);\n }\n this.isInteract = true;\n this.raiseChangeEvent(e);\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n NumericTextBox.prototype.clear = function (event) {\n this.setProperties({ value: null }, true);\n this.setElementValue('');\n this.hiddenInput.value = '';\n var formElement = closest(this.element, 'form');\n if (formElement) {\n var element = this.element.nextElementSibling;\n var keyupEvent = document.createEvent('KeyboardEvent');\n keyupEvent.initEvent('keyup', false, true);\n element.dispatchEvent(keyupEvent);\n }\n };\n NumericTextBox.prototype.resetFormHandler = function () {\n if (this.element.tagName === 'EJS-NUMERICTEXTBOX') {\n this.updateValue(null);\n }\n else {\n this.updateValue(this.inputEleValue);\n }\n };\n NumericTextBox.prototype.setSpinButton = function () {\n if (!isNullOrUndefined(this.spinDown)) {\n attributes(this.spinDown, {\n 'title': this.l10n.getConstant('decrementTitle'),\n 'aria-label': this.l10n.getConstant('decrementTitle')\n });\n }\n if (!isNullOrUndefined(this.spinUp)) {\n attributes(this.spinUp, {\n 'title': this.l10n.getConstant('incrementTitle'),\n 'aria-label': this.l10n.getConstant('incrementTitle')\n });\n }\n };\n NumericTextBox.prototype.wireEvents = function () {\n EventHandler.add(this.element, 'focus', this.focusHandler, this);\n EventHandler.add(this.element, 'blur', this.focusOutHandler, this);\n EventHandler.add(this.element, 'keydown', this.keyDownHandler, this);\n EventHandler.add(this.element, 'keyup', this.keyUpHandler, this);\n EventHandler.add(this.element, 'input', this.inputHandler, this);\n EventHandler.add(this.element, 'keypress', this.keyPressHandler, this);\n EventHandler.add(this.element, 'change', this.changeHandler, this);\n EventHandler.add(this.element, 'paste', this.pasteHandler, this);\n if (this.enabled) {\n this.bindClearEvent();\n if (this.formEle) {\n EventHandler.add(this.formEle, 'reset', this.resetFormHandler, this);\n }\n }\n };\n NumericTextBox.prototype.wireSpinBtnEvents = function () {\n /* bind spin button events */\n EventHandler.add(this.spinUp, Browser.touchStartEvent, this.mouseDownOnSpinner, this);\n EventHandler.add(this.spinDown, Browser.touchStartEvent, this.mouseDownOnSpinner, this);\n EventHandler.add(this.spinUp, Browser.touchEndEvent, this.mouseUpOnSpinner, this);\n EventHandler.add(this.spinDown, Browser.touchEndEvent, this.mouseUpOnSpinner, this);\n EventHandler.add(this.spinUp, Browser.touchMoveEvent, this.touchMoveOnSpinner, this);\n EventHandler.add(this.spinDown, Browser.touchMoveEvent, this.touchMoveOnSpinner, this);\n };\n NumericTextBox.prototype.unwireEvents = function () {\n EventHandler.remove(this.element, 'focus', this.focusHandler);\n EventHandler.remove(this.element, 'blur', this.focusOutHandler);\n EventHandler.remove(this.element, 'keyup', this.keyUpHandler);\n EventHandler.remove(this.element, 'input', this.inputHandler);\n EventHandler.remove(this.element, 'keydown', this.keyDownHandler);\n EventHandler.remove(this.element, 'keypress', this.keyPressHandler);\n EventHandler.remove(this.element, 'change', this.changeHandler);\n EventHandler.remove(this.element, 'paste', this.pasteHandler);\n if (this.formEle) {\n EventHandler.remove(this.formEle, 'reset', this.resetFormHandler);\n }\n };\n NumericTextBox.prototype.unwireSpinBtnEvents = function () {\n /* unbind spin button events */\n EventHandler.remove(this.spinUp, Browser.touchStartEvent, this.mouseDownOnSpinner);\n EventHandler.remove(this.spinDown, Browser.touchStartEvent, this.mouseDownOnSpinner);\n EventHandler.remove(this.spinUp, Browser.touchEndEvent, this.mouseUpOnSpinner);\n EventHandler.remove(this.spinDown, Browser.touchEndEvent, this.mouseUpOnSpinner);\n EventHandler.remove(this.spinUp, Browser.touchMoveEvent, this.touchMoveOnSpinner);\n EventHandler.remove(this.spinDown, Browser.touchMoveEvent, this.touchMoveOnSpinner);\n };\n NumericTextBox.prototype.changeHandler = function (event) {\n event.stopPropagation();\n if (!this.element.value.length) {\n this.setProperties({ value: null }, true);\n }\n var parsedInput = this.instance.getNumberParser({ format: 'n' })(this.element.value);\n this.updateValue(parsedInput, event);\n };\n NumericTextBox.prototype.raiseChangeEvent = function (event) {\n this.inputValue = (isNullOrUndefined(this.inputValue) || isNaN(this.inputValue)) ? null : this.inputValue;\n if (this.prevValue !== this.value || this.prevValue !== this.inputValue) {\n var eventArgs = {};\n this.changeEventArgs = { value: this.value, previousValue: this.prevValue, isInteracted: this.isInteract,\n isInteraction: this.isInteract, event: event };\n if (event) {\n this.changeEventArgs.event = event;\n }\n if (this.changeEventArgs.event === undefined) {\n this.changeEventArgs.isInteracted = false;\n this.changeEventArgs.isInteraction = false;\n }\n merge(eventArgs, this.changeEventArgs);\n this.prevValue = this.value;\n this.isInteract = false;\n this.elementPrevValue = this.element.value;\n this.preventChange = false;\n this.trigger('change', eventArgs);\n }\n };\n NumericTextBox.prototype.pasteHandler = function () {\n var _this = this;\n if (!this.enabled || this.readonly) {\n return;\n }\n var beforeUpdate = this.element.value;\n setTimeout(function () {\n if (!_this.numericRegex().test(_this.element.value)) {\n _this.setElementValue(beforeUpdate);\n }\n });\n };\n NumericTextBox.prototype.preventHandler = function () {\n var _this = this;\n var iOS = !!navigator.platform && /iPad|iPhone|iPod/.test(navigator.platform);\n setTimeout(function () {\n if (_this.element.selectionStart > 0) {\n var currentPos = _this.element.selectionStart;\n var prevPos = _this.element.selectionStart - 1;\n var start = 0;\n var valArray = _this.element.value.split('');\n var numericObject = getNumericObject(_this.locale);\n var decimalSeparator = getValue('decimal', numericObject);\n var ignoreKeyCode = decimalSeparator.charCodeAt(0);\n if (_this.element.value[prevPos] === ' ' && _this.element.selectionStart > 0 && !iOS) {\n if (isNullOrUndefined(_this.prevVal)) {\n _this.element.value = _this.element.value.trim();\n }\n else if (prevPos !== 0) {\n _this.element.value = _this.prevVal;\n }\n else if (prevPos === 0) {\n _this.element.value = _this.element.value.trim();\n }\n _this.element.setSelectionRange(prevPos, prevPos);\n }\n else if (isNaN(parseFloat(_this.element.value[_this.element.selectionStart - 1])) &&\n _this.element.value[_this.element.selectionStart - 1].charCodeAt(0) !== 45) {\n if ((valArray.indexOf(_this.element.value[_this.element.selectionStart - 1]) !==\n valArray.lastIndexOf(_this.element.value[_this.element.selectionStart - 1]) &&\n _this.element.value[_this.element.selectionStart - 1].charCodeAt(0) === ignoreKeyCode) ||\n _this.element.value[_this.element.selectionStart - 1].charCodeAt(0) !== ignoreKeyCode) {\n _this.element.value = _this.element.value.substring(0, prevPos) +\n _this.element.value.substring(currentPos, _this.element.value.length);\n _this.element.setSelectionRange(prevPos, prevPos);\n if (isNaN(parseFloat(_this.element.value[_this.element.selectionStart - 1])) && _this.element.selectionStart > 0\n && _this.element.value.length) {\n _this.preventHandler();\n }\n }\n }\n else if (isNaN(parseFloat(_this.element.value[_this.element.selectionStart - 2])) && _this.element.selectionStart > 1 &&\n _this.element.value[_this.element.selectionStart - 2].charCodeAt(0) !== 45) {\n if ((valArray.indexOf(_this.element.value[_this.element.selectionStart - 2]) !==\n valArray.lastIndexOf(_this.element.value[_this.element.selectionStart - 2]) &&\n _this.element.value[_this.element.selectionStart - 2].charCodeAt(0) === ignoreKeyCode) ||\n _this.element.value[_this.element.selectionStart - 2].charCodeAt(0) !== ignoreKeyCode) {\n _this.element.setSelectionRange(prevPos, prevPos);\n _this.nextEle = _this.element.value[_this.element.selectionStart];\n _this.cursorPosChanged = true;\n _this.preventHandler();\n }\n }\n if (_this.cursorPosChanged === true && _this.element.value[_this.element.selectionStart] === _this.nextEle &&\n isNaN(parseFloat(_this.element.value[_this.element.selectionStart - 1]))) {\n _this.element.setSelectionRange(_this.element.selectionStart + 1, _this.element.selectionStart + 1);\n _this.cursorPosChanged = false;\n _this.nextEle = null;\n }\n if (_this.element.value.trim() === '') {\n _this.element.setSelectionRange(start, start);\n }\n if (_this.element.selectionStart > 0) {\n if ((_this.element.value[_this.element.selectionStart - 1].charCodeAt(0) === 45) && _this.element.selectionStart > 1) {\n if (isNullOrUndefined(_this.prevVal)) {\n // eslint-disable-next-line no-self-assign\n _this.element.value = _this.element.value;\n }\n else {\n _this.element.value = _this.prevVal;\n }\n _this.element.setSelectionRange(_this.element.selectionStart, _this.element.selectionStart);\n }\n if (_this.element.value[_this.element.selectionStart - 1] === decimalSeparator && _this.decimals === 0 && _this.validateDecimalOnType) {\n _this.element.value = _this.element.value.substring(0, prevPos) +\n _this.element.value.substring(currentPos, _this.element.value.length);\n }\n }\n _this.prevVal = _this.element.value;\n }\n });\n };\n NumericTextBox.prototype.keyUpHandler = function () {\n if (!this.enabled || this.readonly) {\n return;\n }\n var iOS = !!navigator.platform && /iPad|iPhone|iPod/.test(navigator.platform);\n if (!iOS && Browser.isDevice) {\n this.preventHandler();\n }\n var parseValue = this.instance.getNumberParser({ format: 'n' })(this.element.value);\n parseValue = parseValue === null || isNaN(parseValue) ? null : parseValue;\n this.hiddenInput.value = parseValue || parseValue === 0 ? parseValue.toString() : null;\n var formElement = closest(this.element, 'form');\n if (formElement) {\n var element = this.element.nextElementSibling;\n var keyupEvent = document.createEvent('KeyboardEvent');\n keyupEvent.initEvent('keyup', false, true);\n element.dispatchEvent(keyupEvent);\n }\n };\n NumericTextBox.prototype.inputHandler = function (event) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-this-alias\n var numerictextboxObj = this;\n if (!this.enabled || this.readonly) {\n return;\n }\n var iOS = !!navigator.platform && /iPad|iPhone|iPod/.test(navigator.platform);\n var fireFox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;\n if ((fireFox || iOS) && Browser.isDevice) {\n this.preventHandler();\n }\n /* istanbul ignore next */\n if (this.isAngular\n && this.element.value !== getValue('decimal', getNumericObject(this.locale))\n && this.element.value !== getValue('minusSign', getNumericObject(this.locale))) {\n var parsedValue = this.instance.getNumberParser({ format: 'n' })(this.element.value);\n parsedValue = isNaN(parsedValue) ? null : parsedValue;\n numerictextboxObj.localChange({ value: parsedValue });\n this.preventChange = true;\n }\n if (this.isVue) {\n var current = this.instance.getNumberParser({ format: 'n' })(this.element.value);\n var previous = this.instance.getNumberParser({ format: 'n' })(this.elementPrevValue);\n //EJ2-54963-if type \".\" or \".0\" or \"-.0\" it converts to \"0\" automatically when binding v-model\n var nonZeroRegex = new RegExp('[^0-9]+$');\n if (nonZeroRegex.test(this.element.value) || ((this.elementPrevValue.indexOf('.') !== -1 || this.elementPrevValue.indexOf('-') !== -1) && this.element.value[this.element.value.length - 1] === '0')) {\n current = this.value;\n }\n var eventArgs = {\n event: event,\n value: (current === null || isNaN(current) ? null : current),\n previousValue: (previous === null || isNaN(previous) ? null : previous)\n };\n this.preventChange = true;\n this.elementPrevValue = this.element.value;\n this.trigger('input', eventArgs);\n }\n };\n NumericTextBox.prototype.keyDownHandler = function (event) {\n if (!this.readonly) {\n switch (event.keyCode) {\n case 38:\n event.preventDefault();\n this.action(INCREMENT, event);\n break;\n case 40:\n event.preventDefault();\n this.action(DECREMENT, event);\n break;\n default: break;\n }\n }\n };\n NumericTextBox.prototype.performAction = function (value, step, operation) {\n if (value === null || isNaN(value)) {\n value = 0;\n }\n var updatedValue = operation === INCREMENT ? value + step : value - step;\n updatedValue = this.correctRounding(value, step, updatedValue);\n return this.strictMode ? this.trimValue(updatedValue) : updatedValue;\n };\n NumericTextBox.prototype.correctRounding = function (value, step, result) {\n var floatExp = new RegExp('[,.](.*)');\n var floatValue = floatExp.test(value.toString());\n var floatStep = floatExp.test(step.toString());\n if (floatValue || floatStep) {\n var valueCount = floatValue ? floatExp.exec(value.toString())[0].length : 0;\n var stepCount = floatStep ? floatExp.exec(step.toString())[0].length : 0;\n var max = Math.max(valueCount, stepCount);\n return value = this.roundValue(result, max);\n }\n return result;\n };\n NumericTextBox.prototype.roundValue = function (result, precision) {\n precision = precision || 0;\n var divide = Math.pow(10, precision);\n return result *= divide, result = Math.round(result) / divide;\n };\n NumericTextBox.prototype.updateValue = function (value, event) {\n if (event) {\n this.isInteract = true;\n }\n if (value !== null && !isNaN(value)) {\n if (this.decimals) {\n value = this.roundNumber(value, this.decimals);\n }\n }\n this.inputValue = value;\n this.changeValue(value === null || isNaN(value) ? null : this.strictMode ? this.trimValue(value) : value);\n /* istanbul ignore next */\n if (!this.isDynamicChange) {\n this.raiseChangeEvent(event);\n }\n };\n NumericTextBox.prototype.updateCurrency = function (prop, propVal) {\n setValue(prop, propVal, this.cultureInfo);\n this.updateValue(this.value);\n };\n NumericTextBox.prototype.changeValue = function (value) {\n if (!(value || value === 0)) {\n value = null;\n this.setProperties({ value: value }, true);\n }\n else {\n var numberOfDecimals = this.getNumberOfDecimals(value);\n this.setProperties({ value: this.roundNumber(value, numberOfDecimals) }, true);\n }\n this.modifyText();\n if (!this.strictMode) {\n this.validateState();\n }\n };\n NumericTextBox.prototype.modifyText = function () {\n if (this.value || this.value === 0) {\n var value = this.formatNumber();\n var elementValue = this.isFocused ? value : this.instance.getNumberFormat(this.cultureInfo)(this.value);\n this.setElementValue(elementValue);\n attributes(this.element, { 'aria-valuenow': value });\n this.hiddenInput.value = this.value.toString();\n if (this.value !== null && this.serverDecimalSeparator) {\n this.hiddenInput.value = this.hiddenInput.value.replace('.', this.serverDecimalSeparator);\n }\n }\n else {\n this.setElementValue('');\n this.element.removeAttribute('aria-valuenow');\n this.hiddenInput.value = null;\n }\n };\n NumericTextBox.prototype.setElementValue = function (val, element) {\n Input.setValue(val, (element ? element : this.element), this.floatLabelType, this.showClearButton);\n };\n NumericTextBox.prototype.validateState = function () {\n this.isValidState = true;\n if (this.value || this.value === 0) {\n this.isValidState = !(this.value > this.max || this.value < this.min);\n }\n this.checkErrorClass();\n };\n NumericTextBox.prototype.getNumberOfDecimals = function (value) {\n var numberOfDecimals;\n // eslint-disable-next-line no-useless-escape\n var EXPREGEXP = new RegExp('[eE][\\-+]?([0-9]+)');\n var valueString = value.toString();\n if (EXPREGEXP.test(valueString)) {\n var result = EXPREGEXP.exec(valueString);\n if (!isNullOrUndefined(result)) {\n valueString = value.toFixed(Math.min(parseInt(result[1], 10), 20));\n }\n }\n var decimalPart = valueString.split('.')[1];\n numberOfDecimals = !decimalPart || !decimalPart.length ? 0 : decimalPart.length;\n if (this.decimals !== null) {\n numberOfDecimals = numberOfDecimals < this.decimals ? numberOfDecimals : this.decimals;\n }\n return numberOfDecimals;\n };\n NumericTextBox.prototype.formatNumber = function () {\n var numberOfDecimals = this.getNumberOfDecimals(this.value);\n return this.instance.getNumberFormat({\n maximumFractionDigits: numberOfDecimals,\n minimumFractionDigits: numberOfDecimals, useGrouping: false\n })(this.value);\n };\n NumericTextBox.prototype.trimValue = function (value) {\n if (value > this.max) {\n return this.max;\n }\n if (value < this.min) {\n return this.min;\n }\n return value;\n };\n NumericTextBox.prototype.roundNumber = function (value, precision) {\n var result = value;\n var decimals = precision || 0;\n var result1 = result.toString().split('e');\n result = Math.round(Number(result1[0] + 'e' + (result1[1] ? (Number(result1[1]) + decimals) : decimals)));\n var result2 = result.toString().split('e');\n result = Number(result2[0] + 'e' + (result2[1] ? (Number(result2[1]) - decimals) : -decimals));\n return Number(result.toFixed(decimals));\n };\n NumericTextBox.prototype.cancelEvent = function (event) {\n event.preventDefault();\n return false;\n };\n NumericTextBox.prototype.keyPressHandler = function (event) {\n if (!this.enabled || this.readonly) {\n return true;\n }\n if (!Browser.isDevice && Browser.info.version === '11.0' && event.keyCode === 13) {\n var parsedInput = this.instance.getNumberParser({ format: 'n' })(this.element.value);\n this.updateValue(parsedInput, event);\n return true;\n }\n if (event.which === 0 || event.metaKey || event.ctrlKey || event.keyCode === 8 || event.keyCode === 13) {\n return true;\n }\n var currentChar = String.fromCharCode(event.which);\n var decimalSeparator = getValue('decimal', getNumericObject(this.locale));\n var isAlterNumPadDecimalChar = event.code === 'NumpadDecimal' && currentChar !== decimalSeparator;\n //EJ2-59813-replace the culture decimal separator value with numberpad decimal separator value when culture decimal separator and numberpad decimal separator are different\n if (isAlterNumPadDecimalChar) {\n currentChar = decimalSeparator;\n }\n var text = this.element.value;\n text = text.substring(0, this.element.selectionStart) + currentChar + text.substring(this.element.selectionEnd);\n if (!this.numericRegex().test(text)) {\n event.preventDefault();\n event.stopPropagation();\n return false;\n }\n else {\n //EJ2-59813-update the numberpad decimal separator and update the cursor position\n if (isAlterNumPadDecimalChar) {\n var start = this.element.selectionStart + 1;\n this.element.value = text;\n this.element.setSelectionRange(start, start);\n event.preventDefault();\n event.stopPropagation();\n }\n return true;\n }\n };\n NumericTextBox.prototype.numericRegex = function () {\n var numericObject = getNumericObject(this.locale);\n var decimalSeparator = getValue('decimal', numericObject);\n var fractionRule = '*';\n if (decimalSeparator === DECIMALSEPARATOR) {\n decimalSeparator = '\\\\' + decimalSeparator;\n }\n if (this.decimals === 0 && this.validateDecimalOnType) {\n return INTREGEXP;\n }\n if (this.decimals && this.validateDecimalOnType) {\n fractionRule = '{0,' + this.decimals + '}';\n }\n /* eslint-disable-next-line security/detect-non-literal-regexp */\n return new RegExp('^(-)?(((\\\\d+(' + decimalSeparator + '\\\\d' + fractionRule +\n ')?)|(' + decimalSeparator + '\\\\d' + fractionRule + ')))?$');\n };\n NumericTextBox.prototype.mouseWheel = function (event) {\n event.preventDefault();\n var delta;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var rawEvent = event;\n if (rawEvent.wheelDelta) {\n delta = rawEvent.wheelDelta / 120;\n }\n else if (rawEvent.detail) {\n delta = -rawEvent.detail / 3;\n }\n if (delta > 0) {\n this.action(INCREMENT, event);\n }\n else if (delta < 0) {\n this.action(DECREMENT, event);\n }\n this.cancelEvent(event);\n };\n NumericTextBox.prototype.focusHandler = function (event) {\n var _this = this;\n clearTimeout(selectionTimeOut);\n this.focusEventArgs = { event: event, value: this.value, container: this.container };\n this.trigger('focus', this.focusEventArgs);\n if (!this.enabled || this.readonly) {\n return;\n }\n this.isFocused = true;\n removeClass([this.container], ERROR);\n this.prevValue = this.value;\n if ((this.value || this.value === 0)) {\n var formatValue_1 = this.formatNumber();\n this.setElementValue(formatValue_1);\n if (!this.isPrevFocused) {\n if (!Browser.isDevice && Browser.info.version === '11.0') {\n this.element.setSelectionRange(0, formatValue_1.length);\n }\n else {\n var delay = (Browser.isDevice && Browser.isIos) ? 600 : 0;\n selectionTimeOut = setTimeout(function () {\n _this.element.setSelectionRange(0, formatValue_1.length);\n }, delay);\n }\n }\n }\n if (!Browser.isDevice) {\n EventHandler.add(this.element, 'mousewheel DOMMouseScroll', this.mouseWheel, this);\n }\n };\n NumericTextBox.prototype.focusOutHandler = function (event) {\n var _this = this;\n this.blurEventArgs = { event: event, value: this.value, container: this.container };\n this.trigger('blur', this.blurEventArgs);\n if (!this.enabled || this.readonly) {\n return;\n }\n if (this.isPrevFocused) {\n event.preventDefault();\n if (Browser.isDevice) {\n var value_1 = this.element.value;\n this.element.focus();\n this.isPrevFocused = false;\n var ele_1 = this.element;\n setTimeout(function () {\n _this.setElementValue(value_1, ele_1);\n }, 200);\n }\n }\n else {\n this.isFocused = false;\n if (!this.element.value.length) {\n this.setProperties({ value: null }, true);\n }\n var parsedInput = this.instance.getNumberParser({ format: 'n' })(this.element.value);\n this.updateValue(parsedInput);\n if (!Browser.isDevice) {\n EventHandler.remove(this.element, 'mousewheel DOMMouseScroll', this.mouseWheel);\n }\n }\n var formElement = closest(this.element, 'form');\n if (formElement) {\n var element = this.element.nextElementSibling;\n var focusEvent = document.createEvent('FocusEvent');\n focusEvent.initEvent('focusout', false, true);\n element.dispatchEvent(focusEvent);\n }\n };\n NumericTextBox.prototype.mouseDownOnSpinner = function (event) {\n var _this = this;\n if (this.isFocused) {\n this.isPrevFocused = true;\n event.preventDefault();\n }\n if (!this.getElementData(event)) {\n return;\n }\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n var result = this.getElementData(event);\n var target = event.currentTarget;\n var action = (target.classList.contains(SPINUP)) ? INCREMENT : DECREMENT;\n EventHandler.add(target, 'mouseleave', this.mouseUpClick, this);\n this.timeOut = setInterval(function () {\n _this.isCalled = true;\n _this.action(action, event);\n }, 150);\n EventHandler.add(document, 'mouseup', this.mouseUpClick, this);\n };\n NumericTextBox.prototype.touchMoveOnSpinner = function (event) {\n var target;\n if (event.type === 'touchmove') {\n var touchEvent = event.touches;\n target = touchEvent.length && document.elementFromPoint(touchEvent[0].pageX, touchEvent[0].pageY);\n }\n else {\n target = document.elementFromPoint(event.clientX, event.clientY);\n }\n if (!(target.classList.contains(SPINICON))) {\n clearInterval(this.timeOut);\n }\n };\n NumericTextBox.prototype.mouseUpOnSpinner = function (event) {\n this.prevValue = this.value;\n if (this.isPrevFocused) {\n this.element.focus();\n if (!Browser.isDevice) {\n this.isPrevFocused = false;\n }\n }\n if (!Browser.isDevice) {\n event.preventDefault();\n }\n if (!this.getElementData(event)) {\n return;\n }\n var target = event.currentTarget;\n var action = (target.classList.contains(SPINUP)) ? INCREMENT : DECREMENT;\n EventHandler.remove(target, 'mouseleave', this.mouseUpClick);\n if (!this.isCalled) {\n this.action(action, event);\n }\n this.isCalled = false;\n EventHandler.remove(document, 'mouseup', this.mouseUpClick);\n var formElement = closest(this.element, 'form');\n if (formElement) {\n var element = this.element.nextElementSibling;\n var keyupEvent = document.createEvent('KeyboardEvent');\n keyupEvent.initEvent('keyup', false, true);\n element.dispatchEvent(keyupEvent);\n }\n };\n NumericTextBox.prototype.getElementData = function (event) {\n if ((event.which && event.which === 3) || (event.button && event.button === 2)\n || !this.enabled || this.readonly) {\n return false;\n }\n clearInterval(this.timeOut);\n return true;\n };\n NumericTextBox.prototype.floatLabelTypeUpdate = function () {\n Input.removeFloating(this.inputWrapper);\n var hiddenInput = this.hiddenInput;\n this.hiddenInput.remove();\n Input.addFloating(this.element, this.floatLabelType, this.placeholder, this.createElement);\n this.container.insertBefore(hiddenInput, this.container.childNodes[1]);\n };\n NumericTextBox.prototype.mouseUpClick = function (event) {\n event.stopPropagation();\n clearInterval(this.timeOut);\n this.isCalled = false;\n if (this.spinUp) {\n EventHandler.remove(this.spinUp, 'mouseleave', this.mouseUpClick);\n }\n if (this.spinDown) {\n EventHandler.remove(this.spinDown, 'mouseleave', this.mouseUpClick);\n }\n };\n /**\n * Increments the NumericTextBox value with the specified step value.\n *\n * @param {number} step - Specifies the value used to increment the NumericTextBox value.\n * if its not given then numeric value will be incremented based on the step property value.\n * @returns {void}\n */\n NumericTextBox.prototype.increment = function (step) {\n if (step === void 0) { step = this.step; }\n this.isInteract = false;\n this.changeValue(this.performAction(this.value, step, INCREMENT));\n this.raiseChangeEvent();\n };\n /**\n * Decrements the NumericTextBox value with specified step value.\n *\n * @param {number} step - Specifies the value used to decrement the NumericTextBox value.\n * if its not given then numeric value will be decremented based on the step property value.\n * @returns {void}\n */\n NumericTextBox.prototype.decrement = function (step) {\n if (step === void 0) { step = this.step; }\n this.isInteract = false;\n this.changeValue(this.performAction(this.value, step, DECREMENT));\n this.raiseChangeEvent();\n };\n /**\n * Removes the component from the DOM and detaches all its related event handlers.\n * Also it maintains the initial input element from the DOM.\n *\n * @method destroy\n * @returns {void}\n */\n NumericTextBox.prototype.destroy = function () {\n this.unwireEvents();\n detach(this.hiddenInput);\n if (this.showSpinButton) {\n this.unwireSpinBtnEvents();\n detach(this.spinUp);\n detach(this.spinDown);\n }\n var attrArray = ['aria-labelledby', 'role', 'autocomplete', 'aria-readonly',\n 'aria-disabled', 'autocapitalize', 'spellcheck', 'aria-autocomplete', 'tabindex',\n 'aria-valuemin', 'aria-valuemax', 'aria-valuenow', 'aria-invalid'];\n for (var i = 0; i < attrArray.length; i++) {\n this.element.removeAttribute(attrArray[i]);\n }\n this.element.classList.remove('e-input');\n this.container.insertAdjacentElement('afterend', this.element);\n detach(this.container);\n this.spinUp = null;\n this.spinDown = null;\n this.container = null;\n this.hiddenInput = null;\n this.changeEventArgs = null;\n this.blurEventArgs = null;\n this.focusEventArgs = null;\n this.inputWrapper = null;\n Input.destroy();\n _super.prototype.destroy.call(this);\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns */\n /**\n * Returns the value of NumericTextBox with the format applied to the NumericTextBox.\n *\n */\n NumericTextBox.prototype.getText = function () {\n return this.element.value;\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns */\n /**\n * Sets the focus to widget for interaction.\n *\n * @returns {void}\n */\n NumericTextBox.prototype.focusIn = function () {\n if (document.activeElement !== this.element && this.enabled) {\n this.element.focus();\n addClass([this.container], [NUMERIC_FOCUS]);\n }\n };\n /**\n * Remove the focus from widget, if the widget is in focus state.\n *\n * @returns {void}\n */\n NumericTextBox.prototype.focusOut = function () {\n if (document.activeElement === this.element && this.enabled) {\n this.element.blur();\n removeClass([this.container], [NUMERIC_FOCUS]);\n }\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Gets the properties to be maintained in the persisted state.\n *\n * @returns {string}\n */\n NumericTextBox.prototype.getPersistData = function () {\n var keyEntity = ['value'];\n return this.addOnPersist(keyEntity);\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Calls internally if any of the property value is changed.\n *\n * @param {NumericTextBoxModel} newProp - Returns the dynamic property value of the component.\n * @param {NumericTextBoxModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n * @private\n */\n NumericTextBox.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'width':\n this.setElementWidth(newProp.width);\n Input.calculateWidth(this.element, this.container);\n break;\n case 'cssClass':\n this.updateCssClass(newProp.cssClass, oldProp.cssClass);\n break;\n case 'enabled':\n Input.setEnabled(newProp.enabled, this.element);\n this.bindClearEvent();\n break;\n case 'enableRtl':\n Input.setEnableRtl(newProp.enableRtl, [this.container]);\n break;\n case 'readonly':\n Input.setReadonly(newProp.readonly, this.element);\n if (this.readonly) {\n attributes(this.element, { 'aria-readonly': 'true' });\n }\n else {\n this.element.removeAttribute('aria-readonly');\n }\n break;\n case 'htmlAttributes':\n this.updateHTMLAttrToElement();\n this.updateHTMLAttrToWrapper();\n this.updateDataAttribute(true);\n this.checkAttributes(true);\n Input.validateInputType(this.container, this.element);\n break;\n case 'placeholder':\n Input.setPlaceholder(newProp.placeholder, this.element);\n Input.calculateWidth(this.element, this.container);\n break;\n case 'step':\n this.step = newProp.step;\n this.validateStep();\n break;\n case 'showSpinButton':\n this.updateSpinButton(newProp);\n break;\n case 'showClearButton':\n this.updateClearButton(newProp);\n break;\n case 'floatLabelType':\n this.floatLabelType = newProp.floatLabelType;\n this.floatLabelTypeUpdate();\n break;\n case 'value':\n this.isDynamicChange = (this.isAngular || this.isVue) && this.preventChange;\n this.updateValue(newProp.value);\n if (this.isDynamicChange) {\n this.preventChange = false;\n this.isDynamicChange = false;\n }\n break;\n case 'min':\n case 'max':\n setValue(prop, getValue(prop, newProp), this);\n this.validateMinMax();\n this.updateValue(this.value);\n break;\n case 'strictMode':\n this.strictMode = newProp.strictMode;\n this.updateValue(this.value);\n this.validateState();\n break;\n case 'locale':\n this.initCultureFunc();\n this.l10n.setLocale(this.locale);\n this.setSpinButton();\n this.updatePlaceholder();\n Input.setPlaceholder(this.placeholder, this.element);\n this.updateValue(this.value);\n break;\n case 'currency':\n {\n var propVal = getValue(prop, newProp);\n this.setProperties({ currencyCode: propVal }, true);\n this.updateCurrency(prop, propVal);\n }\n break;\n case 'currencyCode':\n {\n var propValue = getValue(prop, newProp);\n this.setProperties({ currency: propValue }, true);\n this.updateCurrency('currency', propValue);\n }\n break;\n case 'format':\n setValue(prop, getValue(prop, newProp), this);\n this.initCultureInfo();\n this.updateValue(this.value);\n break;\n case 'decimals':\n this.decimals = newProp.decimals;\n this.updateValue(this.value);\n }\n }\n };\n NumericTextBox.prototype.updateClearButton = function (newProp) {\n Input.setClearButton(newProp.showClearButton, this.element, this.inputWrapper, undefined, this.createElement);\n this.bindClearEvent();\n };\n NumericTextBox.prototype.updateSpinButton = function (newProp) {\n if (newProp.showSpinButton) {\n this.spinBtnCreation();\n }\n else {\n detach(this.spinUp);\n detach(this.spinDown);\n }\n };\n /**\n * Gets the component name\n *\n * @returns {string} Returns the component name.\n * @private\n */\n NumericTextBox.prototype.getModuleName = function () {\n return 'numerictextbox';\n };\n __decorate([\n Property('')\n ], NumericTextBox.prototype, \"cssClass\", void 0);\n __decorate([\n Property(null)\n ], NumericTextBox.prototype, \"value\", void 0);\n __decorate([\n Property(-(Number.MAX_VALUE))\n ], NumericTextBox.prototype, \"min\", void 0);\n __decorate([\n Property(Number.MAX_VALUE)\n ], NumericTextBox.prototype, \"max\", void 0);\n __decorate([\n Property(1)\n ], NumericTextBox.prototype, \"step\", void 0);\n __decorate([\n Property(null)\n ], NumericTextBox.prototype, \"width\", void 0);\n __decorate([\n Property(null)\n ], NumericTextBox.prototype, \"placeholder\", void 0);\n __decorate([\n Property({})\n ], NumericTextBox.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property(true)\n ], NumericTextBox.prototype, \"showSpinButton\", void 0);\n __decorate([\n Property(false)\n ], NumericTextBox.prototype, \"readonly\", void 0);\n __decorate([\n Property(true)\n ], NumericTextBox.prototype, \"enabled\", void 0);\n __decorate([\n Property(false)\n ], NumericTextBox.prototype, \"showClearButton\", void 0);\n __decorate([\n Property(false)\n ], NumericTextBox.prototype, \"enablePersistence\", void 0);\n __decorate([\n Property('n2')\n ], NumericTextBox.prototype, \"format\", void 0);\n __decorate([\n Property(null)\n ], NumericTextBox.prototype, \"decimals\", void 0);\n __decorate([\n Property(null)\n ], NumericTextBox.prototype, \"currency\", void 0);\n __decorate([\n Property(null)\n ], NumericTextBox.prototype, \"currencyCode\", void 0);\n __decorate([\n Property(true)\n ], NumericTextBox.prototype, \"strictMode\", void 0);\n __decorate([\n Property(false)\n ], NumericTextBox.prototype, \"validateDecimalOnType\", void 0);\n __decorate([\n Property('Never')\n ], NumericTextBox.prototype, \"floatLabelType\", void 0);\n __decorate([\n Event()\n ], NumericTextBox.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], NumericTextBox.prototype, \"destroyed\", void 0);\n __decorate([\n Event()\n ], NumericTextBox.prototype, \"change\", void 0);\n __decorate([\n Event()\n ], NumericTextBox.prototype, \"focus\", void 0);\n __decorate([\n Event()\n ], NumericTextBox.prototype, \"blur\", void 0);\n NumericTextBox = __decorate([\n NotifyPropertyChanges\n ], NumericTextBox);\n return NumericTextBox;\n}(Component));\nexport { NumericTextBox };\n","/* tslint:disable-next-line:max-line-length */\nimport { EventHandler, isNullOrUndefined, extend, classList, addClass, removeClass, Browser, getValue, setValue, createElement } from '@syncfusion/ej2-base';\nimport { parentsUntil, getUid, appendChildren, getDatePredicate, getObject, extendObjWithFn, eventPromise, setChecked, clearReactVueTemplates, padZero, Global } from '../base/util';\nimport { remove, debounce, Internationalization, SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport { DataUtil, Query, DataManager, Predicate } from '@syncfusion/ej2-data';\nimport { createCheckBox } from '@syncfusion/ej2-buttons';\nimport * as events from '../base/constant';\nimport { ValueFormatter } from '../services/value-formatter';\nimport { getForeignData } from '../base/util';\nimport { Dialog } from '@syncfusion/ej2-popups';\nimport { Input } from '@syncfusion/ej2-inputs';\nimport { createSpinner, hideSpinner, showSpinner } from '@syncfusion/ej2-popups';\nimport { getFilterMenuPostion, toogleCheckbox, createCboxWithWrap, removeAddCboxClasses, getColumnByForeignKeyValue } from '../base/util';\n/**\n * @hidden\n * `CheckBoxFilterBase` module is used to handle filtering action.\n */\nvar CheckBoxFilterBase = /** @class */ (function () {\n /**\n * Constructor for checkbox filtering module\n *\n * @param {IXLFilter} parent - specifies the IXLFilter\n * @hidden\n */\n function CheckBoxFilterBase(parent) {\n this.isExecuteLocal = false;\n this.existingPredicate = {};\n this.foreignKeyQuery = new Query();\n /** @hidden */\n this.filterState = true;\n this.values = {};\n this.renderEmpty = false;\n this.isCheckboxFilterTemplate = false;\n this.infiniteRenderMod = false;\n // for infinite scroll ui\n this.infiniteInitialLoad = false;\n this.infiniteSearchValChange = false;\n this.infinitePermenantLocalData = [];\n this.infiniteQueryExecutionPending = false;\n this.infiniteSkipCnt = 0;\n this.infiniteScrollAppendDiff = 0;\n this.prevInfiniteScrollDirection = '';\n this.infiniteLoadedElem = [];\n this.infiniteDataCount = 0;\n this.infiniteLocalSelectAll = true;\n this.localInfiniteSelectAllClicked = false;\n this.localInfiniteSelectionInteracted = false;\n this.infiniteManualSelectMaintainPred = [];\n this.parent = parent;\n this.id = this.parent.element.id;\n this.valueFormatter = new ValueFormatter(this.parent.locale);\n this.cBoxTrue = createCheckBox(this.parent.createElement, false, { checked: true, label: ' ' });\n this.cBoxFalse = createCheckBox(this.parent.createElement, false, { checked: false, label: ' ' });\n this.cBoxTrue.insertBefore(this.parent.createElement('input', {\n className: 'e-chk-hidden', attrs: { type: 'checkbox' }\n }), this.cBoxTrue.firstChild);\n this.cBoxFalse.insertBefore(this.parent.createElement('input', {\n className: 'e-chk-hidden', attrs: { 'type': 'checkbox' }\n }), this.cBoxFalse.firstChild);\n this.cBoxFalse.querySelector('.e-frame').classList.add('e-uncheck');\n if (this.parent.enableRtl) {\n addClass([this.cBoxTrue, this.cBoxFalse], ['e-rtl']);\n }\n if (this.parent.cssClass) {\n if (this.parent.cssClass.indexOf(' ') !== -1) {\n addClass([this.cBoxTrue, this.cBoxFalse], this.parent.cssClass.split(' '));\n }\n else {\n addClass([this.cBoxTrue, this.cBoxFalse], [this.parent.cssClass]);\n }\n }\n }\n /**\n * @returns {void}\n * @hidden\n */\n CheckBoxFilterBase.prototype.destroy = function () {\n this.closeDialog();\n };\n CheckBoxFilterBase.prototype.wireEvents = function () {\n EventHandler.add(this.dlg, 'click', this.clickHandler, this);\n EventHandler.add(this.dlg, 'keyup', this.keyupHandler, this);\n this.searchHandler = debounce(this.searchBoxKeyUp, 200);\n var elem = this.dialogObj.element.querySelector('.e-searchinput');\n if (elem) {\n EventHandler.add(elem, 'keyup', this.searchHandler, this);\n EventHandler.add(elem, 'input', this.searchHandler, this);\n }\n };\n CheckBoxFilterBase.prototype.unWireEvents = function () {\n EventHandler.remove(this.dlg, 'click', this.clickHandler);\n EventHandler.remove(this.dlg, 'keyup', this.keyupHandler);\n var elem = this.dialogObj.element.querySelector('.e-searchinput');\n if (elem) {\n EventHandler.remove(elem, 'keyup', this.searchHandler);\n EventHandler.remove(elem, 'input', this.searchHandler);\n }\n };\n CheckBoxFilterBase.prototype.foreignKeyFilter = function (args, fColl, mPredicate) {\n var _this = this;\n var fPredicate = {};\n var filterCollection = [];\n var query = this.foreignKeyQuery.clone();\n this.options.column.dataSource.\n executeQuery(query.where(mPredicate)).then(function (e) {\n _this.options.column.columnData = e.result;\n _this.parent.notify(events.generateQuery, { predicate: fPredicate, column: _this.options.column });\n args.ejpredicate = fPredicate.predicate.predicates;\n var fpred = fPredicate.predicate.predicates;\n for (var i = 0; i < fpred.length; i++) {\n filterCollection.push({\n field: fpred[parseInt(i.toString(), 10)].field,\n predicate: 'or',\n matchCase: fpred[parseInt(i.toString(), 10)].ignoreCase,\n ignoreAccent: fpred[parseInt(i.toString(), 10)].ignoreAccent,\n operator: fpred[parseInt(i.toString(), 10)].operator,\n value: fpred[parseInt(i.toString(), 10)].value,\n type: _this.options.type\n });\n }\n args.filterCollection = filterCollection.length ? filterCollection :\n fColl.filter(function (col) { return col.field = _this.options.field; });\n _this.options.handler(args);\n });\n };\n CheckBoxFilterBase.prototype.foreignFilter = function (args, value) {\n var operator = this.options.isRemote ?\n (this.options.column.type === 'string' ? 'contains' : 'equal') : (this.options.column.type ? 'contains' : 'equal');\n var initalPredicate = new Predicate(this.options.column.foreignKeyValue, operator, value, true, this.options.ignoreAccent);\n this.foreignKeyFilter(args, [args.filterCollection], initalPredicate);\n };\n CheckBoxFilterBase.prototype.searchBoxClick = function (e) {\n var target = e.target;\n if (target.classList.contains('e-searchclear')) {\n this.sInput.value = target.classList.contains('e-chkcancel-icon') ? '' : this.sInput.value;\n if (this.isCheckboxFilterTemplate) {\n this.parent.notify('refreshCheckbox', { event: e });\n }\n else {\n this.refreshCheckboxes();\n }\n this.updateSearchIcon();\n this.sInput.focus();\n }\n };\n CheckBoxFilterBase.prototype.searchBoxKeyUp = function (e) {\n if (isNullOrUndefined(e) || (e.key !== 'ArrowUp' && e.key !== 'ArrowDown' && e.key !== 'Tab' && !(e.key === 'Tab' && e.shiftKey))) {\n if (!isNullOrUndefined(this.parent.loadingIndicator) && this.parent.loadingIndicator.indicatorType === 'Shimmer') {\n this.parent.showMaskRow(undefined, this.dialogObj.element);\n }\n if (this.isCheckboxFilterTemplate) {\n this.parent.notify('refreshCheckbox', { event: e });\n }\n else {\n this.refreshCheckboxes();\n }\n this.updateSearchIcon();\n }\n };\n CheckBoxFilterBase.prototype.updateSearchIcon = function () {\n if (this.sInput.value.length) {\n classList(this.sIcon, ['e-chkcancel-icon'], ['e-search-icon']);\n if (!isNullOrUndefined(document.body.querySelector('.e-chkcancel-icon'))) {\n document.body.querySelector('.e-chkcancel-icon').setAttribute('title', this.localeObj.getConstant('Clear'));\n }\n }\n else {\n classList(this.sIcon, ['e-search-icon'], ['e-chkcancel-icon']);\n if (!isNullOrUndefined(document.body.querySelector('.e-searchclear.e-search-icon'))) {\n document.body.querySelector('.e-searchclear.e-search-icon').setAttribute('title', this.localeObj.getConstant('Search'));\n }\n }\n };\n /**\n * Gets the localized label by locale keyword.\n *\n * @param {string} key - Defines localization key\n * @returns {string} - returns localization label\n */\n CheckBoxFilterBase.prototype.getLocalizedLabel = function (key) {\n return this.localeObj.getConstant(key);\n };\n CheckBoxFilterBase.prototype.updateDataSource = function () {\n var dataSource = this.options.dataSource;\n var str = 'object';\n if (!(dataSource instanceof DataManager)) {\n for (var i = 0; i < dataSource.length; i++) {\n // eslint-disable-next-line valid-typeof\n if (typeof dataSource !== str) {\n var obj = {};\n obj[this.options.field] = dataSource[parseInt(i.toString(), 10)];\n dataSource[parseInt(i.toString(), 10)] = obj;\n }\n }\n }\n };\n CheckBoxFilterBase.prototype.updateModel = function (options) {\n this.options = options;\n this.existingPredicate = options.actualPredicate || {};\n this.options.dataSource = options.dataSource;\n this.options.dataManager = options.dataManager ? options.dataManager : options.dataSource;\n this.updateDataSource();\n this.options.type = options.type;\n this.options.format = options.format || '';\n this.options.ignoreAccent = options.ignoreAccent || false;\n this.options.filteredColumns = options.filteredColumns || this.parent.filterSettings.columns;\n this.options.query = options.query || new Query();\n this.options.allowCaseSensitive = options.allowCaseSensitive || false;\n this.options.uid = options.column.uid;\n this.options.disableHtmlEncode = options.column.disableHtmlEncode || false;\n this.values = {};\n this.localeObj = options.localeObj;\n this.isFiltered = options.filteredColumns.length;\n this.infiniteRenderMod = this.parent.filterSettings && this.parent.filterSettings.enableInfiniteScrolling ? true : false;\n this.infiniteUnloadParentExistPred = this.infiniteRenderMod && this.existingPredicate[this.options.column.field] ? this.existingPredicate[this.options.column.field].slice() : [];\n };\n CheckBoxFilterBase.prototype.getAndSetChkElem = function (options) {\n this.dlg = this.parent.createElement('div', {\n id: this.id + this.options.type + '_excelDlg',\n attrs: { uid: this.options.column.uid },\n className: 'e-checkboxfilter e-filter-popup'\n });\n this.sBox = this.parent.createElement('div', { className: 'e-searchcontainer' });\n if (!options.hideSearchbox) {\n this.sInput = this.parent.createElement('input', {\n id: this.id + '_SearchBox',\n className: 'e-searchinput'\n });\n this.sIcon = this.parent.createElement('span', {\n className: 'e-searchclear e-search-icon e-icons e-input-group-icon', attrs: {\n type: 'text', title: this.getLocalizedLabel('Search')\n }\n });\n this.searchBox = this.parent.createElement('span', { className: 'e-searchbox e-fields' });\n this.searchBox.appendChild(this.sInput);\n this.sBox.appendChild(this.searchBox);\n var inputargs = {\n element: this.sInput, floatLabelType: 'Never', properties: {\n placeholder: this.getLocalizedLabel('Search'),\n cssClass: this.parent.cssClass\n }\n };\n Input.createInput(inputargs, this.parent.createElement);\n this.searchBox.querySelector('.e-input-group').appendChild(this.sIcon);\n }\n this.spinner = this.parent.createElement('div', { className: 'e-spinner' }); //for spinner\n this.cBox = this.parent.createElement('div', {\n id: this.id + this.options.type + '_CheckBoxList',\n className: 'e-checkboxlist e-fields'\n });\n this.spinner.appendChild(this.cBox);\n this.sBox.appendChild(this.spinner);\n return this.sBox;\n };\n CheckBoxFilterBase.prototype.showDialog = function (options) {\n var args = {\n requestType: events.filterBeforeOpen,\n columnName: this.options.field, columnType: this.options.type, cancel: false\n };\n var filterModel = 'filterModel';\n args[\"\" + filterModel] = this;\n this.parent.notify(events.cBoxFltrBegin, args);\n if (args.cancel) {\n options.cancel = args.cancel;\n return;\n }\n this.dialogObj = new Dialog({\n visible: false, content: this.sBox,\n close: this.closeDialog.bind(this),\n enableRtl: this.parent.enableRtl,\n width: (!isNullOrUndefined(parentsUntil(options.target, 'e-bigger')))\n || this.parent.element.classList.contains('e-device') ? 260 : 255,\n target: this.parent.element, animationSettings: { effect: 'None' },\n buttons: [{\n click: this.btnClick.bind(this),\n buttonModel: {\n content: this.getLocalizedLabel(this.isExcel ? 'OKButton' : 'FilterButton'),\n cssClass: this.parent.cssClass ? 'e-primary' + ' ' + this.parent.cssClass : 'e-primary',\n isPrimary: true\n }\n },\n {\n click: this.btnClick.bind(this),\n buttonModel: { cssClass: this.parent.cssClass ? 'e-flat' + ' ' + this.parent.cssClass : 'e-flat',\n content: this.getLocalizedLabel(this.isExcel ? 'CancelButton' : 'ClearButton') }\n }],\n created: this.dialogCreated.bind(this),\n open: this.dialogOpen.bind(this),\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n var isStringTemplate = 'isStringTemplate';\n this.dialogObj[\"\" + isStringTemplate] = true;\n this.renderResponsiveFilter(options);\n var dialogLabel = this.parent.filterSettings && this.parent.filterSettings.type === 'CheckBox' ?\n this.getLocalizedLabel('CheckBoxFilterDialogARIA') : this.getLocalizedLabel('ExcelFilterDialogARIA');\n this.dlg.setAttribute('aria-label', dialogLabel);\n if (options.isResponsiveFilter) {\n var responsiveCnt = document.querySelector('.e-responsive-dialog > .e-dlg-content > .e-mainfilterdiv');\n responsiveCnt.appendChild(this.dlg);\n }\n else {\n this.parent.element.appendChild(this.dlg);\n }\n this.dialogObj.appendTo(this.dlg);\n this.dialogObj.element.style.maxHeight = options.isResponsiveFilter ? 'none' : this.options.height + 'px';\n this.dialogObj.show();\n var content = this.dialogObj.element.querySelector('.e-dlg-content');\n content.appendChild(this.sBox);\n this.wireEvents();\n if (!isNullOrUndefined(this.parent.loadingIndicator) && this.parent.loadingIndicator.indicatorType === 'Shimmer'\n && !this.infiniteRenderMod) {\n this.parent.showMaskRow(undefined, this.dialogObj.element);\n }\n else if (this.infiniteRenderMod && this.parent.filterSettings && this.parent.filterSettings.loadingIndicator === 'Shimmer') {\n this.showMask();\n }\n else {\n if (this.infiniteRenderMod) {\n this.cBox.style.marginTop = this.getListHeight(this.cBox) + 'px';\n }\n createSpinner({ target: this.spinner, cssClass: this.parent.cssClass ? this.parent.cssClass : null }, this.parent.createElement);\n showSpinner(this.spinner);\n }\n this.getAllData();\n };\n CheckBoxFilterBase.prototype.renderResponsiveFilter = function (options) {\n if (options.isResponsiveFilter) {\n this.dialogObj.buttons = [{}];\n this.dialogObj.position = { X: '', Y: '' };\n this.dialogObj.target = document.querySelector('.e-resfilter > .e-dlg-content > .e-mainfilterdiv');\n this.dialogObj.width = '100%';\n }\n };\n CheckBoxFilterBase.prototype.dialogCreated = function (e) {\n if (this.options.isResponsiveFilter) {\n this.dialogObj.element.style.left = '0px';\n }\n else {\n if (!Browser.isDevice) {\n getFilterMenuPostion(this.options.target, this.dialogObj);\n }\n else {\n this.dialogObj.position = { X: 'center', Y: 'center' };\n }\n }\n if (this.options.column.showColumnMenu) {\n this.parent.notify(events.filterDialogCreated, e);\n }\n };\n CheckBoxFilterBase.prototype.openDialog = function (options) {\n this.updateModel(options);\n this.getAndSetChkElem(options);\n this.showDialog(options);\n };\n CheckBoxFilterBase.prototype.closeDialog = function () {\n if (this.infiniteRenderMod && this.infinitePermenantLocalData.length && !this.options.isRemote) {\n this.options.dataSource.dataSource.json = this.infinitePermenantLocalData;\n }\n if (this.dialogObj && !this.dialogObj.isDestroyed) {\n this.isBlanks = false;\n var filterTemplateCol = this.options.columns.filter(function (col) { return col.getFilterItemTemplate(); });\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var registeredTemplate = this.parent.registeredTemplate;\n if (filterTemplateCol.length && !isNullOrUndefined(registeredTemplate) && registeredTemplate.filterItemTemplate) {\n this.parent.destroyTemplate(['filterItemTemplate']);\n }\n if ((this.parent.isReact || this.parent.isVue) && this.parent.destroyTemplate !== undefined) {\n clearReactVueTemplates(this.parent, ['filterItemTemplate']);\n }\n this.parent.notify(events.filterMenuClose, { field: this.options.field });\n this.dialogObj.destroy();\n this.unWireEvents();\n remove(this.dlg);\n this.dlg = null;\n this.parent.notify(events.filterDialogClose, {});\n }\n };\n /**\n * @param {Column} col - Defines column details\n * @returns {void}\n * @hidden\n */\n CheckBoxFilterBase.prototype.clearFilter = function (col) {\n // eslint-disable-next-line max-len\n var args = { instance: this, handler: this.clearFilter, cancel: false };\n this.parent.notify(events.fltrPrevent, args);\n if (args.cancel) {\n return;\n }\n this.options.handler({ action: 'clear-filter', field: col ? col.field : this.options.field });\n };\n CheckBoxFilterBase.prototype.btnClick = function (e) {\n if (this.filterState) {\n if ((e.target.tagName.toLowerCase() === 'input' && e.target.classList.contains('e-searchinput')) ||\n e.keyCode === 13) {\n if (!this.isCheckboxFilterTemplate) {\n this.fltrBtnHandler();\n }\n }\n else {\n var text = e.target.firstChild.textContent.toLowerCase();\n if (this.getLocalizedLabel(this.isExcel ? 'OKButton' : 'FilterButton').toLowerCase() === text) {\n if (!this.isCheckboxFilterTemplate) {\n this.fltrBtnHandler();\n }\n }\n else if (this.getLocalizedLabel('ClearButton').toLowerCase() === text) {\n this.clearFilter();\n }\n }\n this.closeDialog();\n }\n else if (e.target && e.target.firstChild &&\n e.target.firstChild.textContent.toLowerCase() === this.getLocalizedLabel('CancelButton').toLowerCase()) {\n this.closeDialog();\n }\n else if (!(e.target.tagName.toLowerCase() === 'input')) {\n this.clearFilter();\n this.closeDialog();\n }\n if (this.options.column.showColumnMenu) {\n this.parent.notify(events.afterFilterColumnMenuClose, {});\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n CheckBoxFilterBase.prototype.fltrBtnHandler = function () {\n var _this = this;\n if (this.infiniteRenderMod) {\n this.cBox.innerHTML = '';\n appendChildren(this.cBox, this.infiniteLoadedElem.slice());\n }\n var checked = [].slice.call(this.cBox.querySelectorAll('.e-check:not(.e-selectall):not(.e-add-current)'));\n var check = checked;\n var optr = 'equal';\n var ddlValue = this.dialogObj.element.querySelector('.e-dropdownlist');\n if (ddlValue) {\n this.options.operator = optr = ddlValue.ej2_instances[0].value;\n }\n this.isMenuNotEqual = this.options.operator === 'notequal';\n var searchInput;\n if (!this.options.hideSearchbox) {\n searchInput = this.searchBox.querySelector('.e-searchinput');\n }\n var caseSen = this.options.allowCaseSensitive;\n var defaults = {\n field: this.options.field, predicate: this.isMenuNotEqual ? 'and' : 'or', uid: this.options.uid,\n operator: optr, type: this.options.type, matchCase: caseSen, ignoreAccent: this.options.ignoreAccent\n };\n var isNotEqual = this.itemsCnt !== checked.length && this.itemsCnt - checked.length < checked.length;\n if (isNotEqual && searchInput && searchInput.value === '') {\n optr = this.isMenuNotEqual ? 'equal' : 'notequal';\n checked = [].slice.call(this.cBox.querySelectorAll('.e-uncheck:not(.e-selectall)'));\n defaults.predicate = this.isMenuNotEqual ? 'or' : 'and';\n defaults.operator = optr;\n }\n var value;\n var val;\n var length;\n var fObj;\n var coll = [];\n if ((checked.length !== this.itemsCnt || (searchInput && searchInput.value && searchInput.value !== ''))\n || this.infiniteRenderMod) {\n if (!this.infiniteRenderMod) {\n for (var i = 0; i < checked.length; i++) {\n value = this.values[parentsUntil(checked[parseInt(i.toString(), 10)], 'e-ftrchk').getAttribute('uid')];\n fObj = extend({}, { value: value }, defaults);\n if (value && !value.toString().length) {\n fObj.operator = isNotEqual ? 'notequal' : 'equal';\n }\n if (value === '' || isNullOrUndefined(value)) {\n coll = coll.concat(CheckBoxFilterBase.generateNullValuePredicates(defaults));\n }\n else {\n coll.push(fObj);\n }\n this.notifyFilterPrevEvent(fObj);\n }\n }\n else if (this.infiniteRenderMod) {\n this.infiniteFltrBtnHandler(coll);\n }\n if ((this.options.type === 'date' || this.options.type === 'datetime') && check.length) {\n length = check.length - 1;\n val = this.values[parentsUntil(check[parseInt(length.toString(), 10)], 'e-ftrchk').getAttribute('uid')];\n if (isNullOrUndefined(val) && isNotEqual) {\n coll.push({\n field: defaults.field, matchCase: defaults.matchCase, operator: 'equal',\n predicate: 'and', value: null\n });\n }\n }\n var addCurrSelection = this.infiniteRenderMod ? this.sBox.querySelector('.e-add-current') :\n this.cBox.querySelector('.e-add-current');\n if (addCurrSelection && addCurrSelection.classList.contains('e-check')) {\n var existingPredicate_1 = this.existingPredicate[this.options.field];\n if (existingPredicate_1) {\n var _loop_1 = function (j) {\n if (!coll.some(function (data) {\n return data\n .value === existingPredicate_1[parseInt(j.toString(), 10)].value;\n })) {\n coll.push(existingPredicate_1[parseInt(j.toString(), 10)]);\n }\n };\n for (var j = 0; j < existingPredicate_1.length; j++) {\n _loop_1(j);\n }\n }\n else {\n return;\n }\n }\n if (!this.infiniteRenderMod) {\n this.initiateFilter(coll);\n }\n else if (coll.length) {\n this.initiateFilter(coll);\n }\n else if (this.sBox.querySelector('.e-selectall').classList.contains('e-check') && !coll.length) {\n var isClearFilter = this.options.filteredColumns.some(function (value) {\n return _this.options.field === value.field;\n });\n if (isClearFilter) {\n this.clearFilter();\n }\n }\n }\n else {\n var isClearFilter = this.options.filteredColumns.some(function (value) {\n return _this.options.field === value.field;\n });\n if (isClearFilter) {\n this.clearFilter();\n }\n }\n };\n CheckBoxFilterBase.prototype.infiniteFltrBtnHandler = function (coll) {\n var value;\n if (this.infiniteManualSelectMaintainPred.length) {\n for (var i = 0; i < this.infiniteManualSelectMaintainPred.length; i++) {\n var pred = this.infiniteManualSelectMaintainPred[i];\n value = pred.value + '';\n if (value === '' || isNullOrUndefined(value)) {\n var dummyDefaults = { predicate: pred.predicate, field: pred.field, type: pred.type, uid: pred.uid, operator: pred.operator,\n matchCase: pred.matchCase, ignoreAccent: pred.ignoreAccent };\n coll.push.apply(coll, CheckBoxFilterBase.generateNullValuePredicates(dummyDefaults));\n }\n else {\n coll.push(this.infiniteManualSelectMaintainPred[i]);\n }\n this.notifyFilterPrevEvent(this.infiniteManualSelectMaintainPred[i]);\n }\n }\n if (!this.localInfiniteSelectAllClicked && this.sInput.value === '' && !(!this.options.parentCurrentViewDataCount && coll.length)) {\n for (var i = 0; i < this.infiniteUnloadParentExistPred.length; i++) {\n coll.unshift(this.infiniteUnloadParentExistPred[i]);\n this.notifyFilterPrevEvent(this.existingPredicate[this.options.field][i]);\n }\n }\n if (this.sInput.value !== '' && (!this.localInfiniteSelectAllClicked || this.infiniteLocalSelectAll)) {\n this.infiniteSearchPred['predicate'] = 'or';\n coll.unshift(this.infiniteSearchPred);\n this.notifyFilterPrevEvent(this.infiniteSearchPred);\n }\n };\n CheckBoxFilterBase.prototype.notifyFilterPrevEvent = function (predicate) {\n var args = {\n instance: this, handler: this.fltrBtnHandler, arg1: predicate.field, arg2: predicate.predicate, arg3: predicate.operator,\n arg4: predicate.matchCase, arg5: predicate.ignoreAccent, arg6: predicate.value, cancel: false\n };\n this.parent.notify(events.fltrPrevent, args);\n if (args.cancel) {\n return;\n }\n };\n // eslint-disable-next-line\n /** @hidden */\n CheckBoxFilterBase.generateNullValuePredicates = function (defaults) {\n var coll = [];\n if (defaults.type === 'string') {\n coll.push({\n field: defaults.field, ignoreAccent: defaults.ignoreAccent, matchCase: defaults.matchCase,\n operator: defaults.operator, predicate: defaults.predicate, value: ''\n });\n }\n coll.push({\n field: defaults.field,\n matchCase: defaults.matchCase, operator: defaults.operator, predicate: defaults.predicate, value: null\n });\n coll.push({\n field: defaults.field, matchCase: defaults.matchCase, operator: defaults.operator,\n predicate: defaults.predicate, value: undefined\n });\n return coll;\n };\n // eslint-disable-next-line\n /** @hidden */\n CheckBoxFilterBase.prototype.initiateFilter = function (fColl) {\n var firstVal = fColl[0];\n var predicate;\n if (!isNullOrUndefined(firstVal)) {\n predicate = firstVal.ejpredicate ? firstVal.ejpredicate :\n new Predicate(firstVal.field, firstVal.operator, firstVal.value, !firstVal.matchCase, firstVal.ignoreAccent);\n for (var j = 1; j < fColl.length; j++) {\n predicate = fColl[parseInt(j.toString(), 10)].ejpredicate !== undefined ?\n predicate[fColl[parseInt(j.toString(), 10)].predicate](fColl[parseInt(j.toString(), 10)].ejpredicate) :\n predicate[fColl[parseInt(j.toString(), 10)].predicate](fColl[parseInt(j.toString(), 10)].field, fColl[parseInt(j.toString(), 10)].operator, fColl[parseInt(j.toString(), 10)].value, !fColl[parseInt(j.toString(), 10)].matchCase, fColl[parseInt(j.toString(), 10)].ignoreAccent);\n }\n var args = {\n action: 'filtering', filterCollection: fColl, field: this.options.field,\n ejpredicate: Predicate.or(predicate)\n };\n this.options.handler(args);\n }\n };\n CheckBoxFilterBase.prototype.isForeignColumn = function (col) {\n return col.isForeignColumn ? col.isForeignColumn() : false;\n };\n CheckBoxFilterBase.prototype.refreshCheckboxes = function () {\n var _this = this;\n var val = this.sInput.value;\n var column = this.options.column;\n var query = this.isForeignColumn(column) ? this.foreignKeyQuery.clone() : this.options.query.clone();\n var foreignQuery = this.options.query.clone();\n var pred = query.queries.filter(function (e) { return e && e.fn === 'onWhere'; })[0];\n query.queries = [];\n foreignQuery.queries = [];\n var parsed = (this.options.type !== 'string' && parseFloat(val)) ? parseFloat(val) : val;\n var operator = this.options.isRemote ?\n (this.options.type === 'string' ? 'contains' : 'equal') : (this.options.type ? 'contains' : 'equal');\n var matchCase = true;\n var ignoreAccent = this.options.ignoreAccent;\n var field = this.isForeignColumn(column) ? column.foreignKeyValue : column.field;\n parsed = (parsed === '' || parsed === undefined) ? undefined : parsed;\n var coll = [];\n var defaults = {\n field: field, predicate: 'or', uid: this.options.uid,\n operator: 'equal', type: this.options.type, matchCase: matchCase, ignoreAccent: ignoreAccent\n };\n var predicte;\n var moduleName = this.options.dataManager.adaptor.getModuleName;\n if (this.options.type === 'boolean') {\n if (parsed !== undefined &&\n this.getLocalizedLabel('FilterTrue').toLowerCase().indexOf(parsed.toLowerCase()) !== -1) {\n parsed = 'true';\n }\n else if (parsed !== undefined &&\n this.getLocalizedLabel('FilterFalse').toLowerCase().indexOf(parsed.toLowerCase()) !== -1) {\n parsed = 'false';\n }\n if (parsed !== undefined &&\n this.getLocalizedLabel('FilterTrue').toLowerCase().indexOf(parsed.toLowerCase()) !== -1 && moduleName) {\n // eslint-disable-next-line no-constant-condition\n parsed = (moduleName() === 'ODataAdaptor' || 'ODataV4Adaptor') ? true : 'true';\n }\n else if (parsed !== undefined &&\n this.getLocalizedLabel('FilterFalse').toLowerCase().indexOf(parsed.toLowerCase()) !== -1 && moduleName) {\n // eslint-disable-next-line no-constant-condition\n parsed = (moduleName() === 'ODataAdaptor' || 'ODataV4Adaptor') ? false : 'false';\n }\n operator = 'equal';\n }\n if ((this.options.type === 'date' || this.options.type === 'datetime' || this.options.type === 'dateonly') && this.options.format) {\n var intl = new Internationalization();\n var format = typeof (this.options.format) === 'string' ? this.options.format :\n this.options.format.format;\n if (format) {\n parsed = intl.parseDate(val, { format: format }) || new Date(val);\n }\n else {\n parsed = new Date(val);\n }\n if (this.options.type === 'dateonly') {\n parsed = parsed.getFullYear() + '-' + padZero(parsed.getMonth() + 1) + '-' + padZero(parsed.getDate());\n }\n }\n this.infiniteSearchValChange = true;\n this.infiniteLoadedElem = [];\n this.infiniteLocalSelectAll = true;\n this.localInfiniteSelectAllClicked = false;\n this.localInfiniteSelectionInteracted = false;\n this.infiniteSkipCnt = 0;\n this.infiniteDataCount = 0;\n this.infiniteManualSelectMaintainPred = [];\n if (this.sInput.value === '') {\n this.infiniteUnloadParentExistPred = this.infiniteRenderMod && this.existingPredicate[this.options.column.field] ? this.existingPredicate[this.options.column.field].slice() : [];\n this.options.parentTotalDataCount = this.options.parentTotalDataCount;\n }\n else {\n this.infiniteUnloadParentExistPred = [];\n }\n this.addDistinct(query);\n var args = {\n requestType: events.filterSearchBegin,\n filterModel: this, columnName: field, column: column,\n operator: operator, matchCase: matchCase, ignoreAccent: ignoreAccent, filterChoiceCount: null,\n query: query, value: parsed\n };\n if (this.infiniteRenderMod && this.parent.filterSettings.itemsCount) {\n args.filterChoiceCount = this.parent.filterSettings.itemsCount;\n }\n this.parent.trigger(events.actionBegin, args, function (filterargs) {\n // eslint-disable-next-line no-self-assign\n filterargs.operator = filterargs.operator;\n predicte = new Predicate(field, filterargs.operator, args.value, filterargs.matchCase, filterargs.ignoreAccent);\n if (_this.options.type === 'date' || _this.options.type === 'datetime' || _this.options.type === 'dateonly') {\n operator = 'equal';\n var filterObj = {\n field: field, operator: operator, value: parsed, matchCase: matchCase,\n ignoreAccent: ignoreAccent\n };\n if (!isNullOrUndefined(parsed)) {\n predicte = getDatePredicate(filterObj, _this.options.type);\n }\n }\n if (val && typeof val === 'string' && _this.isBlanks &&\n _this.getLocalizedLabel('Blanks').toLowerCase().indexOf(val.toLowerCase()) >= 0) {\n coll = coll.concat(CheckBoxFilterBase.generateNullValuePredicates(defaults));\n var emptyValPredicte = CheckBoxFilterBase.generatePredicate(coll);\n emptyValPredicte.predicates.push(predicte);\n predicte = emptyValPredicte;\n query.where(emptyValPredicte);\n }\n else if (val.length) {\n predicte = !isNullOrUndefined(pred) ? predicte.and(pred.e) : predicte;\n query.where(predicte);\n }\n else if (!isNullOrUndefined(pred)) {\n predicte = pred.e;\n query.where(pred.e);\n }\n _this.infiniteSearchPred = predicte;\n filterargs.filterChoiceCount = !isNullOrUndefined(filterargs.filterChoiceCount) ? filterargs.filterChoiceCount : 1000;\n if (_this.infiniteRenderMod && _this.parent.filterSettings.itemsCount !== filterargs.filterChoiceCount) {\n _this.parent.filterSettings.itemsCount = args.filterChoiceCount;\n }\n var fPredicate = {};\n showSpinner(_this.spinner);\n _this.renderEmpty = false;\n if (_this.isForeignColumn(column) && val.length) {\n var colData = ('result' in column.dataSource) ? new DataManager(column.dataSource.result) :\n column.dataSource;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n colData.executeQuery(query).then(function (e) {\n var columnData = _this.options.column.columnData;\n _this.options.column.columnData = e.result;\n _this.parent.notify(events.generateQuery, { predicate: fPredicate, column: column });\n if (fPredicate.predicate.predicates.length) {\n foreignQuery.where(fPredicate.predicate);\n }\n else {\n _this.renderEmpty = true;\n }\n _this.options.column.columnData = columnData;\n if (_this.infiniteRenderMod) {\n _this.infiniteInitialLoad = isNullOrUndefined(_this.fullData) ? true : false;\n _this.makeInfiniteScrollRequest(foreignQuery);\n foreignQuery.requiresCount();\n }\n else {\n foreignQuery.take(filterargs.filterChoiceCount);\n }\n _this.search(filterargs, foreignQuery);\n });\n }\n else {\n if (_this.infiniteRenderMod && _this.parent.filterSettings.itemsCount) {\n _this.infiniteInitialLoad = isNullOrUndefined(_this.fullData) ? true : false;\n _this.makeInfiniteScrollRequest(query);\n query.requiresCount();\n }\n else {\n query.take(filterargs.filterChoiceCount);\n }\n _this.search(filterargs, query);\n }\n });\n };\n CheckBoxFilterBase.prototype.search = function (args, query) {\n if (this.parent.dataSource && 'result' in this.parent.dataSource) {\n this.filterEvent(args, query);\n }\n else {\n this.processSearch(query);\n }\n };\n CheckBoxFilterBase.prototype.getPredicateFromCols = function (columns, isExecuteLocal) {\n var predicates = CheckBoxFilterBase.getPredicate(columns, isExecuteLocal);\n var predicateList = [];\n var fPredicate = {};\n var isGrid = this.parent.getForeignKeyColumns !== undefined;\n var foreignColumn = isGrid ? this.parent.getForeignKeyColumns() : [];\n for (var _i = 0, _a = Object.keys(predicates); _i < _a.length; _i++) {\n var prop = _a[_i];\n var col = void 0;\n if (isGrid && !this.parent.getColumnByField(prop)) {\n col = getColumnByForeignKeyValue(prop, foreignColumn);\n }\n if (col) {\n this.parent.notify(events.generateQuery, { predicate: fPredicate, column: col });\n if (fPredicate.predicate.predicates.length) {\n predicateList.push(Predicate.or(fPredicate.predicate.predicates));\n }\n }\n else {\n predicateList.push(predicates[\"\" + prop]);\n }\n }\n return predicateList.length && Predicate.and(predicateList);\n };\n CheckBoxFilterBase.prototype.getQuery = function () {\n return this.parent.getQuery ? this.parent.getQuery().clone() : new Query();\n };\n CheckBoxFilterBase.prototype.getAllData = function () {\n var _this = this;\n this.customQuery = false;\n var query = this.getQuery();\n query.requiresCount(); //consider take query\n this.addDistinct(query);\n var args = {\n requestType: events.filterChoiceRequest, query: query, filterChoiceCount: null\n };\n var filterModel = 'filterModel';\n args[\"\" + filterModel] = this;\n if (this.infiniteRenderMod && this.parent.filterSettings.itemsCount) {\n args.filterChoiceCount = this.parent.filterSettings.itemsCount;\n }\n this.parent.trigger(events.actionBegin, args, function (args) {\n args.filterChoiceCount = !isNullOrUndefined(args.filterChoiceCount) ? args.filterChoiceCount : 1000;\n if (_this.infiniteRenderMod && _this.parent.filterSettings.itemsCount !== args.filterChoiceCount) {\n _this.parent.filterSettings.itemsCount = args.filterChoiceCount;\n }\n if (!_this.infiniteRenderMod) {\n query.take(args.filterChoiceCount);\n }\n if (!args.query.distincts.length || _this.infiniteRenderMod) {\n _this.customQuery = true;\n _this.queryGenerate(query);\n }\n if (_this.infiniteRenderMod) {\n _this.infiniteInitialLoad = isNullOrUndefined(_this.fullData) ? true : false;\n _this.makeInfiniteScrollRequest(query);\n }\n if (_this.parent.dataSource && 'result' in _this.parent.dataSource) {\n _this.filterEvent(args, query);\n }\n else {\n _this.processDataOperation(query, true);\n }\n });\n };\n CheckBoxFilterBase.prototype.addDistinct = function (query) {\n var _this = this;\n var _a;\n var filteredColumn = DataUtil.distinct(this.options.filteredColumns, 'field');\n if (filteredColumn.indexOf(this.options.column.field) <= -1) {\n filteredColumn = filteredColumn.concat(this.options.column.field);\n }\n if (!this.infiniteRenderMod) {\n query.distinct(filteredColumn);\n }\n if (this.infiniteRenderMod && !this.options.isRemote && this.sInput.value === '') {\n this.options.dataSource = this.options.dataSource instanceof DataManager ?\n this.options.dataSource : new DataManager(this.options.dataSource);\n this.infinitePermenantLocalData = this.options.dataSource.dataSource.json.slice();\n this.options.dataSource.dataSource.json = DataUtil.distinct((_a = this.options.parentFilteredLocalRecords).concat.apply(_a, this.infinitePermenantLocalData), this.options.column.field, true);\n if (this.isForeignColumn(this.options.column)) {\n this.options.column.dataSource = this.options.column.dataSource instanceof DataManager ?\n this.options.column.dataSource : new DataManager(this.options.column.dataSource);\n this.options.dataSource.dataSource.json = this.options.dataSource.dataSource.json.map(function (item, i) {\n return Object.assign({}, item, _this.options.column.dataSource.dataSource.json[i]);\n });\n }\n }\n else if (this.infiniteRenderMod && this.options.isRemote) {\n query.select(this.options.column.field);\n query.sortBy(this.options.column.field, 'ascending');\n var moduleName = this.options.dataManager.adaptor.getModuleName;\n if (moduleName && moduleName() && (moduleName() === 'ODataV4Adaptor' || moduleName() === 'WebApiAdaptor'\n || moduleName() === 'CustomDataAdaptor' || moduleName() === 'GraphQLAdaptor' || moduleName() === 'ODataAdaptor')) {\n query.distinct(filteredColumn);\n }\n }\n return query;\n };\n CheckBoxFilterBase.prototype.filterEvent = function (args, query) {\n var _this = this;\n var defObj = eventPromise(args, query);\n this.parent.trigger(events.dataStateChange, defObj.state);\n var def = defObj.deffered;\n def.promise.then(function (e) {\n _this.dataSuccess(e);\n });\n };\n CheckBoxFilterBase.prototype.infiniteScrollMouseKeyDownHandler = function () {\n EventHandler.remove(this.cBox, 'scroll', this.infiniteScrollHandler);\n };\n CheckBoxFilterBase.prototype.infiniteScrollMouseKeyUpHandler = function (e) {\n var _this = this;\n EventHandler.add(this.cBox, 'scroll', this.infiniteScrollHandler, this);\n var target = this.cBox;\n if (target.children.length > 1 && (target.scrollTop >= target.scrollHeight - target.offsetHeight || target.scrollTop <= 0)) {\n this.infiniteScrollHandler();\n }\n Global.timer = setTimeout(function () { _this.clickHandler(e); Global.timer = null; }, 0);\n };\n CheckBoxFilterBase.prototype.getListHeight = function (element) {\n var listDiv = createElement('div', { className: 'e-ftrchk', styles: 'visibility: hidden' });\n listDiv.innerHTML = '<div class=\"e-checkbox-wrapper\"><span class=\"e-label e-checkboxfiltertext\">A</div></span>';\n element.appendChild(listDiv);\n var rect = listDiv.getBoundingClientRect();\n element.removeChild(listDiv);\n var listHeight = Math.round(rect.height);\n return listHeight;\n };\n CheckBoxFilterBase.prototype.getShimmerTemplate = function () {\n return '<span class=\"e-mask e-skeleton e-skeleton-text e-shimmer-wave\"></span>';\n };\n CheckBoxFilterBase.prototype.showMask = function () {\n var maskRowCount = 5;\n var maskItemHeight;\n var maskList = this.parent.createElement('div', { id: this.id + this.options.type + '_CheckBoxMaskList',\n className: 'e-checkboxlist e-fields e-infinite-list e-masklist', styles: 'z-index: 10;' });\n var wrapperElem = this.cBox;\n this.removeMask();\n if (wrapperElem) {\n var computedStyle = getComputedStyle(wrapperElem);\n var height = wrapperElem.children.length ? parseInt(computedStyle.height) :\n Math.floor(parseInt(computedStyle.height.split('px')[0])) - 5;\n var backgroundColor = this.isExcel && !wrapperElem.children.length && !this.dlg.classList.contains('e-excelfilter') ?\n '' : getComputedStyle(this.dlg.querySelector('.e-dlg-content')).backgroundColor;\n maskList.style.cssText = 'width: ' + computedStyle.width + '; min-height: ' + computedStyle.minHeight + '; height: ' +\n height + 'px; margin: ' + computedStyle.margin + '; border-style: ' + computedStyle.borderStyle + '; border-width: '\n + computedStyle.borderWidth + '; border-color: ' + computedStyle.borderColor + '; position: absolute; background-color: ' +\n backgroundColor + ';';\n var liHeight = this.getListHeight(wrapperElem);\n maskRowCount = Math.floor(height / liHeight);\n maskRowCount = wrapperElem.children.length > maskRowCount ? wrapperElem.children.length : maskRowCount;\n maskItemHeight = liHeight + 'px';\n }\n var maskTemplate = '<div class=\"e-ftrchk e-mask-ftrchk\" style=\"width: 100%; height:' + maskItemHeight + ';\">'\n + '<div class=\"e-checkbox-wrapper\" style=\"width: 100%;\"><input class=\"e-chk-hidden\">'\n + this.getShimmerTemplate() + this.getShimmerTemplate() + '</div></div>';\n maskList.innerHTML = '';\n if (!wrapperElem.children.length) {\n this.spinner.insertAdjacentHTML('beforebegin', maskTemplate);\n var maskSpan = [].slice.call(this.spinner.parentElement\n .querySelectorAll('.e-mask:not(.e-mask-checkbox-filter-intent):not(.e-mask-checkbox-filter-span-intent)'));\n maskSpan[0].classList.add('e-mask-checkbox-filter-intent');\n maskSpan[1].classList.add('e-mask-checkbox-filter-span-intent');\n }\n this.spinner.insertBefore(maskList, this.cBox);\n for (var i = 0; maskRowCount && i < maskRowCount; i++) {\n maskList.innerHTML += maskTemplate;\n var maskSpan = [].slice.call(maskList\n .querySelectorAll('.e-mask:not(.e-mask-checkbox-filter-intent):not(.e-mask-checkbox-filter-span-intent)'));\n maskSpan[0].classList.add('e-mask-checkbox-filter-intent');\n maskSpan[1].classList.add('e-mask-checkbox-filter-span-intent');\n }\n if (this.cBox) {\n maskList.scrollTop = this.cBox.scrollTop;\n }\n };\n CheckBoxFilterBase.prototype.removeMask = function () {\n var maskLists = this.dialogObj.element.querySelectorAll('.e-mask-ftrchk');\n if (maskLists.length) {\n for (var i = 0; i < maskLists.length; i++) {\n remove(maskLists[i]);\n }\n }\n var maskParent = this.dialogObj.element.querySelector('.e-checkboxlist.e-masklist');\n if (maskParent) {\n remove(this.dialogObj.element.querySelector('.e-checkboxlist.e-masklist'));\n }\n };\n CheckBoxFilterBase.prototype.infiniteScrollHandler = function () {\n var target = this.cBox;\n if (target.scrollTop >= target.scrollHeight - target.offsetHeight && !this.infiniteQueryExecutionPending\n && this.infiniteLoadedElem.length <= (this.infiniteSkipCnt + this.parent.filterSettings.itemsCount)\n && this.cBox.children.length === this.parent.filterSettings.itemsCount * 3\n && (!this.infiniteDataCount || this.infiniteDataCount > (this.infiniteSkipCnt + this.parent.filterSettings.itemsCount))) {\n this.makeInfiniteScrollRequest();\n this.prevInfiniteScrollDirection = 'down';\n }\n else if (target.scrollTop >= target.scrollHeight - target.offsetHeight && !this.infiniteQueryExecutionPending\n && this.infiniteLoadedElem.length > (this.infiniteSkipCnt + this.parent.filterSettings.itemsCount)\n && this.cBox.children.length === this.parent.filterSettings.itemsCount * 3) {\n this.infiniteRemoveElements(([].slice.call(this.cBox.children)).splice(0, this.parent.filterSettings.itemsCount));\n this.infiniteSkipCnt += this.prevInfiniteScrollDirection === 'down' ? this.parent.filterSettings.itemsCount :\n (this.parent.filterSettings.itemsCount * 3);\n appendChildren(this.cBox, this.infiniteLoadedElem.slice(this.infiniteSkipCnt, this.parent.filterSettings.itemsCount + this.infiniteSkipCnt));\n this.prevInfiniteScrollDirection = 'down';\n }\n else if (target.scrollTop === 0 && !this.infiniteInitialLoad && !this.infiniteSearchValChange && this.infiniteSkipCnt\n && this.infiniteLoadedElem.length && this.infiniteLoadedElem.length > this.parent.filterSettings.itemsCount * 3\n && this.cBox.children.length === this.parent.filterSettings.itemsCount * 3) {\n this.infiniteRemoveElements(([].slice.call(this.cBox.children)).splice((this.parent.filterSettings.itemsCount * 2), this.parent.filterSettings.itemsCount));\n this.infiniteSkipCnt -= this.prevInfiniteScrollDirection === 'up' ? this.parent.filterSettings.itemsCount :\n (this.parent.filterSettings.itemsCount * 3);\n this.infiniteAppendElements([].slice.call(this.infiniteLoadedElem.slice(this.infiniteSkipCnt, this.infiniteSkipCnt + this.parent.filterSettings.itemsCount)));\n this.cBox.scrollTop = this.infiniteScrollAppendDiff;\n this.prevInfiniteScrollDirection = 'up';\n }\n else if (target.scrollTop === 0 && !this.infiniteInitialLoad && !this.infiniteSearchValChange && this.infiniteSkipCnt\n && this.infiniteLoadedElem.length && this.cBox.children.length < this.parent.filterSettings.itemsCount * 3) {\n this.infiniteRemoveElements(([].slice.call(this.cBox.children)).splice((this.parent.filterSettings.itemsCount * 2), this.infiniteDataCount % this.parent.filterSettings.itemsCount));\n this.infiniteSkipCnt = (Math.floor(this.infiniteDataCount / this.parent.filterSettings.itemsCount) - 3) *\n this.parent.filterSettings.itemsCount;\n this.infiniteAppendElements([].slice.call(this.infiniteLoadedElem.slice(this.infiniteSkipCnt, this.infiniteSkipCnt + this.parent.filterSettings.itemsCount)));\n this.cBox.scrollTop = this.infiniteScrollAppendDiff;\n this.prevInfiniteScrollDirection = 'up';\n }\n };\n CheckBoxFilterBase.prototype.infiniteRemoveElements = function (removeElem) {\n for (var i = 0; i < removeElem.length; i++) {\n remove(removeElem[i]);\n }\n };\n CheckBoxFilterBase.prototype.infiniteAppendElements = function (appendElem) {\n for (var i = 0; i < appendElem.length; i++) {\n this.cBox.insertBefore(appendElem[i], this.cBox.children[i]);\n }\n };\n CheckBoxFilterBase.prototype.makeInfiniteScrollRequest = function (query) {\n var _this = this;\n if (!this.infiniteInitialLoad && this.parent.filterSettings && this.parent.filterSettings.loadingIndicator === 'Shimmer') {\n setTimeout(function () {\n if (_this.infiniteQueryExecutionPending) {\n _this.showMask();\n }\n }, 500);\n }\n else if (!this.infiniteInitialLoad) {\n createSpinner({ target: this.spinner, cssClass: this.parent.cssClass ? this.parent.cssClass : null }, this.parent.createElement);\n showSpinner(this.spinner);\n }\n var fName = 'fn';\n if (this.infiniteQuery && this.infiniteQuery.queries && this.infiniteQuery.queries.length) {\n for (var i = 0; i < this.infiniteQuery.queries.length; i++) {\n if (this.infiniteQuery.queries[i][\"\" + fName] === 'onTake'\n || this.infiniteQuery.queries[i][\"\" + fName] === 'onSkip') {\n this.infiniteQuery.queries.splice(i, 1);\n i--;\n }\n }\n }\n var existQuery = query ? true : false;\n query = query ? query : this.infiniteQuery;\n if (this.infiniteInitialLoad || this.infiniteSearchValChange) {\n this.infiniteSkipCnt = 0;\n }\n else {\n this.infiniteSkipCnt += this.parent.filterSettings.itemsCount;\n }\n query.skip(this.infiniteSkipCnt);\n if (this.infiniteInitialLoad || this.infiniteSearchValChange) {\n query.take(this.parent.filterSettings.itemsCount * 3);\n this.infiniteSkipCnt += this.parent.filterSettings.itemsCount * 2;\n }\n else {\n query.take(this.parent.filterSettings.itemsCount);\n }\n if (!existQuery) {\n this.processDataOperation(query);\n this.infiniteQueryExecutionPending = true;\n }\n };\n CheckBoxFilterBase.prototype.processDataOperation = function (query, isInitial) {\n var _this = this;\n this.options.dataSource = this.options.dataSource instanceof DataManager ?\n this.options.dataSource : new DataManager(this.options.dataSource);\n var allPromise = [];\n var runArray = [];\n if (this.isForeignColumn(this.options.column) && isInitial) {\n var colData = ('result' in this.options.column.dataSource) ?\n new DataManager(this.options.column.dataSource.result) :\n this.options.column.dataSource;\n this.foreignKeyQuery.params = query.params;\n allPromise.push(colData.executeQuery(this.foreignKeyQuery));\n runArray.push(function (data) { return _this.foreignKeyData = data; });\n }\n if (this.infiniteRenderMod) {\n this.infiniteQuery = query.clone();\n if (this.infiniteInitialLoad) {\n this.cBox.classList.add('e-checkbox-infinitescroll');\n EventHandler.add(this.cBox, 'scroll', this.infiniteScrollHandler, this);\n EventHandler.add(this.cBox, 'mouseup', this.infiniteScrollMouseKeyUpHandler, this);\n EventHandler.add(this.cBox, 'mousedown', this.infiniteScrollMouseKeyDownHandler, this);\n }\n else if (this.infiniteSearchValChange) {\n this.cBox.innerHTML = '';\n }\n }\n if (this.infiniteRenderMod && this.infiniteInitialLoad && !this.options.isRemote) {\n var field = this.isForeignColumn(this.options.column) ? this.options.foreignKeyValue :\n this.options.column.field;\n this.options.dataSource.executeQuery(new Query().sortBy(field, DataUtil.fnAscending)).then(function (e) {\n _this.options.dataSource.dataSource.json = e.result;\n _this.executeQueryOperations(query, allPromise, runArray);\n });\n }\n else {\n this.executeQueryOperations(query, allPromise, runArray);\n }\n };\n CheckBoxFilterBase.prototype.executeQueryOperations = function (query, allPromise, runArray) {\n var _this = this;\n allPromise.push(this.options.dataSource.executeQuery(query));\n runArray.push(this.dataSuccess.bind(this));\n var i = 0;\n Promise.all(allPromise).then(function (e) {\n _this.infiniteQueryExecutionPending = _this.infiniteRenderMod ? false : _this.infiniteQueryExecutionPending;\n for (var j = 0; j < e.length; j++) {\n _this.infiniteDataCount = _this.infiniteRenderMod && !_this.infiniteDataCount ? e[j].count : _this.infiniteDataCount;\n runArray[i++](e[parseInt(j.toString(), 10)].result);\n }\n }).catch(function () {\n if (_this.infiniteRenderMod && _this.parent.filterSettings && _this.parent.filterSettings.loadingIndicator === 'Shimmer') {\n _this.parent.showMaskRow(undefined, _this.dialogObj.element);\n }\n });\n };\n CheckBoxFilterBase.prototype.dataSuccess = function (e) {\n if (!this.infiniteInitialLoad && this.infiniteDataCount && ((this.infiniteSkipCnt >= this.infiniteDataCount\n && !this.infiniteSearchValChange) || (e.length === 0))) {\n return;\n }\n this.fullData = e;\n var args1 = { dataSource: this.fullData, executeQuery: true, field: this.options.field };\n this.parent.notify(events.beforeCheckboxRenderer, args1);\n if (args1.executeQuery) {\n var query = new Query();\n if (!this.customQuery) {\n this.isExecuteLocal = true;\n this.queryGenerate(query);\n this.isExecuteLocal = false;\n }\n // query.select(this.options.field);\n var result = new DataManager(args1.dataSource).executeLocal(query);\n var col = this.options.column;\n this.filteredData = CheckBoxFilterBase.getDistinct(result, this.options.field, col, this.foreignKeyData, this).records || [];\n }\n var data = args1.executeQuery ? this.filteredData : args1.dataSource;\n this.processDataSource(null, true, data, args1);\n if (this.sInput && ((this.infiniteRenderMod && this.infiniteInitialLoad) || !this.infiniteRenderMod)) {\n this.sInput.focus();\n }\n if (this.infiniteInitialLoad || this.infiniteSearchValChange) {\n this.infiniteInitialLoad = false;\n this.infiniteSearchValChange = false;\n }\n var args = {\n requestType: events.filterAfterOpen,\n columnName: this.options.field, columnType: this.options.type\n };\n var filterModel = 'filterModel';\n args[\"\" + filterModel] = this;\n this.parent.notify(events.cBoxFltrComplete, args);\n if (this.isCheckboxFilterTemplate) {\n hideSpinner(this.spinner);\n }\n };\n CheckBoxFilterBase.prototype.queryGenerate = function (query) {\n if (this.parent.searchSettings && this.parent.searchSettings.key.length) {\n var sSettings = this.parent.searchSettings;\n var fields = sSettings.fields.length ? sSettings.fields : this.options.columns.map(function (f) { return f.field; });\n query.search(sSettings.key, fields, sSettings.operator, sSettings.ignoreCase, sSettings.ignoreAccent);\n }\n if ((this.options.filteredColumns.length)) {\n var cols = [];\n for (var i = 0; i < this.options.filteredColumns.length; i++) {\n var filterColumn = this.options.filteredColumns[parseInt(i.toString(), 10)];\n if (this.options.uid) {\n filterColumn.uid = filterColumn.uid || this.parent.getColumnByField(filterColumn.field).uid;\n if (filterColumn.uid !== this.options.uid) {\n cols.push(this.options.filteredColumns[parseInt(i.toString(), 10)]);\n }\n }\n else {\n if (filterColumn.field !== this.options.field) {\n cols.push(this.options.filteredColumns[parseInt(i.toString(), 10)]);\n }\n }\n }\n var predicate = this.getPredicateFromCols(cols, this.isExecuteLocal);\n if (predicate) {\n query.where(predicate);\n }\n }\n };\n CheckBoxFilterBase.prototype.processDataSource = function (query, isInitial, dataSource, args) {\n showSpinner(this.spinner);\n // query = query ? query : this.options.query.clone();\n // query.requiresCount();\n // let result: Object = new DataManager(dataSource as JSON[]).executeLocal(query);\n // let res: { result: Object[] } = result as { result: Object[] };\n this.isExecuteLocal = true;\n this.updateResult();\n this.isExecuteLocal = false;\n var args1 = { dataSource: this.fullData, isCheckboxFilterTemplate: false, column: this.options.column,\n element: this.cBox, type: this.options.type, format: this.options.type, btnObj: this.options.isResponsiveFilter ? null :\n this.dialogObj.btnObj[0], searchBox: this.searchBox };\n this.parent.notify(events.beforeCheckboxfilterRenderer, args1);\n this.isCheckboxFilterTemplate = args1.isCheckboxFilterTemplate;\n if (!this.isCheckboxFilterTemplate) {\n this.createFilterItems(dataSource, isInitial, args);\n }\n else if (this.infiniteRenderMod && this.parent.filterSettings && this.parent.filterSettings.loadingIndicator === 'Shimmer') {\n this.removeMask();\n }\n };\n CheckBoxFilterBase.prototype.processSearch = function (query) {\n this.processDataOperation(query);\n };\n CheckBoxFilterBase.prototype.updateResult = function () {\n this.result = {};\n var predicate = this.infiniteRenderMod && this.existingPredicate[this.options.field] ?\n this.getPredicateFromCols(this.existingPredicate[this.options.field], this.isExecuteLocal) :\n this.getPredicateFromCols(this.options.filteredColumns, this.isExecuteLocal);\n var query = new Query();\n if (predicate) {\n query.where(predicate);\n }\n this.parent.notify(events.beforeCheckboxRendererQuery, { query: query });\n var result = new DataManager(this.fullData).executeLocal(query);\n for (var _i = 0, result_1 = result; _i < result_1.length; _i++) {\n var res = result_1[_i];\n this.result[getObject(this.options.field, res)] = true;\n }\n };\n CheckBoxFilterBase.prototype.clickHandler = function (e) {\n var _a;\n if (!isNullOrUndefined(Global.timer)) {\n clearTimeout(Global.timer);\n }\n var target = e.target;\n if (!isNullOrUndefined(this.parent.loadingIndicator) && this.parent.loadingIndicator.indicatorType === 'Shimmer'\n && parentsUntil(target, 'e-mask-ftrchk')) {\n return;\n }\n var elem = parentsUntil(target, 'e-checkbox-wrapper');\n if (parentsUntil(target, 'e-searchbox')) {\n this.searchBoxClick(e);\n }\n if (elem && !this.isCheckboxFilterTemplate) {\n var selectAll = elem.querySelector('.e-selectall');\n if (selectAll) {\n this.updateAllCBoxes(!selectAll.classList.contains('e-check'));\n }\n else {\n toogleCheckbox(elem.parentElement);\n if (this.infiniteRenderMod && !elem.parentElement.querySelector('.e-add-current')) {\n this.localInfiniteSelectionInteracted = true;\n var caseSen = this.options.allowCaseSensitive;\n var span = elem.parentElement.querySelector('.e-frame');\n var input = span.previousSibling;\n var optr = input.checked ? 'equal' : 'notequal';\n var pred = input.checked ? 'or' : 'and';\n var defaults = { field: this.options.field, predicate: pred, uid: this.options.uid,\n operator: optr, type: this.options.type, matchCase: caseSen, ignoreAccent: this.options.ignoreAccent\n };\n var value = this.values[parentsUntil(input, 'e-ftrchk').getAttribute('uid')];\n this.updateInfiniteManualSelectPred(defaults, value);\n if (this.infiniteRenderMod && !this.options.isRemote && this.options.parentTotalDataCount\n && this.infiniteUnloadParentExistPred.length) {\n var predicate = this.getPredicateFromCols((_a = this.options.filteredColumns).concat.apply(_a, this.infiniteManualSelectMaintainPred), true);\n var query = new Query();\n if (predicate) {\n query.where(predicate);\n }\n var result = new DataManager(this.infinitePermenantLocalData).executeLocal(query);\n if (this.options.parentTotalDataCount !== result.length) {\n this.options.parentTotalDataCount = result.length;\n }\n if (!this.options.parentTotalDataCount && this.infiniteUnloadParentExistPred.length) {\n this.infiniteUnloadParentExistPred = [];\n }\n }\n if (this.infiniteUnloadParentExistPred.length && (this.options.parentTotalDataCount === this.infiniteDataCount\n || !this.options.parentTotalDataCount)) {\n this.infiniteUnloadParentExistPred = [];\n }\n }\n }\n this.updateIndeterminatenBtn();\n elem.querySelector('.e-chk-hidden').focus();\n }\n this.setFocus(parentsUntil(elem, 'e-ftrchk'));\n };\n CheckBoxFilterBase.prototype.updateInfiniteManualSelectPred = function (defaults, value) {\n for (var i = 0; i < this.infiniteManualSelectMaintainPred.length; i++) {\n var predmdl = this.infiniteManualSelectMaintainPred[i];\n if (predmdl.value + '' === value + '' && (predmdl.operator === 'equal' || predmdl.operator === 'notequal')) {\n this.infiniteManualSelectMaintainPred.splice(i, 1);\n break;\n }\n }\n if ((defaults.predicate === 'or' && (!this.localInfiniteSelectAllClicked || !this.infiniteLocalSelectAll))\n || (defaults.predicate === 'and' && (!this.localInfiniteSelectAllClicked || this.infiniteLocalSelectAll))) {\n this.infiniteManualSelectMaintainPred.push(extend({}, { value: value }, defaults));\n if (defaults.predicate === 'or') {\n this.options.parentTotalDataCount++;\n }\n else {\n this.options.parentTotalDataCount--;\n }\n }\n };\n /**\n * Method to set the next target element on keyboard navigation using arrow keys.\n *\n */\n CheckBoxFilterBase.prototype.focusNextOrPrev = function (e, focusableElements) {\n var nextIndex = (e.key === 'ArrowUp') ? focusableElements.indexOf(document.activeElement) - 1\n : focusableElements.indexOf(document.activeElement) + 1;\n var nextElement = focusableElements[((nextIndex + focusableElements.length) % focusableElements.length)];\n // Set focus on the next / previous element\n if (nextElement) {\n nextElement.focus();\n var target = nextElement.classList.contains('e-chk-hidden') ? parentsUntil(nextElement, 'e-ftrchk') : nextElement;\n this.setFocus(target);\n }\n };\n CheckBoxFilterBase.prototype.keyupHandler = function (e) {\n if ((e.key === 'Tab' && e.shiftKey) || e.key === 'Tab' || ((e.key === 'ArrowUp' || e.key === 'ArrowDown') && !e.altKey)) {\n this.setFocus(parentsUntil(e.target, 'e-ftrchk'));\n }\n if ((e.key === 'ArrowUp' || e.key === 'ArrowDown') && !e.altKey && this.parent.filterSettings.type === 'CheckBox') {\n e.preventDefault();\n var focusableElements = Array.from(this.dlg.querySelectorAll('input, button, [tabindex]:not([tabindex=\"-1\"])'));\n this.focusNextOrPrev(e, focusableElements);\n }\n };\n CheckBoxFilterBase.prototype.setFocus = function (elem) {\n var prevElem = this.dlg.querySelector('.e-chkfocus');\n if (prevElem) {\n prevElem.classList.remove('e-chkfocus');\n }\n if (elem && elem !== prevElem) {\n elem.classList.add('e-chkfocus');\n }\n };\n CheckBoxFilterBase.prototype.updateAllCBoxes = function (checked) {\n if (this.infiniteRenderMod) {\n this.localInfiniteSelectAllClicked = true;\n this.infiniteLocalSelectAll = checked;\n this.infiniteUnloadParentExistPred = [];\n this.infiniteManualSelectMaintainPred = [];\n }\n var cBoxes = this.infiniteRenderMod ?\n this.infiniteLoadedElem.map(function (arr) {\n return arr.querySelector('.e-frame');\n }) : [].slice.call(this.cBox.querySelectorAll('.e-frame:not(.e-add-current)'));\n for (var _i = 0, cBoxes_1 = cBoxes; _i < cBoxes_1.length; _i++) {\n var cBox = cBoxes_1[_i];\n removeAddCboxClasses(cBox, checked);\n setChecked(cBox.previousSibling, checked);\n }\n };\n CheckBoxFilterBase.prototype.dialogOpen = function () {\n if (this.parent.element.classList.contains('e-device')) {\n this.dialogObj.element.querySelector('.e-input-group').classList.remove('e-input-focus');\n if (!this.options.isResponsiveFilter) {\n this.dialogObj.element.querySelector('.e-btn').focus();\n }\n }\n };\n CheckBoxFilterBase.prototype.createCheckbox = function (value, checked, data) {\n var elem = checked ? this.cBoxTrue.cloneNode(true) :\n this.cBoxFalse.cloneNode(true);\n setChecked(elem.querySelector('input'), checked);\n var label = elem.querySelector('.e-label');\n var dummyData = extendObjWithFn({}, data, { column: this.options.column, parent: this.parent });\n var innerText = this.options.disableHtmlEncode ? 'textContent' : 'innerHTML';\n label[\"\" + innerText] = !isNullOrUndefined(value) && value.toString().length ?\n this.parent.enableHtmlSanitizer ? SanitizeHtmlHelper.sanitize(value) : value : this.getLocalizedLabel('Blanks');\n var checkboxUid = getUid('cbox');\n label.setAttribute('id', checkboxUid + 'cboxLabel');\n elem.querySelector('input').setAttribute('aria-labelledby', label.id);\n if (label.innerHTML === this.getLocalizedLabel('Blanks')) {\n this.isBlanks = true;\n }\n if (typeof value === 'boolean') {\n label.innerHTML = value === true ? this.getLocalizedLabel('FilterTrue') : this.getLocalizedLabel('FilterFalse');\n }\n addClass([label], ['e-checkboxfiltertext']);\n if (this.options.template && data[this.options.column.field] !== this.getLocalizedLabel('SelectAll')\n && data[this.options.column.field] !== this.getLocalizedLabel('AddCurrentSelection')) {\n label.innerHTML = '';\n var isReactCompiler = this.parent.isReact && this.options.column.filter\n && typeof (this.options.column.filter.itemTemplate) !== 'string';\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.parent.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild) {\n this.options.template(dummyData, this.parent, 'filterItemTemplate', null, null, null, label);\n this.parent.renderTemplates();\n }\n else {\n appendChildren(label, this.options.template(dummyData, this.parent, 'filterItemTemplate'));\n }\n }\n return elem;\n };\n CheckBoxFilterBase.prototype.updateIndeterminatenBtn = function () {\n var cnt = this.infiniteRenderMod ? this.infiniteLoadedElem.length : this.cBox.children.length - 1;\n var className = [];\n var disabled = false;\n var elem = this.infiniteRenderMod ? this.sBox.querySelector('.e-selectall') : this.cBox.querySelector('.e-selectall');\n var selected = this.infiniteRenderMod ? this.infiniteLoadedElem.filter(function (arr) { return arr.querySelector('.e-check'); }).length :\n this.cBox.querySelectorAll('.e-check:not(.e-selectall):not(.e-add-current)').length;\n if (this.cBox.querySelector('.e-add-current')) {\n cnt -= 1;\n }\n var btn;\n if (!this.options.isResponsiveFilter) {\n btn = this.dialogObj.btnObj[0];\n btn.disabled = false;\n }\n var input = elem.previousSibling;\n setChecked(input, false);\n input.indeterminate = false;\n if (this.infiniteRenderMod && this.sInput.value === '' && !this.options.parentCurrentViewDataCount && !this.localInfiniteSelectionInteracted\n && (!this.localInfiniteSelectAllClicked || (!this.infiniteLocalSelectAll && !selected)) && (cnt !== selected || cnt === selected)) {\n selected = 0;\n }\n else if (this.infiniteRenderMod && this.infiniteLoadedElem.length < this.infiniteDataCount\n && this.infiniteUnloadParentExistPred.length && (!selected || cnt === selected) && this.infiniteLocalSelectAll) {\n if (!selected) {\n selected += this.infiniteUnloadParentExistPred.length;\n }\n else {\n cnt += this.infiniteUnloadParentExistPred.length;\n }\n }\n if (cnt === selected) {\n if (this.infiniteRenderMod) {\n this.infiniteLocalSelectAll = true;\n this.localInfiniteSelectAllClicked = true;\n this.infiniteManualSelectMaintainPred = [];\n }\n className = ['e-check'];\n setChecked(input, true);\n }\n else if (selected) {\n className = ['e-stop'];\n input.indeterminate = true;\n }\n else {\n if (this.infiniteRenderMod) {\n this.infiniteLocalSelectAll = false;\n this.localInfiniteSelectAllClicked = true;\n this.infiniteManualSelectMaintainPred = [];\n }\n className = ['e-uncheck'];\n disabled = true;\n if (btn) {\n btn.disabled = true;\n }\n }\n if (btn) {\n this.filterState = !btn.disabled;\n btn.dataBind();\n }\n removeClass([elem], ['e-check', 'e-stop', 'e-uncheck']);\n addClass([elem], className);\n this.parent.notify(events.refreshCustomFilterOkBtn, { disabled: disabled });\n };\n CheckBoxFilterBase.prototype.createFilterItems = function (data, isInitial, args1) {\n var _a, _b, _c;\n var cBoxes = this.parent.createElement('div');\n var btn;\n var disabled = false;\n if (!this.options.isResponsiveFilter) {\n btn = this.dialogObj.btnObj[0];\n }\n var nullCounter = -1;\n var key = 'ejValue';\n if (!args1.executeQuery) {\n key = args1.field;\n }\n for (var i = 0; i < data.length; i++) {\n var val = getValue(key, data[parseInt(i.toString(), 10)]);\n if (val === '' || isNullOrUndefined(val)) {\n nullCounter = nullCounter + 1;\n }\n }\n if (!this.infiniteRenderMod) {\n this.itemsCnt = nullCounter !== -1 ? data.length - nullCounter : data.length;\n }\n if (this.infiniteRenderMod && this.parent.filterSettings && this.parent.filterSettings.loadingIndicator === 'Shimmer') {\n this.removeMask();\n }\n if (data.length && !this.renderEmpty) {\n var selectAllValue = this.getLocalizedLabel('SelectAll');\n var innerDiv = this.cBox.querySelector('.e-checkfltrnmdiv');\n if (innerDiv) {\n innerDiv.classList.remove('e-checkfltrnmdiv');\n }\n var checkBox = this.createCheckbox(selectAllValue, false, (_a = {}, _a[this.options.field] = selectAllValue, _a));\n if (this.parent.cssClass) {\n if (this.parent.cssClass.indexOf(' ') !== -1) {\n addClass([checkBox], this.parent.cssClass.split(' '));\n }\n else {\n addClass([checkBox], [this.parent.cssClass]);\n }\n }\n if (this.infiniteInitialLoad || !this.infiniteRenderMod) {\n var selectAll = createCboxWithWrap(getUid('cbox'), checkBox, 'e-ftrchk');\n selectAll.querySelector('.e-frame').classList.add('e-selectall');\n if (this.infiniteRenderMod) {\n this.sBox.insertBefore(selectAll, this.spinner);\n }\n else {\n cBoxes.appendChild(selectAll);\n }\n }\n else if (this.sBox.querySelector('.e-ftrchk .e-selectall')) {\n this.sBox.querySelector('.e-ftrchk .e-selectall').previousSibling.disabled = false;\n this.sBox.querySelector('.e-ftrchk .e-selectall').parentElement.classList.remove('e-checkbox-disabled');\n }\n var predicate = new Predicate('field', 'equal', this.options.field);\n if (this.options.foreignKeyValue) {\n predicate = predicate.or('field', 'equal', this.options.foreignKeyValue);\n }\n var isColFiltered = new DataManager(this.options.filteredColumns).executeLocal(new Query().where(predicate)).length;\n if (this.sInput.value) {\n var predicateCheckBox = this.createCheckbox(this.getLocalizedLabel('AddCurrentSelection'), false, (_b = {},\n _b[this.options.field] = this.getLocalizedLabel('AddCurrentSelection'),\n _b));\n if (this.parent.cssClass) {\n if (this.parent.cssClass.indexOf(' ') !== -1) {\n addClass([predicateCheckBox], this.parent.cssClass.split(' '));\n }\n else {\n addClass([predicateCheckBox], [this.parent.cssClass]);\n }\n }\n if ((this.infiniteRenderMod && (!isNullOrUndefined(this.sBox.children[2])\n && this.sBox.children[2].innerText !== 'Add current selection to filter')) || !this.infiniteRenderMod) {\n var predicateElement = createCboxWithWrap(getUid('cbox'), predicateCheckBox, 'e-ftrchk');\n predicateElement.querySelector('.e-frame').classList.add('e-add-current');\n if (this.infiniteRenderMod) {\n this.sBox.insertBefore(predicateElement, this.spinner);\n var checkBoxListElem = this.spinner.querySelector('.e-checkboxlist');\n var reduceHeight = Math.ceil(predicateElement.getBoundingClientRect().height);\n checkBoxListElem.style.height = (parseInt(getComputedStyle(checkBoxListElem).height.split('px')[0]) - reduceHeight)\n + 'px';\n checkBoxListElem.style.minHeight = checkBoxListElem.style.height;\n }\n else {\n cBoxes.appendChild(predicateElement);\n }\n }\n else if (this.sBox.querySelector('.e-ftrchk .e-add-current')) {\n this.sBox.querySelector('.e-ftrchk .e-add-current').previousSibling.disabled = false;\n this.sBox.querySelector('.e-ftrchk .e-add-current').parentElement.classList.remove('e-checkbox-disabled');\n }\n }\n else if (this.infiniteRenderMod && !isNullOrUndefined(this.sBox.children[2])\n && this.sBox.children[2].innerText === 'Add current selection to filter') {\n var checkBoxListElem = this.spinner.querySelector('.e-checkboxlist');\n var increaseHeight = Math.ceil(this.sBox.children[2].getBoundingClientRect().height);\n checkBoxListElem.style.height = (parseInt(getComputedStyle(checkBoxListElem).height.split('px')[0]) + increaseHeight)\n + 'px';\n checkBoxListElem.style.minHeight = checkBoxListElem.style.height;\n remove(this.sBox.children[2]);\n }\n var isRndere = void 0;\n for (var i = 0; i < data.length; i++) {\n var uid = getUid('cbox');\n this.values[\"\" + uid] = getValue(key, data[parseInt(i.toString(), 10)]);\n var value = getValue(this.options.field, data[parseInt(i.toString(), 10)]);\n if (this.options.formatFn) {\n value = this.valueFormatter.toView(value, this.options.formatFn);\n }\n var args_1 = { value: value, column: this.options.column, data: data[parseInt(i.toString(), 10)] };\n this.parent.notify(events.filterCboxValue, args_1);\n value = args_1.value;\n if ((value === '' || isNullOrUndefined(value))) {\n if (isRndere) {\n continue;\n }\n isRndere = true;\n }\n if (this.infiniteRenderMod) {\n this.updateInfiniteUnLoadedCheckboxExistPred(value, this.infiniteUnloadParentExistPred);\n }\n var checkbox = this.localInfiniteSelectAllClicked ?\n this.createCheckbox(value, this.infiniteLocalSelectAll, getValue('dataObj', data[i])) :\n this.createCheckbox(value, this.getCheckedState(isColFiltered, this.values[\"\" + uid]), getValue('dataObj', data[i]));\n cBoxes.appendChild(createCboxWithWrap(uid, checkbox, 'e-ftrchk'));\n if (this.infiniteRenderMod) {\n cBoxes.lastChild.style.height = this.getListHeight(this.cBox) + 'px';\n }\n }\n var scrollTop = this.cBox.scrollTop;\n if (!this.infiniteRenderMod || this.infiniteSearchValChange) {\n this.cBox.innerHTML = '';\n }\n else if (this.infiniteRenderMod && this.cBox.children.length) {\n this.infiniteRemoveElements(([].slice.call(this.cBox.children)).splice(0, this.parent.filterSettings.itemsCount));\n }\n if (this.infiniteRenderMod) {\n (_c = this.infiniteLoadedElem).push.apply(_c, [].slice.call(cBoxes.children));\n this.itemsCnt = nullCounter !== -1 ? this.infiniteLoadedElem.length - nullCounter : this.infiniteLoadedElem.length;\n }\n if (this.infiniteUnloadParentExistPred.length && (this.infiniteLoadedElem.length >= this.infiniteDataCount\n || !this.options.parentCurrentViewDataCount || (this.options.parentTotalDataCount === this.infiniteDataCount\n && this.options.parentCurrentViewDataCount))) {\n this.infiniteUnloadParentExistPred = [];\n }\n appendChildren(this.cBox, [].slice.call(cBoxes.children));\n if (this.infiniteRenderMod && !this.infiniteScrollAppendDiff) {\n this.infiniteScrollAppendDiff = Math.round(scrollTop - this.cBox.scrollTop);\n }\n this.updateIndeterminatenBtn();\n if (!this.infiniteRenderMod) {\n if (btn) {\n btn.disabled = false;\n }\n disabled = false;\n }\n else {\n if (btn.disabled) {\n disabled = true;\n }\n else {\n disabled = false;\n }\n }\n }\n else {\n cBoxes.appendChild(this.parent.createElement('span', { innerHTML: this.getLocalizedLabel('NoResult') }));\n this.cBox.innerHTML = '';\n if (this.infiniteRenderMod) {\n var selectAll = this.sBox.querySelector('.e-ftrchk .e-selectall');\n if (selectAll) {\n var selectAllParent = selectAll.parentElement.parentElement;\n if (selectAll.classList.contains('e-check')) {\n toogleCheckbox(selectAllParent);\n }\n else if (selectAll.classList.contains('e-stop')) {\n toogleCheckbox(selectAllParent);\n selectAll.classList.remove('e-stop');\n toogleCheckbox(selectAllParent);\n }\n selectAll.previousSibling.disabled = true;\n selectAll.parentElement.classList.add('e-checkbox-disabled');\n }\n var addCurrSelection = this.sBox.querySelector('.e-ftrchk .e-add-current');\n if (addCurrSelection) {\n var addCurrSelectionParent = addCurrSelection.parentElement.parentElement;\n if (addCurrSelection.classList.contains('e-check')) {\n toogleCheckbox(addCurrSelectionParent);\n }\n addCurrSelection.previousSibling.disabled = true;\n addCurrSelection.parentElement.classList.add('e-checkbox-disabled');\n }\n }\n this.cBox.appendChild(this.parent.createElement('div', { className: 'e-checkfltrnmdiv' }));\n appendChildren(this.cBox.children[0], [].slice.call(cBoxes.children));\n if (btn) {\n btn.disabled = true;\n }\n disabled = true;\n this.filterState = !disabled;\n }\n if (btn && data.length) {\n this.filterState = !btn.disabled;\n btn.dataBind();\n }\n var args = { requestType: events.filterChoiceRequest, dataSource: this.renderEmpty ? [] : data };\n var filterModel = 'filterModel';\n args[\"\" + filterModel] = this;\n this.parent.notify(events.cBoxFltrComplete, args);\n this.parent.notify(events.refreshCustomFilterOkBtn, { disabled: disabled });\n if (this.infiniteRenderMod && this.infiniteInitialLoad) {\n this.cBox.style.marginTop = '0px';\n }\n hideSpinner(this.spinner);\n };\n CheckBoxFilterBase.prototype.updateInfiniteUnLoadedCheckboxExistPred = function (value, updatePredArr) {\n for (var j = 0; j < updatePredArr.length; j++) {\n var pred = updatePredArr[j];\n if (value === pred.value && (pred.operator === 'equal' || pred.operator === 'notequal')) {\n this.infiniteManualSelectMaintainPred.push(updatePredArr[j]);\n updatePredArr.splice(j, 1);\n j--;\n }\n }\n };\n CheckBoxFilterBase.prototype.getCheckedState = function (isColFiltered, value) {\n if (!this.isFiltered || !isColFiltered) {\n return true;\n }\n else {\n var checkState = this.sInput.value ? true : this.result[\"\" + value];\n if (this.infiniteRenderMod) {\n return checkState;\n }\n else {\n return this.options.operator === 'notequal' ? !checkState : checkState;\n }\n }\n };\n CheckBoxFilterBase.getDistinct = function (json, field, column, foreignKeyData, checkboxFilter) {\n var len = json.length;\n var result = [];\n var value;\n var ejValue = 'ejValue';\n var lookup = {};\n var isForeignKey = column && column.isForeignColumn ? column.isForeignColumn() : false;\n while (len--) {\n value = json[parseInt(len.toString(), 10)];\n if (column && column.type === 'dateonly' && typeof value[\"\" + field] === 'string' && value[\"\" + field]) {\n var arr = value[\"\" + field].split(/[^0-9.]/);\n value[\"\" + field] = new Date(parseInt(arr[0], 10), parseInt(arr[1], 10) - 1, parseInt(arr[2], 10));\n }\n value = getObject(field, value); //local remote diff, check with mdu\n var currentFilterValue = (typeof value === 'string') && !(isNullOrUndefined(checkboxFilter)) &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !(isNullOrUndefined(checkboxFilter.parent)) && !(isNullOrUndefined(checkboxFilter.parent.filterSettings)) &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !(isNullOrUndefined(checkboxFilter.parent.filterSettings.enableCaseSensitivity)) ? value.toLowerCase() : value;\n if (!(currentFilterValue in lookup)) {\n var obj = {};\n obj[\"\" + ejValue] = value;\n lookup[\"\" + currentFilterValue] = true;\n if (isForeignKey) {\n var foreignDataObj = getForeignData(column, {}, value, foreignKeyData)[0];\n setValue(events.foreignKeyData, foreignDataObj, json[parseInt(len.toString(), 10)]);\n value = getValue(column.foreignKeyValue, foreignDataObj);\n }\n setValue(field, isNullOrUndefined(value) ? null : value, obj);\n setValue('dataObj', json[parseInt(len.toString(), 10)], obj);\n result.push(obj);\n }\n }\n return DataUtil.group(DataUtil.sort(result, field, DataUtil.fnAscending), 'ejValue');\n };\n CheckBoxFilterBase.getPredicate = function (columns, isExecuteLocal) {\n var cols = DataUtil.distinct(columns, 'field', true) || [];\n var collection = [];\n var pred = {};\n for (var i = 0; i < cols.length; i++) {\n collection = new DataManager(columns).executeLocal(new Query().where('field', 'equal', cols[parseInt(i.toString(), 10)].field));\n if (collection.length !== 0) {\n pred[cols[parseInt(i.toString(), 10)].field] = CheckBoxFilterBase.generatePredicate(collection, isExecuteLocal);\n }\n }\n return pred;\n };\n CheckBoxFilterBase.generatePredicate = function (cols, isExecuteLocal) {\n var len = cols ? cols.length : 0;\n var predicate;\n var operate = 'or';\n var first = CheckBoxFilterBase.updateDateFilter(cols[0]);\n first.ignoreAccent = !isNullOrUndefined(first.ignoreAccent) ? first.ignoreAccent : false;\n if (first.type === 'date' || first.type === 'datetime' || first.type === 'dateonly') {\n predicate = getDatePredicate(first, first.type, isExecuteLocal);\n }\n else {\n predicate = first.ejpredicate ? first.ejpredicate :\n new Predicate(first.field, first.operator, first.value, !CheckBoxFilterBase.getCaseValue(first), first.ignoreAccent);\n }\n for (var p = 1; p < len; p++) {\n cols[parseInt(p.toString(), 10)] = CheckBoxFilterBase.updateDateFilter(cols[parseInt(p.toString(), 10)]);\n if (len > 2 && p > 1 && ((cols[p].predicate === 'or' && cols[p - 1].predicate === 'or')\n || (cols[p].predicate === 'and' && cols[p - 1].predicate === 'and'))) {\n if (cols[p].type === 'date' || cols[p].type === 'datetime' || cols[p].type === 'dateonly') {\n predicate.predicates.push(getDatePredicate(cols[parseInt(p.toString(), 10)], cols[p].type, isExecuteLocal));\n }\n else {\n predicate.predicates.push(new Predicate(cols[p].field, cols[parseInt(p.toString(), 10)].operator, cols[parseInt(p.toString(), 10)].value, !CheckBoxFilterBase.getCaseValue(cols[parseInt(p.toString(), 10)]), cols[parseInt(p.toString(), 10)].ignoreAccent));\n }\n }\n else {\n if (cols[p].type === 'date' || cols[p].type === 'datetime' || cols[p].type === 'dateonly') {\n if (cols[parseInt(p.toString(), 10)].predicate === 'and' && cols[parseInt(p.toString(), 10)].operator === 'equal') {\n predicate = predicate[\"\" + operate](getDatePredicate(cols[parseInt(p.toString(), 10)], cols[parseInt(p.toString(), 10)].type, isExecuteLocal), cols[parseInt(p.toString(), 10)].type, cols[parseInt(p.toString(), 10)].ignoreAccent);\n }\n else {\n predicate = predicate[(cols[parseInt(p.toString(), 10)].predicate)](getDatePredicate(cols[parseInt(p.toString(), 10)], cols[parseInt(p.toString(), 10)].type, isExecuteLocal), cols[parseInt(p.toString(), 10)].type, cols[parseInt(p.toString(), 10)].ignoreAccent);\n }\n }\n else {\n predicate = cols[parseInt(p.toString(), 10)].ejpredicate ?\n predicate[cols[parseInt(p.toString(), 10)]\n .predicate](cols[parseInt(p.toString(), 10)].ejpredicate) :\n predicate[(cols[parseInt(p.toString(), 10)].predicate)](cols[parseInt(p.toString(), 10)].field, cols[parseInt(p.toString(), 10)].operator, cols[parseInt(p.toString(), 10)].value, !CheckBoxFilterBase.getCaseValue(cols[parseInt(p.toString(), 10)]), cols[parseInt(p.toString(), 10)].ignoreAccent);\n }\n }\n }\n return predicate || null;\n };\n CheckBoxFilterBase.getCaseValue = function (filter) {\n if (isNullOrUndefined(filter.matchCase)) {\n if (filter.type === 'string' || isNullOrUndefined(filter.type) && typeof (filter.value) === 'string') {\n return false;\n }\n else {\n return true;\n }\n }\n else {\n return filter.matchCase;\n }\n };\n CheckBoxFilterBase.updateDateFilter = function (filter) {\n if ((filter.type === 'date' || filter.type === 'datetime' || filter.type === 'dateonly' || filter.value instanceof Date)) {\n filter.type = filter.type || 'date';\n }\n return filter;\n };\n return CheckBoxFilterBase;\n}());\nexport { CheckBoxFilterBase };\n","//! moment.js locale configuration\n//! locale : Bambara [bm]\n//! author : Estelle Comment : https://github.com/estellecomment\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var bm = moment.defineLocale('bm', {\n months: 'Zanwuyekalo_Fewuruyekalo_Marisikalo_Awirilikalo_MÉ›kalo_ZuwÉ›nkalo_Zuluyekalo_Utikalo_SÉ›tanburukalo_É”kutÉ”burukalo_Nowanburukalo_Desanburukalo'.split(\n '_'\n ),\n monthsShort: 'Zan_Few_Mar_Awi_MÉ›_Zuw_Zul_Uti_SÉ›t_É”ku_Now_Des'.split('_'),\n weekdays: 'Kari_NtÉ›nÉ›n_Tarata_Araba_Alamisa_Juma_Sibiri'.split('_'),\n weekdaysShort: 'Kar_NtÉ›_Tar_Ara_Ala_Jum_Sib'.split('_'),\n weekdaysMin: 'Ka_Nt_Ta_Ar_Al_Ju_Si'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'MMMM [tile] D [san] YYYY',\n LLL: 'MMMM [tile] D [san] YYYY [lÉ›rÉ›] HH:mm',\n LLLL: 'dddd MMMM [tile] D [san] YYYY [lÉ›rÉ›] HH:mm',\n },\n calendar: {\n sameDay: '[Bi lÉ›rÉ›] LT',\n nextDay: '[Sini lÉ›rÉ›] LT',\n nextWeek: 'dddd [don lÉ›rÉ›] LT',\n lastDay: '[Kunu lÉ›rÉ›] LT',\n lastWeek: 'dddd [tÉ›mÉ›nen lÉ›rÉ›] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s kÉ”nÉ”',\n past: 'a bÉ› %s bÉ”',\n s: 'sanga dama dama',\n ss: 'sekondi %d',\n m: 'miniti kelen',\n mm: 'miniti %d',\n h: 'lÉ›rÉ› kelen',\n hh: 'lÉ›rÉ› %d',\n d: 'tile kelen',\n dd: 'tile %d',\n M: 'kalo kelen',\n MM: 'kalo %d',\n y: 'san kelen',\n yy: 'san %d',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return bm;\n\n})));\n","import { remove, addClass } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { doesImplementInterface, setStyleAndAttributes, appendChildren, extendObjWithFn, addStickyColumnPosition } from '../base/util';\nimport { createCheckBox } from '@syncfusion/ej2-buttons';\nimport { foreignKeyData } from '../base/constant';\nimport { CellType } from '../base/enum';\nimport * as literals from '../base/string-literals';\n/**\n * CellRenderer class which responsible for building cell content.\n *\n * @hidden\n */\nvar CellRenderer = /** @class */ (function () {\n function CellRenderer(parent, locator) {\n this.localizer = locator.getService('localization');\n this.formatter = locator.getService('valueFormatter');\n this.parent = parent;\n this.element = this.parent.createElement('TD', { className: literals.rowCell, attrs: { role: 'gridcell', tabindex: '-1' } });\n this.rowChkBox = this.parent.createElement('input', { className: 'e-checkselect', attrs: { 'type': 'checkbox', 'aria-label': this.localizer.getConstant('SelectRow') } });\n }\n /**\n * Function to return the wrapper for the TD content\n *\n * @returns {string | Element} returns the string\n */\n CellRenderer.prototype.getGui = function () {\n return '';\n };\n /**\n * Function to format the cell value.\n *\n * @param {Column} column - specifies the column\n * @param {Object} value - specifies the value\n * @param {Object} data - specifies the data\n * @returns {string} returns the format\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n CellRenderer.prototype.format = function (column, value, data) {\n if (!isNullOrUndefined(column.format)) {\n if (column.type === 'number' && isNaN(parseInt(value, 10))) {\n value = null;\n }\n if (column.type === 'dateonly' && typeof value === 'string' && value) {\n var arr = value.split(/[^0-9.]/);\n value = new Date(parseInt(arr[0], 10), parseInt(arr[1], 10) - 1, parseInt(arr[2], 10));\n }\n value = this.formatter.toView(value, column.getFormatter());\n }\n return isNullOrUndefined(value) ? '' : value.toString();\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n CellRenderer.prototype.evaluate = function (node, cell, data, attributes, fData, isEdit) {\n var _a;\n var result;\n if (cell.column.template) {\n var isReactCompiler = this.parent.isReact && typeof (cell.column.template) !== 'string' && cell.column.template.prototype && !(cell.column.template.prototype).CSPTemplate;\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n var literals_1 = ['index'];\n var dummyData = extendObjWithFn({}, data, (_a = {}, _a[foreignKeyData] = fData, _a.column = cell.column, _a));\n var templateID = this.parent.element.id + cell.column.uid;\n var str = 'isStringTemplate';\n if (isReactCompiler || isReactChild) {\n var copied = { 'index': attributes[literals_1[0]] };\n cell.column.getColumnTemplate()(extend(copied, dummyData), this.parent, 'columnTemplate', templateID, this.parent[\"\" + str], null, node);\n }\n else {\n result = cell.column.getColumnTemplate()(extend({ 'index': attributes[literals_1[0]] }, dummyData), this.parent, 'template', templateID, this.parent[\"\" + str], undefined, undefined, this.parent['root']);\n }\n if (!isReactCompiler && !isReactChild) {\n appendChildren(node, result);\n }\n this.parent.notify('template-result', { template: result });\n result = null;\n node.setAttribute('aria-label', node.innerText + this.localizer.getConstant('TemplateCell') +\n this.localizer.getConstant('ColumnHeader') + cell.column.headerText);\n return false;\n }\n return true;\n };\n /**\n * Function to invoke the custom formatter available in the column object.\n *\n * @param {Column} column - specifies the column\n * @param {Object} value - specifies the value\n * @param {Object} data - specifies the data\n * @returns {Object} returns the object\n */\n CellRenderer.prototype.invokeFormatter = function (column, value, data) {\n if (!isNullOrUndefined(column.formatter)) {\n if (doesImplementInterface(column.formatter, 'getValue')) {\n var formatter = column.formatter;\n value = new formatter().getValue(column, data);\n }\n else if (typeof column.formatter === 'function') {\n value = column.formatter(column, data);\n }\n else {\n value = column.formatter.getValue(column, data);\n }\n }\n return value;\n };\n /**\n * Function to render the cell content based on Column object.\n *\n * @param {Cell<Column>} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @param {Object} attributes - specifies the attributes\n * @param {boolean} isExpand - specifies the boolean for expand\n * @param {boolean} isEdit - specifies the boolean for edit\n * @returns {Element} returns the element\n */\n CellRenderer.prototype.render = function (cell, data, attributes, isExpand, isEdit) {\n return this.refreshCell(cell, data, attributes, isEdit);\n };\n /**\n * Function to refresh the cell content based on Column object.\n *\n * @param {Element} td - specifies the element\n * @param {Cell<Column>} cell - specifies the cell\n * @param {Object} data - specifies the data\n * @param {Object} attributes - specifies the attribute\n * @returns {void}\n */\n CellRenderer.prototype.refreshTD = function (td, cell, data, attributes) {\n var isEdit = this.parent.editSettings.mode === 'Batch' && td.classList.contains('e-editedbatchcell');\n if (this.parent.isReact) {\n var cellIndex = td.cellIndex;\n var parentRow = td.parentElement;\n remove(td);\n var newTD = this.refreshCell(cell, data, attributes, isEdit);\n this.cloneAttributes(newTD, td);\n if (parentRow.cells.length !== cellIndex - 1) {\n parentRow.insertBefore(newTD, parentRow.cells[parseInt(cellIndex.toString(), 10)]);\n }\n else {\n parentRow.appendChild(newTD);\n }\n }\n else {\n var node = this.refreshCell(cell, data, attributes, isEdit);\n td.innerHTML = '';\n var arialabelText = node.getAttribute('aria-label');\n arialabelText ? td.setAttribute('aria-label', arialabelText) : null;\n var elements = [].slice.call(node.childNodes);\n for (var _i = 0, elements_1 = elements; _i < elements_1.length; _i++) {\n var elem = elements_1[_i];\n td.appendChild(elem);\n }\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n CellRenderer.prototype.cloneAttributes = function (target, source) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var attrs = source.attributes;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var i = attrs.length;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var attr;\n while (i--) {\n attr = attrs[parseInt(i.toString(), 10)];\n target.setAttribute(attr.name, attr.value);\n }\n };\n CellRenderer.prototype.refreshCell = function (cell, data, attributes, isEdit) {\n var _a;\n var node = this.element.cloneNode();\n var column = cell.column;\n var fData;\n if (cell.isForeignKey) {\n fData = cell.foreignKeyData[0] || (_a = {}, _a[column.foreignKeyValue] = column.format ? null : '', _a);\n }\n //Prepare innerHtml\n var innerHtml = this.getGui();\n var value = cell.isForeignKey ? this.getValue(column.foreignKeyValue, fData, column) :\n this.getValue(column.field, data, column);\n if ((column.type === 'date' || column.type === 'datetime') && !isNullOrUndefined(value)) {\n value = new Date(value);\n }\n if (column.type === 'dateonly' && !isNullOrUndefined(value) && typeof value === 'string') {\n var arr = value.split(/[^0-9.]/);\n value = new Date(parseInt(arr[0], 10), parseInt(arr[1], 10) - 1, parseInt(arr[2], 10));\n }\n value = this.format(column, value, data);\n innerHtml = value.toString();\n if (column.type === 'boolean' && !column.displayAsCheckBox) {\n var localeStr = (value !== 'true' && value !== 'false') ? null : value === 'true' ? 'True' : 'False';\n innerHtml = localeStr ? this.localizer.getConstant(localeStr) : innerHtml;\n }\n var fromFormatter = this.invokeFormatter(column, value, data);\n innerHtml = !isNullOrUndefined(column.formatter) ? isNullOrUndefined(fromFormatter) ? '' : fromFormatter.toString() : innerHtml;\n if (this.evaluate(node, cell, data, attributes, fData, isEdit) && column.type !== 'checkbox') {\n this.appendHtml(node, this.parent.sanitize(innerHtml), column.getDomSetter ? column.getDomSetter() : 'innerHTML');\n }\n else if (column.type === 'checkbox') {\n node.classList.add(literals.gridChkBox);\n if (this.parent.selectionSettings.persistSelection) {\n value = value === 'true';\n }\n else {\n value = false;\n }\n var checkWrap = createCheckBox(this.parent.createElement, false, { checked: value, label: ' ' });\n if (this.parent.cssClass) {\n addClass([checkWrap], [this.parent.cssClass]);\n }\n this.rowChkBox.id = 'checkbox-' + cell.rowID;\n checkWrap.insertBefore(this.rowChkBox.cloneNode(), checkWrap.firstChild);\n node.appendChild(checkWrap);\n }\n if (this.parent.checkAllRows === 'Check' && this.parent.enableVirtualization) {\n cell.isSelected = true;\n }\n this.setAttributes(node, cell, attributes);\n if (column.type === 'boolean' && column.displayAsCheckBox) {\n var checked = isNaN(parseInt(value.toString(), 10)) ? value === 'true' : parseInt(value.toString(), 10) > 0;\n var checkWrap = createCheckBox(this.parent.createElement, false, { checked: checked, label: ' ' });\n node.innerHTML = '';\n node.classList.add('e-gridchkbox-cell');\n checkWrap.classList.add('e-checkbox-disabled');\n if (this.parent.cssClass) {\n addClass([checkWrap], [this.parent.cssClass]);\n }\n node.appendChild(checkWrap);\n }\n if (node.classList.contains('e-summarycell') && !data.key) {\n var uid = node.getAttribute('e-mappinguid');\n column = this.parent.getColumnByUid(uid);\n node.setAttribute('aria-label', innerHtml + this.localizer.getConstant('ColumnHeader') + cell.column.headerText);\n }\n if (this.parent.isFrozenGrid() && (!data || (data && !data.key))) {\n addStickyColumnPosition(this.parent, column, node);\n }\n return node;\n };\n /**\n * Function to specifies how the result content to be placed in the cell.\n *\n * @param {Element} node - specifies the node\n * @param {string|Element} innerHtml - specifies the innerHTML\n * @param {string} property - specifies the element\n * @returns {Element} returns the element\n */\n CellRenderer.prototype.appendHtml = function (node, innerHtml, property) {\n if (property === void 0) { property = 'innerHTML'; }\n node[\"\" + property] = innerHtml;\n return node;\n };\n /**\n * @param {HTMLElement} node - specifies the node\n * @param {cell<Column>} cell - specifies the cell\n * @param {Object} attributes - specifies the attributes\n * @returns {void}\n * @hidden\n */\n CellRenderer.prototype.setAttributes = function (node, cell, attributes) {\n var column = cell.column;\n this.buildAttributeFromCell(node, cell, column.type === 'checkbox');\n setStyleAndAttributes(node, attributes);\n setStyleAndAttributes(node, cell.attributes);\n if (column.customAttributes) {\n setStyleAndAttributes(node, column.customAttributes);\n }\n if (this.parent.rowRenderingMode === 'Vertical') {\n setStyleAndAttributes(node, { 'data-cell': column.headerText });\n }\n if (column.textAlign) {\n node.style.textAlign = column.textAlign;\n }\n if (column.clipMode === 'Clip' || (!column.clipMode && this.parent.clipMode === 'Clip')) {\n node.classList.add('e-gridclip');\n }\n else if (column.clipMode === 'EllipsisWithTooltip' || (!column.clipMode && this.parent.clipMode === 'EllipsisWithTooltip')\n && !(this.parent.allowTextWrap && (this.parent.textWrapSettings.wrapMode === 'Content'\n || this.parent.textWrapSettings.wrapMode === 'Both'))) {\n if (column.type !== 'checkbox') {\n node.classList.add('e-ellipsistooltip');\n }\n }\n };\n CellRenderer.prototype.buildAttributeFromCell = function (node, cell, isCheckBoxType) {\n var attr = {};\n var prop = { 'colindex': literals.dataColIndex };\n var classes = [];\n if (cell.colSpan) {\n attr.colSpan = cell.colSpan;\n }\n if (cell.rowSpan) {\n attr.rowSpan = cell.rowSpan;\n }\n if (cell.isTemplate) {\n classes.push('e-templatecell');\n }\n if (cell.isSelected) {\n classes.push.apply(classes, ['e-selectionbackground', 'e-active']);\n if (isCheckBoxType) {\n node.querySelector('.e-frame').classList.add('e-check');\n }\n }\n if (cell.isColumnSelected) {\n classes.push.apply(classes, ['e-columnselection']);\n }\n if (cell.cellType === CellType.Header) {\n attr[prop.colindex] = cell.colIndex;\n attr[literals.ariaColIndex] = cell.colIndex + 1;\n }\n else if (!isNullOrUndefined(cell.index)) {\n attr[prop.colindex] = cell.index;\n attr[literals.ariaColIndex] = cell.index + 1;\n }\n if (!cell.visible) {\n classes.push('e-hide');\n }\n attr.class = classes;\n setStyleAndAttributes(node, attr);\n };\n CellRenderer.prototype.getValue = function (field, data, column) {\n return column.valueAccessor(field, data, column);\n };\n return CellRenderer;\n}());\nexport { CellRenderer };\n","import { isNullOrUndefined, addClass, extend } from '@syncfusion/ej2-base';\nimport { appendChildren, setStyleAndAttributes, addFixedColumnBorder, addStickyColumnPosition } from '../base/util';\nimport * as literals from '../base/string-literals';\n/**\n * Edit render module is used to render grid edit row.\n *\n * @hidden\n */\nvar InlineEditRender = /** @class */ (function () {\n /**\n * Constructor for render module\n *\n * @param {IGrid} parent - returns the IGrid\n */\n function InlineEditRender(parent) {\n this.parent = parent;\n }\n InlineEditRender.prototype.addNew = function (elements, args) {\n this.isEdit = false;\n var tbody;\n if (this.parent.frozenRows && this.parent.editSettings.newRowPosition === 'Top') {\n tbody = this.parent.getHeaderTable().querySelector(literals.tbody);\n }\n else {\n tbody = this.parent.getContentTable().querySelector(literals.tbody);\n }\n args.row = this.parent.createElement('tr', { className: 'e-row e-addedrow' });\n if (this.parent.getContentTable().querySelector('.e-emptyrow')) {\n var emptyRow = this.parent.getContentTable().querySelector('.e-emptyrow');\n emptyRow.parentNode.removeChild(emptyRow);\n if (this.parent.frozenRows && this.parent.element.querySelector('.e-frozenrow-empty')) {\n this.parent.element.querySelector('.e-frozenrow-empty').classList.remove('e-frozenrow-empty');\n }\n }\n if (this.parent.editSettings.newRowPosition === 'Top') {\n tbody.insertBefore(args.row, tbody.firstChild);\n }\n else {\n tbody.appendChild(args.row);\n }\n args.row.appendChild(this.getEditElement(elements, false, undefined, args, true));\n this.parent.editModule.checkLastRow(args.row, args);\n };\n InlineEditRender.prototype.update = function (elements, args) {\n this.isEdit = true;\n var tdElement = [].slice.call(args.row.querySelectorAll('td.e-rowcell'));\n args.row.innerHTML = '';\n args.row.appendChild(this.getEditElement(elements, true, tdElement, args, true));\n args.row.classList.add(literals.editedRow);\n this.parent.editModule.checkLastRow(args.row, args);\n };\n // eslint-disable-next-line max-len\n InlineEditRender.prototype.getEditElement = function (elements, isEdit, tdElement, args, isFrozen) {\n var gObj = this.parent;\n var gLen = 0;\n var isDetail = !isNullOrUndefined(gObj.detailTemplate) || !isNullOrUndefined(gObj.childGrid) ? 1 : 0;\n if (gObj.allowGrouping) {\n gLen = gObj.groupSettings.columns.length;\n }\n var td = this.parent.createElement('td', {\n className: 'e-editcell e-normaledit',\n attrs: {\n colspan: (gObj.getCurrentVisibleColumns(this.parent.enableColumnVirtualization).length +\n this.parent.getIndentCount()).toString()\n }\n });\n var form = args.form =\n this.parent.createElement('form', { id: gObj.element.id + 'EditForm', className: 'e-gridform' });\n if (this.parent.editSettings.template) {\n this.appendChildren(form, args.rowData, isFrozen);\n td.appendChild(form);\n return td;\n }\n var table = this.parent.createElement('table', { className: 'e-table e-inline-edit', attrs: { cellspacing: '0.25', role: 'grid' } });\n table.appendChild(gObj.getContentTable().querySelector(literals.colGroup).cloneNode(true));\n var tbody = this.parent.createElement(literals.tbody, { attrs: { role: 'rowgroup' } });\n var tr = this.parent.createElement('tr');\n var i = 0;\n if (isDetail) {\n tr.insertBefore(this.parent.createElement('td', { className: 'e-detailrowcollapse' }), tr.firstChild);\n }\n if (gObj.isRowDragable()) {\n tr.appendChild(this.parent.createElement('td', { className: 'e-dragindentcell' }));\n }\n while (i < gLen) {\n tr.appendChild(this.parent.createElement('td', { className: 'e-indentcell' }));\n i++;\n }\n var m = 0;\n i = 0;\n var inputValue;\n var cols = args.isCustomFormValidation ? this.parent.columnModel : gObj.getColumns();\n while ((isEdit && m < tdElement.length && i < cols.length) || i < cols.length) {\n var span = isEdit ? tdElement[parseInt(m.toString(), 10)].getAttribute('colspan') : null;\n var col = cols[parseInt(i.toString(), 10)];\n inputValue = (elements[col.uid]).value;\n var td_1 = this.parent.createElement('td', {\n className: literals.rowCell, attrs: { style: 'text-align:' + (col.textAlign ? col.textAlign : ''), 'colspan': span ? span : '' }\n });\n if (col.visible) {\n td_1.appendChild(elements[col.uid]);\n if (this.parent.rowRenderingMode === 'Vertical') {\n setStyleAndAttributes(td_1, { 'data-cell': col.headerText });\n if (i === 0) {\n td_1.classList.add('e-responsive-editcell');\n }\n }\n if (col.editType === 'booleanedit') {\n td_1.classList.add('e-boolcell');\n }\n else if (col.commands || col.commandsTemplate) {\n addClass([td_1], 'e-unboundcell');\n }\n }\n else {\n td_1.classList.add('e-hide');\n }\n if (this.parent.isFrozenGrid()) {\n addStickyColumnPosition(this.parent, col, td_1);\n if (this.parent.enableColumnVirtualization) {\n if (col.freeze === 'Left' && !isNullOrUndefined(col.valueX)) {\n td_1.style.left = (col.valueX - this.parent.translateX) + 'px';\n }\n else if (col.freeze === 'Right' && !isNullOrUndefined(col.valueX)) {\n td_1.style.right = (col.valueX + this.parent.translateX) + 'px';\n }\n else if (col.freeze === 'Fixed') {\n td_1.style.left = (this.parent.leftrightColumnWidth('left') - this.parent.translateX) + 'px';\n td_1.style.right = (this.parent.leftrightColumnWidth('right') + this.parent.translateX) + 'px';\n }\n }\n }\n td_1.setAttribute('aria-label', inputValue + this.parent.localeObj.getConstant('ColumnHeader') + col.headerText);\n tr.appendChild(td_1);\n i = span ? i + parseInt(span, 10) : i + 1;\n m++;\n }\n addFixedColumnBorder(tr);\n tbody.appendChild(tr);\n table.appendChild(tbody);\n form.appendChild(table);\n td.appendChild(form);\n return td;\n };\n InlineEditRender.prototype.removeEventListener = function () {\n //To destroy the renderer\n };\n InlineEditRender.prototype.appendChildren = function (form, data, isFrozen) {\n var _this = this;\n var dummyData = extend({}, data, { isAdd: !this.isEdit, isFrozen: isFrozen }, true);\n var editTemplateID = this.parent.element.id + 'editSettingsTemplate';\n if (this.parent.isReact && typeof (this.parent.editSettings.template) !== 'string') {\n this.parent.getEditTemplate()(dummyData, this.parent, 'editSettingsTemplate', editTemplateID, null, null, form);\n this.parent.renderTemplates();\n }\n else {\n appendChildren(form, this.parent.getEditTemplate()(dummyData, this.parent, 'editSettingsTemplate', editTemplateID));\n }\n // eslint-disable-next-line\n var setRules = function () {\n var cols = _this.parent.getColumns();\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].validationRules) {\n _this.parent.editModule.formObj.rules[cols[parseInt(i.toString(), 10)].field] =\n cols[parseInt(i.toString(), 10)].validationRules;\n }\n }\n };\n };\n return InlineEditRender;\n}());\nexport { InlineEditRender };\n","import { classList } from '@syncfusion/ej2-base';\nimport * as literals from '../base/string-literals';\n/**\n * Edit render module is used to render grid edit row.\n *\n * @hidden\n */\nvar BatchEditRender = /** @class */ (function () {\n /**\n * Constructor for render module\n *\n * @param {IGrid} parent - specifies the IGrid\n */\n function BatchEditRender(parent) {\n this.parent = parent;\n }\n BatchEditRender.prototype.update = function (elements, args) {\n if (this.parent.isReact && args.columnObject && args.columnObject.template) {\n var parentRow = args.cell.parentElement;\n var newTd = args.cell.cloneNode(true);\n parentRow.insertBefore(newTd, args.cell);\n newTd.focus();\n args.cell.remove();\n args.cell = newTd;\n }\n args.cell.setAttribute('aria-label', args.cell.innerHTML + this.parent.localeObj.getConstant('ColumnHeader') + args.columnObject.field);\n args.cell.innerHTML = '';\n args.cell.appendChild(this.getEditElement(elements, args));\n args.cell.classList.add('e-editedbatchcell');\n classList(args.row, [literals.editedRow, 'e-batchrow'], []);\n };\n BatchEditRender.prototype.getEditElement = function (elements, args) {\n var gObj = this.parent;\n var form = this.parent\n .createElement('form', { id: gObj.element.id + 'EditForm', className: 'e-gridform' });\n form.appendChild(elements[args.columnObject.uid]);\n if (args.columnObject.editType === 'booleanedit') {\n args.cell.classList.add('e-boolcell');\n }\n if (!args.columnObject.editType) {\n args.cell.classList.add('e-inputbox');\n }\n return form;\n };\n BatchEditRender.prototype.removeEventListener = function () {\n //To destroy the renderer\n };\n return BatchEditRender;\n}());\nexport { BatchEditRender };\n","import { Dialog } from '@syncfusion/ej2-popups';\nimport { remove, extend, updateBlazorTemplate, initializeCSPTemplate } from '@syncfusion/ej2-base';\nimport * as events from '../base/constant';\nimport { appendChildren, applyBiggerTheme, addBiggerDialog } from '../base/util';\nimport { ResponsiveDialogRenderer } from './responsive-dialog-renderer';\nimport { ResponsiveDialogAction } from '../base/enum';\nimport * as literals from '../base/string-literals';\n/**\n * Edit render module is used to render grid edit row.\n *\n * @hidden\n */\nvar DialogEditRender = /** @class */ (function () {\n /**\n * Constructor for render module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {ServiceLocator} serviceLocator - specifies the serviceLocator\n */\n function DialogEditRender(parent, serviceLocator) {\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.dialogDestroy, this.destroy, this);\n this.parent.on(events.destroy, this.destroy, this);\n }\n DialogEditRender.prototype.setLocaleObj = function () {\n this.l10n = this.serviceLocator.getService('localization');\n };\n DialogEditRender.prototype.addNew = function (elements, args) {\n this.isEdit = false;\n this.createDialog(elements, args);\n };\n DialogEditRender.prototype.update = function (elements, args) {\n this.isEdit = true;\n this.createDialog(elements, args);\n };\n DialogEditRender.prototype.createDialogHeader = function (args) {\n var _this = this;\n var gObj = this.parent;\n var header;\n if (this.parent.enableAdaptiveUI) {\n var responsiveDlgRenderer = new ResponsiveDialogRenderer(this.parent, this.serviceLocator);\n responsiveDlgRenderer.action = this.isEdit ? ResponsiveDialogAction.isEdit : ResponsiveDialogAction.isAdd;\n return responsiveDlgRenderer.renderResponsiveHeader(undefined, args);\n }\n else {\n if (gObj.editSettings.headerTemplate) {\n header = initializeCSPTemplate(function () {\n return _this.getDialogEditTemplateElement('HeaderTemplate', args).outerHTML;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n });\n }\n else if (this.isEdit) {\n header = this.l10n.getConstant('EditFormTitle') + args.primaryKeyValue[0];\n }\n else {\n header = this.l10n.getConstant('AddFormTitle');\n }\n }\n return header;\n };\n DialogEditRender.prototype.createDialog = function (elements, args) {\n var _this = this;\n var gObj = this.parent;\n this.dialog = this.parent.createElement('div', { id: gObj.element.id + '_dialogEdit_wrapper', styles: 'width: auto' });\n if (gObj.enableAdaptiveUI) {\n this.dialog.classList.add('e-responsive-dialog');\n }\n gObj.element.appendChild(this.dialog);\n this.setLocaleObj();\n this.dialog.setAttribute('aria-label', this.l10n.getConstant('DialogEdit'));\n // let position: PositionDataModel = this.parent.element.getBoundingClientRect().height < 400 ?\n // { X: 'center', Y: 'top' } : { X: 'center', Y: 'center' };\n this.dialogObj = new Dialog(extend({\n header: this.createDialogHeader(args), isModal: true, visible: true,\n cssClass: this.parent.cssClass ? 'e-edit-dialog' + ' ' + this.parent.cssClass : 'e-edit-dialog',\n content: this.getEditElement(elements, args),\n showCloseIcon: true,\n allowDragging: true,\n // position: position,\n close: this.dialogClose.bind(this),\n created: this.dialogCreated.bind(this),\n closeOnEscape: true, width: gObj.editSettings.template ? 'auto' : '330px',\n target: args.target ? args.target : document.body, animationSettings: { effect: 'None' },\n footerTemplate: gObj.editSettings.footerTemplate ? initializeCSPTemplate(function () {\n return _this.getDialogEditTemplateElement('FooterTemplate', args).outerHTML;\n }) : null,\n buttons: [{\n click: this.btnClick.bind(this),\n buttonModel: { content: this.l10n.getConstant('SaveButton'),\n cssClass: this.parent.cssClass ? 'e-primary' + ' ' + this.parent.cssClass : 'e-primary',\n isPrimary: true }\n },\n { click: this.btnClick.bind(this),\n buttonModel: {\n cssClass: this.parent.cssClass ? 'e-flat' + ' ' + this.parent.cssClass : 'e-flat',\n content: this.l10n.getConstant('CancelButton')\n } }]\n }, gObj.editSettings.dialog ? (gObj.editSettings.dialog.params || {}) : {}));\n args.dialog = this.dialogObj;\n var isStringTemplate = 'isStringTemplate';\n this.dialogObj[\"\" + isStringTemplate] = true;\n this.renderResponsiveDialog();\n this.dialogObj.appendTo(this.dialog);\n applyBiggerTheme(this.parent.element, this.dialogObj.element.parentElement);\n if (gObj.enableAdaptiveUI) {\n this.dialogObj.show(true);\n }\n };\n DialogEditRender.prototype.dialogCreated = function () {\n addBiggerDialog(this.parent);\n };\n DialogEditRender.prototype.renderResponsiveDialog = function () {\n var _this = this;\n if (this.parent.enableAdaptiveUI) {\n if (this.parent.adaptiveDlgTarget) {\n this.dialogObj.target = this.parent.adaptiveDlgTarget;\n }\n this.dialogObj.buttons = [{}];\n this.dialogObj.showCloseIcon = true;\n this.dialogObj.visible = false;\n this.dialogObj.width = '100%';\n this.dialogObj.open = function () {\n _this.dialogObj.element.style.maxHeight = '100%';\n };\n }\n };\n DialogEditRender.prototype.btnClick = function (e) {\n if (this.l10n.getConstant('CancelButton').toLowerCase() === e.target.innerText.trim().toLowerCase()) {\n this.dialogClose();\n }\n else {\n this.parent.endEdit();\n }\n };\n DialogEditRender.prototype.dialogClose = function () {\n this.parent.closeEdit();\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n DialogEditRender.prototype.destroy = function (args) {\n var dialogEditTemplates = ['template', 'headerTemplate', 'footerTemplate'];\n for (var i = 0; i < dialogEditTemplates.length; i++) {\n if (this.parent.editSettings[dialogEditTemplates[parseInt(i.toString(), 10)]]) {\n var templateName = dialogEditTemplates[parseInt(i.toString(), 10)].charAt(0).toUpperCase()\n + dialogEditTemplates[parseInt(i.toString(), 10)].slice(1);\n var editTemplateID = this.parent.element.id + 'editSettings' + templateName;\n updateBlazorTemplate(editTemplateID, templateName, this.parent.editSettings);\n }\n }\n this.parent.notify(events.destroyForm, {});\n this.parent.isEdit = false;\n this.parent.notify(events.toolbarRefresh, {});\n if (this.dialog && !this.dialogObj.isDestroyed) {\n this.dialogObj.destroy();\n remove(this.dialog);\n }\n };\n DialogEditRender.prototype.getDialogEditTemplateElement = function (dialogTemp, args) {\n var tempDiv = this.parent.createElement('div', { className: 'e-dialog' + dialogTemp });\n var dummyData = extend({}, args.rowData, { isAdd: !this.isEdit }, true);\n var templateID = this.parent.element.id + 'editSettings' + dialogTemp;\n appendChildren(tempDiv, (dialogTemp === 'HeaderTemplate' ? this.parent.getEditHeaderTemplate() :\n this.parent.getEditFooterTemplate())(dummyData, this.parent, 'editSettings' + dialogTemp, templateID));\n updateBlazorTemplate(templateID, dialogTemp, this.parent.editSettings);\n return tempDiv;\n };\n DialogEditRender.prototype.getEditElement = function (elements, args) {\n var _this = this;\n var gObj = this.parent;\n var div = this.parent.createElement('div', { className: this.isEdit ? literals.editedRow : 'e-insertedrow' });\n var form = args.form =\n this.parent.createElement('form', { id: gObj.element.id + 'EditForm', className: 'e-gridform' });\n if (this.parent.editSettings.template) {\n var editTemplateID = this.parent.element.id + 'editSettingsTemplate';\n var dummyData = extend({}, args.rowData, { isAdd: !this.isEdit }, true);\n var isReactCompiler = this.parent.isReact && typeof (this.parent.editSettings.template) !== 'string';\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild) {\n this.parent.getEditTemplate()(dummyData, this.parent, 'editSettingsTemplate', editTemplateID, null, null, form);\n this.parent.renderTemplates();\n }\n else {\n appendChildren(form, this.parent.getEditTemplate()(dummyData, this.parent, 'editSettingsTemplate', editTemplateID));\n }\n var setRules = function () {\n var columns = _this.parent.getColumns();\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].validationRules) {\n _this.parent.editModule.formObj.rules[columns[parseInt(i.toString(), 10)].field] =\n columns[parseInt(i.toString(), 10)].validationRules;\n }\n }\n };\n updateBlazorTemplate(editTemplateID, 'Template', this.parent.editSettings, true, setRules);\n div.appendChild(form);\n return div;\n }\n var table = this.parent.createElement('table', { className: literals.table, attrs: { cellspacing: '6px', role: 'grid' } });\n var tbody = this.parent.createElement(literals.tbody, { attrs: { role: 'rowgroup' } });\n var cols = gObj.getColumns();\n for (var i = 0; i < cols.length; i++) {\n if (this.parent.editModule.checkColumnIsGrouped(cols[parseInt(i.toString(), 10)]) || cols[parseInt(i.toString(), 10)].commands\n || cols[parseInt(i.toString(), 10)].commandsTemplate || cols[parseInt(i.toString(), 10)].type === 'checkbox') {\n continue;\n }\n var tr = this.parent.createElement('tr', { attrs: { role: 'row' } });\n var dataCell = this.parent.createElement('td', {\n className: literals.rowCell, attrs: {\n style: 'text-align:' + (this.parent.enableRtl ? 'right' : 'left') + ';width:190px'\n }\n });\n elements[cols[parseInt(i.toString(), 10)].uid].classList.remove('e-input');\n dataCell.appendChild(elements[cols[parseInt(i.toString(), 10)].uid]);\n tr.appendChild(dataCell);\n tbody.appendChild(tr);\n }\n table.appendChild(tbody);\n form.appendChild(table);\n div.appendChild(form);\n return div;\n };\n DialogEditRender.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.dialogDestroy, this.destroy);\n this.parent.off(events.destroy, this.destroy);\n };\n return DialogEditRender;\n}());\nexport { DialogEditRender };\n","import { isNullOrUndefined, closest, extend } from '@syncfusion/ej2-base';\nimport { InlineEditRender } from './inline-edit-renderer';\nimport { BatchEditRender } from './batch-edit-renderer';\nimport { DialogEditRender } from './dialog-edit-renderer';\nimport { attributes, classList, select } from '@syncfusion/ej2-base';\nimport { CellType } from '../base/enum';\nimport { RowModelGenerator } from '../services/row-model-generator';\nimport { getComplexFieldID, getObject, appendChildren, parentsUntil, extendObjWithFn, padZero } from '../base/util';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\n/**\n * Edit render module is used to render grid edit row.\n *\n * @hidden\n */\nvar EditRender = /** @class */ (function () {\n /**\n * Constructor for render module\n *\n * @param {IGrid} parent -specifies the IGrid\n * @param {ServiceLocator} serviceLocator - specifies the serviceLocator\n */\n function EditRender(parent, serviceLocator) {\n //Internal variables\n this.editType = {\n 'Inline': InlineEditRender,\n 'Normal': InlineEditRender, 'Batch': BatchEditRender, 'Dialog': DialogEditRender\n };\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.renderer = new this.editType[this.parent.editSettings.mode](parent, serviceLocator);\n this.focus = serviceLocator.getService('focus');\n }\n EditRender.prototype.addNew = function (args) {\n this.renderer.addNew(this.getEditElements(args), args);\n this.convertWidget(args);\n };\n EditRender.prototype.update = function (args) {\n this.renderer.update(this.getEditElements(args), args);\n var isCustomFormValidation = args.isCustomFormValidation;\n if (!isCustomFormValidation) {\n this.parent.notify(events.beforeStartEdit, args);\n this.convertWidget(args);\n }\n };\n EditRender.prototype.convertWidget = function (args) {\n var gObj = this.parent;\n var isFocused;\n var cell;\n var value;\n var form = gObj.editSettings.mode === 'Dialog' ?\n select('#' + gObj.element.id + '_dialogEdit_wrapper .e-gridform', document) :\n gObj.element.getElementsByClassName('e-gridform')[0];\n var cols = gObj.editSettings.mode !== 'Batch' ? gObj.getColumns() : [gObj.getColumnByField(args.columnName)];\n for (var _i = 0, cols_1 = cols; _i < cols_1.length; _i++) {\n var col = cols_1[_i];\n if (this.parent.editSettings.template && !isNullOrUndefined(col.field)) {\n var cellArgs = extend({}, args);\n cellArgs.element = form.querySelector('[name=' + getComplexFieldID(col.field) + ']');\n if (typeof col.edit.write === 'string') {\n getObject(col.edit.write, window)(cellArgs);\n }\n else {\n col.edit.write(cellArgs);\n }\n continue;\n }\n if (this.parent.editModule.checkColumnIsGrouped(col) || col.commands) {\n continue;\n }\n // eslint-disable-next-line\n value = (col.valueAccessor(col.field, args.rowData, col));\n cell = form.querySelector('[e-mappinguid=' + col.uid + ']');\n var temp = col.edit.write;\n if (!isNullOrUndefined(cell)) {\n if (typeof temp === 'string') {\n temp = getObject(temp, window);\n temp({\n rowData: args.rowData, element: cell, column: col, requestType: args.requestType, row: args.row,\n foreignKeyData: col.isForeignColumn() && getObject(col.field, args.foreignKeyData)\n });\n }\n else {\n col.edit.write({\n rowData: args.rowData, element: cell, column: col, requestType: args.requestType, row: args.row,\n foreignKeyData: col.isForeignColumn() && getObject(col.field, args.foreignKeyData)\n });\n }\n if (!isFocused && !cell.getAttribute('disabled') && !parentsUntil(cell, 'e-checkbox-disabled')) {\n this.focusElement(cell, args.type);\n isFocused = true;\n }\n }\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n EditRender.prototype.focusElement = function (elem, type) {\n var chkBox = this.parent.element.querySelector('.e-edit-checkselect');\n if (!isNullOrUndefined(chkBox) && chkBox.nextElementSibling) {\n chkBox.nextElementSibling.classList.add('e-focus');\n }\n if (this.parent.editSettings.mode === 'Batch') {\n this.focus.onClick({ target: closest(elem, 'td') }, true);\n }\n else {\n var isFocus = (this.parent.enableVirtualization || this.parent.enableColumnVirtualization) && this.parent.editSettings.mode === 'Normal' ? false : true;\n if (isFocus || ((this.parent.enableVirtualization || this.parent.enableColumnVirtualization) && this.parent.editSettings.newRowPosition === 'Bottom'\n && parentsUntil(elem, literals.addedRow))) {\n elem.focus();\n }\n else {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n elem.focus({ preventScroll: true });\n }\n }\n if (elem.classList.contains('e-defaultcell')) {\n elem.setSelectionRange(elem.value.length, elem.value.length);\n }\n };\n EditRender.prototype.getEditElements = function (args) {\n var gObj = this.parent;\n var elements = {};\n var cols = gObj.editSettings.mode !== 'Batch' ? gObj.getColumns() : [gObj.getColumnByField(args.columnName)];\n if (args.isCustomFormValidation) {\n cols = this.parent.columnModel;\n }\n if (this.parent.editSettings.template) {\n return {};\n }\n for (var i = 0, len = cols.length; i < len; i++) {\n var col = cols[parseInt(i.toString(), 10)];\n if (col.commands || col.commandsTemplate) {\n var cellRendererFact = this.serviceLocator.getService('cellRendererFactory');\n var model = new RowModelGenerator(this.parent);\n var cellRenderer = cellRendererFact.getCellRenderer(CellType.CommandColumn);\n var cells = model.generateRows(args.rowData)[0].cells;\n var cell = cells.filter(function (cell) { return cell.rowID; });\n var td = cellRenderer.render(cell[parseInt(i.toString(), 10)], args.rowData, { 'index': args.row ? args.row.getAttribute(literals.dataRowIndex) : 0 }, this.parent.enableVirtualization);\n var div = td.firstElementChild;\n div.setAttribute('textAlign', td.getAttribute('textAlign'));\n elements[col.uid] = div;\n continue;\n }\n if (col.type === 'dateonly' && args.rowData[col.field] instanceof Date) {\n var cellValue = args.rowData[col.field];\n args.rowData[col.field] = cellValue.getFullYear() + '-' + padZero(cellValue.getMonth() + 1) + '-' + padZero(cellValue.getDate());\n }\n var value = (col.valueAccessor(col.field, args.rowData, col));\n var tArgs = { column: col, value: value, type: args.requestType, data: args.rowData };\n var temp = col.edit.create;\n var input = void 0;\n if (col.editTemplate) {\n input = this.parent.createElement('span', { attrs: { 'e-mappinguid': col.uid } });\n var tempID = this.parent.element.id + col.uid + 'editTemplate';\n var tempData = extendObjWithFn({}, args.rowData, { column: col });\n var isReactCompiler = this.parent.isReact && typeof (col.editTemplate) !== 'string';\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild) {\n col.getEditTemplate()(extend({ 'index': args.rowIndex }, tempData), this.parent, 'editTemplate', tempID, null, null, input);\n this.parent.renderTemplates();\n }\n else {\n var template = col.getEditTemplate()(extend({ 'index': args.rowIndex }, tempData), this.parent, 'editTemplate', tempID);\n appendChildren(input, template);\n }\n }\n else {\n if (typeof temp === 'string') {\n temp = getObject(temp, window);\n input = temp(tArgs);\n }\n else {\n input = col.edit.create(tArgs);\n }\n if (typeof input === 'string') {\n var div = this.parent.createElement('div');\n div.innerHTML = input;\n input = div.firstChild;\n }\n var isInput = input.tagName !== 'input' && input.querySelectorAll('input').length;\n var complexFieldName = getComplexFieldID(col.field);\n attributes(isInput ? input.querySelector('input') : input, {\n name: complexFieldName, 'e-mappinguid': col.uid,\n id: gObj.element.id + complexFieldName\n });\n classList(input, ['e-input', 'e-field'], []);\n if (col.textAlign === 'Right') {\n input.classList.add('e-ralign');\n }\n if ((col.isPrimaryKey || col.isIdentity) && args.requestType === 'beginEdit' ||\n (col.isIdentity && args.requestType === 'add')) { // already disabled in cell plugins\n input.setAttribute('disabled', '');\n }\n }\n elements[col.uid] = input;\n }\n return elements;\n };\n EditRender.prototype.destroy = function () {\n this.renderer.removeEventListener();\n };\n return EditRender;\n}());\nexport { EditRender };\n","import { createEditElement } from '../base/util';\n/**\n * `DropDownEditCell` is used to handle dropdown cell type editing.\n *\n * @hidden\n */\nvar EditCellBase = /** @class */ (function () {\n function EditCellBase(parent) {\n this.parent = parent;\n }\n EditCellBase.prototype.create = function (args) {\n return createEditElement(this.parent, args.column, 'e-field', { type: 'text' });\n };\n EditCellBase.prototype.read = function (element) {\n return element.ej2_instances[0].value;\n };\n EditCellBase.prototype.destroy = function () {\n if (this.obj && !this.obj.isDestroyed) {\n if (this.removeEventHandler) {\n this.removeEventHandler();\n }\n this.obj.destroy();\n }\n };\n return EditCellBase;\n}());\nexport { EditCellBase };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { CheckBox } from '@syncfusion/ej2-buttons';\nimport { extend } from '@syncfusion/ej2-base';\nimport { isEditable, addRemoveActiveClasses, createEditElement, getObject } from '../base/util';\nimport * as literals from '../base/string-literals';\nimport { EditCellBase } from './edit-cell-base';\n/**\n * `BooleanEditCell` is used to handle boolean cell type editing.\n *\n * @hidden\n */\nvar BooleanEditCell = /** @class */ (function (_super) {\n __extends(BooleanEditCell, _super);\n function BooleanEditCell() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.activeClasses = ['e-selectionbackground', 'e-active'];\n return _this;\n }\n BooleanEditCell.prototype.create = function (args) {\n var col = args.column;\n var classNames = 'e-field e-boolcell';\n if (col.type === 'checkbox') {\n classNames = 'e-field e-boolcell e-edit-checkselect';\n }\n this.removeEventHandler = this.removeEventListener;\n return createEditElement(this.parent, args.column, classNames, { type: 'checkbox', value: args.value });\n };\n BooleanEditCell.prototype.read = function (element) {\n return element.checked;\n };\n BooleanEditCell.prototype.write = function (args) {\n var selectChkBox;\n var chkState;\n if (!isNullOrUndefined(args.row)) {\n selectChkBox = args.row.querySelector('.e-edit-checkselect');\n }\n if (getObject(args.column.field, args.rowData)) {\n chkState = JSON.parse(getObject(args.column.field, args.rowData).toString().toLowerCase());\n }\n if (!isNullOrUndefined(selectChkBox) && args.column.type === 'checkbox') {\n this.editType = this.parent.editSettings.mode;\n this.editRow = args.row;\n if (args.requestType !== 'add') {\n var row = this.parent.getRowObjectFromUID(args.row.getAttribute('data-uid'));\n chkState = row ? row.isSelected : false;\n }\n addRemoveActiveClasses.apply(void 0, [[].slice.call(args.row.getElementsByClassName(literals.rowCell)), chkState].concat(this.activeClasses));\n }\n this.obj = new CheckBox(extend({\n label: this.parent.editSettings.mode !== 'Dialog' ? ' ' : args.column.headerText,\n checked: chkState,\n disabled: !isEditable(args.column, args.requestType, args.element), enableRtl: this.parent.enableRtl,\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n }, args.column.edit.params));\n this.addEventListener();\n this.obj.appendTo(args.element);\n };\n BooleanEditCell.prototype.addEventListener = function () {\n this.cbChange = this.checkBoxChange.bind(this);\n this.obj.addEventListener(literals.change, this.cbChange);\n };\n BooleanEditCell.prototype.removeEventListener = function () {\n if (this.obj.isDestroyed) {\n return;\n }\n this.obj.removeEventListener(literals.change, this.cbChange);\n };\n BooleanEditCell.prototype.checkBoxChange = function (args) {\n if (this.editRow && this.editType !== 'Dialog') {\n var add = false;\n if (!args.checked) {\n this.editRow.removeAttribute('aria-selected');\n }\n else {\n add = true;\n this.editRow.setAttribute('aria-selected', add.toString());\n }\n addRemoveActiveClasses.apply(void 0, [[].slice.call(this.editRow.getElementsByClassName(literals.rowCell)), add].concat(this.activeClasses));\n }\n };\n return BooleanEditCell;\n}(EditCellBase));\nexport { BooleanEditCell };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { extend, isNullOrUndefined, select } from '@syncfusion/ej2-base';\nimport { DropDownList } from '@syncfusion/ej2-dropdowns';\nimport { Query, DataManager, DataUtil, Predicate } from '@syncfusion/ej2-data';\nimport { isEditable, getComplexFieldID, getObject } from '../base/util';\nimport { parentsUntil } from '../base/util';\nimport { EditCellBase } from './edit-cell-base';\nimport * as literals from '../base/string-literals';\nimport * as events from '../base/constant';\n/**\n * `DropDownEditCell` is used to handle dropdown cell type editing.\n *\n * @hidden\n */\nvar DropDownEditCell = /** @class */ (function (_super) {\n __extends(DropDownEditCell, _super);\n function DropDownEditCell(parent) {\n var _this = \n //constructor\n _super.call(this) || this;\n _this.parent = parent;\n _this.flag = false;\n _this.removeEventHandler = _this.removeEventListener;\n return _this;\n }\n DropDownEditCell.prototype.write = function (args) {\n var isInline = this.parent.editSettings.mode !== 'Dialog';\n this.column = args.column;\n var pred = new Predicate(args.column.field, 'notequal', null, true, false);\n var params = {};\n if (args.column.edit.params) {\n var keys = Object.keys(args.column.edit.params);\n for (var i = 0; i < keys.length; i++) {\n params[keys[parseInt(i.toString(), 10)]] = keys[parseInt(i.toString(), 10)] === 'query' ?\n args.column.edit.params[keys[parseInt(i.toString(), 10)]].clone() :\n args.column.edit.params[keys[parseInt(i.toString(), 10)]];\n }\n }\n this.obj = new DropDownList(extend({\n dataSource: this.parent.dataSource instanceof DataManager ?\n this.parent.dataSource : new DataManager(this.parent.dataSource),\n query: new Query().where(pred).select(args.column.field), enabled: isEditable(args.column, args.requestType, args.element),\n fields: { value: args.column.field },\n value: getObject(args.column.field, args.rowData),\n enableRtl: this.parent.enableRtl,\n placeholder: isInline ? '' : args.column.headerText, popupHeight: '200px',\n floatLabelType: isInline ? 'Never' : 'Always',\n sortOrder: 'Ascending',\n cssClass: this.parent.cssClass ? this.parent.cssClass : null,\n close: this.dropDownClose.bind(this)\n }, params));\n if (this.parent.enableVirtualization) {\n if (params.dataSource) {\n this.obj.dataSource = params.dataSource;\n }\n else {\n this.obj.dataSource = args.column.isForeignColumn() ? [args.foreignKeyData[0]] : [args.rowData];\n }\n }\n this.addEventListener();\n this.obj.query.params = this.parent.query.params;\n this.obj.appendTo(args.element);\n /* tslint:disable-next-line:no-any */\n args.element.setAttribute('name', getComplexFieldID(args.column.field));\n };\n DropDownEditCell.prototype.dropDownClose = function (args) {\n if (args.event && args.event.action === 'escape') {\n this.parent.editModule.editCellDialogClose = true;\n }\n };\n DropDownEditCell.prototype.addEventListener = function () {\n this.ddCreated = this.dropdownCreated.bind(this);\n this.ddOpen = this.dropDownOpen.bind(this);\n this.ddBeforeOpen = this.dropdownBeforeOpen.bind(this);\n this.ddComplete = this.ddActionComplete.bind(this);\n this.obj.addEventListener(literals.create, this.ddCreated);\n this.obj.addEventListener(literals['open'], this.ddOpen);\n this.obj.addEventListener(literals.beforeOpen, this.ddBeforeOpen);\n this.obj.addEventListener(events.actionComplete, this.ddComplete);\n };\n DropDownEditCell.prototype.removeEventListener = function () {\n if (this.obj.isDestroyed) {\n return;\n }\n this.obj.removeEventListener(literals.create, this.ddCreated);\n this.obj.removeEventListener(literals['open'], this.ddOpen);\n this.obj.removeEventListener(literals.beforeOpen, this.ddBeforeOpen);\n this.obj.removeEventListener(events.actionComplete, this.ddComplete);\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n DropDownEditCell.prototype.dropdownCreated = function (e) {\n this.flag = true;\n };\n DropDownEditCell.prototype.dropdownBeforeOpen = function () {\n if (this.parent.enableVirtualization) {\n if (this.column.edit.params && this.column.edit.params.dataSource) {\n this.obj.dataSource = this.column.edit.params.dataSource;\n }\n else {\n this.obj.dataSource = !this.column.isForeignColumn() ? (this.parent.dataSource instanceof DataManager ?\n this.parent.dataSource : new DataManager(this.parent.dataSource))\n : this.column.dataSource instanceof DataManager ?\n this.column.dataSource : new DataManager(this.column.dataSource);\n }\n }\n };\n DropDownEditCell.prototype.ddActionComplete = function (e) {\n e.result = DataUtil.distinct(e.result, this.obj.fields.value, true);\n if (this.flag && this.column.dataSource && !(this.column.edit.params &&\n this.column.edit.params.ddEditedData)) {\n if ('result' in this.column.dataSource) {\n this.column.dataSource.result = e.result;\n }\n else if (this.column.dataSource instanceof DataManager) {\n this.column.dataSource.dataSource.json = e.result;\n }\n }\n this.flag = false;\n };\n DropDownEditCell.prototype.dropDownOpen = function (args) {\n var dlgElement = parentsUntil(this.obj.element, 'e-dialog');\n if (this.parent.editSettings.mode === 'Dialog' && !isNullOrUndefined(dlgElement)) {\n var dlgObj = select('#' + dlgElement.id, document).ej2_instances[0];\n args.popup.element.style.zIndex = (dlgObj.zIndex + 1).toString();\n }\n };\n return DropDownEditCell;\n}(EditCellBase));\nexport { DropDownEditCell };\n","import { extend, Internationalization } from '@syncfusion/ej2-base';\nimport { NumericTextBox } from '@syncfusion/ej2-inputs';\nimport { isEditable, getComplexFieldID, getObject, createEditElement } from '../base/util';\n/**\n * `NumericEditCell` is used to handle numeric cell type editing.\n *\n * @hidden\n */\nvar NumericEditCell = /** @class */ (function () {\n function NumericEditCell(parent) {\n this.parent = parent;\n }\n NumericEditCell.prototype.keyEventHandler = function (args) {\n if (args.keyCode === 13 || args.keyCode === 9) {\n var evt = document.createEvent('HTMLEvents');\n evt.initEvent('change', false, true);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.dispatchEvent(evt);\n }\n };\n NumericEditCell.prototype.create = function (args) {\n this.instances = new Internationalization(this.parent.locale);\n return createEditElement(this.parent, args.column, 'e-field', {});\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n NumericEditCell.prototype.read = function (element) {\n return this.obj.value;\n };\n NumericEditCell.prototype.write = function (args) {\n var col = args.column;\n var isInline = this.parent.editSettings.mode !== 'Dialog';\n this.obj = new NumericTextBox(extend({\n value: parseFloat(getObject(args.column.field, args.rowData)),\n enableRtl: this.parent.enableRtl,\n placeholder: isInline ? '' : args.column.headerText,\n enabled: isEditable(args.column, args.requestType, args.element),\n floatLabelType: this.parent.editSettings.mode !== 'Dialog' ? 'Never' : 'Always',\n locale: this.parent.locale,\n cssClass: this.parent.cssClass ? this.parent.cssClass : null\n }, col.edit.params));\n args.element.setAttribute('name', getComplexFieldID(args.column.field));\n this.obj.appendTo(args.element);\n this.obj.element.addEventListener('keydown', this.keyEventHandler);\n };\n NumericEditCell.prototype.destroy = function () {\n if (this.obj && !this.obj.isDestroyed) {\n this.obj.element.removeEventListener('keydown', this.keyEventHandler);\n this.obj.destroy();\n }\n };\n return NumericEditCell;\n}());\nexport { NumericEditCell };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { isEditable, createEditElement } from '../base/util';\nimport { TextBox } from '@syncfusion/ej2-inputs';\nimport { EditCellBase } from './edit-cell-base';\n/**\n * `DefaultEditCell` is used to handle default cell type editing.\n *\n * @hidden\n */\nvar DefaultEditCell = /** @class */ (function (_super) {\n __extends(DefaultEditCell, _super);\n function DefaultEditCell() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n DefaultEditCell.prototype.create = function (args) {\n var attr = {\n type: 'text', value: !isNullOrUndefined(args.value) ? args.value : '', style: 'text-align:' + args.column.textAlign\n };\n return createEditElement(this.parent, args.column, 'e-field e-input e-defaultcell', attr);\n };\n DefaultEditCell.prototype.read = function (element) {\n return element.value;\n };\n DefaultEditCell.prototype.write = function (args) {\n var col = args.column;\n var isInline = this.parent.editSettings.mode !== 'Dialog';\n this.obj = new TextBox(extend({\n element: args.element, floatLabelType: this.parent.editSettings.mode !== 'Dialog' ? 'Never' : 'Always',\n enableRtl: this.parent.enableRtl, enabled: isEditable(args.column, args.requestType, args.element),\n placeholder: isInline ? '' : args.column.headerText,\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n }, col.edit.params));\n this.obj.appendTo(args.element);\n if (this.parent.editSettings.mode === 'Batch') {\n this.obj.element.addEventListener('keydown', this.keyEventHandler);\n }\n };\n DefaultEditCell.prototype.keyEventHandler = function (args) {\n if (args.key === 'Enter' || args.key === 'Tab') {\n var evt = new Event('change', { bubbles: false, cancelable: true });\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.dispatchEvent(evt);\n }\n };\n DefaultEditCell.prototype.destroy = function () {\n if (this.obj && !this.obj.isDestroyed) {\n this.obj.element.removeEventListener('keydown', this.keyEventHandler);\n this.obj.destroy();\n }\n };\n return DefaultEditCell;\n}(EditCellBase));\nexport { DefaultEditCell };\n","import { extend, select } from '@syncfusion/ej2-base';\nimport { remove, isNullOrUndefined, updateBlazorTemplate } from '@syncfusion/ej2-base';\nimport { parentsUntil, isGroupAdaptive, refreshForeignData, getObject } from '../base/util';\nimport * as events from '../base/constant';\nimport { RowRenderer } from '../renderer/row-renderer';\nimport { DataUtil } from '@syncfusion/ej2-data';\nimport { addRemoveEventListener, addFixedColumnBorder } from '../base/util';\nimport * as literals from '../base/string-literals';\n/**\n * `NormalEdit` module is used to handle normal('inline, dialog, external') editing actions.\n *\n * @hidden\n */\nvar NormalEdit = /** @class */ (function () {\n function NormalEdit(parent, serviceLocator, renderer) {\n this.args = {};\n this.currentVirtualData = {};\n this.parent = parent;\n this.renderer = renderer;\n this.serviceLocator = serviceLocator;\n this.addEventListener();\n }\n NormalEdit.prototype.clickHandler = function (e) {\n var target = e.target;\n var gObj = this.parent;\n if ((((parentsUntil(target, literals.gridContent) &&\n parentsUntil(parentsUntil(target, literals.gridContent), 'e-grid').id === gObj.element.id)) || (gObj.frozenRows\n && parentsUntil(target, literals.headerContent))) && !parentsUntil(target, 'e-unboundcelldiv')) {\n this.rowIndex = parentsUntil(target, literals.rowCell)\n ? parseInt(target.parentElement.getAttribute(literals.dataRowIndex), 10) : -1;\n if (gObj.isEdit) {\n gObj.editModule.endEdit();\n }\n }\n };\n NormalEdit.prototype.dblClickHandler = function (e) {\n if (parentsUntil(e.target, literals.rowCell) && this.parent.editSettings.allowEditOnDblClick) {\n this.parent.editModule.startEdit(parentsUntil(e.target, literals.row));\n }\n };\n /**\n * The function used to trigger editComplete\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n NormalEdit.prototype.editComplete = function (e) {\n this.parent.isEdit = false;\n var action = 'action';\n switch (e.requestType) {\n case 'save':\n if (!(this.parent.isCheckBoxSelection || this.parent.selectionSettings.type === 'Multiple')\n || (!this.parent.isPersistSelection)) {\n if (e[\"\" + action] !== 'edit') {\n this.parent.selectRow(e['index']);\n }\n }\n this.parent.trigger(events.actionComplete, extend(e, {\n requestType: 'save',\n type: events.actionComplete\n }));\n break;\n case 'delete':\n this.parent.trigger(events.actionComplete, extend(e, {\n requestType: 'delete',\n type: events.actionComplete\n }));\n if (!this.parent.isCheckBoxSelection) {\n this.parent.selectRow(this.editRowIndex);\n }\n break;\n }\n };\n NormalEdit.prototype.getEditArgs = function (editedData, rowObj, isScroll) {\n var primaryKeys = this.parent.getPrimaryKeyFieldNames();\n var primaryKeyValues = [];\n for (var i = 0; i < primaryKeys.length; i++) {\n primaryKeyValues.push(getObject(primaryKeys[parseInt(i.toString(), 10)], editedData));\n }\n var args = {\n primaryKey: primaryKeys, primaryKeyValue: primaryKeyValues, requestType: 'beginEdit',\n rowData: editedData, rowIndex: this.rowIndex, type: 'edit', cancel: false,\n foreignKeyData: rowObj && rowObj.foreignKeyData, target: undefined, isScroll: isScroll\n };\n return args;\n };\n NormalEdit.prototype.startEdit = function (tr) {\n var _this = this;\n var gObj = this.parent;\n this.rowIndex = this.editRowIndex = parseInt(tr.getAttribute(literals.dataRowIndex), 10);\n if (gObj.enableVirtualization || gObj.enableColumnVirtualization || gObj.enableInfiniteScrolling) {\n var selector = '.e-row[data-rowindex=\"' + this.rowIndex + '\"]';\n var virtualRow = this.parent.element.querySelector(selector);\n if (!virtualRow) {\n return;\n }\n }\n var e = { data: undefined, index: this.rowIndex, isScroll: false };\n this.parent.notify(events.virtualScrollEditActionBegin, e);\n if (isGroupAdaptive(gObj)) {\n var rObj = gObj.getRowObjectFromUID(tr.getAttribute('data-uid'));\n this.previousData = rObj.data;\n }\n else if (this.parent.enableVirtualization || this.parent.enableColumnVirtualization ||\n (this.parent.enableInfiniteScrolling && !this.previousData)) {\n this.previousData = e.data;\n }\n else if (!this.parent.enableVirtualization) {\n this.previousData = extend({}, {}, gObj.getCurrentViewRecords()[this.rowIndex], true);\n }\n var editedData = extend({}, {}, e.data || this.previousData, true);\n this.uid = tr.getAttribute('data-uid');\n var rowObj = gObj.getRowObjectFromUID(this.uid);\n var args = this.getEditArgs(editedData, rowObj, e.isScroll);\n args.row = tr;\n if (!args.isScroll) {\n this.parent.notify(events.createVirtualValidationForm, { uid: this.uid, prevData: this.previousData, argsCreator: this.getEditArgs.bind(this), renderer: this.renderer });\n gObj.trigger(events.beginEdit, args, function (begineditargs) {\n begineditargs.type = 'actionBegin';\n gObj.trigger(events.actionBegin, begineditargs, function (editargs) {\n if (!editargs.cancel) {\n _this.inlineEditHandler(editargs, tr);\n }\n });\n });\n }\n else {\n this.inlineEditHandler(args, tr);\n }\n };\n NormalEdit.prototype.inlineEditHandler = function (editargs, tr) {\n var gObj = this.parent;\n gObj.isEdit = true;\n editargs.row = editargs.row ? editargs.row : tr;\n if (gObj.editSettings.mode !== 'Dialog') {\n gObj.clearSelection();\n }\n if (gObj.editSettings.mode === 'Dialog' && gObj.selectionModule) {\n gObj.selectionModule.preventFocus = true;\n editargs.row.classList.add('e-dlgeditrow');\n }\n this.renderer.update(editargs);\n this.uid = tr.getAttribute('data-uid');\n gObj.editModule.applyFormValidation();\n editargs.type = 'actionComplete';\n gObj.trigger(events.actionComplete, editargs);\n if (gObj.editSettings.template) {\n gObj.editModule.applyFormValidation(undefined, editargs.form.ej2_instances[0].rules);\n }\n this.args = editargs;\n if (this.parent.allowTextWrap) {\n this.parent.notify(events.freezeRender, { case: 'textwrap' });\n }\n };\n NormalEdit.prototype.updateRow = function (index, data) {\n var _this = this;\n var gObj = this.parent;\n this.editRowIndex = index;\n var args = {\n requestType: 'save', action: 'edit', type: events.actionBegin, data: data, cancel: false,\n previousData: gObj.getCurrentViewRecords()[parseInt(index.toString(), 10)],\n row: gObj.getRowByIndex(index)\n };\n gObj.showSpinner();\n if (gObj.enableInfiniteScrolling) {\n this.uid = args.row.getAttribute('data-uid');\n var index_1 = parseInt(args.row.getAttribute('data-rowindex'), 10);\n this.parent.notify(events.refreshInfiniteEditrowindex, { index: index_1 });\n }\n gObj.notify(events.updateData, args);\n if (args.promise) {\n args.promise.then(function () { return gObj.refresh(); }).catch(function (e) { return _this.edFail(e); });\n }\n else {\n if (!gObj.enableInfiniteScrolling) {\n gObj.refresh();\n }\n }\n };\n NormalEdit.prototype.editFormValidate = function () {\n var gObj = this.parent;\n var isValid = gObj.editModule.editFormValidate();\n var validationArgs = {\n prevData: this.previousData, isValid: true, editIdx: this.editRowIndex, addIdx: this.addedRowIndex\n };\n gObj.notify(events.validateVirtualForm, validationArgs);\n return (isValid && validationArgs.isValid);\n };\n NormalEdit.prototype.endEdit = function () {\n var _this = this;\n var gObj = this.parent;\n if (!this.parent.isEdit || !this.editFormValidate()) {\n return;\n }\n var editedData = extend({}, {}, this.previousData, true);\n var args = extend(this.args, {\n requestType: 'save', type: events.actionBegin, data: editedData, cancel: false,\n previousData: this.previousData, selectedRow: gObj.selectedRowIndex, foreignKeyData: {}\n });\n var isDlg = gObj.editSettings.mode === 'Dialog';\n var dlgWrapper = select('#' + gObj.element.id + '_dialogEdit_wrapper', document);\n var dlgForm = isDlg ? dlgWrapper.querySelector('.e-gridform') : gObj.element.getElementsByClassName('e-gridform')[0];\n var data = {\n virtualData: extend({}, {}, this.previousData, true), isAdd: false, isScroll: false, endEdit: true\n };\n this.parent.notify(events.getVirtualData, data);\n if ((this.parent.enableVirtualization || this.parent.enableColumnVirtualization || this.parent.enableInfiniteScrolling)\n && this.parent.editSettings.mode === 'Normal' && Object.keys(data.virtualData).length) {\n if (this.parent.isEdit) {\n this.currentVirtualData = editedData = args.data = data.virtualData;\n }\n }\n else {\n editedData = gObj.editModule.getCurrentEditedData(dlgForm, editedData);\n }\n var eleLength = [].slice.call(gObj.element.getElementsByClassName(literals.editedRow)).length;\n if (!data.isAdd && Object.keys(this.currentVirtualData).length && !eleLength) {\n eleLength = 1;\n }\n if (isDlg ? dlgWrapper.getElementsByClassName(literals.editedRow).length : eleLength) {\n args.action = 'edit';\n gObj.trigger(events.actionBegin, args, function (endEditArgs) {\n if (endEditArgs.cancel) {\n return;\n }\n if (_this.parent.loadingIndicator.indicatorType === 'Spinner') {\n gObj.showSpinner();\n }\n if (_this.parent.loadingIndicator.indicatorType === 'Shimmer') {\n _this.parent.showMaskRow();\n }\n gObj.notify(events.updateData, endEditArgs);\n });\n }\n else {\n args.action = 'add';\n args.selectedRow = 0;\n args.index = this.addedRowIndex;\n gObj.notify(events.virtualScrollEditSuccess, {});\n gObj.notify(events.modelChanged, args);\n this.addedRowIndex = null;\n if (args.cancel) {\n return;\n }\n }\n };\n NormalEdit.prototype.destroyElements = function () {\n var gObj = this.parent;\n gObj.editModule.destroyWidgets();\n gObj.editModule.destroyForm();\n this.parent.notify(events.dialogDestroy, {});\n };\n NormalEdit.prototype.editHandler = function (args) {\n var _this = this;\n if (args.promise) {\n args.promise.then(function (e) { return _this.edSucc(e, args); }).catch(function (e) { return _this.edFail(e); });\n }\n else {\n this.editSuccess(args.data, args);\n }\n };\n NormalEdit.prototype.edSucc = function (e, args) {\n this.editSuccess(e, args);\n };\n NormalEdit.prototype.edFail = function (e) {\n this.editFailure(e);\n };\n NormalEdit.prototype.updateCurrentViewData = function (data) {\n if (!this.parent.enableVirtualization && !this.parent.enableInfiniteScrolling) {\n this.parent.getCurrentViewRecords()[this.editRowIndex] = data;\n }\n };\n NormalEdit.prototype.requestSuccess = function (args) {\n if (this.parent.editModule.formObj && !this.parent.editModule.formObj.isDestroyed) {\n this.destroyElements();\n this.stopEditStatus();\n if (this.parent.editSettings.mode === 'Dialog' && args.action !== 'add' &&\n this.parent.selectionModule) {\n this.parent.element.querySelector('.e-dlgeditrow').classList.remove('e-dlgeditrow');\n }\n }\n };\n NormalEdit.prototype.editSuccess = function (e, args) {\n if (!isNullOrUndefined(e) && !(e instanceof Array)) {\n var rowData = 'rowData';\n args.data = extend({}, extend({}, args[\"\" + rowData], args.data), e);\n }\n this.requestSuccess(args);\n this.parent.trigger(events.beforeDataBound, args);\n args.type = events.actionComplete;\n this.parent.isEdit = false;\n this.refreshRow(args.data);\n this.parent.notify(events.virtualScrollEditSuccess, args);\n this.parent.editModule.checkLastRow(args.row);\n this.parent.editModule.isLastRow = false;\n this.updateCurrentViewData(args.data);\n this.blazorTemplate();\n this.editRowIndex = null;\n if (this.parent.allowGrouping && this.parent.groupSettings.columns.length\n && this.parent.groupSettings.showGroupedColumn) {\n var dragRow = args.row;\n var rows = this.parent.getRowsObject();\n var dragRowUid = dragRow.getAttribute('data-uid');\n var dragRowObject_1 = this.parent.getRowObjectFromUID(dragRowUid);\n var _loop_1 = function (i) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var thisRef = this_1;\n rows = rows.filter(function (data) {\n var flag = data.isDataRow && data !== dragRowObject_1;\n if (flag) {\n var groupedColumn = thisRef.parent.groupSettings.columns[parseInt(i.toString(), 10)].split('.');\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var comparer1 = data.data[groupedColumn[0]];\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var comparer2 = args.data[groupedColumn[0]];\n for (var j = 1; j < groupedColumn.length; j++) {\n comparer1 = comparer1[groupedColumn[j]];\n comparer2 = comparer2[groupedColumn[j]];\n }\n return flag && comparer1 === comparer2;\n }\n else {\n return flag;\n }\n });\n };\n var this_1 = this;\n for (var i = 0; i < this.parent.groupSettings.columns.length; i++) {\n _loop_1(i);\n }\n var dropRowObject = rows[0];\n if (!isNullOrUndefined(dragRowObject_1) && !isNullOrUndefined(dropRowObject) &&\n dragRowObject_1.parentUid !== dropRowObject.parentUid) {\n this.parent['groupModule'].groupedRowReorder(dragRowObject_1, dropRowObject);\n }\n else if (this.parent.aggregates.length) {\n this.parent.aggregateModule.refresh(args.data, this.parent.groupSettings.enableLazyLoading ? args.row : undefined);\n }\n }\n else if (this.parent.aggregates.length) {\n this.parent.aggregateModule.refresh(args.data, this.parent.groupSettings.enableLazyLoading ? args.row : undefined);\n }\n this.parent.trigger(events.actionComplete, args);\n if (!(this.parent.isCheckBoxSelection || this.parent.selectionSettings.type === 'Multiple')\n || (!this.parent.isPersistSelection) && !this.parent.selectionSettings.checkboxOnly) {\n if (this.parent.editSettings.mode !== 'Dialog') {\n this.parent.selectRow(this.rowIndex > -1 ? this.rowIndex : this.editRowIndex);\n }\n }\n if (this.parent.aggregates.length && this.parent.groupSettings.enableLazyLoading && this.parent.groupSettings.columns.length\n && (this.parent.groupModule.getGroupAggregateTemplates(true).length\n || this.parent.groupModule.getGroupAggregateTemplates(false).length)) {\n return;\n }\n this.parent.removeMaskRow();\n this.parent.hideSpinner();\n };\n NormalEdit.prototype.closeForm = function () {\n if (!this.cloneRow && this.parent.isEdit) {\n this.stopEditStatus();\n }\n if (this.cloneRow) {\n this.cloneRow.remove();\n this.cloneRow = null;\n this.originalRow.classList.remove('e-hiddenrow');\n }\n if (this.cloneFrozen) {\n this.cloneFrozen.remove();\n if (this.frozen) {\n this.frozen.classList.remove('e-hiddenrow');\n }\n }\n };\n NormalEdit.prototype.blazorTemplate = function () {\n var cols = this.parent.getColumns();\n if (this.parent.editSettings.template && this.parent.editSettings.mode === 'Normal') {\n updateBlazorTemplate(this.parent.element.id + 'editSettingsTemplate', 'Template', this.parent.editSettings);\n }\n for (var i = 0; i < cols.length; i++) {\n var col = cols[parseInt(i.toString(), 10)];\n if (col.template) {\n updateBlazorTemplate(this.parent.element.id + col.uid, 'Template', col, false);\n }\n if (col.editTemplate) {\n updateBlazorTemplate(this.parent.element.id + col.uid + 'editTemplate', 'EditTemplate', col);\n }\n }\n };\n NormalEdit.prototype.editFailure = function (e) {\n this.parent.removeMaskRow();\n this.parent.trigger(events.actionFailure, ({ error: e }));\n this.parent.hideSpinner();\n this.parent.log('actionfailure', { error: e });\n };\n NormalEdit.prototype.needRefresh = function () {\n var refresh = true;\n var editedRow = this.parent.element.querySelector('.e-gridform');\n if ((this.parent.enableVirtualization || this.parent.infiniteScrollSettings.enableCache)\n && this.parent.editSettings.mode === 'Normal' && !editedRow) {\n refresh = false;\n }\n return refresh;\n };\n NormalEdit.prototype.refreshRow = function (data) {\n var row = new RowRenderer(this.serviceLocator, null, this.parent);\n var rowObj = this.parent.getRowObjectFromUID(this.uid);\n if (rowObj) {\n rowObj.changes = data;\n this.parent.notify(events.refreshVirtualCache, { data: data });\n refreshForeignData(rowObj, this.parent.getForeignKeyColumns(), rowObj.changes);\n if (this.needRefresh()) {\n row.refresh(rowObj, this.parent.getColumns(), true);\n }\n var tr = [].slice.call(this.parent.element.querySelectorAll('[data-rowindex=\"' + rowObj.index + '\"]'));\n for (var i = 0; i < tr.length; i++) {\n addFixedColumnBorder(tr[parseInt(i.toString(), 10)]);\n if (this.parent.enableColumnVirtualization &&\n tr[parseInt(i.toString(), 10)].querySelectorAll('.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze').length) {\n var cols = this.parent.getColumns();\n var leftrightCells = [].slice.call(tr[parseInt(i.toString(), 10)].querySelectorAll('.e-leftfreeze,.e-rightfreeze.e-fixedfreeze'));\n for (var j = 0; j < leftrightCells.length; j++) {\n if (leftrightCells[parseInt(j.toString(), 10)].classList.contains('e-leftfreeze')) {\n leftrightCells[parseInt(j.toString(), 10)].style.left = (cols[parseInt(j.toString(), 10)].valueX - this.parent.translateX) + 'px';\n }\n else if (leftrightCells[parseInt(j.toString(), 10)].classList.contains('e-rightfreeze')) {\n var idx = parseInt(leftrightCells[parseInt(j.toString(), 10)].getAttribute('data-colindex'), 10);\n leftrightCells[parseInt(j.toString(), 10)].style.right = ((cols[parseInt(idx.toString(), 10)].valueX + this.parent.translateX)) + 'px';\n }\n else {\n leftrightCells[parseInt(j.toString(), 10)].style.left = (this.parent.leftrightColumnWidth('left') -\n this.parent.translateX) + 'px';\n leftrightCells[parseInt(j.toString(), 10)].style.right = (this.parent.leftrightColumnWidth('right') +\n this.parent.translateX) + 'px';\n }\n }\n }\n }\n }\n };\n NormalEdit.prototype.closeEdit = function () {\n var _this = this;\n if (!this.parent.isEdit) {\n return;\n }\n var gObj = this.parent;\n var args = extend(this.args, {\n requestType: 'cancel', type: events.actionBegin, cancel: false, data: this.previousData, selectedRow: gObj.selectedRowIndex\n });\n gObj.notify(events.virtualScrollEditCancel, args);\n this.blazorTemplate();\n gObj.trigger(events.actionBegin, args, function (closeEditArgs) {\n if (closeEditArgs.cancel) {\n return;\n }\n if (_this.parent.editSettings.mode === 'Dialog') {\n _this.parent.notify(events.dialogDestroy, {});\n }\n gObj.isEdit = false;\n _this.stopEditStatus();\n closeEditArgs.type = events.actionComplete;\n if (gObj.editSettings.mode !== 'Dialog') {\n _this.refreshRow(closeEditArgs.data);\n }\n var isLazyLoad = gObj.groupSettings.enableLazyLoading && gObj.groupSettings.columns.length\n && !gObj.getContentTable().querySelector('tr.e-emptyrow');\n if (!gObj.getContentTable().querySelector('tr.e-emptyrow') &&\n !gObj.getContentTable().querySelector('tr.e-row') && !isLazyLoad) {\n gObj.renderModule.emptyRow();\n }\n if (gObj.editSettings.mode !== 'Dialog') {\n gObj.selectRow(_this.rowIndex);\n }\n gObj.trigger(events.actionComplete, closeEditArgs);\n });\n };\n NormalEdit.prototype.addRecord = function (data, index) {\n var _this = this;\n var gObj = this.parent;\n this.addedRowIndex = index = !isNullOrUndefined(index) ? index : 0;\n if (data) {\n gObj.notify(events.modelChanged, {\n requestType: 'save', type: events.actionBegin, data: data, selectedRow: 0, action: 'add', index: index\n });\n return;\n }\n if (gObj.isEdit) {\n return;\n }\n this.previousData = {};\n this.uid = '';\n var cols = gObj.getColumns();\n var rowData = { virtualData: {}, isScroll: false };\n this.parent.notify(events.getVirtualData, rowData);\n for (var i = 0; i < cols.length; i++) {\n if (rowData.isScroll) {\n continue;\n }\n if (cols[parseInt(i.toString(), 10)].field) {\n if (cols[parseInt(i.toString(), 10)].type === 'string') {\n cols[parseInt(i.toString(), 10)].defaultValue = this.parent.sanitize(cols[parseInt(i.toString(), 10)].defaultValue);\n }\n DataUtil.setValue(cols[parseInt(i.toString(), 10)].field, cols[parseInt(i.toString(), 10)].defaultValue, this.previousData);\n }\n }\n var args = {\n cancel: false, foreignKeyData: {},\n requestType: 'add', data: this.previousData, type: events.actionBegin, index: index,\n rowData: this.previousData, target: undefined, isScroll: rowData.isScroll\n };\n if ((this.parent.enableVirtualization || this.parent.enableColumnVirtualization || this.parent.infiniteScrollSettings.enableCache)\n && Object.keys(rowData.virtualData).length) {\n args.data = args.rowData = rowData.virtualData;\n }\n if (!args.isScroll) {\n this.parent.notify(events.createVirtualValidationForm, { uid: this.uid, prevData: this.previousData, argsCreator: this.getEditArgs.bind(this), renderer: this.renderer });\n gObj.trigger(events.actionBegin, args, function (addArgs) {\n if (addArgs.cancel) {\n return;\n }\n _this.inlineAddHandler(addArgs);\n });\n }\n else {\n this.inlineAddHandler(args);\n }\n };\n NormalEdit.prototype.inlineAddHandler = function (addArgs) {\n var gObj = this.parent;\n gObj.isEdit = true;\n if (gObj.editSettings.mode !== 'Dialog') {\n gObj.clearSelection();\n }\n this.renderer.addNew(addArgs);\n gObj.editModule.applyFormValidation();\n addArgs.type = events.actionComplete;\n addArgs.row = gObj.element.querySelector('.' + literals.addedRow);\n gObj.trigger(events.actionComplete, addArgs);\n if (gObj.editSettings.template) {\n gObj.editModule.applyFormValidation(undefined, addArgs.form.ej2_instances[0].rules);\n }\n this.args = addArgs;\n };\n NormalEdit.prototype.deleteRecord = function (fieldname, data) {\n this.editRowIndex = this.parent.selectedRowIndex;\n if (data) {\n data = (data instanceof Array) ? data : [data];\n var gObj = this.parent;\n var dataLen = Object.keys(data).length;\n fieldname = fieldname || this.parent.getPrimaryKeyFieldNames()[0];\n var _loop_2 = function (i) {\n var _a;\n var tmpRecord;\n var contained = gObj.currentViewData.some(function (record) {\n tmpRecord = record;\n return data[parseInt(i.toString(), 10)] === getObject(fieldname, record) || data[parseInt(i.toString(), 10)] === record;\n });\n data[parseInt(i.toString(), 10)] = contained ? tmpRecord : data[parseInt(i.toString(), 10)][\"\" + fieldname] ?\n data[parseInt(i.toString(), 10)] : (_a = {}, _a[fieldname] = data[parseInt(i.toString(), 10)], _a);\n };\n for (var i = 0; i < dataLen; i++) {\n _loop_2(i);\n }\n }\n var args = {\n requestType: 'delete', type: events.actionBegin, foreignKeyData: {},\n data: data ? data : this.parent.getSelectedRecords(), tr: this.parent.getSelectedRows(), cancel: false\n };\n if (!isNullOrUndefined(this.parent.commandDelIndex)) {\n args.data[0] =\n this.parent.getRowObjectFromUID(this.parent.getRowByIndex(this.parent.commandDelIndex).getAttribute('data-uid')).data;\n }\n if ((this.parent.enableVirtualization || this.parent.enableColumnVirtualization) && args.data.length > 1) {\n var uid = this.parent.getSelectedRows()[0].getAttribute('data-uid');\n args.data = [this.parent.getRowObjectFromUID(uid).data];\n }\n this.parent.notify(events.modelChanged, args);\n };\n NormalEdit.prototype.stopEditStatus = function () {\n var gObj = this.parent;\n var addElements = [].slice.call(gObj.element.getElementsByClassName(literals.addedRow));\n var editElements = [].slice.call(gObj.element.getElementsByClassName(literals.editedRow));\n for (var i = 0; i < addElements.length; i++) {\n remove(addElements[parseInt(i.toString(), 10)]);\n }\n for (var i = 0; i < editElements.length; i++) {\n editElements[parseInt(i.toString(), 10)].classList.remove(literals.editedRow);\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n NormalEdit.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.evtHandlers = [{ event: events.crudAction, handler: this.editHandler },\n { event: events.doubleTap, handler: this.dblClickHandler },\n { event: events.click, handler: this.clickHandler },\n { event: events.recordAdded, handler: this.requestSuccess },\n { event: events.dblclick, handler: this.dblClickHandler },\n { event: events.deleteComplete, handler: this.editComplete },\n { event: events.saveComplete, handler: this.editComplete },\n { event: events.rowModeChange, handler: this.closeEdit },\n { event: events.closeInline, handler: this.closeForm }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n };\n /**\n * @returns {void}\n * @hidden\n */\n NormalEdit.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n };\n /**\n * @returns {void}\n * @hidden\n */\n NormalEdit.prototype.destroy = function () {\n this.removeEventListener();\n this.renderer.destroy();\n };\n return NormalEdit;\n}());\nexport { NormalEdit };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { NormalEdit } from './normal-edit';\n/**\n * `InlineEdit` module is used to handle inline editing actions.\n *\n * @hidden\n */\nvar InlineEdit = /** @class */ (function (_super) {\n __extends(InlineEdit, _super);\n function InlineEdit(parent, serviceLocator, renderer) {\n var _this = _super.call(this, parent, serviceLocator) || this;\n _this.parent = parent;\n _this.serviceLocator = serviceLocator;\n _this.renderer = renderer;\n return _this;\n }\n InlineEdit.prototype.closeEdit = function () {\n _super.prototype.closeEdit.call(this);\n };\n InlineEdit.prototype.addRecord = function (data, index) {\n _super.prototype.addRecord.call(this, data, index);\n };\n InlineEdit.prototype.endEdit = function () {\n _super.prototype.endEdit.call(this);\n };\n InlineEdit.prototype.updateRow = function (index, data) {\n _super.prototype.updateRow.call(this, index, data);\n };\n InlineEdit.prototype.deleteRecord = function (fieldname, data) {\n _super.prototype.deleteRecord.call(this, fieldname, data);\n };\n InlineEdit.prototype.startEdit = function (tr) {\n _super.prototype.startEdit.call(this, tr);\n };\n return InlineEdit;\n}(NormalEdit));\nexport { InlineEdit };\n","import { extend, addClass, removeClass, setValue, closest, select, EventHandler } from '@syncfusion/ej2-base';\nimport { remove, classList } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, isUndefined } from '@syncfusion/ej2-base';\nimport { CellType } from '../base/enum';\nimport { parentsUntil, refreshForeignData, getObject, addRemoveEventListener, } from '../base/util';\nimport { getCellByColAndRowIndex, addFixedColumnBorder } from '../base/util';\nimport * as events from '../base/constant';\nimport { RowRenderer } from '../renderer/row-renderer';\nimport { CellRenderer } from '../renderer/cell-renderer';\nimport { Row } from '../models/row';\nimport { Cell } from '../models/cell';\nimport { RowModelGenerator } from '../services/row-model-generator';\nimport { DataUtil } from '@syncfusion/ej2-data';\nimport * as literals from '../base/string-literals';\n/**\n * `BatchEdit` module is used to handle batch editing actions.\n *\n * @hidden\n */\nvar BatchEdit = /** @class */ (function () {\n function BatchEdit(parent, serviceLocator, renderer) {\n this.cellDetails = {};\n this.originalCell = {};\n this.cloneCell = {};\n this.editNext = false;\n this.preventSaveCell = false;\n this.initialRender = true;\n this.validationColObj = [];\n /** @hidden */\n this.addBatchRow = false;\n this.prevEditedBatchCell = false;\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.renderer = renderer;\n this.focus = serviceLocator.getService('focus');\n this.addEventListener();\n }\n /**\n * @returns {void}\n * @hidden\n */\n BatchEdit.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.evtHandlers = [{ event: events.click, handler: this.clickHandler },\n { event: events.dblclick, handler: this.dblClickHandler },\n { event: events.beforeCellFocused, handler: this.onBeforeCellFocused },\n { event: events.cellFocused, handler: this.onCellFocused },\n { event: events.doubleTap, handler: this.dblClickHandler },\n { event: events.keyPressed, handler: this.keyDownHandler },\n { event: events.editNextValCell, handler: this.editNextValCell },\n { event: events.destroy, handler: this.destroy }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n EventHandler.add(this.parent.element, 'mousedown', this.mouseDownHandler, this);\n this.dataBoundFunction = this.dataBound.bind(this);\n this.batchCancelFunction = this.batchCancel.bind(this);\n this.parent.addEventListener(events.dataBound, this.dataBoundFunction);\n this.parent.addEventListener(events.batchCancel, this.batchCancelFunction);\n };\n /**\n * @returns {void}\n * @hidden\n */\n BatchEdit.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n EventHandler.remove(this.parent.element, 'mousedown', this.mouseDownHandler);\n this.parent.removeEventListener(events.dataBound, this.dataBoundFunction);\n this.parent.removeEventListener(events.batchCancel, this.batchCancelFunction);\n };\n BatchEdit.prototype.batchCancel = function () {\n this.parent.focusModule.restoreFocus();\n };\n BatchEdit.prototype.dataBound = function () {\n this.parent.notify(events.toolbarRefresh, {});\n };\n /**\n * @returns {void}\n * @hidden\n */\n BatchEdit.prototype.destroy = function () {\n this.removeEventListener();\n };\n BatchEdit.prototype.mouseDownHandler = function (e) {\n if (!isNullOrUndefined(this.parent.element.querySelector('.e-gridform'))) {\n this.mouseDownElement = e.target;\n }\n else {\n this.mouseDownElement = undefined;\n }\n };\n BatchEdit.prototype.clickHandler = function (e) {\n if (!parentsUntil(e.target, this.parent.element.id + '_add', true)) {\n if ((this.parent.isEdit && closest(this.form, 'td') !== closest(e.target, 'td'))\n && isNullOrUndefined(this.mouseDownElement) || this.mouseDownElement === e.target) {\n this.saveCell();\n this.editNextValCell();\n }\n if (parentsUntil(e.target, literals.rowCell) && !this.parent.isEdit) {\n this.setCellIdx(e.target);\n }\n }\n };\n BatchEdit.prototype.dblClickHandler = function (e) {\n var target = parentsUntil(e.target, literals.rowCell);\n var tr = parentsUntil(e.target, literals.row);\n var rowIndex = tr && parseInt(tr.getAttribute(literals.dataRowIndex), 10);\n var colIndex = target && parseInt(target.getAttribute(literals.dataColIndex), 10);\n if (!isNullOrUndefined(target) && !isNullOrUndefined(rowIndex) && !isNaN(colIndex)\n && !target.parentElement.classList.contains(literals.editedRow) &&\n this.parent.getColumns()[parseInt(colIndex.toString(), 10)].allowEditing) {\n this.editCell(rowIndex, this.parent.getColumns()[parseInt(colIndex.toString(), 10)].field, this.isAddRow(rowIndex));\n }\n };\n BatchEdit.prototype.onBeforeCellFocused = function (e) {\n if (this.parent.isEdit && this.validateFormObj() &&\n (e.byClick || (['tab', 'shiftTab', 'enter', 'shiftEnter'].indexOf(e.keyArgs.action) > -1))) {\n e.cancel = true;\n if (e.byClick) {\n e.clickArgs.preventDefault();\n }\n else {\n e.keyArgs.preventDefault();\n }\n }\n };\n BatchEdit.prototype.onCellFocused = function (e) {\n var clear = (!e.container.isContent || !e.container.isDataCell) && !(this.parent.frozenRows && e.container.isHeader);\n if (this.parent.focusModule.active) {\n this.prevEditedBatchCell = this.parent.focusModule.active.matrix.current.toString() === this.prevEditedBatchCellMatrix()\n .toString();\n this.crtRowIndex = [].slice.call(this.parent.focusModule.active.getTable().rows).indexOf(closest(e.element, 'tr'));\n }\n if (!e.byKey || clear) {\n if ((this.parent.isEdit && clear)) {\n this.saveCell();\n }\n return;\n }\n var _a = e.container.indexes, rowIndex = _a[0], cellIndex = _a[1];\n var actualIndex = e.element.getAttribute('data-colindex') ? parseInt(e.element.getAttribute('data-colindex')) : cellIndex;\n if (actualIndex !== cellIndex) {\n cellIndex = actualIndex;\n }\n if (this.parent.frozenRows && e.container.isContent) {\n rowIndex += ((this.parent.getContent().querySelector('.e-hiddenrow') ? 0 : this.parent.frozenRows) +\n this.parent.getHeaderContent().querySelectorAll('.e-insertedrow').length);\n }\n var isEdit = this.parent.isEdit;\n if (!this.parent.element.getElementsByClassName('e-popup-open').length) {\n isEdit = isEdit && !this.validateFormObj();\n switch (e.keyArgs.action) {\n case 'tab':\n case 'shiftTab':\n // eslint-disable-next-line no-case-declarations\n var indent = this.parent.isRowDragable() && this.parent.isDetail() ? 2 :\n this.parent.isRowDragable() || this.parent.isDetail() ? 1 : 0;\n // eslint-disable-next-line no-case-declarations\n var col = this.parent.getColumns()[cellIndex - indent];\n if (col && !this.parent.isEdit) {\n this.editCell(rowIndex, col.field);\n }\n if (isEdit || this.parent.isLastCellPrimaryKey) {\n this.editCellFromIndex(rowIndex, cellIndex);\n }\n break;\n case 'enter':\n case 'shiftEnter':\n e.keyArgs.preventDefault();\n // eslint-disable-next-line no-case-declarations\n var args = { cancel: false, keyArgs: e.keyArgs };\n this.parent.notify('beforeFocusCellEdit', args);\n if (!args.cancel && isEdit) {\n this.editCell(rowIndex, this.cellDetails.column.field);\n }\n break;\n case 'f2':\n this.editCellFromIndex(rowIndex, cellIndex);\n this.focus.focus();\n break;\n }\n }\n };\n BatchEdit.prototype.isAddRow = function (index) {\n return this.parent.getDataRows()[parseInt(index.toString(), 10)].classList.contains('e-insertedrow');\n };\n BatchEdit.prototype.editCellFromIndex = function (rowIdx, cellIdx) {\n this.cellDetails.rowIndex = rowIdx;\n this.cellDetails.cellIndex = cellIdx;\n this.editCell(rowIdx, this.parent.getColumns()[parseInt(cellIdx.toString(), 10)].field, this.isAddRow(rowIdx));\n };\n BatchEdit.prototype.closeEdit = function () {\n var gObj = this.parent;\n var rows = this.parent.getRowsObject();\n var argument = { cancel: false, batchChanges: this.getBatchChanges() };\n gObj.notify(events.beforeBatchCancel, argument);\n if (argument.cancel) {\n return;\n }\n if (gObj.isEdit) {\n this.saveCell(true);\n }\n this.isAdded = false;\n gObj.clearSelection();\n for (var i = 0; i < rows.length; i++) {\n var isInsert = false;\n var isDirty = rows[parseInt(i.toString(), 10)].isDirty;\n isInsert = this.removeBatchElementChanges(rows[parseInt(i.toString(), 10)], isDirty);\n if (isInsert) {\n rows.splice(i, 1);\n }\n if (isInsert) {\n i--;\n }\n }\n if (!gObj.getContentTable().querySelector('tr.e-row')) {\n gObj.renderModule.renderEmptyRow();\n }\n var args = {\n requestType: 'batchCancel', rows: this.parent.getRowsObject()\n };\n gObj.notify(events.batchCancel, {\n rows: this.parent.getRowsObject().length ? this.parent.getRowsObject() :\n [new Row({ isDataRow: true, cells: [new Cell({ isDataCell: true, visible: true })] })]\n });\n gObj.selectRow(this.cellDetails.rowIndex);\n this.refreshRowIdx();\n gObj.notify(events.toolbarRefresh, {});\n this.parent.notify(events.tooltipDestroy, {});\n args = { requestType: 'batchCancel', rows: this.parent.getRowsObject() };\n gObj.trigger(events.batchCancel, args);\n };\n BatchEdit.prototype.removeBatchElementChanges = function (row, isDirty) {\n var gObj = this.parent;\n var rowRenderer = new RowRenderer(this.serviceLocator, null, this.parent);\n var isInstertedRemoved = false;\n if (isDirty) {\n row.isDirty = isDirty;\n var tr = gObj.getRowElementByUID(row.uid);\n if (tr) {\n if (tr.classList.contains('e-insertedrow')) {\n remove(tr);\n isInstertedRemoved = true;\n }\n else {\n refreshForeignData(row, this.parent.getForeignKeyColumns(), row.data);\n delete row.changes;\n delete row.edit;\n row.isDirty = false;\n classList(tr, [], ['e-hiddenrow', 'e-updatedtd']);\n rowRenderer.refresh(row, gObj.getColumns(), false);\n }\n if (this.parent.aggregates.length > 0) {\n var type = 'type';\n var editType = [];\n editType[\"\" + type] = 'cancel';\n this.parent.notify(events.refreshFooterRenderer, editType);\n if (this.parent.groupSettings.columns.length > 0) {\n this.parent.notify(events.groupAggregates, editType);\n }\n }\n }\n }\n return isInstertedRemoved;\n };\n BatchEdit.prototype.deleteRecord = function (fieldname, data) {\n this.saveCell();\n if (this.validateFormObj()) {\n this.saveCell(true);\n }\n this.isAdded = false;\n this.bulkDelete(fieldname, data);\n if (this.parent.aggregates.length > 0) {\n this.parent.notify(events.refreshFooterRenderer, {});\n if (this.parent.groupSettings.columns.length > 0) {\n this.parent.notify(events.groupAggregates, {});\n }\n }\n };\n BatchEdit.prototype.addRecord = function (data) {\n this.bulkAddRow(data);\n };\n BatchEdit.prototype.endEdit = function () {\n if (this.parent.isEdit && this.validateFormObj()) {\n return;\n }\n this.batchSave();\n };\n BatchEdit.prototype.validateFormObj = function () {\n return this.parent.editModule.formObj && !this.parent.editModule.formObj.validate();\n };\n BatchEdit.prototype.batchSave = function () {\n var gObj = this.parent;\n var deletedRecords = 'deletedRecords';\n if (gObj.isCheckBoxSelection) {\n var checkAllBox = gObj.element.querySelector('.e-checkselectall').parentElement;\n if (checkAllBox.classList.contains('e-checkbox-disabled') &&\n gObj.pageSettings.totalRecordsCount > gObj.currentViewData.length) {\n removeClass([checkAllBox], ['e-checkbox-disabled']);\n }\n }\n this.saveCell();\n if (gObj.isEdit || this.editNextValCell() || gObj.isEdit) {\n return;\n }\n var changes = this.getBatchChanges();\n if (this.parent.selectionSettings.type === 'Multiple' && changes[\"\" + deletedRecords].length &&\n this.parent.selectionSettings.persistSelection) {\n changes[\"\" + deletedRecords] = this.removeSelectedData;\n this.removeSelectedData = [];\n }\n var original = {\n changedRecords: this.parent.getRowsObject()\n .filter(function (row) { return row.isDirty && ['add', 'delete'].indexOf(row.edit) === -1; })\n .map(function (row) { return row.data; })\n };\n var args = { batchChanges: changes, cancel: false };\n gObj.trigger(events.beforeBatchSave, args, function (beforeBatchSaveArgs) {\n if (beforeBatchSaveArgs.cancel) {\n return;\n }\n gObj.showSpinner();\n gObj.notify(events.bulkSave, { changes: changes, original: original });\n });\n };\n BatchEdit.prototype.getBatchChanges = function () {\n var changes = {\n addedRecords: [],\n deletedRecords: [],\n changedRecords: []\n };\n var rows = this.parent.getRowsObject();\n for (var _i = 0, rows_1 = rows; _i < rows_1.length; _i++) {\n var row = rows_1[_i];\n if (row.isDirty) {\n switch (row.edit) {\n case 'add':\n changes.addedRecords.push(row.changes);\n break;\n case 'delete':\n changes.deletedRecords.push(row.data);\n break;\n default:\n changes.changedRecords.push(row.changes);\n }\n }\n }\n return changes;\n };\n /**\n * @param {string} uid - specifes the uid\n * @returns {void}\n * @hidden\n */\n BatchEdit.prototype.removeRowObjectFromUID = function (uid) {\n var rows = this.parent.getRowsObject();\n var i = 0;\n for (var len = rows.length; i < len; i++) {\n if (rows[parseInt(i.toString(), 10)].uid === uid) {\n break;\n }\n }\n rows.splice(i, 1);\n };\n /**\n * @param {Row<Column>} row - specifies the row object\n * @param {freezeTable} newTableName - specifies the table name\n * @returns {void}\n * @hidden\n */\n BatchEdit.prototype.addRowObject = function (row) {\n var gObj = this.parent;\n var isTop = gObj.editSettings.newRowPosition === 'Top';\n var rowClone = row.clone();\n if (isTop) {\n gObj.getRowsObject().unshift(rowClone);\n }\n else {\n gObj.getRowsObject().push(rowClone);\n }\n };\n // tslint:disable-next-line:max-func-body-length\n BatchEdit.prototype.bulkDelete = function (fieldname, data) {\n var _this = this;\n this.removeSelectedData = [];\n var gObj = this.parent;\n var index = gObj.selectedRowIndex;\n var selectedRows = gObj.getSelectedRows();\n var args = {\n primaryKey: this.parent.getPrimaryKeyFieldNames(),\n rowIndex: index,\n rowData: data ? data : gObj.getSelectedRecords()[0],\n cancel: false\n };\n if (data) {\n args.row = gObj.editModule.deleteRowUid ? gObj.getRowElementByUID(gObj.editModule.deleteRowUid)\n : gObj.getRows()[gObj.getCurrentViewRecords().indexOf(data)];\n }\n else {\n args.row = selectedRows[0];\n }\n if (!args.row) {\n return;\n }\n // tslint:disable-next-line:max-func-body-length\n gObj.trigger(events.beforeBatchDelete, args, function (beforeBatchDeleteArgs) {\n if (beforeBatchDeleteArgs.cancel) {\n return;\n }\n _this.removeSelectedData = gObj.getSelectedRecords();\n gObj.clearSelection();\n beforeBatchDeleteArgs.row = beforeBatchDeleteArgs.row ?\n beforeBatchDeleteArgs.row : data ? gObj.getRows()[parseInt(index.toString(), 10)] : selectedRows[0];\n if (selectedRows.length === 1 || data) {\n var uid = beforeBatchDeleteArgs.row.getAttribute('data-uid');\n uid = data && _this.parent.editModule.deleteRowUid ? uid = _this.parent.editModule.deleteRowUid : uid;\n if (beforeBatchDeleteArgs.row.classList.contains('e-insertedrow')) {\n _this.removeRowObjectFromUID(uid);\n remove(beforeBatchDeleteArgs.row);\n }\n else {\n var rowObj = gObj.getRowObjectFromUID(uid);\n rowObj.isDirty = true;\n rowObj.edit = 'delete';\n classList(beforeBatchDeleteArgs.row, ['e-hiddenrow', 'e-updatedtd'], []);\n if (gObj.frozenRows && index < gObj.frozenRows && gObj.getDataRows().length >= gObj.frozenRows) {\n gObj.getHeaderTable().querySelector(literals.tbody).appendChild(gObj.getRowByIndex(gObj.frozenRows - 1));\n }\n }\n delete beforeBatchDeleteArgs.row;\n }\n else {\n if (data) {\n index = parseInt(beforeBatchDeleteArgs.row.getAttribute(literals.dataRowIndex), 10);\n }\n for (var i = 0; i < selectedRows.length; i++) {\n var uniqueid = selectedRows[parseInt(i.toString(), 10)].getAttribute('data-uid');\n if (selectedRows[parseInt(i.toString(), 10)].classList.contains('e-insertedrow')) {\n _this.removeRowObjectFromUID(uniqueid);\n remove(selectedRows[parseInt(i.toString(), 10)]);\n }\n else {\n classList(selectedRows[parseInt(i.toString(), 10)], ['e-hiddenrow', 'e-updatedtd'], []);\n var selectedRow = gObj.getRowObjectFromUID(uniqueid);\n selectedRow.isDirty = true;\n selectedRow.edit = 'delete';\n delete selectedRows[parseInt(i.toString(), 10)];\n if (gObj.frozenRows && index < gObj.frozenRows && gObj.getDataRows().length >= gObj.frozenRows) {\n gObj.getHeaderTable().querySelector(literals.tbody).appendChild(gObj.getRowByIndex(gObj.frozenRows - 1));\n }\n }\n }\n }\n _this.refreshRowIdx();\n if (data) {\n gObj.editModule.deleteRowUid = undefined;\n }\n if (!gObj.isCheckBoxSelection) {\n gObj.selectRow(index);\n }\n gObj.trigger(events.batchDelete, beforeBatchDeleteArgs);\n gObj.notify(events.batchDelete, { rows: _this.parent.getRowsObject() });\n gObj.notify(events.toolbarRefresh, {});\n });\n };\n BatchEdit.prototype.refreshRowIdx = function () {\n var gObj = this.parent;\n var rows = gObj.getAllDataRows(true);\n var dataObjects = gObj.getRowsObject().filter(function (row) { return !row.isDetailRow; });\n for (var i = 0, j = 0, len = rows.length; i < len; i++) {\n if (rows[parseInt(i.toString(), 10)].classList.contains(literals.row) && !rows[parseInt(i.toString(), 10)].classList.contains('e-hiddenrow')) {\n rows[parseInt(i.toString(), 10)].setAttribute(literals.dataRowIndex, j.toString());\n rows[parseInt(i.toString(), 10)].setAttribute(literals.ariaRowIndex, (j + 1).toString());\n dataObjects[parseInt(i.toString(), 10)].index = j;\n j++;\n }\n else {\n rows[parseInt(i.toString(), 10)].removeAttribute(literals.dataRowIndex);\n rows[parseInt(i.toString(), 10)].removeAttribute(literals.ariaRowIndex);\n dataObjects[parseInt(i.toString(), 10)].index = -1;\n }\n }\n };\n BatchEdit.prototype.bulkAddRow = function (data) {\n var _this = this;\n var gObj = this.parent;\n if (!gObj.editSettings.allowAdding) {\n if (gObj.isEdit) {\n this.saveCell();\n }\n return;\n }\n if (gObj.isEdit) {\n this.saveCell();\n this.parent.notify(events.editNextValCell, {});\n }\n if (this.initialRender) {\n var visibleColumns = gObj.getVisibleColumns();\n for (var i = 0; i < visibleColumns.length; i++) {\n if (visibleColumns[parseInt(i.toString(), 10)].validationRules &&\n visibleColumns[parseInt(i.toString(), 10)].validationRules['required']) {\n var obj = { field: (visibleColumns[parseInt(i.toString(), 10)]['field']).slice(), cellIdx: i };\n this.validationColObj.push(obj);\n }\n }\n this.initialRender = false;\n }\n this.parent.element.classList.add('e-editing');\n var defaultData = data ? data : this.getDefaultData();\n var args = {\n defaultData: defaultData,\n primaryKey: gObj.getPrimaryKeyFieldNames(),\n cancel: false\n };\n gObj.trigger(events.beforeBatchAdd, args, function (beforeBatchAddArgs) {\n if (beforeBatchAddArgs.cancel) {\n return;\n }\n _this.isAdded = true;\n gObj.clearSelection();\n var row = new RowRenderer(_this.serviceLocator, null, _this.parent);\n var model = new RowModelGenerator(_this.parent);\n var modelData = model.generateRows([beforeBatchAddArgs.defaultData]);\n var tr = row.render(modelData[0], gObj.getColumns());\n addFixedColumnBorder(tr);\n var col;\n var index;\n for (var i = 0; i < _this.parent.groupSettings.columns.length; i++) {\n tr.insertBefore(_this.parent.createElement('td', { className: 'e-indentcell' }), tr.firstChild);\n modelData[0].cells.unshift(new Cell({ cellType: CellType.Indent }));\n }\n var tbody = gObj.getContentTable().querySelector(literals.tbody);\n tr.classList.add('e-insertedrow');\n if (tbody.querySelector('.e-emptyrow')) {\n var emptyRow = tbody.querySelector('.e-emptyrow');\n emptyRow.parentNode.removeChild(emptyRow);\n if (gObj.frozenRows && gObj.element.querySelector('.e-frozenrow-empty')) {\n gObj.element.querySelector('.e-frozenrow-empty').classList.remove('e-frozenrow-empty');\n }\n }\n if (gObj.frozenRows && gObj.editSettings.newRowPosition === 'Top') {\n tbody = gObj.getHeaderTable().querySelector(literals.tbody);\n }\n else {\n tbody = gObj.getContentTable().querySelector(literals.tbody);\n }\n if (_this.parent.editSettings.newRowPosition === 'Top') {\n tbody.insertBefore(tr, tbody.firstChild);\n }\n else {\n tbody.appendChild(tr);\n }\n addClass([].slice.call(tr.getElementsByClassName(literals.rowCell)), ['e-updatedtd']);\n modelData[0].isDirty = true;\n modelData[0].changes = extend({}, {}, modelData[0].data, true);\n modelData[0].edit = 'add';\n _this.addRowObject(modelData[0]);\n _this.refreshRowIdx();\n _this.focus.forgetPrevious();\n gObj.notify(events.batchAdd, { rows: _this.parent.getRowsObject() });\n var changes = _this.getBatchChanges();\n var btmIdx = _this.getBottomIndex();\n if (_this.parent.editSettings.newRowPosition === 'Top') {\n gObj.selectRow(0);\n }\n else {\n gObj.selectRow(btmIdx);\n }\n if (!data) {\n index = _this.findNextEditableCell(0, true);\n col = gObj.getColumns()[parseInt(index.toString(), 10)];\n if (_this.parent.editSettings.newRowPosition === 'Top') {\n _this.editCell(0, col.field, true);\n }\n else {\n _this.editCell(btmIdx, col.field, true);\n }\n }\n if (_this.parent.aggregates.length > 0 && (data || changes[literals.addedRecords].length)) {\n _this.parent.notify(events.refreshFooterRenderer, {});\n }\n var args1 = {\n defaultData: beforeBatchAddArgs.defaultData, row: tr,\n columnObject: col, columnIndex: index, primaryKey: beforeBatchAddArgs.primaryKey,\n cell: !isNullOrUndefined(index) ? tr.cells[parseInt(index.toString(), 10)] : undefined\n };\n gObj.trigger(events.batchAdd, args1);\n });\n };\n BatchEdit.prototype.findNextEditableCell = function (columnIndex, isAdd, isValOnly) {\n var cols = this.parent.getColumns();\n var endIndex = cols.length;\n var validation;\n for (var i = columnIndex; i < endIndex; i++) {\n validation = isValOnly ? isNullOrUndefined(cols[parseInt(i.toString(), 10)].validationRules) : false;\n // if (!isAdd && this.checkNPCell(cols[parseInt(i.toString(), 10)])) {\n // return i;\n // } else \n if (isAdd && (!cols[parseInt(i.toString(), 10)].template || cols[parseInt(i.toString(), 10)].field)\n && cols[parseInt(i.toString(), 10)].allowEditing && cols[parseInt(i.toString(), 10)].visible &&\n !(cols[parseInt(i.toString(), 10)].isIdentity && cols[parseInt(i.toString(), 10)].isPrimaryKey) && !validation) {\n return i;\n }\n }\n return -1;\n };\n BatchEdit.prototype.getDefaultData = function () {\n var gObj = this.parent;\n var data = {};\n var dValues = { 'number': 0, 'string': null, 'boolean': false, 'date': null, 'datetime': null };\n for (var _i = 0, _a = (gObj.columnModel); _i < _a.length; _i++) {\n var col = _a[_i];\n if (col.field) {\n setValue(col.field, Object.keys(col).indexOf('defaultValue') >= 0 ? col.defaultValue : dValues[col.type], data);\n }\n }\n return data;\n };\n BatchEdit.prototype.setCellIdx = function (target) {\n var gLen = 0;\n if (this.parent.allowGrouping) {\n gLen = this.parent.groupSettings.columns.length;\n }\n this.cellDetails.cellIndex = target.cellIndex - gLen;\n this.cellDetails.rowIndex = parseInt(target.getAttribute('index'), 10);\n };\n BatchEdit.prototype.editCell = function (index, field, isAdd) {\n var gObj = this.parent;\n var col = gObj.getColumnByField(field);\n this.index = index;\n this.field = field;\n this.isAdd = isAdd;\n var checkEdit = gObj.isEdit && !(this.cellDetails.column.field === field\n && (this.cellDetails.rowIndex === index && this.parent.getDataRows().length - 1 !== index && this.prevEditedBatchCell));\n if (gObj.editSettings.allowEditing) {\n if (!checkEdit && (col.allowEditing || (!col.allowEditing && gObj.focusModule.active\n && gObj.focusModule.active.getTable().rows[this.crtRowIndex]\n && gObj.focusModule.active.getTable().rows[this.crtRowIndex].classList.contains('e-insertedrow')))) {\n this.editCellExtend(index, field, isAdd);\n }\n else if (checkEdit) {\n this.editNext = true;\n this.saveCell();\n }\n }\n };\n BatchEdit.prototype.editCellExtend = function (index, field, isAdd) {\n var _this = this;\n var gObj = this.parent;\n var col = gObj.getColumnByField(field);\n var keys = gObj.getPrimaryKeyFieldNames();\n if (gObj.isEdit) {\n return;\n }\n var rowData = extend({}, {}, this.getDataByIndex(index), true);\n var row = gObj.getDataRows()[parseInt(index.toString(), 10)];\n rowData = extend({}, {}, this.getDataByIndex(index), true);\n if ((keys[0] === col.field && !row.classList.contains('e-insertedrow')) || col.columns ||\n (col.isPrimaryKey && col.isIdentity) || col.commands) {\n this.parent.isLastCellPrimaryKey = true;\n return;\n }\n this.parent.isLastCellPrimaryKey = false;\n this.parent.element.classList.add('e-editing');\n var rowObj = gObj.getRowObjectFromUID(row.getAttribute('data-uid'));\n var cells = [].slice.apply(row.cells);\n var args = {\n columnName: col.field, isForeignKey: !isNullOrUndefined(col.foreignKeyValue),\n primaryKey: keys, rowData: rowData,\n validationRules: extend({}, col.validationRules ? col.validationRules : {}),\n value: getObject(col.field, rowData),\n type: !isAdd ? 'edit' : 'add', cancel: false,\n foreignKeyData: rowObj && rowObj.foreignKeyData\n };\n args.cell = cells[this.getColIndex(cells, this.getCellIdx(col.uid))];\n args.row = row;\n args.columnObject = col;\n if (!args.cell) {\n return;\n }\n gObj.trigger(events.cellEdit, args, function (cellEditArgs) {\n if (cellEditArgs.cancel) {\n return;\n }\n cellEditArgs.cell = cellEditArgs.cell ? cellEditArgs.cell : cells[_this.getColIndex(cells, _this.getCellIdx(col.uid))];\n cellEditArgs.row = cellEditArgs.row ? cellEditArgs.row : row;\n cellEditArgs.columnObject = cellEditArgs.columnObject ? cellEditArgs.columnObject : col;\n // cellEditArgs.columnObject.index = isNullOrUndefined(cellEditArgs.columnObject.index) ? 0 : cellEditArgs.columnObject.index;\n _this.cellDetails = {\n rowData: rowData, column: col, value: cellEditArgs.value, isForeignKey: cellEditArgs.isForeignKey, rowIndex: index,\n cellIndex: parseInt(cellEditArgs.cell.getAttribute(literals.dataColIndex), 10),\n foreignKeyData: cellEditArgs.foreignKeyData\n };\n if (cellEditArgs.cell.classList.contains('e-updatedtd')) {\n _this.isColored = true;\n cellEditArgs.cell.classList.remove('e-updatedtd');\n }\n gObj.isEdit = true;\n gObj.clearSelection();\n if (!gObj.isCheckBoxSelection || !gObj.isPersistSelection) {\n gObj.selectRow(_this.cellDetails.rowIndex, true);\n }\n _this.renderer.update(cellEditArgs);\n _this.parent.notify(events.batchEditFormRendered, cellEditArgs);\n _this.form = select('#' + gObj.element.id + 'EditForm', gObj.element);\n gObj.editModule.applyFormValidation([col]);\n _this.parent.element.querySelector('.e-gridpopup').style.display = 'none';\n });\n };\n BatchEdit.prototype.updateCell = function (rowIndex, field, value) {\n var gObj = this.parent;\n var col = gObj.getColumnByField(field);\n var index = gObj.getColumnIndexByField(field);\n if (col && !col.isPrimaryKey && col.allowEditing) {\n var td_1 = getCellByColAndRowIndex(this.parent, col, rowIndex, index);\n var rowObj_1 = gObj.getRowObjectFromUID(td_1.parentElement.getAttribute('data-uid'));\n if (gObj.isEdit ||\n (!rowObj_1.changes && ((!(value instanceof Date) && rowObj_1.data[\"\" + field] !== value) ||\n ((value instanceof Date) && new Date(rowObj_1.data[\"\" + field]).toString() !== new Date(value).toString()))) ||\n (rowObj_1.changes && ((!(value instanceof Date) && rowObj_1.changes[\"\" + field] !== value) ||\n ((value instanceof Date) && new Date(rowObj_1.changes[\"\" + field]).toString() !== new Date(value).toString())))) {\n this.refreshTD(td_1, col, rowObj_1, value);\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n if (((this.parent.isReact && this.parent.requireTemplateRef) || (isReactChild &&\n this.parent.parentDetails.parentInstObj.requireTemplateRef)) && col.template) {\n var thisRef_1 = this;\n var newReactTd_1 = this.newReactTd;\n thisRef_1.parent.renderTemplates(function () {\n thisRef_1.parent.trigger(events.queryCellInfo, {\n cell: newReactTd_1 || td_1, column: col, data: rowObj_1.changes\n });\n });\n }\n else if ((this.parent.isReact || isReactChild) && col.template) {\n this.parent.renderTemplates();\n this.parent.trigger(events.queryCellInfo, {\n cell: this.newReactTd || td_1, column: col, data: rowObj_1.changes\n });\n }\n else {\n this.parent.trigger(events.queryCellInfo, {\n cell: this.newReactTd || td_1, column: col, data: rowObj_1.changes\n });\n }\n }\n }\n };\n BatchEdit.prototype.setChanges = function (rowObj, field, value) {\n if (!rowObj.changes) {\n rowObj.changes = extend({}, {}, rowObj.data, true);\n }\n if (!isNullOrUndefined(field)) {\n if (typeof value === 'string') {\n value = this.parent.sanitize(value);\n }\n DataUtil.setValue(field, value, rowObj.changes);\n }\n if (rowObj.data[\"\" + field] !== value) {\n var type = this.parent.getColumnByField(field).type;\n if ((type === 'date' || type === 'datetime')) {\n if (new Date(rowObj.data[\"\" + field]).toString() !== new Date(value).toString()) {\n rowObj.isDirty = true;\n }\n }\n else {\n rowObj.isDirty = true;\n }\n }\n };\n BatchEdit.prototype.updateRow = function (index, data) {\n var keys = Object.keys(data);\n for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) {\n var col = keys_1[_i];\n this.updateCell(index, col, data[\"\" + col]);\n }\n };\n BatchEdit.prototype.getCellIdx = function (uid) {\n var cIdx = this.parent.getColumnIndexByUid(uid) + this.parent.groupSettings.columns.length;\n if (!isNullOrUndefined(this.parent.detailTemplate) || !isNullOrUndefined(this.parent.childGrid)) {\n cIdx++;\n }\n if (this.parent.isRowDragable()) {\n cIdx++;\n }\n return cIdx;\n };\n BatchEdit.prototype.refreshTD = function (td, column, rowObj, value) {\n var cell = new CellRenderer(this.parent, this.serviceLocator);\n value = column.type === 'number' && !isNullOrUndefined(value) ? parseFloat(value) : value;\n if (rowObj) {\n this.setChanges(rowObj, column.field, value);\n refreshForeignData(rowObj, this.parent.getForeignKeyColumns(), rowObj.changes);\n }\n var rowcell = rowObj ? rowObj.cells : undefined;\n var parentElement;\n var cellIndex;\n if (this.parent.isReact) {\n parentElement = td.parentElement;\n cellIndex = td.cellIndex;\n }\n var index = 0;\n if (rowObj) {\n cell.refreshTD(td, rowcell[this.getCellIdx(column.uid) - index], rowObj.changes, { 'index': this.getCellIdx(column.uid) });\n }\n if (this.parent.isReact) {\n this.newReactTd = parentElement.cells[parseInt(cellIndex.toString(), 10)];\n parentElement.cells[parseInt(cellIndex.toString(), 10)].classList.add('e-updatedtd');\n }\n else {\n td.classList.add('e-updatedtd');\n }\n td.classList.add('e-updatedtd');\n this.parent.notify(events.toolbarRefresh, {});\n };\n BatchEdit.prototype.getColIndex = function (cells, index) {\n var cIdx = 0;\n if (this.parent.allowGrouping && this.parent.groupSettings.columns) {\n cIdx = this.parent.groupSettings.columns.length;\n }\n if (!isNullOrUndefined(this.parent.detailTemplate) || !isNullOrUndefined(this.parent.childGrid)) {\n cIdx++;\n }\n if (this.parent.isRowDragable()) {\n cIdx++;\n }\n for (var m = 0; m < cells.length; m++) {\n var colIndex = parseInt(cells[parseInt(m.toString(), 10)].getAttribute(literals.dataColIndex), 10);\n if (colIndex === index - cIdx) {\n return m;\n }\n }\n return -1;\n };\n BatchEdit.prototype.editNextValCell = function () {\n var gObj = this.parent;\n var insertedRows = gObj.element.querySelectorAll('.e-insertedrow');\n var isSingleInsert = insertedRows.length === 1 ? true : false;\n if (isSingleInsert && this.isAdded && !gObj.isEdit) {\n var btmIdx = this.getBottomIndex();\n for (var i = this.cellDetails.cellIndex; i < gObj.getColumns().length; i++) {\n if (gObj.isEdit) {\n return;\n }\n var index = this.findNextEditableCell(this.cellDetails.cellIndex + 1, true, true);\n var col = gObj.getColumns()[parseInt(index.toString(), 10)];\n if (col) {\n if (this.parent.editSettings.newRowPosition === 'Bottom') {\n this.editCell(btmIdx, col.field, true);\n }\n else {\n var args = { index: 0, column: col };\n this.parent.notify(events.nextCellIndex, args);\n this.editCell(args.index, col.field, true);\n }\n this.saveCell();\n }\n }\n if (!gObj.isEdit) {\n this.isAdded = false;\n }\n }\n else if (!isSingleInsert && this.isAdded && !gObj.isEdit) {\n var editRowIdx = 0;\n if (gObj.editSettings.newRowPosition === 'Bottom') {\n var changes = this.getBatchChanges();\n editRowIdx = gObj.getCurrentViewRecords().length - changes[literals.deletedRecords].length;\n }\n for (var i = 0; i < insertedRows.length; i++) {\n if (!gObj.isEdit) {\n for (var j = 0; j < this.validationColObj.length; j++) {\n if (gObj.isEdit) {\n break;\n }\n else if (insertedRows[parseInt(i.toString(), 10)].querySelectorAll('td:not(.e-hide)')[this.validationColObj[parseInt(j.toString(), 10)].cellIdx].innerHTML === '') {\n this.editCell(parseInt(insertedRows[parseInt(i.toString(), 10)].getAttribute('data-rowindex'), 10), this.validationColObj[parseInt(j.toString(), 10)].field);\n if (this.validateFormObj()) {\n this.saveCell();\n }\n }\n }\n }\n else {\n break;\n }\n }\n if (!gObj.isEdit) {\n this.isAdded = false;\n }\n }\n };\n BatchEdit.prototype.escapeCellEdit = function () {\n var args = this.generateCellArgs();\n args.value = args.previousValue;\n if (args.value || !this.cellDetails.column.validationRules) {\n this.successCallBack(args, args.cell.parentElement, args.column, true)(args);\n }\n };\n BatchEdit.prototype.generateCellArgs = function () {\n var gObj = this.parent;\n this.parent.element.classList.remove('e-editing');\n var column = this.cellDetails.column;\n var obj = {};\n obj[column.field] = getObject(column.field, this.cellDetails.rowData);\n var editedData = gObj.editModule.getCurrentEditedData(this.form, obj);\n var cloneEditedData = extend({}, editedData);\n editedData = extend({}, editedData, this.cellDetails.rowData);\n var value = getObject(column.field, cloneEditedData);\n if (!isNullOrUndefined(column.field) && !isUndefined(value)) {\n setValue(column.field, value, editedData);\n }\n var args = {\n columnName: column.field,\n value: getObject(column.field, editedData),\n rowData: this.cellDetails.rowData,\n column: column,\n previousValue: this.cellDetails.value,\n isForeignKey: this.cellDetails.isForeignKey,\n cancel: false\n };\n args.cell = this.form.parentElement;\n args.columnObject = column;\n return args;\n };\n BatchEdit.prototype.saveCell = function (isForceSave) {\n if (this.preventSaveCell || !this.form) {\n return;\n }\n var gObj = this.parent;\n if (!isForceSave && (!gObj.isEdit || this.validateFormObj())) {\n return;\n }\n this.preventSaveCell = true;\n var args = this.generateCellArgs();\n var tr = args.cell.parentElement;\n var col = args.column;\n args.cell.removeAttribute('aria-label');\n if (!isForceSave) {\n gObj.trigger(events.cellSave, args, this.successCallBack(args, tr, col));\n gObj.notify(events.batchForm, { formObj: this.form });\n }\n else {\n this.successCallBack(args, tr, col)(args);\n }\n };\n BatchEdit.prototype.successCallBack = function (cellSaveArgs, tr, column, isEscapeCellEdit) {\n var _this = this;\n return function (cellSaveArgs) {\n var gObj = _this.parent;\n cellSaveArgs.cell = cellSaveArgs.cell ? cellSaveArgs.cell : _this.form.parentElement;\n cellSaveArgs.columnObject = cellSaveArgs.columnObject ? cellSaveArgs.columnObject : column;\n // cellSaveArgs.columnObject.index = isNullOrUndefined(cellSaveArgs.columnObject.index) ? 0 : cellSaveArgs.columnObject.index;\n if (cellSaveArgs.cancel) {\n _this.preventSaveCell = false;\n if (_this.editNext) {\n _this.editNext = false;\n if (_this.cellDetails.rowIndex === _this.index && _this.cellDetails.column.field === _this.field) {\n return;\n }\n _this.editCellExtend(_this.index, _this.field, _this.isAdd);\n }\n return;\n }\n gObj.editModule.destroyWidgets([column]);\n gObj.isEdit = false;\n gObj.editModule.destroyForm();\n _this.parent.notify(events.tooltipDestroy, {});\n var rowObj = gObj.getRowObjectFromUID(tr.getAttribute('data-uid'));\n _this.refreshTD(cellSaveArgs.cell, column, rowObj, cellSaveArgs.value);\n if (_this.parent.isReact) {\n cellSaveArgs.cell = _this.newReactTd;\n }\n removeClass([tr], [literals.editedRow, 'e-batchrow']);\n removeClass([cellSaveArgs.cell], ['e-editedbatchcell', 'e-boolcell']);\n if (!isNullOrUndefined(cellSaveArgs.value) && cellSaveArgs.value.toString() ===\n (!isNullOrUndefined(_this.cellDetails.value) ? _this.cellDetails.value : '').toString() && !_this.isColored\n || (isNullOrUndefined(cellSaveArgs.value) && isNullOrUndefined(rowObj.data[column.field]) &&\n isNullOrUndefined(_this.cellDetails.value) && !cellSaveArgs.cell.parentElement.classList.contains('e-insertedrow'))) {\n cellSaveArgs.cell.classList.remove('e-updatedtd');\n }\n if (isNullOrUndefined(isEscapeCellEdit)) {\n var isReactCompiler = gObj.isReact && column.template && typeof (column.template) !== 'string';\n var isReactChild = gObj.parentDetails && gObj.parentDetails.parentInstObj\n && gObj.parentDetails.parentInstObj.isReact;\n if (isReactCompiler || isReactChild) {\n if (gObj.requireTemplateRef) {\n gObj.renderTemplates(function () {\n gObj.trigger(events.cellSaved, cellSaveArgs);\n });\n }\n else {\n gObj.renderTemplates();\n gObj.trigger(events.cellSaved, cellSaveArgs);\n }\n }\n else {\n gObj.trigger(events.cellSaved, cellSaveArgs);\n }\n }\n gObj.notify(events.toolbarRefresh, {});\n _this.isColored = false;\n if (_this.parent.aggregates.length > 0) {\n if (!(_this.parent.isReact || _this.parent.isVue)) {\n _this.parent.notify(events.refreshFooterRenderer, {});\n }\n if (_this.parent.groupSettings.columns.length > 0 && !_this.isAddRow(_this.cellDetails.rowIndex)) {\n _this.parent.notify(events.groupAggregates, {});\n }\n if (_this.parent.isReact || _this.parent.isVue) {\n _this.parent.notify(events.refreshFooterRenderer, {});\n }\n }\n _this.preventSaveCell = false;\n if (_this.editNext) {\n _this.editNext = false;\n if (_this.cellDetails.rowIndex === _this.index && _this.cellDetails.column.field === _this.field && _this.prevEditedBatchCell) {\n return;\n }\n var col = gObj.getColumnByField(_this.field);\n if (col && (col.allowEditing || (!col.allowEditing && gObj.focusModule.active\n && gObj.focusModule.active.getTable().rows[_this.crtRowIndex]\n && gObj.focusModule.active.getTable().rows[_this.crtRowIndex].classList.contains('e-insertedrow')))) {\n _this.editCellExtend(_this.index, _this.field, _this.isAdd);\n }\n }\n if (isEscapeCellEdit) {\n gObj.notify(events.restoreFocus, {});\n }\n };\n };\n BatchEdit.prototype.prevEditedBatchCellMatrix = function () {\n var editedBatchCellMatrix = [];\n var gObj = this.parent;\n var editedBatchCell = gObj.focusModule.active.getTable().querySelector('.e-editedbatchcell');\n if (editedBatchCell) {\n var tr = editedBatchCell.parentElement;\n var rowIndex = [].slice.call(this.parent.focusModule.active.getTable().rows).indexOf(tr);\n var cellIndex = [].slice.call(tr.cells).indexOf(editedBatchCell);\n editedBatchCellMatrix = [rowIndex, cellIndex];\n }\n return editedBatchCellMatrix;\n };\n BatchEdit.prototype.getDataByIndex = function (index) {\n var row = this.parent.getRowObjectFromUID(this.parent.getDataRows()[parseInt(index.toString(), 10)].getAttribute('data-uid'));\n return row.changes ? row.changes : row.data;\n };\n BatchEdit.prototype.keyDownHandler = function (e) {\n if (this.addBatchRow || ((e.action === 'tab' || e.action === 'shiftTab') && this.parent.isEdit)) {\n var gObj = this.parent;\n var btmIdx = this.getBottomIndex();\n var rowcell = parentsUntil(e.target, literals.rowCell);\n if (this.addBatchRow || (rowcell && !this.parent.isReact)) {\n var cell = void 0;\n if (rowcell) {\n cell = rowcell.querySelector('.e-field');\n }\n if (this.addBatchRow || cell) {\n var visibleColumns = this.parent.getVisibleColumns();\n var columnIndex = e.action === 'tab' ? visibleColumns.length - 1 : 0;\n if (this.addBatchRow\n || visibleColumns[parseInt(columnIndex.toString(), 10)].field === cell.getAttribute('id').slice(this.parent.element.id.length)) {\n if (this.cellDetails.rowIndex === btmIdx && e.action === 'tab') {\n if (gObj.editSettings.newRowPosition === 'Top') {\n gObj.editSettings.newRowPosition = 'Bottom';\n this.addRecord();\n gObj.editSettings.newRowPosition = 'Top';\n }\n else {\n this.addRecord();\n }\n this.addBatchRow = false;\n }\n else {\n this.saveCell();\n }\n }\n }\n }\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n BatchEdit.prototype.addCancelWhilePaging = function () {\n if (this.validateFormObj()) {\n this.parent.notify(events.destroyForm, {});\n this.parent.isEdit = false;\n this.editNext = false;\n this.mouseDownElement = undefined;\n this.isColored = false;\n }\n };\n BatchEdit.prototype.getBottomIndex = function () {\n var changes = this.getBatchChanges();\n return this.parent.getCurrentViewRecords().length + changes[literals.addedRecords].length -\n changes[literals.deletedRecords].length - 1;\n };\n return BatchEdit;\n}());\nexport { BatchEdit };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { NormalEdit } from './normal-edit';\n/**\n * `DialogEdit` module is used to handle dialog editing actions.\n *\n * @hidden\n */\nvar DialogEdit = /** @class */ (function (_super) {\n __extends(DialogEdit, _super);\n function DialogEdit(parent, serviceLocator, renderer) {\n var _this = \n //constructor\n _super.call(this, parent, serviceLocator) || this;\n _this.parent = parent;\n _this.serviceLocator = serviceLocator;\n _this.renderer = renderer;\n return _this;\n }\n DialogEdit.prototype.closeEdit = function () {\n //closeEdit\n _super.prototype.closeEdit.call(this);\n };\n DialogEdit.prototype.addRecord = function (data, index) {\n //addRecord\n _super.prototype.addRecord.call(this, data, index);\n };\n DialogEdit.prototype.endEdit = function () {\n //endEdit\n _super.prototype.endEdit.call(this);\n };\n DialogEdit.prototype.updateRow = function (index, data) {\n _super.prototype.updateRow.call(this, index, data);\n };\n DialogEdit.prototype.deleteRecord = function (fieldname, data) {\n //deleteRecord\n _super.prototype.deleteRecord.call(this, fieldname, data);\n };\n DialogEdit.prototype.startEdit = function (tr) {\n _super.prototype.startEdit.call(this, tr);\n };\n return DialogEdit;\n}(NormalEdit));\nexport { DialogEdit };\n","import { L10n, getValue, getDefaultDateObject, cldrData } from '@syncfusion/ej2-base';\nvar ARROWLEFT = 'ArrowLeft';\nvar ARROWRIGHT = 'ArrowRight';\nvar ARROWUP = 'ArrowUp';\nvar ARROWDOWN = 'ArrowDown';\nvar TAB = 'Tab';\nvar SHIFTTAB = 'shiftTab';\nvar END = 'End';\nvar HOME = 'Home';\nvar MaskedDateTime = /** @class */ (function () {\n function MaskedDateTime(parent) {\n this.mask = '';\n this.defaultConstant = {\n day: 'day',\n month: 'month',\n year: 'year',\n hour: 'hour',\n minute: 'minute',\n second: 'second',\n dayOfTheWeek: 'day of the week'\n };\n this.hiddenMask = '';\n this.validCharacters = 'dMyhmHfasz';\n this.isDayPart = false;\n this.isMonthPart = false;\n this.isYearPart = false;\n this.isHourPart = false;\n this.isMinutePart = false;\n this.isSecondsPart = false;\n this.isMilliSecondsPart = false;\n this.monthCharacter = '';\n this.periodCharacter = '';\n this.isHiddenMask = false;\n this.isComplete = false;\n this.isNavigate = false;\n this.navigated = false;\n this.isBlur = false;\n this.formatRegex = /EEEEE|EEEE|EEE|EE|E|dddd|ddd|dd|d|MMMM|MMM|MM|M|yyyy|yy|y|HH|H|hh|h|mm|m|fff|ff|f|aa|a|ss|s|zzzz|zzz|zz|z|'[^']*'|'[^']*'/g;\n this.isDeletion = false;\n this.isShortYear = false;\n this.isDeleteKey = false;\n this.isDateZero = false;\n this.isMonthZero = false;\n this.isYearZero = false;\n this.isLeadingZero = false;\n this.dayTypeCount = 0;\n this.monthTypeCount = 0;\n this.hourTypeCount = 0;\n this.minuteTypeCount = 0;\n this.secondTypeCount = 0;\n this.parent = parent;\n this.dateformat = this.getCulturedFormat();\n this.maskDateValue = this.parent.value != null ? new Date(+this.parent.value) : new Date();\n this.maskDateValue.setMonth(0);\n this.maskDateValue.setHours(0);\n this.maskDateValue.setMinutes(0);\n this.maskDateValue.setSeconds(0);\n this.previousDate = new Date(this.maskDateValue.getFullYear(), this.maskDateValue.getMonth(), this.maskDateValue.getDate(), this.maskDateValue.getHours(), this.maskDateValue.getMinutes(), this.maskDateValue.getSeconds());\n this.removeEventListener();\n this.addEventListener();\n }\n MaskedDateTime.prototype.getModuleName = function () {\n return 'MaskedDateTime';\n };\n MaskedDateTime.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on('createMask', this.createMask, this);\n this.parent.on('setMaskSelection', this.validCharacterCheck, this);\n this.parent.on('inputHandler', this.maskInputHandler, this);\n this.parent.on('keyDownHandler', this.maskKeydownHandler, this);\n this.parent.on('clearHandler', this.clearHandler, this);\n };\n MaskedDateTime.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off('createMask', this.createMask);\n this.parent.off('setMaskSelection', this.validCharacterCheck);\n this.parent.off('inputHandler', this.maskInputHandler);\n this.parent.off('keyDownHandler', this.maskKeydownHandler);\n this.parent.off('clearHandler', this.clearHandler);\n };\n MaskedDateTime.prototype.createMask = function (mask) {\n this.isDayPart = this.isMonthPart = this.isYearPart = this.isHourPart = this.isMinutePart = this.isSecondsPart = false;\n this.dateformat = this.getCulturedFormat();\n if (this.parent.maskPlaceholder.day) {\n this.defaultConstant['day'] = this.parent.maskPlaceholder.day;\n }\n if (this.parent.maskPlaceholder.month) {\n this.defaultConstant['month'] = this.parent.maskPlaceholder.month;\n }\n if (this.parent.maskPlaceholder.year) {\n this.defaultConstant['year'] = this.parent.maskPlaceholder.year;\n }\n if (this.parent.maskPlaceholder.hour) {\n this.defaultConstant['hour'] = this.parent.maskPlaceholder.hour;\n }\n if (this.parent.maskPlaceholder.minute) {\n this.defaultConstant['minute'] = this.parent.maskPlaceholder.minute;\n }\n if (this.parent.maskPlaceholder.second) {\n this.defaultConstant['second'] = this.parent.maskPlaceholder.second;\n }\n if (this.parent.maskPlaceholder.dayOfTheWeek) {\n this.defaultConstant['dayOfTheWeek'] = this.parent.maskPlaceholder.dayOfTheWeek.toString();\n }\n this.getCUltureMaskFormat();\n var inputValue = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isHiddenMask = true;\n this.hiddenMask = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isHiddenMask = false;\n this.previousHiddenMask = this.hiddenMask;\n this.mask = this.previousValue = inputValue;\n this.parent.maskedDateValue = this.mask;\n if (this.parent.value) {\n this.navigated = true;\n this.isBlur = mask.isBlur;\n this.setDynamicValue();\n }\n };\n MaskedDateTime.prototype.getCUltureMaskFormat = function () {\n this.l10n = new L10n(this.parent.moduleName, this.defaultConstant, this.parent.locale);\n this.objectString = Object.keys(this.defaultConstant);\n for (var i = 0; i < this.objectString.length; i++) {\n this.defaultConstant[this.objectString[i].toString()] =\n this.l10n.getConstant(this.objectString[i].toString());\n }\n };\n MaskedDateTime.prototype.validCharacterCheck = function () {\n var start = this.parent.inputElement.selectionStart;\n if (this.parent.moduleName !== 'timepicker') {\n if (start === this.hiddenMask.length && this.mask === this.parent.inputElement.value) {\n start = 0;\n }\n }\n for (var i = start, j = start - 1; i < this.hiddenMask.length || j >= 0; i++, j--) {\n if (i < this.hiddenMask.length && this.validCharacters.indexOf(this.hiddenMask[i]) !== -1) {\n this.setSelection(this.hiddenMask[i]);\n return;\n }\n if (j >= 0 && this.validCharacters.indexOf(this.hiddenMask[j]) !== -1) {\n this.setSelection(this.hiddenMask[j]);\n return;\n }\n }\n };\n MaskedDateTime.prototype.setDynamicValue = function () {\n this.maskDateValue = new Date(+this.parent.value);\n this.isDayPart = this.isMonthPart = this.isYearPart = this.isHourPart = this.isMinutePart = this.isSecondsPart = true;\n this.updateValue();\n if (!this.isBlur) {\n this.validCharacterCheck();\n }\n };\n MaskedDateTime.prototype.setSelection = function (validChar) {\n var start = -1;\n var end = 0;\n for (var i = 0; i < this.hiddenMask.length; i++) {\n if (this.hiddenMask[i] === validChar) {\n end = i + 1;\n if (start === -1) {\n start = i;\n }\n }\n }\n if (start < 0) {\n start = 0;\n }\n this.parent.inputElement.setSelectionRange(start, end);\n };\n MaskedDateTime.prototype.maskKeydownHandler = function (args) {\n this.dayTypeCount = this.monthTypeCount = this.hourTypeCount = this.minuteTypeCount = this.secondTypeCount = 0;\n if (args.e.key === 'Delete') {\n this.isDeleteKey = true;\n return;\n }\n if ((!args.e.altKey && !args.e.ctrlKey) && (args.e.key === ARROWLEFT || args.e.key === ARROWRIGHT\n || args.e.key === SHIFTTAB || args.e.key === TAB || args.e.action === SHIFTTAB ||\n args.e.key === END || args.e.key === HOME)) {\n var start = this.parent.inputElement.selectionStart;\n var end = this.parent.inputElement.selectionEnd;\n var length_1 = this.parent.inputElement.value.length;\n if ((start === 0 && end === length_1) && (args.e.key === TAB || args.e.action === SHIFTTAB)) {\n var index = args.e.action === SHIFTTAB ? end : 0;\n this.parent.inputElement.selectionStart = this.parent.inputElement.selectionEnd = index;\n }\n if (args.e.key === END || args.e.key === HOME) {\n var range = args.e.key === END ? length_1 : 0;\n this.parent.inputElement.selectionStart = this.parent.inputElement.selectionEnd = range;\n }\n this.navigateSelection(args.e.key === ARROWLEFT || args.e.action === SHIFTTAB || args.e.key === END ? true : false);\n }\n if ((!args.e.altKey && !args.e.ctrlKey) && (args.e.key === ARROWUP || args.e.key === ARROWDOWN)) {\n var start = this.parent.inputElement.selectionStart;\n var formatText = '';\n if (this.validCharacters.indexOf(this.hiddenMask[start]) !== -1) {\n formatText = this.hiddenMask[start];\n }\n this.dateAlteration(args.e.key === ARROWDOWN ? true : false);\n var inputValue = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isHiddenMask = true;\n this.hiddenMask = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isHiddenMask = false;\n this.previousHiddenMask = this.hiddenMask;\n this.previousValue = inputValue;\n this.parent.inputElement.value = inputValue;\n for (var i = 0; i < this.hiddenMask.length; i++) {\n if (formatText === this.hiddenMask[i]) {\n start = i;\n break;\n }\n }\n this.parent.inputElement.selectionStart = start;\n this.validCharacterCheck();\n }\n };\n MaskedDateTime.prototype.isPersist = function () {\n var isPersist = this.parent.isFocused || this.navigated;\n return isPersist;\n };\n MaskedDateTime.prototype.differenceCheck = function () {\n var start = this.parent.inputElement.selectionStart;\n var inputValue = this.parent.inputElement.value;\n var previousVal = this.previousValue.substring(0, start + this.previousValue.length - inputValue.length);\n var newVal = inputValue.substring(0, start);\n var newDateValue = new Date(+this.maskDateValue);\n var maxDate = new Date(newDateValue.getFullYear(), newDateValue.getMonth() + 1, 0).getDate();\n if (previousVal.indexOf(newVal) === 0 && (newVal.length === 0 ||\n this.previousHiddenMask[newVal.length - 1] !== this.previousHiddenMask[newVal.length])) {\n for (var i = newVal.length; i < previousVal.length; i++) {\n if (this.previousHiddenMask[i] !== '' && this.validCharacters.indexOf(this.previousHiddenMask[i]) >= 0) {\n this.isDeletion = this.handleDeletion(this.previousHiddenMask[i], false);\n }\n }\n if (this.isDeletion) {\n return;\n }\n }\n switch (this.previousHiddenMask[start - 1]) {\n case 'd':\n {\n var date = (this.isDayPart && newDateValue.getDate().toString().length < 2 &&\n !this.isPersist() ? newDateValue.getDate() * 10 : 0) + parseInt(newVal[start - 1], 10);\n this.isDateZero = (newVal[start - 1] === '0');\n this.parent.isFocused = this.parent.isFocused ? false : this.parent.isFocused;\n this.navigated = this.navigated ? false : this.navigated;\n if (isNaN(date)) {\n return;\n }\n for (var i = 0; date > maxDate; i++) {\n date = parseInt(date.toString().slice(1), 10);\n }\n if (date >= 1) {\n newDateValue.setDate(date);\n this.isNavigate = date.toString().length === 2;\n this.previousDate = new Date(newDateValue.getFullYear(), newDateValue.getMonth(), newDateValue.getDate());\n if (newDateValue.getMonth() !== this.maskDateValue.getMonth()) {\n return;\n }\n this.isDayPart = true;\n this.dayTypeCount = this.dayTypeCount + 1;\n }\n else {\n this.isDayPart = false;\n this.dayTypeCount = this.isDateZero ? this.dayTypeCount + 1 : this.dayTypeCount;\n }\n break;\n }\n case 'M':\n {\n var month = void 0;\n if (newDateValue.getMonth().toString().length < 2 && !this.isPersist()) {\n month = (this.isMonthPart ? (newDateValue.getMonth() + 1) * 10 : 0) + parseInt(newVal[start - 1], 10);\n }\n else {\n month = parseInt(newVal[start - 1], 10);\n }\n this.parent.isFocused = this.parent.isFocused ? false : this.parent.isFocused;\n this.navigated = this.navigated ? false : this.navigated;\n this.isMonthZero = (newVal[start - 1] === '0');\n if (!isNaN(month)) {\n while (month > 12) {\n month = parseInt(month.toString().slice(1), 10);\n }\n if (month >= 1) {\n newDateValue.setMonth(month - 1);\n if (month >= 10 || month == 1) {\n if (this.isLeadingZero && month == 1) {\n this.isNavigate = month.toString().length === 1;\n this.isLeadingZero = false;\n }\n else {\n this.isNavigate = month.toString().length === 2;\n }\n }\n else {\n this.isNavigate = month.toString().length === 1;\n }\n if (newDateValue.getMonth() !== month - 1) {\n newDateValue.setDate(1);\n newDateValue.setMonth(month - 1);\n }\n if (this.isDayPart) {\n var previousMaxDate = new Date(this.previousDate.getFullYear(), this.previousDate.getMonth() + 1, 0).getDate();\n var currentMaxDate = new Date(newDateValue.getFullYear(), newDateValue.getMonth() + 1, 0).getDate();\n if (this.previousDate.getDate() === previousMaxDate && currentMaxDate <= previousMaxDate) {\n newDateValue.setDate(currentMaxDate);\n }\n }\n this.previousDate = new Date(newDateValue.getFullYear(), newDateValue.getMonth(), newDateValue.getDate());\n this.isMonthPart = true;\n this.monthTypeCount = this.monthTypeCount + 1;\n }\n else {\n newDateValue.setMonth(0);\n this.isLeadingZero = true;\n this.isMonthPart = false;\n this.monthTypeCount = this.isMonthZero ? this.monthTypeCount + 1 : this.monthTypeCount;\n }\n }\n else {\n var monthString = (this.getCulturedValue('months[stand-alone].wide'));\n var monthValue = Object.keys(monthString);\n this.monthCharacter += newVal[start - 1].toLowerCase();\n while (this.monthCharacter.length > 0) {\n var i = 1;\n for (var _i = 0, monthValue_1 = monthValue; _i < monthValue_1.length; _i++) {\n var months = monthValue_1[_i];\n if (monthString[i].toLowerCase().indexOf(this.monthCharacter) === 0) {\n newDateValue.setMonth(i - 1);\n this.isMonthPart = true;\n this.maskDateValue = newDateValue;\n return;\n }\n i++;\n }\n this.monthCharacter = this.monthCharacter.substring(1, this.monthCharacter.length);\n }\n }\n break;\n }\n case 'y':\n {\n var year = (this.isYearPart && (newDateValue.getFullYear().toString().length < 4\n && !this.isShortYear) ? newDateValue.getFullYear() * 10 : 0) + parseInt(newVal[start - 1], 10);\n var yearValue = (this.dateformat.match(/y/g) || []).length;\n this.isShortYear = false;\n this.isYearZero = (newVal[start - 1] === '0');\n if (isNaN(year)) {\n return;\n }\n while (year > 9999) {\n year = parseInt(year.toString().slice(1), 10);\n }\n if (year < 1) {\n this.isYearPart = false;\n }\n else {\n newDateValue.setFullYear(year);\n if (year.toString().length === yearValue) {\n this.isNavigate = true;\n }\n this.previousDate = new Date(newDateValue.getFullYear(), newDateValue.getMonth(), newDateValue.getDate());\n this.isYearPart = true;\n }\n break;\n }\n case 'h':\n this.hour = (this.isHourPart && (newDateValue.getHours() % 12 || 12).toString().length < 2\n && !this.isPersist() ? (newDateValue.getHours() % 12 || 12) * 10 : 0) + parseInt(newVal[start - 1], 10);\n this.parent.isFocused = this.parent.isFocused ? false : this.parent.isFocused;\n this.navigated = this.navigated ? false : this.navigated;\n if (isNaN(this.hour)) {\n return;\n }\n while (this.hour > 12) {\n this.hour = parseInt(this.hour.toString().slice(1), 10);\n }\n newDateValue.setHours(Math.floor(newDateValue.getHours() / 12) * 12 + (this.hour % 12));\n this.isNavigate = this.hour.toString().length === 2;\n this.isHourPart = true;\n this.hourTypeCount = this.hourTypeCount + 1;\n break;\n case 'H':\n this.hour = (this.isHourPart && newDateValue.getHours().toString().length < 2 &&\n !this.isPersist() ? newDateValue.getHours() * 10 : 0) + parseInt(newVal[start - 1], 10);\n this.parent.isFocused = this.parent.isFocused ? false : this.parent.isFocused;\n this.navigated = this.navigated ? false : this.navigated;\n if (isNaN(this.hour)) {\n return;\n }\n for (var i = 0; this.hour > 23; i++) {\n this.hour = parseInt(this.hour.toString().slice(1), 10);\n }\n newDateValue.setHours(this.hour);\n this.isNavigate = this.hour.toString().length === 2;\n this.isHourPart = true;\n this.hourTypeCount = this.hourTypeCount + 1;\n break;\n case 'm':\n {\n var minutes = (this.isMinutePart && newDateValue.getMinutes().toString().length < 2\n && !this.isPersist() ? newDateValue.getMinutes() * 10 : 0) + parseInt(newVal[start - 1], 10);\n this.parent.isFocused = this.parent.isFocused ? false : this.parent.isFocused;\n this.navigated = this.navigated ? false : this.navigated;\n if (isNaN(minutes)) {\n return;\n }\n for (var i = 0; minutes > 59; i++) {\n minutes = parseInt(minutes.toString().slice(1), 10);\n }\n newDateValue.setMinutes(minutes);\n this.isNavigate = minutes.toString().length === 2;\n this.isMinutePart = true;\n this.minuteTypeCount = this.minuteTypeCount + 1;\n break;\n }\n case 's':\n {\n var seconds = (this.isSecondsPart && newDateValue.getSeconds().toString().length < 2 &&\n !this.isPersist() ? newDateValue.getSeconds() * 10 : 0) + parseInt(newVal[start - 1], 10);\n this.parent.isFocused = this.parent.isFocused ? false : this.parent.isFocused;\n this.navigated = this.navigated ? false : this.navigated;\n if (isNaN(seconds)) {\n return;\n }\n for (var i = 0; seconds > 59; i++) {\n seconds = parseInt(seconds.toString().slice(1), 10);\n }\n newDateValue.setSeconds(seconds);\n this.isNavigate = seconds.toString().length === 2;\n this.isSecondsPart = true;\n this.secondTypeCount = this.secondTypeCount + 1;\n break;\n }\n case 'a':\n {\n this.periodCharacter += newVal[start - 1].toLowerCase();\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var periodString = (this.getCulturedValue('dayPeriods.format.wide'));\n var periodkeys = Object.keys(periodString);\n for (var i = 0; this.periodCharacter.length > 0; i++) {\n if ((periodString[periodkeys[0]].toLowerCase().indexOf(this.periodCharacter) === 0\n && newDateValue.getHours() >= 12) || (periodString[periodkeys[1]].toLowerCase().\n indexOf(this.periodCharacter) === 0 && newDateValue.getHours() < 12)) {\n newDateValue.setHours((newDateValue.getHours() + 12) % 24);\n this.maskDateValue = newDateValue;\n }\n this.periodCharacter = this.periodCharacter.substring(1, this.periodCharacter.length);\n }\n break;\n }\n default:\n break;\n }\n this.maskDateValue = newDateValue;\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n MaskedDateTime.prototype.formatCheck = function () {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var proxy = this;\n function formatValueSpecifier(formattext) {\n var result;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var daysAbbreviated = proxy.getCulturedValue('days[stand-alone].abbreviated');\n var dayKeyAbbreviated = Object.keys(daysAbbreviated);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var daysWide = (proxy.getCulturedValue('days[stand-alone].wide'));\n var dayKeyWide = Object.keys(daysWide);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var daysNarrow = (proxy.getCulturedValue('days[stand-alone].narrow'));\n var dayKeyNarrow = Object.keys(daysNarrow);\n var monthAbbreviated = (proxy.getCulturedValue('months[stand-alone].abbreviated'));\n var monthWide = (proxy.getCulturedValue('months[stand-alone].wide'));\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var periodString = (proxy.getCulturedValue('dayPeriods.format.wide'));\n var periodkeys = Object.keys(periodString);\n var milliseconds;\n var dateOptions;\n switch (formattext) {\n case 'ddd':\n case 'dddd':\n case 'd':\n result = proxy.isDayPart ? proxy.maskDateValue.getDate().toString() : proxy.defaultConstant['day'].toString();\n result = proxy.zeroCheck(proxy.isDateZero, proxy.isDayPart, result);\n if (proxy.dayTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.dayTypeCount = 0;\n }\n break;\n case 'dd':\n result = proxy.isDayPart ? proxy.roundOff(proxy.maskDateValue.getDate(), 2) : proxy.defaultConstant['day'].toString();\n result = proxy.zeroCheck(proxy.isDateZero, proxy.isDayPart, result);\n if (proxy.dayTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.dayTypeCount = 0;\n }\n break;\n case 'E':\n case 'EE':\n case 'EEE':\n result = proxy.isDayPart && proxy.isMonthPart && proxy.isYearPart ? daysAbbreviated[dayKeyAbbreviated[proxy.maskDateValue.getDay()]].toString() : proxy.defaultConstant['dayOfTheWeek'].toString();\n break;\n case 'EEEE':\n result = proxy.isDayPart && proxy.isMonthPart && proxy.isYearPart ? daysWide[dayKeyWide[proxy.maskDateValue.getDay()]].toString() : proxy.defaultConstant['dayOfTheWeek'].toString();\n break;\n case 'EEEEE':\n result = proxy.isDayPart && proxy.isMonthPart && proxy.isYearPart ? daysNarrow[dayKeyNarrow[proxy.maskDateValue.getDay()]].toString() : proxy.defaultConstant['dayOfTheWeek'].toString();\n break;\n case 'M':\n result = proxy.isMonthPart ? (proxy.maskDateValue.getMonth() + 1).toString() : proxy.defaultConstant['month'].toString();\n result = proxy.zeroCheck(proxy.isMonthZero, proxy.isMonthPart, result);\n if (proxy.monthTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.monthTypeCount = 0;\n }\n break;\n case 'MM':\n result = proxy.isMonthPart ? proxy.roundOff(proxy.maskDateValue.getMonth() + 1, 2) : proxy.defaultConstant['month'].toString();\n result = proxy.zeroCheck(proxy.isMonthZero, proxy.isMonthPart, result);\n if (proxy.monthTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.monthTypeCount = 0;\n }\n break;\n case 'MMM':\n result = proxy.isMonthPart ? monthAbbreviated[proxy.maskDateValue.getMonth() + 1] : proxy.defaultConstant['month'].toString();\n break;\n case 'MMMM':\n result = proxy.isMonthPart ? monthWide[proxy.maskDateValue.getMonth() + 1] : proxy.defaultConstant['month'].toString();\n break;\n case 'yy':\n result = proxy.isYearPart ? proxy.roundOff(proxy.maskDateValue.getFullYear() % 100, 2) : proxy.defaultConstant['year'].toString();\n result = proxy.zeroCheck(proxy.isYearZero, proxy.isYearPart, result);\n break;\n case 'y':\n case 'yyyy':\n result = proxy.isYearPart ? proxy.roundOff(proxy.maskDateValue.getFullYear(), 4) : proxy.defaultConstant['year'].toString();\n result = proxy.zeroCheck(proxy.isYearZero, proxy.isYearPart, result);\n break;\n case 'h':\n result = proxy.isHourPart ? (proxy.maskDateValue.getHours() % 12 || 12).toString() : proxy.defaultConstant['hour'].toString();\n if (proxy.hourTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.hourTypeCount = 0;\n }\n break;\n case 'hh':\n result = proxy.isHourPart ? proxy.roundOff(proxy.maskDateValue.getHours() % 12 || 12, 2) : proxy.defaultConstant['hour'].toString();\n if (proxy.hourTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.hourTypeCount = 0;\n }\n break;\n case 'H':\n result = proxy.isHourPart ? proxy.maskDateValue.getHours().toString() : proxy.defaultConstant['hour'].toString();\n if (proxy.hourTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.hourTypeCount = 0;\n }\n break;\n case 'HH':\n result = proxy.isHourPart ? proxy.roundOff(proxy.maskDateValue.getHours(), 2) : proxy.defaultConstant['hour'].toString();\n if (proxy.hourTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.hourTypeCount = 0;\n }\n break;\n case 'm':\n result = proxy.isMinutePart ? proxy.maskDateValue.getMinutes().toString() : proxy.defaultConstant['minute'].toString();\n if (proxy.minuteTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.minuteTypeCount = 0;\n }\n break;\n case 'mm':\n result = proxy.isMinutePart ? proxy.roundOff(proxy.maskDateValue.getMinutes(), 2) : proxy.defaultConstant['minute'].toString();\n if (proxy.minuteTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.minuteTypeCount = 0;\n }\n break;\n case 's':\n result = proxy.isSecondsPart ? proxy.maskDateValue.getSeconds().toString() : proxy.defaultConstant['second'].toString();\n if (proxy.secondTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.secondTypeCount = 0;\n }\n break;\n case 'ss':\n result = proxy.isSecondsPart ? proxy.roundOff(proxy.maskDateValue.getSeconds(), 2) : proxy.defaultConstant['second'].toString();\n if (proxy.secondTypeCount === 2) {\n proxy.isNavigate = true;\n proxy.secondTypeCount = 0;\n }\n break;\n case 'f':\n result = Math.floor(proxy.maskDateValue.getMilliseconds() / 100).toString();\n break;\n case 'ff':\n milliseconds = proxy.maskDateValue.getMilliseconds();\n if (proxy.maskDateValue.getMilliseconds() > 99) {\n milliseconds = Math.floor(proxy.maskDateValue.getMilliseconds() / 10);\n }\n result = proxy.roundOff(milliseconds, 2);\n break;\n case 'fff':\n result = proxy.roundOff(proxy.maskDateValue.getMilliseconds(), 3);\n break;\n case 'a':\n case 'aa':\n result = proxy.maskDateValue.getHours() < 12 ? periodString[periodkeys[0]] : periodString[periodkeys[1]];\n break;\n case 'z':\n case 'zz':\n case 'zzz':\n case 'zzzz':\n dateOptions = {\n format: formattext,\n type: 'dateTime', skeleton: 'yMd', calendar: proxy.parent.calendarMode\n };\n result = proxy.parent.globalize.formatDate(proxy.maskDateValue, dateOptions);\n break;\n }\n result = result !== undefined ? result : formattext.slice(1, formattext.length - 1);\n if (proxy.isHiddenMask) {\n var hiddenChar = '';\n for (var i = 0; i < result.length; i++) {\n hiddenChar += formattext[0];\n }\n return hiddenChar;\n }\n else {\n return result;\n }\n }\n return formatValueSpecifier;\n };\n MaskedDateTime.prototype.maskInputHandler = function () {\n var start = this.parent.inputElement.selectionStart;\n var formatText = '';\n if (this.validCharacters.indexOf(this.hiddenMask[start]) !== -1) {\n formatText = this.hiddenMask[start];\n }\n this.differenceCheck();\n var inputValue = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isHiddenMask = true;\n this.hiddenMask = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isDateZero = this.isMonthZero = this.isYearZero = false;\n this.isHiddenMask = false;\n this.previousHiddenMask = this.hiddenMask;\n this.previousValue = inputValue;\n this.parent.inputElement.value = inputValue;\n this.parent.inputElement.value = inputValue;\n for (var i = 0; i < this.hiddenMask.length; i++) {\n if (formatText === this.hiddenMask[i]) {\n start = i;\n break;\n }\n }\n this.parent.inputElement.selectionStart = start;\n this.validCharacterCheck();\n if ((this.isNavigate || this.isDeletion) && !this.isDeleteKey) {\n var isbackward = this.isNavigate ? false : true;\n this.isNavigate = this.isDeletion = false;\n this.navigateSelection(isbackward);\n }\n if (this.isDeleteKey) {\n this.isDeletion = false;\n }\n this.isDeleteKey = false;\n };\n MaskedDateTime.prototype.navigateSelection = function (isbackward) {\n var start = this.parent.inputElement.selectionStart;\n var end = this.parent.inputElement.selectionEnd;\n var formatIndex = isbackward ? start - 1 : end;\n this.navigated = true;\n while (formatIndex < this.hiddenMask.length && formatIndex >= 0) {\n if (this.validCharacters.indexOf(this.hiddenMask[formatIndex]) >= 0) {\n this.setSelection(this.hiddenMask[formatIndex]);\n break;\n }\n formatIndex = formatIndex + (isbackward ? -1 : 1);\n }\n };\n MaskedDateTime.prototype.roundOff = function (val, count) {\n var valueText = val.toString();\n var length = count - valueText.length;\n var result = '';\n for (var i = 0; i < length; i++) {\n result += '0';\n }\n return result + valueText;\n };\n MaskedDateTime.prototype.zeroCheck = function (isZero, isDayPart, resultValue) {\n var result = resultValue;\n if (isZero && !isDayPart) {\n result = '0';\n }\n return result;\n };\n MaskedDateTime.prototype.handleDeletion = function (format, isSegment) {\n switch (format) {\n case 'd':\n this.isDayPart = isSegment;\n break;\n case 'M':\n this.isMonthPart = isSegment;\n if (!isSegment) {\n this.maskDateValue.setMonth(0);\n this.monthCharacter = '';\n }\n break;\n case 'y':\n this.isYearPart = isSegment;\n break;\n case 'H':\n case 'h':\n this.isHourPart = isSegment;\n if (!isSegment) {\n this.periodCharacter = '';\n }\n break;\n case 'm':\n this.isMinutePart = isSegment;\n break;\n case 's':\n this.isSecondsPart = isSegment;\n break;\n default:\n return false;\n }\n return true;\n };\n MaskedDateTime.prototype.dateAlteration = function (isDecrement) {\n var start = this.parent.inputElement.selectionStart;\n var formatText = '';\n if (this.validCharacters.indexOf(this.hiddenMask[start]) !== -1) {\n formatText = this.hiddenMask[start];\n }\n else {\n return;\n }\n var newDateValue = new Date(this.maskDateValue.getFullYear(), this.maskDateValue.getMonth(), this.maskDateValue.getDate(), this.maskDateValue.getHours(), this.maskDateValue.getMinutes(), this.maskDateValue.getSeconds());\n this.previousDate = new Date(this.maskDateValue.getFullYear(), this.maskDateValue.getMonth(), this.maskDateValue.getDate(), this.maskDateValue.getHours(), this.maskDateValue.getMinutes(), this.maskDateValue.getSeconds());\n var incrementValue = isDecrement ? -1 : 1;\n switch (formatText) {\n case 'd':\n newDateValue.setDate(newDateValue.getDate() + incrementValue);\n break;\n case 'M':\n {\n var newMonth = newDateValue.getMonth() + incrementValue;\n newDateValue.setDate(1);\n newDateValue.setMonth(newMonth);\n if (this.isDayPart) {\n var previousMaxDate = new Date(this.previousDate.getFullYear(), this.previousDate.getMonth() + 1, 0).getDate();\n var currentMaxDate = new Date(newDateValue.getFullYear(), newDateValue.getMonth() + 1, 0).getDate();\n if (this.previousDate.getDate() === previousMaxDate && currentMaxDate <= previousMaxDate) {\n newDateValue.setDate(currentMaxDate);\n }\n else {\n newDateValue.setDate(this.previousDate.getDate());\n }\n }\n else {\n newDateValue.setDate(this.previousDate.getDate());\n }\n this.previousDate = new Date(newDateValue.getFullYear(), newDateValue.getMonth(), newDateValue.getDate());\n break;\n }\n case 'y':\n newDateValue.setFullYear(newDateValue.getFullYear() + incrementValue);\n break;\n case 'H':\n case 'h':\n newDateValue.setHours(newDateValue.getHours() + incrementValue);\n break;\n case 'm':\n newDateValue.setMinutes(newDateValue.getMinutes() + incrementValue);\n break;\n case 's':\n newDateValue.setSeconds(newDateValue.getSeconds() + incrementValue);\n break;\n case 'a':\n newDateValue.setHours((newDateValue.getHours() + 12) % 24);\n break;\n default:\n break;\n }\n this.maskDateValue = newDateValue.getFullYear() > 0 ? newDateValue : this.maskDateValue;\n if (this.validCharacters.indexOf(this.hiddenMask[start]) !== -1) {\n this.handleDeletion(this.hiddenMask[start], true);\n }\n };\n MaskedDateTime.prototype.getCulturedValue = function (format) {\n var locale = this.parent.locale;\n var result;\n if (locale === 'en' || locale === 'en-US') {\n result = getValue(format, getDefaultDateObject());\n }\n else {\n result = getValue('main.' + '' + locale + ('.dates.calendars.gregorian.' + format), cldrData);\n }\n return result;\n };\n MaskedDateTime.prototype.getCulturedFormat = function () {\n var formatString = (this.getCulturedValue('dateTimeFormats[availableFormats].yMd')).toString();\n if (this.parent.moduleName === 'datepicker') {\n formatString = (this.getCulturedValue('dateTimeFormats[availableFormats].yMd')).toString();\n if (this.parent.format && this.parent.formatString) {\n formatString = this.parent.formatString;\n }\n }\n if (this.parent.moduleName === 'datetimepicker') {\n formatString = (this.getCulturedValue('dateTimeFormats[availableFormats].yMd')).toString();\n if (this.parent.dateTimeFormat) {\n formatString = this.parent.dateTimeFormat;\n }\n }\n if (this.parent.moduleName === 'timepicker') {\n formatString = this.parent.cldrTimeFormat();\n }\n return formatString;\n };\n MaskedDateTime.prototype.clearHandler = function () {\n this.isDayPart = this.isMonthPart = this.isYearPart = this.isHourPart = this.isMinutePart = this.isSecondsPart = false;\n this.updateValue();\n };\n MaskedDateTime.prototype.updateValue = function () {\n this.monthCharacter = this.periodCharacter = '';\n var inputValue = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isHiddenMask = true;\n this.hiddenMask = this.dateformat.replace(this.formatRegex, this.formatCheck());\n this.isHiddenMask = false;\n this.previousHiddenMask = this.hiddenMask;\n this.previousValue = inputValue;\n this.parent.updateInputValue(inputValue);\n };\n MaskedDateTime.prototype.destroy = function () {\n this.removeEventListener();\n };\n return MaskedDateTime;\n}());\nexport { MaskedDateTime };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { extend } from '@syncfusion/ej2-base';\nimport { DatePicker, DateTimePicker, MaskedDateTime } from '@syncfusion/ej2-calendars';\nimport { isEditable, getObject, getCustomDateFormat } from '../base/util';\nimport { EditCellBase } from './edit-cell-base';\nDatePicker.Inject(MaskedDateTime);\n/**\n * `DatePickerEditCell` is used to handle datepicker cell type editing.\n *\n * @hidden\n */\nvar DatePickerEditCell = /** @class */ (function (_super) {\n __extends(DatePickerEditCell, _super);\n function DatePickerEditCell() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n DatePickerEditCell.prototype.write = function (args) {\n this.edit = this.parent.editModule;\n if (args.column.editType === 'datepickeredit') {\n this.obj = new DatePicker(extend(dateanddatetimerender(args, this.parent.editSettings.mode, this.parent.enableRtl, this.parent.cssClass, this), args.column.edit.params));\n }\n else if (args.column.editType === 'datetimepickeredit') {\n this.obj = new DateTimePicker(extend(dateanddatetimerender(args, this.parent.editSettings.mode, this.parent.enableRtl, this.parent.cssClass, this), args.column.edit.params));\n }\n this.obj.appendTo(args.element);\n };\n return DatePickerEditCell;\n}(EditCellBase));\nexport { DatePickerEditCell };\n// eslint-disable-next-line\nfunction dateanddatetimerender(args, mode, rtl, css, datePickerEditCell) {\n var isInline = mode !== 'Dialog';\n var format = getCustomDateFormat(args.column.format, args.column.type);\n var value = getObject(args.column.field, args.rowData);\n value = value ? new Date(value) : null;\n return {\n floatLabelType: isInline ? 'Never' : 'Always',\n value: value,\n format: format,\n placeholder: isInline ?\n '' : args.column.headerText, enableRtl: rtl,\n enabled: isEditable(args.column, args.requestType, args.element),\n cssClass: css ? css : null,\n close: datePickerClose.bind(datePickerEditCell)\n };\n}\n// eslint-disable-next-line\nfunction datePickerClose(args) {\n if (args.event && args.event.action === 'escape') {\n this.edit.editCellDialogClose = true;\n }\n}\n","/**\n * `TemplateEditCell` is used to handle template cell.\n *\n * @hidden\n */\nvar TemplateEditCell = /** @class */ (function () {\n function TemplateEditCell(parent) {\n this.parent = parent;\n }\n TemplateEditCell.prototype.read = function (element, value) {\n return value;\n };\n TemplateEditCell.prototype.write = function () {\n //\n };\n TemplateEditCell.prototype.destroy = function () {\n //\n };\n return TemplateEditCell;\n}());\nexport { TemplateEditCell };\n","import { closest, addClass, select } from '@syncfusion/ej2-base';\nimport { extend, getValue } from '@syncfusion/ej2-base';\nimport { remove } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport * as events from '../base/constant';\nimport { EditRender } from '../renderer/edit-renderer';\nimport { BooleanEditCell } from '../renderer/boolean-edit-cell';\nimport { DropDownEditCell } from '../renderer/dropdown-edit-cell';\nimport { NumericEditCell } from '../renderer/numeric-edit-cell';\nimport { DefaultEditCell } from '../renderer/default-edit-cell';\nimport { InlineEdit } from './inline-edit';\nimport { BatchEdit } from './batch-edit';\nimport { DialogEdit } from './dialog-edit';\nimport { Dialog } from '@syncfusion/ej2-popups';\nimport { parentsUntil, getComplexFieldID, getParsedFieldID, setComplexFieldID, getScrollBarWidth, setValidationRuels } from '../base/util';\nimport { FormValidator } from '@syncfusion/ej2-inputs';\nimport { DatePickerEditCell } from '../renderer/datepicker-edit-cell';\nimport { calculateRelativeBasedPosition } from '@syncfusion/ej2-popups';\nimport { TemplateEditCell } from '../renderer/template-edit-cell';\nimport { DataUtil } from '@syncfusion/ej2-data';\nimport { addRemoveEventListener, padZero } from '../base/util';\nimport * as literals from '../base/string-literals';\n/**\n * The `Edit` module is used to handle editing actions.\n */\nvar Edit = /** @class */ (function () {\n /**\n * Constructor for the Grid editing module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {ServiceLocator} serviceLocator - specifies the servicelocator\n * @hidden\n */\n function Edit(parent, serviceLocator) {\n this.editType = { 'Inline': InlineEdit, 'Normal': InlineEdit, 'Batch': BatchEdit, 'Dialog': DialogEdit };\n this.fieldname = '';\n this.data = {};\n /* @hidden */\n this.editCellDialogClose = false;\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.l10n = this.serviceLocator.getService('localization');\n this.addEventListener();\n this.updateEditObj();\n this.createAlertDlg();\n this.createConfirmDlg();\n }\n Edit.prototype.updateColTypeObj = function () {\n var cols = this.parent.columnModel;\n for (var i = 0; i < cols.length; i++) {\n if (this.parent.editSettings.template || cols[parseInt(i.toString(), 10)].editTemplate) {\n var templteCell = 'templateedit';\n cols[parseInt(i.toString(), 10)].edit = extend(new Edit.editCellType[\"\" + templteCell](this.parent), cols[parseInt(i.toString(), 10)].edit || {});\n }\n else {\n cols[parseInt(i.toString(), 10)].edit = extend(new Edit.editCellType[cols[parseInt(i.toString(), 10)].editType\n && Edit.editCellType[cols[parseInt(i.toString(), 10)].editType] ?\n cols[parseInt(i.toString(), 10)].editType : 'defaultedit'](this.parent, this.serviceLocator), cols[parseInt(i.toString(), 10)].edit || {});\n }\n }\n this.parent.log('primary_column_missing');\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Edit.prototype.getModuleName = function () {\n return 'edit';\n };\n /**\n * @param {NotifyArgs} e - specifies the notifyargs\n * @returns {void}\n * @hidden\n */\n Edit.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName()) {\n return;\n }\n var gObj = this.parent;\n for (var _i = 0, _a = Object.keys(e.properties); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'allowAdding':\n case 'allowDeleting':\n case 'allowEditing':\n if (gObj.editSettings.allowAdding || gObj.editSettings.allowEditing || gObj.editSettings.allowDeleting) {\n this.initialEnd();\n }\n break;\n case 'mode':\n this.updateEditObj();\n gObj.isEdit = false;\n gObj.refresh();\n break;\n }\n }\n };\n Edit.prototype.updateEditObj = function () {\n if (this.editModule) {\n this.editModule.destroy();\n }\n this.renderer = new EditRender(this.parent, this.serviceLocator);\n this.editModule = new this.editType[this.parent.editSettings.mode](this.parent, this.serviceLocator, this.renderer);\n };\n Edit.prototype.initialEnd = function () {\n this.updateColTypeObj();\n };\n /**\n * Edits any bound record in the Grid by TR element.\n *\n * @param {HTMLTableRowElement} tr - Defines the table row to be edited.\n * @returns {void}\n */\n Edit.prototype.startEdit = function (tr) {\n var gObj = this.parent;\n if (!gObj.editSettings.allowEditing || gObj.isEdit || gObj.editSettings.mode === 'Batch') {\n return;\n }\n this.parent.element.classList.add('e-editing');\n if (!gObj.getSelectedRows().length || isNullOrUndefined(this.parent.getRowByIndex(parseInt(this.parent.getSelectedRows()[0].getAttribute('data-rowindex'), 10)))) {\n if (!tr) {\n this.showDialog('EditOperationAlert', this.alertDObj);\n return;\n }\n }\n else if (!tr) {\n tr = gObj.getSelectedRows()[0];\n }\n if (this.parent.enableVirtualization && this.parent.editSettings.mode === 'Normal') {\n var idx = parseInt(tr.getAttribute('data-rowindex'), 10);\n tr = this.parent.getRowByIndex(idx);\n }\n var lastTr = gObj.getContent().querySelector('tr:last-child');\n var hdrTbody = gObj.getHeaderContent().querySelector('tbody');\n if (gObj.frozenRows && isNullOrUndefined(lastTr) && hdrTbody && hdrTbody.querySelector('tr:last-child')) {\n this.isLastRow = tr.rowIndex === parseInt(gObj.getHeaderContent().querySelector('tbody').querySelector('tr:last-child').getAttribute('data-rowindex'), 10);\n }\n else if (lastTr) {\n this.isLastRow = tr.rowIndex === lastTr.rowIndex;\n }\n if (tr.style.display === 'none') {\n return;\n }\n this.editModule.startEdit(tr);\n this.refreshToolbar();\n gObj.element.querySelector('.e-gridpopup').style.display = 'none';\n this.parent.notify('start-edit', {});\n };\n /**\n * @param {Element} tr - specifies the tr element\n * @param {object} args - specifies the object\n * @param {Element} args.row -specfifes the row\n * @param {string} args.requestType - specifies the request type\n * @returns {void}\n * @hidden\n */\n Edit.prototype.checkLastRow = function (tr, args) {\n var checkLastRow = this.isLastRow;\n if (this.parent.height !== 'auto' && this.parent.editSettings.newRowPosition === 'Bottom' && args && args.requestType === 'add' &&\n this.parent.getContent().firstElementChild.offsetHeight > this.parent.getContentTable().scrollHeight) {\n addClass([].slice.call(tr.getElementsByClassName(literals.rowCell)), 'e-lastrowadded');\n }\n else if (checkLastRow && tr && tr.classList) {\n addClass([].slice.call(tr.getElementsByClassName(literals.rowCell)), 'e-lastrowcell');\n }\n };\n /**\n * Cancels edited state.\n *\n * @returns {void}\n */\n Edit.prototype.closeEdit = function () {\n if (this.parent.editSettings.mode === 'Batch' && this.parent.editSettings.showConfirmDialog\n && this.parent.element.getElementsByClassName('e-updatedtd').length) {\n this.showDialog('CancelEdit', this.dialogObj);\n return;\n }\n this.parent.element.classList.remove('e-editing');\n this.editModule.closeEdit();\n this.refreshToolbar();\n this.parent.notify(events.closeEdit, {});\n };\n Edit.prototype.refreshToolbar = function () {\n this.parent.notify(events.toolbarRefresh, {});\n };\n /**\n * To adds a new row at the top with the given data. When data is not passed, it will add empty rows.\n * > `editSettings.allowEditing` should be true.\n *\n * @param {Object} data - Defines the new add record data.\n * @param {number} index - Defines the row index to be added\n * @returns {void}\n */\n Edit.prototype.addRecord = function (data, index) {\n if (!this.parent.editSettings.allowAdding) {\n return;\n }\n var args = { startEdit: true };\n if (!data) {\n this.parent.notify(events.virtualScrollAddActionBegin, args);\n }\n if (args.startEdit) {\n this.parent.element.classList.add('e-editing');\n this.editModule.addRecord(data, index);\n this.refreshToolbar();\n this.parent.notify('start-add', {});\n }\n };\n /**\n * Deletes a record with the given options. If fieldname and data are not given, the Grid will delete the selected record.\n * > `editSettings.allowDeleting` should be true.\n *\n * @param {string} fieldname - Defines the primary key field name of the column.\n * @param {Object} data - Defines the JSON data record to be deleted.\n * @returns {void}\n */\n Edit.prototype.deleteRecord = function (fieldname, data) {\n var gObj = this.parent;\n if (!gObj.editSettings.allowDeleting) {\n return;\n }\n if (!data) {\n if (!gObj.getSelectedRecords().length && isNullOrUndefined(gObj.commandDelIndex)) {\n this.showDialog('DeleteOperationAlert', this.alertDObj);\n return;\n }\n }\n if (gObj.editSettings.showDeleteConfirmDialog) {\n this.fieldname = fieldname;\n this.data = data;\n this.showDialog('ConfirmDelete', this.dialogObj);\n return;\n }\n this.editModule.deleteRecord(fieldname, data);\n };\n /**\n * Deletes a visible row by TR element.\n *\n * @param {HTMLTableRowElement} tr - Defines the table row element.\n * @returns {void}\n */\n Edit.prototype.deleteRow = function (tr) {\n this.deleteRowUid = tr.getAttribute('data-uid');\n var rowObj = this.parent.getRowObjectFromUID(this.deleteRowUid);\n if (!isNullOrUndefined(rowObj)) {\n this.deleteRecord(null, rowObj.data);\n }\n };\n /**\n * If Grid is in editable state, you can save a record by invoking endEdit.\n *\n * @returns {void}\n */\n Edit.prototype.endEdit = function () {\n if (this.parent.editSettings.mode === 'Batch' && this.parent.editSettings.showConfirmDialog &&\n (isNullOrUndefined(this.formObj) || this.formObj.validate())) {\n this.parent.editModule.saveCell();\n this.parent.notify(events.editNextValCell, {});\n if (isNullOrUndefined(this.formObj) || this.formObj.validate()) {\n this.showDialog('BatchSaveConfirm', this.dialogObj);\n return;\n }\n }\n this.endEditing();\n };\n /**\n * To update the specified cell by given value without changing into edited state.\n *\n * @param {number} rowIndex Defines the row index.\n * @param {string} field Defines the column field.\n * @param {string | number | boolean | Date} value - Defines the value to be changed.\n * @returns {void}\n */\n Edit.prototype.updateCell = function (rowIndex, field, value) {\n this.editModule.updateCell(rowIndex, field, value);\n };\n /**\n * To update the specified row by given values without changing into edited state.\n *\n * @param {number} index Defines the row index.\n * @param {Object} data Defines the data object to be updated.\n * @returns {void}\n */\n Edit.prototype.updateRow = function (index, data) {\n this.editModule.updateRow(index, data);\n };\n /**\n * Resets added, edited, and deleted records in the batch mode.\n *\n * @returns {void}\n */\n Edit.prototype.batchCancel = function () {\n this.closeEdit();\n };\n /**\n * Bulk saves added, edited, and deleted records in the batch mode.\n *\n * @returns {void}\n */\n Edit.prototype.batchSave = function () {\n this.endEdit();\n };\n /**\n * Changes a particular cell into edited state based on the row index and field name provided in the `batch` mode.\n *\n * @param {number} index - Defines row index to edit a particular cell.\n * @param {string} field - Defines the field name of the column to perform batch edit.\n * @returns {void}\n */\n Edit.prototype.editCell = function (index, field) {\n this.editModule.editCell(index, field);\n };\n /**\n * Checks the status of validation at the time of editing. If validation is passed, it returns true.\n *\n * @returns {boolean} returns whether the form is validated\n */\n Edit.prototype.editFormValidate = function () {\n var form1 = this.formObj ? this.formObj.validate() : true;\n var form2 = this.mFormObj ? this.mFormObj.validate() : true;\n var form3 = this.frFormObj ? this.frFormObj.validate() : true;\n return form1 && form2 && form3;\n };\n /**\n * Gets the added, edited,and deleted data before bulk save to the DataSource in batch mode.\n *\n * @returns {Object} returns the Object\n */\n Edit.prototype.getBatchChanges = function () {\n return this.editModule.getBatchChanges ? this.editModule.getBatchChanges() : {};\n };\n /**\n * Gets the current value of the edited component.\n *\n * @returns {Object} returns the Object\n */\n Edit.prototype.getCurrentEditCellData = function () {\n var obj = this.getCurrentEditedData(this.formObj.element, {});\n return obj[Object.keys(obj)[0]];\n };\n /**\n * Saves the cell that is currently edited. It does not save the value to the DataSource.\n *\n * @returns {void}\n */\n Edit.prototype.saveCell = function () {\n this.editModule.saveCell();\n };\n Edit.prototype.endEditing = function () {\n this.parent.element.classList.remove('e-editing');\n this.editModule.endEdit();\n this.refreshToolbar();\n };\n Edit.prototype.showDialog = function (content, obj) {\n obj.content = '<div>' + this.l10n.getConstant(content) + '</div>';\n obj.dataBind();\n obj.show();\n };\n Edit.prototype.getValueFromType = function (col, value) {\n var val = value;\n switch (col.type) {\n case 'number':\n val = !isNaN(parseFloat(value)) ? parseFloat(value) : null;\n break;\n case 'boolean':\n if (col.editType !== 'booleanedit') {\n val = value === this.l10n.getConstant('True') || value === true ? true : false;\n }\n break;\n case 'date':\n case 'datetime':\n if (col.editType !== 'datepickeredit' && col.editType !== 'datetimepickeredit'\n && value && value.length) {\n val = new Date(value);\n }\n else if (value === '') {\n val = null;\n }\n break;\n case 'dateonly':\n val = value && (value = new Date(value)) ?\n value.getFullYear() + '-' + padZero(value.getMonth() + 1) + '-' + padZero(value.getDate()) : null;\n break;\n }\n return val;\n };\n Edit.prototype.destroyToolTip = function () {\n var elements = [].slice.call(this.parent.element.getElementsByClassName('e-griderror'));\n for (var _i = 0, elements_1 = elements; _i < elements_1.length; _i++) {\n var elem = elements_1[_i];\n remove(elem);\n }\n this.parent.getContent().firstElementChild.style.position = 'relative';\n if (this.parent.isFrozenGrid()) {\n if (this.parent.element.querySelector('.e-gridheader')) {\n this.parent.element.querySelector('.e-gridheader').style.position = '';\n }\n this.parent.element.querySelector('.e-gridcontent').style.position = '';\n }\n };\n Edit.prototype.createConfirmDlg = function () {\n this.dialogObj = this.dlgWidget([\n {\n click: this.dlgOk.bind(this),\n buttonModel: { content: this.l10n.getConstant('OKButton'),\n cssClass: this.parent.cssClass ? 'e-primary' + ' ' + this.parent.cssClass : 'e-primary',\n isPrimary: true }\n },\n {\n click: this.dlgCancel.bind(this),\n buttonModel: { cssClass: this.parent.cssClass ? 'e-flat' + ' ' + this.parent.cssClass : 'e-flat',\n content: this.l10n.getConstant('CancelButton') }\n }\n ], 'EditConfirm');\n };\n Edit.prototype.createAlertDlg = function () {\n this.alertDObj = this.dlgWidget([\n {\n click: this.alertClick.bind(this),\n buttonModel: { content: this.l10n.getConstant('OKButton'),\n cssClass: this.parent.cssClass ? 'e-flat' + ' ' + this.parent.cssClass : 'e-flat',\n isPrimary: true }\n }\n ], 'EditAlert');\n };\n Edit.prototype.alertClick = function () {\n this.alertDObj.hide();\n };\n Edit.prototype.dlgWidget = function (btnOptions, name) {\n var div = this.parent.createElement('div', { id: this.parent.element.id + name });\n this.parent.element.appendChild(div);\n var options = {\n showCloseIcon: false,\n isModal: true,\n visible: false,\n closeOnEscape: true,\n target: this.parent.element,\n width: '320px',\n animationSettings: { effect: 'None' },\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n };\n options.buttons = btnOptions;\n var obj = new Dialog(options);\n var isStringTemplate = 'isStringTemplate';\n obj[\"\" + isStringTemplate] = true;\n obj.appendTo(div);\n return obj;\n };\n Edit.prototype.dlgCancel = function () {\n if (this.parent.pagerModule) {\n this.parent.pagerModule.isForceCancel = false;\n }\n this.parent.focusModule.clearIndicator();\n this.parent.focusModule.restoreFocus();\n this.dialogObj.hide();\n this.parent.notify('cancelcnfrmDlg', {});\n };\n Edit.prototype.dlgOk = function () {\n switch (this.dialogObj.element.querySelector('.e-dlg-content').firstElementChild.innerText) {\n case this.l10n.getConstant('ConfirmDelete'):\n this.editModule.deleteRecord(this.fieldname, this.data);\n break;\n case this.l10n.getConstant('CancelEdit'):\n this.editModule.closeEdit();\n break;\n case this.l10n.getConstant('BatchSaveConfirm'):\n this.endEditing();\n break;\n case this.l10n.getConstant('BatchSaveLostChanges'):\n if (this.parent.editSettings.mode === 'Batch') {\n this.editModule.addCancelWhilePaging();\n }\n if (this.parent.pagerModule) {\n this.parent.pagerModule.isForceCancel = false;\n }\n this.executeAction();\n break;\n }\n this.dlgCancel();\n };\n Edit.prototype.destroyEditComponents = function () {\n if (this.parent.isEdit) {\n this.destroyWidgets();\n this.destroyForm();\n }\n this.destroy();\n };\n /**\n * @returns {void}\n * @hidden\n */\n Edit.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.eventDetails = [{ event: events.inBoundModelChanged, handler: this.onPropertyChanged },\n { event: events.initialEnd, handler: this.initialEnd },\n { event: events.keyPressed, handler: this.keyPressHandler },\n { event: events.autoCol, handler: this.updateColTypeObj },\n { event: events.tooltipDestroy, handler: this.destroyToolTip },\n { event: events.preventBatch, handler: this.preventBatch },\n { event: events.destroyForm, handler: this.destroyForm },\n { event: events.destroy, handler: this.destroyEditComponents }];\n addRemoveEventListener(this.parent, this.eventDetails, true, this);\n this.actionBeginFunction = this.onActionBegin.bind(this);\n this.actionCompleteFunction = this.actionComplete.bind(this);\n this.parent.addEventListener(events.actionBegin, this.actionBeginFunction);\n this.parent.addEventListener(events.actionComplete, this.actionCompleteFunction);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Edit.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n addRemoveEventListener(this.parent, this.eventDetails, false);\n this.parent.removeEventListener(events.actionComplete, this.actionCompleteFunction);\n this.parent.removeEventListener(events.actionBegin, this.actionBeginFunction);\n };\n Edit.prototype.actionComplete = function (e) {\n var actions = ['add', 'beginEdit', 'save', 'delete', 'cancel', 'filterAfterOpen', 'filterchoicerequest'];\n if (actions.indexOf(e.requestType) < 0) {\n this.parent.isEdit = false;\n }\n if (e.requestType === 'batchsave') {\n this.parent.focusModule.restoreFocus();\n }\n this.refreshToolbar();\n };\n /**\n * @param {Element} form - specifies the element\n * @param {Object} editedData - specifies the edited data\n * @returns {Object} returns the object\n * @hidden\n */\n Edit.prototype.getCurrentEditedData = function (form, editedData) {\n var gObj = this.parent;\n if (gObj.editSettings.template) {\n var elements = [].slice.call(form.elements);\n for (var k = 0; k < elements.length; k++) {\n if (((elements[parseInt(k.toString(), 10)].hasAttribute('name') && (elements[parseInt(k.toString(), 10)].className !== 'e-multi-hidden')) ||\n elements[parseInt(k.toString(), 10)].classList.contains('e-multiselect')) && !(elements[parseInt(k.toString(), 10)].type === 'hidden' &&\n (parentsUntil(elements[parseInt(k.toString(), 10)], 'e-switch-wrapper') || parentsUntil(elements[parseInt(k.toString(), 10)], 'e-checkbox-wrapper')))) {\n var field = (elements[parseInt(k.toString(), 10)].hasAttribute('name')) ? setComplexFieldID(elements[parseInt(k.toString(), 10)].getAttribute('name')) :\n setComplexFieldID(elements[parseInt(k.toString(), 10)].getAttribute('id'));\n var column = gObj.getColumnByField(field) || { field: field, type: elements[parseInt(k.toString(), 10)].getAttribute('type') };\n var value = void 0;\n if (column.type === 'checkbox' || column.type === 'boolean') {\n value = elements[parseInt(k.toString(), 10)].checked;\n }\n else if (elements[parseInt(k.toString(), 10)].value) {\n value = elements[parseInt(k.toString(), 10)].value;\n if (elements[parseInt(k.toString(), 10)].ej2_instances &&\n elements[parseInt(k.toString(), 10)].ej2_instances.length &&\n !isNullOrUndefined(elements[parseInt(k.toString(), 10)].ej2_instances[0].value)) {\n elements[parseInt(k.toString(), 10)].blur();\n value = elements[parseInt(k.toString(), 10)]\n .ej2_instances[0].value;\n }\n }\n else if (elements[parseInt(k.toString(), 10)].ej2_instances) {\n value = elements[parseInt(k.toString(), 10)]\n .ej2_instances[0].value;\n }\n if (column.edit && typeof column.edit.read === 'string') {\n value = getValue(column.edit.read, window)(elements[parseInt(k.toString(), 10)], value);\n }\n else if (column.edit && column.edit.read) {\n value = column.edit.read(elements[parseInt(k.toString(), 10)], value);\n }\n value = gObj.editModule.getValueFromType(column, value);\n if (elements[parseInt(k.toString(), 10)].type === 'radio') {\n if (elements[parseInt(k.toString(), 10)].checked) {\n DataUtil.setValue(column.field, value, editedData);\n }\n }\n else {\n if (typeof value === 'string') {\n this.parent.sanitize(value);\n }\n DataUtil.setValue(column.field, value, editedData);\n }\n }\n }\n return editedData;\n }\n var col = gObj.columnModel.filter(function (col) { return col.editTemplate; });\n for (var j = 0; j < col.length; j++) {\n if (form[getComplexFieldID(col[parseInt(j.toString(), 10)].field)]) {\n var inputElements = [].slice.call(form[getComplexFieldID(col[parseInt(j.toString(), 10)].field)]);\n inputElements = inputElements.length ? inputElements : [form[getComplexFieldID(col[parseInt(j.toString(), 10)].field)]];\n var temp = inputElements.filter(function (e) {\n return !isNullOrUndefined((e.ej2_instances));\n });\n if (temp.length === 0) {\n temp = inputElements.filter(function (e) { return e.hasAttribute('name'); });\n }\n for (var k = 0; k < temp.length; k++) {\n var value = this.getValue(col[parseInt(j.toString(), 10)], temp[parseInt(k.toString(), 10)], editedData);\n if (col[parseInt(j.toString(), 10)].type === 'string') {\n value = this.parent.sanitize(value);\n }\n DataUtil.setValue(col[parseInt(j.toString(), 10)].field, value, editedData);\n }\n }\n }\n var inputs = [].slice.call(form.getElementsByClassName('e-field'));\n for (var i = 0, len = inputs.length; i < len; i++) {\n var col_1 = gObj.getColumnByUid(inputs[parseInt(i.toString(), 10)].getAttribute('e-mappinguid'));\n if (col_1 && col_1.field) {\n var value = this.getValue(col_1, inputs[parseInt(i.toString(), 10)], editedData);\n if (col_1.type === 'string') {\n value = this.parent.sanitize(value);\n }\n DataUtil.setValue(col_1.field, value, editedData);\n }\n }\n return editedData;\n };\n Edit.prototype.getValue = function (col, input, editedData) {\n var value = input.ej2_instances ?\n input.ej2_instances[0].value : input.value;\n var gObj = this.parent;\n var temp = col.edit.read;\n if (col.type === 'checkbox' || col.type === 'boolean') {\n value = input.checked;\n }\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n value = gObj.editModule.getValueFromType(col, (temp)(input, value));\n }\n else {\n value = gObj.editModule.getValueFromType(col, col.edit.read(input, value));\n }\n if (isNullOrUndefined(editedData[col.field]) && value === '') {\n value = editedData[col.field];\n }\n return value;\n };\n /**\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Edit.prototype.onActionBegin = function (e) {\n if (e.requestType === 'columnstate' && this.parent.isEdit\n && this.parent.editSettings.mode !== 'Batch') {\n this.closeEdit();\n }\n else {\n var editRow = this.parent.element.querySelector('.' + literals.editedRow);\n var addRow = this.parent.element.querySelector('.' + literals.addedRow);\n if (editRow && this.parent.frozenRows && e.requestType === 'virtualscroll'\n && parseInt(parentsUntil(editRow, literals.row).getAttribute(literals.dataRowIndex), 10) < this.parent.frozenRows) {\n return;\n }\n var restrictedRequestTypes = ['filterAfterOpen', 'filterBeforeOpen', 'filterchoicerequest', 'filterSearchBegin', 'save', 'infiniteScroll', 'virtualscroll'];\n var isRestrict = restrictedRequestTypes.indexOf(e.requestType) === -1;\n var isDestroyVirtualForm = this.parent.enableVirtualization && this.formObj\n && !this.formObj.isDestroyed && (editRow || addRow || e.requestType === 'cancel') && isRestrict;\n if ((!this.parent.enableVirtualization && this.parent.editSettings.mode !== 'Batch' && this.formObj && !this.formObj.isDestroyed\n && isRestrict && !e.cancel) || isDestroyVirtualForm) {\n this.destroyWidgets();\n this.destroyForm();\n }\n }\n };\n /**\n * @param {Column[]} cols - specfies the column\n * @returns {void}\n * @hidden\n */\n Edit.prototype.destroyWidgets = function (cols) {\n var gObj = this.parent;\n if (gObj.editSettings.template) {\n this.parent.destroyTemplate(['editSettingsTemplate']);\n if (this.parent.isReact) {\n this.parent.renderTemplates();\n }\n }\n cols = cols ? cols : this.parent.getCurrentVisibleColumns(this.parent.enableColumnVirtualization);\n if (cols.some(function (column) { return !isNullOrUndefined(column.editTemplate); })) {\n this.parent.destroyTemplate(['editTemplate']);\n if (this.parent.isReact) {\n this.parent.renderTemplates();\n }\n }\n for (var _i = 0, cols_1 = cols; _i < cols_1.length; _i++) {\n var col = cols_1[_i];\n var temp = col.edit.destroy;\n if (col.edit.destroy) {\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n temp();\n }\n else {\n col.edit.destroy();\n }\n }\n }\n var elements = [].slice.call(this.formObj.element.elements);\n for (var i = 0; i < elements.length; i++) {\n if (elements[parseInt(i.toString(), 10)].hasAttribute('name')) {\n if (elements[parseInt(i.toString(), 10)].ej2_instances &&\n elements[parseInt(i.toString(), 10)].ej2_instances.length &&\n !elements[parseInt(i.toString(), 10)].ej2_instances[0].isDestroyed) {\n elements[parseInt(i.toString(), 10)].ej2_instances[0].destroy();\n }\n }\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Edit.prototype.destroyForm = function () {\n this.destroyToolTip();\n var formObjects = [this.formObj, this.mFormObj, this.frFormObj, this.virtualFormObj];\n for (var i = 0; i < formObjects.length; i++) {\n if (formObjects[parseInt(i.toString(), 10)] && formObjects[parseInt(i.toString(), 10)].element\n && !formObjects[parseInt(i.toString(), 10)].isDestroyed) {\n formObjects[parseInt(i.toString(), 10)].destroy();\n }\n }\n this.destroyToolTip();\n };\n /**\n * To destroy the editing.\n *\n * @returns {void}\n * @hidden\n */\n Edit.prototype.destroy = function () {\n var gridElement = this.parent.element;\n if (!gridElement) {\n return;\n }\n var hasGridChild = gridElement.querySelector('.' + literals.gridHeader) &&\n gridElement.querySelector('.' + literals.gridContent) ? true : false;\n if (hasGridChild) {\n this.destroyForm();\n }\n this.removeEventListener();\n var elem = this.dialogObj.element;\n if (elem.childElementCount > 0) {\n this.dialogObj.destroy();\n remove(elem);\n }\n elem = this.alertDObj.element;\n if (elem.childElementCount > 0) {\n this.alertDObj.destroy();\n remove(elem);\n }\n if (!hasGridChild) {\n return;\n }\n if (this.editModule) {\n this.editModule.destroy();\n }\n };\n Edit.prototype.keyPressHandler = function (e) {\n var isMacLike = /(Mac)/i.test(navigator.platform);\n if (isMacLike && e.metaKey && e.action === 'ctrlEnter') {\n e.action = 'insert';\n }\n switch (e.action) {\n case 'insert':\n this.addRecord();\n break;\n case 'delete':\n if ((e.target.tagName !== 'INPUT' || e.target.classList.contains('e-checkselect'))\n && !document.querySelector('.e-popup-open.e-edit-dialog')) {\n this.deleteRecord();\n }\n break;\n case 'f2':\n this.startEdit();\n break;\n case 'enter':\n if (!parentsUntil(e.target, 'e-unboundcelldiv') && this.parent.editSettings.mode !== 'Batch' &&\n (parentsUntil(e.target, literals.gridContent) || (this.parent.frozenRows\n && parentsUntil(e.target, literals.headerContent)))\n && !document.getElementsByClassName('e-popup-open').length) {\n e.preventDefault();\n this.endEdit();\n }\n break;\n case 'escape':\n if (this.parent.isEdit && !this.editCellDialogClose) {\n if (this.parent.editSettings.mode === 'Batch') {\n this.editModule.escapeCellEdit();\n }\n else {\n this.curretRowFocus(e);\n }\n }\n if (this.editCellDialogClose) {\n this.editCellDialogClose = false;\n }\n break;\n case 'tab':\n case 'shiftTab':\n this.curretRowFocus(e);\n break;\n }\n };\n Edit.prototype.curretRowFocus = function (e) {\n if (this.parent.isEdit && this.parent.editSettings.mode !== 'Batch') {\n var editedRow = parentsUntil(e.target, 'e-editedrow') || parentsUntil(e.target, 'e-addedrow');\n if (editedRow) {\n var focusableEditCells = [].slice.call(editedRow.querySelectorAll('.e-input:not(.e-disabled)'));\n var commandColCell = [].slice.call(editedRow.querySelectorAll('.e-unboundcell'));\n if (commandColCell) {\n for (var i = 0; i < commandColCell.length; i++) {\n focusableEditCells = focusableEditCells.concat([].slice\n .call(commandColCell[parseInt(i.toString(), 10)].querySelectorAll('.e-btn:not(.e-hide)')));\n }\n }\n var rowCell = parentsUntil(e.target, 'e-rowcell');\n if ((rowCell === parentsUntil(focusableEditCells[focusableEditCells.length - 1], 'e-rowcell')\n && e.action === 'tab' && !rowCell.classList.contains('e-unboundcell'))\n || (rowCell === parentsUntil(focusableEditCells[0], 'e-rowcell') && e.action === 'shiftTab')\n || e.action === 'escape') {\n var uid = editedRow.getAttribute('data-uid');\n var rows = this.parent.getRows();\n var rowIndex = rows.map(function (m) { return m.getAttribute('data-uid'); }).indexOf(uid);\n if (this.parent.frozenRows && parentsUntil(editedRow, 'e-content')) {\n rowIndex = rowIndex - this.parent.frozenRows;\n }\n if (editedRow.classList.contains('e-addedrow')) {\n rowIndex = 0;\n }\n if (e.action === 'escape') {\n this.closeEdit();\n }\n else {\n this.endEdit();\n }\n if (this.parent.focusModule.active) {\n this.parent.focusModule.active.matrix.current = [rowIndex, 0];\n }\n }\n }\n }\n };\n Edit.prototype.preventBatch = function (args) {\n this.preventObj = args;\n this.showDialog('BatchSaveLostChanges', this.dialogObj);\n };\n Edit.prototype.executeAction = function () {\n this.preventObj.handler.call(this.preventObj.instance, this.preventObj.arg1, this.preventObj.arg2, this.preventObj.arg3, this.preventObj.arg4, this.preventObj.arg5, this.preventObj.arg6, this.preventObj.arg7, this.preventObj.arg8);\n };\n /**\n * @param {Column[]} cols - specifies the column\n * @param {Object} newRule - specifies the new rule object\n * @returns {void}\n * @hidden\n */\n Edit.prototype.applyFormValidation = function (cols, newRule) {\n var gObj = this.parent;\n var idx = 0;\n var form = this.parent.editSettings.mode !== 'Dialog' ?\n gObj.element.getElementsByClassName('e-gridform')[parseInt(idx.toString(), 10)] :\n select('#' + gObj.element.id + '_dialogEdit_wrapper .e-gridform', document);\n var index = 1;\n var rules = {};\n var mRules = {};\n var frRules = {};\n cols = cols ? cols : gObj.getColumns();\n for (var i = 0; i < cols.length; i++) {\n if (!cols[parseInt(i.toString(), 10)].visible && (gObj.editSettings.mode !== 'Dialog' || (gObj.groupSettings.columns.indexOf(cols[parseInt(i.toString(), 10)].field) === -1\n && gObj.editSettings.mode === 'Dialog'))) {\n continue;\n }\n if (cols[parseInt(i.toString(), 10)].validationRules && isNullOrUndefined(newRule)) {\n setValidationRuels(cols[parseInt(i.toString(), 10)], index, rules, mRules, frRules, cols.length);\n }\n }\n rules = extend(rules, mRules, frRules);\n this.parent.editModule.formObj = this.createFormObj(form, newRule ? newRule : rules);\n };\n /**\n * @param {HTMLFormElement} form - Defined Form element\n * @param {Object} rules - Defines form rules\n * @returns {FormValidator} Returns formvalidator instance\n * @hidden\n */\n Edit.prototype.createFormObj = function (form, rules) {\n var _this = this;\n return new FormValidator(form, {\n rules: rules,\n locale: this.parent.locale,\n validationComplete: function (args) {\n _this.validationComplete(args);\n },\n customPlacement: function (inputElement, error) {\n var uid = inputElement.getAttribute('e-mappinguid');\n var args = {\n column: _this.parent.getColumnByUid(uid),\n error: error,\n inputElement: inputElement,\n value: inputElement.value\n };\n if (!(event && event['relatedTarget'] && event['relatedTarget'].classList.contains('e-cancelbutton'))) {\n _this.valErrorPlacement(inputElement, error);\n }\n _this.parent.notify(events.valCustomPlacement, args);\n }\n });\n };\n Edit.prototype.valErrorPlacement = function (inputElement, error) {\n if (this.parent.isEdit) {\n var id = error.getAttribute('for');\n var elem = this.getElemTable(inputElement).querySelector('#' + getParsedFieldID(id) + '_Error');\n if (!elem) {\n this.createTooltip(inputElement, error, id, '');\n }\n else {\n elem.querySelector('.e-tip-content').innerHTML = error.outerHTML;\n }\n }\n };\n Edit.prototype.getElemTable = function (inputElement) {\n var isFHdr;\n var gObj = this.parent;\n var table;\n if (gObj.editSettings.mode !== 'Dialog') {\n isFHdr = (gObj.frozenRows && gObj.frozenRows\n > (parseInt(closest(inputElement, '.' + literals.row).getAttribute(literals.dataRowIndex), 10) || 0));\n var field = inputElement.name;\n table = this.parent.isFrozenGrid() ? gObj.element : isFHdr ? gObj.getHeaderTable() : gObj.getContentTable();\n }\n else {\n table = select('#' + gObj.element.id + '_dialogEdit_wrapper', document);\n }\n return table;\n };\n Edit.prototype.resetElemPosition = function (elem, args) {\n var td = parentsUntil(args.element, literals.rowCell);\n if (td) {\n var tdRight = td.getBoundingClientRect().right;\n var elemRight = elem.getBoundingClientRect().right;\n if (elemRight > tdRight) {\n var offSet = elemRight - tdRight;\n elem.style.left = (elem.offsetLeft - offSet) + 'px';\n }\n }\n };\n Edit.prototype.validationComplete = function (args) {\n if (this.parent.isEdit) {\n var elem = this.getElemTable(args.element).querySelector('#' + getParsedFieldID(args.inputName) + '_Error');\n if (elem) {\n if (args.status === 'failure') {\n elem.style.display = '';\n this.resetElemPosition(elem, args);\n }\n else {\n elem.style.display = 'none';\n }\n }\n }\n };\n Edit.prototype.createTooltip = function (element, error, name, display) {\n var formObj = this.formObj.element;\n var customForm = parentsUntil(element, 'e-virtual-validation');\n if (customForm) {\n formObj = this.virtualFormObj.element;\n }\n var gcontent = this.parent.getContent().firstElementChild;\n var isScroll = gcontent.scrollHeight > gcontent.clientHeight || gcontent.scrollWidth > gcontent.clientWidth;\n var isInline = this.parent.editSettings.mode !== 'Dialog';\n var td = closest(element, '.' + literals.rowCell);\n var row = closest(element, '.' + literals.row);\n var isFHdr;\n var isFHdrLastRow = false;\n var validationForBottomRowPos;\n var isBatchModeLastRow = false;\n var viewPortRowCount = Math.round(this.parent.getContent().clientHeight / this.parent.getRowHeight()) - 1;\n var rows = [].slice.call(this.parent.getContent().getElementsByClassName(literals.row));\n if (this.parent.editSettings.mode === 'Batch') {\n rows = [].slice.call(this.parent.getContent().querySelectorAll('.e-row:not(.e-hiddenrow)'));\n if (viewPortRowCount >= 1 && rows.length >= viewPortRowCount\n && rows[rows.length - 1].getAttribute(literals.dataRowIndex) === row.getAttribute(literals.dataRowIndex)) {\n isBatchModeLastRow = true;\n }\n }\n if (isInline) {\n if (this.parent.frozenRows) {\n var fHearderRows = [].slice.call(this.parent.getHeaderTable().querySelector(literals.tbody).querySelectorAll('.e-row:not(.e-hiddenrow)'));\n isFHdr = fHearderRows.length > (parseInt(row.getAttribute(literals.dataRowIndex), 10) || 0);\n isFHdrLastRow = isFHdr && parseInt(row.getAttribute(literals.dataRowIndex), 10) === fHearderRows.length - 1;\n var insertRow = [].slice.call(this.parent.getHeaderTable().querySelector(literals.tbody).querySelectorAll('.e-row:not(.e-hiddenrow)'));\n if (insertRow.length === 1 && (insertRow[0].classList.contains('e-addedrow') || insertRow[0].classList.contains('e-insertedrow'))) {\n isFHdrLastRow = true;\n }\n }\n if (isFHdrLastRow || (viewPortRowCount >= 1 && rows.length >= viewPortRowCount\n && ((this.parent.editSettings.newRowPosition === 'Bottom' && (this.editModule.args\n && this.editModule.args.requestType === 'add')) || (td.classList.contains('e-lastrowcell')\n && !row.classList.contains(literals.addedRow)))) || isBatchModeLastRow) {\n validationForBottomRowPos = true;\n }\n }\n var table = isInline ?\n (isFHdr ? this.parent.getHeaderTable() : this.parent.getContentTable()) :\n select('#' + this.parent.element.id + '_dialogEdit_wrapper .e-dlg-content', document);\n var client = table.getBoundingClientRect();\n var left = isInline ?\n this.parent.element.getBoundingClientRect().left : client.left;\n var input = closest(element, 'td');\n var inputClient = input ? input.getBoundingClientRect() : element.parentElement.getBoundingClientRect();\n var div = this.parent.createElement('div', {\n className: 'e-tooltip-wrap e-lib e-control e-popup e-griderror',\n id: name + '_Error',\n styles: 'display:' + display + ';top:' +\n ((isFHdr ? inputClient.top + inputClient.height : inputClient.bottom - client.top) + table.scrollTop + 9) + 'px;left:' +\n (inputClient.left - left + table.scrollLeft + inputClient.width / 2) + 'px;' +\n 'max-width:' + inputClient.width + 'px;text-align:center;'\n });\n if (this.parent.cssClass) {\n div.classList.add(this.parent.cssClass);\n }\n if (isInline && client.left < left) {\n div.style.left = parseInt(div.style.left, 10) - client.left + left + 'px';\n }\n var content = this.parent.createElement('div', { className: 'e-tip-content' });\n content.appendChild(error);\n var arrow;\n if (validationForBottomRowPos) {\n arrow = this.parent.createElement('div', { className: 'e-arrow-tip e-tip-bottom' });\n arrow.appendChild(this.parent.createElement('div', { className: 'e-arrow-tip-outer e-tip-bottom' }));\n arrow.appendChild(this.parent.createElement('div', { className: 'e-arrow-tip-inner e-tip-bottom' }));\n }\n else {\n arrow = this.parent.createElement('div', { className: 'e-arrow-tip e-tip-top' });\n arrow.appendChild(this.parent.createElement('div', { className: 'e-arrow-tip-outer e-tip-top' }));\n arrow.appendChild(this.parent.createElement('div', { className: 'e-arrow-tip-inner e-tip-top' }));\n }\n div.appendChild(content);\n div.appendChild(arrow);\n if (!customForm && (this.parent.frozenRows) && this.parent.editSettings.mode !== 'Dialog') {\n var getEditCell = this.parent.editSettings.mode === 'Normal' ?\n closest(element, '.e-editcell') : closest(element, '.' + literals.table);\n getEditCell.style.position = 'relative';\n div.style.position = 'absolute';\n if (this.parent.editSettings.mode === 'Batch' ||\n (closest(element, '.' + literals.frozenContent) || closest(element, '.' + literals.frozenHeader))\n || (this.parent.frozenRows)) {\n if (this.parent.isFrozenGrid()) {\n if (td.classList.contains('e-unfreeze')) {\n addClass([div], 'e-unfreeze');\n formObj.appendChild(div);\n }\n else {\n var elem = closest(td, '.e-gridheader') ? this.parent.element.querySelector('.e-gridheader') :\n rows.length === 1 ? this.parent.element.querySelector('.e-gridcontent').querySelector('.e-content') :\n this.parent.element.querySelector('.e-gridcontent');\n elem.appendChild(div);\n elem.style.position = 'relative';\n }\n }\n else {\n formObj.appendChild(div);\n }\n }\n else {\n this.mFormObj.element.appendChild(div);\n }\n }\n else {\n if (customForm) {\n this.virtualFormObj.element.appendChild(div);\n }\n else {\n if (this.parent.isFrozenGrid()) {\n if (td.classList.contains('e-unfreeze')) {\n addClass([div], 'e-unfreeze');\n this.formObj.element.appendChild(div);\n }\n else {\n var elem = closest(td, '.e-gridheader') ? this.parent.element.querySelector('.e-gridheader') :\n rows.length === 1 ? this.parent.element.querySelector('.e-gridcontent').querySelector('.e-content') :\n this.parent.element.querySelector('.e-gridcontent');\n elem.appendChild(div);\n elem.style.position = 'relative';\n }\n }\n else {\n this.formObj.element.appendChild(div);\n }\n }\n }\n if (!isNullOrUndefined(td)) {\n if (td.classList.contains('e-fixedfreeze')) {\n div.classList.add('e-fixederror');\n }\n else if (td.classList.contains('e-leftfreeze') || td.classList.contains('e-rightfreeze')) {\n div.classList.add('e-freezeerror');\n }\n }\n if (!validationForBottomRowPos && isInline && gcontent.getBoundingClientRect().bottom < inputClient.bottom + inputClient.height) {\n var contentDiv = this.parent.getContent().querySelector('.e-content');\n if (this.parent.currentViewData.length === 0 && contentDiv.scrollTop === 0) {\n contentDiv.scrollTop = div.offsetHeight + arrow.scrollHeight;\n }\n else {\n gcontent.scrollTop = gcontent.scrollTop + div.offsetHeight + arrow.scrollHeight;\n }\n }\n var lineHeight = parseInt(document.defaultView.getComputedStyle(div, null).getPropertyValue('font-size'), 10);\n if (div.getBoundingClientRect().width < inputClient.width &&\n div.querySelector('label').getBoundingClientRect().height / (lineHeight * 1.2) >= 2) {\n div.style.width = div.style.maxWidth;\n }\n if (this.parent.frozenRows && this.parent.editSettings.mode !== 'Dialog') {\n div.style.left = input.offsetLeft + (input.offsetWidth / 2 - div.offsetWidth / 2) + 'px';\n }\n else {\n div.style.left = (parseInt(div.style.left, 10) - div.offsetWidth / 2) + 'px';\n }\n if (isInline && !isScroll && !this.parent.allowPaging || this.parent.frozenRows) {\n // gcontent.style.position = 'static';\n var pos = calculateRelativeBasedPosition(input, div);\n div.style.top = pos.top + inputClient.height + 9 + 'px';\n }\n if (validationForBottomRowPos) {\n if (isScroll && this.parent.height !== 'auto' && !this.parent.frozenRows\n && !this.parent.enableVirtualization && !(div.classList.contains('e-freezeerror') && div.classList.contains('e-fixederror'))) {\n var scrollWidth = gcontent.scrollWidth > gcontent.offsetWidth ? getScrollBarWidth() : 0;\n var gHeight = this.parent.height.toString().indexOf('%') === -1 ?\n parseInt(this.parent.height, 10) : gcontent.offsetHeight;\n div.style.bottom = (gHeight - gcontent.querySelector('table').offsetHeight\n - scrollWidth) + inputClient.height + 9 + 'px';\n }\n else {\n div.style.bottom = inputClient.height + 9 + 'px';\n }\n if (rows.length < viewPortRowCount && this.parent.editSettings.newRowPosition === 'Bottom' && (this.editModule.args\n && this.editModule.args.requestType === 'add')) {\n var rowsCount = this.parent.frozenRows ? this.parent.frozenRows + (rows.length - 1) : rows.length - 1;\n var rowsHeight = rowsCount * this.parent.getRowHeight();\n var position = this.parent.getContent().clientHeight - rowsHeight;\n div.style.bottom = position + 9 + 'px';\n }\n div.style.top = null;\n }\n };\n /**\n * @param {Column} col - specfies the column\n * @returns {boolean} returns the whether column is grouped\n * @hidden\n */\n Edit.prototype.checkColumnIsGrouped = function (col) {\n return !col.visible && !(this.parent.groupSettings.columns.indexOf(col.field) > -1);\n };\n /**\n * @param {object} editors -specfies the editors\n * @returns {void}\n * @hidden\n */\n Edit.AddEditors = function (editors) {\n Edit.editCellType = extend(Edit.editCellType, editors);\n };\n Edit.editCellType = {\n 'dropdownedit': DropDownEditCell, 'numericedit': NumericEditCell,\n 'datepickeredit': DatePickerEditCell, 'datetimepickeredit': DatePickerEditCell,\n 'booleanedit': BooleanEditCell, 'defaultedit': DefaultEditCell,\n 'templateedit': TemplateEditCell\n };\n return Edit;\n}());\nexport { Edit };\n","//! moment.js locale configuration\n//! locale : Konkani Devanagari script [gom-deva]\n//! author : The Discoverer : https://github.com/WikiDiscoverer\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n s: ['थोडया सॅकंडांनी', 'थोडे सॅकंड'],\n ss: [number + ' सॅकंडांनी', number + ' सॅकंड'],\n m: ['à¤à¤•à¤¾ मिणटान', 'à¤à¤• मिनूट'],\n mm: [number + ' मिणटांनी', number + ' मिणटां'],\n h: ['à¤à¤•à¤¾ वरान', 'à¤à¤• वर'],\n hh: [number + ' वरांनी', number + ' वरां'],\n d: ['à¤à¤•à¤¾ दिसान', 'à¤à¤• दीस'],\n dd: [number + ' दिसांनी', number + ' दीस'],\n M: ['à¤à¤•à¤¾ मà¥à¤¹à¤¯à¤¨à¥à¤¯à¤¾à¤¨', 'à¤à¤• मà¥à¤¹à¤¯à¤¨à¥‹'],\n MM: [number + ' मà¥à¤¹à¤¯à¤¨à¥à¤¯à¤¾à¤¨à¥€', number + ' मà¥à¤¹à¤¯à¤¨à¥‡'],\n y: ['à¤à¤•à¤¾ वरà¥à¤¸à¤¾à¤¨', 'à¤à¤• वरà¥à¤¸'],\n yy: [number + ' वरà¥à¤¸à¤¾à¤‚नी', number + ' वरà¥à¤¸à¤¾à¤‚'],\n };\n return isFuture ? format[key][0] : format[key][1];\n }\n\n var gomDeva = moment.defineLocale('gom-deva', {\n months: {\n standalone:\n 'जानेवारी_फेबà¥à¤°à¥à¤µà¤¾à¤°à¥€_मारà¥à¤š_à¤à¤ªà¥à¤°à¥€à¤²_मे_जून_जà¥à¤²à¤¯_ऑगसà¥à¤Ÿ_सपà¥à¤Ÿà¥‡à¤‚बर_ऑकà¥à¤Ÿà¥‹à¤¬à¤°_नोवà¥à¤¹à¥‡à¤‚बर_डिसेंबर'.split(\n '_'\n ),\n format: 'जानेवारीचà¥à¤¯à¤¾_फेबà¥à¤°à¥à¤µà¤¾à¤°à¥€à¤šà¥à¤¯à¤¾_मारà¥à¤šà¤¾à¤šà¥à¤¯à¤¾_à¤à¤ªà¥à¤°à¥€à¤²à¤¾à¤šà¥à¤¯à¤¾_मेयाचà¥à¤¯à¤¾_जूनाचà¥à¤¯à¤¾_जà¥à¤²à¤¯à¤¾à¤šà¥à¤¯à¤¾_ऑगसà¥à¤Ÿà¤¾à¤šà¥à¤¯à¤¾_सपà¥à¤Ÿà¥‡à¤‚बराचà¥à¤¯à¤¾_ऑकà¥à¤Ÿà¥‹à¤¬à¤°à¤¾à¤šà¥à¤¯à¤¾_नोवà¥à¤¹à¥‡à¤‚बराचà¥à¤¯à¤¾_डिसेंबराचà¥à¤¯à¤¾'.split(\n '_'\n ),\n isFormat: /MMMM(\\s)+D[oD]?/,\n },\n monthsShort:\n 'जाने._फेबà¥à¤°à¥._मारà¥à¤š_à¤à¤ªà¥à¤°à¥€._मे_जून_जà¥à¤²._ऑग._सपà¥à¤Ÿà¥‡à¤‚._ऑकà¥à¤Ÿà¥‹._नोवà¥à¤¹à¥‡à¤‚._डिसें.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'आयतार_सोमार_मंगळार_बà¥à¤§à¤µà¤¾à¤°_बिरेसà¥à¤¤à¤¾à¤°_सà¥à¤•à¥à¤°à¤¾à¤°_शेनवार'.split('_'),\n weekdaysShort: 'आयत._सोम._मंगळ._बà¥à¤§._बà¥à¤°à¥‡à¤¸à¥à¤¤._सà¥à¤•à¥à¤°._शेन.'.split('_'),\n weekdaysMin: 'आ_सो_मं_बà¥_बà¥à¤°à¥‡_सà¥_शे'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'A h:mm [वाजतां]',\n LTS: 'A h:mm:ss [वाजतां]',\n L: 'DD-MM-YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY A h:mm [वाजतां]',\n LLLL: 'dddd, MMMM Do, YYYY, A h:mm [वाजतां]',\n llll: 'ddd, D MMM YYYY, A h:mm [वाजतां]',\n },\n calendar: {\n sameDay: '[आयज] LT',\n nextDay: '[फालà¥à¤¯à¤¾à¤‚] LT',\n nextWeek: '[फà¥à¤¡à¤²à¥‹] dddd[,] LT',\n lastDay: '[काल] LT',\n lastWeek: '[फाटलो] dddd[,] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s',\n past: '%s आदीं',\n s: processRelativeTime,\n ss: processRelativeTime,\n m: processRelativeTime,\n mm: processRelativeTime,\n h: processRelativeTime,\n hh: processRelativeTime,\n d: processRelativeTime,\n dd: processRelativeTime,\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(वेर)/,\n ordinal: function (number, period) {\n switch (period) {\n // the ordinal 'वेर' only applies to day of the month\n case 'D':\n return number + 'वेर';\n default:\n case 'M':\n case 'Q':\n case 'DDD':\n case 'd':\n case 'w':\n case 'W':\n return number;\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week\n doy: 3, // The week that contains Jan 4th is the first week of the year (7 + 0 - 4)\n },\n meridiemParse: /राती|सकाळीं|दनपारां|सांजे/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'राती') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'सकाळीं') {\n return hour;\n } else if (meridiem === 'दनपारां') {\n return hour > 12 ? hour : hour + 12;\n } else if (meridiem === 'सांजे') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'राती';\n } else if (hour < 12) {\n return 'सकाळीं';\n } else if (hour < 16) {\n return 'दनपारां';\n } else if (hour < 20) {\n return 'सांजे';\n } else {\n return 'राती';\n }\n },\n });\n\n return gomDeva;\n\n})));\n","//! moment.js locale configuration\n//! locale : Ukrainian [uk]\n//! author : zemlanin : https://github.com/zemlanin\n//! Author : Menelion Elensúle : https://github.com/Oire\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function plural(word, num) {\n var forms = word.split('_');\n return num % 10 === 1 && num % 100 !== 11\n ? forms[0]\n : num % 10 >= 2 && num % 10 <= 4 && (num % 100 < 10 || num % 100 >= 20)\n ? forms[1]\n : forms[2];\n }\n function relativeTimeWithPlural(number, withoutSuffix, key) {\n var format = {\n ss: withoutSuffix ? 'Ñекунда_Ñекунди_Ñекунд' : 'Ñекунду_Ñекунди_Ñекунд',\n mm: withoutSuffix ? 'хвилина_хвилини_хвилин' : 'хвилину_хвилини_хвилин',\n hh: withoutSuffix ? 'година_години_годин' : 'годину_години_годин',\n dd: 'день_дні_днів',\n MM: 'міÑÑць_міÑÑці_міÑÑців',\n yy: 'рік_роки_років',\n };\n if (key === 'm') {\n return withoutSuffix ? 'хвилина' : 'хвилину';\n } else if (key === 'h') {\n return withoutSuffix ? 'година' : 'годину';\n } else {\n return number + ' ' + plural(format[key], +number);\n }\n }\n function weekdaysCaseReplace(m, format) {\n var weekdays = {\n nominative:\n 'неділÑ_понеділок_вівторок_Ñереда_четвер_п’ÑтницÑ_Ñубота'.split(\n '_'\n ),\n accusative:\n 'неділю_понеділок_вівторок_Ñереду_четвер_п’Ñтницю_Ñуботу'.split(\n '_'\n ),\n genitive:\n 'неділі_понеділка_вівторка_Ñереди_четверга_п’Ñтниці_Ñуботи'.split(\n '_'\n ),\n },\n nounCase;\n\n if (m === true) {\n return weekdays['nominative']\n .slice(1, 7)\n .concat(weekdays['nominative'].slice(0, 1));\n }\n if (!m) {\n return weekdays['nominative'];\n }\n\n nounCase = /(\\[[ВвУу]\\]) ?dddd/.test(format)\n ? 'accusative'\n : /\\[?(?:минулої|наÑтупної)? ?\\] ?dddd/.test(format)\n ? 'genitive'\n : 'nominative';\n return weekdays[nounCase][m.day()];\n }\n function processHoursFunction(str) {\n return function () {\n return str + 'о' + (this.hours() === 11 ? 'б' : '') + '] LT';\n };\n }\n\n var uk = moment.defineLocale('uk', {\n months: {\n format: 'ÑічнÑ_лютого_березнÑ_квітнÑ_травнÑ_червнÑ_липнÑ_ÑерпнÑ_вереÑнÑ_жовтнÑ_лиÑтопада_груднÑ'.split(\n '_'\n ),\n standalone:\n 'Ñічень_лютий_березень_квітень_травень_червень_липень_Ñерпень_вереÑень_жовтень_лиÑтопад_грудень'.split(\n '_'\n ),\n },\n monthsShort: 'Ñіч_лют_бер_квіт_трав_черв_лип_Ñерп_вер_жовт_лиÑÑ‚_груд'.split(\n '_'\n ),\n weekdays: weekdaysCaseReplace,\n weekdaysShort: 'нд_пн_вт_ÑÑ€_чт_пт_Ñб'.split('_'),\n weekdaysMin: 'нд_пн_вт_ÑÑ€_чт_пт_Ñб'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY Ñ€.',\n LLL: 'D MMMM YYYY Ñ€., HH:mm',\n LLLL: 'dddd, D MMMM YYYY Ñ€., HH:mm',\n },\n calendar: {\n sameDay: processHoursFunction('[Сьогодні '),\n nextDay: processHoursFunction('[Завтра '),\n lastDay: processHoursFunction('[Вчора '),\n nextWeek: processHoursFunction('[У] dddd ['),\n lastWeek: function () {\n switch (this.day()) {\n case 0:\n case 3:\n case 5:\n case 6:\n return processHoursFunction('[Минулої] dddd [').call(this);\n case 1:\n case 2:\n case 4:\n return processHoursFunction('[Минулого] dddd [').call(this);\n }\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'за %s',\n past: '%s тому',\n s: 'декілька Ñекунд',\n ss: relativeTimeWithPlural,\n m: relativeTimeWithPlural,\n mm: relativeTimeWithPlural,\n h: 'годину',\n hh: relativeTimeWithPlural,\n d: 'день',\n dd: relativeTimeWithPlural,\n M: 'міÑÑць',\n MM: relativeTimeWithPlural,\n y: 'рік',\n yy: relativeTimeWithPlural,\n },\n // M. E.: those two are virtually unused but a user might want to implement them for his/her website for some reason\n meridiemParse: /ночі|ранку|днÑ|вечора/,\n isPM: function (input) {\n return /^(днÑ|вечора)$/.test(input);\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'ночі';\n } else if (hour < 12) {\n return 'ранку';\n } else if (hour < 17) {\n return 'днÑ';\n } else {\n return 'вечора';\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}-(й|го)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'M':\n case 'd':\n case 'DDD':\n case 'w':\n case 'W':\n return number + '-й';\n case 'D':\n return number + '-го';\n default:\n return number;\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return uk;\n\n})));\n","import { Dialog } from '@syncfusion/ej2-popups';\nimport { EventHandler, isNullOrUndefined, remove, Browser } from '@syncfusion/ej2-base';\nimport { parentsUntil, addBiggerDialog, addRemoveEventListener } from '../base/util';\nimport * as events from '../base/constant';\nimport { Button } from '@syncfusion/ej2-buttons';\nimport { ResponsiveDialogAction } from '../base/enum';\n/**\n *\n * The `ResponsiveDialogRenderer` module is used to render the responsive dialogs.\n */\nvar ResponsiveDialogRenderer = /** @class */ (function () {\n function ResponsiveDialogRenderer(parent, serviceLocator) {\n this.sortedCols = [];\n this.sortPredicate = [];\n /** @hidden */\n this.isCustomDialog = false;\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.addEventListener();\n }\n ResponsiveDialogRenderer.prototype.addEventListener = function () {\n this.evtHandlers = [{ event: events.filterDialogClose, handler: this.closeCustomDialog },\n { event: events.refreshCustomFilterOkBtn, handler: this.refreshCustomFilterOkBtn },\n { event: events.renderResponsiveCmenu, handler: this.renderResponsiveContextMenu },\n { event: events.filterCmenuSelect, handler: this.renderCustomFilterDiv },\n { event: events.customFilterClose, handler: this.customExFilterClose },\n { event: events.refreshCustomFilterClearBtn, handler: this.refreshCustomFilterClearBtn }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n this.onActionCompleteFn = this.editComplate.bind(this);\n this.parent.addEventListener(events.actionComplete, this.onActionCompleteFn);\n };\n ResponsiveDialogRenderer.prototype.customExFilterClose = function () {\n this.isCustomDlgRender = false;\n };\n ResponsiveDialogRenderer.prototype.renderCustomFilterDiv = function () {\n var header = this.customResponsiveDlg.element.querySelector('.e-dlg-header-content');\n var title = header.querySelector('.e-dlg-custom-header');\n var closeBtn = header.querySelector('.e-dlg-closeicon-btn');\n this.isCustomDlgRender = true;\n this.parent.filterModule.filterModule.closeDialog();\n this.saveBtn.element.style.display = '';\n this.refreshCustomFilterOkBtn({ disabled: false });\n this.backBtn.element.style.display = 'none';\n closeBtn.style.display = '';\n title.innerHTML = this.parent.localeObj.getConstant('CustomFilter');\n var content = this.customResponsiveDlg.element.querySelector('.e-dlg-content');\n this.customExcelFilterParent = this.parent.createElement('div', { className: 'e-xl-customfilterdiv e-default-filter' });\n content.appendChild(this.customExcelFilterParent);\n };\n ResponsiveDialogRenderer.prototype.renderResponsiveContextMenu = function (args) {\n if (this.action === ResponsiveDialogAction.isFilter) {\n var content = this.customResponsiveDlg.element.querySelector('.e-dlg-content');\n var header = this.customResponsiveDlg.element.querySelector('.e-dlg-header-content');\n var closeBtn = header.querySelector('.e-dlg-closeicon-btn');\n var text = header.querySelector('.e-dlg-custom-header');\n if (args.isOpen) {\n content.firstChild.style.display = 'none';\n content.appendChild(args.target);\n closeBtn.style.display = 'none';\n this.saveBtn.element.style.display = 'none';\n this.filterClearBtn.element.style.display = 'none';\n text.innerHTML = args.header;\n var backBtn = this.parent.createElement('button');\n var span = this.parent.createElement('span', { className: 'e-btn-icon e-resfilterback e-icons' });\n backBtn.appendChild(span);\n this.backBtn = new Button({\n cssClass: this.parent.cssClass ? 'e-res-back-btn' + ' ' + this.parent.cssClass : 'e-res-back-btn'\n });\n this.backBtn.appendTo(backBtn);\n text.parentElement.insertBefore(backBtn, text);\n }\n else if (this.backBtn && !this.isCustomDlgRender) {\n content.firstChild.style.display = '';\n remove(this.backBtn.element);\n closeBtn.style.display = '';\n this.saveBtn.element.style.display = '';\n if (this.isFiltered) {\n this.filterClearBtn.element.style.display = '';\n }\n text.innerHTML = this.getHeaderTitle({ action: ResponsiveDialogAction.isFilter }, args.col);\n }\n }\n };\n ResponsiveDialogRenderer.prototype.refreshCustomFilterClearBtn = function (args) {\n if (this.filterClearBtn) {\n this.isFiltered = args.isFiltered;\n this.filterClearBtn.element.style.display = args.isFiltered ? '' : 'none';\n }\n };\n ResponsiveDialogRenderer.prototype.refreshCustomFilterOkBtn = function (args) {\n if (this.saveBtn) {\n this.saveBtn.disabled = args.disabled;\n }\n if (this.parent.columnChooserModule && this.parent.columnChooserModule.responsiveDialogRenderer.saveBtn) {\n this.parent.columnChooserModule.responsiveDialogRenderer.saveBtn.disabled = args.disabled;\n }\n };\n ResponsiveDialogRenderer.prototype.columnMenuResponsiveContent = function (str, locale, disabled) {\n var cDiv = this.parent.createElement('div', { className: 'e-responsivecoldiv e-responsive' + str.toLowerCase() + 'div' + (disabled ? ' e-disabled' : '') });\n var span = this.parent.createElement('span', { className: 'e-icons e-res' + str.toLowerCase() + '-icon e-btn-icon' });\n var icon = this.parent.createElement('span', { innerHTML: locale, className: 'e-rescolumn-menu e-res-header-text' });\n cDiv.appendChild(span);\n cDiv.appendChild(icon);\n this.customColumnDiv.appendChild(cDiv);\n };\n ResponsiveDialogRenderer.prototype.renderResponsiveContent = function (col, column) {\n var _this = this;\n var gObj = this.parent;\n var isColumnChooser = this.action === ResponsiveDialogAction.isColumnChooser;\n if (col || isColumnChooser) {\n this.filterParent = this.parent.createElement('div', { className: (isColumnChooser ? 'e-maincolumnchooserdiv ' : '') + 'e-mainfilterdiv e-default-filter',\n id: (isColumnChooser ? 'columchooser' : col.uid) + '-main-filter' });\n return this.filterParent;\n }\n else {\n this.customColumnDiv = gObj.createElement('div', { className: 'columndiv columnmenudiv', styles: 'width: 100%' });\n if (this.parent.showColumnMenu && this.parent.rowRenderingMode === 'Horizontal' && this.action === ResponsiveDialogAction.isColMenu) {\n this.columnMenuResponsiveContent('AutoFitAll', gObj.localeObj.getConstant('AutoFitAll'));\n this.columnMenuResponsiveContent('AutoFit', gObj.localeObj.getConstant('AutoFit'));\n if (column.allowGrouping && gObj.allowGrouping) {\n this.columnMenuResponsiveContent('Group', gObj.localeObj.getConstant('Group'), gObj.groupSettings.columns.indexOf(column.field) >= 0);\n this.columnMenuResponsiveContent('UnGroup', gObj.localeObj.getConstant('Ungroup'), gObj.groupSettings.columns.indexOf(column.field) < 0);\n }\n if (column.allowSorting && gObj.allowSorting) {\n var direction = 'None';\n var sortColumns = this.parent.sortSettings.columns;\n for (var i = 0; i < sortColumns.length; i++) {\n if (sortColumns[parseInt(i.toString(), 10)].field === column.field) {\n direction = sortColumns[parseInt(i.toString(), 10)].direction;\n break;\n }\n }\n this.columnMenuResponsiveContent('ascending', gObj.localeObj.getConstant('SortAscending'), direction === 'Ascending');\n this.columnMenuResponsiveContent('descending', gObj.localeObj.getConstant('SortDescending'), direction === 'Descending');\n }\n if (gObj.showColumnChooser) {\n this.columnMenuResponsiveContent('Column', gObj.localeObj.getConstant('Columnchooser'));\n }\n if (column.allowFiltering && gObj.allowFiltering) {\n this.columnMenuResponsiveContent('Filter', gObj.localeObj.getConstant('FilterMenu'));\n }\n }\n else {\n var cols = gObj.getColumns();\n var sortBtnParent = gObj.createElement('div', { className: 'e-ressortbutton-parent' });\n var filteredCols = [];\n var isSort = this.action === ResponsiveDialogAction.isSort;\n var isFilter = this.action === ResponsiveDialogAction.isFilter;\n if (isFilter) {\n for (var i = 0; i < gObj.filterSettings.columns.length; i++) {\n filteredCols.push(gObj.filterSettings.columns[parseInt(i.toString(), 10)].field);\n }\n }\n for (var i = 0; i < cols.length; i++) {\n if (!cols[parseInt(i.toString(), 10)].visible || (!cols[parseInt(i.toString(), 10)].allowSorting && isSort)\n || (!cols[parseInt(i.toString(), 10)].allowFiltering && isFilter)) {\n continue;\n }\n var cDiv = gObj.createElement('div', { className: 'e-responsivecoldiv' });\n cDiv.setAttribute('data-e-mappingname', cols[parseInt(i.toString(), 10)].field);\n cDiv.setAttribute('data-e-mappinguid', cols[parseInt(i.toString(), 10)].uid);\n var span = gObj.createElement('span', { innerHTML: cols[parseInt(i.toString(), 10)].headerText, className: 'e-res-header-text' });\n cDiv.appendChild(span);\n this.customColumnDiv.appendChild(cDiv);\n if (isSort) {\n var fields = this.getSortedFieldsAndDirections('field');\n var index = fields.indexOf(cols[parseInt(i.toString(), 10)].field);\n var button = gObj.createElement('button', { id: gObj.element.id + cols[parseInt(i.toString(), 10)].field + 'sortbutton' });\n var clone = sortBtnParent.cloneNode();\n clone.appendChild(button);\n cDiv.appendChild(clone);\n var btnObj = new Button({\n cssClass: this.parent.cssClass ? 'e-ressortbutton' + ' ' + this.parent.cssClass : 'e-ressortbutton'\n });\n btnObj.appendTo(button);\n var buttonInnerText = void 0;\n if ((!isNullOrUndefined(this.parent.sortSettings.columns[parseInt(index.toString(), 10)]))) {\n buttonInnerText = (this.parent.sortSettings.columns[parseInt(index.toString(), 10)].direction === 'Ascending') ?\n this.parent.localeObj.getConstant('AscendingText') : this.parent.localeObj.getConstant('DescendingText');\n }\n button.innerHTML = index > -1 ? buttonInnerText : this.parent.localeObj.getConstant('NoneText');\n button.onclick = function (e) {\n _this.sortButtonClickHandler(e.target);\n };\n }\n if (isFilter && filteredCols.indexOf(cols[parseInt(i.toString(), 10)].field) > -1) {\n var divIcon = gObj.createElement('div', { className: 'e-icons e-res-icon e-filtersetdiv' });\n var iconSpan = gObj.createElement('span', { className: 'e-icons e-res-icon e-filterset' });\n iconSpan.setAttribute('colType', cols[parseInt(i.toString(), 10)].type);\n divIcon.appendChild(iconSpan);\n cDiv.appendChild(divIcon);\n }\n }\n }\n EventHandler.add(this.customColumnDiv, Browser.isDevice ? 'touchend' : 'click', this.customFilterColumnClickHandler, this);\n return this.customColumnDiv;\n }\n };\n ResponsiveDialogRenderer.prototype.getSortedFieldsAndDirections = function (name) {\n var fields = [];\n for (var i = 0; i < this.parent.sortSettings.columns.length; i++) {\n fields.push(this.parent.sortSettings.columns[parseInt(i.toString(), 10)][\"\" + name]);\n }\n return fields;\n };\n ResponsiveDialogRenderer.prototype.sortButtonClickHandler = function (target) {\n if (target) {\n var columndiv = parentsUntil(target, 'e-responsivecoldiv');\n var field = columndiv.getAttribute('data-e-mappingname');\n if (!this.parent.allowMultiSorting) {\n this.sortPredicate = [];\n this.sortedCols = [];\n this.isSortApplied = false;\n this.resetSortButtons(target);\n }\n var txt = target.textContent;\n var directionTxt = txt === this.parent.localeObj.getConstant('NoneText') ? this.parent.localeObj.getConstant('AscendingText')\n : txt === this.parent.localeObj.getConstant('AscendingText') ? this.parent.localeObj.getConstant('DescendingText')\n : this.parent.localeObj.getConstant('NoneText');\n var direction = directionTxt === this.parent.localeObj.getConstant('AscendingText') ? 'Ascending'\n : directionTxt === this.parent.localeObj.getConstant('DescendingText') ? 'Descending' : 'None';\n target.innerHTML = directionTxt;\n this.setSortedCols(field, direction);\n }\n };\n ResponsiveDialogRenderer.prototype.resetSortButtons = function (target) {\n var buttons = [].slice.call(this.customColumnDiv.getElementsByClassName('e-ressortbutton'));\n for (var i = 0; i < buttons.length; i++) {\n if (buttons[parseInt(i.toString(), 10)] !== target) {\n buttons[parseInt(i.toString(), 10)].innerHTML = 'None';\n }\n }\n };\n ResponsiveDialogRenderer.prototype.setSortedCols = function (field, direction) {\n var fields = this.getCurrentSortedFields();\n var index = fields.indexOf(field);\n if (this.parent.allowMultiSorting && index > -1) {\n this.sortedCols.splice(index, 1);\n this.sortPredicate.splice(index, 1);\n }\n this.isSortApplied = true;\n if (direction !== 'None') {\n this.sortedCols.push(field);\n this.sortPredicate.push({ field: field, direction: direction });\n }\n };\n ResponsiveDialogRenderer.prototype.getCurrentSortedFields = function () {\n var fields = [];\n for (var i = 0; i < this.sortedCols.length; i++) {\n fields.push(this.sortedCols[parseInt(i.toString(), 10)]);\n }\n return fields;\n };\n ResponsiveDialogRenderer.prototype.customFilterColumnClickHandler = function (e) {\n var gObj = this.parent;\n var target = e.target;\n if (parentsUntil(target, 'columnmenudiv') && this.action === ResponsiveDialogAction.isColMenu && !parentsUntil(target, 'e-disabled')) {\n var column = this.menuCol ? this.menuCol : this.filteredCol;\n if (parentsUntil(target, 'e-responsiveautofitalldiv')) {\n gObj.autoFitColumns([]);\n this.closeCustomFilter();\n }\n else if (parentsUntil(target, 'e-responsiveautofitdiv')) {\n gObj.autoFitColumns(column.field);\n this.closeCustomFilter();\n }\n else if (parentsUntil(target, 'e-responsivegroupdiv')) {\n gObj.groupColumn(column.field);\n this.closeCustomFilter();\n }\n else if (parentsUntil(target, 'e-responsiveungroupdiv')) {\n gObj.ungroupColumn(column.field);\n this.closeCustomFilter();\n }\n else if (parentsUntil(target, 'e-responsiveascendingdiv')) {\n gObj.sortColumn(column.field, 'Ascending');\n this.closeCustomFilter();\n }\n else if (parentsUntil(target, 'e-responsivedescendingdiv')) {\n gObj.sortColumn(column.field, 'Descending');\n this.closeCustomFilter();\n }\n else if (parentsUntil(target, 'e-responsivecolumndiv')) {\n gObj.notify(events.renderResponsiveChangeAction, { action: 5 });\n gObj.showResponsiveCustomColumnChooser();\n }\n else if (parentsUntil(target, 'e-responsivefilterdiv')) {\n gObj.notify(events.renderResponsiveChangeAction, { action: 3 });\n this.isRowResponsive = true;\n this.isCustomDialog = false;\n if (gObj.filterModule) {\n gObj.filterModule.responsiveDialogRenderer.showResponsiveDialog(column);\n }\n }\n e.preventDefault();\n }\n if (this.action !== ResponsiveDialogAction.isFilter) {\n return;\n }\n if (gObj.filterSettings.type !== 'FilterBar') {\n if (target.classList.contains('e-responsivecoldiv') || target.parentElement.classList.contains('e-responsivecoldiv')) {\n var field = target.getAttribute('data-e-mappingname');\n if (!field) {\n field = target.parentElement.getAttribute('data-e-mappingname');\n }\n if (field) {\n var col = gObj.getColumnByField(field);\n this.isRowResponsive = true;\n this.showResponsiveDialog(col);\n }\n }\n else if (target.classList.contains('e-filterset') || target.parentElement.classList.contains('e-filtersetdiv')) {\n var colDiv = parentsUntil(target, 'e-responsivecoldiv');\n if (colDiv) {\n var field = colDiv.getAttribute('data-e-mappingname');\n var col = gObj.getColumnByField(field);\n if (col.filter.type === 'Menu' || (!col.filter.type && gObj.filterSettings.type === 'Menu')) {\n this.isDialogClose = true;\n }\n this.parent.filterModule.filterModule.clearCustomFilter(col);\n this.removeCustomDlgFilterEle(target);\n }\n }\n }\n };\n /**\n * Function to show the responsive dialog\n *\n * @param {Column} col - specifies the filter column\n * @param {Column} column - specifies the menu column\n * @returns {void}\n */\n ResponsiveDialogRenderer.prototype.showResponsiveDialog = function (col, column) {\n if ((this.isCustomDialog && this.action === ResponsiveDialogAction.isFilter && !this.isRowResponsive) ||\n (column && this.action === ResponsiveDialogAction.isColMenu)) {\n this.menuCol = column;\n this.renderCustomFilterDialog(null, column);\n }\n else {\n this.filteredCol = col;\n this.renderResponsiveDialog(col);\n if (this.parent.enableAdaptiveUI && col) {\n this.parent.filterModule.setFilterModel(col);\n this.parent.filterModule.filterModule.openDialog(this.parent.filterModule.createOptions(col, undefined));\n }\n if (this.action === ResponsiveDialogAction.isColumnChooser) {\n this.parent.notify(events.renderResponsiveColumnChooserDiv, { action: 'open' });\n }\n if (this.action === ResponsiveDialogAction.isSort) {\n var args = {\n cancel: false, dialogObj: this.customResponsiveDlg, requestType: 'beforeOpenAptiveSortDialog'\n };\n this.parent.trigger(events.beforeOpenAdaptiveDialog, args);\n if (args.cancel) {\n return;\n }\n }\n this.customResponsiveDlg.show(true);\n this.customResponsiveDlg.element.style.maxHeight = '100%';\n this.setTopToChildDialog(this.customResponsiveDlg.element);\n }\n };\n ResponsiveDialogRenderer.prototype.setTopToChildDialog = function (dialogEle) {\n var child = dialogEle.querySelector('.e-dialog');\n if (child) {\n var top_1 = dialogEle.querySelector('.e-dlg-header-content').getBoundingClientRect().height;\n child.style.top = top_1 + 'px';\n }\n };\n ResponsiveDialogRenderer.prototype.renderCustomFilterDialog = function (col, column) {\n var gObj = this.parent;\n var isColMenu = this.action === ResponsiveDialogAction.isColMenu;\n if (this.action === ResponsiveDialogAction.isFilter && gObj.filterSettings.type === 'FilterBar') {\n return;\n }\n var colMenu = isColMenu ? 'e-customcolumnmenudiv ' : '';\n var outerDiv = this.parent.createElement('div', {\n id: gObj.element.id + (isColMenu ? 'customcolumnmenu' : 'customfilter'),\n className: this.parent.cssClass ? colMenu +\n 'e-customfilterdiv e-responsive-dialog ' + this.parent.cssClass : colMenu + 'e-customfilterdiv e-responsive-dialog'\n });\n this.parent.element.appendChild(outerDiv);\n this.customFilterDlg = this.getDialogOptions(col, true, null, column);\n var args = {\n cancel: false, dialogObj: this.customFilterDlg, requestType: 'beforeOpenAptiveFilterDialog'\n };\n this.parent.trigger(events.beforeOpenAdaptiveDialog, args);\n if (args.cancel) {\n return;\n }\n this.customFilterDlg.appendTo(outerDiv);\n this.customFilterDlg.show(true);\n this.customFilterDlg.element.style.maxHeight = '100%';\n };\n ResponsiveDialogRenderer.prototype.getDialogOptions = function (col, isCustomFilter, id, column) {\n var options = new Dialog({\n isModal: true,\n showCloseIcon: true,\n closeOnEscape: false,\n locale: this.parent.locale,\n target: this.parent.adaptiveDlgTarget ? this.parent.adaptiveDlgTarget : document.body,\n visible: false,\n enableRtl: this.parent.enableRtl,\n content: this.renderResponsiveContent(col, column),\n open: this.dialogOpen.bind(this),\n created: this.dialogCreated.bind(this),\n close: this.beforeDialogClose.bind(this),\n width: '100%',\n height: '100%',\n animationSettings: { effect: 'None' },\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n var isStringTemplate = 'isStringTemplate';\n options[\"\" + isStringTemplate] = true;\n if (isCustomFilter) {\n options.header = this.renderResponsiveHeader(col, undefined, true);\n var colMenu = this.action === ResponsiveDialogAction.isColMenu ? 'e-customcolumnmenu ' : '';\n options.cssClass = colMenu + 'e-customfilter';\n }\n else {\n options.header = this.renderResponsiveHeader(col);\n options.cssClass = this.parent.rowRenderingMode === 'Vertical' && this.action === ResponsiveDialogAction.isFilter\n ? 'e-res' + id + ' e-row-responsive-filter' : 'e-res' + id;\n }\n return options;\n };\n ResponsiveDialogRenderer.prototype.renderResponsiveDialog = function (col) {\n var gObj = this.parent;\n if (this.action === ResponsiveDialogAction.isFilter && gObj.filterSettings.type === 'FilterBar') {\n return;\n }\n var id = this.action === ResponsiveDialogAction.isFilter ? 'filter' : 'sort';\n id = this.action === ResponsiveDialogAction.isColumnChooser ? 'columnchooser' : id;\n var outerDiv = this.parent.createElement('div', {\n id: gObj.element.id + 'responsive' + id,\n className: this.parent.cssClass ?\n 'e-res' + id + 'div e-responsive-dialog ' + this.parent.cssClass : 'e-res' + id + 'div e-responsive-dialog'\n });\n this.parent.element.appendChild(outerDiv);\n this.customResponsiveDlg = this.getDialogOptions(col, false, id);\n this.customResponsiveDlg.appendTo(outerDiv);\n };\n ResponsiveDialogRenderer.prototype.dialogCreated = function () {\n addBiggerDialog(this.parent);\n };\n ResponsiveDialogRenderer.prototype.dialogOpen = function () {\n if (this.action === ResponsiveDialogAction.isSort && this.parent.allowMultiSorting) {\n for (var i = 0; i < this.parent.sortSettings.columns.length; i++) {\n this.sortedCols.push(this.parent.sortSettings.columns[parseInt(i.toString(), 10)].field);\n var sortField = this.parent.sortSettings.columns[parseInt(i.toString(), 10)].field;\n var sortDirection = this.parent.sortSettings.columns[parseInt(i.toString(), 10)].direction;\n this.sortPredicate.push({ field: sortField, direction: sortDirection });\n }\n }\n };\n ResponsiveDialogRenderer.prototype.beforeDialogClose = function (args) {\n this.isDialogClose = args.element && !args.element.querySelector('.e-xl-customfilterdiv')\n && args.element.classList.contains('e-resfilterdiv');\n if (this.action === ResponsiveDialogAction.isFilter) {\n if (args.element.classList.contains('e-resfilterdiv')) {\n this.parent.filterModule.filterModule.closeResponsiveDialog(this.isCustomDlgRender);\n }\n else if (args.element.classList.contains('e-customfilterdiv')) {\n this.closeCustomFilter();\n }\n if (this.parent.rowRenderingMode === 'Horizontal' && this.parent.showColumnMenu) {\n this.parent.notify(events.renderResponsiveChangeAction, { action: 4 });\n var custom = document.querySelector('.e-resfilter');\n if (custom) {\n remove(custom);\n }\n }\n }\n else if (this.action === ResponsiveDialogAction.isSort) {\n this.closeCustomDialog();\n }\n else if (this.action === ResponsiveDialogAction.isColMenu) {\n this.closeCustomFilter();\n var custom = document.querySelector('.e-rescolummenu');\n if (custom) {\n remove(custom);\n }\n }\n else if (this.action === ResponsiveDialogAction.isColumnChooser) {\n this.parent.notify(events.renderResponsiveColumnChooserDiv, { action: 'clear' });\n var custom = document.querySelector('.e-rescolumnchooser');\n if (custom) {\n remove(custom);\n }\n if (this.parent.rowRenderingMode === 'Horizontal' && this.parent.showColumnMenu) {\n this.parent.notify(events.renderResponsiveChangeAction, { action: 4 });\n }\n this.isCustomDialog = false;\n this.isDialogClose = false;\n }\n this.parent.off(events.enterKeyHandler, this.keyHandler);\n };\n ResponsiveDialogRenderer.prototype.sortColumn = function () {\n if (!this.isSortApplied) {\n this.closeCustomDialog();\n return;\n }\n if (this.sortPredicate.length) {\n this.parent.setProperties({ sortSettings: { columns: [] } }, true);\n }\n for (var i = 0; i < this.sortPredicate.length; i++) {\n this.parent.sortColumn(this.sortPredicate[parseInt(i.toString(), 10)].field, this.sortPredicate[parseInt(i.toString(), 10)].direction, this.parent.allowMultiSorting);\n }\n if (!this.sortPredicate.length) {\n this.parent.clearSorting();\n }\n this.closeCustomDialog();\n };\n ResponsiveDialogRenderer.prototype.getHeaderTitle = function (args, col) {\n var gObj = this.parent;\n var title;\n if (this.action === ResponsiveDialogAction.isEdit) {\n title = gObj.localeObj.getConstant('EditFormTitle') + args.primaryKeyValue[0];\n }\n else if (this.action === ResponsiveDialogAction.isAdd) {\n title = gObj.localeObj.getConstant('AddFormTitle');\n }\n else if (this.action === ResponsiveDialogAction.isFilter) {\n title = col ? col.headerText || col.field : gObj.localeObj.getConstant('FilterButton');\n }\n else if (this.action === ResponsiveDialogAction.isSort) {\n title = gObj.localeObj.getConstant('Sort');\n }\n else if (this.action === ResponsiveDialogAction.isColMenu) {\n title = gObj.localeObj.getConstant('ColumnMenu');\n }\n else if (this.action === ResponsiveDialogAction.isColumnChooser) {\n title = gObj.localeObj.getConstant('ChooseColumns');\n }\n return title;\n };\n ResponsiveDialogRenderer.prototype.getDialogName = function (action) {\n var name;\n if (action === ResponsiveDialogAction.isAdd || action === ResponsiveDialogAction.isEdit) {\n name = 'dialogEdit_wrapper_title';\n }\n else if (action === ResponsiveDialogAction.isFilter) {\n name = 'responsive_filter_dialog_wrapper';\n }\n else if (action === ResponsiveDialogAction.isColumnChooser) {\n name = 'responsive_column_chooser_dialog_wrapper';\n }\n return name;\n };\n ResponsiveDialogRenderer.prototype.getButtonText = function (action) {\n var text;\n if (action === ResponsiveDialogAction.isAdd || action === ResponsiveDialogAction.isEdit) {\n text = 'Save';\n }\n else if (action === ResponsiveDialogAction.isFilter || this.action === ResponsiveDialogAction.isSort ||\n action === ResponsiveDialogAction.isColumnChooser || this.action === ResponsiveDialogAction.isColumnChooser) {\n text = 'OKButton';\n }\n return text;\n };\n /**\n * Function to render the responsive header\n *\n * @param {Column} col - specifies the column\n * @param {ResponsiveDialogArgs} args - specifies the responsive dialog arguments\n * @param {boolean} isCustomFilter - specifies whether it is custom filter or not\n * @returns {HTMLElement | string} returns the html element or string\n */\n ResponsiveDialogRenderer.prototype.renderResponsiveHeader = function (col, args, isCustomFilter) {\n var _this = this;\n var gObj = this.parent;\n gObj.on(events.enterKeyHandler, this.keyHandler, this);\n var id = gObj.element.id + this.getDialogName(this.action);\n var header = gObj.createElement('div', { className: 'e-res-custom-element' });\n var titleDiv = gObj.createElement('div', { className: 'e-dlg-custom-header', id: id });\n titleDiv.innerHTML = this.getHeaderTitle(args, col);\n header.appendChild(titleDiv);\n var saveBtn = gObj.createElement('button');\n if (!isCustomFilter) {\n this.saveBtn = new Button({\n cssClass: this.parent.cssClass ?\n 'e-primary e-flat e-res-apply-btn' + ' ' + this.parent.cssClass : 'e-primary e-flat e-res-apply-btn'\n });\n saveBtn.innerHTML = gObj.localeObj.getConstant(this.getButtonText(this.action));\n this.saveBtn.appendTo(saveBtn);\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n saveBtn.onclick = function (e) {\n _this.dialogHdrBtnClickHandler();\n };\n }\n var isSort = this.action === ResponsiveDialogAction.isSort;\n var isFilter = this.action === ResponsiveDialogAction.isFilter;\n if (isFilter || isSort) {\n var id_1 = isSort ? 'sort' : 'filter';\n var clearBtn = gObj.createElement('button');\n this.filterClearBtn = new Button({\n cssClass: this.parent.cssClass ? 'e-primary e-flat e-res-' + id_1 + '-clear-btn' + ' ' + this.parent.cssClass\n : 'e-primary e-flat e-res-' + id_1 + '-clear-btn'\n });\n if (isFilter) {\n var span = gObj.createElement('span', { className: 'e-btn-icon e-icon-filter-clear e-icons' });\n clearBtn.appendChild(span);\n }\n else {\n clearBtn.innerHTML = gObj.localeObj.getConstant('Clear');\n }\n header.appendChild(clearBtn);\n this.filterClearBtn.appendTo(clearBtn);\n clearBtn.onclick = function (e) {\n if ((parentsUntil(e.target, 'e-customfilter'))) {\n _this.parent.filterModule.clearFiltering();\n _this.removeCustomDlgFilterEle();\n }\n else {\n if (isFilter) {\n _this.filterClear();\n }\n else {\n _this.resetSortButtons();\n _this.sortedCols = [];\n _this.sortPredicate = [];\n _this.isSortApplied = true;\n }\n }\n };\n header.appendChild(clearBtn);\n }\n if (!isCustomFilter) {\n header.appendChild(saveBtn);\n }\n return header;\n };\n ResponsiveDialogRenderer.prototype.filterClear = function () {\n this.parent.filterModule.filterModule.clearCustomFilter(this.filteredCol);\n this.parent.filterModule.filterModule.closeResponsiveDialog();\n };\n ResponsiveDialogRenderer.prototype.removeCustomFilterElement = function () {\n var elem = document.getElementById(this.parent.element.id + 'customcolumnmenu');\n if (elem) {\n remove(elem);\n var custom = document.querySelector('.e-customfilter');\n if (custom) {\n remove(custom);\n }\n }\n var custommenu = document.querySelector('.e-rescolumnchooser');\n if (custommenu) {\n remove(custommenu);\n }\n };\n ResponsiveDialogRenderer.prototype.dialogHdrBtnClickHandler = function () {\n if (this.action === ResponsiveDialogAction.isEdit || this.action === ResponsiveDialogAction.isAdd) {\n this.parent.endEdit();\n }\n else if (this.action === ResponsiveDialogAction.isFilter) {\n this.parent.filterModule.filterModule.applyCustomFilter({ col: this.filteredCol, isCustomFilter: this.isCustomDlgRender });\n this.removeCustomFilterElement();\n }\n else if (this.action === ResponsiveDialogAction.isSort) {\n this.sortColumn();\n this.removeCustomFilterElement();\n }\n else if (this.action === ResponsiveDialogAction.isColumnChooser) {\n this.parent.notify(events.renderResponsiveColumnChooserDiv, { action: 'confirm' });\n this.removeCustomFilterElement();\n this.isCustomDialog = false;\n this.isDialogClose = false;\n }\n };\n ResponsiveDialogRenderer.prototype.closeCustomDialog = function () {\n if (this.isCustomDlgRender) {\n var mainfilterdiv = this.customResponsiveDlg.element.querySelector('.e-mainfilterdiv');\n remove(mainfilterdiv);\n return;\n }\n this.isRowResponsive = false;\n this.isCustomDlgRender = false;\n this.destroyCustomFilterDialog();\n };\n ResponsiveDialogRenderer.prototype.destroyCustomFilterDialog = function () {\n if (!this.customResponsiveDlg) {\n return;\n }\n var elem = document.getElementById(this.customResponsiveDlg.element.id);\n if (this.customResponsiveDlg && !this.customResponsiveDlg.isDestroyed && elem) {\n this.customResponsiveDlg.destroy();\n remove(elem);\n }\n this.closeCustomFilter();\n if (this.action === ResponsiveDialogAction.isSort) {\n this.sortPredicate = [];\n this.sortedCols = [];\n this.isSortApplied = false;\n }\n };\n ResponsiveDialogRenderer.prototype.closeCustomFilter = function () {\n if (!this.isDialogClose && this.customFilterDlg) {\n var customEle = document.getElementById(this.customFilterDlg.element.id);\n if (this.customFilterDlg && !this.customFilterDlg.isDestroyed && customEle) {\n this.customFilterDlg.destroy();\n remove(customEle);\n }\n }\n this.isCustomDialog = false;\n this.isDialogClose = false;\n };\n ResponsiveDialogRenderer.prototype.removeCustomDlgFilterEle = function (target) {\n if (target) {\n if (target.parentElement.classList.contains('e-filtersetdiv')) {\n remove(target.parentElement);\n }\n else {\n remove(target);\n }\n }\n else {\n var child = this.customColumnDiv.children;\n for (var i = 0; i < child.length; i++) {\n target = child[parseInt(i.toString(), 10)].querySelector('.e-filtersetdiv');\n if (target) {\n remove(target);\n i--;\n }\n }\n }\n };\n ResponsiveDialogRenderer.prototype.keyHandler = function (e) {\n if (e.keyCode === 13 && ((this.action === ResponsiveDialogAction.isFilter\n && e.target.classList.contains('e-searchinput'))\n || (this.action === ResponsiveDialogAction.isEdit || this.action === ResponsiveDialogAction.isAdd))) {\n this.dialogHdrBtnClickHandler();\n }\n };\n ResponsiveDialogRenderer.prototype.editComplate = function (args) {\n if (args.requestType === 'save' || args.requestType === 'cancel') {\n this.parent.off(events.enterKeyHandler, this.keyHandler);\n }\n };\n ResponsiveDialogRenderer.prototype.removeEventListener = function () {\n if (this.customColumnDiv) {\n EventHandler.remove(this.customColumnDiv, Browser.isDevice ? 'touchend' : 'click', this.customFilterColumnClickHandler);\n }\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n this.parent.removeEventListener(events.actionComplete, this.onActionCompleteFn);\n };\n return ResponsiveDialogRenderer;\n}());\nexport { ResponsiveDialogRenderer };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable @typescript-eslint/no-unused-vars */\nimport { extend, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { ChartLocation } from '../../common/utils/helper';\nimport { stopTimer, removeElement } from '../../common/utils/helper';\nimport { ChartData } from '../../chart/utils/get-data';\nimport { Tooltip as SVGTooltip } from '@syncfusion/ej2-svg-base';\n/**\n * Tooltip Module used to render the tooltip for series.\n */\nvar BaseTooltip = /** @class */ (function (_super) {\n __extends(BaseTooltip, _super);\n /**\n * Constructor for tooltip module.\n *\n * @private\n */\n function BaseTooltip(chart) {\n var _this = _super.call(this, chart) || this;\n _this.element = _this.chart.element;\n _this.textStyle = chart.tooltip.textStyle;\n _this.control = chart;\n _this.template = chart.tooltip.template;\n return _this;\n }\n BaseTooltip.prototype.getElement = function (id) {\n return document.getElementById(id);\n };\n /**\n * Renders the tooltip.\n *\n * @returns {void}\n * @private\n */\n BaseTooltip.prototype.getTooltipElement = function (isTooltip) {\n this.inverted = this.chart.requireInvertedAxis;\n this.header = (this.control.tooltip.header === null) ?\n ((this.control.tooltip.shared) ? '${point.x}' : '${series.name}')\n : (this.control.tooltip.header);\n this.formattedText = [];\n var tooltipDiv = document.getElementById(this.chart.element.id + '_tooltip');\n var isStockChart = this.chart.element.id.indexOf('stockChart') > -1;\n if (!isTooltip && !tooltipDiv || isStockChart) {\n return this.createElement();\n }\n return null;\n };\n BaseTooltip.prototype.createElement = function () {\n var tooltipDiv = document.createElement('div');\n tooltipDiv.id = this.element.id + '_tooltip';\n tooltipDiv.className = 'ejSVGTooltip';\n tooltipDiv.style.pointerEvents = 'none';\n tooltipDiv.style.position = 'absolute';\n tooltipDiv.style.zIndex = '1';\n return tooltipDiv;\n };\n BaseTooltip.prototype.pushData = function (data, isFirst, tooltipDiv, isChart, enable3D) {\n if (data.series.enableTooltip) {\n if (enable3D) {\n this.currentPoints.push(data);\n }\n else if (isChart) {\n this.currentPoints.push(data);\n }\n else {\n this.currentPoints.push(data);\n }\n this.stopAnimation();\n if (tooltipDiv && !document.getElementById(tooltipDiv.id)) {\n if (!this.chart.stockChart) {\n document.getElementById(this.element.id + '_Secondary_Element').appendChild(tooltipDiv);\n }\n else {\n document.getElementById(this.chart.stockChart.element.id + '_Secondary_Element').appendChild(tooltipDiv);\n }\n }\n return true;\n }\n return false;\n };\n BaseTooltip.prototype.removeHighlight = function () {\n var item;\n var series;\n for (var i = 0, len = this.previousPoints.length; i < len; i++) {\n item = this.previousPoints[i];\n if (item.series.isRectSeries) {\n if (item.series.visible) {\n this.highlightPoint(item.series, item.point.index, false);\n }\n continue;\n }\n series = item.series;\n }\n };\n BaseTooltip.prototype.highlightPoint = function (series, pointIndex, highlight) {\n var element = this.getElement(this.element.id + '_Series_' + series.index + '_Point_' + pointIndex);\n var selectionModule = this.control.accumulationSelectionModule;\n var isSelectedElement = selectionModule && selectionModule.selectedDataIndexes.length > 0 ? true : false;\n if (element) {\n if ((!isSelectedElement || isSelectedElement && element.getAttribute('class')\n && element.getAttribute('class').indexOf('_ej2_chart_selection_series_') === -1)) {\n if (this.chart.highlightColor !== '' && !isNullOrUndefined(this.chart.highlightColor)) {\n element.setAttribute('fill', (highlight && this.chart.highlightColor !== 'transparent' ? this.chart.highlightColor : series.pointColorMapping !== '' ? (series.points[0]).color : series.points[pointIndex].color || series.interior));\n }\n else {\n element.setAttribute('opacity', (highlight && this.chart.highlightColor !== 'transparent' ? series.opacity / 2 : series.opacity).toString());\n }\n }\n else {\n element.setAttribute('opacity', series.opacity.toString());\n }\n }\n };\n BaseTooltip.prototype.highlightPoints = function () {\n for (var _i = 0, _a = this.currentPoints; _i < _a.length; _i++) {\n var item = _a[_i];\n if (item.series.isRectSeries && item.series.category === 'Series') {\n this.highlightPoint(item.series, item.point.index, true);\n }\n }\n };\n // tslint:disable-next-line:max-func-body-length\n BaseTooltip.prototype.createTooltip = function (chart, isFirst, location, clipLocation, point, shapes, offset, bounds, crosshairEnabled, extraPoints, templatePoint, customTemplate) {\n if (crosshairEnabled === void 0) { crosshairEnabled = false; }\n if (extraPoints === void 0) { extraPoints = null; }\n if (templatePoint === void 0) { templatePoint = null; }\n var series = this.currentPoints[0].series;\n var module = chart.tooltipModule || chart.tooltip3DModule ||\n chart.accumulationTooltipModule;\n if (!module || location === null) { // For the tooltip enable is false.\n removeElement(this.chart.element.id + '_tooltip');\n return;\n }\n if (isFirst) {\n this.svgTooltip = new SVGTooltip({\n opacity: chart.tooltip.opacity ? chart.tooltip.opacity : ((this.chart.theme === 'Material3' || this.chart.theme === 'Material3Dark') ? 1 : 0.75),\n header: this.headerText,\n content: this.text,\n fill: chart.tooltip.fill,\n border: chart.tooltip.border,\n enableAnimation: chart.tooltip.enableAnimation,\n location: location,\n shared: this.control.tooltip.shared,\n crosshair: crosshairEnabled,\n shapes: shapes,\n clipBounds: this.chart.chartAreaType === 'PolarRadar' ? new ChartLocation(0, 0) : clipLocation,\n areaBounds: bounds,\n palette: this.findPalette(),\n template: customTemplate || this.template,\n data: templatePoint,\n theme: chart.theme,\n offset: offset,\n textStyle: chart.tooltip.textStyle,\n isNegative: (series.isRectSeries && series.type !== 'Waterfall' && point && point.y < 0),\n inverted: this.chart.requireInvertedAxis && series.isRectSeries,\n arrowPadding: this.text.length > 1 || this.chart.stockChart || (this.chart.tooltip.location.x !== null || this.chart.tooltip.location.y !== null) ? 0 : 7,\n availableSize: chart.availableSize,\n duration: this.chart.tooltip.duration,\n isCanvas: this.chart.enableCanvas,\n isFixed: (this.chart.tooltip.location.x !== null || this.chart.tooltip.location.y !== null),\n isTextWrap: chart.tooltip.enableTextWrap && chart.getModuleName() === 'chart',\n blazorTemplate: { name: 'Template', parent: this.chart.tooltip },\n controlInstance: this.chart,\n enableRTL: chart.enableRtl,\n controlName: 'Chart',\n allowHighlight: chart.getModuleName() === 'chart' && !series.marker.allowHighlight,\n tooltipRender: function () {\n module.removeHighlight();\n module.highlightPoints();\n module.updatePreviousPoint(extraPoints);\n },\n animationComplete: function (args) {\n if (args.tooltip.fadeOuted) {\n module.fadeOut(module.previousPoints);\n }\n }\n });\n this.svgTooltip.appendTo(this.getElement(this.element.id + '_tooltip'));\n }\n else {\n if (this.svgTooltip) {\n this.svgTooltip.location = location;\n this.svgTooltip.content = this.text;\n this.svgTooltip.header = this.headerText;\n this.svgTooltip.offset = offset;\n this.svgTooltip.palette = this.findPalette();\n this.svgTooltip.shapes = shapes;\n this.svgTooltip.data = templatePoint;\n this.svgTooltip.template = this.template;\n this.svgTooltip.controlName = 'Chart';\n this.svgTooltip.crosshair = crosshairEnabled;\n this.svgTooltip.textStyle = chart.tooltip.textStyle;\n this.svgTooltip.isNegative = (series.isRectSeries && series.type !== 'Waterfall' && point && point.y < 0);\n this.svgTooltip.clipBounds = this.chart.chartAreaType === 'PolarRadar' ? new ChartLocation(0, 0) : clipLocation;\n this.svgTooltip.arrowPadding = this.text.length > 1 || this.chart.stockChart || (this.chart.tooltip.location.x !== null || this.chart.tooltip.location.y !== null) ? 0 : 7;\n this.svgTooltip.allowHighlight = chart.getModuleName() === 'chart' && !series.marker.allowHighlight;\n this.svgTooltip.dataBind();\n }\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this.chart.isReact) {\n this.chart.renderReactTemplates();\n }\n };\n BaseTooltip.prototype.findPalette = function () {\n var colors = [];\n for (var _i = 0, _a = this.currentPoints; _i < _a.length; _i++) {\n var data = _a[_i];\n colors.push(this.findColor(data, data.series));\n }\n return colors;\n };\n BaseTooltip.prototype.findColor = function (data, series) {\n if (series.isRectSeries && (series.type === 'Candle' || series.type === 'Hilo' || series.type === 'HiloOpenClose')) {\n return data.point.color;\n }\n else {\n return (data.point.color && data.point.color !== '#ffffff' ? data.point.color\n : data.point.interior) ||\n series.marker.fill || series.interior;\n }\n };\n BaseTooltip.prototype.updatePreviousPoint = function (extraPoints) {\n if (extraPoints) {\n this.currentPoints = this.currentPoints.concat(extraPoints);\n }\n this.previousPoints = extend([], this.currentPoints, null, true);\n };\n BaseTooltip.prototype.fadeOut = function (data) {\n var svgElement = this.chart.enableCanvas ? this.getElement(this.element.id + '_tooltip_group') :\n this.getElement(this.element.id + '_tooltip_svg');\n var isTooltip = (svgElement && parseInt(svgElement.getAttribute('opacity'), 10) > 0);\n if (!isTooltip) {\n this.valueX = null;\n this.valueY = null;\n this.currentPoints = [];\n this.removeHighlight();\n this.removeHighlightedMarker(data, true);\n this.svgTooltip = null;\n this.control.trigger('animationComplete', {});\n }\n };\n /*\n * @hidden\n */\n BaseTooltip.prototype.removeHighlightedMarker = function (data, fadeOut) {\n if (this.chart.markerRender) {\n for (var _i = 0, data_1 = data; _i < data_1.length; _i++) {\n var item = data_1[_i];\n removeElement(this.element.id + '_Series_' + item.series.index +\n '_Point_' + item.point.index + '_Trackball');\n this.chart.markerRender.removeHighlightedMarker(item.series, item.point, fadeOut);\n }\n }\n this.previousPoints = [];\n };\n // public triggerEvent(point: PointData | AccPointData, isFirst: boolean, textCollection: string, firstText: boolean = true): boolean {\n // let argsData: ITooltipRenderEventArgs = {\n // cancel: false, name: tooltipRender, text: textCollection,\n // point: point.point, series: point.series, textStyle: this.textStyle\n // };\n // this.chart.trigger(tooltipRender, argsData);\n // if (!argsData.cancel) {\n // if (point.series.type === 'BoxAndWhisker') {\n // this.removeText();\n // isFirst = true;\n // }\n // this.formattedText = this.formattedText.concat(argsData.text);\n // this.text = this.formattedText;\n // }\n // return !argsData.cancel;\n // }\n BaseTooltip.prototype.removeText = function () {\n this.textElements = [];\n var element = this.getElement(this.element.id + '_tooltip_group');\n if (element && element.childNodes.length > 0) {\n while (element.lastChild && element.childNodes.length !== 1) {\n element.removeChild(element.lastChild);\n }\n }\n };\n BaseTooltip.prototype.stopAnimation = function () {\n stopTimer(this.toolTipInterval);\n };\n /**\n * Removes the tooltip on mouse leave.\n *\n * @returns {void}\n * @private\n */\n BaseTooltip.prototype.removeTooltip = function (duration) {\n var _this = this;\n var tooltipElement = this.getElement(this.element.id + '_tooltip');\n var tooltipTemplate = tooltipElement ? this.getElement(tooltipElement.id + 'parent_template') : null;\n var isTemplateRendered = tooltipTemplate && tooltipTemplate.innerText !== '<div></div>';\n this.stopAnimation();\n if (tooltipElement && this.previousPoints.length > 0) {\n this.toolTipInterval = +setTimeout(function () {\n if (_this.svgTooltip) {\n _this.svgTooltip.fadeOut();\n }\n }, duration);\n }\n };\n return BaseTooltip;\n}(ChartData));\nexport { BaseTooltip };\n","import { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { EventHandler } from '@syncfusion/ej2-base';\nimport { attributes, createElement, classList, append } from '@syncfusion/ej2-base';\n/**\n * `NumericContainer` module handles rendering and refreshing numeric container.\n */\nvar NumericContainer = /** @class */ (function () {\n /**\n * Constructor for numericContainer module\n *\n * @param {Pager} pagerModule - specifies the pagerModule\n * @hidden\n */\n function NumericContainer(pagerModule) {\n this.pagerModule = pagerModule;\n }\n /**\n * The function is used to render numericContainer\n *\n * @returns {void}\n * @hidden\n */\n NumericContainer.prototype.render = function () {\n this.pagerElement = this.pagerModule.element;\n this.renderNumericContainer();\n this.refreshNumericLinks();\n this.wireEvents();\n };\n /**\n * Refreshes the numeric container of Pager.\n *\n * @returns {void}\n */\n NumericContainer.prototype.refresh = function () {\n this.pagerModule.updateTotalPages();\n if (this.links.length) {\n this.updateLinksHtml();\n }\n this.refreshAriaAttrLabel();\n this.updateStyles();\n };\n /**\n * The function is used to refresh refreshNumericLinks\n *\n * @returns {void}\n * @hidden\n */\n NumericContainer.prototype.refreshNumericLinks = function () {\n var link;\n var pagerObj = this.pagerModule;\n var div = pagerObj.element.querySelector('.e-numericcontainer');\n var frag = document.createDocumentFragment();\n div.innerHTML = '';\n for (var i = 1; i <= pagerObj.pageCount; i++) {\n link = createElement('a', {\n className: 'e-link e-numericitem e-spacing e-pager-default',\n attrs: { tabindex: '-1', 'aria-label': pagerObj.getLocalizedLabel('Page') + i + pagerObj.getLocalizedLabel('Of') +\n pagerObj.totalPages + pagerObj.getLocalizedLabel('Pages'), href: '#' }\n });\n if (pagerObj.currentPage === i) {\n classList(link, ['e-currentitem', 'e-active'], ['e-pager-default']);\n link.setAttribute('aria-current', 'page');\n }\n frag.appendChild(link);\n }\n div.appendChild(frag);\n this.links = [].slice.call(div.childNodes);\n };\n /**\n * Binding events to the element while component creation\n *\n * @returns {void}\n * @hidden\n */\n NumericContainer.prototype.wireEvents = function () {\n EventHandler.add(this.pagerElement, 'click', this.clickHandler, this);\n EventHandler.add(this.pagerElement, 'auxclick', this.auxiliaryClickHandler, this);\n };\n /**\n * Unbinding events from the element while component destroy\n *\n * @returns {void}\n * @hidden\n */\n NumericContainer.prototype.unwireEvents = function () {\n EventHandler.remove(this.pagerModule.element, 'click', this.clickHandler);\n EventHandler.remove(this.pagerModule.element, 'auxclick', this.auxiliaryClickHandler);\n };\n /**\n * To destroy the PagerMessage\n *\n * @function destroy\n * @returns {void}\n * @hidden\n */\n NumericContainer.prototype.destroy = function () {\n this.unwireEvents();\n };\n NumericContainer.prototype.refreshAriaAttrLabel = function () {\n var pagerObj = this.pagerModule;\n var numericContainer = pagerObj.element.querySelector('.e-numericcontainer');\n var links = numericContainer.querySelectorAll('a');\n for (var i = 0; i < links.length; i++) {\n if (links[parseInt(i.toString(), 10)].hasAttribute('aria-label') && links[parseInt(i.toString(), 10)].hasAttribute('index')) {\n links[parseInt(i.toString(), 10)].setAttribute('aria-label', pagerObj.getLocalizedLabel('Page') + links[parseInt(i.toString(), 10)].getAttribute('index')\n + pagerObj.getLocalizedLabel('Of') + pagerObj.totalPages + pagerObj.getLocalizedLabel('Pages'));\n }\n }\n };\n NumericContainer.prototype.renderNumericContainer = function () {\n this.element = createElement('div', {\n className: 'e-pagercontainer', attrs: { 'role': 'navigation' }\n });\n this.renderFirstNPrev(this.element);\n this.renderPrevPagerSet(this.element);\n this.element.appendChild(createElement('div', { className: 'e-numericcontainer' }));\n this.renderNextPagerSet(this.element);\n this.renderNextNLast(this.element);\n this.pagerModule.element.appendChild(this.element);\n };\n NumericContainer.prototype.renderFirstNPrev = function (pagerContainer) {\n this.first = createElement('div', {\n className: 'e-first e-icons e-icon-first',\n attrs: {\n title: this.pagerModule.getLocalizedLabel('firstPageTooltip'),\n tabindex: '-1', role: 'button'\n }\n });\n this.prev = createElement('div', {\n className: 'e-prev e-icons e-icon-prev',\n attrs: {\n title: this.pagerModule.getLocalizedLabel('previousPageTooltip'),\n tabindex: '-1', role: 'button'\n }\n });\n append([this.first, this.prev], pagerContainer);\n };\n NumericContainer.prototype.renderPrevPagerSet = function (pagerContainer) {\n var prevPager = createElement('div');\n this.PP = createElement('a', {\n className: 'e-link e-pp e-spacing', innerHTML: '...',\n attrs: {\n title: this.pagerModule.getLocalizedLabel('previousPagerTooltip'),\n 'aria-label': this.pagerModule.getLocalizedLabel('previousPagerTooltip'),\n tabindex: '-1',\n href: '#'\n }\n });\n prevPager.appendChild(this.PP);\n pagerContainer.appendChild(prevPager);\n };\n NumericContainer.prototype.renderNextPagerSet = function (pagerContainer) {\n var nextPager = createElement('div');\n this.NP = createElement('a', {\n className: 'e-link e-np e-spacing',\n innerHTML: '...', attrs: {\n title: this.pagerModule.getLocalizedLabel('nextPagerTooltip'),\n 'aria-label': this.pagerModule.getLocalizedLabel('nextPagerTooltip'),\n tabindex: '-1',\n href: '#'\n }\n });\n nextPager.appendChild(this.NP);\n pagerContainer.appendChild(nextPager);\n };\n NumericContainer.prototype.renderNextNLast = function (pagerContainer) {\n this.next = createElement('div', {\n className: 'e-next e-icons e-icon-next',\n attrs: {\n title: this.pagerModule.getLocalizedLabel('nextPageTooltip'),\n tabindex: '-1', role: 'button'\n }\n });\n this.last = createElement('div', {\n className: 'e-last e-icons e-icon-last',\n attrs: {\n title: this.pagerModule.getLocalizedLabel('lastPageTooltip'),\n tabindex: '-1', role: 'button'\n }\n });\n append([this.next, this.last], pagerContainer);\n };\n NumericContainer.prototype.clickHandler = function (e) {\n var pagerObj = this.pagerModule;\n this.target = e.target;\n if (this.target.classList.contains('e-numericitem')) {\n e.preventDefault();\n }\n pagerObj.previousPageNo = pagerObj.currentPage;\n if (!this.target.classList.contains('e-disable') && !isNullOrUndefined(this.target.getAttribute('index'))) {\n pagerObj.currentPage = parseInt(this.target.getAttribute('index'), 10);\n pagerObj.dataBind();\n }\n return false;\n };\n NumericContainer.prototype.auxiliaryClickHandler = function (e) {\n this.target = e.target;\n if (this.target.classList.contains('e-numericitem') && (e.button === 1)) {\n e.preventDefault();\n }\n };\n NumericContainer.prototype.updateLinksHtml = function () {\n var pagerObj = this.pagerModule;\n var currentPageSet;\n var isLastSet;\n var pageNo;\n var numItems = this.pagerElement.querySelectorAll('.e-numericitem:not(.e-hide):not([style*=\"display: none\"]):not(.e-np):not(.e-pp)');\n pagerObj.currentPage = pagerObj.totalPages === 1 ? 1 : pagerObj.currentPage;\n if (pagerObj.currentPage > pagerObj.totalPages && pagerObj.totalPages) {\n pagerObj.currentPage = pagerObj.totalPages;\n }\n currentPageSet = parseInt((pagerObj.currentPage / pagerObj.pageCount).toString(), 10);\n if (pagerObj.currentPage % pagerObj.pageCount === 0 && currentPageSet > 0) {\n currentPageSet = currentPageSet - 1;\n }\n for (var i = 0; i < pagerObj.pageCount; i++) {\n if (pagerObj.isPagerResized) {\n var focusedItem = this.pagerElement.querySelector('.e-focus');\n var focusedorTarget = this.target ? this.target : focusedItem ? focusedItem : null;\n var prevFocused = false;\n var nextFocused = false;\n var firstFocused = false;\n var lastFocused = false;\n var numItemFocused = false;\n var npFocused = false;\n var ppFocused = false;\n if (focusedorTarget) {\n var classList_1 = focusedorTarget.classList;\n if (classList_1.contains('e-icons')) {\n switch (true) {\n case classList_1.contains('e-prev'):\n prevFocused = true;\n break;\n case classList_1.contains('e-next'):\n nextFocused = true;\n break;\n case classList_1.contains('e-first'):\n firstFocused = true;\n break;\n case classList_1.contains('e-last'):\n lastFocused = true;\n break;\n }\n }\n else if (classList_1.contains('e-numericitem')) {\n switch (true) {\n case classList_1.contains('e-np'):\n npFocused = true;\n break;\n case classList_1.contains('e-pp'):\n ppFocused = true;\n break;\n default:\n numItemFocused = classList_1.contains('e-numericitem');\n break;\n }\n }\n }\n isLastSet = lastFocused || (this.pagerModule.keyAction === 'End');\n numItems = this.pagerElement.querySelectorAll('.e-numericitem:not(.e-hide):not([style*=\"display: none\"]):not(.e-np):not(.e-pp)');\n var isPageAvailable = Array.from(numItems).some(function (item) { return parseInt(item.getAttribute('index'), 10) === pagerObj.currentPage; });\n //Setting pageNo to render based on key action or click action.\n if (firstFocused || this.pagerModule.keyAction === 'Home') {\n pageNo = 1 + i;\n }\n else if (lastFocused || this.pagerModule.keyAction === 'End') {\n pageNo = (currentPageSet * pagerObj.pageCount) + 1 + i;\n }\n else if (nextFocused || this.pagerModule.keyAction === 'ArrowRight' || prevFocused || this.pagerModule.keyAction === 'ArrowLeft') {\n if (isPageAvailable) {\n pageNo = parseInt(numItems[0].getAttribute('index'), 10) + i;\n }\n else if (prevFocused || this.pagerModule.keyAction === 'ArrowLeft') {\n pageNo = parseInt(this.PP.getAttribute('index'), 10) + i;\n }\n else {\n pageNo = pagerObj.currentPage + i;\n }\n }\n else if (npFocused || ppFocused) {\n pageNo = pagerObj.currentPage + i;\n }\n else if (numItemFocused) {\n pageNo = (parseInt(numItems[0].getAttribute('index'), 10) + i);\n }\n else {\n pageNo = (currentPageSet * pagerObj.pageCount) + 1 + i;\n }\n }\n else {\n pageNo = (currentPageSet * pagerObj.pageCount) + 1 + i;\n }\n if (pageNo <= pagerObj.totalPages) {\n this.links[parseInt(i.toString(), 10)].classList.remove('e-hide');\n this.links[parseInt(i.toString(), 10)].style.display = '';\n this.links[parseInt(i.toString(), 10)].setAttribute('index', pageNo.toString());\n this.links[parseInt(i.toString(), 10)].innerHTML = !pagerObj.customText ? pageNo.toString() : pagerObj.customText + pageNo;\n if (pagerObj.currentPage !== pageNo) {\n this.links[parseInt(i.toString(), 10)].classList.add('e-pager-default');\n }\n else {\n this.links[parseInt(i.toString(), 10)].classList.remove('e-pager-default');\n }\n }\n else {\n this.links[parseInt(i.toString(), 10)].innerHTML = !pagerObj.customText ? pageNo.toString() : pagerObj.customText + pageNo;\n this.links[parseInt(i.toString(), 10)].style.display = 'none';\n }\n classList(this.links[parseInt(i.toString(), 10)], [], ['e-currentitem', 'e-active']);\n this.links[parseInt(i.toString(), 10)].removeAttribute('aria-current');\n }\n attributes(this.first, {\n 'index': '1',\n 'title': this.pagerModule.getLocalizedLabel('firstPageTooltip'),\n });\n attributes(this.pagerElement.querySelector('.e-mfirst'), {\n 'index': '1',\n 'title': this.pagerModule.getLocalizedLabel('firstPageTooltip'),\n });\n attributes(this.last, {\n 'index': pagerObj.totalPages.toString(),\n 'title': this.pagerModule.getLocalizedLabel('lastPageTooltip'),\n });\n attributes(this.pagerElement.querySelector('.e-mlast'), {\n 'index': pagerObj.totalPages.toString(),\n 'title': this.pagerModule.getLocalizedLabel('lastPageTooltip'),\n });\n attributes(this.prev, {\n 'index': (pagerObj.currentPage - 1).toString(),\n 'title': this.pagerModule.getLocalizedLabel('previousPageTooltip'),\n });\n attributes(this.pagerElement.querySelector('.e-mprev'), {\n 'index': (pagerObj.currentPage - 1).toString(),\n 'title': this.pagerModule.getLocalizedLabel('previousPageTooltip'),\n });\n attributes(this.next, {\n 'index': (pagerObj.currentPage + 1).toString(),\n 'title': this.pagerModule.getLocalizedLabel('nextPageTooltip'),\n });\n attributes(this.pagerElement.querySelector('.e-mnext'), {\n 'index': (pagerObj.currentPage + 1).toString(),\n 'title': this.pagerModule.getLocalizedLabel('nextPageTooltip'),\n });\n var ppIndex = (this.pagerModule.isPagerResized && numItems.length)\n ? isLastSet\n ? parseInt(numItems[0].getAttribute('index'), 10) - pagerObj.avgNumItems\n : parseInt(numItems[0].getAttribute('index'), 10) - numItems.length\n : parseInt(this.links[0].getAttribute('index'), 10) - pagerObj.pageCount;\n attributes(this.PP, {\n 'index': ((ppIndex < 1) ? '1' : ppIndex.toString()),\n 'title': this.pagerModule.getLocalizedLabel('previousPagerTooltip'),\n 'aria-label': this.pagerModule.getLocalizedLabel('previousPagerTooltip')\n });\n var NPIndex = (this.pagerModule.isPagerResized && numItems.length)\n ? parseInt(numItems[numItems.length - 1].getAttribute('index'), 10)\n : parseInt(this.links[this.links.length - 1].getAttribute('index'), 10);\n attributes(this.NP, {\n 'index': (NPIndex + 1).toString(),\n 'title': this.pagerModule.getLocalizedLabel('nextPagerTooltip'),\n 'aria-label': this.pagerModule.getLocalizedLabel('nextPagerTooltip')\n });\n this.target = undefined;\n };\n NumericContainer.prototype.updateStyles = function () {\n var _this = this;\n this.updateFirstNPrevStyles();\n this.updatePrevPagerSetStyles();\n this.updateNextPagerSetStyles();\n this.updateNextNLastStyles();\n if (this.links.length) {\n var currentPageIndex = this.links.findIndex(function (link) { return link.getAttribute('index') === _this.pagerModule.currentPage.toString(); });\n var currentPage = (this.pagerModule.isPagerResized && currentPageIndex !== -1) ? currentPageIndex\n : ((this.pagerModule.currentPage - 1) % this.pagerModule.pageCount);\n classList(this.links[parseInt(currentPage.toString(), 10)], ['e-currentitem', 'e-active'], []);\n this.links[parseInt(currentPage.toString(), 10)].setAttribute('aria-current', 'page');\n }\n };\n NumericContainer.prototype.updateFirstNPrevStyles = function () {\n var firstPage = ['e-firstpage', 'e-pager-default'];\n var firstPageDisabled = ['e-firstpagedisabled', 'e-disable'];\n var prevPage = ['e-prevpage', 'e-pager-default'];\n var prevPageDisabled = ['e-prevpagedisabled', 'e-disable'];\n if (this.pagerModule.totalPages > 0 && this.pagerModule.currentPage > 1) {\n classList(this.prev, prevPage, prevPageDisabled);\n classList(this.first, firstPage, firstPageDisabled);\n classList(this.pagerElement.querySelector('.e-mfirst'), firstPage, firstPageDisabled);\n classList(this.pagerElement.querySelector('.e-mprev'), prevPage, prevPageDisabled);\n }\n else {\n classList(this.prev, prevPageDisabled, prevPage);\n classList(this.first, firstPageDisabled, firstPage);\n classList(this.pagerElement.querySelector('.e-mprev'), prevPageDisabled, prevPage);\n classList(this.pagerElement.querySelector('.e-mfirst'), firstPageDisabled, firstPage);\n }\n };\n NumericContainer.prototype.updatePrevPagerSetStyles = function () {\n if (this.pagerModule.currentPage > this.pagerModule.pageCount || (this.pagerModule.isPagerResized\n && this.links.findIndex(function (link) { return parseInt(link.getAttribute('index'), 10) === 1; }))) {\n classList(this.PP, ['e-numericitem', 'e-pager-default'], ['e-nextprevitemdisabled', 'e-disable']);\n }\n else {\n classList(this.PP, ['e-nextprevitemdisabled', 'e-disable'], ['e-numericitem', 'e-pager-default']);\n }\n };\n NumericContainer.prototype.updateNextPagerSetStyles = function () {\n var pagerObj = this.pagerModule;\n var firstPage = this.links[0].innerHTML.replace(pagerObj.customText, '');\n var numItems = this.pagerElement.querySelectorAll('.e-numericitem:not(.e-hide):not([style*=\"display: none\"]):not(.e-np):not(.e-pp)');\n if (!firstPage.length || !this.links.length || (parseInt(firstPage, 10) + pagerObj.pageCount > pagerObj.totalPages)\n || (pagerObj.isPagerResized && Array.from(numItems).some(function (item) { return parseInt(item.getAttribute('index'), 10) === pagerObj.totalPages; }))) {\n classList(this.NP, ['e-nextprevitemdisabled', 'e-disable'], ['e-numericitem', 'e-pager-default']);\n }\n else {\n classList(this.NP, ['e-numericitem', 'e-pager-default'], ['e-nextprevitemdisabled', 'e-disable']);\n }\n };\n NumericContainer.prototype.updateNextNLastStyles = function () {\n var lastPage = ['e-lastpage', 'e-pager-default'];\n var lastPageDisabled = ['e-lastpagedisabled', 'e-disable'];\n var nextPage = ['e-nextpage', 'e-pager-default'];\n var nextPageDisabled = ['e-nextpagedisabled', 'e-disable'];\n var pagerObj = this.pagerModule;\n if (pagerObj.currentPage === pagerObj.totalPages || pagerObj.totalRecordsCount === 0) {\n classList(this.last, lastPageDisabled, lastPage);\n classList(this.next, nextPageDisabled, nextPage);\n classList(this.pagerElement.querySelector('.e-mlast'), lastPageDisabled, lastPage);\n classList(this.pagerElement.querySelector('.e-mnext'), nextPageDisabled, nextPage);\n }\n else {\n classList(this.last, lastPage, lastPageDisabled);\n classList(this.next, nextPage, nextPageDisabled);\n classList(this.pagerElement.querySelector('.e-mlast'), lastPage, lastPageDisabled);\n classList(this.pagerElement.querySelector('.e-mnext'), nextPage, nextPageDisabled);\n }\n };\n return NumericContainer;\n}());\nexport { NumericContainer };\n","import { createElement, append } from '@syncfusion/ej2-base';\n/**\n * `PagerMessage` module is used to display pager information.\n */\nvar PagerMessage = /** @class */ (function () {\n /**\n * Constructor for externalMessage module\n *\n * @param {Pager} pagerModule - specifies the pager Module\n * @hidden\n */\n function PagerMessage(pagerModule) {\n this.pagerModule = pagerModule;\n }\n /**\n * The function is used to render pager message\n *\n * @returns {void}\n * @hidden\n */\n PagerMessage.prototype.render = function () {\n var div = createElement('div', { className: 'e-parentmsgbar' });\n this.pageNoMsgElem = createElement('span', { className: 'e-pagenomsg', styles: 'textalign:right' });\n this.pageCountMsgElem = createElement('span', { className: 'e-pagecountmsg', styles: 'textalign:right' });\n append([this.pageNoMsgElem, this.pageCountMsgElem], div);\n this.pagerModule.element.appendChild(div);\n this.refresh();\n };\n /**\n * Refreshes the pager information.\n *\n * @returns {void}\n */\n PagerMessage.prototype.refresh = function () {\n var pagerObj = this.pagerModule;\n this.pageNoMsgElem.textContent = this.format(pagerObj.getLocalizedLabel('currentPageInfo'), [pagerObj.totalRecordsCount === 0 ? 0 :\n pagerObj.currentPage, pagerObj.totalPages || 0, pagerObj.totalRecordsCount || 0]) + ' ';\n this.pageCountMsgElem.textContent = this.format(pagerObj.getLocalizedLabel(pagerObj.totalRecordsCount <= 1 ? 'totalItemInfo' : 'totalItemsInfo'), [pagerObj.totalRecordsCount || 0, pagerObj.totalRecordsCount ? (pagerObj.pageSize * (pagerObj.currentPage - 1)) + 1 : 0,\n pagerObj.pageSize * pagerObj.currentPage > pagerObj.totalRecordsCount ? pagerObj.totalRecordsCount :\n pagerObj.pageSize * pagerObj.currentPage]);\n this.pageNoMsgElem.parentElement.classList.remove('e-hide');\n };\n /**\n * Hides the Pager information.\n *\n * @returns {void}\n */\n PagerMessage.prototype.hideMessage = function () {\n if (this.pageNoMsgElem) {\n this.pageNoMsgElem.style.display = 'none';\n }\n if (this.pageCountMsgElem) {\n this.pageCountMsgElem.style.display = 'none';\n }\n };\n /**\n * Shows the Pager information.\n *\n * @returns {void}\n */\n PagerMessage.prototype.showMessage = function () {\n if (!this.pageNoMsgElem) {\n this.render();\n }\n this.pageNoMsgElem.style.display = '';\n this.pageCountMsgElem.style.display = '';\n };\n /**\n * To destroy the PagerMessage\n *\n * @function destroy\n * @returns {void}\n * @hidden\n */\n PagerMessage.prototype.destroy = function () {\n //destroy\n };\n /**\n * To format the PagerMessage\n *\n * @function format\n * @returns {string}\n * @hidden\n */\n PagerMessage.prototype.format = function (str, args) {\n var regx;\n for (var i = 0; i < args.length; i++) {\n // eslint-disable-next-line security/detect-non-literal-regexp\n regx = new RegExp('\\\\{' + (i) + '\\\\}', 'gm');\n str = str.replace(regx, args[parseInt(i.toString(), 10)].toString());\n }\n return str;\n };\n return PagerMessage;\n}());\nexport { PagerMessage };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Component, L10n, Browser, addClass, removeClass, classList } from '@syncfusion/ej2-base';\nimport { createElement, compile as templateCompiler, EventHandler, extend } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { Property, Event, NotifyPropertyChanges } from '@syncfusion/ej2-base';\nimport { NumericContainer } from './numeric-container';\nimport { PagerMessage } from './pager-message';\nimport { appendChildren, parentsUntil } from '../grid/base/util';\nimport * as events from '../grid/base/constant';\n/**\n * Represents the `Pager` component.\n * ```html\n * <div id=\"pager\"/>\n * ```\n * ```typescript\n * <script>\n * var pagerObj = new Pager({ totalRecordsCount: 50, pageSize:10 });\n * pagerObj.appendTo(\"#pager\");\n * </script>\n * ```\n */\nvar Pager = /** @class */ (function (_super) {\n __extends(Pager, _super);\n /**\n * Constructor for creating the component.\n *\n * @param {PagerModel} options - specifies the options\n * @param {string} element - specifies the element\n * @param {string} parent - specifies the pager parent\n * @hidden\n */\n function Pager(options, element, parent) {\n var _this = _super.call(this, options, element) || this;\n /** @hidden */\n _this.hasParent = false;\n _this.checkAll = true;\n _this.pageRefresh = 'pager-refresh';\n _this.firstPagerFocus = false;\n /** @hidden */\n _this.isCancel = false;\n _this.parent = parent;\n return _this;\n }\n /**\n * To provide the array of modules needed for component rendering\n *\n * @returns {ModuleDeclaration[]} returns the modules declaration\n * @hidden\n */\n Pager.prototype.requiredModules = function () {\n var modules = [];\n if (this.enableExternalMessage) {\n modules.push({\n member: 'externalMessage',\n args: [this]\n });\n }\n if (this.checkpagesizes()) {\n modules.push({\n member: 'pagerdropdown',\n args: [this]\n });\n }\n return modules;\n };\n /**\n * Initialize the event handler\n *\n * @returns {void}\n * @hidden\n */\n Pager.prototype.preRender = function () {\n //preRender\n this.defaultConstants = {\n currentPageInfo: '{0} of {1} pages',\n totalItemsInfo: '({0} items)',\n totalItemInfo: '({0} item)',\n firstPageTooltip: 'Go to first page',\n lastPageTooltip: 'Go to last page',\n nextPageTooltip: 'Go to next page',\n previousPageTooltip: 'Go to previous page',\n nextPagerTooltip: 'Go to next pager items',\n previousPagerTooltip: 'Go to previous pager items',\n pagerDropDown: 'Items per page',\n pagerAllDropDown: 'Items',\n CurrentPageInfo: '{0} of {1} pages',\n TotalItemsInfo: '({0} items)',\n FirstPageTooltip: 'Go to first page',\n LastPageTooltip: 'Go to last page',\n NextPageTooltip: 'Go to next page',\n PreviousPageTooltip: 'Go to previous page',\n NextPagerTooltip: 'Go to next pager items',\n PreviousPagerTooltip: 'Go to previous pager items',\n PagerDropDown: 'Items per page',\n PagerAllDropDown: 'Items',\n All: 'All',\n Container: 'Pager Container',\n Information: 'Pager Information',\n ExternalMsg: 'Pager external message',\n Page: 'Page ',\n Of: ' of ',\n Pages: ' Pages'\n };\n this.containerModule = new NumericContainer(this);\n this.pagerMessageModule = new PagerMessage(this);\n };\n /**\n * To Initialize the component rendering\n *\n * @returns {void}\n */\n Pager.prototype.render = function () {\n this.element.setAttribute('data-role', 'pager');\n this.element.setAttribute('tabindex', '-1');\n this.initLocalization();\n if (this.cssClass) {\n if (this.cssClass.indexOf(' ') !== -1) {\n addClass([this.element], this.cssClass.split(' '));\n }\n else {\n addClass([this.element], [this.cssClass]);\n }\n }\n if (!this.hasParent) {\n this.element.setAttribute('tabindex', '0');\n }\n if (this.template) {\n if (this.isReactTemplate()) {\n this.on(this.pageRefresh, this.pagerTemplate, this);\n this.notify(this.pageRefresh, {});\n }\n else {\n this.pagerTemplate();\n }\n }\n else {\n this.updateRTL();\n this.totalRecordsCount = this.totalRecordsCount || 0;\n this.renderFirstPrevDivForDevice();\n this.containerModule.render();\n if (this.enablePagerMessage) {\n this.pagerMessageModule.render();\n }\n this.renderNextLastDivForDevice();\n if (this.checkpagesizes() && this.pagerdropdownModule) {\n this.pagerdropdownModule.render();\n }\n this.addAriaLabel();\n if (this.enableExternalMessage && this.externalMessageModule) {\n this.externalMessageModule.render();\n }\n this.refresh();\n this.trigger('created', { 'currentPage': this.currentPage, 'totalRecordsCount': this.totalRecordsCount });\n }\n this.wireEvents();\n this.addListener();\n };\n /**\n * Get the properties to be maintained in the persisted state.\n *\n * @returns {string} returns the persist data\n * @hidden\n */\n Pager.prototype.getPersistData = function () {\n var keyEntity = ['currentPage', 'pageSize'];\n return this.addOnPersist(keyEntity);\n };\n /**\n * To destroy the Pager component.\n *\n * @method destroy\n * @returns {void}\n */\n Pager.prototype.destroy = function () {\n if (this.isDestroyed) {\n return;\n }\n if (this.isReactTemplate()) {\n this.off(this.pageRefresh, this.pagerTemplate);\n if (!this.hasParent) {\n this.destroyTemplate(['template']);\n }\n }\n this.removeListener();\n this.unwireEvents();\n _super.prototype.destroy.call(this);\n this.containerModule.destroy();\n this.pagerMessageModule.destroy();\n if (!this.isReactTemplate()) {\n this.element.innerHTML = '';\n }\n };\n /**\n * Destroys the given template reference.\n *\n * @param {string[]} propertyNames - Defines the collection of template name.\n * @param {any} index - Defines the index\n */\n // eslint-disable-next-line\n Pager.prototype.destroyTemplate = function (propertyNames, index) {\n this.clearTemplate(propertyNames, index);\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Pager.prototype.getModuleName = function () {\n return 'pager';\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @param {PagerModel} newProp - specifies the new property\n * @param {PagerModel} oldProp - specifies the old propety\n * @returns {void}\n * @hidden\n */\n Pager.prototype.onPropertyChanged = function (newProp, oldProp) {\n if (this.isDestroyed) {\n return;\n }\n if ((newProp.pageSize === this.getLocalizedLabel('All')) && oldProp.pageSize === this.totalRecordsCount) {\n this.pageSize = this.totalRecordsCount;\n return;\n }\n if (newProp.pageCount !== oldProp.pageCount) {\n this.containerModule.refreshNumericLinks();\n this.containerModule.refresh();\n }\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'currentPage':\n if (this.checkGoToPage(newProp.currentPage, oldProp.currentPage)) {\n this.currentPageChanged(newProp, oldProp);\n }\n break;\n case 'pageSize':\n case 'totalRecordsCount':\n case 'customText':\n if (this.checkpagesizes() && this.pagerdropdownModule) {\n if (oldProp.pageSize !== newProp.pageSize) {\n this.currentPage = 1;\n }\n this.pagerdropdownModule.setDropDownValue('value', this.pageSize);\n }\n if (newProp.pageSize !== oldProp.pageSize) {\n this.pageSize = newProp.pageSize;\n this.currentPageChanged(newProp, oldProp);\n if (this.isCancel && this.hasParent) {\n this.parent\n .setProperties({ pageSettings: { pageSize: oldProp.pageSize } }, true);\n }\n }\n else {\n this.refresh();\n }\n break;\n case 'pageSizes':\n if (this.checkpagesizes() && this.pagerdropdownModule) {\n this.pagerdropdownModule.destroy();\n this.pagerdropdownModule.render();\n }\n this.refresh();\n break;\n case 'template':\n this.templateFn = this.compile(this.template);\n this.refresh();\n break;\n case 'locale':\n this.initLocalization();\n this.refresh();\n break;\n case 'enableExternalMessage':\n if (this.enableExternalMessage && this.externalMessageModule) {\n this.externalMessageModule.render();\n }\n break;\n case 'externalMessage':\n if (this.externalMessageModule) {\n this.externalMessageModule.refresh();\n }\n break;\n case 'enableRtl':\n this.updateRTL();\n break;\n case 'enablePagerMessage':\n if (this.enablePagerMessage) {\n this.pagerMessageModule.showMessage();\n }\n else {\n this.pagerMessageModule.hideMessage();\n }\n break;\n }\n }\n this.resizePager();\n };\n Pager.prototype.wireEvents = function () {\n if (!this.hasParent) {\n EventHandler.add(this.element, 'keydown', this.keyPressHandler, this);\n EventHandler.add(document.body, 'keydown', this.keyDownHandler, this);\n }\n EventHandler.add(this.element, 'focusin', this.onFocusIn, this);\n EventHandler.add(this.element, 'focusout', this.onFocusOut, this);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n EventHandler.add(window, 'resize', this.resizePager, this);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n EventHandler.add(window, 'load', this.resizePager, this);\n };\n Pager.prototype.unwireEvents = function () {\n if (!this.hasParent) {\n EventHandler.remove(this.element, 'keydown', this.keyPressHandler);\n EventHandler.remove(document.body, 'keydown', this.keyDownHandler);\n }\n EventHandler.remove(this.element, 'focusin', this.onFocusIn);\n EventHandler.remove(this.element, 'focusout', this.onFocusOut);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n EventHandler.remove(window, 'resize', this.resizePager);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n EventHandler.remove(window, 'load', this.resizePager);\n };\n Pager.prototype.onFocusIn = function (e) {\n var focusedTabIndexElement = this.getFocusedTabindexElement();\n if (isNullOrUndefined(focusedTabIndexElement)) {\n var target = e.target;\n var dropDownPage = this.getDropDownPage();\n if (!this.hasParent) {\n this.element.tabIndex = -1;\n }\n if (target === this.element && !this.hasParent) {\n var focusablePagerElements = this.getFocusablePagerElements(this.element, []);\n this.addFocus(focusablePagerElements[0], true);\n return;\n }\n if (target === this.element) {\n this.element.tabIndex = 0;\n return;\n }\n if (target !== dropDownPage && !target.classList.contains('e-disable')) {\n this.addFocus(target, true);\n }\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Pager.prototype.onFocusOut = function (e) {\n var focusedElement = this.getFocusedElement();\n var dropDownPage = this.getDropDownPage();\n if (!isNullOrUndefined(focusedElement)) {\n this.removeFocus(focusedElement, true);\n }\n if (this.pageSizes && dropDownPage && dropDownPage.classList.contains('e-input-focus')) {\n this.removeFocus(dropDownPage, true);\n }\n this.setTabIndexForFocusLastElement();\n if (!this.hasParent) {\n this.element.tabIndex = 0;\n }\n if (this.hasParent) {\n this.element.tabIndex = -1;\n }\n };\n Pager.prototype.keyDownHandler = function (e) {\n if (e.altKey) {\n if (e.keyCode === 74) {\n var focusablePagerElements = this.getFocusablePagerElements(this.element, []);\n if (focusablePagerElements.length > 0) {\n focusablePagerElements[0].focus();\n }\n }\n }\n };\n Pager.prototype.keyPressHandler = function (e) {\n var presskey = extend(e, { cancel: false });\n this.notify(events.keyPressed, presskey);\n if (presskey.cancel === true) {\n e.stopImmediatePropagation();\n }\n };\n Pager.prototype.addListener = function () {\n if (this.isDestroyed) {\n return;\n }\n if (!this.hasParent) {\n this.on(events.keyPressed, this.onKeyPress, this);\n }\n };\n Pager.prototype.removeListener = function () {\n if (this.isDestroyed) {\n return;\n }\n if (!this.hasParent) {\n this.off(events.keyPressed, this.onKeyPress);\n }\n };\n Pager.prototype.onKeyPress = function (e) {\n if (!this.hasParent) {\n if (this.checkPagerHasFocus()) {\n this.changePagerFocus(e);\n }\n else {\n e.preventDefault();\n this.setPagerFocus();\n }\n }\n };\n /**\n * @returns {boolean} - Return the true value if pager has focus\n * @hidden */\n Pager.prototype.checkPagerHasFocus = function () {\n return this.getFocusedTabindexElement() ? true : false;\n };\n /**\n * @returns {void}\n * @hidden */\n Pager.prototype.setPagerContainerFocus = function () {\n this.element.focus();\n };\n /**\n * @returns {void}\n * @hidden */\n Pager.prototype.setPagerFocus = function () {\n var focusablePagerElements = this.getFocusablePagerElements(this.element, []);\n if (focusablePagerElements.length > 0) {\n focusablePagerElements[0].focus();\n }\n };\n Pager.prototype.setPagerFocusForActiveElement = function () {\n var currentActivePage = this.getActiveElement();\n if (currentActivePage) {\n currentActivePage.focus();\n }\n };\n Pager.prototype.setTabIndexForFocusLastElement = function () {\n var focusablePagerElements = this.getFocusablePagerElements(this.element, []);\n var dropDownPage = this.getDropDownPage();\n if (this.pageSizes && dropDownPage && !isNullOrUndefined(dropDownPage.offsetParent)) {\n dropDownPage.tabIndex = 0;\n }\n else if (focusablePagerElements.length > 0) {\n focusablePagerElements[focusablePagerElements.length - 1].tabIndex = 0;\n }\n };\n /**\n * @param {KeyboardEventArgs} e - Keyboard Event Args\n * @returns {void}\n * @hidden */\n Pager.prototype.changePagerFocus = function (e) {\n this.keyAction = e.key;\n if (e.shiftKey && e.keyCode === 9) {\n this.changeFocusByShiftTab(e);\n }\n else if (e.keyCode === 9) {\n this.changeFocusByTab(e);\n }\n else if (e.keyCode === 13 || e.keyCode === 32) {\n this.navigateToPageByEnterOrSpace(e);\n }\n else if (e.keyCode === 37 || e.keyCode === 39 || e.keyCode === 35 || e.keyCode === 36) {\n this.navigateToPageByKey(e);\n }\n this.keyAction = '';\n };\n Pager.prototype.getFocusedTabindexElement = function () {\n var focusedTabIndexElement;\n var tabindexElements = this.element.querySelectorAll('[tabindex]:not([tabindex=\"-1\"])');\n for (var i = 0; i < tabindexElements.length; i++) {\n var element = tabindexElements[parseInt(i.toString(), 10)];\n if (element && (element.classList.contains('e-focused') || element.classList.contains('e-input-focus'))) {\n focusedTabIndexElement = element;\n break;\n }\n }\n return focusedTabIndexElement;\n };\n Pager.prototype.changeFocusByTab = function (e) {\n var currentItemPagerFocus = this.getFocusedTabindexElement();\n var focusablePagerElements = this.getFocusablePagerElements(this.element, []);\n var dropDownPage = this.getDropDownPage();\n if (focusablePagerElements.length > 0) {\n if (this.pageSizes && dropDownPage && currentItemPagerFocus === focusablePagerElements[focusablePagerElements.length - 1]) {\n dropDownPage.tabIndex = 0;\n }\n else {\n for (var i = 0; i < focusablePagerElements.length; i++) {\n if (currentItemPagerFocus === focusablePagerElements[parseInt(i.toString(), 10)]) {\n var incrementNumber = i + 1;\n if (incrementNumber < focusablePagerElements.length) {\n e.preventDefault();\n focusablePagerElements[parseInt(incrementNumber.toString(), 10)].focus();\n }\n break;\n }\n }\n }\n }\n };\n Pager.prototype.changeFocusByShiftTab = function (e) {\n var currentItemPagerFocus = this.getFocusedTabindexElement();\n var focusablePagerElements = this.getFocusablePagerElements(this.element, []);\n var dropDownPage = this.getDropDownPage();\n if (this.pageSizes && dropDownPage && dropDownPage.classList.contains('e-input-focus')) {\n dropDownPage.tabIndex = -1;\n this.addFocus(focusablePagerElements[focusablePagerElements.length - 1], true);\n }\n else if (focusablePagerElements.length > 0) {\n for (var i = 0; i < focusablePagerElements.length; i++) {\n if (currentItemPagerFocus === focusablePagerElements[parseInt(i.toString(), 10)]) {\n var decrementNumber = i - 1;\n if (decrementNumber >= 0) {\n e.preventDefault();\n focusablePagerElements[parseInt(decrementNumber.toString(), 10)].focus();\n }\n else if (this.hasParent) {\n var rows = this.parent.getRows();\n var lastRow = rows[rows.length - 1];\n var lastCell = lastRow.lastChild;\n e.preventDefault();\n lastCell.focus();\n this.firstPagerFocus = true;\n }\n break;\n }\n }\n }\n };\n /**\n * @returns {void}\n * @hidden */\n Pager.prototype.checkFirstPagerFocus = function () {\n if (this.firstPagerFocus) {\n this.firstPagerFocus = false;\n return true;\n }\n return false;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Pager.prototype.navigateToPageByEnterOrSpace = function (e) {\n var currentItemPagerFocus = this.getFocusedElement();\n if (currentItemPagerFocus) {\n this.goToPage(parseInt(currentItemPagerFocus.getAttribute('index'), 10));\n var currentActivePage = this.getActiveElement();\n var selectedClass = this.getClass(currentItemPagerFocus);\n var classElement = this.getElementByClass(selectedClass);\n if ((selectedClass === 'e-first' || selectedClass === 'e-prev' || selectedClass === 'e-next'\n || selectedClass === 'e-last' || selectedClass === 'e-pp' || selectedClass === 'e-np')\n && classElement && !classElement.classList.contains('e-disable')) {\n classElement.focus();\n }\n else if (this.checkFocusInAdaptiveMode(currentItemPagerFocus)) {\n this.changeFocusInAdaptiveMode(currentItemPagerFocus);\n }\n else {\n if (currentActivePage) {\n currentActivePage.focus();\n }\n }\n }\n };\n Pager.prototype.navigateToPageByKey = function (e) {\n var actionClass = e.keyCode === 37 ? '.e-prev' : e.keyCode === 39 ? '.e-next'\n : e.keyCode === 35 ? '.e-last' : e.keyCode === 36 ? '.e-first' : '';\n var pagingItem = this.element.querySelector(actionClass);\n var currentItemPagerFocus = this.getFocusedElement();\n if (!isNullOrUndefined(pagingItem) && pagingItem.hasAttribute('index')\n && !isNaN(parseInt(pagingItem.getAttribute('index'), 10))) {\n this.goToPage(parseInt(pagingItem.getAttribute('index'), 10));\n var currentActivePage = this.getActiveElement();\n if (this.checkFocusInAdaptiveMode(currentItemPagerFocus)) {\n this.changeFocusInAdaptiveMode(currentItemPagerFocus);\n }\n else {\n if (currentActivePage) {\n currentActivePage.focus();\n }\n }\n }\n };\n Pager.prototype.checkFocusInAdaptiveMode = function (element) {\n var selectedClass = this.getClass(element);\n return selectedClass === 'e-mfirst' || selectedClass === 'e-mprev' || selectedClass === 'e-mnext'\n || selectedClass === 'e-mlast' ? true : false;\n };\n Pager.prototype.changeFocusInAdaptiveMode = function (element) {\n var selectedClass = this.getClass(element);\n var classElement = this.getElementByClass(selectedClass);\n if (classElement && classElement.classList.contains('e-disable')) {\n if (selectedClass === 'e-mnext' || selectedClass === 'e-mlast') {\n var mPrev = this.element.querySelector('.e-mprev');\n mPrev.focus();\n }\n else {\n this.setPagerFocus();\n }\n }\n };\n Pager.prototype.removeTabindexLastElements = function () {\n var tabIndexElements = this.element.querySelectorAll('[tabindex]:not([tabindex=\"-1\"])');\n if (tabIndexElements.length > 1) {\n for (var i = 1; i < tabIndexElements.length; i++) {\n var element = tabIndexElements[parseInt(i.toString(), 10)];\n if (element) {\n element.tabIndex = -1;\n }\n }\n }\n };\n Pager.prototype.getActiveElement = function () {\n return this.element.querySelector('.e-active');\n };\n /**\n * @returns {Element} - Returns DropDown Page\n * @hidden */\n Pager.prototype.getDropDownPage = function () {\n var dropDownPageHolder = this.element.querySelector('.e-pagerdropdown');\n var dropDownPage;\n if (dropDownPageHolder) {\n dropDownPage = dropDownPageHolder.children[0];\n }\n return dropDownPage;\n };\n Pager.prototype.getFocusedElement = function () {\n return this.element.querySelector('.e-focused');\n };\n Pager.prototype.getClass = function (element) {\n var currentClass;\n var classList = ['e-mfirst', 'e-mprev', 'e-first', 'e-prev', 'e-pp',\n 'e-np', 'e-next', 'e-last', 'e-mnext', 'e-mlast'];\n for (var i = 0; i < classList.length; i++) {\n if (element && element.classList.contains(classList[parseInt(i.toString(), 10)])) {\n currentClass = classList[parseInt(i.toString(), 10)];\n return currentClass;\n }\n }\n return currentClass;\n };\n Pager.prototype.getElementByClass = function (className) {\n return this.element.querySelector('.' + className);\n };\n /**\n * @param {Element} element - Pager element\n * @param {Element[]} previousElements - Iterating pager element\n * @returns {Element[]} - Returns focusable pager element\n * @hidden */\n Pager.prototype.getFocusablePagerElements = function (element, previousElements) {\n var target = element;\n var targetChildrens = target.children;\n var pagerElements = previousElements;\n for (var i = 0; i < targetChildrens.length; i++) {\n var element_1 = targetChildrens[parseInt(i.toString(), 10)];\n if (element_1.children.length > 0 && !element_1.classList.contains('e-pagesizes')) {\n pagerElements = this.getFocusablePagerElements(element_1, pagerElements);\n }\n else {\n var tabindexElement = targetChildrens[parseInt(i.toString(), 10)];\n if (tabindexElement.hasAttribute('tabindex') && !element_1.classList.contains('e-disable')\n && element_1.style.display !== 'none'\n && !isNullOrUndefined(element_1.offsetParent)) {\n pagerElements.push(tabindexElement);\n }\n }\n }\n return pagerElements;\n };\n Pager.prototype.addFocus = function (element, addFocusClass) {\n if (addFocusClass) {\n addClass([element], ['e-focused', 'e-focus']);\n }\n element.tabIndex = 0;\n };\n Pager.prototype.removeFocus = function (element, removeFocusClass) {\n if (removeFocusClass) {\n removeClass([element], ['e-focused', 'e-focus']);\n }\n element.tabIndex = -1;\n };\n /**\n * Gets the localized label by locale keyword.\n *\n * @param {string} key - specifies the key\n * @returns {string} returns the localized label\n */\n Pager.prototype.getLocalizedLabel = function (key) {\n return this.localeObj.getConstant(key);\n };\n /**\n * Navigate to target page by given number.\n *\n * @param {number} pageNo - Defines page number.\n * @returns {void}\n */\n Pager.prototype.goToPage = function (pageNo) {\n if (this.checkGoToPage(pageNo)) {\n this.currentPage = pageNo;\n this.dataBind();\n }\n };\n /**\n * @param {number} pageSize - specifies the pagesize\n * @returns {void}\n * @hidden\n */\n Pager.prototype.setPageSize = function (pageSize) {\n this.pageSize = pageSize;\n this.dataBind();\n };\n Pager.prototype.checkpagesizes = function () {\n if (this.pageSizes === true || this.pageSizes.length) {\n return true;\n }\n return false;\n };\n Pager.prototype.checkGoToPage = function (newPageNo, oldPageNo) {\n if (newPageNo !== this.currentPage) {\n this.previousPageNo = this.currentPage;\n }\n if (!isNullOrUndefined(oldPageNo)) {\n this.previousPageNo = oldPageNo;\n }\n if (this.previousPageNo !== newPageNo && (newPageNo >= 1 && newPageNo <= this.totalPages)) {\n return true;\n }\n return false;\n };\n Pager.prototype.currentPageChanged = function (newProp, oldProp) {\n if (this.enableQueryString) {\n this.updateQueryString(this.currentPage);\n }\n if (newProp.currentPage !== oldProp.currentPage || newProp.pageSize !== oldProp.pageSize) {\n var args = {\n currentPage: this.currentPage,\n newProp: newProp, oldProp: oldProp, cancel: false\n };\n this.trigger('click', args);\n if (!args.cancel) {\n this.isCancel = false;\n this.refresh();\n }\n else {\n this.isCancel = true;\n if (oldProp && oldProp.pageSize) {\n this.setProperties({ pageSize: oldProp.pageSize }, true);\n if (this.pagerdropdownModule) {\n this.pagerdropdownModule.setDropDownValue('value', oldProp.pageSize);\n this.pagerdropdownModule['dropDownListObject'].text = oldProp.pageSize + '';\n }\n }\n }\n }\n };\n Pager.prototype.pagerTemplate = function () {\n if (this.isReactTemplate() && this.hasParent) {\n return;\n }\n var result;\n this.element.classList.add('e-pagertemplate');\n this.compile(this.template);\n var data = {\n currentPage: this.currentPage, pageSize: this.pageSize, pageCount: this.pageCount,\n totalRecordsCount: this.totalRecordsCount, totalPages: this.totalPages\n };\n var tempId = this.element.parentElement.id + '_template';\n if (this.isReactTemplate() && !this.isVue) {\n this.getPagerTemplate()(data, this, 'template', tempId, null, null, this.element);\n this.renderReactTemplates();\n }\n else {\n result = this.isVue ? this.getPagerTemplate()(data, this, 'template') : this.getPagerTemplate()(data);\n appendChildren(this.element, result);\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Pager.prototype.updateTotalPages = function () {\n this.totalPages = this.isAllPage ? 1 : (this.totalRecordsCount % this.pageSize === 0) ? (this.totalRecordsCount / this.pageSize) :\n (parseInt((this.totalRecordsCount / this.pageSize).toString(), 10) + 1);\n };\n /**\n * @returns {Function} returns the function\n * @hidden\n */\n Pager.prototype.getPagerTemplate = function () {\n return this.templateFn;\n };\n /**\n * @param {string | Function} template - specifies the template\n * @returns {Function} returns the function\n * @hidden\n */\n Pager.prototype.compile = function (template) {\n if (template) {\n try {\n if (typeof template === 'function') {\n this.templateFn = templateCompiler(template);\n }\n else {\n if (document.querySelectorAll(template).length) {\n this.templateFn = templateCompiler(document.querySelector(template).innerHTML.trim());\n }\n }\n }\n catch (e) {\n this.templateFn = templateCompiler(template);\n }\n }\n return undefined;\n };\n /**\n * Refreshes page count, pager information and external message.\n *\n * @returns {void}\n */\n Pager.prototype.refresh = function () {\n if (this.template) {\n if (this.isReactTemplate()) {\n this.updateTotalPages();\n this.notify(this.pageRefresh, {});\n }\n else {\n this.element.innerHTML = '';\n this.updateTotalPages();\n this.pagerTemplate();\n }\n }\n else {\n this.updateRTL();\n var focusedTabIndexElement = this.getFocusedTabindexElement();\n this.containerModule.refresh();\n this.removeTabindexLastElements();\n if (focusedTabIndexElement && focusedTabIndexElement.classList.contains('e-disable')) {\n if (this.checkFocusInAdaptiveMode(focusedTabIndexElement)) {\n this.changeFocusInAdaptiveMode(focusedTabIndexElement);\n }\n else {\n this.setPagerFocusForActiveElement();\n }\n }\n if (this.enablePagerMessage) {\n this.pagerMessageModule.refresh();\n }\n if (this.pagerdropdownModule) {\n this.pagerdropdownModule.refresh();\n }\n if (this.enableExternalMessage && this.externalMessageModule) {\n this.externalMessageModule.refresh();\n }\n this.setTabIndexForFocusLastElement();\n this.resizePager();\n }\n };\n Pager.prototype.updateRTL = function () {\n if (this.enableRtl) {\n this.element.classList.add('e-rtl');\n }\n else {\n this.element.classList.remove('e-rtl');\n }\n };\n Pager.prototype.initLocalization = function () {\n this.localeObj = new L10n(this.getModuleName(), this.defaultConstants, this.locale);\n };\n Pager.prototype.updateQueryString = function (value) {\n var updatedUrl = this.getUpdatedURL(window.location.href, 'page', value.toString());\n window.history.pushState({ path: updatedUrl }, '', updatedUrl);\n };\n Pager.prototype.getUpdatedURL = function (uri, key, value) {\n // eslint-disable-next-line security/detect-non-literal-regexp\n var regx = new RegExp('([?|&])' + key + '=.*?(&|#|$)', 'i');\n if (uri.match(regx)) {\n return uri.replace(regx, '$1' + key + '=' + value + '$2');\n }\n else {\n var hash = '';\n if (uri.indexOf('#') !== -1) {\n hash = uri.replace(/.*#/, '#');\n uri = uri.replace(/#.*/, '');\n }\n return uri + (uri.indexOf('?') !== -1 ? '&' : '?') + key + '=' + value + hash;\n }\n };\n Pager.prototype.renderFirstPrevDivForDevice = function () {\n this.element.appendChild(createElement('div', {\n className: 'e-mfirst e-icons e-icon-first',\n attrs: { title: this.getLocalizedLabel('firstPageTooltip'), tabindex: '-1' }\n }));\n this.element.appendChild(createElement('div', {\n className: 'e-mprev e-icons e-icon-prev',\n attrs: { title: this.getLocalizedLabel('previousPageTooltip'), tabindex: '-1' }\n }));\n };\n Pager.prototype.renderNextLastDivForDevice = function () {\n this.element.appendChild(createElement('div', {\n className: 'e-mnext e-icons e-icon-next',\n attrs: { title: this.getLocalizedLabel('nextPageTooltip'), tabindex: '-1' }\n }));\n this.element.appendChild(createElement('div', {\n className: 'e-mlast e-icons e-icon-last',\n attrs: { title: this.getLocalizedLabel('lastPageTooltip'), tabindex: '-1' }\n }));\n };\n Pager.prototype.addAriaLabel = function () {\n var classList = ['.e-mfirst', '.e-mprev', '.e-mnext', '.e-mlast'];\n if (!Browser.isDevice) {\n for (var i = 0; i < classList.length; i++) {\n var element = this.element.querySelector(classList[parseInt(i.toString(), 10)]);\n element.setAttribute('aria-label', element.getAttribute('title'));\n }\n }\n };\n Pager.prototype.isReactTemplate = function () {\n return (this.isReact || this.isVue) && this.template && typeof (this.template) !== 'string';\n };\n /**\n * Loop through all the inner elements of pager to calculate the required width for pager child elements.\n *\n * @returns {number} returns the actual width occupied by pager elements.\n */\n Pager.prototype.calculateActualWidth = function () {\n var pagerElements = this.element.querySelectorAll(\n /* tslint:disable-next-line:max-line-length */\n '.e-mfirst, .e-mprev, .e-icon-first, .e-icon-prev, .e-pp:not(.e-disable), .e-numericitem:not(.e-hide), .e-numericitem.e-active.e-hide, .e-np:not(.e-disable), .e-icon-next, .e-icon-last, .e-parentmsgbar, .e-mnext, .e-mlast, .e-pagerdropdown, .e-pagerconstant');\n var actualWidth = 0;\n for (var i = 0; i < pagerElements.length; i++) {\n if (getComputedStyle(pagerElements[parseInt(i.toString(), 10)]).display !== 'none') {\n actualWidth += pagerElements[parseInt(i.toString(), 10)].offsetWidth\n + parseFloat(getComputedStyle(pagerElements[parseInt(i.toString(), 10)]).marginLeft)\n + parseFloat(getComputedStyle(pagerElements[parseInt(i.toString(), 10)]).marginRight);\n }\n }\n var pagerContainer = this.element.querySelector('.e-pagercontainer');\n actualWidth += parseFloat(getComputedStyle(pagerContainer).marginLeft)\n + parseFloat(getComputedStyle(pagerContainer).marginRight);\n return actualWidth;\n };\n /**\n * Resize pager component by hiding pager component's numeric items based on total width available for pager.\n *\n * @returns {void}\n */\n Pager.prototype.resizePager = function () {\n var _this = this;\n var isStyleApplied = this.element.classList.contains('e-pager') ? getComputedStyle(this.element).getPropertyValue('border-style').includes('solid') : null;\n if (!(this.template) && isStyleApplied) {\n var pagerContainer = this.element.querySelector('.e-pagercontainer');\n var actualWidth = this.calculateActualWidth();\n var pagerWidth = this.element.clientWidth\n - parseFloat(getComputedStyle(this.element).paddingLeft)\n - parseFloat(getComputedStyle(this.element).paddingRight)\n - parseFloat(getComputedStyle(this.element).marginLeft)\n - parseFloat(getComputedStyle(this.element).marginRight);\n var numItems = pagerContainer.querySelectorAll('.e-numericitem:not(.e-hide):not([style*=\"display: none\"]):not(.e-np):not(.e-pp)');\n var hiddenNumItems = pagerContainer.querySelectorAll('.e-numericitem.e-hide:not([style*=\"display: none\"])');\n var hideFrom = numItems.length;\n var showFrom = 1;\n var bufferWidth = (!isNullOrUndefined(parentsUntil(this.element, 'e-bigger'))) ? 10 : 5;\n var NP = pagerContainer.querySelector('.e-np');\n var PP = pagerContainer.querySelector('.e-pp');\n var detailItems = this.element.querySelectorAll('.e-parentmsgbar:not(.e-hide):not([style*=\"display: none\"]), .e-pagesizes:not(.e-hide):not([style*=\"display: none\"])');\n var totDetailWidth_1 = 0;\n if (detailItems.length) {\n detailItems.forEach(function (item) {\n totDetailWidth_1 += item.offsetWidth;\n });\n this.averageDetailWidth = totDetailWidth_1 / detailItems.length;\n }\n var totalWidth = 0;\n /**\n * Loop to calculate average width of numeric item.\n */\n for (var i = 0; i < numItems.length; i++) {\n totalWidth += numItems[parseInt(i.toString(), 10)].offsetWidth\n + parseFloat(getComputedStyle(numItems[parseInt(i.toString(), 10)]).marginLeft)\n + parseFloat(getComputedStyle(numItems[parseInt(i.toString(), 10)]).marginRight);\n }\n var numericItemWidth = totalWidth / numItems.length;\n /**\n * Condition to hide numeric items when calculated actual width exceeds available pager space.\n */\n if (pagerWidth > 0 && (actualWidth >= (pagerWidth - (numericItemWidth ? numericItemWidth : 0)))) {\n this.isPagerResized = true;\n if (this.currentPage !== this.totalPages) {\n classList(NP, ['e-numericitem', 'e-pager-default'], ['e-nextprevitemdisabled', 'e-disable']);\n }\n actualWidth = this.calculateActualWidth();\n var diff = Math.abs((actualWidth) - pagerWidth);\n // To calculate number of numeric items need to be hidden.\n var numToHide = Math.ceil(diff / (numericItemWidth));\n numToHide = (numToHide === 0) ? 1 : (numToHide > numItems.length) ? (numItems.length - 1) : numToHide;\n for (var i = 1; i <= numToHide; i++) {\n var hideIndex = hideFrom - parseInt(i.toString(), 10);\n numItems = pagerContainer.querySelectorAll('.e-numericitem:not(.e-hide):not([style*=\"display: none\"]):not(.e-np):not(.e-pp)');\n if (this.currentPage !== 1 && ((parseInt(numItems[Math.abs(hideIndex)].getAttribute('index'), 10) === this.currentPage)\n || parseInt(numItems[numItems.length - 1].getAttribute('index'), 10) === this.currentPage)) {\n hideIndex = 0;\n classList(PP, ['e-numericitem', 'e-pager-default'], ['e-nextprevitemdisabled', 'e-disable']);\n }\n if (numItems[Math.abs(hideIndex)] && !(numItems[Math.abs(hideIndex)].classList.contains('e-currentitem'))) {\n numItems[Math.abs(hideIndex)].classList.add('e-hide');\n }\n }\n numItems = pagerContainer.querySelectorAll('.e-numericitem:not(.e-hide):not([style*=\"display: none\"]):not(.e-np):not(.e-pp)');\n // To hide Pager message elements when no more numeric items available to hide.\n if (numItems.length <= 1 && detailItems.length && window.innerWidth >= 768) {\n var pagerDetailItemsWidth = this.calculateActualWidth();\n if ((pagerDetailItemsWidth) > (pagerWidth - bufferWidth)) {\n var detailtoHide = Math.floor((pagerWidth - (pagerDetailItemsWidth - totDetailWidth_1))\n / this.averageDetailWidth);\n detailtoHide = detailItems.length - detailtoHide;\n for (var i = 0; i < (detailtoHide > detailItems.length ? detailItems.length : detailtoHide); i++) {\n detailItems[parseInt(i.toString(), 10)].classList.add('e-hide');\n }\n }\n }\n }\n /**\n * Condition to show numeric items when space availble in pager at dom.\n */\n else if (actualWidth < (pagerWidth) && hiddenNumItems.length) {\n var diff = Math.abs(pagerWidth - (actualWidth));\n var hiddenDetailItems = this.element.querySelectorAll('.e-parentmsgbar.e-hide, .e-pagesizes.e-hide');\n // To show Pager message elements.\n if (hiddenDetailItems.length && (diff > (this.averageDetailWidth + (this.averageDetailWidth / 4)))) {\n hiddenDetailItems[(hiddenDetailItems.length - 1)].classList.remove('e-hide');\n }\n if ((diff > (numericItemWidth * 2) && !hiddenDetailItems.length && window.innerWidth >= 768)) {\n // To calculate number of numeric items need to be shown.\n var numToShow = Math.floor((diff) / (numericItemWidth + bufferWidth));\n numToShow = (numToShow > hiddenNumItems.length) ? hiddenNumItems.length : (numToShow - 1);\n //Seggregating hidden num items as less index and greater index values than current page value.\n var lesserIndexItems = Array.from(hiddenNumItems).filter(function (item) { return parseInt(item.getAttribute('index'), 10) < _this.currentPage; }).sort(function (a, b) { return parseInt(b.getAttribute('index'), 10) - parseInt(a.getAttribute('index'), 10); });\n var greaterIndexItems = Array.from(hiddenNumItems).filter(function (item) { return parseInt(item.getAttribute('index'), 10) > _this.currentPage; });\n var showItems = (lesserIndexItems.length && lesserIndexItems)\n || (greaterIndexItems.length && greaterIndexItems);\n for (var i = 1; i <= numToShow; i++) {\n var showItem = showItems && showItems[Math.abs(showFrom - i)];\n if (showItem) {\n showItem.classList.remove('e-hide');\n if (showItem === showItems[showItems.length - 1]) {\n showItems = null;\n }\n }\n }\n }\n }\n numItems = pagerContainer.querySelectorAll('.e-numericitem:not(.e-hide):not([style*=\"display: none\"]):not(.e-np):not(.e-pp)');\n if (numItems.length) {\n if (parseInt(numItems[numItems.length - 1].getAttribute('index'), 10) === this.totalPages) {\n classList(NP, ['e-nextprevitemdisabled', 'e-disable'], ['e-numericitem', 'e-pager-default']);\n }\n if (parseInt(numItems[0].getAttribute('index'), 10) === 1) {\n classList(PP, ['e-nextprevitemdisabled', 'e-disable'], ['e-numericitem', 'e-pager-default']);\n }\n var isLastSet = Array.from(numItems).some(function (item) { return parseInt(item.getAttribute('index'), 10) === _this.totalPages; });\n var ppIndex = (parseInt(numItems[0].getAttribute('index'), 10) - (isLastSet ? this.avgNumItems : numItems.length));\n PP.setAttribute('index', (ppIndex < 1) ? '1' : ppIndex.toString());\n NP.setAttribute('index', (parseInt(numItems[numItems.length - 1].getAttribute('index'), 10) + 1).toString());\n this.avgNumItems = isLastSet ? this.avgNumItems : numItems.length;\n }\n /**\n * Condition to add adaptive class name and set pagermessage content with \"/\" when media query css has been applied.\n */\n if (((this.element.offsetWidth < 769) && window.getComputedStyle(this.element.querySelector('.e-mfirst')).getPropertyValue('display') !== 'none') && this.pageSizes) {\n this.element.querySelector('.e-pagesizes').classList.remove('e-hide');\n this.element.querySelector('.e-parentmsgbar').classList.remove('e-hide');\n this.element.classList.add('e-adaptive');\n this.element.querySelector('.e-pagenomsg').innerHTML = this.element.offsetWidth < 481 ? (this.currentPage + ' / ' + this.totalPages) : this.pagerMessageModule.format(this.getLocalizedLabel('currentPageInfo'), [this.totalRecordsCount === 0 ? 0 :\n this.currentPage, this.totalPages || 0, this.totalRecordsCount || 0]) + ' ';\n }\n else {\n this.element.classList.remove('e-adaptive');\n this.element.querySelector('.e-pagenomsg').innerHTML = this.pagerMessageModule.format(this.getLocalizedLabel('currentPageInfo'), [this.totalRecordsCount === 0 ? 0 :\n this.currentPage, this.totalPages || 0, this.totalRecordsCount || 0]) + ' ';\n }\n }\n };\n __decorate([\n Property(false)\n ], Pager.prototype, \"enableQueryString\", void 0);\n __decorate([\n Property(false)\n ], Pager.prototype, \"enableExternalMessage\", void 0);\n __decorate([\n Property(true)\n ], Pager.prototype, \"enablePagerMessage\", void 0);\n __decorate([\n Property(12)\n ], Pager.prototype, \"pageSize\", void 0);\n __decorate([\n Property(10)\n ], Pager.prototype, \"pageCount\", void 0);\n __decorate([\n Property(1)\n ], Pager.prototype, \"currentPage\", void 0);\n __decorate([\n Property()\n ], Pager.prototype, \"totalRecordsCount\", void 0);\n __decorate([\n Property()\n ], Pager.prototype, \"externalMessage\", void 0);\n __decorate([\n Property(false)\n ], Pager.prototype, \"pageSizes\", void 0);\n __decorate([\n Property()\n ], Pager.prototype, \"template\", void 0);\n __decorate([\n Property('')\n ], Pager.prototype, \"customText\", void 0);\n __decorate([\n Event()\n ], Pager.prototype, \"click\", void 0);\n __decorate([\n Property('')\n ], Pager.prototype, \"cssClass\", void 0);\n __decorate([\n Event()\n ], Pager.prototype, \"dropDownChanged\", void 0);\n __decorate([\n Event()\n ], Pager.prototype, \"created\", void 0);\n Pager = __decorate([\n NotifyPropertyChanges\n ], Pager);\n return Pager;\n}(Component));\nexport { Pager };\n","import { createElement, remove } from '@syncfusion/ej2-base';\nimport { DropDownList } from '@syncfusion/ej2-dropdowns';\n/**\n * `PagerDropDown` module handles selected pageSize from DropDownList.\n */\nvar PagerDropDown = /** @class */ (function () {\n /**\n * Constructor for pager module\n *\n * @param {Pager} pagerModule - specifies the pagermodule\n * @hidden\n */\n function PagerDropDown(pagerModule) {\n this.pagerModule = pagerModule;\n }\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n * @hidden\n */\n PagerDropDown.prototype.getModuleName = function () {\n return 'pagerdropdown';\n };\n /**\n * The function is used to render pager dropdown\n *\n * @returns {void}\n * @hidden\n */\n PagerDropDown.prototype.render = function () {\n var pagerObj = this.pagerModule;\n this.pagerDropDownDiv = createElement('div', { className: 'e-pagesizes' });\n var dropDownDiv = createElement('div', { className: 'e-pagerdropdown' });\n var defaultTextDiv = createElement('div', { className: 'e-pagerconstant' });\n var input = createElement('input', { attrs: { type: 'text', tabindex: '-1' } });\n this.pagerCons = createElement('span', {\n className: 'e-constant', innerHTML: this.pagerModule.getLocalizedLabel('pagerDropDown')\n });\n dropDownDiv.appendChild(input);\n defaultTextDiv.appendChild(this.pagerCons);\n this.pagerDropDownDiv.appendChild(dropDownDiv);\n this.pagerDropDownDiv.appendChild(defaultTextDiv);\n this.pagerModule.element.appendChild(this.pagerDropDownDiv);\n var pageSizesModule = this.pagerModule.pageSizes;\n var pageSizesArray = (pageSizesModule.length ? this.convertValue(pageSizesModule) :\n [this.pagerModule.getLocalizedLabel('All'), '5', '10', '12', '20']);\n var defaultValue = this.pagerModule.pageSize;\n this.dropDownListObject = new DropDownList({\n dataSource: pageSizesArray,\n value: defaultValue.toString(),\n change: this.onChange.bind(this),\n placeholder: this.pagerModule.getLocalizedLabel('pagerDropDown'),\n cssClass: this.pagerModule.cssClass ? 'e-alldrop' + ' ' + this.pagerModule.cssClass : 'e-alldrop'\n });\n this.dropDownListObject.appendTo(input);\n if (pageSizesModule.length) {\n this.dropDownListObject.element.value = this.pagerModule.pageSize.toString();\n }\n pagerObj.pageSize = defaultValue;\n pagerObj.dataBind();\n pagerObj.trigger('dropDownChanged', { pageSize: defaultValue });\n this.addEventListener();\n };\n /**\n * For internal use only - Get the pagesize.\n *\n * @param {ChangeEventArgs} e - specifies the changeeventargs\n * @returns {void}\n * @private\n * @hidden\n */\n PagerDropDown.prototype.onChange = function (e) {\n if (this.dropDownListObject.value === this.pagerModule.getLocalizedLabel('All')) {\n this.pagerModule.pageSize = this.pagerModule.totalRecordsCount;\n this.pagerModule.isAllPage = true;\n this.refresh();\n e.value = this.pagerModule.pageSize;\n if (document.getElementsByClassName('e-popup-open e-alldrop').length) {\n document.getElementsByClassName('e-popup-open e-alldrop')[0].style.display = 'none';\n }\n }\n else {\n this.pagerModule.pageSize = parseInt(this.dropDownListObject.value, 10);\n this.pagerModule.isAllPage = false;\n if (this.pagerCons.innerHTML !== this.pagerModule.getLocalizedLabel('pagerDropDown')) {\n this.refresh();\n }\n }\n this.pagerModule.dataBind();\n if (!this.pagerModule.isCancel) {\n this.pagerModule.trigger('dropDownChanged', {\n pageSize: this.pagerModule.isAllPage ||\n (this.pagerModule.isAllPage === undefined && this.dropDownListObject.value === this.pagerModule.getLocalizedLabel('All')) ?\n this.pagerModule.totalRecordsCount : parseInt(this.dropDownListObject.value, 10)\n });\n }\n };\n PagerDropDown.prototype.refresh = function () {\n if (this.pagerCons) {\n if (this.isPageSizeAll(this.pagerModule.pageSize)) {\n this.pagerCons.innerHTML = this.pagerModule.getLocalizedLabel('pagerAllDropDown');\n this.pagerCons.parentElement.classList.add('e-page-all');\n }\n else {\n this.pagerCons.innerHTML = this.pagerModule.getLocalizedLabel('pagerDropDown');\n this.pagerCons.parentElement.classList.remove('e-page-all');\n }\n this.pagerDropDownDiv.classList.remove('e-hide');\n }\n };\n PagerDropDown.prototype.beforeValueChange = function (prop) {\n if (typeof prop.newProp.value === 'number') {\n var val = prop.newProp.value.toString();\n prop.newProp.value = val;\n }\n };\n PagerDropDown.prototype.convertValue = function (pageSizeValue) {\n var item = pageSizeValue;\n for (var i = 0; i < item.length; i++) {\n item[parseInt(i.toString(), 10)] = parseInt(item[parseInt(i.toString(), 10)], 10) ?\n item[parseInt(i.toString(), 10)].toString() : (this.pagerModule.getLocalizedLabel(item[parseInt(i.toString(), 10)]) !== '')\n ? this.pagerModule.getLocalizedLabel(item[parseInt(i.toString(), 10)]) : item[parseInt(i.toString(), 10)];\n }\n return item;\n };\n PagerDropDown.prototype.isPageSizeAll = function (value) {\n var pageSizeNum = typeof (value) === 'string' && value !== this.pagerModule.getLocalizedLabel('All') ?\n parseInt(value, 10) : value;\n if (pageSizeNum === this.pagerModule.totalRecordsCount || value === this.pagerModule.getLocalizedLabel('All')) {\n return true;\n }\n else {\n return false;\n }\n };\n PagerDropDown.prototype.setDropDownValue = function (prop, value) {\n if (this.dropDownListObject) {\n var isbeforeAll = this.pagerModule.isAllPage;\n this.pagerModule.isAllPage = this.isPageSizeAll(value);\n this.pagerModule.checkAll = (isbeforeAll && this.pagerModule.isAllPage) ? true : false;\n this.dropDownListObject[\"\" + prop] = this.pagerModule.isAllPage ? this.pagerModule.getLocalizedLabel('All') : value;\n }\n };\n PagerDropDown.prototype.addEventListener = function () {\n this.dropDownListObject.on('beforeValueChange', this.beforeValueChange, this);\n };\n PagerDropDown.prototype.removeEventListener = function () {\n this.dropDownListObject.off('beforeValueChange', this.beforeValueChange);\n };\n /**\n * To destroy the Pagerdropdown\n *\n * @param {string} args - specifies the arguments\n * @param {string} args.requestType - specfies the request type\n * @returns {void}\n * @hidden\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n PagerDropDown.prototype.destroy = function (args) {\n if (this.dropDownListObject && !this.dropDownListObject.isDestroyed) {\n this.removeEventListener();\n this.dropDownListObject.destroy();\n remove(this.pagerDropDownDiv);\n }\n };\n return PagerDropDown;\n}());\nexport { PagerDropDown };\n","import { createElement, remove, isNullOrUndefined } from '@syncfusion/ej2-base';\n/**\n * `ExternalMessage` module is used to display user provided message.\n */\nvar ExternalMessage = /** @class */ (function () {\n /**\n * Constructor for externalMessage module\n *\n * @param {Pager} pagerModule - specifies the pagermodule\n * @hidden\n */\n function ExternalMessage(pagerModule) {\n this.pagerModule = pagerModule;\n }\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n ExternalMessage.prototype.getModuleName = function () {\n return 'externalMessage';\n };\n /**\n * The function is used to render pager externalMessage\n *\n * @returns {void}\n * @hidden\n */\n ExternalMessage.prototype.render = function () {\n this.element = createElement('div', { className: 'e-pagerexternalmsg', attrs: { 'aria-label': this.pagerModule.getLocalizedLabel('ExternalMsg') } });\n this.pagerModule.element.appendChild(this.element);\n this.refresh();\n };\n /**\n * Refreshes the external message of Pager.\n *\n * @returns {void}\n */\n ExternalMessage.prototype.refresh = function () {\n if (this.pagerModule.externalMessage && this.pagerModule.externalMessage.toString().length) {\n this.showMessage();\n this.element.innerHTML = this.pagerModule.externalMessage;\n }\n else {\n this.hideMessage();\n }\n };\n /**\n * Hides the external message of Pager.\n *\n * @returns {void}\n */\n ExternalMessage.prototype.hideMessage = function () {\n if (!isNullOrUndefined(this.element)) {\n this.element.style.display = 'none';\n }\n };\n /**\n * Shows the external message of the Pager.\n *\n * @returns {void}s\n */\n ExternalMessage.prototype.showMessage = function () {\n this.element.style.display = '';\n };\n /**\n * To destroy the PagerMessage\n *\n * @function destroy\n * @returns {void}\n * @hidden\n */\n ExternalMessage.prototype.destroy = function () {\n if (this.element && this.element.parentElement) {\n remove(this.element);\n }\n };\n return ExternalMessage;\n}());\nexport { ExternalMessage };\n","import { extend } from '@syncfusion/ej2-base';\nimport { remove, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { Pager } from '../../pager/pager';\nimport { PagerDropDown } from '../../pager/pager-dropdown';\nimport { ExternalMessage } from '../../pager/external-message';\nimport { extend as gridExtend, getActualProperties, isActionPrevent, addRemoveEventListener, appendChildren } from '../base/util';\nimport * as events from '../base/constant';\nimport * as literals from '../base/string-literals';\n/**\n * The `Page` module is used to render pager and handle paging action.\n */\nvar Page = /** @class */ (function () {\n /**\n * Constructor for the Grid paging module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {PageSettingsModel} pageSettings - specifies the PageSettingsModel\n * @hidden\n */\n function Page(parent, pageSettings) {\n this.isInitialRender = true;\n /** @hidden */\n this.isCancel = false;\n Pager.Inject(ExternalMessage, PagerDropDown);\n this.parent = parent;\n this.pageSettings = pageSettings;\n this.addEventListener();\n }\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Page.prototype.getModuleName = function () {\n return 'pager';\n };\n /**\n * The function used to render pager from grid pageSettings\n *\n * @returns {void}\n * @hidden\n */\n Page.prototype.render = function () {\n var gObj = this.parent;\n this.pagerDestroy();\n if (!isNullOrUndefined(this.parent.pagerTemplate)) {\n this.pageSettings.template = this.parent.pagerTemplate;\n this.parent.pageTemplateChange = true;\n }\n this.element = this.parent.createElement('div', { className: 'e-gridpager' });\n var pagerObj = gridExtend({}, extend({}, getActualProperties(this.pageSettings)), {\n click: this.clickHandler.bind(this),\n dropDownChanged: this.onSelect.bind(this),\n enableRtl: gObj.enableRtl, locale: gObj.locale,\n created: this.addAriaAttr.bind(this)\n }, ['parentObj', 'propName']);\n pagerObj.cssClass = this.parent.cssClass ? this.parent.cssClass : '';\n this.pagerObj = new Pager(pagerObj, undefined, this.parent);\n this.pagerObj.hasParent = true;\n this.pagerObj.on(events.pagerRefresh, this.renderReactPagerTemplate, this);\n this.pagerObj.allowServerDataBinding = false;\n };\n Page.prototype.onSelect = function (e) {\n this.pageSettings.pageSize = e.pageSize;\n if (!this.isInitialLoad) {\n this.pageSettings.currentPage = 1;\n }\n };\n Page.prototype.addAriaAttr = function () {\n if (!(this.pageSettings.template)) {\n var numericContainerNew = this.parent.createElement('div', { className: 'e-numericcontainer' });\n var pagerContainer = this.element.querySelector('.e-pagercontainer');\n var frag = document.createDocumentFragment();\n var numericContainer = this.element.querySelector('.e-numericcontainer');\n var links = numericContainer.querySelectorAll('a');\n for (var i = 0; i < links.length; i++) {\n if (this.parent.getContentTable()) {\n links[parseInt(i.toString(), 10)].setAttribute('aria-owns', this.parent.getContentTable().id);\n }\n else {\n links[parseInt(i.toString(), 10)].setAttribute('aria-owns', this.parent.element.getAttribute('id') + '_content_table');\n }\n var numericContainerDiv = this.parent.createElement('div');\n numericContainerDiv.appendChild(links[parseInt(i.toString(), 10)]);\n frag.appendChild(numericContainerDiv);\n }\n numericContainerNew.appendChild(frag);\n pagerContainer.replaceChild(numericContainerNew, numericContainer);\n var classList = ['.e-mfirst', '.e-mprev', '.e-first', '.e-prev', '.e-next', '.e-last', '.e-mnext', '.e-mlast'];\n for (var j = 0; j < classList.length; j++) {\n var element = this.element.querySelector(classList[parseInt(j.toString(), 10)]);\n if (this.parent.getContentTable()) {\n element.setAttribute('aria-owns', this.parent.getContentTable().id);\n }\n }\n }\n };\n Page.prototype.dataReady = function (e) {\n this.updateModel(e);\n };\n /**\n * Refreshes the page count, pager information, and external message.\n *\n * @returns {void}\n */\n Page.prototype.refresh = function () {\n this.pagerObj.refresh();\n };\n /**\n * Navigates to the target page according to the given number.\n *\n * @param {number} pageNo - Defines the page number to navigate.\n * @returns {void}\n */\n Page.prototype.goToPage = function (pageNo) {\n this.pagerObj.goToPage(pageNo);\n };\n /**\n * @param {number} pageSize - specifies the page size\n * @returns {void}\n * @hidden\n */\n Page.prototype.setPageSize = function (pageSize) {\n this.pagerObj.setPageSize(pageSize);\n };\n /**\n * The function used to update pageSettings model\n *\n * @param {NotifyArgs} e - specfies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Page.prototype.updateModel = function (e) {\n this.parent.pageSettings.totalRecordsCount = e.count;\n if (this.pagerObj.isAllPage) {\n this.parent.pageSettings.pageSize = this.parent.pageSettings.totalRecordsCount;\n }\n if ((e.action === 'add' && e.requestType === 'save') || (e.requestType === 'batchsave')) {\n if (this.pagerObj.isAllPage && (e.count === this.pageSettings.pageSize)) {\n this.pagerObj.setProperties({ pageSize: e.count }, true);\n }\n }\n this.parent.dataBind();\n };\n /**\n * The function used to trigger onActionComplete\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Page.prototype.onActionComplete = function (e) {\n this.parent.trigger(events.actionComplete, extend(e, {\n currentPage: this.parent.pageSettings.currentPage, requestType: 'paging',\n type: events.actionComplete\n }));\n };\n /**\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Page.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName()) {\n return;\n }\n var newProp = e.properties;\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n this.pagerObj[\"\" + prop] = newProp[\"\" + prop];\n }\n this.pagerObj.dataBind();\n };\n Page.prototype.clickHandler = function (e) {\n var gObj = this.parent;\n if (this.isForceCancel || isActionPrevent(gObj) && !gObj.prevPageMoving && !this.isCancel) {\n if (!this.isForceCancel) {\n if (!isNullOrUndefined(e.newProp) && !isNullOrUndefined(e.newProp.pageSize)) {\n gObj.notify(events.preventBatch, { instance: this, handler: this.setPageSize, arg1: e.newProp.pageSize });\n this.pagerObj.setProperties({ pageSize: e.oldProp.pageSize }, true);\n gObj.setProperties({ pageSettings: { pageSize: e.oldProp.pageSize } }, true);\n this.pagerObj.setProperties({\n currentPage: gObj.pageSettings.currentPage === this.pagerObj.currentPage ?\n this.pagerObj.previousPageNo : gObj.pageSettings.currentPage\n }, true);\n }\n else if (e.currentPage) {\n gObj.notify(events.preventBatch, { instance: this, handler: this.goToPage, arg1: e.currentPage });\n this.pagerObj.currentPage = gObj.pageSettings.currentPage === this.pagerObj.currentPage ?\n this.pagerObj.previousPageNo : gObj.pageSettings.currentPage;\n }\n this.isForceCancel = true;\n this.pagerObj.dataBind();\n }\n else {\n this.isForceCancel = false;\n }\n e.cancel = true;\n return;\n }\n gObj.pageSettings.pageSize = this.pagerObj.pageSize;\n gObj.prevPageMoving = false;\n var prevPage = this.pageSettings.currentPage;\n var args = {\n cancel: false, requestType: 'paging', previousPage: prevPage,\n currentPage: e.currentPage, pageSize: gObj.pageSettings.pageSize, type: events.actionBegin\n };\n if (!this.isCancel) {\n this.pageSettings.currentPage = e.currentPage;\n this.parent.notify(events.modelChanged, args);\n }\n if (args.cancel) {\n e.cancel = true;\n this.parent.setProperties({ pageSettings: { currentPage: prevPage } }, true);\n this.pagerObj.setProperties({ currentPage: prevPage }, true);\n this.isCancel = true;\n return;\n }\n this.isCancel = false;\n this.parent.requestTypeAction = 'paging';\n };\n Page.prototype.keyPressHandler = function (e) {\n if (e.action in keyActions) {\n e.preventDefault();\n this.element.querySelector(keyActions[e.action]).click();\n }\n };\n /**\n * Defines the text of the external message.\n *\n * @param {string} message - Defines the message to update.\n * @returns {void}\n */\n Page.prototype.updateExternalMessage = function (message) {\n if (!this.pagerObj.enableExternalMessage) {\n this.pagerObj.enableExternalMessage = true;\n this.pagerObj.dataBind();\n }\n this.pagerObj.externalMessage = message;\n this.pagerObj.dataBind();\n };\n Page.prototype.appendToElement = function () {\n this.isInitialLoad = true;\n this.parent.element.appendChild(this.element);\n this.parent.setGridPager(this.element);\n this.pagerObj.isReact = this.parent.isReact;\n this.pagerObj.isVue = this.parent.isVue;\n this.pagerObj.appendTo(this.element);\n this.isInitialLoad = false;\n };\n Page.prototype.enableAfterRender = function (e) {\n if (e.module === this.getModuleName() && e.enable) {\n this.render();\n this.appendToElement();\n if (this.isReactTemplate()) {\n this.pagerObj.updateTotalPages();\n this.created();\n }\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Page.prototype.addEventListener = function () {\n this.handlers = {\n load: this.render,\n end: this.appendToElement,\n ready: this.dataReady,\n complete: this.onActionComplete,\n updateLayout: this.enableAfterRender,\n inboundChange: this.onPropertyChanged,\n keyPress: this.keyPressHandler,\n created: this.created\n };\n if (this.parent.isDestroyed) {\n return;\n }\n if (this.parent.isReact || this.parent.isVue) {\n this.parent.addEventListener(literals.create, this.handlers.created.bind(this));\n }\n this.evtHandlers = [{ event: events.initialLoad, handler: this.handlers.load },\n { event: events.initialEnd, handler: this.handlers.end },\n { event: events.dataReady, handler: this.handlers.ready },\n { event: events.pageComplete, handler: this.handlers.complete },\n { event: events.uiUpdate, handler: this.handlers.updateLayout },\n { event: events.inBoundModelChanged, handler: this.handlers.inboundChange },\n { event: events.keyPressed, handler: this.handlers.keyPress },\n { event: events.destroy, handler: this.destroy }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n };\n Page.prototype.created = function () {\n if (this.isInitialRender && this.isReactTemplate()) {\n this.isInitialRender = false;\n this.renderReactPagerTemplate();\n }\n };\n Page.prototype.isReactTemplate = function () {\n return (this.parent.isReact || this.parent.isVue) && this.pagerObj.template && typeof (this.pagerObj.template) !== 'string';\n };\n Page.prototype.renderReactPagerTemplate = function () {\n if (!this.isInitialRender && this.isReactTemplate()) {\n var result = void 0;\n this.parent.destroyTemplate(['pagerTemplate']);\n this.element.classList.add('e-pagertemplate');\n this.pagerObj.compile(this.pagerObj.template);\n var page = this.parent.pageSettings;\n var data = {\n currentPage: page.currentPage, pageSize: page.pageSize, pageCount: page.pageCount,\n totalRecordsCount: page.totalRecordsCount, totalPages: this.pagerObj.totalPages\n };\n var tempId = this.parent.id + '_pagertemplate';\n if (this.parent.isReact) {\n this.pagerObj.templateFn(data, this.parent, 'pagerTemplate', tempId, null, null, this.pagerObj.element);\n this.parent.renderTemplates();\n }\n else {\n result = this.pagerObj.templateFn(data, this.parent, 'pagerTemplate');\n appendChildren(this.pagerObj.element, result);\n }\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Page.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n if (this.parent.isReact || this.parent.isVue) {\n this.parent.removeEventListener(literals.create, this.handlers.created);\n }\n this.parent.off(events.pagerRefresh, this.renderReactPagerTemplate);\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n };\n /**\n * To destroy the pager\n *\n * @returns {void}\n * @hidden\n */\n Page.prototype.destroy = function () {\n this.removeEventListener();\n if (this.isReactTemplate()) {\n this.parent.destroyTemplate(['pagerTemplate']);\n }\n this.pagerObj.destroy();\n };\n Page.prototype.pagerDestroy = function () {\n if (this.pagerObj && !this.pagerObj.isDestroyed) {\n this.pagerObj.destroy();\n remove(this.element);\n }\n };\n return Page;\n}());\nexport { Page };\n/**\n * @hidden\n */\nvar keyActions = {\n pageUp: '.e-prev',\n pageDown: '.e-next',\n ctrlAltPageDown: '.e-last',\n ctrlAltPageUp: '.e-first',\n altPageUp: '.e-pp',\n altPageDown: '.e-np'\n};\n","import { Browser, EventHandler, createElement } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, isUndefined, addClass, removeClass } from '@syncfusion/ej2-base';\nimport { remove, closest, select } from '@syncfusion/ej2-base';\nimport { Query, DataManager } from '@syncfusion/ej2-data';\nimport { setCssInGridPopUp, getPosition, isGroupAdaptive, addRemoveActiveClasses, removeAddCboxClasses } from '../base/util';\nimport { getCellsByTableName, parentsUntil, getScrollBarWidth } from '../base/util';\nimport * as events from '../base/constant';\nimport { RenderType } from '../base/enum';\nimport { iterateExtend, setChecked, isComplexField, getObject } from '../base/util';\nimport { addRemoveEventListener } from '../base/util';\nimport * as literals from '../base/string-literals';\n/**\n * The `Selection` module is used to handle cell and row selection.\n */\nvar Selection = /** @class */ (function () {\n /**\n * Constructor for the Grid selection module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {SelectionSettings} selectionSettings - specifies the selectionsettings\n * @param {ServiceLocator} locator - specifies the ServiceLocator\n * @hidden\n */\n function Selection(parent, selectionSettings, locator) {\n //Internal letiables\n /**\n * @hidden\n */\n this.selectedRowIndexes = [];\n /**\n * @hidden\n */\n this.selectedRowCellIndexes = [];\n /**\n * @hidden\n */\n this.selectedRecords = [];\n /**\n * @hidden\n */\n this.preventFocus = false;\n /**\n * @hidden\n */\n this.selectedColumnsIndexes = [];\n this.checkBoxState = false;\n this.isMultiShiftRequest = false;\n this.isMultiCtrlRequest = false;\n this.isMultiCtrlRequestCell = false;\n this.enableSelectMultiTouch = false;\n this.clearRowCheck = false;\n this.selectRowCheck = false;\n this.selectedRowState = {};\n this.unSelectedRowState = {};\n this.totalRecordsCount = 0;\n this.chkAllCollec = [];\n this.isCheckedOnAdd = false;\n this.persistSelectedData = [];\n this.deSelectedData = [];\n this.isHdrSelectAllClicked = false;\n this.needColumnSelection = false;\n this.isCancelDeSelect = false;\n this.isPreventCellSelect = false;\n this.disableUI = false;\n this.isPersisted = false;\n this.cmdKeyPressed = false;\n this.cellselected = false;\n this.isMultiSelection = false;\n this.isAddRowsToSelection = false;\n this.initialRowSelection = false;\n this.isPrevRowSelection = false;\n this.isKeyAction = false;\n this.isRowDragSelected = false;\n this.isPartialSelection = false;\n this.rmtHdrChkbxClicked = false;\n this.isCheckboxReset = false;\n /**\n * @hidden\n */\n this.autoFillRLselection = true;\n this.bottom = '0 0 2px 0';\n this.top = '2px 0 0 0';\n /* eslint-disable */\n this.right_bottom = '0 2px 2px 0';\n this.bottom_left = '0 0 2px 2px';\n this.top_right = '2px 2px 0 0';\n this.top_left = '2px 0 0 2px';\n this.top_bottom = '2px 0 2px 0';\n this.top_right_bottom = '2px 2px 2px 0';\n this.top_bottom_left = '2px 0 2px 2px';\n this.top_right_left = '2px 2px 0 2px';\n this.right_bottom_left = '0 2px 2px 2px';\n this.all_border = '2px';\n this.parent = parent;\n this.selectionSettings = selectionSettings;\n this.factory = locator.getService('rendererFactory');\n this.focus = locator.getService('focus');\n this.addEventListener();\n this.wireEvents();\n }\n Selection.prototype.initializeSelection = function () {\n this.parent.log('selection_key_missing');\n this.render();\n };\n /**\n * The function used to trigger onActionBegin\n *\n * @param {Object} args - specifies the args\n * @param {string} type - specifies the type\n * @returns {void}\n * @hidden\n */\n Selection.prototype.onActionBegin = function (args, type) {\n this.parent.trigger(type, this.fDataUpdate(args));\n };\n Selection.prototype.fDataUpdate = function (args) {\n if (!this.isMultiSelection && (!isNullOrUndefined(args.cellIndex) || !isNullOrUndefined(args.rowIndex))) {\n var rowObj = this.getRowObj(isNullOrUndefined(args.rowIndex) ? isNullOrUndefined(args.cellIndex) ?\n this.currentIndex : args.cellIndex.rowIndex : args.rowIndex);\n args.foreignKeyData = rowObj.foreignKeyData;\n }\n return args;\n };\n /**\n * The function used to trigger onActionComplete\n *\n * @param {Object} args - specifies the args\n * @param {string} type - specifies the type\n * @returns {void}\n * @hidden\n */\n Selection.prototype.onActionComplete = function (args, type) {\n this.parent.trigger(type, this.fDataUpdate(args));\n this.isMultiSelection = false;\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Selection.prototype.getModuleName = function () {\n return 'selection';\n };\n /**\n * To destroy the selection\n *\n * @returns {void}\n * @hidden\n */\n Selection.prototype.destroy = function () {\n var gridElement = this.parent.element;\n if (!gridElement || (!gridElement.querySelector('.' + literals.gridHeader) && !gridElement.querySelector('.' + literals.gridContent))) {\n return;\n }\n this.hidePopUp();\n this.clearSelection();\n this.removeEventListener();\n this.unWireEvents();\n EventHandler.remove(this.parent.getContent(), 'mousedown', this.mouseDownHandler);\n EventHandler.remove(this.parent.getHeaderContent(), 'mousedown', this.mouseDownHandler);\n };\n Selection.prototype.isEditing = function () {\n return (this.parent.editSettings.mode === 'Normal' || (this.parent.editSettings.mode === 'Batch' && this.parent.editModule &&\n this.parent.editModule.formObj && !this.parent.editModule.formObj.validate())) &&\n this.parent.isEdit && !this.parent.isPersistSelection;\n };\n Selection.prototype.getCurrentBatchRecordChanges = function () {\n var gObj = this.parent;\n if (gObj.editSettings.mode === 'Batch' && gObj.editModule) {\n var currentRecords = iterateExtend(this.parent.getCurrentViewRecords());\n currentRecords = gObj.editSettings.newRowPosition === 'Bottom' ?\n currentRecords.concat(this.parent.editModule.getBatchChanges()[literals.addedRecords]) :\n this.parent.editModule.getBatchChanges()[literals.addedRecords].concat(currentRecords);\n var deletedRecords = this.parent.editModule.getBatchChanges()[literals.deletedRecords];\n var primaryKey = this.parent.getPrimaryKeyFieldNames()[0];\n for (var i = 0; i < (deletedRecords.length); i++) {\n for (var j = 0; j < currentRecords.length; j++) {\n if (deletedRecords[parseInt(i.toString(), 10)][\"\" + primaryKey] === currentRecords[parseInt(j.toString(), 10)][\"\" + primaryKey]) {\n currentRecords.splice(j, 1);\n break;\n }\n }\n }\n return currentRecords;\n }\n else if (this.parent.enableVirtualization && this.parent.groupSettings.columns.length && !this.parent.isPersistSelection) {\n var selectedGroupedData = gObj.getCurrentViewRecords().filter(function (col) { return col['key'] === undefined; });\n return selectedGroupedData;\n }\n else {\n return gObj.getCurrentViewRecords();\n }\n };\n /**\n * Selects a row by the given index.\n *\n * @param {number} index - Defines the row index.\n * @param {boolean} isToggle - If set to true, then it toggles the selection.\n * @returns {void}\n */\n Selection.prototype.selectRow = function (index, isToggle) {\n if (this.selectedRowIndexes.length && this.selectionSettings.enableSimpleMultiRowSelection) {\n this.addRowsToSelection([index]);\n return;\n }\n var gObj = this.parent;\n var selectedRow = gObj.getRowByIndex(index);\n var rowObj = selectedRow && gObj.getRowObjectFromUID(selectedRow.getAttribute('data-uid'));\n if (this.isPartialSelection && rowObj && rowObj.isDataRow && !rowObj.isSelectable) {\n return;\n }\n var selectData;\n var isRemoved = false;\n if (gObj.enableVirtualization && index > -1) {\n var e = { selectedIndex: index, isAvailable: true };\n this.parent.notify(events.selectVirtualRow, e);\n if (selectedRow && (gObj.getRowObjectFromUID(selectedRow.getAttribute('data-uid')))) {\n selectData = gObj.getRowObjectFromUID(selectedRow.getAttribute('data-uid')).data;\n }\n else {\n if (e.isAvailable && !gObj.selectionSettings.persistSelection) {\n var prevSelectedData = this.parent.getSelectedRecords();\n if (prevSelectedData.length > 0) {\n this.clearRowSelection();\n }\n }\n return;\n }\n }\n else {\n selectData = this.getRowObj(index).data;\n }\n if (!this.isRowType() || !selectedRow || this.isEditing()) {\n // if (this.isEditing()) {\n // gObj.selectedRowIndex = index;\n // }\n return;\n }\n var isRowSelected = selectedRow.hasAttribute('aria-selected');\n this.activeTarget();\n isToggle = !isToggle ? isToggle :\n !this.selectedRowIndexes.length ? false :\n (this.selectedRowIndexes.length === 1 ? (this.isKeyAction && this.parent.isCheckBoxSelection ?\n false : index === this.selectedRowIndexes[0]) : false);\n this.isKeyAction = false;\n var args;\n var can = 'cancel';\n if (!isToggle) {\n args = {\n data: selectData, rowIndex: index, isCtrlPressed: this.isMultiCtrlRequest,\n isShiftPressed: this.isMultiShiftRequest, row: selectedRow,\n previousRow: gObj.getRowByIndex(this.prevRowIndex),\n previousRowIndex: this.prevRowIndex, target: this.actualTarget, cancel: false, isInteracted: this.isInteracted,\n isHeaderCheckboxClicked: this.isHeaderCheckboxClicked\n };\n this.parent.trigger(events.rowSelecting, this.fDataUpdate(args), this.rowSelectingCallBack(args, isToggle, index, selectData, isRemoved, isRowSelected, can));\n }\n else {\n this.rowSelectingCallBack(args, isToggle, index, selectData, isRemoved, isRowSelected, can)(args);\n }\n };\n Selection.prototype.rowSelectingCallBack = function (args, isToggle, index, selectData, isRemoved, isRowSelected, can) {\n var _this = this;\n return function (args) {\n if (!isNullOrUndefined(args) && args[\"\" + can] === true) {\n _this.disableInteracted();\n return;\n }\n _this.index = index;\n _this.toggle = isToggle;\n _this.data = selectData;\n _this.removed = isRemoved;\n if (isRowSelected && _this.selectionSettings.persistSelection && !(_this.selectionSettings.checkboxMode === 'ResetOnRowClick')) {\n _this.clearSelectedRow(index);\n _this.selectRowCallBack();\n }\n else if (!isRowSelected && _this.selectionSettings.persistSelection &&\n _this.selectionSettings.checkboxMode !== 'ResetOnRowClick') {\n _this.selectRowCallBack();\n }\n if (_this.selectionSettings.checkboxMode === 'ResetOnRowClick') {\n _this.isCheckboxReset = true;\n _this.clearSelection();\n }\n if (!_this.selectionSettings.persistSelection || _this.selectionSettings.checkboxMode === 'ResetOnRowClick' ||\n (!_this.parent.isCheckBoxSelection && _this.selectionSettings.persistSelection)) {\n _this.selectRowCheck = true;\n _this.clearRow();\n }\n };\n };\n Selection.prototype.selectRowCallBack = function () {\n var gObj = this.parent;\n var args;\n var index = this.index;\n var isToggle = this.toggle;\n var selectData = this.data;\n var isRemoved = this.removed;\n var selectedRow = gObj.getRowByIndex(index);\n if (!isToggle && !isRemoved) {\n if (this.selectedRowIndexes.indexOf(index) <= -1) {\n this.updateRowSelection(selectedRow, index);\n }\n this.selectRowIndex(index);\n }\n if (!isToggle) {\n args = {\n data: selectData, rowIndex: index,\n row: selectedRow, previousRow: gObj.getRowByIndex(this.prevRowIndex),\n previousRowIndex: this.prevRowIndex, target: this.actualTarget, isInteracted: this.isInteracted,\n isHeaderCheckBoxClicked: this.isHeaderCheckboxClicked, rowIndexes: index\n };\n this.onActionComplete(args, events.rowSelected);\n }\n this.isInteracted = false;\n this.updateRowProps(index);\n };\n /**\n * Selects a range of rows from start and end row indexes.\n *\n * @param {number} startIndex - Specifies the start row index.\n * @param {number} endIndex - Specifies the end row index.\n * @returns {void}\n */\n Selection.prototype.selectRowsByRange = function (startIndex, endIndex) {\n this.selectRows(this.getCollectionFromIndexes(startIndex, endIndex));\n this.selectRowIndex(endIndex);\n };\n Selection.prototype.selectedDataUpdate = function (selectedData, foreignKeyData, selectedRows, rowIndexes, selectableRowIndex) {\n for (var i = 0, len = rowIndexes.length; i < len; i++) {\n var currentRow = this.parent.getDataRows()[rowIndexes[parseInt(i.toString(), 10)]];\n if (this.parent.enableVirtualization) {\n currentRow = this.parent.getRowByIndex(rowIndexes[parseInt(i.toString(), 10)]);\n }\n var rowObj = this.getRowObj(currentRow);\n if (rowObj && rowObj.isDataRow && rowObj.isSelectable) {\n selectedData.push(rowObj.data);\n selectedRows.push(currentRow);\n foreignKeyData.push(rowObj.foreignKeyData);\n }\n else {\n if (this.isPartialSelection && selectableRowIndex) {\n selectableRowIndex.splice(selectableRowIndex.indexOf(rowIndexes[parseInt(i.toString(), 10)]), 1);\n }\n }\n }\n };\n /**\n * Selects a collection of rows by index.\n *\n * @param {number[]} rowIndexes - Specifies an array of row indexes.\n * @returns {void}\n */\n Selection.prototype.selectRows = function (rowIndexes) {\n var _this = this;\n var gObj = this.parent;\n var selectableRowIndex = rowIndexes.slice();\n var rowIndex = !this.isSingleSel() ? rowIndexes[0] : rowIndexes[rowIndexes.length - 1];\n this.isMultiSelection = true;\n var selectedRows = [];\n var foreignKeyData = [];\n var can = 'cancel';\n var selectedData = [];\n if (!this.isRowType() || this.isEditing()) {\n return;\n }\n this.selectedDataUpdate(selectedData, foreignKeyData, selectedRows, rowIndexes, selectableRowIndex);\n this.activeTarget();\n var args = {\n cancel: false,\n rowIndexes: selectableRowIndex, row: selectedRows, rowIndex: rowIndex, target: this.actualTarget,\n prevRow: gObj.getRows()[this.prevRowIndex], previousRowIndex: this.prevRowIndex,\n isInteracted: this.isInteracted, isCtrlPressed: this.isMultiCtrlRequest, isShiftPressed: this.isMultiShiftRequest,\n data: selectedData, isHeaderCheckboxClicked: this.isHeaderCheckboxClicked, foreignKeyData: foreignKeyData\n };\n this.parent.trigger(events.rowSelecting, this.fDataUpdate(args), function (args) {\n if (!isNullOrUndefined(args) && args[\"\" + can] === true) {\n _this.disableInteracted();\n return;\n }\n if (!(gObj.allowRowDragAndDrop && _this.isDragged && _this.selectionSettings.persistSelection)) {\n _this.clearRow();\n }\n _this.selectRowIndex(selectableRowIndex.slice(-1)[0]);\n var selectRowFn = function (index, preventFocus) {\n _this.updateRowSelection(gObj.getRowByIndex(index), index, preventFocus);\n _this.updateRowProps(rowIndex);\n };\n if (!_this.isSingleSel()) {\n for (var _i = 0, selectableRowIndex_1 = selectableRowIndex; _i < selectableRowIndex_1.length; _i++) {\n var rowIdx = selectableRowIndex_1[_i];\n selectRowFn(rowIdx, gObj.enableVirtualization ? true : false);\n }\n }\n else {\n selectRowFn(rowIndex);\n }\n args = {\n rowIndexes: selectableRowIndex, row: selectedRows, rowIndex: rowIndex, target: _this.actualTarget,\n prevRow: gObj.getRows()[_this.prevRowIndex], previousRowIndex: _this.prevRowIndex,\n data: _this.getSelectedRecords(), isInteracted: _this.isInteracted,\n isHeaderCheckboxClicked: _this.isHeaderCheckboxClicked, foreignKeyData: foreignKeyData\n };\n if (_this.isRowSelected) {\n _this.onActionComplete(args, events.rowSelected);\n }\n _this.isInteracted = false;\n });\n };\n /**\n * Select rows with existing row selection by passing row indexes.\n *\n * @param {number} rowIndexes - Specifies the row indexes.\n * @returns {void}\n * @hidden\n */\n Selection.prototype.addRowsToSelection = function (rowIndexes) {\n var gObj = this.parent;\n var can = 'cancel';\n var target = this.target;\n this.isMultiSelection = true;\n var selectedRows = [];\n var foreignKeyData = [];\n var selectedData = [];\n var indexes = gObj.getSelectedRowIndexes().concat(rowIndexes);\n var selectedRow = !this.isSingleSel() ? gObj.getRowByIndex(rowIndexes[0]) :\n gObj.getRowByIndex(rowIndexes[rowIndexes.length - 1]);\n if ((!this.isRowType() || this.isEditing()) && !this.selectionSettings.checkboxOnly) {\n return;\n }\n var args;\n var checkboxColumn = this.parent.getColumns().filter(function (col) { return col.type === 'checkbox'; });\n if (this.isMultiCtrlRequest && !checkboxColumn.length) {\n this.selectedDataUpdate(selectedData, foreignKeyData, selectedRows, indexes);\n }\n for (var _i = 0, rowIndexes_1 = rowIndexes; _i < rowIndexes_1.length; _i++) {\n var rowIndex = rowIndexes_1[_i];\n var rowObj = this.getRowObj(rowIndex);\n var isUnSelected = this.selectedRowIndexes.indexOf(rowIndex) > -1;\n if (this.isPartialSelection && rowObj && rowObj.isDataRow && !rowObj.isSelectable) {\n continue;\n }\n this.selectRowIndex(rowIndex);\n if (isUnSelected && ((checkboxColumn.length ? true : this.selectionSettings.enableToggle) || this.isMultiCtrlRequest)) {\n this.isAddRowsToSelection = true;\n this.rowDeselect(events.rowDeselecting, [rowIndex], [rowObj.data], [selectedRow], [rowObj.foreignKeyData], target);\n if (this.isCancelDeSelect) {\n return;\n }\n this.selectedRowIndexes.splice(this.selectedRowIndexes.indexOf(rowIndex), 1);\n this.selectedRecords.splice(this.selectedRecords.indexOf(selectedRow), 1);\n this.selectRowIndex(this.selectedRowIndexes.length ? this.selectedRowIndexes[this.selectedRowIndexes.length - 1] : -1);\n selectedRow.removeAttribute('aria-selected');\n this.addRemoveClassesForRow(selectedRow, false, null, 'e-selectionbackground', 'e-active');\n this.rowDeselect(events.rowDeselected, [rowIndex], [rowObj.data], [selectedRow], [rowObj.foreignKeyData], target, undefined, undefined, undefined);\n this.isInteracted = false;\n this.isMultiSelection = false;\n this.isAddRowsToSelection = false;\n this.isHdrSelectAllClicked = false;\n }\n else {\n this.activeTarget();\n args = {\n cancel: false,\n data: selectedData.length ? selectedData : rowObj.data, rowIndex: rowIndex, row: selectedRows.length ? selectedRows :\n selectedRow, target: this.actualTarget, prevRow: gObj.getRows()[this.prevRowIndex],\n previousRowIndex: this.prevRowIndex, isCtrlPressed: this.isMultiCtrlRequest, isShiftPressed: this.isMultiShiftRequest,\n foreignKeyData: foreignKeyData.length ? foreignKeyData : rowObj.foreignKeyData, isInteracted: this.isInteracted,\n isHeaderCheckboxClicked: this.isHeaderCheckboxClicked, rowIndexes: indexes\n };\n this.parent.trigger(events.rowSelecting, this.fDataUpdate(args));\n if (!isNullOrUndefined(args) && args[\"\" + can] === true) {\n this.disableInteracted();\n return;\n }\n if (this.isSingleSel()) {\n this.clearRow();\n }\n this.updateRowSelection(selectedRow, rowIndex);\n }\n if (!isUnSelected) {\n args = {\n data: selectedData.length ? selectedData : rowObj.data, rowIndex: rowIndex, row: selectedRows.length ? selectedRows :\n selectedRow, target: this.actualTarget, prevRow: gObj.getRows()[this.prevRowIndex],\n previousRowIndex: this.prevRowIndex, foreignKeyData: foreignKeyData.length ? foreignKeyData : rowObj.foreignKeyData,\n isInteracted: this.isInteracted, isHeaderCheckboxClicked: this.isHeaderCheckboxClicked, rowIndexes: indexes\n };\n this.onActionComplete(args, events.rowSelected);\n }\n this.isInteracted = false;\n this.updateRowProps(rowIndex);\n if (this.isSingleSel()) {\n break;\n }\n }\n };\n Selection.prototype.getCollectionFromIndexes = function (startIndex, endIndex) {\n var indexes = [];\n // eslint-disable-next-line prefer-const\n var _a = (startIndex <= endIndex) ?\n { i: startIndex, max: endIndex } : { i: endIndex, max: startIndex }, i = _a.i, max = _a.max;\n for (; i <= max; i++) {\n indexes.push(i);\n }\n if (startIndex > endIndex) {\n indexes.reverse();\n }\n return indexes;\n };\n Selection.prototype.clearRow = function () {\n this.clearRowCheck = true;\n this.clearRowSelection();\n };\n Selection.prototype.clearRowCallBack = function () {\n if (this.isCancelDeSelect && this.parent.checkAllRows !== 'Check') {\n return;\n }\n this.selectedRowIndexes = [];\n this.selectedRecords = [];\n this.selectRowIndex(-1);\n if (this.isSingleSel() && this.parent.isPersistSelection) {\n this.selectedRowState = {};\n }\n };\n Selection.prototype.clearSelectedRow = function (index) {\n if (this.toggle) {\n var selectedEle = this.parent.getRowByIndex(index);\n if (!this.disableUI) {\n selectedEle.removeAttribute('aria-selected');\n this.addRemoveClassesForRow(selectedEle, false, true, 'e-selectionbackground', 'e-active');\n }\n this.removed = true;\n this.updatePersistCollection(selectedEle, false);\n this.updateCheckBoxes(selectedEle);\n this.selectedRowIndexes.splice(this.selectedRowIndexes.indexOf(index), 1);\n this.selectedRecords.splice(this.selectedRecords.indexOf(this.parent.getRowByIndex(index)), 1);\n }\n };\n Selection.prototype.updateRowProps = function (startIndex) {\n this.prevRowIndex = startIndex;\n this.isRowSelected = this.selectedRowIndexes.length && true;\n };\n Selection.prototype.getPkValue = function (pkField, data) {\n return pkField ? isComplexField(pkField) ? getObject(pkField, data) : data[\"\" + pkField] : data[\"\" + pkField];\n };\n Selection.prototype.updatePersistCollection = function (selectedRow, chkState) {\n var _this = this;\n if ((this.parent.isPersistSelection || this.parent.selectionSettings.persistSelection &&\n this.parent.getPrimaryKeyFieldNames().length > 0) && !isNullOrUndefined(selectedRow)) {\n if (!this.parent.isPersistSelection) {\n this.ensureCheckboxFieldSelection();\n }\n var rowObj = this.getRowObj(selectedRow);\n var pKey_1 = rowObj.data ? this.getPkValue(this.primaryKey, rowObj.data) : null;\n if (pKey_1 === null) {\n return;\n }\n rowObj.isSelected = chkState;\n if ((chkState && !this.isPartialSelection) || (this.isPartialSelection && rowObj.isSelectable && rowObj.isSelected)) {\n this.selectedRowState[\"\" + pKey_1] = chkState;\n delete (this.unSelectedRowState[\"\" + pKey_1]);\n if (!this.persistSelectedData.some(function (data) { return _this.getPkValue(_this.primaryKey, data) === pKey_1; })) {\n this.persistSelectedData.push(rowObj.data);\n }\n }\n else {\n this.updatePersistDelete(pKey_1);\n }\n }\n };\n Selection.prototype.updatePersistDelete = function (pKey, isPartialSelection) {\n var _this = this;\n delete (this.selectedRowState[\"\" + pKey]);\n if (this.rmtHdrChkbxClicked) {\n this.unSelectedRowState[\"\" + pKey] = true;\n }\n var index;\n var isPresent = this.persistSelectedData.some(function (data, i) {\n index = i;\n return _this.getPkValue(_this.primaryKey, data) === pKey;\n });\n if (isPresent) {\n this.persistSelectedData.splice(index, 1);\n if (isPartialSelection) {\n this.parent.partialSelectedRecords.splice(index, 1);\n }\n }\n };\n Selection.prototype.updateCheckBoxes = function (row, chkState, rowIndex) {\n if (!isNullOrUndefined(row)) {\n var chkBox = row.querySelector('.e-checkselect');\n if (!isNullOrUndefined(chkBox)) {\n removeAddCboxClasses(chkBox.nextElementSibling, chkState);\n setChecked(chkBox, chkState);\n if (isNullOrUndefined(this.checkedTarget) || (!isNullOrUndefined(this.checkedTarget)\n && !this.checkedTarget.classList.contains('e-checkselectall'))) {\n this.setCheckAllState(rowIndex);\n }\n }\n }\n };\n Selection.prototype.updateRowSelection = function (selectedRow, startIndex, preventFocus) {\n if (!selectedRow) {\n return;\n }\n if (this.selectedRowIndexes.indexOf(startIndex) === -1) {\n this.selectedRowIndexes.push(startIndex);\n this.selectedRecords.push(selectedRow);\n }\n selectedRow.setAttribute('aria-selected', 'true');\n this.updatePersistCollection(selectedRow, true);\n this.updateCheckBoxes(selectedRow, true);\n this.addRemoveClassesForRow(selectedRow, true, null, 'e-selectionbackground', 'e-active');\n if (!this.preventFocus) {\n var target = this.focus.getPrevIndexes().cellIndex ?\n selectedRow.cells[this.focus.getPrevIndexes().cellIndex] :\n selectedRow.querySelector('.e-selectionbackground:not(.e-hide):not(.e-detailrowcollapse):not(.e-detailrowexpand)');\n if (this.parent.contextMenuModule && this.mouseButton === 2) {\n target = this.parent.contextMenuModule.cell;\n }\n if (!target || preventFocus) {\n return;\n }\n this.focus.onClick({ target: target }, true);\n }\n };\n /**\n * Deselects the currently selected rows and cells.\n *\n * @returns {void}\n */\n Selection.prototype.clearSelection = function () {\n this.checkSelectAllClicked = true;\n if (this.selectionSettings.persistSelection && this.persistSelectedData.length) {\n this.deSelectedData = iterateExtend(this.persistSelectedData);\n }\n if (!this.parent.isPersistSelection || (this.parent.isPersistSelection && !this.parent.isEdit) ||\n (!isNullOrUndefined(this.checkedTarget) && this.checkedTarget.classList.contains('e-checkselectall'))) {\n var span = this.parent.element.querySelector('.e-gridpopup').querySelector('span');\n if (span.classList.contains('e-rowselect')) {\n span.classList.remove('e-spanclicked');\n }\n if (this.parent.isPersistSelection) {\n this.persistSelectedData = [];\n this.selectedRowState = {};\n }\n this.clearRowSelection();\n this.clearCellSelection();\n this.clearColumnSelection();\n this.prevRowIndex = undefined;\n this.prevCIdxs = undefined;\n this.prevECIdxs = undefined;\n this.enableSelectMultiTouch = false;\n this.isInteracted = false;\n this.checkSelectAllClicked = false;\n this.isHdrSelectAllClicked = false;\n }\n };\n /**\n * Deselects the currently selected rows.\n *\n * @returns {void}\n */\n Selection.prototype.clearRowSelection = function () {\n var _this = this;\n if (this.isRowSelected) {\n var rows_1 = this.parent.getDataRows();\n var data_1 = [];\n var row_1 = [];\n var rowIndex_1 = [];\n var foreignKeyData_1 = [];\n var target_1 = this.target;\n for (var i = 0, len = this.selectedRowIndexes.length; i < len; i++) {\n var currentRow = this.parent.editSettings.mode === 'Batch' ?\n this.parent.getRows()[this.selectedRowIndexes[parseInt(i.toString(), 10)]]\n : this.parent.getDataRows()[this.selectedRowIndexes[parseInt(i.toString(), 10)]];\n var rowObj = this.getRowObj(currentRow);\n if (rowObj) {\n data_1.push(rowObj.data);\n row_1.push(currentRow);\n rowIndex_1.push(this.selectedRowIndexes[parseInt(i.toString(), 10)]);\n foreignKeyData_1.push(rowObj.foreignKeyData);\n }\n }\n if (this.selectionSettings.persistSelection && this.selectionSettings.checkboxMode !== 'ResetOnRowClick') {\n this.isRowClicked = this.checkSelectAllClicked ? true : false;\n }\n this.rowDeselect(events.rowDeselecting, rowIndex_1, data_1, row_1, foreignKeyData_1, target_1, null, function () {\n if (_this.isCancelDeSelect && (_this.isRowClicked || _this.checkSelectAllClicked || (_this.isInteracted &&\n !_this.parent.isPersistSelection))) {\n if (_this.parent.isPersistSelection) {\n if (_this.getCheckAllStatus(_this.parent.element.querySelector('.e-checkselectall')) === 'Intermediate') {\n for (var i = 0; i < _this.selectedRecords.length; i++) {\n _this.updatePersistCollection(_this.selectedRecords[parseInt(i.toString(), 10)], true);\n }\n }\n else {\n _this.parent.checkAllRows = 'Check';\n _this.updatePersistSelectedData(true);\n }\n }\n if (_this.clearRowCheck) {\n _this.clearRowCallBack();\n _this.clearRowCheck = false;\n if (_this.selectRowCheck) {\n _this.selectRowCallBack();\n _this.selectRowCheck = false;\n }\n }\n return;\n }\n var element = [].slice.call(rows_1.filter(function (record) { return record.hasAttribute('aria-selected'); }));\n for (var j = 0; j < element.length; j++) {\n if (!_this.disableUI) {\n element[parseInt(j.toString(), 10)].removeAttribute('aria-selected');\n _this.addRemoveClassesForRow(element[parseInt(j.toString(), 10)], false, true, 'e-selectionbackground', 'e-active');\n }\n // tslint:disable-next-line:align\n if (!_this.isPrevRowSelection) {\n _this.updatePersistCollection(element[parseInt(j.toString(), 10)], false);\n }\n _this.updateCheckBoxes(element[parseInt(j.toString(), 10)]);\n }\n _this.selectedRowIndexes = [];\n _this.selectedRecords = [];\n _this.isRowSelected = false;\n _this.selectRowIndex(-1);\n _this.isPrevRowSelection = false;\n _this.rowDeselect(events.rowDeselected, rowIndex_1, data_1, row_1, foreignKeyData_1, target_1, null, undefined, null);\n if (_this.clearRowCheck) {\n _this.clearRowCallBack();\n _this.clearRowCheck = false;\n if (_this.selectRowCheck) {\n _this.selectRowCallBack();\n _this.selectRowCheck = false;\n }\n }\n }, null);\n }\n else {\n if (this.clearRowCheck) {\n this.clearRowCallBack();\n this.clearRowCheck = false;\n if (this.selectRowCheck) {\n this.selectRowCallBack();\n this.selectRowCheck = false;\n }\n }\n }\n };\n Selection.prototype.rowDeselect = function (type, rowIndex, data, row, foreignKeyData, target, mRow, rowDeselectCallBack, frozenRightRow) {\n var _this = this;\n if ((this.selectionSettings.persistSelection && (this.isRowClicked || this.checkSelectAllClicked || (this.focus['activeKey'] &&\n this.focus.currentInfo.element.classList.contains('e-gridchkbox') && this.focus['activeKey'] === 'space'))) ||\n !this.selectionSettings.persistSelection) {\n var cancl_1 = 'cancel';\n var isSingleDeSel = rowIndex.length === 1 && this.deSelectedData.length === 1;\n var rowDeselectObj = {\n rowIndex: rowIndex[0], data: this.selectionSettings.persistSelection && (this.parent.checkAllRows === 'Uncheck' &&\n !isSingleDeSel) && this.selectionSettings.checkboxMode !== 'ResetOnRowClick' ? this.deSelectedData : data,\n foreignKeyData: foreignKeyData, cancel: false, isInteracted: this.isInteracted,\n isHeaderCheckboxClicked: this.isHeaderCheckboxClicked\n };\n if (type === 'rowDeselected') {\n delete rowDeselectObj.cancel;\n }\n var rowInString = 'row';\n var target_2 = 'target';\n var rowidx = 'rowIndex';\n var rowidxex = 'rowIndexes';\n var dataTxt = 'data';\n var foreignKey = 'foreignKeyData';\n rowDeselectObj[\"\" + rowInString] = row;\n rowDeselectObj[\"\" + target_2] = this.actualTarget;\n var isHeaderCheckBxClick = this.actualTarget && !isNullOrUndefined(closest(this.actualTarget, 'thead'));\n if (isHeaderCheckBxClick || rowIndex.length > 1) {\n rowDeselectObj[\"\" + rowidx] = rowIndex[0];\n rowDeselectObj[\"\" + rowidxex] = rowIndex;\n }\n else if (rowIndex.length === 1) {\n rowDeselectObj[\"\" + dataTxt] = rowDeselectObj[\"\" + dataTxt][0];\n rowDeselectObj[\"\" + rowInString] = rowDeselectObj[\"\" + rowInString][0];\n rowDeselectObj[\"\" + foreignKey] = rowDeselectObj[\"\" + foreignKey][0];\n if (this.isAddRowsToSelection) {\n rowDeselectObj[\"\" + rowidxex] = rowIndex;\n }\n }\n this.parent.trigger(type, rowDeselectObj, function (args) {\n _this.isCancelDeSelect = args[\"\" + cancl_1];\n if (!_this.isCancelDeSelect || (!_this.isRowClicked && !_this.isInteracted && !_this.checkSelectAllClicked)) {\n _this.updatePersistCollection(row[0], false);\n _this.updateCheckBoxes(row[0], undefined, rowIndex[0]);\n }\n if (rowDeselectCallBack !== undefined) {\n rowDeselectCallBack();\n }\n });\n }\n else if (this.selectionSettings.persistSelection && !this.isInteracted) {\n if (rowDeselectCallBack !== undefined) {\n rowDeselectCallBack();\n }\n }\n };\n Selection.prototype.getRowObj = function (row) {\n if (row === void 0) { row = this.currentIndex; }\n if (isNullOrUndefined(row)) {\n return {};\n }\n if (typeof row === 'number') {\n row = this.parent.getRowByIndex(row);\n }\n if (row) {\n return this.parent.getRowObjectFromUID(row.getAttribute('data-uid')) || {};\n }\n return {};\n };\n /**\n * Selects a cell by the given index.\n *\n * @param {IIndex} cellIndex - Defines the row and column indexes.\n * @param {boolean} isToggle - If set to true, then it toggles the selection.\n * @returns {void}\n */\n Selection.prototype.selectCell = function (cellIndex, isToggle) {\n if (!this.isCellType()) {\n return;\n }\n var gObj = this.parent;\n var args;\n var selectedCell = gObj.getCellFromIndex(cellIndex.rowIndex, this.getColIndex(cellIndex.rowIndex, cellIndex.cellIndex));\n this.currentIndex = cellIndex.rowIndex;\n var selectedData = this.getCurrentBatchRecordChanges()[this.currentIndex];\n if (!this.isCellType() || !selectedCell || this.isEditing()) {\n return;\n }\n var isCellSelected = selectedCell.classList.contains('e-cellselectionbackground');\n isToggle = !isToggle ? isToggle : (!isUndefined(this.prevCIdxs) &&\n cellIndex.rowIndex === this.prevCIdxs.rowIndex && cellIndex.cellIndex === this.prevCIdxs.cellIndex &&\n isCellSelected);\n if (!isToggle) {\n args = {\n data: selectedData, cellIndex: cellIndex,\n isCtrlPressed: this.isMultiCtrlRequest, isShiftPressed: this.isMultiShiftRequest,\n previousRowCell: this.prevECIdxs ?\n this.getCellIndex(this.prevECIdxs.rowIndex, this.prevECIdxs.cellIndex) : undefined,\n cancel: false\n };\n var currentCell = 'currentCell';\n args[\"\" + currentCell] = selectedCell;\n var previousRowCellIndex = 'previousRowCellIndex';\n args[\"\" + previousRowCellIndex] = this.prevECIdxs;\n this.parent.trigger(events.cellSelecting, this.fDataUpdate(args), this.successCallBack(args, isToggle, cellIndex, selectedCell, selectedData));\n this.cellselected = true;\n }\n else {\n this.successCallBack(args, isToggle, cellIndex, selectedCell, selectedData)(args);\n }\n };\n Selection.prototype.successCallBack = function (cellSelectingArgs, isToggle, cellIndex, selectedCell, selectedData) {\n var _this = this;\n return function (cellSelectingArgs) {\n var cncl = 'cancel';\n var currentCell = 'currentCell';\n if (!isNullOrUndefined(cellSelectingArgs) && cellSelectingArgs[\"\" + cncl] === true) {\n return;\n }\n if (!isToggle) {\n cellSelectingArgs[\"\" + currentCell] = cellSelectingArgs[\"\" + currentCell] ? cellSelectingArgs[\"\" + currentCell] : selectedCell;\n }\n _this.clearCell();\n if (!isToggle) {\n _this.updateCellSelection(selectedCell, cellIndex.rowIndex, cellIndex.cellIndex);\n }\n if (!isToggle) {\n var args = {\n data: selectedData, cellIndex: cellIndex, currentCell: selectedCell,\n selectedRowCellIndex: _this.selectedRowCellIndexes,\n previousRowCell: _this.prevECIdxs ?\n _this.getCellIndex(_this.prevECIdxs.rowIndex, _this.prevECIdxs.cellIndex) : undefined\n };\n var previousRowCellIndex = 'previousRowCellIndex';\n args[\"\" + previousRowCellIndex] = _this.prevECIdxs;\n _this.updateCellProps(cellIndex, cellIndex);\n _this.onActionComplete(args, events.cellSelected);\n }\n };\n };\n Selection.prototype.getCellIndex = function (rIdx, cIdx) {\n return this.parent.getCellFromIndex(rIdx, cIdx);\n };\n /**\n * Selects a range of cells from start and end indexes.\n *\n * @param {IIndex} startIndex - Specifies the row and column's start index.\n * @param {IIndex} endIndex - Specifies the row and column's end index.\n * @returns {void}\n */\n Selection.prototype.selectCellsByRange = function (startIndex, endIndex) {\n var _this = this;\n if (!this.isCellType()) {\n return;\n }\n var gObj = this.parent;\n var selectedCell = gObj.getCellFromIndex(startIndex.rowIndex, startIndex.cellIndex);\n var min;\n var max;\n var stIndex = startIndex;\n var edIndex = endIndex = endIndex ? endIndex : startIndex;\n var cellIndexes;\n this.currentIndex = startIndex.rowIndex;\n var cncl = 'cancel';\n var selectedData = this.getCurrentBatchRecordChanges()[this.currentIndex];\n if (this.isSingleSel() || !this.isCellType() || this.isEditing()) {\n return;\n }\n var args = {\n data: selectedData, cellIndex: startIndex, currentCell: selectedCell,\n isCtrlPressed: this.isMultiCtrlRequest, isShiftPressed: this.isMultiShiftRequest,\n previousRowCell: this.prevECIdxs ? this.getCellIndex(this.prevECIdxs.rowIndex, this.prevECIdxs.cellIndex) : undefined\n };\n var previousRowCellIndex = 'previousRowCellIndex';\n args[\"\" + previousRowCellIndex] = this.prevECIdxs;\n this.parent.trigger(events.cellSelecting, this.fDataUpdate(args), function (cellSelectingArgs) {\n if (!isNullOrUndefined(cellSelectingArgs) && cellSelectingArgs[\"\" + cncl] === true) {\n return;\n }\n _this.clearCell();\n if (startIndex.rowIndex > endIndex.rowIndex) {\n var temp = startIndex;\n startIndex = endIndex;\n endIndex = temp;\n }\n for (var i = startIndex.rowIndex; i <= endIndex.rowIndex; i++) {\n if (_this.selectionSettings.cellSelectionMode.indexOf('Box') < 0) {\n min = i === startIndex.rowIndex ? (startIndex.cellIndex) : 0;\n max = i === endIndex.rowIndex ? (endIndex.cellIndex) : _this.getLastColIndex(i);\n }\n else {\n min = startIndex.cellIndex;\n max = endIndex.cellIndex;\n }\n cellIndexes = [];\n for (var j = min < max ? min : max, len = min > max ? min : max; j <= len; j++) {\n selectedCell = gObj.getCellFromIndex(i, j);\n if (!selectedCell) {\n continue;\n }\n cellIndexes.push(j);\n _this.updateCellSelection(selectedCell);\n _this.addAttribute(selectedCell);\n }\n _this.selectedRowCellIndexes.push({ rowIndex: i, cellIndexes: cellIndexes });\n }\n var cellSelectedArgs = {\n data: selectedData, cellIndex: edIndex, currentCell: gObj.getCellFromIndex(edIndex.rowIndex, edIndex.cellIndex),\n selectedRowCellIndex: _this.selectedRowCellIndexes,\n previousRowCell: _this.prevECIdxs ? _this.getCellIndex(_this.prevECIdxs.rowIndex, _this.prevECIdxs.cellIndex) : undefined\n };\n var previousRowCellIndex = 'previousRowCellIndex';\n cellSelectedArgs[\"\" + previousRowCellIndex] = _this.prevECIdxs;\n if (!_this.isDragged) {\n _this.onActionComplete(cellSelectedArgs, events.cellSelected);\n _this.cellselected = true;\n }\n _this.updateCellProps(stIndex, edIndex);\n });\n };\n /**\n * Selects a collection of cells by row and column indexes.\n *\n * @param {ISelectedCell[]} rowCellIndexes - Specifies the row and column indexes.\n * @returns {void}\n */\n Selection.prototype.selectCells = function (rowCellIndexes) {\n if (!this.isCellType()) {\n return;\n }\n var gObj = this.parent;\n var selectedCell = gObj.getCellFromIndex(rowCellIndexes[0].rowIndex, rowCellIndexes[0].cellIndexes[0]);\n this.currentIndex = rowCellIndexes[0].rowIndex;\n var selectedData = this.getCurrentBatchRecordChanges()[this.currentIndex];\n if (this.isSingleSel() || !this.isCellType() || this.isEditing()) {\n return;\n }\n var cellSelectArgs = {\n data: selectedData, cellIndex: rowCellIndexes[0].cellIndexes[0],\n currentCell: selectedCell, isCtrlPressed: this.isMultiCtrlRequest,\n isShiftPressed: this.isMultiShiftRequest,\n previousRowCell: this.prevECIdxs ? this.getCellIndex(this.prevECIdxs.rowIndex, this.prevECIdxs.cellIndex) : undefined\n };\n var previousRowCellIndex = 'previousRowCellIndex';\n cellSelectArgs[\"\" + previousRowCellIndex] = this.prevECIdxs;\n this.onActionBegin(cellSelectArgs, events.cellSelecting);\n for (var i = 0, len = rowCellIndexes.length; i < len; i++) {\n for (var j = 0, cellLen = rowCellIndexes[parseInt(i.toString(), 10)].cellIndexes.length; j < cellLen; j++) {\n selectedCell = gObj.getCellFromIndex(rowCellIndexes[parseInt(i.toString(), 10)].rowIndex, rowCellIndexes[parseInt(i.toString(), 10)].cellIndexes[parseInt(j.toString(), 10)]);\n if (!selectedCell) {\n continue;\n }\n this.updateCellSelection(selectedCell);\n this.addAttribute(selectedCell);\n this.addRowCellIndex({ rowIndex: rowCellIndexes[parseInt(i.toString(), 10)].rowIndex,\n cellIndex: rowCellIndexes[parseInt(i.toString(), 10)].cellIndexes[parseInt(j.toString(), 10)] });\n }\n }\n this.updateCellProps({ rowIndex: rowCellIndexes[0].rowIndex, cellIndex: rowCellIndexes[0].cellIndexes[0] }, { rowIndex: rowCellIndexes[0].rowIndex, cellIndex: rowCellIndexes[0].cellIndexes[0] });\n var cellSelectedArgs = {\n data: selectedData, cellIndex: rowCellIndexes[0].cellIndexes[0],\n currentCell: selectedCell, selectedRowCellIndex: this.selectedRowCellIndexes,\n previousRowCell: this.prevECIdxs ? this.getCellIndex(this.prevECIdxs.rowIndex, this.prevECIdxs.cellIndex) : undefined\n };\n var prvRowCellIndex = 'previousRowCellIndex';\n cellSelectedArgs[\"\" + prvRowCellIndex] = this.prevECIdxs;\n this.onActionComplete(cellSelectedArgs, events.cellSelected);\n };\n /**\n * Select cells with existing cell selection by passing row and column index.\n *\n * @param {IIndex} cellIndexes - Defines the collection of row and column index.\n * @returns {void}\n * @hidden\n */\n Selection.prototype.addCellsToSelection = function (cellIndexes) {\n if (!this.isCellType()) {\n return;\n }\n var gObj = this.parent;\n var selectedCell;\n var index;\n this.currentIndex = cellIndexes[0].rowIndex;\n var cncl = 'cancel';\n var selectedData = this.getCurrentBatchRecordChanges()[this.currentIndex];\n if (this.isSingleSel() || !this.isCellType() || this.isEditing()) {\n return;\n }\n this.hideAutoFill();\n var rowObj;\n rowObj = gObj.getRowsObject()[cellIndexes[0].rowIndex];\n if (gObj.groupSettings.columns.length > 0) {\n rowObj = gObj.getRowObjectFromUID(this.target.parentElement.getAttribute('data-uid'));\n }\n var foreignKeyData = [];\n for (var _i = 0, cellIndexes_1 = cellIndexes; _i < cellIndexes_1.length; _i++) {\n var cellIndex = cellIndexes_1[_i];\n for (var i = 0, len = this.selectedRowCellIndexes.length; i < len; i++) {\n if (this.selectedRowCellIndexes[parseInt(i.toString(), 10)].rowIndex === cellIndex.rowIndex) {\n index = i;\n break;\n }\n }\n selectedCell = gObj.getCellFromIndex(cellIndex.rowIndex, this.getColIndex(cellIndex.rowIndex, cellIndex.cellIndex));\n var idx = cellIndex.cellIndex;\n if (gObj.groupSettings.columns.length > 0) {\n foreignKeyData.push(rowObj.cells[idx + gObj.groupSettings.columns.length].foreignKeyData);\n }\n else {\n foreignKeyData.push(rowObj.cells[parseInt(idx.toString(), 10)].foreignKeyData);\n }\n var args = {\n cancel: false, data: selectedData, cellIndex: cellIndexes[0],\n isShiftPressed: this.isMultiShiftRequest,\n currentCell: selectedCell, isCtrlPressed: this.isMultiCtrlRequest,\n previousRowCell: this.prevECIdxs ?\n gObj.getCellFromIndex(this.prevECIdxs.rowIndex, this.prevECIdxs.cellIndex) : undefined\n };\n var prvRowCellIndex = 'previousRowCellIndex';\n args[\"\" + prvRowCellIndex] = this.prevECIdxs;\n var isUnSelected = index > -1;\n if (isUnSelected) {\n var selectedCellIdx = this.selectedRowCellIndexes[parseInt(index.toString(), 10)].cellIndexes;\n if (selectedCellIdx.indexOf(cellIndex.cellIndex) > -1 || (this.selectionSettings.mode === 'Both' &&\n selectedCell.classList.contains('e-gridchkbox') && !selectedCell.getAttribute('aria-selected'))) {\n this.cellDeselect(events.cellDeselecting, [{ rowIndex: cellIndex.rowIndex, cellIndexes: [cellIndex.cellIndex] }], selectedData, [selectedCell], foreignKeyData);\n selectedCellIdx.splice(selectedCellIdx.indexOf(cellIndex.cellIndex), 1);\n if (selectedCellIdx.length === 0) {\n this.selectedRowCellIndexes.splice(index, 1);\n }\n selectedCell.classList.remove('e-cellselectionbackground');\n selectedCell.removeAttribute('aria-selected');\n this.cellDeselect(events.cellDeselected, [{ rowIndex: cellIndex.rowIndex, cellIndexes: [cellIndex.cellIndex] }], selectedData, [selectedCell], foreignKeyData);\n }\n else {\n isUnSelected = false;\n this.onActionBegin(args, events.cellSelecting);\n this.addRowCellIndex({ rowIndex: cellIndex.rowIndex, cellIndex: cellIndex.cellIndex });\n this.updateCellSelection(selectedCell);\n this.addAttribute(selectedCell);\n }\n }\n else {\n this.onActionBegin(args, events.cellSelecting);\n if (!isNullOrUndefined(args) && args[\"\" + cncl] === true) {\n return;\n }\n this.updateCellSelection(selectedCell, cellIndex.rowIndex, cellIndex.cellIndex);\n }\n if (!isUnSelected) {\n var cellSelectedArgs = {\n data: selectedData, cellIndex: cellIndexes[0], currentCell: selectedCell,\n previousRowCell: this.prevECIdxs ? this.getCellIndex(this.prevECIdxs.rowIndex, this.prevECIdxs.cellIndex) :\n undefined, selectedRowCellIndex: this.selectedRowCellIndexes\n };\n cellSelectedArgs[\"\" + prvRowCellIndex] = this.prevECIdxs;\n this.onActionComplete(cellSelectedArgs, events.cellSelected);\n this.cellselected = true;\n }\n this.updateCellProps(cellIndex, cellIndex);\n }\n };\n Selection.prototype.getColIndex = function (rowIndex, index) {\n var col = this.parent.getColumnByIndex(index);\n var cells = getCellsByTableName(this.parent, col, rowIndex);\n if (cells) {\n for (var m = 0; m < cells.length; m++) {\n var colIndex = parseInt(cells[parseInt(m.toString(), 10)].getAttribute(literals.dataColIndex), 10);\n if (colIndex === index) {\n return m;\n }\n }\n }\n return -1;\n };\n Selection.prototype.getLastColIndex = function (rowIndex) {\n var cells = this.parent.getDataRows()[parseInt(rowIndex.toString(), 10)].querySelectorAll('td.e-rowcell');\n return parseInt(cells[cells.length - 1].getAttribute(literals.dataColIndex), 10);\n };\n Selection.prototype.clearCell = function () {\n this.clearCellSelection();\n };\n Selection.prototype.cellDeselect = function (type, cellIndexes, data, cells, foreignKeyData) {\n var cancl = 'cancel';\n if (cells && cells.length > 0) {\n for (var _i = 0, cells_1 = cells; _i < cells_1.length; _i++) {\n var cell = cells_1[_i];\n if (cell && cell.classList.contains(literals.gridChkBox)) {\n this.updateCheckBoxes(closest(cell, 'tr'));\n }\n }\n }\n var args = {\n cells: cells, data: data, cellIndexes: cellIndexes, foreignKeyData: foreignKeyData, cancel: false\n };\n this.parent.trigger(type, args);\n this.isPreventCellSelect = args[\"\" + cancl];\n };\n Selection.prototype.updateCellSelection = function (selectedCell, rowIndex, cellIndex) {\n if (!isNullOrUndefined(rowIndex)) {\n this.addRowCellIndex({ rowIndex: rowIndex, cellIndex: cellIndex });\n }\n selectedCell.classList.add('e-cellselectionbackground');\n if (selectedCell.classList.contains(literals.gridChkBox)) {\n this.updateCheckBoxes(closest(selectedCell, 'tr'), true);\n }\n this.addAttribute(selectedCell);\n };\n Selection.prototype.addAttribute = function (cell) {\n this.target = cell;\n if (!isNullOrUndefined(cell)) {\n cell.setAttribute('aria-selected', 'true');\n if (!this.preventFocus) {\n this.focus.onClick({ target: cell }, true);\n }\n }\n };\n Selection.prototype.updateCellProps = function (startIndex, endIndex) {\n this.prevCIdxs = startIndex;\n this.prevECIdxs = endIndex;\n this.isCellSelected = this.selectedRowCellIndexes.length && true;\n };\n Selection.prototype.addRowCellIndex = function (rowCellIndex) {\n var isRowAvail;\n var index;\n for (var i = 0, len = this.selectedRowCellIndexes.length; i < len; i++) {\n if (this.selectedRowCellIndexes[parseInt(i.toString(), 10)].rowIndex === rowCellIndex.rowIndex) {\n isRowAvail = true;\n index = i;\n break;\n }\n }\n if (isRowAvail) {\n if (this.selectedRowCellIndexes[parseInt(index.toString(), 10)].cellIndexes.indexOf(rowCellIndex.cellIndex) < 0) {\n this.selectedRowCellIndexes[parseInt(index.toString(), 10)].cellIndexes.push(rowCellIndex.cellIndex);\n }\n }\n else {\n this.selectedRowCellIndexes.push({ rowIndex: rowCellIndex.rowIndex, cellIndexes: [rowCellIndex.cellIndex] });\n }\n };\n /**\n * Deselects the currently selected cells.\n *\n * @returns {void}\n */\n Selection.prototype.clearCellSelection = function () {\n if (this.isCellSelected) {\n var gObj = this.parent;\n var selectedCells = this.getSelectedCellsElement();\n var rowCell = this.selectedRowCellIndexes;\n var data = [];\n var cells = [];\n var foreignKeyData = [];\n var currentViewData = this.getCurrentBatchRecordChanges();\n this.hideAutoFill();\n for (var i = 0, len = rowCell.length; i < len; i++) {\n data.push(currentViewData[rowCell[parseInt(i.toString(), 10)].rowIndex]);\n var rowObj = this.getRowObj(rowCell[parseInt(i.toString(), 10)].rowIndex);\n for (var j = 0, cLen = rowCell[parseInt(i.toString(), 10)].cellIndexes.length; j < cLen; j++) {\n if (rowObj.cells) {\n foreignKeyData.push(rowObj.cells[rowCell[parseInt(i.toString(), 10)]\n .cellIndexes[parseInt(j.toString(), 10)]].foreignKeyData);\n }\n cells.push(gObj.getCellFromIndex(rowCell[parseInt(i.toString(), 10)].rowIndex, rowCell[parseInt(i.toString(), 10)].cellIndexes[parseInt(j.toString(), 10)]));\n }\n }\n this.cellDeselect(events.cellDeselecting, rowCell, data, cells, foreignKeyData);\n if (this.isPreventCellSelect === true) {\n return;\n }\n for (var i = 0, len = selectedCells.length; i < len; i++) {\n selectedCells[parseInt(i.toString(), 10)].classList.remove('e-cellselectionbackground');\n selectedCells[parseInt(i.toString(), 10)].removeAttribute('aria-selected');\n }\n if (this.bdrElement) {\n this.showHideBorders('none');\n }\n this.selectedRowCellIndexes = [];\n this.isCellSelected = false;\n if (!this.isDragged && this.cellselected) {\n this.cellDeselect(events.cellDeselected, rowCell, data, cells, foreignKeyData);\n }\n }\n };\n Selection.prototype.getSelectedCellsElement = function () {\n var gObj = this.parent;\n var rows = gObj.getDataRows();\n var cells = [];\n for (var i = 0, len = rows.length; i < len; i++) {\n cells = cells.concat([].slice.call(rows[parseInt(i.toString(), 10)].getElementsByClassName('e-cellselectionbackground')));\n }\n return cells;\n };\n Selection.prototype.mouseMoveHandler = function (e) {\n e.preventDefault();\n this.stopTimer();\n var gBRect = this.parent.element.getBoundingClientRect();\n var x1 = this.x;\n var y1 = this.y;\n var position = getPosition(e);\n var x2 = position.x - gBRect.left;\n var y2 = position.y - gBRect.top;\n var tmp;\n var target = closest(e.target, 'tr');\n this.isDragged = true;\n if (!this.isCellDrag) {\n if (!target) {\n target = closest(document.elementFromPoint(this.parent.element.offsetLeft + 2, e.clientY), 'tr');\n }\n if (x1 > x2) {\n tmp = x2;\n x2 = x1;\n x1 = tmp;\n }\n if (y1 > y2) {\n tmp = y2;\n y2 = y1;\n y1 = tmp;\n }\n this.element.style.left = x1 + 'px';\n this.element.style.top = y1 + 'px';\n this.element.style.width = x2 - x1 + 'px';\n this.element.style.height = y2 - y1 + 'px';\n }\n if (target && !e.ctrlKey && !e.shiftKey) {\n var rowIndex = parseInt(target.getAttribute(literals.dataRowIndex), 10);\n if (!this.isCellDrag) {\n this.hideAutoFill();\n this.selectRowsByRange(this.startDIndex, rowIndex);\n this.isRowDragSelected = true;\n }\n else {\n var td = parentsUntil(e.target, literals.rowCell);\n if (td) {\n this.startAFCell = this.startCell;\n this.endAFCell = parentsUntil(e.target, literals.rowCell);\n if (rowIndex > -1) {\n this.selectLikeExcel(e, rowIndex, parseInt(td.getAttribute(literals.dataColIndex), 10));\n }\n }\n }\n }\n if (!e.ctrlKey && !e.shiftKey && !this.parent.enableVirtualization && !this.parent.enableInfiniteScrolling &&\n !this.parent.enableColumnVirtualization && !this.parent.groupSettings.columns.length && this.isCellDrag) {\n this.updateScrollPosition(e, position, this.parent.getContent());\n }\n };\n Selection.prototype.updateScrollPosition = function (e, position, scrollElem) {\n var _this = this;\n var cliRect = scrollElem.getBoundingClientRect();\n if (cliRect.left >= position.x - 20) {\n this.timer1 = window.setInterval(function () { _this.setScrollPosition(scrollElem.firstElementChild, 'left', e); }, 200);\n }\n else if (cliRect.left + scrollElem.clientWidth - 20 -\n (this.parent.height !== 'auto' ? getScrollBarWidth() : 0) < position.x) {\n this.timer1 = window.setInterval(function () { _this.setScrollPosition(scrollElem.firstElementChild, 'right', e); }, 200);\n }\n if (cliRect.top >= position.y - (this.parent.getRowHeight() * 0.5)) {\n this.timer2 = window.setInterval(function () { _this.setScrollPosition(scrollElem.firstElementChild, 'up', e); }, 200);\n }\n else if (cliRect.top + scrollElem.clientHeight - (this.parent.getRowHeight() * 0.5) -\n (scrollElem.firstElementChild.scrollWidth > scrollElem.firstElementChild.offsetWidth ?\n getScrollBarWidth() : 0) <= position.y) {\n this.timer2 = window.setInterval(function () { _this.setScrollPosition(scrollElem.firstElementChild, 'down', e); }, 200);\n }\n };\n Selection.prototype.stopTimer = function () {\n if (this.timer1) {\n window.clearInterval(this.timer1);\n this.timer1 = null;\n }\n if (this.timer2) {\n window.clearInterval(this.timer2);\n this.timer2 = null;\n }\n this.preventFocus = false;\n };\n Selection.prototype.setScrollPosition = function (scrollElem, direction, e) {\n var rowIndex = -1;\n var colIndex = -1;\n if (this.endAFCell || this.prevECIdxs) {\n rowIndex = this.endAFCell ? parseInt(this.endAFCell.getAttribute('index')) : this.prevECIdxs.rowIndex;\n colIndex = this.endAFCell ? parseInt(this.endAFCell.getAttribute('data-colindex')) : this.prevECIdxs.cellIndex;\n }\n switch (direction) {\n case 'up':\n if (e && closest(e.target, '.e-headercontent'))\n return;\n if (this.isAutoFillSel && this.selectedRowCellIndexes.length &&\n ((this.selectedRowCellIndexes.length === 1 && this.startAFCell !== this.startCell) ||\n (this.selectedRowCellIndexes.length > 1 && this.startAFCell.getBoundingClientRect().top > 0))) {\n rowIndex = parseInt(this.startAFCell.getAttribute('index'));\n }\n rowIndex -= 1;\n if (this.parent.frozenRows)\n rowIndex += this.parent.frozenRows + 1;\n rowIndex < 1 ? scrollElem.scrollTop = 0 : scrollElem.scrollTop -= this.parent.getRowByIndex(rowIndex).offsetHeight;\n break;\n case 'down':\n if (rowIndex < this.parent.getRows().length - 1) {\n rowIndex += 1;\n scrollElem.scrollTop += this.parent.getRowByIndex(rowIndex).offsetHeight;\n }\n else {\n scrollElem.scrollTop = scrollElem.scrollHeight;\n }\n break;\n case 'left':\n if (colIndex > 0 && rowIndex > -1) {\n if (this.isAutoFillSel && this.selectedRowCellIndexes.length &&\n ((this.selectedRowCellIndexes[0].cellIndexes.length > 0 && this.startAFCell !== this.startCell) ||\n (this.selectedRowCellIndexes[0].cellIndexes.length > 1 && this.startAFCell.getBoundingClientRect().left > 0))) {\n colIndex = parseInt(this.startAFCell.getAttribute('data-colindex'));\n }\n var nextEle = this.findNextCell(scrollElem, direction, colIndex, rowIndex);\n colIndex = nextEle ? parseInt(nextEle.getAttribute('data-colindex')) : -1;\n colIndex < 1 ? scrollElem.scrollLeft = 0 : scrollElem.scrollLeft -= nextEle.offsetWidth;\n }\n break;\n case 'right':\n if (colIndex < this.parent.columns.length - 1) {\n var nextEle = this.findNextCell(scrollElem, direction, colIndex, rowIndex);\n colIndex = nextEle ? parseInt(nextEle.getAttribute('data-colindex')) : -1;\n colIndex < this.parent.columns.length - 1 ? scrollElem.scrollLeft += nextEle.offsetWidth : scrollElem.scrollLeft = scrollElem.scrollWidth;\n }\n break;\n }\n if (rowIndex > -1 && colIndex > -1) {\n var e_1 = { target: this.parent.getCellFromIndex(rowIndex, colIndex) };\n this.endAFCell = e_1.target;\n this.preventFocus = true;\n this.selectLikeExcel(e_1, rowIndex, colIndex);\n }\n };\n Selection.prototype.findNextCell = function (scrollElem, direction, colInd, rowInd) {\n var nextEle = this.parent.getCellFromIndex(rowInd, direction === 'left' ? colInd - 1 : colInd + 1);\n if (nextEle && nextEle.classList.contains('e-hide')) {\n var siblingEles = nextEle.closest('tr').querySelectorAll('.e-rowcell:not(.e-hide)');\n var nextEleInd = Array.from(siblingEles).indexOf(nextEle.nextElementSibling);\n if (nextEleInd > 0 && nextEleInd < siblingEles.length - 1) {\n nextEle = siblingEles[nextEleInd + (direction === 'left' ? -1 : 1)];\n return nextEle;\n }\n else {\n scrollElem.scrollLeft = 0;\n return null;\n }\n }\n return nextEle;\n };\n Selection.prototype.selectLikeExcel = function (e, rowIndex, cellIndex) {\n if (!this.isAutoFillSel) {\n this.clearCellSelection();\n this.selectCellsByRange({ rowIndex: this.startDIndex, cellIndex: this.startDCellIndex }, { rowIndex: rowIndex, cellIndex: cellIndex });\n this.drawBorders();\n }\n else { //Autofill\n this.showAFBorders();\n this.selectLikeAutoFill(e);\n }\n };\n Selection.prototype.setFrozenBorders = function (parentEle, border, bdrStr) {\n var width = border.style.borderWidth.toString().split(' ');\n var strCell = ['', 'e-leftfreeze', 'e-unfreeze', 'e-leftfreeze', 'e-unfreeze', 'e-rightfreeze', 'e-rightfreeze'];\n var cells = [].slice.call(parentEle.querySelectorAll('.e-cellselectionbackground' + '.' + strCell[\"\" + bdrStr])).\n filter(function (ele) { return ele.style.display === ''; });\n var fixedCells = [].slice.call(parentEle.querySelectorAll('.e-cellselectionbackground.e-fixedfreeze')).\n filter(function (ele) { return ele.style.display === ''; });\n var isRtl = this.parent.enableRtl;\n if (cells.length) {\n var firstRowIdx = cells[0].getAttribute('index');\n var firstColIdx = cells[0].getAttribute('data-colindex');\n var lastRowIdx = cells[cells.length - 1].getAttribute('index');\n var lastColIdx = cells[cells.length - 1].getAttribute('data-colindex');\n for (var i = 0; i < cells.length; i++) {\n if (cells[parseInt(i.toString(), 10)].getAttribute('index') === firstRowIdx && (width.length === 1 || (width.length === 3\n && parseInt(width[0], 10) === 2) || (width.length === 4 && parseInt(width[0], 10) === 2))) {\n cells[parseInt(i.toString(), 10)].classList.add('e-xlsel-top-border');\n }\n if (cells[parseInt(i.toString(), 10)].getAttribute('data-colindex') === firstColIdx && (width.length === 1 ||\n (width.length === 3 && parseInt(width[1], 10) === 2) || (width.length === 4 && (((!isRtl && parseInt(width[3], 10) === 2)) ||\n (isRtl && parseInt(width[1], 10) === 2))))) {\n cells[parseInt(i.toString(), 10)].classList.add(isRtl ? 'e-xlsel-right-border' : 'e-xlsel-left-border');\n }\n if (cells[parseInt(i.toString(), 10)].getAttribute('index') === lastRowIdx && (width.length === 1 ||\n (width.length === 3 && parseInt(width[2], 10) === 2) || (width.length === 4 && parseInt(width[2], 10) === 2))) {\n cells[parseInt(i.toString(), 10)].classList.add('e-xlsel-bottom-border');\n }\n if (cells[parseInt(i.toString(), 10)].getAttribute('data-colindex') === lastColIdx && (width.length === 1 ||\n (width.length === 3 && parseInt(width[1], 10) === 2) || (width.length === 4 && ((!isRtl && parseInt(width[1], 10) === 2)) ||\n (isRtl && parseInt(width[3], 10) === 2)))) {\n cells[parseInt(i.toString(), 10)].classList.add(isRtl ? 'e-xlsel-left-border' : 'e-xlsel-right-border');\n }\n }\n }\n if (fixedCells.length) {\n var firstRowIdx = fixedCells[0].getAttribute('index');\n var firstColIdx = fixedCells[0].getAttribute('data-colindex');\n var lastRowIdx = fixedCells[fixedCells.length - 1].getAttribute('index');\n var lastColIdx = fixedCells[fixedCells.length - 1].getAttribute('data-colindex');\n for (var i = 0; i < fixedCells.length; i++) {\n var idx = fixedCells[parseInt(i.toString(), 10)].getAttribute('index');\n var colIdx = fixedCells[parseInt(i.toString(), 10)].getAttribute('data-colindex');\n if (idx === firstRowIdx &&\n ((!this.parent.getHeaderContent().querySelector('.e-cellselectionbackground.e-fixedfreeze')\n && parentsUntil(parentEle, 'e-content')) || !parentsUntil(parentEle, 'e-content'))) {\n fixedCells[parseInt(i.toString(), 10)].classList.add('e-xlsel-top-border');\n }\n if (idx === lastRowIdx &&\n ((!this.parent.getContent().querySelector('.e-cellselectionbackground.e-fixedfreeze')\n && parentsUntil(parentEle, 'e-headercontent')) || !parentsUntil(parentEle, 'e-headercontent'))) {\n fixedCells[parseInt(i.toString(), 10)].classList.add('e-xlsel-bottom-border');\n }\n var preCell = fixedCells[parseInt(i.toString(), 10)].parentElement.children[parseInt(colIdx, 10) - 1];\n if (colIdx === firstColIdx && (!preCell || (preCell && !preCell.classList.contains('e-cellselectionbackground')))) {\n fixedCells[parseInt(i.toString(), 10)].classList.add(isRtl ? 'e-xlsel-right-border' : 'e-xlsel-left-border');\n }\n var nextCell = fixedCells[parseInt(i.toString(), 10)].parentElement.children[parseInt(colIdx, 10) + 1];\n if (colIdx === lastColIdx && (!nextCell || (nextCell && !nextCell.classList.contains('e-cellselectionbackground')))) {\n fixedCells[parseInt(i.toString(), 10)].classList.add(isRtl ? 'e-xlsel-left-border' : 'e-xlsel-right-border');\n }\n }\n }\n };\n Selection.prototype.refreshFrozenBorders = function () {\n if (this.bdrElement) {\n this.setFrozenBorders(this.parent.getContentTable(), this.bdrElement, '1');\n if (this.parent.isFrozenGrid() && this.parent.getFrozenMode() === literals.leftRight) {\n this.setFrozenBorders(this.parent.getContentTable(), this.frcBdrElement, '5');\n }\n if (this.parent.frozenRows) {\n this.setFrozenBorders(this.parent.getHeaderTable(), this.fhBdrElement, '3');\n if (this.parent.isFrozenGrid() && this.parent.getFrozenMode() === literals.leftRight) {\n this.setFrozenBorders(this.parent.getHeaderTable(), this.frhBdrElement, '6');\n }\n }\n }\n };\n Selection.prototype.drawBorders = function () {\n if (this.selectionSettings.cellSelectionMode === 'BoxWithBorder' && this.selectedRowCellIndexes.length && !this.parent.isEdit) {\n this.parent.element.classList.add('e-enabledboxbdr');\n if (!this.bdrElement) {\n this.createBorders();\n }\n this.positionBorders();\n if (this.parent.isFrozenGrid()) {\n this.showHideBorders('none', true);\n this.refreshFrozenBorders();\n }\n }\n else {\n this.showHideBorders('none');\n }\n };\n Selection.prototype.isLastCell = function (cell) {\n var cells = [].slice.call(cell.parentElement.querySelectorAll('.e-rowcell:not(.e-hide)'));\n return cells[cells.length - 1] === cell;\n };\n Selection.prototype.isLastRow = function (cell) {\n var rows = [].slice.call(closest(cell, literals.tbody).querySelectorAll('.e-row:not(.e-hiddenrow)'));\n return cell.parentElement === rows[rows.length - 1];\n };\n Selection.prototype.isFirstRow = function (cell) {\n var rows = [].slice.call(closest(cell, literals.tbody).querySelectorAll('.e-row:not(.e-hiddenrow)'));\n return cell.parentElement === rows[0];\n };\n Selection.prototype.isFirstCell = function (cell) {\n var cells = [].slice.call(cell.parentElement.querySelectorAll('.e-rowcell:not(.e-hide)'));\n return cells[0] === cell;\n };\n Selection.prototype.setBorders = function (parentEle, border, bdrStr) {\n var cells = [].slice.call(parentEle.getElementsByClassName('e-cellselectionbackground')).\n filter(function (ele) { return ele.style.display === ''; });\n if (cells.length && this.parent.isFrozenGrid()) {\n var strCell = ['', 'e-leftfreeze', 'e-unfreeze', 'e-leftfreeze', 'e-unfreeze', 'e-rightfreeze', 'e-rightfreeze'];\n cells = [].slice.call(parentEle.querySelectorAll('.e-cellselectionbackground' + '.' + strCell[\"\" + bdrStr] + ':not(.e-hide)')).\n filter(function (ele) { return ele.style.display === ''; });\n }\n if (cells.length) {\n var isFrozen = this.parent.isFrozenGrid();\n var start = cells[0];\n var end = cells[cells.length - 1];\n var stOff = start.getBoundingClientRect();\n var endOff = end.getBoundingClientRect();\n var parentOff = start.offsetParent.getBoundingClientRect();\n if (start.offsetParent.classList.contains('e-content') || start.offsetParent.classList.contains('e-headercontent')) {\n parentOff = start.offsetParent.querySelector('table').getBoundingClientRect();\n }\n var rowHeight = !isFrozen && this.isLastRow(end) && (bdrStr === '1' || bdrStr === '2' || bdrStr === '5') ? 2 : 0;\n var topOffSet = 0;\n var leftOffset = isFrozen && (bdrStr === '2' || bdrStr === '4') && this.isFirstCell(start) ? 1 : 0;\n var rightOffset = ((this.parent.getFrozenMode() === 'Right' && (bdrStr === '1' || bdrStr === '3'))\n || (this.parent.getFrozenMode() === literals.leftRight && (bdrStr === '5' || bdrStr === '6')))\n && this.isFirstCell(start) ? 1 : 0;\n if (this.parent.enableRtl) {\n border.style.right = parentOff.right - stOff.right - leftOffset + 'px';\n border.style.width = stOff.right - endOff.left + leftOffset + 1 + 'px';\n }\n else {\n border.style.left = stOff.left - parentOff.left - leftOffset - rightOffset + 'px';\n border.style.width = endOff.right - stOff.left + leftOffset - rightOffset + 1 + 'px';\n }\n border.style.top = stOff.top - parentOff.top - topOffSet + 'px';\n border.style.height = endOff.top - stOff.top > 0 ?\n (endOff.top - parentOff.top + endOff.height + (isFrozen ? 0 : 1)) - (stOff.top - parentOff.top) - rowHeight + topOffSet + 'px' :\n endOff.height + topOffSet - rowHeight + (isFrozen ? 0 : 1) + 'px';\n this.selectDirection += bdrStr;\n }\n else {\n border.style.display = 'none';\n }\n };\n Selection.prototype.positionBorders = function () {\n this.updateStartEndCells();\n if (!this.startCell || !this.bdrElement || !this.selectedRowCellIndexes.length) {\n return;\n }\n this.selectDirection = '';\n this.showHideBorders('');\n this.setBorders(this.parent.getContentTable(), this.bdrElement, '1');\n if (this.parent.isFrozenGrid()) {\n this.setBorders(this.parent.getContentTable(), this.mcBdrElement, '2');\n if (this.parent.getFrozenMode() === literals.leftRight) {\n this.setBorders(this.parent.getContentTable(), this.frcBdrElement, '5');\n }\n }\n if (this.parent.frozenRows) {\n this.setBorders(this.parent.getHeaderTable(), this.fhBdrElement, '3');\n if (this.parent.isFrozenGrid()) {\n this.setBorders(this.parent.getHeaderTable(), this.mhBdrElement, '4');\n if (this.parent.getFrozenMode() === literals.leftRight) {\n this.setBorders(this.parent.getHeaderTable(), this.frhBdrElement, '6');\n }\n }\n }\n this.applyBorders(this.selectDirection);\n };\n /* eslint-enable */\n Selection.prototype.applyBothFrozenBorders = function (str) {\n var rtl = this.parent.enableRtl;\n switch (str.length) {\n case 6:\n {\n this.bdrElement.style.borderWidth = rtl ? this.right_bottom : this.bottom_left;\n this.mcBdrElement.style.borderWidth = this.bottom;\n this.fhBdrElement.style.borderWidth = rtl ? this.top_right : this.top_left;\n this.mhBdrElement.style.borderWidth = this.top;\n this.frcBdrElement.style.borderWidth = rtl ? this.bottom_left : this.right_bottom;\n this.frhBdrElement.style.borderWidth = rtl ? this.top_left : this.top_right;\n }\n break;\n case 4:\n {\n if (str.includes('1') && str.includes('2') && str.includes('3') && str.includes('4')) {\n this.fhBdrElement.style.borderWidth = rtl ? this.top_right : this.top_left;\n this.mhBdrElement.style.borderWidth = rtl ? this.top_left : this.top_right;\n this.bdrElement.style.borderWidth = rtl ? this.right_bottom : this.bottom_left;\n this.mcBdrElement.style.borderWidth = rtl ? this.bottom_left : this.right_bottom;\n }\n if (str.includes('2') && str.includes('4') && str.includes('5') && str.includes('6')) {\n this.mcBdrElement.style.borderWidth = rtl ? this.right_bottom : this.bottom_left;\n this.mhBdrElement.style.borderWidth = rtl ? this.top_right : this.top_left;\n this.frcBdrElement.style.borderWidth = rtl ? this.bottom_left : this.right_bottom;\n this.frhBdrElement.style.borderWidth = rtl ? this.top_left : this.top_right;\n }\n }\n break;\n case 3:\n {\n this.bdrElement.style.borderWidth = rtl ? this.top_right_bottom : this.top_bottom_left;\n this.mcBdrElement.style.borderWidth = this.top_bottom;\n this.frcBdrElement.style.borderWidth = rtl ? this.top_bottom_left : this.top_right_bottom;\n if (this.parent.frozenRows) {\n this.fhBdrElement.style.borderWidth = rtl ? this.top_right_bottom : this.top_bottom_left;\n this.mhBdrElement.style.borderWidth = this.top_bottom;\n this.frcBdrElement.style.borderWidth = rtl ? this.top_bottom_left : this.top_right_bottom;\n }\n }\n break;\n case 2:\n {\n if (str.includes('1')) {\n this.mcBdrElement.style.borderWidth = rtl ? this.top_bottom_left : this.top_right_bottom;\n if (this.parent.frozenRows) {\n this.fhBdrElement.style.borderWidth = this.top_right_left;\n }\n }\n if (str.includes('2')) {\n this.bdrElement.style.borderWidth = rtl ? this.top_right_bottom : this.top_bottom_left;\n this.frcBdrElement.style.borderWidth = rtl ? this.top_bottom_left : this.top_right_bottom;\n if (this.parent.frozenRows) {\n this.mhBdrElement.style.borderWidth = this.top_right_left;\n }\n }\n if (str.includes('3')) {\n this.mhBdrElement.style.borderWidth = rtl ? this.top_bottom_left : this.top_right_bottom;\n this.bdrElement.style.borderWidth = this.right_bottom_left;\n }\n if (str.includes('4')) {\n this.fhBdrElement.style.borderWidth = rtl ? this.top_right_bottom : this.top_bottom_left;\n this.frhBdrElement.style.borderWidth = rtl ? this.top_bottom_left : this.top_right_bottom;\n this.mcBdrElement.style.borderWidth = this.right_bottom_left;\n }\n if (str.includes('5')) {\n this.mcBdrElement.style.borderWidth = rtl ? this.top_right_bottom : this.top_bottom_left;\n if (this.parent.frozenRows) {\n this.frhBdrElement.style.borderWidth = this.top_right_left;\n }\n }\n if (str.includes('6')) {\n this.mhBdrElement.style.borderWidth = rtl ? this.top_right_bottom : this.top_bottom_left;\n this.frcBdrElement.style.borderWidth = this.right_bottom_left;\n }\n }\n break;\n default:\n this.bdrElement.style.borderWidth = this.all_border;\n this.mcBdrElement.style.borderWidth = this.all_border;\n this.frcBdrElement.style.borderWidth = this.all_border;\n if (this.parent.frozenRows) {\n this.fhBdrElement.style.borderWidth = this.all_border;\n this.mhBdrElement.style.borderWidth = this.all_border;\n this.frhBdrElement.style.borderWidth = this.all_border;\n }\n break;\n }\n };\n Selection.prototype.applyBorders = function (str) {\n var rtl = this.parent.enableRtl;\n if (this.parent.getFrozenMode() === literals.leftRight) {\n this.applyBothFrozenBorders(str);\n }\n else {\n switch (str.length) {\n case 4:\n {\n if (this.parent.getFrozenMode() === 'Right') {\n this.bdrElement.style.borderWidth = rtl ? this.bottom_left : this.right_bottom;\n this.mcBdrElement.style.borderWidth = rtl ? this.right_bottom : this.bottom_left;\n this.fhBdrElement.style.borderWidth = rtl ? this.top_left : this.top_right;\n this.mhBdrElement.style.borderWidth = rtl ? this.top_right : this.top_left;\n }\n else {\n this.bdrElement.style.borderWidth = rtl ? this.right_bottom : this.bottom_left;\n this.mcBdrElement.style.borderWidth = rtl ? this.bottom_left : this.right_bottom;\n this.fhBdrElement.style.borderWidth = rtl ? this.top_right : this.top_left;\n this.mhBdrElement.style.borderWidth = rtl ? this.top_left : this.top_right;\n }\n }\n break;\n case 2:\n {\n if (this.parent.getFrozenMode() === 'Right') {\n this.bdrElement.style.borderWidth = str.includes('2') ? rtl ? this.top_bottom_left\n : this.top_right_bottom : this.right_bottom_left;\n this.mcBdrElement.style.borderWidth = str.includes('1') ? rtl ? this.top_right_bottom\n : this.top_bottom_left : this.right_bottom_left;\n if (this.parent.frozenRows) {\n this.fhBdrElement.style.borderWidth = str.includes('1') ? this.top_right_left\n : rtl ? this.top_bottom_left : this.top_right_bottom;\n this.mhBdrElement.style.borderWidth = str.includes('2') ? this.top_right_left\n : rtl ? this.top_right_bottom : this.top_bottom_left;\n }\n }\n else {\n this.bdrElement.style.borderWidth = str.includes('2') ? rtl ? this.top_right_bottom\n : this.top_bottom_left : this.right_bottom_left;\n if (this.parent.isFrozenGrid()) {\n this.mcBdrElement.style.borderWidth = str.includes('1') ? rtl ? this.top_bottom_left\n : this.top_right_bottom : this.right_bottom_left;\n }\n if (this.parent.frozenRows) {\n this.fhBdrElement.style.borderWidth = str.includes('1') ? this.top_right_left\n : rtl ? this.top_right_bottom : this.top_bottom_left;\n if (this.parent.isFrozenGrid()) {\n this.mhBdrElement.style.borderWidth = str.includes('2') ? this.top_right_left\n : rtl ? this.top_bottom_left : this.top_right_bottom;\n }\n }\n }\n }\n break;\n default:\n this.bdrElement.style.borderWidth = this.all_border;\n if (this.parent.isFrozenGrid()) {\n this.mcBdrElement.style.borderWidth = this.all_border;\n }\n if (this.parent.frozenRows) {\n this.fhBdrElement.style.borderWidth = this.all_border;\n if (this.parent.isFrozenGrid()) {\n this.mhBdrElement.style.borderWidth = this.all_border;\n }\n }\n break;\n }\n }\n };\n Selection.prototype.createBorders = function () {\n if (!this.bdrElement) {\n this.bdrElement = this.parent.getContentTable().parentElement.appendChild(createElement('div', {\n className: 'e-xlsel', id: this.parent.element.id + '_bdr',\n styles: 'width: 2px; border-width: 0;'\n }));\n if (this.parent.isFrozenGrid()) {\n this.mcBdrElement = this.parent.getContentTable().parentElement.appendChild(createElement('div', {\n className: 'e-xlsel', id: this.parent.element.id + '_mcbdr',\n styles: 'height: 2px; border-width: 0;'\n }));\n if (this.parent.getFrozenMode() === literals.leftRight) {\n this.frcBdrElement = this.parent.getContentTable().parentElement.appendChild(createElement('div', {\n className: 'e-xlsel', id: this.parent.element.id + '_frcbdr',\n styles: 'height: 2px; border-width: 0;'\n }));\n }\n }\n if (this.parent.frozenRows) {\n this.fhBdrElement = this.parent.getHeaderTable().parentElement.appendChild(createElement('div', { className: 'e-xlsel', id: this.parent.element.id + '_fhbdr', styles: 'height: 2px;' }));\n }\n if (this.parent.frozenRows && this.parent.isFrozenGrid()) {\n this.mhBdrElement = this.parent.getHeaderTable().parentElement.appendChild(createElement('div', { className: 'e-xlsel', id: this.parent.element.id + '_mhbdr', styles: 'height: 2px;' }));\n if (this.parent.getFrozenMode() === literals.leftRight) {\n this.frhBdrElement = this.parent.getHeaderTable().parentElement.appendChild(createElement('div', { className: 'e-xlsel', id: this.parent.element.id + '_frhbdr', styles: 'height: 2px;' }));\n }\n }\n }\n };\n Selection.prototype.showHideBorders = function (display, freeze) {\n if (this.bdrElement) {\n this.bdrElement.style.display = display;\n if (this.parent.isFrozenGrid()) {\n var parentEle = this.parent.getContentTable();\n removeClass(parentEle.querySelectorAll('.e-xlsel-top-border'), 'e-xlsel-top-border');\n removeClass(parentEle.querySelectorAll('.e-xlsel-left-border'), 'e-xlsel-left-border');\n removeClass(parentEle.querySelectorAll('.e-xlsel-right-border'), 'e-xlsel-right-border');\n removeClass(parentEle.querySelectorAll('.e-xlsel-bottom-border'), 'e-xlsel-bottom-border');\n if (!freeze) {\n this.mcBdrElement.style.display = display;\n }\n if (this.parent.getFrozenMode() === literals.leftRight) {\n this.frcBdrElement.style.display = display;\n }\n }\n if (this.parent.frozenRows) {\n var parentEle = this.parent.getHeaderTable();\n removeClass(parentEle.querySelectorAll('.e-xlsel-top-border'), 'e-xlsel-top-border');\n removeClass(parentEle.querySelectorAll('.e-xlsel-left-border'), 'e-xlsel-left-border');\n removeClass(parentEle.querySelectorAll('.e-xlsel-right-border'), 'e-xlsel-right-border');\n removeClass(parentEle.querySelectorAll('.e-xlsel-bottom-border'), 'e-xlsel-bottom-border');\n this.fhBdrElement.style.display = display;\n }\n if (this.parent.frozenRows && this.parent.isFrozenGrid()) {\n if (!freeze) {\n this.mhBdrElement.style.display = display;\n }\n if (this.parent.getFrozenMode() === literals.leftRight) {\n this.frhBdrElement.style.display = display;\n }\n }\n }\n };\n Selection.prototype.drawAFBorders = function () {\n if (!this.bdrAFBottom) {\n this.createAFBorders();\n }\n this.positionAFBorders();\n };\n Selection.prototype.positionAFBorders = function () {\n if (!this.startCell || !this.bdrAFLeft) {\n return;\n }\n var stOff = this.startAFCell.getBoundingClientRect();\n var endOff = this.endAFCell.getBoundingClientRect();\n var top = endOff.top - stOff.top > 0 ? 1 : 0;\n var firstCellTop = endOff.top - stOff.top >= 0 && (parentsUntil(this.startAFCell, literals.movableContent) ||\n parentsUntil(this.startAFCell, 'e-frozencontent')) && this.isFirstRow(this.startAFCell) ? 1.5 : 0;\n var firstCellLeft = (parentsUntil(this.startAFCell, literals.movableContent) ||\n parentsUntil(this.startAFCell, literals.movableHeader)) && this.isFirstCell(this.startAFCell) ? 1 : 0;\n var rowHeight = this.isLastRow(this.endAFCell) && (parentsUntil(this.endAFCell, literals.movableContent) ||\n parentsUntil(this.endAFCell, 'e-frozencontent')) ? 2 : 0;\n var parentOff = this.startAFCell.offsetParent.getBoundingClientRect();\n var parentRect = this.parent.element.getBoundingClientRect();\n var sTop = this.startAFCell.offsetParent.parentElement.scrollTop;\n var sLeft = this.startAFCell.offsetParent.parentElement.scrollLeft;\n var scrollTop = sTop - this.startAFCell.offsetTop;\n var scrollLeft = sLeft - this.startAFCell.offsetLeft;\n var totalHeight = this.parent.element.clientHeight - getScrollBarWidth();\n if (this.parent.allowPaging) {\n totalHeight -= this.parent.element.querySelector('.e-pager').offsetHeight;\n }\n if (this.parent.aggregates.length) {\n totalHeight -= this.parent.getFooterContent().offsetHeight;\n }\n var totalWidth = this.parent.element.clientWidth - (this.parent.height !== 'auto' ? getScrollBarWidth() : 0);\n scrollTop = scrollTop > 0 ? Math.floor(scrollTop) - 1 : 0;\n scrollLeft = scrollLeft > 0 ? scrollLeft : 0;\n var left = stOff.left - parentRect.left;\n if (!this.parent.enableRtl) {\n this.bdrAFLeft.style.left = left - firstCellLeft + scrollLeft - 1 + 'px';\n this.bdrAFRight.style.left = endOff.left - parentRect.left - 2 + endOff.width + 'px';\n this.bdrAFRight.style.width = totalWidth <= parseInt(this.bdrAFRight.style.left, 10) ? '0px' : '2px';\n this.bdrAFTop.style.left = left + scrollLeft - 0.5 + 'px';\n this.bdrAFTop.style.width = parseInt(this.bdrAFRight.style.left, 10) - parseInt(this.bdrAFLeft.style.left, 10)\n - firstCellLeft + 1 + 'px';\n if (totalWidth <= (parseInt(this.bdrAFTop.style.width, 10) + parseInt(this.bdrAFTop.style.left, 10))) {\n var leftRemove = (parseInt(this.bdrAFTop.style.width, 10) + parseInt(this.bdrAFTop.style.left, 10)) - totalWidth;\n this.bdrAFTop.style.width = parseInt(this.bdrAFTop.style.width, 10) - leftRemove + 'px';\n }\n }\n else {\n var scrolloffSet = (parentsUntil(this.startAFCell, literals.movableContent) ||\n parentsUntil(this.startAFCell, literals.movableHeader)) ? stOff.right -\n this.startAFCell.offsetParent.parentElement.getBoundingClientRect().width -\n parentRect.left : 0;\n this.bdrAFLeft.style.right = parentRect.right - endOff.right - 2 + endOff.width + 'px';\n this.bdrAFLeft.style.width = totalWidth <= parseInt(this.bdrAFLeft.style.right, 10) ? '0px' : '2px';\n this.bdrAFRight.style.right = parentRect.right - stOff.right - firstCellLeft + scrolloffSet - 1 + 'px';\n this.bdrAFTop.style.left = endOff.left - parentRect.left - 0.5 + 'px';\n this.bdrAFTop.style.width = parseInt(this.bdrAFLeft.style.right, 10) - parseInt(this.bdrAFRight.style.right, 10)\n - firstCellLeft + 1 + 'px';\n if (parseInt(this.bdrAFTop.style.left, 10) < 0) {\n this.bdrAFTop.style.width = parseInt(this.bdrAFTop.style.width, 10) + parseInt(this.bdrAFTop.style.left, 10) + 'px';\n this.bdrAFTop.style.left = '0px';\n }\n }\n this.bdrAFLeft.style.top = stOff.top - parentRect.top - firstCellTop + scrollTop + 'px';\n this.bdrAFLeft.style.height = endOff.top - stOff.top > 0 ?\n (endOff.top - parentOff.top + endOff.height + 1) - (stOff.top - parentOff.top) + firstCellTop - rowHeight - scrollTop + 'px' :\n endOff.height + firstCellTop - rowHeight - scrollTop + 'px';\n this.bdrAFRight.style.top = this.bdrAFLeft.style.top;\n this.bdrAFRight.style.height = parseInt(this.bdrAFLeft.style.height, 10) + 'px';\n this.bdrAFTop.style.top = this.bdrAFRight.style.top;\n this.bdrAFBottom.style.left = this.bdrAFTop.style.left;\n this.bdrAFBottom.style.top = parseFloat(this.bdrAFLeft.style.top) + parseFloat(this.bdrAFLeft.style.height) - top - 1 + 'px';\n this.bdrAFBottom.style.width = totalHeight <= parseFloat(this.bdrAFBottom.style.top) ? '0px' : this.bdrAFTop.style.width;\n if (totalHeight <= (parseInt(this.bdrAFLeft.style.height, 10) + parseInt(this.bdrAFLeft.style.top, 10))) {\n var topRemove = parseInt(this.bdrAFLeft.style.height, 10) + parseInt(this.bdrAFLeft.style.top, 10) - totalHeight;\n this.bdrAFLeft.style.height = parseInt(this.bdrAFLeft.style.height, 10) - topRemove + 'px';\n this.bdrAFRight.style.height = parseInt(this.bdrAFLeft.style.height, 10) + 'px';\n }\n };\n Selection.prototype.createAFBorders = function () {\n if (!this.bdrAFLeft) {\n this.bdrAFLeft = this.parent.element.appendChild(createElement('div', { className: 'e-xlselaf', id: this.parent.element.id + '_bdrafleft', styles: 'width: 2px;' }));\n this.bdrAFRight = this.parent.element.appendChild(createElement('div', { className: 'e-xlselaf', id: this.parent.element.id + '_bdrafright', styles: 'width: 2px;' }));\n this.bdrAFBottom = this.parent.element.appendChild(createElement('div', { className: 'e-xlselaf', id: this.parent.element.id + '_bdrafbottom', styles: 'height: 2px;' }));\n this.bdrAFTop = this.parent.element.appendChild(createElement('div', { className: 'e-xlselaf', id: this.parent.element.id + '_bdraftop', styles: 'height: 2px;' }));\n }\n };\n Selection.prototype.showAFBorders = function () {\n if (this.bdrAFLeft) {\n this.bdrAFLeft.style.display = '';\n this.bdrAFRight.style.display = '';\n this.bdrAFBottom.style.display = '';\n this.bdrAFTop.style.display = '';\n }\n };\n Selection.prototype.hideAFBorders = function () {\n if (this.bdrAFLeft) {\n this.bdrAFLeft.style.display = 'none';\n this.bdrAFRight.style.display = 'none';\n this.bdrAFBottom.style.display = 'none';\n this.bdrAFTop.style.display = 'none';\n }\n };\n Selection.prototype.updateValue = function (rIdx, cIdx, cell) {\n var args = this.createBeforeAutoFill(rIdx, cIdx, cell);\n if (!args.cancel) {\n var col = this.parent.getColumnByIndex(cIdx);\n if (this.parent.editModule && cell) {\n if (col.type === 'number') {\n this.parent.editModule.updateCell(rIdx, col.field, parseFloat(args.value));\n }\n else {\n this.parent.editModule.updateCell(rIdx, col.field, args.value);\n }\n }\n }\n };\n Selection.prototype.createBeforeAutoFill = function (rowIndex, colIndex, cell) {\n var col = this.parent.getColumnByIndex(colIndex);\n var args = {\n column: col,\n value: cell.innerText\n };\n this.parent.trigger(events.beforeAutoFill, args);\n return args;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Selection.prototype.getAutoFillCells = function (rowIndex, startCellIdx) {\n var cls = '.e-cellselectionbackground';\n var cells = [].slice.call(this.parent.getDataRows()[parseInt(rowIndex.toString(), 10)].querySelectorAll(cls));\n return cells;\n };\n Selection.prototype.selectLikeAutoFill = function (e, isApply) {\n var startrowIdx = parseInt(parentsUntil(this.startAFCell, literals.row).getAttribute(literals.dataRowIndex), 10);\n var startCellIdx = parseInt(this.startAFCell.getAttribute(literals.dataColIndex), 10);\n var endrowIdx = parseInt(parentsUntil(this.endAFCell, literals.row).getAttribute(literals.dataRowIndex), 10);\n var endCellIdx = parseInt(this.endAFCell.getAttribute(literals.dataColIndex), 10);\n var rowLen = this.selectedRowCellIndexes.length - 1;\n var colLen = this.selectedRowCellIndexes[0].cellIndexes.length - 1;\n switch (true) { //direction\n case !isApply && this.endAFCell.classList.contains('e-cellselectionbackground') &&\n !!parentsUntil(e.target, literals.rowCell):\n this.startAFCell = this.parent.getCellFromIndex(startrowIdx, startCellIdx);\n this.endAFCell = this.parent.getCellFromIndex(startrowIdx + rowLen, startCellIdx + colLen);\n this.drawAFBorders();\n break;\n case this.autoFillRLselection && startCellIdx + colLen < endCellIdx && //right\n endCellIdx - startCellIdx - colLen + 1 > endrowIdx - startrowIdx - rowLen // right bottom\n && endCellIdx - startCellIdx - colLen + 1 > startrowIdx - endrowIdx: //right top\n this.endAFCell = this.parent.getCellFromIndex(startrowIdx + rowLen, endCellIdx);\n endrowIdx = parseInt(parentsUntil(this.endAFCell, literals.row).getAttribute(literals.dataRowIndex), 10);\n endCellIdx = parseInt(this.endAFCell.getAttribute(literals.dataColIndex), 10);\n if (!isApply) {\n this.drawAFBorders();\n }\n else {\n var cellIdx = parseInt(this.endCell.getAttribute(literals.dataColIndex), 10);\n for (var i = startrowIdx; i <= endrowIdx; i++) {\n var cells = this.getAutoFillCells(i, startCellIdx);\n var c = 0;\n for (var j = cellIdx + 1; j <= endCellIdx; j++) {\n if (c > colLen) {\n c = 0;\n }\n this.updateValue(i, j, cells[parseInt(c.toString(), 10)]);\n c++;\n }\n }\n this.selectCellsByRange({ rowIndex: startrowIdx, cellIndex: this.startCellIndex }, { rowIndex: endrowIdx, cellIndex: endCellIdx });\n }\n break;\n case this.autoFillRLselection && startCellIdx > endCellIdx && // left\n startCellIdx - endCellIdx + 1 > endrowIdx - startrowIdx - rowLen && //left top\n startCellIdx - endCellIdx + 1 > startrowIdx - endrowIdx: // left bottom\n this.startAFCell = this.parent.getCellFromIndex(startrowIdx, endCellIdx);\n this.endAFCell = this.endCell;\n if (!isApply) {\n this.drawAFBorders();\n }\n else {\n for (var i = startrowIdx; i <= startrowIdx + rowLen; i++) {\n var cells = this.getAutoFillCells(i, startCellIdx);\n cells.reverse();\n var c = 0;\n for (var j = this.startCellIndex - 1; j >= endCellIdx; j--) {\n if (c > colLen) {\n c = 0;\n }\n this.updateValue(i, j, cells[parseInt(c.toString(), 10)]);\n c++;\n }\n }\n this.selectCellsByRange({ rowIndex: startrowIdx, cellIndex: endCellIdx }, { rowIndex: startrowIdx + rowLen, cellIndex: this.startCellIndex + colLen });\n }\n break;\n case startrowIdx > endrowIdx: //up\n this.startAFCell = this.parent.getCellFromIndex(endrowIdx, startCellIdx);\n this.endAFCell = this.endCell;\n if (!isApply) {\n this.drawAFBorders();\n }\n else {\n var trIdx = parseInt(this.endCell.parentElement.getAttribute(literals.dataRowIndex), 10);\n var r = trIdx;\n for (var i = startrowIdx - 1; i >= endrowIdx; i--) {\n if (r === this.startIndex - 1) {\n r = trIdx;\n }\n var cells = this.getAutoFillCells(r, startCellIdx);\n var c = 0;\n r--;\n for (var j = this.startCellIndex; j <= this.startCellIndex + colLen; j++) {\n this.updateValue(i, j, cells[parseInt(c.toString(), 10)]);\n c++;\n }\n }\n this.selectCellsByRange({ rowIndex: endrowIdx, cellIndex: startCellIdx + colLen }, { rowIndex: startrowIdx + rowLen, cellIndex: startCellIdx });\n }\n break;\n default: //down\n this.endAFCell = this.parent.getCellFromIndex(endrowIdx, startCellIdx + colLen);\n if (!isApply) {\n this.drawAFBorders();\n }\n else {\n var trIdx = parseInt(this.endCell.parentElement.getAttribute(literals.dataRowIndex), 10);\n var r = this.startIndex;\n for (var i = trIdx + 1; i <= endrowIdx; i++) {\n if (r === trIdx + 1) {\n r = this.startIndex;\n }\n var cells = this.getAutoFillCells(r, startCellIdx);\n r++;\n var c = 0;\n for (var m = this.startCellIndex; m <= this.startCellIndex + colLen; m++) {\n this.updateValue(i, m, cells[parseInt(c.toString(), 10)]);\n c++;\n }\n }\n this.selectCellsByRange({ rowIndex: trIdx - rowLen, cellIndex: startCellIdx }, { rowIndex: endrowIdx, cellIndex: startCellIdx + colLen });\n }\n break;\n }\n };\n Selection.prototype.mouseUpHandler = function (e) {\n this.stopTimer();\n document.body.classList.remove('e-disableuserselect');\n if (this.element && !isNullOrUndefined(this.element.parentElement)) {\n remove(this.element);\n }\n if (this.isDragged && this.selectedRowCellIndexes.length === 1 && this.selectedRowCellIndexes[0].cellIndexes.length === 1) {\n this.mUPTarget = parentsUntil(e.target, literals.rowCell);\n }\n else {\n this.mUPTarget = null;\n }\n var closeRowCell = closest(e.target, '.e-rowcell');\n if (this.isDragged && !this.isAutoFillSel && this.selectionSettings.mode === 'Cell' &&\n closeRowCell && closeRowCell.classList.contains(literals.rowCell)) {\n var rowIndex = parseInt(closeRowCell.parentElement.getAttribute(literals.dataRowIndex), 10);\n var cellIndex = parseInt(closeRowCell.getAttribute(literals.dataColIndex), 10);\n this.isDragged = false;\n this.clearCellSelection();\n this.selectCellsByRange({ rowIndex: this.startDIndex, cellIndex: this.startDCellIndex }, { rowIndex: rowIndex, cellIndex: cellIndex });\n }\n this.isDragged = false;\n this.updateAutoFillPosition();\n if (this.isAutoFillSel) {\n this.preventFocus = true;\n var lastCell = parentsUntil(e.target, literals.rowCell);\n this.endAFCell = lastCell ? lastCell : this.endCell === this.endAFCell ? this.startAFCell : this.endAFCell;\n this.startAFCell = this.startCell;\n this.updateStartCellsIndex();\n this.selectLikeAutoFill(e, true);\n this.updateAutoFillPosition();\n this.hideAFBorders();\n this.positionBorders();\n if (this.parent.isFrozenGrid()) {\n this.showHideBorders('none', true);\n this.refreshFrozenBorders();\n }\n this.isAutoFillSel = false;\n if (this.parent.aggregates.length > 0) {\n this.parent.notify(events.refreshFooterRenderer, {});\n }\n this.preventFocus = false;\n }\n EventHandler.remove(this.parent.getContent(), 'mousemove', this.mouseMoveHandler);\n if (this.parent.frozenRows) {\n EventHandler.remove(this.parent.getHeaderContent(), 'mousemove', this.mouseMoveHandler);\n }\n EventHandler.remove(document, 'mouseup', this.mouseUpHandler);\n };\n Selection.prototype.hideAutoFill = function () {\n if (this.autofill) {\n this.autofill.style.display = 'none';\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Selection.prototype.updateAutoFillPosition = function () {\n if (this.parent.enableAutoFill && !this.parent.isEdit &&\n this.selectionSettings.cellSelectionMode.indexOf('Box') > -1 && !this.isRowType() && !this.isSingleSel()\n && this.selectedRowCellIndexes.length) {\n var index = parseInt(this.target.getAttribute(literals.dataColIndex), 10);\n var rindex = parseInt(this.target.getAttribute('index'), 10);\n var rowIndex = this.selectedRowCellIndexes[this.selectedRowCellIndexes.length - 1].rowIndex;\n var cells = this.getAutoFillCells(rowIndex, index).filter(function (ele) { return ele.style.display === ''; });\n var col = this.parent.getColumnByIndex(index);\n var isFrozenCol = col.getFreezeTableName() === 'movable';\n var isFrozenRow = rindex < this.parent.frozenRows;\n var isFrozenRight = this.parent.getFrozenMode() === literals.leftRight\n && col.getFreezeTableName() === literals.frozenRight;\n if (!select('#' + this.parent.element.id + '_autofill', parentsUntil(this.target, literals.table))) {\n if (select('#' + this.parent.element.id + '_autofill', this.parent.element)) {\n select('#' + this.parent.element.id + '_autofill', this.parent.element).remove();\n }\n this.autofill = createElement('div', { className: 'e-autofill', id: this.parent.element.id + '_autofill' });\n this.autofill.style.display = 'none';\n if (this.target.classList.contains('e-leftfreeze') || this.target.classList.contains('e-rightfreeze') ||\n this.target.classList.contains('e-fixedfreeze')) {\n this.autofill.classList.add('e-freeze-autofill');\n }\n if (!isFrozenRow) {\n if (!isFrozenCol) {\n this.parent.getContentTable().parentElement.appendChild(this.autofill);\n }\n else {\n this.parent.getContentTable().parentElement.appendChild(this.autofill);\n }\n }\n else {\n if (!isFrozenCol) {\n this.parent.getHeaderTable().parentElement.appendChild(this.autofill);\n }\n else {\n this.parent.getHeaderTable().parentElement.appendChild(this.autofill);\n }\n }\n if (isFrozenRight) {\n if (isFrozenRow) {\n this.parent.getHeaderTable().parentElement.appendChild(this.autofill);\n }\n else {\n this.parent.getContentTable().parentElement.appendChild(this.autofill);\n }\n }\n }\n var cell = cells[cells.length - 1];\n if (cell && cell.offsetParent) {\n var clientRect = cell.getBoundingClientRect();\n var parentOff = cell.offsetParent.getBoundingClientRect();\n if (cell.offsetParent.classList.contains('e-content') || cell.offsetParent.classList.contains('e-headercontent')) {\n parentOff = cell.offsetParent.querySelector('table').getBoundingClientRect();\n }\n var colWidth = this.isLastCell(cell) ? 4 : 0;\n var rowHeight = this.isLastRow(cell) ? 3 : 0;\n if (!this.parent.enableRtl) {\n this.autofill.style.left = clientRect.left - parentOff.left + clientRect.width - 4 - colWidth + 'px';\n }\n else {\n this.autofill.style.right = parentOff.right - clientRect.right + clientRect.width - 4 - colWidth + 'px';\n }\n this.autofill.style.top = clientRect.top - parentOff.top + clientRect.height - 5 - rowHeight + 'px';\n }\n this.autofill.style.display = '';\n }\n else {\n this.hideAutoFill();\n }\n };\n Selection.prototype.mouseDownHandler = function (e) {\n this.mouseButton = e.button;\n var target = e.target;\n var gObj = this.parent;\n var isDrag;\n var gridElement = parentsUntil(target, 'e-grid');\n if (gridElement && gridElement.id !== gObj.element.id || parentsUntil(target, literals.headerContent) && !this.parent.frozenRows ||\n parentsUntil(target, 'e-editedbatchcell') || parentsUntil(target, literals.editedRow)) {\n return;\n }\n if (e.shiftKey || e.ctrlKey) {\n e.preventDefault();\n }\n if (parentsUntil(target, literals.rowCell) && !e.shiftKey && !e.ctrlKey) {\n if (gObj.selectionSettings.cellSelectionMode.indexOf('Box') > -1 && !this.isRowType() && !this.isSingleSel()) {\n this.isCellDrag = true;\n isDrag = true;\n }\n else if (gObj.allowRowDragAndDrop && !gObj.isEdit && !this.parent.selectionSettings.checkboxOnly) {\n this.isRowDragSelected = false;\n if (!this.isRowType() || this.isSingleSel() || closest(target, 'td').classList.contains('e-selectionbackground')) {\n this.isDragged = false;\n return;\n }\n isDrag = true;\n this.element = this.parent.createElement('div', { className: 'e-griddragarea' });\n gObj.getContent().appendChild(this.element);\n }\n if (isDrag) {\n this.enableDrag(e, true);\n }\n }\n this.updateStartEndCells();\n if (target.classList.contains('e-autofill') || target.classList.contains('e-xlsel')) {\n this.isCellDrag = true;\n this.isAutoFillSel = true;\n this.enableDrag(e);\n }\n };\n Selection.prototype.updateStartEndCells = function () {\n var cells = [].slice.call(this.parent.element.getElementsByClassName('e-cellselectionbackground'));\n this.startCell = cells[0];\n this.endCell = cells[cells.length - 1];\n if (this.startCell) {\n this.startIndex = parseInt(this.startCell.parentElement.getAttribute(literals.dataRowIndex), 10);\n this.startCellIndex = parseInt(parentsUntil(this.startCell, literals.rowCell).getAttribute(literals.dataColIndex), 10);\n }\n };\n Selection.prototype.updateStartCellsIndex = function () {\n if (this.startCell) {\n this.startIndex = parseInt(this.startCell.parentElement.getAttribute(literals.dataRowIndex), 10);\n this.startCellIndex = parseInt(parentsUntil(this.startCell, literals.rowCell).getAttribute(literals.dataColIndex), 10);\n }\n };\n Selection.prototype.enableDrag = function (e, isUpdate) {\n var gObj = this.parent;\n if (isUpdate) {\n var tr = closest(e.target, 'tr');\n this.startDIndex = parseInt(tr.getAttribute(literals.dataRowIndex), 10);\n this.startDCellIndex = parseInt(parentsUntil(e.target, literals.rowCell).getAttribute(literals.dataColIndex), 10);\n }\n document.body.classList.add('e-disableuserselect');\n var gBRect = gObj.element.getBoundingClientRect();\n var postion = getPosition(e);\n this.x = postion.x - gBRect.left;\n this.y = postion.y - gBRect.top;\n EventHandler.add(gObj.getContent(), 'mousemove', this.mouseMoveHandler, this);\n if (this.parent.frozenRows) {\n EventHandler.add(gObj.getHeaderContent(), 'mousemove', this.mouseMoveHandler, this);\n }\n EventHandler.add(document, 'mouseup', this.mouseUpHandler, this);\n };\n Selection.prototype.clearSelAfterRefresh = function (e) {\n var isInfiniteScroll = this.parent.enableInfiniteScrolling && e.requestType === 'infiniteScroll';\n if (e.requestType !== 'virtualscroll' && !this.parent.isPersistSelection && !isInfiniteScroll) {\n this.clearSelection();\n }\n if ((e.requestType === 'virtualscroll' || isInfiniteScroll) && this.parent.isPersistSelection && this.isPartialSelection\n && this.isHdrSelectAllClicked) {\n var rowObj = this.parent.getRowsObject().filter(function (e) { return e.isSelectable; });\n var indexes = [];\n this.selectedRowState = {};\n this.persistSelectedData = [];\n for (var i = 0; i < rowObj.length; i++) {\n indexes.push(rowObj[parseInt(i.toString(), 10)].index);\n var pkValue = this.getPkValue(this.primaryKey, rowObj[parseInt(i.toString(), 10)].data);\n this.selectedRowState[\"\" + pkValue] = true;\n this.persistSelectedData.push(rowObj[parseInt(i.toString(), 10)].data);\n }\n this.selectedRowIndexes = indexes;\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Selection.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.evtHandlers = [{ event: events.uiUpdate, handler: this.enableAfterRender },\n { event: events.initialEnd, handler: this.initializeSelection },\n { event: events.rowSelectionComplete, handler: this.onActionComplete },\n { event: events.cellSelectionComplete, handler: this.onActionComplete },\n { event: events.inBoundModelChanged, handler: this.onPropertyChanged },\n { event: events.cellFocused, handler: this.onCellFocused },\n { event: events.beforeFragAppend, handler: this.clearSelAfterRefresh },\n { event: events.columnPositionChanged, handler: this.columnPositionChanged },\n { event: events.contentReady, handler: this.initialEnd },\n { event: events.rowsRemoved, handler: this.rowsRemoved },\n { event: events.headerRefreshed, handler: this.refreshHeader },\n { event: events.destroy, handler: this.destroy }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n this.actionBeginFunction = this.actionBegin.bind(this);\n this.actionCompleteFunction = this.actionComplete.bind(this);\n this.parent.addEventListener(events.actionBegin, this.actionBeginFunction);\n this.parent.addEventListener(events.actionComplete, this.actionCompleteFunction);\n this.addEventListener_checkbox();\n };\n /**\n * @returns {void}\n * @hidden\n */\n Selection.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n EventHandler.remove(document, 'mouseup', this.mouseUpHandler);\n EventHandler.remove(this.parent.getContent(), 'mousedown', this.mouseDownHandler);\n EventHandler.remove(this.parent.getHeaderContent(), 'mousedown', this.mouseDownHandler);\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n this.parent.removeEventListener(events.actionBegin, this.actionBeginFunction);\n this.parent.removeEventListener(events.actionComplete, this.actionCompleteFunction);\n this.removeEventListener_checkbox();\n };\n Selection.prototype.wireEvents = function () {\n this.isMacOS = navigator.userAgent.indexOf('Mac OS') !== -1;\n if (this.isMacOS) {\n EventHandler.add(this.parent.element, 'keydown', this.keyDownHandler, this);\n EventHandler.add(this.parent.element, 'keyup', this.keyUpHandler, this);\n }\n else {\n if (!this.parent.allowKeyboard) {\n EventHandler.add(this.parent.element, 'keydown', this.keyDownHandler, this);\n }\n }\n };\n Selection.prototype.unWireEvents = function () {\n if (this.isMacOS) {\n EventHandler.remove(this.parent.element, 'keydown', this.keyDownHandler);\n EventHandler.remove(this.parent.element, 'keyup', this.keyUpHandler);\n }\n else {\n if (!this.parent.allowKeyboard) {\n EventHandler.remove(this.parent.element, 'keydown', this.keyDownHandler);\n }\n }\n };\n Selection.prototype.columnPositionChanged = function () {\n if (!this.parent.isPersistSelection) {\n this.clearSelection();\n }\n };\n Selection.prototype.refreshHeader = function () {\n this.setCheckAllState();\n };\n Selection.prototype.rowsRemoved = function (e) {\n for (var i = 0; i < e.records.length; i++) {\n var pkValue = this.getPkValue(this.primaryKey, e.records[parseInt(i.toString(), 10)]);\n delete (this.selectedRowState[\"\" + pkValue]);\n --this.totalRecordsCount;\n }\n this.setCheckAllState();\n };\n Selection.prototype.beforeFragAppend = function (e) {\n if (e.requestType !== 'virtualscroll' && !this.parent.isPersistSelection) {\n this.clearSelection();\n }\n };\n Selection.prototype.getCheckAllBox = function () {\n return this.parent.getHeaderContent().querySelector('.e-checkselectall');\n };\n Selection.prototype.enableAfterRender = function (e) {\n if (e.module === this.getModuleName() && e.enable) {\n this.render();\n this.initPerisistSelection();\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Selection.prototype.render = function (e) {\n EventHandler.add(this.parent.getContent(), 'mousedown', this.mouseDownHandler, this);\n EventHandler.add(this.parent.getHeaderContent(), 'mousedown', this.mouseDownHandler, this);\n };\n Selection.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName()) {\n return;\n }\n var gObj = this.parent;\n if (!isNullOrUndefined(e.properties.type)) {\n if (this.selectionSettings.type === 'Single') {\n gObj.element.removeAttribute('aria-multiselectable');\n if (this.selectedRowCellIndexes.length > 1) {\n this.clearCellSelection();\n this.prevCIdxs = undefined;\n }\n if (this.selectedRowIndexes.length > 1) {\n this.clearRowSelection();\n this.prevRowIndex = undefined;\n }\n if (this.selectedColumnsIndexes.length > 1) {\n this.clearColumnSelection();\n this.prevColIndex = undefined;\n }\n this.enableSelectMultiTouch = false;\n this.hidePopUp();\n }\n else if (this.selectionSettings.type === 'Multiple') {\n gObj.element.setAttribute('aria-multiselectable', 'true');\n }\n }\n if (!isNullOrUndefined(e.properties.mode) ||\n !isNullOrUndefined(e.properties.cellSelectionMode)) {\n this.clearSelection();\n this.prevRowIndex = undefined;\n this.prevCIdxs = undefined;\n this.prevColIndex = undefined;\n }\n this.isPersisted = true;\n this.checkBoxSelectionChanged();\n this.isPersisted = false;\n if (!this.parent.isCheckBoxSelection) {\n this.initPerisistSelection();\n }\n var checkboxColumn = this.parent.getColumns().filter(function (col) { return col.type === 'checkbox'; });\n if (checkboxColumn.length) {\n gObj.isCheckBoxSelection = !(this.selectionSettings.checkboxMode === 'ResetOnRowClick');\n }\n this.drawBorders();\n };\n Selection.prototype.hidePopUp = function () {\n if (this.parent.element.querySelector('.e-gridpopup').getElementsByClassName('e-rowselect').length) {\n this.parent.element.querySelector('.e-gridpopup').style.display = 'none';\n }\n };\n Selection.prototype.initialEnd = function () {\n if (!this.selectedRowIndexes.length) {\n this.parent.off(events.contentReady, this.initialEnd);\n this.selectRow(this.parent.selectedRowIndex);\n }\n };\n Selection.prototype.checkBoxSelectionChanged = function () {\n var gobj = this.parent;\n gobj.off(events.contentReady, this.checkBoxSelectionChanged);\n var checkboxColumn = gobj.getColumns().filter(function (col) { return col.type === 'checkbox'; });\n if (checkboxColumn.length > 0) {\n gobj.isCheckBoxSelection = true;\n this.chkField = checkboxColumn[0].field;\n this.totalRecordsCount = this.parent.pageSettings.totalRecordsCount;\n if (isNullOrUndefined(this.totalRecordsCount)) {\n this.totalRecordsCount = this.getCurrentBatchRecordChanges().length;\n }\n if (this.isSingleSel()) {\n gobj.selectionSettings.type = 'Multiple';\n gobj.dataBind();\n }\n else {\n this.initPerisistSelection();\n }\n }\n if (!gobj.isCheckBoxSelection && !this.isPersisted) {\n this.chkField = null;\n this.initPerisistSelection();\n }\n };\n Selection.prototype.initPerisistSelection = function () {\n var gobj = this.parent;\n if (this.parent.selectionSettings.persistSelection && this.parent.getPrimaryKeyFieldNames().length > 0) {\n gobj.isPersistSelection = true;\n this.ensureCheckboxFieldSelection();\n }\n else if (this.parent.getPrimaryKeyFieldNames().length > 0) {\n gobj.isPersistSelection = false;\n this.ensureCheckboxFieldSelection();\n }\n else {\n gobj.isPersistSelection = false;\n this.selectedRowState = {};\n }\n };\n Selection.prototype.ensureCheckboxFieldSelection = function () {\n var gobj = this.parent;\n this.primaryKey = this.parent.getPrimaryKeyFieldNames()[0];\n if (!gobj.enableVirtualization && this.chkField\n && ((gobj.isPersistSelection && Object.keys(this.selectedRowState).length === 0) ||\n !gobj.isPersistSelection)) {\n var data = this.parent.getDataModule();\n var query = new Query().where(this.chkField, 'equal', true);\n if (!query.params) {\n query.params = this.parent.query.params;\n }\n var dataManager = data.getData({}, query);\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var proxy_1 = this;\n this.parent.showSpinner();\n dataManager.then(function (e) {\n proxy_1.dataSuccess(e.result);\n proxy_1.refreshPersistSelection();\n proxy_1.parent.hideSpinner();\n });\n }\n };\n Selection.prototype.dataSuccess = function (res) {\n var data = (this.parent.getDataModule().isRemote() && !isNullOrUndefined(res['result'])) ? res['result'] : res;\n for (var i = 0; i < data.length; i++) {\n var pkValue = this.getPkValue(this.primaryKey, data[parseInt(i.toString(), 10)]);\n if (isNullOrUndefined(this.selectedRowState[\"\" + pkValue]) && data[parseInt(i.toString(), 10)][this.chkField]) {\n this.selectedRowState[\"\" + pkValue] = data[parseInt(i.toString(), 10)][this.chkField];\n }\n }\n this.persistSelectedData = data;\n };\n Selection.prototype.setRowSelection = function (state) {\n if (!(this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result))) {\n if (state) {\n if (this.isPartialSelection && (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling)) {\n var rowObj = this.parent.getRowsObject().filter(function (e) { return e.isSelectable; });\n for (var _i = 0, rowObj_1 = rowObj; _i < rowObj_1.length; _i++) {\n var row = rowObj_1[_i];\n this.selectedRowState[this.getPkValue(this.primaryKey, row.data)] = true;\n }\n }\n else {\n var selectedData = this.isPartialSelection ? this.parent.partialSelectedRecords : this.getData();\n if (this.parent.groupSettings.columns.length) {\n for (var _a = 0, _b = this.isPartialSelection ? selectedData : selectedData.records; _a < _b.length; _a++) {\n var data = _b[_a];\n this.selectedRowState[this.getPkValue(this.primaryKey, data)] = true;\n }\n }\n else {\n for (var _c = 0, selectedData_1 = selectedData; _c < selectedData_1.length; _c++) {\n var data = selectedData_1[_c];\n this.selectedRowState[this.getPkValue(this.primaryKey, data)] = true;\n }\n }\n }\n }\n else {\n this.selectedRowState = {};\n }\n // (this.getData()).forEach(function (data) {\n // this.selectedRowState[data[this.primaryKey]] = true;\n // })\n }\n else {\n if (state) {\n var selectedStateKeys = Object.keys(this.selectedRowState);\n var unSelectedRowStateKeys = Object.keys(this.unSelectedRowState);\n if (!this.isCheckboxReset) {\n var rowData = (this.parent.groupSettings.columns.length && this.parent.isPersistSelection) ?\n this.parent.currentViewData['records'] : this.parent.currentViewData;\n for (var _d = 0, rowData_1 = rowData; _d < rowData_1.length; _d++) {\n var data = rowData_1[_d];\n if (!isNullOrUndefined(data[this.primaryKey])) {\n var key = data[this.primaryKey].toString();\n if (selectedStateKeys.indexOf(key) === -1 && unSelectedRowStateKeys.indexOf(key) === -1) {\n this.selectedRowState[data[this.primaryKey]] = true;\n }\n }\n }\n }\n }\n else {\n this.selectedRowState = {};\n this.unSelectedRowState = {};\n this.rmtHdrChkbxClicked = false;\n }\n }\n };\n Selection.prototype.getData = function () {\n return this.parent.getDataModule().dataManager.executeLocal(this.parent.getDataModule().generateQuery(true));\n };\n Selection.prototype.getAvailableSelectedData = function () {\n var filteredSearchedSelectedData = new DataManager(this.persistSelectedData).executeLocal(this.parent.getDataModule().generateQuery(true));\n if (this.parent.groupSettings.columns.length && filteredSearchedSelectedData &&\n filteredSearchedSelectedData.records) {\n filteredSearchedSelectedData = filteredSearchedSelectedData.records.slice();\n }\n return filteredSearchedSelectedData;\n };\n Selection.prototype.refreshPersistSelection = function () {\n var rows = this.parent.getRows();\n this.totalRecordsCount = this.parent.getCurrentViewRecords().length;\n if (this.parent.allowPaging) {\n this.totalRecordsCount = this.parent.pageSettings.totalRecordsCount;\n }\n if (!isNullOrUndefined(rows) && rows.length > 0 && (this.parent.isPersistSelection || this.chkField)) {\n var indexes = [];\n for (var j = 0; j < rows.length; j++) {\n var rowObj = this.getRowObj(rows[parseInt(j.toString(), 10)]);\n var pKey = rowObj ? rowObj.data ? this.getPkValue(this.primaryKey, rowObj.data) : null : null;\n if (pKey === null) {\n return;\n }\n if (this.isPartialSelection && !rowObj.isSelectable) {\n continue;\n }\n var checkState = void 0;\n var chkBox = rows[parseInt(j.toString(), 10)].querySelector('.e-checkselect');\n if (this.selectedRowState[\"\" + pKey] || (this.parent.checkAllRows === 'Check' && this.selectedRowState[\"\" + pKey] &&\n this.totalRecordsCount === Object.keys(this.selectedRowState).length && this.chkAllCollec.indexOf(pKey) < 0)\n || (this.parent.checkAllRows === 'Uncheck' && this.chkAllCollec.indexOf(pKey) > 0 && !this.parent.selectedRowIndex)\n || (this.parent.checkAllRows === 'Intermediate' && !isNullOrUndefined(this.chkField) && rowObj.data[this.chkField])) {\n indexes.push(parseInt(rows[parseInt(j.toString(), 10)].getAttribute(literals.dataRowIndex), 10));\n checkState = true;\n }\n else {\n checkState = false;\n if (this.checkedTarget !== chkBox && this.parent.isCheckBoxSelection && chkBox) {\n removeAddCboxClasses(chkBox.nextElementSibling, checkState);\n }\n }\n this.updatePersistCollection(rows[parseInt(j.toString(), 10)], checkState);\n }\n if (this.isSingleSel() && indexes.length > 0) {\n this.selectRow(indexes[0], true);\n }\n else {\n this.selectRows(indexes);\n }\n }\n if ((this.parent.isCheckBoxSelection || this.parent.selectionSettings.checkboxMode === 'ResetOnRowClick') && this.getCurrentBatchRecordChanges().length > 0) {\n this.setCheckAllState();\n }\n };\n Selection.prototype.actionBegin = function (e) {\n if (e.requestType === 'save' && this.parent.isPersistSelection) {\n var editChkBox = this.parent.element.querySelector('.e-edit-checkselect');\n if (!isNullOrUndefined(editChkBox)) {\n var row = closest(editChkBox, '.' + literals.editedRow);\n if (row) {\n if (this.parent.editSettings.mode === 'Dialog') {\n row = this.parent.element.querySelector('.e-dlgeditrow');\n }\n var rowObj = this.getRowObj(row);\n if (!rowObj) {\n return;\n }\n this.selectedRowState[this.getPkValue(this.primaryKey, rowObj.data)] = rowObj.isSelected = editChkBox.checked;\n }\n else {\n this.isCheckedOnAdd = editChkBox.checked;\n }\n }\n }\n if (this.parent.isPersistSelection && this.isPartialSelection) {\n if (e.requestType === 'paging' && (this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result))) {\n this.selectedRowIndexes = [];\n }\n if (e.requestType === 'filtering' || e.requestType === 'searching') {\n this.parent.partialSelectedRecords = [];\n this.parent.disableSelectedRecords = [];\n }\n }\n };\n Selection.prototype.actionComplete = function (e) {\n if (e.requestType === 'save' && this.parent.isPersistSelection) {\n if (e.action === 'add') {\n if (this.isCheckedOnAdd) {\n var rowObj = this.parent.getRowObjectFromUID(this.parent.getRows()[e.selectedRow].getAttribute('data-uid'));\n this.selectedRowState[this.getPkValue(this.primaryKey, rowObj.data)] = rowObj.isSelected = this.isCheckedOnAdd;\n }\n this.isHdrSelectAllClicked = false;\n this.setCheckAllState();\n }\n this.refreshPersistSelection();\n }\n if (e.requestType === 'delete' && this.parent.isPersistSelection) {\n var records = e.data;\n var data = records.slice();\n for (var i = 0; i < data.length; i++) {\n var pkValue = this.getPkValue(this.primaryKey, data[parseInt(i.toString(), 10)]);\n if (!isNullOrUndefined(pkValue)) {\n this.updatePersistDelete(pkValue, this.isPartialSelection);\n }\n }\n this.isHdrSelectAllClicked = false;\n this.setCheckAllState();\n this.totalRecordsCount = this.parent.pageSettings.totalRecordsCount;\n }\n if (e.requestType === 'paging') {\n if (this.parent.isPersistSelection && this.isPartialSelection && this.isHdrSelectAllClicked) {\n var rows = this.parent.getRowsObject();\n var indexes = [];\n for (var i = 0; i < rows.length; i++) {\n if (rows[parseInt(i.toString(), 10)].isSelectable) {\n indexes.push(rows[parseInt(i.toString(), 10)].index);\n }\n }\n if (indexes.length) {\n this.selectRows(indexes);\n }\n }\n this.prevRowIndex = undefined;\n this.prevCIdxs = undefined;\n this.prevECIdxs = undefined;\n }\n };\n Selection.prototype.onDataBound = function () {\n if (!this.parent.enableVirtualization && this.parent.isPersistSelection) {\n if (this.selectedRecords.length) {\n this.isPrevRowSelection = true;\n }\n }\n if ((this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result)) && this.rmtHdrChkbxClicked) {\n if (this.parent.checkAllRows === 'Intermediate') {\n this.setRowSelection(true);\n }\n else if (this.parent.checkAllRows === 'Uncheck') {\n this.setRowSelection(false);\n }\n }\n if (this.parent.enableVirtualization) {\n this.setCheckAllState();\n }\n if (this.parent.isPersistSelection) {\n this.refreshPersistSelection();\n }\n this.initialRowSelection = this.isRowType() && this.parent.element.querySelectorAll('.e-selectionbackground') &&\n this.parent.getSelectedRows().length ? true : false;\n if (this.parent.isCheckBoxSelection && !this.initialRowSelection) {\n var totalRecords = this.parent.getRowsObject();\n var indexes = [];\n for (var i = 0; i < totalRecords.length; i++) {\n if (totalRecords[parseInt(i.toString(), 10)].isSelected) {\n indexes.push(i);\n }\n }\n if (indexes.length) {\n this.selectRows(indexes);\n }\n this.initialRowSelection = true;\n }\n };\n Selection.prototype.updatePersistSelectedData = function (checkState) {\n if (this.parent.isPersistSelection) {\n var rows = this.parent.getRows();\n for (var i = 0; i < rows.length; i++) {\n this.updatePersistCollection(rows[parseInt(i.toString(), 10)], checkState);\n }\n if (this.parent.checkAllRows === 'Uncheck') {\n this.setRowSelection(false);\n this.persistSelectedData = (this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result))\n ? this.persistSelectedData : [];\n }\n else if (this.parent.checkAllRows === 'Check') {\n this.setRowSelection(true);\n this.persistSelectedData = !(this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result))\n && !this.isPartialSelection ?\n this.parent.groupSettings.columns.length ? this.getData().records.slice() :\n this.getData().slice() : this.persistSelectedData;\n }\n }\n };\n Selection.prototype.checkSelectAllAction = function (checkState) {\n var cRenderer = this.getRenderer();\n var editForm = this.parent.element.querySelector('.e-gridform');\n this.checkedTarget = this.getCheckAllBox();\n if (checkState && this.getCurrentBatchRecordChanges().length) {\n this.parent.checkAllRows = 'Check';\n this.updatePersistSelectedData(checkState);\n this.selectRowsByRange(cRenderer.getVirtualRowIndex(0), cRenderer.getVirtualRowIndex(this.getCurrentBatchRecordChanges().length - 1));\n }\n else {\n this.parent.checkAllRows = 'Uncheck';\n this.updatePersistSelectedData(checkState);\n this.clearSelection();\n }\n this.chkAllCollec = [];\n if (!isNullOrUndefined(editForm)) {\n var editChkBox = editForm.querySelector('.e-edit-checkselect');\n if (!isNullOrUndefined(editChkBox)) {\n removeAddCboxClasses(editChkBox.nextElementSibling, checkState);\n }\n }\n };\n Selection.prototype.checkSelectAll = function (checkBox) {\n var _this = this;\n var stateStr = this.getCheckAllStatus(checkBox);\n var state = stateStr === 'Check';\n this.isHeaderCheckboxClicked = true;\n if ((this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result)) && ((stateStr === 'Uncheck' || this.isCheckboxReset) ||\n (stateStr === 'Intermediate' && this.parent.isPersistSelection))) {\n this.rmtHdrChkbxClicked = true;\n }\n else {\n this.rmtHdrChkbxClicked = false;\n }\n if (this.rmtHdrChkbxClicked && this.isCheckboxReset) {\n this.unSelectedRowState = {};\n }\n this.isCheckboxReset = false;\n if (stateStr === 'Intermediate') {\n if (!this.chkField && !this.parent.isPersistSelection) {\n state = this.getCurrentBatchRecordChanges().some(function (data) {\n return _this.getPkValue(_this.primaryKey, data) in _this.selectedRowState;\n });\n }\n if ((this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result)) && this.parent.isPersistSelection) {\n for (var i = 0; i < this.getCurrentBatchRecordChanges().length; i++) {\n if (!isNullOrUndefined(this.getPkValue(this.primaryKey, this.getCurrentBatchRecordChanges()[\"\" + i]))) {\n if (Object.keys(this.selectedRowState).includes((this.getPkValue(this.primaryKey, this.getCurrentBatchRecordChanges()[\"\" + i])).toString())) {\n state = true;\n }\n else {\n state = false;\n break;\n }\n }\n }\n }\n }\n if (this.parent.isPersistSelection && this.parent.allowPaging) {\n this.totalRecordsCount = this.parent.pageSettings.totalRecordsCount;\n }\n this.checkSelectAllAction(!state);\n this.target = null;\n if (this.getCurrentBatchRecordChanges().length > 0) {\n this.setCheckAllState();\n this.updateSelectedRowIndexes();\n }\n this.triggerChkChangeEvent(checkBox, !state);\n };\n Selection.prototype.getCheckAllStatus = function (ele) {\n var classes = ele ? ele.nextElementSibling.classList :\n this.getCheckAllBox().nextElementSibling.classList;\n var status;\n if (classes.contains('e-check')) {\n status = 'Check';\n }\n else if (classes.contains('e-uncheck')) {\n status = 'Uncheck';\n }\n else if (classes.contains('e-stop')) {\n status = 'Intermediate';\n }\n else {\n status = 'None';\n }\n return status;\n };\n Selection.prototype.checkSelect = function (checkBox) {\n var target = closest(this.checkedTarget, '.' + literals.rowCell);\n var gObj = this.parent;\n this.isMultiCtrlRequest = true;\n var rIndex = 0;\n this.isHeaderCheckboxClicked = false;\n if (isGroupAdaptive(gObj)) {\n var uid = target.parentElement.getAttribute('data-uid');\n if (this.parent.enableVirtualization && this.parent.groupSettings.columns.length) {\n rIndex = parseInt(target.parentElement.getAttribute(literals.dataRowIndex), 10);\n }\n else {\n rIndex = gObj.getRows().map(function (m) { return m.getAttribute('data-uid'); }).indexOf(uid);\n }\n }\n else {\n rIndex = parseInt(target.parentElement.getAttribute(literals.dataRowIndex), 10);\n }\n if (this.parent.isPersistSelection && this.parent.element.getElementsByClassName(literals.addedRow).length > 0 &&\n this.parent.editSettings.newRowPosition === 'Top') {\n ++rIndex;\n }\n this.rowCellSelectionHandler(rIndex, parseInt(target.getAttribute(literals.dataColIndex), 10));\n this.moveIntoUncheckCollection(closest(target, '.' + literals.row));\n this.setCheckAllState();\n this.isMultiCtrlRequest = false;\n this.triggerChkChangeEvent(checkBox, checkBox.nextElementSibling.classList.contains('e-check'));\n };\n Selection.prototype.moveIntoUncheckCollection = function (row) {\n if (this.parent.checkAllRows === 'Check' || this.parent.checkAllRows === 'Uncheck') {\n var rowObj = this.getRowObj(row);\n var pKey = rowObj && rowObj.data ? this.getPkValue(this.primaryKey, rowObj.data) : null;\n if (!pKey) {\n return;\n }\n if (this.chkAllCollec.indexOf(pKey) < 0) {\n this.chkAllCollec.push(pKey);\n }\n else {\n this.chkAllCollec.splice(this.chkAllCollec.indexOf(pKey), 1);\n }\n }\n };\n Selection.prototype.triggerChkChangeEvent = function (checkBox, checkState) {\n this.parent.trigger(events.checkBoxChange, {\n checked: checkState, selectedRowIndexes: this.parent.getSelectedRowIndexes(),\n target: checkBox\n });\n if (!this.parent.isEdit) {\n this.checkedTarget = null;\n }\n };\n Selection.prototype.updateSelectedRowIndexes = function () {\n if (this.parent.isCheckBoxSelection && (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling) &&\n this.isPartialSelection && !(this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result))\n && this.parent.selectionSettings.persistSelection) {\n if (this.parent.checkAllRows !== 'Uncheck') {\n var rowObj = this.parent.getRowsObject().filter(function (e) { return e.isSelectable; });\n for (var _i = 0, rowObj_2 = rowObj; _i < rowObj_2.length; _i++) {\n var row = rowObj_2[_i];\n this.selectedRowIndexes.push(row.index);\n }\n }\n }\n if (this.parent.isCheckBoxSelection && this.parent.enableVirtualization && !this.isPartialSelection &&\n (this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result))\n && !this.parent.isPersistSelection && this.parent.checkAllRows === 'Check') {\n var rowObj = this.parent.getRowsObject().filter(function (e) { return e.isSelectable; });\n if (rowObj.length !== this.selectedRowIndexes.length) {\n for (var _a = 0, rowObj_3 = rowObj; _a < rowObj_3.length; _a++) {\n var row = rowObj_3[_a];\n if (this.selectedRowIndexes.indexOf(row.index) <= -1) {\n this.selectedRowIndexes.push(row.index);\n }\n }\n }\n }\n };\n Selection.prototype.updateSelectedRowIndex = function (index) {\n if (this.parent.isCheckBoxSelection && (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling)\n && !(this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result))\n && !this.isPartialSelection) {\n if (this.parent.checkAllRows === 'Check') {\n this.selectedRowIndexes = [];\n var dataLength = this.parent.groupSettings.columns.length ? this.getData()['records'].length :\n this.getData().length;\n for (var data = 0; data < dataLength; data++) {\n this.selectedRowIndexes.push(data);\n }\n }\n else if (this.parent.checkAllRows === 'Uncheck') {\n this.selectedRowIndexes = [];\n }\n else {\n var row = this.parent.getRowByIndex(index);\n if (index && row && row.getAttribute('aria-selected') === 'false') {\n var selectedVal = this.selectedRowIndexes.indexOf(index);\n this.selectedRowIndexes.splice(selectedVal, 1);\n }\n }\n }\n };\n Selection.prototype.isAllSelected = function (count) {\n if (this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result)) {\n return this.getAvailableSelectedData().length === (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling\n ? this.parent.totalDataRecordsCount : this.totalRecordsCount);\n }\n else {\n if (this.isPartialSelection) {\n if (this.parent.allowPaging && this.parent.pageSettings.pageSize < this.parent.pageSettings.totalRecordsCount) {\n var data = this.parent.partialSelectedRecords;\n for (var i = 0; i < data.length; i++) {\n var pKey = this.getPkValue(this.primaryKey, data[parseInt(i.toString(), 10)]);\n if (!this.selectedRowState[\"\" + pKey]) {\n return false;\n }\n }\n return true;\n }\n else {\n return this.isSelectAllRowCount(count);\n }\n }\n else {\n var data = (this.parent.groupSettings.columns.length) ? this.getData()['records'] : this.getData();\n for (var i = 0; i < data.length; i++) {\n var pKey = this.getPkValue(this.primaryKey, data[parseInt(i.toString(), 10)]);\n if (!this.selectedRowState[\"\" + pKey]) {\n return false;\n }\n }\n return true;\n }\n }\n };\n Selection.prototype.someDataSelected = function () {\n if ((this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result))\n && (this.parent.searchSettings.key.length || this.parent.filterSettings.columns.length)) {\n var filteredSearchedSelectedData = this.getAvailableSelectedData();\n for (var i = 0; i < filteredSearchedSelectedData.length; i++) {\n var pKey = this.getPkValue(this.primaryKey, filteredSearchedSelectedData[parseInt(i.toString(), 10)]);\n if (this.selectedRowState[\"\" + pKey]) {\n return false;\n }\n }\n }\n var data = this.isPartialSelection ? this.parent.partialSelectedRecords\n : (this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result)) ? [] : this.getData();\n for (var i = 0; i < data.length; i++) {\n var pKey = this.getPkValue(this.primaryKey, data[parseInt(i.toString(), 10)]);\n if (this.selectedRowState[\"\" + pKey]) {\n return false;\n }\n }\n return true;\n };\n Selection.prototype.setCheckAllState = function (index, isInteraction) {\n if (this.parent.isCheckBoxSelection || this.parent.selectionSettings.checkboxMode === 'ResetOnRowClick') {\n var checkToSelectAll = false;\n var isFiltered = false;\n var checkedLen = Object.keys(this.selectedRowState).length;\n if (!this.parent.isPersistSelection) {\n checkedLen = this.selectedRowIndexes.length;\n this.totalRecordsCount = this.getCurrentBatchRecordChanges().length;\n }\n if (this.parent.isPersistSelection && !((this.parent.getDataModule().isRemote() ||\n (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result)) &&\n this.isPartialSelection)\n && (this.parent.searchSettings.key.length || this.parent.filterSettings.columns.length)) {\n isFiltered = true;\n checkToSelectAll = this.isAllSelected(checkedLen);\n }\n var input = this.getCheckAllBox();\n if (input) {\n var spanEle = input.nextElementSibling;\n removeClass([spanEle], ['e-check', 'e-stop', 'e-uncheck']);\n setChecked(input, false);\n input.indeterminate = false;\n var getRecord = this.parent.getDataModule().isRemote() ? [] :\n (this.parent.groupSettings.columns.length) ? this.getData()['records'] : this.getData();\n if ((checkToSelectAll && isFiltered && (this.parent.getDataModule().isRemote() ||\n (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result) ||\n getRecord.length)) || (!isFiltered && ((checkedLen === this.totalRecordsCount && this.totalRecordsCount\n && !this.isPartialSelection && (!(this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result))\n || this.parent.allowPaging)) ||\n (!this.parent.enableVirtualization && !this.parent.enableInfiniteScrolling\n && this.isPartialSelection && (this.isSelectAllRowCount(checkedLen) || this.isHdrSelectAllClicked))\n || ((this.parent.enableVirtualization || this.parent.enableInfiniteScrolling)\n && !this.parent.allowPaging && ((!(this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result)) &&\n getRecord.length && checkedLen === getRecord.length) || ((this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result)) &&\n !this.isPartialSelection && ((checkedLen === this.parent.totalDataRecordsCount) || ((this.isSelectAllRowCount(checkedLen)\n || checkedLen === this.totalRecordsCount) && !this.parent.isPersistSelection))) ||\n (this.isPartialSelection && (this.isHdrSelectAllClicked || this.isSelectAllRowCount(checkedLen)))))\n || (checkedLen === this.totalRecordsCount && this.totalRecordsCount && !this.isPartialSelection &&\n !this.parent.allowPaging && !this.parent.enableVirtualization && !this.parent.enableInfiniteScrolling)))) {\n addClass([spanEle], ['e-check']);\n setChecked(input, true);\n if (isInteraction) {\n this.getRenderer().setSelection(null, true, true);\n }\n this.parent.checkAllRows = 'Check';\n }\n else if (((!this.selectedRowIndexes.length && (!this.parent.enableVirtualization ||\n (!this.persistSelectedData.length && !isFiltered) || (isFiltered && this.someDataSelected())) ||\n checkedLen === 0 && this.getCurrentBatchRecordChanges().length === 0) && !this.parent.allowPaging) ||\n (this.parent.allowPaging && (checkedLen === 0 || (checkedLen && isFiltered && this.someDataSelected())))) {\n addClass([spanEle], ['e-uncheck']);\n if (isInteraction) {\n this.getRenderer().setSelection(null, false, true);\n }\n this.parent.checkAllRows = 'Uncheck';\n }\n else {\n addClass([spanEle], ['e-stop']);\n this.parent.checkAllRows = 'Intermediate';\n input.indeterminate = true;\n }\n if (checkedLen === 0 && this.getCurrentBatchRecordChanges().length === 0) {\n addClass([spanEle.parentElement], ['e-checkbox-disabled']);\n }\n else {\n removeClass([spanEle.parentElement], ['e-checkbox-disabled']);\n }\n if (this.isPartialSelection) {\n var rowCount = this.parent.getRowsObject().filter(function (e) { return e.isSelectable; }).length;\n if (rowCount === 0 && spanEle.parentElement.querySelector('.e-frame').classList.contains('e-uncheck')) {\n addClass([spanEle.parentElement], ['e-checkbox-disabled']);\n }\n else {\n removeClass([spanEle.parentElement], ['e-checkbox-disabled']);\n }\n }\n if ((this.parent.enableVirtualization || this.parent.enableInfiniteScrolling)\n && !this.parent.allowPaging && !(this.parent.getDataModule().isRemote()\n || (!isNullOrUndefined(this.parent.dataSource) && this.parent.dataSource.result))) {\n this.updateSelectedRowIndex(index);\n }\n }\n }\n };\n Selection.prototype.isSelectAllRowCount = function (count) {\n var rowCount = 0;\n var rowObj = this.parent.getRowsObject();\n if (this.parent.selectionSettings.persistSelection && (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling)) {\n var dataLen = (this.parent.getDataModule().isRemote() || (!isNullOrUndefined(this.parent.dataSource)\n && this.parent.dataSource.result)) ?\n this.parent.totalDataRecordsCount : this.getData() && this.getData().length;\n if (dataLen === rowObj.length) {\n rowCount = rowObj.filter(function (e) { return e.isSelectable; }).length;\n return rowCount && count === rowCount;\n }\n else {\n return false;\n }\n }\n else {\n if (this.parent.allowPaging && this.parent.selectionSettings.persistSelection) {\n rowCount = this.parent.partialSelectedRecords.length + this.parent.disableSelectedRecords.length;\n if (rowCount === this.totalRecordsCount) {\n return this.parent.partialSelectedRecords.length && count === this.parent.partialSelectedRecords.length;\n }\n else {\n return false;\n }\n }\n else {\n rowCount = rowObj.filter(function (e) { return e.isSelectable; }).length;\n return rowCount && count === rowCount;\n }\n }\n };\n Selection.prototype.keyDownHandler = function (e) {\n // Below are keyCode for command key in MAC OS. Safari/Chrome(91-Left command, 93-Right Command), Opera(17), FireFox(224)\n if ((((Browser.info.name === 'chrome') || (Browser.info.name === 'safari')) && (e.keyCode === 91 || e.keyCode === 93)) ||\n (Browser.info.name === 'opera' && e.keyCode === 17) || (Browser.info.name === 'mozilla' && e.keyCode === 224)) {\n this.cmdKeyPressed = true;\n }\n var targetHeadCell = parentsUntil(e.target, 'e-headercell');\n var targetRowCell = parentsUntil(e.target, literals.rowCell);\n var isCheckBox = targetHeadCell ? targetHeadCell.children[0].classList.contains('e-headerchkcelldiv') :\n targetRowCell ? targetRowCell.classList.contains('e-gridchkbox') : false;\n if (isCheckBox && !this.parent.allowKeyboard && e.keyCode === 32) {\n e.preventDefault();\n }\n };\n Selection.prototype.keyUpHandler = function (e) {\n if ((((Browser.info.name === 'chrome') || (Browser.info.name === 'safari')) && (e.keyCode === 91 || e.keyCode === 93)) ||\n (Browser.info.name === 'opera' && e.keyCode === 17) || (Browser.info.name === 'mozilla' && e.keyCode === 224)) {\n this.cmdKeyPressed = false;\n }\n };\n Selection.prototype.clickHandler = function (e) {\n var target = e.target;\n this.actualTarget = target;\n if (this.selectionSettings.persistSelection) {\n this.deSelectedData = iterateExtend(this.persistSelectedData);\n }\n if (parentsUntil(target, literals.row) || parentsUntil(target, 'e-headerchkcelldiv') ||\n (this.selectionSettings.allowColumnSelection && target.classList.contains('e-headercell'))) {\n this.isInteracted = true;\n }\n this.cmdKeyPressed = e.metaKey;\n this.isMultiCtrlRequest = e.ctrlKey || this.enableSelectMultiTouch ||\n (this.isMacOS && this.cmdKeyPressed);\n if (!this.parent.allowKeyboard) {\n this.isMultiShiftRequest = false;\n this.isMultiCtrlRequest = false;\n }\n else {\n this.isMultiShiftRequest = e.shiftKey;\n }\n this.isMultiCtrlRequestCell = this.isMultiCtrlRequest;\n this.popUpClickHandler(e);\n var chkSelect = false;\n this.preventFocus = true;\n var checkBox;\n var checkWrap = parentsUntil(target, 'e-checkbox-wrapper');\n this.checkSelectAllClicked = checkWrap && checkWrap.getElementsByClassName('e-checkselectall') ||\n (this.selectionSettings.persistSelection && parentsUntil(target, literals.row)) ? true : false;\n if (this.selectionSettings.persistSelection && this.isPartialSelection && parentsUntil(target, 'e-headerchkcelldiv')\n && !target.querySelector('.e-checkbox-disabled')) {\n this.isHdrSelectAllClicked = true;\n }\n if (checkWrap && checkWrap.querySelectorAll('.e-checkselect,.e-checkselectall').length > 0) {\n checkBox = checkWrap.querySelector('input[type=\"checkbox\"]');\n chkSelect = true;\n }\n this.drawBorders();\n this.updateAutoFillPosition();\n target = parentsUntil(target, literals.rowCell);\n if (this.parent.isReact && (target && !target.parentElement && target.classList.contains('e-rowcell'))) {\n target = this.parent.getCellFromIndex(parseInt(target.getAttribute('index'), 10), parseInt(target.getAttribute('data-colindex'), 10));\n }\n if (this.isRowDragSelected && isNullOrUndefined(target) && this.parent.allowRowDragAndDrop &&\n this.selectionSettings.persistSelection && this.checkSelectAllClicked) {\n this.isRowDragSelected = false;\n }\n if (((target && target.parentElement.classList.contains(literals.row) && !this.parent.selectionSettings.checkboxOnly) || chkSelect)\n && !this.isRowDragSelected) {\n if (this.parent.isCheckBoxSelection) {\n this.isMultiCtrlRequest = true;\n }\n this.target = target;\n if (!isNullOrUndefined(checkBox)) {\n this.checkedTarget = checkBox;\n if (checkBox.classList.contains('e-checkselectall')) {\n this.checkSelectAll(checkBox);\n }\n else {\n this.checkSelect(checkBox);\n }\n }\n else {\n var gObj = this.parent;\n var rIndex = 0;\n if (isGroupAdaptive(gObj)) {\n var uid = target.parentElement.getAttribute('data-uid');\n rIndex = gObj.getRows().map(function (m) { return m.getAttribute('data-uid'); }).indexOf(uid);\n }\n else {\n rIndex = parseInt(target.parentElement.getAttribute(literals.dataRowIndex), 10);\n }\n if (this.parent.isPersistSelection && this.parent.element.getElementsByClassName(literals.addedRow).length > 0) {\n ++rIndex;\n }\n if (!this.mUPTarget || !this.mUPTarget.isEqualNode(target)) {\n this.rowCellSelectionHandler(rIndex, parseInt(target.getAttribute(literals.dataColIndex), 10));\n }\n if (this.parent.isCheckBoxSelection) {\n this.moveIntoUncheckCollection(closest(target, '.' + literals.row));\n this.setCheckAllState();\n }\n }\n if (!this.parent.isCheckBoxSelection && Browser.isDevice && !this.isSingleSel()) {\n this.showPopup(e);\n }\n }\n else if (e.target.classList.contains('e-headercell') &&\n !e.target.classList.contains('e-stackedheadercell')) {\n var uid = e.target.querySelector('.e-headercelldiv').getAttribute('e-mappinguid');\n this.headerSelectionHandler(this.parent.getColumnIndexByUid(uid));\n }\n this.isMultiCtrlRequest = false;\n this.isMultiCtrlRequestCell = this.isMultiCtrlRequest;\n this.isMultiShiftRequest = false;\n if (isNullOrUndefined(closest(e.target, '.e-unboundcell'))) {\n this.preventFocus = false;\n }\n };\n Selection.prototype.popUpClickHandler = function (e) {\n var target = e.target;\n if (closest(target, '.e-headercell') || e.target.classList.contains(literals.rowCell) ||\n closest(target, '.e-gridpopup')) {\n if (target.classList.contains('e-rowselect')) {\n if (!target.classList.contains('e-spanclicked')) {\n target.classList.add('e-spanclicked');\n this.enableSelectMultiTouch = true;\n }\n else {\n target.classList.remove('e-spanclicked');\n this.enableSelectMultiTouch = false;\n this.parent.element.querySelector('.e-gridpopup').style.display = 'none';\n }\n }\n }\n else {\n this.parent.element.querySelector('.e-gridpopup').style.display = 'none';\n }\n };\n Selection.prototype.showPopup = function (e) {\n if (!this.selectionSettings.enableSimpleMultiRowSelection) {\n setCssInGridPopUp(this.parent.element.querySelector('.e-gridpopup'), e, 'e-rowselect e-icons e-icon-rowselect' +\n (!this.isSingleSel() && (this.selectedRecords.length > 1\n || this.selectedRowCellIndexes.length > 1) ? ' e-spanclicked' : ''));\n }\n };\n Selection.prototype.rowCellSelectionHandler = function (rowIndex, cellIndex) {\n if ((!this.isMultiCtrlRequest && !this.isMultiShiftRequest) || this.isSingleSel()) {\n if (!this.isDragged) {\n this.selectRow(rowIndex, this.selectionSettings.enableToggle);\n }\n this.selectCell({ rowIndex: rowIndex, cellIndex: cellIndex }, this.selectionSettings.enableToggle);\n if (this.selectedRowCellIndexes.length) {\n this.updateAutoFillPosition();\n }\n this.drawBorders();\n }\n else if (this.isMultiShiftRequest) {\n if (this.parent.isCheckBoxSelection || (!this.parent.isCheckBoxSelection &&\n !closest(this.target, '.' + literals.rowCell).classList.contains(literals.gridChkBox))) {\n this.selectRowsByRange(isUndefined(this.prevRowIndex) ? rowIndex : this.prevRowIndex, rowIndex);\n }\n else {\n this.addRowsToSelection([rowIndex]);\n }\n this.selectCellsByRange(isUndefined(this.prevCIdxs) ? { rowIndex: rowIndex, cellIndex: cellIndex } : this.prevCIdxs, { rowIndex: rowIndex, cellIndex: cellIndex });\n this.updateAutoFillPosition();\n this.drawBorders();\n }\n else {\n this.addRowsToSelection([rowIndex]);\n if (this.selectionSettings.mode === 'Both') {\n var checkboxColumn = this.parent.getColumns().find(function (col) { return col.type === 'checkbox'; });\n var checkboxColumnIndexCheck = checkboxColumn && checkboxColumn.index !== cellIndex;\n if (checkboxColumnIndexCheck && !this.isMultiCtrlRequestCell) {\n this.selectCell({ rowIndex: rowIndex, cellIndex: cellIndex }, this.selectionSettings.enableToggle);\n }\n else if (!checkboxColumn || checkboxColumnIndexCheck) {\n this.addCellsToSelection([{ rowIndex: rowIndex, cellIndex: cellIndex }]);\n }\n }\n else {\n this.addCellsToSelection([{ rowIndex: rowIndex, cellIndex: cellIndex }]);\n }\n this.showHideBorders('none');\n }\n this.isDragged = false;\n };\n Selection.prototype.onCellFocused = function (e) {\n if (this.parent.frozenRows && e.container.isHeader && e.byKey) {\n if (e.keyArgs.action === 'upArrow') {\n if (this.parent.allowFiltering) {\n e.isJump = e.element.tagName === 'INPUT' ? true : false;\n }\n else {\n e.isJump = e.element.tagName === 'TH' ? true : false;\n }\n }\n else {\n if (e.keyArgs.action === 'downArrow') {\n var rIdx = Number(e.element.parentElement.getAttribute(literals.dataRowIndex));\n e.isJump = rIdx === 0 ? true : false;\n }\n else {\n if (e.keyArgs.action === 'ctrlHome') {\n e.isJump = true;\n }\n }\n }\n }\n var clear = ((e.container.isHeader && e.isJump) ||\n (e.container.isContent && !e.container.isSelectable)) && !(e.byKey && e.keyArgs.action === 'space')\n && !(e.element.classList.contains('e-detailrowexpand') || e.element.classList.contains('e-detailrowcollapse'));\n var headerAction = (e.container.isHeader && e.element.tagName !== 'TD' && !closest(e.element, '.' + literals.rowCell))\n && !(e.byKey && e.keyArgs.action === 'space');\n if (!e.byKey || clear) {\n if (clear && !this.parent.isCheckBoxSelection) {\n this.clearSelection();\n }\n return;\n }\n var _a = e.container.isContent ? e.container.indexes : e.indexes, rowIndex = _a[0], cellIndex = _a[1];\n var prev = this.focus.getPrevIndexes();\n if (e.element.parentElement.querySelector('.e-rowcelldrag') || e.element.parentElement.querySelector('.e-dtdiagonalright')\n || e.element.parentElement.querySelector('.e-dtdiagonaldown')) {\n prev.cellIndex = prev.cellIndex - 1;\n }\n if (this.parent.frozenRows) {\n if (e.container.isHeader && (e.element.tagName === 'TD' || closest(e.element, '.' + literals.rowCell))) {\n var thLen = this.parent.getHeaderTable().querySelector('thead').childElementCount;\n rowIndex -= thLen;\n prev.rowIndex = !isNullOrUndefined(prev.rowIndex) ? prev.rowIndex - thLen : null;\n }\n else {\n rowIndex += this.parent.frozenRows;\n prev.rowIndex = prev.rowIndex === 0 || !isNullOrUndefined(prev.rowIndex) ? prev.rowIndex + this.parent.frozenRows : null;\n }\n }\n if (this.parent.enableInfiniteScrolling && this.parent.infiniteScrollSettings.enableCache) {\n rowIndex = parseInt(e.element.parentElement.getAttribute('data-rowindex'), 10);\n }\n if ((headerAction || (['ctrlPlusA', 'escape'].indexOf(e.keyArgs.action) === -1 &&\n e.keyArgs.action !== 'space' && rowIndex === prev.rowIndex && cellIndex === prev.cellIndex)) &&\n !this.selectionSettings.allowColumnSelection) {\n return;\n }\n this.preventFocus = true;\n var columnIndex = this.getKeyColIndex(e);\n if (this.needColumnSelection) {\n cellIndex = columnIndex;\n }\n if (this.parent.element.classList.contains('e-gridcell-read') && (e.keyArgs.action === 'tab' || e.keyArgs.action === 'shiftTab'\n || e.keyArgs.action === 'rightArrow' || e.keyArgs.action === 'leftArrow')) {\n var targetLabel = this.target.getAttribute('aria-label');\n targetLabel = this.target.innerHTML + ' column header ' + this.parent.getColumnByIndex(cellIndex).field;\n this.target.setAttribute('aria-label', targetLabel);\n }\n switch (e.keyArgs.action) {\n case 'downArrow':\n case 'upArrow':\n case 'enter':\n case 'shiftEnter':\n this.target = e.element;\n this.isKeyAction = true;\n this.applyDownUpKey(rowIndex, cellIndex);\n break;\n case 'rightArrow':\n case 'leftArrow':\n this.applyRightLeftKey(rowIndex, cellIndex);\n break;\n case 'shiftDown':\n case 'shiftUp':\n this.shiftDownKey(rowIndex, cellIndex);\n break;\n case 'shiftLeft':\n case 'shiftRight':\n this.applyShiftLeftRightKey(rowIndex, cellIndex);\n break;\n case 'home':\n case 'end':\n cellIndex = e.keyArgs.action === 'end' ? this.getLastColIndex(rowIndex) : 0;\n this.applyHomeEndKey(rowIndex, cellIndex);\n break;\n case 'ctrlHome':\n case 'ctrlEnd':\n this.applyCtrlHomeEndKey(rowIndex, cellIndex);\n break;\n case 'escape':\n this.clearSelection();\n if (this.parent.clipboardModule) {\n window.navigator['clipboard'].writeText('');\n }\n break;\n case 'ctrlPlusA':\n this.ctrlPlusA();\n break;\n case 'space':\n this.applySpaceSelection(e.element);\n break;\n case 'tab':\n if (this.parent.editSettings.allowNextRowEdit) {\n this.selectRow(rowIndex);\n }\n break;\n }\n this.needColumnSelection = false;\n this.preventFocus = false;\n this.positionBorders();\n if (this.parent.isFrozenGrid()) {\n this.showHideBorders('none', true);\n this.refreshFrozenBorders();\n }\n this.updateAutoFillPosition();\n };\n Selection.prototype.getKeyColIndex = function (e) {\n var uid;\n var index = null;\n var stackedHeader = e.element.querySelector('.e-stackedheadercelldiv');\n if (this.selectionSettings.allowColumnSelection && parentsUntil(e.element, 'e-columnheader')) {\n this.needColumnSelection = e.container.isHeader ? true : false;\n if (stackedHeader) {\n if (e.keyArgs.action === 'rightArrow' || e.keyArgs.action === 'leftArrow') {\n return index;\n }\n uid = stackedHeader.getAttribute('e-mappinguid');\n var innerColumn = this.getstackedColumns(this.parent.getColumnByUid(uid).columns);\n var lastIndex = this.parent.getColumnIndexByUid(innerColumn[innerColumn.length - 1].uid);\n var firstIndex = this.parent.getColumnIndexByUid(innerColumn[0].uid);\n index = this.prevColIndex >= lastIndex ? firstIndex : lastIndex;\n }\n else {\n index = this.parent.getColumnIndexByUid(e.element\n .querySelector('.e-headercelldiv').getAttribute('e-mappinguid'));\n }\n }\n return index;\n };\n /**\n * Apply ctrl + A key selection\n *\n * @returns {void}\n * @hidden\n */\n Selection.prototype.ctrlPlusA = function () {\n if (this.isRowType() && !this.isSingleSel()) {\n this.selectRowsByRange(0, this.getCurrentBatchRecordChanges().length - 1);\n }\n if (this.isCellType() && !this.isSingleSel()) {\n this.selectCellsByRange({ rowIndex: 0, cellIndex: 0 }, { rowIndex: this.parent.getRows().length - 1, cellIndex: this.parent.getColumns().length - 1 });\n }\n };\n Selection.prototype.applySpaceSelection = function (target) {\n if (target.classList.contains('e-checkselectall')) {\n this.checkedTarget = target;\n this.checkSelectAll(this.checkedTarget);\n }\n else {\n if (target.classList.contains('e-checkselect')) {\n this.checkedTarget = target;\n this.checkSelect(this.checkedTarget);\n }\n }\n };\n Selection.prototype.applyDownUpKey = function (rowIndex, cellIndex) {\n var gObj = this.parent;\n if (this.parent.isCheckBoxSelection && this.parent.checkAllRows === 'Check' && !this.selectionSettings.persistSelection &&\n !this.selectionSettings.checkboxOnly) {\n this.checkSelectAllAction(false);\n this.checkedTarget = null;\n }\n if (this.isRowType() && !this.selectionSettings.checkboxOnly) {\n if (this.parent.frozenRows) {\n this.selectRow(rowIndex, true);\n this.applyUpDown(gObj.selectedRowIndex);\n }\n else {\n this.selectRow(rowIndex, true);\n this.applyUpDown(gObj.selectedRowIndex);\n }\n }\n if (this.isCellType()) {\n this.selectCell({ rowIndex: rowIndex, cellIndex: cellIndex }, true);\n }\n if (this.selectionSettings.allowColumnSelection && this.needColumnSelection) {\n this.selectColumn(cellIndex);\n }\n };\n Selection.prototype.applyUpDown = function (rowIndex) {\n if (rowIndex < 0) {\n return;\n }\n if (!this.target) {\n this.target = this.parent.getRows()[0].children[this.parent.groupSettings.columns.length || 0];\n }\n var cIndex = parseInt(this.target.getAttribute(literals.dataColIndex), 10);\n var row = this.contentRenderer.getRowByIndex(rowIndex);\n if (row) {\n this.target = row.getElementsByClassName(literals.rowCell)[parseInt(cIndex.toString(), 10)];\n }\n this.addAttribute(this.target);\n if (this.parent.element.classList.contains('e-gridcell-read')) {\n var targetLabel = this.target.getAttribute('aria-label');\n targetLabel = this.target.innerHTML;\n this.target.setAttribute('aria-label', targetLabel);\n }\n };\n Selection.prototype.applyRightLeftKey = function (rowIndex, cellIndex) {\n if (this.selectionSettings.allowColumnSelection && this.needColumnSelection) {\n this.selectColumn(cellIndex);\n }\n else if (this.isCellType()) {\n this.selectCell({ rowIndex: rowIndex, cellIndex: cellIndex }, true);\n this.addAttribute(this.target);\n }\n };\n Selection.prototype.applyHomeEndKey = function (rowIndex, cellIndex) {\n if (this.isCellType()) {\n this.selectCell({ rowIndex: rowIndex, cellIndex: cellIndex }, true);\n }\n else {\n this.addAttribute(this.parent.getCellFromIndex(rowIndex, cellIndex));\n }\n };\n /**\n * Apply shift+down key selection\n *\n * @param {number} rowIndex - specfies the rowIndex\n * @param {number} cellIndex - specifies the CellIndex\n * @returns {void}\n * @hidden\n */\n Selection.prototype.shiftDownKey = function (rowIndex, cellIndex) {\n this.isMultiShiftRequest = true;\n if (this.isRowType() && !this.isSingleSel()) {\n if (!isUndefined(this.prevRowIndex)) {\n this.selectRowsByRange(this.prevRowIndex, rowIndex);\n this.applyUpDown(rowIndex);\n }\n else if (this.isPartialSelection) {\n this.selectRow(rowIndex, true);\n }\n else {\n this.selectRow(0, true);\n }\n }\n if (this.isCellType() && !this.isSingleSel()) {\n this.selectCellsByRange(this.prevCIdxs || { rowIndex: 0, cellIndex: 0 }, { rowIndex: rowIndex, cellIndex: cellIndex });\n }\n this.isMultiShiftRequest = false;\n };\n Selection.prototype.applyShiftLeftRightKey = function (rowIndex, cellIndex) {\n this.isMultiShiftRequest = true;\n if (this.selectionSettings.allowColumnSelection && this.needColumnSelection) {\n this.selectColumnsByRange(this.prevColIndex, cellIndex);\n }\n else {\n this.selectCellsByRange(this.prevCIdxs, { rowIndex: rowIndex, cellIndex: cellIndex });\n }\n this.isMultiShiftRequest = false;\n };\n Selection.prototype.getstackedColumns = function (column) {\n var innerColumnIndexes = [];\n for (var i = 0, len = column.length; i < len; i++) {\n if (column[parseInt(i.toString(), 10)].columns) {\n this.getstackedColumns(column[parseInt(i.toString(), 10)].columns);\n }\n else {\n innerColumnIndexes.push(column[parseInt(i.toString(), 10)]);\n }\n }\n return innerColumnIndexes;\n };\n Selection.prototype.applyCtrlHomeEndKey = function (rowIndex, cellIndex) {\n if (this.isRowType()) {\n this.selectRow(rowIndex, true);\n this.addAttribute(this.parent.getCellFromIndex(rowIndex, cellIndex));\n }\n if (this.isCellType()) {\n this.selectCell({ rowIndex: rowIndex, cellIndex: cellIndex }, true);\n }\n };\n Selection.prototype.addRemoveClassesForRow = function (row, isAdd, clearAll) {\n var args = [];\n for (var _i = 3; _i < arguments.length; _i++) {\n args[_i - 3] = arguments[_i];\n }\n if (row) {\n var cells = [].slice.call(row.getElementsByClassName(literals.rowCell));\n var detailIndentCell = row.querySelector('.e-detailrowcollapse') || row.querySelector('.e-detailrowexpand');\n var dragdropIndentCell = row.querySelector('.e-rowdragdrop');\n if (detailIndentCell) {\n cells.push(detailIndentCell);\n }\n if (dragdropIndentCell) {\n cells.push(dragdropIndentCell);\n }\n addRemoveActiveClasses.apply(void 0, [cells, isAdd].concat(args));\n }\n this.getRenderer().setSelection(row ? row.getAttribute('data-uid') : null, isAdd, clearAll);\n };\n Selection.prototype.isRowType = function () {\n return this.selectionSettings.mode === 'Row' || this.selectionSettings.mode === 'Both';\n };\n Selection.prototype.isCellType = function () {\n return this.selectionSettings.mode === 'Cell' || this.selectionSettings.mode === 'Both';\n };\n Selection.prototype.isSingleSel = function () {\n return this.selectionSettings.type === 'Single';\n };\n Selection.prototype.getRenderer = function () {\n if (isNullOrUndefined(this.contentRenderer)) {\n this.contentRenderer = this.factory.getRenderer(RenderType.Content);\n }\n return this.contentRenderer;\n };\n /**\n * Gets the collection of selected records.\n *\n * @returns {Object[]} returns the Object\n */\n Selection.prototype.getSelectedRecords = function () {\n var selectedData = [];\n if (!this.selectionSettings.persistSelection && this.selectedRecords.length) {\n selectedData = this.parent.getRowsObject().filter(function (row) { return row.isSelected; })\n .map(function (m) { return m.data; });\n }\n else {\n selectedData = this.persistSelectedData;\n }\n return selectedData;\n };\n /**\n * Select the column by passing start column index\n *\n * @param {number} index - specifies the index\n * @returns {void}\n */\n Selection.prototype.selectColumn = function (index) {\n var gObj = this.parent;\n if (isNullOrUndefined(gObj.getColumns()[parseInt(index.toString(), 10)])) {\n return;\n }\n var column = gObj.getColumnByIndex(index);\n var selectedCol = gObj.getColumnHeaderByUid(column.uid);\n var isColSelected = selectedCol.classList.contains('e-columnselection');\n if ((!gObj.selectionSettings.allowColumnSelection)) {\n return;\n }\n var isMultiColumns = this.selectedColumnsIndexes.length > 1 &&\n this.selectedColumnsIndexes.indexOf(index) > -1;\n this.clearColDependency();\n if (!isColSelected || !this.selectionSettings.enableToggle || isMultiColumns) {\n var args = {\n columnIndex: index, headerCell: selectedCol,\n column: column,\n cancel: false, target: this.actualTarget,\n isInteracted: this.isInteracted, previousColumnIndex: this.prevColIndex,\n isCtrlPressed: this.isMultiCtrlRequest, isShiftPressed: this.isMultiShiftRequest\n };\n this.onActionBegin(args, events.columnSelecting);\n if (args.cancel) {\n this.disableInteracted();\n return;\n }\n if (!(gObj.selectionSettings.enableToggle && index === this.prevColIndex && isColSelected) || isMultiColumns) {\n this.updateColSelection(selectedCol, index);\n }\n var selectedArgs = {\n columnIndex: index, headerCell: selectedCol,\n column: column,\n target: this.actualTarget,\n isInteracted: this.isInteracted, previousColumnIndex: this.prevColIndex\n };\n this.onActionComplete(selectedArgs, events.columnSelected);\n }\n this.updateColProps(index);\n };\n /**\n * Select the columns by passing start and end column index\n *\n * @param {number} startIndex - specifies the start index\n * @param {number} endIndex - specifies the end index\n * @returns {void}\n */\n Selection.prototype.selectColumnsByRange = function (startIndex, endIndex) {\n var gObj = this.parent;\n if (isNullOrUndefined(gObj.getColumns()[parseInt(startIndex.toString(), 10)])) {\n return;\n }\n var indexes = [];\n if (gObj.selectionSettings.type === 'Single' || isNullOrUndefined(endIndex)) {\n indexes[0] = startIndex;\n }\n else {\n var min = startIndex < endIndex;\n for (var i = startIndex; min ? i <= endIndex : i >= endIndex; min ? i++ : i--) {\n indexes.push(i);\n }\n }\n this.selectColumns(indexes);\n };\n /**\n * Select the columns by passing column indexes\n *\n * @param {number[]} columnIndexes - specifies the columnIndexes\n * @returns {void}\n */\n Selection.prototype.selectColumns = function (columnIndexes) {\n var gObj = this.parent;\n var selectedCol = this.getselectedCols();\n if (gObj.selectionSettings.type === 'Single') {\n columnIndexes = [columnIndexes[0]];\n }\n if (!gObj.selectionSettings.allowColumnSelection) {\n return;\n }\n this.clearColDependency();\n var selectingArgs = {\n columnIndex: columnIndexes[0], headerCell: selectedCol,\n columnIndexes: columnIndexes,\n column: gObj.getColumnByIndex(columnIndexes[0]),\n cancel: false, target: this.actualTarget,\n isInteracted: this.isInteracted, previousColumnIndex: this.prevColIndex,\n isCtrlPressed: this.isMultiCtrlRequest, isShiftPressed: this.isMultiShiftRequest\n };\n this.onActionBegin(selectingArgs, events.columnSelecting);\n if (selectingArgs.cancel) {\n this.disableInteracted();\n return;\n }\n for (var i = 0, len = columnIndexes.length; i < len; i++) {\n this.updateColSelection(gObj.getColumnHeaderByUid(gObj.getColumnByIndex(columnIndexes[parseInt(i.toString(), 10)]).uid), columnIndexes[parseInt(i.toString(), 10)]);\n }\n selectedCol = this.getselectedCols();\n var selectedArgs = {\n columnIndex: columnIndexes[0], headerCell: selectedCol,\n columnIndexes: columnIndexes,\n column: gObj.getColumnByIndex(columnIndexes[0]),\n target: this.actualTarget,\n isInteracted: this.isInteracted, previousColumnIndex: this.prevColIndex\n };\n this.onActionComplete(selectedArgs, events.columnSelected);\n this.updateColProps(columnIndexes[0]);\n };\n /**\n * Select the column with existing column by passing column index\n *\n * @param {number} startIndex - specifies the start index\n * @returns {void}\n */\n Selection.prototype.selectColumnWithExisting = function (startIndex) {\n var gObj = this.parent;\n if (isNullOrUndefined(gObj.getColumns()[parseInt(startIndex.toString(), 10)])) {\n return;\n }\n var newCol = gObj.getColumnHeaderByUid(gObj.getColumnByIndex(startIndex).uid);\n var selectedCol = this.getselectedCols();\n if (gObj.selectionSettings.type === 'Single') {\n this.clearColDependency();\n }\n if (!gObj.selectionSettings.allowColumnSelection) {\n return;\n }\n if (this.selectedColumnsIndexes.indexOf(startIndex) > -1) {\n this.clearColumnSelection(startIndex);\n }\n else {\n var selectingArgs = {\n columnIndex: startIndex, headerCell: selectedCol,\n columnIndexes: this.selectedColumnsIndexes,\n column: gObj.getColumnByIndex(startIndex),\n cancel: false, target: this.actualTarget,\n isInteracted: this.isInteracted, previousColumnIndex: this.prevColIndex,\n isCtrlPressed: this.isMultiCtrlRequest, isShiftPressed: this.isMultiShiftRequest\n };\n this.onActionBegin(selectingArgs, events.columnSelecting);\n if (selectingArgs.cancel) {\n this.disableInteracted();\n return;\n }\n this.updateColSelection(newCol, startIndex);\n selectedCol = this.getselectedCols();\n var selectedArgs = {\n columnIndex: startIndex, headerCell: selectedCol,\n column: gObj.getColumnByIndex(startIndex),\n columnIndexes: this.selectedColumnsIndexes,\n target: this.actualTarget,\n isInteracted: this.isInteracted, previousColumnIndex: this.prevColIndex\n };\n this.onActionComplete(selectedArgs, events.columnSelected);\n }\n this.updateColProps(startIndex);\n };\n /**\n * Clear the column selection\n *\n * @param {number} clearIndex - specifies the clearIndex\n * @returns {void}\n */\n Selection.prototype.clearColumnSelection = function (clearIndex) {\n if (this.isColumnSelected) {\n var gObj = this.parent;\n if (!isNullOrUndefined(clearIndex) && this.selectedColumnsIndexes.indexOf(clearIndex) === -1) {\n return;\n }\n var index = !isNullOrUndefined(clearIndex) ? clearIndex :\n this.selectedColumnsIndexes[this.selectedColumnsIndexes.length - 1];\n var column = gObj.getColumnByIndex(index);\n var selectedCol = gObj.getColumnHeaderByUid(column.uid);\n var deselectedArgs = {\n columnIndex: index, headerCell: selectedCol,\n columnIndexes: this.selectedColumnsIndexes,\n column: column,\n cancel: false, target: this.actualTarget,\n isInteracted: this.isInteracted\n };\n var isCanceled = this.columnDeselect(deselectedArgs, events.columnDeselecting);\n if (isCanceled) {\n this.disableInteracted();\n return;\n }\n var selectedHeader = !isNullOrUndefined(clearIndex) ? [selectedCol] :\n [].slice.call(gObj.getHeaderContent().getElementsByClassName('e-columnselection'));\n var selectedCells = this.getSelectedColumnCells(clearIndex);\n for (var i = 0, len = selectedHeader.length; i < len; i++) {\n addRemoveActiveClasses([selectedHeader[parseInt(i.toString(), 10)]], false, 'e-columnselection');\n }\n for (var i = 0, len = selectedCells.length; i < len; i++) {\n addRemoveActiveClasses([selectedCells[parseInt(i.toString(), 10)]], false, 'e-columnselection');\n }\n if (!isNullOrUndefined(clearIndex)) {\n this.selectedColumnsIndexes.splice(this.selectedColumnsIndexes.indexOf(clearIndex), 1);\n this.parent.getColumns()[parseInt(clearIndex.toString(), 10)].isSelected = false;\n }\n else {\n this.columnDeselect(deselectedArgs, events.columnDeselected);\n this.selectedColumnsIndexes = [];\n this.isColumnSelected = false;\n this.parent.getColumns().filter(function (col) { return col.isSelected = false; });\n }\n }\n };\n Selection.prototype.getselectedCols = function () {\n var gObj = this.parent;\n var selectedCol;\n if (this.selectedColumnsIndexes.length > 1) {\n selectedCol = [];\n for (var i = 0; i < this.selectedColumnsIndexes.length; i++) {\n (selectedCol).push(gObj.getColumnHeaderByUid(gObj.getColumnByIndex(this.selectedColumnsIndexes[parseInt(i.toString(), 10)]).uid));\n }\n }\n else {\n selectedCol = gObj.getColumnHeaderByUid(gObj.getColumnByIndex(this.selectedColumnsIndexes[0]).uid);\n }\n return selectedCol;\n };\n Selection.prototype.getSelectedColumnCells = function (clearIndex) {\n var gObj = this.parent;\n var isRowTemplate = !isNullOrUndefined(this.parent.rowTemplate);\n var rows = isRowTemplate ? gObj.getRows() : gObj.getDataRows();\n var seletedcells = [];\n var selectionString = !isNullOrUndefined(clearIndex) ? '[data-colindex=\"' + clearIndex + '\"]' : '.e-columnselection';\n for (var i = 0, len = rows.length; i < len; i++) {\n seletedcells = seletedcells.concat([].slice.call(rows[parseInt(i.toString(), 10)].querySelectorAll(selectionString)));\n }\n return seletedcells;\n };\n Selection.prototype.columnDeselect = function (args, event) {\n if (event === 'columnDeselected') {\n delete args.cancel;\n }\n this.onActionComplete(args, event);\n return args.cancel;\n };\n Selection.prototype.updateColProps = function (startIndex) {\n this.prevColIndex = startIndex;\n this.isColumnSelected = this.selectedColumnsIndexes.length && true;\n };\n Selection.prototype.clearColDependency = function () {\n this.clearColumnSelection();\n this.selectedColumnsIndexes = [];\n };\n Selection.prototype.updateColSelection = function (selectedCol, startIndex) {\n if (isNullOrUndefined(this.parent.getColumns()[parseInt(startIndex.toString(), 10)])) {\n return;\n }\n var isRowTemplate = !isNullOrUndefined(this.parent.rowTemplate);\n var rows = isRowTemplate ? this.parent.getRows() : this.parent.getDataRows();\n this.selectedColumnsIndexes.push(startIndex);\n this.parent.getColumns()[parseInt(startIndex.toString(), 10)].isSelected = true;\n startIndex = startIndex + this.parent.getIndentCount();\n addRemoveActiveClasses([selectedCol], true, 'e-columnselection');\n for (var j = 0, len = rows.length; j < len; j++) {\n if (rows[parseInt(j.toString(), 10)].classList.contains(literals.row)) {\n if ((rows[parseInt(j.toString(), 10)].classList.contains(literals.editedRow)\n || rows[parseInt(j.toString(), 10)].classList.contains(literals.addedRow))\n && this.parent.editSettings.mode === 'Normal'\n && !isNullOrUndefined(rows[parseInt(j.toString(), 10)].querySelector('tr').childNodes[parseInt(startIndex.toString(), 10)])) {\n addRemoveActiveClasses([rows[parseInt(j.toString(), 10)].querySelector('tr').childNodes[parseInt(startIndex.toString(), 10)]], true, 'e-columnselection');\n }\n else if (!isNullOrUndefined(rows[parseInt(j.toString(), 10)].childNodes[parseInt(startIndex.toString(), 10)])) {\n addRemoveActiveClasses([rows[parseInt(j.toString(), 10)].childNodes[parseInt(startIndex.toString(), 10)]], true, 'e-columnselection');\n }\n }\n }\n };\n Selection.prototype.headerSelectionHandler = function (colIndex) {\n if ((!this.isMultiCtrlRequest && !this.isMultiShiftRequest) || this.isSingleSel()) {\n this.selectColumn(colIndex);\n }\n else if (this.isMultiShiftRequest) {\n this.selectColumnsByRange(isUndefined(this.prevColIndex) ? colIndex : this.prevColIndex, colIndex);\n }\n else {\n this.selectColumnWithExisting(colIndex);\n }\n };\n // eslint-disable-next-line camelcase\n Selection.prototype.addEventListener_checkbox = function () {\n var _this = this;\n this.parent.on(events.dataReady, this.dataReady, this);\n this.onDataBoundFunction = this.onDataBound.bind(this);\n this.parent.addEventListener(events.dataBound, this.onDataBoundFunction);\n this.parent.on(events.refreshInfinitePersistSelection, this.onDataBoundFunction);\n this.parent.on(events.contentReady, this.checkBoxSelectionChanged, this);\n this.parent.on(events.beforeRefreshOnDataChange, this.initPerisistSelection, this);\n this.parent.on(events.onEmpty, this.setCheckAllForEmptyGrid, this);\n this.actionCompleteFunc = this.actionCompleteHandler.bind(this);\n this.parent.addEventListener(events.actionComplete, this.actionCompleteFunc);\n this.parent.on(events.click, this.clickHandler, this);\n this.resizeEndFn = function () {\n _this.updateAutoFillPosition();\n _this.drawBorders();\n };\n this.resizeEndFn.bind(this);\n this.parent.addEventListener(events.resizeStop, this.resizeEndFn);\n };\n // eslint-disable-next-line camelcase\n Selection.prototype.removeEventListener_checkbox = function () {\n this.parent.off(events.dataReady, this.dataReady);\n this.parent.removeEventListener(events.dataBound, this.onDataBoundFunction);\n this.parent.removeEventListener(events.actionComplete, this.actionCompleteFunc);\n this.parent.off(events.refreshInfinitePersistSelection, this.onDataBoundFunction);\n this.parent.off(events.onEmpty, this.setCheckAllForEmptyGrid);\n this.parent.off(events.click, this.clickHandler);\n this.parent.off(events.beforeRefreshOnDataChange, this.initPerisistSelection);\n };\n Selection.prototype.setCheckAllForEmptyGrid = function () {\n var checkAllBox = this.getCheckAllBox();\n if (checkAllBox) {\n this.parent.isCheckBoxSelection = true;\n var spanEle = checkAllBox.nextElementSibling;\n removeClass([spanEle], ['e-check', 'e-stop', 'e-uncheck']);\n addClass([spanEle.parentElement], ['e-checkbox-disabled']);\n }\n };\n Selection.prototype.dataReady = function (e) {\n this.isHeaderCheckboxClicked = false;\n var isInfinitecroll = this.parent.enableInfiniteScrolling && e.requestType === 'infiniteScroll';\n if (e.requestType !== 'virtualscroll' && !this.parent.isPersistSelection && !isInfinitecroll) {\n this.disableUI = !this.parent.enableImmutableMode && !(e.requestType === 'save' && e['action'] === 'add');\n this.clearSelection();\n this.setCheckAllState();\n this.disableUI = false;\n }\n };\n Selection.prototype.actionCompleteHandler = function (e) {\n if (e.requestType === 'save' && this.parent.isPersistSelection) {\n this.refreshPersistSelection();\n }\n };\n Selection.prototype.selectRowIndex = function (index) {\n this.parent.isSelectedRowIndexUpdating = true;\n if ((isNullOrUndefined(this.parent.selectedRowIndex) || this.parent.selectedRowIndex === -1) || !this.parent.enablePersistence) {\n this.parent.selectedRowIndex = index;\n }\n else {\n this.parent.selectedRowIndex = -1;\n }\n };\n Selection.prototype.disableInteracted = function () {\n this.isInteracted = false;\n };\n Selection.prototype.activeTarget = function () {\n this.actualTarget = this.isInteracted ? this.actualTarget : null;\n };\n return Selection;\n}());\nexport { Selection };\n","//! moment.js locale configuration\n//! locale : Lao [lo]\n//! author : Ryan Hart : https://github.com/ryanhart2\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var lo = moment.defineLocale('lo', {\n months: 'ມັງàºàºàº™_àºàº¸àº¡àºžàº²_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_àºà»àº¥àº°àºàº»àº”_ສິງຫາ_àºàº±àº™àºàº²_ຕຸລາ_ພະຈິàº_ທັນວາ'.split(\n '_'\n ),\n monthsShort:\n 'ມັງàºàºàº™_àºàº¸àº¡àºžàº²_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_àºà»àº¥àº°àºàº»àº”_ສິງຫາ_àºàº±àº™àºàº²_ຕຸລາ_ພະຈິàº_ທັນວາ'.split(\n '_'\n ),\n weekdays: 'àºàº²àº—ິດ_ຈັນ_àºàº±àº‡àº„ານ_ພຸດ_ພະຫັດ_ສຸàº_ເສົາ'.split('_'),\n weekdaysShort: 'ທິດ_ຈັນ_àºàº±àº‡àº„ານ_ພຸດ_ພະຫັດ_ສຸàº_ເສົາ'.split('_'),\n weekdaysMin: 'ທ_ຈ_àºàº„_ພ_ພຫ_ສàº_ສ'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'ວັນdddd D MMMM YYYY HH:mm',\n },\n meridiemParse: /ຕàºàº™à»€àºŠàº»à»‰àº²|ຕàºàº™à»àº¥àº‡/,\n isPM: function (input) {\n return input === 'ຕàºàº™à»àº¥àº‡';\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'ຕàºàº™à»€àºŠàº»à»‰àº²';\n } else {\n return 'ຕàºàº™à»àº¥àº‡';\n }\n },\n calendar: {\n sameDay: '[ມື້ນີ້ເວລາ] LT',\n nextDay: '[ມື້àºàº·à»ˆàº™à»€àº§àº¥àº²] LT',\n nextWeek: '[ວັນ]dddd[ໜ້າເວລາ] LT',\n lastDay: '[ມື້ວານນີ້ເວລາ] LT',\n lastWeek: '[ວັນ]dddd[à»àº¥à»‰àº§àº™àºµà»‰à»€àº§àº¥àº²] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'àºàºµàº %s',\n past: '%sຜ່ານມາ',\n s: 'ບà»à»ˆà»€àº—ົ່າໃດວິນາທີ',\n ss: '%d ວິນາທີ',\n m: '1 ນາທີ',\n mm: '%d ນາທີ',\n h: '1 ຊົ່ວໂມງ',\n hh: '%d ຊົ່ວໂມງ',\n d: '1 ມື້',\n dd: '%d ມື້',\n M: '1 ເດືàºàº™',\n MM: '%d ເດືàºàº™',\n y: '1 ປີ',\n yy: '%d ປີ',\n },\n dayOfMonthOrdinalParse: /(ທີ່)\\d{1,2}/,\n ordinal: function (number) {\n return 'ທີ່' + number;\n },\n });\n\n return lo;\n\n})));\n","import { isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { formatUnit } from '@syncfusion/ej2-base';\nimport { columnWidthChanged, preventFrozenScrollRefresh } from '../base/constant';\nimport { Column } from '../models/column';\nimport { parentsUntil, ispercentageWidth, getScrollBarWidth } from '../base/util';\nimport * as literals from '../base/string-literals';\n/**\n * ColumnWidthService\n *\n * @hidden\n */\nvar ColumnWidthService = /** @class */ (function () {\n function ColumnWidthService(parent) {\n this.parent = parent;\n }\n ColumnWidthService.prototype.setWidthToColumns = function () {\n var i = 0;\n var indexes = this.parent.getColumnIndexesInView();\n var wFlag = true;\n var totalColumnsWidth = 0;\n if (this.parent.allowGrouping) {\n for (var len = this.parent.groupSettings.columns.length; i < len; i++) {\n if (this.parent.enableColumnVirtualization && indexes.indexOf(i) === -1) {\n wFlag = false;\n continue;\n }\n this.setColumnWidth(new Column({ width: '30px' }), i);\n }\n }\n if (this.parent.detailTemplate || this.parent.childGrid) {\n this.setColumnWidth(new Column({ width: '30px' }), i);\n i++;\n }\n if (this.parent.isRowDragable() && this.parent.getFrozenMode() !== 'Right') {\n this.setColumnWidth(new Column({ width: '30px' }), i);\n i++;\n }\n var columns = this.parent.getColumns();\n for (var j = 0; j < columns.length; j++) {\n this.setColumnWidth(columns[parseInt(j.toString(), 10)], wFlag && this.parent.enableColumnVirtualization ? undefined : j + i);\n }\n if (this.parent.isRowDragable() && this.parent.getFrozenMode() === 'Right') {\n this.setColumnWidth(new Column({ width: '30px' }), this.parent.groupSettings.columns.length + columns.length);\n }\n totalColumnsWidth = this.getTableWidth(this.parent.getColumns());\n if (this.parent.width !== 'auto' && this.parent.width.toString().indexOf('%') === -1) {\n this.setMinwidthBycalculation(totalColumnsWidth);\n }\n };\n ColumnWidthService.prototype.setMinwidthBycalculation = function (tWidth) {\n var difference = 0;\n var collection = this.parent.getColumns().filter(function (a) {\n return isNullOrUndefined(a.width) || a.width === 'auto';\n });\n if (collection.length) {\n if (!isNullOrUndefined(this.parent.width) && this.parent.width !== 'auto' &&\n typeof (this.parent.width) === 'string' && this.parent.width.indexOf('%') === -1) {\n difference = (typeof this.parent.width === 'string' ? parseInt(this.parent.width, 10) : this.parent.width) - tWidth;\n }\n else {\n difference = this.parent.element.getBoundingClientRect().width - tWidth;\n }\n var tmWidth = 0;\n for (var _i = 0, collection_1 = collection; _i < collection_1.length; _i++) {\n var cols = collection_1[_i];\n tmWidth += !isNullOrUndefined(cols.minWidth) ?\n ((typeof cols.minWidth === 'string' ? parseInt(cols.minWidth, 10) : cols.minWidth)) : 0;\n }\n for (var i = 0; i < collection.length; i++) {\n if (tWidth === 0 && this.parent.allowResizing && this.isWidthUndefined() && (i !== collection.length - 1)) {\n this.setUndefinedColumnWidth(collection);\n }\n var index = this.parent.getColumnIndexByField(collection[parseInt(i.toString(), 10)].field) + this.parent.getIndentCount();\n if (tWidth !== 0 && difference < tmWidth) {\n this.setWidth(collection[parseInt(i.toString(), 10)].minWidth, index);\n }\n else if (tWidth !== 0 && difference > tmWidth) {\n this.setWidth('', index, true);\n }\n }\n }\n };\n ColumnWidthService.prototype.setUndefinedColumnWidth = function (collection) {\n for (var k = 0; k < collection.length; k++) {\n if (k !== collection.length - 1) {\n collection[parseInt(k.toString(), 10)].width = 200;\n this.setWidth(200, this.parent.getColumnIndexByField(collection[parseInt(k.toString(), 10)].field));\n }\n }\n };\n ColumnWidthService.prototype.setColumnWidth = function (column, index, module) {\n if (this.parent.getColumns().length < 1) {\n return;\n }\n var columnIndex = isNullOrUndefined(index) ? this.parent.getNormalizedColumnIndex(column.uid) : index;\n var cWidth = this.getWidth(column);\n var tgridWidth = this.getTableWidth(this.parent.getColumns());\n if (cWidth !== null) {\n this.setWidth(cWidth, columnIndex);\n if (this.parent.width !== 'auto' && this.parent.width.toString().indexOf('%') === -1) {\n this.setMinwidthBycalculation(tgridWidth);\n }\n if ((this.parent.allowResizing && module === 'resize')) {\n this.setWidthToTable();\n }\n this.parent.notify(columnWidthChanged, { index: columnIndex, width: cWidth, column: column, module: module });\n }\n };\n ColumnWidthService.prototype.setWidth = function (width, index, clear) {\n if (this.parent.groupSettings.columns.length > index && ispercentageWidth(this.parent)) {\n var elementWidth = this.parent.element.offsetWidth;\n width = (30 / elementWidth * 100).toFixed(1) + '%';\n }\n var header = this.parent.getHeaderTable();\n var content = this.parent.getContentTable();\n var fWidth = formatUnit(width);\n var headerCol = header.querySelector(literals.colGroup).children[parseInt(index.toString(), 10)];\n if (headerCol && !clear) {\n headerCol.style.width = fWidth;\n }\n else if (headerCol && clear) {\n headerCol.style.width = '';\n }\n var contentCol = content.querySelector(literals.colGroup).children[parseInt(index.toString(), 10)];\n if (contentCol && !clear) {\n contentCol.style.width = fWidth;\n }\n else if (contentCol && clear) {\n contentCol.style.width = '';\n }\n if (!this.parent.enableColumnVirtualization && this.parent.isEdit) {\n var edit = this.parent.element.querySelectorAll('.e-table.e-inline-edit');\n var editTableCol = [];\n for (var i = 0; i < edit.length; i++) {\n if (parentsUntil(edit[parseInt(i.toString(), 10)], 'e-grid').id === this.parent.element.id) {\n for (var j = 0; j < edit[parseInt(i.toString(), 10)].querySelector('colgroup').children.length; j++) {\n editTableCol.push(edit[parseInt(i.toString(), 10)].querySelector('colgroup').children[parseInt(j.toString(), 10)]);\n }\n }\n }\n if (edit.length && editTableCol.length) {\n editTableCol[parseInt(index.toString(), 10)].style.width = fWidth;\n }\n }\n if (this.parent.isFrozenGrid() && this.parent.enableColumnVirtualization) {\n this.refreshFrozenScrollbar();\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n ColumnWidthService.prototype.refreshFrozenScrollbar = function () {\n var args = { cancel: false };\n this.parent.notify(preventFrozenScrollRefresh, args);\n if (args.cancel) {\n return;\n }\n var scrollWidth = getScrollBarWidth();\n var movableScrollbar = this.parent.element.querySelector('.e-movablescrollbar');\n var movableWidth = this.parent.getContent().firstElementChild.getBoundingClientRect().width;\n if (this.parent.enableColumnVirtualization) {\n var placeHolder = this.parent.getContent().querySelector('.e-virtualtrack');\n if (placeHolder) {\n movableWidth = placeHolder.scrollWidth;\n }\n }\n if (this.parent.height !== 'auto') {\n movableWidth = movableWidth + scrollWidth;\n }\n movableScrollbar.firstElementChild.style.width = movableWidth + 'px';\n };\n ColumnWidthService.prototype.getSiblingsHeight = function (element) {\n var previous = this.getHeightFromDirection(element, 'previous');\n var next = this.getHeightFromDirection(element, 'next');\n return previous + next;\n };\n ColumnWidthService.prototype.getHeightFromDirection = function (element, direction) {\n var sibling = element[direction + 'ElementSibling'];\n var result = 0;\n var classList = [literals.gridHeader, literals.gridFooter, 'e-groupdroparea', 'e-gridpager', 'e-toolbar', 'e-temp-toolbar'];\n while (sibling) {\n if (classList.some(function (value) { return sibling.classList.contains(value); })) {\n result += sibling.offsetHeight;\n }\n sibling = sibling[direction + 'ElementSibling'];\n }\n return result;\n };\n ColumnWidthService.prototype.isWidthUndefined = function () {\n var isWidUndefCount = this.parent.getColumns().filter(function (col) {\n return isNullOrUndefined(col.width) && isNullOrUndefined(col.minWidth);\n }).length;\n return (this.parent.getColumns().length === isWidUndefCount);\n };\n ColumnWidthService.prototype.getWidth = function (column) {\n if (isNullOrUndefined(column.width) && this.parent.allowResizing\n && isNullOrUndefined(column.minWidth) && !this.isWidthUndefined()) {\n column.width = 200;\n }\n if (!column.width) {\n return null;\n }\n var width = parseInt(column.width.toString(), 10);\n if (column.minWidth && width < parseInt(column.minWidth.toString(), 10)) {\n return column.minWidth;\n }\n else if ((column.maxWidth && width > parseInt(column.maxWidth.toString(), 10))) {\n return column.maxWidth;\n }\n else {\n return column.width;\n }\n };\n ColumnWidthService.prototype.getTableWidth = function (columns) {\n var tWidth = 0;\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var column = columns_1[_i];\n var cWidth = this.getWidth(column);\n if (column.width === 'auto') {\n cWidth = 0;\n }\n if (column.visible !== false && cWidth !== null) {\n tWidth += parseInt(cWidth.toString(), 10);\n }\n }\n return tWidth;\n };\n ColumnWidthService.prototype.setWidthToTable = function () {\n var tWidth = formatUnit(this.getTableWidth(this.parent.getColumns()));\n if (this.parent.detailTemplate || this.parent.childGrid) {\n this.setColumnWidth(new Column({ width: '30px' }));\n }\n tWidth = this.isAutoResize() ? '100%' : tWidth;\n this.parent.getHeaderTable().style.width = tWidth;\n this.parent.getContentTable().style.width = tWidth;\n var edit = this.parent.element.querySelector('.e-table.e-inline-edit');\n if (edit) {\n edit.style.width = tWidth;\n }\n };\n ColumnWidthService.prototype.isAutoResize = function () {\n return this.parent.allowResizing && this.parent.resizeSettings.mode === 'Auto';\n };\n return ColumnWidthService;\n}());\nexport { ColumnWidthService };\n","//! moment.js locale configuration\n//! locale : German (Austria) [de-at]\n//! author : lluchs : https://github.com/lluchs\n//! author: Menelion Elensúle: https://github.com/Oire\n//! author : Martin Groller : https://github.com/MadMG\n//! author : Mikolaj Dadela : https://github.com/mik01aj\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n m: ['eine Minute', 'einer Minute'],\n h: ['eine Stunde', 'einer Stunde'],\n d: ['ein Tag', 'einem Tag'],\n dd: [number + ' Tage', number + ' Tagen'],\n w: ['eine Woche', 'einer Woche'],\n M: ['ein Monat', 'einem Monat'],\n MM: [number + ' Monate', number + ' Monaten'],\n y: ['ein Jahr', 'einem Jahr'],\n yy: [number + ' Jahre', number + ' Jahren'],\n };\n return withoutSuffix ? format[key][0] : format[key][1];\n }\n\n var deAt = moment.defineLocale('de-at', {\n months: 'Jänner_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember'.split(\n '_'\n ),\n monthsShort:\n 'Jän._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.'.split('_'),\n monthsParseExact: true,\n weekdays:\n 'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split(\n '_'\n ),\n weekdaysShort: 'So._Mo._Di._Mi._Do._Fr._Sa.'.split('_'),\n weekdaysMin: 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY HH:mm',\n LLLL: 'dddd, D. MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[heute um] LT [Uhr]',\n sameElse: 'L',\n nextDay: '[morgen um] LT [Uhr]',\n nextWeek: 'dddd [um] LT [Uhr]',\n lastDay: '[gestern um] LT [Uhr]',\n lastWeek: '[letzten] dddd [um] LT [Uhr]',\n },\n relativeTime: {\n future: 'in %s',\n past: 'vor %s',\n s: 'ein paar Sekunden',\n ss: '%d Sekunden',\n m: processRelativeTime,\n mm: '%d Minuten',\n h: processRelativeTime,\n hh: '%d Stunden',\n d: processRelativeTime,\n dd: processRelativeTime,\n w: processRelativeTime,\n ww: '%d Wochen',\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return deAt;\n\n})));\n","//! moment.js locale configuration\n//! locale : German [de]\n//! author : lluchs : https://github.com/lluchs\n//! author: Menelion Elensúle: https://github.com/Oire\n//! author : Mikolaj Dadela : https://github.com/mik01aj\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n m: ['eine Minute', 'einer Minute'],\n h: ['eine Stunde', 'einer Stunde'],\n d: ['ein Tag', 'einem Tag'],\n dd: [number + ' Tage', number + ' Tagen'],\n w: ['eine Woche', 'einer Woche'],\n M: ['ein Monat', 'einem Monat'],\n MM: [number + ' Monate', number + ' Monaten'],\n y: ['ein Jahr', 'einem Jahr'],\n yy: [number + ' Jahre', number + ' Jahren'],\n };\n return withoutSuffix ? format[key][0] : format[key][1];\n }\n\n var de = moment.defineLocale('de', {\n months: 'Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember'.split(\n '_'\n ),\n monthsShort:\n 'Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.'.split('_'),\n monthsParseExact: true,\n weekdays:\n 'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split(\n '_'\n ),\n weekdaysShort: 'So._Mo._Di._Mi._Do._Fr._Sa.'.split('_'),\n weekdaysMin: 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY HH:mm',\n LLLL: 'dddd, D. MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[heute um] LT [Uhr]',\n sameElse: 'L',\n nextDay: '[morgen um] LT [Uhr]',\n nextWeek: 'dddd [um] LT [Uhr]',\n lastDay: '[gestern um] LT [Uhr]',\n lastWeek: '[letzten] dddd [um] LT [Uhr]',\n },\n relativeTime: {\n future: 'in %s',\n past: 'vor %s',\n s: 'ein paar Sekunden',\n ss: '%d Sekunden',\n m: processRelativeTime,\n mm: '%d Minuten',\n h: processRelativeTime,\n hh: '%d Stunden',\n d: processRelativeTime,\n dd: processRelativeTime,\n w: processRelativeTime,\n ww: '%d Wochen',\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return de;\n\n})));\n","//! moment.js locale configuration\n//! locale : Central Atlas Tamazight Latin [tzm-latn]\n//! author : Abdel Said : https://github.com/abdelsaid\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var tzmLatn = moment.defineLocale('tzm-latn', {\n months: 'innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_É£wÅ¡t_Å¡wtanbir_ktˤwbrˤ_nwwanbir_dwjnbir'.split(\n '_'\n ),\n monthsShort:\n 'innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_É£wÅ¡t_Å¡wtanbir_ktˤwbrˤ_nwwanbir_dwjnbir'.split(\n '_'\n ),\n weekdays: 'asamas_aynas_asinas_akras_akwas_asimwas_asiá¸yas'.split('_'),\n weekdaysShort: 'asamas_aynas_asinas_akras_akwas_asimwas_asiá¸yas'.split('_'),\n weekdaysMin: 'asamas_aynas_asinas_akras_akwas_asimwas_asiá¸yas'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[asdkh g] LT',\n nextDay: '[aska g] LT',\n nextWeek: 'dddd [g] LT',\n lastDay: '[assant g] LT',\n lastWeek: 'dddd [g] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'dadkh s yan %s',\n past: 'yan %s',\n s: 'imik',\n ss: '%d imik',\n m: 'minuá¸',\n mm: '%d minuá¸',\n h: 'saÉ›a',\n hh: '%d tassaÉ›in',\n d: 'ass',\n dd: '%d ossan',\n M: 'ayowr',\n MM: '%d iyyirn',\n y: 'asgas',\n yy: '%d isgasn',\n },\n week: {\n dow: 6, // Saturday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return tzmLatn;\n\n})));\n","//! moment.js locale configuration\n//! locale : Javanese [jv]\n//! author : Rony Lantip : https://github.com/lantip\n//! reference: http://jv.wikipedia.org/wiki/Basa_Jawa\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var jv = moment.defineLocale('jv', {\n months: 'Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_Nopember_Desember'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nop_Des'.split('_'),\n weekdays: 'Minggu_Senen_Seloso_Rebu_Kemis_Jemuwah_Septu'.split('_'),\n weekdaysShort: 'Min_Sen_Sel_Reb_Kem_Jem_Sep'.split('_'),\n weekdaysMin: 'Mg_Sn_Sl_Rb_Km_Jm_Sp'.split('_'),\n longDateFormat: {\n LT: 'HH.mm',\n LTS: 'HH.mm.ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY [pukul] HH.mm',\n LLLL: 'dddd, D MMMM YYYY [pukul] HH.mm',\n },\n meridiemParse: /enjing|siyang|sonten|ndalu/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'enjing') {\n return hour;\n } else if (meridiem === 'siyang') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === 'sonten' || meridiem === 'ndalu') {\n return hour + 12;\n }\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours < 11) {\n return 'enjing';\n } else if (hours < 15) {\n return 'siyang';\n } else if (hours < 19) {\n return 'sonten';\n } else {\n return 'ndalu';\n }\n },\n calendar: {\n sameDay: '[Dinten puniko pukul] LT',\n nextDay: '[Mbenjang pukul] LT',\n nextWeek: 'dddd [pukul] LT',\n lastDay: '[Kala wingi pukul] LT',\n lastWeek: 'dddd [kepengker pukul] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'wonten ing %s',\n past: '%s ingkang kepengker',\n s: 'sawetawis detik',\n ss: '%d detik',\n m: 'setunggal menit',\n mm: '%d menit',\n h: 'setunggal jam',\n hh: '%d jam',\n d: 'sedinten',\n dd: '%d dinten',\n M: 'sewulan',\n MM: '%d wulan',\n y: 'setaun',\n yy: '%d taun',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return jv;\n\n})));\n","//! moment.js locale configuration\n//! locale : Spanish (Mexico) [es-mx]\n//! author : JC Franco : https://github.com/jcfranco\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsShortDot =\n 'ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.'.split(\n '_'\n ),\n monthsShort = 'ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic'.split('_'),\n monthsParse = [\n /^ene/i,\n /^feb/i,\n /^mar/i,\n /^abr/i,\n /^may/i,\n /^jun/i,\n /^jul/i,\n /^ago/i,\n /^sep/i,\n /^oct/i,\n /^nov/i,\n /^dic/i,\n ],\n monthsRegex =\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i;\n\n var esMx = moment.defineLocale('es-mx', {\n months: 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split(\n '_'\n ),\n monthsShort: function (m, format) {\n if (!m) {\n return monthsShortDot;\n } else if (/-MMM-/.test(format)) {\n return monthsShort[m.month()];\n } else {\n return monthsShortDot[m.month()];\n }\n },\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex:\n /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,\n monthsShortStrictRegex:\n /^(ene\\.?|feb\\.?|mar\\.?|abr\\.?|may\\.?|jun\\.?|jul\\.?|ago\\.?|sep\\.?|oct\\.?|nov\\.?|dic\\.?)/i,\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n weekdays: 'domingo_lunes_martes_miércoles_jueves_viernes_sábado'.split('_'),\n weekdaysShort: 'dom._lun._mar._mié._jue._vie._sáb.'.split('_'),\n weekdaysMin: 'do_lu_ma_mi_ju_vi_sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D [de] MMMM [de] YYYY',\n LLL: 'D [de] MMMM [de] YYYY H:mm',\n LLLL: 'dddd, D [de] MMMM [de] YYYY H:mm',\n },\n calendar: {\n sameDay: function () {\n return '[hoy a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextDay: function () {\n return '[mañana a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n nextWeek: function () {\n return 'dddd [a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastDay: function () {\n return '[ayer a la' + (this.hours() !== 1 ? 's' : '') + '] LT';\n },\n lastWeek: function () {\n return (\n '[el] dddd [pasado a la' +\n (this.hours() !== 1 ? 's' : '') +\n '] LT'\n );\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'en %s',\n past: 'hace %s',\n s: 'unos segundos',\n ss: '%d segundos',\n m: 'un minuto',\n mm: '%d minutos',\n h: 'una hora',\n hh: '%d horas',\n d: 'un dÃa',\n dd: '%d dÃas',\n w: 'una semana',\n ww: '%d semanas',\n M: 'un mes',\n MM: '%d meses',\n y: 'un año',\n yy: '%d años',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n invalidDate: 'Fecha inválida',\n });\n\n return esMx;\n\n})));\n","import { select, detach } from '@syncfusion/ej2-base';\nimport { VScroll } from './v-scroll';\nimport { HScroll } from './h-scroll';\n/**\n * Used to add scroll in menu.\n *\n * @param {createElementType} createElement - Specifies the create element model\n * @param {HTMLElement} container - Specifies the element container\n * @param {HTMLElement} content - Specifies the content element\n * @param {string} scrollType - Specifies the scroll type\n * @param {boolean} enableRtl - Specifies the enable RTL property\n * @param {boolean} offset - Specifies the offset value\n * @returns {HTMLElement} - Element\n * @hidden\n */\nexport function addScrolling(createElement, container, content, scrollType, enableRtl, offset) {\n var containerOffset;\n var contentOffset;\n var parentElem = container.parentElement;\n if (scrollType === 'vscroll') {\n containerOffset = offset || container.getBoundingClientRect().height;\n contentOffset = content.getBoundingClientRect().height;\n }\n else {\n containerOffset = container.getBoundingClientRect().width;\n contentOffset = content.getBoundingClientRect().width;\n }\n if (containerOffset < contentOffset) {\n return createScrollbar(createElement, container, content, scrollType, enableRtl, offset);\n }\n else if (parentElem) {\n var width = parentElem.getBoundingClientRect().width;\n if (width < containerOffset && scrollType === 'hscroll') {\n contentOffset = width;\n container.style.maxWidth = width + 'px';\n return createScrollbar(createElement, container, content, scrollType, enableRtl, offset);\n }\n return content;\n }\n else {\n return content;\n }\n}\n/**\n * Used to create scroll bar in menu.\n *\n * @param {createElementType} createElement - Specifies the create element model\n * @param {HTMLElement} container - Specifies the element container\n * @param {HTMLElement} content - Specifies the content element\n * @param {string} scrollType - Specifies the scroll type\n * @param {boolean} enableRtl - Specifies the enable RTL property\n * @param {boolean} offset - Specifies the offset value\n * @returns {HTMLElement} - Element\n * @hidden\n */\nfunction createScrollbar(createElement, container, content, scrollType, enableRtl, offset) {\n var scrollEle = createElement('div', { className: 'e-menu-' + scrollType });\n container.appendChild(scrollEle);\n scrollEle.appendChild(content);\n if (offset) {\n scrollEle.style.overflow = 'hidden';\n scrollEle.style.height = offset + 'px';\n }\n else {\n scrollEle.style.maxHeight = container.style.maxHeight;\n container.style.overflow = 'hidden';\n }\n var scrollObj;\n if (scrollType === 'vscroll') {\n scrollObj = new VScroll({ enableRtl: enableRtl }, scrollEle);\n scrollObj.scrollStep = select('.e-' + scrollType + '-bar', container).offsetHeight / 2;\n }\n else {\n scrollObj = new HScroll({ enableRtl: enableRtl }, scrollEle);\n scrollObj.scrollStep = select('.e-' + scrollType + '-bar', container).offsetWidth;\n }\n return scrollEle;\n}\n/**\n * Used to destroy the scroll option.\n *\n * @param {VScroll | HScroll} scrollObj - Specifies the scroller object\n * @param {Element} element - Specifies the element\n * @param {HTMLElement} skipEle - Specifies the skip element\n * @returns {void}\n * @hidden\n */\nexport function destroyScroll(scrollObj, element, skipEle) {\n if (scrollObj) {\n var menu = select('.e-menu-parent', element);\n if (menu) {\n if (!skipEle || skipEle === menu) {\n scrollObj.destroy();\n element.parentElement.appendChild(menu);\n detach(element);\n }\n }\n else {\n scrollObj.destroy();\n detach(element);\n }\n }\n}\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Component, Property, ChildProperty, NotifyPropertyChanges, isBlazor } from '@syncfusion/ej2-base';\nimport { Event, EventHandler, KeyboardEvents, Touch } from '@syncfusion/ej2-base';\nimport { Animation } from '@syncfusion/ej2-base';\nimport { Browser, Collection, setValue, getValue, getUniqueID, getInstance, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { select, selectAll, closest, detach, append, rippleEffect, isVisible, Complex, addClass, removeClass } from '@syncfusion/ej2-base';\nimport { ListBase } from '@syncfusion/ej2-lists';\nimport { getZindexPartial, calculatePosition, isCollide, fit, Popup } from '@syncfusion/ej2-popups';\nimport { SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport { getScrollableParent } from '@syncfusion/ej2-popups';\nimport { HScroll } from '../common/h-scroll';\nimport { VScroll } from '../common/v-scroll';\nimport { addScrolling, destroyScroll } from '../common/menu-scroll';\nvar ENTER = 'enter';\nvar ESCAPE = 'escape';\nvar FOCUSED = 'e-focused';\nvar HEADER = 'e-menu-header';\nvar SELECTED = 'e-selected';\nvar SEPARATOR = 'e-separator';\nvar UPARROW = 'uparrow';\nvar DOWNARROW = 'downarrow';\nvar LEFTARROW = 'leftarrow';\nvar RIGHTARROW = 'rightarrow';\nvar HOME = 'home';\nvar END = 'end';\nvar TAB = 'tab';\nvar CARET = 'e-caret';\nvar ITEM = 'e-menu-item';\nvar DISABLED = 'e-disabled';\nvar HIDE = 'e-menu-hide';\nvar ICONS = 'e-icons';\nvar RTL = 'e-rtl';\nvar POPUP = 'e-menu-popup';\nvar TEMPLATE_PROPERTY = 'Template';\n/**\n * Configures the field options of the Menu.\n */\nvar FieldSettings = /** @class */ (function (_super) {\n __extends(FieldSettings, _super);\n function FieldSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('id')\n ], FieldSettings.prototype, \"itemId\", void 0);\n __decorate([\n Property('parentId')\n ], FieldSettings.prototype, \"parentId\", void 0);\n __decorate([\n Property('text')\n ], FieldSettings.prototype, \"text\", void 0);\n __decorate([\n Property('iconCss')\n ], FieldSettings.prototype, \"iconCss\", void 0);\n __decorate([\n Property('url')\n ], FieldSettings.prototype, \"url\", void 0);\n __decorate([\n Property('separator')\n ], FieldSettings.prototype, \"separator\", void 0);\n __decorate([\n Property('items')\n ], FieldSettings.prototype, \"children\", void 0);\n return FieldSettings;\n}(ChildProperty));\nexport { FieldSettings };\n/**\n * Specifies menu items.\n */\nvar MenuItem = /** @class */ (function (_super) {\n __extends(MenuItem, _super);\n function MenuItem() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], MenuItem.prototype, \"iconCss\", void 0);\n __decorate([\n Property('')\n ], MenuItem.prototype, \"id\", void 0);\n __decorate([\n Property(false)\n ], MenuItem.prototype, \"separator\", void 0);\n __decorate([\n Collection([], MenuItem)\n ], MenuItem.prototype, \"items\", void 0);\n __decorate([\n Property('')\n ], MenuItem.prototype, \"text\", void 0);\n __decorate([\n Property('')\n ], MenuItem.prototype, \"url\", void 0);\n return MenuItem;\n}(ChildProperty));\nexport { MenuItem };\n/**\n * Animation configuration settings.\n */\nvar MenuAnimationSettings = /** @class */ (function (_super) {\n __extends(MenuAnimationSettings, _super);\n function MenuAnimationSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('SlideDown')\n ], MenuAnimationSettings.prototype, \"effect\", void 0);\n __decorate([\n Property(400)\n ], MenuAnimationSettings.prototype, \"duration\", void 0);\n __decorate([\n Property('ease')\n ], MenuAnimationSettings.prototype, \"easing\", void 0);\n return MenuAnimationSettings;\n}(ChildProperty));\nexport { MenuAnimationSettings };\n/**\n * Base class for Menu and ContextMenu components.\n *\n * @private\n */\nvar MenuBase = /** @class */ (function (_super) {\n __extends(MenuBase, _super);\n /**\n * Constructor for creating the widget.\n *\n * @private\n * @param {MenuBaseModel} options - Specifies the menu base model\n * @param {string | HTMLUListElement} element - Specifies the element\n */\n function MenuBase(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.navIdx = [];\n _this.animation = new Animation({});\n _this.isTapHold = false;\n _this.tempItem = [];\n _this.showSubMenuOn = 'Auto';\n return _this;\n }\n /**\n * Initialized third party configuration settings.\n *\n * @private\n * @returns {void}\n */\n MenuBase.prototype.preRender = function () {\n if (!this.isMenu) {\n var ul = void 0;\n if (this.element.tagName === 'EJS-CONTEXTMENU') {\n ul = this.createElement('ul', {\n id: getUniqueID(this.getModuleName()), className: 'e-control e-lib e-' + this.getModuleName()\n });\n var ejInst = getValue('ej2_instances', this.element);\n removeClass([this.element], ['e-control', 'e-lib', 'e-' + this.getModuleName()]);\n this.clonedElement = this.element;\n this.element = ul;\n setValue('ej2_instances', ejInst, this.element);\n }\n else {\n ul = this.createElement('ul', { id: getUniqueID(this.getModuleName()) });\n append([].slice.call(this.element.cloneNode(true).children), ul);\n var refEle = this.element.nextElementSibling;\n if (refEle) {\n this.element.parentElement.insertBefore(ul, refEle);\n }\n else {\n this.element.parentElement.appendChild(ul);\n }\n this.clonedElement = ul;\n }\n this.clonedElement.style.display = 'none';\n }\n if (this.element.tagName === 'EJS-MENU') {\n var ele = this.element;\n var ejInstance = getValue('ej2_instances', ele);\n var ul = this.createElement('ul');\n var wrapper = this.createElement('EJS-MENU', { className: 'e-' + this.getModuleName() + '-wrapper' });\n for (var idx = 0, len = ele.attributes.length; idx < len; idx++) {\n ul.setAttribute(ele.attributes[idx].nodeName, ele.attributes[idx].nodeValue);\n }\n ele.parentNode.insertBefore(wrapper, ele);\n detach(ele);\n ele = ul;\n wrapper.appendChild(ele);\n setValue('ej2_instances', ejInstance, ele);\n this.clonedElement = wrapper;\n this.element = ele;\n if (!this.element.id) {\n this.element.id = getUniqueID(this.getModuleName());\n }\n }\n };\n /**\n * Initialize the control rendering.\n *\n * @private\n * @returns {void}\n */\n MenuBase.prototype.render = function () {\n var _this = this;\n this.initialize();\n this.renderItems();\n this.wireEvents();\n this.renderComplete();\n var wrapper = this.getWrapper();\n // eslint-disable-next-line\n if (this.template && this.enableScrolling && (this.isReact || this.isAngular)) {\n requestAnimationFrame(function () {\n addScrolling(_this.createElement, wrapper, _this.element, 'hscroll', _this.enableRtl);\n });\n }\n };\n MenuBase.prototype.initialize = function () {\n var wrapper = this.getWrapper();\n if (!wrapper) {\n wrapper = this.createElement('div', { className: 'e-' + this.getModuleName() + '-wrapper' });\n if (this.isMenu) {\n this.element.parentElement.insertBefore(wrapper, this.element);\n }\n else {\n document.body.appendChild(wrapper);\n }\n }\n if (this.cssClass) {\n addClass([wrapper], this.cssClass.replace(/\\s+/g, ' ').trim().split(' '));\n }\n if (this.enableRtl) {\n wrapper.classList.add(RTL);\n }\n wrapper.appendChild(this.element);\n if (this.isMenu && this.hamburgerMode) {\n if (!this.target) {\n this.createHeaderContainer(wrapper);\n }\n }\n this.defaultOption = this.showItemOnClick;\n };\n MenuBase.prototype.renderItems = function () {\n if (!this.items.length) {\n var items = ListBase.createJsonFromElement(this.element, { fields: { child: 'items' } });\n this.setProperties({ items: items }, true);\n if (isBlazor() && !this.isMenu) {\n this.element = this.removeChildElement(this.element);\n }\n else {\n this.element.innerHTML = '';\n }\n }\n var ul = this.createItems(this.items);\n append(Array.prototype.slice.call(ul.children), this.element);\n this.element.classList.add('e-menu-parent');\n if (this.isMenu) {\n if (!this.hamburgerMode && this.element.classList.contains('e-vertical')) {\n this.setBlankIconStyle(this.element);\n }\n if (this.enableScrolling) {\n var wrapper = this.getWrapper();\n if (this.element.classList.contains('e-vertical')) {\n addScrolling(this.createElement, wrapper, this.element, 'vscroll', this.enableRtl);\n }\n else {\n addScrolling(this.createElement, wrapper, this.element, 'hscroll', this.enableRtl);\n }\n }\n }\n else {\n this.element.parentElement.setAttribute('role', 'dialog');\n this.element.parentElement.setAttribute('aria-label', 'context menu');\n }\n };\n MenuBase.prototype.wireEvents = function () {\n var wrapper = this.getWrapper();\n if (this.target) {\n var target = void 0;\n var targetElems = selectAll(this.target);\n for (var i = 0, len = targetElems.length; i < len; i++) {\n target = targetElems[i];\n if (this.isMenu) {\n EventHandler.add(target, 'click', this.menuHeaderClickHandler, this);\n }\n else {\n if (Browser.isIos) {\n new Touch(target, { tapHold: this.touchHandler.bind(this) });\n }\n else {\n EventHandler.add(target, 'contextmenu', this.cmenuHandler, this);\n }\n }\n }\n this.targetElement = target;\n if (!this.isMenu) {\n EventHandler.add(this.targetElement, 'mousewheel DOMMouseScroll', this.scrollHandler, this);\n for (var _i = 0, _a = getScrollableParent(this.targetElement); _i < _a.length; _i++) {\n var parent_1 = _a[_i];\n EventHandler.add(parent_1, 'mousewheel DOMMouseScroll', this.scrollHandler, this);\n }\n }\n }\n if (!Browser.isDevice) {\n this.delegateMoverHandler = this.moverHandler.bind(this);\n this.delegateMouseDownHandler = this.mouseDownHandler.bind(this);\n EventHandler.add(this.isMenu ? document : wrapper, 'mouseover', this.delegateMoverHandler, this);\n EventHandler.add(document, 'mousedown', this.delegateMouseDownHandler, this);\n }\n this.delegateClickHandler = this.clickHandler.bind(this);\n EventHandler.add(document, 'click', this.delegateClickHandler, this);\n this.wireKeyboardEvent(wrapper);\n this.rippleFn = rippleEffect(wrapper, { selector: '.' + ITEM });\n };\n MenuBase.prototype.wireKeyboardEvent = function (element) {\n var keyConfigs = {\n downarrow: DOWNARROW,\n uparrow: UPARROW,\n enter: ENTER,\n leftarrow: LEFTARROW,\n rightarrow: RIGHTARROW,\n escape: ESCAPE\n };\n if (this.isMenu) {\n keyConfigs.home = HOME;\n keyConfigs.end = END;\n keyConfigs.tab = TAB;\n }\n new KeyboardEvents(element, {\n keyAction: this.keyBoardHandler.bind(this),\n keyConfigs: keyConfigs\n });\n };\n MenuBase.prototype.mouseDownHandler = function (e) {\n if (closest(e.target, '.e-' + this.getModuleName() + '-wrapper') !== this.getWrapper()\n && (!closest(e.target, '.e-' + this.getModuleName() + '-popup'))) {\n this.closeMenu(this.isMenu ? null : this.navIdx.length, e);\n }\n };\n MenuBase.prototype.keyHandler = function (e) {\n if (e.keyCode === 38 || e.keyCode === 40) {\n if (e.target && (e.target.classList.contains('e-contextmenu') || e.target.classList.contains('e-menu-item'))) {\n e.preventDefault();\n }\n }\n };\n MenuBase.prototype.keyBoardHandler = function (e) {\n var actionName = '';\n var trgt = e.target;\n var actionNeeded = this.isMenu && !this.hamburgerMode && !this.element.classList.contains('e-vertical')\n && this.navIdx.length < 1;\n e.preventDefault();\n if (this.enableScrolling && e.keyCode === 13 && trgt.classList.contains('e-scroll-nav')) {\n this.removeLIStateByClass([FOCUSED, SELECTED], [closest(trgt, '.e-' + this.getModuleName() + '-wrapper')]);\n }\n if (actionNeeded) {\n switch (e.action) {\n case RIGHTARROW:\n actionName = RIGHTARROW;\n e.action = DOWNARROW;\n break;\n case LEFTARROW:\n actionName = LEFTARROW;\n e.action = UPARROW;\n break;\n case DOWNARROW:\n actionName = DOWNARROW;\n e.action = RIGHTARROW;\n break;\n case UPARROW:\n actionName = UPARROW;\n e.action = '';\n break;\n }\n }\n else if (this.enableRtl) {\n switch (e.action) {\n case LEFTARROW:\n actionNeeded = true;\n actionName = LEFTARROW;\n e.action = RIGHTARROW;\n break;\n case RIGHTARROW:\n actionNeeded = true;\n actionName = RIGHTARROW;\n e.action = LEFTARROW;\n break;\n }\n }\n switch (e.action) {\n case DOWNARROW:\n case UPARROW:\n case END:\n case HOME:\n case TAB:\n this.upDownKeyHandler(e);\n break;\n case RIGHTARROW:\n this.rightEnterKeyHandler(e);\n break;\n case LEFTARROW:\n this.leftEscKeyHandler(e);\n break;\n case ENTER:\n if (this.hamburgerMode && trgt.tagName === 'SPAN' && trgt.classList.contains('e-menu-icon')) {\n this.menuHeaderClickHandler(e);\n }\n else {\n this.rightEnterKeyHandler(e);\n }\n break;\n case ESCAPE:\n this.leftEscKeyHandler(e);\n break;\n }\n if (actionNeeded) {\n e.action = actionName;\n }\n };\n MenuBase.prototype.upDownKeyHandler = function (e) {\n var cul = this.getUlByNavIdx();\n var defaultIdx = (e.action === DOWNARROW || e.action === HOME || e.action === TAB) ? 0 : cul.childElementCount - 1;\n var fliIdx = defaultIdx;\n var fli = this.getLIByClass(cul, FOCUSED);\n if (fli) {\n if (e.action !== END && e.action !== HOME) {\n fliIdx = this.getIdx(cul, fli);\n }\n fli.classList.remove(FOCUSED);\n if (e.action !== END && e.action !== HOME) {\n if (e.action === DOWNARROW) {\n fliIdx++;\n }\n else {\n fliIdx--;\n }\n if (fliIdx === (e.action === DOWNARROW ? cul.childElementCount : -1)) {\n fliIdx = defaultIdx;\n }\n }\n }\n var cli = cul.children[fliIdx];\n fliIdx = this.isValidLI(cli, fliIdx, e.action);\n cul.children[fliIdx].classList.add(FOCUSED);\n cul.children[fliIdx].focus();\n };\n MenuBase.prototype.isValidLI = function (cli, index, action) {\n var cul = this.getUlByNavIdx();\n var defaultIdx = (action === DOWNARROW || action === HOME || action === TAB) ? 0 : cul.childElementCount - 1;\n if (cli.classList.contains(SEPARATOR) || cli.classList.contains(DISABLED) || cli.classList.contains(HIDE)) {\n if (action === DOWNARROW && index === cul.childElementCount - 1) {\n index = defaultIdx;\n }\n else if (action === UPARROW && index === 0) {\n index = defaultIdx;\n }\n else if ((action === DOWNARROW) || (action === RIGHTARROW)) {\n index++;\n }\n else {\n index--;\n }\n }\n cli = cul.children[index];\n if (cli.classList.contains(SEPARATOR) || cli.classList.contains(DISABLED) || cli.classList.contains(HIDE)) {\n index = this.isValidLI(cli, index, action);\n }\n return index;\n };\n MenuBase.prototype.getUlByNavIdx = function (navIdxLen) {\n var _this = this;\n if (navIdxLen === void 0) { navIdxLen = this.navIdx.length; }\n if (this.isMenu) {\n var popup = [this.getWrapper()].concat([].slice.call(selectAll('.' + POPUP)))[navIdxLen];\n var popups_1 = [];\n var allPopup = selectAll('.' + POPUP);\n allPopup.forEach(function (elem) {\n if (_this.element.id === elem.id.split('-')[2] || elem.id.split('-')[2] + '-' + elem.id.split('-')[3]) {\n popups_1.push(elem);\n }\n });\n popup = [this.getWrapper()].concat([].slice.call(popups_1))[navIdxLen];\n return isNullOrUndefined(popup) ? null : select('.e-menu-parent', popup);\n }\n else {\n return this.getWrapper().children[navIdxLen];\n }\n };\n MenuBase.prototype.rightEnterKeyHandler = function (e) {\n var eventArgs;\n var cul = this.getUlByNavIdx();\n var fli = this.getLIByClass(cul, FOCUSED);\n if (fli) {\n var fliIdx = this.getIdx(cul, fli);\n var navIdx = this.navIdx.concat(fliIdx);\n var item = this.getItem(navIdx);\n if (item.items.length) {\n this.navIdx.push(fliIdx);\n this.keyType = 'right';\n this.action = e.action;\n this.openMenu(fli, item, -1, -1, e);\n }\n else {\n if (e.action === ENTER) {\n if (this.isMenu && this.navIdx.length === 0) {\n this.removeLIStateByClass([SELECTED], [this.getWrapper()]);\n }\n else {\n fli.classList.remove(FOCUSED);\n }\n fli.classList.add(SELECTED);\n eventArgs = { element: fli, item: item, event: e };\n this.trigger('select', eventArgs);\n var aEle = fli.querySelector('.e-menu-url');\n if (item.url && aEle) {\n switch (aEle.getAttribute('target')) {\n case '_blank':\n window.open(item.url, '_blank');\n break;\n case '_parent':\n window.parent.location.href = item.url;\n break;\n default:\n window.location.href = item.url;\n }\n }\n this.closeMenu(null, e);\n var sli = this.getLIByClass(this.getUlByNavIdx(), SELECTED);\n if (sli) {\n sli.classList.add(FOCUSED);\n sli.focus();\n }\n }\n }\n }\n };\n MenuBase.prototype.leftEscKeyHandler = function (e) {\n if (this.navIdx.length) {\n this.keyType = 'left';\n this.closeMenu(this.navIdx.length, e);\n }\n else {\n if (e.action === ESCAPE) {\n this.closeMenu(null, e);\n }\n }\n };\n MenuBase.prototype.scrollHandler = function (e) {\n this.closeMenu(null, e);\n };\n MenuBase.prototype.touchHandler = function (e) {\n this.isTapHold = true;\n this.cmenuHandler(e.originalEvent);\n };\n MenuBase.prototype.cmenuHandler = function (e) {\n e.preventDefault();\n this.currentTarget = e.target;\n this.isCMenu = true;\n this.pageX = e.changedTouches ? e.changedTouches[0].pageX + 1 : e.pageX + 1;\n this.pageY = e.changedTouches ? e.changedTouches[0].pageY + 1 : e.pageY + 1;\n this.closeMenu(null, e);\n if (this.isCMenu) {\n if (this.canOpen(e.target)) {\n this.openMenu(null, null, this.pageY, this.pageX, e);\n }\n this.isCMenu = false;\n }\n };\n // eslint:disable-next-line:max-func-body-length\n MenuBase.prototype.closeMenu = function (ulIndex, e, isIterated) {\n var _this = this;\n if (ulIndex === void 0) { ulIndex = 0; }\n if (e === void 0) { e = null; }\n if (this.isMenuVisible()) {\n var sli = void 0;\n var item_1;\n var wrapper_1 = this.getWrapper();\n var beforeCloseArgs = void 0;\n var items_1;\n var popups = this.getPopups();\n var isClose = false;\n var cnt = this.isMenu ? popups.length + 1 : wrapper_1.childElementCount;\n var ul_1 = this.isMenu && cnt !== 1 ? select('.e-ul', popups[cnt - 2])\n : selectAll('.e-menu-parent', wrapper_1)[cnt - 1];\n if (this.isMenu && ul_1.classList.contains('e-menu')) {\n sli = this.getLIByClass(ul_1, SELECTED);\n if (sli) {\n sli.classList.remove(SELECTED);\n }\n isClose = true;\n }\n if (!isClose) {\n var liElem_1 = e && e.target && this.getLI(e.target);\n if (liElem_1) {\n this.cli = liElem_1;\n }\n else {\n this.cli = ul_1.children[0];\n }\n item_1 = this.navIdx.length ? this.getItem(this.navIdx) : null;\n items_1 = item_1 ? item_1.items : this.items;\n beforeCloseArgs = { element: ul_1, parentItem: item_1, items: items_1, event: e, cancel: false, isFocused: true };\n this.trigger('beforeClose', beforeCloseArgs, function (observedCloseArgs) {\n var popupEle;\n var closeArgs;\n var popupId = '';\n var popupObj;\n var isOpen = !observedCloseArgs.cancel;\n if (isOpen || _this.isCMenu) {\n if (_this.isMenu) {\n popupEle = closest(ul_1, '.' + POPUP);\n if (_this.hamburgerMode) {\n popupEle.parentElement.style.minHeight = '';\n closest(ul_1, '.e-menu-item').setAttribute('aria-expanded', 'false');\n }\n _this.unWireKeyboardEvent(popupEle);\n destroyScroll(getInstance(popupEle.children[0], VScroll), popupEle.children[0]);\n popupObj = getInstance(popupEle, Popup);\n popupObj.hide();\n popupId = popupEle.id;\n popupObj.destroy();\n detach(popupEle);\n }\n else {\n _this.toggleAnimation(ul_1, false);\n }\n closeArgs = { element: ul_1, parentItem: item_1, items: items_1 };\n _this.trigger('onClose', closeArgs);\n _this.navIdx.pop();\n if (_this.navIdx.length === 0 && e && e.type === 'keyup') {\n _this.showSubMenu = false;\n }\n if (!_this.isMenu) {\n EventHandler.remove(ul_1, 'keydown', _this.keyHandler);\n if (_this.keyType === 'right') {\n _this.keyType = '';\n }\n }\n }\n _this.updateReactTemplate();\n var trgtliId;\n var closedLi;\n var trgtLi;\n var trgtpopUp = _this.getWrapper() && _this.getUlByNavIdx();\n if (_this.isCMenu) {\n if (_this.canOpen(e.target)) {\n _this.openMenu(null, null, _this.pageY, _this.pageX, e);\n }\n _this.isCMenu = false;\n }\n if (_this.isMenu && trgtpopUp && popupId.length) {\n // eslint-disable-next-line\n trgtliId = new RegExp('(.*)-ej2menu-' + _this.element.id + '-popup').exec(popupId)[1];\n closedLi = trgtpopUp.querySelector('[id=\"' + trgtliId + '\"]');\n trgtLi = (liElem_1 && trgtpopUp.querySelector('[id=\"' + liElem_1.id + '\"]'));\n }\n else if (trgtpopUp) {\n closedLi = trgtpopUp.querySelector('.e-menu-item.e-selected');\n trgtLi = (liElem_1 && trgtpopUp.querySelector('[id=\"' + liElem_1.id + '\"]'));\n }\n var submenus = liElem_1 && liElem_1.querySelectorAll('.e-menu-item');\n if (isOpen && _this.hamburgerMode && ulIndex && !(submenus.length)) {\n _this.afterCloseMenu(e);\n }\n else if (isOpen && !_this.hamburgerMode && closedLi && !trgtLi && _this.keyType !== 'left' && (_this.navIdx.length || !_this.isMenu && _this.navIdx.length === 0)) {\n var ele = (e && (e.target.classList.contains('e-vscroll') || e.target.classList.contains('e-scroll-nav')))\n ? closest(e.target, '.e-menu-wrapper') : null;\n if (ele) {\n ele = ele.querySelector('.e-menu-item');\n if (_this.showItemOnClick || (ele && _this.getIndex(ele.id, true).length <= _this.navIdx.length)) {\n _this.closeMenu(_this.navIdx[_this.navIdx.length - 1], e, true);\n }\n }\n else {\n if (!(e && e.target.classList.contains('e-nav-arrow'))) {\n _this.closeMenu(_this.navIdx[_this.navIdx.length - 1], e);\n }\n }\n }\n else if (isOpen && !isIterated && !ulIndex && ((_this.hamburgerMode && _this.navIdx.length) ||\n _this.navIdx.length === 1 && liElem_1 && trgtpopUp !== liElem_1.parentElement)) {\n _this.closeMenu(null, e);\n }\n else if (isOpen && isNullOrUndefined(ulIndex) && _this.navIdx.length) {\n _this.closeMenu(null, e);\n }\n else if (isOpen && !_this.isMenu && !ulIndex && _this.navIdx.length === 0 && !_this.isMenusClosed) {\n _this.isMenusClosed = true;\n _this.closeMenu(0, e);\n }\n else if (isOpen && _this.isMenu && e && e.target &&\n _this.navIdx.length !== 0 && closest(e.target, '.e-menu-parent.e-control')) {\n _this.closeMenu(0, e);\n }\n else if (isOpen && !_this.isMenu && selectAll('.e-menu-parent', wrapper_1)[ulIndex - 1] && e.which === 3) {\n _this.closeMenu(null, e);\n }\n else {\n if (isOpen && (_this.keyType === 'right' || _this.keyType === 'click')) {\n _this.afterCloseMenu(e);\n }\n else {\n var cul = _this.getUlByNavIdx();\n var sli_1 = _this.getLIByClass(cul, SELECTED);\n if (sli_1) {\n sli_1.setAttribute('aria-expanded', 'false');\n sli_1.classList.remove(SELECTED);\n if (observedCloseArgs.isFocused && liElem_1 || _this.keyType === 'left') {\n sli_1.classList.add(FOCUSED);\n if (!e.target || !e.target.classList.contains('e-edit-template')) {\n sli_1.focus();\n }\n }\n }\n if (!isOpen && _this.hamburgerMode && liElem_1 && liElem_1.getAttribute('aria-expanded') === 'false' &&\n liElem_1.getAttribute('aria-haspopup') === 'true') {\n if (closest(liElem_1, '.e-menu-parent.e-control')) {\n _this.navIdx = [];\n }\n else {\n _this.navIdx.pop();\n }\n _this.navIdx.push(_this.cliIdx);\n var item_2 = _this.getItem(_this.navIdx);\n liElem_1.setAttribute('aria-expanded', 'true');\n _this.openMenu(liElem_1, item_2, -1, -1, e);\n }\n }\n if (_this.navIdx.length < 1) {\n if (_this.showSubMenuOn === 'Hover' || _this.showSubMenuOn === 'Click') {\n _this.showItemOnClick = _this.defaultOption;\n _this.showSubMenuOn = 'Auto';\n }\n }\n }\n _this.removeStateWrapper();\n });\n }\n }\n };\n MenuBase.prototype.updateReactTemplate = function () {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this.isReact && this.template && this.navIdx.length === 0) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var portals = this.portals.splice(0, this.items.length);\n this.clearTemplate(['template']);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.portals = portals;\n this.renderReactTemplates();\n }\n };\n MenuBase.prototype.getMenuItemModel = function (item, level) {\n if (isNullOrUndefined(item)) {\n return null;\n }\n if (isNullOrUndefined(level)) {\n level = 0;\n }\n var fields = this.getFields(level);\n return { text: item[fields.text], id: item[fields.id], items: item[fields.child], separator: item[fields.separator],\n iconCss: item[fields.iconCss], url: item[fields.url] };\n };\n MenuBase.prototype.getPopups = function () {\n var _this = this;\n var popups = [];\n [].slice.call(document.querySelectorAll('.' + POPUP)).forEach(function (elem) {\n if (!isNullOrUndefined(elem.querySelector('.' + ITEM)) && _this.getIndex(elem.querySelector('.' + ITEM).id, true).length) {\n popups.push(elem);\n }\n });\n return popups;\n };\n MenuBase.prototype.isMenuVisible = function () {\n return (this.navIdx.length > 0 || (this.element.classList.contains('e-contextmenu') && isVisible(this.element).valueOf()));\n };\n MenuBase.prototype.canOpen = function (target) {\n var canOpen = true;\n if (this.filter) {\n canOpen = false;\n var filter = this.filter.split(' ');\n for (var i = 0, len = filter.length; i < len; i++) {\n if (closest(target, '.' + filter[i])) {\n canOpen = true;\n break;\n }\n }\n }\n return canOpen;\n };\n MenuBase.prototype.openMenu = function (li, item, top, left, e, target) {\n var _this = this;\n if (top === void 0) { top = 0; }\n if (left === void 0) { left = 0; }\n if (e === void 0) { e = null; }\n if (target === void 0) { target = this.targetElement; }\n var wrapper = this.getWrapper();\n this.lItem = li;\n var elemId = this.element.id !== '' ? this.element.id : 'menu';\n this.isMenusClosed = false;\n if (isNullOrUndefined(top)) {\n top = -1;\n }\n if (isNullOrUndefined(left)) {\n left = -1;\n }\n if (li) {\n this.uList = this.createItems(item[this.getField('children', this.navIdx.length - 1)]);\n if (!this.isMenu && Browser.isDevice) {\n wrapper.lastChild.style.display = 'none';\n var data = {\n text: item[this.getField('text')].toString(), iconCss: ICONS + ' e-previous'\n };\n var hdata = new MenuItem(this.items[0], 'items', data, true);\n var hli = this.createItems([hdata]).children[0];\n hli.classList.add(HEADER);\n this.uList.insertBefore(hli, this.uList.children[0]);\n }\n if (this.isMenu) {\n this.popupWrapper = this.createElement('div', {\n className: 'e-' + this.getModuleName() + '-wrapper ' + POPUP, id: li.id + '-ej2menu-' + elemId + '-popup'\n });\n if (this.hamburgerMode) {\n top = li.offsetHeight;\n li.appendChild(this.popupWrapper);\n }\n else {\n document.body.appendChild(this.popupWrapper);\n }\n this.isNestedOrVertical = this.element.classList.contains('e-vertical') || this.navIdx.length !== 1;\n this.popupObj = this.generatePopup(this.popupWrapper, this.uList, li, this.isNestedOrVertical);\n if (this.template) {\n this.renderReactTemplates();\n }\n if (this.hamburgerMode) {\n this.calculateIndentSize(this.uList, li);\n }\n else {\n if (this.cssClass) {\n addClass([this.popupWrapper], this.cssClass.replace(/\\s+/g, ' ').trim().split(' '));\n }\n this.popupObj.hide();\n }\n if (!this.hamburgerMode && !this.showItemOnClick && this.hoverDelay) {\n window.clearInterval(this.timer);\n this.timer = window.setTimeout(function () { _this.triggerBeforeOpen(li, _this.uList, item, e, 0, 0, 'menu'); }, this.hoverDelay);\n }\n else {\n this.triggerBeforeOpen(li, this.uList, item, e, 0, 0, 'menu');\n }\n }\n else {\n this.uList.style.zIndex = this.element.style.zIndex;\n wrapper.appendChild(this.uList);\n if (!this.showItemOnClick && this.hoverDelay) {\n window.clearInterval(this.timer);\n this.timer = window.setTimeout(function () { _this.triggerBeforeOpen(li, _this.uList, item, e, top, left, 'none'); }, this.hoverDelay);\n }\n else {\n this.triggerBeforeOpen(li, this.uList, item, e, top, left, 'none');\n }\n }\n }\n else {\n this.uList = this.element;\n this.uList.style.zIndex = getZindexPartial(target ? target : this.element).toString();\n if (isNullOrUndefined(e)) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var ev = document.createEvent('MouseEvents');\n ev.initEvent('click', true, false);\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n var targetEvent = this.copyObject(ev, {});\n targetEvent.target = targetEvent.srcElement = target;\n targetEvent.currentTarget = target;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.triggerBeforeOpen(li, this.uList, item, targetEvent, top, left, 'none');\n }\n else {\n this.triggerBeforeOpen(li, this.uList, item, e, top, left, 'none');\n }\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n MenuBase.prototype.copyObject = function (source, destination) {\n for (var prop in source) {\n destination[\"\" + prop] = source[\"\" + prop];\n }\n return destination;\n };\n MenuBase.prototype.calculateIndentSize = function (ul, li) {\n var liStyle = getComputedStyle(li);\n var liIndent = parseInt(liStyle.textIndent, 10);\n if (this.navIdx.length < 2 && !li.classList.contains('e-blankicon')) {\n liIndent *= 2;\n }\n else {\n liIndent += (liIndent / 4);\n }\n ul.style.textIndent = liIndent + 'px';\n var blankIconElem = ul.querySelectorAll('.e-blankicon');\n if (blankIconElem && blankIconElem.length) {\n var menuIconElem = ul.querySelector('.e-menu-icon');\n var menuIconElemStyle = getComputedStyle(menuIconElem);\n var blankIconIndent = (parseInt(menuIconElemStyle.marginRight, 10) + menuIconElem.offsetWidth + liIndent);\n for (var i = 0; i < blankIconElem.length; i++) {\n blankIconElem[i].style.textIndent = blankIconIndent + 'px';\n }\n }\n };\n MenuBase.prototype.generatePopup = function (popupWrapper, ul, li, isNestedOrVertical) {\n var _this = this;\n var popupObj = new Popup(popupWrapper, {\n actionOnScroll: this.hamburgerMode ? 'none' : 'reposition',\n relateTo: li,\n collision: this.hamburgerMode ? { X: 'none', Y: 'none' } : { X: isNestedOrVertical ||\n this.enableRtl ? 'none' : 'flip', Y: 'fit' },\n position: (isNestedOrVertical && !this.hamburgerMode) ? { X: 'right', Y: 'top' } : { X: 'left', Y: 'bottom' },\n targetType: 'relative',\n enableRtl: this.enableRtl,\n content: ul,\n open: function () {\n var scrollEle = select('.e-menu-vscroll', popupObj.element);\n if (scrollEle) {\n scrollEle.style.height = 'inherit';\n scrollEle.style.maxHeight = '';\n }\n var ul = select('.e-ul', popupObj.element);\n popupObj.element.style.maxHeight = '';\n ul.focus();\n _this.triggerOpen(ul);\n }\n });\n return popupObj;\n };\n MenuBase.prototype.createHeaderContainer = function (wrapper) {\n wrapper = wrapper || this.getWrapper();\n var spanElem = this.createElement('span', { className: 'e-' + this.getModuleName() + '-header' });\n var tempTitle = (this.enableHtmlSanitizer) ? SanitizeHtmlHelper.sanitize(this.title) : this.title;\n var spanTitle = this.createElement('span', {\n className: 'e-' + this.getModuleName() + '-title', innerHTML: tempTitle\n });\n var spanIcon = this.createElement('span', {\n className: 'e-icons e-' + this.getModuleName() + '-icon', attrs: { 'tabindex': '0' }\n });\n spanElem.appendChild(spanTitle);\n spanElem.appendChild(spanIcon);\n wrapper.insertBefore(spanElem, this.element);\n };\n MenuBase.prototype.openHamburgerMenu = function (e) {\n if (this.hamburgerMode) {\n this.triggerBeforeOpen(null, this.element, null, e, 0, 0, 'hamburger');\n }\n };\n MenuBase.prototype.closeHamburgerMenu = function (e) {\n var _this = this;\n var beforeCloseArgs = { element: this.element, parentItem: null, event: e,\n items: this.items, cancel: false };\n this.trigger('beforeClose', beforeCloseArgs, function (observedHamburgerCloseArgs) {\n if (!observedHamburgerCloseArgs.cancel) {\n _this.closeMenu(null, e);\n _this.element.classList.add('e-hide-menu');\n _this.trigger('onClose', { element: _this.element, parentItem: null, items: _this.items });\n }\n });\n };\n MenuBase.prototype.callFit = function (element, x, y, top, left) {\n return fit(element, null, { X: x, Y: y }, { top: top, left: left });\n };\n MenuBase.prototype.triggerBeforeOpen = function (li, ul, item, e, top, left, type) {\n var _this = this;\n var items = li ? item[this.getField('children', this.navIdx.length - 1)] : this.items;\n var eventArgs = {\n element: ul, items: items, parentItem: item, event: e, cancel: false, top: top, left: left, showSubMenuOn: 'Auto'\n };\n var menuType = type;\n this.trigger('beforeOpen', eventArgs, function (observedOpenArgs) {\n switch (menuType) {\n case 'menu':\n if (!_this.hamburgerMode) {\n if (observedOpenArgs.showSubMenuOn !== 'Auto') {\n _this.showItemOnClick = !_this.defaultOption;\n _this.showSubMenuOn = observedOpenArgs.showSubMenuOn;\n }\n _this.top = observedOpenArgs.top;\n _this.left = observedOpenArgs.left;\n }\n _this.popupWrapper.style.display = 'block';\n if (!_this.hamburgerMode) {\n _this.popupWrapper.style.maxHeight = _this.popupWrapper.getBoundingClientRect().height + 'px';\n if (_this.enableScrolling) {\n addScrolling(_this.createElement, _this.popupWrapper, _this.uList, 'vscroll', _this.enableRtl);\n }\n _this.checkScrollOffset(e);\n }\n if (!_this.hamburgerMode && !_this.left && !_this.top) {\n _this.popupObj.refreshPosition(_this.lItem, true);\n _this.left = parseInt(_this.popupWrapper.style.left, 10);\n _this.top = parseInt(_this.popupWrapper.style.top, 10);\n if (_this.enableRtl) {\n _this.left =\n _this.isNestedOrVertical ? _this.left - _this.popupWrapper.offsetWidth - _this.lItem.parentElement.offsetWidth + 2\n : _this.left - _this.popupWrapper.offsetWidth + _this.lItem.offsetWidth;\n }\n // eslint-disable-next-line\n if (_this.template && (_this.isReact || _this.isAngular)) {\n requestAnimationFrame(function () {\n _this.collision();\n _this.popupWrapper.style.display = '';\n });\n }\n else {\n _this.collision();\n _this.popupWrapper.style.display = '';\n }\n }\n else {\n _this.popupObj.collision = { X: 'none', Y: 'none' };\n _this.popupWrapper.style.display = '';\n }\n break;\n case 'none':\n _this.top = observedOpenArgs.top;\n _this.left = observedOpenArgs.left;\n break;\n case 'hamburger':\n if (!observedOpenArgs.cancel) {\n _this.element.classList.remove('e-hide-menu');\n _this.triggerOpen(_this.element);\n }\n break;\n }\n if (menuType !== 'hamburger') {\n if (observedOpenArgs.cancel) {\n if (_this.isMenu) {\n _this.popupObj.destroy();\n detach(_this.popupWrapper);\n }\n else if (ul.className.indexOf('e-ul') > -1) {\n detach(ul);\n }\n _this.navIdx.pop();\n }\n else {\n if (_this.isMenu) {\n if (_this.hamburgerMode) {\n _this.popupWrapper.style.top = _this.top + 'px';\n _this.popupWrapper.style.left = 0 + 'px';\n _this.toggleAnimation(_this.popupWrapper);\n }\n else {\n _this.setBlankIconStyle(_this.popupWrapper);\n _this.wireKeyboardEvent(_this.popupWrapper);\n rippleEffect(_this.popupWrapper, { selector: '.' + ITEM });\n _this.popupWrapper.style.left = _this.left + 'px';\n _this.popupWrapper.style.top = _this.top + 'px';\n var animationOptions = _this.animationSettings.effect !== 'None' ? {\n name: _this.animationSettings.effect, duration: _this.animationSettings.duration,\n timingFunction: _this.animationSettings.easing\n } : null;\n _this.popupObj.show(animationOptions, _this.lItem);\n }\n }\n else {\n _this.setBlankIconStyle(_this.uList);\n _this.setPosition(_this.lItem, _this.uList, _this.top, _this.left);\n _this.toggleAnimation(_this.uList);\n }\n }\n }\n if (_this.keyType === 'right') {\n var cul = _this.getUlByNavIdx();\n li.classList.remove(FOCUSED);\n if (_this.isMenu && _this.navIdx.length === 1) {\n _this.removeLIStateByClass([SELECTED], [_this.getWrapper()]);\n }\n li.classList.add(SELECTED);\n if (_this.action === ENTER) {\n var eventArgs_1 = { element: li, item: item, event: e };\n _this.trigger('select', eventArgs_1);\n }\n li.focus();\n cul = _this.getUlByNavIdx();\n var index = _this.isValidLI(cul.children[0], 0, _this.action);\n cul.children[index].classList.add(FOCUSED);\n cul.children[index].focus();\n }\n });\n };\n MenuBase.prototype.collision = function () {\n var collide;\n collide = isCollide(this.popupWrapper, null, this.left, this.top);\n if ((this.isNestedOrVertical || this.enableRtl) && (collide.indexOf('right') > -1\n || collide.indexOf('left') > -1)) {\n this.popupObj.collision.X = 'none';\n var offWidth = closest(this.lItem, '.e-' + this.getModuleName() + '-wrapper').offsetWidth;\n this.left =\n this.enableRtl ? calculatePosition(this.lItem, this.isNestedOrVertical ? 'right' : 'left', 'top').left\n : this.left - this.popupWrapper.offsetWidth - offWidth + 2;\n }\n collide = isCollide(this.popupWrapper, null, this.left, this.top);\n if (collide.indexOf('left') > -1 || collide.indexOf('right') > -1) {\n this.left = this.callFit(this.popupWrapper, true, false, this.top, this.left).left;\n }\n this.popupWrapper.style.left = this.left + 'px';\n };\n MenuBase.prototype.setBlankIconStyle = function (menu) {\n var blankIconList = [].slice.call(menu.getElementsByClassName('e-blankicon'));\n if (!blankIconList.length) {\n return;\n }\n var iconLi = menu.querySelector('.e-menu-item:not(.e-blankicon):not(.e-separator)');\n if (!iconLi) {\n return;\n }\n var icon = iconLi.querySelector('.e-menu-icon');\n if (!icon) {\n return;\n }\n var cssProp = this.enableRtl ? { padding: 'paddingRight', margin: 'marginLeft' } :\n { padding: 'paddingLeft', margin: 'marginRight' };\n var iconCssProps = getComputedStyle(icon);\n var iconSize = parseInt(iconCssProps.fontSize, 10);\n if (!!parseInt(iconCssProps.width, 10) && parseInt(iconCssProps.width, 10) > iconSize) {\n iconSize = parseInt(iconCssProps.width, 10);\n }\n // eslint:disable\n var size = iconSize + parseInt(\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n iconCssProps[cssProp.margin], 10) + parseInt(getComputedStyle(iconLi)[cssProp.padding], 10) + \"px\";\n blankIconList.forEach(function (li) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n li.style[cssProp.padding] = size;\n });\n // eslint:enable\n };\n MenuBase.prototype.checkScrollOffset = function (e) {\n var wrapper = this.getWrapper();\n if (wrapper.children[0].classList.contains('e-menu-hscroll') && this.navIdx.length === 1) {\n var trgt = isNullOrUndefined(e) ? this.element : closest(e.target, '.' + ITEM);\n var offsetEle = select('.e-hscroll-bar', wrapper);\n if (offsetEle.scrollLeft > trgt.offsetLeft) {\n offsetEle.scrollLeft -= (offsetEle.scrollLeft - trgt.offsetLeft);\n }\n var offsetLeft = offsetEle.scrollLeft + offsetEle.offsetWidth;\n var offsetRight = trgt.offsetLeft + trgt.offsetWidth;\n if (offsetLeft < offsetRight) {\n offsetEle.scrollLeft += (offsetRight - offsetLeft);\n }\n }\n };\n MenuBase.prototype.setPosition = function (li, ul, top, left) {\n var px = 'px';\n this.toggleVisiblity(ul);\n if (ul === this.element || (left > -1 && top > -1)) {\n var collide = isCollide(ul, null, left, top);\n if (collide.indexOf('right') > -1) {\n left = left - ul.offsetWidth;\n }\n if (collide.indexOf('bottom') > -1) {\n var offset = this.callFit(ul, false, true, top, left);\n top = offset.top - 20;\n if (top < 0) {\n var newTop = (pageYOffset + document.documentElement.clientHeight) - ul.getBoundingClientRect().height;\n if (newTop > -1) {\n top = newTop;\n }\n }\n }\n collide = isCollide(ul, null, left, top);\n if (collide.indexOf('left') > -1) {\n var offset = this.callFit(ul, true, false, top, left);\n left = offset.left;\n }\n }\n else {\n if (Browser.isDevice) {\n top = Number(this.element.style.top.replace(px, ''));\n left = Number(this.element.style.left.replace(px, ''));\n }\n else {\n var x = this.enableRtl ? 'left' : 'right';\n var offset = calculatePosition(li, x, 'top');\n top = offset.top;\n left = offset.left;\n var collide = isCollide(ul, null, this.enableRtl ? left - ul.offsetWidth : left, top);\n var xCollision = collide.indexOf('left') > -1 || collide.indexOf('right') > -1;\n if (xCollision) {\n offset = calculatePosition(li, this.enableRtl ? 'right' : 'left', 'top');\n left = offset.left;\n }\n if (this.enableRtl || xCollision) {\n left = (this.enableRtl && xCollision) ? left : left - ul.offsetWidth;\n }\n if (collide.indexOf('bottom') > -1) {\n offset = this.callFit(ul, false, true, top, left);\n top = offset.top;\n }\n }\n }\n this.toggleVisiblity(ul, false);\n ul.style.top = top + px;\n ul.style.left = left + px;\n };\n MenuBase.prototype.toggleVisiblity = function (ul, isVisible) {\n if (isVisible === void 0) { isVisible = true; }\n ul.style.visibility = isVisible ? 'hidden' : '';\n ul.style.display = isVisible ? 'block' : 'none';\n };\n MenuBase.prototype.createItems = function (items) {\n var _this = this;\n var level = this.navIdx ? this.navIdx.length : 0;\n var fields = this.getFields(level);\n var showIcon = this.hasField(items, this.getField('iconCss', level));\n var listBaseOptions = {\n showIcon: showIcon,\n moduleName: 'menu',\n fields: fields,\n template: this.template,\n itemNavigable: true,\n itemCreating: function (args) {\n if (!args.curData[args.fields[fields.id]]) {\n args.curData[args.fields[fields.id]] = getUniqueID('menuitem');\n }\n if (isNullOrUndefined(args.curData.htmlAttributes)) {\n args.curData.htmlAttributes = {};\n }\n if (Browser.isIE) {\n args.curData.htmlAttributes.role = 'menuitem';\n args.curData.htmlAttributes.tabindex = '-1';\n }\n else {\n Object.assign(args.curData.htmlAttributes, { role: 'menuitem', tabindex: '-1' });\n }\n if (_this.isMenu && !args.curData[_this.getField('separator', level)]) {\n args.curData.htmlAttributes['aria-label'] = args.curData[args.fields.text] ?\n args.curData[args.fields.text] : args.curData[args.fields.id];\n }\n if (args.curData[args.fields[fields.iconCss]] === '') {\n args.curData[args.fields[fields.iconCss]] = null;\n }\n },\n itemCreated: function (args) {\n if (args.curData[_this.getField('separator', level)]) {\n args.item.classList.add(SEPARATOR);\n args.item.setAttribute('role', 'separator');\n }\n if (showIcon && !args.curData[args.fields.iconCss]\n && !args.curData[_this.getField('separator', level)]) {\n args.item.classList.add('e-blankicon');\n }\n if (args.curData[args.fields.child]\n && args.curData[args.fields.child].length) {\n var span = _this.createElement('span', { className: ICONS + ' ' + CARET });\n args.item.appendChild(span);\n args.item.setAttribute('aria-haspopup', 'true');\n args.item.setAttribute('aria-expanded', 'false');\n args.item.classList.add('e-menu-caret-icon');\n }\n if (_this.isMenu && _this.template) {\n args.item.setAttribute('id', args.curData[args.fields.id].toString());\n args.item.removeAttribute('data-uid');\n if (args.item.classList.contains('e-level-1')) {\n args.item.classList.remove('e-level-1');\n }\n if (args.item.classList.contains('e-has-child')) {\n args.item.classList.remove('e-has-child');\n }\n args.item.removeAttribute('aria-level');\n }\n var eventArgs = { item: args.curData, element: args.item };\n _this.trigger('beforeItemRender', eventArgs);\n }\n };\n this.setProperties({ 'items': this.items }, true);\n if (this.isMenu) {\n listBaseOptions.templateID = this.element.id + TEMPLATE_PROPERTY;\n }\n var ul = ListBase.createList(this.createElement, items, listBaseOptions, !this.template, this);\n ul.setAttribute('tabindex', '0');\n if (this.isMenu) {\n ul.setAttribute('role', 'menu');\n }\n else {\n ul.setAttribute('role', 'menubar');\n }\n return ul;\n };\n MenuBase.prototype.moverHandler = function (e) {\n var trgt = e.target;\n this.liTrgt = trgt;\n var cli = this.getLI(trgt);\n var wrapper = cli ? closest(cli, '.e-' + this.getModuleName() + '-wrapper') : this.getWrapper();\n var hdrWrapper = this.getWrapper();\n var regex = new RegExp('-ej2menu-(.*)-popup');\n var ulId;\n var isDifferentElem = false;\n if (!wrapper) {\n return;\n }\n if (wrapper.id !== '') {\n ulId = regex.exec(wrapper.id)[1];\n }\n else {\n ulId = wrapper.querySelector('ul').id;\n }\n if (ulId !== this.element.id) {\n this.removeLIStateByClass([FOCUSED, SELECTED], [this.getWrapper()]);\n if (this.navIdx.length) {\n isDifferentElem = true;\n }\n else {\n return;\n }\n }\n if (cli && closest(cli, '.e-' + this.getModuleName() + '-wrapper') && !isDifferentElem) {\n this.removeLIStateByClass([FOCUSED], this.isMenu ? [wrapper].concat(this.getPopups()) : [wrapper]);\n this.removeLIStateByClass([FOCUSED], this.isMenu ? [hdrWrapper].concat(this.getPopups()) : [hdrWrapper]);\n cli.classList.add(FOCUSED);\n if (!this.showItemOnClick) {\n this.clickHandler(e);\n }\n }\n else if (this.isMenu && this.showItemOnClick && !isDifferentElem) {\n this.removeLIStateByClass([FOCUSED], [wrapper].concat(this.getPopups()));\n }\n if (this.isMenu) {\n if (!this.showItemOnClick && (trgt.parentElement !== wrapper && !closest(trgt, '.e-' + this.getModuleName() + '-popup'))\n && (!cli || (cli && !this.getIndex(cli.id, true).length)) && this.showSubMenuOn !== 'Hover') {\n this.removeLIStateByClass([FOCUSED], [wrapper]);\n if (this.navIdx.length) {\n this.isClosed = true;\n this.closeMenu(null, e);\n }\n }\n else if (isDifferentElem && !this.showItemOnClick) {\n if (this.navIdx.length) {\n this.isClosed = true;\n this.closeMenu(null, e);\n }\n }\n if (!this.isClosed) {\n this.removeStateWrapper();\n }\n this.isClosed = false;\n }\n };\n MenuBase.prototype.removeStateWrapper = function () {\n if (this.liTrgt) {\n var wrapper = closest(this.liTrgt, '.e-menu-vscroll');\n if (this.liTrgt.tagName === 'DIV' && wrapper) {\n this.removeLIStateByClass([FOCUSED, SELECTED], [wrapper]);\n }\n }\n };\n MenuBase.prototype.removeLIStateByClass = function (classList, element) {\n var li;\n var _loop_1 = function (i) {\n classList.forEach(function (className) {\n li = select('.' + className, element[i]);\n if (li) {\n li.classList.remove(className);\n }\n });\n };\n for (var i = 0; i < element.length; i++) {\n _loop_1(i);\n }\n };\n MenuBase.prototype.getField = function (propName, level) {\n if (level === void 0) { level = 0; }\n var fieldName = this.fields[\"\" + propName];\n return typeof fieldName === 'string' ? fieldName :\n (!fieldName[level] ? fieldName[fieldName.length - 1].toString()\n : fieldName[level].toString());\n };\n MenuBase.prototype.getFields = function (level) {\n if (level === void 0) { level = 0; }\n return {\n id: this.getField('itemId', level),\n iconCss: this.getField('iconCss', level),\n text: this.getField('text', level),\n url: this.getField('url', level),\n child: this.getField('children', level),\n separator: this.getField('separator', level)\n };\n };\n MenuBase.prototype.hasField = function (items, field) {\n for (var i = 0, len = items.length; i < len; i++) {\n if (items[i][\"\" + field]) {\n return true;\n }\n }\n return false;\n };\n MenuBase.prototype.menuHeaderClickHandler = function (e) {\n if (closest(e.target, '.e-menu-wrapper').querySelector('ul.e-menu-parent').id !== this.element.id) {\n return;\n }\n if (this.element.className.indexOf('e-hide-menu') > -1) {\n this.openHamburgerMenu(e);\n }\n else {\n this.closeHamburgerMenu(e);\n }\n };\n MenuBase.prototype.clickHandler = function (e) {\n if (this.isTapHold) {\n this.isTapHold = false;\n }\n else {\n var wrapper = this.getWrapper();\n var trgt = e.target;\n var cli = this.cli = this.getLI(trgt);\n var regex = new RegExp('-ej2menu-(.*)-popup');\n var cliWrapper = cli ? closest(cli, '.e-' + this.getModuleName() + '-wrapper') : null;\n var isInstLI = cli && cliWrapper && (this.isMenu ? this.getIndex(cli.id, true).length > 0\n : wrapper.firstElementChild.id === cliWrapper.firstElementChild.id);\n if (Browser.isDevice && this.isMenu) {\n this.removeLIStateByClass([FOCUSED], [wrapper].concat(this.getPopups()));\n this.mouseDownHandler(e);\n }\n if (cli && cliWrapper && this.isMenu) {\n var cliWrapperId = cliWrapper.id ? regex.exec(cliWrapper.id)[1] : cliWrapper.querySelector('.e-menu-parent').id;\n if (this.element.id !== cliWrapperId) {\n return;\n }\n }\n if (isInstLI && e.type === 'click' && !cli.classList.contains(HEADER)) {\n this.setLISelected(cli);\n var navIdx = this.getIndex(cli.id, true);\n var item = this.getItem(navIdx);\n var eventArgs = { element: cli, item: item, event: e };\n this.trigger('select', eventArgs);\n }\n if (isInstLI && (e.type === 'mouseover' || Browser.isDevice || this.showItemOnClick)) {\n var ul = void 0;\n if (cli.classList.contains(HEADER)) {\n ul = wrapper.children[this.navIdx.length - 1];\n this.toggleAnimation(ul);\n var sli = this.getLIByClass(ul, SELECTED);\n if (sli) {\n sli.classList.remove(SELECTED);\n }\n detach(cli.parentNode);\n this.navIdx.pop();\n }\n else {\n if (!cli.classList.contains(SEPARATOR)) {\n this.showSubMenu = true;\n var cul = cli.parentNode;\n if (isNullOrUndefined(cul)) {\n return;\n }\n this.cliIdx = this.getIdx(cul, cli);\n if (this.isMenu || !Browser.isDevice) {\n var culIdx = this.isMenu ? Array.prototype.indexOf.call([wrapper].concat(this.getPopups()), closest(cul, '.' + 'e-' + this.getModuleName() + '-wrapper'))\n : this.getIdx(wrapper, cul);\n if (this.navIdx[culIdx] === this.cliIdx) {\n this.showSubMenu = false;\n }\n if (culIdx !== this.navIdx.length && (e.type !== 'mouseover' || this.showSubMenu)) {\n var sli = this.getLIByClass(cul, SELECTED);\n if (sli) {\n sli.classList.remove(SELECTED);\n }\n this.isClosed = true;\n this.keyType = 'click';\n if (this.showItemOnClick) {\n this.setLISelected(cli);\n }\n this.closeMenu(culIdx + 1, e);\n if (this.showItemOnClick) {\n this.setLISelected(cli);\n }\n }\n }\n if (!this.isClosed) {\n this.afterCloseMenu(e);\n }\n this.isClosed = false;\n }\n }\n }\n else {\n if (this.isMenu && trgt.tagName === 'DIV' && this.navIdx.length && closest(trgt, '.e-menu-vscroll')) {\n var popupEle = closest(trgt, '.' + POPUP);\n var cIdx = Array.prototype.indexOf.call(this.getPopups(), popupEle) + 1;\n if (cIdx < this.navIdx.length) {\n this.closeMenu(cIdx + 1, e);\n if (popupEle) {\n this.removeLIStateByClass([FOCUSED, SELECTED], [popupEle]);\n }\n }\n }\n else if (this.isMenu && this.hamburgerMode && trgt.tagName === 'SPAN'\n && trgt.classList.contains('e-menu-icon')) {\n this.menuHeaderClickHandler(e);\n }\n else {\n if (trgt.tagName !== 'UL' || (this.isMenu ? trgt.parentElement.classList.contains('e-menu-wrapper') &&\n !this.getIndex(trgt.querySelector('.' + ITEM).id, true).length : trgt.parentElement !== wrapper)) {\n if (!cli) {\n this.removeLIStateByClass([SELECTED], [wrapper]);\n }\n if (!cli || !cli.querySelector('.' + CARET)) {\n this.closeMenu(null, e);\n }\n }\n }\n }\n }\n };\n MenuBase.prototype.afterCloseMenu = function (e) {\n if (isNullOrUndefined(e)) {\n return;\n }\n var isHeader;\n if (this.showSubMenu) {\n if (this.showItemOnClick && this.navIdx.length === 0) {\n isHeader = closest(e.target, '.e-menu-parent.e-control');\n }\n else {\n isHeader = closest(this.element, '.e-menu-parent.e-control');\n }\n var idx = this.navIdx.concat(this.cliIdx);\n var item = this.getItem(idx);\n if (item && item[this.getField('children', idx.length - 1)] &&\n item[this.getField('children', idx.length - 1)].length) {\n if (e.type === 'mouseover' || (Browser.isDevice && this.isMenu)) {\n this.setLISelected(this.cli);\n }\n if ((!this.hamburgerMode && isHeader) || (this.hamburgerMode && this.cli.getAttribute('aria-expanded') === 'false')) {\n this.cli.setAttribute('aria-expanded', 'true');\n this.navIdx.push(this.cliIdx);\n this.openMenu(this.cli, item, null, null, e);\n }\n }\n else {\n if (e.type !== 'mouseover') {\n this.closeMenu(null, e);\n }\n }\n if (!isHeader) {\n var cul = this.getUlByNavIdx();\n var sli = this.getLIByClass(cul, SELECTED);\n if (sli) {\n sli.setAttribute('aria-expanded', 'false');\n sli.classList.remove(SELECTED);\n }\n }\n }\n this.keyType = '';\n };\n MenuBase.prototype.setLISelected = function (li) {\n var sli = this.getLIByClass(li.parentElement, SELECTED);\n if (sli) {\n sli.classList.remove(SELECTED);\n }\n if (!this.isMenu) {\n li.classList.remove(FOCUSED);\n }\n li.classList.add(SELECTED);\n };\n MenuBase.prototype.getLIByClass = function (ul, classname) {\n for (var i = 0, len = ul.children.length; i < len; i++) {\n if (ul.children[i].classList.contains(classname)) {\n return ul.children[i];\n }\n }\n return null;\n };\n /**\n * This method is used to get the index of the menu item in the Menu based on the argument.\n *\n * @param {MenuItem | string} item - item be passed to get the index | id to be passed to get the item index.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.getItemIndex = function (item, isUniqueId) {\n var idx;\n if (typeof item === 'string') {\n idx = item;\n }\n else {\n idx = item.id;\n }\n var isText = (isUniqueId === false) ? false : true;\n var navIdx = this.getIndex(idx, isText);\n return navIdx;\n };\n /**\n * This method is used to set the menu item in the Menu based on the argument.\n *\n * @param {MenuItem} item - item need to be updated.\n * @param {string} id - id / text to be passed to update the item.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.setItem = function (item, id, isUniqueId) {\n var idx;\n if (isUniqueId) {\n idx = id ? id : item.id;\n }\n else {\n idx = id ? id : item.text;\n }\n var navIdx = this.getIndex(idx, isUniqueId);\n var newItem = this.getItem(navIdx);\n Object.assign(newItem, item);\n };\n MenuBase.prototype.getItem = function (navIdx) {\n navIdx = navIdx.slice();\n var idx = navIdx.pop();\n var items = this.getItems(navIdx);\n return items[idx];\n };\n MenuBase.prototype.getItems = function (navIdx) {\n var items = this.items;\n for (var i = 0; i < navIdx.length; i++) {\n items = items[navIdx[i]][this.getField('children', i)];\n }\n return items;\n };\n MenuBase.prototype.setItems = function (newItems, navIdx) {\n var items = this.getItems(navIdx);\n items.splice(0, items.length);\n for (var i = 0; i < newItems.length; i++) {\n items.splice(i, 0, newItems[i]);\n }\n };\n MenuBase.prototype.getIdx = function (ul, li, skipHdr) {\n if (skipHdr === void 0) { skipHdr = true; }\n var idx = Array.prototype.indexOf.call(ul.children, li);\n if (skipHdr && ul.children[0].classList.contains(HEADER)) {\n idx--;\n }\n return idx;\n };\n MenuBase.prototype.getLI = function (elem) {\n if (elem.tagName === 'LI' && elem.classList.contains('e-menu-item')) {\n return elem;\n }\n return closest(elem, 'li.e-menu-item');\n };\n MenuBase.prototype.updateItemsByNavIdx = function () {\n var items = this.items;\n var count = 0;\n for (var index = 0; index < this.navIdx.length; index++) {\n items = items[index].items;\n if (!items) {\n break;\n }\n count++;\n var ul = this.getUlByNavIdx(count);\n if (!ul) {\n break;\n }\n this.updateItem(ul, items);\n }\n };\n MenuBase.prototype.removeChildElement = function (elem) {\n while (elem.firstElementChild) {\n elem.removeChild(elem.firstElementChild);\n }\n return elem;\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @private\n * @param {MenuBaseModel} newProp - Specifies the new properties\n * @param {MenuBaseModel} oldProp - Specifies the old properties\n * @returns {void}\n */\n MenuBase.prototype.onPropertyChanged = function (newProp, oldProp) {\n var _this = this;\n var wrapper = this.getWrapper();\n var _loop_2 = function (prop) {\n switch (prop) {\n case 'cssClass':\n if (oldProp.cssClass) {\n removeClass([wrapper], oldProp.cssClass.split(' '));\n }\n if (newProp.cssClass) {\n addClass([wrapper], newProp.cssClass.replace(/\\s+/g, ' ').trim().split(' '));\n }\n break;\n case 'enableRtl':\n if (this_1.enableRtl) {\n wrapper.classList.add(RTL);\n }\n else {\n wrapper.classList.remove(RTL);\n }\n break;\n case 'showItemOnClick':\n this_1.unWireEvents();\n this_1.showItemOnClick = newProp.showItemOnClick;\n this_1.wireEvents();\n break;\n case 'enableScrolling':\n if (newProp.enableScrolling) {\n var ul_2;\n if (this_1.element.classList.contains('e-vertical')) {\n addScrolling(this_1.createElement, wrapper, this_1.element, 'vscroll', this_1.enableRtl);\n }\n else {\n addScrolling(this_1.createElement, wrapper, this_1.element, 'hscroll', this_1.enableRtl);\n }\n this_1.getPopups().forEach(function (wrapper) {\n ul_2 = select('.e-ul', wrapper);\n addScrolling(_this.createElement, wrapper, ul_2, 'vscroll', _this.enableRtl);\n });\n }\n else {\n var ul_3 = wrapper.children[0];\n if (this_1.element.classList.contains('e-vertical')) {\n destroyScroll(getInstance(ul_3, VScroll), ul_3);\n }\n else {\n destroyScroll(getInstance(ul_3, HScroll), ul_3);\n }\n wrapper.style.overflow = '';\n wrapper.appendChild(this_1.element);\n this_1.getPopups().forEach(function (wrapper) {\n ul_3 = wrapper.children[0];\n destroyScroll(getInstance(ul_3, VScroll), ul_3);\n wrapper.style.overflow = '';\n });\n }\n break;\n case 'items': {\n var idx = void 0;\n var navIdx = void 0;\n var item = void 0;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (this_1.isReact && this_1.template) {\n this_1.clearTemplate(['template']);\n }\n if (!Object.keys(oldProp.items).length) {\n this_1.updateItem(this_1.element, this_1.items);\n if (this_1.enableScrolling && this_1.element.parentElement.classList.contains('e-custom-scroll')) {\n if (this_1.element.classList.contains('e-vertical')) {\n addScrolling(this_1.createElement, wrapper, this_1.element, 'vscroll', this_1.enableRtl);\n }\n else {\n addScrolling(this_1.createElement, wrapper, this_1.element, 'hscroll', this_1.enableRtl);\n }\n }\n if (!this_1.hamburgerMode) {\n for (var i = 1, count = wrapper.childElementCount; i < count; i++) {\n detach(wrapper.lastElementChild);\n }\n }\n this_1.navIdx = [];\n }\n else {\n var keys = Object.keys(newProp.items);\n for (var i = 0; i < keys.length; i++) {\n navIdx = this_1.getChangedItemIndex(newProp, [], Number(keys[i]));\n if (navIdx.length <= this_1.getWrapper().children.length) {\n idx = navIdx.pop();\n item = this_1.getItems(navIdx);\n this_1.insertAfter([item[idx]], item[idx].text);\n this_1.removeItem(item, navIdx, idx);\n this_1.setItems(item, navIdx);\n }\n navIdx.length = 0;\n }\n }\n break;\n }\n }\n };\n var this_1 = this;\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n _loop_2(prop);\n }\n };\n MenuBase.prototype.updateItem = function (ul, items) {\n if (isBlazor() && !this.isMenu) {\n ul = this.removeChildElement(ul);\n }\n else {\n if (this.enableScrolling) {\n var wrapper1 = this.getWrapper();\n var ul1 = wrapper1.children[0];\n if (this.element.classList.contains('e-vertical')) {\n destroyScroll(getInstance(ul1, VScroll), ul1);\n }\n else {\n destroyScroll(getInstance(ul1, HScroll), ul1);\n }\n }\n ul.innerHTML = '';\n }\n var lis = [].slice.call(this.createItems(items).children);\n lis.forEach(function (li) {\n ul.appendChild(li);\n });\n };\n MenuBase.prototype.getChangedItemIndex = function (newProp, index, idx) {\n index.push(idx);\n var key = Object.keys(newProp.items[idx]).pop();\n if (key === 'items') {\n var item = newProp.items[idx];\n var popStr = Object.keys(item.items).pop();\n if (popStr) {\n this.getChangedItemIndex(item, index, Number(popStr));\n }\n }\n else {\n if (key === 'isParentArray' && index.length > 1) {\n index.pop();\n }\n }\n return index;\n };\n MenuBase.prototype.removeItem = function (item, navIdx, idx) {\n item.splice(idx, 1);\n var uls = this.getWrapper().children;\n if (navIdx.length < uls.length) {\n detach(uls[navIdx.length].children[idx]);\n }\n };\n /**\n * Used to unwire the bind events.\n *\n * @private\n * @param {string} targetSelctor - Specifies the target selector\n * @returns {void}\n */\n MenuBase.prototype.unWireEvents = function (targetSelctor) {\n if (targetSelctor === void 0) { targetSelctor = this.target; }\n var wrapper = this.getWrapper();\n if (targetSelctor) {\n var target = void 0;\n var touchModule = void 0;\n var targetElems = selectAll(targetSelctor);\n for (var i = 0, len = targetElems.length; i < len; i++) {\n target = targetElems[i];\n if (this.isMenu) {\n EventHandler.remove(target, 'click', this.menuHeaderClickHandler);\n }\n else {\n if (Browser.isIos) {\n touchModule = getInstance(target, Touch);\n if (touchModule) {\n touchModule.destroy();\n }\n }\n else {\n EventHandler.remove(target, 'contextmenu', this.cmenuHandler);\n }\n }\n }\n if (!this.isMenu) {\n EventHandler.remove(this.targetElement, 'mousewheel DOMMouseScroll', this.scrollHandler);\n for (var _i = 0, _a = getScrollableParent(this.targetElement); _i < _a.length; _i++) {\n var parent_2 = _a[_i];\n EventHandler.remove(parent_2, 'mousewheel DOMMouseScroll', this.scrollHandler);\n }\n }\n }\n if (!Browser.isDevice) {\n EventHandler.remove(this.isMenu ? document : wrapper, 'mouseover', this.delegateMoverHandler);\n EventHandler.remove(document, 'mousedown', this.delegateMouseDownHandler);\n }\n EventHandler.remove(document, 'click', this.delegateClickHandler);\n this.unWireKeyboardEvent(wrapper);\n this.rippleFn();\n };\n MenuBase.prototype.unWireKeyboardEvent = function (element) {\n var keyboardModule = getInstance(element, KeyboardEvents);\n if (keyboardModule) {\n keyboardModule.destroy();\n }\n };\n MenuBase.prototype.toggleAnimation = function (ul, isMenuOpen) {\n var _this = this;\n if (isMenuOpen === void 0) { isMenuOpen = true; }\n var pUlHeight;\n var pElement;\n if (this.animationSettings.effect === 'None' || !isMenuOpen) {\n this.end(ul, isMenuOpen);\n }\n else {\n this.animation.animate(ul, {\n name: this.animationSettings.effect,\n duration: this.animationSettings.duration,\n timingFunction: this.animationSettings.easing,\n begin: function (options) {\n if (_this.hamburgerMode) {\n pElement = options.element.parentElement;\n options.element.style.position = 'absolute';\n pUlHeight = pElement.offsetHeight;\n options.element.style.maxHeight = options.element.offsetHeight + 'px';\n pElement.style.maxHeight = '';\n }\n else {\n options.element.style.display = 'block';\n options.element.style.maxHeight = options.element.getBoundingClientRect().height + 'px';\n }\n },\n progress: function (options) {\n if (_this.hamburgerMode) {\n pElement.style.minHeight = (pUlHeight + options.element.offsetHeight) + 'px';\n }\n },\n end: function (options) {\n if (_this.hamburgerMode) {\n options.element.style.position = '';\n options.element.style.maxHeight = '';\n pElement.style.minHeight = '';\n options.element.style.top = 0 + 'px';\n options.element.children[0].focus();\n _this.triggerOpen(options.element.children[0]);\n }\n else {\n _this.end(options.element, isMenuOpen);\n }\n }\n });\n }\n };\n MenuBase.prototype.triggerOpen = function (ul) {\n var item = this.navIdx.length ? this.getItem(this.navIdx) : null;\n var eventArgs = {\n element: ul, parentItem: item, items: item ? item.items : this.items\n };\n this.trigger('onOpen', eventArgs);\n if (!this.isMenu) {\n EventHandler.add(ul, 'keydown', this.keyHandler, this);\n }\n };\n MenuBase.prototype.end = function (ul, isMenuOpen) {\n if (isMenuOpen) {\n ul.style.display = 'block';\n ul.style.maxHeight = '';\n this.triggerOpen(ul);\n if (ul.querySelector('.' + FOCUSED)) {\n ul.querySelector('.' + FOCUSED).focus();\n }\n else {\n var ele = this.getWrapper().children[this.getIdx(this.getWrapper(), ul) - 1];\n if (this.currentTarget) {\n if (!(this.currentTarget.classList.contains('e-numerictextbox') || this.currentTarget.classList.contains('e-textbox') || this.currentTarget.tagName === 'INPUT')) {\n if (ele) {\n ele.querySelector('.' + SELECTED).focus();\n }\n else {\n this.element.focus();\n }\n }\n }\n else {\n if (ele) {\n ele.querySelector('.' + SELECTED).focus();\n }\n else {\n this.element.focus();\n }\n }\n }\n }\n else {\n if (ul === this.element) {\n var fli = this.getLIByClass(this.element, FOCUSED);\n if (fli) {\n fli.classList.remove(FOCUSED);\n }\n var sli = this.getLIByClass(this.element, SELECTED);\n if (sli) {\n sli.classList.remove(SELECTED);\n }\n ul.style.display = 'none';\n }\n else {\n detach(ul);\n }\n }\n };\n /**\n * Get the properties to be maintained in the persisted state.\n *\n * @returns {string} - Persist data\n */\n MenuBase.prototype.getPersistData = function () {\n return '';\n };\n /**\n * Get wrapper element.\n *\n * @returns {Element} - Wrapper element\n * @private\n */\n MenuBase.prototype.getWrapper = function () {\n return closest(this.element, '.e-' + this.getModuleName() + '-wrapper');\n };\n MenuBase.prototype.getIndex = function (data, isUniqueId, items, nIndex, isCallBack, level) {\n if (items === void 0) { items = this.items; }\n if (nIndex === void 0) { nIndex = []; }\n if (isCallBack === void 0) { isCallBack = false; }\n if (level === void 0) { level = 0; }\n var item;\n level = isCallBack ? level + 1 : 0;\n for (var i = 0, len = items.length; i < len; i++) {\n item = items[i];\n if ((isUniqueId ? item[this.getField('itemId', level)] : item[this.getField('text', level)]) === data) {\n nIndex.push(i);\n break;\n }\n else if (item[this.getField('children', level)]\n && item[this.getField('children', level)].length) {\n nIndex = this.getIndex(data, isUniqueId, item[this.getField('children', level)], nIndex, true, level);\n if (nIndex[nIndex.length - 1] === -1) {\n if (i !== len - 1) {\n nIndex.pop();\n }\n }\n else {\n nIndex.unshift(i);\n break;\n }\n }\n else {\n if (i === len - 1) {\n nIndex.push(-1);\n }\n }\n }\n return (!isCallBack && nIndex[0] === -1) ? [] : nIndex;\n };\n /**\n * This method is used to enable or disable the menu items in the Menu based on the items and enable argument.\n *\n * @param {string[]} items - Text items that needs to be enabled/disabled.\n * @param {boolean} enable - Set `true`/`false` to enable/disable the list items.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.enableItems = function (items, enable, isUniqueId) {\n if (enable === void 0) { enable = true; }\n var ul;\n var idx;\n var navIdx;\n var disabled = DISABLED;\n var skipItem;\n for (var i = 0; i < items.length; i++) {\n navIdx = this.getIndex(items[i], isUniqueId);\n if (this.navIdx.length) {\n if (navIdx.length !== 1) {\n skipItem = false;\n for (var i_1 = 0, len = navIdx.length - 1; i_1 < len; i_1++) {\n if (navIdx[i_1] !== this.navIdx[i_1]) {\n skipItem = true;\n break;\n }\n }\n if (skipItem) {\n continue;\n }\n }\n }\n else {\n if (navIdx.length !== 1) {\n continue;\n }\n }\n idx = navIdx.pop();\n ul = this.getUlByNavIdx(navIdx.length);\n if (ul && !isNullOrUndefined(idx)) {\n if (enable) {\n if (this.isMenu) {\n ul.children[idx].classList.remove(disabled);\n ul.children[idx].removeAttribute('aria-disabled');\n }\n else {\n if (Browser.isDevice && !ul.classList.contains('e-contextmenu')) {\n ul.children[idx + 1].classList.remove(disabled);\n }\n else {\n ul.children[idx].classList.remove(disabled);\n }\n }\n }\n else {\n if (this.isMenu) {\n ul.children[idx].classList.add(disabled);\n ul.children[idx].setAttribute('aria-disabled', 'true');\n }\n else {\n if (Browser.isDevice && !ul.classList.contains('e-contextmenu')) {\n ul.children[idx + 1].classList.add(disabled);\n }\n else {\n ul.children[idx].classList.add(disabled);\n }\n }\n }\n }\n }\n };\n /**\n * This method is used to show the menu items in the Menu based on the items text.\n *\n * @param {string[]} items - Text items that needs to be shown.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.showItems = function (items, isUniqueId) {\n this.showHideItems(items, false, isUniqueId);\n };\n /**\n * This method is used to hide the menu items in the Menu based on the items text.\n *\n * @param {string[]} items - Text items that needs to be hidden.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.hideItems = function (items, isUniqueId) {\n this.showHideItems(items, true, isUniqueId);\n };\n MenuBase.prototype.showHideItems = function (items, ishide, isUniqueId) {\n var ul;\n var index;\n var navIdx;\n var item;\n for (var i = 0; i < items.length; i++) {\n navIdx = this.getIndex(items[i], isUniqueId);\n index = navIdx.pop();\n ul = this.getUlByNavIdx(navIdx.length);\n item = this.getItems(navIdx);\n if (ul) {\n var validUl = isUniqueId ? ul.children[index].id : item[index].text.toString();\n if (ishide && validUl === items[i]) {\n ul.children[index].classList.add(HIDE);\n }\n else if (!ishide && validUl === items[i]) {\n ul.children[index].classList.remove(HIDE);\n }\n }\n }\n };\n /**\n * It is used to remove the menu items from the Menu based on the items text.\n *\n * @param {string[]} items Text items that needs to be removed.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.removeItems = function (items, isUniqueId) {\n var idx;\n var navIdx;\n var iitems;\n for (var i = 0; i < items.length; i++) {\n navIdx = this.getIndex(items[i], isUniqueId);\n idx = navIdx.pop();\n iitems = this.getItems(navIdx);\n if (!isNullOrUndefined(idx)) {\n this.removeItem(iitems, navIdx, idx);\n }\n }\n };\n /**\n * It is used to insert the menu items after the specified menu item text.\n *\n * @param {MenuItemModel[]} items - Items that needs to be inserted.\n * @param {string} text - Text item after that the element to be inserted.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.insertAfter = function (items, text, isUniqueId) {\n this.insertItems(items, text, isUniqueId);\n };\n /**\n * It is used to insert the menu items before the specified menu item text.\n *\n * @param {MenuItemModel[]} items - Items that needs to be inserted.\n * @param {string} text - Text item before that the element to be inserted.\n * @param {boolean} isUniqueId - Set `true` if it is a unique id.\n * @returns {void}\n */\n MenuBase.prototype.insertBefore = function (items, text, isUniqueId) {\n this.insertItems(items, text, isUniqueId, false);\n };\n MenuBase.prototype.insertItems = function (items, text, isUniqueId, isAfter) {\n if (isAfter === void 0) { isAfter = true; }\n var li;\n var idx;\n var navIdx;\n var iitems;\n var menuitem;\n for (var i = 0; i < items.length; i++) {\n navIdx = this.getIndex(text, isUniqueId);\n idx = navIdx.pop();\n iitems = this.getItems(navIdx);\n menuitem = new MenuItem(iitems[0], 'items', items[i], true);\n iitems.splice(isAfter ? idx + 1 : idx, 0, menuitem);\n var uls = this.isMenu ? [this.getWrapper()].concat(this.getPopups()) : [].slice.call(this.getWrapper().children);\n if (!isNullOrUndefined(idx) && navIdx.length < uls.length) {\n idx = isAfter ? idx + 1 : idx;\n li = this.createItems(iitems).children[idx];\n var ul = this.isMenu ? select('.e-menu-parent', uls[navIdx.length]) : uls[navIdx.length];\n ul.insertBefore(li, ul.children[idx]);\n }\n }\n };\n MenuBase.prototype.removeAttributes = function () {\n var _this = this;\n ['top', 'left', 'display', 'z-index'].forEach(function (key) {\n _this.element.style.removeProperty(key);\n });\n ['role', 'tabindex', 'class', 'style'].forEach(function (key) {\n if (key === 'class' && _this.element.classList.contains('e-menu-parent')) {\n _this.element.classList.remove('e-menu-parent');\n }\n if (['class', 'style'].indexOf(key) === -1 || !_this.element.getAttribute(key)) {\n _this.element.removeAttribute(key);\n }\n if (_this.isMenu && key === 'class' && _this.element.classList.contains('e-vertical')) {\n _this.element.classList.remove('e-vertical');\n }\n });\n };\n /**\n * Destroys the widget.\n *\n * @returns {void}\n */\n MenuBase.prototype.destroy = function () {\n var wrapper = this.getWrapper();\n if (wrapper) {\n this.unWireEvents();\n if (!this.isMenu) {\n this.clonedElement.style.display = '';\n if (this.clonedElement.tagName === 'EJS-CONTEXTMENU') {\n addClass([this.clonedElement], ['e-control', 'e-lib', 'e-' + this.getModuleName()]);\n this.element = this.clonedElement;\n }\n else {\n if (this.refreshing && this.clonedElement.childElementCount && this.clonedElement.children[0].tagName === 'LI') {\n this.setProperties({ 'items': [] }, true);\n }\n if (document.getElementById(this.clonedElement.id)) {\n var refEle = this.clonedElement.nextElementSibling;\n if (refEle && refEle !== wrapper) {\n this.clonedElement.parentElement.insertBefore(this.element, refEle);\n }\n else {\n this.clonedElement.parentElement.appendChild(this.element);\n }\n if (isBlazor() && !this.isMenu) {\n this.element = this.removeChildElement(this.element);\n }\n else {\n this.element.innerHTML = '';\n }\n append([].slice.call(this.clonedElement.children), this.element);\n detach(this.clonedElement);\n this.removeAttributes();\n }\n }\n this.clonedElement = null;\n }\n else {\n this.closeMenu();\n if (isBlazor() && !this.isMenu) {\n this.element = this.removeChildElement(this.element);\n }\n else {\n this.element.innerHTML = '';\n }\n this.removeAttributes();\n wrapper.parentNode.insertBefore(this.element, wrapper);\n this.clonedElement = null;\n }\n if (this.isMenu && this.clonedElement) {\n detach(this.element);\n wrapper.style.display = '';\n wrapper.classList.remove('e-' + this.getModuleName() + '-wrapper');\n wrapper.removeAttribute('data-ripple');\n }\n else {\n detach(wrapper);\n }\n _super.prototype.destroy.call(this);\n if (this.template) {\n this.clearTemplate(['template']);\n }\n }\n this.rippleFn = null;\n };\n __decorate([\n Event()\n ], MenuBase.prototype, \"beforeItemRender\", void 0);\n __decorate([\n Event()\n ], MenuBase.prototype, \"beforeOpen\", void 0);\n __decorate([\n Event()\n ], MenuBase.prototype, \"onOpen\", void 0);\n __decorate([\n Event()\n ], MenuBase.prototype, \"beforeClose\", void 0);\n __decorate([\n Event()\n ], MenuBase.prototype, \"onClose\", void 0);\n __decorate([\n Event()\n ], MenuBase.prototype, \"select\", void 0);\n __decorate([\n Event()\n ], MenuBase.prototype, \"created\", void 0);\n __decorate([\n Property('')\n ], MenuBase.prototype, \"cssClass\", void 0);\n __decorate([\n Property(0)\n ], MenuBase.prototype, \"hoverDelay\", void 0);\n __decorate([\n Property(false)\n ], MenuBase.prototype, \"showItemOnClick\", void 0);\n __decorate([\n Property('')\n ], MenuBase.prototype, \"target\", void 0);\n __decorate([\n Property('')\n ], MenuBase.prototype, \"filter\", void 0);\n __decorate([\n Property(null)\n ], MenuBase.prototype, \"template\", void 0);\n __decorate([\n Property(false)\n ], MenuBase.prototype, \"enableScrolling\", void 0);\n __decorate([\n Property(false)\n ], MenuBase.prototype, \"enableHtmlSanitizer\", void 0);\n __decorate([\n Complex({ itemId: 'id', text: 'text', parentId: 'parentId', iconCss: 'iconCss', url: 'url', separator: 'separator', children: 'items' }, FieldSettings)\n ], MenuBase.prototype, \"fields\", void 0);\n __decorate([\n Collection([], MenuItem)\n ], MenuBase.prototype, \"items\", void 0);\n __decorate([\n Complex({ duration: 400, easing: 'ease', effect: 'SlideDown' }, MenuAnimationSettings)\n ], MenuBase.prototype, \"animationSettings\", void 0);\n MenuBase = __decorate([\n NotifyPropertyChanges\n ], MenuBase);\n return MenuBase;\n}(Component));\nexport { MenuBase };\n","//! moment.js locale configuration\n//! locale : English (Singapore) [en-sg]\n//! author : Matthew Castrillon-Madrigal : https://github.com/techdimension\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enSg = moment.defineLocale('en-sg', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return enSg;\n\n})));\n","//! moment.js locale configuration\n//! locale : Nynorsk [nn]\n//! authors : https://github.com/mechuwind\n//! Stephen Ramthun : https://github.com/stephenramthun\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var nn = moment.defineLocale('nn', {\n months: 'januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember'.split(\n '_'\n ),\n monthsShort:\n 'jan._feb._mars_apr._mai_juni_juli_aug._sep._okt._nov._des.'.split('_'),\n monthsParseExact: true,\n weekdays: 'sundag_mÃ¥ndag_tysdag_onsdag_torsdag_fredag_laurdag'.split('_'),\n weekdaysShort: 'su._mÃ¥._ty._on._to._fr._lau.'.split('_'),\n weekdaysMin: 'su_mÃ¥_ty_on_to_fr_la'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY [kl.] H:mm',\n LLLL: 'dddd D. MMMM YYYY [kl.] HH:mm',\n },\n calendar: {\n sameDay: '[I dag klokka] LT',\n nextDay: '[I morgon klokka] LT',\n nextWeek: 'dddd [klokka] LT',\n lastDay: '[I gÃ¥r klokka] LT',\n lastWeek: '[FøregÃ¥ande] dddd [klokka] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'om %s',\n past: '%s sidan',\n s: 'nokre sekund',\n ss: '%d sekund',\n m: 'eit minutt',\n mm: '%d minutt',\n h: 'ein time',\n hh: '%d timar',\n d: 'ein dag',\n dd: '%d dagar',\n w: 'ei veke',\n ww: '%d veker',\n M: 'ein mÃ¥nad',\n MM: '%d mÃ¥nader',\n y: 'eit Ã¥r',\n yy: '%d Ã¥r',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return nn;\n\n})));\n","//! moment.js locale configuration\n//! locale : Latvian [lv]\n//! author : Kristaps Karlsons : https://github.com/skakri\n//! author : JÄnis Elmeris : https://github.com/JanisE\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var units = {\n ss: 'sekundes_sekundÄ“m_sekunde_sekundes'.split('_'),\n m: 'minÅ«tes_minÅ«tÄ“m_minÅ«te_minÅ«tes'.split('_'),\n mm: 'minÅ«tes_minÅ«tÄ“m_minÅ«te_minÅ«tes'.split('_'),\n h: 'stundas_stundÄm_stunda_stundas'.split('_'),\n hh: 'stundas_stundÄm_stunda_stundas'.split('_'),\n d: 'dienas_dienÄm_diena_dienas'.split('_'),\n dd: 'dienas_dienÄm_diena_dienas'.split('_'),\n M: 'mÄ“neÅ¡a_mÄ“neÅ¡iem_mÄ“nesis_mÄ“neÅ¡i'.split('_'),\n MM: 'mÄ“neÅ¡a_mÄ“neÅ¡iem_mÄ“nesis_mÄ“neÅ¡i'.split('_'),\n y: 'gada_gadiem_gads_gadi'.split('_'),\n yy: 'gada_gadiem_gads_gadi'.split('_'),\n };\n /**\n * @param withoutSuffix boolean true = a length of time; false = before/after a period of time.\n */\n function format(forms, number, withoutSuffix) {\n if (withoutSuffix) {\n // E.g. \"21 minÅ«te\", \"3 minÅ«tes\".\n return number % 10 === 1 && number % 100 !== 11 ? forms[2] : forms[3];\n } else {\n // E.g. \"21 minÅ«tes\" as in \"pÄ“c 21 minÅ«tes\".\n // E.g. \"3 minÅ«tÄ“m\" as in \"pÄ“c 3 minÅ«tÄ“m\".\n return number % 10 === 1 && number % 100 !== 11 ? forms[0] : forms[1];\n }\n }\n function relativeTimeWithPlural(number, withoutSuffix, key) {\n return number + ' ' + format(units[key], number, withoutSuffix);\n }\n function relativeTimeWithSingular(number, withoutSuffix, key) {\n return format(units[key], number, withoutSuffix);\n }\n function relativeSeconds(number, withoutSuffix) {\n return withoutSuffix ? 'dažas sekundes' : 'dažÄm sekundÄ“m';\n }\n\n var lv = moment.defineLocale('lv', {\n months: 'janvÄris_februÄris_marts_aprÄ«lis_maijs_jÅ«nijs_jÅ«lijs_augusts_septembris_oktobris_novembris_decembris'.split(\n '_'\n ),\n monthsShort: 'jan_feb_mar_apr_mai_jÅ«n_jÅ«l_aug_sep_okt_nov_dec'.split('_'),\n weekdays:\n 'svÄ“tdiena_pirmdiena_otrdiena_treÅ¡diena_ceturtdiena_piektdiena_sestdiena'.split(\n '_'\n ),\n weekdaysShort: 'Sv_P_O_T_C_Pk_S'.split('_'),\n weekdaysMin: 'Sv_P_O_T_C_Pk_S'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY.',\n LL: 'YYYY. [gada] D. MMMM',\n LLL: 'YYYY. [gada] D. MMMM, HH:mm',\n LLLL: 'YYYY. [gada] D. MMMM, dddd, HH:mm',\n },\n calendar: {\n sameDay: '[Å odien pulksten] LT',\n nextDay: '[RÄ«t pulksten] LT',\n nextWeek: 'dddd [pulksten] LT',\n lastDay: '[Vakar pulksten] LT',\n lastWeek: '[PagÄjuÅ¡Ä] dddd [pulksten] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'pÄ“c %s',\n past: 'pirms %s',\n s: relativeSeconds,\n ss: relativeTimeWithPlural,\n m: relativeTimeWithSingular,\n mm: relativeTimeWithPlural,\n h: relativeTimeWithSingular,\n hh: relativeTimeWithPlural,\n d: relativeTimeWithSingular,\n dd: relativeTimeWithPlural,\n M: relativeTimeWithSingular,\n MM: relativeTimeWithPlural,\n y: relativeTimeWithSingular,\n yy: relativeTimeWithPlural,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return lv;\n\n})));\n","//! moment.js locale configuration\n//! locale : German (Switzerland) [de-ch]\n//! author : sschueller : https://github.com/sschueller\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n m: ['eine Minute', 'einer Minute'],\n h: ['eine Stunde', 'einer Stunde'],\n d: ['ein Tag', 'einem Tag'],\n dd: [number + ' Tage', number + ' Tagen'],\n w: ['eine Woche', 'einer Woche'],\n M: ['ein Monat', 'einem Monat'],\n MM: [number + ' Monate', number + ' Monaten'],\n y: ['ein Jahr', 'einem Jahr'],\n yy: [number + ' Jahre', number + ' Jahren'],\n };\n return withoutSuffix ? format[key][0] : format[key][1];\n }\n\n var deCh = moment.defineLocale('de-ch', {\n months: 'Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember'.split(\n '_'\n ),\n monthsShort:\n 'Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.'.split('_'),\n monthsParseExact: true,\n weekdays:\n 'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split(\n '_'\n ),\n weekdaysShort: 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),\n weekdaysMin: 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY HH:mm',\n LLLL: 'dddd, D. MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[heute um] LT [Uhr]',\n sameElse: 'L',\n nextDay: '[morgen um] LT [Uhr]',\n nextWeek: 'dddd [um] LT [Uhr]',\n lastDay: '[gestern um] LT [Uhr]',\n lastWeek: '[letzten] dddd [um] LT [Uhr]',\n },\n relativeTime: {\n future: 'in %s',\n past: 'vor %s',\n s: 'ein paar Sekunden',\n ss: '%d Sekunden',\n m: processRelativeTime,\n mm: '%d Minuten',\n h: processRelativeTime,\n hh: '%d Stunden',\n d: processRelativeTime,\n dd: processRelativeTime,\n w: processRelativeTime,\n ww: '%d Wochen',\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return deCh;\n\n})));\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var StackedColumnsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-stacked-columns';\n }\n }\n});\nexport var StackedColumnsPlugin = {\n name: 'e-stacked-columns',\n install: function (Vue) {\n Vue.component(StackedColumnsPlugin.name, StackedColumnsDirective);\n }\n};\nexport var StackedColumnDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-stacked-column';\n }\n }\n});\nexport var StackedColumnPlugin = {\n name: 'e-stacked-column',\n install: function (Vue) {\n Vue.component(StackedColumnPlugin.name, StackedColumnDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var ColumnsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-columns';\n }\n }\n});\nexport var ColumnsPlugin = {\n name: 'e-columns',\n install: function (Vue) {\n Vue.component(ColumnsPlugin.name, ColumnsDirective);\n }\n};\n/**\n * `e-column` directive represent a column of the VueJS Grid.\n * It must be contained in a Grid component(`ejs-grid`).\n * ```vue\n * <ejs-grid :dataSource='data' allowPaging='true' allowSorting='true'>\n * <e-columns>\n * <e-column field='ID' width='100'/>\n * <e-column field='name' headerText='Name' width='100'/>\n * </e-columns>\n * </ejs-grid>\n * ```\n */\nexport var ColumnDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-column';\n }\n }\n});\nexport var ColumnPlugin = {\n name: 'e-column',\n install: function (Vue) {\n Vue.component(ColumnPlugin.name, ColumnDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var AggregateColumnsDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-columns';\n }\n }\n});\nexport var AggregateColumnsPlugin = {\n name: 'e-columns',\n install: function (Vue) {\n Vue.component(AggregateColumnsPlugin.name, AggregateColumnsDirective);\n }\n};\n/**\n * `e-aggregate->e-column` directive represent a aggregate column of the VueJS Grid.\n * ```vue\n * <ejs-grid :dataSource='data' allowPaging='true' allowSorting='true'>\n * <e-columns>\n * <e-column field='ID' width='100'/>\n * <e-column field='name' headerText='Name' width='100'/>\n * </e-columns>\n * <e-aggregates>\n * <e-aggregate>\n * <e-columns>\n * <e-column field='ID' type='Min'/>\n * </e-columns>\n * </e-aggregate>\n * </e-aggregates>\n * </ejs-grid>\n * ```\n */\nexport var AggregateColumnDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-column';\n }\n }\n});\nexport var AggregateColumnPlugin = {\n name: 'e-column',\n install: function (Vue) {\n Vue.component(AggregateColumnPlugin.name, AggregateColumnDirective);\n }\n};\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var AggregatesDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-aggregates';\n }\n }\n});\nexport var AggregatesPlugin = {\n name: 'e-aggregates',\n install: function (Vue) {\n Vue.component(AggregatesPlugin.name, AggregatesDirective);\n }\n};\n/**\n * `e-aggregate` directive represent a aggregate row of the VueJS Grid.\n * It must be contained in a Grid component(`ejs-grid`).\n * ```vue\n * <ejs-grid :dataSource]='data' allowPaging='true' allowSorting='true'>\n * <e-columns>\n * <e-column field='ID' width='100'/>\n * <e-column field='name' headerText='Name' width='100'/>\n * </e-columns>\n * <e-aggregates>\n * <e-aggregate>\n * <e-columns>\n * <e-column field='ID' type='Min'/>\n * </e-columns>\n * </e-aggregate>\n * </e-aggregates>\n * </ejs-grid>\n * ```\n */\nexport var AggregateDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-aggregate';\n }\n }\n});\nexport var AggregatePlugin = {\n name: 'e-aggregate',\n install: function (Vue) {\n Vue.component(AggregatePlugin.name, AggregateDirective);\n }\n};\n","import { ComponentBase, gh, getProps, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined, getValue } from '@syncfusion/ej2-base';\nimport { isUndefined } from '@syncfusion/ej2-base';\nimport { Grid } from '@syncfusion/ej2-grids';\nimport { StackedColumnsDirective, StackedColumnDirective, StackedColumnsPlugin, StackedColumnPlugin } from './stacked-column.directive';\nimport { ColumnsDirective, ColumnDirective, ColumnsPlugin, ColumnPlugin } from './columns.directive';\nimport { AggregateColumnsDirective, AggregateColumnDirective, AggregateColumnsPlugin, AggregateColumnPlugin } from './aggregate-columns.directive';\nimport { AggregatesDirective, AggregateDirective, AggregatesPlugin, AggregatePlugin } from './aggregates.directive';\nexport var properties = ['isLazyUpdate', 'plugins', 'aggregates', 'allowExcelExport', 'allowFiltering', 'allowGrouping', 'allowKeyboard', 'allowMultiSorting', 'allowPaging', 'allowPdfExport', 'allowReordering', 'allowResizing', 'allowRowDragAndDrop', 'allowSelection', 'allowSorting', 'allowTextWrap', 'autoFit', 'childGrid', 'clipMode', 'columnChooserSettings', 'columnMenuItems', 'columnQueryMode', 'columns', 'contextMenuItems', 'cssClass', 'currencyCode', 'currentAction', 'currentViewData', 'dataSource', 'detailTemplate', 'editSettings', 'ej2StatePersistenceVersion', 'emptyRecordTemplate', 'enableAdaptiveUI', 'enableAltRow', 'enableAutoFill', 'enableColumnVirtualization', 'enableHeaderFocus', 'enableHover', 'enableHtmlSanitizer', 'enableImmutableMode', 'enableInfiniteScrolling', 'enablePersistence', 'enableRtl', 'enableStickyHeader', 'enableVirtualMaskRow', 'enableVirtualization', 'exportGrids', 'filterSettings', 'frozenColumns', 'frozenRows', 'gridLines', 'groupSettings', 'height', 'hierarchyPrintMode', 'infiniteScrollSettings', 'loadingIndicator', 'locale', 'pageSettings', 'pagerTemplate', 'parentDetails', 'printMode', 'query', 'queryString', 'resizeSettings', 'rowDropSettings', 'rowHeight', 'rowRenderingMode', 'rowTemplate', 'searchSettings', 'selectedRowIndex', 'selectionSettings', 'showColumnChooser', 'showColumnMenu', 'showHider', 'sortSettings', 'textWrapSettings', 'toolbar', 'toolbarTemplate', 'width', 'actionBegin', 'actionComplete', 'actionFailure', 'batchAdd', 'batchCancel', 'batchDelete', 'beforeAutoFill', 'beforeBatchAdd', 'beforeBatchDelete', 'beforeBatchSave', 'beforeCopy', 'beforeDataBound', 'beforeExcelExport', 'beforeOpenAdaptiveDialog', 'beforeOpenColumnChooser', 'beforePaste', 'beforePdfExport', 'beforePrint', 'beginEdit', 'cellDeselected', 'cellDeselecting', 'cellEdit', 'cellSave', 'cellSaved', 'cellSelected', 'cellSelecting', 'checkBoxChange', 'columnDataStateChange', 'columnDeselected', 'columnDeselecting', 'columnDrag', 'columnDragStart', 'columnDrop', 'columnMenuClick', 'columnMenuOpen', 'columnSelected', 'columnSelecting', 'commandClick', 'contextMenuClick', 'contextMenuOpen', 'created', 'dataBound', 'dataSourceChanged', 'dataStateChange', 'destroyed', 'detailDataBound', 'excelAggregateQueryCellInfo', 'excelExportComplete', 'excelHeaderQueryCellInfo', 'excelQueryCellInfo', 'exportDetailDataBound', 'exportDetailTemplate', 'exportGroupCaption', 'headerCellInfo', 'keyPressed', 'lazyLoadGroupCollapse', 'lazyLoadGroupExpand', 'load', 'pdfAggregateQueryCellInfo', 'pdfExportComplete', 'pdfHeaderQueryCellInfo', 'pdfQueryCellInfo', 'printComplete', 'queryCellInfo', 'recordClick', 'recordDoubleClick', 'resizeStart', 'resizeStop', 'resizing', 'rowDataBound', 'rowDeselected', 'rowDeselecting', 'rowDrag', 'rowDragStart', 'rowDragStartHelper', 'rowDrop', 'rowSelected', 'rowSelecting', 'toolbarClick'];\nexport var modelProps = ['dataSource'];\nexport var testProp = getProps({ props: properties });\nexport var props = testProp[0], watch = testProp[1], emitProbs = Object.keys(watch);\nemitProbs.push('modelchanged', 'update:modelValue');\nfor (var _i = 0, modelProps_1 = modelProps; _i < modelProps_1.length; _i++) {\n var props_1 = modelProps_1[_i];\n emitProbs.push('update:' + props_1);\n}\n/**\n * `ejs-grid` represents the VueJS Grid Component.\n * ```vue\n * <ejs-grid :dataSource='data' allowPaging='true' allowSorting='true'></ejs-grid>\n * ```\n */\nexport var GridComponent = vueDefineComponent({\n name: 'GridComponent',\n mixins: [ComponentBase],\n props: props,\n watch: watch,\n emits: emitProbs,\n model: { event: 'modelchanged' },\n provide: function () { return { custom: this.custom }; },\n data: function () {\n return {\n ej2Instances: new Grid({}),\n propKeys: properties,\n models: modelProps,\n hasChildDirective: true,\n hasInjectedModules: true,\n tagMapper: { \"e-columns\": { \"e-column\": { \"e-stacked-columns\": \"e-stacked-column\" } }, \"e-aggregates\": { \"e-aggregate\": { \"e-columns\": \"e-column\" } } },\n tagNameMapper: { \"e-stacked-columns\": \"e-columns\" },\n isVue3: !isExecute,\n templateCollection: {},\n };\n },\n created: function () {\n this.ej2Instances._trigger = this.ej2Instances.trigger;\n this.ej2Instances.trigger = this.trigger;\n this.bindProperties();\n this.ej2Instances._setProperties = this.ej2Instances.setProperties;\n this.ej2Instances.setProperties = this.setProperties;\n this.ej2Instances.clearTemplate = this.clearTemplate;\n this.updated = this.updated;\n },\n render: function (createElement) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', slots);\n },\n methods: {\n clearTemplate: function (templateNames) {\n if (!templateNames) {\n templateNames = Object.keys(this.templateCollection || {});\n }\n if (templateNames.length && this.templateCollection) {\n for (var _i = 0, templateNames_1 = templateNames; _i < templateNames_1.length; _i++) {\n var tempName = templateNames_1[_i];\n var elementCollection = this.templateCollection[tempName];\n if (elementCollection && elementCollection.length) {\n for (var _a = 0, elementCollection_1 = elementCollection; _a < elementCollection_1.length; _a++) {\n var ele = elementCollection_1[_a];\n var destroy = getValue('__vue__.$destroy', ele);\n if (destroy) {\n ele.__vue__.$destroy();\n }\n if (ele.innerHTML) {\n ele.innerHTML = '';\n }\n }\n delete this.templateCollection[tempName];\n }\n }\n }\n },\n setProperties: function (prop, muteOnChange) {\n var _this = this;\n if (this.isVue3) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if (this.ej2Instances && this.ej2Instances._setProperties) {\n this.ej2Instances._setProperties(prop, muteOnChange);\n }\n if (prop && this.models && this.models.length) {\n Object.keys(prop).map(function (key) {\n _this.models.map(function (model) {\n if ((key === model) && !(/datasource/i.test(key))) {\n if (_this.isVue3) {\n _this.ej2Instances.vueInstance.$emit('update:' + key, prop[key]);\n }\n else {\n _this.$emit('update:' + key, prop[key]);\n _this.$emit('modelchanged', prop[key]);\n }\n }\n });\n });\n }\n },\n trigger: function (eventName, eventProp, successHandler) {\n if (!isExecute) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if ((eventName === 'change' || eventName === 'input') && this.models && (this.models.length !== 0)) {\n var key = this.models.toString().match(/checked|value/) || [];\n var propKey = key[0];\n if (eventProp && key && !isUndefined(eventProp[propKey])) {\n if (!isExecute) {\n this.ej2Instances.vueInstance.$emit('update:' + propKey, eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('modelchanged', eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('update:modelValue', eventProp[propKey]);\n }\n else {\n if (eventName === 'change' || (this.$props && !this.$props.isLazyUpdate)) {\n this.$emit('update:' + propKey, eventProp[propKey]);\n this.$emit('modelchanged', eventProp[propKey]);\n }\n }\n }\n }\n else if ((eventName === 'actionBegin' && eventProp.requestType === 'dateNavigate') && this.models && (this.models.length !== 0)) {\n var key = this.models.toString().match(/currentView|selectedDate/) || [];\n var propKey = key[0];\n if (eventProp && key && !isUndefined(eventProp[propKey])) {\n if (!isExecute) {\n this.ej2Instances.vueInstance.$emit('update:' + propKey, eventProp[propKey]);\n this.ej2Instances.vueInstance.$emit('modelchanged', eventProp[propKey]);\n }\n else {\n this.$emit('update:' + propKey, eventProp[propKey]);\n this.$emit('modelchanged', eventProp[propKey]);\n }\n }\n }\n if ((this.ej2Instances && this.ej2Instances._trigger)) {\n this.ej2Instances._trigger(eventName, eventProp, successHandler);\n }\n },\n custom: function () {\n this.updated();\n },\n addRecord: function (data, index) {\n return this.ej2Instances.addRecord(data, index);\n },\n addShimmerEffect: function () {\n return this.ej2Instances.addShimmerEffect();\n },\n autoFitColumns: function (fieldNames) {\n return this.ej2Instances.autoFitColumns(fieldNames);\n },\n batchAsyncUpdate: function (changes) {\n return this.ej2Instances.batchAsyncUpdate(changes);\n },\n batchUpdate: function (changes) {\n return this.ej2Instances.batchUpdate(changes);\n },\n calculatePageSizeByParentHeight: function (containerHeight) {\n return this.ej2Instances.calculatePageSizeByParentHeight(containerHeight);\n },\n changeDataSource: function (dataSource, columns) {\n return this.ej2Instances.changeDataSource(dataSource, columns);\n },\n clearCellSelection: function () {\n return this.ej2Instances.clearCellSelection();\n },\n clearFiltering: function (fields) {\n return this.ej2Instances.clearFiltering(fields);\n },\n clearGrouping: function () {\n return this.ej2Instances.clearGrouping();\n },\n clearRowSelection: function () {\n return this.ej2Instances.clearRowSelection();\n },\n clearSelection: function () {\n return this.ej2Instances.clearSelection();\n },\n clearSorting: function () {\n return this.ej2Instances.clearSorting();\n },\n closeEdit: function () {\n return this.ej2Instances.closeEdit();\n },\n copy: function (withHeader) {\n return this.ej2Instances.copy(withHeader);\n },\n csvExport: function (excelExportProperties, isMultipleExport, workbook, isBlob) {\n return this.ej2Instances.csvExport(excelExportProperties, isMultipleExport, workbook, isBlob);\n },\n dataReady: function () {\n return this.ej2Instances.dataReady();\n },\n deleteRecord: function (fieldname, data) {\n return this.ej2Instances.deleteRecord(fieldname, data);\n },\n deleteRow: function (tr) {\n return this.ej2Instances.deleteRow(tr);\n },\n destroyTemplate: function (propertyNames, index) {\n return this.ej2Instances.destroyTemplate(propertyNames, index);\n },\n detailCollapseAll: function () {\n return this.ej2Instances.detailCollapseAll();\n },\n detailExpandAll: function () {\n return this.ej2Instances.detailExpandAll();\n },\n editCell: function (index, field) {\n return this.ej2Instances.editCell(index, field);\n },\n enableToolbarItems: function (items, isEnable) {\n return this.ej2Instances.enableToolbarItems(items, isEnable);\n },\n endEdit: function () {\n return this.ej2Instances.endEdit();\n },\n excelExport: function (excelExportProperties, isMultipleExport, workbook, isBlob) {\n return this.ej2Instances.excelExport(excelExportProperties, isMultipleExport, workbook, isBlob);\n },\n extendRequiredModules: function (modules) {\n return this.ej2Instances.extendRequiredModules(modules);\n },\n filterByColumn: function (fieldName, filterOperator, filterValue, predicate, matchCase, ignoreAccent, actualFilterValue, actualOperator) {\n return this.ej2Instances.filterByColumn(fieldName, filterOperator, filterValue, predicate, matchCase, ignoreAccent, actualFilterValue, actualOperator);\n },\n getBatchChanges: function () {\n return this.ej2Instances.getBatchChanges();\n },\n getCellFromIndex: function (rowIndex, columnIndex) {\n return this.ej2Instances.getCellFromIndex(rowIndex, columnIndex);\n },\n getColumnByField: function (field) {\n return this.ej2Instances.getColumnByField(field);\n },\n getColumnByUid: function (uid) {\n return this.ej2Instances.getColumnByUid(uid);\n },\n getColumnFieldNames: function () {\n return this.ej2Instances.getColumnFieldNames();\n },\n getColumnHeaderByField: function (field) {\n return this.ej2Instances.getColumnHeaderByField(field);\n },\n getColumnHeaderByIndex: function (index) {\n return this.ej2Instances.getColumnHeaderByIndex(index);\n },\n getColumnHeaderByUid: function (uid) {\n return this.ej2Instances.getColumnHeaderByUid(uid);\n },\n getColumnIndexByField: function (field) {\n return this.ej2Instances.getColumnIndexByField(field);\n },\n getColumnIndexByUid: function (uid) {\n return this.ej2Instances.getColumnIndexByUid(uid);\n },\n getColumns: function (isRefresh) {\n return this.ej2Instances.getColumns(isRefresh);\n },\n getContent: function () {\n return this.ej2Instances.getContent();\n },\n getContentTable: function () {\n return this.ej2Instances.getContentTable();\n },\n getCurrentViewRecords: function () {\n return this.ej2Instances.getCurrentViewRecords();\n },\n getDataModule: function () {\n return this.ej2Instances.getDataModule();\n },\n getDataRows: function () {\n return this.ej2Instances.getDataRows();\n },\n getFilterUIInfo: function () {\n return this.ej2Instances.getFilterUIInfo();\n },\n getFilteredRecords: function () {\n return this.ej2Instances.getFilteredRecords();\n },\n getFooterContent: function () {\n return this.ej2Instances.getFooterContent();\n },\n getFooterContentTable: function () {\n return this.ej2Instances.getFooterContentTable();\n },\n getForeignKeyColumns: function () {\n return this.ej2Instances.getForeignKeyColumns();\n },\n getFrozenDataRows: function () {\n return this.ej2Instances.getFrozenDataRows();\n },\n getFrozenLeftColumnHeaderByIndex: function (index) {\n return this.ej2Instances.getFrozenLeftColumnHeaderByIndex(index);\n },\n getFrozenLeftCount: function () {\n return this.ej2Instances.getFrozenLeftCount();\n },\n getFrozenMode: function () {\n return this.ej2Instances.getFrozenMode();\n },\n getFrozenRightCellFromIndex: function (rowIndex, columnIndex) {\n return this.ej2Instances.getFrozenRightCellFromIndex(rowIndex, columnIndex);\n },\n getFrozenRightColumnHeaderByIndex: function (index) {\n return this.ej2Instances.getFrozenRightColumnHeaderByIndex(index);\n },\n getFrozenRightDataRows: function () {\n return this.ej2Instances.getFrozenRightDataRows();\n },\n getFrozenRightRowByIndex: function (index) {\n return this.ej2Instances.getFrozenRightRowByIndex(index);\n },\n getFrozenRightRows: function () {\n return this.ej2Instances.getFrozenRightRows();\n },\n getFrozenRowByIndex: function (index) {\n return this.ej2Instances.getFrozenRowByIndex(index);\n },\n getHeaderContent: function () {\n return this.ej2Instances.getHeaderContent();\n },\n getHeaderTable: function () {\n return this.ej2Instances.getHeaderTable();\n },\n getHiddenColumns: function () {\n return this.ej2Instances.getHiddenColumns();\n },\n getMediaColumns: function () {\n return this.ej2Instances.getMediaColumns();\n },\n getMovableCellFromIndex: function (rowIndex, columnIndex) {\n return this.ej2Instances.getMovableCellFromIndex(rowIndex, columnIndex);\n },\n getMovableColumnHeaderByIndex: function (index) {\n return this.ej2Instances.getMovableColumnHeaderByIndex(index);\n },\n getMovableDataRows: function () {\n return this.ej2Instances.getMovableDataRows();\n },\n getMovableRowByIndex: function (index) {\n return this.ej2Instances.getMovableRowByIndex(index);\n },\n getMovableRows: function () {\n return this.ej2Instances.getMovableRows();\n },\n getPager: function () {\n return this.ej2Instances.getPager();\n },\n getPrimaryKeyFieldNames: function () {\n return this.ej2Instances.getPrimaryKeyFieldNames();\n },\n getRowByIndex: function (index) {\n return this.ej2Instances.getRowByIndex(index);\n },\n getRowIndexByPrimaryKey: function (value) {\n return this.ej2Instances.getRowIndexByPrimaryKey(value);\n },\n getRowInfo: function (target) {\n return this.ej2Instances.getRowInfo(target);\n },\n getRows: function () {\n return this.ej2Instances.getRows();\n },\n getSelectedColumnsUid: function () {\n return this.ej2Instances.getSelectedColumnsUid();\n },\n getSelectedRecords: function () {\n return this.ej2Instances.getSelectedRecords();\n },\n getSelectedRowCellIndexes: function () {\n return this.ej2Instances.getSelectedRowCellIndexes();\n },\n getSelectedRowIndexes: function () {\n return this.ej2Instances.getSelectedRowIndexes();\n },\n getSelectedRows: function () {\n return this.ej2Instances.getSelectedRows();\n },\n getSummaryValues: function (summaryCol, summaryData) {\n return this.ej2Instances.getSummaryValues(summaryCol, summaryData);\n },\n getUidByColumnField: function (field) {\n return this.ej2Instances.getUidByColumnField(field);\n },\n getVisibleColumns: function () {\n return this.ej2Instances.getVisibleColumns();\n },\n goToPage: function (pageNo) {\n return this.ej2Instances.goToPage(pageNo);\n },\n groupCollapseAll: function () {\n return this.ej2Instances.groupCollapseAll();\n },\n groupColumn: function (columnName) {\n return this.ej2Instances.groupColumn(columnName);\n },\n groupExpandAll: function () {\n return this.ej2Instances.groupExpandAll();\n },\n hideColumns: function (keys, hideBy) {\n return this.ej2Instances.hideColumns(keys, hideBy);\n },\n hideScroll: function () {\n return this.ej2Instances.hideScroll();\n },\n hideSpinner: function () {\n return this.ej2Instances.hideSpinner();\n },\n isFrozenGrid: function () {\n return this.ej2Instances.isFrozenGrid();\n },\n openColumnChooser: function (x, y) {\n return this.ej2Instances.openColumnChooser(x, y);\n },\n pdfExport: function (pdfExportProperties, isMultipleExport, pdfDoc, isBlob) {\n return this.ej2Instances.pdfExport(pdfExportProperties, isMultipleExport, pdfDoc, isBlob);\n },\n print: function () {\n return this.ej2Instances.print();\n },\n refresh: function () {\n return this.ej2Instances.refresh();\n },\n refreshColumns: function () {\n return this.ej2Instances.refreshColumns();\n },\n refreshHeader: function () {\n return this.ej2Instances.refreshHeader();\n },\n removeMaskRow: function () {\n return this.ej2Instances.removeMaskRow();\n },\n reorderColumnByIndex: function (fromIndex, toIndex) {\n return this.ej2Instances.reorderColumnByIndex(fromIndex, toIndex);\n },\n reorderColumnByTargetIndex: function (fieldName, toIndex) {\n return this.ej2Instances.reorderColumnByTargetIndex(fieldName, toIndex);\n },\n reorderColumns: function (fromFName, toFName) {\n return this.ej2Instances.reorderColumns(fromFName, toFName);\n },\n reorderRows: function (fromIndexes, toIndex) {\n return this.ej2Instances.reorderRows(fromIndexes, toIndex);\n },\n saveCell: function () {\n return this.ej2Instances.saveCell();\n },\n search: function (searchString) {\n return this.ej2Instances.search(searchString);\n },\n selectCell: function (cellIndex, isToggle) {\n return this.ej2Instances.selectCell(cellIndex, isToggle);\n },\n selectCells: function (rowCellIndexes) {\n return this.ej2Instances.selectCells(rowCellIndexes);\n },\n selectCellsByRange: function (startIndex, endIndex) {\n return this.ej2Instances.selectCellsByRange(startIndex, endIndex);\n },\n selectRow: function (index, isToggle) {\n return this.ej2Instances.selectRow(index, isToggle);\n },\n selectRows: function (rowIndexes) {\n return this.ej2Instances.selectRows(rowIndexes);\n },\n selectRowsByRange: function (startIndex, endIndex) {\n return this.ej2Instances.selectRowsByRange(startIndex, endIndex);\n },\n serverCsvExport: function (url) {\n return this.ej2Instances.serverCsvExport(url);\n },\n serverExcelExport: function (url) {\n return this.ej2Instances.serverExcelExport(url);\n },\n serverPdfExport: function (url) {\n return this.ej2Instances.serverPdfExport(url);\n },\n setCellValue: function (key, field, value) {\n return this.ej2Instances.setCellValue(key, field, value);\n },\n setGridContent: function (element) {\n return this.ej2Instances.setGridContent(element);\n },\n setGridContentTable: function (element) {\n return this.ej2Instances.setGridContentTable(element);\n },\n setGridHeaderContent: function (element) {\n return this.ej2Instances.setGridHeaderContent(element);\n },\n setGridHeaderTable: function (element) {\n return this.ej2Instances.setGridHeaderTable(element);\n },\n setGridPager: function (element) {\n return this.ej2Instances.setGridPager(element);\n },\n setRowData: function (key, rowData) {\n return this.ej2Instances.setRowData(key, rowData);\n },\n showAdaptiveFilterDialog: function () {\n return this.ej2Instances.showAdaptiveFilterDialog();\n },\n showAdaptiveSortDialog: function () {\n return this.ej2Instances.showAdaptiveSortDialog();\n },\n showColumns: function (keys, showBy) {\n return this.ej2Instances.showColumns(keys, showBy);\n },\n showMaskRow: function (axisDirection, dialogElement) {\n return this.ej2Instances.showMaskRow(axisDirection, dialogElement);\n },\n showSpinner: function () {\n return this.ej2Instances.showSpinner();\n },\n sortColumn: function (columnName, direction, isMultiSort) {\n return this.ej2Instances.sortColumn(columnName, direction, isMultiSort);\n },\n startEdit: function () {\n return this.ej2Instances.startEdit();\n },\n ungroupColumn: function (columnName) {\n return this.ej2Instances.ungroupColumn(columnName);\n },\n updateCell: function (rowIndex, field, value) {\n return this.ej2Instances.updateCell(rowIndex, field, value);\n },\n updateExternalMessage: function (message) {\n return this.ej2Instances.updateExternalMessage(message);\n },\n updateRow: function (index, data) {\n return this.ej2Instances.updateRow(index, data);\n },\n updateRowValue: function (key, rowData) {\n return this.ej2Instances.updateRowValue(key, rowData);\n },\n }\n});\nexport var GridPlugin = {\n name: 'ejs-grid',\n install: function (Vue) {\n Vue.component(GridPlugin.name, GridComponent);\n Vue.component(ColumnPlugin.name, ColumnDirective);\n Vue.component(ColumnsPlugin.name, ColumnsDirective);\n Vue.component(StackedColumnPlugin.name, StackedColumnDirective);\n Vue.component(StackedColumnsPlugin.name, StackedColumnsDirective);\n Vue.component(AggregatePlugin.name, AggregateDirective);\n Vue.component(AggregatesPlugin.name, AggregatesDirective);\n Vue.component(AggregateColumnPlugin.name, AggregateColumnDirective);\n Vue.component(AggregateColumnsPlugin.name, AggregateColumnsDirective);\n }\n};\n","//! moment.js locale configuration\n//! locale : Central Atlas Tamazight [tzm]\n//! author : Abdel Said : https://github.com/abdelsaid\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var tzm = moment.defineLocale('tzm', {\n months: 'ⵉâµâµâ´°âµ¢âµ”_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓâµâµ¢âµ“_ⵢⵓâµâµ¢âµ“âµ£_ⵖⵓⵛⵜ_ⵛⵓⵜⴰâµâ´±âµ‰âµ”_ⴽⵟⵓⴱⵕ_âµâµ“ⵡⴰâµâ´±âµ‰âµ”_ⴷⵓⵊâµâ´±âµ‰âµ”'.split(\n '_'\n ),\n monthsShort:\n 'ⵉâµâµâ´°âµ¢âµ”_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓâµâµ¢âµ“_ⵢⵓâµâµ¢âµ“âµ£_ⵖⵓⵛⵜ_ⵛⵓⵜⴰâµâ´±âµ‰âµ”_ⴽⵟⵓⴱⵕ_âµâµ“ⵡⴰâµâ´±âµ‰âµ”_ⴷⵓⵊâµâ´±âµ‰âµ”'.split(\n '_'\n ),\n weekdays: 'ⴰⵙⴰⵎⴰⵙ_â´°âµ¢âµâ´°âµ™_ⴰⵙⵉâµâ´°âµ™_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ'.split('_'),\n weekdaysShort: 'ⴰⵙⴰⵎⴰⵙ_â´°âµ¢âµâ´°âµ™_ⴰⵙⵉâµâ´°âµ™_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ'.split('_'),\n weekdaysMin: 'ⴰⵙⴰⵎⴰⵙ_â´°âµ¢âµâ´°âµ™_ⴰⵙⵉâµâ´°âµ™_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[ⴰⵙⴷⵅ â´´] LT',\n nextDay: '[ⴰⵙⴽⴰ â´´] LT',\n nextWeek: 'dddd [â´´] LT',\n lastDay: '[ⴰⵚⴰâµâµœ â´´] LT',\n lastWeek: 'dddd [â´´] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'â´·â´°â´·âµ… âµ™ ⵢⴰⵠ%s',\n past: 'ⵢⴰⵠ%s',\n s: 'ⵉⵎⵉⴽ',\n ss: '%d ⵉⵎⵉⴽ',\n m: 'ⵎⵉâµâµ“â´º',\n mm: '%d ⵎⵉâµâµ“â´º',\n h: 'ⵙⴰⵄⴰ',\n hh: '%d ⵜⴰⵙⵙⴰⵄⵉâµ',\n d: 'ⴰⵙⵙ',\n dd: '%d oⵙⵙⴰâµ',\n M: 'â´°âµ¢oⵓⵔ',\n MM: '%d ⵉⵢⵢⵉⵔâµ',\n y: 'ⴰⵙⴳⴰⵙ',\n yy: '%d ⵉⵙⴳⴰⵙâµ',\n },\n week: {\n dow: 6, // Saturday is the first day of the week.\n doy: 12, // The week that contains Jan 12th is the first week of the year.\n },\n });\n\n return tzm;\n\n})));\n","//! moment.js\n//! version : 2.29.4\n//! authors : Tim Wood, Iskren Chernev, Moment.js contributors\n//! license : MIT\n//! momentjs.com\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n typeof define === 'function' && define.amd ? define(factory) :\n global.moment = factory()\n}(this, (function () { 'use strict';\n\n var hookCallback;\n\n function hooks() {\n return hookCallback.apply(null, arguments);\n }\n\n // This is done to register the method called with moment()\n // without creating circular dependencies.\n function setHookCallback(callback) {\n hookCallback = callback;\n }\n\n function isArray(input) {\n return (\n input instanceof Array ||\n Object.prototype.toString.call(input) === '[object Array]'\n );\n }\n\n function isObject(input) {\n // IE8 will treat undefined and null as object if it wasn't for\n // input != null\n return (\n input != null &&\n Object.prototype.toString.call(input) === '[object Object]'\n );\n }\n\n function hasOwnProp(a, b) {\n return Object.prototype.hasOwnProperty.call(a, b);\n }\n\n function isObjectEmpty(obj) {\n if (Object.getOwnPropertyNames) {\n return Object.getOwnPropertyNames(obj).length === 0;\n } else {\n var k;\n for (k in obj) {\n if (hasOwnProp(obj, k)) {\n return false;\n }\n }\n return true;\n }\n }\n\n function isUndefined(input) {\n return input === void 0;\n }\n\n function isNumber(input) {\n return (\n typeof input === 'number' ||\n Object.prototype.toString.call(input) === '[object Number]'\n );\n }\n\n function isDate(input) {\n return (\n input instanceof Date ||\n Object.prototype.toString.call(input) === '[object Date]'\n );\n }\n\n function map(arr, fn) {\n var res = [],\n i,\n arrLen = arr.length;\n for (i = 0; i < arrLen; ++i) {\n res.push(fn(arr[i], i));\n }\n return res;\n }\n\n function extend(a, b) {\n for (var i in b) {\n if (hasOwnProp(b, i)) {\n a[i] = b[i];\n }\n }\n\n if (hasOwnProp(b, 'toString')) {\n a.toString = b.toString;\n }\n\n if (hasOwnProp(b, 'valueOf')) {\n a.valueOf = b.valueOf;\n }\n\n return a;\n }\n\n function createUTC(input, format, locale, strict) {\n return createLocalOrUTC(input, format, locale, strict, true).utc();\n }\n\n function defaultParsingFlags() {\n // We need to deep clone this object.\n return {\n empty: false,\n unusedTokens: [],\n unusedInput: [],\n overflow: -2,\n charsLeftOver: 0,\n nullInput: false,\n invalidEra: null,\n invalidMonth: null,\n invalidFormat: false,\n userInvalidated: false,\n iso: false,\n parsedDateParts: [],\n era: null,\n meridiem: null,\n rfc2822: false,\n weekdayMismatch: false,\n };\n }\n\n function getParsingFlags(m) {\n if (m._pf == null) {\n m._pf = defaultParsingFlags();\n }\n return m._pf;\n }\n\n var some;\n if (Array.prototype.some) {\n some = Array.prototype.some;\n } else {\n some = function (fun) {\n var t = Object(this),\n len = t.length >>> 0,\n i;\n\n for (i = 0; i < len; i++) {\n if (i in t && fun.call(this, t[i], i, t)) {\n return true;\n }\n }\n\n return false;\n };\n }\n\n function isValid(m) {\n if (m._isValid == null) {\n var flags = getParsingFlags(m),\n parsedParts = some.call(flags.parsedDateParts, function (i) {\n return i != null;\n }),\n isNowValid =\n !isNaN(m._d.getTime()) &&\n flags.overflow < 0 &&\n !flags.empty &&\n !flags.invalidEra &&\n !flags.invalidMonth &&\n !flags.invalidWeekday &&\n !flags.weekdayMismatch &&\n !flags.nullInput &&\n !flags.invalidFormat &&\n !flags.userInvalidated &&\n (!flags.meridiem || (flags.meridiem && parsedParts));\n\n if (m._strict) {\n isNowValid =\n isNowValid &&\n flags.charsLeftOver === 0 &&\n flags.unusedTokens.length === 0 &&\n flags.bigHour === undefined;\n }\n\n if (Object.isFrozen == null || !Object.isFrozen(m)) {\n m._isValid = isNowValid;\n } else {\n return isNowValid;\n }\n }\n return m._isValid;\n }\n\n function createInvalid(flags) {\n var m = createUTC(NaN);\n if (flags != null) {\n extend(getParsingFlags(m), flags);\n } else {\n getParsingFlags(m).userInvalidated = true;\n }\n\n return m;\n }\n\n // Plugins that add properties should also add the key here (null value),\n // so we can properly clone ourselves.\n var momentProperties = (hooks.momentProperties = []),\n updateInProgress = false;\n\n function copyConfig(to, from) {\n var i,\n prop,\n val,\n momentPropertiesLen = momentProperties.length;\n\n if (!isUndefined(from._isAMomentObject)) {\n to._isAMomentObject = from._isAMomentObject;\n }\n if (!isUndefined(from._i)) {\n to._i = from._i;\n }\n if (!isUndefined(from._f)) {\n to._f = from._f;\n }\n if (!isUndefined(from._l)) {\n to._l = from._l;\n }\n if (!isUndefined(from._strict)) {\n to._strict = from._strict;\n }\n if (!isUndefined(from._tzm)) {\n to._tzm = from._tzm;\n }\n if (!isUndefined(from._isUTC)) {\n to._isUTC = from._isUTC;\n }\n if (!isUndefined(from._offset)) {\n to._offset = from._offset;\n }\n if (!isUndefined(from._pf)) {\n to._pf = getParsingFlags(from);\n }\n if (!isUndefined(from._locale)) {\n to._locale = from._locale;\n }\n\n if (momentPropertiesLen > 0) {\n for (i = 0; i < momentPropertiesLen; i++) {\n prop = momentProperties[i];\n val = from[prop];\n if (!isUndefined(val)) {\n to[prop] = val;\n }\n }\n }\n\n return to;\n }\n\n // Moment prototype object\n function Moment(config) {\n copyConfig(this, config);\n this._d = new Date(config._d != null ? config._d.getTime() : NaN);\n if (!this.isValid()) {\n this._d = new Date(NaN);\n }\n // Prevent infinite loop in case updateOffset creates new moment\n // objects.\n if (updateInProgress === false) {\n updateInProgress = true;\n hooks.updateOffset(this);\n updateInProgress = false;\n }\n }\n\n function isMoment(obj) {\n return (\n obj instanceof Moment || (obj != null && obj._isAMomentObject != null)\n );\n }\n\n function warn(msg) {\n if (\n hooks.suppressDeprecationWarnings === false &&\n typeof console !== 'undefined' &&\n console.warn\n ) {\n console.warn('Deprecation warning: ' + msg);\n }\n }\n\n function deprecate(msg, fn) {\n var firstTime = true;\n\n return extend(function () {\n if (hooks.deprecationHandler != null) {\n hooks.deprecationHandler(null, msg);\n }\n if (firstTime) {\n var args = [],\n arg,\n i,\n key,\n argLen = arguments.length;\n for (i = 0; i < argLen; i++) {\n arg = '';\n if (typeof arguments[i] === 'object') {\n arg += '\\n[' + i + '] ';\n for (key in arguments[0]) {\n if (hasOwnProp(arguments[0], key)) {\n arg += key + ': ' + arguments[0][key] + ', ';\n }\n }\n arg = arg.slice(0, -2); // Remove trailing comma and space\n } else {\n arg = arguments[i];\n }\n args.push(arg);\n }\n warn(\n msg +\n '\\nArguments: ' +\n Array.prototype.slice.call(args).join('') +\n '\\n' +\n new Error().stack\n );\n firstTime = false;\n }\n return fn.apply(this, arguments);\n }, fn);\n }\n\n var deprecations = {};\n\n function deprecateSimple(name, msg) {\n if (hooks.deprecationHandler != null) {\n hooks.deprecationHandler(name, msg);\n }\n if (!deprecations[name]) {\n warn(msg);\n deprecations[name] = true;\n }\n }\n\n hooks.suppressDeprecationWarnings = false;\n hooks.deprecationHandler = null;\n\n function isFunction(input) {\n return (\n (typeof Function !== 'undefined' && input instanceof Function) ||\n Object.prototype.toString.call(input) === '[object Function]'\n );\n }\n\n function set(config) {\n var prop, i;\n for (i in config) {\n if (hasOwnProp(config, i)) {\n prop = config[i];\n if (isFunction(prop)) {\n this[i] = prop;\n } else {\n this['_' + i] = prop;\n }\n }\n }\n this._config = config;\n // Lenient ordinal parsing accepts just a number in addition to\n // number + (possibly) stuff coming from _dayOfMonthOrdinalParse.\n // TODO: Remove \"ordinalParse\" fallback in next major release.\n this._dayOfMonthOrdinalParseLenient = new RegExp(\n (this._dayOfMonthOrdinalParse.source || this._ordinalParse.source) +\n '|' +\n /\\d{1,2}/.source\n );\n }\n\n function mergeConfigs(parentConfig, childConfig) {\n var res = extend({}, parentConfig),\n prop;\n for (prop in childConfig) {\n if (hasOwnProp(childConfig, prop)) {\n if (isObject(parentConfig[prop]) && isObject(childConfig[prop])) {\n res[prop] = {};\n extend(res[prop], parentConfig[prop]);\n extend(res[prop], childConfig[prop]);\n } else if (childConfig[prop] != null) {\n res[prop] = childConfig[prop];\n } else {\n delete res[prop];\n }\n }\n }\n for (prop in parentConfig) {\n if (\n hasOwnProp(parentConfig, prop) &&\n !hasOwnProp(childConfig, prop) &&\n isObject(parentConfig[prop])\n ) {\n // make sure changes to properties don't modify parent config\n res[prop] = extend({}, res[prop]);\n }\n }\n return res;\n }\n\n function Locale(config) {\n if (config != null) {\n this.set(config);\n }\n }\n\n var keys;\n\n if (Object.keys) {\n keys = Object.keys;\n } else {\n keys = function (obj) {\n var i,\n res = [];\n for (i in obj) {\n if (hasOwnProp(obj, i)) {\n res.push(i);\n }\n }\n return res;\n };\n }\n\n var defaultCalendar = {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n };\n\n function calendar(key, mom, now) {\n var output = this._calendar[key] || this._calendar['sameElse'];\n return isFunction(output) ? output.call(mom, now) : output;\n }\n\n function zeroFill(number, targetLength, forceSign) {\n var absNumber = '' + Math.abs(number),\n zerosToFill = targetLength - absNumber.length,\n sign = number >= 0;\n return (\n (sign ? (forceSign ? '+' : '') : '-') +\n Math.pow(10, Math.max(0, zerosToFill)).toString().substr(1) +\n absNumber\n );\n }\n\n var formattingTokens =\n /(\\[[^\\[]*\\])|(\\\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,\n localFormattingTokens = /(\\[[^\\[]*\\])|(\\\\)?(LTS|LT|LL?L?L?|l{1,4})/g,\n formatFunctions = {},\n formatTokenFunctions = {};\n\n // token: 'M'\n // padded: ['MM', 2]\n // ordinal: 'Mo'\n // callback: function () { this.month() + 1 }\n function addFormatToken(token, padded, ordinal, callback) {\n var func = callback;\n if (typeof callback === 'string') {\n func = function () {\n return this[callback]();\n };\n }\n if (token) {\n formatTokenFunctions[token] = func;\n }\n if (padded) {\n formatTokenFunctions[padded[0]] = function () {\n return zeroFill(func.apply(this, arguments), padded[1], padded[2]);\n };\n }\n if (ordinal) {\n formatTokenFunctions[ordinal] = function () {\n return this.localeData().ordinal(\n func.apply(this, arguments),\n token\n );\n };\n }\n }\n\n function removeFormattingTokens(input) {\n if (input.match(/\\[[\\s\\S]/)) {\n return input.replace(/^\\[|\\]$/g, '');\n }\n return input.replace(/\\\\/g, '');\n }\n\n function makeFormatFunction(format) {\n var array = format.match(formattingTokens),\n i,\n length;\n\n for (i = 0, length = array.length; i < length; i++) {\n if (formatTokenFunctions[array[i]]) {\n array[i] = formatTokenFunctions[array[i]];\n } else {\n array[i] = removeFormattingTokens(array[i]);\n }\n }\n\n return function (mom) {\n var output = '',\n i;\n for (i = 0; i < length; i++) {\n output += isFunction(array[i])\n ? array[i].call(mom, format)\n : array[i];\n }\n return output;\n };\n }\n\n // format date using native date object\n function formatMoment(m, format) {\n if (!m.isValid()) {\n return m.localeData().invalidDate();\n }\n\n format = expandFormat(format, m.localeData());\n formatFunctions[format] =\n formatFunctions[format] || makeFormatFunction(format);\n\n return formatFunctions[format](m);\n }\n\n function expandFormat(format, locale) {\n var i = 5;\n\n function replaceLongDateFormatTokens(input) {\n return locale.longDateFormat(input) || input;\n }\n\n localFormattingTokens.lastIndex = 0;\n while (i >= 0 && localFormattingTokens.test(format)) {\n format = format.replace(\n localFormattingTokens,\n replaceLongDateFormatTokens\n );\n localFormattingTokens.lastIndex = 0;\n i -= 1;\n }\n\n return format;\n }\n\n var defaultLongDateFormat = {\n LTS: 'h:mm:ss A',\n LT: 'h:mm A',\n L: 'MM/DD/YYYY',\n LL: 'MMMM D, YYYY',\n LLL: 'MMMM D, YYYY h:mm A',\n LLLL: 'dddd, MMMM D, YYYY h:mm A',\n };\n\n function longDateFormat(key) {\n var format = this._longDateFormat[key],\n formatUpper = this._longDateFormat[key.toUpperCase()];\n\n if (format || !formatUpper) {\n return format;\n }\n\n this._longDateFormat[key] = formatUpper\n .match(formattingTokens)\n .map(function (tok) {\n if (\n tok === 'MMMM' ||\n tok === 'MM' ||\n tok === 'DD' ||\n tok === 'dddd'\n ) {\n return tok.slice(1);\n }\n return tok;\n })\n .join('');\n\n return this._longDateFormat[key];\n }\n\n var defaultInvalidDate = 'Invalid date';\n\n function invalidDate() {\n return this._invalidDate;\n }\n\n var defaultOrdinal = '%d',\n defaultDayOfMonthOrdinalParse = /\\d{1,2}/;\n\n function ordinal(number) {\n return this._ordinal.replace('%d', number);\n }\n\n var defaultRelativeTime = {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n w: 'a week',\n ww: '%d weeks',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n };\n\n function relativeTime(number, withoutSuffix, string, isFuture) {\n var output = this._relativeTime[string];\n return isFunction(output)\n ? output(number, withoutSuffix, string, isFuture)\n : output.replace(/%d/i, number);\n }\n\n function pastFuture(diff, output) {\n var format = this._relativeTime[diff > 0 ? 'future' : 'past'];\n return isFunction(format) ? format(output) : format.replace(/%s/i, output);\n }\n\n var aliases = {};\n\n function addUnitAlias(unit, shorthand) {\n var lowerCase = unit.toLowerCase();\n aliases[lowerCase] = aliases[lowerCase + 's'] = aliases[shorthand] = unit;\n }\n\n function normalizeUnits(units) {\n return typeof units === 'string'\n ? aliases[units] || aliases[units.toLowerCase()]\n : undefined;\n }\n\n function normalizeObjectUnits(inputObject) {\n var normalizedInput = {},\n normalizedProp,\n prop;\n\n for (prop in inputObject) {\n if (hasOwnProp(inputObject, prop)) {\n normalizedProp = normalizeUnits(prop);\n if (normalizedProp) {\n normalizedInput[normalizedProp] = inputObject[prop];\n }\n }\n }\n\n return normalizedInput;\n }\n\n var priorities = {};\n\n function addUnitPriority(unit, priority) {\n priorities[unit] = priority;\n }\n\n function getPrioritizedUnits(unitsObj) {\n var units = [],\n u;\n for (u in unitsObj) {\n if (hasOwnProp(unitsObj, u)) {\n units.push({ unit: u, priority: priorities[u] });\n }\n }\n units.sort(function (a, b) {\n return a.priority - b.priority;\n });\n return units;\n }\n\n function isLeapYear(year) {\n return (year % 4 === 0 && year % 100 !== 0) || year % 400 === 0;\n }\n\n function absFloor(number) {\n if (number < 0) {\n // -0 -> 0\n return Math.ceil(number) || 0;\n } else {\n return Math.floor(number);\n }\n }\n\n function toInt(argumentForCoercion) {\n var coercedNumber = +argumentForCoercion,\n value = 0;\n\n if (coercedNumber !== 0 && isFinite(coercedNumber)) {\n value = absFloor(coercedNumber);\n }\n\n return value;\n }\n\n function makeGetSet(unit, keepTime) {\n return function (value) {\n if (value != null) {\n set$1(this, unit, value);\n hooks.updateOffset(this, keepTime);\n return this;\n } else {\n return get(this, unit);\n }\n };\n }\n\n function get(mom, unit) {\n return mom.isValid()\n ? mom._d['get' + (mom._isUTC ? 'UTC' : '') + unit]()\n : NaN;\n }\n\n function set$1(mom, unit, value) {\n if (mom.isValid() && !isNaN(value)) {\n if (\n unit === 'FullYear' &&\n isLeapYear(mom.year()) &&\n mom.month() === 1 &&\n mom.date() === 29\n ) {\n value = toInt(value);\n mom._d['set' + (mom._isUTC ? 'UTC' : '') + unit](\n value,\n mom.month(),\n daysInMonth(value, mom.month())\n );\n } else {\n mom._d['set' + (mom._isUTC ? 'UTC' : '') + unit](value);\n }\n }\n }\n\n // MOMENTS\n\n function stringGet(units) {\n units = normalizeUnits(units);\n if (isFunction(this[units])) {\n return this[units]();\n }\n return this;\n }\n\n function stringSet(units, value) {\n if (typeof units === 'object') {\n units = normalizeObjectUnits(units);\n var prioritized = getPrioritizedUnits(units),\n i,\n prioritizedLen = prioritized.length;\n for (i = 0; i < prioritizedLen; i++) {\n this[prioritized[i].unit](units[prioritized[i].unit]);\n }\n } else {\n units = normalizeUnits(units);\n if (isFunction(this[units])) {\n return this[units](value);\n }\n }\n return this;\n }\n\n var match1 = /\\d/, // 0 - 9\n match2 = /\\d\\d/, // 00 - 99\n match3 = /\\d{3}/, // 000 - 999\n match4 = /\\d{4}/, // 0000 - 9999\n match6 = /[+-]?\\d{6}/, // -999999 - 999999\n match1to2 = /\\d\\d?/, // 0 - 99\n match3to4 = /\\d\\d\\d\\d?/, // 999 - 9999\n match5to6 = /\\d\\d\\d\\d\\d\\d?/, // 99999 - 999999\n match1to3 = /\\d{1,3}/, // 0 - 999\n match1to4 = /\\d{1,4}/, // 0 - 9999\n match1to6 = /[+-]?\\d{1,6}/, // -999999 - 999999\n matchUnsigned = /\\d+/, // 0 - inf\n matchSigned = /[+-]?\\d+/, // -inf - inf\n matchOffset = /Z|[+-]\\d\\d:?\\d\\d/gi, // +00:00 -00:00 +0000 -0000 or Z\n matchShortOffset = /Z|[+-]\\d\\d(?::?\\d\\d)?/gi, // +00 -00 +00:00 -00:00 +0000 -0000 or Z\n matchTimestamp = /[+-]?\\d+(\\.\\d{1,3})?/, // 123456789 123456789.123\n // any word (or two) characters or numbers including two/three word month in arabic.\n // includes scottish gaelic two word and hyphenated months\n matchWord =\n /[0-9]{0,256}['a-z\\u00A0-\\u05FF\\u0700-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFF07\\uFF10-\\uFFEF]{1,256}|[\\u0600-\\u06FF\\/]{1,256}(\\s*?[\\u0600-\\u06FF]{1,256}){1,2}/i,\n regexes;\n\n regexes = {};\n\n function addRegexToken(token, regex, strictRegex) {\n regexes[token] = isFunction(regex)\n ? regex\n : function (isStrict, localeData) {\n return isStrict && strictRegex ? strictRegex : regex;\n };\n }\n\n function getParseRegexForToken(token, config) {\n if (!hasOwnProp(regexes, token)) {\n return new RegExp(unescapeFormat(token));\n }\n\n return regexes[token](config._strict, config._locale);\n }\n\n // Code from http://stackoverflow.com/questions/3561493/is-there-a-regexp-escape-function-in-javascript\n function unescapeFormat(s) {\n return regexEscape(\n s\n .replace('\\\\', '')\n .replace(\n /\\\\(\\[)|\\\\(\\])|\\[([^\\]\\[]*)\\]|\\\\(.)/g,\n function (matched, p1, p2, p3, p4) {\n return p1 || p2 || p3 || p4;\n }\n )\n );\n }\n\n function regexEscape(s) {\n return s.replace(/[-\\/\\\\^$*+?.()|[\\]{}]/g, '\\\\$&');\n }\n\n var tokens = {};\n\n function addParseToken(token, callback) {\n var i,\n func = callback,\n tokenLen;\n if (typeof token === 'string') {\n token = [token];\n }\n if (isNumber(callback)) {\n func = function (input, array) {\n array[callback] = toInt(input);\n };\n }\n tokenLen = token.length;\n for (i = 0; i < tokenLen; i++) {\n tokens[token[i]] = func;\n }\n }\n\n function addWeekParseToken(token, callback) {\n addParseToken(token, function (input, array, config, token) {\n config._w = config._w || {};\n callback(input, config._w, config, token);\n });\n }\n\n function addTimeToArrayFromToken(token, input, config) {\n if (input != null && hasOwnProp(tokens, token)) {\n tokens[token](input, config._a, config, token);\n }\n }\n\n var YEAR = 0,\n MONTH = 1,\n DATE = 2,\n HOUR = 3,\n MINUTE = 4,\n SECOND = 5,\n MILLISECOND = 6,\n WEEK = 7,\n WEEKDAY = 8;\n\n function mod(n, x) {\n return ((n % x) + x) % x;\n }\n\n var indexOf;\n\n if (Array.prototype.indexOf) {\n indexOf = Array.prototype.indexOf;\n } else {\n indexOf = function (o) {\n // I know\n var i;\n for (i = 0; i < this.length; ++i) {\n if (this[i] === o) {\n return i;\n }\n }\n return -1;\n };\n }\n\n function daysInMonth(year, month) {\n if (isNaN(year) || isNaN(month)) {\n return NaN;\n }\n var modMonth = mod(month, 12);\n year += (month - modMonth) / 12;\n return modMonth === 1\n ? isLeapYear(year)\n ? 29\n : 28\n : 31 - ((modMonth % 7) % 2);\n }\n\n // FORMATTING\n\n addFormatToken('M', ['MM', 2], 'Mo', function () {\n return this.month() + 1;\n });\n\n addFormatToken('MMM', 0, 0, function (format) {\n return this.localeData().monthsShort(this, format);\n });\n\n addFormatToken('MMMM', 0, 0, function (format) {\n return this.localeData().months(this, format);\n });\n\n // ALIASES\n\n addUnitAlias('month', 'M');\n\n // PRIORITY\n\n addUnitPriority('month', 8);\n\n // PARSING\n\n addRegexToken('M', match1to2);\n addRegexToken('MM', match1to2, match2);\n addRegexToken('MMM', function (isStrict, locale) {\n return locale.monthsShortRegex(isStrict);\n });\n addRegexToken('MMMM', function (isStrict, locale) {\n return locale.monthsRegex(isStrict);\n });\n\n addParseToken(['M', 'MM'], function (input, array) {\n array[MONTH] = toInt(input) - 1;\n });\n\n addParseToken(['MMM', 'MMMM'], function (input, array, config, token) {\n var month = config._locale.monthsParse(input, token, config._strict);\n // if we didn't find a month name, mark the date as invalid.\n if (month != null) {\n array[MONTH] = month;\n } else {\n getParsingFlags(config).invalidMonth = input;\n }\n });\n\n // LOCALES\n\n var defaultLocaleMonths =\n 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n defaultLocaleMonthsShort =\n 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n MONTHS_IN_FORMAT = /D[oD]?(\\[[^\\[\\]]*\\]|\\s)+MMMM?/,\n defaultMonthsShortRegex = matchWord,\n defaultMonthsRegex = matchWord;\n\n function localeMonths(m, format) {\n if (!m) {\n return isArray(this._months)\n ? this._months\n : this._months['standalone'];\n }\n return isArray(this._months)\n ? this._months[m.month()]\n : this._months[\n (this._months.isFormat || MONTHS_IN_FORMAT).test(format)\n ? 'format'\n : 'standalone'\n ][m.month()];\n }\n\n function localeMonthsShort(m, format) {\n if (!m) {\n return isArray(this._monthsShort)\n ? this._monthsShort\n : this._monthsShort['standalone'];\n }\n return isArray(this._monthsShort)\n ? this._monthsShort[m.month()]\n : this._monthsShort[\n MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'\n ][m.month()];\n }\n\n function handleStrictParse(monthName, format, strict) {\n var i,\n ii,\n mom,\n llc = monthName.toLocaleLowerCase();\n if (!this._monthsParse) {\n // this is not used\n this._monthsParse = [];\n this._longMonthsParse = [];\n this._shortMonthsParse = [];\n for (i = 0; i < 12; ++i) {\n mom = createUTC([2000, i]);\n this._shortMonthsParse[i] = this.monthsShort(\n mom,\n ''\n ).toLocaleLowerCase();\n this._longMonthsParse[i] = this.months(mom, '').toLocaleLowerCase();\n }\n }\n\n if (strict) {\n if (format === 'MMM') {\n ii = indexOf.call(this._shortMonthsParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._longMonthsParse, llc);\n return ii !== -1 ? ii : null;\n }\n } else {\n if (format === 'MMM') {\n ii = indexOf.call(this._shortMonthsParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._longMonthsParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._longMonthsParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortMonthsParse, llc);\n return ii !== -1 ? ii : null;\n }\n }\n }\n\n function localeMonthsParse(monthName, format, strict) {\n var i, mom, regex;\n\n if (this._monthsParseExact) {\n return handleStrictParse.call(this, monthName, format, strict);\n }\n\n if (!this._monthsParse) {\n this._monthsParse = [];\n this._longMonthsParse = [];\n this._shortMonthsParse = [];\n }\n\n // TODO: add sorting\n // Sorting makes sure if one month (or abbr) is a prefix of another\n // see sorting in computeMonthsParse\n for (i = 0; i < 12; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, i]);\n if (strict && !this._longMonthsParse[i]) {\n this._longMonthsParse[i] = new RegExp(\n '^' + this.months(mom, '').replace('.', '') + '$',\n 'i'\n );\n this._shortMonthsParse[i] = new RegExp(\n '^' + this.monthsShort(mom, '').replace('.', '') + '$',\n 'i'\n );\n }\n if (!strict && !this._monthsParse[i]) {\n regex =\n '^' + this.months(mom, '') + '|^' + this.monthsShort(mom, '');\n this._monthsParse[i] = new RegExp(regex.replace('.', ''), 'i');\n }\n // test the regex\n if (\n strict &&\n format === 'MMMM' &&\n this._longMonthsParse[i].test(monthName)\n ) {\n return i;\n } else if (\n strict &&\n format === 'MMM' &&\n this._shortMonthsParse[i].test(monthName)\n ) {\n return i;\n } else if (!strict && this._monthsParse[i].test(monthName)) {\n return i;\n }\n }\n }\n\n // MOMENTS\n\n function setMonth(mom, value) {\n var dayOfMonth;\n\n if (!mom.isValid()) {\n // No op\n return mom;\n }\n\n if (typeof value === 'string') {\n if (/^\\d+$/.test(value)) {\n value = toInt(value);\n } else {\n value = mom.localeData().monthsParse(value);\n // TODO: Another silent failure?\n if (!isNumber(value)) {\n return mom;\n }\n }\n }\n\n dayOfMonth = Math.min(mom.date(), daysInMonth(mom.year(), value));\n mom._d['set' + (mom._isUTC ? 'UTC' : '') + 'Month'](value, dayOfMonth);\n return mom;\n }\n\n function getSetMonth(value) {\n if (value != null) {\n setMonth(this, value);\n hooks.updateOffset(this, true);\n return this;\n } else {\n return get(this, 'Month');\n }\n }\n\n function getDaysInMonth() {\n return daysInMonth(this.year(), this.month());\n }\n\n function monthsShortRegex(isStrict) {\n if (this._monthsParseExact) {\n if (!hasOwnProp(this, '_monthsRegex')) {\n computeMonthsParse.call(this);\n }\n if (isStrict) {\n return this._monthsShortStrictRegex;\n } else {\n return this._monthsShortRegex;\n }\n } else {\n if (!hasOwnProp(this, '_monthsShortRegex')) {\n this._monthsShortRegex = defaultMonthsShortRegex;\n }\n return this._monthsShortStrictRegex && isStrict\n ? this._monthsShortStrictRegex\n : this._monthsShortRegex;\n }\n }\n\n function monthsRegex(isStrict) {\n if (this._monthsParseExact) {\n if (!hasOwnProp(this, '_monthsRegex')) {\n computeMonthsParse.call(this);\n }\n if (isStrict) {\n return this._monthsStrictRegex;\n } else {\n return this._monthsRegex;\n }\n } else {\n if (!hasOwnProp(this, '_monthsRegex')) {\n this._monthsRegex = defaultMonthsRegex;\n }\n return this._monthsStrictRegex && isStrict\n ? this._monthsStrictRegex\n : this._monthsRegex;\n }\n }\n\n function computeMonthsParse() {\n function cmpLenRev(a, b) {\n return b.length - a.length;\n }\n\n var shortPieces = [],\n longPieces = [],\n mixedPieces = [],\n i,\n mom;\n for (i = 0; i < 12; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, i]);\n shortPieces.push(this.monthsShort(mom, ''));\n longPieces.push(this.months(mom, ''));\n mixedPieces.push(this.months(mom, ''));\n mixedPieces.push(this.monthsShort(mom, ''));\n }\n // Sorting makes sure if one month (or abbr) is a prefix of another it\n // will match the longer piece.\n shortPieces.sort(cmpLenRev);\n longPieces.sort(cmpLenRev);\n mixedPieces.sort(cmpLenRev);\n for (i = 0; i < 12; i++) {\n shortPieces[i] = regexEscape(shortPieces[i]);\n longPieces[i] = regexEscape(longPieces[i]);\n }\n for (i = 0; i < 24; i++) {\n mixedPieces[i] = regexEscape(mixedPieces[i]);\n }\n\n this._monthsRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._monthsShortRegex = this._monthsRegex;\n this._monthsStrictRegex = new RegExp(\n '^(' + longPieces.join('|') + ')',\n 'i'\n );\n this._monthsShortStrictRegex = new RegExp(\n '^(' + shortPieces.join('|') + ')',\n 'i'\n );\n }\n\n // FORMATTING\n\n addFormatToken('Y', 0, 0, function () {\n var y = this.year();\n return y <= 9999 ? zeroFill(y, 4) : '+' + y;\n });\n\n addFormatToken(0, ['YY', 2], 0, function () {\n return this.year() % 100;\n });\n\n addFormatToken(0, ['YYYY', 4], 0, 'year');\n addFormatToken(0, ['YYYYY', 5], 0, 'year');\n addFormatToken(0, ['YYYYYY', 6, true], 0, 'year');\n\n // ALIASES\n\n addUnitAlias('year', 'y');\n\n // PRIORITIES\n\n addUnitPriority('year', 1);\n\n // PARSING\n\n addRegexToken('Y', matchSigned);\n addRegexToken('YY', match1to2, match2);\n addRegexToken('YYYY', match1to4, match4);\n addRegexToken('YYYYY', match1to6, match6);\n addRegexToken('YYYYYY', match1to6, match6);\n\n addParseToken(['YYYYY', 'YYYYYY'], YEAR);\n addParseToken('YYYY', function (input, array) {\n array[YEAR] =\n input.length === 2 ? hooks.parseTwoDigitYear(input) : toInt(input);\n });\n addParseToken('YY', function (input, array) {\n array[YEAR] = hooks.parseTwoDigitYear(input);\n });\n addParseToken('Y', function (input, array) {\n array[YEAR] = parseInt(input, 10);\n });\n\n // HELPERS\n\n function daysInYear(year) {\n return isLeapYear(year) ? 366 : 365;\n }\n\n // HOOKS\n\n hooks.parseTwoDigitYear = function (input) {\n return toInt(input) + (toInt(input) > 68 ? 1900 : 2000);\n };\n\n // MOMENTS\n\n var getSetYear = makeGetSet('FullYear', true);\n\n function getIsLeapYear() {\n return isLeapYear(this.year());\n }\n\n function createDate(y, m, d, h, M, s, ms) {\n // can't just apply() to create a date:\n // https://stackoverflow.com/q/181348\n var date;\n // the date constructor remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n date = new Date(y + 400, m, d, h, M, s, ms);\n if (isFinite(date.getFullYear())) {\n date.setFullYear(y);\n }\n } else {\n date = new Date(y, m, d, h, M, s, ms);\n }\n\n return date;\n }\n\n function createUTCDate(y) {\n var date, args;\n // the Date.UTC function remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n args = Array.prototype.slice.call(arguments);\n // preserve leap years using a full 400 year cycle, then reset\n args[0] = y + 400;\n date = new Date(Date.UTC.apply(null, args));\n if (isFinite(date.getUTCFullYear())) {\n date.setUTCFullYear(y);\n }\n } else {\n date = new Date(Date.UTC.apply(null, arguments));\n }\n\n return date;\n }\n\n // start-of-first-week - start-of-year\n function firstWeekOffset(year, dow, doy) {\n var // first-week day -- which january is always in the first week (4 for iso, 1 for other)\n fwd = 7 + dow - doy,\n // first-week day local weekday -- which local weekday is fwd\n fwdlw = (7 + createUTCDate(year, 0, fwd).getUTCDay() - dow) % 7;\n\n return -fwdlw + fwd - 1;\n }\n\n // https://en.wikipedia.org/wiki/ISO_week_date#Calculating_a_date_given_the_year.2C_week_number_and_weekday\n function dayOfYearFromWeeks(year, week, weekday, dow, doy) {\n var localWeekday = (7 + weekday - dow) % 7,\n weekOffset = firstWeekOffset(year, dow, doy),\n dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset,\n resYear,\n resDayOfYear;\n\n if (dayOfYear <= 0) {\n resYear = year - 1;\n resDayOfYear = daysInYear(resYear) + dayOfYear;\n } else if (dayOfYear > daysInYear(year)) {\n resYear = year + 1;\n resDayOfYear = dayOfYear - daysInYear(year);\n } else {\n resYear = year;\n resDayOfYear = dayOfYear;\n }\n\n return {\n year: resYear,\n dayOfYear: resDayOfYear,\n };\n }\n\n function weekOfYear(mom, dow, doy) {\n var weekOffset = firstWeekOffset(mom.year(), dow, doy),\n week = Math.floor((mom.dayOfYear() - weekOffset - 1) / 7) + 1,\n resWeek,\n resYear;\n\n if (week < 1) {\n resYear = mom.year() - 1;\n resWeek = week + weeksInYear(resYear, dow, doy);\n } else if (week > weeksInYear(mom.year(), dow, doy)) {\n resWeek = week - weeksInYear(mom.year(), dow, doy);\n resYear = mom.year() + 1;\n } else {\n resYear = mom.year();\n resWeek = week;\n }\n\n return {\n week: resWeek,\n year: resYear,\n };\n }\n\n function weeksInYear(year, dow, doy) {\n var weekOffset = firstWeekOffset(year, dow, doy),\n weekOffsetNext = firstWeekOffset(year + 1, dow, doy);\n return (daysInYear(year) - weekOffset + weekOffsetNext) / 7;\n }\n\n // FORMATTING\n\n addFormatToken('w', ['ww', 2], 'wo', 'week');\n addFormatToken('W', ['WW', 2], 'Wo', 'isoWeek');\n\n // ALIASES\n\n addUnitAlias('week', 'w');\n addUnitAlias('isoWeek', 'W');\n\n // PRIORITIES\n\n addUnitPriority('week', 5);\n addUnitPriority('isoWeek', 5);\n\n // PARSING\n\n addRegexToken('w', match1to2);\n addRegexToken('ww', match1to2, match2);\n addRegexToken('W', match1to2);\n addRegexToken('WW', match1to2, match2);\n\n addWeekParseToken(\n ['w', 'ww', 'W', 'WW'],\n function (input, week, config, token) {\n week[token.substr(0, 1)] = toInt(input);\n }\n );\n\n // HELPERS\n\n // LOCALES\n\n function localeWeek(mom) {\n return weekOfYear(mom, this._week.dow, this._week.doy).week;\n }\n\n var defaultLocaleWeek = {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n };\n\n function localeFirstDayOfWeek() {\n return this._week.dow;\n }\n\n function localeFirstDayOfYear() {\n return this._week.doy;\n }\n\n // MOMENTS\n\n function getSetWeek(input) {\n var week = this.localeData().week(this);\n return input == null ? week : this.add((input - week) * 7, 'd');\n }\n\n function getSetISOWeek(input) {\n var week = weekOfYear(this, 1, 4).week;\n return input == null ? week : this.add((input - week) * 7, 'd');\n }\n\n // FORMATTING\n\n addFormatToken('d', 0, 'do', 'day');\n\n addFormatToken('dd', 0, 0, function (format) {\n return this.localeData().weekdaysMin(this, format);\n });\n\n addFormatToken('ddd', 0, 0, function (format) {\n return this.localeData().weekdaysShort(this, format);\n });\n\n addFormatToken('dddd', 0, 0, function (format) {\n return this.localeData().weekdays(this, format);\n });\n\n addFormatToken('e', 0, 0, 'weekday');\n addFormatToken('E', 0, 0, 'isoWeekday');\n\n // ALIASES\n\n addUnitAlias('day', 'd');\n addUnitAlias('weekday', 'e');\n addUnitAlias('isoWeekday', 'E');\n\n // PRIORITY\n addUnitPriority('day', 11);\n addUnitPriority('weekday', 11);\n addUnitPriority('isoWeekday', 11);\n\n // PARSING\n\n addRegexToken('d', match1to2);\n addRegexToken('e', match1to2);\n addRegexToken('E', match1to2);\n addRegexToken('dd', function (isStrict, locale) {\n return locale.weekdaysMinRegex(isStrict);\n });\n addRegexToken('ddd', function (isStrict, locale) {\n return locale.weekdaysShortRegex(isStrict);\n });\n addRegexToken('dddd', function (isStrict, locale) {\n return locale.weekdaysRegex(isStrict);\n });\n\n addWeekParseToken(['dd', 'ddd', 'dddd'], function (input, week, config, token) {\n var weekday = config._locale.weekdaysParse(input, token, config._strict);\n // if we didn't get a weekday name, mark the date as invalid\n if (weekday != null) {\n week.d = weekday;\n } else {\n getParsingFlags(config).invalidWeekday = input;\n }\n });\n\n addWeekParseToken(['d', 'e', 'E'], function (input, week, config, token) {\n week[token] = toInt(input);\n });\n\n // HELPERS\n\n function parseWeekday(input, locale) {\n if (typeof input !== 'string') {\n return input;\n }\n\n if (!isNaN(input)) {\n return parseInt(input, 10);\n }\n\n input = locale.weekdaysParse(input);\n if (typeof input === 'number') {\n return input;\n }\n\n return null;\n }\n\n function parseIsoWeekday(input, locale) {\n if (typeof input === 'string') {\n return locale.weekdaysParse(input) % 7 || 7;\n }\n return isNaN(input) ? null : input;\n }\n\n // LOCALES\n function shiftWeekdays(ws, n) {\n return ws.slice(n, 7).concat(ws.slice(0, n));\n }\n\n var defaultLocaleWeekdays =\n 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_'),\n defaultLocaleWeekdaysShort = 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n defaultLocaleWeekdaysMin = 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n defaultWeekdaysRegex = matchWord,\n defaultWeekdaysShortRegex = matchWord,\n defaultWeekdaysMinRegex = matchWord;\n\n function localeWeekdays(m, format) {\n var weekdays = isArray(this._weekdays)\n ? this._weekdays\n : this._weekdays[\n m && m !== true && this._weekdays.isFormat.test(format)\n ? 'format'\n : 'standalone'\n ];\n return m === true\n ? shiftWeekdays(weekdays, this._week.dow)\n : m\n ? weekdays[m.day()]\n : weekdays;\n }\n\n function localeWeekdaysShort(m) {\n return m === true\n ? shiftWeekdays(this._weekdaysShort, this._week.dow)\n : m\n ? this._weekdaysShort[m.day()]\n : this._weekdaysShort;\n }\n\n function localeWeekdaysMin(m) {\n return m === true\n ? shiftWeekdays(this._weekdaysMin, this._week.dow)\n : m\n ? this._weekdaysMin[m.day()]\n : this._weekdaysMin;\n }\n\n function handleStrictParse$1(weekdayName, format, strict) {\n var i,\n ii,\n mom,\n llc = weekdayName.toLocaleLowerCase();\n if (!this._weekdaysParse) {\n this._weekdaysParse = [];\n this._shortWeekdaysParse = [];\n this._minWeekdaysParse = [];\n\n for (i = 0; i < 7; ++i) {\n mom = createUTC([2000, 1]).day(i);\n this._minWeekdaysParse[i] = this.weekdaysMin(\n mom,\n ''\n ).toLocaleLowerCase();\n this._shortWeekdaysParse[i] = this.weekdaysShort(\n mom,\n ''\n ).toLocaleLowerCase();\n this._weekdaysParse[i] = this.weekdays(mom, '').toLocaleLowerCase();\n }\n }\n\n if (strict) {\n if (format === 'dddd') {\n ii = indexOf.call(this._weekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else if (format === 'ddd') {\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n }\n } else {\n if (format === 'dddd') {\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else if (format === 'ddd') {\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._minWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n }\n }\n }\n\n function localeWeekdaysParse(weekdayName, format, strict) {\n var i, mom, regex;\n\n if (this._weekdaysParseExact) {\n return handleStrictParse$1.call(this, weekdayName, format, strict);\n }\n\n if (!this._weekdaysParse) {\n this._weekdaysParse = [];\n this._minWeekdaysParse = [];\n this._shortWeekdaysParse = [];\n this._fullWeekdaysParse = [];\n }\n\n for (i = 0; i < 7; i++) {\n // make the regex if we don't have it already\n\n mom = createUTC([2000, 1]).day(i);\n if (strict && !this._fullWeekdaysParse[i]) {\n this._fullWeekdaysParse[i] = new RegExp(\n '^' + this.weekdays(mom, '').replace('.', '\\\\.?') + '$',\n 'i'\n );\n this._shortWeekdaysParse[i] = new RegExp(\n '^' + this.weekdaysShort(mom, '').replace('.', '\\\\.?') + '$',\n 'i'\n );\n this._minWeekdaysParse[i] = new RegExp(\n '^' + this.weekdaysMin(mom, '').replace('.', '\\\\.?') + '$',\n 'i'\n );\n }\n if (!this._weekdaysParse[i]) {\n regex =\n '^' +\n this.weekdays(mom, '') +\n '|^' +\n this.weekdaysShort(mom, '') +\n '|^' +\n this.weekdaysMin(mom, '');\n this._weekdaysParse[i] = new RegExp(regex.replace('.', ''), 'i');\n }\n // test the regex\n if (\n strict &&\n format === 'dddd' &&\n this._fullWeekdaysParse[i].test(weekdayName)\n ) {\n return i;\n } else if (\n strict &&\n format === 'ddd' &&\n this._shortWeekdaysParse[i].test(weekdayName)\n ) {\n return i;\n } else if (\n strict &&\n format === 'dd' &&\n this._minWeekdaysParse[i].test(weekdayName)\n ) {\n return i;\n } else if (!strict && this._weekdaysParse[i].test(weekdayName)) {\n return i;\n }\n }\n }\n\n // MOMENTS\n\n function getSetDayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n var day = this._isUTC ? this._d.getUTCDay() : this._d.getDay();\n if (input != null) {\n input = parseWeekday(input, this.localeData());\n return this.add(input - day, 'd');\n } else {\n return day;\n }\n }\n\n function getSetLocaleDayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n var weekday = (this.day() + 7 - this.localeData()._week.dow) % 7;\n return input == null ? weekday : this.add(input - weekday, 'd');\n }\n\n function getSetISODayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n\n // behaves the same as moment#day except\n // as a getter, returns 7 instead of 0 (1-7 range instead of 0-6)\n // as a setter, sunday should belong to the previous week.\n\n if (input != null) {\n var weekday = parseIsoWeekday(input, this.localeData());\n return this.day(this.day() % 7 ? weekday : weekday - 7);\n } else {\n return this.day() || 7;\n }\n }\n\n function weekdaysRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysStrictRegex;\n } else {\n return this._weekdaysRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n this._weekdaysRegex = defaultWeekdaysRegex;\n }\n return this._weekdaysStrictRegex && isStrict\n ? this._weekdaysStrictRegex\n : this._weekdaysRegex;\n }\n }\n\n function weekdaysShortRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysShortStrictRegex;\n } else {\n return this._weekdaysShortRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysShortRegex')) {\n this._weekdaysShortRegex = defaultWeekdaysShortRegex;\n }\n return this._weekdaysShortStrictRegex && isStrict\n ? this._weekdaysShortStrictRegex\n : this._weekdaysShortRegex;\n }\n }\n\n function weekdaysMinRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysMinStrictRegex;\n } else {\n return this._weekdaysMinRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysMinRegex')) {\n this._weekdaysMinRegex = defaultWeekdaysMinRegex;\n }\n return this._weekdaysMinStrictRegex && isStrict\n ? this._weekdaysMinStrictRegex\n : this._weekdaysMinRegex;\n }\n }\n\n function computeWeekdaysParse() {\n function cmpLenRev(a, b) {\n return b.length - a.length;\n }\n\n var minPieces = [],\n shortPieces = [],\n longPieces = [],\n mixedPieces = [],\n i,\n mom,\n minp,\n shortp,\n longp;\n for (i = 0; i < 7; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, 1]).day(i);\n minp = regexEscape(this.weekdaysMin(mom, ''));\n shortp = regexEscape(this.weekdaysShort(mom, ''));\n longp = regexEscape(this.weekdays(mom, ''));\n minPieces.push(minp);\n shortPieces.push(shortp);\n longPieces.push(longp);\n mixedPieces.push(minp);\n mixedPieces.push(shortp);\n mixedPieces.push(longp);\n }\n // Sorting makes sure if one weekday (or abbr) is a prefix of another it\n // will match the longer piece.\n minPieces.sort(cmpLenRev);\n shortPieces.sort(cmpLenRev);\n longPieces.sort(cmpLenRev);\n mixedPieces.sort(cmpLenRev);\n\n this._weekdaysRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._weekdaysShortRegex = this._weekdaysRegex;\n this._weekdaysMinRegex = this._weekdaysRegex;\n\n this._weekdaysStrictRegex = new RegExp(\n '^(' + longPieces.join('|') + ')',\n 'i'\n );\n this._weekdaysShortStrictRegex = new RegExp(\n '^(' + shortPieces.join('|') + ')',\n 'i'\n );\n this._weekdaysMinStrictRegex = new RegExp(\n '^(' + minPieces.join('|') + ')',\n 'i'\n );\n }\n\n // FORMATTING\n\n function hFormat() {\n return this.hours() % 12 || 12;\n }\n\n function kFormat() {\n return this.hours() || 24;\n }\n\n addFormatToken('H', ['HH', 2], 0, 'hour');\n addFormatToken('h', ['hh', 2], 0, hFormat);\n addFormatToken('k', ['kk', 2], 0, kFormat);\n\n addFormatToken('hmm', 0, 0, function () {\n return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2);\n });\n\n addFormatToken('hmmss', 0, 0, function () {\n return (\n '' +\n hFormat.apply(this) +\n zeroFill(this.minutes(), 2) +\n zeroFill(this.seconds(), 2)\n );\n });\n\n addFormatToken('Hmm', 0, 0, function () {\n return '' + this.hours() + zeroFill(this.minutes(), 2);\n });\n\n addFormatToken('Hmmss', 0, 0, function () {\n return (\n '' +\n this.hours() +\n zeroFill(this.minutes(), 2) +\n zeroFill(this.seconds(), 2)\n );\n });\n\n function meridiem(token, lowercase) {\n addFormatToken(token, 0, 0, function () {\n return this.localeData().meridiem(\n this.hours(),\n this.minutes(),\n lowercase\n );\n });\n }\n\n meridiem('a', true);\n meridiem('A', false);\n\n // ALIASES\n\n addUnitAlias('hour', 'h');\n\n // PRIORITY\n addUnitPriority('hour', 13);\n\n // PARSING\n\n function matchMeridiem(isStrict, locale) {\n return locale._meridiemParse;\n }\n\n addRegexToken('a', matchMeridiem);\n addRegexToken('A', matchMeridiem);\n addRegexToken('H', match1to2);\n addRegexToken('h', match1to2);\n addRegexToken('k', match1to2);\n addRegexToken('HH', match1to2, match2);\n addRegexToken('hh', match1to2, match2);\n addRegexToken('kk', match1to2, match2);\n\n addRegexToken('hmm', match3to4);\n addRegexToken('hmmss', match5to6);\n addRegexToken('Hmm', match3to4);\n addRegexToken('Hmmss', match5to6);\n\n addParseToken(['H', 'HH'], HOUR);\n addParseToken(['k', 'kk'], function (input, array, config) {\n var kInput = toInt(input);\n array[HOUR] = kInput === 24 ? 0 : kInput;\n });\n addParseToken(['a', 'A'], function (input, array, config) {\n config._isPm = config._locale.isPM(input);\n config._meridiem = input;\n });\n addParseToken(['h', 'hh'], function (input, array, config) {\n array[HOUR] = toInt(input);\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('hmm', function (input, array, config) {\n var pos = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos));\n array[MINUTE] = toInt(input.substr(pos));\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('hmmss', function (input, array, config) {\n var pos1 = input.length - 4,\n pos2 = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos1));\n array[MINUTE] = toInt(input.substr(pos1, 2));\n array[SECOND] = toInt(input.substr(pos2));\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('Hmm', function (input, array, config) {\n var pos = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos));\n array[MINUTE] = toInt(input.substr(pos));\n });\n addParseToken('Hmmss', function (input, array, config) {\n var pos1 = input.length - 4,\n pos2 = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos1));\n array[MINUTE] = toInt(input.substr(pos1, 2));\n array[SECOND] = toInt(input.substr(pos2));\n });\n\n // LOCALES\n\n function localeIsPM(input) {\n // IE8 Quirks Mode & IE7 Standards Mode do not allow accessing strings like arrays\n // Using charAt should be more compatible.\n return (input + '').toLowerCase().charAt(0) === 'p';\n }\n\n var defaultLocaleMeridiemParse = /[ap]\\.?m?\\.?/i,\n // Setting the hour should keep the time, because the user explicitly\n // specified which hour they want. So trying to maintain the same hour (in\n // a new timezone) makes sense. Adding/subtracting hours does not follow\n // this rule.\n getSetHour = makeGetSet('Hours', true);\n\n function localeMeridiem(hours, minutes, isLower) {\n if (hours > 11) {\n return isLower ? 'pm' : 'PM';\n } else {\n return isLower ? 'am' : 'AM';\n }\n }\n\n var baseConfig = {\n calendar: defaultCalendar,\n longDateFormat: defaultLongDateFormat,\n invalidDate: defaultInvalidDate,\n ordinal: defaultOrdinal,\n dayOfMonthOrdinalParse: defaultDayOfMonthOrdinalParse,\n relativeTime: defaultRelativeTime,\n\n months: defaultLocaleMonths,\n monthsShort: defaultLocaleMonthsShort,\n\n week: defaultLocaleWeek,\n\n weekdays: defaultLocaleWeekdays,\n weekdaysMin: defaultLocaleWeekdaysMin,\n weekdaysShort: defaultLocaleWeekdaysShort,\n\n meridiemParse: defaultLocaleMeridiemParse,\n };\n\n // internal storage for locale config files\n var locales = {},\n localeFamilies = {},\n globalLocale;\n\n function commonPrefix(arr1, arr2) {\n var i,\n minl = Math.min(arr1.length, arr2.length);\n for (i = 0; i < minl; i += 1) {\n if (arr1[i] !== arr2[i]) {\n return i;\n }\n }\n return minl;\n }\n\n function normalizeLocale(key) {\n return key ? key.toLowerCase().replace('_', '-') : key;\n }\n\n // pick the locale from the array\n // try ['en-au', 'en-gb'] as 'en-au', 'en-gb', 'en', as in move through the list trying each\n // substring from most specific to least, but move to the next array item if it's a more specific variant than the current root\n function chooseLocale(names) {\n var i = 0,\n j,\n next,\n locale,\n split;\n\n while (i < names.length) {\n split = normalizeLocale(names[i]).split('-');\n j = split.length;\n next = normalizeLocale(names[i + 1]);\n next = next ? next.split('-') : null;\n while (j > 0) {\n locale = loadLocale(split.slice(0, j).join('-'));\n if (locale) {\n return locale;\n }\n if (\n next &&\n next.length >= j &&\n commonPrefix(split, next) >= j - 1\n ) {\n //the next array item is better than a shallower substring of this one\n break;\n }\n j--;\n }\n i++;\n }\n return globalLocale;\n }\n\n function isLocaleNameSane(name) {\n // Prevent names that look like filesystem paths, i.e contain '/' or '\\'\n return name.match('^[^/\\\\\\\\]*$') != null;\n }\n\n function loadLocale(name) {\n var oldLocale = null,\n aliasedRequire;\n // TODO: Find a better way to register and load all the locales in Node\n if (\n locales[name] === undefined &&\n typeof module !== 'undefined' &&\n module &&\n module.exports &&\n isLocaleNameSane(name)\n ) {\n try {\n oldLocale = globalLocale._abbr;\n aliasedRequire = require;\n aliasedRequire('./locale/' + name);\n getSetGlobalLocale(oldLocale);\n } catch (e) {\n // mark as not found to avoid repeating expensive file require call causing high CPU\n // when trying to find en-US, en_US, en-us for every format call\n locales[name] = null; // null means not found\n }\n }\n return locales[name];\n }\n\n // This function will load locale and then set the global locale. If\n // no arguments are passed in, it will simply return the current global\n // locale key.\n function getSetGlobalLocale(key, values) {\n var data;\n if (key) {\n if (isUndefined(values)) {\n data = getLocale(key);\n } else {\n data = defineLocale(key, values);\n }\n\n if (data) {\n // moment.duration._locale = moment._locale = data;\n globalLocale = data;\n } else {\n if (typeof console !== 'undefined' && console.warn) {\n //warn user if arguments are passed but the locale could not be set\n console.warn(\n 'Locale ' + key + ' not found. Did you forget to load it?'\n );\n }\n }\n }\n\n return globalLocale._abbr;\n }\n\n function defineLocale(name, config) {\n if (config !== null) {\n var locale,\n parentConfig = baseConfig;\n config.abbr = name;\n if (locales[name] != null) {\n deprecateSimple(\n 'defineLocaleOverride',\n 'use moment.updateLocale(localeName, config) to change ' +\n 'an existing locale. moment.defineLocale(localeName, ' +\n 'config) should only be used for creating a new locale ' +\n 'See http://momentjs.com/guides/#/warnings/define-locale/ for more info.'\n );\n parentConfig = locales[name]._config;\n } else if (config.parentLocale != null) {\n if (locales[config.parentLocale] != null) {\n parentConfig = locales[config.parentLocale]._config;\n } else {\n locale = loadLocale(config.parentLocale);\n if (locale != null) {\n parentConfig = locale._config;\n } else {\n if (!localeFamilies[config.parentLocale]) {\n localeFamilies[config.parentLocale] = [];\n }\n localeFamilies[config.parentLocale].push({\n name: name,\n config: config,\n });\n return null;\n }\n }\n }\n locales[name] = new Locale(mergeConfigs(parentConfig, config));\n\n if (localeFamilies[name]) {\n localeFamilies[name].forEach(function (x) {\n defineLocale(x.name, x.config);\n });\n }\n\n // backwards compat for now: also set the locale\n // make sure we set the locale AFTER all child locales have been\n // created, so we won't end up with the child locale set.\n getSetGlobalLocale(name);\n\n return locales[name];\n } else {\n // useful for testing\n delete locales[name];\n return null;\n }\n }\n\n function updateLocale(name, config) {\n if (config != null) {\n var locale,\n tmpLocale,\n parentConfig = baseConfig;\n\n if (locales[name] != null && locales[name].parentLocale != null) {\n // Update existing child locale in-place to avoid memory-leaks\n locales[name].set(mergeConfigs(locales[name]._config, config));\n } else {\n // MERGE\n tmpLocale = loadLocale(name);\n if (tmpLocale != null) {\n parentConfig = tmpLocale._config;\n }\n config = mergeConfigs(parentConfig, config);\n if (tmpLocale == null) {\n // updateLocale is called for creating a new locale\n // Set abbr so it will have a name (getters return\n // undefined otherwise).\n config.abbr = name;\n }\n locale = new Locale(config);\n locale.parentLocale = locales[name];\n locales[name] = locale;\n }\n\n // backwards compat for now: also set the locale\n getSetGlobalLocale(name);\n } else {\n // pass null for config to unupdate, useful for tests\n if (locales[name] != null) {\n if (locales[name].parentLocale != null) {\n locales[name] = locales[name].parentLocale;\n if (name === getSetGlobalLocale()) {\n getSetGlobalLocale(name);\n }\n } else if (locales[name] != null) {\n delete locales[name];\n }\n }\n }\n return locales[name];\n }\n\n // returns locale data\n function getLocale(key) {\n var locale;\n\n if (key && key._locale && key._locale._abbr) {\n key = key._locale._abbr;\n }\n\n if (!key) {\n return globalLocale;\n }\n\n if (!isArray(key)) {\n //short-circuit everything else\n locale = loadLocale(key);\n if (locale) {\n return locale;\n }\n key = [key];\n }\n\n return chooseLocale(key);\n }\n\n function listLocales() {\n return keys(locales);\n }\n\n function checkOverflow(m) {\n var overflow,\n a = m._a;\n\n if (a && getParsingFlags(m).overflow === -2) {\n overflow =\n a[MONTH] < 0 || a[MONTH] > 11\n ? MONTH\n : a[DATE] < 1 || a[DATE] > daysInMonth(a[YEAR], a[MONTH])\n ? DATE\n : a[HOUR] < 0 ||\n a[HOUR] > 24 ||\n (a[HOUR] === 24 &&\n (a[MINUTE] !== 0 ||\n a[SECOND] !== 0 ||\n a[MILLISECOND] !== 0))\n ? HOUR\n : a[MINUTE] < 0 || a[MINUTE] > 59\n ? MINUTE\n : a[SECOND] < 0 || a[SECOND] > 59\n ? SECOND\n : a[MILLISECOND] < 0 || a[MILLISECOND] > 999\n ? MILLISECOND\n : -1;\n\n if (\n getParsingFlags(m)._overflowDayOfYear &&\n (overflow < YEAR || overflow > DATE)\n ) {\n overflow = DATE;\n }\n if (getParsingFlags(m)._overflowWeeks && overflow === -1) {\n overflow = WEEK;\n }\n if (getParsingFlags(m)._overflowWeekday && overflow === -1) {\n overflow = WEEKDAY;\n }\n\n getParsingFlags(m).overflow = overflow;\n }\n\n return m;\n }\n\n // iso 8601 regex\n // 0000-00-00 0000-W00 or 0000-W00-0 + T + 00 or 00:00 or 00:00:00 or 00:00:00.000 + +00:00 or +0000 or +00)\n var extendedIsoRegex =\n /^\\s*((?:[+-]\\d{6}|\\d{4})-(?:\\d\\d-\\d\\d|W\\d\\d-\\d|W\\d\\d|\\d\\d\\d|\\d\\d))(?:(T| )(\\d\\d(?::\\d\\d(?::\\d\\d(?:[.,]\\d+)?)?)?)([+-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?$/,\n basicIsoRegex =\n /^\\s*((?:[+-]\\d{6}|\\d{4})(?:\\d\\d\\d\\d|W\\d\\d\\d|W\\d\\d|\\d\\d\\d|\\d\\d|))(?:(T| )(\\d\\d(?:\\d\\d(?:\\d\\d(?:[.,]\\d+)?)?)?)([+-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?$/,\n tzRegex = /Z|[+-]\\d\\d(?::?\\d\\d)?/,\n isoDates = [\n ['YYYYYY-MM-DD', /[+-]\\d{6}-\\d\\d-\\d\\d/],\n ['YYYY-MM-DD', /\\d{4}-\\d\\d-\\d\\d/],\n ['GGGG-[W]WW-E', /\\d{4}-W\\d\\d-\\d/],\n ['GGGG-[W]WW', /\\d{4}-W\\d\\d/, false],\n ['YYYY-DDD', /\\d{4}-\\d{3}/],\n ['YYYY-MM', /\\d{4}-\\d\\d/, false],\n ['YYYYYYMMDD', /[+-]\\d{10}/],\n ['YYYYMMDD', /\\d{8}/],\n ['GGGG[W]WWE', /\\d{4}W\\d{3}/],\n ['GGGG[W]WW', /\\d{4}W\\d{2}/, false],\n ['YYYYDDD', /\\d{7}/],\n ['YYYYMM', /\\d{6}/, false],\n ['YYYY', /\\d{4}/, false],\n ],\n // iso time formats and regexes\n isoTimes = [\n ['HH:mm:ss.SSSS', /\\d\\d:\\d\\d:\\d\\d\\.\\d+/],\n ['HH:mm:ss,SSSS', /\\d\\d:\\d\\d:\\d\\d,\\d+/],\n ['HH:mm:ss', /\\d\\d:\\d\\d:\\d\\d/],\n ['HH:mm', /\\d\\d:\\d\\d/],\n ['HHmmss.SSSS', /\\d\\d\\d\\d\\d\\d\\.\\d+/],\n ['HHmmss,SSSS', /\\d\\d\\d\\d\\d\\d,\\d+/],\n ['HHmmss', /\\d\\d\\d\\d\\d\\d/],\n ['HHmm', /\\d\\d\\d\\d/],\n ['HH', /\\d\\d/],\n ],\n aspNetJsonRegex = /^\\/?Date\\((-?\\d+)/i,\n // RFC 2822 regex: For details see https://tools.ietf.org/html/rfc2822#section-3.3\n rfc2822 =\n /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\\s)?(\\d{1,2})\\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\\s(\\d{2,4})\\s(\\d\\d):(\\d\\d)(?::(\\d\\d))?\\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\\d{4}))$/,\n obsOffsets = {\n UT: 0,\n GMT: 0,\n EDT: -4 * 60,\n EST: -5 * 60,\n CDT: -5 * 60,\n CST: -6 * 60,\n MDT: -6 * 60,\n MST: -7 * 60,\n PDT: -7 * 60,\n PST: -8 * 60,\n };\n\n // date from iso format\n function configFromISO(config) {\n var i,\n l,\n string = config._i,\n match = extendedIsoRegex.exec(string) || basicIsoRegex.exec(string),\n allowTime,\n dateFormat,\n timeFormat,\n tzFormat,\n isoDatesLen = isoDates.length,\n isoTimesLen = isoTimes.length;\n\n if (match) {\n getParsingFlags(config).iso = true;\n for (i = 0, l = isoDatesLen; i < l; i++) {\n if (isoDates[i][1].exec(match[1])) {\n dateFormat = isoDates[i][0];\n allowTime = isoDates[i][2] !== false;\n break;\n }\n }\n if (dateFormat == null) {\n config._isValid = false;\n return;\n }\n if (match[3]) {\n for (i = 0, l = isoTimesLen; i < l; i++) {\n if (isoTimes[i][1].exec(match[3])) {\n // match[2] should be 'T' or space\n timeFormat = (match[2] || ' ') + isoTimes[i][0];\n break;\n }\n }\n if (timeFormat == null) {\n config._isValid = false;\n return;\n }\n }\n if (!allowTime && timeFormat != null) {\n config._isValid = false;\n return;\n }\n if (match[4]) {\n if (tzRegex.exec(match[4])) {\n tzFormat = 'Z';\n } else {\n config._isValid = false;\n return;\n }\n }\n config._f = dateFormat + (timeFormat || '') + (tzFormat || '');\n configFromStringAndFormat(config);\n } else {\n config._isValid = false;\n }\n }\n\n function extractFromRFC2822Strings(\n yearStr,\n monthStr,\n dayStr,\n hourStr,\n minuteStr,\n secondStr\n ) {\n var result = [\n untruncateYear(yearStr),\n defaultLocaleMonthsShort.indexOf(monthStr),\n parseInt(dayStr, 10),\n parseInt(hourStr, 10),\n parseInt(minuteStr, 10),\n ];\n\n if (secondStr) {\n result.push(parseInt(secondStr, 10));\n }\n\n return result;\n }\n\n function untruncateYear(yearStr) {\n var year = parseInt(yearStr, 10);\n if (year <= 49) {\n return 2000 + year;\n } else if (year <= 999) {\n return 1900 + year;\n }\n return year;\n }\n\n function preprocessRFC2822(s) {\n // Remove comments and folding whitespace and replace multiple-spaces with a single space\n return s\n .replace(/\\([^()]*\\)|[\\n\\t]/g, ' ')\n .replace(/(\\s\\s+)/g, ' ')\n .replace(/^\\s\\s*/, '')\n .replace(/\\s\\s*$/, '');\n }\n\n function checkWeekday(weekdayStr, parsedInput, config) {\n if (weekdayStr) {\n // TODO: Replace the vanilla JS Date object with an independent day-of-week check.\n var weekdayProvided = defaultLocaleWeekdaysShort.indexOf(weekdayStr),\n weekdayActual = new Date(\n parsedInput[0],\n parsedInput[1],\n parsedInput[2]\n ).getDay();\n if (weekdayProvided !== weekdayActual) {\n getParsingFlags(config).weekdayMismatch = true;\n config._isValid = false;\n return false;\n }\n }\n return true;\n }\n\n function calculateOffset(obsOffset, militaryOffset, numOffset) {\n if (obsOffset) {\n return obsOffsets[obsOffset];\n } else if (militaryOffset) {\n // the only allowed military tz is Z\n return 0;\n } else {\n var hm = parseInt(numOffset, 10),\n m = hm % 100,\n h = (hm - m) / 100;\n return h * 60 + m;\n }\n }\n\n // date and time from ref 2822 format\n function configFromRFC2822(config) {\n var match = rfc2822.exec(preprocessRFC2822(config._i)),\n parsedArray;\n if (match) {\n parsedArray = extractFromRFC2822Strings(\n match[4],\n match[3],\n match[2],\n match[5],\n match[6],\n match[7]\n );\n if (!checkWeekday(match[1], parsedArray, config)) {\n return;\n }\n\n config._a = parsedArray;\n config._tzm = calculateOffset(match[8], match[9], match[10]);\n\n config._d = createUTCDate.apply(null, config._a);\n config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);\n\n getParsingFlags(config).rfc2822 = true;\n } else {\n config._isValid = false;\n }\n }\n\n // date from 1) ASP.NET, 2) ISO, 3) RFC 2822 formats, or 4) optional fallback if parsing isn't strict\n function configFromString(config) {\n var matched = aspNetJsonRegex.exec(config._i);\n if (matched !== null) {\n config._d = new Date(+matched[1]);\n return;\n }\n\n configFromISO(config);\n if (config._isValid === false) {\n delete config._isValid;\n } else {\n return;\n }\n\n configFromRFC2822(config);\n if (config._isValid === false) {\n delete config._isValid;\n } else {\n return;\n }\n\n if (config._strict) {\n config._isValid = false;\n } else {\n // Final attempt, use Input Fallback\n hooks.createFromInputFallback(config);\n }\n }\n\n hooks.createFromInputFallback = deprecate(\n 'value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), ' +\n 'which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are ' +\n 'discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.',\n function (config) {\n config._d = new Date(config._i + (config._useUTC ? ' UTC' : ''));\n }\n );\n\n // Pick the first defined of two or three arguments.\n function defaults(a, b, c) {\n if (a != null) {\n return a;\n }\n if (b != null) {\n return b;\n }\n return c;\n }\n\n function currentDateArray(config) {\n // hooks is actually the exported moment object\n var nowValue = new Date(hooks.now());\n if (config._useUTC) {\n return [\n nowValue.getUTCFullYear(),\n nowValue.getUTCMonth(),\n nowValue.getUTCDate(),\n ];\n }\n return [nowValue.getFullYear(), nowValue.getMonth(), nowValue.getDate()];\n }\n\n // convert an array to a date.\n // the array should mirror the parameters below\n // note: all values past the year are optional and will default to the lowest possible value.\n // [year, month, day , hour, minute, second, millisecond]\n function configFromArray(config) {\n var i,\n date,\n input = [],\n currentDate,\n expectedWeekday,\n yearToUse;\n\n if (config._d) {\n return;\n }\n\n currentDate = currentDateArray(config);\n\n //compute day of the year from weeks and weekdays\n if (config._w && config._a[DATE] == null && config._a[MONTH] == null) {\n dayOfYearFromWeekInfo(config);\n }\n\n //if the day of the year is set, figure out what it is\n if (config._dayOfYear != null) {\n yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);\n\n if (\n config._dayOfYear > daysInYear(yearToUse) ||\n config._dayOfYear === 0\n ) {\n getParsingFlags(config)._overflowDayOfYear = true;\n }\n\n date = createUTCDate(yearToUse, 0, config._dayOfYear);\n config._a[MONTH] = date.getUTCMonth();\n config._a[DATE] = date.getUTCDate();\n }\n\n // Default to current date.\n // * if no year, month, day of month are given, default to today\n // * if day of month is given, default month and year\n // * if month is given, default only year\n // * if year is given, don't default anything\n for (i = 0; i < 3 && config._a[i] == null; ++i) {\n config._a[i] = input[i] = currentDate[i];\n }\n\n // Zero out whatever was not defaulted, including time\n for (; i < 7; i++) {\n config._a[i] = input[i] =\n config._a[i] == null ? (i === 2 ? 1 : 0) : config._a[i];\n }\n\n // Check for 24:00:00.000\n if (\n config._a[HOUR] === 24 &&\n config._a[MINUTE] === 0 &&\n config._a[SECOND] === 0 &&\n config._a[MILLISECOND] === 0\n ) {\n config._nextDay = true;\n config._a[HOUR] = 0;\n }\n\n config._d = (config._useUTC ? createUTCDate : createDate).apply(\n null,\n input\n );\n expectedWeekday = config._useUTC\n ? config._d.getUTCDay()\n : config._d.getDay();\n\n // Apply timezone offset from input. The actual utcOffset can be changed\n // with parseZone.\n if (config._tzm != null) {\n config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);\n }\n\n if (config._nextDay) {\n config._a[HOUR] = 24;\n }\n\n // check for mismatching day of week\n if (\n config._w &&\n typeof config._w.d !== 'undefined' &&\n config._w.d !== expectedWeekday\n ) {\n getParsingFlags(config).weekdayMismatch = true;\n }\n }\n\n function dayOfYearFromWeekInfo(config) {\n var w, weekYear, week, weekday, dow, doy, temp, weekdayOverflow, curWeek;\n\n w = config._w;\n if (w.GG != null || w.W != null || w.E != null) {\n dow = 1;\n doy = 4;\n\n // TODO: We need to take the current isoWeekYear, but that depends on\n // how we interpret now (local, utc, fixed offset). So create\n // a now version of current config (take local/utc/offset flags, and\n // create now).\n weekYear = defaults(\n w.GG,\n config._a[YEAR],\n weekOfYear(createLocal(), 1, 4).year\n );\n week = defaults(w.W, 1);\n weekday = defaults(w.E, 1);\n if (weekday < 1 || weekday > 7) {\n weekdayOverflow = true;\n }\n } else {\n dow = config._locale._week.dow;\n doy = config._locale._week.doy;\n\n curWeek = weekOfYear(createLocal(), dow, doy);\n\n weekYear = defaults(w.gg, config._a[YEAR], curWeek.year);\n\n // Default to current week.\n week = defaults(w.w, curWeek.week);\n\n if (w.d != null) {\n // weekday -- low day numbers are considered next week\n weekday = w.d;\n if (weekday < 0 || weekday > 6) {\n weekdayOverflow = true;\n }\n } else if (w.e != null) {\n // local weekday -- counting starts from beginning of week\n weekday = w.e + dow;\n if (w.e < 0 || w.e > 6) {\n weekdayOverflow = true;\n }\n } else {\n // default to beginning of week\n weekday = dow;\n }\n }\n if (week < 1 || week > weeksInYear(weekYear, dow, doy)) {\n getParsingFlags(config)._overflowWeeks = true;\n } else if (weekdayOverflow != null) {\n getParsingFlags(config)._overflowWeekday = true;\n } else {\n temp = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy);\n config._a[YEAR] = temp.year;\n config._dayOfYear = temp.dayOfYear;\n }\n }\n\n // constant that refers to the ISO standard\n hooks.ISO_8601 = function () {};\n\n // constant that refers to the RFC 2822 form\n hooks.RFC_2822 = function () {};\n\n // date from string and format string\n function configFromStringAndFormat(config) {\n // TODO: Move this to another part of the creation flow to prevent circular deps\n if (config._f === hooks.ISO_8601) {\n configFromISO(config);\n return;\n }\n if (config._f === hooks.RFC_2822) {\n configFromRFC2822(config);\n return;\n }\n config._a = [];\n getParsingFlags(config).empty = true;\n\n // This array is used to make a Date, either with `new Date` or `Date.UTC`\n var string = '' + config._i,\n i,\n parsedInput,\n tokens,\n token,\n skipped,\n stringLength = string.length,\n totalParsedInputLength = 0,\n era,\n tokenLen;\n\n tokens =\n expandFormat(config._f, config._locale).match(formattingTokens) || [];\n tokenLen = tokens.length;\n for (i = 0; i < tokenLen; i++) {\n token = tokens[i];\n parsedInput = (string.match(getParseRegexForToken(token, config)) ||\n [])[0];\n if (parsedInput) {\n skipped = string.substr(0, string.indexOf(parsedInput));\n if (skipped.length > 0) {\n getParsingFlags(config).unusedInput.push(skipped);\n }\n string = string.slice(\n string.indexOf(parsedInput) + parsedInput.length\n );\n totalParsedInputLength += parsedInput.length;\n }\n // don't parse if it's not a known token\n if (formatTokenFunctions[token]) {\n if (parsedInput) {\n getParsingFlags(config).empty = false;\n } else {\n getParsingFlags(config).unusedTokens.push(token);\n }\n addTimeToArrayFromToken(token, parsedInput, config);\n } else if (config._strict && !parsedInput) {\n getParsingFlags(config).unusedTokens.push(token);\n }\n }\n\n // add remaining unparsed input length to the string\n getParsingFlags(config).charsLeftOver =\n stringLength - totalParsedInputLength;\n if (string.length > 0) {\n getParsingFlags(config).unusedInput.push(string);\n }\n\n // clear _12h flag if hour is <= 12\n if (\n config._a[HOUR] <= 12 &&\n getParsingFlags(config).bigHour === true &&\n config._a[HOUR] > 0\n ) {\n getParsingFlags(config).bigHour = undefined;\n }\n\n getParsingFlags(config).parsedDateParts = config._a.slice(0);\n getParsingFlags(config).meridiem = config._meridiem;\n // handle meridiem\n config._a[HOUR] = meridiemFixWrap(\n config._locale,\n config._a[HOUR],\n config._meridiem\n );\n\n // handle era\n era = getParsingFlags(config).era;\n if (era !== null) {\n config._a[YEAR] = config._locale.erasConvertYear(era, config._a[YEAR]);\n }\n\n configFromArray(config);\n checkOverflow(config);\n }\n\n function meridiemFixWrap(locale, hour, meridiem) {\n var isPm;\n\n if (meridiem == null) {\n // nothing to do\n return hour;\n }\n if (locale.meridiemHour != null) {\n return locale.meridiemHour(hour, meridiem);\n } else if (locale.isPM != null) {\n // Fallback\n isPm = locale.isPM(meridiem);\n if (isPm && hour < 12) {\n hour += 12;\n }\n if (!isPm && hour === 12) {\n hour = 0;\n }\n return hour;\n } else {\n // this is not supposed to happen\n return hour;\n }\n }\n\n // date from string and array of format strings\n function configFromStringAndArray(config) {\n var tempConfig,\n bestMoment,\n scoreToBeat,\n i,\n currentScore,\n validFormatFound,\n bestFormatIsValid = false,\n configfLen = config._f.length;\n\n if (configfLen === 0) {\n getParsingFlags(config).invalidFormat = true;\n config._d = new Date(NaN);\n return;\n }\n\n for (i = 0; i < configfLen; i++) {\n currentScore = 0;\n validFormatFound = false;\n tempConfig = copyConfig({}, config);\n if (config._useUTC != null) {\n tempConfig._useUTC = config._useUTC;\n }\n tempConfig._f = config._f[i];\n configFromStringAndFormat(tempConfig);\n\n if (isValid(tempConfig)) {\n validFormatFound = true;\n }\n\n // if there is any input that was not parsed add a penalty for that format\n currentScore += getParsingFlags(tempConfig).charsLeftOver;\n\n //or tokens\n currentScore += getParsingFlags(tempConfig).unusedTokens.length * 10;\n\n getParsingFlags(tempConfig).score = currentScore;\n\n if (!bestFormatIsValid) {\n if (\n scoreToBeat == null ||\n currentScore < scoreToBeat ||\n validFormatFound\n ) {\n scoreToBeat = currentScore;\n bestMoment = tempConfig;\n if (validFormatFound) {\n bestFormatIsValid = true;\n }\n }\n } else {\n if (currentScore < scoreToBeat) {\n scoreToBeat = currentScore;\n bestMoment = tempConfig;\n }\n }\n }\n\n extend(config, bestMoment || tempConfig);\n }\n\n function configFromObject(config) {\n if (config._d) {\n return;\n }\n\n var i = normalizeObjectUnits(config._i),\n dayOrDate = i.day === undefined ? i.date : i.day;\n config._a = map(\n [i.year, i.month, dayOrDate, i.hour, i.minute, i.second, i.millisecond],\n function (obj) {\n return obj && parseInt(obj, 10);\n }\n );\n\n configFromArray(config);\n }\n\n function createFromConfig(config) {\n var res = new Moment(checkOverflow(prepareConfig(config)));\n if (res._nextDay) {\n // Adding is smart enough around DST\n res.add(1, 'd');\n res._nextDay = undefined;\n }\n\n return res;\n }\n\n function prepareConfig(config) {\n var input = config._i,\n format = config._f;\n\n config._locale = config._locale || getLocale(config._l);\n\n if (input === null || (format === undefined && input === '')) {\n return createInvalid({ nullInput: true });\n }\n\n if (typeof input === 'string') {\n config._i = input = config._locale.preparse(input);\n }\n\n if (isMoment(input)) {\n return new Moment(checkOverflow(input));\n } else if (isDate(input)) {\n config._d = input;\n } else if (isArray(format)) {\n configFromStringAndArray(config);\n } else if (format) {\n configFromStringAndFormat(config);\n } else {\n configFromInput(config);\n }\n\n if (!isValid(config)) {\n config._d = null;\n }\n\n return config;\n }\n\n function configFromInput(config) {\n var input = config._i;\n if (isUndefined(input)) {\n config._d = new Date(hooks.now());\n } else if (isDate(input)) {\n config._d = new Date(input.valueOf());\n } else if (typeof input === 'string') {\n configFromString(config);\n } else if (isArray(input)) {\n config._a = map(input.slice(0), function (obj) {\n return parseInt(obj, 10);\n });\n configFromArray(config);\n } else if (isObject(input)) {\n configFromObject(config);\n } else if (isNumber(input)) {\n // from milliseconds\n config._d = new Date(input);\n } else {\n hooks.createFromInputFallback(config);\n }\n }\n\n function createLocalOrUTC(input, format, locale, strict, isUTC) {\n var c = {};\n\n if (format === true || format === false) {\n strict = format;\n format = undefined;\n }\n\n if (locale === true || locale === false) {\n strict = locale;\n locale = undefined;\n }\n\n if (\n (isObject(input) && isObjectEmpty(input)) ||\n (isArray(input) && input.length === 0)\n ) {\n input = undefined;\n }\n // object construction must be done this way.\n // https://github.com/moment/moment/issues/1423\n c._isAMomentObject = true;\n c._useUTC = c._isUTC = isUTC;\n c._l = locale;\n c._i = input;\n c._f = format;\n c._strict = strict;\n\n return createFromConfig(c);\n }\n\n function createLocal(input, format, locale, strict) {\n return createLocalOrUTC(input, format, locale, strict, false);\n }\n\n var prototypeMin = deprecate(\n 'moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/',\n function () {\n var other = createLocal.apply(null, arguments);\n if (this.isValid() && other.isValid()) {\n return other < this ? this : other;\n } else {\n return createInvalid();\n }\n }\n ),\n prototypeMax = deprecate(\n 'moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/',\n function () {\n var other = createLocal.apply(null, arguments);\n if (this.isValid() && other.isValid()) {\n return other > this ? this : other;\n } else {\n return createInvalid();\n }\n }\n );\n\n // Pick a moment m from moments so that m[fn](other) is true for all\n // other. This relies on the function fn to be transitive.\n //\n // moments should either be an array of moment objects or an array, whose\n // first element is an array of moment objects.\n function pickBy(fn, moments) {\n var res, i;\n if (moments.length === 1 && isArray(moments[0])) {\n moments = moments[0];\n }\n if (!moments.length) {\n return createLocal();\n }\n res = moments[0];\n for (i = 1; i < moments.length; ++i) {\n if (!moments[i].isValid() || moments[i][fn](res)) {\n res = moments[i];\n }\n }\n return res;\n }\n\n // TODO: Use [].sort instead?\n function min() {\n var args = [].slice.call(arguments, 0);\n\n return pickBy('isBefore', args);\n }\n\n function max() {\n var args = [].slice.call(arguments, 0);\n\n return pickBy('isAfter', args);\n }\n\n var now = function () {\n return Date.now ? Date.now() : +new Date();\n };\n\n var ordering = [\n 'year',\n 'quarter',\n 'month',\n 'week',\n 'day',\n 'hour',\n 'minute',\n 'second',\n 'millisecond',\n ];\n\n function isDurationValid(m) {\n var key,\n unitHasDecimal = false,\n i,\n orderLen = ordering.length;\n for (key in m) {\n if (\n hasOwnProp(m, key) &&\n !(\n indexOf.call(ordering, key) !== -1 &&\n (m[key] == null || !isNaN(m[key]))\n )\n ) {\n return false;\n }\n }\n\n for (i = 0; i < orderLen; ++i) {\n if (m[ordering[i]]) {\n if (unitHasDecimal) {\n return false; // only allow non-integers for smallest unit\n }\n if (parseFloat(m[ordering[i]]) !== toInt(m[ordering[i]])) {\n unitHasDecimal = true;\n }\n }\n }\n\n return true;\n }\n\n function isValid$1() {\n return this._isValid;\n }\n\n function createInvalid$1() {\n return createDuration(NaN);\n }\n\n function Duration(duration) {\n var normalizedInput = normalizeObjectUnits(duration),\n years = normalizedInput.year || 0,\n quarters = normalizedInput.quarter || 0,\n months = normalizedInput.month || 0,\n weeks = normalizedInput.week || normalizedInput.isoWeek || 0,\n days = normalizedInput.day || 0,\n hours = normalizedInput.hour || 0,\n minutes = normalizedInput.minute || 0,\n seconds = normalizedInput.second || 0,\n milliseconds = normalizedInput.millisecond || 0;\n\n this._isValid = isDurationValid(normalizedInput);\n\n // representation for dateAddRemove\n this._milliseconds =\n +milliseconds +\n seconds * 1e3 + // 1000\n minutes * 6e4 + // 1000 * 60\n hours * 1000 * 60 * 60; //using 1000 * 60 * 60 instead of 36e5 to avoid floating point rounding errors https://github.com/moment/moment/issues/2978\n // Because of dateAddRemove treats 24 hours as different from a\n // day when working around DST, we need to store them separately\n this._days = +days + weeks * 7;\n // It is impossible to translate months into days without knowing\n // which months you are are talking about, so we have to store\n // it separately.\n this._months = +months + quarters * 3 + years * 12;\n\n this._data = {};\n\n this._locale = getLocale();\n\n this._bubble();\n }\n\n function isDuration(obj) {\n return obj instanceof Duration;\n }\n\n function absRound(number) {\n if (number < 0) {\n return Math.round(-1 * number) * -1;\n } else {\n return Math.round(number);\n }\n }\n\n // compare two arrays, return the number of differences\n function compareArrays(array1, array2, dontConvert) {\n var len = Math.min(array1.length, array2.length),\n lengthDiff = Math.abs(array1.length - array2.length),\n diffs = 0,\n i;\n for (i = 0; i < len; i++) {\n if (\n (dontConvert && array1[i] !== array2[i]) ||\n (!dontConvert && toInt(array1[i]) !== toInt(array2[i]))\n ) {\n diffs++;\n }\n }\n return diffs + lengthDiff;\n }\n\n // FORMATTING\n\n function offset(token, separator) {\n addFormatToken(token, 0, 0, function () {\n var offset = this.utcOffset(),\n sign = '+';\n if (offset < 0) {\n offset = -offset;\n sign = '-';\n }\n return (\n sign +\n zeroFill(~~(offset / 60), 2) +\n separator +\n zeroFill(~~offset % 60, 2)\n );\n });\n }\n\n offset('Z', ':');\n offset('ZZ', '');\n\n // PARSING\n\n addRegexToken('Z', matchShortOffset);\n addRegexToken('ZZ', matchShortOffset);\n addParseToken(['Z', 'ZZ'], function (input, array, config) {\n config._useUTC = true;\n config._tzm = offsetFromString(matchShortOffset, input);\n });\n\n // HELPERS\n\n // timezone chunker\n // '+10:00' > ['10', '00']\n // '-1530' > ['-15', '30']\n var chunkOffset = /([\\+\\-]|\\d\\d)/gi;\n\n function offsetFromString(matcher, string) {\n var matches = (string || '').match(matcher),\n chunk,\n parts,\n minutes;\n\n if (matches === null) {\n return null;\n }\n\n chunk = matches[matches.length - 1] || [];\n parts = (chunk + '').match(chunkOffset) || ['-', 0, 0];\n minutes = +(parts[1] * 60) + toInt(parts[2]);\n\n return minutes === 0 ? 0 : parts[0] === '+' ? minutes : -minutes;\n }\n\n // Return a moment from input, that is local/utc/zone equivalent to model.\n function cloneWithOffset(input, model) {\n var res, diff;\n if (model._isUTC) {\n res = model.clone();\n diff =\n (isMoment(input) || isDate(input)\n ? input.valueOf()\n : createLocal(input).valueOf()) - res.valueOf();\n // Use low-level api, because this fn is low-level api.\n res._d.setTime(res._d.valueOf() + diff);\n hooks.updateOffset(res, false);\n return res;\n } else {\n return createLocal(input).local();\n }\n }\n\n function getDateOffset(m) {\n // On Firefox.24 Date#getTimezoneOffset returns a floating point.\n // https://github.com/moment/moment/pull/1871\n return -Math.round(m._d.getTimezoneOffset());\n }\n\n // HOOKS\n\n // This function will be called whenever a moment is mutated.\n // It is intended to keep the offset in sync with the timezone.\n hooks.updateOffset = function () {};\n\n // MOMENTS\n\n // keepLocalTime = true means only change the timezone, without\n // affecting the local hour. So 5:31:26 +0300 --[utcOffset(2, true)]-->\n // 5:31:26 +0200 It is possible that 5:31:26 doesn't exist with offset\n // +0200, so we adjust the time as needed, to be valid.\n //\n // Keeping the time actually adds/subtracts (one hour)\n // from the actual represented time. That is why we call updateOffset\n // a second time. In case it wants us to change the offset again\n // _changeInProgress == true case, then we have to adjust, because\n // there is no such time in the given timezone.\n function getSetOffset(input, keepLocalTime, keepMinutes) {\n var offset = this._offset || 0,\n localAdjust;\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n if (input != null) {\n if (typeof input === 'string') {\n input = offsetFromString(matchShortOffset, input);\n if (input === null) {\n return this;\n }\n } else if (Math.abs(input) < 16 && !keepMinutes) {\n input = input * 60;\n }\n if (!this._isUTC && keepLocalTime) {\n localAdjust = getDateOffset(this);\n }\n this._offset = input;\n this._isUTC = true;\n if (localAdjust != null) {\n this.add(localAdjust, 'm');\n }\n if (offset !== input) {\n if (!keepLocalTime || this._changeInProgress) {\n addSubtract(\n this,\n createDuration(input - offset, 'm'),\n 1,\n false\n );\n } else if (!this._changeInProgress) {\n this._changeInProgress = true;\n hooks.updateOffset(this, true);\n this._changeInProgress = null;\n }\n }\n return this;\n } else {\n return this._isUTC ? offset : getDateOffset(this);\n }\n }\n\n function getSetZone(input, keepLocalTime) {\n if (input != null) {\n if (typeof input !== 'string') {\n input = -input;\n }\n\n this.utcOffset(input, keepLocalTime);\n\n return this;\n } else {\n return -this.utcOffset();\n }\n }\n\n function setOffsetToUTC(keepLocalTime) {\n return this.utcOffset(0, keepLocalTime);\n }\n\n function setOffsetToLocal(keepLocalTime) {\n if (this._isUTC) {\n this.utcOffset(0, keepLocalTime);\n this._isUTC = false;\n\n if (keepLocalTime) {\n this.subtract(getDateOffset(this), 'm');\n }\n }\n return this;\n }\n\n function setOffsetToParsedOffset() {\n if (this._tzm != null) {\n this.utcOffset(this._tzm, false, true);\n } else if (typeof this._i === 'string') {\n var tZone = offsetFromString(matchOffset, this._i);\n if (tZone != null) {\n this.utcOffset(tZone);\n } else {\n this.utcOffset(0, true);\n }\n }\n return this;\n }\n\n function hasAlignedHourOffset(input) {\n if (!this.isValid()) {\n return false;\n }\n input = input ? createLocal(input).utcOffset() : 0;\n\n return (this.utcOffset() - input) % 60 === 0;\n }\n\n function isDaylightSavingTime() {\n return (\n this.utcOffset() > this.clone().month(0).utcOffset() ||\n this.utcOffset() > this.clone().month(5).utcOffset()\n );\n }\n\n function isDaylightSavingTimeShifted() {\n if (!isUndefined(this._isDSTShifted)) {\n return this._isDSTShifted;\n }\n\n var c = {},\n other;\n\n copyConfig(c, this);\n c = prepareConfig(c);\n\n if (c._a) {\n other = c._isUTC ? createUTC(c._a) : createLocal(c._a);\n this._isDSTShifted =\n this.isValid() && compareArrays(c._a, other.toArray()) > 0;\n } else {\n this._isDSTShifted = false;\n }\n\n return this._isDSTShifted;\n }\n\n function isLocal() {\n return this.isValid() ? !this._isUTC : false;\n }\n\n function isUtcOffset() {\n return this.isValid() ? this._isUTC : false;\n }\n\n function isUtc() {\n return this.isValid() ? this._isUTC && this._offset === 0 : false;\n }\n\n // ASP.NET json date format regex\n var aspNetRegex = /^(-|\\+)?(?:(\\d*)[. ])?(\\d+):(\\d+)(?::(\\d+)(\\.\\d*)?)?$/,\n // from http://docs.closure-library.googlecode.com/git/closure_goog_date_date.js.source.html\n // somewhat more in line with 4.4.3.2 2004 spec, but allows decimal anywhere\n // and further modified to allow for strings containing both week and day\n isoRegex =\n /^(-|\\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;\n\n function createDuration(input, key) {\n var duration = input,\n // matching against regexp is expensive, do it on demand\n match = null,\n sign,\n ret,\n diffRes;\n\n if (isDuration(input)) {\n duration = {\n ms: input._milliseconds,\n d: input._days,\n M: input._months,\n };\n } else if (isNumber(input) || !isNaN(+input)) {\n duration = {};\n if (key) {\n duration[key] = +input;\n } else {\n duration.milliseconds = +input;\n }\n } else if ((match = aspNetRegex.exec(input))) {\n sign = match[1] === '-' ? -1 : 1;\n duration = {\n y: 0,\n d: toInt(match[DATE]) * sign,\n h: toInt(match[HOUR]) * sign,\n m: toInt(match[MINUTE]) * sign,\n s: toInt(match[SECOND]) * sign,\n ms: toInt(absRound(match[MILLISECOND] * 1000)) * sign, // the millisecond decimal point is included in the match\n };\n } else if ((match = isoRegex.exec(input))) {\n sign = match[1] === '-' ? -1 : 1;\n duration = {\n y: parseIso(match[2], sign),\n M: parseIso(match[3], sign),\n w: parseIso(match[4], sign),\n d: parseIso(match[5], sign),\n h: parseIso(match[6], sign),\n m: parseIso(match[7], sign),\n s: parseIso(match[8], sign),\n };\n } else if (duration == null) {\n // checks for null or undefined\n duration = {};\n } else if (\n typeof duration === 'object' &&\n ('from' in duration || 'to' in duration)\n ) {\n diffRes = momentsDifference(\n createLocal(duration.from),\n createLocal(duration.to)\n );\n\n duration = {};\n duration.ms = diffRes.milliseconds;\n duration.M = diffRes.months;\n }\n\n ret = new Duration(duration);\n\n if (isDuration(input) && hasOwnProp(input, '_locale')) {\n ret._locale = input._locale;\n }\n\n if (isDuration(input) && hasOwnProp(input, '_isValid')) {\n ret._isValid = input._isValid;\n }\n\n return ret;\n }\n\n createDuration.fn = Duration.prototype;\n createDuration.invalid = createInvalid$1;\n\n function parseIso(inp, sign) {\n // We'd normally use ~~inp for this, but unfortunately it also\n // converts floats to ints.\n // inp may be undefined, so careful calling replace on it.\n var res = inp && parseFloat(inp.replace(',', '.'));\n // apply sign while we're at it\n return (isNaN(res) ? 0 : res) * sign;\n }\n\n function positiveMomentsDifference(base, other) {\n var res = {};\n\n res.months =\n other.month() - base.month() + (other.year() - base.year()) * 12;\n if (base.clone().add(res.months, 'M').isAfter(other)) {\n --res.months;\n }\n\n res.milliseconds = +other - +base.clone().add(res.months, 'M');\n\n return res;\n }\n\n function momentsDifference(base, other) {\n var res;\n if (!(base.isValid() && other.isValid())) {\n return { milliseconds: 0, months: 0 };\n }\n\n other = cloneWithOffset(other, base);\n if (base.isBefore(other)) {\n res = positiveMomentsDifference(base, other);\n } else {\n res = positiveMomentsDifference(other, base);\n res.milliseconds = -res.milliseconds;\n res.months = -res.months;\n }\n\n return res;\n }\n\n // TODO: remove 'name' arg after deprecation is removed\n function createAdder(direction, name) {\n return function (val, period) {\n var dur, tmp;\n //invert the arguments, but complain about it\n if (period !== null && !isNaN(+period)) {\n deprecateSimple(\n name,\n 'moment().' +\n name +\n '(period, number) is deprecated. Please use moment().' +\n name +\n '(number, period). ' +\n 'See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info.'\n );\n tmp = val;\n val = period;\n period = tmp;\n }\n\n dur = createDuration(val, period);\n addSubtract(this, dur, direction);\n return this;\n };\n }\n\n function addSubtract(mom, duration, isAdding, updateOffset) {\n var milliseconds = duration._milliseconds,\n days = absRound(duration._days),\n months = absRound(duration._months);\n\n if (!mom.isValid()) {\n // No op\n return;\n }\n\n updateOffset = updateOffset == null ? true : updateOffset;\n\n if (months) {\n setMonth(mom, get(mom, 'Month') + months * isAdding);\n }\n if (days) {\n set$1(mom, 'Date', get(mom, 'Date') + days * isAdding);\n }\n if (milliseconds) {\n mom._d.setTime(mom._d.valueOf() + milliseconds * isAdding);\n }\n if (updateOffset) {\n hooks.updateOffset(mom, days || months);\n }\n }\n\n var add = createAdder(1, 'add'),\n subtract = createAdder(-1, 'subtract');\n\n function isString(input) {\n return typeof input === 'string' || input instanceof String;\n }\n\n // type MomentInput = Moment | Date | string | number | (number | string)[] | MomentInputObject | void; // null | undefined\n function isMomentInput(input) {\n return (\n isMoment(input) ||\n isDate(input) ||\n isString(input) ||\n isNumber(input) ||\n isNumberOrStringArray(input) ||\n isMomentInputObject(input) ||\n input === null ||\n input === undefined\n );\n }\n\n function isMomentInputObject(input) {\n var objectTest = isObject(input) && !isObjectEmpty(input),\n propertyTest = false,\n properties = [\n 'years',\n 'year',\n 'y',\n 'months',\n 'month',\n 'M',\n 'days',\n 'day',\n 'd',\n 'dates',\n 'date',\n 'D',\n 'hours',\n 'hour',\n 'h',\n 'minutes',\n 'minute',\n 'm',\n 'seconds',\n 'second',\n 's',\n 'milliseconds',\n 'millisecond',\n 'ms',\n ],\n i,\n property,\n propertyLen = properties.length;\n\n for (i = 0; i < propertyLen; i += 1) {\n property = properties[i];\n propertyTest = propertyTest || hasOwnProp(input, property);\n }\n\n return objectTest && propertyTest;\n }\n\n function isNumberOrStringArray(input) {\n var arrayTest = isArray(input),\n dataTypeTest = false;\n if (arrayTest) {\n dataTypeTest =\n input.filter(function (item) {\n return !isNumber(item) && isString(input);\n }).length === 0;\n }\n return arrayTest && dataTypeTest;\n }\n\n function isCalendarSpec(input) {\n var objectTest = isObject(input) && !isObjectEmpty(input),\n propertyTest = false,\n properties = [\n 'sameDay',\n 'nextDay',\n 'lastDay',\n 'nextWeek',\n 'lastWeek',\n 'sameElse',\n ],\n i,\n property;\n\n for (i = 0; i < properties.length; i += 1) {\n property = properties[i];\n propertyTest = propertyTest || hasOwnProp(input, property);\n }\n\n return objectTest && propertyTest;\n }\n\n function getCalendarFormat(myMoment, now) {\n var diff = myMoment.diff(now, 'days', true);\n return diff < -6\n ? 'sameElse'\n : diff < -1\n ? 'lastWeek'\n : diff < 0\n ? 'lastDay'\n : diff < 1\n ? 'sameDay'\n : diff < 2\n ? 'nextDay'\n : diff < 7\n ? 'nextWeek'\n : 'sameElse';\n }\n\n function calendar$1(time, formats) {\n // Support for single parameter, formats only overload to the calendar function\n if (arguments.length === 1) {\n if (!arguments[0]) {\n time = undefined;\n formats = undefined;\n } else if (isMomentInput(arguments[0])) {\n time = arguments[0];\n formats = undefined;\n } else if (isCalendarSpec(arguments[0])) {\n formats = arguments[0];\n time = undefined;\n }\n }\n // We want to compare the start of today, vs this.\n // Getting start-of-today depends on whether we're local/utc/offset or not.\n var now = time || createLocal(),\n sod = cloneWithOffset(now, this).startOf('day'),\n format = hooks.calendarFormat(this, sod) || 'sameElse',\n output =\n formats &&\n (isFunction(formats[format])\n ? formats[format].call(this, now)\n : formats[format]);\n\n return this.format(\n output || this.localeData().calendar(format, this, createLocal(now))\n );\n }\n\n function clone() {\n return new Moment(this);\n }\n\n function isAfter(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input);\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() > localInput.valueOf();\n } else {\n return localInput.valueOf() < this.clone().startOf(units).valueOf();\n }\n }\n\n function isBefore(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input);\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() < localInput.valueOf();\n } else {\n return this.clone().endOf(units).valueOf() < localInput.valueOf();\n }\n }\n\n function isBetween(from, to, units, inclusivity) {\n var localFrom = isMoment(from) ? from : createLocal(from),\n localTo = isMoment(to) ? to : createLocal(to);\n if (!(this.isValid() && localFrom.isValid() && localTo.isValid())) {\n return false;\n }\n inclusivity = inclusivity || '()';\n return (\n (inclusivity[0] === '('\n ? this.isAfter(localFrom, units)\n : !this.isBefore(localFrom, units)) &&\n (inclusivity[1] === ')'\n ? this.isBefore(localTo, units)\n : !this.isAfter(localTo, units))\n );\n }\n\n function isSame(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input),\n inputMs;\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() === localInput.valueOf();\n } else {\n inputMs = localInput.valueOf();\n return (\n this.clone().startOf(units).valueOf() <= inputMs &&\n inputMs <= this.clone().endOf(units).valueOf()\n );\n }\n }\n\n function isSameOrAfter(input, units) {\n return this.isSame(input, units) || this.isAfter(input, units);\n }\n\n function isSameOrBefore(input, units) {\n return this.isSame(input, units) || this.isBefore(input, units);\n }\n\n function diff(input, units, asFloat) {\n var that, zoneDelta, output;\n\n if (!this.isValid()) {\n return NaN;\n }\n\n that = cloneWithOffset(input, this);\n\n if (!that.isValid()) {\n return NaN;\n }\n\n zoneDelta = (that.utcOffset() - this.utcOffset()) * 6e4;\n\n units = normalizeUnits(units);\n\n switch (units) {\n case 'year':\n output = monthDiff(this, that) / 12;\n break;\n case 'month':\n output = monthDiff(this, that);\n break;\n case 'quarter':\n output = monthDiff(this, that) / 3;\n break;\n case 'second':\n output = (this - that) / 1e3;\n break; // 1000\n case 'minute':\n output = (this - that) / 6e4;\n break; // 1000 * 60\n case 'hour':\n output = (this - that) / 36e5;\n break; // 1000 * 60 * 60\n case 'day':\n output = (this - that - zoneDelta) / 864e5;\n break; // 1000 * 60 * 60 * 24, negate dst\n case 'week':\n output = (this - that - zoneDelta) / 6048e5;\n break; // 1000 * 60 * 60 * 24 * 7, negate dst\n default:\n output = this - that;\n }\n\n return asFloat ? output : absFloor(output);\n }\n\n function monthDiff(a, b) {\n if (a.date() < b.date()) {\n // end-of-month calculations work correct when the start month has more\n // days than the end month.\n return -monthDiff(b, a);\n }\n // difference in months\n var wholeMonthDiff = (b.year() - a.year()) * 12 + (b.month() - a.month()),\n // b is in (anchor - 1 month, anchor + 1 month)\n anchor = a.clone().add(wholeMonthDiff, 'months'),\n anchor2,\n adjust;\n\n if (b - anchor < 0) {\n anchor2 = a.clone().add(wholeMonthDiff - 1, 'months');\n // linear across the month\n adjust = (b - anchor) / (anchor - anchor2);\n } else {\n anchor2 = a.clone().add(wholeMonthDiff + 1, 'months');\n // linear across the month\n adjust = (b - anchor) / (anchor2 - anchor);\n }\n\n //check for negative zero, return zero if negative zero\n return -(wholeMonthDiff + adjust) || 0;\n }\n\n hooks.defaultFormat = 'YYYY-MM-DDTHH:mm:ssZ';\n hooks.defaultFormatUtc = 'YYYY-MM-DDTHH:mm:ss[Z]';\n\n function toString() {\n return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');\n }\n\n function toISOString(keepOffset) {\n if (!this.isValid()) {\n return null;\n }\n var utc = keepOffset !== true,\n m = utc ? this.clone().utc() : this;\n if (m.year() < 0 || m.year() > 9999) {\n return formatMoment(\n m,\n utc\n ? 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]'\n : 'YYYYYY-MM-DD[T]HH:mm:ss.SSSZ'\n );\n }\n if (isFunction(Date.prototype.toISOString)) {\n // native implementation is ~50x faster, use it when we can\n if (utc) {\n return this.toDate().toISOString();\n } else {\n return new Date(this.valueOf() + this.utcOffset() * 60 * 1000)\n .toISOString()\n .replace('Z', formatMoment(m, 'Z'));\n }\n }\n return formatMoment(\n m,\n utc ? 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYY-MM-DD[T]HH:mm:ss.SSSZ'\n );\n }\n\n /**\n * Return a human readable representation of a moment that can\n * also be evaluated to get a new moment which is the same\n *\n * @link https://nodejs.org/dist/latest/docs/api/util.html#util_custom_inspect_function_on_objects\n */\n function inspect() {\n if (!this.isValid()) {\n return 'moment.invalid(/* ' + this._i + ' */)';\n }\n var func = 'moment',\n zone = '',\n prefix,\n year,\n datetime,\n suffix;\n if (!this.isLocal()) {\n func = this.utcOffset() === 0 ? 'moment.utc' : 'moment.parseZone';\n zone = 'Z';\n }\n prefix = '[' + func + '(\"]';\n year = 0 <= this.year() && this.year() <= 9999 ? 'YYYY' : 'YYYYYY';\n datetime = '-MM-DD[T]HH:mm:ss.SSS';\n suffix = zone + '[\")]';\n\n return this.format(prefix + year + datetime + suffix);\n }\n\n function format(inputString) {\n if (!inputString) {\n inputString = this.isUtc()\n ? hooks.defaultFormatUtc\n : hooks.defaultFormat;\n }\n var output = formatMoment(this, inputString);\n return this.localeData().postformat(output);\n }\n\n function from(time, withoutSuffix) {\n if (\n this.isValid() &&\n ((isMoment(time) && time.isValid()) || createLocal(time).isValid())\n ) {\n return createDuration({ to: this, from: time })\n .locale(this.locale())\n .humanize(!withoutSuffix);\n } else {\n return this.localeData().invalidDate();\n }\n }\n\n function fromNow(withoutSuffix) {\n return this.from(createLocal(), withoutSuffix);\n }\n\n function to(time, withoutSuffix) {\n if (\n this.isValid() &&\n ((isMoment(time) && time.isValid()) || createLocal(time).isValid())\n ) {\n return createDuration({ from: this, to: time })\n .locale(this.locale())\n .humanize(!withoutSuffix);\n } else {\n return this.localeData().invalidDate();\n }\n }\n\n function toNow(withoutSuffix) {\n return this.to(createLocal(), withoutSuffix);\n }\n\n // If passed a locale key, it will set the locale for this\n // instance. Otherwise, it will return the locale configuration\n // variables for this instance.\n function locale(key) {\n var newLocaleData;\n\n if (key === undefined) {\n return this._locale._abbr;\n } else {\n newLocaleData = getLocale(key);\n if (newLocaleData != null) {\n this._locale = newLocaleData;\n }\n return this;\n }\n }\n\n var lang = deprecate(\n 'moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.',\n function (key) {\n if (key === undefined) {\n return this.localeData();\n } else {\n return this.locale(key);\n }\n }\n );\n\n function localeData() {\n return this._locale;\n }\n\n var MS_PER_SECOND = 1000,\n MS_PER_MINUTE = 60 * MS_PER_SECOND,\n MS_PER_HOUR = 60 * MS_PER_MINUTE,\n MS_PER_400_YEARS = (365 * 400 + 97) * 24 * MS_PER_HOUR;\n\n // actual modulo - handles negative numbers (for dates before 1970):\n function mod$1(dividend, divisor) {\n return ((dividend % divisor) + divisor) % divisor;\n }\n\n function localStartOfDate(y, m, d) {\n // the date constructor remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n return new Date(y + 400, m, d) - MS_PER_400_YEARS;\n } else {\n return new Date(y, m, d).valueOf();\n }\n }\n\n function utcStartOfDate(y, m, d) {\n // Date.UTC remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n return Date.UTC(y + 400, m, d) - MS_PER_400_YEARS;\n } else {\n return Date.UTC(y, m, d);\n }\n }\n\n function startOf(units) {\n var time, startOfDate;\n units = normalizeUnits(units);\n if (units === undefined || units === 'millisecond' || !this.isValid()) {\n return this;\n }\n\n startOfDate = this._isUTC ? utcStartOfDate : localStartOfDate;\n\n switch (units) {\n case 'year':\n time = startOfDate(this.year(), 0, 1);\n break;\n case 'quarter':\n time = startOfDate(\n this.year(),\n this.month() - (this.month() % 3),\n 1\n );\n break;\n case 'month':\n time = startOfDate(this.year(), this.month(), 1);\n break;\n case 'week':\n time = startOfDate(\n this.year(),\n this.month(),\n this.date() - this.weekday()\n );\n break;\n case 'isoWeek':\n time = startOfDate(\n this.year(),\n this.month(),\n this.date() - (this.isoWeekday() - 1)\n );\n break;\n case 'day':\n case 'date':\n time = startOfDate(this.year(), this.month(), this.date());\n break;\n case 'hour':\n time = this._d.valueOf();\n time -= mod$1(\n time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE),\n MS_PER_HOUR\n );\n break;\n case 'minute':\n time = this._d.valueOf();\n time -= mod$1(time, MS_PER_MINUTE);\n break;\n case 'second':\n time = this._d.valueOf();\n time -= mod$1(time, MS_PER_SECOND);\n break;\n }\n\n this._d.setTime(time);\n hooks.updateOffset(this, true);\n return this;\n }\n\n function endOf(units) {\n var time, startOfDate;\n units = normalizeUnits(units);\n if (units === undefined || units === 'millisecond' || !this.isValid()) {\n return this;\n }\n\n startOfDate = this._isUTC ? utcStartOfDate : localStartOfDate;\n\n switch (units) {\n case 'year':\n time = startOfDate(this.year() + 1, 0, 1) - 1;\n break;\n case 'quarter':\n time =\n startOfDate(\n this.year(),\n this.month() - (this.month() % 3) + 3,\n 1\n ) - 1;\n break;\n case 'month':\n time = startOfDate(this.year(), this.month() + 1, 1) - 1;\n break;\n case 'week':\n time =\n startOfDate(\n this.year(),\n this.month(),\n this.date() - this.weekday() + 7\n ) - 1;\n break;\n case 'isoWeek':\n time =\n startOfDate(\n this.year(),\n this.month(),\n this.date() - (this.isoWeekday() - 1) + 7\n ) - 1;\n break;\n case 'day':\n case 'date':\n time = startOfDate(this.year(), this.month(), this.date() + 1) - 1;\n break;\n case 'hour':\n time = this._d.valueOf();\n time +=\n MS_PER_HOUR -\n mod$1(\n time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE),\n MS_PER_HOUR\n ) -\n 1;\n break;\n case 'minute':\n time = this._d.valueOf();\n time += MS_PER_MINUTE - mod$1(time, MS_PER_MINUTE) - 1;\n break;\n case 'second':\n time = this._d.valueOf();\n time += MS_PER_SECOND - mod$1(time, MS_PER_SECOND) - 1;\n break;\n }\n\n this._d.setTime(time);\n hooks.updateOffset(this, true);\n return this;\n }\n\n function valueOf() {\n return this._d.valueOf() - (this._offset || 0) * 60000;\n }\n\n function unix() {\n return Math.floor(this.valueOf() / 1000);\n }\n\n function toDate() {\n return new Date(this.valueOf());\n }\n\n function toArray() {\n var m = this;\n return [\n m.year(),\n m.month(),\n m.date(),\n m.hour(),\n m.minute(),\n m.second(),\n m.millisecond(),\n ];\n }\n\n function toObject() {\n var m = this;\n return {\n years: m.year(),\n months: m.month(),\n date: m.date(),\n hours: m.hours(),\n minutes: m.minutes(),\n seconds: m.seconds(),\n milliseconds: m.milliseconds(),\n };\n }\n\n function toJSON() {\n // new Date(NaN).toJSON() === null\n return this.isValid() ? this.toISOString() : null;\n }\n\n function isValid$2() {\n return isValid(this);\n }\n\n function parsingFlags() {\n return extend({}, getParsingFlags(this));\n }\n\n function invalidAt() {\n return getParsingFlags(this).overflow;\n }\n\n function creationData() {\n return {\n input: this._i,\n format: this._f,\n locale: this._locale,\n isUTC: this._isUTC,\n strict: this._strict,\n };\n }\n\n addFormatToken('N', 0, 0, 'eraAbbr');\n addFormatToken('NN', 0, 0, 'eraAbbr');\n addFormatToken('NNN', 0, 0, 'eraAbbr');\n addFormatToken('NNNN', 0, 0, 'eraName');\n addFormatToken('NNNNN', 0, 0, 'eraNarrow');\n\n addFormatToken('y', ['y', 1], 'yo', 'eraYear');\n addFormatToken('y', ['yy', 2], 0, 'eraYear');\n addFormatToken('y', ['yyy', 3], 0, 'eraYear');\n addFormatToken('y', ['yyyy', 4], 0, 'eraYear');\n\n addRegexToken('N', matchEraAbbr);\n addRegexToken('NN', matchEraAbbr);\n addRegexToken('NNN', matchEraAbbr);\n addRegexToken('NNNN', matchEraName);\n addRegexToken('NNNNN', matchEraNarrow);\n\n addParseToken(\n ['N', 'NN', 'NNN', 'NNNN', 'NNNNN'],\n function (input, array, config, token) {\n var era = config._locale.erasParse(input, token, config._strict);\n if (era) {\n getParsingFlags(config).era = era;\n } else {\n getParsingFlags(config).invalidEra = input;\n }\n }\n );\n\n addRegexToken('y', matchUnsigned);\n addRegexToken('yy', matchUnsigned);\n addRegexToken('yyy', matchUnsigned);\n addRegexToken('yyyy', matchUnsigned);\n addRegexToken('yo', matchEraYearOrdinal);\n\n addParseToken(['y', 'yy', 'yyy', 'yyyy'], YEAR);\n addParseToken(['yo'], function (input, array, config, token) {\n var match;\n if (config._locale._eraYearOrdinalRegex) {\n match = input.match(config._locale._eraYearOrdinalRegex);\n }\n\n if (config._locale.eraYearOrdinalParse) {\n array[YEAR] = config._locale.eraYearOrdinalParse(input, match);\n } else {\n array[YEAR] = parseInt(input, 10);\n }\n });\n\n function localeEras(m, format) {\n var i,\n l,\n date,\n eras = this._eras || getLocale('en')._eras;\n for (i = 0, l = eras.length; i < l; ++i) {\n switch (typeof eras[i].since) {\n case 'string':\n // truncate time\n date = hooks(eras[i].since).startOf('day');\n eras[i].since = date.valueOf();\n break;\n }\n\n switch (typeof eras[i].until) {\n case 'undefined':\n eras[i].until = +Infinity;\n break;\n case 'string':\n // truncate time\n date = hooks(eras[i].until).startOf('day').valueOf();\n eras[i].until = date.valueOf();\n break;\n }\n }\n return eras;\n }\n\n function localeErasParse(eraName, format, strict) {\n var i,\n l,\n eras = this.eras(),\n name,\n abbr,\n narrow;\n eraName = eraName.toUpperCase();\n\n for (i = 0, l = eras.length; i < l; ++i) {\n name = eras[i].name.toUpperCase();\n abbr = eras[i].abbr.toUpperCase();\n narrow = eras[i].narrow.toUpperCase();\n\n if (strict) {\n switch (format) {\n case 'N':\n case 'NN':\n case 'NNN':\n if (abbr === eraName) {\n return eras[i];\n }\n break;\n\n case 'NNNN':\n if (name === eraName) {\n return eras[i];\n }\n break;\n\n case 'NNNNN':\n if (narrow === eraName) {\n return eras[i];\n }\n break;\n }\n } else if ([name, abbr, narrow].indexOf(eraName) >= 0) {\n return eras[i];\n }\n }\n }\n\n function localeErasConvertYear(era, year) {\n var dir = era.since <= era.until ? +1 : -1;\n if (year === undefined) {\n return hooks(era.since).year();\n } else {\n return hooks(era.since).year() + (year - era.offset) * dir;\n }\n }\n\n function getEraName() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].name;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].name;\n }\n }\n\n return '';\n }\n\n function getEraNarrow() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].narrow;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].narrow;\n }\n }\n\n return '';\n }\n\n function getEraAbbr() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].abbr;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].abbr;\n }\n }\n\n return '';\n }\n\n function getEraYear() {\n var i,\n l,\n dir,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n dir = eras[i].since <= eras[i].until ? +1 : -1;\n\n // truncate time\n val = this.clone().startOf('day').valueOf();\n\n if (\n (eras[i].since <= val && val <= eras[i].until) ||\n (eras[i].until <= val && val <= eras[i].since)\n ) {\n return (\n (this.year() - hooks(eras[i].since).year()) * dir +\n eras[i].offset\n );\n }\n }\n\n return this.year();\n }\n\n function erasNameRegex(isStrict) {\n if (!hasOwnProp(this, '_erasNameRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasNameRegex : this._erasRegex;\n }\n\n function erasAbbrRegex(isStrict) {\n if (!hasOwnProp(this, '_erasAbbrRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasAbbrRegex : this._erasRegex;\n }\n\n function erasNarrowRegex(isStrict) {\n if (!hasOwnProp(this, '_erasNarrowRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasNarrowRegex : this._erasRegex;\n }\n\n function matchEraAbbr(isStrict, locale) {\n return locale.erasAbbrRegex(isStrict);\n }\n\n function matchEraName(isStrict, locale) {\n return locale.erasNameRegex(isStrict);\n }\n\n function matchEraNarrow(isStrict, locale) {\n return locale.erasNarrowRegex(isStrict);\n }\n\n function matchEraYearOrdinal(isStrict, locale) {\n return locale._eraYearOrdinalRegex || matchUnsigned;\n }\n\n function computeErasParse() {\n var abbrPieces = [],\n namePieces = [],\n narrowPieces = [],\n mixedPieces = [],\n i,\n l,\n eras = this.eras();\n\n for (i = 0, l = eras.length; i < l; ++i) {\n namePieces.push(regexEscape(eras[i].name));\n abbrPieces.push(regexEscape(eras[i].abbr));\n narrowPieces.push(regexEscape(eras[i].narrow));\n\n mixedPieces.push(regexEscape(eras[i].name));\n mixedPieces.push(regexEscape(eras[i].abbr));\n mixedPieces.push(regexEscape(eras[i].narrow));\n }\n\n this._erasRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._erasNameRegex = new RegExp('^(' + namePieces.join('|') + ')', 'i');\n this._erasAbbrRegex = new RegExp('^(' + abbrPieces.join('|') + ')', 'i');\n this._erasNarrowRegex = new RegExp(\n '^(' + narrowPieces.join('|') + ')',\n 'i'\n );\n }\n\n // FORMATTING\n\n addFormatToken(0, ['gg', 2], 0, function () {\n return this.weekYear() % 100;\n });\n\n addFormatToken(0, ['GG', 2], 0, function () {\n return this.isoWeekYear() % 100;\n });\n\n function addWeekYearFormatToken(token, getter) {\n addFormatToken(0, [token, token.length], 0, getter);\n }\n\n addWeekYearFormatToken('gggg', 'weekYear');\n addWeekYearFormatToken('ggggg', 'weekYear');\n addWeekYearFormatToken('GGGG', 'isoWeekYear');\n addWeekYearFormatToken('GGGGG', 'isoWeekYear');\n\n // ALIASES\n\n addUnitAlias('weekYear', 'gg');\n addUnitAlias('isoWeekYear', 'GG');\n\n // PRIORITY\n\n addUnitPriority('weekYear', 1);\n addUnitPriority('isoWeekYear', 1);\n\n // PARSING\n\n addRegexToken('G', matchSigned);\n addRegexToken('g', matchSigned);\n addRegexToken('GG', match1to2, match2);\n addRegexToken('gg', match1to2, match2);\n addRegexToken('GGGG', match1to4, match4);\n addRegexToken('gggg', match1to4, match4);\n addRegexToken('GGGGG', match1to6, match6);\n addRegexToken('ggggg', match1to6, match6);\n\n addWeekParseToken(\n ['gggg', 'ggggg', 'GGGG', 'GGGGG'],\n function (input, week, config, token) {\n week[token.substr(0, 2)] = toInt(input);\n }\n );\n\n addWeekParseToken(['gg', 'GG'], function (input, week, config, token) {\n week[token] = hooks.parseTwoDigitYear(input);\n });\n\n // MOMENTS\n\n function getSetWeekYear(input) {\n return getSetWeekYearHelper.call(\n this,\n input,\n this.week(),\n this.weekday(),\n this.localeData()._week.dow,\n this.localeData()._week.doy\n );\n }\n\n function getSetISOWeekYear(input) {\n return getSetWeekYearHelper.call(\n this,\n input,\n this.isoWeek(),\n this.isoWeekday(),\n 1,\n 4\n );\n }\n\n function getISOWeeksInYear() {\n return weeksInYear(this.year(), 1, 4);\n }\n\n function getISOWeeksInISOWeekYear() {\n return weeksInYear(this.isoWeekYear(), 1, 4);\n }\n\n function getWeeksInYear() {\n var weekInfo = this.localeData()._week;\n return weeksInYear(this.year(), weekInfo.dow, weekInfo.doy);\n }\n\n function getWeeksInWeekYear() {\n var weekInfo = this.localeData()._week;\n return weeksInYear(this.weekYear(), weekInfo.dow, weekInfo.doy);\n }\n\n function getSetWeekYearHelper(input, week, weekday, dow, doy) {\n var weeksTarget;\n if (input == null) {\n return weekOfYear(this, dow, doy).year;\n } else {\n weeksTarget = weeksInYear(input, dow, doy);\n if (week > weeksTarget) {\n week = weeksTarget;\n }\n return setWeekAll.call(this, input, week, weekday, dow, doy);\n }\n }\n\n function setWeekAll(weekYear, week, weekday, dow, doy) {\n var dayOfYearData = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy),\n date = createUTCDate(dayOfYearData.year, 0, dayOfYearData.dayOfYear);\n\n this.year(date.getUTCFullYear());\n this.month(date.getUTCMonth());\n this.date(date.getUTCDate());\n return this;\n }\n\n // FORMATTING\n\n addFormatToken('Q', 0, 'Qo', 'quarter');\n\n // ALIASES\n\n addUnitAlias('quarter', 'Q');\n\n // PRIORITY\n\n addUnitPriority('quarter', 7);\n\n // PARSING\n\n addRegexToken('Q', match1);\n addParseToken('Q', function (input, array) {\n array[MONTH] = (toInt(input) - 1) * 3;\n });\n\n // MOMENTS\n\n function getSetQuarter(input) {\n return input == null\n ? Math.ceil((this.month() + 1) / 3)\n : this.month((input - 1) * 3 + (this.month() % 3));\n }\n\n // FORMATTING\n\n addFormatToken('D', ['DD', 2], 'Do', 'date');\n\n // ALIASES\n\n addUnitAlias('date', 'D');\n\n // PRIORITY\n addUnitPriority('date', 9);\n\n // PARSING\n\n addRegexToken('D', match1to2);\n addRegexToken('DD', match1to2, match2);\n addRegexToken('Do', function (isStrict, locale) {\n // TODO: Remove \"ordinalParse\" fallback in next major release.\n return isStrict\n ? locale._dayOfMonthOrdinalParse || locale._ordinalParse\n : locale._dayOfMonthOrdinalParseLenient;\n });\n\n addParseToken(['D', 'DD'], DATE);\n addParseToken('Do', function (input, array) {\n array[DATE] = toInt(input.match(match1to2)[0]);\n });\n\n // MOMENTS\n\n var getSetDayOfMonth = makeGetSet('Date', true);\n\n // FORMATTING\n\n addFormatToken('DDD', ['DDDD', 3], 'DDDo', 'dayOfYear');\n\n // ALIASES\n\n addUnitAlias('dayOfYear', 'DDD');\n\n // PRIORITY\n addUnitPriority('dayOfYear', 4);\n\n // PARSING\n\n addRegexToken('DDD', match1to3);\n addRegexToken('DDDD', match3);\n addParseToken(['DDD', 'DDDD'], function (input, array, config) {\n config._dayOfYear = toInt(input);\n });\n\n // HELPERS\n\n // MOMENTS\n\n function getSetDayOfYear(input) {\n var dayOfYear =\n Math.round(\n (this.clone().startOf('day') - this.clone().startOf('year')) / 864e5\n ) + 1;\n return input == null ? dayOfYear : this.add(input - dayOfYear, 'd');\n }\n\n // FORMATTING\n\n addFormatToken('m', ['mm', 2], 0, 'minute');\n\n // ALIASES\n\n addUnitAlias('minute', 'm');\n\n // PRIORITY\n\n addUnitPriority('minute', 14);\n\n // PARSING\n\n addRegexToken('m', match1to2);\n addRegexToken('mm', match1to2, match2);\n addParseToken(['m', 'mm'], MINUTE);\n\n // MOMENTS\n\n var getSetMinute = makeGetSet('Minutes', false);\n\n // FORMATTING\n\n addFormatToken('s', ['ss', 2], 0, 'second');\n\n // ALIASES\n\n addUnitAlias('second', 's');\n\n // PRIORITY\n\n addUnitPriority('second', 15);\n\n // PARSING\n\n addRegexToken('s', match1to2);\n addRegexToken('ss', match1to2, match2);\n addParseToken(['s', 'ss'], SECOND);\n\n // MOMENTS\n\n var getSetSecond = makeGetSet('Seconds', false);\n\n // FORMATTING\n\n addFormatToken('S', 0, 0, function () {\n return ~~(this.millisecond() / 100);\n });\n\n addFormatToken(0, ['SS', 2], 0, function () {\n return ~~(this.millisecond() / 10);\n });\n\n addFormatToken(0, ['SSS', 3], 0, 'millisecond');\n addFormatToken(0, ['SSSS', 4], 0, function () {\n return this.millisecond() * 10;\n });\n addFormatToken(0, ['SSSSS', 5], 0, function () {\n return this.millisecond() * 100;\n });\n addFormatToken(0, ['SSSSSS', 6], 0, function () {\n return this.millisecond() * 1000;\n });\n addFormatToken(0, ['SSSSSSS', 7], 0, function () {\n return this.millisecond() * 10000;\n });\n addFormatToken(0, ['SSSSSSSS', 8], 0, function () {\n return this.millisecond() * 100000;\n });\n addFormatToken(0, ['SSSSSSSSS', 9], 0, function () {\n return this.millisecond() * 1000000;\n });\n\n // ALIASES\n\n addUnitAlias('millisecond', 'ms');\n\n // PRIORITY\n\n addUnitPriority('millisecond', 16);\n\n // PARSING\n\n addRegexToken('S', match1to3, match1);\n addRegexToken('SS', match1to3, match2);\n addRegexToken('SSS', match1to3, match3);\n\n var token, getSetMillisecond;\n for (token = 'SSSS'; token.length <= 9; token += 'S') {\n addRegexToken(token, matchUnsigned);\n }\n\n function parseMs(input, array) {\n array[MILLISECOND] = toInt(('0.' + input) * 1000);\n }\n\n for (token = 'S'; token.length <= 9; token += 'S') {\n addParseToken(token, parseMs);\n }\n\n getSetMillisecond = makeGetSet('Milliseconds', false);\n\n // FORMATTING\n\n addFormatToken('z', 0, 0, 'zoneAbbr');\n addFormatToken('zz', 0, 0, 'zoneName');\n\n // MOMENTS\n\n function getZoneAbbr() {\n return this._isUTC ? 'UTC' : '';\n }\n\n function getZoneName() {\n return this._isUTC ? 'Coordinated Universal Time' : '';\n }\n\n var proto = Moment.prototype;\n\n proto.add = add;\n proto.calendar = calendar$1;\n proto.clone = clone;\n proto.diff = diff;\n proto.endOf = endOf;\n proto.format = format;\n proto.from = from;\n proto.fromNow = fromNow;\n proto.to = to;\n proto.toNow = toNow;\n proto.get = stringGet;\n proto.invalidAt = invalidAt;\n proto.isAfter = isAfter;\n proto.isBefore = isBefore;\n proto.isBetween = isBetween;\n proto.isSame = isSame;\n proto.isSameOrAfter = isSameOrAfter;\n proto.isSameOrBefore = isSameOrBefore;\n proto.isValid = isValid$2;\n proto.lang = lang;\n proto.locale = locale;\n proto.localeData = localeData;\n proto.max = prototypeMax;\n proto.min = prototypeMin;\n proto.parsingFlags = parsingFlags;\n proto.set = stringSet;\n proto.startOf = startOf;\n proto.subtract = subtract;\n proto.toArray = toArray;\n proto.toObject = toObject;\n proto.toDate = toDate;\n proto.toISOString = toISOString;\n proto.inspect = inspect;\n if (typeof Symbol !== 'undefined' && Symbol.for != null) {\n proto[Symbol.for('nodejs.util.inspect.custom')] = function () {\n return 'Moment<' + this.format() + '>';\n };\n }\n proto.toJSON = toJSON;\n proto.toString = toString;\n proto.unix = unix;\n proto.valueOf = valueOf;\n proto.creationData = creationData;\n proto.eraName = getEraName;\n proto.eraNarrow = getEraNarrow;\n proto.eraAbbr = getEraAbbr;\n proto.eraYear = getEraYear;\n proto.year = getSetYear;\n proto.isLeapYear = getIsLeapYear;\n proto.weekYear = getSetWeekYear;\n proto.isoWeekYear = getSetISOWeekYear;\n proto.quarter = proto.quarters = getSetQuarter;\n proto.month = getSetMonth;\n proto.daysInMonth = getDaysInMonth;\n proto.week = proto.weeks = getSetWeek;\n proto.isoWeek = proto.isoWeeks = getSetISOWeek;\n proto.weeksInYear = getWeeksInYear;\n proto.weeksInWeekYear = getWeeksInWeekYear;\n proto.isoWeeksInYear = getISOWeeksInYear;\n proto.isoWeeksInISOWeekYear = getISOWeeksInISOWeekYear;\n proto.date = getSetDayOfMonth;\n proto.day = proto.days = getSetDayOfWeek;\n proto.weekday = getSetLocaleDayOfWeek;\n proto.isoWeekday = getSetISODayOfWeek;\n proto.dayOfYear = getSetDayOfYear;\n proto.hour = proto.hours = getSetHour;\n proto.minute = proto.minutes = getSetMinute;\n proto.second = proto.seconds = getSetSecond;\n proto.millisecond = proto.milliseconds = getSetMillisecond;\n proto.utcOffset = getSetOffset;\n proto.utc = setOffsetToUTC;\n proto.local = setOffsetToLocal;\n proto.parseZone = setOffsetToParsedOffset;\n proto.hasAlignedHourOffset = hasAlignedHourOffset;\n proto.isDST = isDaylightSavingTime;\n proto.isLocal = isLocal;\n proto.isUtcOffset = isUtcOffset;\n proto.isUtc = isUtc;\n proto.isUTC = isUtc;\n proto.zoneAbbr = getZoneAbbr;\n proto.zoneName = getZoneName;\n proto.dates = deprecate(\n 'dates accessor is deprecated. Use date instead.',\n getSetDayOfMonth\n );\n proto.months = deprecate(\n 'months accessor is deprecated. Use month instead',\n getSetMonth\n );\n proto.years = deprecate(\n 'years accessor is deprecated. Use year instead',\n getSetYear\n );\n proto.zone = deprecate(\n 'moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/',\n getSetZone\n );\n proto.isDSTShifted = deprecate(\n 'isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information',\n isDaylightSavingTimeShifted\n );\n\n function createUnix(input) {\n return createLocal(input * 1000);\n }\n\n function createInZone() {\n return createLocal.apply(null, arguments).parseZone();\n }\n\n function preParsePostFormat(string) {\n return string;\n }\n\n var proto$1 = Locale.prototype;\n\n proto$1.calendar = calendar;\n proto$1.longDateFormat = longDateFormat;\n proto$1.invalidDate = invalidDate;\n proto$1.ordinal = ordinal;\n proto$1.preparse = preParsePostFormat;\n proto$1.postformat = preParsePostFormat;\n proto$1.relativeTime = relativeTime;\n proto$1.pastFuture = pastFuture;\n proto$1.set = set;\n proto$1.eras = localeEras;\n proto$1.erasParse = localeErasParse;\n proto$1.erasConvertYear = localeErasConvertYear;\n proto$1.erasAbbrRegex = erasAbbrRegex;\n proto$1.erasNameRegex = erasNameRegex;\n proto$1.erasNarrowRegex = erasNarrowRegex;\n\n proto$1.months = localeMonths;\n proto$1.monthsShort = localeMonthsShort;\n proto$1.monthsParse = localeMonthsParse;\n proto$1.monthsRegex = monthsRegex;\n proto$1.monthsShortRegex = monthsShortRegex;\n proto$1.week = localeWeek;\n proto$1.firstDayOfYear = localeFirstDayOfYear;\n proto$1.firstDayOfWeek = localeFirstDayOfWeek;\n\n proto$1.weekdays = localeWeekdays;\n proto$1.weekdaysMin = localeWeekdaysMin;\n proto$1.weekdaysShort = localeWeekdaysShort;\n proto$1.weekdaysParse = localeWeekdaysParse;\n\n proto$1.weekdaysRegex = weekdaysRegex;\n proto$1.weekdaysShortRegex = weekdaysShortRegex;\n proto$1.weekdaysMinRegex = weekdaysMinRegex;\n\n proto$1.isPM = localeIsPM;\n proto$1.meridiem = localeMeridiem;\n\n function get$1(format, index, field, setter) {\n var locale = getLocale(),\n utc = createUTC().set(setter, index);\n return locale[field](utc, format);\n }\n\n function listMonthsImpl(format, index, field) {\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n\n format = format || '';\n\n if (index != null) {\n return get$1(format, index, field, 'month');\n }\n\n var i,\n out = [];\n for (i = 0; i < 12; i++) {\n out[i] = get$1(format, i, field, 'month');\n }\n return out;\n }\n\n // ()\n // (5)\n // (fmt, 5)\n // (fmt)\n // (true)\n // (true, 5)\n // (true, fmt, 5)\n // (true, fmt)\n function listWeekdaysImpl(localeSorted, format, index, field) {\n if (typeof localeSorted === 'boolean') {\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n\n format = format || '';\n } else {\n format = localeSorted;\n index = format;\n localeSorted = false;\n\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n\n format = format || '';\n }\n\n var locale = getLocale(),\n shift = localeSorted ? locale._week.dow : 0,\n i,\n out = [];\n\n if (index != null) {\n return get$1(format, (index + shift) % 7, field, 'day');\n }\n\n for (i = 0; i < 7; i++) {\n out[i] = get$1(format, (i + shift) % 7, field, 'day');\n }\n return out;\n }\n\n function listMonths(format, index) {\n return listMonthsImpl(format, index, 'months');\n }\n\n function listMonthsShort(format, index) {\n return listMonthsImpl(format, index, 'monthsShort');\n }\n\n function listWeekdays(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdays');\n }\n\n function listWeekdaysShort(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdaysShort');\n }\n\n function listWeekdaysMin(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdaysMin');\n }\n\n getSetGlobalLocale('en', {\n eras: [\n {\n since: '0001-01-01',\n until: +Infinity,\n offset: 1,\n name: 'Anno Domini',\n narrow: 'AD',\n abbr: 'AD',\n },\n {\n since: '0000-12-31',\n until: -Infinity,\n offset: 1,\n name: 'Before Christ',\n narrow: 'BC',\n abbr: 'BC',\n },\n ],\n dayOfMonthOrdinalParse: /\\d{1,2}(th|st|nd|rd)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n toInt((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n });\n\n // Side effect imports\n\n hooks.lang = deprecate(\n 'moment.lang is deprecated. Use moment.locale instead.',\n getSetGlobalLocale\n );\n hooks.langData = deprecate(\n 'moment.langData is deprecated. Use moment.localeData instead.',\n getLocale\n );\n\n var mathAbs = Math.abs;\n\n function abs() {\n var data = this._data;\n\n this._milliseconds = mathAbs(this._milliseconds);\n this._days = mathAbs(this._days);\n this._months = mathAbs(this._months);\n\n data.milliseconds = mathAbs(data.milliseconds);\n data.seconds = mathAbs(data.seconds);\n data.minutes = mathAbs(data.minutes);\n data.hours = mathAbs(data.hours);\n data.months = mathAbs(data.months);\n data.years = mathAbs(data.years);\n\n return this;\n }\n\n function addSubtract$1(duration, input, value, direction) {\n var other = createDuration(input, value);\n\n duration._milliseconds += direction * other._milliseconds;\n duration._days += direction * other._days;\n duration._months += direction * other._months;\n\n return duration._bubble();\n }\n\n // supports only 2.0-style add(1, 's') or add(duration)\n function add$1(input, value) {\n return addSubtract$1(this, input, value, 1);\n }\n\n // supports only 2.0-style subtract(1, 's') or subtract(duration)\n function subtract$1(input, value) {\n return addSubtract$1(this, input, value, -1);\n }\n\n function absCeil(number) {\n if (number < 0) {\n return Math.floor(number);\n } else {\n return Math.ceil(number);\n }\n }\n\n function bubble() {\n var milliseconds = this._milliseconds,\n days = this._days,\n months = this._months,\n data = this._data,\n seconds,\n minutes,\n hours,\n years,\n monthsFromDays;\n\n // if we have a mix of positive and negative values, bubble down first\n // check: https://github.com/moment/moment/issues/2166\n if (\n !(\n (milliseconds >= 0 && days >= 0 && months >= 0) ||\n (milliseconds <= 0 && days <= 0 && months <= 0)\n )\n ) {\n milliseconds += absCeil(monthsToDays(months) + days) * 864e5;\n days = 0;\n months = 0;\n }\n\n // The following code bubbles up values, see the tests for\n // examples of what that means.\n data.milliseconds = milliseconds % 1000;\n\n seconds = absFloor(milliseconds / 1000);\n data.seconds = seconds % 60;\n\n minutes = absFloor(seconds / 60);\n data.minutes = minutes % 60;\n\n hours = absFloor(minutes / 60);\n data.hours = hours % 24;\n\n days += absFloor(hours / 24);\n\n // convert days to months\n monthsFromDays = absFloor(daysToMonths(days));\n months += monthsFromDays;\n days -= absCeil(monthsToDays(monthsFromDays));\n\n // 12 months -> 1 year\n years = absFloor(months / 12);\n months %= 12;\n\n data.days = days;\n data.months = months;\n data.years = years;\n\n return this;\n }\n\n function daysToMonths(days) {\n // 400 years have 146097 days (taking into account leap year rules)\n // 400 years have 12 months === 4800\n return (days * 4800) / 146097;\n }\n\n function monthsToDays(months) {\n // the reverse of daysToMonths\n return (months * 146097) / 4800;\n }\n\n function as(units) {\n if (!this.isValid()) {\n return NaN;\n }\n var days,\n months,\n milliseconds = this._milliseconds;\n\n units = normalizeUnits(units);\n\n if (units === 'month' || units === 'quarter' || units === 'year') {\n days = this._days + milliseconds / 864e5;\n months = this._months + daysToMonths(days);\n switch (units) {\n case 'month':\n return months;\n case 'quarter':\n return months / 3;\n case 'year':\n return months / 12;\n }\n } else {\n // handle milliseconds separately because of floating point math errors (issue #1867)\n days = this._days + Math.round(monthsToDays(this._months));\n switch (units) {\n case 'week':\n return days / 7 + milliseconds / 6048e5;\n case 'day':\n return days + milliseconds / 864e5;\n case 'hour':\n return days * 24 + milliseconds / 36e5;\n case 'minute':\n return days * 1440 + milliseconds / 6e4;\n case 'second':\n return days * 86400 + milliseconds / 1000;\n // Math.floor prevents floating point math errors here\n case 'millisecond':\n return Math.floor(days * 864e5) + milliseconds;\n default:\n throw new Error('Unknown unit ' + units);\n }\n }\n }\n\n // TODO: Use this.as('ms')?\n function valueOf$1() {\n if (!this.isValid()) {\n return NaN;\n }\n return (\n this._milliseconds +\n this._days * 864e5 +\n (this._months % 12) * 2592e6 +\n toInt(this._months / 12) * 31536e6\n );\n }\n\n function makeAs(alias) {\n return function () {\n return this.as(alias);\n };\n }\n\n var asMilliseconds = makeAs('ms'),\n asSeconds = makeAs('s'),\n asMinutes = makeAs('m'),\n asHours = makeAs('h'),\n asDays = makeAs('d'),\n asWeeks = makeAs('w'),\n asMonths = makeAs('M'),\n asQuarters = makeAs('Q'),\n asYears = makeAs('y');\n\n function clone$1() {\n return createDuration(this);\n }\n\n function get$2(units) {\n units = normalizeUnits(units);\n return this.isValid() ? this[units + 's']() : NaN;\n }\n\n function makeGetter(name) {\n return function () {\n return this.isValid() ? this._data[name] : NaN;\n };\n }\n\n var milliseconds = makeGetter('milliseconds'),\n seconds = makeGetter('seconds'),\n minutes = makeGetter('minutes'),\n hours = makeGetter('hours'),\n days = makeGetter('days'),\n months = makeGetter('months'),\n years = makeGetter('years');\n\n function weeks() {\n return absFloor(this.days() / 7);\n }\n\n var round = Math.round,\n thresholds = {\n ss: 44, // a few seconds to seconds\n s: 45, // seconds to minute\n m: 45, // minutes to hour\n h: 22, // hours to day\n d: 26, // days to month/week\n w: null, // weeks to month\n M: 11, // months to year\n };\n\n // helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize\n function substituteTimeAgo(string, number, withoutSuffix, isFuture, locale) {\n return locale.relativeTime(number || 1, !!withoutSuffix, string, isFuture);\n }\n\n function relativeTime$1(posNegDuration, withoutSuffix, thresholds, locale) {\n var duration = createDuration(posNegDuration).abs(),\n seconds = round(duration.as('s')),\n minutes = round(duration.as('m')),\n hours = round(duration.as('h')),\n days = round(duration.as('d')),\n months = round(duration.as('M')),\n weeks = round(duration.as('w')),\n years = round(duration.as('y')),\n a =\n (seconds <= thresholds.ss && ['s', seconds]) ||\n (seconds < thresholds.s && ['ss', seconds]) ||\n (minutes <= 1 && ['m']) ||\n (minutes < thresholds.m && ['mm', minutes]) ||\n (hours <= 1 && ['h']) ||\n (hours < thresholds.h && ['hh', hours]) ||\n (days <= 1 && ['d']) ||\n (days < thresholds.d && ['dd', days]);\n\n if (thresholds.w != null) {\n a =\n a ||\n (weeks <= 1 && ['w']) ||\n (weeks < thresholds.w && ['ww', weeks]);\n }\n a = a ||\n (months <= 1 && ['M']) ||\n (months < thresholds.M && ['MM', months]) ||\n (years <= 1 && ['y']) || ['yy', years];\n\n a[2] = withoutSuffix;\n a[3] = +posNegDuration > 0;\n a[4] = locale;\n return substituteTimeAgo.apply(null, a);\n }\n\n // This function allows you to set the rounding function for relative time strings\n function getSetRelativeTimeRounding(roundingFunction) {\n if (roundingFunction === undefined) {\n return round;\n }\n if (typeof roundingFunction === 'function') {\n round = roundingFunction;\n return true;\n }\n return false;\n }\n\n // This function allows you to set a threshold for relative time strings\n function getSetRelativeTimeThreshold(threshold, limit) {\n if (thresholds[threshold] === undefined) {\n return false;\n }\n if (limit === undefined) {\n return thresholds[threshold];\n }\n thresholds[threshold] = limit;\n if (threshold === 's') {\n thresholds.ss = limit - 1;\n }\n return true;\n }\n\n function humanize(argWithSuffix, argThresholds) {\n if (!this.isValid()) {\n return this.localeData().invalidDate();\n }\n\n var withSuffix = false,\n th = thresholds,\n locale,\n output;\n\n if (typeof argWithSuffix === 'object') {\n argThresholds = argWithSuffix;\n argWithSuffix = false;\n }\n if (typeof argWithSuffix === 'boolean') {\n withSuffix = argWithSuffix;\n }\n if (typeof argThresholds === 'object') {\n th = Object.assign({}, thresholds, argThresholds);\n if (argThresholds.s != null && argThresholds.ss == null) {\n th.ss = argThresholds.s - 1;\n }\n }\n\n locale = this.localeData();\n output = relativeTime$1(this, !withSuffix, th, locale);\n\n if (withSuffix) {\n output = locale.pastFuture(+this, output);\n }\n\n return locale.postformat(output);\n }\n\n var abs$1 = Math.abs;\n\n function sign(x) {\n return (x > 0) - (x < 0) || +x;\n }\n\n function toISOString$1() {\n // for ISO strings we do not use the normal bubbling rules:\n // * milliseconds bubble up until they become hours\n // * days do not bubble at all\n // * months bubble up until they become years\n // This is because there is no context-free conversion between hours and days\n // (think of clock changes)\n // and also not between days and months (28-31 days per month)\n if (!this.isValid()) {\n return this.localeData().invalidDate();\n }\n\n var seconds = abs$1(this._milliseconds) / 1000,\n days = abs$1(this._days),\n months = abs$1(this._months),\n minutes,\n hours,\n years,\n s,\n total = this.asSeconds(),\n totalSign,\n ymSign,\n daysSign,\n hmsSign;\n\n if (!total) {\n // this is the same as C#'s (Noda) and python (isodate)...\n // but not other JS (goog.date)\n return 'P0D';\n }\n\n // 3600 seconds -> 60 minutes -> 1 hour\n minutes = absFloor(seconds / 60);\n hours = absFloor(minutes / 60);\n seconds %= 60;\n minutes %= 60;\n\n // 12 months -> 1 year\n years = absFloor(months / 12);\n months %= 12;\n\n // inspired by https://github.com/dordille/moment-isoduration/blob/master/moment.isoduration.js\n s = seconds ? seconds.toFixed(3).replace(/\\.?0+$/, '') : '';\n\n totalSign = total < 0 ? '-' : '';\n ymSign = sign(this._months) !== sign(total) ? '-' : '';\n daysSign = sign(this._days) !== sign(total) ? '-' : '';\n hmsSign = sign(this._milliseconds) !== sign(total) ? '-' : '';\n\n return (\n totalSign +\n 'P' +\n (years ? ymSign + years + 'Y' : '') +\n (months ? ymSign + months + 'M' : '') +\n (days ? daysSign + days + 'D' : '') +\n (hours || minutes || seconds ? 'T' : '') +\n (hours ? hmsSign + hours + 'H' : '') +\n (minutes ? hmsSign + minutes + 'M' : '') +\n (seconds ? hmsSign + s + 'S' : '')\n );\n }\n\n var proto$2 = Duration.prototype;\n\n proto$2.isValid = isValid$1;\n proto$2.abs = abs;\n proto$2.add = add$1;\n proto$2.subtract = subtract$1;\n proto$2.as = as;\n proto$2.asMilliseconds = asMilliseconds;\n proto$2.asSeconds = asSeconds;\n proto$2.asMinutes = asMinutes;\n proto$2.asHours = asHours;\n proto$2.asDays = asDays;\n proto$2.asWeeks = asWeeks;\n proto$2.asMonths = asMonths;\n proto$2.asQuarters = asQuarters;\n proto$2.asYears = asYears;\n proto$2.valueOf = valueOf$1;\n proto$2._bubble = bubble;\n proto$2.clone = clone$1;\n proto$2.get = get$2;\n proto$2.milliseconds = milliseconds;\n proto$2.seconds = seconds;\n proto$2.minutes = minutes;\n proto$2.hours = hours;\n proto$2.days = days;\n proto$2.weeks = weeks;\n proto$2.months = months;\n proto$2.years = years;\n proto$2.humanize = humanize;\n proto$2.toISOString = toISOString$1;\n proto$2.toString = toISOString$1;\n proto$2.toJSON = toISOString$1;\n proto$2.locale = locale;\n proto$2.localeData = localeData;\n\n proto$2.toIsoString = deprecate(\n 'toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)',\n toISOString$1\n );\n proto$2.lang = lang;\n\n // FORMATTING\n\n addFormatToken('X', 0, 0, 'unix');\n addFormatToken('x', 0, 0, 'valueOf');\n\n // PARSING\n\n addRegexToken('x', matchSigned);\n addRegexToken('X', matchTimestamp);\n addParseToken('X', function (input, array, config) {\n config._d = new Date(parseFloat(input) * 1000);\n });\n addParseToken('x', function (input, array, config) {\n config._d = new Date(toInt(input));\n });\n\n //! moment.js\n\n hooks.version = '2.29.4';\n\n setHookCallback(createLocal);\n\n hooks.fn = proto;\n hooks.min = min;\n hooks.max = max;\n hooks.now = now;\n hooks.utc = createUTC;\n hooks.unix = createUnix;\n hooks.months = listMonths;\n hooks.isDate = isDate;\n hooks.locale = getSetGlobalLocale;\n hooks.invalid = createInvalid;\n hooks.duration = createDuration;\n hooks.isMoment = isMoment;\n hooks.weekdays = listWeekdays;\n hooks.parseZone = createInZone;\n hooks.localeData = getLocale;\n hooks.isDuration = isDuration;\n hooks.monthsShort = listMonthsShort;\n hooks.weekdaysMin = listWeekdaysMin;\n hooks.defineLocale = defineLocale;\n hooks.updateLocale = updateLocale;\n hooks.locales = listLocales;\n hooks.weekdaysShort = listWeekdaysShort;\n hooks.normalizeUnits = normalizeUnits;\n hooks.relativeTimeRounding = getSetRelativeTimeRounding;\n hooks.relativeTimeThreshold = getSetRelativeTimeThreshold;\n hooks.calendarFormat = getCalendarFormat;\n hooks.prototype = proto;\n\n // currently HTML5 input type only supports 24-hour formats\n hooks.HTML5_FMT = {\n DATETIME_LOCAL: 'YYYY-MM-DDTHH:mm', // <input type=\"datetime-local\" />\n DATETIME_LOCAL_SECONDS: 'YYYY-MM-DDTHH:mm:ss', // <input type=\"datetime-local\" step=\"1\" />\n DATETIME_LOCAL_MS: 'YYYY-MM-DDTHH:mm:ss.SSS', // <input type=\"datetime-local\" step=\"0.001\" />\n DATE: 'YYYY-MM-DD', // <input type=\"date\" />\n TIME: 'HH:mm', // <input type=\"time\" />\n TIME_SECONDS: 'HH:mm:ss', // <input type=\"time\" step=\"1\" />\n TIME_MS: 'HH:mm:ss.SSS', // <input type=\"time\" step=\"0.001\" />\n WEEK: 'GGGG-[W]WW', // <input type=\"week\" />\n MONTH: 'YYYY-MM', // <input type=\"month\" />\n };\n\n return hooks;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { isZoomSet, setRange, triggerLabelRender } from '../../common/utils/helper';\nimport { DoubleRange } from '../utils/double-range';\nimport { withIn, firstToLowerCase } from '../../common/utils/helper';\nimport { DataUtil } from '@syncfusion/ej2-data';\nimport { NiceInterval } from '../axis/axis-helper';\nimport { extend, getValue, isNullOrUndefined } from '@syncfusion/ej2-base';\n/**\n * `DateTime` module is used to render datetime axis.\n */\nvar DateTime = /** @class */ (function (_super) {\n __extends(DateTime, _super);\n /**\n * Constructor for the dateTime module.\n *\n * @private\n */\n function DateTime(chart) {\n return _super.call(this, chart) || this;\n }\n /**\n * The function to calculate the range and labels for the axis.\n *\n * @returns {void}\n */\n DateTime.prototype.calculateRangeAndInterval = function (size, axis) {\n this.calculateRange(axis);\n this.getActualRange(axis, size);\n this.applyRangePadding(axis, size);\n this.calculateVisibleLabels(axis, this.chart);\n };\n /**\n * Actual Range for the axis.\n *\n * @private\n */\n DateTime.prototype.getActualRange = function (axis, size) {\n var option = {\n skeleton: 'full',\n type: 'dateTime'\n };\n var dateParser = this.chart.intl.getDateParser(option);\n var dateFormatter = this.chart.intl.getDateFormat(option);\n // Axis min\n if ((axis.minimum) !== null) {\n this.min = this.chart.isBlazor ? Date.parse(axis.minimum.toString()) : Date.parse(dateParser(dateFormatter(new Date(DataUtil.parse.parseJson({ val: axis.minimum }).val))));\n }\n else if (this.min === null || this.min === Number.POSITIVE_INFINITY) {\n this.min = Date.parse(dateParser(dateFormatter(new Date(1970, 1, 1))));\n }\n // Axis Max\n if ((axis.maximum) !== null) {\n this.max = this.chart.isBlazor ? Date.parse(axis.maximum.toString()) : Date.parse(dateParser(dateFormatter(new Date(DataUtil.parse.parseJson({ val: axis.maximum }).val))));\n }\n else if (this.max === null || this.max === Number.NEGATIVE_INFINITY) {\n this.max = Date.parse(dateParser(dateFormatter(new Date(1970, 5, 1))));\n }\n if (this.min === this.max) {\n this.max = this.max + 2592000000;\n this.min = this.min - 2592000000;\n }\n axis.actualRange = {};\n axis.doubleRange = new DoubleRange(this.min, this.max);\n var datetimeInterval = this.calculateDateTimeNiceInterval(axis, size, axis.doubleRange.start, axis.doubleRange.end);\n if (!axis.interval) {\n axis.actualRange.interval = datetimeInterval;\n }\n else {\n axis.actualRange.interval = axis.interval;\n }\n axis.actualRange.min = axis.doubleRange.start;\n axis.actualRange.max = axis.doubleRange.end;\n };\n /**\n * Apply padding for the range.\n *\n * @private\n */\n DateTime.prototype.applyRangePadding = function (axis, size) {\n this.min = (axis.actualRange.min);\n this.max = (axis.actualRange.max);\n var minimum;\n var maximum;\n var interval = axis.actualRange.interval;\n if (!setRange(axis)) {\n var rangePadding = axis.getRangePadding(this.chart);\n minimum = new Date(this.min);\n maximum = new Date(this.max);\n var intervalType = axis.actualIntervalType;\n if (rangePadding === 'None') {\n this.min = minimum.getTime();\n this.max = maximum.getTime();\n }\n else if (rangePadding === 'Additional' || rangePadding === 'Round') {\n switch (intervalType) {\n case 'Years':\n this.getYear(minimum, maximum, rangePadding, interval);\n break;\n case 'Months':\n this.getMonth(minimum, maximum, rangePadding, interval);\n break;\n case 'Days':\n this.getDay(minimum, maximum, rangePadding, interval);\n break;\n case 'Hours':\n this.getHour(minimum, maximum, rangePadding, interval);\n break;\n case 'Minutes':\n var minute = (minimum.getMinutes() / interval) * interval;\n var endMinute = maximum.getMinutes() + (minimum.getMinutes() - minute);\n if (rangePadding === 'Round') {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), minimum.getDate(), minimum.getHours(), minute, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), maximum.getDate(), maximum.getHours(), endMinute, 59)).getTime();\n }\n else {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), minimum.getDate(), minimum.getHours(), minute + (-interval), 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), maximum.getDate(), maximum.getHours(), endMinute + (interval), 0)).getTime();\n }\n break;\n case 'Seconds':\n var second = (minimum.getSeconds() / interval) * interval;\n var endSecond = maximum.getSeconds() + (minimum.getSeconds() - second);\n if (rangePadding === 'Round') {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), minimum.getDate(), minimum.getHours(), minimum.getMinutes(), second, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), maximum.getDate(), maximum.getHours(), maximum.getMinutes(), endSecond, 0)).getTime();\n }\n else {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), minimum.getDate(), minimum.getHours(), minimum.getMinutes(), second + (-interval), 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), maximum.getDate(), maximum.getHours(), maximum.getMinutes(), endSecond + (interval), 0)).getTime();\n }\n break;\n }\n }\n }\n axis.actualRange.min = (axis.minimum != null) ? this.min : this.min;\n axis.actualRange.max = (axis.maximum != null) ? this.max : this.max;\n axis.actualRange.delta = (axis.actualRange.max - axis.actualRange.min);\n axis.doubleRange = new DoubleRange(axis.actualRange.min, axis.actualRange.max);\n this.calculateVisibleRange(size, axis);\n };\n DateTime.prototype.getYear = function (minimum, maximum, rangePadding, interval) {\n var startYear = minimum.getFullYear();\n var endYear = maximum.getFullYear();\n if (rangePadding === 'Additional') {\n this.min = (new Date(startYear - interval, 1, 1, 0, 0, 0)).getTime();\n this.max = (new Date(endYear + interval, 1, 1, 0, 0, 0)).getTime();\n }\n else {\n this.min = new Date(startYear, 0, 0, 0, 0, 0).getTime();\n this.max = new Date(endYear, 11, 30, 23, 59, 59).getTime();\n }\n };\n DateTime.prototype.getMonth = function (minimum, maximum, rangePadding, interval) {\n var month = minimum.getMonth();\n var endMonth = maximum.getMonth();\n if (rangePadding === 'Round') {\n this.min = (new Date(minimum.getFullYear(), month, 0, 0, 0, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), endMonth, new Date(maximum.getFullYear(), maximum.getMonth(), 0).getDate(), 23, 59, 59)).getTime();\n }\n else {\n this.min = (new Date(minimum.getFullYear(), month + (-interval), 1, 0, 0, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), endMonth + (interval), endMonth === 2 ? 28 : 30, 0, 0, 0)).getTime();\n }\n };\n DateTime.prototype.getDay = function (minimum, maximum, rangePadding, interval) {\n var day = minimum.getDate();\n var endDay = maximum.getDate();\n if (rangePadding === 'Round') {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), day, 0, 0, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), endDay, 23, 59, 59)).getTime();\n }\n else {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), day + (-interval), 0, 0, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), endDay + (interval), 0, 0, 0)).getTime();\n }\n };\n DateTime.prototype.getHour = function (minimum, maximum, rangePadding, interval) {\n var hour = (minimum.getHours() / interval) * interval;\n var endHour = maximum.getHours() + (minimum.getHours() - hour);\n if (rangePadding === 'Round') {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), minimum.getDate(), hour, 0, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), maximum.getDate(), endHour, 59, 59)).getTime();\n }\n else {\n this.min = (new Date(minimum.getFullYear(), minimum.getMonth(), minimum.getDate(), hour + (-interval), 0, 0)).getTime();\n this.max = (new Date(maximum.getFullYear(), maximum.getMonth(), maximum.getDate(), endHour + (interval), 0, 0)).getTime();\n }\n };\n /**\n * Calculate visible range for axis.\n *\n * @private\n */\n DateTime.prototype.calculateVisibleRange = function (size, axis) {\n axis.visibleRange = {\n min: axis.actualRange.min,\n max: axis.actualRange.max,\n interval: axis.actualRange.interval,\n delta: axis.actualRange.delta\n };\n var isLazyLoad = isNullOrUndefined(axis.zoomingScrollBar) ? false : axis.zoomingScrollBar.isLazyLoad;\n if ((isZoomSet(axis)) && !isLazyLoad) {\n axis.calculateVisibleRangeOnZooming(size);\n axis.visibleRange.interval = (axis.enableAutoIntervalOnZooming) ?\n this.calculateDateTimeNiceInterval(axis, size, axis.visibleRange.min, axis.visibleRange.max)\n : axis.visibleRange.interval;\n }\n axis.dateTimeInterval = this.increaseDateTimeInterval(axis, axis.visibleRange.min, axis.visibleRange.interval).getTime()\n - axis.visibleRange.min;\n axis.triggerRangeRender(this.chart, axis.visibleRange.min, axis.visibleRange.max, axis.visibleRange.interval);\n };\n /**\n * Calculate visible labels for the axis.\n *\n * @param {Axis} axis axis\n * @param {Chart | RangeNavigator} chart chart\n * @returns {void}\n * @private\n */\n DateTime.prototype.calculateVisibleLabels = function (axis, chart) {\n axis.visibleLabels = [];\n var tempInterval = axis.visibleRange.min;\n var labelStyle;\n var previousValue;\n var isBlazor = chart.getModuleName() === 'chart' ? chart.isBlazor : false;\n var axisLabels = axis.visibleLabels;\n if (!setRange(axis)) {\n tempInterval = this.alignRangeStart(axis, tempInterval, axis.visibleRange.interval).getTime();\n }\n while (tempInterval <= axis.visibleRange.max) {\n labelStyle = (extend({}, getValue('properties', axis.labelStyle), null, true));\n previousValue = axisLabels.length ? axis.visibleLabels[axisLabels.length - 1].value : tempInterval;\n axis.format = chart.intl.getDateFormat({\n format: this.findCustomFormats(axis, tempInterval, previousValue) || this.blazorCustomFormat(axis),\n type: firstToLowerCase(axis.skeletonType),\n skeleton: this.getSkeleton(axis, tempInterval, previousValue, isBlazor)\n });\n axis.startLabel = axis.format(new Date(axis.visibleRange.min));\n axis.endLabel = axis.format(new Date(axis.visibleRange.max));\n if (withIn(tempInterval, axis.visibleRange)) {\n var interval = this.increaseDateTimeInterval(axis, tempInterval, axis.visibleRange.interval).getTime();\n if (interval > axis.visibleRange.max) {\n axis.endLabel = axis.format(new Date(tempInterval));\n }\n triggerLabelRender(chart, tempInterval, axis.format(new Date(tempInterval)), labelStyle, axis);\n }\n var actualInterval = tempInterval;\n tempInterval = this.increaseDateTimeInterval(axis, tempInterval, axis.visibleRange.interval).getTime();\n if (actualInterval === tempInterval) {\n break;\n }\n }\n //tooltip and crosshair formats for 'Months' and 'Days' interval types\n if ((axis.actualIntervalType === 'Months' || axis.actualIntervalType === 'Days') && axis.isChart) {\n axis.format = chart.intl.getDateFormat({\n format: axis.labelFormat || (axis.actualIntervalType === 'Months' && !axis.skeleton ? 'y MMM' : ''),\n type: firstToLowerCase(axis.skeletonType), skeleton: axis.skeleton || (axis.actualIntervalType === 'Days' ? 'MMMd' : '')\n });\n }\n if (axis.getMaxLabelWidth) {\n axis.getMaxLabelWidth(this.chart);\n }\n };\n /** @private */\n DateTime.prototype.blazorCustomFormat = function (axis) {\n if (this.chart.isBlazor) {\n return axis.actualIntervalType === 'Years' ? (axis.isIntervalInDecimal ? 'yyyy' : 'MMM y') :\n (axis.actualIntervalType === 'Days' && !axis.isIntervalInDecimal) ? 'ddd HH tt' : '';\n }\n else {\n return '';\n }\n };\n /** @private */\n DateTime.prototype.increaseDateTimeInterval = function (axis, value, interval) {\n var result = new Date(value);\n if (axis.interval) {\n axis.isIntervalInDecimal = (interval % 1) === 0;\n axis.visibleRange.interval = interval;\n }\n else {\n interval = Math.ceil(interval);\n axis.visibleRange.interval = interval;\n }\n var intervalType = axis.actualIntervalType;\n if (axis.isIntervalInDecimal) {\n switch (intervalType) {\n case 'Years':\n result.setFullYear(result.getFullYear() + interval);\n return result;\n case 'Quarter':\n result.setMonth(result.getMonth() + (3 * interval));\n return result;\n case 'Months':\n result.setMonth(result.getMonth() + interval);\n return result;\n case 'Weeks':\n result.setDate(result.getDate() + (interval * 7));\n return result;\n case 'Days':\n result.setDate(result.getDate() + interval);\n return result;\n case 'Hours':\n result.setHours(result.getHours() + interval);\n return result;\n case 'Minutes':\n result.setMinutes(result.getMinutes() + interval);\n return result;\n case 'Seconds':\n result.setSeconds(result.getSeconds() + interval);\n return result;\n }\n }\n else {\n result = this.getDecimalInterval(result, interval, intervalType);\n }\n return result;\n };\n DateTime.prototype.alignRangeStart = function (axis, sDate, intervalSize) {\n var sResult = new Date(sDate);\n switch (axis.actualIntervalType) {\n case 'Years':\n var year = Math.floor(Math.floor(sResult.getFullYear() / intervalSize) * intervalSize);\n sResult = new Date(year, sResult.getMonth(), sResult.getDate(), 0, 0, 0);\n return sResult;\n case 'Months':\n var month = Math.floor(Math.floor((sResult.getMonth()) / intervalSize) * intervalSize);\n sResult = new Date(sResult.getFullYear(), month, sResult.getDate(), 0, 0, 0);\n return sResult;\n case 'Days':\n var day = Math.floor(Math.floor((sResult.getDate()) / intervalSize) * intervalSize);\n sResult = new Date(sResult.getFullYear(), sResult.getMonth(), day, 0, 0, 0);\n return sResult;\n case 'Hours':\n var hour = Math.floor(Math.floor((sResult.getHours()) / intervalSize) * intervalSize);\n sResult = new Date(sResult.getFullYear(), sResult.getMonth(), sResult.getDate(), hour, 0, 0);\n return sResult;\n case 'Minutes':\n var minutes = Math.floor(Math.floor((sResult.getMinutes()) / intervalSize) * intervalSize);\n sResult = new Date(sResult.getFullYear(), sResult.getMonth(), sResult.getDate(), sResult.getHours(), minutes, 0, 0);\n return sResult;\n case 'Seconds':\n var seconds = Math.floor(Math.floor((sResult.getSeconds()) / intervalSize) * intervalSize);\n sResult = new Date(sResult.getFullYear(), sResult.getMonth(), sResult.getDate(), sResult.getHours(), sResult.getMinutes(), seconds, 0);\n return sResult;\n }\n return sResult;\n };\n DateTime.prototype.getDecimalInterval = function (result, interval, intervalType) {\n var roundValue = Math.floor(interval);\n var decimalValue = interval - roundValue;\n switch (intervalType) {\n case 'Years':\n var month = Math.round(12 * decimalValue);\n result.setFullYear(result.getFullYear() + roundValue);\n result.setMonth(result.getMonth() + month);\n return result;\n case 'Quarter':\n result.setMonth(result.getMonth() + (3 * interval));\n return result;\n case 'Months':\n var days = Math.round(30 * decimalValue);\n result.setMonth(result.getMonth() + roundValue);\n result.setDate(result.getDate() + days);\n return result;\n case 'Weeks':\n result.setDate(result.getDate() + (interval * 7));\n return result;\n case 'Days':\n var hour = Math.round(24 * decimalValue);\n result.setDate(result.getDate() + roundValue);\n result.setHours(result.getHours() + hour);\n return result;\n case 'Hours':\n var min = Math.round(60 * decimalValue);\n result.setHours(result.getHours() + roundValue);\n result.setMinutes(result.getMinutes() + min);\n return result;\n case 'Minutes':\n var sec = Math.round(60 * decimalValue);\n result.setMinutes(result.getMinutes() + roundValue);\n result.setSeconds(result.getSeconds() + sec);\n return result;\n case 'Seconds':\n var milliSec = Math.round(1000 * decimalValue);\n result.setSeconds(result.getSeconds() + roundValue);\n result.setMilliseconds(result.getMilliseconds() + milliSec);\n return result;\n }\n return result;\n };\n /**\n * Get module name\n */\n DateTime.prototype.getModuleName = function () {\n /**\n * Returns the module name\n */\n return 'DateTime';\n };\n /**\n * To destroy the category axis.\n *\n * @returns {void}\n * @private\n */\n DateTime.prototype.destroy = function () {\n /**\n * Destroy method performed here\n */\n };\n return DateTime;\n}(NiceInterval));\nexport { DateTime };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { EventHandler, getValue, closest, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { addClass, removeClass, extend, Browser } from '@syncfusion/ej2-base';\nimport { CellType } from '../base/enum';\nimport * as event from '../base/constant';\nimport { Row } from '../models/row';\nimport { RowModelGenerator } from './row-model-generator';\nimport { parentsUntil, addRemoveEventListener, findCellIndex } from '../base/util';\nimport * as literals from '../base/string-literals';\n/**\n * FocusStrategy class\n *\n * @hidden\n */\nvar FocusStrategy = /** @class */ (function () {\n function FocusStrategy(parent) {\n this.currentInfo = {};\n this.oneTime = true;\n this.swap = {};\n /** @hidden */\n this.isInfiniteScroll = false;\n this.forget = false;\n this.skipFocus = true;\n this.focusByClick = false;\n this.firstHeaderCellClick = false;\n this.prevIndexes = {};\n this.refMatrix = this.refreshMatrix(true);\n this.actions = ['downArrow', 'upArrow'];\n this.isVirtualScroll = false;\n this.parent = parent;\n this.rowModelGen = new RowModelGenerator(this.parent);\n this.addEventListener();\n }\n FocusStrategy.prototype.focusCheck = function (e) {\n var target = e.target;\n this.focusByClick = true;\n this.firstHeaderCellClick = true;\n this.skipFocus = target.classList.contains('e-grid');\n };\n FocusStrategy.prototype.onFocus = function (e) {\n if (this.parent.isDestroyed || Browser.isDevice || this.parent.enableVirtualization\n || this.parent.element.querySelector('.e-masked-table') || (!this.parent.isInitialLoad && e\n && e.target === this.parent.element && this.parent.element.querySelector('.e-spin-show'))) {\n return;\n }\n this.setActive(!this.parent.enableHeaderFocus && this.parent.frozenRows === 0);\n if (!this.parent.enableHeaderFocus && !this.parent.getCurrentViewRecords().length && ((this.parent.editSettings.mode !== 'Batch')\n || (this.parent.editSettings.mode === 'Batch' && this.parent.editModule && !this.parent.editModule.getBatchChanges()[literals.addedRecords].length))) {\n this.getContent().matrix.\n generate(this.rowModelGen.generateRows({ rows: [new Row({ isDataRow: true })] }), this.getContent().selector, false);\n }\n var current = this.getContent().matrix.get(0, -1, [0, 1], null, this.getContent().validator());\n this.getContent().matrix.select(current[0], current[1]);\n if (this.skipFocus && !(e && e.target === this.parent.element)) {\n this.focus(e);\n this.skipFocus = false;\n }\n };\n FocusStrategy.prototype.passiveFocus = function (e) {\n if (this.parent.isDestroyed) {\n return;\n }\n var firstHeaderCell = this.parent.getHeaderContent().querySelector('.e-headercell:not(.e-hide)');\n if (e.target === firstHeaderCell && e.relatedTarget && !parentsUntil(e.relatedTarget, 'e-grid')\n && !this.firstHeaderCellClick) {\n var firstHeaderCellIndex = [0, 0];\n if (this.active.matrix.matrix[firstHeaderCellIndex[0]][firstHeaderCellIndex[1]] === 0) {\n firstHeaderCellIndex = findCellIndex(this.active.matrix.matrix, firstHeaderCellIndex, true);\n }\n this.active.matrix.current = firstHeaderCellIndex;\n this.currentInfo.element = e.target;\n this.currentInfo.elementToFocus = e.target;\n addClass([this.currentInfo.element], ['e-focused', 'e-focus']);\n }\n this.firstHeaderCellClick = false;\n if (e.target && e.target.classList.contains('e-detailcell')) {\n this.currentInfo.skipAction = false;\n addClass([this.currentInfo.element], ['e-focused', 'e-focus']);\n }\n };\n FocusStrategy.prototype.onBlur = function (e) {\n // The below boolean condition for gantt team focus fix.\n var isGantt = parentsUntil(e.target, 'e-gantt') && e.target.classList.contains('e-rowcell')\n && (!isNullOrUndefined(e.target.nextElementSibling)\n && e.target.nextElementSibling.classList.contains('e-rowcell')) ? true : false;\n if ((this.parent.isEdit || e && (!e.relatedTarget || closest(e.relatedTarget, '.e-grid'))\n && !(this.parent.element.classList.contains('e-childgrid') && !this.parent.element.matches(':focus-within')))\n && !(!isGantt && isNullOrUndefined(e.relatedTarget) && parseInt(e.target.getAttribute('data-colindex'), 10) === 0\n && parseInt(e.target.getAttribute('index'), 10) === 0) && !(!isGantt && isNullOrUndefined(e.relatedTarget)\n && !closest(document.activeElement, '.e-grid') && !isNullOrUndefined(e['sourceCapabilities']))) {\n return;\n }\n this.removeFocus();\n this.skipFocus = true;\n this.currentInfo.skipAction = false;\n this.setLastContentCellTabIndex();\n this.setFirstFocusableTabIndex();\n this.firstHeaderCellClick = false;\n };\n /**\n * @returns {void}\n * @hidden */\n FocusStrategy.prototype.setFirstFocusableTabIndex = function () {\n var gObj = this.parent;\n gObj.element.tabIndex = -1;\n if (gObj.allowGrouping && gObj.groupSettings.showDropArea) {\n var groupModule = gObj.groupModule;\n var focusableGroupedItems = groupModule.getFocusableGroupedItems();\n if (focusableGroupedItems.length > 0) {\n groupModule.element.tabIndex = -1;\n focusableGroupedItems[0].tabIndex = 0;\n }\n else {\n groupModule.element.tabIndex = 0;\n }\n return;\n }\n if (gObj.toolbar || gObj.toolbarTemplate) {\n var toolbarElement = gObj.toolbarModule.element;\n var focusableToolbarItems = this.parent.toolbarModule.getFocusableToolbarItems();\n if (focusableToolbarItems.length > 0 && focusableToolbarItems[0].querySelector('.e-toolbar-item-focus,.e-btn,.e-input')) {\n toolbarElement.tabIndex = -1;\n focusableToolbarItems[0].querySelector('.e-toolbar-item-focus,.e-btn,.e-input').tabIndex = 0;\n }\n else {\n toolbarElement.tabIndex = 0;\n }\n return;\n }\n if (gObj.getColumns().length) {\n var firstHeaderCell = gObj.getHeaderContent().querySelector('.e-headercell:not(.e-hide)');\n firstHeaderCell.tabIndex = 0;\n this.setActive(false);\n if (!isNullOrUndefined(this.active) && (isNullOrUndefined(this.active.target) || !this.active.target.classList.contains('e-columnmenu'))) {\n var firstHeaderCellIndex = [0, 0];\n if (this.active.matrix.matrix[firstHeaderCellIndex[0]][firstHeaderCellIndex[1]] === 0) {\n firstHeaderCellIndex = findCellIndex(this.active.matrix.matrix, firstHeaderCellIndex, true);\n }\n this.active.matrix.current = firstHeaderCellIndex;\n }\n return;\n }\n };\n FocusStrategy.prototype.setLastContentCellTabIndex = function () {\n var contentTable = this.parent.getContentTable();\n if (contentTable.rows[contentTable.rows.length - 1]) {\n var lastCell = contentTable.rows[contentTable.rows.length - 1].lastElementChild;\n lastCell.tabIndex = 0;\n }\n };\n FocusStrategy.prototype.onClick = function (e, force) {\n if (parentsUntil(e.target, 'e-filterbarcell') && (parentsUntil(e.target, 'e-multiselect') ||\n e.target.classList.contains('e-input-group-icon'))) {\n return;\n }\n var isContent = !isNullOrUndefined(closest(e.target, '.' + literals.gridContent));\n var isHeader = !isNullOrUndefined(closest(e.target, '.' + literals.gridHeader));\n isContent = isContent && isHeader ? !isContent : isContent;\n if (!isContent && isNullOrUndefined(closest(e.target, '.' + literals.gridHeader)) ||\n e.target.classList.contains(literals.content) ||\n !isNullOrUndefined(closest(e.target, '.e-unboundcell'))) {\n return;\n }\n this.setActive(isContent);\n if (!isContent && isNullOrUndefined(closest(e.target, '.' + literals.gridHeader))) {\n this.clearOutline();\n return;\n }\n var beforeArgs = { cancel: false, byKey: false, byClick: !isNullOrUndefined(e.target), clickArgs: e };\n this.parent.notify(event.beforeCellFocused, beforeArgs);\n if (beforeArgs.cancel || closest(e.target, '.e-inline-edit')) {\n return;\n }\n this.setActive(isContent);\n if (this.getContent()) {\n var returnVal = this.getContent().onClick(e, force);\n if (returnVal === false) {\n return;\n }\n this.focus();\n if (this.currentInfo.element.classList.contains('e-rowcell') && e.type && e.type === 'click') {\n addClass([this.currentInfo.element], ['e-focused', 'e-focus']);\n }\n }\n };\n FocusStrategy.prototype.handleFilterNavigation = function (e, inputSelector, buttonSelector) {\n if (e.target === document.querySelector(inputSelector) && e.key === 'Tab' && e.shiftKey) {\n e.preventDefault();\n document.querySelector(buttonSelector).focus();\n }\n else if (e.target === document.querySelector(buttonSelector) && e.key === 'Tab' && !e.shiftKey &&\n document.activeElement === document.querySelector(buttonSelector)) {\n e.preventDefault();\n document.querySelector(inputSelector).focus();\n }\n };\n FocusStrategy.prototype.onKeyPress = function (e) {\n if (this.parent.allowPaging) {\n var pagerElement = this.parent.pagerModule.pagerObj.element;\n var focusablePagerElements = this.parent.pagerModule.pagerObj.getFocusablePagerElements(pagerElement, []);\n if (this.parent.childGrid && !parentsUntil(e.target, 'e-gridpager') && this.allowToPaging(e) && focusablePagerElements.length) {\n focusablePagerElements[0].tabIndex = 0;\n }\n if (this.parent.pagerModule.pagerObj.checkPagerHasFocus()) {\n if (e.action === 'shiftTab' && focusablePagerElements.length && focusablePagerElements[0] === e.target) {\n this.setActive(true);\n var lastHeaderCellIndex = [this.active.matrix.matrix.length - 1,\n this.active.matrix.matrix[this.active.matrix.matrix.length - 1].length - 1];\n if (this.active.matrix.matrix[lastHeaderCellIndex[0]][lastHeaderCellIndex[1]] === 0) {\n lastHeaderCellIndex = findCellIndex(this.active.matrix.matrix, lastHeaderCellIndex, false);\n }\n this.active.matrix.current = this.parent.editSettings.mode === 'Batch' ?\n this.isValidBatchEditCell(lastHeaderCellIndex) ? lastHeaderCellIndex :\n this.findBatchEditCell(lastHeaderCellIndex, false) : lastHeaderCellIndex;\n e.preventDefault();\n this.focus(e);\n return;\n }\n if (!(e.action === 'tab' && this.parent.element.classList.contains('e-childgrid')\n && ((!this.parent.pageSettings.pageSizes && focusablePagerElements.length\n && focusablePagerElements[focusablePagerElements.length - 1] === e.target)\n || (this.parent.pagerModule.pagerObj.getDropDownPage() === e.target)))) {\n this.parent.pagerModule.pagerObj.changePagerFocus(e);\n return;\n }\n else {\n var parentCell = parentsUntil(this.parent.element, 'e-detailcell');\n removeClass([this.parent.element], ['e-focus']);\n removeClass([parentCell], ['e-focused']);\n parentCell.tabIndex = -1;\n }\n }\n if (this.parent.pagerModule.pagerObj.element.tabIndex === 0 && (e.keyCode === 38 || (e.shiftKey && e.keyCode === 9))) {\n e.preventDefault();\n this.focus(e);\n return;\n }\n else if (this.parent.pagerModule.pagerObj.element.tabIndex === 0 && e.keyCode === 9) {\n e.preventDefault();\n this.parent.pagerModule.pagerObj.setPagerFocus();\n return;\n }\n if (this.parent.pagerModule.pagerObj.checkFirstPagerFocus()) {\n var lastRow = this.getContent().matrix.rows;\n var lastColumn = this.getContent().matrix.columns;\n this.getContent().matrix.current = [lastRow, lastColumn];\n }\n }\n if (this.parent.filterSettings.type === 'Excel') {\n this.handleFilterNavigation(e, '.e-excelfilter .e-menu-item:not(.e-disabled)', '.e-excelfilter .e-footer-content button:nth-child(2)');\n }\n if (this.parent.filterSettings.type === 'CheckBox') {\n this.handleFilterNavigation(e, '.e-searchinput.e-input', '.e-checkboxfilter .e-footer-content button:nth-child(2)');\n }\n if (this.parent.filterSettings.type === 'Menu') {\n this.handleFilterNavigation(e, '.e-flmenu .e-input-group.e-popup-flmenu', '.e-flmenu .e-footer-content button:nth-child(2)');\n }\n if (this.skipOn(e)) {\n return;\n }\n if (e.target && parentsUntil(e.target, 'e-gridcontent')) {\n var rows = [].slice.call(this.parent.getContentTable().rows);\n var lastCell = rows[rows.length - 1].lastElementChild;\n if (e.target === lastCell) {\n this.setActive(true);\n this.setLastContentCellActive();\n }\n }\n if (e.action === 'shiftTab' && e.target && (e.target === this.parent.element || parentsUntil(e.target, 'e-toolbar')\n || parentsUntil(e.target, 'e-groupdroparea'))) {\n if (e.target === this.parent.element) {\n if (this.parent.element.classList.contains('e-childgrid')) {\n this.focusOutFromChildGrid(e);\n }\n return;\n }\n if (parentsUntil(e.target, 'e-groupdroparea')) {\n if (this.parent.element.classList.contains('e-childgrid')) {\n e.preventDefault();\n this.parent.element.focus();\n }\n return;\n }\n if (parentsUntil(e.target, 'e-toolbar')) {\n if (this.parent.allowGrouping && this.parent.groupSettings.showDropArea) {\n var groupModule = this.parent.groupModule;\n var focusableGroupedItems = groupModule.getFocusableGroupedItems();\n e.preventDefault();\n if (focusableGroupedItems.length > 0) {\n focusableGroupedItems[focusableGroupedItems.length - 1].focus();\n }\n else {\n groupModule.element.focus();\n }\n }\n else if (this.parent.element.classList.contains('e-childgrid')) {\n e.preventDefault();\n this.parent.element.focus();\n }\n return;\n }\n }\n var focusFirstHeaderCell = false;\n if (e.action === 'tab' && e.target && (e.target === this.parent.element || parentsUntil(e.target, 'e-toolbar')\n || parentsUntil(e.target, 'e-groupdroparea'))) {\n if (this.parent.allowGrouping && this.parent.groupSettings.showDropArea\n && (e.target === this.parent.element || e.target.classList.contains('e-groupdroparea'))) {\n var groupModule = this.parent.groupModule;\n var focusableGroupedItems = groupModule.getFocusableGroupedItems();\n if (focusableGroupedItems.length > 0) {\n e.preventDefault();\n focusableGroupedItems[0].focus();\n return;\n }\n if (!e.target.classList.contains('e-groupdroparea')) {\n e.preventDefault();\n groupModule.element.focus();\n return;\n }\n }\n if ((this.parent.toolbar || this.parent.toolbarTemplate) && (e.target === this.parent.element\n || parentsUntil(e.target, 'e-groupdroparea')\n || e.target.classList.contains('e-toolbar'))) {\n var toolbarElement = this.parent.toolbarModule.element;\n var focusableToolbarItems = this.parent.toolbarModule.getFocusableToolbarItems();\n if (focusableToolbarItems.length > 0) {\n e.preventDefault();\n focusableToolbarItems[0].querySelector('.e-toolbar-item-focus,.e-btn,.e-input').focus();\n return;\n }\n if (!e.target.classList.contains('e-toolbar')) {\n e.preventDefault();\n toolbarElement.focus();\n return;\n }\n }\n if (e.target === this.parent.element || parentsUntil(e.target, 'e-toolbar')\n || parentsUntil(e.target, 'e-groupdroparea')) {\n focusFirstHeaderCell = true;\n }\n }\n if (focusFirstHeaderCell) {\n if (this.parent.allowGrouping && this.parent.groupSettings.columns.length === this.parent.columns.length) {\n this.setActive(true);\n }\n else {\n this.setActive(false);\n }\n this.active.matrix.current = [0, -1];\n }\n this.activeKey = e.action;\n var beforeArgs = { cancel: false, byKey: true, byClick: false, keyArgs: e };\n this.parent.notify(event.beforeCellFocused, beforeArgs);\n if (beforeArgs.cancel) {\n return;\n }\n var bValue = this.getContent().matrix.current;\n var prevBatchValue = this.active && this.active.matrix.current ?\n [this.active.matrix.current[0], this.active.matrix.current[1]] : undefined;\n this.currentInfo.outline = true;\n var swapInfo = this.getContent().jump(e.action, bValue);\n this.swap = swapInfo;\n if (swapInfo.swap && !(this.parent.editSettings.mode === 'Batch'\n && (e.action === 'tab' || e.action === 'shiftTab'))) {\n this.setActive(!swapInfo.toHeader);\n this.getContent().matrix.current = this.getContent().getNextCurrent(bValue, swapInfo, this.active, e.action);\n this.prevIndexes = {};\n }\n this.setActiveByKey(e.action, this.getContent());\n var returnVal = this.content.lastIdxCell ? false : this.getContent().onKeyPress(e);\n if (e.target && parentsUntil(e.target, 'e-gridheader')) {\n if (e.action === 'tab' && bValue.toString() === this.active.matrix.current.toString()) {\n var nextHeaderCellIndex = findCellIndex(this.active.matrix.matrix, this.active.matrix.current, true);\n var lastHeaderCellIndex = [this.active.matrix.matrix.length - 1,\n this.active.matrix.matrix[this.active.matrix.matrix.length - 1].length - 1];\n if (this.active.matrix.matrix[lastHeaderCellIndex[0]][lastHeaderCellIndex[1]] === 0) {\n lastHeaderCellIndex = findCellIndex(this.active.matrix.matrix, lastHeaderCellIndex, false);\n }\n if (this.active.matrix.current.toString() === lastHeaderCellIndex.toString() && this.content.matrix.matrix.length) {\n returnVal = true;\n this.setActive(true);\n var firstContentCellIndex = [0, 0];\n if (this.active.matrix.matrix[firstContentCellIndex[0]][firstContentCellIndex[1]] === 0) {\n firstContentCellIndex = findCellIndex(this.active.matrix.matrix, [0, 0], true);\n }\n this.active.matrix.current = this.parent.editSettings.mode === 'Batch' ?\n this.isValidBatchEditCell(firstContentCellIndex) ? firstContentCellIndex :\n this.findBatchEditCell(firstContentCellIndex, true) : firstContentCellIndex;\n }\n else if (this.active.matrix.current.toString() !== nextHeaderCellIndex.toString()) {\n this.active.matrix.current = nextHeaderCellIndex;\n }\n }\n if (e.action === 'shiftTab' && bValue.toString() === this.active.matrix.current.toString()) {\n var previousCellIndex = findCellIndex(this.active.matrix.matrix, this.active.matrix.current, false);\n if (previousCellIndex.toString() === this.active.matrix.current.toString()) {\n this.focusOutFromHeader(e);\n return;\n }\n if (this.active.matrix.current.toString() !== previousCellIndex.toString() && !returnVal) {\n returnVal = true;\n this.active.matrix.current = previousCellIndex;\n }\n }\n }\n if (e.target && parentsUntil(e.target, 'e-gridcontent')) {\n if (this.parent.editSettings.mode === 'Batch' && (e.action === 'tab' || e.action === 'shiftTab')) {\n this.active.matrix.current = this.findBatchEditCell(prevBatchValue, e.action === 'tab' ? true : false);\n if (e.action === 'tab' && prevBatchValue.toString() === this.active.matrix.current.toString()) {\n this.parent.editModule.editModule.addBatchRow = true;\n }\n }\n if (e.action === 'shiftTab' && bValue.toString() === this.active.matrix.current.toString()) {\n if (this.parent.allowGrouping && this.parent.groupSettings.columns.length === this.parent.columns.length) {\n this.focusOutFromHeader(e);\n return;\n }\n var firstContentCellIndex = [0, 0];\n if (this.active.matrix.matrix[firstContentCellIndex[0]][firstContentCellIndex[1]] === 0) {\n firstContentCellIndex = findCellIndex(this.active.matrix.matrix, [0, 0], true);\n }\n if (!returnVal && (firstContentCellIndex.toString() === this.active.matrix.current.toString()\n || (this.parent.editSettings.mode === 'Batch'\n && prevBatchValue.toString() === this.active.matrix.current.toString()))) {\n returnVal = true;\n this.setActive(false);\n this.setLastContentCellActive();\n }\n }\n }\n if (returnVal === false) {\n this.clearIndicator();\n if (e.action === 'shiftTab' && bValue.toString() === [0, 0].toString()) {\n this.parent.element.tabIndex = -1;\n }\n if (this.parent.allowPaging && !this.parent.pagerModule.pagerObj.checkPagerHasFocus() && this.allowToPaging(e)\n && bValue.toString() !== [0, 0].toString()) {\n e.preventDefault();\n if (e.keyCode === 40) {\n this.parent.pagerModule.pagerObj.setPagerContainerFocus();\n return;\n }\n else if (e.keyCode === 9) {\n this.parent.pagerModule.pagerObj.setPagerFocus();\n return;\n }\n }\n if (this.parent.element.classList.contains('e-childgrid')) {\n this.focusOutFromChildGrid(e);\n }\n return;\n }\n e.preventDefault();\n this.focus(e);\n };\n FocusStrategy.prototype.isValidBatchEditCell = function (cellIndex) {\n var cell = this.active.getTable().rows[cellIndex[0]].cells[cellIndex[1]];\n var tr = closest(cell, 'tr');\n var cellColIndex = parseInt(cell.getAttribute('data-colindex'), 10);\n var cellCol = this.parent.getColumns()[parseInt(cellColIndex.toString(), 10)];\n if (this.active.matrix.matrix[cellIndex[0]][cellIndex[1]] === 1\n && (!tr.classList.contains('e-row') || (tr.classList.contains('e-insertedrow') || !cellCol.isPrimaryKey) && cellCol.allowEditing)) {\n return true;\n }\n return false;\n };\n FocusStrategy.prototype.findBatchEditCell = function (currentCellIndex, next, limitRow) {\n var cellIndex = currentCellIndex;\n var tempCellIndex = currentCellIndex;\n var cellIndexObtain = false;\n while (!cellIndexObtain) {\n var prevTempCellIndex = tempCellIndex;\n tempCellIndex = findCellIndex(this.active.matrix.matrix, tempCellIndex, next);\n if ((prevTempCellIndex.toString() === tempCellIndex.toString())\n || (limitRow && prevTempCellIndex[0] !== tempCellIndex[0])) {\n cellIndexObtain = true;\n continue;\n }\n if (this.isValidBatchEditCell(tempCellIndex)) {\n cellIndex = tempCellIndex;\n cellIndexObtain = true;\n }\n }\n return cellIndex;\n };\n FocusStrategy.prototype.setLastContentCellActive = function () {\n var lastContentCellIndex = [this.active.matrix.matrix.length - 1,\n this.active.matrix.matrix[this.active.matrix.matrix.length - 1].length - 1];\n if (this.active.matrix.matrix[lastContentCellIndex[0]][lastContentCellIndex[1]] === 0) {\n lastContentCellIndex = findCellIndex(this.active.matrix.matrix, lastContentCellIndex, false);\n }\n this.active.matrix.current = lastContentCellIndex;\n };\n FocusStrategy.prototype.focusOutFromChildGrid = function (e) {\n var parentTable = parentsUntil(this.parent.element, 'e-table');\n var parentGrid = parentsUntil(parentTable, 'e-grid').ej2_instances[0];\n var parentCell = parentsUntil(this.parent.element, 'e-detailcell');\n var uid = parentsUntil(this.parent.element, 'e-detailrow').getAttribute('data-uid');\n var parentRows = [].slice.call(parentGrid.getContentTable().rows);\n var parentRowIndex = parentRows.map(function (m) { return m.getAttribute('data-uid'); }).indexOf(uid);\n if (e.action === 'tab' && parentRowIndex >= parentRows.length - 1) {\n return;\n }\n removeClass([this.parent.element], ['e-focus']);\n removeClass([parentCell], ['e-focused']);\n parentCell.tabIndex = -1;\n e.preventDefault();\n var nextFocusCell;\n parentGrid.focusModule.removeFocus();\n if (e.action === 'shiftTab') {\n var previousRow = parentRows[parentRowIndex - 1];\n var rowCells = previousRow.cells;\n for (var i = rowCells.length - 1; i >= 0; i--) {\n nextFocusCell = rowCells[parseInt(i.toString(), 10)];\n if (!nextFocusCell.classList.contains('e-hide')) {\n parentGrid.focusModule.active.matrix.current = [parentRowIndex - 1, i];\n break;\n }\n }\n }\n else {\n nextFocusCell = parentRows[parentRowIndex + 1].cells[0];\n parentGrid.focusModule.active.matrix.current = [parentRowIndex + 1, 0];\n }\n parentGrid.focusModule.currentInfo.element = nextFocusCell;\n parentGrid.focusModule.currentInfo.elementToFocus = nextFocusCell;\n addClass([nextFocusCell], ['e-focused', 'e-focus']);\n nextFocusCell.tabIndex = 0;\n nextFocusCell.focus();\n };\n FocusStrategy.prototype.focusOutFromHeader = function (e) {\n this.removeFocus();\n if (this.parent.toolbar || this.parent.toolbarTemplate) {\n var toolbarElement = this.parent.toolbarModule.element;\n var focusableToolbarItems = this.parent.toolbarModule.getFocusableToolbarItems();\n e.preventDefault();\n if (focusableToolbarItems.length > 0) {\n focusableToolbarItems[focusableToolbarItems.length - 1].querySelector('.e-toolbar-item-focus,.e-btn,.e-input').focus();\n }\n else {\n toolbarElement.focus();\n }\n return;\n }\n if (this.parent.allowGrouping && this.parent.groupSettings.showDropArea) {\n var groupModule = this.parent.groupModule;\n var focusableGroupedItems = groupModule.getFocusableGroupedItems();\n e.preventDefault();\n if (focusableGroupedItems.length > 0) {\n focusableGroupedItems[focusableGroupedItems.length - 1].focus();\n }\n else {\n groupModule.element.focus();\n }\n return;\n }\n if (this.parent.element.classList.contains('e-childgrid')) {\n e.preventDefault();\n this.parent.element.focus();\n }\n };\n FocusStrategy.prototype.allowToPaging = function (e) {\n if (this.parent.editSettings.mode === 'Batch' && this.parent.editSettings.allowAdding && e.keyCode !== 40) {\n return false;\n }\n return true;\n };\n FocusStrategy.prototype.skipOn = function (e) {\n var target = e.target;\n if (!target) {\n return false;\n }\n if (this.currentInfo.skipAction) {\n this.clearIndicator();\n return true;\n }\n if (['pageUp', 'pageDown', 'altDownArrow'].indexOf(e.action) > -1) {\n this.clearIndicator();\n return true;\n }\n if (this.parent.allowGrouping) {\n var focusableGroupedItems = this.parent.groupModule.getFocusableGroupedItems();\n if (parentsUntil(e.target, 'e-groupheadercell')\n && !((e.target === focusableGroupedItems[0] && e.action === 'shiftTab')\n || (e.target === focusableGroupedItems[focusableGroupedItems.length - 1] && e.action === 'tab'))) {\n return true;\n }\n }\n if (this.parent.toolbar || this.parent.toolbarTemplate) {\n var toolbarElement = this.parent.toolbarModule.element;\n var focusableToolbarItems = toolbarElement\n .querySelectorAll('.e-toolbar-item:not(.e-overlay):not(.e-hidden)');\n if (parentsUntil(e.target, 'e-toolbar-item')\n && !(focusableToolbarItems.length > 0 && ((parentsUntil(e.target, 'e-toolbar-item') === focusableToolbarItems[0] && e.action === 'shiftTab')\n || (parentsUntil(e.target, 'e-toolbar-item') === focusableToolbarItems[focusableToolbarItems.length - 1] && e.action === 'tab')))) {\n return true;\n }\n }\n var th = closest(target, 'th') && !closest(target, 'th').tabIndex;\n if (e.target.classList.contains('e-filterbaroperator') && (e.keyCode === 13 || e.keyCode === 27)) {\n var inputTarget = closest(e.target, '.e-filterbarcell');\n inputTarget.querySelector('input').focus();\n }\n if (th && closest(document.activeElement, '.e-filterbarcell') !== null) {\n this.removeFocus();\n }\n var filterCell = closest(document.activeElement, '.e-filterbarcell') !== null;\n if (this.parent.enableHeaderFocus && filterCell) {\n var matrix = this.active.matrix;\n var current = matrix.current;\n filterCell = matrix.matrix[current[0]].lastIndexOf(1) !== current[1];\n }\n return (e.action === 'delete'\n || (this.parent.editSettings.mode !== 'Batch' && (this.parent.isEdit || ['insert', 'f2'].indexOf(e.action) > -1))\n || ((filterCell && this.parent.enableHeaderFocus) || (filterCell && e.action !== 'tab' && e.action !== 'shiftTab') ||\n closest(document.activeElement, '#' + this.parent.element.id + '_searchbar') !== null\n && ['enter', 'leftArrow', 'rightArrow',\n 'shiftLeft', 'shiftRight', 'ctrlPlusA'].indexOf(e.action) > -1)\n || (closest(target, '.' + literals.gridContent) === null && closest(target, '.' + literals.gridHeader) === null\n && !(e.target === this.parent.element || parentsUntil(e.target, 'e-toolbar')\n || parentsUntil(e.target, 'e-groupdroparea')))\n || (e.action === 'space' && (!target.classList.contains(literals.gridChkBox) && closest(target, '.' + literals.gridChkBox) === null\n && closest(target, '.e-headerchkcelldiv') === null))) || closest(target, '.e-filter-popup') !== null;\n };\n FocusStrategy.prototype.focusVirtualElement = function (e) {\n var _this = this;\n if (this.parent.enableVirtualization || this.parent.enableInfiniteScrolling) {\n var data = { virtualData: {}, isAdd: false, isCancel: false };\n this.parent.notify(event.getVirtualData, data);\n var isKeyFocus = this.actions.some(function (value) { return value === _this.activeKey; });\n var isSelected = this.parent.contentModule ?\n this.parent.contentModule.selectedRowIndex > -1 : false;\n if (data.isAdd || Object.keys(data.virtualData).length || isKeyFocus || data.isCancel || isSelected) {\n this.parent.notify(event.resetVirtualFocus, { isCancel: false });\n data.isCancel = false;\n this.parent.contentModule.selectedRowIndex = -1;\n if (isKeyFocus) {\n this.activeKey = this.empty;\n this.parent.notify('virtaul-key-handler', e);\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.currentInfo.elementToFocus.focus({ preventScroll: true });\n }\n else {\n if (this.isVirtualScroll || this.isInfiniteScroll) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n this.currentInfo.elementToFocus.focus({ preventScroll: true });\n }\n else {\n this.currentInfo.elementToFocus.focus();\n }\n }\n }\n this.isVirtualScroll = this.isInfiniteScroll = false;\n };\n FocusStrategy.prototype.getFocusedElement = function () {\n return this.currentInfo.elementToFocus;\n };\n FocusStrategy.prototype.getContent = function () {\n return this.active || this.content;\n };\n FocusStrategy.prototype.setActive = function (content) {\n this.active = content ? this.content : this.header;\n };\n FocusStrategy.prototype.setFocusedElement = function (element, e) {\n var _this = this;\n this.currentInfo.elementToFocus = element;\n setTimeout(function () {\n if (!isNullOrUndefined(_this.currentInfo.elementToFocus)) {\n if (_this.parent.enableVirtualization || _this.parent.enableInfiniteScrolling) {\n _this.focusVirtualElement(e);\n }\n else if (isNullOrUndefined(_this.parent.element.querySelector('.e-flmenu')) ||\n parentsUntil(document.activeElement, 'e-flmenu-valuediv') !== _this.parent.element.querySelector('.e-flmenu-valuediv')) {\n _this.currentInfo.elementToFocus.focus();\n }\n }\n }, 0);\n };\n FocusStrategy.prototype.focus = function (e) {\n this.parent.notify(event.virtaulCellFocus, e);\n this.removeFocus();\n this.addFocus(this.getContent().getFocusInfo(), e);\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n FocusStrategy.prototype.removeFocus = function (e) {\n if (!this.currentInfo.element) {\n return;\n }\n if (this.parent.isReact && !this.parent.isEdit && this.currentInfo.element.classList.contains('e-rowcell')\n && !this.currentInfo.element.parentElement && !(this.parent.allowGrouping && this.parent.groupSettings.columns.length) &&\n this.parent.getRowByIndex(this.prevIndexes.rowIndex)) {\n var cellElem = this.parent.getCellFromIndex(this.prevIndexes.rowIndex, this.prevIndexes.cellIndex);\n this.currentInfo.element = cellElem ? cellElem : this.currentInfo.element;\n }\n removeClass([this.currentInfo.element, this.currentInfo.elementToFocus], ['e-focused', 'e-focus']);\n this.currentInfo.element.tabIndex = -1;\n };\n /**\n * @returns {void}\n * @hidden */\n FocusStrategy.prototype.addOutline = function () {\n var info = this.getContent().getFocusInfo();\n if (info.element) {\n addClass([info.element], ['e-focused']);\n addClass([info.elementToFocus], ['e-focus']);\n }\n };\n /**\n * @returns {void}\n * @hidden */\n FocusStrategy.prototype.focusHeader = function () {\n this.setActive(false);\n this.resetFocus();\n };\n /**\n * @returns {void}\n * @hidden */\n FocusStrategy.prototype.focusContent = function () {\n this.setActive(true);\n this.resetFocus();\n };\n FocusStrategy.prototype.resetFocus = function () {\n var current = this.getContent().matrix.get(0, -1, [0, 1], null, this.getContent().validator());\n this.getContent().matrix.select(current[0], current[1]);\n this.focus();\n };\n FocusStrategy.prototype.addFocus = function (info, e) {\n this.currentInfo = info;\n this.currentInfo.outline = info.outline && (!isNullOrUndefined(e) || this.isVirtualScroll);\n if (this.isInfiniteScroll) {\n this.currentInfo.outline = true;\n }\n if (!info.element) {\n return;\n }\n var isFocused = info.elementToFocus.classList.contains('e-focus');\n if (isFocused) {\n return;\n }\n if (this.currentInfo.outline) {\n addClass([info.element], ['e-focused']);\n }\n addClass([info.elementToFocus], ['e-focus']);\n info.element.tabIndex = 0;\n if (!isFocused) {\n this.setFocusedElement(info.elementToFocus, e);\n }\n this.parent.notify(event.cellFocused, {\n element: info.elementToFocus,\n parent: info.element,\n indexes: this.getContent().matrix.current,\n byKey: !isNullOrUndefined(e),\n byClick: isNullOrUndefined(e),\n keyArgs: e,\n isJump: this.swap.swap,\n container: this.getContent().getInfo(e),\n outline: !isNullOrUndefined(e),\n swapInfo: this.swap\n });\n var _a = this.getContent().matrix.current, rowIndex = _a[0], cellIndex = _a[1];\n this.prevIndexes = { rowIndex: rowIndex, cellIndex: cellIndex };\n this.focusedColumnUid = this.parent.getColumnByIndex(cellIndex).uid;\n this.focusByClick = false;\n };\n FocusStrategy.prototype.refreshMatrix = function (content) {\n var _this = this;\n return function (e) {\n if (content && !_this.content) {\n _this.content = new ContentFocus(_this.parent);\n }\n if (!content && !_this.header) {\n _this.header = new HeaderFocus(_this.parent);\n }\n var cFocus = content ? _this.content : _this.header;\n var frozenRow = _this.parent.frozenRows;\n var batchLen = 0;\n if (frozenRow && _this.parent.editSettings.mode === 'Batch') {\n batchLen = _this.parent.getHeaderContent().querySelectorAll('.e-insertedrow').length +\n _this.parent.getHeaderContent().querySelectorAll('.e-hiddenrow').length;\n }\n if (_this.parent.groupSettings.columns.length && frozenRow && content) {\n frozenRow = 0;\n for (var i = 0; i < e.rows.length; i++) {\n frozenRow++;\n if (e.rows[parseInt(i.toString(), 10)].index + 1 === _this.parent.frozenRows) {\n break;\n }\n }\n }\n var rows = content ? e.rows.slice(frozenRow + batchLen) : e.rows;\n var updateRow = content ? e.rows.slice(0, frozenRow + batchLen) : e.rows;\n if (_this.parent.isCollapseStateEnabled() && content) {\n rows = rows.filter(function (x) { return x.visible !== false; });\n }\n var isRowTemplate = !isNullOrUndefined(_this.parent.rowTemplate);\n if (frozenRow && ((_this.parent.editSettings.mode === 'Batch' && content && (e.name === 'batchDelete' || e.name === 'batchAdd' ||\n e.name === 'batchCancel' || (e.args && (e.args.requestType === 'batchsave')))) ||\n (e.args && (e.args.requestType === 'delete' || e.args.requestType === 'save')))) {\n var matrixcs = _this.header.matrix.matrix;\n var hdrLen = _this.parent.headerModule.rows.length;\n matrixcs.splice(hdrLen, matrixcs.length - hdrLen);\n }\n var matrix = cFocus.matrix.generate(updateRow, cFocus.selector, isRowTemplate);\n cFocus.matrix.generate(rows, cFocus.selector, isRowTemplate);\n if (!(_this.parent.isFrozenGrid() && (e.args && (e.args.requestType === 'sorting'\n || e.args.requestType === 'batchsave' || e.args.requestType === 'paging'))) ||\n (frozenRow && _this.parent.editSettings.mode === 'Batch' && content && (e.name === 'batchDelete' || e.name === 'batchAdd' ||\n e.name === 'batchCancel' || e.args.requestType === 'batchsave'\n || e.name === 'batchAdd' || e.name === 'batchCancel'))) {\n cFocus.generateRows(updateRow, {\n matrix: matrix, handlerInstance: _this.header\n });\n }\n if (!Browser.isDevice && e && e.args) {\n if (!_this.focusByClick && e.args.requestType === 'paging' && !_this.parent.pagerModule.pagerObj.checkPagerHasFocus()) {\n _this.skipFocus = false;\n _this.parent.element.focus();\n }\n if (e.args.requestType === 'grouping') {\n _this.skipFocus = true;\n }\n }\n if (e && e.args && e.args.requestType === 'virtualscroll') {\n if (_this.currentInfo.uid) {\n var index_1;\n var bool = e.rows.some(function (row, i) {\n index_1 = i;\n return row.uid === _this.currentInfo.uid;\n });\n if (bool) {\n _this.content.matrix.current[0] = index_1;\n _this.content.matrix.current[1] = _this.parent.getColumnIndexByUid(_this.focusedColumnUid) || 0;\n var focusElement = _this.getContent().getFocusInfo().elementToFocus;\n if (focusElement) {\n var cellPosition = focusElement.getBoundingClientRect();\n var gridPosition = _this.parent.element.getBoundingClientRect();\n if (cellPosition.top >= 0 && cellPosition.left >= 0 &&\n cellPosition.right <= Math.min(gridPosition.right, window.innerWidth ||\n document.documentElement.clientWidth) &&\n cellPosition.bottom <= Math.min(gridPosition.bottom, window.innerHeight ||\n document.documentElement.clientHeight)) {\n _this.isVirtualScroll = true;\n _this.focus();\n }\n }\n }\n }\n else if (e.args.focusElement && e.args.focusElement.classList.contains('e-filtertext')) {\n var focusElement = _this.parent.element.querySelector('#' + e.args.focusElement.id);\n if (focusElement) {\n focusElement.focus();\n }\n }\n }\n if (e && e.args && e.args.requestType === 'infiniteScroll') {\n _this.isInfiniteScroll = true;\n }\n };\n };\n FocusStrategy.prototype.addEventListener = function () {\n var _this = this;\n if (this.parent.isDestroyed) {\n return;\n }\n EventHandler.add(this.parent.element, 'mousedown', this.focusCheck, this);\n EventHandler.add(this.parent.element, 'touchstart', this.focusCheck, this);\n EventHandler.add(this.parent.element, 'focus', this.onFocus, this);\n this.parent.element.addEventListener('focus', this.passiveHandler = function (e) { return _this.passiveFocus(e); }, true);\n EventHandler.add(this.parent.element, 'focusout', this.onBlur, this);\n this.evtHandlers = [{ event: event.keyPressed, handler: this.onKeyPress },\n { event: event.click, handler: this.onClick },\n { event: event.contentReady, handler: this.refMatrix },\n { event: event.partialRefresh, handler: this.refMatrix },\n { event: event.refreshExpandandCollapse, handler: this.refMatrix },\n { event: event.headerRefreshed, handler: this.refreshMatrix() },\n { event: event.closeEdit, handler: this.restoreFocus },\n { event: event.restoreFocus, handler: this.restoreFocus },\n { event: 'start-edit', handler: this.clearIndicator },\n { event: 'start-add', handler: this.clearIndicator },\n { event: 'sorting-complete', handler: this.restoreFocus },\n { event: 'filtering-complete', handler: this.filterfocus },\n { event: 'grouping-complete', handler: this.restoreFocusWithAction },\n { event: 'ungrouping-complete', handler: this.restoreFocusWithAction },\n { event: event.batchAdd, handler: this.refMatrix },\n { event: event.batchCancel, handler: this.refMatrix },\n { event: event.batchDelete, handler: this.refMatrix },\n { event: event.detailDataBound, handler: this.refMatrix },\n { event: event.onEmpty, handler: this.refMatrix },\n { event: event.cellFocused, handler: this.internalCellFocus }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n };\n FocusStrategy.prototype.filterfocus = function () {\n if (this.parent.filterSettings.type !== 'FilterBar') {\n this.restoreFocus();\n }\n };\n FocusStrategy.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n EventHandler.remove(this.parent.element, 'mousedown', this.focusCheck);\n EventHandler.remove(this.parent.element, 'touchstart', this.focusCheck);\n EventHandler.remove(this.parent.element, 'focus', this.onFocus);\n EventHandler.remove(this.parent.element, 'focusout', this.onBlur);\n this.parent.element.removeEventListener('focus', this.passiveHandler, true);\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n };\n FocusStrategy.prototype.destroy = function () {\n this.removeEventListener();\n };\n FocusStrategy.prototype.restoreFocus = function () {\n var groupModule = this.parent.groupModule;\n if (this.parent.allowGrouping && groupModule && (groupModule.groupSortFocus || groupModule.groupTextFocus)) {\n groupModule.groupSortFocus = false;\n groupModule.groupTextFocus = false;\n return;\n }\n this.firstHeaderCellClick = true;\n this.addFocus(this.getContent().getFocusInfo());\n };\n FocusStrategy.prototype.restoreFocusWithAction = function (e) {\n if (!this.parent.enableInfiniteScrolling) {\n var matrix = this.getContent().matrix;\n var current = matrix.current;\n switch (e.requestType) {\n case 'grouping':\n case 'ungrouping':\n current[1] = current.length &&\n !this.parent.groupSettings.showGroupedColumn && !isNullOrUndefined(matrix.matrix[current[0]]) ?\n matrix.matrix[current[0]].indexOf(1) : e.requestType === 'grouping' ? current[1] + 1 : current[1] - 1;\n break;\n }\n this.getContent().matrix.current = current;\n var groupModule = this.parent.groupModule;\n if (this.parent.allowGrouping && groupModule && groupModule.groupCancelFocus) {\n var focusableGroupedItems = groupModule.getFocusableGroupedItems();\n if (focusableGroupedItems.length) {\n if (focusableGroupedItems[0].parentElement.getAttribute('ej-mappingname') === e.columnName) {\n focusableGroupedItems[3].focus();\n }\n else {\n focusableGroupedItems[0].focus();\n }\n }\n else {\n groupModule.element.focus();\n }\n groupModule.groupCancelFocus = false;\n return;\n }\n this.addFocus(this.getContent().getFocusInfo());\n }\n };\n FocusStrategy.prototype.clearOutline = function () {\n this.getContent().matrix.current = this.getContent().matrix.get(0, -1, [0, 1], 'downArrow', this.getContent().validator());\n this.clearIndicator();\n };\n FocusStrategy.prototype.clearIndicator = function () {\n if (!this.currentInfo.element || !this.currentInfo.elementToFocus) {\n return;\n }\n removeClass([this.currentInfo.element, this.currentInfo.elementToFocus], ['e-focus', 'e-focused']);\n };\n FocusStrategy.prototype.getPrevIndexes = function () {\n var forget = this.forget;\n this.forget = false;\n return forget || !Object.keys(this.prevIndexes).length ? { rowIndex: null, cellIndex: null } : this.prevIndexes;\n };\n FocusStrategy.prototype.forgetPrevious = function () {\n this.forget = true;\n };\n FocusStrategy.prototype.setActiveByKey = function (action, active) {\n if (this.parent.frozenRows === 0) {\n return;\n }\n // eslint-disable-next-line prefer-const\n var info;\n var actions = {\n 'home': function () { return ({ toHeader: !info.isContent, toFrozen: true }); },\n 'end': function () { return ({ toHeader: !info.isContent, toFrozen: false }); },\n 'ctrlHome': function () { return ({ toHeader: true, toFrozen: false }); },\n 'ctrlEnd': function () { return ({ toHeader: false, toFrozen: false }); }\n };\n if (!(action in actions)) {\n return;\n }\n info = active.getInfo();\n var swap = actions[\"\" + action]();\n this.setActive(!swap.toHeader);\n this.getContent().matrix.current = active.matrix.current;\n };\n FocusStrategy.prototype.internalCellFocus = function (e) {\n if (!(e.byKey && e.container.isContent && e.keyArgs.action === 'enter'\n && (e.parent.classList.contains('e-detailcell') ||\n e.parent.classList.contains('e-unboundcell')))) {\n return;\n }\n this.clearIndicator();\n var focusEle = this.getContent().getFocusable(this.getFocusedElement());\n this.setFocusedElement(focusEle);\n this.currentInfo.skipAction = true;\n };\n return FocusStrategy;\n}());\nexport { FocusStrategy };\n/**\n * Create matrix from row collection which act as mental model for cell navigation\n *\n * @hidden\n */\nvar Matrix = /** @class */ (function () {\n function Matrix() {\n this.matrix = [];\n this.current = [];\n }\n Matrix.prototype.set = function (rowIndex, columnIndex, allow) {\n rowIndex = Math.max(0, Math.min(rowIndex, this.rows));\n columnIndex = Math.max(0, Math.min(columnIndex, this.columns));\n this.matrix[parseInt(rowIndex.toString(), 10)] = this.matrix[parseInt(rowIndex.toString(), 10)] || [];\n this.matrix[parseInt(rowIndex.toString(), 10)][parseInt(columnIndex.toString(), 10)] = allow ? 1 : 0;\n };\n Matrix.prototype.get = function (rowIndex, columnIndex, navigator, action, validator) {\n var tmp = columnIndex;\n if (rowIndex + navigator[0] < 0) {\n return [rowIndex, columnIndex];\n }\n rowIndex = Math.max(0, Math.min(rowIndex + navigator[0], this.rows));\n var emptyTable = true;\n if (isNullOrUndefined(this.matrix[parseInt(rowIndex.toString(), 10)])) {\n return null;\n }\n columnIndex = Math.max(0, Math.min(columnIndex + navigator[1], this.matrix[parseInt(rowIndex.toString(), 10)].length - 1));\n if (tmp + navigator[1] > this.matrix[parseInt(rowIndex.toString(), 10)].length - 1\n && validator(rowIndex, columnIndex, action)) {\n return [rowIndex, tmp];\n }\n var first = this.first(this.matrix[parseInt(rowIndex.toString(), 10)], columnIndex, navigator, true, action);\n columnIndex = first === null ? tmp : first;\n var val = getValue(rowIndex + \".\" + columnIndex, this.matrix);\n if (rowIndex === this.rows && (action === 'downArrow' || action === 'enter')) {\n navigator[0] = -1;\n }\n if (first === null) {\n for (var i = 0; i < this.rows; i++) {\n if (this.matrix[parseInt(i.toString(), 10)].some(function (v) { return v === 1; })) {\n emptyTable = false;\n break;\n }\n }\n if (emptyTable) {\n rowIndex = this.current.length ? this.current[0] : 0;\n return [rowIndex, columnIndex];\n }\n }\n return this.inValid(val) || !validator(rowIndex, columnIndex, action) ?\n this.get(rowIndex, tmp, navigator, action, validator) : [rowIndex, columnIndex];\n };\n Matrix.prototype.first = function (vector, index, navigator, moveTo, action) {\n if (((index < 0 || index === vector.length) && this.inValid(vector[parseInt(index.toString(), 10)])\n && (action !== 'upArrow' && action !== 'downArrow')) || !vector.some(function (v) { return v === 1; })) {\n return null;\n }\n return !this.inValid(vector[parseInt(index.toString(), 10)]) ? index :\n this.first(vector, (['upArrow', 'downArrow', 'shiftUp', 'shiftDown'].indexOf(action) !== -1) ? moveTo ? 0 : ++index : index + navigator[1], navigator, false, action);\n };\n Matrix.prototype.select = function (rowIndex, columnIndex) {\n rowIndex = Math.max(0, Math.min(rowIndex, this.rows));\n columnIndex = Math.max(0, Math.min(columnIndex, this.matrix[parseInt(rowIndex.toString(), 10)].length - 1));\n this.current = [rowIndex, columnIndex];\n };\n Matrix.prototype.generate = function (rows, selector, isRowTemplate) {\n this.rows = rows.length - 1;\n this.matrix = [];\n for (var i = 0; i < rows.length; i++) {\n var cells = rows[parseInt(i.toString(), 10)].cells.filter(function (c) { return c.isSpanned !== true; });\n this.columns = Math.max(cells.length - 1, this.columns | 0);\n var incrementNumber = 0;\n for (var j = 0; j < cells.length; j++) {\n if (cells[parseInt(j.toString(), 10)].column && cells[parseInt(j.toString(), 10)].column.columns) {\n incrementNumber = this.columnsCount(cells[parseInt(j.toString(), 10)].column.columns, incrementNumber);\n }\n else {\n incrementNumber++;\n }\n this.set(i, j, rows[parseInt(i.toString(), 10)].visible === false ?\n false : selector(rows[parseInt(i.toString(), 10)], cells[parseInt(j.toString(), 10)], isRowTemplate));\n }\n this.columns = Math.max(incrementNumber - 1, this.columns | 0);\n }\n return this.matrix;\n };\n Matrix.prototype.columnsCount = function (rowColumns, currentColumnCount) {\n var columns = rowColumns;\n var incrementNumber = currentColumnCount;\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].columns) {\n incrementNumber = this.columnsCount(columns[parseInt(i.toString(), 10)].columns, incrementNumber);\n }\n else {\n incrementNumber++;\n }\n }\n return incrementNumber;\n };\n Matrix.prototype.inValid = function (value) {\n return value === 0 || value === undefined;\n };\n return Matrix;\n}());\nexport { Matrix };\n/**\n * @hidden\n */\nvar ContentFocus = /** @class */ (function () {\n function ContentFocus(parent) {\n var _this = this;\n this.matrix = new Matrix();\n this.lastIdxCell = false;\n this.parent = parent;\n this.keyActions = {\n 'rightArrow': [0, 1],\n 'tab': [0, 1],\n 'leftArrow': [0, -1],\n 'shiftTab': [0, -1],\n 'upArrow': [-1, 0],\n 'downArrow': [1, 0],\n 'shiftUp': [-1, 0],\n 'shiftDown': [1, 0],\n 'shiftRight': [0, 1],\n 'shiftLeft': [0, -1],\n 'enter': [1, 0],\n 'shiftEnter': [-1, 0]\n };\n this.indexesByKey = function (action) {\n var opt = {\n 'home': [_this.matrix.current[0], -1, 0, 1],\n 'end': [_this.matrix.current[0], _this.matrix.columns + 1, 0, -1],\n 'ctrlHome': [0, -1, 0, 1],\n 'ctrlEnd': [_this.matrix.rows, _this.matrix.columns + 1, 0, -1]\n };\n return opt[\"\" + action] || null;\n };\n }\n ContentFocus.prototype.getTable = function () {\n return (this.parent.getContentTable());\n };\n ContentFocus.prototype.onKeyPress = function (e) {\n var isMacLike = /(Mac)/i.test(navigator.platform);\n if (isMacLike && e.metaKey) {\n if (e.action === 'home') {\n e.action = 'ctrlHome';\n }\n else if (e.action === 'end') {\n e.action = 'ctrlEnd';\n }\n else if (['downArrow', 'upArrow', 'leftArrow', 'rightArrow'].indexOf(e.action) !== -1) {\n return;\n }\n }\n var navigators = this.keyActions[e.action];\n var current = this.getCurrentFromAction(e.action, navigators, e.action in this.keyActions, e);\n if (!current) {\n return;\n }\n if (((['tab', 'shiftTab'].indexOf(e.action) > -1 && this.matrix.current || []).toString() === current.toString())\n || (this.parent.allowPaging && !this.parent.pagerModule.pagerObj.checkPagerHasFocus()\n && this.matrix.current[0] === this.matrix.rows && ((this.parent.editSettings.mode === 'Batch'\n && this.parent.editSettings.allowAdding && e.keyCode === 40) || (e.keyCode === 40)))) {\n if (current.toString() === [this.matrix.rows, this.matrix.columns].toString() ||\n current.toString() === [0, 0].toString() || (this.matrix.current[0] === this.matrix.rows &&\n this.matrix.current.toString() === current.toString()) || (this.parent.allowGrouping &&\n this.parent.infiniteScrollSettings.enableCache && current.toString() === [0, 1].toString())) {\n return false;\n }\n else {\n current = this.editNextRow(current[0], current[1], e.action);\n }\n }\n this.matrix.select(current[0], current[1]);\n };\n ContentFocus.prototype.editNextRow = function (rowIndex, cellIndex, action) {\n var gObj = this.parent;\n var editNextRow = gObj.editSettings.allowNextRowEdit && (gObj.isEdit || gObj.isLastCellPrimaryKey);\n var visibleIndex = gObj.getColumnIndexByField(gObj.getVisibleColumns()[0].field);\n var cell = this.getTable().rows[parseInt(rowIndex.toString(), 10)].cells[parseInt(cellIndex.toString(), 10)];\n if (action === 'tab' && editNextRow) {\n rowIndex++;\n var index = (this.getTable().rows[parseInt(rowIndex.toString(), 10)].getElementsByClassName('e-indentcell').length +\n this.getTable().rows[parseInt(rowIndex.toString(), 10)].getElementsByClassName('e-detailrowcollapse').length);\n cellIndex = visibleIndex + index;\n }\n if (action === 'shiftTab' && editNextRow) {\n rowIndex--;\n cellIndex = gObj.getColumnIndexByField(gObj.getVisibleColumns()[gObj.getVisibleColumns().length - 1].field);\n }\n return !cell.classList.contains(literals.rowCell) && !cell.classList.contains('e-headercell') &&\n !cell.classList.contains('e-groupcaption') && !cell.classList.contains('e-filterbarcell') ?\n this.editNextRow(rowIndex, cellIndex, action) : [rowIndex, cellIndex];\n };\n ContentFocus.prototype.getCurrentFromAction = function (action, navigator, isPresent, e) {\n if (navigator === void 0) { navigator = [0, 0]; }\n if (!isPresent && !this.indexesByKey(action) || (this.matrix.current.length === 0)) {\n return null;\n }\n if (!this.shouldFocusChange(e)) {\n return this.matrix.current;\n }\n // eslint-disable-next-line\n var _a = this.indexesByKey(action) || this.matrix.current.concat(navigator), rowIndex = _a[0], cellIndex = _a[1], rN = _a[2], cN = _a[3];\n if (this.parent.allowGrouping && this.parent.groupSettings.columns.length && this.parent.aggregates.length && action === 'enter') {\n for (var i = rowIndex; i < this.matrix.matrix.length; i++) {\n var row = this.getTable().rows[i + 1];\n if (row && row.cells[parseInt(cellIndex.toString(), 10)] && row.cells[parseInt(cellIndex.toString(), 10)].classList.contains('e-rowcell')) {\n return [i + 1, cellIndex];\n }\n if (i === this.matrix.matrix.length - 1) {\n return [rowIndex, cellIndex];\n }\n }\n }\n if (action === 'ctrlEnd' || action === 'end') {\n var lastContentCellIndex = [this.matrix.matrix.length - 1,\n this.matrix.matrix[this.matrix.matrix.length - 1].length - 1];\n if (action === 'end') {\n lastContentCellIndex = [rowIndex, this.matrix.matrix[parseInt(rowIndex.toString(), 10)].length - 1];\n }\n if (this.matrix.matrix[lastContentCellIndex[0]][lastContentCellIndex[1]] === 0) {\n lastContentCellIndex = findCellIndex(this.matrix.matrix, lastContentCellIndex, false);\n }\n rowIndex = lastContentCellIndex[0];\n cellIndex = lastContentCellIndex[1] + 1;\n }\n var current = this.matrix.get(rowIndex, cellIndex, [rN, cN], action, this.validator());\n return current;\n };\n ContentFocus.prototype.onClick = function (e, force) {\n var target = e.target;\n this.target = target;\n target = (target.classList.contains(literals.rowCell) ? target : closest(target, 'td'));\n target = target ? target : closest(e.target, 'td.e-detailrowcollapse')\n || closest(e.target, 'td.e-detailrowexpand');\n target = closest(e.target, 'td.e-detailcell') ?\n isNullOrUndefined(closest(closest(e.target, '.e-grid'), 'td.e-detailcell')) ? null : target : target;\n target = target && closest(target, 'table').classList.contains(literals.table) ? target : null;\n if (!target) {\n return false;\n }\n var _a = [target.parentElement.rowIndex, target.cellIndex], rowIndex = _a[0], cellIndex = _a[1];\n var _b = this.matrix.current, oRowIndex = _b[0], oCellIndex = _b[1];\n var val = getValue(rowIndex + \".\" + cellIndex, this.matrix.matrix);\n if (this.matrix.inValid(val) || (!force && oRowIndex === rowIndex && oCellIndex === cellIndex) ||\n (!parentsUntil(e.target, literals.rowCell) && !parentsUntil(e.target, 'e-groupcaption')\n && !parentsUntil(e.target, 'e-recordpluscollapse') && !parentsUntil(e.target, 'e-recordplusexpand')\n && !parentsUntil(e.target, 'e-detailrowcollapse') && !parentsUntil(e.target, 'e-detailrowexpand')\n && !parentsUntil(e.target, 'e-templatecell'))) {\n return false;\n }\n this.matrix.select(rowIndex, cellIndex);\n };\n ContentFocus.prototype.getFocusInfo = function () {\n var info = {};\n var _a = this.matrix.current, _b = _a[0], rowIndex = _b === void 0 ? 0 : _b, _c = _a[1], cellIndex = _c === void 0 ? 0 : _c;\n this.matrix.current = [rowIndex, cellIndex];\n info.element = !isNullOrUndefined(this.getTable().rows[parseInt(rowIndex.toString(), 10)]) ?\n this.getTable().rows[parseInt(rowIndex.toString(), 10)].cells[parseInt(cellIndex.toString(), 10)] : null;\n if (!info.element) {\n return info;\n }\n info.elementToFocus = !info.element.classList.contains('e-unboundcell') && !info.element.classList.contains('e-detailcell')\n ? this.getFocusable(info.element) : info.element;\n info.elementToFocus = info.element.classList.contains('e-detailcell') && info.element.querySelector('.e-childgrid')\n ? info.element.querySelector('.e-childgrid') : info.elementToFocus;\n info.outline = true;\n info.uid = info.element.parentElement.getAttribute('data-uid');\n return info;\n };\n ContentFocus.prototype.getFocusable = function (element) {\n var query = 'button, [href], input:not([type=\"hidden\"]), select, textarea, [tabindex]:not([tabindex=\"-1\"])';\n var isTemplate = !isNullOrUndefined(closest(element, '.e-templatecell'));\n if (this.parent.isEdit) {\n query = 'input:not([type=\"hidden\"]), select:not([aria-hidden=\"true\"]), textarea';\n }\n var child = [].slice.call(element.querySelectorAll(query));\n /* Select the first focusable child element\n * if no child found then select the cell itself.\n * if Grid is in editable state, check for editable control inside child.\n */\n return child.length ? isTemplate && child.length > 1 ? this.target ? this.target : element : child[0] : element;\n };\n ContentFocus.prototype.selector = function (row, cell, isRowTemplate) {\n var types = [CellType.Expand, CellType.GroupCaption, CellType.CaptionSummary, CellType.GroupSummary];\n return ((row.isDataRow && cell.visible && (cell.isDataCell || cell.isTemplate))\n || (row.isDataRow && cell.cellType === CellType.DetailExpand && isNullOrUndefined(cell.visible))\n || (!row.isDataRow && types.indexOf(cell.cellType) > -1\n && !((cell.cellType === CellType.GroupSummary || cell.cellType === CellType.CaptionSummary)\n && !(cell.isDataCell && cell.visible)))\n || (cell.column && cell.visible && cell.column.type === 'checkbox')\n || (cell.cellType === CellType.CommandColumn)\n || (row.isDataRow && isRowTemplate))\n && !(row.edit === 'delete' && row.isDirty);\n };\n ContentFocus.prototype.nextRowFocusValidate = function (index) {\n var lastIndex = index;\n for (var i = index, len = this.matrix.rows; i <= len; i++) {\n if (this.matrix.matrix[parseInt(index.toString(), 10)].indexOf(1) === -1) {\n index = index + 1;\n }\n else {\n return index;\n }\n }\n this.lastIdxCell = true;\n return lastIndex;\n };\n ContentFocus.prototype.previousRowFocusValidate = function (index) {\n var firstIndex = index;\n for (var i = index, len = 0; i >= len; i--) {\n if (this.matrix.matrix[parseInt(index.toString(), 10)].indexOf(1) === -1) {\n index = index - 1;\n if (index < 0) {\n this.lastIdxCell = true;\n return firstIndex;\n }\n }\n else {\n return index;\n }\n }\n return firstIndex;\n };\n ContentFocus.prototype.jump = function (action, current) {\n this.lastIdxCell = false;\n var enterFrozen = this.parent.frozenRows !== 0 && action === 'shiftEnter';\n var headerSwap = (action === 'upArrow' || enterFrozen) && current[0] === 0;\n if (action === 'tab' && this.matrix.matrix.length &&\n current[1] === this.matrix.matrix[current[0]].lastIndexOf(1) && this.matrix.matrix.length - 1 !== current[0]) {\n this.matrix.current[0] = this.nextRowFocusValidate(this.matrix.current[0] + 1);\n this.matrix.current[1] = -1;\n }\n if (action === 'shiftTab' &&\n current[0] !== 0 && this.matrix.matrix[current[0]].indexOf(1) === current[1]) {\n this.matrix.current[0] = this.previousRowFocusValidate(this.matrix.current[0] - 1);\n this.matrix.current[1] = this.matrix.matrix[current[0]].length;\n }\n var isHeaderFocus = false;\n var row = parentsUntil(document.activeElement, 'e-row');\n if ((this.parent.enableVirtualization || this.parent.infiniteScrollSettings.enableCache)\n && !isNullOrUndefined(row) && row.classList.contains(literals.row)) {\n var rowIndex = parseInt(row.getAttribute(literals.dataRowIndex), 10);\n isHeaderFocus = rowIndex > 0;\n }\n var info = {\n swap: !isHeaderFocus ? ((action === 'upArrow' || enterFrozen) && current[0] === 0) : false,\n toHeader: headerSwap\n };\n return info;\n };\n ContentFocus.prototype.getNextCurrent = function (previous, swap, active, action) {\n if (previous === void 0) { previous = []; }\n var current = [];\n if (action === 'rightArrow' || action === 'tab') {\n current[0] = previous[0];\n current[1] = -1;\n }\n if (action === 'downArrow' || action === 'enter') {\n current[0] = -1;\n current[1] = previous[1];\n }\n return current;\n };\n ContentFocus.prototype.generateRows = function (rows, optionals) {\n var _a;\n var matrix = optionals.matrix, handlerInstance = optionals.handlerInstance;\n var len = handlerInstance.matrix.matrix.length;\n var defaultLen = this.parent.allowFiltering && this.parent.filterSettings.type === 'FilterBar' ? len + 1 : len;\n handlerInstance.matrix.matrix = handlerInstance.matrix.matrix.slice(0, defaultLen); //Header matrix update.\n handlerInstance.matrix.rows = defaultLen;\n (_a = handlerInstance.matrix.matrix).push.apply(_a, matrix);\n handlerInstance.matrix.rows += matrix.length;\n };\n ContentFocus.prototype.getInfo = function (e) {\n var info = this.getFocusInfo();\n var _a = this.matrix.current, rIndex = _a[0], cIndex = _a[1];\n var isData = info.element.classList.contains(literals.rowCell);\n var isSelectable = isData || (e && e.action !== 'enter' && (info.element.classList.contains('e-detailrowcollapse')\n || info.element.classList.contains('e-detailrowexpand')));\n // eslint-disable-next-line\n var _b = [Math.min(parseInt(info.element.parentElement.getAttribute(literals.dataRowIndex), 10), rIndex),\n Math.min(parseInt(info.element.getAttribute(literals.dataColIndex), 10), cIndex)], rowIndex = _b[0], cellIndex = _b[1];\n if (this.parent.allowGrouping && this.parent.groupSettings.enableLazyLoading && isData) {\n rowIndex = this.parent.getDataRows().indexOf(info.element.parentElement);\n }\n return { isContent: true, isDataCell: isData, indexes: [rowIndex, cellIndex], isSelectable: isSelectable };\n };\n ContentFocus.prototype.validator = function () {\n var table = this.getTable();\n return function (rowIndex, cellIndex, action) {\n if (!isNullOrUndefined(table.rows[parseInt(rowIndex.toString(), 10)])) {\n var cell = void 0;\n cellIndex = table.querySelector('.e-emptyrow') ? 0 : cellIndex;\n if (table.rows[parseInt(rowIndex.toString(), 10)].cells[0].classList.contains('e-editcell')) {\n cell = table.rows[parseInt(rowIndex.toString(), 10)].cells[0].querySelectorAll('td')[parseInt(cellIndex.toString(), 10)];\n }\n else {\n cell = table.rows[parseInt(rowIndex.toString(), 10)].cells[parseInt(cellIndex.toString(), 10)];\n }\n var isCellWidth = cell.getBoundingClientRect().width !== 0;\n if (action === 'enter' || action === 'shiftEnter') {\n return isCellWidth && cell.classList.contains(literals.rowCell);\n }\n if ((action === 'shiftUp' || action === 'shiftDown') && cell.classList.contains(literals.rowCell)) {\n return isCellWidth;\n }\n else if (action !== 'shiftUp' && action !== 'shiftDown') {\n return isCellWidth;\n }\n }\n return false;\n };\n };\n ContentFocus.prototype.shouldFocusChange = function (e) {\n var _a = this.matrix.current, _b = _a[0], rIndex = _b === void 0 ? -1 : _b, _c = _a[1], cIndex = _c === void 0 ? -1 : _c;\n if (rIndex < 0 || cIndex < 0) {\n return true;\n }\n var cell = getValue(rIndex + \".cells.\" + cIndex, this.getTable().rows);\n if (!cell) {\n return true;\n }\n return e.action === 'enter' || e.action === 'shiftEnter' ?\n cell.classList.contains(literals.rowCell) && !cell.classList.contains('e-unboundcell')\n || cell.classList.contains('e-editedbatchcell') && !cell.classList.contains('e-detailcell') : true;\n };\n ContentFocus.prototype.getGridSeletion = function () {\n return this.parent.allowSelection && this.parent.selectionSettings.allowColumnSelection;\n };\n return ContentFocus;\n}());\nexport { ContentFocus };\n/**\n * @hidden\n */\nvar HeaderFocus = /** @class */ (function (_super) {\n __extends(HeaderFocus, _super);\n function HeaderFocus(parent) {\n return _super.call(this, parent) || this;\n }\n HeaderFocus.prototype.getTable = function () {\n return (this.parent.getHeaderTable());\n };\n HeaderFocus.prototype.onClick = function (e) {\n var target = e.target;\n this.target = target;\n target = (target.classList.contains('e-headercell') ? target : closest(target, 'th'));\n if (!target && this.parent.frozenRows !== 0) {\n target = (e.target.classList.contains(literals.rowCell) ? e.target :\n closest(e.target, 'td'));\n }\n if (e.target.classList.contains('e-columnheader') ||\n e.target.querySelector('.e-stackedheadercell')) {\n return false;\n }\n if (!target) {\n return;\n }\n var _a = [target.parentElement.rowIndex, target.cellIndex], rowIndex = _a[0], cellIndex = _a[1];\n var val = getValue(rowIndex + \".\" + cellIndex, this.matrix.matrix);\n if (this.matrix.inValid(val)) {\n return false;\n }\n this.matrix.select(target.parentElement.rowIndex, target.cellIndex);\n };\n HeaderFocus.prototype.getFocusInfo = function () {\n var info = {};\n var _a = this.matrix.current, _b = _a[0], rowIndex = _b === void 0 ? 0 : _b, _c = _a[1], cellIndex = _c === void 0 ? 0 : _c;\n info.element = this.getTable().rows[parseInt(rowIndex.toString(), 10)].cells[parseInt(cellIndex.toString(), 10)];\n if (!isNullOrUndefined(info.element)) {\n info.elementToFocus = this.getFocusable(info.element);\n info.outline = !info.element.classList.contains('e-filterbarcell');\n }\n return info;\n };\n HeaderFocus.prototype.selector = function (row, cell) {\n return (cell.visible && (cell.column.field !== undefined || cell.isTemplate || !isNullOrUndefined(cell.column.template)\n || !isNullOrUndefined(cell.column.commands))) || cell.column.type === 'checkbox' || cell.cellType === CellType.StackedHeader;\n };\n HeaderFocus.prototype.jump = function (action, current) {\n var enterFrozen = this.parent.frozenRows !== 0 && action === 'enter';\n var isLastCell;\n var lastRow;\n if (this.parent.enableHeaderFocus && action === 'tab') {\n lastRow = this.matrix.matrix.length - 1 === current[0];\n isLastCell = current[1] === this.matrix.matrix[current[0]].lastIndexOf(1);\n if (isLastCell) {\n if (!lastRow) {\n this.matrix.current[0] = this.matrix.current[0] + 1;\n }\n else {\n this.matrix.current[0] = 0;\n }\n this.matrix.current[1] = -1;\n }\n }\n return {\n swap: ((action === 'downArrow' || enterFrozen) && current[0] === this.matrix.matrix.length - 1) ||\n (action === 'tab' && lastRow && isLastCell)\n };\n };\n HeaderFocus.prototype.getNextCurrent = function (previous, swap, active, action) {\n if (previous === void 0) { previous = []; }\n var current1 = [];\n if (action === 'rightArrow' || (action === 'shiftRight' && this.getGridSeletion()) || action === 'tab') {\n current1[0] = previous[0];\n current1[1] = -1;\n }\n if (action === 'upArrow' || action === 'shiftEnter') {\n current1[0] = this.matrix.matrix.length;\n current1[1] = previous[1];\n }\n return current1;\n };\n HeaderFocus.prototype.generateRows = function (rows) {\n var length = this.matrix.matrix.length;\n if (this.parent.allowFiltering && this.parent.filterSettings.type === 'FilterBar') {\n this.matrix.rows = ++this.matrix.rows;\n var cells = rows[0].cells;\n var incrementNumber = 0;\n for (var i = 0; i < cells.length; i++) {\n if (cells[parseInt(i.toString(), 10)].column && cells[parseInt(i.toString(), 10)].column.columns) {\n incrementNumber = this.checkFilterColumn(cells[parseInt(i.toString(), 10)].column.columns, length, incrementNumber);\n }\n else {\n this.matrix.set(length, incrementNumber, cells[parseInt(i.toString(), 10)].visible && cells[parseInt(i.toString(), 10)].column.allowFiltering !== false);\n incrementNumber++;\n }\n }\n }\n };\n HeaderFocus.prototype.checkFilterColumn = function (rowColumns, rowIndex, columnIndex) {\n var columns = rowColumns;\n var incrementNumber = columnIndex;\n for (var i = 0; i < columns.length; i++) {\n if (columns[parseInt(i.toString(), 10)].columns) {\n incrementNumber = this.checkFilterColumn(columns[parseInt(i.toString(), 10)].columns, rowIndex, incrementNumber);\n }\n else {\n this.matrix.set(rowIndex, incrementNumber, columns[parseInt(i.toString(), 10)].visible && columns[parseInt(i.toString(), 10)].allowFiltering !== false);\n incrementNumber++;\n }\n }\n return incrementNumber;\n };\n HeaderFocus.prototype.getInfo = function (e) {\n return extend(_super.prototype.getInfo.call(this, e), { isContent: false, isHeader: true });\n };\n HeaderFocus.prototype.validator = function () {\n return function () { return true; };\n };\n HeaderFocus.prototype.shouldFocusChange = function (e) {\n var _a = this.matrix.current, rowIndex = _a[0], columnIndex = _a[1];\n if (rowIndex < 0 || columnIndex < 0) {\n return true;\n }\n var cell = getValue(rowIndex + \".cells.\" + columnIndex, this.getTable().rows);\n if (!cell) {\n return true;\n }\n return e.action === 'enter' || e.action === 'altDownArrow' ? !cell.classList.contains('e-headercell') : true;\n };\n HeaderFocus.prototype.getHeaderType = function () {\n return 'HeaderFocus';\n };\n return HeaderFocus;\n}(ContentFocus));\nexport { HeaderFocus };\n/** @hidden */\nvar SearchBox = /** @class */ (function () {\n function SearchBox(searchBox, serviceLocator) {\n this.searchBox = searchBox;\n this.serviceLocator = serviceLocator;\n this.l10n = this.serviceLocator.getService('localization');\n }\n SearchBox.prototype.searchFocus = function (args) {\n args.target.parentElement.classList.add('e-input-focus');\n if (args.target.classList.contains('e-input') && args.target.classList.contains('e-search') && args.target.value) {\n var sIcon = args.target.parentElement.querySelector('.e-sicon');\n sIcon.classList.add('e-clear-icon');\n sIcon.setAttribute('title', this.l10n.getConstant('ClearButton'));\n (sIcon).style.cursor = 'pointer';\n }\n };\n SearchBox.prototype.searchBlur = function (args) {\n var relatedTarget = args.relatedTarget ? args.relatedTarget : null;\n if (relatedTarget && relatedTarget.classList.contains('e-sicon')) {\n if (relatedTarget.classList.contains('e-clear-icon')) {\n args.target.parentElement.classList.remove('e-input-focus');\n }\n }\n else {\n args.target.parentElement.classList.remove('e-input-focus');\n }\n if (args.target.classList.contains('e-search') && ((relatedTarget && !(relatedTarget.classList.contains('e-sicon e-clear-icon'))\n && !(relatedTarget.classList.contains('e-sicon'))) || isNullOrUndefined(relatedTarget))) {\n var sIcon = args.target.parentElement.querySelector('.e-sicon');\n sIcon.classList.remove('e-clear-icon');\n sIcon.removeAttribute('title');\n sIcon.style.cursor = 'default';\n }\n };\n SearchBox.prototype.wireEvent = function () {\n if (this.searchBox) {\n EventHandler.add(this.searchBox, 'focus', this.searchFocus, this);\n EventHandler.add(this.searchBox, 'blur', this.searchBlur, this);\n }\n };\n SearchBox.prototype.unWireEvent = function () {\n if (this.searchBox) {\n EventHandler.remove(this.searchBox, 'focus', this.searchFocus);\n EventHandler.remove(this.searchBox, 'blur', this.searchBlur);\n }\n };\n return SearchBox;\n}());\nexport { SearchBox };\n","//! moment.js locale configuration\n//! locale : Hebrew [he]\n//! author : Tomer Cohen : https://github.com/tomer\n//! author : Moshe Simantov : https://github.com/DevelopmentIL\n//! author : Tal Ater : https://github.com/TalAter\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var he = moment.defineLocale('he', {\n months: '×™× ×•×ר_פברו×ר_מרץ_×פריל_מ××™_×™×•× ×™_יולי_×וגוסט_ספטמבר_×וקטובר_× ×•×‘×ž×‘×¨_דצמבר'.split(\n '_'\n ),\n monthsShort:\n '×™× ×•×³_פבר׳_מרץ_×פר׳_מ××™_×™×•× ×™_יולי_×וג׳_ספט׳_×וק׳_× ×•×‘×³_דצמ׳'.split('_'),\n weekdays: 'ר×שון_×©× ×™_שלישי_רביעי_חמישי_שישי_שבת'.split('_'),\n weekdaysShort: '×׳_ב׳_ג׳_ד׳_ה׳_ו׳_ש׳'.split('_'),\n weekdaysMin: '×_ב_×’_ד_×”_ו_ש'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D [ב]MMMM YYYY',\n LLL: 'D [ב]MMMM YYYY HH:mm',\n LLLL: 'dddd, D [ב]MMMM YYYY HH:mm',\n l: 'D/M/YYYY',\n ll: 'D MMM YYYY',\n lll: 'D MMM YYYY HH:mm',\n llll: 'ddd, D MMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[×”×™×•× ×‘Ö¾]LT',\n nextDay: '[מחר ב־]LT',\n nextWeek: 'dddd [בשעה] LT',\n lastDay: '[×תמול ב־]LT',\n lastWeek: '[ביו×] dddd [×”×חרון בשעה] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'בעוד %s',\n past: '×œ×¤× ×™ %s',\n s: 'מספר ×©× ×™×•×ª',\n ss: '%d ×©× ×™×•×ª',\n m: 'דקה',\n mm: '%d דקות',\n h: 'שעה',\n hh: function (number) {\n if (number === 2) {\n return 'שעתיי×';\n }\n return number + ' שעות';\n },\n d: 'יו×',\n dd: function (number) {\n if (number === 2) {\n return 'יומיי×';\n }\n return number + ' ימי×';\n },\n M: 'חודש',\n MM: function (number) {\n if (number === 2) {\n return 'חודשיי×';\n }\n return number + ' חודשי×';\n },\n y: '×©× ×”',\n yy: function (number) {\n if (number === 2) {\n return '×©× ×ª×™×™×';\n } else if (number % 10 === 0 && number !== 10) {\n return number + ' ×©× ×”';\n }\n return number + ' ×©× ×™×';\n },\n },\n meridiemParse:\n /××—×”\"צ|×œ×¤× ×”\"צ|×חרי הצהריי×|×œ×¤× ×™ הצהריי×|×œ×¤× ×•×ª בוקר|בבוקר|בערב/i,\n isPM: function (input) {\n return /^(××—×”\"צ|×חרי הצהריי×|בערב)$/.test(input);\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 5) {\n return '×œ×¤× ×•×ª בוקר';\n } else if (hour < 10) {\n return 'בבוקר';\n } else if (hour < 12) {\n return isLower ? '×œ×¤× ×”\"צ' : '×œ×¤× ×™ הצהריי×';\n } else if (hour < 18) {\n return isLower ? '××—×”\"צ' : '×חרי הצהריי×';\n } else {\n return 'בערב';\n }\n },\n });\n\n return he;\n\n})));\n","import { print as printWindow, createElement } from '@syncfusion/ej2-base';\nimport { getElement } from '../utils/helper';\nimport { beforePrint } from '../model/constants';\nvar PrintUtils = /** @class */ (function () {\n /**\n * Constructor for chart and accumulation annotation\n *\n * @param control\n */\n function PrintUtils(control) {\n this.control = control;\n }\n /**\n * To print the accumulation and chart elements.\n *\n * @param elements\n */\n PrintUtils.prototype.print = function (elements) {\n this.printWindow = window.open('', 'print', 'height=' + window.outerHeight + ',width=' + window.outerWidth + ',tabbar=no');\n this.printWindow.moveTo(0, 0);\n this.printWindow.resizeTo(screen.availWidth, screen.availHeight);\n var argsData = {\n cancel: false, htmlContent: this.getHTMLContent(elements), name: beforePrint\n };\n this.control.trigger(beforePrint, argsData);\n if (!argsData.cancel) {\n printWindow(argsData.htmlContent, this.printWindow);\n }\n };\n /**\n * To get the html string of the chart and accumulation\n *\n * @param elements\n * @private\n */\n PrintUtils.prototype.getHTMLContent = function (elements) {\n var div = createElement('div');\n if (elements) {\n if (elements instanceof Array) {\n for (var j = 0; j < elements.length; j++) {\n var value = elements[j];\n div.appendChild(getElement(value).cloneNode(true));\n }\n }\n else if (elements instanceof Element) {\n div.appendChild(elements.cloneNode(true));\n }\n else {\n div.appendChild(getElement(elements).cloneNode(true));\n }\n }\n else {\n div.appendChild(this.control.element.cloneNode(true));\n }\n for (var index = 0; index < div.children.length; index++) {\n var backgroundColor = (this.control.theme.indexOf('Dark') > -1 || this.control.theme === 'HighContrast') ? 'rgba(0, 0, 0, 1)' : 'rgba(255, 255, 255, 1)';\n var svg = div.children[index];\n for (var childIndex = 0; childIndex < svg.children.length; childIndex++) {\n var actualBackgroundColor = void 0;\n var isSVG = false;\n if (svg.id.indexOf('_stockChart_svg') > -1) {\n actualBackgroundColor = svg.children[0].getAttribute('fill');\n isSVG = true;\n }\n else if (svg.children[childIndex].id.indexOf('_svg') > -1) {\n actualBackgroundColor = svg.children[childIndex].children[0].getAttribute('fill');\n isSVG = true;\n }\n if (isSVG) {\n actualBackgroundColor = actualBackgroundColor === 'transparent' ? backgroundColor : actualBackgroundColor;\n svg.children[childIndex].children[0].setAttribute('fill', actualBackgroundColor);\n }\n }\n div[index] = svg;\n }\n return div;\n };\n return PrintUtils;\n}());\nexport { PrintUtils };\n","//! moment.js locale configuration\n//! locale : Albanian [sq]\n//! author : Flakërim Ismani : https://github.com/flakerimi\n//! author : Menelion Elensúle : https://github.com/Oire\n//! author : Oerd Cukalla : https://github.com/oerd\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var sq = moment.defineLocale('sq', {\n months: 'Janar_Shkurt_Mars_Prill_Maj_Qershor_Korrik_Gusht_Shtator_Tetor_Nëntor_Dhjetor'.split(\n '_'\n ),\n monthsShort: 'Jan_Shk_Mar_Pri_Maj_Qer_Kor_Gus_Sht_Tet_Nën_Dhj'.split('_'),\n weekdays: 'E Diel_E Hënë_E Martë_E Mërkurë_E Enjte_E Premte_E Shtunë'.split(\n '_'\n ),\n weekdaysShort: 'Die_Hën_Mar_Mër_Enj_Pre_Sht'.split('_'),\n weekdaysMin: 'D_H_Ma_Më_E_P_Sh'.split('_'),\n weekdaysParseExact: true,\n meridiemParse: /PD|MD/,\n isPM: function (input) {\n return input.charAt(0) === 'M';\n },\n meridiem: function (hours, minutes, isLower) {\n return hours < 12 ? 'PD' : 'MD';\n },\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Sot në] LT',\n nextDay: '[Nesër në] LT',\n nextWeek: 'dddd [në] LT',\n lastDay: '[Dje në] LT',\n lastWeek: 'dddd [e kaluar në] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'në %s',\n past: '%s më parë',\n s: 'disa sekonda',\n ss: '%d sekonda',\n m: 'një minutë',\n mm: '%d minuta',\n h: 'një orë',\n hh: '%d orë',\n d: 'një ditë',\n dd: '%d ditë',\n M: 'një muaj',\n MM: '%d muaj',\n y: 'një vit',\n yy: '%d vite',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return sq;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Property, ChildProperty, Complex, Collection, Browser } from '@syncfusion/ej2-base';\n/**\n * Defines the appearance of the connectors\n */\nvar Connector = /** @class */ (function (_super) {\n __extends(Connector, _super);\n function Connector() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Line')\n ], Connector.prototype, \"type\", void 0);\n __decorate([\n Property(null)\n ], Connector.prototype, \"color\", void 0);\n __decorate([\n Property(1)\n ], Connector.prototype, \"width\", void 0);\n __decorate([\n Property(null)\n ], Connector.prototype, \"length\", void 0);\n __decorate([\n Property('')\n ], Connector.prototype, \"dashArray\", void 0);\n return Connector;\n}(ChildProperty));\nexport { Connector };\n/**\n * Configures the borders in the chart title.\n */\nvar titleBorder = /** @class */ (function (_super) {\n __extends(titleBorder, _super);\n function titleBorder() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('transparent')\n ], titleBorder.prototype, \"color\", void 0);\n __decorate([\n Property(0)\n ], titleBorder.prototype, \"width\", void 0);\n __decorate([\n Property(0.8)\n ], titleBorder.prototype, \"cornerRadius\", void 0);\n return titleBorder;\n}(ChildProperty));\nexport { titleBorder };\n/**\n * Configures the title settings in chart and 3D chart.\n */\nvar titleSettings = /** @class */ (function (_super) {\n __extends(titleSettings, _super);\n function titleSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Normal')\n ], titleSettings.prototype, \"fontStyle\", void 0);\n __decorate([\n Property('15px')\n ], titleSettings.prototype, \"size\", void 0);\n __decorate([\n Property('500')\n ], titleSettings.prototype, \"fontWeight\", void 0);\n __decorate([\n Property('')\n ], titleSettings.prototype, \"color\", void 0);\n __decorate([\n Property('Center')\n ], titleSettings.prototype, \"textAlignment\", void 0);\n __decorate([\n Property('Segoe UI')\n ], titleSettings.prototype, \"fontFamily\", void 0);\n __decorate([\n Property(1)\n ], titleSettings.prototype, \"opacity\", void 0);\n __decorate([\n Property('Wrap')\n ], titleSettings.prototype, \"textOverflow\", void 0);\n __decorate([\n Property('Top')\n ], titleSettings.prototype, \"position\", void 0);\n __decorate([\n Property(0)\n ], titleSettings.prototype, \"x\", void 0);\n __decorate([\n Property(0)\n ], titleSettings.prototype, \"y\", void 0);\n __decorate([\n Property('transparent')\n ], titleSettings.prototype, \"background\", void 0);\n __decorate([\n Complex({}, titleBorder)\n ], titleSettings.prototype, \"border\", void 0);\n return titleSettings;\n}(ChildProperty));\nexport { titleSettings };\n/**\n * Configures the location for the legend.\n */\nvar Location = /** @class */ (function (_super) {\n __extends(Location, _super);\n function Location() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0)\n ], Location.prototype, \"x\", void 0);\n __decorate([\n Property(0)\n ], Location.prototype, \"y\", void 0);\n return Location;\n}(ChildProperty));\nexport { Location };\n/**\n * Configures the fonts in charts.\n */\nvar Font = /** @class */ (function (_super) {\n __extends(Font, _super);\n function Font() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Normal')\n ], Font.prototype, \"fontStyle\", void 0);\n __decorate([\n Property('16px')\n ], Font.prototype, \"size\", void 0);\n __decorate([\n Property('Normal')\n ], Font.prototype, \"fontWeight\", void 0);\n __decorate([\n Property('')\n ], Font.prototype, \"color\", void 0);\n __decorate([\n Property('Center')\n ], Font.prototype, \"textAlignment\", void 0);\n __decorate([\n Property('Segoe UI')\n ], Font.prototype, \"fontFamily\", void 0);\n __decorate([\n Property(1)\n ], Font.prototype, \"opacity\", void 0);\n __decorate([\n Property('Wrap')\n ], Font.prototype, \"textOverflow\", void 0);\n return Font;\n}(ChildProperty));\nexport { Font };\n/**\n * Configures the borders in the chart.\n */\nvar Border = /** @class */ (function (_super) {\n __extends(Border, _super);\n function Border() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('')\n ], Border.prototype, \"color\", void 0);\n __decorate([\n Property(1)\n ], Border.prototype, \"width\", void 0);\n return Border;\n}(ChildProperty));\nexport { Border };\n/**\n * Configures the marker position in the chart.\n */\nvar Offset = /** @class */ (function (_super) {\n __extends(Offset, _super);\n function Offset() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0)\n ], Offset.prototype, \"x\", void 0);\n __decorate([\n Property(0)\n ], Offset.prototype, \"y\", void 0);\n return Offset;\n}(ChildProperty));\nexport { Offset };\n/**\n * Configures the chart area.\n */\nvar ChartArea = /** @class */ (function (_super) {\n __extends(ChartArea, _super);\n function ChartArea() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Complex({}, Border)\n ], ChartArea.prototype, \"border\", void 0);\n __decorate([\n Property('transparent')\n ], ChartArea.prototype, \"background\", void 0);\n __decorate([\n Property(1)\n ], ChartArea.prototype, \"opacity\", void 0);\n __decorate([\n Property(null)\n ], ChartArea.prototype, \"backgroundImage\", void 0);\n __decorate([\n Property(null)\n ], ChartArea.prototype, \"width\", void 0);\n return ChartArea;\n}(ChildProperty));\nexport { ChartArea };\n/**\n * Configures the chart margins.\n */\nvar Margin = /** @class */ (function (_super) {\n __extends(Margin, _super);\n function Margin() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(Browser.isDevice ? 5 : 10)\n ], Margin.prototype, \"left\", void 0);\n __decorate([\n Property(Browser.isDevice ? 5 : 10)\n ], Margin.prototype, \"right\", void 0);\n __decorate([\n Property(Browser.isDevice ? 5 : 10)\n ], Margin.prototype, \"top\", void 0);\n __decorate([\n Property(Browser.isDevice ? 5 : 10)\n ], Margin.prototype, \"bottom\", void 0);\n return Margin;\n}(ChildProperty));\nexport { Margin };\n/**\n * Configures the chart Legend Container Padding.\n */\nvar ContainerPadding = /** @class */ (function (_super) {\n __extends(ContainerPadding, _super);\n function ContainerPadding() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0)\n ], ContainerPadding.prototype, \"left\", void 0);\n __decorate([\n Property(0)\n ], ContainerPadding.prototype, \"right\", void 0);\n __decorate([\n Property(0)\n ], ContainerPadding.prototype, \"top\", void 0);\n __decorate([\n Property(0)\n ], ContainerPadding.prototype, \"bottom\", void 0);\n return ContainerPadding;\n}(ChildProperty));\nexport { ContainerPadding };\n/**\n * Configures the animation behavior for chart series.\n */\nvar Animation = /** @class */ (function (_super) {\n __extends(Animation, _super);\n function Animation() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(true)\n ], Animation.prototype, \"enable\", void 0);\n __decorate([\n Property(1000)\n ], Animation.prototype, \"duration\", void 0);\n __decorate([\n Property(0)\n ], Animation.prototype, \"delay\", void 0);\n return Animation;\n}(ChildProperty));\nexport { Animation };\n/**\n * Series and point index\n *\n * @public\n */\nvar Indexes = /** @class */ (function (_super) {\n __extends(Indexes, _super);\n function Indexes() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0)\n ], Indexes.prototype, \"series\", void 0);\n __decorate([\n Property(0)\n ], Indexes.prototype, \"point\", void 0);\n return Indexes;\n}(ChildProperty));\nexport { Indexes };\n/**\n * Column series rounded corner options\n */\nvar CornerRadius = /** @class */ (function (_super) {\n __extends(CornerRadius, _super);\n function CornerRadius() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(0)\n ], CornerRadius.prototype, \"topLeft\", void 0);\n __decorate([\n Property(0)\n ], CornerRadius.prototype, \"topRight\", void 0);\n __decorate([\n Property(0)\n ], CornerRadius.prototype, \"bottomLeft\", void 0);\n __decorate([\n Property(0)\n ], CornerRadius.prototype, \"bottomRight\", void 0);\n return CornerRadius;\n}(ChildProperty));\nexport { CornerRadius };\n/**\n * @private\n */\nvar Index = /** @class */ (function () {\n function Index(seriesIndex, pointIndex) {\n this.series = seriesIndex;\n this.point = pointIndex;\n }\n return Index;\n}());\nexport { Index };\n/**\n * Configures the Empty Points of series\n */\nvar EmptyPointSettings = /** @class */ (function (_super) {\n __extends(EmptyPointSettings, _super);\n function EmptyPointSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], EmptyPointSettings.prototype, \"fill\", void 0);\n __decorate([\n Complex({ color: 'transparent', width: 0 }, Border)\n ], EmptyPointSettings.prototype, \"border\", void 0);\n __decorate([\n Property('Gap')\n ], EmptyPointSettings.prototype, \"mode\", void 0);\n return EmptyPointSettings;\n}(ChildProperty));\nexport { EmptyPointSettings };\n/**\n * Configures the drag settings of series\n */\nvar DragSettings = /** @class */ (function (_super) {\n __extends(DragSettings, _super);\n function DragSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], DragSettings.prototype, \"enable\", void 0);\n __decorate([\n Property(null)\n ], DragSettings.prototype, \"minY\", void 0);\n __decorate([\n Property(null)\n ], DragSettings.prototype, \"maxY\", void 0);\n __decorate([\n Property(null)\n ], DragSettings.prototype, \"fill\", void 0);\n return DragSettings;\n}(ChildProperty));\nexport { DragSettings };\n/**\n * Options to customize the center label of the pie and doughnut chart.\n *\n * @default {}\n */\nvar CenterLabel = /** @class */ (function (_super) {\n __extends(CenterLabel, _super);\n function CenterLabel() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(null)\n ], CenterLabel.prototype, \"text\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"16px\", fontStyle: 'Normal', fontWeight: '600', color: null }, Font)\n ], CenterLabel.prototype, \"textStyle\", void 0);\n __decorate([\n Property(null)\n ], CenterLabel.prototype, \"hoverTextFormat\", void 0);\n return CenterLabel;\n}(ChildProperty));\nexport { CenterLabel };\n/**\n * Configures the ToolTips in the chart.\n *\n * @public\n */\nvar TooltipSettings = /** @class */ (function (_super) {\n __extends(TooltipSettings, _super);\n function TooltipSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], TooltipSettings.prototype, \"enable\", void 0);\n __decorate([\n Property(true)\n ], TooltipSettings.prototype, \"enableMarker\", void 0);\n __decorate([\n Property(false)\n ], TooltipSettings.prototype, \"shared\", void 0);\n __decorate([\n Property(null)\n ], TooltipSettings.prototype, \"fill\", void 0);\n __decorate([\n Property(null)\n ], TooltipSettings.prototype, \"header\", void 0);\n __decorate([\n Property(null)\n ], TooltipSettings.prototype, \"opacity\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"12px\", fontStyle: 'Normal', fontWeight: null, color: null }, Font)\n ], TooltipSettings.prototype, \"textStyle\", void 0);\n __decorate([\n Property(null)\n ], TooltipSettings.prototype, \"format\", void 0);\n __decorate([\n Property(null)\n ], TooltipSettings.prototype, \"template\", void 0);\n __decorate([\n Property(true)\n ], TooltipSettings.prototype, \"enableAnimation\", void 0);\n __decorate([\n Property(300)\n ], TooltipSettings.prototype, \"duration\", void 0);\n __decorate([\n Property(1000)\n ], TooltipSettings.prototype, \"fadeOutDuration\", void 0);\n __decorate([\n Property('Move')\n ], TooltipSettings.prototype, \"fadeOutMode\", void 0);\n __decorate([\n Property(false)\n ], TooltipSettings.prototype, \"enableTextWrap\", void 0);\n __decorate([\n Property(true)\n ], TooltipSettings.prototype, \"showNearestPoint\", void 0);\n __decorate([\n Complex({ color: null, width: null }, Border)\n ], TooltipSettings.prototype, \"border\", void 0);\n __decorate([\n Complex({ x: null, y: null }, Location)\n ], TooltipSettings.prototype, \"location\", void 0);\n return TooltipSettings;\n}(ChildProperty));\nexport { TooltipSettings };\nvar StockTooltipSettings = /** @class */ (function (_super) {\n __extends(StockTooltipSettings, _super);\n function StockTooltipSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(false)\n ], StockTooltipSettings.prototype, \"enable\", void 0);\n __decorate([\n Property(true)\n ], StockTooltipSettings.prototype, \"enableMarker\", void 0);\n __decorate([\n Property(false)\n ], StockTooltipSettings.prototype, \"shared\", void 0);\n __decorate([\n Property(null)\n ], StockTooltipSettings.prototype, \"fill\", void 0);\n __decorate([\n Property(null)\n ], StockTooltipSettings.prototype, \"header\", void 0);\n __decorate([\n Property(0.75)\n ], StockTooltipSettings.prototype, \"opacity\", void 0);\n __decorate([\n Complex({ fontFamily: null, size: \"12px\", fontStyle: 'Normal', fontWeight: null, color: null }, Font)\n ], StockTooltipSettings.prototype, \"textStyle\", void 0);\n __decorate([\n Property(null)\n ], StockTooltipSettings.prototype, \"format\", void 0);\n __decorate([\n Property(null)\n ], StockTooltipSettings.prototype, \"template\", void 0);\n __decorate([\n Property(true)\n ], StockTooltipSettings.prototype, \"enableAnimation\", void 0);\n __decorate([\n Property(300)\n ], StockTooltipSettings.prototype, \"duration\", void 0);\n __decorate([\n Property(1000)\n ], StockTooltipSettings.prototype, \"fadeOutDuration\", void 0);\n __decorate([\n Property('Move')\n ], StockTooltipSettings.prototype, \"fadeOutMode\", void 0);\n __decorate([\n Property(false)\n ], StockTooltipSettings.prototype, \"enableTextWrap\", void 0);\n __decorate([\n Property(true)\n ], StockTooltipSettings.prototype, \"showNearestPoint\", void 0);\n __decorate([\n Complex({ color: null, width: null }, Border)\n ], StockTooltipSettings.prototype, \"border\", void 0);\n __decorate([\n Property('Fixed')\n ], StockTooltipSettings.prototype, \"position\", void 0);\n return StockTooltipSettings;\n}(ChildProperty));\nexport { StockTooltipSettings };\n/**\n * button settings in period selector\n */\nvar Periods = /** @class */ (function (_super) {\n __extends(Periods, _super);\n function Periods() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Years')\n ], Periods.prototype, \"intervalType\", void 0);\n __decorate([\n Property(1)\n ], Periods.prototype, \"interval\", void 0);\n __decorate([\n Property(null)\n ], Periods.prototype, \"text\", void 0);\n __decorate([\n Property(false)\n ], Periods.prototype, \"selected\", void 0);\n return Periods;\n}(ChildProperty));\nexport { Periods };\n/**\n * Period Selector Settings\n */\nvar PeriodSelectorSettings = /** @class */ (function (_super) {\n __extends(PeriodSelectorSettings, _super);\n function PeriodSelectorSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property(43)\n ], PeriodSelectorSettings.prototype, \"height\", void 0);\n __decorate([\n Property('Bottom')\n ], PeriodSelectorSettings.prototype, \"position\", void 0);\n __decorate([\n Collection([], Periods)\n ], PeriodSelectorSettings.prototype, \"periods\", void 0);\n return PeriodSelectorSettings;\n}(ChildProperty));\nexport { PeriodSelectorSettings };\n","import { getMinPointsDelta, getActualDesiredIntervalsCount, setRange, triggerLabelRender } from '../../common/utils/helper';\nimport { DoubleRange } from '../utils/double-range';\nimport { withIn, logBase } from '../../common/utils/helper';\nimport { isNullOrUndefined, extend, getValue } from '@syncfusion/ej2-base';\n/**\n * Numeric module is used to render numeric axis.\n */\nvar Double = /** @class */ (function () {\n /**\n * Constructor for the dateTime module.\n *\n * @private\n */\n function Double(chart) {\n this.isColumn = 0;\n this.isStacking = false;\n this.chart = chart;\n }\n /**\n * Numeric Nice Interval for the axis.\n *\n * @private\n */\n Double.prototype.calculateNumericNiceInterval = function (axis, delta, size) {\n var actualDesiredIntervalsCount = getActualDesiredIntervalsCount(size, axis);\n var niceInterval = delta / actualDesiredIntervalsCount;\n if (!isNullOrUndefined(axis.desiredIntervals)) {\n if (this.isAutoIntervalOnBothAxis(axis)) {\n return niceInterval;\n }\n }\n var minInterval = Math.pow(10, Math.floor(logBase(niceInterval, 10)));\n for (var _i = 0, _a = axis.intervalDivs; _i < _a.length; _i++) {\n var interval = _a[_i];\n var currentInterval = minInterval * interval;\n if (actualDesiredIntervalsCount < (delta / currentInterval)) {\n break;\n }\n niceInterval = currentInterval;\n }\n return niceInterval;\n };\n /**\n * Actual Range for the axis.\n *\n * @private\n */\n Double.prototype.isAutoIntervalOnBothAxis = function (axis) {\n if (((axis.zoomFactor < 1 || axis.zoomPosition > 0) && axis.enableAutoIntervalOnZooming)) {\n return false;\n }\n else {\n return true;\n }\n };\n Double.prototype.getActualRange = function (axis, size) {\n this.initializeDoubleRange(axis);\n if ((!axis.startFromZero) && (this.isColumn > 0)) {\n axis.actualRange.interval = axis.interval || this.calculateNumericNiceInterval(axis, axis.doubleRange.delta, size);\n axis.actualRange.max = axis.doubleRange.end + axis.actualRange.interval;\n if ((axis.doubleRange.start - axis.actualRange.interval < 0 && axis.doubleRange.start > 0)) {\n axis.actualRange.min = 0;\n }\n else {\n axis.actualRange.min = axis.doubleRange.start - (this.isStacking ? 0 : axis.actualRange.interval);\n }\n }\n else {\n axis.actualRange.interval = axis.interval || this.calculateNumericNiceInterval(axis, axis.doubleRange.delta, size);\n axis.actualRange.min = axis.doubleRange.start;\n axis.actualRange.max = axis.doubleRange.end;\n }\n };\n /**\n * Range for the axis.\n *\n * @private\n */\n Double.prototype.initializeDoubleRange = function (axis) {\n //Axis Min\n if (axis.minimum !== null) {\n this.min = axis.minimum;\n }\n else if (this.min === null || this.min === Number.POSITIVE_INFINITY) {\n this.min = 0;\n }\n // Axis Max\n if (axis.maximum !== null) {\n this.max = axis.maximum;\n }\n else if (this.max === null || this.max === Number.NEGATIVE_INFINITY) {\n this.max = 5;\n }\n if (this.min === this.max) {\n this.max = axis.valueType.indexOf('Category') > -1 ? this.max : this.min + 1;\n }\n axis.doubleRange = new DoubleRange(this.min, this.max);\n axis.actualRange = {};\n };\n /**\n * The function to calculate the range and labels for the axis.\n *\n * @returns {void}\n * @private\n */\n Double.prototype.calculateRangeAndInterval = function (size, axis) {\n this.calculateRange(axis);\n this.getActualRange(axis, size);\n this.applyRangePadding(axis, size);\n this.calculateVisibleLabels(axis, this.chart);\n };\n /**\n * Calculate Range for the axis.\n *\n * @private\n */\n Double.prototype.calculateRange = function (axis) {\n /*! Generate axis range */\n this.min = null;\n this.max = null;\n if (!setRange(axis)) {\n for (var _i = 0, _a = axis.series; _i < _a.length; _i++) {\n var series = _a[_i];\n if (!series.visible) {\n continue;\n }\n this.paddingInterval = 0;\n if (!isNullOrUndefined(series.points)) {\n axis.maxPointLength = series.points.length;\n }\n axis.maxPointLength = series.points.length;\n if (((series.type.indexOf('Column') > -1 || series.type.indexOf('Histogram') > -1) && axis.orientation === 'Horizontal')\n || (series.type.indexOf('Bar') > -1 && axis.orientation === 'Vertical')) {\n if ((series.xAxis.valueType === 'Double' || series.xAxis.valueType === 'DateTime')\n && series.xAxis.rangePadding === 'Auto') {\n this.paddingInterval = getMinPointsDelta(series.xAxis, axis.series) * 0.5;\n }\n }\n //For xRange\n if (axis.orientation === 'Horizontal') {\n if (this.chart.requireInvertedAxis) {\n this.yAxisRange(axis, series);\n }\n else {\n this.findMinMax(series.xMin - this.paddingInterval, series.xMax + this.paddingInterval);\n }\n }\n // For yRange\n if (axis.orientation === 'Vertical') {\n this.isColumn += (series.type.indexOf('Column') !== -1 || series.type.indexOf('Bar') !== -1 || series.drawType === 'Column') ? 1 : 0;\n this.isStacking = series.type.indexOf('Stacking') !== -1;\n if (this.chart.requireInvertedAxis) {\n this.findMinMax(series.xMin - this.paddingInterval, series.xMax + this.paddingInterval);\n }\n else {\n this.yAxisRange(axis, series);\n }\n }\n }\n }\n };\n Double.prototype.yAxisRange = function (axis, series) {\n if (series.dragSettings.enable && this.chart.dragY) {\n if (this.chart.dragY >= axis.visibleRange.max) {\n series.yMax = this.chart.dragY + axis.visibleRange.interval;\n }\n if (this.chart.dragY <= axis.visibleRange.min) {\n series.yMin = this.chart.dragY - axis.visibleRange.interval;\n }\n }\n this.findMinMax(series.yMin, series.yMax);\n };\n Double.prototype.findMinMax = function (min, max) {\n if (this.min === null || this.min > min) {\n this.min = min;\n }\n if (this.max === null || this.max < max) {\n this.max = max;\n }\n if ((this.max === this.min) && this.max < 0 && this.min < 0) { // max == min\n this.max = 0;\n }\n };\n /**\n * Apply padding for the range.\n *\n * @private\n */\n Double.prototype.applyRangePadding = function (axis, size) {\n var start = axis.actualRange.min;\n var end = axis.actualRange.max;\n if (!setRange(axis)) {\n var interval = axis.actualRange.interval;\n var padding = axis.getRangePadding(this.chart);\n if (padding === 'Additional' || padding === 'Round') {\n this.findAdditional(axis, start, end, interval, size);\n }\n else if (padding === 'Normal') {\n this.findNormal(axis, start, end, interval, size);\n }\n else {\n this.updateActualRange(axis, start, end, interval);\n }\n }\n axis.actualRange.delta = axis.actualRange.max - axis.actualRange.min;\n this.calculateVisibleRange(size, axis);\n };\n Double.prototype.updateActualRange = function (axis, minimum, maximum, interval) {\n axis.actualRange = {\n min: axis.minimum != null ? axis.minimum : minimum,\n max: axis.maximum != null ? axis.maximum : maximum,\n interval: axis.interval != null ? axis.interval : interval,\n delta: axis.actualRange.delta\n };\n };\n Double.prototype.findAdditional = function (axis, start, end, interval, size) {\n var minimum;\n var maximum;\n minimum = Math.floor(start / interval) * interval;\n maximum = Math.ceil(end / interval) * interval;\n if (axis.rangePadding === 'Additional') {\n minimum -= interval;\n maximum += interval;\n }\n if (!isNullOrUndefined(axis.desiredIntervals)) {\n var delta = maximum - minimum;\n interval = this.calculateNumericNiceInterval(axis, delta, size);\n }\n this.updateActualRange(axis, minimum, maximum, interval);\n };\n Double.prototype.findNormal = function (axis, start, end, interval, size) {\n var remaining;\n var minimum;\n var maximum;\n var startValue = start;\n if (start < 0) {\n startValue = 0;\n minimum = start + (start * 0.05);\n remaining = interval + (minimum % interval);\n if ((0.365 * interval) >= remaining) {\n minimum -= interval;\n }\n if (minimum % interval < 0) {\n minimum = (minimum - interval) - (minimum % interval);\n }\n }\n else {\n minimum = start < ((5.0 / 6.0) * end) ? 0 : (start - (end - start) * 0.5);\n if (minimum % interval > 0) {\n minimum -= (minimum % interval);\n }\n }\n maximum = (end > 0) ? (end + (end - startValue) * 0.05) : (end - (end - startValue) * 0.05);\n remaining = interval - (maximum % interval);\n if ((0.365 * interval) >= remaining) {\n maximum += interval;\n }\n if (maximum % interval > 0) {\n maximum = (maximum + interval) - (maximum % interval);\n }\n axis.doubleRange = new DoubleRange(minimum, maximum);\n if (minimum === 0 || (minimum < 0 && maximum < 0)) {\n interval = this.calculateNumericNiceInterval(axis, axis.doubleRange.delta, size);\n maximum = Math.ceil(maximum / interval) * interval;\n }\n this.updateActualRange(axis, minimum, maximum, interval);\n };\n /**\n * Calculate visible range for axis.\n *\n * @private\n */\n Double.prototype.calculateVisibleRange = function (size, axis) {\n axis.visibleRange = {\n max: axis.actualRange.max, min: axis.actualRange.min,\n delta: axis.actualRange.delta, interval: axis.actualRange.interval\n };\n if (this.chart.chartAreaType === 'Cartesian') {\n var isLazyLoad = isNullOrUndefined(axis.zoomingScrollBar) ? false : axis.zoomingScrollBar.isLazyLoad;\n if ((axis.zoomFactor < 1 || axis.zoomPosition > 0) && !isLazyLoad) {\n axis.calculateVisibleRangeOnZooming(size);\n axis.visibleRange.interval = (axis.enableAutoIntervalOnZooming) ?\n this.calculateNumericNiceInterval(axis, axis.doubleRange.delta, size)\n : axis.visibleRange.interval;\n }\n }\n if (axis.maximum && axis.orientation === 'Vertical' && axis.rangePadding === 'Auto') {\n var duplicateTempInterval = void 0;\n var tempInterval = axis.visibleRange.min;\n for (; (tempInterval <= axis.visibleRange.max) && (duplicateTempInterval !== tempInterval); tempInterval += axis.visibleRange.interval) {\n duplicateTempInterval = tempInterval;\n }\n if (duplicateTempInterval < axis.visibleRange.max) {\n axis.visibleRange.max = duplicateTempInterval + axis.visibleRange.interval;\n }\n }\n axis.triggerRangeRender(this.chart, axis.visibleRange.min, axis.visibleRange.max, axis.visibleRange.interval);\n };\n /**\n * Calculate label for the axis.\n *\n * @private\n */\n Double.prototype.calculateVisibleLabels = function (axis, chart) {\n /*! Generate axis labels */\n axis.visibleLabels = [];\n var tempInterval = axis.visibleRange.min;\n var labelStyle;\n var controlName = chart.getModuleName();\n var isPolarRadar = controlName === 'chart' && chart.chartAreaType === 'PolarRadar';\n if (!isPolarRadar && (axis.zoomFactor < 1 || axis.zoomPosition > 0 || this.paddingInterval)) {\n tempInterval = axis.visibleRange.min - (axis.visibleRange.min % axis.visibleRange.interval);\n }\n var format = this.getFormat(axis);\n var isCustom = format.match('{value}') !== null;\n var intervalDigits = 0;\n var formatDigits = 0;\n if (axis.labelFormat && axis.labelFormat.indexOf('n') > -1) {\n formatDigits = parseInt(axis.labelFormat.substring(1, axis.labelFormat.length), 10);\n }\n axis.format = chart.intl.getNumberFormat({\n format: isCustom ? '' : format,\n useGrouping: chart.useGroupingSeparator\n });\n axis.startLabel = axis.format(axis.visibleRange.min);\n axis.endLabel = axis.format(axis.visibleRange.max);\n if (axis.visibleRange.interval && (axis.visibleRange.interval + '').indexOf('.') >= 0) {\n intervalDigits = (axis.visibleRange.interval + '').split('.')[1].length;\n }\n var duplicateTempInterval;\n for (; (tempInterval <= axis.visibleRange.max) && (duplicateTempInterval !== tempInterval); tempInterval += axis.visibleRange.interval) {\n duplicateTempInterval = tempInterval;\n labelStyle = (extend({}, getValue('properties', axis.labelStyle), null, true));\n if (withIn(tempInterval, axis.visibleRange)) {\n triggerLabelRender(chart, tempInterval, this.formatValue(axis, isCustom, format, tempInterval), labelStyle, axis);\n }\n }\n if (tempInterval && (tempInterval + '').indexOf('.') >= 0 && (tempInterval + '').split('.')[1].length > 10) {\n tempInterval = (tempInterval + '').split('.')[1].length > (formatDigits || intervalDigits) ?\n +tempInterval.toFixed(formatDigits || intervalDigits) : tempInterval;\n if (tempInterval <= axis.visibleRange.max) {\n triggerLabelRender(chart, tempInterval, this.formatValue(axis, isCustom, format, tempInterval), labelStyle, axis);\n }\n }\n if (axis.getMaxLabelWidth) {\n axis.getMaxLabelWidth(this.chart);\n }\n };\n /**\n * Format of the axis label.\n *\n * @private\n */\n Double.prototype.getFormat = function (axis) {\n if (axis.labelFormat) {\n if (axis.labelFormat.indexOf('p') === 0 && axis.labelFormat.indexOf('{value}') === -1 && axis.isStack100) {\n return '{value}%';\n }\n return axis.labelFormat;\n }\n return axis.isStack100 ? '{value}%' : '';\n };\n /**\n * Formatted the axis label.\n *\n * @private\n */\n Double.prototype.formatValue = function (axis, isCustom, format, tempInterval) {\n /*The toLocaleString method is used to adjust the decimal points for this ticket, specifically for ticket numbers I481747 and I541484.*/\n var labelValue = !(tempInterval % 1) ? tempInterval : Number(tempInterval.toLocaleString('en-US').split(',').join(''));\n return isCustom ? format.replace('{value}', axis.format(labelValue))\n : format ? axis.format(tempInterval) : axis.format(labelValue);\n };\n return Double;\n}());\nexport { Double };\n","/** @hidden */\nexport var created = 'create';\n/** @hidden */\nexport var destroyed = 'destroy';\n/** @hidden */\nexport var load = 'load';\n/** @hidden */\nexport var rowDataBound = 'rowDataBound';\n/** @hidden */\nexport var queryCellInfo = 'queryCellInfo';\n/** @hidden */\nexport var headerCellInfo = 'headerCellInfo';\n/** @hidden */\nexport var actionBegin = 'actionBegin';\n/** @hidden */\nexport var actionComplete = 'actionComplete';\n/** @hidden */\nexport var actionFailure = 'actionFailure';\n/** @hidden */\nexport var dataBound = 'dataBound';\n/** @hidden */\nexport var rowSelecting = 'rowSelecting';\n/** @hidden */\nexport var rowSelected = 'rowSelected';\n/** @hidden */\nexport var rowDeselecting = 'rowDeselecting';\n/** @hidden */\nexport var rowDeselected = 'rowDeselected';\n/** @hidden */\nexport var cellSelecting = 'cellSelecting';\n/** @hidden */\nexport var cellSelected = 'cellSelected';\n/** @hidden */\nexport var cellDeselecting = 'cellDeselecting';\n/** @hidden */\nexport var cellDeselected = 'cellDeselected';\n/** @hidden */\nexport var columnSelecting = 'columnSelecting';\n/** @hidden */\nexport var columnSelected = 'columnSelected';\n/** @hidden */\nexport var columnDeselecting = 'columnDeselecting';\n/** @hidden */\nexport var columnDeselected = 'columnDeselected';\n/** @hidden */\nexport var columnDragStart = 'columnDragStart';\n/** @hidden */\nexport var columnDrag = 'columnDrag';\n/** @hidden */\nexport var columnDrop = 'columnDrop';\n/** @hidden */\nexport var rowDragStartHelper = 'rowDragStartHelper';\n/** @hidden */\nexport var rowDragStart = 'rowDragStart';\n/** @hidden */\nexport var rowDrag = 'rowDrag';\n/** @hidden */\nexport var rowDrop = 'rowDrop';\n/** @hidden */\nexport var beforePrint = 'beforePrint';\n/** @hidden */\nexport var printComplete = 'printComplete';\n/** @hidden */\nexport var detailDataBound = 'detailDataBound';\n/** @hidden */\nexport var toolbarClick = 'toolbarClick';\n/** @hidden */\nexport var batchAdd = 'batchAdd';\n/** @hidden */\nexport var batchCancel = 'batchCancel';\n/** @hidden */\nexport var batchDelete = 'batchDelete';\n/** @hidden */\nexport var beforeBatchAdd = 'beforeBatchAdd';\n/** @hidden */\nexport var beforeBatchDelete = 'beforeBatchDelete';\n/** @hidden */\nexport var beforeBatchSave = 'beforeBatchSave';\n/** @hidden */\nexport var beginEdit = 'beginEdit';\n/** @hidden */\nexport var cellEdit = 'cellEdit';\n/** @hidden */\nexport var cellSave = 'cellSave';\n/** @hidden */\nexport var cellSaved = 'cellSaved';\n/** @hidden */\nexport var endAdd = 'endAdd';\n/** @hidden */\nexport var endDelete = 'endDelete';\n/** @hidden */\nexport var endEdit = 'endEdit';\n/** @hidden */\nexport var recordDoubleClick = 'recordDoubleClick';\n/** @hidden */\nexport var recordClick = 'recordClick';\n/** @hidden */\nexport var beforeDataBound = 'beforeDataBound';\n/** @hidden */\nexport var beforeOpenColumnChooser = 'beforeOpenColumnChooser';\n/** @hidden */\nexport var beforeOpenAdaptiveDialog = 'beforeOpenAdaptiveDialog';\n/** @hidden */\nexport var resizeStart = 'resizeStart';\n/** @hidden */\nexport var onResize = 'resizing';\n/** @hidden */\nexport var resizeStop = 'resizeStop';\n/** @hidden */\nexport var checkBoxChange = 'checkBoxChange';\n/** @hidden */\nexport var beforeCopy = 'beforeCopy';\n/** @hidden */\nexport var beforePaste = 'beforePaste';\n/** @hidden */\nexport var beforeAutoFill = 'beforeAutoFill';\n/** @hidden */\nexport var filterChoiceRequest = 'filterchoicerequest';\n/** @hidden */\nexport var filterAfterOpen = 'filterAfterOpen';\n/** @hidden */\nexport var filterBeforeOpen = 'filterBeforeOpen';\n/** @hidden */\nexport var filterSearchBegin = 'filterSearchBegin';\n/** @hidden */\nexport var commandClick = 'commandClick';\n/** @hidden */\nexport var exportGroupCaption = 'exportGroupCaption';\n/** @hidden */\nexport var lazyLoadGroupExpand = 'lazyLoadGroupExpand';\n/** @hidden */\nexport var lazyLoadGroupCollapse = 'lazyLoadGroupCollapse';\n/**\n * Specifies grid internal events\n */\n/** @hidden */\nexport var initialLoad = 'initial-load';\n/** @hidden */\nexport var initialEnd = 'initial-end';\n/** @hidden */\nexport var dataReady = 'data-ready';\n/** @hidden */\nexport var contentReady = 'content-ready';\n/** @hidden */\nexport var uiUpdate = 'ui-update';\n/** @hidden */\nexport var onEmpty = 'on-empty';\n/** @hidden */\nexport var inBoundModelChanged = 'inbound-model-changed';\n/** @hidden */\nexport var modelChanged = 'model-changed';\n/** @hidden */\nexport var colGroupRefresh = 'colgroup-refresh';\n/** @hidden */\nexport var headerRefreshed = 'header-refreshed';\n/** @hidden */\nexport var pageBegin = 'paging-begin';\n/** @hidden */\nexport var pageComplete = 'paging-complete';\n/** @hidden */\nexport var sortBegin = 'sorting-begin';\n/** @hidden */\nexport var sortComplete = 'sorting-complete';\n/** @hidden */\nexport var filterBegin = 'filtering-begin';\n/** @hidden */\nexport var filterComplete = 'filtering-complete';\n/** @hidden */\nexport var searchBegin = 'searching-begin';\n/** @hidden */\nexport var searchComplete = 'searching-complete';\n/** @hidden */\nexport var reorderBegin = 'reorder-begin';\n/** @hidden */\nexport var reorderComplete = 'reorder-complete';\n/** @hidden */\nexport var rowDragAndDropBegin = 'rowdraganddrop-begin';\n/** @hidden */\nexport var rowDragAndDropComplete = 'rowdraganddrop-complete';\n/** @hidden */\nexport var groupBegin = 'grouping-begin';\n/** @hidden */\nexport var groupComplete = 'grouping-complete';\n/** @hidden */\nexport var ungroupBegin = 'ungrouping-begin';\n/** @hidden */\nexport var ungroupComplete = 'ungrouping-complete';\n/** @hidden */\nexport var groupAggregates = 'group-aggregates';\n/** @hidden */\nexport var refreshFooterRenderer = 'refresh-footer-rendered';\n/** @hidden */\nexport var refreshAggregateCell = 'refresh-aggregate-cell';\n/** @hidden */\nexport var refreshAggregates = 'refresh-aggregates';\n/** @hidden */\nexport var rowSelectionBegin = 'rowselecting';\n/** @hidden */\nexport var rowSelectionComplete = 'rowselected';\n/** @hidden */\nexport var columnSelectionBegin = 'columnselecting';\n/** @hidden */\nexport var columnSelectionComplete = 'columnselected';\n/** @hidden */\nexport var cellSelectionBegin = 'cellselecting';\n/** @hidden */\nexport var cellSelectionComplete = 'cellselected';\n/** @hidden */\nexport var beforeCellFocused = 'beforecellfocused';\n/** @hidden */\nexport var cellFocused = 'cellfocused';\n/** @hidden */\nexport var keyPressed = 'key-pressed';\n/** @hidden */\nexport var click = 'click';\n/** @hidden */\nexport var destroy = 'destroy';\n/** @hidden */\nexport var columnVisibilityChanged = 'column-visible-changed';\n/** @hidden */\nexport var scroll = 'scroll';\n/** @hidden */\nexport var columnWidthChanged = 'column-width-changed';\n/** @hidden */\nexport var columnPositionChanged = 'column-position-changed';\n/** @hidden */\nexport var rowDragAndDrop = 'row-drag-and-drop';\n/** @hidden */\nexport var rowsAdded = 'rows-added';\n/** @hidden */\nexport var rowsRemoved = 'rows-removed';\n/** @hidden */\nexport var columnDragStop = 'column-drag-stop';\n/** @hidden */\nexport var headerDrop = 'header-drop';\n/** @hidden */\nexport var dataSourceModified = 'datasource-modified';\n/** @hidden */\nexport var refreshComplete = 'refresh-complete';\n/** @hidden */\nexport var refreshVirtualBlock = 'refresh-virtual-block';\n/** @hidden */\nexport var dblclick = 'dblclick';\n/** @hidden */\nexport var toolbarRefresh = 'toolbar-refresh';\n/** @hidden */\nexport var bulkSave = 'bulk-save';\n/** @hidden */\nexport var autoCol = 'auto-col';\n/** @hidden */\nexport var tooltipDestroy = 'tooltip-destroy';\n/** @hidden */\nexport var updateData = 'update-data';\n/** @hidden */\nexport var editBegin = 'edit-begin';\n/** @hidden */\nexport var editComplete = 'edit-complete';\n/** @hidden */\nexport var addBegin = 'add-begin';\n/** @hidden */\nexport var addComplete = 'add-complete';\n/** @hidden */\nexport var saveComplete = 'save-complete';\n/** @hidden */\nexport var deleteBegin = 'delete-begin';\n/** @hidden */\nexport var deleteComplete = 'delete-complete';\n/** @hidden */\nexport var preventBatch = 'prevent-batch';\n/** @hidden */\nexport var dialogDestroy = 'dialog-destroy';\n/** @hidden */\nexport var crudAction = 'crud-Action';\n/** @hidden */\nexport var addDeleteAction = 'add-delete-Action';\n/** @hidden */\nexport var destroyForm = 'destroy-form';\n/** @hidden */\nexport var doubleTap = 'double-tap';\n/** @hidden */\nexport var beforeExcelExport = 'beforeExcelExport';\n/** @hidden */\nexport var excelExportComplete = 'excelExportComplete';\n/** @hidden */\nexport var excelQueryCellInfo = 'excelQueryCellInfo';\n/** @hidden */\nexport var excelHeaderQueryCellInfo = 'excelHeaderQueryCellInfo';\n/** @hidden */\nexport var exportDetailDataBound = 'exportDetailDataBound';\n/** @hidden */\nexport var exportDetailTemplate = 'exportDetailTemplate';\n/** @hidden */\nexport var beforePdfExport = 'beforePdfExport';\n/** @hidden */\nexport var pdfExportComplete = 'pdfExportComplete';\n/** @hidden */\nexport var pdfQueryCellInfo = 'pdfQueryCellInfo';\n/** @hidden */\nexport var pdfHeaderQueryCellInfo = 'pdfHeaderQueryCellInfo';\n/** @hidden */\nexport var accessPredicate = 'access-predicate';\n/** @hidden */\nexport var contextMenuClick = 'contextMenuClick';\n/** @hidden */\nexport var freezeRender = 'freezerender';\n/** @hidden */\nexport var freezeRefresh = 'freezerefresh';\n/** @hidden */\nexport var contextMenuOpen = 'contextMenuOpen';\n/** @hidden */\nexport var columnMenuClick = 'columnMenuClick';\n/** @hidden */\nexport var columnMenuOpen = 'columnMenuOpen';\n/** @hidden */\nexport var filterOpen = 'filterOpen';\n/** @hidden */\nexport var filterDialogCreated = 'filterDialogCreated';\n/** @hidden */\nexport var filterMenuClose = 'filter-menu-close';\n/** @hidden */\nexport var initForeignKeyColumn = 'initForeignKeyColumn';\n/** @hidden */\nexport var getForeignKeyData = 'getForeignKeyData';\n/** @hidden */\nexport var generateQuery = 'generateQuery';\n/** @hidden */\nexport var showEmptyGrid = 'showEmptyGrid';\n/** @hidden */\nexport var foreignKeyData = 'foreignKeyData';\n/** @hidden */\nexport var columnDataStateChange = 'columnDataStateChange';\n/** @hidden */\nexport var dataStateChange = 'dataStateChange';\n/** @hidden */\nexport var dataSourceChanged = 'dataSourceChanged';\n/** @hidden */\nexport var rtlUpdated = 'rtl-updated';\n/** @hidden */\nexport var beforeFragAppend = 'beforeFragAppend';\n/** @hidden */\nexport var frozenHeight = 'frozenHeight';\n/** @hidden */\nexport var textWrapRefresh = 'textWrapRefresh';\n/** @hidden */\nexport var recordAdded = 'recordAdded';\n/** @hidden */\nexport var cancelBegin = 'cancel-Begin';\n/** @hidden */\nexport var editNextValCell = 'editNextValCell';\n/** @hidden */\nexport var hierarchyPrint = 'hierarchyprint';\n/** @hidden */\nexport var expandChildGrid = 'expandchildgrid';\n/** @hidden */\nexport var printGridInit = 'printGrid-Init';\n/** @hidden */\nexport var exportRowDataBound = 'export-RowDataBound';\n/** @hidden */\nexport var exportDataBound = 'export-DataBound';\n/** @hidden */\nexport var rowPositionChanged = 'row-position-changed';\n/** @hidden */\nexport var columnChooserOpened = 'columnChooserOpened';\n/** @hidden */\nexport var batchForm = 'batchedit-form';\n/** @hidden */\nexport var beforeStartEdit = 'edit-form';\n/** @hidden */\nexport var beforeBatchCancel = 'before-batch-cancel';\n/** @hidden */\nexport var batchEditFormRendered = 'batcheditform-rendered';\n/** @hidden */\nexport var partialRefresh = 'partial-refresh';\n/** @hidden */\nexport var beforeCustomFilterOpen = 'beforeCustomFilterOpen';\n/** @hidden */\nexport var selectVirtualRow = 'select-virtual-Row';\n/** @hidden */\nexport var columnsPrepared = 'columns-prepared';\n/** @hidden */\nexport var cBoxFltrBegin = 'cbox-filter-begin';\n/** @hidden */\nexport var cBoxFltrComplete = 'cbox-filter-complete';\n/** @hidden */\nexport var fltrPrevent = 'filter-Prevent';\n/** @hidden */\nexport var beforeFltrcMenuOpen = 'before-filter-cmenu-open';\n/** @hidden */\nexport var valCustomPlacement = 'validation-custom-placement';\n/** @hidden */\nexport var filterCboxValue = 'filter-cbox-value';\n/** @hidden */\nexport var componentRendered = 'component-rendered';\n/** @hidden */\nexport var restoreFocus = 'restore-Focus';\n/** @hidden */\nexport var detailStateChange = 'detail-state-change';\n/** @hidden */\nexport var detailIndentCellInfo = 'detail-indentcell-info';\n/** @hidden */\nexport var virtaulKeyHandler = 'virtaul-key-handler';\n/** @hidden */\nexport var virtaulCellFocus = 'virtaul-cell-focus';\n/** @hidden */\nexport var virtualScrollEditActionBegin = 'virtual-scroll-edit-action-begin';\n/** @hidden */\nexport var virtualScrollEditSuccess = 'virtual-scroll-edit-success';\n/** @hidden */\nexport var virtualScrollEditCancel = 'virtual-scroll-edit-cancel';\n/** @hidden */\nexport var virtualScrollEdit = 'virtual-scroll-edit';\n/** @hidden */\nexport var refreshVirtualCache = 'refresh-virtual-cache';\n/** @hidden */\nexport var editReset = 'edit-reset';\n/** @hidden */\nexport var virtualScrollAddActionBegin = 'virtual-scroll-add-action-begin';\n/** @hidden */\nexport var getVirtualData = 'get-virtual-data';\n/** @hidden */\nexport var refreshInfiniteModeBlocks = 'refresh-infinite-mode-blocks';\n/** @hidden */\nexport var resetInfiniteBlocks = 'reset-infinite-blocks';\n/** @hidden */\nexport var infiniteScrollHandler = 'infinite-scroll-handler';\n/** @hidden */\nexport var infinitePageQuery = 'infinite-page-query';\n/** @hidden */\nexport var infiniteShowHide = 'infinite-show-hide';\n/** @hidden */\nexport var appendInfiniteContent = 'append-infinite-content';\n/** @hidden */\nexport var removeInfiniteRows = 'remove-infinite-rows';\n/** @hidden */\nexport var setInfiniteCache = 'set-infinite-cache';\n/** @hidden */\nexport var infiniteEditHandler = 'infinite-edit-handler';\n/** @hidden */\nexport var initialCollapse = 'initial-collapse';\n/** @hidden */\nexport var getAggregateQuery = 'get-aggregate-query';\n/** @hidden */\nexport var closeFilterDialog = 'close-filter-dialog';\n/** @hidden */\nexport var columnChooserCancelBtnClick = 'columnChooserCancelBtnClick';\n/** @hidden */\nexport var getFilterBarOperator = 'get-filterbar-operator';\n/** @hidden */\nexport var resetColumns = 'reset-columns';\n/** @hidden */\nexport var pdfAggregateQueryCellInfo = 'pdfAggregateQueryCellInfo';\n/** @hidden */\nexport var excelAggregateQueryCellInfo = 'excelAggregateQueryCellInfo';\n/** @hidden */\nexport var setGroupCache = 'group-cache';\n/** @hidden */\nexport var lazyLoadScrollHandler = 'lazy-load-scroll-handler';\n/** @hidden */\nexport var groupCollapse = 'group-collapse';\n/** @hidden */\nexport var beforeCheckboxRenderer = 'beforeCheckboxRenderer';\n/** @hidden */\nexport var refreshHandlers = 'refreshResizeHandlers';\n/** @hidden */\nexport var refreshFrozenColumns = 'refresh-frozen-columns';\n/** @hidden */\nexport var setReorderDestinationElement = 'set-reorder-destination-element';\n/** @hidden */\nexport var refreshVirtualFrozenHeight = 'refresh-virtual-frozen-height';\n/** @hidden */\nexport var setFreezeSelection = 'set-freeze-selection';\n/** @hidden */\nexport var setInfiniteFrozenHeight = 'set-infinite-frozen-height';\n/** @hidden */\nexport var setInfiniteColFrozenHeight = 'set-infinite-col-frozen-height';\n/** @hidden */\nexport var beforeRefreshOnDataChange = 'before-refresh-on-data-change';\n/** @hidden */\nexport var immutableBatchCancel = 'immutable-batch-cancel';\n/** @hidden */\nexport var refreshVirtualFrozenRows = 'refresh-virtual-frozenrows';\n/** @hidden */\nexport var checkScrollReset = 'check-scroll-reset';\n/** @hidden */\nexport var refreshFrozenHeight = 'refresh-frozen-height';\n/** @hidden */\nexport var setHeightToFrozenElement = 'set-height-to-frozen-element';\n/** @hidden */\nexport var preventFrozenScrollRefresh = 'prevent-frozen-scroll-refresh';\n/** @hidden */\nexport var nextCellIndex = 'next-cell-index';\n/** @hidden */\nexport var refreshInfiniteCurrentViewData = 'refresh-infinite-current-view-data';\n/** @hidden */\nexport var infiniteCrudCancel = 'infinite-crud-cancel';\n/** @hidden */\nexport var filterDialogClose = 'filter-dialog-close';\n/** @hidden */\nexport var refreshCustomFilterOkBtn = 'refresh-cutsom-filter-ok-button';\n/** @hidden */\nexport var refreshCustomFilterClearBtn = 'refresh-cutsom-filter-clear-button';\n/** @hidden */\nexport var renderResponsiveCmenu = 'render-responsive-cmenu';\n/** @hidden */\nexport var filterCmenuSelect = 'filter-cmenu-select';\n/** @hidden */\nexport var customFilterClose = 'custom-filter-close';\n/** @hidden */\nexport var setFullScreenDialog = 'set-fullscreen-dialog';\n/** @hidden */\nexport var refreshExpandandCollapse = 'refresh-Expand-and-Collapse';\n/** @hidden */\nexport var rowModeChange = 'row-mode-change';\n/** @hidden */\nexport var enterKeyHandler = 'enter-key-handler';\n/** @hidden */\nexport var refreshVirtualMaxPage = 'refresh-virtual-max-page';\n/** @hidden */\nexport var setVirtualPageQuery = 'set-virtual-page-query';\n/** @hidden */\nexport var selectRowOnContextOpen = 'select-row-on-context-open';\n/** @hidden */\nexport var pagerRefresh = 'pager-refresh';\n/** @hidden */\nexport var closeInline = 'closeinline';\n/** @hidden */\nexport var closeBatch = 'closebatch';\n/** @hidden */\nexport var closeEdit = 'close-edit';\n/** @hidden */\nexport var resetVirtualFocus = 'reset-virtual-focus';\n/** @hidden */\nexport var afterContentRender = 'after-content-renderer';\n/** @hidden */\nexport var refreshVirtualEditFormCells = 'refresh-virtual-editform-cells';\n/** @hidden */\nexport var scrollToEdit = 'scroll-to-edit';\n/** @hidden */\nexport var beforeCheckboxRendererQuery = 'before-checkbox-renderer-query';\n/** @hidden */\nexport var createVirtualValidationForm = 'create-virtual-validation-form';\n/** @hidden */\nexport var validateVirtualForm = 'validate-virtual-form';\n/** @hidden */\nexport var destroyChildGrid = 'destroy-child-grid';\n/** @hidden */\nexport var stickyScrollComplete = 'sticky-scroll-complete';\n/** @hidden */\nexport var captionActionComplete = 'infinite-group-collapse';\n/** @hidden */\nexport var refreshInfinitePersistSelection = 'refresh-infinite-persist-selection';\n/** @hidden */\nexport var refreshInfiniteEditrowindex = 'refresh-infinite-editrowindex';\n/** @hidden */\nexport var afterFilterColumnMenuClose = 'after-filter-column-menu-close';\n/** @hidden */\nexport var beforeCheckboxfilterRenderer = 'beforeCheckboxfilterRenderer';\n/** @hidden */\nexport var commandColumnDestroy = 'commandColumnDestroy';\n/** @hidden */\nexport var batchCnfrmDlgCancel = 'cancelcnfrmDlg';\n/** @hidden */\nexport var refreshVirtualLazyLoadCache = 'refresh-Virtual-LazyLoad-Cache';\n/** @hidden */\nexport var refreshFrozenPosition = 'refresh-Frozen-Position';\n/** @hidden */\nexport var refreshResizePosition = 'refresh-Resize-Position';\n/** @hidden */\nexport var refreshSplitFrozenColumn = 'refresh-Split-Frozen-Column';\n/** @hidden */\nexport var renderResponsiveChangeAction = 'render-Responsive-Change-Action';\n/** @hidden */\nexport var renderResponsiveColumnChooserDiv = 'render-Responsive-Column-Chooser-Div';\n","//! moment.js locale configuration\n//! locale : Serbian [sr]\n//! author : Milan JanaÄković<milanjanackovic@gmail.com> : https://github.com/milan-j\n//! author : Stefan Crnjaković <stefan@hotmail.rs> : https://github.com/crnjakovic\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var translator = {\n words: {\n //Different grammatical cases\n ss: ['sekunda', 'sekunde', 'sekundi'],\n m: ['jedan minut', 'jednog minuta'],\n mm: ['minut', 'minuta', 'minuta'],\n h: ['jedan sat', 'jednog sata'],\n hh: ['sat', 'sata', 'sati'],\n d: ['jedan dan', 'jednog dana'],\n dd: ['dan', 'dana', 'dana'],\n M: ['jedan mesec', 'jednog meseca'],\n MM: ['mesec', 'meseca', 'meseci'],\n y: ['jednu godinu', 'jedne godine'],\n yy: ['godinu', 'godine', 'godina'],\n },\n correctGrammaticalCase: function (number, wordKey) {\n if (\n number % 10 >= 1 &&\n number % 10 <= 4 &&\n (number % 100 < 10 || number % 100 >= 20)\n ) {\n return number % 10 === 1 ? wordKey[0] : wordKey[1];\n }\n return wordKey[2];\n },\n translate: function (number, withoutSuffix, key, isFuture) {\n var wordKey = translator.words[key],\n word;\n\n if (key.length === 1) {\n // Nominativ\n if (key === 'y' && withoutSuffix) return 'jedna godina';\n return isFuture || withoutSuffix ? wordKey[0] : wordKey[1];\n }\n\n word = translator.correctGrammaticalCase(number, wordKey);\n // Nominativ\n if (key === 'yy' && withoutSuffix && word === 'godinu') {\n return number + ' godina';\n }\n\n return number + ' ' + word;\n },\n };\n\n var sr = moment.defineLocale('sr', {\n months: 'januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar'.split(\n '_'\n ),\n monthsShort:\n 'jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.'.split('_'),\n monthsParseExact: true,\n weekdays: 'nedelja_ponedeljak_utorak_sreda_Äetvrtak_petak_subota'.split(\n '_'\n ),\n weekdaysShort: 'ned._pon._uto._sre._Äet._pet._sub.'.split('_'),\n weekdaysMin: 'ne_po_ut_sr_Äe_pe_su'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'D. M. YYYY.',\n LL: 'D. MMMM YYYY.',\n LLL: 'D. MMMM YYYY. H:mm',\n LLLL: 'dddd, D. MMMM YYYY. H:mm',\n },\n calendar: {\n sameDay: '[danas u] LT',\n nextDay: '[sutra u] LT',\n nextWeek: function () {\n switch (this.day()) {\n case 0:\n return '[u] [nedelju] [u] LT';\n case 3:\n return '[u] [sredu] [u] LT';\n case 6:\n return '[u] [subotu] [u] LT';\n case 1:\n case 2:\n case 4:\n case 5:\n return '[u] dddd [u] LT';\n }\n },\n lastDay: '[juÄe u] LT',\n lastWeek: function () {\n var lastWeekDays = [\n '[proÅ¡le] [nedelje] [u] LT',\n '[proÅ¡log] [ponedeljka] [u] LT',\n '[proÅ¡log] [utorka] [u] LT',\n '[proÅ¡le] [srede] [u] LT',\n '[proÅ¡log] [Äetvrtka] [u] LT',\n '[proÅ¡log] [petka] [u] LT',\n '[proÅ¡le] [subote] [u] LT',\n ];\n return lastWeekDays[this.day()];\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'za %s',\n past: 'pre %s',\n s: 'nekoliko sekundi',\n ss: translator.translate,\n m: translator.translate,\n mm: translator.translate,\n h: translator.translate,\n hh: translator.translate,\n d: translator.translate,\n dd: translator.translate,\n M: translator.translate,\n MM: translator.translate,\n y: translator.translate,\n yy: translator.translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return sr;\n\n})));\n","//! moment.js locale configuration\n//! locale : Talossan [tzl]\n//! author : Robin van der Vliet : https://github.com/robin0van0der0v\n//! author : Iustì Canun\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n // After the year there should be a slash and the amount of years since December 26, 1979 in Roman numerals.\n // This is currently too difficult (maybe even impossible) to add.\n var tzl = moment.defineLocale('tzl', {\n months: 'Januar_Fevraglh_Març_Avrïu_Mai_Gün_Julia_Guscht_Setemvar_Listopäts_Noemvar_Zecemvar'.split(\n '_'\n ),\n monthsShort: 'Jan_Fev_Mar_Avr_Mai_Gün_Jul_Gus_Set_Lis_Noe_Zec'.split('_'),\n weekdays: 'Súladi_Lúneçi_Maitzi_Márcuri_Xhúadi_Viénerçi_Sáturi'.split('_'),\n weekdaysShort: 'Súl_Lún_Mai_Már_Xhú_Vié_Sát'.split('_'),\n weekdaysMin: 'Sú_Lú_Ma_Má_Xh_Vi_Sá'.split('_'),\n longDateFormat: {\n LT: 'HH.mm',\n LTS: 'HH.mm.ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM [dallas] YYYY',\n LLL: 'D. MMMM [dallas] YYYY HH.mm',\n LLLL: 'dddd, [li] D. MMMM [dallas] YYYY HH.mm',\n },\n meridiemParse: /d\\'o|d\\'a/i,\n isPM: function (input) {\n return \"d'o\" === input.toLowerCase();\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours > 11) {\n return isLower ? \"d'o\" : \"D'O\";\n } else {\n return isLower ? \"d'a\" : \"D'A\";\n }\n },\n calendar: {\n sameDay: '[oxhi à ] LT',\n nextDay: '[demà à ] LT',\n nextWeek: 'dddd [à ] LT',\n lastDay: '[ieiri à ] LT',\n lastWeek: '[sür el] dddd [lasteu à ] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'osprei %s',\n past: 'ja%s',\n s: processRelativeTime,\n ss: processRelativeTime,\n m: processRelativeTime,\n mm: processRelativeTime,\n h: processRelativeTime,\n hh: processRelativeTime,\n d: processRelativeTime,\n dd: processRelativeTime,\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n s: ['viensas secunds', \"'iensas secunds\"],\n ss: [number + ' secunds', '' + number + ' secunds'],\n m: [\"'n mÃut\", \"'iens mÃut\"],\n mm: [number + ' mÃuts', '' + number + ' mÃuts'],\n h: [\"'n þora\", \"'iensa þora\"],\n hh: [number + ' þoras', '' + number + ' þoras'],\n d: [\"'n ziua\", \"'iensa ziua\"],\n dd: [number + ' ziuas', '' + number + ' ziuas'],\n M: [\"'n mes\", \"'iens mes\"],\n MM: [number + ' mesen', '' + number + ' mesen'],\n y: [\"'n ar\", \"'iens ar\"],\n yy: [number + ' ars', '' + number + ' ars'],\n };\n return isFuture\n ? format[key][0]\n : withoutSuffix\n ? format[key][0]\n : format[key][1];\n }\n\n return tzl;\n\n})));\n","//! moment.js locale configuration\n//! locale : Klingon [tlh]\n//! author : Dominika Kruk : https://github.com/amaranthrose\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var numbersNouns = 'pagh_wa’_cha’_wej_loS_vagh_jav_Soch_chorgh_Hut'.split('_');\n\n function translateFuture(output) {\n var time = output;\n time =\n output.indexOf('jaj') !== -1\n ? time.slice(0, -3) + 'leS'\n : output.indexOf('jar') !== -1\n ? time.slice(0, -3) + 'waQ'\n : output.indexOf('DIS') !== -1\n ? time.slice(0, -3) + 'nem'\n : time + ' pIq';\n return time;\n }\n\n function translatePast(output) {\n var time = output;\n time =\n output.indexOf('jaj') !== -1\n ? time.slice(0, -3) + 'Hu’'\n : output.indexOf('jar') !== -1\n ? time.slice(0, -3) + 'wen'\n : output.indexOf('DIS') !== -1\n ? time.slice(0, -3) + 'ben'\n : time + ' ret';\n return time;\n }\n\n function translate(number, withoutSuffix, string, isFuture) {\n var numberNoun = numberAsNoun(number);\n switch (string) {\n case 'ss':\n return numberNoun + ' lup';\n case 'mm':\n return numberNoun + ' tup';\n case 'hh':\n return numberNoun + ' rep';\n case 'dd':\n return numberNoun + ' jaj';\n case 'MM':\n return numberNoun + ' jar';\n case 'yy':\n return numberNoun + ' DIS';\n }\n }\n\n function numberAsNoun(number) {\n var hundred = Math.floor((number % 1000) / 100),\n ten = Math.floor((number % 100) / 10),\n one = number % 10,\n word = '';\n if (hundred > 0) {\n word += numbersNouns[hundred] + 'vatlh';\n }\n if (ten > 0) {\n word += (word !== '' ? ' ' : '') + numbersNouns[ten] + 'maH';\n }\n if (one > 0) {\n word += (word !== '' ? ' ' : '') + numbersNouns[one];\n }\n return word === '' ? 'pagh' : word;\n }\n\n var tlh = moment.defineLocale('tlh', {\n months: 'tera’ jar wa’_tera’ jar cha’_tera’ jar wej_tera’ jar loS_tera’ jar vagh_tera’ jar jav_tera’ jar Soch_tera’ jar chorgh_tera’ jar Hut_tera’ jar wa’maH_tera’ jar wa’maH wa’_tera’ jar wa’maH cha’'.split(\n '_'\n ),\n monthsShort:\n 'jar wa’_jar cha’_jar wej_jar loS_jar vagh_jar jav_jar Soch_jar chorgh_jar Hut_jar wa’maH_jar wa’maH wa’_jar wa’maH cha’'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj'.split(\n '_'\n ),\n weekdaysShort:\n 'lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj'.split('_'),\n weekdaysMin:\n 'lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[DaHjaj] LT',\n nextDay: '[wa’leS] LT',\n nextWeek: 'LLL',\n lastDay: '[wa’Hu’] LT',\n lastWeek: 'LLL',\n sameElse: 'L',\n },\n relativeTime: {\n future: translateFuture,\n past: translatePast,\n s: 'puS lup',\n ss: translate,\n m: 'wa’ tup',\n mm: translate,\n h: 'wa’ rep',\n hh: translate,\n d: 'wa’ jaj',\n dd: translate,\n M: 'wa’ jar',\n MM: translate,\n y: 'wa’ DIS',\n yy: translate,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return tlh;\n\n})));\n","import { Droppable } from '@syncfusion/ej2-base';\nimport { isNullOrUndefined, extend } from '@syncfusion/ej2-base';\nimport { setStyleAttribute, remove, updateBlazorTemplate } from '@syncfusion/ej2-base';\nimport { getUpdateUsingRaf, appendChildren, setDisplayValue, clearReactVueTemplates, getScrollBarWidth, getScrollWidth } from '../base/util';\nimport * as events from '../base/constant';\nimport { RowRenderer } from './row-renderer';\nimport { CellMergeRender } from './cell-merge-renderer';\nimport { RowModelGenerator } from '../services/row-model-generator';\nimport { GroupModelGenerator } from '../services/group-model-generator';\nimport { isGroupAdaptive, addFixedColumnBorder } from '../base/util';\nimport * as literals from '../base/string-literals';\n// eslint-disable-next-line valid-jsdoc\n/**\n * Content module is used to render grid content\n *\n * @hidden\n */\nvar ContentRender = /** @class */ (function () {\n /**\n * Constructor for content renderer module\n *\n * @param {IGrid} parent - specifies the Igrid\n * @param {ServiceLocator} serviceLocator - specifies the service locator\n */\n function ContentRender(parent, serviceLocator) {\n var _this = this;\n this.rows = [];\n this.freezeRows = [];\n this.movableRows = [];\n this.freezeRowElements = [];\n /** @hidden */\n this.currentInfo = {};\n /** @hidden */\n this.prevCurrentView = [];\n this.isLoaded = true;\n this.drop = function (e) {\n _this.parent.notify(events.columnDrop, { target: e.target, droppedElement: e.droppedElement });\n remove(e.droppedElement);\n };\n this.infiniteCache = {};\n /** @hidden */\n this.visibleRows = [];\n this.visibleFrozenRows = [];\n this.rightFreezeRows = [];\n this.isAddRows = false;\n this.isInfiniteFreeze = false;\n this.useGroupCache = false;\n /** @hidden */\n this.tempFreezeRows = [];\n this.rafCallback = function (args) {\n var arg = args;\n return function () {\n _this.ariaService.setBusy(_this.getPanel().querySelector('.' + literals.content), false);\n if (_this.parent.isDestroyed) {\n return;\n }\n var rows = _this.rows.slice(0);\n if (_this.parent.enableInfiniteScrolling) {\n if (_this.parent.groupSettings.enableLazyLoading) {\n for (var i = 0; i < _this.visibleRows.length; i++) {\n _this.setRowsInLazyGroup(_this.visibleRows[parseInt(i.toString(), 10)], i);\n }\n }\n rows = _this.parent.getRowsObject();\n var prevPage = arg.prevPage;\n if (_this.parent.infiniteScrollSettings.enableCache && prevPage) {\n var maxBlock = _this.parent.infiniteScrollSettings.maxBlocks;\n rows = [];\n var rowIdx = (parseInt(_this.rowElements[0].getAttribute('data-rowindex'), 10) + 1);\n var startIdx = Math.ceil(rowIdx / _this.parent.pageSettings.pageSize);\n for (var i = 0, count = startIdx; i < maxBlock; i++, count++) {\n if (_this.infiniteCache[parseInt(count.toString(), 10)]) {\n rows = rows.concat(_this.infiniteCache[parseInt(count.toString(), 10)]);\n }\n }\n }\n }\n _this.parent.notify(events.contentReady, { rows: rows, args: arg });\n if (_this.parent.autoFit) {\n _this.parent.preventAdjustColumns();\n }\n if (!_this.parent.isInitialLoad) {\n _this.parent.focusModule.setFirstFocusableTabIndex();\n }\n if (_this.isLoaded) {\n _this.parent.isManualRefresh = false;\n if (_this.parent.enableInfiniteScrolling && _this.parent.groupSettings.enableLazyLoading && args.requestType === 'sorting') {\n _this.parent.infiniteScrollModule['groupCaptionAction'] = undefined;\n }\n var isReactChild = _this.parent.parentDetails && _this.parent.parentDetails.parentInstObj &&\n _this.parent.parentDetails.parentInstObj.isReact;\n if ((_this.parent.isReact || isReactChild) && _this.parent.element.querySelectorAll('.e-templatecell').length) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var thisRef_1 = _this;\n thisRef_1.parent.renderTemplates(function () {\n thisRef_1.parent.trigger(events.dataBound, {}, function () {\n if (thisRef_1.parent.allowTextWrap) {\n thisRef_1.parent.notify(events.freezeRender, { case: 'textwrap' });\n }\n });\n });\n }\n else {\n _this.parent.trigger(events.dataBound, {}, function () {\n if (_this.parent.allowTextWrap) {\n _this.parent.notify(events.freezeRender, { case: 'textwrap' });\n }\n });\n }\n if (_this.parent.allowTextWrap && _this.parent.height === 'auto') {\n if (_this.parent.getContentTable().scrollHeight > _this.parent.getContent().clientHeight) {\n _this.parent.scrollModule.setPadding();\n }\n else {\n _this.parent.scrollModule.removePadding();\n }\n }\n }\n if (arg) {\n var action = (arg.requestType || '').toLowerCase() + '-complete';\n _this.parent.notify(action, arg);\n if (args.requestType === 'batchsave') {\n args.cancel = false;\n _this.parent.trigger(events.actionComplete, args);\n }\n }\n if (_this.isLoaded) {\n _this.parent.hideSpinner();\n }\n };\n };\n this.parent = parent;\n this.serviceLocator = serviceLocator;\n this.widthService = serviceLocator.getService('widthService');\n this.ariaService = this.serviceLocator.getService('ariaService');\n this.parent.enableDeepCompare = this.parent.getDataModule().isRemote();\n this.generator = this.getModelGenerator();\n if (this.parent.isDestroyed) {\n return;\n }\n if (!this.parent.enableColumnVirtualization && !this.parent.enableVirtualization\n && !this.parent.groupSettings.enableLazyLoading) {\n this.parent.on(events.columnVisibilityChanged, this.setVisible, this);\n }\n this.parent.on(events.colGroupRefresh, this.colGroupRefresh, this);\n this.parent.on(events.uiUpdate, this.enableAfterRender, this);\n this.parent.on(events.refreshInfiniteModeBlocks, this.refreshContentRows, this);\n this.parent.on(events.beforeCellFocused, this.beforeCellFocused, this);\n this.parent.on(events.destroy, this.droppableDestroy, this);\n }\n ContentRender.prototype.beforeCellFocused = function (e) {\n if (e.byKey && (e.keyArgs.action === 'upArrow' || e.keyArgs.action === 'downArrow')) {\n this.pressedKey = e.keyArgs.action;\n }\n else {\n this.pressedKey = undefined;\n }\n };\n /**\n * The function is used to render grid content div\n *\n * @returns {void}\n */\n ContentRender.prototype.renderPanel = function () {\n var gObj = this.parent;\n var div = this.parent.element.querySelector('.' + literals.gridContent);\n if (div) {\n this.ariaService.setOptions(this.parent.element.querySelector('.' + literals.content), { busy: false });\n this.setPanel(div);\n return;\n }\n div = this.parent.createElement('div', { className: literals.gridContent });\n var innerDiv = this.parent.createElement('div', {\n className: literals.content\n });\n this.ariaService.setOptions(innerDiv, { busy: false });\n if (this.parent.enableColumnVirtualization && this.parent.isFrozenGrid()) {\n this.renderHorizontalScrollbar(div);\n innerDiv.classList.add('e-virtual-content');\n }\n div.appendChild(innerDiv);\n this.setPanel(div);\n gObj.element.appendChild(div);\n };\n ContentRender.prototype.renderHorizontalScrollbar = function (element) {\n var parent = this.parent.createElement('div', { className: 'e-movablescrollbar' });\n var child = this.parent.createElement('div', { className: 'e-movablechild' });\n var scrollbarHeight = getScrollBarWidth().toString();\n this.setScrollbarHeight(child, scrollbarHeight);\n this.setScrollbarHeight(parent, scrollbarHeight);\n parent.appendChild(child);\n element.appendChild(parent);\n };\n ContentRender.prototype.setScrollbarHeight = function (ele, height) {\n ele.style.minHeight = height + 'px';\n ele.style.maxHeight = height + 'px';\n };\n /**\n * The function is used to render grid content table\n *\n * @returns {void}\n */\n ContentRender.prototype.renderTable = function () {\n var contentDiv = this.getPanel();\n var virtualTable = contentDiv.querySelector('.e-virtualtable');\n var virtualTrack = contentDiv.querySelector('.e-virtualtrack');\n if (this.parent.enableVirtualization && !isNullOrUndefined(virtualTable) && !isNullOrUndefined(virtualTrack)) {\n remove(virtualTable);\n remove(virtualTrack);\n }\n contentDiv.appendChild(this.createContentTable('_content_table'));\n this.setTable(contentDiv.querySelector('.' + literals.table));\n if (this.parent.selectionSettings.type === 'Multiple') {\n this.ariaService.setOptions(this.parent.element, {\n multiselectable: true\n });\n }\n this.initializeContentDrop();\n if (this.parent.frozenRows) {\n this.parent.getHeaderContent().classList.add('e-frozenhdr');\n }\n };\n /**\n * The function is used to create content table elements\n *\n * @param {string} id - specifies the id\n * @returns {Element} returns the element\n * @hidden\n */\n ContentRender.prototype.createContentTable = function (id) {\n var innerDiv = this.getPanel().firstElementChild;\n if (this.getTable()) {\n remove(this.getTable());\n }\n var table = innerDiv.querySelector('.' + literals.table) ? innerDiv.querySelector('.' + literals.table) :\n this.parent.createElement('table', {\n className: literals.table, attrs: {\n cellspacing: '0.25px', role: 'presentation',\n id: this.parent.element.id + id\n }\n });\n this.setColGroup(this.parent.getHeaderTable().querySelector(literals.colGroup).cloneNode(true));\n table.appendChild(this.getColGroup());\n table.appendChild(this.parent.createElement(literals.tbody, { attrs: { role: 'rowgroup' } }));\n innerDiv.appendChild(table);\n return innerDiv;\n };\n /**\n * Refresh the content of the Grid.\n *\n * @param {NotifyArgs} args - specifies the args\n * @returns {void}\n */\n // tslint:disable-next-line:max-func-body-length\n ContentRender.prototype.refreshContentRows = function (args) {\n var _this = this;\n if (args === void 0) { args = {}; }\n var gObj = this.parent;\n if (gObj.currentViewData.length === 0) {\n return;\n }\n if (gObj.editSettings && gObj.editModule && gObj.editSettings.mode === 'Batch' && gObj.editModule.formObj\n && gObj.editSettings.showConfirmDialog === false) {\n gObj.editModule.destroyForm();\n }\n var dataSource = this.currentMovableRows || gObj.currentViewData;\n var isReact = gObj.isReact && !isNullOrUndefined(gObj.rowTemplate);\n var frag = isReact ? gObj.createElement(literals.tbody, { attrs: { role: 'rowgroup' } }) : document.createDocumentFragment();\n if (!this.initialPageRecords) {\n this.initialPageRecords = extend([], dataSource);\n }\n var hdrfrag = isReact ? gObj.createElement(literals.tbody, { attrs: { role: 'rowgroup' } }) : document.createDocumentFragment();\n var refFrag;\n var refHdrfrag;\n if (gObj.isReact && gObj.rowTemplate) {\n refFrag = frag;\n refHdrfrag = hdrfrag;\n }\n var columns = gObj.getColumns();\n var tr;\n var hdrTbody;\n var trElement;\n var row = new RowRenderer(this.serviceLocator, null, this.parent);\n var isInfiniteScroll = this.parent.enableInfiniteScrolling\n && args.requestType === 'infiniteScroll';\n gObj.notify(events.destroyChildGrid, {});\n this.rowElements = [];\n this.rows = [];\n this.tempFreezeRows = [];\n var tbdy;\n var tableName;\n var isGroupFrozenHdr = this.parent.frozenRows && this.parent.groupSettings.columns.length ? true : false;\n if (isGroupAdaptive(gObj)) {\n if (['sorting', 'filtering', 'searching', 'grouping', 'ungrouping', 'reorder', 'save', 'delete']\n .some(function (value) { return args.requestType === value; })) {\n this.emptyVcRows();\n }\n }\n var modelData;\n modelData = this.checkCache(modelData, args);\n if (!this.isAddRows && !this.useGroupCache) {\n modelData = this.generator.generateRows(dataSource, args);\n }\n this.setGroupCache(modelData, args);\n this.parent.notify(events.setInfiniteCache, { isInfiniteScroll: isInfiniteScroll, modelData: modelData, args: args });\n var isFrozenLeft = false;\n /* eslint-disable */\n if (!(args.requestType === 'infiniteScroll' && !this.parent.infiniteScrollSettings.enableCache) && this.parent.registeredTemplate\n && this.parent.registeredTemplate.template && !args.isFrozen && !isFrozenLeft) {\n var templatetoclear = [];\n for (var i = 0; i < this.parent.registeredTemplate.template.length; i++) {\n for (var j = 0; j < this.parent.registeredTemplate.template[i].rootNodes.length; j++) {\n if (isNullOrUndefined(this.parent.registeredTemplate.template[i].rootNodes[j].parentNode)) {\n templatetoclear.push(this.parent.registeredTemplate.template[i]);\n /* eslint-enable */\n }\n }\n }\n this.parent.destroyTemplate(['template'], templatetoclear);\n }\n if ((this.parent.isReact || this.parent.isVue) && !(args.requestType === 'infiniteScroll' && !this.parent.infiniteScrollSettings.enableCache) && !args.isFrozen) {\n var templates = [\n this.parent.isVue ? 'template' : 'columnTemplate', 'rowTemplate', 'detailTemplate',\n 'captionTemplate', 'commandsTemplate', 'groupFooterTemplate', 'groupCaptionTemplate'\n ];\n if (args.requestType === 'infiniteScroll' && this.parent.infiniteScrollSettings.enableCache) {\n templates = [\n this.parent.isVue ? 'template' : 'columnTemplate', 'commandsTemplate'\n ];\n }\n clearReactVueTemplates(this.parent, templates);\n }\n if (this.parent.enableColumnVirtualization) {\n var cellMerge = new CellMergeRender(this.serviceLocator, this.parent);\n cellMerge.updateVirtualCells(modelData);\n }\n this.tbody = this.getTable().querySelector(literals.tbody);\n var startIndex = 0;\n var blockLoad = true;\n if (isGroupAdaptive(gObj) && gObj.vcRows.length) {\n var top_1 = 'top';\n var scrollTop = !isNullOrUndefined(args.virtualInfo.offsets) ? args.virtualInfo.offsets.top :\n (!isNullOrUndefined(args.scrollTop) ? args.scrollTop[\"\" + top_1] : 0);\n if (scrollTop !== 0) {\n var offsets_1 = gObj.vGroupOffsets;\n var bSize = gObj.pageSettings.pageSize / 2;\n var values = Object.keys(offsets_1).map(function (key) { return offsets_1[\"\" + key]; });\n for (var m = 0; m < values.length; m++) {\n if (scrollTop < values[parseInt(m.toString(), 10)]) {\n if (!isNullOrUndefined(args.virtualInfo) && args.virtualInfo.direction === 'up') {\n startIndex = m > 0 ? ((m - 1) * bSize) : (m * bSize);\n break;\n }\n else {\n startIndex = m * bSize;\n if (this.parent.contentModule.isEndBlock(m) || this.parent.contentModule.isEndBlock(m + 1)) {\n args.virtualInfo.blockIndexes = [m, m + 1];\n }\n break;\n }\n }\n }\n if (Math.round(scrollTop + this.contentPanel.firstElementChild.offsetHeight) >=\n this.contentPanel.firstElementChild.scrollHeight && !args.rowObject) {\n blockLoad = false;\n }\n }\n }\n var isVFFrozenOnly = gObj.frozenRows && this.parent.enableVirtualization\n && args.requestType === 'reorder';\n if ((gObj.frozenRows && args.requestType === 'virtualscroll' && args.virtualInfo.sentinelInfo.axis === 'X') || isVFFrozenOnly) {\n var bIndex = args.virtualInfo.blockIndexes;\n var page = args.virtualInfo.page;\n args.virtualInfo.blockIndexes = [1, 2];\n if (isVFFrozenOnly) {\n args.virtualInfo.page = 1;\n }\n var data = isVFFrozenOnly ? this.initialPageRecords : dataSource;\n var mhdrData = this.vgenerator\n .generateRows(data, args);\n mhdrData.splice(this.parent.frozenRows);\n for (var i = 0; i < this.parent.frozenRows; i++) {\n // mhdrData[parseInt(i.toString(), 10)].cells.splice(0, this.parent.getFrozenColumns());\n tr = row.render(mhdrData[parseInt(i.toString(), 10)], columns);\n addFixedColumnBorder(tr);\n hdrfrag.appendChild(tr);\n }\n args.virtualInfo.blockIndexes = bIndex;\n args.virtualInfo.page = page;\n if (isVFFrozenOnly && args.virtualInfo.page === 1) {\n modelData.splice(0, this.parent.frozenRows);\n }\n }\n this.virtualFrozenHdrRefresh(hdrfrag, modelData, row, args, dataSource, columns);\n if (this.parent.groupSettings.enableLazyLoading && !this.useGroupCache && this.parent.groupSettings.columns.length) {\n (this.parent.enableVirtualization ? this.parent.lazyLoadRender :\n this.parent.contentModule).refRowsObj[this.parent.pageSettings.currentPage] = [];\n }\n if (this.parent.enableInfiniteScrolling && this.parent.groupSettings.enableLazyLoading && args.requestType === 'delete') { // || (this.parent.infiniteScrollSettings && this.parent.infiniteScrollSettings.enableCache))\n this.visibleRows = [];\n }\n var _loop_1 = function (i, len) {\n this_1.rows.push(modelData[parseInt(i.toString(), 10)]);\n if (this_1.parent.groupSettings.enableLazyLoading && !this_1.useGroupCache && this_1.parent.groupSettings.columns.length) {\n (this_1.parent.enableVirtualization ? this_1.parent.lazyLoadRender :\n this_1.parent.contentModule).refRowsObj[this_1.parent.pageSettings.currentPage].push(modelData[parseInt(i.toString(), 10)]);\n this_1.setRowsInLazyGroup(modelData[parseInt(i.toString(), 10)], i);\n if (isNullOrUndefined(modelData[parseInt(i.toString(), 10)].indent)) {\n return \"continue\";\n }\n }\n this_1.setInfiniteVisibleRows(args, modelData[parseInt(i.toString(), 10)]);\n if (isGroupAdaptive(gObj) && args.virtualInfo && args.virtualInfo.blockIndexes\n && (this_1.rowElements.length >= (args.virtualInfo.blockIndexes.length * this_1.parent.contentModule.getBlockSize()))\n && blockLoad) {\n this_1.parent.currentViewData['records'] = this_1.rows.map(function (m) { return m.data; });\n return \"break\";\n }\n if (!gObj.rowTemplate) {\n tr = row.render(modelData[parseInt(i.toString(), 10)], columns);\n addFixedColumnBorder(tr);\n var isVFreorder = this_1.ensureFrozenHeaderRender(args);\n if (gObj.frozenRows && (i < gObj.frozenRows || isGroupFrozenHdr) && !isInfiniteScroll && args.requestType !== 'virtualscroll' && isVFreorder\n && this_1.ensureVirtualFrozenHeaderRender(args)) {\n hdrfrag.appendChild(tr);\n }\n else {\n frag.appendChild(tr);\n }\n var rowIdx = parseInt(tr.getAttribute('data-rowindex'), 10);\n if (rowIdx + 1 === gObj.frozenRows) {\n isGroupFrozenHdr = false;\n }\n if (modelData[parseInt(i.toString(), 10)].isExpand) {\n gObj.notify(events.expandChildGrid, tr.cells[gObj.groupSettings.columns.length]);\n }\n }\n else {\n var rowTemplateID = gObj.element.id + 'rowTemplate';\n var elements = void 0;\n if (gObj.isReact) {\n var isHeader = gObj.frozenRows && i < gObj.frozenRows;\n var copied = extend({ index: i }, dataSource[parseInt(i.toString(), 10)]);\n gObj.getRowTemplate()(copied, gObj, 'rowTemplate', rowTemplateID, null, null, isHeader ? hdrfrag : frag);\n if (gObj.requireTemplateRef) {\n // eslint-disable-next-line @typescript-eslint/no-this-alias\n var thisRef_2 = this_1;\n thisRef_2.parent.renderTemplates(function () {\n if (gObj.frozenRows && i < gObj.frozenRows) {\n tr = refHdrfrag.childNodes[parseInt(i.toString(), 10)];\n }\n else {\n trElement = refFrag.childNodes[parseInt(i.toString(), 10)];\n }\n var arg = { data: modelData[parseInt(i.toString(), 10)].data,\n row: trElement ? trElement : tr };\n thisRef_2.parent.trigger(events.rowDataBound, arg);\n if (modelData[parseInt(i.toString(), 10)].isDataRow || (thisRef_2.parent.enableVirtualization &&\n thisRef_2.parent.groupSettings.enableLazyLoading)) {\n thisRef_2.rowElements.push(tr);\n }\n thisRef_2.ariaService.setOptions(thisRef_2.parent.element, {\n colcount: gObj.getColumns().length.toString()\n });\n if (i === modelData.length - 1) {\n refFrag = null;\n refHdrfrag = null;\n }\n });\n return \"continue\";\n }\n }\n else {\n elements = gObj.getRowTemplate()(extend({ index: i }, dataSource[parseInt(i.toString(), 10)]), gObj, 'rowTemplate', rowTemplateID, undefined, undefined, undefined, this_1.parent['root']);\n }\n if (!gObj.isReact && elements[0].tagName === 'TBODY') {\n for (var j = 0; j < elements.length; j++) {\n var isTR = elements[parseInt(j.toString(), 10)].nodeName.toLowerCase() === 'tr';\n if (isTR || (elements[parseInt(j.toString(), 10)].querySelectorAll && elements[parseInt(j.toString(), 10)].querySelectorAll('tr').length)) {\n tr = isTR ? elements[parseInt(j.toString(), 10)] : elements[parseInt(j.toString(), 10)].querySelector('tr');\n }\n }\n if (gObj.frozenRows && i < gObj.frozenRows) {\n hdrfrag.appendChild(tr);\n }\n else {\n frag.appendChild(tr);\n }\n }\n else {\n if (gObj.frozenRows && i < gObj.frozenRows) {\n tr = !gObj.isReact ? appendChildren(hdrfrag, elements) : hdrfrag.lastElementChild;\n }\n else {\n // frag.appendChild(tr);\n if (!gObj.isReact) {\n tr = appendChildren(frag, elements);\n }\n trElement = gObj.isReact ? frag.lastElementChild : tr.lastElementChild;\n }\n }\n var arg = { data: modelData[parseInt(i.toString(), 10)].data, row: trElement ? trElement : tr };\n this_1.parent.trigger(events.rowDataBound, arg);\n }\n if (modelData[parseInt(i.toString(), 10)].isDataRow || (this_1.parent.enableVirtualization &&\n this_1.parent.groupSettings.enableLazyLoading)) {\n this_1.rowElements.push(tr);\n }\n this_1.ariaService.setOptions(this_1.parent.element, { colcount: gObj.getColumns().length.toString() });\n };\n var this_1 = this;\n for (var i = startIndex, len = modelData.length; i < len; i++) {\n var state_1 = _loop_1(i, len);\n if (state_1 === \"break\")\n break;\n }\n var isReactChild = gObj.parentDetails && gObj.parentDetails.parentInstObj && gObj.parentDetails.parentInstObj.isReact;\n if ((gObj.isReact || isReactChild) && !gObj.requireTemplateRef) {\n gObj.renderTemplates();\n }\n if (this.parent.enableInfiniteScrolling && this.parent.groupSettings.enableLazyLoading) {\n this.parent.contentModule.refRowsObj[this.parent.pageSettings.currentPage] =\n this.parent.contentModule['groupCache'][this.parent.pageSettings.currentPage];\n }\n if (this.parent.groupSettings.enableLazyLoading && !this.useGroupCache && this.parent.groupSettings.columns.length) {\n this.parent.notify(events.refreshExpandandCollapse, {\n rows: (this.parent.enableVirtualization ? this.parent.lazyLoadRender :\n this.parent.contentModule).refRowsObj[this.parent.pageSettings.currentPage]\n });\n }\n gObj.removeMaskRow();\n this.parent.notify('removeGanttShimmer', { requestType: 'hideShimmer' });\n if ((gObj.frozenRows && args.requestType !== 'virtualscroll' && !isInfiniteScroll && this.ensureVirtualFrozenHeaderRender(args))\n || (args.requestType === 'virtualscroll' && args.virtualInfo.sentinelInfo && args.virtualInfo.sentinelInfo.axis === 'X')) {\n hdrTbody = gObj.getHeaderTable().querySelector(literals.tbody);\n if (isReact) {\n var parentTable = hdrTbody.parentElement;\n remove(hdrTbody);\n parentTable.appendChild(hdrfrag);\n }\n else {\n hdrTbody.innerHTML = '';\n hdrTbody.appendChild(hdrfrag);\n }\n if (!gObj.isInitialLoad) {\n gObj.scrollModule.setHeight();\n }\n }\n // if (!gObj.enableVirtualization && hdrTbody && gObj.frozenRows && idx === 0 && cont.offsetHeight === Number(gObj.height)) {\n // cont.style.height = (cont.offsetHeight - hdrTbody.offsetHeight) + 'px';\n // }\n args.rows = this.rows.slice(0);\n getUpdateUsingRaf(function () {\n _this.parent.notify(events.beforeFragAppend, args);\n if (!_this.parent.enableVirtualization && !_this.parent.enableColumnVirtualization && !isInfiniteScroll) {\n if (!gObj.isReact) {\n _this.tbody.innerHTML = '';\n }\n if (!isNullOrUndefined(_this.tbody.parentElement)) {\n remove(_this.tbody);\n }\n else {\n remove(gObj.getContentTable().querySelector(literals.tbody));\n }\n _this.tbody = _this.parent.createElement(literals.tbody, { attrs: { role: 'rowgroup' } });\n }\n if (gObj.rowTemplate) {\n updateBlazorTemplate(gObj.element.id + 'rowTemplate', 'RowTemplate', gObj);\n }\n if (!isNullOrUndefined(_this.parent.infiniteScrollModule) && _this.parent.enableInfiniteScrolling) {\n _this.isAddRows = false;\n _this.parent.notify(events.removeInfiniteRows, { args: args });\n _this.parent.notify(events.appendInfiniteContent, {\n tbody: tbdy ? tbdy : _this.tbody, frag: frag, args: args, rows: _this.rows,\n rowElements: _this.rowElements, visibleRows: _this.visibleRows,\n tableName: tableName\n });\n }\n else {\n _this.useGroupCache = false;\n _this.appendContent(_this.tbody, frag, args);\n }\n if (_this.parent.getVisibleFrozenRightCount() && _this.parent.getContent() && getScrollWidth(_this.parent) > 0) {\n _this.parent.element.classList.add('e-right-shadow');\n }\n frag = null;\n }, this.rafCallback(extend({}, args)));\n };\n ContentRender.prototype.emptyVcRows = function () {\n this.parent.vcRows = [];\n this.parent.vRows = [];\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n ContentRender.prototype.appendContent = function (tbody, frag, args, tableName) {\n var isReact = this.parent.isReact && !isNullOrUndefined(this.parent.rowTemplate);\n if (isReact) {\n this.getTable().appendChild(frag);\n }\n else {\n tbody.appendChild(frag);\n this.getTable().appendChild(tbody);\n }\n if (this.parent.rowRenderingMode === 'Vertical' && this.parent.allowTextWrap && (this.parent.textWrapSettings.wrapMode === 'Header'\n || this.parent.textWrapSettings.wrapMode === 'Both')) {\n var cells = tbody.querySelectorAll('td');\n for (var i = 0; i < cells.length; i++) {\n var headerCellHeight = parseFloat(document.defaultView.getComputedStyle(cells[parseInt(i.toString(), 10)], '::before').getPropertyValue('height'));\n var cellHeight = cells[parseInt(i.toString(), 10)].offsetHeight;\n if (headerCellHeight > cellHeight) {\n cells[parseInt(i.toString(), 10)].style.height = headerCellHeight + 'px';\n cells[parseInt(i.toString(), 10)].style.boxSizing = 'content-box';\n }\n }\n }\n if (this.parent.getVisibleFrozenLeftCount() && this.parent.enableColumnVirtualization) {\n this.widthService.refreshFrozenScrollbar();\n }\n };\n ContentRender.prototype.setRowsInLazyGroup = function (row, index) {\n if (this.parent.groupSettings.enableLazyLoading && !this.useGroupCache && this.parent.groupSettings.columns.length) {\n (this.parent.enableVirtualization ? this.parent.lazyLoadRender :\n this.parent.contentModule).maintainRows(row, index);\n }\n };\n ContentRender.prototype.setGroupCache = function (data, args) {\n if (!this.useGroupCache && this.parent.groupSettings.enableLazyLoading) {\n this.parent.notify(events.setGroupCache, { args: args, data: data });\n }\n };\n ContentRender.prototype.ensureFrozenHeaderRender = function (args) {\n return !((this.parent.enableVirtualization\n && (args.requestType === 'reorder' || args.requestType === 'refresh')) || (this.parent.infiniteScrollSettings.enableCache\n && this.parent.frozenRows && this.parent.infiniteScrollModule.requestType === 'delete'\n && this.parent.pageSettings.currentPage !== 1));\n };\n ContentRender.prototype.ensureVirtualFrozenHeaderRender = function (args) {\n return !(this.parent.enableVirtualization && args.requestType === 'delete');\n };\n ContentRender.prototype.checkCache = function (modelData, args) {\n if (this.parent.infiniteScrollSettings.enableCache && args.requestType === 'infiniteScroll') {\n this.isAddRows = !isNullOrUndefined(this.infiniteCache[this.parent.pageSettings.currentPage]);\n if (this.isAddRows) {\n var data = this.infiniteCache[this.parent.pageSettings.currentPage];\n modelData = this.parent.pageSettings.currentPage === 1 ? data.slice(this.parent.frozenRows) : data;\n }\n return modelData;\n }\n if (this.parent.groupSettings.enableLazyLoading && this.parent.groupSettings.columns.length && (args.requestType === 'paging'\n || args.requestType === 'columnstate' || args.requestType === 'reorder' || args.requestType === 'virtualscroll')\n && (this.parent.enableVirtualization ? this.parent.lazyLoadRender :\n this.parent.contentModule).getGroupCache()[this.parent.pageSettings.currentPage]) {\n if (!this.parent.enableVirtualization) {\n this.useGroupCache = true;\n }\n return this.parent.enableVirtualization ? this.parent.getRowsObject() :\n this.parent.contentModule.initialGroupRows(args.requestType === 'reorder');\n }\n return null;\n };\n ContentRender.prototype.setInfiniteVisibleRows = function (args, data) {\n if (this.parent.enableInfiniteScrolling && !this.parent.infiniteScrollSettings.enableCache) {\n if (!this.parent.infiniteScrollSettings.enableCache) {\n this.visibleRows.push(data);\n }\n }\n };\n ContentRender.prototype.getCurrentBlockInfiniteRecords = function () {\n var data = [];\n if (this.parent.infiniteScrollSettings.enableCache) {\n if (!Object.keys(this.infiniteCache).length) {\n return [];\n }\n var rows = this.parent.getRows();\n var index = parseInt(rows[this.parent.frozenRows].getAttribute(literals.dataRowIndex), 10);\n var first = Math.ceil((index + 1) / this.parent.pageSettings.pageSize);\n index = parseInt(rows[rows.length - 1].getAttribute(literals.dataRowIndex), 10);\n var last = Math.ceil((index + (rows.length ? 1 : 0)) / this.parent.pageSettings.pageSize);\n for (var i = first; i <= last; i++) {\n data = !data.length ? this.infiniteCache[parseInt(i.toString(), 10)]\n : data.concat(this.infiniteCache[parseInt(i.toString(), 10)]);\n }\n if (this.parent.frozenRows && this.parent.pageSettings.currentPage > 1) {\n data = this.infiniteCache[1].slice(0, this.parent.frozenRows).concat(data);\n }\n }\n return data;\n };\n ContentRender.prototype.getReorderedRows = function (args) {\n return this.parent.contentModule.getReorderedFrozenRows(args);\n };\n ContentRender.prototype.virtualFrozenHdrRefresh = function (hdrfrag, modelData, row, args, dataSource, columns) {\n if (this.parent.frozenRows && this.parent.enableVirtualization\n && (args.requestType === 'reorder' || args.requestType === 'refresh')) {\n var tr = void 0;\n var fhdrData = this.getReorderedRows(args);\n for (var i = 0; i < fhdrData.length; i++) {\n tr = row.render(fhdrData[parseInt(i.toString(), 10)], columns);\n hdrfrag.appendChild(tr);\n }\n if (args.virtualInfo.page === 1) {\n modelData.splice(0, this.parent.frozenRows);\n }\n }\n };\n ContentRender.prototype.getInfiniteRows = function () {\n var rows = [];\n if (this.parent.enableInfiniteScrolling) {\n if (this.parent.infiniteScrollSettings.enableCache) {\n var keys = Object.keys(this.infiniteCache);\n for (var i = 0; i < keys.length; i++) {\n rows = rows.concat(this.infiniteCache[keys[parseInt(i.toString(), 10)]]);\n }\n }\n else {\n rows = this.visibleRows;\n }\n }\n return rows;\n };\n ContentRender.prototype.getInfiniteMovableRows = function () {\n var infiniteCacheRows = this.getCurrentBlockInfiniteRecords();\n var infiniteRows = this.parent.enableInfiniteScrolling ? infiniteCacheRows.length ? infiniteCacheRows\n : this.visibleRows : [];\n return infiniteRows;\n };\n /**\n * Get the content div element of grid\n *\n * @returns {Element} returns the element\n */\n ContentRender.prototype.getPanel = function () {\n return this.contentPanel;\n };\n /**\n * Set the content div element of grid\n *\n * @param {Element} panel - specifies the panel\n * @returns {void}\n */\n ContentRender.prototype.setPanel = function (panel) {\n this.contentPanel = panel;\n };\n /**\n * Get the content table element of grid\n *\n * @returns {Element} returns the element\n */\n ContentRender.prototype.getTable = function () {\n return this.contentTable;\n };\n /**\n * Set the content table element of grid\n *\n * @param {Element} table - specifies the table\n * @returns {void}\n */\n ContentRender.prototype.setTable = function (table) {\n this.contentTable = table;\n };\n /**\n * Get the Movable Row collection in the Freeze pane Grid.\n *\n * @returns {Row[] | HTMLCollectionOf<HTMLTableRowElement>} returns the row\n */\n ContentRender.prototype.getRows = function () {\n var infiniteRows = this.getInfiniteRows();\n return infiniteRows.length ? infiniteRows : this.rows;\n };\n /**\n * Get the content table data row elements\n *\n * @returns {Element} returns the element\n */\n ContentRender.prototype.getRowElements = function () {\n return this.rowElements;\n };\n /**\n * Get the content table data row elements\n *\n * @param {Element[]} elements - specifies the elements\n * @returns {void}\n */\n ContentRender.prototype.setRowElements = function (elements) {\n this.rowElements = elements;\n };\n /**\n * Get the header colgroup element\n *\n * @returns {Element} returns the element\n */\n ContentRender.prototype.getColGroup = function () {\n return this.colgroup;\n };\n /**\n * Set the header colgroup element\n *\n * @param {Element} colGroup - specifies the colgroup\n * @returns {Element} returns the element\n */\n ContentRender.prototype.setColGroup = function (colGroup) {\n if (!isNullOrUndefined(colGroup)) {\n colGroup.id = 'content-' + colGroup.id;\n }\n return this.colgroup = colGroup;\n };\n /**\n * Function to hide content table column based on visible property\n *\n * @param {Column[]} columns - specifies the column\n * @returns {void}\n */\n ContentRender.prototype.setVisible = function (columns) {\n var gObj = this.parent;\n var rows = this.getRows();\n var testRow;\n rows.some(function (r) { if (r.isDataRow) {\n testRow = r;\n } return r.isDataRow; });\n var needFullRefresh = true;\n if (!gObj.groupSettings.columns.length && testRow) {\n needFullRefresh = false;\n }\n var tr = gObj.getDataRows();\n var args = {};\n var infiniteData = this.infiniteRowVisibility();\n var contentrows = infiniteData ? infiniteData\n : this.rows.filter(function (row) { return !row.isDetailRow; });\n for (var c = 0, clen = columns.length; c < clen; c++) {\n var column = columns[parseInt(c.toString(), 10)];\n var idx = this.parent.getNormalizedColumnIndex(column.uid);\n var colIdx = this.parent.getColumnIndexByUid(column.uid);\n var displayVal = column.visible === true ? '' : 'none';\n if (idx !== -1 && testRow && idx < testRow.cells.length) {\n setStyleAttribute(this.getColGroup().childNodes[parseInt(idx.toString(), 10)], { 'display': displayVal });\n }\n if (!needFullRefresh) {\n this.setDisplayNone(tr, colIdx, displayVal, contentrows);\n }\n if (!this.parent.invokedFromMedia && column.hideAtMedia) {\n this.parent.updateMediaColumns(column);\n }\n this.parent.invokedFromMedia = false;\n }\n if (needFullRefresh) {\n this.refreshContentRows({ requestType: 'refresh' });\n }\n else {\n this.parent.notify(events.partialRefresh, { rows: contentrows, args: args });\n }\n };\n /**\n * @param {Object} tr - specifies the trr\n * @param {number} idx - specifies the idx\n * @param {string} displayVal - specifies the displayval\n * @param {Row<Column>} rows - specifies the rows\n * @returns {void}\n * @hidden\n */\n ContentRender.prototype.setDisplayNone = function (tr, idx, displayVal, rows) {\n setDisplayValue(tr, idx, displayVal, rows, this.parent, this.parent.isRowDragable());\n this.parent.notify(events.infiniteShowHide, { visible: displayVal, index: idx, isFreeze: this.isInfiniteFreeze });\n };\n ContentRender.prototype.infiniteRowVisibility = function (isFreeze) {\n var infiniteData;\n if (this.parent.enableInfiniteScrolling) {\n this.isInfiniteFreeze = isFreeze;\n if (this.parent.infiniteScrollSettings.enableCache) {\n infiniteData = isFreeze ? this.getCurrentBlockInfiniteRecords() : this.getCurrentBlockInfiniteRecords();\n }\n else {\n infiniteData = isFreeze ? this.visibleFrozenRows : this.visibleRows;\n }\n }\n return infiniteData;\n };\n ContentRender.prototype.colGroupRefresh = function () {\n if (this.getColGroup()) {\n var colGroup = this.getHeaderColGroup();\n this.getTable().replaceChild(colGroup, this.getColGroup());\n this.setColGroup(colGroup);\n }\n };\n ContentRender.prototype.getHeaderColGroup = function () {\n return this.parent.element.querySelector('.' + literals.gridHeader)\n .querySelector(literals.colGroup + ':not(.e-masked-colgroup)').cloneNode(true);\n };\n ContentRender.prototype.initializeContentDrop = function () {\n var gObj = this.parent;\n this.droppable = new Droppable(gObj.element, {\n accept: '.e-dragclone',\n drop: this.drop\n });\n };\n ContentRender.prototype.droppableDestroy = function () {\n if (this.droppable && !this.droppable.isDestroyed) {\n this.droppable.destroy();\n }\n };\n ContentRender.prototype.canSkip = function (column, row, index) {\n /**\n * Skip the toggle visiblity operation when one of the following success\n * 1. Grid has empty records\n * 2. column visible property is unchanged\n * 3. cell`s isVisible property is same as column`s visible property.\n */\n return isNullOrUndefined(row) || //(1)\n isNullOrUndefined(column.visible) || //(2)\n row.cells[parseInt(index.toString(), 10)].visible === column.visible; //(3)\n };\n ContentRender.prototype.getModelGenerator = function () {\n return this.generator = this.parent.allowGrouping ? new GroupModelGenerator(this.parent) : new RowModelGenerator(this.parent);\n };\n ContentRender.prototype.renderEmpty = function (tbody) {\n this.getTable().appendChild(tbody);\n if (this.parent.frozenRows) {\n this.parent.getHeaderContent().querySelector(literals.tbody).innerHTML = '';\n }\n };\n ContentRender.prototype.setSelection = function (uid, set, clearAll) {\n this.parent.notify(events.setFreezeSelection, { uid: uid, set: set, clearAll: clearAll });\n var row = this.getRows().filter(function (row) { return clearAll || uid === row.uid; });\n for (var j = 0; j < row.length; j++) {\n row[parseInt(j.toString(), 10)].isSelected = set;\n var cells = row[parseInt(j.toString(), 10)].cells;\n for (var k = 0; k < cells.length; k++) {\n cells[parseInt(k.toString(), 10)].isSelected = set;\n }\n }\n };\n ContentRender.prototype.getRowByIndex = function (index) {\n index = this.getInfiniteRowIndex(index);\n return !isNullOrUndefined(index) ? this.parent.getDataRows()[parseInt(index.toString(), 10)] : undefined;\n };\n ContentRender.prototype.getInfiniteRowIndex = function (index) {\n if (this.parent.infiniteScrollSettings.enableCache && !isNullOrUndefined(index)) {\n var fRows = this.parent.frozenRows;\n var idx = fRows > index ? 0 : fRows;\n var firstRowIndex = parseInt(this.parent.getRows()[parseInt(idx.toString(), 10)]\n .getAttribute(literals.dataRowIndex), 10);\n index = fRows > index ? index : (index - firstRowIndex) + fRows;\n }\n return index;\n };\n ContentRender.prototype.getVirtualRowIndex = function (index) {\n return index;\n };\n ContentRender.prototype.enableAfterRender = function (e) {\n if (e.module === 'group' && e.enable) {\n this.generator = this.getModelGenerator();\n }\n };\n ContentRender.prototype.setRowObjects = function (rows) {\n this.rows = rows;\n };\n /**\n * @param {NotifyArgs} args - specifies the args\n * @returns {void}\n * @hidden\n */\n ContentRender.prototype.immutableModeRendering = function (args) {\n var _this = this;\n if (args === void 0) { args = {}; }\n var gObj = this.parent;\n gObj.hideSpinner();\n var key = gObj.getPrimaryKeyFieldNames()[0];\n var oldKeys = {};\n var newKeys = {};\n var newRowObjs = [];\n var oldIndexes = {};\n var oldRowObjs = gObj.getRowsObject().slice();\n var batchChangeKeys = this.getBatchEditedRecords(key, oldRowObjs);\n var newIndexes = {};\n var hasBatch = Object.keys(batchChangeKeys).length !== 0;\n if (gObj.getContent().querySelector('.e-emptyrow') || args.requestType === 'reorder'\n || this.parent.groupSettings.columns.length) {\n this.refreshContentRows(args);\n }\n else {\n if (gObj.currentViewData.length === 0) {\n return;\n }\n var oldRowElements = {};\n var tbody = gObj.createElement(literals.tbody, { attrs: { role: 'rowgroup' } });\n var dataSource = gObj.currentViewData;\n var trs = [].slice.call(this.getTable().querySelector(literals.tbody).children);\n if (this.prevCurrentView.length) {\n var prevLen = this.prevCurrentView.length;\n var currentLen = dataSource.length;\n if (prevLen === currentLen) {\n for (var i = 0; i < currentLen; i++) {\n if (this.parent.editSettings.mode === 'Batch'\n && trs[parseInt(i.toString(), 10)].classList.contains('e-insertedrow')) {\n trs.splice(i, 1);\n --i;\n continue;\n }\n newKeys[dataSource[parseInt(i.toString(), 10)][\"\" + key]] = oldKeys[this.prevCurrentView[parseInt(i.toString(), 10)][\"\" + key]] = i;\n newIndexes[parseInt(i.toString(), 10)] = dataSource[parseInt(i.toString(), 10)][\"\" + key];\n oldRowElements[oldRowObjs[parseInt(i.toString(), 10)].uid] = trs[parseInt(i.toString(), 10)];\n oldIndexes[parseInt(i.toString(), 10)] = this.prevCurrentView[parseInt(i.toString(), 10)][\"\" + key];\n }\n }\n else {\n for (var i = 0; i < currentLen; i++) {\n newKeys[dataSource[parseInt(i.toString(), 10)][\"\" + key]] = i;\n newIndexes[parseInt(i.toString(), 10)] = dataSource[parseInt(i.toString(), 10)][\"\" + key];\n }\n for (var i = 0; i < prevLen; i++) {\n if (this.parent.editSettings.mode === 'Batch'\n && trs[parseInt(i.toString(), 10)].classList.contains('e-insertedrow')) {\n trs.splice(i, 1);\n --i;\n continue;\n }\n oldRowElements[oldRowObjs[parseInt(i.toString(), 10)].uid] = trs[parseInt(i.toString(), 10)];\n oldKeys[this.prevCurrentView[parseInt(i.toString(), 10)][\"\" + key]] = i;\n oldIndexes[parseInt(i.toString(), 10)] = this.prevCurrentView[parseInt(i.toString(), 10)][\"\" + key];\n }\n }\n }\n for (var i = 0; i < dataSource.length; i++) {\n var oldIndex = oldKeys[dataSource[parseInt(i.toString(), 10)][\"\" + key]];\n if (!isNullOrUndefined(oldIndex)) {\n var isEqual = false;\n if (this.parent.enableDeepCompare) {\n isEqual = this.objectEqualityChecker(this.prevCurrentView[parseInt(oldIndex.toString(), 10)], dataSource[parseInt(i.toString(), 10)]);\n }\n var tr = oldRowElements[oldRowObjs[parseInt(oldIndex.toString(), 10)]\n .uid];\n newRowObjs.push(oldRowObjs[parseInt(oldIndex.toString(), 10)]);\n if (this.rowElements[parseInt(oldIndex.toString(), 10)] && this.rowElements[parseInt(oldIndex.toString(), 10)].getAttribute('data-uid') === newRowObjs[parseInt(i.toString(), 10)].uid\n && ((hasBatch && isNullOrUndefined(batchChangeKeys[newIndexes[parseInt(i.toString(), 10)]]))\n || (!hasBatch && (isEqual\n || this.prevCurrentView[parseInt(oldIndex.toString(), 10)] === dataSource[parseInt(i.toString(), 10)])))) {\n if (oldIndex !== i) {\n this.refreshImmutableContent(i, tr, newRowObjs[parseInt(i.toString(), 10)]);\n }\n tbody.appendChild(tr);\n continue;\n }\n if ((hasBatch && !isNullOrUndefined(batchChangeKeys[newIndexes[parseInt(i.toString(), 10)]]))\n || (!this.parent.enableDeepCompare\n && dataSource[parseInt(i.toString(), 10)] !== this.prevCurrentView[parseInt(oldIndex.toString(), 10)])\n || (this.parent.enableDeepCompare && !isEqual)) {\n oldRowObjs[parseInt(oldIndex.toString(), 10)].setRowValue(dataSource[parseInt(i.toString(), 10)]);\n }\n tbody.appendChild(tr);\n this.refreshImmutableContent(i, tr, newRowObjs[parseInt(i.toString(), 10)]);\n }\n else {\n var row = new RowRenderer(this.serviceLocator, null, gObj);\n var args_1 = { startIndex: i };\n var modelData = this.generator.generateRows([dataSource[parseInt(i.toString(), 10)]], args_1);\n newRowObjs.push(modelData[0]);\n var tr = row.render(modelData[0], gObj.getColumns());\n tbody.appendChild(tr);\n this.refreshImmutableContent(i, tr, newRowObjs[parseInt(i.toString(), 10)]);\n }\n }\n this.rows = newRowObjs;\n this.rowElements = [].slice.call(tbody.children);\n remove(this.getTable().querySelector(literals.tbody));\n this.getTable().appendChild(tbody);\n this.parent.trigger(events.dataBound, {}, function () {\n if (_this.parent.allowTextWrap) {\n _this.parent.notify(events.freezeRender, { case: 'textwrap' });\n }\n });\n if (args) {\n var action = (args.requestType || '').toLowerCase() + '-complete';\n this.parent.notify(action, args);\n }\n }\n };\n ContentRender.prototype.objectEqualityChecker = function (old, next) {\n var keys = Object.keys(old);\n var isEqual = true;\n for (var i = 0; i < keys.length; i++) {\n if (old[keys[parseInt(i.toString(), 10)]] !== next[keys[parseInt(i.toString(), 10)]]) {\n var isDate = old[keys[parseInt(i.toString(), 10)]] instanceof Date\n && next[keys[parseInt(i.toString(), 10)]] instanceof Date;\n if (!isDate || (old[keys[parseInt(i.toString(), 10)]]\n .getTime() !== next[keys[parseInt(i.toString(), 10)]].getTime())) {\n isEqual = false;\n break;\n }\n }\n }\n return isEqual;\n };\n ContentRender.prototype.getBatchEditedRecords = function (primaryKey, rows) {\n var keys = {};\n var changes = this.parent.getBatchChanges();\n var changedRecords = [];\n var addedRecords = [];\n if (Object.keys(changes).length) {\n changedRecords = changes.changedRecords;\n addedRecords = changes.addedRecords;\n }\n var args = { cancel: false };\n this.parent.notify(events.immutableBatchCancel, { rows: rows, args: args });\n if (addedRecords.length) {\n if (this.parent.editSettings.newRowPosition === 'Bottom') {\n rows.splice(rows.length - 1, addedRecords.length);\n }\n else {\n if (!args.cancel) {\n rows.splice(0, addedRecords.length);\n }\n }\n }\n for (var i = 0; i < changedRecords.length; i++) {\n keys[changedRecords[parseInt(i.toString(), 10)][\"\" + primaryKey]] = i;\n }\n return keys;\n };\n ContentRender.prototype.refreshImmutableContent = function (index, tr, row) {\n row.isAltRow = this.parent.enableAltRow ? index % 2 !== 0 : false;\n if (row.isAltRow) {\n tr.classList.add('e-altrow');\n }\n else {\n tr.classList.remove('e-altrow');\n }\n row.index = index;\n row.edit = undefined;\n row.isDirty = false;\n tr.setAttribute(literals.dataRowIndex, index.toString());\n tr.setAttribute(literals.ariaRowIndex, (index + 1).toString());\n this.updateCellIndex(tr, index);\n };\n ContentRender.prototype.updateCellIndex = function (rowEle, index) {\n for (var i = 0; i < rowEle.cells.length; i++) {\n rowEle.cells[parseInt(i.toString(), 10)].setAttribute('index', index.toString());\n }\n };\n return ContentRender;\n}());\nexport { ContentRender };\n","//! moment.js locale configuration\n//! locale : Tibetan [bo]\n//! author : Thupten N. Chakrishar : https://github.com/vajradog\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '༡',\n 2: '༢',\n 3: '༣',\n 4: '༤',\n 5: '༥',\n 6: '༦',\n 7: '༧',\n 8: '༨',\n 9: '༩',\n 0: '༠',\n },\n numberMap = {\n '༡': '1',\n '༢': '2',\n '༣': '3',\n '༤': '4',\n '༥': '5',\n '༦': '6',\n '༧': '7',\n '༨': '8',\n '༩': '9',\n '༠': '0',\n };\n\n var bo = moment.defineLocale('bo', {\n months: 'ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ'.split(\n '_'\n ),\n monthsShort:\n 'ཟླ་1_ཟླ་2_ཟླ་3_ཟླ་4_ཟླ་5_ཟླ་6_ཟླ་7_ཟླ་8_ཟླ་9_ཟླ་10_ཟླ་11_ཟླ་12'.split(\n '_'\n ),\n monthsShortRegex: /^(ཟླ་\\d{1,2})/,\n monthsParseExact: true,\n weekdays:\n 'གཟའ་ཉི་མ་_གཟའ་ཟླ་བ་_གཟའ་མིག་དམར་_གཟའ་ལྷག་པ་_གཟའ་ཕུར་བུ_གཟའ་པ་སངས་_གཟའ་སྤེན་པ་'.split(\n '_'\n ),\n weekdaysShort: 'ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་'.split(\n '_'\n ),\n weekdaysMin: 'ཉི_ཟླ_མིག_ལྷག_ཕུར_སངས_སྤེན'.split('_'),\n longDateFormat: {\n LT: 'A h:mm',\n LTS: 'A h:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm',\n LLLL: 'dddd, D MMMM YYYY, A h:mm',\n },\n calendar: {\n sameDay: '[དི་རིང] LT',\n nextDay: '[སང་ཉིན] LT',\n nextWeek: '[བདུན་ཕྲག་རྗེས་མ], LT',\n lastDay: '[à½à¼‹à½¦à½„] LT',\n lastWeek: '[བདུན་ཕྲག་མà½à½ ་མ] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s ལ་',\n past: '%s སྔན་ལ',\n s: 'ལམ་སང',\n ss: '%d སà¾à½¢à¼‹à½†à¼',\n m: 'སà¾à½¢à¼‹à½˜à¼‹à½‚ཅིག',\n mm: '%d སà¾à½¢à¼‹à½˜',\n h: 'ཆུ་ཚོད་གཅིག',\n hh: '%d ཆུ་ཚོད',\n d: 'ཉིན་གཅིག',\n dd: '%d ཉིན་',\n M: 'ཟླ་བ་གཅིག',\n MM: '%d ཟླ་བ',\n y: 'ལོ་གཅིག',\n yy: '%d ལོ',\n },\n preparse: function (string) {\n return string.replace(/[༡༢༣༤༥༦༧༨༩༠]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n meridiemParse: /མཚན་མོ|ཞོགས་ཀས|ཉིན་གུང|དགོང་དག|མཚན་མོ/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (\n (meridiem === 'མཚན་མོ' && hour >= 4) ||\n (meridiem === 'ཉིན་གུང' && hour < 5) ||\n meridiem === 'དགོང་དག'\n ) {\n return hour + 12;\n } else {\n return hour;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'མཚན་མོ';\n } else if (hour < 10) {\n return 'ཞོགས་ཀས';\n } else if (hour < 17) {\n return 'ཉིན་གུང';\n } else if (hour < 20) {\n return 'དགོང་དག';\n } else {\n return 'མཚན་མོ';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return bo;\n\n})));\n","//! moment.js locale configuration\n//! locale : Portuguese (Brazil) [pt-br]\n//! author : Caio Ribeiro Pereira : https://github.com/caio-ribeiro-pereira\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ptBr = moment.defineLocale('pt-br', {\n months: 'janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro'.split(\n '_'\n ),\n monthsShort: 'jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez'.split('_'),\n weekdays:\n 'domingo_segunda-feira_terça-feira_quarta-feira_quinta-feira_sexta-feira_sábado'.split(\n '_'\n ),\n weekdaysShort: 'dom_seg_ter_qua_qui_sex_sáb'.split('_'),\n weekdaysMin: 'do_2ª_3ª_4ª_5ª_6ª_sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D [de] MMMM [de] YYYY',\n LLL: 'D [de] MMMM [de] YYYY [à s] HH:mm',\n LLLL: 'dddd, D [de] MMMM [de] YYYY [à s] HH:mm',\n },\n calendar: {\n sameDay: '[Hoje à s] LT',\n nextDay: '[Amanhã à s] LT',\n nextWeek: 'dddd [à s] LT',\n lastDay: '[Ontem à s] LT',\n lastWeek: function () {\n return this.day() === 0 || this.day() === 6\n ? '[Último] dddd [à s] LT' // Saturday + Sunday\n : '[Última] dddd [à s] LT'; // Monday - Friday\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'em %s',\n past: 'há %s',\n s: 'poucos segundos',\n ss: '%d segundos',\n m: 'um minuto',\n mm: '%d minutos',\n h: 'uma hora',\n hh: '%d horas',\n d: 'um dia',\n dd: '%d dias',\n M: 'um mês',\n MM: '%d meses',\n y: 'um ano',\n yy: '%d anos',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n invalidDate: 'Data inválida',\n });\n\n return ptBr;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { Row } from '../models/row';\nimport { isNullOrUndefined, extend, setValue } from '@syncfusion/ej2-base';\nimport { CellType } from '../base/enum';\nimport { RowModelGenerator } from '../services/row-model-generator';\nimport { GroupSummaryModelGenerator, CaptionSummaryModelGenerator } from '../services/summary-model-generator';\nimport { getForeignData, getUid } from '../../grid/base/util';\n/**\n * GroupModelGenerator is used to generate group caption rows and data rows.\n *\n * @hidden\n */\nvar GroupModelGenerator = /** @class */ (function (_super) {\n __extends(GroupModelGenerator, _super);\n function GroupModelGenerator(parent) {\n var _this = _super.call(this, parent) || this;\n _this.rows = [];\n /** @hidden */\n _this.index = 0;\n _this.infiniteChildCount = 0;\n _this.renderInfiniteAgg = true;\n _this.parent = parent;\n _this.summaryModelGen = new GroupSummaryModelGenerator(parent);\n _this.captionModelGen = new CaptionSummaryModelGenerator(parent);\n return _this;\n }\n GroupModelGenerator.prototype.generateRows = function (data, args) {\n if (this.parent.groupSettings.columns.length === 0) {\n return _super.prototype.generateRows.call(this, data, args);\n }\n this.isInfiniteScroll = (args.requestType === 'infiniteScroll');\n this.rows = [];\n this.index = this.parent.enableVirtualization || this.isInfiniteScroll ? args.startIndex : 0;\n for (var i = 0, len = data.length; i < len; i++) {\n this.infiniteChildCount = 0;\n this.renderInfiniteAgg = true;\n this.getGroupedRecords(0, data[parseInt(i.toString(), 10)], data.level, i, undefined, this.rows.length);\n }\n this.index = 0;\n if (this.parent.isCollapseStateEnabled()) {\n this.ensureRowVisibility();\n }\n return this.rows;\n };\n GroupModelGenerator.prototype.getGroupedRecords = function (index, data, raw, parentid, childId, tIndex, parentUid) {\n var _a;\n var level = raw;\n if (isNullOrUndefined(data.items)) {\n if (isNullOrUndefined(data.GroupGuid)) {\n this.rows = this.rows.concat(this.generateDataRows(data, index, parentid, this.rows.length, parentUid));\n }\n else {\n for (var j = 0, len = data.length; j < len; j++) {\n this.getGroupedRecords(index, data[parseInt(j.toString(), 10)], data.level, parentid, index, this.rows.length, parentUid);\n }\n }\n }\n else {\n var preCaption = void 0;\n var captionRow = this.generateCaptionRow(data, index, parentid, childId, tIndex, parentUid);\n if (this.isInfiniteScroll) {\n preCaption = this.getPreCaption(index, captionRow.data.key);\n }\n if (!preCaption) {\n this.rows = this.rows.concat(captionRow);\n }\n else {\n captionRow.uid = preCaption.uid;\n }\n if (data.items && data.items.length) {\n this.getGroupedRecords(index + 1, data.items, data.items.level, parentid, index + 1, this.rows.length, captionRow.uid);\n }\n if (this.parent.aggregates.length && this.isRenderAggregate(captionRow)) {\n var rowCnt = this.rows.length;\n (_a = this.rows).push.apply(_a, this.summaryModelGen.generateRows(data, { level: level, parentUid: captionRow.uid }));\n for (var i = rowCnt - 1; i >= 0; i--) {\n if (this.rows[parseInt(i.toString(), 10)].isCaptionRow) {\n this.rows[parseInt(i.toString(), 10)].aggregatesCount = this.rows.length - rowCnt;\n }\n else if (!this.rows[parseInt(i.toString(), 10)].isCaptionRow && !this.rows[parseInt(i.toString(), 10)].isDataRow) {\n break;\n }\n }\n }\n if (preCaption) {\n this.setInfiniteRowVisibility(preCaption);\n }\n }\n };\n GroupModelGenerator.prototype.isRenderAggregate = function (data) {\n if (this.parent.enableInfiniteScrolling) {\n if (!this.renderInfiniteAgg) {\n return false;\n }\n this.getPreCaption(data.indent, data.data.key);\n this.renderInfiniteAgg = data.data.count === this.infiniteChildCount;\n return this.renderInfiniteAgg;\n }\n return !this.parent.enableInfiniteScrolling;\n };\n GroupModelGenerator.prototype.getPreCaption = function (indent, key) {\n var rowObj = this.parent.getRowsObject().concat(this.rows);\n var preCap;\n this.infiniteChildCount = 0;\n var i = rowObj.length;\n while (i--) {\n if (rowObj[parseInt(i.toString(), 10)].isCaptionRow && rowObj[parseInt(i.toString(), 10)].indent === indent\n && rowObj[parseInt(i.toString(), 10)].data.key === key) {\n preCap = rowObj[parseInt(i.toString(), 10)];\n }\n if (rowObj[parseInt(i.toString(), 10)].indent === indent || rowObj[parseInt(i.toString(), 10)].indent < indent) {\n break;\n }\n if (rowObj[parseInt(i.toString(), 10)].indent === indent + 1) {\n this.infiniteChildCount++;\n }\n }\n return preCap;\n };\n GroupModelGenerator.prototype.getCaptionRowCells = function (field, indent, data) {\n var cells = [];\n var visibles = [];\n var column = this.parent.getColumnByField(field);\n var indexes = this.parent.getColumnIndexesInView();\n if (this.parent.enableColumnVirtualization) {\n column = this.parent.columns.filter(function (c) { return c.field === field; })[0];\n }\n var groupedLen = this.parent.groupSettings.columns.length;\n var gObj = this.parent;\n if (!this.parent.enableColumnVirtualization || indexes.indexOf(indent) !== -1) {\n for (var i = 0; i < indent; i++) {\n cells.push(this.generateIndentCell());\n }\n cells.push(this.generateCell({}, null, CellType.Expand));\n }\n indent = this.parent.enableColumnVirtualization ? 1 :\n (this.parent.getVisibleColumns().length + groupedLen + (gObj.detailTemplate || gObj.childGrid ? 1 : 0) -\n indent + (this.parent.getVisibleColumns().length ? -1 : 0));\n //Captionsummary cells will be added here.\n if (this.parent.aggregates.length && !this.captionModelGen.isEmpty()) {\n var captionCells = this.captionModelGen.generateRows(data)[0];\n extend(data, captionCells.data);\n var cIndex_1 = 0;\n captionCells.cells.some(function (cell, index) { cIndex_1 = index; return cell.visible && cell.isDataCell; });\n visibles = captionCells.cells.slice(cIndex_1).filter(function (cell) { return cell.visible; });\n if (captionCells.visible && visibles[0].column.field === this.parent.getVisibleColumns()[0].field) {\n visibles = visibles.slice(1);\n }\n if (this.parent.getVisibleColumns().length === 1) {\n visibles = [];\n }\n indent = indent - visibles.length;\n }\n var cols = (!this.parent.enableColumnVirtualization ? [column] : this.parent.getColumns());\n var wFlag = true;\n for (var j = 0; j < cols.length; j++) {\n var tmpFlag = wFlag && indexes.indexOf(indent) !== -1;\n if (tmpFlag) {\n wFlag = false;\n }\n var cellType = !this.parent.enableColumnVirtualization || tmpFlag ?\n CellType.GroupCaption : CellType.GroupCaptionEmpty;\n indent = this.parent.enableColumnVirtualization && cellType === CellType.GroupCaption ? indent + groupedLen : indent;\n if (gObj.isRowDragable()) {\n indent++;\n }\n cells.push(this.generateCell(column, null, cellType, indent));\n }\n cells.push.apply(cells, visibles);\n return cells;\n };\n /**\n * @param {GroupedData} data - specifies the data\n * @param {number} indent - specifies the indent\n * @param {number} parentID - specifies the parentID\n * @param {number} childID - specifies the childID\n * @param {number} tIndex - specifies the TIndex\n * @param {string} parentUid - specifies the ParentUid\n * @returns {Row<Column>} returns the Row object\n * @hidden\n */\n GroupModelGenerator.prototype.generateCaptionRow = function (data, indent, parentID, childID, tIndex, parentUid) {\n var options = {};\n var records = 'records';\n var col = this.parent.getColumnByField(data.field);\n options.data = extend({}, data);\n if (col) {\n options.data.field = data.field;\n }\n options.isDataRow = false;\n options.isExpand = !this.parent.groupSettings.enableLazyLoading && !this.parent.isCollapseStateEnabled();\n options.parentGid = parentID;\n options.childGid = childID;\n options.tIndex = tIndex;\n options.isCaptionRow = true;\n options.parentUid = parentUid;\n options.gSummary = !isNullOrUndefined(data.items[\"\" + records]) ? data.items[\"\" + records].length : data.items.length;\n options.uid = getUid('grid-row');\n var row = new Row(options);\n row.indent = indent;\n this.getForeignKeyData(row);\n row.cells = this.getCaptionRowCells(data.field, indent, row.data);\n return row;\n };\n GroupModelGenerator.prototype.getForeignKeyData = function (row) {\n var data = row.data;\n var col = this.parent.getColumnByField(data.field);\n if (col && col.isForeignColumn && col.isForeignColumn()) {\n var fkValue = (isNullOrUndefined(data.key) ? '' : col.valueAccessor(col.foreignKeyValue, getForeignData(col, {}, data.key)[0], col));\n setValue('foreignKey', fkValue, row.data);\n }\n };\n /**\n * @param {Object[]} data - specifies the data\n * @param {number} indent - specifies the indent\n * @param {number} childID - specifies the childID\n * @param {number} tIndex - specifies the tIndex\n * @param {string} parentUid - specifies the ParentUid\n * @returns {Row<Column>[]} returns the row object\n * @hidden\n */\n GroupModelGenerator.prototype.generateDataRows = function (data, indent, childID, tIndex, parentUid) {\n var rows = [];\n var indexes = this.parent.getColumnIndexesInView();\n for (var i = 0, len = data.length; i < len; i++, tIndex++) {\n rows[parseInt(i.toString(), 10)] = this.generateRow(data[parseInt(i.toString(), 10)], this.index, i ? undefined : 'e-firstchildrow', indent, childID, tIndex, parentUid);\n for (var j = 0; j < indent; j++) {\n if (this.parent.enableColumnVirtualization && indexes.indexOf(indent) === -1) {\n continue;\n }\n rows[parseInt(i.toString(), 10)].cells.unshift(this.generateIndentCell());\n }\n this.index++;\n }\n return rows;\n };\n GroupModelGenerator.prototype.generateIndentCell = function () {\n return this.generateCell({}, null, CellType.Indent);\n };\n GroupModelGenerator.prototype.refreshRows = function (input) {\n var indexes = this.parent.getColumnIndexesInView();\n for (var i = 0; i < input.length; i++) {\n if (input[parseInt(i.toString(), 10)].isDataRow) {\n input[parseInt(i.toString(), 10)].cells = this.generateCells(input[parseInt(i.toString(), 10)]);\n for (var j = 0; j < input[parseInt(i.toString(), 10)].indent; j++) {\n if (this.parent.enableColumnVirtualization\n && indexes.indexOf(input[parseInt(i.toString(), 10)].indent) === -1) {\n continue;\n }\n input[parseInt(i.toString(), 10)].cells.unshift(this.generateIndentCell());\n }\n }\n else {\n var cRow = this.generateCaptionRow(input[parseInt(i.toString(), 10)].data, input[parseInt(i.toString(), 10)].indent);\n input[parseInt(i.toString(), 10)].cells = cRow.cells;\n }\n }\n return input;\n };\n GroupModelGenerator.prototype.setInfiniteRowVisibility = function (caption) {\n if (!caption.isExpand || caption.visible === false) {\n for (var _i = 0, _a = this.rows; _i < _a.length; _i++) {\n var row = _a[_i];\n if (row.parentUid === caption.uid) {\n row.visible = false;\n if (row.isCaptionRow) {\n this.setInfiniteRowVisibility(row);\n }\n }\n }\n }\n };\n GroupModelGenerator.prototype.ensureRowVisibility = function () {\n for (var i = 0; i < this.rows.length; i++) {\n var row = this.rows[parseInt(i.toString(), 10)];\n if (!row.isCaptionRow) {\n continue;\n }\n for (var j = i + 1; j < this.rows.length; j++) {\n var childRow = this.rows[parseInt(j.toString(), 10)];\n if (row.uid === childRow.parentUid) {\n this.rows[parseInt(j.toString(), 10)].visible = row.isExpand;\n }\n }\n }\n };\n return GroupModelGenerator;\n}(RowModelGenerator));\nexport { GroupModelGenerator };\n","//! moment.js locale configuration\n//! locale : Filipino [fil]\n//! author : Dan Hagman : https://github.com/hagmandan\n//! author : Matthew Co : https://github.com/matthewdeeco\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var fil = moment.defineLocale('fil', {\n months: 'Enero_Pebrero_Marso_Abril_Mayo_Hunyo_Hulyo_Agosto_Setyembre_Oktubre_Nobyembre_Disyembre'.split(\n '_'\n ),\n monthsShort: 'Ene_Peb_Mar_Abr_May_Hun_Hul_Ago_Set_Okt_Nob_Dis'.split('_'),\n weekdays: 'Linggo_Lunes_Martes_Miyerkules_Huwebes_Biyernes_Sabado'.split(\n '_'\n ),\n weekdaysShort: 'Lin_Lun_Mar_Miy_Huw_Biy_Sab'.split('_'),\n weekdaysMin: 'Li_Lu_Ma_Mi_Hu_Bi_Sab'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'MM/D/YYYY',\n LL: 'MMMM D, YYYY',\n LLL: 'MMMM D, YYYY HH:mm',\n LLLL: 'dddd, MMMM DD, YYYY HH:mm',\n },\n calendar: {\n sameDay: 'LT [ngayong araw]',\n nextDay: '[Bukas ng] LT',\n nextWeek: 'LT [sa susunod na] dddd',\n lastDay: 'LT [kahapon]',\n lastWeek: 'LT [noong nakaraang] dddd',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'sa loob ng %s',\n past: '%s ang nakalipas',\n s: 'ilang segundo',\n ss: '%d segundo',\n m: 'isang minuto',\n mm: '%d minuto',\n h: 'isang oras',\n hh: '%d oras',\n d: 'isang araw',\n dd: '%d araw',\n M: 'isang buwan',\n MM: '%d buwan',\n y: 'isang taon',\n yy: '%d taon',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}/,\n ordinal: function (number) {\n return number;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return fil;\n\n})));\n","//! moment.js locale configuration\n//! locale : Armenian [hy-am]\n//! author : Armendarabyan : https://github.com/armendarabyan\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var hyAm = moment.defineLocale('hy-am', {\n months: {\n format: 'Õ°Õ¸Ö‚Õ¶Õ¾Õ¡Ö€Õ«_ÖƒÕ¥Õ¿Ö€Õ¾Õ¡Ö€Õ«_Õ´Õ¡Ö€Õ¿Õ«_Õ¡ÕºÖ€Õ«Õ¬Õ«_Õ´Õ¡ÕµÕ«Õ½Õ«_Õ°Õ¸Ö‚Õ¶Õ«Õ½Õ«_Õ°Õ¸Ö‚Õ¬Õ«Õ½Õ«_Ö…Õ£Õ¸Õ½Õ¿Õ¸Õ½Õ«_Õ½Õ¥ÕºÕ¿Õ¥Õ´Õ¢Õ¥Ö€Õ«_Õ°Õ¸Õ¯Õ¿Õ¥Õ´Õ¢Õ¥Ö€Õ«_Õ¶Õ¸ÕµÕ¥Õ´Õ¢Õ¥Ö€Õ«_Õ¤Õ¥Õ¯Õ¿Õ¥Õ´Õ¢Õ¥Ö€Õ«'.split(\n '_'\n ),\n standalone:\n 'Õ°Õ¸Ö‚Õ¶Õ¾Õ¡Ö€_ÖƒÕ¥Õ¿Ö€Õ¾Õ¡Ö€_Õ´Õ¡Ö€Õ¿_Õ¡ÕºÖ€Õ«Õ¬_Õ´Õ¡ÕµÕ«Õ½_Õ°Õ¸Ö‚Õ¶Õ«Õ½_Õ°Õ¸Ö‚Õ¬Õ«Õ½_Ö…Õ£Õ¸Õ½Õ¿Õ¸Õ½_Õ½Õ¥ÕºÕ¿Õ¥Õ´Õ¢Õ¥Ö€_Õ°Õ¸Õ¯Õ¿Õ¥Õ´Õ¢Õ¥Ö€_Õ¶Õ¸ÕµÕ¥Õ´Õ¢Õ¥Ö€_Õ¤Õ¥Õ¯Õ¿Õ¥Õ´Õ¢Õ¥Ö€'.split(\n '_'\n ),\n },\n monthsShort: 'Õ°Õ¶Õ¾_ÖƒÕ¿Ö€_Õ´Ö€Õ¿_Õ¡ÕºÖ€_Õ´ÕµÕ½_Õ°Õ¶Õ½_Õ°Õ¬Õ½_Ö…Õ£Õ½_Õ½ÕºÕ¿_Õ°Õ¯Õ¿_Õ¶Õ´Õ¢_Õ¤Õ¯Õ¿'.split('_'),\n weekdays:\n 'Õ¯Õ«Ö€Õ¡Õ¯Õ«_Õ¥Ö€Õ¯Õ¸Ö‚Õ·Õ¡Õ¢Õ©Õ«_Õ¥Ö€Õ¥Ö„Õ·Õ¡Õ¢Õ©Õ«_Õ¹Õ¸Ö€Õ¥Ö„Õ·Õ¡Õ¢Õ©Õ«_Õ°Õ«Õ¶Õ£Õ·Õ¡Õ¢Õ©Õ«_Õ¸Ö‚Ö€Õ¢Õ¡Õ©_Õ·Õ¡Õ¢Õ¡Õ©'.split(\n '_'\n ),\n weekdaysShort: 'Õ¯Ö€Õ¯_Õ¥Ö€Õ¯_Õ¥Ö€Ö„_Õ¹Ö€Ö„_Õ°Õ¶Õ£_Õ¸Ö‚Ö€Õ¢_Õ·Õ¢Õ©'.split('_'),\n weekdaysMin: 'Õ¯Ö€Õ¯_Õ¥Ö€Õ¯_Õ¥Ö€Ö„_Õ¹Ö€Ö„_Õ°Õ¶Õ£_Õ¸Ö‚Ö€Õ¢_Õ·Õ¢Õ©'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D MMMM YYYY Õ©.',\n LLL: 'D MMMM YYYY Õ©., HH:mm',\n LLLL: 'dddd, D MMMM YYYY Õ©., HH:mm',\n },\n calendar: {\n sameDay: '[Õ¡ÕµÕ½Ö…Ö€] LT',\n nextDay: '[Õ¾Õ¡Õ²Õ¨] LT',\n lastDay: '[Õ¥Ö€Õ¥Õ¯] LT',\n nextWeek: function () {\n return 'dddd [Ö…Ö€Õ¨ ÕªÕ¡Õ´Õ¨] LT';\n },\n lastWeek: function () {\n return '[Õ¡Õ¶ÖÕ¡Õ®] dddd [Ö…Ö€Õ¨ ÕªÕ¡Õ´Õ¨] LT';\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s Õ°Õ¥Õ¿Õ¸',\n past: '%s Õ¡Õ¼Õ¡Õ»',\n s: 'Õ´Õ« Ö„Õ¡Õ¶Õ« Õ¾Õ¡ÕµÖ€Õ¯ÕµÕ¡Õ¶',\n ss: '%d Õ¾Õ¡ÕµÖ€Õ¯ÕµÕ¡Õ¶',\n m: 'Ö€Õ¸ÕºÕ¥',\n mm: '%d Ö€Õ¸ÕºÕ¥',\n h: 'ÕªÕ¡Õ´',\n hh: '%d ÕªÕ¡Õ´',\n d: 'Ö…Ö€',\n dd: '%d Ö…Ö€',\n M: 'Õ¡Õ´Õ«Õ½',\n MM: '%d Õ¡Õ´Õ«Õ½',\n y: 'Õ¿Õ¡Ö€Õ«',\n yy: '%d Õ¿Õ¡Ö€Õ«',\n },\n meridiemParse: /Õ£Õ«Õ·Õ¥Ö€Õ¾Õ¡|Õ¡Õ¼Õ¡Õ¾Õ¸Õ¿Õ¾Õ¡|ÖÕ¥Ö€Õ¥Õ¯Õ¾Õ¡|Õ¥Ö€Õ¥Õ¯Õ¸ÕµÕ¡Õ¶/,\n isPM: function (input) {\n return /^(ÖÕ¥Ö€Õ¥Õ¯Õ¾Õ¡|Õ¥Ö€Õ¥Õ¯Õ¸ÕµÕ¡Õ¶)$/.test(input);\n },\n meridiem: function (hour) {\n if (hour < 4) {\n return 'Õ£Õ«Õ·Õ¥Ö€Õ¾Õ¡';\n } else if (hour < 12) {\n return 'Õ¡Õ¼Õ¡Õ¾Õ¸Õ¿Õ¾Õ¡';\n } else if (hour < 17) {\n return 'ÖÕ¥Ö€Õ¥Õ¯Õ¾Õ¡';\n } else {\n return 'Õ¥Ö€Õ¥Õ¯Õ¸ÕµÕ¡Õ¶';\n }\n },\n dayOfMonthOrdinalParse: /\\d{1,2}|\\d{1,2}-(Õ«Õ¶|Ö€Õ¤)/,\n ordinal: function (number, period) {\n switch (period) {\n case 'DDD':\n case 'w':\n case 'W':\n case 'DDDo':\n if (number === 1) {\n return number + '-Õ«Õ¶';\n }\n return number + '-Ö€Õ¤';\n default:\n return number;\n }\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return hyAm;\n\n})));\n","import { Rect } from '@syncfusion/ej2-svg-base';\n/**\n * Specifies Chart Themes\n */\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport var Theme;\n(function (Theme) {\n /** @private */\n Theme.stockEventFont = {\n size: '13px',\n fontWeight: '400',\n color: null,\n fontStyle: 'Normal',\n fontFamily: 'Segoe UI'\n };\n})(Theme || (Theme = {}));\n/** @private */\nexport function getSeriesColor(theme) {\n var palette;\n switch (theme) {\n case 'Fabric':\n palette = ['#4472c4', '#ed7d31', '#ffc000', '#70ad47', '#5b9bd5',\n '#c1c1c1', '#6f6fe2', '#e269ae', '#9e480e', '#997300'];\n break;\n case 'Bootstrap4':\n palette = ['#a16ee5', '#f7ce69', '#55a5c2', '#7ddf1e', '#ff6ea6',\n '#7953ac', '#b99b4f', '#407c92', '#5ea716', '#b91c52'];\n break;\n case 'Bootstrap':\n palette = ['#a16ee5', '#f7ce69', '#55a5c2', '#7ddf1e', '#ff6ea6',\n '#7953ac', '#b99b4f', '#407c92', '#5ea716', '#b91c52'];\n break;\n case 'HighContrastLight':\n case 'HighContrast':\n palette = ['#79ECE4', '#E98272', '#DFE6B6', '#C6E773', '#BA98FF',\n '#FA83C3', '#00C27A', '#43ACEF', '#D681EF', '#D8BC6E'];\n break;\n case 'MaterialDark':\n palette = ['#9ECB08', '#56AEFF', '#C57AFF', '#61EAA9', '#EBBB3E',\n '#F45C5C', '#8A77FF', '#63C7FF', '#FF84B0', '#F7C928'];\n break;\n case 'FabricDark':\n palette = ['#4472c4', '#ed7d31', '#ffc000', '#70ad47', '#5b9bd5',\n '#c1c1c1', '#6f6fe2', '#e269ae', '#9e480e', '#997300'];\n break;\n case 'BootstrapDark':\n palette = ['#a16ee5', '#f7ce69', '#55a5c2', '#7ddf1e', '#ff6ea6',\n '#7953ac', '#b99b4f', '#407c92', '#5ea716', '#b91c52'];\n break;\n case 'Tailwind':\n palette = ['#5A61F6', '#65A30D', '#334155', '#14B8A6', '#8B5CF6',\n '#0369A1', '#F97316', '#9333EA', '#F59E0B', '#15803D'];\n break;\n case 'TailwindDark':\n palette = ['#8B5CF6', '#22D3EE', '#F87171', '#4ADE80', '#E879F9',\n '#FCD34D', '#F97316', '#2DD4BF', '#F472B6', '#10B981'];\n break;\n case 'Bootstrap5':\n palette = ['#6355C7', '#FFB400', '#2196F5', '#F7523F', '#963C70',\n '#4BE0BC', '#FD7400', '#C9E422', '#DE3D8A', '#162F88'];\n break;\n case 'Bootstrap5Dark':\n palette = ['#8F80F4', '#FFD46D', '#6CBDFF', '#FF7F71', '#FF6DB3',\n '#63F5D2', '#FCAA65', '#ECFF77', '#EF8EFF', '#5F82FD'];\n break;\n case 'FluentDark':\n palette = ['#1AC9E6', '#DA4CB2', '#EDBB40', '#AF4BCF', '#FF7266',\n '#1BD565', '#EE993D', '#5887FF', '#EC548D', '#7D39C0'];\n break;\n case 'Fluent':\n palette = ['#1AC9E6', '#DA4CB2', '#EDBB40', '#AF4BCF', '#FF7266',\n '#1BD565', '#EE993D', '#5887FF', '#EC548D', '#7D39C0'];\n break;\n case 'Material3':\n palette = ['#6355C7', '#00AEE0', '#FFB400', '#F7523F', '#963C70',\n '#FD7400', '#4BE0BC', '#2196F5', '#DE3D8A', '#162F88'];\n break;\n case 'Material3Dark':\n palette = ['#4EAAFF', '#FA4EAB', '#FFF500', '#17EA58', '#38FFE7',\n '#FF9E45', '#B3F32F', '#B93CE4', '#FC5664', '#9B55FF'];\n break;\n default:\n palette = ['#00bdae', '#404041', '#357cd2', '#e56590', '#f8b883',\n '#70ad47', '#dd8abd', '#7f84e8', '#7bb4eb', '#ea7a57'];\n break;\n }\n return palette;\n}\n/** @private */\n// tslint:disable-next-line:max-func-body-length\nexport function getThemeColor(theme, canvas) {\n var style;\n var darkBackground = theme === 'MaterialDark' ? '#383838' : (theme === 'FabricDark' ? '#242424' : '#1b1b1b');\n switch (theme) {\n case 'HighContrastLight':\n case 'HighContrast':\n style = {\n axisLabel: '#ffffff',\n axisTitle: '#ffffff',\n axisLine: '#ffffff',\n majorGridLine: '#BFBFBF',\n minorGridLine: '#969696',\n majorTickLine: '#BFBFBF',\n minorTickLine: '#969696',\n chartTitle: '#ffffff',\n legendLabel: '#ffffff',\n background: canvas ? '#000000' : 'transparent',\n areaBorder: '#ffffff',\n errorBar: '#ffffff',\n crosshairLine: '#ffffff',\n crosshairFill: '#ffffff',\n crosshairLabel: '#000000',\n tooltipFill: '#ffffff',\n tooltipBoldLabel: '#000000',\n tooltipLightLabel: '#000000',\n tooltipHeaderLine: '#969696',\n markerShadow: '#BFBFBF',\n selectionRectFill: 'rgba(255, 217, 57, 0.3)',\n selectionRectStroke: '#ffffff',\n selectionCircleStroke: '#FFD939',\n tabColor: '#FFD939',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#FFD939',\n toolkitFill: '#737373',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: '#FFFFFF', fontFamily: 'Segoe UI'\n },\n axisLabelFont: {\n color: '#969696', fontFamily: 'Segoe UI'\n },\n legendTitleFont: {\n color: '#FFFFFF', fontFamily: 'Segoe UI'\n },\n legendLabelFont: {\n color: '#969696', fontFamily: 'Segoe UI'\n },\n tooltipLabelFont: {\n color: '#000000', fontFamily: 'Segoe UI'\n },\n axisTitleFont: {\n color: '#FFFFFF', fontFamily: 'Segoe UI'\n },\n datalabelFont: {\n color: '#969696', fontFamily: 'Segoe UI'\n },\n chartSubTitleFont: {\n color: '#FFFFFF', fontFamily: 'Segoe UI'\n },\n crosshairLabelFont: {\n color: '#000000', fontFamily: 'Segoe UI'\n },\n stripLineLabelFont: {\n color: '#969696', fontFamily: 'Segoe UI'\n }\n };\n break;\n case 'MaterialDark':\n case 'FabricDark':\n case 'BootstrapDark':\n style = {\n axisLabel: '#DADADA', axisTitle: '#ffffff',\n axisLine: ' #6F6C6C',\n majorGridLine: '#414040',\n minorGridLine: '#514F4F',\n majorTickLine: '#414040',\n minorTickLine: ' #4A4848',\n chartTitle: '#ffffff',\n legendLabel: '#DADADA',\n background: canvas ? darkBackground : 'transparent',\n areaBorder: ' #9A9A9A',\n errorBar: '#ffffff',\n crosshairLine: '#F4F4F4',\n crosshairFill: theme === 'MaterialDark' ? '#F4F4F4' : theme === 'FabricDark' ? '#A19F9D' : '#F0F0F0',\n crosshairLabel: '#282727',\n tooltipFill: '#F4F4F4',\n tooltipBoldLabel: '#282727',\n tooltipLightLabel: '#333232',\n tooltipHeaderLine: '#9A9A9A',\n markerShadow: null,\n selectionRectFill: 'rgba(56,169,255, 0.1)',\n selectionRectStroke: '#38A9FF',\n selectionCircleStroke: '#282727',\n tabColor: theme === 'MaterialDark' ? '#00B0FF' : theme === 'FabricDark' ? '#0074CC' : '#0070F0',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: theme === 'MaterialDark' ? '#00B0FF' : theme === 'FabricDark' ? '#0074CC' : '#0070F0',\n toolkitFill: '#737373',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.87)' : theme === 'FabricDark' ? '#DADADA' : '#FFFFFF', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n axisLabelFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.6)' : theme === 'FabricDark' ? '#A19F9D' : '#CED4DA', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n legendTitleFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.87)' : theme === 'FabricDark' ? '#DADADA' : '#FFFFFF', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n legendLabelFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.6)' : theme === 'FabricDark' ? '#A19F9D' : '#676767', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n tooltipLabelFont: {\n color: theme === 'MaterialDark' ? 'rgba(18, 18, 18, 1)' : theme === 'FabricDark' ? '#DADADA' : '#1A1A1A', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n axisTitleFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.87)' : theme === 'FabricDark' ? '#DADADA' : '#FFFFFF', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n datalabelFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.6)' : theme === 'FabricDark' ? '#A19F9D' : '#676767', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n chartSubTitleFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.87)' : theme === 'FabricDark' ? '#DADADA' : '#FFFFFF', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n crosshairLabelFont: {\n color: theme === 'MaterialDark' ? 'rgba(18, 18, 18, 1)' : theme === 'FabricDark' ? '#DADADA' : '#1A1A1A', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n },\n stripLineLabelFont: {\n color: theme === 'MaterialDark' ? 'rgba(255, 255, 255, 0.24)' : theme === 'FabricDark' ? '#6F6C6C' : '#414141', fontFamily: theme === 'MaterialDark' ? 'Roboto' : theme === 'FabricDark' ? 'Segoe UI' : 'Helvetica'\n }\n };\n break;\n case 'Bootstrap4':\n style = {\n axisLabel: '#212529', axisTitle: '#212529', axisLine: '#CED4DA', majorGridLine: '#CED4DA',\n minorGridLine: '#DEE2E6', majorTickLine: '#ADB5BD', minorTickLine: '#CED4DA', chartTitle: '#212529', legendLabel: '#212529',\n background: canvas ? '#FFFFFF' : 'transparent', areaBorder: '#DEE2E6', errorBar: '#000000', crosshairLine: '#6C757D', crosshairFill: '#212529',\n crosshairLabel: '#FFFFFF', tooltipFill: '#020202', tooltipBoldLabel: 'rgba(255,255,255)',\n tooltipLightLabel: 'rgba(255,255,255, 0.9)', tooltipHeaderLine: 'rgba(255,255,255, 0.2)', markerShadow: null,\n selectionRectFill: 'rgba(255,255,255, 0.1)', selectionRectStroke: 'rgba(0, 123, 255)', selectionCircleStroke: '#495057', tabColor: '#007BFF', bearFillColor: '#2ecd71', bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#007BFF',\n toolkitFill: '#495057',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(-5, -5, 26, 26),\n chartTitleFont: {\n color: '#212529', fontFamily: 'Helvetica'\n },\n axisLabelFont: {\n color: '#495057', fontFamily: 'Helvetica'\n },\n legendTitleFont: {\n color: '#212529', fontFamily: 'Helvetica'\n },\n legendLabelFont: {\n color: '#666666', fontFamily: 'Helvetica'\n },\n tooltipLabelFont: {\n color: '#F9FAFB', fontFamily: 'Helvetica'\n },\n axisTitleFont: {\n color: '#212529', fontFamily: 'Helvetica'\n },\n datalabelFont: {\n color: '#495057', fontFamily: 'Helvetica'\n },\n chartSubTitleFont: {\n color: '#212529', fontFamily: 'Helvetica'\n },\n crosshairLabelFont: {\n color: '#F9FAFB', fontFamily: 'Helvetica'\n },\n stripLineLabelFont: {\n color: '#6C757D', fontFamily: 'Helvetica'\n }\n };\n break;\n case 'Tailwind':\n style = {\n axisLabel: '#6B728', axisTitle: '#374151',\n axisLine: ' #D1D5DB',\n majorGridLine: '#E5E7EB',\n minorGridLine: '#E5E7EB',\n majorTickLine: '#D1D5DB',\n minorTickLine: ' #D1D5DB',\n chartTitle: '#374151',\n legendLabel: '#374151',\n background: canvas ? 'rgba(255,255,255, 0.0)' : 'transparent',\n areaBorder: ' #E5E7EB',\n errorBar: '#374151',\n crosshairLine: '#1F2937',\n crosshairFill: '#111827',\n crosshairLabel: '#F9FAFB',\n tooltipFill: '#111827',\n tooltipBoldLabel: '#D1D5DB',\n tooltipLightLabel: '#F9FAFB',\n tooltipHeaderLine: '#6B7280',\n markerShadow: null,\n selectionRectFill: 'rgba(79,70,229, 0.1)',\n selectionRectStroke: '#4F46E5',\n selectionCircleStroke: '#6B7280',\n tabColor: '#4F46E5',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#4F46E5',\n toolkitFill: '#6B7280',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: '#374151', fontFamily: 'Inter'\n },\n axisLabelFont: {\n color: '#6B7280', fontFamily: 'Inter'\n },\n legendTitleFont: {\n color: '#374151', fontFamily: 'Inter'\n },\n legendLabelFont: {\n color: '#374151', fontFamily: 'Inter'\n },\n tooltipLabelFont: {\n color: '#F9FAFB', fontFamily: 'Inter'\n },\n axisTitleFont: {\n color: '#374151', fontFamily: 'Inter'\n },\n datalabelFont: {\n color: '#6B7280', fontFamily: 'Inter'\n },\n chartSubTitleFont: {\n color: '#374151', fontFamily: 'Inter'\n },\n crosshairLabelFont: {\n color: '#F9FAFB', fontFamily: 'Inter'\n },\n stripLineLabelFont: {\n color: '#D1D5DB', fontFamily: 'Inter'\n }\n };\n break;\n case 'TailwindDark':\n style = {\n axisLabel: '#9CA3AF', axisTitle: '#9CA3AF',\n axisLine: ' #4B5563',\n majorGridLine: '#374151',\n minorGridLine: '#374151',\n majorTickLine: '#4B5563',\n minorTickLine: ' #4B5563',\n chartTitle: '#D1D5DB',\n legendLabel: '#D1D5DB',\n background: canvas ? '#1f2937' : 'transparent',\n areaBorder: ' #374151',\n errorBar: '#ffffff',\n crosshairLine: '#9CA3AF',\n crosshairFill: '#F9FAFB',\n crosshairLabel: '#1F2937',\n tooltipFill: '#F9FAFB',\n tooltipBoldLabel: '#6B7280',\n tooltipLightLabel: '#1F2937',\n tooltipHeaderLine: '#9CA3AF',\n markerShadow: null,\n selectionRectFill: 'rgba(34,211,238, 0.1)',\n selectionRectStroke: '#22D3EE',\n selectionCircleStroke: '#282727',\n tabColor: '#22D3EE',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#22D3EE',\n toolkitFill: '#D1D5DB',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: '#D1D5DB', fontFamily: 'Inter'\n },\n axisLabelFont: {\n color: '#9CA3AF', fontFamily: 'Inter'\n },\n legendTitleFont: {\n color: '#D1D5DB', fontFamily: 'Inter'\n },\n legendLabelFont: {\n color: '#D1D5DB', fontFamily: 'Inter'\n },\n tooltipLabelFont: {\n color: '#1F2937', fontFamily: 'Inter'\n },\n axisTitleFont: {\n color: '#D1D5DB', fontFamily: 'Inter'\n },\n datalabelFont: {\n color: '#9CA3AF', fontFamily: 'Inter'\n },\n chartSubTitleFont: {\n color: '#D1D5DB', fontFamily: 'Inter'\n },\n crosshairLabelFont: {\n color: '#1F2937', fontFamily: 'Inter'\n },\n stripLineLabelFont: {\n color: '#6B7280', fontFamily: 'Inter'\n }\n };\n break;\n case 'Bootstrap5':\n style = {\n axisLabel: '#495057',\n axisTitle: '#343A40',\n axisLine: '#D1D5DB',\n majorGridLine: '#E5E7EB',\n minorGridLine: '#E5E7EB',\n majorTickLine: '#D1D5DB',\n minorTickLine: ' #D1D5DB',\n chartTitle: '#343A40',\n legendLabel: '#343A40',\n background: canvas ? '#FFFFFF' : 'transparent',\n areaBorder: ' #DEE2E6',\n errorBar: '#1F2937',\n crosshairLine: '#1F2937',\n crosshairFill: '#212529',\n crosshairLabel: '#F9FAFB',\n tooltipFill: '#212529',\n tooltipBoldLabel: '#F9FAFB',\n tooltipLightLabel: '#F9FAFB',\n tooltipHeaderLine: '#9CA3AF',\n markerShadow: null,\n selectionRectFill: 'rgba(79,70,229, 0.1)',\n selectionRectStroke: '#4F46E5',\n selectionCircleStroke: '#6B7280',\n tabColor: '#0D6EFD',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#0D6EFD',\n toolkitFill: '#737373',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: '#343A40', fontFamily: 'Helvetica'\n },\n axisLabelFont: {\n color: '#495057', fontFamily: 'Helvetica'\n },\n legendTitleFont: {\n color: '#343A40', fontFamily: 'Helvetica'\n },\n legendLabelFont: {\n color: '#343A40', fontFamily: 'Helvetica'\n },\n tooltipLabelFont: {\n color: '#F9FAFB', fontFamily: 'Helvetica'\n },\n axisTitleFont: {\n color: '#343A40', fontFamily: 'Helvetica'\n },\n datalabelFont: {\n color: '#495057', fontFamily: 'Helvetica'\n },\n chartSubTitleFont: {\n color: '#343A40', fontFamily: 'Helvetica'\n },\n crosshairLabelFont: {\n color: '#F9FAFB', fontFamily: 'Helvetica'\n },\n stripLineLabelFont: {\n color: '#ADB5BD', fontFamily: 'Helvetica'\n }\n };\n break;\n case 'Bootstrap5Dark':\n style = {\n axisLabel: '#CED4DA',\n axisTitle: '#E9ECEF',\n axisLine: '#495057',\n majorGridLine: '#343A40',\n minorGridLine: '#343A40',\n majorTickLine: '#495057',\n minorTickLine: ' #495057',\n chartTitle: '#E9ECEF',\n legendLabel: '#E9ECEF',\n background: canvas ? '#212529' : 'transparent',\n areaBorder: ' #444C54',\n errorBar: '#ADB5BD',\n crosshairLine: '#ADB5BD',\n crosshairFill: '#E9ECEF',\n crosshairLabel: '#212529',\n tooltipFill: '#E9ECEF',\n tooltipBoldLabel: '#212529',\n tooltipLightLabel: '#212529',\n tooltipHeaderLine: '#ADB5BD',\n markerShadow: null,\n selectionRectFill: 'rgba(79,70,229, 0.1)',\n selectionRectStroke: '#4F46E5',\n selectionCircleStroke: '#6B7280',\n tabColor: '#0D6EFD',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#0D6EFD',\n toolkitFill: '#737373',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: '#E9ECEF', fontFamily: 'Helvetica'\n },\n axisLabelFont: {\n color: '#CED4DA', fontFamily: 'Helvetica'\n },\n legendTitleFont: {\n color: '#E9ECEF', fontFamily: 'Helvetica'\n },\n legendLabelFont: {\n color: '#E9ECEF', fontFamily: 'Helvetica'\n },\n tooltipLabelFont: {\n color: '#212529', fontFamily: 'Helvetica'\n },\n axisTitleFont: {\n color: '#E9ECEF', fontFamily: 'Helvetica'\n },\n datalabelFont: {\n color: '#E9ECEF', fontFamily: 'Helvetica'\n },\n chartSubTitleFont: {\n color: '#E9ECEF', fontFamily: 'Helvetica'\n },\n crosshairLabelFont: {\n color: '#212529', fontFamily: 'Helvetica'\n },\n stripLineLabelFont: {\n color: '#6C757D', fontFamily: 'Helvetica'\n }\n };\n break;\n case 'Fluent':\n style = {\n axisLabel: '#3B3A39',\n axisTitle: '#201F1E',\n axisLine: '#D2D0CE',\n majorGridLine: '#EDEBE9',\n minorGridLine: '#EDEBE9',\n majorTickLine: '#D2D0CE',\n minorTickLine: ' #D2D0CE',\n chartTitle: '#201F1E',\n legendLabel: '#323130',\n background: canvas ? '#FFFFFF' : 'transparent',\n areaBorder: '#EDEBE9',\n errorBar: '#A19F9D',\n crosshairLine: '#A19F9D',\n crosshairFill: '#FFFFFF',\n crosshairLabel: '#323130',\n tooltipFill: '#FFFFFF',\n tooltipBoldLabel: '#323130',\n tooltipLightLabel: '#323130',\n tooltipHeaderLine: '#D2D0CE',\n markerShadow: null,\n selectionRectFill: 'rgba(79,70,229, 0.1)',\n selectionRectStroke: '#4F46E5',\n selectionCircleStroke: '#6B7280',\n tabColor: '#0078D4',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#0078D4',\n toolkitFill: '#A19F9D',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: '#201F1E', fontFamily: 'Segoe UI'\n },\n axisLabelFont: {\n color: '#3B3A39', fontFamily: 'Segoe UI'\n },\n legendTitleFont: {\n color: '#201F1E', fontFamily: 'Segoe UI'\n },\n legendLabelFont: {\n color: '#49454E', fontFamily: 'Segoe UI'\n },\n tooltipLabelFont: {\n color: '#323130', fontFamily: 'Segoe UI'\n },\n axisTitleFont: {\n color: '#201F1E', fontFamily: 'Segoe UI'\n },\n datalabelFont: {\n color: '#3B3A39', fontFamily: 'Segoe UI'\n },\n chartSubTitleFont: {\n color: '#323129', fontFamily: 'Segoe UI'\n },\n crosshairLabelFont: {\n color: '#323130', fontFamily: 'Segoe UI'\n },\n stripLineLabelFont: {\n color: '#A19F9D', fontFamily: 'Segoe UI'\n }\n };\n break;\n case 'FluentDark':\n style = {\n axisLabel: '#C8C6C4',\n axisTitle: '#F3F2F1',\n axisLine: '#3B3A39',\n majorGridLine: '#414040',\n minorGridLine: '#414040',\n majorTickLine: '#3B3A39',\n minorTickLine: '#3B3A39',\n chartTitle: '#F3F2F1',\n legendLabel: '#D2D0CE',\n background: canvas ? '#383838' : 'transparent',\n areaBorder: '#414040',\n errorBar: '#D2D0CE',\n crosshairLine: '#D2D0CE',\n crosshairFill: '#323130',\n crosshairLabel: '#F3F2F1',\n tooltipFill: '#252423',\n tooltipBoldLabel: '#F3F2F1',\n tooltipLightLabel: '#F3F2F1',\n tooltipHeaderLine: '#3B3A39',\n markerShadow: null,\n selectionRectFill: 'rgba(79,70,229, 0.1)',\n selectionRectStroke: '#4F46E5',\n selectionCircleStroke: '#6B7280',\n tabColor: '#0078D4',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: '#0078D4',\n toolkitFill: '#484644',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: '#C8C6C4', fontFamily: 'Segoe UI'\n },\n axisLabelFont: {\n color: '#C8C6C4', fontFamily: 'Segoe UI'\n },\n legendTitleFont: {\n color: '#F3F2F1', fontFamily: 'Segoe UI'\n },\n legendLabelFont: {\n color: '#D2D0CE', fontFamily: 'Segoe UI'\n },\n tooltipLabelFont: {\n color: '#F3F2F1', fontFamily: 'Segoe UI'\n },\n axisTitleFont: {\n color: '#F3F2F2', fontFamily: 'Segoe UI'\n },\n datalabelFont: {\n color: '#D2D0CE', fontFamily: 'Segoe UI'\n },\n chartSubTitleFont: {\n color: '#F3F2F1', fontFamily: 'Segoe UI'\n },\n crosshairLabelFont: {\n color: '#F3F2F1', fontFamily: 'Segoe UI'\n },\n stripLineLabelFont: {\n color: '#484644', fontFamily: 'Segoe UI'\n }\n };\n break;\n case 'Material3':\n style = {\n axisLabel: '#1E192B',\n axisTitle: '#1C1B1F',\n axisLine: '#C4C7C5',\n majorGridLine: '#C4C7C5',\n minorGridLine: '#C4C7C5',\n majorTickLine: '#C4C7C5',\n minorTickLine: ' #C4C7C5',\n chartTitle: '#1C1B1F',\n legendLabel: '#49454E',\n background: canvas ? '#FFFFFF' : 'transparent',\n areaBorder: '#E7E0EC',\n errorBar: '#79747E',\n crosshairLine: '#49454E',\n crosshairFill: '#313033',\n crosshairLabel: '#F4EFF4',\n tooltipFill: '#313033',\n tooltipBoldLabel: '#F4EFF4',\n tooltipLightLabel: '#F4EFF4',\n tooltipHeaderLine: '#F4EFF4',\n markerShadow: null,\n selectionRectFill: 'rgb(98, 0, 238, 0.06)',\n selectionRectStroke: '#6200EE',\n selectionCircleStroke: '#79747E',\n tabColor: '#49454E',\n bearFillColor: '#5887FF',\n bullFillColor: '#F7523F',\n toolkitSelectionColor: '#49454E',\n toolkitFill: '#49454E',\n toolkitIconRectOverFill: '#EADDFF',\n toolkitIconRectSelectionFill: '#EADDFF',\n toolkitIconRect: new Rect(-4, -5, 26, 26),\n histogram: '#D21020',\n chartTitleFont: {\n color: '#1C1B1F', fontFamily: 'Roboto'\n },\n axisLabelFont: {\n color: '#1E192B', fontFamily: 'Roboto'\n },\n legendTitleFont: {\n color: '#1C1B1F', fontFamily: 'Roboto'\n },\n legendLabelFont: {\n color: '#49454E', fontFamily: 'Roboto'\n },\n tooltipLabelFont: {\n color: '#F4EFF4', fontFamily: 'Roboto'\n },\n axisTitleFont: {\n color: '#1C1B1F', fontFamily: 'Roboto'\n },\n datalabelFont: {\n color: '#49454E', fontFamily: 'Roboto'\n },\n chartSubTitleFont: {\n color: '#49454E', fontFamily: 'Roboto'\n },\n crosshairLabelFont: {\n color: '#F4EFF4', fontFamily: 'Roboto'\n },\n stripLineLabelFont: {\n color: '#79747E', fontFamily: 'Roboto'\n }\n };\n break;\n case 'Material3Dark':\n style = {\n axisLabel: '#E6E1E5',\n axisTitle: '#E6E1E5',\n axisLine: '#49454F',\n majorGridLine: '#444746',\n minorGridLine: '#444746',\n majorTickLine: '#444746',\n minorTickLine: ' #444746',\n chartTitle: '#E6E1E5',\n legendLabel: '#CAC4D0',\n background: canvas ? '#FFFFFF' : 'transparent',\n areaBorder: '#49454F',\n errorBar: '#938F99',\n crosshairLine: '#CAC4D0',\n crosshairFill: '#E6E1E5',\n crosshairLabel: '#313033',\n tooltipFill: '#E6E1E5',\n tooltipBoldLabel: '#313033',\n tooltipLightLabel: '#313033',\n tooltipHeaderLine: '#313033',\n markerShadow: null,\n selectionRectFill: 'rgba(78, 170, 255, 0.06)',\n selectionRectStroke: '#4EAAFF',\n selectionCircleStroke: '#938F99',\n tabColor: '#CAC4D0',\n bearFillColor: '#B3F32F',\n bullFillColor: '#FF9E45',\n toolkitSelectionColor: '#CAC4D0',\n toolkitFill: '#CAC4D0',\n toolkitIconRectOverFill: '#4F378B',\n toolkitIconRectSelectionFill: '#4F378B',\n toolkitIconRect: new Rect(-4, -5, 26, 26),\n histogram: '#FF9E45',\n chartTitleFont: {\n color: '#E6E1E5', fontFamily: 'Roboto'\n },\n axisLabelFont: {\n color: '#CAC4D0', fontFamily: 'Roboto'\n },\n legendTitleFont: {\n color: '#E6E1E5', fontFamily: 'Roboto'\n },\n legendLabelFont: {\n color: '#CAC4D0', fontFamily: 'Roboto'\n },\n tooltipLabelFont: {\n color: '#313033', fontFamily: 'Roboto'\n },\n axisTitleFont: {\n color: '#E6E1E5', fontFamily: 'Roboto'\n },\n datalabelFont: {\n color: '#CAC4D0', fontFamily: 'Roboto'\n },\n chartSubTitleFont: {\n color: '#CAC4D0', fontFamily: 'Roboto'\n },\n crosshairLabelFont: {\n color: '#313033', fontFamily: 'Roboto'\n },\n stripLineLabelFont: {\n color: '#938F99', fontFamily: 'Roboto'\n }\n };\n break;\n default:\n style = {\n axisLabel: '#686868',\n axisTitle: '#424242',\n axisLine: '#b5b5b5',\n majorGridLine: '#dbdbdb',\n minorGridLine: '#eaeaea',\n majorTickLine: '#b5b5b5',\n minorTickLine: '#d6d6d6',\n chartTitle: '#424242',\n legendLabel: '#353535',\n background: canvas ? '#FFFFFF' : 'transparent',\n areaBorder: 'Gray',\n errorBar: '#000000',\n crosshairLine: '#4f4f4f',\n crosshairFill: theme === 'Material' ? '#000816' : theme === 'Fabric' ? '#FFFFFF' : '#212529',\n crosshairLabel: '#e5e5e5',\n tooltipFill: '#000816',\n tooltipBoldLabel: '#ffffff',\n tooltipLightLabel: '#dbdbdb',\n tooltipHeaderLine: '#ffffff',\n markerShadow: null,\n selectionRectFill: 'rgba(41, 171, 226, 0.1)',\n selectionRectStroke: '#29abe2',\n selectionCircleStroke: '#29abe2',\n tabColor: theme === 'Material' ? '#ff4081' : theme === 'Fabric' ? '#0078D6' : '#317AB9',\n bearFillColor: '#2ecd71',\n bullFillColor: '#e74c3d',\n toolkitSelectionColor: theme === 'Material' ? '#ff4081' : theme === 'Fabric' ? '#0078D6' : '#317AB9',\n toolkitFill: '#737373',\n toolkitIconRectOverFill: 'transparent',\n toolkitIconRectSelectionFill: 'transparent',\n toolkitIconRect: new Rect(0, 0, 16, 16),\n chartTitleFont: {\n color: theme === 'Material' ? 'rgba(0, 0, 0, 1)' : theme === 'Fabric' ? '#333333' : '#212529', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n axisLabelFont: {\n color: theme === 'Material' ? 'rgba(97, 97, 97, 1)' : theme === 'Fabric' ? '#666666' : '#676767', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n legendTitleFont: {\n color: theme === 'Material' ? 'rgba(0, 0, 0, 1)' : theme === 'Fabric' ? '#333333' : '#212529', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n legendLabelFont: {\n color: theme === 'Material' ? 'rgba(97, 97, 97, 1)' : theme === 'Fabric' ? '#666666' : '#666666', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n tooltipLabelFont: {\n color: theme === 'Material' ? 'rgba(249, 250, 251, 1)' : theme === 'Fabric' ? '#333333' : '#F9FAFB', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n axisTitleFont: {\n color: theme === 'Material' ? 'rgba(0, 0, 0, 1)' : theme === 'Fabric' ? '#333333' : '#212529', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n datalabelFont: {\n color: theme === 'Material' ? 'rgba(97, 97, 97, 1)' : theme === 'Fabric' ? '#666666' : '#676767', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n chartSubTitleFont: {\n color: theme === 'Material' ? 'rgba(0, 0, 0, 1)' : theme === 'Fabric' ? '#333333' : '#212529', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n crosshairLabelFont: {\n color: theme === 'Material' ? 'rgba(249, 250, 251, 1)' : theme === 'Fabric' ? '#333333' : '#F9FAFB', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n },\n stripLineLabelFont: {\n color: theme === 'Material' ? 'rgba(158, 158, 158, 1)' : theme === 'Fabric' ? '#A6A6A6' : '#676767', fontFamily: theme === 'Material' ? 'Roboto' : theme === 'Fabric' ? 'Segoe UI' : 'Helvetica'\n }\n };\n break;\n }\n return style;\n}\n/** @private */\nexport function getScrollbarThemeColor(theme) {\n var scrollStyle;\n switch (theme) {\n case 'HighContrastLight':\n scrollStyle = {\n backRect: '#333',\n thumb: '#bfbfbf',\n circle: '#fff',\n circleHover: '#685708',\n arrow: '#333',\n grip: '#333',\n arrowHover: '#fff',\n backRectBorder: '#969696'\n };\n break;\n case 'Bootstrap':\n scrollStyle = {\n backRect: '#f5f5f5',\n thumb: '#e6e6e6',\n circle: '#fff',\n circleHover: '#eee',\n arrow: '#8c8c8c',\n grip: '#8c8c8c'\n };\n break;\n case 'Fabric':\n scrollStyle = {\n backRect: '#f8f8f8',\n thumb: '#eaeaea',\n circle: '#fff',\n circleHover: '#eaeaea',\n arrow: '#a6a6a6',\n grip: '#a6a6a6'\n };\n break;\n case 'MaterialDark':\n scrollStyle = {\n backRect: '#424242',\n thumb: '#616161',\n circle: '#757575',\n circleHover: '#616161',\n arrow: '#BDBDBD',\n grip: '#BDBDBD'\n };\n break;\n case 'FabricDark':\n scrollStyle = {\n backRect: '#282727',\n thumb: '#333232',\n circle: '#4A4848',\n circleHover: '#514F4F',\n arrow: '#ADB5BD',\n grip: '#DADADA'\n };\n break;\n case 'BootstrapDark':\n scrollStyle = {\n backRect: '#2A2A2A',\n thumb: '#313131',\n circle: '#414141',\n circleHover: '#484848',\n arrow: '#DADADA',\n grip: '#FFFFFF'\n };\n break;\n case 'Bootstrap5Dark':\n scrollStyle = {\n backRect: '#282D31',\n thumb: '#3B4248',\n circle: '#495057',\n circleHover: '#6C757D',\n arrow: '#A19F9D',\n grip: '#ADB5BD'\n };\n break;\n case 'HighContrast':\n scrollStyle = {\n backRect: '#757575',\n thumb: '#BFBFBF',\n circle: '#FFFFFF',\n circleHover: '#FFFFFF',\n arrow: '#ADB5BD',\n grip: '#969696'\n };\n break;\n case 'TailwindDark':\n scrollStyle = {\n backRect: '#6B7280',\n thumb: '#374151',\n circle: '#4B5563',\n circleHover: '#4B5563',\n arrow: '#ADB5BD',\n grip: '#D1D5DB'\n };\n break;\n case 'Fluent':\n scrollStyle = {\n backRect: '#F3F2F1',\n thumb: '#E1DFDD',\n circle: '#FFFFFF',\n circleHover: '#E1DFDD',\n arrow: '#605E5C',\n grip: '#605E5C'\n };\n break;\n case 'FluentDark':\n scrollStyle = {\n backRect: '#252423',\n thumb: '#323130',\n circle: '#3B3A39',\n circleHover: '#3B3A39',\n arrow: '#ADB5BD',\n grip: '#A19F9D'\n };\n break;\n case 'Material3':\n scrollStyle = {\n backRect: 'rgba(103, 80, 164, 0.05)',\n thumb: ' rgba(103, 80, 164, 0.14)',\n circle: '#FFFFFF',\n circleHover: '#E1DFDD',\n arrow: '#49454E',\n grip: '#49454E'\n };\n break;\n case 'Material3Dark':\n scrollStyle = {\n backRect: 'rgba(208, 188, 255, 0.05)',\n thumb: 'rgba(208, 188, 255, 0.14)',\n circle: '#FFFFFF',\n circleHover: '#E1DFDD',\n arrow: '#CAC4D0',\n grip: '#CAC4D0'\n };\n break;\n default:\n scrollStyle = {\n backRect: '#f5f5f5',\n thumb: '#e0e0e0',\n circle: '#fff',\n circleHover: '#eee',\n arrow: '#9e9e9e',\n grip: '#9e9e9e'\n };\n break;\n }\n return scrollStyle;\n}\n","//! moment.js locale configuration\n//! locale : Catalan [ca]\n//! author : Juan G. Hurtado : https://github.com/juanghurtado\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ca = moment.defineLocale('ca', {\n months: {\n standalone:\n 'gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre'.split(\n '_'\n ),\n format: \"de gener_de febrer_de març_d'abril_de maig_de juny_de juliol_d'agost_de setembre_d'octubre_de novembre_de desembre\".split(\n '_'\n ),\n isFormat: /D[oD]?(\\s)+MMMM/,\n },\n monthsShort:\n 'gen._febr._març_abr._maig_juny_jul._ag._set._oct._nov._des.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays:\n 'diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte'.split(\n '_'\n ),\n weekdaysShort: 'dg._dl._dt._dc._dj._dv._ds.'.split('_'),\n weekdaysMin: 'dg_dl_dt_dc_dj_dv_ds'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM [de] YYYY',\n ll: 'D MMM YYYY',\n LLL: 'D MMMM [de] YYYY [a les] H:mm',\n lll: 'D MMM YYYY, H:mm',\n LLLL: 'dddd D MMMM [de] YYYY [a les] H:mm',\n llll: 'ddd D MMM YYYY, H:mm',\n },\n calendar: {\n sameDay: function () {\n return '[avui a ' + (this.hours() !== 1 ? 'les' : 'la') + '] LT';\n },\n nextDay: function () {\n return '[demà a ' + (this.hours() !== 1 ? 'les' : 'la') + '] LT';\n },\n nextWeek: function () {\n return 'dddd [a ' + (this.hours() !== 1 ? 'les' : 'la') + '] LT';\n },\n lastDay: function () {\n return '[ahir a ' + (this.hours() !== 1 ? 'les' : 'la') + '] LT';\n },\n lastWeek: function () {\n return (\n '[el] dddd [passat a ' +\n (this.hours() !== 1 ? 'les' : 'la') +\n '] LT'\n );\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: \"d'aquà %s\",\n past: 'fa %s',\n s: 'uns segons',\n ss: '%d segons',\n m: 'un minut',\n mm: '%d minuts',\n h: 'una hora',\n hh: '%d hores',\n d: 'un dia',\n dd: '%d dies',\n M: 'un mes',\n MM: '%d mesos',\n y: 'un any',\n yy: '%d anys',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(r|n|t|è|a)/,\n ordinal: function (number, period) {\n var output =\n number === 1\n ? 'r'\n : number === 2\n ? 'n'\n : number === 3\n ? 'r'\n : number === 4\n ? 't'\n : 'è';\n if (period === 'w' || period === 'W') {\n output = 'a';\n }\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return ca;\n\n})));\n","import { ChildProperty, compile as baseTemplateComplier, setValue, Internationalization, isUndefined } from '@syncfusion/ej2-base';\nimport { extend as baseExtend, isNullOrUndefined, getValue, classList } from '@syncfusion/ej2-base';\nimport { setStyleAttribute, addClass, attributes, remove, createElement, removeClass } from '@syncfusion/ej2-base';\nimport { isObject, select, selectAll } from '@syncfusion/ej2-base';\nimport { DataUtil, Query, DataManager, Predicate, UrlAdaptor, Deferred } from '@syncfusion/ej2-data';\nimport { Column } from '../models/column';\nimport { calculateRelativeBasedPosition } from '@syncfusion/ej2-popups';\nimport { Print } from '../actions/print';\nimport { CheckBoxFilterBase } from '../common/checkbox-filter-base';\nimport * as literals from '../base/string-literals';\n//https://typescript.codeplex.com/discussions/401501\n/**\n * Function to check whether target object implement specific interface\n *\n * @param {Object} target - specifies the target\n * @param {string} checkFor - specifies the checkfors\n * @returns {boolean} returns the boolean\n * @hidden\n */\nexport function doesImplementInterface(target, checkFor) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n return target.prototype && checkFor in target.prototype;\n}\n/**\n * Function to get value from provided data\n *\n * @param {string} field - specifies the field\n * @param {Object} data - specifies the data\n * @param {ColumnModel} column - specifies the column\n * @returns {Object} returns the object\n * @hidden\n */\n// eslint-disable-next-line\nexport function valueAccessor(field, data, column) {\n return (isNullOrUndefined(field) || field === '') ? '' : DataUtil.getObject(field, data);\n}\n/**\n * Defines the method used to apply custom header cell values from external function and display this on each header cell rendered.\n *\n * @param {string} field - specifies the field\n * @param {ColumnModel} column - specifies the column\n * @returns {object} headerValueAccessor\n * @hidden\n */\nexport function headerValueAccessor(field, column) {\n return (isNullOrUndefined(field) || field === '') ? '' : DataUtil.getObject(field, column);\n}\n/**\n * The function used to update Dom using requestAnimationFrame.\n *\n * @param {Function} updateFunction - Function that contains the actual action\n * @param {object} callBack - defines the callback\n * @returns {void}\n * @hidden\n */\n// eslint-disable-next-line\nexport function getUpdateUsingRaf(updateFunction, callBack) {\n requestAnimationFrame(function () {\n try {\n callBack(null, updateFunction());\n }\n catch (e) {\n callBack(e);\n }\n });\n}\n/**\n * @hidden\n * @param {PdfExportProperties | ExcelExportProperties} exportProperties - Defines the export properties\n * @returns {boolean} Returns isExportColumns\n */\nexport function isExportColumns(exportProperties) {\n return !isNullOrUndefined(exportProperties) &&\n !isNullOrUndefined(exportProperties.columns) && exportProperties.columns.length > 0;\n}\n/**\n * @param {PdfExportProperties | ExcelExportProperties} exportProperties - Defines the export properties\n * @param {IGrid} gObj - Defines the grid object\n * @returns {void}\n * @hidden\n */\nexport function updateColumnTypeForExportColumns(exportProperties, gObj) {\n var exportColumns = exportProperties.columns;\n var gridColumns = gObj.columns;\n for (var i = 0; i < exportColumns.length; i++) {\n if (gridColumns.length - 1 >= i) {\n if (gridColumns[parseInt(i.toString(), 10)].columns) {\n for (var j = 0; j < gridColumns[parseInt(i.toString(), 10)].columns.length; j++) {\n exportColumns[parseInt(i.toString(), 10)].columns[parseInt(j.toString(), 10)]\n .type = gridColumns[parseInt(i.toString(), 10)].columns[parseInt(j.toString(), 10)].type;\n }\n }\n else {\n exportColumns[parseInt(i.toString(), 10)].type = gridColumns[parseInt(i.toString(), 10)].type;\n }\n }\n }\n}\n/**\n * @hidden\n * @param {IGrid} grid - Defines the grid\n * @returns {void}\n */\nexport function updatecloneRow(grid) {\n var nRows = [];\n var actualRows = grid.vRows;\n for (var i = 0; i < actualRows.length; i++) {\n if (actualRows[parseInt(i.toString(), 10)].isDataRow) {\n nRows.push(actualRows[parseInt(i.toString(), 10)]);\n }\n else if (!actualRows[parseInt(i.toString(), 10)].isDataRow) {\n nRows.push(actualRows[parseInt(i.toString(), 10)]);\n if (!actualRows[parseInt(i.toString(), 10)].isExpand && actualRows[parseInt(i.toString(), 10)].isCaptionRow) {\n i += getCollapsedRowsCount(actualRows[parseInt(i.toString(), 10)], grid);\n }\n }\n }\n grid.vcRows = nRows;\n}\nvar count = 0;\n/**\n * @hidden\n * @param {Row<Column>} val - Defines the value\n * @param {IGrid} grid - Defines the grid\n * @returns {number} Returns the collapsed row count\n */\nexport function getCollapsedRowsCount(val, grid) {\n count = 0;\n var gSummary = 'gSummary';\n var total = 'count';\n var gLen = grid.groupSettings.columns.length;\n var records = 'records';\n var items = 'items';\n var value = val[\"\" + gSummary];\n var dataRowCnt = 0;\n var agrCnt = 'aggregatesCount';\n if (value === val.data[\"\" + total]) {\n if (grid.groupSettings.columns.length && !isNullOrUndefined(val[\"\" + agrCnt]) && val[\"\" + agrCnt]) {\n if (grid.groupSettings.columns.length !== 1) {\n count += (val.indent !== 0 && (value) < 2) ? (val[\"\" + gSummary] * ((gLen - val.indent) + (gLen - val.indent) * val[\"\" + agrCnt])) :\n (val[\"\" + gSummary] * ((gLen - val.indent) + (gLen - val.indent - 1) * val[\"\" + agrCnt])) + val[\"\" + agrCnt];\n }\n else if (grid.groupSettings.columns.length === 1) {\n count += (val[\"\" + gSummary] * (gLen - val.indent)) + val[\"\" + agrCnt];\n }\n }\n else if (grid.groupSettings.columns.length) {\n if (grid.groupSettings.columns.length !== 1) {\n count += val[\"\" + gSummary] * (grid.groupSettings.columns.length - val.indent);\n }\n else {\n count += val[\"\" + gSummary];\n }\n }\n return count;\n }\n else {\n for (var i = 0, len = val.data[\"\" + items].length; i < len; i++) {\n var gLevel = val.data[\"\" + items][parseInt(i.toString(), 10)];\n count += gLevel[\"\" + items].length + ((gLen !== grid.columns.length) &&\n !isNullOrUndefined(gLevel[\"\" + items][\"\" + records]) ? gLevel[\"\" + items][\"\" + records].length : 0);\n dataRowCnt += (!isNullOrUndefined(gLevel[\"\" + items][\"\" + records]) && !isNullOrUndefined(val[\"\" + agrCnt])) ? gLevel[\"\" + items][\"\" + records].length :\n gLevel[\"\" + items].length;\n if (gLevel[\"\" + items].GroupGuid && gLevel[\"\" + items].childLevels !== 0) {\n recursive(gLevel);\n }\n }\n count += val.data[\"\" + items].length;\n if (!isNullOrUndefined(val[\"\" + agrCnt])) {\n if (val[\"\" + agrCnt] && count && dataRowCnt !== 0) {\n count += ((count - dataRowCnt) * val[\"\" + agrCnt]) + val[\"\" + agrCnt];\n }\n }\n }\n return count;\n}\n/**\n * @param {Object[]} row - Defines the row\n * @returns {void}\n * @hidden\n */\nexport function recursive(row) {\n var items = 'items';\n var rCount = 'count';\n for (var j = 0, length_1 = row[\"\" + items].length; j < length_1; j++) {\n var nLevel = row[\"\" + items][parseInt(j.toString(), 10)];\n count += nLevel[\"\" + rCount];\n if (nLevel[\"\" + items].childLevels !== 0) {\n recursive(nLevel);\n }\n }\n}\n/**\n * @param {Object[]} collection - Defines the array\n * @param {Object} predicate - Defines the predicate\n * @returns {Object} Returns the object\n * @hidden\n */\nexport function iterateArrayOrObject(collection, predicate) {\n var result = [];\n for (var i = 0, len = collection.length; i < len; i++) {\n var pred = predicate(collection[parseInt(i.toString(), 10)], i);\n if (!isNullOrUndefined(pred)) {\n result.push(pred);\n }\n }\n return result;\n}\n/**\n * @param {Object[]} array - Defines the array\n * @returns {Object} Returns the object\n * @hidden\n */\nexport function iterateExtend(array) {\n var obj = [];\n for (var i = 0; i < array.length; i++) {\n obj.push(baseExtend({}, getActualProperties(array[parseInt(i.toString(), 10)]), {}, true));\n }\n return obj;\n}\n/**\n * @param {string | Function} template - Defines the template\n * @returns {Function} Returns the function\n * @hidden\n */\nexport function templateCompiler(template) {\n if (template) {\n try {\n var validSelector = template[0] !== '<';\n if (typeof template === 'function') {\n return baseTemplateComplier(template);\n }\n else if (validSelector && document.querySelectorAll(template).length) {\n return baseTemplateComplier(document.querySelector(template).innerHTML.trim());\n }\n else {\n return baseTemplateComplier(template);\n }\n }\n catch (e) {\n return baseTemplateComplier(template);\n }\n }\n return undefined;\n}\n/**\n * @param {Element} node - Defines the column\n * @param {Object} customAttributes - Defines the index\n * @returns {void}\n * @hidden\n */\nexport function setStyleAndAttributes(node, customAttributes) {\n var copyAttr = {};\n var literals = ['style', 'class'];\n //Dont touch the original object - make a copy\n baseExtend(copyAttr, customAttributes, {});\n if ('style' in copyAttr) {\n setStyleAttribute(node, copyAttr[literals[0]]);\n delete copyAttr[literals[0]];\n }\n if ('class' in copyAttr) {\n addClass([node], copyAttr[literals[1]]);\n delete copyAttr[literals[1]];\n }\n attributes(node, copyAttr);\n}\n/**\n * @param {Object} copied - Defines the column\n * @param {Object} first - Defines the inndex\n * @param {Object} second - Defines the second object\n * @param {string[]} exclude - Defines the exclude\n * @returns {Object} Returns the object\n * @hidden\n */\nexport function extend(copied, first, second, exclude) {\n var moved = baseExtend(copied, first, second);\n var values = Object.keys(moved);\n for (var i = 0; i < values.length; i++) {\n if (exclude && exclude.indexOf(values[parseInt(i.toString(), 10)]) !== -1) {\n delete moved[values[parseInt(i.toString(), 10)]];\n }\n }\n return moved;\n}\n/**\n * @param {Column[]} columnModel - Defines the column\n * @param {number} ind - Defines the inndex\n * @returns {number} - Returns the columnindex\n * @hidden\n */\nexport function setColumnIndex(columnModel, ind) {\n if (ind === void 0) { ind = 0; }\n for (var i = 0, len = columnModel.length; i < len; i++) {\n if (columnModel[parseInt(i.toString(), 10)].columns) {\n columnModel[parseInt(i.toString(), 10)].index = isNullOrUndefined(columnModel[parseInt(i.toString(), 10)].index) ? ind\n : columnModel[parseInt(i.toString(), 10)].index;\n ind++;\n ind = setColumnIndex(columnModel[parseInt(i.toString(), 10)].columns, ind);\n }\n else {\n columnModel[parseInt(i.toString(), 10)].index = isNullOrUndefined(columnModel[parseInt(i.toString(), 10)].index) ? ind\n : columnModel[parseInt(i.toString(), 10)].index;\n ind++;\n }\n }\n return ind;\n}\n/**\n * @param {Column[] | string[] | ColumnModel[]} columns - Defines the column\n * @param {boolean} autoWidth - Defines the autowidth\n * @param {IGrid} gObj - Defines the class name\n * @returns {Column} - Returns the columns\n * @hidden\n */\nexport function prepareColumns(columns, autoWidth, gObj) {\n for (var c = 0, len = columns.length; c < len; c++) {\n var column = void 0;\n if (typeof columns[parseInt(c.toString(), 10)] === 'string') {\n column = new Column({ field: columns[parseInt(c.toString(), 10)] }, gObj);\n }\n else if (!(columns[parseInt(c.toString(), 10)] instanceof Column) || columns[parseInt(c.toString(), 10)].columns) {\n if (!columns[parseInt(c.toString(), 10)].columns) {\n column = new Column(columns[parseInt(c.toString(), 10)], gObj);\n }\n else {\n columns[parseInt(c.toString(), 10)].columns = prepareColumns(columns[parseInt(c.toString(), 10)].columns, null, gObj);\n column = new Column(columns[parseInt(c.toString(), 10)], gObj);\n }\n }\n else {\n column = columns[parseInt(c.toString(), 10)];\n }\n if (column.type && column.type.toLowerCase() === 'checkbox') {\n column.allowReordering = false;\n }\n column.headerText = isNullOrUndefined(column.headerText) ? column.foreignKeyValue || column.field || '' : column.headerText;\n column.foreignKeyField = column.foreignKeyField || column.field;\n column.valueAccessor = (typeof column.valueAccessor === 'string' ? getValue(column.valueAccessor, window)\n : column.valueAccessor) || valueAccessor;\n column.width = autoWidth && isNullOrUndefined(column.width) ? 200 : column.width;\n if (isNullOrUndefined(column.visible)) {\n column.visible = true;\n }\n columns[parseInt(c.toString(), 10)] = column;\n }\n return columns;\n}\n/**\n * @param {HTMLElement} popUp - Defines the popup element\n * @param {MouseEvent | TouchEvent} e - Defines the moouse event\n * @param {string} className - Defines the class name\n * @returns {void}\n * @hidden\n */\nexport function setCssInGridPopUp(popUp, e, className) {\n var popUpSpan = popUp.querySelector('span');\n var position = popUp.parentElement.getBoundingClientRect();\n var targetPosition = e.target.getBoundingClientRect();\n popUpSpan.className = className;\n popUp.style.display = '';\n var isBottomTail = (isNullOrUndefined(e.clientY) ? e.changedTouches[0].clientY :\n e.clientY) > popUp.offsetHeight + 10;\n popUp.style.top = targetPosition.top - position.top +\n (isBottomTail ? -(popUp.offsetHeight + 10) : popUp.offsetHeight + 10) + 'px'; //10px for tail element\n popUp.style.left = getPopupLeftPosition(popUp, e, targetPosition, position.left) + 'px';\n if (isBottomTail) {\n popUp.querySelector('.e-downtail').style.display = '';\n popUp.querySelector('.e-uptail').style.display = 'none';\n }\n else {\n popUp.querySelector('.e-downtail').style.display = 'none';\n popUp.querySelector('.e-uptail').style.display = '';\n }\n}\n/**\n * @param {HTMLElement} popup - Defines the popup element\n * @param {MouseEvent | TouchEvent} e - Defines the mouse event\n * @param {Object} targetPosition - Defines the target position\n * @param {number} targetPosition.top - Defines the top position\n * @param {number} targetPosition.left - Defines the left position\n * @param {number} targetPosition.right - Defines the right position\n * @param {number} left - Defines the left position\n * @returns {number} Returns the popup left position\n * @hidden\n */\nfunction getPopupLeftPosition(popup, e, targetPosition, left) {\n var width = popup.offsetWidth / 2;\n var x = getPosition(e).x;\n if (x - targetPosition.left < width) {\n return targetPosition.left - left;\n }\n else if (targetPosition.right - x < width) {\n return targetPosition.right - left - width * 2;\n }\n else {\n return x - left - width;\n }\n}\n/**\n * @param {Object} obj - Defines the object\n * @returns {Object} Returns the Properties\n * @hidden\n */\nexport function getActualProperties(obj) {\n if (obj instanceof ChildProperty) {\n return getValue('properties', obj);\n }\n else {\n return obj;\n }\n}\n/**\n * @param {Element} elem - Defines the element\n * @param {string} selector - Defines the string selector\n * @param {boolean} isID - Defines the isID\n * @returns {Element} Returns the element\n * @hidden\n */\nexport function parentsUntil(elem, selector, isID) {\n var parent = elem;\n while (parent) {\n if (isID ? parent.id === selector : parent.classList.contains(selector)) {\n break;\n }\n parent = parent.parentElement;\n }\n return parent;\n}\n/**\n * @param {Element} element - Defines the element\n * @param {Element} elements - Defines the element\n * @returns {number} Returns the element index\n * @hidden\n */\nexport function getElementIndex(element, elements) {\n var index = -1;\n for (var i = 0, len = elements.length; i < len; i++) {\n if (elements[parseInt(i.toString(), 10)].isEqualNode(element)) {\n index = i;\n break;\n }\n }\n return index;\n}\n/**\n * @param {Object} value - Defines the value\n * @param {Object} collection - defines the collection\n * @returns {number} Returns the array\n * @hidden\n */\nexport function inArray(value, collection) {\n for (var i = 0, len = collection.length; i < len; i++) {\n if (collection[parseInt(i.toString(), 10)] === value) {\n return i;\n }\n }\n return -1;\n}\n/**\n * @param {Object} collection - Defines the collection\n * @returns {Object} Returns the object\n * @hidden\n */\nexport function getActualPropFromColl(collection) {\n var coll = [];\n for (var i = 0, len = collection.length; i < len; i++) {\n // eslint-disable-next-line no-prototype-builtins\n if (collection[parseInt(i.toString(), 10)].hasOwnProperty('properties')) {\n coll.push(collection[parseInt(i.toString(), 10)].properties);\n }\n else {\n coll.push(collection[parseInt(i.toString(), 10)]);\n }\n }\n return coll;\n}\n/**\n * @param {Element} target - Defines the target element\n * @param {string} selector - Defines the selector\n * @returns {void}\n * @hidden\n */\nexport function removeElement(target, selector) {\n var elements = [].slice.call(target.querySelectorAll(selector));\n for (var i = 0; i < elements.length; i++) {\n remove(elements[parseInt(i.toString(), 10)]);\n }\n}\n/**\n * @param {MouseEvent | TouchEvent} e Defines the mouse event\n * @returns {IPosition} Returns the position\n * @hidden\n */\nexport function getPosition(e) {\n var position = {};\n position.x = (isNullOrUndefined(e.clientX) ? e.changedTouches[0].clientX :\n e.clientX);\n position.y = (isNullOrUndefined(e.clientY) ? e.changedTouches[0].clientY :\n e.clientY);\n return position;\n}\nvar uid = 0;\n/**\n * @param {string} prefix - Defines the prefix string\n * @returns {string} Returns the uid\n * @hidden\n */\nexport function getUid(prefix) {\n return prefix + uid++;\n}\n/**\n * @param {Element | DocumentFragment} elem - Defines the element\n * @param {Element[] | NodeList} children - Defines the Element\n * @returns {Element} Returns the element\n * @hidden\n */\nexport function appendChildren(elem, children) {\n for (var i = 0, len = children.length; i < len; i++) {\n if (len === children.length) {\n elem.appendChild(children[parseInt(i.toString(), 10)]);\n }\n else {\n elem.appendChild(children[0]);\n }\n }\n return elem;\n}\n/**\n * @param {Element} elem - Defines the element\n * @param {string} selector - Defines the selector\n * @param {boolean} isID - Defines isID\n * @returns {Element} Return the element\n * @hidden\n */\nexport function parents(elem, selector, isID) {\n var parent = elem;\n var parents = [];\n while (parent) {\n if (isID ? parent.id === selector : parent.classList.contains(selector)) {\n parents.push(parent);\n }\n parent = parent.parentElement;\n }\n return parents;\n}\n/**\n * @param {AggregateType | string} type - Defines the type\n * @param {Object} data - Defines the data\n * @param {AggregateColumnModel} column - Defines the column\n * @param {Object} context - Defines the context\n * @returns {Object} Returns the calculated aggragate\n * @hidden\n */\nexport function calculateAggregate(type, data, column, context) {\n if (type === 'Custom') {\n var temp = column.customAggregate;\n if (typeof temp === 'string') {\n temp = getValue(temp, window);\n }\n return temp ? temp.call(context, data, column) : '';\n }\n return (column.field in data || data instanceof Array) ? DataUtil.aggregates[type.toLowerCase()](data, column.field) : null;\n}\n/** @hidden */\nvar scrollWidth = null;\n/** @hidden\n * @returns {number} - Returns the scrollbarwidth\n */\nexport function getScrollBarWidth() {\n if (scrollWidth !== null) {\n return scrollWidth;\n }\n var divNode = document.createElement('div');\n var value = 0;\n divNode.style.cssText = 'width:100px;height: 100px;overflow: scroll;position: absolute;top: -9999px;';\n document.body.appendChild(divNode);\n value = (divNode.offsetWidth - divNode.clientWidth) | 0;\n document.body.removeChild(divNode);\n return scrollWidth = value;\n}\n/** @hidden */\nvar rowHeight;\n/**\n * @param {HTMLElement} element - Defines the element\n * @returns {number} Returns the roww height\n * @hidden\n */\nexport function getRowHeight(element) {\n if (rowHeight !== undefined) {\n return rowHeight;\n }\n var table = createElement('table', { className: literals.table, styles: 'visibility: hidden', attrs: { role: 'grid' } });\n table.innerHTML = '<tr><td class=\"e-rowcell\">A<td></tr>';\n element.appendChild(table);\n var rect = table.querySelector('td').getBoundingClientRect();\n element.removeChild(table);\n rowHeight = Math.ceil(rect.height);\n return rowHeight;\n}\n/** @hidden */\nvar actualRowHeight;\n/**\n * @param {HTMLElement} element - Defines the HTMl element\n * @returns {number} Returns the row height\n * @hidden\n */\nexport function getActualRowHeight(element) {\n if (actualRowHeight !== undefined) {\n return rowHeight;\n }\n var table = createElement('table', { className: literals.table, styles: 'visibility: hidden', attrs: { role: 'grid' } });\n table.innerHTML = '<tr><td class=\"e-rowcell\">A<td></tr>';\n element.appendChild(table);\n var rect = table.querySelector('tr').getBoundingClientRect();\n element.removeChild(table);\n return rect.height;\n}\n/**\n * @param {string} field - Defines the field\n * @returns {boolean} - Returns is complex field\n * @hidden\n */\nexport function isComplexField(field) {\n return field.split('.').length > 1;\n}\n/**\n * @param {string} field - Defines the field\n * @returns {string} - Returns the get complex field ID\n * @hidden\n */\nexport function getComplexFieldID(field) {\n if (field === void 0) { field = ''; }\n return field.replace(/\\./g, '___');\n}\n/**\n * @param {string} field - Defines the field\n * @returns {string} - Returns the parsed column field id\n * @hidden\n */\nexport function getParsedFieldID(field) {\n if (field === void 0) { field = ''; }\n return field.replace(/[^a-zA-Z0-9_.]/g, '\\\\$&');\n}\n/**\n * @param {string} field - Defines the field\n * @returns {string} - Returns the set complex field ID\n * @hidden\n */\nexport function setComplexFieldID(field) {\n if (field === void 0) { field = ''; }\n return field.replace(/___/g, '.');\n}\n/**\n * @param {Column} col - Defines the column\n * @param {string} type - Defines the type\n * @param {Element} elem - Defines th element\n * @returns {boolean} Returns is Editable\n * @hidden\n */\nexport function isEditable(col, type, elem) {\n var row = parentsUntil(elem, literals.row);\n var isOldRow = !row ? true : row && !row.classList.contains('e-insertedrow');\n if (type === 'beginEdit' && isOldRow) {\n if (col.isIdentity || col.isPrimaryKey || !col.allowEditing) {\n return false;\n }\n return true;\n }\n else if (type === 'add' && col.isIdentity) {\n return false;\n }\n else {\n if (isOldRow && !col.allowEditing && !col.isIdentity && !col.isPrimaryKey) {\n return false;\n }\n return true;\n }\n}\n/**\n * @param {IGrid} inst - Defines the IGrid\n * @returns {boolean} Returns is action prevent in boolean\n * @hidden\n */\nexport function isActionPrevent(inst) {\n var dlg = select('#' + inst.element.id + 'EditConfirm', inst.element);\n return inst.editSettings.mode === 'Batch' &&\n (selectAll('.e-updatedtd', inst.element).length || selectAll('.e-gridform.e-formvalidator', inst.element).length)\n && inst.editSettings.showConfirmDialog && (dlg ? dlg.classList.contains('e-popup-close') : true);\n}\n/**\n * @param {any} elem - Defines the element\n * @param {boolean} action - Defines the boolean for action\n * @returns {void}\n * @hidden\n */\n// eslint-disable-next-line\nexport function wrap(elem, action) {\n var clName = 'e-wrap';\n elem = elem instanceof Array ? elem : [elem];\n for (var i = 0; i < elem.length; i++) {\n if (action) {\n elem[parseInt(i.toString(), 10)].classList.add(clName);\n }\n else {\n elem[parseInt(i.toString(), 10)].classList.remove(clName);\n }\n }\n}\n/**\n * @param {ServiceLocator} serviceLocator - Defines the service locator\n * @param {Column} column - Defines the column\n * @returns {void}\n * @hidden\n */\nexport function setFormatter(serviceLocator, column) {\n var fmtr = serviceLocator.getService('valueFormatter');\n var format = 'format';\n var args;\n if (column.type === 'date' || column.type === 'datetime' || column.type === 'dateonly') {\n args = { type: column.type === 'dateonly' ? 'date' : column.type, skeleton: column.format };\n if ((typeof (column.format) === 'string') && column.format !== 'yMd') {\n args[\"\" + format] = column.format;\n }\n }\n switch (column.type) {\n case 'date':\n column.setFormatter(fmtr.getFormatFunction(args));\n column.setParser(fmtr.getParserFunction(args));\n break;\n case 'dateonly':\n column.setFormatter(fmtr.getFormatFunction(args));\n column.setParser(fmtr.getParserFunction(args));\n break;\n case 'datetime':\n column.setFormatter(fmtr.getFormatFunction(args));\n column.setParser(fmtr.getParserFunction(args));\n break;\n case 'number':\n column.setFormatter(fmtr.getFormatFunction({ format: column.format }));\n column.setParser(fmtr.getParserFunction({ format: column.format }));\n break;\n }\n}\n/**\n * @param {Element} cells - Defines the cell element\n * @param {boolean} add - Defines the add\n * @param {string} args - Defines the args\n * @returns {void}\n * @hidden\n */\nexport function addRemoveActiveClasses(cells, add) {\n var args = [];\n for (var _i = 2; _i < arguments.length; _i++) {\n args[_i - 2] = arguments[_i];\n }\n for (var i = 0, len = cells.length; i < len; i++) {\n if (add) {\n classList(cells[parseInt(i.toString(), 10)], args.slice(), []);\n cells[parseInt(i.toString(), 10)].setAttribute('aria-selected', 'true');\n }\n else {\n classList(cells[parseInt(i.toString(), 10)], [], args.slice());\n cells[parseInt(i.toString(), 10)].removeAttribute('aria-selected');\n }\n }\n}\n/**\n * @param {string} result - Defines th string\n * @returns {string} Returns the distinct staing values\n * @hidden\n */\nexport function distinctStringValues(result) {\n var temp = {};\n var res = [];\n for (var i = 0; i < result.length; i++) {\n if (!(result[parseInt(i.toString(), 10)] in temp)) {\n res.push(result[parseInt(i.toString(), 10)].toString());\n temp[result[parseInt(i.toString(), 10)]] = 1;\n }\n }\n return res;\n}\n/**\n * @param {Element} target - Defines the target\n * @param {Dialog} dialogObj - Defines the dialog\n * @returns {void}\n * @hidden\n */\nexport function getFilterMenuPostion(target, dialogObj) {\n var elementVisible = dialogObj.element.style.display;\n dialogObj.element.style.display = 'block';\n var dlgWidth = dialogObj.width;\n var newpos = calculateRelativeBasedPosition(target, dialogObj.element);\n dialogObj.element.style.display = elementVisible;\n dialogObj.element.style.top = (newpos.top + target.getBoundingClientRect().height) - 5 + 'px';\n var leftPos = ((newpos.left - dlgWidth) + target.clientWidth);\n if (leftPos < 1) {\n dialogObj.element.style.left = (dlgWidth + leftPos) - 16 + 'px'; // right calculation\n }\n else {\n dialogObj.element.style.left = leftPos + -4 + 'px';\n }\n}\n/**\n * @param {Object} args - Defines the args\n * @param {Popup} args.popup - Defines the args for popup\n * @param {Dialog} dialogObj - Defines the dialog obj\n * @returns {void}\n * @hidden\n */\nexport function getZIndexCalcualtion(args, dialogObj) {\n args.popup.element.style.zIndex = (dialogObj.zIndex + 1).toString();\n}\n/**\n * @param {Element} elem - Defines the element\n * @returns {void}\n * @hidden\n */\nexport function toogleCheckbox(elem) {\n var span = elem.querySelector('.e-frame');\n var input = span.previousSibling;\n if (span.classList.contains('e-check')) {\n input.checked = false;\n classList(span, ['e-uncheck'], ['e-check']);\n }\n else {\n input.checked = true;\n classList(span, ['e-check'], ['e-uncheck']);\n }\n}\n/**\n * @param {HTMLInputElement} elem - Defines the element\n * @param {boolean} checked - Defines is checked\n * @returns {void}\n * @hidden\n */\nexport function setChecked(elem, checked) {\n elem.checked = checked;\n}\n/**\n * @param {string} uid - Defines the string\n * @param {Element} elem - Defines the Element\n * @param {string} className - Defines the classname\n * @returns {Element} Returns the box wrap\n * @hidden\n */\nexport function createCboxWithWrap(uid, elem, className) {\n var div = createElement('div', { className: className });\n div.appendChild(elem);\n div.setAttribute('uid', uid);\n return div;\n}\n/**\n * @param {Element} elem - Defines the element\n * @param {boolean} checked - Defines is checked\n * @returns {void}\n * @hidden\n */\nexport function removeAddCboxClasses(elem, checked) {\n removeClass([elem], ['e-check', 'e-stop', 'e-uncheck']);\n if (checked) {\n elem.classList.add('e-check');\n }\n else {\n elem.classList.add('e-uncheck');\n }\n}\n/**\n * Refresh the Row model's foreign data.\n *\n * @param {IRow<Column>} row - Grid Row model object.\n * @param {Column[]} columns - Foreign columns array.\n * @param {Object} data - Updated Row data.\n * @returns {void}\n * @hidden\n */\nexport function refreshForeignData(row, columns, data) {\n for (var i = 0; i < columns.length; i++) {\n setValue(columns[parseInt(i.toString(), 10)].field, getForeignData(columns[parseInt(i.toString(), 10)], data), row.foreignKeyData);\n }\n var cells = row.cells;\n for (var i = 0; i < cells.length; i++) {\n if (cells[parseInt(i.toString(), 10)].isForeignKey) {\n setValue('foreignKeyData', getValue(cells[parseInt(i.toString(), 10)].column.field, row.foreignKeyData), cells[parseInt(i.toString(), 10)]);\n }\n }\n}\n/**\n * Get the foreign data for the corresponding cell value.\n *\n * @param {Column} column - Foreign Key column\n * @param {Object} data - Row data.\n * @param {string | number} lValue - cell value.\n * @param {Object} foreignKeyData - foreign data source.\n * @returns {Object} Returns the object\n * @hidden\n */\nexport function getForeignData(column, data, lValue, foreignKeyData) {\n var fField = column.foreignKeyField;\n var key = (!isNullOrUndefined(lValue) ? lValue : valueAccessor(column.field, data, column));\n key = isNullOrUndefined(key) ? '' : key;\n var query = new Query();\n var fdata = foreignKeyData || ((column.dataSource instanceof DataManager) && column.dataSource.dataSource.json.length ?\n column.dataSource.dataSource.json : column.columnData);\n if (key.getDay) {\n query.where(getDatePredicate({ field: fField, operator: 'equal', value: key, matchCase: false }));\n }\n else {\n query.where(fField, '==', key, false);\n }\n return new DataManager(fdata).executeLocal(query);\n}\n/**\n * To use to get the column's object by the foreign key value.\n *\n * @param {string} foreignKeyValue - Defines ForeignKeyValue.\n * @param {Column[]} columns - Array of column object.\n * @returns {Column} Returns the element\n * @hidden\n */\nexport function getColumnByForeignKeyValue(foreignKeyValue, columns) {\n var column;\n return columns.some(function (col) {\n column = col;\n return col.foreignKeyValue === foreignKeyValue;\n }) && column;\n}\n/**\n * @param {number} value - Defines the date or month value\n * @returns {string} Returns string\n * @hidden\n */\nexport function padZero(value) {\n if (value < 10) {\n return '0' + value;\n }\n return String(value);\n}\n/**\n * @param {PredicateModel} filterObject - Defines the filterObject\n * @param {string} type - Defines the type\n * @param {boolean} isExecuteLocal - Defines whether the data actions performed in client and used for dateonly type field\n * @returns {Predicate} Returns the Predicate\n * @hidden\n */\nexport function getDatePredicate(filterObject, type, isExecuteLocal) {\n var datePredicate;\n var prevDate;\n var nextDate;\n var prevObj = baseExtend({}, getActualProperties(filterObject));\n var nextObj = baseExtend({}, getActualProperties(filterObject));\n if (isNullOrUndefined(filterObject.value) || filterObject.value === '') {\n datePredicate = new Predicate(prevObj.field, prevObj.operator, prevObj.value, false);\n return datePredicate;\n }\n var value = new Date(filterObject.value);\n if (type === 'dateonly' && !isExecuteLocal) {\n if (typeof (prevObj.value) === 'string') {\n prevObj.value = new Date(prevObj.value);\n }\n var dateOnlyString = prevObj.value.getFullYear() + '-' + padZero(prevObj.value.getMonth() + 1) + '-' + padZero(prevObj.value.getDate());\n var predicates = new Predicate(prevObj.field, prevObj.operator, dateOnlyString, false);\n datePredicate = predicates;\n }\n else {\n if (filterObject.operator === 'equal' || filterObject.operator === 'notequal') {\n if (type === 'datetime') {\n prevDate = new Date(value.setSeconds(value.getSeconds() - 1));\n nextDate = new Date(value.setSeconds(value.getSeconds() + 2));\n filterObject.value = new Date(value.setSeconds(nextDate.getSeconds() - 1));\n }\n else {\n prevDate = new Date(value.setHours(0) - 1);\n nextDate = new Date(value.setHours(24));\n }\n prevObj.value = prevDate;\n nextObj.value = nextDate;\n if (filterObject.operator === 'equal') {\n prevObj.operator = 'greaterthan';\n nextObj.operator = 'lessthan';\n }\n else if (filterObject.operator === 'notequal') {\n prevObj.operator = 'lessthanorequal';\n nextObj.operator = 'greaterthanorequal';\n }\n var predicateSt = new Predicate(prevObj.field, prevObj.operator, prevObj.value, false);\n var predicateEnd = new Predicate(nextObj.field, nextObj.operator, nextObj.value, false);\n datePredicate = filterObject.operator === 'equal' ? predicateSt.and(predicateEnd) : predicateSt.or(predicateEnd);\n }\n else {\n if (type === 'date' && (filterObject.operator === 'lessthanorequal' || filterObject.operator === 'greaterthan')) {\n prevObj.value = new Date(value.setHours(24) - 1);\n }\n if (typeof (prevObj.value) === 'string') {\n prevObj.value = new Date(prevObj.value);\n }\n var predicates = new Predicate(prevObj.field, prevObj.operator, prevObj.value, false);\n datePredicate = predicates;\n }\n }\n if (filterObject.setProperties) {\n filterObject.setProperties({ ejpredicate: datePredicate }, true);\n }\n else {\n filterObject.ejpredicate = datePredicate;\n }\n return datePredicate;\n}\n/**\n * @param {IGrid} grid - Defines the IGrid\n * @returns {boolean} Returns true if group adaptive is true\n * @hidden\n */\nexport function isGroupAdaptive(grid) {\n return grid.enableVirtualization && grid.groupSettings.columns.length > 0 && grid.isVirtualAdaptive &&\n !grid.groupSettings.enableLazyLoading;\n}\n/**\n * @param {string} field - Defines the Field\n * @param {Object} object - Defines the objec\n * @returns {any} Returns the object\n * @hidden\n */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport function getObject(field, object) {\n if (field === void 0) { field = ''; }\n if (field) {\n var value = object;\n var splits = field.split('.');\n for (var i = 0; i < splits.length && !isNullOrUndefined(value); i++) {\n value = value[splits[parseInt(i.toString(), 10)]];\n if (isUndefined(value)) {\n var newCase = splits[parseInt(i.toString(), 10)].charAt(0).toUpperCase()\n + splits[parseInt(i.toString(), 10)].slice(1);\n value = object[\"\" + newCase] || object[(\"\" + newCase).charAt(0).toLowerCase() + (\"\" + newCase).slice(1)];\n }\n }\n return value;\n }\n}\n/**\n * @param {string | Object} format - defines the format\n * @param {string} colType - Defines the coltype\n * @returns {string} Returns the custom Data format\n * @hidden\n */\nexport function getCustomDateFormat(format, colType) {\n var intl = new Internationalization();\n var formatvalue;\n var formatter = 'format';\n var type = 'type';\n if (colType === 'date') {\n formatvalue = typeof (format) === 'object' ?\n intl.getDatePattern({ type: format[\"\" + type] ? format[\"\" + type] : 'date', format: format[\"\" + formatter] }, false) :\n intl.getDatePattern({ type: 'dateTime', skeleton: format }, false);\n }\n else {\n formatvalue = typeof (format) === 'object' ?\n intl.getDatePattern({ type: format[\"\" + type] ? format[\"\" + type] : 'dateTime', format: format[\"\" + formatter] }, false) :\n intl.getDatePattern({ type: 'dateTime', skeleton: format }, false);\n }\n return formatvalue;\n}\n/**\n * @param {IGrid} gObj - Defines the IGrid\n * @param {HierarchyGridPrintMode} hierarchyPrintMode - Defines the hierarchyPrintMode\n * @returns {Object} Returns the object\n * @hidden\n */\nexport function getExpandedState(gObj, hierarchyPrintMode) {\n var rows = gObj.getRowsObject();\n var obj = {};\n for (var _i = 0, rows_1 = rows; _i < rows_1.length; _i++) {\n var row = rows_1[_i];\n if (row.isExpand && !row.isDetailRow) {\n var index = gObj.allowPaging && gObj.printMode === 'AllPages' ? row.index +\n (gObj.pageSettings.currentPage * gObj.pageSettings.pageSize) - gObj.pageSettings.pageSize : row.index;\n if (!isNullOrUndefined(index)) {\n obj[parseInt(index.toString(), 10)] = {};\n obj[parseInt(index.toString(), 10)].isExpand = true;\n if (gObj.childGrid) {\n obj[parseInt(index.toString(), 10)].gridModel = getPrintGridModel(row.childGrid, hierarchyPrintMode);\n obj[parseInt(index.toString(), 10)].gridModel.query = gObj.childGrid.query;\n }\n }\n }\n }\n return obj;\n}\n/**\n * @param {IGrid} gObj - Defines the grid objct\n * @param {HierarchyGridPrintMode} hierarchyPrintMode - Defines the hierarchyPrintMode\n * @returns {IGrid} Returns the IGrid\n * @hidden\n */\nexport function getPrintGridModel(gObj, hierarchyPrintMode) {\n if (hierarchyPrintMode === void 0) { hierarchyPrintMode = 'Expanded'; }\n var printGridModel = {};\n if (!gObj) {\n return printGridModel;\n }\n for (var _i = 0, _a = Print.printGridProp; _i < _a.length; _i++) {\n var key = _a[_i];\n if (key === 'columns') {\n printGridModel[\"\" + key] = getActualPropFromColl(gObj.getColumns());\n }\n else if (key === 'allowPaging') {\n printGridModel[\"\" + key] = gObj.printMode === 'CurrentPage';\n }\n else {\n printGridModel[\"\" + key] = getActualProperties(gObj[\"\" + key]);\n }\n }\n printGridModel['enableHover'] = false;\n if ((gObj.childGrid || gObj.detailTemplate) && hierarchyPrintMode !== 'None') {\n printGridModel.expandedRows = getExpandedState(gObj, hierarchyPrintMode);\n }\n return printGridModel;\n}\n/**\n * @param {Object} copied - Defines the copied object\n * @param {Object} first - Defines the first object\n * @param {Object} second - Defines the second object\n * @param {boolean} deep - Defines the deep\n * @returns {Object} Returns the extended object\n * @hidden\n */\nexport function extendObjWithFn(copied, first, second, deep) {\n var res = copied || {};\n var len = arguments.length;\n if (deep) {\n len = len - 1;\n }\n for (var i = 1; i < len; i++) {\n // eslint-disable-next-line prefer-rest-params\n if (!arguments[parseInt(i.toString(), 10)]) {\n continue;\n }\n // eslint-disable-next-line prefer-rest-params\n var obj1 = arguments[parseInt(i.toString(), 10)];\n var keys = Object.keys(Object.getPrototypeOf(obj1)).length ?\n Object.keys(obj1).concat(getPrototypesOfObj(obj1)) : Object.keys(obj1);\n for (var i_1 = 0; i_1 < keys.length; i_1++) {\n var source = res[keys[parseInt(i_1.toString(), 10)]];\n var cpy = obj1[keys[parseInt(i_1.toString(), 10)]];\n var cln = void 0;\n if (deep && (isObject(cpy) || Array.isArray(cpy))) {\n if (isObject(cpy)) {\n cln = source ? source : {};\n res[keys[parseInt(i_1.toString(), 10)]] = baseExtend({}, cln, cpy, deep);\n }\n else {\n cln = source ? source : [];\n res[keys[parseInt(i_1.toString(), 10)]] = baseExtend([], cln, cpy, deep);\n }\n }\n else {\n res[keys[parseInt(i_1.toString(), 10)]] = cpy;\n }\n }\n }\n return res;\n}\n/**\n * @param {Object} obj - Defines the obj\n * @returns {string[]} Returns the string\n * @hidden\n */\nfunction getPrototypesOfObj(obj) {\n var keys = [];\n while (Object.getPrototypeOf(obj) && Object.keys(Object.getPrototypeOf(obj)).length) {\n keys = keys.concat(Object.keys(Object.getPrototypeOf(obj)));\n obj = Object.getPrototypeOf(obj);\n }\n return keys;\n}\n/**\n * @param {Column[]} column - Defines the Column\n * @returns {number} Returns the column Depth\n * @hidden\n */\nexport function measureColumnDepth(column) {\n var max = 0;\n for (var i = 0; i < column.length; i++) {\n var depth = checkDepth(column[parseInt(i.toString(), 10)], 0);\n if (max < depth) {\n max = depth;\n }\n }\n return max + 1;\n}\n/**\n * @param {Column} col - Defines the Column\n * @param {number} index - Defines the index\n * @returns {number} Returns the depth\n * @hidden\n */\nexport function checkDepth(col, index) {\n var max = index;\n var indices = [];\n if (col.columns) {\n index++;\n for (var i = 0; i < col.columns.length; i++) {\n indices[parseInt(i.toString(), 10)] = checkDepth(col.columns[parseInt(i.toString(), 10)], index);\n }\n for (var j = 0; j < indices.length; j++) {\n if (max < indices[parseInt(j.toString(), 10)]) {\n max = indices[parseInt(j.toString(), 10)];\n }\n }\n index = max;\n }\n return index;\n}\n/**\n * @param {IGrid} gObj - Defines the IGrid\n * @param {PredicateModel[]} filteredCols - Defines the PredicateModel\n * @returns {void}\n * @hidden\n */\nexport function refreshFilteredColsUid(gObj, filteredCols) {\n for (var i = 0; i < filteredCols.length; i++) {\n filteredCols[parseInt(i.toString(), 10)].uid = filteredCols[parseInt(i.toString(), 10)].isForeignKey ?\n getColumnByForeignKeyValue(filteredCols[parseInt(i.toString(), 10)].field, gObj.getForeignKeyColumns()).uid\n : gObj.enableColumnVirtualization ? getColumnModelByFieldName(gObj, filteredCols[parseInt(i.toString(), 10)].field).uid\n : gObj.getColumnByField(filteredCols[parseInt(i.toString(), 10)].field).uid;\n }\n}\n/** @hidden */\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport var Global;\n(function (Global) {\n // eslint-disable-next-line prefer-const\n Global.timer = null;\n})(Global || (Global = {}));\n/**\n * @param {Element} element - Defines the element\n * @returns {Object} Returns the transform values\n * @hidden\n */\nexport function getTransformValues(element) {\n var style = document.defaultView.getComputedStyle(element, null);\n var transformV = style.getPropertyValue('transform');\n var replacedTv = transformV.replace(/,/g, '');\n var translateX = parseFloat((replacedTv).split(' ')[4]);\n var translateY = parseFloat((replacedTv).split(' ')[5]);\n return { width: translateX, height: translateY };\n}\n/**\n * @param {Element} rootElement - Defines the root Element\n * @param {Element} element - Defines the element\n * @returns {void}\n * @hidden\n */\nexport function applyBiggerTheme(rootElement, element) {\n if (rootElement.classList.contains('e-bigger')) {\n element.classList.add('e-bigger');\n }\n}\n/**\n * @param {IGrid} gObj - Defines grid object\n * @returns {number} - Returns scroll width\n * @hidden\n */\nexport function getScrollWidth(gObj) {\n var scrollElem = gObj.getContent().firstElementChild;\n return scrollElem.scrollWidth > scrollElem.offsetWidth ? getScrollBarWidth() : 0;\n}\n/**\n * @param {IGrid} gObj - Defines grid object\n * @param {number} idx - Defines the index\n * @returns {number} Returns colSpan index\n * @hidden\n */\nexport function resetColspanGroupCaption(gObj, idx) {\n var colspan = 0;\n var cols = gObj.getColumns();\n var width = idx * 30;\n if (gObj.isRowDragable()) {\n colspan++;\n width += 30;\n }\n colspan += (gObj.groupSettings.columns.length - idx);\n width += (30 * (gObj.groupSettings.columns.length - idx));\n var gridWidth = (gObj.width === 'auto' ? gObj.element.offsetWidth : parseInt(gObj.width.toString(), 10)) -\n getScrollWidth(gObj);\n for (var i = 0; i < cols.length; i++) {\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseInt(cols[parseInt(i.toString(), 10)].width.toString(), 10);\n colspan++;\n }\n if (width > gridWidth) {\n colspan--;\n break;\n }\n }\n return colspan;\n}\n/**\n * @param {HTMLElement} tr - Defines the tr Element\n * @param {IGrid} gObj - Defines grid object\n * @returns {void}\n * @hidden\n */\nexport function groupCaptionRowLeftRightPos(tr, gObj) {\n var width = 0;\n for (var j = 0; j < tr.childNodes.length; j++) {\n var td = tr.childNodes[parseInt(j.toString(), 10)];\n td.classList.add('e-leftfreeze');\n applyStickyLeftRightPosition(td, width, gObj.enableRtl, 'Left');\n if (td.classList.contains('e-indentcell') || td.classList.contains('e-recordplusexpand') ||\n td.classList.contains('e-recordpluscollapse')) {\n width += 30;\n }\n if (td.classList.contains('e-groupcaption')) {\n var colspan = parseInt(td.getAttribute('colspan'), 10);\n if (gObj.isRowDragable()) {\n colspan--;\n width += 30;\n }\n colspan = colspan - (gObj.groupSettings.columns.length - j);\n width = width + (30 * (gObj.groupSettings.columns.length - j));\n var cols = gObj.getColumns();\n for (var i = 0; i < cols.length; i++) {\n if ((parseInt(td.getAttribute('colspan'), 10) > 1) &&\n (parseInt(cols[parseInt(i.toString(), 10)].width.toString(), 10)\n + width) > (parseInt(gObj.width.toString(), 10) - getScrollWidth(gObj))) {\n var newColspan = resetColspanGroupCaption(gObj, j);\n td.setAttribute('colspan', newColspan.toString());\n break;\n }\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseInt(cols[parseInt(i.toString(), 10)].width.toString(), 10);\n colspan--;\n }\n if (colspan === 0) {\n break;\n }\n }\n }\n if (td.classList.contains('e-summarycell')) {\n var uid_1 = td.getAttribute('e-mappinguid');\n var column = gObj.getColumnByUid(uid_1);\n width += parseInt(column.width.toString(), 10);\n }\n }\n}\n/**\n * @param {Element} row - Defines row element\n * @param {IGrid} gridObj - Defines grid object\n * @returns {boolean} Returns isRowEnteredInGrid\n * @hidden\n */\nexport function ensureLastRow(row, gridObj) {\n var content = gridObj.getContent().firstElementChild;\n return row && (row.getBoundingClientRect().top - content.getBoundingClientRect().top +\n gridObj.getRowHeight()) > content.offsetHeight;\n}\n/**\n * @param {Element} row - Defines row element\n * @param {number} rowTop - Defines row top number\n * @returns {boolean} Returns first row is true\n * @hidden\n */\nexport function ensureFirstRow(row, rowTop) {\n return row && row.getBoundingClientRect().top < rowTop;\n}\n/**\n * @param {number} index - Defines index\n * @param {IGrid} gObj - Defines grid object\n * @returns {boolean} Returns isRowEnteredInGrid\n * @hidden\n */\nexport function isRowEnteredInGrid(index, gObj) {\n var rowHeight = gObj.getRowHeight();\n var startIndex = gObj.getContent().firstElementChild.scrollTop / rowHeight;\n var endIndex = startIndex + (gObj.getContent().firstElementChild.offsetHeight / rowHeight);\n return index < endIndex && index > startIndex;\n}\n/**\n * @param {IGrid} gObj - Defines the grid object\n * @param {Object} data - Defines the query\n * @returns {number} Returns the edited data index\n * @hidden\n */\nexport function getEditedDataIndex(gObj, data) {\n var keyField = gObj.getPrimaryKeyFieldNames()[0];\n var dataIndex;\n gObj.getCurrentViewRecords().filter(function (e, index) {\n if (keyField.includes('.')) {\n var currentValue = getObject(keyField, e);\n var originalValue = getObject(keyField, data);\n if (currentValue === originalValue) {\n dataIndex = index;\n }\n }\n else {\n if (e[\"\" + keyField] === data[\"\" + keyField]) {\n dataIndex = index;\n }\n }\n });\n return dataIndex;\n}\n/**\n * @param {Object} args - Defines the argument\n * @param {Query} query - Defines the query\n * @returns {FilterStateObj} Returns the filter state object\n * @hidden\n */\nexport function eventPromise(args, query) {\n var state = getStateEventArgument(query);\n var def = new Deferred();\n state.dataSource = def.resolve;\n state.action = args;\n return { state: state, deffered: def };\n}\n/**\n * @param {Query} query - Defines the query\n * @returns {Object} Returns the state event argument\n * @hidden\n */\nexport function getStateEventArgument(query) {\n var adaptr = new UrlAdaptor();\n var dm = new DataManager({ url: '', adaptor: new UrlAdaptor });\n var state = adaptr.processQuery(dm, query);\n var data = JSON.parse(state.data);\n return data;\n}\n/**\n * @param {IGrid} gObj - Defines the Igrid\n * @returns {boolean} Returns the ispercentageWidth\n * @hidden\n */\nexport function ispercentageWidth(gObj) {\n var columns = gObj.getVisibleColumns();\n var percentageCol = 0;\n var undefinedWidthCol = 0;\n for (var i = 0; i < columns.length; i++) {\n if (isUndefined(columns[parseInt(i.toString(), 10)].width)) {\n undefinedWidthCol++;\n }\n else if (columns[parseInt(i.toString(), 10)].width.toString().indexOf('%') !== -1) {\n percentageCol++;\n }\n }\n return (gObj.width === 'auto' || typeof (gObj.width) === 'string' && gObj.width.indexOf('%') !== -1) &&\n !gObj.groupSettings.showGroupedColumn && gObj.groupSettings.columns.length\n && percentageCol && !undefinedWidthCol;\n}\n/**\n * @param {IGrid} gObj - Defines the IGrid\n * @param {Row<Column>[]} rows - Defines the row\n * @param {HTMLTableRowElement[]} rowElms - Row elements\n * @param {number} index - Row index\n * @param {number} startRowIndex - Start Row Index\n * @returns {void}\n * @hidden\n */\nexport function resetRowIndex(gObj, rows, rowElms, index, startRowIndex) {\n var startIndex = index ? index : 0;\n for (var i = startRowIndex ? startRowIndex : 0; i < rows.length; i++) {\n if (rows[parseInt(i.toString(), 10)] && rows[parseInt(i.toString(), 10)].isDataRow) {\n rows[parseInt(i.toString(), 10)].index = startIndex;\n rows[parseInt(i.toString(), 10)].isAltRow = gObj.enableAltRow ? startIndex % 2 !== 0 : false;\n rowElms[parseInt(i.toString(), 10)].setAttribute(literals.dataRowIndex, startIndex.toString());\n rowElms[parseInt(i.toString(), 10)].setAttribute(literals.ariaRowIndex, (startIndex + 1).toString());\n if (rows[parseInt(i.toString(), 10)].isAltRow) {\n rowElms[parseInt(i.toString(), 10)].classList.add('e-altrow');\n }\n else {\n rowElms[parseInt(i.toString(), 10)].classList.remove('e-altrow');\n }\n for (var j = 0; j < rowElms[parseInt(i.toString(), 10)].cells.length; j++) {\n rowElms[parseInt(i.toString(), 10)].cells[parseInt(j.toString(), 10)].setAttribute('index', startIndex.toString());\n }\n startIndex++;\n }\n }\n if (!rows.length) {\n gObj.renderModule.emptyRow(true);\n }\n}\n/**\n * @param {IGrid} gObj - Defines the grid object\n * @param {Object} changes - Defines the changes\n * @param {string} type - Defines the type\n * @param {string} keyField - Defines the keyfield\n * @returns {void}\n * @hidden\n */\nexport function compareChanges(gObj, changes, type, keyField) {\n var newArray = gObj.dataToBeUpdated[\"\" + type].concat(changes[\"\" + type]).reduce(function (r, o) {\n r[o[\"\" + keyField]] = r[o[\"\" + keyField]] === undefined ? o : Object.assign(r[o[\"\" + keyField]], o);\n return r;\n }, {});\n gObj.dataToBeUpdated[\"\" + type] = Object.keys(newArray).map(function (k) { return newArray[\"\" + k]; });\n}\n/**\n * @param {IGrid} gObj - Defines the grid object\n * @returns {void}\n * @hidden\n */\nexport function setRowElements(gObj) {\n (gObj).contentModule.rowElements =\n [].slice.call(gObj.element.querySelectorAll('.e-row:not(.e-addedrow)'));\n}\n/**\n * @param {Element} row - Defines the row\n * @param {number} start - Defines the start index\n * @param {number} end - Defines the end index\n * @returns {void}\n * @hidden\n */\nexport function sliceElements(row, start, end) {\n var cells = row.children;\n var len = cells.length;\n var k = 0;\n for (var i = 0; i < len; i++, k++) {\n if (i >= start && i < end) {\n continue;\n }\n row.removeChild(row.children[parseInt(k.toString(), 10)]);\n k--;\n }\n}\n/**\n * @param {Column} column - Defines the column\n * @param {string} uid - Defines the uid\n * @returns {boolean} Returns is child column\n * @hidden\n */\nexport function isChildColumn(column, uid) {\n var uids = [];\n uids.push(column.uid);\n pushuid(column, uids);\n if (uids.indexOf(uid) > -1) {\n return true;\n }\n else {\n return false;\n }\n}\n/**\n * @param {Column} column - Defines the column\n * @param {string[]} uids - Defines the uid\n * @returns {void}\n * @hidden\n */\nexport function pushuid(column, uids) {\n for (var i = 0; i < column.columns.length; i++) {\n if (column.columns[parseInt(i.toString(), 10)].uid) {\n uids.push(column.columns[parseInt(i.toString(), 10)].uid);\n }\n if (column.columns[parseInt(i.toString(), 10)].columns &&\n column.columns[parseInt(i.toString(), 10)].columns.length) {\n pushuid(column.columns[parseInt(i.toString(), 10)], uids);\n }\n }\n}\n/**\n * @param {Column} column - Defines the column\n * @returns {string} Returns the direction\n * @hidden\n */\nexport function frozenDirection(column) {\n if (column.columns[0].freeze || column.columns[0].isFrozen) {\n if (column.columns[0].freeze === 'Left' || column.columns[0].isFrozen) {\n return 'Left';\n }\n else if (column.columns[0].freeze === 'Right') {\n return 'Right';\n }\n else if (column.columns[0].freeze === 'Fixed') {\n return 'Fixed';\n }\n else {\n return 'None';\n }\n }\n else {\n if (column.columns[0].columns && column.columns[0].columns.length) {\n return frozenDirection(column.columns[0]);\n }\n else {\n return 'None';\n }\n }\n}\n/**\n * @param {Element} row - Defines the row\n * @returns {void}\n * @hidden\n */\nexport function addFixedColumnBorder(row) {\n if (row.querySelector('.e-fixedfreeze')) {\n var cells = [].slice.call(row.querySelectorAll('.e-filterbarcell:not(.e-hide),.e-summarycell:not(.e-hide),.e-headercell:not(.e-hide),.e-rowcell:not(.e-hide)'));\n for (var j = 0; j < cells.length; j++) {\n if (cells[parseInt(j.toString(), 10)].classList.contains('e-fixedfreeze') && (!(cells[j - 1]) ||\n (cells[j - 1] && !cells[j - 1].classList.contains('e-fixedfreeze')))) {\n cells[parseInt(j.toString(), 10)].classList.add('e-freezeleftborder');\n }\n if (cells[parseInt(j.toString(), 10)].classList.contains('e-fixedfreeze') && (!(cells[j + 1]) ||\n (cells[j + 1] && !cells[j + 1].classList.contains('e-fixedfreeze')))) {\n cells[parseInt(j.toString(), 10)].classList.add('e-freezerightborder');\n }\n }\n }\n}\n/**\n * @param {HTMLElement} node - Defines the row\n * @param {number} width - Defines the width\n * @param {boolean} isRtl - Boolean property\n * @param {string} position - Defines the position\n * @returns {void}\n * @hidden\n */\nexport function applyStickyLeftRightPosition(node, width, isRtl, position) {\n if (position === 'Left') {\n if (isRtl) {\n node.style.right = width + 'px';\n }\n else {\n node.style.left = width + 'px';\n }\n }\n if (position === 'Right') {\n if (isRtl) {\n node.style.left = width + 'px';\n }\n else {\n node.style.right = width + 'px';\n }\n }\n}\n/**\n * @param {IGrid} gObj - Defines the grid\n * @param {Column} column - Defines the column\n * @param {Element} node - Defines the Element\n * @returns {void}\n * @hidden\n */\nexport function addStickyColumnPosition(gObj, column, node) {\n if (column.freeze === 'Left' || column.isFrozen) {\n node.classList.add('e-leftfreeze');\n if (column.border === 'Left') {\n node.classList.add('e-freezeleftborder');\n }\n if (column.index === 0) {\n applyStickyLeftRightPosition(node, (gObj.getIndentCount() * 30), gObj.enableRtl, 'Left');\n if (gObj.enableColumnVirtualization) {\n column.valueX = (gObj.getIndentCount() * 30);\n }\n }\n else {\n var cols = gObj.getColumns();\n var width = gObj.getIndentCount() * 30;\n for (var i = 0; i < cols.length; i++) {\n if (column.uid === cols[parseInt(i.toString(), 10)].uid) {\n break;\n }\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n applyStickyLeftRightPosition(node, width, gObj.enableRtl, 'Left');\n if (gObj.enableColumnVirtualization) {\n column.valueX = width;\n }\n }\n }\n else if (column.freeze === 'Right') {\n node.classList.add('e-rightfreeze');\n var cols = gObj.getColumns();\n if (column.border === 'Right') {\n node.classList.add('e-freezerightborder');\n }\n if (column.index === cols[cols.length - 1].index) {\n var width = gObj.getFrozenMode() === 'Right' && gObj.isRowDragable() ? 30 : 0;\n applyStickyLeftRightPosition(node, width, gObj.enableRtl, 'Right');\n if (gObj.enableColumnVirtualization) {\n column.valueX = width;\n }\n }\n else {\n var width = gObj.getFrozenMode() === 'Right' && gObj.isRowDragable() ? 30 : 0;\n for (var i = cols.length - 1; i >= 0; i--) {\n if (column.uid === cols[parseInt(i.toString(), 10)].uid) {\n break;\n }\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n applyStickyLeftRightPosition(node, width, gObj.enableRtl, 'Right');\n if (gObj.enableColumnVirtualization) {\n column.valueX = width;\n }\n }\n }\n else if (column.freeze === 'Fixed') {\n node.classList.add('e-fixedfreeze');\n var cols = gObj.getColumns();\n var width = 0;\n if (gObj.getVisibleFrozenLeftCount()) {\n width = gObj.getIndentCount() * 30;\n }\n else if (gObj.getFrozenMode() === 'Right') {\n width = gObj.groupSettings.columns.length * 30;\n }\n for (var i = 0; i < cols.length; i++) {\n if (column.uid === cols[parseInt(i.toString(), 10)].uid) {\n break;\n }\n if ((cols[parseInt(i.toString(), 10)].freeze === 'Left' || cols[parseInt(i.toString(), 10)].isFrozen) ||\n cols[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n }\n applyStickyLeftRightPosition(node, (width - 1), gObj.enableRtl, 'Left');\n width = gObj.getFrozenMode() === 'Right' && gObj.isRowDragable() ? 30 : 0;\n for (var i = cols.length - 1; i >= 0; i--) {\n if (column.uid === cols[parseInt(i.toString(), 10)].uid) {\n break;\n }\n if (cols[parseInt(i.toString(), 10)].freeze === 'Right' || cols[parseInt(i.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(i.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(i.toString(), 10)].width.toString());\n }\n }\n }\n applyStickyLeftRightPosition(node, (width - 1), gObj.enableRtl, 'Right');\n }\n else {\n node.classList.add('e-unfreeze');\n }\n}\n/**\n * @param {IGrid} gObj - Defines the grid Object\n * @param {Column} col - Defines the column\n * @param {number} rowIndex - Defines the rowindex\n * @returns {Element} Returns the element\n * @hidden\n */\nexport function getCellsByTableName(gObj, col, rowIndex) {\n return [].slice.call(gObj.getDataRows()[parseInt(rowIndex.toString(), 10)].getElementsByClassName(literals.rowCell));\n}\n/**\n * @param {IGrid} gObj - Defines the column\n * @param {Column} col - Defines the index\n * @param {number} rowIndex - Defines the rules\n * @param {number} index - Defines the movable column rules\n * @returns {Element} Returns the Element\n * @hidden\n */\nexport function getCellByColAndRowIndex(gObj, col, rowIndex, index) {\n return getCellsByTableName(gObj, col, rowIndex)[parseInt(index.toString(), 10)];\n}\n/**\n * @param {Column} col - Defines the column\n * @param {number} index - Defines the index\n * @param {Object} rules - Defines the rules\n * @param {Object} mRules - Defines the movable column rules\n * @param {Object} frRules - Defines the Frozen rules\n * @param {number} len - Defines the length\n * @param {boolean} isCustom - Defines custom form validation\n * @returns {void}\n * @hidden\n */\nexport function setValidationRuels(col, index, rules, mRules, frRules, len, isCustom) {\n if (isCustom) {\n rules[getComplexFieldID(col.field)] = col.validationRules;\n }\n else {\n if (col.getFreezeTableName() === literals.frozenLeft\n || (!index && col.getFreezeTableName() === literals.frozenRight) || len === 1) {\n rules[getComplexFieldID(col.field)] = col.validationRules;\n }\n else if (col.getFreezeTableName() === 'movable' || !col.getFreezeTableName()) {\n mRules[getComplexFieldID(col.field)] = col.validationRules;\n }\n else if (col.getFreezeTableName() === literals.frozenRight) {\n frRules[getComplexFieldID(col.field)] = col.validationRules;\n }\n }\n}\n/**\n * @param {string} numberFormat - Format\n * @param {string} type - Value type\n * @param {boolean} isExcel - Boolean property\n * @param {string} currencyCode - Specifies the currency code to be used for formatting.\n * @returns {string} returns formated value\n * @hidden\n */\nexport function getNumberFormat(numberFormat, type, isExcel, currencyCode) {\n var format;\n var intl = new Internationalization();\n if (type === 'number') {\n try {\n format = intl.getNumberPattern({ format: numberFormat, currency: currencyCode, useGrouping: true }, true);\n }\n catch (error) {\n format = numberFormat;\n }\n }\n else if (type === 'date' || type === 'time' || type === 'datetime') {\n try {\n format = intl.getDatePattern({ skeleton: numberFormat, type: type }, isExcel);\n if (isNullOrUndefined(format)) {\n // eslint-disable-next-line\n throw 'error';\n }\n }\n catch (error) {\n try {\n format = intl.getDatePattern({ format: numberFormat, type: type }, isExcel);\n }\n catch (error) {\n format = numberFormat;\n }\n }\n }\n else {\n format = numberFormat;\n }\n if (type !== 'number') {\n var patternRegex = /G|H|c|'| a|yy|y|EEEE|E/g;\n var mtch_1 = { 'G': '', 'H': 'h', 'c': 'd', '\\'': '\"', ' a': ' AM/PM', 'yy': 'yy', 'y': 'yyyy', 'EEEE': 'dddd', 'E': 'ddd' };\n format = format.replace(patternRegex, function (pattern) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n return mtch_1[\"\" + pattern];\n });\n }\n return format;\n}\n/**\n * @param {IGrid} gObj - Grid instance\n * @returns {void}\n * @hidden\n */\nexport function addBiggerDialog(gObj) {\n if (gObj.enableAdaptiveUI) {\n var dialogs = document.getElementsByClassName('e-responsive-dialog');\n for (var i = 0; i < dialogs.length; i++) {\n dialogs[parseInt(i.toString(), 10)].classList.add('e-bigger');\n }\n }\n}\n/**\n * @param {string} value - specifies the trr\n * @param {Object} mapObject - specifies the idx\n * @returns {Object | string} returns object or string\n * @hidden\n */\nexport function performComplexDataOperation(value, mapObject) {\n var returnObj;\n var length = value.split('.').length;\n var splits = value.split('.');\n var duplicateMap = mapObject;\n for (var i = 0; i < length; i++) {\n returnObj = duplicateMap[splits[parseInt(i.toString(), 10)]];\n duplicateMap = returnObj;\n }\n return returnObj;\n}\n/**\n * @param {Object} tr - specifies the trr\n * @param {number} idx - specifies the idx\n * @param {string} displayVal - specifies the displayval\n * @param {Row<Column>} rows - specifies the rows\n * @param {IGrid} parent - Grid instance\n * @param {boolean} isContent - check for content renderer\n * @returns {void}\n * @hidden\n */\nexport function setDisplayValue(tr, idx, displayVal, rows, parent, isContent) {\n var trs = Object.keys(tr);\n var actualIndex = idx;\n for (var i = 0; i < trs.length; i++) {\n var td = tr[trs[parseInt(i.toString(), 10)]].querySelectorAll('td.e-rowcell')[parseInt(idx.toString(), 10)];\n if (parent && !parent.isFrozenGrid() && !parent.isRowDragable()) {\n td = (!isNullOrUndefined(td) && (parseInt(td.getAttribute('data-colindex'), 10) === idx))\n ? td : tr[parseInt(i.toString(), 10)].querySelector(\"td[data-colindex=\\\"\" + idx + \"\\\"]\");\n if (isNullOrUndefined(td)) {\n continue;\n }\n else {\n idx = (parent.getContentTable().querySelector('.e-detailrowcollapse, .e-detailrowexpand')) ?\n (td.cellIndex - 1) : td.cellIndex;\n }\n }\n if (tr[trs[parseInt(i.toString(), 10)]].querySelectorAll('td.e-rowcell').length && td) {\n setStyleAttribute(tr[trs[parseInt(i.toString(), 10)]].querySelectorAll('td.e-rowcell')[parseInt(idx.toString(), 10)], { 'display': displayVal });\n if (tr[trs[parseInt(i.toString(), 10)]].querySelectorAll('td.e-rowcell')[parseInt(idx.toString(), 10)].classList.contains('e-hide')) {\n removeClass([tr[trs[parseInt(i.toString(), 10)]].querySelectorAll('td.e-rowcell')[parseInt(idx.toString(), 10)]], ['e-hide']);\n }\n if ((isContent && parent.isRowDragable()) || (parent && parent.isDetail())) {\n var index = idx + 1;\n rows[trs[parseInt(i.toString(), 10)]].cells[parseInt(index.toString(), 10)].visible = displayVal === '' ? true : false;\n }\n else {\n if (!isNullOrUndefined(rows[trs[parseInt(i.toString(), 10)]])) {\n rows[trs[parseInt(i.toString(), 10)]].cells[parseInt(idx.toString(), 10)].visible = displayVal === '' ? true : false;\n if (rows[trs[parseInt(i.toString(), 10)]].cells[parseInt(idx.toString(), 10)].visible === false) {\n tr[trs[parseInt(i.toString(), 10)]].querySelectorAll('td.e-rowcell')[parseInt(idx.toString(), 10)].classList.add('e-hide');\n }\n }\n }\n idx = actualIndex;\n }\n }\n}\n// eslint-disable-next-line\n/** @hidden */\nexport function addRemoveEventListener(parent, evt, isOn, module) {\n for (var _i = 0, evt_1 = evt; _i < evt_1.length; _i++) {\n var inst = evt_1[_i];\n if (isOn) {\n parent.on(inst.event, inst.handler, module);\n }\n else {\n parent.off(inst.event, inst.handler);\n }\n }\n}\n// eslint-disable-next-line\n/** @hidden */\nexport function createEditElement(parent, column, classNames, attr) {\n var complexFieldName = getComplexFieldID(column.field);\n attr = Object.assign(attr, {\n id: parent.element.id + complexFieldName,\n name: complexFieldName, 'e-mappinguid': column.uid\n });\n return parent.createElement('input', {\n className: classNames, attrs: attr\n });\n}\n/**\n * @param {IGrid} gObj - Grid instance\n * @param {string} uid - Defines column's uid\n * @returns {Column} returns column model\n * @hidden\n */\nexport function getColumnModelByUid(gObj, uid) {\n var column;\n for (var _i = 0, _a = (gObj.columnModel); _i < _a.length; _i++) {\n var col = _a[_i];\n if (col.uid === uid) {\n column = col;\n break;\n }\n }\n return column;\n}\n/**\n * @param {IGrid} gObj - Grid instance\n * @param {string} field - Defines column's uid\n * @returns {Column} returns column model\n * @hidden\n */\nexport function getColumnModelByFieldName(gObj, field) {\n var column;\n if (!gObj.columnModel) {\n gObj.getColumns();\n }\n for (var _i = 0, _a = (gObj.columnModel); _i < _a.length; _i++) {\n var col = _a[_i];\n if (col.field === field) {\n column = col;\n break;\n }\n }\n return column;\n}\n/**\n * @param {string} id - Defines component id\n * @param {string[]} evts - Defines events\n * @param {object} handlers - Defines event handlers\n * @param {any} instance - Defines class instance\n * @returns {void}\n * @hidden\n */\n// eslint-disable-next-line\nexport function registerEventHandlers(id, evts, handlers, instance) {\n instance.eventHandlers[\"\" + id] = {};\n for (var i = 0; i < evts.length; i++) {\n instance.eventHandlers[\"\" + id][evts[parseInt(i.toString(), 10)]] = handlers[evts[parseInt(i.toString(), 10)]];\n }\n}\n/**\n * @param {any} component - Defines component instance\n * @param {string[]} evts - Defines events\n * @param {any} instance - Defines class instance\n * @returns {void}\n * @hidden\n */\n// eslint-disable-next-line\nexport function removeEventHandlers(component, evts, instance) {\n for (var i = 0; i < evts.length; i++) {\n if (component.isDestroyed) {\n break;\n }\n component.removeEventListener(evts[parseInt(i.toString(), 10)], instance.eventHandlers[component.element.id][evts[parseInt(i.toString(), 10)]]);\n }\n}\n/**\n * @param {IGrid | IXLFilter} parent - Defines parent instance\n * @param {string[]} templates - Defines the templates name which are needs to clear\n * @returns {void}\n * @hidden\n */\nexport function clearReactVueTemplates(parent, templates) {\n parent.destroyTemplate(templates);\n if (parent.isReact) {\n parent.renderTemplates();\n }\n}\n/**\n *\n * @param { Element } row - Defines row element\n * @returns { number } row index\n */\nexport function getRowIndexFromElement(row) {\n return parseInt(row.getAttribute(literals.dataRowIndex), 10);\n}\n/**\n *\n * @param { string[] } fields - Defines grouped fields\n * @param { values } values - Defines caption keys\n * @param { any } instance - Defines dynamic class instance\n * @returns { Predicate } returns filter predicate\n */\n// eslint-disable-next-line\nexport function generateExpandPredicates(fields, values, instance) {\n var filterCols = [];\n for (var i = 0; i < fields.length; i++) {\n var column = instance.parent.getColumnByField(fields[parseInt(i.toString(), 10)]);\n var value = values[parseInt(i.toString(), 10)] === 'null' ? null : values[parseInt(i.toString(), 10)];\n var pred = {\n field: fields[parseInt(i.toString(), 10)], predicate: 'or', uid: column.uid, operator: 'equal', type: column.type,\n matchCase: instance.allowCaseSensitive, ignoreAccent: instance.parent.filterSettings.ignoreAccent\n };\n if (value === '' || isNullOrUndefined(value)) {\n filterCols = filterCols.concat(CheckBoxFilterBase.generateNullValuePredicates(pred));\n }\n else {\n filterCols.push(extend({}, { value: value }, pred));\n }\n }\n return CheckBoxFilterBase.getPredicate(filterCols);\n}\n/**\n *\n * @param { Predicate } pred - Defines filter predicate\n * @returns { Predicate[] } Returns formed predicate\n */\nexport function getPredicates(pred) {\n var predicateList = [];\n for (var _i = 0, _a = Object.keys(pred); _i < _a.length; _i++) {\n var prop = _a[_i];\n predicateList.push(pred[\"\" + prop]);\n }\n return predicateList;\n}\n/**\n *\n * @param { number } index - Defines group caption indent\n * @param { Row<Column>[] } rowsObject - Defines rows object\n * @returns { { fields: string[], keys: string[] } } Returns grouped keys and values\n */\nexport function getGroupKeysAndFields(index, rowsObject) {\n var fields = [];\n var keys = [];\n for (var i = index; i >= 0; i--) {\n if (rowsObject[parseInt(i.toString(), 10)].isCaptionRow\n && fields.indexOf(rowsObject[parseInt(i.toString(), 10)].data.field) === -1\n && (rowsObject[parseInt(i.toString(), 10)].indent < rowsObject[parseInt(index.toString(), 10)].indent || i === index)) {\n fields.push(rowsObject[parseInt(i.toString(), 10)].data.field);\n keys.push(rowsObject[parseInt(i.toString(), 10)].data.key);\n if (rowsObject[parseInt(i.toString(), 10)].indent === 0) {\n break;\n }\n }\n }\n return { fields: fields, keys: keys };\n}\n// eslint-disable-next-line\n/**\n *\n * @param { number[][] } checkActiveMatrix - Defines matrix to check\n * @param { number[] } checkCellIndex - Defines index to check\n * @param { boolean } next - Defines select next or previous index\n * @returns { number[] } - Returns next active current index\n */\nexport function findCellIndex(checkActiveMatrix, checkCellIndex, next) {\n var activeMatrix = checkActiveMatrix;\n var cellIndex = checkCellIndex;\n var currentCellIndexPass = false;\n if (next) {\n for (var i = cellIndex[0]; i < activeMatrix.length; i++) {\n var rowCell = activeMatrix[parseInt(i.toString(), 10)];\n for (var j = 0; j < rowCell.length; j++) {\n if (currentCellIndexPass && activeMatrix[parseInt(i.toString(), 10)][parseInt(j.toString(), 10)] === 1) {\n cellIndex = [i, j];\n return cellIndex;\n }\n if (!currentCellIndexPass && cellIndex.toString() === [i, j].toString()) {\n currentCellIndexPass = true;\n }\n }\n }\n }\n else {\n for (var i = cellIndex[0]; i >= 0; i--) {\n var rowCell = activeMatrix[parseInt(i.toString(), 10)];\n for (var j = rowCell.length - 1; j >= 0; j--) {\n if (currentCellIndexPass && activeMatrix[parseInt(i.toString(), 10)][parseInt(j.toString(), 10)] === 1) {\n cellIndex = [i, j];\n return cellIndex;\n }\n if (!currentCellIndexPass && cellIndex.toString() === [i, j].toString()) {\n currentCellIndexPass = true;\n }\n }\n }\n }\n return cellIndex;\n}\n/**\n *\n * @param { string } string - Defines string need to capitalized first letter\n * @returns { string } - Returns capitalized first letter string\n */\nexport function capitalizeFirstLetter(string) {\n return string.charAt(0).toUpperCase() + string.slice(1);\n}\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/* eslint-disable jsdoc/require-returns */\n/* eslint-disable jsdoc/require-param */\n/* eslint-disable valid-jsdoc */\nimport { Animation, compile as templateComplier, Browser } from '@syncfusion/ej2-base';\nimport { merge, extend, isNullOrUndefined, resetBlazorTemplate } from '@syncfusion/ej2-base';\nimport { createElement, remove } from '@syncfusion/ej2-base';\nimport { Index } from '../../common/model/base';\nimport { VisibleLabels } from '../../chart/axis/axis';\nimport { axisLabelRender, regSub } from '../model/constants';\nimport { measureText, Rect, TextOption, Size, PathOption, SvgRenderer, CanvasRenderer } from '@syncfusion/ej2-svg-base';\n/**\n * Function to sort the dataSource, by default it sort the data in ascending order.\n *\n * @param {Object} data chart data\n * @param {string} fields date fields\n * @param {boolean} isDescending boolean values of descending\n * @returns {Object[]} It returns chart data which be sorted.\n */\nexport function sort(data, fields, isDescending) {\n var sortData = extend([], data, null);\n for (var i = 0; i < sortData.length; i++) {\n for (var j = 0; j < fields.length; j++) {\n if (sortData[i][fields[j]] instanceof Date) {\n sortData[i][fields[j]] = sortData[i][fields[j]].getTime();\n }\n }\n }\n sortData.sort(function (a, b) {\n var first = 0;\n var second = 0;\n for (var i = 0; i < fields.length; i++) {\n first += a[fields[i]];\n second += b[fields[i]];\n }\n if ((!isDescending && first < second) || (isDescending && first > second)) {\n return -1;\n }\n else if (first === second) {\n return 0;\n }\n return 1;\n });\n return sortData;\n}\n/** @private */\nexport function isBreakLabel(label) {\n return label.indexOf('<br>') !== -1;\n}\n/** @private */\nexport function getVisiblePoints(series) {\n var points = extend([], series.points, null, true);\n var tempPoints = [];\n var tempPoint;\n var pointIndex = 0;\n for (var i = 0; i < points.length; i++) {\n tempPoint = points[i];\n if (isNullOrUndefined(tempPoint.x)) {\n continue;\n }\n else {\n tempPoint.index = pointIndex++;\n tempPoints.push(tempPoint);\n }\n }\n return tempPoints;\n}\n/** @private */\nexport function rotateTextSize(font, text, angle, chart) {\n var transformValue = chart.element.style.transform;\n if (transformValue) {\n chart.element.style.transform = '';\n }\n var renderer = new SvgRenderer(chart.element.id);\n var labelText;\n var textCollection = [];\n var height;\n var dy;\n var label;\n var tspanElement;\n var options = {\n id: 'rotate_text',\n x: chart.initialClipRect.x,\n y: chart.initialClipRect.y,\n 'font-size': font.size,\n 'font-style': font.fontStyle,\n 'font-family': font.fontFamily,\n 'font-weight': font.fontWeight,\n 'transform': 'rotate(' + angle + ', 0, 0)',\n 'text-anchor': 'middle'\n };\n if (isBreakLabel(text)) {\n textCollection = text.split('<br>');\n labelText = textCollection[0];\n }\n else {\n labelText = text;\n }\n var htmlObject = renderer.createText(options, labelText);\n if (!chart.delayRedraw && !chart.redraw && !chart.stockChart) {\n chart.element.appendChild(chart.svgObject);\n }\n // for line break label\n if (typeof textCollection !== 'string' && textCollection.length > 1) {\n for (var i = 1, len = textCollection.length; i < len; i++) {\n height = (measureText(textCollection[i], font, chart.themeStyle.axisLabelFont).height);\n dy = (options.y) + ((i * height));\n label = textCollection[i];\n tspanElement = renderer.createTSpan({\n 'x': options.x, 'id': options.id,\n 'y': dy\n }, label);\n htmlObject.appendChild(tspanElement);\n }\n }\n chart.svgObject.appendChild(htmlObject);\n var box = htmlObject.getBoundingClientRect();\n if (transformValue) {\n chart.element.style.transform = transformValue;\n }\n remove(htmlObject);\n if (!chart.delayRedraw && !chart.redraw && !chart.stockChart) {\n remove(chart.svgObject);\n }\n if (chart.enableCanvas) {\n var textWidth = measureText(text, font, chart.themeStyle.axisLabelFont).width;\n var textHeight = measureText(text, font, chart.themeStyle.axisLabelFont).height;\n var angleInRadians = (angle * Math.PI) / 180; // Convert the rotation angle to radians\n var rotatedTextWidth = Math.abs(Math.cos(angleInRadians) * textWidth) + Math.abs(Math.sin(angleInRadians) * textHeight);\n var rotatedTextHeight = Math.abs(Math.sin(angleInRadians) * textWidth) + Math.abs(Math.cos(angleInRadians) * textHeight);\n return new Size(rotatedTextWidth, rotatedTextHeight);\n }\n return new Size((box.right - box.left), (box.bottom - box.top));\n}\n/** @private */\nexport function removeElement(id) {\n if (!id) {\n return null;\n }\n var element = typeof id === 'string' ? getElement(id) : id;\n if (element) {\n remove(element);\n }\n}\n/** @private */\nexport function logBase(value, base) {\n return Math.log(value) / Math.log(base);\n}\n/** @private */\nexport function showTooltip(text, x, y, areaWidth, id, element, isTouch, isTitleOrLegendEnabled) {\n //let id1: string = 'EJ2_legend_tooltip';\n var tooltip = document.getElementById(id);\n var size = measureText(text, {\n fontFamily: 'Segoe UI', size: '12px',\n fontStyle: 'Normal', fontWeight: 'Regular'\n });\n var width = size.width + 5;\n x = (x + width > areaWidth) ? x - (width + 15) : x;\n y = isTitleOrLegendEnabled ? (y - size.height / 2) : y + 15;\n if (!tooltip) {\n tooltip = createElement('div', {\n id: id,\n styles: 'top:' + (y).toString() + 'px;left:' + (x + 15).toString() +\n 'px;background-color: rgb(255, 255, 255) !important; color:black !important; ' +\n 'position:absolute;border:1px solid rgb(112, 112, 112); padding-left : 3px; padding-right : 2px;' +\n 'padding-bottom : 2px; padding-top : 2px; font-size:12px; font-family: \"Segoe UI\"'\n });\n tooltip.innerText = text;\n element.appendChild(tooltip);\n var left = parseInt(tooltip.style.left.replace('px', ''), 10);\n if (left < 0) {\n tooltip.style.left = '0px';\n }\n }\n else {\n tooltip.innerText = text;\n tooltip.style.top = (y).toString() + 'px';\n tooltip.style.left = (x + 15).toString() + 'px';\n }\n if (isTouch) {\n setTimeout(function () { removeElement(id); }, 1500);\n }\n}\n/** @private */\nexport function inside(value, range) {\n return (value < range.max) && (value > range.min);\n}\n/** @private */\nexport function withIn(value, range) {\n return (value <= range.max) && (value >= range.min);\n}\n/** @private */\nexport function logWithIn(value, axis) {\n return axis.valueType === 'Logarithmic' ? logBase(value, axis.logBase) : value;\n}\n/** @private */\nexport function withInRange(previousPoint, currentPoint, nextPoint, series) {\n var mX2 = logWithIn(currentPoint.xValue, series.xAxis);\n var mX1 = previousPoint ? logWithIn(previousPoint.xValue, series.xAxis) : mX2;\n var mX3 = nextPoint ? logWithIn(nextPoint.xValue, series.xAxis) : mX2;\n var xStart = Math.floor(series.xAxis.visibleRange.min);\n var xEnd = Math.ceil(series.xAxis.visibleRange.max);\n return ((mX1 >= xStart && mX1 <= xEnd) || (mX2 >= xStart && mX2 <= xEnd) ||\n (mX3 >= xStart && mX3 <= xEnd) || (xStart >= mX1 && xStart <= mX3));\n}\n/** @private */\nexport function sum(values) {\n var sum = 0;\n for (var _i = 0, values_1 = values; _i < values_1.length; _i++) {\n var value = values_1[_i];\n sum += value;\n }\n return sum;\n}\n/** @private */\nexport function subArraySum(values, first, last, index, series) {\n var sum = 0;\n if (index !== null) {\n for (var i = (first + 1); i < last; i++) {\n if (index.indexOf(i) === -1) {\n sum += values[i][series.yName];\n }\n }\n }\n else {\n for (var i = (first + 1); i < last; i++) {\n if (!isNullOrUndefined(values[i][series.yName])) {\n sum += values[i][series.yName];\n }\n }\n }\n return sum;\n}\n/** @private */\nexport function subtractThickness(rect, thickness) {\n rect.x += thickness.left;\n rect.y += thickness.top;\n rect.width -= thickness.left + thickness.right;\n rect.height -= thickness.top + thickness.bottom;\n return rect;\n}\n/** @private */\nexport function subtractRect(rect, thickness) {\n rect.x += thickness.x;\n rect.y += thickness.y;\n rect.width -= thickness.x + thickness.width;\n rect.height -= thickness.y + thickness.height;\n return rect;\n}\n/** @private */\nexport function degreeToLocation(degree, radius, center) {\n var radian = (degree * Math.PI) / 180;\n return new ChartLocation(Math.cos(radian) * radius + center.x, Math.sin(radian) * radius + center.y);\n}\n/** @private */\nexport function degreeToRadian(degree) {\n return degree * (Math.PI / 180);\n}\n/** @private */\nexport function getRotatedRectangleCoordinates(actualPoints, centerX, centerY, angle) {\n var coordinatesAfterRotation = [];\n for (var i = 0; i < 4; i++) {\n var point = actualPoints[i];\n // translate point to origin\n var tempX = point.x - centerX;\n var tempY = point.y - centerY;\n // now apply rotation\n var rotatedX = tempX * Math.cos(degreeToRadian(angle)) - tempY * Math.sin(degreeToRadian(angle));\n var rotatedY = tempX * Math.sin(degreeToRadian(angle)) + tempY * Math.cos(degreeToRadian(angle));\n // translate back\n point.x = rotatedX + centerX;\n point.y = rotatedY + centerY;\n coordinatesAfterRotation.push(new ChartLocation(point.x, point.y));\n }\n return coordinatesAfterRotation;\n}\n/**\n * Helper function to determine whether there is an intersection between the two polygons described\n * by the lists of vertices. Uses the Separating Axis Theorem\n *\n * @param {ChartLocation[]} a an array of connected points [{x:, y:}, {x:, y:},...] that form a closed polygon\n * @param {ChartLocation[]} b an array of connected points [{x:, y:}, {x:, y:},...] that form a closed polygon\n * @returns {boolean} if there is any intersection between the 2 polygons, false otherwise\n */\nexport function isRotatedRectIntersect(a, b) {\n var polygons = [a, b];\n var minA;\n var maxA;\n var projected;\n var i;\n var i1;\n var j;\n var minB;\n var maxB;\n for (i = 0; i < polygons.length; i++) {\n // for each polygon, look at each edge of the polygon, and determine if it separates\n // the two shapes\n var polygon = polygons[i];\n for (i1 = 0; i1 < polygon.length; i1++) {\n // grab 2 vertices to create an edge\n var i2 = (i1 + 1) % polygon.length;\n var p1 = polygon[i1];\n var p2 = polygon[i2];\n // find the line perpendicular to this edge\n var normal = new ChartLocation(p2.y - p1.y, p1.x - p2.x);\n minA = maxA = undefined;\n // for each vertex in the first shape, project it onto the line perpendicular to the edge\n // and keep track of the min and max of these values\n for (j = 0; j < a.length; j++) {\n projected = normal.x * a[j].x + normal.y * a[j].y;\n if (isNullOrUndefined(minA) || projected < minA) {\n minA = projected;\n }\n if (isNullOrUndefined(maxA) || projected > maxA) {\n maxA = projected;\n }\n }\n // for each vertex in the second shape, project it onto the line perpendicular to the edge\n // and keep track of the min and max of these values\n minB = maxB = undefined;\n for (j = 0; j < b.length; j++) {\n projected = normal.x * b[j].x + normal.y * b[j].y;\n if (isNullOrUndefined(minB) || projected < minB) {\n minB = projected;\n }\n if (isNullOrUndefined(maxB) || projected > maxB) {\n maxB = projected;\n }\n }\n // if there is no overlap between the projects, the edge we are looking at separates the two\n // polygons, and we know there is no overlap\n if (maxA < minB || maxB < minA) {\n return false;\n }\n }\n }\n return true;\n}\n/** @private */\nfunction getAccumulationLegend(locX, locY, r, height, width, mode) {\n var cartesianlarge = degreeToLocation(270, r, new ChartLocation(locX, locY));\n var cartesiansmall = degreeToLocation(270, r, new ChartLocation(locX + (width / 10), locY));\n return 'M' + ' ' + locX + ' ' + locY + ' ' + 'L' + ' ' + (locX + r) + ' ' + (locY) + ' ' + 'A' + ' ' + (r) + ' ' + (r) +\n ' ' + 0 + ' ' + 1 + ' ' + 1 + ' ' + cartesianlarge.x + ' ' + cartesianlarge.y + ' ' + 'Z' + ' ' + 'M' + ' ' + (locX +\n (width / 10)) + ' ' + (locY - (height / 10)) + ' ' + 'L' + (locX + (r)) + ' ' + (locY - height / 10) + ' ' + 'A' + ' '\n + (r) + ' ' + (r) + ' ' + 0 + ' ' + 0 + ' ' + 0 + ' ' + cartesiansmall.x + ' ' + cartesiansmall.y + ' ' + 'Z';\n}\n/** @private */\nexport function getAngle(center, point) {\n var angle = Math.atan2((point.y - center.y), (point.x - center.x));\n angle = angle < 0 ? (6.283 + angle) : angle;\n return angle * (180 / Math.PI);\n}\n/** @private */\nexport function subArray(values, index) {\n var subArray = [];\n for (var i = 0; i <= index - 1; i++) {\n subArray.push(values[i]);\n }\n return subArray;\n}\n/** @private */\nexport function valueToCoefficient(value, axis) {\n var range = axis.visibleRange;\n var result = (value - range.min) / (range.delta);\n var isInverse = axis.isChart ? axis.isAxisInverse : axis.isInversed;\n return isInverse ? (1 - result) : result;\n}\n/** @private */\nexport function TransformToVisible(x, y, xAxis, yAxis, isInverted, series) {\n x = (xAxis.valueType === 'Logarithmic' ? logBase(x > 1 ? x : 1, xAxis.logBase) : x);\n y = (yAxis.valueType === 'Logarithmic' ?\n logBase(y > 1 ? y : 1, yAxis.logBase) : y);\n x += xAxis.valueType === 'Category' && xAxis.labelPlacement === 'BetweenTicks' && series.type !== 'Radar' ? 0.5 : 0;\n var radius = series.chart.radius * valueToCoefficient(y, yAxis);\n var point = CoefficientToVector(valueToPolarCoefficient(x, xAxis), series.chart.primaryXAxis.startAngle);\n return {\n x: (series.clipRect.width / 2 + series.clipRect.x) + radius * point.x,\n y: (series.clipRect.height / 2 + series.clipRect.y) + radius * point.y\n };\n}\n/**\n * method to find series, point index by element id\n *\n * @private\n */\nexport function indexFinder(id, isPoint) {\n if (isPoint === void 0) { isPoint = false; }\n var ids = ['NaN', 'NaN'];\n if (id.indexOf('_Point_') > -1) {\n ids = id.split('_Series_')[1].split('_Point_');\n }\n else if (id.indexOf('_shape_') > -1 && (!isPoint || (isPoint && id.indexOf('_legend_') === -1))) {\n ids = id.split('_shape_');\n ids[0] = '0';\n }\n else if (id.indexOf('_text_') > -1 && (!isPoint || (isPoint && id.indexOf('_legend_') === -1))) {\n ids = id.split('_text_');\n ids[0] = '0';\n }\n return new Index(parseInt(ids[0], 10), parseInt(ids[1], 10));\n}\n/** @private */\nexport function CoefficientToVector(coefficient, startAngle) {\n startAngle = startAngle < 0 ? startAngle + 360 : startAngle;\n var angle = Math.PI * (1.5 - 2 * coefficient);\n angle = angle + (startAngle * Math.PI) / 180;\n return { x: Math.cos(angle), y: Math.sin(angle) };\n}\n/** @private */\nexport function valueToPolarCoefficient(value, axis) {\n var range = axis.visibleRange;\n var delta;\n var length;\n if (axis.valueType !== 'Category') {\n delta = (range.max - (axis.valueType === 'DateTime' ? axis.dateTimeInterval : range.interval)) - range.min;\n length = axis.visibleLabels.length - 1;\n delta = delta === 0 ? 1 : delta;\n }\n else {\n // To split an interval equally based on visible labels count\n delta = axis.visibleLabels.length === 1 ? 1 :\n (axis.visibleLabels[axis.visibleLabels.length - 1].value - axis.visibleLabels[0].value);\n length = axis.visibleLabels.length;\n }\n return axis.isAxisInverse ? ((value - range.min) / delta) * (1 - 1 / (length)) :\n 1 - ((value - range.min) / delta) * (1 - 1 / (length));\n}\n/** @private */\nvar Mean = /** @class */ (function () {\n function Mean(verticalStandardMean, verticalSquareRoot, horizontalStandardMean, horizontalSquareRoot, verticalMean, horizontalMean) {\n this.verticalStandardMean = verticalStandardMean;\n this.horizontalStandardMean = horizontalStandardMean;\n this.verticalSquareRoot = verticalSquareRoot;\n this.horizontalSquareRoot = horizontalSquareRoot;\n this.verticalMean = verticalMean;\n this.horizontalMean = horizontalMean;\n }\n return Mean;\n}());\nexport { Mean };\n/** @private */\nvar PolarArc = /** @class */ (function () {\n function PolarArc(startAngle, endAngle, innerRadius, radius, currentXPosition) {\n this.startAngle = startAngle;\n this.endAngle = endAngle;\n this.innerRadius = innerRadius;\n this.radius = radius;\n this.currentXPosition = currentXPosition;\n }\n return PolarArc;\n}());\nexport { PolarArc };\n/** @private */\nexport function createTooltip(id, text, top, left, fontSize) {\n var tooltip = getElement(id);\n var style = 'top:' + top.toString() + 'px;' +\n 'left:' + left.toString() + 'px;' +\n 'color:black !important; ' +\n 'background:#FFFFFF !important; ' +\n 'position:absolute;border:1px solid #707070;font-size:' + fontSize + ';border-radius:2px; z-index:1';\n if (!tooltip) {\n tooltip = createElement('div', {\n id: id, innerHTML: ' ' + text + ' ', styles: style\n });\n document.body.appendChild(tooltip);\n }\n else {\n tooltip.setAttribute('innerHTML', ' ' + text + ' ');\n tooltip.setAttribute('styles', style);\n }\n}\n/** @private */\nexport function createZoomingLabels(chart, axis, parent, index, isVertical, rect) {\n var margin = 5;\n var opposedPosition = axis.isAxisOpposedPosition;\n var anchor = chart.enableRtl ? 'end' : isVertical ? 'start' : 'auto';\n var size;\n var chartRect = chart.availableSize.width;\n var pathElement;\n var x;\n var y;\n var rx = 3;\n var arrowLocation;\n var direction;\n var scrollBarHeight = axis.scrollbarSettings.enable || (axis.zoomingScrollBar && axis.zoomingScrollBar.svgObject)\n ? axis.scrollBarHeight : 0;\n var isRtlEnabled = (chart.enableRtl && !isVertical && !axis.isInversed) || (axis.isInversed && !(chart.enableRtl && !isVertical));\n for (var i = 0; i < 2; i++) {\n size = measureText(i ? (isRtlEnabled ? axis.startLabel : axis.endLabel) : (isRtlEnabled ? axis.endLabel : axis.startLabel), axis.labelStyle, chart.themeStyle.axisLabelFont);\n if (isVertical) {\n arrowLocation = i ? new ChartLocation(rect.x - scrollBarHeight, rect.y + rx) :\n new ChartLocation(axis.rect.x - scrollBarHeight, (rect.y + rect.height - rx));\n x = (rect.x + (opposedPosition ? (rect.width + margin + scrollBarHeight) : -(size.width + margin + margin + scrollBarHeight)));\n y = (rect.y + (i ? 0 : rect.height - size.height - margin));\n x += (x < 0 || ((chartRect) < (x + size.width + margin))) ? (opposedPosition ? -(size.width / 2) : size.width / 2) : 0;\n direction = findCrosshairDirection(rx, rx, new Rect(x, y, size.width + margin, size.height + margin), arrowLocation, margin, false, false, !opposedPosition, arrowLocation.x, arrowLocation.y + (i ? -rx : rx));\n }\n else {\n arrowLocation = i ? new ChartLocation((rect.x + rect.width - rx), (rect.y + rect.height + scrollBarHeight)) :\n new ChartLocation(rect.x + rx, (rect.y + rect.height + scrollBarHeight));\n x = (rect.x + (i ? (rect.width - size.width - margin) : 0));\n y = (opposedPosition ? (rect.y - size.height - 10 - scrollBarHeight) : (rect.y + rect.height + margin + scrollBarHeight));\n direction = findCrosshairDirection(rx, rx, new Rect(x, y, size.width + margin, size.height + margin), arrowLocation, margin, opposedPosition, !opposedPosition, false, arrowLocation.x + (i ? rx : -rx), arrowLocation.y);\n }\n x = x + (margin / 2);\n y = y + (3 * (size.height / 4)) + (margin / 2);\n pathElement = chart.renderer.drawPath({\n 'id': chart.element.id + '_Zoom_' + index + '_AxisLabel_Shape_' + i,\n 'fill': chart.themeStyle.crosshairFill, 'width': 2, 'color': chart.themeStyle.crosshairFill,\n 'opacity': 1, 'stroke-dasharray': null, 'd': direction\n }, null);\n parent.appendChild(pathElement);\n if (chart.theme === 'Fluent' || chart.theme === 'FluentDark') {\n var shadowId = chart.element.id + '_shadow';\n pathElement.setAttribute('filter', Browser.isIE ? '' : 'url(#' + shadowId + ')');\n var shadow = '<filter id=\"' + shadowId + '\" height=\"130%\"><feGaussianBlur in=\"SourceAlpha\" stdDeviation=\"3\"/>';\n shadow += '<feOffset dx=\"3\" dy=\"3\" result=\"offsetblur\"/><feComponentTransfer><feFuncA type=\"linear\" slope=\"0.5\"/>';\n shadow += '</feComponentTransfer><feMerge><feMergeNode/><feMergeNode in=\"SourceGraphic\"/></feMerge></filter>';\n var defElement = chart.renderer.createDefs();\n defElement.setAttribute('id', chart.element.id + 'SVG_tooltip_definition');\n parent.appendChild(defElement);\n defElement.innerHTML = shadow;\n pathElement.setAttribute('stroke', '#cccccc');\n pathElement.setAttribute('stroke-width', '0.5');\n }\n textElement(chart.renderer, new TextOption(chart.element.id + '_Zoom_' + index + '_AxisLabel_' + i, x, y, anchor, i ? (isRtlEnabled ? axis.startLabel : axis.endLabel) : (isRtlEnabled ? axis.endLabel : axis.startLabel)), { color: chart.themeStyle.crosshairLabelFont.color, fontFamily: 'Segoe UI', fontWeight: 'Regular', size: '11px' }, chart.themeStyle.crosshairLabelFont.color, parent, null, null, null, null, null, null, null, null, null, null, chart.themeStyle.crosshairLabelFont);\n }\n return parent;\n}\n/** @private */\nexport function findCrosshairDirection(rX, rY, rect, arrowLocation, arrowPadding, top, bottom, left, tipX, tipY) {\n var direction = '';\n var startX = rect.x;\n var startY = rect.y;\n var width = rect.x + rect.width;\n var height = rect.y + rect.height;\n if (top) {\n direction = direction.concat('M' + ' ' + (startX) + ' ' + (startY + rY) + ' Q ' + startX + ' '\n + startY + ' ' + (startX + rX) + ' ' + startY);\n direction = direction.concat(' L' + ' ' + (width - rX) + ' ' + (startY) + ' Q ' + width + ' '\n + startY + ' ' + (width) + ' ' + (startY + rY));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (height - rY) + ' Q ' + width + ' '\n + (height) + ' ' + (width - rX) + ' ' + (height));\n if (arrowPadding !== 0) {\n direction = direction.concat(' L' + ' ' + (arrowLocation.x + arrowPadding / 2) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (tipX) + ' ' + (height + arrowPadding)\n + ' L' + ' ' + (arrowLocation.x - arrowPadding / 2) + ' ' + height);\n }\n if ((arrowLocation.x - arrowPadding / 2) > startX) {\n direction = direction.concat(' L' + ' ' + (startX + rX) + ' ' + height + ' Q ' + startX + ' '\n + height + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else {\n if (arrowPadding === 0) {\n direction = direction.concat(' L' + ' ' + (startX + rX) + ' ' + height + ' Q ' + startX + ' '\n + height + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else {\n direction = direction.concat(' L' + ' ' + (startX) + ' ' + (height + rY) + ' z');\n }\n }\n }\n else if (bottom) {\n direction = direction.concat('M' + ' ' + (startX) + ' ' + (startY + rY) + ' Q ' + startX + ' '\n + (startY) + ' ' + (startX + rX) + ' ' + (startY) + ' L' + ' ' + (arrowLocation.x - arrowPadding / 2) + ' ' + (startY));\n direction = direction.concat(' L' + ' ' + (tipX) + ' ' + (arrowLocation.y));\n direction = direction.concat(' L' + ' ' + (arrowLocation.x + arrowPadding / 2) + ' ' + (startY));\n direction = direction.concat(' L' + ' ' + (width - rX) + ' ' + (startY)\n + ' Q ' + (width) + ' ' + (startY) + ' ' + (width) + ' ' + (startY + rY));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (height - rY) + ' Q ' + (width) + ' '\n + (height) + ' ' + (width - rX) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (startX + rX) + ' ' + (height) + ' Q ' + (startX) + ' '\n + (height) + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else if (left) {\n direction = direction.concat('M' + ' ' + (startX) + ' ' + (startY + rY) + ' Q ' + startX + ' '\n + (startY) + ' ' + (startX + rX) + ' ' + (startY));\n direction = direction.concat(' L' + ' ' + (width - rX) + ' ' + (startY) + ' Q ' + (width) + ' '\n + (startY) + ' ' + (width) + ' ' + (startY + rY) + ' L' + ' ' + (width) + ' ' + (arrowLocation.y - arrowPadding / 2));\n direction = direction.concat(' L' + ' ' + (width + arrowPadding) + ' ' + (tipY));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (arrowLocation.y + arrowPadding / 2));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (height - rY) + ' Q ' + width + ' ' + (height) + ' ' + (width - rX) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (startX + rX) + ' ' + (height) + ' Q ' + startX + ' '\n + (height) + ' ' + (startX) + ' ' + (height - rY) + ' z');\n }\n else {\n direction = direction.concat('M' + ' ' + (startX + rX) + ' ' + (startY) + ' Q ' + (startX) + ' '\n + (startY) + ' ' + (startX) + ' ' + (startY + rY) + ' L' + ' ' + (startX) + ' ' + (arrowLocation.y - arrowPadding / 2));\n direction = direction.concat(' L' + ' ' + (startX - arrowPadding) + ' ' + (tipY));\n direction = direction.concat(' L' + ' ' + (startX) + ' ' + (arrowLocation.y + arrowPadding / 2));\n direction = direction.concat(' L' + ' ' + (startX) + ' ' + (height - rY) + ' Q ' + startX + ' '\n + (height) + ' ' + (startX + rX) + ' ' + (height));\n direction = direction.concat(' L' + ' ' + (width - rX) + ' ' + (height) + ' Q ' + width + ' '\n + (height) + ' ' + (width) + ' ' + (height - rY));\n direction = direction.concat(' L' + ' ' + (width) + ' ' + (startY + rY) + ' Q ' + width + ' '\n + (startY) + ' ' + (width - rX) + ' ' + (startY) + ' z');\n }\n return direction;\n}\n//Within bounds\n/** @private */\nexport function withInBounds(x, y, bounds, width, height) {\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n return (x >= bounds.x - width && x <= bounds.x + bounds.width + width && y >= bounds.y - height\n && y <= bounds.y + bounds.height + height);\n}\n/** @private */\nexport function getValueXByPoint(value, size, axis) {\n var actualValue = !axis.isAxisInverse ? value / size : (1 - (value / size));\n return actualValue * (axis.visibleRange.delta) + axis.visibleRange.min;\n}\n/** @private */\nexport function getValueYByPoint(value, size, axis) {\n var actualValue = axis.isAxisInverse ? value / size : (1 - (value / size));\n return actualValue * (axis.visibleRange.delta) + axis.visibleRange.min;\n}\n/** @private */\nexport function findClipRect(series, isCanvas) {\n if (isCanvas === void 0) { isCanvas = false; }\n var rect = series.clipRect;\n if (isCanvas && (series.type === 'Polar' || series.type === 'Radar')) {\n if (series.drawType === 'Scatter') {\n rect.x = series.xAxis.rect.x;\n rect.y = series.yAxis.rect.y;\n rect.width = series.xAxis.rect.width;\n rect.height = series.yAxis.rect.height;\n }\n else {\n rect.x = series.xAxis.rect.x / 2;\n rect.y = series.yAxis.rect.y / 2;\n rect.width = series.xAxis.rect.width;\n rect.height = series.yAxis.rect.height;\n }\n }\n else {\n if (series.chart.requireInvertedAxis) {\n rect.x = series.yAxis.rect.x;\n rect.y = series.xAxis.rect.y;\n rect.width = series.yAxis.rect.width;\n rect.height = series.xAxis.rect.height;\n }\n else {\n rect.x = series.xAxis.rect.x;\n rect.y = series.yAxis.rect.y;\n rect.width = series.xAxis.rect.width;\n rect.height = series.yAxis.rect.height;\n }\n }\n}\n/** @private */\nexport function firstToLowerCase(str) {\n return str.substr(0, 1).toLowerCase() + str.substr(1);\n}\n/** @private */\nexport function getTransform(xAxis, yAxis, invertedAxis) {\n var x;\n var y;\n var width;\n var height;\n if (invertedAxis) {\n x = yAxis.rect.x;\n y = xAxis.rect.y;\n width = yAxis.rect.width;\n height = xAxis.rect.height;\n }\n else {\n x = xAxis.rect.x;\n y = yAxis.rect.y;\n width = xAxis.rect.width;\n height = yAxis.rect.height;\n }\n return new Rect(x, y, width, height);\n}\n/** @private */\nexport function getMinPointsDelta(axis, seriesCollection) {\n var minDelta = Number.MAX_VALUE;\n var xValues;\n var minVal;\n var seriesMin;\n var stackingGroups = [];\n for (var index = 0; index < seriesCollection.length; index++) {\n var series = seriesCollection[index];\n xValues = [];\n if (series.visible &&\n (axis.name === series.xAxisName || (axis.name === 'primaryXAxis' && series.xAxisName === null)\n || (axis.name === series.chart.primaryXAxis.name && !series.xAxisName))) {\n if (series.type.indexOf('Stacking') > -1 && stackingGroups.indexOf(series.stackingGroup) === -1) {\n stackingGroups.push(series.stackingGroup);\n }\n xValues = series.points.map(function (point) {\n return point.xValue;\n });\n xValues.sort(function (first, second) { return first - second; });\n if (xValues.length === 1) {\n seriesMin = (axis.valueType === 'DateTime' && series.xMin === series.xMax) ? (series.xMin - 25920000) : series.xMin;\n minVal = xValues[0] - (!isNullOrUndefined(seriesMin) ?\n seriesMin : axis.visibleRange.min);\n if (minVal !== 0) {\n minDelta = Math.min(minDelta, minVal);\n }\n }\n else {\n for (var index_1 = 0; index_1 < xValues.length; index_1++) {\n var value = xValues[index_1];\n if (index_1 > 0 && value) {\n minVal = series.type.indexOf('Stacking') > -1 && axis.valueType == \"Category\" ? stackingGroups.length : value - xValues[index_1 - 1];\n if (minVal !== 0) {\n minDelta = Math.min(minDelta, minVal);\n }\n }\n }\n }\n }\n }\n if (minDelta === Number.MAX_VALUE) {\n minDelta = 1;\n }\n return minDelta;\n}\n/** @private */\nexport function getAnimationFunction(effect) {\n var functionName;\n switch (effect) {\n case 'Linear':\n functionName = linear;\n break;\n }\n return functionName;\n}\n/**\n * Animation Effect Calculation Started Here\n *\n * @param {number} currentTime currentTime\n * @param {number} startValue startValue of the animation\n * @param {number} endValue endValue of the animation\n * @param {number} duration duration of the animation\n * @private\n */\nexport function linear(currentTime, startValue, endValue, duration) {\n return -endValue * Math.cos(currentTime / duration * (Math.PI / 2)) + endValue + startValue;\n}\n/**\n * Animation Effect Calculation End\n *\n * @private\n */\nexport function markerAnimate(element, delay, duration, series, pointIndex, point, isLabel) {\n var centerX = point.x;\n var centerY = point.y;\n var height = 0;\n element.style.visibility = 'hidden';\n var transform = element.getAttribute('transform');\n new Animation({}).animate(element, {\n duration: duration,\n delay: delay,\n progress: function (args) {\n if (args.timeStamp > args.delay) {\n args.element.style.visibility = 'visible';\n height = ((args.timeStamp - args.delay) / args.duration);\n element.setAttribute('transform', 'translate(' + centerX\n + ' ' + centerY + ') scale(' + height + ') translate(' + (-centerX) + ' ' + (-centerY) + ')');\n }\n },\n end: function () {\n element.style.visibility = '';\n element.setAttribute('transform', transform ? transform : '');\n if ((series.type === 'Scatter' || series.type === 'Bubble') && !isLabel && (pointIndex === series.points.length - 1)) {\n series.chart.trigger('animationComplete', { series: series.chart.isBlazor ? {} : series });\n }\n }\n });\n}\n/**\n * Animate the rect element.\n */\nexport function animateRectElement(element, delay, duration, currentRect, previousRect) {\n var setStyle = function (rect) {\n element.setAttribute('x', rect.x + '');\n element.setAttribute('y', rect.y + '');\n element.setAttribute('width', rect.width + '');\n element.setAttribute('height', rect.height + '');\n };\n new Animation({}).animate(createElement('div'), {\n duration: duration,\n delay: delay,\n //name: name,\n progress: function (args) {\n setStyle(new Rect(linear(args.timeStamp, previousRect.x, currentRect.x - previousRect.x, args.duration), linear(args.timeStamp, previousRect.y, currentRect.y - previousRect.y, args.duration), linear(args.timeStamp, previousRect.width, currentRect.width - previousRect.width, args.duration), linear(args.timeStamp, previousRect.height, currentRect.height - previousRect.height, args.duration)));\n },\n end: function () {\n setStyle(currentRect);\n }\n });\n}\n/**\n * Animation after legend click a path.\n *\n * @param {Element} element element to be animated\n * @param {string} direction current direction of the path\n * @param {boolean} redraw chart redraw\n * @param {string} previousDirection previous direction of the path\n * @param {number} animateDuration animateDuration of the path\n */\nexport function pathAnimation(element, direction, redraw, previousDirection, animateDuration) {\n if (!redraw || (!previousDirection && !element)) {\n return null;\n }\n var duration = 300;\n if (animateDuration) {\n duration = animateDuration;\n }\n var startDirections = previousDirection || element.getAttribute('d');\n var splitDirections = startDirections.split(/(?=[LMCZAQ])/);\n var endDirections = direction.split(/(?=[LMCZAQ])/);\n var currentDireciton;\n var startPath = [];\n var endPath = [];\n var c;\n var end;\n element.setAttribute('d', startDirections);\n new Animation({}).animate(createElement('div'), {\n duration: duration,\n progress: function (args) {\n currentDireciton = '';\n splitDirections.map(function (directions, index) {\n startPath = directions.split(' ');\n endPath = endDirections[index] ? endDirections[index].split(' ') : startPath;\n if (startPath[0] === 'Z') {\n currentDireciton += 'Z' + ' ';\n }\n else if (startPath[0] === '') {\n currentDireciton = '';\n }\n else {\n currentDireciton += startPath[0] + ' ' +\n linear(args.timeStamp, +startPath[1], (+endPath[1] - +startPath[1]), args.duration) + ' ' +\n linear(args.timeStamp, +startPath[2], (+endPath[2] - +startPath[2]), args.duration) + ' ';\n }\n if (startPath[0] === 'C' || startPath[0] === 'Q') {\n c = 3;\n end = startPath[0] === 'Q' ? 4 : 6;\n while (c < end) {\n currentDireciton += linear(args.timeStamp, +startPath[c], (+endPath[c] - +startPath[c]), args.duration) + ' ' +\n linear(args.timeStamp, +startPath[++c], (+endPath[c] - +startPath[c]), args.duration) + ' ';\n ++c;\n }\n }\n if (startPath[0] === 'A') {\n currentDireciton += 0 + ' ' + 0 + ' ' + 1 + ' ' +\n linear(args.timeStamp, +startPath[6], (+endPath[6] - +startPath[6]), args.duration) + ' ' +\n linear(args.timeStamp, +startPath[7], (+endPath[7] - +startPath[7]), args.duration) + ' ';\n }\n });\n element.setAttribute('d', currentDireciton);\n },\n end: function () {\n element.setAttribute('d', direction);\n }\n });\n}\n/**\n * To append the clip rect element.\n *\n * @param {boolean} redraw chart redraw value\n * @param {BaseAttibutes} options element options\n * @param {SvgRenderer} renderer svg renderer values\n * @param {string} clipPath clipPath of the element\n */\nexport function appendClipElement(redraw, options, renderer, clipPath) {\n if (clipPath === void 0) { clipPath = 'drawClipPath'; }\n var clipElement = redrawElement(redraw, options.id, options, renderer);\n if (clipElement) {\n var def = renderer.createDefs();\n def.appendChild(clipElement);\n return def;\n }\n else {\n return renderer[clipPath](options);\n }\n}\n/**\n * Triggers the event.\n *\n * @returns {void}\n * @private\n */\nexport function triggerLabelRender(chart, tempInterval, text, labelStyle, axis) {\n var argsData = {\n cancel: false, name: axisLabelRender, axis: axis,\n text: text, value: tempInterval, labelStyle: labelStyle\n };\n chart.trigger(axisLabelRender, argsData);\n if (!argsData.cancel) {\n var isLineBreakLabels = argsData.text.indexOf('<br>') !== -1;\n var text_1 = (axis.enableTrim) ? (isLineBreakLabels ?\n lineBreakLabelTrim(axis.maximumLabelWidth, argsData.text, axis.labelStyle, chart.themeStyle.axisLabelFont) :\n textTrim(axis.maximumLabelWidth, argsData.text, axis.labelStyle, chart.enableRtl, chart.themeStyle.axisLabelFont)) : argsData.text;\n axis.visibleLabels.push(new VisibleLabels(text_1, argsData.value, argsData.labelStyle, argsData.text));\n }\n}\n/**\n * The function used to find whether the range is set.\n *\n * @returns {boolean} It returns true if the axis range is set otherwise false.\n * @private\n */\nexport function setRange(axis) {\n return (axis.minimum != null && axis.maximum != null);\n}\n/**\n * To check whether the axis is zoomed or not.\n *\n * @param {Axis} axis axis model\n */\nexport function isZoomSet(axis) {\n return (axis.zoomFactor < 1 && axis.zoomPosition >= 0);\n}\n/**\n * Calculate desired interval for the axis.\n *\n * @returns {void} It returns desired interval count.\n * @private\n */\nexport function getActualDesiredIntervalsCount(availableSize, axis) {\n var size = axis.orientation === 'Horizontal' ? availableSize.width : availableSize.height;\n if (isNullOrUndefined(axis.desiredIntervals)) {\n var desiredIntervalsCount = (axis.orientation === 'Horizontal' ? 0.533 : 1) * axis.maximumLabels;\n desiredIntervalsCount = Math.max((size * (desiredIntervalsCount / 100)), 1);\n return desiredIntervalsCount;\n }\n else {\n return axis.desiredIntervals;\n }\n}\n/**\n * Animation for template\n *\n * @private\n */\nexport function templateAnimate(element, delay, duration, name, isRemove) {\n new Animation({}).animate(element, {\n duration: duration,\n delay: delay,\n name: name,\n progress: function (args) {\n args.element.style.visibility = 'visible';\n },\n end: function (args) {\n if (isRemove) {\n remove(args.element);\n }\n else {\n args.element.style.visibility = 'visible';\n }\n }\n });\n}\n/** @private */\nexport function drawSymbol(location, shape, size, url, options, label, renderer, clipRect, isChartControl, control) {\n var chartRenderer = renderer ? renderer : new SvgRenderer('');\n var shapeOption = calculateShapes(location, size, shape, options, url, isChartControl, control);\n var drawElement = chartRenderer['draw' + shapeOption.functionName](shapeOption.renderOption, clipRect ? new Int32Array([clipRect.x, clipRect.y]) : null);\n //drawElement.setAttribute('aria-label', label);\n return drawElement;\n}\n/** @private */\nexport function calculateShapes(location, size, shape, options, url, isChart, control) {\n var dir;\n var functionName = 'Path';\n var isBulletChart = isChart;\n var width = (isBulletChart && shape === 'Circle') ? (size.width - 2) : size.width;\n var height = (isBulletChart && shape === 'Circle') ? (size.height - 2) : size.height;\n var sizeBullet = (isBulletChart) ? control.targetWidth : 0;\n var lx = location.x;\n var ly = location.y;\n var y = location.y + (-height / 2);\n var x = location.x + (-width / 2);\n var eq = 72;\n var xVal;\n var yVal;\n switch (shape) {\n case 'Bubble':\n case 'Circle':\n functionName = 'Ellipse';\n merge(options, { 'rx': width / 2, 'ry': height / 2, 'cx': lx, 'cy': ly });\n break;\n case 'Plus':\n dir = 'M' + ' ' + x + ' ' + ly + ' ' + 'L' + ' ' + (lx + (width / 2)) + ' ' + ly + ' ' +\n 'M' + ' ' + lx + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' + lx + ' ' +\n (ly + (-height / 2));\n merge(options, { 'd': dir });\n break;\n case 'Cross':\n dir = 'M' + ' ' + x + ' ' + (ly + (-height / 2)) + ' ' + 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly + (height / 2)) + ' ' +\n 'M' + ' ' + x + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly + (-height / 2));\n merge(options, { 'd': dir });\n break;\n case 'Multiply':\n dir = 'M ' + (lx - sizeBullet) + ' ' + (ly - sizeBullet) + ' L ' +\n (lx + sizeBullet) + ' ' + (ly + sizeBullet) + ' M ' +\n (lx - sizeBullet) + ' ' + (ly + sizeBullet) + ' L ' + (lx + sizeBullet) + ' ' + (ly - sizeBullet);\n merge(options, { 'd': dir, stroke: options.fill });\n break;\n case 'HorizontalLine':\n dir = 'M' + ' ' + x + ' ' + ly + ' ' + 'L' + ' ' + (lx + (width / 2)) + ' ' + ly;\n merge(options, { 'd': dir });\n break;\n case 'VerticalLine':\n dir = 'M' + ' ' + lx + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' + lx + ' ' + (ly + (-height / 2));\n merge(options, { 'd': dir });\n break;\n case 'Diamond':\n dir = 'M' + ' ' + x + ' ' + ly + ' ' +\n 'L' + ' ' + lx + ' ' + (ly + (-height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + ly + ' ' +\n 'L' + ' ' + lx + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + ly + ' z';\n merge(options, { 'd': dir });\n break;\n case 'ActualRect':\n dir = 'M' + ' ' + x + ' ' + (ly + (-height / 8)) + ' ' +\n 'L' + ' ' + (lx + (sizeBullet)) + ' ' + (ly + (-height / 8)) + ' ' +\n 'L' + ' ' + (lx + (sizeBullet)) + ' ' + (ly + (height / 8)) + ' ' +\n 'L' + ' ' + x + ' ' + (ly + (height / 8)) + ' ' +\n 'L' + ' ' + x + ' ' + (ly + (-height / 8)) + ' z';\n merge(options, { 'd': dir });\n break;\n case 'TargetRect':\n dir = 'M' + ' ' + (x + (sizeBullet)) + ' ' + (ly + (-height / 2)) + ' ' +\n 'L' + ' ' + (lx + (sizeBullet / 2)) + ' ' + (ly + (-height / 2)) + ' ' +\n 'L' + ' ' + (lx + (sizeBullet / 2)) + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + (x + (sizeBullet)) + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + (x + (sizeBullet)) + ' ' + (ly + (-height / 2)) + ' z';\n merge(options, { 'd': dir });\n break;\n case 'Rectangle':\n case 'Hilo':\n case 'HiloOpenClose':\n case 'Candle':\n case 'Waterfall':\n case 'BoxAndWhisker':\n case 'StepArea':\n case 'RangeStepArea':\n case 'StackingStepArea':\n case 'Square':\n case 'Flag':\n dir = 'M' + ' ' + x + ' ' + (ly + (-height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly + (-height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + (ly + (-height / 2)) + ' z';\n merge(options, { 'd': dir });\n break;\n case 'Pyramid':\n case 'Triangle':\n dir = 'M' + ' ' + x + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + lx + ' ' + (ly + (-height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + x + ' ' + (ly + (height / 2)) + ' z';\n merge(options, { 'd': dir });\n break;\n case 'Funnel':\n case 'InvertedTriangle':\n dir = 'M' + ' ' + (lx + (width / 2)) + ' ' + (ly - (height / 2)) + ' ' +\n 'L' + ' ' + lx + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + (lx - (width / 2)) + ' ' + (ly - (height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly - (height / 2)) + ' z';\n merge(options, { 'd': dir });\n break;\n case 'Pentagon':\n for (var i = 0; i <= 5; i++) {\n xVal = (width / 2) * Math.cos((Math.PI / 180) * (i * eq));\n yVal = (height / 2) * Math.sin((Math.PI / 180) * (i * eq));\n if (i === 0) {\n dir = 'M' + ' ' + (lx + xVal) + ' ' + (ly + yVal) + ' ';\n }\n else {\n dir = dir.concat('L' + ' ' + (lx + xVal) + ' ' + (ly + yVal) + ' ');\n }\n }\n dir = dir.concat('Z');\n merge(options, { 'd': dir });\n break;\n case 'Image':\n functionName = 'Image';\n merge(options, { 'href': url, 'height': height, 'width': width, x: x, y: y });\n break;\n }\n options = calculateLegendShapes(location, new Size(width, height), shape, options).renderOption;\n return { renderOption: options, functionName: functionName };\n}\n/** @private */\nexport function getRectLocation(startLocation, endLocation, outerRect) {\n var x = (endLocation.x < outerRect.x) ? outerRect.x :\n (endLocation.x > (outerRect.x + outerRect.width)) ? outerRect.x + outerRect.width : endLocation.x;\n var y = (endLocation.y < outerRect.y) ? outerRect.y :\n (endLocation.y > (outerRect.y + outerRect.height)) ? outerRect.y + outerRect.height : endLocation.y;\n return new Rect((x > startLocation.x ? startLocation.x : x), (y > startLocation.y ? startLocation.y : y), Math.abs(x - startLocation.x), Math.abs(y - startLocation.y));\n}\n/** @private */\nexport function minMax(value, min, max) {\n return value > max ? max : (value < min ? min : value);\n}\n/** @private */\nexport function getElement(id) {\n return document.getElementById(id);\n}\n/** @private */\nexport function getTemplateFunction(template) {\n var templateFn = null;\n try {\n if (typeof template !== 'function' && document.querySelectorAll(template).length) {\n templateFn = templateComplier(document.querySelector(template).innerHTML.trim());\n }\n else {\n templateFn = templateComplier(template);\n }\n }\n catch (e) {\n templateFn = templateComplier(template);\n }\n return templateFn;\n}\n/** @private */\nexport function accReactTemplate(childElement, chart, isTemplate, points, argsData, point, datalabelGroup, id, dataLabel, redraw) {\n var clientRect = childElement.getBoundingClientRect();\n chart.accumulationDataLabelModule.calculateLabelSize(isTemplate, childElement, point, points, argsData, datalabelGroup, id, dataLabel, redraw, clientRect, true);\n}\n/** @private */\nexport function chartReactTemplate(childElement, chart, point, series, labelIndex, redraw) {\n var parentElement = document.getElementById(chart.element.id + '_Series_' + (series.index === undefined ? series.category : series.index) + '_DataLabelCollections');\n if (parentElement) {\n if (point.index === 0) {\n chart.dataLabelCollections = []; // clear old datalabel bounds for react callback\n }\n chart.dataLabelModule.calculateTemplateLabelSize(parentElement, childElement, point, series, series.marker.dataLabel, labelIndex, series.clipRect, redraw, true);\n }\n}\n/** @private */\nexport function createTemplate(childElement, pointIndex, content, chart, point, series, dataLabelId, labelIndex, argsData, isTemplate, points, datalabelGroup, id, dataLabel, redraw) {\n var templateFn = getTemplateFunction(content);\n var templateElement;\n try {\n var blazor = 'Blazor';\n var tempObject = window[blazor] ? (dataLabelId ? point : { point: point }) :\n { chart: chart, series: series, point: point };\n var templateId = dataLabelId ? dataLabelId + '_template' : 'template';\n var elementData = templateFn ? templateFn(tempObject, chart, templateId, dataLabelId ||\n childElement.id.replace(/[^a-zA-Z0-9]/g, '')) : [];\n if (elementData.length) {\n templateElement = Array.prototype.slice.call(elementData);\n var len = templateElement.length;\n for (var i = 0; i < len; i++) {\n childElement.appendChild(templateElement[i]);\n }\n }\n var reactCallback = void 0;\n if (chart.getModuleName() === 'accumulationchart') {\n reactCallback = accReactTemplate.bind(this, childElement, chart, isTemplate, points, argsData, points[pointIndex], datalabelGroup, id, dataLabel, redraw);\n // tslint:disable-next-line:no-any\n if (chart.isReact) {\n chart.renderReactTemplates(reactCallback);\n }\n }\n else if (chart.getModuleName() === 'chart') {\n reactCallback = (point && series) ? chartReactTemplate.bind(this, childElement, chart, point, series, labelIndex, redraw) : reactCallback;\n // tslint:disable-next-line:no-any\n if (chart.isReact) {\n chart.renderReactTemplates(reactCallback);\n }\n }\n }\n catch (e) {\n return childElement;\n }\n return childElement;\n}\n/** @private */\nexport function getFontStyle(font) {\n var style = '';\n style = 'font-size:' + font.size +\n '; font-style:' + font.fontStyle + '; font-weight:' + font.fontWeight +\n '; font-family:' + font.fontFamily + ';opacity:' + font.opacity +\n '; color:' + font.color + ';';\n return style;\n}\n/** @private */\nexport function measureElementRect(element, redraw, isReactCallback) {\n if (redraw === void 0) { redraw = false; }\n if (!isReactCallback) { // If the element is already in DOM, no need to append in the body.\n document.body.appendChild(element);\n }\n var bounds = element.getBoundingClientRect();\n if (redraw) {\n remove(element);\n }\n else if (!isReactCallback) { // for react chart data label template - (callback function)\n removeElement(element.id);\n }\n return bounds;\n}\n/** @private */\nexport function findlElement(elements, id) {\n var element;\n for (var i = 0, length_1 = elements.length; i < length_1; i++) {\n if (elements[i].id.indexOf(id) > -1) {\n element = elements[i];\n continue;\n }\n }\n return element;\n}\n/** @private */\nexport function getPoint(x, y, xAxis, yAxis, isInverted) {\n x = ((xAxis.valueType === 'Logarithmic') ?\n logBase(((x > 0) ? x : Math.pow(xAxis.logBase, xAxis.visibleRange.min)), xAxis.logBase) : x);\n y = ((yAxis.valueType === 'Logarithmic') ?\n logBase(((y > 0) ? y : Math.pow(yAxis.logBase, yAxis.visibleRange.min)), yAxis.logBase) : y);\n x = valueToCoefficient(x, xAxis);\n y = valueToCoefficient(y, yAxis);\n var xLength = (isInverted ? xAxis.rect.height : xAxis.rect.width);\n var yLength = (isInverted ? yAxis.rect.width : yAxis.rect.height);\n var locationX = isInverted ? y * (yLength) : x * (xLength);\n var locationY = isInverted ? (1 - x) * (xLength) : (1 - y) * (yLength);\n return new ChartLocation(locationX, locationY);\n}\n/** @private */\nexport function appendElement(child, parent, redraw, animate, x, y) {\n if (redraw === void 0) { redraw = false; }\n if (animate === void 0) { animate = false; }\n if (x === void 0) { x = 'x'; }\n if (y === void 0) { y = 'y'; }\n if (child && child.hasChildNodes() && parent) {\n appendChildElement(false, parent, child, redraw, animate, x, y);\n }\n else {\n return null;\n }\n}\n/**\n * Method to append child element.\n *\n * @param {boolean} isCanvas canvas mode value\n * @param {Element} parent parent element\n * @param {Element} childElement childElement element\n * @param {boolean} redraw chart redraw value\n * @param {boolean} isAnimate animation value\n * @param {string} x x position\n * @param {string} y y position\n * @param {ChartLocation} start start location value\n * @param {string} direction direction of the element\n * @param {boolean} forceAnimate forceAnimate\n * @param {boolean} isRect isRect\n * @param {Rect} previousRect previousRect\n * @param {number} animateDuration duration of the animation\n */\nexport function appendChildElement(isCanvas, parent, childElement, redraw, isAnimate, x, y, start, direction, forceAnimate, isRect, previousRect, animateDuration, scatterElement) {\n if (isAnimate === void 0) { isAnimate = false; }\n if (x === void 0) { x = 'x'; }\n if (y === void 0) { y = 'y'; }\n if (forceAnimate === void 0) { forceAnimate = false; }\n if (isRect === void 0) { isRect = false; }\n if (previousRect === void 0) { previousRect = null; }\n if (scatterElement === void 0) { scatterElement = false; }\n if (isCanvas) {\n return null;\n }\n var existChild = scatterElement ? null : parent.querySelector('#' + childElement.id);\n var element = (existChild || getElement(childElement.id));\n var child = childElement;\n var duration = animateDuration ? animateDuration : 300;\n if (redraw && isAnimate && element) {\n start = start || (element.tagName === 'DIV' ?\n new ChartLocation(+(element.style[x].split('px')[0]), +(element.style[y].split('px')[0])) :\n new ChartLocation(+element.getAttribute(x), +element.getAttribute(y)));\n if (direction && direction !== 'undefined') {\n pathAnimation(childElement, childElement.getAttribute('d'), redraw, direction, duration);\n }\n else if (isRect && previousRect) {\n animateRectElement(child, 0, duration, new Rect(+element.getAttribute('x'), +element.getAttribute('y'), +element.getAttribute('width'), +element.getAttribute('height')), previousRect);\n }\n else {\n var end = child.tagName === 'DIV' ?\n new ChartLocation(+(child.style[x].split('px')[0]), +(child.style[y].split('px')[0])) :\n new ChartLocation(+child.getAttribute(x), +child.getAttribute(y));\n animateRedrawElement(child, duration, start, end, x, y);\n }\n }\n else if (redraw && isAnimate && !element && forceAnimate) {\n templateAnimate(child, 0, 600, 'FadeIn');\n }\n if (existChild) {\n parent.replaceChild(child, element);\n }\n else {\n parent.appendChild(child);\n }\n}\n/** @private */\nexport function getDraggedRectLocation(x1, y1, x2, y2, outerRect) {\n var width = Math.abs(x1 - x2);\n var height = Math.abs(y1 - y2);\n var x = Math.max(checkBounds(Math.min(x1, x2), width, outerRect.x, outerRect.width), outerRect.x);\n var y = Math.max(checkBounds(Math.min(y1, y2), height, outerRect.y, outerRect.height), outerRect.y);\n return new Rect(x, y, Math.min(width, outerRect.width), Math.min(height, outerRect.height));\n}\n/** @private */\nexport function checkBounds(start, size, min, max) {\n if (start < min) {\n start = min;\n }\n else if ((start + size) > (max + min)) {\n start = (max + min) - size;\n }\n return start;\n}\n/** @private */\nexport function getLabelText(currentPoint, series, chart) {\n var labelFormat = series.marker.dataLabel.format ? series.marker.dataLabel.format : series.yAxis.labelFormat;\n var text = [];\n var customLabelFormat = labelFormat.match('{value}') !== null;\n switch (series.seriesType) {\n case 'XY':\n /**\n * I255790\n * For Polar radar series, the dataLabel appears out of range when axis range is given for yaxis\n * Cause: Since symbol location for the points which did not lies in within range, lies outside of seriesRect.\n * Fix: DataLabel rendered after checking WithIn for the points\n */\n if (series.chart.chartAreaType === 'PolarRadar') {\n if (series.drawType.indexOf('Stacking') !== -1) {\n if ((series.yAxis.valueType === 'Logarithmic' &&\n logWithIn(series.stackedValues.endValues[currentPoint.index], series.yAxis)) ||\n withIn(series.stackedValues.endValues[currentPoint.index], series.yAxis.visibleRange)) {\n text.push(currentPoint.text || currentPoint.yValue.toString());\n }\n }\n else {\n if ((series.yAxis.valueType === 'Logarithmic' && logWithIn(currentPoint.yValue, series.yAxis)) ||\n withIn(currentPoint.yValue, series.yAxis.visibleRange)) {\n text.push(currentPoint.text || currentPoint.yValue.toString());\n }\n }\n }\n else {\n text.push(currentPoint.text || currentPoint.yValue.toString());\n }\n break;\n case 'HighLow':\n text.push(currentPoint.text || Math.max(currentPoint.high, currentPoint.low).toString());\n text.push(currentPoint.text || Math.min(currentPoint.high, currentPoint.low).toString());\n break;\n case 'HighLowOpenClose':\n text.push(currentPoint.text || Math.max(currentPoint.high, currentPoint.low).toString());\n text.push(currentPoint.text || Math.min(currentPoint.high, currentPoint.low).toString());\n text.push(currentPoint.text || Math.max(currentPoint.open, currentPoint.close).toString());\n text.push(currentPoint.text || Math.min(currentPoint.open, currentPoint.close).toString());\n break;\n case 'BoxPlot':\n text.push(currentPoint.text || currentPoint.median.toString());\n text.push(currentPoint.text || currentPoint.maximum.toString());\n text.push(currentPoint.text || currentPoint.minimum.toString());\n text.push(currentPoint.text || currentPoint.upperQuartile.toString());\n text.push(currentPoint.text || currentPoint.lowerQuartile.toString());\n for (var _i = 0, _a = currentPoint.outliers; _i < _a.length; _i++) {\n var liers = _a[_i];\n text.push(currentPoint.text || liers.toString());\n }\n break;\n }\n if ((labelFormat || chart.useGroupingSeparator) && !currentPoint.text) {\n series.yAxis.format = chart.intl.getNumberFormat({\n format: customLabelFormat ? '' : labelFormat,\n useGrouping: chart.useGroupingSeparator\n });\n for (var i = 0; i < text.length; i++) {\n text[i] = customLabelFormat ? labelFormat.replace('{value}', series.yAxis.format(parseFloat(text[i]))) :\n series.yAxis.format(parseFloat(text[i]));\n }\n }\n return text;\n}\n/** @private */\nexport function stopTimer(timer) {\n window.clearInterval(timer);\n}\n/** @private */\nexport function isCollide(rect, collections, clipRect) {\n var currentRect = new Rect(rect.x + clipRect.x, rect.y + clipRect.y, rect.width, rect.height);\n var isCollide = collections.some(function (rect) {\n return (currentRect.x < rect.x + rect.width && currentRect.x + currentRect.width > rect.x &&\n currentRect.y < rect.y + rect.height && currentRect.height + currentRect.y > rect.y);\n });\n return isCollide;\n}\n/** @private */\nexport function isOverlap(currentRect, rect) {\n return (currentRect.x < rect.x + rect.width && currentRect.x + currentRect.width > rect.x &&\n currentRect.y < rect.y + rect.height && currentRect.height + currentRect.y > rect.y);\n}\n/** @private */\nexport function containsRect(currentRect, rect) {\n return (currentRect.x <= rect.x && currentRect.x + currentRect.width >= rect.x + rect.width &&\n currentRect.y <= rect.y && currentRect.height + currentRect.y >= rect.y + rect.height);\n}\n/** @private */\nexport function calculateRect(location, textSize, margin) {\n return new Rect((location.x - (textSize.width / 2) - margin.left), (location.y - (textSize.height / 2) - margin.top), textSize.width + margin.left + margin.right, textSize.height + margin.top + margin.bottom);\n}\n/** @private */\nexport function convertToHexCode(value) {\n return '#' + componentToHex(value.r) + componentToHex(value.g) + componentToHex(value.b);\n}\n/** @private */\nexport function componentToHex(value) {\n var hex = value.toString(16);\n return hex.length === 1 ? '0' + hex : hex;\n}\n/** @private */\nexport function convertHexToColor(hex) {\n var result = /^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(hex);\n return result ? new ColorValue(parseInt(result[1], 16), parseInt(result[2], 16), parseInt(result[3], 16)) :\n new ColorValue(255, 255, 255);\n}\n/** @private */\nexport function colorNameToHex(color) {\n color = color === 'transparent' ? 'white' : color;\n document.body.appendChild(createElement('text', { id: 'chartmeasuretext' }));\n var element = document.getElementById('chartmeasuretext');\n element.style.color = color;\n color = window.getComputedStyle(element).color;\n remove(element);\n // eslint-disable-next-line security/detect-unsafe-regex\n var exp = /^(rgb|hsl)(a?)[(]\\s*([\\d.]+\\s*%?)\\s*,\\s*([\\d.]+\\s*%?)\\s*,\\s*([\\d.]+\\s*%?)\\s*(?:,\\s*([\\d.]+)\\s*)?[)]$/;\n var isRGBValue = exp.exec(color);\n return convertToHexCode(new ColorValue(parseInt(isRGBValue[3], 10), parseInt(isRGBValue[4], 10), parseInt(isRGBValue[5], 10)));\n}\n/** @private */\nexport function checkColorFormat(color) {\n // eslint-disable-next-line security/detect-unsafe-regex\n return /(rgba?\\((?:\\d{1,3}[,)]){3}(?:\\d+\\.\\d+\\))?)|(^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$)/gmi.test(color);\n}\n/** @private */\nexport function getSaturationColor(color, factor) {\n color = colorNameToHex(color);\n color = color.replace(/[^0-9a-f]/gi, '');\n if (color.length < 6) {\n color = color[0] + color[0] + color[1] + color[1] + color[2] + color[2];\n }\n factor = factor || 0;\n // convert to decimal and change luminosity\n var rgb = '#';\n var colorCode;\n for (var i = 0; i < 3; i++) {\n colorCode = parseInt(color.substr(i * 2, 2), 16);\n colorCode = Math.round(Math.min(Math.max(0, colorCode + (colorCode * factor)), 255));\n rgb += ('00' + colorCode.toString(16)).substr(colorCode.toString(16).length);\n }\n return rgb;\n}\n/** @private */\nexport function applyZLight(color, value) {\n var RGB = convertHexToColor(color);\n RGB.r = parseInt(Math.floor(RGB.r * value).toString(), 10);\n RGB.g = parseInt(Math.floor(RGB.g * value).toString(), 10);\n RGB.b = parseInt(Math.floor(RGB.b * value).toString(), 10);\n return '#' + componentToHex(RGB.r).toUpperCase() + componentToHex(RGB.g).toUpperCase() + componentToHex(RGB.b).toUpperCase();\n}\n/** @private */\nexport function getMedian(values) {\n var half = Math.floor(values.length / 2);\n return values.length % 2 ? values[half] : ((values[half - 1] + values[half]) / 2.0);\n}\n/** @private */\nexport function calculateLegendShapes(location, size, shape, options) {\n var padding = 10;\n var dir = '';\n var space = 2;\n var height = size.height;\n var width = size.width;\n var lx = location.x;\n var ly = location.y;\n switch (shape) {\n case 'MultiColoredLine':\n case 'Line':\n case 'StackingLine':\n case 'StackingLine100':\n dir = 'M' + ' ' + (lx + (-width * (3 / 4))) + ' ' + (ly) + ' ' +\n 'L' + ' ' + (lx + (width * (3 / 4))) + ' ' + (ly);\n merge(options, { 'd': dir });\n break;\n case 'StepLine':\n options.fill = 'transparent';\n dir = 'M' + ' ' + (lx + (-width / 2) - (padding / 4)) + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' + (lx +\n (-width / 2) + (width / 10)) + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' + (lx + (-width / 2) + (width / 10))\n + ' ' + (ly) + ' ' + 'L' + ' ' + (lx + (-width / 10)) + ' ' + (ly) + ' ' + 'L' + ' ' + (lx + (-width / 10))\n + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' + (lx + (width / 5)) + ' ' + (ly + (height / 2)) + ' ' + 'L' +\n ' ' + (lx + (width / 5)) + ' ' + (ly + (-height / 2)) + ' ' + 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly +\n (-height / 2)) + 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly + (height / 2)) + ' ' + 'L' + '' + (lx + (width / 2)\n + (padding / 4)) + ' ' + (ly + (height / 2));\n merge(options, { 'd': dir });\n break;\n case 'UpArrow':\n options.fill = options.stroke;\n options.stroke = 'transparent';\n dir = 'M' + ' ' + (lx + (-width / 2)) + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + (lx) + ' ' + (ly - (height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly + (height / 2)) +\n 'L' + ' ' + (lx + (width / 2) - space) + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + (lx) + ' ' + (ly - (height / 2) + (2 * space)) +\n 'L' + (lx - (width / 2) + space) + ' ' + (ly + (height / 2)) + ' Z';\n merge(options, { 'd': dir });\n break;\n case 'DownArrow':\n dir = 'M' + ' ' + (lx - (width / 2)) + ' ' + (ly - (height / 2)) + ' ' +\n 'L' + ' ' + (lx) + ' ' + (ly + (height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly - (height / 2)) +\n 'L' + ' ' + (lx + (width / 2) - space) + ' ' + (ly - (height / 2)) + ' ' +\n 'L' + ' ' + (lx) + ' ' + (ly + (height / 2) - (2 * space)) +\n 'L' + (lx - (width / 2) + space) + ' ' + (ly - (height / 2)) + ' Z';\n merge(options, { 'd': dir });\n break;\n case 'RightArrow':\n dir = 'M' + ' ' + (lx + (-width / 2)) + ' ' + (ly - (height / 2)) + ' ' +\n 'L' + ' ' + (lx + (width / 2)) + ' ' + (ly) + ' ' + 'L' + ' ' +\n (lx + (-width / 2)) + ' ' + (ly + (height / 2)) + ' L' + ' ' + (lx + (-width / 2)) + ' ' +\n (ly + (height / 2) - space) + ' ' + 'L' + ' ' + (lx + (width / 2) - (2 * space)) + ' ' + (ly) +\n ' L' + (lx + (-width / 2)) + ' ' + (ly - (height / 2) + space) + ' Z';\n merge(options, { 'd': dir });\n break;\n case 'LeftArrow':\n options.fill = options.stroke;\n options.stroke = 'transparent';\n dir = 'M' + ' ' + (lx + (width / 2)) + ' ' + (ly - (height / 2)) + ' ' +\n 'L' + ' ' + (lx + (-width / 2)) + ' ' + (ly) + ' ' + 'L' + ' ' +\n (lx + (width / 2)) + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' +\n (lx + (width / 2)) + ' ' + (ly + (height / 2) - space) + ' L' + ' ' + (lx + (-width / 2) + (2 * space))\n + ' ' + (ly) + ' L' + (lx + (width / 2)) + ' ' + (ly - (height / 2) + space) + ' Z';\n merge(options, { 'd': dir });\n break;\n case 'Column':\n case 'Pareto':\n case 'StackingColumn':\n case 'StackingColumn100':\n case 'RangeColumn':\n case 'Histogram':\n dir = 'M' + ' ' + (lx - 3 * (width / 5)) + ' ' + (ly - (height / 5)) + ' ' + 'L' + ' ' +\n (lx + 3 * (-width / 10)) + ' ' + (ly - (height / 5)) + ' ' + 'L' + ' ' +\n (lx + 3 * (-width / 10)) + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' ' + (lx - 3 *\n (width / 5)) + ' ' + (ly + (height / 2)) + ' ' + 'Z' + ' ' + 'M' + ' ' +\n (lx + (-width / 10) - (width / 20)) + ' ' + (ly - (height / 4) - (padding / 2))\n + ' ' + 'L' + ' ' + (lx + (width / 10) + (width / 20)) + ' ' + (ly - (height / 4) -\n (padding / 2)) + ' ' + 'L' + ' ' + (lx + (width / 10) + (width / 20)) + ' ' + (ly\n + (height / 2)) + ' ' + 'L' + ' ' + (lx + (-width / 10) - (width / 20)) + ' ' + (ly +\n (height / 2)) + ' ' + 'Z' + ' ' + 'M' + ' ' + (lx + 3 * (width / 10)) + ' ' + (ly) + ' ' +\n 'L' + ' ' + (lx + 3 * (width / 5)) + ' ' + (ly) + ' ' + 'L' + ' '\n + (lx + 3 * (width / 5)) + ' ' + (ly + (height / 2)) + ' ' + 'L' + ' '\n + (lx + 3 * (width / 10)) + ' ' + (ly + (height / 2)) + ' ' + 'Z';\n merge(options, { 'd': dir });\n break;\n case 'Bar':\n case 'StackingBar':\n case 'StackingBar100':\n dir = 'M' + ' ' + (lx + (-width / 2) + (-padding / 4)) + ' ' + (ly - 3 * (height / 5)) + ' '\n + 'L' + ' ' + (lx + 3 * (width / 10)) + ' ' + (ly - 3 * (height / 5)) + ' ' + 'L' + ' ' +\n (lx + 3 * (width / 10)) + ' ' + (ly - 3 * (height / 10)) + ' ' + 'L' + ' ' +\n (lx - (width / 2) + (-padding / 4)) + ' ' + (ly - 3 * (height / 10)) + ' ' + 'Z' + ' '\n + 'M' + ' ' + (lx + (-width / 2) + (-padding / 4)) + ' ' + (ly - (height / 5)\n + (padding / 20)) + ' ' + 'L' + ' ' + (lx + (width / 2) + (padding / 4)) + ' ' + (ly\n - (height / 5) + (padding / 20)) + ' ' + 'L' + ' ' + (lx + (width / 2) + (padding / 4))\n + ' ' + (ly + (height / 10) + (padding / 20)) + ' ' + 'L' + ' ' + (lx - (width / 2)\n + (-padding / 4)) + ' ' + (ly + (height / 10) + (padding / 20)) + ' ' + 'Z' + ' ' + 'M'\n + ' ' + (lx - (width / 2) + (-padding / 4)) + ' ' + (ly + (height / 5)\n + (padding / 10)) + ' ' + 'L' + ' ' + (lx + (-width / 4)) + ' ' + (ly + (height / 5)\n + (padding / 10)) + ' ' + 'L' + ' ' + (lx + (-width / 4)) + ' ' + (ly + (height / 2)\n + (padding / 10)) + ' ' + 'L' + ' ' + (lx - (width / 2) + (-padding / 4))\n + ' ' + (ly + (height / 2) + (padding / 10)) + ' ' + 'Z';\n merge(options, { 'd': dir });\n break;\n case 'Spline':\n options.fill = 'transparent';\n dir = 'M' + ' ' + (lx - (width / 2)) + ' ' + (ly + (height / 5)) + ' ' + 'Q' + ' '\n + lx + ' ' + (ly - height) + ' ' + lx + ' ' + (ly + (height / 5))\n + ' ' + 'M' + ' ' + lx + ' ' + (ly + (height / 5)) + ' ' + 'Q' + ' ' + (lx\n + (width / 2)) + ' ' + (ly + (height / 2)) + ' ' + (lx + (width / 2)) + ' '\n + (ly - (height / 2));\n merge(options, { 'd': dir });\n break;\n case 'Area':\n case 'MultiColoredArea':\n case 'RangeArea':\n case 'StackingArea':\n case 'StackingArea100':\n dir = 'M' + ' ' + (lx - (width / 2) - (padding / 4)) + ' ' + (ly + (height / 2))\n + ' ' + 'L' + ' ' + (lx + (-width / 4) + (-padding / 8)) + ' ' + (ly - (height / 2))\n + ' ' + 'L' + ' ' + (lx) + ' ' + (ly + (height / 4)) + ' ' + 'L' + ' ' + (lx\n + (width / 4) + (padding / 8)) + ' ' + (ly + (-height / 2) + (height / 4)) + ' '\n + 'L' + ' ' + (lx + (height / 2) + (padding / 4)) + ' ' + (ly + (height / 2)) + ' ' + 'Z';\n merge(options, { 'd': dir });\n break;\n case 'SplineArea':\n case 'SplineRangeArea':\n dir = 'M' + ' ' + (lx - (width / 2)) + ' ' + (ly + (height / 5)) + ' ' + 'Q' + ' ' + lx\n + ' ' + (ly - height) + ' ' + lx + ' ' + (ly + (height / 5)) + ' ' + 'Z' + ' ' + 'M'\n + ' ' + lx + ' ' + (ly + (height / 5)) + ' ' + 'Q' + ' ' + (lx + (width / 2)) + ' '\n + (ly + (height / 2)) + ' ' + (lx + (width / 2)) + ' '\n + (ly - (height / 2)) + ' ' + ' Z';\n merge(options, { 'd': dir });\n break;\n case 'Pie':\n case 'Doughnut':\n options.stroke = 'transparent';\n // eslint-disable-next-line no-case-declarations\n var r = Math.min(height, width) / 2;\n dir = getAccumulationLegend(lx, ly, r, height, width, shape);\n merge(options, { 'd': dir });\n break;\n }\n return { renderOption: options };\n}\n/** @private */\nexport function textTrim(maxWidth, text, font, isRtlEnabled, themeFontStyle) {\n var label = text;\n var size = measureText(text, font, themeFontStyle).width;\n if (size > maxWidth) {\n var textLength = text.length;\n for (var i = textLength - 1; i >= 0; --i) {\n label = isRtlEnabled ? '...' + text.substring(0, i) : text.substring(0, i) + '...';\n size = measureText(label, font, themeFontStyle).width;\n if (size <= maxWidth) {\n return label;\n }\n }\n }\n return label;\n}\n/** @private */\nexport function lineBreakLabelTrim(maxWidth, text, font, themeFontStyle) {\n var labelCollection = [];\n var breakLabels = text.split('<br>');\n for (var i = 0; i < breakLabels.length; i++) {\n text = breakLabels[i];\n var size = measureText(text, font, themeFontStyle).width;\n if (size > maxWidth) {\n var textLength = text.length;\n for (var i_1 = textLength - 1; i_1 >= 0; --i_1) {\n text = text.substring(0, i_1) + '...';\n size = measureText(text, font, themeFontStyle).width;\n if (size <= maxWidth) {\n labelCollection.push(text);\n break;\n }\n }\n }\n else {\n labelCollection.push(text);\n }\n }\n return labelCollection;\n}\n/** @private */\nexport function stringToNumber(value, containerSize) {\n if (value !== null && value !== undefined) {\n return value.indexOf('%') !== -1 ? (containerSize / 100) * parseInt(value, 10) : parseInt(value, 10);\n }\n return null;\n}\n/** @private */\nexport function redrawElement(redraw, id, options, renderer) {\n if (!redraw) {\n return null;\n }\n var element = getElement(id);\n if (element && options) {\n renderer.setElementAttributes(options, element.tagName === 'clipPath' ? element.childNodes[0] : element);\n }\n return element;\n}\n/** @private */\nexport function animateRedrawElement(element, duration, start, end, x, y) {\n if (x === void 0) { x = 'x'; }\n if (y === void 0) { y = 'y'; }\n var isDiv = element.tagName === 'DIV';\n var setStyle = function (xValue, yValue) {\n if (isDiv) {\n element.style[x] = xValue + 'px';\n element.style[y] = yValue + 'px';\n }\n else {\n element.setAttribute(x, xValue + '');\n element.setAttribute(y, yValue + '');\n }\n };\n setStyle(start.x, start.y);\n new Animation({}).animate(createElement('div'), {\n duration: duration,\n progress: function (args) {\n setStyle(linear(args.timeStamp, start.x, end.x - start.x, args.duration), linear(args.timeStamp, start.y, end.y - start.y, args.duration));\n },\n end: function () {\n setStyle(end.x, end.y);\n }\n });\n}\n/** @private */\nexport function textElement(renderer, option, font, color, parent, isMinus, redraw, isAnimate, forceAnimate, animateDuration, seriesClipRect, labelSize, isRotatedLabelIntersect, isCanvas, isDataLabelWrap, themeFontStyle) {\n if (isMinus === void 0) { isMinus = false; }\n if (forceAnimate === void 0) { forceAnimate = false; }\n var renderOptions = {};\n var tspanElement;\n //let renderer: SvgRenderer = new SvgRenderer('');\n var height;\n var dy;\n var label;\n var width = 0;\n var dx;\n var maxWidth = 0;\n if (option.text.length > 1 && isDataLabelWrap) {\n for (var i = 0, len = option.text.length; i < len; i++) {\n maxWidth = Math.max(maxWidth, measureText(option.text[i], font, themeFontStyle).width);\n }\n width = measureText(option.text[0], font, themeFontStyle).width;\n }\n dx = (option.text.length > 1 && isDataLabelWrap) ? (option.x + maxWidth / 2 - width / 2) : option.x;\n renderOptions = {\n 'id': option.id,\n 'x': dx,\n 'y': option.y,\n 'fill': color ? color : 'black',\n 'font-size': font.size,\n 'font-style': font.fontStyle,\n 'font-family': font.fontFamily || themeFontStyle.fontFamily,\n 'font-weight': font.fontWeight,\n 'text-anchor': option.anchor,\n 'labelRotation': option.labelRotation,\n 'transform': option.transform,\n 'opacity': font.opacity,\n 'dominant-baseline': option.baseLine\n };\n var text = typeof option.text === 'string' ? option.text : isMinus ? option.text[option.text.length - 1] : option.text[0];\n var transX = seriesClipRect ? seriesClipRect.x : 0;\n var transY = seriesClipRect ? seriesClipRect.y : 0;\n var htmlObject = renderer.createText(renderOptions, text, transX, transY);\n if (typeof option.text !== 'string' && option.text.length > 1) {\n for (var i = 1, len = option.text.length; i < len; i++) {\n height = (measureText(option.text[i], font, themeFontStyle).height);\n width = measureText(option.text[i], font, themeFontStyle).width;\n dy = (option.y) + ((isMinus) ? -(i * height) : (i * height));\n dx = isDataLabelWrap ? (option.x + maxWidth / 2 - width / 2) : option.x;\n label = isMinus ? option.text[option.text.length - (i + 1)] : option.text[i];\n if (isCanvas) {\n tspanElement = renderer.createText(renderOptions, label, null, null, dy, true);\n }\n else {\n tspanElement = renderer.createTSpan({\n 'x': dx, 'id': option.id,\n 'y': dy\n }, label);\n htmlObject.appendChild(tspanElement);\n }\n }\n }\n if (!isRotatedLabelIntersect) {\n appendChildElement(renderer instanceof CanvasRenderer, parent, htmlObject, redraw, isAnimate, 'x', 'y', null, null, forceAnimate, false, null, animateDuration);\n }\n return htmlObject;\n}\n/**\n * Method to calculate the width and height of the chart.\n */\nexport function calculateSize(chart) {\n // fix for Chart rendered with default width in IE issue\n var containerWidth = chart.element.clientWidth || chart.element.offsetWidth;\n var containerHeight = chart.element.clientHeight;\n if (chart.stockChart) {\n containerWidth = chart.stockChart.availableSize.width;\n containerHeight = chart.stockChart.availableSize.height;\n }\n var height = 450;\n var marginHeight;\n if (chart.getModuleName() === 'rangeNavigator') {\n var range = chart;\n var tooltipSpace = range.tooltip.enable ? 35 : 0;\n var periodHeight = range.periodSelectorSettings.periods.length ?\n range.periodSelectorSettings.height : 0;\n marginHeight = range.margin.top + range.margin.bottom + tooltipSpace;\n var labelSize = measureText('tempString', range.labelStyle, range.themeStyle.axisLabelFont).height;\n var labelPadding = 15;\n height = (chart.series.length ? (Browser.isDevice ? 80 : 120) : ((range.enableGrouping ? (40 + labelPadding + labelSize) : 40)\n + marginHeight)) + periodHeight;\n if (range.disableRangeSelector) {\n height = periodHeight;\n }\n }\n chart.availableSize = new Size(stringToNumber(chart.width, containerWidth) || containerWidth || 600, stringToNumber(chart.height, containerHeight || height) || containerHeight || height);\n if (chart.getModuleName() === 'chart') {\n var scaleX = 1;\n var scaleY = 1;\n if (chart.width === '' || chart.width === null || chart.width === '100%') {\n scaleX = chart.element.getBoundingClientRect().width > 0 ?\n chart.element.getBoundingClientRect().width / chart.availableSize.width : 1;\n scaleY = chart.element.getBoundingClientRect().height > 0 ?\n chart.element.getBoundingClientRect().height / chart.availableSize.height : 1;\n var transformValue = chart.element.style.transform;\n if (transformValue) {\n var scaleValue = parseFloat(transformValue.match(/scale\\((.*?)\\)/)[1]);\n scaleX = scaleValue ? scaleX / scaleValue : scaleX;\n scaleY = scaleValue ? scaleY / scaleValue : scaleY;\n }\n chart.availableSize.width = chart.availableSize.width * scaleX;\n chart.availableSize.height = chart.availableSize.height * scaleY;\n chart.scaleX = scaleX;\n chart.scaleY = scaleY;\n }\n }\n}\n/**\n * To create svg element.\n *\n * @param {Chart} chart chart instance\n */\nexport function createSvg(chart) {\n chart.canvasRender = new CanvasRenderer(chart.element.id);\n chart.renderer = chart.enableCanvas ? chart.canvasRender : new SvgRenderer(chart.element.id);\n calculateSize(chart);\n if (chart.stockChart && chart.getModuleName() === 'chart') {\n chart.svgObject = chart.stockChart.chartObject;\n }\n else if (chart.stockChart && chart.getModuleName() === 'rangeNavigator') {\n chart.svgObject = chart.stockChart.selectorObject;\n }\n else {\n if (chart.enableCanvas) {\n chart.svgObject = chart.renderer.createCanvas({\n id: chart.element.id + '_canvas',\n width: chart.availableSize.width,\n height: chart.availableSize.height\n });\n }\n else {\n chart.svgObject = chart.renderer.createSvg({\n id: chart.element.id + '_svg',\n width: chart.availableSize.width,\n height: chart.availableSize.height\n });\n }\n }\n if (chart.enableCanvas) {\n chart.renderer.ctx.direction = chart.enableRtl ? 'rtl' : 'ltr';\n }\n}\n/**\n * To calculate chart title and height.\n *\n * @param {string} title text of the title\n * @param {FontModel} style style of the title\n * @param {number} width width of the title\n */\nexport function getTitle(title, style, width, isRtlEnabled, themeFontStyle) {\n var titleCollection = [];\n switch (style.textOverflow) {\n case 'Wrap':\n titleCollection = textWrap(title, width, style, isRtlEnabled, null, null, themeFontStyle);\n break;\n case 'Trim':\n titleCollection.push(textTrim(width, title, style, isRtlEnabled, themeFontStyle));\n break;\n default:\n titleCollection.push(title);\n break;\n }\n return titleCollection;\n}\n/**\n * Method to calculate x position of title.\n */\nexport function titlePositionX(rect, titleStyle) {\n var positionX;\n if (titleStyle.textAlignment === 'Near') {\n positionX = rect.x;\n }\n else if (titleStyle.textAlignment === 'Center') {\n positionX = rect.x + rect.width / 2;\n }\n else {\n positionX = rect.x + rect.width;\n }\n return positionX;\n}\n/**\n * Method to find new text and element size based on textOverflow.\n */\nexport function textWrap(currentLabel, maximumWidth, font, isRtlEnabled, wrapAnyWhere, clip, themeFontStyle) {\n if (wrapAnyWhere) {\n return (textWrapAnyWhere(currentLabel, maximumWidth, font, themeFontStyle));\n }\n else {\n var textCollection = currentLabel.split(' ');\n var label = '';\n var labelCollection = [];\n var text = void 0;\n for (var i = 0, len = textCollection.length; i < len; i++) {\n text = textCollection[i];\n if (measureText(label.concat(label === '' ? '' : ' ' + text), font, themeFontStyle).width < maximumWidth) {\n label = label.concat((label === '' ? '' : ' ') + text);\n }\n else {\n if (label !== '') {\n labelCollection.push(clip ? label : textTrim(maximumWidth, label, font, isRtlEnabled, themeFontStyle));\n label = text;\n }\n else {\n labelCollection.push(clip ? text : textTrim(maximumWidth, text, font, isRtlEnabled, themeFontStyle));\n text = '';\n }\n }\n if (label && i === len - 1) {\n labelCollection.push(clip ? label : textTrim(maximumWidth, label, font, isRtlEnabled, themeFontStyle));\n }\n }\n return labelCollection;\n }\n}\n/**\n * Method to find new text and element size based on textWrap.\n */\nexport function textWrapAnyWhere(currentLabel, maximumWidth, font, themeFontStyle) {\n var size = measureText(currentLabel, font, themeFontStyle).width;\n var labelCollection = [];\n if (size > maximumWidth) {\n var label = '';\n var startIndex = 0;\n var labelIndex = 1;\n while (labelIndex < currentLabel.length) {\n label = currentLabel.substring(startIndex, labelIndex);\n size = measureText(label, font, themeFontStyle).width;\n if (size < maximumWidth) {\n labelIndex++;\n }\n else if (size === maximumWidth) {\n startIndex = labelIndex;\n labelCollection.push(label);\n labelIndex++;\n label = '';\n }\n else if (size > maximumWidth) {\n label = label.slice(0, -1);\n startIndex = labelIndex - 1;\n labelCollection.push(label);\n label = '';\n }\n }\n if (label.length > 0) {\n labelCollection.push(label);\n }\n }\n else {\n labelCollection.push(currentLabel);\n }\n return labelCollection;\n}\n/**\n * Method to support the subscript and superscript value to text.\n */\nexport function getUnicodeText(text, regexp) {\n var title = text.replace(regexp, ' ');\n var digit = text.match(regexp);\n var digitSpecific = ' ';\n var convertedText = ' ';\n var k = 0;\n var unicodeSub = {\n '0': '\\u2080', '1': '\\u2081', '2': '\\u2082', '3': '\\u2083', '4': '\\u2084',\n '5': '\\u2085', '6': '\\u2086', '7': '\\u2087', '8': '\\u2088', '9': '\\u2089'\n };\n var unicodeSup = {\n '0': '\\u2070', '1': '\\u00B9', '2': '\\u00B2', '3': '\\u00B3', '4': '\\u2074',\n '5': '\\u2075', '6': '\\u2076', '7': '\\u2077', '8': '\\u2078', '9': '\\u2079'\n };\n for (var i = 0; i <= title.length - 1; i++) {\n if (title[i] === ' ') {\n digitSpecific = (regexp === regSub) ? digit[k].replace(/~/g, '') : digit[k].replace(/\\^/g, '');\n for (var j = 0; j < digitSpecific.length; j++) {\n convertedText += (regexp === regSub) ? unicodeSub[digitSpecific[j]] : unicodeSup[digitSpecific[j]];\n }\n k++;\n }\n else {\n convertedText += title[i];\n }\n }\n return convertedText.trim();\n}\n/**\n * Method to reset the blazor templates.\n */\nexport function blazorTemplatesReset(control) {\n for (var i = 0; i < control.annotations.length; i++) {\n resetBlazorTemplate((control.element.id + '_Annotation_' + i).replace(/[^a-zA-Z0-9]/g, ''), 'ContentTemplate');\n }\n //This reset the tooltip templates\n resetBlazorTemplate(control.element.id + '_tooltipparent_template' + '_blazorTemplate', 'Template');\n //Datalabel templates reset\n resetBlazorTemplate(control.element.id + '_DataLabel');\n}\n/** @private */\nvar CustomizeOption = /** @class */ (function () {\n function CustomizeOption(id) {\n this.id = id;\n }\n return CustomizeOption;\n}());\nexport { CustomizeOption };\n/** @private */\nvar StackValues = /** @class */ (function () {\n function StackValues(startValue, endValue) {\n this.startValues = startValue;\n this.endValues = endValue;\n }\n return StackValues;\n}());\nexport { StackValues };\n/** @private */\nvar RectOption = /** @class */ (function (_super) {\n __extends(RectOption, _super);\n function RectOption(id, fill, border, opacity, rect, rx, ry, transform, dashArray) {\n var _this = _super.call(this, id, fill, border.width, border.color, opacity, dashArray) || this;\n _this.y = rect.y;\n _this.x = rect.x;\n _this.height = rect.height;\n _this.width = rect.width;\n _this.rx = rx ? rx : 0;\n _this.ry = ry ? ry : 0;\n _this.transform = transform ? transform : '';\n _this.stroke = (border.width !== 0 && _this.stroke !== '') ? border.color === null ? '' : border.color : 'transparent';\n return _this;\n }\n return RectOption;\n}(PathOption));\nexport { RectOption };\n/** @private */\nvar ImageOption = /** @class */ (function () {\n function ImageOption(height, width, href, x, y, id, visibility, preserveAspectRatio) {\n this.height = height;\n this.width = width;\n this.href = href;\n this.x = x;\n this.y = y;\n this.id = id;\n this.visibility = visibility;\n this.preserveAspectRatio = preserveAspectRatio;\n }\n return ImageOption;\n}());\nexport { ImageOption };\n/** @private */\nvar CircleOption = /** @class */ (function (_super) {\n __extends(CircleOption, _super);\n function CircleOption(id, fill, border, opacity, cx, cy, r) {\n var _this = _super.call(this, id, fill, border.width, border.color, opacity) || this;\n _this.cy = cy;\n _this.cx = cx;\n _this.r = r;\n return _this;\n }\n return CircleOption;\n}(PathOption));\nexport { CircleOption };\n/** @private */\nvar PolygonOption = /** @class */ (function () {\n function PolygonOption(id, points, fill) {\n this.id = id;\n this.points = points;\n this.fill = fill;\n }\n return PolygonOption;\n}());\nexport { PolygonOption };\n/** @private */\nvar ChartLocation = /** @class */ (function () {\n function ChartLocation(x, y) {\n this.x = x;\n this.y = y;\n }\n return ChartLocation;\n}());\nexport { ChartLocation };\n/** @private */\nvar LabelLocation = /** @class */ (function () {\n function LabelLocation(x, y) {\n this.x = 0;\n this.y = 0;\n this.x = x;\n this.y = y;\n }\n return LabelLocation;\n}());\nexport { LabelLocation };\n/** @private */\nvar Thickness = /** @class */ (function () {\n function Thickness(left, right, top, bottom) {\n this.left = left;\n this.right = right;\n this.top = top;\n this.bottom = bottom;\n }\n return Thickness;\n}());\nexport { Thickness };\n/** @private */\nvar ColorValue = /** @class */ (function () {\n function ColorValue(r, g, b) {\n this.r = r;\n this.g = g;\n this.b = b;\n }\n return ColorValue;\n}());\nexport { ColorValue };\n/** @private */\nvar PointData = /** @class */ (function () {\n function PointData(point, series, index) {\n if (index === void 0) { index = 0; }\n this.point = point;\n this.series = series;\n this.lierIndex = index;\n }\n return PointData;\n}());\nexport { PointData };\n/** @private */\nvar AccPointData = /** @class */ (function () {\n function AccPointData(point, series, index) {\n if (index === void 0) { index = 0; }\n this.point = point;\n this.series = series;\n this.index = index;\n }\n return AccPointData;\n}());\nexport { AccPointData };\n/** @private */\nvar Point3D = /** @class */ (function () {\n /** @private */\n function Point3D(point, series) {\n this.point = point;\n this.series = series;\n }\n return Point3D;\n}());\nexport { Point3D };\n/** @private */\nvar ControlPoints = /** @class */ (function () {\n function ControlPoints(controlPoint1, controlPoint2) {\n this.controlPoint1 = controlPoint1;\n this.controlPoint2 = controlPoint2;\n }\n return ControlPoints;\n}());\nexport { ControlPoints };\n/** @private */\nexport function getColorByValue(colorMap, value) {\n var color = '';\n var rbgColorValue;\n if (Number(value) === colorMap.start) {\n color = colorMap.colors[0];\n }\n else if (Number(value) === colorMap.end) {\n color = colorMap.colors[colorMap.colors.length - 1];\n }\n else {\n rbgColorValue = getGradientColor(Number(value), colorMap);\n color = convertToHexCode(rbgColorValue);\n }\n return color;\n}\n/** @private */\nexport function getGradientColor(value, colorMap) {\n var previousOffset = colorMap.start;\n var nextOffset = colorMap.end;\n var percent = 0;\n var full = nextOffset - previousOffset;\n var midColor;\n percent = (value - previousOffset) / full;\n var previousColor;\n var nextColor;\n if (colorMap.colors.length <= 2) {\n previousColor = colorMap.colors[0].charAt(0) === '#' ? colorMap.colors[0] : colorNameToHex(colorMap.colors[0]);\n nextColor = colorMap.colors[colorMap.colors.length - 1].charAt(0) === '#' ?\n colorMap.colors[colorMap.colors.length - 1] : colorNameToHex(colorMap.colors[colorMap.colors.length - 1]);\n }\n else {\n previousColor = colorMap.colors[0].charAt(0) === '#' ? colorMap.colors[0] : colorNameToHex(colorMap.colors[0]);\n nextColor = colorMap.colors[colorMap.colors.length - 1].charAt(0) === '#' ?\n colorMap.colors[colorMap.colors.length - 1] : colorNameToHex(colorMap.colors[colorMap.colors.length - 1]);\n var a = full / (colorMap.colors.length - 1);\n var b = void 0;\n var c = void 0;\n var length_2 = colorMap.colors.length - 1;\n var splitColorValueOffset = [];\n var splitColor = {};\n for (var j = 1; j < length_2; j++) {\n c = j * a;\n b = previousOffset + c;\n splitColor = { b: b, color: colorMap.colors[j] };\n splitColorValueOffset.push(splitColor);\n }\n for (var i = 0; i < splitColorValueOffset.length; i++) {\n if (previousOffset <= value && value <= splitColorValueOffset[i]['b'] && i === 0) {\n midColor = splitColorValueOffset[i]['color'].charAt(0) === '#' ?\n splitColorValueOffset[i]['color'] : colorNameToHex(splitColorValueOffset[i]['color']);\n nextColor = midColor;\n percent = value <= splitColorValueOffset[i]['b'] ? 1 - Math.abs((value - splitColorValueOffset[i]['b']) / a)\n : (value - splitColorValueOffset[i]['b']) / a;\n }\n else if (splitColorValueOffset[i]['b'] <= value && value <= nextOffset && i === (splitColorValueOffset.length - 1)) {\n midColor = splitColorValueOffset[i]['color'].charAt(0) === '#' ?\n splitColorValueOffset[i]['color'] : colorNameToHex(splitColorValueOffset[i]['color']);\n previousColor = midColor;\n percent = value < splitColorValueOffset[i]['b'] ?\n 1 - Math.abs((value - splitColorValueOffset[i]['b']) / a) : (value - splitColorValueOffset[i]['b']) / a;\n }\n if (i !== splitColorValueOffset.length - 1 && i < splitColorValueOffset.length) {\n if (splitColorValueOffset[i]['b'] <= value && value <= splitColorValueOffset[i + 1]['b']) {\n midColor = splitColorValueOffset[i]['color'].charAt(0) === '#' ?\n splitColorValueOffset[i]['color'] : colorNameToHex(splitColorValueOffset[i]['color']);\n previousColor = midColor;\n nextColor = splitColorValueOffset[i + 1]['color'].charAt(0) === '#' ?\n splitColorValueOffset[i + 1]['color'] : colorNameToHex(splitColorValueOffset[i + 1]['color']);\n percent = Math.abs((value - splitColorValueOffset[i + 1]['b'])) / a;\n }\n }\n }\n }\n return getPercentageColor(percent, previousColor, nextColor);\n}\n/** @private */\nexport function getPercentageColor(percent, previous, next) {\n var nextColor = next.split('#')[1];\n var prevColor = previous.split('#')[1];\n var r = getPercentage(percent, parseInt(prevColor.substr(0, 2), 16), parseInt(nextColor.substr(0, 2), 16));\n var g = getPercentage(percent, parseInt(prevColor.substr(2, 2), 16), parseInt(nextColor.substr(2, 2), 16));\n var b = getPercentage(percent, parseInt(prevColor.substr(4, 2), 16), parseInt(nextColor.substr(4, 2), 16));\n return new ColorValue(r, g, b);\n}\n/** @private */\nexport function getPercentage(percent, previous, next) {\n var full = next - previous;\n return Math.round((previous + (full * percent)));\n}\n/** @private */\nexport function getTextAnchor(alignment, enableRTL) {\n switch (alignment) {\n case 'Near':\n return enableRTL ? 'end' : 'start';\n case 'Far':\n return enableRTL ? 'start' : 'end';\n default:\n return 'middle';\n }\n}\n","//! moment.js locale configuration\n//! locale : French (Canada) [fr-ca]\n//! author : Jonathan Abourbih : https://github.com/jonbca\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var frCa = moment.defineLocale('fr-ca', {\n months: 'janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre'.split(\n '_'\n ),\n monthsShort:\n 'janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),\n weekdaysShort: 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),\n weekdaysMin: 'di_lu_ma_me_je_ve_sa'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'YYYY-MM-DD',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Aujourd’hui à ] LT',\n nextDay: '[Demain à ] LT',\n nextWeek: 'dddd [à ] LT',\n lastDay: '[Hier à ] LT',\n lastWeek: 'dddd [dernier à ] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'dans %s',\n past: 'il y a %s',\n s: 'quelques secondes',\n ss: '%d secondes',\n m: 'une minute',\n mm: '%d minutes',\n h: 'une heure',\n hh: '%d heures',\n d: 'un jour',\n dd: '%d jours',\n M: 'un mois',\n MM: '%d mois',\n y: 'un an',\n yy: '%d ans',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(er|e)/,\n ordinal: function (number, period) {\n switch (period) {\n // Words with masculine grammatical gender: mois, trimestre, jour\n default:\n case 'M':\n case 'Q':\n case 'D':\n case 'DDD':\n case 'd':\n return number + (number === 1 ? 'er' : 'e');\n\n // Words with feminine grammatical gender: semaine\n case 'w':\n case 'W':\n return number + (number === 1 ? 're' : 'e');\n }\n },\n });\n\n return frCa;\n\n})));\n","//! moment.js locale configuration\n//! locale : Dutch (Belgium) [nl-be]\n//! author : Joris Röling : https://github.com/jorisroling\n//! author : Jacob Middag : https://github.com/middagj\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsShortWithDots =\n 'jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.'.split('_'),\n monthsShortWithoutDots =\n 'jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec'.split('_'),\n monthsParse = [\n /^jan/i,\n /^feb/i,\n /^maart|mrt.?$/i,\n /^apr/i,\n /^mei$/i,\n /^jun[i.]?$/i,\n /^jul[i.]?$/i,\n /^aug/i,\n /^sep/i,\n /^okt/i,\n /^nov/i,\n /^dec/i,\n ],\n monthsRegex =\n /^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december|jan\\.?|feb\\.?|mrt\\.?|apr\\.?|ju[nl]\\.?|aug\\.?|sep\\.?|okt\\.?|nov\\.?|dec\\.?)/i;\n\n var nlBe = moment.defineLocale('nl-be', {\n months: 'januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december'.split(\n '_'\n ),\n monthsShort: function (m, format) {\n if (!m) {\n return monthsShortWithDots;\n } else if (/-MMM-/.test(format)) {\n return monthsShortWithoutDots[m.month()];\n } else {\n return monthsShortWithDots[m.month()];\n }\n },\n\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex:\n /^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december)/i,\n monthsShortStrictRegex:\n /^(jan\\.?|feb\\.?|mrt\\.?|apr\\.?|mei|ju[nl]\\.?|aug\\.?|sep\\.?|okt\\.?|nov\\.?|dec\\.?)/i,\n\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n\n weekdays:\n 'zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag'.split('_'),\n weekdaysShort: 'zo._ma._di._wo._do._vr._za.'.split('_'),\n weekdaysMin: 'zo_ma_di_wo_do_vr_za'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[vandaag om] LT',\n nextDay: '[morgen om] LT',\n nextWeek: 'dddd [om] LT',\n lastDay: '[gisteren om] LT',\n lastWeek: '[afgelopen] dddd [om] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'over %s',\n past: '%s geleden',\n s: 'een paar seconden',\n ss: '%d seconden',\n m: 'één minuut',\n mm: '%d minuten',\n h: 'één uur',\n hh: '%d uur',\n d: 'één dag',\n dd: '%d dagen',\n M: 'één maand',\n MM: '%d maanden',\n y: 'één jaar',\n yy: '%d jaar',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(ste|de)/,\n ordinal: function (number) {\n return (\n number +\n (number === 1 || number === 8 || number >= 20 ? 'ste' : 'de')\n );\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return nlBe;\n\n})));\n","//! moment.js locale configuration\n//! locale : Hindi [hi]\n//! author : Mayank Singhal : https://github.com/mayanksinghal\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '१',\n 2: '२',\n 3: '३',\n 4: '४',\n 5: '५',\n 6: '६',\n 7: 'à¥',\n 8: '८',\n 9: '९',\n 0: '०',\n },\n numberMap = {\n '१': '1',\n '२': '2',\n '३': '3',\n '४': '4',\n '५': '5',\n '६': '6',\n 'à¥': '7',\n '८': '8',\n '९': '9',\n '०': '0',\n },\n monthsParse = [\n /^जन/i,\n /^फ़र|फर/i,\n /^मारà¥à¤š/i,\n /^अपà¥à¤°à¥ˆ/i,\n /^मई/i,\n /^जून/i,\n /^जà¥à¤²/i,\n /^अग/i,\n /^सितं|सित/i,\n /^अकà¥à¤Ÿà¥‚/i,\n /^नव|नवं/i,\n /^दिसं|दिस/i,\n ],\n shortMonthsParse = [\n /^जन/i,\n /^फ़र/i,\n /^मारà¥à¤š/i,\n /^अपà¥à¤°à¥ˆ/i,\n /^मई/i,\n /^जून/i,\n /^जà¥à¤²/i,\n /^अग/i,\n /^सित/i,\n /^अकà¥à¤Ÿà¥‚/i,\n /^नव/i,\n /^दिस/i,\n ];\n\n var hi = moment.defineLocale('hi', {\n months: {\n format: 'जनवरी_फ़रवरी_मारà¥à¤š_अपà¥à¤°à¥ˆà¤²_मई_जून_जà¥à¤²à¤¾à¤ˆ_अगसà¥à¤¤_सितमà¥à¤¬à¤°_अकà¥à¤Ÿà¥‚बर_नवमà¥à¤¬à¤°_दिसमà¥à¤¬à¤°'.split(\n '_'\n ),\n standalone:\n 'जनवरी_फरवरी_मारà¥à¤š_अपà¥à¤°à¥ˆà¤²_मई_जून_जà¥à¤²à¤¾à¤ˆ_अगसà¥à¤¤_सितंबर_अकà¥à¤Ÿà¥‚बर_नवंबर_दिसंबर'.split(\n '_'\n ),\n },\n monthsShort:\n 'जन._फ़र._मारà¥à¤š_अपà¥à¤°à¥ˆ._मई_जून_जà¥à¤²._अग._सित._अकà¥à¤Ÿà¥‚._नव._दिस.'.split('_'),\n weekdays: 'रविवार_सोमवार_मंगलवार_बà¥à¤§à¤µà¤¾à¤°_गà¥à¤°à¥‚वार_शà¥à¤•à¥à¤°à¤µà¤¾à¤°_शनिवार'.split('_'),\n weekdaysShort: 'रवि_सोम_मंगल_बà¥à¤§_गà¥à¤°à¥‚_शà¥à¤•à¥à¤°_शनि'.split('_'),\n weekdaysMin: 'र_सो_मं_बà¥_गà¥_शà¥_श'.split('_'),\n longDateFormat: {\n LT: 'A h:mm बजे',\n LTS: 'A h:mm:ss बजे',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm बजे',\n LLLL: 'dddd, D MMMM YYYY, A h:mm बजे',\n },\n\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: shortMonthsParse,\n\n monthsRegex:\n /^(जनवरी|जन\\.?|फ़रवरी|फरवरी|फ़र\\.?|मारà¥à¤š?|अपà¥à¤°à¥ˆà¤²|अपà¥à¤°à¥ˆ\\.?|मई?|जून?|जà¥à¤²à¤¾à¤ˆ|जà¥à¤²\\.?|अगसà¥à¤¤|अग\\.?|सितमà¥à¤¬à¤°|सितंबर|सित\\.?|अकà¥à¤Ÿà¥‚बर|अकà¥à¤Ÿà¥‚\\.?|नवमà¥à¤¬à¤°|नवंबर|नव\\.?|दिसमà¥à¤¬à¤°|दिसंबर|दिस\\.?)/i,\n\n monthsShortRegex:\n /^(जनवरी|जन\\.?|फ़रवरी|फरवरी|फ़र\\.?|मारà¥à¤š?|अपà¥à¤°à¥ˆà¤²|अपà¥à¤°à¥ˆ\\.?|मई?|जून?|जà¥à¤²à¤¾à¤ˆ|जà¥à¤²\\.?|अगसà¥à¤¤|अग\\.?|सितमà¥à¤¬à¤°|सितंबर|सित\\.?|अकà¥à¤Ÿà¥‚बर|अकà¥à¤Ÿà¥‚\\.?|नवमà¥à¤¬à¤°|नवंबर|नव\\.?|दिसमà¥à¤¬à¤°|दिसंबर|दिस\\.?)/i,\n\n monthsStrictRegex:\n /^(जनवरी?|फ़रवरी|फरवरी?|मारà¥à¤š?|अपà¥à¤°à¥ˆà¤²?|मई?|जून?|जà¥à¤²à¤¾à¤ˆ?|अगसà¥à¤¤?|सितमà¥à¤¬à¤°|सितंबर|सित?\\.?|अकà¥à¤Ÿà¥‚बर|अकà¥à¤Ÿà¥‚\\.?|नवमà¥à¤¬à¤°|नवंबर?|दिसमà¥à¤¬à¤°|दिसंबर?)/i,\n\n monthsShortStrictRegex:\n /^(जन\\.?|फ़र\\.?|मारà¥à¤š?|अपà¥à¤°à¥ˆ\\.?|मई?|जून?|जà¥à¤²\\.?|अग\\.?|सित\\.?|अकà¥à¤Ÿà¥‚\\.?|नव\\.?|दिस\\.?)/i,\n\n calendar: {\n sameDay: '[आज] LT',\n nextDay: '[कल] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[कल] LT',\n lastWeek: '[पिछले] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s में',\n past: '%s पहले',\n s: 'कà¥à¤› ही कà¥à¤·à¤£',\n ss: '%d सेकंड',\n m: 'à¤à¤• मिनट',\n mm: '%d मिनट',\n h: 'à¤à¤• घंटा',\n hh: '%d घंटे',\n d: 'à¤à¤• दिन',\n dd: '%d दिन',\n M: 'à¤à¤• महीने',\n MM: '%d महीने',\n y: 'à¤à¤• वरà¥à¤·',\n yy: '%d वरà¥à¤·',\n },\n preparse: function (string) {\n return string.replace(/[१२३४५६à¥à¥®à¥¯à¥¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n // Hindi notation for meridiems are quite fuzzy in practice. While there exists\n // a rigid notion of a 'Pahar' it is not used as rigidly in modern Hindi.\n meridiemParse: /रात|सà¥à¤¬à¤¹|दोपहर|शाम/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'रात') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'सà¥à¤¬à¤¹') {\n return hour;\n } else if (meridiem === 'दोपहर') {\n return hour >= 10 ? hour : hour + 12;\n } else if (meridiem === 'शाम') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'रात';\n } else if (hour < 10) {\n return 'सà¥à¤¬à¤¹';\n } else if (hour < 17) {\n return 'दोपहर';\n } else if (hour < 20) {\n return 'शाम';\n } else {\n return 'रात';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return hi;\n\n})));\n","import { isNullOrUndefined, attributes } from '@syncfusion/ej2-base';\nimport { iterateArrayOrObject } from '../base/util';\nimport { CellType } from '../base/enum';\n/**\n * `CellMergeRender` module.\n *\n * @hidden\n */\nvar CellMergeRender = /** @class */ (function () {\n function CellMergeRender(serviceLocator, parent) {\n this.serviceLocator = serviceLocator;\n this.parent = parent;\n }\n CellMergeRender.prototype.render = function (cellArgs, row, i, td) {\n var cellRendererFact = this.serviceLocator.getService('cellRendererFactory');\n var cellRenderer = cellRendererFact.getCellRenderer(row.cells[parseInt(i.toString(), 10)].cellType\n || CellType.Data);\n var colSpan = row.cells[parseInt(i.toString(), 10)].cellSpan ? row.cells[parseInt(i.toString(), 10)].cellSpan :\n (cellArgs.colSpan + i) <= row.cells.length ? cellArgs.colSpan : row.cells.length - i;\n var rowSpan = cellArgs.rowSpan;\n var visible = 0;\n var spannedCell;\n if (row.index > 0) {\n var rowsObject = this.parent.getRowsObject();\n var cells = this.parent.groupSettings.columns.length > 0 &&\n !rowsObject[row.index - 1].isDataRow ? rowsObject[row.index].cells : rowsObject[row.index - 1].cells;\n var targetCell_1 = row.cells[parseInt(i.toString(), 10)];\n var uid_1 = 'uid';\n spannedCell = cells.filter(function (cell) { return cell.column.uid === targetCell_1.column[\"\" + uid_1]; })[0];\n }\n var colSpanLen = spannedCell && spannedCell.colSpanRange > 1 && spannedCell.rowSpanRange > 1 ?\n spannedCell.colSpanRange : colSpan;\n for (var j = i + 1; j < i + colSpanLen && j < row.cells.length; j++) {\n if (row.cells[parseInt(j.toString(), 10)].visible === false) {\n visible++;\n }\n else {\n row.cells[parseInt(j.toString(), 10)].isSpanned = true;\n }\n }\n if (visible > 0) {\n for (var j = i + colSpan; j < i + colSpan + visible && j < row.cells.length; j++) {\n row.cells[parseInt(j.toString(), 10)].isSpanned = true;\n }\n if (i + colSpan + visible >= row.cells.length) {\n colSpan -= (i + colSpan + visible) - row.cells.length;\n }\n }\n if (row.cells[parseInt(i.toString(), 10)].cellSpan) {\n row.data[cellArgs.column.field] = row.cells[parseInt(i.toString(), 10)].spanText;\n td = cellRenderer.render(row.cells[parseInt(i.toString(), 10)], row.data, { 'index': !isNullOrUndefined(row.index) ? row.index.toString() : '' });\n }\n if (colSpan > 1) {\n attributes(td, { 'colSpan': colSpan.toString(), 'aria-colSpan': colSpan.toString() });\n }\n if (rowSpan > 1) {\n attributes(td, { 'rowspan': rowSpan.toString(), 'aria-rowspan': rowSpan.toString() });\n row.cells[parseInt(i.toString(), 10)].isRowSpanned = true;\n row.cells[parseInt(i.toString(), 10)].rowSpanRange = Number(rowSpan);\n if (colSpan > 1) {\n row.cells[parseInt(i.toString(), 10)].colSpanRange = Number(colSpan);\n }\n }\n if (row.index > 0 && (spannedCell.rowSpanRange > 1)) {\n row.cells[parseInt(i.toString(), 10)].isSpanned = true;\n row.cells[parseInt(i.toString(), 10)].rowSpanRange = Number(spannedCell.rowSpanRange - 1);\n row.cells[parseInt(i.toString(), 10)].colSpanRange = spannedCell.rowSpanRange > 0 ? spannedCell.colSpanRange : 1;\n }\n if (this.parent.enableColumnVirtualization && !row.cells[parseInt(i.toString(), 10)].cellSpan &&\n !this.containsKey(cellArgs.column.field, cellArgs.data[cellArgs.column.field])) {\n this.backupMergeCells(cellArgs.column.field, cellArgs.data[cellArgs.column.field], cellArgs.colSpan);\n }\n return td;\n };\n CellMergeRender.prototype.backupMergeCells = function (fName, data, span) {\n this.setMergeCells(this.generteKey(fName, data), span);\n };\n CellMergeRender.prototype.generteKey = function (fname, data) {\n return fname + '__' + data.toString();\n };\n CellMergeRender.prototype.splitKey = function (key) {\n return key.split('__');\n };\n CellMergeRender.prototype.containsKey = function (fname, data) {\n // eslint-disable-next-line no-prototype-builtins\n return this.getMergeCells().hasOwnProperty(this.generteKey(fname, data));\n };\n CellMergeRender.prototype.getMergeCells = function () {\n return this.parent.mergeCells;\n };\n CellMergeRender.prototype.setMergeCells = function (key, span) {\n this.parent.mergeCells[\"\" + key] = span;\n };\n CellMergeRender.prototype.updateVirtualCells = function (rows) {\n var mCells = this.getMergeCells();\n for (var _i = 0, _a = Object.keys(mCells); _i < _a.length; _i++) {\n var key = _a[_i];\n var value = mCells[\"\" + key];\n var merge = this.splitKey(key);\n var columnIndex = this.getIndexFromAllColumns(merge[0]);\n var vColumnIndices = this.parent.getColumnIndexesInView();\n var span = value - (vColumnIndices[0] - columnIndex);\n if (columnIndex < vColumnIndices[0] && span > 1) {\n for (var _b = 0, rows_1 = rows; _b < rows_1.length; _b++) {\n var row = rows_1[_b];\n if (row.data[merge[0]].toString() === merge[1].toString()) {\n row.cells[0].cellSpan = span;\n row.cells[0].spanText = merge[1];\n break;\n }\n }\n }\n }\n return rows;\n };\n CellMergeRender.prototype.getIndexFromAllColumns = function (field) {\n var index = iterateArrayOrObject(this.parent.getVisibleColumns(), function (item, index) {\n if (item.field === field) {\n return index;\n }\n return undefined;\n })[0];\n return index;\n };\n return CellMergeRender;\n}());\nexport { CellMergeRender };\n","import { EventHandler, extend, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { remove, select, removeClass } from '@syncfusion/ej2-base';\nimport { Toolbar as tool } from '@syncfusion/ej2-navigations';\nimport * as events from '../base/constant';\nimport { templateCompiler, appendChildren, parentsUntil, addRemoveEventListener, applyBiggerTheme } from '../base/util';\nimport { ResponsiveToolbarAction } from '../base/enum';\nimport { ContextMenu as Menu } from '@syncfusion/ej2-navigations';\nimport { calculatePosition } from '@syncfusion/ej2-popups';\nimport { SearchBox } from '../services/focus-strategy';\n/**\n *\n * The `Toolbar` module is used to handle ToolBar actions.\n */\nvar Toolbar = /** @class */ (function () {\n function Toolbar(parent, serviceLocator) {\n this.predefinedItems = {};\n this.isSearched = false;\n this.items = ['Add', 'Edit', 'Update', 'Delete', 'Cancel', 'Print', 'Search',\n 'ColumnChooser', 'PdfExport', 'ExcelExport', 'CsvExport', 'WordExport'];\n this.isRightToolbarMenu = false;\n this.parent = parent;\n this.gridID = parent.element.id;\n this.serviceLocator = serviceLocator;\n this.addEventListener();\n }\n Toolbar.prototype.render = function () {\n this.l10n = this.serviceLocator.getService('localization');\n var preItems = ['Add', 'Edit', 'Update', 'Delete', 'Cancel', 'Print',\n 'PdfExport', 'ExcelExport', 'WordExport', 'CsvExport'];\n var isAdaptive = this.parent.enableAdaptiveUI;\n var excludingItems = ['Edit', 'Delete', 'Update', 'Cancel'];\n for (var _i = 0, preItems_1 = preItems; _i < preItems_1.length; _i++) {\n var item = preItems_1[_i];\n var itemStr = item.toLowerCase();\n var localeName = itemStr[0].toUpperCase() + itemStr.slice(1);\n this.predefinedItems[\"\" + item] = {\n id: this.gridID + '_' + itemStr, prefixIcon: 'e-' + itemStr,\n text: this.l10n.getConstant(localeName), tooltipText: this.l10n.getConstant(localeName)\n };\n if (isAdaptive) {\n this.predefinedItems[\"\" + item].text = '';\n this.predefinedItems[\"\" + item].visible = excludingItems.indexOf(item) === -1;\n }\n }\n this.predefinedItems.Search = {\n id: this.gridID + '_search',\n tooltipText: this.l10n.getConstant('Search'), align: 'Right', cssClass: 'e-search-wrapper',\n type: 'Input'\n };\n this.isRightToolbarMenu = false;\n if (this.parent.enableAdaptiveUI && this.isResponsiveToolbarMenuItems(true) && ((this.parent.rowRenderingMode === 'Horizontal') ||\n (this.parent.rowRenderingMode === 'Vertical' && !this.parent.allowFiltering && !this.parent.allowSorting))) {\n this.isRightToolbarMenu = true;\n }\n if (isAdaptive && this.isResponsiveToolbarMenuItems(false)) {\n this.predefinedItems.responsiveToolbarItems = {\n id: this.gridID + '_' + 'responsivetoolbaritems', cssClass: 'e-responsive-toolbar-items e-menu-toolbar', suffixIcon: 'e-' + 'responsivetoolbaritems-btn',\n align: this.isRightToolbarMenu ? 'Left' : 'Right'\n };\n }\n else {\n this.predefinedItems.ColumnChooser = {\n id: this.gridID + '_' + 'columnchooser', cssClass: 'e-cc e-ccdiv e-cc-toolbar', suffixIcon: 'e-' + 'columnchooser-btn',\n text: isAdaptive ? '' : this.l10n.getConstant('Columnchooser'),\n tooltipText: this.l10n.getConstant('Columnchooser'), align: 'Right'\n };\n }\n if (this.parent.rowRenderingMode === 'Vertical') {\n if (this.parent.allowFiltering && this.parent.filterSettings.type !== 'FilterBar') {\n this.predefinedItems.responsiveFilter = {\n id: this.gridID + '_' + 'responsivefilter', cssClass: 'e-gridresponsiveicons e-icons',\n suffixIcon: 'e-' + 'resfilter-icon', tooltipText: this.l10n.getConstant('FilterButton')\n };\n }\n if (this.parent.allowSorting) {\n this.predefinedItems.responsiveSort = {\n id: this.gridID + '_' + 'responsivesort', cssClass: 'e-gridresponsiveicons e-icons',\n suffixIcon: 'e-' + 'ressort-icon', tooltipText: this.l10n.getConstant('Sort')\n };\n }\n }\n if (this.parent.enableAdaptiveUI && this.parent.toolbar && this.parent.toolbar.indexOf('Search') > -1) {\n this.predefinedItems.responsiveBack = {\n id: this.gridID + '_' + 'responsiveback', cssClass: 'e-gridresponsiveicons e-icons',\n suffixIcon: 'e-' + 'resback-icon', visible: false\n };\n }\n this.createToolbar();\n if (this.parent.enableAdaptiveUI) {\n if (isNullOrUndefined(this.responsiveToolbarMenu)) {\n this.renderResponsiveToolbarpopup();\n }\n this.toolbar.refreshOverflow();\n }\n };\n Toolbar.prototype.isResponsiveToolbarMenuItems = function (isRight) {\n var items = isRight ? ['Add', 'Edit', 'Delete', 'Search'] : ['Print', 'ColumnChooser', 'PdfExport', 'ExcelExport', 'CsvExport'];\n var toolbarItems = this.parent.toolbar || [];\n for (var i = 0; i < items.length; i++) {\n if (toolbarItems.indexOf(items[parseInt(i.toString(), 10)]) >= 0) {\n return isRight ? false : true;\n }\n }\n return isRight ? true : false;\n };\n /**\n * Gets the toolbar of the Grid.\n *\n * @returns {Element} returns the element\n * @hidden\n */\n Toolbar.prototype.getToolbar = function () {\n return this.toolbar.element;\n };\n /**\n * Destroys the ToolBar.\n *\n * @function destroy\n * @returns {void}\n */\n Toolbar.prototype.destroy = function () {\n if (this.toolbar && !this.toolbar.isDestroyed) {\n if (this.responsiveToolbarMenu) {\n this.responsiveToolbarMenu.destroy();\n }\n if (!this.toolbar.element) {\n this.parent.destroyTemplate(['toolbarTemplate']);\n if (this.parent.isReact) {\n this.parent.renderTemplates();\n }\n }\n else {\n this.toolbar.off('render-react-toolbar-template', this.addReactToolbarPortals);\n this.toolbar.destroy();\n }\n this.unWireEvent();\n this.removeEventListener();\n if (this.element.parentNode) {\n remove(this.element);\n }\n }\n };\n Toolbar.prototype.bindSearchEvents = function () {\n this.searchElement = select('#' + this.gridID + '_searchbar', this.element);\n this.wireEvent();\n this.refreshToolbarItems();\n if (this.parent.searchSettings) {\n this.updateSearchBox();\n }\n };\n Toolbar.prototype.toolbarCreated = function (isNormal) {\n if (this.element.querySelector('.e-search-wrapper')) {\n if (!this.parent.enableAdaptiveUI || isNormal) {\n var classList = this.parent.cssClass ? 'e-input-group e-search ' + this.parent.cssClass\n : 'e-input-group e-search';\n this.element.querySelector('.e-search-wrapper').innerHTML = '<div class=\"' + classList + '\" role=\"search\">\\\n <input id=\"' + this.gridID + '_searchbar\" class=\"e-input e-search\" name=\"input\" type=\"search\" \\\n placeholder= \"' + this.l10n.getConstant('Search') + '\"/>\\\n <span id=\"' + this.gridID + '_clearbutton\" class=\"e-input-group-icon e-icons e-sicon\" \\\n tabindex=\"-1\" aria-label= \"clear\" role= \"button\" style=\"cursor: default\"></span>\\\n <span id=\"' + this.gridID + '_searchbutton\" class=\"e-input-group-icon e-search-icon e-icons\" \\\n tabindex=\"-1\" title=\"' + this.l10n.getConstant('Search') + '\" role= \"search\"></span> \\\n </div>';\n }\n else {\n this.element.querySelector('.e-search-wrapper').innerHTML = '<span id=\"' + this.gridID\n + '_clearbutton\" class=\"e-input-group-icon e-icons e-sicon\" \\\n tabindex=\"-1\" role= \"button\" aria-label= \"clear\" style=\"cursor: default\"></span>\\\n <span id=\"' + this.gridID\n + '_searchbutton\" class=\"e-input-group-icon e-search-icon e-icons\" \\\n tabindex=\"-1\" role= \"button\" title=\"' + this.l10n.getConstant('Search') + '\"></span> \\\n </div>';\n }\n }\n if (this.element.querySelector('.e-responsive-toolbar-items')) {\n this.element.querySelector('.e-responsive-toolbar-items').innerHTML = '<button id=\"' + this.gridID\n + '_responsivetoolbaritems\" class=\"e-tbar-btn e-control e-btn e-lib e-icon-btn\" \\\n type=\"button\" data-ripple=\"true\" tabindex=\"-1\" data-tabindex=\"-1\" aria-label=\"responsivetoolbaritems\" \\\n aria-disabled=\"false\" style=\"width: auto;\"><span class=\"e-btn-icon e-responsivetoolbaritems-btn e-icons\"></span>';\n }\n this.bindSearchEvents();\n };\n Toolbar.prototype.createToolbar = function () {\n var items = this.getItems();\n this.toolbar = new tool({\n items: items,\n clicked: this.toolbarClickHandler.bind(this),\n enablePersistence: this.parent.enablePersistence,\n enableRtl: this.parent.enableRtl,\n created: this.toolbarCreated.bind(this),\n cssClass: this.parent.cssClass ? this.parent.cssClass : ''\n });\n this.toolbar.isReact = this.parent.isReact;\n this.toolbar.on('render-react-toolbar-template', this.addReactToolbarPortals, this);\n var isStringTemplate = 'isStringTemplate';\n this.toolbar[\"\" + isStringTemplate] = true;\n var viewStr = 'viewContainerRef';\n var registerTemp = 'registeredTemplate';\n if (this.parent[\"\" + viewStr]) {\n this.toolbar[\"\" + registerTemp] = {};\n this.toolbar[\"\" + viewStr] = this.parent[\"\" + viewStr];\n }\n this.element = this.parent.createElement('div', { id: this.gridID + '_toolbarItems' });\n if (this.parent.enableAdaptiveUI) {\n this.element.classList.add('e-res-toolbar');\n }\n if (this.parent.toolbarTemplate) {\n if (typeof (this.parent.toolbarTemplate) === 'string') {\n this.toolbar.appendTo(this.parent.toolbarTemplate);\n this.element = this.toolbar.element;\n }\n else {\n var isReactCompiler = this.parent.isReact && typeof (this.parent.toolbarTemplate) !== 'string';\n var isReactChild = this.parent.parentDetails && this.parent.parentDetails.parentInstObj &&\n this.parent.parentDetails.parentInstObj.isReact;\n var ID = this.parent.element.id + 'toolbarTemplate';\n if (isReactCompiler || isReactChild) {\n templateCompiler(this.parent.toolbarTemplate)({}, this.parent, 'toolbarTemplate', ID, null, null, this.element);\n this.parent.renderTemplates();\n }\n else {\n appendChildren(this.element, templateCompiler(this.parent.toolbarTemplate)({}, this.parent, 'toolbarTemplate'));\n }\n }\n this.element.classList.add('e-temp-toolbar');\n }\n else {\n this.toolbar.appendTo(this.element);\n }\n this.parent.element.insertBefore(this.element, this.parent.getHeaderContent());\n var tlbrLeftElement = this.element.querySelector('.e-toolbar-left');\n var tlbrCenterElement = this.element.querySelector('.e-toolbar-center');\n var tlbrRightElement = this.element.querySelector('.e-toolbar-right');\n var tlbrItems = this.element.querySelector('.e-toolbar-items');\n var tlbrElement = this.element;\n var tlbrLeftWidth = tlbrLeftElement ? tlbrLeftElement.clientWidth : 0;\n var tlbrCenterWidth = tlbrCenterElement ? tlbrCenterElement.clientWidth : 0;\n var tlbrRightWidth = tlbrRightElement ? tlbrRightElement.clientWidth : 0;\n var tlbrItemsWidth = tlbrItems ? tlbrItems.clientWidth : 0;\n var tlbrWidth = tlbrElement ? tlbrElement.clientWidth : 0;\n if (tlbrLeftWidth > tlbrWidth || tlbrCenterWidth > tlbrWidth || tlbrRightWidth > tlbrWidth || tlbrItemsWidth > tlbrWidth) {\n this.toolbar.refreshOverflow();\n }\n };\n Toolbar.prototype.addReactToolbarPortals = function (args) {\n if (this.parent.isReact && args) {\n this.parent.portals = this.parent.portals.concat(args);\n this.parent.renderTemplates();\n }\n };\n Toolbar.prototype.renderResponsiveSearch = function (isRender) {\n if (isRender) {\n this.toolbarCreated(true);\n this.refreshResponsiveToolbarItems(ResponsiveToolbarAction.isSearch);\n this.searchElement = select('#' + this.gridID + '_searchbar', this.element);\n var right = parentsUntil(this.searchElement, 'e-toolbar-right');\n right.classList.add('e-responsive-right');\n if (this.parent.searchSettings) {\n this.updateSearchBox();\n }\n this.searchBoxObj.searchFocus({ target: this.searchElement });\n this.searchElement.focus();\n }\n else {\n this.refreshResponsiveToolbarItems(ResponsiveToolbarAction.isInitial);\n }\n };\n Toolbar.prototype.refreshResponsiveToolbarItems = function (action) {\n if (action === ResponsiveToolbarAction.isInitial) {\n var id = this.parent.element.id;\n var items = [id + '_edit', id + '_delete'];\n var selectedRecords = this.parent.getSelectedRowIndexes();\n var excludingItems = [id + '_responsiveback', id + '_update', id + '_cancel'];\n for (var _i = 0, _a = this.toolbar.items; _i < _a.length; _i++) {\n var item = _a[_i];\n var toolbarEle = item.template.length ? this.toolbar.element.querySelector(item.template) : this.toolbar.element.querySelector('#' + item.id);\n if (toolbarEle) {\n if (items.indexOf(item.id) > -1) {\n if (selectedRecords.length) {\n toolbarEle.parentElement.classList.remove('e-hidden');\n }\n else {\n toolbarEle.parentElement.classList.add('e-hidden');\n }\n }\n else {\n if (excludingItems.indexOf(item.id) === -1) {\n toolbarEle.parentElement.classList.remove('e-hidden');\n }\n else {\n toolbarEle.parentElement.classList.add('e-hidden');\n }\n }\n }\n }\n if (this.searchElement) {\n var right = parentsUntil(this.searchElement, 'e-toolbar-right');\n right.classList.remove('e-responsive-right');\n this.toolbarCreated(false);\n this.unWireEvent();\n this.searchElement = undefined;\n }\n }\n if (action === ResponsiveToolbarAction.isSearch) {\n var items = [this.parent.element.id + '_responsiveback', this.parent.element.id + '_search'];\n for (var _b = 0, _c = this.toolbar.items; _b < _c.length; _b++) {\n var item = _c[_b];\n var toolbarEle = this.toolbar.element.querySelector('#' + item.id);\n if (toolbarEle) {\n if (items.indexOf(item.id) > -1) {\n toolbarEle.parentElement.classList.remove('e-hidden');\n }\n else {\n toolbarEle.parentElement.classList.add('e-hidden');\n }\n }\n }\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Toolbar.prototype.refreshToolbarItems = function (args) {\n var gObj = this.parent;\n var enableItems = [];\n var disableItems = [];\n var edit = gObj.editSettings;\n var hasData = gObj.currentViewData && gObj.currentViewData.length;\n if (edit.allowAdding) {\n enableItems.push(this.gridID + '_add');\n }\n else {\n disableItems.push(this.gridID + '_add');\n }\n if (edit.allowEditing && hasData) {\n enableItems.push(this.gridID + '_edit');\n }\n else {\n disableItems.push(this.gridID + '_edit');\n }\n if (edit.allowDeleting && hasData) {\n enableItems.push(this.gridID + '_delete');\n }\n else {\n disableItems.push(this.gridID + '_delete');\n }\n if (gObj.editSettings.mode === 'Batch') {\n if (gObj.element.getElementsByClassName('e-updatedtd').length && (edit.allowAdding || edit.allowEditing)) {\n enableItems.push(this.gridID + '_update');\n enableItems.push(this.gridID + '_cancel');\n }\n else {\n disableItems.push(this.gridID + '_update');\n disableItems.push(this.gridID + '_cancel');\n }\n }\n else {\n if (gObj.isEdit && (edit.allowAdding || edit.allowEditing)) {\n enableItems = [this.gridID + '_update', this.gridID + '_cancel'];\n disableItems = [this.gridID + '_add', this.gridID + '_edit', this.gridID + '_delete'];\n }\n else {\n disableItems.push(this.gridID + '_update');\n disableItems.push(this.gridID + '_cancel');\n }\n }\n this.enableItems(enableItems, true);\n this.enableItems(disableItems, false);\n };\n Toolbar.prototype.getItems = function () {\n var items = [];\n var toolbarItems = this.parent.toolbar || [];\n var toolbarItemsString = false;\n if (typeof (this.parent.toolbar) === 'string') {\n return [];\n }\n if (this.parent.rowRenderingMode === 'Vertical') {\n if (this.parent.allowFiltering && this.parent.filterSettings.type !== 'FilterBar') {\n items.push(this.getItemObject('responsiveFilter'));\n }\n if (this.parent.allowSorting) {\n items.push(this.getItemObject('responsiveSort'));\n }\n }\n for (var _i = 0, toolbarItems_1 = toolbarItems; _i < toolbarItems_1.length; _i++) {\n var item = toolbarItems_1[_i];\n if (this.parent.enableAdaptiveUI && ['Print', 'ColumnChooser',\n 'PdfExport', 'ExcelExport', 'CsvExport'].indexOf(item) !== -1) {\n toolbarItemsString = true;\n continue;\n }\n switch (typeof item) {\n case 'number':\n items.push(this.getItemObject(this.items[item]));\n break;\n case 'string':\n items.push(this.getItemObject(item));\n break;\n default:\n items.push(this.getItem(item));\n }\n }\n if (this.parent.enableAdaptiveUI && this.parent.toolbar && this.parent.toolbar.indexOf('Search') > -1) {\n items.push(this.getItemObject('responsiveBack'));\n }\n if (this.parent.enableAdaptiveUI && this.isResponsiveToolbarMenuItems(false)) {\n items.push(this.getItemObject('responsiveToolbarItems'));\n }\n return items;\n };\n Toolbar.prototype.getItem = function (itemObject) {\n var item = this.predefinedItems[itemObject.text];\n return item ? extend(item, item, itemObject) : itemObject;\n };\n Toolbar.prototype.getItemObject = function (itemName) {\n return this.predefinedItems[\"\" + itemName] || { text: itemName, id: this.gridID + '_' + itemName };\n };\n /**\n * Enables or disables ToolBar items.\n *\n * @param {string[]} items - Defines the collection of itemID of ToolBar items.\n * @param {boolean} isEnable - Defines the items to be enabled or disabled.\n * @returns {void}\n * @hidden\n */\n Toolbar.prototype.enableItems = function (items, isEnable) {\n for (var _i = 0, items_1 = items; _i < items_1.length; _i++) {\n var item = items_1[_i];\n var element = select('#' + item, this.element);\n if (element) {\n this.toolbar.enableItems(element.closest('.e-toolbar-item'), isEnable);\n }\n }\n };\n Toolbar.prototype.toolbarClickHandler = function (args) {\n var _this = this;\n var gObj = this.parent;\n var gID = this.gridID;\n var originalEvent = args.originalEvent;\n if (this.parent.enableAdaptiveUI && args.item.id === gID + '_responsivetoolbaritems') {\n this.openResponsiveToolbarMenuPopup(originalEvent, args.item.id);\n }\n else {\n extend(args, { cancel: false });\n var newArgs = args;\n gObj.trigger(events.toolbarClick, newArgs, function (toolbarargs) {\n toolbarargs.originalEvent = toolbarargs.originalEvent ? toolbarargs.originalEvent : originalEvent;\n if (!toolbarargs.cancel) {\n switch (!isNullOrUndefined(toolbarargs.item) && toolbarargs.item.id) {\n case gID + '_print':\n gObj.print();\n break;\n case gID + '_edit':\n gObj.startEdit();\n break;\n case gID + '_update':\n gObj.endEdit();\n break;\n case gID + '_cancel':\n gObj.closeEdit();\n break;\n case gID + '_add':\n gObj.addRecord();\n break;\n case gID + '_delete':\n gObj.deleteRecord();\n break;\n case gID + '_search':\n if (toolbarargs.originalEvent.target.id === gID + '_searchbutton' && _this.searchElement) {\n _this.search();\n }\n else if (gObj.enableAdaptiveUI && !_this.searchElement\n && (toolbarargs.originalEvent.target.classList.contains('e-search-wrapper')\n || toolbarargs.originalEvent.target.id === gID + '_searchbutton')) {\n _this.renderResponsiveSearch(true);\n }\n else if (toolbarargs.originalEvent.target.classList.contains('e-clear-icon') && toolbarargs.originalEvent.target.id === gID + '_clearbutton' && _this.searchElement) {\n _this.searchElement.value = '';\n if (_this.searchElement) {\n _this.sIcon = _this.searchElement.parentElement.querySelector('.e-sicon');\n _this.sIcon.classList.remove('e-clear-icon');\n _this.sIcon.removeAttribute('title');\n _this.sIcon.style.cursor = 'default';\n }\n if (_this.isSearched || _this.parent.searchSettings.key.length) {\n _this.parent.search(_this.searchElement.value);\n _this.isSearched = false;\n }\n }\n break;\n case gID + '_columnchooser':\n if (_this.parent.enableAdaptiveUI) {\n gObj.showResponsiveCustomColumnChooser();\n }\n else {\n /* eslint-disable */\n var tarElement = _this.parent.element.querySelector('.e-ccdiv');\n var y = tarElement.getBoundingClientRect().top;\n var x = tarElement.getBoundingClientRect().left;\n var targetEle = toolbarargs.originalEvent.target;\n /* eslint-enable */\n y = tarElement.getBoundingClientRect().top + tarElement.offsetTop;\n gObj.createColumnchooser(x, y, targetEle);\n }\n break;\n case gID + '_responsivefilter':\n gObj.notify(events.renderResponsiveChangeAction, { action: 3 });\n gObj.showResponsiveCustomFilter();\n break;\n case gID + '_responsivesort':\n gObj.notify(events.renderResponsiveChangeAction, { action: 2 });\n gObj.showResponsiveCustomSort();\n break;\n case gID + '_responsiveback':\n _this.renderResponsiveSearch(false);\n break;\n }\n }\n });\n }\n };\n Toolbar.prototype.openResponsiveToolbarMenuPopup = function (e, id) {\n var pos = { top: 0, left: 0 };\n this.toolbarMenuElement.style.cssText = 'display:block;visibility:hidden';\n var elePos = this.toolbarMenuElement.getBoundingClientRect();\n var gClient = this.parent.element.getBoundingClientRect();\n this.toolbarMenuElement.style.cssText = 'display:none;visibility:visible';\n var target;\n if (isNullOrUndefined(e)) {\n target = this.parent.element.querySelector('#' + id);\n }\n else {\n target = e.target;\n }\n if (this.parent.enableRtl) {\n pos = calculatePosition(target, 'left', 'bottom');\n if (this.isRightToolbarMenu) {\n pos.left -= elePos.width;\n }\n }\n else {\n pos = calculatePosition(target, 'right', 'bottom');\n if (!this.isRightToolbarMenu) {\n pos.left -= elePos.width;\n }\n if ((pos.left + elePos.width + 1) >= gClient.right) {\n pos.left -= 35;\n }\n }\n this.responsiveToolbarMenu['open'](pos.top, pos.left);\n if (e && e.preventDefault) {\n e.preventDefault();\n }\n applyBiggerTheme(this.parent.element, this.responsiveToolbarMenu.element.parentElement);\n };\n Toolbar.prototype.getMenuItems = function () {\n var items = [];\n var toolbarItems = this.parent.toolbar || [];\n for (var _i = 0, toolbarItems_2 = toolbarItems; _i < toolbarItems_2.length; _i++) {\n var item = toolbarItems_2[_i];\n if (typeof item === 'string' && (item === 'ColumnChooser' || item === 'PdfExport' || item === 'ExcelExport' ||\n item === 'CsvExport' || item === 'Print')) {\n items.push({\n text: this.getLocaleText(item),\n id: this.gridID + '_' + item.toLowerCase(),\n iconCss: 'e-btn-icon e-' + item.toLowerCase() + ' e-icons'\n });\n }\n }\n return items;\n };\n Toolbar.prototype.getLocaleText = function (item) {\n var title;\n if (item === 'ColumnChooser') {\n title = this.l10n.getConstant('Columnchooser');\n }\n else if (item === 'PdfExport') {\n title = this.l10n.getConstant('Pdfexport');\n }\n else if (item === 'ExcelExport') {\n title = this.l10n.getConstant('Excelexport');\n }\n else if (item === 'CsvExport') {\n title = this.l10n.getConstant('Csvexport');\n }\n else if (item === 'Print') {\n title = this.l10n.getConstant('Print');\n }\n return title;\n };\n Toolbar.prototype.renderResponsiveToolbarpopup = function () {\n this.l10n = this.serviceLocator.getService('localization');\n this.toolbarMenuElement = this.parent.createElement('ul', {\n id: this.gridID + '__toolbaritemsmenu', className: 'e-responsivetoolbar-menu'\n });\n this.element.setAttribute('aria-label', this.l10n.getConstant('ToolbarMenuDialogARIA'));\n this.parent.element.appendChild(this.toolbarMenuElement);\n this.responsiveToolbarMenu = new Menu({\n cssClass: this.parent.cssClass ? 'e-grid-toolbarmenu' + ' ' + this.parent.cssClass : 'e-grid-toolbarmenu',\n enableRtl: this.parent.enableRtl,\n enablePersistence: this.parent.enablePersistence,\n locale: this.parent.locale,\n items: this.getMenuItems(),\n select: this.ResponsiveToolbarMenuItemClick.bind(this),\n });\n this.responsiveToolbarMenu.appendTo(this.toolbarMenuElement);\n };\n Toolbar.prototype.ResponsiveToolbarMenuItemClick = function (args) {\n var _this = this;\n var gObj = this.parent;\n var element = args.element;\n args.item.id = element.id;\n var newArgs = { cancel: false, name: 'clicked', item: args.item, originalEvent: args.event };\n gObj.trigger(events.toolbarClick, newArgs, function (toolbarargs) {\n if (!toolbarargs.cancel) {\n switch (!isNullOrUndefined(toolbarargs.item) && toolbarargs.item.id) {\n case _this.gridID + '_columnchooser':\n gObj.notify(events.renderResponsiveChangeAction, { action: 5 });\n gObj.showResponsiveCustomColumnChooser();\n break;\n case _this.gridID + '_print':\n gObj.print();\n break;\n }\n }\n });\n };\n Toolbar.prototype.modelChanged = function (e) {\n if (e.module === 'edit') {\n this.refreshToolbarItems();\n }\n };\n Toolbar.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName() || !this.parent.toolbar) {\n return;\n }\n if (this.element) {\n remove(this.element);\n }\n this.render();\n };\n Toolbar.prototype.keyUpHandler = function (e) {\n if (e.keyCode === 13) {\n this.search();\n }\n if (this.searchElement) {\n this.sIcon = this.searchElement.parentElement.querySelector('.e-sicon');\n if (this.searchElement.value.length && !isNullOrUndefined(this.sIcon)) {\n this.sIcon.classList.add('e-clear-icon');\n this.sIcon.setAttribute('title', this.l10n.getConstant('ClearButton'));\n this.sIcon.style.cursor = 'pointer';\n }\n else {\n this.sIcon.classList.remove('e-clear-icon');\n this.sIcon.removeAttribute('title');\n this.sIcon.style.cursor = 'default';\n }\n }\n };\n Toolbar.prototype.search = function () {\n this.isSearched = true;\n this.parent.search(this.searchElement.value);\n };\n Toolbar.prototype.updateSearchBox = function () {\n if (this.searchElement) {\n this.searchElement.value = this.parent.searchSettings.key;\n }\n };\n Toolbar.prototype.wireEvent = function () {\n if (this.searchElement) {\n this.searchBoxObj = new SearchBox(this.searchElement, this.serviceLocator);\n EventHandler.add(this.searchElement, 'keyup', this.keyUpHandler, this);\n this.searchBoxObj.wireEvent();\n }\n EventHandler.add(this.element, 'focusin', this.onFocusIn, this);\n EventHandler.add(this.element, 'focusout', this.onFocusOut, this);\n };\n Toolbar.prototype.unWireEvent = function () {\n if (this.searchElement) {\n EventHandler.remove(this.searchElement, 'keyup', this.keyUpHandler);\n this.searchBoxObj.unWireEvent();\n }\n EventHandler.remove(this.element, 'focusin', this.onFocusIn);\n EventHandler.remove(this.element, 'focusout', this.onFocusOut);\n };\n Toolbar.prototype.onFocusIn = function (e) {\n var currentInfo = this.parent.focusModule.currentInfo;\n if (currentInfo && currentInfo.element) {\n removeClass([currentInfo.element, currentInfo.elementToFocus], ['e-focused', 'e-focus']);\n currentInfo.element.tabIndex = -1;\n }\n e.target.tabIndex = 0;\n };\n Toolbar.prototype.onFocusOut = function (e) {\n e.target.tabIndex = -1;\n };\n Toolbar.prototype.setFocusToolbarItem = function (element) {\n var elementToFocus = element.querySelector('.e-btn,.e-input,.e-toolbar-item-focus');\n if (!elementToFocus && this.parent.enableAdaptiveUI && !this.searchElement\n && element.classList.contains('e-search-wrapper')) {\n elementToFocus = element.querySelector('#' + this.gridID + '_searchbutton');\n }\n elementToFocus.focus();\n };\n Toolbar.prototype.getFocusableToolbarItems = function () {\n var getFocusToolbarElements = [].slice.call(this.element.querySelectorAll('.e-toolbar-item:not(.e-overlay):not(.e-hidden)'));\n var getFocusToolbarItems = [];\n for (var i = 0; i < getFocusToolbarElements.length; i++) {\n if (!isNullOrUndefined(getFocusToolbarElements[parseInt(i.toString(), 10)].querySelector('.e-btn,.e-input,.e-toolbar-item-focus'))) {\n getFocusToolbarItems.push(getFocusToolbarElements[parseInt(i.toString(), 10)]);\n }\n }\n return getFocusToolbarItems;\n };\n Toolbar.prototype.keyPressedHandler = function (e) {\n if (e.target && parentsUntil(e.target, 'e-toolbar-item')) {\n var targetParent = parentsUntil(e.target, 'e-toolbar-item');\n var focusableToolbarItems = this.getFocusableToolbarItems();\n if (e.action === 'tab' || e.action === 'shiftTab') {\n if ((e.action === 'tab' && targetParent === focusableToolbarItems[focusableToolbarItems.length - 1])\n || (e.action === 'shiftTab' && targetParent === focusableToolbarItems[0])) {\n return;\n }\n for (var i = 0; i < focusableToolbarItems.length; i++) {\n if (targetParent === focusableToolbarItems[parseInt(i.toString(), 10)]) {\n e.preventDefault();\n var index = e.action === 'tab' ? i + 1 : i - 1;\n this.setFocusToolbarItem(focusableToolbarItems[parseInt(index.toString(), 10)]);\n return;\n }\n }\n }\n if (e.action === 'enter') {\n if (this.parent.enableAdaptiveUI && !this.searchElement\n && e.target.id === this.gridID + '_searchbutton') {\n this.renderResponsiveSearch(true);\n }\n }\n }\n };\n Toolbar.prototype.reRenderToolbar = function () {\n if (this.element) {\n remove(this.element);\n }\n this.render();\n };\n Toolbar.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.evtHandlers = [{ event: events.setFullScreenDialog, handler: this.reRenderToolbar },\n { event: events.initialEnd, handler: this.render },\n { event: events.uiUpdate, handler: this.onPropertyChanged },\n { event: events.inBoundModelChanged, handler: this.updateSearchBox.bind(this) },\n { event: events.modelChanged, handler: this.refreshToolbarItems },\n { event: events.toolbarRefresh, handler: this.refreshToolbarItems },\n { event: events.inBoundModelChanged, handler: this.modelChanged },\n { event: events.dataBound, handler: this.refreshToolbarItems },\n { event: events.click, handler: this.removeResponsiveSearch },\n { event: events.rowModeChange, handler: this.reRenderToolbar },\n { event: events.destroy, handler: this.destroy },\n { event: events.keyPressed, handler: this.keyPressedHandler }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n this.rowSelectedFunction = this.rowSelected.bind(this);\n this.rowDeSelectedFunction = this.rowSelected.bind(this);\n this.parent.addEventListener(events.rowSelected, this.rowSelectedFunction);\n this.parent.addEventListener(events.rowDeselected, this.rowDeSelectedFunction);\n };\n Toolbar.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n this.parent.removeEventListener(events.rowSelected, this.rowSelectedFunction);\n this.parent.removeEventListener(events.rowDeselected, this.rowDeSelectedFunction);\n };\n Toolbar.prototype.removeResponsiveSearch = function (e) {\n var target = e.target;\n var isSearch = target.classList.contains('e-search-icon') || target.classList.contains('e-search-wrapper');\n if (this.parent.enableAdaptiveUI && !isSearch && this.searchElement\n && !parentsUntil(e.target, 'e-res-toolbar')) {\n this.renderResponsiveSearch(false);\n }\n };\n Toolbar.prototype.rowSelected = function () {\n if (this.parent.enableAdaptiveUI) {\n this.refreshResponsiveToolbarItems(ResponsiveToolbarAction.isInitial);\n this.toolbar.refreshOverflow();\n }\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n */\n Toolbar.prototype.getModuleName = function () {\n return 'toolbar';\n };\n return Toolbar;\n}());\nexport { Toolbar };\n","//! moment.js locale configuration\n//! locale : Gujarati [gu]\n//! author : Kaushik Thanki : https://github.com/Kaushik1987\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '૧',\n 2: '૨',\n 3: 'à«©',\n 4: '૪',\n 5: 'à««',\n 6: '૬',\n 7: 'à«',\n 8: 'à«®',\n 9: '૯',\n 0: '૦',\n },\n numberMap = {\n '૧': '1',\n '૨': '2',\n 'à«©': '3',\n '૪': '4',\n 'à««': '5',\n '૬': '6',\n 'à«': '7',\n 'à«®': '8',\n '૯': '9',\n '૦': '0',\n };\n\n var gu = moment.defineLocale('gu', {\n months: 'જાનà«àª¯à«àª†àª°à«€_ફેબà«àª°à«àª†àª°à«€_મારà«àªš_àªàªªà«àª°àª¿àª²_મે_જૂન_જà«àª²àª¾àªˆ_ઑગસà«àªŸ_સપà«àªŸà«‡àª®à«àª¬àª°_ઑકà«àªŸà«àª¬àª°_નવેમà«àª¬àª°_ડિસેમà«àª¬àª°'.split(\n '_'\n ),\n monthsShort:\n 'જાનà«àª¯à«._ફેબà«àª°à«._મારà«àªš_àªàªªà«àª°àª¿._મે_જૂન_જà«àª²àª¾._ઑગ._સપà«àªŸà«‡._ઑકà«àªŸà«._નવે._ડિસે.'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays: 'રવિવાર_સોમવાર_મંગળવાર_બà«àª§à«àªµàª¾àª°_ગà«àª°à«àªµàª¾àª°_શà«àª•à«àª°àªµàª¾àª°_શનિવાર'.split(\n '_'\n ),\n weekdaysShort: 'રવિ_સોમ_મંગળ_બà«àª§à«_ગà«àª°à«_શà«àª•à«àª°_શનિ'.split('_'),\n weekdaysMin: 'ર_સો_મં_બà«_ગà«_શà«_શ'.split('_'),\n longDateFormat: {\n LT: 'A h:mm વાગà«àª¯à«‡',\n LTS: 'A h:mm:ss વાગà«àª¯à«‡',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm વાગà«àª¯à«‡',\n LLLL: 'dddd, D MMMM YYYY, A h:mm વાગà«àª¯à«‡',\n },\n calendar: {\n sameDay: '[આજ] LT',\n nextDay: '[કાલે] LT',\n nextWeek: 'dddd, LT',\n lastDay: '[ગઇકાલે] LT',\n lastWeek: '[પાછલા] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s મા',\n past: '%s પહેલા',\n s: 'અમà«àª• પળો',\n ss: '%d સેકંડ',\n m: 'àªàª• મિનિટ',\n mm: '%d મિનિટ',\n h: 'àªàª• કલાક',\n hh: '%d કલાક',\n d: 'àªàª• દિવસ',\n dd: '%d દિવસ',\n M: 'àªàª• મહિનો',\n MM: '%d મહિનો',\n y: 'àªàª• વરà«àª·',\n yy: '%d વરà«àª·',\n },\n preparse: function (string) {\n return string.replace(/[૧૨૩૪૫૬à«à«®à«¯à«¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n // Gujarati notation for meridiems are quite fuzzy in practice. While there exists\n // a rigid notion of a 'Pahar' it is not used as rigidly in modern Gujarati.\n meridiemParse: /રાત|બપોર|સવાર|સાંજ/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'રાત') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'સવાર') {\n return hour;\n } else if (meridiem === 'બપોર') {\n return hour >= 10 ? hour : hour + 12;\n } else if (meridiem === 'સાંજ') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'રાત';\n } else if (hour < 10) {\n return 'સવાર';\n } else if (hour < 17) {\n return 'બપોર';\n } else if (hour < 20) {\n return 'સાંજ';\n } else {\n return 'રાત';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return gu;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { Component, Property, Event, EventHandler, L10n, compile, isNullOrUndefined, SanitizeHtmlHelper } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges, detach, append, Animation } from '@syncfusion/ej2-base';\nimport { addClass, removeClass, KeyboardEvents, setValue, getValue, ChildProperty } from '@syncfusion/ej2-base';\nimport { Collection, Complex, Browser, Ajax, getUniqueID, closest, remove } from '@syncfusion/ej2-base';\nimport { createSpinner, showSpinner, hideSpinner } from '@syncfusion/ej2-popups';\nimport { select, selectAll } from '@syncfusion/ej2-base';\nvar CONTROL_WRAPPER = 'e-upload e-control-wrapper';\nvar INPUT_WRAPPER = 'e-file-select';\nvar DROP_AREA = 'e-file-drop';\nvar DROP_WRAPPER = 'e-file-select-wrap';\nvar LIST_PARENT = 'e-upload-files';\nvar FILE = 'e-upload-file-list';\nvar STATUS = 'e-file-status';\nvar ACTION_BUTTONS = 'e-upload-actions';\nvar UPLOAD_BUTTONS = 'e-file-upload-btn e-css e-btn e-flat e-primary';\nvar CLEAR_BUTTONS = 'e-file-clear-btn e-css e-btn e-flat';\nvar FILE_NAME = 'e-file-name';\nvar FILE_TYPE = 'e-file-type';\nvar FILE_SIZE = 'e-file-size';\nvar REMOVE_ICON = 'e-file-remove-btn';\nvar DELETE_ICON = 'e-file-delete-btn';\nvar SPINNER_PANE = 'e-spinner-pane';\nvar ABORT_ICON = 'e-file-abort-btn';\nvar RETRY_ICON = 'e-file-reload-btn';\nvar DRAG_HOVER = 'e-upload-drag-hover';\nvar PROGRESS_WRAPPER = 'e-upload-progress-wrap';\nvar PROGRESSBAR = 'e-upload-progress-bar';\nvar PROGRESSBAR_TEXT = 'e-progress-bar-text';\nvar UPLOAD_INPROGRESS = 'e-upload-progress';\nvar UPLOAD_SUCCESS = 'e-upload-success';\nvar UPLOAD_FAILED = 'e-upload-fails';\nvar TEXT_CONTAINER = 'e-file-container';\nvar VALIDATION_FAILS = 'e-validation-fails';\nvar RTL = 'e-rtl';\nvar DISABLED = 'e-disabled';\nvar RTL_CONTAINER = 'e-rtl-container';\nvar ICON_FOCUSED = 'e-clear-icon-focus';\nvar PROGRESS_INNER_WRAPPER = 'e-progress-inner-wrap';\nvar PAUSE_UPLOAD = 'e-file-pause-btn';\nvar RESUME_UPLOAD = 'e-file-play-btn';\nvar RESTRICT_RETRY = 'e-restrict-retry';\nvar wrapperAttr = ['title', 'style', 'class'];\nvar FORM_UPLOAD = 'e-form-upload';\nvar HIDDEN_INPUT = 'e-hidden-file-input';\nvar INVALID_FILE = 'e-file-invalid';\nvar INFORMATION = 'e-file-information';\nvar FilesProp = /** @class */ (function (_super) {\n __extends(FilesProp, _super);\n function FilesProp() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('')\n ], FilesProp.prototype, \"name\", void 0);\n __decorate([\n Property(null)\n ], FilesProp.prototype, \"size\", void 0);\n __decorate([\n Property('')\n ], FilesProp.prototype, \"type\", void 0);\n return FilesProp;\n}(ChildProperty));\nexport { FilesProp };\nvar ButtonsProps = /** @class */ (function (_super) {\n __extends(ButtonsProps, _super);\n function ButtonsProps() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('Browse...')\n ], ButtonsProps.prototype, \"browse\", void 0);\n __decorate([\n Property('Upload')\n ], ButtonsProps.prototype, \"upload\", void 0);\n __decorate([\n Property('Clear')\n ], ButtonsProps.prototype, \"clear\", void 0);\n return ButtonsProps;\n}(ChildProperty));\nexport { ButtonsProps };\nvar AsyncSettings = /** @class */ (function (_super) {\n __extends(AsyncSettings, _super);\n function AsyncSettings() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n __decorate([\n Property('')\n ], AsyncSettings.prototype, \"saveUrl\", void 0);\n __decorate([\n Property('')\n ], AsyncSettings.prototype, \"removeUrl\", void 0);\n __decorate([\n Property(0)\n ], AsyncSettings.prototype, \"chunkSize\", void 0);\n __decorate([\n Property(3)\n ], AsyncSettings.prototype, \"retryCount\", void 0);\n __decorate([\n Property(500)\n ], AsyncSettings.prototype, \"retryAfterDelay\", void 0);\n return AsyncSettings;\n}(ChildProperty));\nexport { AsyncSettings };\n/**\n * The uploader component allows to upload images, documents, and other files from local to server.\n * ```html\n * <input type='file' name='images[]' id='upload'/>\n * ```\n * ```typescript\n * <script>\n * var uploadObj = new Uploader();\n * uploadObj.appendTo('#upload');\n * </script>\n * ```\n */\nvar Uploader = /** @class */ (function (_super) {\n __extends(Uploader, _super);\n /**\n * Triggers when change the Uploader value.\n *\n * @param {UploaderModel} options - Specifies the Uploader model.\n * @param {string | HTMLInputElement} element - Specifies the element to render as component.\n * @private\n */\n function Uploader(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.initialAttr = { accept: null, multiple: false, disabled: false };\n _this.uploadedFilesData = [];\n _this.base64String = [];\n _this.isForm = false;\n _this.allTypes = false;\n _this.pausedData = [];\n _this.uploadMetaData = [];\n _this.tabIndex = '0';\n _this.btnTabIndex = '0';\n _this.disableKeyboardNavigation = false;\n _this.count = -1;\n _this.actionCompleteCount = 0;\n _this.flag = true;\n _this.selectedFiles = [];\n _this.uploaderName = 'UploadFiles';\n _this.fileStreams = [];\n _this.newFileRef = 0;\n _this.isFirstFileOnSelection = false;\n _this.dragCounter = 0;\n _this.isAngular = false;\n /**\n * Get the file item(li) which are shown in file list.\n *\n * @private\n */\n _this.fileList = [];\n /**\n * Get the data of files which are shown in file list.\n *\n * @private\n */\n _this.filesData = [];\n _this.uploaderOptions = options;\n return _this;\n }\n /**\n * Calls internally if any of the property value is changed.\n *\n * @param {UploaderModel} newProp - Returns the dynamic property value of the component.\n * @param {UploaderModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n * @private\n */\n Uploader.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'allowedExtensions':\n this.setExtensions(this.allowedExtensions);\n this.clearAll();\n break;\n case 'enabled':\n this.setControlStatus();\n break;\n case 'multiple':\n this.setMultipleSelection();\n break;\n case 'enableRtl':\n this.setRTL();\n this.reRenderFileList();\n break;\n case 'buttons':\n this.buttons.browse = isNullOrUndefined(this.buttons.browse) ? '' : this.buttons.browse;\n this.buttons.clear = isNullOrUndefined(this.buttons.clear) ? '' : this.buttons.clear;\n this.buttons.upload = isNullOrUndefined(this.buttons.upload) ? '' : this.buttons.upload;\n this.renderButtonTemplates();\n break;\n case 'dropArea':\n this.unBindDropEvents();\n this.updateDropArea();\n break;\n case 'htmlAttributes':\n this.updateHTMLAttrToElement();\n this.updateHTMLAttrToWrapper();\n this.checkHTMLAttributes(true);\n break;\n case 'files':\n this.renderPreLoadFiles();\n break;\n case 'directoryUpload':\n this.updateDirectoryAttributes();\n break;\n case 'template':\n var ejInstance = getValue('ej2_instances', this.element);\n if (ejInstance[0].isReact) {\n this.reRenderFileList();\n }\n else {\n this.clearAll();\n }\n break;\n case 'minFileSize':\n case 'maxFileSize':\n case 'autoUpload':\n this.clearAll();\n break;\n case 'sequentialUpload':\n this.clearAll();\n break;\n case 'locale':\n this.l10n.setLocale(this.locale);\n this.setLocalizedTexts();\n this.preLocaleObj = getValue('currentLocale', this.l10n);\n break;\n case 'cssClass':\n this.setCSSClass(oldProp.cssClass);\n break;\n }\n }\n };\n Uploader.prototype.setLocalizedTexts = function () {\n if (isNullOrUndefined(this.template)) {\n if (typeof (this.buttons.browse) === 'string') {\n this.browseButton.innerText = (this.buttons.browse === 'Browse...') ?\n this.localizedTexts('Browse') : this.buttons.browse;\n this.browseButton.setAttribute('title', this.browseButton.innerText);\n if (this.uploadWrapper && !isNullOrUndefined(this.uploadWrapper.querySelector('.' + DROP_AREA))) {\n this.uploadWrapper.querySelector('.' + DROP_AREA).innerHTML = this.localizedTexts('dropFilesHint');\n }\n }\n this.updateFileList();\n }\n };\n Uploader.prototype.getKeyValue = function (val) {\n var keyValue;\n for (var _i = 0, _a = Object.keys(this.preLocaleObj); _i < _a.length; _i++) {\n var key = _a[_i];\n if (this.preLocaleObj[\"\" + key] === val) {\n keyValue = key;\n }\n }\n return keyValue;\n };\n Uploader.prototype.updateFileList = function () {\n var element;\n /* istanbul ignore next */\n if (this.fileList.length > 0 && !isNullOrUndefined(this.uploadWrapper.querySelector('.' + LIST_PARENT))) {\n for (var i = 0; i < this.fileList.length; i++) {\n element = this.fileList[i].querySelector('.e-file-status');\n element.innerHTML = this.localizedTexts(this.getKeyValue(this.filesData[i].status));\n this.filesData[i].status = this.localizedTexts(this.getKeyValue(this.filesData[i].status));\n if (this.fileList[i].classList.contains(UPLOAD_SUCCESS)) {\n this.fileList[i].querySelector('.e-icons').setAttribute('title', this.localizedTexts('delete'));\n }\n if (this.fileList[i].querySelector('.e-file-play-btn')) {\n this.fileList[i].querySelector('.e-icons').setAttribute('title', this.localizedTexts('resume'));\n }\n if (this.fileList[i].querySelector('.e-file-remove-btn')) {\n this.fileList[i].querySelector('.e-icons').setAttribute('title', this.localizedTexts('remove'));\n }\n if (this.fileList[i].querySelector('.e-file-reload-btn')) {\n this.fileList[i].querySelector('.e-icons').setAttribute('title', this.localizedTexts('retry'));\n }\n if (!this.autoUpload) {\n this.uploadButton.innerText = (this.buttons.upload === 'Upload') ?\n this.localizedTexts('Upload') : this.buttons.upload;\n this.uploadButton.setAttribute('title', this.localizedTexts('Upload'));\n this.clearButton.innerText = (this.buttons.clear === 'Clear') ?\n this.localizedTexts('Clear') : this.buttons.clear;\n this.clearButton.setAttribute('title', this.localizedTexts('Clear'));\n }\n }\n }\n };\n Uploader.prototype.reRenderFileList = function () {\n if (this.listParent) {\n detach(this.listParent);\n this.listParent = null;\n this.fileList = [];\n this.internalCreateFileList(this.filesData);\n if (this.actionButtons) {\n this.removeActionButtons();\n this.renderActionButtons();\n this.checkActionButtonStatus();\n }\n }\n };\n Uploader.prototype.preRender = function () {\n this.localeText = { Browse: 'Browse...', Clear: 'Clear', Upload: 'Upload', invalidFileName: 'File Name is not allowed',\n dropFilesHint: 'Or drop files here', invalidMaxFileSize: 'File size is too large',\n invalidMinFileSize: 'File size is too small', invalidFileType: 'File type is not allowed',\n uploadFailedMessage: 'File failed to upload', uploadSuccessMessage: 'File uploaded successfully',\n removedSuccessMessage: 'File removed successfully', removedFailedMessage: 'Unable to remove file', inProgress: 'Uploading',\n readyToUploadMessage: 'Ready to upload', abort: 'Abort', remove: 'Remove', cancel: 'Cancel', delete: 'Delete file',\n pauseUpload: 'File upload paused', pause: 'Pause', resume: 'Resume', retry: 'Retry',\n fileUploadCancel: 'File upload canceled', invalidFileSelection: 'Invalid files selected', totalFiles: 'Total files',\n size: 'Size'\n };\n this.l10n = new L10n('uploader', this.localeText, this.locale);\n this.preLocaleObj = getValue('currentLocale', this.l10n);\n this.formRendered();\n this.updateHTMLAttrToElement();\n this.checkHTMLAttributes(false);\n var ejInstance = getValue('ej2_instances', this.element);\n /* istanbul ignore next */\n if (this.element.tagName === 'EJS-UPLOADER') {\n var inputElement = this.createElement('input', { attrs: { type: 'file' } });\n var index = 0;\n for (index; index < this.element.attributes.length; index++) {\n if (this.element.attributes[index].nodeName !== 'id') {\n inputElement.setAttribute(this.element.attributes[index].nodeName, this.element.attributes[index].nodeValue);\n }\n else if (this.element.attributes[index].nodeName === 'id') {\n inputElement.setAttribute(this.element.attributes[index].nodeName, getUniqueID('uploader'));\n }\n inputElement.innerHTML = this.element.innerHTML;\n }\n if (!inputElement.hasAttribute('name')) {\n inputElement.setAttribute('name', 'UploadFiles');\n }\n this.element.appendChild(inputElement);\n this.element = inputElement;\n setValue('ej2_instances', ejInstance, this.element);\n }\n /* istanbul ignore next */\n if (ejInstance[0].isPureReactComponent) {\n if (!isNullOrUndefined(ejInstance[0].props.name)) {\n this.element.setAttribute('name', ejInstance[0].props.name);\n }\n else if (!isNullOrUndefined(ejInstance[0].props.id) && isNullOrUndefined(ejInstance[0].props.name)) {\n this.element.setAttribute('name', ejInstance[0].props.id);\n }\n else {\n this.element.setAttribute('name', 'UploadFiles');\n }\n }\n if (isNullOrUndefined(this.element.getAttribute('name'))) {\n this.element.setAttribute('name', this.element.getAttribute('id'));\n }\n if (!this.element.hasAttribute('type')) {\n this.element.setAttribute('type', 'file');\n }\n this.updateDirectoryAttributes();\n this.keyConfigs = {\n enter: 'enter'\n };\n if (this.element.hasAttribute('tabindex')) {\n this.tabIndex = this.element.getAttribute('tabindex');\n }\n this.browserName = Browser.info.name;\n this.uploaderName = this.element.getAttribute('name');\n };\n Uploader.prototype.formRendered = function () {\n var parentEle = closest(this.element, 'form');\n if (!isNullOrUndefined(parentEle)) {\n for (; parentEle && parentEle !== document.documentElement; parentEle = parentEle.parentElement) {\n if (parentEle.tagName === 'FORM') {\n this.isForm = true;\n this.formElement = parentEle;\n parentEle.setAttribute('enctype', 'multipart/form-data');\n parentEle.setAttribute('encoding', 'multipart/form-data');\n }\n }\n }\n };\n Uploader.prototype.getPersistData = function () {\n return this.addOnPersist(['filesData']);\n };\n /**\n * Return the module name of the component.\n *\n * @returns {string} Returns the component name.\n */\n Uploader.prototype.getModuleName = function () {\n return 'uploader';\n };\n Uploader.prototype.updateDirectoryAttributes = function () {\n if (this.directoryUpload) {\n this.element.setAttribute('directory', 'true');\n this.element.setAttribute('webkitdirectory', 'true');\n }\n else {\n this.element.removeAttribute('directory');\n this.element.removeAttribute('webkitdirectory');\n }\n };\n /**\n * To Initialize the control rendering\n *\n * @private\n * @returns {void}\n */\n Uploader.prototype.render = function () {\n this.renderBrowseButton();\n this.initializeUpload();\n this.updateHTMLAttrToWrapper();\n this.wireEvents();\n this.setMultipleSelection();\n this.setExtensions(this.allowedExtensions);\n this.setRTL();\n this.renderPreLoadFiles();\n this.setControlStatus();\n this.setCSSClass();\n };\n Uploader.prototype.renderBrowseButton = function () {\n this.browseButton = this.createElement('button', { className: 'e-css e-btn', attrs: { 'type': 'button' } });\n this.browseButton.setAttribute('tabindex', this.tabIndex);\n if (typeof (this.buttons.browse) === 'string') {\n this.browseButton.textContent = (this.buttons.browse === 'Browse...') ?\n this.localizedTexts('Browse') : this.buttons.browse;\n this.browseButton.setAttribute('title', this.browseButton.innerText);\n }\n else {\n this.browseButton.appendChild(this.buttons.browse);\n }\n this.element.setAttribute('aria-label', 'Uploader');\n };\n Uploader.prototype.renderActionButtons = function () {\n this.element.setAttribute('tabindex', '-1');\n this.actionButtons = this.createElement('div', { className: ACTION_BUTTONS });\n this.uploadButton = this.createElement('button', { className: UPLOAD_BUTTONS,\n attrs: { 'type': 'button', 'tabindex': this.btnTabIndex } });\n this.clearButton = this.createElement('button', { className: CLEAR_BUTTONS,\n attrs: { 'type': 'button', 'tabindex': this.btnTabIndex } });\n this.actionButtons.appendChild(this.clearButton);\n this.actionButtons.appendChild(this.uploadButton);\n this.renderButtonTemplates();\n this.uploadWrapper.appendChild(this.actionButtons);\n this.browseButton.blur();\n if (!this.isPreloadFiles) {\n this.uploadButton.focus();\n }\n this.wireActionButtonEvents();\n };\n /* istanbul ignore next */\n Uploader.prototype.serverActionButtonsEventBind = function (element) {\n if (element && !this.isForm) {\n this.browseButton.blur();\n this.actionButtons = element;\n this.uploadButton = this.actionButtons.querySelector('.e-file-upload-btn');\n this.clearButton = this.actionButtons.querySelector('.e-file-clear-btn');\n this.uploadButton.focus();\n this.unwireActionButtonEvents();\n this.wireActionButtonEvents();\n this.checkActionButtonStatus();\n }\n };\n Uploader.prototype.wireActionButtonEvents = function () {\n EventHandler.add(this.uploadButton, 'click', this.uploadButtonClick, this);\n EventHandler.add(this.clearButton, 'click', this.clearButtonClick, this);\n };\n Uploader.prototype.unwireActionButtonEvents = function () {\n EventHandler.remove(this.uploadButton, 'click', this.uploadButtonClick);\n EventHandler.remove(this.clearButton, 'click', this.clearButtonClick);\n };\n Uploader.prototype.removeActionButtons = function () {\n if (this.actionButtons) {\n this.unwireActionButtonEvents();\n detach(this.actionButtons);\n this.actionButtons = null;\n }\n };\n Uploader.prototype.renderButtonTemplates = function () {\n if (typeof (this.buttons.browse) === 'string') {\n this.browseButton.textContent = (this.buttons.browse === 'Browse...') ?\n this.localizedTexts('Browse') : this.buttons.browse;\n this.browseButton.setAttribute('title', this.browseButton.textContent);\n }\n else {\n this.browseButton.innerHTML = '';\n this.browseButton.appendChild(this.buttons.browse);\n }\n if (this.uploadButton) {\n var uploadText = isNullOrUndefined(this.buttons.upload) ? 'Upload' : this.buttons.upload;\n this.buttons.upload = uploadText;\n if (typeof (this.buttons.upload) === 'string') {\n this.uploadButton.textContent = (this.buttons.upload === 'Upload') ?\n this.localizedTexts('Upload') : this.buttons.upload;\n this.uploadButton.setAttribute('title', this.uploadButton.textContent);\n }\n else {\n this.uploadButton.innerHTML = '';\n this.uploadButton.appendChild(this.buttons.upload);\n }\n }\n if (this.clearButton) {\n var clearText = isNullOrUndefined(this.buttons.clear) ? 'Clear' : this.buttons.clear;\n this.buttons.clear = clearText;\n if (typeof (this.buttons.clear) === 'string') {\n this.clearButton.textContent = (this.buttons.clear === 'Clear') ?\n this.localizedTexts('Clear') : this.buttons.clear;\n this.clearButton.setAttribute('title', this.clearButton.textContent);\n }\n else {\n this.clearButton.innerHTML = '';\n this.clearButton.appendChild(this.buttons.clear);\n }\n }\n };\n Uploader.prototype.initializeUpload = function () {\n this.element.setAttribute('tabindex', '-1');\n var inputWrapper = this.createElement('span', { className: INPUT_WRAPPER });\n this.element.parentElement.insertBefore(inputWrapper, this.element);\n this.dropAreaWrapper = this.createElement('div', { className: DROP_WRAPPER });\n this.element.parentElement.insertBefore(this.dropAreaWrapper, this.element);\n inputWrapper.appendChild(this.element);\n this.dropAreaWrapper.appendChild(this.browseButton);\n this.dropAreaWrapper.appendChild(inputWrapper);\n this.uploadWrapper = this.createElement('div', { className: CONTROL_WRAPPER });\n this.dropAreaWrapper.parentElement.insertBefore(this.uploadWrapper, this.dropAreaWrapper);\n this.uploadWrapper.appendChild(this.dropAreaWrapper);\n this.setDropArea();\n };\n Uploader.prototype.renderPreLoadFiles = function () {\n if (this.files.length) {\n if (this.enablePersistence && this.filesData.length) {\n this.internalCreateFileList(this.filesData);\n return;\n }\n if (isNullOrUndefined(this.files[0].size)) {\n return;\n }\n this.isPreloadFiles = true;\n var files = [].slice.call(this.files);\n var filesData = [];\n if (!this.multiple) {\n this.clearData();\n files = [files[0]];\n }\n for (var _i = 0, files_1 = files; _i < files_1.length; _i++) {\n var data = files_1[_i];\n var fileData = {\n name: data.name + '.' + data.type.split('.')[data.type.split('.').length - 1],\n rawFile: '',\n size: data.size,\n status: this.localizedTexts('uploadSuccessMessage'),\n type: data.type,\n validationMessages: { minSize: '', maxSize: '' },\n statusCode: '2'\n };\n filesData.push(fileData);\n this.filesData.push(fileData);\n }\n this.internalCreateFileList(filesData);\n if (!this.autoUpload && this.listParent && !this.actionButtons && (!this.isForm || this.allowUpload()) && this.showFileList) {\n this.renderActionButtons();\n }\n this.checkActionButtonStatus();\n if (this.sequentialUpload) {\n this.count = this.filesData.length - 1;\n }\n this.isPreloadFiles = false;\n }\n };\n Uploader.prototype.checkActionButtonStatus = function () {\n if (this.actionButtons) {\n var length_1 = this.uploadWrapper.querySelectorAll('.' + VALIDATION_FAILS).length +\n this.uploadWrapper.querySelectorAll('.e-upload-fails:not(.e-upload-progress)').length +\n this.uploadWrapper.querySelectorAll('span.' + UPLOAD_SUCCESS).length +\n this.uploadWrapper.querySelectorAll('span.' + UPLOAD_INPROGRESS).length;\n if (length_1 > 0 && length_1 === this.uploadWrapper.querySelectorAll('li').length) {\n this.uploadButton.setAttribute('disabled', 'disabled');\n }\n else {\n this.uploadButton.removeAttribute('disabled');\n }\n }\n };\n Uploader.prototype.setDropArea = function () {\n var dropTextArea = this.dropAreaWrapper.querySelector('.e-file-drop');\n if (this.dropArea) {\n this.dropZoneElement = (typeof (this.dropArea) !== 'string') ? this.dropArea :\n select(this.dropArea, document);\n var element = this.element;\n var enableDropText = false;\n while (element.parentNode) {\n element = element.parentNode;\n if (element === this.dropZoneElement) {\n enableDropText = true;\n if (!dropTextArea) {\n this.createDropTextHint();\n }\n else {\n dropTextArea.innerHTML = this.localizedTexts('dropFilesHint');\n }\n }\n }\n if (!enableDropText && dropTextArea) {\n remove(dropTextArea);\n }\n }\n else if (!isNullOrUndefined(this.uploaderOptions) && this.uploaderOptions.dropArea === undefined) {\n this.createDropTextHint();\n this.dropZoneElement = this.uploadWrapper;\n this.setProperties({ dropArea: this.uploadWrapper }, true);\n }\n this.bindDropEvents();\n };\n Uploader.prototype.updateDropArea = function () {\n if (this.dropArea) {\n this.setDropArea();\n }\n else {\n this.dropZoneElement = null;\n var dropTextArea = this.dropAreaWrapper.querySelector('.e-file-drop');\n if (dropTextArea) {\n remove(dropTextArea);\n }\n }\n };\n Uploader.prototype.createDropTextHint = function () {\n var fileDropArea = this.createElement('span', { className: DROP_AREA });\n fileDropArea.innerHTML = this.localizedTexts('dropFilesHint');\n this.dropAreaWrapper.appendChild(fileDropArea);\n };\n Uploader.prototype.updateHTMLAttrToElement = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var pro = _a[_i];\n if (wrapperAttr.indexOf(pro) < 0) {\n this.element.setAttribute(pro, this.htmlAttributes[\"\" + pro]);\n }\n }\n }\n };\n Uploader.prototype.updateHTMLAttrToWrapper = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var pro = _a[_i];\n if (wrapperAttr.indexOf(pro) > -1) {\n if (pro === 'class') {\n var updatedClassValues = (this.htmlAttributes[\"\" + pro].replace(/\\s+/g, ' ')).trim();\n if (updatedClassValues !== '') {\n addClass([this.uploadWrapper], updatedClassValues.split(' '));\n }\n }\n else if (pro === 'style') {\n var uploadStyle = this.uploadWrapper.getAttribute(pro);\n uploadStyle = !isNullOrUndefined(uploadStyle) ? (uploadStyle + this.htmlAttributes[\"\" + pro]) :\n this.htmlAttributes[\"\" + pro];\n this.uploadWrapper.setAttribute(pro, uploadStyle);\n }\n else {\n this.uploadWrapper.setAttribute(pro, this.htmlAttributes[\"\" + pro]);\n }\n }\n }\n }\n };\n Uploader.prototype.setMultipleSelection = function () {\n if (this.multiple && !this.element.hasAttribute('multiple')) {\n var newAttr = document.createAttribute('multiple');\n newAttr.value = 'multiple';\n this.element.setAttributeNode(newAttr);\n }\n else if (!this.multiple) {\n this.element.removeAttribute('multiple');\n }\n };\n Uploader.prototype.checkAutoUpload = function (fileData) {\n if (this.autoUpload) {\n if (this.sequentialUpload) {\n /* istanbul ignore next */\n this.sequenceUpload(fileData);\n }\n else {\n this.upload(fileData);\n }\n this.removeActionButtons();\n }\n else if (!this.actionButtons) {\n this.renderActionButtons();\n }\n this.checkActionButtonStatus();\n };\n Uploader.prototype.sequenceUpload = function (fileData) {\n if (this.filesData.length - fileData.length === 0 ||\n this.filesData[(this.filesData.length - fileData.length - 1)].statusCode !== '1') {\n if (this.multiple || this.count < 0) {\n ++this.count;\n }\n var isFileListCreated = this.showFileList ? false : true;\n if (typeof this.filesData[this.count] === 'object') {\n this.isFirstFileOnSelection = false;\n this.upload(this.filesData[this.count], isFileListCreated);\n if (this.filesData[this.count].statusCode === '0') {\n this.sequenceUpload(fileData);\n }\n }\n else {\n --this.count;\n }\n }\n };\n Uploader.prototype.setCSSClass = function (oldCSSClass) {\n var updatedOldCssClass = oldCSSClass;\n if (!isNullOrUndefined(oldCSSClass)) {\n updatedOldCssClass = (oldCSSClass.replace(/\\s+/g, ' ')).trim();\n }\n if (!isNullOrUndefined(oldCSSClass) && updatedOldCssClass !== '') {\n removeClass([this.uploadWrapper], updatedOldCssClass.split(' '));\n }\n var updatedCssClassValue = this.cssClass;\n if (!isNullOrUndefined(this.cssClass) && this.cssClass !== '') {\n updatedCssClassValue = (this.cssClass.replace(/\\s+/g, ' ')).trim();\n }\n if (!isNullOrUndefined(this.cssClass) && updatedCssClassValue !== '') {\n addClass([this.uploadWrapper], updatedCssClassValue.split(updatedCssClassValue.indexOf(',') > -1 ? ',' : ' '));\n }\n };\n Uploader.prototype.wireEvents = function () {\n EventHandler.add(this.browseButton, 'click', this.browseButtonClick, this);\n EventHandler.add(this.element, 'change', this.onSelectFiles, this);\n EventHandler.add(document, 'click', this.removeFocus, this);\n this.keyboardModule = new KeyboardEvents(this.uploadWrapper, {\n keyAction: this.keyActionHandler.bind(this),\n keyConfigs: this.keyConfigs,\n eventName: 'keydown'\n });\n if (this.isForm) {\n EventHandler.add(this.formElement, 'reset', this.resetForm, this);\n }\n };\n Uploader.prototype.unWireEvents = function () {\n EventHandler.remove(this.browseButton, 'click', this.browseButtonClick);\n EventHandler.remove(this.element, 'change', this.onSelectFiles);\n EventHandler.remove(document, 'click', this.removeFocus);\n if (this.isForm) {\n EventHandler.remove(this.formElement, 'reset', this.resetForm);\n }\n if (this.keyboardModule) {\n this.keyboardModule.destroy();\n }\n };\n Uploader.prototype.resetForm = function () {\n this.clearAll();\n };\n Uploader.prototype.keyActionHandler = function (e) {\n var targetElement = e.target;\n switch (e.action) {\n case 'enter':\n if (e.target === this.clearButton) {\n this.clearButtonClick();\n }\n else if (e.target === this.uploadButton) {\n this.uploadButtonClick();\n }\n else if (e.target === this.browseButton) {\n this.browseButtonClick();\n }\n else if (targetElement.classList.contains(PAUSE_UPLOAD)) {\n var metaData = this.getCurrentMetaData(null, e);\n metaData.file.statusCode = '4';\n metaData.file.status = this.localizedTexts('pauseUpload');\n this.abortUpload(metaData, false);\n }\n else if (targetElement.classList.contains(RESUME_UPLOAD)) {\n this.resumeUpload(this.getCurrentMetaData(null, e), e);\n }\n else if (targetElement.classList.contains(RETRY_ICON)) {\n var metaData = this.getCurrentMetaData(null, e);\n if (!isNullOrUndefined(metaData)) {\n metaData.file.statusCode = '1';\n metaData.file.status = this.localizedTexts('readyToUploadMessage');\n this.chunkUpload(metaData.file);\n }\n else {\n var target = e.target.parentElement;\n var fileData = this.filesData[this.fileList.indexOf(target)];\n this.retry(fileData);\n }\n }\n else {\n this.removeFiles(e);\n if (!targetElement.classList.contains(ABORT_ICON)) {\n this.browseButton.focus();\n }\n }\n e.preventDefault();\n e.stopPropagation();\n break;\n }\n };\n Uploader.prototype.getCurrentMetaData = function (fileInfo, e) {\n var fileData;\n var targetMetaData;\n if (isNullOrUndefined(fileInfo)) {\n var target = e.target.parentElement;\n fileData = this.filesData[this.fileList.indexOf(target)];\n }\n else {\n fileData = fileInfo;\n }\n for (var i = 0; i < this.uploadMetaData.length; i++) {\n if (this.uploadMetaData[i].file.name === fileData.name) {\n targetMetaData = this.uploadMetaData[i];\n }\n }\n return targetMetaData;\n };\n Uploader.prototype.removeFocus = function () {\n if (this.uploadWrapper && this.listParent && this.listParent.querySelector('.' + ICON_FOCUSED)) {\n document.activeElement.blur();\n this.listParent.querySelector('.' + ICON_FOCUSED).classList.remove(ICON_FOCUSED);\n }\n };\n Uploader.prototype.browseButtonClick = function () {\n this.element.click();\n };\n Uploader.prototype.uploadButtonClick = function () {\n if (this.sequentialUpload) {\n this.sequenceUpload(this.filesData);\n }\n else {\n this.upload(this.filesData);\n }\n };\n Uploader.prototype.clearButtonClick = function () {\n this.clearAll();\n /* istanbul ignore next */\n if (this.sequentialUpload) {\n this.count = -1;\n }\n this.actionCompleteCount = 0;\n };\n Uploader.prototype.bindDropEvents = function () {\n if (this.dropZoneElement) {\n EventHandler.add(this.dropZoneElement, 'drop', this.dropElement, this);\n EventHandler.add(this.dropZoneElement, 'dragover', this.dragHover, this);\n EventHandler.add(this.dropZoneElement, 'dragleave', this.onDragLeave, this);\n EventHandler.add(this.dropZoneElement, 'paste', this.onPasteFile, this);\n EventHandler.add(this.dropZoneElement, 'dragenter', this.onDragEnter, this);\n }\n };\n Uploader.prototype.unBindDropEvents = function () {\n if (this.dropZoneElement) {\n EventHandler.remove(this.dropZoneElement, 'drop', this.dropElement);\n EventHandler.remove(this.dropZoneElement, 'dragover', this.dragHover);\n EventHandler.remove(this.dropZoneElement, 'dragleave', this.onDragLeave);\n EventHandler.remove(this.dropZoneElement, 'dragenter', this.onDragEnter);\n }\n };\n Uploader.prototype.onDragEnter = function (e) {\n if (!this.enabled) {\n return;\n }\n this.dropZoneElement.classList.add(DRAG_HOVER);\n this.dragCounter = this.dragCounter + 1;\n e.preventDefault();\n e.stopPropagation();\n };\n Uploader.prototype.onDragLeave = function () {\n if (!this.enabled) {\n return;\n }\n this.dragCounter = this.dragCounter - 1;\n if (!this.dragCounter) {\n this.dropZoneElement.classList.remove(DRAG_HOVER);\n }\n };\n Uploader.prototype.dragHover = function (e) {\n if (!this.enabled) {\n return;\n }\n if (this.dropEffect !== 'Default') {\n e.dataTransfer.dropEffect = this.dropEffect.toLowerCase();\n }\n e.preventDefault();\n e.stopPropagation();\n };\n /* istanbul ignore next */\n Uploader.prototype.dropElement = function (e) {\n this.dragCounter = 0;\n this.dropZoneElement.classList.remove(DRAG_HOVER);\n this.onSelectFiles(e);\n e.preventDefault();\n e.stopPropagation();\n };\n /* istanbul ignore next */\n Uploader.prototype.onPasteFile = function (event) {\n var item = event.clipboardData.items;\n if (event.type === 'paste' && this.browserName !== 'msie' && this.browserName !== 'edge' && this.browserName !== 'safari') {\n this.element.files = event.clipboardData.files;\n }\n if (item.length !== 1 && !this.multiple) {\n return;\n }\n for (var file = 0; file < item.length; file++) {\n var pasteFile = [].slice.call(item)[file];\n if ((pasteFile.kind === 'file') || pasteFile.type.match('^image/')) {\n this.renderSelectedFiles(event, [pasteFile.getAsFile()], false, true);\n }\n }\n };\n Uploader.prototype.getSelectedFiles = function (index) {\n var data = [];\n var liElement = this.fileList[index];\n var allFiles = this.getFilesData();\n var nameElements = +liElement.getAttribute('data-files-count');\n var startIndex = 0;\n for (var i = 0; i < index; i++) {\n startIndex += (+this.fileList[i].getAttribute('data-files-count'));\n }\n for (var j = startIndex; j < (startIndex + nameElements); j++) {\n data.push(allFiles[j]);\n }\n return data;\n };\n Uploader.prototype.removeFiles = function (args) {\n if (!this.enabled) {\n return;\n }\n var selectedElement = args.target.parentElement;\n var index = this.fileList.indexOf(selectedElement);\n var liElement = this.fileList[index];\n var formUpload = this.isFormUpload();\n var fileData = formUpload ? this.getSelectedFiles(index) : this.getFilesInArray(this.filesData[index]);\n if (isNullOrUndefined(fileData)) {\n return;\n }\n if (args.target.classList.contains(ABORT_ICON) && !formUpload) {\n fileData[0].statusCode = '5';\n if (!isNullOrUndefined(liElement)) {\n var spinnerTarget = liElement.querySelector('.' + ABORT_ICON);\n createSpinner({ target: spinnerTarget, width: '20px' });\n showSpinner(spinnerTarget);\n }\n if (this.sequentialUpload) {\n /* istanbul ignore next */\n this.uploadSequential();\n }\n if (!(liElement.classList.contains(RESTRICT_RETRY))) {\n this.checkActionComplete(true);\n }\n }\n else if (!closest(args.target, '.' + SPINNER_PANE)) {\n this.remove(fileData, false, false, true, args);\n }\n this.checkActionButtonStatus();\n };\n Uploader.prototype.removeFilesData = function (file, customTemplate) {\n var index;\n if (customTemplate) {\n if (!this.showFileList) {\n index = this.filesData.indexOf(file);\n this.filesData.splice(index, 1);\n }\n return;\n }\n var selectedElement = this.getLiElement(file);\n if (isNullOrUndefined(selectedElement)) {\n return;\n }\n this.element.value = '';\n detach(selectedElement);\n index = this.fileList.indexOf(selectedElement);\n this.fileList.splice(index, 1);\n this.filesData.splice(index, 1);\n if (this.fileList.length === 0 && !isNullOrUndefined(this.listParent)) {\n detach(this.listParent);\n this.listParent = null;\n this.removeActionButtons();\n }\n if (this.sequentialUpload) {\n /* istanbul ignore next */\n if (index <= this.count) {\n --this.count;\n }\n }\n };\n Uploader.prototype.removeUploadedFile = function (file, eventArgs, removeDirectly, custom) {\n var _this = this;\n var selectedFiles = file;\n var ajax = new Ajax(this.asyncSettings.removeUrl, 'POST', true, null);\n ajax.emitError = false;\n var formData = new FormData();\n ajax.beforeSend = function (e) {\n eventArgs.currentRequest = ajax.httpRequest;\n if (!removeDirectly) {\n _this.trigger('removing', eventArgs, function (eventArgs) {\n if (eventArgs.cancel) {\n e.cancel = true;\n }\n else {\n _this.removingEventCallback(eventArgs, formData, selectedFiles, file);\n }\n });\n }\n else {\n _this.removingEventCallback(eventArgs, formData, selectedFiles, file);\n }\n };\n ajax.onLoad = function (e) {\n _this.removeCompleted(e, selectedFiles, custom);\n return {};\n };\n /* istanbul ignore next */\n ajax.onError = function (e) {\n _this.removeFailed(e, selectedFiles, custom);\n return {};\n };\n ajax.send(formData);\n };\n Uploader.prototype.removingEventCallback = function (eventArgs, formData, selectedFiles, file) {\n /* istanbul ignore next */\n var name = this.element.getAttribute('name');\n var liElement = this.getLiElement(file);\n if (!isNullOrUndefined(liElement) && (!isNullOrUndefined(liElement.querySelector('.' + DELETE_ICON)) ||\n !isNullOrUndefined(liElement.querySelector('.' + REMOVE_ICON)))) {\n var spinnerTarget = liElement.querySelector('.' + DELETE_ICON) ?\n liElement.querySelector('.' + DELETE_ICON) :\n liElement.querySelector('.' + REMOVE_ICON);\n createSpinner({ target: spinnerTarget, width: '20px' });\n showSpinner(spinnerTarget);\n }\n if (eventArgs.postRawFile && !isNullOrUndefined(selectedFiles.rawFile) && selectedFiles.rawFile !== '') {\n formData.append(name, selectedFiles.rawFile, selectedFiles.name);\n }\n else {\n formData.append(name, selectedFiles.name);\n }\n this.updateFormData(formData, eventArgs.customFormData);\n };\n /* istanbul ignore next */\n Uploader.prototype.updateFormData = function (formData, customData) {\n if (customData.length > 0 && customData[0]) {\n var _loop_1 = function (i) {\n var data = customData[i];\n // eslint-disable-next-line @typescript-eslint/tslint/config\n var value = Object.keys(data).map(function (e) {\n return data[\"\" + e];\n });\n formData.append(Object.keys(data)[0], value);\n };\n for (var i = 0; i < customData.length; i++) {\n _loop_1(i);\n }\n }\n };\n /* istanbul ignore next */\n Uploader.prototype.updateCustomheader = function (request, currentRequest) {\n if (currentRequest.length > 0 && currentRequest[0]) {\n var _loop_2 = function (i) {\n var data = currentRequest[i];\n // eslint-disable-next-line @typescript-eslint/tslint/config\n var value = Object.keys(data).map(function (e) {\n return data[\"\" + e];\n });\n request.setRequestHeader(Object.keys(data)[0], value);\n };\n for (var i = 0; i < currentRequest.length; i++) {\n _loop_2(i);\n }\n }\n };\n Uploader.prototype.removeCompleted = function (e, files, customTemplate) {\n var response = e && e.currentTarget ? this.getResponse(e) : null;\n var status = e.target;\n if (status.readyState === 4 && status.status >= 200 && status.status <= 299) {\n var args = {\n e: e, response: response, operation: 'remove', file: this.updateStatus(files, this.localizedTexts('removedSuccessMessage'), '2')\n };\n this.trigger('success', args);\n this.removeFilesData(files, customTemplate);\n var index = this.uploadedFilesData.indexOf(files);\n this.uploadedFilesData.splice(index, 1);\n this.trigger('change', { files: this.uploadedFilesData });\n }\n else {\n this.removeFailed(e, files, customTemplate);\n }\n };\n Uploader.prototype.removeFailed = function (e, files, customTemplate) {\n var response = e && e.currentTarget ? this.getResponse(e) : null;\n var args = {\n e: e, response: response, operation: 'remove', file: this.updateStatus(files, this.localizedTexts('removedFailedMessage'), '0')\n };\n if (!customTemplate) {\n var index = this.filesData.indexOf(files);\n var rootElement = this.fileList[index];\n if (rootElement) {\n rootElement.classList.remove(UPLOAD_SUCCESS);\n rootElement.classList.add(UPLOAD_FAILED);\n var statusElement = rootElement.querySelector('.' + STATUS);\n if (statusElement) {\n statusElement.classList.remove(UPLOAD_SUCCESS);\n statusElement.classList.add(UPLOAD_FAILED);\n }\n }\n this.checkActionButtonStatus();\n }\n this.trigger('failure', args);\n var liElement = this.getLiElement(files);\n /* istanbul ignore next */\n if (!isNullOrUndefined(liElement) && !isNullOrUndefined(liElement.querySelector('.' + DELETE_ICON))) {\n var spinnerTarget = liElement.querySelector('.' + DELETE_ICON);\n hideSpinner(spinnerTarget);\n detach(liElement.querySelector('.e-spinner-pane'));\n }\n };\n /* istanbul ignore next */\n Uploader.prototype.getFilesFromFolder = function (event) {\n this.filesEntries = [];\n var items = this.multiple ?\n event.dataTransfer.items : [event.dataTransfer.items[0]];\n var validDirectoryUpload = this.checkDirectoryUpload(items);\n if (!validDirectoryUpload) {\n return;\n }\n var _loop_3 = function (i) {\n var item = items[i].webkitGetAsEntry();\n if (item.isFile) {\n var files_2 = [];\n (item).file(function (fileObj) {\n var path = item.fullPath;\n files_2.push({ 'path': path, 'file': fileObj });\n });\n this_1.renderSelectedFiles(event, files_2, true);\n }\n else if (item.isDirectory) {\n this_1.traverseFileTree(item, event);\n }\n };\n var this_1 = this;\n for (var i = 0; i < items.length; i++) {\n _loop_3(i);\n }\n };\n /* istanbul ignore next */\n Uploader.prototype.checkDirectoryUpload = function (items) {\n for (var i = 0; items && i < items.length; i++) {\n var item = items[i].webkitGetAsEntry();\n if (item.isDirectory) {\n return true;\n }\n }\n return false;\n };\n /* eslint-disable @typescript-eslint/explicit-module-boundary-types */\n /* istanbul ignore next */\n Uploader.prototype.traverseFileTree = function (item, event) {\n /* eslint-enable @typescript-eslint/explicit-module-boundary-types */\n if (item.isFile) {\n this.filesEntries.push(item);\n }\n else if (item.isDirectory) {\n var directoryReader = item.createReader();\n this.readFileFromDirectory(directoryReader, event);\n }\n };\n /* istanbul ignore next */\n Uploader.prototype.readFileFromDirectory = function (directoryReader, event) {\n var _this = this;\n directoryReader.readEntries(function (entries) {\n for (var i = 0; i < entries.length; i++) {\n _this.traverseFileTree(entries[i], event);\n }\n _this.pushFilesEntries(event);\n if (entries.length) {\n _this.readFileFromDirectory(directoryReader);\n }\n });\n };\n Uploader.prototype.pushFilesEntries = function (event) {\n var _this = this;\n var files = [];\n var _loop_4 = function (i) {\n this_2.filesEntries[i].file(function (fileObj) {\n if (_this.filesEntries.length) {\n var path = _this.filesEntries[i].fullPath;\n files.push({ 'path': path, 'file': fileObj });\n if (i === _this.filesEntries.length - 1) {\n _this.filesEntries = [];\n _this.renderSelectedFiles(event, files, true);\n }\n }\n });\n };\n var this_2 = this;\n for (var i = 0; i < this.filesEntries.length; i++) {\n _loop_4(i);\n }\n };\n Uploader.prototype.onSelectFiles = function (args) {\n if (!this.enabled) {\n return;\n }\n var targetFiles;\n /* istanbul ignore next */\n if (args.type === 'drop') {\n if (this.directoryUpload) {\n this.getFilesFromFolder(args);\n }\n else {\n var files = this.sortFilesList = args.dataTransfer.files;\n if (this.browserName !== 'msie' && this.browserName !== 'edge' && this.browserName !== 'safari') {\n this.element.files = files;\n }\n if (files.length > 0) {\n targetFiles = this.multiple ? this.sortFileList(files) : [files[0]];\n this.renderSelectedFiles(args, targetFiles);\n }\n }\n }\n else {\n targetFiles = [].slice.call(args.target.files);\n this.renderSelectedFiles(args, targetFiles);\n }\n if (this.isAngular || this.isReact) {\n args.stopPropagation();\n }\n };\n /* istanbul ignore next */\n Uploader.prototype.getBase64 = function (file) {\n return new Promise(function (resolve, reject) {\n var fileReader = new FileReader();\n fileReader.readAsDataURL(file);\n fileReader.onload = function () { return resolve(fileReader.result); };\n fileReader.onerror = function (error) { return reject(error); };\n });\n };\n /* istanbul ignore next */\n /* tslint:ignore */\n Uploader.prototype.renderSelectedFiles = function (args, targetFiles, directory, paste) {\n var _this = this;\n this.base64String = [];\n var eventArgs = {\n event: args,\n cancel: false,\n filesData: [],\n isModified: false,\n modifiedFilesData: [],\n progressInterval: '',\n isCanceled: false,\n currentRequest: null,\n customFormData: null\n };\n /* istanbul ignore next */\n if (targetFiles.length < 1) {\n eventArgs.isCanceled = true;\n this.trigger('selected', eventArgs);\n return;\n }\n this.flag = true;\n var fileData = [];\n if (!this.multiple) {\n this.clearData(true);\n this.actionCompleteCount = 0;\n targetFiles = [targetFiles[0]];\n }\n for (var i = 0; i < targetFiles.length; i++) {\n var file = directory ? targetFiles[i].file : targetFiles[i];\n this.updateInitialFileDetails(args, targetFiles, file, i, fileData, directory, paste);\n }\n eventArgs.filesData = fileData;\n if (this.allowedExtensions.indexOf('*') > -1) {\n this.allTypes = true;\n }\n if (this.enableHtmlSanitizer) {\n for (var i = 0; i < fileData.length; i++) {\n var sanitizeFile = SanitizeHtmlHelper.beforeSanitize();\n var sanitizeFileName = SanitizeHtmlHelper.serializeValue(sanitizeFile, fileData[parseInt(i.toString())].name);\n var currentFileName = fileData[parseInt(i.toString())].name;\n var isUTF8 = false;\n for (var i_1 = 0; i_1 < currentFileName.length; i_1++) {\n if (currentFileName.charCodeAt(i_1) > 127) {\n isUTF8 = true;\n break;\n }\n }\n var htmlTagRegex = /<([a-z][a-z0-9]*)\\b[^>]*>(.*?)<\\/\\1>/i;\n var hasHTMLString = htmlTagRegex.test(currentFileName);\n if ((sanitizeFileName !== fileData[parseInt(i.toString())].name) && !(isUTF8 && !hasHTMLString)) {\n var encodedFileName = targetFiles[parseInt(i.toString())].name.replace(/[\\u00A0-\\u9999<>\\&]/g, function (i) {\n return '&#' + i.charCodeAt(0) + ';';\n });\n fileData[parseInt(i.toString())].name = encodedFileName;\n fileData[parseInt(i.toString())].status = this.localizedTexts('invalidFileName');\n fileData[parseInt(i.toString())].statusCode = '0';\n }\n }\n }\n if (!this.allTypes) {\n fileData = this.checkExtension(fileData);\n }\n this.trigger('selected', eventArgs, function (eventArgs) {\n _this._internalRenderSelect(eventArgs, fileData);\n });\n };\n Uploader.prototype.updateInitialFileDetails = function (args, \n // eslint-disable-next-line @typescript-eslint/indent\n targetFiles, file, i, fileData, directory, paste) {\n var fileName = directory ? targetFiles[i].path.substring(1, targetFiles[i].path.length) : paste ?\n getUniqueID(file.name.substring(0, file.name.lastIndexOf('.'))) + '.' + this.getFileType(file.name) :\n this.directoryUpload ? targetFiles[i].webkitRelativePath : file.name;\n var fileDetails = {\n name: fileName,\n rawFile: file,\n size: file.size,\n status: this.localizedTexts('readyToUploadMessage'),\n type: this.getFileType(file.name),\n validationMessages: this.validatedFileSize(file.size),\n statusCode: '1',\n id: getUniqueID(file.name.substring(0, file.name.lastIndexOf('.'))) + '.' + this.getFileType(file.name)\n };\n /* istanbul ignore next */\n if (paste) {\n fileDetails.fileSource = 'paste';\n }\n fileDetails.status = fileDetails.validationMessages.minSize !== '' ? this.localizedTexts('invalidMinFileSize') :\n fileDetails.validationMessages.maxSize !== '' ? this.localizedTexts('invalidMaxFileSize') : fileDetails.status;\n if (fileDetails.validationMessages.minSize !== '' || fileDetails.validationMessages.maxSize !== '') {\n fileDetails.statusCode = '0';\n }\n fileData.push(fileDetails);\n };\n Uploader.prototype._internalRenderSelect = function (eventArgs, fileData) {\n if (!eventArgs.cancel) {\n /* istanbul ignore next */\n this.selectedFiles = this.selectedFiles.concat(fileData);\n this.btnTabIndex = this.disableKeyboardNavigation ? '-1' : '0';\n if (this.showFileList) {\n if (eventArgs.isModified && eventArgs.modifiedFilesData.length > 0) {\n for (var j = 0; j < eventArgs.modifiedFilesData.length; j++) {\n for (var k = 0; k < fileData.length; k++) {\n if (eventArgs.modifiedFilesData[j].id === fileData[k].id) {\n eventArgs.modifiedFilesData[j].rawFile = fileData[k].rawFile;\n }\n }\n }\n var dataFiles = this.allTypes ? eventArgs.modifiedFilesData :\n this.checkExtension(eventArgs.modifiedFilesData);\n this.updateSortedFileList(dataFiles);\n this.filesData = this.filesData.concat(dataFiles);\n if (!this.isForm || this.allowUpload()) {\n this.checkAutoUpload(dataFiles);\n }\n }\n else {\n this.internalCreateFileList(fileData);\n if (this.autoUpload && this.sequenceUpload && this.sequentialUpload && this.filesData.length > 0 && this.filesData[this.filesData.length - 1].statusCode !== '2' && this.filesData[this.filesData.length - 1].statusCode !== '0') {\n this.filesData = this.filesData.concat(fileData);\n return;\n }\n this.filesData = this.filesData.concat(fileData);\n if (!this.isForm || this.allowUpload()) {\n this.checkAutoUpload(fileData);\n }\n }\n if (!isNullOrUndefined(eventArgs.progressInterval) && eventArgs.progressInterval !== '') {\n this.progressInterval = eventArgs.progressInterval;\n }\n }\n else {\n this.filesData = this.filesData.concat(fileData);\n if (this.autoUpload) {\n this.upload(this.filesData, true);\n }\n }\n for (var item = 0; item < this.filesData.length; item++) {\n if (this.filesData[item].statusCode === '0') {\n this.checkActionComplete(true);\n }\n }\n this.isFirstFileOnSelection = true;\n }\n };\n Uploader.prototype.allowUpload = function () {\n var allowFormUpload = false;\n if (this.isForm && (!isNullOrUndefined(this.asyncSettings.saveUrl) && this.asyncSettings.saveUrl !== '')) {\n allowFormUpload = true;\n }\n return allowFormUpload;\n };\n Uploader.prototype.isFormUpload = function () {\n var isFormUpload = false;\n if (this.isForm && ((isNullOrUndefined(this.asyncSettings.saveUrl) || this.asyncSettings.saveUrl === '')\n && (isNullOrUndefined(this.asyncSettings.removeUrl) || this.asyncSettings.removeUrl === ''))) {\n isFormUpload = true;\n }\n return isFormUpload;\n };\n Uploader.prototype.clearData = function (singleUpload) {\n if (!isNullOrUndefined(this.listParent)) {\n detach(this.listParent);\n this.listParent = null;\n }\n if (this.browserName !== 'msie' && !singleUpload) {\n this.element.value = '';\n }\n this.fileList = [];\n this.filesData = [];\n this.removeActionButtons();\n };\n Uploader.prototype.updateSortedFileList = function (filesData) {\n var previousListClone = this.createElement('div', { id: 'clonewrapper' });\n var added = -1;\n var removedList;\n if (this.listParent) {\n for (var i = 0; i < this.listParent.querySelectorAll('li').length; i++) {\n var liElement = this.listParent.querySelectorAll('li')[i];\n previousListClone.appendChild(liElement.cloneNode(true));\n }\n this.removeActionButtons();\n var oldList = [].slice.call(previousListClone.childNodes);\n this.createParentUL();\n for (var index = 0; index < filesData.length; index++) {\n for (var j = 0; j < this.filesData.length; j++) {\n if (this.filesData[j].name === filesData[index].name) {\n this.listParent.appendChild(oldList[j]);\n EventHandler.add(oldList[j].querySelector('.e-icons'), 'click', this.removeFiles, this);\n this.fileList.push(oldList[j]);\n added = index;\n }\n }\n if (added !== index) {\n this.internalCreateFileList([filesData[index]]);\n }\n }\n }\n else {\n this.internalCreateFileList(filesData);\n }\n };\n Uploader.prototype.isBlank = function (str) {\n return (!str || /^\\s*$/.test(str));\n };\n Uploader.prototype.checkExtension = function (files) {\n var dropFiles = files;\n if (!this.isBlank(this.allowedExtensions)) {\n var allowedExtensions = [];\n var extensions = this.allowedExtensions.split(',');\n for (var _i = 0, extensions_1 = extensions; _i < extensions_1.length; _i++) {\n var extension = extensions_1[_i];\n allowedExtensions.push(extension.trim().toLocaleLowerCase());\n }\n for (var i = 0; i < files.length; i++) {\n if (allowedExtensions.indexOf(('.' + files[i].type).toLocaleLowerCase()) === -1) {\n files[i].status = this.localizedTexts('invalidFileType');\n files[i].statusCode = '0';\n }\n }\n }\n return dropFiles;\n };\n Uploader.prototype.validatedFileSize = function (fileSize) {\n var minSizeError = '';\n var maxSizeError = '';\n if (fileSize < this.minFileSize) {\n minSizeError = this.localizedTexts('invalidMinFileSize');\n }\n else if (fileSize > this.maxFileSize) {\n maxSizeError = this.localizedTexts('invalidMaxFileSize');\n }\n else {\n minSizeError = '';\n maxSizeError = '';\n }\n var errorMessage = { minSize: minSizeError, maxSize: maxSizeError };\n return errorMessage;\n };\n Uploader.prototype.isPreLoadFile = function (fileData) {\n var isPreload = false;\n for (var i = 0; i < this.files.length; i++) {\n if (this.files[i].name === fileData.name.slice(0, fileData.name.lastIndexOf('.')) && this.files[i].type === fileData.type) {\n isPreload = true;\n }\n }\n return isPreload;\n };\n Uploader.prototype.createCustomfileList = function (fileData) {\n this.createParentUL();\n for (var _i = 0, fileData_1 = fileData; _i < fileData_1.length; _i++) {\n var listItem = fileData_1[_i];\n var listElement = this.createElement('li', { className: FILE, attrs: { 'data-file-name': listItem.name } });\n this.uploadTemplateFn = this.templateComplier(this.template);\n var liTempCompiler = this.uploadTemplateFn(listItem, this, 'template', this.element.id + 'Template', this.isStringTemplate, null, listElement);\n if (liTempCompiler) {\n var fromElements = [].slice.call(liTempCompiler);\n append(fromElements, listElement);\n }\n var index = fileData.indexOf(listItem);\n var eventArgs = {\n element: listElement,\n fileInfo: listItem,\n index: index,\n isPreload: this.isPreLoadFile(listItem)\n };\n var eventsArgs = {\n element: listElement,\n fileInfo: listItem,\n index: index,\n isPreload: this.isPreLoadFile(listItem)\n };\n this.trigger('rendering', eventArgs);\n this.trigger('fileListRendering', eventsArgs);\n this.listParent.appendChild(listElement);\n this.fileList.push(listElement);\n }\n this.renderReactTemplates();\n };\n Uploader.prototype.createParentUL = function () {\n if (isNullOrUndefined(this.listParent)) {\n this.listParent = this.createElement('ul', { className: LIST_PARENT });\n this.uploadWrapper.appendChild(this.listParent);\n }\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Uploader.prototype.formFileList = function (fileData, files) {\n var fileList = this.createElement('li', { className: FILE });\n fileList.setAttribute('data-files-count', fileData.length + '');\n var fileContainer = this.createElement('span', { className: TEXT_CONTAINER });\n var statusMessage;\n for (var _i = 0, fileData_2 = fileData; _i < fileData_2.length; _i++) {\n var listItem = fileData_2[_i];\n var fileNameEle = this.createElement('span', { className: FILE_NAME });\n fileNameEle.innerHTML = this.getFileNameOnly(listItem.name);\n var fileTypeEle = this.createElement('span', { className: FILE_TYPE });\n var fileType = this.getFileType(listItem.name);\n fileTypeEle.innerHTML = '.' + fileType;\n if (!fileType) {\n fileTypeEle.classList.add('e-hidden');\n }\n if (!this.enableRtl) {\n fileContainer.appendChild(fileNameEle);\n fileContainer.appendChild(fileTypeEle);\n }\n else {\n var rtlContainer = this.createElement('span', { className: RTL_CONTAINER });\n rtlContainer.appendChild(fileTypeEle);\n rtlContainer.appendChild(fileNameEle);\n fileContainer.appendChild(rtlContainer);\n }\n this.truncateName(fileNameEle);\n statusMessage = this.formValidateFileInfo(listItem, fileList);\n }\n fileList.appendChild(fileContainer);\n this.setListToFileInfo(fileData, fileList);\n var index = this.listParent.querySelectorAll('li').length;\n var infoEle = this.createElement('span');\n if (fileList.classList.contains(INVALID_FILE)) {\n infoEle.classList.add(STATUS);\n infoEle.classList.add(INVALID_FILE);\n infoEle.innerText = fileData.length > 1 ? this.localizedTexts('invalidFileSelection') : statusMessage;\n }\n else {\n infoEle.classList.add(fileData.length > 1 ? INFORMATION : FILE_SIZE);\n infoEle.innerText = fileData.length > 1 ? this.localizedTexts('totalFiles') + ': ' + fileData.length + ' , '\n + this.localizedTexts('size') + ': ' +\n this.bytesToSize(this.getFileSize(fileData)) : this.bytesToSize(fileData[0].size);\n this.createFormInput(fileData);\n }\n fileContainer.appendChild(infoEle);\n if (isNullOrUndefined(fileList.querySelector('.e-icons'))) {\n var iconElement = this.createElement('span', { className: 'e-icons', attrs: { 'tabindex': this.btnTabIndex } });\n /* istanbul ignore next */\n if (this.browserName === 'msie') {\n iconElement.classList.add('e-msie');\n }\n iconElement.setAttribute('title', this.localizedTexts('remove'));\n fileList.appendChild(fileContainer);\n fileList.appendChild(iconElement);\n EventHandler.add(iconElement, 'click', this.removeFiles, this);\n iconElement.classList.add(REMOVE_ICON);\n }\n var eventArgs = {\n element: fileList,\n fileInfo: this.mergeFileInfo(fileData, fileList),\n index: index,\n isPreload: this.isPreLoadFile(this.mergeFileInfo(fileData, fileList))\n };\n var eventsArgs = {\n element: fileList,\n fileInfo: this.mergeFileInfo(fileData, fileList),\n index: index,\n isPreload: this.isPreLoadFile(this.mergeFileInfo(fileData, fileList))\n };\n this.trigger('rendering', eventArgs);\n this.trigger('fileListRendering', eventsArgs);\n this.listParent.appendChild(fileList);\n this.fileList.push(fileList);\n };\n Uploader.prototype.formValidateFileInfo = function (listItem, fileList) {\n var statusMessage = listItem.status;\n var validationMessages = this.validatedFileSize(listItem.size);\n if (validationMessages.minSize !== '' || validationMessages.maxSize !== '') {\n this.addInvalidClass(fileList);\n statusMessage = validationMessages.minSize !== '' ? this.localizedTexts('invalidMinFileSize') :\n validationMessages.maxSize !== '' ? this.localizedTexts('invalidMaxFileSize') : statusMessage;\n }\n var typeValidationMessage = this.checkExtension(this.getFilesInArray(listItem))[0].status;\n if (typeValidationMessage === this.localizedTexts('invalidFileType')) {\n this.addInvalidClass(fileList);\n statusMessage = typeValidationMessage;\n }\n return statusMessage;\n };\n Uploader.prototype.addInvalidClass = function (fileList) {\n fileList.classList.add(INVALID_FILE);\n };\n Uploader.prototype.createFormInput = function (fileData) {\n if (this.browserName !== 'safari') {\n var inputElement = this.element.cloneNode(true);\n inputElement.classList.add(HIDDEN_INPUT);\n for (var _i = 0, fileData_3 = fileData; _i < fileData_3.length; _i++) {\n var listItem = fileData_3[_i];\n listItem.input = inputElement;\n }\n inputElement.setAttribute('id', getUniqueID('hiddenUploader'));\n inputElement.setAttribute('name', this.uploaderName);\n this.uploadWrapper.querySelector('.' + INPUT_WRAPPER).appendChild(inputElement);\n if (this.browserName !== 'msie' && this.browserName !== 'edge') {\n this.element.value = '';\n }\n }\n };\n Uploader.prototype.getFileSize = function (fileData) {\n var fileSize = 0;\n for (var _i = 0, fileData_4 = fileData; _i < fileData_4.length; _i++) {\n var file = fileData_4[_i];\n fileSize += file.size;\n }\n return fileSize;\n };\n Uploader.prototype.mergeFileInfo = function (fileData, fileList) {\n var result = {\n name: '',\n rawFile: '',\n size: 0,\n status: '',\n type: '',\n validationMessages: { minSize: '', maxSize: '' },\n statusCode: '1',\n list: fileList\n };\n var fileNames = [];\n var type = '';\n for (var _i = 0, fileData_5 = fileData; _i < fileData_5.length; _i++) {\n var listItem = fileData_5[_i];\n fileNames.push(listItem.name);\n type = listItem.type;\n }\n result.name = fileNames.join(', ');\n result.size = this.getFileSize(fileData);\n result.type = type;\n result.status = this.statusForFormUpload(fileData, fileList);\n return result;\n };\n Uploader.prototype.statusForFormUpload = function (fileData, fileList) {\n var isValid = true;\n var statusMessage;\n for (var _i = 0, fileData_6 = fileData; _i < fileData_6.length; _i++) {\n var listItem = fileData_6[_i];\n statusMessage = listItem.status;\n var validationMessages = this.validatedFileSize(listItem.size);\n if (validationMessages.minSize !== '' || validationMessages.maxSize !== '') {\n isValid = false;\n statusMessage = validationMessages.minSize !== '' ? this.localizedTexts('invalidMinFileSize') :\n validationMessages.maxSize !== '' ? this.localizedTexts('invalidMaxFileSize') : statusMessage;\n }\n var typeValidationMessage = this.checkExtension(this.getFilesInArray(listItem))[0].status;\n if (typeValidationMessage === this.localizedTexts('invalidFileType')) {\n isValid = false;\n statusMessage = typeValidationMessage;\n }\n }\n if (!isValid) {\n fileList.classList.add(INVALID_FILE);\n statusMessage = fileData.length > 1 ? this.localizedTexts('invalidFileSelection') : statusMessage;\n }\n else {\n statusMessage = this.localizedTexts('totalFiles') + ': ' + fileData.length + ' , '\n + this.localizedTexts('size') + ': ' +\n this.bytesToSize(this.getFileSize(fileData));\n }\n return statusMessage;\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Uploader.prototype.formCustomFileList = function (fileData, files) {\n this.createParentUL();\n var fileList = this.createElement('li', { className: FILE });\n fileList.setAttribute('data-files-count', fileData.length + '');\n this.setListToFileInfo(fileData, fileList);\n var result = this.mergeFileInfo(fileData, fileList);\n fileList.setAttribute('data-file-name', result.name);\n this.uploadTemplateFn = this.templateComplier(this.template);\n var liTempCompiler = this.uploadTemplateFn(result, this, 'template', this.element.id + 'Template', this.isStringTemplate, null, fileList);\n if (liTempCompiler) {\n var fromElements = [].slice.call(liTempCompiler);\n append(fromElements, fileList);\n }\n var index = this.listParent.querySelectorAll('li').length;\n if (!fileList.classList.contains(INVALID_FILE)) {\n this.createFormInput(fileData);\n }\n var eventArgs = {\n element: fileList,\n fileInfo: result,\n index: index,\n isPreload: this.isPreLoadFile(result)\n };\n var eventsArgs = {\n element: fileList,\n fileInfo: result,\n index: index,\n isPreload: this.isPreLoadFile(result)\n };\n this.trigger('rendering', eventArgs);\n this.trigger('fileListRendering', eventsArgs);\n this.listParent.appendChild(fileList);\n this.fileList.push(fileList);\n this.renderReactTemplates();\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-param */\n /**\n * Create the file list for specified files data.\n *\n * @param { FileInfo[] } fileData - Specifies the files data for file list creation.\n * @returns {void}\n */\n Uploader.prototype.createFileList = function (fileData) {\n this.filesData = this.filesData && this.filesData.length > 0 ? this.filesData.concat(fileData) : fileData;\n this.internalCreateFileList(fileData);\n };\n Uploader.prototype.internalCreateFileList = function (fileData) {\n /* eslint-enable valid-jsdoc, jsdoc/require-param */\n this.createParentUL();\n if (this.template !== '' && !isNullOrUndefined(this.template)) {\n if (this.isFormUpload()) {\n this.uploadWrapper.classList.add(FORM_UPLOAD);\n this.formCustomFileList(fileData, this.element.files);\n }\n else {\n this.createCustomfileList(fileData);\n }\n }\n else if (this.isFormUpload()) {\n this.uploadWrapper.classList.add(FORM_UPLOAD);\n this.formFileList(fileData, this.element.files);\n }\n else {\n for (var _i = 0, fileData_7 = fileData; _i < fileData_7.length; _i++) {\n var listItem = fileData_7[_i];\n var liElement = this.createElement('li', {\n className: FILE,\n attrs: { 'data-file-name': listItem.name, 'data-files-count': '1' }\n });\n var textContainer = this.createElement('span', { className: TEXT_CONTAINER });\n var textElement = this.createElement('span', { className: FILE_NAME, attrs: { 'title': listItem.name } });\n textElement.innerHTML = this.getFileNameOnly(listItem.name);\n var fileExtension = this.createElement('span', { className: FILE_TYPE });\n var fileType = this.getFileType(listItem.name);\n fileExtension.innerHTML = '.' + fileType;\n if (!fileType) {\n fileExtension.classList.add('e-hidden');\n }\n if (!this.enableRtl) {\n textContainer.appendChild(textElement);\n textContainer.appendChild(fileExtension);\n }\n else {\n var rtlContainer = this.createElement('span', { className: RTL_CONTAINER });\n rtlContainer.appendChild(fileExtension);\n rtlContainer.appendChild(textElement);\n textContainer.appendChild(rtlContainer);\n }\n var fileSize = this.createElement('span', { className: FILE_SIZE });\n fileSize.innerHTML = this.bytesToSize(listItem.size);\n textContainer.appendChild(fileSize);\n var statusElement = this.createElement('span', { className: STATUS });\n textContainer.appendChild(statusElement);\n statusElement.innerHTML = listItem.status;\n liElement.appendChild(textContainer);\n var iconElement = this.createElement('span', { className: ' e-icons',\n attrs: { 'tabindex': this.btnTabIndex } });\n /* istanbul ignore next */\n if (this.browserName === 'msie') {\n iconElement.classList.add('e-msie');\n }\n iconElement.setAttribute('title', this.localizedTexts('remove'));\n liElement.appendChild(iconElement);\n EventHandler.add(iconElement, 'click', this.removeFiles, this);\n if (listItem.statusCode === '2') {\n statusElement.classList.add(UPLOAD_SUCCESS);\n iconElement.classList.add(DELETE_ICON);\n iconElement.setAttribute('title', this.localizedTexts('delete'));\n }\n else if (listItem.statusCode !== '1') {\n statusElement.classList.remove(UPLOAD_SUCCESS);\n statusElement.classList.add(VALIDATION_FAILS);\n }\n if (this.autoUpload && listItem.statusCode === '1' && this.asyncSettings.saveUrl !== '') {\n statusElement.innerHTML = '';\n }\n if (!iconElement.classList.contains(DELETE_ICON)) {\n iconElement.classList.add(REMOVE_ICON);\n }\n var index = fileData.indexOf(listItem);\n var eventArgs = {\n element: liElement,\n fileInfo: listItem,\n index: index,\n isPreload: this.isPreLoadFile(listItem)\n };\n var eventsArgs = {\n element: liElement,\n fileInfo: listItem,\n index: index,\n isPreload: this.isPreLoadFile(listItem)\n };\n this.trigger('rendering', eventArgs);\n this.trigger('fileListRendering', eventsArgs);\n this.listParent.appendChild(liElement);\n this.fileList.push(liElement);\n this.truncateName(textElement);\n var preventActionComplete = this.flag;\n if (this.isPreLoadFile(listItem)) {\n this.flag = false;\n this.checkActionComplete(true);\n this.flag = preventActionComplete;\n }\n }\n }\n };\n Uploader.prototype.getSlicedName = function (nameElement) {\n var text = nameElement.textContent;\n nameElement.dataset.tail = text.slice(text.length - 10);\n };\n Uploader.prototype.setListToFileInfo = function (fileData, fileList) {\n for (var _i = 0, fileData_8 = fileData; _i < fileData_8.length; _i++) {\n var listItem = fileData_8[_i];\n listItem.list = fileList;\n }\n };\n Uploader.prototype.truncateName = function (name) {\n var nameElement = name;\n if (this.browserName !== 'edge' && nameElement.offsetWidth < nameElement.scrollWidth) {\n this.getSlicedName(nameElement);\n /* istanbul ignore next */\n }\n else if (nameElement.offsetWidth + 1 < nameElement.scrollWidth) {\n this.getSlicedName(nameElement);\n }\n };\n Uploader.prototype.getFileType = function (name) {\n var extension;\n var index = name.lastIndexOf('.');\n if (index >= 0) {\n extension = name.substring(index + 1);\n }\n return extension ? extension : '';\n };\n Uploader.prototype.getFileNameOnly = function (name) {\n var type = this.getFileType(name);\n var names = name.split('.' + type);\n return type = names[0];\n };\n Uploader.prototype.setInitialAttributes = function () {\n if (this.initialAttr.accept) {\n this.element.setAttribute('accept', this.initialAttr.accept);\n }\n if (this.initialAttr.disabled) {\n this.element.setAttribute('disabled', 'disabled');\n }\n if (this.initialAttr.multiple) {\n var newAttr = document.createAttribute('multiple');\n this.element.setAttributeNode(newAttr);\n }\n };\n Uploader.prototype.filterfileList = function (files) {\n var filterFiles = [];\n var li;\n for (var i = 0; i < files.length; i++) {\n li = this.getLiElement(files[i]);\n if (!li.classList.contains(UPLOAD_SUCCESS)) {\n filterFiles.push(files[i]);\n }\n }\n return filterFiles;\n };\n Uploader.prototype.updateStatus = function (files, status, statusCode, updateLiStatus) {\n if (updateLiStatus === void 0) { updateLiStatus = true; }\n if (!(status === '' || isNullOrUndefined(status)) && !(statusCode === '' || isNullOrUndefined(statusCode))) {\n files.status = status;\n files.statusCode = statusCode;\n }\n if (updateLiStatus) {\n var li = this.getLiElement(files);\n if (!isNullOrUndefined(li)) {\n if (!isNullOrUndefined(li.querySelector('.' + STATUS)) && !((status === '' || isNullOrUndefined(status)))) {\n li.querySelector('.' + STATUS).textContent = status;\n }\n }\n }\n return files;\n };\n Uploader.prototype.getLiElement = function (files) {\n var index;\n for (var i = 0; i < this.filesData.length; i++) {\n if (!isNullOrUndefined(files) && ((!isNullOrUndefined(this.filesData[i].id) &&\n !isNullOrUndefined(files.id)) ? (this.filesData[i].name === files.name &&\n this.filesData[i].id === files.id) : this.filesData[i].name === files.name)) {\n index = i;\n }\n }\n return this.fileList[index];\n };\n Uploader.prototype.createProgressBar = function (liElement) {\n var progressbarWrapper = this.createElement('span', { className: PROGRESS_WRAPPER });\n var progressBar = this.createElement('progressbar', { className: PROGRESSBAR, attrs: { value: '0', max: '100' } });\n var progressbarInnerWrapper = this.createElement('span', { className: PROGRESS_INNER_WRAPPER });\n progressBar.setAttribute('style', 'width: 0%');\n var progressbarText = this.createElement('span', { className: PROGRESSBAR_TEXT });\n progressbarText.textContent = '0%';\n progressbarInnerWrapper.appendChild(progressBar);\n progressbarWrapper.appendChild(progressbarInnerWrapper);\n progressbarWrapper.appendChild(progressbarText);\n liElement.querySelector('.' + TEXT_CONTAINER).appendChild(progressbarWrapper);\n };\n /* istanbul ignore next */\n Uploader.prototype.updateProgressbar = function (e, li) {\n if (!isNaN(Math.round((e.loaded / e.total) * 100)) && !isNullOrUndefined(li.querySelector('.' + PROGRESSBAR))) {\n if (!isNullOrUndefined(this.progressInterval) && this.progressInterval !== '') {\n var value = (Math.round((e.loaded / e.total) * 100)) % parseInt(this.progressInterval, 10);\n if (value === 0 || value === 100) {\n this.changeProgressValue(li, Math.round((e.loaded / e.total) * 100).toString() + '%');\n }\n }\n else {\n this.changeProgressValue(li, Math.round((e.loaded / e.total) * 100).toString() + '%');\n }\n }\n };\n Uploader.prototype.changeProgressValue = function (li, progressValue) {\n li.querySelector('.' + PROGRESSBAR).setAttribute('style', 'width:' + progressValue);\n li.querySelector('.' + PROGRESSBAR_TEXT).textContent = progressValue;\n };\n Uploader.prototype.uploadInProgress = function (e, files, customUI, request) {\n var li = this.getLiElement(files);\n if (isNullOrUndefined(li) && (!customUI)) {\n return;\n }\n if (!isNullOrUndefined(li)) {\n /* istanbul ignore next */\n if (files.statusCode === '5') {\n this.cancelUploadingFile(files, e, request, li);\n }\n if (!(li.querySelectorAll('.' + PROGRESS_WRAPPER).length > 0) && li.querySelector('.' + STATUS)) {\n li.querySelector('.' + STATUS).classList.add(UPLOAD_INPROGRESS);\n this.createProgressBar(li);\n this.updateProgressBarClasses(li, UPLOAD_INPROGRESS);\n li.querySelector('.' + STATUS).classList.remove(UPLOAD_FAILED);\n }\n this.updateProgressbar(e, li);\n var iconEle = li.querySelector('.' + REMOVE_ICON);\n if (!isNullOrUndefined(iconEle)) {\n iconEle.classList.add(ABORT_ICON, UPLOAD_INPROGRESS);\n iconEle.setAttribute('title', this.localizedTexts('abort'));\n iconEle.classList.remove(REMOVE_ICON);\n }\n }\n else {\n this.cancelUploadingFile(files, e, request);\n }\n var args = { e: e, operation: 'upload', file: this.updateStatus(files, this.localizedTexts('inProgress'), '3') };\n this.trigger('progress', args);\n };\n /* istanbul ignore next */\n Uploader.prototype.cancelUploadingFile = function (files, e, request, li) {\n var _this = this;\n if (files.statusCode === '5') {\n var eventArgs = {\n event: e,\n fileData: files,\n cancel: false,\n customFormData: [],\n currentRequest: null\n };\n this.trigger('canceling', eventArgs, function (eventArgs) {\n if (eventArgs.cancel) {\n files.statusCode = '3';\n if (!isNullOrUndefined(li)) {\n var spinnerTarget = li.querySelector('.' + ABORT_ICON);\n if (!isNullOrUndefined(spinnerTarget)) {\n hideSpinner(spinnerTarget);\n detach(li.querySelector('.e-spinner-pane'));\n }\n }\n }\n else {\n request.emitError = false;\n request.httpRequest.abort();\n var formData = new FormData();\n if (files.statusCode === '5') {\n var name_1 = _this.element.getAttribute('name');\n formData.append(name_1, files.name);\n formData.append('cancel-uploading', files.name);\n _this.updateFormData(formData, eventArgs.customFormData);\n var ajax_1 = new Ajax(_this.asyncSettings.removeUrl, 'POST', true, null);\n ajax_1.emitError = false;\n ajax_1.beforeSend = function (e) {\n if (eventArgs.currentRequest) {\n _this.updateCustomheader(ajax_1.httpRequest, eventArgs.currentRequest);\n }\n };\n ajax_1.onLoad = function (e) {\n _this.removecanceledFile(e, files);\n return {};\n };\n ajax_1.send(formData);\n }\n }\n });\n }\n };\n Uploader.prototype.removecanceledFile = function (e, file) {\n var liElement = this.getLiElement(file);\n if (isNullOrUndefined(liElement) || liElement.querySelector('.' + RETRY_ICON) || isNullOrUndefined(liElement.querySelector('.' + ABORT_ICON))) {\n return;\n }\n this.updateStatus(file, this.localizedTexts('fileUploadCancel'), '5');\n this.renderFailureState(e, file, liElement);\n var spinnerTarget = liElement.querySelector('.' + REMOVE_ICON);\n if (!isNullOrUndefined(liElement)) {\n hideSpinner(spinnerTarget);\n if (!isNullOrUndefined(liElement.querySelector('.e-spinner-pane'))) {\n detach(liElement.querySelector('.e-spinner-pane'));\n }\n }\n var requestResponse = e && e.currentTarget ? this.getResponse(e) : null;\n var args = { event: e, response: requestResponse, operation: 'cancel', file: file };\n this.trigger('success', args);\n };\n Uploader.prototype.renderFailureState = function (e, file, liElement) {\n var _this = this;\n this.updateProgressBarClasses(liElement, UPLOAD_FAILED);\n this.removeProgressbar(liElement, 'failure');\n if (!isNullOrUndefined(liElement.querySelector('.e-file-status'))) {\n liElement.querySelector('.e-file-status').classList.add(UPLOAD_FAILED);\n }\n var deleteIcon = liElement.querySelector('.' + ABORT_ICON);\n if (isNullOrUndefined(deleteIcon)) {\n return;\n }\n deleteIcon.classList.remove(ABORT_ICON, UPLOAD_INPROGRESS);\n deleteIcon.classList.add(REMOVE_ICON);\n deleteIcon.setAttribute('title', this.localizedTexts('remove'));\n this.pauseButton = this.createElement('span', { className: 'e-icons e-file-reload-btn', attrs: { 'tabindex': this.btnTabIndex } });\n deleteIcon.parentElement.insertBefore(this.pauseButton, deleteIcon);\n this.pauseButton.setAttribute('title', this.localizedTexts('retry'));\n var retryElement = liElement.querySelector('.' + RETRY_ICON);\n /* istanbul ignore next */\n retryElement.addEventListener('click', function (e) {\n _this.reloadcanceledFile(e, file, liElement, false);\n }, false);\n };\n Uploader.prototype.reloadcanceledFile = function (e, file, liElement, custom) {\n file.statusCode = '1';\n file.status = this.localizedTexts('readyToUploadMessage');\n if (!custom) {\n if (!isNullOrUndefined(liElement.querySelector('.' + STATUS))) {\n liElement.querySelector('.' + STATUS).classList.remove(UPLOAD_FAILED);\n }\n if (!isNullOrUndefined(liElement.querySelector('.' + RETRY_ICON))) {\n detach(liElement.querySelector('.' + RETRY_ICON));\n }\n this.pauseButton = null;\n }\n /* istanbul ignore next */\n if (!isNullOrUndefined(liElement)) {\n liElement.classList.add(RESTRICT_RETRY);\n }\n this.upload([file]);\n };\n /* istanbul ignore next */\n Uploader.prototype.uploadComplete = function (e, file, customUI) {\n var status = e.target;\n if (status.readyState === 4 && status.status >= 200 && status.status <= 299) {\n var li = this.getLiElement(file);\n if (isNullOrUndefined(li) && (!customUI || isNullOrUndefined(customUI))) {\n return;\n }\n if (!isNullOrUndefined(li)) {\n this.updateProgressBarClasses(li, UPLOAD_SUCCESS);\n this.removeProgressbar(li, 'success');\n var iconEle = li.querySelector('.' + ABORT_ICON);\n if (!isNullOrUndefined(iconEle)) {\n iconEle.classList.add(DELETE_ICON);\n iconEle.setAttribute('title', this.localizedTexts('delete'));\n iconEle.classList.remove(ABORT_ICON);\n iconEle.classList.remove(UPLOAD_INPROGRESS);\n }\n }\n this.raiseSuccessEvent(e, file);\n }\n else {\n this.uploadFailed(e, file);\n }\n };\n Uploader.prototype.getResponse = function (e) {\n var target = e.currentTarget;\n var response = {\n readyState: target.readyState,\n statusCode: target.status,\n statusText: target.statusText,\n headers: target.getAllResponseHeaders(),\n withCredentials: target.withCredentials\n };\n return response;\n };\n Uploader.prototype.raiseSuccessEvent = function (e, file) {\n var _this = this;\n var response = e && e.currentTarget ? this.getResponse(e) : null;\n var statusMessage = this.localizedTexts('uploadSuccessMessage');\n var args = {\n e: e, response: response, operation: 'upload', file: this.updateStatus(file, statusMessage, '2', false), statusText: statusMessage\n };\n var liElement = this.getLiElement(file);\n if (!isNullOrUndefined(liElement)) {\n var spinnerEle = liElement.querySelector('.' + SPINNER_PANE);\n if (!isNullOrUndefined(spinnerEle)) {\n hideSpinner(liElement);\n detach(spinnerEle);\n }\n }\n this.trigger('success', args, function (args) {\n _this.updateStatus(file, args.statusText, '2');\n _this.uploadedFilesData.push(file);\n _this.trigger('change', { file: _this.uploadedFilesData });\n _this.checkActionButtonStatus();\n if (_this.fileList.length > 0) {\n if ((!(_this.getLiElement(file)).classList.contains(RESTRICT_RETRY))) {\n _this.uploadSequential();\n _this.checkActionComplete(true);\n }\n else {\n /* istanbul ignore next */\n (_this.getLiElement(file)).classList.remove(RESTRICT_RETRY);\n }\n }\n else if (!_this.showFileList) {\n _this.checkActionComplete(true);\n }\n });\n };\n Uploader.prototype.uploadFailed = function (e, file) {\n var _this = this;\n var li = this.getLiElement(file);\n var response = e && e.currentTarget ? this.getResponse(e) : null;\n var statusMessage = this.localizedTexts('uploadFailedMessage');\n var args = {\n e: e, response: response, operation: 'upload', file: this.updateStatus(file, statusMessage, '0', false), statusText: statusMessage\n };\n if (!isNullOrUndefined(li)) {\n this.renderFailureState(e, file, li);\n }\n this.trigger('failure', args, function (args) {\n _this.updateStatus(file, args.statusText, '0');\n _this.checkActionButtonStatus();\n _this.uploadSequential();\n _this.checkActionComplete(true);\n });\n };\n Uploader.prototype.uploadSequential = function () {\n if (this.sequentialUpload) {\n if (this.autoUpload) {\n /* istanbul ignore next */\n this.checkAutoUpload(this.filesData);\n }\n else {\n this.uploadButtonClick();\n }\n }\n };\n Uploader.prototype.checkActionComplete = function (increment) {\n if (increment) {\n ++this.actionCompleteCount;\n }\n else {\n --this.actionCompleteCount;\n }\n this.raiseActionComplete();\n };\n Uploader.prototype.raiseActionComplete = function () {\n if ((this.filesData.length === this.actionCompleteCount) && this.flag) {\n this.flag = false;\n var eventArgs = {\n fileData: []\n };\n eventArgs.fileData = this.getSelectedFileStatus(this.selectedFiles);\n this.trigger('actionComplete', eventArgs);\n }\n };\n Uploader.prototype.getSelectedFileStatus = function (selectedFiles) {\n var matchFiles = [];\n var matchFilesIndex = 0;\n for (var selectFileIndex = 0; selectFileIndex < selectedFiles.length; selectFileIndex++) {\n var selectedFileData = selectedFiles[selectFileIndex];\n for (var fileDataIndex = 0; fileDataIndex < this.filesData.length; fileDataIndex++) {\n if (this.filesData[fileDataIndex].name === selectedFileData.name && this.filesData[fileDataIndex].status === selectedFileData.status) {\n matchFiles[matchFilesIndex] = this.filesData[fileDataIndex];\n ++matchFilesIndex;\n }\n }\n }\n return matchFiles;\n };\n Uploader.prototype.updateProgressBarClasses = function (li, className) {\n var progressBar = li.querySelector('.' + PROGRESSBAR);\n if (!isNullOrUndefined(progressBar)) {\n progressBar.classList.add(className);\n }\n };\n Uploader.prototype.removeProgressbar = function (li, callType) {\n var _this = this;\n if (!isNullOrUndefined(li.querySelector('.' + PROGRESS_WRAPPER))) {\n this.progressAnimation = new Animation({ duration: 1250 });\n this.progressAnimation.animate(li.querySelector('.' + PROGRESS_WRAPPER), { name: 'FadeOut' });\n this.progressAnimation.animate(li.querySelector('.' + PROGRESSBAR_TEXT), { name: 'FadeOut' });\n setTimeout(function () {\n _this.animateProgressBar(li, callType);\n }, 750);\n }\n };\n /* istanbul ignore next */\n Uploader.prototype.animateProgressBar = function (li, callType) {\n if (callType === 'success') {\n li.classList.add(UPLOAD_SUCCESS);\n if (!isNullOrUndefined(li.querySelector('.' + STATUS))) {\n li.querySelector('.' + STATUS).classList.remove(UPLOAD_INPROGRESS);\n this.progressAnimation.animate(li.querySelector('.' + STATUS), { name: 'FadeIn' });\n li.querySelector('.' + STATUS).classList.add(UPLOAD_SUCCESS);\n }\n }\n else {\n if (!isNullOrUndefined(li.querySelector('.' + STATUS))) {\n li.querySelector('.' + STATUS).classList.remove(UPLOAD_INPROGRESS);\n this.progressAnimation.animate(li.querySelector('.' + STATUS), { name: 'FadeIn' });\n li.querySelector('.' + STATUS).classList.add(UPLOAD_FAILED);\n }\n }\n if (li.querySelector('.' + PROGRESS_WRAPPER)) {\n detach(li.querySelector('.' + PROGRESS_WRAPPER));\n }\n };\n Uploader.prototype.setExtensions = function (extensions) {\n if (extensions !== '' && !isNullOrUndefined(extensions)) {\n this.element.setAttribute('accept', extensions);\n }\n else {\n this.element.removeAttribute('accept');\n }\n };\n Uploader.prototype.templateComplier = function (uploadTemplate) {\n if (uploadTemplate) {\n try {\n if (typeof uploadTemplate !== 'function' && selectAll(uploadTemplate, document).length) {\n return compile(select(uploadTemplate, document).innerHTML.trim());\n }\n else {\n return compile(uploadTemplate);\n }\n }\n catch (exception) {\n return compile(uploadTemplate);\n }\n }\n return undefined;\n };\n Uploader.prototype.setRTL = function () {\n if (this.enableRtl) {\n addClass([this.uploadWrapper], RTL);\n }\n else {\n removeClass([this.uploadWrapper], RTL);\n }\n };\n Uploader.prototype.localizedTexts = function (localeText) {\n this.l10n.setLocale(this.locale);\n return this.l10n.getConstant(localeText);\n };\n Uploader.prototype.setControlStatus = function () {\n if (!this.enabled) {\n this.uploadWrapper.classList.add(DISABLED);\n this.element.setAttribute('disabled', 'disabled');\n this.browseButton.setAttribute('disabled', 'disabled');\n if (!isNullOrUndefined(this.clearButton)) {\n this.clearButton.setAttribute('disabled', 'disabled');\n }\n if (!isNullOrUndefined(this.uploadButton)) {\n this.uploadButton.setAttribute('disabled', 'disabled');\n }\n }\n else {\n if (this.uploadWrapper.classList.contains(DISABLED)) {\n this.uploadWrapper.classList.remove(DISABLED);\n }\n if (!isNullOrUndefined(this.browseButton) && this.element.hasAttribute('disabled')) {\n this.element.removeAttribute('disabled');\n this.browseButton.removeAttribute('disabled');\n }\n if (!isNullOrUndefined(this.clearButton) && this.clearButton.hasAttribute('disabled')) {\n this.clearButton.removeAttribute('disabled');\n }\n if (!isNullOrUndefined(this.uploadButton) && this.uploadButton.hasAttribute('disabled')) {\n this.uploadButton.hasAttribute('disabled');\n }\n }\n };\n Uploader.prototype.checkHTMLAttributes = function (isDynamic) {\n var attributes = isDynamic ? isNullOrUndefined(this.htmlAttributes) ? [] : Object.keys(this.htmlAttributes) :\n ['accept', 'multiple', 'disabled'];\n for (var _i = 0, attributes_1 = attributes; _i < attributes_1.length; _i++) {\n var prop = attributes_1[_i];\n if (!isNullOrUndefined(this.element.getAttribute(prop))) {\n switch (prop) {\n case 'accept':\n if ((isNullOrUndefined(this.uploaderOptions) || (this.uploaderOptions['allowedExtensions'] === undefined))\n || isDynamic) {\n this.setProperties({ allowedExtensions: this.element.getAttribute('accept') }, !isDynamic);\n this.initialAttr.accept = this.allowedExtensions;\n }\n break;\n case 'multiple':\n if ((isNullOrUndefined(this.uploaderOptions) || (this.uploaderOptions['multiple'] === undefined)) || isDynamic) {\n var isMutiple = this.element.getAttribute(prop) === 'multiple' ||\n this.element.getAttribute(prop) === '' || this.element.getAttribute(prop) === 'true' ? true : false;\n this.setProperties({ multiple: isMutiple }, !isDynamic);\n this.initialAttr.multiple = true;\n }\n break;\n case 'disabled':\n if ((isNullOrUndefined(this.uploaderOptions) || (this.uploaderOptions['enabled'] === undefined)) || isDynamic) {\n var isDisabled = this.element.getAttribute(prop) === 'disabled' ||\n this.element.getAttribute(prop) === '' || this.element.getAttribute(prop) === 'true' ? false : true;\n this.setProperties({ enabled: isDisabled }, !isDynamic);\n this.initialAttr.disabled = true;\n }\n }\n }\n }\n };\n Uploader.prototype.chunkUpload = function (file, custom, fileIndex) {\n var start = 0;\n var end = Math.min(this.asyncSettings.chunkSize, file.size);\n var index = 0;\n var blob = file.rawFile.slice(start, end);\n var metaData = { chunkIndex: index, blob: blob, file: file, start: start, end: end, retryCount: 0, request: null };\n this.sendRequest(file, metaData, custom, fileIndex);\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Uploader.prototype.sendRequest = function (file, metaData, custom, fileIndex) {\n var _this = this;\n var formData = new FormData();\n var blob = file.rawFile.slice(metaData.start, metaData.end);\n formData.append(this.uploaderName, blob, file.name);\n formData.append('chunk-index', metaData.chunkIndex.toString());\n formData.append('chunkIndex', metaData.chunkIndex.toString());\n var totalChunk = Math.max(Math.ceil(file.size / this.asyncSettings.chunkSize), 1);\n formData.append('total-chunk', totalChunk.toString());\n formData.append('totalChunk', totalChunk.toString());\n var ajax = new Ajax({ url: this.asyncSettings.saveUrl, type: 'POST', async: true, contentType: null });\n ajax.emitError = false;\n ajax.onLoad = function (e) {\n _this.chunkUploadComplete(e, metaData, custom);\n return {};\n };\n ajax.onUploadProgress = function (e) {\n _this.chunkUploadInProgress(e, metaData, custom);\n return {};\n };\n var eventArgs = {\n fileData: file,\n customFormData: [],\n cancel: false,\n chunkSize: this.asyncSettings.chunkSize === 0 ? null : this.asyncSettings.chunkSize\n };\n ajax.beforeSend = function (e) {\n eventArgs.currentRequest = ajax.httpRequest;\n eventArgs.currentChunkIndex = metaData.chunkIndex;\n if (eventArgs.currentChunkIndex === 0) {\n // This event is currently not required but to avoid breaking changes for previous customer, we have included.\n _this.trigger('uploading', eventArgs, function (eventArgs) {\n _this.uploadingEventCallback(formData, eventArgs, e, file);\n });\n }\n else {\n _this.trigger('chunkUploading', eventArgs, function (eventArgs) {\n _this.uploadingEventCallback(formData, eventArgs, e, file);\n });\n }\n };\n /* istanbul ignore next */\n ajax.onError = function (e) {\n _this.chunkUploadFailed(e, metaData, custom);\n return {};\n };\n ajax.send(formData);\n metaData.request = ajax;\n };\n Uploader.prototype.uploadingEventCallback = function (formData, eventArgs, e, file) {\n if (eventArgs.cancel) {\n this.eventCancelByArgs(e, eventArgs, file);\n }\n else {\n this.updateFormData(formData, eventArgs.customFormData);\n }\n };\n Uploader.prototype.eventCancelByArgs = function (e, eventArgs, file) {\n var _this = this;\n e.cancel = true;\n if (eventArgs.fileData.statusCode === '5') {\n return;\n }\n eventArgs.fileData.statusCode = '5';\n eventArgs.fileData.status = this.localizedTexts('fileUploadCancel');\n var liElement = this.getLiElement(eventArgs.fileData);\n if (liElement) {\n if (!isNullOrUndefined(liElement.querySelector('.' + STATUS))) {\n liElement.querySelector('.' + STATUS).innerHTML = this.localizedTexts('fileUploadCancel');\n liElement.querySelector('.' + STATUS).classList.add(UPLOAD_FAILED);\n }\n this.pauseButton = this.createElement('span', { className: 'e-icons e-file-reload-btn', attrs: { 'tabindex': this.btnTabIndex } });\n var removeIcon = liElement.querySelector('.' + REMOVE_ICON);\n if (removeIcon) {\n removeIcon.parentElement.insertBefore(this.pauseButton, removeIcon);\n }\n this.pauseButton.setAttribute('title', this.localizedTexts('retry'));\n /* istanbul ignore next */\n this.pauseButton.addEventListener('click', function (e) {\n _this.reloadcanceledFile(e, file, liElement);\n }, false);\n this.checkActionButtonStatus();\n }\n };\n Uploader.prototype.checkChunkUpload = function () {\n return (this.asyncSettings.chunkSize <= 0 || isNullOrUndefined(this.asyncSettings.chunkSize)) ? false : true;\n };\n Uploader.prototype.chunkUploadComplete = function (e, metaData, custom) {\n var _this = this;\n var response = e.target;\n var liElement;\n if (response.readyState === 4 && response.status >= 200 && response.status < 300) {\n var requestResponse = e && e.currentTarget ? this.getResponse(e) : null;\n var totalChunk = Math.max(Math.ceil(metaData.file.size / this.asyncSettings.chunkSize), 1);\n var eventArgs = {\n event: e,\n file: metaData.file,\n chunkIndex: metaData.chunkIndex,\n totalChunk: totalChunk,\n chunkSize: this.asyncSettings.chunkSize,\n response: requestResponse\n };\n this.trigger('chunkSuccess', eventArgs);\n if (isNullOrUndefined(custom) || !custom) {\n liElement = this.getLiElement(metaData.file);\n }\n this.updateMetaData(metaData);\n if (metaData.end === metaData.file.size) {\n metaData.file.statusCode = '3';\n }\n if (metaData.file.statusCode === '5') {\n var eventArgs_1 = { event: e, fileData: metaData.file, cancel: false, customFormData: [] };\n this.trigger('canceling', eventArgs_1, function (eventArgs) {\n /* istanbul ignore next */\n if (eventArgs.cancel) {\n metaData.file.statusCode = '3';\n var spinnerTarget = liElement.querySelector('.' + ABORT_ICON);\n if (!isNullOrUndefined(liElement) && !isNullOrUndefined(spinnerTarget)) {\n hideSpinner(spinnerTarget);\n detach(liElement.querySelector('.e-spinner-pane'));\n }\n _this.sendNextRequest(metaData);\n }\n else {\n metaData.request.emitError = false;\n response.abort();\n var formData = new FormData();\n var name_2 = _this.element.getAttribute('name');\n formData.append(name_2, metaData.file.name);\n formData.append('cancel-uploading', metaData.file.name);\n formData.append('cancelUploading', metaData.file.name);\n _this.updateFormData(formData, eventArgs.customFormData);\n var ajax = new Ajax(_this.asyncSettings.removeUrl, 'POST', true, null);\n ajax.emitError = false;\n ajax.onLoad = function (e) {\n _this.removeChunkFile(e, metaData, custom);\n return {};\n };\n ajax.send(formData);\n }\n });\n }\n else {\n if ((totalChunk - 1) === metaData.chunkIndex && totalChunk > metaData.chunkIndex) {\n var index = this.pausedData.indexOf(metaData);\n if (index >= 0) {\n this.pausedData.splice(index, 1);\n }\n if (isNullOrUndefined(this.template) && (isNullOrUndefined(custom) || !custom) && liElement) {\n if (liElement && !isNullOrUndefined(liElement.querySelector('.' + PAUSE_UPLOAD))) {\n detach(liElement.querySelector('.' + PAUSE_UPLOAD));\n }\n this.removeChunkProgressBar(metaData);\n }\n this.raiseSuccessEvent(e, metaData.file);\n return;\n }\n if (metaData.file.statusCode !== '4') {\n this.sendNextRequest(metaData);\n }\n }\n }\n else {\n this.chunkUploadFailed(e, metaData);\n }\n };\n Uploader.prototype.sendNextRequest = function (metaData) {\n metaData.start = metaData.end;\n metaData.end += this.asyncSettings.chunkSize;\n metaData.end = Math.min(metaData.end, metaData.file.size);\n metaData.chunkIndex += 1;\n this.sendRequest(metaData.file, metaData);\n };\n Uploader.prototype.removeChunkFile = function (e, metaData, custom) {\n if (isNullOrUndefined(this.template) && (isNullOrUndefined(custom) && !custom)) {\n var liElement = this.getLiElement(metaData.file);\n var deleteIcon = liElement.querySelector('.' + ABORT_ICON);\n var spinnerTarget = deleteIcon;\n this.updateStatus(metaData.file, this.localizedTexts('fileUploadCancel'), '5');\n this.updateProgressBarClasses(liElement, UPLOAD_FAILED);\n this.removeProgressbar(liElement, 'failure');\n (deleteIcon && deleteIcon.classList.remove(ABORT_ICON));\n (deleteIcon && deleteIcon.classList.add(REMOVE_ICON));\n (deleteIcon && deleteIcon.setAttribute('title', this.localizedTexts('remove')));\n var pauseIcon = liElement.querySelector('.' + PAUSE_UPLOAD);\n (pauseIcon && pauseIcon.classList.add(RETRY_ICON));\n (pauseIcon && pauseIcon.classList.remove(PAUSE_UPLOAD));\n (pauseIcon && pauseIcon.setAttribute('title', this.localizedTexts('retry')));\n if (!isNullOrUndefined(liElement) && !isNullOrUndefined(deleteIcon)\n && !isNullOrUndefined(liElement.querySelector('.e-spinner-pane'))) {\n hideSpinner(spinnerTarget);\n detach(liElement.querySelector('.e-spinner-pane'));\n }\n }\n };\n Uploader.prototype.pauseUpload = function (metaData, e, custom) {\n metaData.file.statusCode = '4';\n metaData.file.status = this.localizedTexts('pause');\n this.updateMetaData(metaData);\n var eventArgs = {\n event: e ? e : null,\n file: metaData.file,\n chunkIndex: metaData.chunkIndex,\n chunkCount: Math.round(metaData.file.size / this.asyncSettings.chunkSize),\n chunkSize: this.asyncSettings.chunkSize\n };\n this.abortUpload(metaData, custom, eventArgs);\n };\n Uploader.prototype.abortUpload = function (metaData, custom, eventArgs) {\n if (metaData.file.statusCode !== '4') {\n metaData.request.emitError = false;\n metaData.request.httpRequest.abort();\n }\n var liElement = this.getLiElement(metaData.file);\n if (isNullOrUndefined(this.template) && (isNullOrUndefined(custom) || !custom)) {\n var targetElement = liElement.querySelector('.' + PAUSE_UPLOAD);\n targetElement.classList.remove(PAUSE_UPLOAD);\n targetElement.classList.add(RESUME_UPLOAD);\n targetElement.setAttribute('title', this.localizedTexts('resume'));\n targetElement.nextElementSibling.classList.add(REMOVE_ICON);\n targetElement.nextElementSibling.classList.remove(ABORT_ICON);\n targetElement.nextElementSibling.setAttribute('title', this.localizedTexts('remove'));\n }\n for (var i = 0; i < this.pausedData.length; i++) {\n if (this.pausedData[i].file.name === metaData.file.name) {\n this.pausedData.splice(i, 1);\n }\n }\n this.pausedData.push(metaData);\n this.trigger('pausing', eventArgs);\n };\n Uploader.prototype.resumeUpload = function (metaData, e, custom) {\n var liElement = this.getLiElement(metaData.file);\n var targetElement;\n if (!isNullOrUndefined(liElement)) {\n targetElement = liElement.querySelector('.' + RESUME_UPLOAD);\n }\n if (!isNullOrUndefined(targetElement) && (isNullOrUndefined(custom) || !custom)) {\n targetElement.classList.remove(RESUME_UPLOAD);\n targetElement.classList.add(PAUSE_UPLOAD);\n targetElement.setAttribute('title', this.localizedTexts('pause'));\n targetElement.nextElementSibling.classList.remove(REMOVE_ICON);\n targetElement.nextElementSibling.classList.add(ABORT_ICON);\n targetElement.nextElementSibling.setAttribute('title', this.localizedTexts('abort'));\n }\n metaData.file.status = this.localizedTexts('inProgress');\n metaData.file.statusCode = '3';\n this.updateMetaData(metaData);\n var eventArgs = {\n event: e ? e : null,\n file: metaData.file,\n chunkIndex: metaData.chunkIndex,\n chunkCount: Math.round(metaData.file.size / this.asyncSettings.chunkSize),\n chunkSize: this.asyncSettings.chunkSize\n };\n this.trigger('resuming', eventArgs);\n for (var i = 0; i < this.pausedData.length; i++) {\n if (this.pausedData[i].end === this.pausedData[i].file.size) {\n this.chunkUploadComplete(e, metaData, custom);\n }\n else {\n if (this.pausedData[i].file.name === metaData.file.name) {\n this.pausedData[i].start = this.pausedData[i].end;\n this.pausedData[i].end = this.pausedData[i].end + this.asyncSettings.chunkSize;\n this.pausedData[i].end = Math.min(this.pausedData[i].end, this.pausedData[i].file.size);\n this.pausedData[i].chunkIndex = this.pausedData[i].chunkIndex + 1;\n this.sendRequest(this.pausedData[i].file, this.pausedData[i], custom);\n }\n }\n }\n };\n Uploader.prototype.updateMetaData = function (metaData) {\n if (this.uploadMetaData.indexOf(metaData) === -1) {\n this.uploadMetaData.push(metaData);\n }\n else {\n this.uploadMetaData.splice(this.uploadMetaData.indexOf(metaData), 1);\n this.uploadMetaData.push(metaData);\n }\n };\n Uploader.prototype.removeChunkProgressBar = function (metaData) {\n var liElement = this.getLiElement(metaData.file);\n if (!isNullOrUndefined(liElement)) {\n this.updateProgressBarClasses(liElement, UPLOAD_SUCCESS);\n this.removeProgressbar(liElement, 'success');\n var cancelButton = liElement.querySelector('.' + ABORT_ICON);\n if (!isNullOrUndefined(cancelButton)) {\n cancelButton.classList.add(DELETE_ICON);\n cancelButton.setAttribute('title', this.localizedTexts('delete'));\n cancelButton.classList.remove(ABORT_ICON, UPLOAD_INPROGRESS);\n }\n }\n };\n Uploader.prototype.chunkUploadFailed = function (e, metaData, custom) {\n var _this = this;\n var chunkCount = Math.max(Math.ceil(metaData.file.size / this.asyncSettings.chunkSize), 1);\n var liElement;\n if (isNullOrUndefined(this.template) && (isNullOrUndefined(custom) || !custom)) {\n liElement = this.getLiElement(metaData.file);\n }\n var requestResponse = e && e.currentTarget ? this.getResponse(e) : null;\n var eventArgs = {\n event: e,\n file: metaData.file,\n chunkIndex: metaData.chunkIndex,\n totalChunk: chunkCount,\n chunkSize: this.asyncSettings.chunkSize,\n cancel: false,\n response: requestResponse\n };\n this.trigger('chunkFailure', eventArgs, function (eventArgs) {\n // To prevent triggering of failure event\n if (!eventArgs.cancel) {\n if (metaData.retryCount < _this.asyncSettings.retryCount) {\n setTimeout(function () {\n _this.retryRequest(liElement, metaData, custom);\n }, _this.asyncSettings.retryAfterDelay);\n }\n else {\n if (!isNullOrUndefined(liElement)) {\n var pauseButton = liElement.querySelector('.' + PAUSE_UPLOAD) ?\n liElement.querySelector('.' + PAUSE_UPLOAD) : liElement.querySelector('.' + RESUME_UPLOAD);\n if (!isNullOrUndefined(pauseButton)) {\n pauseButton.classList.add(RETRY_ICON);\n pauseButton.classList.remove(PAUSE_UPLOAD, RESUME_UPLOAD);\n }\n _this.updateProgressBarClasses(liElement, UPLOAD_FAILED);\n _this.removeProgressbar(liElement, 'failure');\n liElement.querySelector('.e-icons').classList.remove(UPLOAD_INPROGRESS);\n var iconElement = liElement.querySelector('.' + ABORT_ICON) ?\n liElement.querySelector('.' + ABORT_ICON) : liElement.querySelector('.' + REMOVE_ICON);\n iconElement.classList.remove(ABORT_ICON);\n if (!isNullOrUndefined(liElement.querySelector('.' + PAUSE_UPLOAD))) {\n detach(liElement.querySelector('.' + PAUSE_UPLOAD));\n }\n if (metaData.start > 0) {\n iconElement.classList.add(DELETE_ICON);\n iconElement.setAttribute('title', _this.localizedTexts('delete'));\n }\n else {\n iconElement.classList.add(REMOVE_ICON);\n iconElement.setAttribute('title', _this.localizedTexts('remove'));\n }\n }\n metaData.retryCount = 0;\n var file_1 = metaData.file;\n var failureMessage = _this.localizedTexts('uploadFailedMessage');\n var args = {\n e: e, response: requestResponse,\n operation: 'upload',\n file: _this.updateStatus(file_1, failureMessage, '0', false),\n statusText: failureMessage\n };\n _this.trigger('failure', args, function (args) {\n _this.updateStatus(file_1, args.statusText, '0');\n _this.uploadSequential();\n _this.checkActionComplete(true);\n });\n }\n }\n });\n };\n Uploader.prototype.retryRequest = function (liElement, metaData, custom) {\n if (isNullOrUndefined(this.template) && (isNullOrUndefined(custom) || !custom) && liElement) {\n this.updateProgressBarClasses(liElement, UPLOAD_FAILED);\n }\n metaData.retryCount += 1;\n this.sendRequest(metaData.file, metaData);\n };\n Uploader.prototype.checkPausePlayAction = function (e) {\n var targetElement = e.target;\n var selectedElement = e.target.parentElement;\n var index = this.fileList.indexOf(selectedElement);\n var fileData = this.filesData[index];\n var metaData = this.getCurrentMetaData(fileData);\n if (targetElement.classList.contains(PAUSE_UPLOAD)) {\n /* istanbul ignore next */\n this.pauseUpload(metaData, e);\n }\n else if (targetElement.classList.contains(RESUME_UPLOAD)) {\n /* istanbul ignore next */\n this.resumeUpload(metaData, e);\n }\n else if (targetElement.classList.contains(RETRY_ICON)) {\n if (metaData.file.status === this.localizedTexts('fileUploadCancel')) {\n this.retryUpload(metaData, false);\n }\n else {\n this.retryUpload(metaData, true);\n }\n }\n };\n Uploader.prototype.retryUpload = function (metaData, fromcanceledStage) {\n if (fromcanceledStage) {\n metaData.end = metaData.end + this.asyncSettings.chunkSize;\n metaData.start = metaData.start + this.asyncSettings.chunkSize;\n this.sendRequest(metaData.file, metaData);\n }\n else {\n metaData.file.statusCode = '1';\n metaData.file.status = this.localizedTexts('readyToUploadMessage');\n this.chunkUpload(metaData.file);\n }\n /* istanbul ignore next */\n (this.getLiElement(metaData.file)).classList.add(RESTRICT_RETRY);\n };\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n Uploader.prototype.chunkUploadInProgress = function (e, metaData, custom) {\n var _this = this;\n if (metaData.file.statusCode === '4') {\n return;\n }\n if (metaData.file.statusCode !== '4' && metaData.file.statusCode !== '5') {\n metaData.file.statusCode = '3';\n metaData.file.status = this.localizedTexts('inProgress');\n }\n this.updateMetaData(metaData);\n var liElement = this.getLiElement(metaData.file);\n if (isNullOrUndefined(liElement)) {\n return;\n }\n var retryElement = liElement.querySelector('.' + RETRY_ICON);\n if (!isNullOrUndefined(retryElement)) {\n retryElement.classList.add(PAUSE_UPLOAD);\n retryElement.setAttribute('title', this.localizedTexts('pause'));\n retryElement.classList.remove(RETRY_ICON);\n }\n if (!isNullOrUndefined(liElement)) {\n if (!(liElement.querySelectorAll('.' + PROGRESS_WRAPPER).length > 0)) {\n var statusElement = liElement.querySelector('.' + STATUS);\n if (isNullOrUndefined(this.template)) {\n statusElement.classList.add(UPLOAD_INPROGRESS);\n statusElement.classList.remove(UPLOAD_FAILED);\n this.createProgressBar(liElement);\n this.updateProgressBarClasses(liElement, UPLOAD_INPROGRESS);\n }\n var clearIcon = liElement.querySelector('.' + REMOVE_ICON) ? liElement.querySelector('.' + REMOVE_ICON) :\n liElement.querySelector('.' + DELETE_ICON);\n if (!isNullOrUndefined(clearIcon)) {\n clearIcon.classList.add(ABORT_ICON);\n clearIcon.setAttribute('title', this.localizedTexts('abort'));\n clearIcon.classList.remove(REMOVE_ICON);\n }\n }\n if (!isNaN(Math.round((e.loaded / e.total) * 100)) && isNullOrUndefined(this.template) && metaData.file.statusCode !== '4') {\n var progressVal = void 0;\n var totalChunks = Math.ceil(metaData.file.size / this.asyncSettings.chunkSize) - 1;\n if (this.asyncSettings.chunkSize && totalChunks) {\n progressVal = Math.round(metaData.chunkIndex / totalChunks * 100);\n this.changeProgressValue(liElement, progressVal.toString() + '%');\n }\n }\n if (metaData.chunkIndex === 0) {\n this.checkActionButtonStatus();\n }\n }\n if (isNullOrUndefined(liElement.querySelector('.' + PAUSE_UPLOAD)) && isNullOrUndefined(this.template)\n && isNullOrUndefined(liElement.querySelector('.' + DELETE_ICON))) {\n this.pauseButton = this.createElement('span', { className: 'e-icons e-file-pause-btn', attrs: { 'tabindex': this.btnTabIndex } });\n if (this.browserName === 'msie') {\n this.pauseButton.classList.add('e-msie');\n }\n var abortIcon = liElement.querySelector('.' + ABORT_ICON);\n abortIcon.parentElement.insertBefore(this.pauseButton, abortIcon);\n this.pauseButton.setAttribute('title', this.localizedTexts('pause'));\n this.pauseButton.addEventListener('click', function (e) {\n _this.checkPausePlayAction(e);\n }, false);\n }\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * It is used to convert bytes value into kilobytes or megabytes depending on the size based\n * on [binary prefix](https://en.wikipedia.org/wiki/Binary_prefix).\n *\n * @param { number } bytes - Specifies the file size in bytes.\n * @returns {string}\n */\n Uploader.prototype.bytesToSize = function (bytes) {\n var i = -1;\n if (!bytes) {\n return '0.0 KB';\n }\n do {\n bytes = bytes / 1024;\n i++;\n } while (bytes > 99);\n if (i >= 2) {\n bytes = bytes * 1024;\n i = 1;\n }\n return Math.max(bytes, 0).toFixed(1) + ' ' + ['KB', 'MB'][i];\n };\n /**\n * Allows you to sort the file data alphabetically based on its file name clearly.\n *\n * @param { FileList } filesData - specifies the files data for upload.\n * @returns {File[]}\n */\n /* istanbul ignore next */\n Uploader.prototype.sortFileList = function (filesData) {\n filesData = filesData ? filesData : this.sortFilesList;\n var files = filesData;\n var fileNames = [];\n for (var i = 0; i < files.length; i++) {\n fileNames.push(files[i].name);\n }\n var sortedFileNames = fileNames.sort();\n var sortedFilesData = [];\n for (var _i = 0, sortedFileNames_1 = sortedFileNames; _i < sortedFileNames_1.length; _i++) {\n var name_3 = sortedFileNames_1[_i];\n for (var i = 0; i < files.length; i++) {\n if (name_3 === files[i].name) {\n sortedFilesData.push(files[i]);\n }\n }\n }\n return sortedFilesData;\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Removes the component from the DOM and detaches all its related event handlers. Also it removes the attributes and classes.\n *\n * @method destroy\n * @returns {void}\n */\n Uploader.prototype.destroy = function () {\n this.element.value = null;\n this.clearTemplate();\n this.clearAll();\n this.unWireEvents();\n this.unBindDropEvents();\n if (this.multiple) {\n this.element.removeAttribute('multiple');\n }\n if (!this.enabled) {\n this.element.removeAttribute('disabled');\n }\n this.element.removeAttribute('accept');\n this.setInitialAttributes();\n var attributes = ['aria-label', 'directory', 'webkitdirectory', 'tabindex'];\n for (var _i = 0, attributes_2 = attributes; _i < attributes_2.length; _i++) {\n var key = attributes_2[_i];\n this.element.removeAttribute(key);\n }\n if (!isNullOrUndefined(this.uploadWrapper)) {\n this.uploadWrapper.parentElement.appendChild(this.element);\n detach(this.uploadWrapper);\n }\n this.uploadWrapper = null;\n this.uploadWrapper = null;\n this.browseButton = null;\n this.dropAreaWrapper = null;\n this.dropZoneElement = null;\n this.dropArea = null;\n this.keyboardModule = null;\n this.clearButton = null;\n this.uploadButton = null;\n _super.prototype.destroy.call(this);\n };\n /**\n * Allows you to call the upload process manually by calling save URL action.\n * To process the selected files (added in upload queue), pass an empty argument otherwise\n * upload the specific file based on its argument.\n *\n * @param { FileInfo | FileInfo[] } files - Specifies the files data for upload.\n * @param {boolean} custom - Specifies whether the uploader is rendered with custom file list.\n * @returns {void}\n */\n Uploader.prototype.upload = function (files, custom) {\n var _this = this;\n files = files ? files : this.filesData;\n if (this.sequentialUpload && (this.isFirstFileOnSelection || custom)) {\n this.sequenceUpload(files);\n }\n else {\n var uploadFiles_1 = this.getFilesInArray(files);\n var eventArgs = {\n customFormData: [],\n currentRequest: null,\n cancel: false\n };\n this.trigger('beforeUpload', eventArgs, function (eventArgs) {\n if (!eventArgs.cancel) {\n _this.uploadFiles(uploadFiles_1, custom);\n }\n });\n }\n };\n Uploader.prototype.getFilesInArray = function (files) {\n var uploadFiles = [];\n if (files instanceof Array) {\n uploadFiles = files;\n }\n else {\n uploadFiles.push(files);\n }\n return uploadFiles;\n };\n /* istanbul ignore next */\n Uploader.prototype.serverReadFileBase64 = function (fileIndex, position, totalCount) {\n var _this = this;\n return new Promise(function (resolve, reject) {\n var file = _this.fileStreams[fileIndex].rawFile;\n try {\n var reader = new FileReader();\n reader.onload = (function (args) {\n return function () {\n try {\n var contents = args.result;\n var data = contents ? contents.split(';base64,')[1] : null;\n resolve(data);\n }\n catch (e) {\n reject(e);\n }\n };\n })(reader);\n reader.readAsDataURL(file.slice(position, position + totalCount));\n }\n catch (e) {\n reject(e);\n }\n });\n };\n /* eslint-disable @typescript-eslint/no-unused-vars */\n /* istanbul ignore next */\n Uploader.prototype.uploadFileCount = function (ele) {\n /* eslint-enable @typescript-eslint/no-unused-vars */\n var files = this.filesData;\n if (!files || files.length === 0) {\n return -1;\n }\n var result = files.length;\n return result;\n };\n /* eslint-disable @typescript-eslint/no-unused-vars */\n /* istanbul ignore next */\n Uploader.prototype.getFileRead = function (index, ele) {\n /* eslint-enable @typescript-eslint/no-unused-vars */\n var files = this.filesData;\n if (!files || files.length === 0) {\n return -1;\n }\n var file = files[index];\n var fileCount = this.newFileRef++;\n this.fileStreams[fileCount] = file;\n return fileCount;\n };\n /* eslint-disable @typescript-eslint/no-unused-vars */\n /* istanbul ignore next */\n Uploader.prototype.getFileInfo = function (index, ele) {\n /* eslint-enable @typescript-eslint/no-unused-vars */\n var files = this.filesData;\n if (!files || files.length === 0) {\n return null;\n }\n var file = files[index];\n if (!file) {\n return null;\n }\n return this.filesData[index];\n };\n Uploader.prototype.uploadFiles = function (files, custom) {\n var selectedFiles = [];\n if (this.asyncSettings.saveUrl === '' || isNullOrUndefined(this.asyncSettings.saveUrl)) {\n return;\n }\n if (!custom || isNullOrUndefined(custom)) {\n if (!this.multiple) {\n var file = [];\n file.push(files[0]);\n selectedFiles = this.filterfileList(file);\n }\n else {\n selectedFiles = this.filterfileList(files);\n }\n }\n else {\n selectedFiles = files;\n }\n for (var i = 0; i < selectedFiles.length; i++) {\n this.uploadFilesRequest(selectedFiles, i, custom);\n }\n };\n Uploader.prototype.uploadFilesRequest = function (selectedFiles, i, custom) {\n var _this = this;\n var cloneFiles = [];\n var chunkEnabled = this.checkChunkUpload();\n var ajax = new Ajax(this.asyncSettings.saveUrl, 'POST', true, null);\n ajax.emitError = false;\n var getFileData;\n var eventArgs = {\n fileData: selectedFiles[i],\n customFormData: [],\n cancel: false\n };\n var formData = new FormData();\n ajax.beforeSend = function (e) {\n eventArgs.currentRequest = ajax.httpRequest;\n _this.trigger('uploading', eventArgs, function (eventArgs) {\n /* istanbul ignore next */\n if (eventArgs.cancel) {\n _this.eventCancelByArgs(e, eventArgs, selectedFiles[i]);\n }\n _this.updateFormData(formData, eventArgs.customFormData);\n });\n };\n if (selectedFiles[i].statusCode === '1') {\n var name_4 = this.element.getAttribute('name');\n formData.append(name_4, selectedFiles[i].rawFile, selectedFiles[i].name);\n if (chunkEnabled && selectedFiles[i].size > this.asyncSettings.chunkSize) {\n this.chunkUpload(selectedFiles[i], custom, i);\n }\n else {\n ajax.onLoad = function (e) {\n if (eventArgs.cancel) {\n return {};\n }\n else {\n _this.uploadComplete(e, selectedFiles[i], custom);\n return {};\n }\n };\n ajax.onUploadProgress = function (e) {\n if (eventArgs.cancel) {\n return {};\n }\n else {\n _this.uploadInProgress(e, selectedFiles[i], custom, ajax);\n return {};\n }\n };\n /* istanbul ignore next */\n ajax.onError = function (e) {\n _this.uploadFailed(e, selectedFiles[i]);\n return {};\n };\n ajax.send(formData);\n }\n }\n };\n Uploader.prototype.spliceFiles = function (liIndex) {\n var liElement = this.fileList[liIndex];\n var allFiles = this.getFilesData();\n var nameElements = +liElement.getAttribute('data-files-count');\n var startIndex = 0;\n for (var i = 0; i < liIndex; i++) {\n startIndex += (+this.fileList[i].getAttribute('data-files-count'));\n }\n var endIndex = (startIndex + nameElements) - 1;\n for (var j = endIndex; j >= startIndex; j--) {\n allFiles.splice(j, 1);\n }\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-param */\n /**\n * Remove the uploaded file from server manually by calling the remove URL action.\n * If you pass an empty argument to this method, the complete file list can be cleared,\n * otherwise remove the specific file based on its argument (“file_dataâ€).\n *\n * @param { FileInfo | FileInfo[] } fileData - specifies the files data to remove from file list/server.\n * @param { boolean } customTemplate - Set true if the component rendering with customize template.\n * @param { boolean } removeDirectly - Set true if files remove without removing event.\n * @param { boolean } postRawFile - Set false, to post file name only to the remove action.\n * @returns {void}\n */\n Uploader.prototype.remove = function (fileData, customTemplate, removeDirectly, postRawFile, args) {\n var _this = this;\n if (isNullOrUndefined(postRawFile)) {\n postRawFile = true;\n }\n var eventArgs = {\n event: args,\n cancel: false,\n filesData: [],\n customFormData: [],\n postRawFile: postRawFile,\n currentRequest: null\n };\n var beforeEventArgs = {\n cancel: false,\n customFormData: [],\n currentRequest: null\n };\n this.trigger('beforeRemove', beforeEventArgs, function (beforeEventArgs) {\n if (!beforeEventArgs.cancel) {\n if (_this.isFormUpload()) {\n eventArgs.filesData = fileData;\n _this.trigger('removing', eventArgs, function (eventArgs) {\n if (!eventArgs.cancel) {\n var removingFiles = _this.getFilesInArray(fileData);\n var isLiRemoved = false;\n var liIndex = void 0;\n for (var _i = 0, removingFiles_1 = removingFiles; _i < removingFiles_1.length; _i++) {\n var data = removingFiles_1[_i];\n if (!isLiRemoved) {\n liIndex = _this.fileList.indexOf(data.list);\n }\n if (liIndex > -1) {\n var inputElement = !isNullOrUndefined(data.input) ? data.input : null;\n if (inputElement) {\n detach(inputElement);\n }\n _this.spliceFiles(liIndex);\n detach(_this.fileList[liIndex]);\n _this.fileList.splice(liIndex, 1);\n isLiRemoved = true;\n liIndex = -1;\n }\n }\n }\n });\n }\n else if (_this.isForm && (isNullOrUndefined(_this.asyncSettings.removeUrl) || _this.asyncSettings.removeUrl === '')) {\n eventArgs.filesData = _this.getFilesData();\n _this.trigger('removing', eventArgs, function (eventArgs) {\n if (!eventArgs.cancel) {\n _this.clearAll();\n }\n });\n }\n else {\n var removeFiles = [];\n fileData = !isNullOrUndefined(fileData) ? fileData : _this.filesData;\n if (fileData instanceof Array) {\n removeFiles = fileData;\n }\n else {\n removeFiles.push(fileData);\n }\n eventArgs.filesData = removeFiles;\n var removeUrl = _this.asyncSettings.removeUrl;\n var validUrl = (removeUrl === '' || isNullOrUndefined(removeUrl)) ? false : true;\n var _loop_5 = function (files) {\n var fileUploadedIndex = _this.uploadedFilesData.indexOf(files);\n if ((files.statusCode === '2' || files.statusCode === '4' || (files.statusCode === '0' &&\n fileUploadedIndex !== -1)) && validUrl) {\n _this.removeUploadedFile(files, eventArgs, removeDirectly, customTemplate);\n }\n else {\n if (!removeDirectly) {\n _this.trigger('removing', eventArgs, function (eventArgs) {\n if (!eventArgs.cancel) {\n _this.removeFilesData(files, customTemplate);\n }\n });\n }\n else {\n _this.removeFilesData(files, customTemplate);\n }\n }\n if (args && !args.target.classList.contains(REMOVE_ICON)) {\n _this.checkActionComplete(false);\n }\n };\n for (var _i = 0, removeFiles_1 = removeFiles; _i < removeFiles_1.length; _i++) {\n var files = removeFiles_1[_i];\n _loop_5(files);\n }\n }\n }\n });\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-param */\n /**\n * Clear all the file entries from list that can be uploaded files or added in upload queue.\n *\n * @returns {void}\n */\n Uploader.prototype.clearAll = function () {\n var _this = this;\n if (isNullOrUndefined(this.listParent)) {\n if (this.browserName !== 'msie') {\n this.element.value = '';\n }\n this.filesData = [];\n return;\n }\n var eventArgs = {\n cancel: false,\n filesData: this.filesData\n };\n this.trigger('clearing', eventArgs, function (eventArgs) {\n if (!eventArgs.cancel) {\n _this.clearData();\n _this.actionCompleteCount = 0;\n _this.count = -1;\n }\n });\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Get the data of files which are shown in file list.\n *\n * @param { number } index - specifies the file list item(li) index.\n * @returns {FileInfo[]}\n */\n Uploader.prototype.getFilesData = function (index) {\n if (isNullOrUndefined(index)) {\n return this.filesData;\n }\n else {\n return this.getSelectedFiles(index);\n }\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns-description */\n /**\n * Pauses the in-progress chunked upload based on the file data.\n *\n * @param { FileInfo | FileInfo[] } fileData - specifies the files data to pause from uploading.\n * @param { boolean } custom - Set true if used custom UI.\n * @returns {void}\n */\n Uploader.prototype.pause = function (fileData, custom) {\n fileData = fileData ? fileData : this.filesData;\n var fileDataFiles = this.getFilesInArray(fileData);\n this.pauseUploading(fileDataFiles, custom);\n };\n Uploader.prototype.pauseUploading = function (fileData, custom) {\n var files = this.getFiles(fileData);\n for (var i = 0; i < files.length; i++) {\n if (files[i].statusCode === '3') {\n this.pauseUpload(this.getCurrentMetaData(files[i], null), null, custom);\n }\n }\n };\n Uploader.prototype.getFiles = function (fileData) {\n var files = [];\n if (!isNullOrUndefined(fileData) && !(fileData instanceof Array)) {\n files.push(fileData);\n }\n else {\n files = fileData;\n }\n return files;\n };\n /**\n * Resumes the chunked upload that is previously paused based on the file data.\n *\n * @param { FileInfo | FileInfo[] } fileData - specifies the files data to resume the paused file.\n * @param { boolean } custom - Set true if used custom UI.\n * @returns {void}\n */\n Uploader.prototype.resume = function (fileData, custom) {\n fileData = fileData ? fileData : this.filesData;\n var fileDataFiles = this.getFilesInArray(fileData);\n this.resumeFiles(fileDataFiles, custom);\n };\n Uploader.prototype.resumeFiles = function (fileData, custom) {\n var files = this.getFiles(fileData);\n for (var i = 0; i < files.length; i++) {\n if (files[i].statusCode === '4') {\n this.resumeUpload(this.getCurrentMetaData(files[i], null), null, custom);\n }\n }\n };\n /**\n * Retries the canceled or failed file upload based on the file data.\n *\n * @param { FileInfo | FileInfo[] } fileData - specifies the files data to retry the canceled or failed file.\n * @param { boolean } fromcanceledStage - Set true to retry from canceled stage and set false to retry from initial stage.\n * @param {boolean} custom -Specifies whether the uploader is rendered with custom file list.\n * @returns {void}\n */\n Uploader.prototype.retry = function (fileData, fromcanceledStage, custom) {\n fileData = fileData ? fileData : this.filesData;\n var fileDataFiles = this.getFilesInArray(fileData);\n if (this.sequentialUpload && this.isFirstFileOnSelection) {\n this.isFirstFileOnSelection = false;\n }\n this.retryFailedFiles(fileDataFiles, fromcanceledStage, custom);\n };\n Uploader.prototype.retryFailedFiles = function (fileData, fromcanceledStage, custom) {\n var files = this.getFiles(fileData);\n for (var i = 0; i < files.length; i++) {\n if (files[i].statusCode === '5' || files[i].statusCode === '0') {\n if (this.asyncSettings.chunkSize > 0 && this.getCurrentMetaData(files[i], null)) {\n this.retryUpload(this.getCurrentMetaData(files[i], null), fromcanceledStage);\n }\n else {\n var liElement = void 0;\n if (!custom) {\n liElement = this.fileList[this.filesData.indexOf(files[i])];\n }\n this.reloadcanceledFile(null, files[i], liElement, custom);\n }\n }\n }\n };\n /**\n * Stops the in-progress chunked upload based on the file data.\n * When the file upload is canceled, the partially uploaded file is removed from server.\n *\n * @param { FileInfo | FileInfo[] } fileData - specifies the files data to cancel the progressing file.\n * @returns {void}\n */\n Uploader.prototype.cancel = function (fileData) {\n fileData = fileData ? fileData : this.filesData;\n var cancelingFiles = this.getFilesInArray(fileData);\n this.cancelUpload(cancelingFiles);\n };\n Uploader.prototype.cancelUpload = function (fileData) {\n var files = this.getFiles(fileData);\n if (this.asyncSettings.chunkSize > 0) {\n for (var i = 0; i < files.length; i++) {\n if (files[i].statusCode === '3') {\n var metaData = this.getCurrentMetaData(files[i], null);\n metaData.file.statusCode = '5';\n metaData.file.status = this.localizedTexts('fileUploadCancel');\n this.updateMetaData(metaData);\n this.showHideUploadSpinner(files[i]);\n }\n }\n }\n else {\n for (var i = 0; i < files.length; i++) {\n if (files[i].statusCode === '3') {\n files[i].statusCode = '5';\n files[i].status = this.localizedTexts('fileUploadCancel');\n this.showHideUploadSpinner(files[i]);\n }\n }\n }\n };\n Uploader.prototype.showHideUploadSpinner = function (files) {\n var liElement = this.getLiElement(files);\n if (!isNullOrUndefined(liElement) && isNullOrUndefined(this.template)) {\n var spinnerTarget = liElement.querySelector('.' + ABORT_ICON);\n createSpinner({ target: spinnerTarget, width: '20px' });\n showSpinner(spinnerTarget);\n }\n };\n __decorate([\n Complex({ saveUrl: '', removeUrl: '' }, AsyncSettings)\n ], Uploader.prototype, \"asyncSettings\", void 0);\n __decorate([\n Property(false)\n ], Uploader.prototype, \"sequentialUpload\", void 0);\n __decorate([\n Property({})\n ], Uploader.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property('')\n ], Uploader.prototype, \"cssClass\", void 0);\n __decorate([\n Property(true)\n ], Uploader.prototype, \"enabled\", void 0);\n __decorate([\n Property(null)\n ], Uploader.prototype, \"template\", void 0);\n __decorate([\n Property(true)\n ], Uploader.prototype, \"multiple\", void 0);\n __decorate([\n Property(true)\n ], Uploader.prototype, \"autoUpload\", void 0);\n __decorate([\n Property(true)\n ], Uploader.prototype, \"enableHtmlSanitizer\", void 0);\n __decorate([\n Complex({}, ButtonsProps)\n ], Uploader.prototype, \"buttons\", void 0);\n __decorate([\n Property('')\n ], Uploader.prototype, \"allowedExtensions\", void 0);\n __decorate([\n Property(0)\n ], Uploader.prototype, \"minFileSize\", void 0);\n __decorate([\n Property(30000000)\n ], Uploader.prototype, \"maxFileSize\", void 0);\n __decorate([\n Property(null)\n ], Uploader.prototype, \"dropArea\", void 0);\n __decorate([\n Collection([{}], FilesProp)\n ], Uploader.prototype, \"files\", void 0);\n __decorate([\n Property(true)\n ], Uploader.prototype, \"showFileList\", void 0);\n __decorate([\n Property(false)\n ], Uploader.prototype, \"directoryUpload\", void 0);\n __decorate([\n Property('Default')\n ], Uploader.prototype, \"dropEffect\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"actionComplete\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"rendering\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"beforeUpload\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"fileListRendering\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"selected\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"uploading\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"success\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"failure\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"removing\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"beforeRemove\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"clearing\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"progress\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"change\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"chunkSuccess\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"chunkFailure\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"chunkUploading\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"canceling\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"pausing\", void 0);\n __decorate([\n Event()\n ], Uploader.prototype, \"resuming\", void 0);\n Uploader = __decorate([\n NotifyPropertyChanges\n ], Uploader);\n return Uploader;\n}(Component));\nexport { Uploader };\n/* eslint-enable @typescript-eslint/no-explicit-any */\n","import { gh, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined } from '@syncfusion/ej2-base';\nexport var FilesDirective = vueDefineComponent({\n inject: { custom: { default: null } },\n render: function (createElement) {\n if (!isExecute) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('div', { class: 'e-directive' }, slots);\n }\n return;\n },\n updated: function () {\n if (!isExecute && this.custom) {\n this.custom();\n }\n },\n methods: {\n getTag: function () {\n return 'e-files';\n }\n }\n});\nexport var FilesPlugin = {\n name: 'e-files',\n install: function (Vue) {\n Vue.component(FilesPlugin.name, FilesDirective);\n }\n};\n/**\n * 'files' directive represent a file of vue uploader\n * It must be contained in a Uploader component(`ejs-uploader`).\n * ```html\n * <ejs-uploader id='fileupload' v-bind:multiple='true'>\n * <e-files>\n * <e-file name='Java' size=23000 type='pdf'></e-file>\n * <e-file name='C++' size=30000 type='.docx'></e-file>\n * </e-files>\n * </ejs-uploader>\n * ```\n */\nexport var UploadedFilesDirective = vueDefineComponent({\n render: function () {\n return;\n },\n methods: {\n getTag: function () {\n return 'e-uploadedfiles';\n }\n }\n});\nexport var UploadedFilesPlugin = {\n name: 'e-uploadedfiles',\n install: function (Vue) {\n Vue.component(UploadedFilesPlugin.name, UploadedFilesDirective);\n }\n};\n","import { ComponentBase, gh, getProps, isExecute, vueDefineComponent } from '@syncfusion/ej2-vue-base';\nimport { isNullOrUndefined, getValue } from '@syncfusion/ej2-base';\nimport { Uploader } from '@syncfusion/ej2-inputs';\nimport { FilesDirective, UploadedFilesDirective, FilesPlugin, UploadedFilesPlugin } from './files.directive';\nexport var properties = ['isLazyUpdate', 'plugins', 'allowedExtensions', 'asyncSettings', 'autoUpload', 'buttons', 'cssClass', 'directoryUpload', 'dropArea', 'dropEffect', 'enableHtmlSanitizer', 'enablePersistence', 'enableRtl', 'enabled', 'files', 'htmlAttributes', 'locale', 'maxFileSize', 'minFileSize', 'multiple', 'sequentialUpload', 'showFileList', 'template', 'actionComplete', 'beforeRemove', 'beforeUpload', 'canceling', 'change', 'chunkFailure', 'chunkSuccess', 'chunkUploading', 'clearing', 'created', 'failure', 'fileListRendering', 'pausing', 'progress', 'removing', 'rendering', 'resuming', 'selected', 'success', 'uploading'];\nexport var modelProps = [];\nexport var testProp = getProps({ props: properties });\nexport var props = testProp[0], watch = testProp[1], emitProbs = Object.keys(watch);\nemitProbs.push('modelchanged', 'update:modelValue');\nfor (var _i = 0, modelProps_1 = modelProps; _i < modelProps_1.length; _i++) {\n var props_1 = modelProps_1[_i];\n emitProbs.push('update:' + props_1);\n}\n/**\n * Represents the Essential JS 2 VueJS Uploader Component\n * ```html\n * <ejs-uploader id='fileUpload' v-bind:multiple='true'></ejs-uploader>\n * ```\n */\nexport var UploaderComponent = vueDefineComponent({\n name: 'UploaderComponent',\n mixins: [ComponentBase],\n props: props,\n watch: watch,\n emits: emitProbs,\n provide: function () { return { custom: this.custom }; },\n data: function () {\n return {\n ej2Instances: new Uploader({}),\n propKeys: properties,\n models: modelProps,\n hasChildDirective: true,\n hasInjectedModules: false,\n tagMapper: { \"e-files\": \"e-uploadedfiles\" },\n tagNameMapper: {},\n isVue3: !isExecute,\n templateCollection: {},\n };\n },\n created: function () {\n this.bindProperties();\n this.ej2Instances._setProperties = this.ej2Instances.setProperties;\n this.ej2Instances.setProperties = this.setProperties;\n this.ej2Instances.clearTemplate = this.clearTemplate;\n this.updated = this.updated;\n },\n render: function (createElement) {\n var h = !isExecute ? gh : createElement;\n var slots = null;\n if (!isNullOrUndefined(this.$slots.default)) {\n slots = !isExecute ? this.$slots.default() : this.$slots.default;\n }\n return h('input', slots);\n },\n methods: {\n clearTemplate: function (templateNames) {\n if (!templateNames) {\n templateNames = Object.keys(this.templateCollection || {});\n }\n if (templateNames.length && this.templateCollection) {\n for (var _i = 0, templateNames_1 = templateNames; _i < templateNames_1.length; _i++) {\n var tempName = templateNames_1[_i];\n var elementCollection = this.templateCollection[tempName];\n if (elementCollection && elementCollection.length) {\n for (var _a = 0, elementCollection_1 = elementCollection; _a < elementCollection_1.length; _a++) {\n var ele = elementCollection_1[_a];\n var destroy = getValue('__vue__.$destroy', ele);\n if (destroy) {\n ele.__vue__.$destroy();\n }\n if (ele.innerHTML) {\n ele.innerHTML = '';\n }\n }\n delete this.templateCollection[tempName];\n }\n }\n }\n },\n setProperties: function (prop, muteOnChange) {\n var _this = this;\n if (this.isVue3) {\n this.models = !this.models ? this.ej2Instances.referModels : this.models;\n }\n if (this.ej2Instances && this.ej2Instances._setProperties) {\n this.ej2Instances._setProperties(prop, muteOnChange);\n }\n if (prop && this.models && this.models.length) {\n Object.keys(prop).map(function (key) {\n _this.models.map(function (model) {\n if ((key === model) && !(/datasource/i.test(key))) {\n if (_this.isVue3) {\n _this.ej2Instances.vueInstance.$emit('update:' + key, prop[key]);\n }\n else {\n _this.$emit('update:' + key, prop[key]);\n _this.$emit('modelchanged', prop[key]);\n }\n }\n });\n });\n }\n },\n custom: function () {\n this.updated();\n },\n bytesToSize: function (bytes) {\n return this.ej2Instances.bytesToSize(bytes);\n },\n cancel: function (fileData) {\n return this.ej2Instances.cancel(fileData);\n },\n clearAll: function () {\n return this.ej2Instances.clearAll();\n },\n createFileList: function (fileData) {\n return this.ej2Instances.createFileList(fileData);\n },\n getFilesData: function (index) {\n return this.ej2Instances.getFilesData(index);\n },\n pause: function (fileData, custom) {\n return this.ej2Instances.pause(fileData, custom);\n },\n remove: function (fileData, customTemplate, removeDirectly, postRawFile, args) {\n return this.ej2Instances.remove(fileData, customTemplate, removeDirectly, postRawFile, args);\n },\n resume: function (fileData, custom) {\n return this.ej2Instances.resume(fileData, custom);\n },\n retry: function (fileData, fromcanceledStage, custom) {\n return this.ej2Instances.retry(fileData, fromcanceledStage, custom);\n },\n sortFileList: function (filesData) {\n return this.ej2Instances.sortFileList(filesData);\n },\n traverseFileTree: function (item, event) {\n return this.ej2Instances.traverseFileTree(item, event);\n },\n upload: function (files, custom) {\n return this.ej2Instances.upload(files, custom);\n },\n }\n});\nexport var UploaderPlugin = {\n name: 'ejs-uploader',\n install: function (Vue) {\n Vue.component(UploaderPlugin.name, UploaderComponent);\n Vue.component(UploadedFilesPlugin.name, UploadedFilesDirective);\n Vue.component(FilesPlugin.name, FilesDirective);\n }\n};\n","//! moment.js locale configuration\n//! locale : English (Ireland) [en-ie]\n//! author : Chris Cartlidge : https://github.com/chriscartlidge\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enIe = moment.defineLocale('en-ie', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return enIe;\n\n})));\n","import { Browser } from '@syncfusion/ej2-base';\nimport { extend, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { closest, classList } from '@syncfusion/ej2-base';\nimport { ResponsiveDialogAction } from '../base/enum';\nimport { setCssInGridPopUp, getActualPropFromColl, isActionPrevent, iterateExtend, parentsUntil } from '../base/util';\nimport { addRemoveEventListener } from '../base/util';\nimport * as events from '../base/constant';\nimport { AriaService } from '../services/aria-service';\nimport * as literals from '../base/string-literals';\n/**\n *\n * The `Sort` module is used to handle sorting action.\n */\nvar Sort = /** @class */ (function () {\n /**\n * Constructor for Grid sorting module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @param {SortSettings} sortSettings - specifies the SortSettings\n * @param {string[]} sortedColumns - specifies the string\n * @param {ServiceLocator} locator - specifies the ServiceLocator\n * @hidden\n */\n function Sort(parent, sortSettings, sortedColumns, locator) {\n this.contentRefresh = true;\n this.isModelChanged = true;\n this.aria = new AriaService();\n this.currentTarget = null;\n this.parent = parent;\n this.sortSettings = sortSettings;\n this.sortedColumns = sortedColumns;\n this.serviceLocator = locator;\n this.focus = locator.getService('focus');\n this.addEventListener();\n this.setFullScreenDialog();\n }\n /**\n * The function used to update sortSettings\n *\n * @returns {void}\n * @hidden\n */\n Sort.prototype.updateModel = function () {\n var sortedColumn = { field: this.columnName, direction: this.direction };\n var index;\n var gCols = this.parent.groupSettings.columns;\n var flag = false;\n if (!this.isMultiSort) {\n if (!gCols.length) {\n this.sortSettings.columns = [sortedColumn];\n }\n else {\n var sortedCols = [];\n for (var i = 0, len = gCols.length; i < len; i++) {\n index = this.getSortedColsIndexByField(gCols[parseInt(i.toString(), 10)], sortedCols);\n if (this.columnName === gCols[parseInt(i.toString(), 10)]) {\n flag = true;\n sortedCols.push(sortedColumn);\n }\n else {\n var sCol = this.getSortColumnFromField(gCols[parseInt(i.toString(), 10)]);\n sortedCols.push({ field: sCol.field, direction: sCol.direction, isFromGroup: sCol.isFromGroup });\n }\n }\n if (!flag) {\n sortedCols.push(sortedColumn);\n }\n this.sortSettings.columns = sortedCols;\n }\n }\n else {\n index = this.getSortedColsIndexByField(this.columnName);\n if (index > -1) {\n this.sortSettings.columns.splice(index, 1);\n }\n this.sortSettings.columns.push(sortedColumn);\n // eslint-disable-next-line no-self-assign\n this.sortSettings.columns = this.sortSettings.columns;\n }\n this.parent.dataBind();\n this.lastSortedCol = this.columnName;\n };\n /**\n * The function used to trigger onActionComplete\n *\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Sort.prototype.onActionComplete = function (e) {\n var args = !this.isRemove ? {\n columnName: this.columnName, direction: this.direction, requestType: 'sorting', type: events.actionComplete\n } : { requestType: 'sorting', type: events.actionComplete };\n this.isRemove = false;\n this.parent.trigger(events.actionComplete, extend(e, args));\n };\n /**\n * Sorts a column with the given options.\n *\n * @param {string} columnName - Defines the column name to sort.\n * @param {SortDirection} direction - Defines the direction of sorting field.\n * @param {boolean} isMultiSort - Specifies whether the previously sorted columns are to be maintained.\n * @returns {void}\n */\n Sort.prototype.sortColumn = function (columnName, direction, isMultiSort) {\n var gObj = this.parent;\n if (this.parent.getColumnByField(columnName).allowSorting === false || this.parent.isContextMenuOpen()) {\n this.parent.log('action_disabled_column', { moduleName: this.getModuleName(), columnName: columnName });\n return;\n }\n if (!gObj.allowMultiSorting) {\n isMultiSort = gObj.allowMultiSorting;\n }\n if (this.isActionPrevent()) {\n gObj.notify(events.preventBatch, {\n instance: this, handler: this.sortColumn,\n arg1: columnName, arg2: direction, arg3: isMultiSort\n });\n return;\n }\n this.backupSettings();\n this.columnName = columnName;\n this.direction = direction;\n this.isMultiSort = isMultiSort;\n this.removeSortIcons();\n this.updateSortedCols(columnName, isMultiSort);\n this.updateModel();\n };\n Sort.prototype.setFullScreenDialog = function () {\n if (this.serviceLocator) {\n this.serviceLocator.registerAdaptiveService(this, this.parent.enableAdaptiveUI, ResponsiveDialogAction.isSort);\n }\n };\n Sort.prototype.backupSettings = function () {\n this.lastSortedCols = iterateExtend(this.sortSettings.columns);\n this.lastCols = this.sortedColumns;\n };\n Sort.prototype.restoreSettings = function () {\n this.isModelChanged = false;\n this.isMultiSort = true;\n this.parent.setProperties({ sortSettings: { columns: this.lastSortedCols } }, true);\n //this.parent.sortSettings.columns = this.lastSortedCols;\n this.sortedColumns = this.lastCols;\n this.isModelChanged = true;\n };\n Sort.prototype.updateSortedCols = function (columnName, isMultiSort) {\n if (!isMultiSort) {\n if (this.parent.allowGrouping) {\n for (var i = 0, len = this.sortedColumns.length; i < len; i++) {\n if (this.parent.groupSettings.columns.indexOf(this.sortedColumns[parseInt(i.toString(), 10)]) < 0) {\n this.sortedColumns.splice(i, 1);\n len--;\n i--;\n }\n }\n }\n else {\n this.sortedColumns.splice(0, this.sortedColumns.length);\n }\n }\n if (this.sortedColumns.indexOf(columnName) < 0) {\n this.sortedColumns.push(columnName);\n }\n };\n /**\n * @param {NotifyArgs} e - specifies the NotifyArgs\n * @returns {void}\n * @hidden\n */\n Sort.prototype.onPropertyChanged = function (e) {\n if (e.module !== this.getModuleName()) {\n return;\n }\n if (this.contentRefresh) {\n var args = this.sortSettings.columns.length ? {\n columnName: this.columnName, direction: this.direction, requestType: 'sorting',\n type: events.actionBegin, target: this.currentTarget, cancel: false\n } : {\n requestType: 'sorting', type: events.actionBegin, cancel: false,\n target: this.currentTarget\n };\n this.parent.notify(events.modelChanged, args);\n }\n this.refreshSortSettings();\n this.removeSortIcons();\n this.addSortIcons();\n };\n Sort.prototype.refreshSortSettings = function () {\n this.sortedColumns.length = 0;\n var sortColumns = this.sortSettings.columns;\n for (var i = 0; i < sortColumns.length; i++) {\n if (!sortColumns[parseInt(i.toString(), 10)].isFromGroup) {\n this.sortedColumns.push(sortColumns[parseInt(i.toString(), 10)].field);\n }\n }\n };\n /**\n * Clears all the sorted columns of the Grid.\n *\n * @returns {void}\n */\n Sort.prototype.clearSorting = function () {\n var cols = getActualPropFromColl(this.sortSettings.columns);\n if (this.isActionPrevent()) {\n this.parent.notify(events.preventBatch, { instance: this, handler: this.clearSorting });\n return;\n }\n for (var i = 0, len = cols.length; i < len; i++) {\n this.removeSortColumn(cols[parseInt(i.toString(), 10)].field);\n }\n };\n Sort.prototype.isActionPrevent = function () {\n return isActionPrevent(this.parent);\n };\n /**\n * Remove sorted column by field name.\n *\n * @param {string} field - Defines the column field name to remove sort.\n * @returns {void}\n * @hidden\n */\n Sort.prototype.removeSortColumn = function (field) {\n var gObj = this.parent;\n var cols = this.sortSettings.columns;\n if (cols.length === 0 && this.sortedColumns.indexOf(field) < 0) {\n return;\n }\n if (this.isActionPrevent()) {\n this.parent.notify(events.preventBatch, { instance: this, handler: this.removeSortColumn, arg1: field });\n return;\n }\n this.backupSettings();\n this.removeSortIcons();\n var args = { requestType: 'sorting', type: events.actionBegin, target: this.currentTarget };\n for (var i = 0, len = cols.length; i < len; i++) {\n if (cols[parseInt(i.toString(), 10)].field === field) {\n if (gObj.allowGrouping && gObj.groupSettings.columns.indexOf(cols[parseInt(i.toString(), 10)].field) > -1) {\n continue;\n }\n this.sortedColumns.splice(this.sortedColumns.indexOf(cols[parseInt(i.toString(), 10)].field), 1);\n cols.splice(i, 1);\n this.isRemove = true;\n if (this.isModelChanged) {\n this.parent.notify(events.modelChanged, args);\n }\n break;\n }\n }\n if (!args.cancel) {\n this.addSortIcons();\n }\n };\n Sort.prototype.getSortedColsIndexByField = function (field, sortedColumns) {\n var cols = sortedColumns ? sortedColumns : this.sortSettings.columns;\n for (var i = 0, len = cols.length; i < len; i++) {\n if (cols[parseInt(i.toString(), 10)].field === field) {\n return i;\n }\n }\n return -1;\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Sort.prototype.getModuleName = function () {\n return 'sort';\n };\n Sort.prototype.initialEnd = function () {\n this.parent.off(events.contentReady, this.initialEnd);\n if (this.parent.getColumns().length && this.sortSettings.columns.length) {\n var gObj = this.parent;\n this.contentRefresh = false;\n this.isMultiSort = this.sortSettings.columns.length > 1;\n for (var _i = 0, _a = gObj.sortSettings.columns.slice(); _i < _a.length; _i++) {\n var col = _a[_i];\n if (this.sortedColumns.indexOf(col.field) > -1) {\n this.sortColumn(col.field, col.direction, true);\n }\n }\n this.isMultiSort = false;\n this.contentRefresh = true;\n }\n };\n /**\n * @returns {void}\n * @hidden\n */\n Sort.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.evtHandlers = [{ event: events.setFullScreenDialog, handler: this.setFullScreenDialog },\n { event: events.renderResponsiveChangeAction, handler: this.renderResponsiveChangeAction },\n { event: events.contentReady, handler: this.initialEnd },\n { event: events.sortComplete, handler: this.onActionComplete },\n { event: events.inBoundModelChanged, handler: this.onPropertyChanged },\n { event: events.click, handler: this.clickHandler },\n { event: events.headerRefreshed, handler: this.refreshSortIcons },\n { event: events.keyPressed, handler: this.keyPressed },\n { event: events.cancelBegin, handler: this.cancelBeginEvent },\n { event: events.destroy, handler: this.destroy }];\n addRemoveEventListener(this.parent, this.evtHandlers, true, this);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Sort.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n addRemoveEventListener(this.parent, this.evtHandlers, false);\n };\n /**\n * To destroy the sorting\n *\n * @returns {void}\n * @hidden\n */\n Sort.prototype.destroy = function () {\n this.isModelChanged = false;\n var gridElement = this.parent.element;\n if (!gridElement || (!gridElement.querySelector('.' + literals.gridHeader) && !gridElement.querySelector('.' + literals.gridContent))) {\n return;\n }\n if (this.parent.element.querySelector('.e-gridpopup').getElementsByClassName('e-sortdirect').length) {\n this.parent.element.querySelector('.e-gridpopup').style.display = 'none';\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (!this.parent.refreshing && (this.parent.isDestroyed || !this.parent.allowSorting)) {\n this.clearSorting();\n }\n this.isModelChanged = true;\n this.removeEventListener();\n };\n Sort.prototype.cancelBeginEvent = function (e) {\n if (e.requestType === 'sorting') {\n this.restoreSettings();\n this.refreshSortIcons();\n this.isMultiSort = true;\n }\n };\n Sort.prototype.clickHandler = function (e) {\n var gObj = this.parent;\n this.currentTarget = null;\n this.popUpClickHandler(e);\n var target = closest(e.target, '.e-headercell');\n if (target && !e.target.classList.contains('e-grptogglebtn') &&\n !(target.classList.contains('e-resized')) &&\n !e.target.classList.contains('e-rhandler') &&\n !e.target.classList.contains('e-columnmenu') &&\n !e.target.classList.contains('e-filtermenudiv') &&\n !parentsUntil(e.target, 'e-stackedheadercell') &&\n !(gObj.allowSelection && gObj.selectionSettings.allowColumnSelection &&\n e.target.classList.contains('e-headercell'))) {\n var gObj_1 = this.parent;\n var colObj = gObj_1.getColumnByUid(target.querySelector('.e-headercelldiv').getAttribute('e-mappinguid'));\n if (colObj.type !== 'checkbox') {\n this.initiateSort(target, e, colObj);\n if (Browser.isDevice) {\n this.showPopUp(e);\n }\n }\n }\n if (target) {\n target.classList.remove('e-resized');\n }\n if (parentsUntil(e.target, 'e-excel-ascending') ||\n parentsUntil(e.target, 'e-excel-descending')) {\n var colUid = closest(e.target, '.e-filter-popup').getAttribute('uid');\n var direction = isNullOrUndefined(parentsUntil(e.target, 'e-excel-descending')) ?\n 'Ascending' : 'Descending';\n this.sortColumn(gObj.getColumnByUid(colUid).field, direction, false);\n }\n };\n Sort.prototype.keyPressed = function (e) {\n var ele = e.target;\n if (!this.parent.isEdit && (e.action === 'enter' || e.action === 'ctrlEnter' || e.action === 'shiftEnter')\n && closest(ele, '.e-headercell')) {\n var target = this.focus.getFocusedElement();\n if (isNullOrUndefined(target) || !target.classList.contains('e-headercell')\n || !target.querySelector('.e-headercelldiv')) {\n return;\n }\n var col = this.parent.getColumnByUid(target.querySelector('.e-headercelldiv').getAttribute('e-mappinguid'));\n this.initiateSort(target, e, col);\n }\n };\n Sort.prototype.initiateSort = function (target, e, column) {\n var gObj = this.parent;\n var field = column.field;\n this.currentTarget = e.target;\n var direction = !target.getElementsByClassName('e-ascending').length ? 'Ascending' :\n 'Descending';\n this.isMultiSort = e.ctrlKey || this.enableSortMultiTouch ||\n (navigator.userAgent.indexOf('Mac OS') !== -1 && e.metaKey);\n if (e.shiftKey || (this.sortSettings.allowUnsort && target.getElementsByClassName('e-descending').length)\n && !(gObj.groupSettings.columns.indexOf(field) > -1)) {\n this.removeSortColumn(field);\n }\n else {\n this.sortColumn(field, direction, this.isMultiSort);\n }\n };\n Sort.prototype.showPopUp = function (e) {\n var target = closest(e.target, '.e-headercell');\n if (this.parent.allowMultiSorting && (!isNullOrUndefined(target) || this.parent.isContextMenuOpen())) {\n setCssInGridPopUp(this.parent.element.querySelector('.e-gridpopup'), e, 'e-sortdirect e-icons e-icon-sortdirect' + (this.sortedColumns.length > 1 ? ' e-spanclicked' : ''));\n }\n };\n Sort.prototype.popUpClickHandler = function (e) {\n var target = e.target;\n if (closest(target, '.e-headercell') || e.target.classList.contains(literals.rowCell) ||\n closest(target, '.e-gridpopup')) {\n if (target.classList.contains('e-sortdirect')) {\n if (!target.classList.contains('e-spanclicked')) {\n target.classList.add('e-spanclicked');\n this.enableSortMultiTouch = true;\n }\n else {\n target.classList.remove('e-spanclicked');\n this.enableSortMultiTouch = false;\n this.parent.element.querySelector('.e-gridpopup').style.display = 'none';\n }\n }\n }\n else {\n this.parent.element.querySelector('.e-gridpopup').style.display = 'none';\n }\n };\n Sort.prototype.addSortIcons = function () {\n var gObj = this.parent;\n var header;\n var filterElement;\n var cols = this.sortSettings.columns;\n var fieldNames = this.parent.getColumns().map(function (c) { return c.field; });\n for (var i = 0, len = cols.length; i < len; i++) {\n header = gObj.getColumnHeaderByField(cols[parseInt(i.toString(), 10)].field);\n if (fieldNames.indexOf(cols[parseInt(i.toString(), 10)].field) === -1 || isNullOrUndefined(header)) {\n continue;\n }\n this.aria.setSort(header, (cols[parseInt(i.toString(), 10)].direction).toLowerCase());\n if (cols.length > 1) {\n header.querySelector('.e-headercelldiv').insertBefore(this.parent.createElement('span', { className: 'e-sortnumber', innerHTML: (i + 1).toString() }), header.querySelector('.e-headertext'));\n }\n filterElement = header.querySelector('.e-sortfilterdiv');\n if (cols[parseInt(i.toString(), 10)].direction === 'Ascending') {\n classList(filterElement, ['e-ascending', 'e-icon-ascending'], []);\n }\n else {\n classList(filterElement, ['e-descending', 'e-icon-descending'], []);\n }\n }\n };\n Sort.prototype.removeSortIcons = function (position) {\n var gObj = this.parent;\n var header;\n var cols = this.sortSettings.columns;\n var fieldNames = this.parent.getColumns().map(function (c) { return c.field; });\n for (var i = position ? position : 0, len = !isNullOrUndefined(position) ? position + 1 : cols.length; i < len; i++) {\n header = gObj.getColumnHeaderByField(cols[parseInt(i.toString(), 10)].field);\n if (isNullOrUndefined(header) || (gObj.allowGrouping\n && gObj.groupSettings.columns.indexOf(cols[parseInt(i.toString(), 10)].field) > -1\n && !header.querySelector('.e-sortfilterdiv'))) {\n continue;\n }\n if (fieldNames.indexOf(cols[parseInt(i.toString(), 10)].field) === -1) {\n continue;\n }\n this.aria.setSort(header, 'none');\n classList(header.querySelector('.e-sortfilterdiv'), [], ['e-descending', 'e-icon-descending', 'e-ascending', 'e-icon-ascending']);\n if (header.querySelector('.e-sortnumber')) {\n header.querySelector('.e-headercelldiv').removeChild(header.querySelector('.e-sortnumber'));\n }\n }\n };\n Sort.prototype.getSortColumnFromField = function (field) {\n for (var i = 0, len = this.sortSettings.columns.length; i < len; i++) {\n if (this.sortSettings.columns[parseInt(i.toString(), 10)].field === field) {\n return this.sortSettings.columns[parseInt(i.toString(), 10)];\n }\n }\n return false;\n };\n Sort.prototype.updateAriaAttr = function () {\n var fieldNames = this.parent.getColumns().map(function (c) { return c.field; });\n for (var _i = 0, _a = this.sortedColumns; _i < _a.length; _i++) {\n var col = _a[_i];\n if (fieldNames.indexOf(col) === -1) {\n continue;\n }\n var header = this.parent.getColumnHeaderByField(col);\n this.aria.setSort(header, this.getSortColumnFromField(col).direction);\n }\n };\n Sort.prototype.refreshSortIcons = function () {\n this.removeSortIcons();\n this.isMultiSort = true;\n this.removeSortIcons();\n this.addSortIcons();\n this.isMultiSort = false;\n this.updateAriaAttr();\n };\n Sort.prototype.renderResponsiveChangeAction = function (args) {\n this.responsiveDialogRenderer.action = args.action;\n };\n /**\n * To show the responsive custom sort dialog\n *\n * @param {boolean} enable - specifes dialog open\n * @returns {void}\n * @hidden\n */\n Sort.prototype.showCustomSort = function (enable) {\n this.responsiveDialogRenderer.isCustomDialog = enable;\n this.responsiveDialogRenderer.showResponsiveDialog();\n };\n return Sort;\n}());\nexport { Sort };\n","//! moment.js locale configuration\n//! locale : Cambodian [km]\n//! author : Kruy Vanna : https://github.com/kruyvanna\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '១',\n 2: '២',\n 3: '៣',\n 4: '៤',\n 5: '៥',\n 6: '៦',\n 7: '៧',\n 8: '៨',\n 9: '៩',\n 0: '០',\n },\n numberMap = {\n '១': '1',\n '២': '2',\n '៣': '3',\n '៤': '4',\n '៥': '5',\n '៦': '6',\n '៧': '7',\n '៨': '8',\n '៩': '9',\n '០': '0',\n };\n\n var km = moment.defineLocale('km', {\n months: 'មករា_កុម្ភៈ_មីនា_មáŸážŸáž¶_ឧសភា_មិážáž»áž“ា_កក្កដា_សីហា_កញ្ញា_ážáž»áž›áž¶_វិច្ឆិកា_ធ្នូ'.split(\n '_'\n ),\n monthsShort:\n 'មករា_កុម្ភៈ_មីនា_មáŸážŸáž¶_ឧសភា_មិážáž»áž“ា_កក្កដា_សីហា_កញ្ញា_ážáž»áž›áž¶_វិច្ឆិកា_ធ្នូ'.split(\n '_'\n ),\n weekdays: 'អាទិážáŸ’áž™_áž…áŸáž“្ទ_អង្គារ_ពុធ_ព្រហស្បážáž·áŸ_សុក្រ_សៅរáŸ'.split('_'),\n weekdaysShort: 'អា_áž…_អ_áž–_ព្រ_សុ_ស'.split('_'),\n weekdaysMin: 'អា_áž…_អ_áž–_ព្រ_សុ_ស'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n meridiemParse: /ព្រឹក|ល្ងាច/,\n isPM: function (input) {\n return input === 'ល្ងាច';\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 12) {\n return 'ព្រឹក';\n } else {\n return 'ល្ងាច';\n }\n },\n calendar: {\n sameDay: '[ážáŸ’ងៃនáŸáŸ‡ ម៉ោង] LT',\n nextDay: '[ស្អែក ម៉ោង] LT',\n nextWeek: 'dddd [ម៉ោង] LT',\n lastDay: '[ម្សិលមិញ ម៉ោង] LT',\n lastWeek: 'dddd [សប្ážáž¶áž áŸáž˜áž»áž“] [ម៉ោង] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%sទៀáž',\n past: '%sមុន',\n s: 'ប៉ុន្មានវិនាទី',\n ss: '%d វិនាទី',\n m: 'មួយនាទី',\n mm: '%d នាទី',\n h: 'មួយម៉ោង',\n hh: '%d ម៉ោង',\n d: 'មួយážáŸ’ងៃ',\n dd: '%d ážáŸ’ងៃ',\n M: 'មួយážáŸ‚',\n MM: '%d ážáŸ‚',\n y: 'មួយឆ្នាំ',\n yy: '%d ឆ្នាំ',\n },\n dayOfMonthOrdinalParse: /ទី\\d{1,2}/,\n ordinal: 'ទី%d',\n preparse: function (string) {\n return string.replace(/[១២៣៤៥៦៧៨៩០]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return km;\n\n})));\n","/* eslint-disable jsdoc/require-returns */\n/**\n * Numeric Range.\n *\n * @private\n */\nvar DoubleRange = /** @class */ (function () {\n function DoubleRange(start, end) {\n /*\n if (!isNaN(start) && !isNaN(end)) {\n this.mIsEmpty = true;\n } else {\n this.mIsEmpty = false;\n }*/\n if (start < end) {\n this.mStart = start;\n this.mEnd = end;\n }\n else {\n this.mStart = end;\n this.mEnd = start;\n }\n }\n Object.defineProperty(DoubleRange.prototype, \"start\", {\n //private mIsEmpty: boolean;\n /** @private */\n get: function () {\n return this.mStart;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(DoubleRange.prototype, \"end\", {\n /** @private */\n get: function () {\n return this.mEnd;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(DoubleRange.prototype, \"delta\", {\n /*\n get isEmpty(): boolean {\n return this.mIsEmpty;\n }*/\n /** @private */\n get: function () {\n return (this.mEnd - this.mStart);\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(DoubleRange.prototype, \"median\", {\n /** @private */\n get: function () {\n return this.mStart + (this.mEnd - this.mStart) / 2;\n },\n enumerable: true,\n configurable: true\n });\n return DoubleRange;\n}());\nexport { DoubleRange };\n","import { merge } from '@syncfusion/ej2-base';\n/**\n * Row\n *\n * @hidden\n */\nvar Row = /** @class */ (function () {\n function Row(options, parent) {\n merge(this, options);\n this.parent = parent;\n }\n Row.prototype.clone = function () {\n var row = new Row({});\n merge(row, this);\n row.cells = this.cells.map(function (cell) { return cell.clone(); });\n return row;\n };\n /**\n * Replaces the row data and grid refresh the particular row element only.\n *\n * @param {Object} data - To update new data for the particular row.\n * @returns {void}\n */\n Row.prototype.setRowValue = function (data) {\n if (!this.parent) {\n return;\n }\n var key = this.data[this.parent.getPrimaryKeyFieldNames()[0]];\n this.parent.setRowData(key, data);\n };\n /**\n * Replaces the given field value and refresh the particular cell element only.\n *\n * @param {string} field - Specifies the field name which you want to update.\n * @param {string | number | boolean | Date} value - To update new value for the particular cell.\n * @returns {void}\n */\n Row.prototype.setCellValue = function (field, value) {\n if (!this.parent) {\n return;\n }\n var isValDiff = !(this.data[\"\" + field].toString() === value.toString());\n if (isValDiff) {\n var pKeyField = this.parent.getPrimaryKeyFieldNames()[0];\n var key = this.data[\"\" + pKeyField];\n this.parent.setCellValue(key, field, value);\n this.makechanges(pKeyField, this.data);\n }\n else {\n return;\n }\n };\n Row.prototype.makechanges = function (key, data) {\n if (!this.parent) {\n return;\n }\n var gObj = this.parent;\n var dataManager = gObj.getDataModule().dataManager;\n dataManager.update(key, data);\n };\n return Row;\n}());\nexport { Row };\n","//! moment.js locale configuration\n//! locale : Malay [ms]\n//! author : Weldan Jamili : https://github.com/weldan\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var ms = moment.defineLocale('ms', {\n months: 'Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis'.split('_'),\n weekdays: 'Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu'.split('_'),\n weekdaysShort: 'Ahd_Isn_Sel_Rab_Kha_Jum_Sab'.split('_'),\n weekdaysMin: 'Ah_Is_Sl_Rb_Km_Jm_Sb'.split('_'),\n longDateFormat: {\n LT: 'HH.mm',\n LTS: 'HH.mm.ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY [pukul] HH.mm',\n LLLL: 'dddd, D MMMM YYYY [pukul] HH.mm',\n },\n meridiemParse: /pagi|tengahari|petang|malam/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'pagi') {\n return hour;\n } else if (meridiem === 'tengahari') {\n return hour >= 11 ? hour : hour + 12;\n } else if (meridiem === 'petang' || meridiem === 'malam') {\n return hour + 12;\n }\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours < 11) {\n return 'pagi';\n } else if (hours < 15) {\n return 'tengahari';\n } else if (hours < 19) {\n return 'petang';\n } else {\n return 'malam';\n }\n },\n calendar: {\n sameDay: '[Hari ini pukul] LT',\n nextDay: '[Esok pukul] LT',\n nextWeek: 'dddd [pukul] LT',\n lastDay: '[Kelmarin pukul] LT',\n lastWeek: 'dddd [lepas pukul] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'dalam %s',\n past: '%s yang lepas',\n s: 'beberapa saat',\n ss: '%d saat',\n m: 'seminit',\n mm: '%d minit',\n h: 'sejam',\n hh: '%d jam',\n d: 'sehari',\n dd: '%d hari',\n M: 'sebulan',\n MM: '%d bulan',\n y: 'setahun',\n yy: '%d tahun',\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 7, // The week that contains Jan 7th is the first week of the year.\n },\n });\n\n return ms;\n\n})));\n","//! moment.js locale configuration\n//! locale : Estonian [et]\n//! author : Henry Kehlmann : https://github.com/madhenry\n//! improvements : Illimar Tambek : https://github.com/ragulka\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n function processRelativeTime(number, withoutSuffix, key, isFuture) {\n var format = {\n s: ['mõne sekundi', 'mõni sekund', 'paar sekundit'],\n ss: [number + 'sekundi', number + 'sekundit'],\n m: ['ühe minuti', 'üks minut'],\n mm: [number + ' minuti', number + ' minutit'],\n h: ['ühe tunni', 'tund aega', 'üks tund'],\n hh: [number + ' tunni', number + ' tundi'],\n d: ['ühe päeva', 'üks päev'],\n M: ['kuu aja', 'kuu aega', 'üks kuu'],\n MM: [number + ' kuu', number + ' kuud'],\n y: ['ühe aasta', 'aasta', 'üks aasta'],\n yy: [number + ' aasta', number + ' aastat'],\n };\n if (withoutSuffix) {\n return format[key][2] ? format[key][2] : format[key][1];\n }\n return isFuture ? format[key][0] : format[key][1];\n }\n\n var et = moment.defineLocale('et', {\n months: 'jaanuar_veebruar_märts_aprill_mai_juuni_juuli_august_september_oktoober_november_detsember'.split(\n '_'\n ),\n monthsShort:\n 'jaan_veebr_märts_apr_mai_juuni_juuli_aug_sept_okt_nov_dets'.split('_'),\n weekdays:\n 'pühapäev_esmaspäev_teisipäev_kolmapäev_neljapäev_reede_laupäev'.split(\n '_'\n ),\n weekdaysShort: 'P_E_T_K_N_R_L'.split('_'),\n weekdaysMin: 'P_E_T_K_N_R_L'.split('_'),\n longDateFormat: {\n LT: 'H:mm',\n LTS: 'H:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'D. MMMM YYYY',\n LLL: 'D. MMMM YYYY H:mm',\n LLLL: 'dddd, D. MMMM YYYY H:mm',\n },\n calendar: {\n sameDay: '[Täna,] LT',\n nextDay: '[Homme,] LT',\n nextWeek: '[Järgmine] dddd LT',\n lastDay: '[Eile,] LT',\n lastWeek: '[Eelmine] dddd LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s pärast',\n past: '%s tagasi',\n s: processRelativeTime,\n ss: processRelativeTime,\n m: processRelativeTime,\n mm: processRelativeTime,\n h: processRelativeTime,\n hh: processRelativeTime,\n d: processRelativeTime,\n dd: '%d päeva',\n M: processRelativeTime,\n MM: processRelativeTime,\n y: processRelativeTime,\n yy: processRelativeTime,\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return et;\n\n})));\n","//! moment.js locale configuration\n//! locale : English (India) [en-in]\n//! author : Jatin Agrawal : https://github.com/jatinag22\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var enIn = moment.defineLocale('en-in', {\n months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split(\n '_'\n ),\n monthsShort: 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(\n '_'\n ),\n weekdaysShort: 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n weekdaysMin: 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n longDateFormat: {\n LT: 'h:mm A',\n LTS: 'h:mm:ss A',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY h:mm A',\n LLLL: 'dddd, D MMMM YYYY h:mm A',\n },\n calendar: {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(st|nd|rd|th)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 1st is the first week of the year.\n },\n });\n\n return enIn;\n\n})));\n","//! moment.js locale configuration\n//! locale : Sinhalese [si]\n//! author : Sampath Sitinamaluwa : https://github.com/sampathsris\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n /*jshint -W100*/\n var si = moment.defineLocale('si', {\n months: 'ජනවà·à¶»à·’_පෙබරවà·à¶»à·’_මà·à¶»à·Šà¶à·”_අප්â€à¶»à·šà¶½à·Š_මà·à¶ºà·’_ජූනි_ජූලි_අගà·à·ƒà·Šà¶à·”_à·ƒà·à¶´à·Šà¶à·à¶¸à·Šà¶¶à¶»à·Š_ඔක්à¶à·à¶¶à¶»à·Š_නොවà·à¶¸à·Šà¶¶à¶»à·Š_දෙසà·à¶¸à·Šà¶¶à¶»à·Š'.split(\n '_'\n ),\n monthsShort: 'ජන_පෙබ_මà·à¶»à·Š_අප්_මà·à¶ºà·’_ජූනි_ජූලි_අගà·_à·ƒà·à¶´à·Š_ඔක්_නොවà·_දෙසà·'.split(\n '_'\n ),\n weekdays:\n 'ඉරිදà·_සඳුදà·_අඟහරුවà·à¶¯à·_බදà·à¶¯à·_බ්â€à¶»à·„ස්පà¶à·’න්දà·_සිකුරà·à¶¯à·_සෙනසුරà·à¶¯à·'.split(\n '_'\n ),\n weekdaysShort: 'ඉරි_සඳු_අඟ_බදà·_බ්â€à¶»à·„_සිකු_සෙන'.split('_'),\n weekdaysMin: 'ඉ_à·ƒ_අ_බ_බ්â€à¶»_සි_සෙ'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'a h:mm',\n LTS: 'a h:mm:ss',\n L: 'YYYY/MM/DD',\n LL: 'YYYY MMMM D',\n LLL: 'YYYY MMMM D, a h:mm',\n LLLL: 'YYYY MMMM D [à·€à·à¶±à·’] dddd, a h:mm:ss',\n },\n calendar: {\n sameDay: '[අද] LT[ට]',\n nextDay: '[හෙට] LT[ට]',\n nextWeek: 'dddd LT[ට]',\n lastDay: '[ඊයේ] LT[ට]',\n lastWeek: '[පසුගිය] dddd LT[ට]',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%sකින්',\n past: '%sකට පෙර',\n s: 'à¶à¶à·Šà¶´à¶» කිහිපය',\n ss: 'à¶à¶à·Šà¶´à¶» %d',\n m: 'මිනිà¶à·Šà¶à·”à·€',\n mm: 'මිනිà¶à·Šà¶à·” %d',\n h: 'පà·à¶º',\n hh: 'පà·à¶º %d',\n d: 'දිනය',\n dd: 'දින %d',\n M: 'මà·à·ƒà¶º',\n MM: 'මà·à·ƒ %d',\n y: 'වසර',\n yy: 'වසර %d',\n },\n dayOfMonthOrdinalParse: /\\d{1,2} à·€à·à¶±à·’/,\n ordinal: function (number) {\n return number + ' à·€à·à¶±à·’';\n },\n meridiemParse: /පෙර වරු|පස් වරු|පෙ.à·€|ප.à·€./,\n isPM: function (input) {\n return input === 'ප.à·€.' || input === 'පස් වරු';\n },\n meridiem: function (hours, minutes, isLower) {\n if (hours > 11) {\n return isLower ? 'ප.à·€.' : 'පස් වරු';\n } else {\n return isLower ? 'පෙ.à·€.' : 'පෙර වරු';\n }\n },\n });\n\n return si;\n\n})));\n","import { merge } from '@syncfusion/ej2-base';\n/**\n * Cell\n *\n * @hidden\n */\nvar Cell = /** @class */ (function () {\n function Cell(options) {\n this.isSpanned = false;\n this.isRowSpanned = false;\n merge(this, options);\n }\n Cell.prototype.clone = function () {\n var cell = new Cell({});\n merge(cell, this);\n return cell;\n };\n return Cell;\n}());\nexport { Cell };\n","import { EventHandler, detach, formatUnit, Browser, closest } from '@syncfusion/ej2-base';\nimport { Column } from '../models/column';\nimport { ColumnWidthService } from '../services/width-controller';\nimport * as events from '../base/constant';\nimport { getScrollBarWidth, parentsUntil, Global, frozenDirection, isChildColumn, applyStickyLeftRightPosition, groupCaptionRowLeftRightPos } from '../base/util';\nimport { isNullOrUndefined, addClass, removeClass } from '@syncfusion/ej2-base';\nimport * as literals from '../base/string-literals';\nexport var resizeClassList = {\n root: 'e-rhandler',\n suppress: 'e-rsuppress',\n icon: 'e-ricon',\n helper: 'e-rhelper',\n header: 'th.e-headercell',\n cursor: 'e-rcursor'\n};\n/**\n * `Resize` module is used to handle Resize to fit for columns.\n *\n * @hidden\n * @private\n */\nvar Resize = /** @class */ (function () {\n /**\n * Constructor for the Grid resize module\n *\n * @param {IGrid} parent - specifies the IGrid\n * @hidden\n */\n function Resize(parent) {\n this.tapped = false;\n this.isDblClk = true;\n /** @hidden */\n this.resizeProcess = false;\n this.parent = parent;\n if (this.parent.isDestroyed) {\n return;\n }\n this.widthService = new ColumnWidthService(parent);\n this.addEventListener();\n }\n /**\n * Resize by field names.\n *\n * @param {string|string[]} fName - Defines the field name.\n * @returns {void}\n */\n Resize.prototype.autoFitColumns = function (fName) {\n var columnName = (fName === undefined || fName === null || fName.length <= 0) ?\n this.parent.getColumns().map(function (x) { return x.field; }) : (typeof fName === 'string') ? [fName] : fName;\n this.parent.isAutoFitColumns = true;\n if (this.parent.enableAdaptiveUI) {\n this.parent.element.classList.add('e-grid-autofit');\n }\n this.findColumn(columnName);\n };\n Resize.prototype.autoFit = function () {\n var newarray = this.parent.getColumns().filter(function (c) { return c.autoFit === true; })\n .map(function (c) { return c.field || c.headerText; });\n if (newarray.length > 0) {\n this.autoFitColumns(newarray);\n }\n if (this.parent.resizeSettings.mode === 'Auto') {\n this.widthService.setWidthToTable();\n }\n };\n Resize.prototype.resizeColumn = function (fName, index, id) {\n var gObj = this.parent;\n var tWidth = 0;\n var headerTable = gObj.getHeaderTable();\n var contentTable = gObj.getContentTable();\n var footerTable;\n var headerDivTag = 'e-gridheader';\n var contentDivTag = literals.gridContent;\n var footerDivTag = literals.gridFooter;\n var indentWidth = 0;\n var uid = id ? id : this.parent.getUidByColumnField(fName);\n var columnIndex = this.parent.getNormalizedColumnIndex(uid);\n var headerTextClone = headerTable.querySelector('[e-mappinguid=\"' + uid + '\"]').parentElement.cloneNode(true);\n var contentTextClone = contentTable.querySelectorAll(\"td.e-rowcell:nth-child(\" + (columnIndex + 1) + \"):not(.e-groupcaption):not(.e-detailcell)\");\n var footerTextClone;\n var columnIndexByField = this.parent.getColumnIndexByField(fName);\n if (!isNullOrUndefined(gObj.getFooterContent())) {\n footerTable = gObj.getFooterContentTable();\n }\n if (footerTable) {\n footerTextClone = footerTable.querySelectorAll(\"td:nth-child(\" + (columnIndex + 1) + \"):not(.e-groupcaption)\");\n }\n var indentWidthClone = [].slice.call(headerTable.querySelector('tr').getElementsByClassName('e-grouptopleftcell'));\n if (indentWidthClone.length > 0) {\n for (var i = 0; i < indentWidthClone.length; i++) {\n indentWidth += indentWidthClone[parseInt(i.toString(), 10)].offsetWidth;\n }\n }\n var detailsElement = contentTable.querySelector('.e-detailrowcollapse') ||\n contentTable.querySelector('.e-detailrowexpand');\n if ((this.parent.detailTemplate || this.parent.childGrid) && detailsElement) {\n indentWidth += detailsElement.offsetWidth;\n }\n var headerText = [headerTextClone];\n var contentText = [];\n var footerText = [];\n if (footerTable) {\n for (var i = 0; i < footerTextClone.length; i++) {\n footerText[parseInt(i.toString(), 10)] = footerTextClone[parseInt(i.toString(), 10)].cloneNode(true);\n }\n }\n for (var i = 0; i < contentTextClone.length; i++) {\n contentText[parseInt(i.toString(), 10)] = contentTextClone[parseInt(i.toString(), 10)].cloneNode(true);\n }\n var wHeader = this.createTable(headerTable, headerText, headerDivTag);\n var wFooter = null;\n var wContent = null;\n if (gObj.getCurrentViewRecords().length) {\n wContent = this.createTable(contentTable, contentText, contentDivTag);\n }\n if (footerText.length) {\n wFooter = this.createTable(footerTable, footerText, footerDivTag);\n }\n var columnbyindex = gObj.getColumns()[parseInt(columnIndexByField.toString(), 10)];\n var width = columnbyindex.width = formatUnit(Math.max(wHeader, wContent, wFooter));\n var colMaxWidth = columnbyindex.maxWidth && parseFloat(columnbyindex.maxWidth.toString());\n if (parseInt(width, 10) > colMaxWidth) {\n columnbyindex.width = colMaxWidth;\n }\n this.widthService.setColumnWidth(gObj.getColumns()[parseInt(columnIndexByField.toString(), 10)]);\n var result = gObj.getColumns().some(function (x) { return x.width === null\n || x.width === undefined || x.width.length <= 0; });\n if (result === false) {\n var element = gObj.getColumns();\n for (var i = 0; i < element.length; i++) {\n if (element[parseInt(i.toString(), 10)].visible) {\n tWidth = tWidth + parseFloat(element[parseInt(i.toString(), 10)].width);\n }\n }\n }\n var calcTableWidth = tWidth + indentWidth;\n if (tWidth > 0) {\n if (this.parent.detailTemplate || this.parent.childGrid) {\n this.widthService.setColumnWidth(new Column({ width: '30px' }));\n }\n if (this.parent.resizeSettings.mode === 'Auto') {\n calcTableWidth = '100%';\n }\n headerTable.style.width = formatUnit(calcTableWidth);\n contentTable.style.width = formatUnit(calcTableWidth);\n if (!isNullOrUndefined(footerTable)) {\n footerTable.style.width = formatUnit(calcTableWidth);\n }\n }\n if (gObj.isFrozenGrid() && gObj.enableColumnVirtualization) {\n this.widthService.refreshFrozenScrollbar();\n }\n var tableWidth = headerTable.offsetWidth;\n var contentwidth = (gObj.getContent().scrollWidth);\n if (contentwidth > tableWidth) {\n if (!isNullOrUndefined(contentTable.querySelector('.e-emptyrow'))) {\n addClass([headerTable], ['e-tableborder']);\n removeClass([contentTable], ['e-tableborder']);\n }\n else {\n addClass([headerTable, contentTable], ['e-tableborder']);\n }\n }\n else {\n removeClass([headerTable, contentTable], ['e-tableborder']);\n }\n if (!isNullOrUndefined(footerTable)) {\n footerTable.classList.add('e-tableborder');\n }\n };\n /**\n * To destroy the resize\n *\n * @returns {void}\n * @hidden\n */\n Resize.prototype.destroy = function () {\n var gridElement = this.parent.element;\n if (!gridElement || (!gridElement.querySelector('.' + literals.gridHeader) && !gridElement.querySelector('.' + literals.gridContent))) {\n return;\n }\n this.widthService = null;\n this.unwireEvents();\n this.removeEventListener();\n };\n /**\n * For internal use only - Get the module name.\n *\n * @returns {string} returns the module name\n * @private\n */\n Resize.prototype.getModuleName = function () {\n return 'resize';\n };\n Resize.prototype.findColumn = function (fName) {\n for (var i = 0; i < fName.length; i++) {\n var fieldName = fName[parseInt(i.toString(), 10)];\n var columnIndex = this.parent.getColumnIndexByField(fieldName);\n var column = this.parent.getColumns()[parseInt(columnIndex.toString(), 10)];\n if (columnIndex > -1 && !isNullOrUndefined(column) && column.visible === true) {\n this.resizeColumn(fieldName, columnIndex);\n }\n }\n if (this.parent.allowTextWrap) {\n this.parent.notify(events.freezeRender, { case: 'refreshHeight', isModeChg: true });\n }\n if (this.parent.isFrozenGrid()) {\n this.refreshResizefrzCols(true, true);\n }\n };\n /**\n * To create table for autofit\n *\n * @param {Element} table - specifies the table\n * @param {Element[]} text - specifies the text\n * @param {string} tag - specifies the tag name\n * @returns {number} returns the number\n * @hidden\n */\n Resize.prototype.createTable = function (table, text, tag) {\n var myTableDiv = this.parent.createElement('div');\n var adaptiveClass = this.parent.enableAdaptiveUI ? ' e-bigger' : '';\n myTableDiv.className = this.parent.element.className + adaptiveClass;\n myTableDiv.style.cssText = 'display: inline-block;visibility:hidden;position:absolute';\n var mySubDiv = this.parent.createElement('div');\n mySubDiv.className = tag;\n var myTable = this.parent.createElement('table', { attrs: { role: 'grid' } });\n myTable.className = table.className;\n myTable.classList.add('e-resizetable');\n myTable.style.cssText = 'table-layout: auto;width: auto';\n var myTr = this.parent.createElement('tr');\n for (var i = 0; i < text.length; i++) {\n var tr = myTr.cloneNode();\n tr.className = table.querySelector('tr').className;\n tr.appendChild(text[parseInt(i.toString(), 10)]);\n myTable.appendChild(tr);\n }\n mySubDiv.appendChild(myTable);\n myTableDiv.appendChild(mySubDiv);\n document.body.appendChild(myTableDiv);\n var offsetWidthValue = myTable.getBoundingClientRect().width;\n document.body.removeChild(myTableDiv);\n return Math.ceil(offsetWidthValue);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Resize.prototype.addEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.on(events.headerRefreshed, this.refreshHeight, this);\n this.parent.on(events.refreshResizePosition, this.refreshResizePosition, this);\n this.parent.on(events.initialEnd, this.wireEvents, this);\n this.parent.on(events.contentReady, this.autoFit, this);\n this.parent.on(events.refreshHandlers, this.refreshHeight, this);\n this.parent.on(events.destroy, this.destroy, this);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Resize.prototype.removeEventListener = function () {\n if (this.parent.isDestroyed) {\n return;\n }\n this.parent.off(events.headerRefreshed, this.refreshHeight);\n this.parent.off(events.refreshResizePosition, this.refreshResizePosition);\n this.parent.off(events.initialEnd, this.wireEvents);\n this.parent.off(events.refreshHandlers, this.refreshHeight);\n this.parent.off(events.destroy, this.destroy);\n };\n /**\n * @returns {void}\n * @hidden\n */\n Resize.prototype.render = function () {\n this.unwireEvents();\n this.wireEvents();\n this.setHandlerHeight();\n };\n Resize.prototype.refreshHeight = function () {\n if (this.parent.getHeaderTable()) {\n var element = this.getResizeHandlers();\n for (var i = 0; i < element.length; i++) {\n if (element[parseInt(i.toString(), 10)].parentElement.offsetHeight > 0) {\n element[parseInt(i.toString(), 10)].style.height = element[parseInt(i.toString(), 10)].parentElement.offsetHeight + 'px';\n }\n }\n this.setHandlerHeight();\n }\n };\n Resize.prototype.wireEvents = function () {\n EventHandler.add(this.parent.getHeaderContent(), Browser.touchStartEvent, this.touchResizeStart, this);\n EventHandler.add(this.parent.getHeaderContent(), events.dblclick, this.callAutoFit, this);\n };\n Resize.prototype.unwireEvents = function () {\n EventHandler.remove(this.parent.getHeaderContent(), Browser.touchStartEvent, this.touchResizeStart);\n EventHandler.remove(this.parent.getHeaderContent(), events.dblclick, this.callAutoFit);\n };\n Resize.prototype.getResizeHandlers = function () {\n return [].slice.call(this.parent.getHeaderTable().getElementsByClassName(resizeClassList.root));\n };\n Resize.prototype.setHandlerHeight = function () {\n var element = [].slice.call(this.parent.getHeaderTable().getElementsByClassName(resizeClassList.suppress));\n for (var i = 0; i < element.length; i++) {\n element[parseInt(i.toString(), 10)].style.height = element[parseInt(i.toString(), 10)].parentElement.offsetHeight + 'px';\n }\n };\n Resize.prototype.callAutoFit = function (e) {\n if (e.target.classList.contains('e-rhandler')) {\n var col = this.getTargetColumn(e);\n if (col.columns) {\n return;\n }\n this.resizeColumn(col.field, this.parent.getNormalizedColumnIndex(col.uid), col.uid);\n var header = closest(e.target, resizeClassList.header);\n header.classList.add('e-resized');\n }\n };\n Resize.prototype.touchResizeStart = function (e) {\n if (!Global.timer) {\n Global.timer = setTimeout(function () {\n Global.timer = null;\n }, 300);\n return this.resizeStart(e);\n }\n else {\n clearTimeout(Global.timer);\n Global.timer = null;\n this.callAutoFit(e);\n }\n };\n Resize.prototype.resizeStart = function (e) {\n var _this = this;\n if (e.target.classList.contains('e-rhandler')) {\n if (!this.helper) {\n if (this.getScrollBarWidth() === 0) {\n this.resizeProcess = true;\n if (this.parent.allowGrouping) {\n for (var i = 0; i < this.parent.groupSettings.columns.length; i++) {\n this.widthService.setColumnWidth(new Column({ width: '30px' }), i);\n }\n }\n for (var _i = 0, _a = this.refreshColumnWidth(); _i < _a.length; _i++) {\n var col = _a[_i];\n this.widthService.setColumnWidth(col);\n }\n this.widthService.setWidthToTable();\n this.resizeProcess = false;\n }\n this.refreshStackedColumnWidth();\n this.element = e.target;\n this.parentElementWidth = this.parent.element.getBoundingClientRect().width;\n this.appendHelper();\n this.column = this.getTargetColumn(e);\n this.pageX = this.getPointX(e);\n if (this.column.getFreezeTableName() === literals.frozenRight) {\n if (this.parent.enableRtl) {\n this.minMove = (this.column.minWidth ? parseFloat(this.column.minWidth.toString()) : 0)\n - parseFloat(isNullOrUndefined(this.column.width) ? '' : this.column.width.toString());\n }\n else {\n this.minMove = parseFloat(isNullOrUndefined(this.column.width) ? '' : this.column.width.toString())\n - (this.column.minWidth ? parseFloat(this.column.minWidth.toString()) : 0);\n }\n }\n else if (this.parent.enableRtl) {\n this.minMove = parseFloat(this.column.width.toString())\n - (this.column.minWidth ? parseFloat(this.column.minWidth.toString()) : 0);\n }\n else {\n this.minMove = (this.column.minWidth ? parseFloat(this.column.minWidth.toString()) : 0)\n - parseFloat(isNullOrUndefined(this.column.width) ? '' : this.column.width.toString());\n }\n this.minMove += this.pageX;\n }\n if (Browser.isDevice && !this.helper.classList.contains(resizeClassList.icon)) {\n this.helper.classList.add(resizeClassList.icon);\n EventHandler.add(document, Browser.touchStartEvent, this.removeHelper, this);\n EventHandler.add(this.helper, Browser.touchStartEvent, this.resizeStart, this);\n }\n else {\n var args = { e: e, column: this.column };\n this.parent.trigger(events.resizeStart, args, function (args) {\n if (args.cancel || _this.parent.isEdit) {\n _this.cancelResizeAction();\n return;\n }\n EventHandler.add(document, Browser.touchEndEvent, _this.resizeEnd, _this);\n EventHandler.add(_this.parent.element, Browser.touchMoveEvent, _this.resizing, _this);\n _this.updateCursor('add');\n });\n }\n }\n };\n Resize.prototype.cancelResizeAction = function (removeEvents) {\n if (removeEvents) {\n EventHandler.remove(this.parent.element, Browser.touchMoveEvent, this.resizing);\n EventHandler.remove(document, Browser.touchEndEvent, this.resizeEnd);\n this.updateCursor('remove');\n }\n if (Browser.isDevice) {\n EventHandler.remove(document, Browser.touchStartEvent, this.removeHelper);\n EventHandler.remove(this.helper, Browser.touchStartEvent, this.resizeStart);\n }\n detach(this.helper);\n this.refresh();\n };\n Resize.prototype.getWidth = function (width, minWidth, maxWidth) {\n if (minWidth && width < minWidth) {\n return minWidth;\n }\n else if ((maxWidth && width > maxWidth)) {\n return maxWidth;\n }\n else {\n return width;\n }\n };\n Resize.prototype.updateResizeEleHeight = function () {\n var elements = [].slice.call(this.parent.getHeaderContent().getElementsByClassName('e-rhandler'));\n for (var i = 0; i < elements.length; i++) {\n elements[parseInt(i.toString(), 10)].style.height = this.element.parentElement.offsetHeight + 'px';\n }\n };\n Resize.prototype.getColData = function (column, mousemove) {\n return {\n width: parseFloat(isNullOrUndefined(this.widthService.getWidth(column)) || this.widthService.getWidth(column) === 'auto' ? '0'\n : this.widthService.getWidth(column).toString()) + mousemove,\n minWidth: column.minWidth ? parseFloat(column.minWidth.toString()) : null,\n maxWidth: column.maxWidth ? parseFloat(column.maxWidth.toString()) : null\n };\n };\n Resize.prototype.refreshResizeFixedCols = function (pos) {\n var cols = this.parent.getColumns();\n var translateX = this.parent.enableColumnVirtualization ? this.parent.translateX : 0;\n var th = [].slice.call(this.parent.getHeaderContent().querySelector('tbody').querySelectorAll('.e-fixedfreeze')).concat([].slice.call(this.parent.getContent().querySelectorAll('.e-fixedfreeze')));\n for (var i = 0; i < th.length; i++) {\n var node = th[parseInt(i.toString(), 10)];\n var column = void 0;\n if (node.classList.contains('e-summarycell')) {\n var uid = node.getAttribute('e-mappinguid');\n column = this.parent.getColumnByUid(uid);\n }\n else {\n var index = parseInt(node.getAttribute('data-colindex'), 10);\n column = cols[parseInt(index.toString(), 10)];\n }\n var width = 0;\n if (pos === 'Left') {\n if (this.parent.getVisibleFrozenLeftCount()) {\n width = this.parent.getIndentCount() * 30;\n }\n else if (this.parent.getFrozenMode() === 'Right') {\n width = this.parent.groupSettings.columns.length * 30;\n }\n for (var j = 0; j < cols.length; j++) {\n if (column.index > cols[parseInt(j.toString(), 10)].index) {\n if (column.uid === cols[parseInt(j.toString(), 10)].uid) {\n break;\n }\n if ((cols[parseInt(j.toString(), 10)].freeze === 'Left' || cols[parseInt(j.toString(), 10)].isFrozen) ||\n cols[parseInt(j.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(j.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(j.toString(), 10)].width.toString());\n }\n }\n }\n }\n applyStickyLeftRightPosition(node, ((width === 0 ? width : width - 1) - translateX), this.parent.enableRtl, 'Left');\n }\n if (pos === 'Right') {\n width = this.parent.getFrozenMode() === 'Right' && this.parent.isRowDragable() ? 30 : 0;\n for (var j = cols.length - 1; j >= 0; j--) {\n if (column.uid === cols[parseInt(j.toString(), 10)].uid) {\n break;\n }\n if (cols[parseInt(j.toString(), 10)].freeze === 'Right' || cols[parseInt(j.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(j.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(j.toString(), 10)].width.toString());\n }\n }\n }\n applyStickyLeftRightPosition(node, width + translateX, this.parent.enableRtl, 'Right');\n }\n }\n };\n Resize.prototype.refreshResizePosition = function () {\n this.refreshResizefrzCols(true);\n };\n Resize.prototype.refreshResizefrzCols = function (freezeRefresh, isAutoFitCol) {\n var _this = this;\n var translateX = this.parent.enableColumnVirtualization ? this.parent.translateX : 0;\n if (freezeRefresh || ((this.column.freeze === 'Left' || this.column.isFrozen) ||\n (this.column.columns && frozenDirection(this.column) === 'Left'))) {\n var width_1 = this.parent.getIndentCount() * 30;\n var columns = this.parent.getColumns().filter(function (col) { return col.freeze === 'Left' || col.isFrozen; });\n if (!freezeRefresh || isAutoFitCol) {\n this.frzHdrRefresh('Left');\n }\n for (var i = 0; i < columns.length; i++) {\n if (freezeRefresh || (columns[parseInt(i.toString(), 10)].index > this.column.index)) {\n var elements = [];\n if (this.parent.frozenRows) {\n elements = [].slice.call(this.parent.getHeaderContent().querySelectorAll('td[data-colindex=\"' + i + '\"]')).concat([].slice.call(this.parent.getContent().querySelectorAll('td[data-colindex=\"' + i + '\"]')));\n }\n else {\n elements = [].slice.call(this.parent.getContent().querySelectorAll('td[data-colindex=\"' + i + '\"]'));\n }\n elements.filter(function (cell) {\n applyStickyLeftRightPosition(cell, width_1 - translateX, _this.parent.enableRtl, 'Left');\n });\n if (this.parent.enableColumnVirtualization) {\n columns[parseInt(i.toString(), 10)].valueX = width_1;\n }\n }\n if (columns[parseInt(i.toString(), 10)].visible) {\n width_1 += parseFloat(columns[parseInt(i.toString(), 10)].width.toString());\n }\n }\n this.refreshResizeFixedCols('Left');\n }\n if (freezeRefresh || (this.column.freeze === 'Right' || (this.column.columns && frozenDirection(this.column) === 'Right'))) {\n var width_2 = this.parent.getFrozenMode() === 'Right' && this.parent.isRowDragable() ? 30 : 0;\n var columns = this.parent.getColumns();\n if (!freezeRefresh || isAutoFitCol) {\n this.frzHdrRefresh('Right');\n }\n var columnsRight = columns.filter(function (col) { return col.freeze === 'Right'; });\n for (var i = columns.length - 1; i >= columns.length - columnsRight.length; i--) {\n var elements = [];\n if (this.parent.frozenRows) {\n elements = [].slice.call(this.parent.getHeaderContent().querySelectorAll('td[data-colindex=\"' + i + '\"]')).concat([].slice.call(this.parent.getContent().querySelectorAll('td[data-colindex=\"' + i + '\"]')));\n }\n else {\n elements = [].slice.call(this.parent.getContent().querySelectorAll('td[data-colindex=\"' + i + '\"]'));\n }\n elements.filter(function (cell) {\n applyStickyLeftRightPosition(cell, width_2 + translateX, _this.parent.enableRtl, 'Right');\n });\n if (this.parent.enableColumnVirtualization) {\n columns[parseInt(i.toString(), 10)].valueX = width_2;\n }\n if (columns[parseInt(i.toString(), 10)].visible) {\n width_2 = width_2 + parseFloat(columns[parseInt(i.toString(), 10)].width.toString());\n }\n }\n this.refreshResizeFixedCols('Right');\n }\n if (this.column && (this.column.freeze === 'Fixed' || (this.column.columns && frozenDirection(this.column) === 'Fixed'))) {\n this.refreshResizeFixedCols('Left');\n this.refreshResizeFixedCols('Right');\n this.frzHdrRefresh('Left');\n this.frzHdrRefresh('Right');\n }\n if (this.parent.groupSettings.columns.length && this.parent.aggregates.length &&\n this.parent.getContent().querySelector('.e-groupcaptionrow')) {\n this.refreshGroupCaptionRow();\n }\n };\n Resize.prototype.refreshGroupCaptionRow = function () {\n var capRow = [].slice.call(this.parent.getContent().querySelectorAll('.e-groupcaptionrow'));\n for (var i = 0; i < capRow.length; i++) {\n var tr = capRow[parseInt(i.toString(), 10)];\n if (tr.querySelector('.e-summarycell')) {\n groupCaptionRowLeftRightPos(tr, this.parent);\n }\n }\n };\n Resize.prototype.frzHdrRefresh = function (pos) {\n var _this = this;\n var translateX = this.parent.enableColumnVirtualization ? this.parent.translateX : 0;\n if (pos === 'Left') {\n var tr = [].slice.call(this.parent.getHeaderContent().querySelector('thead').querySelectorAll('tr'));\n for (var i = 0; i < tr.length; i++) {\n var th = [].slice.call(tr[parseInt(i.toString(), 10)].querySelectorAll('.e-leftfreeze,.e-fixedfreeze'));\n var _loop_1 = function (j) {\n var node = th[parseInt(j.toString(), 10)];\n if (node.classList.contains('e-rowdragheader') || node.classList.contains('e-dragheadercell') ||\n node.classList.contains('e-grouptopleftcell')) {\n return \"continue\";\n }\n var column = this_1.getParticularCol(node);\n var cols = this_1.parent.getColumns();\n var width = 0;\n var summarycell = [];\n if (this_1.parent.aggregates.length && this_1.parent.getFooterContent()) {\n if (this_1.parent.getContent().querySelectorAll('.e-summaryrow').length) {\n var summaryRows = [].slice.call(this_1.parent.getContent().querySelectorAll('.e-summaryrow'));\n summaryRows.filter(function (row) {\n summarycell.push(row.querySelector('[e-mappinguid=\"' + column.uid + '\"]'));\n });\n }\n summarycell = summarycell.concat([].slice.call(this_1.parent.getFooterContent().querySelectorAll('[e-mappinguid=\"' + column.uid + '\"]')));\n }\n if (node.classList.contains('e-fixedfreeze')) {\n if (this_1.parent.getVisibleFrozenLeftCount()) {\n width = this_1.parent.getIndentCount() * 30;\n }\n else if (this_1.parent.getFrozenMode() === 'Right') {\n width = this_1.parent.groupSettings.columns.length * 30;\n }\n for (var w = 0; w < cols.length; w++) {\n if (column.index > cols[parseInt(w.toString(), 10)].index) {\n if (column.uid === cols[parseInt(w.toString(), 10)].uid) {\n break;\n }\n if ((cols[parseInt(w.toString(), 10)].freeze === 'Left' || cols[parseInt(w.toString(), 10)].isFrozen) ||\n cols[parseInt(w.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(w.toString(), 10)].visible) {\n width += parseInt(cols[parseInt(w.toString(), 10)].width.toString(), 10);\n }\n }\n }\n }\n if (summarycell && summarycell.length) {\n summarycell.filter(function (cell) {\n applyStickyLeftRightPosition(cell, width - translateX, _this.parent.enableRtl, 'Left');\n });\n }\n applyStickyLeftRightPosition(node, ((width === 0 ? width : width - 1) - translateX), this_1.parent.enableRtl, 'Left');\n }\n else {\n width = this_1.parent.getIndentCount() * 30;\n if (column.index === 0) {\n if (summarycell && summarycell.length) {\n summarycell.filter(function (cell) {\n applyStickyLeftRightPosition(cell, width - translateX, _this.parent.enableRtl, 'Left');\n });\n }\n applyStickyLeftRightPosition(node, width - translateX, this_1.parent.enableRtl, 'Left');\n if (this_1.parent.enableColumnVirtualization) {\n column.valueX = width;\n }\n }\n else {\n for (var k = 0; k < cols.length; k++) {\n if (column.index < cols[parseInt(k.toString(), 10)].index ||\n column.uid === cols[parseInt(k.toString(), 10)].uid) {\n break;\n }\n if (cols[parseInt(k.toString(), 10)].visible) {\n width += parseInt(cols[parseInt(k.toString(), 10)].width.toString(), 10);\n }\n }\n if (summarycell && summarycell.length) {\n summarycell.filter(function (cell) {\n applyStickyLeftRightPosition(cell, width - translateX, _this.parent.enableRtl, 'Left');\n });\n }\n applyStickyLeftRightPosition(node, width - translateX, this_1.parent.enableRtl, 'Left');\n if (this_1.parent.enableColumnVirtualization) {\n column.valueX = width;\n }\n }\n }\n };\n var this_1 = this;\n for (var j = 0; j < th.length; j++) {\n _loop_1(j);\n }\n }\n }\n if (pos === 'Right') {\n var tr = [].slice.call(this.parent.getHeaderContent().querySelector('thead').querySelectorAll('tr'));\n for (var i = 0; i < tr.length; i++) {\n var th = [].slice.call(tr[parseInt(i.toString(), 10)].querySelectorAll('.e-rightfreeze, .e-fixedfreeze'));\n var _loop_2 = function (j) {\n var node = th[parseInt(j.toString(), 10)];\n var column = this_2.getParticularCol(node);\n var cols = this_2.parent.getColumns();\n var width = 0;\n var summarycell = [];\n if (this_2.parent.aggregates.length && this_2.parent.getFooterContent()) {\n if (this_2.parent.getContent().querySelectorAll('.e-summaryrow').length) {\n var summaryRows = [].slice.call(this_2.parent.getContent().querySelectorAll('.e-summaryrow'));\n summaryRows.filter(function (row) {\n summarycell.push(row.querySelector('[e-mappinguid=\"' + column.uid + '\"]'));\n });\n }\n summarycell = summarycell.concat([].slice.call(this_2.parent.getFooterContent().querySelectorAll('[e-mappinguid=\"' + column.uid + '\"]')));\n }\n if (node.classList.contains('e-fixedfreeze')) {\n width = this_2.parent.getFrozenMode() === 'Right' && this_2.parent.isRowDragable() ? 30 : 0;\n for (var w = cols.length - 1; w >= 0; w--) {\n if (column.index < cols[parseInt(w.toString(), 10)].index) {\n if ((column.columns && isChildColumn(column, cols[parseInt(w.toString(), 10)].uid)) ||\n column.index > cols[parseInt(w.toString(), 10)].index) {\n break;\n }\n if (cols[parseInt(w.toString(), 10)].freeze === 'Right' ||\n cols[parseInt(w.toString(), 10)].freeze === 'Fixed') {\n if (cols[parseInt(w.toString(), 10)].visible) {\n width += parseFloat(cols[parseInt(w.toString(), 10)].width.toString());\n }\n }\n }\n }\n if (summarycell.length) {\n summarycell.filter(function (cell) {\n applyStickyLeftRightPosition(cell, width + translateX, _this.parent.enableRtl, 'Right');\n });\n }\n applyStickyLeftRightPosition(node, width + translateX, this_2.parent.enableRtl, 'Right');\n }\n else {\n width = this_2.parent.getFrozenMode() === 'Right' && this_2.parent.isRowDragable() ? 30 : 0;\n for (var k = cols.length - 1; k >= 0; k--) {\n if ((column.columns && isChildColumn(column, cols[parseInt(k.toString(), 10)].uid)) ||\n column.index > cols[parseInt(k.toString(), 10)].index ||\n column.uid === cols[parseInt(k.toString(), 10)].uid) {\n break;\n }\n if (cols[parseInt(k.toString(), 10)].visible) {\n width += parseInt(cols[parseInt(k.toString(), 10)].width.toString(), 10);\n }\n }\n if (summarycell.length) {\n summarycell.filter(function (cell) {\n applyStickyLeftRightPosition(cell, width + translateX, _this.parent.enableRtl, 'Right');\n });\n }\n applyStickyLeftRightPosition(node, width + translateX, this_2.parent.enableRtl, 'Right');\n if (this_2.parent.enableColumnVirtualization) {\n column.valueX = width;\n }\n }\n };\n var this_2 = this;\n for (var j = th.length - 1; j >= 0; j--) {\n _loop_2(j);\n }\n }\n }\n };\n Resize.prototype.getParticularCol = function (node) {\n var uid = node.classList.contains('e-filterbarcell') ? node.getAttribute('e-mappinguid') :\n node.querySelector('[e-mappinguid]').getAttribute('e-mappinguid');\n return this.parent.getColumnByUid(uid);\n };\n Resize.prototype.resizing = function (e) {\n if (isNullOrUndefined(this.column)) {\n return;\n }\n if (this.parent.isFrozenGrid()) {\n this.refreshResizefrzCols();\n }\n var offsetWidth = 0;\n if (isNullOrUndefined(this.column)) {\n offsetWidth = parentsUntil(this.element, 'th').offsetWidth;\n }\n if (this.parent.allowTextWrap) {\n this.updateResizeEleHeight();\n this.setHelperHeight();\n }\n var pageX = this.getPointX(e);\n var mousemove = this.parent.enableRtl ? -(pageX - this.pageX) : (pageX - this.pageX);\n var colData = this.getColData(this.column, mousemove);\n if (!colData.width) {\n colData.width = closest(this.element, 'th').offsetWidth;\n }\n var width = this.getWidth(colData.width, colData.minWidth, colData.maxWidth);\n this.parent.log('resize_min_max', { column: this.column, width: width });\n if (((!this.parent.enableRtl && this.minMove >= pageX) || (this.parent.enableRtl && this.minMove <= pageX))) {\n width = this.column.minWidth ? parseFloat(this.column.minWidth.toString()) : 10;\n this.pageX = pageX = this.minMove;\n }\n if (width !== parseFloat(isNullOrUndefined(this.column.width) || this.column.width === 'auto' ?\n offsetWidth.toString() : this.column.width.toString())) {\n this.pageX = pageX;\n this.column.width = formatUnit(width);\n var args = {\n e: e,\n column: this.column\n };\n this.parent.trigger(events.onResize, args);\n if (args.cancel) {\n this.cancelResizeAction(true);\n return;\n }\n var columns = [this.column];\n var finalColumns = [this.column];\n if (this.column.columns) {\n columns = this.getSubColumns(this.column, []);\n columns = this.calulateColumnsWidth(columns, false, mousemove);\n finalColumns = this.calulateColumnsWidth(columns, true, mousemove);\n }\n this.resizeProcess = true;\n for (var _i = 0, finalColumns_1 = finalColumns; _i < finalColumns_1.length; _i++) {\n var col = finalColumns_1[_i];\n this.widthService.setColumnWidth(col, null, 'resize');\n }\n this.resizeProcess = false;\n this.updateHelper();\n }\n this.isDblClk = false;\n };\n Resize.prototype.calulateColumnsWidth = function (columns, isUpdate, mousemove) {\n var finalColumns = [];\n for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {\n var col = columns_1[_i];\n var totalWidth = 0;\n for (var i = 0; i < columns.length; i++) {\n totalWidth += parseFloat(columns[parseInt(i.toString(), 10)].width.toString());\n }\n var colData = this.getColData(col, (parseFloat(col.width)) * mousemove / totalWidth);\n var colWidth = this.getWidth(colData.width, colData.minWidth, colData.maxWidth);\n if ((colWidth !== parseFloat(col.width.toString()))) {\n if (isUpdate) {\n col.width = formatUnit(colWidth < 1 ? 1 : colWidth);\n }\n finalColumns.push(col);\n }\n }\n return finalColumns;\n };\n Resize.prototype.getSubColumns = function (column, subColumns) {\n for (var _i = 0, _a = column.columns; _i < _a.length; _i++) {\n var col = _a[_i];\n if (col.visible !== false && col.allowResizing) {\n if (col.columns) {\n this.getSubColumns(col, subColumns);\n }\n else {\n subColumns.push(col);\n }\n }\n }\n return subColumns;\n };\n Resize.prototype.resizeEnd = function (e) {\n if (!this.helper || this.parent.isDestroyed) {\n return;\n }\n var gObj = this.parent;\n EventHandler.remove(this.parent.element, Browser.touchMoveEvent, this.resizing);\n EventHandler.remove(document, Browser.touchEndEvent, this.resizeEnd);\n this.updateCursor('remove');\n detach(this.helper);\n var args = { e: e, column: this.column };\n var content = this.parent.getContent().querySelector('.' + literals.content);\n var cTable = content;\n if (cTable.scrollHeight > cTable.clientHeight) {\n this.parent.scrollModule.setPadding();\n cTable.style.overflowY = 'scroll';\n }\n this.parent.trigger(events.resizeStop, args);\n closest(this.element, '.e-headercell').classList.add('e-resized');\n this.isFrozenColResized = false;\n if (this.parent.allowTextWrap) {\n this.updateResizeEleHeight();\n this.parent.notify(events.textWrapRefresh, { case: 'textwrap' });\n }\n var headerTable = gObj.getHeaderTable();\n var contentTable = gObj.getContentTable();\n var footerTable;\n if (!isNullOrUndefined(gObj.getFooterContent())) {\n footerTable = gObj.getFooterContentTable();\n }\n var tableWidth = headerTable.offsetWidth;\n var contentwidth = (gObj.getContent().scrollWidth);\n if (contentwidth > tableWidth) {\n if (!isNullOrUndefined(contentTable.querySelector('.e-emptyrow'))) {\n addClass([headerTable], ['e-tableborder']);\n removeClass([contentTable], ['e-tableborder']);\n }\n else {\n addClass([headerTable, contentTable], ['e-tableborder']);\n }\n }\n else {\n removeClass([headerTable, contentTable], ['e-tableborder']);\n }\n if (!isNullOrUndefined(footerTable)) {\n footerTable.classList.add('e-tableborder');\n }\n this.refresh();\n this.doubleTapEvent(e);\n this.isDblClk = true;\n };\n Resize.prototype.getPointX = function (e) {\n if (e.touches && e.touches.length) {\n return e.touches[0].pageX;\n }\n else {\n return e.pageX;\n }\n };\n Resize.prototype.refreshColumnWidth = function () {\n var columns = this.parent.getColumns();\n for (var _i = 0, _a = [].slice.apply(this.parent.getHeaderContent().querySelectorAll('th.e-headercell')); _i < _a.length; _i++) {\n var ele = _a[_i];\n for (var _b = 0, columns_2 = columns; _b < columns_2.length; _b++) {\n var column = columns_2[_b];\n if (ele.querySelector('[e-mappinguid]') &&\n ele.querySelector('[e-mappinguid]').getAttribute('e-mappinguid') === column.uid && column.visible) {\n column.width = ele.getBoundingClientRect().width;\n break;\n }\n }\n }\n return columns;\n };\n Resize.prototype.refreshStackedColumnWidth = function () {\n for (var _i = 0, _a = this.parent.getStackedColumns(this.parent.columns); _i < _a.length; _i++) {\n var stackedColumn = _a[_i];\n stackedColumn.width = this.getStackedWidth(stackedColumn, 0);\n }\n };\n Resize.prototype.getStackedWidth = function (column, width) {\n for (var _i = 0, _a = column.columns; _i < _a.length; _i++) {\n var col = _a[_i];\n if (col.visible !== false) {\n if (col.columns) {\n width = this.getStackedWidth(col, width);\n }\n else {\n width += parseFloat(col.width.toString());\n }\n }\n }\n return width;\n };\n Resize.prototype.getTargetColumn = function (e) {\n var cell = closest(e.target, resizeClassList.header);\n cell = cell.querySelector('.e-headercelldiv') || cell.querySelector('.e-stackedheadercelldiv');\n var uid = cell.getAttribute('e-mappinguid');\n return this.parent.getColumnByUid(uid);\n };\n Resize.prototype.updateCursor = function (action) {\n var headerRows = [].slice.call(this.parent.getHeaderContent().querySelectorAll('th'));\n headerRows.push(this.parent.element);\n for (var _i = 0, headerRows_1 = headerRows; _i < headerRows_1.length; _i++) {\n var row = headerRows_1[_i];\n row.classList[\"\" + action](resizeClassList.cursor);\n }\n };\n Resize.prototype.refresh = function () {\n this.column = null;\n this.pageX = null;\n this.element = null;\n this.helper = null;\n };\n Resize.prototype.appendHelper = function () {\n this.helper = this.parent.createElement('div', {\n className: resizeClassList.helper\n });\n this.parent.element.appendChild(this.helper);\n this.setHelperHeight();\n };\n Resize.prototype.setHelperHeight = function () {\n var height = this.parent.getContent().offsetHeight - this.getScrollBarWidth();\n var rect = closest(this.element, resizeClassList.header);\n var tr = [].slice.call(this.parent.getHeaderContent().querySelectorAll('tr'));\n for (var i = tr.indexOf(rect.parentElement); i < tr.length && i > -1; i++) {\n height += tr[parseInt(i.toString(), 10)].offsetHeight;\n }\n var pos = this.calcPos(rect);\n pos.left += (this.parent.enableRtl ? 0 - 1 : rect.offsetWidth - 2);\n this.helper.style.cssText = 'height: ' + height + 'px; top: ' + pos.top + 'px; left:' + Math.floor(pos.left) + 'px;';\n if (this.parent.enableVirtualization) {\n this.helper.classList.add('e-virtual-rhandler');\n }\n };\n Resize.prototype.getScrollBarWidth = function (height) {\n var ele = this.parent.getContent().firstChild;\n return (ele.scrollHeight > ele.clientHeight && height) ||\n ele.scrollWidth > ele.clientWidth ? getScrollBarWidth() : 0;\n };\n Resize.prototype.removeHelper = function (e) {\n var cls = e.target.classList;\n if (!(cls.contains(resizeClassList.root) || cls.contains(resizeClassList.icon)) && this.helper) {\n EventHandler.remove(document, Browser.touchStartEvent, this.removeHelper);\n EventHandler.remove(this.helper, Browser.touchStartEvent, this.resizeStart);\n detach(this.helper);\n this.refresh();\n }\n };\n Resize.prototype.updateHelper = function () {\n var rect = closest(this.element, resizeClassList.header);\n var left;\n left = Math.floor(this.calcPos(rect).left + (this.parent.enableRtl ? 0 - 1 : rect.offsetWidth - 2));\n var borderWidth = 2; // to maintain the helper inside of grid element.\n if (left > this.parentElementWidth) {\n left = this.parentElementWidth - borderWidth;\n }\n this.helper.style.left = left + 'px';\n };\n Resize.prototype.calcPos = function (elem) {\n var parentOffset = {\n top: 0,\n left: 0\n };\n var offset = elem.getBoundingClientRect();\n var doc = elem.ownerDocument;\n var offsetParent = parentsUntil(elem, 'e-grid') || doc.documentElement;\n while (offsetParent &&\n (offsetParent === doc.body || offsetParent === doc.documentElement) &&\n offsetParent.style.position === 'static') {\n offsetParent = offsetParent.parentNode;\n }\n if (offsetParent && offsetParent !== elem && offsetParent.nodeType === 1) {\n parentOffset = offsetParent.getBoundingClientRect();\n }\n return {\n top: offset.top - parentOffset.top,\n left: offset.left - parentOffset.left\n };\n };\n Resize.prototype.doubleTapEvent = function (e) {\n var _this = this;\n if (this.getUserAgent() && this.isDblClk) {\n if (!this.tapped) {\n this.tapped = setTimeout(function () {\n _this.tapped = null;\n }, 300);\n }\n else {\n clearTimeout(this.tapped);\n this.callAutoFit(e);\n this.tapped = null;\n }\n }\n };\n Resize.prototype.getUserAgent = function () {\n var userAgent = Browser.userAgent.toLowerCase();\n return /iphone|ipod|ipad/.test(userAgent);\n };\n Resize.prototype.timeoutHandler = function () {\n this.tapped = null;\n };\n return Resize;\n}());\nexport { Resize };\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nimport { Component, Property, Event, EventHandler, L10n, setValue, getValue, isNullOrUndefined, Browser } from '@syncfusion/ej2-base';\nimport { NotifyPropertyChanges, detach, Internationalization, getUniqueID, closest } from '@syncfusion/ej2-base';\nimport { addClass, removeClass } from '@syncfusion/ej2-base';\nimport { Input } from '../input/input';\nvar HIDE_CLEAR = 'e-clear-icon-hide';\nvar TEXTBOX_FOCUS = 'e-input-focus';\nvar containerAttr = ['title', 'style', 'class'];\n/**\n * Represents the TextBox component that allows the user to enter the values based on it's type.\n * ```html\n * <input name='images' id='textbox'/>\n * ```\n * ```typescript\n * <script>\n * var textboxObj = new TextBox();\n * textboxObj.appendTo('#textbox');\n * </script>\n * ```\n */\nvar TextBox = /** @class */ (function (_super) {\n __extends(TextBox, _super);\n /**\n *\n * @param {TextBoxModel} options - Specifies the TextBox model.\n * @param {string | HTMLInputElement | HTMLTextAreaElement} element - Specifies the element to render as component.\n * @private\n */\n function TextBox(options, element) {\n var _this = _super.call(this, options, element) || this;\n _this.previousValue = null;\n _this.isAngular = false;\n _this.isHiddenInput = false;\n _this.isForm = false;\n _this.inputPreviousValue = null;\n _this.isVue = false;\n _this.textboxOptions = options;\n return _this;\n }\n /**\n * Calls internally if any of the property value is changed.\n *\n * @param {TextBoxModel} newProp - Returns the dynamic property value of the component.\n * @param {TextBoxModel} oldProp - Returns the previous property value of the component.\n * @returns {void}\n * @private\n */\n TextBox.prototype.onPropertyChanged = function (newProp, oldProp) {\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'floatLabelType':\n Input.removeFloating(this.textboxWrapper);\n Input.addFloating(this.respectiveElement, this.floatLabelType, this.placeholder);\n break;\n case 'enabled':\n Input.setEnabled(this.enabled, this.respectiveElement, this.floatLabelType, this.textboxWrapper.container);\n this.bindClearEvent();\n break;\n case 'width':\n Input.setWidth(newProp.width, this.textboxWrapper.container);\n break;\n case 'value':\n {\n var prevOnChange = this.isProtectedOnChange;\n this.isProtectedOnChange = true;\n if (!this.isBlank(this.value)) {\n this.value = this.value.toString();\n }\n this.isProtectedOnChange = prevOnChange;\n Input.setValue(this.value, this.respectiveElement, this.floatLabelType, this.showClearButton);\n if (this.isHiddenInput) {\n this.element.value = this.respectiveElement.value;\n }\n this.inputPreviousValue = this.respectiveElement.value;\n /* istanbul ignore next */\n if ((this.isAngular || this.isVue) && this.preventChange === true) {\n this.previousValue = this.isAngular ? this.value : this.previousValue;\n this.preventChange = false;\n }\n else if (isNullOrUndefined(this.isAngular) || !this.isAngular\n || (this.isAngular && !this.preventChange) || (this.isAngular && isNullOrUndefined(this.preventChange))) {\n this.raiseChangeEvent();\n }\n }\n break;\n case 'htmlAttributes':\n {\n this.updateHTMLAttrToElement();\n this.updateHTMLAttrToWrapper();\n this.checkAttributes(true);\n this.multiline && !isNullOrUndefined(this.textarea) ? Input.validateInputType(this.textboxWrapper.container, this.textarea) : Input.validateInputType(this.textboxWrapper.container, this.element);\n }\n break;\n case 'readonly':\n Input.setReadonly(this.readonly, this.respectiveElement);\n break;\n case 'type':\n if (this.respectiveElement.tagName !== 'TEXTAREA') {\n this.respectiveElement.setAttribute('type', this.type);\n Input.validateInputType(this.textboxWrapper.container, this.element);\n this.raiseChangeEvent();\n }\n break;\n case 'showClearButton':\n Input.setClearButton(this.showClearButton, this.respectiveElement, this.textboxWrapper);\n this.bindClearEvent();\n break;\n case 'enableRtl':\n Input.setEnableRtl(this.enableRtl, [this.textboxWrapper.container]);\n break;\n case 'placeholder':\n Input.setPlaceholder(this.placeholder, this.respectiveElement);\n Input.calculateWidth(this.respectiveElement, this.textboxWrapper.container);\n break;\n case 'autocomplete':\n if (this.autocomplete !== 'on' && this.autocomplete !== '') {\n this.respectiveElement.autocomplete = this.autocomplete;\n }\n else {\n this.removeAttributes(['autocomplete']);\n }\n break;\n case 'cssClass':\n this.updateCssClass(newProp.cssClass, oldProp.cssClass);\n break;\n case 'locale':\n this.globalize = new Internationalization(this.locale);\n this.l10n.setLocale(this.locale);\n this.setProperties({ placeholder: this.l10n.getConstant('placeholder') }, true);\n Input.setPlaceholder(this.placeholder, this.respectiveElement);\n break;\n }\n }\n };\n /**\n * Gets the component name\n *\n * @returns {string} Returns the component name.\n * @private\n */\n TextBox.prototype.getModuleName = function () {\n return 'textbox';\n };\n TextBox.prototype.isBlank = function (str) {\n return (!str || /^\\s*$/.test(str));\n };\n TextBox.prototype.preRender = function () {\n this.cloneElement = this.element.cloneNode(true);\n this.formElement = closest(this.element, 'form');\n if (!isNullOrUndefined(this.formElement)) {\n this.isForm = true;\n }\n /* istanbul ignore next */\n if (this.element.tagName === 'EJS-TEXTBOX') {\n var ejInstance = getValue('ej2_instances', this.element);\n var inputElement = this.multiline ?\n this.createElement('textarea') :\n this.createElement('input');\n var index = 0;\n for (index; index < this.element.attributes.length; index++) {\n var attributeName = this.element.attributes[index].nodeName;\n if (attributeName !== 'id' && attributeName !== 'class') {\n inputElement.setAttribute(attributeName, this.element.attributes[index].nodeValue);\n inputElement.innerHTML = this.element.innerHTML;\n if (attributeName === 'name') {\n this.element.removeAttribute('name');\n }\n }\n else if (attributeName === 'class') {\n inputElement.setAttribute(attributeName, this.element.className.split(' ').filter(function (item) { return item.indexOf('ng-') !== 0; }).join(' '));\n }\n }\n this.element.appendChild(inputElement);\n this.element = inputElement;\n setValue('ej2_instances', ejInstance, this.element);\n }\n this.updateHTMLAttrToElement();\n this.checkAttributes(false);\n if ((isNullOrUndefined(this.textboxOptions) || (this.textboxOptions['value'] === undefined)) && this.element.value !== '') {\n this.setProperties({ value: this.element.value }, true);\n }\n if (this.element.tagName !== 'TEXTAREA') {\n this.element.setAttribute('type', this.type);\n }\n if (this.type === 'text') {\n this.element.setAttribute('role', 'textbox');\n }\n this.globalize = new Internationalization(this.locale);\n var localeText = { placeholder: this.placeholder };\n this.l10n = new L10n('textbox', localeText, this.locale);\n if (this.l10n.getConstant('placeholder') !== '') {\n this.setProperties({ placeholder: this.placeholder || this.l10n.getConstant('placeholder') }, true);\n }\n if (!this.element.hasAttribute('id')) {\n this.element.setAttribute('id', getUniqueID('textbox'));\n }\n if (!this.element.hasAttribute('name')) {\n this.element.setAttribute('name', this.element.getAttribute('id'));\n }\n if (this.element.tagName === 'INPUT' && this.multiline) {\n this.isHiddenInput = true;\n this.textarea = this.createElement('textarea');\n this.element.parentNode.insertBefore(this.textarea, this.element);\n this.element.setAttribute('type', 'hidden');\n this.textarea.setAttribute('name', this.element.getAttribute('name'));\n this.element.removeAttribute('name');\n this.textarea.setAttribute('role', this.element.getAttribute('role'));\n this.element.removeAttribute('role');\n this.textarea.setAttribute('id', getUniqueID('textarea'));\n var apiAttributes = ['placeholder', 'disabled', 'value', 'readonly', 'type', 'autocomplete'];\n for (var index = 0; index < this.element.attributes.length; index++) {\n var attributeName = this.element.attributes[index].nodeName;\n if (this.element.hasAttribute(attributeName) && containerAttr.indexOf(attributeName) < 0 &&\n !(attributeName === 'id' || attributeName === 'type' || attributeName === 'e-mappinguid')) {\n // e-mappinguid attribute is handled for Grid component.\n this.textarea.setAttribute(attributeName, this.element.attributes[index].nodeValue);\n if (apiAttributes.indexOf(attributeName) < 0) {\n this.element.removeAttribute(attributeName);\n index--;\n }\n }\n }\n }\n };\n TextBox.prototype.checkAttributes = function (isDynamic) {\n var attrs = isDynamic ? isNullOrUndefined(this.htmlAttributes) ? [] : Object.keys(this.htmlAttributes) :\n ['placeholder', 'disabled', 'value', 'readonly', 'type', 'autocomplete'];\n for (var _i = 0, attrs_1 = attrs; _i < attrs_1.length; _i++) {\n var key = attrs_1[_i];\n if (!isNullOrUndefined(this.element.getAttribute(key))) {\n switch (key) {\n case 'disabled':\n if ((isNullOrUndefined(this.textboxOptions) || (this.textboxOptions['enabled'] === undefined)) || isDynamic) {\n var enabled = this.element.getAttribute(key) === 'disabled' || this.element.getAttribute(key) === '' ||\n this.element.getAttribute(key) === 'true' ? false : true;\n this.setProperties({ enabled: enabled }, !isDynamic);\n }\n break;\n case 'readonly':\n if ((isNullOrUndefined(this.textboxOptions) || (this.textboxOptions['readonly'] === undefined)) || isDynamic) {\n var readonly = this.element.getAttribute(key) === 'readonly' || this.element.getAttribute(key) === ''\n || this.element.getAttribute(key) === 'true' ? true : false;\n this.setProperties({ readonly: readonly }, !isDynamic);\n }\n break;\n case 'placeholder':\n if ((isNullOrUndefined(this.textboxOptions) || (this.textboxOptions['placeholder'] === undefined)) || isDynamic) {\n this.setProperties({ placeholder: this.element.placeholder }, !isDynamic);\n }\n break;\n case 'autocomplete':\n if ((isNullOrUndefined(this.textboxOptions) || (this.textboxOptions['autocomplete'] === undefined)) || isDynamic) {\n var autoCompleteTxt = this.element.autocomplete === 'off' ? 'off' : 'on';\n this.setProperties({ autocomplete: autoCompleteTxt }, !isDynamic);\n }\n break;\n case 'value':\n if (((isNullOrUndefined(this.textboxOptions) || (this.textboxOptions['value'] === undefined)) || isDynamic) && this.element.value !== '') {\n this.setProperties({ value: this.element.value }, !isDynamic);\n }\n break;\n case 'type':\n if ((isNullOrUndefined(this.textboxOptions) || (this.textboxOptions['type'] === undefined)) || isDynamic) {\n this.setProperties({ type: this.element.type }, !isDynamic);\n }\n break;\n }\n }\n }\n };\n /**\n * To Initialize the control rendering\n *\n * @returns {void}\n * @private\n */\n TextBox.prototype.render = function () {\n var updatedCssClassValue = this.cssClass;\n if (!isNullOrUndefined(this.cssClass) && this.cssClass !== '') {\n updatedCssClassValue = this.getInputValidClassList(this.cssClass);\n }\n this.respectiveElement = (this.isHiddenInput) ? this.textarea : this.element;\n this.textboxWrapper = Input.createInput({\n element: this.respectiveElement,\n floatLabelType: this.floatLabelType,\n properties: {\n enabled: this.enabled,\n enableRtl: this.enableRtl,\n cssClass: updatedCssClassValue,\n readonly: this.readonly,\n placeholder: this.placeholder,\n showClearButton: this.showClearButton\n }\n });\n this.updateHTMLAttrToWrapper();\n if (this.isHiddenInput) {\n this.respectiveElement.parentNode.insertBefore(this.element, this.respectiveElement);\n }\n this.wireEvents();\n if (!isNullOrUndefined(this.value)) {\n Input.setValue(this.value, this.respectiveElement, this.floatLabelType, this.showClearButton);\n if (this.isHiddenInput) {\n this.element.value = this.respectiveElement.value;\n }\n }\n if (!isNullOrUndefined(this.value)) {\n this.initialValue = this.value;\n this.setInitialValue();\n }\n if (this.autocomplete !== 'on' && this.autocomplete !== '') {\n this.respectiveElement.autocomplete = this.autocomplete;\n }\n else if (!isNullOrUndefined(this.textboxOptions) && (this.textboxOptions['autocomplete'] !== undefined)) {\n this.removeAttributes(['autocomplete']);\n }\n this.previousValue = this.value;\n this.inputPreviousValue = this.value;\n this.respectiveElement.defaultValue = this.respectiveElement.value;\n Input.setWidth(this.width, this.textboxWrapper.container);\n if (!isNullOrUndefined(closest(this.element, 'fieldset')) && closest(this.element, 'fieldset').disabled) {\n this.enabled = false;\n }\n this.renderComplete();\n };\n TextBox.prototype.updateHTMLAttrToWrapper = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n if (containerAttr.indexOf(key) > -1) {\n if (key === 'class') {\n var updatedClassValues = this.getInputValidClassList(this.htmlAttributes[\"\" + key]);\n if (updatedClassValues !== '') {\n addClass([this.textboxWrapper.container], updatedClassValues.split(' '));\n }\n }\n else if (key === 'style') {\n var setStyle = this.textboxWrapper.container.getAttribute(key);\n setStyle = !isNullOrUndefined(setStyle) ? (setStyle + this.htmlAttributes[\"\" + key]) :\n this.htmlAttributes[\"\" + key];\n this.textboxWrapper.container.setAttribute(key, setStyle);\n }\n else {\n this.textboxWrapper.container.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n }\n };\n TextBox.prototype.updateHTMLAttrToElement = function () {\n if (!isNullOrUndefined(this.htmlAttributes)) {\n for (var _i = 0, _a = Object.keys(this.htmlAttributes); _i < _a.length; _i++) {\n var key = _a[_i];\n if (containerAttr.indexOf(key) < 0) {\n this.multiline && !isNullOrUndefined(this.textarea) ? this.textarea.setAttribute(key, this.htmlAttributes[\"\" + key]) : this.element.setAttribute(key, this.htmlAttributes[\"\" + key]);\n }\n }\n }\n };\n TextBox.prototype.updateCssClass = function (newClass, oldClass) {\n Input.setCssClass(this.getInputValidClassList(newClass), [this.textboxWrapper.container], this.getInputValidClassList(oldClass));\n };\n TextBox.prototype.getInputValidClassList = function (inputClassName) {\n var result = inputClassName;\n if (!isNullOrUndefined(inputClassName) && inputClassName !== '') {\n result = (inputClassName.replace(/\\s+/g, ' ')).trim();\n }\n return result;\n };\n TextBox.prototype.setInitialValue = function () {\n if (!this.isAngular) {\n this.respectiveElement.setAttribute('value', this.initialValue);\n }\n };\n TextBox.prototype.wireEvents = function () {\n EventHandler.add(this.respectiveElement, 'focus', this.focusHandler, this);\n EventHandler.add(this.respectiveElement, 'blur', this.focusOutHandler, this);\n EventHandler.add(this.respectiveElement, 'keydown', this.keydownHandler, this);\n EventHandler.add(this.respectiveElement, 'input', this.inputHandler, this);\n EventHandler.add(this.respectiveElement, 'change', this.changeHandler, this);\n if (this.isForm) {\n EventHandler.add(this.formElement, 'reset', this.resetForm, this);\n }\n this.bindClearEvent();\n if (!isNullOrUndefined(this.textboxWrapper.container.querySelector('.e-float-text')) && this.floatLabelType === 'Auto'\n && this.textboxWrapper.container.classList.contains('e-autofill') &&\n this.textboxWrapper.container.classList.contains('e-outline')) {\n EventHandler.add((this.textboxWrapper.container.querySelector('.e-float-text')), 'animationstart', this.animationHandler, this);\n }\n };\n TextBox.prototype.animationHandler = function () {\n this.textboxWrapper.container.classList.add('e-valid-input');\n var label = this.textboxWrapper.container.querySelector('.e-float-text');\n if (!isNullOrUndefined(label)) {\n label.classList.add('e-label-top');\n if (label.classList.contains('e-label-bottom')) {\n label.classList.remove('e-label-bottom');\n }\n }\n };\n TextBox.prototype.resetValue = function (value) {\n var prevOnChange = this.isProtectedOnChange;\n this.isProtectedOnChange = true;\n this.value = value;\n if (value == null && this.textboxWrapper.container.classList.contains('e-valid-input')) {\n this.textboxWrapper.container.classList.remove('e-valid-input');\n }\n this.isProtectedOnChange = prevOnChange;\n };\n TextBox.prototype.resetForm = function () {\n if (this.isAngular) {\n this.resetValue('');\n }\n else {\n this.resetValue(this.initialValue);\n }\n if (!isNullOrUndefined(this.textboxWrapper)) {\n var label = this.textboxWrapper.container.querySelector('.e-float-text');\n if (!isNullOrUndefined(label) && this.floatLabelType !== 'Always') {\n if ((isNullOrUndefined(this.initialValue) || this.initialValue === '')) {\n label.classList.add('e-label-bottom');\n label.classList.remove('e-label-top');\n }\n else if (this.initialValue !== '') {\n label.classList.add('e-label-top');\n label.classList.remove('e-label-bottom');\n }\n }\n }\n };\n TextBox.prototype.focusHandler = function (args) {\n var eventArgs = {\n container: this.textboxWrapper.container,\n event: args,\n value: this.value\n };\n this.trigger('focus', eventArgs);\n };\n TextBox.prototype.focusOutHandler = function (args) {\n if (!(this.previousValue === null && this.value === null && this.respectiveElement.value === '') &&\n (this.previousValue !== this.value)) {\n this.raiseChangeEvent(args, true);\n }\n var eventArgs = {\n container: this.textboxWrapper.container,\n event: args,\n value: this.value\n };\n this.trigger('blur', eventArgs);\n };\n TextBox.prototype.keydownHandler = function (args) {\n if ((args.keyCode === 13 || args.keyCode === 9) && !((this.previousValue === null || this.previousValue === \"\") && (this.value === null || this.value === \"\") && this.respectiveElement.value === \"\")) {\n this.setProperties({ value: this.respectiveElement.value }, true);\n }\n };\n TextBox.prototype.inputHandler = function (args) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-this-alias\n var textboxObj = this;\n var eventArgs = {\n event: args,\n value: this.respectiveElement.value,\n previousValue: this.inputPreviousValue,\n container: this.textboxWrapper.container\n };\n this.inputPreviousValue = this.respectiveElement.value;\n /* istanbul ignore next */\n if (this.isAngular) {\n textboxObj.localChange({ value: this.respectiveElement.value });\n this.preventChange = true;\n }\n if (this.isVue) {\n this.preventChange = true;\n }\n this.trigger('input', eventArgs);\n args.stopPropagation();\n };\n TextBox.prototype.changeHandler = function (args) {\n this.setProperties({ value: this.respectiveElement.value }, true);\n if (this.previousValue != this.value) {\n this.raiseChangeEvent(args, true);\n }\n args.stopPropagation();\n };\n TextBox.prototype.raiseChangeEvent = function (event, interaction) {\n var eventArgs = {\n event: event,\n value: this.value,\n previousValue: this.previousValue,\n container: this.textboxWrapper.container,\n isInteraction: interaction ? interaction : false,\n isInteracted: interaction ? interaction : false\n };\n this.preventChange = false;\n this.trigger('change', eventArgs);\n this.previousValue = this.value;\n //EJ2CORE-738:For this task we update the textarea value to the input when input tag with multiline is present\n if (this.element.tagName === 'INPUT' && this.multiline && Browser.info.name === 'mozilla') {\n this.element.value = this.respectiveElement.value;\n }\n };\n TextBox.prototype.bindClearEvent = function () {\n if (this.showClearButton) {\n if (this.enabled) {\n EventHandler.add(this.textboxWrapper.clearButton, 'mousedown touchstart', this.resetInputHandler, this);\n }\n else {\n EventHandler.remove(this.textboxWrapper.clearButton, 'mousedown touchstart', this.resetInputHandler);\n }\n }\n };\n TextBox.prototype.resetInputHandler = function (event) {\n event.preventDefault();\n if (!(this.textboxWrapper.clearButton.classList.contains(HIDE_CLEAR)) || this.textboxWrapper.container.classList.contains('e-static-clear')) {\n Input.setValue('', this.respectiveElement, this.floatLabelType, this.showClearButton);\n if (this.isHiddenInput) {\n this.element.value = this.respectiveElement.value;\n }\n this.setProperties({ value: this.respectiveElement.value }, true);\n var eventArgs = {\n event: event,\n value: this.respectiveElement.value,\n previousValue: this.inputPreviousValue,\n container: this.textboxWrapper.container\n };\n this.trigger('input', eventArgs);\n this.inputPreviousValue = this.respectiveElement.value;\n this.raiseChangeEvent(event, true);\n if (closest(this.element, 'form')) {\n var element = this.element;\n var keyupEvent = document.createEvent('KeyboardEvent');\n keyupEvent.initEvent('keyup', false, true);\n element.dispatchEvent(keyupEvent);\n }\n }\n };\n TextBox.prototype.unWireEvents = function () {\n EventHandler.remove(this.respectiveElement, 'focus', this.focusHandler);\n EventHandler.remove(this.respectiveElement, 'blur', this.focusOutHandler);\n EventHandler.remove(this.respectiveElement, 'keydown', this.keydownHandler);\n EventHandler.remove(this.respectiveElement, 'input', this.inputHandler);\n EventHandler.remove(this.respectiveElement, 'change', this.changeHandler);\n if (this.isForm) {\n EventHandler.remove(this.formElement, 'reset', this.resetForm);\n }\n if (!isNullOrUndefined(this.textboxWrapper.container.querySelector('.e-float-text')) && this.floatLabelType === 'Auto'\n && this.textboxWrapper.container.classList.contains('e-outline') &&\n this.textboxWrapper.container.classList.contains('e-autofill')) {\n EventHandler.remove((this.textboxWrapper.container.querySelector('.e-float-text')), 'animationstart', this.animationHandler);\n }\n };\n /**\n * Removes the component from the DOM and detaches all its related event handlers.\n * Also, it maintains the initial TextBox element from the DOM.\n *\n * @method destroy\n * @returns {void}\n */\n TextBox.prototype.destroy = function () {\n this.unWireEvents();\n if (this.element.tagName === 'INPUT' && this.multiline) {\n detach(this.textboxWrapper.container.getElementsByTagName('textarea')[0]);\n this.respectiveElement = this.element;\n this.element.removeAttribute('type');\n }\n this.respectiveElement.value = this.respectiveElement.defaultValue;\n this.respectiveElement.classList.remove('e-input');\n this.removeAttributes(['aria-disabled', 'aria-readonly', 'aria-labelledby']);\n if (!isNullOrUndefined(this.textboxWrapper)) {\n this.textboxWrapper.container.insertAdjacentElement('afterend', this.respectiveElement);\n detach(this.textboxWrapper.container);\n }\n this.textboxWrapper = null;\n Input.destroy();\n _super.prototype.destroy.call(this);\n };\n /**\n * Adding the icons to the TextBox component.\n *\n * @param { string } position - Specify the icon placement on the TextBox. Possible values are append and prepend.\n * @param { string | string[] } icons - Icon classes which are need to add to the span element which is going to created.\n * Span element acts as icon or button element for TextBox.\n * @returns {void}\n */\n TextBox.prototype.addIcon = function (position, icons) {\n Input.addIcon(position, icons, this.textboxWrapper.container, this.respectiveElement, this.createElement);\n };\n /* eslint-disable valid-jsdoc, jsdoc/require-returns */\n /**\n * Gets the properties to be maintained in the persisted state.\n *\n */\n TextBox.prototype.getPersistData = function () {\n var keyEntity = ['value'];\n return this.addOnPersist(keyEntity);\n };\n /* eslint-enable valid-jsdoc, jsdoc/require-returns */\n /**\n * Adding the multiple attributes as key-value pair to the TextBox element.\n *\n * @param {string} attributes - Specifies the attributes to be add to TextBox element.\n * @returns {void}\n */\n TextBox.prototype.addAttributes = function (attributes) {\n for (var _i = 0, _a = Object.keys(attributes); _i < _a.length; _i++) {\n var key = _a[_i];\n if (key === 'disabled') {\n this.setProperties({ enabled: false }, true);\n Input.setEnabled(this.enabled, this.respectiveElement, this.floatLabelType, this.textboxWrapper.container);\n }\n else if (key === 'readonly') {\n this.setProperties({ readonly: true }, true);\n Input.setReadonly(this.readonly, this.respectiveElement);\n }\n else if (key === 'class') {\n this.respectiveElement.classList.add(attributes[\"\" + key]);\n }\n else if (key === 'placeholder') {\n this.setProperties({ placeholder: attributes[\"\" + key] }, true);\n Input.setPlaceholder(this.placeholder, this.respectiveElement);\n }\n else if (key === 'rows' && this.respectiveElement.tagName === 'TEXTAREA') {\n this.respectiveElement.setAttribute(key, attributes[\"\" + key]);\n }\n else {\n this.respectiveElement.setAttribute(key, attributes[\"\" + key]);\n }\n }\n };\n /**\n * Removing the multiple attributes as key-value pair to the TextBox element.\n *\n * @param { string[] } attributes - Specifies the attributes name to be removed from TextBox element.\n * @returns {void}\n */\n TextBox.prototype.removeAttributes = function (attributes) {\n for (var _i = 0, attributes_1 = attributes; _i < attributes_1.length; _i++) {\n var key = attributes_1[_i];\n if (key === 'disabled') {\n this.setProperties({ enabled: true }, true);\n Input.setEnabled(this.enabled, this.respectiveElement, this.floatLabelType, this.textboxWrapper.container);\n }\n else if (key === 'readonly') {\n this.setProperties({ readonly: false }, true);\n Input.setReadonly(this.readonly, this.respectiveElement);\n }\n else if (key === 'placeholder') {\n this.setProperties({ placeholder: null }, true);\n Input.setPlaceholder(this.placeholder, this.respectiveElement);\n }\n else {\n this.respectiveElement.removeAttribute(key);\n }\n }\n };\n /**\n * Sets the focus to widget for interaction.\n *\n * @returns {void}\n */\n TextBox.prototype.focusIn = function () {\n if (document.activeElement !== this.respectiveElement && this.enabled) {\n this.respectiveElement.focus();\n if (this.textboxWrapper.container.classList.contains('e-input-group')\n || this.textboxWrapper.container.classList.contains('e-outline')\n || this.textboxWrapper.container.classList.contains('e-filled')) {\n addClass([this.textboxWrapper.container], [TEXTBOX_FOCUS]);\n }\n }\n };\n /**\n * Remove the focus from widget, if the widget is in focus state.\n *\n * @returns {void}\n */\n TextBox.prototype.focusOut = function () {\n if (document.activeElement === this.respectiveElement && this.enabled) {\n this.respectiveElement.blur();\n if (this.textboxWrapper.container.classList.contains('e-input-group')\n || this.textboxWrapper.container.classList.contains('e-outline')\n || this.textboxWrapper.container.classList.contains('e-filled')) {\n removeClass([this.textboxWrapper.container], [TEXTBOX_FOCUS]);\n }\n }\n };\n __decorate([\n Property('text')\n ], TextBox.prototype, \"type\", void 0);\n __decorate([\n Property(false)\n ], TextBox.prototype, \"readonly\", void 0);\n __decorate([\n Property(null)\n ], TextBox.prototype, \"value\", void 0);\n __decorate([\n Property('Never')\n ], TextBox.prototype, \"floatLabelType\", void 0);\n __decorate([\n Property('')\n ], TextBox.prototype, \"cssClass\", void 0);\n __decorate([\n Property(null)\n ], TextBox.prototype, \"placeholder\", void 0);\n __decorate([\n Property('on')\n ], TextBox.prototype, \"autocomplete\", void 0);\n __decorate([\n Property({})\n ], TextBox.prototype, \"htmlAttributes\", void 0);\n __decorate([\n Property(false)\n ], TextBox.prototype, \"multiline\", void 0);\n __decorate([\n Property(true)\n ], TextBox.prototype, \"enabled\", void 0);\n __decorate([\n Property(false)\n ], TextBox.prototype, \"showClearButton\", void 0);\n __decorate([\n Property(false)\n ], TextBox.prototype, \"enablePersistence\", void 0);\n __decorate([\n Property(null)\n ], TextBox.prototype, \"width\", void 0);\n __decorate([\n Event()\n ], TextBox.prototype, \"created\", void 0);\n __decorate([\n Event()\n ], TextBox.prototype, \"destroyed\", void 0);\n __decorate([\n Event()\n ], TextBox.prototype, \"change\", void 0);\n __decorate([\n Event()\n ], TextBox.prototype, \"blur\", void 0);\n __decorate([\n Event()\n ], TextBox.prototype, \"focus\", void 0);\n __decorate([\n Event()\n ], TextBox.prototype, \"input\", void 0);\n TextBox = __decorate([\n NotifyPropertyChanges\n ], TextBox);\n return TextBox;\n}(Component));\nexport { TextBox };\n","//! moment.js locale configuration\n//! locale : Portuguese [pt]\n//! author : Jefferson : https://github.com/jalex79\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var pt = moment.defineLocale('pt', {\n months: 'janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro'.split(\n '_'\n ),\n monthsShort: 'jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez'.split('_'),\n weekdays:\n 'Domingo_Segunda-feira_Terça-feira_Quarta-feira_Quinta-feira_Sexta-feira_Sábado'.split(\n '_'\n ),\n weekdaysShort: 'Dom_Seg_Ter_Qua_Qui_Sex_Sáb'.split('_'),\n weekdaysMin: 'Do_2ª_3ª_4ª_5ª_6ª_Sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D [de] MMMM [de] YYYY',\n LLL: 'D [de] MMMM [de] YYYY HH:mm',\n LLLL: 'dddd, D [de] MMMM [de] YYYY HH:mm',\n },\n calendar: {\n sameDay: '[Hoje à s] LT',\n nextDay: '[Amanhã à s] LT',\n nextWeek: 'dddd [à s] LT',\n lastDay: '[Ontem à s] LT',\n lastWeek: function () {\n return this.day() === 0 || this.day() === 6\n ? '[Último] dddd [à s] LT' // Saturday + Sunday\n : '[Última] dddd [à s] LT'; // Monday - Friday\n },\n sameElse: 'L',\n },\n relativeTime: {\n future: 'em %s',\n past: 'há %s',\n s: 'segundos',\n ss: '%d segundos',\n m: 'um minuto',\n mm: '%d minutos',\n h: 'uma hora',\n hh: '%d horas',\n d: 'um dia',\n dd: '%d dias',\n w: 'uma semana',\n ww: '%d semanas',\n M: 'um mês',\n MM: '%d meses',\n y: 'um ano',\n yy: '%d anos',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}º/,\n ordinal: '%dº',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return pt;\n\n})));\n","/**\n * Save class provide method to save file\n * ```typescript\n * let blob : Blob = new Blob([''], { type: 'text/plain' });\n * Save.save('fileName.txt',blob);\n */\nvar Save = /** @class */ (function () {\n /**\n * Initialize new instance of {save}\n */\n function Save() {\n // tslint:disable\n }\n /**\n * Saves the file with specified name and sends the file to client browser\n * @param {string} fileName- file name to save.\n * @param {Blob} buffer- the content to write in file\n * @param {boolean} isMicrosoftBrowser- specify whether microsoft browser or not\n * @returns {void}\n */\n Save.save = function (fileName, buffer) {\n if (fileName === null || fileName === undefined || fileName === '') {\n throw new Error('ArgumentException: fileName cannot be undefined, null or empty');\n }\n var extension = fileName.substring(fileName.lastIndexOf('.') + 1, fileName.length);\n var mimeType = this.getMimeType(extension);\n if (mimeType !== '') {\n buffer = new Blob([buffer], { type: mimeType });\n }\n if (this.isMicrosoftBrowser) {\n navigator.msSaveBlob(buffer, fileName);\n }\n else {\n var downloadLink = document.createElementNS('http://www.w3.org/1999/xhtml', 'a');\n this.saveInternal(fileName, extension, buffer, downloadLink, 'download' in downloadLink);\n }\n };\n Save.saveInternal = function (fileName, extension, buffer, downloadLink, hasDownloadAttribute) {\n if (hasDownloadAttribute) {\n downloadLink.download = fileName;\n var dataUrl_1 = window.URL.createObjectURL(buffer);\n downloadLink.href = dataUrl_1;\n var event_1 = document.createEvent('MouseEvent');\n event_1.initEvent('click', true, true);\n downloadLink.dispatchEvent(event_1);\n setTimeout(function () {\n window.URL.revokeObjectURL(dataUrl_1);\n dataUrl_1 = undefined;\n });\n }\n else {\n if (extension !== 'docx' && extension !== 'xlsx') {\n var url = window.URL.createObjectURL(buffer);\n var isPopupBlocked = window.open(url, '_blank');\n if (!isPopupBlocked) {\n window.location.href = url;\n }\n }\n else {\n var reader_1 = new FileReader();\n reader_1.onloadend = function () {\n var isPopupBlocked = window.open(reader_1.result, '_blank');\n if (!isPopupBlocked) {\n window.location.href = reader_1.result;\n }\n };\n reader_1.readAsDataURL(buffer);\n }\n }\n };\n /**\n *\n * @param {string} extension - get mime type of the specified extension\n * @private\n */\n Save.getMimeType = function (extension) {\n var mimeType = '';\n switch (extension) {\n case 'html':\n mimeType = 'text/html';\n break;\n case 'pdf':\n mimeType = 'application/pdf';\n break;\n case 'docx':\n mimeType = 'application/vnd.openxmlformats-officedocument.wordprocessingml.document';\n break;\n case 'xlsx':\n mimeType = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet';\n break;\n case 'txt':\n mimeType = 'text/plain';\n break;\n }\n return mimeType;\n };\n return Save;\n}());\nexport { Save };\n","//! moment.js locale configuration\n//! locale : Punjabi (India) [pa-in]\n//! author : Harpreet Singh : https://github.com/harpreetkhalsagtbit\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var symbolMap = {\n 1: '੧',\n 2: '੨',\n 3: 'à©©',\n 4: '੪',\n 5: 'à©«',\n 6: '੬',\n 7: 'à©',\n 8: 'à©®',\n 9: '੯',\n 0: '੦',\n },\n numberMap = {\n '੧': '1',\n '੨': '2',\n 'à©©': '3',\n '੪': '4',\n 'à©«': '5',\n '੬': '6',\n 'à©': '7',\n 'à©®': '8',\n '੯': '9',\n '੦': '0',\n };\n\n var paIn = moment.defineLocale('pa-in', {\n // There are months name as per Nanakshahi Calendar but they are not used as rigidly in modern Punjabi.\n months: 'ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪà©à¨°à©ˆà¨²_ਮਈ_ਜੂਨ_ਜà©à¨²à¨¾à¨ˆ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ'.split(\n '_'\n ),\n monthsShort:\n 'ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪà©à¨°à©ˆà¨²_ਮਈ_ਜੂਨ_ਜà©à¨²à¨¾à¨ˆ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ'.split(\n '_'\n ),\n weekdays: 'à¨à¨¤à¨µà¨¾à¨°_ਸੋਮਵਾਰ_ਮੰਗਲਵਾਰ_ਬà©à¨§à¨µà¨¾à¨°_ਵੀਰਵਾਰ_ਸ਼à©à©±à¨•à¨°à¨µà¨¾à¨°_ਸ਼ਨੀਚਰਵਾਰ'.split(\n '_'\n ),\n weekdaysShort: 'à¨à¨¤_ਸੋਮ_ਮੰਗਲ_ਬà©à¨§_ਵੀਰ_ਸ਼à©à¨•à¨°_ਸ਼ਨੀ'.split('_'),\n weekdaysMin: 'à¨à¨¤_ਸੋਮ_ਮੰਗਲ_ਬà©à¨§_ਵੀਰ_ਸ਼à©à¨•à¨°_ਸ਼ਨੀ'.split('_'),\n longDateFormat: {\n LT: 'A h:mm ਵਜੇ',\n LTS: 'A h:mm:ss ਵਜੇ',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY, A h:mm ਵਜੇ',\n LLLL: 'dddd, D MMMM YYYY, A h:mm ਵਜੇ',\n },\n calendar: {\n sameDay: '[ਅਜ] LT',\n nextDay: '[ਕਲ] LT',\n nextWeek: '[ਅਗਲਾ] dddd, LT',\n lastDay: '[ਕਲ] LT',\n lastWeek: '[ਪਿਛਲੇ] dddd, LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s ਵਿੱਚ',\n past: '%s ਪਿਛਲੇ',\n s: 'ਕà©à¨ ਸਕਿੰਟ',\n ss: '%d ਸਕਿੰਟ',\n m: 'ਇਕ ਮਿੰਟ',\n mm: '%d ਮਿੰਟ',\n h: 'ਇੱਕ ਘੰਟਾ',\n hh: '%d ਘੰਟੇ',\n d: 'ਇੱਕ ਦਿਨ',\n dd: '%d ਦਿਨ',\n M: 'ਇੱਕ ਮਹੀਨਾ',\n MM: '%d ਮਹੀਨੇ',\n y: 'ਇੱਕ ਸਾਲ',\n yy: '%d ਸਾਲ',\n },\n preparse: function (string) {\n return string.replace(/[੧੨੩੪੫੬à©à©®à©¯à©¦]/g, function (match) {\n return numberMap[match];\n });\n },\n postformat: function (string) {\n return string.replace(/\\d/g, function (match) {\n return symbolMap[match];\n });\n },\n // Punjabi notation for meridiems are quite fuzzy in practice. While there exists\n // a rigid notion of a 'Pahar' it is not used as rigidly in modern Punjabi.\n meridiemParse: /ਰਾਤ|ਸਵੇਰ|ਦà©à¨ªà¨¹à¨¿à¨°|ਸ਼ਾਮ/,\n meridiemHour: function (hour, meridiem) {\n if (hour === 12) {\n hour = 0;\n }\n if (meridiem === 'ਰਾਤ') {\n return hour < 4 ? hour : hour + 12;\n } else if (meridiem === 'ਸਵੇਰ') {\n return hour;\n } else if (meridiem === 'ਦà©à¨ªà¨¹à¨¿à¨°') {\n return hour >= 10 ? hour : hour + 12;\n } else if (meridiem === 'ਸ਼ਾਮ') {\n return hour + 12;\n }\n },\n meridiem: function (hour, minute, isLower) {\n if (hour < 4) {\n return 'ਰਾਤ';\n } else if (hour < 10) {\n return 'ਸਵੇਰ';\n } else if (hour < 17) {\n return 'ਦà©à¨ªà¨¹à¨¿à¨°';\n } else if (hour < 20) {\n return 'ਸ਼ਾਮ';\n } else {\n return 'ਰਾਤ';\n }\n },\n week: {\n dow: 0, // Sunday is the first day of the week.\n doy: 6, // The week that contains Jan 6th is the first week of the year.\n },\n });\n\n return paIn;\n\n})));\n","/**\n * Encoding class: Contains the details about encoding type, whether to write a Unicode byte order mark (BOM).\n * ```typescript\n * let encoding : Encoding = new Encoding();\n * encoding.type = 'Utf8';\n * encoding.getBytes('Encoding', 0, 5);\n * ```\n */\nvar Encoding = /** @class */ (function () {\n /**\n * Initializes a new instance of the Encoding class. A parameter specifies whether to write a Unicode byte order mark\n * @param {boolean} includeBom?-true to specify that a Unicode byte order mark is written; otherwise, false.\n */\n function Encoding(includeBom) {\n this.emitBOM = true;\n this.encodingType = 'Ansi';\n this.initBOM(includeBom);\n }\n Object.defineProperty(Encoding.prototype, \"includeBom\", {\n /**\n * Gets a value indicating whether to write a Unicode byte order mark\n * @returns boolean- true to specify that a Unicode byte order mark is written; otherwise, false\n */\n get: function () {\n return this.emitBOM;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(Encoding.prototype, \"type\", {\n /**\n * Gets the encoding type.\n * @returns EncodingType\n */\n get: function () {\n return this.encodingType;\n },\n /**\n * Sets the encoding type.\n * @param {EncodingType} value\n */\n set: function (value) {\n this.encodingType = value;\n },\n enumerable: true,\n configurable: true\n });\n /**\n * Initialize the includeBom to emit BOM or Not\n * @param {boolean} includeBom\n */\n Encoding.prototype.initBOM = function (includeBom) {\n if (includeBom === undefined || includeBom === null) {\n this.emitBOM = true;\n }\n else {\n this.emitBOM = includeBom;\n }\n };\n /**\n * Calculates the number of bytes produced by encoding the characters in the specified string\n * @param {string} chars - The string containing the set of characters to encode\n * @returns {number} - The number of bytes produced by encoding the specified characters\n */\n Encoding.prototype.getByteCount = function (chars) {\n var byteCount = 0;\n validateNullOrUndefined(chars, 'string');\n if (chars === '') {\n var byte = this.utf8Len(chars.charCodeAt(0));\n return byte;\n }\n if (this.type === null || this.type === undefined) {\n this.type = 'Ansi';\n }\n return this.getByteCountInternal(chars, 0, chars.length);\n };\n /**\n * Return the Byte of character\n * @param {number} codePoint\n * @returns {number}\n */\n Encoding.prototype.utf8Len = function (codePoint) {\n var bytes = codePoint <= 0x7F ? 1 :\n codePoint <= 0x7FF ? 2 :\n codePoint <= 0xFFFF ? 3 :\n codePoint <= 0x1FFFFF ? 4 : 0;\n return bytes;\n };\n /**\n * for 4 byte character return surrogate pair true, otherwise false\n * @param {number} codeUnit\n * @returns {boolean}\n */\n Encoding.prototype.isHighSurrogate = function (codeUnit) {\n return codeUnit >= 0xD800 && codeUnit <= 0xDBFF;\n };\n /**\n * for 4byte character generate the surrogate pair\n * @param {number} highCodeUnit\n * @param {number} lowCodeUnit\n */\n Encoding.prototype.toCodepoint = function (highCodeUnit, lowCodeUnit) {\n highCodeUnit = (0x3FF & highCodeUnit) << 10;\n var u = highCodeUnit | (0x3FF & lowCodeUnit);\n return u + 0x10000;\n };\n /**\n * private method to get the byte count for specific charindex and count\n * @param {string} chars\n * @param {number} charIndex\n * @param {number} charCount\n */\n Encoding.prototype.getByteCountInternal = function (chars, charIndex, charCount) {\n var byteCount = 0;\n if (this.encodingType === 'Utf8' || this.encodingType === 'Unicode') {\n var isUtf8 = this.encodingType === 'Utf8';\n for (var i = 0; i < charCount; i++) {\n var charCode = chars.charCodeAt(isUtf8 ? charIndex : charIndex++);\n if (this.isHighSurrogate(charCode)) {\n if (isUtf8) {\n var high = charCode;\n var low = chars.charCodeAt(++charIndex);\n byteCount += this.utf8Len(this.toCodepoint(high, low));\n }\n else {\n byteCount += 4;\n ++i;\n }\n }\n else {\n if (isUtf8) {\n byteCount += this.utf8Len(charCode);\n }\n else {\n byteCount += 2;\n }\n }\n if (isUtf8) {\n charIndex++;\n }\n }\n return byteCount;\n }\n else {\n byteCount = charCount;\n return byteCount;\n }\n };\n /**\n * Encodes a set of characters from the specified string into the ArrayBuffer.\n * @param {string} s- The string containing the set of characters to encode\n * @param {number} charIndex-The index of the first character to encode.\n * @param {number} charCount- The number of characters to encode.\n * @returns {ArrayBuffer} - The ArrayBuffer that contains the resulting sequence of bytes.\n */\n Encoding.prototype.getBytes = function (s, charIndex, charCount) {\n validateNullOrUndefined(s, 'string');\n validateNullOrUndefined(charIndex, 'charIndex');\n validateNullOrUndefined(charCount, 'charCount');\n if (charIndex < 0 || charCount < 0) {\n throw new RangeError('Argument Out Of Range Exception: charIndex or charCount is less than zero');\n }\n if (s.length - charIndex < charCount) {\n throw new RangeError('Argument Out Of Range Exception: charIndex and charCount do not denote a valid range in string');\n }\n var bytes;\n if (s === '') {\n bytes = new ArrayBuffer(0);\n return bytes;\n }\n if (this.type === null || this.type === undefined) {\n this.type = 'Ansi';\n }\n var byteCount = this.getByteCountInternal(s, charIndex, charCount);\n switch (this.type) {\n case 'Utf8':\n bytes = this.getBytesOfUtf8Encoding(byteCount, s, charIndex, charCount);\n return bytes;\n case 'Unicode':\n bytes = this.getBytesOfUnicodeEncoding(byteCount, s, charIndex, charCount);\n return bytes;\n default:\n bytes = this.getBytesOfAnsiEncoding(byteCount, s, charIndex, charCount);\n return bytes;\n }\n };\n /**\n * Decodes a sequence of bytes from the specified ArrayBuffer into the string.\n * @param {ArrayBuffer} bytes- The ArrayBuffer containing the sequence of bytes to decode.\n * @param {number} index- The index of the first byte to decode.\n * @param {number} count- The number of bytes to decode.\n * @returns {string} - The string that contains the resulting set of characters.\n */\n Encoding.prototype.getString = function (bytes, index, count) {\n validateNullOrUndefined(bytes, 'bytes');\n validateNullOrUndefined(index, 'index');\n validateNullOrUndefined(count, 'count');\n if (index < 0 || count < 0) {\n throw new RangeError('Argument Out Of Range Exception: index or count is less than zero');\n }\n if (bytes.byteLength - index < count) {\n throw new RangeError('Argument Out Of Range Exception: index and count do not denote a valid range in bytes');\n }\n if (bytes.byteLength === 0 || count === 0) {\n return '';\n }\n if (this.type === null || this.type === undefined) {\n this.type = 'Ansi';\n }\n var out = '';\n var byteCal = new Uint8Array(bytes);\n switch (this.type) {\n case 'Utf8':\n var s = this.getStringOfUtf8Encoding(byteCal, index, count);\n return s;\n case 'Unicode':\n var byteUnicode = new Uint16Array(bytes);\n out = this.getStringofUnicodeEncoding(byteUnicode, index, count);\n return out;\n default:\n var j = index;\n for (var i = 0; i < count; i++) {\n var c = byteCal[j];\n out += String.fromCharCode(c); // 1 byte(ASCII) character \n j++;\n }\n return out;\n }\n };\n Encoding.prototype.getBytesOfAnsiEncoding = function (byteCount, s, charIndex, charCount) {\n var bytes = new ArrayBuffer(byteCount);\n var bufview = new Uint8Array(bytes);\n var k = 0;\n for (var i = 0; i < charCount; i++) {\n var charcode = s.charCodeAt(charIndex++);\n if (charcode < 0x800) {\n bufview[k] = charcode;\n }\n else {\n bufview[k] = 63; //replacement character '?'\n }\n k++;\n }\n return bytes;\n };\n Encoding.prototype.getBytesOfUtf8Encoding = function (byteCount, s, charIndex, charCount) {\n var bytes = new ArrayBuffer(byteCount);\n var uint = new Uint8Array(bytes);\n var index = charIndex;\n var j = 0;\n for (var i = 0; i < charCount; i++) {\n var charcode = s.charCodeAt(index);\n if (charcode <= 0x7F) { // 1 byte character 2^7\n uint[j] = charcode;\n }\n else if (charcode < 0x800) { // 2 byte character 2^11\n uint[j] = 0xc0 | (charcode >> 6);\n uint[++j] = 0x80 | (charcode & 0x3f);\n }\n else if ((charcode < 0xd800 || charcode >= 0xe000)) { // 3 byte character 2^16 \n uint[j] = 0xe0 | (charcode >> 12);\n uint[++j] = 0x80 | ((charcode >> 6) & 0x3f);\n uint[++j] = 0x80 | (charcode & 0x3f);\n }\n else {\n uint[j] = 0xef;\n uint[++j] = 0xbf;\n uint[++j] = 0xbd; // U+FFFE \"replacement character\"\n }\n ++j;\n ++index;\n }\n return bytes;\n };\n Encoding.prototype.getBytesOfUnicodeEncoding = function (byteCount, s, charIndex, charCount) {\n var bytes = new ArrayBuffer(byteCount);\n var uint16 = new Uint16Array(bytes);\n for (var i = 0; i < charCount; i++) {\n var charcode = s.charCodeAt(i);\n uint16[i] = charcode;\n }\n return bytes;\n };\n Encoding.prototype.getStringOfUtf8Encoding = function (byteCal, index, count) {\n var j = 0;\n var i = index;\n var s = '';\n for (j; j < count; j++) {\n var c = byteCal[i++];\n while (i > byteCal.length) {\n return s;\n }\n if (c > 127) {\n if (c > 191 && c < 224 && i < count) {\n c = (c & 31) << 6 | byteCal[i] & 63;\n }\n else if (c > 223 && c < 240 && i < byteCal.byteLength) {\n c = (c & 15) << 12 | (byteCal[i] & 63) << 6 | byteCal[++i] & 63;\n }\n else if (c > 239 && c < 248 && i < byteCal.byteLength) {\n c = (c & 7) << 18 | (byteCal[i] & 63) << 12 | (byteCal[++i] & 63) << 6 | byteCal[++i] & 63;\n }\n ++i;\n }\n s += String.fromCharCode(c); // 1 byte(ASCII) character \n }\n return s;\n };\n Encoding.prototype.getStringofUnicodeEncoding = function (byteUni, index, count) {\n if (count > byteUni.length) {\n throw new RangeError('ArgumentOutOfRange_Count');\n }\n var byte16 = new Uint16Array(count);\n var out = '';\n for (var i = 0; i < count && i < byteUni.length; i++) {\n byte16[i] = byteUni[index++];\n }\n out = String.fromCharCode.apply(null, byte16);\n return out;\n };\n /**\n * To clear the encoding instance\n * @return {void}\n */\n Encoding.prototype.destroy = function () {\n this.emitBOM = undefined;\n this.encodingType = undefined;\n };\n return Encoding;\n}());\nexport { Encoding };\n/**\n * To check the object is null or undefined and throw error if it is null or undefined\n * @param {Object} value - object to check is null or undefined\n * @return {boolean}\n * @throws {ArgumentException} - if the value is null or undefined\n * @private\n */\nexport function validateNullOrUndefined(value, message) {\n if (value === null || value === undefined) {\n throw new Error('ArgumentException: ' + message + ' cannot be null or undefined');\n }\n}\n","//! moment.js locale configuration\n//! locale : Scottish Gaelic [gd]\n//! author : Jon Ashdown : https://github.com/jonashdown\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var months = [\n 'Am Faoilleach',\n 'An Gearran',\n 'Am Mà rt',\n 'An Giblean',\n 'An Cèitean',\n 'An t-Ã’gmhios',\n 'An t-Iuchar',\n 'An Lùnastal',\n 'An t-Sultain',\n 'An Dà mhair',\n 'An t-Samhain',\n 'An Dùbhlachd',\n ],\n monthsShort = [\n 'Faoi',\n 'Gear',\n 'Mà rt',\n 'Gibl',\n 'Cèit',\n 'Ã’gmh',\n 'Iuch',\n 'Lùn',\n 'Sult',\n 'Dà mh',\n 'Samh',\n 'Dùbh',\n ],\n weekdays = [\n 'Didòmhnaich',\n 'Diluain',\n 'Dimà irt',\n 'Diciadain',\n 'Diardaoin',\n 'Dihaoine',\n 'Disathairne',\n ],\n weekdaysShort = ['Did', 'Dil', 'Dim', 'Dic', 'Dia', 'Dih', 'Dis'],\n weekdaysMin = ['Dò', 'Lu', 'Mà ', 'Ci', 'Ar', 'Ha', 'Sa'];\n\n var gd = moment.defineLocale('gd', {\n months: months,\n monthsShort: monthsShort,\n monthsParseExact: true,\n weekdays: weekdays,\n weekdaysShort: weekdaysShort,\n weekdaysMin: weekdaysMin,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[An-diugh aig] LT',\n nextDay: '[A-mà ireach aig] LT',\n nextWeek: 'dddd [aig] LT',\n lastDay: '[An-dè aig] LT',\n lastWeek: 'dddd [seo chaidh] [aig] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'ann an %s',\n past: 'bho chionn %s',\n s: 'beagan diogan',\n ss: '%d diogan',\n m: 'mionaid',\n mm: '%d mionaidean',\n h: 'uair',\n hh: '%d uairean',\n d: 'latha',\n dd: '%d latha',\n M: 'mìos',\n MM: '%d mìosan',\n y: 'bliadhna',\n yy: '%d bliadhna',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(d|na|mh)/,\n ordinal: function (number) {\n var output = number === 1 ? 'd' : number % 10 === 2 ? 'na' : 'mh';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return gd;\n\n})));\n","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\n/* eslint-disable @typescript-eslint/triple-slash-reference */\n/// <reference path='../common/menu-base-model.d.ts'/>\nimport { attributes, getUniqueID, Collection, NotifyPropertyChanges, Property } from '@syncfusion/ej2-base';\nimport { getZindexPartial } from '@syncfusion/ej2-popups';\nimport { MenuBase, MenuItem } from '../common/menu-base';\n/**\n * The ContextMenu is a graphical user interface that appears on the user right click/touch hold operation.\n * ```html\n * <div id = 'target'></div>\n * <ul id = 'contextmenu'></ul>\n * ```\n * ```typescript\n * <script>\n * var contextMenuObj = new ContextMenu({items: [{ text: 'Cut' }, { text: 'Copy' },{ text: 'Paste' }], target: '#target'});\n * </script>\n * ```\n */\nvar ContextMenu = /** @class */ (function (_super) {\n __extends(ContextMenu, _super);\n /**\n * Constructor for creating the widget.\n *\n * @private\n * @param {ContextMenuModel} options - Specifies the context menu model\n * @param {string} element - Specifies the element\n */\n function ContextMenu(options, element) {\n return _super.call(this, options, element) || this;\n }\n /**\n * For internal use only - prerender processing.\n *\n * @private\n * @returns {void}\n */\n ContextMenu.prototype.preRender = function () {\n this.isMenu = false;\n this.element.id = this.element.id || getUniqueID('ej2-contextmenu');\n _super.prototype.preRender.call(this);\n };\n ContextMenu.prototype.initialize = function () {\n _super.prototype.initialize.call(this);\n attributes(this.element, { 'role': 'menubar', 'tabindex': '0' });\n this.element.style.zIndex = getZindexPartial(this.element).toString();\n };\n /**\n * This method is used to open the ContextMenu in specified position.\n *\n * @param {number} top - To specify ContextMenu vertical positioning.\n * @param {number} left - To specify ContextMenu horizontal positioning.\n * @param {HTMLElement} target - To calculate z-index for ContextMenu based upon the specified target.\n * @function open\n * @returns {void}\n */\n ContextMenu.prototype.open = function (top, left, target) {\n _super.prototype.openMenu.call(this, null, null, top, left, null, target);\n };\n /**\n * Closes the ContextMenu if it is opened.\n *\n * @function close\n * @returns {void}\n */\n ContextMenu.prototype.close = function () {\n _super.prototype.closeMenu.call(this);\n };\n /**\n * Called internally if any of the property value changed.\n *\n * @private\n * @param {ContextMenuModel} newProp - Specifies new properties\n * @param {ContextMenuModel} oldProp - Specifies old properties\n * @returns {void}\n */\n ContextMenu.prototype.onPropertyChanged = function (newProp, oldProp) {\n _super.prototype.onPropertyChanged.call(this, newProp, oldProp);\n for (var _i = 0, _a = Object.keys(newProp); _i < _a.length; _i++) {\n var prop = _a[_i];\n switch (prop) {\n case 'filter':\n this.close();\n this.filter = newProp.filter;\n break;\n case 'target':\n this.unWireEvents(oldProp.target);\n this.wireEvents();\n break;\n }\n }\n };\n /**\n * Get module name.\n *\n * @returns {string} - Module Name\n * @private\n */\n ContextMenu.prototype.getModuleName = function () {\n return 'contextmenu';\n };\n __decorate([\n Property('')\n ], ContextMenu.prototype, \"target\", void 0);\n __decorate([\n Property('')\n ], ContextMenu.prototype, \"filter\", void 0);\n __decorate([\n Collection([], MenuItem)\n ], ContextMenu.prototype, \"items\", void 0);\n ContextMenu = __decorate([\n NotifyPropertyChanges\n ], ContextMenu);\n return ContextMenu;\n}(MenuBase));\nexport { ContextMenu };\n","//! moment.js locale configuration\n//! locale : Dutch [nl]\n//! author : Joris Röling : https://github.com/jorisroling\n//! author : Jacob Middag : https://github.com/middagj\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var monthsShortWithDots =\n 'jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.'.split('_'),\n monthsShortWithoutDots =\n 'jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec'.split('_'),\n monthsParse = [\n /^jan/i,\n /^feb/i,\n /^maart|mrt.?$/i,\n /^apr/i,\n /^mei$/i,\n /^jun[i.]?$/i,\n /^jul[i.]?$/i,\n /^aug/i,\n /^sep/i,\n /^okt/i,\n /^nov/i,\n /^dec/i,\n ],\n monthsRegex =\n /^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december|jan\\.?|feb\\.?|mrt\\.?|apr\\.?|ju[nl]\\.?|aug\\.?|sep\\.?|okt\\.?|nov\\.?|dec\\.?)/i;\n\n var nl = moment.defineLocale('nl', {\n months: 'januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december'.split(\n '_'\n ),\n monthsShort: function (m, format) {\n if (!m) {\n return monthsShortWithDots;\n } else if (/-MMM-/.test(format)) {\n return monthsShortWithoutDots[m.month()];\n } else {\n return monthsShortWithDots[m.month()];\n }\n },\n\n monthsRegex: monthsRegex,\n monthsShortRegex: monthsRegex,\n monthsStrictRegex:\n /^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december)/i,\n monthsShortStrictRegex:\n /^(jan\\.?|feb\\.?|mrt\\.?|apr\\.?|mei|ju[nl]\\.?|aug\\.?|sep\\.?|okt\\.?|nov\\.?|dec\\.?)/i,\n\n monthsParse: monthsParse,\n longMonthsParse: monthsParse,\n shortMonthsParse: monthsParse,\n\n weekdays:\n 'zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag'.split('_'),\n weekdaysShort: 'zo._ma._di._wo._do._vr._za.'.split('_'),\n weekdaysMin: 'zo_ma_di_wo_do_vr_za'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD-MM-YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[vandaag om] LT',\n nextDay: '[morgen om] LT',\n nextWeek: 'dddd [om] LT',\n lastDay: '[gisteren om] LT',\n lastWeek: '[afgelopen] dddd [om] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'over %s',\n past: '%s geleden',\n s: 'een paar seconden',\n ss: '%d seconden',\n m: 'één minuut',\n mm: '%d minuten',\n h: 'één uur',\n hh: '%d uur',\n d: 'één dag',\n dd: '%d dagen',\n w: 'één week',\n ww: '%d weken',\n M: 'één maand',\n MM: '%d maanden',\n y: 'één jaar',\n yy: '%d jaar',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(ste|de)/,\n ordinal: function (number) {\n return (\n number +\n (number === 1 || number === 8 || number >= 20 ? 'ste' : 'de')\n );\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return nl;\n\n})));\n","/* eslint-disable jsdoc/require-returns */\n/* eslint-disable valid-jsdoc */\n/* eslint-disable jsdoc/require-param */\nimport { ChartLocation, RectOption, isCollide, isOverlap } from '../../common/utils/helper';\nimport { markerAnimate, appendChildElement, getVisiblePoints } from '../../common/utils/helper';\nimport { getLabelText, convertHexToColor, calculateRect, textElement, colorNameToHex } from '../../common/utils/helper';\nimport { measureText, TextOption, Rect } from '@syncfusion/ej2-svg-base';\nimport { textRender } from '../../common/model/constants';\nimport { createTemplate, getFontStyle, getElement, measureElementRect, templateAnimate, withIn, withInBounds } from '../../common/utils/helper';\nimport { createElement, getValue, extend } from '@syncfusion/ej2-base';\nimport { getPoint, getRotatedRectangleCoordinates, isRotatedRectIntersect } from '../../common/utils/helper';\n/**\n * `DataLabel` module is used to render data label for the data point.\n */\nvar DataLabel = /** @class */ (function () {\n /**\n * Constructor for the data label module.\n *\n * @private\n */\n function DataLabel(chart) {\n this.errorHeight = 0;\n this.chart = chart;\n }\n DataLabel.prototype.initPrivateVariables = function (series, marker) {\n var transform = '';\n var clipPath = '';\n var render = series.chart.renderer;\n var index = (series.index === undefined) ? series.category : series.index;\n if (series.chart.chartAreaType === 'Cartesian') {\n transform = 'translate(' + series.clipRect.x + ',' + (series.clipRect.y) + ')';\n clipPath = 'url(#' + this.chart.element.id + '_ChartSeriesClipRect_' + index + ')';\n }\n if (marker.dataLabel.visible && !this.chart.enableCanvas) {\n series.shapeElement = render.createGroup({\n 'id': this.chart.element.id + 'ShapeGroup' + index,\n 'transform': transform,\n 'clip-path': 'url(#' + this.chart.element.id + '_ChartSeriesClipRect_' + index + ')'\n });\n series.textElement = render.createGroup({\n 'id': this.chart.element.id + 'TextGroup' + index,\n 'transform': transform,\n 'clip-path': clipPath\n });\n series.textElement.setAttribute('aria-hidden', 'true');\n }\n this.markerHeight = ((series.type === 'Scatter' || marker.visible)) ? (marker.height / 2) : 0;\n this.commonId = this.chart.element.id + '_Series_' + index + '_Point_';\n this.calculateErrorHeight(series, series.marker.dataLabel.position);\n this.chartBackground = this.chart.chartArea.background === 'transparent' ?\n this.chart.background || this.chart.themeStyle.background : this.chart.chartArea.background;\n };\n DataLabel.prototype.calculateErrorHeight = function (series, position) {\n if (!series.errorBar.visible) {\n return null;\n }\n else if (series.errorBar.visible && this.chart.chartAreaType !== 'PolarRadar') {\n var direction = series.errorBar.direction;\n var positiveHeight = this.chart.errorBarModule.positiveHeight;\n var negativeHeight = this.chart.errorBarModule.negativeHeight;\n if (this.isRectSeries(series)) {\n if (position === 'Top' || position === 'Auto') {\n if (direction === 'Both' || direction === 'Minus') {\n this.errorHeight = negativeHeight;\n }\n else {\n this.errorHeight = 0;\n }\n }\n if (position === 'Outer' || position === 'Auto') {\n if (direction === 'Both' || direction === 'Plus') {\n this.errorHeight = positiveHeight;\n }\n else {\n this.errorHeight = 0;\n }\n }\n }\n else {\n if (position === 'Top' || position === 'Outer' || position === 'Auto') {\n if ((direction === 'Both' || direction === 'Plus') && (!series.chart.isTransposed)) {\n this.errorHeight = positiveHeight;\n }\n else {\n this.errorHeight = 0;\n }\n }\n if (position === 'Bottom' || position === 'Auto') {\n if (direction === 'Both' || direction === 'Minus') {\n this.errorHeight = negativeHeight;\n }\n else {\n this.errorHeight = 0;\n }\n }\n }\n }\n else {\n this.errorHeight = 0;\n }\n };\n DataLabel.prototype.isRectSeries = function (series) {\n return series.isRectSeries || series.type === 'RangeArea' || series.type === 'SplineRangeArea' || series.type === 'RangeStepArea';\n };\n /**\n * Render the data label for series.\n *\n * @returns {void}\n */\n DataLabel.prototype.render = function (series, chart, dataLabel) {\n // initialize the private variable\n this.initPrivateVariables(series, series.marker);\n var rect;\n var labelLocation = { x: 0, y: 0 };\n var rgbValue;\n var contrast;\n var argsData;\n var border;\n var textSize;\n var angle;\n var degree;\n this.inverted = chart.requireInvertedAxis;\n this.yAxisInversed = series.yAxis.isAxisInverse;\n var redraw = chart.redraw;\n var isDataLabelOverlap = false;\n var coordinatesAfterRotation = [];\n var templateId = chart.element.id + '_Series_' +\n (series.index === undefined ? series.category : series.index) + '_DataLabelCollections';\n var element = createElement('div', {\n id: templateId\n });\n var visiblePoints = getVisiblePoints(series);\n var point;\n var rectCenterX;\n var rectCenterY;\n // Data label point iteration started\n for (var i = 0; i < visiblePoints.length; i++) {\n point = visiblePoints[i];\n if (!dataLabel.showZero && ((point.y !== 0) || (point.y === 0 && series.emptyPointSettings.mode === 'Zero'))) {\n return null;\n }\n this.margin = dataLabel.margin;\n var labelText = [];\n var labelLength = void 0;\n var xPos = void 0;\n var yPos = void 0;\n var xValue = void 0;\n var yValue = void 0;\n var isRender = true;\n var clip = series.clipRect;\n var shapeRect = void 0;\n isDataLabelOverlap = false;\n dataLabel.angle = dataLabel.labelIntersectAction === 'Rotate90' ? 90 : dataLabel.angle;\n dataLabel.enableRotation = dataLabel.labelIntersectAction === 'Rotate90' ? true : dataLabel.enableRotation;\n angle = degree = dataLabel.angle;\n border = { width: dataLabel.border.width, color: dataLabel.border.color };\n var argsFont = (extend({}, getValue('properties', dataLabel.font), null, true));\n if ((point.symbolLocations.length && point.symbolLocations[0]) ||\n (series.type === 'BoxAndWhisker' && point.regions.length)) {\n labelText = getLabelText(point, series, chart);\n labelLength = labelText.length;\n for (var i_1 = 0; i_1 < labelLength; i_1++) {\n argsData = {\n cancel: false, name: textRender, series: series,\n point: point, text: labelText[i_1], border: border,\n color: dataLabel.fill, template: dataLabel.template, font: argsFont, location: labelLocation,\n textSize: measureText(labelText[i_1], dataLabel.font, this.chart.themeStyle.datalabelFont)\n };\n chart.trigger(textRender, argsData);\n if (!argsData.cancel) {\n this.fontBackground = argsData.color;\n this.isDataLabelShape(argsData);\n this.markerHeight = series.type === 'Bubble' ? (point.regions[0].height / 2) : this.markerHeight;\n if (argsData.template !== null) {\n this.createDataLabelTemplate(element, series, dataLabel, point, argsData, i_1, redraw);\n }\n else {\n textSize = measureText(argsData.text, dataLabel.font, this.chart.themeStyle.datalabelFont);\n rect = this.calculateTextPosition(point, series, textSize, dataLabel, i_1);\n // To check whether the polar radar chart datalabel intersects the axis label or not\n if (chart.chartAreaType === 'PolarRadar') {\n for (var _i = 0, _a = chart.chartAxisLayoutPanel.visibleAxisLabelRect; _i < _a.length; _i++) {\n var rectRegion = _a[_i];\n if (isOverlap(new Rect(rect.x, rect.y, rect.width, rect.height), rectRegion)) {\n isRender = false;\n break;\n }\n }\n }\n var actualRect = new Rect(rect.x + clip.x, rect.y + clip.y, rect.width, rect.height);\n //let notOverlapping: boolean;\n if (dataLabel.enableRotation) {\n var rectCoordinates = this.getRectanglePoints(rect);\n rectCenterX = rect.x + (rect.width / 2);\n rectCenterY = (rect.y + (rect.height / 2));\n coordinatesAfterRotation = getRotatedRectangleCoordinates(rectCoordinates, rectCenterX, rectCenterY, angle);\n isDataLabelOverlap = (dataLabel.labelIntersectAction === 'Rotate90' || angle == -90) ? false : this.isDataLabelOverlapWithChartBound(coordinatesAfterRotation, chart, clip);\n if (!isDataLabelOverlap) {\n this.chart.rotatedDataLabelCollections.push(coordinatesAfterRotation);\n var currentPointIndex = this.chart.rotatedDataLabelCollections.length - 1;\n for (var index = currentPointIndex; index >= 0; index--) {\n if (this.chart.rotatedDataLabelCollections[currentPointIndex] &&\n this.chart.rotatedDataLabelCollections[index - 1] &&\n isRotatedRectIntersect(this.chart.rotatedDataLabelCollections[currentPointIndex], this.chart.rotatedDataLabelCollections[index - 1])) {\n isDataLabelOverlap = true;\n this.chart.rotatedDataLabelCollections[currentPointIndex] = null;\n break;\n }\n }\n }\n }\n else {\n isDataLabelOverlap = isCollide(rect, chart.dataLabelCollections, clip);\n }\n if ((!isDataLabelOverlap || dataLabel.labelIntersectAction === 'None') && isRender) {\n chart.dataLabelCollections.push(actualRect);\n if (this.isShape) {\n shapeRect = chart.renderer.drawRectangle(new RectOption(this.commonId + point.index + '_TextShape_' + i_1, argsData.color, argsData.border, dataLabel.opacity, rect, dataLabel.rx, dataLabel.ry), new Int32Array([clip.x, clip.y]));\n if (series.shapeElement) {\n series.shapeElement.appendChild(shapeRect);\n }\n }\n // Checking the font color\n var backgroundColor = this.fontBackground === 'transparent' ? ((this.chart.theme.indexOf('Dark') > -1 || this.chart.theme === 'HighContrast') ? 'black' : 'white') : this.fontBackground;\n rgbValue = convertHexToColor(colorNameToHex(backgroundColor));\n contrast = Math.round((rgbValue.r * 299 + rgbValue.g * 587 + rgbValue.b * 114) / 1000);\n xPos = (rect.x + this.margin.left + textSize.width / 2) + labelLocation.x;\n yPos = (rect.y + this.margin.top + textSize.height * 3 / 4) + labelLocation.y;\n labelLocation = { x: 0, y: 0 };\n if (angle !== 0 && dataLabel.enableRotation) {\n // xValue = xPos - (dataLabel.margin.left) / 2 + (dataLabel.margin.right / 2);\n xValue = rectCenterX;\n //yValue = yPos - (dataLabel.margin.top) / 2 - (textSize.height / dataLabel.margin.top) +\n // (dataLabel.margin.bottom) / 2;\n yValue = rectCenterY;\n degree = (angle > 360) ? angle - 360 : (angle < -360) ? angle + 360 : angle;\n }\n else {\n degree = 0;\n xValue = rect.x;\n yValue = rect.y;\n xPos -= chart.chartAreaType == 'Cartesian' && xPos + (textSize.width / 2) > clip.width ? (xPos + textSize.width / 2) - clip.width : 0;\n yPos -= (yPos + textSize.height > clip.y + clip.height && !(series.type.indexOf('Bar') > -1)) ? (yPos + textSize.height) - (clip.y + clip.height) : 0;\n }\n var textAnchor = dataLabel.labelIntersectAction === 'Rotate90' ? (dataLabel.position == 'Top' ? 'start' : (dataLabel.position == 'Middle' ? 'middle' : 'end')) :\n ((angle == -90 && dataLabel.enableRotation) ? (dataLabel.position == 'Top' ? 'end' : (dataLabel.position == 'Middle' ? 'middle' : 'start')) : 'middle');\n textElement(chart.renderer, new TextOption(this.commonId + point.index + '_Text_' + i_1, xPos, yPos, textAnchor, argsData.text, 'rotate(' + degree + ',' + (xValue) + ',' + (yValue) + ')', 'auto', degree), argsData.font, argsData.font.color ||\n ((contrast >= 128 || series.type === 'Hilo' || series.type === 'HiloOpenClose') ? 'black' : 'white'), series.textElement, false, redraw, true, false, series.chart.duration, series.clipRect, null, null, chart.enableCanvas, null, this.chart.themeStyle.datalabelFont);\n }\n }\n }\n }\n }\n }\n if (element.childElementCount) {\n if (!chart.enableCanvas) {\n appendChildElement(chart.enableCanvas, getElement(chart.element.id + '_Secondary_Element'), element, chart.redraw, \n // eslint-disable-next-line @typescript-eslint/indent\n false, 'x', 'y', null, '', false, false, null, chart.duration);\n }\n else {\n getElement(chart.element.id + '_Secondary_Element').appendChild(element);\n }\n }\n };\n /**\n * Get rect coordinates\n */\n DataLabel.prototype.getRectanglePoints = function (rect) {\n var loc1 = new ChartLocation(rect.x, rect.y);\n var loc2 = new ChartLocation(rect.x + rect.width, rect.y);\n var loc3 = new ChartLocation(rect.x + rect.width, rect.y + rect.height);\n var loc4 = new ChartLocation(rect.x, rect.y + rect.height);\n return [loc1, loc2, loc3, loc4];\n };\n DataLabel.prototype.isDataLabelOverlapWithChartBound = function (rectCoordinates, chart, clip) {\n for (var index = 0; index < rectCoordinates.length; index++) {\n if (!withInBounds(rectCoordinates[index].x + clip.x, rectCoordinates[index].y + clip.y, chart.initialClipRect)) {\n return true;\n }\n }\n return false;\n };\n /**\n * Render the data label template.\n *\n * @returns {void}\n * @private\n */\n DataLabel.prototype.createDataLabelTemplate = function (parentElement, series, dataLabel, point, data, labelIndex, redraw) {\n this.margin = { left: 0, right: 0, bottom: 0, top: 0 };\n var clip = series.clipRect;\n var childElement = createTemplate(createElement('div', {\n id: this.chart.element.id + '_Series_' + (series.index === undefined ? series.category : series.index) + '_DataLabel_'\n + point.index + (labelIndex ? ('_' + labelIndex) : ''),\n styles: 'position: absolute;background-color:' + data.color + ';' +\n getFontStyle(dataLabel.font) + ';border:' + data.border.width + 'px solid ' + data.border.color + ';'\n }), point.index, data.template, this.chart, point, series, this.chart.element.id + '_DataLabel', labelIndex);\n this.calculateTemplateLabelSize(parentElement, childElement, point, series, dataLabel, labelIndex, clip, redraw);\n };\n DataLabel.prototype.calculateTemplateLabelSize = function (parentElement, childElement, point, series, dataLabel, labelIndex, clip, redraw, isReactCallback) {\n var elementRect = measureElementRect(childElement, redraw, isReactCallback);\n var rect = this.calculateTextPosition(point, series, { width: elementRect.width, height: elementRect.height }, dataLabel, labelIndex);\n var clipWidth = 0;\n var clipHeight = 0;\n var isOverlap = false;\n if (isReactCallback) {\n isOverlap = (elementRect.width === 0 || elementRect.height === 0); // To check the data label already overlap before react callback call\n // clipWidth = ((series.clipRect.x + rect.x) + elementRect.width) > parentElement.clientWidth ?\n // (parentElement.clientWidth - (series.clipRect.x + rect.x)) : 0;\n // clipHeight = (series.points.length - 1 === point.index) ? elementRect.height / 2 : 0;\n }\n childElement.style.left = ((this.chart.chartAreaType === 'PolarRadar' ? 0 : series.clipRect.x) + rect.x - clipWidth) + 'px';\n childElement.style.top = ((this.chart.chartAreaType === 'PolarRadar' ? 0 : series.clipRect.y) + rect.y + clipHeight) + 'px';\n var backgroundColor = this.fontBackground === 'transparent' ? (this.chart.theme.indexOf('Dark') > -1 ? 'black' : 'white') : this.fontBackground;\n var rgbValue = convertHexToColor(colorNameToHex(backgroundColor));\n var vAxis = series.chart.requireInvertedAxis ? series.xAxis : series.yAxis;\n var hAxis = series.chart.requireInvertedAxis ? series.yAxis : series.xAxis;\n childElement.style.color = dataLabel.font.color ||\n ((Math.round((rgbValue.r * 299 + rgbValue.g * 587 + rgbValue.b * 114) / 1000)) >= 128 ? 'black' : 'white');\n if (childElement.childElementCount && !isOverlap && (!isCollide(rect, this.chart.dataLabelCollections, clip) ||\n dataLabel.labelIntersectAction === 'None') && (series.seriesType !== 'XY' || point.yValue === undefined ||\n withIn(point.yValue, series.yAxis.visibleRange) || (series.type.indexOf('Stacking') > -1) ||\n (series.type.indexOf('100') > -1 && withIn(series.stackedValues.endValues[point.index], series.yAxis.visibleRange))) &&\n withIn(point.xValue, series.xAxis.visibleRange) && parseFloat(childElement.style.top) >= vAxis.rect.y &&\n parseFloat(childElement.style.left) >= hAxis.rect.x &&\n parseFloat(childElement.style.top) <= vAxis.rect.y + vAxis.rect.height &&\n parseFloat(childElement.style.left) <= hAxis.rect.x + hAxis.rect.width) {\n this.chart.dataLabelCollections.push(new Rect(rect.x + clip.x, rect.y + clip.y, rect.width, rect.height));\n appendChildElement(this.chart.enableCanvas, parentElement, childElement, redraw, true, 'left', 'top');\n if (series.animation.enable && this.chart.animateSeries && !this.chart.enableCanvas) {\n this.doDataLabelAnimation(series, childElement);\n }\n else if (this.chart.enableCanvas) {\n parentElement.appendChild(childElement);\n }\n }\n };\n DataLabel.prototype.calculateTextPosition = function (point, series, textSize, dataLabel, labelIndex) {\n var labelRegion = labelIndex > 1 ? (series.type === 'Candle') ? point.regions[1] : point.regions[0] : point.regions[0];\n if (labelIndex > 1 && series.type === 'HiloOpenClose') {\n labelRegion = (labelIndex === 2) ? point.regions[1] : point.regions[2];\n }\n var location;\n location = this.getLabelLocation(point, series, textSize, labelIndex);\n var padding = 5;\n var clipRect = series.clipRect;\n // calculating alignment\n if (!this.chart.requireInvertedAxis || !this.isRectSeries(series) || series.type === 'BoxAndWhisker') {\n this.locationX = location.x;\n var alignmentValue = textSize.height + (this.borderWidth * 2) + this.markerHeight +\n this.margin.bottom + this.margin.top + padding;\n location.x = (dataLabel.position === 'Auto') ? location.x :\n this.calculateAlignment(alignmentValue, location.x, dataLabel.alignment, this.isRectSeries(series) ? point.yValue < 0 : false);\n // calculating position\n location.y = (!this.isRectSeries(series) || series.type === 'BoxAndWhisker') ?\n this.calculatePathPosition(location.y, dataLabel.position, series, point, textSize, labelIndex) :\n this.calculateRectPosition(location.y, labelRegion, point.yValue < 0 !== this.yAxisInversed, dataLabel.position, series, textSize, labelIndex, point);\n if (this.isRectSeries(series) && this.chart.chartAreaType === 'PolarRadar') {\n location = this.calculatePolarRectPosition(location, dataLabel.position, series, point, textSize, labelIndex, dataLabel.alignment, alignmentValue);\n }\n }\n else {\n this.locationY = location.y;\n var alignmentValue = textSize.width + this.borderWidth + this.margin.left + this.margin.right - padding;\n location.x = dataLabel.position === 'Auto' ? location.x :\n this.calculateAlignment(alignmentValue, location.x, dataLabel.alignment, point.yValue < 0);\n location.x = this.calculateRectPosition(location.x, labelRegion, point.yValue < 0 !== this.yAxisInversed, dataLabel.position, series, textSize, labelIndex, point);\n }\n var rect = calculateRect(location, textSize, this.margin);\n // Checking the condition whether data Label has been exist the clip rect\n if (!(dataLabel.enableRotation === true && dataLabel.angle !== 0) &&\n !((rect.y > (clipRect.y + clipRect.height)) || (rect.x > (clipRect.x + clipRect.width)) ||\n (rect.x + rect.width < 0) || (rect.y + rect.height < 0))) {\n rect.x = rect.x < 0 ? padding : rect.x;\n rect.y = (rect.y < 0) && !(dataLabel.labelIntersectAction === 'None') ? padding : rect.y;\n rect.x -= (rect.x + rect.width) > (clipRect.x + clipRect.width) ? (rect.x + rect.width)\n - (clipRect.x + clipRect.width) + padding : 0;\n rect.y -= (rect.y + rect.height) > (clipRect.y + clipRect.height) ? (rect.y + rect.height)\n - (clipRect.y + clipRect.height) + padding : 0;\n this.fontBackground = this.fontBackground === 'transparent' ? this.chartBackground : this.fontBackground;\n }\n var dataLabelOutRegion;\n if (this.inverted && series.isRectSeries && (rect.x + rect.width > labelRegion.x + labelRegion.width)) {\n dataLabelOutRegion = true;\n }\n this.fontBackground = dataLabelOutRegion ? this.chartBackground : this.fontBackground;\n return rect;\n };\n // Calculation label location for polar column draw types\n DataLabel.prototype.calculatePolarRectPosition = function (location, position, series, point, size, labelIndex, alignment, alignmentValue) {\n var padding = 5;\n var columnRadius;\n var chartWidth = this.chart.availableSize.width;\n var alignmentSign = (alignment === 'Center') ? 0 : (alignment === 'Far' ? 1 : -1);\n var angle = (point.regionData.startAngle - 0.5 * Math.PI) + (point.regionData.endAngle - point.regionData.startAngle) / 2;\n if (labelIndex === 0) {\n columnRadius = point.regionData.radius < point.regionData.innerRadius ? point.regionData.innerRadius\n : point.regionData.radius;\n }\n else {\n columnRadius = point.regionData.radius > point.regionData.innerRadius ? point.regionData.innerRadius\n : point.regionData.radius;\n }\n this.fontBackground = this.fontBackground === 'transparent' ? this.chartBackground : this.fontBackground;\n if (series.drawType.indexOf('Stacking') > -1) {\n position = position === 'Outer' ? 'Top' : position;\n }\n else if (series.drawType.indexOf('Range') > -1) {\n position = (position === 'Outer' || position === 'Top') ? position : 'Auto';\n }\n if (position === 'Outer') {\n columnRadius = labelIndex === 0 ? columnRadius + 2 * padding + this.markerHeight :\n columnRadius - 2 * padding - this.markerHeight;\n }\n else if (position === 'Middle') {\n columnRadius = columnRadius / 2 + padding;\n if (series.drawType === 'StackingColumn') {\n columnRadius = point.regionData.innerRadius + ((point.regionData.radius - point.regionData.innerRadius) / 2)\n + padding - (size.height / 2);\n }\n }\n else if (position === 'Top') {\n columnRadius = labelIndex === 0 ? columnRadius - 2 * padding - this.markerHeight :\n columnRadius + 2 * padding + this.markerHeight;\n }\n else if (position === 'Bottom') {\n columnRadius = 2 * padding;\n columnRadius += (series.drawType === 'StackingColumn') ? (point.regionData.innerRadius + this.markerHeight) : 0;\n }\n else {\n if (labelIndex === 0) {\n columnRadius = columnRadius >= series.chart.radius ? columnRadius - padding :\n series.drawType === 'StackingColumn' ? columnRadius - 2 * padding : columnRadius + 2 * padding;\n }\n else {\n columnRadius = columnRadius >= series.chart.radius ? columnRadius + padding : columnRadius - 2 * padding;\n }\n }\n columnRadius += (alignmentValue * alignmentSign);\n location.x = series.clipRect.width / 2 + series.clipRect.x + columnRadius * Math.cos(angle);\n // To change x location based on text anchor for column and stackingcolumn chart\n if (series.drawType === 'StackingColumn') {\n location.x = location.x < chartWidth / 2 ? location.x + size.width / 2 :\n (location.x > chartWidth / 2 ? location.x - size.width / 2 : location.x);\n }\n else if (series.drawType === 'Column') {\n location.x = location.x < chartWidth / 2 ? location.x - size.width / 2 :\n (location.x > chartWidth / 2 ? location.x + size.width / 2 : location.x);\n }\n location.y = series.clipRect.height / 2 + series.clipRect.y + columnRadius * Math.sin(angle);\n return location;\n };\n /**\n * Get the label location\n */\n DataLabel.prototype.getLabelLocation = function (point, series, textSize, labelIndex) {\n var location = new ChartLocation(0, 0);\n var labelRegion = (series.type === 'Candle' && labelIndex > 1) ? point.regions[1] : point.regions[0];\n if (series.type === 'HiloOpenClose') {\n labelRegion = (labelIndex === 2) ? point.regions[1] : point.regions[2];\n }\n var xAxis = series.xAxis;\n var yAxis = series.yAxis;\n var isInverted = series.chart.requireInvertedAxis;\n if (series.type === 'BoxAndWhisker') {\n this.markerHeight = 0;\n switch (labelIndex) {\n case 0:\n location = getPoint(point.xValue, point.median, xAxis, yAxis, isInverted);\n break;\n case 1:\n location = getPoint(point.xValue, point.maximum, xAxis, yAxis, isInverted);\n break;\n case 2:\n location = getPoint(point.xValue, point.minimum, xAxis, yAxis, isInverted);\n break;\n case 3:\n location = getPoint(point.xValue, point.upperQuartile, xAxis, yAxis, isInverted);\n break;\n case 4:\n location = getPoint(point.xValue, point.lowerQuartile, xAxis, yAxis, isInverted);\n break;\n default: {\n location = getPoint(point.xValue, point.outliers[labelIndex - 5], xAxis, yAxis, isInverted);\n this.markerHeight = series.marker.height / 2;\n break;\n }\n }\n if (isInverted) {\n location.y = point.regions[0].y + (point.regions[0].height / 2);\n }\n else {\n location.x = point.regions[0].x + (point.regions[0].width / 2);\n }\n }\n else if (labelIndex === 0 || labelIndex === 1) {\n location = new ChartLocation(point.symbolLocations[0].x, point.symbolLocations[0].y);\n }\n else if ((labelIndex === 2 || labelIndex === 3) && series.type === 'Candle') {\n location = new ChartLocation(point.symbolLocations[1].x, point.symbolLocations[1].y);\n }\n else if (isInverted) {\n location = { x: labelRegion.x + (labelRegion.width) / 2, y: labelRegion.y };\n }\n else {\n location = { x: labelRegion.x + labelRegion.width, y: labelRegion.y + (labelRegion.height) / 2 };\n }\n //Aligning the label at the beginning of the tick, when tick size is less than text size\n if (labelIndex > 1 && series.type === 'HiloOpenClose') {\n if (series.chart.requireInvertedAxis) {\n var height = labelRegion.height;\n location.y = labelRegion.y + height / 2 + 2 * (labelIndex === 2 ? 1 : -1);\n }\n else {\n var width = labelRegion.width;\n location.x = labelRegion.x + width / 2 + 2 * (labelIndex === 2 ? 1 : -1);\n }\n }\n return location;\n };\n DataLabel.prototype.calculateRectPosition = function (labelLocation, rect, isMinus, position, series, textSize, labelIndex, point) {\n if (series.chart.chartAreaType === 'PolarRadar') {\n return null;\n }\n var padding = 5;\n var margin = this.margin;\n var textLength = !this.inverted ? textSize.height : textSize.width;\n var extraSpace = this.borderWidth + textLength / 2 + (position !== 'Outer' && series.type.indexOf('Column') > -1 &&\n (Math.abs(rect.height - textSize.height) < padding) ? 0 : padding);\n if (series.type === 'StackingColumn100' || series.type === 'StackingBar100') {\n position = (position === 'Outer') ? 'Top' : position;\n }\n else if (series.type.indexOf('Range') > -1) {\n position = (position === 'Outer' || position === 'Top') ? position : 'Auto';\n }\n else if (series.type === 'Waterfall') {\n position = position === 'Auto' ? 'Middle' : position;\n }\n switch (position) {\n case 'Bottom':\n labelLocation = !this.inverted ?\n isMinus ? (labelLocation + (series.type === 'Waterfall' ? (-extraSpace - margin.top - this.markerHeight) : (-rect.height + extraSpace + margin.top))) :\n (labelLocation + rect.height - extraSpace - margin.bottom) :\n isMinus ? (labelLocation + (series.type === 'Waterfall' ? (+extraSpace + margin.left + this.markerHeight) : (+rect.width - extraSpace - margin.left))) :\n (labelLocation - rect.width + extraSpace + margin.right);\n break;\n case 'Middle':\n labelLocation = labelLocation = !this.inverted ?\n (isMinus ? labelLocation - (rect.height / 2) : labelLocation + (rect.height / 2)) :\n (isMinus ? labelLocation + (rect.width / 2) : labelLocation - (rect.width / 2));\n break;\n case 'Auto':\n labelLocation = this.calculateRectActualPosition(labelLocation, rect, isMinus, series, textSize, labelIndex, point);\n break;\n default:\n extraSpace += this.errorHeight;\n labelLocation = this.calculateTopAndOuterPosition(labelLocation, rect, position, series, labelIndex, extraSpace, isMinus);\n break;\n }\n var check = !this.inverted ? (labelLocation < rect.y || labelLocation > rect.y + rect.height) :\n (labelLocation < rect.x || labelLocation > rect.x + rect.width);\n this.fontBackground = check ?\n (this.fontBackground === 'transparent' ? this.chartBackground : this.fontBackground)\n : this.fontBackground === 'transparent' ? (point.color || series.interior) : this.fontBackground;\n var seriesLength = series.chart.series.length;\n if (position === 'Outer' && (series.type.indexOf('Stacking') > -1) && ((seriesLength - 1) > series.index)) {\n var nextSeries = void 0;\n var nextSeriesPoint = void 0;\n for (var i = series.index + 1; i < seriesLength; i++) {\n nextSeries = series.chart.series[i];\n nextSeriesPoint = nextSeries.points[point.index];\n if ((nextSeries.type.indexOf('Stacking') > -1) && (nextSeries.type.indexOf('100') === -1)) {\n this.fontBackground = (nextSeriesPoint && ((nextSeriesPoint.yValue < 0 && point.yValue < 0) ||\n (nextSeriesPoint.yValue > 0 && point.yValue > 0))) ? (nextSeriesPoint ? nextSeriesPoint.color :\n nextSeries.interior) : this.fontBackground;\n break;\n }\n }\n }\n return labelLocation;\n };\n DataLabel.prototype.calculatePathPosition = function (labelLocation, position, series, point, size, labelIndex) {\n var padding = 5;\n if ((series.type.indexOf('Area') > -1 && series.type !== 'RangeArea' && series.type !== 'SplineRangeArea' && series.type !== 'RangeStepArea')\n && this.yAxisInversed && series.marker.dataLabel.position !== 'Auto') {\n position = position === 'Top' ? 'Bottom' : position === 'Bottom' ? 'Top' : position;\n }\n this.fontBackground = this.fontBackground === 'transparent' ? this.chartBackground : this.fontBackground;\n switch (position) {\n case 'Top':\n case 'Outer':\n labelLocation = labelLocation - this.markerHeight - this.borderWidth - size.height / 2 - this.margin.bottom - padding -\n this.errorHeight;\n break;\n case 'Bottom':\n labelLocation = labelLocation + this.markerHeight + this.borderWidth + size.height / 2 + this.margin.top + padding +\n this.errorHeight;\n break;\n case 'Auto':\n labelLocation = this.calculatePathActualPosition(labelLocation, this.markerHeight, series, point, size, labelIndex);\n break;\n }\n return labelLocation;\n };\n DataLabel.prototype.isDataLabelShape = function (style) {\n this.isShape = (style.color !== 'transparent' || style.border.width > 0);\n this.borderWidth = style.border.width;\n if (!this.isShape) {\n this.margin = { left: 0, right: 0, bottom: 0, top: 0 };\n }\n };\n DataLabel.prototype.calculateRectActualPosition = function (labelLocation, rect, isMinus, series, size, labelIndex, point) {\n var location;\n var labelRect;\n var isOverLap = true;\n var position = 0;\n var collection = this.chart.dataLabelCollections;\n var finalPosition = series.type.indexOf('Range') !== -1 || series.type === 'Hilo' ? 2 : 4;\n while (isOverLap && position < finalPosition) {\n var actualPosition = this.getPosition(position);\n if (series.type.indexOf('Stacking') > -1 && actualPosition === 'Outer') {\n actualPosition = 'Top';\n position++;\n }\n location = this.calculateRectPosition(labelLocation, rect, isMinus, actualPosition, series, size, labelIndex, point);\n if (!this.inverted) {\n labelRect = calculateRect(new ChartLocation(this.locationX, location), size, this.margin);\n isOverLap = labelRect.y < 0 || isCollide(labelRect, collection, series.clipRect) || labelRect.y > series.clipRect.height;\n }\n else {\n labelRect = calculateRect(new ChartLocation(location, this.locationY), size, this.margin);\n isOverLap = labelRect.x < 0 || isCollide(labelRect, collection, series.clipRect) ||\n labelRect.x + labelRect.width > series.clipRect.width;\n }\n position++;\n }\n return location;\n };\n // alignment calculation assigned here\n DataLabel.prototype.calculateAlignment = function (value, labelLocation, alignment, isMinus) {\n switch (alignment) {\n case 'Far':\n labelLocation = !this.inverted ? (isMinus ? labelLocation + value : labelLocation - value) :\n (isMinus ? labelLocation - value : labelLocation + value);\n break;\n case 'Near':\n labelLocation = !this.inverted ? (isMinus ? labelLocation - value : labelLocation + value) :\n (isMinus ? labelLocation + value : labelLocation - value);\n break;\n // eslint-disable-next-line no-self-assign\n case 'Center':\n labelLocation = labelLocation;\n break;\n }\n return labelLocation;\n };\n //calculation for top and outer position of datalabel for rect series\n DataLabel.prototype.calculateTopAndOuterPosition = function (location, rect, position, series, index, extraSpace, isMinus) {\n var margin = this.margin;\n var top;\n switch (series.type) {\n case 'RangeColumn':\n case 'RangeArea':\n case 'RangeStepArea':\n case 'SplineRangeArea':\n case 'Hilo':\n top = (index === 0 && !this.yAxisInversed) || (index === 1 && this.yAxisInversed);\n location = this.updateLabelLocation(position, location, extraSpace, margin, rect, top);\n break;\n case 'Candle':\n top = (index === 0 || index === 2) && !this.yAxisInversed\n || (index === 1 || index === 3) && this.yAxisInversed;\n location = this.updateLabelLocation(position, location, extraSpace, margin, rect, top, index > 1);\n break;\n case 'HiloOpenClose':\n if (index <= 1) {\n top = (index === 0 && !this.yAxisInversed) || (index === 1 && this.yAxisInversed);\n location = this.updateLabelLocation(position, location, extraSpace, margin, rect, top);\n }\n else {\n if (this.yAxisInversed) {\n location = !this.inverted ? location + extraSpace + margin.top : location - extraSpace - margin.right;\n }\n else {\n location = !this.inverted ? location - extraSpace - margin.bottom : location + extraSpace + margin.left;\n }\n }\n break;\n default:\n if ((isMinus && position === 'Top') || (!isMinus && position === 'Outer')) {\n location = !this.inverted ? location + (isMinus && series.type === 'Waterfall' ? (-rect.height + extraSpace + margin.bottom) : (-extraSpace - margin.bottom - this.markerHeight)) :\n location + (isMinus && series.type === 'Waterfall' ? (+rect.width - extraSpace - margin.left) : (+extraSpace + margin.left + this.markerHeight));\n }\n else {\n location = !this.inverted ? location + (isMinus && series.type === 'Waterfall' ? (-rect.height - extraSpace - margin.top) : (+extraSpace + margin.top + this.markerHeight)) :\n location + (isMinus && series.type === 'Waterfall' ? (+rect.width + extraSpace + margin.top) : (-extraSpace - margin.right - this.markerHeight));\n }\n break;\n }\n return location;\n };\n /**\n * Updates the label location\n */\n DataLabel.prototype.updateLabelLocation = function (position, location, extraSpace, margin, rect, top, inside) {\n if (inside === void 0) { inside = false; }\n if (!this.inverted) {\n if (top) {\n location = (position === 'Outer' && !inside) ? location - extraSpace - margin.bottom - this.markerHeight :\n location + extraSpace + margin.top + this.markerHeight;\n }\n else {\n location = (position === 'Outer' && !inside) ? location + rect.height + extraSpace + margin.top + this.markerHeight :\n location + rect.height - extraSpace - margin.bottom - this.markerHeight;\n }\n }\n else {\n if (top) {\n location = (position === 'Outer' && !inside) ? location + extraSpace + margin.left + this.markerHeight :\n location - extraSpace - margin.right - this.markerHeight;\n }\n else {\n location = (position === 'Outer' && !inside) ? location - rect.width - extraSpace - margin.right - this.markerHeight :\n location - rect.width + extraSpace + margin.left + this.markerHeight;\n }\n }\n return location;\n };\n DataLabel.prototype.calculatePathActualPosition = function (y, markerSize, series, point, size, labelIndex) {\n var points = series.points;\n var index = point.index;\n var yValue = points[index].yValue;\n var position;\n var nextPoint = points.length - 1 > index ? points[index + 1] : null;\n var previousPoint = index > 0 ? points[index - 1] : null;\n var yLocation;\n var isOverLap = true;\n var labelRect;\n var isBottom;\n var positionIndex;\n var collection = this.chart.dataLabelCollections;\n if (series.type === 'Bubble') {\n position = 'Top';\n }\n else if (series.type.indexOf('Step') > -1) {\n position = 'Top';\n if (index) {\n position = (!previousPoint || !previousPoint.visible || (yValue > previousPoint.yValue !== this.yAxisInversed)\n || yValue === previousPoint.yValue) ? 'Top' : 'Bottom';\n }\n }\n else if (series.type === 'BoxAndWhisker') {\n if (labelIndex === 1 || labelIndex === 3 || labelIndex > 4) {\n position = series.yAxis.isAxisInverse ? 'Bottom' : 'Top';\n }\n else if (labelIndex === 2 || labelIndex === 4) {\n position = series.yAxis.isAxisInverse ? 'Top' : 'Bottom';\n }\n else {\n isOverLap = false;\n position = 'Middle';\n yLocation = this.calculatePathPosition(y, position, series, point, size, labelIndex);\n }\n }\n else {\n if (index === 0) {\n position = (!nextPoint || !nextPoint.visible || yValue > nextPoint.yValue ||\n (yValue < nextPoint.yValue && this.yAxisInversed)) ? 'Top' : 'Bottom';\n }\n else if (index === points.length - 1) {\n position = (!previousPoint || !previousPoint.visible || yValue > previousPoint.yValue ||\n (yValue < previousPoint.yValue && this.yAxisInversed)) ? 'Top' : 'Bottom';\n }\n else {\n if (!nextPoint.visible && !(previousPoint && previousPoint.visible)) {\n position = 'Top';\n }\n else if (!nextPoint.visible || !previousPoint) {\n position = (nextPoint.yValue > yValue || (previousPoint && previousPoint.yValue > yValue)) ?\n 'Bottom' : 'Top';\n }\n else {\n var slope = (nextPoint.yValue - previousPoint.yValue) / 2;\n var intersectY = (slope * index) + (nextPoint.yValue - (slope * (index + 1)));\n position = !this.yAxisInversed ? intersectY < yValue ? 'Top' : 'Bottom' :\n intersectY < yValue ? 'Bottom' : 'Top';\n }\n }\n }\n isBottom = position === 'Bottom';\n positionIndex = ['Outer', 'Top', 'Bottom', 'Middle', 'Auto'].indexOf(position);\n while (isOverLap && positionIndex < 4) {\n yLocation = this.calculatePathPosition(y, this.getPosition(positionIndex), series, point, size, labelIndex);\n labelRect = calculateRect(new ChartLocation(this.locationX, yLocation), size, this.margin);\n isOverLap = labelRect.y < 0 || isCollide(labelRect, collection, series.clipRect)\n || (labelRect.y + labelRect.height) > series.clipRect.height;\n positionIndex = isBottom ? positionIndex - 1 : positionIndex + 1;\n isBottom = false;\n }\n return yLocation;\n };\n /**\n * Animates the data label.\n *\n * @param {Series} series - Data label of the series gets animated.\n * @returns {void}\n */\n DataLabel.prototype.doDataLabelAnimation = function (series, element) {\n var shapeElements = series.shapeElement.childNodes;\n var textNode = series.textElement.childNodes;\n var delay = series.animation.delay + series.animation.duration;\n var duration = series.chart.animated ? series.chart.duration : 200;\n var location;\n var length = element ? 1 : textNode.length;\n var tempElement;\n for (var i = 0; i < length; i++) {\n tempElement = textNode[i];\n if (element) {\n element.style.visibility = 'hidden';\n templateAnimate(element, delay, duration, 'ZoomIn');\n }\n else {\n location = new ChartLocation((+tempElement.getAttribute('x')) + ((+tempElement.getAttribute('width')) / 2), (+tempElement.getAttribute('y')) + ((+tempElement.getAttribute('height')) / 2));\n markerAnimate(tempElement, delay, duration, series, null, location, true);\n if (shapeElements[i]) {\n tempElement = shapeElements[i];\n location = new ChartLocation((+tempElement.getAttribute('x')) + ((+tempElement.getAttribute('width')) / 2), (+tempElement.getAttribute('y')) + ((+tempElement.getAttribute('height')) / 2));\n markerAnimate(tempElement, delay, duration, series, null, location, true);\n }\n }\n }\n };\n DataLabel.prototype.getPosition = function (index) {\n return (['Outer', 'Top', 'Bottom', 'Middle', 'Auto'][index]);\n };\n /**\n * Get module name.\n */\n DataLabel.prototype.getModuleName = function () {\n // Returns the module name\n return 'DataLabel';\n };\n /**\n * To destroy the dataLabel for series.\n *\n * @returns {void}\n * @private\n */\n DataLabel.prototype.destroy = function () {\n // Destroy method performed here\n };\n return DataLabel;\n}());\nexport { DataLabel };\n","//! moment.js locale configuration\n//! locale : Pseudo [x-pseudo]\n//! author : Andrew Hood : https://github.com/andrewhood125\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var xPseudo = moment.defineLocale('x-pseudo', {\n months: 'J~áñúá~rý_F~ébrú~árý_~Márc~h_Ãp~rÃl_~Máý_~Júñé~_Júl~ý_Ãú~gúst~_Sép~témb~ér_Ó~ctób~ér_Ñ~óvém~bér_~Décé~mbér'.split(\n '_'\n ),\n monthsShort:\n 'J~áñ_~Féb_~Már_~Ãpr_~Máý_~Júñ_~Júl_~Ãúg_~Sép_~Óct_~Ñóv_~Déc'.split(\n '_'\n ),\n monthsParseExact: true,\n weekdays:\n 'S~úñdá~ý_Mó~ñdáý~_Túé~sdáý~_Wéd~ñésd~áý_T~húrs~dáý_~FrÃd~áý_S~átúr~dáý'.split(\n '_'\n ),\n weekdaysShort: 'S~úñ_~Móñ_~Túé_~Wéd_~Thú_~FrÃ_~Sát'.split('_'),\n weekdaysMin: 'S~ú_Mó~_Tú_~Wé_T~h_Fr~_Sá'.split('_'),\n weekdaysParseExact: true,\n longDateFormat: {\n LT: 'HH:mm',\n L: 'DD/MM/YYYY',\n LL: 'D MMMM YYYY',\n LLL: 'D MMMM YYYY HH:mm',\n LLLL: 'dddd, D MMMM YYYY HH:mm',\n },\n calendar: {\n sameDay: '[T~ódá~ý át] LT',\n nextDay: '[T~ómó~rró~w át] LT',\n nextWeek: 'dddd [át] LT',\n lastDay: '[Ã~ést~érdá~ý át] LT',\n lastWeek: '[L~ást] dddd [át] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: 'Ã~ñ %s',\n past: '%s á~gó',\n s: 'á ~féw ~sécó~ñds',\n ss: '%d s~écóñ~ds',\n m: 'á ~mÃñ~úté',\n mm: '%d m~Ãñú~tés',\n h: 'á~ñ hó~úr',\n hh: '%d h~óúrs',\n d: 'á ~dáý',\n dd: '%d d~áýs',\n M: 'á ~móñ~th',\n MM: '%d m~óñt~hs',\n y: 'á ~ýéár',\n yy: '%d ý~éárs',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}(th|st|nd|rd)/,\n ordinal: function (number) {\n var b = number % 10,\n output =\n ~~((number % 100) / 10) === 1\n ? 'th'\n : b === 1\n ? 'st'\n : b === 2\n ? 'nd'\n : b === 3\n ? 'rd'\n : 'th';\n return number + output;\n },\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return xPseudo;\n\n})));\n","//! moment.js locale configuration\n//! locale : Northern Sami [se]\n//! authors : BÃ¥rd Rolstad Henriksen : https://github.com/karamell\n\n;(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined'\n && typeof require === 'function' ? factory(require('../moment')) :\n typeof define === 'function' && define.amd ? define(['../moment'], factory) :\n factory(global.moment)\n}(this, (function (moment) { 'use strict';\n\n //! moment.js locale configuration\n\n var se = moment.defineLocale('se', {\n months: 'oÄ‘Ä‘ajagemánnu_guovvamánnu_njukÄamánnu_cuoÅ‹ománnu_miessemánnu_geassemánnu_suoidnemánnu_borgemánnu_ÄakÄamánnu_golggotmánnu_skábmamánnu_juovlamánnu'.split(\n '_'\n ),\n monthsShort:\n 'oÄ‘Ä‘j_guov_njuk_cuo_mies_geas_suoi_borg_ÄakÄ_golg_skáb_juov'.split('_'),\n weekdays:\n 'sotnabeaivi_vuossárga_maÅ‹Å‹ebárga_gaskavahkku_duorastat_bearjadat_lávvardat'.split(\n '_'\n ),\n weekdaysShort: 'sotn_vuos_maÅ‹_gask_duor_bear_láv'.split('_'),\n weekdaysMin: 's_v_m_g_d_b_L'.split('_'),\n longDateFormat: {\n LT: 'HH:mm',\n LTS: 'HH:mm:ss',\n L: 'DD.MM.YYYY',\n LL: 'MMMM D. [b.] YYYY',\n LLL: 'MMMM D. [b.] YYYY [ti.] HH:mm',\n LLLL: 'dddd, MMMM D. [b.] YYYY [ti.] HH:mm',\n },\n calendar: {\n sameDay: '[otne ti] LT',\n nextDay: '[ihttin ti] LT',\n nextWeek: 'dddd [ti] LT',\n lastDay: '[ikte ti] LT',\n lastWeek: '[ovddit] dddd [ti] LT',\n sameElse: 'L',\n },\n relativeTime: {\n future: '%s geažes',\n past: 'maÅ‹it %s',\n s: 'moadde sekunddat',\n ss: '%d sekunddat',\n m: 'okta minuhta',\n mm: '%d minuhtat',\n h: 'okta diimmu',\n hh: '%d diimmut',\n d: 'okta beaivi',\n dd: '%d beaivvit',\n M: 'okta mánnu',\n MM: '%d mánut',\n y: 'okta jahki',\n yy: '%d jagit',\n },\n dayOfMonthOrdinalParse: /\\d{1,2}\\./,\n ordinal: '%d.',\n week: {\n dow: 1, // Monday is the first day of the week.\n doy: 4, // The week that contains Jan 4th is the first week of the year.\n },\n });\n\n return se;\n\n})));\n"],"sourceRoot":""}