@xrn1997/dsh-session-delete 0.3.1 → 0.5.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 (83) hide show
  1. package/LICENSE +201 -201
  2. package/README.md +141 -129
  3. package/cordis.patch.yml +3 -3
  4. package/lib/client.js +2811 -1264
  5. package/lib/index.js +2368 -1277
  6. package/lib/types/api/attachment-orphans.d.ts +11 -0
  7. package/lib/types/api/attachment.d.ts +23 -0
  8. package/lib/types/api/dispatch.d.ts +13 -29
  9. package/lib/types/api/request-trust.d.ts +45 -0
  10. package/lib/types/api/route-table.d.ts +52 -18
  11. package/lib/types/api/trash-rows.d.ts +3 -3
  12. package/lib/types/client/attachment-view.d.ts +27 -0
  13. package/lib/types/client/batch-bar.d.ts +1 -1
  14. package/lib/types/client/batch-confirm.d.ts +2 -2
  15. package/lib/types/client/batch-menu-item.d.ts +1 -1
  16. package/lib/types/client/batch-select.d.ts +1 -1
  17. package/lib/types/client/busy-gate.d.ts +6 -2
  18. package/lib/types/client/confirm-close.d.ts +14 -0
  19. package/lib/types/client/context.d.ts +3 -2
  20. package/lib/types/client/copy.d.ts +102 -42
  21. package/lib/types/client/delete-confirm.d.ts +1 -3
  22. package/lib/types/client/delete-menu-item.d.ts +1 -1
  23. package/lib/types/client/host-rows.d.ts +5 -1
  24. package/lib/types/client/main-view.d.ts +1 -1
  25. package/lib/types/client/maintenance-parts.d.ts +25 -0
  26. package/lib/types/client/maintenance-settings.d.ts +22 -0
  27. package/lib/types/client/markdown.d.ts +9 -2
  28. package/lib/types/client/orphan-maintenance.d.ts +16 -13
  29. package/lib/types/client/receipt.d.ts +44 -2
  30. package/lib/types/client/remote.d.ts +38 -50
  31. package/lib/types/client/store.d.ts +14 -3
  32. package/lib/types/client/trash-confirm.d.ts +2 -15
  33. package/lib/types/client/trash-detail.d.ts +48 -6
  34. package/lib/types/client/trash-entry.d.ts +1 -1
  35. package/lib/types/client/trash-nav.d.ts +12 -8
  36. package/lib/types/client/trash-panel.d.ts +4 -3
  37. package/lib/types/client/ui/Checkbox.d.ts +1 -1
  38. package/lib/types/client/ui/Modal.d.ts +2 -2
  39. package/lib/types/client/ui/Toast.d.ts +3 -1
  40. package/lib/types/client/ui/icons.d.ts +7 -12
  41. package/lib/types/client/ui/top-layer.d.ts +10 -0
  42. package/lib/types/client/undo-notices.d.ts +52 -0
  43. package/lib/types/client/undo-toast.d.ts +6 -59
  44. package/lib/types/client/use-column-resize.d.ts +9 -20
  45. package/lib/types/client/use-maintenance-section.d.ts +52 -0
  46. package/lib/types/client/use-maintenance.d.ts +17 -0
  47. package/lib/types/client/use-panel-width.d.ts +1 -1
  48. package/lib/types/client/use-trash-panel-controller.d.ts +54 -16
  49. package/lib/types/client/use-trash-query.d.ts +39 -34
  50. package/lib/types/client/use-trash-selection.d.ts +15 -12
  51. package/lib/types/client/write-seats.d.ts +36 -28
  52. package/lib/types/client/write-settlement.d.ts +11 -17
  53. package/lib/types/client/write.d.ts +21 -8
  54. package/lib/types/deps.d.ts +18 -7
  55. package/lib/types/domain/closure.d.ts +44 -0
  56. package/lib/types/index.d.ts +6 -2
  57. package/lib/types/log/session-log.d.ts +4 -3
  58. package/lib/types/log/zstd-frames.d.ts +13 -8
  59. package/lib/types/ports/agent-handles.d.ts +1 -1
  60. package/lib/types/ports/connection-port.d.ts +33 -0
  61. package/lib/types/ports/fs-port.d.ts +24 -9
  62. package/lib/types/ports/host-port.d.ts +21 -50
  63. package/lib/types/ports/presence-port.d.ts +31 -0
  64. package/lib/types/shared/wire.d.ts +175 -38
  65. package/lib/types/trash/attachments.d.ts +92 -0
  66. package/lib/types/trash/detail.d.ts +46 -16
  67. package/lib/types/trash/entry.d.ts +10 -4
  68. package/lib/types/trash/groups.d.ts +9 -11
  69. package/lib/types/trash/manifest.d.ts +4 -4
  70. package/lib/types/trash/storage-manifest.d.ts +1 -1
  71. package/lib/types/verbs/batch-carried.d.ts +1 -3
  72. package/lib/types/verbs/delete-session.d.ts +2 -2
  73. package/lib/types/verbs/errors.d.ts +2 -0
  74. package/lib/types/verbs/live-admission.d.ts +4 -7
  75. package/lib/types/verbs/member-journal.d.ts +3 -4
  76. package/lib/types/verbs/member-presence.d.ts +16 -37
  77. package/lib/types/verbs/move-group.d.ts +2 -1
  78. package/lib/types/verbs/orphan-subagents.d.ts +19 -12
  79. package/lib/types/verbs/permanent-removal.d.ts +60 -25
  80. package/lib/types/verbs/restore-session.d.ts +7 -13
  81. package/lib/types/verbs/trash-scope.d.ts +36 -0
  82. package/package.json +117 -106
  83. package/lib/types/verbs/purge-trash.d.ts +0 -30
@@ -1,30 +0,0 @@
1
- import type { TrashEntry } from '../trash/entry.js';
2
- import type { CoreDeps } from '../deps.js';
3
- /**
4
- * 彻底删除:从回收站里**真的**抹掉一条(或整组、或整站),并连带那些"还留在盘上、没被带走"的后代。
5
- *
6
- * 与另外两个动词的关系(ADR-0002):它的 interface 是"这一组目标 + 一份只读清册快照
7
- *(targets 缺席 = 清空)";目标由 `verbs/batch-carried.ts` 按组语义算好,批量的"已被同批前一条
8
- * 带走"判据不在这里。`requestedId` 是唯一的例外参数,但它**不参与任何判据**:只是让
9
- * `trash-empty` 的原文点得出用户点的是哪一条(原文要上屏,点名承重),批量语义仍在批量层。
10
- *
11
- * **这条动词只做两件事:拿目标、把计划交给执行器**。量目录、筛盘上后代、活体准入与"先退归档集、
12
- * 再摘账本、最后删目录"的顺序都住 `verbs/permanent-removal.ts`——计划只读,执行器只写,计划就是
13
- * 执行前的闸(别在这里再长出一段手写步骤)。
14
- *
15
- * **这条动词不做回滚**:目录删掉就没有"退回去"这回事(2026-10-19 `f2a7757`:删到一半失败时已删目录不回滚;
16
- * 带部分计数的 `details` 回执只属于 `orphan-clean`,purge 的 `removed` / `freedBytes` 仍只在成功回执里给)。
17
- * 对应地,`kind:'trash'` 的计划失败时执行器只抛那一步的 `io` 与原文、不带 details。
18
- */
19
- export declare function purgeTrash(deps: CoreDeps): (
20
- /** 这一组(只读);`undefined` = 清空。批量层由 `batch-carried.ts` 的 `claimOf` 给出,直调者
21
- * 按 `trash/groups.ts` 的 `groupOf` 自己算;ghost 父的组只有孩子(不含 `requestedId`),照样清
22
- * 这一组。 */
23
- targets: readonly TrashEntry[] | undefined,
24
- /** **只读**清册快照:批量层已经读过一次就递下来;收缩归 `batch-carried.ts`,动词不碰它。 */
25
- rows: readonly TrashEntry[],
26
- /** 只用于 `trash-empty` 的原文要点名用户点的那一条;不参与任何判据(批量语义归 `batch-carried.ts`)。 */
27
- requestedId?: string) => Promise<{
28
- removed: number;
29
- freedBytes: number;
30
- }>;