@revolist/revogrid 3.0.96 → 3.0.99

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 (50) hide show
  1. package/custom-element/index.js +147 -56
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/revo-grid.cjs.js +1 -1
  4. package/dist/cjs/revo-grid_11.cjs.entry.js +115 -49
  5. package/dist/cjs/revogr-filter-panel.cjs.entry.js +31 -6
  6. package/dist/collection/components/data/revogr-data-style.css +8 -0
  7. package/dist/collection/components/header/revogr-header-style.css +8 -0
  8. package/dist/collection/components/overlay/editors/text.js +1 -1
  9. package/dist/collection/components/overlay/revogr-edit-style.css +8 -0
  10. package/dist/collection/components/overlay/revogr-overlay-selection.js +3 -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 +40 -10
  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 +1 -1
  20. package/dist/collection/plugins/filter/filter.plugin.js +11 -1
  21. package/dist/collection/plugins/filter/filter.pop.js +54 -7
  22. package/dist/collection/plugins/filter/filter.style.css +14 -1
  23. package/dist/collection/plugins/sorting/sorting.plugin.js +70 -32
  24. package/dist/collection/services/column.data.provider.js +4 -2
  25. package/dist/collection/services/selection.store.connector.js +4 -0
  26. package/dist/collection/utilsExternal/generate-data.js +7 -1
  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 +115 -49
  30. package/dist/esm/revogr-filter-panel.entry.js +31 -6
  31. package/dist/esm-es5/loader.js +1 -1
  32. package/dist/esm-es5/revo-grid.js +1 -1
  33. package/dist/esm-es5/revo-grid_11.entry.js +1 -1
  34. package/dist/esm-es5/revogr-filter-panel.entry.js +1 -1
  35. package/dist/revo-grid/revo-grid.esm.js +1 -1
  36. package/dist/revo-grid/revo-grid.system.js +1 -1
  37. package/dist/revo-grid/revo-grid_11.entry.js +1 -1
  38. package/dist/revo-grid/revo-grid_11.system.entry.js +1 -1
  39. package/dist/revo-grid/revogr-filter-panel.entry.js +1 -1
  40. package/dist/revo-grid/revogr-filter-panel.system.entry.js +1 -1
  41. package/dist/types/components/revo-grid/revo-grid.d.ts +8 -2
  42. package/dist/types/components/revo-grid/viewport.service.d.ts +1 -0
  43. package/dist/types/components.d.ts +11 -3
  44. package/dist/types/interfaces.d.ts +3 -0
  45. package/dist/types/plugins/filter/filter.plugin.d.ts +12 -0
  46. package/dist/types/plugins/filter/filter.pop.d.ts +6 -0
  47. package/dist/types/plugins/sorting/sorting.plugin.d.ts +3 -1
  48. package/dist/types/services/column.data.provider.d.ts +1 -1
  49. package/dist/types/services/selection.store.connector.d.ts +1 -0
  50. package/package.json +1 -1
@@ -28,13 +28,19 @@ const RevoButton = (props, children) => {
28
28
  }
29
29
  })();
30
30
 
31
- const filterStyleCss = ".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}";
31
+ const filterStyleCss = ".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 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}.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}.center{text-align:center}.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}";
32
32
 
33
33
  const defaultType = 'none';
