solid-ui 5.0.2-0 → 5.0.2-2

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 (390) hide show
  1. package/dist/_virtual/_rolldown/runtime.esm.js +1 -2
  2. package/dist/_virtual/~icons/app/solid-emblem.esm.js +1 -2
  3. package/dist/_virtual/~icons/lucide/book-user.esm.js +1 -2
  4. package/dist/_virtual/~icons/lucide/chevron-down.esm.js +1 -2
  5. package/dist/_virtual/~icons/lucide/circle-user.esm.js +1 -2
  6. package/dist/_virtual/~icons/lucide/circle-x.esm.js +1 -2
  7. package/dist/_virtual/~icons/lucide/folder-open.cjs.js +2 -0
  8. package/dist/_virtual/~icons/lucide/folder-open.cjs.js.map +1 -0
  9. package/dist/_virtual/~icons/lucide/folder-open.esm.js +10 -0
  10. package/dist/_virtual/~icons/lucide/folder-open.esm.js.map +1 -0
  11. package/dist/_virtual/~icons/lucide/folder.cjs.js +2 -0
  12. package/dist/_virtual/~icons/lucide/folder.cjs.js.map +1 -0
  13. package/dist/_virtual/~icons/lucide/folder.esm.js +10 -0
  14. package/dist/_virtual/~icons/lucide/folder.esm.js.map +1 -0
  15. package/dist/_virtual/~icons/lucide/globe.esm.js +1 -2
  16. package/dist/_virtual/~icons/lucide/link.esm.js +1 -2
  17. package/dist/_virtual/~icons/lucide/log-in.esm.js +1 -2
  18. package/dist/_virtual/~icons/lucide/log-out.esm.js +1 -2
  19. package/dist/_virtual/~icons/lucide/square-arrow-out-up-right.esm.js +1 -2
  20. package/dist/_virtual/~icons/lucide/triangle-alert.esm.js +1 -2
  21. package/dist/_virtual/~icons/lucide/user-round.esm.js +1 -2
  22. package/dist/_virtual/~icons/lucide/user.esm.js +1 -2
  23. package/dist/_virtual/~icons/lucide/users.esm.js +1 -2
  24. package/dist/_virtual/~icons/lucide/x.esm.js +1 -2
  25. package/dist/_virtual/~icons/svg-spinners/180-ring.esm.js +1 -2
  26. package/dist/_virtual/~icons/svg-spinners/3-dots-fade.esm.js +1 -2
  27. package/dist/acl/access-controller.esm.js +1 -2
  28. package/dist/acl/access-groups.esm.js +1 -2
  29. package/dist/acl/acl-control.esm.js +1 -2
  30. package/dist/acl/acl.esm.js +1 -2
  31. package/dist/acl/add-agent-buttons.esm.js +1 -2
  32. package/dist/acl/index.esm.js +1 -2
  33. package/dist/chat/bookmarks.esm.js +1 -2
  34. package/dist/chat/chatLogic.esm.js +1 -2
  35. package/dist/chat/dateFolder.esm.js +1 -2
  36. package/dist/chat/infinite.cjs.js +1 -1
  37. package/dist/chat/infinite.cjs.js.map +1 -1
  38. package/dist/chat/infinite.esm.js +2 -3
  39. package/dist/chat/infinite.esm.js.map +1 -1
  40. package/dist/chat/keys.esm.js +1 -2
  41. package/dist/chat/message.esm.js +1 -2
  42. package/dist/chat/messageTools.esm.js +1 -2
  43. package/dist/chat/signature.esm.js +0 -1
  44. package/dist/chunks/{DialogProvider-B7oVYKJO.js → DialogProvider-C89v7x0r.js} +5 -8
  45. package/dist/chunks/{DialogProvider-B7oVYKJO.js.map → DialogProvider-C89v7x0r.js.map} +1 -1
  46. package/dist/chunks/{access-control-modal-eOv2-U27.js → access-control-modal-Dcg6-f4V.js} +924 -540
  47. package/dist/chunks/access-control-modal-Dcg6-f4V.js.map +1 -0
  48. package/dist/chunks/{account-DpmYJEd-.js → account-D6JK-n7u.js} +16 -21
  49. package/dist/chunks/{account-DpmYJEd-.js.map → account-D6JK-n7u.js.map} +1 -1
  50. package/dist/chunks/{auth-Hp8M6TQf.js → auth-B_abPDvH.js} +28 -31
  51. package/dist/chunks/auth-B_abPDvH.js.map +1 -0
  52. package/dist/chunks/{avatar-D5rcw6gN.js → avatar-BR3COVSQ.js} +6 -9
  53. package/dist/chunks/{avatar-D5rcw6gN.js.map → avatar-BR3COVSQ.js.map} +1 -1
  54. package/dist/chunks/{button-lol95DqR.js → button-D6qO2idW.js} +5 -8
  55. package/dist/chunks/{button-lol95DqR.js.map → button-D6qO2idW.js.map} +1 -1
  56. package/dist/chunks/{chevron-down-ujxRg3MD.js → chevron-down-CqUEolao.js} +2 -3
  57. package/dist/chunks/chevron-down-CqUEolao.js.map +1 -0
  58. package/dist/chunks/{chunk.UEBQI7VV-OBPERnuy.js → chunk.UEBQI7VV-lcP-fpUk.js} +14 -23
  59. package/dist/chunks/{chunk.UEBQI7VV-OBPERnuy.js.map → chunk.UEBQI7VV-lcP-fpUk.js.map} +1 -1
  60. package/dist/chunks/{combobox-Dmv-TZtI.js → combobox-fSTp9qoT.js} +11 -15
  61. package/dist/chunks/combobox-fSTp9qoT.js.map +1 -0
  62. package/dist/chunks/{combobox-option-B-Hksiq2.js → combobox-option-DOtGuKel.js} +4 -6
  63. package/dist/chunks/{combobox-option-B-Hksiq2.js.map → combobox-option-DOtGuKel.js.map} +1 -1
  64. package/dist/chunks/{components-Bdqizu8x.js → components-C8c2Ucm5.js} +17 -33
  65. package/dist/chunks/{components-Bdqizu8x.js.map → components-C8c2Ucm5.js.map} +1 -1
  66. package/dist/chunks/{dialog-DYgcCurb.js → dialog-CgYK767T.js} +8 -10
  67. package/dist/chunks/{dialog-DYgcCurb.js.map → dialog-CgYK767T.js.map} +1 -1
  68. package/dist/chunks/{dialog-content-jx08y2Oa.js → dialog-content-DjwRH1ci.js} +4 -6
  69. package/dist/chunks/{dialog-content-jx08y2Oa.js.map → dialog-content-DjwRH1ci.js.map} +1 -1
  70. package/dist/chunks/{dialog-footer-Bhl8k1PX.js → dialog-footer-GQWi8lfB.js} +4 -6
  71. package/dist/chunks/{dialog-footer-Bhl8k1PX.js.map → dialog-footer-GQWi8lfB.js.map} +1 -1
  72. package/dist/chunks/{dialog-header-Dn6PQzFB.js → dialog-header-c3qOMQfb.js} +4 -6
  73. package/dist/chunks/{dialog-header-Dn6PQzFB.js.map → dialog-header-c3qOMQfb.js.map} +1 -1
  74. package/dist/chunks/{dialogs-B6TfxrPt.js → dialogs-BmtLjMzg.js} +5 -7
  75. package/dist/chunks/{dialogs-B6TfxrPt.js.map → dialogs-BmtLjMzg.js.map} +1 -1
  76. package/dist/chunks/{dialogs-root-Qiucjj9u.js → dialogs-root-BcQo2XMF.js} +6 -8
  77. package/dist/chunks/{dialogs-root-Qiucjj9u.js.map → dialogs-root-BcQo2XMF.js.map} +1 -1
  78. package/dist/chunks/{error-state-DK1x-kNd.js → error-state-BD4_Wrkz.js} +6 -8
  79. package/dist/chunks/{error-state-DK1x-kNd.js.map → error-state-BD4_Wrkz.js.map} +1 -1
  80. package/dist/chunks/{guard-FbhNrJGh.js → guard-bTeM7wd7.js} +5 -7
  81. package/dist/chunks/{guard-FbhNrJGh.js.map → guard-bTeM7wd7.js.map} +1 -1
  82. package/dist/chunks/{index.esm-N8NHgFUj.js → index.esm-CECfD0e9.js} +3256 -3083
  83. package/dist/chunks/index.esm-CECfD0e9.js.map +1 -0
  84. package/dist/chunks/{input-lpqx_k53.js → input-Bz3l514j.js} +5 -7
  85. package/dist/chunks/{input-lpqx_k53.js.map → input-Bz3l514j.js.map} +1 -1
  86. package/dist/chunks/{jsonld-Djw57WRt.js → jsonld-CnfzCyCn.js} +4 -5
  87. package/dist/chunks/{jsonld-Djw57WRt.js.map → jsonld-CnfzCyCn.js.map} +1 -1
  88. package/dist/chunks/{login-button-DCq4Gi3_.js → login-button-Div4ZT4J.js} +6 -8
  89. package/dist/chunks/{login-button-DCq4Gi3_.js.map → login-button-Div4ZT4J.js.map} +1 -1
  90. package/dist/chunks/{logout-button-D3dJrsV4.js → logout-button-D3lqlnCX.js} +6 -8
  91. package/dist/chunks/{logout-button-D3dJrsV4.js.map → logout-button-D3lqlnCX.js.map} +1 -1
  92. package/dist/chunks/{menu-RJklqKQE.js → menu-D0k2fkiE.js} +22 -39
  93. package/dist/chunks/{menu-RJklqKQE.js.map → menu-D0k2fkiE.js.map} +1 -1
  94. package/dist/chunks/{menu-item-C2e0qj-v.js → menu-item-nfPpH4dN.js} +5 -7
  95. package/dist/chunks/{menu-item-C2e0qj-v.js.map → menu-item-nfPpH4dN.js.map} +1 -1
  96. package/dist/chunks/{photo-capture-DEMQNmzb.js → photo-capture-hJaJm4TM.js} +6 -8
  97. package/dist/chunks/{photo-capture-DEMQNmzb.js.map → photo-capture-hJaJm4TM.js.map} +1 -1
  98. package/dist/chunks/{photo-capture-modal-C7oESDQq.js → photo-capture-modal-BsHv6wmh.js} +9 -11
  99. package/dist/chunks/{photo-capture-modal-C7oESDQq.js.map → photo-capture-modal-BsHv6wmh.js.map} +1 -1
  100. package/dist/chunks/{provider-D9UgRI4G.js → provider-Dcd1NPYx.js} +7 -9
  101. package/dist/chunks/{provider-D9UgRI4G.js.map → provider-Dcd1NPYx.js.map} +1 -1
  102. package/dist/chunks/{query-BYu9q8lA.js → query-DjAOg-tk.js} +3 -5
  103. package/dist/chunks/{query-BYu9q8lA.js.map → query-DjAOg-tk.js.map} +1 -1
  104. package/dist/chunks/{rdf-form-BLgKdXP2.js → rdf-form-CmPnHKR-.js} +23 -25
  105. package/dist/chunks/{rdf-form-BLgKdXP2.js.map → rdf-form-CmPnHKR-.js.map} +1 -1
  106. package/dist/chunks/{rdf-input-DWnDpkXy.js → rdf-input-3AgoeCkJ.js} +48 -51
  107. package/dist/chunks/{rdf-input-DWnDpkXy.js.map → rdf-input-3AgoeCkJ.js.map} +1 -1
  108. package/dist/chunks/{select-CnkJMo_K.js → select-ClPkDkGl.js} +7 -10
  109. package/dist/chunks/{select-CnkJMo_K.js.map → select-ClPkDkGl.js.map} +1 -1
  110. package/dist/chunks/{select-option-B9HSZiTp.js → select-option-DQan7rcB.js} +4 -6
  111. package/dist/chunks/{select-option-B9HSZiTp.js.map → select-option-DQan7rcB.js.map} +1 -1
  112. package/dist/chunks/{show-dialog-eEW5yRBv.js → show-dialog-DAmFslrf.js} +2 -3
  113. package/dist/chunks/{show-dialog-eEW5yRBv.js.map → show-dialog-DAmFslrf.js.map} +1 -1
  114. package/dist/chunks/{signup-button-BQ4AWem2.js → signup-button-2fAoS0Nv.js} +6 -8
  115. package/dist/chunks/{signup-button-BQ4AWem2.js.map → signup-button-2fAoS0Nv.js.map} +1 -1
  116. package/dist/chunks/{solid-emblem-DNjQSX1z.js → solid-emblem-DwLdkGuO.js} +5 -8
  117. package/dist/chunks/{solid-emblem-DNjQSX1z.js.map → solid-emblem-DwLdkGuO.js.map} +1 -1
  118. package/dist/chunks/{src-DQMZZG1B.js → src-Dx7k_VIe.js} +2732 -2782
  119. package/dist/chunks/src-Dx7k_VIe.js.map +1 -0
  120. package/dist/chunks/{style-ChFDDB1c.js → style-w0Fl0xnd.js} +25 -29
  121. package/dist/chunks/{style-ChFDDB1c.js.map → style-w0Fl0xnd.js.map} +1 -1
  122. package/dist/chunks/{widgets-CVLwnfkU.js → widgets-BWpm5CPx.js} +694 -715
  123. package/dist/chunks/widgets-BWpm5CPx.js.map +1 -0
  124. package/dist/chunks/{x-BRRkraZN.js → x-D1JUUSOS.js} +2 -3
  125. package/dist/chunks/x-D1JUUSOS.js.map +1 -0
  126. package/dist/components/access-control-modal/AccessControlAddAccess.cjs.js +11 -5
  127. package/dist/components/access-control-modal/AccessControlAddAccess.cjs.js.map +1 -1
  128. package/dist/components/access-control-modal/AccessControlAddAccess.d.ts +1 -0
  129. package/dist/components/access-control-modal/AccessControlAddAccess.d.ts.map +1 -1
  130. package/dist/components/access-control-modal/AccessControlAddAccess.esm.js +75 -57
  131. package/dist/components/access-control-modal/AccessControlAddAccess.esm.js.map +1 -1
  132. package/dist/components/access-control-modal/AccessControlAddAccess.styles.cjs.js +1 -1
  133. package/dist/components/access-control-modal/AccessControlAddAccess.styles.cjs.js.map +1 -1
  134. package/dist/components/access-control-modal/AccessControlAddAccess.styles.esm.js +2 -3
  135. package/dist/components/access-control-modal/AccessControlAddAccess.styles.esm.js.map +1 -1
  136. package/dist/components/access-control-modal/AccessControlErrors.cjs.js +3 -2
  137. package/dist/components/access-control-modal/AccessControlErrors.cjs.js.map +1 -1
  138. package/dist/components/access-control-modal/AccessControlErrors.d.ts +1 -0
  139. package/dist/components/access-control-modal/AccessControlErrors.d.ts.map +1 -1
  140. package/dist/components/access-control-modal/AccessControlErrors.esm.js +6 -3
  141. package/dist/components/access-control-modal/AccessControlErrors.esm.js.map +1 -1
  142. package/dist/components/access-control-modal/AccessControlErrors.styles.esm.js +1 -2
  143. package/dist/components/access-control-modal/AccessControlGeneralAccess.cjs.js +5 -3
  144. package/dist/components/access-control-modal/AccessControlGeneralAccess.cjs.js.map +1 -1
  145. package/dist/components/access-control-modal/AccessControlGeneralAccess.d.ts +1 -0
  146. package/dist/components/access-control-modal/AccessControlGeneralAccess.d.ts.map +1 -1
  147. package/dist/components/access-control-modal/AccessControlGeneralAccess.esm.js +57 -45
  148. package/dist/components/access-control-modal/AccessControlGeneralAccess.esm.js.map +1 -1
  149. package/dist/components/access-control-modal/AccessControlGeneralAccess.styles.esm.js +1 -2
  150. package/dist/components/access-control-modal/AccessControlModal.cjs.js +112 -6
  151. package/dist/components/access-control-modal/AccessControlModal.cjs.js.map +1 -1
  152. package/dist/components/access-control-modal/AccessControlModal.d.ts +27 -0
  153. package/dist/components/access-control-modal/AccessControlModal.d.ts.map +1 -1
  154. package/dist/components/access-control-modal/AccessControlModal.esm.js +411 -127
  155. package/dist/components/access-control-modal/AccessControlModal.esm.js.map +1 -1
  156. package/dist/components/access-control-modal/AccessControlModal.styles.cjs.js +1 -1
  157. package/dist/components/access-control-modal/AccessControlModal.styles.cjs.js.map +1 -1
  158. package/dist/components/access-control-modal/AccessControlModal.styles.esm.js +2 -3
  159. package/dist/components/access-control-modal/AccessControlModal.styles.esm.js.map +1 -1
  160. package/dist/components/access-control-modal/AccessControlSharedAccess.cjs.js +6 -5
  161. package/dist/components/access-control-modal/AccessControlSharedAccess.cjs.js.map +1 -1
  162. package/dist/components/access-control-modal/AccessControlSharedAccess.d.ts +1 -0
  163. package/dist/components/access-control-modal/AccessControlSharedAccess.d.ts.map +1 -1
  164. package/dist/components/access-control-modal/AccessControlSharedAccess.esm.js +71 -55
  165. package/dist/components/access-control-modal/AccessControlSharedAccess.esm.js.map +1 -1
  166. package/dist/components/access-control-modal/AccessControlSharedAccess.styles.esm.js +1 -2
  167. package/dist/components/access-control-modal/accessGrantDrafts.cjs.js +1 -1
  168. package/dist/components/access-control-modal/accessGrantDrafts.cjs.js.map +1 -1
  169. package/dist/components/access-control-modal/accessGrantDrafts.d.ts.map +1 -1
  170. package/dist/components/access-control-modal/accessGrantDrafts.esm.js +6 -7
  171. package/dist/components/access-control-modal/accessGrantDrafts.esm.js.map +1 -1
  172. package/dist/components/access-control-modal/accessTargetResolver.cjs.js +1 -1
  173. package/dist/components/access-control-modal/accessTargetResolver.cjs.js.map +1 -1
  174. package/dist/components/access-control-modal/accessTargetResolver.d.ts +1 -0
  175. package/dist/components/access-control-modal/accessTargetResolver.d.ts.map +1 -1
  176. package/dist/components/access-control-modal/accessTargetResolver.esm.js +92 -46
  177. package/dist/components/access-control-modal/accessTargetResolver.esm.js.map +1 -1
  178. package/dist/components/access-control-modal/applyAccessChanges.cjs.js +1 -1
  179. package/dist/components/access-control-modal/applyAccessChanges.cjs.js.map +1 -1
  180. package/dist/components/access-control-modal/applyAccessChanges.d.ts +4 -2
  181. package/dist/components/access-control-modal/applyAccessChanges.d.ts.map +1 -1
  182. package/dist/components/access-control-modal/applyAccessChanges.esm.js +23 -15
  183. package/dist/components/access-control-modal/applyAccessChanges.esm.js.map +1 -1
  184. package/dist/components/access-control-modal/buildAccessChanges.esm.js +1 -2
  185. package/dist/components/access-control-modal/helpers.esm.js +1 -2
  186. package/dist/components/access-control-modal/index.esm.js +1 -2
  187. package/dist/components/access-control-modal/types.d.ts +6 -1
  188. package/dist/components/access-control-modal/types.d.ts.map +1 -1
  189. package/dist/components/access-control-modal.js +1 -1
  190. package/dist/components/account/Account.esm.js +1 -2
  191. package/dist/components/account/Account.styles.esm.js +1 -2
  192. package/dist/components/account/index.esm.js +1 -2
  193. package/dist/components/account.js +1 -1
  194. package/dist/components/avatar/Avatar.esm.js +1 -2
  195. package/dist/components/avatar/Avatar.styles.esm.js +1 -2
  196. package/dist/components/avatar/index.esm.js +1 -2
  197. package/dist/components/avatar.js +1 -1
  198. package/dist/components/button/Button.esm.js +1 -2
  199. package/dist/components/button/Button.styles.esm.js +1 -2
  200. package/dist/components/button/index.esm.js +1 -2
  201. package/dist/components/button.js +1 -1
  202. package/dist/components/combobox/Combobox.cjs.js +1 -0
  203. package/dist/components/combobox/Combobox.cjs.js.map +1 -1
  204. package/dist/components/combobox/Combobox.d.ts.map +1 -1
  205. package/dist/components/combobox/Combobox.esm.js +2 -2
  206. package/dist/components/combobox/Combobox.esm.js.map +1 -1
  207. package/dist/components/combobox/Combobox.styles.esm.js +1 -2
  208. package/dist/components/combobox/index.esm.js +1 -2
  209. package/dist/components/combobox-option/ComboboxOption.esm.js +1 -2
  210. package/dist/components/combobox-option/index.esm.js +1 -2
  211. package/dist/components/combobox-option.js +1 -1
  212. package/dist/components/combobox.js +1 -1
  213. package/dist/components/dialog/Dialog.esm.js +1 -2
  214. package/dist/components/dialog/Dialog.styles.esm.js +1 -2
  215. package/dist/components/dialog/index.esm.js +1 -2
  216. package/dist/components/dialog-content/DialogContent.esm.js +1 -2
  217. package/dist/components/dialog-content/DialogContent.styles.esm.js +1 -2
  218. package/dist/components/dialog-content/index.esm.js +1 -2
  219. package/dist/components/dialog-content.js +1 -1
  220. package/dist/components/dialog-footer/DialogFooter.esm.js +1 -2
  221. package/dist/components/dialog-footer/DialogFooter.styles.esm.js +1 -2
  222. package/dist/components/dialog-footer/index.esm.js +1 -2
  223. package/dist/components/dialog-footer.js +1 -1
  224. package/dist/components/dialog-header/DialogHeader.esm.js +1 -2
  225. package/dist/components/dialog-header/DialogHeader.styles.esm.js +1 -2
  226. package/dist/components/dialog-header/index.esm.js +1 -2
  227. package/dist/components/dialog-header.js +1 -1
  228. package/dist/components/dialog-provider/DialogProvider.esm.js +1 -2
  229. package/dist/components/dialog-provider/index.esm.js +1 -2
  230. package/dist/components/dialog-provider.js +2 -3
  231. package/dist/components/dialog.js +1 -1
  232. package/dist/components/dialogs-root/DialogsRoot.esm.js +1 -2
  233. package/dist/components/dialogs-root/index.esm.js +1 -2
  234. package/dist/components/dialogs-root.js +1 -1
  235. package/dist/components/error-state/ErrorState.esm.js +1 -2
  236. package/dist/components/error-state/ErrorState.styles.esm.js +1 -2
  237. package/dist/components/error-state.js +1 -1
  238. package/dist/components/guard/Guard.esm.js +1 -2
  239. package/dist/components/guard/index.esm.js +1 -2
  240. package/dist/components/guard.js +1 -1
  241. package/dist/components/input/Input.esm.js +1 -2
  242. package/dist/components/input/Input.styles.esm.js +1 -2
  243. package/dist/components/input/index.esm.js +1 -2
  244. package/dist/components/input.js +1 -1
  245. package/dist/components/login-button/LoginButton.esm.js +1 -2
  246. package/dist/components/login-button/index.esm.js +1 -2
  247. package/dist/components/login-button.js +1 -1
  248. package/dist/components/login-modal/LoginModal.esm.js +1 -2
  249. package/dist/components/login-modal/LoginModal.styles.esm.js +1 -2
  250. package/dist/components/login-modal/index.esm.js +1 -2
  251. package/dist/components/login-modal.js +1 -1
  252. package/dist/components/logout-button/LogoutButton.esm.js +1 -2
  253. package/dist/components/logout-button/index.esm.js +1 -2
  254. package/dist/components/logout-button.js +1 -1
  255. package/dist/components/menu/Menu.esm.js +1 -2
  256. package/dist/components/menu/Menu.styles.esm.js +1 -2
  257. package/dist/components/menu/index.esm.js +1 -2
  258. package/dist/components/menu-item/MenuItem.esm.js +1 -2
  259. package/dist/components/menu-item/MenuItem.styles.esm.js +1 -2
  260. package/dist/components/menu-item/index.esm.js +1 -2
  261. package/dist/components/menu-item.js +1 -1
  262. package/dist/components/menu.js +1 -1
  263. package/dist/components/photo-capture/PhotoCapture.esm.js +1 -2
  264. package/dist/components/photo-capture/index.esm.js +1 -2
  265. package/dist/components/photo-capture-modal/PhotoCaptureModal.cjs.js +1 -1
  266. package/dist/components/photo-capture-modal/PhotoCaptureModal.cjs.js.map +1 -1
  267. package/dist/components/photo-capture-modal/PhotoCaptureModal.esm.js +2 -3
  268. package/dist/components/photo-capture-modal/PhotoCaptureModal.esm.js.map +1 -1
  269. package/dist/components/photo-capture-modal/PhotoCaptureModal.styles.esm.js +1 -2
  270. package/dist/components/photo-capture-modal/index.esm.js +1 -2
  271. package/dist/components/photo-capture-modal.js +1 -1
  272. package/dist/components/photo-capture.js +1 -1
  273. package/dist/components/provider/Provider.esm.js +1 -2
  274. package/dist/components/provider/index.esm.js +1 -2
  275. package/dist/components/provider.js +1 -1
  276. package/dist/components/rdf-form/RDFForm.esm.js +1 -2
  277. package/dist/components/rdf-form/index.esm.js +1 -2
  278. package/dist/components/rdf-form.js +1 -1
  279. package/dist/components/rdf-input/RDFInput.esm.js +1 -2
  280. package/dist/components/rdf-input/index.esm.js +1 -2
  281. package/dist/components/rdf-input.js +1 -1
  282. package/dist/components/select/Select.esm.js +1 -2
  283. package/dist/components/select/Select.styles.esm.js +1 -2
  284. package/dist/components/select/index.esm.js +1 -2
  285. package/dist/components/select-option/SelectOption.esm.js +1 -2
  286. package/dist/components/select-option/index.esm.js +1 -2
  287. package/dist/components/select-option.js +1 -1
  288. package/dist/components/select.js +1 -1
  289. package/dist/components/signup-button/SignupButton.esm.js +1 -2
  290. package/dist/components/signup-button/index.esm.js +1 -2
  291. package/dist/components/signup-button.js +1 -1
  292. package/dist/components/solid-emblem/SolidEmblem.esm.js +1 -2
  293. package/dist/components/solid-emblem/SolidEmblem.styles.esm.js +1 -2
  294. package/dist/components/solid-emblem/index.esm.js +1 -2
  295. package/dist/components/solid-emblem.js +1 -1
  296. package/dist/components.js +28 -28
  297. package/dist/create/create.esm.js +1 -2
  298. package/dist/create/index.esm.js +1 -2
  299. package/dist/create/types.esm.js +1 -2
  300. package/dist/footer/index.esm.js +1 -2
  301. package/dist/header/empty-profile.esm.js +1 -2
  302. package/dist/header/index.esm.js +1 -2
  303. package/dist/index.esm.js +1 -2
  304. package/dist/index.js +8 -8
  305. package/dist/lib/auth/Account.esm.js +1 -2
  306. package/dist/lib/auth/NoopAuth.esm.js +1 -2
  307. package/dist/lib/auth/SolidAuth.esm.js +1 -2
  308. package/dist/lib/auth/context.esm.js +1 -2
  309. package/dist/lib/code-editor/CodeEditor.esm.js +1 -2
  310. package/dist/lib/components/decorators.esm.js +1 -2
  311. package/dist/lib/components/dialog-component/DialogComponent.esm.js +1 -2
  312. package/dist/lib/components/form-control-component/FormControlComponent.esm.js +1 -2
  313. package/dist/lib/components/ids.esm.js +1 -2
  314. package/dist/lib/components/traits/DialogTrait.esm.js +1 -2
  315. package/dist/lib/components/traits/FormControlTrait.esm.js +1 -2
  316. package/dist/lib/components/web-component/WebComponent.esm.js +1 -2
  317. package/dist/lib/components/web-component/WebComponent.styles.esm.js +1 -2
  318. package/dist/lib/debug.esm.js +1 -2
  319. package/dist/lib/dialogs/Dialog.esm.js +1 -2
  320. package/dist/lib/dialogs/context.esm.js +1 -2
  321. package/dist/lib/dialogs/events/close-dialog.esm.js +1 -2
  322. package/dist/lib/dialogs/events/show-dialog.esm.js +1 -2
  323. package/dist/lib/dialogs/helpers.esm.js +1 -2
  324. package/dist/lib/file-explorer/context.esm.js +1 -2
  325. package/dist/lib/forms/fieldParams.esm.js +1 -2
  326. package/dist/lib/forms/rdfFormsHelper.esm.js +1 -2
  327. package/dist/lib/forms/store/NoopStore.esm.js +1 -2
  328. package/dist/lib/forms/store/StoreContext.esm.js +1 -2
  329. package/dist/lib/iconBase.esm.js +1 -2
  330. package/dist/lib/log.esm.js +1 -2
  331. package/dist/lib/messageArea.esm.js +1 -2
  332. package/dist/lib/newperson.esm.js +1 -2
  333. package/dist/lib/ns.esm.js +1 -2
  334. package/dist/lib/pad.esm.js +1 -2
  335. package/dist/lib/participation.esm.js +1 -2
  336. package/dist/lib/preferences.esm.js +1 -2
  337. package/dist/lib/style.esm.js +1 -2
  338. package/dist/lib/styleConstants.esm.js +1 -2
  339. package/dist/lib/style_multiSelect.esm.js +1 -2
  340. package/dist/lib/table.esm.js +1 -2
  341. package/dist/lib/tabs.esm.js +1 -2
  342. package/dist/lib/timing.esm.js +1 -2
  343. package/dist/lib/values.esm.js +1 -2
  344. package/dist/loader.js +8 -8
  345. package/dist/login/login.esm.js +1 -2
  346. package/dist/matrix/index.esm.js +1 -2
  347. package/dist/matrix/matrix.esm.js +1 -2
  348. package/dist/media/index.esm.js +1 -2
  349. package/dist/media/media-capture.esm.js +1 -2
  350. package/dist/signup/config-default.esm.js +1 -2
  351. package/dist/signup/signup.esm.js +1 -2
  352. package/dist/solid-ui.js +243 -126
  353. package/dist/solid-ui.min.js +243 -126
  354. package/dist/solid-ui.min.js.map +1 -1
  355. package/dist/utils/headerFooterHelpers.esm.js +1 -2
  356. package/dist/utils/index.esm.js +1 -2
  357. package/dist/utils/keyHelpers/accessData.esm.js +1 -2
  358. package/dist/utils/keyHelpers/acl.esm.js +1 -2
  359. package/dist/utils/keyHelpers/otherHelpers.esm.js +1 -2
  360. package/dist/utils/label.esm.js +1 -2
  361. package/dist/widgets/buttons/iconLinks.esm.js +1 -2
  362. package/dist/widgets/buttons.esm.js +1 -2
  363. package/dist/widgets/dragAndDrop.esm.js +1 -2
  364. package/dist/widgets/error.esm.js +1 -2
  365. package/dist/widgets/forms/autocomplete/autocompleteBar.esm.js +1 -2
  366. package/dist/widgets/forms/autocomplete/autocompleteField.esm.js +1 -2
  367. package/dist/widgets/forms/autocomplete/autocompletePicker.cjs.js +1 -1
  368. package/dist/widgets/forms/autocomplete/autocompletePicker.cjs.js.map +1 -1
  369. package/dist/widgets/forms/autocomplete/autocompletePicker.esm.js +2 -3
  370. package/dist/widgets/forms/autocomplete/autocompletePicker.esm.js.map +1 -1
  371. package/dist/widgets/forms/autocomplete/language.esm.js +1 -2
  372. package/dist/widgets/forms/autocomplete/publicData.esm.js +1 -2
  373. package/dist/widgets/forms/basic.esm.js +1 -2
  374. package/dist/widgets/forms/fieldFunction.esm.js +1 -2
  375. package/dist/widgets/forms/fieldParams.esm.js +1 -2
  376. package/dist/widgets/forms/formStyle.esm.js +1 -2
  377. package/dist/widgets/forms.esm.js +1 -2
  378. package/dist/widgets/index.esm.js +1 -2
  379. package/dist/widgets/multiSelect.esm.js +1 -2
  380. package/dist/widgets/peoplePicker.esm.js +1 -2
  381. package/dist/widgets/widgetHelpers.esm.js +1 -2
  382. package/package.json +2 -2
  383. package/dist/chunks/access-control-modal-eOv2-U27.js.map +0 -1
  384. package/dist/chunks/auth-Hp8M6TQf.js.map +0 -1
  385. package/dist/chunks/chevron-down-ujxRg3MD.js.map +0 -1
  386. package/dist/chunks/combobox-Dmv-TZtI.js.map +0 -1
  387. package/dist/chunks/index.esm-N8NHgFUj.js.map +0 -1
  388. package/dist/chunks/src-DQMZZG1B.js.map +0 -1
  389. package/dist/chunks/widgets-CVLwnfkU.js.map +0 -1
  390. package/dist/chunks/x-BRRkraZN.js.map +0 -1
