pollination-react-io 1.15.0 → 1.16.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/build/RunCard/RunCard.d.ts +5 -0
- package/build/RunCard/RunCard.types.d.ts +10 -0
- package/build/RunsList/RunsList.d.ts +5 -0
- package/build/RunsList/RunsList.types.d.ts +10 -0
- package/build/SelectRun/SelectRun.types.d.ts +2 -3
- package/build/atoms/ComboBox/ComboBox.d.ts +0 -1
- package/build/atoms/ScrollZone/ScrollZone.d.ts +6 -0
- package/build/atoms/ScrollZone/ScrollZone.types.d.ts +16 -0
- package/build/hooks/index.d.ts +1 -0
- package/build/hooks/useRuns.d.ts +54 -0
- package/build/hooks/utilities.d.ts +2 -0
- package/build/index.esm.js +2995 -2812
- package/build/index.esm.js.map +1 -1
- package/build/index.js +3000 -2811
- package/build/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Run, UserPrivate } from '@pollination-solutions/pollination-sdk';
|
|
2
|
+
import { APIClient } from '../hooks';
|
|
3
|
+
export interface RunCardProps {
|
|
4
|
+
projectOwner: string;
|
|
5
|
+
projectName: string;
|
|
6
|
+
jobId: string;
|
|
7
|
+
run: Run;
|
|
8
|
+
client?: APIClient;
|
|
9
|
+
authUser?: UserPrivate;
|
|
10
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { UserPrivate } from '@pollination-solutions/pollination-sdk';
|
|
2
|
+
import { APIClient } from '../hooks';
|
|
3
|
+
export interface RunsListProps {
|
|
4
|
+
projectOwner: string;
|
|
5
|
+
projectName: string;
|
|
6
|
+
jobId: string[];
|
|
7
|
+
subscribe: boolean;
|
|
8
|
+
client: APIClient;
|
|
9
|
+
authUser?: UserPrivate;
|
|
10
|
+
}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { Run, UserPrivate } from '@pollination-solutions/pollination-sdk';
|
|
2
2
|
import { APIClient } from '../hooks';
|
|
3
3
|
export interface SelectRunProps {
|
|
4
|
-
authUser?: UserPrivate;
|
|
5
|
-
client?: APIClient;
|
|
6
4
|
projectOwner?: string;
|
|
7
5
|
projectName?: string;
|
|
8
6
|
jobId?: string[];
|
|
9
7
|
setSelRun?: (recipe: Run) => void;
|
|
10
|
-
|
|
8
|
+
authUser?: UserPrivate;
|
|
9
|
+
client?: APIClient;
|
|
11
10
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { GetPropsCommonOptions, UseComboboxGetItemPropsOptions, UseComboboxGetMenuPropsOptions } from 'downshift';
|
|
2
|
+
import { CSSProperties, ReactNode } from 'react';
|
|
3
|
+
export interface ScrollZoneProps {
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
items: any[];
|
|
6
|
+
highlightedIndex?: number;
|
|
7
|
+
menuStyle?: CSSProperties;
|
|
8
|
+
renderItem?: (item: any, i?: number, arr?: any[]) => ReactNode;
|
|
9
|
+
getMenuProps?: (options?: UseComboboxGetMenuPropsOptions, otherOptions?: GetPropsCommonOptions) => any;
|
|
10
|
+
getItemProps?: (options: UseComboboxGetItemPropsOptions<{
|
|
11
|
+
id: string;
|
|
12
|
+
name: string;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
}>) => any;
|
|
15
|
+
onScrollEnd?: (...args: any[]) => void;
|
|
16
|
+
}
|
package/build/hooks/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export * from './useGetGeometry';
|
|
|
6
6
|
export * from './useSendHbjson';
|
|
7
7
|
export * from './useSendMessage';
|
|
8
8
|
export * from './useRunCommand';
|
|
9
|
+
export * from './useRuns';
|
|
9
10
|
export * from './useManageSettings';
|
|
10
11
|
export * from './useHbjsontoVTK';
|
|
11
12
|
export * from './useArtifacts';
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import duration from 'dayjs/plugin/duration';
|
|
2
|
+
import { Run, RunStatusEnum } from '@pollination-solutions/pollination-sdk';
|
|
3
|
+
import { APIClient } from './useAPIClient';
|
|
4
|
+
export declare const statusMap: {
|
|
5
|
+
pending: {
|
|
6
|
+
color: string;
|
|
7
|
+
};
|
|
8
|
+
running: {
|
|
9
|
+
color: string;
|
|
10
|
+
};
|
|
11
|
+
failed: {
|
|
12
|
+
color: string;
|
|
13
|
+
};
|
|
14
|
+
canceled: {
|
|
15
|
+
color: string;
|
|
16
|
+
};
|
|
17
|
+
completed: {
|
|
18
|
+
color: string;
|
|
19
|
+
};
|
|
20
|
+
Created: {
|
|
21
|
+
color: string;
|
|
22
|
+
};
|
|
23
|
+
Scheduled: {
|
|
24
|
+
color: string;
|
|
25
|
+
};
|
|
26
|
+
Running: {
|
|
27
|
+
color: string;
|
|
28
|
+
};
|
|
29
|
+
'Pre-Processing': {
|
|
30
|
+
color: string;
|
|
31
|
+
};
|
|
32
|
+
PostProcessing: {
|
|
33
|
+
color: string;
|
|
34
|
+
};
|
|
35
|
+
Failed: {
|
|
36
|
+
color: string;
|
|
37
|
+
};
|
|
38
|
+
Cancelled: {
|
|
39
|
+
color: string;
|
|
40
|
+
};
|
|
41
|
+
Succeeded: {
|
|
42
|
+
color: string;
|
|
43
|
+
};
|
|
44
|
+
Unknown: {
|
|
45
|
+
color: string;
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
export declare const getSummaryColor: (status: any) => string;
|
|
49
|
+
export declare const getDuration: (run?: Run) => duration.Duration;
|
|
50
|
+
export declare const useRuns: (client: APIClient) => {
|
|
51
|
+
listRuns: (projectOwner: string, projectName: string, jobId?: string[], page?: number, perPage?: number, statusFilter?: RunStatusEnum) => Promise<import("@pollination-solutions/pollination-sdk").RunList>;
|
|
52
|
+
fetchRun: (projectOwner: string, projectName: string, runId: string) => Promise<Run>;
|
|
53
|
+
cancelRun: (projectOwner: string, projectName: string, runId: string) => Promise<any>;
|
|
54
|
+
};
|
|
@@ -4,3 +4,5 @@ export declare function checkRuby(): boolean;
|
|
|
4
4
|
export declare function sendMessageDotNet(message: PanelMessageIn): PanelMessageIn;
|
|
5
5
|
export declare function sendMessageRuby(message: PanelMessageIn): PanelMessageIn;
|
|
6
6
|
export declare function getHost(key?: string, defaultValue?: 'web' | 'rhino' | 'revit' | 'sketchup'): 'web' | 'rhino' | 'revit' | 'sketchup';
|
|
7
|
+
export declare const recipeLinkFromSource: (source: string) => string;
|
|
8
|
+
export declare function formatBytes(bytes: any, decimals?: number): string;
|