Skip to content

Conversation

@luca-rath
Copy link
Contributor

Adds a component which truncates an element's text to the element's height.

Set overflow: hidden and e.g. line-height: 20px and max-height: calc(20px * 3) to the components element to truncate the text of that element to 3 lines.

This component also works with responsive breakpoints.

A custom separator can be defined in the options. e.g. { separator: '!!!' }
A custom debounceDelay for the window resize function can also be set in the options. e.g. { debounceDelay: 500 }

@thomasduenser
Copy link

Code looks good. What about a usage documentation (like the description of this merge request) inside the JS component? I would also prefer comments containing a short description for each method. else ACK

@luca-rath
Copy link
Contributor Author

looks good? @thomasduenser

@thomasduenser
Copy link

@luca-rath ACK

@alexander-schranz alexander-schranz merged commit ef45be5 into sulu:master Nov 6, 2018
@luca-rath luca-rath deleted the patch-2 branch November 6, 2018 09:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants