@xfey/tutti 0.1.21 → 0.1.22

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 (33) hide show
  1. package/dist/collaboration-state/index.d.ts +1 -1
  2. package/dist/collaboration-state/index.js +1 -1
  3. package/dist/collaboration-state/messages.js +50 -1
  4. package/dist/collaboration-state/scratchpad.d.ts +2 -0
  5. package/dist/collaboration-state/scratchpad.js +63 -0
  6. package/dist/collaboration-state/storage-types.d.ts +5 -0
  7. package/dist/collaboration-state/types.d.ts +8 -1
  8. package/dist/control-plane/scratchpad-refresh-start.d.ts +2 -0
  9. package/dist/control-plane/scratchpad-refresh-start.js +10 -0
  10. package/dist/control-plane/scratchpad-refresh.d.ts +2 -0
  11. package/dist/control-plane/scratchpad-refresh.js +1 -0
  12. package/dist/project-timeline/index.d.ts +17 -3
  13. package/dist/server-shell/http/routes/project-api/openapi-collaboration-routes.d.ts +1 -0
  14. package/dist/server-shell/http/routes/project-api/openapi-timeline-routes.d.ts +94 -5
  15. package/dist/server-shell/http/routes/project-api/openapi.d.ts +95 -5
  16. package/dist/server-shell/http/routes/project-api/payload-validation.d.ts +6 -2
  17. package/dist/server-shell/http/routes/project-api/payload-validation.js +3 -0
  18. package/dist/server-shell/http/routes/project-api/project-timeline-projection.js +694 -502
  19. package/migrations/0013_scratchpad_receipt_sources.sql +24 -0
  20. package/migrations/README.md +3 -2
  21. package/node_modules/@tutti/shared/dist/schemas/api/index.d.ts +1 -1
  22. package/node_modules/@tutti/shared/dist/schemas/api/index.js +1 -1
  23. package/node_modules/@tutti/shared/dist/schemas/api/messages.d.ts +1 -0
  24. package/node_modules/@tutti/shared/dist/schemas/api/messages.js +1 -0
  25. package/node_modules/@tutti/shared/dist/schemas/api/project-timeline.d.ts +313 -12
  26. package/node_modules/@tutti/shared/dist/schemas/api/project-timeline.js +131 -14
  27. package/node_modules/@tutti/shared/dist/schemas/api/types.d.ts +5 -1
  28. package/package.json +1 -1
  29. package/web/assets/index-BfFYfzeO.js +29 -0
  30. package/web/assets/index-De6mK5Q2.css +1 -0
  31. package/web/index.html +2 -2
  32. package/web/assets/index-BtneECwp.js +0 -29
  33. package/web/assets/index-CM9mbbeW.css +0 -1
@@ -1,5 +1,9 @@
1
- import type { GetMessagesRequest, SendClarificationRoundMessagePayload, SendMainChatMessagePayload, UpdateProjectDescriptionPayload, UpdateProjectDisplayNamePayload } from "@tutti/shared/schemas/api";
2
- export declare function requireValidMessageWindowRequest(query: GetMessagesRequest): GetMessagesRequest;
1
+ import type { SendClarificationRoundMessagePayload, SendMainChatMessagePayload, UpdateProjectDescriptionPayload, UpdateProjectDisplayNamePayload } from "@tutti/shared/schemas/api";
2
+ export declare function requireValidMessageWindowRequest<T extends {
3
+ before?: string;
4
+ after?: string;
5
+ around?: string;
6
+ }>(query: T): T;
3
7
  export declare function requireValidSendMainChatPayload(payload: SendMainChatMessagePayload): SendMainChatMessagePayload;
4
8
  export declare function requireValidRoundMessagePayload(payload: SendClarificationRoundMessagePayload): SendClarificationRoundMessagePayload;
5
9
  export declare function requireValidProjectDisplayNamePayload(payload: UpdateProjectDisplayNamePayload): UpdateProjectDisplayNamePayload;
@@ -3,6 +3,9 @@ export function requireValidMessageWindowRequest(query) {
3
3
  if (query.before !== undefined && query.after !== undefined) {
4
4
  throw new HostProjectBadRequestError("before and after cursors cannot be used together");
5
5
  }
6
+ if (query.around !== undefined && (query.before !== undefined || query.after !== undefined)) {
7
+ throw new HostProjectBadRequestError("around cannot be used with before or after cursors");
8
+ }
6
9
  return query;
7
10
  }
8
11
  export function requireValidSendMainChatPayload(payload) {