Skip to content

Commit

Permalink
Fix wordWrap: max-width instead of width for HTML element
Browse files Browse the repository at this point in the history
  • Loading branch information
bigtimebuddy committed Nov 4, 2022
1 parent 4b69ca4 commit 0e66d32
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ export class HTMLText extends Sprite
if (style.wordWrap)
{
css += `word-wrap:${style.breakWords ? 'break-all' : 'break-word'};`;
css += `width:${style.wordWrapWidth}px;`;
css += `max-width:${style.wordWrapWidth}px;`;
}

if (style.strokeThickness)
Expand Down

0 comments on commit 0e66d32

Please sign in to comment.