@memberjunction/ng-conversations 6.3.0-edge.0 → 6.3.0-edge.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +60 -22
- package/dist/assets/edge-ai.worker.js +35168 -0
- package/dist/lib/components/agent/agent-instance-editor-modal.component.d.ts +186 -0
- package/dist/lib/components/agent/agent-instance-editor-modal.component.d.ts.map +1 -0
- package/dist/lib/components/agent/agent-instance-editor-modal.component.js +2202 -0
- package/dist/lib/components/agent/agent-instance-editor-modal.component.js.map +1 -0
- package/dist/lib/components/artifact/artifact-share-modal.component.d.ts +39 -6
- package/dist/lib/components/artifact/artifact-share-modal.component.d.ts.map +1 -1
- package/dist/lib/components/artifact/artifact-share-modal.component.js +773 -204
- package/dist/lib/components/artifact/artifact-share-modal.component.js.map +1 -1
- package/dist/lib/components/collection/collection-tree.component.d.ts.map +1 -1
- package/dist/lib/components/collection/collection-tree.component.js +19 -18
- package/dist/lib/components/collection/collection-tree.component.js.map +1 -1
- package/dist/lib/components/collection/collection-view.component.d.ts +6 -4
- package/dist/lib/components/collection/collection-view.component.d.ts.map +1 -1
- package/dist/lib/components/collection/collection-view.component.js +35 -17
- package/dist/lib/components/collection/collection-view.component.js.map +1 -1
- package/dist/lib/components/collection/collections-full-view.component.d.ts +1 -0
- package/dist/lib/components/collection/collections-full-view.component.d.ts.map +1 -1
- package/dist/lib/components/collection/collections-full-view.component.js +108 -106
- package/dist/lib/components/collection/collections-full-view.component.js.map +1 -1
- package/dist/lib/components/composer/ai-composer.component.d.ts +15 -1
- package/dist/lib/components/composer/ai-composer.component.d.ts.map +1 -1
- package/dist/lib/components/composer/ai-composer.component.js +43 -4
- package/dist/lib/components/composer/ai-composer.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-agent-picker.component.d.ts +20 -2
- package/dist/lib/components/conversation/conversation-agent-picker.component.d.ts.map +1 -1
- package/dist/lib/components/conversation/conversation-agent-picker.component.js +378 -62
- package/dist/lib/components/conversation/conversation-agent-picker.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-chat-area.component.d.ts +94 -18
- package/dist/lib/components/conversation/conversation-chat-area.component.d.ts.map +1 -1
- package/dist/lib/components/conversation/conversation-chat-area.component.js +732 -439
- package/dist/lib/components/conversation/conversation-chat-area.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-list.component.d.ts +19 -1
- package/dist/lib/components/conversation/conversation-list.component.d.ts.map +1 -1
- package/dist/lib/components/conversation/conversation-list.component.js +184 -89
- package/dist/lib/components/conversation/conversation-list.component.js.map +1 -1
- package/dist/lib/components/export/export-modal.component.d.ts +7 -2
- package/dist/lib/components/export/export-modal.component.d.ts.map +1 -1
- package/dist/lib/components/export/export-modal.component.js +13 -2
- package/dist/lib/components/export/export-modal.component.js.map +1 -1
- package/dist/lib/components/library/library-create-dialog.component.d.ts +136 -0
- package/dist/lib/components/library/library-create-dialog.component.d.ts.map +1 -0
- package/dist/lib/components/library/library-create-dialog.component.js +1620 -0
- package/dist/lib/components/library/library-create-dialog.component.js.map +1 -0
- package/dist/lib/components/library/library-full-view.component.d.ts +10 -4
- package/dist/lib/components/library/library-full-view.component.d.ts.map +1 -1
- package/dist/lib/components/library/library-full-view.component.js +216 -40
- package/dist/lib/components/library/library-full-view.component.js.map +1 -1
- package/dist/lib/components/library/library-remote-drive-pane.component.d.ts +97 -0
- package/dist/lib/components/library/library-remote-drive-pane.component.d.ts.map +1 -0
- package/dist/lib/components/library/library-remote-drive-pane.component.js +1229 -0
- package/dist/lib/components/library/library-remote-drive-pane.component.js.map +1 -0
- package/dist/lib/components/library/library-workspace.component.d.ts +293 -0
- package/dist/lib/components/library/library-workspace.component.d.ts.map +1 -0
- package/dist/lib/components/library/library-workspace.component.js +5121 -0
- package/dist/lib/components/library/library-workspace.component.js.map +1 -0
- package/dist/lib/components/library/library.models.d.ts +192 -0
- package/dist/lib/components/library/library.models.d.ts.map +1 -0
- package/dist/lib/components/library/library.models.js +2 -0
- package/dist/lib/components/library/library.models.js.map +1 -0
- package/dist/lib/components/message/agent-handoff-card.component.js +1 -1
- package/dist/lib/components/message/agent-handoff-card.component.js.map +1 -1
- package/dist/lib/components/message/conversation-message-rating.component.d.ts +5 -0
- package/dist/lib/components/message/conversation-message-rating.component.d.ts.map +1 -1
- package/dist/lib/components/message/conversation-message-rating.component.js +72 -16
- package/dist/lib/components/message/conversation-message-rating.component.js.map +1 -1
- package/dist/lib/components/message/message-input.component.d.ts +33 -14
- package/dist/lib/components/message/message-input.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-input.component.js +142 -75
- package/dist/lib/components/message/message-input.component.js.map +1 -1
- package/dist/lib/components/message/message-item.component.d.ts +51 -4
- package/dist/lib/components/message/message-item.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-item.component.js +640 -399
- package/dist/lib/components/message/message-item.component.js.map +1 -1
- package/dist/lib/components/message/message-list.component.d.ts +15 -1
- package/dist/lib/components/message/message-list.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-list.component.js +75 -3
- package/dist/lib/components/message/message-list.component.js.map +1 -1
- package/dist/lib/components/navigation/conversation-navigation.component.js +9 -9
- package/dist/lib/components/navigation/conversation-navigation.component.js.map +1 -1
- package/dist/lib/components/overlay/chat-overlay.component.d.ts +94 -6
- package/dist/lib/components/overlay/chat-overlay.component.d.ts.map +1 -1
- package/dist/lib/components/overlay/chat-overlay.component.js +249 -59
- package/dist/lib/components/overlay/chat-overlay.component.js.map +1 -1
- package/dist/lib/components/project/project-form-modal.component.d.ts +6 -0
- package/dist/lib/components/project/project-form-modal.component.d.ts.map +1 -1
- package/dist/lib/components/project/project-form-modal.component.js +81 -61
- package/dist/lib/components/project/project-form-modal.component.js.map +1 -1
- package/dist/lib/components/project/project-selector.component.d.ts +5 -0
- package/dist/lib/components/project/project-selector.component.d.ts.map +1 -1
- package/dist/lib/components/project/project-selector.component.js +11 -4
- package/dist/lib/components/project/project-selector.component.js.map +1 -1
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.d.ts +55 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.d.ts.map +1 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.js +974 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.js.map +1 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.d.ts +66 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.d.ts.map +1 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.js +253 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.js.map +1 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.d.ts +80 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.d.ts.map +1 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.js +49 -0
- package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.js.map +1 -0
- package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.d.ts +54 -0
- package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.d.ts.map +1 -0
- package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.js +386 -0
- package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.js.map +1 -0
- package/dist/lib/components/realtime/capture/realtime-capture-channel.d.ts +28 -1
- package/dist/lib/components/realtime/capture/realtime-capture-channel.d.ts.map +1 -1
- package/dist/lib/components/realtime/capture/realtime-capture-channel.js +53 -1
- package/dist/lib/components/realtime/capture/realtime-capture-channel.js.map +1 -1
- package/dist/lib/components/realtime/channels/client-context-channel.d.ts.map +1 -1
- package/dist/lib/components/realtime/channels/client-context-channel.js +23 -7
- package/dist/lib/components/realtime/channels/client-context-channel.js.map +1 -1
- package/dist/lib/components/realtime/interactive-component/interactive-component-channel.d.ts +1 -0
- package/dist/lib/components/realtime/interactive-component/interactive-component-channel.d.ts.map +1 -1
- package/dist/lib/components/realtime/interactive-component/interactive-component-channel.js +15 -2
- package/dist/lib/components/realtime/interactive-component/interactive-component-channel.js.map +1 -1
- package/dist/lib/components/realtime/media/media-channel.d.ts +32 -11
- package/dist/lib/components/realtime/media/media-channel.d.ts.map +1 -1
- package/dist/lib/components/realtime/media/media-channel.js +186 -23
- package/dist/lib/components/realtime/media/media-channel.js.map +1 -1
- package/dist/lib/components/realtime/media/realtime-media-surface.component.d.ts +9 -1
- package/dist/lib/components/realtime/media/realtime-media-surface.component.d.ts.map +1 -1
- package/dist/lib/components/realtime/media/realtime-media-surface.component.js +33 -10
- package/dist/lib/components/realtime/media/realtime-media-surface.component.js.map +1 -1
- package/dist/lib/components/realtime/realtime-agent-banner.component.js +3 -3
- package/dist/lib/components/realtime/realtime-agent-banner.component.js.map +1 -1
- package/dist/lib/components/realtime/realtime-agent-picker.component.d.ts.map +1 -1
- package/dist/lib/components/realtime/realtime-agent-picker.component.js +3 -3
- package/dist/lib/components/realtime/realtime-agent-picker.component.js.map +1 -1
- package/dist/lib/components/realtime/realtime-composer.component.js +6 -4
- package/dist/lib/components/realtime/realtime-composer.component.js.map +1 -1
- package/dist/lib/components/realtime/realtime-session-overlay.component.d.ts +82 -33
- package/dist/lib/components/realtime/realtime-session-overlay.component.d.ts.map +1 -1
- package/dist/lib/components/realtime/realtime-session-overlay.component.js +521 -191
- package/dist/lib/components/realtime/realtime-session-overlay.component.js.map +1 -1
- package/dist/lib/components/realtime/realtime-session-state.d.ts.map +1 -1
- package/dist/lib/components/realtime/realtime-session-state.js +1 -1
- package/dist/lib/components/realtime/realtime-session-state.js.map +1 -1
- package/dist/lib/components/realtime/realtime-session-thread.component.d.ts.map +1 -1
- package/dist/lib/components/realtime/realtime-session-thread.component.js +90 -5
- package/dist/lib/components/realtime/realtime-session-thread.component.js.map +1 -1
- package/dist/lib/components/realtime/realtime-surface-stage.model.d.ts.map +1 -1
- package/dist/lib/components/realtime/realtime-surface-stage.model.js +2 -1
- package/dist/lib/components/realtime/realtime-surface-stage.model.js.map +1 -1
- package/dist/lib/components/realtime/realtime-surface-tab-style.d.ts +11 -4
- package/dist/lib/components/realtime/realtime-surface-tab-style.d.ts.map +1 -1
- package/dist/lib/components/realtime/realtime-surface-tab-style.js +24 -5
- package/dist/lib/components/realtime/realtime-surface-tab-style.js.map +1 -1
- package/dist/lib/components/realtime/realtime-surface-tabs.model.d.ts +7 -9
- package/dist/lib/components/realtime/realtime-surface-tabs.model.d.ts.map +1 -1
- package/dist/lib/components/realtime/realtime-surface-tabs.model.js +25 -15
- package/dist/lib/components/realtime/realtime-surface-tabs.model.js.map +1 -1
- package/dist/lib/components/realtime/remote-browser/remote-browser-channel.d.ts +30 -1
- package/dist/lib/components/realtime/remote-browser/remote-browser-channel.d.ts.map +1 -1
- package/dist/lib/components/realtime/remote-browser/remote-browser-channel.js +150 -2
- package/dist/lib/components/realtime/remote-browser/remote-browser-channel.js.map +1 -1
- package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.d.ts +101 -3
- package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.d.ts.map +1 -1
- package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.js +503 -55
- package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.js.map +1 -1
- package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.d.ts +48 -5
- package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.d.ts.map +1 -1
- package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.js +249 -53
- package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.js.map +1 -1
- package/dist/lib/components/realtime/whiteboard/whiteboard-channel.d.ts.map +1 -1
- package/dist/lib/components/realtime/whiteboard/whiteboard-channel.js +1 -1
- package/dist/lib/components/realtime/whiteboard/whiteboard-channel.js.map +1 -1
- package/dist/lib/components/search/search-panel.component.d.ts +10 -0
- package/dist/lib/components/search/search-panel.component.d.ts.map +1 -1
- package/dist/lib/components/search/search-panel.component.js +25 -3
- package/dist/lib/components/search/search-panel.component.js.map +1 -1
- package/dist/lib/components/share/share-modal.component.d.ts.map +1 -1
- package/dist/lib/components/share/share-modal.component.js +181 -127
- package/dist/lib/components/share/share-modal.component.js.map +1 -1
- package/dist/lib/components/sidebar/conversation-sidebar.component.d.ts +14 -1
- package/dist/lib/components/sidebar/conversation-sidebar.component.d.ts.map +1 -1
- package/dist/lib/components/sidebar/conversation-sidebar.component.js +50 -11
- package/dist/lib/components/sidebar/conversation-sidebar.component.js.map +1 -1
- package/dist/lib/components/sidebar/my-agents-section.component.d.ts +78 -0
- package/dist/lib/components/sidebar/my-agents-section.component.d.ts.map +1 -0
- package/dist/lib/components/sidebar/my-agents-section.component.js +450 -0
- package/dist/lib/components/sidebar/my-agents-section.component.js.map +1 -0
- package/dist/lib/components/task/tasks-full-view.component.d.ts +31 -8
- package/dist/lib/components/task/tasks-full-view.component.d.ts.map +1 -1
- package/dist/lib/components/task/tasks-full-view.component.js +701 -497
- package/dist/lib/components/task/tasks-full-view.component.js.map +1 -1
- package/dist/lib/components/workspace/conversation-workspace.component.d.ts.map +1 -1
- package/dist/lib/components/workspace/conversation-workspace.component.js +15 -2
- package/dist/lib/components/workspace/conversation-workspace.component.js.map +1 -1
- package/dist/lib/composer-plugins/base-conversation-mention.provider.d.ts +1 -0
- package/dist/lib/composer-plugins/base-conversation-mention.provider.d.ts.map +1 -1
- package/dist/lib/composer-plugins/base-conversation-mention.provider.js +13 -1
- package/dist/lib/composer-plugins/base-conversation-mention.provider.js.map +1 -1
- package/dist/lib/conversations.module.d.ts +78 -71
- package/dist/lib/conversations.module.d.ts.map +1 -1
- package/dist/lib/conversations.module.js +68 -1
- package/dist/lib/conversations.module.js.map +1 -1
- package/dist/lib/models/agent-turn.model.d.ts +7 -1
- package/dist/lib/models/agent-turn.model.d.ts.map +1 -1
- package/dist/lib/models/agent-turn.model.js.map +1 -1
- package/dist/lib/services/agent-state.service.d.ts.map +1 -1
- package/dist/lib/services/agent-state.service.js +14 -3
- package/dist/lib/services/agent-state.service.js.map +1 -1
- package/dist/lib/services/artifact-permission.service.d.ts.map +1 -1
- package/dist/lib/services/artifact-permission.service.js +14 -3
- package/dist/lib/services/artifact-permission.service.js.map +1 -1
- package/dist/lib/services/artifact-state.service.d.ts.map +1 -1
- package/dist/lib/services/artifact-state.service.js +43 -11
- package/dist/lib/services/artifact-state.service.js.map +1 -1
- package/dist/lib/services/conversation-agent.service.d.ts +31 -21
- package/dist/lib/services/conversation-agent.service.d.ts.map +1 -1
- package/dist/lib/services/conversation-agent.service.js +84 -35
- package/dist/lib/services/conversation-agent.service.js.map +1 -1
- package/dist/lib/services/conversation-tasks-filter.d.ts +59 -2
- package/dist/lib/services/conversation-tasks-filter.d.ts.map +1 -1
- package/dist/lib/services/conversation-tasks-filter.js +222 -18
- package/dist/lib/services/conversation-tasks-filter.js.map +1 -1
- package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.d.ts +85 -0
- package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.d.ts.map +1 -0
- package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.js +257 -0
- package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.js.map +1 -0
- package/dist/lib/services/edge-ai/edge-ai-protocol.d.ts +85 -0
- package/dist/lib/services/edge-ai/edge-ai-protocol.d.ts.map +1 -0
- package/dist/lib/services/edge-ai/edge-ai-protocol.js +10 -0
- package/dist/lib/services/edge-ai/edge-ai-protocol.js.map +1 -0
- package/dist/lib/services/edge-ai/edge-ai-worker-host.d.ts +90 -0
- package/dist/lib/services/edge-ai/edge-ai-worker-host.d.ts.map +1 -0
- package/dist/lib/services/edge-ai/edge-ai-worker-host.js +386 -0
- package/dist/lib/services/edge-ai/edge-ai-worker-host.js.map +1 -0
- package/dist/lib/services/edge-ai/edge-ai.worker.d.ts +13 -0
- package/dist/lib/services/edge-ai/edge-ai.worker.d.ts.map +1 -0
- package/dist/lib/services/edge-ai/edge-ai.worker.js +201 -0
- package/dist/lib/services/edge-ai/edge-ai.worker.js.map +1 -0
- package/dist/lib/services/export.service.d.ts +64 -0
- package/dist/lib/services/export.service.d.ts.map +1 -1
- package/dist/lib/services/export.service.js +185 -6
- package/dist/lib/services/export.service.js.map +1 -1
- package/dist/lib/services/library-creation.service.d.ts +304 -0
- package/dist/lib/services/library-creation.service.d.ts.map +1 -0
- package/dist/lib/services/library-creation.service.js +1244 -0
- package/dist/lib/services/library-creation.service.js.map +1 -0
- package/dist/lib/services/realtime-pairing.d.ts +3 -3
- package/dist/lib/services/realtime-pairing.js +4 -4
- package/dist/lib/services/realtime-pairing.js.map +1 -1
- package/dist/lib/services/realtime-session-review.service.d.ts +14 -0
- package/dist/lib/services/realtime-session-review.service.d.ts.map +1 -1
- package/dist/lib/services/realtime-session-review.service.js +46 -4
- package/dist/lib/services/realtime-session-review.service.js.map +1 -1
- package/dist/lib/services/realtime-session.service.d.ts.map +1 -1
- package/dist/lib/services/realtime-session.service.js +2 -1
- package/dist/lib/services/realtime-session.service.js.map +1 -1
- package/dist/lib/services/search.service.d.ts +19 -2
- package/dist/lib/services/search.service.d.ts.map +1 -1
- package/dist/lib/services/search.service.js +99 -36
- package/dist/lib/services/search.service.js.map +1 -1
- package/dist/lib/utils/agent-handoff-map.js +1 -1
- package/dist/lib/utils/agent-handoff-map.js.map +1 -1
- package/dist/lib/utils/agent-turn-routing.js +1 -1
- package/dist/lib/utils/agent-turn-routing.js.map +1 -1
- package/dist/lib/utils/decision-routing.d.ts +5 -2
- package/dist/lib/utils/decision-routing.d.ts.map +1 -1
- package/dist/lib/utils/decision-routing.js +9 -4
- package/dist/lib/utils/decision-routing.js.map +1 -1
- package/dist/public-api.d.ts +15 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +17 -1
- package/dist/public-api.js.map +1 -1
- package/package.json +42 -37
|
@@ -0,0 +1,1229 @@
|
|
|
1
|
+
import { ChangeDetectorRef, Component, EventEmitter, Input, Output, inject, } from '@angular/core';
|
|
2
|
+
import { DomSanitizer } from '@angular/platform-browser';
|
|
3
|
+
import { BaseAngularComponent } from '@memberjunction/ng-base-types';
|
|
4
|
+
import { GraphQLDataProvider, GraphQLFileStorageClient, } from '@memberjunction/graphql-dataprovider';
|
|
5
|
+
import { MJNotificationService } from '@memberjunction/ng-notifications';
|
|
6
|
+
import { LibraryCreationService } from '../../services/library-creation.service';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
import * as i1 from "@memberjunction/ng-ui-components";
|
|
9
|
+
import * as i2 from "@memberjunction/ng-artifacts";
|
|
10
|
+
import * as i3 from "@memberjunction/ng-shared-generic";
|
|
11
|
+
import * as i4 from "@angular/common";
|
|
12
|
+
const _forTrack0 = ($index, $item) => $item.FullPrefix;
|
|
13
|
+
const _forTrack1 = ($index, $item) => $item.path;
|
|
14
|
+
const _forTrack2 = ($index, $item) => $item.fullPath;
|
|
15
|
+
function LibraryRemoteDrivePaneComponent_Conditional_3_Template(rf, ctx) { if (rf & 1) {
|
|
16
|
+
const _r1 = i0.ɵɵgetCurrentView();
|
|
17
|
+
i0.ɵɵelementStart(0, "button", 19);
|
|
18
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_3_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.BackRequested.emit()); });
|
|
19
|
+
i0.ɵɵelement(1, "i", 20);
|
|
20
|
+
i0.ɵɵelementEnd();
|
|
21
|
+
} }
|
|
22
|
+
function LibraryRemoteDrivePaneComponent_For_9_Template(rf, ctx) { if (rf & 1) {
|
|
23
|
+
const _r3 = i0.ɵɵgetCurrentView();
|
|
24
|
+
i0.ɵɵelement(0, "i", 21);
|
|
25
|
+
i0.ɵɵelementStart(1, "button", 22);
|
|
26
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_For_9_Template_button_click_1_listener() { const crumb_r4 = i0.ɵɵrestoreView(_r3).$implicit; const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.NavigateToPrefix(crumb_r4.FullPrefix)); });
|
|
27
|
+
i0.ɵɵtext(2);
|
|
28
|
+
i0.ɵɵelementEnd();
|
|
29
|
+
} if (rf & 2) {
|
|
30
|
+
const crumb_r4 = ctx.$implicit;
|
|
31
|
+
const ɵ$index_19_r5 = ctx.$index;
|
|
32
|
+
const ɵ$count_19_r6 = ctx.$count;
|
|
33
|
+
i0.ɵɵadvance();
|
|
34
|
+
i0.ɵɵclassProp("crumb-active", ɵ$index_19_r5 === ɵ$count_19_r6 - 1);
|
|
35
|
+
i0.ɵɵadvance();
|
|
36
|
+
i0.ɵɵtextInterpolate1(" ", crumb_r4.Name, " ");
|
|
37
|
+
} }
|
|
38
|
+
function LibraryRemoteDrivePaneComponent_Conditional_15_Template(rf, ctx) { if (rf & 1) {
|
|
39
|
+
const _r7 = i0.ɵɵgetCurrentView();
|
|
40
|
+
i0.ɵɵelementStart(0, "button", 23);
|
|
41
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_15_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.RunRemoteSearch()); });
|
|
42
|
+
i0.ɵɵelement(1, "i", 24);
|
|
43
|
+
i0.ɵɵtext(2, " Search Drive ");
|
|
44
|
+
i0.ɵɵelementEnd();
|
|
45
|
+
} if (rf & 2) {
|
|
46
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
47
|
+
i0.ɵɵproperty("disabled", ctx_r1.IsSearchingRemote);
|
|
48
|
+
i0.ɵɵadvance();
|
|
49
|
+
i0.ɵɵclassProp("fa-magnifying-glass", !ctx_r1.IsSearchingRemote)("fa-spinner", ctx_r1.IsSearchingRemote)("fa-spin", ctx_r1.IsSearchingRemote);
|
|
50
|
+
} }
|
|
51
|
+
function LibraryRemoteDrivePaneComponent_Conditional_16_Template(rf, ctx) { if (rf & 1) {
|
|
52
|
+
const _r8 = i0.ɵɵgetCurrentView();
|
|
53
|
+
i0.ɵɵelementStart(0, "button", 25);
|
|
54
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_16_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.ClearRemoteSearch()); });
|
|
55
|
+
i0.ɵɵtext(1, " Clear Search ");
|
|
56
|
+
i0.ɵɵelementEnd();
|
|
57
|
+
} }
|
|
58
|
+
function LibraryRemoteDrivePaneComponent_Conditional_20_Template(rf, ctx) { if (rf & 1) {
|
|
59
|
+
i0.ɵɵelementStart(0, "div", 14);
|
|
60
|
+
i0.ɵɵelement(1, "mj-loading", 26);
|
|
61
|
+
i0.ɵɵelementEnd();
|
|
62
|
+
} }
|
|
63
|
+
function LibraryRemoteDrivePaneComponent_Conditional_21_Template(rf, ctx) { if (rf & 1) {
|
|
64
|
+
const _r9 = i0.ɵɵgetCurrentView();
|
|
65
|
+
i0.ɵɵelementStart(0, "mj-empty-state", 27);
|
|
66
|
+
i0.ɵɵlistener("Action", function LibraryRemoteDrivePaneComponent_Conditional_21_Template_mj_empty_state_Action_0_listener() { i0.ɵɵrestoreView(_r9); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.ReloadListing()); });
|
|
67
|
+
i0.ɵɵelementEnd();
|
|
68
|
+
} if (rf & 2) {
|
|
69
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
70
|
+
i0.ɵɵproperty("Message", ctx_r1.ErrorMessage);
|
|
71
|
+
} }
|
|
72
|
+
function LibraryRemoteDrivePaneComponent_Conditional_22_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
73
|
+
i0.ɵɵelement(0, "mj-empty-state", 28);
|
|
74
|
+
} }
|
|
75
|
+
function LibraryRemoteDrivePaneComponent_Conditional_22_Conditional_1_For_13_Template(rf, ctx) { if (rf & 1) {
|
|
76
|
+
const _r10 = i0.ɵɵgetCurrentView();
|
|
77
|
+
i0.ɵɵelementStart(0, "tr", 30);
|
|
78
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_22_Conditional_1_For_13_Template_tr_click_0_listener() { const hit_r11 = i0.ɵɵrestoreView(_r10).$implicit; const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.SelectSearchHit(hit_r11)); });
|
|
79
|
+
i0.ɵɵelementStart(1, "td", 31);
|
|
80
|
+
i0.ɵɵelement(2, "i");
|
|
81
|
+
i0.ɵɵelementStart(3, "span");
|
|
82
|
+
i0.ɵɵtext(4);
|
|
83
|
+
i0.ɵɵelementEnd()();
|
|
84
|
+
i0.ɵɵelementStart(5, "td", 32);
|
|
85
|
+
i0.ɵɵtext(6);
|
|
86
|
+
i0.ɵɵelementEnd();
|
|
87
|
+
i0.ɵɵelementStart(7, "td", 32);
|
|
88
|
+
i0.ɵɵtext(8);
|
|
89
|
+
i0.ɵɵelementEnd();
|
|
90
|
+
i0.ɵɵelementStart(9, "td", 32);
|
|
91
|
+
i0.ɵɵtext(10);
|
|
92
|
+
i0.ɵɵpipe(11, "date");
|
|
93
|
+
i0.ɵɵelementEnd()();
|
|
94
|
+
} if (rf & 2) {
|
|
95
|
+
const hit_r11 = ctx.$implicit;
|
|
96
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
97
|
+
i0.ɵɵclassProp("selected", (ctx_r1.SelectedObject == null ? null : ctx_r1.SelectedObject.fullPath) === hit_r11.path);
|
|
98
|
+
i0.ɵɵadvance(2);
|
|
99
|
+
i0.ɵɵclassMap(ctx_r1.GetFileIcon(hit_r11.name, hit_r11.contentType));
|
|
100
|
+
i0.ɵɵadvance(2);
|
|
101
|
+
i0.ɵɵtextInterpolate(hit_r11.name);
|
|
102
|
+
i0.ɵɵadvance(2);
|
|
103
|
+
i0.ɵɵtextInterpolate(hit_r11.path);
|
|
104
|
+
i0.ɵɵadvance(2);
|
|
105
|
+
i0.ɵɵtextInterpolate(ctx_r1.FormatBytes(hit_r11.size));
|
|
106
|
+
i0.ɵɵadvance(2);
|
|
107
|
+
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind2(11, 8, hit_r11.lastModified, "mediumDate"));
|
|
108
|
+
} }
|
|
109
|
+
function LibraryRemoteDrivePaneComponent_Conditional_22_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
110
|
+
i0.ɵɵelementStart(0, "table", 17)(1, "thead")(2, "tr")(3, "th");
|
|
111
|
+
i0.ɵɵtext(4, "Name");
|
|
112
|
+
i0.ɵɵelementEnd();
|
|
113
|
+
i0.ɵɵelementStart(5, "th");
|
|
114
|
+
i0.ɵɵtext(6, "Path");
|
|
115
|
+
i0.ɵɵelementEnd();
|
|
116
|
+
i0.ɵɵelementStart(7, "th");
|
|
117
|
+
i0.ɵɵtext(8, "Size");
|
|
118
|
+
i0.ɵɵelementEnd();
|
|
119
|
+
i0.ɵɵelementStart(9, "th");
|
|
120
|
+
i0.ɵɵtext(10, "Modified");
|
|
121
|
+
i0.ɵɵelementEnd()()();
|
|
122
|
+
i0.ɵɵelementStart(11, "tbody");
|
|
123
|
+
i0.ɵɵrepeaterCreate(12, LibraryRemoteDrivePaneComponent_Conditional_22_Conditional_1_For_13_Template, 12, 11, "tr", 29, _forTrack1);
|
|
124
|
+
i0.ɵɵelementEnd()();
|
|
125
|
+
} if (rf & 2) {
|
|
126
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
127
|
+
i0.ɵɵadvance(12);
|
|
128
|
+
i0.ɵɵrepeater(ctx_r1.RemoteSearchResults);
|
|
129
|
+
} }
|
|
130
|
+
function LibraryRemoteDrivePaneComponent_Conditional_22_Template(rf, ctx) { if (rf & 1) {
|
|
131
|
+
i0.ɵɵconditionalCreate(0, LibraryRemoteDrivePaneComponent_Conditional_22_Conditional_0_Template, 1, 0, "mj-empty-state", 28)(1, LibraryRemoteDrivePaneComponent_Conditional_22_Conditional_1_Template, 14, 0, "table", 17);
|
|
132
|
+
} if (rf & 2) {
|
|
133
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
134
|
+
i0.ɵɵconditional(ctx_r1.RemoteSearchResults.length === 0 ? 0 : 1);
|
|
135
|
+
} }
|
|
136
|
+
function LibraryRemoteDrivePaneComponent_Conditional_23_Template(rf, ctx) { if (rf & 1) {
|
|
137
|
+
i0.ɵɵelement(0, "mj-empty-state", 16);
|
|
138
|
+
} if (rf & 2) {
|
|
139
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
140
|
+
i0.ɵɵproperty("Variant", ctx_r1.SearchTerm ? "no-results" : "empty")("Title", ctx_r1.SearchTerm ? "No matching items in folder" : "This folder is empty")("Message", ctx_r1.SearchTerm ? "Try clearing the filter or searching across the entire drive." : "Remote files in this connected drive appear dynamically here.");
|
|
141
|
+
} }
|
|
142
|
+
function LibraryRemoteDrivePaneComponent_Conditional_24_For_13_Template(rf, ctx) { if (rf & 1) {
|
|
143
|
+
const _r12 = i0.ɵɵgetCurrentView();
|
|
144
|
+
i0.ɵɵelementStart(0, "tr", 34);
|
|
145
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_24_For_13_Template_tr_click_0_listener() { const folder_r13 = i0.ɵɵrestoreView(_r12).$implicit; const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.NavigateToPrefix(folder_r13.FullPrefix)); });
|
|
146
|
+
i0.ɵɵelementStart(1, "td", 31);
|
|
147
|
+
i0.ɵɵelement(2, "i", 35);
|
|
148
|
+
i0.ɵɵelementStart(3, "span", 36);
|
|
149
|
+
i0.ɵɵtext(4);
|
|
150
|
+
i0.ɵɵelementEnd()();
|
|
151
|
+
i0.ɵɵelementStart(5, "td", 32);
|
|
152
|
+
i0.ɵɵtext(6, "Folder");
|
|
153
|
+
i0.ɵɵelementEnd();
|
|
154
|
+
i0.ɵɵelementStart(7, "td", 32);
|
|
155
|
+
i0.ɵɵtext(8, "\u2014");
|
|
156
|
+
i0.ɵɵelementEnd();
|
|
157
|
+
i0.ɵɵelementStart(9, "td", 32);
|
|
158
|
+
i0.ɵɵtext(10, "\u2014");
|
|
159
|
+
i0.ɵɵelementEnd()();
|
|
160
|
+
} if (rf & 2) {
|
|
161
|
+
const folder_r13 = ctx.$implicit;
|
|
162
|
+
i0.ɵɵadvance(4);
|
|
163
|
+
i0.ɵɵtextInterpolate(folder_r13.Name);
|
|
164
|
+
} }
|
|
165
|
+
function LibraryRemoteDrivePaneComponent_Conditional_24_For_15_Template(rf, ctx) { if (rf & 1) {
|
|
166
|
+
const _r14 = i0.ɵɵgetCurrentView();
|
|
167
|
+
i0.ɵɵelementStart(0, "tr", 30);
|
|
168
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_24_For_15_Template_tr_click_0_listener() { const file_r15 = i0.ɵɵrestoreView(_r14).$implicit; const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.SelectRemoteFile(file_r15)); });
|
|
169
|
+
i0.ɵɵelementStart(1, "td", 31);
|
|
170
|
+
i0.ɵɵelement(2, "i");
|
|
171
|
+
i0.ɵɵelementStart(3, "span");
|
|
172
|
+
i0.ɵɵtext(4);
|
|
173
|
+
i0.ɵɵelementEnd()();
|
|
174
|
+
i0.ɵɵelementStart(5, "td", 32);
|
|
175
|
+
i0.ɵɵtext(6);
|
|
176
|
+
i0.ɵɵelementEnd();
|
|
177
|
+
i0.ɵɵelementStart(7, "td", 32);
|
|
178
|
+
i0.ɵɵtext(8);
|
|
179
|
+
i0.ɵɵelementEnd();
|
|
180
|
+
i0.ɵɵelementStart(9, "td", 32);
|
|
181
|
+
i0.ɵɵtext(10);
|
|
182
|
+
i0.ɵɵpipe(11, "date");
|
|
183
|
+
i0.ɵɵelementEnd()();
|
|
184
|
+
} if (rf & 2) {
|
|
185
|
+
const file_r15 = ctx.$implicit;
|
|
186
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
187
|
+
i0.ɵɵclassProp("selected", (ctx_r1.SelectedObject == null ? null : ctx_r1.SelectedObject.fullPath) === file_r15.fullPath);
|
|
188
|
+
i0.ɵɵadvance(2);
|
|
189
|
+
i0.ɵɵclassMap(ctx_r1.GetFileIcon(file_r15.name, file_r15.contentType));
|
|
190
|
+
i0.ɵɵadvance(2);
|
|
191
|
+
i0.ɵɵtextInterpolate(file_r15.name);
|
|
192
|
+
i0.ɵɵadvance(2);
|
|
193
|
+
i0.ɵɵtextInterpolate(ctx_r1.DescribeFileType(file_r15.name, file_r15.contentType));
|
|
194
|
+
i0.ɵɵadvance(2);
|
|
195
|
+
i0.ɵɵtextInterpolate(ctx_r1.FormatBytes(file_r15.size));
|
|
196
|
+
i0.ɵɵadvance(2);
|
|
197
|
+
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind2(11, 8, file_r15.lastModified, "short"));
|
|
198
|
+
} }
|
|
199
|
+
function LibraryRemoteDrivePaneComponent_Conditional_24_Template(rf, ctx) { if (rf & 1) {
|
|
200
|
+
i0.ɵɵelementStart(0, "table", 17)(1, "thead")(2, "tr")(3, "th");
|
|
201
|
+
i0.ɵɵtext(4, "Name");
|
|
202
|
+
i0.ɵɵelementEnd();
|
|
203
|
+
i0.ɵɵelementStart(5, "th");
|
|
204
|
+
i0.ɵɵtext(6, "Type");
|
|
205
|
+
i0.ɵɵelementEnd();
|
|
206
|
+
i0.ɵɵelementStart(7, "th");
|
|
207
|
+
i0.ɵɵtext(8, "Size");
|
|
208
|
+
i0.ɵɵelementEnd();
|
|
209
|
+
i0.ɵɵelementStart(9, "th");
|
|
210
|
+
i0.ɵɵtext(10, "Last Modified");
|
|
211
|
+
i0.ɵɵelementEnd()()();
|
|
212
|
+
i0.ɵɵelementStart(11, "tbody");
|
|
213
|
+
i0.ɵɵrepeaterCreate(12, LibraryRemoteDrivePaneComponent_Conditional_24_For_13_Template, 11, 1, "tr", 33, _forTrack0);
|
|
214
|
+
i0.ɵɵrepeaterCreate(14, LibraryRemoteDrivePaneComponent_Conditional_24_For_15_Template, 12, 11, "tr", 29, _forTrack2);
|
|
215
|
+
i0.ɵɵelementEnd()();
|
|
216
|
+
} if (rf & 2) {
|
|
217
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
218
|
+
i0.ɵɵadvance(12);
|
|
219
|
+
i0.ɵɵrepeater(ctx_r1.FilteredFolders);
|
|
220
|
+
i0.ɵɵadvance(2);
|
|
221
|
+
i0.ɵɵrepeater(ctx_r1.FilteredFiles);
|
|
222
|
+
} }
|
|
223
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_15_Template(rf, ctx) { if (rf & 1) {
|
|
224
|
+
const _r17 = i0.ɵɵgetCurrentView();
|
|
225
|
+
i0.ɵɵelementStart(0, "button", 50);
|
|
226
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_15_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r17); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.ConvertCopyToNativeLibrary()); });
|
|
227
|
+
i0.ɵɵelement(1, "i", 24);
|
|
228
|
+
i0.ɵɵtext(2);
|
|
229
|
+
i0.ɵɵelementEnd();
|
|
230
|
+
} if (rf & 2) {
|
|
231
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
232
|
+
i0.ɵɵproperty("disabled", ctx_r1.IsConvertingCopy);
|
|
233
|
+
i0.ɵɵadvance();
|
|
234
|
+
i0.ɵɵclassProp("fa-wand-magic-sparkles", !ctx_r1.IsConvertingCopy)("fa-spinner", ctx_r1.IsConvertingCopy)("fa-spin", ctx_r1.IsConvertingCopy);
|
|
235
|
+
i0.ɵɵadvance();
|
|
236
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r1.IsConvertingCopy ? "Converting\u2026" : "Open Copy in Studio", " ");
|
|
237
|
+
} }
|
|
238
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_22_Template(rf, ctx) { if (rf & 1) {
|
|
239
|
+
i0.ɵɵelementStart(0, "div", 14);
|
|
240
|
+
i0.ɵɵelement(1, "mj-loading", 51);
|
|
241
|
+
i0.ɵɵelementEnd();
|
|
242
|
+
} }
|
|
243
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_23_Template(rf, ctx) { if (rf & 1) {
|
|
244
|
+
i0.ɵɵelement(0, "mj-empty-state", 49);
|
|
245
|
+
} if (rf & 2) {
|
|
246
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
247
|
+
i0.ɵɵproperty("Message", ctx_r1.PreviewError);
|
|
248
|
+
} }
|
|
249
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_0_Template(rf, ctx) { if (rf & 1) {
|
|
250
|
+
i0.ɵɵelement(0, "mj-docx-preview", 52);
|
|
251
|
+
} if (rf & 2) {
|
|
252
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
253
|
+
i0.ɵɵproperty("Url", ctx_r1.PreviewUrl);
|
|
254
|
+
} }
|
|
255
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_1_Template(rf, ctx) { if (rf & 1) {
|
|
256
|
+
i0.ɵɵelement(0, "mj-xlsx-preview", 52);
|
|
257
|
+
} if (rf & 2) {
|
|
258
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
259
|
+
i0.ɵɵproperty("Url", ctx_r1.PreviewUrl);
|
|
260
|
+
} }
|
|
261
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_2_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
262
|
+
i0.ɵɵelement(0, "iframe", 56);
|
|
263
|
+
} if (rf & 2) {
|
|
264
|
+
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
265
|
+
i0.ɵɵproperty("src", ctx_r1.SafePreviewUrl, i0.ɵɵsanitizeResourceUrl)("title", ctx_r1.SelectedObject.name);
|
|
266
|
+
} }
|
|
267
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_2_Template(rf, ctx) { if (rf & 1) {
|
|
268
|
+
i0.ɵɵconditionalCreate(0, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_2_Conditional_0_Template, 1, 2, "iframe", 56);
|
|
269
|
+
} if (rf & 2) {
|
|
270
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
271
|
+
i0.ɵɵconditional(ctx_r1.SafePreviewUrl ? 0 : -1);
|
|
272
|
+
} }
|
|
273
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_3_Template(rf, ctx) { if (rf & 1) {
|
|
274
|
+
i0.ɵɵelementStart(0, "div", 53);
|
|
275
|
+
i0.ɵɵelement(1, "img", 57);
|
|
276
|
+
i0.ɵɵelementEnd();
|
|
277
|
+
} if (rf & 2) {
|
|
278
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
279
|
+
i0.ɵɵadvance();
|
|
280
|
+
i0.ɵɵproperty("src", ctx_r1.PreviewUrl, i0.ɵɵsanitizeUrl)("alt", ctx_r1.SelectedObject.name);
|
|
281
|
+
} }
|
|
282
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_4_Template(rf, ctx) { if (rf & 1) {
|
|
283
|
+
i0.ɵɵelementStart(0, "div", 53);
|
|
284
|
+
i0.ɵɵelement(1, "video", 58);
|
|
285
|
+
i0.ɵɵelementEnd();
|
|
286
|
+
} if (rf & 2) {
|
|
287
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
288
|
+
i0.ɵɵadvance();
|
|
289
|
+
i0.ɵɵproperty("src", ctx_r1.PreviewUrl, i0.ɵɵsanitizeUrl);
|
|
290
|
+
} }
|
|
291
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_5_Template(rf, ctx) { if (rf & 1) {
|
|
292
|
+
i0.ɵɵelementStart(0, "div", 53);
|
|
293
|
+
i0.ɵɵelement(1, "audio", 59);
|
|
294
|
+
i0.ɵɵelementEnd();
|
|
295
|
+
} if (rf & 2) {
|
|
296
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
297
|
+
i0.ɵɵadvance();
|
|
298
|
+
i0.ɵɵproperty("src", ctx_r1.PreviewUrl);
|
|
299
|
+
} }
|
|
300
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_6_Template(rf, ctx) { if (rf & 1) {
|
|
301
|
+
i0.ɵɵelementStart(0, "pre", 54);
|
|
302
|
+
i0.ɵɵtext(1);
|
|
303
|
+
i0.ɵɵelementEnd();
|
|
304
|
+
} if (rf & 2) {
|
|
305
|
+
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
306
|
+
i0.ɵɵadvance();
|
|
307
|
+
i0.ɵɵtextInterpolate(ctx_r1.PreviewTextContent);
|
|
308
|
+
} }
|
|
309
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_7_Template(rf, ctx) { if (rf & 1) {
|
|
310
|
+
i0.ɵɵelement(0, "mj-empty-state", 55);
|
|
311
|
+
} }
|
|
312
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Template(rf, ctx) { if (rf & 1) {
|
|
313
|
+
i0.ɵɵconditionalCreate(0, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_0_Template, 1, 1, "mj-docx-preview", 52)(1, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_1_Template, 1, 1, "mj-xlsx-preview", 52)(2, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_2_Template, 1, 1)(3, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_3_Template, 2, 2, "div", 53)(4, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_4_Template, 2, 1, "div", 53)(5, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_5_Template, 2, 1, "div", 53)(6, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_6_Template, 2, 1, "pre", 54)(7, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Case_7_Template, 1, 0, "mj-empty-state", 55);
|
|
314
|
+
} if (rf & 2) {
|
|
315
|
+
let tmp_2_0;
|
|
316
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
317
|
+
i0.ɵɵconditional((tmp_2_0 = ctx_r1.PreviewKind) === "docx" ? 0 : tmp_2_0 === "xlsx" ? 1 : tmp_2_0 === "pdf" ? 2 : tmp_2_0 === "image" ? 3 : tmp_2_0 === "video" ? 4 : tmp_2_0 === "audio" ? 5 : tmp_2_0 === "text" ? 6 : 7);
|
|
318
|
+
} }
|
|
319
|
+
function LibraryRemoteDrivePaneComponent_Conditional_25_Template(rf, ctx) { if (rf & 1) {
|
|
320
|
+
const _r16 = i0.ɵɵgetCurrentView();
|
|
321
|
+
i0.ɵɵelementStart(0, "aside", 18)(1, "header", 37)(2, "div", 38);
|
|
322
|
+
i0.ɵɵelement(3, "i");
|
|
323
|
+
i0.ɵɵelementStart(4, "div", 39)(5, "div", 40);
|
|
324
|
+
i0.ɵɵtext(6);
|
|
325
|
+
i0.ɵɵelementEnd();
|
|
326
|
+
i0.ɵɵelementStart(7, "div", 41)(8, "span");
|
|
327
|
+
i0.ɵɵtext(9);
|
|
328
|
+
i0.ɵɵelementEnd();
|
|
329
|
+
i0.ɵɵelementStart(10, "span");
|
|
330
|
+
i0.ɵɵtext(11, "\u00B7");
|
|
331
|
+
i0.ɵɵelementEnd();
|
|
332
|
+
i0.ɵɵelementStart(12, "span");
|
|
333
|
+
i0.ɵɵtext(13, "Streamed dynamically (no MJ: Files record)");
|
|
334
|
+
i0.ɵɵelementEnd()()()();
|
|
335
|
+
i0.ɵɵelementStart(14, "div", 42);
|
|
336
|
+
i0.ɵɵconditionalCreate(15, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_15_Template, 3, 8, "button", 43);
|
|
337
|
+
i0.ɵɵelementStart(16, "button", 44);
|
|
338
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_25_Template_button_click_16_listener() { i0.ɵɵrestoreView(_r16); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.DownloadSelectedObject()); });
|
|
339
|
+
i0.ɵɵelement(17, "i", 45);
|
|
340
|
+
i0.ɵɵtext(18, " Download ");
|
|
341
|
+
i0.ɵɵelementEnd();
|
|
342
|
+
i0.ɵɵelementStart(19, "button", 46);
|
|
343
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Conditional_25_Template_button_click_19_listener() { i0.ɵɵrestoreView(_r16); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.ClosePreview()); });
|
|
344
|
+
i0.ɵɵelement(20, "i", 47);
|
|
345
|
+
i0.ɵɵelementEnd()()();
|
|
346
|
+
i0.ɵɵelementStart(21, "div", 48);
|
|
347
|
+
i0.ɵɵconditionalCreate(22, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_22_Template, 2, 0, "div", 14)(23, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_23_Template, 1, 1, "mj-empty-state", 49)(24, LibraryRemoteDrivePaneComponent_Conditional_25_Conditional_24_Template, 8, 1);
|
|
348
|
+
i0.ɵɵelementEnd()();
|
|
349
|
+
} if (rf & 2) {
|
|
350
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
351
|
+
i0.ɵɵadvance(3);
|
|
352
|
+
i0.ɵɵclassMap(ctx_r1.GetFileIcon(ctx_r1.SelectedObject.name, ctx_r1.SelectedObject.contentType));
|
|
353
|
+
i0.ɵɵadvance(2);
|
|
354
|
+
i0.ɵɵproperty("title", ctx_r1.SelectedObject.name);
|
|
355
|
+
i0.ɵɵadvance();
|
|
356
|
+
i0.ɵɵtextInterpolate(ctx_r1.SelectedObject.name);
|
|
357
|
+
i0.ɵɵadvance(3);
|
|
358
|
+
i0.ɵɵtextInterpolate(ctx_r1.FormatBytes(ctx_r1.SelectedObject.size));
|
|
359
|
+
i0.ɵɵadvance(6);
|
|
360
|
+
i0.ɵɵconditional(ctx_r1.CanConvertSelectedObject ? 15 : -1);
|
|
361
|
+
i0.ɵɵadvance();
|
|
362
|
+
i0.ɵɵproperty("disabled", !ctx_r1.PreviewUrl);
|
|
363
|
+
i0.ɵɵadvance(6);
|
|
364
|
+
i0.ɵɵconditional(ctx_r1.IsLoadingPreview ? 22 : ctx_r1.PreviewError ? 23 : 24);
|
|
365
|
+
} }
|
|
366
|
+
const MAX_TEXT_PREVIEW_METADATA_BYTES = 5 * 1024 * 1024;
|
|
367
|
+
const MAX_TEXT_PREVIEW_READ_BYTES = 102_400;
|
|
368
|
+
/**
|
|
369
|
+
* Stateless Connected Drive browser & inline remote preview pane.
|
|
370
|
+
*
|
|
371
|
+
* Architectural guarantee:
|
|
372
|
+
* - Browses folders, searches, downloads, and previews remote cloud storage objects dynamically via
|
|
373
|
+
* `GraphQLFileStorageClient.ListObjects` and `CreatePreAuthDownloadUrl`.
|
|
374
|
+
* - **Never creates `MJ: Files` database records.**
|
|
375
|
+
* - Optionally converts a remote `.docx`, `.xlsx`, `.csv`, `.md`, `.sql`, or `.json` stream in memory
|
|
376
|
+
* into a `ContentMode = 'Text'` native `MJ: Artifacts` copy when the user explicitly clicks
|
|
377
|
+
* "Open Copy as MJ Doc / Sheet".
|
|
378
|
+
*/
|
|
379
|
+
export class LibraryRemoteDrivePaneComponent extends BaseAngularComponent {
|
|
380
|
+
_account;
|
|
381
|
+
_currentPrefix = '';
|
|
382
|
+
isInitialized = false;
|
|
383
|
+
set Account(value) {
|
|
384
|
+
const changed = this._account !== value;
|
|
385
|
+
this._account = value;
|
|
386
|
+
if (this.isInitialized && changed) {
|
|
387
|
+
this.onAccountOrPrefixChanged();
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
get Account() {
|
|
391
|
+
return this._account;
|
|
392
|
+
}
|
|
393
|
+
set CurrentPrefix(value) {
|
|
394
|
+
const next = value ?? '';
|
|
395
|
+
const changed = this._currentPrefix !== next;
|
|
396
|
+
this._currentPrefix = next;
|
|
397
|
+
if (this.isInitialized && changed) {
|
|
398
|
+
this.onAccountOrPrefixChanged();
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
get CurrentPrefix() {
|
|
402
|
+
return this._currentPrefix;
|
|
403
|
+
}
|
|
404
|
+
CurrentUser;
|
|
405
|
+
EnvironmentId = '';
|
|
406
|
+
Collections = [];
|
|
407
|
+
ShowBackButton = false;
|
|
408
|
+
StorageClientOverride = null;
|
|
409
|
+
PrefixChange = new EventEmitter();
|
|
410
|
+
BackRequested = new EventEmitter();
|
|
411
|
+
ArtifactConverted = new EventEmitter();
|
|
412
|
+
IsLoading = false;
|
|
413
|
+
ErrorMessage = null;
|
|
414
|
+
Folders = [];
|
|
415
|
+
Files = [];
|
|
416
|
+
SearchTerm = '';
|
|
417
|
+
IsSearchingRemote = false;
|
|
418
|
+
RemoteSearchResults = null;
|
|
419
|
+
SelectedObject = null;
|
|
420
|
+
IsLoadingPreview = false;
|
|
421
|
+
PreviewError = null;
|
|
422
|
+
PreviewUrl = null;
|
|
423
|
+
SafePreviewUrl = null;
|
|
424
|
+
PreviewKind = 'none';
|
|
425
|
+
PreviewTextContent = '';
|
|
426
|
+
IsConvertingCopy = false;
|
|
427
|
+
previewRequestSeq = 0;
|
|
428
|
+
activePreviewAbort = null;
|
|
429
|
+
cdr = inject(ChangeDetectorRef);
|
|
430
|
+
sanitizer = inject(DomSanitizer);
|
|
431
|
+
creationService = inject(LibraryCreationService);
|
|
432
|
+
notifications = inject(MJNotificationService);
|
|
433
|
+
ngOnInit() {
|
|
434
|
+
this.isInitialized = true;
|
|
435
|
+
void this.ReloadListing();
|
|
436
|
+
}
|
|
437
|
+
ngOnDestroy() {
|
|
438
|
+
this.abortActivePreviewStream();
|
|
439
|
+
}
|
|
440
|
+
onAccountOrPrefixChanged() {
|
|
441
|
+
this.ClosePreview();
|
|
442
|
+
this.RemoteSearchResults = null;
|
|
443
|
+
void this.ReloadListing();
|
|
444
|
+
}
|
|
445
|
+
get ProviderIcon() {
|
|
446
|
+
const name = (this.Account?.provider?.Name ?? '').toLowerCase();
|
|
447
|
+
if (name.includes('google drive'))
|
|
448
|
+
return 'fa-brands fa-google-drive';
|
|
449
|
+
if (name.includes('sharepoint') || name.includes('onedrive') || name.includes('azure'))
|
|
450
|
+
return 'fa-brands fa-microsoft';
|
|
451
|
+
if (name.includes('aws') || name.includes('s3'))
|
|
452
|
+
return 'fa-brands fa-aws';
|
|
453
|
+
if (name.includes('dropbox'))
|
|
454
|
+
return 'fa-brands fa-dropbox';
|
|
455
|
+
if (name.includes('box'))
|
|
456
|
+
return 'fa-solid fa-box';
|
|
457
|
+
return 'fa-solid fa-cloud';
|
|
458
|
+
}
|
|
459
|
+
get SupportsProviderSearch() {
|
|
460
|
+
return this.Account?.provider?.SupportsSearch === true;
|
|
461
|
+
}
|
|
462
|
+
get Breadcrumbs() {
|
|
463
|
+
const rawPrefix = this.CurrentPrefix ?? '';
|
|
464
|
+
let start = 0;
|
|
465
|
+
while (start < rawPrefix.length && rawPrefix[start] === '/') {
|
|
466
|
+
start++;
|
|
467
|
+
}
|
|
468
|
+
let end = rawPrefix.length;
|
|
469
|
+
while (end > start && rawPrefix[end - 1] === '/') {
|
|
470
|
+
end--;
|
|
471
|
+
}
|
|
472
|
+
const clean = rawPrefix.slice(start, end);
|
|
473
|
+
if (!clean)
|
|
474
|
+
return [];
|
|
475
|
+
const segments = clean.split('/').filter((s) => s.length > 0);
|
|
476
|
+
const crumbs = [];
|
|
477
|
+
let running = '';
|
|
478
|
+
for (const seg of segments) {
|
|
479
|
+
running = `${running}${seg}/`;
|
|
480
|
+
crumbs.push({ Name: seg, FullPrefix: running });
|
|
481
|
+
}
|
|
482
|
+
return crumbs;
|
|
483
|
+
}
|
|
484
|
+
get FilteredFolders() {
|
|
485
|
+
const q = this.SearchTerm.trim().toLowerCase();
|
|
486
|
+
if (!q)
|
|
487
|
+
return this.Folders;
|
|
488
|
+
return this.Folders.filter((f) => f.Name.toLowerCase().includes(q));
|
|
489
|
+
}
|
|
490
|
+
get FilteredFiles() {
|
|
491
|
+
const q = this.SearchTerm.trim().toLowerCase();
|
|
492
|
+
if (!q)
|
|
493
|
+
return this.Files;
|
|
494
|
+
return this.Files.filter((f) => f.name.toLowerCase().includes(q));
|
|
495
|
+
}
|
|
496
|
+
get CanConvertSelectedObject() {
|
|
497
|
+
return !!this.SelectedObject && this.creationService.IsConvertibleFileName(this.SelectedObject.name);
|
|
498
|
+
}
|
|
499
|
+
async ReloadListing() {
|
|
500
|
+
if (!this.Account?.account?.ID) {
|
|
501
|
+
return;
|
|
502
|
+
}
|
|
503
|
+
this.IsLoading = true;
|
|
504
|
+
this.ErrorMessage = null;
|
|
505
|
+
try {
|
|
506
|
+
const client = this.getStorageClient();
|
|
507
|
+
const result = await client.ListObjects(this.Account.account.ID, this.CurrentPrefix || '', '/');
|
|
508
|
+
const prefixFolders = (result.prefixes ?? []).map((p) => {
|
|
509
|
+
const trimmed = p.replace(/\/+$/, '');
|
|
510
|
+
const lastSlash = trimmed.lastIndexOf('/');
|
|
511
|
+
const label = lastSlash >= 0 ? trimmed.slice(lastSlash + 1) : trimmed;
|
|
512
|
+
return {
|
|
513
|
+
Name: label || p,
|
|
514
|
+
FullPrefix: p.endsWith('/') ? p : `${p}/`,
|
|
515
|
+
};
|
|
516
|
+
});
|
|
517
|
+
const objectFolders = (result.objects ?? [])
|
|
518
|
+
.filter((o) => o.isDirectory)
|
|
519
|
+
.map((o) => ({
|
|
520
|
+
Name: o.name.replace(/\/+$/, ''),
|
|
521
|
+
FullPrefix: o.fullPath.endsWith('/') ? o.fullPath : `${o.fullPath}/`,
|
|
522
|
+
}));
|
|
523
|
+
const seenPrefixes = new Set();
|
|
524
|
+
const mergedFolders = [];
|
|
525
|
+
for (const f of [...prefixFolders, ...objectFolders]) {
|
|
526
|
+
if (!seenPrefixes.has(f.FullPrefix)) {
|
|
527
|
+
seenPrefixes.add(f.FullPrefix);
|
|
528
|
+
mergedFolders.push(f);
|
|
529
|
+
}
|
|
530
|
+
}
|
|
531
|
+
this.Folders = mergedFolders.sort((a, b) => a.Name.localeCompare(b.Name));
|
|
532
|
+
this.Files = (result.objects ?? [])
|
|
533
|
+
.filter((o) => !o.isDirectory)
|
|
534
|
+
.sort((a, b) => a.name.localeCompare(b.name));
|
|
535
|
+
}
|
|
536
|
+
catch (err) {
|
|
537
|
+
this.ErrorMessage = err instanceof Error ? err.message : 'Could not list objects in this storage account.';
|
|
538
|
+
}
|
|
539
|
+
finally {
|
|
540
|
+
this.IsLoading = false;
|
|
541
|
+
this.cdr.detectChanges();
|
|
542
|
+
}
|
|
543
|
+
}
|
|
544
|
+
NavigateToPrefix(prefix) {
|
|
545
|
+
this.CurrentPrefix = prefix;
|
|
546
|
+
this.RemoteSearchResults = null;
|
|
547
|
+
this.ClosePreview();
|
|
548
|
+
this.PrefixChange.emit(prefix);
|
|
549
|
+
void this.ReloadListing();
|
|
550
|
+
}
|
|
551
|
+
OnSearchChanged(value) {
|
|
552
|
+
this.SearchTerm = value;
|
|
553
|
+
if (!value.trim()) {
|
|
554
|
+
this.RemoteSearchResults = null;
|
|
555
|
+
}
|
|
556
|
+
}
|
|
557
|
+
async RunRemoteSearch() {
|
|
558
|
+
const query = this.SearchTerm.trim();
|
|
559
|
+
if (!query || !this.Account?.account?.ID)
|
|
560
|
+
return;
|
|
561
|
+
this.IsSearchingRemote = true;
|
|
562
|
+
try {
|
|
563
|
+
const client = this.getStorageClient();
|
|
564
|
+
const response = await client.SearchFiles([this.Account.account.ID], query, {
|
|
565
|
+
maxResultsPerAccount: 50,
|
|
566
|
+
});
|
|
567
|
+
const firstAccount = response.accountResults?.[0];
|
|
568
|
+
this.RemoteSearchResults = firstAccount?.results ?? [];
|
|
569
|
+
}
|
|
570
|
+
catch (err) {
|
|
571
|
+
this.notifications.CreateSimpleNotification(err instanceof Error ? err.message : 'Remote search failed.', 'error', 4000);
|
|
572
|
+
}
|
|
573
|
+
finally {
|
|
574
|
+
this.IsSearchingRemote = false;
|
|
575
|
+
this.cdr.detectChanges();
|
|
576
|
+
}
|
|
577
|
+
}
|
|
578
|
+
ClearRemoteSearch() {
|
|
579
|
+
this.RemoteSearchResults = null;
|
|
580
|
+
this.SearchTerm = '';
|
|
581
|
+
}
|
|
582
|
+
SelectSearchHit(hit) {
|
|
583
|
+
const synthesized = {
|
|
584
|
+
name: hit.name,
|
|
585
|
+
path: hit.path,
|
|
586
|
+
fullPath: hit.path,
|
|
587
|
+
size: hit.size,
|
|
588
|
+
contentType: hit.contentType,
|
|
589
|
+
lastModified: hit.lastModified,
|
|
590
|
+
isDirectory: false,
|
|
591
|
+
};
|
|
592
|
+
void this.SelectRemoteFile(synthesized);
|
|
593
|
+
}
|
|
594
|
+
async SelectRemoteFile(file) {
|
|
595
|
+
this.abortActivePreviewStream();
|
|
596
|
+
const requestId = ++this.previewRequestSeq;
|
|
597
|
+
this.SelectedObject = file;
|
|
598
|
+
this.IsLoadingPreview = true;
|
|
599
|
+
this.PreviewError = null;
|
|
600
|
+
this.PreviewUrl = null;
|
|
601
|
+
this.SafePreviewUrl = null;
|
|
602
|
+
this.PreviewTextContent = '';
|
|
603
|
+
this.PreviewKind = this.resolvePreviewKind(file.name, file.contentType);
|
|
604
|
+
this.cdr.detectChanges();
|
|
605
|
+
try {
|
|
606
|
+
const client = this.getStorageClient();
|
|
607
|
+
const signedUrl = await client.CreatePreAuthDownloadUrl(this.Account.account.ID, file.fullPath);
|
|
608
|
+
if (requestId !== this.previewRequestSeq) {
|
|
609
|
+
return;
|
|
610
|
+
}
|
|
611
|
+
const safeUrl = this.parseSafeHttpUrl(signedUrl);
|
|
612
|
+
if (!safeUrl) {
|
|
613
|
+
this.PreviewUrl = null;
|
|
614
|
+
this.SafePreviewUrl = null;
|
|
615
|
+
this.PreviewError = 'Invalid or unsupported download URL returned by storage provider.';
|
|
616
|
+
return;
|
|
617
|
+
}
|
|
618
|
+
this.PreviewUrl = safeUrl;
|
|
619
|
+
if (this.PreviewKind === 'pdf') {
|
|
620
|
+
this.SafePreviewUrl = this.sanitizer.bypassSecurityTrustResourceUrl(safeUrl);
|
|
621
|
+
}
|
|
622
|
+
else if (this.PreviewKind === 'text') {
|
|
623
|
+
if (Number.isFinite(file.size) && file.size > MAX_TEXT_PREVIEW_METADATA_BYTES) {
|
|
624
|
+
this.PreviewTextContent = `File is large (${this.FormatBytes(file.size)}) — click Download to view.`;
|
|
625
|
+
}
|
|
626
|
+
else {
|
|
627
|
+
const controller = new AbortController();
|
|
628
|
+
this.activePreviewAbort = controller;
|
|
629
|
+
const previewText = await this.readBoundedTextPreview(signedUrl, controller, MAX_TEXT_PREVIEW_READ_BYTES);
|
|
630
|
+
if (requestId !== this.previewRequestSeq) {
|
|
631
|
+
return;
|
|
632
|
+
}
|
|
633
|
+
this.PreviewTextContent = previewText;
|
|
634
|
+
}
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
catch (err) {
|
|
638
|
+
if (requestId !== this.previewRequestSeq) {
|
|
639
|
+
return;
|
|
640
|
+
}
|
|
641
|
+
if (err instanceof DOMException && err.name === 'AbortError') {
|
|
642
|
+
return;
|
|
643
|
+
}
|
|
644
|
+
this.PreviewError = err instanceof Error ? err.message : 'Failed to open remote preview stream.';
|
|
645
|
+
}
|
|
646
|
+
finally {
|
|
647
|
+
if (requestId === this.previewRequestSeq) {
|
|
648
|
+
this.IsLoadingPreview = false;
|
|
649
|
+
this.cdr.detectChanges();
|
|
650
|
+
}
|
|
651
|
+
}
|
|
652
|
+
}
|
|
653
|
+
ClosePreview() {
|
|
654
|
+
this.abortActivePreviewStream();
|
|
655
|
+
this.previewRequestSeq++;
|
|
656
|
+
this.SelectedObject = null;
|
|
657
|
+
this.PreviewUrl = null;
|
|
658
|
+
this.SafePreviewUrl = null;
|
|
659
|
+
this.PreviewError = null;
|
|
660
|
+
this.PreviewTextContent = '';
|
|
661
|
+
this.PreviewKind = 'none';
|
|
662
|
+
this.IsLoadingPreview = false;
|
|
663
|
+
}
|
|
664
|
+
abortActivePreviewStream() {
|
|
665
|
+
if (this.activePreviewAbort) {
|
|
666
|
+
this.activePreviewAbort.abort();
|
|
667
|
+
this.activePreviewAbort = null;
|
|
668
|
+
}
|
|
669
|
+
}
|
|
670
|
+
async readBoundedTextPreview(signedUrl, controller, maxBytes) {
|
|
671
|
+
const resp = await fetch(signedUrl, {
|
|
672
|
+
signal: controller.signal,
|
|
673
|
+
headers: { Range: `bytes=0-${maxBytes}` },
|
|
674
|
+
});
|
|
675
|
+
if (!resp.ok) {
|
|
676
|
+
throw new Error(`Could not stream text preview (${resp.status}).`);
|
|
677
|
+
}
|
|
678
|
+
const reader = resp.body?.getReader();
|
|
679
|
+
if (!reader) {
|
|
680
|
+
const fallback = await resp.text();
|
|
681
|
+
return fallback.length > maxBytes
|
|
682
|
+
? `${fallback.slice(0, maxBytes)}\n\n… [Preview truncated at 100 KB]`
|
|
683
|
+
: fallback;
|
|
684
|
+
}
|
|
685
|
+
const chunks = [];
|
|
686
|
+
let totalBytes = 0;
|
|
687
|
+
let truncated = false;
|
|
688
|
+
try {
|
|
689
|
+
while (true) {
|
|
690
|
+
const { done, value } = await reader.read();
|
|
691
|
+
if (done || !value) {
|
|
692
|
+
break;
|
|
693
|
+
}
|
|
694
|
+
const remaining = maxBytes - totalBytes;
|
|
695
|
+
if (value.byteLength >= remaining) {
|
|
696
|
+
chunks.push(value.subarray(0, remaining));
|
|
697
|
+
totalBytes += remaining;
|
|
698
|
+
truncated = true;
|
|
699
|
+
controller.abort();
|
|
700
|
+
void reader.cancel().catch(() => undefined);
|
|
701
|
+
break;
|
|
702
|
+
}
|
|
703
|
+
chunks.push(value);
|
|
704
|
+
totalBytes += value.byteLength;
|
|
705
|
+
}
|
|
706
|
+
}
|
|
707
|
+
catch (readErr) {
|
|
708
|
+
// Aborting the stream once we have collected maxBytes is intentional, not an error
|
|
709
|
+
if (totalBytes < maxBytes) {
|
|
710
|
+
throw readErr;
|
|
711
|
+
}
|
|
712
|
+
}
|
|
713
|
+
finally {
|
|
714
|
+
if (this.activePreviewAbort === controller) {
|
|
715
|
+
this.activePreviewAbort = null;
|
|
716
|
+
}
|
|
717
|
+
}
|
|
718
|
+
const merged = new Uint8Array(totalBytes);
|
|
719
|
+
let offset = 0;
|
|
720
|
+
for (const chunk of chunks) {
|
|
721
|
+
merged.set(chunk, offset);
|
|
722
|
+
offset += chunk.byteLength;
|
|
723
|
+
}
|
|
724
|
+
const decoded = new TextDecoder('utf-8').decode(merged);
|
|
725
|
+
return truncated ? `${decoded}\n\n… [Preview truncated at 100 KB]` : decoded;
|
|
726
|
+
}
|
|
727
|
+
DownloadSelectedObject() {
|
|
728
|
+
const safeUrl = this.parseSafeHttpUrl(this.PreviewUrl);
|
|
729
|
+
if (!safeUrl)
|
|
730
|
+
return;
|
|
731
|
+
window.open(safeUrl, '_blank', 'noopener,noreferrer');
|
|
732
|
+
}
|
|
733
|
+
parseSafeHttpUrl(rawUrl) {
|
|
734
|
+
if (!rawUrl || !rawUrl.trim()) {
|
|
735
|
+
return null;
|
|
736
|
+
}
|
|
737
|
+
try {
|
|
738
|
+
const parsed = new URL(rawUrl.trim());
|
|
739
|
+
if (parsed.protocol === 'https:' || parsed.protocol === 'http:') {
|
|
740
|
+
return parsed.toString();
|
|
741
|
+
}
|
|
742
|
+
return null;
|
|
743
|
+
}
|
|
744
|
+
catch {
|
|
745
|
+
return null;
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
async ConvertCopyToNativeLibrary() {
|
|
749
|
+
if (!this.SelectedObject || this.IsConvertingCopy)
|
|
750
|
+
return;
|
|
751
|
+
this.IsConvertingCopy = true;
|
|
752
|
+
this.cdr.detectChanges();
|
|
753
|
+
try {
|
|
754
|
+
const created = await this.creationService.ConvertRemoteDriveObjectToNativeArtifact({
|
|
755
|
+
AccountID: this.Account.account.ID,
|
|
756
|
+
ObjectPath: this.SelectedObject.fullPath,
|
|
757
|
+
FileName: this.SelectedObject.name,
|
|
758
|
+
ProviderType: this.Account.provider?.Name ?? this.Account.account?.Name ?? 'ConnectedDrive',
|
|
759
|
+
ETag: this.SelectedObject.etag || undefined,
|
|
760
|
+
RemoteModifiedAt: this.SelectedObject.lastModified instanceof Date
|
|
761
|
+
? this.SelectedObject.lastModified.toISOString()
|
|
762
|
+
: typeof this.SelectedObject.lastModified === 'string'
|
|
763
|
+
? this.SelectedObject.lastModified
|
|
764
|
+
: undefined,
|
|
765
|
+
EnvironmentID: this.EnvironmentId,
|
|
766
|
+
CurrentUser: this.CurrentUser,
|
|
767
|
+
Provider: this.ProviderToUse,
|
|
768
|
+
StorageClientOverride: this.getStorageClient(),
|
|
769
|
+
});
|
|
770
|
+
this.notifications.CreateSimpleNotification(`Created editable copy "${created.Artifact.Name}" in Library`, 'success', 3500);
|
|
771
|
+
this.ArtifactConverted.emit({
|
|
772
|
+
ArtifactId: created.Artifact.ID,
|
|
773
|
+
VersionNumber: created.Version.VersionNumber,
|
|
774
|
+
});
|
|
775
|
+
}
|
|
776
|
+
catch (err) {
|
|
777
|
+
this.notifications.CreateSimpleNotification(err instanceof Error ? err.message : 'Failed to convert remote file.', 'error', 4500);
|
|
778
|
+
}
|
|
779
|
+
finally {
|
|
780
|
+
this.IsConvertingCopy = false;
|
|
781
|
+
this.cdr.detectChanges();
|
|
782
|
+
}
|
|
783
|
+
}
|
|
784
|
+
GetFileIcon(name, contentType) {
|
|
785
|
+
const ext = this.getExtension(name);
|
|
786
|
+
const mime = (contentType ?? '').toLowerCase();
|
|
787
|
+
if (ext === 'pdf' || mime === 'application/pdf')
|
|
788
|
+
return 'fa-solid fa-file-pdf';
|
|
789
|
+
if (ext === 'docx' || ext === 'doc' || mime.includes('wordprocessingml'))
|
|
790
|
+
return 'fa-solid fa-file-word';
|
|
791
|
+
if (ext === 'xlsx' || ext === 'xls' || ext === 'csv' || mime.includes('spreadsheetml'))
|
|
792
|
+
return 'fa-solid fa-file-excel';
|
|
793
|
+
if (ext === 'pptx' || ext === 'ppt' || mime.includes('presentationml'))
|
|
794
|
+
return 'fa-solid fa-file-powerpoint';
|
|
795
|
+
if (mime.startsWith('image/') || ['png', 'jpg', 'jpeg', 'gif', 'webp', 'svg'].includes(ext))
|
|
796
|
+
return 'fa-solid fa-file-image';
|
|
797
|
+
if (mime.startsWith('video/') || ['mp4', 'webm', 'mov'].includes(ext))
|
|
798
|
+
return 'fa-solid fa-file-video';
|
|
799
|
+
if (mime.startsWith('audio/') || ['mp3', 'wav', 'm4a'].includes(ext))
|
|
800
|
+
return 'fa-solid fa-file-audio';
|
|
801
|
+
if (['md', 'markdown', 'txt'].includes(ext))
|
|
802
|
+
return 'fa-solid fa-file-lines';
|
|
803
|
+
if (['json', 'sql', 'ts', 'js', 'py', 'xml', 'yaml', 'yml'].includes(ext))
|
|
804
|
+
return 'fa-solid fa-file-code';
|
|
805
|
+
return 'fa-solid fa-file';
|
|
806
|
+
}
|
|
807
|
+
DescribeFileType(name, contentType) {
|
|
808
|
+
const ext = this.getExtension(name);
|
|
809
|
+
if (ext)
|
|
810
|
+
return ext.toUpperCase();
|
|
811
|
+
if (contentType && contentType !== 'application/octet-stream')
|
|
812
|
+
return contentType;
|
|
813
|
+
return 'File';
|
|
814
|
+
}
|
|
815
|
+
FormatBytes(bytes) {
|
|
816
|
+
if (!Number.isFinite(bytes) || bytes <= 0)
|
|
817
|
+
return '0 B';
|
|
818
|
+
const units = ['B', 'KB', 'MB', 'GB'];
|
|
819
|
+
let idx = 0;
|
|
820
|
+
let val = bytes;
|
|
821
|
+
while (val >= 1024 && idx < units.length - 1) {
|
|
822
|
+
val /= 1024;
|
|
823
|
+
idx++;
|
|
824
|
+
}
|
|
825
|
+
return `${idx === 0 ? val : val.toFixed(1)} ${units[idx]}`;
|
|
826
|
+
}
|
|
827
|
+
resolvePreviewKind(name, contentType) {
|
|
828
|
+
const ext = this.getExtension(name);
|
|
829
|
+
const mime = (contentType ?? '').toLowerCase();
|
|
830
|
+
if (ext === 'docx' || mime === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document')
|
|
831
|
+
return 'docx';
|
|
832
|
+
if (ext === 'xlsx' || ext === 'xls' || mime === 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet')
|
|
833
|
+
return 'xlsx';
|
|
834
|
+
if (ext === 'pdf' || mime === 'application/pdf')
|
|
835
|
+
return 'pdf';
|
|
836
|
+
if (mime.startsWith('image/') || ['png', 'jpg', 'jpeg', 'gif', 'webp', 'svg'].includes(ext))
|
|
837
|
+
return 'image';
|
|
838
|
+
if (mime.startsWith('video/') || ['mp4', 'webm', 'mov'].includes(ext))
|
|
839
|
+
return 'video';
|
|
840
|
+
if (mime.startsWith('audio/') || ['mp3', 'wav', 'ogg', 'm4a'].includes(ext))
|
|
841
|
+
return 'audio';
|
|
842
|
+
if (mime.startsWith('text/') ||
|
|
843
|
+
['md', 'markdown', 'txt', 'csv', 'json', 'sql', 'ts', 'js', 'py', 'xml', 'yaml', 'yml'].includes(ext)) {
|
|
844
|
+
return 'text';
|
|
845
|
+
}
|
|
846
|
+
return 'unsupported';
|
|
847
|
+
}
|
|
848
|
+
getExtension(name) {
|
|
849
|
+
const dot = name.lastIndexOf('.');
|
|
850
|
+
return dot >= 0 ? name.slice(dot + 1).trim().toLowerCase() : '';
|
|
851
|
+
}
|
|
852
|
+
getStorageClient() {
|
|
853
|
+
const targetProvider = (this.ProviderToUse ?? GraphQLDataProvider.Instance);
|
|
854
|
+
return this.StorageClientOverride ?? new GraphQLFileStorageClient(targetProvider);
|
|
855
|
+
}
|
|
856
|
+
static ɵfac = /*@__PURE__*/ (() => { let ɵLibraryRemoteDrivePaneComponent_BaseFactory; return function LibraryRemoteDrivePaneComponent_Factory(__ngFactoryType__) { return (ɵLibraryRemoteDrivePaneComponent_BaseFactory || (ɵLibraryRemoteDrivePaneComponent_BaseFactory = i0.ɵɵgetInheritedFactory(LibraryRemoteDrivePaneComponent)))(__ngFactoryType__ || LibraryRemoteDrivePaneComponent); }; })();
|
|
857
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LibraryRemoteDrivePaneComponent, selectors: [["mj-library-remote-drive-pane"]], inputs: { Account: "Account", CurrentPrefix: "CurrentPrefix", CurrentUser: "CurrentUser", EnvironmentId: "EnvironmentId", Collections: "Collections", ShowBackButton: "ShowBackButton", StorageClientOverride: "StorageClientOverride" }, outputs: { PrefixChange: "PrefixChange", BackRequested: "BackRequested", ArtifactConverted: "ArtifactConverted" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 26, vars: 15, consts: [["data-testid", "library-remote-drive-pane", 1, "remote-drive-shell"], [1, "remote-drive-toolbar"], [1, "remote-drive-breadcrumb"], ["type", "button", "mjButton", "", "variant", "flat", "size", "sm", "title", "Back to Connected Drives"], ["type", "button", 1, "crumb-btn", "crumb-root", 3, "click"], ["title", "Browsed dynamically from remote provider without creating MJ: Files rows", 1, "remote-live-pill"], [1, "fa-solid", "fa-bolt"], [1, "remote-drive-actions"], ["AriaLabel", "Filter or search remote drive files", 3, "ValueChange", "Placeholder", "Value"], ["type", "button", "mjButton", "", "variant", "secondary", "size", "sm", 3, "disabled"], ["type", "button", "mjButton", "", "variant", "flat", "size", "sm"], [3, "Clicked", "Loading"], [1, "remote-drive-body"], [1, "remote-list-pane"], [1, "remote-state"], ["Variant", "error", "Title", "Unable to browse connected drive", "ActionText", "Retry", "ActionIcon", "fa-solid fa-rotate-right", 3, "Message"], ["Icon", "fa-solid fa-cloud", 3, "Variant", "Title", "Message"], [1, "remote-table"], ["data-testid", "remote-stateless-preview", 1, "remote-preview-pane"], ["type", "button", "mjButton", "", "variant", "flat", "size", "sm", "title", "Back to Connected Drives", 3, "click"], [1, "fa-solid", "fa-arrow-left"], ["aria-hidden", "true", 1, "fa-solid", "fa-chevron-right", "crumb-sep"], ["type", "button", 1, "crumb-btn", 3, "click"], ["type", "button", "mjButton", "", "variant", "secondary", "size", "sm", 3, "click", "disabled"], [1, "fa-solid"], ["type", "button", "mjButton", "", "variant", "flat", "size", "sm", 3, "click"], ["text", "Listing remote folder...", "size", "medium"], ["Variant", "error", "Title", "Unable to browse connected drive", "ActionText", "Retry", "ActionIcon", "fa-solid fa-rotate-right", 3, "Action", "Message"], ["Variant", "no-results", "Title", "No matching remote files", "Message", "No files matched your search query in this connected drive."], [1, "remote-row", 3, "selected"], [1, "remote-row", 3, "click"], [1, "cell-name"], [1, "cell-muted"], [1, "remote-row", "folder-row"], [1, "remote-row", "folder-row", 3, "click"], [1, "fa-solid", "fa-folder", "folder-glyph"], [1, "folder-label"], [1, "remote-preview-header"], [1, "preview-title-group"], [1, "preview-title-text"], [1, "preview-filename", 3, "title"], [1, "preview-submeta"], [1, "preview-header-actions"], ["type", "button", "mjButton", "", "variant", "primary", "size", "sm", "title", "Import an editable copy into Native Library as an MJ Document or Spreadsheet", 3, "disabled"], ["type", "button", "mjButton", "", "variant", "secondary", "size", "sm", "title", "Download file from Connected Drive", 3, "click", "disabled"], [1, "fa-solid", "fa-download"], ["type", "button", "mjButton", "", "variant", "flat", "size", "sm", "aria-label", "Close remote preview", 3, "click"], [1, "fa-solid", "fa-xmark"], [1, "remote-preview-body"], ["Variant", "error", "Title", "Preview unavailable", 3, "Message"], ["type", "button", "mjButton", "", "variant", "primary", "size", "sm", "title", "Import an editable copy into Native Library as an MJ Document or Spreadsheet", 3, "click", "disabled"], ["text", "Opening remote stream...", "size", "medium"], [3, "Url"], [1, "remote-media-stage"], [1, "remote-text-preview"], ["Icon", "fa-solid fa-file-arrow-down", "Title", "Inline preview not available for this format", "Message", "Click Download above to open this remote file locally."], [1, "remote-pdf-frame", 3, "src", "title"], [1, "remote-image", 3, "src", "alt"], ["controls", "", 1, "remote-video", 3, "src"], ["controls", "", 3, "src"]], template: function LibraryRemoteDrivePaneComponent_Template(rf, ctx) { if (rf & 1) {
|
|
858
|
+
i0.ɵɵelementStart(0, "div", 0)(1, "div", 1)(2, "div", 2);
|
|
859
|
+
i0.ɵɵconditionalCreate(3, LibraryRemoteDrivePaneComponent_Conditional_3_Template, 2, 0, "button", 3);
|
|
860
|
+
i0.ɵɵelementStart(4, "button", 4);
|
|
861
|
+
i0.ɵɵlistener("click", function LibraryRemoteDrivePaneComponent_Template_button_click_4_listener() { return ctx.NavigateToPrefix(""); });
|
|
862
|
+
i0.ɵɵelement(5, "i");
|
|
863
|
+
i0.ɵɵelementStart(6, "span");
|
|
864
|
+
i0.ɵɵtext(7);
|
|
865
|
+
i0.ɵɵelementEnd()();
|
|
866
|
+
i0.ɵɵrepeaterCreate(8, LibraryRemoteDrivePaneComponent_For_9_Template, 3, 3, null, null, _forTrack0);
|
|
867
|
+
i0.ɵɵelementStart(10, "span", 5);
|
|
868
|
+
i0.ɵɵelement(11, "i", 6);
|
|
869
|
+
i0.ɵɵtext(12, " Live Remote \u00B7 Stateless ");
|
|
870
|
+
i0.ɵɵelementEnd()();
|
|
871
|
+
i0.ɵɵelementStart(13, "div", 7)(14, "mj-page-search", 8);
|
|
872
|
+
i0.ɵɵlistener("ValueChange", function LibraryRemoteDrivePaneComponent_Template_mj_page_search_ValueChange_14_listener($event) { return ctx.OnSearchChanged($event); });
|
|
873
|
+
i0.ɵɵelementEnd();
|
|
874
|
+
i0.ɵɵconditionalCreate(15, LibraryRemoteDrivePaneComponent_Conditional_15_Template, 3, 7, "button", 9);
|
|
875
|
+
i0.ɵɵconditionalCreate(16, LibraryRemoteDrivePaneComponent_Conditional_16_Template, 2, 0, "button", 10);
|
|
876
|
+
i0.ɵɵelementStart(17, "mj-refresh-button", 11);
|
|
877
|
+
i0.ɵɵlistener("Clicked", function LibraryRemoteDrivePaneComponent_Template_mj_refresh_button_Clicked_17_listener() { return ctx.ReloadListing(); });
|
|
878
|
+
i0.ɵɵelementEnd()()();
|
|
879
|
+
i0.ɵɵelementStart(18, "div", 12)(19, "div", 13);
|
|
880
|
+
i0.ɵɵconditionalCreate(20, LibraryRemoteDrivePaneComponent_Conditional_20_Template, 2, 0, "div", 14)(21, LibraryRemoteDrivePaneComponent_Conditional_21_Template, 1, 1, "mj-empty-state", 15)(22, LibraryRemoteDrivePaneComponent_Conditional_22_Template, 2, 1)(23, LibraryRemoteDrivePaneComponent_Conditional_23_Template, 1, 3, "mj-empty-state", 16)(24, LibraryRemoteDrivePaneComponent_Conditional_24_Template, 16, 0, "table", 17);
|
|
881
|
+
i0.ɵɵelementEnd();
|
|
882
|
+
i0.ɵɵconditionalCreate(25, LibraryRemoteDrivePaneComponent_Conditional_25_Template, 25, 8, "aside", 18);
|
|
883
|
+
i0.ɵɵelementEnd()();
|
|
884
|
+
} if (rf & 2) {
|
|
885
|
+
i0.ɵɵadvance(3);
|
|
886
|
+
i0.ɵɵconditional(ctx.ShowBackButton ? 3 : -1);
|
|
887
|
+
i0.ɵɵadvance();
|
|
888
|
+
i0.ɵɵclassProp("crumb-active", ctx.Breadcrumbs.length === 0);
|
|
889
|
+
i0.ɵɵadvance();
|
|
890
|
+
i0.ɵɵclassMap(ctx.ProviderIcon);
|
|
891
|
+
i0.ɵɵadvance(2);
|
|
892
|
+
i0.ɵɵtextInterpolate(ctx.Account.account.Name);
|
|
893
|
+
i0.ɵɵadvance();
|
|
894
|
+
i0.ɵɵrepeater(ctx.Breadcrumbs);
|
|
895
|
+
i0.ɵɵadvance(6);
|
|
896
|
+
i0.ɵɵproperty("Placeholder", ctx.SupportsProviderSearch ? "Search remote drive..." : "Filter current folder...")("Value", ctx.SearchTerm);
|
|
897
|
+
i0.ɵɵadvance();
|
|
898
|
+
i0.ɵɵconditional(ctx.SupportsProviderSearch && ctx.SearchTerm.trim().length >= 2 ? 15 : -1);
|
|
899
|
+
i0.ɵɵadvance();
|
|
900
|
+
i0.ɵɵconditional(ctx.RemoteSearchResults !== null ? 16 : -1);
|
|
901
|
+
i0.ɵɵadvance();
|
|
902
|
+
i0.ɵɵproperty("Loading", ctx.IsLoading);
|
|
903
|
+
i0.ɵɵadvance();
|
|
904
|
+
i0.ɵɵclassProp("has-preview", ctx.SelectedObject !== null);
|
|
905
|
+
i0.ɵɵadvance(2);
|
|
906
|
+
i0.ɵɵconditional(ctx.IsLoading ? 20 : ctx.ErrorMessage ? 21 : ctx.RemoteSearchResults !== null ? 22 : ctx.FilteredFolders.length === 0 && ctx.FilteredFiles.length === 0 ? 23 : 24);
|
|
907
|
+
i0.ɵɵadvance(5);
|
|
908
|
+
i0.ɵɵconditional(ctx.SelectedObject ? 25 : -1);
|
|
909
|
+
} }, dependencies: [i1.MJButtonDirective, i1.MJEmptyStateComponent, i1.MJPageSearchComponent, i1.MJRefreshButtonComponent, i2.DocxPreviewComponent, i2.XlsxPreviewComponent, i3.LoadingComponent, i4.DatePipe], styles: ["[_nghost-%COMP%] {\n display: flex;\n flex-direction: column;\n flex: 1;\n min-height: 0;\n min-width: 0;\n }\n\n .remote-drive-shell[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n flex: 1;\n min-height: 0;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-lg);\n overflow: hidden;\n }\n\n .remote-drive-toolbar[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: space-between;\n flex-wrap: wrap;\n gap: var(--mj-space-3);\n padding: var(--mj-space-3) var(--mj-space-4);\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .remote-drive-breadcrumb[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n gap: var(--mj-space-2);\n min-width: 0;\n }\n\n .crumb-btn[_ngcontent-%COMP%] {\n display: inline-flex;\n align-items: center;\n gap: var(--mj-space-1-5);\n padding: 4px 8px;\n border: none;\n border-radius: var(--mj-radius-sm);\n background: transparent;\n color: var(--mj-text-secondary);\n font-size: var(--mj-text-sm);\n font-weight: 500;\n cursor: pointer;\n transition: background-color 0.15s ease, color 0.15s ease;\n }\n\n .crumb-btn[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n }\n\n .crumb-btn.crumb-active[_ngcontent-%COMP%] {\n color: var(--mj-text-primary);\n font-weight: 600;\n }\n\n .crumb-sep[_ngcontent-%COMP%] {\n font-size: 10px;\n color: var(--mj-text-disabled);\n }\n\n .remote-live-pill[_ngcontent-%COMP%] {\n display: inline-flex;\n align-items: center;\n gap: 5px;\n padding: 2px 8px;\n border-radius: var(--mj-radius-full);\n font-size: 11px;\n font-weight: 600;\n color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n border: 1px solid color-mix(in srgb, var(--mj-brand-primary) 24%, var(--mj-border-default));\n }\n\n .remote-drive-actions[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2);\n }\n\n .remote-drive-body[_ngcontent-%COMP%] {\n display: grid;\n grid-template-columns: minmax(0, 1fr);\n flex: 1;\n min-height: 0;\n }\n\n .remote-drive-body.has-preview[_ngcontent-%COMP%] {\n grid-template-columns: minmax(280px, 44%) minmax(340px, 56%);\n }\n\n .remote-list-pane[_ngcontent-%COMP%] {\n overflow: auto;\n min-height: 280px;\n }\n\n .remote-state[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 240px;\n padding: var(--mj-space-6);\n }\n\n .remote-table[_ngcontent-%COMP%] {\n width: 100%;\n border-collapse: collapse;\n font-size: var(--mj-text-sm);\n }\n\n .remote-table[_ngcontent-%COMP%] thead[_ngcontent-%COMP%] th[_ngcontent-%COMP%] {\n position: sticky;\n top: 0;\n z-index: 1;\n text-align: left;\n padding: 10px var(--mj-space-4);\n font-size: 11px;\n font-weight: 600;\n text-transform: uppercase;\n letter-spacing: 0.04em;\n color: var(--mj-text-muted);\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .remote-row[_ngcontent-%COMP%] {\n cursor: pointer;\n border-bottom: 1px solid var(--mj-border-subtle);\n transition: background-color 0.12s ease;\n }\n\n .remote-row[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n }\n\n .remote-row.selected[_ngcontent-%COMP%] {\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n }\n\n .remote-row[_ngcontent-%COMP%] td[_ngcontent-%COMP%] {\n padding: 10px var(--mj-space-4);\n vertical-align: middle;\n }\n\n .cell-name[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2-5);\n color: var(--mj-text-primary);\n font-weight: 500;\n }\n\n .folder-glyph[_ngcontent-%COMP%] {\n color: var(--mj-brand-primary);\n font-size: 15px;\n }\n\n .folder-label[_ngcontent-%COMP%] {\n font-weight: 600;\n }\n\n .cell-muted[_ngcontent-%COMP%] {\n color: var(--mj-text-muted);\n white-space: nowrap;\n }\n\n .remote-preview-pane[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n min-height: 0;\n border-left: 1px solid var(--mj-border-default);\n background: var(--mj-bg-surface);\n }\n\n .remote-preview-header[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: var(--mj-space-3);\n padding: var(--mj-space-3) var(--mj-space-4);\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .preview-title-group[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2-5);\n min-width: 0;\n }\n\n .preview-title-group[_ngcontent-%COMP%] > i[_ngcontent-%COMP%] {\n font-size: 18px;\n color: var(--mj-brand-primary);\n }\n\n .preview-title-text[_ngcontent-%COMP%] {\n min-width: 0;\n }\n\n .preview-filename[_ngcontent-%COMP%] {\n font-size: var(--mj-text-sm);\n font-weight: 600;\n color: var(--mj-text-primary);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .preview-submeta[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: 11px;\n color: var(--mj-text-muted);\n }\n\n .preview-header-actions[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2);\n flex-shrink: 0;\n }\n\n .remote-preview-body[_ngcontent-%COMP%] {\n flex: 1;\n min-height: 0;\n overflow: auto;\n display: flex;\n flex-direction: column;\n }\n\n .remote-pdf-frame[_ngcontent-%COMP%] {\n width: 100%;\n flex: 1;\n min-height: 480px;\n border: none;\n }\n\n .remote-media-stage[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n flex: 1;\n padding: var(--mj-space-6);\n background: var(--mj-bg-surface-sunken);\n }\n\n .remote-image[_ngcontent-%COMP%] {\n max-width: 100%;\n max-height: 70vh;\n border-radius: var(--mj-radius-md);\n box-shadow: var(--mj-shadow-md);\n }\n\n .remote-video[_ngcontent-%COMP%] {\n max-width: 100%;\n max-height: 70vh;\n border-radius: var(--mj-radius-md);\n }\n\n .remote-text-preview[_ngcontent-%COMP%] {\n margin: 0;\n padding: var(--mj-space-5);\n font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;\n font-size: 12.5px;\n line-height: 1.6;\n color: var(--mj-text-primary);\n white-space: pre-wrap;\n word-break: break-word;\n }\n\n @media (max-width: 960px) {\n .remote-drive-body.has-preview[_ngcontent-%COMP%] {\n grid-template-columns: 1fr;\n }\n .remote-preview-pane[_ngcontent-%COMP%] {\n border-left: none;\n border-top: 1px solid var(--mj-border-default);\n }\n }"] });
|
|
910
|
+
}
|
|
911
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LibraryRemoteDrivePaneComponent, [{
|
|
912
|
+
type: Component,
|
|
913
|
+
args: [{ standalone: false, selector: 'mj-library-remote-drive-pane', template: `
|
|
914
|
+
<div class="remote-drive-shell" data-testid="library-remote-drive-pane">
|
|
915
|
+
<!-- Drive Interior Toolbar -->
|
|
916
|
+
<div class="remote-drive-toolbar">
|
|
917
|
+
<div class="remote-drive-breadcrumb">
|
|
918
|
+
@if (ShowBackButton) {
|
|
919
|
+
<button
|
|
920
|
+
type="button"
|
|
921
|
+
mjButton
|
|
922
|
+
variant="flat"
|
|
923
|
+
size="sm"
|
|
924
|
+
(click)="BackRequested.emit()"
|
|
925
|
+
title="Back to Connected Drives"
|
|
926
|
+
>
|
|
927
|
+
<i class="fa-solid fa-arrow-left"></i>
|
|
928
|
+
</button>
|
|
929
|
+
}
|
|
930
|
+
<button
|
|
931
|
+
type="button"
|
|
932
|
+
class="crumb-btn crumb-root"
|
|
933
|
+
[class.crumb-active]="Breadcrumbs.length === 0"
|
|
934
|
+
(click)="NavigateToPrefix('')"
|
|
935
|
+
>
|
|
936
|
+
<i [class]="ProviderIcon"></i>
|
|
937
|
+
<span>{{ Account.account.Name }}</span>
|
|
938
|
+
</button>
|
|
939
|
+
@for (crumb of Breadcrumbs; track crumb.FullPrefix; let isLast = $last) {
|
|
940
|
+
<i class="fa-solid fa-chevron-right crumb-sep" aria-hidden="true"></i>
|
|
941
|
+
<button
|
|
942
|
+
type="button"
|
|
943
|
+
class="crumb-btn"
|
|
944
|
+
[class.crumb-active]="isLast"
|
|
945
|
+
(click)="NavigateToPrefix(crumb.FullPrefix)"
|
|
946
|
+
>
|
|
947
|
+
{{ crumb.Name }}
|
|
948
|
+
</button>
|
|
949
|
+
}
|
|
950
|
+
<span class="remote-live-pill" title="Browsed dynamically from remote provider without creating MJ: Files rows">
|
|
951
|
+
<i class="fa-solid fa-bolt"></i>
|
|
952
|
+
Live Remote · Stateless
|
|
953
|
+
</span>
|
|
954
|
+
</div>
|
|
955
|
+
|
|
956
|
+
<div class="remote-drive-actions">
|
|
957
|
+
<mj-page-search
|
|
958
|
+
AriaLabel="Filter or search remote drive files"
|
|
959
|
+
[Placeholder]="SupportsProviderSearch ? 'Search remote drive...' : 'Filter current folder...'"
|
|
960
|
+
[Value]="SearchTerm"
|
|
961
|
+
(ValueChange)="OnSearchChanged($event)"
|
|
962
|
+
></mj-page-search>
|
|
963
|
+
@if (SupportsProviderSearch && SearchTerm.trim().length >= 2) {
|
|
964
|
+
<button
|
|
965
|
+
type="button"
|
|
966
|
+
mjButton
|
|
967
|
+
variant="secondary"
|
|
968
|
+
size="sm"
|
|
969
|
+
[disabled]="IsSearchingRemote"
|
|
970
|
+
(click)="RunRemoteSearch()"
|
|
971
|
+
>
|
|
972
|
+
<i class="fa-solid" [class.fa-magnifying-glass]="!IsSearchingRemote" [class.fa-spinner]="IsSearchingRemote" [class.fa-spin]="IsSearchingRemote"></i>
|
|
973
|
+
Search Drive
|
|
974
|
+
</button>
|
|
975
|
+
}
|
|
976
|
+
@if (RemoteSearchResults !== null) {
|
|
977
|
+
<button type="button" mjButton variant="flat" size="sm" (click)="ClearRemoteSearch()">
|
|
978
|
+
Clear Search
|
|
979
|
+
</button>
|
|
980
|
+
}
|
|
981
|
+
<mj-refresh-button [Loading]="IsLoading" (Clicked)="ReloadListing()"></mj-refresh-button>
|
|
982
|
+
</div>
|
|
983
|
+
</div>
|
|
984
|
+
|
|
985
|
+
<!-- Main Body: Split between Folder/File list and Inline Stateless Preview -->
|
|
986
|
+
<div class="remote-drive-body" [class.has-preview]="SelectedObject !== null">
|
|
987
|
+
<div class="remote-list-pane">
|
|
988
|
+
@if (IsLoading) {
|
|
989
|
+
<div class="remote-state">
|
|
990
|
+
<mj-loading text="Listing remote folder..." size="medium"></mj-loading>
|
|
991
|
+
</div>
|
|
992
|
+
} @else if (ErrorMessage) {
|
|
993
|
+
<mj-empty-state
|
|
994
|
+
Variant="error"
|
|
995
|
+
Title="Unable to browse connected drive"
|
|
996
|
+
[Message]="ErrorMessage"
|
|
997
|
+
ActionText="Retry"
|
|
998
|
+
ActionIcon="fa-solid fa-rotate-right"
|
|
999
|
+
(Action)="ReloadListing()"
|
|
1000
|
+
></mj-empty-state>
|
|
1001
|
+
} @else if (RemoteSearchResults !== null) {
|
|
1002
|
+
@if (RemoteSearchResults.length === 0) {
|
|
1003
|
+
<mj-empty-state
|
|
1004
|
+
Variant="no-results"
|
|
1005
|
+
Title="No matching remote files"
|
|
1006
|
+
Message="No files matched your search query in this connected drive."
|
|
1007
|
+
></mj-empty-state>
|
|
1008
|
+
} @else {
|
|
1009
|
+
<table class="remote-table">
|
|
1010
|
+
<thead>
|
|
1011
|
+
<tr>
|
|
1012
|
+
<th>Name</th>
|
|
1013
|
+
<th>Path</th>
|
|
1014
|
+
<th>Size</th>
|
|
1015
|
+
<th>Modified</th>
|
|
1016
|
+
</tr>
|
|
1017
|
+
</thead>
|
|
1018
|
+
<tbody>
|
|
1019
|
+
@for (hit of RemoteSearchResults; track hit.path) {
|
|
1020
|
+
<tr
|
|
1021
|
+
class="remote-row"
|
|
1022
|
+
[class.selected]="SelectedObject?.fullPath === hit.path"
|
|
1023
|
+
(click)="SelectSearchHit(hit)"
|
|
1024
|
+
>
|
|
1025
|
+
<td class="cell-name">
|
|
1026
|
+
<i [class]="GetFileIcon(hit.name, hit.contentType)"></i>
|
|
1027
|
+
<span>{{ hit.name }}</span>
|
|
1028
|
+
</td>
|
|
1029
|
+
<td class="cell-muted">{{ hit.path }}</td>
|
|
1030
|
+
<td class="cell-muted">{{ FormatBytes(hit.size) }}</td>
|
|
1031
|
+
<td class="cell-muted">{{ hit.lastModified | date: 'mediumDate' }}</td>
|
|
1032
|
+
</tr>
|
|
1033
|
+
}
|
|
1034
|
+
</tbody>
|
|
1035
|
+
</table>
|
|
1036
|
+
}
|
|
1037
|
+
} @else if (FilteredFolders.length === 0 && FilteredFiles.length === 0) {
|
|
1038
|
+
<mj-empty-state
|
|
1039
|
+
[Variant]="SearchTerm ? 'no-results' : 'empty'"
|
|
1040
|
+
Icon="fa-solid fa-cloud"
|
|
1041
|
+
[Title]="SearchTerm ? 'No matching items in folder' : 'This folder is empty'"
|
|
1042
|
+
[Message]="SearchTerm ? 'Try clearing the filter or searching across the entire drive.' : 'Remote files in this connected drive appear dynamically here.'"
|
|
1043
|
+
></mj-empty-state>
|
|
1044
|
+
} @else {
|
|
1045
|
+
<table class="remote-table">
|
|
1046
|
+
<thead>
|
|
1047
|
+
<tr>
|
|
1048
|
+
<th>Name</th>
|
|
1049
|
+
<th>Type</th>
|
|
1050
|
+
<th>Size</th>
|
|
1051
|
+
<th>Last Modified</th>
|
|
1052
|
+
</tr>
|
|
1053
|
+
</thead>
|
|
1054
|
+
<tbody>
|
|
1055
|
+
@for (folder of FilteredFolders; track folder.FullPrefix) {
|
|
1056
|
+
<tr class="remote-row folder-row" (click)="NavigateToPrefix(folder.FullPrefix)">
|
|
1057
|
+
<td class="cell-name">
|
|
1058
|
+
<i class="fa-solid fa-folder folder-glyph"></i>
|
|
1059
|
+
<span class="folder-label">{{ folder.Name }}</span>
|
|
1060
|
+
</td>
|
|
1061
|
+
<td class="cell-muted">Folder</td>
|
|
1062
|
+
<td class="cell-muted">—</td>
|
|
1063
|
+
<td class="cell-muted">—</td>
|
|
1064
|
+
</tr>
|
|
1065
|
+
}
|
|
1066
|
+
@for (file of FilteredFiles; track file.fullPath) {
|
|
1067
|
+
<tr
|
|
1068
|
+
class="remote-row"
|
|
1069
|
+
[class.selected]="SelectedObject?.fullPath === file.fullPath"
|
|
1070
|
+
(click)="SelectRemoteFile(file)"
|
|
1071
|
+
>
|
|
1072
|
+
<td class="cell-name">
|
|
1073
|
+
<i [class]="GetFileIcon(file.name, file.contentType)"></i>
|
|
1074
|
+
<span>{{ file.name }}</span>
|
|
1075
|
+
</td>
|
|
1076
|
+
<td class="cell-muted">{{ DescribeFileType(file.name, file.contentType) }}</td>
|
|
1077
|
+
<td class="cell-muted">{{ FormatBytes(file.size) }}</td>
|
|
1078
|
+
<td class="cell-muted">{{ file.lastModified | date: 'short' }}</td>
|
|
1079
|
+
</tr>
|
|
1080
|
+
}
|
|
1081
|
+
</tbody>
|
|
1082
|
+
</table>
|
|
1083
|
+
}
|
|
1084
|
+
</div>
|
|
1085
|
+
|
|
1086
|
+
<!-- Stateless Inline Remote Preview Drawer -->
|
|
1087
|
+
@if (SelectedObject) {
|
|
1088
|
+
<aside class="remote-preview-pane" data-testid="remote-stateless-preview">
|
|
1089
|
+
<header class="remote-preview-header">
|
|
1090
|
+
<div class="preview-title-group">
|
|
1091
|
+
<i [class]="GetFileIcon(SelectedObject.name, SelectedObject.contentType)"></i>
|
|
1092
|
+
<div class="preview-title-text">
|
|
1093
|
+
<div class="preview-filename" [title]="SelectedObject.name">{{ SelectedObject.name }}</div>
|
|
1094
|
+
<div class="preview-submeta">
|
|
1095
|
+
<span>{{ FormatBytes(SelectedObject.size) }}</span>
|
|
1096
|
+
<span>·</span>
|
|
1097
|
+
<span>Streamed dynamically (no MJ: Files record)</span>
|
|
1098
|
+
</div>
|
|
1099
|
+
</div>
|
|
1100
|
+
</div>
|
|
1101
|
+
<div class="preview-header-actions">
|
|
1102
|
+
@if (CanConvertSelectedObject) {
|
|
1103
|
+
<button
|
|
1104
|
+
type="button"
|
|
1105
|
+
mjButton
|
|
1106
|
+
variant="primary"
|
|
1107
|
+
size="sm"
|
|
1108
|
+
[disabled]="IsConvertingCopy"
|
|
1109
|
+
(click)="ConvertCopyToNativeLibrary()"
|
|
1110
|
+
title="Import an editable copy into Native Library as an MJ Document or Spreadsheet"
|
|
1111
|
+
>
|
|
1112
|
+
<i
|
|
1113
|
+
class="fa-solid"
|
|
1114
|
+
[class.fa-wand-magic-sparkles]="!IsConvertingCopy"
|
|
1115
|
+
[class.fa-spinner]="IsConvertingCopy"
|
|
1116
|
+
[class.fa-spin]="IsConvertingCopy"
|
|
1117
|
+
></i>
|
|
1118
|
+
{{ IsConvertingCopy ? 'Converting…' : 'Open Copy in Studio' }}
|
|
1119
|
+
</button>
|
|
1120
|
+
}
|
|
1121
|
+
<button
|
|
1122
|
+
type="button"
|
|
1123
|
+
mjButton
|
|
1124
|
+
variant="secondary"
|
|
1125
|
+
size="sm"
|
|
1126
|
+
[disabled]="!PreviewUrl"
|
|
1127
|
+
(click)="DownloadSelectedObject()"
|
|
1128
|
+
title="Download file from Connected Drive"
|
|
1129
|
+
>
|
|
1130
|
+
<i class="fa-solid fa-download"></i>
|
|
1131
|
+
Download
|
|
1132
|
+
</button>
|
|
1133
|
+
<button
|
|
1134
|
+
type="button"
|
|
1135
|
+
mjButton
|
|
1136
|
+
variant="flat"
|
|
1137
|
+
size="sm"
|
|
1138
|
+
(click)="ClosePreview()"
|
|
1139
|
+
aria-label="Close remote preview"
|
|
1140
|
+
>
|
|
1141
|
+
<i class="fa-solid fa-xmark"></i>
|
|
1142
|
+
</button>
|
|
1143
|
+
</div>
|
|
1144
|
+
</header>
|
|
1145
|
+
|
|
1146
|
+
<div class="remote-preview-body">
|
|
1147
|
+
@if (IsLoadingPreview) {
|
|
1148
|
+
<div class="remote-state">
|
|
1149
|
+
<mj-loading text="Opening remote stream..." size="medium"></mj-loading>
|
|
1150
|
+
</div>
|
|
1151
|
+
} @else if (PreviewError) {
|
|
1152
|
+
<mj-empty-state
|
|
1153
|
+
Variant="error"
|
|
1154
|
+
Title="Preview unavailable"
|
|
1155
|
+
[Message]="PreviewError"
|
|
1156
|
+
></mj-empty-state>
|
|
1157
|
+
} @else {
|
|
1158
|
+
@switch (PreviewKind) {
|
|
1159
|
+
@case ('docx') {
|
|
1160
|
+
<mj-docx-preview [Url]="PreviewUrl"></mj-docx-preview>
|
|
1161
|
+
}
|
|
1162
|
+
@case ('xlsx') {
|
|
1163
|
+
<mj-xlsx-preview [Url]="PreviewUrl"></mj-xlsx-preview>
|
|
1164
|
+
}
|
|
1165
|
+
@case ('pdf') {
|
|
1166
|
+
@if (SafePreviewUrl) {
|
|
1167
|
+
<iframe
|
|
1168
|
+
class="remote-pdf-frame"
|
|
1169
|
+
[src]="SafePreviewUrl"
|
|
1170
|
+
[title]="SelectedObject.name"
|
|
1171
|
+
></iframe>
|
|
1172
|
+
}
|
|
1173
|
+
}
|
|
1174
|
+
@case ('image') {
|
|
1175
|
+
<div class="remote-media-stage">
|
|
1176
|
+
<img class="remote-image" [src]="PreviewUrl" [alt]="SelectedObject.name" />
|
|
1177
|
+
</div>
|
|
1178
|
+
}
|
|
1179
|
+
@case ('video') {
|
|
1180
|
+
<div class="remote-media-stage">
|
|
1181
|
+
<video class="remote-video" controls [src]="PreviewUrl"></video>
|
|
1182
|
+
</div>
|
|
1183
|
+
}
|
|
1184
|
+
@case ('audio') {
|
|
1185
|
+
<div class="remote-media-stage">
|
|
1186
|
+
<audio controls [src]="PreviewUrl"></audio>
|
|
1187
|
+
</div>
|
|
1188
|
+
}
|
|
1189
|
+
@case ('text') {
|
|
1190
|
+
<pre class="remote-text-preview">{{ PreviewTextContent }}</pre>
|
|
1191
|
+
}
|
|
1192
|
+
@default {
|
|
1193
|
+
<mj-empty-state
|
|
1194
|
+
Icon="fa-solid fa-file-arrow-down"
|
|
1195
|
+
Title="Inline preview not available for this format"
|
|
1196
|
+
Message="Click Download above to open this remote file locally."
|
|
1197
|
+
></mj-empty-state>
|
|
1198
|
+
}
|
|
1199
|
+
}
|
|
1200
|
+
}
|
|
1201
|
+
</div>
|
|
1202
|
+
</aside>
|
|
1203
|
+
}
|
|
1204
|
+
</div>
|
|
1205
|
+
</div>
|
|
1206
|
+
`, styles: ["\n :host {\n display: flex;\n flex-direction: column;\n flex: 1;\n min-height: 0;\n min-width: 0;\n }\n\n .remote-drive-shell {\n display: flex;\n flex-direction: column;\n flex: 1;\n min-height: 0;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-lg);\n overflow: hidden;\n }\n\n .remote-drive-toolbar {\n display: flex;\n align-items: center;\n justify-content: space-between;\n flex-wrap: wrap;\n gap: var(--mj-space-3);\n padding: var(--mj-space-3) var(--mj-space-4);\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .remote-drive-breadcrumb {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n gap: var(--mj-space-2);\n min-width: 0;\n }\n\n .crumb-btn {\n display: inline-flex;\n align-items: center;\n gap: var(--mj-space-1-5);\n padding: 4px 8px;\n border: none;\n border-radius: var(--mj-radius-sm);\n background: transparent;\n color: var(--mj-text-secondary);\n font-size: var(--mj-text-sm);\n font-weight: 500;\n cursor: pointer;\n transition: background-color 0.15s ease, color 0.15s ease;\n }\n\n .crumb-btn:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n }\n\n .crumb-btn.crumb-active {\n color: var(--mj-text-primary);\n font-weight: 600;\n }\n\n .crumb-sep {\n font-size: 10px;\n color: var(--mj-text-disabled);\n }\n\n .remote-live-pill {\n display: inline-flex;\n align-items: center;\n gap: 5px;\n padding: 2px 8px;\n border-radius: var(--mj-radius-full);\n font-size: 11px;\n font-weight: 600;\n color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n border: 1px solid color-mix(in srgb, var(--mj-brand-primary) 24%, var(--mj-border-default));\n }\n\n .remote-drive-actions {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2);\n }\n\n .remote-drive-body {\n display: grid;\n grid-template-columns: minmax(0, 1fr);\n flex: 1;\n min-height: 0;\n }\n\n .remote-drive-body.has-preview {\n grid-template-columns: minmax(280px, 44%) minmax(340px, 56%);\n }\n\n .remote-list-pane {\n overflow: auto;\n min-height: 280px;\n }\n\n .remote-state {\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 240px;\n padding: var(--mj-space-6);\n }\n\n .remote-table {\n width: 100%;\n border-collapse: collapse;\n font-size: var(--mj-text-sm);\n }\n\n .remote-table thead th {\n position: sticky;\n top: 0;\n z-index: 1;\n text-align: left;\n padding: 10px var(--mj-space-4);\n font-size: 11px;\n font-weight: 600;\n text-transform: uppercase;\n letter-spacing: 0.04em;\n color: var(--mj-text-muted);\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .remote-row {\n cursor: pointer;\n border-bottom: 1px solid var(--mj-border-subtle);\n transition: background-color 0.12s ease;\n }\n\n .remote-row:hover {\n background: var(--mj-bg-surface-hover);\n }\n\n .remote-row.selected {\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n }\n\n .remote-row td {\n padding: 10px var(--mj-space-4);\n vertical-align: middle;\n }\n\n .cell-name {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2-5);\n color: var(--mj-text-primary);\n font-weight: 500;\n }\n\n .folder-glyph {\n color: var(--mj-brand-primary);\n font-size: 15px;\n }\n\n .folder-label {\n font-weight: 600;\n }\n\n .cell-muted {\n color: var(--mj-text-muted);\n white-space: nowrap;\n }\n\n .remote-preview-pane {\n display: flex;\n flex-direction: column;\n min-height: 0;\n border-left: 1px solid var(--mj-border-default);\n background: var(--mj-bg-surface);\n }\n\n .remote-preview-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: var(--mj-space-3);\n padding: var(--mj-space-3) var(--mj-space-4);\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .preview-title-group {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2-5);\n min-width: 0;\n }\n\n .preview-title-group > i {\n font-size: 18px;\n color: var(--mj-brand-primary);\n }\n\n .preview-title-text {\n min-width: 0;\n }\n\n .preview-filename {\n font-size: var(--mj-text-sm);\n font-weight: 600;\n color: var(--mj-text-primary);\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .preview-submeta {\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: 11px;\n color: var(--mj-text-muted);\n }\n\n .preview-header-actions {\n display: flex;\n align-items: center;\n gap: var(--mj-space-2);\n flex-shrink: 0;\n }\n\n .remote-preview-body {\n flex: 1;\n min-height: 0;\n overflow: auto;\n display: flex;\n flex-direction: column;\n }\n\n .remote-pdf-frame {\n width: 100%;\n flex: 1;\n min-height: 480px;\n border: none;\n }\n\n .remote-media-stage {\n display: flex;\n align-items: center;\n justify-content: center;\n flex: 1;\n padding: var(--mj-space-6);\n background: var(--mj-bg-surface-sunken);\n }\n\n .remote-image {\n max-width: 100%;\n max-height: 70vh;\n border-radius: var(--mj-radius-md);\n box-shadow: var(--mj-shadow-md);\n }\n\n .remote-video {\n max-width: 100%;\n max-height: 70vh;\n border-radius: var(--mj-radius-md);\n }\n\n .remote-text-preview {\n margin: 0;\n padding: var(--mj-space-5);\n font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;\n font-size: 12.5px;\n line-height: 1.6;\n color: var(--mj-text-primary);\n white-space: pre-wrap;\n word-break: break-word;\n }\n\n @media (max-width: 960px) {\n .remote-drive-body.has-preview {\n grid-template-columns: 1fr;\n }\n .remote-preview-pane {\n border-left: none;\n border-top: 1px solid var(--mj-border-default);\n }\n }\n "] }]
|
|
1207
|
+
}], null, { Account: [{
|
|
1208
|
+
type: Input
|
|
1209
|
+
}], CurrentPrefix: [{
|
|
1210
|
+
type: Input
|
|
1211
|
+
}], CurrentUser: [{
|
|
1212
|
+
type: Input
|
|
1213
|
+
}], EnvironmentId: [{
|
|
1214
|
+
type: Input
|
|
1215
|
+
}], Collections: [{
|
|
1216
|
+
type: Input
|
|
1217
|
+
}], ShowBackButton: [{
|
|
1218
|
+
type: Input
|
|
1219
|
+
}], StorageClientOverride: [{
|
|
1220
|
+
type: Input
|
|
1221
|
+
}], PrefixChange: [{
|
|
1222
|
+
type: Output
|
|
1223
|
+
}], BackRequested: [{
|
|
1224
|
+
type: Output
|
|
1225
|
+
}], ArtifactConverted: [{
|
|
1226
|
+
type: Output
|
|
1227
|
+
}] }); })();
|
|
1228
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(LibraryRemoteDrivePaneComponent, { className: "LibraryRemoteDrivePaneComponent", filePath: "src/lib/components/library/library-remote-drive-pane.component.ts", lineNumber: 636 }); })();
|
|
1229
|
+
//# sourceMappingURL=library-remote-drive-pane.component.js.map
|