@revolist/revogrid 3.0.98 → 3.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/custom-element/index.js +519 -301
  2. package/dist/cjs/debounce-e9b040d9.js +575 -0
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/revo-grid.cjs.js +1 -1
  5. package/dist/cjs/revo-grid_11.cjs.entry.js +195 -645
  6. package/dist/cjs/revogr-filter-panel.cjs.entry.js +166 -33
  7. package/dist/collection/components/data/revogr-data-style.css +8 -0
  8. package/dist/collection/components/header/revogr-header-style.css +8 -0
  9. package/dist/collection/components/overlay/editors/text.js +1 -1
  10. package/dist/collection/components/overlay/revogr-edit-style.css +8 -0
  11. package/dist/collection/components/overlay/revogr-overlay-style.css +8 -0
  12. package/dist/collection/components/revo-grid/revo-grid-style.css +8 -0
  13. package/dist/collection/components/revo-grid/revo-grid.js +30 -3
  14. package/dist/collection/components/revo-grid/viewport.service.js +3 -0
  15. package/dist/collection/components/scroll/revogr-viewport-scroll-style.css +8 -0
  16. package/dist/collection/components/scrollable/revogr-scroll-style.css +8 -0
  17. package/dist/collection/components/selection-focus/revogr-focus-style.css +8 -0
  18. package/dist/collection/components/selection-temp-range/revogr-temp-range-style.css +8 -0
  19. package/dist/collection/plugins/filter/conditions/equal.js +5 -1
  20. package/dist/collection/plugins/filter/filter.button.js +10 -0
  21. package/dist/collection/plugins/filter/filter.plugin.js +103 -47
  22. package/dist/collection/plugins/filter/filter.pop.js +227 -38
  23. package/dist/collection/plugins/filter/filter.style.css +61 -1
  24. package/dist/collection/plugins/groupingColumn/grouping.col.plugin.js +1 -0
  25. package/dist/collection/services/selection.store.connector.js +4 -0
  26. package/dist/esm/debounce-8dadcda7.js +558 -0
  27. package/dist/esm/loader.js +1 -1
  28. package/dist/esm/revo-grid.js +1 -1
  29. package/dist/esm/revo-grid_11.entry.js +149 -599
  30. package/dist/esm/revogr-filter-panel.entry.js +165 -32
  31. package/dist/esm-es5/debounce-8dadcda7.js +1 -0
  32. package/dist/esm-es5/loader.js +1 -1
  33. package/dist/esm-es5/revo-grid.js +1 -1
  34. package/dist/esm-es5/revo-grid_11.entry.js +1 -1
  35. package/dist/esm-es5/revogr-filter-panel.entry.js +1 -1
  36. package/dist/revo-grid/debounce-d097578d.js +1 -0
  37. package/dist/revo-grid/debounce-f40a88f6.system.js +1 -0
  38. package/dist/revo-grid/revo-grid.esm.js +1 -1
  39. package/dist/revo-grid/revo-grid.system.js +1 -1
  40. package/dist/revo-grid/revo-grid_11.entry.js +1 -1
  41. package/dist/revo-grid/revo-grid_11.system.entry.js +1 -1
  42. package/dist/revo-grid/revogr-filter-panel.entry.js +1 -1
  43. package/dist/revo-grid/revogr-filter-panel.system.entry.js +1 -1
  44. package/dist/types/components/revo-grid/revo-grid.d.ts +5 -1
  45. package/dist/types/components/revo-grid/viewport.service.d.ts +1 -0
  46. package/dist/types/components.d.ts +12 -4
  47. package/dist/types/plugins/filter/filter.button.d.ts +4 -0
  48. package/dist/types/plugins/filter/filter.plugin.d.ts +17 -8
  49. package/dist/types/plugins/filter/filter.pop.d.ts +31 -7
  50. package/dist/types/services/selection.store.connector.d.ts +1 -0
  51. package/package.json +1 -1
  52. package/dist/cjs/filter.button-2396a488.js +0 -27
  53. package/dist/esm/filter.button-53ebca66.js +0 -23
  54. package/dist/esm-es5/filter.button-53ebca66.js +0 -1
  55. package/dist/revo-grid/filter.button-1509c206.js +0 -1
  56. package/dist/revo-grid/filter.button-4bd87101.system.js +0 -1
