@nu-art/work-hub-shared 0.401.2 → 0.401.4

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/index.d.ts CHANGED
@@ -1,7 +1,2 @@
1
- export type WorkHubTab = {
2
- itemKey: string;
3
- id: string;
4
- label: string;
5
- tag?: string;
6
- renderArgs: any;
7
- };
1
+ export * from './types.js';
2
+ export * from './utils.js';
package/index.js CHANGED
@@ -1 +1,2 @@
1
- export {};
1
+ export * from './types.js';
2
+ export * from './utils.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nu-art/work-hub-shared",
3
- "version": "0.401.2",
3
+ "version": "0.401.4",
4
4
  "description": "TS WorkHub Shared",
5
5
  "keywords": [
6
6
  "TacB0sS",
@@ -21,8 +21,8 @@
21
21
  "linkDirectory": true
22
22
  },
23
23
  "dependencies": {
24
- "@nu-art/ts-common": "0.401.2",
25
- "@nu-art/thunderstorm-shared": "0.401.2",
24
+ "@nu-art/ts-common": "0.401.4",
25
+ "@nu-art/thunderstorm-shared": "0.401.4",
26
26
  "react": "^18.0.0"
27
27
  },
28
28
  "devDependencies": {
package/types.d.ts ADDED
@@ -0,0 +1,18 @@
1
+ export type WorkHubTab = {
2
+ itemKey: string;
3
+ id: string;
4
+ label: string;
5
+ tag?: string;
6
+ renderArgs: any;
7
+ };
8
+ export type WorkHubTabGroup_ColorScheme = {
9
+ foreground: string;
10
+ background: string;
11
+ };
12
+ export type WorkHubTabGroup = {
13
+ groupKey: string;
14
+ label: string;
15
+ color: WorkHubTabGroup_ColorScheme;
16
+ collapsed: boolean;
17
+ tabs: WorkHubTab[];
18
+ };
package/types.js ADDED
@@ -0,0 +1 @@
1
+ export {};
package/utils.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ import { WorkHubTab, WorkHubTabGroup } from './types.js';
2
+ export declare function isWorkHubTabGroup(item: WorkHubTabGroup | WorkHubTab): item is WorkHubTabGroup;
3
+ export declare function isWorkHubTab(item: WorkHubTabGroup | WorkHubTab): item is WorkHubTab;
package/utils.js ADDED
@@ -0,0 +1,6 @@
1
+ export function isWorkHubTabGroup(item) {
2
+ return 'groupKey' in item;
3
+ }
4
+ export function isWorkHubTab(item) {
5
+ return !isWorkHubTabGroup(item);
6
+ }