Comments (4)
We'll have to consult with @BrendanMcK and our designers, see which option is preferable.
from yamui.
Even if you were to correctly calculate the height, how would you introduce the ellipsis?
from yamui.
I'm open to suggestions... I imagine we'd want to consult a designer.
Some options:
Maybe an offset one with a pseudo element?
Or maybe we could progressively enhance and use --webkit-line-clamp
for browsers that support it.
Or maybe better would be a fade?
Or this:
https://css-tricks.com/text-fade-read-more/
from yamui.
My understanding is that since the clipping is purely visual, and the DOM still contains all the original text, a screenreader will still read out the full content. That's acceptable in most cases.
OTOH, if the content was significantly larger than the visible portion, we might want to ensure that the screenreader also only reads out text cropped to the same ballpark (ie doesn't need to crop at exact same character, just reads out roughly the same amount).
But if we're confident there won't be more than a few lines here anyhow, that's likely not an issue.
from yamui.
Related Issues (20)
- Visibility Observer Doesn't Work on Edge 15 With Zero Area Element
- Aside Section Visual Diff Test is Flakey HOT 1
- Should all components support aria-hidden?
- Image has zero height when it receives imageFit without a height and width
- Should we replace all Context API usage with selectors in our getClassNames() functions?
- Update ModalDialog component example
- MenuButton shows beak on narrow viewport
- Incorrect Shadow on Dropdown HOT 1
- Text: rename MEDIUM_SUB to SMALL_PLUS to align with Fabric
- Box component should not accept onClick
- Base Component with Styles
- [RTL] Choice group renders incorrectly when right-to-left HOT 1
- ImageFit cover occasionally has extra white space HOT 1
- Create ActionLinkList component to enforce padding of action links in right rail
- Image has no maxWidth constraint HOT 1
- Bullets in layout list need to accept theme
- Support High Contrast Illustrations
- HorizontalActionList has a typo in its folder name
- PreviewCard does not use a fallback thumbnail icon HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yamui.