Dynamic delivery date estimates and mandatory TSCA consent blocks at checkout, powered by Shopify Functions.
Interested in a similar project?
Tell us about your store and goals — we'll come back with ideas.
Dynamic delivery date estimates and mandatory TSCA consent blocks at checkout, powered by Shopify Functions.
Shipping times vary by country and method, but standard Shopify didn't allow flexible, data-driven display of precise delivery expectations, factoring in business days and holidays. Separately, certain products require TSCA consent for US orders, but the default checkout UI didn't provide dedicated, validated blocks for this kind of mandatory information and confirmation.
We built a dedicated checkout app called "pap-checkout-extensions" using both Checkout UI Extensions and Shopify Functions.
On the UI side, a shipping text component displays dynamic delivery messages based on data stored in a shop metafield, and a TSCA form is shown for US customers with TSCA-tagged products, including a mandatory checkbox and a "More information" pop-up.
On the Functions side, a delivery-customization function calculates shipping dates per country and method (taking weekends and holidays into account), and validation functions ensure checkout can't proceed until the TSCA checkbox is ticked when TSCA-tagged items are in the cart.
Customers get clearer, more accurate expectations around delivery time, which reduces negative surprises and shipping-related support requests. For US orders with TSCA products, the extra confirmation step is embedded directly into checkout, helping the business meet compliance requirements while keeping the process structured and auditable.
Shipping data is stored in the "shipping.data" shop metafield as a compressed JSON payload (due to metafield size limits), used by both the delivery-customization Function and the shipping text UI extension. The function uses a holidays array to skip non-working days and calculates a specific delivery date per shipping method. Products that require TSCA consent are tagged "TSCA"; the UI extension renders the checkbox and popup, and a validation function blocks order submission if consent isn't given.
Stay in the loop
New Shopify case studies and storefront insights — straight to your inbox.
Tell us about your store and goals — we'll come back with ideas.