@@ -1 +1 @@
1
- import{h as e,r as t,c as i,H as r}from"./index-a7f99799.js";import{i as o}from"./filter.button-1509c206.js";const s=(t,i)=>e("button",Object.assign({},t,{class:Object.assign(Object.assign({},"object"==typeof t.class?t.class:t.class?{[t.class]:!0}:""),{"revo-button":!0})}),i);Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),Element.prototype.closest||(Element.prototype.closest=function(e){let t=this;do{if(Element.prototype.matches.call(t,e))return t;t=t.parentElement||t.parentNode}while(null!==t&&1===t.nodeType);return null});const n=class{constructor(e){t(this,e),this.filterChange=i(this,"filterChange",7),this.filterTypes={},this.filterNames={},this.filterEntities={}}onMouseDown(e){if(this.changes&&!e.defaultPrevented){const t=e.target;this.isOutside(t)&&!o(t)&&(this.changes=void 0)}}async show(e){this.changes=e,this.changes&&(this.changes.type=this.changes.type||"none")}async getChanges(){return this.changes}renderConditions(t){const i=[];for(let r in this.filterTypes)i.push(e("option",{value:"none"},this.filterNames.none)),i.push(...this.filterTypes[r].map((i=>e("option",{value:i,selected:t===i},this.filterNames[i])))),i.push(e("option",{disabled:!0}));return i}renderExtra(t,i){switch(this.extraElement=void 0,t){case"input":return e("input",{type:"text",value:i,onInput:e=>this.onInput(e),onKeyDown:e=>this.onKeyDown(e),ref:e=>this.extraElement=e});default:return""}}render(){return this.changes&&this.changes?e(r,{style:{display:"block",left:`${this.changes.x}px`,top:`${this.changes.y}px`}},e("label",null,"Filter by condition"),e("select",{class:"select-css",onChange:e=>this.onFilterChange(e)},this.renderConditions(this.changes.type)),e("div",null,this.renderExtra(this.filterEntities[this.changes.type].extra,this.changes.value)),e(s,{class:{green:!0},onClick:()=>this.onSave()},"Save"),e(s,{class:{light:!0},onClick:()=>this.onCancel()},"Cancel")):e(r,{style:{display:"none"}})}onFilterChange(e){if(!this.changes)throw new Error("Changes required per edit");const t=e.target.value;this.changes=Object.assign(Object.assign({},this.changes),{type:t})}onInput(e){this.changes.value=e.target.value,e.preventDefault()}onKeyDown(e){"enter"===e.key.toLowerCase()&&this.onSave(),e.stopPropagation()}onCancel(){this.changes=void 0}onSave(){var e,t;if(!this.changes)throw new Error("Changes required per edit");this.filterChange.emit({prop:this.changes.prop,type:this.changes.type,value:null===(t=null===(e=this.extraElement)||void 0===e?void 0:e.value)||void 0===t?void 0:t.trim()}),this.changes=void 0}isOutside(e){return!e.classList.contains(`[uuid="${this.uuid}"]`)&&!(null==e?void 0:e.closest(`[uuid="${this.uuid}"]`))}};n.style=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:150px;text-align:left}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box}revogr-filter-panel button{margin-top:10px;margin-right:5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:#c5c5c5}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}";export{n as revogr_filter_panel}
1
+ import{h as t,r as e,c as i,H as s}from"./index-a7f99799.js";import{k as o,g as r,A as n,T as l}from"./debounce-d097578d.js";const a=(e,i)=>t("button",Object.assign({},e,{class:Object.assign(Object.assign({},"object"==typeof e.class?e.class:e.class?{[e.class]:!0}:""),{"revo-button":!0})}),i);Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),Element.prototype.closest||(Element.prototype.closest=function(t){let e=this;do{if(Element.prototype.matches.call(e,t))return e;e=e.parentElement||e.parentNode}while(null!==e&&1===e.nodeType);return null});const d=class{constructor(t){e(this,t),this.filterChange=i(this,"filterChange",7),this.filterCaptionsInternal={title:"Filter by condition",save:"Save",reset:"Reset",cancel:"Close"},this.isFilterIdSet=!1,this.filterId=0,this.currentFilterId=-1,this.currentFilterType="none",this.filterItems={},this.filterTypes={},this.filterNames={},this.filterEntities={},this.debouncedApplyFilter=o((()=>{this.filterChange.emit(this.filterItems)}),400)}onMouseDown(t){if(this.changes&&!t.defaultPrevented){const e=t.target;this.isOutside(e)&&!r(e)&&(this.changes=void 0)}}async show(t){this.changes=t,this.changes&&(this.changes.type=this.changes.type||"none")}async getChanges(){return this.changes}componentWillRender(){if(!this.isFilterIdSet){this.isFilterIdSet=!0;const t=Object.keys(this.filterItems);for(const e of t)this.filterId+=this.filterItems[e].length}}renderSelectOptions(e,i=!1){var s;const o=[],r=null===(s=this.changes)||void 0===s?void 0:s.prop;i||o.push(t("option",{selected:"none"===this.currentFilterType,value:"none"},r&&this.filterItems[r]&&this.filterItems[r].length>0?"Add more condition...":this.filterNames.none));for(let i in this.filterTypes)o.push(...this.filterTypes[i].map((i=>t("option",{value:i,selected:e===i},this.filterNames[i])))),o.push(t("option",{disabled:!0}));return o}renderExtra(e,i){const s=this.filterItems[e];return s?"input"!==this.filterEntities[s[i].type].extra?"":t("input",{id:`filter-input-${s[i].id}`,placeholder:"Enter value...",type:"text",value:s[i].value,onInput:this.onUserInput.bind(this,i,e),onKeyDown:t=>this.onKeyDown(t)}):""}getFilterItemsList(){var e;const i=null===(e=this.changes)||void 0===e?void 0:e.prop;if(!i&&0!==i)return"";const s=this.filterItems[i]||[];return t("div",{key:this.filterId},s.map(((e,s)=>{let o;return s!==this.filterItems[i].length-1&&(o=t("div",{onClick:()=>this.toggleFilterAndOr(e.id)},t(n,{isAnd:"and"===e.relation}))),t("div",{key:e.id,class:"multi-filter-list"},t("div",{class:{"select-input":!0}},t("select",{class:"select-css select-filter",onChange:t=>this.onFilterTypeChange(t,i,s)},this.renderSelectOptions(this.filterItems[i][s].type,!0)),t("div",{class:"multi-filter-list-action"},o),t("div",{onClick:()=>this.onRemoveFilter(e.id)},t(l,null))),t("div",null,this.renderExtra(i,s)))})),s.length>0?t("div",{class:"add-filter-divider"}):"")}render(){if(!this.changes)return t(s,{style:{display:"none"}});const e={display:"block",left:`${this.changes.x}px`,top:`${this.changes.y}px`},i=Object.assign(this.filterCaptionsInternal,this.filterCaptions);return t(s,{style:e},t("label",null,i.title),t("div",{class:"filter-holder"},this.getFilterItemsList()),t("div",{class:"add-filter"},t("select",{id:"add-filter",class:"select-css",onChange:t=>this.onAddNewFilter(t)},this.renderSelectOptions(this.currentFilterType))),t("div",{class:"filter-actions"},t(a,{class:{red:!0},onClick:()=>this.onReset()},i.reset),t(a,{class:{light:!0},onClick:()=>this.onCancel()},i.cancel)))}onFilterTypeChange(t,e,i){this.filterItems[e][i].type=t.target.value,this.filterId++,setTimeout((()=>{const t=document.getElementById("filter-input-"+this.filterItems[e][i].id);t&&t.focus()}),0),this.debouncedApplyFilter()}onAddNewFilter(t){this.currentFilterType=t.target.value,this.addNewFilterToProp();const e=document.getElementById("add-filter");e&&(e.value="none",this.currentFilterType="none"),this.debouncedApplyFilter()}addNewFilterToProp(){var t;const e=null===(t=this.changes)||void 0===t?void 0:t.prop;(e||0===e)&&(this.filterItems[e]||(this.filterItems[e]=[]),"none"!==this.currentFilterType&&(this.filterId++,this.currentFilterId=this.filterId,this.filterItems[e].push({id:this.currentFilterId,type:this.currentFilterType,value:"",relation:"and"}),setTimeout((()=>{const t=document.getElementById("filter-input-"+this.currentFilterId);t&&t.focus()}),0)))}onUserInput(t,e,i){this.filterItems[e][t].value=i.target.value,this.debouncedApplyFilter()}onKeyDown(t){if("enter"!==t.key.toLowerCase())t.stopPropagation();else{const t=document.getElementById("add-filter");t&&(t.value="none",this.currentFilterType="none",this.addNewFilterToProp(),t.focus())}}onCancel(){this.changes=void 0}onReset(){this.assertChanges(),delete this.filterItems[this.changes.prop],this.filterId++,this.filterChange.emit(this.filterItems)}onRemoveFilter(t){this.assertChanges(),this.filterId++;const e=this.changes.prop,i=this.filterItems[e];if(!i)return;const s=i.findIndex((e=>e.id===t));-1!==s&&(i.splice(s,1),0===i.length&&delete this.filterItems[e],this.debouncedApplyFilter())}toggleFilterAndOr(t){this.assertChanges(),this.filterId++;const e=this.filterItems[this.changes.prop];if(!e)return;const i=e.findIndex((e=>e.id===t));-1!==i&&(e[i].relation="and"===e[i].relation?"or":"and",this.debouncedApplyFilter())}assertChanges(){if(!this.changes)throw new Error("Changes required per edit")}isOutside(t){const e=document.getElementById("add-filter");return e&&(e.value="none"),this.currentFilterType="none",this.changes.type="none",this.currentFilterId=-1,!t.classList.contains(`[uuid="${this.uuid}"]`)&&!(null==t?void 0:t.closest(`[uuid="${this.uuid}"]`))}};d.style=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.red{background-color:#E0662E;border:1px solid #d55920}.revo-button:disabled,.revo-button[disabled]{cursor:not-allowed !important;filter:opacity(0.35) !important}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:220px;text-align:left}revogr-filter-panel .filter-holder>div{display:flex;flex-direction:column}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box;width:100%}revogr-filter-panel button{margin-top:10px;margin-right:5px}revogr-filter-panel .filter-actions{text-align:right;margin-right:-5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:#c5c5c5}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}.multi-filter-list{margin-top:5px;margin-bottom:5px}.multi-filter-list div{white-space:nowrap}.multi-filter-list .multi-filter-list-action{display:flex;justify-content:space-between;align-items:center}.multi-filter-list .and-or-button{margin:0 0 0 10px;min-width:58px;cursor:pointer}.multi-filter-list .trash-button{margin:0 0 -2px 6px;cursor:pointer;width:22px;height:22px;color:gray;font-size:18px}.multi-filter-list .trash-button .trash-img{width:1em}.add-filter-divider{display:block;margin:0 -10px 10px -10px;border-bottom:1px solid #d9d9d9;height:10px;box-shadow:0 4px 5px rgba(0, 0, 0, 0.05)}.select-input{display:flex;justify-content:space-between;align-items:center}";export{d as revogr_filter_panel}
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,r,n){function i(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,o){function a(e){try{l(n.next(e))}catch(e){o(e)}}function s(e){try{l(n["throw"](e))}catch(e){o(e)}}function l(e){e.done?r(e.value):i(e.value).then(a,s)}l((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(e){return function(t){return l([e,t])}}function l(a){if(n)throw new TypeError("Generator is already executing.");while(r)try{if(n=1,i&&(o=a[0]&2?i["return"]:a[0]?i["throw"]||((o=i["return"])&&o.call(i),0):i.next)&&!(o=o.call(i,a[1])).done)return o;if(i=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:r.label++;return{value:a[1],done:false};case 5:r.label++;i=a[1];a=[0];continue;case 7:a=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){r.label=a[1];break}if(a[0]===6&&r.label<o[1]){r.label=o[1];o=a;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(a);break}if(o[2])r.ops.pop();r.trys.pop();continue}a=t.call(e,r)}catch(e){a=[6,e];i=0}finally{n=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};System.register(["./index-a15e7527.system.js","./filter.button-4bd87101.system.js"],(function(e){"use strict";var t,r,n,i,o;return{setters:[function(e){t=e.h;r=e.r;n=e.c;i=e.H},function(e){o=e.i}],execute:function(){var a=function(e,r){var n,i;return t("button",Object.assign({},e,{class:Object.assign(Object.assign({},typeof e.class==="object"?e.class:e.class?(n={},n[e.class]=true,n):""),(i={},i["revo-button"]=true,i))}),r)};(function e(){if(!Element.prototype.matches){Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector}if(!Element.prototype.closest){Element.prototype.closest=function(e){var t=this;do{if(Element.prototype.matches.call(t,e)){return t}t=t.parentElement||t.parentNode}while(t!==null&&t.nodeType===1);return null}}})();var s=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:150px;text-align:left}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box}revogr-filter-panel button{margin-top:10px;margin-right:5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:#c5c5c5}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}";var l="none";var c=e("revogr_filter_panel",function(){function e(e){r(this,e);this.filterChange=n(this,"filterChange",7);this.filterTypes={};this.filterNames={};this.filterEntities={}}e.prototype.onMouseDown=function(e){if(this.changes&&!e.defaultPrevented){var t=e.target;if(this.isOutside(t)&&!o(t)){this.changes=undefined}}};e.prototype.show=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.changes=e;if(this.changes){this.changes.type=this.changes.type||l}return[2]}))}))};e.prototype.getChanges=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.changes]}))}))};e.prototype.renderConditions=function(e){var r=this;var n=[];for(var i in this.filterTypes){n.push(t("option",{value:l},this.filterNames[l]));n.push.apply(n,this.filterTypes[i].map((function(n){return t("option",{value:n,selected:e===n},r.filterNames[n])})));n.push(t("option",{disabled:true}))}return n};e.prototype.renderExtra=function(e,r){var n=this;this.extraElement=undefined;switch(e){case"input":return t("input",{type:"text",value:r,onInput:function(e){return n.onInput(e)},onKeyDown:function(e){return n.onKeyDown(e)},ref:function(e){return n.extraElement=e}});default:return""}};e.prototype.render=function(){var e=this;if(!this.changes||!this.changes){return t(i,{style:{display:"none"}})}var r={display:"block",left:this.changes.x+"px",top:this.changes.y+"px"};return t(i,{style:r},t("label",null,"Filter by condition"),t("select",{class:"select-css",onChange:function(t){return e.onFilterChange(t)}},this.renderConditions(this.changes.type)),t("div",null,this.renderExtra(this.filterEntities[this.changes.type].extra,this.changes.value)),t(a,{class:{green:true},onClick:function(){return e.onSave()}},"Save"),t(a,{class:{light:true},onClick:function(){return e.onCancel()}},"Cancel"))};e.prototype.onFilterChange=function(e){if(!this.changes){throw new Error("Changes required per edit")}var t=e.target;var r=t.value;this.changes=Object.assign(Object.assign({},this.changes),{type:r})};e.prototype.onInput=function(e){this.changes.value=e.target.value;e.preventDefault()};e.prototype.onKeyDown=function(e){if(e.key.toLowerCase()==="enter"){this.onSave()}e.stopPropagation()};e.prototype.onCancel=function(){this.changes=undefined};e.prototype.onSave=function(){var e,t;if(!this.changes){throw new Error("Changes required per edit")}this.filterChange.emit({prop:this.changes.prop,type:this.changes.type,value:(t=(e=this.extraElement)===null||e===void 0?void 0:e.value)===null||t===void 0?void 0:t.trim()});this.changes=undefined};e.prototype.isOutside=function(e){if(e.classList.contains('[uuid="'+this.uuid+'"]')){return false}return!(e===null||e===void 0?void 0:e.closest('[uuid="'+this.uuid+'"]'))};return e}());c.style=s}}}));
1
+ var __awaiter=this&&this.__awaiter||function(t,e,r,i){function n(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,o){function s(t){try{a(i.next(t))}catch(t){o(t)}}function l(t){try{a(i["throw"](t))}catch(t){o(t)}}function a(t){t.done?r(t.value):n(t.value).then(s,l)}a((i=i.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},i,n,o,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(t){return function(e){return a([t,e])}}function a(s){if(i)throw new TypeError("Generator is already executing.");while(r)try{if(i=1,n&&(o=s[0]&2?n["return"]:s[0]?n["throw"]||((o=n["return"])&&o.call(n),0):n.next)&&!(o=o.call(n,s[1])).done)return o;if(n=0,o)s=[s[0]&2,o.value];switch(s[0]){case 0:case 1:o=s;break;case 4:r.label++;return{value:s[1],done:false};case 5:r.label++;n=s[1];s=[0];continue;case 7:s=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(s[0]===6||s[0]===2)){r=0;continue}if(s[0]===3&&(!o||s[1]>o[0]&&s[1]<o[3])){r.label=s[1];break}if(s[0]===6&&r.label<o[1]){r.label=o[1];o=s;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(s);break}if(o[2])r.ops.pop();r.trys.pop();continue}s=e.call(t,r)}catch(t){s=[6,t];n=0}finally{i=o=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};System.register(["./index-a15e7527.system.js","./debounce-f40a88f6.system.js"],(function(t){"use strict";var e,r,i,n,o,s,l,a;return{setters:[function(t){e=t.h;r=t.r;i=t.c;n=t.H},function(t){o=t.k;s=t.g;l=t.A;a=t.T}],execute:function(){var c=function(t,r){var i,n;return e("button",Object.assign({},t,{class:Object.assign(Object.assign({},typeof t.class==="object"?t.class:t.class?(i={},i[t.class]=true,i):""),(n={},n["revo-button"]=true,n))}),r)};(function t(){if(!Element.prototype.matches){Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector}if(!Element.prototype.closest){Element.prototype.closest=function(t){var e=this;do{if(Element.prototype.matches.call(e,t)){return e}e=e.parentElement||e.parentNode}while(e!==null&&e.nodeType===1);return null}}})();var d=".revo-drag-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 438 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M421.875,70.40625 C426.432292,70.40625 430.175781,68.9414062 433.105469,66.0117188 C436.035156,63.0820312 437.5,59.3385417 437.5,54.78125 L437.5,54.78125 L437.5,15.71875 C437.5,11.1614583 436.035156,7.41796875 433.105469,4.48828125 C430.175781,1.55859375 426.432292,0.09375 421.875,0.09375 L421.875,0.09375 L15.625,0.09375 C11.0677083,0.09375 7.32421875,1.55859375 4.39453125,4.48828125 C1.46484375,7.41796875 0,11.1614583 0,15.71875 L0,15.71875 L0,54.78125 C0,59.3385417 1.46484375,63.0820312 4.39453125,66.0117188 C7.32421875,68.9414062 11.0677083,70.40625 15.625,70.40625 L15.625,70.40625 L421.875,70.40625 Z M421.875,226.65625 C426.432292,226.65625 430.175781,225.191406 433.105469,222.261719 C436.035156,219.332031 437.5,215.588542 437.5,211.03125 L437.5,211.03125 L437.5,171.96875 C437.5,167.411458 436.035156,163.667969 433.105469,160.738281 C430.175781,157.808594 426.432292,156.34375 421.875,156.34375 L421.875,156.34375 L15.625,156.34375 C11.0677083,156.34375 7.32421875,157.808594 4.39453125,160.738281 C1.46484375,163.667969 0,167.411458 0,171.96875 L0,171.96875 L0,211.03125 C0,215.588542 1.46484375,219.332031 4.39453125,222.261719 C7.32421875,225.191406 11.0677083,226.65625 15.625,226.65625 L15.625,226.65625 L421.875,226.65625 Z M421.875,382.90625 C426.432292,382.90625 430.175781,381.441406 433.105469,378.511719 C436.035156,375.582031 437.5,371.838542 437.5,367.28125 L437.5,367.28125 L437.5,328.21875 C437.5,323.661458 436.035156,319.917969 433.105469,316.988281 C430.175781,314.058594 426.432292,312.59375 421.875,312.59375 L421.875,312.59375 L15.625,312.59375 C11.0677083,312.59375 7.32421875,314.058594 4.39453125,316.988281 C1.46484375,319.917969 0,323.661458 0,328.21875 L0,328.21875 L0,367.28125 C0,371.838542 1.46484375,375.582031 4.39453125,378.511719 C7.32421875,381.441406 11.0677083,382.90625 15.625,382.90625 L15.625,382.90625 L421.875,382.90625 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:7px;background-size:cover;background-repeat:no-repeat}.revo-alt-icon{-webkit-mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg viewBox='0 0 384 383' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3E%3Cg%3E%3Cpath d='M192.4375,383 C197.424479,383 201.663411,381.254557 205.154297,377.763672 L205.154297,377.763672 L264.25,318.667969 C270.234375,312.683594 271.605794,306.075846 268.364258,298.844727 C265.122721,291.613607 259.51237,287.998047 251.533203,287.998047 L251.533203,287.998047 L213.382812,287.998047 L213.382812,212.445312 L288.935547,212.445312 L288.935547,250.595703 C288.935547,258.57487 292.551107,264.185221 299.782227,267.426758 C307.013346,270.668294 313.621094,269.296875 319.605469,263.3125 L319.605469,263.3125 L378.701172,204.216797 C382.192057,200.725911 383.9375,196.486979 383.9375,191.5 C383.9375,186.513021 382.192057,182.274089 378.701172,178.783203 L378.701172,178.783203 L319.605469,119.6875 C313.621094,114.201823 307.013346,112.955078 299.782227,115.947266 C292.551107,118.939453 288.935547,124.42513 288.935547,132.404297 L288.935547,132.404297 L288.935547,170.554688 L213.382812,170.554688 L213.382812,95.0019531 L251.533203,95.0019531 C259.51237,95.0019531 264.998047,91.3863932 267.990234,84.1552734 C270.982422,76.9241536 269.735677,70.3164062 264.25,64.3320312 L264.25,64.3320312 L205.154297,5.23632812 C201.663411,1.74544271 197.424479,0 192.4375,0 C187.450521,0 183.211589,1.74544271 179.720703,5.23632812 L179.720703,5.23632812 L120.625,64.3320312 C114.640625,70.3164062 113.269206,76.9241536 116.510742,84.1552734 C119.752279,91.3863932 125.36263,95.0019531 133.341797,95.0019531 L133.341797,95.0019531 L171.492188,95.0019531 L171.492188,170.554688 L95.9394531,170.554688 L95.9394531,132.404297 C95.9394531,124.42513 92.3238932,118.814779 85.0927734,115.573242 C77.8616536,112.331706 71.2539062,113.703125 65.2695312,119.6875 L65.2695312,119.6875 L6.17382812,178.783203 C2.68294271,182.274089 0.9375,186.513021 0.9375,191.5 C0.9375,196.486979 2.68294271,200.725911 6.17382812,204.216797 L6.17382812,204.216797 L65.2695312,263.3125 C71.2539062,268.798177 77.8616536,270.044922 85.0927734,267.052734 C92.3238932,264.060547 95.9394531,258.57487 95.9394531,250.595703 L95.9394531,250.595703 L95.9394531,212.445312 L171.492188,212.445312 L171.492188,287.998047 L133.341797,287.998047 C125.36263,287.998047 119.876953,291.613607 116.884766,298.844727 C113.892578,306.075846 115.139323,312.683594 120.625,318.667969 L120.625,318.667969 L179.720703,377.763672 C183.211589,381.254557 187.450521,383 192.4375,383 Z'%3E%3C/path%3E%3C/g%3E%3C/svg%3E\");width:11px;height:11px;background-size:cover;background-repeat:no-repeat}.arrow-down{position:absolute;right:5px;top:0}.arrow-down svg{width:8px;margin-top:5px;margin-left:5px;opacity:0.4}.cell-value-wrapper{margin-right:10px;overflow:hidden;text-overflow:ellipsis}.revo-button{position:relative;overflow:hidden;color:#fff;background-color:#6200ee;height:34px;line-height:34px;padding:0 15px;outline:0;border:0;border-radius:7px;box-sizing:border-box;cursor:pointer}.revo-button.green{background-color:#2ee072;border:1px solid #20d565}.revo-button.red{background-color:#E0662E;border:1px solid #d55920}.revo-button:disabled,.revo-button[disabled]{cursor:not-allowed !important;filter:opacity(0.35) !important}.revo-button.light{border:2px solid #cedefa;line-height:32px;background:none;color:#4876ca;box-shadow:none}revogr-filter-panel{position:absolute;display:block;top:0;left:0;z-index:100;opacity:1;transform:none;background-color:#fff;transform-origin:62px 0px;box-shadow:0 5px 18px -2px rgba(0, 0, 0, 0.2);padding:10px;border-radius:4px;min-width:220px;text-align:left}revogr-filter-panel .filter-holder>div{display:flex;flex-direction:column}revogr-filter-panel label{color:gray;font-size:13px;font-weight:600;display:block;padding:8px 0}revogr-filter-panel select{width:100%}revogr-filter-panel input[type=text]{border:0;min-height:34px;margin:5px 0;background:#f3f3f3;border-radius:5px;padding:0 10px;box-sizing:border-box;width:100%}revogr-filter-panel button{margin-top:10px;margin-right:5px}revogr-filter-panel .filter-actions{text-align:right;margin-right:-5px}.rgHeaderCell:hover .rv-filter{transition:opacity 267ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, transform 178ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.rgHeaderCell:hover .rv-filter,.rgHeaderCell .rv-filter.active{opacity:1}.rgHeaderCell .rv-filter{height:24px;width:24px;background:none;border:0;opacity:0;visibility:visible;cursor:pointer;border-radius:4px}.rgHeaderCell .rv-filter.active{color:#10224a}.rgHeaderCell .rv-filter .filter-img{color:gray;width:11px}.select-css{display:block;font-family:sans-serif;font-weight:600;color:#444;line-height:1.3;padding:0.6em 1.4em 0.5em 0.8em;width:100%;max-width:100%;box-sizing:border-box;margin:0;border:1px solid #f1f1f1;box-shadow:transparent;border-radius:0.5em;appearance:none;background-color:#fff;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23007CB2%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%);background-repeat:no-repeat, repeat;background-position:right 0.7em top 50%, 0 0;background-size:0.65em auto, 100%;}.select-css::-ms-expand{display:none}.select-css:hover{border-color:#c5c5c5}.select-css:focus{border-color:#f1f1f1;box-shadow:0 0 1px 3px rgba(59, 153, 252, 0.7);box-shadow:0 0 0 3px -moz-mac-focusring;color:#222;outline:none}.select-css option{font-weight:normal}.select-css:disabled,.select-css[aria-disabled=true]{color:gray;background-image:url(\"data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22graytext%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E\"), linear-gradient(to bottom, #ffffff 0%, #ffffff 100%)}.select-css:disabled:hover,.select-css[aria-disabled=true]{border-color:#f1f1f1}.multi-filter-list{margin-top:5px;margin-bottom:5px}.multi-filter-list div{white-space:nowrap}.multi-filter-list .multi-filter-list-action{display:flex;justify-content:space-between;align-items:center}.multi-filter-list .and-or-button{margin:0 0 0 10px;min-width:58px;cursor:pointer}.multi-filter-list .trash-button{margin:0 0 -2px 6px;cursor:pointer;width:22px;height:22px;color:gray;font-size:18px}.multi-filter-list .trash-button .trash-img{width:1em}.add-filter-divider{display:block;margin:0 -10px 10px -10px;border-bottom:1px solid #d9d9d9;height:10px;box-shadow:0 4px 5px rgba(0, 0, 0, 0.05)}.select-input{display:flex;justify-content:space-between;align-items:center}";var p="none";var u="multi-filter-list";var f="multi-filter-list-action";var h=t("revogr_filter_panel",function(){function t(t){var e=this;r(this,t);this.filterChange=i(this,"filterChange",7);this.filterCaptionsInternal={title:"Filter by condition",save:"Save",reset:"Reset",cancel:"Close"};this.isFilterIdSet=false;this.filterId=0;this.currentFilterId=-1;this.currentFilterType=p;this.filterItems={};this.filterTypes={};this.filterNames={};this.filterEntities={};this.debouncedApplyFilter=o((function(){e.filterChange.emit(e.filterItems)}),400)}t.prototype.onMouseDown=function(t){if(this.changes&&!t.defaultPrevented){var e=t.target;if(this.isOutside(e)&&!s(e)){this.changes=undefined}}};t.prototype.show=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.changes=t;if(this.changes){this.changes.type=this.changes.type||p}return[2]}))}))};t.prototype.getChanges=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){return[2,this.changes]}))}))};t.prototype.componentWillRender=function(){if(!this.isFilterIdSet){this.isFilterIdSet=true;var t=Object.keys(this.filterItems);for(var e=0,r=t;e<r.length;e++){var i=r[e];this.filterId+=this.filterItems[i].length}}};t.prototype.renderSelectOptions=function(t,r){var i=this;if(r===void 0){r=false}var n;var o=[];var s=(n=this.changes)===null||n===void 0?void 0:n.prop;if(!r){o.push(e("option",{selected:this.currentFilterType===p,value:p},s&&this.filterItems[s]&&this.filterItems[s].length>0?"Add more condition...":this.filterNames[p]))}for(var l in this.filterTypes){o.push.apply(o,this.filterTypes[l].map((function(r){return e("option",{value:r,selected:t===r},i.filterNames[r])})));o.push(e("option",{disabled:true}))}return o};t.prototype.renderExtra=function(t,r){var i=this;var n=this.filterItems[t];if(!n)return"";if(this.filterEntities[n[r].type].extra!=="input")return"";return e("input",{id:"filter-input-"+n[r].id,placeholder:"Enter value...",type:"text",value:n[r].value,onInput:this.onUserInput.bind(this,r,t),onKeyDown:function(t){return i.onKeyDown(t)}})};t.prototype.getFilterItemsList=function(){var t=this;var r;var i=(r=this.changes)===null||r===void 0?void 0:r.prop;if(!(i||i===0))return"";var n=this.filterItems[i]||[];return e("div",{key:this.filterId},n.map((function(r,n){var o;if(n!==t.filterItems[i].length-1){o=e("div",{onClick:function(){return t.toggleFilterAndOr(r.id)}},e(l,{isAnd:r.relation==="and"}))}return e("div",{key:r.id,class:u},e("div",{class:{"select-input":true}},e("select",{class:"select-css select-filter",onChange:function(e){return t.onFilterTypeChange(e,i,n)}},t.renderSelectOptions(t.filterItems[i][n].type,true)),e("div",{class:f},o),e("div",{onClick:function(){return t.onRemoveFilter(r.id)}},e(a,null))),e("div",null,t.renderExtra(i,n)))})),n.length>0?e("div",{class:"add-filter-divider"}):"")};t.prototype.render=function(){var t=this;if(!this.changes){return e(n,{style:{display:"none"}})}var r={display:"block",left:this.changes.x+"px",top:this.changes.y+"px"};var i=Object.assign(this.filterCaptionsInternal,this.filterCaptions);return e(n,{style:r},e("label",null,i.title),e("div",{class:"filter-holder"},this.getFilterItemsList()),e("div",{class:"add-filter"},e("select",{id:"add-filter",class:"select-css",onChange:function(e){return t.onAddNewFilter(e)}},this.renderSelectOptions(this.currentFilterType))),e("div",{class:"filter-actions"},e(c,{class:{red:true},onClick:function(){return t.onReset()}},i.reset),e(c,{class:{light:true},onClick:function(){return t.onCancel()}},i.cancel)))};t.prototype.onFilterTypeChange=function(t,e,r){var i=this;var n=t.target;var o=n.value;this.filterItems[e][r].type=o;this.filterId++;setTimeout((function(){var t=document.getElementById("filter-input-"+i.filterItems[e][r].id);if(t)t.focus()}),0);this.debouncedApplyFilter()};t.prototype.onAddNewFilter=function(t){var e=t.target;var r=e.value;this.currentFilterType=r;this.addNewFilterToProp();var i=document.getElementById("add-filter");if(i){i.value=p;this.currentFilterType=p}this.debouncedApplyFilter()};t.prototype.addNewFilterToProp=function(){var t=this;var e;var r=(e=this.changes)===null||e===void 0?void 0:e.prop;if(!(r||r===0))return;if(!this.filterItems[r]){this.filterItems[r]=[]}if(this.currentFilterType==="none")return;this.filterId++;this.currentFilterId=this.filterId;this.filterItems[r].push({id:this.currentFilterId,type:this.currentFilterType,value:"",relation:"and"});setTimeout((function(){var e=document.getElementById("filter-input-"+t.currentFilterId);if(e)e.focus()}),0)};t.prototype.onUserInput=function(t,e,r){this.filterItems[e][t].value=r.target.value;this.debouncedApplyFilter()};t.prototype.onKeyDown=function(t){if(t.key.toLowerCase()==="enter"){var e=document.getElementById("add-filter");if(e){e.value=p;this.currentFilterType=p;this.addNewFilterToProp();e.focus()}return}t.stopPropagation()};t.prototype.onCancel=function(){this.changes=undefined};t.prototype.onReset=function(){this.assertChanges();delete this.filterItems[this.changes.prop];this.filterId++;this.filterChange.emit(this.filterItems)};t.prototype.onRemoveFilter=function(t){this.assertChanges();this.filterId++;var e=this.changes.prop;var r=this.filterItems[e];if(!r)return;var i=r.findIndex((function(e){return e.id===t}));if(i===-1)return;r.splice(i,1);if(r.length===0)delete this.filterItems[e];this.debouncedApplyFilter()};t.prototype.toggleFilterAndOr=function(t){this.assertChanges();this.filterId++;var e=this.changes.prop;var r=this.filterItems[e];if(!r)return;var i=r.findIndex((function(e){return e.id===t}));if(i===-1)return;r[i].relation=r[i].relation==="and"?"or":"and";this.debouncedApplyFilter()};t.prototype.assertChanges=function(){if(!this.changes){throw new Error("Changes required per edit")}};t.prototype.isOutside=function(t){var e=document.getElementById("add-filter");if(e)e.value=p;this.currentFilterType=p;this.changes.type=p;this.currentFilterId=-1;if(t.classList.contains('[uuid="'+this.uuid+'"]')){return false}return!(t===null||t===void 0?void 0:t.closest('[uuid="'+this.uuid+'"]'))};return t}());h.style=d}}}));
@@ -341,9 +341,13 @@ export declare class RevoGridComponent {
341
341
  */
342
342
  getPlugins(): Promise<RevoPlugin.Plugin[]>;
343
343
  /**
344
- * Get all active plugins instances
344
+ * Get the currently focused cell.
345
345
  */
346
346
  getFocused(): Promise<FocusedData | null>;
347
+ /**
348
+ * Get the currently selected Range.
349
+ */
350
+ getSelectedRange(): Promise<Selection.RangeArea | null>;
347
351
  /** Clear data which is outside of grid container */
348
352
  private handleOutsideClick;
349
353
  /** DRAG AND DROP */
@@ -58,6 +58,7 @@ export default class ViewportService {
58
58
  clearFocused(): void;
59
59
  clearEdit(): void;
60
60
  getFocused(): FocusedData | null;
61
+ getSelectedRange(): Selection.RangeArea | null;
61
62
  setEdit(rowIndex: number, colIndex: number, colType: RevoGrid.DimensionCols, rowType: RevoGrid.DimensionRows): void;
62
63
  }
63
64
  export {};
@@ -7,15 +7,15 @@
7
7
  import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
8
8
  import { Edition, Observable, RevoGrid, RevoPlugin, Selection, ThemeSpace } from "./interfaces";
9
9
  import { AutoSizeColumnConfig } from "./plugins/autoSizeColumn";
10
- import { ColumnFilterConfig, FilterCollection } from "./plugins/filter/filter.plugin";
10
+ import { ColumnFilterConfig, FilterCaptions, FilterCollection } from "./plugins/filter/filter.plugin";
11
11
  import { GroupingOptions } from "./plugins/groupingRow/grouping.row.types";
12
12
  import { FocusedData } from "./components/revo-grid/viewport.service";
13
13
  import { ColumnCollection } from "./services/column.data.provider";
14
14
  import { DataInput } from "./plugins/export/types";
15
15
  import { VNode } from "./stencil-public-runtime";
16
16
  import { ColumnSource, RowSource } from "./components/data/columnService";
17
+ import { MultiFilterItem, ShowData } from "./plugins/filter/filter.pop";
17
18
  import { LogicFunction } from "./plugins/filter/filter.types";
18
- import { FilterItem, ShowData } from "./plugins/filter/filter.pop";
19
19
  import { DataSourceState, Groups } from "./store/dataSource/data.store";
20
20
  import { ViewportData } from "./components/revo-grid/viewport.interfaces";
21
21
  import { ElementScroll } from "./components/revo-grid/viewport.scrolling.service";
@@ -79,13 +79,17 @@ export namespace Components {
79
79
  */
80
80
  "getColumns": () => Promise<RevoGrid.ColumnRegular[]>;
81
81
  /**
82
- * Get all active plugins instances
82
+ * Get the currently focused cell.
83
83
  */
84
84
  "getFocused": () => Promise<FocusedData | null>;
85
85
  /**
86
86
  * Get all active plugins instances
87
87
  */
88
88
  "getPlugins": () => Promise<RevoPlugin.Plugin[]>;
89
+ /**
90
+ * Get the currently selected Range.
91
+ */
92
+ "getSelectedRange": () => Promise<Selection.RangeArea | null>;
89
93
  /**
90
94
  * Get data from source
91
95
  */
@@ -232,7 +236,9 @@ export namespace Components {
232
236
  "editor": Edition.EditorCtr | null;
233
237
  }
234
238
  interface RevogrFilterPanel {
239
+ "filterCaptions": FilterCaptions | undefined;
235
240
  "filterEntities": Record<string, LogicFunction>;
241
+ "filterItems": MultiFilterItem;
236
242
  "filterNames": Record<string, string>;
237
243
  "filterTypes": Record<string, string[]>;
238
244
  "getChanges": () => Promise<ShowData>;
@@ -689,10 +695,12 @@ declare namespace LocalJSX {
689
695
  "onCloseEdit"?: (event: CustomEvent<boolean | undefined>) => void;
690
696
  }
691
697
  interface RevogrFilterPanel {
698
+ "filterCaptions"?: FilterCaptions | undefined;
692
699
  "filterEntities"?: Record<string, LogicFunction>;
700
+ "filterItems"?: MultiFilterItem;
693
701
  "filterNames"?: Record<string, string>;
694
702
  "filterTypes"?: Record<string, string[]>;
695
- "onFilterChange"?: (event: CustomEvent<FilterItem>) => void;
703
+ "onFilterChange"?: (event: CustomEvent<MultiFilterItem>) => void;
696
704
  "uuid"?: string;
697
705
  }
698
706
  interface RevogrFocus {
@@ -2,9 +2,13 @@ import { RevoGrid } from '../../interfaces';
2
2
  export declare const FILTER_BUTTON_CLASS = "rv-filter";
3
3
  export declare const FILTER_BUTTON_ACTIVE = "active";
4
4
  export declare const FILTER_PROP = "hasFilter";
5
+ export declare const AND_OR_BUTTON = "and-or-button";
6
+ export declare const TRASH_BUTTON = "trash-button";
5
7
  declare type Props = {
6
8
  column: RevoGrid.ColumnRegular;
7
9
  };
8
10
  export declare const FilterButton: ({ column }: Props) => any;
11
+ export declare const TrashButton: () => any;
12
+ export declare const AndOrButton: ({ isAnd }: any) => any;
9
13
  export declare function isFilterBtn(e: HTMLElement): true | Element;
10
14
  export {};
@@ -1,6 +1,6 @@
1
1
  import BasePlugin from '../basePlugin';
2
2
  import { RevoGrid } from '../../interfaces';
3
- import { FilterItem } from './filter.pop';
3
+ import { MultiFilterItem } from './filter.pop';
4
4
  import { FilterType } from './filter.service';
5
5
  import { LogicFunction } from './filter.types';
6
6
  declare type CustomFilter = {
@@ -8,18 +8,32 @@ declare type CustomFilter = {
8
8
  name: string;
9
9
  func: LogicFunction;
10
10
  };
11
+ export declare type FilterCaptions = {
12
+ title: string;
13
+ save: string;
14
+ reset: string;
15
+ cancel: string;
16
+ };
17
+ export declare type FilterLocalization = {
18
+ captions: FilterCaptions;
19
+ filterNames: Record<FilterType, string>;
20
+ };
11
21
  /**
12
22
  * @typedef ColumnFilterConfig
13
23
  * @type {object}
14
24
  * @property {FilterCollection|undefined} collection - preserved filter data
15
25
  * @property {string[]|undefined} include - filters to be included, if defined everything else out of scope will be ignored
16
26
  * @property {Record<string, CustomFilter>|undefined} customFilters - hash map of {FilterType:CustomFilter}.
27
+ * @property {FilterLocalization|undefined} localization - translation for filter popup captions.
28
+ * @property {MultiFilterItem|undefined} multiFilterItems - data for multi filtering.
17
29
  * A way to define your own filter types per column
18
30
  */
19
31
  export declare type ColumnFilterConfig = {
20
32
  collection?: FilterCollection;
21
33
  include?: string[];
22
34
  customFilters?: Record<string, CustomFilter>;
35
+ localization?: FilterLocalization;
36
+ multiFilterItems?: MultiFilterItem;
23
37
  };
24
38
  declare type FilterCollectionItem = {
25
39
  filter: LogicFunction;
@@ -32,6 +46,7 @@ export default class FilterPlugin extends BasePlugin {
32
46
  protected revogrid: HTMLRevoGridElement;
33
47
  private pop;
34
48
  private filterCollection;
49
+ private multiFilterItems;
35
50
  private possibleFilters;
36
51
  private possibleFilterNames;
37
52
  private possibleFilterEntities;
@@ -41,16 +56,10 @@ export default class FilterPlugin extends BasePlugin {
41
56
  private getColumnFilter;
42
57
  private isValidType;
43
58
  private onFilterChange;
44
- /**
45
- * Apply filters collection to extend existing one or override
46
- * @method
47
- * @param conditions - list of filters to apply
48
- */
49
- filterByProps(conditions: Record<RevoGrid.ColumnProp, FilterItem>, override?: boolean): Promise<void>;
50
59
  /**
51
60
  * Triggers grid filtering
52
61
  */
53
- doFiltering(collection: FilterCollection, items: RevoGrid.DataType[], columns: RevoGrid.ColumnRegular[]): Promise<void>;
62
+ doFiltering(collection: FilterCollection, items: RevoGrid.DataType[], columns: RevoGrid.ColumnRegular[], filterItems: MultiFilterItem): Promise<void>;
54
63
  clearFiltering(): Promise<void>;
55
64
  private runFiltering;
56
65
  private getData;
@@ -3,6 +3,7 @@ import { FilterType } from './filter.service';
3
3
  import { RevoGrid } from '../../interfaces';
4
4
  import '../../utils/closestPolifill';
5
5
  import { LogicFunction } from './filter.types';
6
+ import { FilterCaptions } from './filter.plugin';
6
7
  /**
7
8
  * @typedef FilterItem
8
9
  * @type {object}
@@ -15,28 +16,51 @@ export declare type FilterItem = {
15
16
  type?: FilterType;
16
17
  value?: any;
17
18
  };
19
+ export declare type FilterData = {
20
+ id: number;
21
+ type: FilterType;
22
+ value?: any;
23
+ relation: 'and' | 'or';
24
+ };
25
+ export declare type MultiFilterItem = {
26
+ [prop: string]: FilterData[];
27
+ };
18
28
  export declare type ShowData = {
19
29
  x: number;
20
30
  y: number;
21
31
  } & FilterItem;
22
32
  export declare class FilterPanel {
23
- private extraElement;
33
+ private filterCaptionsInternal;
34
+ isFilterIdSet: boolean;
35
+ filterId: number;
36
+ currentFilterId: number;
37
+ currentFilterType: FilterType;
24
38
  changes: ShowData | undefined;
25
39
  uuid: string;
40
+ filterItems: MultiFilterItem;
26
41
  filterTypes: Record<string, string[]>;
27
42
  filterNames: Record<string, string>;
28
43
  filterEntities: Record<string, LogicFunction>;
29
- filterChange: EventEmitter<FilterItem>;
44
+ filterCaptions: FilterCaptions | undefined;
45
+ filterChange: EventEmitter<MultiFilterItem>;
30
46
  onMouseDown(e: MouseEvent): void;
31
47
  show(newEntity?: ShowData): Promise<void>;
32
48
  getChanges(): Promise<ShowData>;
33
- renderConditions(type: FilterType): VNode[];
34
- renderExtra(extra?: string, value?: any): any;
49
+ componentWillRender(): void;
50
+ renderSelectOptions(type: FilterType, isDefaultTypeRemoved?: boolean): VNode[];
51
+ renderExtra(prop: RevoGrid.ColumnProp, index: number): any;
52
+ getFilterItemsList(): any;
35
53
  render(): any;
36
- private onFilterChange;
37
- private onInput;
54
+ private onFilterTypeChange;
55
+ private debouncedApplyFilter;
56
+ private onAddNewFilter;
57
+ private addNewFilterToProp;
58
+ private onUserInput;
38
59
  private onKeyDown;
39
60
  private onCancel;
40
- private onSave;
61
+ private onReset;
62
+ private onRemoveFilter;
63
+ private toggleFilterAndOr;
64
+ private assertChanges;
41
65
  private isOutside;
42
66
  }
@@ -19,6 +19,7 @@ export default class SelectionStoreConnector {
19
19
  get focusedStore(): FocusedStore | null;
20
20
  get edit(): EditCellStore | undefined;
21
21
  get focused(): Cell | undefined;
22
+ get selectedRange(): Selection.RangeArea | undefined;
22
23
  private readonly sections;
23
24
  registerSection(e?: Element): void;
24
25
  beforeUpdate(): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@revolist/revogrid",
3
- "version": "3.0.98",
3
+ "version": "3.1.1",
4
4
  "description": "Virtual reactive data grid component - RevoGrid.",
5
5
  "license": "MIT",
6
6
  "directories": {
@@ -1,27 +0,0 @@
1
- 'use strict';
2
-
3
- const index = require('./index-d3f67f2e.js');
4
-
5
- const FILTER_BUTTON_CLASS = 'rv-filter';
6
- const FILTER_BUTTON_ACTIVE = 'active';
7
- const FILTER_PROP = 'hasFilter';
8
- const FilterButton = ({ column }) => {
9
- return (index.h("span", null,
10
- index.h("button", { class: {
11
- [FILTER_BUTTON_CLASS]: true,
12
- [FILTER_BUTTON_ACTIVE]: column && !!column[FILTER_PROP],
13
- } },
14
- index.h("svg", { class: "filter-img", viewBox: "0 0 64 64" },
15
- index.h("g", { stroke: "none", "stroke-width": "1", fill: "none", "fill-rule": "evenodd" },
16
- index.h("path", { d: "M43,48 L43,56 L21,56 L21,48 L43,48 Z M53,28 L53,36 L12,36 L12,28 L53,28 Z M64,8 L64,16 L0,16 L0,8 L64,8 Z", fill: "currentColor" }))))));
17
- };
18
- function isFilterBtn(e) {
19
- if (e.classList.contains(FILTER_BUTTON_CLASS)) {
20
- return true;
21
- }
22
- return e === null || e === void 0 ? void 0 : e.closest(`.${FILTER_BUTTON_CLASS}`);
23
- }
24
-
25
- exports.FILTER_PROP = FILTER_PROP;
26
- exports.FilterButton = FilterButton;
27
- exports.isFilterBtn = isFilterBtn;
@@ -1,23 +0,0 @@
1
- import { h } from './index-42c84e7c.js';
2
-
3
- const FILTER_BUTTON_CLASS = 'rv-filter';
4
- const FILTER_BUTTON_ACTIVE = 'active';
5
- const FILTER_PROP = 'hasFilter';
6
- const FilterButton = ({ column }) => {
7
- return (h("span", null,
8
- h("button", { class: {
9
- [FILTER_BUTTON_CLASS]: true,
10
- [FILTER_BUTTON_ACTIVE]: column && !!column[FILTER_PROP],
11
- } },
12
- h("svg", { class: "filter-img", viewBox: "0 0 64 64" },
13
- h("g", { stroke: "none", "stroke-width": "1", fill: "none", "fill-rule": "evenodd" },
14
- h("path", { d: "M43,48 L43,56 L21,56 L21,48 L43,48 Z M53,28 L53,36 L12,36 L12,28 L53,28 Z M64,8 L64,16 L0,16 L0,8 L64,8 Z", fill: "currentColor" }))))));
15
- };
16
- function isFilterBtn(e) {
17
- if (e.classList.contains(FILTER_BUTTON_CLASS)) {
18
- return true;
19
- }
20
- return e === null || e === void 0 ? void 0 : e.closest(`.${FILTER_BUTTON_CLASS}`);
21
- }
22
-
23
- export { FILTER_PROP as F, FilterButton as a, isFilterBtn as i };
@@ -1 +0,0 @@
1
- import{h}from"./index-42c84e7c.js";var FILTER_BUTTON_CLASS="rv-filter";var FILTER_BUTTON_ACTIVE="active";var FILTER_PROP="hasFilter";var FilterButton=function(t){var r;var e=t.column;return h("span",null,h("button",{class:(r={},r[FILTER_BUTTON_CLASS]=true,r[FILTER_BUTTON_ACTIVE]=e&&!!e[FILTER_PROP],r)},h("svg",{class:"filter-img",viewBox:"0 0 64 64"},h("g",{stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},h("path",{d:"M43,48 L43,56 L21,56 L21,48 L43,48 Z M53,28 L53,36 L12,36 L12,28 L53,28 Z M64,8 L64,16 L0,16 L0,8 L64,8 Z",fill:"currentColor"})))))};function isFilterBtn(t){if(t.classList.contains(FILTER_BUTTON_CLASS)){return true}return t===null||t===void 0?void 0:t.closest("."+FILTER_BUTTON_CLASS)}export{FILTER_PROP as F,FilterButton as a,isFilterBtn as i};
@@ -1 +0,0 @@
1
- import{h as l}from"./index-a7f99799.js";const r="hasFilter",e=({column:r})=>l("span",null,l("button",{class:{"rv-filter":!0,active:r&&!!r.hasFilter}},l("svg",{class:"filter-img",viewBox:"0 0 64 64"},l("g",{stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},l("path",{d:"M43,48 L43,56 L21,56 L21,48 L43,48 Z M53,28 L53,36 L12,36 L12,28 L53,28 Z M64,8 L64,16 L0,16 L0,8 L64,8 Z",fill:"currentColor"})))));function t(l){return!!l.classList.contains("rv-filter")||(null==l?void 0:l.closest(".rv-filter"))}export{r as F,e as a,t as i}
@@ -1 +0,0 @@
1
- System.register(["./index-a15e7527.system.js"],(function(t){"use strict";var e;return{setters:[function(t){e=t.h}],execute:function(){t("i",l);var r="rv-filter";var n="active";var i=t("F","hasFilter");var s=t("a",(function(t){var s;var l=t.column;return e("span",null,e("button",{class:(s={},s[r]=true,s[n]=l&&!!l[i],s)},e("svg",{class:"filter-img",viewBox:"0 0 64 64"},e("g",{stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},e("path",{d:"M43,48 L43,56 L21,56 L21,48 L43,48 Z M53,28 L53,36 L12,36 L12,28 L53,28 Z M64,8 L64,16 L0,16 L0,8 L64,8 Z",fill:"currentColor"})))))}));function l(t){if(t.classList.contains(r)){return true}return t===null||t===void 0?void 0:t.closest("."+r)}}}}));