CSS Container Query Generator
Generate named or unnamed container styles and min-width queries with three editable breakpoints.
css-container-query-generatorLOCAL WORKSPACE
Enabling local controls…
Settings
Results
CSS
.query-container {
container-type: inline-size;
container-name: card;
}
/* 400px */
@container card (min-width: 400px) {
.card{flex-direction:row}
}
/* 700px */
@container card (min-width: 700px) {
.card{flex-direction:row}
}
/* 1000px */
@container card (min-width: 1000px) {
.card{flex-direction:row}
}How to use this tool
Choose a preset or edit the controls. Copy the result or download it when it is ready.
When not to use it
Set up the container selector on a parent of the elements you style. normal only generates container setup.