Hi. You need to add a condition to your button in the code (below is an example) and you need to add the buttons you have in the code instead of the given buttons, while using this logic:
I think the method of searching for an element by class will work for you. Download your theme and open it through a handy code editor. Then try to find the class “product-form__buttons”, there you should see these buttons.
You’ll need to edit your Dawn theme’s code. Go to Online Store → Themes → Actions → Edit code and find the product form file (typically sections/main-product.liquid or snippets/product-form.liquid). Add Liquid conditional logic checking if product.selected_or_first_available_variant.inventory_quantity is ≤ 0, then display “Pre-order” instead of “Add to cart.” Wrap dynamic checkout buttons with the same conditional to hide them at zero inventory. Here’s Shopify’s theme editing guide.
Trade-offs: This requires theme customization knowledge and maintenance across theme updates.
Alternatively, an app like K1 PreOrder (I’m the founder) automates this—replacing the button with “Pre-order” text when inventory hits zero and hiding dynamic checkout buttons automatically. It uses Theme App Extensions (no manual coding) and works with Dawn 10.0.0. Here’s the K1 PreOrder listing if relevant.
Happy to help with the theme customization if needed.