|
7 | 7 | * 1) Prevent Mobile Safari from scaling up text: https://blog.55minutes.com/2012/04/iphone-text-resizing/ |
8 | 8 | */ |
9 | 9 | @mixin typographyBody() { |
10 | | - font-family: $font-primary; |
11 | | - font-size: $font-size-med-2; |
12 | | - font-weight: 500; |
13 | | - line-height: 1.6; |
14 | | - -webkit-text-size-adjust: 100%; /* 1 */ |
| 10 | + font-family: $font-primary; |
| 11 | + font-size: $font-size-med-2; |
| 12 | + font-weight: 500; |
| 13 | + line-height: 1.6; |
| 14 | + -webkit-text-size-adjust: 100%; /* 1 */ |
15 | 15 | } |
16 | 16 |
|
17 | 17 | /** |
18 | 18 | * XL Type Styles |
19 | 19 | */ |
20 | 20 | @mixin typographyBodyLarge() { |
21 | | - font-size: $font-size-med-2; |
22 | | - line-height: $line-height-large; |
| 21 | + font-size: $font-size-med-2; |
| 22 | + line-height: $line-height-large; |
23 | 23 | } |
24 | 24 |
|
25 | 25 | /** |
26 | 26 | * XL Heading Styles |
27 | 27 | */ |
28 | 28 | @mixin typographyHeadingXl() { |
29 | | - font-weight: $font-weight-bold; |
30 | | - font-size: $font-size-large-2; |
31 | | - line-height: $line-height-med-2; |
| 29 | + font-weight: $font-weight-bold; |
| 30 | + font-size: $font-size-large-2; |
| 31 | + line-height: $line-height-med-2; |
32 | 32 |
|
33 | | - @media all and (min-width: $bp-med) { |
34 | | - font-size: $font-size-xl; |
35 | | - } |
| 33 | + @media all and (min-width: $bp-med) { |
| 34 | + font-size: $font-size-xl; |
| 35 | + } |
36 | 36 | } |
37 | 37 |
|
38 | 38 | /** |
39 | 39 | * Large Heading Styles |
40 | 40 | */ |
41 | 41 | @mixin typographyHeadingLarge() { |
42 | | - font-size: $font-size-large; |
43 | | - font-weight: 700; |
44 | | - line-height: 1.6; |
| 42 | + font-size: $font-size-large; |
| 43 | + font-weight: 700; |
| 44 | + line-height: 1.6; |
45 | 45 | } |
46 | 46 |
|
47 | 47 | /** |
48 | 48 | * Medium 2 Heading Styles |
49 | 49 | */ |
50 | 50 | @mixin typographyHeadingMed2() { |
51 | | - font-size: $font-size-med-2; |
52 | | - font-weight: 700; |
53 | | - line-height: 1.2; |
| 51 | + font-size: $font-size-med-2; |
| 52 | + font-weight: 700; |
| 53 | + line-height: 1.2; |
54 | 54 | } |
55 | 55 |
|
56 | 56 | /** |
57 | 57 | * Medium Heading Styles |
58 | 58 | */ |
59 | 59 | @mixin typographyHeadingMed() { |
60 | | - font-size: $font-size-med; |
61 | | - font-weight: 700; |
62 | | - line-height: 1.2; |
| 60 | + font-size: $font-size-med; |
| 61 | + font-weight: 700; |
| 62 | + line-height: 1.2; |
63 | 63 | } |
64 | 64 |
|
65 | 65 | /*------------------------------------*\ |
66 | 66 | #FOCUS |
67 | 67 | \*------------------------------------*/ |
68 | 68 |
|
69 | 69 | @mixin focus() { |
70 | | - outline: 2px dotted $color-black; |
71 | | - outline-offset: 4px; |
| 70 | + outline: 2px dotted $color-black; |
| 71 | + outline-offset: 4px; |
72 | 72 | } |
73 | 73 |
|
74 | 74 | @mixin focusInverted() { |
75 | | - outline: 1px dotted $color-white; |
76 | | - outline-offset: 4px; |
| 75 | + outline: 1px dotted $color-white; |
| 76 | + outline-offset: 4px; |
77 | 77 | } |
78 | 78 |
|
79 | 79 | /*------------------------------------*\ |
80 | 80 | #DECORATIVE |
81 | 81 | \*------------------------------------*/ |
82 | 82 |
|
83 | | -@mixin highlightEffect() { |
84 | | - box-shadow: 20px 0 0 $color-white, -20px 0 0 $color-white; |
| 83 | +@mixin textShadowEffect() { |
| 84 | + position: relative; |
| 85 | + z-index: 1; |
| 86 | + |
| 87 | + &:after { |
| 88 | + position: absolute; |
| 89 | + left: 4px; |
| 90 | + top: 4px; |
| 91 | + z-index: 0; |
| 92 | + content: attr(data-text); |
| 93 | + |
| 94 | + background-image: radial-gradient( |
| 95 | + $color-brand-purple 0%, |
| 96 | + $color-brand-purple 60%, |
| 97 | + transparent 60% |
| 98 | + ); |
| 99 | + background-size: 4px 4px; |
| 100 | + -webkit-background-clip: text; |
| 101 | + -webkit-text-fill-color: transparent; |
| 102 | + z-index: -5; |
| 103 | + display: block; |
| 104 | + text-shadow: none; |
| 105 | + } |
| 106 | +} |
| 107 | + |
| 108 | +@mixin boxShadowEffect($color: 'green') { |
| 109 | + @if $color == 'green' { |
| 110 | + box-shadow: 6px 6px 0 $color-brand-green, 12px 12px 0 $color-brand-green-transparent; |
| 111 | + } |
| 112 | + @elseif $color == 'orange' { |
| 113 | + box-shadow: 6px 6px 0 $color-brand-orange, 12px 12px 0 $color-brand-orange-transparent; |
| 114 | + } @else { |
| 115 | + box-shadow: 6px 6px 0 $color-brand-purple, 12px 12px 0 $color-brand-purple-transparent; |
| 116 | + } |
85 | 117 | } |
0 commit comments