34
34
  const FilterPanel = class {
35
35
  constructor(hostRef) {
36
36
  index.registerInstance(this, hostRef);
37
37
  this.filterChange = index.createEvent(this, "filterChange", 7);
38
+ this.filterCaptionsInternal = {
39
+ title: "Filter by condition",
40
+ save: "Save",
41
+ reset: "Reset",
42
+ cancel: "Cancel",
43
+ };
38
44
  this.filterTypes = {};
39
45
  this.filterNames = {};
40
46
  this.filterEntities = {};
@@ -69,7 +75,7 @@ const FilterPanel = class {
69
75
  this.extraElement = undefined;
70
76
  switch (extra) {
71
77
  case 'input':
72
- return (index.h("input", { type: "text", value: value, onInput: e => (this.changes.value = e.target.value), onKeyDown: e => this.onKeyDown(e), ref: e => (this.extraElement = e) }));
78
+ return (index.h("input", { type: "text", value: value, onInput: (e) => this.onInput(e), onKeyDown: e => this.onKeyDown(e), ref: e => (this.extraElement = e) }));
73
79
  default:
74
80
  return '';
75
81
  }
@@ -83,7 +89,8 @@ const FilterPanel = class {
83
89
  left: `${this.changes.x}px`,
84
90
  top: `${this.changes.y}px`,
85
91
  };
86
- return (index.h(index.Host, { style: style }, index.h("label", null, "Filter by condition"), index.h("select", { class: "select-css", onChange: e => this.onFilterChange(e) }, this.renderConditions(this.changes.type)), index.h("div", null, this.renderExtra(this.filterEntities[this.changes.type].extra, this.changes.value)), index.h(RevoButton, { class: { green: true }, onClick: () => this.onSave() }, "Save"), index.h(RevoButton, { class: { light: true }, onClick: () => this.onCancel() }, "Cancel")));
92
+ const capts = Object.assign(this.filterCaptionsInternal, this.filterCaptions);
93
+ return (index.h(index.Host, { style: style }, index.h("label", null, capts.title), index.h("select", { class: "select-css", onChange: e => this.onFilterChange(e) }, this.renderConditions(this.changes.type)), index.h("div", null, this.renderExtra(this.filterEntities[this.changes.type].extra, this.changes.value)), index.h("div", { class: "center" }, index.h(RevoButton, { class: { green: true }, onClick: () => this.onSave() }, capts.save), index.h(RevoButton, { class: { red: true }, onClick: () => this.onReset() }, capts.reset), index.h(RevoButton, { class: { light: true }, onClick: () => this.onCancel() }, capts.cancel))));
87
94
  }
88
95
  onFilterChange(e) {
89
96
  if (!this.changes) {
@@ -93,19 +100,24 @@ const FilterPanel = class {
93
100
  const type = el.value;
94
101
  this.changes = Object.assign(Object.assign({}, this.changes), { type });
95
102
  }
103
+ onInput(e) {
104
+ this.changes.value = e.target.value;
105
+ // prevent grid focus and other unexpected events
106
+ e.preventDefault();
107
+ }
96
108
  onKeyDown(e) {
97
109
  if (e.key.toLowerCase() === 'enter') {
98
110
  this.onSave();
99
111
  }
112
+ // keep event local, don't escalate farther to dom
113
+ e.stopPropagation();
100
114
  }
101
115
  onCancel() {
102
116
  this.changes = undefined;
103
117
  }
104
118
  onSave() {
105
119
  var _a, _b;
106
- if (!this.changes) {
107
- throw new Error('Changes required per edit');
108
- }
120
+ this.assertChanges();
109
121
  this.filterChange.emit({
110
122
  prop: this.changes.prop,
111
123
  type: this.changes.type,
@@ -113,6 +125,19 @@ const FilterPanel = class {
113
125
  });
114
126
  this.changes = undefined;
115
127
  }
128
+ onReset() {
129
+ this.assertChanges();
130
+ this.filterChange.emit({
131
+ prop: this.changes.prop,
132
+ type: "none",
133
+ });
134
+ this.changes = void 0;
135
+ }
136
+ assertChanges() {
137
+ if (!this.changes) {
138
+ throw new Error('Changes required per edit');
139
+ }
140
+ }
116
141
  isOutside(e) {
117
142
  if (e.classList.contains(`[uuid="${this.uuid}"]`)) {
118
143
  return false;
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -53,6 +53,14 @@
53
53
  background-color: #2ee072;
54
54
  border: 1px solid #20d565;
55
55
  }
56
+ .revo-button.red {
57
+ background-color: #E0662E;
58
+ border: 1px solid #d55920;
59
+ }
60
+ .revo-button:disabled, .revo-button[disabled] {
61
+ cursor: not-allowed !important;
62
+ filter: opacity(0.35) !important;
63
+ }
56
64
  .revo-button.light {
57
65
  border: 2px solid #cedefa;
58
66
  line-height: 32px;
@@ -18,7 +18,7 @@ export class TextEditor {
18
18
  onKeyDown(e) {
19
19
  const isEnter = isEnterKey(e.code);
20
20
  const isKeyTab = isTab(e.code);
21
- if ((isKeyTab || isEnter) && e.target && this.saveCallback) {
21
+ if ((isKeyTab || isEnter) && e.target && this.saveCallback && !e.isComposing) {
22
22
  // blur is needed to avoid autoscroll
23
23
  this.editInput.blur();
24
24
  // request callback which will close cell after all
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -46,6 +46,9 @@ export class OverlaySelection {
46
46
  /** Recived keyboard down from element */
47
47
  onKeyDown(e) {
48
48
  var _a;
49
+ if (e.defaultPrevented) {
50
+ return;
51
+ }
49
52
  (_a = this.keyboardService) === null || _a === void 0 ? void 0 : _a.keyDown(e, this.range);
50
53
  }
51
54
  /** Create selection store */
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -238,8 +238,8 @@ export class RevoGridComponent {
238
238
  * @param index - virtual column index
239
239
  * @param order - order to apply
240
240
  */
241
- async updateColumnSorting(column, index, order) {
242
- return this.columnProvider.updateColumnSorting(column, index, order);
241
+ async updateColumnSorting(column, index, order, additive) {
242
+ return this.columnProvider.updateColumnSorting(column, index, order, additive);
243
243
  }
244
244
  /**
245
245
  * Clears column sorting
@@ -273,12 +273,19 @@ export class RevoGridComponent {
273
273
  return [...this.internalPlugins];
274
274
  }
275
275
  /**
276
- * Get all active plugins instances
276
+ * Get the currently focused cell.
277
277
  */
278
278
  async getFocused() {
279
279
  var _a;
280
280
  return (_a = this.viewport) === null || _a === void 0 ? void 0 : _a.getFocused();
281
281
  }
282
+ /**
283
+ * Get the currently selected Range.
284
+ */
285
+ async getSelectedRange() {
286
+ var _a;
287
+ return (_a = this.viewport) === null || _a === void 0 ? void 0 : _a.getSelectedRange();
288
+ }
282
289
  // --------------------------------------------------------------------------
283
290
  //
284
291
  // Listeners outside scope
@@ -965,7 +972,7 @@ export class RevoGridComponent {
965
972
  "mutable": false,
966
973
  "complexType": {
967
974
  "original": "boolean | ColumnFilterConfig",
968
- "resolved": "boolean | { collection?: FilterCollection; include?: string[]; customFilters?: Record<string, CustomFilter>; }",
975
+ "resolved": "boolean | { collection?: FilterCollection; include?: string[]; customFilters?: Record<string, CustomFilter>; localization?: FilterLocalization; }",
969
976
  "references": {
970
977
  "ColumnFilterConfig": {
971
978
  "location": "import",
@@ -1207,8 +1214,8 @@ export class RevoGridComponent {
1207
1214
  "text": "Before sorting apply.\nUse e.preventDefault() to prevent sorting data change."
1208
1215
  },
1209
1216
  "complexType": {
1210
- "original": "{\n column: RevoGrid.ColumnRegular;\n order: 'desc' | 'asc';\n }",
1211
- "resolved": "{ column: ColumnRegular; order: \"desc\" | \"asc\"; }",
1217
+ "original": "{\n column: RevoGrid.ColumnRegular;\n order: 'desc' | 'asc';\n additive: boolean;\n }",
1218
+ "resolved": "{ column: ColumnRegular; order: \"desc\" | \"asc\"; additive: boolean; }",
1212
1219
  "references": {
1213
1220
  "RevoGrid": {
1214
1221
  "location": "import",
@@ -1227,8 +1234,8 @@ export class RevoGridComponent {
1227
1234
  "text": "Before sorting event.\nInitial sorting triggered, if this event stops no other event called.\nUse e.preventDefault() to prevent sorting."
1228
1235
  },
1229
1236
  "complexType": {
1230
- "original": "{\n column: RevoGrid.ColumnRegular;\n order: 'desc' | 'asc';\n }",
1231
- "resolved": "{ column: ColumnRegular; order: \"desc\" | \"asc\"; }",
1237
+ "original": "{\n column: RevoGrid.ColumnRegular;\n order: 'desc' | 'asc';\n additive: boolean;\n }",
1238
+ "resolved": "{ column: ColumnRegular; order: \"desc\" | \"asc\"; additive: boolean; }",
1232
1239
  "references": {
1233
1240
  "RevoGrid": {
1234
1241
  "location": "import",
@@ -1925,7 +1932,7 @@ export class RevoGridComponent {
1925
1932
  },
1926
1933
  "updateColumnSorting": {
1927
1934
  "complexType": {
1928
- "signature": "(column: RevoGrid.ColumnRegular, index: number, order: 'asc' | 'desc') => Promise<RevoGrid.ColumnRegular>",
1935
+ "signature": "(column: RevoGrid.ColumnRegular, index: number, order: 'asc' | 'desc', additive: boolean) => Promise<RevoGrid.ColumnRegular>",
1929
1936
  "parameters": [{
1930
1937
  "tags": [{
1931
1938
  "text": "column - full column details to update",
@@ -1944,6 +1951,9 @@ export class RevoGridComponent {
1944
1951
  "name": "param"
1945
1952
  }],
1946
1953
  "text": "- order to apply"
1954
+ }, {
1955
+ "tags": [],
1956
+ "text": ""
1947
1957
  }],
1948
1958
  "references": {
1949
1959
  "Promise": {
@@ -2058,7 +2068,27 @@ export class RevoGridComponent {
2058
2068
  "return": "Promise<FocusedData>"
2059
2069
  },
2060
2070
  "docs": {
2061
- "text": "Get all active plugins instances",
2071
+ "text": "Get the currently focused cell.",
2072
+ "tags": []
2073
+ }
2074
+ },
2075
+ "getSelectedRange": {
2076
+ "complexType": {
2077
+ "signature": "() => Promise<Selection.RangeArea | null>",
2078
+ "parameters": [],
2079
+ "references": {
2080
+ "Promise": {
2081
+ "location": "global"
2082
+ },
2083
+ "Selection": {
2084
+ "location": "import",
2085
+ "path": "../../interfaces"
2086
+ }
2087
+ },
2088
+ "return": "Promise<RangeArea>"
2089
+ },
2090
+ "docs": {
2091
+ "text": "Get the currently selected Range.",
2062
2092
  "tags": []
2063
2093
  }
2064
2094
  }
@@ -194,6 +194,9 @@ export default class ViewportService {
194
194
  rowType
195
195
  };
196
196
  }
197
+ getSelectedRange() {
198
+ return this.sv.selectionStoreConnector.selectedRange;
199
+ }
197
200
  setEdit(rowIndex, colIndex, colType, rowType) {
198
201
  var _a;
199
202
  const stores = this.storesByType;
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -5,7 +5,7 @@ const eq = (value, extra) => {
5
5
  if (typeof value !== 'string') {
6
6
  value = JSON.stringify(value);
7
7
  }
8
- return value.toLocaleLowerCase() === extra;
8
+ return value.toLocaleLowerCase() === extra.toString().toLocaleLowerCase();
9
9
  };
10
10
  export const notEq = (value, extra) => !eq(value, extra);
11
11
  notEq.extra = 'input';
@@ -5,6 +5,7 @@ import { filterEntities, filterNames, filterTypes } from './filter.service';
5
5
  export const FILTER_TRIMMED_TYPE = 'filter';
6
6
  export default class FilterPlugin extends BasePlugin {
7
7
  constructor(revogrid, uiid, config) {
8
+ var _a;
8
9
  super(revogrid);
9
10
  this.revogrid = revogrid;
10
11
  this.filterCollection = {};
@@ -23,7 +24,7 @@ export default class FilterPlugin extends BasePlugin {
23
24
  this.addEventListener('headerclick', headerclick);
24
25
  this.addEventListener('aftersourceset', aftersourceset);
25
26
  this.revogrid.registerVNode([
26
- h("revogr-filter-panel", { uuid: `filter-${uiid}`, filterNames: this.possibleFilterNames, filterEntities: this.possibleFilterEntities, onFilterChange: e => this.onFilterChange(e.detail), ref: e => (this.pop = e) }),
27
+ h("revogr-filter-panel", { uuid: `filter-${uiid}`, filterNames: this.possibleFilterNames, filterEntities: this.possibleFilterEntities, filterCaptions: (_a = config.localization) === null || _a === void 0 ? void 0 : _a.captions, onFilterChange: e => this.onFilterChange(e.detail), ref: e => (this.pop = e) }),
27
28
  ]);
28
29
  }
29
30
  initConfig(config) {
@@ -59,6 +60,15 @@ export default class FilterPlugin extends BasePlugin {
59
60
  this.possibleFilters = filters;
60
61
  }
61
62
  }
63
+ if (config.localization) {
64
+ if (config.localization.filterNames) {
65
+ Object.entries(config.localization.filterNames).forEach(([k, v]) => {
66
+ if (this.possibleFilterNames[k] != void 0) {
67
+ this.possibleFilterNames[k] = v;
68
+ }
69
+ });
70
+ }
71
+ }
62
72
  }
63
73
  async headerclick(e) {
64
74
  var _a;
@@ -5,6 +5,12 @@ import '../../utils/closestPolifill';
5
5
  const defaultType = 'none';
6
6
  export class FilterPanel {
7
7
  constructor() {
8
+ this.filterCaptionsInternal = {
9
+ title: "Filter by condition",
10
+ save: "Save",
11
+ reset: "Reset",
12
+ cancel: "Cancel",
13
+ };
8
14
  this.filterTypes = {};
9
15
  this.filterNames = {};
10
16
  this.filterEntities = {};
@@ -39,7 +45,7 @@ export class FilterPanel {
39
45
  this.extraElement = undefined;
40
46
  switch (extra) {
41
47
  case 'input':
42
- return (h("input", { type: "text", value: value, onInput: e => (this.changes.value = e.target.value), onKeyDown: e => this.onKeyDown(e), ref: e => (this.extraElement = e) }));
48
+ return (h("input", { type: "text", value: value, onInput: (e) => this.onInput(e), onKeyDown: e => this.onKeyDown(e), ref: e => (this.extraElement = e) }));
43
49
  default:
44
50
  return '';
45
51
  }
@@ -53,12 +59,15 @@ export class FilterPanel {
53
59
  left: `${this.changes.x}px`,
54
60
  top: `${this.changes.y}px`,
55
61
  };
62
+ const capts = Object.assign(this.filterCaptionsInternal, this.filterCaptions);
56
63
  return (h(Host, { style: style },
57
- h("label", null, "Filter by condition"),
64
+ h("label", null, capts.title),
58
65
  h("select", { class: "select-css", onChange: e => this.onFilterChange(e) }, this.renderConditions(this.changes.type)),
59
66
  h("div", null, this.renderExtra(this.filterEntities[this.changes.type].extra, this.changes.value)),
60
- h(RevoButton, { class: { green: true }, onClick: () => this.onSave() }, "Save"),
61
- h(RevoButton, { class: { light: true }, onClick: () => this.onCancel() }, "Cancel")));
67
+ h("div", { class: "center" },
68
+ h(RevoButton, { class: { green: true }, onClick: () => this.onSave() }, capts.save),
69
+ h(RevoButton, { class: { red: true }, onClick: () => this.onReset() }, capts.reset),
70
+ h(RevoButton, { class: { light: true }, onClick: () => this.onCancel() }, capts.cancel))));
62
71
  }
63
72
  onFilterChange(e) {
64
73
  if (!this.changes) {
@@ -68,19 +77,24 @@ export class FilterPanel {
68
77
  const type = el.value;
69
78
  this.changes = Object.assign(Object.assign({}, this.changes), { type });
70
79
  }
80
+ onInput(e) {
81
+ this.changes.value = e.target.value;
82
+ // prevent grid focus and other unexpected events
83
+ e.preventDefault();
84
+ }
71
85
  onKeyDown(e) {
72
86
  if (e.key.toLowerCase() === 'enter') {
73
87
  this.onSave();
74
88
  }
89
+ // keep event local, don't escalate farther to dom
90
+ e.stopPropagation();
75
91
  }
76
92
  onCancel() {
77
93
  this.changes = undefined;
78
94
  }
79
95
  onSave() {
80
96
  var _a, _b;
81
- if (!this.changes) {
82
- throw new Error('Changes required per edit');
83
- }
97
+ this.assertChanges();
84
98
  this.filterChange.emit({
85
99
  prop: this.changes.prop,
86
100
  type: this.changes.type,
@@ -88,6 +102,19 @@ export class FilterPanel {
88
102
  });
89
103
  this.changes = undefined;
90
104
  }
105
+ onReset() {
106
+ this.assertChanges();
107
+ this.filterChange.emit({
108
+ prop: this.changes.prop,
109
+ type: "none",
110
+ });
111
+ this.changes = void 0;
112
+ }
113
+ assertChanges() {
114
+ if (!this.changes) {
115
+ throw new Error('Changes required per edit');
116
+ }
117
+ }
91
118
  isOutside(e) {
92
119
  if (e.classList.contains(`[uuid="${this.uuid}"]`)) {
93
120
  return false;
@@ -182,6 +209,26 @@ export class FilterPanel {
182
209
  "text": ""
183
210
  },
184
211
  "defaultValue": "{}"
212
+ },
213
+ "filterCaptions": {
214
+ "type": "unknown",
215
+ "mutable": false,
216
+ "complexType": {
217
+ "original": "FilterCaptions | undefined",
218
+ "resolved": "{ title: string; save: string; reset: string; cancel: string; }",
219
+ "references": {
220
+ "FilterCaptions": {
221
+ "location": "import",
222
+ "path": "./filter.plugin"
223
+ }
224
+ }
225
+ },
226
+ "required": false,
227
+ "optional": false,
228
+ "docs": {
229
+ "tags": [],
230
+ "text": ""
231
+ }
185
232
  }
186
233
  }; }
187
234
  static get states() { return {
@@ -52,6 +52,14 @@
52
52
  background-color: #2ee072;
53
53
  border: 1px solid #20d565;
54
54
  }
55
+ .revo-button.red {
56
+ background-color: #E0662E;
57
+ border: 1px solid #d55920;
58
+ }
59
+ .revo-button:disabled, .revo-button[disabled] {
60
+ cursor: not-allowed !important;
61
+ filter: opacity(0.35) !important;
62
+ }
55
63
  .revo-button.light {
56
64
  border: 2px solid #cedefa;
57
65
  line-height: 32px;
@@ -73,7 +81,7 @@ revogr-filter-panel {
73
81
  box-shadow: 0 5px 18px -2px rgba(0, 0, 0, 0.2);
74
82
  padding: 10px;
75
83
  border-radius: 4px;
76
- min-width: 150px;
84
+ min-width: 220px;
77
85
  text-align: left;
78
86
  }
79
87
  revogr-filter-panel label {
@@ -94,6 +102,7 @@ revogr-filter-panel input[type=text] {
94
102
  border-radius: 5px;
95
103
  padding: 0 10px;
96
104
  box-sizing: border-box;
105
+ width: 100%;
97
106
  }
98
107
  revogr-filter-panel button {
99
108
  margin-top: 10px;
@@ -125,6 +134,10 @@ revogr-filter-panel button {
125
134
  width: 11px;
126
135
  }
127
136
 
137
+ .center {
138
+ text-align: center;
139
+ }
140
+
128
141
  .select-css {
129
142
  display: block;
130
143
  font-family: sans-serif;