Skip to content

Potential enhancement for line-clamp #9

@mob8607

Description

@mob8607

As we can use lh as height value, we can probably improve the line-clamp mixin.

Needs to be tested in all browsers.

@mixin line-clamp($clamp) {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: $clamp;
  max-height: #{$clamp}lh;
  overflow: hidden;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions