@shoplix-ai/block-kit 5.0.0 → 5.16.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/README.md +92 -13
- package/dist/account-links.d.ts +50 -1
- package/dist/account-links.d.ts.map +1 -1
- package/dist/account-links.js +61 -1
- package/dist/account-links.js.map +1 -1
- package/dist/address-list.d.ts +9 -8
- package/dist/address-list.d.ts.map +1 -1
- package/dist/address-list.js +5 -5
- package/dist/address-list.js.map +1 -1
- package/dist/buy-box.d.ts +8 -0
- package/dist/buy-box.d.ts.map +1 -1
- package/dist/buy-box.js +8 -0
- package/dist/buy-box.js.map +1 -1
- package/dist/capabilities.d.ts +4 -1
- package/dist/capabilities.d.ts.map +1 -1
- package/dist/capabilities.js.map +1 -1
- package/dist/category-grid.d.ts +92 -0
- package/dist/category-grid.d.ts.map +1 -0
- package/dist/category-grid.js +123 -0
- package/dist/category-grid.js.map +1 -0
- package/dist/color-choice.d.ts +4 -0
- package/dist/color-choice.d.ts.map +1 -0
- package/dist/color-choice.js +11 -0
- package/dist/color-choice.js.map +1 -0
- package/dist/content-direction.d.ts +10 -0
- package/dist/content-direction.d.ts.map +1 -0
- package/dist/content-direction.js +20 -0
- package/dist/content-direction.js.map +1 -0
- package/dist/description.d.ts +60 -0
- package/dist/description.d.ts.map +1 -0
- package/dist/description.js +332 -0
- package/dist/description.js.map +1 -0
- package/dist/index.d.ts +23 -12
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +14 -8
- package/dist/index.js.map +1 -1
- package/dist/listing-filters.d.ts +114 -0
- package/dist/listing-filters.d.ts.map +1 -0
- package/dist/listing-filters.js +195 -0
- package/dist/listing-filters.js.map +1 -0
- package/dist/listing-toolbar.d.ts +117 -0
- package/dist/listing-toolbar.d.ts.map +1 -0
- package/dist/listing-toolbar.js +130 -0
- package/dist/listing-toolbar.js.map +1 -0
- package/dist/money.d.ts +7 -0
- package/dist/money.d.ts.map +1 -1
- package/dist/money.js +15 -0
- package/dist/money.js.map +1 -1
- package/dist/navigation.d.ts +7 -5
- package/dist/navigation.d.ts.map +1 -1
- package/dist/orders.d.ts +87 -9
- package/dist/orders.d.ts.map +1 -1
- package/dist/orders.js +127 -13
- package/dist/orders.js.map +1 -1
- package/dist/product-card.d.ts +4 -0
- package/dist/product-card.d.ts.map +1 -1
- package/dist/product-card.js +4 -0
- package/dist/product-card.js.map +1 -1
- package/dist/product-gallery.d.ts +3 -0
- package/dist/product-gallery.d.ts.map +1 -1
- package/dist/product-gallery.js +3 -0
- package/dist/product-gallery.js.map +1 -1
- package/dist/product-specs.d.ts +33 -2
- package/dist/product-specs.d.ts.map +1 -1
- package/dist/product-specs.js +51 -2
- package/dist/product-specs.js.map +1 -1
- package/dist/product-summary.d.ts +12 -1
- package/dist/product-summary.d.ts.map +1 -1
- package/dist/product-summary.js +29 -0
- package/dist/product-summary.js.map +1 -1
- package/dist/profile-header.d.ts +8 -1
- package/dist/profile-header.d.ts.map +1 -1
- package/dist/profile-header.js +8 -1
- package/dist/profile-header.js.map +1 -1
- package/dist/sign-in.d.ts +3 -0
- package/dist/sign-in.d.ts.map +1 -1
- package/dist/sign-in.js +3 -0
- package/dist/sign-in.js.map +1 -1
- package/dist/store-header.d.ts +49 -6
- package/dist/store-header.d.ts.map +1 -1
- package/dist/store-header.js +59 -5
- package/dist/store-header.js.map +1 -1
- package/dist/variant-choice.d.ts +14 -0
- package/dist/variant-choice.d.ts.map +1 -1
- package/dist/variant-choice.js +36 -0
- package/dist/variant-choice.js.map +1 -1
- package/dist/variant-rows.d.ts +33 -0
- package/dist/variant-rows.d.ts.map +1 -0
- package/dist/variant-rows.js +52 -0
- package/dist/variant-rows.js.map +1 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.d.ts.map +1 -1
- package/dist/version.js +1 -1
- package/dist/version.js.map +1 -1
- package/dist/words.d.ts +67 -2
- package/dist/words.d.ts.map +1 -1
- package/dist/words.js +180 -1
- package/dist/words.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -17,14 +17,25 @@ export { productCardColors } from './product-card.js';
|
|
|
17
17
|
export type { ProductCardColors, ProductCardPart } from './product-card.js';
|
|
18
18
|
export { productGalleryColors } from './product-gallery.js';
|
|
19
19
|
export type { ProductGalleryColors, ProductGalleryPart } from './product-gallery.js';
|
|
20
|
-
export { productSpecsColors } from './product-specs.js';
|
|
21
|
-
export type { ProductSpecsColors, ProductSpecsPart } from './product-specs.js';
|
|
22
|
-
export {
|
|
20
|
+
export { PRODUCT_SECTION_TITLES, productSectionTitle, productSpecRows, productSpecsColors, shippingRowsOf, } from './product-specs.js';
|
|
21
|
+
export type { ProductSpecRow, ProductSpecsColors, ProductSpecsPart, ShippingRow, } from './product-specs.js';
|
|
22
|
+
export { contentDirection } from './content-direction.js';
|
|
23
|
+
export { descriptionFacts, descriptionParts, descriptionPartsOf, descriptionText, shownDescriptionParts, } from './description.js';
|
|
24
|
+
export type { DescriptionFact, DescriptionPart, DescriptionRun } from './description.js';
|
|
25
|
+
export { chosenPrice, variantLabel, variantRows } from './variant-rows.js';
|
|
26
|
+
export type { ChosenPrice, VariantRow } from './variant-rows.js';
|
|
27
|
+
export { productSummaryColors, savingText } from './product-summary.js';
|
|
23
28
|
export type { ProductSummaryColors, ProductSummaryPart } from './product-summary.js';
|
|
24
29
|
export { reviewsSlotColors } from './reviews-slot.js';
|
|
25
30
|
export type { ReviewsSlotColors, ReviewsSlotPart } from './reviews-slot.js';
|
|
26
31
|
export { collectionTileColors } from './collection-tile.js';
|
|
32
|
+
export { categoryGridColors, categoryGridLook, categoryGridRow, categoryTileOf, categoryTileWidth, } from './category-grid.js';
|
|
33
|
+
export type { CategoryGridColors, CategoryGridLook, CategoryGridPart, CategoryGridRow, CategoryTileArt, CategoryTileContent, } from './category-grid.js';
|
|
27
34
|
export type { CollectionTileColors, CollectionTilePart } from './collection-tile.js';
|
|
35
|
+
export { PRODUCT_ROW_LOOK, listingCount, listingSortLabel, listingSortRows, listingToolbarColors, listingToolbarLook, } from './listing-toolbar.js';
|
|
36
|
+
export type { ListingCount, ListingSortRow, ListingToolbarColors, ListingToolbarLook, ListingToolbarPart, } from './listing-toolbar.js';
|
|
37
|
+
export { PRICE_RANGE_VALUE, activeFilterKey, activeFilterOf, activePriceFilter, listingFilterRows, listingFilterShown, listingFilterWords, listingFilterWordsApply, priceBoundsOf, typedPrice, } from './listing-filters.js';
|
|
38
|
+
export type { ActiveListingFilter, ListingFilterRow, ListingFilterWords, } from './listing-filters.js';
|
|
28
39
|
export { cartLinesColors, compareAtUnit } from './cart-lines.js';
|
|
29
40
|
export type { CartLinesColors, CartLinesPart } from './cart-lines.js';
|
|
30
41
|
export { cartEmptyColors } from './cart-empty.js';
|
|
@@ -43,22 +54,22 @@ export { sectionHeaderColors } from './section-header.js';
|
|
|
43
54
|
export { featureStripColors } from './feature-strip.js';
|
|
44
55
|
export { brandRailColors } from './brand-rail.js';
|
|
45
56
|
export { BUY_QUANTITY_CEILING, buyBoxColors, productChoices, swatchColor } from './buy-box.js';
|
|
46
|
-
export { defaultSelections, effectiveSelections, selectedVariant, valueAvailable, } from './variant-choice.js';
|
|
57
|
+
export { choicesAfterPick, defaultSelections, effectiveSelections, selectedVariant, valueAvailable, valuesAfterEarlierChoices, } from './variant-choice.js';
|
|
47
58
|
export type { OptionSelections } from './variant-choice.js';
|
|
48
59
|
export { announcementBarColors } from './announcement-bar.js';
|
|
49
60
|
export { aroundAmount, shippingProgress, shippingProgressColors } from './shipping-progress.js';
|
|
50
|
-
export { cartBadgeCount, storeHeaderColors } from './store-header.js';
|
|
51
|
-
export type { StoreHeaderColors, StoreHeaderPart } from './store-header.js';
|
|
61
|
+
export { cartBadgeCount, searchBarWords, searchEntryBox, searchEntryWords, STORE_MENU_DIM, storeHeaderColors, storeMenuMetrics, } from './store-header.js';
|
|
62
|
+
export type { SearchEntryBox, SearchEntryWords, StoreHeaderColors, StoreHeaderPart, StoreMenuMetrics, } from './store-header.js';
|
|
52
63
|
export { signInColors } from './sign-in.js';
|
|
53
64
|
export type { SignInColors, SignInPart } from './sign-in.js';
|
|
54
65
|
export { customerInitials, profileHeaderColors } from './profile-header.js';
|
|
55
66
|
export type { ProfileHeaderColors, ProfileHeaderPart } from './profile-header.js';
|
|
56
|
-
export { accountLinkRows, accountLinksColors, accountLinksRadius } from './account-links.js';
|
|
57
|
-
export type { AccountLinkRows, AccountLinksColors, AccountLinksPart, NamedAccountLink, } from './account-links.js';
|
|
67
|
+
export { accountLinkRows, accountLinksCard, accountLinksColors, accountLinksLayout, accountLinksRadius, } from './account-links.js';
|
|
68
|
+
export type { AccountLinkRows, AccountLinkSection, AccountLinkShape, AccountLinksCard, AccountLinksColors, AccountLinksLayout, AccountLinksPart, DestructiveAccountLink, NamedAccountLink, } from './account-links.js';
|
|
58
69
|
export { addressCardOf, addressControlsOf, addressListColors, addressListRadius, } from './address-list.js';
|
|
59
70
|
export type { AddressCard, AddressControls, AddressListColors, AddressListPart, } from './address-list.js';
|
|
60
|
-
export { SHIPMENT_STEPS, fulfillmentEventWord, fulfillmentPillOf, orderColors, orderDay, orderMoneyRows, orderPillColors, orderRadius, orderTime, paymentPillOf, shipmentStepReached, shipmentWord, } from './orders.js';
|
|
61
|
-
export type { OrderColors, OrderMoneyRow, OrderPart, OrderPill, OrderPillColors, OrderPillTone, ShipmentStep, } from './orders.js';
|
|
71
|
+
export { SHIPMENT_STEPS, fulfillmentEventWord, fulfillmentPillOf, orderColors, orderDay, orderHasShipments, orderItemsOf, orderLineCard, orderListCards, orderMoneyRows, orderPillColors, orderRadius, orderStatusColors, orderSummaryBox, orderTime, paymentPillOf, shipmentStepReached, shipmentWord, } from './orders.js';
|
|
72
|
+
export type { OrderColors, OrderItems, OrderLineCard, OrderListCards, OrderMoneyRow, OrderPart, OrderPill, OrderPillColors, OrderPillTone, OrderRowCard, OrderSummaryBox, ShipmentStep, } from './orders.js';
|
|
62
73
|
export { readableInk } from './readable.js';
|
|
63
74
|
export type { SectionHeaderColors, SectionHeaderPart } from './section-header.js';
|
|
64
75
|
export type { FeatureStripColors, FeatureStripPart } from './feature-strip.js';
|
|
@@ -66,12 +77,12 @@ export type { BrandRailColors, BrandRailPart } from './brand-rail.js';
|
|
|
66
77
|
export type { BuyBoxColors, BuyBoxPart } from './buy-box.js';
|
|
67
78
|
export type { AnnouncementBarColors, AnnouncementBarPart } from './announcement-bar.js';
|
|
68
79
|
export type { ShippingProgress, ShippingProgressColors, ShippingProgressPart, } from './shipping-progress.js';
|
|
69
|
-
export { derivedMoney, derivedPrice, discountPercent, formatMoney, moneyAmount, moneyParts, moneyText, } from './money.js';
|
|
80
|
+
export { compareAtParts, derivedMoney, derivedPrice, discountPercent, formatMoney, moneyAmount, moneyParts, moneyText, } from './money.js';
|
|
70
81
|
export type { MoneyParts } from './money.js';
|
|
71
82
|
export { imageSourceFor } from './renditions.js';
|
|
72
83
|
export type { ImageSource } from './renditions.js';
|
|
73
84
|
export { localize, pickLocale, textDirection } from './locale.js';
|
|
74
85
|
export type { ShopLanguages } from './locale.js';
|
|
75
|
-
export { CATALOG_LANGUAGES, DELETION_FACTS, WORD_KEYS, cartItemCount, platformWords, } from './words.js';
|
|
86
|
+
export { CATALOG_LANGUAGES, DELETION_FACTS, WORD_KEYS, cartItemCount, orderItemCount, orderSubtotalLabel, platformWords, } from './words.js';
|
|
76
87
|
export type { PlatformWords, WordKey } from './words.js';
|
|
77
88
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7F,YAAY,EACV,YAAY,EACZ,kBAAkB,EAClB,YAAY,EACZ,cAAc,EACd,gBAAgB,EAChB,iBAAiB,EACjB,uBAAuB,EACvB,aAAa,EACb,qBA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,MAAM,cAAc,CAAC;AAC7D,YAAY,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AACxF,YAAY,EACV,gBAAgB,EAChB,sBAAsB,EACtB,oBAAoB,GACrB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,cAAc,EACd,YAAY,EACZ,YAAY,EACZ,eAAe,EACf,WAAW,EACX,WAAW,EACX,UAAU,EACV,SAAS,GACV,MAAM,YAAY,CAAC;AACpB,YAAY,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACjD,YAAY,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAClE,YAAY,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EACL,iBAAiB,EACjB,cAAc,EACd,SAAS,EACT,aAAa,EACb,cAAc,EACd,kBAAkB,EAClB,aAAa,GACd,MAAM,YAAY,CAAC;AACpB,YAAY,EAAE,aAAa,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -8,10 +8,16 @@ export { resolveToken } from './tokens.js';
|
|
|
8
8
|
export { addToCartColors } from './add-to-cart.js';
|
|
9
9
|
export { productCardColors } from './product-card.js';
|
|
10
10
|
export { productGalleryColors } from './product-gallery.js';
|
|
11
|
-
export { productSpecsColors } from './product-specs.js';
|
|
12
|
-
export {
|
|
11
|
+
export { PRODUCT_SECTION_TITLES, productSectionTitle, productSpecRows, productSpecsColors, shippingRowsOf, } from './product-specs.js';
|
|
12
|
+
export { contentDirection } from './content-direction.js';
|
|
13
|
+
export { descriptionFacts, descriptionParts, descriptionPartsOf, descriptionText, shownDescriptionParts, } from './description.js';
|
|
14
|
+
export { chosenPrice, variantLabel, variantRows } from './variant-rows.js';
|
|
15
|
+
export { productSummaryColors, savingText } from './product-summary.js';
|
|
13
16
|
export { reviewsSlotColors } from './reviews-slot.js';
|
|
14
17
|
export { collectionTileColors } from './collection-tile.js';
|
|
18
|
+
export { categoryGridColors, categoryGridLook, categoryGridRow, categoryTileOf, categoryTileWidth, } from './category-grid.js';
|
|
19
|
+
export { PRODUCT_ROW_LOOK, listingCount, listingSortLabel, listingSortRows, listingToolbarColors, listingToolbarLook, } from './listing-toolbar.js';
|
|
20
|
+
export { PRICE_RANGE_VALUE, activeFilterKey, activeFilterOf, activePriceFilter, listingFilterRows, listingFilterShown, listingFilterWords, listingFilterWordsApply, priceBoundsOf, typedPrice, } from './listing-filters.js';
|
|
15
21
|
export { cartLinesColors, compareAtUnit } from './cart-lines.js';
|
|
16
22
|
export { cartEmptyColors } from './cart-empty.js';
|
|
17
23
|
export { cartDiscountCodeColors } from './cart-discount-code.js';
|
|
@@ -23,18 +29,18 @@ export { sectionHeaderColors } from './section-header.js';
|
|
|
23
29
|
export { featureStripColors } from './feature-strip.js';
|
|
24
30
|
export { brandRailColors } from './brand-rail.js';
|
|
25
31
|
export { BUY_QUANTITY_CEILING, buyBoxColors, productChoices, swatchColor } from './buy-box.js';
|
|
26
|
-
export { defaultSelections, effectiveSelections, selectedVariant, valueAvailable, } from './variant-choice.js';
|
|
32
|
+
export { choicesAfterPick, defaultSelections, effectiveSelections, selectedVariant, valueAvailable, valuesAfterEarlierChoices, } from './variant-choice.js';
|
|
27
33
|
export { announcementBarColors } from './announcement-bar.js';
|
|
28
34
|
export { aroundAmount, shippingProgress, shippingProgressColors } from './shipping-progress.js';
|
|
29
|
-
export { cartBadgeCount, storeHeaderColors } from './store-header.js';
|
|
35
|
+
export { cartBadgeCount, searchBarWords, searchEntryBox, searchEntryWords, STORE_MENU_DIM, storeHeaderColors, storeMenuMetrics, } from './store-header.js';
|
|
30
36
|
export { signInColors } from './sign-in.js';
|
|
31
37
|
export { customerInitials, profileHeaderColors } from './profile-header.js';
|
|
32
|
-
export { accountLinkRows, accountLinksColors, accountLinksRadius } from './account-links.js';
|
|
38
|
+
export { accountLinkRows, accountLinksCard, accountLinksColors, accountLinksLayout, accountLinksRadius, } from './account-links.js';
|
|
33
39
|
export { addressCardOf, addressControlsOf, addressListColors, addressListRadius, } from './address-list.js';
|
|
34
|
-
export { SHIPMENT_STEPS, fulfillmentEventWord, fulfillmentPillOf, orderColors, orderDay, orderMoneyRows, orderPillColors, orderRadius, orderTime, paymentPillOf, shipmentStepReached, shipmentWord, } from './orders.js';
|
|
40
|
+
export { SHIPMENT_STEPS, fulfillmentEventWord, fulfillmentPillOf, orderColors, orderDay, orderHasShipments, orderItemsOf, orderLineCard, orderListCards, orderMoneyRows, orderPillColors, orderRadius, orderStatusColors, orderSummaryBox, orderTime, paymentPillOf, shipmentStepReached, shipmentWord, } from './orders.js';
|
|
35
41
|
export { readableInk } from './readable.js';
|
|
36
|
-
export { derivedMoney, derivedPrice, discountPercent, formatMoney, moneyAmount, moneyParts, moneyText, } from './money.js';
|
|
42
|
+
export { compareAtParts, derivedMoney, derivedPrice, discountPercent, formatMoney, moneyAmount, moneyParts, moneyText, } from './money.js';
|
|
37
43
|
export { imageSourceFor } from './renditions.js';
|
|
38
44
|
export { localize, pickLocale, textDirection } from './locale.js';
|
|
39
|
-
export { CATALOG_LANGUAGES, DELETION_FACTS, WORD_KEYS, cartItemCount, platformWords, } from './words.js';
|
|
45
|
+
export { CATALOG_LANGUAGES, DELETION_FACTS, WORD_KEYS, cartItemCount, orderItemCount, orderSubtotalLabel, platformWords, } from './words.js';
|
|
40
46
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAgB7F,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAkB5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AC;AAerB,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAW5C,OAAO,EACL,cAAc,EACd,YAAY,EACZ,YAAY,EACZ,eAAe,EACf,WAAW,EACX,WAAW,EACX,UAAU,EACV,SAAS,GACV,MAAM,YAAY,CAAC;AAEpB,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAEjD,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAElE,OAAO,EACL,iBAAiB,EACjB,cAAc,EACd,SAAS,EACT,aAAa,EACb,cAAc,EACd,kBAAkB,EAClB,aAAa,GACd,MAAM,YAAY,CAAC"}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import { type ListingFilterDisplay, type ListingFilterKind, type ListingFilterValueDisplay, type ListingToolbarBlock, type LocaleCode } from '@shoplix-ai/sdui-schema';
|
|
2
|
+
type ListingToolbarSettings = ListingToolbarBlock['props'];
|
|
3
|
+
interface RowBase {
|
|
4
|
+
readonly filterId: string;
|
|
5
|
+
readonly kind?: ListingFilterKind;
|
|
6
|
+
readonly label: string;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* One row of the filter sheet, in the shape the shopper answers it with: a
|
|
10
|
+
* switch for a filter Shopify answers with a yes, the stock for one, with the
|
|
11
|
+
* line under its words; the values of a list, each with its count and its
|
|
12
|
+
* swatch or picture; or a price range between the bounds Shopify offers.
|
|
13
|
+
*/
|
|
14
|
+
export type ListingFilterRow = (RowBase & {
|
|
15
|
+
readonly shape: 'switch';
|
|
16
|
+
readonly hint?: string;
|
|
17
|
+
readonly value: ListingFilterValueDisplay;
|
|
18
|
+
}) | (RowBase & {
|
|
19
|
+
readonly shape: 'list';
|
|
20
|
+
readonly values: readonly ListingFilterValueDisplay[];
|
|
21
|
+
}) | (RowBase & {
|
|
22
|
+
readonly shape: 'range';
|
|
23
|
+
readonly min: number;
|
|
24
|
+
readonly max: number;
|
|
25
|
+
});
|
|
26
|
+
/** Whether the merchant's words for a kind title its filter: every kind but those that may hold several. */
|
|
27
|
+
export declare function listingFilterWordsApply(kind: ListingFilterKind): boolean;
|
|
28
|
+
/**
|
|
29
|
+
* The rows of the filter sheet out of the filters Shopify offers the
|
|
30
|
+
* collection, in the merchant's order (`listingFiltersOf`), each titled in the
|
|
31
|
+
* merchant's words where they wrote some the buyer reads and Shopify's
|
|
32
|
+
* otherwise. The stock is a switch that says "In stock only" over "Hide
|
|
33
|
+
* products that are sold out" from the catalog, or the merchant's words and
|
|
34
|
+
* line, and turns on Shopify's own in stock value.
|
|
35
|
+
*/
|
|
36
|
+
export declare function listingFilterRows(settings: ListingToolbarSettings, filters: readonly ListingFilterDisplay[], language: LocaleCode, defaultLanguage: LocaleCode): readonly ListingFilterRow[];
|
|
37
|
+
/**
|
|
38
|
+
* A filter the shopper turned on: the filter and the value it is, the product
|
|
39
|
+
* filter that goes to Shopify for it, and the words of the chip that names it
|
|
40
|
+
* under the toolbar. The chip keeps its words, so a filter stays named while
|
|
41
|
+
* the listing reads again.
|
|
42
|
+
*/
|
|
43
|
+
export interface ActiveListingFilter {
|
|
44
|
+
readonly filterId: string;
|
|
45
|
+
readonly valueId: string;
|
|
46
|
+
readonly input: string;
|
|
47
|
+
readonly label: string;
|
|
48
|
+
}
|
|
49
|
+
/** One filter on, as one key: two of them are the same filter where their keys are. */
|
|
50
|
+
export declare function activeFilterKey(filter: Pick<ActiveListingFilter, 'filterId' | 'valueId'>): string;
|
|
51
|
+
/**
|
|
52
|
+
* Whether a toolbar offers its filters, on the phone and on the canvas alike:
|
|
53
|
+
* the merchant left the button on, the listing reads a collection, and Shopify
|
|
54
|
+
* offers a filter the sheet would draw, has not answered yet, or the shopper
|
|
55
|
+
* has a filter on.
|
|
56
|
+
*/
|
|
57
|
+
export declare function listingFilterShown(settings: ListingToolbarSettings, listing: {
|
|
58
|
+
readonly filterable: boolean;
|
|
59
|
+
readonly filters: readonly ListingFilterDisplay[] | undefined;
|
|
60
|
+
readonly active: number;
|
|
61
|
+
}, language: LocaleCode, defaultLanguage: LocaleCode): boolean;
|
|
62
|
+
/** A switch or a value of a list turned on: Shopify's own input for the value, and the switch's words or the value's. */
|
|
63
|
+
export declare function activeFilterOf(row: Extract<ListingFilterRow, {
|
|
64
|
+
shape: 'switch' | 'list';
|
|
65
|
+
}>, value: ListingFilterValueDisplay): ActiveListingFilter;
|
|
66
|
+
/** The id a price range the shopper gave holds in place of a value's, Shopify offering one range and no values to pick. */
|
|
67
|
+
export declare const PRICE_RANGE_VALUE = "range";
|
|
68
|
+
/**
|
|
69
|
+
* A price the shopper typed, read as a number whatever keyboard wrote it: the
|
|
70
|
+
* digits the Arabic and the Persian keyboards write read as the ones Shopify
|
|
71
|
+
* takes, the Arabic decimal mark as the point, and the thousands marks dropped.
|
|
72
|
+
* Where a point and a comma both stand, the last is the decimal mark; a lone
|
|
73
|
+
* comma before three digits groups the thousands, so "1,000" is a thousand and
|
|
74
|
+
* "49,90" forty-nine and ninety; a lone point is the decimal mark. Nothing
|
|
75
|
+
* typed, or something that is no price, is no bound.
|
|
76
|
+
*/
|
|
77
|
+
export declare function typedPrice(typed: string): number | undefined;
|
|
78
|
+
/**
|
|
79
|
+
* A price range the shopper gave, as Shopify's price filter, the one filter
|
|
80
|
+
* whose input the app writes, since Shopify offers a range's bounds and no
|
|
81
|
+
* value to pick: the bounds they typed, low first. Its chip names the filter
|
|
82
|
+
* and both ends, a missing end being Shopify's own bound. No bound typed is no
|
|
83
|
+
* filter.
|
|
84
|
+
*/
|
|
85
|
+
export declare function activePriceFilter(row: Extract<ListingFilterRow, {
|
|
86
|
+
shape: 'range';
|
|
87
|
+
}>, low: number | undefined, high: number | undefined): ActiveListingFilter | undefined;
|
|
88
|
+
/** The bounds of a price range the shopper gave, read back off its filter, to stand in the sheet's fields again. */
|
|
89
|
+
export declare function priceBoundsOf(active: ActiveListingFilter): {
|
|
90
|
+
readonly min?: number;
|
|
91
|
+
readonly max?: number;
|
|
92
|
+
};
|
|
93
|
+
/** Every word of the filter button, the sheet and the chips. */
|
|
94
|
+
export interface ListingFilterWords {
|
|
95
|
+
readonly button: string;
|
|
96
|
+
readonly title: string;
|
|
97
|
+
readonly apply: string;
|
|
98
|
+
readonly clear: string;
|
|
99
|
+
readonly clearAll: string;
|
|
100
|
+
readonly remove: string;
|
|
101
|
+
readonly none: string;
|
|
102
|
+
readonly min: string;
|
|
103
|
+
readonly max: string;
|
|
104
|
+
/** How a screen reader names the button with this many filters on. */
|
|
105
|
+
on(count: number): string;
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* The words of the filters: the merchant's for the button, the sheet's title,
|
|
109
|
+
* its two buttons and "clear all" where they wrote some the buyer reads, and
|
|
110
|
+
* the catalog's `listing.filter*` otherwise.
|
|
111
|
+
*/
|
|
112
|
+
export declare function listingFilterWords(settings: ListingToolbarSettings, language: LocaleCode, defaultLanguage: LocaleCode): ListingFilterWords;
|
|
113
|
+
export {};
|
|
114
|
+
//# sourceMappingURL=listing-filters.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"listing-filters.d.ts","sourceRoot":"","sources":["../src/listing-filters.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,EACtB,KAAK,yBAAyB,EAC9B,KAAK,mBAAmB,EACxB,KAAK,UAAU,EAEhB,MAAM,yBAAyB,CAAC;AAIjC,KAAK,sBAAsB,GAAG,mBAAmB,CAAC,OAAO,CAAC,CAAC;AAE3D,UAAU,OAAO;IACf,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,IAAI,CAAC,EAAE,iBAAiB,CAAC;IAClC,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;CACxB;AAED;;;;;GAKG;AACH,MAAM,MAAM,gBAAgB,GACxB,CAAC,OAAO,GAAG;IACT,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC;IACzB,QAAQ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E,MAAM,CAAC;IACrB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,sEAAsE;IACtE,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAAC;CAC3B;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,sBAAsB,EAChC,QAAQ,EAAE,UAAU,EACpB,eAAe,EAAE,UAAU,GAC1B,kBAAkB,CAcpB"}
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { LISTING_TOOLBAR_DEFAULTS, listingFiltersOf, } from '@shoplix-ai/sdui-schema';
|
|
2
|
+
import { readable } from './locale.js';
|
|
3
|
+
import { platformWords } from './words.js';
|
|
4
|
+
function wordOf(text, language, defaultLanguage) {
|
|
5
|
+
return text === undefined ? undefined : readable(text, language, defaultLanguage);
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* The kinds that may hold several filters of Shopify's, a size and a colour
|
|
9
|
+
* for one: each is titled in the words the merchant gave it in Search &
|
|
10
|
+
* Discovery, since one word of theirs could not name both.
|
|
11
|
+
*/
|
|
12
|
+
const SEVERAL_FILTER_KINDS = new Set([
|
|
13
|
+
'variant_option',
|
|
14
|
+
'metafield',
|
|
15
|
+
]);
|
|
16
|
+
/** Whether the merchant's words for a kind title its filter: every kind but those that may hold several. */
|
|
17
|
+
export function listingFilterWordsApply(kind) {
|
|
18
|
+
return !SEVERAL_FILTER_KINDS.has(kind);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* The rows of the filter sheet out of the filters Shopify offers the
|
|
22
|
+
* collection, in the merchant's order (`listingFiltersOf`), each titled in the
|
|
23
|
+
* merchant's words where they wrote some the buyer reads and Shopify's
|
|
24
|
+
* otherwise. The stock is a switch that says "In stock only" over "Hide
|
|
25
|
+
* products that are sold out" from the catalog, or the merchant's words and
|
|
26
|
+
* line, and turns on Shopify's own in stock value.
|
|
27
|
+
*/
|
|
28
|
+
export function listingFilterRows(settings, filters, language, defaultLanguage) {
|
|
29
|
+
const words = platformWords(language, defaultLanguage);
|
|
30
|
+
return listingFiltersOf(settings, filters).flatMap(({ filter, choice }) => {
|
|
31
|
+
const worded = filter.kind !== undefined && listingFilterWordsApply(filter.kind);
|
|
32
|
+
const own = worded ? wordOf(choice?.label, language, defaultLanguage) : undefined;
|
|
33
|
+
const stock = filter.kind === 'availability';
|
|
34
|
+
const base = {
|
|
35
|
+
filterId: filter.id,
|
|
36
|
+
...(filter.kind === undefined ? {} : { kind: filter.kind }),
|
|
37
|
+
};
|
|
38
|
+
const yes = filter.values.find((value) => value.id === filter.yes);
|
|
39
|
+
if (yes !== undefined) {
|
|
40
|
+
const hint = stock
|
|
41
|
+
? (wordOf(choice?.hint, language, defaultLanguage) ??
|
|
42
|
+
words.own('listing.filter_in_stock_hint'))
|
|
43
|
+
: undefined;
|
|
44
|
+
return [
|
|
45
|
+
{
|
|
46
|
+
...base,
|
|
47
|
+
shape: 'switch',
|
|
48
|
+
label: own ?? (stock ? words.own('listing.filter_in_stock') : filter.label),
|
|
49
|
+
...(hint === undefined ? {} : { hint }),
|
|
50
|
+
value: yes,
|
|
51
|
+
},
|
|
52
|
+
];
|
|
53
|
+
}
|
|
54
|
+
if (filter.shape === 'price_range') {
|
|
55
|
+
if (filter.range === undefined)
|
|
56
|
+
return [];
|
|
57
|
+
return [
|
|
58
|
+
{
|
|
59
|
+
...base,
|
|
60
|
+
shape: 'range',
|
|
61
|
+
label: own ?? filter.label,
|
|
62
|
+
min: filter.range.min,
|
|
63
|
+
max: filter.range.max,
|
|
64
|
+
},
|
|
65
|
+
];
|
|
66
|
+
}
|
|
67
|
+
if (filter.values.length === 0)
|
|
68
|
+
return [];
|
|
69
|
+
return [{ ...base, shape: 'list', label: own ?? filter.label, values: filter.values }];
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
/** One filter on, as one key: two of them are the same filter where their keys are. */
|
|
73
|
+
export function activeFilterKey(filter) {
|
|
74
|
+
return `${filter.filterId}:${filter.valueId}`;
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Whether a toolbar offers its filters, on the phone and on the canvas alike:
|
|
78
|
+
* the merchant left the button on, the listing reads a collection, and Shopify
|
|
79
|
+
* offers a filter the sheet would draw, has not answered yet, or the shopper
|
|
80
|
+
* has a filter on.
|
|
81
|
+
*/
|
|
82
|
+
export function listingFilterShown(settings, listing, language, defaultLanguage) {
|
|
83
|
+
if (!(settings.filter ?? LISTING_TOOLBAR_DEFAULTS.filter) || !listing.filterable)
|
|
84
|
+
return false;
|
|
85
|
+
if (listing.filters === undefined || listing.active > 0)
|
|
86
|
+
return true;
|
|
87
|
+
return listingFilterRows(settings, listing.filters, language, defaultLanguage).length > 0;
|
|
88
|
+
}
|
|
89
|
+
/** A switch or a value of a list turned on: Shopify's own input for the value, and the switch's words or the value's. */
|
|
90
|
+
export function activeFilterOf(row, value) {
|
|
91
|
+
return {
|
|
92
|
+
filterId: row.filterId,
|
|
93
|
+
valueId: value.id,
|
|
94
|
+
input: value.input,
|
|
95
|
+
label: row.shape === 'switch' ? row.label : value.label,
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
/** The id a price range the shopper gave holds in place of a value's, Shopify offering one range and no values to pick. */
|
|
99
|
+
export const PRICE_RANGE_VALUE = 'range';
|
|
100
|
+
const DIGIT_SETS = ['٠١٢٣٤٥٦٧٨٩', '۰۱۲۳۴۵۶۷۸۹'];
|
|
101
|
+
/**
|
|
102
|
+
* A price the shopper typed, read as a number whatever keyboard wrote it: the
|
|
103
|
+
* digits the Arabic and the Persian keyboards write read as the ones Shopify
|
|
104
|
+
* takes, the Arabic decimal mark as the point, and the thousands marks dropped.
|
|
105
|
+
* Where a point and a comma both stand, the last is the decimal mark; a lone
|
|
106
|
+
* comma before three digits groups the thousands, so "1,000" is a thousand and
|
|
107
|
+
* "49,90" forty-nine and ninety; a lone point is the decimal mark. Nothing
|
|
108
|
+
* typed, or something that is no price, is no bound.
|
|
109
|
+
*/
|
|
110
|
+
export function typedPrice(typed) {
|
|
111
|
+
let text = typed
|
|
112
|
+
.trim()
|
|
113
|
+
.replace(/[\s٬']/g, '')
|
|
114
|
+
.replace(/٫/g, '.');
|
|
115
|
+
for (const set of DIGIT_SETS) {
|
|
116
|
+
text = text.replace(/[٠-٩۰-۹]/g, (digit) => {
|
|
117
|
+
const at = set.indexOf(digit);
|
|
118
|
+
return at === -1 ? digit : String(at);
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
const marks = [...text.matchAll(/[.,]/g)].map((match) => match.index);
|
|
122
|
+
const last = marks[marks.length - 1];
|
|
123
|
+
let decimal;
|
|
124
|
+
if (last !== undefined && new Set(marks.map((at) => text[at])).size === 2)
|
|
125
|
+
decimal = last;
|
|
126
|
+
else if (last !== undefined && marks.length === 1) {
|
|
127
|
+
decimal = text[last] === '.' || text.length - last - 1 !== 3 ? last : undefined;
|
|
128
|
+
}
|
|
129
|
+
const whole = decimal === undefined ? text : text.slice(0, decimal);
|
|
130
|
+
const fraction = decimal === undefined ? undefined : text.slice(decimal + 1);
|
|
131
|
+
const groups = whole.split(/[.,]/);
|
|
132
|
+
if (groups.slice(1).some((group) => group.length !== 3))
|
|
133
|
+
return undefined;
|
|
134
|
+
const latin = groups.join('') + (fraction === undefined ? '' : `.${fraction}`);
|
|
135
|
+
if (!/^\d+(\.\d+)?$/.test(latin))
|
|
136
|
+
return undefined;
|
|
137
|
+
const amount = Number(latin);
|
|
138
|
+
return Number.isFinite(amount) ? amount : undefined;
|
|
139
|
+
}
|
|
140
|
+
function priceWord(amount) {
|
|
141
|
+
return String(Math.round(amount * 100) / 100);
|
|
142
|
+
}
|
|
143
|
+
/**
|
|
144
|
+
* A price range the shopper gave, as Shopify's price filter, the one filter
|
|
145
|
+
* whose input the app writes, since Shopify offers a range's bounds and no
|
|
146
|
+
* value to pick: the bounds they typed, low first. Its chip names the filter
|
|
147
|
+
* and both ends, a missing end being Shopify's own bound. No bound typed is no
|
|
148
|
+
* filter.
|
|
149
|
+
*/
|
|
150
|
+
export function activePriceFilter(row, low, high) {
|
|
151
|
+
if (low === undefined && high === undefined)
|
|
152
|
+
return undefined;
|
|
153
|
+
const [min, max] = low !== undefined && high !== undefined && low > high ? [high, low] : [low, high];
|
|
154
|
+
const price = { ...(min === undefined ? {} : { min }), ...(max === undefined ? {} : { max }) };
|
|
155
|
+
return {
|
|
156
|
+
filterId: row.filterId,
|
|
157
|
+
valueId: PRICE_RANGE_VALUE,
|
|
158
|
+
input: JSON.stringify({ price }),
|
|
159
|
+
label: `${row.label}: ${priceWord(min ?? row.min)} – ${priceWord(max ?? row.max)}`,
|
|
160
|
+
};
|
|
161
|
+
}
|
|
162
|
+
/** The bounds of a price range the shopper gave, read back off its filter, to stand in the sheet's fields again. */
|
|
163
|
+
export function priceBoundsOf(active) {
|
|
164
|
+
try {
|
|
165
|
+
const price = JSON.parse(active.input).price;
|
|
166
|
+
return {
|
|
167
|
+
...(typeof price?.min === 'number' ? { min: price.min } : {}),
|
|
168
|
+
...(typeof price?.max === 'number' ? { max: price.max } : {}),
|
|
169
|
+
};
|
|
170
|
+
}
|
|
171
|
+
catch {
|
|
172
|
+
return {};
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* The words of the filters: the merchant's for the button, the sheet's title,
|
|
177
|
+
* its two buttons and "clear all" where they wrote some the buyer reads, and
|
|
178
|
+
* the catalog's `listing.filter*` otherwise.
|
|
179
|
+
*/
|
|
180
|
+
export function listingFilterWords(settings, language, defaultLanguage) {
|
|
181
|
+
const words = platformWords(language, defaultLanguage);
|
|
182
|
+
return {
|
|
183
|
+
button: words.merchantOr(settings.filterButton, 'listing.filter'),
|
|
184
|
+
title: words.merchantOr(settings.filterTitle, 'listing.filter_title'),
|
|
185
|
+
apply: words.merchantOr(settings.filterApply, 'listing.filter_apply'),
|
|
186
|
+
clear: words.merchantOr(settings.filterClear, 'listing.filter_clear'),
|
|
187
|
+
clearAll: words.merchantOr(settings.filterClearAll, 'listing.filter_clear_all'),
|
|
188
|
+
remove: words.own('listing.filter_remove'),
|
|
189
|
+
none: words.own('listing.filter_none'),
|
|
190
|
+
min: words.own('listing.filter_min'),
|
|
191
|
+
max: words.own('listing.filter_max'),
|
|
192
|
+
on: (count) => words.own('listing.filter_on').replace('{count}', String(count)),
|
|
193
|
+
};
|
|
194
|
+
}
|
|
195
|
+
//# sourceMappingURL=listing-filters.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"listing-filters.js","sourceRoot":"","sources":["../src/listing-filters.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,gBAAgB,GAOjB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAyB3C,SAAS,MAAM,CACb,IAA+B,EAC/B,QAAoB,EACpB,eAA2B;IAE3B,OAAO,IAAI,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,EAAE,QAAQ,EAAE,eAAe,CAAC,CAAC;AACpF,CAAC;AAED;;;;GAIG;AACH,MAAM,oBAAoB,GAAmC,IAAI,GAAG,CAAC;IACnE,gBAAgB;IAChB,WAAW;CACZ,CAAC,CAAC;AAEH,4GAA4G;AAC5G,MAAM,UAAU,uBAAuB,CAAC,IAAuB;IAC7D,OAAO,CAAC,oBAAoB,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;AACzC,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,iBAAiB,CAC/B,QAAgC,EAChC,OAAwC,EACxC,QAAoB,EACpB,eAA2B;IAE3B,MAAM,KAAK,GAAG,aAAa,CAAC,QAAQ,EAAE,eAAe,CAAC,CAAC;IACvD,OAAO,gBAAgB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,OAAO,CAAC,CAAC,EAAE,MAAM,EAAE,MAAM,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AAuB,CAAC;QAC1C,IAAI,EAAE,KAAK,CAAC,GAAG,CAAC,qBAAqB,CAAC;QACtC,GAAG,EAAE,KAAK,CAAC,GAAG,CAAC,oBAAoB,CAAC;QACpC,GAAG,EAAE,KAAK,CAAC,GAAG,CAAC,oBAAoB,CAAC;QACpC,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,mBAAmB,CAAC,CAAC,OAAO,CAAC,SAAS,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC;KAChF,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
import { type ListingSortKey, type ListingToolbarBlock, type LocaleCode, type ThemeStyle } from '@shoplix-ai/sdui-schema';
|
|
2
|
+
type ListingToolbarSettings = ListingToolbarBlock['props'];
|
|
3
|
+
/** The parts of the listing toolbar, each with the theme role it draws unless a component token names another. */
|
|
4
|
+
declare const LISTING_TOOLBAR_ROLES: {
|
|
5
|
+
readonly count: "text";
|
|
6
|
+
readonly count_word: "muted";
|
|
7
|
+
readonly bar: "elevated";
|
|
8
|
+
readonly bar_stroke: "border";
|
|
9
|
+
readonly bar_ink: "text";
|
|
10
|
+
readonly track: "sunken";
|
|
11
|
+
readonly cell: "elevated";
|
|
12
|
+
readonly cell_ink: "text";
|
|
13
|
+
readonly cell_idle: "subtle";
|
|
14
|
+
readonly divider: "border";
|
|
15
|
+
readonly badge: "accent";
|
|
16
|
+
readonly chip: "sunken";
|
|
17
|
+
readonly chip_stroke: "border";
|
|
18
|
+
readonly chip_ink: "text";
|
|
19
|
+
readonly chip_remove: "subtle";
|
|
20
|
+
readonly clear_all: "accent";
|
|
21
|
+
};
|
|
22
|
+
export type ListingToolbarPart = keyof typeof LISTING_TOOLBAR_ROLES;
|
|
23
|
+
/** The toolbar's colours, and the ink that reads on the badge and on a chip's remove button. */
|
|
24
|
+
export type ListingToolbarColors = Readonly<Record<ListingToolbarPart | 'badge_ink' | 'chip_remove_ink', string>>;
|
|
25
|
+
/**
|
|
26
|
+
* Every colour the listing toolbar draws: the count and its word, the bar
|
|
27
|
+
* that opens the sorts and the filters with its stroke, its words and the line
|
|
28
|
+
* between its halves, the badge that counts the filters on, the switch's track
|
|
29
|
+
* with the cell of the layout on show and the idle one, and the chips under the
|
|
30
|
+
* bar with their stroke, words and remove button, and "clear all". A role the
|
|
31
|
+
* merchant chose for the bar, its stroke, its words, the track, the badge or
|
|
32
|
+
* the chips wins; every other part is its role with `listing_toolbar.<part>`
|
|
33
|
+
* over it, and the badge and the remove button write in whichever ink reads on
|
|
34
|
+
* them. The phone and its web twin read this one table.
|
|
35
|
+
*/
|
|
36
|
+
export declare function listingToolbarColors(theme: ThemeStyle, settings?: Pick<ListingToolbarSettings, 'surface' | 'stroke' | 'ink' | 'track' | 'badge' | 'chipSurface' | 'chipStroke' | 'chipInk'>): ListingToolbarColors;
|
|
37
|
+
/** Every measure of the toolbar, and which of its parts it draws. */
|
|
38
|
+
export interface ListingToolbarLook {
|
|
39
|
+
readonly count: boolean;
|
|
40
|
+
readonly layoutSwitch: boolean;
|
|
41
|
+
readonly sort: boolean;
|
|
42
|
+
readonly filter: boolean;
|
|
43
|
+
readonly chips: boolean;
|
|
44
|
+
readonly height: number;
|
|
45
|
+
readonly radius: number;
|
|
46
|
+
readonly countSize: number;
|
|
47
|
+
readonly wordSize: number;
|
|
48
|
+
readonly labelSize: number;
|
|
49
|
+
readonly iconSize: number;
|
|
50
|
+
readonly switchCell: {
|
|
51
|
+
readonly width: number;
|
|
52
|
+
readonly height: number;
|
|
53
|
+
readonly radius: number;
|
|
54
|
+
};
|
|
55
|
+
readonly switchPad: number;
|
|
56
|
+
readonly badge: {
|
|
57
|
+
readonly size: number;
|
|
58
|
+
readonly text: number;
|
|
59
|
+
};
|
|
60
|
+
readonly chip: {
|
|
61
|
+
readonly height: number;
|
|
62
|
+
readonly radius: number;
|
|
63
|
+
readonly text: number;
|
|
64
|
+
readonly remove: number;
|
|
65
|
+
readonly gap: number;
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* The toolbar as the mot design measures it: the count at 15 over a word at
|
|
70
|
+
* 13, the switch's two 34 by 30 cells on a track padded by 3, the bar at the
|
|
71
|
+
* merchant's height and corner with its words at 12.5 beside a 16 point
|
|
72
|
+
* glyph, the badge an 18 point circle with its number at 10.5, and each chip
|
|
73
|
+
* 32 tall at the merchant's corner with its words at 12.5 and an 18 point
|
|
74
|
+
* remove button, 8 apart. The merchant switches each part off and sets the bar.
|
|
75
|
+
*/
|
|
76
|
+
export declare function listingToolbarLook(settings: ListingToolbarSettings): ListingToolbarLook;
|
|
77
|
+
/** How many products a listing holds so far: the number, with a plus while more pages exist, and the word after it. */
|
|
78
|
+
export interface ListingCount {
|
|
79
|
+
readonly number: string;
|
|
80
|
+
readonly word: string;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* The count a listing shows: the products it has loaded, "24+" while Shopify
|
|
84
|
+
* names a next page, and the full number once the last page is in. The
|
|
85
|
+
* Storefront gives a collection no total, so the app never claims one.
|
|
86
|
+
*/
|
|
87
|
+
export declare function listingCount(count: number, more: boolean, language: LocaleCode, defaultLanguage: LocaleCode): ListingCount;
|
|
88
|
+
/** One sort the sheet offers, in the words the shopper reads. */
|
|
89
|
+
export interface ListingSortRow {
|
|
90
|
+
readonly key: ListingSortKey;
|
|
91
|
+
readonly label: string;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* The words of one sort: the merchant's own where they wrote some in a
|
|
95
|
+
* language the buyer reads, and the catalog's otherwise, so a sort the
|
|
96
|
+
* Binding opens in that the toolbar does not list is still named.
|
|
97
|
+
*/
|
|
98
|
+
export declare function listingSortLabel(settings: ListingToolbarSettings, key: ListingSortKey, language: LocaleCode, defaultLanguage: LocaleCode): string;
|
|
99
|
+
/** The sorts the sheet offers, in the merchant's order and words. */
|
|
100
|
+
export declare function listingSortRows(settings: ListingToolbarSettings, language: LocaleCode, defaultLanguage: LocaleCode): readonly ListingSortRow[];
|
|
101
|
+
/**
|
|
102
|
+
* The row a product takes in a list, as mot-mobile draws it: the picture
|
|
103
|
+
* square at 104 beside the title in two lines and the price, and the add
|
|
104
|
+
* button, a 40 point square on the theme's corner, at the reading end, inside
|
|
105
|
+
* a card padded by 10 with 12 between its parts.
|
|
106
|
+
*/
|
|
107
|
+
export declare const PRODUCT_ROW_LOOK: {
|
|
108
|
+
readonly picture: 104;
|
|
109
|
+
readonly padding: 10;
|
|
110
|
+
readonly gap: 12;
|
|
111
|
+
readonly button: 40;
|
|
112
|
+
readonly titleSize: 13.5;
|
|
113
|
+
readonly titleLines: 2;
|
|
114
|
+
readonly priceSize: 17;
|
|
115
|
+
};
|
|
116
|
+
export {};
|
|
117
|
+
//# sourceMappingURL=listing-toolbar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"listing-toolbar.d.ts","sourceRoot":"","sources":["../src/listing-toolbar.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,cAAc,EACnB,KAAK,mBAAmB,EACxB,KAAK,UAAU,EAEf,KAAK,UAAU,EAChB,MAAM,yBAAyB,CAAC;AAMjC,KAAK,sBAAsB,GAAG,mBAAmB,CAAC,OAAO,CAAC,CAAC;AAE3D,kHAAkH;AAClH,QAAA,MAAM,qBAAqB;;;;;;;;;;;;;;;;;CAiBwB,CAAC;AAEpD,MAAM,MAAM,kBAAkB,GAAG,MAAM,OAAO,qBAAqB,CAAC;AAEpE,gGAAgG;AAChG,MAAM,MAAM,oBAAoB,GAAG,QAAQ,CACzC,MAAM,CAAC,kBAAkB,GAAG,WAAW,GAAG,iBAAiB,EAAE,MAAM,CAAC,CACrE,CAAC;AAEF;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,CAClC,KAAK,EAAE,UAAU,EACjB,QAAQ,GAAE,IAAI,CACZ,sBAAsB,EACtB,SAAS,GAAG,QAAQ,GAAG,KAAK,GAAG,OAAO,GAAG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