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

@grapecity/wijmo.grid.grouppanel

Package Overview
Dependencies
Maintainers
1
Versions
1292
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@grapecity/wijmo.grid.grouppanel - npm Package Compare versions

Comparing version 5.20183.595-nightly.d20190405.t210807 to 5.20183.595-nightly.d20190406.t001954

15

es2015-commonjs.js

@@ -1,14 +0,1 @@

/*!
*
* Wijmo Library 5.20183.595-nightly.d20190405.t210807
* http://wijmo.com/
*
* Copyright(c) GrapeCity, Inc. All rights reserved.
*
* Licensed under the GrapeCity Commercial License.
* sales@wijmo.com
* wijmo.com/products/wijmo-5/license/
*
*/
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const wijmo_1=require("@grapecity/wijmo"),wijmo_grid_1=require("@grapecity/wijmo.grid"),wijmo_grid_filter_1=require("@grapecity/wijmo.grid.filter"),selfModule=require("@grapecity/wijmo.grid.grouppanel");class GroupPanel extends wijmo_1.Control{constructor(e,t){super(e),this._hideGroupedCols=!0,this._showDragGlyphs=!0,this._maxGroups=6,this._hiddenCols=[];let i=this.getTemplate();this.applyTemplate("wj-grouppanel wj-control",i,{_divMarkers:"div-markers",_divPH:"div-ph"});let r=this.hostElement;this.addEventListener(r,"dragstart",this._dragStart.bind(this)),this.addEventListener(r,"dragover",this._dragOver.bind(this)),this.addEventListener(r,"drop",this._drop.bind(this)),this.addEventListener(r,"dragend",this._dragEnd.bind(this)),this.addEventListener(r,"click",this._click.bind(this)),this.initialize(t)}get hideGroupedColumns(){return this._hideGroupedCols}set hideGroupedColumns(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=wijmo_1.asBoolean(e))}get showDragGlyphs(){return this._showDragGlyphs}set showDragGlyphs(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=wijmo_1.asBoolean(e),this.refresh())}get maxGroups(){return this._maxGroups}set maxGroups(e){if(e!=this._maxGroups){this._maxGroups=wijmo_1.asNumber(e);let t=this._gds,i=this._maxGroups;t&&i>-1&&i<t.length&&t.splice(i,t.length-i)}}get placeholder(){return this._divPH.textContent}set placeholder(e){this._divPH.textContent=e}get grid(){return this._g}set grid(e){if((e=wijmo_1.asType(e,wijmo_grid_1.FlexGrid,!0))!=this._g){let t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}}get filter(){return this._filter}set filter(e){if((e=wijmo_1.asType(e,wijmo_grid_filter_1.FlexGridFilter,!0))!=this._filter){let t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}}refresh(){if(super.refresh(),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){let t=this._g,i=t.columnHeaders;for(let r=0;r<this._gds.length;r++){let s=this._gds[r],l=-1,n=-1;for(let e=i.rows.length-1;e>=0&&n<0;e--)for(let r=0;r<i.columns.length&&n<0;r++){let o=t._getBindingColumn(i,e,i.columns[r]);if(o&&o.binding==s.propertyName){n=r,l=e;break}}if(n>-1&&l>-1){let r=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,l,n,r),r.setAttribute("class","wj-cell wj-header wj-groupmarker"),wijmo_1.setCss(r,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var e=wijmo_1.createElement('<span class="wj-glyph-drag"></span>');r.insertBefore(e,r.firstChild)}let s=r.querySelector(".wj-elem-filter");s&&wijmo_1.removeChild(s);let o=this._getColumnFilter(i.columns[n]);o&&(s=wijmo_1.createElement('<span class="wj-filter wj-glyph-filter"></span>',r),wijmo_1.toggleClass(s,"wj-filter-on",o.isActive),wijmo_1.toggleClass(s,"wj-filter-off",!o.isActive)),wijmo_1.createElement('<span class="wj-remove">&times;</span>',r),this._divMarkers.appendChild(r)}}let r=this._divMarkers.children.length>0;this._divPH.style.display=r?"none":"",this._divMarkers.style.display=r?"":"none"}}_getColumnFilter(e){let t=this._filter,i=null;return t&&(i=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),i}_editFilter(e){let t=this._gds,i=this._getElementIndex(e),r=t&&i>-1?t[i]:null,s=r?r.propertyName:null,l=s?this._g.columns.getColumn(s):null;l&&this._filter.editColumnFilter(l,null,e)}_addGroup(e,t){let i=this._getIndex(t),r=this._gds,s=this._maxGroups;for(let t=0;t<r.length;t++)if(r[t].propertyName==e.binding){r.removeAt(t),t<i&&i--;break}if(s>-1)for(let e=s-1;e<r.length;e++)this._removeGroup(e,r),e<i&&i--;(s<0||r.length<s)&&(r.deferUpdate(()=>{let t=new wijmo_1.PropertyGroupDescription(e.binding);r.insert(i,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))}_moveGroup(e,t){let i=this._gds,r=this._getElementIndex(this._dragMarker),s=this._getIndex(t);s>r&&s--,s>=this._gds.length&&(s=this._gds.length),r!=s&&i.deferUpdate(()=>{let e=i[r];i.removeAt(r),i.insert(s,e)})}_removeGroup(e,t=this._gds){let i=null;t&&e>-1&&(i=t[e],t.removeAt(e));let r=i?i.propertyName:null,s=r?this._g.columns.getColumn(r):null;if(s){s.visible=!0;let e=this._hiddenCols.indexOf(s);e>-1&&this._hiddenCols.splice(e,1)}}_getIndex(e){let t=e.clientX,i=this._divMarkers.children;for(let e=0;e<i.length;e++){let r=i[e].getBoundingClientRect();if((t-r.left)*(t-r.right)<0)return e}return i.length}_getElementIndex(e){if(e&&e.parentElement){let t=e.parentElement.children;for(let i=0;i<t.length;i++)if(t[i]==e)return i}return-1}_draggingColumn(e,t){let i=this._g,r=i._getBindingColumn(t.panel,t.row,i.columns[t.col]);this._dragCol=r.binding?r:null}_itemsSourceChanging(e,t){this._hiddenCols.forEach(e=>{e.visible=!0}),this._hiddenCols=[]}_itemsSourceChanged(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()}_collectionChanged(e,t){t.action==wijmo_1.NotifyCollectionChangedAction.Reset&&this.invalidate()}_dragStart(e){wijmo_1._startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null}_dragOver(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())}_drop(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)}_dragEnd(e){this._dragMarker=this._dragCol=null}_click(e){let t=e.target,i=wijmo_1.hasClass(t,"wj-remove"),r=wijmo_1.hasClass(t,"wj-filter"),s=wijmo_1.closest(t,".wj-cell");if(wijmo_1.hasClass(s,"wj-cell")){let t=this._getElementIndex(s),l=this._g.collectionView.sortDescriptions;if(r)this._editFilter(s);else if(i)this._removeGroup(t);else if(e.ctrlKey)l.clear();else{let e=this._gds[t],i=!0;for(let t=0;t<l.length;t++)if(l[t].property==e.propertyName){i=!l[t].ascending;break}let r=new wijmo_1.SortDescription(e.propertyName,i);l.splice(0,l.length,r)}}}}GroupPanel.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',exports.GroupPanel=GroupPanel,wijmo_1._registerModule("wijmo.grid.grouppanel",selfModule);
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const wijmo_1=require("@grapecity/wijmo"),wijmo_grid_1=require("@grapecity/wijmo.grid"),wijmo_grid_filter_1=require("@grapecity/wijmo.grid.filter"),selfModule=require("@grapecity/wijmo.grid.grouppanel");class GroupPanel extends wijmo_1.Control{constructor(e,t){super(e),this._hideGroupedCols=!0,this._showDragGlyphs=!0,this._maxGroups=6,this._hiddenCols=[];let i=this.getTemplate();this.applyTemplate("wj-grouppanel wj-control",i,{_divMarkers:"div-markers",_divPH:"div-ph"});let r=this.hostElement;this.addEventListener(r,"dragstart",this._dragStart.bind(this)),this.addEventListener(r,"dragover",this._dragOver.bind(this)),this.addEventListener(r,"drop",this._drop.bind(this)),this.addEventListener(r,"dragend",this._dragEnd.bind(this)),this.addEventListener(r,"click",this._click.bind(this)),this.initialize(t)}get hideGroupedColumns(){return this._hideGroupedCols}set hideGroupedColumns(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=wijmo_1.asBoolean(e))}get showDragGlyphs(){return this._showDragGlyphs}set showDragGlyphs(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=wijmo_1.asBoolean(e),this.refresh())}get maxGroups(){return this._maxGroups}set maxGroups(e){if(e!=this._maxGroups){this._maxGroups=wijmo_1.asNumber(e);let t=this._gds,i=this._maxGroups;t&&i>-1&&i<t.length&&t.splice(i,t.length-i)}}get placeholder(){return this._divPH.textContent}set placeholder(e){this._divPH.textContent=e}get grid(){return this._g}set grid(e){if((e=wijmo_1.asType(e,wijmo_grid_1.FlexGrid,!0))!=this._g){let t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}}get filter(){return this._filter}set filter(e){if((e=wijmo_1.asType(e,wijmo_grid_filter_1.FlexGridFilter,!0))!=this._filter){let t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}}refresh(){if(super.refresh(),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){let t=this._g,i=t.columnHeaders;for(let r=0;r<this._gds.length;r++){let s=this._gds[r],l=-1,n=-1;for(let e=i.rows.length-1;e>=0&&n<0;e--)for(let r=0;r<i.columns.length&&n<0;r++){let o=t._getBindingColumn(i,e,i.columns[r]);if(o&&o.binding==s.propertyName){n=r,l=e;break}}if(n>-1&&l>-1){let r=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,l,n,r),r.setAttribute("class","wj-cell wj-header wj-groupmarker"),wijmo_1.setCss(r,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var e=wijmo_1.createElement('<span class="wj-glyph-drag"></span>');r.insertBefore(e,r.firstChild)}let s=r.querySelector(".wj-elem-filter");s&&wijmo_1.removeChild(s);let o=this._getColumnFilter(i.columns[n]);o&&(s=wijmo_1.createElement('<span class="wj-filter wj-glyph-filter"></span>',r),wijmo_1.toggleClass(s,"wj-filter-on",o.isActive),wijmo_1.toggleClass(s,"wj-filter-off",!o.isActive)),wijmo_1.createElement('<span class="wj-remove">&times;</span>',r),this._divMarkers.appendChild(r)}}let r=this._divMarkers.children.length>0;this._divPH.style.display=r?"none":"",this._divMarkers.style.display=r?"":"none"}}_getColumnFilter(e){let t=this._filter,i=null;return t&&(i=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),i}_editFilter(e){let t=this._gds,i=this._getElementIndex(e),r=t&&i>-1?t[i]:null,s=r?r.propertyName:null,l=s?this._g.columns.getColumn(s):null;l&&this._filter.editColumnFilter(l,null,e)}_addGroup(e,t){let i=this._getIndex(t),r=this._gds,s=this._maxGroups;for(let t=0;t<r.length;t++)if(r[t].propertyName==e.binding){r.removeAt(t),t<i&&i--;break}if(s>-1)for(let e=s-1;e<r.length;e++)this._removeGroup(e,r),e<i&&i--;(s<0||r.length<s)&&(r.deferUpdate(()=>{let t=new wijmo_1.PropertyGroupDescription(e.binding);r.insert(i,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))}_moveGroup(e,t){let i=this._gds,r=this._getElementIndex(this._dragMarker),s=this._getIndex(t);s>r&&s--,s>=this._gds.length&&(s=this._gds.length),r!=s&&i.deferUpdate(()=>{let e=i[r];i.removeAt(r),i.insert(s,e)})}_removeGroup(e,t=this._gds){let i=null;t&&e>-1&&(i=t[e],t.removeAt(e));let r=i?i.propertyName:null,s=r?this._g.columns.getColumn(r):null;if(s){s.visible=!0;let e=this._hiddenCols.indexOf(s);e>-1&&this._hiddenCols.splice(e,1)}}_getIndex(e){let t=e.clientX,i=this._divMarkers.children;for(let e=0;e<i.length;e++){let r=i[e].getBoundingClientRect();if((t-r.left)*(t-r.right)<0)return e}return i.length}_getElementIndex(e){if(e&&e.parentElement){let t=e.parentElement.children;for(let i=0;i<t.length;i++)if(t[i]==e)return i}return-1}_draggingColumn(e,t){let i=this._g,r=i._getBindingColumn(t.panel,t.row,i.columns[t.col]);this._dragCol=r.binding?r:null}_itemsSourceChanging(e,t){this._hiddenCols.forEach(e=>{e.visible=!0}),this._hiddenCols=[]}_itemsSourceChanged(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()}_collectionChanged(e,t){t.action==wijmo_1.NotifyCollectionChangedAction.Reset&&this.invalidate()}_dragStart(e){wijmo_1._startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null}_dragOver(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())}_drop(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)}_dragEnd(e){this._dragMarker=this._dragCol=null}_click(e){let t=e.target,i=wijmo_1.hasClass(t,"wj-remove"),r=wijmo_1.hasClass(t,"wj-filter"),s=wijmo_1.closest(t,".wj-cell");if(wijmo_1.hasClass(s,"wj-cell")){let t=this._getElementIndex(s),l=this._g.collectionView.sortDescriptions;if(r)this._editFilter(s);else if(i)this._removeGroup(t);else if(e.ctrlKey)l.clear();else{let e=this._gds[t],i=!0;for(let t=0;t<l.length;t++)if(l[t].property==e.propertyName){i=!l[t].ascending;break}let r=new wijmo_1.SortDescription(e.propertyName,i);l.splice(0,l.length,r)}}}}GroupPanel.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',exports.GroupPanel=GroupPanel,wijmo_1._registerModule("wijmo.grid.grouppanel",selfModule);

@@ -1,14 +0,1 @@

/*!
*
* Wijmo Library 5.20183.595-nightly.d20190405.t210807
* http://wijmo.com/
*
* Copyright(c) GrapeCity, Inc. All rights reserved.
*
* Licensed under the GrapeCity Commercial License.
* sales@wijmo.com
* wijmo.com/products/wijmo-5/license/
*
*/
import{Control,asBoolean,asNumber,asType,setCss,toggleClass,createElement,removeChild,_startDrag,hasClass,closest,PropertyGroupDescription,SortDescription,NotifyCollectionChangedAction,_registerModule}from"@grapecity/wijmo";import{FlexGrid}from"@grapecity/wijmo.grid";import{FlexGridFilter}from"@grapecity/wijmo.grid.filter";import*as selfModule from"@grapecity/wijmo.grid.grouppanel";export class GroupPanel extends Control{constructor(e,t){super(e),this._hideGroupedCols=!0,this._showDragGlyphs=!0,this._maxGroups=6,this._hiddenCols=[];let i=this.getTemplate();this.applyTemplate("wj-grouppanel wj-control",i,{_divMarkers:"div-markers",_divPH:"div-ph"});let r=this.hostElement;this.addEventListener(r,"dragstart",this._dragStart.bind(this)),this.addEventListener(r,"dragover",this._dragOver.bind(this)),this.addEventListener(r,"drop",this._drop.bind(this)),this.addEventListener(r,"dragend",this._dragEnd.bind(this)),this.addEventListener(r,"click",this._click.bind(this)),this.initialize(t)}get hideGroupedColumns(){return this._hideGroupedCols}set hideGroupedColumns(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=asBoolean(e))}get showDragGlyphs(){return this._showDragGlyphs}set showDragGlyphs(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=asBoolean(e),this.refresh())}get maxGroups(){return this._maxGroups}set maxGroups(e){if(e!=this._maxGroups){this._maxGroups=asNumber(e);let t=this._gds,i=this._maxGroups;t&&i>-1&&i<t.length&&t.splice(i,t.length-i)}}get placeholder(){return this._divPH.textContent}set placeholder(e){this._divPH.textContent=e}get grid(){return this._g}set grid(e){if((e=asType(e,FlexGrid,!0))!=this._g){let t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}}get filter(){return this._filter}set filter(e){if((e=asType(e,FlexGridFilter,!0))!=this._filter){let t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}}refresh(){if(super.refresh(),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){let t=this._g,i=t.columnHeaders;for(let r=0;r<this._gds.length;r++){let s=this._gds[r],l=-1,n=-1;for(let e=i.rows.length-1;e>=0&&n<0;e--)for(let r=0;r<i.columns.length&&n<0;r++){let o=t._getBindingColumn(i,e,i.columns[r]);if(o&&o.binding==s.propertyName){n=r,l=e;break}}if(n>-1&&l>-1){let r=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,l,n,r),r.setAttribute("class","wj-cell wj-header wj-groupmarker"),setCss(r,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var e=createElement('<span class="wj-glyph-drag"></span>');r.insertBefore(e,r.firstChild)}let s=r.querySelector(".wj-elem-filter");s&&removeChild(s);let o=this._getColumnFilter(i.columns[n]);o&&(s=createElement('<span class="wj-filter wj-glyph-filter"></span>',r),toggleClass(s,"wj-filter-on",o.isActive),toggleClass(s,"wj-filter-off",!o.isActive)),createElement('<span class="wj-remove">&times;</span>',r),this._divMarkers.appendChild(r)}}let r=this._divMarkers.children.length>0;this._divPH.style.display=r?"none":"",this._divMarkers.style.display=r?"":"none"}}_getColumnFilter(e){let t=this._filter,i=null;return t&&(i=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),i}_editFilter(e){let t=this._gds,i=this._getElementIndex(e),r=t&&i>-1?t[i]:null,s=r?r.propertyName:null,l=s?this._g.columns.getColumn(s):null;l&&this._filter.editColumnFilter(l,null,e)}_addGroup(e,t){let i=this._getIndex(t),r=this._gds,s=this._maxGroups;for(let t=0;t<r.length;t++)if(r[t].propertyName==e.binding){r.removeAt(t),t<i&&i--;break}if(s>-1)for(let e=s-1;e<r.length;e++)this._removeGroup(e,r),e<i&&i--;(s<0||r.length<s)&&(r.deferUpdate(()=>{let t=new PropertyGroupDescription(e.binding);r.insert(i,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))}_moveGroup(e,t){let i=this._gds,r=this._getElementIndex(this._dragMarker),s=this._getIndex(t);s>r&&s--,s>=this._gds.length&&(s=this._gds.length),r!=s&&i.deferUpdate(()=>{let e=i[r];i.removeAt(r),i.insert(s,e)})}_removeGroup(e,t=this._gds){let i=null;t&&e>-1&&(i=t[e],t.removeAt(e));let r=i?i.propertyName:null,s=r?this._g.columns.getColumn(r):null;if(s){s.visible=!0;let e=this._hiddenCols.indexOf(s);e>-1&&this._hiddenCols.splice(e,1)}}_getIndex(e){let t=e.clientX,i=this._divMarkers.children;for(let e=0;e<i.length;e++){let r=i[e].getBoundingClientRect();if((t-r.left)*(t-r.right)<0)return e}return i.length}_getElementIndex(e){if(e&&e.parentElement){let t=e.parentElement.children;for(let i=0;i<t.length;i++)if(t[i]==e)return i}return-1}_draggingColumn(e,t){let i=this._g,r=i._getBindingColumn(t.panel,t.row,i.columns[t.col]);this._dragCol=r.binding?r:null}_itemsSourceChanging(e,t){this._hiddenCols.forEach(e=>{e.visible=!0}),this._hiddenCols=[]}_itemsSourceChanged(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()}_collectionChanged(e,t){t.action==NotifyCollectionChangedAction.Reset&&this.invalidate()}_dragStart(e){_startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null}_dragOver(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())}_drop(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)}_dragEnd(e){this._dragMarker=this._dragCol=null}_click(e){let t=e.target,i=hasClass(t,"wj-remove"),r=hasClass(t,"wj-filter"),s=closest(t,".wj-cell");if(hasClass(s,"wj-cell")){let t=this._getElementIndex(s),l=this._g.collectionView.sortDescriptions;if(r)this._editFilter(s);else if(i)this._removeGroup(t);else if(e.ctrlKey)l.clear();else{let e=this._gds[t],i=!0;for(let t=0;t<l.length;t++)if(l[t].property==e.propertyName){i=!l[t].ascending;break}let r=new SortDescription(e.propertyName,i);l.splice(0,l.length,r)}}}};GroupPanel.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',_registerModule("wijmo.grid.grouppanel",selfModule);
import{Control,asBoolean,asNumber,asType,setCss,toggleClass,createElement,removeChild,_startDrag,hasClass,closest,PropertyGroupDescription,SortDescription,NotifyCollectionChangedAction,_registerModule}from"@grapecity/wijmo";import{FlexGrid}from"@grapecity/wijmo.grid";import{FlexGridFilter}from"@grapecity/wijmo.grid.filter";import*as selfModule from"@grapecity/wijmo.grid.grouppanel";export class GroupPanel extends Control{constructor(e,t){super(e),this._hideGroupedCols=!0,this._showDragGlyphs=!0,this._maxGroups=6,this._hiddenCols=[];let i=this.getTemplate();this.applyTemplate("wj-grouppanel wj-control",i,{_divMarkers:"div-markers",_divPH:"div-ph"});let r=this.hostElement;this.addEventListener(r,"dragstart",this._dragStart.bind(this)),this.addEventListener(r,"dragover",this._dragOver.bind(this)),this.addEventListener(r,"drop",this._drop.bind(this)),this.addEventListener(r,"dragend",this._dragEnd.bind(this)),this.addEventListener(r,"click",this._click.bind(this)),this.initialize(t)}get hideGroupedColumns(){return this._hideGroupedCols}set hideGroupedColumns(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=asBoolean(e))}get showDragGlyphs(){return this._showDragGlyphs}set showDragGlyphs(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=asBoolean(e),this.refresh())}get maxGroups(){return this._maxGroups}set maxGroups(e){if(e!=this._maxGroups){this._maxGroups=asNumber(e);let t=this._gds,i=this._maxGroups;t&&i>-1&&i<t.length&&t.splice(i,t.length-i)}}get placeholder(){return this._divPH.textContent}set placeholder(e){this._divPH.textContent=e}get grid(){return this._g}set grid(e){if((e=asType(e,FlexGrid,!0))!=this._g){let t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}}get filter(){return this._filter}set filter(e){if((e=asType(e,FlexGridFilter,!0))!=this._filter){let t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}}refresh(){if(super.refresh(),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){let t=this._g,i=t.columnHeaders;for(let r=0;r<this._gds.length;r++){let s=this._gds[r],l=-1,n=-1;for(let e=i.rows.length-1;e>=0&&n<0;e--)for(let r=0;r<i.columns.length&&n<0;r++){let o=t._getBindingColumn(i,e,i.columns[r]);if(o&&o.binding==s.propertyName){n=r,l=e;break}}if(n>-1&&l>-1){let r=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,l,n,r),r.setAttribute("class","wj-cell wj-header wj-groupmarker"),setCss(r,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var e=createElement('<span class="wj-glyph-drag"></span>');r.insertBefore(e,r.firstChild)}let s=r.querySelector(".wj-elem-filter");s&&removeChild(s);let o=this._getColumnFilter(i.columns[n]);o&&(s=createElement('<span class="wj-filter wj-glyph-filter"></span>',r),toggleClass(s,"wj-filter-on",o.isActive),toggleClass(s,"wj-filter-off",!o.isActive)),createElement('<span class="wj-remove">&times;</span>',r),this._divMarkers.appendChild(r)}}let r=this._divMarkers.children.length>0;this._divPH.style.display=r?"none":"",this._divMarkers.style.display=r?"":"none"}}_getColumnFilter(e){let t=this._filter,i=null;return t&&(i=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),i}_editFilter(e){let t=this._gds,i=this._getElementIndex(e),r=t&&i>-1?t[i]:null,s=r?r.propertyName:null,l=s?this._g.columns.getColumn(s):null;l&&this._filter.editColumnFilter(l,null,e)}_addGroup(e,t){let i=this._getIndex(t),r=this._gds,s=this._maxGroups;for(let t=0;t<r.length;t++)if(r[t].propertyName==e.binding){r.removeAt(t),t<i&&i--;break}if(s>-1)for(let e=s-1;e<r.length;e++)this._removeGroup(e,r),e<i&&i--;(s<0||r.length<s)&&(r.deferUpdate(()=>{let t=new PropertyGroupDescription(e.binding);r.insert(i,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))}_moveGroup(e,t){let i=this._gds,r=this._getElementIndex(this._dragMarker),s=this._getIndex(t);s>r&&s--,s>=this._gds.length&&(s=this._gds.length),r!=s&&i.deferUpdate(()=>{let e=i[r];i.removeAt(r),i.insert(s,e)})}_removeGroup(e,t=this._gds){let i=null;t&&e>-1&&(i=t[e],t.removeAt(e));let r=i?i.propertyName:null,s=r?this._g.columns.getColumn(r):null;if(s){s.visible=!0;let e=this._hiddenCols.indexOf(s);e>-1&&this._hiddenCols.splice(e,1)}}_getIndex(e){let t=e.clientX,i=this._divMarkers.children;for(let e=0;e<i.length;e++){let r=i[e].getBoundingClientRect();if((t-r.left)*(t-r.right)<0)return e}return i.length}_getElementIndex(e){if(e&&e.parentElement){let t=e.parentElement.children;for(let i=0;i<t.length;i++)if(t[i]==e)return i}return-1}_draggingColumn(e,t){let i=this._g,r=i._getBindingColumn(t.panel,t.row,i.columns[t.col]);this._dragCol=r.binding?r:null}_itemsSourceChanging(e,t){this._hiddenCols.forEach(e=>{e.visible=!0}),this._hiddenCols=[]}_itemsSourceChanged(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()}_collectionChanged(e,t){t.action==NotifyCollectionChangedAction.Reset&&this.invalidate()}_dragStart(e){_startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null}_dragOver(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())}_drop(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)}_dragEnd(e){this._dragMarker=this._dragCol=null}_click(e){let t=e.target,i=hasClass(t,"wj-remove"),r=hasClass(t,"wj-filter"),s=closest(t,".wj-cell");if(hasClass(s,"wj-cell")){let t=this._getElementIndex(s),l=this._g.collectionView.sortDescriptions;if(r)this._editFilter(s);else if(i)this._removeGroup(t);else if(e.ctrlKey)l.clear();else{let e=this._gds[t],i=!0;for(let t=0;t<l.length;t++)if(l[t].property==e.propertyName){i=!l[t].ascending;break}let r=new SortDescription(e.propertyName,i);l.splice(0,l.length,r)}}}};GroupPanel.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',_registerModule("wijmo.grid.grouppanel",selfModule);

@@ -1,14 +0,1 @@

/*!
*
* Wijmo Library 5.20183.595-nightly.d20190405.t210807
* http://wijmo.com/
*
* Copyright(c) GrapeCity, Inc. All rights reserved.
*
* Licensed under the GrapeCity Commercial License.
* sales@wijmo.com
* wijmo.com/products/wijmo-5/license/
*
*/
var __extends=this&&this.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function i(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(i.prototype=r.prototype,new i)}}();import{Control,asBoolean,asNumber,asType,setCss,toggleClass,createElement,removeChild,_startDrag,hasClass,closest,PropertyGroupDescription,SortDescription,NotifyCollectionChangedAction,_registerModule}from"@grapecity/wijmo";import{FlexGrid}from"@grapecity/wijmo.grid";import{FlexGridFilter}from"@grapecity/wijmo.grid.filter";import*as selfModule from"@grapecity/wijmo.grid.grouppanel";var GroupPanel=function(e){function t(t,r){var i=e.call(this,t)||this;i._hideGroupedCols=!0,i._showDragGlyphs=!0,i._maxGroups=6,i._hiddenCols=[];var n=i.getTemplate();i.applyTemplate("wj-grouppanel wj-control",n,{_divMarkers:"div-markers",_divPH:"div-ph"});var o=i.hostElement;return i.addEventListener(o,"dragstart",i._dragStart.bind(i)),i.addEventListener(o,"dragover",i._dragOver.bind(i)),i.addEventListener(o,"drop",i._drop.bind(i)),i.addEventListener(o,"dragend",i._dragEnd.bind(i)),i.addEventListener(o,"click",i._click.bind(i)),i.initialize(r),i}return __extends(t,e),Object.defineProperty(t.prototype,"hideGroupedColumns",{get:function(){return this._hideGroupedCols},set:function(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=asBoolean(e))},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"showDragGlyphs",{get:function(){return this._showDragGlyphs},set:function(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=asBoolean(e),this.refresh())},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"maxGroups",{get:function(){return this._maxGroups},set:function(e){if(e!=this._maxGroups){this._maxGroups=asNumber(e);var t=this._gds,r=this._maxGroups;t&&r>-1&&r<t.length&&t.splice(r,t.length-r)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"placeholder",{get:function(){return this._divPH.textContent},set:function(e){this._divPH.textContent=e},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"grid",{get:function(){return this._g},set:function(e){if((e=asType(e,FlexGrid,!0))!=this._g){var t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"filter",{get:function(){return this._filter},set:function(e){if((e=asType(e,FlexGridFilter,!0))!=this._filter){var t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}},enumerable:!0,configurable:!0}),t.prototype.refresh=function(){if(e.prototype.refresh.call(this),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){for(var t=this._g,r=t.columnHeaders,i=0;i<this._gds.length;i++){for(var n=this._gds[i],o=-1,s=-1,l=r.rows.length-1;l>=0&&s<0;l--)for(var a=0;a<r.columns.length&&s<0;a++){var d=t._getBindingColumn(r,l,r.columns[a]);if(d&&d.binding==n.propertyName){s=a,o=l;break}}if(s>-1&&o>-1){var h=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,o,s,h),h.setAttribute("class","wj-cell wj-header wj-groupmarker"),setCss(h,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var g=createElement('<span class="wj-glyph-drag"></span>');h.insertBefore(g,h.firstChild)}var p=h.querySelector(".wj-elem-filter");p&&removeChild(p);var u=this._getColumnFilter(r.columns[s]);u&&(p=createElement('<span class="wj-filter wj-glyph-filter"></span>',h),toggleClass(p,"wj-filter-on",u.isActive),toggleClass(p,"wj-filter-off",!u.isActive)),createElement('<span class="wj-remove">&times;</span>',h),this._divMarkers.appendChild(h)}}var c=this._divMarkers.children.length>0;this._divPH.style.display=c?"none":"",this._divMarkers.style.display=c?"":"none"}},t.prototype._getColumnFilter=function(e){var t=this._filter,r=null;return t&&(r=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),r},t.prototype._editFilter=function(e){var t=this._gds,r=this._getElementIndex(e),i=t&&r>-1?t[r]:null,n=i?i.propertyName:null,o=n?this._g.columns.getColumn(n):null;o&&this._filter.editColumnFilter(o,null,e)},t.prototype._addGroup=function(e,t){for(var r=this._getIndex(t),i=this._gds,n=this._maxGroups,o=0;o<i.length;o++)if(i[o].propertyName==e.binding){i.removeAt(o),o<r&&r--;break}if(n>-1)for(o=n-1;o<i.length;o++)this._removeGroup(o,i),o<r&&r--;(n<0||i.length<n)&&(i.deferUpdate(function(){var t=new PropertyGroupDescription(e.binding);i.insert(r,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))},t.prototype._moveGroup=function(e,t){var r=this._gds,i=this._getElementIndex(this._dragMarker),n=this._getIndex(t);n>i&&n--,n>=this._gds.length&&(n=this._gds.length),i!=n&&r.deferUpdate(function(){var e=r[i];r.removeAt(i),r.insert(n,e)})},t.prototype._removeGroup=function(e,t){void 0===t&&(t=this._gds);var r=null;t&&e>-1&&(r=t[e],t.removeAt(e));var i=r?r.propertyName:null,n=i?this._g.columns.getColumn(i):null;if(n){n.visible=!0;var o=this._hiddenCols.indexOf(n);o>-1&&this._hiddenCols.splice(o,1)}},t.prototype._getIndex=function(e){for(var t=e.clientX,r=this._divMarkers.children,i=0;i<r.length;i++){var n=r[i].getBoundingClientRect();if((t-n.left)*(t-n.right)<0)return i}return r.length},t.prototype._getElementIndex=function(e){if(e&&e.parentElement)for(var t=e.parentElement.children,r=0;r<t.length;r++)if(t[r]==e)return r;return-1},t.prototype._draggingColumn=function(e,t){var r=this._g,i=r._getBindingColumn(t.panel,t.row,r.columns[t.col]);this._dragCol=i.binding?i:null},t.prototype._itemsSourceChanging=function(e,t){this._hiddenCols.forEach(function(e){e.visible=!0}),this._hiddenCols=[]},t.prototype._itemsSourceChanged=function(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()},t.prototype._collectionChanged=function(e,t){t.action==NotifyCollectionChangedAction.Reset&&this.invalidate()},t.prototype._dragStart=function(e){_startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null},t.prototype._dragOver=function(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())},t.prototype._drop=function(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)},t.prototype._dragEnd=function(e){this._dragMarker=this._dragCol=null},t.prototype._click=function(e){var t=e.target,r=hasClass(t,"wj-remove"),i=hasClass(t,"wj-filter"),n=closest(t,".wj-cell");if(hasClass(n,"wj-cell")){var o=this._getElementIndex(n),s=this._g.collectionView.sortDescriptions;if(i)this._editFilter(n);else if(r)this._removeGroup(o);else if(e.ctrlKey)s.clear();else{for(var l=this._gds[o],a=!0,d=0;d<s.length;d++)if(s[d].property==l.propertyName){a=!s[d].ascending;break}var h=new SortDescription(l.propertyName,a);s.splice(0,s.length,h)}}},t.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',t}(Control);export{GroupPanel};_registerModule("wijmo.grid.grouppanel",selfModule);
var __extends=this&&this.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(t,r)};return function(t,r){function i(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(i.prototype=r.prototype,new i)}}();import{Control,asBoolean,asNumber,asType,setCss,toggleClass,createElement,removeChild,_startDrag,hasClass,closest,PropertyGroupDescription,SortDescription,NotifyCollectionChangedAction,_registerModule}from"@grapecity/wijmo";import{FlexGrid}from"@grapecity/wijmo.grid";import{FlexGridFilter}from"@grapecity/wijmo.grid.filter";import*as selfModule from"@grapecity/wijmo.grid.grouppanel";var GroupPanel=function(e){function t(t,r){var i=e.call(this,t)||this;i._hideGroupedCols=!0,i._showDragGlyphs=!0,i._maxGroups=6,i._hiddenCols=[];var n=i.getTemplate();i.applyTemplate("wj-grouppanel wj-control",n,{_divMarkers:"div-markers",_divPH:"div-ph"});var o=i.hostElement;return i.addEventListener(o,"dragstart",i._dragStart.bind(i)),i.addEventListener(o,"dragover",i._dragOver.bind(i)),i.addEventListener(o,"drop",i._drop.bind(i)),i.addEventListener(o,"dragend",i._dragEnd.bind(i)),i.addEventListener(o,"click",i._click.bind(i)),i.initialize(r),i}return __extends(t,e),Object.defineProperty(t.prototype,"hideGroupedColumns",{get:function(){return this._hideGroupedCols},set:function(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=asBoolean(e))},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"showDragGlyphs",{get:function(){return this._showDragGlyphs},set:function(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=asBoolean(e),this.refresh())},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"maxGroups",{get:function(){return this._maxGroups},set:function(e){if(e!=this._maxGroups){this._maxGroups=asNumber(e);var t=this._gds,r=this._maxGroups;t&&r>-1&&r<t.length&&t.splice(r,t.length-r)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"placeholder",{get:function(){return this._divPH.textContent},set:function(e){this._divPH.textContent=e},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"grid",{get:function(){return this._g},set:function(e){if((e=asType(e,FlexGrid,!0))!=this._g){var t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"filter",{get:function(){return this._filter},set:function(e){if((e=asType(e,FlexGridFilter,!0))!=this._filter){var t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}},enumerable:!0,configurable:!0}),t.prototype.refresh=function(){if(e.prototype.refresh.call(this),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){for(var t=this._g,r=t.columnHeaders,i=0;i<this._gds.length;i++){for(var n=this._gds[i],o=-1,s=-1,l=r.rows.length-1;l>=0&&s<0;l--)for(var a=0;a<r.columns.length&&s<0;a++){var d=t._getBindingColumn(r,l,r.columns[a]);if(d&&d.binding==n.propertyName){s=a,o=l;break}}if(s>-1&&o>-1){var h=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,o,s,h),h.setAttribute("class","wj-cell wj-header wj-groupmarker"),setCss(h,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var g=createElement('<span class="wj-glyph-drag"></span>');h.insertBefore(g,h.firstChild)}var p=h.querySelector(".wj-elem-filter");p&&removeChild(p);var u=this._getColumnFilter(r.columns[s]);u&&(p=createElement('<span class="wj-filter wj-glyph-filter"></span>',h),toggleClass(p,"wj-filter-on",u.isActive),toggleClass(p,"wj-filter-off",!u.isActive)),createElement('<span class="wj-remove">&times;</span>',h),this._divMarkers.appendChild(h)}}var c=this._divMarkers.children.length>0;this._divPH.style.display=c?"none":"",this._divMarkers.style.display=c?"":"none"}},t.prototype._getColumnFilter=function(e){var t=this._filter,r=null;return t&&(r=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),r},t.prototype._editFilter=function(e){var t=this._gds,r=this._getElementIndex(e),i=t&&r>-1?t[r]:null,n=i?i.propertyName:null,o=n?this._g.columns.getColumn(n):null;o&&this._filter.editColumnFilter(o,null,e)},t.prototype._addGroup=function(e,t){for(var r=this._getIndex(t),i=this._gds,n=this._maxGroups,o=0;o<i.length;o++)if(i[o].propertyName==e.binding){i.removeAt(o),o<r&&r--;break}if(n>-1)for(o=n-1;o<i.length;o++)this._removeGroup(o,i),o<r&&r--;(n<0||i.length<n)&&(i.deferUpdate(function(){var t=new PropertyGroupDescription(e.binding);i.insert(r,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))},t.prototype._moveGroup=function(e,t){var r=this._gds,i=this._getElementIndex(this._dragMarker),n=this._getIndex(t);n>i&&n--,n>=this._gds.length&&(n=this._gds.length),i!=n&&r.deferUpdate(function(){var e=r[i];r.removeAt(i),r.insert(n,e)})},t.prototype._removeGroup=function(e,t){void 0===t&&(t=this._gds);var r=null;t&&e>-1&&(r=t[e],t.removeAt(e));var i=r?r.propertyName:null,n=i?this._g.columns.getColumn(i):null;if(n){n.visible=!0;var o=this._hiddenCols.indexOf(n);o>-1&&this._hiddenCols.splice(o,1)}},t.prototype._getIndex=function(e){for(var t=e.clientX,r=this._divMarkers.children,i=0;i<r.length;i++){var n=r[i].getBoundingClientRect();if((t-n.left)*(t-n.right)<0)return i}return r.length},t.prototype._getElementIndex=function(e){if(e&&e.parentElement)for(var t=e.parentElement.children,r=0;r<t.length;r++)if(t[r]==e)return r;return-1},t.prototype._draggingColumn=function(e,t){var r=this._g,i=r._getBindingColumn(t.panel,t.row,r.columns[t.col]);this._dragCol=i.binding?i:null},t.prototype._itemsSourceChanging=function(e,t){this._hiddenCols.forEach(function(e){e.visible=!0}),this._hiddenCols=[]},t.prototype._itemsSourceChanged=function(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()},t.prototype._collectionChanged=function(e,t){t.action==NotifyCollectionChangedAction.Reset&&this.invalidate()},t.prototype._dragStart=function(e){_startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null},t.prototype._dragOver=function(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())},t.prototype._drop=function(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)},t.prototype._dragEnd=function(e){this._dragMarker=this._dragCol=null},t.prototype._click=function(e){var t=e.target,r=hasClass(t,"wj-remove"),i=hasClass(t,"wj-filter"),n=closest(t,".wj-cell");if(hasClass(n,"wj-cell")){var o=this._getElementIndex(n),s=this._g.collectionView.sortDescriptions;if(i)this._editFilter(n);else if(r)this._removeGroup(o);else if(e.ctrlKey)s.clear();else{for(var l=this._gds[o],a=!0,d=0;d<s.length;d++)if(s[d].property==l.propertyName){a=!s[d].ascending;break}var h=new SortDescription(l.propertyName,a);s.splice(0,s.length,h)}}},t.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',t}(Control);export{GroupPanel};_registerModule("wijmo.grid.grouppanel",selfModule);

@@ -1,13 +0,1 @@

/*!
*
* Wijmo Library 5.20183.595-nightly.d20190405.t210807
* http://wijmo.com/
*
* Copyright(c) GrapeCity, Inc. All rights reserved.
*
* Licensed under the GrapeCity Commercial License.
* sales@wijmo.com
* wijmo.com/products/wijmo-5/license/
*
*/
/**

@@ -14,0 +2,0 @@ * {@module wijmo.grid.grouppanel}

@@ -1,14 +0,1 @@

/*!
*
* Wijmo Library 5.20183.595-nightly.d20190405.t210807
* http://wijmo.com/
*
* Copyright(c) GrapeCity, Inc. All rights reserved.
*
* Licensed under the GrapeCity Commercial License.
* sales@wijmo.com
* wijmo.com/products/wijmo-5/license/
*
*/
"use strict";var __extends=this&&this.__extends||function(){var e=function(t,i){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])})(t,i)};return function(t,i){function r(){this.constructor=t}e(t,i),t.prototype=null===i?Object.create(i):(r.prototype=i.prototype,new r)}}();Object.defineProperty(exports,"__esModule",{value:!0});var wijmo_1=require("@grapecity/wijmo"),wijmo_grid_1=require("@grapecity/wijmo.grid"),wijmo_grid_filter_1=require("@grapecity/wijmo.grid.filter"),selfModule=require("@grapecity/wijmo.grid.grouppanel"),GroupPanel=function(e){function t(t,i){var r=e.call(this,t)||this;r._hideGroupedCols=!0,r._showDragGlyphs=!0,r._maxGroups=6,r._hiddenCols=[];var o=r.getTemplate();r.applyTemplate("wj-grouppanel wj-control",o,{_divMarkers:"div-markers",_divPH:"div-ph"});var n=r.hostElement;return r.addEventListener(n,"dragstart",r._dragStart.bind(r)),r.addEventListener(n,"dragover",r._dragOver.bind(r)),r.addEventListener(n,"drop",r._drop.bind(r)),r.addEventListener(n,"dragend",r._dragEnd.bind(r)),r.addEventListener(n,"click",r._click.bind(r)),r.initialize(i),r}return __extends(t,e),Object.defineProperty(t.prototype,"hideGroupedColumns",{get:function(){return this._hideGroupedCols},set:function(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=wijmo_1.asBoolean(e))},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"showDragGlyphs",{get:function(){return this._showDragGlyphs},set:function(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=wijmo_1.asBoolean(e),this.refresh())},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"maxGroups",{get:function(){return this._maxGroups},set:function(e){if(e!=this._maxGroups){this._maxGroups=wijmo_1.asNumber(e);var t=this._gds,i=this._maxGroups;t&&i>-1&&i<t.length&&t.splice(i,t.length-i)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"placeholder",{get:function(){return this._divPH.textContent},set:function(e){this._divPH.textContent=e},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"grid",{get:function(){return this._g},set:function(e){if((e=wijmo_1.asType(e,wijmo_grid_1.FlexGrid,!0))!=this._g){var t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"filter",{get:function(){return this._filter},set:function(e){if((e=wijmo_1.asType(e,wijmo_grid_filter_1.FlexGridFilter,!0))!=this._filter){var t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}},enumerable:!0,configurable:!0}),t.prototype.refresh=function(){if(e.prototype.refresh.call(this),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){for(var t=this._g,i=t.columnHeaders,r=0;r<this._gds.length;r++){for(var o=this._gds[r],n=-1,s=-1,l=i.rows.length-1;l>=0&&s<0;l--)for(var a=0;a<i.columns.length&&s<0;a++){var d=t._getBindingColumn(i,l,i.columns[a]);if(d&&d.binding==o.propertyName){s=a,n=l;break}}if(s>-1&&n>-1){var h=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,n,s,h),h.setAttribute("class","wj-cell wj-header wj-groupmarker"),wijmo_1.setCss(h,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var g=wijmo_1.createElement('<span class="wj-glyph-drag"></span>');h.insertBefore(g,h.firstChild)}var _=h.querySelector(".wj-elem-filter");_&&wijmo_1.removeChild(_);var p=this._getColumnFilter(i.columns[s]);p&&(_=wijmo_1.createElement('<span class="wj-filter wj-glyph-filter"></span>',h),wijmo_1.toggleClass(_,"wj-filter-on",p.isActive),wijmo_1.toggleClass(_,"wj-filter-off",!p.isActive)),wijmo_1.createElement('<span class="wj-remove">&times;</span>',h),this._divMarkers.appendChild(h)}}var u=this._divMarkers.children.length>0;this._divPH.style.display=u?"none":"",this._divMarkers.style.display=u?"":"none"}},t.prototype._getColumnFilter=function(e){var t=this._filter,i=null;return t&&(i=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),i},t.prototype._editFilter=function(e){var t=this._gds,i=this._getElementIndex(e),r=t&&i>-1?t[i]:null,o=r?r.propertyName:null,n=o?this._g.columns.getColumn(o):null;n&&this._filter.editColumnFilter(n,null,e)},t.prototype._addGroup=function(e,t){for(var i=this._getIndex(t),r=this._gds,o=this._maxGroups,n=0;n<r.length;n++)if(r[n].propertyName==e.binding){r.removeAt(n),n<i&&i--;break}if(o>-1)for(n=o-1;n<r.length;n++)this._removeGroup(n,r),n<i&&i--;(o<0||r.length<o)&&(r.deferUpdate(function(){var t=new wijmo_1.PropertyGroupDescription(e.binding);r.insert(i,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))},t.prototype._moveGroup=function(e,t){var i=this._gds,r=this._getElementIndex(this._dragMarker),o=this._getIndex(t);o>r&&o--,o>=this._gds.length&&(o=this._gds.length),r!=o&&i.deferUpdate(function(){var e=i[r];i.removeAt(r),i.insert(o,e)})},t.prototype._removeGroup=function(e,t){void 0===t&&(t=this._gds);var i=null;t&&e>-1&&(i=t[e],t.removeAt(e));var r=i?i.propertyName:null,o=r?this._g.columns.getColumn(r):null;if(o){o.visible=!0;var n=this._hiddenCols.indexOf(o);n>-1&&this._hiddenCols.splice(n,1)}},t.prototype._getIndex=function(e){for(var t=e.clientX,i=this._divMarkers.children,r=0;r<i.length;r++){var o=i[r].getBoundingClientRect();if((t-o.left)*(t-o.right)<0)return r}return i.length},t.prototype._getElementIndex=function(e){if(e&&e.parentElement)for(var t=e.parentElement.children,i=0;i<t.length;i++)if(t[i]==e)return i;return-1},t.prototype._draggingColumn=function(e,t){var i=this._g,r=i._getBindingColumn(t.panel,t.row,i.columns[t.col]);this._dragCol=r.binding?r:null},t.prototype._itemsSourceChanging=function(e,t){this._hiddenCols.forEach(function(e){e.visible=!0}),this._hiddenCols=[]},t.prototype._itemsSourceChanged=function(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()},t.prototype._collectionChanged=function(e,t){t.action==wijmo_1.NotifyCollectionChangedAction.Reset&&this.invalidate()},t.prototype._dragStart=function(e){wijmo_1._startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null},t.prototype._dragOver=function(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())},t.prototype._drop=function(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)},t.prototype._dragEnd=function(e){this._dragMarker=this._dragCol=null},t.prototype._click=function(e){var t=e.target,i=wijmo_1.hasClass(t,"wj-remove"),r=wijmo_1.hasClass(t,"wj-filter"),o=wijmo_1.closest(t,".wj-cell");if(wijmo_1.hasClass(o,"wj-cell")){var n=this._getElementIndex(o),s=this._g.collectionView.sortDescriptions;if(r)this._editFilter(o);else if(i)this._removeGroup(n);else if(e.ctrlKey)s.clear();else{for(var l=this._gds[n],a=!0,d=0;d<s.length;d++)if(s[d].property==l.propertyName){a=!s[d].ascending;break}var h=new wijmo_1.SortDescription(l.propertyName,a);s.splice(0,s.length,h)}}},t.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',t}(wijmo_1.Control);exports.GroupPanel=GroupPanel,wijmo_1._registerModule("wijmo.grid.grouppanel",selfModule);
"use strict";var __extends=this&&this.__extends||function(){var e=function(t,i){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])})(t,i)};return function(t,i){function r(){this.constructor=t}e(t,i),t.prototype=null===i?Object.create(i):(r.prototype=i.prototype,new r)}}();Object.defineProperty(exports,"__esModule",{value:!0});var wijmo_1=require("@grapecity/wijmo"),wijmo_grid_1=require("@grapecity/wijmo.grid"),wijmo_grid_filter_1=require("@grapecity/wijmo.grid.filter"),selfModule=require("@grapecity/wijmo.grid.grouppanel"),GroupPanel=function(e){function t(t,i){var r=e.call(this,t)||this;r._hideGroupedCols=!0,r._showDragGlyphs=!0,r._maxGroups=6,r._hiddenCols=[];var o=r.getTemplate();r.applyTemplate("wj-grouppanel wj-control",o,{_divMarkers:"div-markers",_divPH:"div-ph"});var n=r.hostElement;return r.addEventListener(n,"dragstart",r._dragStart.bind(r)),r.addEventListener(n,"dragover",r._dragOver.bind(r)),r.addEventListener(n,"drop",r._drop.bind(r)),r.addEventListener(n,"dragend",r._dragEnd.bind(r)),r.addEventListener(n,"click",r._click.bind(r)),r.initialize(i),r}return __extends(t,e),Object.defineProperty(t.prototype,"hideGroupedColumns",{get:function(){return this._hideGroupedCols},set:function(e){e!=this._hideGroupedCols&&(this._hideGroupedCols=wijmo_1.asBoolean(e))},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"showDragGlyphs",{get:function(){return this._showDragGlyphs},set:function(e){e!=this._showDragGlyphs&&(this._showDragGlyphs=wijmo_1.asBoolean(e),this.refresh())},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"maxGroups",{get:function(){return this._maxGroups},set:function(e){if(e!=this._maxGroups){this._maxGroups=wijmo_1.asNumber(e);var t=this._gds,i=this._maxGroups;t&&i>-1&&i<t.length&&t.splice(i,t.length-i)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"placeholder",{get:function(){return this._divPH.textContent},set:function(e){this._divPH.textContent=e},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"grid",{get:function(){return this._g},set:function(e){if((e=wijmo_1.asType(e,wijmo_grid_1.FlexGrid,!0))!=this._g){var t=this._g;t&&(t.draggingColumn.removeHandler(this._draggingColumn),t.itemsSourceChanging.removeHandler(this._itemsSourceChanging),t.itemsSourceChanged.removeHandler(this._itemsSourceChanged),t.columns.collectionChanged.removeHandler(this._itemsSourceChanged)),t=this._g=e,this._hiddenCols=[],t&&(t.draggingColumn.addHandler(this._draggingColumn,this),t.itemsSourceChanging.addHandler(this._itemsSourceChanging,this),t.itemsSourceChanged.addHandler(this._itemsSourceChanged,this),t.columns.collectionChanged.addHandler(this._itemsSourceChanged,this)),this._itemsSourceChanged(t,null)}},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"filter",{get:function(){return this._filter},set:function(e){if((e=wijmo_1.asType(e,wijmo_grid_filter_1.FlexGridFilter,!0))!=this._filter){var t=this._filter;t&&t.filterApplied.removeHandler(this.refresh,this),(t=this._filter=e)&&t.filterApplied.addHandler(this.refresh,this),this.refresh()}},enumerable:!0,configurable:!0}),t.prototype.refresh=function(){if(e.prototype.refresh.call(this),this._divMarkers.innerHTML="",this._dragMarker=this._dragCol=null,this._gds){for(var t=this._g,i=t.columnHeaders,r=0;r<this._gds.length;r++){for(var o=this._gds[r],n=-1,s=-1,l=i.rows.length-1;l>=0&&s<0;l--)for(var a=0;a<i.columns.length&&s<0;a++){var d=t._getBindingColumn(i,l,i.columns[a]);if(d&&d.binding==o.propertyName){s=a,n=l;break}}if(s>-1&&n>-1){var h=document.createElement("div");if(t.cellFactory.updateCell(this._g.columnHeaders,n,s,h),h.setAttribute("class","wj-cell wj-header wj-groupmarker"),wijmo_1.setCss(h,{position:"static",display:"inline-block",verticalAlign:"top",left:"",top:"",right:"",height:"auto",width:"auto"}),this.showDragGlyphs){var g=wijmo_1.createElement('<span class="wj-glyph-drag"></span>');h.insertBefore(g,h.firstChild)}var _=h.querySelector(".wj-elem-filter");_&&wijmo_1.removeChild(_);var p=this._getColumnFilter(i.columns[s]);p&&(_=wijmo_1.createElement('<span class="wj-filter wj-glyph-filter"></span>',h),wijmo_1.toggleClass(_,"wj-filter-on",p.isActive),wijmo_1.toggleClass(_,"wj-filter-off",!p.isActive)),wijmo_1.createElement('<span class="wj-remove">&times;</span>',h),this._divMarkers.appendChild(h)}}var u=this._divMarkers.children.length>0;this._divPH.style.display=u?"none":"",this._divMarkers.style.display=u?"":"none"}},t.prototype._getColumnFilter=function(e){var t=this._filter,i=null;return t&&(i=t.filterColumns&&t.filterColumns.indexOf(e.binding)<0?null:t.getColumnFilter(e)),i},t.prototype._editFilter=function(e){var t=this._gds,i=this._getElementIndex(e),r=t&&i>-1?t[i]:null,o=r?r.propertyName:null,n=o?this._g.columns.getColumn(o):null;n&&this._filter.editColumnFilter(n,null,e)},t.prototype._addGroup=function(e,t){for(var i=this._getIndex(t),r=this._gds,o=this._maxGroups,n=0;n<r.length;n++)if(r[n].propertyName==e.binding){r.removeAt(n),n<i&&i--;break}if(o>-1)for(n=o-1;n<r.length;n++)this._removeGroup(n,r),n<i&&i--;(o<0||r.length<o)&&(r.deferUpdate(function(){var t=new wijmo_1.PropertyGroupDescription(e.binding);r.insert(i,t)}),e&&this.hideGroupedColumns&&(e.visible=!1,this._hiddenCols.push(e)))},t.prototype._moveGroup=function(e,t){var i=this._gds,r=this._getElementIndex(this._dragMarker),o=this._getIndex(t);o>r&&o--,o>=this._gds.length&&(o=this._gds.length),r!=o&&i.deferUpdate(function(){var e=i[r];i.removeAt(r),i.insert(o,e)})},t.prototype._removeGroup=function(e,t){void 0===t&&(t=this._gds);var i=null;t&&e>-1&&(i=t[e],t.removeAt(e));var r=i?i.propertyName:null,o=r?this._g.columns.getColumn(r):null;if(o){o.visible=!0;var n=this._hiddenCols.indexOf(o);n>-1&&this._hiddenCols.splice(n,1)}},t.prototype._getIndex=function(e){for(var t=e.clientX,i=this._divMarkers.children,r=0;r<i.length;r++){var o=i[r].getBoundingClientRect();if((t-o.left)*(t-o.right)<0)return r}return i.length},t.prototype._getElementIndex=function(e){if(e&&e.parentElement)for(var t=e.parentElement.children,i=0;i<t.length;i++)if(t[i]==e)return i;return-1},t.prototype._draggingColumn=function(e,t){var i=this._g,r=i._getBindingColumn(t.panel,t.row,i.columns[t.col]);this._dragCol=r.binding?r:null},t.prototype._itemsSourceChanging=function(e,t){this._hiddenCols.forEach(function(e){e.visible=!0}),this._hiddenCols=[]},t.prototype._itemsSourceChanged=function(e,t){this._view&&this._view.collectionChanged.removeHandler(this._collectionChanged),this._view=this._g?this._g.collectionView:null,this._gds=this._view?this._view.groupDescriptions:null,this._view&&this._view.collectionChanged.addHandler(this._collectionChanged,this),this.invalidate()},t.prototype._collectionChanged=function(e,t){t.action==wijmo_1.NotifyCollectionChangedAction.Reset&&this.invalidate()},t.prototype._dragStart=function(e){wijmo_1._startDrag(e.dataTransfer,"move"),this._dragMarker=e.target,this._dragCol=null},t.prototype._dragOver=function(e){(this._dragCol||this._dragMarker)&&(e.dataTransfer.dropEffect="move",e.preventDefault(),e.stopPropagation())},t.prototype._drop=function(e){this._dragMarker?this._moveGroup(this._dragMarker,e):this._dragCol&&this._addGroup(this._dragCol,e)},t.prototype._dragEnd=function(e){this._dragMarker=this._dragCol=null},t.prototype._click=function(e){var t=e.target,i=wijmo_1.hasClass(t,"wj-remove"),r=wijmo_1.hasClass(t,"wj-filter"),o=wijmo_1.closest(t,".wj-cell");if(wijmo_1.hasClass(o,"wj-cell")){var n=this._getElementIndex(o),s=this._g.collectionView.sortDescriptions;if(r)this._editFilter(o);else if(i)this._removeGroup(n);else if(e.ctrlKey)s.clear();else{for(var l=this._gds[n],a=!0,d=0;d<s.length;d++)if(s[d].property==l.propertyName){a=!s[d].ascending;break}var h=new wijmo_1.SortDescription(l.propertyName,a);s.splice(0,s.length,h)}}},t.controlTemplate='<div style="cursor:default;overflow:hidden;height:100%;width:100%;min-height:1em"><div wj-part="div-ph"></div><div wj-part="div-markers"></div></div>',t}(wijmo_1.Control);exports.GroupPanel=GroupPanel,wijmo_1._registerModule("wijmo.grid.grouppanel",selfModule);

10

package.json
{
"name": "@grapecity/wijmo.grid.grouppanel",
"version": "5.20183.595-nightly.d20190405.t210807",
"version": "5.20183.595-nightly.d20190406.t001954",
"description": "UI library for pure JS, Angular, React, Vue and more...",

@@ -10,6 +10,6 @@ "author": "GrapeCity, Inc",

"dependencies": {
"@grapecity/wijmo": "5.20183.595-nightly.d20190405.t210807",
"@grapecity/wijmo.input": "5.20183.595-nightly.d20190405.t210807",
"@grapecity/wijmo.grid": "5.20183.595-nightly.d20190405.t210807",
"@grapecity/wijmo.grid.filter": "5.20183.595-nightly.d20190405.t210807"
"@grapecity/wijmo": "5.20183.595-nightly.d20190406.t001954",
"@grapecity/wijmo.input": "5.20183.595-nightly.d20190406.t001954",
"@grapecity/wijmo.grid": "5.20183.595-nightly.d20190406.t001954",
"@grapecity/wijmo.grid.filter": "5.20183.595-nightly.d20190406.t001954"
},

@@ -16,0 +16,0 @@ "module": "./es5-esm.js",

@@ -1,13 +0,1 @@

/*!
*
* Wijmo Library 5.20183.595-nightly.d20190405.t210807
* http://wijmo.com/
*
* Copyright(c) GrapeCity, Inc. All rights reserved.
*
* Licensed under the GrapeCity Commercial License.
* sales@wijmo.com
* wijmo.com/products/wijmo-5/license/
*
*/
/**

@@ -14,0 +2,0 @@ * {@module wijmo.grid.grouppanel}

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc