Forum digitalis

2.7 Size and overflow

Introduction

CSS allows you to control element sizes. width and height set fixed dimensions, while min-width/max-width define limits. overflow determines how content outside the container is handled: hidden, auto, or scroll. Text can be wrapped using word-break or overflow-wrap, and text-overflow: ellipsis displays "..." for truncated text.

.box { width: 200px; height: 50px; max-width: 300px; min-width: 100px; overflow: hidden; word-break: break-word; overflow-wrap: break-word; text-overflow: ellipsis; }