Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(label): fix ellipsis was not working #18525

Merged
merged 1 commit into from
Apr 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/label/labelStyle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,7 @@ const TEXT_PROPS_WITH_GLOBAL = [
'textShadowColor', 'textShadowBlur', 'textShadowOffsetX', 'textShadowOffsetY'
] as const;
const TEXT_PROPS_SELF = [
'align', 'lineHeight', 'width', 'height', 'tag', 'verticalAlign'
'align', 'lineHeight', 'width', 'height', 'tag', 'verticalAlign', 'ellipsis'
] as const;
const TEXT_PROPS_BOX = [
'padding', 'borderWidth', 'borderRadius', 'borderDashOffset',
Expand Down
2 changes: 2 additions & 0 deletions src/util/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1056,6 +1056,8 @@ export interface LabelOption extends TextCommonOption {
minMargin?: number

overflow?: TextStyleProps['overflow']
ellipsis?: TextStyleProps['ellipsis']

silent?: boolean
precision?: number | 'auto'
valueAnimation?: boolean
Expand Down
110 changes: 110 additions & 0 deletions test/label-ellipsis.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.