streamlit-nightly 1.39.1.dev20241022__py2.py3-none-any.whl → 1.39.1.dev20241025__py2.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.
Files changed (32) hide show
  1. streamlit/static/asset-manifest.json +15 -15
  2. streamlit/static/index.html +1 -1
  3. streamlit/static/static/css/{main.5513bd04.css → main.a1bc16b2.css} +1 -1
  4. streamlit/static/static/js/1260.f4b7cd39.chunk.js +5 -0
  5. streamlit/static/static/js/{3224.86a6ba35.chunk.js → 3224.a04b49ba.chunk.js} +1 -1
  6. streamlit/static/static/js/3560.22d06cb7.chunk.js +1 -0
  7. streamlit/static/static/js/5618.f51b795a.chunk.js +5 -0
  8. streamlit/static/static/js/6360.50be2ff5.chunk.js +1 -0
  9. streamlit/static/static/js/7193.534e7da1.chunk.js +1 -0
  10. streamlit/static/static/js/{8166.094f1288.chunk.js → 8166.1d69c908.chunk.js} +1 -1
  11. streamlit/static/static/js/9114.ee2dff18.chunk.js +1 -0
  12. streamlit/static/static/js/954.07ce4880.chunk.js +5 -0
  13. streamlit/static/static/js/{9943.54dc52f7.chunk.js → 9943.7e306ca1.chunk.js} +1 -1
  14. streamlit/static/static/js/9993.5b55b4c2.chunk.js +1 -0
  15. streamlit/static/static/js/main.d68f7490.js +28 -0
  16. streamlit/web/server/component_request_handler.py +1 -1
  17. {streamlit_nightly-1.39.1.dev20241022.dist-info → streamlit_nightly-1.39.1.dev20241025.dist-info}/METADATA +2 -2
  18. {streamlit_nightly-1.39.1.dev20241022.dist-info → streamlit_nightly-1.39.1.dev20241025.dist-info}/RECORD +23 -23
  19. streamlit/static/static/js/1260.dc193a5e.chunk.js +0 -5
  20. streamlit/static/static/js/3560.50f03f0f.chunk.js +0 -1
  21. streamlit/static/static/js/5618.2d933cb5.chunk.js +0 -5
  22. streamlit/static/static/js/6073.192808c1.chunk.js +0 -1
  23. streamlit/static/static/js/6360.172f2b06.chunk.js +0 -1
  24. streamlit/static/static/js/7193.629fc6fe.chunk.js +0 -1
  25. streamlit/static/static/js/9114.37a044b5.chunk.js +0 -1
  26. streamlit/static/static/js/954.88014372.chunk.js +0 -5
  27. streamlit/static/static/js/main.b154eb39.js +0 -28
  28. /streamlit/static/static/js/{main.b154eb39.js.LICENSE.txt → main.d68f7490.js.LICENSE.txt} +0 -0
  29. {streamlit_nightly-1.39.1.dev20241022.data → streamlit_nightly-1.39.1.dev20241025.data}/scripts/streamlit.cmd +0 -0
  30. {streamlit_nightly-1.39.1.dev20241022.dist-info → streamlit_nightly-1.39.1.dev20241025.dist-info}/WHEEL +0 -0
  31. {streamlit_nightly-1.39.1.dev20241022.dist-info → streamlit_nightly-1.39.1.dev20241025.dist-info}/entry_points.txt +0 -0
  32. {streamlit_nightly-1.39.1.dev20241022.dist-info → streamlit_nightly-1.39.1.dev20241025.dist-info}/top_level.txt +0 -0
@@ -51,7 +51,7 @@ class ComponentRequestHandler(tornado.web.RequestHandler):
51
51
  # follow symlinks to get an accurate normalized path
52
52
  component_root = os.path.realpath(component_root)
53
53
  filename = "/".join(parts[1:])
54
- abspath = os.path.realpath(os.path.join(component_root, filename))
54
+ abspath = os.path.normpath(os.path.join(component_root, filename))
55
55
 
56
56
  # Do NOT expose anything outside of the component root.
57
57
  if os.path.commonpath([component_root, abspath]) != component_root:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: streamlit-nightly
3
- Version: 1.39.1.dev20241022
3
+ Version: 1.39.1.dev20241025
4
4
  Summary: A faster way to build and share data apps
5
5
  Home-page: https://streamlit.io
6
6
  Author: Snowflake Inc
@@ -38,7 +38,7 @@ Requires-Dist: click<9,>=7.0
38
38
  Requires-Dist: numpy<3,>=1.20
39
39
  Requires-Dist: packaging<25,>=20
40
40
  Requires-Dist: pandas<3,>=1.4.0
41
- Requires-Dist: pillow<11,>=7.1.0
41
+ Requires-Dist: pillow<12,>=7.1.0
42
42
  Requires-Dist: protobuf<6,>=3.20
43
43
  Requires-Dist: pyarrow>=7.0
44
44
  Requires-Dist: requests<3,>=2.27
@@ -347,25 +347,25 @@ streamlit/runtime/state/safe_session_state.py,sha256=WLFFyMtP4F19TWWBarKtSP942Ie
347
347
  streamlit/runtime/state/session_state.py,sha256=SMBWsSZY29jAgL3QfX4xvJr9aLCNrHHUz9AmosX7FlQ,28850
348
348
  streamlit/runtime/state/session_state_proxy.py,sha256=IWF43f6UWL4KyxNWF3aTv1sbykNI2hI5UsPF2UIfpdE,5524
349
349
  streamlit/runtime/state/widgets.py,sha256=r5XOgHBh9AqS52rgKGgDXFGnkdY6ObUJBSSUBqkzTK8,5319
350
- streamlit/static/asset-manifest.json,sha256=URiYi5M5hj23DdUCS7tUfIsD4d0kW4b_1XRs4mxs2EY,14713
350
+ streamlit/static/asset-manifest.json,sha256=IHxOls20emAZKUxVrR41tVw9du0HY7NLzoYB2y1lJxY,14713
351
351
  streamlit/static/favicon.png,sha256=if5cVgw7azxKOvV5FpGixga7JLn23rfnHcy1CdWI1-E,1019
352
- streamlit/static/index.html,sha256=ME8A3Q87NoU1tOSoVmhutl5Bpq0_9R4ooqYamx5yRc0,891
352
+ streamlit/static/index.html,sha256=MP_f7ktjCFm9yQMYv4_63Lg9FQ9e-ThJzmm6zNmhu9k,891
353
353
  streamlit/static/static/css/4096.8b8f33d6.chunk.css,sha256=4m2lbj1eVFXSaGCRBHZNhqyRz-4Ce9KogjJPxIq6On8,33275
354
354
  streamlit/static/static/css/9943.d452238e.chunk.css,sha256=B69nSRvppH7uO-_kso_XSGce7SJOCm8ZD1GB9g6fttA,12038
355
- streamlit/static/static/css/main.5513bd04.css,sha256=9vuriEsFvHDyAwsI3vtBY9PNL8UOjqGwWZ4lZHsdFzw,29356
355
+ streamlit/static/static/css/main.a1bc16b2.css,sha256=mPtYM1NFajTb7mdT5xey2DzapUSnS_yMsUZN5TmJ4Lo,28563
356
356
  streamlit/static/static/js/1086.93ecee4c.chunk.js,sha256=zaPpGC_iUSZOCaJvaN_eQjjV8qEb70tqqpsRV15YaVY,11646
357
357
  streamlit/static/static/js/1101.13462bff.chunk.js,sha256=Iu-ECFDUDJJ14X1UQR4KIqtBHDhW60i15dbuEzx9HT4,3259
358
- streamlit/static/static/js/1260.dc193a5e.chunk.js,sha256=Xm4rj0pmMBuJ81DSUJY8RR4iqteyXF4OavQ6AegsqKk,10999
358
+ streamlit/static/static/js/1260.f4b7cd39.chunk.js,sha256=ExhFr4CY3x-oUPIC50CYyyB-V80iYoorBWNgIHoWrPs,10986
359
359
  streamlit/static/static/js/1674.86aea8e0.chunk.js,sha256=g2RyDOrwFlJImiNgHT8Yo_LVDjfqRV5DHDhXK_IYdQE,9236
360
360
  streamlit/static/static/js/1674.86aea8e0.chunk.js.LICENSE.txt,sha256=426lVBKMW2FKu5BqnSDpZnhms1QqJZ-nDvqwC62w-Z8,479
361
361
  streamlit/static/static/js/223.2359dae5.chunk.js,sha256=QSBOzn0nC-VViJW5bSdwAWp_7VI-_JgELrhMQdM-aEM,15452
362
362
  streamlit/static/static/js/245.f99a075b.chunk.js,sha256=Uh-JbxYM-u3OWNz4ic9QpO1-ctFk64sER5Y61FUIYwQ,16029
363
363
  streamlit/static/static/js/2627.2462a014.chunk.js,sha256=PdOFzDOJSqybqqZpNdX3C-QzWLq7SuVcMjhY--a7mJA,21253
364
- streamlit/static/static/js/3224.86a6ba35.chunk.js,sha256=Tq56fa46bDoZ739e5G5ubgTYBD0XMMYvOaqbcPiYEoc,15376
364
+ streamlit/static/static/js/3224.a04b49ba.chunk.js,sha256=0z1RX1ZDDy4egCCqcr6N5sbOFXnh-CxxuZ5qwL5yW1k,15373
365
365
  streamlit/static/static/js/3389.71902a75.chunk.js,sha256=rmAaytiYyUUn62JwB0cWuq8XlufugjELi3FkHfwri0Y,2263290
366
366
  streamlit/static/static/js/3391.7aba08a0.chunk.js,sha256=UwAjzqpjIayXO5WqVNvDCtg4KTmFpaOtpPSVLJYSTWA,2177
367
367
  streamlit/static/static/js/3471.de4b25a2.chunk.js,sha256=v46A9eVjvhxYsBZ6SFG6wRg94XAccGQn6xA3q7sIluE,2698
368
- streamlit/static/static/js/3560.50f03f0f.chunk.js,sha256=yNEq0TZS_hqWqxwEUzsb_QWX_qIQdFn852js9fcoo7M,24894
368
+ streamlit/static/static/js/3560.22d06cb7.chunk.js,sha256=9SGdXpZY8uaHJgtkErT65hGLHYKMdd1l8t75FW2mr0c,25096
369
369
  streamlit/static/static/js/3861.867f8617.chunk.js,sha256=IjitNZiIVxMbpBT7myMMeJRHwU3MYCTh6ONsM9Pg5Ow,3119
370
370
  streamlit/static/static/js/3966.e0686958.chunk.js,sha256=zf2wvStW2Hl8p1n7K6ZCZ28xFzRklujcMF1UCLaSbRA,14199
371
371
  streamlit/static/static/js/4096.178414b7.chunk.js,sha256=gr-bJc1eiWtgGcV6yR9TTInbYURHmmZMaeXsN1pBiEo,2270568
@@ -378,21 +378,20 @@ streamlit/static/static/js/4856.03868952.chunk.js,sha256=B7GmZSz0b5tjbfjSoZOxfZ_
378
378
  streamlit/static/static/js/4856.03868952.chunk.js.LICENSE.txt,sha256=MFVywCe4fCte7HrHaVpL-jnDWhe9ei9zkyRvRUXQU-4,212
379
379
  streamlit/static/static/js/4942.e4db7877.chunk.js,sha256=3ccntc6WQ6_-pCJFp4NZHE3QbPQ1TEaifagA-pMYnC4,107578
380
380
  streamlit/static/static/js/5281.5e3aa7c6.chunk.js,sha256=J1aL1Y3sBRZu3wW8lC0my6ZAYqaOqFmTYJI-_MH083s,15095
381
- streamlit/static/static/js/5618.2d933cb5.chunk.js,sha256=Vm_CF144hbwNelnloQW_1ijGTuJXQ1tt80fOETazT5o,11683
381
+ streamlit/static/static/js/5618.f51b795a.chunk.js,sha256=EI4TofyIhjET9XGTRs3MtRckhcOmuE6S98fdmgUblvQ,11699
382
382
  streamlit/static/static/js/5625.a2d9a416.chunk.js,sha256=9sWAVS-_qiXpq-76PMP7_KU4ojfSxXYmC91hF6OhDnE,11143
383
383
  streamlit/static/static/js/5764.5a55e5be.chunk.js,sha256=EXfo-JRIKlOsXU91rI9-4Nu1v-wZqsQF2GTHmSydOZk,32464
384
384
  streamlit/static/static/js/5828.f8572ba4.chunk.js,sha256=KrgzrwMJj70Ou4vPwvpeUEd-E7fKQUKUGK_y6wGkEf8,2272
385
385
  streamlit/static/static/js/583.61ac7fde.chunk.js,sha256=ZNm9WsrrmRUjAJPKbaBwKDxJeXYgp3Prip_YtHMU3Nc,3252
386
386
  streamlit/static/static/js/5849.e92568db.chunk.js,sha256=2ay_pWGuk6Y26KeBbfMGqGzOJWBCpuqN9Y3MGN8CPG0,22834
387
- streamlit/static/static/js/6073.192808c1.chunk.js,sha256=aFAGqEXyyLDqeR2G2rAkMhZQQEKpY643ew439AWBMFg,40343
388
387
  streamlit/static/static/js/6088.cf24e25c.chunk.js,sha256=7rVWAzP5oDH4aAJrS-YpRYeFTUIz_40aKJcgHhlxoqU,21141
389
388
  streamlit/static/static/js/6141.d2879825.chunk.js,sha256=1thDcPIyU3rnFInTd2gUU4O0XqpLVqANd1G4tbvESJE,1190
390
389
  streamlit/static/static/js/6198.956025ac.chunk.js,sha256=M8auCVk5IHkZg39jS43Ix7QyPAx87dv0MyXhEPkAlmc,3660955
391
390
  streamlit/static/static/js/6198.956025ac.chunk.js.LICENSE.txt,sha256=aKN36g4SjyJ9CsqUUElZzz2T54Y9-y_Dz53dBlV7Q1o,2011
392
- streamlit/static/static/js/6360.172f2b06.chunk.js,sha256=6Y_kW3BxpGGUNAvqsVOvQjdhJhpk_3OcfVVjc37r7os,5320
391
+ streamlit/static/static/js/6360.50be2ff5.chunk.js,sha256=C-JHtHoblP1piG5dTTEqQYTP7zkNmeE2TdnKP0u4cAU,5372
393
392
  streamlit/static/static/js/6679.265ca09c.chunk.js,sha256=WmwYRnLnqPjmlAXo6meukmcKzMalOQeUCU2spQpWrHw,13574
394
393
  streamlit/static/static/js/6817.6adfea98.chunk.js,sha256=a899OLftoHmnEOJ4LgrzJaPzCe-rwE0wKUNrF7xKpuM,13038
395
- streamlit/static/static/js/7193.629fc6fe.chunk.js,sha256=0U9FPXb1ou2YQQqVWTj3cFHYd0Kshdujqst3Ms9v86E,2666
394
+ streamlit/static/static/js/7193.534e7da1.chunk.js,sha256=1bt-QTiM9H36CjZqN14FV4nri3WXg2o-IL2ab6yk05w,2682
396
395
  streamlit/static/static/js/7591.b3928443.chunk.js,sha256=BIil7acYkoN0zKvMnK8JbuQr8yRGZfMVt1LJPHcDVrQ,21261
397
396
  streamlit/static/static/js/7591.b3928443.chunk.js.LICENSE.txt,sha256=u9LVDbKjZkI5agN4AH5SidNkG6wf-oCZfLzdGp8DDl4,188
398
397
  streamlit/static/static/js/766.e3700e32.chunk.js,sha256=VPlOlYxsQ-Nptf1M3pbEqYHbqHrexY9bLDQ0MgMmkjg,12213
@@ -402,7 +401,7 @@ streamlit/static/static/js/797.36f1bf7d.chunk.js,sha256=lBSxYn2yOvQ9qigWurVjQBSL
402
401
  streamlit/static/static/js/7983.15bb2017.chunk.js,sha256=wNR0QnXubELkrdJ1K1QKVltDS2q4yJ3NoQUZxO5FIDI,3358
403
402
  streamlit/static/static/js/8148.5521cded.chunk.js,sha256=gAXcXKai9Xz5WCnxIVs2HUTP1umSt83aaVvMhWTh_Xc,2138
404
403
  streamlit/static/static/js/8161.9b75f98a.chunk.js,sha256=vWAh7Nhi5kkx3Z330eIRlgh0B4FxgJjmRVaQNDDX_DU,3640
405
- streamlit/static/static/js/8166.094f1288.chunk.js,sha256=8p_DkKjBuOErd7-xxq4qUgbE_W4E2D5R05SDOLbM9Zk,2746
404
+ streamlit/static/static/js/8166.1d69c908.chunk.js,sha256=sHs1Q8Wlc3gstHgkavln6MDkuBuZicLljS3AoNO4rG4,2762
406
405
  streamlit/static/static/js/8237.9d947ccb.chunk.js,sha256=TE526Er4a-jV7Rz73wttJQ_1olUpy-j-L5OPiarrmf0,12856
407
406
  streamlit/static/static/js/84.414fa87b.chunk.js,sha256=sF7-dsOEXmnl7d-z2d0Fb7F8vyEWlUY2vEK7TQ5RK8k,622
408
407
  streamlit/static/static/js/8460.38082ffb.chunk.js,sha256=pE2ohKDObi3afqzShRhcHj4SMIHmSvnc8gtuSXS0AFU,14487
@@ -413,14 +412,15 @@ streamlit/static/static/js/8790.0b98f286.chunk.js,sha256=P5TzrizssOnsqzKQLw91uOl
413
412
  streamlit/static/static/js/8815.92ce1b4a.chunk.js,sha256=hnEln2tZDZUU2flQp4YeL7n9oFnNmyKi8yTGAqdPG4I,5905
414
413
  streamlit/static/static/js/9060.1ec8dc2b.chunk.js,sha256=4eqbVFB_JXytGM3AFtzGHk1fywaaNDZuEsVm1AgPW6Y,686
415
414
  streamlit/static/static/js/9077.721329d6.chunk.js,sha256=J3aE0FDe8moAWsvWCNJfgfqQAbf-VPxj3uIFbRIJw3E,65779
416
- streamlit/static/static/js/9114.37a044b5.chunk.js,sha256=r5njw5okKFhTTNMmGmURAn4XXB2MadtgCsfbTlgm3Qs,7279
415
+ streamlit/static/static/js/9114.ee2dff18.chunk.js,sha256=koKnNzSEt7mLbczifdo4dib3Zw3REEnFuKb5yau12Q0,7545
417
416
  streamlit/static/static/js/9464.7e9a3c0a.chunk.js,sha256=63Fg1-eQ1Sx7Hb6rqtQaTOJ7CTZ8GZdyl7aMZJ-NcI8,1350
