@orangelogic/design-system 2.207.0 → 2.208.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.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@orangelogic/design-system",
3
3
  "type": "module",
4
- "version": "2.207.0",
4
+ "version": "2.208.0",
5
5
  "license": "UNLICENSED",
6
6
  "types": "library/types.d.ts",
7
7
  "scripts": {
@@ -111,6 +111,7 @@ export default class CxDropdown extends CortexElement {
111
111
  private handleKeyDown;
112
112
  private handleDocumentKeyDown;
113
113
  private handleDocumentMouseDown;
114
+ private handleDocumentFocusIn;
114
115
  private handlePanelSelect;
115
116
  handleTriggerClick(): Promise<void>;
116
117
  handleTriggerKeyDown(event: KeyboardEvent): void;
@@ -37,14 +37,11 @@ export default class CxMenu extends CortexElement {
37
37
  default: boolean;
38
38
  /** Can menu bubble keydown events */
39
39
  bubbleKeyDown: boolean;
40
- /**
41
- * Override the default keydown navigation behavior of the dropdown menu.
42
- */
40
+ /** Override the default keydown navigation behavior of the dropdown menu. */
43
41
  ignoredKeys: string[];
42
+ /** @deprecated Only stops ArrowUp/ArrowDown wrapping now; Tab is no longer intercepted. */
44
43
  disabledTabLoop: boolean;
45
- /**
46
- * When true, checkbox items in this menu do not toggle off when already activated while checked—the same behavior as setting `no-uncheck` on each checkbox item.
47
- */
44
+ /** When true, checkbox items don't toggle off when already checked (same as each item's own `no-uncheck`). */
48
45
  noUncheck: boolean;
49
46
  resizeObserver: ResizeObserver | null;
50
47
  private slotMutationObserver;
@@ -53,8 +50,11 @@ export default class CxMenu extends CortexElement {
53
50
  runFirstUpdated(): void;
54
51
  private handleClick;
55
52
  private handleKeyDown;
56
- private handleMouseDown;
57
53
  private handleSlotChange;
54
+ /** Sets `tabindex="0"` on the selected item (`checked`/`active`), or the first item if none is selected. */
55
+ private syncTabIndexToSelection;
56
+ /** Moves `tabindex="0"` directly to `item`; used by `setCurrentItem()` for explicit external placement. */
57
+ private setRovingTabIndex;
58
58
  private isMenuSection;
59
59
  private isMenuItem;
60
60
  /** @internal Gets all slotted menu items, ignoring dividers, headers, and other elements. */
@@ -65,15 +65,7 @@ export default class CxMenu extends CortexElement {
65
65
  adjustMenuSize(duration?: number): Promise<void>;
66
66
  resetActiveMenu(): void;
67
67
  getActiveMenu(): CxMenu | undefined;
68
- /**
69
- * @internal Gets the current menu item, which is the menu item that has `tabindex="0"` within the roving tab index.
70
- * The menu item may or may not have focus, but for keyboard interaction purposes it's considered the "active" item.
71
- */
72
- getCurrentItem(): CxMenuItem | undefined;
73
- /**
74
- * @internal Sets the current menu item to the specified element. This sets `tabindex="0"` on the target element and
75
- * `tabindex="-1"` to all other items. This method must be called prior to setting focus on a menu item.
76
- */
68
+ /** @internal Sets `tabindex="0"` on `item` and `tabindex="-1"` on all others. Call before focusing a menu item. */
77
69
  setCurrentItem(item: CxMenuItem): void;
78
70
  render(): import('lit').TemplateResult<1>;
79
71
  }
@@ -29,7 +29,10 @@ export default class CxContentBuilderViewer extends CortexLightElement {
29
29
  private readonly processedFetchableBlocks;
30
30
  /** Blocks already populated by a previous space-list scan; skipped on re-scans. */
31
31
  private readonly processedSpaceListBlocks;
32
+ /** Blocks already populated by a previous page-list scan; skipped on re-scans. */
33
+ private readonly processedPageListBlocks;
32
34
  private apiGetTeamSpaceSpaceList;
35
+ private apiGetAllPagesAndLinks;
33
36
  constructor();
34
37
  createRenderRoot(): this;
35
38
  connectedCallback(): void;
@@ -59,6 +62,16 @@ export default class CxContentBuilderViewer extends CortexLightElement {
59
62
  private fetchSpaceList;
60
63
  private collectPendingSpaceListBlocks;
61
64
  private applySpaceList;
65
+ private scanAndFetchPageList;
66
+ /**
67
+ * One request per element, shared by every scan — same reasoning as the space list.
68
+ *
69
+ * Neither an empty result nor a failure is retained, so it is retried on the next scan
70
+ * instead of leaving every page card blank for the session.
71
+ */
72
+ private fetchPageList;
73
+ private collectPendingPageListBlocks;
74
+ private applyPageList;
62
75
  }
63
76
  declare global {
64
77
  interface HTMLElementTagNameMap {
@@ -30,6 +30,7 @@ export declare class WorkerProxy implements IDownloadManager {
30
30
  start(enableRocketMode: boolean, keepDownloading: boolean): Promise<void>;
31
31
  restart(): Promise<void>;
32
32
  handleCookiesRejected(): void;
33
+ handleCookiesAccepted(): Promise<void>;
33
34
  registerDownload(transactionID: string): Promise<string | null>;
34
35
  startDownload(transactionID: string, location: string): Promise<void>;
35
36
  pauseFile(fileID: string): Promise<void>;
@@ -36,6 +36,11 @@ export type IDownloadManager = {
36
36
  getChunkSize: () => Promise<number>;
37
37
  getDefaultRootName: () => Promise<string | null>;
38
38
  getFile: (id: string) => Promise<GetFileQuery.QueryResult>;
39
+ /**
40
+ * Do necessary handling when the user has accepted cookies for downloader again
41
+ * after previously rejecting them
42
+ */
43
+ handleCookiesAccepted: () => Promise<void>;
39
44
  /**
40
45
  * Do necessary handling when the user has rejected cookies for downloader
41
46
  */
@@ -82,6 +87,7 @@ export declare class DownloadManager implements IDownloadManager {
82
87
  private databaseDiscarded;
83
88
  constructor(context: DownloadContext, downloadDatabase: DownloadDatabase, downloadTransactionsRepo: IDownloadTransactionsRepository, downloadFilesRepo: IDownloadFilesRepository, downloadChunksRepo: IDownloadChunksRepository, downloadApiClient: IDownloadApiClient, storage: IStorage, eventHub: IEventHub, logger: ILogger, retrier: IRetrier, locker: ILocker);
84
89
  handleCookiesRejected(): void;
90
+ handleCookiesAccepted(): Promise<void>;
85
91
  private setupBackgroundJobs;
86
92
  isRocketModeEnabled(): Promise<boolean>;
87
93
  private internalToggleRocketMode;
@@ -146,6 +146,8 @@ export default class CxDownloader extends CortexElement {
146
146
  setCheckDefaultRootNameInterval(): void;
147
147
  checkCookiesRejectedInterval: NodeJS.Timer | undefined;
148
148
  setCheckCookiesRejectedInterval(): void;
149
+ checkCookiesAcceptedInterval: NodeJS.Timer | undefined;
150
+ setCheckCookiesAcceptedInterval(): void;
149
151
  cancelSingle: (id: string) => void;
150
152
  onCancelAll: () => Promise<void>;
151
153
  onClear: (id: string) => void;
@@ -0,0 +1,10 @@
1
+ import { EditorState } from '@tiptap/pm/state';
2
+
3
+ /**
4
+ * The link the caret is on, counting both edges as the legacy editor did (`isActive('link')` is
5
+ * true only strictly between them). Shared with the `link--active` decoration so both agree. (426ODZ)
6
+ */
7
+ export default function activeLinkRange(state: EditorState): {
8
+ from: number;
9
+ to: number;
10
+ } | null;
@@ -1,4 +1,17 @@
1
- export declare const Table: import('@tiptap/core').Node<import('@tiptap/extension-table').TableOptions, any>;
1
+ import { TableOptions } from '@tiptap/extension-table';
2
+
3
+ /** Inline style a new table starts with when the host does not pass its own. */
4
+ export declare const DEFAULT_TABLE_STYLE = "width: 100%;";
5
+ interface CortexTableOptions extends TableOptions {
6
+ /** Inline style a new table starts with. */
7
+ defaultTableStyle: string;
8
+ /** Shows the drag handle that selects the whole table. Off by default; the legacy editor had none. */
9
+ enableTableDragHandle: boolean;
10
+ /** Class stamped on every rendered table, on top of the author's own. Empty forces none. */
11
+ tableClass: string;
12
+ }
13
+ export declare const Table: import('@tiptap/core').Node<CortexTableOptions, any>;
2
14
  export declare const TableRow: import('@tiptap/core').Node<any, any>;
3
15
  export declare const TableHeader: import('@tiptap/core').Node<any, any>;
4
16
  export declare const TableCell: import('@tiptap/core').Node<any, any>;
17
+ export {};
@@ -350,6 +350,7 @@ export declare enum DialogType {
350
350
  Gallery = "gallery"
351
351
  }
352
352
  export type Page = {
353
+ description: string;
353
354
  hasChildren: boolean;
354
355
  id: string;
355
356
  title: string;
@@ -357,6 +358,7 @@ export type Page = {
357
358
  url: string | null;
358
359
  };
359
360
  export type Link = {
361
+ description: string;
360
362
  hasChildren: boolean;
361
363
  id: string;
362
364
  title: string;
@@ -866,11 +866,11 @@
866
866
  */
867
867
  ignoredKeys?: string[];
868
868
  /**
869
- *
869
+ * @deprecated Only stops ArrowUp/ArrowDown wrapping now; Tab is no longer intercepted.
870
870
  */
871
871
  disabledTabLoop?: boolean;
872
872
  /**
873
- * When true, checkbox items in this menu do not toggle off when already activated while checked—the same behavior as setting `no-uncheck` on each checkbox item.
873
+ * When true, checkbox items don't toggle off when already checked (same as each item's own `no-uncheck`).
874
874
  */
875
875
  noUncheck?: boolean;
876
876
  /**
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@orangelogic/design-system",
3
3
  "type": "module",
4
- "version": "2.207.0",
4
+ "version": "2.208.0",
5
5
  "license": "UNLICENSED",
6
6
  "types": "library/types.d.ts",
7
7
  "scripts": {