Version Description
- fixed load order of views so files inside of the child theme have priority over the parent theme.
- comment ordering respects the default set in WordPress
- added getting started screen
- misc bug fixes
- removed lots of old garbage, simplified file organization
- contributors for this release: @ysurian, @thisislawatts, @punkshui and @paulwilde
Download this release
Release Info
Developer | jarednova |
Plugin | Timber |
Version | 0.11.0 |
Comparing to | |
See all releases |
Code changes from version 0.10.7 to 0.11.0
- README.md +2 -2
- admin/.sass-cache/0c6da0fedfe6ba00ac91e45612eb724ccf05f95f/_hacks.scssc +0 -0
- admin/.sass-cache/257118799312f10d0785641acb3d0af4165868eb/_base.scssc +0 -0
- admin/.sass-cache/35163ebe99a359972ff8921fd495a4d31ad0e65d/_css3.scssc +0 -0
- admin/.sass-cache/35163ebe99a359972ff8921fd495a4d31ad0e65d/_support.scssc +0 -0
- admin/.sass-cache/8a7a56067d1b0d09ae370ff5b2b0c74f7ff7d072/timber-admin.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_appearance.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_background-clip.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_background-origin.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_background-size.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_border-radius.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_box-shadow.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_box-sizing.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_box.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_columns.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_filter.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_font-face.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_hyphenation.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_images.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_inline-block.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_opacity.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_regions.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_shared.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_text-shadow.scssc +0 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_transform.scssc +1415 -0
- admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_transition.scssc +486 -0
- admin/.sass-cache/f3a328c66776df8ae0a66eaf4e5122387c195ad0/_mixins.scssc +1094 -0
- admin/config.rb +15 -0
- {images → admin/images}/logo/timber-badge-large.jpg +0 -0
- {images → admin/images}/logo/timber-badge.jpg +0 -0
- {images → admin/images}/logo/timber.jpg +0 -0
- admin/partials/_base.scss +55 -0
- admin/partials/_layout.scss +262 -0
- admin/partials/_mixins.scss +429 -0
- admin/partials/_normalize.scss +249 -0
- admin/partials/_reset.scss +215 -0
- admin/timber-admin.css +1 -23
- admin/timber-admin.php +52 -32
- admin/timber-admin.scss +116 -0
- admin/timber-admin.twig +44 -15
- functions/functions-php-helper.php +0 -85
- functions/functions-post-master.php +0 -298
- functions/functions-twig.php +326 -345
- functions/functions-word-query.php +35 -35
- functions/functions-wp-helper.php +358 -419
- functions/functions-wp-image-helper.php +30 -0
- {objects → functions}/timber-comment.php +0 -0
- functions/timber-core.php +37 -0
- functions/timber-image.php +104 -0
- functions/timber-loader.php +130 -0
- {objects → functions}/timber-menu.php +0 -0
- {objects → functions}/timber-page.php +0 -4
- functions/timber-post.php +460 -0
- functions/timber-term-getter.php +82 -0
- functions/timber-term.php +143 -0
- {objects → functions}/timber-user.php +0 -0
- objects/timber-core.php +0 -41
- objects/timber-image.php +0 -115
- objects/timber-loader.php +0 -142
- objects/timber-post.php +0 -505
- objects/timber-term-getter.php +0 -82
- objects/timber-term.php +0 -151
- readme.txt +17 -4
- timber-starter-theme/screenshot.png +0 -0
- timber.php +17 -14
README.md
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
<div style="text-align:center">
|
2 |
-
<a href="http://jarednova.github.com/timber"><img src="https://github.com/jarednova/timber/blob/master/images/logo/timber-badge-large.jpg?raw=true" style="display:block; margin:auto;"/></a>
|
3 |
<div>
|
4 |
By Jared Novack (<a href="http://twitter.com/jarednova">@JaredNova</a>) and <a href="http://upstatement.com">Upstatement</a> (<a href="http://twitter.com/upstatement">@Upstatement</a>)</div>
|
5 |
</div>
|
@@ -28,7 +28,7 @@ Once Timber is installed and activated in your plugin directory, it gives any Wo
|
|
28 |
|
29 |
### Looking for docs?
|
30 |
* [Timber Documentation](https://github.com/jarednova/timber/wiki/)
|
31 |
-
* [Twig Reference](http://twig.sensiolabs.org/
|
32 |
* **[Video Tutorials](https://github.com/jarednova/timber/wiki/Video-Tutorials)**
|
33 |
* [Overview / Getting Started Guide](https://github.com/jarednova/timber/wiki/getting-started)
|
34 |
|
1 |
<div style="text-align:center">
|
2 |
+
<a href="http://jarednova.github.com/timber"><img src="https://github.com/jarednova/timber/blob/master/admin/images/logo/timber-badge-large.jpg?raw=true" style="display:block; margin:auto;"/></a>
|
3 |
<div>
|
4 |
By Jared Novack (<a href="http://twitter.com/jarednova">@JaredNova</a>) and <a href="http://upstatement.com">Upstatement</a> (<a href="http://twitter.com/upstatement">@Upstatement</a>)</div>
|
5 |
</div>
|
28 |
|
29 |
### Looking for docs?
|
30 |
* [Timber Documentation](https://github.com/jarednova/timber/wiki/)
|
31 |
+
* [Twig Reference](http://twig.sensiolabs.org/doc/templates.html)
|
32 |
* **[Video Tutorials](https://github.com/jarednova/timber/wiki/Video-Tutorials)**
|
33 |
* [Overview / Getting Started Guide](https://github.com/jarednova/timber/wiki/getting-started)
|
34 |
|
admin/.sass-cache/0c6da0fedfe6ba00ac91e45612eb724ccf05f95f/_hacks.scssc
ADDED
Binary file
|
admin/.sass-cache/257118799312f10d0785641acb3d0af4165868eb/_base.scssc
ADDED
Binary file
|
admin/.sass-cache/35163ebe99a359972ff8921fd495a4d31ad0e65d/_css3.scssc
ADDED
Binary file
|
admin/.sass-cache/35163ebe99a359972ff8921fd495a4d31ad0e65d/_support.scssc
ADDED
Binary file
|
admin/.sass-cache/8a7a56067d1b0d09ae370ff5b2b0c74f7ff7d072/timber-admin.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_appearance.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_background-clip.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_background-origin.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_background-size.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_border-radius.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_box-shadow.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_box-sizing.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_box.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_columns.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_filter.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_font-face.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_hyphenation.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_images.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_inline-block.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_opacity.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_regions.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_shared.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_text-shadow.scssc
ADDED
Binary file
|
admin/.sass-cache/b2291351f6f4358d516fffa26e4a5a4df0f9907c/_transform.scssc
ADDED
@@ -0,0 +1,1415 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
3.2.7 (Media Mark)
|
2 |
+
c6b1622193f2b16b41d0238260d902d3a3b29ac0
|
3 |
+
o:Sass::Tree::RootNode
|
4 |
+
:@template"�H@import "shared";
|
5 |
+
|
6 |
+
// @doc off
|
7 |
+
// Note ----------------------------------------------------------------------
|
8 |
+
// Safari, Chrome, and Firefox all support 3D transforms. However,
|
9 |
+
// only in the most recent builds. You should also provide fallback 2d support for
|
10 |
+
// Opera and IE. IE10 is slated to have 3d enabled, but is currently unreleased.
|
11 |
+
// To make that easy, all 2D transforms include an browser-targeting toggle ($only3d)
|
12 |
+
// to switch between the two support lists. The toggle defaults to 'false' (2D),
|
13 |
+
// and also accepts 'true' (3D). Currently the lists are as follows:
|
14 |
+
// 2D: Mozilla, Webkit, Opera, Official
|
15 |
+
// 3D: Webkit, Firefox.
|
16 |
+
|
17 |
+
// Available Transforms ------------------------------------------------------
|
18 |
+
// - Scale (2d and 3d)
|
19 |
+
// - Rotate (2d and 3d)
|
20 |
+
// - Translate (2d and 3d)
|
21 |
+
// - Skew (2d only)
|
22 |
+
|
23 |
+
// Transform Parameters ------------------------------------------------------
|
24 |
+
// - Transform Origin (2d and 3d)
|
25 |
+
// - Perspective (3d)
|
26 |
+
// - Perspective Origin (3d)
|
27 |
+
// - Transform Style (3d)
|
28 |
+
// - Backface Visibility (3d)
|
29 |
+
|
30 |
+
// Mixins --------------------------------------------------------------------
|
31 |
+
// transform-origin
|
32 |
+
// - shortcuts: transform-origin2d, transform-origin3d
|
33 |
+
// - helpers: apply-origin
|
34 |
+
// transform
|
35 |
+
// - shortcuts: transform2d, transform3d
|
36 |
+
// - helpers: simple-transform, create-transform
|
37 |
+
// perspective
|
38 |
+
// - helpers: perspective-origin
|
39 |
+
// transform-style
|
40 |
+
// backface-visibility
|
41 |
+
// scale
|
42 |
+
// - shortcuts: scaleX, scaleY, scaleZ, scale3d
|
43 |
+
// rotate
|
44 |
+
// - shortcuts: rotateX, rotateY, rotate3d
|
45 |
+
// translate
|
46 |
+
// - shortcuts: translateX, translateY, translateZ, translate3d
|
47 |
+
// skew
|
48 |
+
// - shortcuts: skewX, skewY
|
49 |
+
|
50 |
+
// Defaults ------------------------------------------------------------------
|
51 |
+
// @doc on
|
52 |
+
|
53 |
+
// The default x-origin for transforms
|
54 |
+
$default-origin-x : 50% !default;
|
55 |
+
// The default y-origin for transforms
|
56 |
+
$default-origin-y : 50% !default;
|
57 |
+
// The default z-origin for transforms
|
58 |
+
$default-origin-z : 50% !default;
|
59 |
+
|
60 |
+
|
61 |
+
// The default x-multiplier for scaling
|
62 |
+
$default-scale-x : 1.25 !default;
|
63 |
+
// The default y-multiplier for scaling
|
64 |
+
$default-scale-y : $default-scale-x !default;
|
65 |
+
// The default z-multiplier for scaling
|
66 |
+
$default-scale-z : $default-scale-x !default;
|
67 |
+
|
68 |
+
|
69 |
+
// The default angle for rotations
|
70 |
+
$default-rotate : 45deg !default;
|
71 |
+
|
72 |
+
|
73 |
+
// The default x-vector for the axis of 3d rotations
|
74 |
+
$default-vector-x : 1 !default;
|
75 |
+
// The default y-vector for the axis of 3d rotations
|
76 |
+
$default-vector-y : 1 !default;
|
77 |
+
// The default z-vector for the axis of 3d rotations
|
78 |
+
$default-vector-z : 1 !default;
|
79 |
+
|
80 |
+
|
81 |
+
// The default x-length for translations
|
82 |
+
$default-translate-x : 1em !default;
|
83 |
+
// The default y-length for translations
|
84 |
+
$default-translate-y : $default-translate-x !default;
|
85 |
+
// The default z-length for translations
|
86 |
+
$default-translate-z : $default-translate-x !default;
|
87 |
+
|
88 |
+
|
89 |
+
// The default x-angle for skewing
|
90 |
+
$default-skew-x : 5deg !default;
|
91 |
+
// The default y-angle for skewing
|
92 |
+
$default-skew-y : 5deg !default;
|
93 |
+
|
94 |
+
|
95 |
+
// **Transform-origin**
|
96 |
+
// Transform-origin sent as a complete string
|
97 |
+
//
|
98 |
+
// @include apply-origin( origin [, 3D-only ] )
|
99 |
+
//
|
100 |
+
// where 'origin' is a space separated list containing 1-3 (x/y/z) coordinates
|
101 |
+
// in percentages, absolute (px, cm, in, em etc..) or relative
|
102 |
+
// (left, top, right, bottom, center) units
|
103 |
+
//
|
104 |
+
// @param only3d Set this to true to only apply this
|
105 |
+
// mixin where browsers have 3D support.
|
106 |
+
@mixin apply-origin($origin, $only3d) {
|
107 |
+
$only3d: $only3d or -compass-list-size(-compass-list($origin)) > 2;
|
108 |
+
@if $only3d {
|
109 |
+
@include experimental(transform-origin, $origin,
|
110 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
111 |
+
);
|
112 |
+
} @else {
|
113 |
+
@include experimental(transform-origin, $origin,
|
114 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
115 |
+
);
|
116 |
+
}
|
117 |
+
}
|
118 |
+
|
119 |
+
// Transform-origin sent as individual arguments:
|
120 |
+
//
|
121 |
+
// @include transform-origin( [ origin-x, origin-y, origin-z, 3D-only ] )
|
122 |
+
//
|
123 |
+
// where the 3 'origin-' arguments represent x/y/z coordinates.
|
124 |
+
//
|
125 |
+
// **NOTE:** setting z coordinates triggers 3D support list, leave false for 2D support
|
126 |
+
@mixin transform-origin(
|
127 |
+
$origin-x: $default-origin-x,
|
128 |
+
$origin-y: $default-origin-y,
|
129 |
+
$origin-z: false,
|
130 |
+
$only3d: if($origin-z, true, false)
|
131 |
+
) {
|
132 |
+
$origin: unquote('');
|
133 |
+
@if $origin-x or $origin-y or $origin-z {
|
134 |
+
@if $origin-x { $origin: $origin-x; } @else { $origin: 50%; }
|
135 |
+
@if $origin-y { $origin: $origin $origin-y; } @else { @if $origin-z { $origin: $origin 50%; }}
|
136 |
+
@if $origin-z { $origin: $origin $origin-z; }
|
137 |
+
@include apply-origin($origin, $only3d);
|
138 |
+
}
|
139 |
+
}
|
140 |
+
|
141 |
+
|
142 |
+
// Transform sent as a complete string:
|
143 |
+
//
|
144 |
+
// @include transform( transforms [, 3D-only ] )
|
145 |
+
//
|
146 |
+
// where 'transforms' is a space separated list of all the transforms to be applied.
|
147 |
+
@mixin transform(
|
148 |
+
$transform,
|
149 |
+
$only3d: false
|
150 |
+
) {
|
151 |
+
@if $only3d {
|
152 |
+
@include experimental(transform, $transform,
|
153 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
154 |
+
);
|
155 |
+
} @else {
|
156 |
+
@include experimental(transform, $transform,
|
157 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
158 |
+
);
|
159 |
+
}
|
160 |
+
}
|
161 |
+
|
162 |
+
// Shortcut to target all browsers with 2D transform support
|
163 |
+
@mixin transform2d($trans) {
|
164 |
+
@include transform($trans, false);
|
165 |
+
}
|
166 |
+
|
167 |
+
// Shortcut to target only browsers with 3D transform support
|
168 |
+
@mixin transform3d($trans) {
|
169 |
+
@include transform($trans, true);
|
170 |
+
}
|
171 |
+
|
172 |
+
// @doc off
|
173 |
+
// 3D Parameters -------------------------------------------------------------
|
174 |
+
// @doc on
|
175 |
+
|
176 |
+
// Set the perspective of 3D transforms on the children of an element:
|
177 |
+
//
|
178 |
+
// @include perspective( perspective )
|
179 |
+
//
|
180 |
+
// where 'perspective' is a unitless number representing the depth of the
|
181 |
+
// z-axis. The higher the perspective, the more exaggerated the foreshortening.
|
182 |
+
// values from 500 to 1000 are more-or-less "normal" - a good starting-point.
|
183 |
+
@mixin perspective($p) {
|
184 |
+
@include experimental(perspective, $p,
|
185 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
186 |
+
);
|
187 |
+
}
|
188 |
+
|
189 |
+
// Set the origin position for the perspective
|
190 |
+
//
|
191 |
+
// @include perspective-origin(origin-x [origin-y])
|
192 |
+
//
|
193 |
+
// where the two arguments represent x/y coordinates
|
194 |
+
@mixin perspective-origin($origin: 50%) {
|
195 |
+
@include experimental(perspective-origin, $origin,
|
196 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
197 |
+
);
|
198 |
+
}
|
199 |
+
|
200 |
+
// Determine whether a 3D objects children also live in the given 3D space
|
201 |
+
//
|
202 |
+
// @include transform-style( [ style ] )
|
203 |
+
//
|
204 |
+
// where `style` can be either `flat` or `preserve-3d`.
|
205 |
+
// Browsers default to `flat`, mixin defaults to `preserve-3d`.
|
206 |
+
@mixin transform-style($style: preserve-3d) {
|
207 |
+
@include experimental(transform-style, $style,
|
208 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
209 |
+
);
|
210 |
+
}
|
211 |
+
|
212 |
+
// Determine the visibility of an element when it's back is turned
|
213 |
+
//
|
214 |
+
// @include backface-visibility( [ visibility ] )
|
215 |
+
//
|
216 |
+
// where `visibility` can be either `visible` or `hidden`.
|
217 |
+
// Browsers default to visible, mixin defaults to hidden
|
218 |
+
@mixin backface-visibility($visibility: hidden) {
|
219 |
+
@include experimental(backface-visibility, $visibility,
|
220 |
+
-moz, -webkit, -o, -ms, not -khtml, official
|
221 |
+
);
|
222 |
+
}
|
223 |
+
|
224 |
+
// @doc off
|
225 |
+
// Transform Partials --------------------------------------------------------
|
226 |
+
// These work well on their own, but they don't add to each other, they override.
|
227 |
+
// Use along with transform parameter mixins to adjust origin, perspective and style
|
228 |
+
// ---------------------------------------------------------------------------
|
229 |
+
|
230 |
+
|
231 |
+
// Scale ---------------------------------------------------------------------
|
232 |
+
// @doc on
|
233 |
+
|
234 |
+
// Scale an object along the x and y axis:
|
235 |
+
//
|
236 |
+
// @include scale( [ scale-x, scale-y, perspective, 3D-only ] )
|
237 |
+
//
|
238 |
+
// where the 'scale-' arguments are unitless multipliers of the x and y dimensions
|
239 |
+
// and perspective, which works the same as the stand-alone perspective property/mixin
|
240 |
+
// but applies to the individual element (multiplied with any parent perspective)
|
241 |
+
//
|
242 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
243 |
+
@mixin scale(
|
244 |
+
$scale-x: $default-scale-x,
|
245 |
+
$scale-y: $scale-x,
|
246 |
+
$perspective: false,
|
247 |
+
$only3d: false
|
248 |
+
) {
|
249 |
+
$trans: scale($scale-x, $scale-y);
|
250 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
251 |
+
@include transform($trans, $only3d);
|
252 |
+
}
|
253 |
+
|
254 |
+
// Scale an object along the x axis
|
255 |
+
// @include scaleX( [ scale-x, perspective, 3D-only ] )
|
256 |
+
//
|
257 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
258 |
+
@mixin scaleX(
|
259 |
+
$scale: $default-scale-x,
|
260 |
+
$perspective: false,
|
261 |
+
$only3d: false
|
262 |
+
) {
|
263 |
+
$trans: scaleX($scale);
|
264 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
265 |
+
@include transform($trans, $only3d);
|
266 |
+
}
|
267 |
+
|
268 |
+
// Scale an object along the y axis
|
269 |
+
// @include scaleY( [ scale-y, perspective, 3D-only ] )
|
270 |
+
//
|
271 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
272 |
+
@mixin scaleY(
|
273 |
+
$scale: $default-scale-y,
|
274 |
+
$perspective: false,
|
275 |
+
$only3d: false
|
276 |
+
) {
|
277 |
+
$trans: scaleY($scale);
|
278 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
279 |
+
@include transform($trans, $only3d);
|
280 |
+
}
|
281 |
+
|
282 |
+
// Scale an object along the z axis
|
283 |
+
// @include scaleZ( [ scale-z, perspective ] )
|
284 |
+
//
|
285 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
286 |
+
@mixin scaleZ(
|
287 |
+
$scale: $default-scale-z,
|
288 |
+
$perspective: false
|
289 |
+
) {
|
290 |
+
$trans: scaleZ($scale);
|
291 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
292 |
+
@include transform3d($trans);
|
293 |
+
}
|
294 |
+
|
295 |
+
// Scale and object along all three axis
|
296 |
+
// @include scale3d( [ scale-x, scale-y, scale-z, perspective ] )
|
297 |
+
//
|
298 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
299 |
+
@mixin scale3d(
|
300 |
+
$scale-x: $default-scale-x,
|
301 |
+
$scale-y: $default-scale-y,
|
302 |
+
$scale-z: $default-scale-z,
|
303 |
+
$perspective: false
|
304 |
+
) {
|
305 |
+
$trans: scale3d($scale-x, $scale-y, $scale-z);
|
306 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
307 |
+
@include transform3d($trans);
|
308 |
+
}
|
309 |
+
|
310 |
+
// @doc off
|
311 |
+
// Rotate --------------------------------------------------------------------
|
312 |
+
// @doc on
|
313 |
+
|
314 |
+
// Rotate an object around the z axis (2D)
|
315 |
+
// @include rotate( [ rotation, perspective, 3D-only ] )
|
316 |
+
// where 'rotation' is an angle set in degrees (deg) or radian (rad) units
|
317 |
+
//
|
318 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
319 |
+
@mixin rotate(
|
320 |
+
$rotate: $default-rotate,
|
321 |
+
$perspective: false,
|
322 |
+
$only3d: false
|
323 |
+
) {
|
324 |
+
$trans: rotate($rotate);
|
325 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
326 |
+
@include transform($trans, $only3d);
|
327 |
+
}
|
328 |
+
|
329 |
+
// A longcut for 'rotate' in case you forget that 'z' is implied
|
330 |
+
//
|
331 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
332 |
+
@mixin rotateZ(
|
333 |
+
$rotate: $default-rotate,
|
334 |
+
$perspective: false,
|
335 |
+
$only3d: false
|
336 |
+
) {
|
337 |
+
@include rotate($rotate, $perspective, $only3d);
|
338 |
+
}
|
339 |
+
|
340 |
+
// Rotate an object around the x axis (3D)
|
341 |
+
// @include rotateX( [ rotation, perspective ] )
|
342 |
+
//
|
343 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
344 |
+
@mixin rotateX(
|
345 |
+
$rotate: $default-rotate,
|
346 |
+
$perspective: false
|
347 |
+
) {
|
348 |
+
$trans: rotateX($rotate);
|
349 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
350 |
+
@include transform3d($trans);
|
351 |
+
}
|
352 |
+
|
353 |
+
// Rotate an object around the y axis (3D)
|
354 |
+
// @include rotate( [ rotation, perspective ] )
|
355 |
+
//
|
356 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
357 |
+
@mixin rotateY(
|
358 |
+
$rotate: $default-rotate,
|
359 |
+
$perspective: false
|
360 |
+
) {
|
361 |
+
$trans: rotateY($rotate);
|
362 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
363 |
+
@include transform3d($trans);
|
364 |
+
}
|
365 |
+
|
366 |
+
// Rotate an object around an arbitrary axis (3D)
|
367 |
+
// @include rotate( [ vector-x, vector-y, vector-z, rotation, perspective ] )
|
368 |
+
// where the 'vector-' arguments accept unitless numbers.
|
369 |
+
// These numbers are not important on their own, but in relation to one another
|
370 |
+
// creating an axis from your transform-origin, along the axis of Xx = Yy = Zz.
|
371 |
+
//
|
372 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
373 |
+
@mixin rotate3d(
|
374 |
+
$vector-x: $default-vector-x,
|
375 |
+
$vector-y: $default-vector-y,
|
376 |
+
$vector-z: $default-vector-z,
|
377 |
+
$rotate: $default-rotate,
|
378 |
+
$perspective: false
|
379 |
+
) {
|
380 |
+
$trans: rotate3d($vector-x, $vector-y, $vector-z, $rotate);
|
381 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
382 |
+
@include transform3d($trans);
|
383 |
+
}
|
384 |
+
|
385 |
+
// @doc off
|
386 |
+
// Translate -----------------------------------------------------------------
|
387 |
+
// @doc on
|
388 |
+
|
389 |
+
// Move an object along the x or y axis (2D)
|
390 |
+
// @include translate( [ translate-x, translate-y, perspective, 3D-only ] )
|
391 |
+
// where the 'translate-' arguments accept any distance in percentages or absolute (px, cm, in, em etc..) units.
|
392 |
+
//
|
393 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
394 |
+
@mixin translate(
|
395 |
+
$translate-x: $default-translate-x,
|
396 |
+
$translate-y: $default-translate-y,
|
397 |
+
$perspective: false,
|
398 |
+
$only3d: false
|
399 |
+
) {
|
400 |
+
$trans: translate($translate-x, $translate-y);
|
401 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
402 |
+
@include transform($trans, $only3d);
|
403 |
+
}
|
404 |
+
|
405 |
+
// Move an object along the x axis (2D)
|
406 |
+
// @include translate( [ translate-x, perspective, 3D-only ] )
|
407 |
+
//
|
408 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
409 |
+
@mixin translateX(
|
410 |
+
$trans-x: $default-translate-x,
|
411 |
+
$perspective: false,
|
412 |
+
$only3d: false
|
413 |
+
) {
|
414 |
+
$trans: translateX($trans-x);
|
415 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
416 |
+
@include transform($trans, $only3d);
|
417 |
+
}
|
418 |
+
|
419 |
+
// Move an object along the y axis (2D)
|
420 |
+
// @include translate( [ translate-y, perspective, 3D-only ] )
|
421 |
+
//
|
422 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
423 |
+
@mixin translateY(
|
424 |
+
$trans-y: $default-translate-y,
|
425 |
+
$perspective: false,
|
426 |
+
$only3d: false
|
427 |
+
) {
|
428 |
+
$trans: translateY($trans-y);
|
429 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
430 |
+
@include transform($trans, $only3d);
|
431 |
+
}
|
432 |
+
|
433 |
+
// Move an object along the z axis (3D)
|
434 |
+
// @include translate( [ translate-z, perspective ] )
|
435 |
+
//
|
436 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
437 |
+
@mixin translateZ(
|
438 |
+
$trans-z: $default-translate-z,
|
439 |
+
$perspective: false
|
440 |
+
) {
|
441 |
+
$trans: translateZ($trans-z);
|
442 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
443 |
+
@include transform3d($trans);
|
444 |
+
}
|
445 |
+
|
446 |
+
// Move an object along the x, y and z axis (3D)
|
447 |
+
// @include translate( [ translate-x, translate-y, translate-z, perspective ] )
|
448 |
+
//
|
449 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
450 |
+
@mixin translate3d(
|
451 |
+
$translate-x: $default-translate-x,
|
452 |
+
$translate-y: $default-translate-y,
|
453 |
+
$translate-z: $default-translate-z,
|
454 |
+
$perspective: false
|
455 |
+
) {
|
456 |
+
$trans: translate3d($translate-x, $translate-y, $translate-z);
|
457 |
+
@if $perspective { $trans: perspective($perspective) $trans; }
|
458 |
+
@include transform3d($trans);
|
459 |
+
}
|
460 |
+
|
461 |
+
// @doc off
|
462 |
+
// Skew ----------------------------------------------------------------------
|
463 |
+
// @doc on
|
464 |
+
|
465 |
+
// Skew an element:
|
466 |
+
//
|
467 |
+
// @include skew( [ skew-x, skew-y, 3D-only ] )
|
468 |
+
//
|
469 |
+
// where the 'skew-' arguments accept css angles in degrees (deg) or radian (rad) units.
|
470 |
+
//
|
471 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
472 |
+
@mixin skew(
|
473 |
+
$skew-x: $default-skew-x,
|
474 |
+
$skew-y: $default-skew-y,
|
475 |
+
$only3d: false
|
476 |
+
) {
|
477 |
+
$trans: skew($skew-x, $skew-y);
|
478 |
+
@include transform($trans, $only3d);
|
479 |
+
}
|
480 |
+
|
481 |
+
// Skew an element along the x axiz
|
482 |
+
//
|
483 |
+
// @include skew( [ skew-x, 3D-only ] )
|
484 |
+
//
|
485 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
486 |
+
@mixin skewX(
|
487 |
+
$skew-x: $default-skew-x,
|
488 |
+
$only3d: false
|
489 |
+
) {
|
490 |
+
$trans: skewX($skew-x);
|
491 |
+
@include transform($trans, $only3d);
|
492 |
+
}
|
493 |
+
|
494 |
+
// Skew an element along the y axis
|
495 |
+
//
|
496 |
+
// @include skew( [ skew-y, 3D-only ] )
|
497 |
+
//
|
498 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
499 |
+
@mixin skewY(
|
500 |
+
$skew-y: $default-skew-y,
|
501 |
+
$only3d: false
|
502 |
+
) {
|
503 |
+
$trans: skewY($skew-y);
|
504 |
+
@include transform($trans, $only3d);
|
505 |
+
}
|
506 |
+
|
507 |
+
|
508 |
+
// Full transform mixins
|
509 |
+
// For settings any combination of transforms as arguments
|
510 |
+
// These are complex and not highly recommended for daily use. They are mainly
|
511 |
+
// here for backward-compatibility purposes.
|
512 |
+
//
|
513 |
+
// * they include origin adjustments
|
514 |
+
// * scale takes a multiplier (unitless), rotate and skew take degrees (deg)
|
515 |
+
//
|
516 |
+
// **Note** This mixin cannot be combined with other transform mixins.
|
517 |
+
@mixin create-transform(
|
518 |
+
$perspective: false,
|
519 |
+
$scale-x: false,
|
520 |
+
$scale-y: false,
|
521 |
+
$scale-z: false,
|
522 |
+
$rotate-x: false,
|
523 |
+
$rotate-y: false,
|
524 |
+
$rotate-z: false,
|
525 |
+
$rotate3d: false,
|
526 |
+
$trans-x: false,
|
527 |
+
$trans-y: false,
|
528 |
+
$trans-z: false,
|
529 |
+
$skew-x: false,
|
530 |
+
$skew-y: false,
|
531 |
+
$origin-x: false,
|
532 |
+
$origin-y: false,
|
533 |
+
$origin-z: false,
|
534 |
+
$only3d: false
|
535 |
+
) {
|
536 |
+
$trans: unquote("");
|
537 |
+
|
538 |
+
// perspective
|
539 |
+
@if $perspective { $trans: perspective($perspective) ; }
|
540 |
+
|
541 |
+
// scale
|
542 |
+
@if $scale-x and $scale-y {
|
543 |
+
@if $scale-z { $trans: $trans scale3d($scale-x, $scale-y, $scale-z); }
|
544 |
+
@else { $trans: $trans scale($scale-x, $scale-y); }
|
545 |
+
} @else {
|
546 |
+
@if $scale-x { $trans: $trans scaleX($scale-x); }
|
547 |
+
@if $scale-y { $trans: $trans scaleY($scale-y); }
|
548 |
+
@if $scale-z { $trans: $trans scaleZ($scale-z); }
|
549 |
+
}
|
550 |
+
|
551 |
+
// rotate
|
552 |
+
@if $rotate-x { $trans: $trans rotateX($rotate-x); }
|
553 |
+
@if $rotate-y { $trans: $trans rotateY($rotate-y); }
|
554 |
+
@if $rotate-z { $trans: $trans rotateZ($rotate-z); }
|
555 |
+
@if $rotate3d { $trans: $trans rotate3d($rotate3d); }
|
556 |
+
|
557 |
+
// translate
|
558 |
+
@if $trans-x and $trans-y {
|
559 |
+
@if $trans-z { $trans: $trans translate3d($trans-x, $trans-y, $trans-z); }
|
560 |
+
@else { $trans: $trans translate($trans-x, $trans-y); }
|
561 |
+
} @else {
|
562 |
+
@if $trans-x { $trans: $trans translateX($trans-x); }
|
563 |
+
@if $trans-y { $trans: $trans translateY($trans-y); }
|
564 |
+
@if $trans-z { $trans: $trans translateZ($trans-z); }
|
565 |
+
}
|
566 |
+
|
567 |
+
// skew
|
568 |
+
@if $skew-x and $skew-y { $trans: $trans skew($skew-x, $skew-y); }
|
569 |
+
@else {
|
570 |
+
@if $skew-x { $trans: $trans skewX($skew-x); }
|
571 |
+
@if $skew-y { $trans: $trans skewY($skew-y); }
|
572 |
+
}
|
573 |
+
|
574 |
+
// apply it!
|
575 |
+
@include transform($trans, $only3d);
|
576 |
+
@include transform-origin($origin-x, $origin-y, $origin-z, $only3d);
|
577 |
+
}
|
578 |
+
|
579 |
+
|
580 |
+
// A simplified set of options
|
581 |
+
// backwards-compatible with the previous version of the 'transform' mixin
|
582 |
+
@mixin simple-transform(
|
583 |
+
$scale: false,
|
584 |
+
$rotate: false,
|
585 |
+
$trans-x: false,
|
586 |
+
$trans-y: false,
|
587 |
+
$skew-x: false,
|
588 |
+
$skew-y: false,
|
589 |
+
$origin-x: false,
|
590 |
+
$origin-y: false
|
591 |
+
) {
|
592 |
+
@include create-transform(
|
593 |
+
false,
|
594 |
+
$scale, $scale, false,
|
595 |
+
false, false, $rotate, false,
|
596 |
+
$trans-x, $trans-y, false,
|
597 |
+
$skew-x, $skew-y,
|
598 |
+
$origin-x, $origin-y, false,
|
599 |
+
false
|
600 |
+
);
|
601 |
+
}
|
602 |
+
:
|
603 |
+
@linei:@children[io:Sass::Tree::ImportNode;0:@imported_file0:@imported_filename"shared;@; i;
|
604 |
+
[ o:Sass::Tree::CommentNode
|
605 |
+
:
|
606 |
+
@type:silent;@:@value["p/* @doc off
|
607 |
+
* Note ----------------------------------------------------------------------
|
608 |
+
* Safari, Chrome, and Firefox all support 3D transforms. However,
|
609 |
+
* only in the most recent builds. You should also provide fallback 2d support for
|
610 |
+
* Opera and IE. IE10 is slated to have 3d enabled, but is currently unreleased.
|
611 |
+
* To make that easy, all 2D transforms include an browser-targeting toggle ($only3d)
|
612 |
+
* to switch between the two support lists. The toggle defaults to 'false' (2D),
|
613 |
+
* and also accepts 'true' (3D). Currently the lists are as follows:
|
614 |
+
* 2D: Mozilla, Webkit, Opera, Official
|
615 |
+
* 3D: Webkit, Firefox. */; i;
|
616 |
+
[ o;
|
617 |
+
;;;@;["�/* Available Transforms ------------------------------------------------------
|
618 |
+
* - Scale (2d and 3d)
|
619 |
+
* - Rotate (2d and 3d)
|
620 |
+
* - Translate (2d and 3d)
|
621 |
+
* - Skew (2d only) */; i;
|
622 |
+
[ o;
|
623 |
+
;;;@;["�/* Transform Parameters ------------------------------------------------------
|
624 |
+
* - Transform Origin (2d and 3d)
|
625 |
+
* - Perspective (3d)
|
626 |
+
* - Perspective Origin (3d)
|
627 |
+
* - Transform Style (3d)
|
628 |
+
* - Backface Visibility (3d) */; i;
|
629 |
+
[ o;
|
630 |
+
;;;@;["p/* Mixins --------------------------------------------------------------------
|
631 |
+
* transform-origin
|
632 |
+
* - shortcuts: transform-origin2d, transform-origin3d
|
633 |
+
* - helpers: apply-origin
|
634 |
+
* transform
|
635 |
+
* - shortcuts: transform2d, transform3d
|
636 |
+
* - helpers: simple-transform, create-transform
|
637 |
+
* perspective
|
638 |
+
* - helpers: perspective-origin
|
639 |
+
* transform-style
|
640 |
+
* backface-visibility
|
641 |
+
* scale
|
642 |
+
* - shortcuts: scaleX, scaleY, scaleZ, scale3d
|
643 |
+
* rotate
|
644 |
+
* - shortcuts: rotateX, rotateY, rotate3d
|
645 |
+
* translate
|
646 |
+
* - shortcuts: translateX, translateY, translateZ, translate3d
|
647 |
+
* skew
|
648 |
+
* - shortcuts: skewX, skewY */; i ;
|
649 |
+
[ o;
|
650 |
+
;;;@;["a/* Defaults ------------------------------------------------------------------
|
651 |
+
* @doc on */; i4;
|
652 |
+
[ o;
|
653 |
+
;;;@;["./* The default x-origin for transforms */; i7;
|
654 |
+
[ o:Sass::Tree::VariableNode:
|
655 |
+
@expro:Sass::Script::Number:@numerator_units["%:@original"50%;@;i7; i8:@denominator_units[ :
|
656 |
+
@name"default-origin-x;@; i8;
|
657 |
+
[ o;
|
658 |
+
;;;@;["./* The default y-origin for transforms */; i9;
|
659 |
+
[ o;;"
|
660 |
+
[ o;
|
661 |
+
;;;@;["./* The default z-origin for transforms */; i;;
|
662 |
+
[ o;;"
|
663 |
+
[ o;
|
664 |
+
;;;@;["//* The default x-multiplier for scaling */; i?;
|
665 |
+
[ o;;"
|
666 |
+
[ o;
|
667 |
+
;;;@;["//* The default y-multiplier for scaling */; iA;
|
668 |
+
[ o;;"
|
669 |
+
[ o;
|
670 |
+
;;;@;["//* The default z-multiplier for scaling */; iC;
|
671 |
+
[ o;;"
|
672 |
+
[ o;
|
673 |
+
;;;@;["*/* The default angle for rotations */; iG;
|
674 |
+
[ o;;"
|
675 |
+
45deg;@;i2; iH;[ ;"default-rotate;@; iH;
|
676 |
+
[ o;
|
677 |
+
;;;@;["</* The default x-vector for the axis of 3d rotations */; iK;
|
678 |
+
[ o;;"
|
679 |
+
[ o;
|
680 |
+
;;;@;["</* The default y-vector for the axis of 3d rotations */; iM;
|
681 |
+
[ o;;"
|
682 |
+
[ o;
|
683 |
+
;;;@;["</* The default z-vector for the axis of 3d rotations */; iO;
|
684 |
+
[ o;;"
|
685 |
+
[ o;
|
686 |
+
;;;@;["0/* The default x-length for translations */; iS;
|
687 |
+
[ o;;"
|
688 |
+
[ o;
|
689 |
+
;;;@;["0/* The default y-length for translations */; iU;
|
690 |
+
[ o;;"
|
691 |
+
[ o;
|
692 |
+
;;;@;["0/* The default z-length for translations */; iW;
|
693 |
+
[ o;;"
|
694 |
+
[ o;
|
695 |
+
;;;@;["*/* The default x-angle for skewing */; i[;
|
696 |
+
[ o;;"
|
697 |
+
; i\;[ ;"default-skew-x;@; i\;
|
698 |
+
[ o;
|
699 |
+
;;;@;["*/* The default y-angle for skewing */; i];
|
700 |
+
[ o;;"
|
701 |
+
; i^;[ ;"default-skew-y;@; i^;
|
702 |
+
[ o;
|
703 |
+
;;;@;["�/* **Transform-origin**
|
704 |
+
* Transform-origin sent as a complete string
|
705 |
+
*
|
706 |
+
* @include apply-origin( origin [, 3D-only ] )
|
707 |
+
*
|
708 |
+
* where 'origin' is a space separated list containing 1-3 (x/y/z) coordinates
|
709 |
+
* in percentages, absolute (px, cm, in, em etc..) or relative
|
710 |
+
* (left, top, right, bottom, center) units
|
711 |
+
*
|
712 |
+
* @param only3d Set this to true to only apply this
|
713 |
+
* mixin where browsers have 3D support. */; ia;
|
714 |
+
[ o:Sass::Tree::MixinDefNode;"apply-origin;@;T; il;
|
715 |
+
[o;;0;o:Sass::Script::Operation
|
716 |
+
:@operator:or;@:@operand2o;
|
717 |
+
;:gt;@; o;;[ ;"2;@;i; im;@Q; im:@operand1o:Sass::Script::Funcall:@keywords{ ;"-compass-list-size;@; im:@splat0:
|
718 |
+
@args[o;#;${ ;"-compass-list;@; im;%0;&[o; ;"origin;"origin;@; im; im;"o; ;"only3d;"only3d;@; im;"only3d;@; im;
|
719 |
+
[ u:Sass::Tree::IfNode�[o:Sass::Script::Variable :@underscored_name"only3d:
|
720 |
+
@name"only3d:
|
721 |
+
@lineinu:Sass::Tree::IfNode�[00[o:Sass::Tree::MixinNode:@keywords{ :
|
722 |
+
@name"experimental:
|
723 |
+
@lineiu:@children[ :@splat0:
|
724 |
+
@args[
|
725 |
+
@type:identifier;@
|
726 |
+
:@value"transform-origin; iso:Sass::Script::Variable :@underscored_name"origin;"origin;@
|
727 |
+
; iso;
|
728 |
+
;" -moz; ito;
|
729 |
+
;"-webkit; ito;
|
730 |
+
;"-o; ito;
|
731 |
+
;"-ms; ito:!Sass::Script::UnaryOperation :@operator:not;@
|
732 |
+
; it:
|
733 |
+
;"-khtml; ito;
|
734 |
+
;"
|
735 |
+
@args[
|
736 |
+
@type:identifier;@ :@value"transform-origin; ioo; ;"origin;"origin;@ ; ioo; ;;;@ ;" -moz; ipo; ;;;@ ;"-webkit; ipo; ;;;@ ;"-o; ipo; ;;;@ ;"-ms; ipo:!Sass::Script::UnaryOperation :@operator:not;@ ; ip:
|
737 |
+
;;;@;["#/* Transform-origin sent as individual arguments:
|
738 |
+
*
|
739 |
+
* @include transform-origin( [ origin-x, origin-y, origin-z, 3D-only ] )
|
740 |
+
*
|
741 |
+
* where the 3 'origin-' arguments represent x/y/z coordinates.
|
742 |
+
*
|
743 |
+
* **NOTE:** setting z coordinates triggers 3D support list, leave false for 2D support */; iy;
|
744 |
+
[ o;;"transform-origin;@;T; i�;
|
745 |
+
[o;;0;o;#;${ ;"unquote;@; i�;%0;&[o:Sass::Script::String ;:string;@;"
|