@narumitw/pi-image-drop 0.25.0 → 0.30.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/README.md +11 -4
- package/package.json +16 -5
- package/src/index.ts +1 -0
- package/src/runtime.ts +1 -4
- package/src/server.ts +8 -2
- package/src/web/app.js +97 -537
- package/src/web/index.html +2 -102
- package/src/web/state.js +5 -114
- package/src/web/styles.css +2 -538
- package/src/web/ui/app.tsx +178 -0
- package/src/web/ui/client.ts +377 -0
- package/src/web/ui/components.tsx +615 -0
- package/src/web/ui/state.ts +149 -0
- package/src/web/ui/styles.css +572 -0
- package/src/web/ui/types.ts +56 -0
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
BatchPhase,
|
|
3
|
+
HistoryRestageResult,
|
|
4
|
+
ItemStatus,
|
|
5
|
+
PublicBatchItem,
|
|
6
|
+
PublicBatchState,
|
|
7
|
+
PublicHistoryItem,
|
|
8
|
+
PublicHistoryState,
|
|
9
|
+
} from "../../batch.js";
|
|
10
|
+
|
|
11
|
+
export type {
|
|
12
|
+
BatchPhase,
|
|
13
|
+
HistoryRestageResult,
|
|
14
|
+
ItemStatus,
|
|
15
|
+
PublicBatchItem,
|
|
16
|
+
PublicBatchState,
|
|
17
|
+
PublicHistoryItem,
|
|
18
|
+
PublicHistoryState,
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
export interface ImageDropState {
|
|
22
|
+
projectName: string;
|
|
23
|
+
sessionName?: string;
|
|
24
|
+
cwd: string;
|
|
25
|
+
activeClientId?: string;
|
|
26
|
+
batch: PublicBatchState;
|
|
27
|
+
history: PublicHistoryState;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export interface RestageState extends ImageDropState {
|
|
31
|
+
restage: HistoryRestageResult;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export interface UploadState extends ImageDropState {
|
|
35
|
+
duplicateOf?: string;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export interface ConnectionFailure {
|
|
39
|
+
title: string;
|
|
40
|
+
message: string;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export interface ImageDropView {
|
|
44
|
+
state?: ImageDropState;
|
|
45
|
+
error: string;
|
|
46
|
+
connectionFailure?: ConnectionFailure;
|
|
47
|
+
highlightedId?: string;
|
|
48
|
+
focusTarget?: string;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export interface RequestOptions {
|
|
52
|
+
method?: string;
|
|
53
|
+
headers?: HeadersInit;
|
|
54
|
+
body?: BodyInit;
|
|
55
|
+
json?: unknown;
|
|
56
|
+
}
|