streamlit-nightly 1.53.2.dev20260128__py3-none-any.whl → 1.53.2.dev20260131__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/config.py +3 -2
- streamlit/config_util.py +63 -8
- streamlit/elements/deck_gl_json_chart.py +5 -1
- streamlit/elements/lib/built_in_chart_utils.py +24 -4
- streamlit/elements/lib/color_util.py +20 -1
- streamlit/elements/vega_charts.py +24 -4
- streamlit/proto/Alert_pb2.py +2 -3
- streamlit/proto/AppPage_pb2.py +2 -3
- streamlit/proto/ArrowData_pb2.py +2 -3
- streamlit/proto/ArrowNamedDataSet_pb2.py +2 -3
- streamlit/proto/ArrowVegaLiteChart_pb2.py +2 -3
- streamlit/proto/Arrow_pb2.py +11 -18
- streamlit/proto/Arrow_pb2.pyi +1 -42
- streamlit/proto/AudioInput_pb2.py +2 -3
- streamlit/proto/Audio_pb2.py +2 -3
- streamlit/proto/AuthRedirect_pb2.py +2 -3
- streamlit/proto/AutoRerun_pb2.py +2 -3
- streamlit/proto/BackMsg_pb2.py +2 -3
- streamlit/proto/Balloons_pb2.py +2 -3
- streamlit/proto/BidiComponent_pb2.py +2 -3
- streamlit/proto/Block_pb2.py +36 -43
- streamlit/proto/Block_pb2.pyi +3 -48
- streamlit/proto/BokehChart_pb2.py +2 -3
- streamlit/proto/ButtonGroup_pb2.py +2 -3
- streamlit/proto/ButtonLikeIconPosition_pb2.py +2 -3
- streamlit/proto/Button_pb2.py +3 -6
- streamlit/proto/Button_pb2.pyi +1 -18
- streamlit/proto/CameraInput_pb2.py +2 -3
- streamlit/proto/ChatInput_pb2.py +5 -8
- streamlit/proto/ChatInput_pb2.pyi +1 -17
- streamlit/proto/Checkbox_pb2.py +2 -3
- streamlit/proto/ClientState_pb2.py +2 -3
- streamlit/proto/Code_pb2.py +3 -6
- streamlit/proto/Code_pb2.pyi +1 -18
- streamlit/proto/ColorPicker_pb2.py +2 -3
- streamlit/proto/Common_pb2.py +7 -8
- streamlit/proto/Common_pb2.pyi +2 -10
- streamlit/proto/Components_pb2.py +2 -3
- streamlit/proto/DateInput_pb2.py +2 -3
- streamlit/proto/DateTimeInput_pb2.py +2 -3
- streamlit/proto/DeckGlJsonChart_pb2.py +5 -12
- streamlit/proto/DeckGlJsonChart_pb2.pyi +1 -54
- streamlit/proto/Delta_pb2.py +4 -6
- streamlit/proto/Delta_pb2.pyi +5 -14
- streamlit/proto/DocString_pb2.py +2 -3
- streamlit/proto/DownloadButton_pb2.py +2 -3
- streamlit/proto/Element_pb2.py +4 -7
- streamlit/proto/Element_pb2.pyi +3 -23
- streamlit/proto/Empty_pb2.py +2 -3
- streamlit/proto/Exception_pb2.py +2 -3
- streamlit/proto/Favicon_pb2.py +2 -3
- streamlit/proto/FileUploader_pb2.py +2 -3
- streamlit/proto/ForwardMsg_pb2.py +12 -18
- streamlit/proto/ForwardMsg_pb2.pyi +4 -48
- streamlit/proto/GapSize_pb2.py +2 -3
- streamlit/proto/GitInfo_pb2.py +2 -3
- streamlit/proto/GraphVizChart_pb2.py +3 -6
- streamlit/proto/GraphVizChart_pb2.pyi +1 -18
- streamlit/proto/Heading_pb2.py +2 -3
- streamlit/proto/HeightConfig_pb2.py +2 -3
- streamlit/proto/Html_pb2.py +2 -3
- streamlit/proto/IFrame_pb2.py +3 -10
- streamlit/proto/IFrame_pb2.pyi +1 -42
- streamlit/proto/Image_pb2.py +3 -6
- streamlit/proto/Image_pb2.pyi +1 -18
- streamlit/proto/Json_pb2.py +2 -3
- streamlit/proto/LabelVisibilityMessage_pb2.py +2 -3
- streamlit/proto/LinkButton_pb2.py +2 -3
- streamlit/proto/Logo_pb2.py +2 -3
- streamlit/proto/Markdown_pb2.py +2 -3
- streamlit/proto/Metric_pb2.py +2 -3
- streamlit/proto/MetricsEvent_pb2.py +2 -3
- streamlit/proto/MultiSelect_pb2.py +3 -6
- streamlit/proto/MultiSelect_pb2.pyi +1 -11
- streamlit/proto/Navigation_pb2.py +2 -3
- streamlit/proto/NewSession_pb2.py +27 -28
- streamlit/proto/NewSession_pb2.pyi +2 -12
- streamlit/proto/NumberInput_pb2.py +2 -3
- streamlit/proto/PageConfig_pb2.py +2 -3
- streamlit/proto/PageInfo_pb2.py +2 -3
- streamlit/proto/PageLink_pb2.py +2 -3
- streamlit/proto/PageNotFound_pb2.py +2 -3
- streamlit/proto/PageProfile_pb2.py +2 -3
- streamlit/proto/ParentMessage_pb2.py +2 -3
- streamlit/proto/PlotlyChart_pb2.py +5 -10
- streamlit/proto/PlotlyChart_pb2.pyi +1 -58
- streamlit/proto/Progress_pb2.py +2 -3
- streamlit/proto/Radio_pb2.py +3 -6
- streamlit/proto/Radio_pb2.pyi +2 -19
- streamlit/proto/RootContainer_pb2.py +2 -3
- streamlit/proto/Selectbox_pb2.py +3 -6
- streamlit/proto/Selectbox_pb2.pyi +2 -19
- streamlit/proto/SessionEvent_pb2.py +2 -3
- streamlit/proto/SessionStatus_pb2.py +2 -3
- streamlit/proto/Skeleton_pb2.py +2 -3
- streamlit/proto/Slider_pb2.py +2 -3
- streamlit/proto/Snow_pb2.py +2 -3
- streamlit/proto/Space_pb2.py +2 -3
- streamlit/proto/Spinner_pb2.py +2 -3
- streamlit/proto/TextAlignmentConfig_pb2.py +2 -3
- streamlit/proto/TextArea_pb2.py +3 -6
- streamlit/proto/TextArea_pb2.pyi +1 -18
- streamlit/proto/TextInput_pb2.py +2 -3
- streamlit/proto/Text_pb2.py +2 -3
- streamlit/proto/TimeInput_pb2.py +2 -3
- streamlit/proto/Toast_pb2.py +2 -3
- streamlit/proto/Transient_pb2.py +2 -3
- streamlit/proto/Video_pb2.py +2 -3
- streamlit/proto/WidgetStates_pb2.py +2 -3
- streamlit/proto/WidthConfig_pb2.py +2 -3
- streamlit/proto/openmetrics_data_model_pb2.py +2 -3
- streamlit/runtime/runtime.py +0 -4
- streamlit/static/index.html +1 -1
- streamlit/static/manifest.json +295 -295
- streamlit/static/static/js/{ErrorOutline.esm.D71F8ziR.js → ErrorOutline.esm.DC6KVDKK.js} +1 -1
- streamlit/static/static/js/{FileDownload.esm.yTkppsJy.js → FileDownload.esm.Z9hRQIHi.js} +1 -1
- streamlit/static/static/js/{FileHelper.hUOqtbwa.js → FileHelper.DqvW90pm.js} +1 -1
- streamlit/static/static/js/{FormClearHelper.DN8D_YXO.js → FormClearHelper.DTFnX0js.js} +1 -1
- streamlit/static/static/js/{InputInstructions.DbssY6d4.js → InputInstructions.CdzsN_Va.js} +1 -1
- streamlit/static/static/js/{Particles.BznyVdfo.js → Particles.12xFSjcn.js} +1 -1
- streamlit/static/static/js/{ProgressBar.C5uBOtcx.js → ProgressBar.Dg-oMbWg.js} +1 -1
- streamlit/static/static/js/{StreamlitSyntaxHighlighter.Nf1895x-.js → StreamlitSyntaxHighlighter.rbzmcipw.js} +1 -1
- streamlit/static/static/js/{TableChart.esm.DHKzVs3a.js → TableChart.esm.CzJtGIR-.js} +1 -1
- streamlit/static/static/js/{Toolbar.CQsWYXer.js → Toolbar.COH7NaOE.js} +1 -1
- streamlit/static/static/js/{WidgetLabelHelpIconInline.6xCU76OE.js → WidgetLabelHelpIconInline.Dlc8f0Ji.js} +1 -1
- streamlit/static/static/js/{base-input.Cs-E6S71.js → base-input.Q-zJLgRK.js} +4 -4
- streamlit/static/static/js/{checkbox.OTGupu18.js → checkbox.BKgWNdeI.js} +1 -1
- streamlit/static/static/js/{createDownloadLinkElement.DnBEQQbK.js → createDownloadLinkElement.6oO-YlYv.js} +1 -1
- streamlit/static/static/js/{data-grid-overlay-editor.COiiMi5r.js → data-grid-overlay-editor.CO0xdNiG.js} +1 -1
- streamlit/static/static/js/{downloader.K0GUNeuj.js → downloader.BBXcXdX1.js} +1 -1
- streamlit/static/static/js/{embed.o8HvK3mH.js → embed.CJzOXYBF.js} +1 -1
- streamlit/static/static/js/{es6.BHy5pqTP.js → es6.CdxPQzwJ.js} +2 -2
- streamlit/static/static/js/{formatNumber.BK7h0k2z.js → formatNumber.DB5irY8c.js} +1 -1
- streamlit/static/static/js/{iconPosition.2YynQUxu.js → iconPosition.BVScIr6G.js} +1 -1
- streamlit/static/static/js/{iframeResizer.contentWindow.D5h3hQuU.js → iframeResizer.contentWindow.D_QHVqPM.js} +1 -1
- streamlit/static/static/js/{index.cfuZ69LI.js → index.6DFY6LUF.js} +1 -1
- streamlit/static/static/js/{index.Dh3PJIlq.js → index.B80gSxrS.js} +1 -1
- streamlit/static/static/js/{index.DxfYCrPp.js → index.BDtN2n7T.js} +1 -1
- streamlit/static/static/js/{index.DLUSo6de.js → index.BED2_zc7.js} +1 -1
- streamlit/static/static/js/{index.CxWzt6oi.js → index.BQnLeHnr.js} +1 -1
- streamlit/static/static/js/{index.Cb03y5I8.js → index.BSYebegS.js} +1 -1
- streamlit/static/static/js/{index.BtuskCwg.js → index.BSpYHDvk.js} +1 -1
- streamlit/static/static/js/{index.q0ceUXt6.js → index.BiCbrx53.js} +1 -1
- streamlit/static/static/js/{index.CgVv04GM.js → index.Biyf9aUg.js} +1 -1
- streamlit/static/static/js/{index.BPdmXoYW.js → index.BqbKiDp2.js} +1 -1
- streamlit/static/static/js/{index.COh5V_89.js → index.BqxwnMem.js} +1 -1
- streamlit/static/static/js/{index.DVRCyxMp.js → index.BtOoVQt7.js} +1 -1
- streamlit/static/static/js/{index.C7wst9Tm.js → index.BxMkW82k.js} +1 -1
- streamlit/static/static/js/{index.5zqfJ-in.js → index.BxQxTpWl.js} +1 -1
- streamlit/static/static/js/{index.BtRWcqZV.js → index.C5oqIM3a.js} +1 -1
- streamlit/static/static/js/{index.iUV9rb8C.js → index.CBE2cIbj.js} +1 -1
- streamlit/static/static/js/{index.DcngUOyD.js → index.CE2WIFD1.js} +1 -1
- streamlit/static/static/js/{index.aCorc3Yt.js → index.CPc_uZux.js} +48 -48
- streamlit/static/static/js/{index.Bqmx23jK.js → index.CUYi3FrD.js} +1 -1
- streamlit/static/static/js/index.Cpu2p5bH.js +1 -0
- streamlit/static/static/js/{index.Bfo1cXfC.js → index.CrY1BsL3.js} +1 -1
- streamlit/static/static/js/{index.Dc5-tFdw.js → index.CtbETWQK.js} +1 -1
- streamlit/static/static/js/{index.CUkhn-vu.js → index.CvtybR-u.js} +1 -1
- streamlit/static/static/js/{index.BZ-GJVxB.js → index.CxoREvnF.js} +1 -1
- streamlit/static/static/js/{index.C6wyTXhz.js → index.D6OexhdL.js} +1 -1
- streamlit/static/static/js/{index.HmRK3HyC.js → index.D9v2Y8Gk.js} +1 -1
- streamlit/static/static/js/{index.8MlRyIxN.js → index.DAfIQKfP.js} +1 -1
- streamlit/static/static/js/index.DAnczAW2.js +2 -0
- streamlit/static/static/js/{index.TjMWsKSH.js → index.DAyGxxdm.js} +1 -1
- streamlit/static/static/js/{index.6c-qDsD7.js → index.DCe7fo-m.js} +1 -1
- streamlit/static/static/js/{index.CX0KdFyR.js → index.DNfyKqhQ.js} +1 -1
- streamlit/static/static/js/{index.DJfMW0Gy.js → index.DRoJNzFX.js} +1 -1
- streamlit/static/static/js/{index.DBPWUJsj.js → index.DU68jVpM.js} +54 -54
- streamlit/static/static/js/{index.BfMPq234.js → index.DZmBuE3z.js} +2 -2
- streamlit/static/static/js/{index.CYhhEdja.js → index.DhRAGiPR.js} +1 -1
- streamlit/static/static/js/{index.DlgcEr0f.js → index.DrcbvB2t.js} +1 -1
- streamlit/static/static/js/{index.DxGXuhh6.js → index.Dud7RRHc.js} +1 -1
- streamlit/static/static/js/{index.C2EoeVjP.js → index.DyXcT2tD.js} +1 -1
- streamlit/static/static/js/{index.Bgf49D1Z.js → index.DyfvmNCy.js} +222 -222
- streamlit/static/static/js/{index.CZf7Go1Z.js → index.GieKl4BG.js} +1 -1
- streamlit/static/static/js/{index.C65jHNhe.js → index.YULCxEtm.js} +1 -1
- streamlit/static/static/js/{index.DL_yE83J.js → index._1zqETQ9.js} +2 -2
- streamlit/static/static/js/{index.CwtpGPHA.js → index.bQJYmJ2T.js} +1 -1
- streamlit/static/static/js/{index.hlAfdSqC.js → index.iXh5nbLZ.js} +1 -1
- streamlit/static/static/js/index.mSdC1FV6.js +1 -0
- streamlit/static/static/js/{index.BIqcOZ_u.js → index.nL1fkE1D.js} +1 -1
- streamlit/static/static/js/{index.VwDKazgt.js → index.tuFFlbxa.js} +1 -1
- streamlit/static/static/js/{index.BzTVI_BY.js → index.y-pa6LIX.js} +1 -1
- streamlit/static/static/js/{input.CXGIJ7D6.js → input.BcC6sPE_.js} +1 -1
- streamlit/static/static/js/{main.CCVkbuxC.js → main.TU5_aabd.js} +1 -1
- streamlit/static/static/js/{memory.CNbnYs2A.js → memory.By_OTlI4.js} +1 -1
- streamlit/static/static/js/{number-overlay-editor.CvI6wkld.js → number-overlay-editor.FSRaRpbU.js} +1 -1
- streamlit/static/static/js/{pandasStylerUtils.CFSReOTm.js → pandasStylerUtils.3IiIKU9-.js} +1 -1
- streamlit/static/static/js/{sandbox.Bld0L3us.js → sandbox.DnxTbWzV.js} +1 -1
- streamlit/static/static/js/{styled-components.BoUHK6TA.js → styled-components.BeEcZ0vW.js} +1 -1
- streamlit/static/static/js/{throttle.ByDFm7WV.js → throttle.emUyC44c.js} +1 -1
- streamlit/static/static/js/{timepicker.CN6CUZEL.js → timepicker.DZ_ZufYF.js} +1 -1
- streamlit/static/static/js/{toConsumableArray.DwMycSpg.js → toConsumableArray.DDV1bN1-.js} +1 -1
- streamlit/static/static/js/uniqueId.DTwvAE-J.js +1 -0
- streamlit/static/static/js/{useBasicWidgetState.Bg0ZMUt5.js → useBasicWidgetState.DvpdEDYZ.js} +1 -1
- streamlit/static/static/js/{useIntlLocale.DgBUDcPA.js → useIntlLocale.BBDLbTq9.js} +1 -1
- streamlit/static/static/js/{useTextInputAutoExpand.DDBezxks.js → useTextInputAutoExpand.BIApLJKn.js} +1 -1
- streamlit/static/static/js/{useUpdateUiValue.Df1h6fXC.js → useUpdateUiValue.DQ4RuJNC.js} +1 -1
- streamlit/static/static/js/{useWaveformController.DbWw5MEk.js → useWaveformController.B0olyXLQ.js} +1 -1
- streamlit/static/static/js/{withCalculatedWidth.YaK0HIIP.js → withCalculatedWidth.DYeqePuh.js} +1 -1
- streamlit/static/static/js/{withFullScreenWrapper.CcWCKoY8.js → withFullScreenWrapper.DtkUCO_d.js} +1 -1
- streamlit/testing/v1/element_tree.py +16 -2
- streamlit/web/server/server.py +0 -1
- streamlit/web/server/starlette/starlette_app.py +0 -1
- {streamlit_nightly-1.53.2.dev20260128.dist-info → streamlit_nightly-1.53.2.dev20260131.dist-info}/METADATA +10 -25
- {streamlit_nightly-1.53.2.dev20260128.dist-info → streamlit_nightly-1.53.2.dev20260131.dist-info}/RECORD +209 -218
- streamlit/proto/DataFrame_pb2.py +0 -56
- streamlit/proto/DataFrame_pb2.pyi +0 -430
- streamlit/proto/NamedDataSet_pb2.py +0 -28
- streamlit/proto/NamedDataSet_pb2.pyi +0 -67
- streamlit/proto/PagesChanged_pb2.py +0 -28
- streamlit/proto/PagesChanged_pb2.pyi +0 -55
- streamlit/proto/VegaLiteChart_pb2.py +0 -29
- streamlit/proto/VegaLiteChart_pb2.pyi +0 -79
- streamlit/static/static/js/index.CSPY26T2.js +0 -1
- streamlit/static/static/js/index.CdsyTabv.js +0 -1
- streamlit/static/static/js/index.CjRU8O1O.js +0 -2
- streamlit/static/static/js/uniqueId.DcCWa2cf.js +0 -1
- streamlit_nightly-1.53.2.dev20260128.data/scripts/streamlit.cmd +0 -16
- {streamlit_nightly-1.53.2.dev20260128.dist-info → streamlit_nightly-1.53.2.dev20260131.dist-info}/WHEEL +0 -0
- {streamlit_nightly-1.53.2.dev20260128.dist-info → streamlit_nightly-1.53.2.dev20260131.dist-info}/entry_points.txt +0 -0
- {streamlit_nightly-1.53.2.dev20260128.dist-info → streamlit_nightly-1.53.2.dev20260131.dist-info}/top_level.txt +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as W,aA as O,z as _,r as i,k as $,l as q,a9 as S,aa as G,o as M,j as c,ab as N,ac as J,ae as Q}from"./index.
|
|
1
|
+
import{p as W,aA as O,z as _,r as i,k as $,l as q,a9 as S,aa as G,o as M,j as c,ab as N,ac as J,ae as Q}from"./index.CPc_uZux.js";import{I as X}from"./InputInstructions.CdzsN_Va.js";import{u as Y}from"./useBasicWidgetState.DvpdEDYZ.js";import{u as Z,a as tt,b as et}from"./useUpdateUiValue.DQ4RuJNC.js";import{u as ot,T as at}from"./useTextInputAutoExpand.BIApLJKn.js";import{u as it}from"./uniqueId.DTwvAE-J.js";import"./FormClearHelper.DTFnX0js.js";import"./inputUtils.CptNuJwn.js";import"./base-input.Q-zJLgRK.js";const st=(e,t)=>{let a="auto";if(e.heightConfig?.useStretch)a="100%";else if(e.heightConfig?.pixelHeight&&e.heightConfig.pixelHeight>0){const s=W(t.labelVisibility?.value)===O.Collapsed?2:30,l=e.heightConfig.pixelHeight-s;a=`${Math.max(0,l)}px`}return a},rt=_("div",{target:"e1tmb1p40"})({height:"100%",display:"flex",flexDirection:"column"}),T=(e,t)=>e.getStringValue(t)??t.default??null,lt=e=>e.default??null,nt=e=>e.value??null,ut=(e,t,a,s)=>{t.setStringValue(e,a.value,{fromUi:a.fromUi},s)},dt=({disabled:e,element:t,widgetMgr:a,fragmentId:s,outerElement:l})=>{const h=i.useRef(it("text_area_")).current,{width:y,elementRef:V}=$(),[r,g]=i.useState(!1),[I,x]=i.useState(!1),n=l.heightConfig?.useContent??!1,v=l.heightConfig?.useStretch??!1,A=st(l,t),C=i.useRef(null),[u,p]=i.useState(()=>T(a,t)??null),F=i.useCallback(()=>{p(t.default??null),g(!0)},[t]),[R,f]=Y({getStateFromWidgetMgr:T,getDefaultStateFromProto:lt,getCurrStateFromProto:nt,updateWidgetMgrState:ut,element:t,widgetMgr:a,fragmentId:s,onFormCleared:F});Z(R,u,p,r);const o=q(),{height:k,maxHeight:z,updateScrollHeight:H}=ot({textareaRef:C,dependencies:[t.placeholder]}),m=i.useCallback(()=>{g(!1),f({value:u,fromUi:!0})},[u,f]),L=i.useCallback(()=>{r&&m(),x(!1)},[r,m]),B=i.useCallback(()=>{x(!0)},[]),D=i.useCallback(()=>{n&&H()},[n,H]),E=tt({formId:t.formId,maxChars:t.maxChars,setDirty:g,setUiValue:p,setValueWithSource:f,additionalAction:D}),U=et(t.formId,m,r,a,s,!0),{placeholder:P,formId:b}=t,j=S({formId:b})?a.allowFormEnterToSubmit(b):r,w=I&&y>G(o.breakpoints.hideWidgetDetails);return M(rt,{className:"stTextArea","data-testid":"stTextArea",ref:V,children:[c(J,{label:t.label,disabled:e,labelVisibility:W(t.labelVisibility?.value),htmlFor:h,children:t.help&&c(N,{content:t.help,label:t.label})}),c(at,{inputRef:n?C:void 0,value:u??"",placeholder:P,onBlur:L,onFocus:B,onChange:E,onKeyDown:U,"aria-label":t.label,disabled:e,id:h,overrides:{Input:{style:{fontWeight:o.fontWeights.normal,lineHeight:o.lineHeights.inputWidget,height:n?k:A,maxHeight:n?z:"",minHeight:o.sizes.largestElementHeight,resize:v?"none":"vertical",paddingRight:o.spacing.md,paddingLeft:o.spacing.md,paddingBottom:o.spacing.md,paddingTop:o.spacing.md,"::placeholder":{color:o.colors.fadedText60}}},Root:{props:{"data-testid":"stTextAreaRootElement"},style:({$isFocused:K})=>{const d=Q(o.colors,K);return{borderLeftWidth:o.sizes.borderWidth,borderRightWidth:o.sizes.borderWidth,borderTopWidth:o.sizes.borderWidth,borderBottomWidth:o.sizes.borderWidth,borderTopColor:d,borderRightColor:d,borderBottomColor:d,borderLeftColor:d,flexGrow:1}}}}}),w&&c(X,{dirty:r,value:u??"",maxLength:t.maxChars,type:"multiline",inForm:S({formId:b}),allowEnterToSubmit:j})]})},Ht=i.memo(dt);export{Ht as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z as f,r as o,R as g,j as l,V as v}from"./index.
|
|
1
|
+
import{z as f,r as o,R as g,j as l,V as v}from"./index.CPc_uZux.js";const T=f("div",{target:"e1z085g90"})(()=>({lineHeight:0})),y=f("audio",{target:"e1z085g91"})(({theme:t})=>({width:"100%",height:t.sizes.minElementHeight,margin:0,padding:0})),h=v.getLogger("Audio");function L({element:t,endpoints:a,elementMgr:s}){const i=o.useRef(null),{startTime:n,endTime:d,loop:u,autoplay:p}=t,E=o.useMemo(()=>{if(!t.id)return!0;const e=s.getElementState(t.id,"preventAutoplay");return e||s.setElementState(t.id,"preventAutoplay",!0),e??!1},[t.id,s]);o.useEffect(()=>{i.current&&(i.current.currentTime=n)},[n]),o.useEffect(()=>{const e=i.current,r=()=>{e&&(e.currentTime=t.startTime)};return e&&e.addEventListener("loadedmetadata",r),()=>{e&&e.removeEventListener("loadedmetadata",r)}},[t]),o.useEffect(()=>{const e=i.current;if(!e)return;let r=!1;const c=()=>{d>0&&e.currentTime>=d&&(u?(e.currentTime=n||0,e.play()):r||(r=!0,e.pause()))};return d>0&&e.addEventListener("timeupdate",c),()=>{e&&d>0&&e.removeEventListener("timeupdate",c)}},[d,u,n]),o.useEffect(()=>{const e=i.current;if(!e)return;const r=()=>{u&&(e.currentTime=n||0,e.play())};return e.addEventListener("ended",r),()=>{e&&e.removeEventListener("ended",r)}},[u,n]);const m=g(t.url),A=a.buildMediaURL(t.url);return l(T,{children:l(y,{className:"stAudio","data-testid":"stAudio",ref:i,controls:!0,autoPlay:p&&!E,src:A,onError:e=>{const r=e.currentTarget.src;h.error(`Client Error: Audio source error - ${r}`),a.sendClientErrorToHost("Audio","Audio source failed to load","onerror triggered",r)},crossOrigin:m})})}const z=o.memo(L);export{z as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{z as g,r as W,W as w,o as h,j as a,R as L,q as C,V as E}from"./index.CPc_uZux.js";import{w as b,E as T}from"./withFullScreenWrapper.DtkUCO_d.js";import{S as p,T as v}from"./Toolbar.COH7NaOE.js";const F=g("div",{target:"e1xt4yf90"})(({theme:e,shouldStretch:t})=>({display:"flex",flexDirection:"row",flexWrap:"wrap",rowGap:e.spacing.lg,maxWidth:"100%",width:t?"100%":"fit-content"})),R=g("div",{target:"e1xt4yf91"})(({theme:e,shouldStretch:t})=>({display:"flex",flexDirection:"column",alignItems:"stretch",width:t?"100%":"auto",flexGrow:t?1:0,">img":{borderRadius:e.radii.default}})),j=g("div",{target:"e1xt4yf92"})(({theme:e})=>({textAlign:"center",marginTop:e.spacing.xs,wordWrap:"break-word",padding:e.spacing.threeXS})),H=E.getLogger("ImageList");function M(e,t){if(e){if(e.useStretch)return t;if(e.useContent)return;if(e.pixelWidth)return e.pixelWidth}}const G=({itemKey:e,image:t,imgStyle:i,buildMediaURL:l,handleImageError:s,shouldStretch:d})=>{const o=L(t.url);return h(R,{"data-testid":"stImageContainer",shouldStretch:d,children:[a("img",{style:i,src:l(t.url),alt:e,onError:s,crossOrigin:o}),t.caption&&a(j,{"data-testid":"stImageCaption",style:i,children:a(C,{source:t.caption,allowHTML:!1,isCaption:!0,isLabel:!0})})]})};function O({element:e,endpoints:t,widthConfig:i,disableFullscreenMode:l}){const{expanded:s,width:d,height:o,expand:x,collapse:f}=w(T),m=d||0,I=M(i,m),u=i?.useStretch??!1,r={};o&&s?(r.maxHeight=o,r.objectFit="contain",r.width="100%"):(r.width=I??"100%",r.maxWidth="100%");const S=c=>{const n=c.currentTarget.src;H.error(`Client Error: Image source error - ${n}`),t.sendClientErrorToHost("Image","Image source failed to load","onerror triggered",n)};return h(p,{width:m,height:o,useContainerWidth:s,topCentered:!0,children:[a(v,{target:p,isFullScreen:s,onExpand:x,onCollapse:f,disableFullscreenMode:l}),a(F,{className:"stImage","data-testid":"stImage",shouldStretch:u,children:e.imgs.map((c,n)=>a(G,{itemKey:n.toString(),image:c,imgStyle:r,buildMediaURL:y=>t.buildMediaURL(y),handleImageError:S,shouldStretch:u},n))})]})}const U=b(O),D=W.memo(U);export{D as default};
|