@@ -1,49 +1,70 @@
1
- import { D as e, _ as t, a as n, g as r, h as i, i as a, v as o } from "./index.esm-N8NHgFUj.js";
2
- import { u as s } from "./style-ChFDDB1c.js";
3
- import { T as c, p as l } from "./widgets-CVLwnfkU.js";
4
- import { a as u, c as d, g as f, i as p, o as m, p as h, r as g, u as _ } from "./components-Bdqizu8x.js";
5
- import "./button-lol95DqR.js";
6
- import "./dialog-DYgcCurb.js";
7
- import "./dialog-content-jx08y2Oa.js";
8
- import "./dialog-footer-Bhl8k1PX.js";
9
- import { r as v } from "./combobox-Dmv-TZtI.js";
10
- import "./combobox-option-B-Hksiq2.js";
11
- import "./error-state-DK1x-kNd.js";
12
- //#region ~icons/lucide/circle-x
13
- var y = class extends HTMLElement {
1
+ import { S as e, _ as t, a as n, b as r, g as i, i as a, k as o, m as s, v as c, y as l } from "./index.esm-CECfD0e9.js";
2
+ import { u } from "./style-w0Fl0xnd.js";
3
+ import { T as d, p as f } from "./widgets-BWpm5CPx.js";
4
+ import { a as p, c as m, g as h, i as g, o as _, p as v, r as y, u as b } from "./components-C8c2Ucm5.js";
5
+ import "./x-D1JUUSOS.js";
6
+ import "./button-D6qO2idW.js";
7
+ import "./dialog-CgYK767T.js";
8
+ import "./dialog-content-DjwRH1ci.js";
9
+ import "./dialog-footer-GQWi8lfB.js";
10
+ import { r as x } from "./combobox-fSTp9qoT.js";
11
+ import "./combobox-option-DOtGuKel.js";
12
+ import "./error-state-BD4_Wrkz.js";
13
+ // ~icons/lucide/circle-x
14
+ var S = class extends HTMLElement {
14
15
  constructor() {
15
16
  super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\"><circle cx=\"12\" cy=\"12\" r=\"10\"/><path d=\"m15 9l-6 6m0-6l6 6\"/></g></svg>";
16
17
  }
17
18
  };
18
- customElements.get("icon-lucide-circle-x") || customElements.define("icon-lucide-circle-x", y);
19
- //#endregion
20
- //#region src/components/access-control-modal/AccessControlSharedAccess.styles.css
21
- var b = h`:host{& h2{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-md,1rem);font-weight:600}& .access-grants-header,& .access-grants-list{align-self:stretch;padding:0 10px}& .access-grants-header{justify-content:space-between;align-items:center;gap:15px;display:flex;& .access-grants-search-input{--solid-ui-input-border-color:transparent;width:12ch;min-width:12ch;color:var(--solid-ui-color-zinc-500,#71717b);font-size:var(--solid-ui-font-size-sm,.875rem);flex:none;font-weight:500}}& .access-grants-list{align-items:flex-start;gap:20px;display:flex;& ul{box-sizing:border-box;border:1px solid var(--solid-ui-color-gray-200,#e5e7eb);border-radius:10px;flex-direction:column;flex:1 0 0;align-items:flex-start;gap:15px;height:195px;min-height:0;padding:15px;display:flex;overflow:hidden auto}& li{flex:none;align-items:center;gap:10px;width:100%;display:flex;& .access-grants-image{aspect-ratio:1;width:30px;height:30px;color:var(--solid-ui-color-white,#fff);text-align:center;font-size:var(--solid-ui-font-size-xs,.75rem);border-radius:999px;flex:0 0 30px;justify-content:center;align-items:center;font-weight:500;display:flex;overflow:hidden;& img{object-fit:cover;border-radius:999px;width:100%;height:100%;display:flex}& span{justify-content:center;align-items:center;width:100%;height:100%;line-height:1;display:flex}}& .access-grants-image--agentGroup{background:var(--solid-ui-color-blue-900,#083575)}& .access-grants-image--agent,& .access-grants-image--agentClass{background:var(--solid-ui-color-lavender-300,#e6dcff)}& .access-grants-image--origin{background:var(--solid-ui-color-green-700,#15803d)}& .access-grants-image--unknown{background:var(--solid-ui-color-gray-300,#d1d5db)}& h3{min-width:0;color:var(--solid-ui-color-gray-800,#1e2939);font-size:var(--solid-ui-font-size-xs,.75rem);flex:auto;font-weight:600}& span{text-align:right;flex:none;margin-left:auto}& .access-grants-role{font-size:var(--solid-ui-font-size-xs,.75rem);flex:none;margin-left:auto}& .access-grants-role--owner{font-size:var(--solid-ui-font-size-xs,.75rem)}& .access-grants-role--editable{max-width:100%}}}& .access-role-select--compact{--solid-ui-input-border-color:transparent;flex:0 0 110px;width:110px;min-width:110px;max-width:100%;margin-top:0}& .access-grants-list li .access-role-select--compact{flex:0 0 110px;width:110px;min-width:110px}}`, x, S, C, w, T, E, D, O, k, A, j, ee, te;
22
- function ne(e, t, n) {
23
- re(e, t), t.set(e, n);
24
- }
25
- function re(e, t) {
19
+ customElements.get("icon-lucide-circle-x") || customElements.define("icon-lucide-circle-x", S);
20
+ // ~icons/lucide/folder
21
+ var C = class extends HTMLElement {
22
+ constructor() {
23
+ super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><path fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z\"/></svg>";
24
+ }
25
+ };
26
+ customElements.get("icon-lucide-folder") || customElements.define("icon-lucide-folder", C);
27
+ // ~icons/lucide/folder-open
28
+ var w = class extends HTMLElement {
29
+ constructor() {
30
+ super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><path fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"m6 14l1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2\"/></svg>";
31
+ }
32
+ };
33
+ customElements.get("icon-lucide-folder-open") || customElements.define("icon-lucide-folder-open", w);
34
+ // ~icons/lucide/globe
35
+ var T = class extends HTMLElement {
36
+ constructor() {
37
+ super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\"><circle cx=\"12\" cy=\"12\" r=\"10\"/><path d=\"M12 2a14.5 14.5 0 0 0 0 20a14.5 14.5 0 0 0 0-20M2 12h20\"/></g></svg>";
38
+ }
39
+ };
40
+ customElements.get("icon-lucide-globe") || customElements.define("icon-lucide-globe", T);
41
+ // src/components/access-control-modal/AccessControlSharedAccess.styles.css
42
+ var E = v`:host{& h2{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-md,1rem);font-weight:600}& .access-grants-header,& .access-grants-list{align-self:stretch;padding:0 10px}& .access-grants-header{justify-content:space-between;align-items:center;gap:15px;display:flex;& .access-grants-search-input{--solid-ui-input-border-color:transparent;width:12ch;min-width:12ch;color:var(--solid-ui-color-zinc-500,#71717b);font-size:var(--solid-ui-font-size-sm,.875rem);flex:none;font-weight:500}}& .access-grants-list{align-items:flex-start;gap:20px;display:flex;& ul{box-sizing:border-box;border:1px solid var(--solid-ui-color-gray-200,#e5e7eb);border-radius:10px;flex-direction:column;flex:1 0 0;align-items:flex-start;gap:15px;height:195px;min-height:0;padding:15px;display:flex;overflow:hidden auto}& li{flex:none;align-items:center;gap:10px;width:100%;display:flex;& .access-grants-image{aspect-ratio:1;width:30px;height:30px;color:var(--solid-ui-color-white,#fff);text-align:center;font-size:var(--solid-ui-font-size-xs,.75rem);border-radius:999px;flex:0 0 30px;justify-content:center;align-items:center;font-weight:500;display:flex;overflow:hidden;& img{object-fit:cover;border-radius:999px;width:100%;height:100%;display:flex}& span{justify-content:center;align-items:center;width:100%;height:100%;line-height:1;display:flex}}& .access-grants-image--agentGroup{background:var(--solid-ui-color-blue-900,#083575)}& .access-grants-image--agent,& .access-grants-image--agentClass{background:var(--solid-ui-color-lavender-300,#e6dcff)}& .access-grants-image--origin{background:var(--solid-ui-color-green-700,#15803d)}& .access-grants-image--unknown{background:var(--solid-ui-color-gray-300,#d1d5db)}& h3{min-width:0;color:var(--solid-ui-color-gray-800,#1e2939);font-size:var(--solid-ui-font-size-xs,.75rem);flex:auto;font-weight:600}& span{text-align:right;flex:none;margin-left:auto}& .access-grants-role{font-size:var(--solid-ui-font-size-xs,.75rem);flex:none;margin-left:auto}& .access-grants-role--owner{font-size:var(--solid-ui-font-size-xs,.75rem)}& .access-grants-role--editable{max-width:100%}}}& .access-role-select--compact{--solid-ui-input-border-color:transparent;flex:0 0 110px;width:110px;min-width:110px;max-width:100%;margin-top:0}& .access-grants-list li .access-role-select--compact{flex:0 0 110px;width:110px;min-width:110px}}`, D, O, k, A, j, ee, te, ne, re, ie, ae, oe, se, ce, le, ue;
43
+ function de(e, t, n) {
44
+ fe(e, t), t.set(e, n);
45
+ }
46
+ function fe(e, t) {
26
47
  if (t.has(e)) throw TypeError("Cannot initialize the same private elements twice on an object");
27
48
  }
28
- function ie(e, t, n) {
29
- return e.set(oe(e, t), n), n;
49
+ function pe(e, t, n) {
50
+ return e.set(he(e, t), n), n;
30
51
  }
31
- function ae(e, t) {
32
- return e.get(oe(e, t));
52
+ function me(e, t) {
53
+ return e.get(he(e, t));
33
54
  }
34
- function oe(e, t, n) {
55
+ function he(e, t, n) {
35
56
  if (typeof e == "function" ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
36
57
  throw TypeError("Private element is not present on this object");
37
58
  }
38
- function se(e, t, n) {
39
- return (t = le(t)) in e ? Object.defineProperty(e, t, {
59
+ function ge(e, t, n) {
60
+ return (t = ve(t)) in e ? Object.defineProperty(e, t, {
40
61
  value: n,
41
62
  enumerable: !0,
42
63
  configurable: !0,
43
64
  writable: !0
44
65
  }) : e[t] = n, e;
45
66
  }
46
- function ce(e, t, n, r, i, a) {
67
+ function _e(e, t, n, r, i, a) {
47
68
  function o(e, t, n) {
48
69
  return function(r, i) {
49
70
  return n && n(r), e[t].call(r, i);
@@ -66,13 +87,13 @@ function ce(e, t, n, r, i, a) {
66
87
  n || Array.isArray(_) || (_ = [_]);
67
88
  var b = {}, x = [], S = i === 3 ? "get" : i === 4 || p ? "set" : "value";
68
89
  d ? (f || p ? b = {
69
- get: de(function() {
90
+ get: be(function() {
70
91
  return v(this);
71
92
  }, r, "get"),
72
93
  set: function(e) {
73
94
  t[4](this, e);
74
95
  }
75
- } : b[S] = v, f || de(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
96
+ } : b[S] = v, f || be(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
76
97
  }
77
98
  for (var C = e, w = _.length - 1; w >= 0; w -= n ? 2 : 1) {
78
99
  var T = _[w], E = n ? _[w - 1] : void 0, D = {}, O = {
@@ -132,7 +153,7 @@ function ce(e, t, n, r, i, a) {
132
153
  if (arguments.length >= 6) var d = a[Symbol.metadata || Symbol.for("Symbol.metadata")];
133
154
  var f = Object.create(d ?? null), p = function(e, t, n, r) {
134
155
  var i, a, o = [], c = function(t) {
135
- return fe(t) === e;
156
+ return xe(t) === e;
136
157
  }, u = /* @__PURE__ */ new Map();
137
158
  function d(e) {
138
159
  e && o.push(s.bind(null, e));
@@ -146,7 +167,7 @@ function ce(e, t, n, r, i, a) {
146
167
  if (!0 === x || x === 3 && m !== 4 || x === 4 && m !== 3) throw Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: " + h);
147
168
  u.set(b, !(m > 2) || m);
148
169
  }
149
- l(v ? e : e.prototype, p, _, g ? "#" + h : le(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
170
+ l(v ? e : e.prototype, p, _, g ? "#" + h : ve(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
150
171
  }
151
172
  }
152
173
  return d(i), d(a), o;
@@ -159,11 +180,11 @@ function ce(e, t, n, r, i, a) {
159
180
  }
160
181
  };
161
182
  }
162
- function le(e) {
163
- var t = ue(e, "string");
183
+ function ve(e) {
184
+ var t = ye(e, "string");
164
185
  return typeof t == "symbol" ? t : t + "";
165
186
  }
166
- function ue(e, t) {
187
+ function ye(e, t) {
167
188
  if (typeof e != "object" || !e) return e;
168
189
  var n;
169
190
  if (typeof Symbol < "u" && (n = e[Symbol.toPrimitive]) !== void 0) {
@@ -173,7 +194,7 @@ function ue(e, t) {
173
194
  }
174
195
  return (t === "string" ? String : Number)(e);
175
196
  }
176
- function de(e, t, n) {
197
+ function be(e, t, n) {
177
198
  typeof t == "symbol" && (t = (t = t.description) ? "[" + t + "]" : "");
178
199
  try {
179
200
  Object.defineProperty(e, "name", {
@@ -183,30 +204,36 @@ function de(e, t, n) {
183
204
  } catch {}
184
205
  return e;
185
206
  }
186
- function fe(e) {
207
+ function xe(e) {
187
208
  if (Object(e) !== e) throw TypeError("right-hand side of 'in' should be an object, got " + (e === null ? "null" : typeof e));
188
209
  return e;
189
210
  }
190
- function pe(e) {
211
+ function Se(e) {
191
212
  return e;
192
213
  }
193
- D = [f("solid-ui-access-control-shared-access")];
194
- var me;
195
- new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te = (O = p({ attribute: !1 }), A = g(), "accessGrantViewModels"), S = class extends m {
214
+ ne = [h("solid-ui-access-control-shared-access")];
215
+ var Ce;
216
+ new (le = (k = /*#__PURE__*/ new WeakMap(), A = /*#__PURE__*/ new WeakMap(), j = /*#__PURE__*/ new WeakMap(), ue = (re = g({ attribute: !1 }), ae = g({ type: Boolean }), se = y(), "accessGrantViewModels"), O = class extends _ {
196
217
  constructor(...e) {
197
- super(...e), ne(this, C, (T(this), k(this, []))), ne(this, w, j(this, ""));
218
+ super(...e), de(this, k, (ee(this), ie(this, []))), de(this, A, oe(this, !1)), de(this, j, ce(this, ""));
198
219
  }
199
- get [te]() {
200
- return ae(C, this);
220
+ get [ue]() {
221
+ return me(k, this);
201
222
  }
202
223
  set accessGrantViewModels(e) {
203
- ie(C, this, e);
224
+ pe(k, this, e);
225
+ }
226
+ get disabled() {
227
+ return me(A, this);
228
+ }
229
+ set disabled(e) {
230
+ pe(A, this, e);
204
231
  }
205
232
  get searchValue() {
206
- return ae(w, this);
233
+ return me(j, this);
207
234
  }
208
235
  set searchValue(e) {
209
- ie(w, this, e);
236
+ pe(j, this, e);
210
237
  }
211
238
  onSearchInput(e) {
212
239
  let t = e.currentTarget;
@@ -217,14 +244,14 @@ new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te
217
244
  typeof t.label == "string" && (this.searchValue = t.label);
218
245
  }
219
246
  onAccessGrantRoleChange(e, t) {
220
- let n = t.detail.option.value;
221
- if (typeof n != "string" || !r.includes(n)) return;
222
- let i = {
247
+ let n = t.detail.option.value, r = typeof n == "string" ? i.find((e) => e === n) : void 0;
248
+ if (!r) return;
249
+ let a = {
223
250
  id: e,
224
- role: n
251
+ role: r
225
252
  };
226
253
  this.dispatchEvent(new CustomEvent("access-grant-role-changed", {
227
- detail: i,
254
+ detail: a,
228
255
  bubbles: !0,
229
256
  composed: !0
230
257
  }));
@@ -234,7 +261,7 @@ new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te
234
261
  return this.accessGrantViewModels.filter(({ subjectLabel: t, subjects: n }) => n.length ? !e || t.toLowerCase().includes(e) : !1);
235
262
  }
236
263
  renderAccessGrant(e) {
237
- return _`
264
+ return b`
238
265
  <li>
239
266
  ${this.renderAuthorizationBadge(e.authorization, e.subjectLabel)}
240
267
  <h3>${e.subjectLabel}</h3>
@@ -244,38 +271,39 @@ new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te
244
271
  }
245
272
  renderAuthorizationBadge(e, t) {
246
273
  let n = this.getAuthorizationBadge(e, t);
247
- return _`
274
+ return b`
248
275
  <div class="access-grants-image access-grants-image--${n.kind}">
249
- ${n.image ? _`<img src=${n.image} alt="" aria-hidden="true" />` : _`<span aria-hidden="true">${n.text}</span>`}
276
+ ${n.image ? b`<img src=${n.image} alt="" aria-hidden="true" />` : n.kind === "origin" ? b`<icon-lucide-globe aria-hidden="true"></icon-lucide-globe>` : b`<span aria-hidden="true">${n.text}</span>`}
250
277
  </div>
251
278
  `;
252
279
  }
253
- getAuthorizationBadge(t, n) {
254
- let r = t.agent[0];
255
- if (r) {
256
- let t = l(e(r));
280
+ getAuthorizationBadge(e, t) {
281
+ let n = e.agent[0];
282
+ if (n) {
283
+ let e = f(o(n));
257
284
  return {
258
285
  kind: "agent",
259
- image: t,
260
- text: t ? "" : this.getInitials(n, 2)
286
+ image: e,
287
+ text: e ? "" : this.getInitials(t, 2)
261
288
  };
262
289
  }
263
- if (t.agentGroup[0]) return {
290
+ if (e.agentGroup[0]) return {
264
291
  kind: "agentGroup",
265
- text: this.getInitials(n, 1)
292
+ text: this.getInitials(t, 1)
266
293
  };
267
- let i = t.agentClass[0];
268
- if (i) {
269
- let t = l(e(i));
294
+ let r = e.agentClass[0];
295
+ if (r) {
296
+ let e = f(o(r));
270
297
  return {
271
298
  kind: "agentClass",
272
- image: t,
273
- text: t ? "" : this.getInitials(n, 2)
299
+ image: e,
300
+ text: e ? "" : this.getInitials(t, 2)
274
301
  };
275
302
  }
276
- return t.origin[0] ? {
303
+ return e.origin[0] ? {
277
304
  kind: "origin",
278
- text: "O"
305
+ text: "O",
306
+ image: ""
279
307
  } : {
280
308
  kind: "unknown",
281
309
  text: "?"
@@ -285,9 +313,10 @@ new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te
285
313
  return (e.split(/\s+/).filter(Boolean).slice(0, t).map((e) => e[0]).join("") || e.slice(0, t)).toUpperCase();
286
314
  }
287
315
  renderAuthorizationRole(e, t) {
288
- return _`
316
+ return b`
289
317
  <solid-ui-combobox
290
318
  class="access-role-select access-role-select--compact access-grants-role access-grants-role--editable ${e === "Owner" ? "access-grants-role--owner" : ""}"
319
+ .disabled=${this.disabled}
291
320
  .value=${e}
292
321
  @change=${(e) => this.onAccessGrantRoleChange(t, e)}
293
322
  >
@@ -296,16 +325,16 @@ new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te
296
325
  `;
297
326
  }
298
327
  renderGrantRoleOptions() {
299
- return r.map((e) => _`
328
+ return i.map((e) => b`
300
329
  <solid-ui-combobox-option value=${e}>${e === "No Access" ? "Remove" : e}</solid-ui-combobox-option>
301
330
  `);
302
331
  }
303
332
  render() {
304
333
  let e = this.getFilteredAccessGrants();
305
- return _`
334
+ return b`
306
335
  <section aria-labelledby="access-grants-heading">
307
336
  <div class="access-grants-header">
308
- <h2 id="access-grants-heading">Share with</h2>
337
+ <h2 id="access-grants-heading">Shared with</h2>
309
338
  <solid-ui-combobox
310
339
  class="access-grants-search-input"
311
340
  label="Search access grants"
@@ -315,7 +344,7 @@ new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te
315
344
  @input=${this.onSearchInput}
316
345
  @change=${this.onSearchSelect}
317
346
  >
318
- ${this.accessGrantViewModels.filter(({ subjects: e }) => e.length > 0).map(({ subjectLabel: e }) => _`
347
+ ${this.accessGrantViewModels.filter(({ subjects: e }) => e.length > 0).map(({ subjectLabel: e }) => b`
319
348
  <solid-ui-combobox-option .value=${e}>
320
349
  ${e}
321
350
  </solid-ui-combobox-option>
@@ -324,69 +353,67 @@ new (ee = (C = /*#__PURE__*/ new WeakMap(), w = /*#__PURE__*/ new WeakMap(), te
324
353
  </div>
325
354
  <div class="access-grants-list">
326
355
  <ul>
327
- ${e.length > 0 ? e.map((e) => this.renderAccessGrant(e)) : _`<li>No access grants</li>`}
356
+ ${e.length > 0 ? e.map((e) => this.renderAccessGrant(e)) : b`<li>No access grants</li>`}
328
357
  </ul>
329
358
  </div>
330
359
  </section>
331
360
  `;
332
361
  }
333
- }, {e: [k, j, T], c: [me, E]} = ce(S, [[
334
- O,
335
- 1,
336
- "accessGrantViewModels"
337
- ], [
338
- A,
339
- 1,
340
- "searchValue"
341
- ]], D, 0, void 0, m), S), x = class extends pe {
362
+ }, {e: [ie, oe, ce, ee], c: [Ce, te]} = _e(O, [
363
+ [
364
+ re,
365
+ 1,
366
+ "accessGrantViewModels"
367
+ ],
368
+ [
369
+ ae,
370
+ 1,
371
+ "disabled"
372
+ ],
373
+ [
374
+ se,
375
+ 1,
376
+ "searchValue"
377
+ ]
378
+ ], ne, 0, void 0, _), O), D = class extends Se {
342
379
  constructor() {
343
- super(me), se(this, "styles", b), E();
380
+ super(Ce), ge(this, "styles", E), te();
344
381
  }
345
- }, se(x, ee, void 0), x)();
346
- //#endregion
347
- //#region ~icons/lucide/link
348
- var he = class extends HTMLElement {
382
+ }, ge(D, le, void 0), D)();
383
+ // ~icons/lucide/link
384
+ var we = class extends HTMLElement {
349
385
  constructor() {
350
386
  super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\"><path d=\"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71\"/><path d=\"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71\"/></g></svg>";
351
387
  }
352
388
  };
353
- customElements.get("icon-lucide-link") || customElements.define("icon-lucide-link", he);
354
- //#endregion
355
- //#region ~icons/lucide/globe
356
- var ge = class extends HTMLElement {
357
- constructor() {
358
- super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\"><circle cx=\"12\" cy=\"12\" r=\"10\"/><path d=\"M12 2a14.5 14.5 0 0 0 0 20a14.5 14.5 0 0 0 0-20M2 12h20\"/></g></svg>";
359
- }
360
- };
361
- customElements.get("icon-lucide-globe") || customElements.define("icon-lucide-globe", ge);
362
- //#endregion
363
- //#region src/components/access-control-modal/AccessControlGeneralAccess.styles.css
364
- var _e = h`:host{& h2{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-md,1rem);font-weight:600}& .access-grants-general{flex-direction:column;align-self:stretch;align-items:flex-start;gap:10px;padding:0 10px;display:flex;& solid-ui-combobox,& solid-ui-input{--solid-ui-input-border-color:var(--solid-ui-color-slate-200,#e2e8f0)}& .access-grants-general-header{flex-direction:row;justify-content:space-between;align-self:stretch;align-items:center;gap:15px;display:flex;& .access-grants-copy-link-button-label{font-size:var(--solid-ui-font-size-xs,.75rem);font-weight:500}& .access-grants-copy-link-button icon-lucide-link{aspect-ratio:1;width:12px;height:12px}}& .access-grants-general-share{align-self:stretch;align-items:center;gap:10px;display:flex;& .access-grants-general-share-content{flex-direction:row;flex:1 0 0;align-items:flex-start;gap:10px;display:flex;& .access-grants-general-share-icon{aspect-ratio:1;background:var(--solid-ui-color-violet-50,#f5f3ff);border-radius:50px;justify-content:center;align-items:center;width:30px;height:30px;padding:5px;display:flex}& .access-grants-general-share-icon-inner{aspect-ratio:1;flex-shrink:0;justify-content:center;align-items:center;width:20px;height:20px;padding:1.25px;display:flex;& icon-lucide-globe{aspect-ratio:1;flex-shrink:0;width:17.5px;height:17.5px}}& .access-grants-general-share-text{flex:auto;min-width:0;& .access-grants-general-share-text-title{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-sm,.875rem);font-weight:600}& .access-grants-general-share-text-description{color:var(--solid-ui-color-gray-700,#364153);font-size:var(--solid-ui-font-size-sm,.875rem)}}}}}& .access-role-select--general{width:120px;min-width:120px;font-size:var(--solid-ui-font-size-xs,.75rem);flex:0 0 120px;font-weight:500}& .access-role-select--compact{--solid-ui-input-border-color:transparent;max-width:100%;margin-top:0;display:block}}`, ve, ye, be, M, N, xe, Se, Ce, we, Te, Ee, De, Oe, ke, Ae, je;
365
- function Me(e, t, n) {
366
- Ne(e, t), t.set(e, n);
367
- }
368
- function Ne(e, t) {
389
+ customElements.get("icon-lucide-link") || customElements.define("icon-lucide-link", we);
390
+ // src/components/access-control-modal/AccessControlGeneralAccess.styles.css
391
+ var Te = v`:host{& h2{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-md,1rem);font-weight:600}& .access-grants-general{flex-direction:column;align-self:stretch;align-items:flex-start;gap:10px;padding:0 10px;display:flex;& solid-ui-combobox,& solid-ui-input{--solid-ui-input-border-color:var(--solid-ui-color-slate-200,#e2e8f0)}& .access-grants-general-header{flex-direction:row;justify-content:space-between;align-self:stretch;align-items:center;gap:15px;display:flex;& .access-grants-copy-link-button-label{font-size:var(--solid-ui-font-size-xs,.75rem);font-weight:500}& .access-grants-copy-link-button icon-lucide-link{aspect-ratio:1;width:12px;height:12px}}& .access-grants-general-share{align-self:stretch;align-items:center;gap:10px;display:flex;& .access-grants-general-share-content{flex-direction:row;flex:1 0 0;align-items:flex-start;gap:10px;display:flex;& .access-grants-general-share-icon{aspect-ratio:1;background:var(--solid-ui-color-violet-50,#f5f3ff);border-radius:50px;justify-content:center;align-items:center;width:30px;height:30px;padding:5px;display:flex}& .access-grants-general-share-icon-inner{aspect-ratio:1;flex-shrink:0;justify-content:center;align-items:center;width:20px;height:20px;padding:1.25px;display:flex;& icon-lucide-globe{aspect-ratio:1;flex-shrink:0;width:17.5px;height:17.5px}}& .access-grants-general-share-text{flex:auto;min-width:0;& .access-grants-general-share-text-title{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-sm,.875rem);font-weight:600}& .access-grants-general-share-text-description{color:var(--solid-ui-color-gray-700,#364153);font-size:var(--solid-ui-font-size-sm,.875rem)}}}}}& .access-role-select--general{width:120px;min-width:120px;font-size:var(--solid-ui-font-size-xs,.75rem);flex:0 0 120px;font-weight:500}& .access-role-select--compact{--solid-ui-input-border-color:transparent;max-width:100%;margin-top:0;display:block}}`, Ee, De, Oe, ke, Ae, je, Me, Ne, Pe, Fe, Ie, Le, Re, ze, Be, Ve, He, Ue, We;
392
+ function Ge(e, t, n) {
393
+ Ke(e, t), t.set(e, n);
394
+ }
395
+ function Ke(e, t) {
369
396
  if (t.has(e)) throw TypeError("Cannot initialize the same private elements twice on an object");
370
397
  }
371
- function Pe(e, t, n) {
372
- return e.set(Ie(e, t), n), n;
398
+ function M(e, t, n) {
399
+ return e.set(qe(e, t), n), n;
373
400
  }
374
- function Fe(e, t) {
375
- return e.get(Ie(e, t));
401
+ function N(e, t) {
402
+ return e.get(qe(e, t));
376
403
  }
377
- function Ie(e, t, n) {
404
+ function qe(e, t, n) {
378
405
  if (typeof e == "function" ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
379
406
  throw TypeError("Private element is not present on this object");
380
407
  }
381
- function Le(e, t, n) {
382
- return (t = ze(t)) in e ? Object.defineProperty(e, t, {
408
+ function Je(e, t, n) {
409
+ return (t = Xe(t)) in e ? Object.defineProperty(e, t, {
383
410
  value: n,
384
411
  enumerable: !0,
385
412
  configurable: !0,
386
413
  writable: !0
387
414
  }) : e[t] = n, e;
388
415
  }
389
- function Re(e, t, n, r, i, a) {
416
+ function Ye(e, t, n, r, i, a) {
390
417
  function o(e, t, n) {
391
418
  return function(r, i) {
392
419
  return n && n(r), e[t].call(r, i);
@@ -409,13 +436,13 @@ function Re(e, t, n, r, i, a) {
409
436
  n || Array.isArray(_) || (_ = [_]);
410
437
  var b = {}, x = [], S = i === 3 ? "get" : i === 4 || p ? "set" : "value";
411
438
  d ? (f || p ? b = {
412
- get: Ve(function() {
439
+ get: Qe(function() {
413
440
  return v(this);
414
441
  }, r, "get"),
415
442
  set: function(e) {
416
443
  t[4](this, e);
417
444
  }
418
- } : b[S] = v, f || Ve(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
445
+ } : b[S] = v, f || Qe(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
419
446
  }
420
447
  for (var C = e, w = _.length - 1; w >= 0; w -= n ? 2 : 1) {
421
448
  var T = _[w], E = n ? _[w - 1] : void 0, D = {}, O = {
@@ -475,7 +502,7 @@ function Re(e, t, n, r, i, a) {
475
502
  if (arguments.length >= 6) var d = a[Symbol.metadata || Symbol.for("Symbol.metadata")];
476
503
  var f = Object.create(d ?? null), p = function(e, t, n, r) {
477
504
  var i, a, o = [], c = function(t) {
478
- return He(t) === e;
505
+ return $e(t) === e;
479
506
  }, u = /* @__PURE__ */ new Map();
480
507
  function d(e) {
481
508
  e && o.push(s.bind(null, e));
@@ -489,7 +516,7 @@ function Re(e, t, n, r, i, a) {
489
516
  if (!0 === x || x === 3 && m !== 4 || x === 4 && m !== 3) throw Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: " + h);
490
517
  u.set(b, !(m > 2) || m);
491
518
  }
492
- l(v ? e : e.prototype, p, _, g ? "#" + h : ze(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
519
+ l(v ? e : e.prototype, p, _, g ? "#" + h : Xe(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
493
520
  }
494
521
  }
495
522
  return d(i), d(a), o;
@@ -502,11 +529,11 @@ function Re(e, t, n, r, i, a) {
502
529
  }
503
530
  };
504
531
  }
505
- function ze(e) {
506
- var t = Be(e, "string");
532
+ function Xe(e) {
533
+ var t = Ze(e, "string");
507
534
  return typeof t == "symbol" ? t : t + "";
508
535
  }
509
- function Be(e, t) {
536
+ function Ze(e, t) {
510
537
  if (typeof e != "object" || !e) return e;
511
538
  var n;
512
539
  if (typeof Symbol < "u" && (n = e[Symbol.toPrimitive]) !== void 0) {
@@ -516,7 +543,7 @@ function Be(e, t) {
516
543
  }
517
544
  return (t === "string" ? String : Number)(e);
518
545
  }
519
- function Ve(e, t, n) {
546
+ function Qe(e, t, n) {
520
547
  typeof t == "symbol" && (t = (t = t.description) ? "[" + t + "]" : "");
521
548
  try {
522
549
  Object.defineProperty(e, "name", {
@@ -526,42 +553,48 @@ function Ve(e, t, n) {
526
553
  } catch {}
527
554
  return e;
528
555
  }
529
- function He(e) {
556
+ function $e(e) {
530
557
  if (Object(e) !== e) throw TypeError("right-hand side of 'in' should be an object, got " + (e === null ? "null" : typeof e));
531
558
  return e;
532
559
  }
533
- function Ue(e) {
560
+ function et(e) {
534
561
  return e;
535
562
  }
536
- Ce = [f("solid-ui-access-control-general-access")];
537
- var We;
538
- new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N = /*#__PURE__*/ new WeakMap(), je = (we = p({ attribute: !1 }), Ee = p({ attribute: !1 }), Oe = p({ attribute: !1 }), "subjectUri"), ye = class extends m {
563
+ Pe = [h("solid-ui-access-control-general-access")];
564
+ var tt;
565
+ new (Ue = (Oe = /*#__PURE__*/ new WeakMap(), ke = /*#__PURE__*/ new WeakMap(), Ae = /*#__PURE__*/ new WeakMap(), je = /*#__PURE__*/ new WeakMap(), We = (Fe = g({ attribute: !1 }), Le = g({ attribute: !1 }), ze = g({ attribute: !1 }), Ve = g({ type: Boolean }), "subjectUri"), De = class extends _ {
539
566
  constructor(...e) {
540
- super(...e), Me(this, be, (xe(this), Te(this, void 0))), Me(this, M, De(this, "No Access")), Me(this, N, ke(this, "No Access"));
567
+ super(...e), Ge(this, Oe, (Me(this), Ie(this, void 0))), Ge(this, ke, Re(this, "No Access")), Ge(this, Ae, Be(this, "No Access")), Ge(this, je, He(this, !1));
541
568
  }
542
- get [je]() {
543
- return Fe(be, this);
569
+ get [We]() {
570
+ return N(Oe, this);
544
571
  }
545
572
  set subjectUri(e) {
546
- Pe(be, this, e);
573
+ M(Oe, this, e);
547
574
  }
548
575
  get authenticatedAccessRoleValue() {
549
- return Fe(M, this);
576
+ return N(ke, this);
550
577
  }
551
578
  set authenticatedAccessRoleValue(e) {
552
- Pe(M, this, e);
579
+ M(ke, this, e);
553
580
  }
554
581
  get publicAccessRoleValue() {
555
- return Fe(N, this);
582
+ return N(Ae, this);
556
583
  }
557
584
  set publicAccessRoleValue(e) {
558
- Pe(N, this, e);
585
+ M(Ae, this, e);
586
+ }
587
+ get disabled() {
588
+ return N(je, this);
589
+ }
590
+ set disabled(e) {
591
+ M(je, this, e);
559
592
  }
560
593
  onAuthenticatedRoleChange(e) {
561
- this.dispatchRoleChange("authenticated-role-changed", e, r);
594
+ this.dispatchRoleChange("authenticated-role-changed", e, i);
562
595
  }
563
596
  onPublicRoleChange(e) {
564
- this.dispatchRoleChange("public-role-changed", e, i);
597
+ this.dispatchRoleChange("public-role-changed", e, c);
565
598
  }
566
599
  dispatchRoleChange(e, t, n) {
567
600
  let r = t.detail.option.value;
@@ -577,23 +610,24 @@ new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N
577
610
  if (e.preventDefault(), this.subjectUri) try {
578
611
  await navigator.clipboard.writeText(this.subjectUri);
579
612
  } catch (e) {
580
- c("Failed to copy resource link", e);
613
+ d("Failed to copy resource link", e);
581
614
  }
582
615
  }
583
616
  renderAuthenticatedRoleOptions() {
584
- return r.map((e) => _`
617
+ return i.map((e) => b`
585
618
  <solid-ui-combobox-option value=${e}>${e}</solid-ui-combobox-option>
586
619
  `);
587
620
  }
588
621
  renderPublicRoleOptions() {
589
- return i.map((e) => _`
622
+ return c.map((e) => b`
590
623
  <solid-ui-combobox-option value=${e}>${e}</solid-ui-combobox-option>
591
624
  `);
592
625
  }
593
626
  renderAuthenticatedModeSelector() {
594
- return _`
627
+ return b`
595
628
  <solid-ui-combobox
596
629
  class="access-role-select access-role-select--compact access-role-select--general access-grants-role access-grants-role--editable access-role-select--authenticated"
630
+ .disabled=${this.disabled}
597
631
  .value=${this.authenticatedAccessRoleValue}
598
632
  @change=${this.onAuthenticatedRoleChange}
599
633
  >
@@ -602,9 +636,10 @@ new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N
602
636
  `;
603
637
  }
604
638
  renderPublicModeSelector() {
605
- return _`
639
+ return b`
606
640
  <solid-ui-combobox
607
641
  class="access-role-select access-role-select--compact access-role-select--general access-grants-role access-grants-role--editable access-role-select--public"
642
+ .disabled=${this.disabled}
608
643
  .value=${this.publicAccessRoleValue}
609
644
  @change=${this.onPublicRoleChange}
610
645
  >
@@ -613,7 +648,7 @@ new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N
613
648
  `;
614
649
  }
615
650
  renderGeneralAccessIcon() {
616
- return _`
651
+ return b`
617
652
  <div class="access-grants-general-share-icon">
618
653
  <div class="access-grants-general-share-icon-inner">
619
654
  <icon-lucide-globe class="access-grants-general-share-icon-image"></icon-lucide-globe>
@@ -622,7 +657,7 @@ new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N
622
657
  `;
623
658
  }
624
659
  renderGeneralShareRow(e) {
625
- return _`
660
+ return b`
626
661
  <div class="access-grants-general-share">
627
662
  <div class="access-grants-general-share-content">
628
663
  ${this.renderGeneralAccessIcon()}
@@ -636,7 +671,7 @@ new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N
636
671
  `;
637
672
  }
638
673
  render() {
639
- return _`
674
+ return b`
640
675
  <section class="access-grants-general" aria-labelledby="general-access-heading">
641
676
  <div class="access-grants-general-header">
642
677
  <h2 id="general-access-heading">General Access</h2>
@@ -650,7 +685,7 @@ new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N
650
685
  </solid-ui-button>
651
686
  </div>
652
687
  ${this.renderGeneralShareRow({
653
- title: "Share with Anyone Signed In",
688
+ title: "Only logged in users with the link",
654
689
  description: "Users must sign in to SolidOS to access this shared item using the link.",
655
690
  variant: "authenticated"
656
691
  })}
@@ -662,55 +697,59 @@ new (Ae = (be = /*#__PURE__*/ new WeakMap(), M = /*#__PURE__*/ new WeakMap(), N
662
697
  </section>
663
698
  `;
664
699
  }
665
- }, {e: [Te, De, ke, xe], c: [We, Se]} = Re(ye, [
700
+ }, {e: [Ie, Re, Be, He, Me], c: [tt, Ne]} = Ye(De, [
666
701
  [
667
- we,
702
+ Fe,
668
703
  1,
669
704
  "subjectUri"
670
705
  ],
671
706
  [
672
- Ee,
707
+ Le,
673
708
  1,
674
709
  "authenticatedAccessRoleValue"
675
710
  ],
676
711
  [
677
- Oe,
712
+ ze,
678
713
  1,
679
714
  "publicAccessRoleValue"
715
+ ],
716
+ [
717
+ Ve,
718
+ 1,
719
+ "disabled"
680
720
  ]
681
- ], Ce, 0, void 0, m), ye), ve = class extends Ue {
721
+ ], Pe, 0, void 0, _), De), Ee = class extends et {
682
722
  constructor() {
683
- super(We), Le(this, "styles", _e), Se();
723
+ super(tt), Je(this, "styles", Te), Ne();
684
724
  }
685
- }, Le(ve, Ae, void 0), ve)();
686
- //#endregion
687
- //#region src/components/access-control-modal/AccessControlErrors.styles.css
688
- var Ge = h`:host{contain:inline-size;width:100%;display:block;& solid-ui-error-state{contain:inline-size;width:100%;max-width:100%}& .access-control-save-errors{box-sizing:border-box;gap:8px;width:100%;margin:0;padding-left:0;list-style:none;display:grid;& li{min-width:0;color:var(--solid-ui-color-red-600,#be2e48);font-size:var(--solid-ui-font-size-sm,.875rem);grid-template-columns:minmax(0,18rem) minmax(0,1fr);align-items:baseline;gap:6px;line-height:1.4;display:grid}& .access-control-save-error-label{overflow-wrap:anywhere;font-weight:500}& .access-control-save-error-detail{overflow-wrap:anywhere;min-width:0}}@media (width<=600px){& .access-control-save-errors li{grid-template-columns:minmax(0,40%) minmax(0,1fr)}}}`, Ke, qe, P, F, Je, Ye, Xe, Ze, Qe, $e, et, tt, nt;
689
- function rt(e, t, n) {
690
- it(e, t), t.set(e, n);
725
+ }, Je(Ee, Ue, void 0), Ee)();
726
+ // src/components/access-control-modal/AccessControlErrors.styles.css
727
+ var nt = v`:host{contain:inline-size;width:100%;display:block;& solid-ui-error-state{contain:inline-size;width:100%;max-width:100%}& .access-control-save-errors{box-sizing:border-box;gap:8px;width:100%;margin:0;padding-left:0;list-style:none;display:grid;& li{min-width:0;color:var(--solid-ui-color-red-600,#be2e48);font-size:var(--solid-ui-font-size-sm,.875rem);grid-template-columns:minmax(0,18rem) minmax(0,1fr);align-items:baseline;gap:6px;line-height:1.4;display:grid}& .access-control-save-error-label{overflow-wrap:anywhere;font-weight:500}& .access-control-save-error-detail{overflow-wrap:anywhere;min-width:0}}@media (width<=600px){& .access-control-save-errors li{grid-template-columns:minmax(0,40%) minmax(0,1fr)}}}`, rt, it, P, F, at, ot, st, ct, lt, ut, dt, ft, pt;
728
+ function mt(e, t, n) {
729
+ ht(e, t), t.set(e, n);
691
730
  }
692
- function it(e, t) {
731
+ function ht(e, t) {
693
732
  if (t.has(e)) throw TypeError("Cannot initialize the same private elements twice on an object");
694
733
  }
695
- function at(e, t, n) {
696
- return e.set(st(e, t), n), n;
734
+ function gt(e, t, n) {
735
+ return e.set(vt(e, t), n), n;
697
736
  }
698
- function ot(e, t) {
699
- return e.get(st(e, t));
737
+ function _t(e, t) {
738
+ return e.get(vt(e, t));
700
739
  }
701
- function st(e, t, n) {
740
+ function vt(e, t, n) {
702
741
  if (typeof e == "function" ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
703
742
  throw TypeError("Private element is not present on this object");
704
743
  }
705
- function ct(e, t, n) {
706
- return (t = ut(t)) in e ? Object.defineProperty(e, t, {
744
+ function yt(e, t, n) {
745
+ return (t = xt(t)) in e ? Object.defineProperty(e, t, {
707
746
  value: n,
708
747
  enumerable: !0,
709
748
  configurable: !0,
710
749
  writable: !0
711
750
  }) : e[t] = n, e;
712
751
  }
713
- function lt(e, t, n, r, i, a) {
752
+ function bt(e, t, n, r, i, a) {
714
753
  function o(e, t, n) {
715
754
  return function(r, i) {
716
755
  return n && n(r), e[t].call(r, i);
@@ -733,13 +772,13 @@ function lt(e, t, n, r, i, a) {
733
772
  n || Array.isArray(_) || (_ = [_]);
734
773
  var b = {}, x = [], S = i === 3 ? "get" : i === 4 || p ? "set" : "value";
735
774
  d ? (f || p ? b = {
736
- get: ft(function() {
775
+ get: Ct(function() {
737
776
  return v(this);
738
777
  }, r, "get"),
739
778
  set: function(e) {
740
779
  t[4](this, e);
741
780
  }
742
- } : b[S] = v, f || ft(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
781
+ } : b[S] = v, f || Ct(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
743
782
  }
744
783
  for (var C = e, w = _.length - 1; w >= 0; w -= n ? 2 : 1) {
745
784
  var T = _[w], E = n ? _[w - 1] : void 0, D = {}, O = {
@@ -799,7 +838,7 @@ function lt(e, t, n, r, i, a) {
799
838
  if (arguments.length >= 6) var d = a[Symbol.metadata || Symbol.for("Symbol.metadata")];
800
839
  var f = Object.create(d ?? null), p = function(e, t, n, r) {
801
840
  var i, a, o = [], c = function(t) {
802
- return pt(t) === e;
841
+ return wt(t) === e;
803
842
  }, u = /* @__PURE__ */ new Map();
804
843
  function d(e) {
805
844
  e && o.push(s.bind(null, e));
@@ -813,7 +852,7 @@ function lt(e, t, n, r, i, a) {
813
852
  if (!0 === x || x === 3 && m !== 4 || x === 4 && m !== 3) throw Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: " + h);
814
853
  u.set(b, !(m > 2) || m);
815
854
  }
816
- l(v ? e : e.prototype, p, _, g ? "#" + h : ut(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
855
+ l(v ? e : e.prototype, p, _, g ? "#" + h : xt(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
817
856
  }
818
857
  }
819
858
  return d(i), d(a), o;
@@ -826,11 +865,11 @@ function lt(e, t, n, r, i, a) {
826
865
  }
827
866
  };
828
867
  }
829
- function ut(e) {
830
- var t = dt(e, "string");
868
+ function xt(e) {
869
+ var t = St(e, "string");
831
870
  return typeof t == "symbol" ? t : t + "";
832
871
  }
833
- function dt(e, t) {
872
+ function St(e, t) {
834
873
  if (typeof e != "object" || !e) return e;
835
874
  var n;
836
875
  if (typeof Symbol < "u" && (n = e[Symbol.toPrimitive]) !== void 0) {
@@ -840,7 +879,7 @@ function dt(e, t) {
840
879
  }
841
880
  return (t === "string" ? String : Number)(e);
842
881
  }
843
- function ft(e, t, n) {
882
+ function Ct(e, t, n) {
844
883
  typeof t == "symbol" && (t = (t = t.description) ? "[" + t + "]" : "");
845
884
  try {
846
885
  Object.defineProperty(e, "name", {
@@ -850,30 +889,30 @@ function ft(e, t, n) {
850
889
  } catch {}
851
890
  return e;
852
891
  }
853
- function pt(e) {
892
+ function wt(e) {
854
893
  if (Object(e) !== e) throw TypeError("right-hand side of 'in' should be an object, got " + (e === null ? "null" : typeof e));
855
894
  return e;
856
895
  }
857
- function mt(e) {
896
+ function Tt(e) {
858
897
  return e;
859
898
  }
860
- Xe = [f("solid-ui-access-control-errors")];
861
- var ht;
862
- new (tt = (P = /*#__PURE__*/ new WeakMap(), F = /*#__PURE__*/ new WeakMap(), nt = (Ze = p({ attribute: !1 }), $e = p({ attribute: !1 }), "errors"), qe = class extends m {
899
+ st = [h("solid-ui-access-control-errors")];
900
+ var Et;
901
+ new (ft = (P = /*#__PURE__*/ new WeakMap(), F = /*#__PURE__*/ new WeakMap(), pt = (ct = g({ attribute: !1 }), ut = g({ attribute: !1 }), "errors"), it = class extends _ {
863
902
  constructor(...e) {
864
- super(...e), rt(this, P, (Je(this), Qe(this, []))), rt(this, F, et(this, !0));
903
+ super(...e), mt(this, P, (at(this), lt(this, []))), mt(this, F, dt(this, !0));
865
904
  }
866
- get [nt]() {
867
- return ot(P, this);
905
+ get [pt]() {
906
+ return _t(P, this);
868
907
  }
869
908
  set errors(e) {
870
- at(P, this, e);
909
+ gt(P, this, e);
871
910
  }
872
911
  get successfulChangesRefreshed() {
873
- return ot(F, this);
912
+ return _t(F, this);
874
913
  }
875
914
  set successfulChangesRefreshed(e) {
876
- at(F, this, e);
915
+ gt(F, this, e);
877
916
  }
878
917
  onClose(e) {
879
918
  e.stopPropagation(), this.dispatchEvent(new CustomEvent("close", {
@@ -881,86 +920,53 @@ new (tt = (P = /*#__PURE__*/ new WeakMap(), F = /*#__PURE__*/ new WeakMap(), nt
881
920
  composed: !0
882
921
  }));
883
922
  }
923
+ getScopeLabel(e) {
924
+ return e === "folder+contents" ? "folder and contents" : e === "container" ? "folder" : e === "contents" ? "contents" : "resource";
925
+ }
884
926
  render() {
885
- return this.errors.length ? _`
927
+ return this.errors.length ? b`
886
928
  <solid-ui-error-state
887
929
  title="Some access changes could not be saved"
888
930
  message=${this.successfulChangesRefreshed ? "Any successful changes are shown above. The list below shows only the changes that failed. Close this dialog and reopen it if you want to try again." : "Some changes may have been saved, but we could not refresh the Shared with list. The list below shows only the changes that failed. Close this dialog and reopen it if you want to try again."}
889
931
  @close=${this.onClose}
890
932
  >
891
933
  <ul class="access-control-save-errors">
892
- ${this.errors.map((e) => _`
934
+ ${this.errors.map((e) => b`
893
935
  <li>
894
936
  <span class="access-control-save-error-label">${e.label}</span>
895
937
  <span class="access-control-save-error-detail">
896
- ${e.action === "grant" ? `Could not grant ${e.role ?? "access"}` : e.action === "revoke" ? "Could not remove access" : "Could not save access changes"}
938
+ ${e.action === "grant" ? `Could not grant ${e.role ?? "access"} for ${e.scope ? this.getScopeLabel(e.scope) : "resource"}` : e.action === "revoke" ? `Could not remove access for ${e.scope ? this.getScopeLabel(e.scope) : "resource"}` : e.action === "reset" ? "Could not reset sharing" : "Could not save access changes"}
897
939
  </span>
940
+ <span class="access-control-save-error-message">${e.message}</span>
898
941
  </li>
899
942
  `)}
900
943
  </ul>
901
944
  </solid-ui-error-state>
902
- ` : _``;
945
+ ` : b``;
903
946
  }
904
- }, {e: [Qe, et, Je], c: [ht, Ye]} = lt(qe, [[
905
- Ze,
947
+ }, {e: [lt, dt, at], c: [Et, ot]} = bt(it, [[
948
+ ct,
906
949
  1,
907
950
  "errors"
908
951
  ], [
909
- $e,
952
+ ut,
910
953
  1,
911
954
  "successfulChangesRefreshed"
912
- ]], Xe, 0, void 0, m), qe), Ke = class extends mt {
955
+ ]], st, 0, void 0, _), it), rt = class extends Tt {
913
956
  constructor() {
914
- super(ht), ct(this, "styles", Ge), Ye();
915
- }
916
- }, ct(Ke, tt, void 0), Ke)();
917
- //#endregion
918
- //#region src/components/access-control-modal/AccessControlModal.styles.css
919
- var gt = h`:host{& .access-control-footer-actions{justify-content:flex-end;align-items:center;gap:15px;width:100%;display:flex;&>solid-ui-button{min-width:132px}}@media (width<=380px){& .access-control-footer-actions{gap:8px;&>solid-ui-button{flex:1 1 0;min-width:0}}}}`;
920
- //#endregion
921
- //#region src/components/access-control-modal/helpers.ts
922
- function _t(e) {
923
- try {
924
- let t = new URL(e);
925
- return (t.protocol === "http:" || t.protocol === "https:") && !!t.hostname;
926
- } catch {
927
- return !1;
957
+ super(Et), yt(this, "styles", nt), ot();
928
958
  }
929
- }
930
- function vt(e) {
931
- if (!_t(e)) return !1;
932
- let t = new URL(e);
933
- return t.pathname === "/" && !t.search && !t.hash && !t.username && !t.password;
934
- }
935
- function yt(e) {
936
- let t = e.trim();
937
- if (t && !_t(t)) try {
938
- let e = new URL(`https://${t}`), n = e.protocol === "http:" || e.protocol === "https:", r = e.pathname === "/" && !e.search && !e.hash, i = e.hostname.includes(".") || e.hostname.includes(":");
939
- return n && r && i && !e.username && !e.password ? e.origin : void 0;
940
- } catch {
941
- return;
942
- }
943
- }
944
- function bt(e, t) {
945
- let n = /* @__PURE__ */ new Map();
946
- for (let r of e) {
947
- let e = t(r);
948
- e && !n.has(e) && n.set(e, r);
949
- }
950
- return [...n.values()];
951
- }
952
- function xt(e) {
953
- return bt(e, (e) => e.value);
954
- }
955
- //#endregion
956
- //#region src/components/access-control-modal/accessGrantDrafts.ts
957
- function St(e) {
959
+ }, yt(rt, ft, void 0), rt)();
960
+ // src/components/access-control-modal/AccessControlModal.styles.css
961
+ var Dt = v`:host{& .access-control-mixed-policy-warning{border:1px solid var(--solid-ui-color-red-300,#fca5a5);background:var(--solid-ui-color-red-50,#fef2f2);color:var(--solid-ui-color-red-800,#991b1b);font-size:var(--solid-ui-font-size-sm,.875rem);border-radius:5px;gap:4px;margin:0 0 16px;padding:12px 14px;line-height:1.45;display:grid;& strong{font-weight:600}}& .access-control-same-access-toggle{color:var(--solid-ui-color-gray-900,#101828);text-align:left;line-height:1.4;font:inherit;cursor:pointer;background:0 0;border:0;align-items:flex-start;gap:8px;margin-top:12px;padding:0;display:flex}& .access-control-switch-track{background:var(--solid-ui-color-slate-300,#cbd5e1);border-radius:999px;flex:none;width:34px;height:20px;margin-top:1px;padding:2px;transition:background .15s;display:inline-flex}& .access-control-same-access-toggle[aria-checked=true] .access-control-switch-track{background:var(--solid-ui-color-purple-600,#9333ea)}& .access-control-switch-thumb{background:#fff;border-radius:50%;width:16px;height:16px;transition:transform .15s;box-shadow:0 1px 2px #00000040}& .access-control-same-access-toggle[aria-checked=true] .access-control-switch-thumb{transform:translate(14px)}& .access-control-same-access-toggle>span:last-child{overflow-wrap:anywhere;min-width:0;max-width:100%}& .access-control-sharing-state,& .access-control-contents-prompt{box-sizing:border-box;min-width:0;max-width:100%;font-size:var(--solid-ui-font-size-sm,.875rem);margin-bottom:16px;padding:10px;& h2{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-md,1rem);margin:0 0 10px;font-weight:600}& .access-control-advanced-sharing{box-sizing:border-box;overflow-wrap:anywhere;width:100%;min-width:0;max-width:100%;margin-top:10px;padding:10px 48px 10px 15px;position:relative;& h2{color:var(--solid-ui-color-gray-900,#101828);font-size:var(--solid-ui-font-size-md,1rem);margin:0 0 4px;font-weight:600}& p{overflow-wrap:anywhere;min-width:0;max-width:100%;color:var(--solid-ui-color-gray-600,#4a5565);font-size:var(--solid-ui-font-size-xs,.75rem);margin:0;line-height:1.5}& .access-control-advanced-sharing-description-line{max-width:100%;display:block}}& .access-control-advanced-sharing-options,& .access-control-advanced-sharing-actions{flex-wrap:wrap;gap:8px;min-width:0;margin-top:10px;display:flex;& solid-ui-button{--solid-ui-font-size-md:var(--solid-ui-font-size-sm,.875rem);white-space:normal;min-width:0;max-width:100%}}& .access-control-advanced-sharing-actions{justify-content:flex-end;margin-top:0;position:absolute;top:10px;right:15px;& solid-ui-button{color:var(--solid-ui-color-gray-600,#4a5565)}}& p{overflow-wrap:anywhere;min-width:0;max-width:100%;color:var(--solid-ui-color-gray-600,#4a5565);margin:0;line-height:1.5}}& .access-control-sharing-state-panel,& .access-control-contents-prompt{box-sizing:border-box;border:1px solid var(--solid-ui-color-slate-200,#e2e8f0);background:var(--solid-ui-color-white,#fff);border-radius:5px;min-width:0;max-width:100%;padding:10px 15px}& .access-control-sharing-state-panel{gap:10px;display:grid;& p{overflow-wrap:anywhere;min-width:0;max-width:100%}& .access-control-sharing-state-custom-row{flex-wrap:wrap;align-items:center;gap:8px;display:flex;& p{flex:auto}& solid-ui-button{--solid-ui-font-size-md:var(--solid-ui-font-size-sm,.875rem);flex:none}}}& .access-control-sharing-guidance{justify-content:space-between;align-items:center;gap:12px;min-width:0;display:flex;& p{overflow-wrap:anywhere;min-width:0;max-width:100%}& solid-ui-button{--solid-ui-font-size-md:var(--solid-ui-font-size-sm,.875rem);flex:none}}& .access-control-sharing-state-actions{flex-direction:column;justify-content:flex-end;align-items:flex-end;gap:8px;min-width:0;margin-top:10px;display:flex;& solid-ui-button{--solid-ui-font-size-md:var(--solid-ui-font-size-sm,.875rem);max-width:100%}}@media (width<=420px){& .access-control-sharing-guidance{flex-direction:column;align-items:flex-start;gap:8px;& solid-ui-button{align-self:flex-end}}}& .access-control-contents-prompt{& .access-control-contents-prompt-actions{flex-wrap:wrap;gap:8px;min-width:0;margin-top:10px;display:flex}& solid-ui-button{--solid-ui-font-size-md:var(--solid-ui-font-size-sm,.875rem);flex:0 auto;max-width:100%}}& .access-control-contents-prompt h2{margin-bottom:4px}& .access-control-footer-actions{justify-content:flex-end;align-items:center;gap:15px;width:100%;display:flex;&>solid-ui-button{min-width:132px}}@media (width<=380px){& .access-control-footer-actions{gap:8px;&>solid-ui-button{flex:1 1 0;min-width:0}}}}`;
962
+ // src/components/access-control-modal/accessGrantDrafts.ts
963
+ function Ot(e) {
958
964
  return {
959
965
  ...e,
960
- agentClass: e.agentClass.filter((e) => e !== t.iri && e !== o.iri)
966
+ agentClass: e.agentClass.filter((e) => e !== l.iri && e !== r.iri)
961
967
  };
962
968
  }
963
- function Ct(e) {
969
+ function kt(e) {
964
970
  return [
965
971
  {
966
972
  type: "agent",
@@ -983,122 +989,118 @@ function Ct(e) {
983
989
  iri: t
984
990
  })));
985
991
  }
986
- function wt(e) {
987
- return Ct(e).map((e) => `${e.type}:${e.iri}`).sort().join("|");
992
+ function At(e) {
993
+ return e.id ? e.id : kt(e).map((e) => `${e.type}:${e.iri}`).sort().join("|");
988
994
  }
989
- function Tt(e) {
995
+ function jt(e) {
990
996
  let t = /* @__PURE__ */ new Map();
991
997
  return e.map((e) => {
992
- let n = wt(St(e)), r = t.get(n) ?? 0;
998
+ let n = At(Ot(e)), r = t.get(n) ?? 0;
993
999
  return t.set(n, r + 1), r === 0 ? n : `${n}#${r}`;
994
1000
  });
995
1001
  }
996
- function Et(t) {
997
- let n = [
998
- ...t.agent,
999
- ...t.agentGroup,
1000
- ...t.agentClass,
1001
- ...t.origin
1002
+ function Mt(e) {
1003
+ let t = [
1004
+ ...e.agent,
1005
+ ...e.agentGroup,
1006
+ ...e.agentClass,
1007
+ ...e.origin
1002
1008
  ];
1003
- return n.length ? n.map((t) => s(e(t))).join(", ") : "Unknown access holder";
1009
+ return t.length ? t.map((e) => u(o(e))).join(", ") : "Unknown access holder";
1004
1010
  }
1005
- function Dt(e) {
1011
+ function Nt(e) {
1006
1012
  return a.acl.roleFromModes(e.mode);
1007
1013
  }
1008
- function Ot(e) {
1009
- let t = St(e);
1014
+ function Pt(e) {
1015
+ let t = Ot(e);
1010
1016
  return {
1011
- id: wt(t),
1017
+ id: At(t),
1012
1018
  authorization: t,
1013
- role: Dt(t),
1014
- initialRole: Dt(e),
1015
- subjectLabel: Et(t),
1016
- subjects: Ct(t)
1019
+ role: Nt(t),
1020
+ initialRole: Nt(e),
1021
+ subjectLabel: Mt(t),
1022
+ subjects: kt(t)
1017
1023
  };
1018
1024
  }
1019
- function kt(e) {
1020
- let t = Tt(e);
1025
+ function Ft(e) {
1026
+ let t = jt(e);
1021
1027
  return e.map((e, n) => ({
1022
- ...Ot(e),
1028
+ ...Pt(e),
1023
1029
  id: t[n]
1024
1030
  }));
1025
1031
  }
1026
- function At(e) {
1032
+ function It(e) {
1027
1033
  return [...e].sort((t, n) => {
1028
1034
  let r = t.role === "Owner", i = n.role === "Owner";
1029
1035
  return r && !i ? -1 : !r && i ? 1 : e.indexOf(t) - e.indexOf(n);
1030
1036
  });
1031
1037
  }
1032
- function jt(e) {
1033
- return At(e).filter(({ role: e, initialRole: t, subjects: n }) => e !== t && n.length > 0).map(({ authorization: e, subjects: t, role: n }) => ({
1038
+ function Lt(e) {
1039
+ return It(e).filter(({ role: e, initialRole: t, subjects: n }) => e !== t && n.length > 0).map(({ authorization: e, subjects: t, role: n }) => ({
1034
1040
  authorization: e,
1035
1041
  subjects: t,
1036
1042
  role: n
1037
1043
  }));
1038
1044
  }
1039
- function Mt(e) {
1040
- let n = e.find((e) => e.agentClass.includes(t.iri));
1041
- return n ? Dt(n) : "No Access";
1045
+ function Rt(e) {
1046
+ let t = e.filter((e) => e.agentClass.includes(l.iri)).flatMap((e) => e.mode);
1047
+ return t.length ? a.acl.roleFromModes(t) : "No Access";
1042
1048
  }
1043
- function Nt(e) {
1044
- let t = e.find((e) => e.agentClass.includes(o.iri));
1045
- return t ? a.acl.publicRoleFromModes(t.mode) : "No Access";
1049
+ function zt(e) {
1050
+ let t = e.filter((e) => e.agentClass.includes(r.iri)).flatMap((e) => e.mode);
1051
+ return t.length ? a.acl.publicRoleFromModes(t) : "No Access";
1046
1052
  }
1047
- function Pt(n) {
1048
- return n.iri === t.iri ? "Authenticated users" : n.iri === o.iri ? "Public" : s(e(n.iri)).trim() || n.iri;
1053
+ function Bt(e) {
1054
+ return e.iri === l.iri ? "Authenticated users" : e.iri === r.iri ? "Public" : u(o(e.iri)).trim() || e.iri;
1049
1055
  }
1050
- //#endregion
1051
- //#region ~icons/lucide/book-user
1052
- var Ft = class extends HTMLElement {
1056
+ // ~icons/lucide/book-user
1057
+ var Vt = class extends HTMLElement {
1053
1058
  constructor() {
1054
1059
  super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\"><path d=\"M15 13a3 3 0 1 0-6 0\"/><path d=\"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20\"/><circle cx=\"12\" cy=\"8\" r=\"2\"/></g></svg>";
1055
1060
  }
1056
1061
  };
1057
- customElements.get("icon-lucide-book-user") || customElements.define("icon-lucide-book-user", Ft);
1058
- //#endregion
1059
- //#region ~icons/lucide/user-round
1060
- var It = class extends HTMLElement {
1062
+ customElements.get("icon-lucide-book-user") || customElements.define("icon-lucide-book-user", Vt);
1063
+ // ~icons/lucide/user-round
1064
+ var Ht = class extends HTMLElement {
1061
1065
  constructor() {
1062
1066
  super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\"><circle cx=\"12\" cy=\"8\" r=\"5\"/><path d=\"M20 21a8 8 0 0 0-16 0\"/></g></svg>";
1063
1067
  }
1064
1068
  };
1065
- customElements.get("icon-lucide-user-round") || customElements.define("icon-lucide-user-round", It);
1066
- //#endregion
1067
- //#region ~icons/lucide/users
1068
- var Lt = class extends HTMLElement {
1069
+ customElements.get("icon-lucide-user-round") || customElements.define("icon-lucide-user-round", Ht);
1070
+ // ~icons/lucide/users
1071
+ var Ut = class extends HTMLElement {
1069
1072
  constructor() {
1070
1073
  super(), this.attachShadow({ mode: "open" }).innerHTML = "<style>:host { display: inline-flex; }</style><svg viewBox=\"0 0 24 24\" width=\"100%\" height=\"100%\" ><g fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\"><path d=\"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2M16 3.128a4 4 0 0 1 0 7.744M22 21v-2a4 4 0 0 0-3-3.87\"/><circle cx=\"9\" cy=\"7\" r=\"4\"/></g></svg>";
1071
1074
  }
1072
1075
  };
1073
- customElements.get("icon-lucide-users") || customElements.define("icon-lucide-users", Lt);
1074
- //#endregion
1075
- //#region src/components/access-control-modal/AccessControlAddAccess.styles.css
1076
- var Rt = h`:host{& .access-grants-form{font-size:var(--solid-ui-font-size-sm,.875rem);--access-role-select-width:129px;flex-direction:column;align-self:stretch;align-items:flex-start;gap:10px;padding:10px;display:flex;& p{color:var(--solid-ui-color-gray-600,#4a5565);line-height:1.5}& .access-grants-form-main{align-self:stretch;align-items:flex-start;gap:10px;display:flex;& .access-grants-input{border:1px solid var(--solid-ui-color-slate-200,#e2e8f0);background:var(--solid-ui-color-white,#fff);border-radius:5px;flex-direction:column;flex:auto;align-items:flex-start;gap:12px;min-width:0;padding:10px 15px;display:flex;& solid-ui-combobox{--solid-ui-input-border-color:var(--solid-ui-color-slate-200,#e2e8f0);width:100%}& .access-principal-error{color:var(--solid-ui-color-red-700,#b42318);font-size:var(--solid-ui-font-size-xs,.75rem);margin:0;line-height:1.4}}}& .access-grants-pending{flex-wrap:wrap;align-items:center;gap:8px;min-height:42px;display:flex}& .access-grants-pending-item{border:1px solid var(--solid-ui-color-gray-300,#d1d5dc);background:var(--solid-ui-color-gray-50,#f9fafb);max-width:100%;color:var(--solid-ui-color-gray-700,#374151);border-radius:5px;align-items:center;gap:6px;padding:5px 10px;display:flex}& .access-grants-pending-item-label{text-overflow:ellipsis;white-space:nowrap;min-width:0;color:var(--solid-ui-color-gray-500,#6a7282);font-size:var(--solid-ui-font-size-xs,.75rem);line-height:1;overflow:hidden}& .access-grants-pending-item-remove{color:var(--solid-ui-color-gray-300,#d1d5dc);cursor:pointer;background:0 0;border:none;border-radius:999px;justify-content:center;align-items:center;padding:0;display:inline-flex;& icon-lucide-circle-x{width:14px;height:14px}}}& .access-grants-directory-entry{align-items:center;gap:8px;line-height:1;display:inline-flex}& .access-role-select{max-width:100%;width:var(--access-role-select-width);--solid-ui-input-border-color:var(--solid-ui-color-slate-200,#e2e8f0);flex:none;margin-top:25px;display:block}& .access-role-select--top{margin-top:0}}`, zt, Bt, Vt, Ht, I, L, R, Ut, Wt, Gt, Kt, qt, Jt, Yt, Xt, Zt, Qt, $t, en, tn, nn, rn;
1077
- function z(e, t, n) {
1078
- an(e, t), t.set(e, n);
1079
- }
1080
- function an(e, t) {
1076
+ customElements.get("icon-lucide-users") || customElements.define("icon-lucide-users", Ut);
1077
+ // src/components/access-control-modal/AccessControlAddAccess.styles.css
1078
+ var Wt = v`:host{& .access-grants-form{font-size:var(--solid-ui-font-size-sm,.875rem);--access-role-select-width:129px;flex-direction:column;align-self:stretch;align-items:flex-start;gap:10px;padding:10px;display:flex;& p{color:var(--solid-ui-color-gray-600,#4a5565);line-height:1.5}& .access-grants-form-main{align-self:stretch;align-items:center;gap:10px;display:flex;& .access-grants-input{border:1px solid var(--solid-ui-color-slate-200,#e2e8f0);background:var(--solid-ui-color-white,#fff);border-radius:5px;flex-direction:column;flex:auto;align-items:flex-start;gap:12px;min-width:0;padding:10px 15px;display:flex;& solid-ui-combobox{--solid-ui-input-border-color:var(--solid-ui-color-slate-200,#e2e8f0);width:100%}& .access-principal-error{color:var(--solid-ui-color-red-700,#b42318);font-size:var(--solid-ui-font-size-xs,.75rem);margin:0;line-height:1.4}}}& .access-grants-pending{flex-wrap:wrap;align-items:center;gap:8px;min-height:42px;display:flex}& .access-grants-pending-item{border:1px solid var(--solid-ui-color-gray-300,#d1d5dc);background:var(--solid-ui-color-gray-50,#f9fafb);max-width:100%;color:var(--solid-ui-color-gray-700,#374151);border-radius:5px;align-items:center;gap:6px;padding:5px 10px;display:flex}& .access-grants-pending-item-label{text-overflow:ellipsis;white-space:nowrap;min-width:0;color:var(--solid-ui-color-gray-500,#6a7282);font-size:var(--solid-ui-font-size-xs,.75rem);line-height:1;overflow:hidden}& .access-grants-pending-item-remove{color:var(--solid-ui-color-gray-300,#d1d5dc);cursor:pointer;background:0 0;border:none;border-radius:999px;justify-content:center;align-items:center;padding:0;display:inline-flex;& icon-lucide-circle-x{width:14px;height:14px}}}& .access-grants-directory-entry{align-items:center;gap:8px;line-height:1;display:inline-flex}& .access-role-select{max-width:100%;width:var(--access-role-select-width);--solid-ui-input-border-color:var(--solid-ui-color-slate-200,#e2e8f0);flex:none;margin-top:25px;display:block}& .access-role-select--top{margin-top:0}}`, Gt, Kt, I, L, R, z, B, V, qt, Jt, Yt, Xt, Zt, Qt, $t, en, tn, nn, rn, an, on, sn, cn, ln, un;
1079
+ function H(e, t, n) {
1080
+ dn(e, t), t.set(e, n);
1081
+ }
1082
+ function dn(e, t) {
1081
1083
  if (t.has(e)) throw TypeError("Cannot initialize the same private elements twice on an object");
1082
1084
  }
1083
- function B(e, t, n) {
1084
- return e.set(on(e, t), n), n;
1085
+ function U(e, t, n) {
1086
+ return e.set(fn(e, t), n), n;
1085
1087
  }
1086
- function V(e, t) {
1087
- return e.get(on(e, t));
1088
+ function W(e, t) {
1089
+ return e.get(fn(e, t));
1088
1090
  }
1089
- function on(e, t, n) {
1091
+ function fn(e, t, n) {
1090
1092
  if (typeof e == "function" ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
1091
1093
  throw TypeError("Private element is not present on this object");
1092
1094
  }
1093
- function sn(e, t, n) {
1094
- return (t = ln(t)) in e ? Object.defineProperty(e, t, {
1095
+ function pn(e, t, n) {
1096
+ return (t = hn(t)) in e ? Object.defineProperty(e, t, {
1095
1097
  value: n,
1096
1098
  enumerable: !0,
1097
1099
  configurable: !0,
1098
1100
  writable: !0
1099
1101
  }) : e[t] = n, e;
1100
1102
  }
1101
- function cn(e, t, n, r, i, a) {
1103
+ function mn(e, t, n, r, i, a) {
1102
1104
  function o(e, t, n) {
1103
1105
  return function(r, i) {
1104
1106
  return n && n(r), e[t].call(r, i);
@@ -1121,13 +1123,13 @@ function cn(e, t, n, r, i, a) {
1121
1123
  n || Array.isArray(_) || (_ = [_]);
1122
1124
  var b = {}, x = [], S = i === 3 ? "get" : i === 4 || p ? "set" : "value";
1123
1125
  d ? (f || p ? b = {
1124
- get: dn(function() {
1126
+ get: _n(function() {
1125
1127
  return v(this);
1126
1128
  }, r, "get"),
1127
1129
  set: function(e) {
1128
1130
  t[4](this, e);
1129
1131
  }
1130
- } : b[S] = v, f || dn(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
1132
+ } : b[S] = v, f || _n(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
1131
1133
  }
1132
1134
  for (var C = e, w = _.length - 1; w >= 0; w -= n ? 2 : 1) {
1133
1135
  var T = _[w], E = n ? _[w - 1] : void 0, D = {}, O = {
@@ -1187,7 +1189,7 @@ function cn(e, t, n, r, i, a) {
1187
1189
  if (arguments.length >= 6) var d = a[Symbol.metadata || Symbol.for("Symbol.metadata")];
1188
1190
  var f = Object.create(d ?? null), p = function(e, t, n, r) {
1189
1191
  var i, a, o = [], c = function(t) {
1190
- return fn(t) === e;
1192
+ return vn(t) === e;
1191
1193
  }, u = /* @__PURE__ */ new Map();
1192
1194
  function d(e) {
1193
1195
  e && o.push(s.bind(null, e));
@@ -1201,7 +1203,7 @@ function cn(e, t, n, r, i, a) {
1201
1203
  if (!0 === x || x === 3 && m !== 4 || x === 4 && m !== 3) throw Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: " + h);
1202
1204
  u.set(b, !(m > 2) || m);
1203
1205
  }
1204
- l(v ? e : e.prototype, p, _, g ? "#" + h : ln(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
1206
+ l(v ? e : e.prototype, p, _, g ? "#" + h : hn(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
1205
1207
  }
1206
1208
  }
1207
1209
  return d(i), d(a), o;
@@ -1214,11 +1216,11 @@ function cn(e, t, n, r, i, a) {
1214
1216
  }
1215
1217
  };
1216
1218
  }
1217
- function ln(e) {
1218
- var t = un(e, "string");
1219
+ function hn(e) {
1220
+ var t = gn(e, "string");
1219
1221
  return typeof t == "symbol" ? t : t + "";
1220
1222
  }
1221
- function un(e, t) {
1223
+ function gn(e, t) {
1222
1224
  if (typeof e != "object" || !e) return e;
1223
1225
  var n;
1224
1226
  if (typeof Symbol < "u" && (n = e[Symbol.toPrimitive]) !== void 0) {
@@ -1228,7 +1230,7 @@ function un(e, t) {
1228
1230
  }
1229
1231
  return (t === "string" ? String : Number)(e);
1230
1232
  }
1231
- function dn(e, t, n) {
1233
+ function _n(e, t, n) {
1232
1234
  typeof t == "symbol" && (t = (t = t.description) ? "[" + t + "]" : "");
1233
1235
  try {
1234
1236
  Object.defineProperty(e, "name", {
@@ -1238,59 +1240,65 @@ function dn(e, t, n) {
1238
1240
  } catch {}
1239
1241
  return e;
1240
1242
  }
1241
- function fn(e) {
1243
+ function vn(e) {
1242
1244
  if (Object(e) !== e) throw TypeError("right-hand side of 'in' should be an object, got " + (e === null ? "null" : typeof e));
1243
1245
  return e;
1244
1246
  }
1245
- function pn(e) {
1247
+ function yn(e) {
1246
1248
  return e;
1247
1249
  }
1248
- function mn(e) {
1249
- return _`
1250
+ function bn(e) {
1251
+ return b`
1250
1252
  <span class="access-grants-directory-entry">
1251
- ${hn(e)}
1253
+ ${xn(e)}
1252
1254
  <span>${e.label}</span>
1253
1255
  </span>
1254
1256
  `;
1255
1257
  }
1256
- function hn(e) {
1257
- return e.sources.includes("contacts") || e.sources.includes("groups") ? _`<icon-lucide-book-user style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-book-user>` : e.sources.includes("friends") ? _`<icon-lucide-users style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-users>` : e.sources.includes("catalog") ? _`<icon-lucide-user-round style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-user-round>` : d;
1258
+ function xn(e) {
1259
+ return e.sources.includes("contacts") || e.sources.includes("groups") ? b`<icon-lucide-book-user style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-book-user>` : e.sources.includes("friends") ? b`<icon-lucide-users style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-users>` : e.sources.includes("catalog") ? b`<icon-lucide-user-round style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-user-round>` : m;
1258
1260
  }
1259
- Gt = [f("solid-ui-access-control-add-access")];
1260
- var gn;
1261
- new (nn = (Vt = /*#__PURE__*/ new WeakMap(), Ht = /*#__PURE__*/ new WeakMap(), I = /*#__PURE__*/ new WeakMap(), L = /*#__PURE__*/ new WeakMap(), R = /*#__PURE__*/ new WeakMap(), rn = (Kt = p({ attribute: !1 }), Jt = p({ attribute: !1 }), Xt = p({ attribute: !1 }), Qt = p({ attribute: !1 }), en = p({ attribute: !1 }), "principalInputValue"), Bt = class extends m {
1261
+ Yt = [h("solid-ui-access-control-add-access")];
1262
+ var Sn;
1263
+ new (ln = (I = /*#__PURE__*/ new WeakMap(), L = /*#__PURE__*/ new WeakMap(), R = /*#__PURE__*/ new WeakMap(), z = /*#__PURE__*/ new WeakMap(), B = /*#__PURE__*/ new WeakMap(), V = /*#__PURE__*/ new WeakMap(), un = (Xt = g({ attribute: !1 }), Qt = g({ attribute: !1 }), en = g({ attribute: !1 }), nn = g({ attribute: !1 }), an = g({ type: Boolean }), sn = g({ attribute: !1 }), "principalInputValue"), Kt = class extends _ {
1262
1264
  constructor(...e) {
1263
- super(...e), z(this, Vt, (Ut(this), qt(this, ""))), z(this, Ht, Yt(this, "Viewer")), z(this, I, Zt(this, [])), z(this, L, $t(this, "")), z(this, R, tn(this, null));
1265
+ super(...e), H(this, I, (qt(this), Zt(this, ""))), H(this, L, $t(this, "Viewer")), H(this, R, tn(this, [])), H(this, z, rn(this, "")), H(this, B, on(this, !1)), H(this, V, cn(this, null));
1264
1266
  }
1265
- get [rn]() {
1266
- return V(Vt, this);
1267
+ get [un]() {
1268
+ return W(I, this);
1267
1269
  }
1268
1270
  set principalInputValue(e) {
1269
- B(Vt, this, e);
1271
+ U(I, this, e);
1270
1272
  }
1271
1273
  get addAccessRoleValue() {
1272
- return V(Ht, this);
1274
+ return W(L, this);
1273
1275
  }
1274
1276
  set addAccessRoleValue(e) {
1275
- B(Ht, this, e);
1277
+ U(L, this, e);
1276
1278
  }
1277
1279
  get pendingAccessGrants() {
1278
- return V(I, this);
1280
+ return W(R, this);
1279
1281
  }
1280
1282
  set pendingAccessGrants(e) {
1281
- B(I, this, e);
1283
+ U(R, this, e);
1282
1284
  }
1283
1285
  get inputError() {
1284
- return V(L, this);
1286
+ return W(z, this);
1285
1287
  }
1286
1288
  set inputError(e) {
1287
- B(L, this, e);
1289
+ U(z, this, e);
1290
+ }
1291
+ get disabled() {
1292
+ return W(B, this);
1293
+ }
1294
+ set disabled(e) {
1295
+ U(B, this, e);
1288
1296
  }
1289
1297
  get asyncOptionsProvider() {
1290
- return V(R, this);
1298
+ return W(V, this);
1291
1299
  }
1292
1300
  set asyncOptionsProvider(e) {
1293
- B(R, this, e);
1301
+ U(V, this, e);
1294
1302
  }
1295
1303
  onPrincipalInput(e) {
1296
1304
  let t = this.getEventValue(e);
@@ -1305,16 +1313,17 @@ new (nn = (Vt = /*#__PURE__*/ new WeakMap(), Ht = /*#__PURE__*/ new WeakMap(), I
1305
1313
  typeof t.value == "string" && this.dispatchEvent(new CustomEvent("target-selected", {
1306
1314
  detail: {
1307
1315
  value: t.value,
1308
- label: t.label
1316
+ label: t.label,
1317
+ targetKind: t.targetKind
1309
1318
  },
1310
1319
  bubbles: !0,
1311
1320
  composed: !0
1312
1321
  }));
1313
1322
  }
1314
1323
  onRoleChange(e) {
1315
- let t = e.detail.option.value;
1316
- typeof t == "string" && r.includes(t) && this.dispatchEvent(new CustomEvent("role-changed", {
1317
- detail: { role: t },
1324
+ let t = e.detail.option.value, n = typeof t == "string" ? i.find((e) => e === t) : void 0;
1325
+ n && this.dispatchEvent(new CustomEvent("role-changed", {
1326
+ detail: { role: n },
1318
1327
  bubbles: !0,
1319
1328
  composed: !0
1320
1329
  }));
@@ -1331,13 +1340,14 @@ new (nn = (Vt = /*#__PURE__*/ new WeakMap(), Ht = /*#__PURE__*/ new WeakMap(), I
1331
1340
  return typeof t?.value == "string" ? t.value : "";
1332
1341
  }
1333
1342
  render() {
1334
- return _`
1343
+ return b`
1335
1344
  <section class="access-grants-form" aria-label="Add access">
1336
1345
  <p>Add person, group or software agent URL.</p>
1337
1346
  <div class="access-grants-form-main">
1338
1347
  <div class="access-grants-input">
1339
1348
  <solid-ui-combobox
1340
1349
  class="access-principal-combobox"
1350
+ .disabled=${this.disabled}
1341
1351
  label="Add person, group or software agent URL."
1342
1352
  .srOnlyLabel=${!0}
1343
1353
  .value=${this.principalInputValue}
@@ -1346,15 +1356,16 @@ new (nn = (Vt = /*#__PURE__*/ new WeakMap(), Ht = /*#__PURE__*/ new WeakMap(), I
1346
1356
  @input=${this.onPrincipalInput}
1347
1357
  @change=${this.onPrincipalSelect}
1348
1358
  ></solid-ui-combobox>
1349
- ${this.inputError ? _`<p class="access-principal-error" role="alert">${this.inputError}</p>` : d}
1359
+ ${this.inputError ? b`<p class="access-principal-error" role="alert">${this.inputError}</p>` : m}
1350
1360
  ${this.renderPendingAccessGrants()}
1351
1361
  </div>
1352
1362
  <solid-ui-combobox
1353
1363
  class="access-role-select access-role-select--top"
1364
+ .disabled=${this.disabled}
1354
1365
  .value=${this.addAccessRoleValue}
1355
1366
  @change=${this.onRoleChange}
1356
1367
  >
1357
- ${r.filter((e) => e !== "No Access").map((e) => _`
1368
+ ${i.filter((e) => e !== "No Access").map((e) => b`
1358
1369
  <solid-ui-combobox-option value=${e}>${e}</solid-ui-combobox-option>
1359
1370
  `)}
1360
1371
  </solid-ui-combobox>
@@ -1363,15 +1374,19 @@ new (nn = (Vt = /*#__PURE__*/ new WeakMap(), Ht = /*#__PURE__*/ new WeakMap(), I
1363
1374
  `;
1364
1375
  }
1365
1376
  renderPendingAccessGrants() {
1366
- return this.pendingAccessGrants.length ? _`
1377
+ return this.pendingAccessGrants.length ? b`
1367
1378
  <div class="access-grants-pending">
1368
- ${this.pendingAccessGrants.map((e, t) => _`
1379
+ ${this.pendingAccessGrants.map((e, t) => b`
1369
1380
  <div class="access-grants-pending-item">
1370
- <span class="access-grants-pending-item-label">${e.label}</span>
1381
+ <span class="access-grants-pending-item-label">
1382
+ ${e.targetKind === "trustedApp" ? b`<icon-lucide-globe style="width: 13px; height: 13px; vertical-align: -2px;"></icon-lucide-globe>` : m}
1383
+ ${e.label}
1384
+ </span>
1371
1385
  <solid-ui-button
1372
1386
  type="button"
1373
1387
  variant="ghost"
1374
1388
  class="access-grants-pending-item-remove"
1389
+ ?disabled=${this.disabled}
1375
1390
  @click=${() => this.onPendingGrantRemove(t)}
1376
1391
  >
1377
1392
  <span class="sr-only">Remove ${e.label}</span>
@@ -1380,118 +1395,193 @@ new (nn = (Vt = /*#__PURE__*/ new WeakMap(), Ht = /*#__PURE__*/ new WeakMap(), I
1380
1395
  </div>
1381
1396
  `)}
1382
1397
  </div>
1383
- ` : d;
1398
+ ` : m;
1384
1399
  }
1385
- }, {e: [qt, Yt, Zt, $t, tn, Ut], c: [gn, Wt]} = cn(Bt, [
1400
+ }, {e: [Zt, $t, tn, rn, on, cn, qt], c: [Sn, Jt]} = mn(Kt, [
1386
1401
  [
1387
- Kt,
1402
+ Xt,
1388
1403
  1,
1389
1404
  "principalInputValue"
1390
1405
  ],
1391
1406
  [
1392
- Jt,
1407
+ Qt,
1393
1408
  1,
1394
1409
  "addAccessRoleValue"
1395
1410
  ],
1396
1411
  [
1397
- Xt,
1412
+ en,
1398
1413
  1,
1399
1414
  "pendingAccessGrants"
1400
1415
  ],
1401
1416
  [
1402
- Qt,
1417
+ nn,
1403
1418
  1,
1404
1419
  "inputError"
1405
1420
  ],
1406
1421
  [
1407
- en,
1422
+ an,
1423
+ 1,
1424
+ "disabled"
1425
+ ],
1426
+ [
1427
+ sn,
1408
1428
  1,
1409
1429
  "asyncOptionsProvider"
1410
1430
  ]
1411
- ], Gt, 0, void 0, m), Bt), zt = class extends pn {
1431
+ ], Yt, 0, void 0, _), Kt), Gt = class extends yn {
1412
1432
  constructor() {
1413
- super(gn), sn(this, "styles", Rt), Wt();
1433
+ super(Sn), pn(this, "styles", Wt), Jt();
1414
1434
  }
1415
- }, sn(zt, nn, void 0), zt)();
1416
- //#endregion
1417
- //#region src/components/access-control-modal/accessTargetResolver.ts
1418
- async function _n(e) {
1419
- let t = yt(e);
1435
+ }, pn(Gt, ln, void 0), Gt)();
1436
+ // src/components/access-control-modal/helpers.ts
1437
+ function Cn(e) {
1438
+ try {
1439
+ let t = new URL(e);
1440
+ return (t.protocol === "http:" || t.protocol === "https:") && !!t.hostname;
1441
+ } catch {
1442
+ return !1;
1443
+ }
1444
+ }
1445
+ function wn(e) {
1446
+ if (!Cn(e)) return !1;
1447
+ let t = new URL(e);
1448
+ return t.pathname === "/" && !t.search && !t.hash && !t.username && !t.password;
1449
+ }
1450
+ function Tn(e) {
1451
+ let t = e.trim();
1452
+ if (t && !Cn(t)) try {
1453
+ let e = new URL(`https://${t}`), n = e.protocol === "http:" || e.protocol === "https:", r = e.pathname === "/" && !e.search && !e.hash, i = e.hostname.includes(".") || e.hostname.includes(":");
1454
+ return n && r && i && !e.username && !e.password ? e.origin : void 0;
1455
+ } catch {
1456
+ return;
1457
+ }
1458
+ }
1459
+ function En(e, t) {
1460
+ let n = /* @__PURE__ */ new Map();
1461
+ for (let r of e) {
1462
+ let e = t(r);
1463
+ e && !n.has(e) && n.set(e, r);
1464
+ }
1465
+ return [...n.values()];
1466
+ }
1467
+ function Dn(e) {
1468
+ return En(e, (e) => e.value);
1469
+ }
1470
+ // src/components/access-control-modal/accessTargetResolver.ts
1471
+ async function On(e) {
1472
+ let t = Tn(e);
1420
1473
  return t ? {
1421
1474
  kind: "origin",
1422
1475
  subjectValue: t
1476
+ } : wn(e) ? {
1477
+ kind: "origin",
1478
+ subjectValue: new URL(e).origin
1423
1479
  } : await a.acl.classifyAccessControlSubject(e);
1424
1480
  }
1425
- async function vn(t, n) {
1426
- if (!t || t.kind === "origin") return t?.subjectValue;
1427
- let r = e(t.subjectValue);
1428
- await a.store.fetcher.load(r.doc());
1429
- let i = n?.trim() || s(r).trim();
1430
- if (i && i !== t.subjectValue) return i;
1481
+ async function kn(e, t) {
1482
+ if (!e || e.kind === "origin") return e?.subjectValue;
1483
+ let n = o(e.subjectValue);
1484
+ await a.store.fetcher.load(n.doc());
1485
+ let r = t?.trim() || u(n).trim();
1486
+ if (!r || r === e.subjectValue) throw Error("The access target has no usable display label.");
1487
+ return r;
1431
1488
  }
1432
- async function yn(e, t) {
1433
- let n = await _n(e);
1489
+ async function An(e, t) {
1490
+ let n = await On(e);
1434
1491
  if (!n) return;
1435
- let r = await vn(n, t);
1492
+ let r = await kn(n, t);
1436
1493
  if (r) return {
1437
1494
  subjectType: n.kind,
1438
1495
  subjectValue: n.subjectValue,
1439
- label: r
1496
+ label: r,
1497
+ targetKind: n.kind === "origin" ? "origin" : void 0
1440
1498
  };
1441
1499
  }
1442
- async function bn(e) {
1443
- let t = await yn(e);
1500
+ async function jn(e) {
1501
+ let t = await An(e);
1444
1502
  return t ? {
1445
1503
  label: t.label,
1446
1504
  value: e
1447
1505
  } : void 0;
1448
1506
  }
1449
- function xn(e, t) {
1507
+ function Mn(e, t) {
1450
1508
  return {
1451
1509
  label: t,
1452
1510
  value: e.uri,
1453
- template: mn({
1511
+ template: bn({
1454
1512
  ...e,
1455
1513
  label: t
1456
1514
  })
1457
1515
  };
1458
1516
  }
1459
- async function Sn(e) {
1460
- let t = yt(e);
1517
+ async function Nn(e) {
1518
+ let t = Tn(e);
1461
1519
  if (t) return [{
1462
1520
  label: `Use origin ${t}`,
1463
- value: t
1521
+ value: t,
1522
+ targetKind: "origin",
1523
+ template: b`<span class="access-grants-directory-entry"><icon-lucide-globe style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-globe><span>Use origin ${t}</span></span>`
1464
1524
  }];
1465
- if (!_t(e)) return [];
1466
- if (vt(e)) return [{
1525
+ if (!Cn(e)) return [];
1526
+ if (wn(e)) return [{
1467
1527
  label: `Use origin ${new URL(e).origin}`,
1468
- value: new URL(e).origin
1528
+ value: new URL(e).origin,
1529
+ targetKind: "origin",
1530
+ template: b`<span class="access-grants-directory-entry"><icon-lucide-globe style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-globe><span>Use origin ${new URL(e).origin}</span></span>`
1469
1531
  }];
1470
- let n = await bn(e);
1471
- return xt(n ? [n] : []);
1532
+ let n = await jn(e);
1533
+ return Dn(n ? [n] : []);
1472
1534
  }
1473
- function Cn(e) {
1535
+ async function Pn(t) {
1536
+ try {
1537
+ let n = a.authn.currentUser();
1538
+ if (!n) return [];
1539
+ await a.profile.loadProfile(n);
1540
+ let r = a.store;
1541
+ return r.each(n, e.acl("trustedApp")).flatMap((n) => {
1542
+ let i = r.any(n, e.acl("origin"));
1543
+ if (!i || !wn(i.value)) return [];
1544
+ let a = new URL(i.value).origin;
1545
+ return t && !`${a} trusted app`.toLowerCase().includes(t.toLowerCase()) ? [] : [{
1546
+ label: `Trusted app: ${a}`,
1547
+ value: a,
1548
+ targetKind: "trustedApp",
1549
+ template: b`<span class="access-grants-directory-entry"><icon-lucide-globe style="width: 13px; height: 13px; flex: 0 0 13px;"></icon-lucide-globe><span>Trusted app: ${a}</span></span>`
1550
+ }];
1551
+ });
1552
+ } catch {
1553
+ return [];
1554
+ }
1555
+ }
1556
+ function Fn(e) {
1474
1557
  return e.length ? e : [{
1475
1558
  label: "Type at least 2 characters to search",
1476
1559
  value: "",
1477
1560
  selectable: !1
1478
1561
  }];
1479
1562
  }
1480
- var wn = v(async (e) => {
1481
- let t = e.trim(), r = await Sn(t);
1482
- if (t.length < 2) return Cn(r);
1483
- let i = [];
1563
+ var In = x(async (e) => {
1564
+ let t = e.trim(), r = await Nn(t), i = await Pn(t);
1565
+ if (t.length < 2) return En([
1566
+ ...r,
1567
+ ...i,
1568
+ ...Fn(r)
1569
+ ], (e) => {
1570
+ let t = e;
1571
+ return typeof t.value == "string" ? `${t.value}:${t.targetKind ?? "default"}` : void 0;
1572
+ });
1573
+ let o = [];
1484
1574
  try {
1485
- i = await a.directory.search({
1575
+ o = await a.directory.search({
1486
1576
  query: t,
1487
1577
  sources: n
1488
1578
  });
1489
1579
  } catch (e) {
1490
- if (!r.length) throw e;
1580
+ if (!r.length && !i.length) throw e;
1491
1581
  }
1492
- let o = (await Promise.all(i.map(async (e) => {
1582
+ let s = (await Promise.all(o.map(async (e) => {
1493
1583
  try {
1494
- let t = await yn(e.uri, e.label);
1584
+ let t = await An(e.uri, e.label);
1495
1585
  return t ? {
1496
1586
  entry: e,
1497
1587
  label: t.label
@@ -1499,30 +1589,44 @@ var wn = v(async (e) => {
1499
1589
  } catch {
1500
1590
  return;
1501
1591
  }
1502
- }))).filter((e) => e !== void 0).map(({ entry: e, label: t }) => xn(e, t));
1503
- return bt([...r, ...o], (e) => typeof e.value == "string" ? e.value : void 0);
1592
+ }))).filter((e) => e !== void 0).map(({ entry: e, label: t }) => Mn(e, t));
1593
+ return En([
1594
+ ...r,
1595
+ ...i,
1596
+ ...s
1597
+ ], (e) => {
1598
+ let t = e;
1599
+ return typeof t.value == "string" ? `${t.value}:${t.targetKind ?? "default"}` : void 0;
1600
+ });
1504
1601
  });
1505
- //#endregion
1506
- //#region src/components/access-control-modal/applyAccessChanges.ts
1507
- async function Tn(e, t) {
1508
- let n = [];
1509
- for (let { subject: r, label: i, role: s } of t) try {
1510
- let t = s === "No Access" ? await a.acl.planRevoke(e, r) : await a.acl.planGrant(e, r, r.type === "agentClass" && r.iri === o.iri ? a.acl.modesFromPublicRole(s) : a.acl.modesFromRole(s));
1511
- await a.acl.applyPlan(t);
1602
+ // src/components/access-control-modal/applyAccessChanges.ts
1603
+ async function Ln(e, t, n = {}) {
1604
+ let r = [], i = n.containerScope ?? "file";
1605
+ for (let { subject: n, label: o, role: s } of t) try {
1606
+ let t = i === "folder+contents" ? a.acl.planGrantContainerAndContents : i === "container" ? a.acl.planGrantContainer : i === "contents" ? a.acl.planGrantContainerContents : a.acl.planGrant, r = s === "No Access" ? await (i === "contents" ? a.acl.planRevokeContainerContents(e, n) : a.acl.planRevoke(e, n)) : await t(e, n, Rn(n, s));
1607
+ await a.acl.applyPlan(r);
1512
1608
  } catch (e) {
1513
- n.push({
1609
+ r.push({
1514
1610
  action: s === "No Access" ? "revoke" : "grant",
1515
- targetUri: r.iri,
1516
- label: i,
1611
+ targetUri: n.iri,
1612
+ label: o,
1517
1613
  role: s,
1614
+ scope: i,
1518
1615
  message: e instanceof Error ? e.message : "Unable to apply access change."
1519
1616
  });
1520
1617
  }
1521
- return n;
1618
+ return r;
1522
1619
  }
1523
- //#endregion
1524
- //#region src/components/access-control-modal/buildAccessChanges.ts
1525
- function En({ pendingAccessGrants: e, generalAccessChanges: t, changedAccessGrants: n }) {
1620
+ function Rn(e, t) {
1621
+ if (e.type === "agentClass" && e.iri === r.iri) {
1622
+ let e = c.find((e) => e === t);
1623
+ if (!e) throw Error(`Public access does not support the ${t} role.`);
1624
+ return a.acl.modesFromPublicRole(e);
1625
+ }
1626
+ return a.acl.modesFromRole(t);
1627
+ }
1628
+ // src/components/access-control-modal/buildAccessChanges.ts
1629
+ function zn({ pendingAccessGrants: e, generalAccessChanges: t, changedAccessGrants: n }) {
1526
1630
  return [
1527
1631
  ...e.map((e) => ({
1528
1632
  subject: {
@@ -1536,38 +1640,37 @@ function En({ pendingAccessGrants: e, generalAccessChanges: t, changedAccessGran
1536
1640
  ...n.flatMap(({ subjects: e, role: t }) => e.map((e) => ({
1537
1641
  subject: e,
1538
1642
  role: t,
1539
- label: Pt(e)
1643
+ label: Bt(e)
1540
1644
  })))
1541
1645
  ];
1542
1646
  }
1543
- //#endregion
1544
- //#region src/components/access-control-modal/AccessControlModal.ts
1545
- var Dn, On, H, U, W, G, K, q, J, Y, X, kn, An, jn, Mn, Nn, Pn, Fn, In, Ln, Rn, zn, Bn, Vn, Hn, Un, Wn, Gn, Kn, qn, Jn, Yn, Xn, Zn, Qn, $n, er, tr, nr, rr;
1546
- function Z(e, t, n) {
1547
- ir(e, t), t.set(e, n);
1647
+ // src/components/access-control-modal/AccessControlModal.ts
1648
+ var Bn, Vn, G, K, q, J, Hn, Un, Wn, Gn, Kn, qn, Jn, Yn, Xn, Zn, Y, Qn, $n, er, tr, nr, rr, ir, ar, or, sr, cr, lr, ur, dr, fr, pr, mr, hr, gr, _r, vr, yr, br, xr, Sr, Cr, wr, Tr, Er, Dr, Or, kr, Ar, jr, Mr, Nr, Pr, Fr, Ir, Lr, Rr, zr, Br, Vr;
1649
+ function X(e, t, n) {
1650
+ Hr(e, t), t.set(e, n);
1548
1651
  }
1549
- function ir(e, t) {
1652
+ function Hr(e, t) {
1550
1653
  if (t.has(e)) throw TypeError("Cannot initialize the same private elements twice on an object");
1551
1654
  }
1552
- function Q(e, t, n) {
1553
- return e.set(ar(e, t), n), n;
1655
+ function Z(e, t, n) {
1656
+ return e.set(Ur(e, t), n), n;
1554
1657
  }
1555
- function $(e, t) {
1556
- return e.get(ar(e, t));
1658
+ function Q(e, t) {
1659
+ return e.get(Ur(e, t));
1557
1660
  }
1558
- function ar(e, t, n) {
1661
+ function Ur(e, t, n) {
1559
1662
  if (typeof e == "function" ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
1560
1663
  throw TypeError("Private element is not present on this object");
1561
1664
  }
1562
- function or(e, t, n) {
1563
- return (t = cr(t)) in e ? Object.defineProperty(e, t, {
1665
+ function $(e, t, n) {
1666
+ return (t = Gr(t)) in e ? Object.defineProperty(e, t, {
1564
1667
  value: n,
1565
1668
  enumerable: !0,
1566
1669
  configurable: !0,
1567
1670
  writable: !0
1568
1671
  }) : e[t] = n, e;
1569
1672
  }
1570
- function sr(e, t, n, r, i, a) {
1673
+ function Wr(e, t, n, r, i, a) {
1571
1674
  function o(e, t, n) {
1572
1675
  return function(r, i) {
1573
1676
  return n && n(r), e[t].call(r, i);
@@ -1590,13 +1693,13 @@ function sr(e, t, n, r, i, a) {
1590
1693
  n || Array.isArray(_) || (_ = [_]);
1591
1694
  var b = {}, x = [], S = i === 3 ? "get" : i === 4 || p ? "set" : "value";
1592
1695
  d ? (f || p ? b = {
1593
- get: ur(function() {
1696
+ get: qr(function() {
1594
1697
  return v(this);
1595
1698
  }, r, "get"),
1596
1699
  set: function(e) {
1597
1700
  t[4](this, e);
1598
1701
  }
1599
- } : b[S] = v, f || ur(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
1702
+ } : b[S] = v, f || qr(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
1600
1703
  }
1601
1704
  for (var C = e, w = _.length - 1; w >= 0; w -= n ? 2 : 1) {
1602
1705
  var T = _[w], E = n ? _[w - 1] : void 0, D = {}, O = {
@@ -1656,7 +1759,7 @@ function sr(e, t, n, r, i, a) {
1656
1759
  if (arguments.length >= 6) var d = a[Symbol.metadata || Symbol.for("Symbol.metadata")];
1657
1760
  var f = Object.create(d ?? null), p = function(e, t, n, r) {
1658
1761
  var i, a, o = [], c = function(t) {
1659
- return dr(t) === e;
1762
+ return Jr(t) === e;
1660
1763
  }, u = /* @__PURE__ */ new Map();
1661
1764
  function d(e) {
1662
1765
  e && o.push(s.bind(null, e));
@@ -1670,7 +1773,7 @@ function sr(e, t, n, r, i, a) {
1670
1773
  if (!0 === x || x === 3 && m !== 4 || x === 4 && m !== 3) throw Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: " + h);
1671
1774
  u.set(b, !(m > 2) || m);
1672
1775
  }
1673
- l(v ? e : e.prototype, p, _, g ? "#" + h : cr(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
1776
+ l(v ? e : e.prototype, p, _, g ? "#" + h : Gr(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
1674
1777
  }
1675
1778
  }
1676
1779
  return d(i), d(a), o;
@@ -1683,11 +1786,11 @@ function sr(e, t, n, r, i, a) {
1683
1786
  }
1684
1787
  };
1685
1788
  }
1686
- function cr(e) {
1687
- var t = lr(e, "string");
1789
+ function Gr(e) {
1790
+ var t = Kr(e, "string");
1688
1791
  return typeof t == "symbol" ? t : t + "";
1689
1792
  }
1690
- function lr(e, t) {
1793
+ function Kr(e, t) {
1691
1794
  if (typeof e != "object" || !e) return e;
1692
1795
  var n;
1693
1796
  if (typeof Symbol < "u" && (n = e[Symbol.toPrimitive]) !== void 0) {
@@ -1697,7 +1800,7 @@ function lr(e, t) {
1697
1800
  }
1698
1801
  return (t === "string" ? String : Number)(e);
1699
1802
  }
1700
- function ur(e, t, n) {
1803
+ function qr(e, t, n) {
1701
1804
  typeof t == "symbol" && (t = (t = t.description) ? "[" + t + "]" : "");
1702
1805
  try {
1703
1806
  Object.defineProperty(e, "name", {
@@ -1707,90 +1810,132 @@ function ur(e, t, n) {
1707
1810
  } catch {}
1708
1811
  return e;
1709
1812
  }
1710
- function dr(e) {
1813
+ function Jr(e) {
1711
1814
  if (Object(e) !== e) throw TypeError("right-hand side of 'in' should be an object, got " + (e === null ? "null" : typeof e));
1712
1815
  return e;
1713
1816
  }
1714
- function fr(e) {
1817
+ function Yr(e) {
1715
1818
  return e;
1716
1819
  }
1717
- function pr(e) {
1820
+ function Xr(e) {
1718
1821
  return e != null;
1719
1822
  }
1720
- Nn = [f("solid-ui-access-control-modal")];
1721
- var mr;
1722
- new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W = /*#__PURE__*/ new WeakMap(), G = /*#__PURE__*/ new WeakMap(), K = /*#__PURE__*/ new WeakMap(), q = /*#__PURE__*/ new WeakMap(), J = /*#__PURE__*/ new WeakMap(), Y = /*#__PURE__*/ new WeakMap(), X = /*#__PURE__*/ new WeakMap(), kn = /*#__PURE__*/ new WeakMap(), An = /*#__PURE__*/ new WeakMap(), rr = (Pn = p({ attribute: !1 }), In = p({ attribute: !1 }), Rn = g(), Bn = g(), Hn = g(), Wn = g(), Kn = g(), Jn = g(), Xn = g(), Qn = g(), er = g(), "subjectUri"), On = class extends u {
1823
+ rr = [h("solid-ui-access-control-modal")];
1824
+ var Zr;
1825
+ new (Br = (G = /*#__PURE__*/ new WeakMap(), K = /*#__PURE__*/ new WeakMap(), q = /*#__PURE__*/ new WeakMap(), J = /*#__PURE__*/ new WeakMap(), Hn = /*#__PURE__*/ new WeakMap(), Un = /*#__PURE__*/ new WeakMap(), Wn = /*#__PURE__*/ new WeakMap(), Gn = /*#__PURE__*/ new WeakMap(), Kn = /*#__PURE__*/ new WeakMap(), qn = /*#__PURE__*/ new WeakMap(), Jn = /*#__PURE__*/ new WeakMap(), Yn = /*#__PURE__*/ new WeakMap(), Xn = /*#__PURE__*/ new WeakMap(), Zn = /*#__PURE__*/ new WeakMap(), Y = /*#__PURE__*/ new WeakMap(), Qn = /*#__PURE__*/ new WeakMap(), $n = /*#__PURE__*/ new WeakMap(), er = /*#__PURE__*/ new WeakMap(), Vr = (ir = g({ attribute: !1 }), or = g({ attribute: !1 }), cr = y(), ur = y(), fr = y(), mr = y(), gr = y(), vr = y(), br = y(), Sr = y(), wr = y(), Er = y(), Or = y(), Ar = y(), Mr = y(), Pr = y(), Ir = y(), Rr = y(), "subjectUri"), Vn = class extends p {
1723
1826
  constructor(...e) {
1724
- super(...e), Z(this, H, (jn(this), Fn(this, void 0))), Z(this, U, Ln(this, void 0)), Z(this, W, zn(this, "")), Z(this, G, Vn(this, "Viewer")), Z(this, K, Un(this, "No Access")), Z(this, q, Gn(this, "No Access")), Z(this, J, qn(this, !1)), Z(this, Y, Yn(this, [])), Z(this, X, Zn(this, [])), Z(this, kn, $n(this, [])), Z(this, An, tr(this, !0)), or(this, "accessGrantLabelRequestVersion", 0);
1827
+ super(...e), X(this, G, (tr(this), ar(this, void 0))), X(this, K, sr(this, void 0)), X(this, q, lr(this, "")), X(this, J, dr(this, "Viewer")), X(this, Hn, pr(this, "No Access")), X(this, Un, hr(this, "No Access")), X(this, Wn, _r(this, !1)), X(this, Gn, yr(this, [])), X(this, Kn, xr(this, [])), X(this, qn, Cr(this, [])), X(this, Jn, Tr(this, !0)), X(this, Yn, Dr(this)), X(this, Xn, kr(this, !1)), X(this, Zn, jr(this, "")), X(this, Y, Nr(this, !1)), X(this, Qn, Fr(this, "folder+contents")), X(this, $n, Lr(this)), X(this, er, zr(this, !1)), $(this, "accessGrantLabelRequestVersion", 0), $(this, "accessContextRequestVersion", 0), $(this, "accessContextSubjectUri", void 0);
1725
1828
  }
1726
- get [rr]() {
1727
- return $(H, this);
1829
+ get [Vr]() {
1830
+ return Q(G, this);
1728
1831
  }
1729
1832
  set subjectUri(e) {
1730
- Q(H, this, e);
1833
+ Z(G, this, e);
1731
1834
  }
1732
1835
  get accessGrants() {
1733
- return $(U, this);
1836
+ return Q(K, this);
1734
1837
  }
1735
1838
  set accessGrants(e) {
1736
- Q(U, this, e);
1839
+ Z(K, this, e);
1737
1840
  }
1738
1841
  get principalInputValue() {
1739
- return $(W, this);
1842
+ return Q(q, this);
1740
1843
  }
1741
1844
  set principalInputValue(e) {
1742
- Q(W, this, e);
1845
+ Z(q, this, e);
1743
1846
  }
1744
1847
  get addAccessRoleValue() {
1745
- return $(G, this);
1848
+ return Q(J, this);
1746
1849
  }
1747
1850
  set addAccessRoleValue(e) {
1748
- Q(G, this, e);
1851
+ Z(J, this, e);
1749
1852
  }
1750
1853
  get authenticatedAccessRoleValue() {
1751
- return $(K, this);
1854
+ return Q(Hn, this);
1752
1855
  }
1753
1856
  set authenticatedAccessRoleValue(e) {
1754
- Q(K, this, e);
1857
+ Z(Hn, this, e);
1755
1858
  }
1756
1859
  get publicAccessRoleValue() {
1757
- return $(q, this);
1860
+ return Q(Un, this);
1758
1861
  }
1759
1862
  set publicAccessRoleValue(e) {
1760
- Q(q, this, e);
1863
+ Z(Un, this, e);
1761
1864
  }
1762
1865
  get submitting() {
1763
- return $(J, this);
1866
+ return Q(Wn, this);
1764
1867
  }
1765
1868
  set submitting(e) {
1766
- Q(J, this, e);
1869
+ Z(Wn, this, e);
1767
1870
  }
1768
1871
  get pendingAccessGrants() {
1769
- return $(Y, this);
1872
+ return Q(Gn, this);
1770
1873
  }
1771
1874
  set pendingAccessGrants(e) {
1772
- Q(Y, this, e);
1875
+ Z(Gn, this, e);
1773
1876
  }
1774
1877
  get accessGrantDrafts() {
1775
- return $(X, this);
1878
+ return Q(Kn, this);
1776
1879
  }
1777
1880
  set accessGrantDrafts(e) {
1778
- Q(X, this, e);
1881
+ Z(Kn, this, e);
1779
1882
  }
1780
1883
  get errors() {
1781
- return $(kn, this);
1884
+ return Q(qn, this);
1782
1885
  }
1783
1886
  set errors(e) {
1784
- Q(kn, this, e);
1887
+ Z(qn, this, e);
1785
1888
  }
1786
1889
  get successfulChangesRefreshed() {
1787
- return $(An, this);
1890
+ return Q(Jn, this);
1788
1891
  }
1789
1892
  set successfulChangesRefreshed(e) {
1790
- Q(An, this, e);
1893
+ Z(Jn, this, e);
1894
+ }
1895
+ get accessContext() {
1896
+ return Q(Yn, this);
1897
+ }
1898
+ set accessContext(e) {
1899
+ Z(Yn, this, e);
1900
+ }
1901
+ get accessContextLoading() {
1902
+ return Q(Xn, this);
1903
+ }
1904
+ set accessContextLoading(e) {
1905
+ Z(Xn, this, e);
1906
+ }
1907
+ get accessContextError() {
1908
+ return Q(Zn, this);
1909
+ }
1910
+ set accessContextError(e) {
1911
+ Z(Zn, this, e);
1912
+ }
1913
+ get advancedSharingOpen() {
1914
+ return Q(Y, this);
1915
+ }
1916
+ set advancedSharingOpen(e) {
1917
+ Z(Y, this, e);
1918
+ }
1919
+ get containerScope() {
1920
+ return Q(Qn, this);
1921
+ }
1922
+ set containerScope(e) {
1923
+ Z(Qn, this, e);
1924
+ }
1925
+ get containerScopeAnalysis() {
1926
+ return Q($n, this);
1927
+ }
1928
+ set containerScopeAnalysis(e) {
1929
+ Z($n, this, e);
1930
+ }
1931
+ get protectedTarget() {
1932
+ return Q(er, this);
1933
+ }
1934
+ set protectedTarget(e) {
1935
+ Z(er, this, e);
1791
1936
  }
1792
1937
  disconnectedCallback() {
1793
- this.accessGrantLabelRequestVersion++, this.errors = [], super.disconnectedCallback();
1938
+ this.accessGrantLabelRequestVersion++, this.accessContextRequestVersion++, this.errors = [], super.disconnectedCallback();
1794
1939
  }
1795
1940
  get inputError() {
1796
1941
  return this.errors.find((e) => e.action === "input")?.message ?? "";
@@ -1806,28 +1951,33 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
1806
1951
  }
1807
1952
  willUpdate(e) {
1808
1953
  if (super.willUpdate(e), e.has("accessGrants")) {
1809
- let e = this.accessGrants ?? [];
1810
- this.accessGrantDrafts = kt(e), this.authenticatedAccessRoleValue = Mt(e), this.publicAccessRoleValue = Nt(e);
1954
+ let e = this.getScopedAccessGrants();
1955
+ this.accessGrantDrafts = Ft(e), this.authenticatedAccessRoleValue = Rt(e), this.publicAccessRoleValue = zt(e);
1811
1956
  }
1812
1957
  }
1813
1958
  updated(e) {
1814
- super.updated(e), e.has("accessGrants") && this.refreshAccessGrantLabels().catch((e) => {
1815
- c("Failed to refresh access grant labels", e);
1816
- });
1959
+ super.updated(e), e.has("subjectUri") && this.loadAccessContext().catch((e) => {
1960
+ d("Failed to load access control context", e);
1961
+ }), e.has("accessGrants") && this.refreshAccessGrantLabels().catch((e) => {
1962
+ d("Failed to refresh access grant labels", e);
1963
+ }), e.has("accessContext") && !e.has("subjectUri") && this.refreshContainerScopeAnalysis();
1964
+ }
1965
+ refreshContainerScopeAnalysis() {
1966
+ this.isContainer() && this.accessContext ? (this.containerScopeAnalysis = t(this.accessContext), this.containerScope = this.containerScopeAnalysis.primaryScope, this.refreshScopedAccessGrantDrafts()) : this.containerScopeAnalysis = void 0;
1817
1967
  }
1818
1968
  async refreshAccessGrantLabels() {
1819
- let t = ++this.accessGrantLabelRequestVersion, n = this.accessGrants ?? [];
1820
- if (!n.length) {
1969
+ let e = ++this.accessGrantLabelRequestVersion, t = this.accessGrants, n = this.subjectUri, r = this.getSelectedContainerScope(), i = this.getScopedAccessGrants(r);
1970
+ if (!i.length) {
1821
1971
  this.accessGrantDrafts = [];
1822
1972
  return;
1823
1973
  }
1824
- let r = await Promise.all(n.map(async (t) => (await Promise.all(t.agentGroup.map(async (t) => {
1974
+ let s = await Promise.all(i.map(async (e) => (await Promise.all(e.agentGroup.map(async (e) => {
1825
1975
  try {
1826
- await a.store.fetcher.load(e(t).doc());
1976
+ await a.store.fetcher.load(o(e).doc());
1827
1977
  } catch {}
1828
- })), Et(St(t)))));
1829
- if (t === this.accessGrantLabelRequestVersion && this.accessGrants === n) {
1830
- let e = new Map(Tt(n).map((e, t) => [e, r[t]]));
1978
+ })), Mt(Ot(e)))));
1979
+ if (e === this.accessGrantLabelRequestVersion && this.accessGrants === t && this.subjectUri === n && this.getSelectedContainerScope() === r) {
1980
+ let e = new Map(jt(i).map((e, t) => [e, s[t]]));
1831
1981
  this.accessGrantDrafts = this.accessGrantDrafts.map((t) => ({
1832
1982
  ...t,
1833
1983
  subjectLabel: e.get(t.id) ?? t.subjectLabel
@@ -1835,31 +1985,203 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
1835
1985
  }
1836
1986
  }
1837
1987
  getDialogTitle() {
1838
- let t = this.subjectUri ? e(this.subjectUri) : void 0, n = t ? s(t).trim() : "";
1839
- return !n || n === "this resource" ? "Share this resource" : `Share "${n}"`;
1988
+ let e = this.subjectUri ? o(this.subjectUri) : void 0, t = e ? u(e).trim() : "";
1989
+ return !t || t === "this resource" ? "Manage Access of \"this resource\"" : `Manage Access of "${t}"`;
1990
+ }
1991
+ isContainer() {
1992
+ return !!(this.subjectUri && new URL(this.subjectUri).pathname.endsWith("/"));
1993
+ }
1994
+ async loadAccessContext() {
1995
+ let e = ++this.accessContextRequestVersion, t = this.subjectUri;
1996
+ if (this.accessContext = void 0, this.accessContextSubjectUri = void 0, this.accessContextError = "", this.accessContextLoading = !!t, !t) this.accessContextLoading = !1;
1997
+ else try {
1998
+ let n = await a.acl.findEffectiveAcl(t);
1999
+ if (e !== this.accessContextRequestVersion || this.subjectUri !== t) return;
2000
+ this.accessContext = n, this.accessContextSubjectUri = t, this.accessContext?.inherited && !this.accessGrants?.length && (this.accessGrants = this.accessContext.authorizations), this.refreshContainerScopeAnalysis(), this.protectedTarget = a.acl.isProtectedResource(t), this.protectedTarget && this.refreshScopedAccessGrantDrafts();
2001
+ } catch (n) {
2002
+ if (e !== this.accessContextRequestVersion || this.subjectUri !== t) return;
2003
+ this.accessContextError = n instanceof Error && n.message.trim() ? n.message : "Unable to load access settings for this resource.", d("Failed to load access control context", n);
2004
+ } finally {
2005
+ e === this.accessContextRequestVersion && this.subjectUri === t && (this.accessContextLoading = !1);
2006
+ }
2007
+ }
2008
+ async ensureAccessContext() {
2009
+ return this.subjectUri ? !this.isConnected || this.accessContextSubjectUri === this.subjectUri && this.accessContext && !this.accessContextError ? !0 : (await this.loadAccessContext(), this.accessContextSubjectUri === this.subjectUri && !!this.accessContext && !this.accessContextError) : !1;
2010
+ }
2011
+ canMutate() {
2012
+ return !this.isConnected || !this.subjectUri || !(!this.subjectUri || this.accessContextSubjectUri !== this.subjectUri || !this.accessContext || this.accessContextLoading || this.accessContextError);
2013
+ }
2014
+ async retryAccessContext() {
2015
+ await this.loadAccessContext();
2016
+ }
2017
+ renderSharingInformation() {
2018
+ if (!this.accessContext) return b``;
2019
+ let e = !this.accessContext.inherited, t = this.accessContext?.effectiveContainer, n = t ? u(o(t)).trim() : "", r = n && n !== t ? b`<strong>${n}</strong> (${t})` : b`<strong>${t ?? "the parent container"}</strong>`;
2020
+ return b`
2021
+ <div class="access-control-sharing-state-panel">
2022
+ ${e ? b`
2023
+ <div class="access-control-sharing-state-custom-row">
2024
+ <p>This resource has its own sharing settings.</p>
2025
+ ${this.protectedTarget ? b`` : b`
2026
+ <solid-ui-button
2027
+ type="button"
2028
+ variant="tertiary"
2029
+ aria-label="Reset custom sharing to default"
2030
+ @click=${this.onResetToDefault}
2031
+ >
2032
+ Reset to default
2033
+ </solid-ui-button>
2034
+ `}
2035
+ </div>
2036
+ ` : t ? b`<p>This resource inherits sharing settings from ${r}.</p>` : b`<p>This resource inherits sharing settings, but no inherited default is available.</p>`}
2037
+ ${this.protectedTarget ? b`<p class="access-control-sharing-state-protected-message">This is a protected storage resource. Its primary access-control settings cannot be reset here.</p>` : b``}
2038
+ </div>
2039
+ `;
2040
+ }
2041
+ renderSharingState() {
2042
+ return !this.accessContext || !this.advancedSharingOpen ? b`` : b`
2043
+ <section
2044
+ class="access-control-sharing-state"
2045
+ aria-labelledby="access-control-advanced-sharing-heading"
2046
+ >
2047
+ ${this.renderSharingInformation()}
2048
+ ${this.renderAdvancedSharing()}
2049
+ </section>
2050
+ `;
2051
+ }
2052
+ getSelectedContainerScope() {
2053
+ return this.containerScope;
2054
+ }
2055
+ hasMixedContainerPolicy() {
2056
+ return this.isContainer() && this.containerScopeAnalysis?.mixed === !0;
2057
+ }
2058
+ renderAccessContextState() {
2059
+ return this.accessContextLoading ? b`<p role="status">Loading access settings...</p>` : this.accessContextError ? b`
2060
+ <solid-ui-error-state
2061
+ title="Could not load access settings"
2062
+ message=${this.accessContextError}
2063
+ >
2064
+ <solid-ui-button type="button" variant="secondary" @click=${this.retryAccessContext}>
2065
+ Retry
2066
+ </solid-ui-button>
2067
+ </solid-ui-error-state>
2068
+ ` : this.accessContext ? b`` : b`<p role="status">Access settings are not ready yet.</p>`;
2069
+ }
2070
+ renderMixedContainerWarning() {
2071
+ return this.hasMixedContainerPolicy() ? b`
2072
+ <div class="access-control-mixed-policy-warning" role="alert">
2073
+ <strong>This container has different access settings for the folder and its contents.</strong>
2074
+ <span>Changing this mixed policy is an advanced feature and will be available in the next release. Access changes are disabled for now.</span>
2075
+ </div>
2076
+ ` : b``;
2077
+ }
2078
+ getScopedAccessGrants(e = this.getSelectedContainerScope()) {
2079
+ let t = this.accessGrants ?? [];
2080
+ return !this.isContainer() || !this.subjectUri || this.protectedTarget ? t : s(this.subjectUri, t, e, this.accessContext?.inherited ?? !1);
2081
+ }
2082
+ refreshScopedAccessGrantDrafts() {
2083
+ let e = this.getScopedAccessGrants();
2084
+ this.accessGrantDrafts = Ft(e), this.authenticatedAccessRoleValue = Rt(e), this.publicAccessRoleValue = zt(e);
2085
+ }
2086
+ selectContainerScope(e) {
2087
+ this.containerScope = e, this.refreshScopedAccessGrantDrafts();
2088
+ }
2089
+ renderAdvancedSharing() {
2090
+ return this.advancedSharingOpen ? b`
2091
+ <section
2092
+ id="access-control-advanced-sharing"
2093
+ class="access-control-advanced-sharing"
2094
+ role="group"
2095
+ aria-labelledby="access-control-advanced-sharing-heading"
2096
+ aria-describedby="access-control-advanced-sharing-description"
2097
+ >
2098
+ <h2 id="access-control-advanced-sharing-heading">Advanced sharing</h2>
2099
+ <p id="access-control-advanced-sharing-description">
2100
+ <span class="access-control-advanced-sharing-description-line">Use this option when the folder and its contents have different access requirements.</span>
2101
+ <span class="access-control-advanced-sharing-description-line">Choose which access settings to edit.</span>
2102
+ <span class="access-control-advanced-sharing-description-line">Save Changes applies your current edits only to that scope.</span>
2103
+ </p>
2104
+ ${this.isContainer() ? b`
2105
+ <button
2106
+ type="button"
2107
+ class="access-control-same-access-toggle"
2108
+ role="switch"
2109
+ aria-checked=${this.containerScope === "folder+contents" ? "true" : "false"}
2110
+ @click=${() => {
2111
+ let e = this.containerScope !== "folder+contents";
2112
+ this.selectContainerScope(e ? "folder+contents" : this.containerScope === "contents" ? "contents" : "folder");
2113
+ }}
2114
+ >
2115
+ <span class="access-control-switch-track" aria-hidden="true">
2116
+ <span class="access-control-switch-thumb"></span>
2117
+ </span>
2118
+ <span>Use the same access for this folder and its contents</span>
2119
+ </button>
2120
+ <div class="access-control-advanced-sharing-options">
2121
+ <solid-ui-button
2122
+ type="button"
2123
+ variant=${this.containerScope === "folder" ? "primary" : "secondary"}
2124
+ aria-pressed=${this.containerScope === "folder" ? "true" : "false"}
2125
+ @click=${() => {
2126
+ this.selectContainerScope("folder");
2127
+ }}
2128
+ >
2129
+ Folder Only
2130
+ </solid-ui-button>
2131
+ <solid-ui-button
2132
+ type="button"
2133
+ variant=${this.containerScope === "contents" ? "primary" : "secondary"}
2134
+ aria-pressed=${this.containerScope === "contents" ? "true" : "false"}
2135
+ @click=${() => {
2136
+ this.selectContainerScope("contents");
2137
+ }}
2138
+ >
2139
+ Contents Only
2140
+ </solid-ui-button>
2141
+ </div>
2142
+ ` : b``}
2143
+ <div class="access-control-advanced-sharing-actions">
2144
+ <solid-ui-button
2145
+ type="button"
2146
+ variant="ghost"
2147
+ aria-label="Close advanced sharing"
2148
+ title="Close advanced sharing"
2149
+ @click=${this.closeAdvancedSharing}
2150
+ >
2151
+ <icon-lucide-x slot="icon" aria-hidden="true"></icon-lucide-x>
2152
+ <span class="sr-only">Close</span>
2153
+ </solid-ui-button>
2154
+ </div>
2155
+ </section>
2156
+ ` : b``;
1840
2157
  }
1841
2158
  render() {
1842
2159
  let e = this.getDialogTitle();
1843
- return _`
2160
+ return b`
1844
2161
  <solid-ui-dialog title=${e}>
1845
2162
  <form @submit=${this.onSubmit}>
1846
2163
  <solid-ui-dialog-content>
1847
- <solid-ui-access-control-add-access
2164
+ ${this.renderAccessContextState()}
2165
+ ${this.renderMixedContainerWarning()}
2166
+ <solid-ui-access-control-add-access
2167
+ .disabled=${!this.canMutate() || this.hasMixedContainerPolicy()}
1848
2168
  .principalInputValue=${this.principalInputValue}
1849
2169
  .addAccessRoleValue=${this.addAccessRoleValue}
1850
2170
  .pendingAccessGrants=${this.pendingAccessGrants}
1851
2171
  .inputError=${this.inputError}
1852
- .asyncOptionsProvider=${wn}
2172
+ .asyncOptionsProvider=${In}
1853
2173
  @target-input=${this.onPrincipalInput}
1854
2174
  @target-selected=${this.onPrincipalSelect}
1855
2175
  @role-changed=${this.onAddAccessRoleInput}
1856
2176
  @pending-grant-removed=${this.onPendingGrantRemoved}
1857
2177
  ></solid-ui-access-control-add-access>
1858
2178
  <solid-ui-access-control-shared-access
1859
- .accessGrantViewModels=${At(this.accessGrantDrafts)}
2179
+ .disabled=${!this.canMutate() || this.hasMixedContainerPolicy()}
2180
+ .accessGrantViewModels=${It(this.accessGrantDrafts)}
1860
2181
  @access-grant-role-changed=${this.onAccessGrantRoleInput}
1861
2182
  ></solid-ui-access-control-shared-access>
1862
2183
  <solid-ui-access-control-general-access
2184
+ .disabled=${!this.canMutate() || this.hasMixedContainerPolicy()}
1863
2185
  .subjectUri=${this.subjectUri}
1864
2186
  .authenticatedAccessRoleValue=${this.authenticatedAccessRoleValue}
1865
2187
  .publicAccessRoleValue=${this.publicAccessRoleValue}
@@ -1871,6 +2193,7 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
1871
2193
  .successfulChangesRefreshed=${this.successfulChangesRefreshed}
1872
2194
  @close=${this.onCancelClick}
1873
2195
  ></solid-ui-access-control-errors>
2196
+ ${this.renderSharingState()}
1874
2197
  </solid-ui-dialog-content>
1875
2198
 
1876
2199
  <solid-ui-dialog-footer>
@@ -1882,7 +2205,7 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
1882
2205
  Cancel
1883
2206
  </solid-ui-button>
1884
2207
  <solid-ui-button
1885
- ?disabled=${!this.hasUnsavedChanges() || this.submitting || this.saveErrors.length > 0}
2208
+ ?disabled=${!this.canMutate() || !this.hasUnsavedChanges() || this.submitting || this.saveErrors.length > 0 || this.hasMixedContainerPolicy()}
1886
2209
  ?loading=${this.submitting}
1887
2210
  type="button"
1888
2211
  @click=${this.onSaveClick}
@@ -1896,27 +2219,51 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
1896
2219
  `;
1897
2220
  }
1898
2221
  async onSubmit(e) {
1899
- e.preventDefault(), !this.submitting && await this.commitPrincipalFromInputSafely();
2222
+ e.preventDefault(), this.submitting || this.hasMixedContainerPolicy() || this.isConnected && !await this.ensureAccessContext() || await this.commitPrincipalFromInputSafely();
1900
2223
  }
1901
2224
  async onSaveClick() {
1902
- this.submitting || (!this.principalInputValue.trim() || await this.commitPrincipalFromInputSafely()) && await this.saveAccessChanges();
2225
+ if (this.submitting || this.hasMixedContainerPolicy() || this.isConnected && !await this.ensureAccessContext() || this.principalInputValue.trim() && !await this.commitPrincipalFromInputSafely()) return;
2226
+ let e = this.isContainer() && !this.protectedTarget ? this.getSelectedContainerScope() : "file";
2227
+ await this.saveAccessChanges(e === "folder" ? "container" : e);
1903
2228
  }
1904
2229
  onCancelClick() {
1905
2230
  this.close();
1906
2231
  }
1907
- async saveAccessChanges() {
1908
- if (this.submitting) return;
1909
- let e = jt(this.accessGrantDrafts), t = this.getGeneralAccessChanges();
1910
- if ((this.pendingAccessGrants.length || e.length || t.length) && this.subjectUri) {
2232
+ closeAdvancedSharing() {
2233
+ this.advancedSharingOpen = !1;
2234
+ }
2235
+ async onResetToDefault() {
2236
+ if (this.subjectUri && this.canMutate() && this.accessContext && !this.accessContext.inherited && !this.submitting && !this.hasMixedContainerPolicy()) {
2237
+ this.submitting = !0, this.errors = this.errors.filter((e) => e.action === "input");
2238
+ try {
2239
+ await a.acl.resetToDefault(this.subjectUri), await this.loadAccessContext();
2240
+ let e = await a.acl.findAccessGrants(this.subjectUri);
2241
+ this.accessGrants = this.accessContext?.inherited ? this.accessContext.authorizations : e;
2242
+ } catch (e) {
2243
+ this.errors = [...this.errors, {
2244
+ action: "reset",
2245
+ targetUri: this.subjectUri,
2246
+ label: "Custom sharing",
2247
+ message: e instanceof Error ? e.message : "Unable to reset sharing."
2248
+ }], d("Failed to reset access control", e);
2249
+ } finally {
2250
+ this.submitting = !1;
2251
+ }
2252
+ }
2253
+ }
2254
+ async saveAccessChanges(e = "file") {
2255
+ if (this.submitting || !this.canMutate() || this.hasMixedContainerPolicy()) return;
2256
+ let t = Lt(this.accessGrantDrafts), n = this.getGeneralAccessChanges();
2257
+ if ((this.pendingAccessGrants.length || t.length || n.length) && this.subjectUri) {
1911
2258
  this.submitting = !0, this.errors = this.errors.filter((e) => e.action === "input"), this.successfulChangesRefreshed = !0;
1912
2259
  try {
1913
- let n = En({
2260
+ let r = zn({
1914
2261
  pendingAccessGrants: this.pendingAccessGrants,
1915
- generalAccessChanges: t,
1916
- changedAccessGrants: e
1917
- }), r = await Tn(this.subjectUri, n);
1918
- if (r.length) {
1919
- this.errors = [...this.errors, ...r], this.principalInputValue = "", this.pendingAccessGrants = [];
2262
+ generalAccessChanges: n,
2263
+ changedAccessGrants: t
2264
+ }), i = await Ln(this.subjectUri, r, { containerScope: e });
2265
+ if (i.length) {
2266
+ this.errors = [...this.errors, ...i], this.principalInputValue = "", this.pendingAccessGrants = [];
1920
2267
  try {
1921
2268
  this.accessGrants = await a.acl.findAccessGrants(this.subjectUri);
1922
2269
  } catch (e) {
@@ -1925,9 +2272,9 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
1925
2272
  targetUri: this.subjectUri,
1926
2273
  label: "Shared with list",
1927
2274
  message: e instanceof Error ? e.message : "Unable to refresh the access list."
1928
- }], c("Failed to refresh access grants after save errors", e);
2275
+ }], d("Failed to refresh access grants after save errors", e);
1929
2276
  }
1930
- c("Failed to save some access changes", r);
2277
+ d("Failed to save some access changes", i);
1931
2278
  return;
1932
2279
  }
1933
2280
  this.principalInputValue = "", this.pendingAccessGrants = [], this.close();
@@ -1944,49 +2291,50 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
1944
2291
  }
1945
2292
  }
1946
2293
  onPrincipalInput(e) {
1947
- this.principalInputValue = e.detail.value, this.clearInputError();
2294
+ this.canMutate() && !this.hasMixedContainerPolicy() && (this.principalInputValue = e.detail.value, this.clearInputError());
1948
2295
  }
1949
2296
  onPrincipalSelect(e) {
1950
- this.queuePendingPrincipal(e.detail.value, this.addAccessRoleValue, e.detail.label);
2297
+ this.canMutate() && !this.hasMixedContainerPolicy() && this.queuePendingPrincipal(e.detail.value, this.addAccessRoleValue, e.detail.label, void 0, e.detail.targetKind);
1951
2298
  }
1952
2299
  getGeneralAccessChanges() {
1953
2300
  if (!this.subjectUri) return [];
1954
- let e = this.accessGrants ?? [], n = Mt(e), r = Nt(e);
1955
- return [this.authenticatedAccessRoleValue === n ? void 0 : {
1956
- subject: t,
2301
+ let e = this.getScopedAccessGrants(), t = Rt(e), n = zt(e);
2302
+ return [this.authenticatedAccessRoleValue === t ? void 0 : {
2303
+ subject: l,
1957
2304
  role: this.authenticatedAccessRoleValue,
1958
2305
  label: "Authenticated users"
1959
- }, this.publicAccessRoleValue === r ? void 0 : {
1960
- subject: o,
2306
+ }, this.publicAccessRoleValue === n ? void 0 : {
2307
+ subject: r,
1961
2308
  role: this.publicAccessRoleValue,
1962
2309
  label: "Public"
1963
- }].filter(pr);
2310
+ }].filter(Xr);
1964
2311
  }
1965
2312
  onAddAccessRoleInput(e) {
1966
- this.addAccessRoleValue = e.detail.role, this.pendingAccessGrants = this.pendingAccessGrants.map((t) => ({
2313
+ this.canMutate() && !this.hasMixedContainerPolicy() && (this.addAccessRoleValue = e.detail.role, this.pendingAccessGrants = this.pendingAccessGrants.map((t) => ({
1967
2314
  ...t,
1968
2315
  role: e.detail.role
1969
- }));
2316
+ })));
1970
2317
  }
1971
2318
  onAuthenticatedAccessRoleInput(e) {
1972
- this.authenticatedAccessRoleValue = e.detail.role;
2319
+ this.canMutate() && !this.hasMixedContainerPolicy() && (this.authenticatedAccessRoleValue = e.detail.role);
1973
2320
  }
1974
2321
  onPublicAccessRoleInput(e) {
1975
- this.publicAccessRoleValue = e.detail.role;
2322
+ this.canMutate() && !this.hasMixedContainerPolicy() && (this.publicAccessRoleValue = e.detail.role);
1976
2323
  }
1977
2324
  onAccessGrantRoleInput(e) {
1978
- this.accessGrantDrafts = this.accessGrantDrafts.map((t) => t.id === e.detail.id ? {
2325
+ this.canMutate() && !this.hasMixedContainerPolicy() && (this.accessGrantDrafts = this.accessGrantDrafts.map((t) => t.id === e.detail.id ? {
1979
2326
  ...t,
1980
2327
  role: e.detail.role
1981
- } : t);
2328
+ } : t));
1982
2329
  }
1983
2330
  onPendingGrantRemoved(e) {
1984
- this.pendingAccessGrants = this.pendingAccessGrants.filter((t, n) => n !== e.detail.index);
2331
+ this.canMutate() && !this.hasMixedContainerPolicy() && (this.pendingAccessGrants = this.pendingAccessGrants.filter((t, n) => n !== e.detail.index));
1985
2332
  }
1986
2333
  hasUnsavedChanges() {
1987
- return !!(this.pendingAccessGrants.length || this.principalInputValue.trim() || jt(this.accessGrantDrafts).length || this.getGeneralAccessChanges().length);
2334
+ return !!(this.pendingAccessGrants.length || this.principalInputValue.trim() || Lt(this.accessGrantDrafts).length || this.getGeneralAccessChanges().length);
1988
2335
  }
1989
2336
  async commitPrincipalFromInput() {
2337
+ if (!this.canMutate() || this.hasMixedContainerPolicy()) return !1;
1990
2338
  let e = this.principalInputValue.trim();
1991
2339
  return e ? this.queuePendingPrincipal(e, this.addAccessRoleValue, void 0, e) : !1;
1992
2340
  }
@@ -2000,27 +2348,28 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
2000
2348
  label: "Access target",
2001
2349
  targetUri: this.principalInputValue.trim(),
2002
2350
  message: "We could not verify this access target. Check the value and try again."
2003
- }), c("Failed to commit pending access grants", t), !1) : (c("Ignored stale access-target validation error", t), !1);
2351
+ }), d("Failed to commit pending access grants", t), !1) : (d("Ignored stale access-target validation error", t), !1);
2004
2352
  }
2005
2353
  }
2006
- async queuePendingPrincipal(e, t = this.addAccessRoleValue, n, r) {
2007
- let i = r ?? this.principalInputValue.trim(), a = await this.createPendingAccessGrant(e, t, n);
2008
- if ("error" in a) return this.principalInputValue.trim() === i && this.setInputError(a.error), c("Failed to add access grant:", a.error.message), !1;
2009
- let o = [...this.pendingAccessGrants, a.grant];
2010
- return this.pendingAccessGrants = this.dedupePendingAccessGrants(o), this.principalInputValue.trim() === i && (this.clearInputError(), this.principalInputValue = ""), !0;
2354
+ async queuePendingPrincipal(e, t = this.addAccessRoleValue, n, r, i) {
2355
+ let a = r ?? this.principalInputValue.trim(), o = await this.createPendingAccessGrant(e, t, n, i);
2356
+ if ("error" in o) return this.principalInputValue.trim() === a && this.setInputError(o.error), d("Failed to add access grant:", o.error.message), !1;
2357
+ let s = [...this.pendingAccessGrants, o.grant];
2358
+ return this.pendingAccessGrants = this.dedupePendingAccessGrants(s), this.principalInputValue.trim() === a && (this.clearInputError(), this.principalInputValue = ""), !0;
2011
2359
  }
2012
- async createPendingAccessGrant(e, t = this.addAccessRoleValue, n) {
2360
+ async createPendingAccessGrant(e, t = this.addAccessRoleValue, n, r) {
2013
2361
  try {
2014
- let r = e.trim(), i = await yn(r, n);
2015
- return i ? { grant: {
2016
- subjectType: i.subjectType,
2017
- subjectValue: i.subjectValue,
2362
+ let i = e.trim(), a = await An(i, n);
2363
+ return a ? { grant: {
2364
+ subjectType: a.subjectType,
2365
+ subjectValue: a.subjectValue,
2018
2366
  role: t,
2019
- label: i.label
2367
+ label: a.label,
2368
+ targetKind: r ?? a.targetKind
2020
2369
  } } : { error: {
2021
2370
  action: "input",
2022
2371
  label: "Access target",
2023
- targetUri: r,
2372
+ targetUri: i,
2024
2373
  message: "Could not verify this access target"
2025
2374
  } };
2026
2375
  } catch (t) {
@@ -2033,73 +2382,108 @@ new (nr = (H = /*#__PURE__*/ new WeakMap(), U = /*#__PURE__*/ new WeakMap(), W =
2033
2382
  }
2034
2383
  }
2035
2384
  dedupePendingAccessGrants(e) {
2036
- return bt(e, (e) => `${e.subjectType}:${e.subjectValue}`);
2385
+ let t = /* @__PURE__ */ new Map();
2386
+ for (let n of e) t.set(`${n.subjectType}:${n.subjectValue}`, n);
2387
+ return [...t.values()];
2037
2388
  }
2038
- }, {e: [Fn, Ln, zn, Vn, Un, Gn, qn, Yn, Zn, $n, tr, jn], c: [mr, Mn]} = sr(On, [
2389
+ }, {e: [ar, sr, lr, dr, pr, hr, _r, yr, xr, Cr, Tr, Dr, kr, jr, Nr, Fr, Lr, zr, tr], c: [Zr, nr]} = Wr(Vn, [
2039
2390
  [
2040
- Pn,
2391
+ ir,
2041
2392
  1,
2042
2393
  "subjectUri"
2043
2394
  ],
2044
2395
  [
2045
- In,
2396
+ or,
2046
2397
  1,
2047
2398
  "accessGrants"
2048
2399
  ],
2049
2400
  [
2050
- Rn,
2401
+ cr,
2051
2402
  1,
2052
2403
  "principalInputValue"
2053
2404
  ],
2054
2405
  [
2055
- Bn,
2406
+ ur,
2056
2407
  1,
2057
2408
  "addAccessRoleValue"
2058
2409
  ],
2059
2410
  [
2060
- Hn,
2411
+ fr,
2061
2412
  1,
2062
2413
  "authenticatedAccessRoleValue"
2063
2414
  ],
2064
2415
  [
2065
- Wn,
2416
+ mr,
2066
2417
  1,
2067
2418
  "publicAccessRoleValue"
2068
2419
  ],
2069
2420
  [
2070
- Kn,
2421
+ gr,
2071
2422
  1,
2072
2423
  "submitting"
2073
2424
  ],
2074
2425
  [
2075
- Jn,
2426
+ vr,
2076
2427
  1,
2077
2428
  "pendingAccessGrants"
2078
2429
  ],
2079
2430
  [
2080
- Xn,
2431
+ br,
2081
2432
  1,
2082
2433
  "accessGrantDrafts"
2083
2434
  ],
2084
2435
  [
2085
- Qn,
2436
+ Sr,
2086
2437
  1,
2087
2438
  "errors"
2088
2439
  ],
2089
2440
  [
2090
- er,
2441
+ wr,
2091
2442
  1,
2092
2443
  "successfulChangesRefreshed"
2444
+ ],
2445
+ [
2446
+ Er,
2447
+ 1,
2448
+ "accessContext"
2449
+ ],
2450
+ [
2451
+ Or,
2452
+ 1,
2453
+ "accessContextLoading"
2454
+ ],
2455
+ [
2456
+ Ar,
2457
+ 1,
2458
+ "accessContextError"
2459
+ ],
2460
+ [
2461
+ Mr,
2462
+ 1,
2463
+ "advancedSharingOpen"
2464
+ ],
2465
+ [
2466
+ Pr,
2467
+ 1,
2468
+ "containerScope"
2469
+ ],
2470
+ [
2471
+ Ir,
2472
+ 1,
2473
+ "containerScopeAnalysis"
2474
+ ],
2475
+ [
2476
+ Rr,
2477
+ 1,
2478
+ "protectedTarget"
2093
2479
  ]
2094
- ], Nn, 0, void 0, u), On), Dn = class extends fr {
2480
+ ], rr, 0, void 0, p), Vn), Bn = class extends Yr {
2095
2481
  constructor() {
2096
- super(mr), or(this, "styles", gt), Mn();
2097
- }
2098
- }, or(Dn, nr, void 0), Dn)();
2099
- //#endregion
2100
- //#region src/components/access-control-modal/index.ts
2101
- var hr = mr;
2102
- //#endregion
2103
- export { mr as n, hr as t };
2482
+ super(Zr), $(this, "styles", Dt), nr();
2483
+ }
2484
+ }, $(Bn, Br, void 0), Bn)();
2485
+ // src/components/access-control-modal/index.ts
2486
+ var Qr = Zr;
2487
+ export { Zr as n, Qr as t };
2104
2488
 
2105
- //# sourceMappingURL=access-control-modal-eOv2-U27.js.map
2489
+ //# sourceMappingURL=access-control-modal-Dcg6-f4V.js.map