solid-ui 2.4.28 → 2.4.29

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 (259) hide show
  1. package/LICENSE.md +0 -0
  2. package/README.md +0 -0
  3. package/dist/670.solid-ui.min.js +0 -0
  4. package/dist/805.solid-ui.min.js +1 -1
  5. package/dist/805.solid-ui.min.js.LICENSE.txt +0 -0
  6. package/dist/805.solid-ui.min.js.map +1 -1
  7. package/dist/_2b19.solid-ui.js +0 -0
  8. package/dist/_2b19.solid-ui.js.map +1 -1
  9. package/dist/index.html +0 -0
  10. package/dist/solid-ui.js +5087 -2322
  11. package/dist/solid-ui.js.map +1 -1
  12. package/dist/solid-ui.min.js +1 -1
  13. package/dist/solid-ui.min.js.LICENSE.txt +0 -0
  14. package/dist/solid-ui.min.js.map +1 -1
  15. package/dist/vendors-node_modules_jsonld_lib_jsonld_js.solid-ui.js +0 -0
  16. package/dist/vendors-node_modules_jsonld_lib_jsonld_js.solid-ui.js.map +0 -0
  17. package/lib/acl/access-controller.d.ts +0 -0
  18. package/lib/acl/access-controller.d.ts.map +0 -0
  19. package/lib/acl/access-controller.js +3 -4
  20. package/lib/acl/access-controller.js.map +1 -1
  21. package/lib/acl/access-groups.d.ts +0 -0
  22. package/lib/acl/access-groups.d.ts.map +0 -0
  23. package/lib/acl/access-groups.js +3 -4
  24. package/lib/acl/access-groups.js.map +1 -1
  25. package/lib/acl/acl-control.d.ts +0 -0
  26. package/lib/acl/acl-control.d.ts.map +0 -0
  27. package/lib/acl/acl-control.js +2 -2
  28. package/lib/acl/acl-control.js.map +1 -1
  29. package/lib/acl/acl.d.ts +0 -0
  30. package/lib/acl/acl.d.ts.map +0 -0
  31. package/lib/acl/acl.js +2 -2
  32. package/lib/acl/acl.js.map +1 -1
  33. package/lib/acl/add-agent-buttons.d.ts +0 -0
  34. package/lib/acl/add-agent-buttons.d.ts.map +0 -0
  35. package/lib/acl/add-agent-buttons.js +3 -4
  36. package/lib/acl/add-agent-buttons.js.map +1 -1
  37. package/lib/acl/index.d.ts +0 -0
  38. package/lib/acl/index.d.ts.map +0 -0
  39. package/lib/acl/index.js +2 -4
  40. package/lib/acl/index.js.map +1 -1
  41. package/lib/acl/types.d.ts +0 -0
  42. package/lib/acl/types.d.ts.map +0 -0
  43. package/lib/acl/types.js +0 -0
  44. package/lib/acl/types.js.map +0 -0
  45. package/lib/chat/bookmarks.js +2 -2
  46. package/lib/chat/bookmarks.js.map +1 -1
  47. package/lib/chat/chatLogic.js +3 -4
  48. package/lib/chat/chatLogic.js.map +1 -1
  49. package/lib/chat/dateFolder.js +5 -8
  50. package/lib/chat/dateFolder.js.map +1 -1
  51. package/lib/chat/infinite.js +27 -5
  52. package/lib/chat/infinite.js.map +1 -1
  53. package/lib/chat/keys.d.ts +0 -0
  54. package/lib/chat/keys.d.ts.map +0 -0
  55. package/lib/chat/keys.js +2 -2
  56. package/lib/chat/keys.js.map +1 -1
  57. package/lib/chat/message.js +6 -3
  58. package/lib/chat/message.js.map +1 -1
  59. package/lib/chat/messageTools.js +2 -3
  60. package/lib/chat/messageTools.js.map +1 -1
  61. package/lib/chat/signature.d.ts +0 -0
  62. package/lib/chat/signature.d.ts.map +0 -0
  63. package/lib/chat/signature.js +4 -6
  64. package/lib/chat/signature.js.map +1 -1
  65. package/lib/chat/thread.js +2 -2
  66. package/lib/chat/thread.js.map +1 -1
  67. package/lib/create/create.d.ts +0 -0
  68. package/lib/create/create.d.ts.map +0 -0
  69. package/lib/create/create.js +2 -2
  70. package/lib/create/create.js.map +1 -1
  71. package/lib/create/index.d.ts +0 -0
  72. package/lib/create/index.d.ts.map +0 -0
  73. package/lib/create/index.js +1 -2
  74. package/lib/create/index.js.map +1 -1
  75. package/lib/create/types.d.ts +0 -0
  76. package/lib/create/types.d.ts.map +0 -0
  77. package/lib/create/types.js +0 -0
  78. package/lib/create/types.js.map +0 -0
  79. package/lib/debug.d.ts +0 -0
  80. package/lib/debug.d.ts.map +0 -0
  81. package/lib/debug.js +0 -0
  82. package/lib/debug.js.map +1 -1
  83. package/lib/folders.js +2 -2
  84. package/lib/folders.js.map +1 -1
  85. package/lib/footer/index.d.ts +0 -0
  86. package/lib/footer/index.d.ts.map +0 -0
  87. package/lib/footer/index.js +2 -2
  88. package/lib/footer/index.js.map +1 -1
  89. package/lib/header/empty-profile.d.ts +0 -0
  90. package/lib/header/empty-profile.d.ts.map +0 -0
  91. package/lib/header/empty-profile.js +1 -2
  92. package/lib/header/empty-profile.js.map +1 -1
  93. package/lib/header/index.d.ts +0 -0
  94. package/lib/header/index.d.ts.map +0 -0
  95. package/lib/header/index.js +7 -2
  96. package/lib/header/index.js.map +1 -1
  97. package/lib/iconBase.d.ts +0 -0
  98. package/lib/iconBase.d.ts.map +0 -0
  99. package/lib/iconBase.js +3 -6
  100. package/lib/iconBase.js.map +1 -1
  101. package/lib/icons/solid_logo.d.ts +0 -0
  102. package/lib/icons/solid_logo.d.ts.map +0 -0
  103. package/lib/icons/solid_logo.js +0 -0
  104. package/lib/icons/solid_logo.js.map +0 -0
  105. package/lib/index.d.ts +0 -0
  106. package/lib/index.d.ts.map +0 -0
  107. package/lib/index.js +4 -4
  108. package/lib/index.js.map +1 -1
  109. package/lib/log.d.ts +0 -0
  110. package/lib/log.d.ts.map +0 -0
  111. package/lib/log.js +4 -5
  112. package/lib/log.js.map +1 -1
  113. package/lib/login/login.d.ts +0 -0
  114. package/lib/login/login.d.ts.map +1 -1
  115. package/lib/login/login.js +56 -44
  116. package/lib/login/login.js.map +1 -1
  117. package/lib/matrix/index.d.ts +0 -0
  118. package/lib/matrix/index.d.ts.map +0 -0
  119. package/lib/matrix/index.js +1 -2
  120. package/lib/matrix/index.js.map +1 -1
  121. package/lib/matrix/matrix.d.ts +0 -0
  122. package/lib/matrix/matrix.d.ts.map +0 -0
  123. package/lib/matrix/matrix.js +2 -2
  124. package/lib/matrix/matrix.js.map +1 -1
  125. package/lib/matrix/types.d.ts +0 -0
  126. package/lib/matrix/types.d.ts.map +0 -0
  127. package/lib/matrix/types.js +0 -0
  128. package/lib/matrix/types.js.map +0 -0
  129. package/lib/media/index.d.ts +0 -0
  130. package/lib/media/index.d.ts.map +0 -0
  131. package/lib/media/index.js +1 -2
  132. package/lib/media/index.js.map +1 -1
  133. package/lib/media/media-capture.d.ts +0 -0
  134. package/lib/media/media-capture.d.ts.map +0 -0
  135. package/lib/media/media-capture.js +2 -2
  136. package/lib/media/media-capture.js.map +1 -1
  137. package/lib/messageArea.js +2 -2
  138. package/lib/messageArea.js.map +1 -1
  139. package/lib/noun_Camera_1618446_000000.js +1 -2
  140. package/lib/noun_Camera_1618446_000000.js.map +1 -1
  141. package/lib/ns.js +2 -2
  142. package/lib/ns.js.map +1 -1
  143. package/lib/pad.d.ts +0 -0
  144. package/lib/pad.d.ts.map +0 -0
  145. package/lib/pad.js +6 -3
  146. package/lib/pad.js.map +1 -1
  147. package/lib/participation.d.ts +0 -0
  148. package/lib/participation.d.ts.map +0 -0
  149. package/lib/participation.js +7 -5
  150. package/lib/participation.js.map +1 -1
  151. package/lib/preferences.js +3 -4
  152. package/lib/preferences.js.map +1 -1
  153. package/lib/signup/config-default.js +1 -2
  154. package/lib/signup/config-default.js.map +1 -1
  155. package/lib/signup/signup.js +0 -0
  156. package/lib/signup/signup.js.map +1 -1
  157. package/lib/stories/decorators.js +1 -2
  158. package/lib/stories/decorators.js.map +1 -1
  159. package/lib/style.js +1 -2
  160. package/lib/style.js.map +1 -1
  161. package/lib/style_multiSelect.js +1 -2
  162. package/lib/style_multiSelect.js.map +1 -1
  163. package/lib/table.js +2 -2
  164. package/lib/table.js.map +1 -1
  165. package/lib/tabs.d.ts +0 -0
  166. package/lib/tabs.d.ts.map +0 -0
  167. package/lib/tabs.js +1 -2
  168. package/lib/tabs.js.map +1 -1
  169. package/lib/typings.d.js +0 -0
  170. package/lib/typings.d.js.map +0 -0
  171. package/lib/utils/headerFooterHelpers.d.ts +0 -0
  172. package/lib/utils/headerFooterHelpers.d.ts.map +0 -0
  173. package/lib/utils/headerFooterHelpers.js +2 -0
  174. package/lib/utils/headerFooterHelpers.js.map +1 -1
  175. package/lib/utils/index.js +2 -2
  176. package/lib/utils/index.js.map +1 -1
  177. package/lib/utils/keyHelpers/accessData.d.ts +0 -1
  178. package/lib/utils/keyHelpers/accessData.d.ts.map +1 -1
  179. package/lib/utils/keyHelpers/accessData.js +96 -140
  180. package/lib/utils/keyHelpers/accessData.js.map +1 -1
  181. package/lib/utils/keyHelpers/acl.d.ts +0 -0
  182. package/lib/utils/keyHelpers/acl.d.ts.map +0 -0
  183. package/lib/utils/keyHelpers/acl.js +4 -6
  184. package/lib/utils/keyHelpers/acl.js.map +1 -1
  185. package/lib/utils/label.d.ts +0 -0
  186. package/lib/utils/label.d.ts.map +0 -0
  187. package/lib/utils/label.js +2 -2
  188. package/lib/utils/label.js.map +1 -1
  189. package/lib/versionInfo.d.ts +0 -0
  190. package/lib/versionInfo.d.ts.map +0 -0
  191. package/lib/versionInfo.js +15 -16
  192. package/lib/versionInfo.js.map +1 -1
  193. package/lib/widgets/buttons/iconLinks.d.ts +0 -0
  194. package/lib/widgets/buttons/iconLinks.d.ts.map +0 -0
  195. package/lib/widgets/buttons/iconLinks.js +1 -2
  196. package/lib/widgets/buttons/iconLinks.js.map +1 -1
  197. package/lib/widgets/buttons.d.ts +0 -0
  198. package/lib/widgets/buttons.d.ts.map +0 -0
  199. package/lib/widgets/buttons.js +7 -10
  200. package/lib/widgets/buttons.js.map +1 -1
  201. package/lib/widgets/dragAndDrop.js +2 -2
  202. package/lib/widgets/dragAndDrop.js.map +1 -1
  203. package/lib/widgets/error.d.ts +0 -0
  204. package/lib/widgets/error.d.ts.map +0 -0
  205. package/lib/widgets/error.js +0 -0
  206. package/lib/widgets/error.js.map +1 -1
  207. package/lib/widgets/forms/autocomplete/autocompleteBar.d.ts +0 -0
  208. package/lib/widgets/forms/autocomplete/autocompleteBar.d.ts.map +0 -0
  209. package/lib/widgets/forms/autocomplete/autocompleteBar.js +10 -3
  210. package/lib/widgets/forms/autocomplete/autocompleteBar.js.map +1 -1
  211. package/lib/widgets/forms/autocomplete/autocompleteField.d.ts +0 -0
  212. package/lib/widgets/forms/autocomplete/autocompleteField.d.ts.map +0 -0
  213. package/lib/widgets/forms/autocomplete/autocompleteField.js +2 -2
  214. package/lib/widgets/forms/autocomplete/autocompleteField.js.map +1 -1
  215. package/lib/widgets/forms/autocomplete/autocompletePicker.d.ts +0 -0
  216. package/lib/widgets/forms/autocomplete/autocompletePicker.d.ts.map +0 -0
  217. package/lib/widgets/forms/autocomplete/autocompletePicker.js +10 -5
  218. package/lib/widgets/forms/autocomplete/autocompletePicker.js.map +1 -1
  219. package/lib/widgets/forms/autocomplete/language.d.ts +0 -0
  220. package/lib/widgets/forms/autocomplete/language.d.ts.map +0 -0
  221. package/lib/widgets/forms/autocomplete/language.js +10 -6
  222. package/lib/widgets/forms/autocomplete/language.js.map +1 -1
  223. package/lib/widgets/forms/autocomplete/publicData.d.ts +0 -0
  224. package/lib/widgets/forms/autocomplete/publicData.d.ts.map +0 -0
  225. package/lib/widgets/forms/autocomplete/publicData.js +16 -24
  226. package/lib/widgets/forms/autocomplete/publicData.js.map +1 -1
  227. package/lib/widgets/forms/basic.d.ts +0 -0
  228. package/lib/widgets/forms/basic.d.ts.map +0 -0
  229. package/lib/widgets/forms/basic.js +2 -2
  230. package/lib/widgets/forms/basic.js.map +1 -1
  231. package/lib/widgets/forms/comment.d.ts +0 -0
  232. package/lib/widgets/forms/comment.d.ts.map +0 -0
  233. package/lib/widgets/forms/comment.js +2 -2
  234. package/lib/widgets/forms/comment.js.map +1 -1
  235. package/lib/widgets/forms/fieldFunction.d.ts +0 -0
  236. package/lib/widgets/forms/fieldFunction.d.ts.map +0 -0
  237. package/lib/widgets/forms/fieldFunction.js +1 -2
  238. package/lib/widgets/forms/fieldFunction.js.map +1 -1
  239. package/lib/widgets/forms/fieldParams.d.ts +0 -0
  240. package/lib/widgets/forms/fieldParams.d.ts.map +0 -0
  241. package/lib/widgets/forms/fieldParams.js +3 -4
  242. package/lib/widgets/forms/fieldParams.js.map +1 -1
  243. package/lib/widgets/forms/formStyle.d.ts +0 -0
  244. package/lib/widgets/forms/formStyle.d.ts.map +0 -0
  245. package/lib/widgets/forms/formStyle.js +2 -2
  246. package/lib/widgets/forms/formStyle.js.map +1 -1
  247. package/lib/widgets/forms.js +6 -3
  248. package/lib/widgets/forms.js.map +1 -1
  249. package/lib/widgets/index.js +2 -2
  250. package/lib/widgets/index.js.map +1 -1
  251. package/lib/widgets/multiSelect.js +3 -4
  252. package/lib/widgets/multiSelect.js.map +1 -1
  253. package/lib/widgets/peoplePicker.js +18 -12
  254. package/lib/widgets/peoplePicker.js.map +1 -1
  255. package/lib/widgets/widgetHelpers.d.ts +0 -0
  256. package/lib/widgets/widgetHelpers.d.ts.map +0 -0
  257. package/lib/widgets/widgetHelpers.js +3 -6
  258. package/lib/widgets/widgetHelpers.js.map +1 -1
  259. package/package.json +26 -26
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["_index","require","_solidLogic","_login","widgets","_interopRequireWildcard","style","_emptyProfile","_headerFooterHelpers","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","DEFAULT_HELP_MENU_ICON","icons","iconBase","DEFAUL_SOLID_ICON_URL","initHeader","_x","_x2","_x3","_initHeader","apply","arguments","_asyncToGenerator2","_regenerator","mark","_callee2","store","userMenuList","options","header","pod","wrap","_callee2$","_context2","prev","next","document","getElementById","abrupt","getPod","rebuildHeader","authSession","onLogout","onLogin","stop","_callee","user","_callee$","_context","authn","currentUser","innerHTML","t0","createBanner","t1","sent","appendChild","_x4","_x5","_x6","_x7","_x8","_createBanner","_callee3","podLink","image","userMenu","banner","leftSideOfHeader","helpMenu","_callee3$","_context3","createElement","href","uri","setAttribute","headerBannerLink","src","logo","headerBannerIcon","createUserMenu","createLoginSignUpButtons","headerBanner","headerBannerRightMenu","helpMenuList","createHelpMenu","helpMenuItems","headerUserMenuList","forEach","menuItem","menuItemType","url","createUserMenuItem","createUserMenuLink","label","target","createUserMenuButton","onclick","headerUserMenuNavigationMenuNotDisplayed","helpMenuContainer","headerBannerUserMenu","helpMenuTrigger","headerUserMenuTrigger","type","helpMenuIcon","helpIcon","headerUserMenuTriggerImg","throttledMenuToggle","throttle","event","toggleMenu","addEventListener","timer","setTimeout","clearTimeout","nav","headerUserMenuNavigationMenu","profileLoginButtonPre","headerBannerLogin","loginStatusBox","onClick","button","headerUserMenuButton","onmouseover","headerUserMenuButtonHover","onmouseout","innerText","link","headerUserMenuLink","headerUserMenuLinkHover","_x9","_x10","_x11","_createUserMenu","_callee4","fetcher","loggedInMenuList","loggedInMenu","loggedInMenuTrigger","profileImg","loggedInMenuContainer","_callee4$","_context4","load","getProfileImg","headerBannerUserMenuNotDisplayed","child","menuProfileItem","headerUserMenuListItem","profileUrl","findImage","emptyProfile","_unused","profileImage","headerUserMenuPhoto","backgroundImage","concat","trigger","menu","isExpanded","getAttribute","expand","close","toString"],"sources":["../../src/header/index.ts"],"sourcesContent":["/* global EventListenerOrEventListenerObject */\n/*\n This file was copied from mashlib/src/global/header.ts file. It is modified to\n work in solid-ui by adjusting where imported functions are found.\n */\nimport { IndexedFormula, NamedNode } from 'rdflib'\nimport { icons } from '../index'\nimport { authn, authSession } from 'solid-logic'\nimport { loginStatusBox } from '../login/login'\n// import { loginStatusBox, authSession, currentUser } from '../authn/authn'\nimport * as widgets from '../widgets'\nimport * as style from '../style'\nimport { emptyProfile } from './empty-profile'\nimport { getPod, throttle } from '../utils/headerFooterHelpers'\n\n/**\n * menu icons\n*/\nconst DEFAULT_HELP_MENU_ICON = icons.iconBase + 'noun_help.svg'\nconst DEFAUL_SOLID_ICON_URL = 'https://solidproject.org/assets/img/solid-emblem.svg'\n\nexport type MenuItemLink = {\n label: string,\n url: string,\n target?: string\n}\n\nexport type MenuItemButton = {\n label: string,\n onclick: () => void\n}\n\nexport type MenuItems = MenuItemLink | MenuItemButton\n\n/*\n HeaderOptions allow for customizing the logo and menu list. If a logo is not provided the default\n is solid. Menulist will always show a link to logout and to the users profile.\n */\nexport type HeaderOptions = {\n logo?: string,\n helpIcon?: string,\n helpMenuList?: MenuItems[]\n}\n\n/**\n * Initialize header component, the header object returned depends on whether the user is authenticated.\n * @param store the data store\n * @param userMenuList a list of menu items when the user is logged in\n * @param options allow the header to be customized with a personalized logo, help icon and a help menu list of links or buttons.\n * @returns a header for an authenticated user with menu items given or a login screen\n */\nexport async function initHeader (store: IndexedFormula, userMenuList: MenuItems[], options?: HeaderOptions) {\n const header = document.getElementById('PageHeader')\n if (!header) {\n return\n }\n\n const pod = getPod()\n rebuildHeader(header, store, pod, userMenuList, options)()\n authSession.onLogout(rebuildHeader(header, store, pod, userMenuList, options))\n authSession.onLogin(rebuildHeader(header, store, pod, userMenuList, options))\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function rebuildHeader (header: HTMLElement, store: IndexedFormula, pod: NamedNode, userMenuList: MenuItems[], options?: HeaderOptions) {\n return async () => {\n const user = authn.currentUser()\n header.innerHTML = ''\n header.appendChild(await createBanner(store, pod, user, userMenuList, options))\n }\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport async function createBanner (store: IndexedFormula, pod: NamedNode, user: NamedNode | null, userMenuList: MenuItems[], options?: HeaderOptions): Promise<HTMLElement> {\n const podLink = document.createElement('a')\n podLink.href = pod.uri\n podLink.setAttribute('style', style.headerBannerLink)\n const image = document.createElement('img')\n if (options) {\n image.src = options.logo ? options.logo : DEFAUL_SOLID_ICON_URL\n }\n image.setAttribute('style', style.headerBannerIcon)\n podLink.appendChild(image)\n\n const userMenu = user\n ? await createUserMenu(store, user, userMenuList)\n : createLoginSignUpButtons()\n\n const banner = document.createElement('div')\n banner.setAttribute('style', style.headerBanner)\n banner.appendChild(podLink)\n\n const leftSideOfHeader = document.createElement('div')\n leftSideOfHeader.setAttribute('style', style.headerBannerRightMenu)\n leftSideOfHeader.appendChild(userMenu)\n\n if (options && options.helpMenuList) {\n const helpMenu = createHelpMenu(options, options.helpMenuList)\n leftSideOfHeader.appendChild(helpMenu as HTMLDivElement)\n }\n\n banner.appendChild(leftSideOfHeader)\n\n return banner\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createHelpMenu (options: HeaderOptions, helpMenuItems: MenuItems[]) {\n if (!helpMenuItems) return\n const helpMenuList = document.createElement('ul')\n helpMenuList.setAttribute('style', style.headerUserMenuList)\n helpMenuItems.forEach(function (menuItem) {\n const menuItemType: string = (menuItem as MenuItemLink).url ? 'url' : 'onclick'\n if (menuItemType === 'url') {\n helpMenuList.appendChild(createUserMenuItem(createUserMenuLink(menuItem.label, (menuItem as MenuItemLink).url, (menuItem as MenuItemLink).target)))\n } else {\n helpMenuList.appendChild(createUserMenuItem(createUserMenuButton(menuItem.label, (menuItem as MenuItemButton).onclick)))\n }\n })\n\n const helpMenu = document.createElement('nav')\n\n helpMenu.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n helpMenu.setAttribute('aria-hidden', 'true')\n helpMenu.setAttribute('id', 'helperNav')\n helpMenu.appendChild(helpMenuList)\n\n const helpMenuContainer = document.createElement('div')\n helpMenuContainer.setAttribute('style', style.headerBannerUserMenu)\n helpMenuContainer.appendChild(helpMenu)\n\n const helpMenuTrigger = document.createElement('button')\n helpMenuTrigger.setAttribute('style', style.headerUserMenuTrigger)\n helpMenuTrigger.type = 'button'\n\n const helpMenuIcon = document.createElement('img')\n helpMenuIcon.src = (options && options.helpIcon) ? options.helpIcon : icons.iconBase + DEFAULT_HELP_MENU_ICON\n helpMenuIcon.setAttribute('style', style.headerUserMenuTriggerImg)\n helpMenuContainer.appendChild(helpMenuTrigger)\n helpMenuTrigger.appendChild(helpMenuIcon)\n\n const throttledMenuToggle = throttle((event: Event) => toggleMenu(event, helpMenuTrigger, helpMenu), 50)\n helpMenuTrigger.addEventListener('click', throttledMenuToggle)\n let timer = setTimeout(() => null, 0)\n helpMenuContainer.addEventListener('mouseover', event => {\n clearTimeout(timer)\n throttledMenuToggle(event)\n const nav = document.getElementById('helperNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenu)\n })\n helpMenuContainer.addEventListener('mouseout', event => {\n timer = setTimeout(() => throttledMenuToggle(event), 200)\n const nav = document.getElementById('helperNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n })\n\n return helpMenuContainer\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createLoginSignUpButtons () {\n const profileLoginButtonPre = document.createElement('div')\n profileLoginButtonPre.setAttribute('style', style.headerBannerLogin)\n profileLoginButtonPre.appendChild(loginStatusBox(document, null, {}))\n return profileLoginButtonPre\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createUserMenuButton (label: string, onClick: EventListenerOrEventListenerObject): HTMLElement {\n const button = document.createElement('button')\n button.setAttribute('style', style.headerUserMenuButton)\n button.onmouseover = function () {\n button.setAttribute('style', style.headerUserMenuButtonHover)\n }\n button.onmouseout = function () {\n button.setAttribute('style', style.headerUserMenuButton)\n }\n button.addEventListener('click', onClick)\n button.innerText = label\n return button\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createUserMenuLink (label: string, href: string, target?: string): HTMLElement {\n const link = document.createElement('a')\n link.setAttribute('style', style.headerUserMenuLink)\n link.onmouseover = function () {\n link.setAttribute('style', style.headerUserMenuLinkHover)\n }\n link.onmouseout = function () {\n link.setAttribute('style', style.headerUserMenuLink)\n }\n link.href = href\n link.innerText = label\n if (target) link.target = target\n return link\n}\n\n/**\n * @ignore exporting this only for the unit test\n */\nexport async function createUserMenu (store: IndexedFormula, user: NamedNode, userMenuList: MenuItems[]): Promise<HTMLElement> {\n const fetcher = (<any>store).fetcher\n if (fetcher) {\n // Making sure that Profile is loaded before building menu\n await fetcher.load(user)\n }\n\n const loggedInMenuList = document.createElement('ul')\n loggedInMenuList.setAttribute('style', style.headerUserMenuList)\n if (userMenuList) {\n userMenuList.forEach(function (menuItem) {\n const menuItemType: string = (menuItem as MenuItemLink).url ? 'url' : 'onclick'\n if (menuItemType === 'url') {\n loggedInMenuList.appendChild(createUserMenuItem(createUserMenuLink(menuItem.label, (menuItem as MenuItemLink).url, (menuItem as MenuItemLink).target)))\n } else {\n loggedInMenuList.appendChild(createUserMenuItem(createUserMenuButton(menuItem.label, (menuItem as MenuItemButton).onclick)))\n }\n })\n }\n const loggedInMenu = document.createElement('nav')\n\n loggedInMenu.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n loggedInMenu.setAttribute('aria-hidden', 'true')\n loggedInMenu.setAttribute('id', 'loggedInNav')\n loggedInMenu.appendChild(loggedInMenuList)\n\n const loggedInMenuTrigger = document.createElement('button')\n loggedInMenuTrigger.setAttribute('style', style.headerUserMenuTrigger)\n loggedInMenuTrigger.type = 'button'\n const profileImg = getProfileImg(store, user)\n if (typeof profileImg === 'string') {\n loggedInMenuTrigger.innerHTML = profileImg\n } else {\n loggedInMenuTrigger.appendChild(profileImg)\n }\n\n const loggedInMenuContainer = document.createElement('div')\n loggedInMenuContainer.setAttribute('style', style.headerBannerUserMenuNotDisplayed)\n loggedInMenuContainer.appendChild(loggedInMenuTrigger)\n loggedInMenuContainer.appendChild(loggedInMenu)\n\n const throttledMenuToggle = throttle((event: Event) => toggleMenu(event, loggedInMenuTrigger, loggedInMenu), 50)\n loggedInMenuTrigger.addEventListener('click', throttledMenuToggle)\n let timer = setTimeout(() => null, 0)\n loggedInMenuContainer.addEventListener('mouseover', event => {\n clearTimeout(timer)\n throttledMenuToggle(event)\n const nav = document.getElementById('loggedInNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenu)\n })\n loggedInMenuContainer.addEventListener('mouseout', event => {\n timer = setTimeout(() => throttledMenuToggle(event), 200)\n const nav = document.getElementById('loggedInNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n })\n\n return loggedInMenuContainer\n}\n\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createUserMenuItem (child: HTMLElement): HTMLElement {\n const menuProfileItem = document.createElement('li')\n menuProfileItem.setAttribute('style', style.headerUserMenuListItem)\n menuProfileItem.appendChild(child)\n return menuProfileItem\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function getProfileImg (store: IndexedFormula, user: NamedNode): string | HTMLElement {\n let profileUrl = null\n try {\n profileUrl = widgets.findImage(user)\n if (!profileUrl) {\n return emptyProfile\n }\n } catch {\n return emptyProfile\n }\n\n const profileImage = document.createElement('div')\n profileImage.setAttribute('style', style.headerUserMenuPhoto)\n profileImage.style.backgroundImage = `url(${profileUrl})`\n return profileImage\n}\n\n/**\n * @internal\n */\nfunction toggleMenu (event: Event, trigger: HTMLButtonElement, menu: HTMLElement): void {\n const isExpanded = trigger.getAttribute('aria-expanded') === 'true'\n const expand = event.type === 'mouseover'\n const close = event.type === 'mouseout'\n if ((isExpanded && expand) || (!isExpanded && close)) {\n return\n }\n trigger.setAttribute('aria-expanded', (!isExpanded).toString())\n menu.setAttribute('aria-hidden', isExpanded.toString())\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAMA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,WAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AAEA,IAAAG,OAAA,GAAAC,uBAAA,CAAAJ,OAAA;AACA,IAAAK,KAAA,GAAAD,uBAAA,CAAAJ,OAAA;AACA,IAAAM,aAAA,GAAAN,OAAA;AACA,IAAAO,oBAAA,GAAAP,OAAA;AAA+D,SAAAQ,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,yBAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAL,wB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ACF,CAAC,CAAC,OAAAC,OAAA,EAAM;IACN,OAAOD,0BAAY;EACrB;EAEA,IAAME,YAAY,GAAGrH,QAAQ,CAACoC,aAAa,CAAC,KAAK,CAAC;EAClDiF,YAAY,CAAC9E,YAAY,CAAC,OAAO,EAAEzF,KAAK,CAACwK,mBAAmB,CAAC;EAC7DD,YAAY,CAACvK,KAAK,CAACyK,eAAe,UAAAC,MAAA,CAAUP,UAAU,MAAG;EACzD,OAAOI,YAAY;AACrB;;AAEA;AACA;AACA;AACA,SAAS3C,UAAUA,CAAED,KAAY,EAAEgD,OAA0B,EAAEC,IAAiB,EAAQ;EACtF,IAAMC,UAAU,GAAGF,OAAO,CAACG,YAAY,CAAC,eAAe,CAAC,KAAK,MAAM;EACnE,IAAMC,MAAM,GAAGpD,KAAK,CAACN,IAAI,KAAK,WAAW;EACzC,IAAM2D,KAAK,GAAGrD,KAAK,CAACN,IAAI,KAAK,UAAU;EACvC,IAAKwD,UAAU,IAAIE,MAAM,IAAM,CAACF,UAAU,IAAIG,KAAM,EAAE;IACpD;EACF;EACAL,OAAO,CAAClF,YAAY,CAAC,eAAe,EAAE,CAAC,CAACoF,UAAU,EAAEI,QAAQ,EAAE,CAAC;EAC/DL,IAAI,CAACnF,YAAY,CAAC,aAAa,EAAEoF,UAAU,CAACI,QAAQ,EAAE,CAAC;AACzD"}
1
+ {"version":3,"file":"index.js","names":["_index","require","_solidLogic","_login","widgets","_interopRequireWildcard","style","_emptyProfile","_headerFooterHelpers","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","_typeof","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","prototype","hasOwnProperty","call","i","set","DEFAULT_HELP_MENU_ICON","icons","iconBase","DEFAUL_SOLID_ICON_URL","initHeader","_x","_x2","_x3","_initHeader","apply","arguments","_asyncToGenerator2","_regenerator","mark","_callee2","store","userMenuList","options","header","pod","wrap","_callee2$","_context2","prev","next","document","getElementById","abrupt","getPod","rebuildHeader","authSession","onLogout","onLogin","stop","_callee","user","_callee$","_context","authn","currentUser","innerHTML","t0","createBanner","t1","sent","appendChild","_x4","_x5","_x6","_x7","_x8","_createBanner","_callee3","podLink","image","userMenu","banner","leftSideOfHeader","helpMenu","_callee3$","_context3","createElement","href","uri","setAttribute","headerBannerLink","src","logo","headerBannerIcon","createUserMenu","createLoginSignUpButtons","headerBanner","headerBannerRightMenu","helpMenuList","createHelpMenu","helpMenuItems","headerUserMenuList","forEach","menuItem","menuItemType","url","createUserMenuItem","createUserMenuLink","label","target","createUserMenuButton","onclick","headerUserMenuNavigationMenuNotDisplayed","helpMenuContainer","headerBannerUserMenu","helpMenuTrigger","headerUserMenuTrigger","type","helpMenuIcon","helpIcon","headerUserMenuTriggerImg","throttledMenuToggle","throttle","event","toggleMenu","addEventListener","timer","setTimeout","clearTimeout","nav","headerUserMenuNavigationMenu","profileLoginButtonPre","headerBannerLogin","loginStatusBox","onClick","button","headerUserMenuButton","onmouseover","headerUserMenuButtonHover","onmouseout","innerText","link","headerUserMenuLink","headerUserMenuLinkHover","_x9","_x10","_x11","_createUserMenu","_callee4","fetcher","loggedInMenuList","loggedInMenu","loggedInMenuTrigger","profileImg","loggedInMenuContainer","_callee4$","_context4","load","getProfileImg","headerBannerUserMenuNotDisplayed","child","menuProfileItem","headerUserMenuListItem","profileUrl","findImage","emptyProfile","_unused","profileImage","headerUserMenuPhoto","backgroundImage","concat","trigger","menu","isExpanded","getAttribute","expand","close","toString"],"sources":["../../src/header/index.ts"],"sourcesContent":["/* global EventListenerOrEventListenerObject */\n/*\n This file was copied from mashlib/src/global/header.ts file. It is modified to\n work in solid-ui by adjusting where imported functions are found.\n */\nimport { IndexedFormula, NamedNode } from 'rdflib'\nimport { icons } from '../index'\nimport { authn, authSession } from 'solid-logic'\nimport { loginStatusBox } from '../login/login'\n// import { loginStatusBox, authSession, currentUser } from '../authn/authn'\nimport * as widgets from '../widgets'\nimport * as style from '../style'\nimport { emptyProfile } from './empty-profile'\nimport { getPod, throttle } from '../utils/headerFooterHelpers'\n\n/**\n * menu icons\n*/\nconst DEFAULT_HELP_MENU_ICON = icons.iconBase + 'noun_help.svg'\nconst DEFAUL_SOLID_ICON_URL = 'https://solidproject.org/assets/img/solid-emblem.svg'\n\nexport type MenuItemLink = {\n label: string,\n url: string,\n target?: string\n}\n\nexport type MenuItemButton = {\n label: string,\n onclick: () => void\n}\n\nexport type MenuItems = MenuItemLink | MenuItemButton\n\n/*\n HeaderOptions allow for customizing the logo and menu list. If a logo is not provided the default\n is solid. Menulist will always show a link to logout and to the users profile.\n */\nexport type HeaderOptions = {\n logo?: string,\n helpIcon?: string,\n helpMenuList?: MenuItems[]\n}\n\n/**\n * Initialize header component, the header object returned depends on whether the user is authenticated.\n * @param store the data store\n * @param userMenuList a list of menu items when the user is logged in\n * @param options allow the header to be customized with a personalized logo, help icon and a help menu list of links or buttons.\n * @returns a header for an authenticated user with menu items given or a login screen\n */\nexport async function initHeader (store: IndexedFormula, userMenuList: MenuItems[], options?: HeaderOptions) {\n const header = document.getElementById('PageHeader')\n if (!header) {\n return\n }\n\n const pod = getPod()\n rebuildHeader(header, store, pod, userMenuList, options)()\n authSession.onLogout(rebuildHeader(header, store, pod, userMenuList, options))\n authSession.onLogin(rebuildHeader(header, store, pod, userMenuList, options))\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function rebuildHeader (header: HTMLElement, store: IndexedFormula, pod: NamedNode, userMenuList: MenuItems[], options?: HeaderOptions) {\n return async () => {\n const user = authn.currentUser()\n header.innerHTML = ''\n header.appendChild(await createBanner(store, pod, user, userMenuList, options))\n }\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport async function createBanner (store: IndexedFormula, pod: NamedNode, user: NamedNode | null, userMenuList: MenuItems[], options?: HeaderOptions): Promise<HTMLElement> {\n const podLink = document.createElement('a')\n podLink.href = pod.uri\n podLink.setAttribute('style', style.headerBannerLink)\n const image = document.createElement('img')\n if (options) {\n image.src = options.logo ? options.logo : DEFAUL_SOLID_ICON_URL\n }\n image.setAttribute('style', style.headerBannerIcon)\n podLink.appendChild(image)\n\n const userMenu = user\n ? await createUserMenu(store, user, userMenuList)\n : createLoginSignUpButtons()\n\n const banner = document.createElement('div')\n banner.setAttribute('style', style.headerBanner)\n banner.appendChild(podLink)\n\n const leftSideOfHeader = document.createElement('div')\n leftSideOfHeader.setAttribute('style', style.headerBannerRightMenu)\n leftSideOfHeader.appendChild(userMenu)\n\n if (options && options.helpMenuList) {\n const helpMenu = createHelpMenu(options, options.helpMenuList)\n leftSideOfHeader.appendChild(helpMenu as HTMLDivElement)\n }\n\n banner.appendChild(leftSideOfHeader)\n\n return banner\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createHelpMenu (options: HeaderOptions, helpMenuItems: MenuItems[]) {\n if (!helpMenuItems) return\n const helpMenuList = document.createElement('ul')\n helpMenuList.setAttribute('style', style.headerUserMenuList)\n helpMenuItems.forEach(function (menuItem) {\n const menuItemType: string = (menuItem as MenuItemLink).url ? 'url' : 'onclick'\n if (menuItemType === 'url') {\n helpMenuList.appendChild(createUserMenuItem(createUserMenuLink(menuItem.label, (menuItem as MenuItemLink).url, (menuItem as MenuItemLink).target)))\n } else {\n helpMenuList.appendChild(createUserMenuItem(createUserMenuButton(menuItem.label, (menuItem as MenuItemButton).onclick)))\n }\n })\n\n const helpMenu = document.createElement('nav')\n\n helpMenu.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n helpMenu.setAttribute('aria-hidden', 'true')\n helpMenu.setAttribute('id', 'helperNav')\n helpMenu.appendChild(helpMenuList)\n\n const helpMenuContainer = document.createElement('div')\n helpMenuContainer.setAttribute('style', style.headerBannerUserMenu)\n helpMenuContainer.appendChild(helpMenu)\n\n const helpMenuTrigger = document.createElement('button')\n helpMenuTrigger.setAttribute('style', style.headerUserMenuTrigger)\n helpMenuTrigger.type = 'button'\n\n const helpMenuIcon = document.createElement('img')\n helpMenuIcon.src = (options && options.helpIcon) ? options.helpIcon : icons.iconBase + DEFAULT_HELP_MENU_ICON\n helpMenuIcon.setAttribute('style', style.headerUserMenuTriggerImg)\n helpMenuContainer.appendChild(helpMenuTrigger)\n helpMenuTrigger.appendChild(helpMenuIcon)\n\n const throttledMenuToggle = throttle((event: Event) => toggleMenu(event, helpMenuTrigger, helpMenu), 50)\n helpMenuTrigger.addEventListener('click', throttledMenuToggle)\n let timer = setTimeout(() => null, 0)\n helpMenuContainer.addEventListener('mouseover', event => {\n clearTimeout(timer)\n throttledMenuToggle(event)\n const nav = document.getElementById('helperNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenu)\n })\n helpMenuContainer.addEventListener('mouseout', event => {\n timer = setTimeout(() => throttledMenuToggle(event), 200)\n const nav = document.getElementById('helperNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n })\n\n return helpMenuContainer\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createLoginSignUpButtons () {\n const profileLoginButtonPre = document.createElement('div')\n profileLoginButtonPre.setAttribute('style', style.headerBannerLogin)\n profileLoginButtonPre.appendChild(loginStatusBox(document, null, {}))\n return profileLoginButtonPre\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createUserMenuButton (label: string, onClick: EventListenerOrEventListenerObject): HTMLElement {\n const button = document.createElement('button')\n button.setAttribute('style', style.headerUserMenuButton)\n button.onmouseover = function () {\n button.setAttribute('style', style.headerUserMenuButtonHover)\n }\n button.onmouseout = function () {\n button.setAttribute('style', style.headerUserMenuButton)\n }\n button.addEventListener('click', onClick)\n button.innerText = label\n return button\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createUserMenuLink (label: string, href: string, target?: string): HTMLElement {\n const link = document.createElement('a')\n link.setAttribute('style', style.headerUserMenuLink)\n link.onmouseover = function () {\n link.setAttribute('style', style.headerUserMenuLinkHover)\n }\n link.onmouseout = function () {\n link.setAttribute('style', style.headerUserMenuLink)\n }\n link.href = href\n link.innerText = label\n if (target) link.target = target\n return link\n}\n\n/**\n * @ignore exporting this only for the unit test\n */\nexport async function createUserMenu (store: IndexedFormula, user: NamedNode, userMenuList: MenuItems[]): Promise<HTMLElement> {\n const fetcher = (<any>store).fetcher\n if (fetcher) {\n // Making sure that Profile is loaded before building menu\n await fetcher.load(user)\n }\n\n const loggedInMenuList = document.createElement('ul')\n loggedInMenuList.setAttribute('style', style.headerUserMenuList)\n if (userMenuList) {\n userMenuList.forEach(function (menuItem) {\n const menuItemType: string = (menuItem as MenuItemLink).url ? 'url' : 'onclick'\n if (menuItemType === 'url') {\n loggedInMenuList.appendChild(createUserMenuItem(createUserMenuLink(menuItem.label, (menuItem as MenuItemLink).url, (menuItem as MenuItemLink).target)))\n } else {\n loggedInMenuList.appendChild(createUserMenuItem(createUserMenuButton(menuItem.label, (menuItem as MenuItemButton).onclick)))\n }\n })\n }\n const loggedInMenu = document.createElement('nav')\n\n loggedInMenu.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n loggedInMenu.setAttribute('aria-hidden', 'true')\n loggedInMenu.setAttribute('id', 'loggedInNav')\n loggedInMenu.appendChild(loggedInMenuList)\n\n const loggedInMenuTrigger = document.createElement('button')\n loggedInMenuTrigger.setAttribute('style', style.headerUserMenuTrigger)\n loggedInMenuTrigger.type = 'button'\n const profileImg = getProfileImg(store, user)\n if (typeof profileImg === 'string') {\n loggedInMenuTrigger.innerHTML = profileImg\n } else {\n loggedInMenuTrigger.appendChild(profileImg)\n }\n\n const loggedInMenuContainer = document.createElement('div')\n loggedInMenuContainer.setAttribute('style', style.headerBannerUserMenuNotDisplayed)\n loggedInMenuContainer.appendChild(loggedInMenuTrigger)\n loggedInMenuContainer.appendChild(loggedInMenu)\n\n const throttledMenuToggle = throttle((event: Event) => toggleMenu(event, loggedInMenuTrigger, loggedInMenu), 50)\n loggedInMenuTrigger.addEventListener('click', throttledMenuToggle)\n let timer = setTimeout(() => null, 0)\n loggedInMenuContainer.addEventListener('mouseover', event => {\n clearTimeout(timer)\n throttledMenuToggle(event)\n const nav = document.getElementById('loggedInNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenu)\n })\n loggedInMenuContainer.addEventListener('mouseout', event => {\n timer = setTimeout(() => throttledMenuToggle(event), 200)\n const nav = document.getElementById('loggedInNav')\n nav?.setAttribute('style', style.headerUserMenuNavigationMenuNotDisplayed)\n })\n\n return loggedInMenuContainer\n}\n\n/**\n * @ignore exporting this only for the unit test\n */\nexport function createUserMenuItem (child: HTMLElement): HTMLElement {\n const menuProfileItem = document.createElement('li')\n menuProfileItem.setAttribute('style', style.headerUserMenuListItem)\n menuProfileItem.appendChild(child)\n return menuProfileItem\n}\n/**\n * @ignore exporting this only for the unit test\n */\nexport function getProfileImg (store: IndexedFormula, user: NamedNode): string | HTMLElement {\n let profileUrl = null\n try {\n profileUrl = widgets.findImage(user)\n if (!profileUrl) {\n return emptyProfile\n }\n } catch {\n return emptyProfile\n }\n\n const profileImage = document.createElement('div')\n profileImage.setAttribute('style', style.headerUserMenuPhoto)\n profileImage.style.backgroundImage = `url(${profileUrl})`\n return profileImage\n}\n\n/**\n * @internal\n */\nfunction toggleMenu (event: Event, trigger: HTMLButtonElement, menu: HTMLElement): void {\n const isExpanded = trigger.getAttribute('aria-expanded') === 'true'\n const expand = event.type === 'mouseover'\n const close = event.type === 'mouseout'\n if ((isExpanded && expand) || (!isExpanded && close)) {\n return\n }\n trigger.setAttribute('aria-expanded', (!isExpanded).toString())\n menu.setAttribute('aria-hidden', isExpanded.toString())\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAMA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,WAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AAEA,IAAAG,OAAA,GAAAC,uBAAA,CAAAJ,OAAA;AACA,IAAAK,KAAA,GAAAD,uBAAA,CAAAJ,OAAA;AACA,IAAAM,aAAA,GAAAN,OAAA;AACA,IAAAO,oBAAA,GAAAP,OAAA;AAA+D,SAAAQ,yBAAAC,CAAA,6BAAAC,OAAA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H,KAAqB,EAAEoB,IAAe,EAAwB;EAC3F,IAAIuG,UAAU,GAAG,IAAI;EACrB,IAAI;IACFA,UAAU,GAAGpK,OAAO,CAACqK,SAAS,CAACxG,IAAI,CAAC;IACpC,IAAI,CAACuG,UAAU,EAAE;MACf,OAAOE,0BAAY;IACrB;EACF,CAAC,CAAC,OAAAC,OAAA,EAAM;IACN,OAAOD,0BAAY;EACrB;EAEA,IAAME,YAAY,GAAGrH,QAAQ,CAACoC,aAAa,CAAC,KAAK,CAAC;EAClDiF,YAAY,CAAC9E,YAAY,CAAC,OAAO,EAAExF,KAAK,CAACuK,mBAAmB,CAAC;EAC7DD,YAAY,CAACtK,KAAK,CAACwK,eAAe,UAAAC,MAAA,CAAUP,UAAU,MAAG;EACzD,OAAOI,YAAY;AACrB;;AAEA;AACA;AACA;AACA,SAAS3C,UAAUA,CAAED,KAAY,EAAEgD,OAA0B,EAAEC,IAAiB,EAAQ;EACtF,IAAMC,UAAU,GAAGF,OAAO,CAACG,YAAY,CAAC,eAAe,CAAC,KAAK,MAAM;EACnE,IAAMC,MAAM,GAAGpD,KAAK,CAACN,IAAI,KAAK,WAAW;EACzC,IAAM2D,KAAK,GAAGrD,KAAK,CAACN,IAAI,KAAK,UAAU;EACvC,IAAKwD,UAAU,IAAIE,MAAM,IAAM,CAACF,UAAU,IAAIG,KAAM,EAAE;IACpD;EACF;EACAL,OAAO,CAAClF,YAAY,CAAC,eAAe,EAAE,CAAC,CAACoF,UAAU,EAAEI,QAAQ,CAAC,CAAC,CAAC;EAC/DL,IAAI,CAACnF,YAAY,CAAC,aAAa,EAAEoF,UAAU,CAACI,QAAQ,CAAC,CAAC,CAAC;AACzD"}
package/lib/iconBase.d.ts CHANGED
File without changes
File without changes
package/lib/iconBase.js CHANGED
@@ -24,7 +24,7 @@ var _debug = require("./debug");
24
24
  // Do not export. Always us this module to find the icons, as they vary
25
25
  var iconsOnGithub = 'https://solidos.github.io/solid-ui/src'; // changed org 2022-05
26
26
 
27
- var icons = module.scriptURI // Firefox extension
27
+ var icons = exports.icons = module.scriptURI // Firefox extension
28
28
  ? {
29
29
  iconBase: module.scriptURI.slice(0, module.scriptURI.lastIndexOf('/')) + '/icons/',
30
30
  originalIconBase: module.scriptURI.slice(0, module.scriptURI.lastIndexOf('/')) + '/originalIcons/'
@@ -37,12 +37,9 @@ var icons = module.scriptURI // Firefox extension
37
37
  iconBase: iconsOnGithub + '/icons/',
38
38
  originalIconBase: iconsOnGithub + '/originalIcons/'
39
39
  };
40
- exports.icons = icons;
41
40
  (0, _debug.log)(' icons.iconBase is set to : ' + icons.iconBase);
42
41
 
43
42
  // allow tests etc named-import this directly from this module
44
- var iconBase = icons.iconBase;
45
- exports.iconBase = iconBase;
46
- var originalIconBase = icons.originalIconBase;
47
- exports.originalIconBase = originalIconBase;
43
+ var iconBase = exports.iconBase = icons.iconBase;
44
+ var originalIconBase = exports.originalIconBase = icons.originalIconBase;
48
45
  //# sourceMappingURL=iconBase.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"iconBase.js","names":["_debug","require","iconsOnGithub","icons","module","scriptURI","iconBase","slice","lastIndexOf","originalIconBase","$SolidTestEnvironment","exports","log"],"sources":["../src/iconBase.ts"],"sourcesContent":["// Works in FF extension - what about browserify??\n// 2021-04-08 Convert to TS\n\n/* The Firefox case is left for historical record, as we don't currenly\n * have a FF extension for mashlib, but we could. This is sthepoint to\n * hack the place it can find its icons internally\n *\n * The $SolidTestEnvironment is important and is used for\n * example when testing on localhost to specify a place the icons be found\n * in your test set up.\n *\n * You can also use it if you want to just run a mashlib whhich takes its\n * icons seved by other than github.\n */\n/* eslint-disable multiline-ternary */\n\nimport { log } from './debug'\n\ndeclare let $SolidTestEnvironment\n\n// Do not export. Always us this module to find the icons, as they vary\nconst iconsOnGithub = 'https://solidos.github.io/solid-ui/src' // changed org 2022-05\n\nexport const icons = (module as any).scriptURI // Firefox extension\n ? {\n iconBase:\n (module as any).scriptURI.slice(0, (module as any).scriptURI.lastIndexOf('/')) + '/icons/',\n originalIconBase:\n (module as any).scriptURI.slice(0, (module as any).scriptURI.lastIndexOf('/')) +\n '/originalIcons/'\n }\n : typeof $SolidTestEnvironment !== 'undefined' && $SolidTestEnvironment.iconBase // Test environemnt\n ? {\n iconBase: $SolidTestEnvironment.iconBase,\n originalIconBase: $SolidTestEnvironment.originalIconBase\n }\n : {\n // Normal case:\n iconBase: iconsOnGithub + '/icons/',\n originalIconBase: iconsOnGithub + '/originalIcons/'\n }\n\nlog(' icons.iconBase is set to : ' + icons.iconBase)\n\n// allow tests etc named-import this directly from this module\nexport const iconBase = icons.iconBase\nexport const originalIconBase = icons.originalIconBase\n"],"mappings":";;;;;;AAgBA,IAAAA,MAAA,GAAAC,OAAA;AAhBA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAMA;AACA,IAAMC,aAAa,GAAG,wCAAwC,EAAC;;AAExD,IAAMC,KAAK,GAAIC,MAAM,CAASC,SAAS,CAAC;AAAA,EAC3C;EACEC,QAAQ,EACLF,MAAM,CAASC,SAAS,CAACE,KAAK,CAAC,CAAC,EAAGH,MAAM,CAASC,SAAS,CAACG,WAAW,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS;EAC5FC,gBAAgB,EACbL,MAAM,CAASC,SAAS,CAACE,KAAK,CAAC,CAAC,EAAGH,MAAM,CAASC,SAAS,CAACG,WAAW,CAAC,GAAG,CAAC,CAAC,GAC9E;AACJ,CAAC,GACD,OAAOE,qBAAqB,KAAK,WAAW,IAAIA,qBAAqB,CAACJ,QAAQ,CAAC;AAAA,EAC7E;EACEA,QAAQ,EAAEI,qBAAqB,CAACJ,QAAQ;EACxCG,gBAAgB,EAAEC,qBAAqB,CAACD;AAC1C,CAAC,GACD;EACA;EACEH,QAAQ,EAAEJ,aAAa,GAAG,SAAS;EACnCO,gBAAgB,EAAEP,aAAa,GAAG;AACpC,CAAC;AAAAS,OAAA,CAAAR,KAAA,GAAAA,KAAA;AAEP,IAAAS,UAAG,EAAC,gCAAgC,GAAGT,KAAK,CAACG,QAAQ,CAAC;;AAEtD;AACO,IAAMA,QAAQ,GAAGH,KAAK,CAACG,QAAQ;AAAAK,OAAA,CAAAL,QAAA,GAAAA,QAAA;AAC/B,IAAMG,gBAAgB,GAAGN,KAAK,CAACM,gBAAgB;AAAAE,OAAA,CAAAF,gBAAA,GAAAA,gBAAA"}
1
+ {"version":3,"file":"iconBase.js","names":["_debug","require","iconsOnGithub","icons","exports","module","scriptURI","iconBase","slice","lastIndexOf","originalIconBase","$SolidTestEnvironment","log"],"sources":["../src/iconBase.ts"],"sourcesContent":["// Works in FF extension - what about browserify??\n// 2021-04-08 Convert to TS\n\n/* The Firefox case is left for historical record, as we don't currenly\n * have a FF extension for mashlib, but we could. This is sthepoint to\n * hack the place it can find its icons internally\n *\n * The $SolidTestEnvironment is important and is used for\n * example when testing on localhost to specify a place the icons be found\n * in your test set up.\n *\n * You can also use it if you want to just run a mashlib whhich takes its\n * icons seved by other than github.\n */\n/* eslint-disable multiline-ternary */\n\nimport { log } from './debug'\n\ndeclare let $SolidTestEnvironment\n\n// Do not export. Always us this module to find the icons, as they vary\nconst iconsOnGithub = 'https://solidos.github.io/solid-ui/src' // changed org 2022-05\n\nexport const icons = (module as any).scriptURI // Firefox extension\n ? {\n iconBase:\n (module as any).scriptURI.slice(0, (module as any).scriptURI.lastIndexOf('/')) + '/icons/',\n originalIconBase:\n (module as any).scriptURI.slice(0, (module as any).scriptURI.lastIndexOf('/')) +\n '/originalIcons/'\n }\n : typeof $SolidTestEnvironment !== 'undefined' && $SolidTestEnvironment.iconBase // Test environemnt\n ? {\n iconBase: $SolidTestEnvironment.iconBase,\n originalIconBase: $SolidTestEnvironment.originalIconBase\n }\n : {\n // Normal case:\n iconBase: iconsOnGithub + '/icons/',\n originalIconBase: iconsOnGithub + '/originalIcons/'\n }\n\nlog(' icons.iconBase is set to : ' + icons.iconBase)\n\n// allow tests etc named-import this directly from this module\nexport const iconBase = icons.iconBase\nexport const originalIconBase = icons.originalIconBase\n"],"mappings":";;;;;;AAgBA,IAAAA,MAAA,GAAAC,OAAA;AAhBA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAMA;AACA,IAAMC,aAAa,GAAG,wCAAwC,EAAC;;AAExD,IAAMC,KAAK,GAAAC,OAAA,CAAAD,KAAA,GAAIE,MAAM,CAASC,SAAS,CAAC;AAAA,EAC3C;EACEC,QAAQ,EACLF,MAAM,CAASC,SAAS,CAACE,KAAK,CAAC,CAAC,EAAGH,MAAM,CAASC,SAAS,CAACG,WAAW,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS;EAC5FC,gBAAgB,EACbL,MAAM,CAASC,SAAS,CAACE,KAAK,CAAC,CAAC,EAAGH,MAAM,CAASC,SAAS,CAACG,WAAW,CAAC,GAAG,CAAC,CAAC,GAC9E;AACJ,CAAC,GACD,OAAOE,qBAAqB,KAAK,WAAW,IAAIA,qBAAqB,CAACJ,QAAQ,CAAC;AAAA,EAC7E;EACEA,QAAQ,EAAEI,qBAAqB,CAACJ,QAAQ;EACxCG,gBAAgB,EAAEC,qBAAqB,CAACD;AAC1C,CAAC,GACD;EACA;EACEH,QAAQ,EAAEL,aAAa,GAAG,SAAS;EACnCQ,gBAAgB,EAAER,aAAa,GAAG;AACpC,CAAC;AAEP,IAAAU,UAAG,EAAC,gCAAgC,GAAGT,KAAK,CAACI,QAAQ,CAAC;;AAEtD;AACO,IAAMA,QAAQ,GAAAH,OAAA,CAAAG,QAAA,GAAGJ,KAAK,CAACI,QAAQ;AAC/B,IAAMG,gBAAgB,GAAAN,OAAA,CAAAM,gBAAA,GAAGP,KAAK,CAACO,gBAAgB"}
File without changes
File without changes
File without changes
File without changes
package/lib/index.d.ts CHANGED
File without changes
File without changes
package/lib/index.js CHANGED
@@ -170,8 +170,8 @@ var _footer = require("./footer");
170
170
  var createTypes = _interopRequireWildcard(require("./create/types"));
171
171
  exports.createTypes = createTypes;
172
172
  var _solidLogic = require("solid-logic");
173
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
174
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
173
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
174
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
175
175
  // pull in first avoid cross-refs
176
176
  // @ts-ignore
177
177
  // @ts-ignore
@@ -183,8 +183,8 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
183
183
  // @ts-ignore
184
184
  // @ts-ignore
185
185
  // @ts-ignore
186
- var dom = window ? window.document : null; // Idea that UI.dom can be adapted in non-browser environments
187
- exports.dom = dom;
186
+ var dom = exports.dom = window ? window.document : null; // Idea that UI.dom can be adapted in non-browser environments
187
+
188
188
  if (typeof window !== 'undefined') {
189
189
  ;
190
190
  window.UI = {
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["_typeof","require","Object","defineProperty","exports","value","enumerable","get","_index","acl","aclControl","_solidLogic","authn","_index2","create","dom","createTypes","_iconBase","icons","_infinite","infiniteMessageArea","_footer","initFooter","_header","initHeader","login","log","language","_index3","matrix","_index4","media","_messageArea","messageArea","rdf","preferences","participation","pad","ns","store","style","_table","renderTableViewPane","utils","tabs","_versionInfo","versionInfo","widgets","_interopRequireWildcard","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","cache","has","newObj","hasPropertyDescriptor","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","window","document","UI","table"],"sources":["../src/index.ts"],"sourcesContent":["/*\nThe MIT License (MIT)\n\nCopyright (c) 2015-2016 Solid\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\nIf you would like to know more about the solid Solid project, please see\nhttps://github.com/solidos/solid\n*/\n'use strict'\n/**\n * Provides a Solid client helper object (which exposes various static modules).\n * @module solidUi.js\n * @main solidUi.js\n */\n\n/**\n * @class SolidUi\n * @static\n */\n\n// REMOVE @ts-ignore as you migrate files to TypeScript\nimport * as rdf from 'rdflib' // pull in first avoid cross-refs\n// @ts-ignore\nimport * as ns from './ns'\nimport { acl, aclControl } from './acl/index'\nimport { create } from './create/index'\n// @ts-ignore\nimport { icons } from './iconBase'\nimport * as language from './widgets/forms/autocomplete/language'\nimport * as log from './log'\nimport { matrix } from './matrix/index'\nimport { media } from './media/index'\n// @ts-ignore\nimport { messageArea } from './messageArea'\n// @ts-ignore\nimport { infiniteMessageArea } from './chat/infinite'\n// @ts-ignore\nimport * as pad from './pad'\n// @ts-ignore\nimport * as participation from './participation'\n// @ts-ignore\nimport * as preferences from './preferences'\n// @ts-ignore\nimport * as style from './style'\n// @ts-ignore\nimport { renderTableViewPane as table } from './table'\nimport * as tabs from './tabs'\n// @ts-ignore\nimport * as utils from './utils'\nimport * as login from './login/login'\nimport * as widgets from './widgets/index'\nimport { versionInfo } from './versionInfo'\nimport { initHeader } from './header'\nimport { initFooter } from './footer'\nimport * as createTypes from './create/types'\nimport { authn, store } from 'solid-logic'\n\nconst dom = window ? window.document : null // Idea that UI.dom can be adapted in non-browser environments\n\nif (typeof window !== 'undefined') {\n ;(<any>window).UI = {\n authn,\n store,\n ns,\n rdf,\n acl,\n aclControl,\n create,\n createTypes,\n dom,\n icons,\n language,\n log,\n login,\n matrix,\n media,\n messageArea,\n infiniteMessageArea,\n pad,\n participation,\n preferences,\n style,\n table,\n tabs,\n utils,\n widgets,\n versionInfo,\n initHeader,\n initFooter\n } // Simpler access by non-node scripts\n}\n\n// this variables are directly used in the storybook\nexport {\n authn,\n store,\n ns,\n rdf,\n acl,\n aclControl,\n create,\n createTypes,\n dom,\n icons,\n language,\n log,\n login,\n matrix,\n media,\n messageArea,\n infiniteMessageArea,\n pad,\n participation,\n preferences,\n style,\n table,\n tabs,\n utils,\n widgets,\n versionInfo,\n initHeader,\n initFooter\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,YAAY;;AACZ;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAC,KAAA;AAAA;AAAAH,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAC,MAAA,CAAAC,GAAA;EAAA;AAAA;AAAAP,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAC,MAAA,CAAAE,UAAA;EAAA;AAAA;AAAAR,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAI,WAAA,CAAAC,KAAA;EAAA;AAAA;AAAAV,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAM,OAAA,CAAAC,MAAA;EAAA;AAAA;AAAAV,OAAA,CAAAW,GAAA,GAAAX,OAAA,CAAAY,WAAA;AAAAd,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAU,SAAA,CAAAC,KAAA;EAAA;AAAA;AAAAhB,MAAA,CAAAC,cAAA,CAAAC,OAA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,KAAK,EAALA,KAAK;IACL8B,KAAK,EAALA,0BAAK;IACL1B,IAAI,EAAJA,IAAI;IACJD,KAAK,EAALA,KAAK;IACLI,OAAO,EAAPA,OAAO;IACPD,WAAW,EAAXA,wBAAW;IACXtB,UAAU,EAAVA,kBAAU;IACVF,UAAU,EAAVA;EACF,CAAC,EAAC;AACJ;;AAEA"}
1
+ {"version":3,"file":"index.js","names":["_typeof","require","Object","defineProperty","exports","value","enumerable","get","_index","acl","aclControl","_solidLogic","authn","_index2","create","dom","createTypes","_iconBase","icons","_infinite","infiniteMessageArea","_footer","initFooter","_header","initHeader","login","log","language","_index3","matrix","_index4","media","_messageArea","messageArea","rdf","preferences","participation","pad","ns","store","style","_table","renderTableViewPane","utils","tabs","_versionInfo","versionInfo","widgets","_interopRequireWildcard","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","has","n","__proto__","a","getOwnPropertyDescriptor","u","prototype","hasOwnProperty","call","i","set","window","document","UI","table"],"sources":["../src/index.ts"],"sourcesContent":["/*\nThe MIT License (MIT)\n\nCopyright (c) 2015-2016 Solid\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\nIf you would like to know more about the solid Solid project, please see\nhttps://github.com/solidos/solid\n*/\n'use strict'\n/**\n * Provides a Solid client helper object (which exposes various static modules).\n * @module solidUi.js\n * @main solidUi.js\n */\n\n/**\n * @class SolidUi\n * @static\n */\n\n// REMOVE @ts-ignore as you migrate files to TypeScript\nimport * as rdf from 'rdflib' // pull in first avoid cross-refs\n// @ts-ignore\nimport * as ns from './ns'\nimport { acl, aclControl } from './acl/index'\nimport { create } from './create/index'\n// @ts-ignore\nimport { icons } from './iconBase'\nimport * as language from './widgets/forms/autocomplete/language'\nimport * as log from './log'\nimport { matrix } from './matrix/index'\nimport { media } from './media/index'\n// @ts-ignore\nimport { messageArea } from './messageArea'\n// @ts-ignore\nimport { infiniteMessageArea } from './chat/infinite'\n// @ts-ignore\nimport * as pad from './pad'\n// @ts-ignore\nimport * as participation from './participation'\n// @ts-ignore\nimport * as preferences from './preferences'\n// @ts-ignore\nimport * as style from './style'\n// @ts-ignore\nimport { renderTableViewPane as table } from './table'\nimport * as tabs from './tabs'\n// @ts-ignore\nimport * as utils from './utils'\nimport * as login from './login/login'\nimport * as widgets from './widgets/index'\nimport { versionInfo } from './versionInfo'\nimport { initHeader } from './header'\nimport { initFooter } from './footer'\nimport * as createTypes from './create/types'\nimport { authn, store } from 'solid-logic'\n\nconst dom = window ? window.document : null // Idea that UI.dom can be adapted in non-browser environments\n\nif (typeof window !== 'undefined') {\n ;(<any>window).UI = {\n authn,\n store,\n ns,\n rdf,\n acl,\n aclControl,\n create,\n createTypes,\n dom,\n icons,\n language,\n log,\n login,\n matrix,\n media,\n messageArea,\n infiniteMessageArea,\n pad,\n participation,\n preferences,\n style,\n table,\n tabs,\n utils,\n widgets,\n versionInfo,\n initHeader,\n initFooter\n } // Simpler access by non-node scripts\n}\n\n// this variables are directly used in the storybook\nexport {\n authn,\n store,\n ns,\n rdf,\n acl,\n aclControl,\n create,\n createTypes,\n dom,\n icons,\n language,\n log,\n login,\n matrix,\n media,\n messageArea,\n infiniteMessageArea,\n pad,\n participation,\n preferences,\n style,\n table,\n tabs,\n utils,\n widgets,\n versionInfo,\n initHeader,\n initFooter\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,YAAY;;AACZ;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAC,KAAA;AAAA;AAAAH,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAC,MAAA,CAAAC,GAAA;EAAA;AAAA;AAAAP,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAC,MAAA,CAAAE,UAAA;EAAA;AAAA;AAAAR,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAI,WAAA,CAAAC,KAAA;EAAA;AAAA;AAAAV,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAM,OAAA,CAAAC,MAAA;EAAA;AAAA;AAAAV,OAAA,CAAAW,GAAA,GAAAX,OAAA,CAAAY,WAAA;AAAAd,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAU,SAAA,CAAAC,KAAA;EAAA;AAAA;AAAAhB,MAAA,CAAAC,cAAA,CAAAC,OAAA;EAAAE,UAAA;EAAAC,GAAA,WAAAA,IAAA;IAAA,OAAAY,SAAA,CAAAC,mBAAA;EAAA;AA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KAAK;IACLI,OAAO,EAAPA,OAAO;IACPD,WAAW,EAAXA,wBAAW;IACXtB,UAAU,EAAVA,kBAAU;IACVF,UAAU,EAAVA;EACF,CAAC,EAAC;AACJ;;AAEA"}
package/lib/log.d.ts CHANGED
File without changes
package/lib/log.d.ts.map CHANGED
File without changes
package/lib/log.js CHANGED
@@ -38,10 +38,7 @@ var TDEBUG = 32;
38
38
  var TALL = 63;
39
39
 
40
40
  /** @internal */
41
- var LogLevel;
42
- /** @internal */
43
- exports.LogLevel = LogLevel;
44
- (function (LogLevel) {
41
+ var LogLevel = exports.LogLevel = /*#__PURE__*/function (LogLevel) {
45
42
  LogLevel[LogLevel["Error"] = 1] = "Error";
46
43
  LogLevel[LogLevel["Warning"] = 2] = "Warning";
47
44
  LogLevel[LogLevel["Message"] = 4] = "Message";
@@ -49,7 +46,9 @@ exports.LogLevel = LogLevel;
49
46
  LogLevel[LogLevel["Info"] = 16] = "Info";
50
47
  LogLevel[LogLevel["Debug"] = 32] = "Debug";
51
48
  LogLevel[LogLevel["All"] = 63] = "All";
52
- })(LogLevel || (exports.LogLevel = LogLevel = {}));
49
+ return LogLevel;
50
+ }({});
51
+ /** @internal */
53
52
  var _level = TERROR + TWARN + TMESG;
54
53
  /** @internal */
55
54
  var _ascending = false;
package/lib/log.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"log.js","names":["TERROR","TWARN","TMESG","TSUCCESS","TINFO","TDEBUG","TALL","LogLevel","exports","_level","_ascending","_dom","document","_window","window","log","str","type","arguments","length","undefined","typestr","logArea","getElementById","addendum","createElement","setAttribute","now","Date","innerHTML","concat","getHours","getMinutes","getSeconds","escapeForXML","insertBefore","firstChild","appendChild","console","msg","message","warn","debug","info","error","success","alert","clear","_dom2","setLevel","level","dumpHTML","_dom3","_dom3$body","body","logAscending","logDescending","replace","setInternals"],"sources":["../src/log.ts"],"sourcesContent":["// /////////////////////// Logging\n//\n// bitmask levels\n// const TNONE = 0\n/** @internal */\nconst TERROR = 1\n/** @internal */\nconst TWARN = 2\n/** @internal */\nconst TMESG = 4\n/** @internal */\nconst TSUCCESS = 8\n/** @internal */\nconst TINFO = 16\n/** @internal */\nconst TDEBUG = 32\n/** @internal */\nconst TALL = 63\n\n/** @internal */\nexport enum LogLevel {\n Error = TERROR,\n Warning = TWARN,\n Message = TMESG,\n Success = TSUCCESS,\n Info = TINFO,\n Debug = TDEBUG,\n All = TALL\n}\n\n/** @internal */\nlet _level: number = TERROR + TWARN + TMESG\n/** @internal */\nlet _ascending: boolean = false\n/** @internal */\nlet _dom: HTMLDocument = document // must be able to override for tests\n/** @internal */\nlet _window: Window = window // must be able to override for tests\n\n/** @internal */\nfunction log (str: string, type: number = TMESG, typestr: string = 'mesg') {\n if (!(_level & type)) return // bitmask\n\n if (typeof _dom !== 'undefined') {\n const logArea = _dom.getElementById('status')\n if (!logArea) return\n\n const addendum = _dom.createElement('span')\n addendum.setAttribute('class', typestr)\n const now = new Date()\n addendum.innerHTML = `${now.getHours()}:${now.getMinutes()}:${now.getSeconds()} [${typestr}] ${escapeForXML(str)}<br/>`\n if (_ascending) {\n logArea.insertBefore(addendum, logArea.firstChild)\n } else {\n logArea.appendChild(addendum)\n }\n } else if (typeof console !== 'undefined') {\n // eslint-disable-next-line no-console\n console.log(str)\n }\n}\n\n/**\n * Adds a message to the element with id \"status\". The messages are prepended with\n * time and type of message, in this case [mesg].\n */\nexport function msg (message: string) {\n log(message)\n}\n\n/**\n * Adds a warning message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [warn].\n */\nexport function warn (message: string): void {\n log(message, TWARN, 'warn')\n}\n\n/**\n * Adds a debugging message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [dbug].\n */\nexport function debug (message: string): void {\n log(message, TDEBUG, 'dbug')\n}\n\n/**\n * Adds a info message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [info].\n */\nexport function info (message: string): void {\n log(message, TINFO, 'info')\n}\n\n/**\n * Adds a error to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [eror].\n */\nexport function error (message: string): void {\n log(message, TERROR, 'eror')\n}\n\n/**\n * Adds a success message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [good].\n */\nexport function success (message: string): void {\n log(message, TSUCCESS, 'good')\n}\n\n/**\n * Uses the global alert to send an alert. If global alert is not available, it\n * will output the message using the method [[warning]]s.\n */\nexport function alert (message: string): void {\n if (_window && typeof _window.alert !== 'undefined') {\n _window.alert(message)\n } else {\n warn(message)\n }\n}\n\n/**\n * Will clear the content of the element with id \"status\".\n */\nexport function clear (): void {\n const logArea = _dom?.getElementById('status')\n if (!logArea) return\n logArea.innerHTML = ''\n}\n\n/**\n * Lets you configure which types of messages will be shown. The module uses\n * [bitmask](https://en.wikipedia.org/wiki/Mask_(computing)) to filter which\n * types of messages should be shown. E.g. if you only want warning messages\n * to be shown, pass 2 to the function, if you want warning and success to be\n * shown, pass 10 (2+8). By passing the sum of all, 63, you'll show all\n * types of messages.\n *\n * - Error: 1\n * - Warning: 2\n * - Message: 4\n * - Success: 8\n * - Info: 16\n * - Debug: 32\n */\nexport function setLevel (level: number): void {\n _level = TALL\n debug('Log level is now ' + level)\n _level = level\n}\n\n/**\n * Will dump the current HTML using the [[debug]] method.\n */\nexport function dumpHTML (): void {\n if (!_dom) return\n const level = _level\n _level = TALL\n debug(_dom?.body?.innerHTML || '')\n _level = level\n}\n\n/**\n * Will start prepending messages the list of log messages.\n */\nexport function logAscending () {\n _ascending = true\n}\n\n/**\n * Will start appending messages the list of log messages. (This is default\n * behavior.)\n */\nexport function logDescending () {\n _ascending = false\n}\n\n/** @internal */\nexport function escapeForXML (str: string): string {\n // can be replaced with function utils module when migrating\n return str\n .replace(/&/g, '&amp;')\n .replace(/</g, '&lt;')\n .replace(/>/g, '&gt;')\n}\n\n/** @internal */\nexport function setInternals (window, document) {\n _window = window\n _dom = document\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA,IAAM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pB,MAAM,GAAGyC,KAAK;AAChB;;AAEA;AACA;AACA;AACO,SAASK,YAAYA,CAAA,EAAI;EAC9B7C,UAAU,GAAG,IAAI;AACnB;;AAEA;AACA;AACA;AACA;AACO,SAAS8C,aAAaA,CAAA,EAAI;EAC/B9C,UAAU,GAAG,KAAK;AACpB;;AAEA;AACO,SAASwB,YAAYA,CAAElB,GAAW,EAAU;EACjD;EACA,OAAOA,GAAG,CACPyC,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,CACtBA,OAAO,CAAC,IAAI,EAAE,MAAM,CAAC,CACrBA,OAAO,CAAC,IAAI,EAAE,MAAM,CAAC;AAC1B;;AAEA;AACO,SAASC,YAAYA,CAAE5C,MAAM,EAAEF,QAAQ,EAAE;EAC9CC,OAAO,GAAGC,MAAM;EAChBH,IAAI,GAAGC,QAAQ;AACjB"}
1
+ {"version":3,"file":"log.js","names":["TERROR","TWARN","TMESG","TSUCCESS","TINFO","TDEBUG","TALL","LogLevel","exports","_level","_ascending","_dom","document","_window","window","log","str","type","arguments","length","undefined","typestr","logArea","getElementById","addendum","createElement","setAttribute","now","Date","innerHTML","concat","getHours","getMinutes","getSeconds","escapeForXML","insertBefore","firstChild","appendChild","console","msg","message","warn","debug","info","error","success","alert","clear","_dom2","setLevel","level","dumpHTML","_dom3","_dom3$body","body","logAscending","logDescending","replace","setInternals"],"sources":["../src/log.ts"],"sourcesContent":["// /////////////////////// Logging\n//\n// bitmask levels\n// const TNONE = 0\n/** @internal */\nconst TERROR = 1\n/** @internal */\nconst TWARN = 2\n/** @internal */\nconst TMESG = 4\n/** @internal */\nconst TSUCCESS = 8\n/** @internal */\nconst TINFO = 16\n/** @internal */\nconst TDEBUG = 32\n/** @internal */\nconst TALL = 63\n\n/** @internal */\nexport enum LogLevel {\n Error = TERROR,\n Warning = TWARN,\n Message = TMESG,\n Success = TSUCCESS,\n Info = TINFO,\n Debug = TDEBUG,\n All = TALL\n}\n\n/** @internal */\nlet _level: number = TERROR + TWARN + TMESG\n/** @internal */\nlet _ascending: boolean = false\n/** @internal */\nlet _dom: HTMLDocument = document // must be able to override for tests\n/** @internal */\nlet _window: Window = window // must be able to override for tests\n\n/** @internal */\nfunction log (str: string, type: number = TMESG, typestr: string = 'mesg') {\n if (!(_level & type)) return // bitmask\n\n if (typeof _dom !== 'undefined') {\n const logArea = _dom.getElementById('status')\n if (!logArea) return\n\n const addendum = _dom.createElement('span')\n addendum.setAttribute('class', typestr)\n const now = new Date()\n addendum.innerHTML = `${now.getHours()}:${now.getMinutes()}:${now.getSeconds()} [${typestr}] ${escapeForXML(str)}<br/>`\n if (_ascending) {\n logArea.insertBefore(addendum, logArea.firstChild)\n } else {\n logArea.appendChild(addendum)\n }\n } else if (typeof console !== 'undefined') {\n // eslint-disable-next-line no-console\n console.log(str)\n }\n}\n\n/**\n * Adds a message to the element with id \"status\". The messages are prepended with\n * time and type of message, in this case [mesg].\n */\nexport function msg (message: string) {\n log(message)\n}\n\n/**\n * Adds a warning message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [warn].\n */\nexport function warn (message: string): void {\n log(message, TWARN, 'warn')\n}\n\n/**\n * Adds a debugging message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [dbug].\n */\nexport function debug (message: string): void {\n log(message, TDEBUG, 'dbug')\n}\n\n/**\n * Adds a info message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [info].\n */\nexport function info (message: string): void {\n log(message, TINFO, 'info')\n}\n\n/**\n * Adds a error to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [eror].\n */\nexport function error (message: string): void {\n log(message, TERROR, 'eror')\n}\n\n/**\n * Adds a success message to the element with id \"status\". The messages are\n * prepended with time and type of message, in this case [good].\n */\nexport function success (message: string): void {\n log(message, TSUCCESS, 'good')\n}\n\n/**\n * Uses the global alert to send an alert. If global alert is not available, it\n * will output the message using the method [[warning]]s.\n */\nexport function alert (message: string): void {\n if (_window && typeof _window.alert !== 'undefined') {\n _window.alert(message)\n } else {\n warn(message)\n }\n}\n\n/**\n * Will clear the content of the element with id \"status\".\n */\nexport function clear (): void {\n const logArea = _dom?.getElementById('status')\n if (!logArea) return\n logArea.innerHTML = ''\n}\n\n/**\n * Lets you configure which types of messages will be shown. The module uses\n * [bitmask](https://en.wikipedia.org/wiki/Mask_(computing)) to filter which\n * types of messages should be shown. E.g. if you only want warning messages\n * to be shown, pass 2 to the function, if you want warning and success to be\n * shown, pass 10 (2+8). By passing the sum of all, 63, you'll show all\n * types of messages.\n *\n * - Error: 1\n * - Warning: 2\n * - Message: 4\n * - Success: 8\n * - Info: 16\n * - Debug: 32\n */\nexport function setLevel (level: number): void {\n _level = TALL\n debug('Log level is now ' + level)\n _level = level\n}\n\n/**\n * Will dump the current HTML using the [[debug]] method.\n */\nexport function dumpHTML (): void {\n if (!_dom) return\n const level = _level\n _level = TALL\n debug(_dom?.body?.innerHTML || '')\n _level = level\n}\n\n/**\n * Will start prepending messages the list of log messages.\n */\nexport function logAscending () {\n _ascending = true\n}\n\n/**\n * Will start appending messages the list of log messages. (This is default\n * behavior.)\n */\nexport function logDescending () {\n _ascending = false\n}\n\n/** @internal */\nexport function escapeForXML (str: string): string {\n // can be replaced with function utils module when migrating\n return str\n .replace(/&/g, '&amp;')\n .replace(/</g, '&lt;')\n .replace(/>/g, '&gt;')\n}\n\n/** @internal */\nexport function setInternals (window, document) {\n _window = window\n _dom = document\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA,IAAMA,MAAM,GAAG,CAAC;AAChB;AACA,IAAMC,KAAK,GAAG,CAAC;AACf;AACA,IAAMC,KAAK,GAAG,CAAC;AACf;AACA,IAAMC,QAAQ,GAAG,CAAC;AAClB;AACA,IAAMC,KAAK,GAAG,EAAE;AAChB;AACA,IAAMC,MAAM,GAAG,EAAE;AACjB;AACA,IAAMC,IAAI,GAAG,EAAE;;AAEf;AAAA,IACYC,QAAQ,GAAAC,OAAA,CAAAD,QAAA,0BAARA,QA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,OAAO,CAAC,qBAAqB,CAAC,CAuCjC;AAqGD,wBAAgB,iBAAiB,CAAE,GAAG,EAAE,YAAY,QA+InD;AAED;;;;;;;;;GASG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EAAE,YAAY,EACjB,QAAQ,GAAE,CAAC,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC,GAAG,IAAW,EACtD,OAAO,GAAE;IACP,WAAW,CAAC,EAAE,MAAM,CAAC;CACjB,GACL,WAAW,CAwFb;AAyBD;;;GAGG;AAEH;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,eAAe,CAC7B,GAAG,EAAE,YAAY,EACjB,UAAU,EAAE,UAAU,EACtB,UAAU,EAAE,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,EAAE,OAAO,EAAE,MAAM,KAAK,IAAI,GAC9D,WAAW,CA0Pb;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EAAE,YAAY,EACjB,UAAU,EAAE,UAAU,EACtB,QAAQ,EAAE,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,EAAE,OAAO,EAAE,MAAM,KAAK,IAAI,GAC5D,WAAW,CAmBb;AACD;;;GAGG;AACH,wBAAsB,YAAY,IAAK,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAgB/D;AAED;;GAEG;AACH,wBAAsB,oBAAoB,CACxC,KAAK,EAAE,KAAK,CAAC,cAAc,CAAC,GAC3B,OAAO,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,CAGhC"}
@@ -30,11 +30,34 @@ var ns = _interopRequireWildcard(require("../ns.js"));
30
30
  var _signup = require("../signup/signup.js");
31
31
  var utils = _interopRequireWildcard(require("../utils"));
32
32
  var widgets = _interopRequireWildcard(require("../widgets"));
33
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
34
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
33
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
34
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
35
35
  function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
36
36
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
37
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
37
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; } /* eslint-disable camelcase */ /**
38
+ * Signing in, signing up, profile and preferences reloading
39
+ * Type index management
40
+ *
41
+ * Many functions in this module take a context object which
42
+ * holds various RDF symbols, add to it, and return a promise of it.
43
+ *
44
+ * * `me` RDF symbol for the user's WebID
45
+ * * `publicProfile` The user's public profile, iff loaded
46
+ * * `preferencesFile` The user's personal preference file, iff loaded
47
+ * * `index.public` The user's public type index file
48
+ * * `index.private` The user's private type index file
49
+ *
50
+ * Not RDF symbols:
51
+ * * `noun` A string in english for the type of thing -- like "address book"
52
+ * * `instance` An array of nodes which are existing instances
53
+ * * `containers` An array of nodes of containers of instances
54
+ * * `div` A DOM element where UI can be displayed
55
+ * * `statusArea` A DOM element (opt) progress stuff can be displayed, or error messages
56
+ * *
57
+ * * Vocabulary: "load" loads a file if it exists;
58
+ * * 'Ensure" CREATES the file if it does not exist (if it can) and then loads it.
59
+ * @packageDocumentation
60
+ */ // eslint-disable-next-line camelcase
38
61
  var store = _solidLogic.solidLogicSingleton.store;
39
62
  var _solidLogicSingleton$ = _solidLogic.solidLogicSingleton.profile,
40
63
  loadPreferences = _solidLogicSingleton$.loadPreferences,
@@ -100,104 +123,93 @@ function ensureLoadedPreferences(_x) {
100
123
  // used to be logInLoadProfile
101
124
  function _ensureLoadedPreferences() {
102
125
  _ensureLoadedPreferences = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee4(context) {
103
- var statusArea, progressDisplay, complain, preferencesFile, m2;
126
+ var progressDisplay, preferencesFile, m2;
104
127
  return _regenerator["default"].wrap(function _callee4$(_context4) {
105
128
  while (1) switch (_context4.prev = _context4.next) {
106
129
  case 0:
107
- complain = function _complain(message) {
108
- message = "ensureLoadedPreferences: ".concat(message);
109
- if (statusArea) {
110
- // statusArea.innerHTML = ''
111
- statusArea.appendChild(widgets.errorMessageBlock(context.dom, message));
112
- }
113
- debug.log(message);
114
- // reject(new Error(message))
115
- };
116
130
  if (!context.preferencesFile) {
117
- _context4.next = 3;
131
+ _context4.next = 2;
118
132
  break;
119
133
  }
120
134
  return _context4.abrupt("return", Promise.resolve(context));
121
- case 3:
122
- // already done
123
- statusArea = context.statusArea || context.div || null;
124
- _context4.prev = 4;
125
- _context4.next = 7;
135
+ case 2:
136
+ _context4.prev = 2;
137
+ _context4.next = 5;
126
138
  return ensureLoadedProfile(context);
127
- case 7:
139
+ case 5:
128
140
  context = _context4.sent;
129
- _context4.next = 10;
141
+ _context4.next = 8;
130
142
  return loadPreferences(context.me);
131
- case 10:
143
+ case 8:
132
144
  preferencesFile = _context4.sent;
133
145
  if (progressDisplay) {
134
146
  progressDisplay.parentNode.removeChild(progressDisplay);
135
147
  }
136
148
  context.preferencesFile = preferencesFile;
137
- _context4.next = 51;
149
+ _context4.next = 49;
138
150
  break;
139
- case 15:
140
- _context4.prev = 15;
141
- _context4.t0 = _context4["catch"](4);
151
+ case 13:
152
+ _context4.prev = 13;
153
+ _context4.t0 = _context4["catch"](2);
142
154
  if (!(_context4.t0 instanceof _solidLogic.UnauthorizedError)) {
143
- _context4.next = 22;
155
+ _context4.next = 20;
144
156
  break;
145
157
  }
146
158
  m2 = 'Ooops - you are not authenticated (properly logged in) to for me to read your preference file. Try loggin out and logging in?';
147
159
  (0, _log.alert)(m2);
148
- _context4.next = 51;
160
+ _context4.next = 49;
149
161
  break;
150
- case 22:
162
+ case 20:
151
163
  if (!(_context4.t0 instanceof _solidLogic.CrossOriginForbiddenError)) {
152
- _context4.next = 28;
164
+ _context4.next = 26;
153
165
  break;
154
166
  }
155
167
  m2 = "Unauthorized: Assuming preference file blocked for origin ".concat(window.location.origin);
156
168
  context.preferencesFileError = m2;
157
169
  return _context4.abrupt("return", context);
158
- case 28:
170
+ case 26:
159
171
  if (!(_context4.t0 instanceof _solidLogic.SameOriginForbiddenError)) {
160
- _context4.next = 34;
172
+ _context4.next = 32;
161
173
  break;
162
174
  }
163
175
  m2 = 'You are not authorized to read your preference file. This may be because you are using an untrusted web app.';
164
176
  debug.warn(m2);
165
177
  return _context4.abrupt("return", context);
166
- case 34:
178
+ case 32:
167
179
  if (!(_context4.t0 instanceof _solidLogic.NotEditableError)) {
168
- _context4.next = 40;
180
+ _context4.next = 38;
169
181
  break;
170
182
  }
171
183
  m2 = 'You are not authorized to edit your preference file. This may be because you are using an untrusted web app.';
172
184
  debug.warn(m2);
173
185
  return _context4.abrupt("return", context);
174
- case 40:
186
+ case 38:
175
187
  if (!(_context4.t0 instanceof _solidLogic.WebOperationError)) {
176
- _context4.next = 45;
188
+ _context4.next = 43;
177
189
  break;
178
190
  }
179
191
  m2 = 'You are not authorized to edit your preference file. This may be because you are using an untrusted web app.';
180
192
  debug.warn(m2);
181
- _context4.next = 51;
193
+ _context4.next = 49;
182
194
  break;
183
- case 45:
195
+ case 43:
184
196
  if (!(_context4.t0 instanceof _solidLogic.FetchError)) {
185
- _context4.next = 50;
197
+ _context4.next = 48;
186
198
  break;
187
199
  }
188
200
  m2 = "Strange: Error ".concat(_context4.t0.status, " trying to read your preference file.").concat(_context4.t0.message);
189
201
  (0, _log.alert)(m2);
190
- _context4.next = 51;
202
+ _context4.next = 49;
191
203
  break;
192
- case 50:
204
+ case 48:
193
205
  throw new Error("(via loadPrefs) ".concat(_context4.t0));
194
- case 51:
206
+ case 49:
195
207
  return _context4.abrupt("return", context);
196
- case 52:
208
+ case 50:
197
209
  case "end":
198
210
  return _context4.stop();
199
211
  }
200
- }, _callee4, null, [[4, 15]]);
212
+ }, _callee4, null, [[2, 13]]);
201
213
  }));
202
214
  return _ensureLoadedPreferences.apply(this, arguments);
203
215
  }