lightly-studio 0.3.2__py3-none-any.whl → 0.3.4__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.

Potentially problematic release.


This version of lightly-studio might be problematic. Click here for more details.

Files changed (163) hide show
  1. lightly_studio/__init__.py +1 -1
  2. lightly_studio/api/app.py +8 -4
  3. lightly_studio/api/db_tables.py +0 -3
  4. lightly_studio/api/routes/api/annotation.py +26 -0
  5. lightly_studio/api/routes/api/annotations/__init__.py +7 -0
  6. lightly_studio/api/routes/api/annotations/create_annotation.py +52 -0
  7. lightly_studio/api/routes/api/caption.py +30 -0
  8. lightly_studio/api/routes/api/dataset.py +3 -5
  9. lightly_studio/api/routes/api/embeddings2d.py +136 -0
  10. lightly_studio/api/routes/api/export.py +73 -0
  11. lightly_studio/api/routes/api/metadata.py +57 -1
  12. lightly_studio/api/routes/api/selection.py +87 -0
  13. lightly_studio/core/add_samples.py +138 -9
  14. lightly_studio/core/dataset.py +174 -63
  15. lightly_studio/core/dataset_query/dataset_query.py +5 -0
  16. lightly_studio/dataset/env.py +4 -0
  17. lightly_studio/dataset/file_utils.py +13 -2
  18. lightly_studio/dataset/loader.py +2 -62
  19. lightly_studio/dataset/mobileclip_embedding_generator.py +3 -2
  20. lightly_studio/db_manager.py +10 -4
  21. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/0.B3oFNb6O.css +1 -0
  22. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/2.CkOblLn7.css +1 -0
  23. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/Samples.CIbricz7.css +1 -0
  24. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/_layout.7Ma7YdVg.css +1 -0
  25. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/{useFeatureFlags.CV-KWLNP.css → _layout.CefECEWA.css} +1 -1
  26. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/transform.2jKMtOWG.css +1 -0
  27. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/-DXuGN29.js +1 -0
  28. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/{Ccq4ZD0B.js → B7302SU7.js} +1 -1
  29. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/BeWf8-vJ.js +1 -0
  30. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Bqz7dyEC.js +1 -0
  31. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/C1FmrZbK.js +1 -0
  32. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/{DRZO-E-T.js → CSCQddQS.js} +1 -1
  33. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/CZGpyrcA.js +1 -0
  34. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/CfQ4mGwl.js +1 -0
  35. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/CiaNZCBa.js +1 -0
  36. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Cqo0Vpvt.js +417 -0
  37. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Cy4fgWTG.js +1 -0
  38. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/D5w4xp5l.js +1 -0
  39. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DD63uD-T.js +1 -0
  40. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DQ8aZ1o-.js +3 -0
  41. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/{Df3aMO5B.js → DSxvnAMh.js} +1 -1
  42. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/D_JuJOO3.js +20 -0
  43. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/D_ynJAfY.js +2 -0
  44. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Dafy4oEQ.js +1 -0
  45. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/{BqBqV92V.js → Dj4O-5se.js} +1 -1
  46. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DmjAI-UV.js +1 -0
  47. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Dug7Bq1S.js +1 -0
  48. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Dv5BSBQG.js +1 -0
  49. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DzBTnFhV.js +1 -0
  50. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DzX_yyqb.js +1 -0
  51. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Frwd2CjB.js +1 -0
  52. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/H4l0JFh9.js +1 -0
  53. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/H60ATh8g.js +2 -0
  54. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/qIv1kPyv.js +1 -0
  55. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/sLqs1uaK.js +20 -0
  56. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/u-it74zV.js +96 -0
  57. lightly_studio/dist_lightly_studio_view_app/_app/immutable/entry/app.BPc0HQPq.js +2 -0
  58. lightly_studio/dist_lightly_studio_view_app/_app/immutable/entry/start.SNvc2nrm.js +1 -0
  59. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/0.5jT7P06o.js +1 -0
  60. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/1.Cdy-7S5q.js +1 -0
  61. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/10.C_uoESTX.js +1 -0
  62. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/12.DcO8wIAc.js +1 -0
  63. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/2.BIldfkxL.js +1012 -0
  64. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/{3.w9g4AcAx.js → 3.BC9z_TWM.js} +1 -1
  65. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/{4.BBI8KwnD.js → 4.D8X_Ch5n.js} +1 -1
  66. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/5.CAXhxJu6.js +39 -0
  67. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/{6.CrbkRPam.js → 6.DRA5Ru_2.js} +1 -1
  68. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/7.WVBsruHQ.js +1 -0
  69. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/8.BuKUrCEN.js +20 -0
  70. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/9.CUIn1yCR.js +1 -0
  71. lightly_studio/dist_lightly_studio_view_app/_app/immutable/workers/clustering.worker-DKqeLtG0.js +2 -0
  72. lightly_studio/dist_lightly_studio_view_app/_app/immutable/workers/search.worker-vNSty3B0.js +1 -0
  73. lightly_studio/dist_lightly_studio_view_app/_app/version.json +1 -1
  74. lightly_studio/dist_lightly_studio_view_app/index.html +15 -14
  75. lightly_studio/examples/example.py +4 -0
  76. lightly_studio/examples/example_coco.py +4 -0
  77. lightly_studio/examples/example_coco_caption.py +24 -0
  78. lightly_studio/examples/example_metadata.py +4 -1
  79. lightly_studio/examples/example_selection.py +4 -0
  80. lightly_studio/examples/example_split_work.py +4 -0
  81. lightly_studio/examples/example_yolo.py +4 -0
  82. lightly_studio/export/export_dataset.py +73 -0
  83. lightly_studio/export/lightly_studio_label_input.py +120 -0
  84. lightly_studio/few_shot_classifier/classifier_manager.py +5 -26
  85. lightly_studio/metadata/compute_typicality.py +67 -0
  86. lightly_studio/models/annotation/annotation_base.py +11 -12
  87. lightly_studio/models/caption.py +73 -0
  88. lightly_studio/models/dataset.py +1 -2
  89. lightly_studio/models/metadata.py +1 -1
  90. lightly_studio/models/sample.py +2 -2
  91. lightly_studio/resolvers/annotation_label_resolver/__init__.py +2 -1
  92. lightly_studio/resolvers/annotation_label_resolver/get_all.py +15 -0
  93. lightly_studio/resolvers/annotation_resolver/__init__.py +2 -3
  94. lightly_studio/resolvers/annotation_resolver/create_many.py +3 -3
  95. lightly_studio/resolvers/annotation_resolver/delete_annotation.py +1 -1
  96. lightly_studio/resolvers/annotation_resolver/delete_annotations.py +7 -3
  97. lightly_studio/resolvers/annotation_resolver/get_by_id.py +19 -1
  98. lightly_studio/resolvers/annotation_resolver/update_annotation_label.py +0 -1
  99. lightly_studio/resolvers/annotations/annotations_filter.py +1 -11
  100. lightly_studio/resolvers/caption_resolver.py +80 -0
  101. lightly_studio/resolvers/dataset_resolver.py +4 -7
  102. lightly_studio/resolvers/metadata_resolver/__init__.py +2 -2
  103. lightly_studio/resolvers/metadata_resolver/sample/__init__.py +3 -3
  104. lightly_studio/resolvers/metadata_resolver/sample/bulk_update_metadata.py +46 -0
  105. lightly_studio/resolvers/samples_filter.py +18 -10
  106. lightly_studio/selection/mundig.py +7 -10
  107. lightly_studio/selection/selection_config.py +4 -1
  108. lightly_studio/services/annotations_service/__init__.py +8 -0
  109. lightly_studio/services/annotations_service/create_annotation.py +63 -0
  110. lightly_studio/services/annotations_service/delete_annotation.py +22 -0
  111. lightly_studio/type_definitions.py +2 -0
  112. {lightly_studio-0.3.2.dist-info → lightly_studio-0.3.4.dist-info}/METADATA +231 -41
  113. {lightly_studio-0.3.2.dist-info → lightly_studio-0.3.4.dist-info}/RECORD +114 -104
  114. lightly_studio/api/routes/api/annotation_task.py +0 -37
  115. lightly_studio/api/routes/api/metrics.py +0 -76
  116. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/0.DenzbfeK.css +0 -1
  117. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/SelectableSvgGroup.BBm0IWdq.css +0 -1
  118. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/SelectableSvgGroup.BNTuXSAe.css +0 -1
  119. lightly_studio/dist_lightly_studio_view_app/_app/immutable/assets/_layout.T-zjSUd3.css +0 -1
  120. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/2O287xak.js +0 -3
  121. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/7YNGEs1C.js +0 -1
  122. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/BBoGk9hq.js +0 -1
  123. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/BRnH9v23.js +0 -92
  124. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Bg1Y5eUZ.js +0 -1
  125. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/C0JiMuYn.js +0 -1
  126. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/C98Hk3r5.js +0 -1
  127. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/CG0dMCJi.js +0 -1
  128. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Cpy-nab_.js +0 -1
  129. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Crk-jcvV.js +0 -1
  130. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Cs31G8Qn.js +0 -1
  131. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/CsKrY2zA.js +0 -1
  132. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/Cur71c3O.js +0 -1
  133. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/CzgC3GFB.js +0 -1
  134. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/D8GZDMNN.js +0 -1
  135. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DFRh-Spp.js +0 -1
  136. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DcGCxgpH.js +0 -1
  137. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DkR_EZ_B.js +0 -1
  138. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/DqUGznj_.js +0 -1
  139. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/H7C68rOM.js +0 -1
  140. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/KpAtIldw.js +0 -1
  141. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/M1Q1F7bw.js +0 -4
  142. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/OH7-C_mc.js +0 -1
  143. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/gLNdjSzu.js +0 -1
  144. lightly_studio/dist_lightly_studio_view_app/_app/immutable/chunks/i0ZZ4z06.js +0 -1
  145. lightly_studio/dist_lightly_studio_view_app/_app/immutable/entry/app.BI-EA5gL.js +0 -2
  146. lightly_studio/dist_lightly_studio_view_app/_app/immutable/entry/start.CcsRl3cZ.js +0 -1
  147. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/0.BbO4Zc3r.js +0 -1
  148. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/1._I9GR805.js +0 -1
  149. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/10.J2RBFrSr.js +0 -1
  150. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/12.Cmqj25a-.js +0 -1
  151. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/2.C45iKJHA.js +0 -6
  152. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/5.huHuxdiF.js +0 -1
  153. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/7.FomEdhD6.js +0 -1
  154. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/8.Cb_ADSLk.js +0 -1
  155. lightly_studio/dist_lightly_studio_view_app/_app/immutable/nodes/9.CajIG5ce.js +0 -1
  156. lightly_studio/metrics/__init__.py +0 -0
  157. lightly_studio/metrics/detection/__init__.py +0 -0
  158. lightly_studio/metrics/detection/map.py +0 -268
  159. lightly_studio/models/annotation_task.py +0 -28
  160. lightly_studio/resolvers/annotation_resolver/create.py +0 -19
  161. lightly_studio/resolvers/annotation_task_resolver.py +0 -31
  162. lightly_studio/resolvers/metadata_resolver/sample/bulk_set_metadata.py +0 -48
  163. {lightly_studio-0.3.2.dist-info → lightly_studio-0.3.4.dist-info}/WHEEL +0 -0
