Propriedade CSS overflow-wrap
Exemplo
Permita que o navegador tenha permissão para quebrar linhas com palavras longas, se elas ultrapassarem o contêiner:
div {
overflow-wrap: break-word;
}
Definição e uso
A overflow-wrap
propriedade especifica se o navegador pode ou não quebrar linhas com palavras longas, se elas estourarem o contêiner.
Valor padrão: | normal |
---|---|
Herdado: | sim |
Animavel: | não. Leia sobre animáveis |
Versão: | CSS3 |
Sintaxe JavaScript: | objeto .style.overflowWrap="normal" |
Suporte ao navegador
Os números na tabela especificam a primeira versão do navegador que oferece suporte total à propriedade.
Property | |||||
---|---|---|---|---|---|
overflow-wrap | 23.0 | 18.0 | 49.0 | 6.1 | 12.1 |
Sintaxe CSS
overflow-wrap: normal|anywhere|break-word|initial|inherit;
Valores de propriedade
Value | Description | Play it |
---|---|---|
normal | Long words will not break, even if they overflow the container. This is default | |
anywhere | Long words will break if they overflow the container | |
break-word | Long words will break if they overflow the container | |
initial | Sets this property to its default value. Read about initial | |
inherit | Inherits this property from its parent element. Read about inherit |
Páginas relacionadas
Tutorial CSS: CSS Overflow