@revolist/revogrid 4.16.0 → 4.17.0
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.
- package/dist/cjs/{app-globals-CnL-iuWZ.js → app-globals-D67EXhgK.js} +3 -3
- package/dist/cjs/{app-globals-CnL-iuWZ.js.map → app-globals-D67EXhgK.js.map} +1 -1
- package/dist/cjs/{cell-renderer-RYPxTSX7.js → cell-renderer-TmNnqu7r.js} +5 -5
- package/dist/cjs/{cell-renderer-RYPxTSX7.js.map → cell-renderer-TmNnqu7r.js.map} +1 -1
- package/dist/cjs/{column.drag.plugin-CxKQ-GqY.js → column.drag.plugin-pCfjUQwZ.js} +13 -13
- package/dist/cjs/column.drag.plugin-pCfjUQwZ.js.map +1 -0
- package/dist/cjs/{column.service-urln-gkz.js → column.service-euEyR799.js} +4 -4
- package/dist/cjs/{column.service-urln-gkz.js.map → column.service-euEyR799.js.map} +1 -1
- package/dist/cjs/{dimension.helpers-BmZOxsgq.js → dimension.helpers-C5PvAWJW.js} +24 -8
- package/dist/cjs/dimension.helpers-C5PvAWJW.js.map +1 -0
- package/dist/cjs/{edit.utils-Bx3jy_dC.js → edit.utils-T20rr-g4.js} +3 -3
- package/dist/cjs/{edit.utils-Bx3jy_dC.js.map → edit.utils-T20rr-g4.js.map} +1 -1
- package/dist/cjs/{filter.button-rIn9mDMT.js → filter.button-DSsWNs23.js} +3 -3
- package/dist/cjs/{filter.button-rIn9mDMT.js.map → filter.button-DSsWNs23.js.map} +1 -1
- package/dist/cjs/{header-cell-renderer-c5sd3ee7.js → header-cell-renderer-BwHvC5YY.js} +4 -4
- package/dist/cjs/{header-cell-renderer-c5sd3ee7.js.map → header-cell-renderer-BwHvC5YY.js.map} +1 -1
- package/dist/cjs/{index-BbtPQ4Br.js → index-BF1c1pO3.js} +196 -133
- package/dist/cjs/index-BF1c1pO3.js.map +1 -0
- package/dist/cjs/index.cjs.js +10 -10
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/revo-grid.cjs.entry.js +8 -8
- package/dist/cjs/revo-grid.cjs.entry.js.map +1 -1
- package/dist/cjs/revo-grid.cjs.js +4 -4
- package/dist/cjs/revo-grid.cjs.js.map +1 -1
- package/dist/cjs/revo-grid.entry.cjs.js.map +1 -1
- package/dist/cjs/revogr-attribution.revogr-extra.revogr-focus.revogr-overlay-selection.revogr-row-headers.revogr-scroll-virtual.revogr-temp-range.entry.cjs.js.map +1 -1
- package/dist/cjs/revogr-attribution_7.cjs.entry.js +10 -10
- package/dist/cjs/revogr-attribution_7.cjs.entry.js.map +1 -1
- package/dist/cjs/revogr-clipboard.revogr-edit.revogr-order-editor.entry.cjs.js.map +1 -1
- package/dist/cjs/revogr-clipboard_3.cjs.entry.js +5 -5
- package/dist/cjs/revogr-clipboard_3.cjs.entry.js.map +1 -1
- package/dist/cjs/revogr-data.revogr-header.revogr-viewport-scroll.vnode-html.entry.cjs.js.map +1 -1
- package/dist/cjs/revogr-data_4.cjs.entry.js +10 -10
- package/dist/cjs/revogr-data_4.cjs.entry.js.map +1 -1
- package/dist/cjs/revogr-filter-panel.cjs.entry.js +3 -3
- package/dist/cjs/revogr-filter-panel.cjs.entry.js.map +1 -1
- package/dist/cjs/revogr-filter-panel.entry.cjs.js.map +1 -1
- package/dist/cjs/{text-editor-pxAtbkyc.js → text-editor-C6fUGszl.js} +4 -4
- package/dist/cjs/{text-editor-pxAtbkyc.js.map → text-editor-C6fUGszl.js.map} +1 -1
- package/dist/cjs/{throttle-CQppnhEi.js → throttle-BBq2OiCM.js} +3 -3
- package/dist/cjs/{throttle-CQppnhEi.js.map → throttle-BBq2OiCM.js.map} +1 -1
- package/dist/cjs/{viewport.store-BrZDEt69.js → viewport.store-BQqAGkuJ.js} +3 -3
- package/dist/cjs/{viewport.store-BrZDEt69.js.map → viewport.store-BQqAGkuJ.js.map} +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/data/revogr-data-style.css +0 -72
- package/dist/collection/components/editors/revogr-edit-style.css +0 -72
- package/dist/collection/components/header/revogr-header-style.css +0 -72
- package/dist/collection/components/overlay/revogr-overlay-style.css +0 -72
- package/dist/collection/components/revoGrid/revo-grid-style.css +3 -75
- package/dist/collection/components/scroll/revogr-viewport-scroll-style.css +0 -72
- package/dist/collection/components/scrollable/revogr-scroll-style.css +0 -72
- package/dist/collection/components/selectionFocus/revogr-focus-style.css +0 -72
- package/dist/collection/components/selectionTempRange/revogr-temp-range-style.css +0 -72
- package/dist/collection/plugins/filter/filter.style.css +0 -72
- package/dist/collection/plugins/sorting/sorting.func.js +2 -2
- package/dist/collection/plugins/sorting/sorting.func.js.map +1 -1
- package/dist/collection/plugins/sorting/sorting.plugin.js +3 -3
- package/dist/collection/plugins/sorting/sorting.plugin.js.map +1 -1
- package/dist/esm/{app-globals-Bp4Vbqcr.js → app-globals-C3ZHKjnB.js} +3 -3
- package/dist/esm/{app-globals-Bp4Vbqcr.js.map → app-globals-C3ZHKjnB.js.map} +1 -1
- package/dist/{revo-grid/cell-renderer-C6x60eGs.js → esm/cell-renderer-AeQIe3qD.js} +5 -5
- package/dist/{revo-grid/cell-renderer-C6x60eGs.js.map → esm/cell-renderer-AeQIe3qD.js.map} +1 -1
- package/dist/esm/{column.drag.plugin-Capa_0kN.js → column.drag.plugin-Dc7h1kmS.js} +13 -13
- package/dist/esm/column.drag.plugin-Dc7h1kmS.js.map +1 -0
- package/dist/esm/{column.service-QLZCp9EY.js → column.service-DyqJ8oYq.js} +4 -4
- package/dist/{revo-grid/column.service-QLZCp9EY.js.map → esm/column.service-DyqJ8oYq.js.map} +1 -1
- package/dist/{revo-grid/dimension.helpers-pcKIUO61.js → esm/dimension.helpers-D5lwLPzd.js} +24 -8
- package/dist/{revo-grid/dimension.helpers-pcKIUO61.js.map → esm/dimension.helpers-D5lwLPzd.js.map} +1 -1
- package/dist/esm/{edit.utils-BBbK2wbv.js → edit.utils-B6bLKSQh.js} +3 -3
- package/dist/esm/{edit.utils-BBbK2wbv.js.map → edit.utils-B6bLKSQh.js.map} +1 -1
- package/dist/{revo-grid/filter.button-BpZR0kGU.js → esm/filter.button-DmOE7VCJ.js} +3 -3
- package/dist/esm/{filter.button-BpZR0kGU.js.map → filter.button-DmOE7VCJ.js.map} +1 -1
- package/dist/esm/{header-cell-renderer-AAPG96e2.js → header-cell-renderer-XxSVxgM5.js} +4 -4
- package/dist/esm/{header-cell-renderer-AAPG96e2.js.map → header-cell-renderer-XxSVxgM5.js.map} +1 -1
- package/dist/esm/{index-gUcGIzDv.js → index-Dyptvvxf.js} +196 -133
- package/dist/esm/index-Dyptvvxf.js.map +1 -0
- package/dist/esm/index.js +11 -11
- package/dist/esm/loader.js +4 -4
- package/dist/esm/revo-grid.entry.js +8 -8
- package/dist/esm/revo-grid.entry.js.map +1 -1
- package/dist/esm/revo-grid.js +5 -5
- package/dist/esm/revo-grid.js.map +1 -1
- package/dist/esm/revogr-attribution.revogr-extra.revogr-focus.revogr-overlay-selection.revogr-row-headers.revogr-scroll-virtual.revogr-temp-range.entry.js.map +1 -1
- package/dist/esm/revogr-attribution_7.entry.js +10 -10
- package/dist/esm/revogr-attribution_7.entry.js.map +1 -1
- package/dist/esm/revogr-clipboard.revogr-edit.revogr-order-editor.entry.js.map +1 -1
- package/dist/esm/revogr-clipboard_3.entry.js +5 -5
- package/dist/esm/revogr-clipboard_3.entry.js.map +1 -1
- package/dist/esm/revogr-data.revogr-header.revogr-viewport-scroll.vnode-html.entry.js.map +1 -1
- package/dist/esm/revogr-data_4.entry.js +10 -10
- package/dist/esm/revogr-data_4.entry.js.map +1 -1
- package/dist/esm/revogr-filter-panel.entry.js +3 -3
- package/dist/esm/revogr-filter-panel.entry.js.map +1 -1
- package/dist/esm/{text-editor-92MGc5Bc.js → text-editor-DlCRmV75.js} +4 -4
- package/dist/esm/{text-editor-92MGc5Bc.js.map → text-editor-DlCRmV75.js.map} +1 -1
- package/dist/esm/{throttle-Dshl76F1.js → throttle-DcjZyclk.js} +3 -3
- package/dist/{revo-grid/throttle-Dshl76F1.js.map → esm/throttle-DcjZyclk.js.map} +1 -1
- package/dist/{revo-grid/viewport.store-C89n4AEU.js → esm/viewport.store-2mQugd8S.js} +3 -3
- package/dist/{revo-grid/viewport.store-C89n4AEU.js.map → esm/viewport.store-2mQugd8S.js.map} +1 -1
- package/dist/revo-grid/{app-globals-Bp4Vbqcr.js → app-globals-C3ZHKjnB.js} +3 -3
- package/dist/revo-grid/{app-globals-Bp4Vbqcr.js.map → app-globals-C3ZHKjnB.js.map} +1 -1
- package/dist/{esm/cell-renderer-C6x60eGs.js → revo-grid/cell-renderer-AeQIe3qD.js} +5 -5
- package/dist/{esm/cell-renderer-C6x60eGs.js.map → revo-grid/cell-renderer-AeQIe3qD.js.map} +1 -1
- package/dist/revo-grid/{column.drag.plugin-Capa_0kN.js → column.drag.plugin-Dc7h1kmS.js} +13 -13
- package/dist/revo-grid/column.drag.plugin-Dc7h1kmS.js.map +1 -0
- package/dist/revo-grid/{column.service-QLZCp9EY.js → column.service-DyqJ8oYq.js} +4 -4
- package/dist/{esm/column.service-QLZCp9EY.js.map → revo-grid/column.service-DyqJ8oYq.js.map} +1 -1
- package/dist/{esm/dimension.helpers-pcKIUO61.js → revo-grid/dimension.helpers-D5lwLPzd.js} +24 -8
- package/dist/{esm/dimension.helpers-pcKIUO61.js.map → revo-grid/dimension.helpers-D5lwLPzd.js.map} +1 -1
- package/dist/revo-grid/{edit.utils-BBbK2wbv.js → edit.utils-B6bLKSQh.js} +3 -3
- package/dist/revo-grid/{edit.utils-BBbK2wbv.js.map → edit.utils-B6bLKSQh.js.map} +1 -1
- package/dist/{esm/filter.button-BpZR0kGU.js → revo-grid/filter.button-DmOE7VCJ.js} +3 -3
- package/dist/revo-grid/{filter.button-BpZR0kGU.js.map → filter.button-DmOE7VCJ.js.map} +1 -1
- package/dist/revo-grid/{header-cell-renderer-AAPG96e2.js → header-cell-renderer-XxSVxgM5.js} +4 -4
- package/dist/revo-grid/{header-cell-renderer-AAPG96e2.js.map → header-cell-renderer-XxSVxgM5.js.map} +1 -1
- package/dist/revo-grid/{index-gUcGIzDv.js → index-Dyptvvxf.js} +196 -133
- package/dist/revo-grid/index-Dyptvvxf.js.map +1 -0
- package/dist/revo-grid/index.esm.js +11 -11
- package/dist/revo-grid/revo-grid.entry.esm.js.map +1 -1
- package/dist/revo-grid/revo-grid.entry.js +8 -8
- package/dist/revo-grid/revo-grid.entry.js.map +1 -1
- package/dist/revo-grid/revo-grid.esm.js +5 -5
- package/dist/revo-grid/revo-grid.esm.js.map +1 -1
- package/dist/revo-grid/revogr-attribution.revogr-extra.revogr-focus.revogr-overlay-selection.revogr-row-headers.revogr-scroll-virtual.revogr-temp-range.entry.esm.js.map +1 -1
- package/dist/revo-grid/revogr-attribution_7.entry.js +10 -10
- package/dist/revo-grid/revogr-attribution_7.entry.js.map +1 -1
- package/dist/revo-grid/revogr-clipboard.revogr-edit.revogr-order-editor.entry.esm.js.map +1 -1
- package/dist/revo-grid/revogr-clipboard_3.entry.js +5 -5
- package/dist/revo-grid/revogr-clipboard_3.entry.js.map +1 -1
- package/dist/revo-grid/revogr-data.revogr-header.revogr-viewport-scroll.vnode-html.entry.esm.js.map +1 -1
- package/dist/revo-grid/revogr-data_4.entry.js +10 -10
- package/dist/revo-grid/revogr-data_4.entry.js.map +1 -1
- package/dist/revo-grid/revogr-filter-panel.entry.esm.js.map +1 -1
- package/dist/revo-grid/revogr-filter-panel.entry.js +3 -3
- package/dist/revo-grid/revogr-filter-panel.entry.js.map +1 -1
- package/dist/revo-grid/{text-editor-92MGc5Bc.js → text-editor-DlCRmV75.js} +4 -4
- package/dist/revo-grid/{text-editor-92MGc5Bc.js.map → text-editor-DlCRmV75.js.map} +1 -1
- package/dist/revo-grid/{throttle-Dshl76F1.js → throttle-DcjZyclk.js} +3 -3
- package/dist/{esm/throttle-Dshl76F1.js.map → revo-grid/throttle-DcjZyclk.js.map} +1 -1
- package/dist/{esm/viewport.store-C89n4AEU.js → revo-grid/viewport.store-2mQugd8S.js} +3 -3
- package/dist/{esm/viewport.store-C89n4AEU.js.map → revo-grid/viewport.store-2mQugd8S.js.map} +1 -1
- package/dist/types/stencil-public-runtime.d.ts +12 -5
- package/hydrate/index.js +275 -158
- package/hydrate/index.mjs +275 -158
- package/package.json +4 -4
- package/standalone/data.store.js +21 -5
- package/standalone/data.store.js.map +1 -1
- package/standalone/revo-grid.js +7 -7
- package/standalone/revo-grid.js.map +1 -1
- package/standalone/revogr-attribution2.js +1 -1
- package/standalone/revogr-data2.js +2 -2
- package/standalone/revogr-data2.js.map +1 -1
- package/standalone/revogr-edit2.js +2 -2
- package/standalone/revogr-edit2.js.map +1 -1
- package/standalone/revogr-extra2.js +1 -1
- package/standalone/revogr-filter-panel.js +2 -2
- package/standalone/revogr-filter-panel.js.map +1 -1
- package/standalone/revogr-focus2.js +2 -2
- package/standalone/revogr-focus2.js.map +1 -1
- package/standalone/revogr-header2.js +2 -2
- package/standalone/revogr-header2.js.map +1 -1
- package/standalone/revogr-overlay-selection2.js +2 -2
- package/standalone/revogr-overlay-selection2.js.map +1 -1
- package/standalone/revogr-row-headers2.js +1 -1
- package/standalone/revogr-scroll-virtual2.js +2 -2
- package/standalone/revogr-scroll-virtual2.js.map +1 -1
- package/standalone/revogr-temp-range2.js +2 -2
- package/standalone/revogr-temp-range2.js.map +1 -1
- package/standalone/revogr-viewport-scroll2.js +2 -2
- package/standalone/revogr-viewport-scroll2.js.map +1 -1
- package/standalone/vnode-converter.js +1 -1
- package/dist/cjs/column.drag.plugin-CxKQ-GqY.js.map +0 -1
- package/dist/cjs/dimension.helpers-BmZOxsgq.js.map +0 -1
- package/dist/cjs/index-BbtPQ4Br.js.map +0 -1
- package/dist/esm/column.drag.plugin-Capa_0kN.js.map +0 -1
- package/dist/esm/index-gUcGIzDv.js.map +0 -1
- package/dist/revo-grid/column.drag.plugin-Capa_0kN.js.map +0 -1
- package/dist/revo-grid/index-gUcGIzDv.js.map +0 -1
|
@@ -1,75 +1,3 @@
|
|
|
1
|
-
.revo-drag-icon {
|
|
2
|
-
width: 11px;
|
|
3
|
-
opacity: 0.8;
|
|
4
|
-
}
|
|
5
|
-
.revo-drag-icon::before {
|
|
6
|
-
content: "::";
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.revo-alt-icon {
|
|
10
|
-
-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");
|
|
11
|
-
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");
|
|
12
|
-
width: 11px;
|
|
13
|
-
height: 11px;
|
|
14
|
-
background-size: cover;
|
|
15
|
-
background-repeat: no-repeat;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.arrow-down {
|
|
19
|
-
position: absolute;
|
|
20
|
-
right: 5px;
|
|
21
|
-
top: 0;
|
|
22
|
-
}
|
|
23
|
-
.arrow-down svg {
|
|
24
|
-
width: 8px;
|
|
25
|
-
margin-top: 5px;
|
|
26
|
-
margin-left: 5px;
|
|
27
|
-
opacity: 0.4;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.cell-value-wrapper {
|
|
31
|
-
margin-right: 10px;
|
|
32
|
-
overflow: hidden;
|
|
33
|
-
text-overflow: ellipsis;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
.revo-button {
|
|
37
|
-
position: relative;
|
|
38
|
-
overflow: hidden;
|
|
39
|
-
color: #fff;
|
|
40
|
-
background-color: #4545ff;
|
|
41
|
-
height: 32px;
|
|
42
|
-
line-height: 32px;
|
|
43
|
-
padding: 0 15px;
|
|
44
|
-
outline: 0;
|
|
45
|
-
border: 0;
|
|
46
|
-
border-radius: 7px;
|
|
47
|
-
box-sizing: border-box;
|
|
48
|
-
cursor: pointer;
|
|
49
|
-
}
|
|
50
|
-
.revo-button.green {
|
|
51
|
-
background-color: #009037;
|
|
52
|
-
}
|
|
53
|
-
.revo-button.red {
|
|
54
|
-
background-color: #E0662E;
|
|
55
|
-
}
|
|
56
|
-
.revo-button:disabled, .revo-button[disabled] {
|
|
57
|
-
cursor: not-allowed !important;
|
|
58
|
-
filter: opacity(0.35) !important;
|
|
59
|
-
}
|
|
60
|
-
.revo-button.outline {
|
|
61
|
-
border: 1px solid #dbdbdb;
|
|
62
|
-
line-height: 30px;
|
|
63
|
-
background: none;
|
|
64
|
-
color: #000;
|
|
65
|
-
box-shadow: none;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
revo-grid[theme^=dark] .revo-button.outline {
|
|
69
|
-
border: 1px solid #404040;
|
|
70
|
-
color: #d8d8d8;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
1
|
.rowHeaders {
|
|
74
2
|
z-index: 2;
|
|
75
3
|
font-size: 10px;
|
|
@@ -1,75 +1,3 @@
|
|
|
1
|
-
.revo-drag-icon {
|
|
2
|
-
width: 11px;
|
|
3
|
-
opacity: 0.8;
|
|
4
|
-
}
|
|
5
|
-
.revo-drag-icon::before {
|
|
6
|
-
content: "::";
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.revo-alt-icon {
|
|
10
|
-
-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");
|
|
11
|
-
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");
|
|
12
|
-
width: 11px;
|
|
13
|
-
height: 11px;
|
|
14
|
-
background-size: cover;
|
|
15
|
-
background-repeat: no-repeat;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.arrow-down {
|
|
19
|
-
position: absolute;
|
|
20
|
-
right: 5px;
|
|
21
|
-
top: 0;
|
|
22
|
-
}
|
|
23
|
-
.arrow-down svg {
|
|
24
|
-
width: 8px;
|
|
25
|
-
margin-top: 5px;
|
|
26
|
-
margin-left: 5px;
|
|
27
|
-
opacity: 0.4;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.cell-value-wrapper {
|
|
31
|
-
margin-right: 10px;
|
|
32
|
-
overflow: hidden;
|
|
33
|
-
text-overflow: ellipsis;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
.revo-button {
|
|
37
|
-
position: relative;
|
|
38
|
-
overflow: hidden;
|
|
39
|
-
color: #fff;
|
|
40
|
-
background-color: #4545ff;
|
|
41
|
-
height: 32px;
|
|
42
|
-
line-height: 32px;
|
|
43
|
-
padding: 0 15px;
|
|
44
|
-
outline: 0;
|
|
45
|
-
border: 0;
|
|
46
|
-
border-radius: 7px;
|
|
47
|
-
box-sizing: border-box;
|
|
48
|
-
cursor: pointer;
|
|
49
|
-
}
|
|
50
|
-
.revo-button.green {
|
|
51
|
-
background-color: #009037;
|
|
52
|
-
}
|
|
53
|
-
.revo-button.red {
|
|
54
|
-
background-color: #E0662E;
|
|
55
|
-
}
|
|
56
|
-
.revo-button:disabled, .revo-button[disabled] {
|
|
57
|
-
cursor: not-allowed !important;
|
|
58
|
-
filter: opacity(0.35) !important;
|
|
59
|
-
}
|
|
60
|
-
.revo-button.outline {
|
|
61
|
-
border: 1px solid #dbdbdb;
|
|
62
|
-
line-height: 30px;
|
|
63
|
-
background: none;
|
|
64
|
-
color: #000;
|
|
65
|
-
box-shadow: none;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
revo-grid[theme^=dark] .revo-button.outline {
|
|
69
|
-
border: 1px solid #404040;
|
|
70
|
-
color: #d8d8d8;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
1
|
revogr-scroll-virtual[autohide] {
|
|
74
2
|
position: absolute;
|
|
75
3
|
z-index: 100 !important;
|
|
@@ -1,75 +1,3 @@
|
|
|
1
|
-
.revo-drag-icon {
|
|
2
|
-
width: 11px;
|
|
3
|
-
opacity: 0.8;
|
|
4
|
-
}
|
|
5
|
-
.revo-drag-icon::before {
|
|
6
|
-
content: "::";
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.revo-alt-icon {
|
|
10
|
-
-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");
|
|
11
|
-
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");
|
|
12
|
-
width: 11px;
|
|
13
|
-
height: 11px;
|
|
14
|
-
background-size: cover;
|
|
15
|
-
background-repeat: no-repeat;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.arrow-down {
|
|
19
|
-
position: absolute;
|
|
20
|
-
right: 5px;
|
|
21
|
-
top: 0;
|
|
22
|
-
}
|
|
23
|
-
.arrow-down svg {
|
|
24
|
-
width: 8px;
|
|
25
|
-
margin-top: 5px;
|
|
26
|
-
margin-left: 5px;
|
|
27
|
-
opacity: 0.4;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.cell-value-wrapper {
|
|
31
|
-
margin-right: 10px;
|
|
32
|
-
overflow: hidden;
|
|
33
|
-
text-overflow: ellipsis;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
.revo-button {
|
|
37
|
-
position: relative;
|
|
38
|
-
overflow: hidden;
|
|
39
|
-
color: #fff;
|
|
40
|
-
background-color: #4545ff;
|
|
41
|
-
height: 32px;
|
|
42
|
-
line-height: 32px;
|
|
43
|
-
padding: 0 15px;
|
|
44
|
-
outline: 0;
|
|
45
|
-
border: 0;
|
|
46
|
-
border-radius: 7px;
|
|
47
|
-
box-sizing: border-box;
|
|
48
|
-
cursor: pointer;
|
|
49
|
-
}
|
|
50
|
-
.revo-button.green {
|
|
51
|
-
background-color: #009037;
|
|
52
|
-
}
|
|
53
|
-
.revo-button.red {
|
|
54
|
-
background-color: #E0662E;
|
|
55
|
-
}
|
|
56
|
-
.revo-button:disabled, .revo-button[disabled] {
|
|
57
|
-
cursor: not-allowed !important;
|
|
58
|
-
filter: opacity(0.35) !important;
|
|
59
|
-
}
|
|
60
|
-
.revo-button.outline {
|
|
61
|
-
border: 1px solid #dbdbdb;
|
|
62
|
-
line-height: 30px;
|
|
63
|
-
background: none;
|
|
64
|
-
color: #000;
|
|
65
|
-
box-shadow: none;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
revo-grid[theme^=dark] .revo-button.outline {
|
|
69
|
-
border: 1px solid #404040;
|
|
70
|
-
color: #d8d8d8;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
1
|
revogr-focus.focused-cell {
|
|
74
2
|
box-shadow: -1px 0 0 #0d63e8 inset, 1px 0 0 #0d63e8 inset, 0 -1px 0 #0d63e8 inset, 0 1px 0 #0d63e8 inset;
|
|
75
3
|
position: absolute;
|
|
@@ -1,75 +1,3 @@
|
|
|
1
|
-
.revo-drag-icon {
|
|
2
|
-
width: 11px;
|
|
3
|
-
opacity: 0.8;
|
|
4
|
-
}
|
|
5
|
-
.revo-drag-icon::before {
|
|
6
|
-
content: "::";
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.revo-alt-icon {
|
|
10
|
-
-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");
|
|
11
|
-
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");
|
|
12
|
-
width: 11px;
|
|
13
|
-
height: 11px;
|
|
14
|
-
background-size: cover;
|
|
15
|
-
background-repeat: no-repeat;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.arrow-down {
|
|
19
|
-
position: absolute;
|
|
20
|
-
right: 5px;
|
|
21
|
-
top: 0;
|
|
22
|
-
}
|
|
23
|
-
.arrow-down svg {
|
|
24
|
-
width: 8px;
|
|
25
|
-
margin-top: 5px;
|
|
26
|
-
margin-left: 5px;
|
|
27
|
-
opacity: 0.4;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.cell-value-wrapper {
|
|
31
|
-
margin-right: 10px;
|
|
32
|
-
overflow: hidden;
|
|
33
|
-
text-overflow: ellipsis;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
.revo-button {
|
|
37
|
-
position: relative;
|
|
38
|
-
overflow: hidden;
|
|
39
|
-
color: #fff;
|
|
40
|
-
background-color: #4545ff;
|
|
41
|
-
height: 32px;
|
|
42
|
-
line-height: 32px;
|
|
43
|
-
padding: 0 15px;
|
|
44
|
-
outline: 0;
|
|
45
|
-
border: 0;
|
|
46
|
-
border-radius: 7px;
|
|
47
|
-
box-sizing: border-box;
|
|
48
|
-
cursor: pointer;
|
|
49
|
-
}
|
|
50
|
-
.revo-button.green {
|
|
51
|
-
background-color: #009037;
|
|
52
|
-
}
|
|
53
|
-
.revo-button.red {
|
|
54
|
-
background-color: #E0662E;
|
|
55
|
-
}
|
|
56
|
-
.revo-button:disabled, .revo-button[disabled] {
|
|
57
|
-
cursor: not-allowed !important;
|
|
58
|
-
filter: opacity(0.35) !important;
|
|
59
|
-
}
|
|
60
|
-
.revo-button.outline {
|
|
61
|
-
border: 1px solid #dbdbdb;
|
|
62
|
-
line-height: 30px;
|
|
63
|
-
background: none;
|
|
64
|
-
color: #000;
|
|
65
|
-
box-shadow: none;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
revo-grid[theme^=dark] .revo-button.outline {
|
|
69
|
-
border: 1px solid #404040;
|
|
70
|
-
color: #d8d8d8;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
1
|
.temp-bg-range {
|
|
74
2
|
display: block !important;
|
|
75
3
|
position: absolute;
|
|
@@ -1,75 +1,3 @@
|
|
|
1
|
-
.revo-drag-icon {
|
|
2
|
-
width: 11px;
|
|
3
|
-
opacity: 0.8;
|
|
4
|
-
}
|
|
5
|
-
.revo-drag-icon::before {
|
|
6
|
-
content: "::";
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.revo-alt-icon {
|
|
10
|
-
-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");
|
|
11
|
-
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");
|
|
12
|
-
width: 11px;
|
|
13
|
-
height: 11px;
|
|
14
|
-
background-size: cover;
|
|
15
|
-
background-repeat: no-repeat;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.arrow-down {
|
|
19
|
-
position: absolute;
|
|
20
|
-
right: 5px;
|
|
21
|
-
top: 0;
|
|
22
|
-
}
|
|
23
|
-
.arrow-down svg {
|
|
24
|
-
width: 8px;
|
|
25
|
-
margin-top: 5px;
|
|
26
|
-
margin-left: 5px;
|
|
27
|
-
opacity: 0.4;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.cell-value-wrapper {
|
|
31
|
-
margin-right: 10px;
|
|
32
|
-
overflow: hidden;
|
|
33
|
-
text-overflow: ellipsis;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
.revo-button {
|
|
37
|
-
position: relative;
|
|
38
|
-
overflow: hidden;
|
|
39
|
-
color: #fff;
|
|
40
|
-
background-color: #4545ff;
|
|
41
|
-
height: 32px;
|
|
42
|
-
line-height: 32px;
|
|
43
|
-
padding: 0 15px;
|
|
44
|
-
outline: 0;
|
|
45
|
-
border: 0;
|
|
46
|
-
border-radius: 7px;
|
|
47
|
-
box-sizing: border-box;
|
|
48
|
-
cursor: pointer;
|
|
49
|
-
}
|
|
50
|
-
.revo-button.green {
|
|
51
|
-
background-color: #009037;
|
|
52
|
-
}
|
|
53
|
-
.revo-button.red {
|
|
54
|
-
background-color: #E0662E;
|
|
55
|
-
}
|
|
56
|
-
.revo-button:disabled, .revo-button[disabled] {
|
|
57
|
-
cursor: not-allowed !important;
|
|
58
|
-
filter: opacity(0.35) !important;
|
|
59
|
-
}
|
|
60
|
-
.revo-button.outline {
|
|
61
|
-
border: 1px solid #dbdbdb;
|
|
62
|
-
line-height: 30px;
|
|
63
|
-
background: none;
|
|
64
|
-
color: #000;
|
|
65
|
-
box-shadow: none;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
revo-grid[theme^=dark] .revo-button.outline {
|
|
69
|
-
border: 1px solid #404040;
|
|
70
|
-
color: #d8d8d8;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
1
|
revogr-filter-panel {
|
|
74
2
|
position: absolute;
|
|
75
3
|
display: block;
|
|
@@ -43,8 +43,8 @@ export function sortIndexByItems(indexes, source, sortingFunc = {}) {
|
|
|
43
43
|
export function defaultCellCompare(prop, a, b) {
|
|
44
44
|
const aRaw = this.column ? getCellRaw(a, this.column) : a === null || a === void 0 ? void 0 : a[prop];
|
|
45
45
|
const bRaw = this.column ? getCellRaw(b, this.column) : b === null || b === void 0 ? void 0 : b[prop];
|
|
46
|
-
const av = aRaw === null || aRaw === void 0 ? void 0 : aRaw.toString().toLowerCase();
|
|
47
|
-
const bv = bRaw === null || bRaw === void 0 ? void 0 : bRaw.toString().toLowerCase();
|
|
46
|
+
const av = typeof aRaw === 'number' ? aRaw : aRaw === null || aRaw === void 0 ? void 0 : aRaw.toString().toLowerCase();
|
|
47
|
+
const bv = typeof bRaw === 'number' ? bRaw : bRaw === null || bRaw === void 0 ? void 0 : bRaw.toString().toLowerCase();
|
|
48
48
|
if (av === bv) {
|
|
49
49
|
return 0;
|
|
50
50
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sorting.func.js","sourceRoot":"","sources":["../../../src/plugins/sorting/sorting.func.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAC7D,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AAEtD,MAAM,UAAU,gBAAgB,CAC9B,OAAiB,EACjB,MAAkB,EAClB,cAAoC,EAAE;IAEtC,0CAA0C;IAC1C,IAAI,MAAM,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAC7C,mBAAmB;QACnB,OAAO,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC;IAC3C,CAAC;IACD,EAAE;IACF;;;OAGG;IACH,OAAO,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE;QAC3B,MAAM,KAAK,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;QACxB,MAAM,KAAK,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;QACxB,KAAK,MAAM,CAAC,IAAI,EAAE,GAAG,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,WAAW,CAAC,EAAE,CAAC;YACtD,IAAI,UAAU,CAAC,KAAK,CAAC,EAAE,CAAC;gBACtB,IAAI,KAAK,CAAC,aAAa,CAAC,KAAK,IAAI,EAAE,CAAC;oBAClC,OAAO,CAAC,CAAC;gBACX,CAAC;YACH,CAAC;YACD,IAAI,UAAU,CAAC,KAAK,CAAC,EAAE,CAAC;gBACtB,IAAI,KAAK,CAAC,aAAa,CAAC,KAAK,IAAI,EAAE,CAAC;oBAClC,OAAO,CAAC,CAAC;gBACX,CAAC;YACH,CAAC;YACD;;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BAAkB,uBAAlB,kBAAkB,CAAE,IAAI,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAAA,CAAC;IACtF,IAAI,KAAK,IAAI,KAAK,EAAE,CAAC;QACnB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,IAAI,KAAK,IAAI,MAAM,EAAE,CAAC;QACpB,OAAO,eAAe,CAAC,OAAO,CAAC,CAAC;IAClC,CAAC;IACD,OAAO,SAAS,CAAC;AACnB,CAAC","sourcesContent":["import type { CellCompareFunc, ColumnProp, ColumnRegular, DataType, Order } from '@type';\nimport type { SortingOrderFunction } from './sorting.types';\nimport { isGrouping } from '../groupingRow/grouping.service';\nimport { getCellRaw } from '../../utils/column.utils';\n\nexport function sortIndexByItems(\n indexes: number[],\n source: DataType[],\n sortingFunc: SortingOrderFunction = {},\n): number[] {\n // if no sorting - return unsorted indexes\n if (Object.entries(sortingFunc).length === 0) {\n // Unsorted indexes\n return [...Array(indexes.length).keys()];\n }\n //\n /**\n * go through all indexes and align in new order\n * performs a multi-level sorting by applying multiple comparison functions to determine the order of the items based on different properties.\n */\n return indexes.sort((a, b) => {\n const itemA = source[a];\n const itemB = source[b];\n for (const [prop, cmp] of Object.entries(sortingFunc)) {\n if (isGrouping(itemA)) {\n if (itemA['__rvgr-prop'] !== prop) {\n return 0;\n }\n }\n if (isGrouping(itemB)) {\n if (itemB['__rvgr-prop'] !== prop) {\n return 0;\n }\n }\n /**\n * If the comparison function returns a non-zero value (sorted), it means that the items should be sorted based on the given property. In such a case, the function immediately returns the sorted value, indicating the order in which the items should be arranged.\n * If none of the comparison functions result in a non-zero value, indicating that the items are equal or should remain in the same order, the function eventually returns 0.\n */\n const sorted = cmp?.(prop, itemA, itemB);\n if (sorted) {\n return sorted;\n }\n }\n return 0;\n });\n}\n\nexport function defaultCellCompare(this: { column?: ColumnRegular }, prop: ColumnProp, a: DataType, b: DataType) {\n const aRaw = this.column ? getCellRaw(a, this.column) : a?.[prop];\n const bRaw = this.column ? getCellRaw(b, this.column) : b?.[prop];\n const av = typeof aRaw === 'number' ? aRaw : aRaw?.toString().toLowerCase();\n const bv = typeof bRaw === 'number' ? bRaw : bRaw?.toString().toLowerCase();\n\n if (av === bv) {\n return 0;\n }\n if (av > bv) {\n return 1;\n }\n return -1;\n}\n\nexport function descCellCompare(cmp: CellCompareFunc) {\n return (prop: ColumnProp, a: DataType, b: DataType): number => {\n return -1 * cmp(prop, a, b);\n };\n}\n\nexport function getNextOrder(currentOrder: Order): Order {\n switch (currentOrder) {\n case undefined:\n return 'asc';\n case 'asc':\n return 'desc';\n case 'desc':\n return undefined;\n }\n}\n\n\nexport function getComparer(column: Partial<ColumnRegular> | undefined, order: Order): CellCompareFunc | undefined {\n const cellCmp: CellCompareFunc =\n column?.cellCompare?.bind({ order }) || defaultCellCompare?.bind({ column, order });\n if (order == 'asc') {\n return cellCmp;\n }\n if (order == 'desc') {\n return descCellCompare(cellCmp);\n }\n return undefined;\n}\n"]}
|
|
@@ -138,9 +138,6 @@ export class SortingPlugin extends BasePlugin {
|
|
|
138
138
|
if (beforeApplyEvent.detail.additive && this.sorting) {
|
|
139
139
|
const sorting = {};
|
|
140
140
|
const sortingFunc = {};
|
|
141
|
-
this.sorting = Object.assign(Object.assign({}, this.sorting), sorting);
|
|
142
|
-
// extend sorting function with new sorting for multiple columns sorting
|
|
143
|
-
this.sortingFunc = Object.assign(Object.assign({}, this.sortingFunc), sortingFunc);
|
|
144
141
|
if (columnProp in sorting && size(sorting) > 1 && order === undefined) {
|
|
145
142
|
delete sorting[columnProp];
|
|
146
143
|
delete sortingFunc[columnProp];
|
|
@@ -149,6 +146,9 @@ export class SortingPlugin extends BasePlugin {
|
|
|
149
146
|
sorting[columnProp] = order;
|
|
150
147
|
sortingFunc[columnProp] = cmp;
|
|
151
148
|
}
|
|
149
|
+
this.sorting = Object.assign(Object.assign({}, this.sorting), sorting);
|
|
150
|
+
// extend sorting function with new sorting for multiple columns sorting
|
|
151
|
+
this.sortingFunc = Object.assign(Object.assign({}, this.sortingFunc), sortingFunc);
|
|
152
152
|
}
|
|
153
153
|
else {
|
|
154
154
|
if (order) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sorting.plugin.js","sourceRoot":"","sources":["../../../src/plugins/sorting/sorting.plugin.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,aAAa,CAAC;AAC/B,OAAO,QAAQ,MAAM,iBAAiB,CAAC;AAEvC,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAQ5C,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAC3D,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,QAAQ,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAE7E,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAE/B;;;;;;;;GAQG;AAEH,MAAM,OAAO,aAAc,SAAQ,UAAU;IAoB3C,YACS,QAA6B,EACpC,SAA0B,EAC1B,MAAsB;QAEtB,KAAK,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAC;QAJpB,aAAQ,GAAR,QAAQ,CAAqB;QAftC;;WAEG;QACH,mBAAc,GAAwB,IAAI,CAAC;QAE3C;;WAEG;QACH,iBAAY,GAAG,QAAQ,CACrB,CAAC,KAAoB,EAAE,UAAiC,EAAE,oBAA8B,EAAE,EAAE,CAC1F,IAAI,CAAC,UAAU,CAAC,KAAK,EAAE,UAAU,EAAE,oBAAoB,CAAC,EAC1D,EAAE,CACH,CAAC;QASA,MAAM,SAAS,GAAG,CAAC,GAAmB,EAAE,EAAE;;YACxC,IAAI,GAAG,EAAE,CAAC;gBACR,MAAM,WAAW,GAAyB,EAAE,CAAC;gBAC7C,MAAM,KAAK,GAAiB,EAAE,CAAC;gBAC/B,MAAA,GAAG,CAAC,OAAO,0CAAE,OA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E,CAAC;QACpD,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,IAAI,CAAC,mBAAmB,CAAC,CAAC;IACjC,CAAC;CACF","sourcesContent":["import size from 'lodash/size';\nimport debounce from 'lodash/debounce';\n\nimport { BasePlugin } from '../base.plugin';\nimport type {\n Order,\n ColumnRegular,\n DimensionRows,\n PluginProviders,\n} from '@type';\nimport type { SortingConfig, SortingOrder, SortingOrderFunction } from './sorting.types';\nimport { getColumnByProp } from '../../utils/column.utils';\nimport { columnTypes, rowTypes } from '@store';\nimport { getComparer, getNextOrder, sortIndexByItems } from './sorting.func';\n\nexport * from './sorting.types';\nexport * from './sorting.func';\nexport * from './sorting.sign';\n\n/**\n * Lifecycle\n * 1. @event `beforesorting` - Triggered when sorting just starts. Nothing has happened yet. This can be triggered from a column or from the source. If the type is from rows, the column will be undefined.\n * 2. @event `beforesourcesortingapply` - Triggered before the sorting data is applied to the data source. You can prevent this event, and the data will not be sorted.\n * 3. @event `beforesortingapply` - Triggered before the sorting data is applied to the data source. You can prevent this event, and the data will not be sorted. This event is only called from a column sorting click.\n * 4. @event `aftersortingapply` - Triggered after sorting has been applied and completed. This event occurs for both row and column sorting.\n *\n * Note: If you prevent an event, it will not proceed to the subsequent steps.\n */\n\nexport class SortingPlugin extends BasePlugin {\n // Current sorting order per column prop\n sorting?: SortingOrder;\n\n // Each column sorting function, multiple columns sorting supported\n sortingFunc?: SortingOrderFunction;\n /**\n * Delayed sorting promise\n */\n sortingPromise: (() => void) | null = null;\n\n /**\n * We need to sort only so often\n */\n postponeSort = debounce(\n (order?: SortingOrder, comparison?: SortingOrderFunction, ignoreViewportUpdate?: boolean) =>\n this.runSorting(order, comparison, ignoreViewportUpdate),\n 50,\n );\n\n constructor(\n public revogrid: HTMLRevoGridElement,\n providers: PluginProviders,\n config?: SortingConfig,\n ) {\n super(revogrid, providers);\n\n const setConfig = (cfg?: SortingConfig) => {\n if (cfg) {\n const sortingFunc: SortingOrderFunction = {};\n const order: SortingOrder = {};\n cfg.columns?.forEach(col => {\n sortingFunc[col.prop] = getComparer(col, col.order);\n order[col.prop] = col.order;\n });\n\n if (cfg.additive) {\n this.sorting = {\n ...this.sorting,\n ...order,\n };\n this.sortingFunc = {\n ...this.sortingFunc,\n ...sortingFunc,\n };\n } else {\n // // set sorting\n this.sorting = order;\n this.sortingFunc = sortingFunc;\n }\n }\n }\n\n setConfig(config);\n\n this.addEventListener('sortingconfigchanged', ({ detail }) => {\n config = detail;\n setConfig(detail);\n this.startSorting(this.sorting, this.sortingFunc);\n });\n\n this.addEventListener('beforeheaderrender', ({\n detail,\n }) => {\n const { data: column } = detail;\n if (column.sortable) {\n detail.data = {\n ...column,\n order: this.sorting?.[column.prop],\n };\n }\n });\n\n this.addEventListener('beforeanysource', ({\n detail: { type },\n }) => {\n // if sorting was provided - sort data\n if (!!this.sorting && this.sortingFunc) {\n const event = this.emit('beforesourcesortingapply', { type, sorting: this.sorting });\n if (event.defaultPrevented) {\n return;\n }\n this.startSorting(this.sorting, this.sortingFunc);\n }\n });\n this.addEventListener('aftercolumnsset', ({\n detail: { order },\n }) => {\n // if config provided - do nothing, read from config\n if (config) {\n return;\n }\n\n const columns = this.providers.column.getColumns();\n const sortingFunc: SortingOrderFunction = {};\n\n for (let prop in order) {\n const cmp = getComparer(\n getColumnByProp(columns, prop),\n order[prop],\n );\n sortingFunc[prop] = cmp;\n }\n\n // set sorting\n this.sorting = order;\n this.sortingFunc = order && sortingFunc;\n });\n this.addEventListener('beforeheaderclick', (e) => {\n if (e.defaultPrevented) {\n return;\n }\n\n if (!e.detail?.column?.sortable) {\n return;\n }\n\n this.headerclick(\n e.detail.column,\n e.detail?.originalEvent?.shiftKey,\n );\n });\n }\n\n /**\n * Entry point for sorting, waits for all delayes, registers jobs\n */\n startSorting(order?: SortingOrder, sortingFunc?: SortingOrderFunction, ignoreViewportUpdate?: boolean) {\n if (!this.sortingPromise) {\n // add job before render\n this.revogrid.jobsBeforeRender.push(\n new Promise<void>(resolve => {\n this.sortingPromise = resolve;\n }),\n );\n }\n this.postponeSort(order, sortingFunc, ignoreViewportUpdate);\n }\n\n\n /**\n * Apply sorting to data on header click\n * If additive - add to existing sorting, multiple columns can be sorted\n */\n headerclick(column: ColumnRegular, additive: boolean) {\n const columnProp = column.prop;\n let order: Order = getNextOrder(this.sorting?.[columnProp]);\n const beforeEvent = this.emit('beforesorting', { column, order, additive });\n if (beforeEvent.defaultPrevented) {\n return;\n }\n order = beforeEvent.detail.order;\n\n // apply sort data\n const beforeApplyEvent = this.emit('beforesortingapply', {\n column: beforeEvent.detail.column,\n order,\n additive,\n });\n if (beforeApplyEvent.defaultPrevented) {\n return;\n }\n const cmp = getComparer(beforeApplyEvent.detail.column, beforeApplyEvent.detail.order);\n\n if (beforeApplyEvent.detail.additive && this.sorting) {\n const sorting: SortingOrder = {};\n const sortingFunc: SortingOrderFunction = {};\n\n this.sorting = {\n ...this.sorting,\n ...sorting,\n };\n // extend sorting function with new sorting for multiple columns sorting\n this.sortingFunc = {\n ...this.sortingFunc,\n ...sortingFunc,\n };\n\n if (columnProp in sorting && size(sorting) > 1 && order === undefined) {\n delete sorting[columnProp];\n delete sortingFunc[columnProp];\n } else {\n sorting[columnProp] = order;\n sortingFunc[columnProp] = cmp;\n }\n } else {\n if (order) {\n // reset sorting\n this.sorting = { [columnProp]: order };\n this.sortingFunc = { [columnProp]: cmp };\n } else {\n delete this.sorting?.[columnProp];\n delete this.sortingFunc?.[columnProp];\n }\n }\n\n this.startSorting(this.sorting, this.sortingFunc);\n }\n\n runSorting(\n order?: SortingOrder,\n comparison?: SortingOrderFunction,\n ignoreViewportUpdate?: boolean\n ) {\n this.sort(order, comparison, undefined, ignoreViewportUpdate);\n this.sortingPromise?.();\n this.sortingPromise = null;\n }\n\n /**\n * Sort items by sorting function\n * @requires proxyItems applied to row store\n * @requires source applied to row store\n *\n * @param sorting - per column sorting\n * @param data - this.stores['rgRow'].store.get('source')\n */\n sort(\n sorting?: SortingOrder,\n sortingFunc?: SortingOrderFunction,\n types: DimensionRows[] = rowTypes,\n ignoreViewportUpdate = false\n ) {\n // if no sorting - reset\n if (!Object.keys(sorting || {}).length) {\n for (let type of types) {\n const storeService = this.providers.data.stores[type];\n // row data\n const source = storeService.store.get('source');\n // row indexes\n const proxyItems = storeService.store.get('proxyItems');\n // row indexes\n const newItemsOrder = Array.from({ length: source.length }, (_, i) => i); // recover indexes range(0, source.length)\n this.providers.dimension.updateSizesPositionByNewDataIndexes(type, newItemsOrder, proxyItems);\n storeService.setData({ proxyItems: newItemsOrder, source: [...source], });\n }\n } else {\n for (let type of types) {\n const storeService = this.providers.data.stores[type];\n // row data\n const source = storeService.store.get('source');\n // row indexes\n const proxyItems = storeService.store.get('proxyItems');\n\n const newItemsOrder = sortIndexByItems(\n [...proxyItems],\n source,\n sortingFunc,\n );\n \n // take row indexes before trim applied and proxy items\n const prevItems = storeService.store.get('items');\n storeService.setData({\n proxyItems: newItemsOrder,\n source: [...source],\n });\n // take currently visible row indexes\n const newItems = storeService.store.get('items');\n if (!ignoreViewportUpdate) {\n this.providers.dimension\n .updateSizesPositionByNewDataIndexes(type, newItems, prevItems);\n }\n }\n }\n // refresh columns to redraw column headers and show correct icon\n columnTypes.forEach((type) => {\n this.providers.column.dataSources[type].refresh();\n });\n this.emit('aftersortingapply');\n }\n}\n\n\n"]}
|
|
1
|
+
{"version":3,"file":"sorting.plugin.js","sourceRoot":"","sources":["../../../src/plugins/sorting/sorting.plugin.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,aAAa,CAAC;AAC/B,OAAO,QAAQ,MAAM,iBAAiB,CAAC;AAEvC,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAQ5C,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAC3D,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,QAAQ,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAA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AAa,GAAG,gBAAgB,CACpC,CAAC,GAAG,UAAU,CAAC,EACf,MAAM,EACN,WAAW,CACZ,CAAC;gBAEF,uDAAuD;gBACvD,MAAM,SAAS,GAAG,YAAY,CAAC,KAAK,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;gBAClD,YAAY,CAAC,OAAO,CAAC;oBACnB,UAAU,EAAE,aAAa;oBACzB,MAAM,EAAE,CAAC,GAAG,MAAM,CAAC;iBACpB,CAAC,CAAC;gBACH,qCAAqC;gBACrC,MAAM,QAAQ,GAAG,YAAY,CAAC,KAAK,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;gBACjD,IAAI,CAAC,oBAAoB,EAAE,CAAC;oBAC1B,IAAI,CAAC,SAAS,CAAC,SAAS;yBACrB,mCAAmC,CAAC,IAAI,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC;gBACpE,CAAC;YACH,CAAC;QACH,CAAC;QACD,iEAAiE;QACjE,WAAW,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,EAAE;YAC3B,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;QACpD,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,IAAI,CAAC,mBAAmB,CAAC,CAAC;IACjC,CAAC;CACF","sourcesContent":["import size from 'lodash/size';\nimport debounce from 'lodash/debounce';\n\nimport { BasePlugin } from '../base.plugin';\nimport type {\n Order,\n ColumnRegular,\n DimensionRows,\n PluginProviders,\n} from '@type';\nimport type { SortingConfig, SortingOrder, SortingOrderFunction } from './sorting.types';\nimport { getColumnByProp } from '../../utils/column.utils';\nimport { columnTypes, rowTypes } from '@store';\nimport { getComparer, getNextOrder, sortIndexByItems } from './sorting.func';\n\nexport * from './sorting.types';\nexport * from './sorting.func';\nexport * from './sorting.sign';\n\n/**\n * Lifecycle\n * 1. @event `beforesorting` - Triggered when sorting just starts. Nothing has happened yet. This can be triggered from a column or from the source. If the type is from rows, the column will be undefined.\n * 2. @event `beforesourcesortingapply` - Triggered before the sorting data is applied to the data source. You can prevent this event, and the data will not be sorted.\n * 3. @event `beforesortingapply` - Triggered before the sorting data is applied to the data source. You can prevent this event, and the data will not be sorted. This event is only called from a column sorting click.\n * 4. @event `aftersortingapply` - Triggered after sorting has been applied and completed. This event occurs for both row and column sorting.\n *\n * Note: If you prevent an event, it will not proceed to the subsequent steps.\n */\n\nexport class SortingPlugin extends BasePlugin {\n // Current sorting order per column prop\n sorting?: SortingOrder;\n\n // Each column sorting function, multiple columns sorting supported\n sortingFunc?: SortingOrderFunction;\n /**\n * Delayed sorting promise\n */\n sortingPromise: (() => void) | null = null;\n\n /**\n * We need to sort only so often\n */\n postponeSort = debounce(\n (order?: SortingOrder, comparison?: SortingOrderFunction, ignoreViewportUpdate?: boolean) =>\n this.runSorting(order, comparison, ignoreViewportUpdate),\n 50,\n );\n\n constructor(\n public revogrid: HTMLRevoGridElement,\n providers: PluginProviders,\n config?: SortingConfig,\n ) {\n super(revogrid, providers);\n\n const setConfig = (cfg?: SortingConfig) => {\n if (cfg) {\n const sortingFunc: SortingOrderFunction = {};\n const order: SortingOrder = {};\n cfg.columns?.forEach(col => {\n sortingFunc[col.prop] = getComparer(col, col.order);\n order[col.prop] = col.order;\n });\n\n if (cfg.additive) {\n this.sorting = {\n ...this.sorting,\n ...order,\n };\n this.sortingFunc = {\n ...this.sortingFunc,\n ...sortingFunc,\n };\n } else {\n // // set sorting\n this.sorting = order;\n this.sortingFunc = sortingFunc;\n }\n }\n }\n\n setConfig(config);\n\n this.addEventListener('sortingconfigchanged', ({ detail }) => {\n config = detail;\n setConfig(detail);\n this.startSorting(this.sorting, this.sortingFunc);\n });\n\n this.addEventListener('beforeheaderrender', ({\n detail,\n }) => {\n const { data: column } = detail;\n if (column.sortable) {\n detail.data = {\n ...column,\n order: this.sorting?.[column.prop],\n };\n }\n });\n\n this.addEventListener('beforeanysource', ({\n detail: { type },\n }) => {\n // if sorting was provided - sort data\n if (!!this.sorting && this.sortingFunc) {\n const event = this.emit('beforesourcesortingapply', { type, sorting: this.sorting });\n if (event.defaultPrevented) {\n return;\n }\n this.startSorting(this.sorting, this.sortingFunc);\n }\n });\n this.addEventListener('aftercolumnsset', ({\n detail: { order },\n }) => {\n // if config provided - do nothing, read from config\n if (config) {\n return;\n }\n\n const columns = this.providers.column.getColumns();\n const sortingFunc: SortingOrderFunction = {};\n\n for (let prop in order) {\n const cmp = getComparer(\n getColumnByProp(columns, prop),\n order[prop],\n );\n sortingFunc[prop] = cmp;\n }\n\n // set sorting\n this.sorting = order;\n this.sortingFunc = order && sortingFunc;\n });\n this.addEventListener('beforeheaderclick', (e) => {\n if (e.defaultPrevented) {\n return;\n }\n\n if (!e.detail?.column?.sortable) {\n return;\n }\n\n this.headerclick(\n e.detail.column,\n e.detail?.originalEvent?.shiftKey,\n );\n });\n }\n\n /**\n * Entry point for sorting, waits for all delayes, registers jobs\n */\n startSorting(order?: SortingOrder, sortingFunc?: SortingOrderFunction, ignoreViewportUpdate?: boolean) {\n if (!this.sortingPromise) {\n // add job before render\n this.revogrid.jobsBeforeRender.push(\n new Promise<void>(resolve => {\n this.sortingPromise = resolve;\n }),\n );\n }\n this.postponeSort(order, sortingFunc, ignoreViewportUpdate);\n }\n\n\n /**\n * Apply sorting to data on header click\n * If additive - add to existing sorting, multiple columns can be sorted\n */\n headerclick(column: ColumnRegular, additive: boolean) {\n const columnProp = column.prop;\n let order: Order = getNextOrder(this.sorting?.[columnProp]);\n const beforeEvent = this.emit('beforesorting', { column, order, additive });\n if (beforeEvent.defaultPrevented) {\n return;\n }\n order = beforeEvent.detail.order;\n\n // apply sort data\n const beforeApplyEvent = this.emit('beforesortingapply', {\n column: beforeEvent.detail.column,\n order,\n additive,\n });\n if (beforeApplyEvent.defaultPrevented) {\n return;\n }\n const cmp = getComparer(beforeApplyEvent.detail.column, beforeApplyEvent.detail.order);\n\n if (beforeApplyEvent.detail.additive && this.sorting) {\n const sorting: SortingOrder = {};\n const sortingFunc: SortingOrderFunction = {};\n\n if (columnProp in sorting && size(sorting) > 1 && order === undefined) {\n delete sorting[columnProp];\n delete sortingFunc[columnProp];\n } else {\n sorting[columnProp] = order;\n sortingFunc[columnProp] = cmp;\n } \n\n this.sorting = {\n ...this.sorting,\n ...sorting,\n };\n \n // extend sorting function with new sorting for multiple columns sorting\n this.sortingFunc = {\n ...this.sortingFunc,\n ...sortingFunc,\n };\n } else {\n if (order) {\n // reset sorting\n this.sorting = { [columnProp]: order };\n this.sortingFunc = { [columnProp]: cmp };\n } else {\n delete this.sorting?.[columnProp];\n delete this.sortingFunc?.[columnProp];\n }\n }\n\n this.startSorting(this.sorting, this.sortingFunc);\n }\n\n runSorting(\n order?: SortingOrder,\n comparison?: SortingOrderFunction,\n ignoreViewportUpdate?: boolean\n ) {\n this.sort(order, comparison, undefined, ignoreViewportUpdate);\n this.sortingPromise?.();\n this.sortingPromise = null;\n }\n\n /**\n * Sort items by sorting function\n * @requires proxyItems applied to row store\n * @requires source applied to row store\n *\n * @param sorting - per column sorting\n * @param data - this.stores['rgRow'].store.get('source')\n */\n sort(\n sorting?: SortingOrder,\n sortingFunc?: SortingOrderFunction,\n types: DimensionRows[] = rowTypes,\n ignoreViewportUpdate = false\n ) {\n // if no sorting - reset\n if (!Object.keys(sorting || {}).length) {\n for (let type of types) {\n const storeService = this.providers.data.stores[type];\n // row data\n const source = storeService.store.get('source');\n // row indexes\n const proxyItems = storeService.store.get('proxyItems');\n // row indexes\n const newItemsOrder = Array.from({ length: source.length }, (_, i) => i); // recover indexes range(0, source.length)\n this.providers.dimension.updateSizesPositionByNewDataIndexes(type, newItemsOrder, proxyItems);\n storeService.setData({ proxyItems: newItemsOrder, source: [...source], });\n }\n } else {\n for (let type of types) {\n const storeService = this.providers.data.stores[type];\n // row data\n const source = storeService.store.get('source');\n // row indexes\n const proxyItems = storeService.store.get('proxyItems');\n\n const newItemsOrder = sortIndexByItems(\n [...proxyItems],\n source,\n sortingFunc,\n );\n \n // take row indexes before trim applied and proxy items\n const prevItems = storeService.store.get('items');\n storeService.setData({\n proxyItems: newItemsOrder,\n source: [...source],\n });\n // take currently visible row indexes\n const newItems = storeService.store.get('items');\n if (!ignoreViewportUpdate) {\n this.providers.dimension\n .updateSizesPositionByNewDataIndexes(type, newItems, prevItems);\n }\n }\n }\n // refresh columns to redraw column headers and show correct icon\n columnTypes.forEach((type) => {\n this.providers.column.dataSources[type].refresh();\n });\n this.emit('aftersortingapply');\n }\n}\n\n\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built by Revolist OU ❤️
|
|
3
3
|
*/
|
|
4
|
-
import './index-
|
|
4
|
+
import './index-Dyptvvxf.js';
|
|
5
5
|
|
|
6
6
|
function appGlobalScript () {
|
|
7
7
|
}
|
|
@@ -9,6 +9,6 @@ function appGlobalScript () {
|
|
|
9
9
|
const globalScripts = appGlobalScript;
|
|
10
10
|
|
|
11
11
|
export { globalScripts as g };
|
|
12
|
-
//# sourceMappingURL=app-globals-
|
|
12
|
+
//# sourceMappingURL=app-globals-C3ZHKjnB.js.map
|
|
13
13
|
|
|
14
|
-
//# sourceMappingURL=app-globals-
|
|
14
|
+
//# sourceMappingURL=app-globals-C3ZHKjnB.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app-globals-
|
|
1
|
+
{"version":3,"file":"app-globals-C3ZHKjnB.js","sources":["src/global/global.ts","@stencil/core/internal/app-globals"],"sourcesContent":["import { setMode } from '@stencil/core';\nimport { getTheme } from '../themeManager/theme.service';\n\nexport default function() {\n setMode(elm => {\n let theme = (elm as HTMLRevoGridElement).theme || elm.getAttribute('theme');\n if (typeof theme === 'string') {\n theme = theme.trim();\n }\n\n const parsedTheme = getTheme(theme);\n if (parsedTheme !== theme) {\n elm.setAttribute('theme', parsedTheme);\n }\n return parsedTheme;\n });\n}\n","import appGlobalScript from '/home/runner/work/revogrid/revogrid/src/global/global.ts';\nexport const globalScripts = appGlobalScript;\nexport const globalStyles = \"\";\n"],"names":[],"mappings":";;;;;AAGc,wBAAA,IAAA;AAad;;ACfY,MAAC,aAAa,GAAG;;;;"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built by Revolist OU ❤️
|
|
3
3
|
*/
|
|
4
|
-
import { h, B as Build } from './index-
|
|
5
|
-
import { y as DATA_ROW, G as DRAG_ICON_CLASS, I as DRAGGABLE_CLASS } from './dimension.helpers-
|
|
6
|
-
import { m as GROUP_EXPAND_BTN, o as GROUP_EXPAND_EVENT, G as GROUP_DEPTH, j as GROUP_EXPANDED, P as PSEUDO_GROUP_ITEM, T as isRowDragService, C as getCellDataParsed } from './column.service-
|
|
4
|
+
import { h, B as Build } from './index-Dyptvvxf.js';
|
|
5
|
+
import { y as DATA_ROW, G as DRAG_ICON_CLASS, I as DRAGGABLE_CLASS } from './dimension.helpers-D5lwLPzd.js';
|
|
6
|
+
import { m as GROUP_EXPAND_BTN, o as GROUP_EXPAND_EVENT, G as GROUP_DEPTH, j as GROUP_EXPANDED, P as PSEUDO_GROUP_ITEM, T as isRowDragService, C as getCellDataParsed } from './column.service-DyqJ8oYq.js';
|
|
7
7
|
|
|
8
8
|
const SortingSign = ({ column }) => {
|
|
9
9
|
var _a;
|
|
@@ -93,6 +93,6 @@ const CellRenderer = ({ renderProps, cellProps, }) => {
|
|
|
93
93
|
};
|
|
94
94
|
|
|
95
95
|
export { CellRenderer as C, GroupingRowRenderer as G, PADDING_DEPTH as P, RowRenderer as R, SortingSign as S, expandSvgIconVNode as a, expandEvent as e };
|
|
96
|
-
//# sourceMappingURL=cell-renderer-
|
|
96
|
+
//# sourceMappingURL=cell-renderer-AeQIe3qD.js.map
|
|
97
97
|
|
|
98
|
-
//# sourceMappingURL=cell-renderer-
|
|
98
|
+
//# sourceMappingURL=cell-renderer-AeQIe3qD.js.map
|