Sha256: e780dc2ae5d0913966fd8340d0ce214294363d1fa4e034579b32058fa94b2a35

Contents?: true

Size: 1.71 KB

Versions: 21

Compression:

Stored size: 1.71 KB

Contents

// Mixins to support specific CSS Text Level 3 elements

@import "compass/support";

// The the user threshold for hyphens support.
// Defaults to `$graceful-usage-threshold`.
$hyphens-support-threshold: $graceful-usage-threshold !default;


// Mixin for word-break properties
// http://www.w3.org/css3-text/#word-break
// * legal values for $type : normal, keep-all, break-all
//
// Example:
//    p.wordBreak {@include word-break(break-all);}
//
// Which generates:
//    p.wordBreak {
//      word-break: break-all;
//      word-break: break-word;}
//
@mixin word-break($value: normal){
  word-break: $value;
  @if $value == break-all {
    //Webkit handles break-all differently... as break-word
    @include with-prefix(-webkit) {
      word-break: break-word;
    }
  }
}

// Mixin for the hyphens property
//
// W3C specification: http://www.w3.org/TR/css3-text/#hyphens
// * legal values for $type : auto, manual, none
//
// Example:
//  p {
//    @include hyphens(auto);}
// Which generates:
//  p {
//    -moz-hyphens: auto;
//    -webkit-hyphens: auto;
//    hyphens: auto;}
//
@mixin hyphens($value: auto){
  @include prefixed-properties(css-hyphens, $hyphens-support-threshold, (
    hyphens: $value
  ));
}

// Mixin for x-browser hyphenation based on @auchenberg's post:
// Removes the need for the <wbr/> HTML tag
// http://blog.kenneth.io/blog/2012/03/04/word-wrapping-hypernation-using-css/
//
//  Example:
//  div {@include hyphenation;}
//
//  Which generates:
//    div {
//      -ms-word-break: break-all;
//      word-break: break-all;
//      word-break: break-word;
//      -moz-hyphens: auto;
//      -webkit-hyphens: auto;
//      hyphens: auto;}
//
@mixin hyphenation {
  @include word-break(break-all);
  @include hyphens;
}

Version data entries

21 entries across 21 versions & 4 rubygems

Version Path
arcabouco-0.2.13 vendor/bundle/gems/compass-core-1.0.3/stylesheets/compass/css3/_hyphenation.scss
gem_2345-0.1.2 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.3 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.1.0.alpha.3 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.1.0.alpha.2 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.1.0.alpha.1 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.1.0.alpha.0 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.1 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.rc.1 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.rc.0 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.21 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.20 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.19 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.17 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.16 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.15 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.14 stylesheets/compass/css3/_hyphenation.scss
compass-core-1.0.0.alpha.13 stylesheets/compass/css3/_hyphenation.scss
compass-0.13.alpha.12 frameworks/compass/stylesheets/compass/css3/_hyphenation.scss