Skip to content

Responsive

TaishoDS Core offers three responsive modes. Pick one based on how much control you need—from zero breakpoints to full control by viewport.

1 · Auto-fit (recommended)

No breakpoints. The grid fits as many columns as there’s room for, based on a minimum width. Ideal for content grids.

html
<!-- min = minimum width token: 2xs..xl (160→400px) -->
<div class="ts grid-auto grid-min-sm gap-base">
  <div>…</div> <div>…</div> <div>…</div>
</div>

2 · Container queries

The response depends on the container’s width, not the viewport—perfect for components that live at different widths (sidebar vs. main). Mark the container with cq and use the @sm/@md/@lg/@xl variants, and up to @7xl with taisho generate.

html
<div class="ts cq">
  <div class="ts grid grid-cols-1 @md:grid-cols-3 gap-base">
    … rearranges based on the container's width …
  </div>
</div>

3 · Manual (viewport)

sm:/md:/lg:/xl: viewport prefixes on a curated set of utilities: display, flex direction, grid (grid-cols, col-span…), gap, alignment, and keyword widths. In Core’s plain CSS those variants are already emitted. You write the class and it works, with no build. Outside that set there’s no variant in the static file; with taisho generate and content, any utility comes out with the screen you write. State variants (hover:, focus:…) combine with screen variants (md:hover:). They’re in Variants. With the npm package, any screen variant you write literally comes out the same as with taisho generate.

html
<div class="ts grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-base">
  <div class="ts lg:col-span-2">Spans 2 at lg</div>
  …
</div>

Fluid typography

The heading scales use clamp(). They grow with the viewport between a minimum and a maximum, with no breakpoints. There’s nothing to configure.