@shopify/ui-extensions 2022.10.5 → 2023.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (706) hide show
  1. package/README.md +1 -1
  2. package/build/cjs/surfaces/admin/components/AdminAction/AdminAction.js +12 -0
  3. package/build/cjs/surfaces/admin/components/AdminBlock/AdminBlock.js +9 -0
  4. package/build/cjs/surfaces/admin/components/BlockStack/BlockStack.js +9 -0
  5. package/build/cjs/surfaces/admin/components/Box/Box.js +9 -0
  6. package/build/cjs/surfaces/admin/components/Button/Button.js +9 -0
  7. package/build/cjs/surfaces/admin/components/Checkbox/Checkbox.js +9 -0
  8. package/build/cjs/surfaces/admin/components/CustomerSegmentationTemplate/CustomerSegmentationTemplate.js +12 -0
  9. package/build/cjs/surfaces/admin/components/Divider/Divider.js +9 -0
  10. package/build/cjs/surfaces/admin/components/EmailField/EmailField.js +9 -0
  11. package/build/cjs/surfaces/admin/components/Form/Form.js +9 -0
  12. package/build/cjs/surfaces/admin/components/Heading/Heading.js +9 -0
  13. package/build/cjs/surfaces/admin/components/HeadingGroup/HeadingGroup.js +9 -0
  14. package/build/cjs/surfaces/admin/components/Icon/Icon.js +9 -0
  15. package/build/cjs/surfaces/admin/components/Image/Image.js +9 -0
  16. package/build/cjs/surfaces/admin/components/InlineStack/InlineStack.js +9 -0
  17. package/build/cjs/surfaces/admin/components/Link/Link.js +9 -0
  18. package/build/cjs/surfaces/admin/components/NumberField/NumberField.js +9 -0
  19. package/build/cjs/surfaces/admin/components/PasswordField/PasswordField.js +9 -0
  20. package/build/cjs/surfaces/admin/components/Select/Select.js +9 -0
  21. package/build/cjs/surfaces/admin/components/Text/Text.js +9 -0
  22. package/build/cjs/surfaces/admin/components/TextArea/TextArea.js +9 -0
  23. package/build/cjs/surfaces/admin/components/TextField/TextField.js +9 -0
  24. package/build/cjs/surfaces/admin/components/URLField/URLField.js +9 -0
  25. package/build/cjs/surfaces/admin/extension.js +11 -0
  26. package/build/cjs/surfaces/admin.js +56 -0
  27. package/build/cjs/surfaces/checkout/components/DateField/DateField.js +13 -0
  28. package/build/cjs/surfaces/checkout/components/DatePicker/DatePicker.js +22 -0
  29. package/build/cjs/surfaces/checkout/components/Disclosure/Disclosure.js +20 -0
  30. package/build/cjs/surfaces/checkout/components/Modal/Modal.js +17 -0
  31. package/build/cjs/surfaces/checkout/components/Popover/Popover.js +17 -0
  32. package/build/cjs/surfaces/checkout/components/View/View.js +0 -3
  33. package/build/cjs/surfaces/checkout/extension.js +35 -2
  34. package/build/cjs/surfaces/checkout/style/memoize.js +2 -0
  35. package/build/cjs/surfaces/checkout/style/style.js +0 -1
  36. package/build/cjs/surfaces/checkout.js +11 -0
  37. package/build/cjs/utilities/registration.js +26 -2
  38. package/build/esm/surfaces/admin/components/AdminAction/AdminAction.mjs +8 -0
  39. package/build/esm/surfaces/admin/components/AdminBlock/AdminBlock.mjs +5 -0
  40. package/build/esm/surfaces/admin/components/BlockStack/BlockStack.mjs +5 -0
  41. package/build/esm/surfaces/admin/components/Box/Box.mjs +5 -0
  42. package/build/esm/surfaces/admin/components/Button/Button.mjs +5 -0
  43. package/build/esm/surfaces/admin/components/Checkbox/Checkbox.mjs +5 -0
  44. package/build/esm/surfaces/admin/components/CustomerSegmentationTemplate/CustomerSegmentationTemplate.mjs +8 -0
  45. package/build/esm/surfaces/admin/components/Divider/Divider.mjs +5 -0
  46. package/build/esm/surfaces/admin/components/EmailField/EmailField.mjs +5 -0
  47. package/build/esm/surfaces/admin/components/Form/Form.mjs +5 -0
  48. package/build/esm/surfaces/admin/components/Heading/Heading.mjs +5 -0
  49. package/build/esm/surfaces/admin/components/HeadingGroup/HeadingGroup.mjs +5 -0
  50. package/build/esm/surfaces/admin/components/Icon/Icon.mjs +5 -0
  51. package/build/esm/surfaces/admin/components/Image/Image.mjs +5 -0
  52. package/build/esm/surfaces/admin/components/InlineStack/InlineStack.mjs +5 -0
  53. package/build/esm/surfaces/admin/components/Link/Link.mjs +5 -0
  54. package/build/esm/surfaces/admin/components/NumberField/NumberField.mjs +5 -0
  55. package/build/esm/surfaces/admin/components/PasswordField/PasswordField.mjs +5 -0
  56. package/build/esm/surfaces/admin/components/Select/Select.mjs +5 -0
  57. package/build/esm/surfaces/admin/components/Text/Text.mjs +5 -0
  58. package/build/esm/surfaces/admin/components/TextArea/TextArea.mjs +5 -0
  59. package/build/esm/surfaces/admin/components/TextField/TextField.mjs +5 -0
  60. package/build/esm/surfaces/admin/components/URLField/URLField.mjs +5 -0
  61. package/build/esm/surfaces/admin/extension.mjs +6 -0
  62. package/build/esm/surfaces/admin.mjs +24 -0
  63. package/build/esm/surfaces/checkout/components/DateField/DateField.mjs +9 -0
  64. package/build/esm/surfaces/checkout/components/DatePicker/DatePicker.mjs +18 -0
  65. package/build/esm/surfaces/checkout/components/Disclosure/Disclosure.mjs +16 -0
  66. package/build/esm/surfaces/checkout/components/Modal/Modal.mjs +13 -0
  67. package/build/esm/surfaces/checkout/components/Popover/Popover.mjs +13 -0
  68. package/build/esm/surfaces/checkout/components/View/View.mjs +0 -3
  69. package/build/esm/surfaces/checkout/extension.mjs +35 -3
  70. package/build/esm/surfaces/checkout/style/memoize.mjs +2 -0
  71. package/build/esm/surfaces/checkout/style/style.mjs +0 -1
  72. package/build/esm/surfaces/checkout.mjs +6 -1
  73. package/build/esm/utilities/registration.mjs +26 -2
  74. package/build/esnext/surfaces/admin/components/AdminAction/AdminAction.esnext +8 -0
  75. package/build/esnext/surfaces/admin/components/AdminBlock/AdminBlock.esnext +5 -0
  76. package/build/esnext/surfaces/admin/components/BlockStack/BlockStack.esnext +5 -0
  77. package/build/esnext/surfaces/admin/components/Box/Box.esnext +5 -0
  78. package/build/esnext/surfaces/admin/components/Button/Button.esnext +5 -0
  79. package/build/esnext/surfaces/admin/components/Checkbox/Checkbox.esnext +5 -0
  80. package/build/esnext/surfaces/admin/components/CustomerSegmentationTemplate/CustomerSegmentationTemplate.esnext +8 -0
  81. package/build/esnext/surfaces/admin/components/Divider/Divider.esnext +5 -0
  82. package/build/esnext/surfaces/admin/components/EmailField/EmailField.esnext +5 -0
  83. package/build/esnext/surfaces/admin/components/Form/Form.esnext +5 -0
  84. package/build/esnext/surfaces/admin/components/Heading/Heading.esnext +5 -0
  85. package/build/esnext/surfaces/admin/components/HeadingGroup/HeadingGroup.esnext +5 -0
  86. package/build/esnext/surfaces/admin/components/Icon/Icon.esnext +5 -0
  87. package/build/esnext/surfaces/admin/components/Image/Image.esnext +5 -0
  88. package/build/esnext/surfaces/admin/components/InlineStack/InlineStack.esnext +5 -0
  89. package/build/esnext/surfaces/admin/components/Link/Link.esnext +5 -0
  90. package/build/esnext/surfaces/admin/components/NumberField/NumberField.esnext +5 -0
  91. package/build/esnext/surfaces/admin/components/PasswordField/PasswordField.esnext +5 -0
  92. package/build/esnext/surfaces/admin/components/Select/Select.esnext +5 -0
  93. package/build/esnext/surfaces/admin/components/Text/Text.esnext +5 -0
  94. package/build/esnext/surfaces/admin/components/TextArea/TextArea.esnext +5 -0
  95. package/build/esnext/surfaces/admin/components/TextField/TextField.esnext +5 -0
  96. package/build/esnext/surfaces/admin/components/URLField/URLField.esnext +5 -0
  97. package/build/esnext/surfaces/admin/extension.esnext +6 -0
  98. package/build/esnext/surfaces/admin.esnext +24 -0
  99. package/build/esnext/surfaces/checkout/components/DateField/DateField.esnext +9 -0
  100. package/build/esnext/surfaces/checkout/components/DatePicker/DatePicker.esnext +18 -0
  101. package/build/esnext/surfaces/checkout/components/Disclosure/Disclosure.esnext +16 -0
  102. package/build/esnext/surfaces/checkout/components/Modal/Modal.esnext +13 -0
  103. package/build/esnext/surfaces/checkout/components/Popover/Popover.esnext +13 -0
  104. package/build/esnext/surfaces/checkout/components/View/View.esnext +0 -3
  105. package/build/esnext/surfaces/checkout/extension.esnext +35 -3
  106. package/build/esnext/surfaces/checkout/style/memoize.esnext +2 -0
  107. package/build/esnext/surfaces/checkout/style/style.esnext +0 -1
  108. package/build/esnext/surfaces/checkout.esnext +6 -1
  109. package/build/esnext/utilities/registration.esnext +26 -2
  110. package/build/ts/api.d.ts +62 -0
  111. package/build/ts/api.d.ts.map +1 -1
  112. package/build/ts/extension.d.ts +8 -1
  113. package/build/ts/extension.d.ts.map +1 -1
  114. package/build/ts/index.d.ts +0 -1
  115. package/build/ts/index.d.ts.map +1 -1
  116. package/build/ts/shared.d.ts +6 -0
  117. package/build/ts/shared.d.ts.map +1 -0
  118. package/build/ts/surfaces/admin/api/action/action.d.ts +11 -0
  119. package/build/ts/surfaces/admin/api/action/action.d.ts.map +1 -0
  120. package/build/ts/surfaces/admin/api/action/action.doc.d.ts +4 -0
  121. package/build/ts/surfaces/admin/api/action/action.doc.d.ts.map +1 -0
  122. package/build/ts/surfaces/admin/api/customer-segmentation-template/customer-segmentation-template.d.ts +11 -0
  123. package/build/ts/surfaces/admin/api/customer-segmentation-template/customer-segmentation-template.d.ts.map +1 -0
  124. package/build/ts/surfaces/admin/api/extension-targets/extension-targets.doc.d.ts +4 -0
  125. package/build/ts/surfaces/admin/api/extension-targets/extension-targets.doc.d.ts.map +1 -0
  126. package/build/ts/surfaces/admin/api/standard/standard.d.ts +13 -0
  127. package/build/ts/surfaces/admin/api/standard/standard.d.ts.map +1 -0
  128. package/build/ts/surfaces/admin/api/standard/standard.doc.d.ts +4 -0
  129. package/build/ts/surfaces/admin/api/standard/standard.doc.d.ts.map +1 -0
  130. package/build/ts/surfaces/admin/api.d.ts +5 -0
  131. package/build/ts/surfaces/admin/api.d.ts.map +1 -0
  132. package/build/ts/surfaces/admin/components/AdminAction/AdminAction.d.ts +25 -0
  133. package/build/ts/surfaces/admin/components/AdminAction/AdminAction.d.ts.map +1 -0
  134. package/build/ts/surfaces/admin/components/AdminAction/AdminAction.doc.d.ts +4 -0
  135. package/build/ts/surfaces/admin/components/AdminAction/AdminAction.doc.d.ts.map +1 -0
  136. package/build/ts/surfaces/admin/components/AdminBlock/AdminBlock.d.ts +17 -0
  137. package/build/ts/surfaces/admin/components/AdminBlock/AdminBlock.d.ts.map +1 -0
  138. package/build/ts/surfaces/admin/components/AdminBlock/AdminBlock.doc.d.ts +4 -0
  139. package/build/ts/surfaces/admin/components/AdminBlock/AdminBlock.doc.d.ts.map +1 -0
  140. package/build/ts/surfaces/admin/components/BlockStack/BlockStack.d.ts +15 -0
  141. package/build/ts/surfaces/admin/components/BlockStack/BlockStack.d.ts.map +1 -0
  142. package/build/ts/surfaces/admin/components/BlockStack/BlockStack.doc.d.ts +4 -0
  143. package/build/ts/surfaces/admin/components/BlockStack/BlockStack.doc.d.ts.map +1 -0
  144. package/build/ts/surfaces/admin/components/Box/Box.d.ts +9 -0
  145. package/build/ts/surfaces/admin/components/Box/Box.d.ts.map +1 -0
  146. package/build/ts/surfaces/admin/components/Box/Box.doc.d.ts +4 -0
  147. package/build/ts/surfaces/admin/components/Box/Box.doc.d.ts.map +1 -0
  148. package/build/ts/surfaces/admin/components/Button/Button.d.ts +87 -0
  149. package/build/ts/surfaces/admin/components/Button/Button.d.ts.map +1 -0
  150. package/build/ts/surfaces/admin/components/Button/Button.doc.d.ts +4 -0
  151. package/build/ts/surfaces/admin/components/Button/Button.doc.d.ts.map +1 -0
  152. package/build/ts/surfaces/admin/components/Checkbox/Checkbox.d.ts +55 -0
  153. package/build/ts/surfaces/admin/components/Checkbox/Checkbox.d.ts.map +1 -0
  154. package/build/ts/surfaces/admin/components/Checkbox/Checkbox.doc.d.ts +4 -0
  155. package/build/ts/surfaces/admin/components/Checkbox/Checkbox.doc.d.ts.map +1 -0
  156. package/build/ts/surfaces/admin/components/CustomerSegmentationTemplate/CustomerSegmentationTemplate.d.ts +27 -0
  157. package/build/ts/surfaces/admin/components/CustomerSegmentationTemplate/CustomerSegmentationTemplate.d.ts.map +1 -0
  158. package/build/ts/surfaces/admin/components/Divider/Divider.d.ts +14 -0
  159. package/build/ts/surfaces/admin/components/Divider/Divider.d.ts.map +1 -0
  160. package/build/ts/surfaces/admin/components/Divider/Divider.doc.d.ts +4 -0
  161. package/build/ts/surfaces/admin/components/Divider/Divider.doc.d.ts.map +1 -0
  162. package/build/ts/surfaces/admin/components/EmailField/EmailField.d.ts +10 -0
  163. package/build/ts/surfaces/admin/components/EmailField/EmailField.d.ts.map +1 -0
  164. package/build/ts/surfaces/admin/components/EmailField/EmailField.doc.d.ts +4 -0
  165. package/build/ts/surfaces/admin/components/EmailField/EmailField.doc.d.ts.map +1 -0
  166. package/build/ts/surfaces/admin/components/Form/Form.d.ts +30 -0
  167. package/build/ts/surfaces/admin/components/Form/Form.d.ts.map +1 -0
  168. package/build/ts/surfaces/admin/components/Form/Form.doc.d.ts +4 -0
  169. package/build/ts/surfaces/admin/components/Form/Form.doc.d.ts.map +1 -0
  170. package/build/ts/surfaces/admin/components/Heading/Heading.d.ts +14 -0
  171. package/build/ts/surfaces/admin/components/Heading/Heading.d.ts.map +1 -0
  172. package/build/ts/surfaces/admin/components/Heading/Heading.doc.d.ts +4 -0
  173. package/build/ts/surfaces/admin/components/Heading/Heading.doc.d.ts.map +1 -0
  174. package/build/ts/surfaces/admin/components/HeadingGroup/HeadingGroup.d.ts +8 -0
  175. package/build/ts/surfaces/admin/components/HeadingGroup/HeadingGroup.d.ts.map +1 -0
  176. package/build/ts/surfaces/admin/components/HeadingGroup/HeadingGroup.doc.d.ts +4 -0
  177. package/build/ts/surfaces/admin/components/HeadingGroup/HeadingGroup.doc.d.ts.map +1 -0
  178. package/build/ts/surfaces/admin/components/Icon/Icon.d.ts +23 -0
  179. package/build/ts/surfaces/admin/components/Icon/Icon.d.ts.map +1 -0
  180. package/build/ts/surfaces/admin/components/Icon/Icon.doc.d.ts +4 -0
  181. package/build/ts/surfaces/admin/components/Icon/Icon.doc.d.ts.map +1 -0
  182. package/build/ts/surfaces/admin/components/Image/Image.d.ts +114 -0
  183. package/build/ts/surfaces/admin/components/Image/Image.d.ts.map +1 -0
  184. package/build/ts/surfaces/admin/components/Image/Image.doc.d.ts +4 -0
  185. package/build/ts/surfaces/admin/components/Image/Image.doc.d.ts.map +1 -0
  186. package/build/ts/surfaces/admin/components/InlineStack/InlineStack.d.ts +15 -0
  187. package/build/ts/surfaces/admin/components/InlineStack/InlineStack.d.ts.map +1 -0
  188. package/build/ts/surfaces/admin/components/InlineStack/InlineStack.doc.d.ts +4 -0
  189. package/build/ts/surfaces/admin/components/InlineStack/InlineStack.doc.d.ts.map +1 -0
  190. package/build/ts/surfaces/admin/components/Link/Link.d.ts +57 -0
  191. package/build/ts/surfaces/admin/components/Link/Link.d.ts.map +1 -0
  192. package/build/ts/surfaces/admin/components/Link/Link.doc.d.ts +4 -0
  193. package/build/ts/surfaces/admin/components/Link/Link.doc.d.ts.map +1 -0
  194. package/build/ts/surfaces/admin/components/NumberField/NumberField.d.ts +41 -0
  195. package/build/ts/surfaces/admin/components/NumberField/NumberField.d.ts.map +1 -0
  196. package/build/ts/surfaces/admin/components/NumberField/NumberField.doc.d.ts +4 -0
  197. package/build/ts/surfaces/admin/components/NumberField/NumberField.doc.d.ts.map +1 -0
  198. package/build/ts/surfaces/admin/components/PasswordField/PasswordField.d.ts +10 -0
  199. package/build/ts/surfaces/admin/components/PasswordField/PasswordField.d.ts.map +1 -0
  200. package/build/ts/surfaces/admin/components/PasswordField/PasswordField.doc.d.ts +4 -0
  201. package/build/ts/surfaces/admin/components/PasswordField/PasswordField.doc.d.ts.map +1 -0
  202. package/build/ts/surfaces/admin/components/Select/Select.d.ts +127 -0
  203. package/build/ts/surfaces/admin/components/Select/Select.d.ts.map +1 -0
  204. package/build/ts/surfaces/admin/components/Select/Select.doc.d.ts +4 -0
  205. package/build/ts/surfaces/admin/components/Select/Select.doc.d.ts.map +1 -0
  206. package/build/ts/surfaces/admin/components/Text/Text.d.ts +97 -0
  207. package/build/ts/surfaces/admin/components/Text/Text.d.ts.map +1 -0
  208. package/build/ts/surfaces/admin/components/Text/Text.doc.d.ts +4 -0
  209. package/build/ts/surfaces/admin/components/Text/Text.doc.d.ts.map +1 -0
  210. package/build/ts/surfaces/admin/components/TextArea/TextArea.d.ts +15 -0
  211. package/build/ts/surfaces/admin/components/TextArea/TextArea.d.ts.map +1 -0
  212. package/build/ts/surfaces/admin/components/TextArea/TextArea.doc.d.ts +4 -0
  213. package/build/ts/surfaces/admin/components/TextArea/TextArea.doc.d.ts.map +1 -0
  214. package/build/ts/surfaces/admin/components/TextField/TextField.d.ts +9 -0
  215. package/build/ts/surfaces/admin/components/TextField/TextField.d.ts.map +1 -0
  216. package/build/ts/surfaces/admin/components/TextField/TextField.doc.d.ts +4 -0
  217. package/build/ts/surfaces/admin/components/TextField/TextField.doc.d.ts.map +1 -0
  218. package/build/ts/surfaces/admin/components/URLField/URLField.d.ts +10 -0
  219. package/build/ts/surfaces/admin/components/URLField/URLField.d.ts.map +1 -0
  220. package/build/ts/surfaces/admin/components/URLField/URLField.doc.d.ts +4 -0
  221. package/build/ts/surfaces/admin/components/URLField/URLField.doc.d.ts.map +1 -0
  222. package/build/ts/surfaces/admin/components/shared/index.d.ts +443 -0
  223. package/build/ts/surfaces/admin/components/shared/index.d.ts.map +1 -0
  224. package/build/ts/surfaces/admin/components.d.ts +47 -0
  225. package/build/ts/surfaces/admin/components.d.ts.map +1 -0
  226. package/build/ts/surfaces/admin/extension-points.d.ts +64 -0
  227. package/build/ts/surfaces/admin/extension-points.d.ts.map +1 -0
  228. package/build/ts/surfaces/admin/extension.d.ts +5 -0
  229. package/build/ts/surfaces/admin/extension.d.ts.map +1 -0
  230. package/build/ts/surfaces/admin/globals.d.ts +5 -0
  231. package/build/ts/surfaces/admin/globals.d.ts.map +1 -0
  232. package/build/ts/surfaces/admin/shared.d.ts +6 -0
  233. package/build/ts/surfaces/admin/shared.d.ts.map +1 -0
  234. package/build/ts/surfaces/admin.d.ts +7 -0
  235. package/build/ts/surfaces/admin.d.ts.map +1 -0
  236. package/build/ts/surfaces/checkout/api/cart-line/cart-line-details.d.ts +9 -0
  237. package/build/ts/surfaces/checkout/api/cart-line/cart-line-details.d.ts.map +1 -0
  238. package/build/ts/surfaces/checkout/api/checkout/checkout.d.ts +367 -0
  239. package/build/ts/surfaces/checkout/api/checkout/checkout.d.ts.map +1 -0
  240. package/build/ts/surfaces/checkout/api/order-status/order-status.d.ts +27 -0
  241. package/build/ts/surfaces/checkout/api/order-status/order-status.d.ts.map +1 -0
  242. package/build/ts/surfaces/checkout/api/payment-method/render.d.ts +44 -0
  243. package/build/ts/surfaces/checkout/api/payment-method/render.d.ts.map +1 -0
  244. package/build/ts/surfaces/checkout/api/pickup/pickup-locations.d.ts +8 -0
  245. package/build/ts/surfaces/checkout/api/pickup/pickup-locations.d.ts.map +1 -0
  246. package/build/ts/surfaces/checkout/api/pickup/pickup-points.d.ts +8 -0
  247. package/build/ts/surfaces/checkout/api/pickup/pickup-points.d.ts.map +1 -0
  248. package/build/ts/surfaces/checkout/api/redeemable/render.d.ts +44 -0
  249. package/build/ts/surfaces/checkout/api/redeemable/render.d.ts.map +1 -0
  250. package/build/ts/surfaces/checkout/api/shared.d.ts +46 -0
  251. package/build/ts/surfaces/checkout/api/shared.d.ts.map +1 -1
  252. package/build/ts/surfaces/checkout/api/shipping/shipping-method-details.d.ts +13 -0
  253. package/build/ts/surfaces/checkout/api/shipping/shipping-method-details.d.ts.map +1 -0
  254. package/build/ts/surfaces/checkout/api/standard/standard.d.ts +562 -406
  255. package/build/ts/surfaces/checkout/api/standard/standard.d.ts.map +1 -1
  256. package/build/ts/surfaces/checkout/api.d.ts +10 -3
  257. package/build/ts/surfaces/checkout/api.d.ts.map +1 -1
  258. package/build/ts/surfaces/checkout/components/Banner/Banner.d.ts +2 -2
  259. package/build/ts/surfaces/checkout/components/Banner/Banner.d.ts.map +1 -1
  260. package/build/ts/surfaces/checkout/components/Banner/Banner.doc.d.ts +4 -0
  261. package/build/ts/surfaces/checkout/components/Banner/Banner.doc.d.ts.map +1 -0
  262. package/build/ts/surfaces/checkout/components/BlockLayout/BlockLayout.doc.d.ts +4 -0
  263. package/build/ts/surfaces/checkout/components/BlockLayout/BlockLayout.doc.d.ts.map +1 -0
  264. package/build/ts/surfaces/checkout/components/BlockSpacer/BlockSpacer.d.ts +2 -2
  265. package/build/ts/surfaces/checkout/components/BlockSpacer/BlockSpacer.d.ts.map +1 -1
  266. package/build/ts/surfaces/checkout/components/BlockSpacer/BlockSpacer.doc.d.ts +4 -0
  267. package/build/ts/surfaces/checkout/components/BlockSpacer/BlockSpacer.doc.d.ts.map +1 -0
  268. package/build/ts/surfaces/checkout/components/BlockStack/BlockStack.d.ts +20 -4
  269. package/build/ts/surfaces/checkout/components/BlockStack/BlockStack.d.ts.map +1 -1
  270. package/build/ts/surfaces/checkout/components/BlockStack/BlockStack.doc.d.ts +4 -0
  271. package/build/ts/surfaces/checkout/components/BlockStack/BlockStack.doc.d.ts.map +1 -0
  272. package/build/ts/surfaces/checkout/components/Button/Button.d.ts +3 -4
  273. package/build/ts/surfaces/checkout/components/Button/Button.d.ts.map +1 -1
  274. package/build/ts/surfaces/checkout/components/Button/Button.doc.d.ts +4 -0
  275. package/build/ts/surfaces/checkout/components/Button/Button.doc.d.ts.map +1 -0
  276. package/build/ts/surfaces/checkout/components/Checkbox/Checkbox.d.ts +5 -9
  277. package/build/ts/surfaces/checkout/components/Checkbox/Checkbox.d.ts.map +1 -1
  278. package/build/ts/surfaces/checkout/components/Checkbox/Checkbox.doc.d.ts +4 -0
  279. package/build/ts/surfaces/checkout/components/Checkbox/Checkbox.doc.d.ts.map +1 -0
  280. package/build/ts/surfaces/checkout/components/Choice/Choice.d.ts +2 -4
  281. package/build/ts/surfaces/checkout/components/Choice/Choice.d.ts.map +1 -1
  282. package/build/ts/surfaces/checkout/components/Choice/Choice.doc.d.ts +4 -0
  283. package/build/ts/surfaces/checkout/components/Choice/Choice.doc.d.ts.map +1 -0
  284. package/build/ts/surfaces/checkout/components/ChoiceList/ChoiceList.doc.d.ts +4 -0
  285. package/build/ts/surfaces/checkout/components/ChoiceList/ChoiceList.doc.d.ts.map +1 -0
  286. package/build/ts/surfaces/checkout/components/DateField/DateField.d.ts +32 -0
  287. package/build/ts/surfaces/checkout/components/DateField/DateField.d.ts.map +1 -0
  288. package/build/ts/surfaces/checkout/components/DateField/DateField.doc.d.ts +4 -0
  289. package/build/ts/surfaces/checkout/components/DateField/DateField.doc.d.ts.map +1 -0
  290. package/build/ts/surfaces/checkout/components/DatePicker/DatePicker.d.ts +81 -0
  291. package/build/ts/surfaces/checkout/components/DatePicker/DatePicker.d.ts.map +1 -0
  292. package/build/ts/surfaces/checkout/components/DatePicker/DatePicker.doc.d.ts +4 -0
  293. package/build/ts/surfaces/checkout/components/DatePicker/DatePicker.doc.d.ts.map +1 -0
  294. package/build/ts/surfaces/checkout/components/Disclosure/Disclosure.d.ts +45 -0
  295. package/build/ts/surfaces/checkout/components/Disclosure/Disclosure.d.ts.map +1 -0
  296. package/build/ts/surfaces/checkout/components/Disclosure/Disclosure.doc.d.ts +4 -0
  297. package/build/ts/surfaces/checkout/components/Disclosure/Disclosure.doc.d.ts.map +1 -0
  298. package/build/ts/surfaces/checkout/components/Divider/Divider.d.ts +2 -2
  299. package/build/ts/surfaces/checkout/components/Divider/Divider.d.ts.map +1 -1
  300. package/build/ts/surfaces/checkout/components/Divider/Divider.doc.d.ts +4 -0
  301. package/build/ts/surfaces/checkout/components/Divider/Divider.doc.d.ts.map +1 -0
  302. package/build/ts/surfaces/checkout/components/Form/Form.doc.d.ts +4 -0
  303. package/build/ts/surfaces/checkout/components/Form/Form.doc.d.ts.map +1 -0
  304. package/build/ts/surfaces/checkout/components/Grid/Grid.d.ts +20 -4
  305. package/build/ts/surfaces/checkout/components/Grid/Grid.d.ts.map +1 -1
  306. package/build/ts/surfaces/checkout/components/Grid/Grid.doc.d.ts +4 -0
  307. package/build/ts/surfaces/checkout/components/Grid/Grid.doc.d.ts.map +1 -0
  308. package/build/ts/surfaces/checkout/components/GridItem/GridItem.d.ts +20 -4
  309. package/build/ts/surfaces/checkout/components/GridItem/GridItem.d.ts.map +1 -1
  310. package/build/ts/surfaces/checkout/components/GridItem/GridItem.doc.d.ts +4 -0
  311. package/build/ts/surfaces/checkout/components/GridItem/GridItem.doc.d.ts.map +1 -0
  312. package/build/ts/surfaces/checkout/components/Heading/Heading.doc.d.ts +4 -0
  313. package/build/ts/surfaces/checkout/components/Heading/Heading.doc.d.ts.map +1 -0
  314. package/build/ts/surfaces/checkout/components/HeadingGroup/HeadingGroup.doc.d.ts +4 -0
  315. package/build/ts/surfaces/checkout/components/HeadingGroup/HeadingGroup.doc.d.ts.map +1 -0
  316. package/build/ts/surfaces/checkout/components/Icon/Icon.d.ts +7 -3
  317. package/build/ts/surfaces/checkout/components/Icon/Icon.d.ts.map +1 -1
  318. package/build/ts/surfaces/checkout/components/Icon/Icon.doc.d.ts +4 -0
  319. package/build/ts/surfaces/checkout/components/Icon/Icon.doc.d.ts.map +1 -0
  320. package/build/ts/surfaces/checkout/components/Image/Image.d.ts +2 -3
  321. package/build/ts/surfaces/checkout/components/Image/Image.d.ts.map +1 -1
  322. package/build/ts/surfaces/checkout/components/Image/Image.doc.d.ts +4 -0
  323. package/build/ts/surfaces/checkout/components/Image/Image.doc.d.ts.map +1 -0
  324. package/build/ts/surfaces/checkout/components/InlineLayout/InlineLayout.d.ts +2 -2
  325. package/build/ts/surfaces/checkout/components/InlineLayout/InlineLayout.d.ts.map +1 -1
  326. package/build/ts/surfaces/checkout/components/InlineLayout/InlineLayout.doc.d.ts +4 -0
  327. package/build/ts/surfaces/checkout/components/InlineLayout/InlineLayout.doc.d.ts.map +1 -0
  328. package/build/ts/surfaces/checkout/components/InlineSpacer/InlineSpacer.d.ts +2 -2
  329. package/build/ts/surfaces/checkout/components/InlineSpacer/InlineSpacer.d.ts.map +1 -1
  330. package/build/ts/surfaces/checkout/components/InlineSpacer/InlineSpacer.doc.d.ts +4 -0
  331. package/build/ts/surfaces/checkout/components/InlineSpacer/InlineSpacer.doc.d.ts.map +1 -0
  332. package/build/ts/surfaces/checkout/components/InlineStack/InlineStack.d.ts +23 -3
  333. package/build/ts/surfaces/checkout/components/InlineStack/InlineStack.d.ts.map +1 -1
  334. package/build/ts/surfaces/checkout/components/InlineStack/InlineStack.doc.d.ts +4 -0
  335. package/build/ts/surfaces/checkout/components/InlineStack/InlineStack.doc.d.ts.map +1 -0
  336. package/build/ts/surfaces/checkout/components/Link/Link.d.ts +3 -4
  337. package/build/ts/surfaces/checkout/components/Link/Link.d.ts.map +1 -1
  338. package/build/ts/surfaces/checkout/components/Link/Link.doc.d.ts +4 -0
  339. package/build/ts/surfaces/checkout/components/Link/Link.doc.d.ts.map +1 -0
  340. package/build/ts/surfaces/checkout/components/List/List.d.ts +2 -2
  341. package/build/ts/surfaces/checkout/components/List/List.d.ts.map +1 -1
  342. package/build/ts/surfaces/checkout/components/List/List.doc.d.ts +4 -0
  343. package/build/ts/surfaces/checkout/components/List/List.doc.d.ts.map +1 -0
  344. package/build/ts/surfaces/checkout/components/ListItem/ListItem.d.ts +2 -1
  345. package/build/ts/surfaces/checkout/components/ListItem/ListItem.d.ts.map +1 -1
  346. package/build/ts/surfaces/checkout/components/ListItem/ListItem.doc.d.ts +4 -0
  347. package/build/ts/surfaces/checkout/components/ListItem/ListItem.doc.d.ts.map +1 -0
  348. package/build/ts/surfaces/checkout/components/Modal/Modal.d.ts +44 -0
  349. package/build/ts/surfaces/checkout/components/Modal/Modal.d.ts.map +1 -0
  350. package/build/ts/surfaces/checkout/components/Modal/Modal.doc.d.ts +4 -0
  351. package/build/ts/surfaces/checkout/components/Modal/Modal.doc.d.ts.map +1 -0
  352. package/build/ts/surfaces/checkout/components/PhoneField/PhoneField.d.ts +87 -2
  353. package/build/ts/surfaces/checkout/components/PhoneField/PhoneField.d.ts.map +1 -1
  354. package/build/ts/surfaces/checkout/components/PhoneField/PhoneField.doc.d.ts +4 -0
  355. package/build/ts/surfaces/checkout/components/PhoneField/PhoneField.doc.d.ts.map +1 -0
  356. package/build/ts/surfaces/checkout/components/Popover/Popover.d.ts +36 -0
  357. package/build/ts/surfaces/checkout/components/Popover/Popover.d.ts.map +1 -0
  358. package/build/ts/surfaces/checkout/components/Popover/Popover.doc.d.ts +4 -0
  359. package/build/ts/surfaces/checkout/components/Popover/Popover.doc.d.ts.map +1 -0
  360. package/build/ts/surfaces/checkout/components/Pressable/Pressable.d.ts +20 -3
  361. package/build/ts/surfaces/checkout/components/Pressable/Pressable.d.ts.map +1 -1
  362. package/build/ts/surfaces/checkout/components/Pressable/Pressable.doc.d.ts +4 -0
  363. package/build/ts/surfaces/checkout/components/Pressable/Pressable.doc.d.ts.map +1 -0
  364. package/build/ts/surfaces/checkout/components/ScrollView/ScrollView.d.ts +7 -4
  365. package/build/ts/surfaces/checkout/components/ScrollView/ScrollView.d.ts.map +1 -1
  366. package/build/ts/surfaces/checkout/components/ScrollView/ScrollView.doc.d.ts +4 -0
  367. package/build/ts/surfaces/checkout/components/ScrollView/ScrollView.doc.d.ts.map +1 -0
  368. package/build/ts/surfaces/checkout/components/Select/Select.d.ts +2 -3
  369. package/build/ts/surfaces/checkout/components/Select/Select.d.ts.map +1 -1
  370. package/build/ts/surfaces/checkout/components/Select/Select.doc.d.ts +4 -0
  371. package/build/ts/surfaces/checkout/components/Select/Select.doc.d.ts.map +1 -0
  372. package/build/ts/surfaces/checkout/components/SkeletonImage/SkeletonImage.d.ts +2 -1
  373. package/build/ts/surfaces/checkout/components/SkeletonImage/SkeletonImage.d.ts.map +1 -1
  374. package/build/ts/surfaces/checkout/components/SkeletonImage/SkeletonImage.doc.d.ts +4 -0
  375. package/build/ts/surfaces/checkout/components/SkeletonImage/SkeletonImage.doc.d.ts.map +1 -0
  376. package/build/ts/surfaces/checkout/components/SkeletonText/SkeletonText.d.ts +7 -3
  377. package/build/ts/surfaces/checkout/components/SkeletonText/SkeletonText.d.ts.map +1 -1
  378. package/build/ts/surfaces/checkout/components/SkeletonText/SkeletonText.doc.d.ts +4 -0
  379. package/build/ts/surfaces/checkout/components/SkeletonText/SkeletonText.doc.d.ts.map +1 -0
  380. package/build/ts/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.d.ts +7 -2
  381. package/build/ts/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.d.ts.map +1 -1
  382. package/build/ts/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.doc.d.ts +4 -0
  383. package/build/ts/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.doc.d.ts.map +1 -0
  384. package/build/ts/surfaces/checkout/components/Spinner/Spinner.d.ts +2 -2
  385. package/build/ts/surfaces/checkout/components/Spinner/Spinner.d.ts.map +1 -1
  386. package/build/ts/surfaces/checkout/components/Spinner/Spinner.doc.d.ts +4 -0
  387. package/build/ts/surfaces/checkout/components/Spinner/Spinner.doc.d.ts.map +1 -0
  388. package/build/ts/surfaces/checkout/components/Stepper/Stepper.d.ts +98 -3
  389. package/build/ts/surfaces/checkout/components/Stepper/Stepper.d.ts.map +1 -1
  390. package/build/ts/surfaces/checkout/components/Stepper/Stepper.doc.d.ts +4 -0
  391. package/build/ts/surfaces/checkout/components/Stepper/Stepper.doc.d.ts.map +1 -0
  392. package/build/ts/surfaces/checkout/components/Tag/Tag.d.ts +5 -7
  393. package/build/ts/surfaces/checkout/components/Tag/Tag.d.ts.map +1 -1
  394. package/build/ts/surfaces/checkout/components/Tag/Tag.doc.d.ts +4 -0
  395. package/build/ts/surfaces/checkout/components/Tag/Tag.doc.d.ts.map +1 -0
  396. package/build/ts/surfaces/checkout/components/Text/Text.d.ts +2 -2
  397. package/build/ts/surfaces/checkout/components/Text/Text.d.ts.map +1 -1
  398. package/build/ts/surfaces/checkout/components/Text/Text.doc.d.ts +4 -0
  399. package/build/ts/surfaces/checkout/components/Text/Text.doc.d.ts.map +1 -0
  400. package/build/ts/surfaces/checkout/components/TextBlock/TextBlock.d.ts +3 -7
  401. package/build/ts/surfaces/checkout/components/TextBlock/TextBlock.d.ts.map +1 -1
  402. package/build/ts/surfaces/checkout/components/TextBlock/TextBlock.doc.d.ts +4 -0
  403. package/build/ts/surfaces/checkout/components/TextBlock/TextBlock.doc.d.ts.map +1 -0
  404. package/build/ts/surfaces/checkout/components/TextField/TextField.d.ts +2 -2
  405. package/build/ts/surfaces/checkout/components/TextField/TextField.d.ts.map +1 -1
  406. package/build/ts/surfaces/checkout/components/TextField/TextField.doc.d.ts +4 -0
  407. package/build/ts/surfaces/checkout/components/TextField/TextField.doc.d.ts.map +1 -0
  408. package/build/ts/surfaces/checkout/components/Tooltip/Tooltip.d.ts +2 -1
  409. package/build/ts/surfaces/checkout/components/Tooltip/Tooltip.d.ts.map +1 -1
  410. package/build/ts/surfaces/checkout/components/Tooltip/Tooltip.doc.d.ts +4 -0
  411. package/build/ts/surfaces/checkout/components/Tooltip/Tooltip.doc.d.ts.map +1 -0
  412. package/build/ts/surfaces/checkout/components/View/View.d.ts +16 -16
  413. package/build/ts/surfaces/checkout/components/View/View.d.ts.map +1 -1
  414. package/build/ts/surfaces/checkout/components/View/View.doc.d.ts +4 -0
  415. package/build/ts/surfaces/checkout/components/View/View.doc.d.ts.map +1 -0
  416. package/build/ts/surfaces/checkout/components/shared.d.ts +57 -18
  417. package/build/ts/surfaces/checkout/components/shared.d.ts.map +1 -1
  418. package/build/ts/surfaces/checkout/components.d.ts +13 -3
  419. package/build/ts/surfaces/checkout/components.d.ts.map +1 -1
  420. package/build/ts/surfaces/checkout/extension-points.d.ts +136 -26
  421. package/build/ts/surfaces/checkout/extension-points.d.ts.map +1 -1
  422. package/build/ts/surfaces/checkout/extension.d.ts +35 -3
  423. package/build/ts/surfaces/checkout/extension.d.ts.map +1 -1
  424. package/build/ts/surfaces/checkout/globals.d.ts +1 -1
  425. package/build/ts/surfaces/checkout/globals.d.ts.map +1 -1
  426. package/build/ts/surfaces/checkout/helper.docs.d.ts +16 -0
  427. package/build/ts/surfaces/checkout/helper.docs.d.ts.map +1 -0
  428. package/build/ts/surfaces/checkout/shared.d.ts +3 -5
  429. package/build/ts/surfaces/checkout/shared.d.ts.map +1 -1
  430. package/build/ts/surfaces/checkout/style/index.d.ts +3 -0
  431. package/build/ts/surfaces/checkout/style/index.d.ts.map +1 -0
  432. package/build/ts/surfaces/checkout/style/memoize.d.ts.map +1 -1
  433. package/build/ts/surfaces/checkout/style/style.d.ts +4 -0
  434. package/build/ts/surfaces/checkout/style/style.d.ts.map +1 -1
  435. package/build/ts/surfaces/checkout/style/style.doc.d.ts +4 -0
  436. package/build/ts/surfaces/checkout/style/style.doc.d.ts.map +1 -0
  437. package/build/ts/surfaces/checkout/style/types.d.ts +5 -0
  438. package/build/ts/surfaces/checkout/style/types.d.ts.map +1 -1
  439. package/build/ts/utilities/registration.d.ts +5 -1
  440. package/build/ts/utilities/registration.d.ts.map +1 -1
  441. package/build/tsconfig.tsbuildinfo +1 -1
  442. package/package.json +21 -4
  443. package/src/api.ts +73 -0
  444. package/src/extension.ts +30 -1
  445. package/src/index.ts +0 -1
  446. package/src/shared.ts +13 -0
  447. package/src/surfaces/admin/api/action/action.doc.ts +19 -0
  448. package/src/surfaces/admin/api/action/action.ts +14 -0
  449. package/src/surfaces/admin/api/customer-segmentation-template/customer-segmentation-template.ts +19 -0
  450. package/src/surfaces/admin/api/extension-targets/extension-targets.doc.ts +20 -0
  451. package/src/surfaces/admin/api/standard/README.md +1 -0
  452. package/src/surfaces/admin/api/standard/standard.doc.ts +20 -0
  453. package/src/surfaces/admin/api/standard/standard.ts +14 -0
  454. package/src/surfaces/admin/api.ts +4 -0
  455. package/src/surfaces/admin/components/AdminAction/AdminAction.doc.ts +41 -0
  456. package/src/surfaces/admin/components/AdminAction/AdminAction.ts +28 -0
  457. package/src/surfaces/admin/components/AdminAction/examples/basic-adminaction.example.ts +16 -0
  458. package/src/surfaces/admin/components/AdminBlock/AdminBlock.doc.ts +41 -0
  459. package/src/surfaces/admin/components/AdminBlock/AdminBlock.ts +19 -0
  460. package/src/surfaces/admin/components/AdminBlock/examples/basic-adminblock.example.ts +11 -0
  461. package/src/surfaces/admin/components/BlockStack/BlockStack.doc.ts +42 -0
  462. package/src/surfaces/admin/components/BlockStack/BlockStack.ts +27 -0
  463. package/src/surfaces/admin/components/BlockStack/examples/basic-blockstack.example.ts +24 -0
  464. package/src/surfaces/admin/components/Box/Box.doc.ts +42 -0
  465. package/src/surfaces/admin/components/Box/Box.ts +13 -0
  466. package/src/surfaces/admin/components/Box/examples/basic-box.example.ts +11 -0
  467. package/src/surfaces/admin/components/Button/Button.doc.ts +41 -0
  468. package/src/surfaces/admin/components/Button/Button.ts +99 -0
  469. package/src/surfaces/admin/components/Button/README.md +3 -0
  470. package/src/surfaces/admin/components/Button/examples/basic-button.example.ts +11 -0
  471. package/src/surfaces/admin/components/Checkbox/Checkbox.doc.ts +42 -0
  472. package/src/surfaces/admin/components/Checkbox/Checkbox.ts +63 -0
  473. package/src/surfaces/admin/components/Checkbox/examples/basic-checkbox.example.ts +11 -0
  474. package/src/surfaces/admin/components/CustomerSegmentationTemplate/CustomerSegmentationTemplate.ts +68 -0
  475. package/src/surfaces/admin/components/CustomerSegmentationTemplate/examples/CustomerSegmentationTemplate.example.ts +37 -0
  476. package/src/surfaces/admin/components/Divider/Divider.doc.ts +42 -0
  477. package/src/surfaces/admin/components/Divider/Divider.ts +14 -0
  478. package/src/surfaces/admin/components/Divider/README.md +7 -0
  479. package/src/surfaces/admin/components/Divider/examples/basic-divider.example.ts +17 -0
  480. package/src/surfaces/admin/components/EmailField/EmailField.doc.ts +41 -0
  481. package/src/surfaces/admin/components/EmailField/EmailField.ts +22 -0
  482. package/src/surfaces/admin/components/EmailField/README.md +7 -0
  483. package/src/surfaces/admin/components/EmailField/examples/basic-emailfield.example.ts +9 -0
  484. package/src/surfaces/admin/components/Form/Form.doc.ts +41 -0
  485. package/src/surfaces/admin/components/Form/Form.ts +32 -0
  486. package/src/surfaces/admin/components/Form/examples/basic-form.example.ts +41 -0
  487. package/src/surfaces/admin/components/Heading/Heading.doc.ts +42 -0
  488. package/src/surfaces/admin/components/Heading/Heading.ts +15 -0
  489. package/src/surfaces/admin/components/Heading/README.md +9 -0
  490. package/src/surfaces/admin/components/Heading/examples/basic-heading.example.ts +7 -0
  491. package/src/surfaces/admin/components/HeadingGroup/HeadingGroup.doc.ts +42 -0
  492. package/src/surfaces/admin/components/HeadingGroup/HeadingGroup.ts +8 -0
  493. package/src/surfaces/admin/components/HeadingGroup/README.md +5 -0
  494. package/src/surfaces/admin/components/HeadingGroup/examples/basic-headinggroup.example.ts +20 -0
  495. package/src/surfaces/admin/components/Icon/Icon.doc.ts +42 -0
  496. package/src/surfaces/admin/components/Icon/Icon.ts +42 -0
  497. package/src/surfaces/admin/components/Icon/README.md +3 -0
  498. package/src/surfaces/admin/components/Icon/examples/basic-icon.example.ts +7 -0
  499. package/src/surfaces/admin/components/Image/Image.doc.ts +41 -0
  500. package/src/surfaces/admin/components/Image/Image.ts +120 -0
  501. package/src/surfaces/admin/components/Image/README.md +20 -0
  502. package/src/surfaces/admin/components/Image/examples/basic-image.example.ts +10 -0
  503. package/src/surfaces/admin/components/InlineStack/InlineStack.doc.ts +41 -0
  504. package/src/surfaces/admin/components/InlineStack/InlineStack.ts +28 -0
  505. package/src/surfaces/admin/components/InlineStack/examples/basic-inlinestack.example.ts +18 -0
  506. package/src/surfaces/admin/components/Link/Link.doc.ts +103 -0
  507. package/src/surfaces/admin/components/Link/Link.ts +63 -0
  508. package/src/surfaces/admin/components/Link/README.md +11 -0
  509. package/src/surfaces/admin/components/Link/examples/app-link.example.ts +17 -0
  510. package/src/surfaces/admin/components/Link/examples/external-link.example.ts +17 -0
  511. package/src/surfaces/admin/components/Link/examples/relative-link.example.ts +17 -0
  512. package/src/surfaces/admin/components/Link/examples/shopify-section-link.example.ts +17 -0
  513. package/src/surfaces/admin/components/NumberField/NumberField.doc.ts +42 -0
  514. package/src/surfaces/admin/components/NumberField/NumberField.ts +59 -0
  515. package/src/surfaces/admin/components/NumberField/README.md +7 -0
  516. package/src/surfaces/admin/components/NumberField/examples/basic-numberfield.example.ts +9 -0
  517. package/src/surfaces/admin/components/PasswordField/PasswordField.doc.ts +42 -0
  518. package/src/surfaces/admin/components/PasswordField/PasswordField.ts +22 -0
  519. package/src/surfaces/admin/components/PasswordField/README.md +7 -0
  520. package/src/surfaces/admin/components/PasswordField/examples/basic-passwordfield.example.ts +13 -0
  521. package/src/surfaces/admin/components/Select/README.md +99 -0
  522. package/src/surfaces/admin/components/Select/Select.doc.ts +42 -0
  523. package/src/surfaces/admin/components/Select/Select.ts +147 -0
  524. package/src/surfaces/admin/components/Select/examples/basic-select.example.ts +47 -0
  525. package/src/surfaces/admin/components/Text/README.md +7 -0
  526. package/src/surfaces/admin/components/Text/Text.doc.ts +42 -0
  527. package/src/surfaces/admin/components/Text/Text.ts +124 -0
  528. package/src/surfaces/admin/components/Text/examples/basic-text.example.ts +14 -0
  529. package/src/surfaces/admin/components/TextArea/TextArea.doc.ts +42 -0
  530. package/src/surfaces/admin/components/TextArea/TextArea.ts +24 -0
  531. package/src/surfaces/admin/components/TextArea/examples/basic-textarea.example.ts +10 -0
  532. package/src/surfaces/admin/components/TextField/README.md +7 -0
  533. package/src/surfaces/admin/components/TextField/TextField.doc.ts +42 -0
  534. package/src/surfaces/admin/components/TextField/TextField.ts +16 -0
  535. package/src/surfaces/admin/components/TextField/examples/basic-textfield.example.ts +9 -0
  536. package/src/surfaces/admin/components/URLField/README.md +7 -0
  537. package/src/surfaces/admin/components/URLField/URLField.doc.ts +41 -0
  538. package/src/surfaces/admin/components/URLField/URLField.ts +26 -0
  539. package/src/surfaces/admin/components/URLField/examples/basic-urlfield.example.ts +9 -0
  540. package/src/surfaces/admin/components/shared/index.ts +664 -0
  541. package/src/surfaces/admin/components.ts +52 -0
  542. package/src/surfaces/admin/extension-points.ts +143 -0
  543. package/src/surfaces/admin/extension.ts +8 -0
  544. package/src/surfaces/admin/globals.ts +8 -0
  545. package/src/surfaces/admin/shared.ts +6 -0
  546. package/src/surfaces/admin.ts +6 -0
  547. package/src/surfaces/checkout/api/{cart-line-details/render-after.ts → cart-line/cart-line-details.ts} +2 -3
  548. package/src/surfaces/checkout/api/checkout/checkout.ts +454 -0
  549. package/src/surfaces/checkout/api/order-status/order-status.ts +28 -0
  550. package/src/surfaces/checkout/api/payment-method/render.ts +55 -0
  551. package/src/surfaces/checkout/api/pickup/pickup-locations.ts +8 -0
  552. package/src/surfaces/checkout/api/pickup/pickup-points.ts +8 -0
  553. package/src/surfaces/checkout/api/redeemable/render.ts +55 -0
  554. package/src/surfaces/checkout/api/shared.ts +57 -0
  555. package/src/surfaces/checkout/api/shipping/shipping-method-details.ts +15 -0
  556. package/src/surfaces/checkout/api/standard/README.md +100 -1
  557. package/src/surfaces/checkout/api/standard/standard.ts +644 -483
  558. package/src/surfaces/checkout/api.ts +93 -35
  559. package/src/surfaces/checkout/components/Banner/Banner.doc.ts +57 -0
  560. package/src/surfaces/checkout/components/Banner/Banner.ts +2 -2
  561. package/src/surfaces/checkout/components/Banner/examples/basic-banner.example.ts +2 -2
  562. package/src/surfaces/checkout/components/BlockLayout/BlockLayout.doc.ts +50 -0
  563. package/src/surfaces/checkout/components/BlockLayout/examples/basic-blockLayout.example.ts +2 -2
  564. package/src/surfaces/checkout/components/BlockLayout/examples/basic-blocklayout.example.ts +16 -0
  565. package/src/surfaces/checkout/components/BlockSpacer/BlockSpacer.doc.ts +47 -0
  566. package/src/surfaces/checkout/components/BlockSpacer/BlockSpacer.ts +2 -2
  567. package/src/surfaces/checkout/components/BlockSpacer/examples/basic-blockspacer.example.ts +2 -2
  568. package/src/surfaces/checkout/components/BlockStack/BlockStack.doc.ts +60 -0
  569. package/src/surfaces/checkout/components/BlockStack/BlockStack.ts +20 -2
  570. package/src/surfaces/checkout/components/BlockStack/examples/basic-blockstack.example.ts +2 -2
  571. package/src/surfaces/checkout/components/Button/Button.doc.ts +64 -0
  572. package/src/surfaces/checkout/components/Button/Button.ts +8 -4
  573. package/src/surfaces/checkout/components/Button/examples/basic-button.example.ts +2 -2
  574. package/src/surfaces/checkout/components/Checkbox/Checkbox.doc.ts +49 -0
  575. package/src/surfaces/checkout/components/Checkbox/Checkbox.ts +5 -5
  576. package/src/surfaces/checkout/components/Checkbox/content/guidelines.md +1 -1
  577. package/src/surfaces/checkout/components/Checkbox/examples/basic-checkbox.example.ts +2 -2
  578. package/src/surfaces/checkout/components/Choice/Choice.doc.ts +57 -0
  579. package/src/surfaces/checkout/components/Choice/Choice.ts +2 -4
  580. package/src/surfaces/checkout/components/Choice/examples/basic-choice.example.ts +2 -2
  581. package/src/surfaces/checkout/components/ChoiceList/ChoiceList.doc.ts +63 -0
  582. package/src/surfaces/checkout/components/ChoiceList/content/guidelines.md +2 -2
  583. package/src/surfaces/checkout/components/ChoiceList/examples/basic-choicelist.example.ts +2 -2
  584. package/src/surfaces/checkout/components/DateField/DateField.doc.ts +49 -0
  585. package/src/surfaces/checkout/components/DateField/DateField.ts +50 -0
  586. package/src/surfaces/checkout/components/DateField/examples/basic-datefield.example.ts +9 -0
  587. package/src/surfaces/checkout/components/DatePicker/DatePicker.doc.ts +50 -0
  588. package/src/surfaces/checkout/components/DatePicker/DatePicker.ts +81 -0
  589. package/src/surfaces/checkout/components/DatePicker/examples/basic-datepicker.example.ts +9 -0
  590. package/src/surfaces/checkout/components/Disclosure/Disclosure.doc.ts +61 -0
  591. package/src/surfaces/checkout/components/Disclosure/Disclosure.ts +46 -0
  592. package/src/surfaces/checkout/components/Disclosure/examples/basic-disclosure.example.ts +19 -0
  593. package/src/surfaces/checkout/components/Divider/Divider.doc.ts +41 -0
  594. package/src/surfaces/checkout/components/Divider/Divider.ts +2 -2
  595. package/src/surfaces/checkout/components/Divider/examples/basic-divider.example.ts +2 -2
  596. package/src/surfaces/checkout/components/Form/Form.doc.ts +50 -0
  597. package/src/surfaces/checkout/components/Form/examples/basic-form.example.ts +2 -2
  598. package/src/surfaces/checkout/components/Grid/Grid.doc.ts +57 -0
  599. package/src/surfaces/checkout/components/Grid/Grid.ts +24 -3
  600. package/src/surfaces/checkout/components/Grid/examples/basic-grid.example.ts +2 -2
  601. package/src/surfaces/checkout/components/GridItem/GridItem.doc.ts +57 -0
  602. package/src/surfaces/checkout/components/GridItem/GridItem.ts +24 -3
  603. package/src/surfaces/checkout/components/GridItem/examples/basic-griditem.example.ts +2 -2
  604. package/src/surfaces/checkout/components/Heading/Heading.doc.ts +69 -0
  605. package/src/surfaces/checkout/components/Heading/examples/basic-heading.example.ts +2 -2
  606. package/src/surfaces/checkout/components/HeadingGroup/HeadingGroup.doc.ts +63 -0
  607. package/src/surfaces/checkout/components/HeadingGroup/examples/basic-headinggroup.example.ts +2 -2
  608. package/src/surfaces/checkout/components/Icon/Icon.doc.ts +57 -0
  609. package/src/surfaces/checkout/components/Icon/Icon.ts +23 -11
  610. package/src/surfaces/checkout/components/Icon/examples/basic-icon.example.ts +2 -2
  611. package/src/surfaces/checkout/components/Image/Image.doc.ts +49 -0
  612. package/src/surfaces/checkout/components/Image/Image.ts +8 -3
  613. package/src/surfaces/checkout/components/Image/examples/basic-image.example.ts +2 -2
  614. package/src/surfaces/checkout/components/InlineLayout/InlineLayout.doc.ts +61 -0
  615. package/src/surfaces/checkout/components/InlineLayout/InlineLayout.ts +8 -1
  616. package/src/surfaces/checkout/components/InlineLayout/examples/basic-inlineLayout.example.ts +2 -2
  617. package/src/surfaces/checkout/components/InlineLayout/examples/basic-inlinelayout.example.ts +16 -0
  618. package/src/surfaces/checkout/components/InlineSpacer/InlineSpacer.doc.ts +41 -0
  619. package/src/surfaces/checkout/components/InlineSpacer/InlineSpacer.ts +2 -2
  620. package/src/surfaces/checkout/components/InlineSpacer/examples/basic-inlinespacer.example.ts +2 -2
  621. package/src/surfaces/checkout/components/InlineStack/InlineStack.doc.ts +50 -0
  622. package/src/surfaces/checkout/components/InlineStack/InlineStack.ts +23 -1
  623. package/src/surfaces/checkout/components/InlineStack/examples/basic-inlinestack.example.ts +2 -2
  624. package/src/surfaces/checkout/components/Link/Link.doc.ts +64 -0
  625. package/src/surfaces/checkout/components/Link/Link.ts +9 -4
  626. package/src/surfaces/checkout/components/Link/examples/basic-link.example.ts +2 -2
  627. package/src/surfaces/checkout/components/List/List.doc.ts +58 -0
  628. package/src/surfaces/checkout/components/List/List.ts +2 -2
  629. package/src/surfaces/checkout/components/List/examples/basic-list.example.ts +2 -2
  630. package/src/surfaces/checkout/components/ListItem/ListItem.doc.ts +42 -0
  631. package/src/surfaces/checkout/components/ListItem/ListItem.ts +3 -1
  632. package/src/surfaces/checkout/components/ListItem/examples/basic-listitem.example.ts +2 -2
  633. package/src/surfaces/checkout/components/Modal/Modal.doc.ts +50 -0
  634. package/src/surfaces/checkout/components/Modal/Modal.ts +42 -0
  635. package/src/surfaces/checkout/components/Modal/examples/basic-modal.example.ts +44 -0
  636. package/src/surfaces/checkout/components/PhoneField/PhoneField.doc.ts +41 -0
  637. package/src/surfaces/checkout/components/PhoneField/PhoneField.ts +99 -23
  638. package/src/surfaces/checkout/components/PhoneField/examples/basic-phonefield.example.ts +2 -2
  639. package/src/surfaces/checkout/components/Popover/Popover.doc.ts +50 -0
  640. package/src/surfaces/checkout/components/Popover/Popover.ts +45 -0
  641. package/src/surfaces/checkout/components/Popover/examples/basic-popover.example.ts +30 -0
  642. package/src/surfaces/checkout/components/Pressable/Pressable.doc.ts +41 -0
  643. package/src/surfaces/checkout/components/Pressable/Pressable.ts +25 -2
  644. package/src/surfaces/checkout/components/Pressable/examples/basic-pressable.example.ts +4 -4
  645. package/src/surfaces/checkout/components/ScrollView/ScrollView.doc.ts +41 -0
  646. package/src/surfaces/checkout/components/ScrollView/ScrollView.ts +6 -1
  647. package/src/surfaces/checkout/components/ScrollView/examples/basic-scrollview.example.ts +2 -2
  648. package/src/surfaces/checkout/components/Select/Select.doc.ts +50 -0
  649. package/src/surfaces/checkout/components/Select/Select.ts +2 -2
  650. package/src/surfaces/checkout/components/Select/examples/basic-select.example.ts +2 -2
  651. package/src/surfaces/checkout/components/SkeletonImage/SkeletonImage.doc.ts +52 -0
  652. package/src/surfaces/checkout/components/SkeletonImage/SkeletonImage.ts +2 -3
  653. package/src/surfaces/checkout/components/SkeletonImage/examples/basic-skeletonimage.example.ts +2 -2
  654. package/src/surfaces/checkout/components/SkeletonText/SkeletonText.doc.ts +52 -0
  655. package/src/surfaces/checkout/components/SkeletonText/SkeletonText.ts +7 -3
  656. package/src/surfaces/checkout/components/SkeletonText/examples/basic-skeletontext.example.ts +2 -2
  657. package/src/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.doc.ts +41 -0
  658. package/src/surfaces/checkout/components/SkeletonTextBlock/SkeletonTextBlock.ts +7 -2
  659. package/src/surfaces/checkout/components/SkeletonTextBlock/examples/basic-skeletontextblock.example.ts +2 -2
  660. package/src/surfaces/checkout/components/Spinner/Spinner.doc.ts +50 -0
  661. package/src/surfaces/checkout/components/Spinner/Spinner.ts +2 -2
  662. package/src/surfaces/checkout/components/Spinner/examples/basic-spinner.example.ts +2 -2
  663. package/src/surfaces/checkout/components/Stepper/Stepper.doc.ts +50 -0
  664. package/src/surfaces/checkout/components/Stepper/Stepper.ts +113 -21
  665. package/src/surfaces/checkout/components/Stepper/examples/basic-stepper.example.ts +2 -2
  666. package/src/surfaces/checkout/components/Tag/Tag.doc.ts +41 -0
  667. package/src/surfaces/checkout/components/Tag/Tag.ts +4 -4
  668. package/src/surfaces/checkout/components/Tag/examples/basic-tag.example.ts +2 -2
  669. package/src/surfaces/checkout/components/Text/Text.doc.ts +76 -0
  670. package/src/surfaces/checkout/components/Text/Text.ts +2 -4
  671. package/src/surfaces/checkout/components/Text/content/guidelines.md +1 -1
  672. package/src/surfaces/checkout/components/Text/examples/basic-text.example.ts +2 -2
  673. package/src/surfaces/checkout/components/TextBlock/TextBlock.doc.ts +76 -0
  674. package/src/surfaces/checkout/components/TextBlock/TextBlock.ts +9 -9
  675. package/src/surfaces/checkout/components/TextBlock/content/guidelines.md +1 -1
  676. package/src/surfaces/checkout/components/TextBlock/examples/basic-textblock.example.ts +6 -2
  677. package/src/surfaces/checkout/components/TextField/TextField.doc.ts +49 -0
  678. package/src/surfaces/checkout/components/TextField/TextField.ts +2 -2
  679. package/src/surfaces/checkout/components/TextField/examples/basic-textfield.example.ts +2 -2
  680. package/src/surfaces/checkout/components/Tooltip/Tooltip.doc.ts +50 -0
  681. package/src/surfaces/checkout/components/Tooltip/Tooltip.ts +3 -1
  682. package/src/surfaces/checkout/components/Tooltip/examples/basic-tooltip.example.ts +2 -2
  683. package/src/surfaces/checkout/components/View/View.doc.ts +50 -0
  684. package/src/surfaces/checkout/components/View/View.ts +17 -18
  685. package/src/surfaces/checkout/components/View/examples/basic-view.example.ts +2 -2
  686. package/src/surfaces/checkout/components/shared.ts +73 -18
  687. package/src/surfaces/checkout/components.ts +41 -16
  688. package/src/surfaces/checkout/extension-points.ts +245 -52
  689. package/src/surfaces/checkout/extension.ts +62 -3
  690. package/src/surfaces/checkout/globals.ts +1 -1
  691. package/src/surfaces/checkout/helper.docs.ts +103 -0
  692. package/src/surfaces/checkout/shared.ts +3 -11
  693. package/src/surfaces/checkout/style/examples/.eslintrc.js +8 -0
  694. package/src/surfaces/checkout/style/examples/defaultstyle.example.tsx +9 -0
  695. package/src/surfaces/checkout/style/examples/simplecondition.example.tsx +9 -0
  696. package/src/surfaces/checkout/style/examples/style.example.ts +18 -0
  697. package/src/surfaces/checkout/style/examples/style.example.tsx +16 -0
  698. package/src/surfaces/checkout/style/index.ts +16 -0
  699. package/src/surfaces/checkout/style/memoize.ts +2 -0
  700. package/src/surfaces/checkout/style/style.doc.ts +166 -0
  701. package/src/surfaces/checkout/style/style.ts +5 -0
  702. package/src/surfaces/checkout/style/types.ts +5 -0
  703. package/src/utilities/registration.ts +59 -7
  704. package/build/ts/surfaces/checkout/api/cart-line-details/render-after.d.ts +0 -9
  705. package/build/ts/surfaces/checkout/api/cart-line-details/render-after.d.ts.map +0 -1
  706. package/src/surfaces/checkout/api/cart-line-details/README.md +0 -1
