solid-panes 5.0.0-0 → 5.0.0
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.
- package/dist/RDFXMLPane.d.ts.map +1 -1
- package/dist/RDFXMLPane2.cjs.js +1 -2
- package/dist/RDFXMLPane2.cjs.js.map +1 -1
- package/dist/RDFXMLPane2.esm.js +15 -42
- package/dist/RDFXMLPane2.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/arrow-left.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/arrow-left.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/ellipsis-vertical.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/ellipsis-vertical.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/folder-open.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/folder-open.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/folder.cjs.js +2 -0
- package/dist/_virtual/~icons/lucide/folder.cjs.js.map +1 -0
- package/dist/_virtual/~icons/lucide/{trash-2.esm.js → folder.esm.js} +4 -4
- package/dist/_virtual/~icons/lucide/folder.esm.js.map +1 -0
- package/dist/_virtual/~icons/lucide/globe.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/globe.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/help-circle.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/help-circle.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/layout-dashboard.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/layout-dashboard.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/lock-keyhole.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/lock-keyhole.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/pencil.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/pencil.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/settings-2.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/settings-2.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/share-2.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/share-2.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/user-round-cog.cjs.js +2 -0
- package/dist/_virtual/~icons/lucide/user-round-cog.cjs.js.map +1 -0
- package/dist/_virtual/~icons/lucide/user-round-cog.esm.js +11 -0
- package/dist/_virtual/~icons/lucide/user-round-cog.esm.js.map +1 -0
- package/dist/_virtual/~icons/lucide/user.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/user.esm.js.map +1 -1
- package/dist/_virtual/~icons/lucide/users.cjs.js.map +1 -1
- package/dist/_virtual/~icons/lucide/users.esm.js.map +1 -1
- package/dist/audio/audioPane.cjs.js.map +1 -1
- package/dist/audio/audioPane.esm.js.map +1 -1
- package/dist/classInstancePane.cjs.js.map +1 -1
- package/dist/classInstancePane.esm.js.map +1 -1
- package/dist/components/editor-card/EditorCard.cjs.js +6 -0
- package/dist/components/editor-card/EditorCard.cjs.js.map +1 -0
- package/dist/components/editor-card/EditorCard.d.ts +16 -0
- package/dist/components/editor-card/EditorCard.d.ts.map +1 -0
- package/dist/components/editor-card/EditorCard.esm.js +268 -0
- package/dist/components/editor-card/EditorCard.esm.js.map +1 -0
- package/dist/components/editor-card/EditorCard.styles.cjs.js +2 -0
- package/dist/components/editor-card/EditorCard.styles.cjs.js.map +1 -0
- package/dist/components/editor-card/EditorCard.styles.esm.js +7 -0
- package/dist/components/editor-card/EditorCard.styles.esm.js.map +1 -0
- package/dist/components/editor-card/index.cjs.js +1 -0
- package/dist/components/editor-card/index.d.ts +4 -0
- package/dist/components/editor-card/index.d.ts.map +1 -0
- package/dist/components/editor-card/index.esm.js +1 -0
- package/dist/components/file-explorer-header/FileExplorerHeader.cjs.js +2 -2
- package/dist/components/file-explorer-header/FileExplorerHeader.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeader.d.ts +1 -2
- package/dist/components/file-explorer-header/FileExplorerHeader.d.ts.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeader.esm.js +16 -16
- package/dist/components/file-explorer-header/FileExplorerHeader.esm.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeader.styles.cjs.js +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeader.styles.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeader.styles.esm.js +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeader.styles.esm.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.cjs.js +24 -14
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.d.ts +7 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.d.ts.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.esm.js +94 -66
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.esm.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.styles.cjs.js +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.styles.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.styles.esm.js +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderControls.styles.esm.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.cjs.js +22 -7
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.d.ts +3 -2
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.d.ts.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.esm.js +90 -65
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.esm.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.styles.cjs.js +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.styles.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.styles.esm.js +1 -1
- package/dist/components/file-explorer-header/FileExplorerHeaderSummary.styles.esm.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerProvider.cjs.js +4 -4
- package/dist/components/file-explorer-header/FileExplorerProvider.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerProvider.d.ts +1 -1
- package/dist/components/file-explorer-header/FileExplorerProvider.d.ts.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerProvider.esm.js +17 -16
- package/dist/components/file-explorer-header/FileExplorerProvider.esm.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerProvider.styles.cjs.js.map +1 -1
- package/dist/components/file-explorer-header/FileExplorerProvider.styles.esm.js.map +1 -1
- package/dist/components/file-explorer-header/index.cjs.js +1 -0
- package/dist/components/file-explorer-header/index.d.ts +3 -0
- package/dist/components/file-explorer-header/index.d.ts.map +1 -0
- package/dist/components/file-explorer-header/index.esm.js +2 -0
- package/dist/components/file-explorer-header/types.d.ts +8 -0
- package/dist/components/file-explorer-header/types.d.ts.map +1 -1
- package/dist/components/header/Header.cjs.js +1 -1
- package/dist/components/header/Header.cjs.js.map +1 -1
- package/dist/components/header/Header.esm.js +4 -4
- package/dist/components/header/Header.esm.js.map +1 -1
- package/dist/components/header/Header.styles.cjs.js +1 -1
- package/dist/components/header/Header.styles.cjs.js.map +1 -1
- package/dist/components/header/Header.styles.esm.js +1 -1
- package/dist/components/header/Header.styles.esm.js.map +1 -1
- package/dist/components/navbar/Navbar.cjs.js +2 -2
- package/dist/components/navbar/Navbar.cjs.js.map +1 -1
- package/dist/components/navbar/Navbar.esm.js +5 -5
- package/dist/components/navbar/Navbar.esm.js.map +1 -1
- package/dist/components/navbar/Navbar.styles.cjs.js.map +1 -1
- package/dist/components/navbar/Navbar.styles.esm.js.map +1 -1
- package/dist/components/resource-actions-menu/ResourceActionsMenu.cjs.js +23 -9
- package/dist/components/resource-actions-menu/ResourceActionsMenu.cjs.js.map +1 -1
- package/dist/components/resource-actions-menu/ResourceActionsMenu.d.ts +7 -4
- package/dist/components/resource-actions-menu/ResourceActionsMenu.d.ts.map +1 -1
- package/dist/components/resource-actions-menu/ResourceActionsMenu.esm.js +146 -84
- package/dist/components/resource-actions-menu/ResourceActionsMenu.esm.js.map +1 -1
- package/dist/components/resource-actions-menu/ResourceActionsMenu.styles.cjs.js +2 -0
- package/dist/components/resource-actions-menu/ResourceActionsMenu.styles.cjs.js.map +1 -0
- package/dist/components/resource-actions-menu/ResourceActionsMenu.styles.esm.js +7 -0
- package/dist/components/resource-actions-menu/ResourceActionsMenu.styles.esm.js.map +1 -0
- package/dist/dashboard/basicPreferences.cjs.js.map +1 -1
- package/dist/dashboard/basicPreferences.esm.js.map +1 -1
- package/dist/dashboard/dashboardPane.cjs.js.map +1 -1
- package/dist/dashboard/dashboardPane.esm.js.map +1 -1
- package/dist/dashboard/homepage.cjs.js.map +1 -1
- package/dist/dashboard/homepage.esm.js.map +1 -1
- package/dist/dashboard/ontologyData.cjs.js.map +1 -1
- package/dist/dashboard/ontologyData.esm.js.map +1 -1
- package/dist/dashboard/preferencesFormText.cjs.js.map +1 -1
- package/dist/dashboard/preferencesFormText.esm.js.map +1 -1
- package/dist/dataContentPane2.cjs.js +1 -1
- package/dist/dataContentPane2.cjs.js.map +1 -1
- package/dist/dataContentPane2.esm.js +1 -1
- package/dist/dataContentPane2.esm.js.map +1 -1
- package/dist/defaultPane2.cjs.js +1 -1
- package/dist/defaultPane2.cjs.js.map +1 -1
- package/dist/defaultPane2.esm.js +2 -2
- package/dist/defaultPane2.esm.js.map +1 -1
- package/dist/dokieli/dokieliPane.cjs.js.map +1 -1
- package/dist/dokieli/dokieliPane.esm.js.map +1 -1
- package/dist/dokieli/new.cjs.js.map +1 -1
- package/dist/dokieli/new.esm.js.map +1 -1
- package/dist/form/pane.cjs.js.map +1 -1
- package/dist/form/pane.esm.js.map +1 -1
- package/dist/home/homePane.cjs.js +1 -1
- package/dist/home/homePane.cjs.js.map +1 -1
- package/dist/home/homePane.esm.js +1 -1
- package/dist/home/homePane.esm.js.map +1 -1
- package/dist/humanReadablePane.d.ts +1 -1
- package/dist/humanReadablePane.d.ts.map +1 -1
- package/dist/humanReadablePane2.cjs.js +1 -1
- package/dist/humanReadablePane2.cjs.js.map +1 -1
- package/dist/humanReadablePane2.esm.js +2 -2
- package/dist/humanReadablePane2.esm.js.map +1 -1
- package/dist/icons/folder.cjs.js.map +1 -1
- package/dist/icons/folder.esm.js.map +1 -1
- package/dist/icons/friends.cjs.js.map +1 -1
- package/dist/icons/friends.esm.js.map +1 -1
- package/dist/icons/person.cjs.js.map +1 -1
- package/dist/icons/person.esm.js.map +1 -1
- package/dist/imagePane2.cjs.js +1 -1
- package/dist/imagePane2.cjs.js.map +1 -1
- package/dist/imagePane2.esm.js +1 -1
- package/dist/imagePane2.esm.js.map +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/internal/internalPane2.cjs.js +1 -1
- package/dist/internal/internalPane2.cjs.js.map +1 -1
- package/dist/internal/internalPane2.esm.js +2 -2
- package/dist/internal/internalPane2.esm.js.map +1 -1
- package/dist/mainPage/header.cjs.js.map +1 -1
- package/dist/mainPage/header.esm.js.map +1 -1
- package/dist/mainPage/index.cjs.js.map +1 -1
- package/dist/mainPage/index.esm.js.map +1 -1
- package/dist/mainPage/navbar.cjs.js.map +1 -1
- package/dist/mainPage/navbar.esm.js.map +1 -1
- package/dist/n3Pane.d.ts.map +1 -1
- package/dist/n3Pane2.cjs.js +1 -2
- package/dist/n3Pane2.cjs.js.map +1 -1
- package/dist/n3Pane2.esm.js +10 -34
- package/dist/n3Pane2.esm.js.map +1 -1
- package/dist/outline/context.cjs.js.map +1 -1
- package/dist/outline/context.esm.js.map +1 -1
- package/dist/outline/manager2.cjs.js +1 -1
- package/dist/outline/manager2.cjs.js.map +1 -1
- package/dist/outline/manager2.esm.js +9 -12
- package/dist/outline/manager2.esm.js.map +1 -1
- package/dist/outline/outlineIcons.cjs.js.map +1 -1
- package/dist/outline/outlineIcons.esm.js.map +1 -1
- package/dist/outline/propertyViews.cjs.js.map +1 -1
- package/dist/outline/propertyViews.esm.js.map +1 -1
- package/dist/outline/queryByExample.cjs.js +1 -1
- package/dist/outline/queryByExample.cjs.js.map +1 -1
- package/dist/outline/queryByExample.esm.js +4 -4
- package/dist/outline/queryByExample.esm.js.map +1 -1
- package/dist/outline/userInput.cjs.js +1 -1
- package/dist/outline/userInput.cjs.js.map +1 -1
- package/dist/outline/userInput.esm.js +2 -2
- package/dist/outline/userInput.esm.js.map +1 -1
- package/dist/outline/viewAsImage.cjs.js.map +1 -1
- package/dist/outline/viewAsImage.esm.js.map +1 -1
- package/dist/outline/viewAsMbox.cjs.js.map +1 -1
- package/dist/outline/viewAsMbox.esm.js.map +1 -1
- package/dist/pad/padPane2.cjs.js +1 -1
- package/dist/pad/padPane2.cjs.js.map +1 -1
- package/dist/pad/padPane2.esm.js +3 -3
- package/dist/pad/padPane2.esm.js.map +1 -1
- package/dist/playlist/playlistPane.cjs.js +1 -1
- package/dist/playlist/playlistPane.cjs.js.map +1 -1
- package/dist/playlist/playlistPane.esm.js +1 -1
- package/dist/playlist/playlistPane.esm.js.map +1 -1
- package/dist/registerPanes.cjs.js.map +1 -1
- package/dist/registerPanes.esm.js.map +1 -1
- package/dist/schedule/formsForSchedule.cjs.js.map +1 -1
- package/dist/schedule/formsForSchedule.esm.js.map +1 -1
- package/dist/schedule/schedulePane2.cjs.js.map +1 -1
- package/dist/schedule/schedulePane2.esm.js.map +1 -1
- package/dist/sharing/sharingPane.cjs.js +1 -1
- package/dist/sharing/sharingPane.cjs.js.map +1 -1
- package/dist/sharing/sharingPane.esm.js +1 -1
- package/dist/sharing/sharingPane.esm.js.map +1 -1
- package/dist/slideshow/slideshowPane.cjs.js.map +1 -1
- package/dist/slideshow/slideshowPane.esm.js.map +1 -1
- package/dist/social/editProfileDetails.cjs.js.map +1 -1
- package/dist/social/editProfileDetails.esm.js.map +1 -1
- package/dist/social/icons.cjs.js.map +1 -1
- package/dist/social/icons.esm.js.map +1 -1
- package/dist/social/socialPane2.cjs.js +2 -2
- package/dist/social/socialPane2.cjs.js.map +1 -1
- package/dist/social/socialPane2.esm.js +3 -3
- package/dist/social/socialPane2.esm.js.map +1 -1
- package/dist/social/socialSections.cjs.js.map +1 -1
- package/dist/social/socialSections.esm.js.map +1 -1
- package/dist/social/triage.cjs.js +1 -1
- package/dist/social/triage.cjs.js.map +1 -1
- package/dist/social/triage.esm.js +1 -1
- package/dist/social/triage.esm.js.map +1 -1
- package/dist/tabbed/tabbedPane.cjs.js.map +1 -1
- package/dist/tabbed/tabbedPane.esm.js.map +1 -1
- package/dist/tableViewPane.cjs.js.map +1 -1
- package/dist/tableViewPane.esm.js.map +1 -1
- package/dist/transaction/pane.cjs.js.map +1 -1
- package/dist/transaction/pane.esm.js.map +1 -1
- package/dist/transaction/period.cjs.js +1 -1
- package/dist/transaction/period.cjs.js.map +1 -1
- package/dist/transaction/period.esm.js +1 -1
- package/dist/transaction/period.esm.js.map +1 -1
- package/dist/trip/tripPane.cjs.js.map +1 -1
- package/dist/trip/tripPane.esm.js.map +1 -1
- package/dist/trustedApplications/trustedApplications.dom.cjs.js.map +1 -1
- package/dist/trustedApplications/trustedApplications.dom.esm.js.map +1 -1
- package/dist/trustedApplications/trustedApplications.utils.cjs.js.map +1 -1
- package/dist/trustedApplications/trustedApplications.utils.esm.js.map +1 -1
- package/dist/trustedApplications/trustedApplications.view.cjs.js.map +1 -1
- package/dist/trustedApplications/trustedApplications.view.esm.js.map +1 -1
- package/dist/ui/pane.cjs.js.map +1 -1
- package/dist/ui/pane.esm.js.map +1 -1
- package/dist/utils/paneUtils.cjs.js.map +1 -1
- package/dist/utils/paneUtils.esm.js.map +1 -1
- package/dist/utils/podUtils.cjs.js +1 -1
- package/dist/utils/podUtils.cjs.js.map +1 -1
- package/dist/utils/podUtils.d.ts +6 -1
- package/dist/utils/podUtils.d.ts.map +1 -1
- package/dist/utils/podUtils.esm.js +93 -22
- package/dist/utils/podUtils.esm.js.map +1 -1
- package/dist/utils/webIdUtils.cjs.js.map +1 -1
- package/dist/utils/webIdUtils.esm.js.map +1 -1
- package/dist/versionInfo.cjs.js +1 -1
- package/dist/versionInfo.cjs.js.map +1 -1
- package/dist/versionInfo.esm.js +3 -3
- package/dist/versionInfo.esm.js.map +1 -1
- package/dist/video/videoPane.cjs.js.map +1 -1
- package/dist/video/videoPane.esm.js.map +1 -1
- package/package.json +13 -13
- package/dist/_virtual/~icons/lucide/trash-2.cjs.js +0 -2
- package/dist/_virtual/~icons/lucide/trash-2.cjs.js.map +0 -1
- package/dist/_virtual/~icons/lucide/trash-2.esm.js.map +0 -1
- package/dist/components/file-explorer-header/helper.cjs.js +0 -2
- package/dist/components/file-explorer-header/helper.cjs.js.map +0 -1
- package/dist/components/file-explorer-header/helper.d.ts +0 -15
- package/dist/components/file-explorer-header/helper.d.ts.map +0 -1
- package/dist/components/file-explorer-header/helper.esm.js +0 -64
- package/dist/components/file-explorer-header/helper.esm.js.map +0 -1
- package/dist/components/resource-actions-menu/DeleteResourceDialog.cjs.js +0 -16
- package/dist/components/resource-actions-menu/DeleteResourceDialog.cjs.js.map +0 -1
- package/dist/components/resource-actions-menu/DeleteResourceDialog.esm.js +0 -215
- package/dist/components/resource-actions-menu/DeleteResourceDialog.esm.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileExplorerHeaderSummary.cjs.js","names":["sym","widgets","utils","WebComponent","fileExplorerContext","customElement","property","query","state","html","consume","styles","_classDecs","_FileExplorerHeaderSu","_FileExplorerHeaderSu2","_A","WeakMap","_B","_C","_D","_E","_F","_ref","_fileExplorerContextDecs","context","subscribe","_paneIconDecs","attribute","_onBackClickDecs","_responseMetadataDecs","_resolvedPaneIconDecs","_titleHeadingDecs","_FileExplorerHeaderSummary","FileExplorerHeaderSummary","constructor","args","_defineProperty","_initProto","_classPrivateFieldInitSpec","_init_fileExplorerContext","undefined","_init_paneIcon","_init_onBackClick","_init_responseMetadata","modified","isPublic","_init_resolvedPaneIcon","_init_titleHeading","_classPrivateFieldGet","v","_classPrivateFieldSet","paneIcon","onBackClick","responseMetadata","resolvedPaneIcon","titleHeading","formatModifiedDate","date","Date","Number","isNaN","getTime","parts","Intl","DateTimeFormat","day","month","year","hour","minute","hour12","formatToParts","getPart","type","find","part","value","dayPeriod","toUpperCase","updated","_resolvedPaneIconFor","resolvePaneIcon","subjectUri","_draggableSubjectUri","makeDraggable","icon","error","console","warn","render","subject","label","e","c","_initClass","_applyDecs","_Class","_identity","default"],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.ts"],"sourcesContent":["import { sym } from 'rdflib'\nimport { widgets, utils, WebComponent, fileExplorerContext, type FileExplorerContext } from 'solid-ui'\nimport 'solid-ui/components/button'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { html } from 'lit'\nimport { consume } from '@lit/context'\nimport { PaneIcon } from './types'\nimport '~icons/lucide/globe'\nimport '~icons/lucide/lock-keyhole'\nimport '~icons/lucide/arrow-left'\nimport styles from './FileExplorerHeaderSummary.styles.css'\nimport { type FileExplorerResourceMetadata } from './helper'\n\n@customElement('file-explorer-header-summary')\nexport default class FileExplorerHeaderSummary extends WebComponent {\n static styles = styles\n\n private _draggableSubjectUri: string | undefined\n private _resolvedPaneIconFor: PaneIcon | undefined\n\n @consume({ context: fileExplorerContext, subscribe: true })\n accessor fileExplorerContext: FileExplorerContext = undefined as unknown as FileExplorerContext\n\n @property({ attribute: false })\n accessor paneIcon: PaneIcon | undefined\n\n @property({ attribute: false })\n accessor onBackClick: (() => void) | undefined\n\n @property({ attribute: false })\n accessor responseMetadata: Pick<FileExplorerResourceMetadata, 'modified' | 'isPublic'> = {\n modified: undefined,\n isPublic: false\n }\n\n @state()\n accessor resolvedPaneIcon: string | undefined = undefined\n\n @query('h1')\n private accessor titleHeading: HTMLHeadingElement | null = null\n\n private formatModifiedDate (modified: string | undefined) {\n if (!modified) return ''\n\n const date = new Date(modified)\n if (Number.isNaN(date.getTime())) return modified\n\n const parts = new Intl.DateTimeFormat('en-GB', {\n day: '2-digit',\n month: 'short',\n year: 'numeric',\n hour: '2-digit',\n minute: '2-digit',\n hour12: true\n }).formatToParts(date)\n\n const getPart = (type: Intl.DateTimeFormatPartTypes) => parts.find(part => part.type === type)?.value ?? ''\n const day = getPart('day')\n const month = getPart('month')\n const year = getPart('year')\n const hour = getPart('hour')\n const minute = getPart('minute')\n const dayPeriod = getPart('dayPeriod').toUpperCase()\n\n return `${day} ${month}, ${year} at ${hour}:${minute} ${dayPeriod}`\n }\n\n protected updated () {\n if (this.paneIcon !== undefined && this._resolvedPaneIconFor !== this.paneIcon) {\n this._resolvedPaneIconFor = this.paneIcon\n this.resolvePaneIcon()\n }\n\n if (!this.titleHeading || !this.fileExplorerContext?.subjectUri || this._draggableSubjectUri === this.fileExplorerContext.subjectUri) return\n\n widgets.makeDraggable(this.titleHeading, sym(this.fileExplorerContext.subjectUri)) // doing it this way for now, just to keep the same functionality\n this._draggableSubjectUri = this.fileExplorerContext.subjectUri\n }\n\n // Needed because humanReadable pane can return a promise for an icon.\n private async resolvePaneIcon () {\n try {\n if (this.paneIcon == null) {\n this.resolvedPaneIcon = undefined\n return\n }\n\n const icon = await this.paneIcon\n this.resolvedPaneIcon = icon ?? undefined\n } catch (error) {\n this.resolvedPaneIcon = undefined\n console.warn('file-explorer-header-summary: failed to resolve pane icon', error)\n }\n }\n\n render () {\n const subject = this.fileExplorerContext?.subjectUri ? sym(this.fileExplorerContext.subjectUri) : undefined\n const label = subject ? utils.label(subject) : ''\n const modified = this.formatModifiedDate(this.responseMetadata.modified)\n const isPublic = this.responseMetadata.isPublic\n\n return html`\n <div class=\"file-explorer-header-summary\">\n <solid-ui-button\n variant=\"ghost\"\n @click=${this.onBackClick}\n title=\"Back\"\n >\n <icon-lucide-arrow-left></icon-lucide-arrow-left>\n </solid-ui-button>\n <span class=\"pane-icon\">\n ${this.resolvedPaneIcon ? html`<img src=${this.resolvedPaneIcon} alt=\"\" />` : ''}\n </span>\n <div>\n <h1>${label}</h1>\n <p>${modified} ${isPublic ? html`<span class=\"public\"><icon-lucide-globe></icon-lucide-globe> Public</span>` : html`<span class=\"private\"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole> Private</span>`}</p>\n </div>\n </div>\n `\n }\n}\n"],"mappings":"g/IAU2DY,EAAA,EAAA,EAG1DP,EAAAA,cAAAA,CAAc,8BAA8B,CAAC,EAAA,IAAAQ,EAAA,IAAAC,GAAAC,EAAA,IAAAC,QAAAC,EAAA,IAAAD,QAAAE,EAAA,IAAAF,QAAAG,EAAA,IAAAH,QAAAI,EAAA,IAAAJ,QAAAK,EAAA,IAAAL,QAAAM,GAAAC,GAAAA,EAO3Cb,EAAAA,QAAAA,CAAQ,CAAEc,QAASpB,EAAAA,oBAAqBqB,UAAW,EAAK,CAAC,EAACC,GAAAA,EAG1DpB,EAAAA,SAAAA,CAAS,CAAEqB,UAAW,EAAM,CAAC,EAACC,GAAAA,EAG9BtB,EAAAA,SAAAA,CAAS,CAAEqB,UAAW,EAAM,CAAC,EAACE,GAAAA,EAG9BvB,EAAAA,SAAAA,CAAS,CAAEqB,UAAW,EAAM,CAAC,EAACG,GAAAA,EAM9BtB,EAAAA,MAAAA,CAAM,EAACuB,GAAAA,EAGPxB,EAAAA,MAAAA,CAAM,IAAI,EAAC,wBAAAyB,EAzBd,cACuD7B,EAAAA,YAAa,CAAA+B,YAAA,GAAAC,EAAA,CAAA,MAAA,GAAAA,CAAA,EAAAC,EAAA,KAAAd,EAAA,KAAAe,EAAA,IAAA,CAAA,EAAAD,EAAA,KAAA,uBAAA,IAAA,EAAA,EAAAE,EAAA,KAAAvB,EAAAwB,EAAA,KAOdC,IAAAA,EAAS,CAAA,EAAAF,EAAA,KAAArB,EAAAwB,EAAA,IAAA,CAAA,EAAAH,EAAA,KAAApB,EAAAwB,EAAA,IAAA,CAAA,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AO,EAAI,GACzC9C,EAAW,KAAKY,mBAAmB,KAAKH,iBAAiBT,QAAQ,EACjEC,EAAW,KAAKQ,iBAAiBR,SAEvC,MAAOpC,GAAAA,IAAI;;;;mBAII,KAAK2C,YAAW;;;;;;YAMvB,KAAKE,iBAAmB7C,EAAAA,IAAI,YAAY,KAAK6C,iBAAgB,YAAe,GAAE;;;gBAG1EqC,EAAK;eACN/C,EAAQ,GAAIC,EAAWpC,EAAAA,IAAI,6EAA+EA,EAAAA,IAAI,6FAA4F;;;KAIvN,CACF,EAAC,CAAAmF,EAAA,CAAArD,EAAAE,EAAAC,EAAAC,EAAAG,EAAAC,EAAAV,GAAAwD,EAAA,CAAAhF,EAAAiF,IAAAC,EAAA/D,EAAA,CAAA,CAAAT,EAAA,EAAA,qBAAA,EAAA,CAAAG,EAAA,EAAA,UAAA,EAAA,CAAAE,EAAA,EAAA,aAAA,EAAA,CAAAC,EAAA,EAAA,kBAAA,EAAA,CAAAC,EAAA,EAAA,kBAAA,EAAA,CAAAC,EAAA,EAAA,cAAA,CAAA,EAAAnB,EAAA,EAAA,IAAA,GA1GsDT,EAAAA,YAAY,EAAA6B,GAAAgE,EAAA,cAAAC,CAAA,CAAA/D,aAAA,CAAA,MAAArB,CAAA,EAAAuB,EAAA,KAAA,SACjDzB,EAAAA,OAAM,EAAAmF,EAAA,CAAA,CAAA,EAAA1D,EAAA4D,EAAAlF,EAAA,IAAA,EAAA,EAAAkF"}
|
|
1
|
+
{"version":3,"file":"FileExplorerHeaderSummary.cjs.js","names":["sym","widgets","utils","WebComponent","fileExplorerContext","customElement","property","query","state","html","consume","styles","getContainerItemCount","isContainerSubject","_classDecs","_FileExplorerHeaderSu","_FileExplorerHeaderSu2","_A","WeakMap","_B","_C","_D","_E","_F","_ref","_fileExplorerContextDecs","context","subscribe","_paneIconDecs","attribute","_onBackClickDecs","_responseMetadataDecs","_resolvedPaneIconDecs","_titleHeadingDecs","_FileExplorerHeaderSummary","FileExplorerHeaderSummary","constructor","args","_defineProperty","_initProto","_classPrivateFieldInitSpec","_init_fileExplorerContext","undefined","_init_paneIcon","_init_onBackClick","_init_responseMetadata","modified","isPublic","_init_resolvedPaneIcon","_init_titleHeading","_classPrivateFieldGet","v","_classPrivateFieldSet","paneIcon","onBackClick","responseMetadata","resolvedPaneIcon","titleHeading","formatModifiedDate","date","Date","Number","isNaN","getTime","parts","Intl","DateTimeFormat","day","month","year","hour","minute","hour12","formatToParts","getPart","type","find","part","value","dayPeriod","toUpperCase","updated","_resolvedPaneIconFor","resolvePaneIcon","subjectUri","_draggableSubjectUri","makeDraggable","icon","error","console","warn","renderContainerResourceHeader","label","itemCount","store","renderResourceHeader","render","subject","isContainerResource","e","c","_initClass","_applyDecs","_Class","_identity","default","customElement","consume","fileExplorerContext","property","state","query","WebComponent","sym","getContainerItemCount","utils","isContainerSubject","styles","require_podUtils","require_FileExplorerHeaderSummary_styles","solid_ui","rdflib","lit_decorators_js","_lit_context","lit","_Class","_FileExplorerHeaderSummary","_A","_B","_C","_D","_E","_F","_initProto","_initClass","_classDecs","_fileExplorerContextDecs","_init_fileExplorerContext","_paneIconDecs","_init_paneIcon","_onBackClickDecs","_init_onBackClick","_responseMetadataDecs","_init_responseMetadata","_resolvedPaneIconDecs","_init_resolvedPaneIcon","_titleHeadingDecs","_init_titleHeading","_FileExplorerHeaderSu2","_ref","_classPrivateFieldInitSpec","_checkPrivateRedeclaration","a","_classPrivateFieldSet","s","_assertClassBrand","r","_classPrivateFieldGet","_defineProperty","_toPropertyKey","t","_applyDecs","i","n","o","c","applyDec","m","h","y","v","g","b","u","w","S","A","d","f","p","_setFunctionName","P","j","D","I","F","l","N","_checkInRHS","_toPrimitive","e","_identity","_FileExplorerHeaderSu","args","modified","date","parts","getPart","part","type","icon","error","itemCount","label","isPublic","subject","isContainerResource"],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.ts"],"sourcesContent":["import { sym } from 'rdflib'\nimport { widgets, utils, WebComponent, fileExplorerContext, type FileExplorerContext } from 'solid-ui'\nimport 'solid-ui/components/button'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { html } from 'lit'\nimport { consume } from '@lit/context'\nimport { PaneIcon } from './types'\nimport '~icons/lucide/globe'\nimport '~icons/lucide/lock-keyhole'\nimport '~icons/lucide/arrow-left'\nimport '~icons/lucide/folder'\nimport styles from './FileExplorerHeaderSummary.styles.css'\nimport { getContainerItemCount, isContainerSubject } from '../../utils/podUtils'\nimport type { FileExplorerResourceMetadata } from './types'\n\n@customElement('file-explorer-header-summary')\nexport default class FileExplorerHeaderSummary extends WebComponent {\n static styles = styles\n\n private _draggableSubjectUri: string | undefined\n private _resolvedPaneIconFor: PaneIcon | undefined\n\n @consume({ context: fileExplorerContext, subscribe: true })\n accessor fileExplorerContext: FileExplorerContext = undefined as unknown as FileExplorerContext\n\n @property({ attribute: false })\n accessor paneIcon: PaneIcon | undefined\n\n @property({ attribute: false })\n accessor onBackClick: (() => void) | undefined\n\n @property({ attribute: false })\n accessor responseMetadata: Pick<FileExplorerResourceMetadata, 'modified' | 'isPublic'> = {\n modified: undefined,\n isPublic: false\n }\n\n @state()\n accessor resolvedPaneIcon: string | undefined = undefined\n\n @query('h1')\n private accessor titleHeading: HTMLHeadingElement | null = null\n\n private formatModifiedDate (modified: string | undefined) {\n if (!modified) return ''\n\n const date = new Date(modified)\n if (Number.isNaN(date.getTime())) return modified\n\n const parts = new Intl.DateTimeFormat('en-GB', {\n day: '2-digit',\n month: 'short',\n year: 'numeric',\n hour: '2-digit',\n minute: '2-digit',\n hour12: true\n }).formatToParts(date)\n\n const getPart = (type: Intl.DateTimeFormatPartTypes) => parts.find(part => part.type === type)?.value ?? ''\n const day = getPart('day')\n const month = getPart('month')\n const year = getPart('year')\n const hour = getPart('hour')\n const minute = getPart('minute')\n const dayPeriod = getPart('dayPeriod').toUpperCase()\n\n return `${day} ${month}, ${year} at ${hour}:${minute} ${dayPeriod}`\n }\n\n protected updated () {\n if (this.paneIcon !== undefined && this._resolvedPaneIconFor !== this.paneIcon) {\n this._resolvedPaneIconFor = this.paneIcon\n this.resolvePaneIcon()\n }\n\n if (!this.titleHeading || !this.fileExplorerContext?.subjectUri || this._draggableSubjectUri === this.fileExplorerContext.subjectUri) return\n\n widgets.makeDraggable(this.titleHeading, sym(this.fileExplorerContext.subjectUri)) // doing it this way for now, just to keep the same functionality\n this._draggableSubjectUri = this.fileExplorerContext.subjectUri\n }\n\n // Needed because humanReadable pane can return a promise for an icon.\n private async resolvePaneIcon () {\n try {\n if (this.paneIcon == null) {\n this.resolvedPaneIcon = undefined\n return\n }\n\n const icon = await this.paneIcon\n this.resolvedPaneIcon = icon ?? undefined\n } catch (error) {\n this.resolvedPaneIcon = undefined\n console.warn('file-explorer-header-summary: failed to resolve pane icon', error)\n }\n }\n\n private renderContainerResourceHeader (label: string, isPublic: boolean) {\n const itemCount = getContainerItemCount(this.fileExplorerContext?.store, this.fileExplorerContext?.subjectUri) ?? 0\n return html`\n <div class=\"container-info\">\n <h1>\n <span>${label}</span>\n </h1>\n <p>\n ${itemCount} items\n ${isPublic\n ? html`<span class=\"public\"><icon-lucide-globe></icon-lucide-globe></span>`\n : html`<span class=\"private\"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole></span>`}\n </p>\n </div>\n `\n }\n\n private renderResourceHeader (label: string, isPublic: boolean) {\n const modified = this.formatModifiedDate(this.responseMetadata.modified)\n\n return html`\n <div class=\"resource-info\">\n <h1>\n <span>${label}</span>\n </h1>\n <p><span class=\"resource-date\">${modified}</span> ${isPublic ? html`<span class=\"public\"><icon-lucide-globe></icon-lucide-globe> Public</span>` : html`<span class=\"private\"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole> Private</span>`}</p>\n </div>\n `\n }\n\n render () {\n const subject = this.fileExplorerContext?.subjectUri ? sym(this.fileExplorerContext.subjectUri) : undefined\n const label = subject ? utils.label(subject) : ''\n const isPublic = this.responseMetadata.isPublic\n const isContainerResource = isContainerSubject(this.fileExplorerContext?.store, this.fileExplorerContext?.subjectUri)\n\n return html`\n <div class=\"file-explorer-header-summary\">\n <solid-ui-button\n variant=\"ghost\"\n @click=${this.onBackClick}\n title=\"Back\"\n >\n <icon-lucide-arrow-left></icon-lucide-arrow-left>\n </solid-ui-button>\n <span class=\"pane-icon\">\n ${this.resolvedPaneIcon ? html`<img src=${this.resolvedPaneIcon} alt=\"\" />` : ''}\n </span>\n ${isContainerResource ? this.renderContainerResourceHeader(label, isPublic) : this.renderResourceHeader(label, isPublic)}\n </div>\n </div>\n `\n }\n}\n"],"mappings":"qlJAYgFc,EAAA,EAAA,EAG/ET,EAAAA,cAAAA,CAAc,8BAA8B,CAAC,EAAA,IAAAU,EAAA,IAAAC,GAAAC,EAAA,IAAAC,QAAAC,EAAA,IAAAD,QAAAE,EAAA,IAAAF,QAAAG,EAAA,IAAAH,QAAAI,EAAA,IAAAJ,QAAAK,EAAA,IAAAL,QAAAM,GAAAC,GAAAA,EAO3Cf,EAAAA,QAAAA,CAAQ,CAAEgB,QAAStB,EAAAA,oBAAqBuB,UAAW,EAAK,CAAC,EAACC,GAAAA,EAG1DtB,EAAAA,SAAAA,CAAS,CAAEuB,UAAW,EAAM,CAAC,EAACC,GAAAA,EAG9BxB,EAAAA,SAAAA,CAAS,CAAEuB,UAAW,EAAM,CAAC,EAACE,GAAAA,EAG9BzB,EAAAA,SAAAA,CAAS,CAAEuB,UAAW,EAAM,CAAC,EAACG,GAAAA,EAM9BxB,EAAAA,MAAAA,CAAM,EAACyB,GAAAA,EAGP1B,EAAAA,MAAAA,CAAM,IAAI,EAAC,wBAAA2B,EAzBd,cACuD/B,EAAAA,YAAa,CAAAiC,YAAA,GAAAC,EAAA,CAAA,MAAA,GAAAA,CAAA,EAAAC,EAAA,KAAAd,EAAA,KAAAe,EAAA,IAAA,CAAA,EAAAD,EAAA,KAAA,uBAAA,IAAA,EAAA,EAAAE,EAAA,KAAAvB,EAAAwB,EAAA,KAOdC,IAAAA,EAAS,CAAA,EAAAF,EAAA,K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AAA,EAAAnB,EAAA,EAAA,IAAA,GAtIsDX,EAAAA,YAAY,EAAA+B,GAAAqE,EAAA,cAAAC,CAAA,CAAApE,aAAA,CAAA,MAAArB,CAAA,EAAAuB,EAAA,KAAA,SACjD3B,EAAAA,OAAM,EAAA0F,EAAA,CAAA,CAAA,EAAA/D,EAAAiE,EAAAvF,EAAA,IAAA,EAAA,EAAAuF"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { WebComponent, FileExplorerContext } from 'solid-ui';
|
|
2
|
-
import { PaneIcon } from './types';
|
|
3
|
-
import { FileExplorerResourceMetadata } from './helper';
|
|
2
|
+
import { PaneIcon, FileExplorerResourceMetadata } from './types';
|
|
4
3
|
export default class FileExplorerHeaderSummary extends WebComponent {
|
|
5
4
|
static styles: any;
|
|
6
5
|
private _draggableSubjectUri;
|
|
@@ -14,6 +13,8 @@ export default class FileExplorerHeaderSummary extends WebComponent {
|
|
|
14
13
|
private formatModifiedDate;
|
|
15
14
|
protected updated(): void;
|
|
16
15
|
private resolvePaneIcon;
|
|
16
|
+
private renderContainerResourceHeader;
|
|
17
|
+
private renderResourceHeader;
|
|
17
18
|
render(): import('lit-html').TemplateResult<1>;
|
|
18
19
|
}
|
|
19
20
|
//# sourceMappingURL=FileExplorerHeaderSummary.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileExplorerHeaderSummary.d.ts","sourceRoot":"","sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.ts"],"names":[],"mappings":"AACA,OAAO,EAAkB,YAAY,EAAuB,KAAK,mBAAmB,EAAE,MAAM,UAAU,CAAA;AACtG,OAAO,4BAA4B,CAAA;AAInC,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AAClC,OAAO,qBAAqB,CAAA;AAC5B,OAAO,4BAA4B,CAAA;AACnC,OAAO,0BAA0B,CAAA;
|
|
1
|
+
{"version":3,"file":"FileExplorerHeaderSummary.d.ts","sourceRoot":"","sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.ts"],"names":[],"mappings":"AACA,OAAO,EAAkB,YAAY,EAAuB,KAAK,mBAAmB,EAAE,MAAM,UAAU,CAAA;AACtG,OAAO,4BAA4B,CAAA;AAInC,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AAClC,OAAO,qBAAqB,CAAA;AAC5B,OAAO,4BAA4B,CAAA;AACnC,OAAO,0BAA0B,CAAA;AACjC,OAAO,sBAAsB,CAAA;AAG7B,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,SAAS,CAAA;AAG3D,MAAM,CAAC,OAAO,OAAO,yBAA0B,SAAQ,YAAY;IACjE,MAAM,CAAC,MAAM,MAAS;IAEtB,OAAO,CAAC,oBAAoB,CAAoB;IAChD,OAAO,CAAC,oBAAoB,CAAsB;IAGlD,QAAQ,CAAC,mBAAmB,EAAE,mBAAmB,CAA8C;IAG/F,QAAQ,CAAC,QAAQ,EAAE,QAAQ,GAAG,SAAS,CAAA;IAGvC,QAAQ,CAAC,WAAW,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAA;IAG9C,QAAQ,CAAC,gBAAgB,EAAE,IAAI,CAAC,4BAA4B,EAAE,UAAU,GAAG,UAAU,CAAC,CAGrF;IAGD,QAAQ,CAAC,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAY;IAGzD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAkC;IAE/D,OAAO,CAAC,kBAAkB;IA0B1B,SAAS,CAAC,OAAO;YAaH,eAAe;IAe7B,OAAO,CAAC,6BAA6B;IAiBrC,OAAO,CAAC,oBAAoB;IAa5B,MAAM;CAuBP"}
|
|
@@ -1,40 +1,42 @@
|
|
|
1
|
+
import { getContainerItemCount as e, isContainerSubject as t } from "../../utils/podUtils.esm.js";
|
|
1
2
|
import "../../_virtual/~icons/lucide/globe.esm.js";
|
|
2
3
|
import "../../_virtual/~icons/lucide/lock-keyhole.esm.js";
|
|
3
4
|
import "../../_virtual/~icons/lucide/arrow-left.esm.js";
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { consume as s } from "@lit/context";
|
|
5
|
+
import "../../_virtual/~icons/lucide/folder.esm.js";
|
|
6
|
+
import n from "./FileExplorerHeaderSummary.styles.esm.js";
|
|
7
|
+
import { WebComponent as r, fileExplorerContext as i, utils as a, widgets as o } from "solid-ui";
|
|
8
|
+
import { sym as s } from "rdflib";
|
|
9
9
|
import { customElement as c, property as l, query as u, state as d } from "lit/decorators.js";
|
|
10
|
+
import { consume as f } from "@lit/context";
|
|
11
|
+
import { html as p } from "lit";
|
|
10
12
|
import "solid-ui/components/button";
|
|
11
13
|
//#region src/components/file-explorer-header/FileExplorerHeaderSummary.ts
|
|
12
|
-
var
|
|
13
|
-
function L(e, t, n) {
|
|
14
|
-
R(e, t), t.set(e, n);
|
|
15
|
-
}
|
|
16
|
-
function R(e, t) {
|
|
17
|
-
if (t.has(e)) throw TypeError("Cannot initialize the same private elements twice on an object");
|
|
18
|
-
}
|
|
14
|
+
var m, h, g, _, v, y, b, x, S, C, w, T, E, D, O, k, A, j, M, N, P, F, I, L, R;
|
|
19
15
|
function z(e, t, n) {
|
|
20
|
-
|
|
16
|
+
B(e, t), t.set(e, n);
|
|
21
17
|
}
|
|
22
18
|
function B(e, t) {
|
|
23
|
-
|
|
19
|
+
if (t.has(e)) throw TypeError("Cannot initialize the same private elements twice on an object");
|
|
24
20
|
}
|
|
25
21
|
function V(e, t, n) {
|
|
22
|
+
return e.set(U(e, t), n), n;
|
|
23
|
+
}
|
|
24
|
+
function H(e, t) {
|
|
25
|
+
return e.get(U(e, t));
|
|
26
|
+
}
|
|
27
|
+
function U(e, t, n) {
|
|
26
28
|
if (typeof e == "function" ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
|
|
27
29
|
throw TypeError("Private element is not present on this object");
|
|
28
30
|
}
|
|
29
|
-
function
|
|
30
|
-
return (t =
|
|
31
|
+
function W(e, t, n) {
|
|
32
|
+
return (t = K(t)) in e ? Object.defineProperty(e, t, {
|
|
31
33
|
value: n,
|
|
32
34
|
enumerable: !0,
|
|
33
35
|
configurable: !0,
|
|
34
36
|
writable: !0
|
|
35
37
|
}) : e[t] = n, e;
|
|
36
38
|
}
|
|
37
|
-
function
|
|
39
|
+
function G(e, t, n, r, i, a) {
|
|
38
40
|
function o(e, t, n) {
|
|
39
41
|
return function(r, i) {
|
|
40
42
|
return n && n(r), e[t].call(r, i);
|
|
@@ -57,13 +59,13 @@ function U(e, t, n, r, i, a) {
|
|
|
57
59
|
n || Array.isArray(_) || (_ = [_]);
|
|
58
60
|
var b = {}, x = [], S = i === 3 ? "get" : i === 4 || p ? "set" : "value";
|
|
59
61
|
d ? (f || p ? b = {
|
|
60
|
-
get:
|
|
62
|
+
get: J(function() {
|
|
61
63
|
return v(this);
|
|
62
64
|
}, r, "get"),
|
|
63
65
|
set: function(e) {
|
|
64
66
|
t[4](this, e);
|
|
65
67
|
}
|
|
66
|
-
} : b[S] = v, f ||
|
|
68
|
+
} : b[S] = v, f || J(b[S], r, i === 2 ? "" : S)) : f || (b = Object.getOwnPropertyDescriptor(e, r));
|
|
67
69
|
}
|
|
68
70
|
for (var C = e, w = _.length - 1; w >= 0; w -= n ? 2 : 1) {
|
|
69
71
|
var T = _[w], E = n ? _[w - 1] : void 0, D = {}, O = {
|
|
@@ -123,7 +125,7 @@ function U(e, t, n, r, i, a) {
|
|
|
123
125
|
if (arguments.length >= 6) var d = a[Symbol.metadata || Symbol.for("Symbol.metadata")];
|
|
124
126
|
var f = Object.create(d ?? null), p = function(e, t, n, r) {
|
|
125
127
|
var i, a, o = [], c = function(t) {
|
|
126
|
-
return
|
|
128
|
+
return Y(t) === e;
|
|
127
129
|
}, u = /* @__PURE__ */ new Map();
|
|
128
130
|
function d(e) {
|
|
129
131
|
e && o.push(s.bind(null, e));
|
|
@@ -137,7 +139,7 @@ function U(e, t, n, r, i, a) {
|
|
|
137
139
|
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);
|
|
138
140
|
u.set(b, !(m > 2) || m);
|
|
139
141
|
}
|
|
140
|
-
l(v ? e : e.prototype, p, _, g ? "#" + h :
|
|
142
|
+
l(v ? e : e.prototype, p, _, g ? "#" + h : K(h), m, r, v ? a ||= [] : i ||= [], o, v, g, y, m === 1, v && g ? c : n);
|
|
141
143
|
}
|
|
142
144
|
}
|
|
143
145
|
return d(i), d(a), o;
|
|
@@ -150,11 +152,11 @@ function U(e, t, n, r, i, a) {
|
|
|
150
152
|
}
|
|
151
153
|
};
|
|
152
154
|
}
|
|
153
|
-
function
|
|
154
|
-
var t =
|
|
155
|
+
function K(e) {
|
|
156
|
+
var t = q(e, "string");
|
|
155
157
|
return typeof t == "symbol" ? t : t + "";
|
|
156
158
|
}
|
|
157
|
-
function
|
|
159
|
+
function q(e, t) {
|
|
158
160
|
if (typeof e != "object" || !e) return e;
|
|
159
161
|
var n = e[Symbol.toPrimitive];
|
|
160
162
|
if (n !== void 0) {
|
|
@@ -164,7 +166,7 @@ function G(e, t) {
|
|
|
164
166
|
}
|
|
165
167
|
return (t === "string" ? String : Number)(e);
|
|
166
168
|
}
|
|
167
|
-
function
|
|
169
|
+
function J(e, t, n) {
|
|
168
170
|
typeof t == "symbol" && (t = (t = t.description) ? "[" + t + "]" : "");
|
|
169
171
|
try {
|
|
170
172
|
Object.defineProperty(e, "name", {
|
|
@@ -174,60 +176,60 @@ function K(e, t, n) {
|
|
|
174
176
|
} catch {}
|
|
175
177
|
return e;
|
|
176
178
|
}
|
|
177
|
-
function
|
|
179
|
+
function Y(e) {
|
|
178
180
|
if (Object(e) !== e) throw TypeError("right-hand side of 'in' should be an object, got " + (e === null ? "null" : typeof e));
|
|
179
181
|
return e;
|
|
180
182
|
}
|
|
181
|
-
function
|
|
183
|
+
function X(e) {
|
|
182
184
|
return e;
|
|
183
185
|
}
|
|
184
|
-
|
|
185
|
-
var
|
|
186
|
-
new (
|
|
187
|
-
context:
|
|
186
|
+
w = [c("file-explorer-header-summary")];
|
|
187
|
+
var Z;
|
|
188
|
+
new (L = (g = /*#__PURE__*/ new WeakMap(), _ = /*#__PURE__*/ new WeakMap(), v = /*#__PURE__*/ new WeakMap(), y = /*#__PURE__*/ new WeakMap(), b = /*#__PURE__*/ new WeakMap(), x = /*#__PURE__*/ new WeakMap(), R = (T = f({
|
|
189
|
+
context: i,
|
|
188
190
|
subscribe: !0
|
|
189
|
-
}),
|
|
191
|
+
}), D = l({ attribute: !1 }), k = l({ attribute: !1 }), j = l({ attribute: !1 }), N = d(), F = u("h1"), "_draggableSubjectUri"), h = class extends r {
|
|
190
192
|
constructor(...e) {
|
|
191
|
-
super(...e),
|
|
193
|
+
super(...e), W(this, R, void S(this)), W(this, "_resolvedPaneIconFor", void 0), z(this, g, E(this, void 0)), z(this, _, O(this)), z(this, v, A(this)), z(this, y, M(this, {
|
|
192
194
|
modified: void 0,
|
|
193
195
|
isPublic: !1
|
|
194
|
-
})),
|
|
196
|
+
})), z(this, b, P(this, void 0)), z(this, x, I(this, null));
|
|
195
197
|
}
|
|
196
198
|
get fileExplorerContext() {
|
|
197
|
-
return
|
|
199
|
+
return H(g, this);
|
|
198
200
|
}
|
|
199
201
|
set fileExplorerContext(e) {
|
|
200
|
-
|
|
202
|
+
V(g, this, e);
|
|
201
203
|
}
|
|
202
204
|
get paneIcon() {
|
|
203
|
-
return
|
|
205
|
+
return H(_, this);
|
|
204
206
|
}
|
|
205
207
|
set paneIcon(e) {
|
|
206
|
-
|
|
208
|
+
V(_, this, e);
|
|
207
209
|
}
|
|
208
210
|
get onBackClick() {
|
|
209
|
-
return
|
|
211
|
+
return H(v, this);
|
|
210
212
|
}
|
|
211
213
|
set onBackClick(e) {
|
|
212
|
-
|
|
214
|
+
V(v, this, e);
|
|
213
215
|
}
|
|
214
216
|
get responseMetadata() {
|
|
215
|
-
return
|
|
217
|
+
return H(y, this);
|
|
216
218
|
}
|
|
217
219
|
set responseMetadata(e) {
|
|
218
|
-
|
|
220
|
+
V(y, this, e);
|
|
219
221
|
}
|
|
220
222
|
get resolvedPaneIcon() {
|
|
221
|
-
return
|
|
223
|
+
return H(b, this);
|
|
222
224
|
}
|
|
223
225
|
set resolvedPaneIcon(e) {
|
|
224
|
-
|
|
226
|
+
V(b, this, e);
|
|
225
227
|
}
|
|
226
228
|
get titleHeading() {
|
|
227
|
-
return
|
|
229
|
+
return H(x, this);
|
|
228
230
|
}
|
|
229
231
|
set titleHeading(e) {
|
|
230
|
-
|
|
232
|
+
V(x, this, e);
|
|
231
233
|
}
|
|
232
234
|
formatModifiedDate(e) {
|
|
233
235
|
if (!e) return "";
|
|
@@ -244,7 +246,7 @@ new (F = (m = /*#__PURE__*/ new WeakMap(), h = /*#__PURE__*/ new WeakMap(), g =
|
|
|
244
246
|
return `${r("day")} ${r("month")}, ${r("year")} at ${r("hour")}:${r("minute")} ${r("dayPeriod").toUpperCase()}`;
|
|
245
247
|
}
|
|
246
248
|
updated() {
|
|
247
|
-
this.paneIcon !== void 0 && this._resolvedPaneIconFor !== this.paneIcon && (this._resolvedPaneIconFor = this.paneIcon, this.resolvePaneIcon()),
|
|
249
|
+
this.paneIcon !== void 0 && this._resolvedPaneIconFor !== this.paneIcon && (this._resolvedPaneIconFor = this.paneIcon, this.resolvePaneIcon()), this.titleHeading && this.fileExplorerContext?.subjectUri && this._draggableSubjectUri !== this.fileExplorerContext.subjectUri && (o.makeDraggable(this.titleHeading, s(this.fileExplorerContext.subjectUri)), this._draggableSubjectUri = this.fileExplorerContext.subjectUri);
|
|
248
250
|
}
|
|
249
251
|
async resolvePaneIcon() {
|
|
250
252
|
try {
|
|
@@ -258,9 +260,34 @@ new (F = (m = /*#__PURE__*/ new WeakMap(), h = /*#__PURE__*/ new WeakMap(), g =
|
|
|
258
260
|
this.resolvedPaneIcon = void 0, console.warn("file-explorer-header-summary: failed to resolve pane icon", e);
|
|
259
261
|
}
|
|
260
262
|
}
|
|
263
|
+
renderContainerResourceHeader(t, n) {
|
|
264
|
+
let r = e(this.fileExplorerContext?.store, this.fileExplorerContext?.subjectUri) ?? 0;
|
|
265
|
+
return p`
|
|
266
|
+
<div class="container-info">
|
|
267
|
+
<h1>
|
|
268
|
+
<span>${t}</span>
|
|
269
|
+
</h1>
|
|
270
|
+
<p>
|
|
271
|
+
${r} items
|
|
272
|
+
${n ? p`<span class="public"><icon-lucide-globe></icon-lucide-globe></span>` : p`<span class="private"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole></span>`}
|
|
273
|
+
</p>
|
|
274
|
+
</div>
|
|
275
|
+
`;
|
|
276
|
+
}
|
|
277
|
+
renderResourceHeader(e, t) {
|
|
278
|
+
let n = this.formatModifiedDate(this.responseMetadata.modified);
|
|
279
|
+
return p`
|
|
280
|
+
<div class="resource-info">
|
|
281
|
+
<h1>
|
|
282
|
+
<span>${e}</span>
|
|
283
|
+
</h1>
|
|
284
|
+
<p><span class="resource-date">${n}</span> ${t ? p`<span class="public"><icon-lucide-globe></icon-lucide-globe> Public</span>` : p`<span class="private"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole> Private</span>`}</p>
|
|
285
|
+
</div>
|
|
286
|
+
`;
|
|
287
|
+
}
|
|
261
288
|
render() {
|
|
262
|
-
let e = this.fileExplorerContext?.subjectUri ?
|
|
263
|
-
return
|
|
289
|
+
let e = this.fileExplorerContext?.subjectUri ? s(this.fileExplorerContext.subjectUri) : void 0, n = e ? a.label(e) : "", r = this.responseMetadata.isPublic, i = t(this.fileExplorerContext?.store, this.fileExplorerContext?.subjectUri);
|
|
290
|
+
return p`
|
|
264
291
|
<div class="file-explorer-header-summary">
|
|
265
292
|
<solid-ui-button
|
|
266
293
|
variant="ghost"
|
|
@@ -270,52 +297,50 @@ new (F = (m = /*#__PURE__*/ new WeakMap(), h = /*#__PURE__*/ new WeakMap(), g =
|
|
|
270
297
|
<icon-lucide-arrow-left></icon-lucide-arrow-left>
|
|
271
298
|
</solid-ui-button>
|
|
272
299
|
<span class="pane-icon">
|
|
273
|
-
${this.resolvedPaneIcon ?
|
|
300
|
+
${this.resolvedPaneIcon ? p`<img src=${this.resolvedPaneIcon} alt="" />` : ""}
|
|
274
301
|
</span>
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
<p>${n} ${i ? o`<span class="public"><icon-lucide-globe></icon-lucide-globe> Public</span>` : o`<span class="private"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole> Private</span>`}</p>
|
|
278
|
-
</div>
|
|
302
|
+
${i ? this.renderContainerResourceHeader(n, r) : this.renderResourceHeader(n, r)}
|
|
303
|
+
</div>
|
|
279
304
|
</div>
|
|
280
305
|
`;
|
|
281
306
|
}
|
|
282
|
-
}, {e: [
|
|
307
|
+
}, {e: [E, O, A, M, P, I, S], c: [Z, C]} = G(h, [
|
|
283
308
|
[
|
|
284
|
-
|
|
309
|
+
T,
|
|
285
310
|
1,
|
|
286
311
|
"fileExplorerContext"
|
|
287
312
|
],
|
|
288
313
|
[
|
|
289
|
-
|
|
314
|
+
D,
|
|
290
315
|
1,
|
|
291
316
|
"paneIcon"
|
|
292
317
|
],
|
|
293
318
|
[
|
|
294
|
-
|
|
319
|
+
k,
|
|
295
320
|
1,
|
|
296
321
|
"onBackClick"
|
|
297
322
|
],
|
|
298
323
|
[
|
|
299
|
-
|
|
324
|
+
j,
|
|
300
325
|
1,
|
|
301
326
|
"responseMetadata"
|
|
302
327
|
],
|
|
303
328
|
[
|
|
304
|
-
|
|
329
|
+
N,
|
|
305
330
|
1,
|
|
306
331
|
"resolvedPaneIcon"
|
|
307
332
|
],
|
|
308
333
|
[
|
|
309
|
-
|
|
334
|
+
F,
|
|
310
335
|
1,
|
|
311
336
|
"titleHeading"
|
|
312
337
|
]
|
|
313
|
-
],
|
|
338
|
+
], w, 0, void 0, r), h), m = class extends X {
|
|
314
339
|
constructor() {
|
|
315
|
-
super(
|
|
340
|
+
super(Z), W(this, "styles", n), C();
|
|
316
341
|
}
|
|
317
|
-
},
|
|
342
|
+
}, W(m, L, void 0), m)();
|
|
318
343
|
//#endregion
|
|
319
|
-
export {
|
|
344
|
+
export { Z as default };
|
|
320
345
|
|
|
321
346
|
//# sourceMappingURL=FileExplorerHeaderSummary.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileExplorerHeaderSummary.esm.js","names":["sym","widgets","utils","WebComponent","fileExplorerContext","customElement","property","query","state","html","consume","styles","_classDecs","_FileExplorerHeaderSu","_FileExplorerHeaderSu2","_A","WeakMap","_B","_C","_D","_E","_F","_ref","_fileExplorerContextDecs","context","subscribe","_paneIconDecs","attribute","_onBackClickDecs","_responseMetadataDecs","_resolvedPaneIconDecs","_titleHeadingDecs","_FileExplorerHeaderSummary","FileExplorerHeaderSummary","constructor","args","_defineProperty","_initProto","_classPrivateFieldInitSpec","_init_fileExplorerContext","undefined","_init_paneIcon","_init_onBackClick","_init_responseMetadata","modified","isPublic","_init_resolvedPaneIcon","_init_titleHeading","_classPrivateFieldGet","v","_classPrivateFieldSet","paneIcon","onBackClick","responseMetadata","resolvedPaneIcon","titleHeading","formatModifiedDate","date","Date","Number","isNaN","getTime","parts","Intl","DateTimeFormat","day","month","year","hour","minute","hour12","formatToParts","getPart","type","find","part","value","dayPeriod","toUpperCase","updated","_resolvedPaneIconFor","resolvePaneIcon","subjectUri","_draggableSubjectUri","makeDraggable","icon","error","console","warn","render","subject","label","e","c","_initClass","_applyDecs","_Class","_identity","default"],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.ts"],"sourcesContent":["import { sym } from 'rdflib'\nimport { widgets, utils, WebComponent, fileExplorerContext, type FileExplorerContext } from 'solid-ui'\nimport 'solid-ui/components/button'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { html } from 'lit'\nimport { consume } from '@lit/context'\nimport { PaneIcon } from './types'\nimport '~icons/lucide/globe'\nimport '~icons/lucide/lock-keyhole'\nimport '~icons/lucide/arrow-left'\nimport styles from './FileExplorerHeaderSummary.styles.css'\nimport { type FileExplorerResourceMetadata } from './helper'\n\n@customElement('file-explorer-header-summary')\nexport default class FileExplorerHeaderSummary extends WebComponent {\n static styles = styles\n\n private _draggableSubjectUri: string | undefined\n private _resolvedPaneIconFor: PaneIcon | undefined\n\n @consume({ context: fileExplorerContext, subscribe: true })\n accessor fileExplorerContext: FileExplorerContext = undefined as unknown as FileExplorerContext\n\n @property({ attribute: false })\n accessor paneIcon: PaneIcon | undefined\n\n @property({ attribute: false })\n accessor onBackClick: (() => void) | undefined\n\n @property({ attribute: false })\n accessor responseMetadata: Pick<FileExplorerResourceMetadata, 'modified' | 'isPublic'> = {\n modified: undefined,\n isPublic: false\n }\n\n @state()\n accessor resolvedPaneIcon: string | undefined = undefined\n\n @query('h1')\n private accessor titleHeading: HTMLHeadingElement | null = null\n\n private formatModifiedDate (modified: string | undefined) {\n if (!modified) return ''\n\n const date = new Date(modified)\n if (Number.isNaN(date.getTime())) return modified\n\n const parts = new Intl.DateTimeFormat('en-GB', {\n day: '2-digit',\n month: 'short',\n year: 'numeric',\n hour: '2-digit',\n minute: '2-digit',\n hour12: true\n }).formatToParts(date)\n\n const getPart = (type: Intl.DateTimeFormatPartTypes) => parts.find(part => part.type === type)?.value ?? ''\n const day = getPart('day')\n const month = getPart('month')\n const year = getPart('year')\n const hour = getPart('hour')\n const minute = getPart('minute')\n const dayPeriod = getPart('dayPeriod').toUpperCase()\n\n return `${day} ${month}, ${year} at ${hour}:${minute} ${dayPeriod}`\n }\n\n protected updated () {\n if (this.paneIcon !== undefined && this._resolvedPaneIconFor !== this.paneIcon) {\n this._resolvedPaneIconFor = this.paneIcon\n this.resolvePaneIcon()\n }\n\n if (!this.titleHeading || !this.fileExplorerContext?.subjectUri || this._draggableSubjectUri === this.fileExplorerContext.subjectUri) return\n\n widgets.makeDraggable(this.titleHeading, sym(this.fileExplorerContext.subjectUri)) // doing it this way for now, just to keep the same functionality\n this._draggableSubjectUri = this.fileExplorerContext.subjectUri\n }\n\n // Needed because humanReadable pane can return a promise for an icon.\n private async resolvePaneIcon () {\n try {\n if (this.paneIcon == null) {\n this.resolvedPaneIcon = undefined\n return\n }\n\n const icon = await this.paneIcon\n this.resolvedPaneIcon = icon ?? undefined\n } catch (error) {\n this.resolvedPaneIcon = undefined\n console.warn('file-explorer-header-summary: failed to resolve pane icon', error)\n }\n }\n\n render () {\n const subject = this.fileExplorerContext?.subjectUri ? sym(this.fileExplorerContext.subjectUri) : undefined\n const label = subject ? utils.label(subject) : ''\n const modified = this.formatModifiedDate(this.responseMetadata.modified)\n const isPublic = this.responseMetadata.isPublic\n\n return html`\n <div class=\"file-explorer-header-summary\">\n <solid-ui-button\n variant=\"ghost\"\n @click=${this.onBackClick}\n title=\"Back\"\n >\n <icon-lucide-arrow-left></icon-lucide-arrow-left>\n </solid-ui-button>\n <span class=\"pane-icon\">\n ${this.resolvedPaneIcon ? html`<img src=${this.resolvedPaneIcon} alt=\"\" />` : ''}\n </span>\n <div>\n <h1>${label}</h1>\n <p>${modified} ${isPublic ? html`<span class=\"public\"><icon-lucide-globe></icon-lucide-globe> Public</span>` : html`<span class=\"private\"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole> Private</span>`}</p>\n </div>\n </div>\n `\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAU2DY,IAAA,CAG1DP,EAAc,8BAA8B,CAAC;AAAA,IAAAQ;AAAA,KAAAC,KAAAC,kBAAA,IAAAC,QAAA,GAAAC,kBAAA,IAAAD,QAAA,GAAAE,kBAAA,IAAAF,QAAA,GAAAG,kBAA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;CAAA;EAAAC;EAAA;EAAA;CAAA;AAAA,GAAAnB,GAAA,GAAA,KAAA,GA1GsDT,CAAY,GAAA6B,IAAAgE,IAAA,cAAAC,EAAA;CAAA/D,cAAA;EAAA,MAAArB,CAAA,GAAAuB,EAAA,MAAA,UACjDzB,CAAM,GAAAmF,EAAA;CAAA;AAAA,GAAA1D,EAAA4D,GAAAlF,GAAA,KAAA,CAAA,GAAAkF,GAAA"}
|
|
1
|
+
{"version":3,"file":"FileExplorerHeaderSummary.esm.js","names":["sym","widgets","utils","WebComponent","fileExplorerContext","customElement","property","query","state","html","consume","styles","getContainerItemCount","isContainerSubject","_classDecs","_FileExplorerHeaderSu","_FileExplorerHeaderSu2","_A","WeakMap","_B","_C","_D","_E","_F","_ref","_fileExplorerContextDecs","context","subscribe","_paneIconDecs","attribute","_onBackClickDecs","_responseMetadataDecs","_resolvedPaneIconDecs","_titleHeadingDecs","_FileExplorerHeaderSummary","FileExplorerHeaderSummary","constructor","args","_defineProperty","_initProto","_classPrivateFieldInitSpec","_init_fileExplorerContext","undefined","_init_paneIcon","_init_onBackClick","_init_responseMetadata","modified","isPublic","_init_resolvedPaneIcon","_init_titleHeading","_classPrivateFieldGet","v","_classPrivateFieldSet","paneIcon","onBackClick","responseMetadata","resolvedPaneIcon","titleHeading","formatModifiedDate","date","Date","Number","isNaN","getTime","parts","Intl","DateTimeFormat","day","month","year","hour","minute","hour12","formatToParts","getPart","type","find","part","value","dayPeriod","toUpperCase","updated","_resolvedPaneIconFor","resolvePaneIcon","subjectUri","_draggableSubjectUri","makeDraggable","icon","error","console","warn","renderContainerResourceHeader","label","itemCount","store","renderResourceHeader","render","subject","isContainerResource","e","c","_initClass","_applyDecs","_Class","_identity","default","customElement","styles","FileExplorerHeaderSummary_styles_default","customElement$1","_Class","_FileExplorerHeaderSummary","_A","_B","_C","_D","_E","_F","_initProto","_initClass","_classDecs","_fileExplorerContextDecs","_init_fileExplorerContext","_paneIconDecs","_init_paneIcon","_onBackClickDecs","_init_onBackClick","_responseMetadataDecs","_init_responseMetadata","_resolvedPaneIconDecs","_init_resolvedPaneIcon","_titleHeadingDecs","_init_titleHeading","_FileExplorerHeaderSu2","_ref","_classPrivateFieldInitSpec","a","_checkPrivateRedeclaration","_classPrivateFieldSet","s","_assertClassBrand","r","_classPrivateFieldGet","_defineProperty","_toPropertyKey","t","_applyDecs","i","n","o","c","applyDec","m","h","y","v","g","b","u","w","S","A","d","p","_setFunctionName","P","j","D","I","F","l","f","N","_checkInRHS","_toPrimitive","e","_identity","_FileExplorerHeaderSu","consume","fileExplorerContext","property","state","query","WebComponent","args","modified","date","parts","getPart","part","type","widgets","sym","icon","error","itemCount","getContainerItemCount","label","isPublic","subject","utils","isContainerResource","isContainerSubject"],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.ts"],"sourcesContent":["import { sym } from 'rdflib'\nimport { widgets, utils, WebComponent, fileExplorerContext, type FileExplorerContext } from 'solid-ui'\nimport 'solid-ui/components/button'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { html } from 'lit'\nimport { consume } from '@lit/context'\nimport { PaneIcon } from './types'\nimport '~icons/lucide/globe'\nimport '~icons/lucide/lock-keyhole'\nimport '~icons/lucide/arrow-left'\nimport '~icons/lucide/folder'\nimport styles from './FileExplorerHeaderSummary.styles.css'\nimport { getContainerItemCount, isContainerSubject } from '../../utils/podUtils'\nimport type { FileExplorerResourceMetadata } from './types'\n\n@customElement('file-explorer-header-summary')\nexport default class FileExplorerHeaderSummary extends WebComponent {\n static styles = styles\n\n private _draggableSubjectUri: string | undefined\n private _resolvedPaneIconFor: PaneIcon | undefined\n\n @consume({ context: fileExplorerContext, subscribe: true })\n accessor fileExplorerContext: FileExplorerContext = undefined as unknown as FileExplorerContext\n\n @property({ attribute: false })\n accessor paneIcon: PaneIcon | undefined\n\n @property({ attribute: false })\n accessor onBackClick: (() => void) | undefined\n\n @property({ attribute: false })\n accessor responseMetadata: Pick<FileExplorerResourceMetadata, 'modified' | 'isPublic'> = {\n modified: undefined,\n isPublic: false\n }\n\n @state()\n accessor resolvedPaneIcon: string | undefined = undefined\n\n @query('h1')\n private accessor titleHeading: HTMLHeadingElement | null = null\n\n private formatModifiedDate (modified: string | undefined) {\n if (!modified) return ''\n\n const date = new Date(modified)\n if (Number.isNaN(date.getTime())) return modified\n\n const parts = new Intl.DateTimeFormat('en-GB', {\n day: '2-digit',\n month: 'short',\n year: 'numeric',\n hour: '2-digit',\n minute: '2-digit',\n hour12: true\n }).formatToParts(date)\n\n const getPart = (type: Intl.DateTimeFormatPartTypes) => parts.find(part => part.type === type)?.value ?? ''\n const day = getPart('day')\n const month = getPart('month')\n const year = getPart('year')\n const hour = getPart('hour')\n const minute = getPart('minute')\n const dayPeriod = getPart('dayPeriod').toUpperCase()\n\n return `${day} ${month}, ${year} at ${hour}:${minute} ${dayPeriod}`\n }\n\n protected updated () {\n if (this.paneIcon !== undefined && this._resolvedPaneIconFor !== this.paneIcon) {\n this._resolvedPaneIconFor = this.paneIcon\n this.resolvePaneIcon()\n }\n\n if (!this.titleHeading || !this.fileExplorerContext?.subjectUri || this._draggableSubjectUri === this.fileExplorerContext.subjectUri) return\n\n widgets.makeDraggable(this.titleHeading, sym(this.fileExplorerContext.subjectUri)) // doing it this way for now, just to keep the same functionality\n this._draggableSubjectUri = this.fileExplorerContext.subjectUri\n }\n\n // Needed because humanReadable pane can return a promise for an icon.\n private async resolvePaneIcon () {\n try {\n if (this.paneIcon == null) {\n this.resolvedPaneIcon = undefined\n return\n }\n\n const icon = await this.paneIcon\n this.resolvedPaneIcon = icon ?? undefined\n } catch (error) {\n this.resolvedPaneIcon = undefined\n console.warn('file-explorer-header-summary: failed to resolve pane icon', error)\n }\n }\n\n private renderContainerResourceHeader (label: string, isPublic: boolean) {\n const itemCount = getContainerItemCount(this.fileExplorerContext?.store, this.fileExplorerContext?.subjectUri) ?? 0\n return html`\n <div class=\"container-info\">\n <h1>\n <span>${label}</span>\n </h1>\n <p>\n ${itemCount} items\n ${isPublic\n ? html`<span class=\"public\"><icon-lucide-globe></icon-lucide-globe></span>`\n : html`<span class=\"private\"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole></span>`}\n </p>\n </div>\n `\n }\n\n private renderResourceHeader (label: string, isPublic: boolean) {\n const modified = this.formatModifiedDate(this.responseMetadata.modified)\n\n return html`\n <div class=\"resource-info\">\n <h1>\n <span>${label}</span>\n </h1>\n <p><span class=\"resource-date\">${modified}</span> ${isPublic ? html`<span class=\"public\"><icon-lucide-globe></icon-lucide-globe> Public</span>` : html`<span class=\"private\"><icon-lucide-lock-keyhole></icon-lucide-lock-keyhole> Private</span>`}</p>\n </div>\n `\n }\n\n render () {\n const subject = this.fileExplorerContext?.subjectUri ? sym(this.fileExplorerContext.subjectUri) : undefined\n const label = subject ? utils.label(subject) : ''\n const isPublic = this.responseMetadata.isPublic\n const isContainerResource = isContainerSubject(this.fileExplorerContext?.store, this.fileExplorerContext?.subjectUri)\n\n return html`\n <div class=\"file-explorer-header-summary\">\n <solid-ui-button\n variant=\"ghost\"\n @click=${this.onBackClick}\n title=\"Back\"\n >\n <icon-lucide-arrow-left></icon-lucide-arrow-left>\n </solid-ui-button>\n <span class=\"pane-icon\">\n ${this.resolvedPaneIcon ? html`<img src=${this.resolvedPaneIcon} alt=\"\" />` : ''}\n </span>\n ${isContainerResource ? this.renderContainerResourceHeader(label, isPublic) : this.renderResourceHeader(label, isPublic)}\n </div>\n </div>\n `\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAYgFc,IAAA,CAG/ET,EAAc,8BAA8B,CAAC;AAAA,IAAAU;AAAA,KAAAC,KAAAC,kBAAA,IAAAC,QA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1F,qBAAqBgF,UAAU;EAEpH,OAAO3E,CAAI;;;;mBAII,KAAK6C,YAAW;;;;;;YAMvB,KAAKE,mBAAmB/C,CAAI,YAAY,KAAK+C,iBAAgB,cAAe,GAAE;;UAEhF0C,IAAsB,KAAKP,8BAA8BC,GAAO7C,CAAQ,IAAI,KAAKgD,qBAAqBH,GAAO7C,CAAQ,EAAC;;;;CAI9H;AACF,GAAC,CAAAoD,GAAA,CAAA1D,GAAAE,GAAAC,GAAAC,GAAAG,GAAAC,GAAAV,IAAA6D,GAAA,CAAArF,GAAAsF,MAAAC,EAAApE,GAAA;CAAA;EAAAT;EAAA;EAAA;CAAA;CAAA;EAAAG;EAAA;EAAA;CAAA;CAAA;EAAAE;EAAA;EAAA;CAAA;CAAA;EAAAC;EAAA;EAAA;CAAA;CAAA;EAAAC;EAAA;EAAA;CAAA;CAAA;EAAAC;EAAA;EAAA;CAAA;AAAA,GAAAnB,GAAA,GAAA,KAAA,GAtIsDX,CAAY,GAAA+B,IAAAqE,IAAA,cAAAC,EAAA;CAAApE,cAAA;EAAA,MAAArB,CAAA,GAAAuB,EAAA,MAAA,UACjD3B,CAAM,GAAA0F,EAAA;CAAA;AAAA,GAAA/D,EAAAiE,GAAAvF,GAAA,KAAA,CAAA,GAAAuF,GAAA"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var e=require("lit").css`:host .file-explorer-header-summary{text-align:left;flex-wrap:wrap;flex:auto;justify-content:flex-start;align-items:center;gap:6px;min-width:0;display:flex}:host h1{color:var(--solid-ui-color-gray-700,#364153);font-size:var(--solid-ui-font-size-
|
|
1
|
+
var e=require("lit").css`:host .file-explorer-header-summary{text-align:left;flex-wrap:wrap;flex:auto;justify-content:flex-start;align-items:center;gap:6px;min-width:0;display:flex}:host h1{color:var(--solid-ui-color-gray-700,#364153);font-size:var(--solid-ui-font-size-xl,1.25rem);align-items:center;gap:8px;margin:0;font-weight:500;display:flex}:host .resource-info{flex-direction:column;min-width:0;display:flex}:host .container-info{flex-direction:row;gap:10px;min-width:0;display:flex}:host .pane-icon{aspect-ratio:1;justify-content:center;align-items:center;width:40px;height:40px;padding:7.5px 7px 6.5px;display:flex}:host .pane-icon img{object-fit:contain;width:100%;height:100%;display:block}:host p{color:var(--solid-ui-gray-500,#6a7282);font-size:var(--solid-ui-font-size-xs,.75rem);align-items:center;gap:5px;font-weight:500;display:flex}:host .public{color:var(--blue-400,#51a2ff);background:var(--blue-50,#eff6ff);border-radius:5px;justify-content:center;align-items:center;gap:3px;padding:2px 5px;display:flex}:host icon-lucide-globe{stroke-width:1.021px;stroke:var(--blue-400,#51a2ff)}:host .private{color:var(--yellow-600,#d08700);background:var(--yellow-100,#fef9c2);border-radius:5px;justify-content:center;align-items:center;gap:3px;padding:2px 5px;display:flex}:host icon-lucide-lock-keyhole{stroke-width:1.021px;stroke:var(--yellow-600,#d08700)}:host icon-lucide-globe,:host icon-lucide-lock-keyhole{width:.875rem;height:.875rem}:host .resource-date{font-size:inherit}:host icon-lucide-arrow-left{width:1.125rem;height:1.125rem}@media (width<=600px){:host .file-explorer-header-summary{gap:7px}:host h1{font-size:14px}:host .pane-icon{aspect-ratio:1;flex-shrink:0;width:18.2px;height:18.2px;padding:0}:host p{font-size:14px}:host .resource-date{font-size:10px}:host .public,:host .private{font-size:9px}:host icon-lucide-arrow-left{aspect-ratio:5/6;flex-shrink:0;width:15px;height:18px}}`;exports.default=e;
|
|
2
2
|
//# sourceMappingURL=FileExplorerHeaderSummary.styles.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileExplorerHeaderSummary.styles.cjs.js","names":[],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.styles.css"],"sourcesContent":[" :host {\n .file-explorer-header-summary {\n display: flex;\n justify-content: flex-start;\n align-items: center;\n gap: 6px;\n flex-wrap: wrap;\n flex: 1 1 auto;\n min-width: 0;\n text-align: left;\n }\n\n h1 {\n color: var(--solid-ui-color-gray-700, #364153);\n font-size: var(--solid-ui-font-size-
|
|
1
|
+
{"version":3,"file":"FileExplorerHeaderSummary.styles.cjs.js","names":["FileExplorerHeaderSummary_styles_default"],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.styles.css"],"sourcesContent":[" :host {\n .file-explorer-header-summary {\n display: flex;\n justify-content: flex-start;\n align-items: center;\n gap: 6px;\n flex-wrap: wrap;\n flex: 1 1 auto;\n min-width: 0;\n text-align: left;\n }\n\n h1 {\n color: var(--solid-ui-color-gray-700, #364153);\n font-size: var(--solid-ui-font-size-xl, 1.25rem); /* while in expand; will go to 2xl when new design is complete */\n font-weight: 500;\n display: flex;\n align-items: center;\n gap: 8px;\n margin: 0;\n }\n\n .resource-info {\n display: flex;\n flex-direction: column;\n min-width: 0;\n }\n\n .container-info {\n display: flex;\n flex-direction: row;\n gap: 10px;\n min-width: 0;\n }\n\n .pane-icon {\n display: flex;\n width: 40px;\n height: 40px;\n padding: 7.5px 7px 6.5px 7px;\n justify-content: center;\n align-items: center;\n aspect-ratio: 1/1;\n /* border-radius: 100px; */\n /* background: var(--slate-600, #45556C); */\n }\n\n .pane-icon img {\n width: 100%;\n height: 100%;\n object-fit: contain;\n display: block;\n }\n\n p {\n display: flex;\n align-items: center;\n gap: 5px;\n color: var(--solid-ui-gray-500, #6A7282);\n font-size: var(--solid-ui-font-size-xs, .75rem);\n font-weight: 500;\n }\n\n .public {\n display: flex;\n padding: 2px 5px;\n justify-content: center;\n align-items: center;\n gap: 3px;\n color: var(--blue-400, #51A2FF);\n border-radius: 5px;\n background: var(--blue-50, #EFF6FF);\n }\n\n icon-lucide-globe {\n stroke-width: 1.021px;\n stroke: var(--blue-400, #51A2FF);\n }\n\n .private {\n display: flex;\n padding: 2px 5px;\n justify-content: center;\n align-items: center;\n gap: 3px;\n color: var(--yellow-600, #D08700);\n border-radius: 5px;\n background: var(--yellow-100, #FEF9C2);\n }\n\n icon-lucide-lock-keyhole {\n stroke-width: 1.021px;\n stroke: var(--yellow-600, #D08700);\n }\n\n icon-lucide-globe,\n icon-lucide-lock-keyhole {\n width: 0.875rem;\n height: 0.875rem;\n }\n\n .resource-date {\n font-size: inherit;\n }\n\n icon-lucide-arrow-left {\n width: 1.125rem;\n height: 1.125rem;\n }\n\n @media (max-width: 600px) {\n .file-explorer-header-summary {\n gap: 7px;\n }\n\n h1 {\n font-size: 14px;\n }\n\n .pane-icon {\n width: 18.2px;\n height: 18.2px;\n flex-shrink: 0;\n aspect-ratio: 1 / 1;\n padding: 0;\n }\n\n p {\n font-size: 14px;\n }\n\n .resource-date {\n font-size: 10px;\n }\n\n .public,\n .private {\n font-size: 9px;\n }\n\n icon-lucide-arrow-left {\n width: 15px;\n height: 18px;\n flex-shrink: 0;\n aspect-ratio: 5 / 6;\n }\n }\n}\n"],"mappings":""}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { css as e } from "lit";
|
|
2
2
|
//#region src/components/file-explorer-header/FileExplorerHeaderSummary.styles.css
|
|
3
|
-
var t = e`:host .file-explorer-header-summary{text-align:left;flex-wrap:wrap;flex:auto;justify-content:flex-start;align-items:center;gap:6px;min-width:0;display:flex}:host h1{color:var(--solid-ui-color-gray-700,#364153);font-size:var(--solid-ui-font-size-
|
|
3
|
+
var t = e`:host .file-explorer-header-summary{text-align:left;flex-wrap:wrap;flex:auto;justify-content:flex-start;align-items:center;gap:6px;min-width:0;display:flex}:host h1{color:var(--solid-ui-color-gray-700,#364153);font-size:var(--solid-ui-font-size-xl,1.25rem);align-items:center;gap:8px;margin:0;font-weight:500;display:flex}:host .resource-info{flex-direction:column;min-width:0;display:flex}:host .container-info{flex-direction:row;gap:10px;min-width:0;display:flex}:host .pane-icon{aspect-ratio:1;justify-content:center;align-items:center;width:40px;height:40px;padding:7.5px 7px 6.5px;display:flex}:host .pane-icon img{object-fit:contain;width:100%;height:100%;display:block}:host p{color:var(--solid-ui-gray-500,#6a7282);font-size:var(--solid-ui-font-size-xs,.75rem);align-items:center;gap:5px;font-weight:500;display:flex}:host .public{color:var(--blue-400,#51a2ff);background:var(--blue-50,#eff6ff);border-radius:5px;justify-content:center;align-items:center;gap:3px;padding:2px 5px;display:flex}:host icon-lucide-globe{stroke-width:1.021px;stroke:var(--blue-400,#51a2ff)}:host .private{color:var(--yellow-600,#d08700);background:var(--yellow-100,#fef9c2);border-radius:5px;justify-content:center;align-items:center;gap:3px;padding:2px 5px;display:flex}:host icon-lucide-lock-keyhole{stroke-width:1.021px;stroke:var(--yellow-600,#d08700)}:host icon-lucide-globe,:host icon-lucide-lock-keyhole{width:.875rem;height:.875rem}:host .resource-date{font-size:inherit}:host icon-lucide-arrow-left{width:1.125rem;height:1.125rem}@media (width<=600px){:host .file-explorer-header-summary{gap:7px}:host h1{font-size:14px}:host .pane-icon{aspect-ratio:1;flex-shrink:0;width:18.2px;height:18.2px;padding:0}:host p{font-size:14px}:host .resource-date{font-size:10px}:host .public,:host .private{font-size:9px}:host icon-lucide-arrow-left{aspect-ratio:5/6;flex-shrink:0;width:15px;height:18px}}`;
|
|
4
4
|
//#endregion
|
|
5
5
|
export { t as default };
|
|
6
6
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileExplorerHeaderSummary.styles.esm.js","names":[],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.styles.css"],"sourcesContent":[" :host {\n .file-explorer-header-summary {\n display: flex;\n justify-content: flex-start;\n align-items: center;\n gap: 6px;\n flex-wrap: wrap;\n flex: 1 1 auto;\n min-width: 0;\n text-align: left;\n }\n\n h1 {\n color: var(--solid-ui-color-gray-700, #364153);\n font-size: var(--solid-ui-font-size-
|
|
1
|
+
{"version":3,"file":"FileExplorerHeaderSummary.styles.esm.js","names":["FileExplorerHeaderSummary_styles_default"],"sources":["../../../src/components/file-explorer-header/FileExplorerHeaderSummary.styles.css"],"sourcesContent":[" :host {\n .file-explorer-header-summary {\n display: flex;\n justify-content: flex-start;\n align-items: center;\n gap: 6px;\n flex-wrap: wrap;\n flex: 1 1 auto;\n min-width: 0;\n text-align: left;\n }\n\n h1 {\n color: var(--solid-ui-color-gray-700, #364153);\n font-size: var(--solid-ui-font-size-xl, 1.25rem); /* while in expand; will go to 2xl when new design is complete */\n font-weight: 500;\n display: flex;\n align-items: center;\n gap: 8px;\n margin: 0;\n }\n\n .resource-info {\n display: flex;\n flex-direction: column;\n min-width: 0;\n }\n\n .container-info {\n display: flex;\n flex-direction: row;\n gap: 10px;\n min-width: 0;\n }\n\n .pane-icon {\n display: flex;\n width: 40px;\n height: 40px;\n padding: 7.5px 7px 6.5px 7px;\n justify-content: center;\n align-items: center;\n aspect-ratio: 1/1;\n /* border-radius: 100px; */\n /* background: var(--slate-600, #45556C); */\n }\n\n .pane-icon img {\n width: 100%;\n height: 100%;\n object-fit: contain;\n display: block;\n }\n\n p {\n display: flex;\n align-items: center;\n gap: 5px;\n color: var(--solid-ui-gray-500, #6A7282);\n font-size: var(--solid-ui-font-size-xs, .75rem);\n font-weight: 500;\n }\n\n .public {\n display: flex;\n padding: 2px 5px;\n justify-content: center;\n align-items: center;\n gap: 3px;\n color: var(--blue-400, #51A2FF);\n border-radius: 5px;\n background: var(--blue-50, #EFF6FF);\n }\n\n icon-lucide-globe {\n stroke-width: 1.021px;\n stroke: var(--blue-400, #51A2FF);\n }\n\n .private {\n display: flex;\n padding: 2px 5px;\n justify-content: center;\n align-items: center;\n gap: 3px;\n color: var(--yellow-600, #D08700);\n border-radius: 5px;\n background: var(--yellow-100, #FEF9C2);\n }\n\n icon-lucide-lock-keyhole {\n stroke-width: 1.021px;\n stroke: var(--yellow-600, #D08700);\n }\n\n icon-lucide-globe,\n icon-lucide-lock-keyhole {\n width: 0.875rem;\n height: 0.875rem;\n }\n\n .resource-date {\n font-size: inherit;\n }\n\n icon-lucide-arrow-left {\n width: 1.125rem;\n height: 1.125rem;\n }\n\n @media (max-width: 600px) {\n .file-explorer-header-summary {\n gap: 7px;\n }\n\n h1 {\n font-size: 14px;\n }\n\n .pane-icon {\n width: 18.2px;\n height: 18.2px;\n flex-shrink: 0;\n aspect-ratio: 1 / 1;\n padding: 0;\n }\n\n p {\n font-size: 14px;\n }\n\n .resource-date {\n font-size: 10px;\n }\n\n .public,\n .private {\n font-size: 9px;\n }\n\n icon-lucide-arrow-left {\n width: 15px;\n height: 18px;\n flex-shrink: 0;\n aspect-ratio: 5 / 6;\n }\n }\n}\n"],"mappings":""}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
require("./FileExplorerHeader.cjs.js");const e=require("./FileExplorerProvider.styles.cjs.js"),t=require("../../icons/person.cjs.js"),n=require("../../icons/friends.cjs.js");let r=require("solid-ui"),i=require("lit"),a=require("@lit/context"),o=require("lit
|
|
1
|
+
require("../../_virtual/~icons/lucide/share-2.cjs.js"),require("./FileExplorerHeader.cjs.js");const e=require("./FileExplorerProvider.styles.cjs.js"),t=require("../../icons/person.cjs.js"),n=require("../../icons/friends.cjs.js");let r=require("solid-ui"),i=require("lit/decorators.js"),a=require("@lit/context"),o=require("lit");var s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,C,w,T,E,D,O,k,A,j,M,ee,te,ne,re,ie,ae,N,P,F,I,L,R,z,B,V,H,U,W,G,K,q,J,oe,se,ce,le,ue,de,fe;function Y(e,t,n){pe(e,t),t.set(e,n)}function pe(e,t){if(t.has(e))throw TypeError(`Cannot initialize the same private elements twice on an object`)}function X(e,t,n){return e.set(me(e,t),n),n}function Z(e,t){return e.get(me(e,t))}function me(e,t,n){if(typeof e==`function`?e===t:e.has(t))return arguments.length<3?t:n;throw TypeError(`Private element is not present on this object`)}function Q(e,t,n){return(t=ge(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function he(e,t,n,r,i,a){function o(e,t,n){return function(r,i){return n&&n(r),e[t].call(r,i)}}function s(e,t){for(var n=0;n<e.length;n++)e[n].call(t);return t}function c(e,t,n,r){if(typeof e!=`function`&&(r||e!==void 0))throw TypeError(t+` must `+(n||`be`)+` a function`+(r?``:` or undefined`));return e}function l(e,t,n,r,i,a,s,l,u,d,f,p,m){function h(e){if(!m(e))throw TypeError(`Attempted to access private element on non-instance`)}var g,_=t[0],v=t[3],y=!l;if(!y){n||Array.isArray(_)||(_=[_]);var b={},x=[],S=i===3?`get`:i===4||p?`set`:`value`;d?(f||p?b={get:ve(function(){return v(this)},r,`get`),set:function(e){t[4](this,e)}}:b[S]=v,f||ve(b[S],r,i===2?``:S)):f||(b=Object.getOwnPropertyDescriptor(e,r))}for(var C=e,w=_.length-1;w>=0;w-=n?2:1){var T=_[w],E=n?_[w-1]:void 0,D={},O={kind:[`field`,`accessor`,`method`,`getter`,`setter`,`class`][i],name:r,metadata:a,addInitializer:function(e,t){if(e.v)throw Error(`attempted to call addInitializer after decoration was finished`);c(t,`An initializer`,`be`,!0),s.push(t)}.bind(null,D)};try{if(y)(g=c(T.call(E,C,O),`class decorators`,`return`))&&(C=g);else{var k,A;O.static=u,O.private=d,d?i===2?k=function(e){return h(e),b.value}:(i<4&&(k=o(b,`get`,h)),i!==3&&(A=o(b,`set`,h))):(k=function(e){return e[r]},(i<2||i===4)&&(A=function(e,t){e[r]=t}));var j=O.access={has:d?m.bind():function(e){return r in e}};if(k&&(j.get=k),A&&(j.set=A),C=T.call(E,p?{get:b.get,set:b.set}:b[S],O),p){if(typeof C==`object`&&C)(g=c(C.get,`accessor.get`))&&(b.get=g),(g=c(C.set,`accessor.set`))&&(b.set=g),(g=c(C.init,`accessor.init`))&&x.push(g);else if(C!==void 0)throw TypeError(`accessor decorators must return an object with get, set, or init properties or void 0`)}else c(C,(f?`field`:`method`)+` decorators`,`return`)&&(f?x.push(C):b[S]=C)}}finally{D.v=!0}}return(f||p)&&l.push(function(e,t){for(var n=x.length-1;n>=0;n--)t=x[n].call(e,t);return t}),f||y||(d?p?l.push(o(b,`get`),o(b,`set`)):l.push(i===2?b[S]:o.call.bind(b[S])):Object.defineProperty(e,r,b)),C}function u(e,t){return Object.defineProperty(e,Symbol.metadata||Symbol.for(`Symbol.metadata`),{configurable:!0,enumerable:!0,value:t})}if(arguments.length>=6)var d=a[Symbol.metadata||Symbol.for(`Symbol.metadata`)];var f=Object.create(d??null),p=function(e,t,n,r){var i,a,o=[],c=function(t){return ye(t)===e},u=new Map;function d(e){e&&o.push(s.bind(null,e))}for(var f=0;f<t.length;f++){var p=t[f];if(Array.isArray(p)){var m=p[1],h=p[2],g=p.length>3,_=16&m,v=!!(8&m),y=(m&=7)==0,b=h+`/`+v;if(!y&&!g){var x=u.get(b);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);u.set(b,!(m>2)||m)}l(v?e:e.prototype,p,_,g?`#`+h:ge(h),m,r,v?a||=[]:i||=[],o,v,g,y,m===1,v&&g?c:n)}}return d(i),d(a),o}(e,t,i,f);return n.length||u(e,f),{e:p,get c(){var t=[];return n.length&&[u(l(e,[n],r,e.name,5,f,t),f),s.bind(null,t,e)]}}}function ge(e){var t=_e(e,`string`);return typeof t==`symbol`?t:t+``}function _e(e,t){if(typeof e!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(typeof r!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function ve(e,t,n){typeof t==`symbol`&&(t=(t=t.description)?`[`+t+`]`:``);try{Object.defineProperty(e,"name",{configurable:!0,value:n?n+` `+t:t})}catch{}return e}function ye(e){if(Object(e)!==e)throw TypeError(`right-hand side of 'in' should be an object, got `+(e===null?`null`:typeof e));return e}function be(e){return e}var xe=t.default,Se=n.default;function Ce(e){return{store:e.store,subjectUri:e.subjectUri,pane:e.pane,soloPane:e.soloPane,onBack:e.onBack,openPane:e.openPane,handleAccessClick:e.handleAccessClick,paneSupportsEditing:e.paneSupportsEditing,edit:e.edit}}D=[(0,i.customElement)(`file-explorer-provider`)];var $;new(de=(l=new WeakMap,u=new WeakMap,d=new WeakMap,f=new WeakMap,p=new WeakMap,m=new WeakMap,h=new WeakMap,g=new WeakMap,_=new WeakMap,v=new WeakMap,y=new WeakMap,b=new WeakMap,x=new WeakMap,S=new WeakMap,C=new WeakMap,w=new WeakMap,fe=(O=(0,i.property)({attribute:!1}),A=(0,i.property)({attribute:!1}),M=(0,i.property)({attribute:!1}),te=(0,i.property)({attribute:!1}),re=(0,i.property)({attribute:!1}),ae=(0,i.property)({attribute:!1}),P=(0,i.property)({attribute:!1}),I=(0,i.property)({attribute:!1}),R=(0,i.property)({attribute:!1}),B=(0,i.property)({attribute:!1}),H=(0,i.state)(),W=(0,i.state)(),K=(0,i.state)(),J=(0,i.state)(),se=(0,i.state)(),le=(0,a.provide)({context:r.fileExplorerContext}),`context`),c=class extends r.WebComponent{constructor(...e){super(...e),Y(this,l,(T(this),k(this,void 0))),Y(this,u,j(this,void 0)),Y(this,d,ee(this,void 0)),Y(this,f,ne(this,[])),Y(this,p,ie(this,void 0)),Y(this,m,N(this,{})),Y(this,h,F(this,!0)),Y(this,g,L(this,void 0)),Y(this,_,z(this,void 0)),Y(this,v,V(this,void 0)),Y(this,y,U(this,[])),Y(this,b,G(this,!1)),Y(this,x,q(this,!1)),Y(this,S,oe(this,!1)),Q(this,`beginEditingInSourcePane`,()=>{this.querySelector(`source-pane-source-provider`)?.beginEditing?.()}),Y(this,C,ce(this,{onEdit:this.beginEditingInSourcePane,isDirty:!1,updateDirtyState:e=>{this.isDirty!==e&&(this.isDirty=e,this.edit={...this.edit,isDirty:e},this.refreshFileExplorerContextValue())}})),Y(this,w,ue(this,Ce({store:this.context?.session.store,subjectUri:this.subjectUri,pane:this.pane,soloPane:this.soloPane,onBack:this.onBack,openPane:this.openPane,handleAccessClick:this.handleAccessClick,paneSupportsEditing:!1,edit:this.edit})))}get[fe](){return Z(l,this)}set context(e){X(l,this,e)}get subjectUri(){return Z(u,this)}set subjectUri(e){X(u,this,e)}get onBack(){return Z(d,this)}set onBack(e){X(d,this,e)}get relevantPanes(){return Z(f,this)}set relevantPanes(e){X(f,this,e)}get pane(){return Z(p,this)}set pane(e){X(p,this,e)}get paneRenderOptions(){return Z(m,this)}set paneRenderOptions(e){X(m,this,e)}get showHeader(){return Z(h,this)}set showHeader(e){X(h,this,e)}get handleAccessClick(){return Z(g,this)}set handleAccessClick(e){X(g,this,e)}get soloPane(){return Z(_,this)}set soloPane(e){X(_,this,e)}get openPane(){return Z(v,this)}set openPane(e){X(v,this,e)}get menuItems(){return Z(y,this)}set menuItems(e){X(y,this,e)}get isEditing(){return Z(b,this)}set isEditing(e){X(b,this,e)}get isDirty(){return Z(x,this)}set isDirty(e){X(x,this,e)}get paneSupportsEditing(){return Z(S,this)}set paneSupportsEditing(e){X(S,this,e)}get edit(){return Z(C,this)}set edit(e){X(C,this,e)}get fileExplorerContextValue(){return Z(w,this)}set fileExplorerContextValue(e){X(w,this,e)}openSelectedPane(e){this.context?.session.store&&this.subjectUri&&(this.paneSupportsEditing=e.name===`source`,this.pane=e)}getPaneIcon(e,t,n){if(e)return typeof e.icon==`function`?e.icon(t,n):e.icon}async getPaneItems(e,t,n){let i=t.dom;return await Promise.all(n.map(async n=>{let a=n.label(e,t),o=``;o=n.name===`profile`?xe:n.name===`social`?Se:await this.getPaneIcon(n,e,t);let s=r.utils.AJARImage(o,a,a,i);return s.setAttribute(`slot`,`left-icon`),{label:a,icon:s,action:()=>this.openPane?.(e,n.name)}}))}refreshFileExplorerContextValue(){this.fileExplorerContextValue=Ce({store:this.context?.session.store,subjectUri:this.subjectUri,pane:this.pane,soloPane:this.soloPane,onBack:this.onBack,openPane:this.openPane,handleAccessClick:this.handleAccessClick,paneSupportsEditing:this.paneSupportsEditing,edit:this.edit})}async refreshMenuItems(){let e=this.context?.session.store;if(!e||!this.subjectUri)return;let t=e.sym(this.subjectUri),n=await this.getPaneItems(t,this.context,this.relevantPanes);this.menuItems=n}willUpdate(e){if(super.willUpdate(e),!this.context?.session.store)throw Error("The element is missing the required `context.session.store` value. Ensure the `context` property is set.");if(!this.subjectUri)throw Error("The element is missing the required `subjectUri` property.");(e.has(`subjectUri`)||e.has(`relevantPanes`)||e.has(`context`))&&this.refreshMenuItems().catch(e=>{console.warn(`Failed to refresh menu items`,e)}),(e.has(`pane`)||e.has(`subjectUri`)||e.has(`context`))&&(this.paneSupportsEditing=this.pane?.name===`source`),(e.has(`context`)||e.has(`subjectUri`)||e.has(`pane`)||e.has(`soloPane`)||e.has(`onBack`)||e.has(`openPane`)||e.has(`handleAccessClick`)||e.has(`pane`)||e.has(`isDirty`))&&this.refreshFileExplorerContextValue()}render(){let e=(this.context?.session.store).sym(this.subjectUri);return o.html`
|
|
2
2
|
<div class="file-explorer-provider">
|
|
3
|
-
${this.showHeader?
|
|
3
|
+
${this.showHeader?o.html`
|
|
4
4
|
<file-explorer-header
|
|
5
5
|
.paneIcon=${this.getPaneIcon(this.pane,e,this.context)}
|
|
6
6
|
.menuItems=${this.menuItems}
|
|
7
7
|
.paneSupportsEditing=${this.paneSupportsEditing}
|
|
8
8
|
></file-explorer-header>
|
|
9
|
-
`:
|
|
9
|
+
`:o.nothing}
|
|
10
10
|
<slot class="pane"></slot>
|
|
11
11
|
</div>
|
|
12
|
-
`}},{e:[k,j,ee,ne,ie,N,F,L,z,V,U,G,q,oe,ce,ue,T],c:[$,E]}=he(c,[[O,1,`context`],[A,1,`subjectUri`],[M,1,`onBack`],[te,1,`relevantPanes`],[re,1,`pane`],[ae,1,`paneRenderOptions`],[P,1,`showHeader`],[I,1,`
|
|
12
|
+
`}},{e:[k,j,ee,ne,ie,N,F,L,z,V,U,G,q,oe,ce,ue,T],c:[$,E]}=he(c,[[O,1,`context`],[A,1,`subjectUri`],[M,1,`onBack`],[te,1,`relevantPanes`],[re,1,`pane`],[ae,1,`paneRenderOptions`],[P,1,`showHeader`],[I,1,`handleAccessClick`],[R,1,`soloPane`],[B,1,`openPane`],[H,1,`menuItems`],[W,1,`isEditing`],[K,1,`isDirty`],[J,1,`paneSupportsEditing`],[se,1,`edit`],[le,1,`fileExplorerContextValue`]],D,0,void 0,r.WebComponent),c),s=class extends be{constructor(){super($),Q(this,`styles`,e.default),E()}},Q(s,de,void 0),s),Object.defineProperty(exports,"default",{enumerable:!0,get:function(){return $}});
|
|
13
13
|
//# sourceMappingURL=FileExplorerProvider.cjs.js.map
|