@kubohiroya/turbowarp-plus-editor-git 0.0.0-stage → 0.7.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.
Files changed (59) hide show
  1. package/LICENSE +373 -0
  2. package/README.ja.md +105 -0
  3. package/README.md +35 -2
  4. package/THIRD_PARTY_NOTICES.md +5 -0
  5. package/dist/THIRD_PARTY_NOTICES.md +1186 -0
  6. package/dist/block-diff-location.d.ts +22 -0
  7. package/dist/block-diff-preview.d.ts +17 -0
  8. package/dist/browser.d.ts +4 -0
  9. package/dist/connection-settings.d.ts +35 -0
  10. package/dist/file-diff-view.d.ts +16 -0
  11. package/dist/filesystem.d.ts +89 -0
  12. package/dist/github-pull-requests.d.ts +38 -0
  13. package/dist/index.d.ts +29 -0
  14. package/dist/index.js +3556 -0
  15. package/dist/libesm-OWRWzmu_.js +739 -0
  16. package/dist/messages.d.ts +112 -0
  17. package/dist/mutation-fs.d.ts +58 -0
  18. package/dist/objectSpread2-Dkd68nJH.js +101 -0
  19. package/dist/project-source-diff.d.ts +22 -0
  20. package/dist/project-source-diff.js +169 -0
  21. package/dist/project-source-patch.d.ts +39 -0
  22. package/dist/project-source-review-model.d.ts +20 -0
  23. package/dist/project-source-review.d.ts +34 -0
  24. package/dist/pull-request-panel.d.ts +8 -0
  25. package/dist/remote-operations.d.ts +5 -0
  26. package/dist/repository-DplMQiuo.js +17212 -0
  27. package/dist/repository.d.ts +61 -0
  28. package/dist/repository.js +1 -0
  29. package/dist/scratch-block-diff-renderer-CLYoOIB2.js +1464 -0
  30. package/dist/scratch-block-diff-renderer.d.ts +65 -0
  31. package/dist/smart-http-BmHEkE7K.js +303 -0
  32. package/dist/smart-http.d.ts +60 -0
  33. package/dist/smart-http.js +1 -0
  34. package/dist/style.css +109 -0
  35. package/package.json +60 -4
  36. package/src/block-diff-location.ts +63 -0
  37. package/src/block-diff-preview.tsx +36 -0
  38. package/src/browser.ts +5 -0
  39. package/src/connection-settings.tsx +103 -0
  40. package/src/file-diff-view.tsx +43 -0
  41. package/src/filesystem.ts +125 -0
  42. package/src/github-pull-requests.ts +162 -0
  43. package/src/index.tsx +349 -0
  44. package/src/messages.ts +64 -0
  45. package/src/mutation-fs.ts +204 -0
  46. package/src/project-source-diff.css +79 -0
  47. package/src/project-source-diff.tsx +132 -0
  48. package/src/project-source-patch.ts +126 -0
  49. package/src/project-source-review-model.ts +113 -0
  50. package/src/project-source-review.tsx +217 -0
  51. package/src/pull-request-panel.tsx +134 -0
  52. package/src/remote-operations.ts +90 -0
  53. package/src/repository.ts +308 -0
  54. package/src/scratch-block-diff-renderer.ts +213 -0
  55. package/src/smart-http.ts +190 -0
  56. package/src/style.css +29 -0
  57. package/src/styles.d.ts +1 -0
  58. package/tsconfig.json +18 -0
  59. package/vite.config.ts +26 -0
@@ -0,0 +1,61 @@
1
+ import type { GetRemoteSession, RemoteOperation } from './remote-operations.js';
2
+ export { createReadOnlyFs, GitPanelError } from './filesystem.js';
3
+ export type ChangeGroup = 'staged' | 'unstaged' | 'untracked' | 'commit';
4
+ export interface FileChange {
5
+ path: string;
6
+ group: ChangeGroup;
7
+ before: string | null;
8
+ after: string | null;
9
+ worktree: boolean;
10
+ oldMode: number | null;
11
+ newMode: number | null;
12
+ }
13
+ export interface Commit {
14
+ oid: string;
15
+ message: string;
16
+ author: string;
17
+ timestamp: number;
18
+ }
19
+ type Metadata = Map<string, Uint8Array | null>;
20
+ export interface Snapshot {
21
+ branch: string | undefined;
22
+ head: string | null;
23
+ branches: string[];
24
+ commits: Commit[];
25
+ changes: FileChange[];
26
+ scope: string;
27
+ metadata: Metadata;
28
+ /** Size and time fingerprint taken before the read. Compare it with `probe(scope)` to see later changes. */
29
+ probe: string;
30
+ }
31
+ export interface FileDiff {
32
+ binary: boolean;
33
+ patch: string;
34
+ /**
35
+ * Both versions as text, for views that read the content instead of the patch. A missing version is empty.
36
+ * Absent for binary content and above the text limit, except for project.source.json up to 16 MiB.
37
+ */
38
+ text?: {
39
+ before: string;
40
+ after: string;
41
+ };
42
+ beforeSize: number;
43
+ afterSize: number;
44
+ tooLarge: boolean;
45
+ }
46
+ export declare function openRepository(root: FileSystemDirectoryHandle): Promise<{
47
+ root: FileSystemDirectoryHandle;
48
+ openProject: (path: string) => Promise<FileSystemDirectoryHandle>;
49
+ browse: (path?: string) => Promise<{
50
+ path: string;
51
+ children: string[];
52
+ isProject: boolean;
53
+ }>;
54
+ probe: (scope?: string) => Promise<string>;
55
+ readOrigin: () => Promise<any>;
56
+ remoteOperation: (operation: RemoteOperation, getSession: GetRemoteSession, guard: () => void, signal?: AbortSignal) => Promise<void>;
57
+ read: (scope?: string) => Promise<Snapshot>;
58
+ readDiff: (snapshot: Snapshot, change: FileChange) => Promise<FileDiff>;
59
+ historyChanges: (snapshot: Snapshot, oid: string) => Promise<FileChange[]>;
60
+ }>;
61
+ export type Repository = Awaited<ReturnType<typeof openRepository>>;
@@ -0,0 +1 @@
1
+ export { n as GitPanelError, r as createReadOnlyFs, t as openRepository } from "./repository-DplMQiuo.js";