streamlit-nightly 1.53.2.dev20260125__py3-none-any.whl → 1.53.2.dev20260128__py3-none-any.whl
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.
- streamlit/commands/logo.py +81 -25
- streamlit/config.py +11 -0
- streamlit/deprecation_util.py +19 -1
- streamlit/elements/arrow.py +2 -1
- streamlit/elements/lib/built_in_chart_utils.py +2 -2
- streamlit/elements/lib/options_selector_utils.py +72 -22
- streamlit/elements/widgets/select_slider.py +123 -37
- streamlit/hello/plotting_demo.py +19 -12
- streamlit/proto/Logo_pb2.py +5 -3
- streamlit/proto/Logo_pb2.pyi +25 -1
- streamlit/proto/NewSession_pb2.py +24 -22
- streamlit/proto/NewSession_pb2.pyi +23 -1
- streamlit/proto/Slider_pb2.py +6 -6
- streamlit/proto/Slider_pb2.pyi +9 -1
- streamlit/runtime/app_session.py +19 -0
- streamlit/runtime/scriptrunner/script_runner.py +17 -0
- streamlit/runtime/scriptrunner_utils/script_run_context.py +13 -10
- streamlit/runtime/state/__init__.py +7 -1
- streamlit/runtime/state/common.py +13 -0
- streamlit/runtime/state/query_params.py +494 -6
- streamlit/runtime/state/session_state.py +178 -3
- streamlit/runtime/state/widgets.py +26 -1
- streamlit/static/index.html +1 -1
- streamlit/static/manifest.json +299 -299
- streamlit/static/static/js/{ErrorOutline.esm.CIFYUdwC.js → ErrorOutline.esm.D71F8ziR.js} +1 -1
- streamlit/static/static/js/{FileDownload.esm.DWVTnTHm.js → FileDownload.esm.yTkppsJy.js} +1 -1
- streamlit/static/static/js/{FileHelper.BPYQIPd1.js → FileHelper.hUOqtbwa.js} +1 -1
- streamlit/static/static/js/{FormClearHelper.CypmvhYZ.js → FormClearHelper.DN8D_YXO.js} +1 -1
- streamlit/static/static/js/{InputInstructions.Bi62hDTQ.js → InputInstructions.DbssY6d4.js} +1 -1
- streamlit/static/static/js/{Particles.yebG0VuV.js → Particles.BznyVdfo.js} +1 -1
- streamlit/static/static/js/{ProgressBar.Dy9CI6w4.js → ProgressBar.C5uBOtcx.js} +1 -1
- streamlit/static/static/js/{StreamlitSyntaxHighlighter.Btk92CPv.js → StreamlitSyntaxHighlighter.Nf1895x-.js} +1 -1
- streamlit/static/static/js/{TableChart.esm.DBeVaFNt.js → TableChart.esm.DHKzVs3a.js} +1 -1
- streamlit/static/static/js/{Toolbar.DC2Tp-qb.js → Toolbar.CQsWYXer.js} +1 -1
- streamlit/static/static/js/{WidgetLabelHelpIconInline.3DnEd9BK.js → WidgetLabelHelpIconInline.6xCU76OE.js} +1 -1
- streamlit/static/static/js/{base-input.7Sj6pVk0.js → base-input.Cs-E6S71.js} +1 -1
- streamlit/static/static/js/{checkbox.CcUx3XuQ.js → checkbox.OTGupu18.js} +1 -1
- streamlit/static/static/js/{createDownloadLinkElement.DZuwkCqy.js → createDownloadLinkElement.DnBEQQbK.js} +1 -1
- streamlit/static/static/js/{data-grid-overlay-editor.Dw-AewlN.js → data-grid-overlay-editor.COiiMi5r.js} +1 -1
- streamlit/static/static/js/{downloader.Bsx5M2Du.js → downloader.K0GUNeuj.js} +1 -1
- streamlit/static/static/js/embed.o8HvK3mH.js +193 -0
- streamlit/static/static/js/{es6.BpAqZaR_.js → es6.BHy5pqTP.js} +2 -2
- streamlit/static/static/js/{formatNumber.DjehVPVS.js → formatNumber.BK7h0k2z.js} +1 -1
- streamlit/static/static/js/{iconPosition.D02OPE-d.js → iconPosition.2YynQUxu.js} +1 -1
- streamlit/static/static/js/{iframeResizer.contentWindow.xtstqPd7.js → iframeResizer.contentWindow.D5h3hQuU.js} +1 -1
- streamlit/static/static/js/{index.5H98WqjT.js → index.5zqfJ-in.js} +1 -1
- streamlit/static/static/js/{index.B5tD5YeV.js → index.6c-qDsD7.js} +1 -1
- streamlit/static/static/js/{index.CA0RmxJF.js → index.8MlRyIxN.js} +1 -1
- streamlit/static/static/js/{index.DSSapl3Q.js → index.BIqcOZ_u.js} +1 -1
- streamlit/static/static/js/{index.DJjSqPAx.js → index.BPdmXoYW.js} +1 -1
- streamlit/static/static/js/{index.iXzAofuY.js → index.BZ-GJVxB.js} +2 -2
- streamlit/static/static/js/{index.CKUBdVQ9.js → index.BfMPq234.js} +1 -1
- streamlit/static/static/js/{index.B8-HOwf1.js → index.Bfo1cXfC.js} +1 -1
- streamlit/static/static/js/{index.-faJDV20.js → index.Bgf49D1Z.js} +1 -1
- streamlit/static/static/js/{index.CgARjn28.js → index.Bqmx23jK.js} +1 -1
- streamlit/static/static/js/{index.D6Z9hKJY.js → index.BtRWcqZV.js} +1 -1
- streamlit/static/static/js/{index.ZIA43eTF.js → index.BtuskCwg.js} +1 -1
- streamlit/static/static/js/{index.BV6XgCij.js → index.BzTVI_BY.js} +1 -1
- streamlit/static/static/js/{index.DDu_qTm0.js → index.C2EoeVjP.js} +1 -1
- streamlit/static/static/js/{index.8FPw0_gD.js → index.C65jHNhe.js} +1 -1
- streamlit/static/static/js/{index.D6J2UPzF.js → index.C6wyTXhz.js} +1 -1
- streamlit/static/static/js/{index.CGbvkEtg.js → index.C7wst9Tm.js} +1 -1
- streamlit/static/static/js/{index.BIcJe97b.js → index.COh5V_89.js} +1 -1
- streamlit/static/static/js/index.CSPY26T2.js +1 -0
- streamlit/static/static/js/{index.CEwnDCn9.js → index.CUkhn-vu.js} +1 -1
- streamlit/static/static/js/{index.DO2T-QzF.js → index.CX0KdFyR.js} +1 -1
- streamlit/static/static/js/{index.BDlI2pRp.js → index.CYhhEdja.js} +1 -1
- streamlit/static/static/js/{index.DgLRJfs3.js → index.CZf7Go1Z.js} +1 -1
- streamlit/static/static/js/{index.DZv5AoR1.js → index.Cb03y5I8.js} +1 -1
- streamlit/static/static/js/{index.BVhVdVeE.js → index.CdsyTabv.js} +1 -1
- streamlit/static/static/js/{index.JL0uGAeJ.js → index.CgVv04GM.js} +1 -1
- streamlit/static/static/js/index.CjRU8O1O.js +2 -0
- streamlit/static/static/js/{index.BqfJJr3c.js → index.CwtpGPHA.js} +1 -1
- streamlit/static/static/js/{index.iF5zYERg.js → index.CxWzt6oi.js} +1 -1
- streamlit/static/static/js/{index.m3dn5Bai.js → index.DBPWUJsj.js} +5 -5
- streamlit/static/static/js/{index.D9RL5sRp.js → index.DJfMW0Gy.js} +1 -1
- streamlit/static/static/js/{index.BOkpEbJS.js → index.DLUSo6de.js} +1 -1
- streamlit/static/static/js/{index.S-mjkUeF.js → index.DL_yE83J.js} +1 -1
- streamlit/static/static/js/{index.BK9S5qug.js → index.DVRCyxMp.js} +1 -1
- streamlit/static/static/js/{index.D_TIyPF4.js → index.Dc5-tFdw.js} +1 -1
- streamlit/static/static/js/index.DcngUOyD.js +2 -0
- streamlit/static/static/js/{index.B9gbSNsw.js → index.Dh3PJIlq.js} +1 -1
- streamlit/static/static/js/{index.BvZbnSMC.js → index.DlgcEr0f.js} +1 -1
- streamlit/static/static/js/{index.Bo1ztye0.js → index.DxGXuhh6.js} +1 -1
- streamlit/static/static/js/{index.x1B588Xu.js → index.DxfYCrPp.js} +1 -1
- streamlit/static/static/js/{index.CyDHwK5P.js → index.HmRK3HyC.js} +1 -1
- streamlit/static/static/js/{index.DdxofXV8.js → index.TjMWsKSH.js} +3 -3
- streamlit/static/static/js/{index.Bri1T2TS.js → index.VwDKazgt.js} +1 -1
- streamlit/static/static/js/{index.BB_iwaVr.js → index.aCorc3Yt.js} +34 -34
- streamlit/static/static/js/{index.CdRwiHPm.js → index.cfuZ69LI.js} +1 -1
- streamlit/static/static/js/{index.C9v49R-a.js → index.hlAfdSqC.js} +1 -1
- streamlit/static/static/js/{index.BGTMh3Uu.js → index.iUV9rb8C.js} +1 -1
- streamlit/static/static/js/{index.XFMDBL5n.js → index.q0ceUXt6.js} +1 -1
- streamlit/static/static/js/{input.VYKyGuhi.js → input.CXGIJ7D6.js} +1 -1
- streamlit/static/static/js/{main.u5Bb3MY7.js → main.CCVkbuxC.js} +1 -1
- streamlit/static/static/js/{memory.BOMt4yAV.js → memory.CNbnYs2A.js} +1 -1
- streamlit/static/static/js/{number-overlay-editor.CihlAHgl.js → number-overlay-editor.CvI6wkld.js} +1 -1
- streamlit/static/static/js/{pandasStylerUtils.BuqSgXpk.js → pandasStylerUtils.CFSReOTm.js} +1 -1
- streamlit/static/static/js/{sandbox.COGR4pqz.js → sandbox.Bld0L3us.js} +1 -1
- streamlit/static/static/js/{styled-components.BEf3c4IJ.js → styled-components.BoUHK6TA.js} +1 -1
- streamlit/static/static/js/{throttle.Bl-XsA9N.js → throttle.ByDFm7WV.js} +1 -1
- streamlit/static/static/js/{timepicker.B-HgBYlK.js → timepicker.CN6CUZEL.js} +1 -1
- streamlit/static/static/js/{toConsumableArray.BrQebwtE.js → toConsumableArray.DwMycSpg.js} +1 -1
- streamlit/static/static/js/uniqueId.DcCWa2cf.js +1 -0
- streamlit/static/static/js/{useBasicWidgetState.8WwISl9r.js → useBasicWidgetState.Bg0ZMUt5.js} +1 -1
- streamlit/static/static/js/{useIntlLocale.D37LWdCR.js → useIntlLocale.DgBUDcPA.js} +1 -1
- streamlit/static/static/js/{useTextInputAutoExpand.Bb_KqJvq.js → useTextInputAutoExpand.DDBezxks.js} +1 -1
- streamlit/static/static/js/{useUpdateUiValue.D1BLS5t7.js → useUpdateUiValue.Df1h6fXC.js} +1 -1
- streamlit/static/static/js/{useWaveformController.Ce0-qTws.js → useWaveformController.DbWw5MEk.js} +1 -1
- streamlit/static/static/js/{withCalculatedWidth.BX2K3UVv.js → withCalculatedWidth.YaK0HIIP.js} +1 -1
- streamlit/static/static/js/{withFullScreenWrapper.CqfGs8T2.js → withFullScreenWrapper.CcWCKoY8.js} +1 -1
- streamlit/testing/v1/element_tree.py +23 -8
- streamlit/web/bootstrap.py +5 -2
- streamlit/web/server/server_util.py +22 -0
- {streamlit_nightly-1.53.2.dev20260125.dist-info → streamlit_nightly-1.53.2.dev20260128.dist-info}/METADATA +1 -1
- {streamlit_nightly-1.53.2.dev20260125.dist-info → streamlit_nightly-1.53.2.dev20260128.dist-info}/RECORD +120 -120
- streamlit/static/static/js/embed.C7by6AoE.js +0 -195
- streamlit/static/static/js/index.Bhy8EBYI.js +0 -2
- streamlit/static/static/js/index.C5ehUqNt.js +0 -2
- streamlit/static/static/js/index.m4WkwGMu.js +0 -1
- streamlit/static/static/js/uniqueId.8R4hbkYl.js +0 -1
- {streamlit_nightly-1.53.2.dev20260125.data → streamlit_nightly-1.53.2.dev20260128.data}/scripts/streamlit.cmd +0 -0
- {streamlit_nightly-1.53.2.dev20260125.dist-info → streamlit_nightly-1.53.2.dev20260128.dist-info}/WHEEL +0 -0
- {streamlit_nightly-1.53.2.dev20260125.dist-info → streamlit_nightly-1.53.2.dev20260128.dist-info}/entry_points.txt +0 -0
- {streamlit_nightly-1.53.2.dev20260125.dist-info → streamlit_nightly-1.53.2.dev20260128.dist-info}/top_level.txt +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as y,bj as oe,bk as ie,bl as ae,bm as le,x as s,A as P,am as F,bn as de,an as J,au as z,w as C,bo as Y,bp as G}from"./index.
|
|
1
|
+
import{r as y,bj as oe,bk as ie,bl as ae,bm as le,x as s,A as P,am as F,bn as de,an as J,au as z,w as C,bo as Y,bp as G}from"./index.aCorc3Yt.js";var pe=["title","size","color","overrides"];function D(){return D=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},D.apply(this,arguments)}function fe(e,t){if(e==null)return{};var r=ye(e,t),n,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)n=i[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function ye(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i<n.length;i++)o=n[i],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function ge(e,t){return me(e)||ve(e,t)||he(e,t)||be()}function be(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
2
2
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function he(e,t){if(e){if(typeof e=="string")return Q(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Q(e,t)}}function Q(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function ve(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],o=!0,i=!1,a,l;try{for(r=r.call(e);!(o=(a=r.next()).done)&&(n.push(a.value),!(t&&n.length===t));o=!0);}catch(u){i=!0,l=u}finally{try{!o&&r.return!=null&&r.return()}finally{if(i)throw l}}return n}}function me(e){if(Array.isArray(e))return e}function $e(e,t){var r=oe(),n=ge(r,2),o=n[1],i=e.title,a=i===void 0?"Hide":i,l=e.size,u=e.color,c=e.overrides,d=c===void 0?{}:c,g=fe(e,pe),b=ie({component:o.icons&&o.icons.Hide?o.icons.Hide:null},d&&d.Svg?ae(d.Svg):{});return y.createElement(le,D({viewBox:"0 0 20 20",ref:t,title:a,size:l,color:u,overrides:{Svg:b}},g),y.createElement("path",{d:"M12.81 4.36l-1.77 1.78a4 4 0 00-4.9 4.9l-2.76 2.75C2.06 12.79.96 11.49.2 10a11 11 0 0112.6-5.64zm3.8 1.85c1.33 1 2.43 2.3 3.2 3.79a11 11 0 01-12.62 5.64l1.77-1.78a4 4 0 004.9-4.9l2.76-2.75zm-.25-3.99l1.42 1.42L3.64 17.78l-1.42-1.42L16.36 2.22z"}))}const Oe=y.forwardRef($e);var Ce=["title","size","color","overrides"];function N(){return N=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},N.apply(this,arguments)}function Se(e,t){if(e==null)return{};var r=_e(e,t),n,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)n=i[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function _e(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i<n.length;i++)o=n[i],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function Ie(e,t){return Te(e)||Fe(e,t)||Pe(e,t)||we()}function we(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3
3
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Pe(e,t){if(e){if(typeof e=="string")return X(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return X(e,t)}}function X(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Fe(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],o=!0,i=!1,a,l;try{for(r=r.call(e);!(o=(a=r.next()).done)&&(n.push(a.value),!(t&&n.length===t));o=!0);}catch(u){i=!0,l=u}finally{try{!o&&r.return!=null&&r.return()}finally{if(i)throw l}}return n}}function Te(e){if(Array.isArray(e))return e}function ke(e,t){var r=oe(),n=Ie(r,2),o=n[1],i=e.title,a=i===void 0?"Show":i,l=e.size,u=e.color,c=e.overrides,d=c===void 0?{}:c,g=Se(e,Ce),b=ie({component:o.icons&&o.icons.Show?o.icons.Show:null},d&&d.Svg?ae(d.Svg):{});return y.createElement(le,N({viewBox:"0 0 20 20",ref:t,title:a,size:l,color:u,overrides:{Svg:b}},g),y.createElement("path",{d:"M.2 10a11 11 0 0119.6 0A11 11 0 01.2 10zm9.8 4a4 4 0 100-8 4 4 0 000 8zm0-2a2 2 0 110-4 2 2 0 010 4z"}))}const Ee=y.forwardRef(ke);function ee(e,t){var r=e.disabled,n=e.error,o=e.positive,i=e.adjoined,a=e.size,l=e.required,u=e.resize,c=e.readOnly,d=t.isFocused;return{$isFocused:d,$disabled:r,$error:n,$positive:o,$adjoined:i,$size:a,$required:l,$resize:u,$isReadOnly:c}}function te(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function h(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?te(Object(r),!0).forEach(function(n){p(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):te(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function p(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var K=F("button",function(e){var t,r=e.$theme,n=e.$size,o=e.$isFocusVisible,i=(t={},p(t,s.mini,r.sizing.scale400),p(t,s.compact,r.sizing.scale400),p(t,s.default,r.sizing.scale300),p(t,s.large,r.sizing.scale200),t)[n];return{display:"flex",alignItems:"center",borderTopStyle:"none",borderBottomStyle:"none",borderLeftStyle:"none",borderRightStyle:"none",background:"none",paddingLeft:i,paddingRight:i,outline:o?"solid 3px ".concat(r.colors.accent):"none",color:r.colors.contentPrimary}});K.displayName="StyledMaskToggleButton";K.displayName="StyledMaskToggleButton";var Z=F("div",function(e){var t,r=e.$alignTop,n=r===void 0?!1:r,o=e.$size,i=e.$theme,a=(t={},p(t,s.mini,i.sizing.scale200),p(t,s.compact,i.sizing.scale200),p(t,s.default,i.sizing.scale100),p(t,s.large,i.sizing.scale0),t)[o];return{display:"flex",alignItems:n?"flex-start":"center",paddingLeft:a,paddingRight:a,paddingTop:n?i.sizing.scale500:"0px",color:i.colors.contentPrimary}});Z.displayName="StyledClearIconContainer";Z.displayName="StyledClearIconContainer";var H=F(de,function(e){var t=e.$theme,r=e.$isFocusVisible;return{cursor:"pointer",outline:r?"solid 3px ".concat(t.colors.accent):"none"}});H.displayName="StyledClearIcon";H.displayName="StyledClearIcon";function Re(e,t){var r;return(r={},p(r,s.mini,{paddingTop:t.scale100,paddingBottom:t.scale100,paddingLeft:t.scale550,paddingRight:t.scale550}),p(r,s.compact,{paddingTop:t.scale200,paddingBottom:t.scale200,paddingLeft:t.scale550,paddingRight:t.scale550}),p(r,s.default,{paddingTop:t.scale400,paddingBottom:t.scale400,paddingLeft:t.scale550,paddingRight:t.scale550}),p(r,s.large,{paddingTop:t.scale550,paddingBottom:t.scale550,paddingLeft:t.scale550,paddingRight:t.scale550}),r)[e]}function xe(e,t,r,n,o){var i=e===P.both||e===P.left&&n!=="rtl"||e===P.right&&n==="rtl"||o&&n==="rtl",a=e===P.both||e===P.right&&n!=="rtl"||e===P.left&&n==="rtl"||o&&n!=="rtl";return{paddingLeft:i?r.scale550:"0px",paddingRight:a?r.scale550:"0px"}}function A(e,t){var r;return(r={},p(r,s.mini,t.font100),p(r,s.compact,t.font200),p(r,s.default,t.font300),p(r,s.large,t.font400),r)[e]}function Be(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,o=arguments.length>4?arguments[4]:void 0;return e?{borderLeftColor:o.inputFillDisabled,borderRightColor:o.inputFillDisabled,borderTopColor:o.inputFillDisabled,borderBottomColor:o.inputFillDisabled,backgroundColor:o.inputFillDisabled}:t?{borderLeftColor:o.borderSelected,borderRightColor:o.borderSelected,borderTopColor:o.borderSelected,borderBottomColor:o.borderSelected,backgroundColor:o.inputFillActive}:r?{borderLeftColor:o.inputBorderError,borderRightColor:o.inputBorderError,borderTopColor:o.inputBorderError,borderBottomColor:o.inputBorderError,backgroundColor:o.inputFillError}:n?{borderLeftColor:o.inputBorderPositive,borderRightColor:o.inputBorderPositive,borderTopColor:o.inputBorderPositive,borderBottomColor:o.inputBorderPositive,backgroundColor:o.inputFillPositive}:{borderLeftColor:o.inputBorder,borderRightColor:o.inputBorder,borderTopColor:o.inputBorder,borderBottomColor:o.inputBorder,backgroundColor:o.inputFill}}function je(e,t){var r=t.inputBorderRadius;return e===s.mini&&(r=t.inputBorderRadiusMini),{borderTopLeftRadius:r,borderBottomLeftRadius:r,borderTopRightRadius:r,borderBottomRightRadius:r}}var Ae=function(t){var r=t.$isFocused,n=t.$adjoined,o=t.$error,i=t.$disabled,a=t.$positive,l=t.$size,u=t.$theme,c=t.$theme,d=c.borders,g=c.colors,b=c.sizing,I=c.typography,$=c.animation,_=t.$hasIconTrailing;return h(h(h(h({boxSizing:"border-box",display:"flex",overflow:"hidden",width:"100%",borderLeftWidth:"2px",borderRightWidth:"2px",borderTopWidth:"2px",borderBottomWidth:"2px",borderLeftStyle:"solid",borderRightStyle:"solid",borderTopStyle:"solid",borderBottomStyle:"solid",transitionProperty:"border",transitionDuration:$.timing200,transitionTimingFunction:$.easeOutCurve},je(l,d)),A(l,I)),Be(i,r,o,a,g)),xe(n,l,b,u.direction,_))},se=F("div",Ae);se.displayName="Root";se.displayName="Root";function Me(e,t){var r;return(r={},p(r,s.mini,{paddingRight:t.scale400,paddingLeft:t.scale400}),p(r,s.compact,{paddingRight:t.scale400,paddingLeft:t.scale400}),p(r,s.default,{paddingRight:t.scale300,paddingLeft:t.scale300}),p(r,s.large,{paddingRight:t.scale200,paddingLeft:t.scale200}),r)[e]}function Le(e,t,r,n,o){return e?{color:o.inputEnhancerTextDisabled,backgroundColor:o.inputFillDisabled}:t?{color:o.contentPrimary,backgroundColor:o.inputFillActive}:r?{color:o.contentPrimary,backgroundColor:o.inputFillError}:n?{color:o.contentPrimary,backgroundColor:o.inputFillPositive}:{color:o.contentPrimary,backgroundColor:o.inputFill}}var ue=F("div",function(e){var t=e.$size,r=e.$disabled,n=e.$isFocused,o=e.$error,i=e.$positive,a=e.$theme,l=a.colors,u=a.sizing,c=a.typography,d=a.animation;return h(h(h({display:"flex",alignItems:"center",justifyContent:"center",transitionProperty:"color, background-color",transitionDuration:d.timing200,transitionTimingFunction:d.easeOutCurve},A(t,c)),Me(t,u)),Le(r,n,o,i,l))});ue.displayName="InputEnhancer";ue.displayName="InputEnhancer";function ze(e,t,r,n,o){return e?{color:o.inputTextDisabled,backgroundColor:o.inputFillDisabled}:t?{color:o.contentPrimary,backgroundColor:o.inputFillActive}:r?{color:o.contentPrimary,backgroundColor:o.inputFillError}:n?{color:o.contentPrimary,backgroundColor:o.inputFillPositive}:{color:o.contentPrimary,backgroundColor:o.inputFill}}var De=function(t){var r=t.$isFocused,n=t.$error,o=t.$disabled,i=t.$positive,a=t.$size,l=t.$theme,u=l.colors,c=l.typography,d=l.animation;return h(h({display:"flex",width:"100%",transitionProperty:"background-color",transitionDuration:d.timing200,transitionTimingFunction:d.easeOutCurve},A(a,c)),ze(o,r,n,i,u))},U=F("div",De);U.displayName="InputContainer";U.displayName="InputContainer";function Ne(e,t,r,n){return e?{color:n.inputTextDisabled,"-webkit-text-fill-color":n.inputTextDisabled,caretColor:n.contentPrimary,"::placeholder":{color:n.inputPlaceholderDisabled}}:{color:n.contentPrimary,caretColor:n.contentPrimary,"::placeholder":{color:n.inputPlaceholder}}}var Ve=function(t){var r=t.$disabled,n=t.$isFocused,o=t.$error,i=t.$size,a=t.$theme,l=a.colors,u=a.sizing,c=a.typography;return h(h(h({boxSizing:"border-box",backgroundColor:"transparent",borderLeftWidth:0,borderRightWidth:0,borderTopWidth:0,borderBottomWidth:0,borderLeftStyle:"none",borderRightStyle:"none",borderTopStyle:"none",borderBottomStyle:"none",outline:"none",width:"100%",minWidth:0,maxWidth:"100%",cursor:r?"not-allowed":"text",margin:"0",paddingTop:"0",paddingBottom:"0",paddingLeft:"0",paddingRight:"0"},A(i,c)),Re(i,u)),Ne(r,n,o,l))},q=F("input",Ve);q.displayName="Input";q.displayName="Input";function We(e){var t;return typeof window.Event=="function"?t=new window.Event(e,{bubbles:!0,cancelable:!0}):(t=document.createEvent("Event"),t.initEvent(e,!0,!0)),t}function V(e){"@babel/helpers - typeof";return V=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},V(e)}function m(){return m=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},m.apply(this,arguments)}function S(e,t){return Ue(e)||He(e,t)||Ze(e,t)||Ke()}function Ke(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
4
4
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ze(e,t){if(e){if(typeof e=="string")return re(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return re(e,t)}}function re(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function He(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],o=!0,i=!1,a,l;try{for(r=r.call(e);!(o=(a=r.next()).done)&&(n.push(a.value),!(t&&n.length===t));o=!0);}catch(u){i=!0,l=u}finally{try{!o&&r.return!=null&&r.return()}finally{if(i)throw l}}return n}}function Ue(e){if(Array.isArray(e))return e}function qe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Je(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function Ye(e,t,r){return t&&Je(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ge(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&W(e,t)}function W(e,t){return W=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,o){return n.__proto__=o,n},W(e,t)}function Qe(e){var t=et();return function(){var n=j(e),o;if(t){var i=j(this).constructor;o=Reflect.construct(n,arguments,i)}else o=n.apply(this,arguments);return Xe(this,o)}}function Xe(e,t){if(t&&(V(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return v(e)}function v(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function et(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function j(e){return j=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},j(e)}function f(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var ne=function(){return null},tt=(function(e){Ge(r,e);var t=Qe(r);function r(){var n;qe(this,r);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return n=t.call.apply(t,[this].concat(i)),f(v(n),"inputRef",n.props.inputRef||y.createRef()),f(v(n),"state",{isFocused:n.props.autoFocus||!1,isMasked:n.props.type==="password",initialType:n.props.type,isFocusVisibleForClear:!1,isFocusVisibleForMaskToggle:!1}),f(v(n),"onInputKeyDown",function(l){n.props.clearOnEscape&&l.key==="Escape"&&n.inputRef.current&&!n.props.readOnly&&(n.clearValue(),l.stopPropagation())}),f(v(n),"onClearIconClick",function(){n.inputRef.current&&n.clearValue(),n.inputRef.current&&n.inputRef.current.focus()}),f(v(n),"onFocus",function(l){n.setState({isFocused:!0}),n.props.onFocus(l)}),f(v(n),"onBlur",function(l){n.setState({isFocused:!1}),n.props.onBlur(l)}),f(v(n),"handleFocusForMaskToggle",function(l){J(l)&&n.setState({isFocusVisibleForMaskToggle:!0})}),f(v(n),"handleBlurForMaskToggle",function(l){n.state.isFocusVisibleForMaskToggle!==!1&&n.setState({isFocusVisibleForMaskToggle:!1})}),f(v(n),"handleFocusForClear",function(l){J(l)&&n.setState({isFocusVisibleForClear:!0})}),f(v(n),"handleBlurForClear",function(l){n.state.isFocusVisibleForClear!==!1&&n.setState({isFocusVisibleForClear:!1})}),n}return Ye(r,[{key:"componentDidMount",value:function(){var o=this.props,i=o.autoFocus,a=o.clearable;this.inputRef.current&&(i&&this.inputRef.current.focus(),a&&this.inputRef.current.addEventListener("keydown",this.onInputKeyDown))}},{key:"componentWillUnmount",value:function(){var o=this.props.clearable;o&&this.inputRef.current&&this.inputRef.current.removeEventListener("keydown",this.onInputKeyDown)}},{key:"clearValue",value:function(){var o=this.inputRef.current;if(o){var i=Object.getOwnPropertyDescriptor(this.props.type===z.textarea?HTMLTextAreaElement.prototype:HTMLInputElement.prototype,"value");if(i){var a=i.set;if(a){a.call(o,"");var l=We("input");o.dispatchEvent(l)}}}}},{key:"getInputType",value:function(){return this.props.type==="password"?this.state.isMasked?"password":"text":this.props.type}},{key:"renderMaskToggle",value:function(){var o,i=this;if(this.props.type!=="password")return null;var a=C(this.props.overrides.MaskToggleButton,K),l=S(a,2),u=l[0],c=l[1],d=C(this.props.overrides.MaskToggleShowIcon,Ee),g=S(d,2),b=g[0],I=g[1],$=C(this.props.overrides.MaskToggleHideIcon,Oe),_=S($,2),T=_[0],x=_[1],O=this.state.isMasked?"Show password text":"Hide password text",k=(o={},f(o,s.mini,"12px"),f(o,s.compact,"16px"),f(o,s.default,"20px"),f(o,s.large,"24px"),o)[this.props.size];return y.createElement(u,m({$size:this.props.size,$isFocusVisible:this.state.isFocusVisibleForMaskToggle,"aria-label":O,onClick:function(){return i.setState(function(E){return{isMasked:!E.isMasked}})},title:O,type:"button"},c,{onFocus:G(c,this.handleFocusForMaskToggle),onBlur:Y(c,this.handleBlurForMaskToggle)}),this.state.isMasked?y.createElement(b,m({size:k,title:O},I)):y.createElement(T,m({size:k,title:O},x)))}},{key:"renderClear",value:function(){var o,i=this,a=this.props,l=a.clearable,u=a.value,c=a.disabled,d=a.readOnly,g=a.overrides,b=g===void 0?{}:g;if(c||d||!l||u==null||typeof u=="string"&&u.length===0)return null;var I=C(b.ClearIconContainer,Z),$=S(I,2),_=$[0],T=$[1],x=C(b.ClearIcon,H),O=S(x,2),k=O[0],w=O[1],E="Clear value",B=ee(this.props,this.state),M=(o={},f(o,s.mini,"14px"),f(o,s.compact,"14px"),f(o,s.default,"16px"),f(o,s.large,"22px"),o)[this.props.size];return y.createElement(_,m({$alignTop:this.props.type===z.textarea},B,T),y.createElement(k,m({size:M,tabIndex:0,title:E,"aria-label":E,onClick:this.onClearIconClick,onKeyDown:function(R){R.key&&(R.key==="Enter"||R.key===" ")&&(R.preventDefault(),i.onClearIconClick())},role:"button",$isFocusVisible:this.state.isFocusVisibleForClear},B,w,{onFocus:G(w,this.handleFocusForClear),onBlur:Y(w,this.handleBlurForClear)})))}},{key:"render",value:function(){var o=this.props.overrides,i=o.InputContainer,a=o.Input,l=o.Before,u=o.After,c=this.state.initialType==="password"&&this.props.autoComplete===r.defaultProps.autoComplete?"new-password":this.props.autoComplete,d=ee(this.props,this.state),g=C(i,U),b=S(g,2),I=b[0],$=b[1],_=C(a,q),T=S(_,2),x=T[0],O=T[1],k=C(l,ne),w=S(k,2),E=w[0],B=w[1],M=C(u,ne),L=S(M,2),R=L[0],ce=L[1];return y.createElement(I,m({"data-baseweb":this.props["data-baseweb"]||"base-input"},d,$),y.createElement(E,m({},d,B)),y.createElement(x,m({ref:this.inputRef,"aria-activedescendant":this.props["aria-activedescendant"],"aria-autocomplete":this.props["aria-autocomplete"],"aria-controls":this.props["aria-controls"],"aria-errormessage":this.props["aria-errormessage"],"aria-haspopup":this.props["aria-haspopup"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-describedby":this.props["aria-describedby"],"aria-invalid":this.props.error,"aria-required":this.props.required,autoComplete:c,disabled:this.props.disabled,readOnly:this.props.readOnly,id:this.props.id,inputMode:this.props.inputMode,maxLength:this.props.maxLength,name:this.props.name,onBlur:this.onBlur,onChange:this.props.onChange,onFocus:this.onFocus,onKeyDown:this.props.onKeyDown,onKeyPress:this.props.onKeyPress,onKeyUp:this.props.onKeyUp,pattern:this.props.pattern,placeholder:this.props.placeholder,type:this.getInputType(),required:this.props.required,role:this.props.role,value:this.props.value,min:this.props.min,max:this.props.max,step:this.props.step,rows:this.props.type===z.textarea?this.props.rows:null},d,O)),this.renderClear(),this.renderMaskToggle(),y.createElement(R,m({},d,ce)))}}]),r})(y.Component);f(tt,"defaultProps",{"aria-activedescendant":null,"aria-autocomplete":null,"aria-controls":null,"aria-errormessage":null,"aria-haspopup":null,"aria-label":null,"aria-labelledby":null,"aria-describedby":null,adjoined:P.none,autoComplete:"on",autoFocus:!1,disabled:!1,error:!1,positive:!1,name:"",inputMode:"text",onBlur:function(){},onChange:function(){},onKeyDown:function(){},onKeyPress:function(){},onKeyUp:function(){},onFocus:function(){},onClear:function(){},clearable:!1,clearOnEscape:!0,overrides:{},pattern:null,placeholder:"",required:!1,role:null,size:s.default,type:"text",readOnly:!1});export{tt as B,ue as I,se as R,Ae as a,De as b,Ve as c,q as d,ee as g};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{am as $,an as ie,ao as v,r as u,ap as p}from"./index.
|
|
1
|
+
import{am as $,an as ie,ao as v,r as u,ap as p}from"./index.aCorc3Yt.js";var T=Object.freeze({default:"default",toggle:"toggle",toggle_round:"toggle"}),ye=Object.freeze({top:"top",right:"right",bottom:"bottom",left:"left"});function U(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),o.push.apply(o,r)}return o}function P(e){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?U(Object(o),!0).forEach(function(r){q(e,r,o[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):U(Object(o)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(o,r))})}return e}function q(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function ne(e){var t=e.$disabled,o=e.$checked,r=e.$error,i=e.$isIndeterminate,a=e.$theme,n=e.$isFocusVisible,l=a.colors;return t?l.tickFillDisabled:o||i?"transparent":r?l.borderNegative:n?l.borderSelected:l.tickBorder}function ae(e){var t=e.$labelPlacement,o=t===void 0?"":t,r=e.$theme,i=r.sizing,a=i.scale300,n;switch(o){case"top":n="Bottom";break;case"bottom":n="Top";break;case"left":n="Right";break;default:case"right":n="Left";break}return r.direction==="rtl"&&n==="Left"?n="Right":r.direction==="rtl"&&n==="Right"&&(n="Left"),q({},"padding".concat(n),a)}function le(e){var t=e.$disabled,o=e.$checked,r=e.$isIndeterminate,i=e.$error,a=e.$isHovered,n=e.$isActive,l=e.$theme,c=l.colors;return t?o||r?c.tickFillDisabled:c.tickFill:i&&(r||o)?n?c.tickFillErrorSelectedHoverActive:a?c.tickFillErrorSelectedHover:c.tickFillErrorSelected:i?n?c.tickFillErrorHoverActive:a?c.tickFillErrorHover:c.tickFillError:r||o?n?c.tickFillSelectedHoverActive:a?c.tickFillSelectedHover:c.tickFillSelected:n?c.tickFillActive:a?c.tickFillHover:c.tickFill}function ce(e){var t=e.$disabled,o=e.$theme,r=o.colors;return t?r.contentSecondary:r.contentPrimary}var x=$("label",function(e){var t=e.$disabled,o=e.$labelPlacement;return{flexDirection:o==="top"||o==="bottom"?"column":"row",display:"flex",alignItems:o==="top"||o==="bottom"?"center":"flex-start",cursor:t?"not-allowed":"pointer",userSelect:"none"}});x.displayName="Root";x.displayName="Root";var E=$("span",function(e){var t=e.$checked,o=e.$disabled,r=e.$error,i=e.$isIndeterminate,a=e.$theme,n=e.$isFocusVisible,l=a.sizing,c=a.animation,s=o?a.colors.tickMarkFillDisabled:r?a.colors.tickMarkFillError:a.colors.tickMarkFill,w=encodeURIComponent(`
|
|
2
2
|
<svg width="14" height="4" viewBox="0 0 14 4" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
3
3
|
<path d="M14 0.5H0V3.5H14V0.5Z" fill="`.concat(s,`"/>
|
|
4
4
|
</svg>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{S as a}from"./index.
|
|
1
|
+
import{S as a}from"./index.aCorc3Yt.js";const s=({enforceDownloadInNewTab:n,url:e,filename:o})=>{const t=document.createElement("a");t.setAttribute("href",e),n?t.setAttribute("target","_blank"):t.setAttribute("target","_self");const r=a.DOWNLOAD_ASSETS_BASE_URL;return(!r||!e.startsWith(r)||window.navigator.userAgent.includes("Firefox"))&&t.setAttribute("download",o),t};export{s as c};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r,aj as J}from"./index.
|
|
1
|
+
import{r,aj as J}from"./index.aCorc3Yt.js";import{s as Q,i as I,a as U,b as Z,T as ee,C as te,m as re}from"./index.DBPWUJsj.js";import"./withFullScreenWrapper.CcWCKoY8.js";import"./Toolbar.CQsWYXer.js";import"./FormClearHelper.DN8D_YXO.js";import"./moment.C7qA8nIE.js";import"./pandasStylerUtils.CFSReOTm.js";import"./numbro.B9_PXfzp.js";import"./_baseIndexOf.BTknn6Gb.js";import"./index.8HslT92O.js";import"./main.CCVkbuxC.js";import"./throttle.ByDFm7WV.js";import"./toConsumableArray.DwMycSpg.js";import"./formatNumber.BK7h0k2z.js";import"./sprintf.DpPCfzXw.js";import"./formatMoment.C6Hwn6X5.js";import"./checkbox.OTGupu18.js";import"./createDownloadLinkElement.DnBEQQbK.js";import"./FileDownload.esm.yTkppsJy.js";import"./_arrayIncludes.B19Iyn2B.js";const ie=()=>t=>t.targetX,ne=()=>t=>t.targetY,se=()=>t=>t.targetWidth,oe=()=>t=>t.targetHeight,ae=()=>t=>t.targetY+10,le=()=>t=>Math.max(0,(t.targetHeight-28)/2),de=Q("div")({name:"DataGridOverlayEditorStyle",class:"gdg-d19meir1",propsAsIs:!1,vars:{"d19meir1-0":[ne(),"px"],"d19meir1-1":[ie(),"px"],"d19meir1-2":[se(),"px"],"d19meir1-3":[oe(),"px"],"d19meir1-4":[ae(),"px"],"d19meir1-5":[le(),"px"]}});function ue(){const[t,s]=r.useState();return[t??void 0,s]}function ce(){const[t,s]=ue(),[n,h]=r.useState(0),[f,b]=r.useState(!0);r.useLayoutEffect(()=>{if(t===void 0||!("IntersectionObserver"in window))return;const o=new IntersectionObserver(a=>{a.length!==0&&b(a[0].isIntersecting)},{threshold:1});return o.observe(t),()=>o.disconnect()},[t]),r.useEffect(()=>{if(f||t===void 0)return;let o;const a=()=>{const{right:x}=t.getBoundingClientRect();h(m=>Math.min(m+window.innerWidth-x-10,0)),o=requestAnimationFrame(a)};return o=requestAnimationFrame(a),()=>{o!==void 0&&cancelAnimationFrame(o)}},[t,f]);const C=r.useMemo(()=>({transform:`translateX(${n}px)`}),[n]);return{ref:s,style:C}}const Te=t=>{const{target:s,content:n,onFinishEditing:h,forceEditMode:f,initialValue:b,imageEditorOverride:C,markdownDivCreateNode:o,highlight:a,className:x,theme:m,id:W,cell:p,bloom:w,portalElementRef:F,validateCell:g,getCellRenderer:P,provideEditor:T,isOutsideClick:X,customEventTarget:j,activation:O}=t,[l,A]=r.useState(f?n:void 0),S=r.useRef(l??n);S.current=l??n;const[y,k]=r.useState(()=>g===void 0?!0:!(I(n)&&g?.(p,n,S.current)===!1)),u=r.useCallback((e,i)=>{h(y?e:void 0,i)},[y,h]),K=r.useCallback(e=>{if(g!==void 0&&e!==void 0&&I(e)){const i=g(p,e,S.current);i===!1?k(!1):(typeof i=="object"&&(e=i),k(!0))}A(e)},[p,g]),E=r.useRef(!1),c=r.useRef(void 0),Y=r.useCallback(()=>{u(l,[0,0]),E.current=!0},[l,u]),L=r.useCallback((e,i)=>{u(e,i??c.current??[0,0]),E.current=!0},[u]),q=r.useCallback(async e=>{let i=!1;e.key==="Escape"?(e.stopPropagation(),e.preventDefault(),c.current=[0,0]):e.key==="Enter"&&!e.shiftKey?(e.stopPropagation(),e.preventDefault(),c.current=[0,1],i=!0):e.key==="Tab"&&(e.stopPropagation(),e.preventDefault(),c.current=[e.shiftKey?-1:1,0],i=!0),window.setTimeout(()=>{!E.current&&c.current!==void 0&&(u(i?l:void 0,c.current),E.current=!0)},0)},[u,l]),R=l??n,[d,B]=r.useMemo(()=>{if(U(n))return[];const e={...n,location:p,activation:O},i=T?.(e);return i!==void 0?[i,!1]:[P(n)?.provideEditor?.(e),!1]},[p,n,P,T,O]),{ref:$,style:z}=ce();let M=!0,_,N=!0,v;if(d!==void 0){M=d.disablePadding!==!0,N=d.disableStyling!==!0;const e=Z(d);e&&(v=d.styleOverride);const i=e?d.editor:d;_=r.createElement(i,{portalElementRef:F,isHighlighted:a,activation:O,onChange:K,value:R,initialValue:b,onFinishedEditing:L,validatedSelection:I(R)?R.selectionRange:void 0,forceEditMode:f,target:s,imageEditorOverride:C,markdownDivCreateNode:o,isValid:y,theme:m})}v={...v,...z};const V=F?.current??document.getElementById("portal");if(V===null)return console.error('Cannot open Data Grid overlay editor, because portal not found. Please, either provide a portalElementRef or add `<div id="portal" />` as the last child of your `<body>`.'),null;let D=N?"gdg-style":"gdg-unstyle";y||(D+=" gdg-invalid"),M&&(D+=" gdg-pad");const G=w?.[0]??1,H=w?.[1]??1;return J.createPortal(r.createElement(ee.Provider,{value:m},r.createElement(te,{style:re(m),className:x,onClickOutside:Y,isOutsideClick:X,customEventTarget:j},r.createElement(de,{ref:$,id:W,className:D,style:v,as:B===!0?"label":void 0,targetX:s.x-G,targetY:s.y-H,targetWidth:s.width+G*2,targetHeight:s.height+H*2},r.createElement("div",{className:"gdg-clip-region",onKeyDown:q},_)))),V)};export{Te as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as w,e as b}from"./es6.
|
|
1
|
+
import{c as w,e as b}from"./es6.BHy5pqTP.js";import"./index.aCorc3Yt.js";const{WritableStream:m,TransformStream:y,DOMException:P,Blob:_}=w,{GONE:v}=b,E=/constructor/i.test(window.HTMLElement);class C{constructor(e="unkown"){this.name=e,this.kind="file"}async getFile(){throw new P(...v)}async isSameEntry(e){return this===e}async createWritable(e={}){const t=await navigator.serviceWorker?.getRegistration(),o=document.createElement("a"),n=new y,u=n.writable;if(o.download=this.name,E||!t){let r=[];n.readable.pipeTo(new m({write(s){r.push(new _([s]))},close(){const s=new _(r,{type:"application/octet-stream; charset=utf-8"});r=[],o.href=URL.createObjectURL(s),o.click(),setTimeout(()=>URL.revokeObjectURL(o.href),1e4)}}))}else{const{writable:r,readablePort:s}=new S(m),a=encodeURIComponent(this.name).replace(/['()]/g,escape).replace(/\*/g,"%2A"),R={"content-disposition":"attachment; filename*=UTF-8''"+a,"content-type":"application/octet-stream; charset=utf-8",...e.size?{"content-length":e.size}:{}},f=setTimeout(()=>t.active.postMessage(0),1e4);n.readable.pipeThrough(new y({transform(c,d){if(c instanceof Uint8Array)return d.enqueue(c);const g=new Response(c).body.getReader(),h=j=>g.read().then(p=>p.done?0:h(d.enqueue(p.value)));return h()}})).pipeTo(r).finally(()=>{clearInterval(f)}),t.active.postMessage({url:t.scope+a,headers:R,readablePort:s},[s]);const i=document.createElement("iframe");i.hidden=!0,i.src=t.scope+a,document.body.appendChild(i)}return u.getWriter()}}const M=0,T=0,L=1,O=1,U=2;class k{constructor(e){e.onmessage=t=>this._onMessage(t.data),this._port=e,this._resetReady()}start(e){return this._controller=e,this._readyPromise}write(e){const t={type:M,chunk:e};return this._port.postMessage(t,[e.buffer]),this._resetReady(),this._readyPromise}close(){this._port.postMessage({type:U}),this._port.close()}abort(e){this._port.postMessage({type:O,reason:e}),this._port.close()}_onMessage(e){e.type===T&&this._resolveReady(),e.type===L&&this._onError(e.reason)}_onError(e){this._controller.error(e),this._rejectReady(e),this._port.close()}_resetReady(){this._readyPromise=new Promise((e,t)=>{this._readyResolve=e,this._readyReject=t}),this._readyPending=!0}_resolveReady(){this._readyResolve(),this._readyPending=!1}_rejectReady(e){this._readyPending||this._resetReady(),this._readyPromise.catch(()=>{}),this._readyReject(e),this._readyPending=!1}}class S{constructor(e){const t=new MessageChannel;this.readablePort=t.port1,this.writable=new e(new k(t.port2))}}export{C as FileHandle};
|