418
417
  streamlit/static/static/js/9528.a58c0ad2.chunk.js,sha256=LCX8VwyKfm9gr9lIAvz5d-8GnrpaOX13WoZPdogplbk,1872
419
- streamlit/static/static/js/954.88014372.chunk.js,sha256=iM-oVcorvEnZJzzEem6IrtXG6U63FfXPupeoIxFK92U,8769
418
+ streamlit/static/static/js/954.07ce4880.chunk.js,sha256=E4zF-KsTfWSqRim6MOetITJgTNMs-Yype7yTE1EiB20,8868
420
419
  streamlit/static/static/js/9923.2bb9616f.chunk.js,sha256=EtTxhVpm_jY8E23uFAg-00WCnbvi1zXVRAky8JxbMaI,3579
421
- streamlit/static/static/js/9943.54dc52f7.chunk.js,sha256=__dBNdmwDa6eZ3IwppDYRvXWnBWfwKeRHCvHl6imidw,49465
422
- streamlit/static/static/js/main.b154eb39.js,sha256=1CPk86wbuU5z-A0VQTXSjUGFSJCbEWQU-hxUqEkDjdo,4481314
423
- streamlit/static/static/js/main.b154eb39.js.LICENSE.txt,sha256=vcwWCW5VNoALG8YyhU5k8oDUNAwYisMZfiZ8X1cvtWk,4730
420
+ streamlit/static/static/js/9943.7e306ca1.chunk.js,sha256=w-NyC9woEtTMnJB6umkDSguV9RSovOsNbivOkNBnFtU,49399
421
+ streamlit/static/static/js/9993.5b55b4c2.chunk.js,sha256=uJI1SGarpF5Lc12L6nzoWCAPNtWOYmW6m6pf4tt_RkI,40386
422
+ streamlit/static/static/js/main.d68f7490.js,sha256=8y4CXXssSee9FVS6_5S5yD4-bNkEAupT_-LQo2SFsSY,4481189
423
+ streamlit/static/static/js/main.d68f7490.js.LICENSE.txt,sha256=vcwWCW5VNoALG8YyhU5k8oDUNAwYisMZfiZ8X1cvtWk,4730
424
424
  streamlit/static/static/media/KaTeX_AMS-Regular.73ea273a72f4aca30ca5.woff2,sha256=DN04fJWQoan5eUVgAi27WWVKfYbxh6oMgUla1C06cwg,28076
425
425
  streamlit/static/static/media/KaTeX_AMS-Regular.853be92419a6c3766b9a.ttf,sha256=aFNIQLz90r_7bw6N60hoTdAefwTqKBMmdXevuQbeHRM,63632
426
426
  streamlit/static/static/media/KaTeX_AMS-Regular.d562e886c52f12660a41.woff,sha256=MNqR6EyJP4deJSaJ-uvcWQsocRReitx_mp1NvYzgslE,33516
@@ -534,7 +534,7 @@ streamlit/web/cli.py,sha256=a5d_KIyFsOI2bzE8pPcyVhIvbt5jlxT850RKfquyYuU,11268
534
534
  streamlit/web/server/__init__.py,sha256=w4TFcV0OjM5zx8ej7oThRIyB6gq3kqdt45XBk1zkRWo,1080
535
535
  streamlit/web/server/app_static_file_handler.py,sha256=HQwZXzv2LMv0Kuq9gQYfHCS7midNJWj5us7Dt1UOvUY,3110
536
536
  streamlit/web/server/browser_websocket_handler.py,sha256=rcOCOfzs1cgkipT-8drKBVdxMsJDwihRccaOea3KYqU,7950
537
- streamlit/web/server/component_request_handler.py,sha256=nHSuvJwHzOk91CHAT4BbUkt88-T2Osdun38Sx3Z-5XU,4415
537
+ streamlit/web/server/component_request_handler.py,sha256=nPgLavJe4Guk49YvlSkTc-wfJhY6EaJBd96UD6aMBqc,4415
538
538
  streamlit/web/server/media_file_handler.py,sha256=2KfzPnMN1RstMtI4fs0PD0vFiFrWMyKL0q7LfWJLYZ4,5270
539
539
  streamlit/web/server/routes.py,sha256=dylD7VM9cyd6znQew1cCGHdSJx1zJ-JSXLhqMzqmpjs,10263
540
540
  streamlit/web/server/server.py,sha256=OV1rZto9AmAOGllVoc4N25ZCPDSaERNJQOTKmrWwtZs,15398
@@ -542,9 +542,9 @@ streamlit/web/server/server_util.py,sha256=ioIHkXNlA_ujj2Q3isziM8r5glKxgK2JZRoCD
542
542
  streamlit/web/server/stats_request_handler.py,sha256=e144zIhzLTB1PN4CwTCxElCoWMuo9IsBEPex2exHCQ0,3641
543
543
  streamlit/web/server/upload_file_request_handler.py,sha256=ftyKpARrUjOpRcFETIXuoTyOG_mo-ToOw5NI0y_W4lE,5003
544
544
  streamlit/web/server/websocket_headers.py,sha256=uUxypj04ondEC4ocBiYCndX_N06Zwe1Mt690Vupe08Y,2232
