diff --git a/package.json b/package.json index 89a4d1322d..c7224b1d4c 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "@shopify/babel-preset": "^24.1.0", "@shopify/browserslist-config": "^3.0.0", "@shopify/eslint-plugin": "^42.0.0", - "@shopify/generate-docs": "0.16.4", + "@shopify/generate-docs": "1.0.0", "@shopify/loom": "^1.0.0", "@shopify/loom-cli": "^1.0.0", "@shopify/loom-plugin-build-library": "^1.0.0", @@ -54,4 +54,4 @@ "typescript": "^4.9.0" }, "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e" -} +} \ No newline at end of file diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/api.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/api.ts index 73e8a49084..c374d51fda 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/api.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/api.ts @@ -16,6 +16,8 @@ import {ExtensionApiContext} from '../context'; * which contains a basic set of properties about the checkout. * * For a full list of the API available to each extension target, see the [ExtensionTargets type](https://shopify.dev/docs/api/checkout-ui-extensions/apis/extensiontargets). + * + * @publicDocs */ export function useApi< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -43,6 +45,8 @@ export function useApi< * > Caution: This is deprecated, use `useApi` instead. * * @deprecated This is deprecated, use `useApi` instead. + * + * @publicDocs */ export function useExtensionApi< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/app-metafields.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/app-metafields.ts index 70aa813b25..793174921a 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/app-metafields.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/app-metafields.ts @@ -23,6 +23,8 @@ type AppMetafieldFilterKeys = keyof AppMetafieldFilters; /** * Returns the metafields configured with `shopify.extension.toml`. * @arg {AppMetafieldFilters} - filter the list of returned metafields + * + * @publicDocs */ export function useAppMetafields< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/attributes.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/attributes.ts index ae633415df..dcb19faa1c 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/attributes.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/attributes.ts @@ -12,6 +12,8 @@ import {useSubscription} from './subscription'; /** * Returns the proposed `attributes` applied to the checkout. + * + * @publicDocs */ export function useAttributes< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -23,6 +25,8 @@ export function useAttributes< * Returns the values for the specified `attributes` applied to the checkout. * * @param keys - An array of attribute keys. + * + * @publicDocs */ export function useAttributeValues< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -41,6 +45,8 @@ export function useAttributeValues< /** * Returns a function to mutate the `attributes` property of the checkout. + * + * @publicDocs */ export function useApplyAttributeChange< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/billing-address.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/billing-address.ts index 0cd2bd2406..82c2510556 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/billing-address.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/billing-address.ts @@ -10,6 +10,8 @@ import {useSubscription} from './subscription'; /** * Returns the proposed `billingAddress` applied to the checkout. + * + * @publicDocs */ export function useBillingAddress< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-identity.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-identity.ts index 011d51499e..6acb68730e 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-identity.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-identity.ts @@ -13,6 +13,8 @@ import {useSubscription} from './subscription'; * Returns the current `Customer`. * * The value is `undefined` if the buyer isn't a known customer for this shop or if they haven't logged in yet. + * + * @publicDocs */ export function useCustomer< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -31,6 +33,8 @@ export function useCustomer< /** * Returns the email address of the buyer that is interacting with the cart. * The value is `undefined` if the app does not have access to customer data. + * + * @publicDocs */ export function useEmail< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -49,6 +53,8 @@ export function useEmail< /** * Returns the phone number of the buyer that is interacting with the cart. * The value is `undefined` if the app does not have access to customer data. + * + * @publicDocs */ export function usePhone< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -70,6 +76,8 @@ export function usePhone< * identify both the company and its corresponding location to which the business customer belongs. * * The value is `undefined` if a business customer isn't logged in. This function throws an error if the app doesn't have access to customer data. + * + * @publicDocs */ export function usePurchasingCompany< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-journey.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-journey.ts index 4ad30a1a29..6bf3bfa3eb 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-journey.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/buyer-journey.ts @@ -13,6 +13,8 @@ import {useSubscription} from './subscription'; /** * Returns the `buyerJourney` details on buyer progression in checkout. + * + * @publicDocs */ export function useBuyerJourney< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -33,6 +35,8 @@ export function useBuyerJourney< * Returns true if the buyer completed submitting their order. * * For example, when viewing the **Order status** page after submitting payment, the buyer will have completed their order. + * + * @publicDocs */ export function useBuyerJourneyCompleted< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -54,6 +58,8 @@ export function useBuyerJourneyCompleted< * * If you do, then you're expected to inform the buyer why navigation was blocked, * either by passing validation errors to the checkout UI or rendering the errors in your extension. + * + * @publicDocs */ export function useBuyerJourneyIntercept< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -80,6 +86,8 @@ export function useBuyerJourneyIntercept< /** * Returns all possible steps a buyer can take to complete the checkout. These steps may vary depending on the type of checkout or the shop's configuration. + * + * @publicDocs */ export function useBuyerJourneySteps< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -95,6 +103,8 @@ export function useBuyerJourneySteps< /** * Returns the buyer journey step that the buyer is currently on. + * + * @publicDocs */ export function useBuyerJourneyActiveStep< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/capabilities.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/capabilities.ts index 0dd45d9425..98c282bfd0 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/capabilities.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/capabilities.ts @@ -5,6 +5,8 @@ import {useApi} from './api'; /** * Returns a list of an extension's granted capabilities. + * + * @publicDocs */ export function useExtensionCapabilities(): Capability[] { return useSubscription(useApi().extension.capabilities); @@ -12,6 +14,8 @@ export function useExtensionCapabilities(): Capability[] { /** * Returns whether or not a given capability of an extension is granted. + * + * @publicDocs */ export function useExtensionCapability(capability: Capability): boolean { return useExtensionCapabilities().includes(capability); diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-line-target.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-line-target.ts index 7100fde564..48ec6f8aea 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-line-target.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-line-target.ts @@ -12,6 +12,8 @@ import {useSubscription} from './subscription'; * - `purchase.checkout.cart-line-item.render-after` * - `purchase.thank-you.cart-line-item.render-after` * - 'customer-account.order-status.cart-line-item.render-after' + * + * @publicDocs */ export function useCartLineTarget(): CartLine { const api = useApi< diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-lines.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-lines.ts index 218712fa1f..61fe27fd63 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-lines.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/cart-lines.ts @@ -13,6 +13,8 @@ import {useSubscription} from './subscription'; /** * Returns the current line items for the checkout, and automatically re-renders * your component if line items are added, removed, or updated. + * + * @publicDocs */ export function useCartLines< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -24,6 +26,8 @@ export function useCartLines< /** * Returns a function to mutate the `lines` property of checkout. + * + * @publicDocs */ export function useApplyCartLinesChange< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-settings.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-settings.ts index 78fd7d8df4..704455f502 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-settings.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-settings.ts @@ -8,6 +8,8 @@ import {useSubscription} from './subscription'; /** * Returns the `checkoutSettings` applied to the checkout. + * + * @publicDocs */ export function useCheckoutSettings< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-token.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-token.ts index 52ebd6dda8..41f611e70f 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-token.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/checkout-token.ts @@ -11,6 +11,8 @@ import {useSubscription} from './subscription'; * * Matches the `token` field in the [WebPixel checkout payload](https://shopify.dev/docs/api/pixels/customer-events#checkout) * and the `checkout_token` field in the [Admin REST API Order resource](https://shopify.dev/docs/api/admin-rest/unstable/resources/order#resource-object). + * + * @publicDocs */ export function useCheckoutToken< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/cost.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/cost.ts index e30954fb14..cfda499770 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/cost.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/cost.ts @@ -9,6 +9,8 @@ import {useSubscription} from './subscription'; /** * A `Money` value representing the subtotal value of the items in the cart at the current * step of checkout. + * + * @publicDocs */ export function useSubtotalAmount< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -20,6 +22,8 @@ export function useSubtotalAmount< * A `Money` value representing the total shipping a buyer can expect to pay at the current * step of checkout. This value includes shipping discounts. Returns undefined if shipping * has not been negotiated yet, such as on the information step. + * + * @publicDocs */ export function useTotalShippingAmount< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -31,6 +35,8 @@ export function useTotalShippingAmount< * A `Money` value representing the total tax a buyer can expect to pay at the current * step of checkout or the total tax included in product and shipping prices. Returns * undefined if taxes are unavailable. + * + * @publicDocs */ export function useTotalTaxAmount< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -42,6 +48,8 @@ export function useTotalTaxAmount< * Returns a `Money` value representing the minimum a buyer can expect to pay at the current * step of checkout. This value excludes amounts yet to be negotiated. For example, * the information step might not have delivery costs calculated. + * + * @publicDocs */ export function useTotalAmount< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/country.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/country.ts index 32c5e7b707..d3513a6801 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/country.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/country.ts @@ -9,6 +9,8 @@ import {useSubscription} from './subscription'; /** * Returns the country of the checkout, and automatically re-renders * your component if the country changes. + * + * @publicDocs */ export function useLocalizationCountry< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/currency.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/currency.ts index 724ac99ec7..5dcd102189 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/currency.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/currency.ts @@ -9,6 +9,8 @@ import {useSubscription} from './subscription'; /** * Returns the currency of the checkout, and automatically re-renders * your component if the currency changes. + * + * @publicDocs */ export function useCurrency< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/customer-privacy.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/customer-privacy.ts index ae0ff66bf7..1801675e3c 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/customer-privacy.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/customer-privacy.ts @@ -9,6 +9,8 @@ import {useSubscription} from './subscription'; /** * Returns the current customer privacy settings and metadata and * re-renders your component if the customer privacy settings change. + * + * @publicDocs */ export function useCustomerPrivacy< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-list-target.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-list-target.ts index e7d59b171f..b22ce44975 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-list-target.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-list-target.ts @@ -8,6 +8,8 @@ import {useSubscription} from './subscription'; * extension targets: * - purchase.checkout.shipping-option-list.render-before * - purchase.checkout.shipping-option-list.render-after + * + * @publicDocs */ export function useDeliveryGroupListTarget(): DeliveryGroupList | undefined { const api = useApi< diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-target.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-target.ts index 7bacc39e75..840b86bffd 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-target.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group-target.ts @@ -12,6 +12,8 @@ import {useSubscription} from './subscription'; * > Caution: Deprecated as of version `2024-07`, use `useDeliveryGroupListTarget()` instead. * * @deprecated Deprecated as of version `2024-07`, use `useDeliveryGroupListTarget()` instead. + * + * @publicDocs */ export function useDeliveryGroupTarget(): DeliveryGroup | undefined { const api = useApi< diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group.ts index 8872b5554b..75bcfa4d59 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-group.ts @@ -13,6 +13,8 @@ import {useSubscription} from './subscription'; /** * Returns the full expanded details of a delivery group and automatically re-renders * your component when that delivery group changes. + * + * @publicDocs */ export function useDeliveryGroup< ID extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-groups.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-groups.ts index f7465b5b64..7550fe1dbf 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-groups.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-groups.ts @@ -11,6 +11,8 @@ import {useSubscription} from './subscription'; /** * Returns the current delivery groups for the checkout, and automatically re-renders * your component when delivery address or delivery option selection changes. + * + * @publicDocs */ export function useDeliveryGroups< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-selection-groups.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-selection-groups.ts index 003965f1a9..685db981b8 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-selection-groups.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/delivery-selection-groups.ts @@ -8,6 +8,8 @@ import {useSubscription} from './subscription'; * extension targets: * - purchase.checkout.shipping-option-list.render-before * - purchase.checkout.shipping-option-list.render-after + * + * @publicDocs */ export function useDeliverySelectionGroups(): | DeliverySelectionGroup[] diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/discounts.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/discounts.ts index 61bd917851..141b9b59a3 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/discounts.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/discounts.ts @@ -14,6 +14,8 @@ import {useSubscription} from './subscription'; /** * Returns the current discount codes applied to the cart, and automatically re-renders * your component if discount codes are added or removed. + * + * @publicDocs */ export function useDiscountCodes< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -26,6 +28,8 @@ export function useDiscountCodes< /** * Returns the current discount allocations applied to the cart, and automatically re-renders * your component if discount allocations changed. + * + * @publicDocs */ export function useDiscountAllocations< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -40,6 +44,8 @@ export function useDiscountAllocations< * * > Caution: * > See [security considerations](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#network-access) if your extension retrieves discount codes through a network call. + * + * @publicDocs */ export function useApplyDiscountCodeChange< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-editor.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-editor.ts index ed73a3d777..83032cb791 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-editor.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-editor.ts @@ -4,6 +4,8 @@ import {useApi} from './api'; /** * Returns information about the editor where the extension is being rendered. + * + * @publicDocs */ export function useExtensionEditor(): Editor | undefined { return useApi().extension.editor; diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-language.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-language.ts index e19aebb77d..5edd821c85 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-language.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension-language.ts @@ -8,6 +8,8 @@ import {useSubscription} from './subscription'; /** * Returns the buyer's language, as supported by the extension. + * + * @publicDocs */ export function useExtensionLanguage< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension.ts index 566475b437..5ed4c47239 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/extension.ts @@ -4,6 +4,8 @@ import {useApi} from './api'; /** * Returns the metadata about the extension. + * + * @publicDocs */ export function useExtension(): Extension { return useApi().extension as Extension; @@ -13,6 +15,8 @@ export function useExtension(): Extension { * Returns the metadata about the extension. * > Caution: This is deprecated, use `useExtension()` instead. * @deprecated Use `useExtension()` instead. + * + * @publicDocs */ export function useExtensionData(): Extension { return useExtension(); diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/gift-cards.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/gift-cards.ts index f45f1da174..c4434bddd9 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/gift-cards.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/gift-cards.ts @@ -13,6 +13,8 @@ import {useSubscription} from './subscription'; /** * Returns the current gift cards applied to the cart, and automatically re-renders * your component if gift cards are added or removed. + * + * @publicDocs */ export function useAppliedGiftCards< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -27,6 +29,8 @@ export function useAppliedGiftCards< * * > Caution: * > See [security considerations](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#network-access) if your extension retrieves gift card codes through a network call. + * + * @publicDocs */ export function useApplyGiftCardChange< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/instructions.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/instructions.ts index f7c8a94cf2..d62ee50316 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/instructions.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/instructions.ts @@ -8,6 +8,8 @@ import {useSubscription} from './subscription'; /** * Returns the cart instructions used to create the checkout and possibly limit extension capabilities. + * + * @publicDocs */ export function useInstructions< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/language.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/language.ts index 7329a9f08c..740fc5d844 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/language.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/language.ts @@ -9,6 +9,8 @@ import {useSubscription} from './subscription'; /** * Returns the current language of the checkout, and automatically re-renders * your component if the language changes. + * + * @publicDocs */ export function useLanguage< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/market.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/market.ts index 4c3edd8772..400b542101 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/market.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/market.ts @@ -9,6 +9,8 @@ import {useSubscription} from './subscription'; /** * Returns the market of the checkout, and automatically re-renders * your component if it changes. + * + * @publicDocs */ export function useLocalizationMarket< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafield.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafield.ts index 041c42e115..927f5994db 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafield.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafield.ts @@ -12,6 +12,8 @@ interface MetafieldFilter { /** * Returns a single filtered `Metafield` or `undefined`. * @arg {MetafieldFilter} - filter the list of returned metafields to a single metafield + * + * @publicDocs */ export function useMetafield(filters: MetafieldFilter): Metafield | undefined { const {namespace, key} = filters; diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafields.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafields.ts index e993f25c40..c94da67d1a 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafields.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/metafields.ts @@ -20,6 +20,8 @@ interface MetafieldsFilters { * Returns the current array of `metafields` applied to the checkout. * You can optionally filter the list. * @arg {MetafieldsFilters} - filter the list of returned metafields + * + * @publicDocs */ export function useMetafields< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -50,6 +52,8 @@ export function useMetafields< /** * Returns a function to mutate the `metafields` property of the checkout. + * + * @publicDocs */ export function useApplyMetafieldsChange< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/note.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/note.ts index 483fb4ab0a..f2069e2929 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/note.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/note.ts @@ -11,6 +11,8 @@ import {useSubscription} from './subscription'; /** * Returns the proposed `note` applied to the checkout. + * + * @publicDocs */ export function useNote< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -20,6 +22,8 @@ export function useNote< /** * Returns a function to mutate the `note` property of the checkout. + * + * @publicDocs */ export function useApplyNoteChange< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/order.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/order.ts index 3f06c80ce7..e93327dc60 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/order.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/order.ts @@ -10,6 +10,8 @@ import {useSubscription} from './subscription'; /** * Returns the order information that's available post-checkout. + * + * @publicDocs */ export function useOrder< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-method.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-method.ts index b4ad2cacb6..f151612c86 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-method.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-method.ts @@ -11,6 +11,8 @@ import {useSubscription} from './subscription'; /** * Returns the proposed `paymentAttributes` applied to the checkout. + * + * @publicDocs */ export function usePaymentMethodAttributes(): | PaymentMethodAttribute[] @@ -33,6 +35,8 @@ export function usePaymentMethodAttributes(): * Returns the values for the specified `paymentAttributes` applied to the checkout. * * @param keys - An array of attribute keys. + * + * @publicDocs */ export function usePaymentMethodAttributeValues( keys: string[], @@ -51,6 +55,8 @@ export function usePaymentMethodAttributeValues( /** * Returns a function to set payment method attributes. + * + * @publicDocs */ export function useApplyPaymentMethodAttributesChange(): ( change: PaymentMethodAttributesChange, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-options.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-options.ts index bea0176b4a..0c68096a4e 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-options.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/payment-options.ts @@ -11,6 +11,8 @@ import {useSubscription} from './subscription'; /** * Returns all available payment options. + * + * @publicDocs */ export function useAvailablePaymentOptions< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -29,6 +31,8 @@ export function useAvailablePaymentOptions< /** * Returns payment options selected by the buyer. + * + * @publicDocs */ export function useSelectedPaymentOptions< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/pickup-location-option-target.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/pickup-location-option-target.ts index 415926921f..3d7ad51bf8 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/pickup-location-option-target.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/pickup-location-option-target.ts @@ -10,6 +10,8 @@ import {useSubscription} from './subscription'; * Returns the pickup location option the extension is attached to. This hook can only be used by extensions in the following * extension target: * - `purchase.checkout.pickup-location-option-item.render-after` + * + * @publicDocs */ export function usePickupLocationOptionTarget(): { pickupLocationOptionTarget: PickupLocationOption; diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/redeemable.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/redeemable.ts index fe645a685e..4778dccdf7 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/redeemable.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/redeemable.ts @@ -9,6 +9,8 @@ import {useApi} from './api'; /** * Returns a function to apply a change to add a redeemable. + * + * @publicDocs */ export function useApplyRedeemableChange(): ( change: RedeemableChange, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/session-token.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/session-token.ts index 67c931f5e6..0ecfda265f 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/session-token.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/session-token.ts @@ -7,6 +7,8 @@ import {useApi} from './api'; /** * Provides access to session tokens, which can be used to verify token claims on your app's server. + * + * @publicDocs */ export function useSessionToken< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/settings.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/settings.ts index d9b82e0c37..07d0105bf1 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/settings.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/settings.ts @@ -5,6 +5,8 @@ import {useSubscription} from './subscription'; /** * Returns the setting values defined by the merchant for the extension. + * + * @publicDocs */ export function useSettings< Settings extends ExtensionSettings, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-address.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-address.ts index 28bfd3ea58..cee063f9d8 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-address.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-address.ts @@ -12,6 +12,8 @@ import {useSubscription} from './subscription'; /** * Returns the proposed `shippingAddress` applied to the checkout. + * + * @publicDocs */ export function useShippingAddress< Target extends RenderExtensionTarget = RenderExtensionTarget, @@ -29,6 +31,8 @@ export function useShippingAddress< /** * Returns a function to mutate the `shippingAddress` property of checkout. + * + * @publicDocs */ export function useApplyShippingAddressChange< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-option-target.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-option-target.ts index 58af52df76..0fbd9907ab 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-option-target.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/shipping-option-target.ts @@ -14,6 +14,8 @@ import {useSubscription} from './subscription'; * extension targets: * - `purchase.checkout.shipping-option-item.render-after` * - `purchase.checkout.shipping-option-item.details.render` + * + * @publicDocs */ export function useShippingOptionTarget(): { shippingOptionTarget: ShippingOption; diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/shop.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/shop.ts index 4bc3ddb960..0b9a1f3977 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/shop.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/shop.ts @@ -7,6 +7,8 @@ import {useApi} from './api'; /** * Returns the `Shop` where the checkout is taking place. + * + * @publicDocs */ export function useShop< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/storage.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/storage.ts index 9905a17da6..c6fd117bcd 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/storage.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/storage.ts @@ -12,6 +12,8 @@ import {useApi} from './api'; * * Data is shared across all activated extension targets of this extension. In versions `<=2023-07`, * each activated extension target had its own storage. + * + * @publicDocs */ export function useStorage< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/subscription.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/subscription.ts index b4ec1f8044..9dcc7c53ee 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/subscription.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/subscription.ts @@ -11,6 +11,8 @@ type Subscriber = Parameters['subscribe']>[0]; * > Note: * > You generally shouldn’t need to use this directly, as there are dedicated hooks * > for accessing the current value of each individual resource in the checkout. + * + * @publicDocs */ export function useSubscription( subscription: StatefulRemoteSubscribable, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/target.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/target.ts index c6995fcfe5..48591b5fd9 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/target.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/target.ts @@ -22,6 +22,8 @@ class ExtensionHasNoTargetError extends Error { * > Caution: Deprecated as of version `2023-10`, use `useCartLineTarget()` instead. * * @deprecated Deprecated as of version `2023-10`, use `useCartLineTarget()` instead. + * + * @publicDocs */ export function useTarget(): CartLine { const api = useApi< diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/timezone.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/timezone.ts index 93d5b96905..31d43f84fe 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/timezone.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/timezone.ts @@ -9,6 +9,8 @@ import {useSubscription} from './subscription'; /** * Returns the time zone of the checkout, and automatically re-renders * your component if the time zone changes. + * + * @publicDocs */ export function useTimezone< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions-react/src/surfaces/checkout/hooks/translate.ts b/packages/ui-extensions-react/src/surfaces/checkout/hooks/translate.ts index 5df1ee6c79..7fed2a9fe3 100644 --- a/packages/ui-extensions-react/src/surfaces/checkout/hooks/translate.ts +++ b/packages/ui-extensions-react/src/surfaces/checkout/hooks/translate.ts @@ -8,6 +8,8 @@ import {useApi} from './api'; /** * Returns the `I18nTranslate` interface used to translate strings. + * + * @publicDocs */ export function useTranslate< Target extends RenderExtensionTarget = RenderExtensionTarget, diff --git a/packages/ui-extensions/docs/surfaces/admin/build-docs.sh b/packages/ui-extensions/docs/surfaces/admin/build-docs.sh index 669707ff4d..2e3d0a04f7 100755 --- a/packages/ui-extensions/docs/surfaces/admin/build-docs.sh +++ b/packages/ui-extensions/docs/surfaces/admin/build-docs.sh @@ -50,7 +50,7 @@ fi # Make sure https://shopify.dev URLs are relative so they work in Spin. # See https://github.com/Shopify/generate-docs/issues/181 -run_sed 's/https:\/\/shopify.dev//gi' ./$DOCS_PATH/generated/generated_docs_data.json +run_sed 's/https:\/\/shopify.dev//gi' ./$DOCS_PATH/generated/generated_docs_data_v2.json sed_exit=$? if [ $sed_exit -ne 0 ]; then fail_and_exit $sed_exit @@ -70,7 +70,7 @@ if [ -d $SHOPIFY_DEV_PATH ]; then # Replace 'unstable' with the exact API version in relative doc links run_sed \ "s/\/docs\/api\/admin-extensions\/unstable/\/docs\/api\/admin-extensions\/$API_VERSION/gi" \ - $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/admin_extensions/$API_VERSION/generated_docs_data.json + $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/admin_extensions/$API_VERSION/generated_docs_data_v2.json sed_exit=$? if [ $sed_exit -ne 0 ]; then fail_and_exit $sed_exit diff --git a/packages/ui-extensions/docs/surfaces/checkout/build-docs.sh b/packages/ui-extensions/docs/surfaces/checkout/build-docs.sh index 8a0aed6749..560e615632 100644 --- a/packages/ui-extensions/docs/surfaces/checkout/build-docs.sh +++ b/packages/ui-extensions/docs/surfaces/checkout/build-docs.sh @@ -66,7 +66,7 @@ fi # Make sure https://shopify.dev URLs are relative so they work in Spin. # See https://github.com/Shopify/generate-docs/issues/181 -run_sed 's/https:\/\/shopify.dev//gi' ./$DOCS_PATH/generated/generated_docs_data.json +run_sed 's/https:\/\/shopify.dev//gi' ./$DOCS_PATH/generated/generated_docs_data_v2.json sed_exit=$? if [ $sed_exit -ne 0 ]; then fail_and_exit $sed_exit @@ -87,7 +87,7 @@ if [ -d $SHOPIFY_DEV_PATH ]; then # Replace 'unstable' with the exact API version in relative doc links run_sed \ "s/\/docs\/api\/checkout-ui-extensions\/unstable/\/docs\/api\/checkout-ui-extensions\/$API_VERSION/gi" \ - $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/checkout_extensions/$API_VERSION/generated_docs_data.json + $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/checkout_extensions/$API_VERSION/generated_docs_data_v2.json sed_exit=$? if [ $sed_exit -ne 0 ]; then fail_and_exit $sed_exit diff --git a/packages/ui-extensions/docs/surfaces/customer-account/build-docs.sh b/packages/ui-extensions/docs/surfaces/customer-account/build-docs.sh index 83b6e0de9a..0ba5f8fd46 100644 --- a/packages/ui-extensions/docs/surfaces/customer-account/build-docs.sh +++ b/packages/ui-extensions/docs/surfaces/customer-account/build-docs.sh @@ -64,12 +64,20 @@ fi find ./ -name '*.doc*.js' -exec rm -r {} \; +# @shopify/generate-docs v1.0.0 outputs generated_docs_data.json; downstream expects generated_docs_data_v2.json +if [ -f "./$DOCS_PATH/generated/generated_docs_data.json" ]; then + cp "./$DOCS_PATH/generated/generated_docs_data.json" "./$DOCS_PATH/generated/generated_docs_data_v2.json" +fi + # Make sure https://shopify.dev URLs are relative so they work in Spin. # See https://github.com/Shopify/generate-docs/issues/181 -run_sed 's/https:\/\/shopify.dev//gi' ./$DOCS_PATH/generated/generated_docs_data.json -sed_exit=$? -if [ $sed_exit -ne 0 ]; then - fail_and_exit $sed_exit +DOCS_JSON="./$DOCS_PATH/generated/generated_docs_data_v2.json" +if [ -f "$DOCS_JSON" ]; then + run_sed 's/https:\/\/shopify.dev//gi' "$DOCS_JSON" + sed_exit=$? + if [ $sed_exit -ne 0 ]; then + fail_and_exit $sed_exit + fi fi # Generate targets.json @@ -83,13 +91,16 @@ fi if [ -d $SHOPIFY_DEV_PATH ]; then mkdir -p $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/customer_account_ui_extensions/$API_VERSION cp ./$DOCS_PATH/generated/* $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/customer_account_ui_extensions/$API_VERSION - # Replace 'unstable' with the exact API version in relative doc links - run_sed \ - "s/\/docs\/api\/customer-account-ui-extensions\/unstable/\/docs\/api\/customer-account-ui-extensions\/$API_VERSION/gi" \ - $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/customer_account_ui_extensions/$API_VERSION/generated_docs_data.json - sed_exit=$? - if [ $sed_exit -ne 0 ]; then - fail_and_exit $sed_exit + # Replace 'unstable' with the exact API version in relative doc links (downstream expects generated_docs_data_v2.json) + DEST_DOCS_JSON="$SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/customer_account_ui_extensions/$API_VERSION/generated_docs_data_v2.json" + if [ -f "$DEST_DOCS_JSON" ]; then + run_sed \ + "s/\/docs\/api\/customer-account-ui-extensions\/unstable/\/docs\/api\/customer-account-ui-extensions\/$API_VERSION/gi" \ + "$DEST_DOCS_JSON" + sed_exit=$? + if [ $sed_exit -ne 0 ]; then + fail_and_exit $sed_exit + fi fi rsync -a --delete ./$DOCS_PATH/screenshots/ $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/content/assets/images/templated-apis-screenshots/customer-account-ui-extensions/$API_VERSION diff --git a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/authenticated-account.doc.ts b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/authenticated-account.doc.ts index ca1c2efe8d..3ff4d37d7a 100644 --- a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/authenticated-account.doc.ts +++ b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/authenticated-account.doc.ts @@ -13,19 +13,19 @@ const data: ReferenceEntityTemplateSchema = { { title: CUSTOMER_ACCOUNT_STANDARD_API_DEFINITION.title, description: CUSTOMER_ACCOUNT_STANDARD_API_DEFINITION.description, - type: 'Docs_Standard_AuthenticatedAccountApi', + type: CUSTOMER_ACCOUNT_STANDARD_API_DEFINITION.type, }, { title: 'useAuthenticatedAccountCustomer', description: "Returns the current authenticated `Customer`. The value is `undefined` if the customer isn't authenticated.", - type: 'UseAuthenticatedAccountCustomerGeneratedType', + type: 'UseCustomerGeneratedType', }, { title: 'useAuthenticatedAccountPurchasingCompany', description: "Provides information about the company of the authenticated business customer. The value is `undefined` if a business customer isn't authenticated.", - type: 'UseAuthenticatedAccountPurchasingCompanyGeneratedType', + type: 'UsePurchasingCompanyGeneratedType', }, ], related: [], diff --git a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/extension.doc.ts b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/extension.doc.ts index cff72890a0..1d06c9490c 100644 --- a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/extension.doc.ts +++ b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/extension.doc.ts @@ -12,7 +12,7 @@ const data: ReferenceEntityTemplateSchema = { { title: CUSTOMER_ACCOUNT_STANDARD_API_DEFINITION.title, description: CUSTOMER_ACCOUNT_STANDARD_API_DEFINITION.description, - type: 'Docs_Standard_ExtensionApi', + type: CUSTOMER_ACCOUNT_STANDARD_API_DEFINITION.type, }, { title: 'useExtension', diff --git a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/localization.doc.ts b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/localization.doc.ts index 0283ed43d8..875b6c5ebb 100644 --- a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/localization.doc.ts +++ b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/localization.doc.ts @@ -30,7 +30,7 @@ const data: ReferenceEntityTemplateSchema = { title: 'useI18n', description: 'Returns utilities for translating content and formatting values according to the current localization of the user.', - type: 'UseI18nGeneratedType', + type: 'UseTranslateGeneratedType', }, { title: 'useTranslate', diff --git a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/navigation.doc.ts b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/navigation.doc.ts index c9c14a6116..fb9119d613 100644 --- a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/navigation.doc.ts +++ b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/navigation.doc.ts @@ -31,7 +31,7 @@ const data: ReferenceEntityTemplateSchema = { { title: 'useNavigationCurrentEntry', description: 'Returns the live navigation current entry', - type: 'UseNavigationCurrentEntryGeneratedType', + type: 'UseApiGeneratedType', }, ], defaultExample: { diff --git a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/order-status-api/authentication-state.doc.ts b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/order-status-api/authentication-state.doc.ts index 24310b8353..9bc89b6b86 100644 --- a/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/order-status-api/authentication-state.doc.ts +++ b/packages/ui-extensions/docs/surfaces/customer-account/reference/apis/order-status-api/authentication-state.doc.ts @@ -18,7 +18,7 @@ const data: ReferenceEntityTemplateSchema = { { title: 'useAuthenticationState', description: 'Returns authentication state of Order status page.', - type: 'UseAuthenticationStateGeneratedType', + type: 'UseApiGeneratedType', }, ], related: [], diff --git a/packages/ui-extensions/docs/surfaces/point-of-sale/build-docs.sh b/packages/ui-extensions/docs/surfaces/point-of-sale/build-docs.sh index 89cf7767a4..63e83ff6d5 100755 --- a/packages/ui-extensions/docs/surfaces/point-of-sale/build-docs.sh +++ b/packages/ui-extensions/docs/surfaces/point-of-sale/build-docs.sh @@ -47,10 +47,16 @@ fi # Make sure https://shopify.dev URLs are relative so they work in Spin. # See https://github.com/Shopify/generate-docs/issues/181 -run_sed 's/https:\/\/shopify.dev//gi' ./$DOCS_PATH/generated/generated_docs_data.json -sed_exit=$? -if [ $sed_exit -ne 0 ]; then - fail_and_exit $sed_exit +DOCS_JSON="./$DOCS_PATH/generated/generated_docs_data_v2.json" +if [ ! -f "$DOCS_JSON" ]; then + DOCS_JSON="./$DOCS_PATH/generated/generated_docs_data.json" +fi +if [ -f "$DOCS_JSON" ]; then + run_sed 's/https:\/\/shopify.dev//gi' "$DOCS_JSON" + sed_exit=$? + if [ $sed_exit -ne 0 ]; then + fail_and_exit $sed_exit + fi fi # Generate targets.json @@ -65,12 +71,18 @@ if [ -d $SHOPIFY_DEV_PATH ]; then mkdir -p $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/pos_ui_extensions/$API_VERSION cp ./$DOCS_PATH/generated/* $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/pos_ui_extensions/$API_VERSION # Replace 'unstable' with the exact API version in relative doc links - run_sed \ - "s/\/docs\/api\/pos-ui-extensions\/unstable/\/docs\/api\/pos-ui-extensions\/$API_VERSION/gi" \ - $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/pos_ui_extensions/$API_VERSION/generated_docs_data.json - sed_exit=$? - if [ $sed_exit -ne 0 ]; then - fail_and_exit $sed_exit + DEST_DOCS_JSON="$SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/pos_ui_extensions/$API_VERSION/generated_docs_data_v2.json" + if [ ! -f "$DEST_DOCS_JSON" ]; then + DEST_DOCS_JSON="$SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/db/data/docs/templated_apis/pos_ui_extensions/$API_VERSION/generated_docs_data.json" + fi + if [ -f "$DEST_DOCS_JSON" ]; then + run_sed \ + "s/\/docs\/api\/pos-ui-extensions\/unstable/\/docs\/api\/pos-ui-extensions\/$API_VERSION/gi" \ + "$DEST_DOCS_JSON" + sed_exit=$? + if [ $sed_exit -ne 0 ]; then + fail_and_exit $sed_exit + fi fi rsync -a --delete ./$DOCS_PATH/screenshots/ $SHOPIFY_DEV_PATH/areas/platforms/shopify-dev/content/assets/images/templated-apis-screenshots/pos-ui-extensions/$API_VERSION diff --git a/packages/ui-extensions/package.json b/packages/ui-extensions/package.json index f09cf48cb0..1b85b79075 100644 --- a/packages/ui-extensions/package.json +++ b/packages/ui-extensions/package.json @@ -67,7 +67,7 @@ "@remote-ui/core": "^2.2.4" }, "devDependencies": { - "@shopify/generate-docs": "0.16.4", + "@shopify/generate-docs": "1.0.0", "typescript": "^4.9.0" }, "publishConfig": { @@ -86,4 +86,4 @@ "@shopify/strict-component-boundaries": "off" } } -} +} \ No newline at end of file diff --git a/packages/ui-extensions/src/surfaces/admin/api/checkout-rules/metafields.ts b/packages/ui-extensions/src/surfaces/admin/api/checkout-rules/metafields.ts index 1c0552d293..909044b236 100644 --- a/packages/ui-extensions/src/surfaces/admin/api/checkout-rules/metafields.ts +++ b/packages/ui-extensions/src/surfaces/admin/api/checkout-rules/metafields.ts @@ -104,7 +104,7 @@ type MetafieldChangeResult = | MetafieldChangeResultError; /** - * A function that applies metafield changes to validation settings. Call this function with an update or removal operation, then await the Promise to receive a result indicating success or failure. Use the result to provide feedback or handle errors in your settings interface. + * Applies a [metafield](/docs/apps/build/metafields) change to the validation settings. Use this method to update or remove metafields that store validation function configuration data. The method accepts a change object specifying the operation type, metafield key, namespace, value, and [value type](/docs/apps/build/metafields/list-of-data-types). Returns a promise that resolves to indicate success or provides an error message if the operation fails. */ export type ApplyMetafieldChange = ( change: MetafieldChange, diff --git a/packages/ui-extensions/src/surfaces/admin/components/AdminAction/AdminAction.ts b/packages/ui-extensions/src/surfaces/admin/components/AdminAction/AdminAction.ts index 267d8bba33..ecd89be471 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/AdminAction/AdminAction.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/AdminAction/AdminAction.ts @@ -5,6 +5,8 @@ import type {RemoteFragment} from '@remote-ui/core'; * Props for the AdminAction component, used by Admin Action extensions to * configure the title, primary and secondary action buttons, and loading * state of the action modal. + * + * @publicDocs */ export interface AdminActionProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/AdminBlock/AdminBlock.ts b/packages/ui-extensions/src/surfaces/admin/components/AdminBlock/AdminBlock.ts index 24e60e77b3..f82d11e0bd 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/AdminBlock/AdminBlock.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/AdminBlock/AdminBlock.ts @@ -4,6 +4,8 @@ import {createRemoteComponent} from '@remote-ui/core'; * Props for the AdminBlock component, used by Admin Block extensions to * configure the title and collapsed summary of an app block rendered on * a resource page in the Shopify admin. + * + * @publicDocs */ export interface AdminBlockProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/AdminPrintAction/AdminPrintAction.ts b/packages/ui-extensions/src/surfaces/admin/components/AdminPrintAction/AdminPrintAction.ts index ef449e5ce4..e1dd8fcd80 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/AdminPrintAction/AdminPrintAction.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/AdminPrintAction/AdminPrintAction.ts @@ -3,6 +3,8 @@ import {createRemoteComponent} from '@remote-ui/core'; /** * Props for the AdminPrintAction component, used by Admin Print Action * extensions to configure a source document to preview and print. + * + * @publicDocs */ export interface AdminPrintActionProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/Badge/Badge.ts b/packages/ui-extensions/src/surfaces/admin/components/Badge/Badge.ts index bbadd60a57..bafd6be3cc 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Badge/Badge.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Badge/Badge.ts @@ -76,6 +76,8 @@ interface BadgeNoIconProps { * Props for the Badge component. A badge can optionally include an icon * (`BadgeIconProps`) or omit one (`BadgeNoIconProps`). This union ensures * type safety so that `iconPosition` can only be set when `icon` is present. + * + * @publicDocs */ export type BadgeProps = BadgeBaseProps & (BadgeIconProps | BadgeNoIconProps); diff --git a/packages/ui-extensions/src/surfaces/admin/components/Banner/Banner.ts b/packages/ui-extensions/src/surfaces/admin/components/Banner/Banner.ts index 74cf85dc17..98914123a2 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Banner/Banner.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Banner/Banner.ts @@ -5,6 +5,8 @@ import {GlobalProps, Tone} from '../shared'; * Props for the Banner component, which displays a prominent message to * the merchant. Banners communicate important information, status updates, * warnings, or errors, with optional primary and secondary actions. + * + * @publicDocs */ export interface BannerProps extends GlobalProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/BlockStack/BlockStack.ts b/packages/ui-extensions/src/surfaces/admin/components/BlockStack/BlockStack.ts index 3e85931e8f..d6e0dc3b95 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/BlockStack/BlockStack.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/BlockStack/BlockStack.ts @@ -15,6 +15,8 @@ import { * Props for the BlockStack component, which arranges its children in a * vertical stack (block axis). Use BlockStack to lay out components * vertically with consistent spacing and alignment. + * + * @publicDocs */ export interface BlockStackProps extends AccessibilityRoleProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/Box/Box.ts b/packages/ui-extensions/src/surfaces/admin/components/Box/Box.ts index f4f8120d04..dd029369ac 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Box/Box.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Box/Box.ts @@ -10,6 +10,8 @@ import {DisplayProps} from '../shared/display'; * Props for the Box component, a generic layout container. Box doesn't * define any props of its own. It inherits accessibility, sizing, padding, * and display props from shared interfaces. + * + * @publicDocs */ export interface BoxProps extends AccessibilityRoleProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/Button/Button.ts b/packages/ui-extensions/src/surfaces/admin/components/Button/Button.ts index 20ad292fa0..24aea846c2 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Button/Button.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Button/Button.ts @@ -5,6 +5,8 @@ import type {AccessibilityRole, AnchorProps} from '../shared'; * Props for the Button component. A button can either be a standard action * button (`ButtonBaseProps`) or an anchor-style button that navigates to a * URL (`ButtonAnchorProps`). + * + * @publicDocs */ export type ButtonProps = ButtonBaseProps | ButtonAnchorProps; diff --git a/packages/ui-extensions/src/surfaces/admin/components/Checkbox/Checkbox.ts b/packages/ui-extensions/src/surfaces/admin/components/Checkbox/Checkbox.ts index 746b34af46..178349a8f3 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Checkbox/Checkbox.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Checkbox/Checkbox.ts @@ -4,6 +4,8 @@ import {AccessibilityLabelProps} from '../shared'; /** * Props for the Checkbox component, which renders a toggleable input * that lets the merchant choose between a checked and unchecked state. + * + * @publicDocs */ export interface CheckboxProps extends AccessibilityLabelProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/ChoiceList/ChoiceList.ts b/packages/ui-extensions/src/surfaces/admin/components/ChoiceList/ChoiceList.ts index ce5a7b5868..e3521d12f1 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/ChoiceList/ChoiceList.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/ChoiceList/ChoiceList.ts @@ -24,6 +24,8 @@ export interface ChoiceProps * Props for the ChoiceList component, which renders a group of selectable * choices as either radio buttons (single selection) or checkboxes * (multiple selection). + * + * @publicDocs */ export interface ChoiceListProps extends Pick< diff --git a/packages/ui-extensions/src/surfaces/admin/components/ColorPicker/ColorPicker.ts b/packages/ui-extensions/src/surfaces/admin/components/ColorPicker/ColorPicker.ts index 1c6cd425fd..36f1183631 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/ColorPicker/ColorPicker.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/ColorPicker/ColorPicker.ts @@ -4,6 +4,8 @@ import {createRemoteComponent} from '@remote-ui/core'; * Props for the ColorPicker component, which provides a visual interface * for the merchant to select a color, with optional alpha (transparency) * support. + * + * @publicDocs */ export interface ColorPickerProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/CustomerSegmentTemplate/CustomerSegmentTemplate.ts b/packages/ui-extensions/src/surfaces/admin/components/CustomerSegmentTemplate/CustomerSegmentTemplate.ts index af4a6236df..f5debeff0e 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/CustomerSegmentTemplate/CustomerSegmentTemplate.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/CustomerSegmentTemplate/CustomerSegmentTemplate.ts @@ -11,6 +11,8 @@ type CustomerStandardMetafieldDependency = 'facts.birth_date'; * Props for the CustomerSegmentTemplate component, which defines a * reusable segment template that merchants can apply in the customer * segment editor. + * + * @publicDocs */ export interface CustomerSegmentTemplateProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/DateField/DateField.ts b/packages/ui-extensions/src/surfaces/admin/components/DateField/DateField.ts index 5a3a0e08ec..aa7f93efa4 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/DateField/DateField.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/DateField/DateField.ts @@ -7,6 +7,8 @@ import type {TextFieldProps} from '../TextField/TextField'; * picker for date selection. Text input props (like `label`, `value`, `onChange`, * and `error`) come from `TextFieldProps`, while calendar navigation props (like * `yearMonth`, `disabled`, and `onYearMonthChange`) come from `DatePickerProps`. + * + * @publicDocs */ export interface DateFieldProps extends Pick< diff --git a/packages/ui-extensions/src/surfaces/admin/components/DatePicker/DatePicker.ts b/packages/ui-extensions/src/surfaces/admin/components/DatePicker/DatePicker.ts index 6ade504479..c984d99966 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/DatePicker/DatePicker.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/DatePicker/DatePicker.ts @@ -4,6 +4,8 @@ import {createRemoteComponent} from '@remote-ui/core'; * Props for the DatePicker component, a calendar-based date selection control. * The generic parameter `T` determines the selection mode: pass a `DateString` * for single-date, a `DateString[]` for multi-date, or a `Range` for range selection. + * + * @publicDocs */ export interface DatePickerProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/Divider/Divider.ts b/packages/ui-extensions/src/surfaces/admin/components/Divider/Divider.ts index d37d133d59..64e290e813 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Divider/Divider.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Divider/Divider.ts @@ -3,6 +3,8 @@ import {createRemoteComponent} from '@remote-ui/core'; /** * Props for the Divider component, a visual separator used to distinguish * adjacent sections of content. + * + * @publicDocs */ export interface DividerProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/EmailField/EmailField.ts b/packages/ui-extensions/src/surfaces/admin/components/EmailField/EmailField.ts index 3d0aa987a3..a52be749da 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/EmailField/EmailField.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/EmailField/EmailField.ts @@ -12,6 +12,8 @@ import { * addresses. It inherits common input props (like `label`, `value`, * `onChange`, and `error`) from `InputProps`, length validation from * `MinMaxLengthProps`, and browser autofill hints from `AutocompleteProps`. + * + * @publicDocs */ export interface EmailFieldProps extends InputProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/Form/Form.ts b/packages/ui-extensions/src/surfaces/admin/components/Form/Form.ts index 785d868962..a279303720 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Form/Form.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Form/Form.ts @@ -4,6 +4,8 @@ import {createRemoteComponent} from '@remote-ui/core'; * Props for the Form component, a container that groups related input * fields and manages submission and reset behavior through the * save bar. + * + * @publicDocs */ export interface FormProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/FunctionSettings/FunctionSettings.ts b/packages/ui-extensions/src/surfaces/admin/components/FunctionSettings/FunctionSettings.ts index c045b48e29..22623a118e 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/FunctionSettings/FunctionSettings.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/FunctionSettings/FunctionSettings.ts @@ -4,6 +4,8 @@ import {createRemoteComponent} from '@remote-ui/core'; * Props for the FunctionSettings component, a form container designed * for Shopify Function configuration experiences. It provides hooks for * saving settings and handling server-side validation errors. + * + * @publicDocs */ export interface FunctionSettingsProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/Heading/Heading.ts b/packages/ui-extensions/src/surfaces/admin/components/Heading/Heading.ts index a39b8b6f5c..274d310701 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Heading/Heading.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Heading/Heading.ts @@ -12,6 +12,8 @@ type Level = 1 | 2 | 3 | 4 | 5 | 6; * determined automatically by the nesting depth of HeadingGroup or * Section ancestors; use the `size` prop to control its visual * appearance independently. + * + * @publicDocs */ export interface HeadingProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/HeadingGroup/HeadingGroup.ts b/packages/ui-extensions/src/surfaces/admin/components/HeadingGroup/HeadingGroup.ts index 368ad96a26..92206e6763 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/HeadingGroup/HeadingGroup.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/HeadingGroup/HeadingGroup.ts @@ -6,6 +6,8 @@ import {createRemoteComponent} from '@remote-ui/core'; * semantic heading level for any Heading components nested inside it. * Each level of HeadingGroup nesting increments the heading level by one * (for example, a Heading inside two HeadingGroup components renders as a level-3 heading). + * + * @publicDocs */ export interface HeadingGroupProps {} diff --git a/packages/ui-extensions/src/surfaces/admin/components/Icon/Icon.ts b/packages/ui-extensions/src/surfaces/admin/components/Icon/Icon.ts index 7cdf577a2c..1ee27c361d 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Icon/Icon.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Icon/Icon.ts @@ -5,6 +5,8 @@ import {AccessibilityLabelProps} from '../shared'; /** * Props for the Icon component, which renders a Polaris icon by name. * Inherits accessibility label support from `AccessibilityLabelProps`. + * + * @publicDocs */ export interface IconProps extends AccessibilityLabelProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/Icon/IconName.ts b/packages/ui-extensions/src/surfaces/admin/components/Icon/IconName.ts index 82d76a405a..cbf49d47e7 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Icon/IconName.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Icon/IconName.ts @@ -3,6 +3,8 @@ * the Polaris icon set. Names follow the pattern `{IconName}{Major|Minor}`, * where `Major` icons are intended for primary use and `Minor` icons are * smaller variants for inline or secondary use. + * + * @publicDocs */ export type IconName = | 'AbandonedCartFilledMajor' diff --git a/packages/ui-extensions/src/surfaces/admin/components/Image/Image.ts b/packages/ui-extensions/src/surfaces/admin/components/Image/Image.ts index 24cef67134..fc373813ce 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Image/Image.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Image/Image.ts @@ -5,6 +5,8 @@ import type {AccessibilityRole} from '../shared'; * Props for the Image component. Requires either `accessibilityLabel` * or `alt` for alternative text, and either `source` or `src` for the * image URL. + * + * @publicDocs */ export type ImageProps = (ImageAccessibilityLabelProp | ImageAltProp) & (ImageSourceProp | ImageSrcProp) & diff --git a/packages/ui-extensions/src/surfaces/admin/components/InlineStack/InlineStack.ts b/packages/ui-extensions/src/surfaces/admin/components/InlineStack/InlineStack.ts index d20c2d9238..6bad540687 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/InlineStack/InlineStack.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/InlineStack/InlineStack.ts @@ -15,6 +15,8 @@ import { * Props for the InlineStack component, a horizontal layout container that * arranges children in a row along the inline axis. Inherits accessibility, * sizing, padding, and gap props from shared utilities. + * + * @publicDocs */ export interface InlineStackProps extends AccessibilityRoleProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/Link/Link.ts b/packages/ui-extensions/src/surfaces/admin/components/Link/Link.ts index 997561da6c..c63ac73dad 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Link/Link.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Link/Link.ts @@ -5,6 +5,8 @@ import {AccessibilityLabelProps} from '../shared'; * Props for the Link component, an interactive text element that navigates * to a URL or triggers an action when pressed. Inherits accessibility * label support from `AccessibilityLabelProps`. + * + * @publicDocs */ export interface LinkProps extends AccessibilityLabelProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/MoneyField/MoneyField.ts b/packages/ui-extensions/src/surfaces/admin/components/MoneyField/MoneyField.ts index b79fe58830..2aae9b069a 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/MoneyField/MoneyField.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/MoneyField/MoneyField.ts @@ -11,6 +11,8 @@ import type { * Props for the MoneyField component, a specialized input for entering * monetary values. It extends standard input props with number constraints * and autocomplete support for transaction amounts. + * + * @publicDocs */ export interface MoneyFieldProps extends InputProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/NumberField/NumberField.ts b/packages/ui-extensions/src/surfaces/admin/components/NumberField/NumberField.ts index b175d3a54b..216f7f75ae 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/NumberField/NumberField.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/NumberField/NumberField.ts @@ -13,6 +13,8 @@ import { * Props for the NumberField component, a text input for numeric values. * Inherits standard input props, number constraints (min, max, step), * autocomplete support, and field decoration props. + * + * @publicDocs */ export interface NumberFieldProps extends InputProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/Paragraph/Paragraph.ts b/packages/ui-extensions/src/surfaces/admin/components/Paragraph/Paragraph.ts index faefa7bd72..8da21aa71e 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Paragraph/Paragraph.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Paragraph/Paragraph.ts @@ -5,6 +5,8 @@ import type {BaseTypographyProps, GlobalProps} from '../shared'; * Props for the Paragraph component, which renders a block of text * as a distinct paragraph. Use Paragraph to structure your content * into readable sections with appropriate spacing. + * + * @publicDocs */ export interface ParagraphProps extends BaseTypographyProps, GlobalProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/PasswordField/PasswordField.ts b/packages/ui-extensions/src/surfaces/admin/components/PasswordField/PasswordField.ts index 496ea7af12..24b18e7f92 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/PasswordField/PasswordField.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/PasswordField/PasswordField.ts @@ -11,6 +11,8 @@ import { * content for secure entry of sensitive values like passwords or PINs. * It extends standard input props with min/max length constraints and * autocomplete support for password managers. + * + * @publicDocs */ export interface PasswordFieldProps extends InputProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/Pressable/Pressable.ts b/packages/ui-extensions/src/surfaces/admin/components/Pressable/Pressable.ts index a10c5cf35b..75ef219d0c 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Pressable/Pressable.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Pressable/Pressable.ts @@ -7,6 +7,8 @@ import type {BoxProps} from '../Box/Box'; * of Box with the interactive behavior of Link. Use Pressable when you * need a custom interactive area that can navigate to a URL or respond to * press events while supporting flexible layout and styling options. + * + * @publicDocs */ export interface PressableProps extends BoxProps, LinkProps {} diff --git a/packages/ui-extensions/src/surfaces/admin/components/ProgressIndicator/ProgressIndicator.ts b/packages/ui-extensions/src/surfaces/admin/components/ProgressIndicator/ProgressIndicator.ts index 2860899019..8f94cde6ed 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/ProgressIndicator/ProgressIndicator.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/ProgressIndicator/ProgressIndicator.ts @@ -6,6 +6,8 @@ import {GlobalProps, SizeScale, AccessibilityLabelProps} from '../shared'; * (such as a spinner) to communicate that a process is underway. Use this * component to reassure users that content is loading or an action is being * processed. + * + * @publicDocs */ export interface ProgressIndicatorProps extends GlobalProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/Section/Section.ts b/packages/ui-extensions/src/surfaces/admin/components/Section/Section.ts index ff742c1e6f..99b720f93b 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Section/Section.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Section/Section.ts @@ -5,6 +5,8 @@ import {createRemoteComponent} from '@remote-ui/core'; * optional heading. Sections provide both visual and semantic structure, * making it easier for users (and assistive technologies) to navigate * through distinct areas of an extension. + * + * @publicDocs */ export interface SectionProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/Select/Select.ts b/packages/ui-extensions/src/surfaces/admin/components/Select/Select.ts index 407613b2f4..4ae4e685a1 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Select/Select.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Select/Select.ts @@ -3,6 +3,8 @@ import {createRemoteComponent} from '@remote-ui/core'; /** * Props for the Select component, a form control that lets the user choose * one value from a predefined list of options presented in a dropdown menu. + * + * @publicDocs */ export interface SelectProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/Text/Text.ts b/packages/ui-extensions/src/surfaces/admin/components/Text/Text.ts index 93e26dacd7..659812b79a 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/Text/Text.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/Text/Text.ts @@ -11,6 +11,8 @@ import type { * Props for the Text component, an inline element for rendering and styling * a run of text. Use Text to apply typographic treatments such as font * weight, style, variant, and overflow behavior to a portion of content. + * + * @publicDocs */ export interface TextProps { /** diff --git a/packages/ui-extensions/src/surfaces/admin/components/TextArea/TextArea.ts b/packages/ui-extensions/src/surfaces/admin/components/TextArea/TextArea.ts index 73fa1c12db..aebb540473 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/TextArea/TextArea.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/TextArea/TextArea.ts @@ -11,6 +11,8 @@ import { * Props for the TextArea component, a multi-line text input for entering * longer-form content such as descriptions, comments, or notes. It extends * standard input props with min/max length constraints and autocomplete support. + * + * @publicDocs */ export interface TextAreaProps extends InputProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/TextField/TextField.ts b/packages/ui-extensions/src/surfaces/admin/components/TextField/TextField.ts index 81228cd1c2..f5acf65412 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/TextField/TextField.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/TextField/TextField.ts @@ -12,6 +12,8 @@ import { * short-form content such as names, emails, or search queries. It extends * standard input props with min/max length constraints, autocomplete support, * and a field decoration option (suffix). + * + * @publicDocs */ export interface TextFieldProps extends InputProps, diff --git a/packages/ui-extensions/src/surfaces/admin/components/URLField/URLField.ts b/packages/ui-extensions/src/surfaces/admin/components/URLField/URLField.ts index 475bf992b2..b38d91d223 100644 --- a/packages/ui-extensions/src/surfaces/admin/components/URLField/URLField.ts +++ b/packages/ui-extensions/src/surfaces/admin/components/URLField/URLField.ts @@ -12,6 +12,8 @@ import { * Props for the URLField component, a text input optimized for entering * URLs. It extends standard input props with min/max length constraints * and autocomplete support for URL-related fields. + * + * @publicDocs */ export interface URLFieldProps extends InputProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/format-suggestion.ts b/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/format-suggestion.ts index f0816945db..2c61808db0 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/format-suggestion.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/format-suggestion.ts @@ -3,6 +3,7 @@ import type { AutocompleteAddress, } from './shared'; +/** @publicDocs */ export interface AddressAutocompleteFormatSuggestionApi { /** * The autocomplete suggestion that the buyer selected during checkout. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/standard.ts b/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/standard.ts index 41be950399..d31b03ca30 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/standard.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/standard.ts @@ -24,6 +24,7 @@ import type { Timezone, } from '../../../../shared'; +/** @publicDocs */ export interface AddressAutocompleteStandardApi< Target extends | 'purchase.address-autocomplete.suggest' diff --git a/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/suggest.ts b/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/suggest.ts index 5a147d1272..76d3e298ac 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/suggest.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/address-autocomplete/suggest.ts @@ -2,6 +2,7 @@ import type {CountryCode} from '../../../checkout'; import type {AddressAutocompleteSuggestion} from './shared'; +/** @publicDocs */ export interface AddressAutocompleteSuggestApi { /** * The signal that the extension should listen to for cancellation requests. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/cart-line/cart-line-item.ts b/packages/ui-extensions/src/surfaces/checkout/api/cart-line/cart-line-item.ts index 85eaf26bdc..06bafa711b 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/cart-line/cart-line-item.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/cart-line/cart-line-item.ts @@ -2,6 +2,7 @@ import type {StatefulRemoteSubscribable} from '@remote-ui/async-subscription'; import type {CartLine} from '../standard/standard'; +/** @publicDocs */ export interface CartLineItemApi { /** * The cart line the extension is attached to. Until version `2023-04`, this property was a `StatefulRemoteSubscribable`. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/checkout/checkout.ts b/packages/ui-extensions/src/surfaces/checkout/api/checkout/checkout.ts index 8dd7cfebde..f2082c341a 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/checkout/checkout.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/checkout/checkout.ts @@ -511,6 +511,7 @@ export type ShippingAddressChangeResult = | ShippingAddressChangeResultSuccess | ShippingAddressChangeResultError; +/** @publicDocs */ export interface CheckoutApi { /** * Performs an update on an attribute attached to the cart and checkout. If diff --git a/packages/ui-extensions/src/surfaces/checkout/api/docs.ts b/packages/ui-extensions/src/surfaces/checkout/api/docs.ts index 201f8a368b..a1a3645e95 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/docs.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/docs.ts @@ -10,96 +10,130 @@ import type {OrderStatusApi} from './order-status/order-status'; * Note: These are not exported as part of the package, they are only used for documentation purposes. */ +/** @publicDocs */ export interface Docs_Standard_AddressApi extends Pick {} +/** @publicDocs */ export interface Docs_Checkout_AddressApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_AttributesApi extends Pick {} +/** @publicDocs */ export interface Docs_Checkout_AttributesApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_BuyerIdentityApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_BuyerJourneyApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_CartInstructionsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_CartLinesApi extends Pick {} +/** @publicDocs */ export interface Docs_Checkout_CartLinesApi extends Pick {} +/** @publicDocs */ export interface Docs_CartLineItem_CartLinesApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_CostApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_LocalizationApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_MetafieldsApi extends Pick {} +/** @publicDocs */ export interface Docs_Checkout_MetafieldsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_DeliveryApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_CheckoutTokenApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_ExtensionMetaApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_CheckoutSettingsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_ShopApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_NoteApi extends Pick {} +/** @publicDocs */ export interface Docs_Checkout_NoteApi extends Pick {} +/** @publicDocs */ export interface Docs_OrderStatus_OrderApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_PaymentOptionsApi extends Pick< StandardApi, 'availablePaymentOptions' | 'selectedPaymentOptions' > {} +/** @publicDocs */ export interface Docs_Standard_GiftCardsApi extends Pick {} +/** @publicDocs */ export interface Docs_Checkout_GiftCardsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_DiscountsApi extends Pick {} +/** @publicDocs */ export interface Docs_Checkout_DiscountsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_SessionTokenApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_SettingsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_StorageApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_QueryApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_AnalyticsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_CustomerPrivacyApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_Ui extends Pick {} diff --git a/packages/ui-extensions/src/surfaces/checkout/api/order-confirmation/order-confirmation.ts b/packages/ui-extensions/src/surfaces/checkout/api/order-confirmation/order-confirmation.ts index 69cc033bf9..5e765b2008 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/order-confirmation/order-confirmation.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/order-confirmation/order-confirmation.ts @@ -14,6 +14,7 @@ export interface OrderConfirmation { number?: string; } +/** @publicDocs */ export interface OrderConfirmationApi { /** * Order information that's available post-checkout. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/order-status/order-status.ts b/packages/ui-extensions/src/surfaces/checkout/api/order-status/order-status.ts index 03c951ea9b..e9764a9e49 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/order-status/order-status.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/order-status/order-status.ts @@ -30,6 +30,7 @@ export interface Order { confirmationNumber?: string; } +/** @publicDocs */ export interface OrderStatusApi { /** * Order information that's available post-checkout. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-item.ts b/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-item.ts index 74888fca1d..7b9eced6e4 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-item.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-item.ts @@ -2,6 +2,7 @@ import type {StatefulRemoteSubscribable} from '@remote-ui/async-subscription'; import type {PickupLocationOption} from '../standard/standard'; +/** @publicDocs */ export interface PickupLocationItemApi { /** * The pickup location the extension is attached to. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-list.ts b/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-list.ts index d61c1d0370..51e44ba03f 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-list.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-location-list.ts @@ -1,5 +1,6 @@ import type {StatefulRemoteSubscribable} from '@remote-ui/async-subscription'; +/** @publicDocs */ export interface PickupLocationListApi { /** * Whether the customer location input form is shown to the buyer. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-point-list.ts b/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-point-list.ts index 1f943fe3d8..ff84681e08 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-point-list.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/pickup/pickup-point-list.ts @@ -1,5 +1,6 @@ import type {StatefulRemoteSubscribable} from '@remote-ui/async-subscription'; +/** @publicDocs */ export interface PickupPointListApi { /** * Whether the customer location input form is shown to the buyer. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-item.ts b/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-item.ts index 6738b79f6f..2283000e32 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-item.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-item.ts @@ -2,6 +2,7 @@ import type {StatefulRemoteSubscribable} from '@remote-ui/async-subscription'; import type {ShippingOption} from '../standard/standard'; +/** @publicDocs */ export interface ShippingOptionItemApi { /** * The shipping option the extension is attached to. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-list.ts b/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-list.ts index 222da91e8e..435d666cda 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-list.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/shipping/shipping-option-list.ts @@ -7,6 +7,7 @@ import type { Money, } from '../standard/standard'; +/** @publicDocs */ export interface ShippingOptionListApi { /** * The delivery group list the extension is attached to. The target will be undefined when there are no groups for a given type. diff --git a/packages/ui-extensions/src/surfaces/checkout/api/standard/standard.ts b/packages/ui-extensions/src/surfaces/checkout/api/standard/standard.ts index dd510078e8..2acba0854c 100644 --- a/packages/ui-extensions/src/surfaces/checkout/api/standard/standard.ts +++ b/packages/ui-extensions/src/surfaces/checkout/api/standard/standard.ts @@ -481,6 +481,7 @@ export interface BuyerJourneyStep { disabled: boolean; } +/** @publicDocs */ export interface StandardApi { /** * The methods for interacting with [Web Pixels](https://shopify.dev/docs/apps/marketing), such as emitting an event. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Badge/Badge.ts b/packages/ui-extensions/src/surfaces/checkout/components/Badge/Badge.ts index a2bd251c4d..efbd8175fa 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Badge/Badge.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Badge/Badge.ts @@ -5,6 +5,7 @@ import type {IconSource} from '../Icon/Icon'; type Tone = 'default' | 'critical' | 'subdued'; +/** @publicDocs */ export interface BadgeProps extends VisibilityProps { /** * The tone of the badge being rendered. Indicates its level of importance, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Banner/Banner.ts b/packages/ui-extensions/src/surfaces/checkout/components/Banner/Banner.ts index d7ba23df22..a93762fef4 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Banner/Banner.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Banner/Banner.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps, Status} from '../shared'; +/** @publicDocs */ export interface BannerProps extends IdProps { /** * Banners have an optional title. Use a title to grab the buyer’s attention diff --git a/packages/ui-extensions/src/surfaces/checkout/components/BlockLayout/BlockLayout.ts b/packages/ui-extensions/src/surfaces/checkout/components/BlockLayout/BlockLayout.ts index abffe082d8..6afe558c6c 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/BlockLayout/BlockLayout.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/BlockLayout/BlockLayout.ts @@ -4,6 +4,7 @@ import type {MaybeResponsiveConditionalStyle} from '../../style/types'; import type {Rows} from '../shared'; import type {GridProps} from '../Grid/Grid'; +/** @publicDocs */ export interface BlockLayoutProps extends Omit { /** * Sizes for each row of the layout. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/BlockSpacer/BlockSpacer.ts b/packages/ui-extensions/src/surfaces/checkout/components/BlockSpacer/BlockSpacer.ts index e17ff536d0..abfaa0f101 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/BlockSpacer/BlockSpacer.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/BlockSpacer/BlockSpacer.ts @@ -3,6 +3,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {MaybeResponsiveConditionalStyle} from '../../style/types'; import type {IdProps, Spacing} from '../shared'; +/** @publicDocs */ export interface BlockSpacerProps extends IdProps { /** * Adjust size of the spacer diff --git a/packages/ui-extensions/src/surfaces/checkout/components/BlockStack/BlockStack.ts b/packages/ui-extensions/src/surfaces/checkout/components/BlockStack/BlockStack.ts index d1a067f700..0d01fbcc9b 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/BlockStack/BlockStack.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/BlockStack/BlockStack.ts @@ -13,6 +13,7 @@ import type { } from '../shared'; import type {MaybeResponsiveConditionalStyle} from '../../style/types'; +/** @publicDocs */ export interface BlockStackProps extends Pick, BorderProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Button/Button.ts b/packages/ui-extensions/src/surfaces/checkout/components/Button/Button.ts index d097833bd3..3e19513716 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Button/Button.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Button/Button.ts @@ -9,6 +9,7 @@ import type { DisclosureActivatorProps, } from '../shared'; +/** @publicDocs */ export interface ButtonProps extends OverlayActivatorProps, DisclosureActivatorProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Chat/Chat.ts b/packages/ui-extensions/src/surfaces/checkout/components/Chat/Chat.ts index 0ec0fce420..1b1c0da255 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Chat/Chat.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Chat/Chat.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps} from '../shared'; +/** @publicDocs */ export interface ChatProps extends IdProps { /** * Adjust the inline size. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Checkbox/Checkbox.ts b/packages/ui-extensions/src/surfaces/checkout/components/Checkbox/Checkbox.ts index 9a2277338f..8e2148b7e1 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Checkbox/Checkbox.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Checkbox/Checkbox.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {DisclosureActivatorProps} from '../shared'; +/** @publicDocs */ export interface CheckboxProps extends DisclosureActivatorProps { /** * A unique identifier for the field. When no `id` is set, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Choice/Choice.ts b/packages/ui-extensions/src/surfaces/checkout/components/Choice/Choice.ts index c9bebf1e97..d26c538ffc 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Choice/Choice.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Choice/Choice.ts @@ -1,6 +1,7 @@ import type {RemoteFragment} from '@remote-ui/core'; import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface ChoiceProps { /** * A unique identifier for the choice. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ChoiceList/ChoiceList.ts b/packages/ui-extensions/src/surfaces/checkout/components/ChoiceList/ChoiceList.ts index 15262660c8..99cc119455 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ChoiceList/ChoiceList.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ChoiceList/ChoiceList.ts @@ -1,5 +1,6 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface ChoiceListProps { /** * A unique identifier for the field in the closest `Form` component. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ConsentCheckbox/ConsentCheckbox.ts b/packages/ui-extensions/src/surfaces/checkout/components/ConsentCheckbox/ConsentCheckbox.ts index 64994557c1..b7b5e98deb 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ConsentCheckbox/ConsentCheckbox.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ConsentCheckbox/ConsentCheckbox.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {CheckboxProps} from '../Checkbox/Checkbox'; +/** @publicDocs */ export interface ConsentCheckboxProps extends Omit { /** * The policy for which buyer consent is being collected for. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ConsentPhoneField/ConsentPhoneField.ts b/packages/ui-extensions/src/surfaces/checkout/components/ConsentPhoneField/ConsentPhoneField.ts index 217259e8ef..654d2a1c2a 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ConsentPhoneField/ConsentPhoneField.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ConsentPhoneField/ConsentPhoneField.ts @@ -4,6 +4,7 @@ import type {PhoneFieldProps} from '../PhoneField/PhoneField'; export type ConsentPolicy = 'sms-marketing'; +/** @publicDocs */ export interface ConsentPhoneFieldProps extends Omit { /** * The policy for which buyer consent is being collected for. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/DateField/DateField.ts b/packages/ui-extensions/src/surfaces/checkout/components/DateField/DateField.ts index 235182597e..308ea76720 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/DateField/DateField.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/DateField/DateField.ts @@ -3,6 +3,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {DatePickerProps, SelectedDate} from '../DatePicker/DatePicker'; import type {TextFieldProps} from '../TextField/TextField'; +/** @publicDocs */ export interface DateFieldProps extends Pick< TextFieldProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/DatePicker/DatePicker.ts b/packages/ui-extensions/src/surfaces/checkout/components/DatePicker/DatePicker.ts index e4e36e43bd..4f3671fb42 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/DatePicker/DatePicker.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/DatePicker/DatePicker.ts @@ -28,6 +28,7 @@ export type YearMonth = {year: number; month: number} | YearMonthString; export type SelectedDate = DateString | DateString[] | DateRange; export type DisabledDate = DateString | DateRange | DayString; +/** @publicDocs */ export interface DatePickerProps { /** * [Controlled](https://reactjs.org/docs/forms.html#controlled-components) year and month to display. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Disclosure/Disclosure.ts b/packages/ui-extensions/src/surfaces/checkout/components/Disclosure/Disclosure.ts index 01611775f4..b2114b662d 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Disclosure/Disclosure.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Disclosure/Disclosure.ts @@ -3,6 +3,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {MaybeResponsiveConditionalStyle} from '../../style/types'; import type {DisclosureOpen} from '../shared'; +/** @publicDocs */ export interface DisclosureProps { /** * For uncontrolled disclosure components, the default `open` state on the initial render. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Divider/Divider.ts b/packages/ui-extensions/src/surfaces/checkout/components/Divider/Divider.ts index 8cf24c3e51..0c6ff2dfee 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Divider/Divider.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Divider/Divider.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {Alignment, Direction, IdProps, Size} from '../shared'; +/** @publicDocs */ export interface DividerProps extends IdProps { /** * Use to create dividers with varying widths. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Form/Form.ts b/packages/ui-extensions/src/surfaces/checkout/components/Form/Form.ts index 904ca9dec9..0c31622a08 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Form/Form.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Form/Form.ts @@ -1,5 +1,6 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface FormProps { /** * Whether the form is able to be submitted. When set to `true`, this will diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Grid/Grid.ts b/packages/ui-extensions/src/surfaces/checkout/components/Grid/Grid.ts index 9ae4925f4c..81b2062d42 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Grid/Grid.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Grid/Grid.ts @@ -16,6 +16,7 @@ import type { ViewLikeAccessibilityRole, } from '../shared'; +/** @publicDocs */ export interface GridProps extends Pick, IdProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/GridItem/GridItem.ts b/packages/ui-extensions/src/surfaces/checkout/components/GridItem/GridItem.ts index 7bfeae4390..c5c5447078 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/GridItem/GridItem.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/GridItem/GridItem.ts @@ -11,6 +11,7 @@ import type { ViewLikeAccessibilityRole, } from '../shared'; +/** @publicDocs */ export interface GridItemProps extends Pick, BorderProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Heading/Heading.ts b/packages/ui-extensions/src/surfaces/checkout/components/Heading/Heading.ts index 539f4af86f..9df3bfe129 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Heading/Heading.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Heading/Heading.ts @@ -4,6 +4,7 @@ import type {InlineAlignment, AccessibilityRole} from '../shared'; type Level = 1 | 2 | 3 | 4; +/** @publicDocs */ export interface HeadingProps { /** * Unique identifier. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/HeadingGroup/HeadingGroup.ts b/packages/ui-extensions/src/surfaces/checkout/components/HeadingGroup/HeadingGroup.ts index 0fb8e04f1c..0959fa1a9c 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/HeadingGroup/HeadingGroup.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/HeadingGroup/HeadingGroup.ts @@ -1,5 +1,6 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface HeadingGroupProps {} /** diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Icon/Icon.ts b/packages/ui-extensions/src/surfaces/checkout/components/Icon/Icon.ts index 793ee72ab9..d88b5f5fa1 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Icon/Icon.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Icon/Icon.ts @@ -75,6 +75,7 @@ export type IconSource = | 'warning' | 'warningFill'; +/** @publicDocs */ export interface IconProps extends IdProps { /** * A label that describes the purpose or contents of the icon. When set, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Image/Image.ts b/packages/ui-extensions/src/surfaces/checkout/components/Image/Image.ts index e347d90919..379dc69fff 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Image/Image.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Image/Image.ts @@ -15,6 +15,7 @@ import type { IdProps, } from '../shared'; +/** @publicDocs */ export interface ImageProps extends BorderProps, CornerProps, IdProps { /** * The URL of the image. Supports the `resolution` and `viewportInlineSize` conditional styles only. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/InlineLayout/InlineLayout.ts b/packages/ui-extensions/src/surfaces/checkout/components/InlineLayout/InlineLayout.ts index 77dc4b7637..6b2e2d3b05 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/InlineLayout/InlineLayout.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/InlineLayout/InlineLayout.ts @@ -10,6 +10,7 @@ import type { } from '../shared'; import type {GridProps} from '../Grid/Grid'; +/** @publicDocs */ export interface InlineLayoutProps extends Omit, BorderProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/InlineSpacer/InlineSpacer.ts b/packages/ui-extensions/src/surfaces/checkout/components/InlineSpacer/InlineSpacer.ts index 4adc233268..c7aeaa0b34 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/InlineSpacer/InlineSpacer.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/InlineSpacer/InlineSpacer.ts @@ -3,6 +3,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {MaybeResponsiveConditionalStyle} from '../../style/types'; import type {IdProps, Spacing} from '../shared'; +/** @publicDocs */ export interface InlineSpacerProps extends IdProps { /** * Adjust size of the spacer diff --git a/packages/ui-extensions/src/surfaces/checkout/components/InlineStack/InlineStack.ts b/packages/ui-extensions/src/surfaces/checkout/components/InlineStack/InlineStack.ts index b31145187f..eb0816c2cf 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/InlineStack/InlineStack.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/InlineStack/InlineStack.ts @@ -14,6 +14,7 @@ import type { ViewLikeAccessibilityRole, } from '../shared'; +/** @publicDocs */ export interface InlineStackProps extends Pick, BorderProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Link/Link.ts b/packages/ui-extensions/src/surfaces/checkout/components/Link/Link.ts index 47db56a128..cdef94fc3e 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Link/Link.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Link/Link.ts @@ -6,6 +6,7 @@ import type { DisclosureActivatorProps, } from '../shared'; +/** @publicDocs */ export interface LinkProps extends OverlayActivatorProps, DisclosureActivatorProps { diff --git a/packages/ui-extensions/src/surfaces/checkout/components/List/List.ts b/packages/ui-extensions/src/surfaces/checkout/components/List/List.ts index 60838f2bba..7f8e7d1674 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/List/List.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/List/List.ts @@ -5,6 +5,7 @@ import type {MaybeResponsiveConditionalStyle} from '../../style/types'; export type Marker = 'none' | 'bullet' | 'number'; +/** @publicDocs */ export interface ListProps extends IdProps { /** * Adjust spacing between list items diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ListItem/ListItem.ts b/packages/ui-extensions/src/surfaces/checkout/components/ListItem/ListItem.ts index a2bb3c4ed4..7e0aa3434c 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ListItem/ListItem.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ListItem/ListItem.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps} from '../shared'; +/** @publicDocs */ export interface ListItemProps extends IdProps {} /** diff --git a/packages/ui-extensions/src/surfaces/checkout/components/LoginWithShop/LoginWithShop.ts b/packages/ui-extensions/src/surfaces/checkout/components/LoginWithShop/LoginWithShop.ts index cb312db232..04d0748514 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/LoginWithShop/LoginWithShop.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/LoginWithShop/LoginWithShop.ts @@ -1,5 +1,6 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface LoginWithShopProps { open: boolean; openLogin?: boolean; diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Map/Map.ts b/packages/ui-extensions/src/surfaces/checkout/components/Map/Map.ts index 761950d5e2..1430afd675 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Map/Map.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Map/Map.ts @@ -31,6 +31,7 @@ export interface MapBounds { northEast: MapLocation; southWest: MapLocation; } +/** @publicDocs */ export interface MapProps extends Pick< SizingProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/MapMarker/MapMarker.ts b/packages/ui-extensions/src/surfaces/checkout/components/MapMarker/MapMarker.ts index da70a000e2..e318742502 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/MapMarker/MapMarker.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/MapMarker/MapMarker.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {OverlayActivatorProps} from '../shared'; +/** @publicDocs */ export interface MapMarkerProps extends OverlayActivatorProps { /** * The latitude of the marker. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/MapPopover/MapPopover.ts b/packages/ui-extensions/src/surfaces/checkout/components/MapPopover/MapPopover.ts index 1525d0be3f..66e04db46f 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/MapPopover/MapPopover.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/MapPopover/MapPopover.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps} from '../shared'; +/** @publicDocs */ export interface MapPopoverProps extends IdProps { /** * Callback to run when the Popover is closed. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Modal/Modal.ts b/packages/ui-extensions/src/surfaces/checkout/components/Modal/Modal.ts index c68a0cda21..7ce0eb33ec 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Modal/Modal.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Modal/Modal.ts @@ -1,6 +1,7 @@ import type {RemoteFragment} from '@remote-ui/core'; import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface ModalProps { /** * A unique identifier for the Modal. When no `id` is set, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/PaymentIcon/PaymentIcon.ts b/packages/ui-extensions/src/surfaces/checkout/components/PaymentIcon/PaymentIcon.ts index 6c5d838748..c5788eff1a 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/PaymentIcon/PaymentIcon.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/PaymentIcon/PaymentIcon.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; // Copied from https://github.com/Shopify/ui-api-design/blob/main/components/PaymentIcon/PaymentIcon.ts // NOTE: Add new entries to the PaymentMethod type in alphabetical order +/** @publicDocs */ export type PaymentMethod = | '7-eleven' | 'acima-leasing' @@ -448,6 +449,7 @@ export type PaymentMethod = | 'zip' | 'zoodpay'; +/** @publicDocs */ export interface PaymentIconProps { /** * The name of the payment method. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/PhoneField/PhoneField.ts b/packages/ui-extensions/src/surfaces/checkout/components/PhoneField/PhoneField.ts index 1bbe6a6a1c..8ad6f5b8a9 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/PhoneField/PhoneField.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/PhoneField/PhoneField.ts @@ -4,6 +4,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {Autocomplete} from '../shared'; import type {IconSource} from '../Icon/Icon'; +/** @publicDocs */ export interface PhoneFieldProps { /** * Any content to render at the end of the text field. Commonly used diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Popover/Popover.ts b/packages/ui-extensions/src/surfaces/checkout/components/Popover/Popover.ts index ba7b7d703e..df502d4d8c 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Popover/Popover.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Popover/Popover.ts @@ -8,6 +8,7 @@ export type PopoverPosition = | 'blockStart' | 'blockEnd'; +/** @publicDocs */ export interface PopoverProps extends IdProps, Pick, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Pressable/Pressable.ts b/packages/ui-extensions/src/surfaces/checkout/components/Pressable/Pressable.ts index 39dac4ea96..752b78797a 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Pressable/Pressable.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Pressable/Pressable.ts @@ -17,6 +17,7 @@ import type { IdProps, } from '../shared'; +/** @publicDocs */ export interface PressableProps extends Pick, BorderProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ProductThumbnail/ProductThumbnail.ts b/packages/ui-extensions/src/surfaces/checkout/components/ProductThumbnail/ProductThumbnail.ts index ffc1b30406..a4cdd34766 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ProductThumbnail/ProductThumbnail.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ProductThumbnail/ProductThumbnail.ts @@ -6,6 +6,7 @@ import type { } from '../../style/types'; import type {Size} from '../shared'; +/** @publicDocs */ export interface ProductThumbnailProps { /** * An alternative text description that describe the image for the reader to diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Progress/Progress.ts b/packages/ui-extensions/src/surfaces/checkout/components/Progress/Progress.ts index c89b299cb2..1830886840 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Progress/Progress.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Progress/Progress.ts @@ -4,6 +4,7 @@ import type {IdProps} from '../shared'; type Tone = 'auto' | 'critical'; +/** @publicDocs */ export interface ProgressProps extends IdProps { /** * Specify how much of the task that has been completed. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/QRCode/QRCode.ts b/packages/ui-extensions/src/surfaces/checkout/components/QRCode/QRCode.ts index f4a83ec507..6ef23a4794 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/QRCode/QRCode.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/QRCode/QRCode.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps, BorderStyle} from '../shared'; +/** @publicDocs */ export interface QRCodeProps extends IdProps { /** * The content to be encoded in the QR code, which can be any string such as a URL, email address, plain text, etc. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ScrollView/ScrollView.ts b/packages/ui-extensions/src/surfaces/checkout/components/ScrollView/ScrollView.ts index a42a388e83..ef7f0ab62b 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ScrollView/ScrollView.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ScrollView/ScrollView.ts @@ -31,6 +31,7 @@ export interface ScrollViewEvent { }; } +/** @publicDocs */ export interface ScrollViewProps extends Pick, BorderProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Select/Select.ts b/packages/ui-extensions/src/surfaces/checkout/components/Select/Select.ts index 45cfed5aca..f53b901689 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Select/Select.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Select/Select.ts @@ -18,6 +18,7 @@ export interface SelectOptionProps { disabled?: boolean; } +/** @publicDocs */ export interface SelectProps { /** * A unique identifier for the field. When no `id` is set, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Sheet/Sheet.ts b/packages/ui-extensions/src/surfaces/checkout/components/Sheet/Sheet.ts index e08f16aeb6..8858a23c9a 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Sheet/Sheet.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Sheet/Sheet.ts @@ -3,6 +3,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps} from '../shared'; +/** @publicDocs */ export interface SheetProps extends IdProps { /** * A label to describe the purpose of the sheet that is announced by screen readers. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/SkeletonImage/SkeletonImage.ts b/packages/ui-extensions/src/surfaces/checkout/components/SkeletonImage/SkeletonImage.ts index b97ec589ec..483c58d021 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/SkeletonImage/SkeletonImage.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/SkeletonImage/SkeletonImage.ts @@ -3,6 +3,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {MaybeResponsiveConditionalStyle} from '../../style/types'; import type {IdProps} from '../shared'; +/** @publicDocs */ export interface SkeletonImageProps extends IdProps { /** * Adjust the block size of the skeleton. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/SkeletonText/SkeletonText.ts b/packages/ui-extensions/src/surfaces/checkout/components/SkeletonText/SkeletonText.ts index fc4feebeb3..38a660ada5 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/SkeletonText/SkeletonText.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/SkeletonText/SkeletonText.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps, TextSize, Size} from '../shared'; +/** @publicDocs */ export interface SkeletonTextProps extends IdProps { /** * @private diff --git a/packages/ui-extensions/src/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.ts b/packages/ui-extensions/src/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.ts index 28395abedf..bd293bea5f 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps, TextSize} from '../shared'; +/** @publicDocs */ export interface SkeletonTextBlockProps extends IdProps { /** * @private diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Spinner/Spinner.ts b/packages/ui-extensions/src/surfaces/checkout/components/Spinner/Spinner.ts index 88f36a4895..741892a588 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Spinner/Spinner.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Spinner/Spinner.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {Appearance, IdProps, Size} from '../shared'; +/** @publicDocs */ export interface SpinnerProps extends IdProps { /** * Adjusts the size of the icon. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Stepper/Stepper.ts b/packages/ui-extensions/src/surfaces/checkout/components/Stepper/Stepper.ts index 871fea1781..ba240ab094 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Stepper/Stepper.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Stepper/Stepper.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IconSource} from '../Icon/Icon'; +/** @publicDocs */ export interface StepperProps { /** * A detailed description for screen readers. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Switch/Switch.ts b/packages/ui-extensions/src/surfaces/checkout/components/Switch/Switch.ts index d180732901..8a816a2c93 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Switch/Switch.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Switch/Switch.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps, DisclosureActivatorProps} from '../shared'; +/** @publicDocs */ export interface SwitchProps extends IdProps, DisclosureActivatorProps { /** * An identifier for the field that is unique within the nearest diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Tag/Tag.ts b/packages/ui-extensions/src/surfaces/checkout/components/Tag/Tag.ts index a90db46a10..90a6821208 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Tag/Tag.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Tag/Tag.ts @@ -3,6 +3,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IconSource} from '../Icon/Icon'; import type {IdProps} from '../shared'; +/** @publicDocs */ export interface TagProps extends IdProps { children?: string; /** diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Text/Text.ts b/packages/ui-extensions/src/surfaces/checkout/components/Text/Text.ts index c57e84d5de..f0cfc0874b 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Text/Text.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Text/Text.ts @@ -8,6 +8,7 @@ import type { VisibilityProps, } from '../shared'; +/** @publicDocs */ export interface TextProps extends VisibilityProps { /** * Size of the text diff --git a/packages/ui-extensions/src/surfaces/checkout/components/TextBlock/TextBlock.ts b/packages/ui-extensions/src/surfaces/checkout/components/TextBlock/TextBlock.ts index efdd614173..6f12fca1ed 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/TextBlock/TextBlock.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/TextBlock/TextBlock.ts @@ -8,6 +8,7 @@ import type { TextSize, } from '../shared'; +/** @publicDocs */ export interface TextBlockProps extends IdProps { /** * Size of the text diff --git a/packages/ui-extensions/src/surfaces/checkout/components/TextField/TextField.ts b/packages/ui-extensions/src/surfaces/checkout/components/TextField/TextField.ts index 0665e59b2a..0b52b50624 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/TextField/TextField.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/TextField/TextField.ts @@ -6,6 +6,7 @@ import type {IconSource} from '../Icon/Icon'; type Type = 'text' | 'email' | 'number' | 'telephone'; +/** @publicDocs */ export interface TextFieldProps { /** * A unique identifier for the field. When no `id` is set, diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ToggleButton/ToggleButton.ts b/packages/ui-extensions/src/surfaces/checkout/components/ToggleButton/ToggleButton.ts index cd5e19aaaa..01029b26c5 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ToggleButton/ToggleButton.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ToggleButton/ToggleButton.ts @@ -1,5 +1,6 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface ToggleButtonProps { /** * A unique identifier for the toggle button. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/ToggleButtonGroup/ToggleButtonGroup.ts b/packages/ui-extensions/src/surfaces/checkout/components/ToggleButtonGroup/ToggleButtonGroup.ts index 8abe92e66d..89fe7f5805 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/ToggleButtonGroup/ToggleButtonGroup.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/ToggleButtonGroup/ToggleButtonGroup.ts @@ -1,5 +1,6 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** @publicDocs */ export interface ToggleButtonGroupProps { /** * An id of the selected button. diff --git a/packages/ui-extensions/src/surfaces/checkout/components/Tooltip/Tooltip.ts b/packages/ui-extensions/src/surfaces/checkout/components/Tooltip/Tooltip.ts index 27d0e7861a..b5899865dc 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/Tooltip/Tooltip.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/Tooltip/Tooltip.ts @@ -2,6 +2,7 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {IdProps} from '../shared'; +/** @publicDocs */ export interface TooltipProps extends IdProps {} /** diff --git a/packages/ui-extensions/src/surfaces/checkout/components/View/View.ts b/packages/ui-extensions/src/surfaces/checkout/components/View/View.ts index 70737ec334..2d35d6ccf5 100644 --- a/packages/ui-extensions/src/surfaces/checkout/components/View/View.ts +++ b/packages/ui-extensions/src/surfaces/checkout/components/View/View.ts @@ -125,6 +125,7 @@ export interface Translate { inline?: number | `${number}%`; } +/** @publicDocs */ export interface ViewProps extends Pick, BorderProps, diff --git a/packages/ui-extensions/src/surfaces/checkout/globals.ts b/packages/ui-extensions/src/surfaces/checkout/globals.ts index a478ec34f6..59501850fc 100644 --- a/packages/ui-extensions/src/surfaces/checkout/globals.ts +++ b/packages/ui-extensions/src/surfaces/checkout/globals.ts @@ -1,5 +1,8 @@ import type {ExtensionTargets} from './targets'; +/** + * @publicDocs + */ export interface ShopifyGlobal { extend( target: ExtensionTarget, diff --git a/packages/ui-extensions/src/surfaces/checkout/shared.ts b/packages/ui-extensions/src/surfaces/checkout/shared.ts index 464deddddf..159e2e88fa 100644 --- a/packages/ui-extensions/src/surfaces/checkout/shared.ts +++ b/packages/ui-extensions/src/surfaces/checkout/shared.ts @@ -2,7 +2,9 @@ import type {ComponentsBuilder, AnyComponentBuilder} from '../../shared'; import type * as ComponentsModule from './components'; +/** @publicDocs */ export type Components = ComponentsBuilder; +/** @publicDocs */ export type AnyComponent = AnyComponentBuilder; export type AllowedComponents = diff --git a/packages/ui-extensions/src/surfaces/checkout/style/style.ts b/packages/ui-extensions/src/surfaces/checkout/style/style.ts index fd6a84dd47..d78ffd6936 100644 --- a/packages/ui-extensions/src/surfaces/checkout/style/style.ts +++ b/packages/ui-extensions/src/surfaces/checkout/style/style.ts @@ -88,6 +88,7 @@ const when: WhenFunction = function when< // This interface is only used to provide documentation for the Style helper. // It is not used in the implementation. +/** @publicDocs */ export interface DocsStyle { /** * Sets an optional default value to use when no other condition is met. diff --git a/packages/ui-extensions/src/surfaces/checkout/targets.ts b/packages/ui-extensions/src/surfaces/checkout/targets.ts index 079d8bea22..410b8e1a44 100644 --- a/packages/ui-extensions/src/surfaces/checkout/targets.ts +++ b/packages/ui-extensions/src/surfaces/checkout/targets.ts @@ -32,6 +32,8 @@ import type { * and is expected to return a value in a specific shape. * The input arguments and the output type are different * for each extension target. + * + * @publicDocs */ export interface RenderExtensionTargets { /** @@ -743,6 +745,7 @@ export interface RenderExtensionTargets { >; } +/** @publicDocs */ export interface RunnableExtensionTargets { /** * An extension target that provides address autocomplete suggestions. These suggestions are shown to buyers as they @@ -774,9 +777,11 @@ export interface RunnableExtensionTargets { >; } +/** @publicDocs */ export type ExtensionTargets = RenderExtensionTargets & RunnableExtensionTargets; +/** @publicDocs */ export type ExtensionTarget = keyof ExtensionTargets; export type AvailableExtensionDefinitions = @@ -786,6 +791,8 @@ export type AvailableExtensionDefinitions = /** * For a given extension target, returns the value that is expected to be * returned by that extension target’s callback type. + * + * @publicDocs */ export type ReturnTypeForExtension = ReturnType; @@ -793,6 +800,8 @@ export type ReturnTypeForExtension = /** * For a given extension target, returns the tuple of arguments that would * be provided to that extension target’s callback type. + * + * @publicDocs */ export type ArgumentsForExtension = Parameters; @@ -800,6 +809,8 @@ export type ArgumentsForExtension = /** * For a given extension target, returns the type of the API that the * extension will receive at runtime. + * + * @publicDocs */ export type ApiForExtension = ExtractedApiFromExtensionDefinition; @@ -812,11 +823,15 @@ type ExtractedApiFromExtensionDefinition = * accepting a [`@remote-ui/core` `RemoteRoot`](https://github.com/Shopify/remote-dom/tree/remote-ui/packages/core) * and an additional `api` argument, and using those arguments to render * UI. + * + * @publicDocs */ export type RenderExtensionTarget = keyof RenderExtensionTargets; /** * A mapping of each “render extension” name to its callback type. + * + * @publicDocs */ export type RenderExtensions = { [Target in RenderExtensionTarget]: RenderExtensionTargets[Target]; @@ -827,6 +842,8 @@ type ExtractedAllowedComponentsFromRenderExtension = /** * @deprecated Use `ExtractedApiFromExtensionDefinition` instead. + * + * @publicDocs */ type ExtractedApiFromRenderExtension = T extends RenderExtension< infer Api, @@ -844,6 +861,8 @@ type ExtractedApiFromRenderExtension = T extends RenderExtension< * extension targets each receive a `RemoteRoot` object. * * @deprecated Use `ApiForExtension` instead. + * + * @publicDocs */ export type ApiForRenderExtension = ExtractedApiFromRenderExtension; @@ -851,13 +870,17 @@ export type ApiForRenderExtension = /** * For a given rendering extension target, returns the UI components that the * extension target supports. + * + * @publicDocs */ export type AllowedComponentsForRenderExtension< Target extends keyof RenderExtensions, > = ExtractedAllowedComponentsFromRenderExtension; +/** @publicDocs */ export type RunnableExtensionTarget = keyof RunnableExtensionTargets; +/** @publicDocs */ export type RunnableExtensions = { [Target in RunnableExtensionTarget]: RunnableExtensionTargets[Target]; }; @@ -865,6 +888,8 @@ export type RunnableExtensions = { /** * The part of the standard API implemented for customer-account targets. Must * match the types defined in the `surfaces/customer-account` section of this package. + * + * @publicDocs */ export interface CustomerAccountStandardApi< Target extends keyof ExtensionTargets, diff --git a/packages/ui-extensions/src/surfaces/customer-account/api/docs.ts b/packages/ui-extensions/src/surfaces/customer-account/api/docs.ts index 071bf9a4bc..432d2dafa9 100644 --- a/packages/ui-extensions/src/surfaces/customer-account/api/docs.ts +++ b/packages/ui-extensions/src/surfaces/customer-account/api/docs.ts @@ -3,85 +3,129 @@ import {StandardApi} from './standard-api/standard-api'; import {CartLineItemApi} from './cart-line/cart-line-item'; import {FullPageApi} from '../targets'; import {ButtonProps} from '../components'; +import type {AuthenticatedAccount} from './shared'; +import type {I18n} from './shared'; +import type {NavigationHistoryEntry} from './standard-api/standard-api'; +/** @publicDocs */ +export type UseCustomerGeneratedType = AuthenticatedAccount['customer']; + +/** @publicDocs */ +export type UsePurchasingCompanyGeneratedType = + AuthenticatedAccount['purchasingCompany']; + +/** @publicDocs */ +export type UseTranslateGeneratedType = I18n; + +/** @publicDocs */ +export type UseApiGeneratedType = NavigationHistoryEntry; + +/** @publicDocs */ export interface Docs_OrderStatus_MetafieldsApi extends Pick, 'appMetafields' | 'metafields'> {} +/** @publicDocs */ export interface Docs_OrderStatus_AttributesApi extends Pick, 'attributes'> {} +/** @publicDocs */ export interface Docs_OrderStatus_BuyerIdentityApi extends Pick, 'buyerIdentity'> {} +/** @publicDocs */ export interface Docs_OrderStatus_CheckoutSettingsApi extends Pick, 'checkoutSettings'> {} +/** @publicDocs */ export interface Docs_OrderStatus_CostApi extends Pick, 'cost'> {} +/** @publicDocs */ export interface Docs_OrderStatus_LocalizationApi extends Pick, 'localization'> {} +/** @publicDocs */ export interface Docs_OrderStatus_DiscountsApi extends Pick, 'discountAllocations' | 'discountCodes'> {} +/** @publicDocs */ export interface Docs_OrderStatus_GiftCardsApi extends Pick, 'appliedGiftCards'> {} +/** @publicDocs */ export interface Docs_OrderStatus_NoteApi extends Pick, 'note'> {} +/** @publicDocs */ export interface Docs_OrderStatus_AddressApi extends Pick, 'shippingAddress' | 'billingAddress'> {} +/** @publicDocs */ export interface Docs_OrderStatus_ShopApi extends Pick, 'shop'> {} +/** @publicDocs */ export interface Docs_OrderStatus_RequireLoginApi extends Pick, 'requireLogin'> {} +/** @publicDocs */ export interface Docs_OrderStatus_AuthenticationStateApi extends Pick, 'authenticationState'> {} +/** @publicDocs */ export interface Docs_OrderStatus_CartLinesApi extends Pick, 'lines'> {} +/** @publicDocs */ export interface Docs_CartLineItem_CartLinesApi extends Pick {} +/** @publicDocs */ export interface Docs_OrderStatus_OrderApi extends Pick, 'order'> {} +/** @publicDocs */ export interface Docs_Standard_ExtensionApi extends Pick, 'extension'> {} +/** @publicDocs */ export interface Docs_Standard_AuthenticatedAccountApi extends Pick, 'authenticatedAccount'> {} +/** @publicDocs */ export interface Docs_Standard_VersionApi extends Pick, 'version'> {} +/** @publicDocs */ export interface Docs_Standard_LocalizationApi extends Pick, 'localization' | 'i18n'> {} +/** @publicDocs */ export interface Docs_Standard_SessionTokenApi extends Pick, 'sessionToken'> {} +/** @publicDocs */ export interface Docs_Standard_SettingsApi extends Pick {} +/** @publicDocs */ export interface Docs_Standard_StorageApi extends Pick, 'storage'> {} +/** @publicDocs */ export interface Docs_Standard_UIApi extends Pick, 'ui'> {} +/** @publicDocs */ export interface Docs_Standard_QueryApi extends Pick, 'query'> {} +/** @publicDocs */ export interface Docs_StandardApi extends Omit, 'router'> {} +/** @publicDocs */ export interface Docs_FullPageApi extends FullPageApi {} +/** @publicDocs */ export interface Docs_Page_Button_PrimaryAction extends Pick< ButtonProps, @@ -93,6 +137,7 @@ export interface Docs_Page_Button_PrimaryAction | 'disabled' | 'accessibilityLabel' > {} +/** @publicDocs */ export interface Docs_Page_Button_SecondaryAction extends Pick { /** @@ -101,6 +146,7 @@ export interface Docs_Page_Button_SecondaryAction accessibilityLabel: ButtonProps['accessibilityLabel']; } +/** @publicDocs */ export interface Docs_ResourceItem_Button_Action extends Pick< ButtonProps, @@ -114,12 +160,14 @@ export interface Docs_ResourceItem_Button_Action | 'kind' > {} +/** @publicDocs */ export interface Docs_Menu_Button_Action extends Omit< ButtonProps, 'kind' | 'textDecoration' | 'inlineAlignment' | 'inlineSize' | 'size' > {} +/** @publicDocs */ export interface Docs_OrderActionMenu_Button extends Pick< ButtonProps, @@ -133,6 +181,7 @@ export interface Docs_OrderActionMenu_Button to: ButtonProps['to']; } +/** @publicDocs */ export interface Docs_CustomerAccountAction_Button_PrimaryAction extends Pick< ButtonProps, @@ -144,6 +193,7 @@ export interface Docs_CustomerAccountAction_Button_PrimaryAction | 'accessibilityRole' > {} +/** @publicDocs */ export interface Docs_CustomerAccountAction_Button_SecondaryAction extends Pick< ButtonProps, diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/action-api/action-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/action-api/action-api.ts index 174c9269c3..d84b85446e 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/action-api/action-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/action-api/action-api.ts @@ -1,3 +1,8 @@ +/** + * The `ActionApi` object provides properties for presenting modal interfaces. Access these properties through `api.action` to launch full-screen modal experiences. + * + * @publicDocs + */ export interface ActionApiContent { /** * Presents the corresponding action (modal) target on top of the current view as a full-screen modal. For example, calling this method from `pos.purchase.post.action.menu-item.render` presents `pos.purchase.post.action.render`. Use to launch detailed workflows, complex forms, or multi-step processes that require more screen space than simple components provide. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/cart-api/cart-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/cart-api/cart-api.ts index ad80fcf40c..c6c2881955 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/cart-api/cart-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/cart-api/cart-api.ts @@ -36,6 +36,11 @@ export type CartDiscountType = 'Percentage' | 'FixedAmount' | 'Code'; */ export type LineItemDiscountType = 'Percentage' | 'FixedAmount'; +/** + * The `CartApi` object provides access to cart management and subscribable cart state. Access these properties through `api.cart` to build cart-aware extensions that respond to real-time cart updates. + * + * @publicDocs + */ export interface CartApiContent { /** * Subscribes to real-time cart state changes. Provides initial cart value and triggers callbacks on updates. Supports only one active subscription—use `makeStatefulSubscribable` for multiple subscribers. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/connectivity-api/connectivity-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/connectivity-api/connectivity-api.ts index ee9ce44204..54d8696331 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/connectivity-api/connectivity-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/connectivity-api/connectivity-api.ts @@ -16,6 +16,11 @@ export interface ConnectivityState { internetConnected: ConnectivityStateSeverity; } +/** + * The `ConnectivityApi` object provides properties for monitoring network connectivity. Access these properties through `api.connectivity` to check connection status and subscribe to connectivity changes. + * + * @publicDocs + */ export interface ConnectivityApiContent { /** * Creates a subscription to changes in connectivity. Provides an initial value and a callback to subscribe to value changes. Use for implementing offline-aware functionality and reactive connectivity handling. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/customer-api/customer-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/customer-api/customer-api.ts index 45ab2f03b2..cb754c53ee 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/customer-api/customer-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/customer-api/customer-api.ts @@ -5,6 +5,11 @@ export interface CustomerApi { customer: CustomerApiContent; } +/** + * The `CustomerApi` object provides access to customer data. Access these properties through `api.customer` to interact with the current customer context. + * + * @publicDocs + */ export interface CustomerApiContent { /** * The unique identifier for the customer. Use for customer lookups, applying customer-specific pricing, enabling personalized features, and integrating with external systems. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/device-api/device-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/device-api/device-api.ts index 945ca75340..665edc8090 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/device-api/device-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/device-api/device-api.ts @@ -1,3 +1,8 @@ +/** + * The `DeviceApi` object provides access to device information and capabilities. Access these properties through `api.device` to retrieve device details and check device characteristics. + * + * @publicDocs + */ export interface DeviceApiContent { /** * The name of the device as configured by the merchant or system. Use for displaying device information in interfaces, logging, or support contexts where device identification is helpful. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/draft-order-api/draft-order-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/draft-order-api/draft-order-api.ts index 2783f5e0d2..c66a58cdf1 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/draft-order-api/draft-order-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/draft-order-api/draft-order-api.ts @@ -5,6 +5,11 @@ export interface DraftOrderApi { draftOrder: DraftOrderApiContent; } +/** + * The `DraftOrderApi` object provides access to draft order data. Access these properties through `api.draftOrder` to interact with the current draft order context. + * + * @publicDocs + */ export interface DraftOrderApiContent { /** * The unique identifier for the draft order. Use for draft order lookups, implementing order-specific functionality, and integrating with external systems. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/locale-api/locale-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/locale-api/locale-api.ts index 08e79cdb02..30f864056b 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/locale-api/locale-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/locale-api/locale-api.ts @@ -1,5 +1,10 @@ import type {RemoteSubscribable} from '@remote-ui/async-subscription'; +/** + * The `LocaleApi` object provides access to current locale information and change notifications. Access these properties through `api.locale` to retrieve and monitor locale data. + * + * @publicDocs + */ export interface LocaleApiContent { /** * Provides the current IETF-formatted locale (for example, "en-US") and allows you to subscribe to locale changes. Supports only one subscription at a time. To enable multiple subscriptions, use `makeStatefulSubscribable` on the `RemoteSubscribable` object. Using `makeStatefulSubscribable` or related hooks counts as an active subscription. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/navigation-api/navigation-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/navigation-api/navigation-api.ts index 0b449e797e..5af477cb10 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/navigation-api/navigation-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/navigation-api/navigation-api.ts @@ -1,3 +1,8 @@ +/** + * The global `navigation` object provides web-standard navigation functionality. Access these properties directly through the global `navigation` object to manage navigation within modal interfaces. + * + * @publicDocs + */ export interface NavigationApiContent { /** * Navigate to a route in current navigation tree. Pushes the specified screen if it isn't present in the navigation tree, goes back to a created screen otherwise. Use for implementing multi-screen workflows with parameter passing between screens. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/order-api/order-api.tsx b/packages/ui-extensions/src/surfaces/point-of-sale/api/order-api/order-api.tsx index 00ec7002e1..6b2e561017 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/order-api/order-api.tsx +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/order-api/order-api.tsx @@ -5,6 +5,11 @@ export interface OrderApi { order: OrderApiContent; } +/** + * The `OrderApi` object provides access to order data. Access these properties through `api.order` to interact with the current order context. + * + * @publicDocs + */ export interface OrderApiContent { /** * The unique identifier for the order. Use for order lookups, implementing order-specific functionality, and integrating with external systems. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/product-api/product-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/product-api/product-api.ts index dbb53b9c31..2ce165b2f6 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/product-api/product-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/product-api/product-api.ts @@ -5,6 +5,11 @@ export interface ProductApi { product: ProductApiContent; } +/** + * The `ProductApi` object provides access to product data. Access these properties through `api.product` to interact with the current product context. + * + * @publicDocs + */ export interface ProductApiContent { /** * The unique identifier for the product. Use for product lookups, implementing product-specific functionality, and integrating with external systems. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/product-search-api/product-search-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/product-search-api/product-search-api.ts index bde49109ba..c4dbd8e127 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/product-search-api/product-search-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/product-search-api/product-search-api.ts @@ -41,6 +41,11 @@ export interface ProductSearchParams extends PaginationParams { sortType?: ProductSortType; } +/** + * The `ProductSearchApi` object provides properties for searching and fetching product data. Access these properties through `api.productSearch` to perform product searches and lookups. + * + * @publicDocs + */ export interface ProductSearchApiContent { /** * Searches for products on the POS device using text queries and sorting options. Returns paginated results with up to 50 products per page. When a query string is provided, results are sorted by relevance. Use for implementing custom search interfaces, product discovery features, or filtered product listings. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/scanner-api/scanner-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/scanner-api/scanner-api.ts index a9a0951e4d..8db424525f 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/scanner-api/scanner-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/scanner-api/scanner-api.ts @@ -23,6 +23,11 @@ export interface ScannerSubscriptionResult { source?: ScannerSource; } +/** + * The `ScannerApi` object provides access to scanning functionality and scanner source information. Access these properties through `api.scanner` to monitor scan events and available scanner sources. + * + * @publicDocs + */ export interface ScannerApiContent { /** * Subscribe to scan events to receive barcode and QR code data when scanned. Supports one subscription at a time. Use for receiving real-time scan results. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/session-api/session-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/session-api/session-api.ts index a8181e6bbf..e293836f45 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/session-api/session-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/session-api/session-api.ts @@ -1,5 +1,10 @@ import type {Session} from '../types/session'; +/** + * The `SessionApi` object provides access to current session information and authentication. Access these properties through `api.session` to retrieve shop data and generate secure tokens. These properties enable secure API calls while maintaining user privacy and [app permissions](https://help.shopify.com/manual/your-account/users/roles/permissions/store-permissions#apps-and-channels-permissions). + * + * @publicDocs + */ export interface SessionApiContent { /** * Provides comprehensive information about the current POS session including shop details, user authentication, location data, staff member information, currency settings, and POS version. This data is static for the duration of the session and updates when users switch locations or staff members change. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/api/toast-api/toast-api.ts b/packages/ui-extensions/src/surfaces/point-of-sale/api/toast-api/toast-api.ts index ae22634d75..eb0f073be2 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/api/toast-api/toast-api.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/api/toast-api/toast-api.ts @@ -10,6 +10,11 @@ export interface ShowToastOptions { duration?: number; } +/** + * The `ToastApi` object provides properties for displaying temporary notification messages. Access these properties through `api.toast` to show user feedback and status updates. + * + * @publicDocs + */ export interface ToastApiContent { /** * Displays a toast notification with the specified text content. The message appears as a temporary overlay that automatically dismisses after the specified duration. Use for providing immediate user feedback, confirming actions, or communicating status updates without interrupting the user's workflow. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Badge/Badge.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Badge/Badge.ts index 8aa828ba98..d706acd082 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Badge/Badge.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Badge/Badge.ts @@ -8,6 +8,11 @@ export type BadgeVariant = | 'highlight'; export type BadgeStatus = 'empty' | 'partial' | 'complete'; +/** + * Configure the following properties on the Badge component. + * + * @publicDocs + */ export interface BadgeProps { /** * The text content displayed within the badge. Keep this concise and descriptive to clearly communicate status or category information. Examples include "Paid," "Pending," "Out of Stock," or "VIP Customer." diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Banner/Banner.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Banner/Banner.ts index 15fc72d444..24df3c7905 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Banner/Banner.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Banner/Banner.ts @@ -2,6 +2,11 @@ import {createRemoteComponent} from '@remote-ui/core'; export type BannerVariant = 'confirmation' | 'alert' | 'error' | 'information'; +/** + * Configure the following properties on the Banner component. + * + * @publicDocs + */ export interface BannerProps { /** * The title text displayed prominently on the banner. This should be concise and clearly communicate the main message or purpose of the banner to merchants. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Button/Button.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Button/Button.ts index 063f7b27b2..fb94a37f49 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Button/Button.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Button/Button.ts @@ -7,6 +7,11 @@ export type ButtonType = /** @deprecated No longer supported as of POS 10.0.0. */ | 'plain'; +/** + * Configure the following properties on the Button component. + * + * @publicDocs + */ export interface ButtonProps { /** * The text set on the button. When using a button for action (menu item) targets, the title will be ignored. The text on the menu item will be the extension's description. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/CameraScanner/CameraScanner.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/CameraScanner/CameraScanner.ts index 3257ac8c37..b994ff8c1a 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/CameraScanner/CameraScanner.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/CameraScanner/CameraScanner.ts @@ -17,6 +17,11 @@ export interface CameraScannerBannerProps { visible: boolean; } +/** + * Configure the following properties on the CameraScanner component. + * + * @publicDocs + */ export interface CameraScannerProps { /** * An optional banner configuration object that displays contextual messages during scanning operations. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/DateField/DateField.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/DateField/DateField.ts index ae16d735a4..a8efbf774a 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/DateField/DateField.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/DateField/DateField.ts @@ -1,6 +1,11 @@ import {createRemoteComponent} from '@remote-ui/core'; import {InputProps} from '../shared/InputField'; +/** + * Configure the following properties on the DateField component. + * + * @publicDocs + */ export interface DateFieldProps extends Pick< InputProps, diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/DatePicker/DatePicker.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/DatePicker/DatePicker.ts index dfce63f0c8..6266f1b801 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/DatePicker/DatePicker.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/DatePicker/DatePicker.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the DatePicker component. + * + * @publicDocs + */ export interface DatePickerProps { /** * The currently selected date value. Defaults to the current date when not specified. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Dialog/Dialog.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Dialog/Dialog.ts index 645bce5318..41e6144894 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Dialog/Dialog.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Dialog/Dialog.ts @@ -2,6 +2,11 @@ import {createRemoteComponent} from '@remote-ui/core'; export type DialogType = 'default' | 'alert' | 'error' | 'destructive'; +/** + * Configure the following properties on the Dialog component. + * + * @publicDocs + */ export interface DialogProps { /** * The text displayed in the title of the dialog. This should be concise and clearly communicate the purpose or action being confirmed. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/EmailField/EmailField.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/EmailField/EmailField.ts index 276bbad677..c671431f59 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/EmailField/EmailField.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/EmailField/EmailField.ts @@ -1,6 +1,11 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {InputProps} from '../shared/InputField'; +/** + * Configure the following properties on the EmailField component. + * + * @publicDocs + */ export interface EmailFieldProps extends InputProps {} export const EmailField = createRemoteComponent<'EmailField', EmailFieldProps>( diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/FormattedTextField/FormattedTextField.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/FormattedTextField/FormattedTextField.ts index ef4aca8ddf..e160da0a32 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/FormattedTextField/FormattedTextField.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/FormattedTextField/FormattedTextField.ts @@ -2,7 +2,9 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {AutoCapitalizationType} from '../shared/auto-capitalization-type'; import type {BaseTextFieldProps} from '../shared/BaseTextField'; +/** @publicDocs */ export type InputType = 'text' | 'number' | 'currency' | 'giftcard' | 'email'; +/** @publicDocs */ export interface FormattedTextFieldProps extends BaseTextFieldProps { /** * Defines the input type options that determine which specialized keyboard layout is displayed. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Icon/Icon.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Icon/Icon.ts index ea42bbc426..ed265eb9a7 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Icon/Icon.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Icon/Icon.ts @@ -96,6 +96,11 @@ export type IconName = */ export type IconSize = 'minor' | 'major' | 'spot' | 'caption' | 'badge'; +/** + * Configure the following properties on the Icon component. + * + * @publicDocs + */ export interface IconProps { /** * A name used to render the icon. Choose from the available icon set including commerce-specific symbols like `'cart'`, `'payment'`, `'search'`, navigation arrows, and system indicators. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Image/Image.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Image/Image.ts index da9ed7f8a6..6b5e880f2a 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Image/Image.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Image/Image.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the Image component. + * + * @publicDocs + */ export interface ImageProps { /** * The source of the image to be displayed. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/List/List.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/List/List.ts index 50d9c0a36e..65c580e5d4 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/List/List.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/List/List.ts @@ -107,6 +107,11 @@ export interface ListRow { onPress?: () => void; } +/** + * Configure the following properties on the List component. + * + * @publicDocs + */ export interface ListProps { /** * A large display title shown at the top of the list. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Navigator/Navigator.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Navigator/Navigator.ts index 77edfc9899..52902154b2 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Navigator/Navigator.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Navigator/Navigator.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the Navigator component. + * + * @publicDocs + */ export interface NavigatorProps { /** * The name of the initial Screen component to display when the Navigator is first rendered. Must match the `name` property of a child Screen component. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/NumberField/NumberField.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/NumberField/NumberField.ts index 4582d94f42..2e93c256a8 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/NumberField/NumberField.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/NumberField/NumberField.ts @@ -1,6 +1,11 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {InputProps} from '../shared/InputField'; +/** + * Configure the following properties on the NumberField component. + * + * @publicDocs + */ export interface NumberFieldProps extends InputProps { /** * The virtual keyboard layout to display: diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlock.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlock.ts index b112321814..cb1e2b4c5a 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlock.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlock.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the POSBlock component. + * + * @publicDocs + */ export interface POSBlockProps { /** * An optional action button configuration to be displayed on the POSBlock. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlockRow.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlockRow.ts index 0e45960296..2e303d78fa 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlockRow.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/POSBlock/POSBlockRow.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the POSBlockRow component. + * + * @publicDocs + */ export interface POSBlockRowProps { /** * A callback function executed when the user taps the row. Use this to handle row-specific interactions or navigation. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/PinPad/PinPad.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/PinPad/PinPad.ts index a6f404b06e..fc21da27af 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/PinPad/PinPad.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/PinPad/PinPad.ts @@ -37,6 +37,11 @@ export interface PinPadActionType { onPress: () => Promise; } +/** + * Configure the following properties on the PinPad component. + * + * @publicDocs + */ export interface PinPadProps { /** * Whether the entered PIN should be masked with dots or asterisks to protect privacy and security. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/RadioButtonList/RadioButtonList.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/RadioButtonList/RadioButtonList.ts index a1dc1d1d03..61c4c4b3b5 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/RadioButtonList/RadioButtonList.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/RadioButtonList/RadioButtonList.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the RadioButtonList component. + * + * @publicDocs + */ export interface RadioButtonListProps { /** * An array of string values representing the radio button options available for selection. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Screen/Screen.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Screen/Screen.ts index 659f4d334a..5d5097619d 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Screen/Screen.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Screen/Screen.ts @@ -28,6 +28,11 @@ export interface SecondaryActionProps { isEnabled?: boolean; } +/** + * Configure the following properties on the Screen component. + * + * @publicDocs + */ export interface ScreenProps { /** * The unique identifier used to identify this screen as a destination in the navigation stack. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/SearchBar/SearchBar.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/SearchBar/SearchBar.ts index cac09188a5..5d1d882c21 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/SearchBar/SearchBar.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/SearchBar/SearchBar.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the SearchBar component. + * + * @publicDocs + */ export interface SearchBarProps { /** * The initial text value displayed in the search bar when first rendered. This differs from placeholder text which appears when the field is empty. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Section/Section.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Section/Section.ts index 5317d65bd4..c2d988a70a 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Section/Section.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Section/Section.ts @@ -14,6 +14,11 @@ export interface SectionHeaderAction { onPress: () => void; } +/** + * Configure the following properties on the Section component. + * + * @publicDocs + */ export interface SectionProps { /** * The title text displayed at the top of the section to describe its content. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/SectionHeader/SectionHeader.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/SectionHeader/SectionHeader.ts index 940836fde2..486d461d16 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/SectionHeader/SectionHeader.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/SectionHeader/SectionHeader.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the SectionHeader component. + * + * @publicDocs + */ export interface SectionHeaderProps { /** * The title text displayed in the section header. Provide clear, descriptive text that accurately represents the content section below. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/SegmentedControl/SegmentedControl.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/SegmentedControl/SegmentedControl.ts index 17b0e99b23..cbf3be265e 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/SegmentedControl/SegmentedControl.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/SegmentedControl/SegmentedControl.ts @@ -17,6 +17,11 @@ export interface Segment { disabled: boolean; } +/** + * Configure the following properties on the SegmentedControl component. + * + * @publicDocs + */ export interface SegmentedControlProps { /** * An array of segment objects that define the available options in the segmented control. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Selectable/Selectable.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Selectable/Selectable.ts index 2163aa948a..0b51c02167 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Selectable/Selectable.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Selectable/Selectable.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the Selectable component. + * + * @publicDocs + */ export interface SelectableProps { /** * The callback function that's executed when the user taps or presses the selectable component. This is the primary way to handle user interactions with the wrapped content. The function receives no parameters and should contain the logic for what happens when the selection occurs, such as navigation, state updates, or triggering other actions. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Spacing/Spacing.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Spacing/Spacing.ts index b350b25e8e..2ef63db47c 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Spacing/Spacing.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Spacing/Spacing.ts @@ -1,3 +1,8 @@ +/** + * The spacing values for controlling vertical space between elements. + * + * @publicDocs + */ export type VerticalSpacing = | 'HalfPoint' | 'ExtraSmall' @@ -6,6 +11,11 @@ export type VerticalSpacing = | 'Large' | 'ExtraLarge'; +/** + * The spacing values for controlling horizontal space between elements. + * + * @publicDocs + */ export type HorizontalSpacing = | 'HalfPoint' | 'ExtraSmall' diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Stack/Stack.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Stack/Stack.ts index beb5041dce..def36f2f64 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Stack/Stack.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Stack/Stack.ts @@ -17,6 +17,11 @@ export type Spacing = | 13 | 16; +/** + * Configure the following properties on the Stack component. + * + * @publicDocs + */ export interface StackProps { /** * The direction of the stack. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Stepper/Stepper.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Stepper/Stepper.ts index 7ba814a32e..6a2a39e5fa 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Stepper/Stepper.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Stepper/Stepper.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the Stepper component. + * + * @publicDocs + */ export interface StepperProps { /** * The initial value of the stepper that sets the starting numeric value when the component is first rendered. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Text/Text.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Text/Text.ts index 75867d8a33..deea590c90 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Text/Text.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Text/Text.ts @@ -46,6 +46,11 @@ export type ColorType = | 'TextInteractive' | 'TextHighlight'; +/** + * Configure the following properties on the Text component. + * + * @publicDocs + */ export interface TextProps { /** * The typography variant that determines the size, weight, and styling of the text within the design system hierarchy. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/TextArea/TextArea.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/TextArea/TextArea.ts index 8a6b09bab6..9c78f89a69 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/TextArea/TextArea.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/TextArea/TextArea.ts @@ -1,6 +1,11 @@ import {createRemoteComponent} from '@remote-ui/core'; import type {InputProps} from '../shared/InputField'; +/** + * Configure the following properties on the TextArea component. + * + * @publicDocs + */ export interface TextAreaProps extends InputProps { /** * The initial number of visible text lines to be displayed. Maximum of 8 lines. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/TextField/TextField.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/TextField/TextField.ts index 14476d0a9f..88e805f235 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/TextField/TextField.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/TextField/TextField.ts @@ -60,6 +60,11 @@ export type EmbeddedElementProps = | SuccessProps | PasswordProps; +/** + * Configure the following properties on the TextField component. + * + * @publicDocs + */ export interface NewTextFieldProps extends InputProps {} /** diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/Tile/Tile.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/Tile/Tile.ts index ab693ddc33..ca4a56fc1e 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/Tile/Tile.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/Tile/Tile.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the Tile component. + * + * @publicDocs + */ export interface TileProps { /** * The text displayed as the main label of the tile. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/TimeField/TimeField.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/TimeField/TimeField.ts index bbbfd48a35..ec6a2d7add 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/TimeField/TimeField.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/TimeField/TimeField.ts @@ -1,6 +1,11 @@ import {createRemoteComponent} from '@remote-ui/core'; import {InputProps} from '../shared/InputField'; +/** + * Configure the following properties on the TimeField component. + * + * @publicDocs + */ export interface TimeFieldProps extends Pick< InputProps, diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/TimePicker/TimePicker.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/TimePicker/TimePicker.ts index 369cdff932..49500c239d 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/TimePicker/TimePicker.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/TimePicker/TimePicker.ts @@ -1,5 +1,10 @@ import {createRemoteComponent} from '@remote-ui/core'; +/** + * Configure the following properties on the TimePicker component. + * + * @publicDocs + */ export interface TimePickerProps { /** * The currently selected time value. Defaults to the current time when not specified. diff --git a/packages/ui-extensions/src/surfaces/point-of-sale/components/shared/auto-capitalization-type.ts b/packages/ui-extensions/src/surfaces/point-of-sale/components/shared/auto-capitalization-type.ts index e3eab1e041..2770e8c6e3 100644 --- a/packages/ui-extensions/src/surfaces/point-of-sale/components/shared/auto-capitalization-type.ts +++ b/packages/ui-extensions/src/surfaces/point-of-sale/components/shared/auto-capitalization-type.ts @@ -1,3 +1,4 @@ +/** @publicDocs */ export type AutoCapitalizationType = | 'none' | 'sentences' diff --git a/yarn.lock b/yarn.lock index f33e6be4a9..8ff293421b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1910,10 +1910,10 @@ pkg-dir "^5.0.0" pluralize "^8.0.0" -"@shopify/generate-docs@0.16.4": - version "0.16.4" - resolved "https://registry.yarnpkg.com/@shopify/generate-docs/-/generate-docs-0.16.4.tgz#4e9c6348f080217e59be34ca6fbde850769eccef" - integrity sha512-lYtnB2gPPSBf73YvbrNM9u6p1cm/qbg1uEqkMW9sG4/dORb5tBPDDC/KkckaCaMF7soHg9PsinNXHAa0/Hlf4g== +"@shopify/generate-docs@1.0.0": + version "1.0.0" + resolved "https://npm.shopify.io/node/@shopify/generate-docs/-/generate-docs-1.0.0.tgz#2aaa894e8e09ff1acea9ac49eb1ab212088f30c8" + integrity sha512-DOkWeqGjVg3xxS6slNuyYpegvRLMn1o9VPwZm1fIzsRsJRAHy12TZM3Bq3yMimx5IU3J34y+iD/jPb/S/gFU5g== dependencies: "@types/react" "^18.0.21" globby "^11.1.0"