grid の子要素の幅を fr で指定していると overflow-wrap: break-word; が効かない
#フロントエンド #CSS
html - css grid grows over 100% width with fr but not with minmax - Stack Overflow
code:css
.wrapper {
display: grid;
grid-template-columns: auto 1fr;
}
.inner {
overflow-wrap: break-word; /** はみ出る */
}
code:css
.wrapper {
display: grid;
grid-template-columns: auto minmax(0, 1fr);
}
minmax() - CSS: カスケーディングスタイルシート | MDN
関連: CSS Grid Layoutでwidthを指定してもはみ出て困った - Qiita