545
- streamlit_nightly-1.39.1.dev20241022.data/scripts/streamlit.cmd,sha256=ZEYM3vBJSp-k7vwSJ3ba5NzEk9-qHdSeLvGYAAe1mMw,676
546
- streamlit_nightly-1.39.1.dev20241022.dist-info/METADATA,sha256=u1Z1lb78EmjfTEtP3ig_J9B_uQFv3sw_zoYUBE0jowk,8512
547
- streamlit_nightly-1.39.1.dev20241022.dist-info/WHEEL,sha256=TJ49d73sNs10F0aze1W_bTW2P_X7-F4YXOlBqoqA-jY,109
548
- streamlit_nightly-1.39.1.dev20241022.dist-info/entry_points.txt,sha256=uNJ4DwGNXEhOK0USwSNanjkYyR-Bk7eYQbJFDrWyOgY,53
549
- streamlit_nightly-1.39.1.dev20241022.dist-info/top_level.txt,sha256=V3FhKbm7G2LnR0s4SytavrjIPNIhvcsAGXfYHAwtQzw,10
550
- streamlit_nightly-1.39.1.dev20241022.dist-info/RECORD,,
545
+ streamlit_nightly-1.39.1.dev20241025.data/scripts/streamlit.cmd,sha256=ZEYM3vBJSp-k7vwSJ3ba5NzEk9-qHdSeLvGYAAe1mMw,676
546
+ streamlit_nightly-1.39.1.dev20241025.dist-info/METADATA,sha256=qzYyauUX4aAyjv5Iy50DsVX2Xtr5OVzcsRRA1HOygCE,8512
547
+ streamlit_nightly-1.39.1.dev20241025.dist-info/WHEEL,sha256=TJ49d73sNs10F0aze1W_bTW2P_X7-F4YXOlBqoqA-jY,109
548
+ streamlit_nightly-1.39.1.dev20241025.dist-info/entry_points.txt,sha256=uNJ4DwGNXEhOK0USwSNanjkYyR-Bk7eYQbJFDrWyOgY,53
549
+ streamlit_nightly-1.39.1.dev20241025.dist-info/top_level.txt,sha256=V3FhKbm7G2LnR0s4SytavrjIPNIhvcsAGXfYHAwtQzw,10
550
+ streamlit_nightly-1.39.1.dev20241025.dist-info/RECORD,,
@@ -1,5 +0,0 @@
1
- (self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[1260],{68035:(t,e,r)=>{"use strict";r.d(e,{A:()=>u});r(58878);var n=r(25571),o=r(78286),i=r(89653);const s=r(60667).i7`
2
- 50% {
3
- color: rgba(0, 0, 0, 0);
4
- }
5
- `,a=(0,i.A)("span",{target:"edlqvik0"})((t=>{let{includeDot:e,shouldBlink:r,theme:n}=t;return{...e?{"&::before":{opacity:1,content:'"\u2022"',animation:"none",color:n.colors.gray,margin:`0 ${n.spacing.twoXS}`}}:{},...r?{color:n.colors.red,animationName:`${s}`,animationDuration:"0.5s",animationIterationCount:5}:{}}}),"");var l=r(90782);const u=t=>{let{dirty:e,value:r,inForm:i,maxLength:s,className:u,type:c="single",allowEnterToSubmit:d=!0}=t;const p=[],h=function(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];p.push((0,l.jsx)(a,{includeDot:p.length>0,shouldBlink:e,children:t},p.length))};if(d){const t=i?"submit form":"apply";if("multiline"===c){h(`Press ${(0,n.u_)()?"\u2318":"Ctrl"}+Enter to ${t}`)}else"single"===c&&h(`Press Enter to ${t}`)}return s&&("chat"!==c||e)&&h(`${r.length}/${s}`,e&&r.length>=s),(0,l.jsx)(o.tp,{"data-testid":"InputInstructions",className:u,children:p})}},34752:(t,e,r)=>{"use strict";r.d(e,{X:()=>s,o:()=>i});var n=r(58878),o=r(25571);class i{constructor(){this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}manageFormClearListener(t,e,r){(0,o.se)(this.formClearListener)&&this.lastWidgetMgr===t&&this.lastFormId===e||(this.disconnect(),(0,o._L)(e)&&(this.formClearListener=t.addFormClearedListener(e,r),this.lastWidgetMgr=t,this.lastFormId=e))}disconnect(){var t;null===(t=this.formClearListener)||void 0===t||t.disconnect(),this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}}function s(t){let{element:e,widgetMgr:r,onFormCleared:i}=t;(0,n.useEffect)((()=>{if(!(0,o._L)(e.formId))return;const t=r.addFormClearedListener(e.formId,i);return()=>{t.disconnect()}}),[e,r,i])}},81260:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>v});var n=r(58878),o=r(32698),i=r.n(o),s=r(59095),a=r(8151),l=r(29669),u=r(34752),c=r(68035),d=r(70474),p=r(78286),h=r(93480),f=r(997),m=r(25571);const y=(0,r(89653).A)("div",{target:"e11y4ecf0"})((t=>{let{width:e}=t;return{position:"relative",width:e}}),"");var b=r(90782);class g extends n.PureComponent{constructor(t){var e;super(t),e=this,this.formClearHelper=new u.o,this.id=void 0,this.state={dirty:!1,focused:!1,value:this.initialValue},this.commitWidgetValue=function(t){let r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];const{widgetMgr:n,element:o,fragmentId:i}=e.props;n.setStringValue(o,e.state.value,t,i),r&&e.setState({dirty:!1})},this.onFormCleared=()=>{this.setState(((t,e)=>{var r;return{value:null!==(r=e.element.default)&&void 0!==r?r:null}}),(()=>this.commitWidgetValue({fromUi:!0})))},this.onBlur=()=>{this.state.dirty&&this.commitWidgetValue({fromUi:!0}),this.setState({focused:!1})},this.onFocus=()=>this.setState({focused:!0}),this.onChange=t=>{const{value:e}=t.target,{element:r}=this.props,{maxChars:n}=r;0!==n&&e.length>n||((0,m.Ml)(this.props.element)?this.setState({dirty:!0,value:e},(()=>{this.commitWidgetValue({fromUi:!0},!1)})):this.setState({dirty:!0,value:e}))},this.onKeyPress=t=>{const{element:e,widgetMgr:r,fragmentId:n}=this.props,{formId:o}=e,i=r.allowFormEnterToSubmit(o);"Enter"===t.key&&(this.state.dirty&&this.commitWidgetValue({fromUi:!0}),i&&r.submitForm(o,n))},this.id=i()("text_input_")}get initialValue(){var t;const e=this.props.widgetMgr.getStringValue(this.props.element);return null!==(t=null!==e&&void 0!==e?e:this.props.element.default)&&void 0!==t?t:null}componentDidMount(){this.props.element.setValue?this.updateFromProtobuf():this.commitWidgetValue({fromUi:!1})}componentDidUpdate(){this.maybeUpdateFromProtobuf()}componentWillUnmount(){this.formClearHelper.disconnect()}maybeUpdateFromProtobuf(){const{setValue:t}=this.props.element;t&&this.updateFromProtobuf()}updateFromProtobuf(){const{value:t}=this.props.element;this.props.element.setValue=!1,this.setState({value:null!==t&&void 0!==t?t:null},(()=>{this.commitWidgetValue({fromUi:!1})}))}getTypeString(){return this.props.element.type===l.ks.Type.PASSWORD?"password":"text"}render(){var t;const{dirty:e,focused:r,value:n}=this.state,{element:o,width:i,disabled:a,widgetMgr:l,theme:u}=this.props,{placeholder:g,formId:v}=o,w=(0,m.Ml)({formId:v})?l.allowFormEnterToSubmit(v):e,O=r&&i>u.breakpoints.hideWidgetDetails;return this.formClearHelper.manageFormClearListener(l,v,this.onFormCleared),(0,b.jsxs)(y,{className:"stTextInput","data-testid":"stTextInput",width:i,children:[(0,b.jsx)(d.L,{label:o.label,disabled:a,labelVisibility:(0,m.yv)(null===(t=o.labelVisibility)||void 0===t?void 0:t.value),htmlFor:this.id,children:o.help&&(0,b.jsx)(p.j,{children:(0,b.jsx)(h.A,{content:o.help,placement:f.W.TOP_RIGHT})})}),(0,b.jsx)(s.A,{value:null!==n&&void 0!==n?n:"",placeholder:g,onBlur:this.onBlur,onFocus:this.onFocus,onChange:this.onChange,onKeyPress:this.onKeyPress,"aria-label":o.label,disabled:a,id:this.id,type:this.getTypeString(),autoComplete:o.autocomplete,overrides:{Input:{style:{minWidth:0,"::placeholder":{opacity:"0.7"},lineHeight:u.lineHeights.inputWidget,paddingRight:u.spacing.sm,paddingLeft:u.spacing.sm,paddingBottom:u.spacing.sm,paddingTop:u.spacing.sm}},Root:{props:{"data-testid":"stTextInputRootElement"},style:{height:u.sizes.minElementHeight,borderLeftWidth:u.sizes.borderWidth,borderRightWidth:u.sizes.borderWidth,borderTopWidth:u.sizes.borderWidth,borderBottomWidth:u.sizes.borderWidth}}}}),O&&(0,b.jsx)(c.A,{dirty:e,value:null!==n&&void 0!==n?n:"",maxLength:o.maxChars,inForm:(0,m.Ml)({formId:v}),allowEnterToSubmit:w})]})}}const v=(0,a.b)(g)},59095:(t,e,r)=>{"use strict";r.d(e,{A:()=>E});var n=r(58878),o=r(35331),i=r(4842),s=r(18648),a=r(81301),l=r(92850);function u(t){return u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},u(t)}var c=["Root","StartEnhancer","EndEnhancer"],d=["startEnhancer","endEnhancer","overrides"];function p(){return p=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},p.apply(this,arguments)}function h(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null==r)return;var n,o,i=[],s=!0,a=!1;try{for(r=r.call(t);!(s=(n=r.next()).done)&&(i.push(n.value),!e||i.length!==e);s=!0);}catch(l){a=!0,o=l}finally{try{s||null==r.return||r.return()}finally{if(a)throw o}}return i}(t,e)||function(t,e){if(!t)return;if("string"===typeof t)return f(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return f(t,e)}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function m(t,e){if(null==t)return{};var r,n,o=function(t,e){if(null==t)return{};var r,n,o={},i=Object.keys(t);for(n=0;n<i.length;n++)r=i[n],e.indexOf(r)>=0||(o[r]=t[r]);return o}(t,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(n=0;n<i.length;n++)r=i[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(o[r]=t[r])}return o}function y(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function b(t,e){return b=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},b(t,e)}function g(t){var e=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function(){var r,n=w(t);if(e){var o=w(this).constructor;r=Reflect.construct(n,arguments,o)}else r=n.apply(this,arguments);return function(t,e){if(e&&("object"===u(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return v(t)}(this,r)}}function v(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function w(t){return w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},w(t)}function O(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var S=function(t){!function(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&b(t,e)}(w,t);var e,r,u,f=g(w);function w(){var t;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,w);for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];return O(v(t=f.call.apply(f,[this].concat(r))),"state",{isFocused:t.props.autoFocus||!1}),O(v(t),"onFocus",(function(e){t.setState({isFocused:!0}),t.props.onFocus(e)})),O(v(t),"onBlur",(function(e){t.setState({isFocused:!1}),t.props.onBlur(e)})),t}return e=w,(r=[{key:"render",value:function(){var t=this.props,e=t.startEnhancer,r=t.endEnhancer,u=t.overrides,f=u.Root,y=u.StartEnhancer,b=u.EndEnhancer,g=m(u,c),v=m(t,d),w=h((0,o._O)(f,a.bL),2),O=w[0],S=w[1],E=h((0,o._O)(y,a.P2),2),C=E[0],P=E[1],x=h((0,o._O)(b,a.P2),2),I=x[0],W=x[1],_=(0,i.e)(this.props,this.state);return n.createElement(O,p({"data-baseweb":"input"},_,S,{$adjoined:F(e,r),$hasIconTrailing:this.props.clearable||"password"==this.props.type}),j(e)&&n.createElement(C,p({},_,P,{$position:l.vN.start}),"function"===typeof e?e(_):e),n.createElement(s.A,p({},v,{overrides:g,adjoined:F(e,r),onFocus:this.onFocus,onBlur:this.onBlur})),j(r)&&n.createElement(I,p({},_,W,{$position:l.vN.end}),"function"===typeof r?r(_):r))}}])&&y(e.prototype,r),u&&y(e,u),Object.defineProperty(e,"prototype",{writable:!1}),w}(n.Component);function F(t,e){return j(t)&&j(e)?l.fb.both:j(t)?l.fb.left:j(e)?l.fb.right:l.fb.none}function j(t){return Boolean(t||0===t)}O(S,"defaultProps",{autoComplete:"on",autoFocus:!1,disabled:!1,name:"",onBlur:function(){},onFocus:function(){},overrides:{},required:!1,size:l.SK.default,startEnhancer:null,endEnhancer:null,clearable:!1,type:"text",readOnly:!1});const E=S},32698:(t,e,r)=>{var n=r(30136),o=0;t.exports=function(t){var e=++o;return n(t)+e}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[3560],{34752:(e,t,r)=>{r.d(t,{X:()=>l,o:()=>i});var o=r(58878),n=r(25571);class i{constructor(){this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}manageFormClearListener(e,t,r){(0,n.se)(this.formClearListener)&&this.lastWidgetMgr===e&&this.lastFormId===t||(this.disconnect(),(0,n._L)(t)&&(this.formClearListener=e.addFormClearedListener(t,r),this.lastWidgetMgr=e,this.lastFormId=t))}disconnect(){var e;null===(e=this.formClearListener)||void 0===e||e.disconnect(),this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}}function l(e){let{element:t,widgetMgr:r,onFormCleared:i}=e;(0,o.useEffect)((()=>{if(!(0,n._L)(t.formId))return;const e=r.addFormClearedListener(t.formId,i);return()=>{e.disconnect()}}),[t,r,i])}},33560:(e,t,r)=>{r.r(t),r.d(t,{default:()=>m});var o=r(58878),n=r(10783),i=r(38065),l=r(3680),a=r(8151),s=r(34752),d=r(70474),u=r(78286),c=r(93480),p=r(997),f=r(25571);const b=(0,r(89653).A)("div",{target:"e1ipygm10"})({name:"1ucqwki",styles:"position:absolute;top:50%;right:2.05em"});var y=r(90782);class g extends o.PureComponent{constructor(){super(...arguments),this.formClearHelper=new s.o,this.state={value:this.initialValue},this.commitWidgetValue=e=>{const{widgetMgr:t,element:r,fragmentId:o}=this.props;t.setStringValue(r,this.state.value,e,o)},this.onFormCleared=()=>{this.setState(((e,t)=>{var r;return{value:null!==(r=t.element.default)&&void 0!==r?r:null}}),(()=>this.commitWidgetValue({fromUi:!0})))},this.handleChange=e=>{let t;t=null===e?null:this.dateToString(e),this.setState({value:t},(()=>this.commitWidgetValue({fromUi:!0})))},this.stringToDate=e=>{if(null===e)return null;const[t,r]=e.split(":").map(Number),o=new Date;return o.setHours(t),o.setMinutes(r),o},this.dateToString=e=>`${e.getHours().toString().padStart(2,"0")}:${e.getMinutes().toString().padStart(2,"0")}`}get initialValue(){var e;const t=this.props.widgetMgr.getStringValue(this.props.element);return null!==(e=null!==t&&void 0!==t?t:this.props.element.default)&&void 0!==e?e:null}componentDidMount(){this.props.element.setValue?this.updateFromProtobuf():this.commitWidgetValue({fromUi:!1})}componentDidUpdate(){this.maybeUpdateFromProtobuf()}componentWillUnmount(){this.formClearHelper.disconnect()}maybeUpdateFromProtobuf(){const{setValue:e}=this.props.element;e&&this.updateFromProtobuf()}updateFromProtobuf(){const{value:e}=this.props.element;this.props.element.setValue=!1,this.setState({value:null!==e&&void 0!==e?e:null},(()=>{this.commitWidgetValue({fromUi:!1})}))}render(){var e;const{disabled:t,width:r,element:o,widgetMgr:a,theme:s}=this.props,g=(0,f.hX)(o.default)&&!t,m={width:r},h={Select:{props:{disabled:t,overrides:{ControlContainer:{style:{height:s.sizes.minElementHeight,borderLeftWidth:s.sizes.borderWidth,borderRightWidth:s.sizes.borderWidth,borderTopWidth:s.sizes.borderWidth,borderBottomWidth:s.sizes.borderWidth}},IconsContainer:{style:()=>({paddingRight:s.spacing.sm})},ValueContainer:{style:()=>({lineHeight:s.lineHeights.inputWidget,paddingRight:s.spacing.sm,paddingLeft:s.spacing.sm,paddingBottom:s.spacing.sm,paddingTop:s.spacing.sm})},SingleValue:{props:{"data-testid":"stTimeInputTimeDisplay"}},Dropdown:{style:()=>({paddingTop:s.spacing.none,paddingBottom:s.spacing.none})},Popover:{props:{overrides:{Body:{style:()=>({marginTop:s.spacing.px})}}}},SelectArrow:{component:l.A,props:{overrides:{Svg:{style:()=>({width:s.iconSizes.xl,height:s.iconSizes.xl})}}}}}}}};return this.formClearHelper.manageFormClearListener(a,o.formId,this.onFormCleared),(0,y.jsxs)("div",{className:"stTimeInput","data-testid":"stTimeInput",style:m,children:[(0,y.jsx)(d.L,{label:o.label,disabled:t,labelVisibility:(0,f.yv)(null===(e=o.labelVisibility)||void 0===e?void 0:e.value),children:o.help&&(0,y.jsx)(u.j,{children:(0,y.jsx)(c.A,{content:o.help,placement:p.W.TOP_RIGHT})})}),(0,y.jsx)(n.A,{format:"24",step:o.step?Number(o.step):900,value:(0,f.hX)(this.state.value)?void 0:this.stringToDate(this.state.value),onChange:this.handleChange,overrides:h,nullable:g,creatable:!0,"aria-label":o.label}),g&&!(0,f.hX)(this.state.value)&&(0,y.jsx)(b,{onClick:()=>{this.handleChange(null)},"data-testid":"stTimeInputClearButton",children:(0,y.jsx)(i.GZ,{overrides:{Svg:{style:{color:s.colors.darkGray,padding:s.spacing.threeXS,height:s.sizes.clearIconSize,width:s.sizes.clearIconSize,":hover":{fill:s.colors.bodyText}}}},$isFocusVisible:!1})})]})}}const m=(0,a.b)(g)},14051:(e,t,r)=>{r.r(t),r.d(t,{ThemeConsumer:()=>l,ThemeProvider:()=>o.A,createThemedStyled:()=>n.Fo,createThemedUseStyletron:()=>n.jT,createThemedWithStyle:()=>n.NN,expandBorderStyles:()=>i.d2,hexToRgb:()=>i.E2,styled:()=>n.I4,useStyletron:()=>n.c6,withStyle:()=>n._F,withWrapper:()=>n.K6});var o=r(93200),n=r(57224),i=r(76939),l=o.D.Consumer},91367:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getOverride=f,t.getOverrideProps=b,t.getOverrides=g,t.mergeConfigurationOverrides=h,t.mergeOverride=m,t.mergeOverrides=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=Object.assign({},e,t);return Object.keys(r).reduce((function(r,o){return r[o]=m(y(e[o]),y(t[o])),r}),{})},t.toObjectOverride=y,t.useOverrides=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return n.useMemo((function(){return Object.keys(e).reduce((function(r,o){return r[o]=g(t[o],e[o]),r}),{})}),[t])};var o,n=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==p(e)&&"function"!==typeof e)return{default:e};var r=a(t);if(r&&r.has(e))return r.get(e);var o={},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var l=n?Object.getOwnPropertyDescriptor(e,i):null;l&&(l.get||l.set)?Object.defineProperty(o,i,l):o[i]=e[i]}o.default=e,r&&r.set(e,o);return o}(r(58878)),i=r(64157),l=(o=r(48095))&&o.__esModule?o:{default:o};function a(e){if("function"!==typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(a=function(e){return e?r:t})(e)}function s(){return s=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},s.apply(this,arguments)}function d(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?d(Object(r),!0).forEach((function(t){c(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):d(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function c(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function p(e){return p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},p(e)}function f(e){return(0,i.isValidElementType)(e)?e:e&&"object"===p(e)?e.component:e}function b(e){return e&&"object"===p(e)?"object"===p(e.props)?u(u({},e.props),{},{$style:e.style}):{$style:e.style}:{}}function y(e){return(0,i.isValidElementType)(e)?{component:e}:e||{}}function g(e,t){var r=f(e)||t;if(e&&"object"===p(e)&&"function"===typeof e.props){0;var o=n.forwardRef((function(t,o){var i=e.props(t),l=b(u(u({},e),{},{props:i}));return n.createElement(r,s({ref:o},l))}));return o.displayName=r.displayName,[o,{}]}var i=b(e);return[r,i]}function m(e,t){var r=u(u({},e),t);return e.props&&t.props&&(r.props=h(e.props,t.props)),e.style&&t.style&&(r.style=h(e.style,t.style)),r}function h(e,t){return"object"===p(e)&&"object"===p(t)?(0,l.default)({},e,t):function(){return(0,l.default)({},"function"===typeof e?e.apply(void 0,arguments):e,"function"===typeof t?t.apply(void 0,arguments):t)}}},311:(e,t,r)=>{function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==o(e)&&"function"!==typeof e)return{default:e};var r=u(t);if(r&&r.has(e))return r.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if("default"!==l&&Object.prototype.hasOwnProperty.call(e,l)){var a=i?Object.getOwnPropertyDescriptor(e,l):null;a&&(a.get||a.set)?Object.defineProperty(n,l,a):n[l]=e[l]}n.default=e,r&&r.set(e,n);return n}(r(58878)),l=r(14051),a=r(91367),s=(n=r(71123))&&n.__esModule?n:{default:n},d=["title","size","color","overrides"];function u(e){if("function"!==typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(u=function(e){return e?r:t})(e)}function c(){return c=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},c.apply(this,arguments)}function p(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function f(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==r)return;var o,n,i=[],l=!0,a=!1;try{for(r=r.call(e);!(l=(o=r.next()).done)&&(i.push(o.value),!t||i.length!==t);l=!0);}catch(s){a=!0,n=s}finally{try{l||null==r.return||r.return()}finally{if(a)throw n}}return i}(e,t)||function(e,t){if(!e)return;if("string"===typeof e)return b(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return b(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function b(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=new Array(t);r<t;r++)o[r]=e[r];return o}function y(e,t){var r=f((0,l.useStyletron)(),2)[1],o=e.title,n=void 0===o?"Delete Alt":o,u=e.size,b=e.color,y=e.overrides,g=void 0===y?{}:y,m=p(e,d),h=(0,a.mergeOverride)({component:r.icons&&r.icons.DeleteAlt?r.icons.DeleteAlt:null},g&&g.Svg?(0,a.toObjectOverride)(g.Svg):{});return i.createElement(s.default,c({viewBox:"0 0 24 24",ref:t,title:n,size:u,color:b,overrides:{Svg:h}},m),i.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 20C16.4183 20 20 16.4183 20 12C20 7.58173 16.4183 4 12 4C7.58173 4 4 7.58173 4 12C4 16.4183 7.58173 20 12 20ZM10.0303 8.96967C9.73743 8.67679 9.26257 8.67679 8.96967 8.96967C8.67676 9.26257 8.67676 9.73743 8.96967 10.0303L10.9393 12L8.96967 13.9697C8.67676 14.2626 8.67676 14.7374 8.96967 15.0303C9.26257 15.3232 9.73743 15.3232 10.0303 15.0303L12 13.0607L13.9697 15.0303C14.2626 15.3232 14.7374 15.3232 15.0303 15.0303C15.3232 14.7374 15.3232 14.2626 15.0303 13.9697L13.0607 12L15.0303 10.0303C15.3232 9.73743 15.3232 9.26257 15.0303 8.96967C14.7374 8.67679 14.2626 8.67679 13.9697 8.96967L12 10.9393L10.0303 8.96967Z"}))}var g=i.forwardRef(y);t.default=g},71123:(e,t,r)=>{function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,i=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==o(e)&&"function"!==typeof e)return{default:e};var r=u(t);if(r&&r.has(e))return r.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if("default"!==l&&Object.prototype.hasOwnProperty.call(e,l)){var a=i?Object.getOwnPropertyDescriptor(e,l):null;a&&(a.get||a.set)?Object.defineProperty(n,l,a):n[l]=e[l]}n.default=e,r&&r.set(e,n);return n}(r(58878)),l=r(91367),a=r(20658),s=(n=r(5087))&&n.__esModule?n:{default:n},d=["children","title","size","color","overrides"];function u(e){if("function"!==typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(u=function(e){return e?r:t})(e)}function c(){return c=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},c.apply(this,arguments)}function p(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?p(Object(r),!0).forEach((function(t){b(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):p(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function b(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==r)return;var o,n,i=[],l=!0,a=!1;try{for(r=r.call(e);!(l=(o=r.next()).done)&&(i.push(o.value),!t||i.length!==t);l=!0);}catch(s){a=!0,n=s}finally{try{l||null==r.return||r.return()}finally{if(a)throw n}}return i}(e,t)||function(e,t){if(!e)return;if("string"===typeof e)return g(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return g(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function g(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,o=new Array(t);r<t;r++)o[r]=e[r];return o}function m(e,t){if(null==e)return{};var r,o,n=function(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}var h=function(e,t){var r=e.children,o=e.title,n=e.size,u=e.color,p=e.overrides,b=void 0===p?{}:p,g=m(e,d),h=y((0,l.getOverrides)(b.Svg,a.Svg),2),v=h[0],O=h[1],S=v.__STYLETRON__?f(f({title:o,$color:u,$size:n},g),O):f(f({title:o,color:u,size:n},(0,s.default)(g)),(0,s.default)(O));return i.createElement(v,c({"data-baseweb":"icon",ref:t},S),o?i.createElement("title",null,o):null,r)},v=i.forwardRef(h);t.default=v},5087:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t={};for(var r in e)"$"!==r[0]&&(t[r]=e[r]);return t}},20658:(e,t,r)=>{function o(e){var t=e.$theme,r=e.$size,o=e.$color,n=t.sizing.scale600;r&&(n=t.sizing[r]?t.sizing[r]:"number"===typeof r?"".concat(r,"px"):r);var i="currentColor";return o&&(i=t.colors[o]?t.colors[o]:o),{display:"inline-block",fill:i,color:i,height:n,width:n}}Object.defineProperty(t,"__esModule",{value:!0}),t.Svg=void 0,t.getSvgStyles=o;var n=(0,r(14051).styled)("svg",o);t.Svg=n,n.displayName="Svg",n.displayName="Svg"},96902:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.STATE_CHANGE_TYPE=t.SIZE=t.ENHANCER_POSITION=t.CUSTOM_INPUT_TYPE=t.ADJOINED=void 0;t.STATE_CHANGE_TYPE={change:"change"};t.CUSTOM_INPUT_TYPE={textarea:"textarea"};t.ADJOINED={none:"none",left:"left",right:"right",both:"both"};t.SIZE={mini:"mini",default:"default",compact:"compact",large:"large"};t.ENHANCER_POSITION={start:"start",end:"end"}},38065:(e,t,r)=>{t.GZ=void 0;var o,n=r(14051),i=r(96902),l=(o=r(311))&&o.__esModule?o:{default:o};function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var u=(0,n.styled)("button",(function(e){var t,r=e.$theme,o=e.$size,n=e.$isFocusVisible,l=(t={},d(t,i.SIZE.mini,r.sizing.scale400),d(t,i.SIZE.compact,r.sizing.scale400),d(t,i.SIZE.default,r.sizing.scale300),d(t,i.SIZE.large,r.sizing.scale200),t)[o];return{display:"flex",alignItems:"center",borderTopStyle:"none",borderBottomStyle:"none",borderLeftStyle:"none",borderRightStyle:"none",background:"none",paddingLeft:l,paddingRight:l,outline:n?"solid 3px ".concat(r.colors.accent):"none",color:r.colors.contentPrimary}}));u.displayName="StyledMaskToggleButton",u.displayName="StyledMaskToggleButton";var c=(0,n.styled)("div",(function(e){var t,r=e.$alignTop,o=void 0!==r&&r,n=e.$size,l=e.$theme,a=(t={},d(t,i.SIZE.mini,l.sizing.scale200),d(t,i.SIZE.compact,l.sizing.scale200),d(t,i.SIZE.default,l.sizing.scale100),d(t,i.SIZE.large,l.sizing.scale0),t)[n];return{display:"flex",alignItems:o?"flex-start":"center",paddingLeft:a,paddingRight:a,paddingTop:o?l.sizing.scale500:"0px",color:l.colors.contentPrimary}}));c.displayName="StyledClearIconContainer",c.displayName="StyledClearIconContainer";var p=(0,n.styled)(l.default,(function(e){var t=e.$theme;return{cursor:"pointer",outline:e.$isFocusVisible?"solid 3px ".concat(t.colors.accent):"none"}}));function f(e,t){var r;return(r={},d(r,i.SIZE.mini,t.font100),d(r,i.SIZE.compact,t.font200),d(r,i.SIZE.default,t.font300),d(r,i.SIZE.large,t.font400),r)[e]}t.GZ=p,p.displayName="StyledClearIcon",p.displayName="StyledClearIcon";var b=function(e){var t=e.$isFocused,r=e.$adjoined,o=e.$error,n=e.$disabled,l=e.$positive,a=e.$size,d=e.$theme,u=e.$theme,c=u.borders,p=u.colors,b=u.sizing,y=u.typography,g=u.animation,m=e.$hasIconTrailing;return s(s(s(s({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:g.timing200,transitionTimingFunction:g.easeOutCurve},function(e,t){var r=t.inputBorderRadius;return e===i.SIZE.mini&&(r=t.inputBorderRadiusMini),{borderTopLeftRadius:r,borderBottomLeftRadius:r,borderTopRightRadius:r,borderBottomRightRadius:r}}(a,c)),f(a,y)),function(e,t,r){var o=arguments.length>3&&void 0!==arguments[3]&&arguments[3],n=arguments.length>4?arguments[4]:void 0;return e?{borderLeftColor:n.inputFillDisabled,borderRightColor:n.inputFillDisabled,borderTopColor:n.inputFillDisabled,borderBottomColor:n.inputFillDisabled,backgroundColor:n.inputFillDisabled}:t?{borderLeftColor:n.borderSelected,borderRightColor:n.borderSelected,borderTopColor:n.borderSelected,borderBottomColor:n.borderSelected,backgroundColor:n.inputFillActive}:r?{borderLeftColor:n.inputBorderError,borderRightColor:n.inputBorderError,borderTopColor:n.inputBorderError,borderBottomColor:n.inputBorderError,backgroundColor:n.inputFillError}:o?{borderLeftColor:n.inputBorderPositive,borderRightColor:n.inputBorderPositive,borderTopColor:n.inputBorderPositive,borderBottomColor:n.inputBorderPositive,backgroundColor:n.inputFillPositive}:{borderLeftColor:n.inputBorder,borderRightColor:n.inputBorder,borderTopColor:n.inputBorder,borderBottomColor:n.inputBorder,backgroundColor:n.inputFill}}(n,t,o,l,p)),function(e,t,r,o,n){var l=e===i.ADJOINED.both||e===i.ADJOINED.left&&"rtl"!==o||e===i.ADJOINED.right&&"rtl"===o||n&&"rtl"===o,a=e===i.ADJOINED.both||e===i.ADJOINED.right&&"rtl"!==o||e===i.ADJOINED.left&&"rtl"===o||n&&"rtl"!==o;return{paddingLeft:l?r.scale550:"0px",paddingRight:a?r.scale550:"0px"}}(r,0,b,d.direction,m))};var y=(0,n.styled)("div",b);y.displayName="Root",y.displayName="Root";var g=(0,n.styled)("div",(function(e){var t=e.$size,r=e.$disabled,o=e.$isFocused,n=e.$error,l=e.$positive,a=e.$theme,u=a.colors,c=a.sizing,p=a.typography,b=a.animation;return s(s(s({display:"flex",alignItems:"center",justifyContent:"center",transitionProperty:"color, background-color",transitionDuration:b.timing200,transitionTimingFunction:b.easeOutCurve},f(t,p)),function(e,t){var r;return(r={},d(r,i.SIZE.mini,{paddingRight:t.scale400,paddingLeft:t.scale400}),d(r,i.SIZE.compact,{paddingRight:t.scale400,paddingLeft:t.scale400}),d(r,i.SIZE.default,{paddingRight:t.scale300,paddingLeft:t.scale300}),d(r,i.SIZE.large,{paddingRight:t.scale200,paddingLeft:t.scale200}),r)[e]}(t,c)),function(e,t,r,o,n){return e?{color:n.inputEnhancerTextDisabled,backgroundColor:n.inputFillDisabled}:t?{color:n.contentPrimary,backgroundColor:n.inputFillActive}:r?{color:n.contentPrimary,backgroundColor:n.inputFillError}:o?{color:n.contentPrimary,backgroundColor:n.inputFillPositive}:{color:n.contentPrimary,backgroundColor:n.inputFill}}(r,o,n,l,u))}));g.displayName="InputEnhancer",g.displayName="InputEnhancer";var m=function(e){var t=e.$isFocused,r=e.$error,o=e.$disabled,n=e.$positive,i=e.$size,l=e.$theme,a=l.colors,d=l.typography,u=l.animation;return s(s({display:"flex",width:"100%",transitionProperty:"background-color",transitionDuration:u.timing200,transitionTimingFunction:u.easeOutCurve},f(i,d)),function(e,t,r,o,n){return e?{color:n.inputTextDisabled,backgroundColor:n.inputFillDisabled}:t?{color:n.contentPrimary,backgroundColor:n.inputFillActive}:r?{color:n.contentPrimary,backgroundColor:n.inputFillError}:o?{color:n.contentPrimary,backgroundColor:n.inputFillPositive}:{color:n.contentPrimary,backgroundColor:n.inputFill}}(o,t,r,n,a))};var h=(0,n.styled)("div",m);h.displayName="InputContainer",h.displayName="InputContainer";var v=function(e){var t=e.$disabled,r=(e.$isFocused,e.$error,e.$size),o=e.$theme,n=o.colors,l=o.sizing;return s(s(s({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:t?"not-allowed":"text",margin:"0",paddingTop:"0",paddingBottom:"0",paddingLeft:"0",paddingRight:"0"},f(r,o.typography)),function(e,t){var r;return(r={},d(r,i.SIZE.mini,{paddingTop:t.scale100,paddingBottom:t.scale100,paddingLeft:t.scale550,paddingRight:t.scale550}),d(r,i.SIZE.compact,{paddingTop:t.scale200,paddingBottom:t.scale200,paddingLeft:t.scale550,paddingRight:t.scale550}),d(r,i.SIZE.default,{paddingTop:t.scale400,paddingBottom:t.scale400,paddingLeft:t.scale550,paddingRight:t.scale550}),d(r,i.SIZE.large,{paddingTop:t.scale550,paddingBottom:t.scale550,paddingLeft:t.scale550,paddingRight:t.scale550}),r)[e]}(r,l)),function(e,t,r,o){return e?{color:o.inputTextDisabled,"-webkit-text-fill-color":o.inputTextDisabled,caretColor:o.contentPrimary,"::placeholder":{color:o.inputPlaceholderDisabled}}:{color:o.contentPrimary,caretColor:o.contentPrimary,"::placeholder":{color:o.inputPlaceholder}}}(t,0,0,n))};var O=(0,n.styled)("input",v);O.displayName="Input",O.displayName="Input"},48095:(e,t)=>{function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function o(e){return Array.isArray(e)||"[object Object]"=={}.toString.call(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){t=t||{};for(var n,i,l=arguments.length<=1?0:arguments.length-1,a=0;a<l;a++)for(var s in n=(a+1<1||arguments.length<=a+1?void 0:arguments[a+1])||{})void 0!==r(n[s])&&(o(i=n[s])?t[s]=e(t[s]||Array.isArray(i)&&[]||{},i):t[s]=i);return t}}}]);
@@ -1,5 +0,0 @@
1
- (self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[5618],{68035:(e,t,r)=>{"use strict";r.d(t,{A:()=>u});r(58878);var n=r(25571),o=r(78286),i=r(89653);const a=r(60667).i7`
2
- 50% {
3
- color: rgba(0, 0, 0, 0);
4
- }
5
- `,l=(0,i.A)("span",{target:"edlqvik0"})((e=>{let{includeDot:t,shouldBlink:r,theme:n}=e;return{...t?{"&::before":{opacity:1,content:'"\u2022"',animation:"none",color:n.colors.gray,margin:`0 ${n.spacing.twoXS}`}}:{},...r?{color:n.colors.red,animationName:`${a}`,animationDuration:"0.5s",animationIterationCount:5}:{}}}),"");var s=r(90782);const u=e=>{let{dirty:t,value:r,inForm:i,maxLength:a,className:u,type:c="single",allowEnterToSubmit:d=!0}=e;const f=[],p=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];f.push((0,s.jsx)(l,{includeDot:f.length>0,shouldBlink:t,children:e},f.length))};if(d){const e=i?"submit form":"apply";if("multiline"===c){p(`Press ${(0,n.u_)()?"\u2318":"Ctrl"}+Enter to ${e}`)}else"single"===c&&p(`Press Enter to ${e}`)}return a&&("chat"!==c||t)&&p(`${r.length}/${a}`,t&&r.length>=a),(0,s.jsx)(o.tp,{"data-testid":"InputInstructions",className:u,children:f})}},34752:(e,t,r)=>{"use strict";r.d(t,{X:()=>a,o:()=>i});var n=r(58878),o=r(25571);class i{constructor(){this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}manageFormClearListener(e,t,r){(0,o.se)(this.formClearListener)&&this.lastWidgetMgr===e&&this.lastFormId===t||(this.disconnect(),(0,o._L)(t)&&(this.formClearListener=e.addFormClearedListener(t,r),this.lastWidgetMgr=e,this.lastFormId=t))}disconnect(){var e;null===(e=this.formClearListener)||void 0===e||e.disconnect(),this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}}function a(e){let{element:t,widgetMgr:r,onFormCleared:i}=e;(0,n.useEffect)((()=>{if(!(0,o._L)(t.formId))return;const e=r.addFormClearedListener(t.formId,i);return()=>{e.disconnect()}}),[t,r,i])}},25618:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>S});var n=r(58878),o=r(94928),i=r(8151),a=r(32698),l=r.n(a),s=r(68035),u=r(70474),c=r(78286),d=r(93480),f=r(997),p=r(25571),m=r(3101),g=r(90782);const h=(e,t)=>{var r,n;return null!==(r=null!==(n=e.getStringValue(t))&&void 0!==n?n:t.default)&&void 0!==r?r:null},y=e=>{var t;return null!==(t=e.default)&&void 0!==t?t:null},b=e=>{var t;return null!==(t=e.value)&&void 0!==t?t:null},v=(e,t,r,n)=>{t.setStringValue(e,r.value,{fromUi:r.fromUi},n)},S=e=>{var t,r;let{disabled:a,element:S,widgetMgr:w,fragmentId:O,width:C}=e;const F=(0,n.useRef)(l()("text_area_")).current,[j,x]=(0,n.useState)(null!==(t=h(w,S))&&void 0!==t?t:null),[I,P]=(0,n.useState)(!1),[E,T]=(0,n.useState)(!1),W=(0,n.useCallback)((()=>{var e;x(null!==(e=S.default)&&void 0!==e?e:null),P(!0)}),[S]),[,M]=(0,m.t)({getStateFromWidgetMgr:h,getDefaultStateFromProto:y,getCurrStateFromProto:b,updateWidgetMgrState:v,element:S,widgetMgr:w,fragmentId:O,onFormCleared:W}),k=(0,i.u)(),$=(0,n.useCallback)((e=>{let{fromUi:t}=e;M({value:j,fromUi:t}),P(!1)}),[j,M]),_=(0,n.useCallback)((()=>{I&&$({fromUi:!0}),T(!1)}),[I,$]),A=(0,n.useCallback)((()=>{T(!0)}),[]),D=(0,n.useCallback)((e=>{const{value:t}=e.target,{maxChars:r}=S;0!==r&&t.length>r||(x(t),P(!0))}),[S]),R=(0,n.useCallback)((e=>{const{metaKey:t,ctrlKey:r}=e,{formId:n}=S,o=w.allowFormEnterToSubmit(n);(e=>{var t;const{keyCode:r,key:n}=e;return("Enter"===n||13===r||10===r)&&!(!0===(null===(t=e.nativeEvent)||void 0===t?void 0:t.isComposing))})(e)&&(r||t)&&I&&(e.preventDefault(),$({fromUi:!0}),o&&w.submitForm(n,O))}),[S,w,I,$,O]),L={width:C},{height:z,placeholder:B,formId:U}=S,N=(0,p.Ml)({formId:U})?w.allowFormEnterToSubmit(U):I,K=E&&C>k.breakpoints.hideWidgetDetails;return(0,g.jsxs)("div",{className:"stTextArea","data-testid":"stTextArea",style:L,children:[(0,g.jsx)(u.L,{label:S.label,disabled:a,labelVisibility:(0,p.yv)(null===(r=S.labelVisibility)||void 0===r?void 0:r.value),htmlFor:F,children:S.help&&(0,g.jsx)(c.j,{children:(0,g.jsx)(d.A,{content:S.help,placement:f.W.TOP_RIGHT})})}),(0,g.jsx)(o.A,{value:null!==j&&void 0!==j?j:"",placeholder:B,onBlur:_,onFocus:A,onChange:D,onKeyDown:R,"aria-label":S.label,disabled:a,id:F,overrides:{Input:{style:{lineHeight:k.lineHeights.inputWidget,height:z?`${z}px`:"",minHeight:k.sizes.largestElementHeight,resize:"vertical","::placeholder":{opacity:"0.7"},paddingRight:k.spacing.lg,paddingLeft:k.spacing.lg,paddingBottom:k.spacing.lg,paddingTop:k.spacing.lg}},Root:{props:{"data-testid":"stTextAreaRootElement"},style:{borderLeftWidth:k.sizes.borderWidth,borderRightWidth:k.sizes.borderWidth,borderTopWidth:k.sizes.borderWidth,borderBottomWidth:k.sizes.borderWidth}}}}),K&&(0,g.jsx)(s.A,{dirty:I,value:null!==j&&void 0!==j?j:"",maxLength:S.maxChars,type:"multiline",inForm:(0,p.Ml)({formId:U}),allowEnterToSubmit:N})]})}},3101:(e,t,r)=>{"use strict";r.d(t,{_:()=>a,t:()=>l});var n=r(58878),o=r(34752),i=r(25571);function a(e){let{getStateFromWidgetMgr:t,getDefaultState:r,updateWidgetMgrState:a,element:l,widgetMgr:s,fragmentId:u,onFormCleared:c}=e;const[d,f]=(0,n.useState)((()=>{var e;return null!==(e=t(s,l))&&void 0!==e?e:r(s,l)})),[p,m]=(0,n.useState)({value:d,fromUi:!1});(0,n.useEffect)((()=>{(0,i.hX)(p)||(m(null),f(p.value),a(l,s,p,u))}),[p,a,l,s,u]);const g=(0,n.useCallback)((()=>{m({value:r(s,l),fromUi:!0}),null===c||void 0===c||c()}),[m,l,r,s,c]);return(0,o.X)({widgetMgr:s,element:l,onFormCleared:g}),[d,m]}function l(e){let{getStateFromWidgetMgr:t,getDefaultStateFromProto:r,getCurrStateFromProto:o,updateWidgetMgrState:i,element:l,widgetMgr:s,fragmentId:u,onFormCleared:c}=e;const d=(0,n.useCallback)(((e,t)=>r(t)),[r]),[f,p]=a({getStateFromWidgetMgr:t,getDefaultState:d,updateWidgetMgrState:i,element:l,widgetMgr:s,fragmentId:u,onFormCleared:c});return(0,n.useEffect)((()=>{l.setValue&&(l.setValue=!1,p({value:o(l),fromUi:!1}))}),[l,o,p]),[f,p]}},94928:(e,t,r)=>{"use strict";r.d(t,{A:()=>x});var n=r(58878),o=r(35331),i=r(18648),a=r(92850),l=r(57224),s=r(81301);function u(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?u(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):u(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var f=(0,l.I4)("div",(function(e){return c(c({},(0,s.vt)(c(c({$positive:!1},e),{},{$hasIconTrailing:!1}))),{},{width:e.$resize?"fit-content":"100%"})}));f.displayName="StyledTextAreaRoot",f.displayName="StyledTextAreaRoot";var p=(0,l.I4)("div",(function(e){return(0,s.EO)(c({$positive:!1},e))}));p.displayName="StyledTextareaContainer",p.displayName="StyledTextareaContainer";var m=(0,l.I4)("textarea",(function(e){return c(c({},(0,s.n)(e)),{},{resize:e.$resize||"none"})}));function g(e){return g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g(e)}function h(){return h=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},h.apply(this,arguments)}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==r)return;var n,o,i=[],a=!0,l=!1;try{for(r=r.call(e);!(a=(n=r.next()).done)&&(i.push(n.value),!t||i.length!==t);a=!0);}catch(s){l=!0,o=s}finally{try{a||null==r.return||r.return()}finally{if(l)throw o}}return i}(e,t)||function(e,t){if(!e)return;if("string"===typeof e)return b(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return b(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function b(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function v(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 S(e,t){return S=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},S(e,t)}function w(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=C(e);if(t){var o=C(this).constructor;r=Reflect.construct(n,arguments,o)}else r=n.apply(this,arguments);return function(e,t){if(t&&("object"===g(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return O(e)}(this,r)}}function O(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function C(e){return C=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},C(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}m.displayName="StyledTextarea",m.displayName="StyledTextarea";var j=function(e){!function(e,t){if("function"!==typeof t&&null!==t)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&&S(e,t)}(u,e);var t,r,l,s=w(u);function u(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,u);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return F(O(e=s.call.apply(s,[this].concat(r))),"state",{isFocused:e.props.autoFocus||!1}),F(O(e),"onFocus",(function(t){e.setState({isFocused:!0}),e.props.onFocus(t)})),F(O(e),"onBlur",(function(t){e.setState({isFocused:!1}),e.props.onBlur(t)})),e}return t=u,(r=[{key:"render",value:function(){var e=this.props.overrides,t=void 0===e?{}:e,r=y((0,o._O)(t.Root,f),2),l=r[0],s=r[1],u=(0,o.Qp)({Input:{component:m},InputContainer:{component:p}},t);return n.createElement(l,h({"data-baseweb":"textarea",$isFocused:this.state.isFocused,$isReadOnly:this.props.readOnly,$disabled:this.props.disabled,$error:this.props.error,$positive:this.props.positive,$required:this.props.required,$resize:this.props.resize},s),n.createElement(i.A,h({},this.props,{type:a.GT.textarea,overrides:u,onFocus:this.onFocus,onBlur:this.onBlur,resize:this.props.resize})))}}])&&v(t.prototype,r),l&&v(t,l),Object.defineProperty(t,"prototype",{writable:!1}),u}(n.Component);F(j,"defaultProps",{autoFocus:!1,disabled:!1,readOnly:!1,error:!1,name:"",onBlur:function(){},onChange:function(){},onKeyDown:function(){},onKeyPress:function(){},onKeyUp:function(){},onFocus:function(){},overrides:{},placeholder:"",required:!1,rows:3,size:a.SK.default});const x=j},32698:(e,t,r)=>{var n=r(30136),o=0;e.exports=function(e){var t=++o;return n(e)+t}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[6073],{95241:(t,e,i)=>{i.d(e,{e:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("path",{fill:"none",d:"M0 0h24v24H0V0z"}),n.createElement("path",{d:"M16 9v10H8V9h8m-1.5-6h-5l-1 1H5v2h14V4h-3.5l-1-1zM18 7H6v12c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7z"}))}));o.displayName="Delete"},50248:(t,e,i)=>{i.d(e,{f:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("path",{fill:"none",d:"M0 0h24v24H0V0z"}),n.createElement("path",{d:"M19 9h-4V3H9v6H5l7 7 7-7zm-8 2V5h2v6h1.17L12 13.17 9.83 11H11zm-6 7h14v2H5z"}))}));o.displayName="Download"},12274:(t,e,i)=>{i.d(e,{g:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("path",{fill:"none",d:"M0 0h24v24H0V0z"}),n.createElement("path",{d:"M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"}))}));o.displayName="Fullscreen"},63186:(t,e,i)=>{i.d(e,{Q:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("path",{fill:"none",d:"M0 0h24v24H0V0z"}),n.createElement("path",{d:"M5 16h3v3h2v-5H5v2zm3-8H5v2h5V5H8v3zm6 11h2v-3h3v-2h-5v5zm2-11V5h-2v5h5V8h-3z"}))}));o.displayName="FullscreenExit"},96626:(t,e,i)=>{i.d(e,{G:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("g",{fill:"none"},n.createElement("rect",{width:24,height:24}),n.createElement("rect",{width:24,height:24}),n.createElement("rect",{width:24,height:24})),n.createElement("path",{d:"M12 14c1.66 0 3-1.34 3-3V5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3z"}),n.createElement("path",{d:"M17 11c0 2.76-2.24 5-5 5s-5-2.24-5-5H5c0 3.53 2.61 6.43 6 6.92V21h2v-3.08c3.39-.49 6-3.39 6-6.92h-2z"}))}));o.displayName="Mic"},37789:(t,e,i)=>{i.d(e,{v:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("rect",{width:24,height:24,fill:"none"}),n.createElement("path",{d:"M8 19c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2s-2 .9-2 2v10c0 1.1.9 2 2 2zm6-12v10c0 1.1.9 2 2 2s2-.9 2-2V7c0-1.1-.9-2-2-2s-2 .9-2 2z"}))}));o.displayName="Pause"},14757:(t,e,i)=>{i.d(e,{S:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("rect",{width:24,height:24,fill:"none"}),n.createElement("path",{d:"M8 6.82v10.36c0 .79.87 1.27 1.54.84l8.14-5.18a1 1 0 000-1.69L9.54 5.98A.998.998 0 008 6.82z"}))}));o.displayName="PlayArrow"},88685:(t,e,i)=>{i.d(e,{C:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("path",{fill:"none",d:"M0 0h24v24H0V0z"}),n.createElement("path",{d:"M17.65 6.35a7.95 7.95 0 00-6.48-2.31c-3.67.37-6.69 3.35-7.1 7.02C3.52 15.91 7.27 20 12 20a7.98 7.98 0 007.21-4.56c.32-.67-.16-1.44-.9-1.44-.37 0-.72.2-.88.53a5.994 5.994 0 01-6.8 3.31c-2.22-.49-4.01-2.3-4.48-4.52A6.002 6.002 0 0112 6c1.66 0 3.14.69 4.22 1.78l-1.51 1.51c-.63.63-.19 1.71.7 1.71H19c.55 0 1-.45 1-1V6.41c0-.89-1.08-1.34-1.71-.71l-.64.65z"}))}));o.displayName="Refresh"},34783:(t,e,i)=>{i.d(e,{X:()=>o});var r=i(68102),n=i(58878),s=i(68622),o=n.forwardRef((function(t,e){return n.createElement(s.I,(0,r.A)({iconAttrs:{fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},iconVerticalAlign:"middle",iconViewBox:"0 0 24 24"},t,{ref:e}),n.createElement("g",{fill:"none"},n.createElement("rect",{width:24,height:24}),n.createElement("rect",{width:24,height:24})),n.createElement("path",{fillRule:"evenodd",d:"M9 16h6c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1H9c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1zm3-14C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2z"}))}));o.displayName="StopCircle"},56146:(t,e,i)=>{function r(t,e,i,r){return new(i||(i=Promise))((function(n,s){function o(t){try{h(r.next(t))}catch(t){s(t)}}function a(t){try{h(r.throw(t))}catch(t){s(t)}}function h(t){var e;t.done?n(t.value):(e=t.value,e instanceof i?e:new i((function(t){t(e)}))).then(o,a)}h((r=r.apply(t,e||[])).next())}))}i.d(e,{A:()=>h}),"function"==typeof SuppressedError&&SuppressedError;class n{constructor(){this.listeners={}}on(t,e,i){if(this.listeners[t]||(this.listeners[t]=new Set),this.listeners[t].add(e),null==i?void 0:i.once){const i=()=>{this.un(t,i),this.un(t,e)};return this.on(t,i),i}return()=>this.un(t,e)}un(t,e){var i;null===(i=this.listeners[t])||void 0===i||i.delete(e)}once(t,e){return this.on(t,e,{once:!0})}unAll(){this.listeners={}}emit(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),r=1;r<e;r++)i[r-1]=arguments[r];this.listeners[t]&&this.listeners[t].forEach((t=>t(...i)))}}class s extends n{constructor(t){super(),this.subscriptions=[],this.options=t}onInit(){}_init(t){this.wavesurfer=t,this.onInit()}destroy(){this.emit("destroy"),this.subscriptions.forEach((t=>t()))}}class o extends n{constructor(){super(...arguments),this.unsubscribe=()=>{}}start(){this.unsubscribe=this.on("tick",(()=>{requestAnimationFrame((()=>{this.emit("tick")}))})),this.emit("tick")}stop(){this.unsubscribe()}destroy(){this.unsubscribe()}}const a=["audio/webm","audio/wav","audio/mpeg","audio/mp4","audio/mp3"];class h extends s{constructor(t){var e,i,r,n,s;super(Object.assign(Object.assign({},t),{audioBitsPerSecond:null!==(e=t.audioBitsPerSecond)&&void 0!==e?e:128e3,scrollingWaveform:null!==(i=t.scrollingWaveform)&&void 0!==i&&i,scrollingWaveformWindow:null!==(r=t.scrollingWaveformWindow)&&void 0!==r?r:5,renderRecordedAudio:null===(n=t.renderRecordedAudio)||void 0===n||n,mediaRecorderTimeslice:null!==(s=t.mediaRecorderTimeslice)&&void 0!==s?s:void 0})),this.stream=null,this.mediaRecorder=null,this.dataWindow=null,this.isWaveformPaused=!1,this.lastStartTime=0,this.lastDuration=0,this.duration=0,this.timer=new o,this.subscriptions.push(this.timer.on("tick",(()=>{const t=performance.now()-this.lastStartTime;this.duration=this.isPaused()?this.duration:this.lastDuration+t,this.emit("record-progress",this.duration)})))}static create(t){return new h(t||{})}renderMicStream(t){const e=new AudioContext,i=e.createMediaStreamSource(t),r=e.createAnalyser();i.connect(r);const n=r.frequencyBinCount,s=new Float32Array(n);let o;const a=Math.floor((this.options.scrollingWaveformWindow||0)*e.sampleRate),h=()=>{var t;if(this.isWaveformPaused)return void(o=requestAnimationFrame(h));if(r.getFloatTimeDomainData(s),this.options.scrollingWaveform){const t=Math.min(a,this.dataWindow?this.dataWindow.length+n:n),e=new Float32Array(a);if(this.dataWindow){const i=Math.max(0,a-this.dataWindow.length);e.set(this.dataWindow.slice(-t+n),i)}e.set(s,a-n),this.dataWindow=e}else this.dataWindow=s;const e=this.options.scrollingWaveformWindow;this.wavesurfer&&(null!==(t=this.originalOptions)&&void 0!==t||(this.originalOptions={cursorWidth:this.wavesurfer.options.cursorWidth,interact:this.wavesurfer.options.interact}),this.wavesurfer.options.cursorWidth=0,this.wavesurfer.options.interact=!1,this.wavesurfer.load("",[this.dataWindow],e)),o=requestAnimationFrame(h)};return h(),{onDestroy:()=>{cancelAnimationFrame(o),null==i||i.disconnect(),null==e||e.close()},onEnd:()=>{this.isWaveformPaused=!0,cancelAnimationFrame(o),this.stopMic()}}}startMic(t){return r(this,void 0,void 0,(function*(){let e;try{e=yield navigator.mediaDevices.getUserMedia({audio:!(null==t?void 0:t.deviceId)||{deviceId:t.deviceId}})}catch(e){throw new Error("Error accessing the microphone: "+e.message)}const{onDestroy:i,onEnd:r}=this.renderMicStream(e);return this.subscriptions.push(this.once("destroy",i)),this.subscriptions.push(this.once("record-end",r)),this.stream=e,e}))}stopMic(){this.stream&&(this.stream.getTracks().forEach((t=>t.stop())),this.stream=null,this.mediaRecorder=null)}startRecording(t){return r(this,void 0,void 0,(function*(){const e=this.stream||(yield this.startMic(t));this.dataWindow=null;const i=this.mediaRecorder||new MediaRecorder(e,{mimeType:this.options.mimeType||a.find((t=>MediaRecorder.isTypeSupported(t))),audioBitsPerSecond:this.options.audioBitsPerSecond});this.mediaRecorder=i,this.stopRecording();const r=[];i.ondataavailable=t=>{t.data.size>0&&r.push(t.data),this.emit("record-data-available",t.data)};const n=t=>{var e;const n=new Blob(r,{type:i.mimeType});this.emit(t,n),this.options.renderRecordedAudio&&(this.applyOriginalOptionsIfNeeded(),null===(e=this.wavesurfer)||void 0===e||e.load(URL.createObjectURL(n)))};i.onpause=()=>n("record-pause"),i.onstop=()=>n("record-end"),i.start(this.options.mediaRecorderTimeslice),this.lastStartTime=performance.now(),this.lastDuration=0,this.duration=0,this.isWaveformPaused=!1,this.timer.start(),this.emit("record-start")}))}getDuration(){return this.duration}isRecording(){var t;return"recording"===(null===(t=this.mediaRecorder)||void 0===t?void 0:t.state)}isPaused(){var t;return"paused"===(null===(t=this.mediaRecorder)||void 0===t?void 0:t.state)}isActive(){var t;return"inactive"!==(null===(t=this.mediaRecorder)||void 0===t?void 0:t.state)}stopRecording(){var t;this.isActive()&&(null===(t=this.mediaRecorder)||void 0===t||t.stop(),this.timer.stop())}pauseRecording(){var t,e;this.isRecording()&&(this.isWaveformPaused=!0,null===(t=this.mediaRecorder)||void 0===t||t.requestData(),null===(e=this.mediaRecorder)||void 0===e||e.pause(),this.timer.stop(),this.lastDuration=this.duration)}resumeRecording(){var t;this.isPaused()&&(this.isWaveformPaused=!1,null===(t=this.mediaRecorder)||void 0===t||t.resume(),this.timer.start(),this.lastStartTime=performance.now(),this.emit("record-resume"))}static getAvailableAudioDevices(){return r(this,void 0,void 0,(function*(){return navigator.mediaDevices.enumerateDevices().then((t=>t.filter((t=>"audioinput"===t.kind))))}))}destroy(){this.applyOriginalOptionsIfNeeded(),super.destroy(),this.stopRecording(),this.stopMic()}applyOriginalOptionsIfNeeded(){this.wavesurfer&&this.originalOptions&&(this.wavesurfer.options.cursorWidth=this.originalOptions.cursorWidth,this.wavesurfer.options.interact=this.originalOptions.interact,delete this.originalOptions)}}},19613:(t,e,i)=>{function r(t,e,i,r){return new(i||(i=Promise))((function(n,s){function o(t){try{h(r.next(t))}catch(t){s(t)}}function a(t){try{h(r.throw(t))}catch(t){s(t)}}function h(t){var e;t.done?n(t.value):(e=t.value,e instanceof i?e:new i((function(t){t(e)}))).then(o,a)}h((r=r.apply(t,e||[])).next())}))}i.d(e,{A:()=>v}),"function"==typeof SuppressedError&&SuppressedError;class n{constructor(){this.listeners={}}on(t,e,i){if(this.listeners[t]||(this.listeners[t]=new Set),this.listeners[t].add(e),null==i?void 0:i.once){const i=()=>{this.un(t,i),this.un(t,e)};return this.on(t,i),i}return()=>this.un(t,e)}un(t,e){var i;null===(i=this.listeners[t])||void 0===i||i.delete(e)}once(t,e){return this.on(t,e,{once:!0})}unAll(){this.listeners={}}emit(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),r=1;r<e;r++)i[r-1]=arguments[r];this.listeners[t]&&this.listeners[t].forEach((t=>t(...i)))}}const s={decode:function(t,e){return r(this,void 0,void 0,(function*(){const i=new AudioContext({sampleRate:e});return i.decodeAudioData(t).finally((()=>i.close()))}))},createBuffer:function(t,e){return"number"==typeof t[0]&&(t=[t]),function(t){const e=t[0];if(e.some((t=>t>1||t<-1))){const i=e.length;let r=0;for(let t=0;t<i;t++){const i=Math.abs(e[t]);i>r&&(r=i)}for(const e of t)for(let t=0;t<i;t++)e[t]/=r}}(t),{duration:e,length:t[0].length,sampleRate:t[0].length/e,numberOfChannels:t.length,getChannelData:e=>null==t?void 0:t[e],copyFromChannel:AudioBuffer.prototype.copyFromChannel,copyToChannel:AudioBuffer.prototype.copyToChannel}}};function o(t,e){const i=e.xmlns?document.createElementNS(e.xmlns,t):document.createElement(t);for(const[r,n]of Object.entries(e))if("children"===r)for(const[t,s]of Object.entries(e))"string"==typeof s?i.appendChild(document.createTextNode(s)):i.appendChild(o(t,s));else"style"===r?Object.assign(i.style,n):"textContent"===r?i.textContent=n:i.setAttribute(r,n.toString());return i}function a(t,e,i){const r=o(t,e||{});return null==i||i.appendChild(r),r}var h=Object.freeze({__proto__:null,createElement:a,default:a});const l={fetchBlob:function(t,e,i){return r(this,void 0,void 0,(function*(){const n=yield fetch(t,i);if(n.status>=400)throw new Error(`Failed to fetch ${t}: ${n.status} (${n.statusText})`);return function(t,e){r(this,void 0,void 0,(function*(){if(!t.body||!t.headers)return;const i=t.body.getReader(),n=Number(t.headers.get("Content-Length"))||0;let s=0;const o=t=>r(this,void 0,void 0,(function*(){s+=(null==t?void 0:t.length)||0;const i=Math.round(s/n*100);e(i)})),a=()=>r(this,void 0,void 0,(function*(){let t;try{t=yield i.read()}catch(t){return}t.done||(o(t.value),yield a())}));a()}))}(n.clone(),e),n.blob()}))}};class d extends n{constructor(t){super(),this.isExternalMedia=!1,t.media?(this.media=t.media,this.isExternalMedia=!0):this.media=document.createElement("audio"),t.mediaControls&&(this.media.controls=!0),t.autoplay&&(this.media.autoplay=!0),null!=t.playbackRate&&this.onMediaEvent("canplay",(()=>{null!=t.playbackRate&&(this.media.playbackRate=t.playbackRate)}),{once:!0})}onMediaEvent(t,e,i){return this.media.addEventListener(t,e,i),()=>this.media.removeEventListener(t,e,i)}getSrc(){return this.media.currentSrc||this.media.src||""}revokeSrc(){const t=this.getSrc();t.startsWith("blob:")&&URL.revokeObjectURL(t)}canPlayType(t){return""!==this.media.canPlayType(t)}setSrc(t,e){const i=this.getSrc();if(t&&i===t)return;this.revokeSrc();const r=e instanceof Blob&&(this.canPlayType(e.type)||!t)?URL.createObjectURL(e):t;try{this.media.src=r}catch(e){this.media.src=t}}destroy(){this.media.pause(),this.isExternalMedia||(this.media.remove(),this.revokeSrc(),this.media.src="",this.media.load())}setMediaElement(t){this.media=t}play(){return r(this,void 0,void 0,(function*(){return this.media.play()}))}pause(){this.media.pause()}isPlaying(){return!this.media.paused&&!this.media.ended}setTime(t){this.media.currentTime=t}getDuration(){return this.media.duration}getCurrentTime(){return this.media.currentTime}getVolume(){return this.media.volume}setVolume(t){this.media.volume=t}getMuted(){return this.media.muted}setMuted(t){this.media.muted=t}getPlaybackRate(){return this.media.playbackRate}isSeeking(){return this.media.seeking}setPlaybackRate(t,e){null!=e&&(this.media.preservesPitch=e),this.media.playbackRate=t}getMediaElement(){return this.media}setSinkId(t){return this.media.setSinkId(t)}}class c extends n{constructor(t,e){super(),this.timeouts=[],this.isScrollable=!1,this.audioData=null,this.resizeObserver=null,this.lastContainerWidth=0,this.isDragging=!1,this.subscriptions=[],this.subscriptions=[],this.options=t;const i=this.parentFromOptionsContainer(t.container);this.parent=i;const[r,n]=this.initHtml();i.appendChild(r),this.container=r,this.scrollContainer=n.querySelector(".scroll"),this.wrapper=n.querySelector(".wrapper"),this.canvasWrapper=n.querySelector(".canvases"),this.progressWrapper=n.querySelector(".progress"),this.cursor=n.querySelector(".cursor"),e&&n.appendChild(e),this.initEvents()}parentFromOptionsContainer(t){let e;if("string"==typeof t?e=document.querySelector(t):t instanceof HTMLElement&&(e=t),!e)throw new Error("Container not found");return e}initEvents(){const t=t=>{const e=this.wrapper.getBoundingClientRect(),i=t.clientX-e.left,r=t.clientY-e.top;return[i/e.width,r/e.height]};if(this.wrapper.addEventListener("click",(e=>{const[i,r]=t(e);this.emit("click",i,r)})),this.wrapper.addEventListener("dblclick",(e=>{const[i,r]=t(e);this.emit("dblclick",i,r)})),!0!==this.options.dragToSeek&&"object"!=typeof this.options.dragToSeek||this.initDrag(),this.scrollContainer.addEventListener("scroll",(()=>{const{scrollLeft:t,scrollWidth:e,clientWidth:i}=this.scrollContainer,r=t/e,n=(t+i)/e;this.emit("scroll",r,n,t,t+i)})),"function"==typeof ResizeObserver){const t=this.createDelay(100);this.resizeObserver=new ResizeObserver((()=>{t().then((()=>this.onContainerResize())).catch((()=>{}))})),this.resizeObserver.observe(this.scrollContainer)}}onContainerResize(){const t=this.parent.clientWidth;t===this.lastContainerWidth&&"auto"!==this.options.height||(this.lastContainerWidth=t,this.reRender())}initDrag(){this.subscriptions.push(function(t,e,i,r){let n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:3,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:100;if(!t)return()=>{};const a=matchMedia("(pointer: coarse)").matches;let h=()=>{};const l=l=>{if(l.button!==s)return;l.preventDefault(),l.stopPropagation();let d=l.clientX,c=l.clientY,u=!1;const p=Date.now(),m=r=>{if(r.preventDefault(),r.stopPropagation(),a&&Date.now()-p<o)return;const s=r.clientX,h=r.clientY,l=s-d,m=h-c;if(u||Math.abs(l)>n||Math.abs(m)>n){const r=t.getBoundingClientRect(),{left:n,top:o}=r;u||(null==i||i(d-n,c-o),u=!0),e(l,m,s-n,h-o),d=s,c=h}},v=e=>{if(u){const i=e.clientX,n=e.clientY,s=t.getBoundingClientRect(),{left:o,top:a}=s;null==r||r(i-o,n-a)}h()},f=t=>{t.relatedTarget&&t.relatedTarget!==document.documentElement||v(t)},g=t=>{u&&(t.stopPropagation(),t.preventDefault())},b=t=>{u&&t.preventDefault()};document.addEventListener("pointermove",m),document.addEventListener("pointerup",v),document.addEventListener("pointerout",f),document.addEventListener("pointercancel",f),document.addEventListener("touchmove",b,{passive:!1}),document.addEventListener("click",g,{capture:!0}),h=()=>{document.removeEventListener("pointermove",m),document.removeEventListener("pointerup",v),document.removeEventListener("pointerout",f),document.removeEventListener("pointercancel",f),document.removeEventListener("touchmove",b),setTimeout((()=>{document.removeEventListener("click",g,{capture:!0})}),10)}};return t.addEventListener("pointerdown",l),()=>{h(),t.removeEventListener("pointerdown",l)}}(this.wrapper,((t,e,i)=>{this.emit("drag",Math.max(0,Math.min(1,i/this.wrapper.getBoundingClientRect().width)))}),(t=>{this.isDragging=!0,this.emit("dragstart",Math.max(0,Math.min(1,t/this.wrapper.getBoundingClientRect().width)))}),(t=>{this.isDragging=!1,this.emit("dragend",Math.max(0,Math.min(1,t/this.wrapper.getBoundingClientRect().width)))})))}getHeight(t,e){var i;const r=(null===(i=this.audioData)||void 0===i?void 0:i.numberOfChannels)||1;if(null==t)return 128;if(!isNaN(Number(t)))return Number(t);if("auto"===t){const t=this.parent.clientHeight||128;return(null==e?void 0:e.every((t=>!t.overlay)))?t/r:t}return 128}initHtml(){const t=document.createElement("div"),e=t.attachShadow({mode:"open"});return e.innerHTML=`\n <style>\n :host {\n user-select: none;\n min-width: 1px;\n }\n :host audio {\n display: block;\n width: 100%;\n }\n :host .scroll {\n overflow-x: auto;\n overflow-y: hidden;\n width: 100%;\n position: relative;\n }\n :host .noScrollbar {\n scrollbar-color: transparent;\n scrollbar-width: none;\n }\n :host .noScrollbar::-webkit-scrollbar {\n display: none;\n -webkit-appearance: none;\n }\n :host .wrapper {\n position: relative;\n overflow: visible;\n z-index: 2;\n }\n :host .canvases {\n min-height: ${this.getHeight(this.options.height,this.options.splitChannels)}px;\n }\n :host .canvases > div {\n position: relative;\n }\n :host canvas {\n display: block;\n position: absolute;\n top: 0;\n image-rendering: pixelated;\n }\n :host .progress {\n pointer-events: none;\n position: absolute;\n z-index: 2;\n top: 0;\n left: 0;\n width: 0;\n height: 100%;\n overflow: hidden;\n }\n :host .progress > div {\n position: relative;\n }\n :host .cursor {\n pointer-events: none;\n position: absolute;\n z-index: 5;\n top: 0;\n left: 0;\n height: 100%;\n border-radius: 2px;\n }\n </style>\n\n <div class="scroll" part="scroll">\n <div class="wrapper" part="wrapper">\n <div class="canvases" part="canvases"></div>\n <div class="progress" part="progress"></div>\n <div class="cursor" part="cursor"></div>\n </div>\n </div>\n `,[t,e]}setOptions(t){if(this.options.container!==t.container){const e=this.parentFromOptionsContainer(t.container);e.appendChild(this.container),this.parent=e}!0!==t.dragToSeek&&"object"!=typeof this.options.dragToSeek||this.initDrag(),this.options=t,this.reRender()}getWrapper(){return this.wrapper}getWidth(){return this.scrollContainer.clientWidth}getScroll(){return this.scrollContainer.scrollLeft}setScroll(t){this.scrollContainer.scrollLeft=t}setScrollPercentage(t){const{scrollWidth:e}=this.scrollContainer,i=e*t;this.setScroll(i)}destroy(){var t,e;this.subscriptions.forEach((t=>t())),this.container.remove(),null===(t=this.resizeObserver)||void 0===t||t.disconnect(),null===(e=this.unsubscribeOnScroll)||void 0===e||e.call(this)}createDelay(){let t,e,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10;const r=()=>{t&&clearTimeout(t),e&&e()};return this.timeouts.push(r),()=>new Promise(((n,s)=>{r(),e=s,t=setTimeout((()=>{t=void 0,e=void 0,n()}),i)}))}convertColorValues(t){if(!Array.isArray(t))return t||"";if(t.length<2)return t[0]||"";const e=document.createElement("canvas"),i=e.getContext("2d"),r=e.height*(window.devicePixelRatio||1),n=i.createLinearGradient(0,0,0,r),s=1/(t.length-1);return t.forEach(((t,e)=>{const i=e*s;n.addColorStop(i,t)})),n}getPixelRatio(){return Math.max(1,window.devicePixelRatio||1)}renderBarWaveform(t,e,i,r){const n=t[0],s=t[1]||t[0],o=n.length,{width:a,height:h}=i.canvas,l=h/2,d=this.getPixelRatio(),c=e.barWidth?e.barWidth*d:1,u=e.barGap?e.barGap*d:e.barWidth?c/2:0,p=e.barRadius||0,m=a/(c+u)/o,v=p&&"roundRect"in i?"roundRect":"rect";i.beginPath();let f=0,g=0,b=0;for(let y=0;y<=o;y++){const t=Math.round(y*m);if(t>f){const n=Math.round(g*l*r),s=n+Math.round(b*l*r)||1;let o=l-n;"top"===e.barAlign?o=0:"bottom"===e.barAlign&&(o=h-s),i[v](f*(c+u),o,c,s,p),f=t,g=0,b=0}const o=Math.abs(n[y]||0),a=Math.abs(s[y]||0);o>g&&(g=o),a>b&&(b=a)}i.fill(),i.closePath()}renderLineWaveform(t,e,i,r){const n=e=>{const n=t[e]||t[0],s=n.length,{height:o}=i.canvas,a=o/2,h=i.canvas.width/s;i.moveTo(0,a);let l=0,d=0;for(let t=0;t<=s;t++){const s=Math.round(t*h);if(s>l){const t=a+(Math.round(d*a*r)||1)*(0===e?-1:1);i.lineTo(l,t),l=s,d=0}const o=Math.abs(n[t]||0);o>d&&(d=o)}i.lineTo(l,a)};i.beginPath(),n(0),n(1),i.fill(),i.closePath()}renderWaveform(t,e,i){if(i.fillStyle=this.convertColorValues(e.waveColor),e.renderFunction)return void e.renderFunction(t,i);let r=e.barHeight||1;if(e.normalize){const e=Array.from(t[0]).reduce(((t,e)=>Math.max(t,Math.abs(e))),0);r=e?1/e:1}e.barWidth||e.barGap||e.barAlign?this.renderBarWaveform(t,e,i,r):this.renderLineWaveform(t,e,i,r)}renderSingleCanvas(t,e,i,r,n,s,o){const a=this.getPixelRatio(),h=document.createElement("canvas");h.width=Math.round(i*a),h.height=Math.round(r*a),h.style.width=`${i}px`,h.style.height=`${r}px`,h.style.left=`${Math.round(n)}px`,s.appendChild(h);const l=h.getContext("2d");if(this.renderWaveform(t,e,l),h.width>0&&h.height>0){const t=h.cloneNode(),i=t.getContext("2d");i.drawImage(h,0,0),i.globalCompositeOperation="source-in",i.fillStyle=this.convertColorValues(e.progressColor),i.fillRect(0,0,h.width,h.height),o.appendChild(t)}}renderMultiCanvas(t,e,i,r,n,s){const o=this.getPixelRatio(),{clientWidth:a}=this.scrollContainer;if(a*o>=i)return void this.renderSingleCanvas(t,e,a,r,0,n,s);const h=i/o;let l=Math.min(c.MAX_CANVAS_WIDTH,a,h),d={};if(e.barWidth||e.barGap){const t=e.barWidth||.5,i=t+(e.barGap||t/2);l%i!=0&&(l=Math.floor(l/i)*i)}const u=i=>{if(i<0||i>=p)return;if(d[i])return;d[i]=!0;const o=i*l,a=Math.min(h-o,l);if(a<=0)return;const c=t.map((t=>{const e=Math.floor(o/h*t.length),i=Math.floor((o+a)/h*t.length);return t.slice(e,i)}));this.renderSingleCanvas(c,e,a,r,o,n,s)},p=Math.ceil(h/l),m=this.scrollContainer.scrollLeft/h,v=Math.floor(m*p);u(v-1),u(v),u(v+1),p>1&&(this.unsubscribeOnScroll=this.on("scroll",(()=>{const{scrollLeft:t}=this.scrollContainer,e=Math.floor(t/h*p);Object.keys(d).length>c.MAX_NODES&&(n.innerHTML="",s.innerHTML="",d={}),u(e-1),u(e),u(e+1)})))}renderChannel(t,e,i,r){var{overlay:n}=e,s=function(t,e){var i={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(i[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(r=Object.getOwnPropertySymbols(t);n<r.length;n++)e.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(t,r[n])&&(i[r[n]]=t[r[n]])}return i}(e,["overlay"]);const o=document.createElement("div"),a=this.getHeight(s.height,s.splitChannels);o.style.height=`${a}px`,n&&r>0&&(o.style.marginTop=`-${a}px`),this.canvasWrapper.style.minHeight=`${a}px`,this.canvasWrapper.appendChild(o);const h=o.cloneNode();this.progressWrapper.appendChild(h),this.renderMultiCanvas(t,s,i,a,o,h)}render(t){return r(this,void 0,void 0,(function*(){var e;this.timeouts.forEach((t=>t())),this.timeouts=[],this.canvasWrapper.innerHTML="",this.progressWrapper.innerHTML="",null!=this.options.width&&(this.scrollContainer.style.width="number"==typeof this.options.width?`${this.options.width}px`:this.options.width);const i=this.getPixelRatio(),r=this.scrollContainer.clientWidth,n=Math.ceil(t.duration*(this.options.minPxPerSec||0));this.isScrollable=n>r;const s=this.options.fillParent&&!this.isScrollable,o=(s?r:n)*i;if(this.wrapper.style.width=s?"100%":`${n}px`,this.scrollContainer.style.overflowX=this.isScrollable?"auto":"hidden",this.scrollContainer.classList.toggle("noScrollbar",!!this.options.hideScrollbar),this.cursor.style.backgroundColor=`${this.options.cursorColor||this.options.progressColor}`,this.cursor.style.width=`${this.options.cursorWidth}px`,this.audioData=t,this.emit("render"),this.options.splitChannels)for(let a=0;a<t.numberOfChannels;a++){const i=Object.assign(Object.assign({},this.options),null===(e=this.options.splitChannels)||void 0===e?void 0:e[a]);this.renderChannel([t.getChannelData(a)],i,o,a)}else{const e=[t.getChannelData(0)];t.numberOfChannels>1&&e.push(t.getChannelData(1)),this.renderChannel(e,this.options,o,0)}Promise.resolve().then((()=>this.emit("rendered")))}))}reRender(){var t;if(null===(t=this.unsubscribeOnScroll)||void 0===t||t.call(this),delete this.unsubscribeOnScroll,!this.audioData)return;const{scrollWidth:e}=this.scrollContainer,{right:i}=this.progressWrapper.getBoundingClientRect();if(this.render(this.audioData),this.isScrollable&&e!==this.scrollContainer.scrollWidth){const{right:t}=this.progressWrapper.getBoundingClientRect();let e=t-i;e*=2,e=e<0?Math.floor(e):Math.ceil(e),e/=2,this.scrollContainer.scrollLeft+=e}}zoom(t){this.options.minPxPerSec=t,this.reRender()}scrollIntoView(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const{scrollLeft:i,scrollWidth:r,clientWidth:n}=this.scrollContainer,s=t*r,o=i,a=i+n,h=n/2;if(this.isDragging){const t=30;s+t>a?this.scrollContainer.scrollLeft+=t:s-t<o&&(this.scrollContainer.scrollLeft-=t)}else{(s<o||s>a)&&(this.scrollContainer.scrollLeft=s-(this.options.autoCenter?h:0));const t=s-i-h;e&&this.options.autoCenter&&t>0&&(this.scrollContainer.scrollLeft+=Math.min(t,10))}{const t=this.scrollContainer.scrollLeft,e=t/r,i=(t+n)/r;this.emit("scroll",e,i,t,t+n)}}renderProgress(t,e){if(isNaN(t))return;const i=100*t;this.canvasWrapper.style.clipPath=`polygon(${i}% 0, 100% 0, 100% 100%, ${i}% 100%)`,this.progressWrapper.style.width=`${i}%`,this.cursor.style.left=`${i}%`,this.cursor.style.transform=`translateX(-${100===Math.round(i)?this.options.cursorWidth:0}px)`,this.isScrollable&&this.options.autoScroll&&this.scrollIntoView(t,e)}exportImage(t,e,i){return r(this,void 0,void 0,(function*(){const r=this.canvasWrapper.querySelectorAll("canvas");if(!r.length)throw new Error("No waveform data");if("dataURL"===i){const i=Array.from(r).map((i=>i.toDataURL(t,e)));return Promise.resolve(i)}return Promise.all(Array.from(r).map((i=>new Promise(((r,n)=>{i.toBlob((t=>{t?r(t):n(new Error("Could not export image"))}),t,e)})))))}))}}c.MAX_CANVAS_WIDTH=8e3,c.MAX_NODES=10;class u extends n{constructor(){super(...arguments),this.unsubscribe=()=>{}}start(){this.unsubscribe=this.on("tick",(()=>{requestAnimationFrame((()=>{this.emit("tick")}))})),this.emit("tick")}stop(){this.unsubscribe()}destroy(){this.unsubscribe()}}class p extends n{constructor(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new AudioContext;super(),this.bufferNode=null,this.playStartTime=0,this.playedDuration=0,this._muted=!1,this._playbackRate=1,this._duration=void 0,this.buffer=null,this.currentSrc="",this.paused=!0,this.crossOrigin=null,this.seeking=!1,this.autoplay=!1,this.addEventListener=this.on,this.removeEventListener=this.un,this.audioContext=t,this.gainNode=this.audioContext.createGain(),this.gainNode.connect(this.audioContext.destination)}load(){return r(this,void 0,void 0,(function*(){}))}get src(){return this.currentSrc}set src(t){if(this.currentSrc=t,this._duration=void 0,!t)return this.buffer=null,void this.emit("emptied");fetch(t).then((e=>{if(e.status>=400)throw new Error(`Failed to fetch ${t}: ${e.status} (${e.statusText})`);return e.arrayBuffer()})).then((e=>this.currentSrc!==t?null:this.audioContext.decodeAudioData(e))).then((e=>{this.currentSrc===t&&(this.buffer=e,this.emit("loadedmetadata"),this.emit("canplay"),this.autoplay&&this.play())}))}_play(){var t;if(!this.paused)return;this.paused=!1,null===(t=this.bufferNode)||void 0===t||t.disconnect(),this.bufferNode=this.audioContext.createBufferSource(),this.buffer&&(this.bufferNode.buffer=this.buffer),this.bufferNode.playbackRate.value=this._playbackRate,this.bufferNode.connect(this.gainNode);let e=this.playedDuration*this._playbackRate;e>=this.duration&&(e=0,this.playedDuration=0),this.bufferNode.start(this.audioContext.currentTime,e),this.playStartTime=this.audioContext.currentTime,this.bufferNode.onended=()=>{this.currentTime>=this.duration&&(this.pause(),this.emit("ended"))}}_pause(){var t;this.paused=!0,null===(t=this.bufferNode)||void 0===t||t.stop(),this.playedDuration+=this.audioContext.currentTime-this.playStartTime}play(){return r(this,void 0,void 0,(function*(){this.paused&&(this._play(),this.emit("play"))}))}pause(){this.paused||(this._pause(),this.emit("pause"))}stopAt(t){var e,i;const r=t-this.currentTime;null===(e=this.bufferNode)||void 0===e||e.stop(this.audioContext.currentTime+r),null===(i=this.bufferNode)||void 0===i||i.addEventListener("ended",(()=>{this.bufferNode=null,this.pause()}),{once:!0})}setSinkId(t){return r(this,void 0,void 0,(function*(){return this.audioContext.setSinkId(t)}))}get playbackRate(){return this._playbackRate}set playbackRate(t){this._playbackRate=t,this.bufferNode&&(this.bufferNode.playbackRate.value=t)}get currentTime(){return(this.paused?this.playedDuration:this.playedDuration+(this.audioContext.currentTime-this.playStartTime))*this._playbackRate}set currentTime(t){const e=!this.paused;e&&this._pause(),this.playedDuration=t/this._playbackRate,e&&this._play(),this.emit("seeking"),this.emit("timeupdate")}get duration(){var t,e;return null!==(t=this._duration)&&void 0!==t?t:(null===(e=this.buffer)||void 0===e?void 0:e.duration)||0}set duration(t){this._duration=t}get volume(){return this.gainNode.gain.value}set volume(t){this.gainNode.gain.value=t,this.emit("volumechange")}get muted(){return this._muted}set muted(t){this._muted!==t&&(this._muted=t,this._muted?this.gainNode.disconnect():this.gainNode.connect(this.audioContext.destination))}canPlayType(t){return/^(audio|video)\//.test(t)}getGainNode(){return this.gainNode}getChannelData(){const t=[];if(!this.buffer)return t;const e=this.buffer.numberOfChannels;for(let i=0;i<e;i++)t.push(this.buffer.getChannelData(i));return t}}const m={waveColor:"#999",progressColor:"#555",cursorWidth:1,minPxPerSec:0,fillParent:!0,interact:!0,dragToSeek:!1,autoScroll:!0,autoCenter:!0,sampleRate:8e3};class v extends d{static create(t){return new v(t)}constructor(t){const e=t.media||("WebAudio"===t.backend?new p:void 0);super({media:e,mediaControls:t.mediaControls,autoplay:t.autoplay,playbackRate:t.audioRate}),this.plugins=[],this.decodedData=null,this.subscriptions=[],this.mediaSubscriptions=[],this.abortController=null,this.options=Object.assign({},m,t),this.timer=new u;const i=e?void 0:this.getMediaElement();this.renderer=new c(this.options,i),this.initPlayerEvents(),this.initRendererEvents(),this.initTimerEvents(),this.initPlugins();const r=this.options.url||this.getSrc()||"";Promise.resolve().then((()=>{this.emit("init");const{peaks:t,duration:e}=this.options;(r||t&&e)&&this.load(r,t,e).catch((()=>null))}))}updateProgress(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getCurrentTime();return this.renderer.renderProgress(t/this.getDuration(),this.isPlaying()),t}initTimerEvents(){this.subscriptions.push(this.timer.on("tick",(()=>{if(!this.isSeeking()){const t=this.updateProgress();this.emit("timeupdate",t),this.emit("audioprocess",t)}})))}initPlayerEvents(){this.isPlaying()&&(this.emit("play"),this.timer.start()),this.mediaSubscriptions.push(this.onMediaEvent("timeupdate",(()=>{const t=this.updateProgress();this.emit("timeupdate",t)})),this.onMediaEvent("play",(()=>{this.emit("play"),this.timer.start()})),this.onMediaEvent("pause",(()=>{this.emit("pause"),this.timer.stop()})),this.onMediaEvent("emptied",(()=>{this.timer.stop()})),this.onMediaEvent("ended",(()=>{this.emit("finish")})),this.onMediaEvent("seeking",(()=>{this.emit("seeking",this.getCurrentTime())})),this.onMediaEvent("error",(t=>{this.emit("error",t.error)})))}initRendererEvents(){this.subscriptions.push(this.renderer.on("click",((t,e)=>{this.options.interact&&(this.seekTo(t),this.emit("interaction",t*this.getDuration()),this.emit("click",t,e))})),this.renderer.on("dblclick",((t,e)=>{this.emit("dblclick",t,e)})),this.renderer.on("scroll",((t,e,i,r)=>{const n=this.getDuration();this.emit("scroll",t*n,e*n,i,r)})),this.renderer.on("render",(()=>{this.emit("redraw")})),this.renderer.on("rendered",(()=>{this.emit("redrawcomplete")})),this.renderer.on("dragstart",(t=>{this.emit("dragstart",t)})),this.renderer.on("dragend",(t=>{this.emit("dragend",t)})));{let t;this.subscriptions.push(this.renderer.on("drag",(e=>{if(!this.options.interact)return;let i;this.renderer.renderProgress(e),clearTimeout(t),this.isPlaying()?i=0:!0===this.options.dragToSeek?i=200:"object"==typeof this.options.dragToSeek&&void 0!==this.options.dragToSeek&&(i=this.options.dragToSeek.debounceTime),t=setTimeout((()=>{this.seekTo(e)}),i),this.emit("interaction",e*this.getDuration()),this.emit("drag",e)})))}}initPlugins(){var t;(null===(t=this.options.plugins)||void 0===t?void 0:t.length)&&this.options.plugins.forEach((t=>{this.registerPlugin(t)}))}unsubscribePlayerEvents(){this.mediaSubscriptions.forEach((t=>t())),this.mediaSubscriptions=[]}setOptions(t){this.options=Object.assign({},this.options,t),this.renderer.setOptions(this.options),t.audioRate&&this.setPlaybackRate(t.audioRate),null!=t.mediaControls&&(this.getMediaElement().controls=t.mediaControls)}registerPlugin(t){return t._init(this),this.plugins.push(t),this.subscriptions.push(t.once("destroy",(()=>{this.plugins=this.plugins.filter((e=>e!==t))}))),t}getWrapper(){return this.renderer.getWrapper()}getWidth(){return this.renderer.getWidth()}getScroll(){return this.renderer.getScroll()}setScroll(t){return this.renderer.setScroll(t)}setScrollTime(t){const e=t/this.getDuration();this.renderer.setScrollPercentage(e)}getActivePlugins(){return this.plugins}loadAudio(t,e,i,n){return r(this,void 0,void 0,(function*(){var r;if(this.emit("load",t),!this.options.media&&this.isPlaying()&&this.pause(),this.decodedData=null,!e&&!i){const i=this.options.fetchParams||{};window.AbortController&&!i.signal&&(this.abortController=new AbortController,i.signal=null===(r=this.abortController)||void 0===r?void 0:r.signal);const n=t=>this.emit("loading",t);e=yield l.fetchBlob(t,n,i)}this.setSrc(t,e);const o=yield new Promise((t=>{const e=n||this.getDuration();e?t(e):this.mediaSubscriptions.push(this.onMediaEvent("loadedmetadata",(()=>t(this.getDuration())),{once:!0}))}));if(!t&&!e){const t=this.getMediaElement();t instanceof p&&(t.duration=o)}if(i)this.decodedData=s.createBuffer(i,o||0);else if(e){const t=yield e.arrayBuffer();this.decodedData=yield s.decode(t,this.options.sampleRate)}this.decodedData&&(this.emit("decode",this.getDuration()),this.renderer.render(this.decodedData)),this.emit("ready",this.getDuration())}))}load(t,e,i){return r(this,void 0,void 0,(function*(){try{return yield this.loadAudio(t,void 0,e,i)}catch(r){throw this.emit("error",r),r}}))}loadBlob(t,e,i){return r(this,void 0,void 0,(function*(){try{return yield this.loadAudio("",t,e,i)}catch(r){throw this.emit("error",r),r}}))}zoom(t){if(!this.decodedData)throw new Error("No audio loaded");this.renderer.zoom(t),this.emit("zoom",t)}getDecodedData(){return this.decodedData}exportPeaks(){let{channels:t=2,maxLength:e=8e3,precision:i=1e4}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!this.decodedData)throw new Error("The audio has not been decoded yet");const r=Math.min(t,this.decodedData.numberOfChannels),n=[];for(let s=0;s<r;s++){const t=this.decodedData.getChannelData(s),r=[],o=t.length/e;for(let n=0;n<e;n++){const e=t.slice(Math.floor(n*o),Math.ceil((n+1)*o));let s=0;for(let t=0;t<e.length;t++){const i=e[t];Math.abs(i)>Math.abs(s)&&(s=i)}r.push(Math.round(s*i)/i)}n.push(r)}return n}getDuration(){let t=super.getDuration()||0;return 0!==t&&t!==1/0||!this.decodedData||(t=this.decodedData.duration),t}toggleInteraction(t){this.options.interact=t}setTime(t){super.setTime(t),this.updateProgress(t),this.emit("timeupdate",t)}seekTo(t){const e=this.getDuration()*t;this.setTime(e)}playPause(){return r(this,void 0,void 0,(function*(){return this.isPlaying()?this.pause():this.play()}))}stop(){this.pause(),this.setTime(0)}skip(t){this.setTime(this.getCurrentTime()+t)}empty(){this.load("",[[0]],.001)}setMediaElement(t){this.unsubscribePlayerEvents(),super.setMediaElement(t),this.initPlayerEvents()}exportImage(){return r(this,arguments,void 0,(function(){var t=this;let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"image/png",i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"dataURL";return function*(){return t.renderer.exportImage(e,i,r)}()}))}destroy(){var t;this.emit("destroy"),null===(t=this.abortController)||void 0===t||t.abort(),this.plugins.forEach((t=>t.destroy())),this.subscriptions.forEach((t=>t())),this.unsubscribePlayerEvents(),this.timer.destroy(),this.renderer.destroy(),super.destroy()}}v.BasePlugin=class extends n{constructor(t){super(),this.subscriptions=[],this.options=t}onInit(){}_init(t){this.wavesurfer=t,this.onInit()}destroy(){this.emit("destroy"),this.subscriptions.forEach((t=>t()))}},v.dom=h}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[6360],{36360:(e,t,s)=>{s.r(t),s.d(t,{default:()=>C});var i=s(58878),r=s(17643),o=s.n(r),a=s(8151),n=s(64942),l=s(754),d=s(41639),m=s(34752),p=s(70474),h=s(78286),c=s(93480),u=s(997),g=s(25571),f=s(90782);const v="YYYY/MM/DD";function b(e){return e.map((e=>new Date(e)))}class y extends i.PureComponent{constructor(){super(...arguments),this.formClearHelper=new m.o,this.state={values:this.initialValue,isRange:this.props.element.isRange,isEmpty:!1},this.commitWidgetValue=e=>{const{widgetMgr:t,element:s,fragmentId:i}=this.props;var r;t.setStringArrayValue(s,(r=this.state.values)?r.map((e=>o()(e).format(v))):[],e,i)},this.onFormCleared=()=>{const e=b(this.props.element.default);this.setState({values:e,isEmpty:!e},(()=>this.commitWidgetValue({fromUi:!0})))},this.handleChange=e=>{let{date:t}=e;if(null===t||void 0===t)return void this.setState({values:[],isEmpty:!0});const s=[];Array.isArray(t)?t.forEach((e=>{e&&s.push(e)})):s.push(t),this.setState({values:s,isEmpty:!s},(()=>{this.state.isEmpty||this.commitWidgetValue({fromUi:!0})}))},this.handleClose=()=>{const{isEmpty:e}=this.state;e&&this.setState(((e,t)=>({values:b(t.element.default),isEmpty:!b(t.element.default)})),(()=>{this.commitWidgetValue({fromUi:!0})}))},this.getMaxDate=()=>{const{element:e}=this.props,t=e.max;return t&&t.length>0?o()(t,v).toDate():void 0}}get initialValue(){const e=this.props.widgetMgr.getStringArrayValue(this.props.element);return b(void 0!==e?e:this.props.element.default||[])}componentDidMount(){this.props.element.setValue?this.updateFromProtobuf():this.commitWidgetValue({fromUi:!1})}componentDidUpdate(){this.maybeUpdateFromProtobuf()}componentWillUnmount(){this.formClearHelper.disconnect()}maybeUpdateFromProtobuf(){const{setValue:e}=this.props.element;e&&this.updateFromProtobuf()}updateFromProtobuf(){const{value:e}=this.props.element;this.props.element.setValue=!1;const t=e.map((e=>new Date(e)));this.setState({values:t,isEmpty:!t},(()=>{this.commitWidgetValue({fromUi:!1})}))}render(){var e;const{width:t,element:s,disabled:i,theme:r,widgetMgr:a}=this.props,{values:m,isRange:b}=this.state,{colors:y,fontSizes:C,lineHeights:W,spacing:I}=r,S={width:t},D=o()(s.min,v).toDate(),F=this.getMaxDate(),L=0===s.default.length&&!i,V=s.format.replaceAll(/[a-zA-Z]/g,"9"),x=s.format.replaceAll("Y","y").replaceAll("D","d");return this.formClearHelper.manageFormClearListener(a,s.formId,this.onFormCleared),(0,f.jsxs)("div",{className:"stDateInput","data-testid":"stDateInput",style:S,children:[(0,f.jsx)(p.L,{label:s.label,disabled:i,labelVisibility:(0,g.yv)(null===(e=s.labelVisibility)||void 0===e?void 0:e.value),children:s.help&&(0,f.jsx)(h.j,{children:(0,f.jsx)(c.A,{content:s.help,placement:u.W.TOP_RIGHT})})}),(0,f.jsx)(n.A,{density:l.fY.high,formatString:x,mask:b?`${V} \u2013 ${V}`:V,placeholder:b?`${s.format} \u2013 ${s.format}`:s.format,disabled:i,onChange:this.handleChange,onClose:this.handleClose,overrides:{Popover:{props:{placement:d.El.bottomLeft,overrides:{Body:{style:{border:`${r.sizes.borderWidth} solid ${y.borderColor}`}}}}},CalendarContainer:{style:{fontSize:C.sm,paddingRight:r.spacing.sm,paddingLeft:r.spacing.sm,paddingBottom:r.spacing.sm,paddingTop:r.spacing.sm}},Week:{style:{fontSize:C.sm}},Day:{style:e=>{let{$pseudoHighlighted:t,$pseudoSelected:s,$selected:i,$isHovered:r}=e;return{fontSize:C.sm,lineHeight:W.base,"::before":{backgroundColor:i||s||t||r?`${y.secondaryBg} !important`:y.transparent},"::after":{borderColor:y.transparent}}}},PrevButton:{style:()=>({display:"flex",alignItems:"center",justifyContent:"center",":active":{backgroundColor:y.transparent},":focus":{backgroundColor:y.transparent,outline:0}})},NextButton:{style:{display:"flex",alignItems:"center",justifyContent:"center",":active":{backgroundColor:y.transparent},":focus":{backgroundColor:y.transparent,outline:0}}},Input:{props:{maskChar:null,overrides:{Root:{style:{borderLeftWidth:r.sizes.borderWidth,borderRightWidth:r.sizes.borderWidth,borderTopWidth:r.sizes.borderWidth,borderBottomWidth:r.sizes.borderWidth,paddingRight:r.spacing.twoXS}},ClearIcon:{props:{overrides:{Svg:{style:{color:r.colors.darkGray,padding:r.spacing.threeXS,height:r.sizes.clearIconSize,width:r.sizes.clearIconSize,":hover":{fill:r.colors.bodyText}}}}}},Input:{style:{paddingRight:I.sm,paddingLeft:I.sm,paddingBottom:I.sm,paddingTop:I.sm,lineHeight:W.inputWidget},props:{"data-testid":"stDateInputField"}}}}}},value:m,minDate:D,maxDate:F,range:b,clearable:L})]})}}const C=(0,a.b)(y)},34752:(e,t,s)=>{s.d(t,{X:()=>a,o:()=>o});var i=s(58878),r=s(25571);class o{constructor(){this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}manageFormClearListener(e,t,s){(0,r.se)(this.formClearListener)&&this.lastWidgetMgr===e&&this.lastFormId===t||(this.disconnect(),(0,r._L)(t)&&(this.formClearListener=e.addFormClearedListener(t,s),this.lastWidgetMgr=e,this.lastFormId=t))}disconnect(){var e;null===(e=this.formClearListener)||void 0===e||e.disconnect(),this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}}function a(e){let{element:t,widgetMgr:s,onFormCleared:o}=e;(0,i.useEffect)((()=>{if(!(0,r._L)(t.formId))return;const e=s.addFormClearedListener(t.formId,o);return()=>{e.disconnect()}}),[t,s,o])}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[7193],{17193:(e,t,r)=>{r.r(t),r.d(t,{default:()=>m});var a=r(58878),l=r(42637),i=r(25571),o=r(3101),d=r(90782);const n=(e,t)=>e.getStringValue(t),s=e=>{var t;return null!==(t=e.default)&&void 0!==t?t:null},g=e=>{var t;return null!==(t=e.value)&&void 0!==t?t:null},u=(e,t,r,a)=>{t.setStringValue(e,r.value,{fromUi:r.fromUi},a)},m=e=>{var t;let{element:r,disabled:m,widgetMgr:f,width:v,fragmentId:c}=e;const[h,C]=(0,o.t)({getStateFromWidgetMgr:n,getDefaultStateFromProto:s,getCurrStateFromProto:g,updateWidgetMgrState:u,element:r,widgetMgr:f,fragmentId:c}),F=(0,a.useCallback)((e=>{C({value:e,fromUi:!0})}),[C]);return(0,d.jsx)(l.A,{label:r.label,labelVisibility:(0,i.yv)(null===(t=r.labelVisibility)||void 0===t?void 0:t.value),help:r.help,onChange:F,disabled:m,width:v,value:h})}},34752:(e,t,r)=>{r.d(t,{X:()=>o,o:()=>i});var a=r(58878),l=r(25571);class i{constructor(){this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}manageFormClearListener(e,t,r){(0,l.se)(this.formClearListener)&&this.lastWidgetMgr===e&&this.lastFormId===t||(this.disconnect(),(0,l._L)(t)&&(this.formClearListener=e.addFormClearedListener(t,r),this.lastWidgetMgr=e,this.lastFormId=t))}disconnect(){var e;null===(e=this.formClearListener)||void 0===e||e.disconnect(),this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}}function o(e){let{element:t,widgetMgr:r,onFormCleared:i}=e;(0,a.useEffect)((()=>{if(!(0,l._L)(t.formId))return;const e=r.addFormClearedListener(t.formId,i);return()=>{e.disconnect()}}),[t,r,i])}},3101:(e,t,r)=>{r.d(t,{_:()=>o,t:()=>d});var a=r(58878),l=r(34752),i=r(25571);function o(e){let{getStateFromWidgetMgr:t,getDefaultState:r,updateWidgetMgrState:o,element:d,widgetMgr:n,fragmentId:s,onFormCleared:g}=e;const[u,m]=(0,a.useState)((()=>{var e;return null!==(e=t(n,d))&&void 0!==e?e:r(n,d)})),[f,v]=(0,a.useState)({value:u,fromUi:!1});(0,a.useEffect)((()=>{(0,i.hX)(f)||(v(null),m(f.value),o(d,n,f,s))}),[f,o,d,n,s]);const c=(0,a.useCallback)((()=>{v({value:r(n,d),fromUi:!0}),null===g||void 0===g||g()}),[v,d,r,n,g]);return(0,l.X)({widgetMgr:n,element:d,onFormCleared:c}),[u,v]}function d(e){let{getStateFromWidgetMgr:t,getDefaultStateFromProto:r,getCurrStateFromProto:l,updateWidgetMgrState:i,element:d,widgetMgr:n,fragmentId:s,onFormCleared:g}=e;const u=(0,a.useCallback)(((e,t)=>r(t)),[r]),[m,f]=o({getStateFromWidgetMgr:t,getDefaultState:u,updateWidgetMgrState:i,element:d,widgetMgr:n,fragmentId:s,onFormCleared:g});return(0,a.useEffect)((()=>{d.setValue&&(d.setValue=!1,f({value:l(d),fromUi:!1}))}),[d,l,f]),[m,f]}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[9114],{34752:(e,t,i)=>{i.d(t,{X:()=>o,o:()=>r});var s=i(58878),n=i(25571);class r{constructor(){this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}manageFormClearListener(e,t,i){(0,n.se)(this.formClearListener)&&this.lastWidgetMgr===e&&this.lastFormId===t||(this.disconnect(),(0,n._L)(t)&&(this.formClearListener=e.addFormClearedListener(t,i),this.lastWidgetMgr=e,this.lastFormId=t))}disconnect(){var e;null===(e=this.formClearListener)||void 0===e||e.disconnect(),this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}}function o(e){let{element:t,widgetMgr:i,onFormCleared:r}=e;(0,s.useEffect)((()=>{if(!(0,n._L)(t.formId))return;const e=i.addFormClearedListener(t.formId,r);return()=>{e.disconnect()}}),[t,i,r])}},79114:(e,t,i)=>{i.r(t),i.d(t,{default:()=>F});var s=i(58878),n=i(97757),r=i.n(n),o=i(90847),a=i(8151),l=i(34694),d=i(17643),h=i.n(d),m=i(34752),u=i(29669),c=i(25571),g=i(70474),p=i(78286),f=i(93480),b=i(997),v=i(89653),y=i(32735);const T=(0,v.A)("div",{target:"ew7r33m3"})((e=>{let{disabled:t,theme:i}=e;return{alignItems:"center",backgroundColor:t?i.colors.gray:i.colors.primary,borderTopLeftRadius:"100%",borderTopRightRadius:"100%",borderBottomLeftRadius:"100%",borderBottomRightRadius:"100%",borderTopStyle:"none",borderBottomStyle:"none",borderRightStyle:"none",borderLeftStyle:"none",boxShadow:"none",display:"flex",justifyContent:"center",height:i.sizes.sliderThumb,width:i.sizes.sliderThumb,":focus":{outline:"none"},":focus-visible":{boxShadow:`0 0 0 0.2rem ${(0,y.No)(i.colors.primary,.5)}`}}}),""),C=(0,v.A)("div",{target:"ew7r33m2"})((e=>{let{disabled:t,theme:i}=e;return{fontFamily:i.genericFonts.codeFont,fontSize:i.fontSizes.sm,color:t?i.colors.gray:i.colors.primary,top:"-1.6em",position:"absolute",whiteSpace:"nowrap",backgroundColor:i.colors.transparent,lineHeight:i.lineHeights.base,fontWeight:i.fontWeights.normal}}),""),R=(0,v.A)("div",{target:"ew7r33m1"})((e=>{let{theme:t}=e;return{fontSize:t.fontSizes.sm,paddingBottom:t.spacing.none,paddingLeft:t.spacing.none,paddingRight:t.spacing.none,paddingTop:"0.65em",justifyContent:"space-between",alignItems:"center",display:"flex"}}),""),V=(0,v.A)("div",{target:"ew7r33m0"})((e=>{let{disabled:t,theme:i}=e;return{lineHeight:i.lineHeights.base,fontWeight:i.fontWeights.normal,fontFamily:i.genericFonts.codeFont,color:t?i.colors.fadedText40:"inherit"}}),"");var w=i(90782);class x extends s.PureComponent{constructor(e){super(e),this.formClearHelper=new m.o,this.state=void 0,this.sliderRef=s.createRef(),this.thumbRef=[],this.thumbValueRef=[],this.commitWidgetValueDebounced=void 0,this.commitWidgetValue=e=>{const{widgetMgr:t,element:i,fragmentId:s}=this.props;t.setDoubleArrayValue(i,this.state.value,e,s)},this.onFormCleared=()=>{this.setState(((e,t)=>({value:t.element.default})),(()=>this.commitWidgetValue({fromUi:!0})))},this.handleChange=e=>{let{value:t}=e;this.setState({value:t},(()=>this.commitWidgetValueDebounced({fromUi:!0})))},this.renderThumb=s.forwardRef(((e,t)=>{const{$value:i,$thumbIndex:n}=e,o=n||0;this.thumbRef[o]=t,this.thumbValueRef[o]||=s.createRef();const a=i?this.formatValue(i[n]):"",l=r()(e,["role","style","aria-valuemax","aria-valuemin","aria-valuenow","tabIndex","onKeyUp","onKeyDown","onMouseEnter","onMouseLeave","draggable"]),d={};return(this.props.element.options.length>0||this.isDateTimeType())&&(d["aria-valuetext"]=a),(0,w.jsx)(T,{...l,disabled:!0===e.$disabled,ref:this.thumbRef[o],"aria-valuetext":a,"aria-label":this.props.element.label,children:(0,w.jsx)(C,{"data-testid":"stSliderThumbValue",disabled:!0===e.$disabled,ref:this.thumbValueRef[o],children:a})})})),this.renderTickBar=()=>{const{disabled:e,element:t}=this.props,{max:i,min:s}=t;return(0,w.jsxs)(R,{"data-testid":"stSliderTickBar",children:[(0,w.jsx)(V,{disabled:e,"data-testid":"stSliderTickBarMin",children:this.formatValue(s)}),(0,w.jsx)(V,{disabled:e,"data-testid":"stSliderTickBarMax",children:this.formatValue(i)})]})},this.commitWidgetValueDebounced=(0,c.sg)(200,this.commitWidgetValue.bind(this)),this.state={value:this.initialValue}}get initialValue(){const e=this.props.widgetMgr.getDoubleArrayValue(this.props.element);return void 0!==e?e:this.props.element.default}componentDidMount(){setTimeout((()=>{this.thumbValueAlignment()}),0),this.props.element.setValue?this.updateFromProtobuf():this.commitWidgetValue({fromUi:!1})}componentDidUpdate(){this.maybeUpdateFromProtobuf()}componentWillUnmount(){this.formClearHelper.disconnect()}maybeUpdateFromProtobuf(){const{setValue:e}=this.props.element;e&&this.updateFromProtobuf()}updateFromProtobuf(){const{value:e}=this.props.element;this.props.element.setValue=!1,this.setState({value:e},(()=>{this.commitWidgetValue({fromUi:!1})}))}get value(){const{min:e,max:t}=this.props.element,{value:i}=this.state;let s=i[0],n=i.length>1?i[1]:i[0];return s>n&&(s=n),s<e&&(s=e),s>t&&(s=t),n<e&&(n=e),n>t&&(n=t),i.length>1?[s,n]:[s]}isDateTimeType(){const{dataType:e}=this.props.element;return e===u.Ap.DataType.DATETIME||e===u.Ap.DataType.DATE||e===u.Ap.DataType.TIME}formatValue(e){const{format:t,options:i}=this.props.element;return this.isDateTimeType()?h().utc(e/1e3).format(t):i.length>0?(0,l.sprintf)(t,i[e]):(0,l.sprintf)(t,e)}alignValueOnThumb(e,t,i){if(e&&t&&i){const s=e.getBoundingClientRect(),n=t.getBoundingClientRect(),r=i.getBoundingClientRect(),o=n.left+n.width/2,a=o-r.width/2<s.left,l=o+r.width/2>s.right;i.style.left=a?"0":"",i.style.right=l?"0":""}}thumbValueAlignment(){var e,t,i,s;const n=this.sliderRef.current,r=null===(e=this.thumbRef[0])||void 0===e?void 0:e.current,o=null===(t=this.thumbRef[1])||void 0===t?void 0:t.current,a=null===(i=this.thumbValueRef[0])||void 0===i?void 0:i.current,l=null===(s=this.thumbValueRef[1])||void 0===s?void 0:s.current;if(this.alignValueOnThumb(n,r,a),this.alignValueOnThumb(n,o,l),n&&r&&o&&a&&l){const e=n.getBoundingClientRect(),t=r.getBoundingClientRect(),i=o.getBoundingClientRect(),s=a.getBoundingClientRect(),d=l.getBoundingClientRect();if(s.right+16>d.left){d.left-16-s.width>e.left?a.style.right=d.width+16-(i.right-t.right)+"px":l.style.left=s.width+16-(i.left-t.left)+"px"}}}render(){var e;const{disabled:t,element:i,theme:s,width:n,widgetMgr:r}=this.props,{colors:a,fonts:l,fontSizes:d,spacing:h}=s,m={width:n};return this.formClearHelper.manageFormClearListener(r,i.formId,this.onFormCleared),this.thumbValueAlignment(),(0,w.jsxs)("div",{ref:this.sliderRef,className:"stSlider","data-testid":"stSlider",style:m,children:[(0,w.jsx)(g.L,{label:i.label,disabled:t,labelVisibility:(0,c.yv)(null===(e=i.labelVisibility)||void 0===e?void 0:e.value),children:i.help&&(0,w.jsx)(p.j,{children:(0,w.jsx)(f.A,{content:i.help,placement:b.W.TOP_RIGHT})})}),(0,w.jsx)(o.A,{min:i.min,max:i.max,step:i.step,value:this.value,onChange:this.handleChange,disabled:t,overrides:{Thumb:this.renderThumb,Tick:{style:{fontFamily:l.monospace}},Track:{style:{backgroundColor:"none !important",paddingBottom:h.none,paddingLeft:h.none,paddingRight:h.none,paddingTop:`calc(${d.sm} * 1.35)`}},InnerTrack:{style:e=>{let{$disabled:t}=e;return{height:h.twoXS,...t?{background:a.darkenedBgMix25}:{}}}},TickBar:this.renderTickBar}})]})}}const F=(0,a.b)(x)}}]);
@@ -1,5 +0,0 @@
1
- "use strict";(self.webpackChunk_streamlit_app=self.webpackChunk_streamlit_app||[]).push([[954],{68035:(e,t,r)=>{r.d(t,{A:()=>d});r(58878);var o=r(25571),i=r(78286),n=r(89653);const l=r(60667).i7`
2
- 50% {
3
- color: rgba(0, 0, 0, 0);
4
- }
5
- `,a=(0,n.A)("span",{target:"edlqvik0"})((e=>{let{includeDot:t,shouldBlink:r,theme:o}=e;return{...t?{"&::before":{opacity:1,content:'"\u2022"',animation:"none",color:o.colors.gray,margin:`0 ${o.spacing.twoXS}`}}:{},...r?{color:o.colors.red,animationName:`${l}`,animationDuration:"0.5s",animationIterationCount:5}:{}}}),"");var s=r(90782);const d=e=>{let{dirty:t,value:r,inForm:n,maxLength:l,className:d,type:u="single",allowEnterToSubmit:c=!0}=e;const p=[],m=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];p.push((0,s.jsx)(a,{includeDot:p.length>0,shouldBlink:t,children:e},p.length))};if(c){const e=n?"submit form":"apply";if("multiline"===u){m(`Press ${(0,o.u_)()?"\u2318":"Ctrl"}+Enter to ${e}`)}else"single"===u&&m(`Press Enter to ${e}`)}return l&&("chat"!==u||t)&&m(`${r.length}/${l}`,t&&r.length>=l),(0,s.jsx)(i.tp,{"data-testid":"InputInstructions",className:d,children:p})}},34752:(e,t,r)=>{r.d(t,{X:()=>l,o:()=>n});var o=r(58878),i=r(25571);class n{constructor(){this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}manageFormClearListener(e,t,r){(0,i.se)(this.formClearListener)&&this.lastWidgetMgr===e&&this.lastFormId===t||(this.disconnect(),(0,i._L)(t)&&(this.formClearListener=e.addFormClearedListener(t,r),this.lastWidgetMgr=e,this.lastFormId=t))}disconnect(){var e;null===(e=this.formClearListener)||void 0===e||e.disconnect(),this.formClearListener=void 0,this.lastWidgetMgr=void 0,this.lastFormId=void 0}}function l(e){let{element:t,widgetMgr:r,onFormCleared:n}=e;(0,o.useEffect)((()=>{if(!(0,i._L)(t.formId))return;const e=r.addFormClearedListener(t.formId,n);return()=>{e.disconnect()}}),[t,r,n])}},10954:(e,t,r)=>{r.r(t),r.d(t,{default:()=>D});var o=r(58878),i=r(27774),n=r(94388),l=r(8151),a=r(34694),s=r(59095),d=r(32698),u=r.n(d),c=r(25571),p=r(34752),m=r(84996),h=r(29669),g=r(93480),b=r(997),f=r(64611),v=r(68035),y=r(70474),I=r(78286),w=r(89653);const C=(0,w.A)("div",{target:"e116k4er3"})((e=>{let{theme:t}=e;return{display:"flex",flexDirection:"row",flexWrap:"nowrap",alignItems:"center",height:t.sizes.minElementHeight,borderWidth:t.sizes.borderWidth,borderStyle:"solid",borderColor:t.colors.widgetBorderColor||t.colors.widgetBackgroundColor||t.colors.bgColor,transitionDuration:"200ms",transitionProperty:"border",transitionTimingFunction:"cubic-bezier(0.2, 0.8, 0.4, 1)",borderRadius:t.radii.default,overflow:"hidden","&.focused":{borderColor:t.colors.primary},input:{MozAppearance:"textfield","&::-webkit-inner-spin-button, &::-webkit-outer-spin-button":{WebkitAppearance:"none",margin:t.spacing.none}}}}),""),T=(0,w.A)("div",{target:"e116k4er2"})({name:"76z9jo",styles:"display:flex;flex-direction:row;align-self:stretch"}),x=(0,w.A)("button",{target:"e116k4er1"})((e=>{let{theme:t}=e;return{margin:t.spacing.none,border:"none",height:t.sizes.full,display:"flex",alignItems:"center",width:"32px",justifyContent:"center",color:t.colors.bodyText,transition:"color 300ms, backgroundColor 300ms",backgroundColor:t.colors.widgetBackgroundColor||t.colors.secondaryBg,"&:hover:enabled, &:focus:enabled":{color:t.colors.white,backgroundColor:t.colors.primary,transition:"none",outline:"none"},"&:active":{outline:"none",border:"none"},"&:last-of-type":{borderTopRightRadius:t.radii.default,borderBottomRightRadius:t.radii.default},"&:disabled":{cursor:"not-allowed",color:t.colors.fadedText40}}}),""),k=(0,w.A)("div",{target:"e116k4er0"})((e=>{let{theme:t,clearable:r}=e;return{position:"absolute",marginRight:t.spacing.twoXS,left:0,right:64+(r?12:0)+"px"}}),"");var F=r(90782);const R=e=>{let{step:t,dataType:r}=e;return t||(r===h.Q7.DataType.INT?1:.01)},S=e=>{let{value:t,format:r,step:o,dataType:i}=e;if((0,c.hX)(t))return null;let n=function(e){return(0,c.hX)(e)||""===e?void 0:e}(r);if((0,c.hX)(n)&&(0,c.se)(o)){const e=o.toString();if(i===h.Q7.DataType.FLOAT&&0!==o&&e.includes(".")){n=`%0.${e.split(".")[1].length}f`}}if((0,c.hX)(n))return t.toString();try{return(0,a.sprintf)(n,t)}catch(l){return(0,m.FF)(`Error in sprintf(${n}, ${t}): ${l}`),String(t)}},D=(0,l.b)((e=>{var t;let{disabled:r,element:l,widgetMgr:a,width:d,theme:m,fragmentId:w}=e;const{dataType:D,id:j,formId:A,default:L,format:N}=l,W=l.hasMin?l.min:-1/0,E=l.hasMax?l.max:1/0,[M,z]=o.useState(R(l)),B=(e=>{var t;const r=e.element.dataType===h.Q7.DataType.INT?e.widgetMgr.getIntValue(e.element):e.widgetMgr.getDoubleValue(e.element);return null!==(t=null!==r&&void 0!==r?r:e.element.default)&&void 0!==t?t:null})({element:l,widgetMgr:a}),[X,$]=o.useState(!1),[V,_]=o.useState(B),[U,Q]=o.useState(S({value:B,...l,step:M})),[H,P]=o.useState(!1),O=o.useRef(null),G=o.useRef(new p.o),K=o.useRef(u()("number_input_")),q=((e,t,r)=>!(0,c.hX)(e)&&e-t>=r)(V,M,W),J=((e,t,r)=>!(0,c.hX)(e)&&e+t<=r)(V,M,E),Y=(0,c.Ml)({formId:A}),Z=Y?a.allowFormEnterToSubmit(A):X,ee=H&&d>m.breakpoints.hideWidgetDetails;o.useEffect((()=>{z(R({step:l.step,dataType:l.dataType}))}),[l.dataType,l.step]);const te=o.useCallback((e=>{let{value:t,source:r}=e;if((0,c.se)(t)&&(W>t||t>E)){var o;null===(o=O.current)||void 0===o||o.reportValidity()}else{var i;const e=null!==(i=null!==t&&void 0!==t?t:L)&&void 0!==i?i:null;switch(D){case h.Q7.DataType.INT:a.setIntValue({id:j,formId:A},e,r,w);break;case h.Q7.DataType.FLOAT:a.setDoubleValue({id:j,formId:A},e,r,w);break;default:throw new Error("Invalid data type")}$(!1),_(e),Q(S({value:e,dataType:D,format:N,step:M}))}}),[W,E,O,a,w,M,D,j,A,L,N]),re=()=>{const{value:e}=l;l.setValue=!1,_(null!==e&&void 0!==e?e:null),Q(S({value:null!==e&&void 0!==e?e:null,...l,step:M})),te({value:null!==e&&void 0!==e?e:null,source:{fromUi:!1}})};o.useEffect((()=>{const e=G.current;return l.setValue?re():te({value:V,source:{fromUi:!1}}),()=>{e.disconnect()}}),[]),l.setValue&&re();const oe=(0,c.hX)(l.default)&&!r;G.current.manageFormClearListener(a,l.formId,(()=>{var e;_(null!==(e=l.default)&&void 0!==e?e:null),te({value:V,source:{fromUi:!0}})}));const ie=o.useCallback((()=>{J&&($(!0),te({value:(null!==V&&void 0!==V?V:W)+M,source:{fromUi:!0}}))}),[V,W,M,J]),ne=o.useCallback((()=>{q&&($(!0),te({value:(null!==V&&void 0!==V?V:E)-M,source:{fromUi:!0}}))}),[V,E,M,q]),le=o.useCallback((e=>{const{key:t}=e;switch(t){case"ArrowUp":e.preventDefault(),ie();break;case"ArrowDown":e.preventDefault(),ne()}}),[ie,ne]),ae=o.useCallback((e=>{"Enter"===e.key&&(X&&te({value:V,source:{fromUi:!0}}),a.allowFormEnterToSubmit(A)&&a.submitForm(A,w))}),[X,V,te,a,A,w]);return(0,F.jsxs)("div",{className:"stNumberInput","data-testid":"stNumberInput",style:{width:d},children:[(0,F.jsx)(y.L,{label:l.label,disabled:r,labelVisibility:(0,c.yv)(null===(t=l.labelVisibility)||void 0===t?void 0:t.value),htmlFor:K.current,children:l.help&&(0,F.jsx)(I.j,{children:(0,F.jsx)(g.A,{content:l.help,placement:b.W.TOP_RIGHT})})}),(0,F.jsxs)(C,{className:H?"focused":"","data-testid":"stNumberInputContainer",children:[(0,F.jsx)(s.A,{type:"number",inputRef:O,value:null!==U&&void 0!==U?U:"",placeholder:l.placeholder,onBlur:()=>(X&&te({value:V,source:{fromUi:!0}}),void P(!1)),onFocus:()=>{P(!0)},onChange:e=>(e=>{const{value:t}=e.target;if(""===t)$(!0),_(null),Q(null);else{let e;e=l.dataType===h.Q7.DataType.INT?parseInt(t,10):parseFloat(t),$(!0),_(e),Q(t)}})(e),onKeyPress:e=>ae(e),onKeyDown:e=>le(e),clearable:oe,clearOnEscape:oe,disabled:r,"aria-label":l.label,id:K.current,overrides:{ClearIconContainer:{style:{padding:0}},ClearIcon:{props:{overrides:{Svg:{style:{color:m.colors.darkGray,padding:m.spacing.threeXS,height:m.sizes.clearIconSize,width:m.sizes.clearIconSize,":hover":{fill:m.colors.bodyText}}}}}},Input:{props:{"data-testid":"stNumberInputField",step:M,min:W,max:E},style:{lineHeight:m.lineHeights.inputWidget,paddingRight:m.spacing.sm,paddingLeft:m.spacing.sm,paddingBottom:m.spacing.sm,paddingTop:m.spacing.sm}},InputContainer:{style:()=>({borderTopRightRadius:0,borderBottomRightRadius:0})},Root:{style:{borderTopRightRadius:0,borderBottomRightRadius:0,borderLeftWidth:0,borderRightWidth:0,borderTopWidth:0,borderBottomWidth:0,paddingRight:0}}}}),d>m.breakpoints.hideNumberInputControls&&(0,F.jsxs)(T,{children:[(0,F.jsx)(x,{"data-testid":"stNumberInputStepDown",onClick:ne,disabled:!q||r,tabIndex:-1,children:(0,F.jsx)(f.A,{content:i.H,size:"xs",color:q?"inherit":"disabled"})}),(0,F.jsx)(x,{"data-testid":"stNumberInputStepUp",onClick:ie,disabled:!J||r,tabIndex:-1,children:(0,F.jsx)(f.A,{content:n.F,size:"xs",color:J?"inherit":"disabled"})})]})]}),ee&&(0,F.jsx)(k,{clearable:oe,children:(0,F.jsx)(v.A,{dirty:X,value:null!==U&&void 0!==U?U:"",inForm:Y,allowEnterToSubmit:Z})})]})}))}}]);