Theme Dawn: Breite eines Text-Containers anpassen

Topic summary

A user working with Shopify’s Dawn theme needed help adjusting the width of a text container on a custom page. The text remained centered but wouldn’t expand beyond the default width, despite attempts using CSS with max-width: 800px.

Solution provided:

  • Add CSS code to the bottom of base.css
  • Target .article-template__content.page-width.page-width--narrow and .page-width.page-width--narrow classes
  • Use max-width: 90% or max-width: 100% with !important flags
  • Include margin: 0 auto to maintain centering
  • Add padding (e.g., padding: 0 50px) for spacing

The solution successfully resolved the issue, allowing the text container to expand while staying centered on the page.

Summarized with AI on November 1. AI used: claude-sonnet-4-5-20250929.

Ein freundliches Hallo in die Runde…

Ich nutze das Theme Dawn und habe folgendes Problem:
Ich habe eine neue Seite angelegt und einen stinknormalen Fließtext verfasst. Nun versuche ich die Breite dieses Textes so zu verändern, das er mittig auf der Seite bleibt, aber breiter wird. Leider gelingt mir dies nicht.

Hat jemand eine Idee?

Hab es schon mit folgendem css-Code versucht:



.text-container {



max-width: 800px;



margin: 0 auto;



}

Dabei bleibt der Text zwar mittig, aber er wird nicht breiter. Möchte mehr als 800px…

Hoffe es kann mir jemand helfen! :blush:

Etwas wie der folgende CSS ganz unten im base.css - passe es einfach deinen Bedürfnissen an:

.article-template__content.page-width.page-width--narrow {
    margin: 0 auto !important; 
    max-width: 90% !important; 
    padding: 0 50px; 
}

.page-width.page-width--narrow {
    max-width: 100% !important;
    margin: 0 auto !important;
    padding: 0 50px; 
}
1 Like

Super! Genau das, was ich gesucht habe! Vielen Dank!

1 Like