@@ -1,7 +1,5 @@
1
1
  import type { StatefulRemoteSubscribable } from '@remote-ui/async-subscription';
2
- import type { StandardApi as BaseStandardApi } from '../../../../api';
3
- import type { ExtensionPoint as AnyExtensionPoint } from '../../extension-points';
4
- import type { CurrencyCode, CountryCode, Timezone } from '../shared';
2
+ import type { CurrencyCode, CountryCode, Timezone, GraphQLError, StorefrontApiVersion, ValidationError, SellingPlan, Attribute } from '../shared';
5
3
  /**
6
4
  * A key-value storage object for extension points.
7
5
  *
@@ -34,27 +32,33 @@ export interface Storage {
34
32
  delete(key: string): Promise<void>;
35
33
  }
36
34
  /**
37
- * The high-level capabilities an extension is allowed to have access to.
35
+ * The capabilities an extension has access to.
38
36
  *
39
- * * `network_access` allows an extension to make network calls via fetch() and
40
- * is requested by a partner
37
+ * * [`api_access`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#api-access): the extension can access the Storefront API.
41
38
  *
42
- * * `block_progress` allows an extension to block a buyer's progress through
43
- * checkout and may be granted by a merchant in differing checkout contexts
39
+ * * [`network_access`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#network-access): the extension can make external network calls.
40
+ *
41
+ * * [`block_progress`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#block-progress): the extension can block a buyer's progress and the merchant has allowed this blocking behavior.
44
42
  */
