@wix/himalaya-cli 0.1529.0 → 0.1530.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 (70) hide show
  1. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk/bookings-v2/src/index.d.ts +24 -0
  2. package/dist/cli.mjs +717 -484
  3. package/dist/preview-assets.generated.bin +0 -0
  4. package/guides/release-notes.md +17 -0
  5. package/guides/templates.md +11 -1
  6. package/guides/tier-5-add-a-screen.md +4 -0
  7. package/package.json +2 -2
  8. package/templates/beauty-salon/dev/index.ts +1767 -2698
  9. package/templates/beauty-salon/tier5-src/_shared/collection-service.ts +23 -5
  10. package/templates/beauty-salon/tier5-src/_shared/engine-intl.ts +18 -0
  11. package/templates/beauty-salon/tier5-src/_shared/member-bookings.ts +50 -7
  12. package/templates/beauty-salon/tier5-src/himi-booking-bookings/index.ts +385 -74
  13. package/templates/beauty-salon-owner/tier5-src/_shared/collection-service.ts +23 -5
  14. package/templates/beauty-salon-owner/tier5-src/_shared/engine-intl.ts +18 -0
  15. package/templates/branded-lite/dev/index.ts +1753 -2697
  16. package/templates/branded-lite/tier5-src/_shared/collection-service.ts +23 -5
  17. package/templates/branded-lite/tier5-src/_shared/engine-intl.ts +18 -0
  18. package/templates/branded-lite/tier5-src/_shared/member-bookings.ts +50 -7
  19. package/templates/branded-lite/tier5-src/himi-booking-bookings/index.ts +385 -74
  20. package/templates/community-club/tier5-src/_shared/collection-service.ts +23 -5
  21. package/templates/community-club/tier5-src/_shared/engine-intl.ts +18 -0
  22. package/templates/community-club/tier5-src/_shared/member-bookings.ts +50 -7
  23. package/templates/community-club-owner/tier5-src/_shared/collection-service.ts +23 -5
  24. package/templates/community-club-owner/tier5-src/_shared/engine-intl.ts +18 -0
  25. package/templates/events-meetups/tier5-src/_shared/collection-service.ts +23 -5
  26. package/templates/events-meetups/tier5-src/_shared/engine-intl.ts +18 -0
  27. package/templates/events-meetups/tier5-src/_shared/member-bookings.ts +50 -7
  28. package/templates/events-meetups-owner/tier5-src/_shared/collection-service.ts +23 -5
  29. package/templates/events-meetups-owner/tier5-src/_shared/engine-intl.ts +18 -0
  30. package/templates/gym-fitness/dev/index.ts +1753 -2697
  31. package/templates/gym-fitness/tier5-src/_shared/collection-service.ts +23 -5
  32. package/templates/gym-fitness/tier5-src/_shared/engine-intl.ts +18 -0
  33. package/templates/gym-fitness/tier5-src/_shared/member-bookings.ts +50 -7
  34. package/templates/gym-fitness/tier5-src/himi-booking-bookings/index.ts +385 -74
  35. package/templates/gym-fitness-owner/tier5-src/_shared/collection-service.ts +23 -5
  36. package/templates/gym-fitness-owner/tier5-src/_shared/engine-intl.ts +18 -0
  37. package/templates/nonprofit-cause/tier5-src/_shared/collection-service.ts +23 -5
  38. package/templates/nonprofit-cause/tier5-src/_shared/engine-intl.ts +18 -0
  39. package/templates/nonprofit-cause/tier5-src/_shared/member-bookings.ts +50 -7
  40. package/templates/nonprofit-cause-owner/tier5-src/_shared/collection-service.ts +23 -5
  41. package/templates/nonprofit-cause-owner/tier5-src/_shared/engine-intl.ts +18 -0
  42. package/templates/owner-lite/tier5-src/_shared/collection-service.ts +23 -5
  43. package/templates/owner-lite/tier5-src/_shared/engine-intl.ts +18 -0
  44. package/templates/podcast-creator/tier5-src/_shared/collection-service.ts +23 -5
  45. package/templates/podcast-creator/tier5-src/_shared/engine-intl.ts +18 -0
  46. package/templates/podcast-creator/tier5-src/_shared/member-bookings.ts +50 -7
  47. package/templates/podcast-creator-owner/tier5-src/_shared/collection-service.ts +23 -5
  48. package/templates/podcast-creator-owner/tier5-src/_shared/engine-intl.ts +18 -0
  49. package/templates/portfolio-creative/tier5-src/_shared/collection-service.ts +23 -5
  50. package/templates/portfolio-creative/tier5-src/_shared/engine-intl.ts +18 -0
  51. package/templates/portfolio-creative/tier5-src/_shared/member-bookings.ts +50 -7
  52. package/templates/portfolio-creative-owner/tier5-src/_shared/collection-service.ts +23 -5
  53. package/templates/portfolio-creative-owner/tier5-src/_shared/engine-intl.ts +18 -0
  54. package/templates/restaurant/tier5-src/_shared/collection-service.ts +23 -5
  55. package/templates/restaurant/tier5-src/_shared/engine-intl.ts +18 -0
  56. package/templates/restaurant/tier5-src/_shared/member-bookings.ts +50 -7
  57. package/templates/restaurant-owner/tier5-src/_shared/collection-service.ts +23 -5
  58. package/templates/restaurant-owner/tier5-src/_shared/engine-intl.ts +18 -0
  59. package/templates/retail-store/tier5-src/_shared/collection-service.ts +23 -5
  60. package/templates/retail-store/tier5-src/_shared/engine-intl.ts +18 -0
  61. package/templates/retail-store/tier5-src/_shared/member-bookings.ts +50 -7
  62. package/templates/retail-store-owner/tier5-src/_shared/collection-service.ts +23 -5
  63. package/templates/retail-store-owner/tier5-src/_shared/engine-intl.ts +18 -0
  64. package/templates/yoga-studio/dev/index.ts +1755 -2699
  65. package/templates/yoga-studio/tier5-src/_shared/collection-service.ts +23 -5
  66. package/templates/yoga-studio/tier5-src/_shared/engine-intl.ts +18 -0
  67. package/templates/yoga-studio/tier5-src/_shared/member-bookings.ts +50 -7
  68. package/templates/yoga-studio/tier5-src/himi-booking-bookings/index.ts +385 -74
  69. package/templates/yoga-studio-owner/tier5-src/_shared/collection-service.ts +23 -5
  70. package/templates/yoga-studio-owner/tier5-src/_shared/engine-intl.ts +18 -0
