Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .changeset/cruel-crabs-rest.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'@shopify/ui-extensions': patch
---

- Adding toggle state to Announcement callback events docs
- Adding correct Map callback events docs
- Adding setup updated setup instructions for checkout extensions
25 changes: 15 additions & 10 deletions packages/ui-extensions/docs/surfaces/checkout/build-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ fail_and_exit() {
run_sed() {
if [[ "$OSTYPE" == "darwin"* ]]; then
# macOS
# WARNING: do not synchronize this with checkout-web
sed -Ei '' "$1" "$2"
else
# Linux and other Unix-like systems
Expand Down Expand Up @@ -100,19 +101,23 @@ copy_generated_docs_to_shopify_dev() {
if [ -d $SHOPIFY_DEV_PATH ]; then
mkdir -p $SHOPIFY_DEV_PATH/db/data/docs/templated_apis/checkout_extensions/$API_VERSION
cp ./$DOCS_PATH/generated/* $SHOPIFY_DEV_PATH/db/data/docs/templated_apis/checkout_extensions/$API_VERSION
# Replace 'unstable' with the exact API version in relative doc links
run_sed \
"s/\/docs\/api\/checkout-ui-extensions\/unstable/\/docs\/api\/checkout-ui-extensions\/$API_VERSION/gi" \
$SHOPIFY_DEV_PATH/db/data/docs/templated_apis/checkout_extensions/$API_VERSION/generated_docs_data.json
sed_exit=$?
if [ $sed_exit -ne 0 ]; then
fail_and_exit $sed_exit
fi

# Replace 'latest' with the exact API version in relative doc links
for file in generated_docs_data.json generated_static_pages.json; do
run_sed \
"s/\/docs\/api\/checkout-ui-extensions\/latest/\/docs\/api\/checkout-ui-extensions\/$API_VERSION/gi" \
"$SHOPIFY_DEV_PATH/db/data/docs/templated_apis/checkout_extensions/$API_VERSION/$file"
sed_exit=$?
if [ $sed_exit -ne 0 ]; then
fail_and_exit $sed_exit
fi
done

rsync -a --delete ./$DOCS_PATH/screenshots/ $SHOPIFY_DEV_PATH/react-app/public/images/templated-apis-screenshots/checkout-ui-extensions/$API_VERSION
echo "Docs: https://shopify-dev.shop.dev/docs/api/checkout-ui-extensions"
else
echo "Not copying docs to shopify-dev because it was not found at $SHOPIFY_DEV_PATH."
fi
echo "Not copying docs to shopify-dev because it was not found at $SHOPIFY_DEV_PATH."
fi
}

# Assume we have a relative path to shopify-dev (for non-local environments like CI, and Github Actions)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const data: ReferenceEntityTemplateSchema = {
description: `
The APIs for interacting with delivery and shipping options.

> > Tip: Not all extension targets implement all APIs. Check the documentation for the extension target you are using to see which APIs are available.
> Tip: Not all extension targets implement all APIs. Check the documentation for the extension target you are using to see which APIs are available.
`,
overviewPreviewDescription:
'The APIs for interacting with delivery and shipping options.',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ api_version = "2025-10"
[[extensions]]
name = "My checkout extension"
handle = "checkout-ui"
uid = "fddfc370-27c7-c30f-4ee0-a927194e2accadefd40c"
type = "ui_extension"

[[extensions.targeting]]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ api_version = "2025-10"
[[extensions]]
name = "My checkout extension"
handle = "checkout-ui"
uid = "fddfc370-27c7-c30f-4ee0-a927194e2accadefd40c"
type = "ui_extension"

[[extensions.targeting]]
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

Loading