@pitcher/js-api 1.30.0 → 1.31.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/js-api.esm.js +80 -17
- package/js-api.esm.js.map +1 -1
- package/js-api.umd.min.js +15 -15
- package/js-api.umd.min.js.map +1 -1
- package/lib/apps/browser/components/ContextMenu/TranslateFileButton.test.d.ts +1 -0
- package/lib/apps/browser/stores/api.filesFoldersDeleter.test.d.ts +1 -0
- package/lib/apps/canvas-builder/components/container/PopupApps/PopupAppModal.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/components/container/PresentationTools/PresentationToolsButtons.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/components/ui/BottomSheetModal/BottomSheetModal.integration.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/components/ui/BottomSheetModal/BottomSheetModal.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/components/ui/DynamicContent/section-component-bindings.util.d.ts +32 -0
- package/lib/apps/canvas-builder/components/ui/DynamicContent/useDynamicContent.d.ts +4 -0
- package/lib/apps/canvas-builder/components/ui/Link/Link.util.d.ts +8 -1
- package/lib/apps/canvas-builder/components/ui/Link/Link.util.test.d.ts +1 -0
- package/lib/apps/canvas-builder/components/ui/SectionList/SectionItemModal.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/composables/useCanvas.d.ts +83 -9
- package/lib/apps/canvas-builder/composables/useCanvasBlocks.d.ts +4 -2
- package/lib/apps/canvas-builder/composables/useCanvasHistory.d.ts +2 -2
- package/lib/apps/canvas-builder/composables/useCanvasTheme.d.ts +2 -2
- package/lib/apps/canvas-builder/composables/useNavigatorDrawer.d.ts +25 -0
- package/lib/apps/canvas-builder/composables/useNavigatorDrawer.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/composables/usePopupApps.d.ts +41 -4
- package/lib/apps/canvas-builder/composables/usePopupApps.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/composables/usePresentationTools.d.ts +112 -0
- package/lib/apps/canvas-builder/composables/usePresentationTools.spec.d.ts +1 -0
- package/lib/apps/canvas-builder/types/canvas.d.ts +13 -0
- package/lib/apps/canvas-builder/util/canvas.util.d.ts +12 -0
- package/lib/apps/canvas-builder/util/completionWizard.util.d.ts +251 -11
- package/lib/apps/canvas-builder/util/iframe.util.d.ts +24 -2
- package/lib/apps/canvas-builder/util/iframe.util.test.d.ts +1 -0
- package/lib/apps/canvas-selector/stores/app.d.ts +14 -0
- package/lib/apps/collection-player/components/AppHeader.spec.d.ts +1 -0
- package/lib/apps/collection-player/composables/speaker-notes.use.d.ts +14 -0
- package/lib/apps/collection-player/composables/speaker-notes.use.spec.d.ts +1 -0
- package/lib/apps/collection-player/stores/app.store.d.ts +5 -1
- package/lib/apps/collection-player/stores/showNotesToggle.spec.d.ts +1 -0
- package/lib/apps/content-selector/appTypes.d.ts +16 -0
- package/lib/apps/content-selector/components/Content/AllContent/List/expandFileGuard.spec.d.ts +1 -0
- package/lib/apps/notes/NotesApp.accountNotes.spec.d.ts +1 -0
- package/lib/apps/notes/NotesApp.speakerNotes.spec.d.ts +1 -0
- package/lib/apps/notes/composables/useAccountNotes.d.ts +14 -0
- package/lib/apps/notes/composables/useAccountNotes.spec.d.ts +1 -0
- package/lib/apps/notes/composables/useAccountOnlyNotesGate.d.ts +21 -0
- package/lib/apps/notes/composables/useAccountOnlyNotesGate.spec.d.ts +1 -0
- package/lib/apps/notes/composables/useActiveSlideNotes.d.ts +42 -0
- package/lib/apps/notes/composables/useActiveSlideNotes.spec.d.ts +1 -0
- package/lib/components/CFileAccessManagement/collaborationApi.d.ts +2 -0
- package/lib/components/CFilePanel/Details.spec.d.ts +1 -0
- package/lib/components/CFilePanel/KeyMessages.spec.d.ts +1 -0
- package/lib/components/CFilePanel/Summary.spec.d.ts +1 -0
- package/lib/components/CFileViewer/pdf/CFileViewer.pdf.util.d.ts +52 -0
- package/lib/components/CGlobalLoader/CGlobalLoaderMark.spec.d.ts +1 -0
- package/lib/components/CGlobalLoader/globalLoader.paths.d.ts +2 -0
- package/lib/components/CGlobalSearch/globalSearchTarget.util.d.ts +31 -0
- package/lib/components/CGlobalSearch/globalSearchTarget.util.test.d.ts +1 -0
- package/lib/components/CRichTextEditor/extensions/paragraphExtended.d.ts +7 -1
- package/lib/components/CRichTextEditor/extensions/paragraphExtended.test.d.ts +1 -0
- package/lib/components/canvases/CanvasesManagementBulk.use.d.ts +12 -2
- package/lib/components/masterCanvases/CMasterCanvasesManagement.use.d.ts +86 -0
- package/lib/components/masterCanvases/CMasterCanvasesManagement.use.spec.d.ts +1 -0
- package/lib/components/masterCanvases/CMasterCanvasesPendingShareCell.spec.d.ts +1 -0
- package/lib/components/masterCanvases/CMasterCanvasesSharedWithCell.use.d.ts +39 -0
- package/lib/components/masterCanvases/CMasterCanvasesSharedWithCell.use.spec.d.ts +1 -0
- package/lib/components/masterCanvases/createFromMaster.use.d.ts +255 -0
- package/lib/components/masterCanvases/createFromMaster.use.spec.d.ts +1 -0
- package/lib/components/masterCanvases/masterCanvasDocuments.use.d.ts +56 -0
- package/lib/components/masterCanvases/masterCanvasDocuments.use.spec.d.ts +1 -0
- package/lib/components/masterCanvases/masterCanvasShares.use.d.ts +103 -0
- package/lib/components/masterCanvases/masterCanvasShares.use.spec.d.ts +1 -0
- package/lib/components/masterCanvases/masterFromCanvas.use.d.ts +122 -0
- package/lib/components/masterCanvases/masterFromCanvas.use.spec.d.ts +1 -0
- package/lib/components/masterCanvases/masterFromTemplate.use.d.ts +50 -0
- package/lib/components/masterCanvases/masterFromTemplate.use.spec.d.ts +1 -0
- package/lib/components/savedCanvases/CSavedCanvasesManagement.use.d.ts +203 -0
- package/lib/components/savedCanvases/savedCanvasDocuments.use.d.ts +111 -0
- package/lib/components/savedCanvases/savedCanvasDocuments.use.spec.d.ts +1 -0
- package/lib/components/savedCanvases/smartFolders/SmartFolders.use.d.ts +4 -0
- package/lib/constants/cdp.const.d.ts +1 -0
- package/lib/constants/translationLanguages.const.d.ts +86 -8
- package/lib/constants/translationLanguages.const.spec.d.ts +1 -0
- package/lib/main.lib.d.ts +5 -0
- package/lib/sdk/api/HighLevelApi.d.ts +2 -0
- package/lib/sdk/api/modules/appsDb.d.ts +4 -4
- package/lib/sdk/api/modules/canvas.d.ts +12 -0
- package/lib/sdk/api/modules/ui/types.ui.d.ts +18 -0
- package/lib/sdk/interfaces.d.ts +31 -1
- package/lib/sdk/main.d.ts +38 -0
- package/lib/sdk/payload.types.d.ts +45 -0
- package/lib/sdk/platform.d.ts +27 -0
- package/lib/sdk/platform.spec.d.ts +1 -0
- package/lib/sdk/singleton-scope.spec.d.ts +1 -0
- package/lib/sdk/utils/httpFetch.spec.d.ts +1 -0
- package/lib/theme/canvasUiUnoPreset.test.d.ts +1 -0
- package/lib/types/app.d.ts +55 -1
- package/lib/types/canvases.d.ts +15 -0
- package/lib/types/launchDarkly.types.d.ts +8 -1
- package/lib/types/organizationSettings.types.d.ts +29 -0
- package/lib/util/aiSummary.d.ts +30 -0
- package/lib/util/aiSummary.spec.d.ts +1 -0
- package/lib/util/network.d.ts +35 -0
- package/package.json +1 -1
- package/types/openapi/models/Canvas.d.ts +1 -0
- package/types/openapi/models/CanvasCreate.d.ts +1 -0
- package/types/openapi/models/CanvasCreateRequest.d.ts +1 -0
- package/types/openapi/models/CanvasRecommendedFile.d.ts +1 -1
- package/types/openapi/models/CanvasRetrieve.d.ts +1 -0
- package/types/openapi/models/CanvasUpdate.d.ts +1 -0
- package/types/openapi/models/CanvasUpdateRequest.d.ts +1 -0
- package/types/openapi/models/DeletedCanvas.d.ts +1 -0
- package/types/openapi/models/File.d.ts +1 -1
- package/types/openapi/models/PatchedCanvasUpdateRequest.d.ts +1 -0
- package/types/openapi/models/SharedLink.d.ts +6 -0
- package/types/openapi/models/SharedLinkCreateRequest.d.ts +5 -0
|
@@ -26,6 +26,22 @@ export type AppProps = {
|
|
|
26
26
|
minSelections?: Range<0, 999>;
|
|
27
27
|
disableNoSharable?: boolean;
|
|
28
28
|
disableNoPptxData?: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* The mounting host's file source cannot decompose a file into pages, so the per-item
|
|
31
|
+
* "Expand file" action is withheld. Default `false` — sales mounts pass nothing and keep it.
|
|
32
|
+
*
|
|
33
|
+
* Expanding renders one tile per entry in the fetched file's `content_thumbnails`
|
|
34
|
+
* (FoldersFilesList.vue / FoldersFilesGrid.vue); with none, the view falls through to its
|
|
35
|
+
* "thumbnails are missing — re-upload the PDF" empty state. That state is correct advice for a
|
|
36
|
+
* sales `pitcher_files` PDF whose thumbnail generation failed, and WRONG for a source that never
|
|
37
|
+
* generates page thumbnails at all: re-uploading changes nothing. Set this where the second is
|
|
38
|
+
* true, so the action is absent rather than a button that always dead-ends.
|
|
39
|
+
*
|
|
40
|
+
* Set by the L&D course host (PIT-7083 QA-4): ld-app populates `contentThumbnails` only on its two
|
|
41
|
+
* video paths, as a single cover image — the PDF path ingests straight into PSPDFKit and appends
|
|
42
|
+
* none (ldIngestService.ts), so an L&D PDF's `content_thumbnails` is permanently `[]`.
|
|
43
|
+
*/
|
|
44
|
+
disableFileExpansion?: boolean;
|
|
29
45
|
onlyAllowContentPdfPages?: boolean;
|
|
30
46
|
allowFolderSelection?: boolean;
|
|
31
47
|
};
|
package/lib/apps/content-selector/components/Content/AllContent/List/expandFileGuard.spec.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { MaybeRefOrGetter, ComputedRef, WritableComputedRef } from 'vue';
|
|
2
|
+
export declare const NOTES_APP_CONTENT_KEY = "notes_app_content";
|
|
3
|
+
/**
|
|
4
|
+
* PIT-8143: under `enable_account_only_meeting_notes`, meeting notes are scoped
|
|
5
|
+
* to the meeting bar's selected account. Each account gets its own localStorage
|
|
6
|
+
* bucket; the legacy key doubles as the "mode off / no account" bucket, so
|
|
7
|
+
* pre-existing free-floating notes keep working unchanged.
|
|
8
|
+
*/
|
|
9
|
+
export declare function accountNotesBucketKey(baseKey: string, accountId: string | null): string;
|
|
10
|
+
export declare function useAccountNotes(baseKey?: string, enabled?: MaybeRefOrGetter<boolean>): {
|
|
11
|
+
content: WritableComputedRef<string>;
|
|
12
|
+
accountId: ComputedRef<string | null>;
|
|
13
|
+
storageKey: ComputedRef<string>;
|
|
14
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ComputedRef, MaybeRefOrGetter } from 'vue';
|
|
2
|
+
import { InstanceSettings } from '../../../types/instanceSettings.types';
|
|
3
|
+
type PitcherSettings = InstanceSettings;
|
|
4
|
+
/**
|
|
5
|
+
* PIT-8144: under `enable_account_only_meeting_notes`, the notes app is HIDDEN everywhere while no
|
|
6
|
+
* account is selected — not rendered as a disabled tab. Every entry point (slotty TopBar,
|
|
7
|
+
* canvas-builder ControlBar/BottomBar, the collection player header, Impact's file viewer) and both
|
|
8
|
+
* widget mounts share this gate, so they can never drift apart.
|
|
9
|
+
*
|
|
10
|
+
* The signal is `call.selectedAccount.Id` and deliberately nothing broader — it is the exact key
|
|
11
|
+
* `useAccountNotes` buckets keystrokes by, so visibility and bucketing always agree. A pitchdeck
|
|
12
|
+
* that carries its own account satisfies it through deck-context adoption
|
|
13
|
+
* (`resolveDeckContextAdoption` in slotty), which writes that account into the call store.
|
|
14
|
+
*
|
|
15
|
+
* `settings` is for hosts that PROVIDE `pitcherSettings` themselves (slotty App.vue, Impact
|
|
16
|
+
* authenticated.vue) — a component cannot inject its own provide. Children omit it and inject.
|
|
17
|
+
*/
|
|
18
|
+
export declare function useAccountOnlyNotesGate(settings?: MaybeRefOrGetter<PitcherSettings | undefined>): {
|
|
19
|
+
isNotesAppHidden: ComputedRef<boolean>;
|
|
20
|
+
};
|
|
21
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Speaker notes for the slide currently on screen in a FILE viewer — the standard
|
|
3
|
+
* PSPDFKit viewer or the Collection Player — as opposed to the canvas-builder's
|
|
4
|
+
* `active-section-metadata`, which only ever describes a converted section.
|
|
5
|
+
*
|
|
6
|
+
* localStorage rather than a shared ref because NotesApp runs in three contexts that
|
|
7
|
+
* share an origin but not a JS realm: the Impact widget, the slotty widget, and the
|
|
8
|
+
* `?fullscreen_notes=true` popup window.
|
|
9
|
+
*/
|
|
10
|
+
export declare const ACTIVE_SLIDE_NOTES_KEY = "active-slide-notes";
|
|
11
|
+
export interface ActiveSlideNotes {
|
|
12
|
+
file_id: string;
|
|
13
|
+
/** 0-based position in `metadata.pptx_data.slides` — equal to the PSPDFKit page index. */
|
|
14
|
+
slide_index: number;
|
|
15
|
+
title: string;
|
|
16
|
+
note: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* The narrow slice of a file both producers can supply (`PitcherFile`, `CollectionFileEntity`).
|
|
20
|
+
*
|
|
21
|
+
* `metadata` stays an open record because it genuinely is one — it maps a Django JSONField, and
|
|
22
|
+
* `FileMetadata` declares `[key: string]: any` for that reason. Declaring the `pptx_data` shape
|
|
23
|
+
* here instead would make this a weak type that neither caller's metadata satisfies. The shape is
|
|
24
|
+
* enforced at runtime by `readSlides` below, which is where an untyped blob has to be checked anyway.
|
|
25
|
+
*/
|
|
26
|
+
interface SlideNotesSource {
|
|
27
|
+
id: string;
|
|
28
|
+
metadata?: Record<string, unknown> | null;
|
|
29
|
+
}
|
|
30
|
+
/** Read side — consumed by NotesApp. */
|
|
31
|
+
export declare function useActiveSlideNotes(): import('@vueuse/shared').RemovableRef<ActiveSlideNotes | null>;
|
|
32
|
+
/**
|
|
33
|
+
* Resolve `file.metadata.pptx_data.slides[pageIndex]` and publish just the two fields the
|
|
34
|
+
* Speaker Notes tab renders. The slide's `content` is deliberately left out: `pptx_data` runs
|
|
35
|
+
* to tens of KB and this is rewritten on every page turn.
|
|
36
|
+
*
|
|
37
|
+
* Clears the key when the file has no extracted pptx data or the page is out of range, so a
|
|
38
|
+
* non-PPTX file never inherits the previous file's note.
|
|
39
|
+
*/
|
|
40
|
+
export declare function setActiveSlideNotes(file: SlideNotesSource | null | undefined, pageIndex: number): void;
|
|
41
|
+
export declare function clearActiveSlideNotes(): void;
|
|
42
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -15,3 +15,55 @@ import { default as PSPDFKitType } from '@nutrient-sdk/viewer';
|
|
|
15
15
|
* actually disposes the stuck dialog.
|
|
16
16
|
*/
|
|
17
17
|
export declare function safePspdfkitUnload(pspdfkit: Pick<typeof PSPDFKitType, 'unload'> | undefined, container: HTMLElement | null): void;
|
|
18
|
+
/** What a keypress in the PDF viewer should do, or `null` for "ignore it". */
|
|
19
|
+
export type FileViewerKeyAction = 'next' | 'previous' | 'first' | 'last' | null;
|
|
20
|
+
/**
|
|
21
|
+
* Is the user typing into something? PDF AcroForm fields and rich-text
|
|
22
|
+
* annotations are editable in this viewer (PIT-7330), and there the arrow keys
|
|
23
|
+
* move the caret. Changing page out from under someone mid-edit would be a worse
|
|
24
|
+
* bug than the one this guard ships alongside.
|
|
25
|
+
*
|
|
26
|
+
* Deliberately duck-typed instead of `instanceof HTMLInputElement` (which is how
|
|
27
|
+
* NavigatorPresentation.vue does it). That works there because it listens on
|
|
28
|
+
* `window`, in the same realm. Our listener is attached to
|
|
29
|
+
* `instance.contentDocument`, so a target can belong to a DIFFERENT document
|
|
30
|
+
* realm, where `instanceof` against this realm's constructors is always false —
|
|
31
|
+
* it would silently disable the guard rather than fail loudly.
|
|
32
|
+
*/
|
|
33
|
+
export declare function isTextEntryTarget(target: unknown): boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Is an overlay open that owns the paging keys itself?
|
|
36
|
+
*
|
|
37
|
+
* Naive's dropdown binds `keydown` on `document` via vooks' `useKeyboard` — the exact
|
|
38
|
+
* target this composable now uses — while `keyboard && show` are true. So an open
|
|
39
|
+
* annotation menu would navigate the menu AND page the file behind it, with our
|
|
40
|
+
* `preventDefault()` on top. `.n-dropdown` only exists in the DOM while open.
|
|
41
|
+
*
|
|
42
|
+
* Drawers (file info, page metadata) scroll their own content, so `PageUp`/`PageDown`/
|
|
43
|
+
* `Home`/`End` belong to the panel whenever the press came from inside one.
|
|
44
|
+
*/
|
|
45
|
+
export declare function isPagingOverlayActive(target: unknown): boolean;
|
|
46
|
+
/**
|
|
47
|
+
* Does `instance.contentDocument` need its own key listener?
|
|
48
|
+
*
|
|
49
|
+
* The SDK types it `Document | ShadowRoot`: normally it is the viewer's SHADOW ROOT,
|
|
50
|
+
* and `keydown` is a composed event, so presses inside it also reach the host
|
|
51
|
+
* `document` — one listener there is enough, and adding a second on the shadow root
|
|
52
|
+
* would fire the handler twice for the same press (advancing two pages).
|
|
53
|
+
*
|
|
54
|
+
* Under the SDK's iframe fallback it is a separate `Document` instead, whose events
|
|
55
|
+
* never reach the host at all, so that case does need its own listener.
|
|
56
|
+
*
|
|
57
|
+
* Checked by `nodeType` rather than `instanceof Document`: an iframe's document
|
|
58
|
+
* belongs to another realm, where `instanceof` against our constructors is false —
|
|
59
|
+
* the exact trap `isTextEntryTarget` documents.
|
|
60
|
+
*/
|
|
61
|
+
export declare function needsOwnKeyListener(contentDocument: unknown): boolean;
|
|
62
|
+
/**
|
|
63
|
+
* Map a keydown to a page-navigation action, or `null` when it should be left alone.
|
|
64
|
+
*
|
|
65
|
+
* Split out so it can be unit-tested — the handler that consumes it lives inside a
|
|
66
|
+
* composable that needs a live PSPDFKit instance. It reads the event and (via
|
|
67
|
+
* `isPagingOverlayActive`) the document, but touches no viewer state.
|
|
68
|
+
*/
|
|
69
|
+
export declare function resolveFileViewerKeyAction(event: KeyboardEvent): FileViewerKeyAction;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export declare const GLOBAL_LOADER_PATH_1: readonly ["M45,0.1080000028014183 C45,22.57200050354004 45,45 45,45 C45,45 22.42799949645996,45 -0.1080000028014183,45", "M45,0.3959999978542328 C45,22.76300048828125 45,45 45,45 C45,45 22.235000610351562,45 -0.3959999978542328,45", "M45,0.8640000224113464 C45,23.07200050354004 45,45 45,45 C45,45 21.920000076293945,45 -0.8640000224113464,45", "M45,1.5839999914169312 C45,23.54400062561035 45,45 45,45 C45,45 21.430999755859375,45 -1.5839999914169312,45", "M45,2.5920000076293945 C45,24.195999145507812 45,45 45,45 C45,45 20.738000869750977,45 -2.5920000076293945,45", "M45,3.888000011444092 C45,25.020000457763672 45,45 45,45 C45,45 19.829999923706055,45 -3.888000011444092,45", "M45,5.6519999504089355 C45,26.118000030517578 45,45 45,45 C45,45 18.56399917602539,45 -5.6519999504089355,45", "M45,7.631999969482422 C45,27.31999969482422 45,45 45,45 C45,45 17.100000381469727,45 -7.631999969482422,45", "M45,10.116000175476074 C45,28.783000946044922 45,45 45,45 C45,45 15.190999984741211,45 -10.116000175476074,45", "M45,13.211999893188477 C45,30.540000915527344 45,45 45,45 C45,45 12.6899995803833,45 -13.211999893188477,45", "M45,17.20800018310547 C45,32.707000732421875 45,45 45,45 C45,45 9.230999946594238,45 -17.20800018310547,45", "M45,21.816999435424805 C45,35.07500076293945 45,45 45,45 C45,45 4.848999977111816,45 -21.816999435424805,45", "M45,27.792999267578125 C45,37.94900131225586 45,45 45,45 C45,45 -1.6679999828338623,45 -27.792999267578125,45", "M45,34.95600128173828 C45,41.11399841308594 45,45 45,45 C45,45 -11.482000350952148,45 -34.95600128173828,45", "M45,43.99399948120117 C45,44.650001525878906 45,45 45,45 C45,45 -34.12799835205078,45 -43.99399948120117,45", "M34.130001068115234,45 C10.1850004196167,45 -45,45 -45,45 C-45,45 -45,40.763999938964844 -45,34.130001068115234", "M18.4689998626709,45 C-8.07800006866455,45 -45,45 -45,45 C-45,45 -45,33.36899948120117 -45,18.4689998626709", "M0.25200000405311584,45 C-22.332000732421875,45 -45,45 -45,45 C-45,45 -45,22.667999267578125 -45,0.25200000405311584", "M-19.799999237060547,45 C-34.055999755859375,45 -45,45 -45,45 C-45,45 -45,6.824999809265137 -45,-19.799999237060547", "M-35.89400100708008,45 C-41.50600051879883,45 -45,45 -45,45 C-45,45 -45,-13.026000022888184 -45,-35.89400100708008", "M-45,41.32899856567383 C-45,24.437000274658203 -45,-45 -45,-45 C-45,-45 -43.667999267578125,-45 -41.32899856567383,-45", "M-45,31.35700035095215 C-45,6.190000057220459 -45,-45 -45,-45 C-45,-45 -39.56100082397461,-45 -31.35700035095215,-45", "M-45,24.37299919128418 C-45,-2.197000026702881 -45,-45 -45,-45 C-45,-45 -36.33000183105469,-45 -24.37299919128418,-45", "M-45,18.361000061035156 C-45,-8.178000450134277 -45,-45 -45,-45 C-45,-45 -33.3120002746582,-45 -18.361000061035156,-45", "M-45,13.680000305175781 C-45,-12.298999786376953 -45,-45 -45,-45 C-45,-45 -30.799999237060547,-45 -13.680000305175781,-45", "M-45,10.116000175476074 C-45,-15.190999984741211 -45,-45 -45,-45 C-45,-45 -28.783000946044922,-45 -10.116000175476074,-45", "M-45,7.343999862670898 C-45,-17.31599998474121 -45,-45 -45,-45 C-45,-45 -27.14699935913086,-45 -7.343999862670898,-45", "M-45,5.1479997634887695 C-45,-18.93000030517578 -45,-45 -45,-45 C-45,-45 -25.80699920654297,-45 -5.1479997634887695,-45", "M-45,3.312000036239624 C-45,-20.236000061035156 -45,-45 -45,-45 C-45,-45 -24.6560001373291,-45 -3.312000036239624,-45", "M-45,2.052000045776367 C-45,-21.111000061035156 -45,-45 -45,-45 C-45,-45 -23.847999572753906,-45 -2.052000045776367,-45", "M-45,1.0800000429153442 C-45,-21.77400016784668 -45,-45 -45,-45 C-45,-45 -23.214000701904297,-45 -1.0800000429153442,-45", "M-45,0.46799999475479126 C-45,-22.187000274658203 -45,-45 -45,-45 C-45,-45 -22.81100082397461,-45 -0.46799999475479126,-45", "M-45,0.1080000028014183 C-45,-22.42799949645996 -45,-45 -45,-45 C-45,-45 -22.57200050354004,-45 -0.1080000028014183,-45", "M-45,0 C-45,-22.5 -45,-45 -45,-45 C-45,-45 -22.5,-45 0,-45", "M-45,0 C-45,-22.5 -45,-45 -45,-45 C-45,-45 -22.5,-45 0,-45", "M45,0 C45,22.5 45,45 45,45 C45,45 22.5,45 0,45"];
|
|
2
|
+
export declare const GLOBAL_LOADER_PATH_2: readonly ["M45,0.07199999690055847 C45,22.54800033569336 45,45 45,45 C45,45 22.45199966430664,45 -0.07199999690055847,45", "M45,0.36000001430511475 C45,22.73900032043457 45,45 45,45 C45,45 22.259000778198242,45 -0.36000001430511475,45", "M45,0.8640000224113464 C45,23.07200050354004 45,45 45,45 C45,45 21.920000076293945,45 -0.8640000224113464,45", "M45,1.5479999780654907 C45,23.520000457763672 45,45 45,45 C45,45 21.45599937438965,45 -1.5479999780654907,45", "M45,2.555999994277954 C45,24.17300033569336 45,45 45,45 C45,45 20.76300048828125,45 -2.555999994277954,45", "M45,3.8519999980926514 C45,24.996999740600586 45,45 45,45 C45,45 19.856000900268555,45 -3.8519999980926514,45", "M45,5.507999897003174 C45,26.030000686645508 45,45 45,45 C45,45 18.66900062561035,45 -5.507999897003174,45", "M45,7.631999969482422 C45,27.31999969482422 45,45 45,45 C45,45 17.100000381469727,45 -7.631999969482422,45", "M45,10.079999923706055 C45,28.761999130249023 45,45 45,45 C45,45 15.218999862670898,45 -10.079999923706055,45", "M45,13.28499984741211 C45,30.579999923706055 45,45 45,45 C45,45 12.630000114440918,45 -13.28499984741211,45", "M45,17.100000381469727 C45,32.650001525878906 45,45 45,45 C45,45 9.32800006866455,45 -17.100000381469727,45", "M45,21.7450008392334 C45,35.03900146484375 45,45 45,45 C45,45 4.921999931335449,45 -21.7450008392334,45", "M45,27.253000259399414 C45,37.698001861572266 45,45 45,45 C45,45 -1.0299999713897705,45 -27.253000259399414,45", "M45,34.777000427246094 C45,41.03799819946289 45,45 45,45 C45,45 -11.196999549865723,45 -34.777000427246094,45", "M45,43.308998107910156 C45,44.40399932861328 45,45 45,45 C45,45 -30.948999404907227,45 -43.308998107910156,45", "M35.02899932861328,45 C11.598999977111816,45 -45,45 -45,45 C-45,45 -45,41.14400100708008 -45,35.02899932861328", "M20.089000701904297,45 C-6.547999858856201,45 -45,45 -45,45 C-45,45 -45,34.202999114990234 -45,20.089000701904297", "M0.46799999475479126,45 C-22.187000274658203,45 -45,45 -45,45 C-45,45 -45,22.81100082397461 -45,0.46799999475479126", "M-19.04400062561035,45 C-33.66699981689453,45 -45,45 -45,45 C-45,45 -45,7.540999889373779 -45,-19.04400062561035", "M-35.388999938964844,45 C-41.29499816894531,45 -45,45 -45,45 C-45,45 -45,-12.1850004196167 -45,-35.388999938964844", "M-45,41.4739990234375 C-45,24.836999893188477 -45,-45 -45,-45 C-45,-45 -43.722999572753906,-45 -41.4739990234375,-45", "M-45,31.716999053955078 C-45,6.679999828338623 -45,-45 -45,-45 C-45,-45 -39.71900177001953,-45 -31.716999053955078,-45", "M-45,24.44499969482422 C-45,-2.119999885559082 -45,-45 -45,-45 C-45,-45 -36.3650016784668,-45 -24.44499969482422,-45", "M-45,18.4689998626709 C-45,-8.07800006866455 -45,-45 -45,-45 C-45,-45 -33.36899948120117,-45 -18.4689998626709,-45", "M-45,13.968000411987305 C-45,-12.055999755859375 -45,-45 -45,-45 C-45,-45 -30.958999633789062,-45 -13.968000411987305,-45", "M-45,10.331999778747559 C-45,-15.020999908447266 -45,-45 -45,-45 C-45,-45 -28.906999588012695,-45 -10.331999778747559,-45", "M-45,7.380000114440918 C-45,-17.288999557495117 -45,-45 -45,-45 C-45,-45 -27.16900062561035,-45 -7.380000114440918,-45", "M-45,5.21999979019165 C-45,-18.878000259399414 -45,-45 -45,-45 C-45,-45 -25.851999282836914,-45 -5.21999979019165,-45", "M-45,3.4200000762939453 C-45,-20.15999984741211 -45,-45 -45,-45 C-45,-45 -24.724000930786133,-45 -3.4200000762939453,-45", "M-45,2.052000045776367 C-45,-21.111000061035156 -45,-45 -45,-45 C-45,-45 -23.847999572753906,-45 -2.052000045776367,-45", "M-45,1.1160000562667847 C-45,-21.75 -45,-45 -45,-45 C-45,-45 -23.238000869750977,-45 -1.1160000562667847,-45", "M-45,0.46799999475479126 C-45,-22.187000274658203 -45,-45 -45,-45 C-45,-45 -22.81100082397461,-45 -0.46799999475479126,-45", "M-45,0.1080000028014183 C-45,-22.42799949645996 -45,-45 -45,-45 C-45,-45 -22.57200050354004,-45 -0.1080000028014183,-45", "M-45,0 C-45,-22.5 -45,-45 -45,-45 C-45,-45 -22.5,-45 0,-45", "M-45,0 C-45,-22.5 -45,-45 -45,-45 C-45,-45 -22.5,-45 0,-45", "M45,0 C45,22.5 45,45 45,45 C45,45 22.5,45 0,45"];
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Decides whether a bare keystroke arriving at the `document` should be treated as a global
|
|
3
|
+
* shortcut (`/` opens omni-search) or as literal text the user is typing into a field.
|
|
4
|
+
*
|
|
5
|
+
* The subtlety this file exists for: the Meeting Bar V3 widget renders inside
|
|
6
|
+
* `attachShadow({ mode: 'open' })` (see `slotty-ui-ng/.../MeetingBarV3Embed.vue`), and a composed
|
|
7
|
+
* event crossing a shadow boundary has its `target` **retargeted to the host element**. A
|
|
8
|
+
* document-level listener therefore sees the host `<div>`, never the `<input>` the rep is typing
|
|
9
|
+
* in — so a naive `event.target.tagName` check waves the keystroke through and `/` tears the
|
|
10
|
+
* account-selector flyout down mid-search (PIT-8130).
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* The element actually receiving `event` — piercing any open shadow roots between it and the
|
|
14
|
+
* `document` listener that observed the event.
|
|
15
|
+
*
|
|
16
|
+
* `composedPath()` is the flattened path the event really travelled, so its first entry is the
|
|
17
|
+
* innermost node regardless of how many shadow boundaries sit above it, where `event.target` has
|
|
18
|
+
* already been retargeted to the outermost host. Real keyboard events are always `composed`; the
|
|
19
|
+
* `event.target` fallback covers a synthetic one that isn't (and a closed shadow root, where
|
|
20
|
+
* neither can see past the host).
|
|
21
|
+
*
|
|
22
|
+
* MUST be called synchronously from the event listener: `composedPath()` returns `[]` once
|
|
23
|
+
* dispatch has finished, which silently degrades this back to the retargeted `event.target` and
|
|
24
|
+
* reintroduces PIT-8130. Never defer it behind a `setTimeout`/`nextTick`.
|
|
25
|
+
*/
|
|
26
|
+
export declare const resolveKeystrokeTarget: (event: KeyboardEvent) => Element | null;
|
|
27
|
+
/**
|
|
28
|
+
* `true` when `event` is a bare keystroke that no editable field is claiming, i.e. it is safe to
|
|
29
|
+
* consume as a global shortcut.
|
|
30
|
+
*/
|
|
31
|
+
export declare const isTargetAllowed: (event: KeyboardEvent) => boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -11,10 +11,16 @@ export declare const styling: {
|
|
|
11
11
|
fontSize: number;
|
|
12
12
|
};
|
|
13
13
|
};
|
|
14
|
+
/**
|
|
15
|
+
* `data-size` is read straight off authored HTML, so it can carry any string. Canvas content
|
|
16
|
+
* built by scripts/templates has been seen with heading values on a `<p>` (`data-size="h1"`),
|
|
17
|
+
* which is not a paragraph size and has no `styling` entry.
|
|
18
|
+
*/
|
|
19
|
+
export declare const isParagraphSize: (value: unknown) => value is Paragraphs;
|
|
14
20
|
declare module '@tiptap/core' {
|
|
15
21
|
interface Commands<ReturnType> {
|
|
16
22
|
paragraphExtended: {
|
|
17
|
-
setParagraphExtended: (size:
|
|
23
|
+
setParagraphExtended: (size: Paragraphs) => ReturnType;
|
|
18
24
|
};
|
|
19
25
|
}
|
|
20
26
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -9,6 +9,16 @@ interface BaseBulkProps {
|
|
|
9
9
|
confirmText?: string;
|
|
10
10
|
cancelText?: string;
|
|
11
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* What the dialogs NAME the selected rows as — a superset of `CanvasType` (PIT-8360 QA).
|
|
14
|
+
*
|
|
15
|
+
* `'master-canvas'` is deliberately not a `CanvasType`: that type is the API's `canvas_type`, sent
|
|
16
|
+
* as-is to the instance-tags endpoint by `bulkAddTagsDialog`, and there is no such server-side
|
|
17
|
+
* type. It exists only to pick the noun these dialogs put in front of the user, so it is confined
|
|
18
|
+
* to the two dialogs the masters tab actually opens (delete and manage attributes) — the tag
|
|
19
|
+
* dialogs, which are hidden on that tab, keep the narrower `CanvasType`.
|
|
20
|
+
*/
|
|
21
|
+
export type BulkEntityType = CanvasType | 'master-canvas';
|
|
12
22
|
interface BulkUpdateFileAttributeProps extends BaseBulkProps {
|
|
13
23
|
fileNames: string[];
|
|
14
24
|
metadataFetcher?: (params?: GetInstanceMetadataTemplatesPayload) => Promise<PaginatedMetadataTemplateList>;
|
|
@@ -22,7 +32,7 @@ interface BulkUpdateMetadataDialogProps extends BaseBulkProps {
|
|
|
22
32
|
noMetadataErrorText?: string;
|
|
23
33
|
subtitle?: string;
|
|
24
34
|
isBulkUpdating: Ref<boolean>;
|
|
25
|
-
canvasType:
|
|
35
|
+
canvasType: BulkEntityType;
|
|
26
36
|
updater?: (params: PatchedCanvasUpdateRequest & {
|
|
27
37
|
id: CanvasRetrieve['id'];
|
|
28
38
|
fields?: string;
|
|
@@ -31,7 +41,7 @@ interface BulkUpdateMetadataDialogProps extends BaseBulkProps {
|
|
|
31
41
|
interface BulkDeleteDialogProps extends BaseBulkProps {
|
|
32
42
|
filteredData: ComputedRef<CanvasRetrieve[]>;
|
|
33
43
|
isBulkDeleting: Ref<boolean>;
|
|
34
|
-
canvasType:
|
|
44
|
+
canvasType: BulkEntityType;
|
|
35
45
|
isReadonly?: (canvas: CanvasRetrieve) => boolean;
|
|
36
46
|
content?: string;
|
|
37
47
|
}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import { CanvasRetrieve } from '../../../types/openapi';
|
|
2
|
+
/**
|
|
3
|
+
* PIT-7488 — row actions on a master pitchdeck, from the signed-off prototype's `…` menu.
|
|
4
|
+
*
|
|
5
|
+
* Same vocabulary as the pitchdeck tab, minus `use-as-master` (a master cannot become one) and
|
|
6
|
+
* plus `share` (sharing a master with colleagues, which ordinary decks do not do).
|
|
7
|
+
*/
|
|
8
|
+
export type MasterCanvasAction = 'view' | 'edit' | 'open-new-tab' | 'freeze' | 'share' | 'duplicate' | 'delete';
|
|
9
|
+
/** Dialogs the master tab owns. `create-from-master` belongs to the create flow (block 4). */
|
|
10
|
+
export type MasterCanvasDialog = {
|
|
11
|
+
type: 'share';
|
|
12
|
+
canvasId: CanvasRetrieve['id'];
|
|
13
|
+
} | {
|
|
14
|
+
type: 'duplicate';
|
|
15
|
+
canvasId: CanvasRetrieve['id'];
|
|
16
|
+
} | {
|
|
17
|
+
type: 'confirm-delete';
|
|
18
|
+
canvasId: CanvasRetrieve['id'];
|
|
19
|
+
};
|
|
20
|
+
/** Actions the host performs directly — no confirmation step. */
|
|
21
|
+
export type MasterCanvasPassthroughAction = Exclude<MasterCanvasAction, 'share' | 'duplicate' | 'delete'>;
|
|
22
|
+
/**
|
|
23
|
+
* What a row action resolves to. Splitting these two apart is the point of this module: the
|
|
24
|
+
* prototype's `onRowAction` switch conflates "open a dialog" with "do the thing", and the two
|
|
25
|
+
* have completely different owners in production — dialogs are local state, whereas view / edit /
|
|
26
|
+
* download / freeze are host callbacks that already exist on the pitchdeck tab.
|
|
27
|
+
*/
|
|
28
|
+
export type MasterCanvasActionResolution = {
|
|
29
|
+
kind: 'dialog';
|
|
30
|
+
dialog: MasterCanvasDialog;
|
|
31
|
+
} | {
|
|
32
|
+
kind: 'passthrough';
|
|
33
|
+
action: MasterCanvasPassthroughAction;
|
|
34
|
+
};
|
|
35
|
+
export declare function resolveMasterCanvasAction(action: MasterCanvasAction, canvasId: CanvasRetrieve['id']): MasterCanvasActionResolution;
|
|
36
|
+
/**
|
|
37
|
+
* Dialog state for the master tab.
|
|
38
|
+
*
|
|
39
|
+
* This is the ONLY part of the PoC reducer that survives contact with production: its list
|
|
40
|
+
* mutations (create / duplicate / delete / share) all rewrote an in-memory array, whereas here
|
|
41
|
+
* the list comes from the host's `fetcher` and a mutation is a request plus a refetch — machinery
|
|
42
|
+
* `CSavedCanvasesManagement` already owns. So this deliberately holds no rows.
|
|
43
|
+
*/
|
|
44
|
+
export declare function useMasterCanvasDialogs(): {
|
|
45
|
+
dialog: import('vue').Ref<{
|
|
46
|
+
type: "share";
|
|
47
|
+
canvasId: CanvasRetrieve["id"];
|
|
48
|
+
} | {
|
|
49
|
+
type: "duplicate";
|
|
50
|
+
canvasId: CanvasRetrieve["id"];
|
|
51
|
+
} | {
|
|
52
|
+
type: "confirm-delete";
|
|
53
|
+
canvasId: CanvasRetrieve["id"];
|
|
54
|
+
} | null, MasterCanvasDialog | {
|
|
55
|
+
type: "share";
|
|
56
|
+
canvasId: CanvasRetrieve["id"];
|
|
57
|
+
} | {
|
|
58
|
+
type: "duplicate";
|
|
59
|
+
canvasId: CanvasRetrieve["id"];
|
|
60
|
+
} | {
|
|
61
|
+
type: "confirm-delete";
|
|
62
|
+
canvasId: CanvasRetrieve["id"];
|
|
63
|
+
} | null>;
|
|
64
|
+
openDialog: (next: MasterCanvasDialog) => void;
|
|
65
|
+
closeDialog: () => void;
|
|
66
|
+
handleAction: (action: MasterCanvasAction, canvasId: CanvasRetrieve["id"]) => MasterCanvasPassthroughAction | null;
|
|
67
|
+
};
|
|
68
|
+
export interface ShouldOfferUseToCreateOptions {
|
|
69
|
+
/** The permission/settings gate the pitchdeck cell also applies. */
|
|
70
|
+
canUseToCreate: boolean;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Whether a master's row may offer "Use to create pitchdeck" (PIT-7488 QA Q12).
|
|
74
|
+
*
|
|
75
|
+
* The `!isDraft` term is GONE as of PIT-8360, along with the Ready column that was the only control
|
|
76
|
+
* able to clear the flag. Keeping it would have stranded two populations for good: every new master
|
|
77
|
+
* (created as a Draft until this change) and every master already created as one — hidden from the
|
|
78
|
+
* row action here and filtered out of the creation picker, with nothing left to flip.
|
|
79
|
+
*
|
|
80
|
+
* So a master is offerable whenever the caller may create from one. Masters no longer carry a
|
|
81
|
+
* meaningful draft state; `is_draft` survives on the model because every canvas has it, not because
|
|
82
|
+
* anything on this tab means anything by it.
|
|
83
|
+
*
|
|
84
|
+
* Hidden rather than disabled, matching how this cell already treats an unavailable lead action.
|
|
85
|
+
*/
|
|
86
|
+
export declare function shouldOfferUseToCreate(opts: ShouldOfferUseToCreateOptions): boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { MiniUser } from '../../../types/openapi';
|
|
2
|
+
/**
|
|
3
|
+
* PIT-7488 — display logic for the master pitchdeck "Shared with" cell.
|
|
4
|
+
*
|
|
5
|
+
* Kept out of the SFC so the capping/label rules are unit-testable: the cell itself is then a
|
|
6
|
+
* thin renderer over this result.
|
|
7
|
+
*
|
|
8
|
+
* The list is `Collaboration['user']` (a `MiniUser`) — block 5 is what will actually populate it.
|
|
9
|
+
*/
|
|
10
|
+
/** Avatars rendered before collapsing the rest into a "+N" bubble. From the prototype. */
|
|
11
|
+
export declare const MAX_SHARED_WITH_AVATARS = 3;
|
|
12
|
+
export interface SharedWithSummary {
|
|
13
|
+
/** Users to render an avatar for, capped at `max`. */
|
|
14
|
+
shown: MiniUser[];
|
|
15
|
+
/** How many users the cap hid. `0` when everyone fits. */
|
|
16
|
+
overflow: number;
|
|
17
|
+
/** Compact text beside the avatar stack. */
|
|
18
|
+
label: string;
|
|
19
|
+
/** Every name, for the hover tooltip and the aria-label. */
|
|
20
|
+
allNames: string;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Names in list order, blank-name users resolved to their email (SSO users frequently have no
|
|
24
|
+
* populated name — PIT-5973), and users with neither dropped rather than rendered as an
|
|
25
|
+
* empty comma.
|
|
26
|
+
*/
|
|
27
|
+
export declare function sharedWithNames(users: MiniUser[]): string[];
|
|
28
|
+
/**
|
|
29
|
+
* The compact label beside the avatar stack: every shown name, then "+N" for the rest.
|
|
30
|
+
*
|
|
31
|
+
* Note the prototype (`next-core/src/app/examples/master-pitchdeck-ng/components/
|
|
32
|
+
* SharedWithCell.tsx`) contradicts itself — its comment promises "first two names + +N" while
|
|
33
|
+
* its code joins all three *shown* names. We follow the code. The label truncates in a narrow
|
|
34
|
+
* column, which is accepted: the tooltip always carries the full list.
|
|
35
|
+
*
|
|
36
|
+
* `names` is already email-resolved and blank-filtered; `overflow` is how many the cap hid.
|
|
37
|
+
*/
|
|
38
|
+
export declare function buildSharedWithLabel(names: string[], overflow: number): string;
|
|
39
|
+
export declare function summarizeSharedWith(users: MiniUser[], max?: number): SharedWithSummary;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|