Skip to content

Commit

Permalink
fix: add ellipses when width is constrained
Browse files Browse the repository at this point in the history
  • Loading branch information
emyarod committed Jan 6, 2020
1 parent 307afc8 commit 6bf731b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/components/src/components/tag/tag.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<div role="list">
{{#if filter}}
<span class="{{@root.prefix}}--tag {{@root.prefix}}--tag--filter" title="Clear filter" role="listitem">
filter
<span class="{{@root.prefix}}--tag__label">filter</span>
<button aria-label='Clear filter' class="{{@root.prefix}}--tag--filter__close-button">
{{ carbon-icon 'Close16' }}
</button>
Expand Down
4 changes: 3 additions & 1 deletion packages/react/src/components/Tag/Tag.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ const Tag = ({
});
return filter ? (
<span className={tagClasses} {...other}>
{children !== null && children !== undefined ? children : TYPES[type]}
<span className={`${prefix}--tag__label`}>
{children !== null && children !== undefined ? children : TYPES[type]}
</span>
<button
aria-label={title || 'Clear filter'}
className={`${prefix}--tag--filter__close-button`}
Expand Down

0 comments on commit 6bf731b

Please sign in to comment.