@@ -0,0 +1,96 @@
1
+ import"./CWj6FrbW.js";import{p as R,f as J,n as H,a as N,c as q,r as X,g as f,b as mt,au as St,s as ut,t as Mt,u as xt,ak as it,Y as L,aa as Zt}from"./Frwd2CjB.js";import{c as $,a as B,f as nt,t as Dt}from"./CiaNZCBa.js";import{s as E,P as It}from"./DzX_yyqb.js";import{s as lt,r as K,p as tt,b as et}from"./Dafy4oEQ.js";import{I as ct,J as Et,e as ht,M as Rt,Q as bt,T as gt,R as vt,U as yt}from"./Cqo0Vpvt.js";import{a as rt,g as Nt,s as _t,d as Vt}from"./D_ynJAfY.js";import{i as kt}from"./-DXuGN29.js";import{f as At,u as Yt,g as Ct}from"./DD63uD-T.js";import{o as qt}from"./DQ8aZ1o-.js";import{s as j,p as ot,a as Xt,y as Ht}from"./DmjAI-UV.js";import{s as Kt}from"./H60ATh8g.js";function Ft(n,e){R(e,!0);/**
2
+ * @license @lucide/svelte v0.482.0 - ISC
3
+ *
4
+ * ISC License
5
+ *
6
+ * Copyright (c) for portions of Lucide are held by Cole Bemis 2013-2022 as part of Feather (MIT). All other copyright (c) for Lucide are held by Lucide Contributors 2022.
7
+ *
8
+ * Permission to use, copy, modify, and/or distribute this software for any
9
+ * purpose with or without fee is hereby granted, provided that the above
10
+ * copyright notice and this permission notice appear in all copies.
11
+ *
12
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
13
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
14
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
15
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
16
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
17
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
18
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
19
+ *
20
+ */let a=K(e,["$$slots","$$events","$$legacy"]);const c=[["path",{d:"m9 18 6-6-6-6"}]];ct(n,lt({name:"chevron-right"},()=>a,{get iconNode(){return c},children:(r,l)=>{var i=$(),_=J(i);E(_,()=>e.children??H),B(r,i)},$$slots:{default:!0}})),N()}function Se(n,e){R(e,!0);/**
21
+ * @license @lucide/svelte v0.482.0 - ISC
22
+ *
23
+ * ISC License
24
+ *
25
+ * Copyright (c) for portions of Lucide are held by Cole Bemis 2013-2022 as part of Feather (MIT). All other copyright (c) for Lucide are held by Lucide Contributors 2022.
26
+ *
27
+ * Permission to use, copy, modify, and/or distribute this software for any
28
+ * purpose with or without fee is hereby granted, provided that the above
29
+ * copyright notice and this permission notice appear in all copies.
30
+ *
31
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
32
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
33
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
34
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
35
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
36
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
37
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
38
+ *
39
+ */let a=K(e,["$$slots","$$events","$$legacy"]);const c=[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5"}],["path",{d:"M3 12A9 3 0 0 0 21 12"}]];ct(n,lt({name:"database"},()=>a,{get iconNode(){return c},children:(r,l)=>{var i=$(),_=J(i);E(_,()=>e.children??H),B(r,i)},$$slots:{default:!0}})),N()}function Ze(n,e){R(e,!0);/**
40
+ * @license @lucide/svelte v0.482.0 - ISC
41
+ *
42
+ * ISC License
43
+ *
44
+ * Copyright (c) for portions of Lucide are held by Cole Bemis 2013-2022 as part of Feather (MIT). All other copyright (c) for Lucide are held by Lucide Contributors 2022.
45
+ *
46
+ * Permission to use, copy, modify, and/or distribute this software for any
47
+ * purpose with or without fee is hereby granted, provided that the above
48
+ * copyright notice and this permission notice appear in all copies.
49
+ *
50
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
51
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
52
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
53
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
54
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
55
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
56
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
57
+ *
58
+ */let a=K(e,["$$slots","$$events","$$legacy"]);const c=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"}]];ct(n,lt({name:"house"},()=>a,{get iconNode(){return c},children:(r,l)=>{var i=$(),_=J(i);E(_,()=>e.children??H),B(r,i)},$$slots:{default:!0}})),N()}function Gt(n,e){R(e,!0);/**
59
+ * @license @lucide/svelte v0.482.0 - ISC
60
+ *
61
+ * ISC License
62
+ *
63
+ * Copyright (c) for portions of Lucide are held by Cole Bemis 2013-2022 as part of Feather (MIT). All other copyright (c) for Lucide are held by Lucide Contributors 2022.
64
+ *
65
+ * Permission to use, copy, modify, and/or distribute this software for any
66
+ * purpose with or without fee is hereby granted, provided that the above
67
+ * copyright notice and this permission notice appear in all copies.
68
+ *
69
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
70
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
71
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
72
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
73
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
74
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
75
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
76
+ *
77
+ */let a=K(e,["$$slots","$$events","$$legacy"]);const c=[["circle",{cx:"11",cy:"11",r:"8"}],["line",{x1:"21",x2:"16.65",y1:"21",y2:"16.65"}],["line",{x1:"11",x2:"11",y1:"8",y2:"14"}],["line",{x1:"8",x2:"14",y1:"11",y2:"11"}]];ct(n,lt({name:"zoom-in"},()=>a,{get iconNode(){return c},children:(r,l)=>{var i=$(),_=J(i);E(_,()=>e.children??H),B(r,i)},$$slots:{default:!0}})),N()}function Ot(n,e){R(e,!0);/**
78
+ * @license @lucide/svelte v0.482.0 - ISC
79
+ *
80
+ * ISC License
81
+ *
82
+ * Copyright (c) for portions of Lucide are held by Cole Bemis 2013-2022 as part of Feather (MIT). All other copyright (c) for Lucide are held by Lucide Contributors 2022.
83
+ *
84
+ * Permission to use, copy, modify, and/or distribute this software for any
85
+ * purpose with or without fee is hereby granted, provided that the above
86
+ * copyright notice and this permission notice appear in all copies.
87
+ *
88
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
89
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
90
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
91
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
92
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
93
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
94
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
95
+ *
96
+ */let a=K(e,["$$slots","$$events","$$legacy"]);const c=[["circle",{cx:"11",cy:"11",r:"8"}],["line",{x1:"21",x2:"16.65",y1:"21",y2:"16.65"}],["line",{x1:"8",x2:"14",y1:"11",y2:"11"}]];ct(n,lt({name:"zoom-out"},()=>a,{get iconNode(){return c},children:(r,l)=>{var i=$(),_=J(i);E(_,()=>e.children??H),B(r,i)},$$slots:{default:!0}})),N()}function Qt(n){return new Et([document.querySelectorAll(n)],[document.documentElement])}var Ut=nt("<nav><!></nav>");function De(n,e){R(e,!0);let a=tt(e,"ref",15),c=K(e,["$$slots","$$events","$$legacy","ref","class","children"]);var r=Ut();rt(r,()=>({class:e.class,"aria-label":"breadcrumb",...c}));var l=q(r);E(l,()=>e.children??H),X(r),et(r,i=>a(i),()=>a()),B(n,r),N()}var Wt=nt("<li><!></li>");function Ie(n,e){R(e,!0);let a=tt(e,"ref",15,null),c=K(e,["$$slots","$$events","$$legacy","ref","class","children"]);var r=Wt();rt(r,i=>({class:i,...c}),[()=>ht("inline-flex items-center gap-1.5",e.class)]);var l=q(r);E(l,()=>e.children??H),X(r),et(r,i=>a(i),()=>a()),B(n,r),N()}var Lt=nt("<li><!></li>");function Ee(n,e){R(e,!0);let a=tt(e,"ref",15,null),c=K(e,["$$slots","$$events","$$legacy","ref","class","children"]);var r=Lt();rt(r,d=>({role:"presentation","aria-hidden":"true",class:d,...c}),[()=>ht("[&>svg]:size-3.5",e.class)]);var l=q(r);{var i=d=>{var p=$(),M=J(p);E(M,()=>e.children??H),B(d,p)},_=d=>{Ft(d,{})};kt(l,d=>{e.children?d(i):d(_,!1)})}X(r),et(r,d=>a(d),()=>a()),B(n,r),N()}var jt=nt("<a><!></a>");function Re(n,e){R(e,!0);let a=tt(e,"ref",15,null),c=tt(e,"href",3,void 0),r=K(e,["$$slots","$$events","$$legacy","ref","class","href","child","children"]);const l=mt(()=>({class:ht("hover:text-foreground transition-colors",e.class),href:c(),...r})),i=Nt(),[_,d]=i;var p=$(),M=J(p);{var G=P=>{var w=$(),Z=J(w);E(Z,()=>e.child,()=>({props:f(l)})),B(P,w)},x=P=>{var w=jt();rt(w,S=>({...S}),[()=>d({...f(l)},[{attribute_name:"href",lang_attribute_name:"hreflang"}])]);var Z=q(w);E(Z,()=>e.children??H),X(w),et(w,S=>a(S),()=>a()),B(P,w)};kt(M,P=>{e.child?P(G):P(x,!1)})}B(n,p),N()}var Jt=nt("<ol><!></ol>");function Ne(n,e){R(e,!0);let a=tt(e,"ref",15,null),c=K(e,["$$slots","$$events","$$legacy","ref","class","children"]);var r=Jt();rt(r,i=>({class:i,...c}),[()=>ht("text-muted-foreground flex flex-wrap items-center gap-1.5 break-words text-sm sm:gap-2.5",e.class)]);var l=q(r);E(l,()=>e.children??H),X(r),et(r,i=>a(i),()=>a()),B(n,r),N()}var $t=nt("<span><!></span>");function Ve(n,e){R(e,!0);let a=tt(e,"ref",15,null),c=K(e,["$$slots","$$events","$$legacy","ref","class","children"]);var r=$t();rt(r,i=>({role:"link","aria-disabled":"true","aria-current":"page",class:i,...c}),[()=>ht("text-foreground font-normal",e.class)]);var l=q(r);E(l,()=>e.children??H),X(r),et(r,i=>a(i),()=>a()),B(n,r),N()}const Ae=n=>`${It}/sample/${n}`,Ye=({sampleId:n,datasetId:e})=>{const a=At({path:{sample_id:n,dataset_id:e}}),c=Yt(),r=Ct(a);return{refetch:()=>{c.invalidateQueries({queryKey:a.queryKey})},sample:r}};var te=1e-12;function zt(n){return((n=Math.exp(n))+1/n)/2}function ee(n){return((n=Math.exp(n))-1/n)/2}function ne(n){return((n=Math.exp(2*n))-1)/(n+1)}const oe=function n(e,a,c){function r(l,i){var _=l[0],d=l[1],p=l[2],M=i[0],G=i[1],x=i[2],P=M-_,w=G-d,Z=P*P+w*w,S,h;if(Z<te)h=Math.log(x/p)/e,S=function(k){return[_+k*P,d+k*w,p*Math.exp(e*k*h)]};else{var D=Math.sqrt(Z),I=(x*x-p*p+c*Z)/(2*p*a*D),O=(x*x-p*p-c*Z)/(2*x*a*D),V=Math.log(Math.sqrt(I*I+1)-I),g=Math.log(Math.sqrt(O*O+1)-O);h=(g-V)/e,S=function(k){var A=k*h,W=zt(V),at=p/(a*D)*(W*ne(e*A+V)-ee(V));return[_+at*P,d+at*w,p*W/zt(e*A+V)]}}return S.duration=h*1e3*e/Math.SQRT2,S}return r.rho=function(l){var i=Math.max(.001,+l),_=i*i,d=_*_;return n(i,_,d)},r}(Math.SQRT2,2,4),ft=n=>()=>n;function ae(n,{sourceEvent:e,target:a,transform:c,dispatch:r}){Object.defineProperties(this,{type:{value:n,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:a,enumerable:!0,configurable:!0},transform:{value:c,enumerable:!0,configurable:!0},_:{value:r}})}function pt(n){n.stopImmediatePropagation()}function st(n){n.preventDefault(),n.stopImmediatePropagation()}function ie(n){return(!n.ctrlKey||n.type==="wheel")&&!n.button}function re(){var n=this;return n instanceof SVGElement?(n=n.ownerSVGElement||n,n.hasAttribute("viewBox")?(n=n.viewBox.baseVal,[[n.x,n.y],[n.x+n.width,n.y+n.height]]):[[0,0],[n.width.baseVal.value,n.height.baseVal.value]]):[[0,0],[n.clientWidth,n.clientHeight]]}function wt(){return this.__zoom||bt}function se(n){return-n.deltaY*(n.deltaMode===1?.05:n.deltaMode?1:.002)*(n.ctrlKey?10:1)}function ue(){return navigator.maxTouchPoints||"ontouchstart"in this}function le(n,e,a){var c=n.invertX(e[0][0])-a[0][0],r=n.invertX(e[1][0])-a[1][0],l=n.invertY(e[0][1])-a[0][1],i=n.invertY(e[1][1])-a[1][1];return n.translate(r>c?(c+r)/2:Math.min(0,c)||Math.max(0,r),i>l?(l+i)/2:Math.min(0,l)||Math.max(0,i))}function ce(){var n=ie,e=re,a=le,c=se,r=ue,l=[0,1/0],i=[[-1/0,-1/0],[1/0,1/0]],_=250,d=oe,p=Rt("start","zoom","end"),M,G,x,P=500,w=150,Z=0,S=10;function h(t){t.property("__zoom",wt).on("wheel.zoom",A,{passive:!1}).on("mousedown.zoom",W).on("dblclick.zoom",at).filter(r).on("touchstart.zoom",Tt).on("touchmove.zoom",Bt).on("touchend.zoom touchcancel.zoom",Pt).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}h.transform=function(t,s,o,u){var m=t.selection?t.selection():t;m.property("__zoom",wt),t!==m?V(t,s,o,u):m.interrupt().each(function(){g(this,arguments).event(u).start().zoom(null,typeof s=="function"?s.apply(this,arguments):s).end()})},h.scaleBy=function(t,s,o,u){h.scaleTo(t,function(){var m=this.__zoom.k,v=typeof s=="function"?s.apply(this,arguments):s;return m*v},o,u)},h.scaleTo=function(t,s,o,u){h.transform(t,function(){var m=e.apply(this,arguments),v=this.__zoom,y=o==null?O(m):typeof o=="function"?o.apply(this,arguments):o,b=v.invert(y),z=typeof s=="function"?s.apply(this,arguments):s;return a(I(D(v,z),y,b),m,i)},o,u)},h.translateBy=function(t,s,o,u){h.transform(t,function(){return a(this.__zoom.translate(typeof s=="function"?s.apply(this,arguments):s,typeof o=="function"?o.apply(this,arguments):o),e.apply(this,arguments),i)},null,u)},h.translateTo=function(t,s,o,u,m){h.transform(t,function(){var v=e.apply(this,arguments),y=this.__zoom,b=u==null?O(v):typeof u=="function"?u.apply(this,arguments):u;return a(bt.translate(b[0],b[1]).scale(y.k).translate(typeof s=="function"?-s.apply(this,arguments):-s,typeof o=="function"?-o.apply(this,arguments):-o),v,i)},u,m)};function D(t,s){return s=Math.max(l[0],Math.min(l[1],s)),s===t.k?t:new gt(s,t.x,t.y)}function I(t,s,o){var u=s[0]-o[0]*t.k,m=s[1]-o[1]*t.k;return u===t.x&&m===t.y?t:new gt(t.k,u,m)}function O(t){return[(+t[0][0]+ +t[1][0])/2,(+t[0][1]+ +t[1][1])/2]}function V(t,s,o,u){t.on("start.zoom",function(){g(this,arguments).event(u).start()}).on("interrupt.zoom end.zoom",function(){g(this,arguments).event(u).end()}).tween("zoom",function(){var m=this,v=arguments,y=g(m,v).event(u),b=e.apply(m,v),z=o==null?O(b):typeof o=="function"?o.apply(m,v):o,F=Math.max(b[1][0]-b[0][0],b[1][1]-b[0][1]),T=m.__zoom,Y=typeof s=="function"?s.apply(m,v):s,Q=d(T.invert(z).concat(F/T.k),Y.invert(z).concat(F/Y.k));return function(C){if(C===1)C=Y;else{var U=Q(C),dt=F/U[2];C=new gt(dt,z[0]-U[0]*dt,z[1]-U[1]*dt)}y.zoom(null,C)}})}function g(t,s,o){return!o&&t.__zooming||new k(t,s)}function k(t,s){this.that=t,this.args=s,this.active=0,this.sourceEvent=null,this.extent=e.apply(t,s),this.taps=0}k.prototype={event:function(t){return t&&(this.sourceEvent=t),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(t,s){return this.mouse&&t!=="mouse"&&(this.mouse[1]=s.invert(this.mouse[0])),this.touch0&&t!=="touch"&&(this.touch0[1]=s.invert(this.touch0[0])),this.touch1&&t!=="touch"&&(this.touch1[1]=s.invert(this.touch1[0])),this.that.__zoom=s,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(t){var s=j(this.that).datum();p.call(t,this.that,new ae(t,{sourceEvent:this.sourceEvent,target:h,transform:this.that.__zoom,dispatch:p}),s)}};function A(t,...s){if(!n.apply(this,arguments))return;var o=g(this,s).event(t),u=this.__zoom,m=Math.max(l[0],Math.min(l[1],u.k*Math.pow(2,c.apply(this,arguments)))),v=ot(t);if(o.wheel)(o.mouse[0][0]!==v[0]||o.mouse[0][1]!==v[1])&&(o.mouse[1]=u.invert(o.mouse[0]=v)),clearTimeout(o.wheel);else{if(u.k===m)return;o.mouse=[v,u.invert(v)],vt(this),o.start()}st(t),o.wheel=setTimeout(y,w),o.zoom("mouse",a(I(D(u,m),o.mouse[0],o.mouse[1]),o.extent,i));function y(){o.wheel=null,o.end()}}function W(t,...s){if(x||!n.apply(this,arguments))return;var o=t.currentTarget,u=g(this,s,!0).event(t),m=j(t.view).on("mousemove.zoom",z,!0).on("mouseup.zoom",F,!0),v=ot(t,o),y=t.clientX,b=t.clientY;Xt(t.view),pt(t),u.mouse=[v,this.__zoom.invert(v)],vt(this),u.start();function z(T){if(st(T),!u.moved){var Y=T.clientX-y,Q=T.clientY-b;u.moved=Y*Y+Q*Q>Z}u.event(T).zoom("mouse",a(I(u.that.__zoom,u.mouse[0]=ot(T,o),u.mouse[1]),u.extent,i))}function F(T){m.on("mousemove.zoom mouseup.zoom",null),Ht(T.view,u.moved),st(T),u.event(T).end()}}function at(t,...s){if(n.apply(this,arguments)){var o=this.__zoom,u=ot(t.changedTouches?t.changedTouches[0]:t,this),m=o.invert(u),v=o.k*(t.shiftKey?.5:2),y=a(I(D(o,v),u,m),e.apply(this,s),i);st(t),_>0?j(this).transition().duration(_).call(V,y,u,t):j(this).call(h.transform,y,u,t)}}function Tt(t,...s){if(n.apply(this,arguments)){var o=t.touches,u=o.length,m=g(this,s,t.changedTouches.length===u).event(t),v,y,b,z;for(pt(t),y=0;y<u;++y)b=o[y],z=ot(b,this),z=[z,this.__zoom.invert(z),b.identifier],m.touch0?!m.touch1&&m.touch0[2]!==z[2]&&(m.touch1=z,m.taps=0):(m.touch0=z,v=!0,m.taps=1+!!M);M&&(M=clearTimeout(M)),v&&(m.taps<2&&(G=z[0],M=setTimeout(function(){M=null},P)),vt(this),m.start())}}function Bt(t,...s){if(this.__zooming){var o=g(this,s).event(t),u=t.changedTouches,m=u.length,v,y,b,z;for(st(t),v=0;v<m;++v)y=u[v],b=ot(y,this),o.touch0&&o.touch0[2]===y.identifier?o.touch0[0]=b:o.touch1&&o.touch1[2]===y.identifier&&(o.touch1[0]=b);if(y=o.that.__zoom,o.touch1){var F=o.touch0[0],T=o.touch0[1],Y=o.touch1[0],Q=o.touch1[1],C=(C=Y[0]-F[0])*C+(C=Y[1]-F[1])*C,U=(U=Q[0]-T[0])*U+(U=Q[1]-T[1])*U;y=D(y,Math.sqrt(C/U)),b=[(F[0]+Y[0])/2,(F[1]+Y[1])/2],z=[(T[0]+Q[0])/2,(T[1]+Q[1])/2]}else if(o.touch0)b=o.touch0[0],z=o.touch0[1];else return;o.zoom("touch",a(I(y,b,z),o.extent,i))}}function Pt(t,...s){if(this.__zooming){var o=g(this,s).event(t),u=t.changedTouches,m=u.length,v,y;for(pt(t),x&&clearTimeout(x),x=setTimeout(function(){x=null},P),v=0;v<m;++v)y=u[v],o.touch0&&o.touch0[2]===y.identifier?delete o.touch0:o.touch1&&o.touch1[2]===y.identifier&&delete o.touch1;if(o.touch1&&!o.touch0&&(o.touch0=o.touch1,delete o.touch1),o.touch0)o.touch0[1]=this.__zoom.invert(o.touch0[0]);else if(o.end(),o.taps===2&&(y=ot(y,this),Math.hypot(G[0]-y[0],G[1]-y[1])<S)){var b=j(this).on("dblclick.zoom");b&&b.apply(this,arguments)}}}return h.wheelDelta=function(t){return arguments.length?(c=typeof t=="function"?t:ft(+t),h):c},h.filter=function(t){return arguments.length?(n=typeof t=="function"?t:ft(!!t),h):n},h.touchable=function(t){return arguments.length?(r=typeof t=="function"?t:ft(!!t),h):r},h.extent=function(t){return arguments.length?(e=typeof t=="function"?t:ft([[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]]),h):e},h.scaleExtent=function(t){return arguments.length?(l[0]=+t[0],l[1]=+t[1],h):[l[0],l[1]]},h.translateExtent=function(t){return arguments.length?(i[0][0]=+t[0][0],i[1][0]=+t[1][0],i[0][1]=+t[0][1],i[1][1]=+t[1][1],h):[[i[0][0],i[0][1]],[i[1][0],i[1][1]]]},h.constrain=function(t){return arguments.length?(a=t,h):a},h.duration=function(t){return arguments.length?(_=+t,h):_},h.interpolate=function(t){return arguments.length?(d=t,h):d},h.on=function(){var t=p.on.apply(p,arguments);return t===p?h:t},h.clickDistance=function(t){return arguments.length?(Z=(t=+t)*t,h):Math.sqrt(Z)},h.tapDistance=function(t){return arguments.length?(S=+t,h):S},h}function he(n,e){let a=n.scaleIndependentXForm;a||(a=n.scaleIndependentXForm=e.createSVGTransform(),n.transform.baseVal.appendItem(a));const c=n.parentNode;if(c){const r=c.getScreenCTM();if(r){const l=r.inverse().multiply(e.getScreenCTM());l.e=l.f=0,a.setMatrix(l)}}}var fe=nt('<div class="pointer-events-auto absolute bottom-0 left-1 z-20 flex select-none items-center gap-1 rounded-lg bg-muted bg-opacity-80 shadow-md backdrop-blur-sm"><!> <div class="h-6 w-px bg-white bg-opacity-20"></div> <!> <div class="w-[32px] text-center text-sm text-muted-foreground" data-testid="zoom-level"> </div> <!></div>');function me(n,e){var a=fe(),c=q(a);yt(c,{variant:"ghost","data-testid":"zoom-reset",size:"sm",get onclick(){return e.onZoomReset},get disabled(){return e.isResetDisabled},children:(d,p)=>{St();var M=Dt("Reset");B(d,M)},$$slots:{default:!0}});var r=ut(c,4);yt(r,{title:"zoom out",variant:"ghost",size:"icon","data-testid":"zoom-out",get onclick(){return e.onZoomOut},get disabled(){return e.isZoominDisabled},children:(d,p)=>{Ot(d,{class:"h-4 w-4"})},$$slots:{default:!0}});var l=ut(r,2),i=q(l);X(l);var _=ut(l,2);yt(_,{title:"zoom in",variant:"ghost",size:"icon","data-testid":"zoom-in",get onclick(){return e.onZoomIn},get disabled(){return e.isZoomoutDisabled},children:(d,p)=>{Gt(d,{class:"h-4 w-4"})},$$slots:{default:!0}}),X(a),Mt(d=>Kt(i,`${d??""}%`),[()=>Math.round(e.scale*100)]),B(n,a)}var de=nt('<div class="relative flex h-full w-full select-none items-center justify-center"><!> <svg class="z-10 h-full w-full" preserveAspectRatio="xMidYMid meet"><g><!></g></svg> <svg class="pointer-events-none absolute inset-0" preserveAspectRatio="xMidYMid meet"></svg></div>');function Ce(n,e){R(e,!0);let a=it(null),c=it(null);const r=tt(e,"cursor",3,"auto");let l=it(800),i=it(600);xt(()=>{if(!f(a))return;L(l,f(a).clientWidth,!0),L(i,f(a).clientHeight,!0);const g=new ResizeObserver(()=>{f(a)&&(L(l,f(a).clientWidth,!0),L(i,f(a).clientHeight,!0))});return g.observe(f(a)),()=>g.disconnect()});const _=10,d=mt(()=>{const g={x:0,y:0,width:e.width,height:e.height};if(e.boundingBox){Z();const{x:k,y:A,width:W,height:at}=e.boundingBox;return{x:Math.round(Math.max(0,k-_)),y:Math.round(Math.max(0,A-_)),width:Math.round(Math.min(e.width-k,W+_*2)),height:Math.round(Math.min(e.height-A,at+_*2))}}return g});let p=it(Zt({k:1,x:0,y:0}));const M=mt(()=>{if(!f(a))return 1;const g=f(l)/e.width,k=f(i)/e.height,A=Math.min(g,k);return f(p).k*A}),G=mt(()=>{if(!f(a))return 1;let g=f(M);if(e.boundingBox){const k=e.width/f(d).width,A=e.height/f(d).height,W=Math.min(k,A);g*=W}return g});let x=it(null);const P=()=>{f(a)&&(L(x,ce().on("zoom",g=>{L(p,g.transform,!0)}).filter(g=>(!g.ctrlKey||g.type==="wheel")&&!g.button&&!(g.type==="mousedown"&&g.button===2)).wheelDelta(g=>-g.deltaY*.002),!0),j(f(a)).call(f(x)).on("dblclick.zoom",null))},w=g=>{if(!f(a)||!f(x))return;const k=g?1.5:.75;j(f(a)).transition().duration(300).call(f(x).scaleBy,k)},Z=()=>{!f(a)||!f(x)||j(f(a)).transition().duration(300).call(f(x).transform,bt)};qt(()=>{P()}),xt(()=>{f(p).k,Qt(".unscaled").each(function(){he(this,f(c))})});var S=de(),h=q(S);me(h,{get scale(){return f(M)},onZoomIn:()=>w(!0),onZoomOut:()=>w(!1),onZoomReset:Z});var D=ut(h,2),I=q(D),O=q(I);E(O,()=>e.zoomableContent,()=>({scale:f(G)})),X(I),X(D),et(D,g=>L(a,g),()=>f(a));var V=ut(D,2);_t(V,"viewBox","0 0 1024 768"),et(V,g=>L(c,g),()=>f(c)),X(S),Mt(()=>{Vt(D,`cursor: ${r()};`),_t(D,"viewBox",`${f(d).x} ${f(d).y} ${f(d).width} ${f(d).height}`),_t(I,"transform",`translate(${f(p).x}, ${f(p).y}) scale(${f(p).k})`)}),B(n,S),N()}export{De as B,Se as D,Ze as H,Ce as Z,Ne as a,Ie as b,Re as c,Ee as d,Ve as e,Ae as g,Ye as u};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["../nodes/0.5jT7P06o.js","../chunks/qIv1kPyv.js","../chunks/D5w4xp5l.js","../chunks/Frwd2CjB.js","../chunks/DIeogL5L.js","../chunks/CWj6FrbW.js","../chunks/DQ8aZ1o-.js","../chunks/CYgJF_JY.js","../chunks/CiaNZCBa.js","../chunks/DzX_yyqb.js","../chunks/D_ynJAfY.js","../chunks/Dug7Bq1S.js","../chunks/H60ATh8g.js","../chunks/H4l0JFh9.js","../chunks/Dj4O-5se.js","../chunks/69_IOA4Y.js","../chunks/B7302SU7.js","../chunks/-DXuGN29.js","../chunks/DzBTnFhV.js","../chunks/Dafy4oEQ.js","../assets/0.B3oFNb6O.css","../nodes/1.Cdy-7S5q.js","../chunks/DSxvnAMh.js","../nodes/2.BIldfkxL.js","../chunks/CfQ4mGwl.js","../chunks/B90CZVMX.js","../chunks/Cqo0Vpvt.js","../chunks/Bqz7dyEC.js","../chunks/DD63uD-T.js","../chunks/C1FmrZbK.js","../chunks/Cy4fgWTG.js","../assets/transform.2jKMtOWG.css","../chunks/CZGpyrcA.js","../chunks/sLqs1uaK.js","../assets/2.CkOblLn7.css","../nodes/3.BC9z_TWM.js","../chunks/Dv5BSBQG.js","../nodes/4.D8X_Ch5n.js","../nodes/5.CAXhxJu6.js","../chunks/DmjAI-UV.js","../chunks/u-it74zV.js","../nodes/6.DRA5Ru_2.js","../nodes/7.WVBsruHQ.js","../nodes/8.BuKUrCEN.js","../chunks/CSCQddQS.js","../nodes/9.CUIn1yCR.js","../chunks/BeWf8-vJ.js","../nodes/10.C_uoESTX.js","../nodes/11.CWG1ehzT.js","../nodes/12.DcO8wIAc.js"])))=>i.map(i=>d[i]);
2
+ var mt=r=>{throw TypeError(r)};var dt=(r,t,e)=>t.has(r)||mt("Cannot "+e);var i=(r,t,e)=>(dt(r,t,"read from private field"),e?e.call(r):t.get(r)),p=(r,t,e)=>t.has(r)?mt("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(r):t.set(r,e),$=(r,t,e,_)=>(dt(r,t,"write to private field"),_?_.call(r,e):t.set(r,e),e);import{_ as m}from"../chunks/C1FmrZbK.js";import{i as Vt}from"../chunks/Dj4O-5se.js";import{Y as G,ai as xt,g as n,aL as kt,z as wt,W as jt,p as Ct,e as Mt,u as St,ak as tt,aM as Yt,f as d,s as zt,a as Gt,b as y,c as Wt,r as qt,t as Bt}from"../chunks/Frwd2CjB.js";import{h as Ft,m as Ht,u as Jt,s as Kt}from"../chunks/H60ATh8g.js";import"../chunks/CWj6FrbW.js";import{o as Nt}from"../chunks/DQ8aZ1o-.js";import{i as w}from"../chunks/-DXuGN29.js";import{f as ut,a as o,c,t as Qt}from"../chunks/CiaNZCBa.js";import{p as j,c as I,b as R}from"../chunks/Dafy4oEQ.js";function Ut(r){return class extends Xt{constructor(t){super({component:r,...t})}}}var O,l;class Xt{constructor(t){p(this,O);p(this,l);var D;var e=new Map,_=(a,s)=>{var E=jt(s,!1,!1);return e.set(a,E),E};const f=new Proxy({...t.props||{},$$events:{}},{get(a,s){return n(e.get(s)??_(s,Reflect.get(a,s)))},has(a,s){return s===xt?!0:(n(e.get(s)??_(s,Reflect.get(a,s))),Reflect.has(a,s))},set(a,s,E){return G(e.get(s)??_(s,E),E),Reflect.set(a,s,E)}});$(this,l,(t.hydrate?Ft:Ht)(t.component,{target:t.target,anchor:t.anchor,props:f,context:t.context,intro:t.intro??!1,recover:t.recover})),(!((D=t==null?void 0:t.props)!=null&&D.$$host)||t.sync===!1)&&kt(),$(this,O,f.$$events);for(const a of Object.keys(i(this,l)))a==="$set"||a==="$destroy"||a==="$on"||wt(this,a,{get(){return i(this,l)[a]},set(s){i(this,l)[a]=s},enumerable:!0});i(this,l).$set=a=>{Object.assign(f,a)},i(this,l).$destroy=()=>{Jt(i(this,l))}}$set(t){i(this,l).$set(t)}$on(t,e){i(this,O)[t]=i(this,O)[t]||[];const _=(...f)=>e.call(this,...f);return i(this,O)[t].push(_),()=>{i(this,O)[t]=i(this,O)[t].filter(f=>f!==_)}}$destroy(){i(this,l).$destroy()}}O=new WeakMap,l=new WeakMap;const Zt=Vt.reroute(),he={};var pt=ut('<div id="svelte-announcer" aria-live="assertive" aria-atomic="true" style="position: absolute; left: 0; top: 0; clip: rect(0 0 0 0); clip-path: inset(50%); overflow: hidden; white-space: nowrap; width: 1px; height: 1px"><!></div>'),$t=ut("<!> <!>",1);function te(r,t){Ct(t,!0);let e=j(t,"components",23,()=>[]),_=j(t,"data_0",3,null),f=j(t,"data_1",3,null),D=j(t,"data_2",3,null),a=j(t,"data_3",3,null),s=j(t,"data_4",3,null);Mt(()=>t.stores.page.set(t.page)),St(()=>{t.stores,t.page,t.constructors,e(),t.form,_(),f(),D(),a(),s(),t.stores.page.notify()});let E=tt(!1),et=tt(!1),rt=tt(null);Nt(()=>{const u=t.stores.page.subscribe(()=>{n(E)&&(G(et,!0),Yt().then(()=>{G(rt,document.title||"untitled page",!0)}))});return G(E,!0),u});const ct=y(()=>t.constructors[4]);var at=$t(),st=d(at);{var lt=u=>{const b=y(()=>t.constructors[0]);var L=c(),C=d(L);I(C,()=>n(b),(A,T)=>{R(T(A,{get data(){return _()},get form(){return t.form},children:(v,ae)=>{var ot=c(),ht=d(ot);{var Pt=V=>{const W=y(()=>t.constructors[1]);var M=c(),q=d(M);I(q,()=>n(W),(B,F)=>{R(F(B,{get data(){return f()},get form(){return t.form},children:(g,se)=>{var nt=c(),yt=d(nt);{var It=x=>{const H=y(()=>t.constructors[2]);var S=c(),J=d(S);I(J,()=>n(H),(K,N)=>{R(N(K,{get data(){return D()},get form(){return t.form},children:(h,oe)=>{var it=c(),Ot=d(it);{var bt=k=>{const Q=y(()=>t.constructors[3]);var Y=c(),U=d(Y);I(U,()=>n(Q),(X,Z)=>{R(Z(X,{get data(){return a()},get form(){return t.form},children:(P,ne)=>{var _t=c(),At=d(_t);I(At,()=>n(ct),(Dt,Tt)=>{R(Tt(Dt,{get data(){return s()},get form(){return t.form}}),z=>e()[4]=z,()=>{var z;return(z=e())==null?void 0:z[4]})}),o(P,_t)},$$slots:{default:!0}}),P=>e()[3]=P,()=>{var P;return(P=e())==null?void 0:P[3]})}),o(k,Y)},Lt=k=>{const Q=y(()=>t.constructors[3]);var Y=c(),U=d(Y);I(U,()=>n(Q),(X,Z)=>{R(Z(X,{get data(){return a()},get form(){return t.form}}),P=>e()[3]=P,()=>{var P;return(P=e())==null?void 0:P[3]})}),o(k,Y)};w(Ot,k=>{t.constructors[4]?k(bt):k(Lt,!1)})}o(h,it)},$$slots:{default:!0}}),h=>e()[2]=h,()=>{var h;return(h=e())==null?void 0:h[2]})}),o(x,S)},Rt=x=>{const H=y(()=>t.constructors[2]);var S=c(),J=d(S);I(J,()=>n(H),(K,N)=>{R(N(K,{get data(){return D()},get form(){return t.form}}),h=>e()[2]=h,()=>{var h;return(h=e())==null?void 0:h[2]})}),o(x,S)};w(yt,x=>{t.constructors[3]?x(It):x(Rt,!1)})}o(g,nt)},$$slots:{default:!0}}),g=>e()[1]=g,()=>{var g;return(g=e())==null?void 0:g[1]})}),o(V,M)},Et=V=>{const W=y(()=>t.constructors[1]);var M=c(),q=d(M);I(q,()=>n(W),(B,F)=>{R(F(B,{get data(){return f()},get form(){return t.form}}),g=>e()[1]=g,()=>{var g;return(g=e())==null?void 0:g[1]})}),o(V,M)};w(ht,V=>{t.constructors[2]?V(Pt):V(Et,!1)})}o(v,ot)},$$slots:{default:!0}}),v=>e()[0]=v,()=>{var v;return(v=e())==null?void 0:v[0]})}),o(u,L)},ft=u=>{const b=y(()=>t.constructors[0]);var L=c(),C=d(L);I(C,()=>n(b),(A,T)=>{R(T(A,{get data(){return _()},get form(){return t.form}}),v=>e()[0]=v,()=>{var v;return(v=e())==null?void 0:v[0]})}),o(u,L)};w(st,u=>{t.constructors[1]?u(lt):u(ft,!1)})}var vt=zt(st,2);{var gt=u=>{var b=pt(),L=Wt(b);{var C=A=>{var T=Qt();Bt(()=>Kt(T,n(rt))),o(A,T)};w(L,A=>{n(et)&&A(C)})}qt(b),o(u,b)};w(vt,u=>{n(E)&&u(gt)})}o(r,at),Gt()}const Pe=Ut(te),Ee=[()=>m(()=>import("../nodes/0.5jT7P06o.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20]),import.meta.url),()=>m(()=>import("../nodes/1.Cdy-7S5q.js"),__vite__mapDeps([21,5,15,4,3,12,11,8,18,22,6,7]),import.meta.url),()=>m(()=>import("../nodes/2.BIldfkxL.js"),__vite__mapDeps([23,1,2,3,4,24,25,7,5,6,8,17,9,22,26,15,12,11,10,13,18,19,27,28,29,30,31,32,33,16,34]),import.meta.url),()=>m(()=>import("../nodes/3.BC9z_TWM.js"),__vite__mapDeps([35,30,3,4,9,1,2,36,5,8]),import.meta.url),()=>m(()=>import("../nodes/4.D8X_Ch5n.js"),__vite__mapDeps([37,27,9,3,4,1,2,30,36,5,8]),import.meta.url),()=>m(()=>import("../nodes/5.CAXhxJu6.js"),__vite__mapDeps([38,5,3,4,8,9,17,22,6,7,26,15,12,11,10,2,13,18,19,1,27,24,28,29,30,31,32,39,40]),import.meta.url),()=>m(()=>import("../nodes/6.DRA5Ru_2.js"),__vite__mapDeps([41,24,2,25,7]),import.meta.url),()=>m(()=>import("../nodes/7.WVBsruHQ.js"),__vite__mapDeps([42,5,3,4,17,26,15,12,11,8,10,9,2,13,18,22,6,7,19,1,27,24,28,29,30,31]),import.meta.url),()=>m(()=>import("../nodes/8.BuKUrCEN.js"),__vite__mapDeps([43,3,4,2,1,5,8,17,11,10,12,9,13,6,7,26,15,18,22,19,27,24,28,29,30,31,32,39,40,44,33]),import.meta.url),()=>m(()=>import("../nodes/9.CUIn1yCR.js"),__vite__mapDeps([45,5,17,3,4,26,15,12,11,8,10,9,2,13,18,22,6,7,19,1,27,24,28,29,30,31,46,39]),import.meta.url),()=>m(()=>import("../nodes/10.C_uoESTX.js"),__vite__mapDeps([47,5,3,4,17,26,15,12,11,8,10,9,2,13,18,22,6,7,19,1,27,24,28,29,30,31,46,39]),import.meta.url),()=>m(()=>import("../nodes/11.CWG1ehzT.js"),__vite__mapDeps([48,5,15,4]),import.meta.url),()=>m(()=>import("../nodes/12.DcO8wIAc.js"),__vite__mapDeps([49,3,4,2,28,1,13,5,15,11,8,17,22,6,7,24,44]),import.meta.url)],ye=[],Ie={"/":[6],"/datasets/[dataset_id]/annotations":[7,[2,3]],"/datasets/[dataset_id]/annotations/[sampleId]/[annotationId]/[annotationIndex]":[8,[2,3]],"/datasets/[dataset_id]/classifiers":[9,[2]],"/datasets/[dataset_id]/samples":[10,[2,4]],"/datasets/[dataset_id]/samples/[sampleId]":[11,[2,4,5]],"/datasets/[dataset_id]/samples/[sampleId]/[sampleIndex]":[12,[2,4,5]]},ee={handleError:({error:r})=>{console.error(r)},reroute:Zt||(()=>{}),transport:{}},re=Object.fromEntries(Object.entries(ee.transport).map(([r,t])=>[r,t.decode])),Re=!1,Oe=(r,t)=>re[r](t);export{Oe as decode,re as decoders,Ie as dictionary,Re as hash,ee as hooks,he as matchers,Ee as nodes,Pe as root,ye as server_loads};
@@ -0,0 +1 @@
1
+ import{l as o,e as r}from"../chunks/DQ8aZ1o-.js";export{o as load_css,r as start};
@@ -0,0 +1 @@
1
+ var an=e=>{throw TypeError(e)};var sn=(e,t,a)=>t.has(e)||an("Cannot "+a);var r=(e,t,a)=>(sn(e,t,"read from private field"),a?a.call(e):t.get(e)),at=(e,t,a)=>t.has(e)?an("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,a),j=(e,t,a,s)=>(sn(e,t,"write to private field"),s?s.call(e,a):t.set(e,a),a);var Ae=(e,t,a,s)=>({set _(l){j(e,t,l,a)},get _(){return r(e,t,s)}});import{u as Un}from"../chunks/qIv1kPyv.js";import"../chunks/CWj6FrbW.js";import{b as xn,i as qn,o as Se,d as Kn}from"../chunks/DQ8aZ1o-.js";import{G as zn,H as jn,ba as Vn,p as te,bb as At,Y as h,W as oe,g as n,k as yt,bc as In,f as v,h as Qt,a as ee,t as rt,m as Gn,c as mt,r as lt,bd as Wn,aO as on,aP as Yn,ak as Y,aa as Tn,u as Vt,b as T,s as $t,n as kt}from"../chunks/Frwd2CjB.js";import{c as m,a as i,f as ct,t as rn,b as xe}from"../chunks/CiaNZCBa.js";import{s as _t}from"../chunks/DzX_yyqb.js";import{e as Ee,i as Zn,s as S,L as Xn,f as Jn,k as pn,h as ln,M as $n,j as cn,c as Ut,b as qt,l as st,g as ta,m as Nt,d as Ye,S as ea,a as na,n as aa,u as sa}from"../chunks/D_ynJAfY.js";import{n as On,p as Je,s as pe,i as ia}from"../chunks/Dj4O-5se.js";import"../chunks/69_IOA4Y.js";import{b as oa,c as ra,s as Ce}from"../chunks/H60ATh8g.js";import{s as Mn,i as A,a as An}from"../chunks/-DXuGN29.js";import{i as tn}from"../chunks/DzBTnFhV.js";import{p as k,b as Cn,c as pt,s as Ze,r as la}from"../chunks/Dafy4oEQ.js";import{p as $e}from"../chunks/B7302SU7.js";import{o as Be,e as ca,d as ua}from"../chunks/Dug7Bq1S.js";import{S as Dn,o as Pn,Q as da,e as ft,q as un,u as dn,n as Kt,f as fa,v as fn,a as hn,w as ha,x as gn,y as vn,z as ga,A as va}from"../chunks/H4l0JFh9.js";const ma=!0;function En(e,t,a,s,l){var R;zn&&jn();var o=(R=t.$$slots)==null?void 0:R[a],D=!1;o===!0&&(o=t.children,D=!0),o===void 0||o(e,D?()=>s:s)}const ya=ma,_a=Vn;function ba(e,t){return e.protocol!==t.protocol?t.href:t.password||t.username?"//"+[t.username,t.password].filter(Boolean).join(":")+"@"+t.host+t.pathname+t.search+t.hash:e.host!==t.host?"//"+t.host+t.pathname+t.search+t.hash:t.pathname+t.search+t.hash}function wa(e,t,a){const s=new URL(a,t).pathname;return e.origin!==t.origin||!e.pathname.startsWith(s)}var xa=ct('<link rel="alternate"/>');function Ia(e,t){te(t,!1);const a=()=>Mn($e,"$page",s),[s,l]=An(),o=oe(),D=oe(),R=oe(),ot=On(xn,new URL(a().url))||"/";let w=k(t,"availableLanguageTags",8),Q=k(t,"strategy",8),bt=k(t,"currentLang",8);const Dt=(F,q)=>{const K=[];for(const wt of w()){const Et=q.getLocalisedPath(F,wt),ht=pe(Et,ot,void 0),O=new URL(ht,new URL(a().url)).href;K.push(O)}return K};At(()=>a(),()=>{h(o,Je(a().url.pathname,ot)[0])}),At(()=>(yt(Q()),n(o),yt(bt())),()=>{h(D,Q().getCanonicalPath(n(o),bt()))}),At(()=>(n(D),yt(Q())),()=>{h(R,Dt(n(D),Q()))}),In(),tn();var Pt=m(),H=v(Pt);{var V=F=>{var q=m(),K=v(q);Ee(K,1,()=>n(R),Zn,(wt,Et,ht)=>{var O=xa();rt(()=>{S(O,"hreflang",(yt(w()),Qt(()=>w()[ht]))),S(O,"href",n(Et))}),i(wt,O)}),i(F,q)};A(H,F=>{yt(w()),Qt(()=>w().length>=1)&&F(V)})}i(e,Pt),ee(),l()}const Ta=(e,t)=>`${Xn}=${e};Path=${t};SameSite=lax;Max-Age=31557600`;function Oa(e,t){te(t,!1);const a=()=>Mn($e,"$page",s),[s,l]=An(),o=oe(),D=oe(),R=On(xn,new URL(a().url))||"/";let ot=k(t,"languageTag",24,()=>{}),w=k(t,"i18n",8),Q=oe(0);function bt(H,V){try{const F=new URL(Gn($e).url),[q,K]=Je(F.pathname,R),wt=w().strategy.getCanonicalPath(q,n(o)),Et=new URL(F);Et.pathname=pe(wt,R,K);const ht=new URL(H,new URL(Et));if(wa(ht,F,R)||w().config.exclude(ht.pathname))return H;const O=V??n(o),[gt,Ht]=Je(ht.pathname,R),Bt=w().strategy.getLocalisedPath(gt,O),ut=new URL(ht);return ut.pathname=pe(Bt,R,Ht),ba(F,ut)}catch{return H}}Jn({translateHref:bt}),At(()=>(yt(ot()),yt(w()),a()),()=>{h(o,ot()??w().getLanguageFromUrl(a().url))}),At(()=>(yt(w()),n(o)),()=>{w().config.runtime.setLanguageTag(n(o))}),At(()=>n(o),()=>{document.documentElement.lang=n(o)}),At(()=>(yt(w()),n(o)),()=>{document.documentElement.dir=w().config.textDirection[n(o)]??"ltr"}),At(()=>(n(o),n(Q)),()=>{n(o)&&h(Q,n(Q)+1)}),At(()=>(n(o),n(Q),ln),()=>{n(o)&&(n(Q)>1||_a)&&qn(ln)}),At(()=>n(o),()=>{h(D,n(o))}),At(()=>n(o),()=>{document.cookie=Ta(n(o),R)}),In(),tn();var Dt=m();oa(H=>{var V=m(),F=v(V);{var q=K=>{Ia(K,{get availableLanguageTags(){return yt(w()),Qt(()=>w().config.runtime.availableLanguageTags)},get strategy(){return yt(w()),Qt(()=>w().strategy)},get currentLang(){return n(o)}})};A(F,K=>{yt(w()),a(),Qt(()=>w().config.seo.noAlternateLinks!==!0&&!w().config.exclude(a().url.pathname))&&K(q)})}i(H,V)});var Pt=v(Dt);pn(Pt,()=>n(D),H=>{var V=m(),F=v(V);En(F,t,"default",{}),i(H,V)}),i(e,Dt),ee(),l()}const Ma=Un(),Aa=async()=>({globalStorage:Ma}),Us=Object.freeze(Object.defineProperty({__proto__:null,load:Aa},Symbol.toStringTag,{value:"Module"}));var St,_n,Ca=(_n=class extends Dn{constructor(t={}){super();at(this,St);this.config=t,j(this,St,new Map)}build(t,a,s){const l=a.queryKey,o=a.queryHash??Pn(l,a);let D=this.get(o);return D||(D=new da({client:t,queryKey:l,queryHash:o,options:t.defaultQueryOptions(a),state:s,defaultOptions:t.getQueryDefaults(l)}),this.add(D)),D}add(t){r(this,St).has(t.queryHash)||(r(this,St).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const a=r(this,St).get(t.queryHash);a&&(t.destroy(),a===t&&r(this,St).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){ft.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return r(this,St).get(t)}getAll(){return[...r(this,St).values()]}find(t){const a={exact:!0,...t};return this.getAll().find(s=>un(a,s))}findAll(t={}){const a=this.getAll();return Object.keys(t).length>0?a.filter(s=>un(t,s)):a}notify(t){ft.batch(()=>{this.listeners.forEach(a=>{a(t)})})}onFocus(){ft.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){ft.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},St=new WeakMap,_n),zt,Ct,_e,bn,Da=(bn=class extends Dn{constructor(t={}){super();at(this,zt);at(this,Ct);at(this,_e);this.config=t,j(this,zt,new Set),j(this,Ct,new Map),j(this,_e,0)}build(t,a,s){const l=new $n({mutationCache:this,mutationId:++Ae(this,_e)._,options:t.defaultMutationOptions(a),state:s});return this.add(l),l}add(t){r(this,zt).add(t);const a=De(t);if(typeof a=="string"){const s=r(this,Ct).get(a);s?s.push(t):r(this,Ct).set(a,[t])}this.notify({type:"added",mutation:t})}remove(t){if(r(this,zt).delete(t)){const a=De(t);if(typeof a=="string"){const s=r(this,Ct).get(a);if(s)if(s.length>1){const l=s.indexOf(t);l!==-1&&s.splice(l,1)}else s[0]===t&&r(this,Ct).delete(a)}}this.notify({type:"removed",mutation:t})}canRun(t){const a=De(t);if(typeof a=="string"){const s=r(this,Ct).get(a),l=s==null?void 0:s.find(o=>o.state.status==="pending");return!l||l===t}else return!0}runNext(t){var s;const a=De(t);if(typeof a=="string"){const l=(s=r(this,Ct).get(a))==null?void 0:s.find(o=>o!==t&&o.state.isPaused);return(l==null?void 0:l.continue())??Promise.resolve()}else return Promise.resolve()}clear(){ft.batch(()=>{r(this,zt).forEach(t=>{this.notify({type:"removed",mutation:t})}),r(this,zt).clear(),r(this,Ct).clear()})}getAll(){return Array.from(r(this,zt))}find(t){const a={exact:!0,...t};return this.getAll().find(s=>dn(a,s))}findAll(t={}){return this.getAll().filter(a=>dn(t,a))}notify(t){ft.batch(()=>{this.listeners.forEach(a=>{a(t)})})}resumePausedMutations(){const t=this.getAll().filter(a=>a.state.isPaused);return ft.batch(()=>Promise.all(t.map(a=>a.continue().catch(Kt))))}},zt=new WeakMap,Ct=new WeakMap,_e=new WeakMap,bn);function De(e){var t;return(t=e.options.scope)==null?void 0:t.id}var U,Wt,Yt,re,le,Zt,ce,ue,wn,Bn=(wn=class{constructor(e={}){at(this,U);at(this,Wt);at(this,Yt);at(this,re);at(this,le);at(this,Zt);at(this,ce);at(this,ue);j(this,U,e.queryCache||new Ca),j(this,Wt,e.mutationCache||new Da),j(this,Yt,e.defaultOptions||{}),j(this,re,new Map),j(this,le,new Map),j(this,Zt,0)}mount(){Ae(this,Zt)._++,r(this,Zt)===1&&(j(this,ce,fa.subscribe(async e=>{e&&(await this.resumePausedMutations(),r(this,U).onFocus())})),j(this,ue,fn.subscribe(async e=>{e&&(await this.resumePausedMutations(),r(this,U).onOnline())})))}unmount(){var e,t;Ae(this,Zt)._--,r(this,Zt)===0&&((e=r(this,ce))==null||e.call(this),j(this,ce,void 0),(t=r(this,ue))==null||t.call(this),j(this,ue,void 0))}isFetching(e){return r(this,U).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return r(this,Wt).findAll({...e,status:"pending"}).length}getQueryData(e){var a;const t=this.defaultQueryOptions({queryKey:e});return(a=r(this,U).get(t.queryHash))==null?void 0:a.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),a=r(this,U).build(this,t),s=a.state.data;return s===void 0?this.fetchQuery(e):(e.revalidateIfStale&&a.isStaleByTime(hn(t.staleTime,a))&&this.prefetchQuery(t),Promise.resolve(s))}getQueriesData(e){return r(this,U).findAll(e).map(({queryKey:t,state:a})=>{const s=a.data;return[t,s]})}setQueryData(e,t,a){const s=this.defaultQueryOptions({queryKey:e}),l=r(this,U).get(s.queryHash),o=l==null?void 0:l.state.data,D=ha(t,o);if(D!==void 0)return r(this,U).build(this,s).setData(D,{...a,manual:!0})}setQueriesData(e,t,a){return ft.batch(()=>r(this,U).findAll(e).map(({queryKey:s})=>[s,this.setQueryData(s,t,a)]))}getQueryState(e){var a;const t=this.defaultQueryOptions({queryKey:e});return(a=r(this,U).get(t.queryHash))==null?void 0:a.state}removeQueries(e){const t=r(this,U);ft.batch(()=>{t.findAll(e).forEach(a=>{t.remove(a)})})}resetQueries(e,t){const a=r(this,U);return ft.batch(()=>(a.findAll(e).forEach(s=>{s.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const a={revert:!0,...t},s=ft.batch(()=>r(this,U).findAll(e).map(l=>l.cancel(a)));return Promise.all(s).then(Kt).catch(Kt)}invalidateQueries(e,t={}){return ft.batch(()=>(r(this,U).findAll(e).forEach(a=>{a.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const a={...t,cancelRefetch:t.cancelRefetch??!0},s=ft.batch(()=>r(this,U).findAll(e).filter(l=>!l.isDisabled()).map(l=>{let o=l.fetch(void 0,a);return a.throwOnError||(o=o.catch(Kt)),l.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(s).then(Kt)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const a=r(this,U).build(this,t);return a.isStaleByTime(hn(t.staleTime,a))?a.fetch(t):Promise.resolve(a.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Kt).catch(Kt)}fetchInfiniteQuery(e){return e.behavior=cn(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Kt).catch(Kt)}ensureInfiniteQueryData(e){return e.behavior=cn(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return fn.isOnline()?r(this,Wt).resumePausedMutations():Promise.resolve()}getQueryCache(){return r(this,U)}getMutationCache(){return r(this,Wt)}getDefaultOptions(){return r(this,Yt)}setDefaultOptions(e){j(this,Yt,e)}setQueryDefaults(e,t){r(this,re).set(gn(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...r(this,re).values()],a={};return t.forEach(s=>{vn(e,s.queryKey)&&Object.assign(a,s.defaultOptions)}),a}setMutationDefaults(e,t){r(this,le).set(gn(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...r(this,le).values()],a={};return t.forEach(s=>{vn(e,s.mutationKey)&&Object.assign(a,s.defaultOptions)}),a}defaultQueryOptions(e){if(e._defaulted)return e;const t={...r(this,Yt).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Pn(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===ga&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...r(this,Yt).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){r(this,U).clear(),r(this,Wt).clear()}},U=new WeakMap,Wt=new WeakMap,Yt=new WeakMap,re=new WeakMap,le=new WeakMap,Zt=new WeakMap,ce=new WeakMap,ue=new WeakMap,wn);function Pa(e,t){te(t,!1);let a=k(t,"client",24,()=>new Bn);Se(()=>{a().mount()}),va(a()),Kn(()=>{a().unmount()}),tn();var s=m(),l=v(s);En(l,t,"default",{}),i(e,s),ee()}const Ea=Array(12).fill(0);var Ba=ct('<div class="sonner-loading-bar"></div>'),La=ct('<div><div class="sonner-spinner"></div></div>');function Sa(e,t){te(t,!0);var a=La(),s=mt(a);Ee(s,23,()=>Ea,(l,o)=>`spinner-bar-${o}`,(l,o)=>{var D=Ba();i(l,D)}),lt(s),lt(a),rt(l=>{qt(a,1,l),S(a,"data-visible",t.visible)},[()=>Ut(["sonner-loading-wrapper",t.class].filter(Boolean).join(" "))]),i(e,a),ee()}const ka=typeof window<"u"?window:void 0;function Qa(e){let t=e.activeElement;for(;t!=null&&t.shadowRoot;){const a=t.shadowRoot.activeElement;if(a===t)break;t=a}return t}var de,be;class Ha{constructor(t={}){at(this,de);at(this,be);const{window:a=ka,document:s=a==null?void 0:a.document}=t;a!==void 0&&(j(this,de,s),j(this,be,ra(l=>{const o=Be(a,"focusin",l),D=Be(a,"focusout",l);return()=>{o(),D()}})))}get current(){var t;return(t=r(this,be))==null||t.call(this),r(this,de)?Qa(r(this,de)):null}}de=new WeakMap,be=new WeakMap;new Ha;var we,jt;class Ra{constructor(t){at(this,we);at(this,jt);j(this,we,t),j(this,jt,Symbol(t))}get key(){return r(this,jt)}exists(){return Wn(r(this,jt))}get(){const t=on(r(this,jt));if(t===void 0)throw new Error(`Context "${r(this,we)}" not found`);return t}getOr(t){const a=on(r(this,jt));return a===void 0?t:a}set(t){return Yn(r(this,jt),t)}}we=new WeakMap,jt=new WeakMap;const Fa=new Ra("<Toaster/>");function Le(e){return e.label!==void 0}function Na(){let e=Y(Tn(typeof document<"u"?document.hidden:!1));return Vt(()=>Be(document,"visibilitychange",()=>{h(e,document.hidden,!0)})),{get current(){return n(e)}}}const mn=4e3,Ua=14,qa=45,Ka=200,za=.05,ja={toast:"",title:"",description:"",loader:"",closeButton:"",cancelButton:"",actionButton:"",action:"",warning:"",error:"",success:"",default:"",info:"",loading:""};function Va(e){const[t,a]=e.split("-"),s=[];return t&&s.push(t),a&&s.push(a),s}function yn(e){return 1/(1.5+Math.abs(e)/20)}var Ga=ct("<div><!></div>"),Wa=(e,t,a,s,l)=>{var o,D;n(t)||!n(a)||(s(),(D=(o=l.toast).onDismiss)==null||D.call(o,l.toast))},Ya=ct('<button data-close-button=""><!></button>'),Za=ct('<div data-icon=""><!> <!></div>'),Xa=ct('<div data-description=""><!></div>'),Ja=(e,t,a,s)=>{var l,o;Le(t.toast.cancel)&&n(a)&&((o=(l=t.toast.cancel)==null?void 0:l.onClick)==null||o.call(l,e),s())},pa=ct('<button data-button="" data-cancel=""> </button>'),$a=(e,t,a)=>{var s;Le(t.toast.action)&&((s=t.toast.action)==null||s.onClick(e),!e.defaultPrevented&&a())},ts=ct('<button data-button=""> </button>'),es=ct('<!> <div data-content=""><div data-title=""><!></div> <!></div> <!> <!>',1),ns=ct('<li data-sonner-toast=""><!> <!></li>');function as(e,t){te(t,!0);const a=d=>{var g=m(),P=v(g);{var E=x=>{var tt=Ga(),dt=mt(tt);_t(dt,()=>t.loadingIcon),lt(tt),rt(et=>{qt(tt,1,et),S(tt,"data-visible",n(O)==="loading")},[()=>{var et,X,b;return Ut(Nt((et=n(vt))==null?void 0:et.loader,(b=(X=t.toast)==null?void 0:X.classes)==null?void 0:b.loader,"sonner-loader"))}]),i(x,tt)},B=x=>{{let tt=T(()=>{var et,X;return Nt((et=n(vt))==null?void 0:et.loader,(X=t.toast.classes)==null?void 0:X.loader)}),dt=T(()=>n(O)==="loading");Sa(x,{get class(){return n(tt)},get visible(){return n(dt)}})}};A(P,x=>{t.loadingIcon?x(E):x(B,!1)})}i(d,g)};let s=k(t,"cancelButtonStyle",3,""),l=k(t,"actionButtonStyle",3,""),o=k(t,"descriptionClass",3,""),D=k(t,"unstyled",3,!1),R=k(t,"defaultRichColors",3,!1);const ot={...ja};let w=Y(!1),Q=Y(!1),bt=Y(!1),Dt=Y(!1),Pt=Y(!1),H=Y(0),V=Y(0),F=t.toast.duration||t.duration||mn,q=Y(void 0),K=Y(null),wt=Y(null);const Et=T(()=>t.index===0),ht=T(()=>t.index+1<=t.visibleToasts),O=T(()=>t.toast.type),gt=T(()=>t.toast.dismissable!==!1),Ht=T(()=>t.toast.class||""),Bt=T(()=>t.toast.descriptionClass||""),ut=T(()=>st.heights.findIndex(d=>d.toastId===t.toast.id)||0),Xt=T(()=>t.toast.closeButton??t.closeButton),ke=T(()=>t.toast.duration??t.duration??mn);let Gt=null;const Ie=T(()=>t.position.split("-")),Qe=T(()=>st.heights.reduce((d,g,P)=>P>=n(ut)?d:d+g.height,0)),He=Na(),Re=T(()=>t.toast.invert||t.invert),fe=T(()=>n(O)==="loading"),vt=T(()=>({...ot,...t.classes})),Fe=T(()=>t.toast.title),Jt=T(()=>t.toast.description);let he=Y(0),Te=Y(0);const f=T(()=>Math.round(n(ut)*Ua+n(Qe)));Vt(()=>{n(Fe),n(Jt);let d;t.expanded||t.expandByDefault?d=1:d=1-t.index*za;const g=Qt(()=>n(q));if(g===void 0)return;g.style.setProperty("height","auto");const P=g.offsetHeight,E=g.getBoundingClientRect().height,B=Math.round(E/d+Number.EPSILON&100)/100;g.style.removeProperty("height");let x;Math.abs(B-P)<1?x=B:x=P,h(V,x,!0),Qt(()=>{st.setHeight({toastId:t.toast.id,height:x})})});function _(){h(Q,!0),h(H,n(f),!0),st.removeHeight(t.toast.id),setTimeout(()=>{st.remove(t.toast.id)},Ka)}let Z;const Rt=T(()=>t.toast.promise&&n(O)==="loading"||t.toast.duration===Number.POSITIVE_INFINITY);function xt(){h(he,new Date().getTime(),!0),Z=setTimeout(()=>{var d,g;(g=(d=t.toast).onAutoClose)==null||g.call(d,t.toast),_()},F)}function ne(){if(n(Te)<n(he)){const d=new Date().getTime()-n(he);F=F-d}h(Te,new Date().getTime(),!0)}Vt(()=>{t.toast.updated&&(clearTimeout(Z),F=n(ke),xt())}),Vt(()=>(n(Rt)||(t.expanded||t.interacting||He.current?ne():xt()),()=>clearTimeout(Z))),Se(()=>{var g;h(w,!0);const d=(g=n(q))==null?void 0:g.getBoundingClientRect().height;return h(V,d,!0),st.setHeight({toastId:t.toast.id,height:d}),()=>{st.removeHeight(t.toast.id)}}),Vt(()=>{t.toast.delete&&Qt(()=>{var d,g;_(),(g=(d=t.toast).onDismiss)==null||g.call(d,t.toast)})});const en=d=>{if(n(fe))return;h(H,n(f),!0);const g=d.target;g.setPointerCapture(d.pointerId),g.tagName!=="BUTTON"&&(h(bt,!0),Gt={x:d.clientX,y:d.clientY})},Oe=()=>{var x,tt,dt,et,X,b;if(n(Dt)||!n(gt))return;Gt=null;const d=Number(((x=n(q))==null?void 0:x.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),g=Number(((tt=n(q))==null?void 0:tt.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),P=new Date().getTime()-0,E=n(K)==="x"?d:g,B=Math.abs(E)/P;if(Math.abs(E)>=qa||B>.11){h(H,n(f),!0),(et=(dt=t.toast).onDismiss)==null||et.call(dt,t.toast),n(K)==="x"?h(wt,d>0?"right":"left",!0):h(wt,g>0?"down":"up",!0),_(),h(Dt,!0);return}else(X=n(q))==null||X.style.setProperty("--swipe-amount-x","0px"),(b=n(q))==null||b.style.setProperty("--swipe-amount-y","0px");h(Pt,!1),h(bt,!1),h(K,null)},Lt=d=>{var tt,dt,et;if(!Gt||!n(gt)||(((tt=window.getSelection())==null?void 0:tt.toString().length)??-1)>0)return;const P=d.clientY-Gt.y,E=d.clientX-Gt.x,B=t.swipeDirections??Va(t.position);!n(K)&&(Math.abs(E)>1||Math.abs(P)>1)&&h(K,Math.abs(E)>Math.abs(P)?"x":"y",!0);let x={x:0,y:0};if(n(K)==="y"){if(B.includes("top")||B.includes("bottom"))if(B.includes("top")&&P<0||B.includes("bottom")&&P>0)x.y=P;else{const X=P*yn(P);x.y=Math.abs(X)<Math.abs(P)?X:P}}else if(n(K)==="x"&&(B.includes("left")||B.includes("right")))if(B.includes("left")&&E<0||B.includes("right")&&E>0)x.x=E;else{const X=E*yn(E);x.x=Math.abs(X)<Math.abs(E)?X:E}(Math.abs(x.x)>0||Math.abs(x.y)>0)&&h(Pt,!0),(dt=n(q))==null||dt.style.setProperty("--swipe-amount-x",`${x.x}px`),(et=n(q))==null||et.style.setProperty("--swipe-amount-y",`${x.y}px`)},Ft=()=>{h(bt,!1),h(K,null),Gt=null},$=T(()=>t.toast.icon?t.toast.icon:n(O)==="success"?t.successIcon:n(O)==="error"?t.errorIcon:n(O)==="warning"?t.warningIcon:n(O)==="info"?t.infoIcon:n(O)==="loading"?t.loadingIcon:null);ta();var M=ns();S(M,"tabindex",0);let Me;M.__pointermove=Lt,M.__pointerup=Oe,M.__pointerdown=en;var Ne=mt(M);{var Ue=d=>{var g=Ya();g.__click=[Wa,fe,gt,_,t];var P=mt(g);_t(P,()=>t.closeIcon??kt),lt(g),rt(E=>{S(g,"aria-label",t.closeButtonAriaLabel),S(g,"data-disabled",n(fe)),qt(g,1,E)},[()=>{var E,B,x;return Ut(Nt((E=n(vt))==null?void 0:E.closeButton,(x=(B=t.toast)==null?void 0:B.classes)==null?void 0:x.closeButton))}]),i(d,g)};A(Ne,d=>{n(Xt)&&!t.toast.component&&n(O)!=="loading"&&t.closeIcon!==null&&d(Ue)})}var qe=$t(Ne,2);{var Ke=d=>{const g=T(()=>t.toast.component);var P=m(),E=v(P);pt(E,()=>n(g),(B,x)=>{x(B,Ze(()=>t.toast.componentProps,{closeToast:_}))}),i(d,P)},ze=d=>{var g=es(),P=v(g);{var E=C=>{var c=Za(),y=mt(c);{var L=I=>{var N=m(),J=v(N);{var W=nt=>{var p=m(),Ot=v(p);pt(Ot,()=>t.toast.icon,(Mt,ge)=>{ge(Mt,{})}),i(nt,p)},z=nt=>{a(nt)};A(J,nt=>{t.toast.icon?nt(W):nt(z,!1)})}i(I,N)};A(y,I=>{(t.toast.promise||n(O)==="loading")&&I(L)})}var G=$t(y,2);{var u=I=>{var N=m(),J=v(N);{var W=nt=>{var p=m(),Ot=v(p);pt(Ot,()=>t.toast.icon,(Mt,ge)=>{ge(Mt,{})}),i(nt,p)},z=nt=>{var p=m(),Ot=v(p);{var Mt=ae=>{var ve=m(),je=v(ve);_t(je,()=>t.successIcon??kt),i(ae,ve)},ge=ae=>{var ve=m(),je=v(ve);{var kn=se=>{var me=m(),Ve=v(me);_t(Ve,()=>t.errorIcon??kt),i(se,me)},Qn=se=>{var me=m(),Ve=v(me);{var Hn=ie=>{var ye=m(),Ge=v(ye);_t(Ge,()=>t.warningIcon??kt),i(ie,ye)},Rn=ie=>{var ye=m(),Ge=v(ye);{var Fn=We=>{var nn=m(),Nn=v(nn);_t(Nn,()=>t.infoIcon??kt),i(We,nn)};A(Ge,We=>{n(O)==="info"&&We(Fn)},!0)}i(ie,ye)};A(Ve,ie=>{n(O)==="warning"?ie(Hn):ie(Rn,!1)},!0)}i(se,me)};A(je,se=>{n(O)==="error"?se(kn):se(Qn,!1)},!0)}i(ae,ve)};A(Ot,ae=>{n(O)==="success"?ae(Mt):ae(ge,!1)},!0)}i(nt,p)};A(J,nt=>{t.toast.icon?nt(W):nt(z,!1)})}i(I,N)};A(G,I=>{t.toast.type!=="loading"&&I(u)})}lt(c),rt(I=>qt(c,1,I),[()=>{var I,N,J;return Ut(Nt((I=n(vt))==null?void 0:I.icon,(J=(N=t.toast)==null?void 0:N.classes)==null?void 0:J.icon))}]),i(C,c)};A(P,C=>{(n(O)||t.toast.icon||t.toast.promise)&&t.toast.icon!==null&&(n($)!==null||t.toast.icon)&&C(E)})}var B=$t(P,2),x=mt(B),tt=mt(x);{var dt=C=>{var c=m(),y=v(c);{var L=u=>{const I=T(()=>t.toast.title);var N=m(),J=v(N);pt(J,()=>n(I),(W,z)=>{z(W,Ze(()=>t.toast.componentProps))}),i(u,N)},G=u=>{var I=rn();rt(()=>Ce(I,t.toast.title)),i(u,I)};A(y,u=>{typeof t.toast.title!="string"?u(L):u(G,!1)})}i(C,c)};A(tt,C=>{t.toast.title&&C(dt)})}lt(x);var et=$t(x,2);{var X=C=>{var c=Xa(),y=mt(c);{var L=u=>{const I=T(()=>t.toast.description);var N=m(),J=v(N);pt(J,()=>n(I),(W,z)=>{z(W,Ze(()=>t.toast.componentProps))}),i(u,N)},G=u=>{var I=rn();rt(()=>Ce(I,t.toast.description)),i(u,I)};A(y,u=>{typeof t.toast.description!="string"?u(L):u(G,!1)})}lt(c),rt(u=>qt(c,1,u),[()=>{var u,I;return Ut(Nt(o(),n(Bt),(u=n(vt))==null?void 0:u.description,(I=t.toast.classes)==null?void 0:I.description))}]),i(C,c)};A(et,C=>{t.toast.description&&C(X)})}lt(B);var b=$t(B,2);{var it=C=>{var c=m(),y=v(c);{var L=u=>{var I=m(),N=v(I);pt(N,()=>t.toast.cancel,(J,W)=>{W(J,{})}),i(u,I)},G=u=>{var I=m(),N=v(I);{var J=W=>{var z=pa();z.__click=[Ja,t,gt,_];var nt=mt(z,!0);lt(z),rt(p=>{Ye(z,t.toast.cancelButtonStyle??s()),qt(z,1,p),Ce(nt,t.toast.cancel.label)},[()=>{var p,Ot,Mt;return Ut(Nt((p=n(vt))==null?void 0:p.cancelButton,(Mt=(Ot=t.toast)==null?void 0:Ot.classes)==null?void 0:Mt.cancelButton))}]),i(W,z)};A(N,W=>{Le(t.toast.cancel)&&W(J)},!0)}i(u,I)};A(y,u=>{typeof t.toast.cancel=="function"?u(L):u(G,!1)})}i(C,c)};A(b,C=>{t.toast.cancel&&C(it)})}var It=$t(b,2);{var Tt=C=>{var c=m(),y=v(c);{var L=u=>{var I=m(),N=v(I);pt(N,()=>t.toast.action,(J,W)=>{W(J,{})}),i(u,I)},G=u=>{var I=m(),N=v(I);{var J=W=>{var z=ts();z.__click=[$a,t,_];var nt=mt(z,!0);lt(z),rt(p=>{Ye(z,t.toast.actionButtonStyle??l()),qt(z,1,p),Ce(nt,t.toast.action.label)},[()=>{var p,Ot,Mt;return Ut(Nt((p=n(vt))==null?void 0:p.actionButton,(Mt=(Ot=t.toast)==null?void 0:Ot.classes)==null?void 0:Mt.actionButton))}]),i(W,z)};A(N,W=>{Le(t.toast.action)&&W(J)},!0)}i(u,I)};A(y,u=>{typeof t.toast.action=="function"?u(L):u(G,!1)})}i(C,c)};A(It,C=>{t.toast.action&&C(Tt)})}rt(C=>qt(x,1,C),[()=>{var C,c,y;return Ut(Nt((C=n(vt))==null?void 0:C.title,(y=(c=t.toast)==null?void 0:c.classes)==null?void 0:y.title))}]),i(d,g)};A(qe,d=>{t.toast.component?d(Ke):d(ze,!1)})}lt(M),Cn(M,d=>h(q,d),()=>n(q)),rt((d,g,P,E)=>{qt(M,1,d),S(M,"data-rich-colors",t.toast.richColors??R()),S(M,"data-styled",!(t.toast.component||t.toast.unstyled||D())),S(M,"data-mounted",n(w)),S(M,"data-promise",g),S(M,"data-swiped",n(Pt)),S(M,"data-removed",n(Q)),S(M,"data-visible",n(ht)),S(M,"data-y-position",n(Ie)[0]),S(M,"data-x-position",n(Ie)[1]),S(M,"data-index",t.index),S(M,"data-front",n(Et)),S(M,"data-swiping",n(bt)),S(M,"data-dismissable",n(gt)),S(M,"data-type",n(O)),S(M,"data-invert",n(Re)),S(M,"data-swipe-out",n(Dt)),S(M,"data-swipe-direction",n(wt)),S(M,"data-expanded",P),Me=Ye(M,`${t.style} ${t.toast.style}`,Me,E)},[()=>{var d,g,P,E,B,x;return Ut(Nt(t.class,n(Ht),(d=n(vt))==null?void 0:d.toast,(P=(g=t.toast)==null?void 0:g.classes)==null?void 0:P.toast,(E=n(vt))==null?void 0:E[n(O)],(x=(B=t.toast)==null?void 0:B.classes)==null?void 0:x[n(O)]))},()=>!!t.toast.promise,()=>!!(t.expanded||t.expandByDefault&&n(w)),()=>({"--index":t.index,"--toasts-before":t.index,"--z-index":st.toasts.length-t.index,"--offset":`${n(Q)?n(H):n(f)}px`,"--initial-height":t.expandByDefault?"auto":`${n(V)}px`})]),ca("dragend",M,Ft),i(e,M),ee()}ua(["pointermove","pointerup","pointerdown","click"]);var ss=xe('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" height="20" width="20" data-sonner-success-icon=""><path fill-rule="evenodd" d="M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z" clip-rule="evenodd"></path></svg>');function is(e){var t=ss();i(e,t)}var os=xe('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" height="20" width="20" data-sonner-error-icon=""><path fill-rule="evenodd" d="M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z" clip-rule="evenodd"></path></svg>');function rs(e){var t=os();i(e,t)}var ls=xe('<svg viewBox="0 0 64 64" fill="currentColor" height="20" width="20" data-sonner-warning-icon="" xmlns="http://www.w3.org/2000/svg"><path d="M32.427,7.987c2.183,0.124 4,1.165 5.096,3.281l17.936,36.208c1.739,3.66 -0.954,8.585 -5.373,8.656l-36.119,0c-4.022,-0.064 -7.322,-4.631 -5.352,-8.696l18.271,-36.207c0.342,-0.65 0.498,-0.838 0.793,-1.179c1.186,-1.375 2.483,-2.111 4.748,-2.063Zm-0.295,3.997c-0.687,0.034 -1.316,0.419 -1.659,1.017c-6.312,11.979 -12.397,24.081 -18.301,36.267c-0.546,1.225 0.391,2.797 1.762,2.863c12.06,0.195 24.125,0.195 36.185,0c1.325,-0.064 2.321,-1.584 1.769,-2.85c-5.793,-12.184 -11.765,-24.286 -17.966,-36.267c-0.366,-0.651 -0.903,-1.042 -1.79,-1.03Z"></path><path d="M33.631,40.581l-3.348,0l-0.368,-16.449l4.1,0l-0.384,16.449Zm-3.828,5.03c0,-0.609 0.197,-1.113 0.592,-1.514c0.396,-0.4 0.935,-0.601 1.618,-0.601c0.684,0 1.223,0.201 1.618,0.601c0.395,0.401 0.593,0.905 0.593,1.514c0,0.587 -0.193,1.078 -0.577,1.473c-0.385,0.395 -0.929,0.593 -1.634,0.593c-0.705,0 -1.249,-0.198 -1.634,-0.593c-0.384,-0.395 -0.576,-0.886 -0.576,-1.473Z"></path></svg>');function cs(e){var t=ls();i(e,t)}var us=xe('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" height="20" width="20" data-sonner-info-icon=""><path fill-rule="evenodd" d="M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z" clip-rule="evenodd"></path></svg>');function ds(e){var t=us();i(e,t)}var fs=xe('<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" data-sonner-close-icon=""><line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line></svg>');function hs(e){var t=fs();i(e,t)}const gs=3,Ln="24px",Sn="16px",vs=4e3,ms=356,ys=14,Xe="dark",Pe="light";function _s(e,t){const a={};return[e,t].forEach((s,l)=>{const o=l===1,D=o?"--mobile-offset":"--offset",R=o?Sn:Ln;function ot(w){["top","right","bottom","left"].forEach(Q=>{a[`${D}-${Q}`]=typeof w=="number"?`${w}px`:w})}typeof s=="number"||typeof s=="string"?ot(s):typeof s=="object"?["top","right","bottom","left"].forEach(w=>{const Q=s[w];Q===void 0?a[`${D}-${w}`]=R:a[`${D}-${w}`]=typeof Q=="number"?`${Q}px`:Q}):ot(R)}),a}var bs=ct("<ol></ol>"),ws=ct('<section aria-live="polite" aria-relevant="additions text" aria-atomic="false" class="svelte-nbs0zk"><!></section>');function xs(e,t){te(t,!0);function a(f){return f!=="system"?f:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?Xe:Pe}let s=k(t,"invert",3,!1),l=k(t,"position",3,"bottom-right"),o=k(t,"hotkey",19,()=>["altKey","KeyT"]),D=k(t,"expand",3,!1),R=k(t,"closeButton",3,!1),ot=k(t,"offset",3,Ln),w=k(t,"mobileOffset",3,Sn),Q=k(t,"theme",3,"light"),bt=k(t,"richColors",3,!1),Dt=k(t,"duration",3,vs),Pt=k(t,"visibleToasts",3,gs),H=k(t,"toastOptions",19,()=>({})),V=k(t,"dir",7,"auto"),F=k(t,"gap",3,ys),q=k(t,"containerAriaLabel",3,"Notifications"),K=k(t,"closeButtonAriaLabel",3,"Close toast"),wt=la(t,["$$slots","$$events","$$legacy","invert","position","hotkey","expand","closeButton","offset","mobileOffset","theme","richColors","duration","visibleToasts","toastOptions","dir","gap","loadingIcon","successIcon","errorIcon","warningIcon","closeIcon","infoIcon","containerAriaLabel","class","closeButtonAriaLabel","onblur","onfocus","onmouseenter","onmousemove","onmouseleave","ondragend","onpointerdown","onpointerup"]);function Et(){if(V()!=="auto")return V();if(typeof window>"u"||typeof document>"u")return"ltr";const f=document.documentElement.getAttribute("dir");return f==="auto"||!f?(Qt(()=>V(window.getComputedStyle(document.documentElement).direction??"ltr")),V()):(Qt(()=>V(f)),f)}const ht=T(()=>Array.from(new Set([l(),...st.toasts.filter(f=>f.position).map(f=>f.position)].filter(Boolean))));let O=Y(!1),gt=Y(!1),Ht=Y(Tn(a(Q()))),Bt=Y(void 0),ut=Y(null),Xt=Y(!1);const ke=T(()=>o().join("+").replace(/Key/g,"").replace(/Digit/g,""));Vt(()=>{st.toasts.length<=1&&h(O,!1)}),Vt(()=>{const f=st.toasts.filter(_=>_.dismiss&&!_.delete);if(f.length>0){const _=st.toasts.map(Z=>f.find(xt=>xt.id===Z.id)?{...Z,delete:!0}:Z);st.toasts=_}}),Vt(()=>()=>{n(Bt)&&n(ut)&&(n(ut).focus({preventScroll:!0}),h(ut,null),h(Xt,!1))}),Se(()=>(st.reset(),Be(document,"keydown",_=>{var Rt,xt;o().every(ne=>_[ne]||_.code===ne)&&(h(O,!0),(Rt=n(Bt))==null||Rt.focus()),_.code==="Escape"&&(document.activeElement===n(Bt)||(xt=n(Bt))!=null&&xt.contains(document.activeElement))&&h(O,!1)}))),Vt(()=>{if(Q()!=="system"&&h(Ht,Q()),typeof window<"u"){Q()==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?h(Ht,Xe):h(Ht,Pe));const f=window.matchMedia("(prefers-color-scheme: dark)"),_=({matches:Z})=>{h(Ht,Z?Xe:Pe,!0)};"addEventListener"in f?f.addEventListener("change",_):f.addListener(_)}});const Gt=f=>{var _;(_=t.onblur)==null||_.call(t,f),n(Xt)&&!f.currentTarget.contains(f.relatedTarget)&&(h(Xt,!1),n(ut)&&(n(ut).focus({preventScroll:!0}),h(ut,null)))},Ie=f=>{var Z;(Z=t.onfocus)==null||Z.call(t,f),!(f.target instanceof HTMLElement&&f.target.dataset.dismissable==="false")&&(n(Xt)||(h(Xt,!0),h(ut,f.relatedTarget,!0)))},Qe=f=>{var Z;(Z=t.onpointerdown)==null||Z.call(t,f),!(f.target instanceof HTMLElement&&f.target.dataset.dismissable==="false")&&h(gt,!0)},He=f=>{var _;(_=t.onmouseenter)==null||_.call(t,f),h(O,!0)},Re=f=>{var _;(_=t.onmouseleave)==null||_.call(t,f),n(gt)||h(O,!1)},fe=f=>{var _;(_=t.onmousemove)==null||_.call(t,f),h(O,!0)},vt=f=>{var _;(_=t.ondragend)==null||_.call(t,f),h(O,!1)},Fe=f=>{var _;(_=t.onpointerup)==null||_.call(t,f),h(gt,!1)};Fa.set(new ea);var Jt=ws();S(Jt,"tabindex",-1);var he=mt(Jt);{var Te=f=>{var _=m(),Z=v(_);Ee(Z,18,()=>n(ht),Rt=>Rt,(Rt,xt,ne,en)=>{const Oe=T(()=>{const[$,M]=xt.split("-");return{y:$,x:M}}),Lt=T(()=>_s(ot(),w()));var Ft=bs();na(Ft,($,M)=>({tabindex:-1,dir:$,class:t.class,"data-sonner-toaster":!0,"data-sonner-theme":n(Ht),"data-y-position":n(Oe).y,"data-x-position":n(Oe).x,style:t.style,onblur:Gt,onfocus:Ie,onmouseenter:He,onmousemove:fe,onmouseleave:Re,ondragend:vt,onpointerdown:Qe,onpointerup:Fe,...wt,[aa]:M}),[Et,()=>{var $;return{"--front-toast-height":`${($=st.heights[0])==null?void 0:$.height}px`,"--width":`${ms}px`,"--gap":`${F()}px`,"--offset-top":n(Lt)["--offset-top"],"--offset-right":n(Lt)["--offset-right"],"--offset-bottom":n(Lt)["--offset-bottom"],"--offset-left":n(Lt)["--offset-left"],"--mobile-offset-top":n(Lt)["--mobile-offset-top"],"--mobile-offset-right":n(Lt)["--mobile-offset-right"],"--mobile-offset-bottom":n(Lt)["--mobile-offset-bottom"],"--mobile-offset-left":n(Lt)["--mobile-offset-left"]}}],void 0,"svelte-nbs0zk"),Ee(Ft,23,()=>st.toasts.filter($=>!$.position&&n(ne)===0||$.position===xt),$=>$.id,($,M,Me,Ne)=>{{const Ue=b=>{var it=m(),It=v(it);{var Tt=c=>{var y=m(),L=v(y);_t(L,()=>t.successIcon??kt),i(c,y)},C=c=>{var y=m(),L=v(y);{var G=u=>{is(u)};A(L,u=>{t.successIcon!==null&&u(G)},!0)}i(c,y)};A(It,c=>{t.successIcon?c(Tt):c(C,!1)})}i(b,it)},qe=b=>{var it=m(),It=v(it);{var Tt=c=>{var y=m(),L=v(y);_t(L,()=>t.errorIcon??kt),i(c,y)},C=c=>{var y=m(),L=v(y);{var G=u=>{rs(u)};A(L,u=>{t.errorIcon!==null&&u(G)},!0)}i(c,y)};A(It,c=>{t.errorIcon?c(Tt):c(C,!1)})}i(b,it)},Ke=b=>{var it=m(),It=v(it);{var Tt=c=>{var y=m(),L=v(y);_t(L,()=>t.warningIcon??kt),i(c,y)},C=c=>{var y=m(),L=v(y);{var G=u=>{cs(u)};A(L,u=>{t.warningIcon!==null&&u(G)},!0)}i(c,y)};A(It,c=>{t.warningIcon?c(Tt):c(C,!1)})}i(b,it)},ze=b=>{var it=m(),It=v(it);{var Tt=c=>{var y=m(),L=v(y);_t(L,()=>t.infoIcon??kt),i(c,y)},C=c=>{var y=m(),L=v(y);{var G=u=>{ds(u)};A(L,u=>{t.infoIcon!==null&&u(G)},!0)}i(c,y)};A(It,c=>{t.infoIcon?c(Tt):c(C,!1)})}i(b,it)},d=b=>{var it=m(),It=v(it);{var Tt=c=>{var y=m(),L=v(y);_t(L,()=>t.closeIcon??kt),i(c,y)},C=c=>{var y=m(),L=v(y);{var G=u=>{hs(u)};A(L,u=>{t.closeIcon!==null&&u(G)},!0)}i(c,y)};A(It,c=>{t.closeIcon?c(Tt):c(C,!1)})}i(b,it)};let g=T(()=>{var b;return((b=H())==null?void 0:b.duration)??Dt()}),P=T(()=>{var b;return((b=H())==null?void 0:b.class)??""}),E=T(()=>{var b;return((b=H())==null?void 0:b.descriptionClass)||""}),B=T(()=>{var b;return((b=H())==null?void 0:b.style)??""}),x=T(()=>H().classes||{}),tt=T(()=>H().unstyled??!1),dt=T(()=>{var b;return((b=H())==null?void 0:b.cancelButtonStyle)??""}),et=T(()=>{var b;return((b=H())==null?void 0:b.actionButtonStyle)??""}),X=T(()=>{var b;return((b=H())==null?void 0:b.closeButtonAriaLabel)??K()});as($,{get index(){return n(Me)},get toast(){return n(M)},get defaultRichColors(){return bt()},get duration(){return n(g)},get class(){return n(P)},get descriptionClass(){return n(E)},get invert(){return s()},get visibleToasts(){return Pt()},get closeButton(){return R()},get interacting(){return n(gt)},get position(){return xt},get style(){return n(B)},get classes(){return n(x)},get unstyled(){return n(tt)},get cancelButtonStyle(){return n(dt)},get actionButtonStyle(){return n(et)},get closeButtonAriaLabel(){return n(X)},get expandByDefault(){return D()},get expanded(){return n(O)},get loadingIcon(){return t.loadingIcon},successIcon:Ue,errorIcon:qe,warningIcon:Ke,infoIcon:ze,closeIcon:d,$$slots:{successIcon:!0,errorIcon:!0,warningIcon:!0,infoIcon:!0,closeIcon:!0}})}}),lt(Ft),Cn(Ft,$=>h(Bt,$),()=>n(Bt)),rt(()=>Ft.dir=Ft.dir),i(Rt,Ft)}),i(f,_)};A(he,f=>{st.toasts.length>0&&f(Te)})}lt(Jt),rt(()=>S(Jt,"aria-label",`${q()??""} ${n(ke)??""}`)),i(e,Jt),ee()}var Is=ct('<div class="flex h-full w-full flex-col"><!> <!></div>');function qs(e,t){te(t,!0);const a=new Bn({defaultOptions:{queries:{enabled:ya}}});Se(()=>{{const{initSettings:s}=sa();s()}}),Oa(e,{get i18n(){return ia},children:(s,l)=>{Pa(s,{get client(){return a},children:(o,D)=>{var R=Is(),ot=mt(R);_t(ot,()=>t.children);var w=$t(ot,2);xs(w,{richColors:!0}),lt(R),i(o,R)},$$slots:{default:!0}})},$$slots:{default:!0}}),ee()}export{qs as component,Us as universal};
@@ -0,0 +1 @@
1
+ import"../chunks/CWj6FrbW.js";import"../chunks/69_IOA4Y.js";import{p as c,f as l,t as v,a as u,c as o,r as e,s as _}from"../chunks/Frwd2CjB.js";import{s as p}from"../chunks/H60ATh8g.js";import{f as g,a as x}from"../chunks/CiaNZCBa.js";import{i as d}from"../chunks/DzBTnFhV.js";import{p as m}from"../chunks/DSxvnAMh.js";var b=g("<h1> </h1> <p> </p>",1);function A(i,f){c(f,!1),d();var t=b(),r=l(t),n=o(r,!0);e(r);var a=_(r,2),h=o(a,!0);e(a),v(()=>{var s;p(n,m.status),p(h,(s=m.error)==null?void 0:s.message)}),x(i,t),u()}export{A as component};
@@ -0,0 +1 @@
1
+ import"../chunks/CWj6FrbW.js";import{p as S,u as $,g as a,a as _,b as o}from"../chunks/Frwd2CjB.js";import{s as i,a as h}from"../chunks/-DXuGN29.js";import"../chunks/Cqo0Vpvt.js";import{u as T}from"../chunks/qIv1kPyv.js";import"../chunks/D_ynJAfY.js";import"../chunks/Bqz7dyEC.js";import"../chunks/D5w4xp5l.js";import"../chunks/DSxvnAMh.js";import"../chunks/69_IOA4Y.js";import"../chunks/DQ8aZ1o-.js";import{u as b}from"../chunks/Cy4fgWTG.js";import"../chunks/DzX_yyqb.js";import{S as G}from"../chunks/BeWf8-vJ.js";function B(p,t){S(t,!0);const m=()=>i(u,"$lastGridType",s),e=()=>i(n,"$sampleSize",s),[s,d]=h(),{datasetId:r,sampleSize:n,selectedAnnotationFilterIds:l,globalStorage:{textEmbedding:g}}=t.data,{lastGridType:u}=T(),c=o(()=>b({dataset_id:r})),f=o(()=>a(c).clearTagsSelected);$(()=>{m()!=="samples"&&a(f)()}),G(p,{get sampleHeight(){return e().height},get sampleWidth(){return e().width},get textEmbedding(){return g},get dataset_id(){return r},get selectedAnnotationFilterIds(){return l}}),_(),d()}export{B as component};
@@ -0,0 +1 @@
1
+ import{w as I,m as r,p as $,f as j,a as y,$ as N,g as h,b as v}from"../chunks/Frwd2CjB.js";import{b as P}from"../chunks/D5w4xp5l.js";import{c as L}from"../chunks/DD63uD-T.js";import{u as A}from"../chunks/qIv1kPyv.js";import"../chunks/CWj6FrbW.js";import"../chunks/69_IOA4Y.js";import{e as k}from"../chunks/Dug7Bq1S.js";import{c as E,a as T}from"../chunks/CiaNZCBa.js";import{i as D,a as O,s as F}from"../chunks/-DXuGN29.js";import{p as x}from"../chunks/DSxvnAMh.js";import{g as b}from"../chunks/DQ8aZ1o-.js";import{r as w}from"../chunks/CfQ4mGwl.js";import{S as M}from"../chunks/CSCQddQS.js";const z=({dataset_id:n,sampleIndex:s,tagIds:a,annotationLabelIds:u,min_width:f,max_width:l,min_height:o,max_height:p,textEmbedding:m,metadataValues:c})=>{const i=I({isLoading:!1});return(async()=>{i.update(e=>({...e,isLoading:!0,error:void 0}));try{const{data:e}=await P({path:{dataset_id:n},body:{pagination:{offset:s<1?0:s-1,limit:3},filters:{annotation_label_ids:u,tag_ids:a,width:{min:f,max:l},height:{min:o,max:p},metadata_filters:c?L(c):void 0},text_embedding:m},throwOnError:!0}),{setSamplesTotalCount:t}=A();t(e==null?void 0:e.total_count);let d;const g=s>0?e.data[0]:void 0;e.data.length>2&&(d=s==0?e.data[1]:e.data[2]),i.update(S=>({...S,isLoading:!1,sampleNext:d,samplePrevious:g,error:void 0}))}catch(e){i.update(t=>({...t,isLoading:!1,error:e.message||"Failed to load adjacent samples"}))}})(),i},C=async({parent:n,params:{dataset_id:s,sampleId:a,sampleIndex:u}})=>{var _,e,t,d,g;const{samplesSelectedTagsIds:f,samplesSelectedAnnotationLabelsIds:l,samplesDimensions:o,samplesTextEmbedding:p}=await n(),m=parseInt(u,10),{metadataValues:c}=A();return{sampleAdjacents:z({dataset_id:s,sampleIndex:m,tagIds:Array.from(r(f)),annotationLabelIds:Array.from(r(l)),min_width:(_=r(o))==null?void 0:_.min_width,max_width:(e=r(o))==null?void 0:e.max_width,min_height:(t=r(o))==null?void 0:t.min_height,max_height:(d=r(o))==null?void 0:d.max_height,textEmbedding:(g=r(p))==null?void 0:g.embedding,metadataValues:r(c)}),sampleIndex:m}},ee=Object.freeze(Object.defineProperty({__proto__:null,load:C},Symbol.toStringTag,{value:"Module"}));function G(n,s){$(s,!0);const a=()=>F(h(o),"$sampleAdjacents",u),[u,f]=O(),l=v(()=>x.data.sampleIndex),o=v(()=>x.data.sampleAdjacents),p=()=>{a().sampleNext&&b(w.toSample({sampleId:a().sampleNext.sample_id,datasetId:a().sampleNext.dataset_id,sampleIndex:h(l)+1}),{invalidateAll:!0})},m=()=>{a().samplePrevious&&b(w.toSample({sampleId:a().samplePrevious.sample_id,datasetId:a().samplePrevious.dataset_id,sampleIndex:h(l)-1}),{invalidateAll:!0})},c=t=>{switch(t.key){case"ArrowRight":p();break;case"ArrowLeft":m();break}};var i=E();k("keydown",N,c);var _=j(i);{var e=t=>{{let d=v(()=>!!a().samplePrevious),g=v(()=>!!a().sampleNext);M(t,{get hasPrevious(){return h(d)},get hasNext(){return h(g)},onPrevious:m,onNext:p})}};D(_,t=>{a()&&t(e)})}T(n,i),y(),f()}function ae(n){G(n,{})}export{ae as component,ee as universal};