archetype 0.0.1.pre.1 → 0.0.1.pre.3.00dfd9a
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CHANGELOG.md +88 -0
- data/LICENSE +16 -0
- data/README.md +87 -1
- data/VERSION.yml +6 -0
- data/lib/README.rdoc +4 -0
- data/lib/archetype.rb +45 -0
- data/lib/archetype/functions.rb +9 -0
- data/lib/archetype/functions/hash.rb +149 -0
- data/lib/archetype/functions/helpers.rb +125 -0
- data/lib/archetype/functions/styleguide_memoizer.rb +61 -0
- data/lib/archetype/sass_extensions.rb +6 -0
- data/lib/archetype/sass_extensions/functions.rb +14 -0
- data/lib/archetype/sass_extensions/functions/environment.rb +14 -0
- data/lib/archetype/sass_extensions/functions/lists.rb +284 -0
- data/lib/archetype/sass_extensions/functions/locale.rb +77 -0
- data/lib/archetype/sass_extensions/functions/numbers.rb +19 -0
- data/lib/archetype/sass_extensions/functions/styleguide.rb +406 -0
- data/lib/archetype/sass_extensions/functions/ui.rb +59 -0
- data/lib/archetype/sass_extensions/functions/version.rb +95 -0
- data/lib/archetype/version.rb +75 -0
- data/stylesheets/_archetype.scss +2 -0
- data/stylesheets/archetype/_base.scss +46 -0
- data/stylesheets/archetype/_config.scss +366 -0
- data/stylesheets/archetype/_grid.scss +3 -0
- data/stylesheets/archetype/_hacks.scss +72 -0
- data/stylesheets/archetype/_init.scss +23 -0
- data/stylesheets/archetype/_styleguide.scss +6 -0
- data/stylesheets/archetype/_ui.scss +326 -0
- data/stylesheets/archetype/_util.scss +12 -0
- data/stylesheets/archetype/base/_h5bp.scss +307 -0
- data/stylesheets/archetype/base/_hybrid.scss +25 -0
- data/stylesheets/archetype/base/_normalize.scss +595 -0
- data/stylesheets/archetype/base/_reset.scss +72 -0
- data/stylesheets/archetype/grid/_config.scss +14 -0
- data/stylesheets/archetype/grid/_grid.scss +391 -0
- data/stylesheets/archetype/styleguide/_components.scss +25 -0
- data/stylesheets/archetype/styleguide/_helpers.scss +215 -0
- data/stylesheets/archetype/styleguide/_primitives.scss +10 -0
- data/stylesheets/archetype/styleguide/_styleguide.scss +41 -0
- data/stylesheets/archetype/styleguide/components/_alerts.scss +59 -0
- data/stylesheets/archetype/styleguide/components/_annotations.scss +27 -0
- data/stylesheets/archetype/styleguide/components/_bristol.scss +15 -0
- data/stylesheets/archetype/styleguide/components/_button_groups.scss +47 -0
- data/stylesheets/archetype/styleguide/components/_button_toolbars.scss +17 -0
- data/stylesheets/archetype/styleguide/components/_buttons.scss +338 -0
- data/stylesheets/archetype/styleguide/components/_canvas.scss +15 -0
- data/stylesheets/archetype/styleguide/components/_carets.scss +336 -0
- data/stylesheets/archetype/styleguide/components/_closes.scss +63 -0
- data/stylesheets/archetype/styleguide/components/_container.scss +27 -0
- data/stylesheets/archetype/styleguide/components/_copy.scss +85 -0
- data/stylesheets/archetype/styleguide/components/_flyouts.scss +52 -0
- data/stylesheets/archetype/styleguide/components/_headings.scss +33 -0
- data/stylesheets/archetype/styleguide/components/_headlines.scss +63 -0
- data/stylesheets/archetype/styleguide/components/_hovercards.scss +27 -0
- data/stylesheets/archetype/styleguide/components/_icons.scss +17 -0
- data/stylesheets/archetype/styleguide/components/_identities.scss +34 -0
- data/stylesheets/archetype/styleguide/components/_links.scss +66 -0
- data/stylesheets/archetype/styleguide/components/_loaders.scss +154 -0
- data/stylesheets/archetype/styleguide/components/_menu_items.scss +31 -0
- data/stylesheets/archetype/styleguide/components/_module.scss +15 -0
- data/stylesheets/archetype/styleguide/components/_pullquotes.scss +29 -0
- data/stylesheets/archetype/styleguide/components/_punchcut.scss +18 -0
- data/stylesheets/archetype/styleguide/components/_tooltips.scss +28 -0
- data/stylesheets/archetype/styleguide/primitives/_animations.scss +17 -0
- data/stylesheets/archetype/styleguide/primitives/_dimensions.scss +50 -0
- data/stylesheets/archetype/styleguide/primitives/_glyphs.scss +11 -0
- data/stylesheets/archetype/styleguide/primitives/_misc.scss +8 -0
- data/stylesheets/archetype/styleguide/primitives/_palettes.scss +94 -0
- data/stylesheets/archetype/styleguide/primitives/_shadows.scss +23 -0
- data/stylesheets/archetype/styleguide/primitives/_sprites.scss +46 -0
- data/stylesheets/archetype/styleguide/primitives/_textures.scss +10 -0
- data/stylesheets/archetype/styleguide/primitives/_typography.scss +56 -0
- data/stylesheets/archetype/util/_debug.scss +40 -0
- data/stylesheets/archetype/util/_lists.scss +57 -0
- data/stylesheets/archetype/util/_misc.scss +108 -0
- data/stylesheets/archetype/util/_rtl.scss +279 -0
- data/stylesheets/archetype/util/_spacing.scss +78 -0
- data/stylesheets/archetype/util/_styles.scss +466 -0
- data/stylesheets/archetype/util/_targeting.scss +210 -0
- data/stylesheets/archetype/util/_units.scss +18 -0
- data/templates/example/index.html +40 -0
- data/templates/example/manifest.rb +13 -0
- data/templates/example/screen.scss +99 -0
- data/templates/example/vendor/archetype/animations/loaders/large/large.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/large/large_dark.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/large/large_dark_static.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/large/large_static.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/medium/medium.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/medium/medium_dark.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/medium/medium_dark_static.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/medium/medium_static.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/small/small.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/small/small_dark.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/small/small_dark_static.png +0 -0
- data/templates/example/vendor/archetype/animations/loaders/small/small_static.png +0 -0
- data/templates/example/vendor/archetype/fontawesome-webfont.eot +0 -0
- data/templates/example/vendor/archetype/fontawesome-webfont.svg +255 -0
- data/templates/example/vendor/archetype/fontawesome-webfont.ttf +0 -0
- data/templates/example/vendor/archetype/fontawesome-webfont.woff +0 -0
- data/templates/project/manifest.rb +9 -0
- data/templates/project/screen.scss +1 -0
- data/templates/project/vendor/archetype/animations/loaders/large/large.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/large/large_dark.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/large/large_dark_static.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/large/large_static.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/medium/medium.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/medium/medium_dark.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/medium/medium_dark_static.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/medium/medium_static.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/small/small.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/small/small_dark.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/small/small_dark_static.png +0 -0
- data/templates/project/vendor/archetype/animations/loaders/small/small_static.png +0 -0
- data/templates/project/vendor/archetype/fontawesome-webfont.eot +0 -0
- data/templates/project/vendor/archetype/fontawesome-webfont.svg +255 -0
- data/templates/project/vendor/archetype/fontawesome-webfont.ttf +0 -0
- data/templates/project/vendor/archetype/fontawesome-webfont.woff +0 -0
- data/test/fixtures/stylesheets/archetype/assets/fonts/fontawesome-webfont.eot +0 -0
- data/test/fixtures/stylesheets/archetype/assets/fonts/fontawesome-webfont.svg +255 -0
- data/test/fixtures/stylesheets/archetype/assets/fonts/fontawesome-webfont.ttf +0 -0
- data/test/fixtures/stylesheets/archetype/assets/fonts/fontawesome-webfont.woff +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/large/large.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/large/large_dark.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/large/large_dark_static.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/large/large_static.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/medium/medium.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/medium/medium_dark.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/medium/medium_dark_static.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/medium/medium_static.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/small/small.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/small/small_dark.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/small/small_dark_static.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/animations/loaders/small/small_static.png +0 -0
- data/test/fixtures/stylesheets/archetype/assets/images/vendor/archetype/sprites/hovercard_tip.png +0 -0
- data/test/fixtures/stylesheets/archetype/config.rb +19 -0
- data/test/fixtures/stylesheets/archetype/expected/b.css +14 -0
- data/test/fixtures/stylesheets/archetype/expected/base.css +349 -0
- data/test/fixtures/stylesheets/archetype/expected/hacks/ie_pseudo.css +11 -0
- data/test/fixtures/stylesheets/archetype/expected/locale.css +23 -0
- data/test/fixtures/stylesheets/archetype/expected/styleguide/buttons.css +2091 -0
- data/test/fixtures/stylesheets/archetype/expected/styleguide/fallback_styles.css +9 -0
- data/test/fixtures/stylesheets/archetype/expected/styleguide/nested_styleguides.css +24 -0
- data/test/fixtures/stylesheets/archetype/expected/styleguide/selective_state.css +174 -0
- data/test/fixtures/stylesheets/archetype/expected/ui/glyph_icon.css +37 -0
- data/test/fixtures/stylesheets/archetype/expected/ui/hide_element.css +8 -0
- data/test/fixtures/stylesheets/archetype/expected/ui/stroke.css +17 -0
- data/test/fixtures/stylesheets/archetype/expected/ui/triangle.css +35 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/associative.css +9 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/if-set.css +9 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/spacing/horizontal-spacing.css +29 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/spacing/vertical-spacing.css +29 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/styles/filter.css +11 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/styles/font-family.css +16 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/styles/z-index.css +15 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/targeting/target-browser.css +100 -0
- data/test/fixtures/stylesheets/archetype/expected/utilities/targeting/target-os.css +55 -0
- data/test/fixtures/stylesheets/archetype/source/b.scss +9 -0
- data/test/fixtures/stylesheets/archetype/source/base.scss +3 -0
- data/test/fixtures/stylesheets/archetype/source/hacks/ie_pseudo.scss +13 -0
- data/test/fixtures/stylesheets/archetype/source/locale.scss +43 -0
- data/test/fixtures/stylesheets/archetype/source/styleguide/buttons.scss +18 -0
- data/test/fixtures/stylesheets/archetype/source/styleguide/fallback_styles.scss +22 -0
- data/test/fixtures/stylesheets/archetype/source/styleguide/nested_styleguides.scss +40 -0
- data/test/fixtures/stylesheets/archetype/source/styleguide/selective_state.scss +22 -0
- data/test/fixtures/stylesheets/archetype/source/ui/glyph_icon.scss +13 -0
- data/test/fixtures/stylesheets/archetype/source/ui/hide_element.scss +5 -0
- data/test/fixtures/stylesheets/archetype/source/ui/stroke.scss +13 -0
- data/test/fixtures/stylesheets/archetype/source/ui/triangle.scss +13 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/associative.scss +24 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/if-set.scss +16 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/spacing/horizontal-spacing.scss +27 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/spacing/vertical-spacing.scss +27 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/styles/filter.scss +9 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/styles/font-family.scss +9 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/styles/z-index.scss +18 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/targeting/target-browser.scss +70 -0
- data/test/fixtures/stylesheets/archetype/source/utilities/targeting/target-os.scss +42 -0
- data/test/helpers/diff.rb +49 -0
- data/test/helpers/io.rb +36 -0
- data/test/helpers/test_case.rb +62 -0
- data/test/integrations/archetype_test.rb +126 -0
- data/test/test_helper.rb +26 -0
- data/test/units/sass_extensions_test.rb +207 -0
- metadata +303 -15
@@ -0,0 +1,63 @@
|
|
1
|
+
// ==========
|
2
|
+
// CLOSES
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_CLOSES_ID: close !default;
|
5
|
+
$STYLEGUIDE_CLOSES: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_CLOSES_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_CLOSES_ID, $STYLEGUIDE_CLOSES, (
|
9
|
+
(default, (
|
10
|
+
color inherit,
|
11
|
+
background (transparent none),
|
12
|
+
padding (0 1px 0 0),
|
13
|
+
border 0,
|
14
|
+
margin 0,
|
15
|
+
cursor pointer,
|
16
|
+
text-decoration none,
|
17
|
+
position absolute,
|
18
|
+
overflow hidden,
|
19
|
+
top vertical-spacing(2),
|
20
|
+
right horizontal-spacing(2),
|
21
|
+
width nth($CONFIG_GLYPH_CLOSE, 4),
|
22
|
+
height nth($CONFIG_GLYPH_CLOSE, 4),
|
23
|
+
text-indent (nth($CONFIG_GLYPH_CLOSE, 4) + 1px),
|
24
|
+
glyph-icon (nth($CONFIG_GLYPH_CLOSE, 1), nth($CONFIG_GLYPH_CLOSE, 2), nth($CONFIG_GLYPH_CLOSE, 3), before, 'text-decoration:none;vertical-align:top;line-height:1;position:absolute;top:0;right:0;'),
|
25
|
+
(selectors, (
|
26
|
+
('&:before', (
|
27
|
+
vertical-align top,
|
28
|
+
line-height 1,
|
29
|
+
position absolute,
|
30
|
+
top 0,
|
31
|
+
right 0,
|
32
|
+
text-decoration none,
|
33
|
+
cursor pointer
|
34
|
+
)),
|
35
|
+
nil
|
36
|
+
)),
|
37
|
+
(states, (
|
38
|
+
(hover, (
|
39
|
+
text-shadow $CONFIG_SHADOW_CLOSES,
|
40
|
+
nil
|
41
|
+
)),
|
42
|
+
nil
|
43
|
+
))
|
44
|
+
)),
|
45
|
+
(in-alert, (
|
46
|
+
color nth($CONFIG_COLOR_COPY, 2),
|
47
|
+
nil
|
48
|
+
)),
|
49
|
+
(in-dialog, (
|
50
|
+
color nth($CONFIG_COLOR_COPY, 2),
|
51
|
+
opacity 0.7,
|
52
|
+
top vertical-spacing(2.6, $abuse: true),
|
53
|
+
(states, (
|
54
|
+
(hover, (
|
55
|
+
opacity 1,
|
56
|
+
nil
|
57
|
+
)),
|
58
|
+
nil
|
59
|
+
))
|
60
|
+
)),
|
61
|
+
nil
|
62
|
+
), $CONFIG_THEME);
|
63
|
+
}
|
@@ -0,0 +1,27 @@
|
|
1
|
+
// ==========
|
2
|
+
// CONTAINER
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_CONTAINERS_ID: container !default;
|
5
|
+
$STYLEGUIDE_CONTAINERS: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_CONTAINERS_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_CONTAINERS_ID, $STYLEGUIDE_CONTAINERS, (
|
9
|
+
(default, (
|
10
|
+
background nth($CONFIG_TEXTURE_CONTAINER, 1),
|
11
|
+
box-shadow $CONFIG_SHADOW_CONTAINER,
|
12
|
+
target-browser $CONFIG_SHADOW_CONTAINER_ALT // simulate the shadow in IE<9
|
13
|
+
)),
|
14
|
+
(light, (
|
15
|
+
nil
|
16
|
+
)),
|
17
|
+
(dark, (
|
18
|
+
background nth($CONFIG_TEXTURE_CONTAINER, 2),
|
19
|
+
nil
|
20
|
+
)),
|
21
|
+
(without-shadow, (
|
22
|
+
box-shadow nil,
|
23
|
+
target-browser nil,
|
24
|
+
nil
|
25
|
+
))
|
26
|
+
), $CONFIG_THEME);
|
27
|
+
}
|
@@ -0,0 +1,85 @@
|
|
1
|
+
// ==========
|
2
|
+
// COPY
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_COPY_ID: copy !default;
|
5
|
+
$STYLEGUIDE_COPY: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_COPY_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_COPY_ID, $STYLEGUIDE_COPY, (
|
9
|
+
(default, (
|
10
|
+
font-size nth($CONFIG_FONT_COPY_MEDIUM, 1),
|
11
|
+
line-height nth-cyclic($CONFIG_FONT_COPY_MEDIUM, 2),
|
12
|
+
color nth($CONFIG_COLOR_COPY, 1),
|
13
|
+
font-weight normal
|
14
|
+
)),
|
15
|
+
// sizes
|
16
|
+
(medium, (
|
17
|
+
nil
|
18
|
+
)),
|
19
|
+
(large, (
|
20
|
+
font-size nth($CONFIG_FONT_COPY_LARGE, 1),
|
21
|
+
line-height nth-cyclic($CONFIG_FONT_COPY_LARGE, 2)
|
22
|
+
)),
|
23
|
+
(small, (
|
24
|
+
font-size nth($CONFIG_FONT_COPY_SMALL, 1),
|
25
|
+
line-height nth-cyclic($CONFIG_FONT_COPY_SMALL, 2)
|
26
|
+
)),
|
27
|
+
// contexts
|
28
|
+
(in-dark, (
|
29
|
+
color nth-cyclic($CONFIG_COLOR_COPY, 2),
|
30
|
+
nil
|
31
|
+
)),
|
32
|
+
(in-module, (
|
33
|
+
color nth($CONFIG_COLOR_COPY, 1),
|
34
|
+
nil
|
35
|
+
)),
|
36
|
+
(in-bristol, (
|
37
|
+
inherit (in-dark),
|
38
|
+
nil
|
39
|
+
)),
|
40
|
+
(in-tooltip, (
|
41
|
+
inherit (in-dark),
|
42
|
+
nil
|
43
|
+
)),
|
44
|
+
(in-alert, (
|
45
|
+
inherit (in-dark),
|
46
|
+
nil
|
47
|
+
)),
|
48
|
+
(in-punchcut, (
|
49
|
+
inherit (in-dark),
|
50
|
+
text-shadow nth-cyclic($CONFIG_SHADOW_COPY, 2),
|
51
|
+
nil
|
52
|
+
)),
|
53
|
+
(breadcrumb, (
|
54
|
+
color nth($CONFIG_COLOR_BREADCRUMB, 1),
|
55
|
+
font-size nth($CONFIG_FONT_BREADCRUMB, 1),
|
56
|
+
font-weight $CONFIG_FONT_WEIGHT_BREADCRUMB,
|
57
|
+
text-decoration nth($CONFIG_DECORATION_LINK, 1),
|
58
|
+
text-shadow $CONFIG_SHADOW_BREADCRUMB,
|
59
|
+
nil
|
60
|
+
)),
|
61
|
+
(active breadcrumb, (
|
62
|
+
color nth($CONFIG_COLOR_BREADCRUMB_ACTIVE, 1),
|
63
|
+
font-size nth($CONFIG_FONT_BREADCRUMB, 1),
|
64
|
+
font-weight $CONFIG_FONT_WEIGHT_BREADCRUMB,
|
65
|
+
text-shadow $CONFIG_SHADOW_BREADCRUMB,
|
66
|
+
border-left ($CONFIG_DIM_GENERIC_BORDER solid $CONFIG_COLOR_BREADCRUMB),
|
67
|
+
margin $CONFIG_DIM_BREADCRUMB_SPACING_OUTER,
|
68
|
+
padding $CONFIG_DIM_BREADCRUMB_SPACING,
|
69
|
+
nil
|
70
|
+
)),
|
71
|
+
(emphasized, (
|
72
|
+
font-style italic,
|
73
|
+
nil
|
74
|
+
)),
|
75
|
+
(strong, (
|
76
|
+
font-weight bold,
|
77
|
+
nil
|
78
|
+
)),
|
79
|
+
// muted colors
|
80
|
+
(muted, (
|
81
|
+
color nth($CONFIG_COLOR_COPY_MUTED, 1),
|
82
|
+
nil
|
83
|
+
))
|
84
|
+
), $CONFIG_THEME);
|
85
|
+
}
|
@@ -0,0 +1,52 @@
|
|
1
|
+
// ==========
|
2
|
+
// FLYOUT MENUS
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_FLYOUTS_ID: flyout !default;
|
5
|
+
$STYLEGUIDE_FLYOUTS: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_FLYOUTS_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_FLYOUTS_ID, $STYLEGUIDE_FLYOUTS, (
|
9
|
+
(default, (
|
10
|
+
display none, // hidden by default (use `visible flyout` if you want it shown by default)
|
11
|
+
position absolute, // position!
|
12
|
+
top 100%, // align it to the bottom of the context
|
13
|
+
left 0, // align left
|
14
|
+
z-index 1,
|
15
|
+
border ($CONFIG_DIM_GENERIC_BORDER solid nth($CONFIG_COLOR_BORDER_FLYOUT,1)),
|
16
|
+
background nth($CONFIG_TEXTURE_CONTAINER, 1),
|
17
|
+
box-shadow $CONFIG_SHADOW_FLYOUT,
|
18
|
+
padding $CONFIG_DIM_FLYOUT_SPACING,
|
19
|
+
min-width $CONFIG_DIM_FLYOUT_MIN_WIDTH,
|
20
|
+
cursor default,
|
21
|
+
float left,
|
22
|
+
list-style none // just incase its a list
|
23
|
+
)),
|
24
|
+
(visible, (
|
25
|
+
display block,
|
26
|
+
nil
|
27
|
+
)),
|
28
|
+
(in-button, (
|
29
|
+
// restore some things used for buttons
|
30
|
+
font-weight normal,
|
31
|
+
white-space normal,
|
32
|
+
text-shadow none,
|
33
|
+
// no box-shadow
|
34
|
+
box-shadow nil,
|
35
|
+
// thick borders!
|
36
|
+
border-width $CONFIG_DIM_GENERIC_BORDER_THICK,
|
37
|
+
border-radius $CONFIG_DIM_FLYOUT_RADIUS
|
38
|
+
)),
|
39
|
+
(in-button-group, (
|
40
|
+
inherit (in-button),
|
41
|
+
nil
|
42
|
+
)),
|
43
|
+
(upward, (
|
44
|
+
top nil,
|
45
|
+
bottom 100%
|
46
|
+
)),
|
47
|
+
(right aligned, (
|
48
|
+
left nil,
|
49
|
+
right 0
|
50
|
+
))
|
51
|
+
), $CONFIG_THEME);
|
52
|
+
}
|
@@ -0,0 +1,33 @@
|
|
1
|
+
// ==========
|
2
|
+
// HEADINGS
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_HEADINGS_ID: heading !default;
|
5
|
+
$STYLEGUIDE_HEADINGS: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_HEADINGS_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_HEADINGS_ID, $STYLEGUIDE_HEADINGS, (
|
9
|
+
(default, (
|
10
|
+
nil
|
11
|
+
)),
|
12
|
+
(in-flyout in-in-button-group, (
|
13
|
+
margin $CONFIG_DIM_HEADING_SPACING_OUTER,
|
14
|
+
padding $CONFIG_DIM_HEADING_SPACING,
|
15
|
+
background-color $CONFIG_TEXTURE_HEADING,
|
16
|
+
border ($CONFIG_DIM_GENERIC_BORDER solid nth($CONFIG_COLOR_BORDER_SECTION,1)),
|
17
|
+
border-width ($CONFIG_DIM_GENERIC_BORDER 0),
|
18
|
+
color nth($CONFIG_COLOR_COPY_MUTED, 1)
|
19
|
+
)),
|
20
|
+
(first in-flyout in-in-button-group, (
|
21
|
+
margin-top 0,
|
22
|
+
border-top-width 0
|
23
|
+
)),
|
24
|
+
(in-flyout in-in-button, (
|
25
|
+
inherit (in-flyout in-in-button-group),
|
26
|
+
nil
|
27
|
+
)),
|
28
|
+
(first in-flyout in-in-button, (
|
29
|
+
inherit (first in-flyout in-in-button-group),
|
30
|
+
nil
|
31
|
+
))
|
32
|
+
), $CONFIG_THEME);
|
33
|
+
}
|
@@ -0,0 +1,63 @@
|
|
1
|
+
// ==========
|
2
|
+
// HEADLINES
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_HEADLINES_ID: headline !default;
|
5
|
+
$STYLEGUIDE_HEADLINES: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_HEADLINES_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_HEADLINES_ID, $STYLEGUIDE_HEADLINES, (
|
9
|
+
(default, (
|
10
|
+
font-size nth($CONFIG_FONT_HEADLINE_LARGE, 1),
|
11
|
+
font-weight bold,
|
12
|
+
line-height nth-cyclic($CONFIG_FONT_HEADLINE_LARGE, 2),
|
13
|
+
color nth($CONFIG_COLOR_STRONG, 1)
|
14
|
+
)),
|
15
|
+
(muted, (
|
16
|
+
font-weight normal,
|
17
|
+
nil
|
18
|
+
)),
|
19
|
+
(xlarge, (
|
20
|
+
font-size nth($CONFIG_FONT_HEADLINE_XLARGE, 1),
|
21
|
+
line-height nth-cyclic($CONFIG_FONT_HEADLINE_XLARGE, 2)
|
22
|
+
)),
|
23
|
+
(xxlarge, (
|
24
|
+
font-size nth($CONFIG_FONT_HEADLINE_XXLARGE, 1),
|
25
|
+
line-height nth-cyclic($CONFIG_FONT_HEADLINE_XXLARGE, 2)
|
26
|
+
)),
|
27
|
+
(large, (
|
28
|
+
nil
|
29
|
+
)),
|
30
|
+
(medium, (
|
31
|
+
font-size nth($CONFIG_FONT_HEADLINE_MEDIUM, 1),
|
32
|
+
line-height nth-cyclic($CONFIG_FONT_HEADLINE_MEDIUM, 2)
|
33
|
+
)),
|
34
|
+
(small, (
|
35
|
+
font-size nth($CONFIG_FONT_HEADLINE_SMALL, 1),
|
36
|
+
line-height nth-cyclic($CONFIG_FONT_HEADLINE_SMALL, 2)
|
37
|
+
)),
|
38
|
+
(xsmall, (
|
39
|
+
font-size nth($CONFIG_FONT_HEADLINE_XSMALL, 1),
|
40
|
+
line-height nth-cyclic($CONFIG_FONT_HEADLINE_XSMALL, 2)
|
41
|
+
)),
|
42
|
+
(in-dark, (
|
43
|
+
color nth-cyclic($CONFIG_COLOR_STRONG, 2),
|
44
|
+
nil
|
45
|
+
)),
|
46
|
+
(in-bristol, (
|
47
|
+
inherit (in-dark),
|
48
|
+
nil
|
49
|
+
)),
|
50
|
+
(in-tooltip, (
|
51
|
+
inherit (in-dark),
|
52
|
+
nil
|
53
|
+
)),
|
54
|
+
(in-alert, (
|
55
|
+
inherit (in-dark),
|
56
|
+
nil
|
57
|
+
)),
|
58
|
+
(in-punchcut, (
|
59
|
+
inherit (in-dark),
|
60
|
+
text-shadow nth-cyclic($CONFIG_SHADOW_COPY, 2)
|
61
|
+
))
|
62
|
+
), $CONFIG_THEME);
|
63
|
+
}
|
@@ -0,0 +1,27 @@
|
|
1
|
+
// ==========
|
2
|
+
// HOVERCARDS
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_HOVERCARDS_ID: hovercard !default;
|
5
|
+
$STYLEGUIDE_HOVERCARDS: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_HOVERCARDS_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_HOVERCARDS_ID, $STYLEGUIDE_HOVERCARDS, (
|
9
|
+
(default, (
|
10
|
+
border-radius $CONFIG_DIM_HOVERCARD_RADIUS,
|
11
|
+
background nth($CONFIG_TEXTURE_CONTAINER, 1),
|
12
|
+
border-color nth($CONFIG_COLOR_BORDER_HOVERCARD, 1),
|
13
|
+
border-style solid,
|
14
|
+
border-width $CONFIG_DIM_GENERIC_BORDER,
|
15
|
+
box-shadow $CONFIG_SHADOW_HOVERCARD,
|
16
|
+
max-width $CONFIG_DIM_HOVERCARD_MAX_WIDTH,
|
17
|
+
padding $CONFIG_DIM_HOVERCARD_SPACING,
|
18
|
+
// structure
|
19
|
+
outline 0, // for accessibility purposes, we don't want to outline the hovercard if it has focus
|
20
|
+
display block,
|
21
|
+
position absolute,
|
22
|
+
visibility visible,
|
23
|
+
z-index 1
|
24
|
+
)),
|
25
|
+
nil
|
26
|
+
), $CONFIG_THEME);
|
27
|
+
}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
// ==========
|
2
|
+
// ICONS
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_ICONS_ID: icon !default;
|
5
|
+
$STYLEGUIDE_ICONS: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_ICONS_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_ICONS_ID, $STYLEGUIDE_ICONS, (
|
9
|
+
(default, (
|
10
|
+
inline-block true,
|
11
|
+
hide-text true,
|
12
|
+
content $CONTENT_PLACEHOLDER,
|
13
|
+
background (none no-repeat scroll 0 0 transparent)
|
14
|
+
)),
|
15
|
+
nil
|
16
|
+
), $CONFIG_THEME);
|
17
|
+
}
|
@@ -0,0 +1,34 @@
|
|
1
|
+
// ==========
|
2
|
+
// IDENTITIES
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_IDENTITY_ID: identity !default;
|
5
|
+
$STYLEGUIDE_IDENTITY: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_IDENTITY_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_IDENTITY_ID, $STYLEGUIDE_IDENTITY, (
|
9
|
+
(default, (
|
10
|
+
color nth($CONFIG_COLOR_BRAND, 1),
|
11
|
+
font-weight bold,
|
12
|
+
text-decoration nth($CONFIG_DECORATION_IDENTITY, 1),
|
13
|
+
(states, (
|
14
|
+
(hover, (
|
15
|
+
text-decoration nth-cyclic($CONFIG_DECORATION_IDENTITY, 2),
|
16
|
+
nil
|
17
|
+
)),
|
18
|
+
nil
|
19
|
+
))
|
20
|
+
)),
|
21
|
+
(in-dark, (
|
22
|
+
color nth-cyclic($CONFIG_COLOR_BRAND, 2),
|
23
|
+
nil
|
24
|
+
)),
|
25
|
+
(in-punchcut, (
|
26
|
+
inherit (in-dark),
|
27
|
+
nil
|
28
|
+
)),
|
29
|
+
(in-bristol, (
|
30
|
+
inherit (in-dark),
|
31
|
+
nil
|
32
|
+
))
|
33
|
+
), $CONFIG_THEME);
|
34
|
+
}
|
@@ -0,0 +1,66 @@
|
|
1
|
+
// ==========
|
2
|
+
// LINKS
|
3
|
+
// ==========
|
4
|
+
$STYLEGUIDE_LINKS_ID: link !default;
|
5
|
+
$STYLEGUIDE_LINKS: () !default;
|
6
|
+
|
7
|
+
@if not styleguide-component-exists($STYLEGUIDE_LINKS_ID, $CONFIG_THEME) {
|
8
|
+
$a-blackhole: styleguide-add-component($STYLEGUIDE_LINKS_ID, $STYLEGUIDE_LINKS, (
|
9
|
+
(default, (
|
10
|
+
color nth($CONFIG_COLOR_BRAND, 1),
|
11
|
+
text-decoration nth($CONFIG_DECORATION_LINK, 1),
|
12
|
+
(states, (
|
13
|
+
(hover, (
|
14
|
+
text-decoration nth-cyclic($CONFIG_DECORATION_LINK, 2),
|
15
|
+
nil
|
16
|
+
)),
|
17
|
+
nil
|
18
|
+
))
|
19
|
+
)),
|
20
|
+
(without-underline, (
|
21
|
+
(states, (
|
22
|
+
(hover, (
|
23
|
+
text-decoration none,
|
24
|
+
nil
|
25
|
+
)),
|
26
|
+
nil
|
27
|
+
)),
|
28
|
+
nil
|
29
|
+
)),
|
30
|
+
(in-dark, (
|
31
|
+
color nth-cyclic($CONFIG_COLOR_BRAND, 2),
|
32
|
+
nil
|
33
|
+
)),
|
34
|
+
(in-punchcut, (
|
35
|
+
inherit (in-dark),
|
36
|
+
nil
|
37
|
+
)),
|
38
|
+
(in-bristol, (
|
39
|
+
inherit (in-dark),
|
40
|
+
nil
|
41
|
+
)),
|
42
|
+
(in-alert, (
|
43
|
+
color nth-cyclic($CONFIG_COLOR_COPY, 2),
|
44
|
+
font-weight bold,
|
45
|
+
(states, (
|
46
|
+
(hover, (
|
47
|
+
color nil,
|
48
|
+
nil
|
49
|
+
)),
|
50
|
+
nil
|
51
|
+
))
|
52
|
+
)),
|
53
|
+
(muted, (
|
54
|
+
// de-emphasized links have no color until you hover over them
|
55
|
+
color nil,
|
56
|
+
(states, (
|
57
|
+
(hover, (
|
58
|
+
color nth($CONFIG_COLOR_BRAND, 1),
|
59
|
+
text-decoration none
|
60
|
+
)),
|
61
|
+
nil
|
62
|
+
))
|
63
|
+
)),
|
64
|
+
nil
|
65
|
+
), $CONFIG_THEME);
|
66
|
+
}
|