@shopify/ui-extensions 2025.10.0-rc.40 → 2025.10.0-rc.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/surfaces/checkout/preact/api.js +4 -0
- package/build/cjs/surfaces/checkout/preact/subscription.js +6 -5
- package/build/cjs/surfaces/checkout/shared.js +17 -4
- package/build/esm/surfaces/checkout/preact/api.mjs +4 -0
- package/build/esm/surfaces/checkout/preact/subscription.mjs +6 -5
- package/build/esm/surfaces/checkout/shared.mjs +17 -4
- package/build/esnext/surfaces/checkout/preact/api.esnext +4 -0
- package/build/esnext/surfaces/checkout/preact/subscription.esnext +6 -5
- package/build/esnext/surfaces/checkout/shared.esnext +17 -4
- package/build/ts/docs/shared/components/Details.d.ts +4 -0
- package/build/ts/docs/shared/components/Details.d.ts.map +1 -0
- package/build/ts/docs/shared/components/MoneyField.d.ts.map +1 -1
- package/build/ts/docs/shared/components/PressButton.d.ts +4 -0
- package/build/ts/docs/shared/components/PressButton.d.ts.map +1 -0
- package/build/ts/docs/shared/components/SkeletonParagraph.d.ts +4 -0
- package/build/ts/docs/shared/components/SkeletonParagraph.d.ts.map +1 -0
- package/build/ts/docs/shared/components/Summary.d.ts +4 -0
- package/build/ts/docs/shared/components/Summary.d.ts.map +1 -0
- package/build/ts/docs/shared/components/Tooltip.d.ts +1 -1
- package/build/ts/docs/shared/components/Tooltip.d.ts.map +1 -1
- package/build/ts/docs/shared/components/index.d.ts +6 -1
- package/build/ts/docs/shared/components/index.d.ts.map +1 -1
- package/build/ts/index.d.ts.map +1 -1
- package/build/ts/shared.d.ts +4 -34
- package/build/ts/shared.d.ts.map +1 -1
- package/build/ts/surfaces/admin/api/customer-segment-template/customer-segment-template.d.ts +30 -0
- package/build/ts/surfaces/admin/api/customer-segment-template/customer-segment-template.d.ts.map +1 -1
- package/build/ts/surfaces/admin/api.d.ts +1 -1
- package/build/ts/surfaces/admin/api.d.ts.map +1 -1
- package/build/ts/surfaces/admin/components/Table/Table.doc.d.ts.map +1 -1
- package/build/ts/surfaces/admin/components/patterns/accountConnection.ab.doc.d.ts +4 -0
- package/build/ts/surfaces/admin/components/patterns/accountConnection.ab.doc.d.ts.map +1 -0
- package/build/ts/surfaces/admin/components/patterns/indexTable.ab.doc.d.ts.map +1 -1
- package/build/ts/surfaces/admin/extension-targets.d.ts +5 -3
- package/build/ts/surfaces/admin/extension-targets.d.ts.map +1 -1
- package/build/ts/surfaces/admin/targets/admin.customers.segmentation-templates.data.d.ts +6 -0
- package/build/ts/surfaces/checkout/api/address-autocomplete/standard.d.ts +1 -1
- package/build/ts/surfaces/checkout/api/cart-line/cart-line-item.d.ts +3 -3
- package/build/ts/surfaces/checkout/api/cart-line/cart-line-item.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/checkout/checkout.d.ts +2 -2
- package/build/ts/surfaces/checkout/api/order-confirmation/order-confirmation.d.ts +2 -2
- package/build/ts/surfaces/checkout/api/order-confirmation/order-confirmation.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/payment/payment-option-item.d.ts +3 -3
- package/build/ts/surfaces/checkout/api/payment/payment-option-item.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/pickup/pickup-location-item.d.ts +3 -3
- package/build/ts/surfaces/checkout/api/pickup/pickup-location-item.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/pickup/pickup-location-list.d.ts +2 -2
- package/build/ts/surfaces/checkout/api/pickup/pickup-location-list.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/pickup/pickup-point-list.d.ts +2 -2
- package/build/ts/surfaces/checkout/api/pickup/pickup-point-list.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/shipping/shipping-option-item.d.ts +3 -3
- package/build/ts/surfaces/checkout/api/shipping/shipping-option-item.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/shipping/shipping-option-list.d.ts +3 -3
- package/build/ts/surfaces/checkout/api/shipping/shipping-option-list.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/api/standard/standard.d.ts +45 -40
- package/build/ts/surfaces/checkout/api/standard/standard.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/components/Badge/Badge.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Badge/Badge.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Badge.d.ts +3 -8
- package/build/ts/surfaces/checkout/components/Box/Box.doc.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/components/Button.d.ts +1 -1
- package/build/ts/surfaces/checkout/components/Clickable/Clickable.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Clickable/Clickable.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Clickable.d.ts +1 -1
- package/build/ts/surfaces/checkout/components/Details/Details.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Details/Details.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Details.d.ts +15 -2
- package/build/ts/surfaces/checkout/components/Divider/Divider.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Divider/Divider.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Divider.d.ts +17 -2
- package/build/ts/surfaces/checkout/components/DropZone.d.ts +8 -3
- package/build/ts/surfaces/checkout/components/EmailField.d.ts +8 -1
- package/build/ts/surfaces/checkout/components/Form/Form.doc.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/components/Form.d.ts +3 -0
- package/build/ts/surfaces/checkout/components/Grid/Grid.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Grid/Grid.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Grid.d.ts +7 -7
- package/build/ts/surfaces/checkout/components/Icon.d.ts +2 -7
- package/build/ts/surfaces/checkout/components/Link.d.ts +1 -1
- package/build/ts/surfaces/checkout/components/MapMarker.d.ts +9 -12
- package/build/ts/surfaces/checkout/components/Modal/Modal.doc.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/components/Modal.d.ts +16 -15
- package/build/ts/surfaces/checkout/components/MoneyField/MoneyField.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/MoneyField/MoneyField.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/{UrlField.d.ts → MoneyField.d.ts} +14 -18
- package/build/ts/surfaces/checkout/components/OrderedList/OrderedList.doc.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/components/PhoneField.d.ts +10 -12
- package/build/ts/surfaces/checkout/components/Popover/Popover.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Popover/Popover.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Popover.d.ts +50 -2
- package/build/ts/surfaces/checkout/components/PressButton/PressButton.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/PressButton/PressButton.doc.d.ts.map +1 -0
- package/{src/surfaces/checkout/components/Select.d.ts → build/ts/surfaces/checkout/components/PressButton.d.ts} +20 -20
- package/build/ts/surfaces/checkout/components/Sheet/Sheet.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Sheet/Sheet.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Sheet.d.ts +21 -15
- package/build/ts/surfaces/checkout/components/SkeletonParagraph/SkeletonParagraph.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/SkeletonParagraph/SkeletonParagraph.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/Stack.d.ts +4 -4
- package/build/ts/surfaces/checkout/components/Switch/Switch.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Switch/Switch.doc.d.ts.map +1 -0
- package/build/ts/surfaces/checkout/components/TextField.d.ts +10 -17
- package/build/ts/surfaces/checkout/components/Tooltip/Tooltip.doc.d.ts +4 -0
- package/build/ts/surfaces/checkout/components/Tooltip/Tooltip.doc.d.ts.map +1 -0
- package/{src/surfaces/checkout/components/Option.d.ts → build/ts/surfaces/checkout/components/Tooltip.d.ts} +9 -7
- package/build/ts/surfaces/checkout/components/UnorderedList/UnorderedList.doc.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/components/components-shared.d.ts +631 -275
- package/build/ts/surfaces/checkout/components/components.d.ts +1013 -501
- package/build/ts/surfaces/checkout/preact/api.d.ts +4 -0
- package/build/ts/surfaces/checkout/preact/api.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/preact/subscription.d.ts +5 -4
- package/build/ts/surfaces/checkout/preact/subscription.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/shared.d.ts +27 -4
- package/build/ts/surfaces/checkout/shared.d.ts.map +1 -1
- package/build/ts/surfaces/checkout/targets/Checkout::Actions::RenderBefore.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::CartLineDetails::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::CartLineDetails::RenderLineComponents.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::CartLines::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::Contact::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::CustomerInformation::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::DeliveryAddress::RenderBefore.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::Dynamic::Render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::GiftCard::Render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::PaymentMethod::HostedFields::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::PaymentMethod::Render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::PaymentMethod::RenderRequiredAction.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::PickupLocations::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::PickupLocations::RenderBefore.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::PickupPoints::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::PickupPoints::RenderBefore.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::Reductions::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::Reductions::RenderBefore.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ShippingMethodDetails::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ShippingMethodDetails::RenderExpanded.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ShippingMethods::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ShippingMethods::RenderBefore.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ThankYou::CartLineDetails::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ThankYou::CartLines::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ThankYou::CustomerInformation::RenderAfter.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/Checkout::ThankYou::Dynamic::Render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.cart-line-item.line-components.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.actions.render-before.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.block.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.cart-line-item.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.cart-line-list.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.contact.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.delivery-address.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.delivery-address.render-before.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.footer.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.gift-card.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.header.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.payment-method-list.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.payment-method-list.render-before.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.payment-option-item.action-required.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.payment-option-item.details.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.payment-option-item.hosted-fields.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.pickup-location-list.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.pickup-location-list.render-before.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.pickup-location-option-item.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.pickup-point-list.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.pickup-point-list.render-before.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.reductions.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.reductions.render-before.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.shipping-option-item.details.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.shipping-option-item.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.shipping-option-list.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.checkout.shipping-option-list.render-before.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.thank-you.announcement.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.thank-you.block.render.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.thank-you.cart-line-item.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.thank-you.cart-line-list.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.thank-you.customer-information.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.thank-you.footer.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout/targets/purchase.thank-you.header.render-after.d.ts +3 -4
- package/build/ts/surfaces/checkout.d.ts +1 -0
- package/build/ts/surfaces/checkout.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/api/shared.d.ts +2 -1
- package/build/ts/surfaces/customer-account/api/shared.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/Avatar/Avatar.doc.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/Avatar.d.ts +2 -2
- package/build/ts/surfaces/customer-account/components/Badge.d.ts +3 -8
- package/build/ts/surfaces/customer-account/components/Button.d.ts +1 -1
- package/build/ts/surfaces/customer-account/components/ButtonGroup/ButtonGroup.doc.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/ButtonGroup.d.ts +2 -2
- package/build/ts/surfaces/customer-account/components/Clickable.d.ts +1 -1
- package/build/ts/surfaces/customer-account/components/CustomerAccountAction/CustomerAccountAction.doc.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/CustomerAccountAction.d.ts +3 -3
- package/build/ts/surfaces/customer-account/components/Details.d.ts +15 -2
- package/build/ts/surfaces/customer-account/components/Divider.d.ts +17 -2
- package/build/ts/surfaces/customer-account/components/DropZone.d.ts +8 -3
- package/build/ts/surfaces/customer-account/components/EmailField.d.ts +8 -1
- package/build/ts/surfaces/customer-account/components/Form.d.ts +3 -0
- package/build/ts/surfaces/customer-account/components/Grid.d.ts +7 -7
- package/build/ts/surfaces/customer-account/components/Icon.d.ts +2 -7
- package/build/ts/surfaces/customer-account/components/ImageGroup/ImageGroup.doc.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/Link.d.ts +1 -1
- package/build/ts/surfaces/customer-account/components/MapMarker.d.ts +9 -12
- package/build/ts/surfaces/customer-account/components/Menu/Menu.doc.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/Modal.d.ts +16 -15
- package/{src/surfaces/checkout/components/UrlField.d.ts → build/ts/surfaces/customer-account/components/MoneyField.d.ts} +14 -18
- package/build/ts/surfaces/customer-account/components/Page/Page.doc.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/Page.d.ts +3 -3
- package/build/ts/surfaces/customer-account/components/PhoneField.d.ts +10 -12
- package/build/ts/surfaces/customer-account/components/Popover.d.ts +50 -2
- package/build/ts/surfaces/customer-account/components/{Select.d.ts → PressButton.d.ts} +20 -20
- package/build/ts/surfaces/customer-account/components/Section/Section.doc.d.ts.map +1 -1
- package/build/ts/surfaces/customer-account/components/Sheet.d.ts +21 -15
- package/build/ts/surfaces/customer-account/components/Stack.d.ts +4 -4
- package/build/ts/surfaces/customer-account/components/TextField.d.ts +10 -17
- package/build/ts/surfaces/customer-account/components/{Option.d.ts → Tooltip.d.ts} +9 -7
- package/build/ts/surfaces/customer-account/components/components-shared.d.ts +631 -275
- package/build/ts/surfaces/customer-account/components/components.d.ts +1013 -501
- package/build/ts/surfaces/customer-account/targets/customer-account.footer.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-index.announcement.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-index.block.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.announcement.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.block.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.cart-line-item.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.cart-line-list.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.customer-information.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.fulfillment-details.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.payment-details.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.return-details.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order-status.unfulfilled-items.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order.action.menu-item.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order.action.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.order.page.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.page.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.addresses.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.announcement.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.block.render.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.company-details.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.company-location-addresses.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.company-location-payment.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.company-location-staff.render-after.d.ts +3 -4
- package/build/ts/surfaces/customer-account/targets/customer-account.profile.payment.render-after.d.ts +3 -4
- package/build/ts/surfaces/point-of-sale/api/navigation-api/navigation-api.d.ts +2 -9
- package/build/ts/surfaces/point-of-sale/api/navigation-api/navigation-api.d.ts.map +1 -1
- package/build/ts/surfaces/point-of-sale/components/Badge/Badge.doc.d.ts.map +1 -1
- package/build/ts/surfaces/point-of-sale/components/Banner.d.ts +11 -2
- package/build/ts/surfaces/point-of-sale/components/Button.d.ts +29 -4
- package/build/ts/surfaces/point-of-sale/components/DatePicker/DatePicker.doc.d.ts.map +1 -1
- package/build/ts/surfaces/point-of-sale/components/DateSpinner/DateSpinner.doc.d.ts.map +1 -1
- package/{src/surfaces/point-of-sale/components/Navigator.d.ts → build/ts/surfaces/point-of-sale/components/Divider.d.ts} +7 -10
- package/build/ts/surfaces/point-of-sale/components/Modal.d.ts +1 -2
- package/build/ts/surfaces/point-of-sale/components/Page.d.ts +4 -4
- package/build/ts/surfaces/point-of-sale/components/QrCode.d.ts +43 -0
- package/build/ts/surfaces/point-of-sale/components/ScrollBox.d.ts +93 -2
- package/build/ts/surfaces/point-of-sale/components/components-shared.d.ts +14 -0
- package/build/ts/surfaces/point-of-sale/components/targets/ReceiptComponents.d.ts +1 -1
- package/build/ts/surfaces/point-of-sale/components/targets/ReceiptComponents.d.ts.map +1 -1
- package/build/ts/surfaces/point-of-sale/targets/pos.receipt-footer.block.render.d.ts +2 -0
- package/build/ts/surfaces/point-of-sale/targets/pos.receipt-header.block.render.d.ts +2 -0
- package/build/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/docs/shared/components/Details.ts +12 -0
- package/src/docs/shared/components/EmailField.ts +1 -1
- package/src/docs/shared/components/Modal.ts +1 -1
- package/src/docs/shared/components/MoneyField.ts +2 -1
- package/src/docs/shared/components/Popover.ts +1 -1
- package/src/docs/shared/components/PressButton.ts +12 -0
- package/src/docs/shared/components/SkeletonParagraph.ts +12 -0
- package/src/docs/shared/components/Summary.ts +12 -0
- package/src/docs/shared/components/Tooltip.ts +2 -2
- package/src/docs/shared/components/index.ts +6 -1
- package/src/index.ts +0 -1
- package/src/shared.ts +5 -36
- package/src/surfaces/admin/api/customer-segment-template/customer-segment-template.ts +31 -0
- package/src/surfaces/admin/api.ts +4 -1
- package/src/surfaces/admin/components/patterns/examples/accountConnection.html +16 -0
- package/src/surfaces/admin/components.d.ts +366 -451
- package/src/surfaces/admin/extension-targets.ts +6 -5
- package/src/surfaces/checkout/api/address-autocomplete/standard.ts +1 -1
- package/src/surfaces/checkout/api/cart-line/cart-line-item.ts +3 -3
- package/src/surfaces/checkout/api/checkout/checkout.ts +2 -2
- package/src/surfaces/checkout/api/order-confirmation/order-confirmation.ts +2 -2
- package/src/surfaces/checkout/api/payment/payment-option-item.ts +3 -3
- package/src/surfaces/checkout/api/pickup/pickup-location-item.ts +3 -3
- package/src/surfaces/checkout/api/pickup/pickup-location-list.ts +2 -2
- package/src/surfaces/checkout/api/pickup/pickup-point-list.ts +2 -2
- package/src/surfaces/checkout/api/shipping/shipping-option-item.ts +3 -3
- package/src/surfaces/checkout/api/shipping/shipping-option-list.ts +3 -3
- package/src/surfaces/checkout/api/standard/standard.ts +44 -40
- package/src/surfaces/checkout/components/Badge/examples/basic-badge.example.html +3 -0
- package/src/surfaces/checkout/components/Badge.d.ts +3 -8
- package/src/surfaces/checkout/components/Banner/examples/basic-banner.example.html +1 -2
- package/src/surfaces/checkout/components/Button.d.ts +1 -1
- package/src/surfaces/checkout/components/Clickable/examples/basic-clickable.example.html +3 -0
- package/src/surfaces/checkout/components/Clickable.d.ts +1 -1
- package/src/surfaces/checkout/components/Details/examples/basic-details.example.html +6 -0
- package/src/surfaces/checkout/components/Details.d.ts +15 -2
- package/src/surfaces/checkout/components/Divider/examples/basic-divider.example.html +1 -0
- package/src/surfaces/checkout/components/Divider.d.ts +17 -2
- package/src/surfaces/checkout/components/DropZone/examples/basic-drop-zone.example.html +1 -0
- package/src/surfaces/checkout/components/DropZone.d.ts +8 -3
- package/src/surfaces/checkout/components/EmailField/examples/basic-email-field.example.html +1 -0
- package/src/surfaces/checkout/components/EmailField.d.ts +8 -1
- package/src/surfaces/checkout/components/Form/examples/basic-form.example.html +3 -3
- package/src/surfaces/checkout/components/Form.d.ts +3 -0
- package/src/surfaces/checkout/components/Grid/examples/basic-grid.example.html +11 -0
- package/src/surfaces/checkout/components/Grid.d.ts +7 -7
- package/src/surfaces/checkout/components/Icon.d.ts +2 -7
- package/src/surfaces/checkout/components/Image/examples/basic-image.example.html +1 -1
- package/src/surfaces/checkout/components/Link.d.ts +1 -1
- package/src/surfaces/checkout/components/Map/examples/basic-map.example.html +3 -3
- package/src/surfaces/checkout/components/MapMarker.d.ts +9 -12
- package/src/surfaces/checkout/components/Modal.d.ts +16 -15
- package/src/surfaces/checkout/components/MoneyField/examples/basic-money-field.example.html +1 -0
- package/{build/ts/surfaces/customer-account/components/UrlField.d.ts → src/surfaces/checkout/components/MoneyField.d.ts} +14 -18
- package/src/surfaces/checkout/components/PhoneField/examples/basic-phone-field.example.html +1 -0
- package/src/surfaces/checkout/components/PhoneField.d.ts +10 -12
- package/src/surfaces/checkout/components/Popover/examples/basic-popover.example.html +7 -0
- package/src/surfaces/checkout/components/Popover.d.ts +50 -2
- package/src/surfaces/checkout/components/PressButton/examples/basic-press-button.example.html +1 -0
- package/{build/ts/surfaces/checkout/components/Select.d.ts → src/surfaces/checkout/components/PressButton.d.ts} +20 -20
- package/src/surfaces/checkout/components/ProductThumbnail/examples/basic-product-thumbnail.example.html +1 -0
- package/src/surfaces/checkout/components/Progress/examples/basic-progress.example.html +1 -1
- package/src/surfaces/checkout/components/Sheet/examples/basic-sheet.example.html +5 -0
- package/src/surfaces/checkout/components/Sheet.d.ts +21 -15
- package/src/surfaces/checkout/components/SkeletonParagraph/examples/basic-skeleton-paragraph.example.html +2 -0
- package/src/surfaces/checkout/components/Spinner/examples/basic-spinner.example.html +1 -1
- package/src/surfaces/checkout/components/Stack/examples/basic-stack.example.html +4 -0
- package/src/surfaces/checkout/components/Stack.d.ts +4 -4
- package/src/surfaces/checkout/components/Switch/examples/basic-switch.example.html +1 -0
- package/src/surfaces/checkout/components/Text/examples/basic-text.example.html +1 -1
- package/src/surfaces/checkout/components/TextArea/examples/basic-text-area.example.html +1 -0
- package/src/surfaces/checkout/components/TextField.d.ts +10 -17
- package/src/surfaces/checkout/components/Time/examples/basic-time.example.html +1 -1
- package/src/surfaces/checkout/components/Tooltip/examples/basic-tooltip.example.html +9 -0
- package/{build/ts/surfaces/checkout/components/Option.d.ts → src/surfaces/checkout/components/Tooltip.d.ts} +9 -7
- package/src/surfaces/checkout/components/components-shared.d.ts +631 -275
- package/src/surfaces/checkout/components/components.d.ts +1013 -501
- package/src/surfaces/checkout/preact/api.ts +4 -0
- package/src/surfaces/checkout/preact/subscription.ts +9 -8
- package/src/surfaces/checkout/preact/tests/buyer-identity.test.tsx +2 -3
- package/src/surfaces/checkout/preact/tests/mount.tsx +3 -3
- package/src/surfaces/checkout/shared.ts +37 -3
- package/src/surfaces/checkout.ts +3 -1
- package/src/surfaces/customer-account/api/shared.ts +2 -1
- package/src/surfaces/customer-account/components/Avatar/examples/basic-Avatar.example.html +4 -0
- package/src/surfaces/customer-account/components/Avatar.d.ts +2 -2
- package/src/surfaces/customer-account/components/ButtonGroup/examples/basic-ButtonGroup.example.html +11 -0
- package/src/surfaces/customer-account/components/ButtonGroup.d.ts +2 -2
- package/src/surfaces/customer-account/components/CustomerAccountAction/examples/basic-CustomerAccountAction.example.html +15 -0
- package/src/surfaces/customer-account/components/CustomerAccountAction.d.ts +3 -3
- package/src/surfaces/customer-account/components/ImageGroup/examples/basic-ImageGroup.example.html +18 -0
- package/src/surfaces/customer-account/components/Menu/examples/basic-Menu.example.html +14 -0
- package/src/surfaces/customer-account/components/Page/examples/basic-Page.example.html +19 -0
- package/src/surfaces/customer-account/components/Page.d.ts +3 -3
- package/src/surfaces/customer-account/components/Section/examples/basic-Section.example.html +12 -0
- package/src/surfaces/customer-account/components/Section.d.ts +2 -2
- package/src/surfaces/point-of-sale/api/navigation-api/navigation-api.ts +2 -10
- package/src/surfaces/point-of-sale/components/Badge/examples/default.html +5 -5
- package/src/surfaces/point-of-sale/components/Banner.d.ts +11 -2
- package/src/surfaces/point-of-sale/components/Button.d.ts +29 -4
- package/{build/ts/surfaces/point-of-sale/components/Navigator.d.ts → src/surfaces/point-of-sale/components/Divider.d.ts} +7 -10
- package/src/surfaces/point-of-sale/components/Modal.d.ts +1 -2
- package/src/surfaces/point-of-sale/components/Page.d.ts +4 -4
- package/src/surfaces/point-of-sale/components/QrCode.d.ts +43 -0
- package/src/surfaces/point-of-sale/components/ScrollBox.d.ts +93 -2
- package/src/surfaces/point-of-sale/components/components-shared.d.ts +14 -0
- package/src/surfaces/point-of-sale/components/targets/ReceiptComponents.ts +1 -1
- package/src/surfaces/point-of-sale/components.d.ts +554 -386
- package/build/ts/surfaces/admin/targets/admin.customers.segmentation-templates.render.d.ts +0 -57
- package/build/ts/surfaces/checkout/components/NumberField.d.ts +0 -85
- package/build/ts/surfaces/checkout/components/PasswordField.d.ts +0 -84
- package/build/ts/surfaces/customer-account/components/NumberField.d.ts +0 -85
- package/build/ts/surfaces/customer-account/components/PasswordField.d.ts +0 -84
- package/build/ts/surfaces/point-of-sale/components/Screen.d.ts +0 -91
- package/build/ts/surfaces/point-of-sale/components/shared.d.ts +0 -76
- package/src/surfaces/checkout/components/DropZone/examples/basic-dropzone.example.html +0 -1
- package/src/surfaces/checkout/components/EmailField/examples/basic-emailfield.example.html +0 -4
- package/src/surfaces/checkout/components/NumberField.d.ts +0 -85
- package/src/surfaces/checkout/components/PasswordField.d.ts +0 -84
- package/src/surfaces/checkout/components/PhoneField/examples/basic-phonefield.example.html +0 -2
- package/src/surfaces/checkout/components/ProductThumbnail/examples/basic-productthumbnail.example.html +0 -4
- package/src/surfaces/checkout/components/TextArea/examples/basic-textarea.example.html +0 -5
- package/src/surfaces/customer-account/components/Avatar/examples/basic-Avatar-preact.example.tsx +0 -10
- package/src/surfaces/customer-account/components/ButtonGroup/examples/basic-ButtonGroup-preact.example.tsx +0 -22
- package/src/surfaces/customer-account/components/CustomerAccountAction/examples/basic-CustomerAccountAction-preact.example.tsx +0 -17
- package/src/surfaces/customer-account/components/ImageGroup/examples/basic-ImageGroup-preact.example.tsx +0 -17
- package/src/surfaces/customer-account/components/Menu/examples/basic-Menu-preact.example.tsx +0 -24
- package/src/surfaces/customer-account/components/Page/examples/basic-Page-preact.example.tsx +0 -37
- package/src/surfaces/customer-account/components/Section/examples/basic-Section-preact.example.tsx +0 -23
- package/src/surfaces/point-of-sale/components/Screen.d.ts +0 -91
- package/src/surfaces/point-of-sale/components/shared.d.ts +0 -76
- /package/src/surfaces/checkout/components/ClipboardItem/examples/{basic-clipboarditem.example.html → basic-clipboard-item.example.html} +0 -0
- /package/src/surfaces/checkout/components/OrderedList/examples/{basic-orderedlist.example.html → basic-ordered-list.example.html} +0 -0
- /package/src/surfaces/checkout/components/PaymentIcon/examples/{basic-paymenticon.example.html → basic-payment-icon.example.html} +0 -0
- /package/src/surfaces/checkout/components/QRCode/examples/{basic-qrcode.example.html → basic-qr-code.example.html} +0 -0
- /package/src/surfaces/checkout/components/TextField/examples/{basic-textfield.example.html → basic-text-field.example.html} +0 -0
- /package/src/surfaces/checkout/components/UnorderedList/examples/{basic-unorderedlist.example.html → basic-unordered-list.example.html} +0 -0
|
@@ -14,6 +14,10 @@ import {CheckoutUIExtensionError} from './errors';
|
|
|
14
14
|
* which contains a basic set of properties about the checkout.
|
|
15
15
|
*
|
|
16
16
|
* 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).
|
|
17
|
+
*
|
|
18
|
+
* > Note:
|
|
19
|
+
* > As of version 2025-10, you no longer need this hook. The full API object is accessible via
|
|
20
|
+
* > the global `shopify` object.
|
|
17
21
|
*/
|
|
18
22
|
export function useApi<
|
|
19
23
|
Target extends RenderExtensionTarget = RenderExtensionTarget,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {useEffect, useState} from 'preact/hooks';
|
|
2
2
|
|
|
3
|
-
import type {
|
|
3
|
+
import type {SubscribableSignalLike} from '../shared';
|
|
4
4
|
|
|
5
|
-
type Subscriber<T> = Parameters<
|
|
5
|
+
type Subscriber<T> = Parameters<SubscribableSignalLike<T>['subscribe']>[0];
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Subscribes to the special wrapper type that all "changeable" values in the
|
|
@@ -10,13 +10,14 @@ type Subscriber<T> = Parameters<StatefulRemoteSubscribable<T>['subscribe']>[0];
|
|
|
10
10
|
* and subscribes to update the value when changes occur in the checkout.
|
|
11
11
|
*
|
|
12
12
|
* > Note:
|
|
13
|
-
* >
|
|
14
|
-
* >
|
|
13
|
+
* > As of version 2025-10, you no longer need this hook. When you access `.value`
|
|
14
|
+
* > (instead of `.current`) on subscribable properties, Preact will automatically
|
|
15
|
+
* > re-render as `.value` changes.
|
|
15
16
|
*/
|
|
16
17
|
export function useSubscription<Value>(
|
|
17
|
-
subscription:
|
|
18
|
+
subscription: SubscribableSignalLike<Value>,
|
|
18
19
|
): Value {
|
|
19
|
-
const [, setValue] = useState(subscription.
|
|
20
|
+
const [, setValue] = useState(subscription.value);
|
|
20
21
|
|
|
21
22
|
useEffect(() => {
|
|
22
23
|
let didUnsubscribe = false;
|
|
@@ -34,7 +35,7 @@ export function useSubscription<Value>(
|
|
|
34
35
|
// Because we're subscribing in a passive effect,
|
|
35
36
|
// it's possible for an update to occur between render and the effect handler.
|
|
36
37
|
// Check for this and schedule an update if work has occurred.
|
|
37
|
-
checkForUpdates(subscription.
|
|
38
|
+
checkForUpdates(subscription.value);
|
|
38
39
|
|
|
39
40
|
return () => {
|
|
40
41
|
didUnsubscribe = true;
|
|
@@ -42,5 +43,5 @@ export function useSubscription<Value>(
|
|
|
42
43
|
};
|
|
43
44
|
}, [subscription]);
|
|
44
45
|
|
|
45
|
-
return subscription.
|
|
46
|
+
return subscription.value;
|
|
46
47
|
}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type {SubscribableSignalLike} from '../../shared';
|
|
2
2
|
import {faker} from '@faker-js/faker';
|
|
3
3
|
|
|
4
4
|
import {ScopeNotGrantedError} from '../../errors';
|
|
5
5
|
import {useCustomer, useEmail, usePhone} from '../buyer-identity';
|
|
6
6
|
|
|
7
7
|
import {mount} from './mount';
|
|
8
|
-
|
|
9
8
|
function createMockCustomer(customer = {}) {
|
|
10
9
|
const firstName = faker.person.firstName();
|
|
11
10
|
const lastName = faker.person.lastName();
|
|
@@ -41,7 +40,7 @@ function createUsePhoneContext(phone?: string) {
|
|
|
41
40
|
return createMockHookContext(undefined, phone, undefined);
|
|
42
41
|
}
|
|
43
42
|
|
|
44
|
-
function createMockSuscribable<T>(data: T):
|
|
43
|
+
function createMockSuscribable<T>(data: T): SubscribableSignalLike<T> {
|
|
45
44
|
return {
|
|
46
45
|
current: data,
|
|
47
46
|
value: data,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import {createRender} from '@quilted/react-testing';
|
|
2
|
-
import type {
|
|
2
|
+
import type {SubscribableSignalLike} from '../../shared';
|
|
3
3
|
|
|
4
4
|
import type {
|
|
5
5
|
ApiForExtension,
|
|
@@ -39,8 +39,8 @@ interface Options {
|
|
|
39
39
|
|
|
40
40
|
export function createMockStatefulRemoteSubscribable<T>(
|
|
41
41
|
value: T,
|
|
42
|
-
):
|
|
43
|
-
const subscribable:
|
|
42
|
+
): SubscribableSignalLike<T> {
|
|
43
|
+
const subscribable: SubscribableSignalLike<T> = {
|
|
44
44
|
get current() {
|
|
45
45
|
return value;
|
|
46
46
|
},
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import type {ReadonlySignalLike} from '../../shared';
|
|
2
|
+
|
|
1
3
|
/**
|
|
2
4
|
* The list of supported components.
|
|
3
|
-
* As of
|
|
5
|
+
* As of October 1st, 2025, this is a subset of the components that will be available in the 2025-10 stable release.
|
|
4
6
|
*/
|
|
5
7
|
export const SUPPORTED_COMPONENTS = [
|
|
6
8
|
'Abbreviation',
|
|
@@ -9,8 +11,12 @@ export const SUPPORTED_COMPONENTS = [
|
|
|
9
11
|
'Box',
|
|
10
12
|
'Button',
|
|
11
13
|
'Checkbox',
|
|
14
|
+
'Choice',
|
|
15
|
+
'ChoiceList',
|
|
12
16
|
'Clickable',
|
|
13
17
|
'ClipboardItem',
|
|
18
|
+
'DateField',
|
|
19
|
+
'DatePicker',
|
|
14
20
|
'Details',
|
|
15
21
|
'Divider',
|
|
16
22
|
'DropZone',
|
|
@@ -26,15 +32,19 @@ export const SUPPORTED_COMPONENTS = [
|
|
|
26
32
|
'Map',
|
|
27
33
|
'MapMarker',
|
|
28
34
|
'Modal',
|
|
35
|
+
'MoneyField',
|
|
29
36
|
'NumberField',
|
|
30
37
|
'Option',
|
|
31
38
|
'OrderedList',
|
|
32
39
|
'Paragraph',
|
|
40
|
+
'PasswordField',
|
|
33
41
|
'PaymentIcon',
|
|
34
42
|
'PhoneField',
|
|
35
43
|
'Popover',
|
|
36
44
|
'ProductThumbnail',
|
|
45
|
+
'PressButton',
|
|
37
46
|
'Progress',
|
|
47
|
+
'QueryContainer',
|
|
38
48
|
'QRCode',
|
|
39
49
|
'ScrollBox',
|
|
40
50
|
'Section',
|
|
@@ -49,12 +59,13 @@ export const SUPPORTED_COMPONENTS = [
|
|
|
49
59
|
'TextArea',
|
|
50
60
|
'TextField',
|
|
51
61
|
'Time',
|
|
62
|
+
'Tooltip',
|
|
52
63
|
'UnorderedList',
|
|
53
64
|
'UrlField',
|
|
54
65
|
] as const;
|
|
55
66
|
|
|
56
67
|
/**
|
|
57
|
-
* Note: Chat is not supported in the 2025-
|
|
68
|
+
* Note: Chat is not supported in the 2025-10 release candidate, but it is tied to a target, and we don't want to remove the target documentation.
|
|
58
69
|
* Once Chat is supported, you can remove this note.
|
|
59
70
|
* @private
|
|
60
71
|
*/
|
|
@@ -62,7 +73,7 @@ export type PrivateComponent = 'Chat';
|
|
|
62
73
|
|
|
63
74
|
/**
|
|
64
75
|
* The list of supported components.
|
|
65
|
-
* As of
|
|
76
|
+
* As of October 1st, 2025, this is a subset of the components that will be available in the 2025-10 stable release.
|
|
66
77
|
*/
|
|
67
78
|
export type AnyComponent =
|
|
68
79
|
| (typeof SUPPORTED_COMPONENTS)[number]
|
|
@@ -73,3 +84,26 @@ export type AnyComponentExcept<Except extends AnyComponent> = Exclude<
|
|
|
73
84
|
AnyComponent,
|
|
74
85
|
Except
|
|
75
86
|
>;
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* Represents a read-only value managed on the main thread that an extension can subscribe to.
|
|
90
|
+
*
|
|
91
|
+
* Example: Checkout uses this to manage the state of an object and
|
|
92
|
+
* communicate state changes to extensions running in a sandboxed web worker.
|
|
93
|
+
*
|
|
94
|
+
* This interface is compatible with [Preact's ReadonlySignal](https://github.com/preactjs/signals/blob/a023a132a81bd4ba4a0bebb8cbbeffbd8c8bbafc/packages/core/src/index.ts#L700-L709).
|
|
95
|
+
*
|
|
96
|
+
* Some fields are deprecated but still supported for backwards compatibility.
|
|
97
|
+
* In version 2025-10, [`StatefulRemoteSubscribable`](https://github.com/Shopify/remote-dom/blob/03929aa8418a89d41d294005f219837582718df8/packages/async-subscription/src/types.ts#L17) was replaced with `ReadonlySignalLike`. Checkout will remove the old fields some time in the future.
|
|
98
|
+
*
|
|
99
|
+
*/
|
|
100
|
+
export interface SubscribableSignalLike<T> extends ReadonlySignalLike<T> {
|
|
101
|
+
/**
|
|
102
|
+
* @deprecated Use `.value` instead.
|
|
103
|
+
*/
|
|
104
|
+
readonly current: T;
|
|
105
|
+
/**
|
|
106
|
+
* @deprecated No longer needed. Use Preact Signal management instead.
|
|
107
|
+
*/
|
|
108
|
+
destroy(): Promise<void>;
|
|
109
|
+
}
|
package/src/surfaces/checkout.ts
CHANGED
|
@@ -86,6 +86,8 @@ export type {
|
|
|
86
86
|
ShippingAddress,
|
|
87
87
|
} from './checkout/api/shared';
|
|
88
88
|
|
|
89
|
+
export type {SubscribableSignalLike} from './checkout/shared';
|
|
90
|
+
|
|
89
91
|
export type {
|
|
90
92
|
RedeemableAttribute,
|
|
91
93
|
RedeemableChange,
|
|
@@ -183,8 +185,8 @@ export type {
|
|
|
183
185
|
} from './checkout/api/payment/payment-option-item';
|
|
184
186
|
|
|
185
187
|
export * from './checkout/extension-targets';
|
|
186
|
-
|
|
187
188
|
export * from './checkout/shared';
|
|
189
|
+
|
|
188
190
|
export {
|
|
189
191
|
Style,
|
|
190
192
|
isConditionalStyle,
|
|
@@ -12,13 +12,13 @@ export type CallbackEventListener<
|
|
|
12
12
|
export interface AvatarElementProps extends IdProps {
|
|
13
13
|
/**
|
|
14
14
|
* Initials to display in the avatar.
|
|
15
|
+
*
|
|
16
|
+
* Initials will be rendered as a fallback if `src` is not provided, fails to load or does not load quickly.
|
|
15
17
|
*/
|
|
16
18
|
initials?: string;
|
|
17
19
|
|
|
18
20
|
/**
|
|
19
21
|
* The URL or path to the image.
|
|
20
|
-
*
|
|
21
|
-
* Initials will be rendered as a fallback if `src` is not provided, fails to load or does not load quickly.
|
|
22
22
|
*/
|
|
23
23
|
src?: string;
|
|
24
24
|
|
package/src/surfaces/customer-account/components/ButtonGroup/examples/basic-ButtonGroup.example.html
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<s-button-group>
|
|
2
|
+
<s-button slot="primary-action" variant="primary">
|
|
3
|
+
Pay now
|
|
4
|
+
</s-button>
|
|
5
|
+
<s-button slot="secondary-actions" variant="secondary">
|
|
6
|
+
Edit order
|
|
7
|
+
</s-button>
|
|
8
|
+
<s-button slot="secondary-actions" variant="secondary">
|
|
9
|
+
Cancel order
|
|
10
|
+
</s-button>
|
|
11
|
+
</s-button-group>
|
|
@@ -9,11 +9,11 @@ export interface ButtonGroupProps extends IdProps {
|
|
|
9
9
|
|
|
10
10
|
export interface ButtonGroupElementSlots {
|
|
11
11
|
/**
|
|
12
|
-
* The primary action
|
|
12
|
+
* The primary action for the group. Accepts a single [Button](/docs/api/checkout-ui-extensions/polaris-web-components/actions/button) element.
|
|
13
13
|
*/
|
|
14
14
|
'primary-action'?: HTMLElement;
|
|
15
15
|
/**
|
|
16
|
-
* The secondary actions
|
|
16
|
+
* The secondary actions for the group. Accepts multiple [Button](/docs/api/checkout-ui-extensions/polaris-web-components/actions/button) elements.
|
|
17
17
|
*/
|
|
18
18
|
'secondary-actions'?: HTMLElement;
|
|
19
19
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<s-customer-account-action heading="My order action">
|
|
2
|
+
Modal content
|
|
3
|
+
<s-button
|
|
4
|
+
slot="primary-action"
|
|
5
|
+
onClick={() => console.log('pressed primary action')}
|
|
6
|
+
>
|
|
7
|
+
Primary
|
|
8
|
+
</s-button>
|
|
9
|
+
<s-button
|
|
10
|
+
slot="secondary-actions"
|
|
11
|
+
onClick={() => console.log('pressed secondary action')}
|
|
12
|
+
>
|
|
13
|
+
Secondary
|
|
14
|
+
</s-button>
|
|
15
|
+
</s-customer-account-action>
|
|
@@ -2,18 +2,18 @@ import {BaseElementPropsWithChildren, IdProps} from './shared';
|
|
|
2
2
|
|
|
3
3
|
export interface CustomerAccountActionProps extends IdProps {
|
|
4
4
|
/**
|
|
5
|
-
* Sets the heading of the
|
|
5
|
+
* Sets the heading of the action container.
|
|
6
6
|
*/
|
|
7
7
|
heading: string;
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
export interface CustomerAccountActionElementSlots {
|
|
11
11
|
/**
|
|
12
|
-
* The primary action
|
|
12
|
+
* The primary action for the page. Accepts a single Button element with restricted properties (see below).
|
|
13
13
|
*/
|
|
14
14
|
'primary-action'?: HTMLElement;
|
|
15
15
|
/**
|
|
16
|
-
* The secondary actions
|
|
16
|
+
* The secondary actions for the page. Accepts multiple Button elements with restricted properties (see below).
|
|
17
17
|
*/
|
|
18
18
|
'secondary-actions'?: HTMLElement;
|
|
19
19
|
}
|
package/src/surfaces/customer-account/components/ImageGroup/examples/basic-ImageGroup.example.html
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<s-image-group>
|
|
2
|
+
<s-image
|
|
3
|
+
src="https://cdn.shopify.com/YOUR_IMAGE_HERE"
|
|
4
|
+
alt="Product image"
|
|
5
|
+
></s-image>
|
|
6
|
+
<s-image
|
|
7
|
+
src="https://cdn.shopify.com/YOUR_IMAGE_HERE"
|
|
8
|
+
alt="Product image"
|
|
9
|
+
></s-image>
|
|
10
|
+
<s-image
|
|
11
|
+
src="https://cdn.shopify.com/YOUR_IMAGE_HERE"
|
|
12
|
+
alt="Product image"
|
|
13
|
+
></s-image>
|
|
14
|
+
<s-image
|
|
15
|
+
src="https://cdn.shopify.com/YOUR_IMAGE_HERE"
|
|
16
|
+
alt="Product image"
|
|
17
|
+
></s-image>
|
|
18
|
+
</s-image-group>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<>
|
|
2
|
+
<s-button commandFor="order-actions-menu">
|
|
3
|
+
Manage
|
|
4
|
+
</s-button>
|
|
5
|
+
|
|
6
|
+
<s-menu
|
|
7
|
+
id="order-actions-menu"
|
|
8
|
+
accessibilityLabel="List of order actions"
|
|
9
|
+
>
|
|
10
|
+
<s-button>Submit problem</s-button>
|
|
11
|
+
<s-button>Request return</s-button>
|
|
12
|
+
<s-button tone="critical">Cancel order</s-button>
|
|
13
|
+
</s-menu>
|
|
14
|
+
</>
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<s-page
|
|
2
|
+
heading="Order #1411"
|
|
3
|
+
subheading="Confirmed Oct 5"
|
|
4
|
+
>
|
|
5
|
+
<s-button slot="primary-action">
|
|
6
|
+
Buy again
|
|
7
|
+
</s-button>
|
|
8
|
+
<s-button slot="secondary-actions">
|
|
9
|
+
Edit order
|
|
10
|
+
</s-button>
|
|
11
|
+
<s-button slot="secondary-actions">
|
|
12
|
+
Cancel order
|
|
13
|
+
</s-button>
|
|
14
|
+
<s-button
|
|
15
|
+
slot="breadcrumb-actions"
|
|
16
|
+
accessibilityLabel="Back to orders"
|
|
17
|
+
></s-button>
|
|
18
|
+
Content
|
|
19
|
+
</s-page>
|
|
@@ -14,15 +14,15 @@ export interface PageProps extends IdProps {
|
|
|
14
14
|
|
|
15
15
|
export interface PageElementSlots {
|
|
16
16
|
/**
|
|
17
|
-
* The breadcrumb actions
|
|
17
|
+
* The breadcrumb actions for the page. Accepts a single Button element with restricted properties (see below).
|
|
18
18
|
*/
|
|
19
19
|
'breadcrumb-actions'?: HTMLElement;
|
|
20
20
|
/**
|
|
21
|
-
* The primary action
|
|
21
|
+
* The primary action for the page. Accepts a single Button element with restricted properties (see below).
|
|
22
22
|
*/
|
|
23
23
|
'primary-action'?: HTMLElement;
|
|
24
24
|
/**
|
|
25
|
-
* The secondary actions
|
|
25
|
+
* The secondary actions for the page. Accepts multiple Button elements with restricted properties (see below).
|
|
26
26
|
*/
|
|
27
27
|
'secondary-actions'?: HTMLElement;
|
|
28
28
|
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<s-section heading="Rewards">
|
|
2
|
+
<s-button slot="primary-action" variant="primary">
|
|
3
|
+
Redeem
|
|
4
|
+
</s-button>
|
|
5
|
+
<s-button slot="secondary-actions" variant="secondary">
|
|
6
|
+
My rewards
|
|
7
|
+
</s-button>
|
|
8
|
+
<s-paragraph>
|
|
9
|
+
Earn 10 points for every $1 spent. Redeem 100 points for $10 off your
|
|
10
|
+
next purchase.
|
|
11
|
+
</s-paragraph>
|
|
12
|
+
</s-section>
|
|
@@ -18,11 +18,11 @@ export interface SectionProps extends IdProps {
|
|
|
18
18
|
|
|
19
19
|
export interface SectionElementSlots {
|
|
20
20
|
/**
|
|
21
|
-
* The primary action
|
|
21
|
+
* The primary action for the section. Accepts a single [Button](/docs/api/checkout-ui-extensions/polaris-web-components/actions/button) element.
|
|
22
22
|
*/
|
|
23
23
|
'primary-action'?: HTMLElement;
|
|
24
24
|
/**
|
|
25
|
-
* The secondary actions
|
|
25
|
+
* The secondary actions for the section. Accepts multiple [Button](/docs/api/checkout-ui-extensions/polaris-web-components/actions/button) elements.
|
|
26
26
|
*/
|
|
27
27
|
'secondary-actions'?: HTMLElement;
|
|
28
28
|
}
|
|
@@ -12,7 +12,7 @@ export interface NavigationHistoryEntry {
|
|
|
12
12
|
/** Returns the key of the history entry. This is a unique, UA-generated value that represents the history entry's slot in the entries list rather than the entry itself. */
|
|
13
13
|
key: string;
|
|
14
14
|
/**
|
|
15
|
-
* Returns the URL of this history entry.
|
|
15
|
+
* Returns the lowercased URL of this history entry.
|
|
16
16
|
*/
|
|
17
17
|
url: string | null;
|
|
18
18
|
/**
|
|
@@ -35,7 +35,7 @@ export interface Navigation {
|
|
|
35
35
|
/**
|
|
36
36
|
* The navigate() method navigates to a specific URL, updating any provided state in the history entries list.
|
|
37
37
|
*/
|
|
38
|
-
navigate:
|
|
38
|
+
navigate: (url: string, options?: NavigationNavigateOptions) => void;
|
|
39
39
|
/**
|
|
40
40
|
* The currentEntry read-only property of the Navigation interface returns a NavigationHistoryEntry object representing the location the user is currently navigated to right now.
|
|
41
41
|
*/
|
|
@@ -53,11 +53,3 @@ export interface Navigation {
|
|
|
53
53
|
cb: (event: NavigationCurrentEntryChangeEvent) => void,
|
|
54
54
|
): void;
|
|
55
55
|
}
|
|
56
|
-
|
|
57
|
-
export interface NavigateFunction {
|
|
58
|
-
/**
|
|
59
|
-
* Navigates to a specific URL, updating any provided state in the history entries list.
|
|
60
|
-
* @param url The destination URL to navigate to.
|
|
61
|
-
*/
|
|
62
|
-
(url: string, options?: NavigationNavigateOptions): void;
|
|
63
|
-
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
<s-badge tone="neutral">
|
|
2
|
-
<s-badge tone="success">
|
|
3
|
-
<s-badge tone="info">
|
|
4
|
-
<s-badge tone="warning">
|
|
5
|
-
<s-badge tone="critical">
|
|
1
|
+
<s-badge tone="neutral">Paid</s-badge>
|
|
2
|
+
<s-badge tone="success">Active</s-badge>
|
|
3
|
+
<s-badge tone="info">Draft</s-badge>
|
|
4
|
+
<s-badge tone="warning">On hold</s-badge>
|
|
5
|
+
<s-badge tone="critical">Action required</s-badge>
|
|
@@ -33,12 +33,21 @@ export interface BaseElementPropsWithChildren<TClass = HTMLElement>
|
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
declare const tagName = 's-banner';
|
|
36
|
-
export interface BannerJSXProps
|
|
37
|
-
|
|
36
|
+
export interface BannerJSXProps extends Pick<BannerProps, 'heading' | 'id'> {
|
|
37
|
+
/**
|
|
38
|
+
* Determines whether the banner is hidden.
|
|
39
|
+
*/
|
|
40
|
+
hidden?: BannerProps['hidden'];
|
|
41
|
+
/**
|
|
42
|
+
* Sets the tone of the Banner, based on the intention of the information being conveyed.
|
|
43
|
+
*/
|
|
38
44
|
tone?: Extract<
|
|
39
45
|
BannerProps['tone'],
|
|
40
46
|
'success' | 'info' | 'warning' | 'critical'
|
|
41
47
|
>;
|
|
48
|
+
/**
|
|
49
|
+
* The action taken when the Banner is pressed.
|
|
50
|
+
*/
|
|
42
51
|
primaryAction?: ComponentChild;
|
|
43
52
|
children?: ComponentChildren;
|
|
44
53
|
}
|
|
@@ -38,14 +38,39 @@ export interface CallbackEvent<T extends keyof HTMLElementTagNameMap> {
|
|
|
38
38
|
|
|
39
39
|
declare const tagName = 's-button';
|
|
40
40
|
export interface ButtonJSXProps
|
|
41
|
-
extends Pick<
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
41
|
+
extends Pick<ButtonProps, 'disabled' | 'command' | 'commandFor' | 'loading'> {
|
|
42
|
+
/**
|
|
43
|
+
* Sets the action the `commandFor` should take when this clickable is activated.
|
|
44
|
+
*
|
|
45
|
+
* See the documentation of particular components for the actions they support.
|
|
46
|
+
*
|
|
47
|
+
* - `--auto`: a default action for the target component.
|
|
48
|
+
* - `--show`: shows the target component.
|
|
49
|
+
* - `--hide`: hides the target component.
|
|
50
|
+
* - `--toggle`: toggles the target component.
|
|
51
|
+
*
|
|
52
|
+
* @default '--auto'
|
|
53
|
+
*
|
|
54
|
+
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#command
|
|
55
|
+
*/
|
|
56
|
+
command?: Extract<
|
|
57
|
+
ButtonProps['command'],
|
|
58
|
+
'--auto' | '--show' | '--hide' | '--toggle'
|
|
59
|
+
>;
|
|
60
|
+
/**
|
|
61
|
+
* Sets the tone of the Button, based on the intention of the information being conveyed.
|
|
62
|
+
*
|
|
63
|
+
* @default 'auto'
|
|
64
|
+
*/
|
|
45
65
|
tone?: Extract<
|
|
46
66
|
ButtonProps['tone'],
|
|
47
67
|
'auto' | 'critical' | 'neutral' | 'warning' | 'caution'
|
|
48
68
|
>;
|
|
69
|
+
/**
|
|
70
|
+
* Changes the visual appearance of the Button.
|
|
71
|
+
*
|
|
72
|
+
* @default 'auto' - the variant is automatically determined by the Button's context
|
|
73
|
+
*/
|
|
49
74
|
variant?: Extract<ButtonProps['variant'], 'primary' | 'secondary'>;
|
|
50
75
|
onClick?: (event: CallbackEvent<typeof tagName>) => void;
|
|
51
76
|
children?: ComponentChildren;
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
/* eslint-disable import-x/namespace */
|
|
9
9
|
// eslint-disable-next-line @typescript-eslint/triple-slash-reference, spaced-comment
|
|
10
10
|
/// <reference lib="DOM" />
|
|
11
|
-
import type {Key, Ref} from './components-shared.d.ts';
|
|
11
|
+
import type {DividerProps, Key, Ref} from './components-shared.d.ts';
|
|
12
12
|
|
|
13
13
|
export type ComponentChildren = any;
|
|
14
14
|
/**
|
|
@@ -27,24 +27,21 @@ export interface BaseElementPropsWithChildren<TClass = HTMLElement>
|
|
|
27
27
|
children?: ComponentChildren;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
declare const tagName = 's-
|
|
31
|
-
export interface
|
|
32
|
-
initialScreenName?: string;
|
|
33
|
-
children?: React.ReactNode;
|
|
34
|
-
}
|
|
30
|
+
declare const tagName = 's-divider';
|
|
31
|
+
export interface DividerJSXProps extends Pick<DividerProps, 'direction'> {}
|
|
35
32
|
declare global {
|
|
36
33
|
interface HTMLElementTagNameMap {
|
|
37
|
-
[tagName]:
|
|
34
|
+
[tagName]: DividerJSXProps;
|
|
38
35
|
}
|
|
39
36
|
}
|
|
40
37
|
declare module 'preact' {
|
|
41
38
|
namespace createElement.JSX {
|
|
42
39
|
interface IntrinsicElements {
|
|
43
|
-
[tagName]:
|
|
44
|
-
BaseElementPropsWithChildren<
|
|
40
|
+
[tagName]: DividerJSXProps &
|
|
41
|
+
BaseElementPropsWithChildren<DividerJSXProps>;
|
|
45
42
|
}
|
|
46
43
|
}
|
|
47
44
|
}
|
|
48
45
|
|
|
49
46
|
export {tagName};
|
|
50
|
-
export type {
|
|
47
|
+
export type {DividerJSXProps};
|
|
@@ -14,7 +14,6 @@ import type {
|
|
|
14
14
|
Ref,
|
|
15
15
|
ComponentChild,
|
|
16
16
|
} from './components-shared.d.ts';
|
|
17
|
-
import {ReactNode} from 'react';
|
|
18
17
|
|
|
19
18
|
export type ComponentChildren = any;
|
|
20
19
|
/**
|
|
@@ -48,7 +47,7 @@ export interface ModalJSXProps extends Pick<ModalProps, 'id' | 'heading'> {
|
|
|
48
47
|
secondaryActions?: ComponentChild;
|
|
49
48
|
onHide?: (event: CallbackEvent<typeof tagName>) => void | null;
|
|
50
49
|
onShow?: (event: CallbackEvent<typeof tagName>) => void | null;
|
|
51
|
-
children?:
|
|
50
|
+
children?: ComponentChildren;
|
|
52
51
|
}
|
|
53
52
|
declare global {
|
|
54
53
|
interface HTMLElementTagNameMap {
|
|
@@ -35,12 +35,12 @@ export interface BaseElementPropsWithChildren<TClass = HTMLElement>
|
|
|
35
35
|
declare const tagName = 's-page';
|
|
36
36
|
export type PickedProps = Pick<
|
|
37
37
|
PageProps,
|
|
38
|
-
'heading' | 'subheading' | 'secondaryActions'
|
|
38
|
+
'heading' | 'subheading' | 'secondaryActions' | 'aside'
|
|
39
39
|
>;
|
|
40
40
|
export interface PageJSXProps extends PickedProps {
|
|
41
41
|
children?: ComponentChildren;
|
|
42
42
|
secondaryActions?: ComponentChild;
|
|
43
|
-
|
|
43
|
+
aside?: ComponentChild;
|
|
44
44
|
}
|
|
45
45
|
declare global {
|
|
46
46
|
interface HTMLElementTagNameMap {
|
|
@@ -50,9 +50,9 @@ declare global {
|
|
|
50
50
|
declare module 'preact' {
|
|
51
51
|
namespace createElement.JSX {
|
|
52
52
|
interface IntrinsicElements {
|
|
53
|
-
[tagName]: Omit<PageJSXProps, '
|
|
53
|
+
[tagName]: Omit<PageJSXProps, 'secondaryActions' | 'aside'> &
|
|
54
54
|
BaseElementPropsWithChildren<
|
|
55
|
-
Omit<PageJSXProps, '
|
|
55
|
+
Omit<PageJSXProps, 'secondaryActions' | 'aside'>
|
|
56
56
|
>;
|
|
57
57
|
}
|
|
58
58
|
}
|