45
- export type Capability = 'network_access' | 'block_progress';
43
+ export type Capability = 'api_access' | 'network_access' | 'block_progress';
46
44
  /**
47
45
  * Meta information about an extension point.
48
46
  */
49
- export interface ExtensionInstance {
47
+ export interface Extension {
50
48
  /**
51
49
  * The published version of the running extension point.
52
50
  *
53
- * For unpublished extensions, the value is `null`.
51
+ * For unpublished extensions, the value is `undefined`.
54
52
  *
55
53
  * @example 3.0.10
56
54
  */
57
55
  version?: string;
56
+ /**
57
+ * The API version that was set in the extension config file.
58
+ *
59
+ * @example '2023-01', '2022-10'
60
+ */
61
+ apiVersion: ApiVersion;
58
62
  /**
59
63
  * The URL to the script that started the extension point.
60
64
  */
@@ -73,14 +77,13 @@ export interface ExtensionInstance {
73
77
  rendered: StatefulRemoteSubscribable<boolean>;
74
78
  /**
75
79
  * The allowed capabilities of the extension, defined
76
- * in your `shopify.ui.extension.toml` file .
80
+ * in your [shopify.ui.extension.toml](https://shopify.dev/docs/api/checkout-ui-extensions/configuration) file.
77
81
  *
78
- * `network_access`:
79
- * You must [request access](https://shopify.dev/api/checkout-extensions/checkout/configuration#complete-a-request-for-network-access)
80
- * to make network calls.
82
+ * * [`api_access`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#api-access): the extension can access the Storefront API.
81
83
  *
82
- * `block_progress`:
83
- * Merchants control whether your extension [can block checkout progress](https://shopify.dev/api/checkout-extensions/checkout/configuration#block-progress)
84
+ * * [`network_access`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#network-access): the extension can make external network calls.
85
+ *
86
+ * * [`block_progress`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#block-progress): the extension can block a buyer's progress and the merchant has allowed this blocking behavior.
84
87
  */
85
88
  capabilities: StatefulRemoteSubscribable<Capability[]>;
86
89
  /**
@@ -96,94 +99,6 @@ export interface Editor {
96
99
  */
97
100
  type: 'checkout';
98
101
  }
99
- /**
100
- * Removes a note
101
- */
102
- export interface NoteRemoveChange {
103
- /**
104
- * The type of the `NoteRemoveChange` API.
105
- */
106
- type: 'removeNote';
107
- }
108
- /**
109
- * An Update to a note on the order.
110
- * for example, the buyer could request detailed packaging instructions in an order note
111
- */
112
- export interface NoteUpdateChange {
113
- /**
114
- * The type of the `NoteUpdateChange` API.
115
- */
116
- type: 'updateNote';
117
- /**
118
- * The new value of the note.
119
- */
120
- note: string;
121
- }
122
- export type NoteChange = NoteRemoveChange | NoteUpdateChange;
123
- export interface NoteChangeResultSuccess {
124
- /**
125
- * The type of the `NoteChangeResultSuccess` API.
126
- */
127
- type: 'success';
128
- }
129
- export interface NoteChangeResultError {
130
- /**
131
- * The type of the `NoteChangeResultError` API.
132
- */
133
- type: 'error';
134
- /**
135
- * A message that explains the error. This message is useful for debugging.
136
- * It is **not** localized, and therefore should not be presented directly
137
- * to the buyer.
138
- */
139
- message: string;
140
- }
141
- export type NoteChangeResult = NoteChangeResultSuccess | NoteChangeResultError;
142
- /**
143
- * Updates an attribute on the order. If an attribute with the
144
- * provided key does not already exist, it gets created.
145
- */
146
- export interface AttributeUpdateChange {
147
- /**
148
- * The type of the `AttributeUpdateChange` API.
149
- */
150
- type: 'updateAttribute';
151
- /**
152
- * Key of the attribute to add or update
153
- */
154
- key: string;
155
- /**
156
- * Value for the attribute to add or update
157
- */
158
- value: string;
159
- }
160
- export type AttributeChange = AttributeUpdateChange;
161
- /**
162
- * The returned result of a successful update to an attribute.
163
- */
164
- export interface AttributeChangeResultSuccess {
165
- /**
166
- * The type of the `AttributeChangeResultSuccess` API.
167
- */
168
- type: 'success';
169
- }
170
- /**
171
- * The returned result of an unsuccessful update to an attribute
172
- * with a message detailing the type of error that occurred.
173
- */
174
- export interface AttributeChangeResultError {
175
- /**
176
- * The type of the `AttributeChangeResultError` API.
177
- */
178
- type: 'error';
179
- /**
180
- * A message that explains the error. This message is useful for debugging.
181
- * It is **not** localized, and therefore should not be presented directly
182
- * to the buyer.
183
- */
184
- message: string;
185
- }
186
- export type AttributeChangeResult = AttributeChangeResultSuccess | AttributeChangeResultError;
187
102
  /**
188
103
  * Metadata associated with the checkout.
189
104
  */
@@ -206,61 +121,6 @@ export interface Metafield {
206
121
  /** The metafield’s information type. */
207
122
  valueType: 'integer' | 'string' | 'json_string';
208
123
  }
209
- /** Removes a metafield. */
210
- export interface MetafieldRemoveChange {
211
- /**
212
- * The type of the `MetafieldRemoveChange` API.
213
- */
214
- type: 'removeMetafield';
215
- /**
216
- * The name of the metafield to remove.
217
- */
218
- key: string;
219
- /**
220
- * The namespace of the metafield to remove.
221
- */
222
- namespace: string;
223
- }
224
- /**
225
- * Updates a metafield. If a metafield with the
226
- * provided key and namespace does not already exist, it gets created.
227
- */
228
- export interface MetafieldUpdateChange {
229
- /**
230
- * The type of the `MetafieldUpdateChange` API.
231
- */
232
- type: 'updateMetafield';
233
- /** The name of the metafield to update. */
234
- key: string;
235
- /** The namespace of the metafield to add. */
236
- namespace: string;
237
- /** The new information to store in the metafield. */
238
- value: string | number;
239
- /**
240
- * The metafield’s information type.
241
- */
242
- valueType: 'integer' | 'string' | 'json_string';
243
- }
244
- export type MetafieldChange = MetafieldRemoveChange | MetafieldUpdateChange;
245
- export interface MetafieldChangeResultSuccess {
246
- /**
247
- * The type of the `MetafieldChangeResultSuccess` API.
248
- */
249
- type: 'success';
250
- }
251
- export interface MetafieldChangeResultError {
252
- /**
253
- * The type of the `MetafieldChangeResultError` API.
254
- */
255
- type: 'error';
256
- /**
257
- * A message that explains the error. This message is useful for debugging.
258
- * It is **not** localized, and therefore should not be presented directly
259
- * to the buyer.
260
- */
261
- message: string;
262
- }
263
- export type MetafieldChangeResult = MetafieldChangeResultSuccess | MetafieldChangeResultError;
264
124
  /**
265
125
  * Represents a custom metadata attached to a resource.
266
126
  */
@@ -278,7 +138,11 @@ export interface AppMetafield {
278
138
  * The metafield owner.
279
139
  */
280
140
  export interface AppMetafieldEntryTarget {
281
- /** The type of the metafield owner. */
141
+ /**
142
+ * The type of the metafield owner.
143
+ *
144
+ * {% include /apps/checkout/privacy-icon.md %} Requires access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data) when the type is `customer`.
145
+ */
282
146
  type: 'customer' | 'product' | 'shop' | 'variant';
283
147
  /** The numeric owner ID that is associated with the metafield. */
284
148
  id: string;
@@ -287,25 +151,25 @@ export interface AppMetafieldEntryTarget {
287
151
  * A metafield associated with the shop or a resource on the checkout.
288
152
  */
289
153
  export interface AppMetafieldEntry {
290
- /** The target that is associated to the metadata. */
154
+ /**
155
+ * The target that is associated to the metadata.
156
+ *
157
+ * {% include /apps/checkout/privacy-icon.md %} Requires access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data) when the type is `customer`.
158
+ */
291
159
  target: AppMetafieldEntryTarget;
292
160
  /** The metadata information. */
293
161
  metafield: AppMetafield;
294
162
  }
295
- export type Version = 'unstable';
163
+ export type ApiVersion = '2022-10' | '2023-01' | '2023-04' | 'unstable';
164
+ export type Version = string;
296
165
  /**
297
- * This defines the i18n.translate() signature.
166
+ * This returns a translated string matching a key in a locale file.
167
+ *
168
+ * @example translate("banner.title")
298
169
  */
299
- export interface I18nTranslate {
300
- /**
301
- * This returns a translated string matching a key in a locale file.
302
- *
303
- * @example translate("banner.title")
304
- */
305
- <ReplacementType = string>(key: string, options?: {
306
- [placeholderKey: string]: ReplacementType | string | number;
307
- }): ReplacementType extends string | number ? string : (string | ReplacementType)[];
308
- }
170
+ export type I18nTranslate<ReplacementType = string> = (key: string, options?: {
171
+ [placeholderKey: string]: ReplacementType | string | number;
172
+ }) => ReplacementType extends string | number ? string : (string | ReplacementType)[];
309
173
  export interface I18n {
310
174
  /**
311
175
  * Returns a localized number.
@@ -372,6 +236,23 @@ export interface Currency {
372
236
  */
373
237
  isoCode: CurrencyCode;
374
238
  }
239
+ export interface Country {
240
+ /**
241
+ * The ISO-3166-1 code for this country.
242
+ * @see https://www.iso.org/iso-3166-country-codes.html
243
+ */
244
+ isoCode: CountryCode;
245
+ }
246
+ export interface Market {
247
+ /**
248
+ * A globally-unique identifier for a market.
249
+ */
250
+ id: string;
251
+ /**
252
+ * The human-readable, shop-scoped identifier for the market.
253
+ */
254
+ handle: string;
255
+ }
375
256
  export interface Localization {
376
257
  /**
377
258
  * The currency that the buyer sees for money amounts in the checkout.
@@ -397,81 +278,127 @@ export interface Localization {
397
278
  * extension (that is, the one matching your .default.json file).
398
279
  */
399
280
  extensionLanguage: StatefulRemoteSubscribable<Language>;
281
+ /**
282
+ * The country context of the checkout. This value carries over from the
283
+ * context of the cart, where it was used to contextualize the storefront
284
+ * experience. It will update if the buyer changes the country of their
285
+ * shipping address. The value is undefined if unknown.
286
+ */
287
+ country: StatefulRemoteSubscribable<Country | undefined>;
288
+ /**
289
+ * The [market](https://shopify.dev/docs/apps/markets) context of the
290
+ * checkout. This value carries over from the context of the cart, where it
291
+ * was used to contextualize the storefront experience. It will update if the
292
+ * buyer changes the country of their shipping address. The value is undefined
293
+ * if unknown.
294
+ */
295
+ market: StatefulRemoteSubscribable<Market | undefined>;
400
296
  }
401
297
  /**
402
- * The following APIs are provided to all extension points.
298
+ * Provides details on the buyer's progression through the checkout.
403
299
  */
404
- export interface StandardApi<ExtensionPoint extends AnyExtensionPoint> extends BaseStandardApi {
300
+ export interface BuyerJourney {
405
301
  /**
406
- * The renderer version being used for the extension.
302
+ * Installs a function for intercepting and preventing progress on checkout.
407
303
  *
408
- * @example 'unstable'
304
+ * This returns a promise that resolves to a teardown function. Calling the
305
+ * teardown function will remove the interceptor.
306
+ *
307
+ * To block checkout progress, you must set the [block_progress](https://shopify.dev/docs/api/checkout-ui-extensions/configuration#block-progress)
308
+ * capability in your extension's configuration.
409
309
  */
410
- version: Version;
310
+ intercept(interceptor: Interceptor): Promise<() => void>;
411
311
  /**
412
- * Provides details on buyer progression through the steps of the checkout.
413
- */
414
- buyerJourney: {
415
- /**
416
- * A function for intercepting and preventing progress on checkout. You can block
417
- * checkout progress by returning an object with `{behavior: 'block', reason: InvalidResultReason.InvalidExtensionState}`.
418
- * If you do, then you're expected to also update some part of your UI to reflect the reason why progress
419
- * was blocked.
420
- *
421
- * To block checkout progress, you must set the [block_progress](https://shopify.dev/api/checkout-extensions/checkout/configuration#block-progress) capability in your extension's configuration.
422
- */
423
- intercept(interceptor: Interceptor): Promise<() => void>;
424
- };
312
+ * This subscribable value will be true if the buyer completed submitting their order.
313
+ *
314
+ * For example, when viewing the order status page after submitting payment, the buyer will have completed their order.
315
+ */
316
+ completed: StatefulRemoteSubscribable<boolean>;
317
+ }
318
+ export interface StandardApi<ExtensionPoint extends import('../../extension-points').ExtensionPoint> {
425
319
  /**
426
- * The identifier of the running extension point.
427
- * @example 'Checkout::PostPurchase::Render'
320
+ * Methods for interacting with [Web Pixels](https://shopify.dev/docs/apps/marketing), such as emitting an event.
428
321
  */
429
- extensionPoint: ExtensionPoint;
322
+ analytics: Analytics;
430
323
  /**
431
- * Meta information about the extension.
324
+ * Gift Cards that have been applied to the checkout.
432
325
  */
433
- extension: ExtensionInstance;
326
+ appliedGiftCards: StatefulRemoteSubscribable<AppliedGiftCard[]>;
434
327
  /**
435
- * Key-value storage for the extension point.
328
+ * The metafields requested in the
329
+ * [`shopify.ui.extension.toml`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration)
330
+ * file. These metafields are updated when there's a change in the merchandise items
331
+ * being purchased by the customer.
332
+ *
333
+ * {% include /apps/checkout/privacy-icon.md %} Requires access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
436
334
  */
437
- storage: Storage;
335
+ appMetafields: StatefulRemoteSubscribable<AppMetafieldEntry[]>;
438
336
  /**
439
- * The proposed buyer shipping address. During the information step, the address
440
- * updates when the field is committed (on change) rather than every keystroke.
441
- * An address value is only present if delivery is required. Otherwise, the
442
- * subscribable value is undefined.
337
+ * Custom attributes left by the customer to the merchant, either in their cart or during checkout.
443
338
  */
444
- shippingAddress?: StatefulRemoteSubscribable<MailingAddress | undefined>;
339
+ attributes: StatefulRemoteSubscribable<Attribute[] | undefined>;
340
+ /**
341
+ * All available payment options.
342
+ */
343
+ availablePaymentOptions: StatefulRemoteSubscribable<PaymentOption[]>;
445
344
  /**
446
345
  * Information about the buyer that is interacting with the checkout.
346
+ *
347
+ * {% include /apps/checkout/privacy-icon.md %} Requires access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
447
348
  */
448
349
  buyerIdentity?: BuyerIdentity;
449
- /** Shop where the checkout is taking place. */
450
- shop: Shop;
350
+ /**
351
+ * Provides details on the buyer's progression through the checkout.
352
+ *
353
+ * See [buyer journey](https://shopify.dev/docs/api/checkout-ui-extensions/apis/standardapi#example-buyer-journey)
354
+ * examples for more information.
355
+ */
356
+ buyerJourney: BuyerJourney;
451
357
  /**
452
358
  * Details on the costs the buyer will pay for this checkout.
453
359
  */
454
360
  cost: CartCost;
455
361
  /**
456
- * A note left by the customer to the merchant, either in their cart or during checkout.
362
+ * A list of delivery groups containing information about the delivery of the items the customer intends to purchase.
457
363
  */
458
- note: StatefulRemoteSubscribable<string | undefined>;
364
+ deliveryGroups: StatefulRemoteSubscribable<DeliveryGroup[]>;
459
365
  /**
460
- * Performs an update on the note attached to the cart and checkout. If
461
- * successful, this mutation results in an update to the value retrieved
462
- * through the `note` property.
366
+ * A list of discount codes currently applied to the checkout.
463
367
  */
464
- applyNoteChange(change: NoteChange): Promise<NoteChangeResult>;
368
+ discountCodes: StatefulRemoteSubscribable<CartDiscountCode[]>;
465
369
  /**
466
- * Custom attributes left by the customer to the merchant, either in their cart or during checkout.
370
+ * Discounts that have been applied to the entire cart.
467
371
  */
468
- attributes: StatefulRemoteSubscribable<Attribute[] | undefined>;
372
+ discountAllocations: StatefulRemoteSubscribable<CartDiscountAllocation[]>;
469
373
  /**
470
- * Performs an update on an attribute attached to the cart and checkout. If
471
- * successful, this mutation results in an update to the value retrieved
472
- * through the `attributes` property.
374
+ * Meta information about the extension.
473
375
  */
474
- applyAttributeChange(change: AttributeChange): Promise<AttributeChangeResult>;
376
+ extension: Extension;
377
+ /**
378
+ * The identifier of the running extension point.
379
+ * @example 'Checkout::PostPurchase::Render'
380
+ */
381
+ extensionPoint: ExtensionPoint;
382
+ /**
383
+ * Utilities for translating content and formatting values according to the current
384
+ * [`localization`](https://shopify.dev/docs/api/checkout-ui-extensions/apis/standardapi#properties-propertydetail-localization)
385
+ * of the checkout.
386
+ *
387
+ * See [localization examples](https://shopify.dev/docs/api/checkout-ui-extensions/apis/standardapi#example-localization)
388
+ * for more information.
389
+ */
390
+ i18n: I18n;
391
+ /**
392
+ * A list of lines containing information about the items the customer intends to purchase.
393
+ */
394
+ lines: StatefulRemoteSubscribable<CartLine[]>;
395
+ /**
396
+ * Details about the location, language, and currency of the buyer. For utilities to easily
397
+ * format and translate content based on these details, you can use the
398
+ * [`i18n`](https://shopify.dev/docs/api/checkout-ui-extensions/apis/standardapi#properties-propertydetail-i18n)
399
+ * object instead.
400
+ */
401
+ localization: Localization;
475
402
  /**
476
403
  * The metafields that apply to the current checkout. The actual resource
477
404
  * on which these metafields exist depends on the source of the checkout:
@@ -492,93 +419,124 @@ export interface StandardApi<ExtensionPoint extends AnyExtensionPoint> extends B
492
419
  */
493
420
  metafields: StatefulRemoteSubscribable<Metafield[]>;
494
421
  /**
495
- * Performs an update on a piece of metadata attached to the checkout. If
496
- * successful, this mutation results in an update to the value retrieved
497
- * through the `metafields` property.
498
- */
499
- applyMetafieldChange(change: MetafieldChange): Promise<MetafieldChangeResult>;
500
- /**
501
- * A list of lines containing information about the items the customer intends to purchase.
422
+ * A note left by the customer to the merchant, either in their cart or during checkout.
502
423
  */
503
- lines: StatefulRemoteSubscribable<CartLine[]>;
424
+ note: StatefulRemoteSubscribable<string | undefined>;
504
425
  /**
505
426
  * A list of the line items displayed in the checkout. These may be the same as lines, or may be a subset.
506
427
  */
507
428
  presentmentLines: StatefulRemoteSubscribable<PresentmentCartLine[]>;
508
429
  /**
509
- * Performs an update on the merchandise line items. It resolves when the new
510
- * line items have been negotiated and results in an update to the value
511
- * retrieved through the `lines` property.
430
+ * Used to query the Storefront GraphQL API with a prefetched token.
431
+ *
432
+ * See [storefront api access examples](https://shopify.dev/docs/api/checkout-ui-extensions/apis/standardapi#example-storefront-api-access) for more information.
512
433
  */
513
- applyCartLinesChange(change: CartLineChange): Promise<CartLineChangeResult>;
434
+ query: <Data = unknown, Variables = {
435
+ [key: string]: unknown;
436
+ }>(query: string, options?: {
437
+ variables?: Variables;
438
+ version?: StorefrontApiVersion;
439
+ }) => Promise<{
440
+ data?: Data;
441
+ errors?: GraphQLError[];
442
+ }>;
514
443
  /**
515
- * A list of discount codes currently applied to the checkout.
444
+ * Payment options selected by the buyer.
516
445
  */
517
- discountCodes: StatefulRemoteSubscribable<CartDiscountCode[]>;
446
+ selectedPaymentOptions: StatefulRemoteSubscribable<SelectedPaymentOption[]>;
518
447
  /**
519
- * Discounts that have been applied to the entire cart.
448
+ * Provides access to session tokens, which can be used to verify token claims on your app's server.
449
+ *
450
+ * See [session token examples](https://shopify.dev/docs/api/checkout-ui-extensions/apis/standardapi#example-session-token) for more information.
520
451
  */
521
- discountAllocations: StatefulRemoteSubscribable<CartDiscountAllocation[]>;
452
+ sessionToken: SessionToken;
522
453
  /**
523
- * Performs an update on the discount codes.
524
- * It resolves when the new discount codes have been negotiated and results in an update
525
- * to the value retrieved through the `discountCodes` property.
454
+ * The settings matching the settings definition written in the
455
+ * [`shopify.ui.extension.toml`](https://shopify.dev/docs/api/checkout-ui-extensions/configuration) file.
456
+ *
457
+ * See [settings examples](https://shopify.dev/docs/api/checkout-ui-extensions/apis/standardapi#example-settings) for more information.
458
+ *
459
+ * > Note: When an extension is being installed in the editor, the settings will be empty until
460
+ * a merchant sets a value. In that case, this object will be updated in real time as a merchant fills in the settings.
526
461
  */
527
- applyDiscountCodeChange(change: DiscountCodeChange): Promise<DiscountCodeChangeResult>;
462
+ settings: StatefulRemoteSubscribable<ExtensionSettings>;
528
463
  /**
529
- * The metafields requested in the `shopify.ui.extension.toml` file. These metafields are
530
- * updated when there's a change in the merchandise items being purchased by the customer.
464
+ * The proposed buyer shipping address. During the information step, the address
465
+ * updates when the field is committed (on change) rather than every keystroke.
466
+ * An address value is only present if delivery is required. Otherwise, the
467
+ * subscribable value is undefined.
468
+ *
469
+ * {% include /apps/checkout/privacy-icon.md %} Requires access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
531
470
  */
532
- appMetafields: StatefulRemoteSubscribable<AppMetafieldEntry[]>;
471
+ shippingAddress?: StatefulRemoteSubscribable<MailingAddress | undefined>;
472
+ /** Shop where the checkout is taking place. */
473
+ shop: Shop;
533
474
  /**
534
- * Details about the location, language, and currency of the buyer. For utilities to easily
535
- * format and translate content based on these details, you can use the `i18n` object instead.
475
+ * Key-value storage for the extension point.
536
476
  */
537
- localization: Localization;
477
+ storage: Storage;
538
478
  /**
539
- * Utilities for translating content and formatting values according to the current `localization`
540
- * of the checkout.
479
+ * Methods to interact with the extension's UI.
541
480
  */
542
- i18n: I18n;
481
+ ui: Ui;
543
482
  /**
544
- * The settings matching the settings definition written in the `shopify.ui.extension.toml` file.
483
+ * The renderer version being used for the extension.
545
484
  *
546
- * **Note:** When an extension is being installed in the editor, the settings will be empty until
547
- * a merchant sets a value. In that case, this object will be updated in real time as a merchant fills in the settings.
485
+ * @example 'unstable'
548
486
  */
549
- settings: StatefulRemoteSubscribable<ExtensionSettings>;
487
+ version: Version;
488
+ }
489
+ export interface Ui {
490
+ overlay: {
491
+ close(overlayId: string): void;
492
+ };
493
+ }
494
+ export interface SessionToken {
550
495
  /**
551
- * Exposes a `analytics.publish` method to publish analytics events.
496
+ * Requests a session token that hasn't expired. You should call this method every
497
+ * time you need to make a request to your backend in order to get a valid token.
498
+ * This method will return cached tokens when possible, so you don’t need to worry
499
+ * about storing these tokens yourself.
552
500
  */
553
- analytics: Analytics;
501
+ get(): Promise<string>;
554
502
  }
555
503
  export interface BuyerIdentity {
556
504
  /**
557
- * The customer account from the buyer. This value will update when there's a
558
- * change in the account. The value is undefined if the buyer isn’t a known customer
559
- * for this shop.
505
+ * The buyer's customer account. The value is undefined if the buyer isn’t a
506
+ * known customer for this shop or if they haven't logged in yet.
560
507
  *
561
- * Protected resource: Requires approval to access protected customer data.
562
- * More info - https://shopify.dev/apps/store/data-protection/protected-customer-data
508
+ * {% include /apps/checkout/privacy-icon.md %} Requires access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
563
509
  */
564
510
  customer: StatefulRemoteSubscribable<Customer | undefined>;
565
511
  /**
566
- * The email address of the buyer that is interacting with the cart. This value will update when there's a
567
- * change in the checkout formulary. The value is undefined if no permission given.
512
+ * The email address of the buyer that is interacting with the cart.
513
+ * The value is `undefined` if the app does not have access to customer data.
568
514
  *
569
- * Protected resource: Requires approval to access protected customer data (Level 2).
570
- * More info - https://shopify.dev/apps/store/data-protection/protected-customer-data
515
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
571
516
  */
572
517
  email: StatefulRemoteSubscribable<string | undefined>;
573
518
  /**
574
- * The phone number of the buyer that is interacting with the cart. This value will update when there's a
575
- * change in the checkout formulary. The value is undefined if no permission given.
519
+ * The phone number of the buyer that is interacting with the cart.
520
+ * The value is `undefined` if the app does not have access to customer data.
576
521
  *
577
- * Protected resource: Requires approval to access protected customer data (Level 2).
578
- * More info - https://shopify.dev/apps/store/data-protection/protected-customer-data
522
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
579
523
  */
580
524
  phone: StatefulRemoteSubscribable<string | undefined>;
581
525
  }
526
+ export interface AppliedGiftCard {
527
+ /**
528
+ * The last four characters of the applied gift card's code.
529
+ */
530
+ lastCharacters: string;
531
+ /**
532
+ * The amount of the applied gift card that will be used when the checkout is completed.
533
+ */
534
+ amountUsed: Money;
535
+ /**
536
+ * The current balance of the applied gift card prior to checkout completion.
537
+ */
538
+ balance: Money;
539
+ }
582
540
  export interface Shop {
583
541
  /**
584
542
  * The shop ID.
@@ -601,56 +559,89 @@ export interface Shop {
601
559
  export interface MailingAddress {
602
560
  /**
603
561
  * The buyer's full name.
562
+ *
563
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
564
+ *
604
565
  * @example 'John Doe'
605
566
  */
606
567
  name?: string;
607
568
  /**
608
569
  * The buyer's first name.
570
+ *
571
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
572
+ *
609
573
  * @example 'John'
610
574
  */
611
575
  firstName?: string;
612
576
  /**
613
577
  * The buyer's last name.
578
+ *
579
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
580
+ *
614
581
  * @example 'Doe'
615
582
  */
616
583
  lastName?: string;
617
584
  /**
618
585
  * The buyer's company name.
586
+ *
587
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 1 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
588
+ *
619
589
  * @example 'Shopify'
620
590
  */
621
591
  company?: string;
622
592
  /**
623
593
  * The first line of the buyer's address, including street name and number.
594
+ *
595
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
596
+ *
624
597
  * @example '151 O'Connor Street'
625
598
  */
626
599
  address1?: string;
627
600
  /**
628
601
  * The second line of the buyer's address, like apartment number, suite, etc.
602
+ *
603
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
604
+ *
629
605
  * @example 'Ground floor'
630
606
  */
631
607
  address2?: string;
632
608
  /**
633
609
  * The buyer's city.
610
+ *
611
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
612
+ *
634
613
  * @example 'Ottawa'
635
614
  */
636
615
  city?: string;
637
616
  /**
638
617
  * The buyer's postal or ZIP code.
618
+ *
619
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
620
+ *
639
621
  * @example 'K2P 2L8'
640
622
  */
641
623
  zip?: string;
642
624
  /**
643
625
  * The ISO 3166 Alpha-2 format for the buyer's country. Refer to https://www.iso.org/iso-3166-country-codes.html.
626
+ *
627
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
628
+ *
644
629
  * @example 'CA' for Canada.
645
630
  */
646
631
  countryCode?: CountryCode;
647
632
  /**
648
633
  * The buyer's zone code, such as state, province, prefecture, or region.
634
+ *
635
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
636
+ *
649
637
  * @example 'ON' for Ontario.
650
638
  */
651
639
  provinceCode?: string;
652
640
  /**
653
641
  * The buyer's phone number.
642
+ *
643
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
644
+ *
654
645
  * @example '+1 613 111 2222'.
655
646
  */
656
647
  phone?: string;
@@ -692,22 +683,44 @@ export interface CartLine {
692
683
  * Discounts applied to the cart line.
693
684
  */
694
685
  discountAllocations: CartDiscountAllocation[];
695
- /** @private */
696
- __lineComponents: CartLineComponentType[];
686
+ /**
687
+ * Sub lines of the merchandise line. If no sub lines are present, this will be an empty array.
688
+ */
689
+ lineComponents: CartLineComponentType[];
697
690
  }
698
- /** @private */
699
691
  type CartLineComponentType = CartBundleLineComponent;
700
- /** @private */
701
692
  export interface CartBundleLineComponent {
693
+ type: 'bundle';
694
+ /**
695
+ * A unique identifier for the bundle line component.
696
+ *
697
+ * This ID is not stable. If an operation updates the line items in any way, all IDs could change.
698
+ *
699
+ * @example 'gid://shopify/CartLineComponent/123'
700
+ */
702
701
  id: string;
702
+ /**
703
+ * The merchandise of this bundle line component.
704
+ */
703
705
  merchandise: Merchandise;
706
+ /**
707
+ * The quantity of merchandise being purchased.
708
+ */
704
709
  quantity: number;
710
+ /**
711
+ * The cost attributed to this bundle line component.
712
+ */
705
713
  cost: CartLineCost;
714
+ /**
715
+ * Additional custom attributes for the bundle line component.
716
+ *
717
+ * @example [{key: 'engraving', value: 'hello world'}]
718
+ */
706
719
  attributes: Attribute[];
707
720
  }
708
721
  export interface CartLineCost {
709
722
  /**
710
- * The total amount the buyer can expect to pay that is directly attributable to a single
723
+ * The total amount after reductions the buyer can expect to pay that is directly attributable to a single
711
724
  * cart line.
712
725
  */
713
726
  totalAmount: Money;
@@ -758,6 +771,14 @@ export interface ProductVariant extends BaseMerchandise {
758
771
  * The product object that the product variant belongs to.
759
772
  */
760
773
  product: Product;
774
+ /**
775
+ * Whether or not the product requires shipping.
776
+ */
777
+ requiresShipping: boolean;
778
+ /**
779
+ * The selling plan associated with the merchandise.
780
+ */
781
+ sellingPlan?: SellingPlan;
761
782
  }
762
783
  export interface Product {
763
784
  /**
@@ -783,16 +804,6 @@ export interface ImageDetails {
783
804
  */
784
805
  altText?: string;
785
806
  }
786
- export interface Attribute {
787
- /**
788
- * The key for the attribute.
789
- */
790
- key: string;
791
- /**
792
- * The value for the attribute.
793
- */
794
- value: string;
795
- }
796
807
  export interface SelectedOption {
797
808
  /**
798
809
  * The name of the merchandise option.
@@ -841,83 +852,46 @@ export interface PresentmentCartLineCost {
841
852
  */
842
853
  totalAmount: Money;
843
854
  }
844
- export interface CartLineChangeResultSuccess {
845
- /**
846
- * Indicates that the line item was changed successfully.
847
- */
848
- type: 'success';
849
- }
850
- export interface CartLineChangeResultError {
851
- /**
852
- * Indicates that the line item was not changed successfully. Refer to the `message` property for details about the error.
853
- */
854
- type: 'error';
855
- /**
856
- * A message that explains the error. This message is useful for debugging.
857
- * It is **not** localized, and therefore should not be presented directly
858
- * to the buyer.
859
- */
860
- message: string;
861
- }
862
- export type CartLineChangeResult = CartLineChangeResultSuccess | CartLineChangeResultError;
863
- export type CartLineChange = CartLineAddChange | CartLineRemoveChange | CartLineUpdateChange;
864
- export interface CartLineAddChange {
865
- /**
866
- * An identifier for changes that add line items.
867
- */
868
- type: 'addCartLine';
869
- /**
870
- * The merchandise ID being added.
871
- * @example 'gid://shopify/ProductVariant/123'
872
- */
873
- merchandiseId: string;
874
- /**
875
- * The quantity of the merchandise being added.
876
- */
877
- quantity: number;
878
- /**
879
- * The attributes associated with the line item.
880
- */
881
- attributes?: Attribute[];
882
- }
883
- export interface CartLineRemoveChange {
884
- /**
885
- * An identifier for changes that remove line items.
886
- */
887
- type: 'removeCartLine';
888
- /**
889
- * Line Item ID.
890
- * @example 'gid://shopify/CartLine/123'
891
- */
892
- id: string;
855
+ /**
856
+ * A payment option presented to the buyer.
857
+ */
858
+ export interface PaymentOption {
893
859
  /**
894
- * The quantity being removed for this line item.
860
+ * The type of the payment option.
861
+ *
862
+ * Shops can be configured to support many different payment options. Some options are only available to buyers in specific regions.
863
+ *
864
+ * | Type | Description |
865
+ * |---|---|
866
+ * | `creditCard` | A vaulted or manually entered credit card. |
867
+ * | `deferred` | A [deferred payment](https://help.shopify.com/en/manual/orders/deferred-payments), such as invoicing the buyer and collecting payment at a later time. |
868
+ * | `local` | A [local payment option](https://help.shopify.com/en/manual/payments/shopify-payments/local-payment-methods) specific to the current region or market |
869
+ * | `manualPayment` | A manual payment option such as an in-person retail transaction. |
870
+ * | `offsite` | A payment processed outside of Shopify's checkout, excluding integrated wallets. |
871
+ * | `other` | Another type of payment not defined here. |
872
+ * | `paymentOnDelivery` | A payment that will be collected on delivery. |
873
+ * | `redeemable` | A redeemable payment option such as a gift card or store credit. |
874
+ * | `wallet` | An integrated wallet such as PayPal, Google Pay, Apple Pay, etc. |
875
+ * | `customOnsite` | A custom payment option that is processed through a checkout extension with a payments app. |
876
+ */
877
+ type: 'creditCard' | 'deferred' | 'local' | 'manualPayment' | 'offsite' | 'other' | 'paymentOnDelivery' | 'redeemable' | 'wallet' | 'customOnsite';
878
+ /**
879
+ * The unique handle for the payment option.
880
+ *
881
+ * This is not a globally unique identifier. It may be an identifier specific to the given checkout session or the current shop.
895
882
  */
896
- quantity: number;
883
+ handle: string;
897
884
  }
898
- export interface CartLineUpdateChange {
899
- /**
900
- * An identifier for changes that update line items.
901
- */
902
- type: 'updateCartLine';
903
- /**
904
- * Line Item ID.
905
- * @example 'gid://shopify/CartLine/123'
906
- */
907
- id: string;
908
- /**
909
- * The new merchandise ID for the line item.
910
- * @example 'gid://shopify/ProductVariant/123'
911
- */
912
- merchandiseId?: string;
913
- /**
914
- * The new quantity for the line item.
915
- */
916
- quantity?: number;
885
+ /**
886
+ * A payment option selected by the buyer.
887
+ */
888
+ export interface SelectedPaymentOption {
917
889
  /**
918
- * The new attributes for the line item.
890
+ * The unique handle referencing `PaymentOption.handle`.
891
+ *
892
+ * See [availablePaymentOptions](https://shopify.dev/docs/api/checkout-ui-extensions/unstable/apis/standardapi#properties-propertydetail-availablepaymentoptions).
919
893
  */
920
- attributes?: Attribute[];
894
+ handle: string;
921
895
  }
922
896
  export interface CartDiscountCode {
923
897
  /**
@@ -962,46 +936,6 @@ export interface CartCustomDiscountAllocation extends CartDiscountAllocationBase
962
936
  */
963
937
  type: 'custom';
964
938
  }
965
- export type DiscountCodeChange = DiscountCodeAddChange | DiscountCodeRemoveChange;
966
- export type DiscountCodeChangeResult = DiscountCodeChangeResultSuccess | DiscountCodeChangeResultError;
967
- export interface DiscountCodeAddChange {
968
- /**
969
- * The type of the `DiscountCodeChange` API.
970
- */
971
- type: 'addDiscountCode';
972
- /**
973
- * The code for the discount
974
- */
975
- code: string;
976
- }
977
- export interface DiscountCodeRemoveChange {
978
- /**
979
- * The type of the `DiscountCodeChange` API.
980
- */
981
- type: 'removeDiscountCode';
982
- /**
983
- * The code for the discount
984
- */
985
- code: string;
986
- }
987
- export interface DiscountCodeChangeResultSuccess {
988
- /**
989
- * Indicates that the discount code change was applied successfully.
990
- */
991
- type: 'success';
992
- }
993
- export interface DiscountCodeChangeResultError {
994
- /**
995
- * Indicates that the discount code change failed.
996
- */
997
- type: 'error';
998
- /**
999
- * A message that explains the error. This message is useful for debugging.
1000
- * It is **not** localized, and therefore should not be presented directly
1001
- * to the buyer.
1002
- */
1003
- message: string;
1004
- }
1005
939
  type InterceptorResult = InterceptorResultAllow | InterceptorResultBlock;
1006
940
  interface InterceptorResultAllow {
1007
941
  /**
@@ -1042,13 +976,17 @@ interface InterceptorRequestBlock {
1042
976
  * own internal debugging and metrics.
1043
977
  */
1044
978
  reason: string;
979
+ /**
980
+ * Used to pass errors to the checkout UI, outside your extension's UI boundaries.
981
+ */
982
+ errors?: ValidationError[];
1045
983
  /**
1046
984
  * This callback is called when all interceptors finish. We recommend
1047
985
  * setting errors or reasons for blocking at this stage, so that all the errors in
1048
986
  * the UI show up at once.
1049
987
  * @param result InterceptorResult with behavior as either 'allow' or 'block'
1050
988
  */
1051
- perform(result: InterceptorResult): void | Promise<void>;
989
+ perform?(result: InterceptorResult): void | Promise<void>;
1052
990
  }
1053
991
  export interface InterceptorProps {
1054
992
  /**
@@ -1057,52 +995,92 @@ export interface InterceptorProps {
1057
995
  */
1058
996
  canBlockProgress: boolean;
1059
997
  }
1060
- export interface Interceptor {
1061
- /**
1062
- * A function for intercepting and preventing navigation on checkout. You can block
1063
- * navigation by returning an object with `{behavior: 'block', reason: InvalidResultReason.InvalidExtensionState}`.
1064
- * If you do, then you're expected to also update some part of your UI to reflect the reason why navigation
1065
- * was blocked.
1066
- */
1067
- (interceptorProps: InterceptorProps): InterceptorRequest | Promise<InterceptorRequest>;
1068
- }
998
+ /**
999
+ * A function for intercepting and preventing navigation on checkout. You can block
1000
+ * navigation by returning an object with
1001
+ * `{behavior: 'block', reason: InvalidResultReason.InvalidExtensionState, errors?: ValidationErrors[]}`.
1002
+ * If you do, then you're expected to also update some part of your UI to reflect the reason why navigation
1003
+ * was blocked, either by targeting checkout UI fields, passing errors to the page level or rendering the errors in your extension.
1004
+ */
1005
+ export type Interceptor = (interceptorProps: InterceptorProps) => InterceptorRequest | Promise<InterceptorRequest>;
1069
1006
  /**
1070
1007
  * Information about a customer who has previously purchased from this shop.
1008
+ *
1009
+ * {% include /apps/checkout/privacy-icon.md %} Requires access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1071
1010
  */
1072
1011
  export interface Customer {
1073
1012
  /**
1074
1013
  * Customer ID.
1014
+ *
1015
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 1 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1016
+ *
1075
1017
  * @example 'gid://shopify/Customer/123'
1076
1018
  */
1077
1019
  id: string;
1078
1020
  /**
1079
1021
  * The email of the customer.
1022
+ *
1023
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1080
1024
  */
1081
1025
  email?: string;
1082
1026
  /**
1083
1027
  * The phone number of the customer.
1028
+ *
1029
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1084
1030
  */
1085
1031
  phone?: string;
1086
1032
  /**
1087
1033
  * The full name of the customer.
1034
+ *
1035
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1088
1036
  */
1089
1037
  fullName?: string;
1090
1038
  /**
1091
1039
  * The first name of the customer.
1040
+ *
1041
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1092
1042
  */
1093
1043
  firstName?: string;
1094
1044
  /**
1095
1045
  * The last name of the customer.
1046
+ *
1047
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 2 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1096
1048
  */
1097
1049
  lastName?: string;
1098
1050
  /**
1099
1051
  * The image associated with the customer.
1052
+ *
1053
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 1 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1100
1054
  */
1101
1055
  image: ImageDetails;
1102
1056
  /**
1103
1057
  * Defines if the customer accepts marketing activities.
1058
+ *
1059
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 1 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1104
1060
  */
1105
1061
  acceptsMarketing: boolean;
1062
+ /**
1063
+ * The Store Credit Accounts owned by the customer and usable during the checkout process.
1064
+ *
1065
+ * {% include /apps/checkout/privacy-icon.md %} Requires level 1 access to [protected customer data](/docs/apps/store/data-protection/protected-customer-data).
1066
+ *
1067
+ * @private
1068
+ */
1069
+ storeCreditAccounts: StoreCreditAccount[];
1070
+ }
1071
+ /**
1072
+ * Information about a Store Credit Account.
1073
+ */
1074
+ export interface StoreCreditAccount {
1075
+ /**
1076
+ * A globally-unique identifier.
1077
+ * @example 'gid://shopify/StoreCreditAccount/1'
1078
+ */
1079
+ id: string;
1080
+ /**
1081
+ * The current balance of the Store Credit Account.
1082
+ */
1083
+ balance: Money;
1106
1084
  }
1107
1085
  /**
1108
1086
  * The merchant-defined setting values for the extension.
@@ -1110,13 +1088,191 @@ export interface Customer {
1110
1088
  export interface ExtensionSettings {
1111
1089
  [key: string]: string | number | boolean | undefined;
1112
1090
  }
1113
- /**
1114
- * Publish method to emit analytics events to Web Pixels.
1115
- */
1116
1091
  export interface Analytics {
1092
+ /**
1093
+ * Publish method to emit analytics events to [Web Pixels](https://shopify.dev/docs/apps/marketing).
1094
+ */
1117
1095
  publish(name: string, data: {
1118
1096
  [key: string]: unknown;
1119
1097
  }): Promise<boolean>;
1120
1098
  }
1099
+ /**
1100
+ * Represents the delivery information and options available for one or
1101
+ * more cart lines.
1102
+ */
1103
+ export interface DeliveryGroup {
1104
+ /**
1105
+ * The cart line references associated to the delivery group.
1106
+ */
1107
+ targetedCartLines: CartLineReference[];
1108
+ /**
1109
+ * The delivery options available for the delivery group.
1110
+ */
1111
+ deliveryOptions: DeliveryOption[];
1112
+ /**
1113
+ * The selected delivery option for the delivery group.
1114
+ */
1115
+ selectedDeliveryOption?: DeliveryOptionReference;
1116
+ /**
1117
+ * The type of the delivery group.
1118
+ */
1119
+ groupType: DeliveryGroupType;
1120
+ /**
1121
+ * Whether delivery is required for the delivery group.
1122
+ */
1123
+ deliveryRequired: boolean;
1124
+ }
1125
+ /**
1126
+ * The possible types of a delivery group.
1127
+ */
1128
+ export type DeliveryGroupType = 'oneTimePurchase' | 'subscription';
1129
+ /**
1130
+ * Represents a reference to a cart line.
1131
+ */
1132
+ export interface CartLineReference {
1133
+ /**
1134
+ * The unique identifier of the referenced cart line.
1135
+ */
1136
+ id: string;
1137
+ }
1138
+ /**
1139
+ * Represents a reference to a delivery option.
1140
+ */
1141
+ export interface DeliveryOptionReference {
1142
+ /**
1143
+ * The unique identifier of the referenced delivery option.
1144
+ */
1145
+ handle: string;
1146
+ }
1147
+ /**
1148
+ * Represents a base interface for a single delivery option.
1149
+ */
1150
+ export interface DeliveryOption {
1151
+ /**
1152
+ * The unique identifier of the delivery option.
1153
+ */
1154
+ handle: string;
1155
+ /**
1156
+ * The title of the delivery option.
1157
+ */
1158
+ title?: string;
1159
+ /**
1160
+ * The description of the delivery option.
1161
+ */
1162
+ description?: string;
1163
+ }
1164
+ /**
1165
+ * Represents a delivery option that is a shipping option.
1166
+ */
1167
+ export interface ShippingOption extends DeliveryOption {
1168
+ /**
1169
+ * The type of this delivery option.
1170
+ */
1171
+ type: 'shipping' | 'local';
1172
+ /**
1173
+ * Information about the carrier.
1174
+ */
1175
+ carrier: ShippingOptionCarrier;
1176
+ /**
1177
+ * The cost of the delivery.
1178
+ */
1179
+ cost: Money;
1180
+ /**
1181
+ * The cost of the delivery including discounts.
1182
+ */
1183
+ costAfterDiscounts: Money;
1184
+ /**
1185
+ * Information about the estimated delivery time.
1186
+ */
1187
+ deliveryEstimate: DeliveryEstimate;
1188
+ }
1189
+ export interface DeliveryEstimate {
1190
+ /**
1191
+ * The estimated time in transit for the delivery in seconds.
1192
+ */
1193
+ timeInTransit?: NumberRange;
1194
+ }
1195
+ export interface ShippingOptionCarrier {
1196
+ /**
1197
+ * The name of the carrier.
1198
+ */
1199
+ name?: string;
1200
+ }
1201
+ export interface PickupPointOption extends DeliveryOption {
1202
+ /**
1203
+ * The type of this delivery option.
1204
+ */
1205
+ type: 'pickupPoint';
1206
+ /**
1207
+ * Information about the carrier that ships to the pickup point.
1208
+ */
1209
+ carrier: PickupPointCarrier;
1210
+ /**
1211
+ * The cost to ship to this pickup point.
1212
+ */
1213
+ cost: Money;
1214
+ /**
1215
+ * The cost to ship to this pickup point including discounts.
1216
+ */
1217
+ costAfterDiscounts: Money;
1218
+ /**
1219
+ * The location details of the pickup point.
1220
+ */
1221
+ location: PickupPointLocation;
1222
+ }
1223
+ export interface PickupLocationOption extends DeliveryOption {
1224
+ /**
1225
+ * The type of this delivery option.
1226
+ */
1227
+ type: 'pickup';
1228
+ /**
1229
+ * The location details of the pickup location.
1230
+ */
1231
+ location: PickupLocation;
1232
+ }
1233
+ interface PickupLocation {
1234
+ /**
1235
+ * The name of the pickup location.
1236
+ */
1237
+ name?: string;
1238
+ /**
1239
+ * The address of the pickup location.
1240
+ */
1241
+ address: MailingAddress;
1242
+ }
1243
+ interface PickupPointLocation {
1244
+ /**
1245
+ * The name of the pickup point.
1246
+ */
1247
+ name?: string;
1248
+ /**
1249
+ * The unique identifier of the pickup point.
1250
+ */
1251
+ handle: string;
1252
+ /**
1253
+ * The address of the pickup point.
1254
+ */
1255
+ address: MailingAddress;
1256
+ }
1257
+ interface PickupPointCarrier {
1258
+ /**
1259
+ * The code identifying the carrier.
1260
+ */
1261
+ code?: string;
1262
+ /**
1263
+ * The name of the carrier.
1264
+ */
1265
+ name?: string;
1266
+ }
1267
+ export interface NumberRange {
1268
+ /**
1269
+ * The lower bound of the number range.
1270
+ */
1271
+ lower?: number;
1272
+ /**
1273
+ * The upper bound of the number range.
1274
+ */
1275
+ upper?: number;
1276
+ }
1121
1277
  export {};
1122
1278
  //# sourceMappingURL=standard.d.ts.map