@kdlbs/plugin-sdk 0.3.0 → 0.4.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/package.json +1 -1
- package/sdk-release.json +3 -3
- package/src/index.ts +28 -0
package/package.json
CHANGED
package/sdk-release.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -6,6 +6,22 @@
|
|
|
6
6
|
* all runtime values during initialize and use these structural types at
|
|
7
7
|
* compile time only.
|
|
8
8
|
*/
|
|
9
|
+
|
|
10
|
+
/** Host-resolved complete grouping, distinct from page-local task-list facets. */
|
|
11
|
+
export type SidebarGroupingReference = `plugin:${string}:${string}`;
|
|
12
|
+
export interface SidebarGroupingProvider {
|
|
13
|
+
reference: SidebarGroupingReference;
|
|
14
|
+
label: string;
|
|
15
|
+
labelKey?: string;
|
|
16
|
+
generation: string;
|
|
17
|
+
}
|
|
18
|
+
export interface SidebarGroupingSnapshot {
|
|
19
|
+
version: 1;
|
|
20
|
+
revision: string;
|
|
21
|
+
complete: true;
|
|
22
|
+
groups: Array<{ id: string; label: string; color?: string }>;
|
|
23
|
+
memberships: Array<{ task_id: string; group_id: string }>;
|
|
24
|
+
}
|
|
9
25
|
export type HostNode = unknown;
|
|
10
26
|
// `any` is deliberate at these two React compatibility seams. Reproducing
|
|
11
27
|
// React's overloaded createElement and recursive ReactNode types would make
|
|
@@ -1486,7 +1502,19 @@ export interface IntegrationSettingsActionProps {
|
|
|
1486
1502
|
surface: IntegrationSettingsActionSurface;
|
|
1487
1503
|
}
|
|
1488
1504
|
|
|
1505
|
+
/** Host-selected, read-only file bytes. The host grants access before mounting. */
|
|
1506
|
+
export interface FileViewerProps {
|
|
1507
|
+
file: { name: string; sizeBytes: number; generation: string };
|
|
1508
|
+
readBytes(signal: AbortSignal): Promise<ArrayBuffer>;
|
|
1509
|
+
}
|
|
1510
|
+
export interface FileViewerRegistration {
|
|
1511
|
+
id: string;
|
|
1512
|
+
Component: Component<FileViewerProps>;
|
|
1513
|
+
}
|
|
1514
|
+
|
|
1489
1515
|
export interface PluginRegistry {
|
|
1516
|
+
/** Register a viewer declared in ui.file_viewers. */
|
|
1517
|
+
registerFileViewer(registration: FileViewerRegistration): void;
|
|
1490
1518
|
registerTranslations(catalogs: PluginTranslationCatalogs): void;
|
|
1491
1519
|
registerRoute(path: string, component: Component, options?: PluginRouteOptions): void;
|
|
1492
1520
|
registerNavItem(item: {
|