@@ -108,6 +108,24 @@ export function formatMonthDayLong(date: Date, locale = "en-US", timeZone?: stri
108
108
  return `${MONTHS_LONG[date.getMonth()]} ${date.getDate()}`;
109
109
  }
110
110
 
111
+ const WEEKDAYS_LONG = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"] as const;
112
+
113
+ /** `{ weekday: "short", month: "short", day: "numeric" }` — "Mon, Jan 5". */
114
+ export function formatWeekdayMonthDay(date: Date, locale = "en-US", timeZone?: string): string {
115
+ if (hasIntl()) {
116
+ return dateFormat(locale, { weekday: "short", month: "short", day: "numeric" }, timeZone).format(date);
117
+ }
118
+ return `${WEEKDAYS_SHORT[date.getDay()]}, ${MONTHS_SHORT[date.getMonth()]} ${date.getDate()}`;
119
+ }
120
+
121
+ /** `{ weekday: "long", month: "long", day: "numeric" }` — "Monday, January 5". */
122
+ export function formatWeekdayMonthDayLong(date: Date, locale = "en-US", timeZone?: string): string {
123
+ if (hasIntl()) {
124
+ return dateFormat(locale, { weekday: "long", month: "long", day: "numeric" }, timeZone).format(date);
125
+ }
126
+ return `${WEEKDAYS_LONG[date.getDay()]}, ${MONTHS_LONG[date.getMonth()]} ${date.getDate()}`;
127
+ }
128
+
111
129
  /** `{ weekday: "short", month: "short", day: "numeric", hour: "numeric", minute: "2-digit" }`
112
130
  * — "Mon, Jan 5, 3:07 PM". */
113
131
  export function formatWeekdayDateTime(date: Date, locale = "en-US", timeZone?: string): string {