@wix/himalaya-cli 0.1538.0 → 0.1539.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.
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/sdk/state/src/index.d.ts +7 -0
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk/stores-v1/src/display.d.ts +4 -0
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/state.mjs +23 -0
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-events.mjs +1 -0
- package/dist/cli.mjs +3 -3
- package/guides/component-reference.json +24 -39
- package/guides/component-reference.md +59 -13
- package/guides/dynamic-list.service.ts +7 -1
- package/guides/form-submit.service.ts +7 -1
- package/guides/index.json +2 -2
- package/guides/recipe-four-state.md +10 -1
- package/guides/sdk-reference.json +966 -46
- package/guides/search-list.service.ts +7 -1
- package/package.json +2 -2
- package/templates/beauty-salon/dev/index.ts +5021 -4164
- package/templates/beauty-salon/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/beauty-salon/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/beauty-salon/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/beauty-salon/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/beauty-salon/tier5-src/_shared/store-order-presentation.ts +56 -0
- package/templates/beauty-salon/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/beauty-salon/tier5-src/himi-branded-lite-category/index.ts +196 -0
- package/templates/beauty-salon/tier5-src/himi-branded-lite-order/index.ts +29 -6
- package/templates/beauty-salon/tier5-src/himi-branded-lite-orders/index.ts +58 -5
- package/templates/beauty-salon/tier5-src/wix-spaces-collections/index.ts +37 -88
- package/templates/beauty-salon-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/beauty-salon-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/beauty-salon-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/branded-lite/dev/index.ts +4933 -4079
- package/templates/branded-lite/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/branded-lite/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/branded-lite/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/branded-lite/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/branded-lite/tier5-src/_shared/store-order-presentation.ts +56 -0
- package/templates/branded-lite/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/branded-lite/tier5-src/himi-branded-lite-category/index.ts +196 -0
- package/templates/branded-lite/tier5-src/himi-branded-lite-order/index.ts +29 -6
- package/templates/branded-lite/tier5-src/himi-branded-lite-orders/index.ts +58 -5
- package/templates/branded-lite/tier5-src/wix-spaces-collections/index.ts +37 -88
- package/templates/community-club/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/community-club/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/community-club/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/community-club/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/community-club/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/community-club-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/community-club-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/community-club-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/events-meetups/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/events-meetups/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/events-meetups/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/events-meetups/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/events-meetups/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/events-meetups-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/events-meetups-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/events-meetups-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/gym-fitness/dev/index.ts +5018 -4161
- package/templates/gym-fitness/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/gym-fitness/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/gym-fitness/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/gym-fitness/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/gym-fitness/tier5-src/_shared/store-order-presentation.ts +56 -0
- package/templates/gym-fitness/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/gym-fitness/tier5-src/himi-branded-lite-category/index.ts +196 -0
- package/templates/gym-fitness/tier5-src/himi-branded-lite-order/index.ts +29 -6
- package/templates/gym-fitness/tier5-src/himi-branded-lite-orders/index.ts +58 -5
- package/templates/gym-fitness/tier5-src/wix-spaces-collections/index.ts +37 -88
- package/templates/gym-fitness-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/gym-fitness-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/gym-fitness-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/nonprofit-cause/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/nonprofit-cause/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/nonprofit-cause/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/nonprofit-cause/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/nonprofit-cause/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/nonprofit-cause-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/nonprofit-cause-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/nonprofit-cause-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/owner-lite/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/owner-lite/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/owner-lite/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/podcast-creator/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/podcast-creator/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/podcast-creator/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/podcast-creator/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/podcast-creator/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/podcast-creator-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/podcast-creator-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/podcast-creator-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/portfolio-creative/dev/index.ts +5017 -4157
- package/templates/portfolio-creative/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/portfolio-creative/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/portfolio-creative/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/portfolio-creative/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/portfolio-creative/tier5-src/_shared/store-order-presentation.ts +56 -0
- package/templates/portfolio-creative/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/portfolio-creative/tier5-src/himi-branded-lite-category/index.ts +196 -0
- package/templates/portfolio-creative/tier5-src/himi-branded-lite-order/index.ts +29 -6
- package/templates/portfolio-creative/tier5-src/himi-branded-lite-orders/index.ts +58 -5
- package/templates/portfolio-creative/tier5-src/wix-spaces-collections/index.ts +37 -88
- package/templates/portfolio-creative-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/portfolio-creative-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/portfolio-creative-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/restaurant/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/restaurant/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/restaurant/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/restaurant/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/restaurant/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/restaurant-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/restaurant-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/restaurant-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/retail-store/dev/index.ts +5159 -4302
- package/templates/retail-store/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/retail-store/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/retail-store/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/retail-store/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/retail-store/tier5-src/_shared/store-order-presentation.ts +56 -0
- package/templates/retail-store/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/retail-store/tier5-src/himi-branded-lite-category/index.ts +196 -0
- package/templates/retail-store/tier5-src/himi-branded-lite-order/index.ts +29 -6
- package/templates/retail-store/tier5-src/himi-branded-lite-orders/index.ts +58 -5
- package/templates/retail-store/tier5-src/wix-spaces-collections/index.ts +37 -88
- package/templates/retail-store-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/retail-store-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/retail-store-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/yoga-studio/dev/index.ts +0 -3
- package/templates/yoga-studio/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/yoga-studio/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/yoga-studio/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/yoga-studio/tier5-src/_shared/himi-store-categories.ts +18 -12
- package/templates/yoga-studio/tier5-src/_shared/wix-service-price.ts +4 -2
- package/templates/yoga-studio-owner/tier5-src/_shared/collection-contract.ts +9 -3
- package/templates/yoga-studio-owner/tier5-src/_shared/collection-service.ts +6 -3
- package/templates/yoga-studio-owner/tier5-src/_shared/engine-intl.ts +5 -2
- package/templates/beauty-salon/tier5-src/wix-spaces-collection-detail/index.ts +0 -170
- package/templates/branded-lite/tier5-src/wix-spaces-collection-detail/index.ts +0 -170
- package/templates/gym-fitness/tier5-src/wix-spaces-collection-detail/index.ts +0 -170
- package/templates/portfolio-creative/tier5-src/wix-spaces-collection-detail/index.ts +0 -170
- package/templates/retail-store/tier5-src/wix-spaces-collection-detail/index.ts +0 -170
|
@@ -95,7 +95,10 @@ export function decorateCollection(name: string, def: { state: State; actions?:
|
|
|
95
95
|
if (sort === 'default' || sort === 'az' || sort === 'za') { prefs.sort = sort; changed = true; }
|
|
96
96
|
}
|
|
97
97
|
if (Object.prototype.hasOwnProperty.call(input, 'collectionFilter')) {
|
|
98
|
-
const
|
|
98
|
+
const requestedFilter = String(input.collectionFilter ?? '');
|
|
99
|
+
// Old links to Saved must migrate with the stored preference when this
|
|
100
|
+
// collection no longer exposes that filter.
|
|
101
|
+
const filter = config.rowStyle === 'flat' && requestedFilter === 'saved' ? 'all' : requestedFilter;
|
|
99
102
|
const configured = config.filterValues ?? [];
|
|
100
103
|
const rows = Array.isArray(state[config.rows]) ? state[config.rows] as CollectionRow[] : [];
|
|
101
104
|
const derived = config.filter ? rows.map(row => String(row[config.filter!] ?? '')).filter(Boolean) : [];
|
|
@@ -139,7 +142,7 @@ export function decorateCollection(name: string, def: { state: State; actions?:
|
|
|
139
142
|
copyParam('collection.itemActionsFor', 'Actions for {title}'), copyParam('collection.itemActions', 'Item actions'));
|
|
140
143
|
});
|
|
141
144
|
if (previewId && !rows.some(row => collectionId(row) === previewId)) previewId = '';
|
|
142
|
-
const filterChoices = [{ id: 'all', label: copyParam('collection.all', 'All') }, { id: 'saved', label: copyParam('collection.saved', 'Saved') },
|
|
145
|
+
const filterChoices = [{ id: 'all', label: copyParam('collection.all', 'All') }, ...(config.rowStyle === 'flat' ? [] : [{ id: 'saved', label: copyParam('collection.saved', 'Saved') }]),
|
|
143
146
|
...projected.filters.map(label => ({ id: `value:${label}`, label: copyParam(`collection.filter.${label}`, label) }))];
|
|
144
147
|
const loading = s.status === 'loading' || s.isLoading === true;
|
|
145
148
|
// Older domain reducers expose `errored` rather than `isErrored`; backend
|
|
@@ -220,7 +223,7 @@ export function decorateCollection(name: string, def: { state: State; actions?:
|
|
|
220
223
|
? [copyParam(`collection.${name}.countOne`, config.countNoun[0]), copyParam(`collection.${name}.countMany`, config.countNoun[1])] : undefined }),
|
|
221
224
|
selectedSummary: `${prefs.selectedIds.length} ${copyParam('collection.selected', 'selected')}`,
|
|
222
225
|
filterChoices,
|
|
223
|
-
chips: config.filterValues ? filterChoices.filter(choice => ['all', 'saved', prefs.filter].includes(choice.id)) : filterChoices,
|
|
226
|
+
chips: config.filterValues && config.rowStyle !== 'flat' ? filterChoices.filter(choice => ['all', 'saved', prefs.filter].includes(choice.id)) : filterChoices,
|
|
224
227
|
} };
|
|
225
228
|
};
|
|
226
229
|
const actions: Record<string, Reducer> = {};
|
|
@@ -410,8 +410,11 @@ export function compareDateDesc(a: string, b: string): number {
|
|
|
410
410
|
// kind of number. So: one money pattern, one clock, one range.
|
|
411
411
|
|
|
412
412
|
// Money uses `formatCurrency(amount, currency, "en")` — the currency's NATURAL decimals
|
|
413
|
-
// ("₪70.00", "¥500")
|
|
414
|
-
//
|
|
413
|
+
// ("₪70.00", "¥500") — for Shop, Menu and every other price. The one exception is a Bookings
|
|
414
|
+
// SERVICE price (`_shared/wix-service-price.ts`): it drops the cents of a whole amount ("₪70",
|
|
415
|
+
// "₪69.50"), the format the redesigned service screen and services list were approved with. It
|
|
416
|
+
// must read the same on every screen that shows a service (the list, the service screen, the
|
|
417
|
+
// time screen, Home, the agenda); do not put those back on natural decimals one screen at a time.
|
|
415
418
|
|
|
416
419
|
const KNOWN_SYMBOLS = new Set(Object.values(CURRENCY_SYMBOL));
|
|
417
420
|
|