@curless/hotel-storefront 0.2.0 → 0.4.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 (44) hide show
  1. package/dist/__tests__/data.test.js +91 -0
  2. package/dist/__tests__/data.test.js.map +1 -1
  3. package/dist/__tests__/dates.test.js +25 -1
  4. package/dist/__tests__/dates.test.js.map +1 -1
  5. package/dist/__tests__/demo-hotels.test.js +45 -0
  6. package/dist/__tests__/demo-hotels.test.js.map +1 -1
  7. package/dist/__tests__/present.test.js +12 -1
  8. package/dist/__tests__/present.test.js.map +1 -1
  9. package/dist/__tests__/tools.test.js +29 -4
  10. package/dist/__tests__/tools.test.js.map +1 -1
  11. package/dist/backend.d.ts +10 -0
  12. package/dist/backend.d.ts.map +1 -1
  13. package/dist/backend.js +23 -1
  14. package/dist/backend.js.map +1 -1
  15. package/dist/card.generated.d.ts +1 -1
  16. package/dist/card.generated.js +2 -2
  17. package/dist/card.generated.js.map +1 -1
  18. package/dist/data.d.ts.map +1 -1
  19. package/dist/data.js +32 -2
  20. package/dist/data.js.map +1 -1
  21. package/dist/dates.d.ts +3 -3
  22. package/dist/dates.d.ts.map +1 -1
  23. package/dist/dates.js +59 -4
  24. package/dist/dates.js.map +1 -1
  25. package/dist/demo-hotels.d.ts +16 -0
  26. package/dist/demo-hotels.d.ts.map +1 -1
  27. package/dist/demo-hotels.js +47 -4
  28. package/dist/demo-hotels.js.map +1 -1
  29. package/dist/legal.d.ts.map +1 -1
  30. package/dist/legal.js +15 -0
  31. package/dist/legal.js.map +1 -1
  32. package/dist/present.d.ts +12 -0
  33. package/dist/present.d.ts.map +1 -1
  34. package/dist/present.js +9 -0
  35. package/dist/present.js.map +1 -1
  36. package/dist/server.d.ts +8 -8
  37. package/dist/server.js +2 -2
  38. package/dist/tools.d.ts +2 -2
  39. package/dist/tools.d.ts.map +1 -1
  40. package/dist/tools.js +23 -3
  41. package/dist/tools.js.map +1 -1
  42. package/dist/types.d.ts +11 -0
  43. package/dist/types.d.ts.map +1 -1
  44. package/package.json +1 -1
package/dist/backend.js CHANGED
@@ -1,2 +1,24 @@
1
- export {};
1
+ /**
2
+ * Where the rooms come from.
3
+ *
4
+ * ⚠️ THE WHOLE PACKAGE TALKS TO THIS AND NOTHING ELSE. Today the only
5
+ * implementation reads a JSON file of demonstration data (`DemoHotels`); the
6
+ * group's real booking API is coming (robin, 2026-09-18), and when it does it
7
+ * arrives as a second implementation - the tools, the card and the evals do not
8
+ * learn about it. That is the entire reason this interface exists rather than
9
+ * the tools reading the data file directly.
10
+ *
11
+ * Every method that can carry a price takes a `Stay`, because a room has no
12
+ * price until someone names the nights.
13
+ */
14
+ /**
15
+ * The most hotels one browse may answer with, whatever `limit` asked for.
16
+ *
17
+ * Not a display limit - a context limit, and part of this seam's contract
18
+ * rather than any one backend's habit. Ninety-six hotels with their
19
+ * descriptions is about seventy kilobytes of JSON, which is what a model asking
20
+ * for "all of them" would be handed before it has decided anything. A negative
21
+ * `limit` used to reach `slice(0, -3)` and return ninety-three.
22
+ */
23
+ export const MAX_PAGE = 50;
2
24
  //# sourceMappingURL=backend.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"backend.js","sourceRoot":"","sources":["../src/backend.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"backend.js","sourceRoot":"","sources":["../src/backend.ts"],"names":[],"mappings":"AAeA;;;;;;;;;;;;GAYG;AACH;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,EAAE,CAAC"}
@@ -1,4 +1,4 @@
1
1
  export declare const HOTEL_CARD_HTML: string;
2
2
  /** sha256 of widget/src + widget/index.html at build time - the drift guard reads this. */
3
- export declare const HOTEL_CARD_SOURCE_SHA = "d5e92e7909f1f51be6ace0a732ce6da46b969e06f5493824e6752dc6b9264436";
3
+ export declare const HOTEL_CARD_SOURCE_SHA = "7eeb40ba5f463b23e978e6669e0ea6c24d4c4eec1319d1bcfdaa291c2b0462fc";
4
4
  //# sourceMappingURL=card.generated.d.ts.map