archetype 0.0.1.pre.13 → 1.0.0.alpha.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +97 -24
- data/README.md +11 -5
- data/VERSION +1 -0
- data/lib/archetype.rb +30 -18
- data/lib/archetype/actions/migrate.rb +152 -0
- data/lib/archetype/actions/theme.rb +6 -7
- data/lib/archetype/executor.rb +21 -7
- data/lib/archetype/extensions.rb +57 -0
- data/lib/archetype/functions.rb +2 -3
- data/lib/archetype/functions/css.rb +70 -0
- data/lib/archetype/functions/css/constants.rb +247 -0
- data/lib/archetype/functions/css/helpers.rb +265 -0
- data/lib/archetype/functions/css/routers.rb +28 -0
- data/lib/archetype/functions/css/routers/animation.rb +55 -0
- data/lib/archetype/functions/css/routers/background.rb +38 -0
- data/lib/archetype/functions/css/routers/border.rb +151 -0
- data/lib/archetype/functions/css/routers/list.rb +63 -0
- data/lib/archetype/functions/css/routers/margin_padding.rb +40 -0
- data/lib/archetype/functions/css/routers/outline.rb +56 -0
- data/lib/archetype/functions/css/routers/overflow.rb +11 -0
- data/lib/archetype/functions/css/routers/target.rb +38 -0
- data/lib/archetype/functions/css/routers/transition.rb +48 -0
- data/lib/archetype/functions/css/shorthands.rb +43 -0
- data/lib/archetype/functions/css/shorthands/animation.rb +18 -0
- data/lib/archetype/functions/css/shorthands/background.rb +68 -0
- data/lib/archetype/functions/css/shorthands/border.rb +102 -0
- data/lib/archetype/functions/hash.rb +3 -149
- data/lib/archetype/functions/hash/extend.rb +74 -0
- data/lib/archetype/functions/hash/shim.rb +48 -0
- data/lib/archetype/functions/helpers.rb +231 -22
- data/lib/archetype/functions/styleguide_memoizer.rb +18 -1
- data/lib/archetype/sass_extensions.rb +1 -3
- data/lib/archetype/sass_extensions/functions.rb +15 -1
- data/lib/archetype/sass_extensions/functions/environment.rb +152 -1
- data/lib/archetype/sass_extensions/functions/lists.rb +95 -45
- data/lib/archetype/sass_extensions/functions/locale.rb +107 -28
- data/lib/archetype/sass_extensions/functions/numbers.rb +118 -4
- data/lib/archetype/sass_extensions/functions/strings.rb +53 -0
- data/lib/archetype/sass_extensions/functions/styleguide.rb +43 -375
- data/lib/archetype/sass_extensions/functions/styleguide/components.rb +25 -0
- data/lib/archetype/sass_extensions/functions/styleguide/constants.rb +27 -0
- data/lib/archetype/sass_extensions/functions/styleguide/grammar.rb +80 -0
- data/lib/archetype/sass_extensions/functions/styleguide/helpers.rb +36 -0
- data/lib/archetype/sass_extensions/functions/styleguide/resolve.rb +159 -0
- data/lib/archetype/sass_extensions/functions/styleguide/styles.rb +146 -0
- data/lib/archetype/sass_extensions/functions/styleguide/themes.rb +40 -0
- data/lib/archetype/sass_extensions/functions/ui.rb +7 -57
- data/lib/archetype/sass_extensions/functions/ui/glyphs.rb +118 -0
- data/lib/archetype/sass_extensions/functions/ui/scopes.rb +96 -0
- data/lib/archetype/sass_extensions/functions/util.rb +14 -0
- data/lib/archetype/sass_extensions/functions/util/debug.rb +22 -0
- data/lib/archetype/sass_extensions/functions/util/hacks.rb +44 -0
- data/lib/archetype/sass_extensions/functions/util/images.rb +132 -0
- data/lib/archetype/sass_extensions/functions/util/misc.rb +220 -0
- data/lib/archetype/sass_extensions/functions/util/spacing.rb +83 -0
- data/lib/archetype/sass_extensions/functions/version.rb +12 -17
- data/lib/archetype/version.rb +1 -1
- data/stylesheets/archetype/_config.scss +1 -389
- data/stylesheets/archetype/_core.scss +15 -0
- data/stylesheets/archetype/_hacks.scss +4 -120
- data/stylesheets/archetype/_init.scss +4 -22
- data/stylesheets/archetype/_required.scss +3 -0
- data/stylesheets/archetype/_reset.scss +3 -0
- data/stylesheets/archetype/_styleguide.scss +2 -6
- data/stylesheets/archetype/_ui.scss +2 -358
- data/stylesheets/archetype/_util.scss +3 -10
- data/stylesheets/archetype/config/_core.scss +14 -0
- data/stylesheets/archetype/config/_environment.scss +19 -0
- data/stylesheets/archetype/config/_formatting.scss +63 -0
- data/stylesheets/archetype/config/_glyphs.scss +252 -0
- data/stylesheets/archetype/config/_resets.scss +7 -0
- data/stylesheets/archetype/config/_resolution.scss +3 -0
- data/stylesheets/archetype/config/_spacing.scss +5 -0
- data/stylesheets/archetype/config/_targeting.scss +18 -0
- data/stylesheets/archetype/config/_theme.scss +3 -0
- data/stylesheets/archetype/config/_typography.scss +56 -0
- data/stylesheets/archetype/config/_units.scss +2 -0
- data/stylesheets/archetype/config/_vars.scss +10 -0
- data/stylesheets/archetype/hacks/_core.scss +4 -0
- data/stylesheets/archetype/hacks/_hacks.scss +160 -0
- data/stylesheets/archetype/hacks/_init.scss +2 -0
- data/stylesheets/archetype/styleguide/_core.scss +4 -0
- data/stylesheets/archetype/styleguide/_init.scss +1 -0
- data/stylesheets/archetype/styleguide/_styleguide.scss +41 -18
- data/stylesheets/archetype/ui/_accessibility.scss +41 -0
- data/stylesheets/archetype/ui/_breakpoints.scss +19 -0
- data/stylesheets/archetype/ui/_core.scss +10 -0
- data/stylesheets/archetype/ui/_elements.scss +98 -0
- data/stylesheets/archetype/ui/_glyphs.scss +244 -0
- data/stylesheets/archetype/ui/_init.scss +5 -0
- data/stylesheets/archetype/ui/_layout.scss +37 -0
- data/stylesheets/archetype/ui/_locale.scss +12 -0
- data/stylesheets/archetype/ui/_scopes.scss +42 -0
- data/stylesheets/archetype/util/_core.scss +8 -0
- data/stylesheets/archetype/util/_debug.scss +9 -21
- data/stylesheets/archetype/util/_init.scss +1 -0
- data/stylesheets/archetype/util/_misc.scss +21 -86
- data/stylesheets/archetype/util/_spacing.scss +9 -40
- data/stylesheets/archetype/util/_styles.scss +189 -178
- data/stylesheets/archetype/util/_targeting.scss +51 -68
- data/templates/example/manifest.rb +2 -2
- data/templates/example/screen.scss +0 -1
- data/templates/project/manifest.rb +3 -8
- metadata +93 -263
- data/bin/archetype +0 -3
- data/lib/archetype/sass_extensions/monkey_patches.rb +0 -3
- data/lib/archetype/sass_extensions/monkey_patches/handle_include_loop.rb +0 -13
- data/stylesheets/archetype/_base.scss +0 -54
- data/stylesheets/archetype/_grid.scss +0 -3
- data/stylesheets/archetype/base/_h5bp.scss +0 -307
- data/stylesheets/archetype/base/_hybrid.scss +0 -25
- data/stylesheets/archetype/base/_normalize.scss +0 -634
- data/stylesheets/archetype/base/_reset.scss +0 -72
- data/stylesheets/archetype/grid/_config.scss +0 -14
- data/stylesheets/archetype/grid/_grid.scss +0 -391
- data/stylesheets/archetype/styleguide/_components.scss +0 -25
- data/stylesheets/archetype/styleguide/_helpers.scss +0 -215
- data/stylesheets/archetype/styleguide/_primitives.scss +0 -10
- data/stylesheets/archetype/styleguide/components/_alerts.scss +0 -59
- data/stylesheets/archetype/styleguide/components/_annotations.scss +0 -27
- data/stylesheets/archetype/styleguide/components/_bristol.scss +0 -15
- data/stylesheets/archetype/styleguide/components/_button_groups.scss +0 -47
- data/stylesheets/archetype/styleguide/components/_button_toolbars.scss +0 -17
- data/stylesheets/archetype/styleguide/components/_buttons.scss +0 -339
- data/stylesheets/archetype/styleguide/components/_canvas.scss +0 -15
- data/stylesheets/archetype/styleguide/components/_carets.scss +0 -336
- data/stylesheets/archetype/styleguide/components/_closes.scss +0 -63
- data/stylesheets/archetype/styleguide/components/_container.scss +0 -27
- data/stylesheets/archetype/styleguide/components/_copy.scss +0 -85
- data/stylesheets/archetype/styleguide/components/_flyouts.scss +0 -52
- data/stylesheets/archetype/styleguide/components/_headings.scss +0 -33
- data/stylesheets/archetype/styleguide/components/_headlines.scss +0 -64
- data/stylesheets/archetype/styleguide/components/_hovercards.scss +0 -27
- data/stylesheets/archetype/styleguide/components/_icons.scss +0 -17
- data/stylesheets/archetype/styleguide/components/_identities.scss +0 -34
- data/stylesheets/archetype/styleguide/components/_links.scss +0 -68
- data/stylesheets/archetype/styleguide/components/_loaders.scss +0 -154
- data/stylesheets/archetype/styleguide/components/_menu_items.scss +0 -31
- data/stylesheets/archetype/styleguide/components/_module.scss +0 -15
- data/stylesheets/archetype/styleguide/components/_pullquotes.scss +0 -29
- data/stylesheets/archetype/styleguide/components/_punchcut.scss +0 -18
- data/stylesheets/archetype/styleguide/components/_tooltips.scss +0 -28
- data/stylesheets/archetype/styleguide/primitives/_animations.scss +0 -17
- data/stylesheets/archetype/styleguide/primitives/_dimensions.scss +0 -50
- data/stylesheets/archetype/styleguide/primitives/_glyphs.scss +0 -11
- data/stylesheets/archetype/styleguide/primitives/_misc.scss +0 -8
- data/stylesheets/archetype/styleguide/primitives/_palettes.scss +0 -94
- data/stylesheets/archetype/styleguide/primitives/_shadows.scss +0 -23
- data/stylesheets/archetype/styleguide/primitives/_sprites.scss +0 -46
- data/stylesheets/archetype/styleguide/primitives/_textures.scss +0 -10
- data/stylesheets/archetype/styleguide/primitives/_typography.scss +0 -56
- data/stylesheets/archetype/util/_lists.scss +0 -57
- data/stylesheets/archetype/util/_rtl.scss +0 -279
- data/stylesheets/archetype/util/_units.scss +0 -18
- data/templates/project/screen.scss +0 -1
- 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 +0 -255
- 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 +0 -255
- 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-s7889ccc8c1.png +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 +0 -21
- data/test/fixtures/stylesheets/archetype/source/b.scss +0 -9
- data/test/fixtures/stylesheets/archetype/source/base.scss +0 -3
- data/test/fixtures/stylesheets/archetype/source/hacks/ie_pseudo.scss +0 -13
- data/test/fixtures/stylesheets/archetype/source/hacks/transparent_focusable.scss +0 -5
- data/test/fixtures/stylesheets/archetype/source/locale.scss +0 -43
- data/test/fixtures/stylesheets/archetype/source/styleguide/alerts.scss +0 -21
- data/test/fixtures/stylesheets/archetype/source/styleguide/buttons.scss +0 -18
- data/test/fixtures/stylesheets/archetype/source/styleguide/drop.scss +0 -101
- data/test/fixtures/stylesheets/archetype/source/styleguide/extend.scss +0 -24
- data/test/fixtures/stylesheets/archetype/source/styleguide/fallback_styles.scss +0 -23
- data/test/fixtures/stylesheets/archetype/source/styleguide/invalid_structures.scss +0 -85
- data/test/fixtures/stylesheets/archetype/source/styleguide/multi_value.scss +0 -18
- data/test/fixtures/stylesheets/archetype/source/styleguide/nested_styleguides.scss +0 -40
- data/test/fixtures/stylesheets/archetype/source/styleguide/selective_state.scss +0 -22
- data/test/fixtures/stylesheets/archetype/source/ui/glyph_icon.scss +0 -35
- data/test/fixtures/stylesheets/archetype/source/ui/hide_element.scss +0 -5
- data/test/fixtures/stylesheets/archetype/source/ui/stroke.scss +0 -13
- data/test/fixtures/stylesheets/archetype/source/ui/triangle.scss +0 -13
- data/test/fixtures/stylesheets/archetype/source/utilities/associative.scss +0 -24
- data/test/fixtures/stylesheets/archetype/source/utilities/custom_output_styler.scss +0 -22
- data/test/fixtures/stylesheets/archetype/source/utilities/if-set.scss +0 -16
- data/test/fixtures/stylesheets/archetype/source/utilities/spacing/horizontal-spacing.scss +0 -27
- data/test/fixtures/stylesheets/archetype/source/utilities/spacing/vertical-spacing.scss +0 -27
- data/test/fixtures/stylesheets/archetype/source/utilities/styles/filter.scss +0 -9
- data/test/fixtures/stylesheets/archetype/source/utilities/styles/font-family.scss +0 -9
- data/test/fixtures/stylesheets/archetype/source/utilities/styles/z-index.scss +0 -18
- data/test/fixtures/stylesheets/archetype/source/utilities/targeting/target-browser.scss +0 -77
- data/test/fixtures/stylesheets/archetype/source/utilities/targeting/target-os.scss +0 -42
- data/test/fixtures/stylesheets/archetype/tmp/b.css +0 -14
- data/test/fixtures/stylesheets/archetype/tmp/base.css +0 -349
- data/test/fixtures/stylesheets/archetype/tmp/hacks/ie_pseudo.css +0 -11
- data/test/fixtures/stylesheets/archetype/tmp/hacks/transparent_focusable.css +0 -4
- data/test/fixtures/stylesheets/archetype/tmp/locale.css +0 -23
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/alerts.css +0 -711
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/buttons.css +0 -2119
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/drop.css +0 -63
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/extend.css +0 -11
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/fallback_styles.css +0 -10
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/invalid_structures.css +0 -21
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/multi_value.css +0 -13
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/nested_styleguides.css +0 -28
- data/test/fixtures/stylesheets/archetype/tmp/styleguide/selective_state.css +0 -177
- data/test/fixtures/stylesheets/archetype/tmp/ui/glyph_icon.css +0 -127
- data/test/fixtures/stylesheets/archetype/tmp/ui/hide_element.css +0 -8
- data/test/fixtures/stylesheets/archetype/tmp/ui/stroke.css +0 -17
- data/test/fixtures/stylesheets/archetype/tmp/ui/triangle.css +0 -35
- data/test/fixtures/stylesheets/archetype/tmp/utilities/associative.css +0 -9
- data/test/fixtures/stylesheets/archetype/tmp/utilities/custom_output_styler.css +0 -8
- data/test/fixtures/stylesheets/archetype/tmp/utilities/if-set.css +0 -9
- data/test/fixtures/stylesheets/archetype/tmp/utilities/spacing/horizontal-spacing.css +0 -29
- data/test/fixtures/stylesheets/archetype/tmp/utilities/spacing/vertical-spacing.css +0 -29
- data/test/fixtures/stylesheets/archetype/tmp/utilities/styles/filter.css +0 -11
- data/test/fixtures/stylesheets/archetype/tmp/utilities/styles/font-family.css +0 -16
- data/test/fixtures/stylesheets/archetype/tmp/utilities/styles/z-index.css +0 -15
- data/test/fixtures/stylesheets/archetype/tmp/utilities/targeting/target-browser.css +0 -105
- data/test/fixtures/stylesheets/archetype/tmp/utilities/targeting/target-os.css +0 -55
- data/test/helpers/diff.rb +0 -49
- data/test/helpers/io.rb +0 -36
- data/test/helpers/test_case.rb +0 -62
- data/test/integrations/archetype_test.rb +0 -126
- data/test/test_helper.rb +0 -26
- data/test/units/sass_extensions_test.rb +0 -200
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c6a2fb81e863d967312ecbecbc7f3c5448b59c62
|
4
|
+
data.tar.gz: 0b6e44d73cafd433970965a671a2fa0c43c405bc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fc1349d999e060d49b2e94e4bd8abfe527e9bd6fff4b3ecfcc7c29c24698cf651ceeece94496347a4a230764ad43d41e3eb4d8c02fb32e4f3d649e92a9ca4e19
|
7
|
+
data.tar.gz: 16adc0073b1fec35365d4c55edd05dc677ef49959266675955a4c0f67bf469804f62214626223bbc74ce93c858952139d40be3c2541c2cc2b4b28af45a9767c8
|
data/CHANGELOG.md
CHANGED
@@ -1,33 +1,106 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
-
## 0.0.1
|
3
|
+
## 1.0.0.alpha.1 (unreleased)
|
4
4
|
|
5
|
-
|
5
|
+
### Resolved Issues:
|
6
|
+
|
7
|
+
- support Sass 3.3.0 and Compass 1.0.0
|
8
|
+
- `content` is no longer improperly quoted if not needed
|
9
|
+
- fix for IE7 `:before` glyphs not being positioned correctly
|
10
|
+
- fix for IE7 potentially crashing with `Operation Aborted` due to glyph injection
|
11
|
+
|
12
|
+
### New Features:
|
13
|
+
|
14
|
+
- added `$CONFIG_STATE_BEM` and `$CONFIG_BEM_MODIFIER_SEPARATOR` to generate [BEM style state selectors](http://bem.info/method/)
|
15
|
+
- added `$CONFIG_BEM_ELEMENT_SEPARATOR` and `bem` mixin
|
16
|
+
- added `bem-selector` function to help compute the BEM style selector for a context
|
17
|
+
- added `str-replace` function for simple Sass::Script::Value::String replacements
|
18
|
+
- added `$CONFIG_THEME_EXCLUDE` takes a list of components that will be excluded (not registered)
|
19
|
+
- added `switch-locale` mixin to switch the interface locale
|
20
|
+
- styleguides now support registering maps
|
21
|
+
- `to-styles` now takes a map (but still supports a key-value paired list)
|
22
|
+
- improved debugging messages generated by `styleguide` and `styleguide-diff`
|
23
|
+
- `glyph-icons` mixin now supports multiple glyph libraries as well as multiple grid sizes via `$CONFIG_GLYPHS_LIBRARIES`
|
24
|
+
- `glyph-icons` mixin now supports multiple glyph icons on one element
|
25
|
+
- added `glyph-icons` function to help with retrieving glyph info (returned in a map for access)
|
26
|
+
- added `$CONFIG_GLYPHS_OUTPUT_FALLBACK` config
|
27
|
+
- added `archetype migrate` command line action to test for migration/back-compat issues
|
28
|
+
- improved locale functionality, including
|
29
|
+
- support for more complex formats. e.g. `sr_SP@Cyrillic`
|
30
|
+
- new methods to extract a piece of a locale: `locale-language`, `locale-territory`, `locale-modifier`
|
31
|
+
- added `derived-style` and `styleguide-derived-style` for extracting individual style rules from maps of styles or styleguide components
|
32
|
+
- improved memoizer scheme with option for `:aggressive` memoizing
|
33
|
+
- added `-archetype-list` to mimic the deprecated `-compass-list`
|
34
|
+
- added `$CONFIG_NAMESPACE` to allow namespacing global generated CSS (keyframes, font-face, etc)
|
35
|
+
- added `high-resolution` mixin for scoping high resolution (HiDPI / retina) code
|
36
|
+
- added `resolution-to-*` functions for converting between various resolution types (ratio, dppx, dpi, dpcm)
|
37
|
+
- `resolution_to_x`, `resolution-to-ratio`, `resolution-to-dppx`, `resolution-to-dpi`, `resolution-to-dpcm`
|
38
|
+
- added `to-fraction` function for converting a decimal number to a fractional representation (e.g. `1.5` -> `3/2`)
|
39
|
+
- added `list-join` function for joining a list into a string
|
40
|
+
- added `archetype-meta` function to retrieve values set on `$CONFIG_META` or `Compass.configuration.archetype_meta`
|
41
|
+
- added `register-breakpoint` and `get-breakpoint` functions for registering / retrieving breakpoint definitions
|
42
|
+
- added `breakpoint` mixin for creating breakpoint media queries
|
43
|
+
- added `switch-locale` function to assist switching locale states
|
44
|
+
- added helper functions for working with Archetype modules: `register-archetype-module`, `has-archetype-modules`, `require-archetype-modules`
|
45
|
+
- added `runtime-locale-value` for decorating a map so we can compute it's value respective to the locale at runtime (better support for `switch-locale`)
|
46
|
+
- e.g. `runtime-locale-value((default: a, en_US: b, ru_RU: c, ...))`
|
47
|
+
- added `get-runtime-locale-value` for selecting the value based on the current locale. this should be in conjunction with `runtime-locale-value`
|
48
|
+
- added `register-glyph-library`, `get-glyph-library`, and `get-all-glyph-libraries` functions for registering / retrieving glyph icon libraries
|
49
|
+
- added `before` and `after` mixins to ease the pain in styling `:before` and `:after` elements cross-browser
|
50
|
+
- allow `target-browser` and `target-os` to accept a map of property-value pairs
|
51
|
+
|
52
|
+
### Major Changes:
|
53
|
+
|
54
|
+
- dropped support for older versions of Sass/Compass (sorry, can't pass up the new feature set)
|
55
|
+
- removed `gradient-with-deg` mixin
|
56
|
+
- removed `_isLegacySupported` function
|
57
|
+
- `inline-block` in styleguide component has changed syntax to take proper arguments
|
58
|
+
- dropped `gradient` from supported keywords in styleguide components (use `background-image` instead)
|
59
|
+
- `$CORE_STATE_MAPPINGS` and `$CONFIG_STATE_MAPPINGS` are now proper Sass maps
|
60
|
+
- `styleguide` function now has the same signature as the mixin and can take multiple definitions at once
|
61
|
+
- `styleguide-diff` now takes two `styleguide` results as params
|
62
|
+
- removed `testing` configuration, instead check for `defined?(ArchetypeTestHelpers)`
|
63
|
+
- removed `$CONFIG_GLYPHS_NAME`, `$CONFIG_GLYPHS_VERSION`, `$CONFIG_GLYPHS_SVG_ID`, `$CONFIG_GLYPHS_BASE_PATH`, `$CONFIG_GLYPHS_EOT`, `$CONFIG_GLYPHS_FILES`, `$CONFIG_GLYPHS_THRESHOLD`, `$CORE_GLYPHS_MAPPINGS`, `$CONFIG_GLYPHS_MAPPINGS` and instead merged these configs into `$CORE_GLYPHS_LIBRARIES` and `$CONFIG_GLYPHS_LIBRARIES`
|
64
|
+
- removed all RTL functions
|
65
|
+
- `styleguide-sprite*` and `styleguide-image*` functions have been replaced with private methods (`-archetype-sprite*`, `-archetype-image*`)
|
66
|
+
- ported many functions to ruby instead of defined as Sass user functions
|
67
|
+
- glyph icon mappings now take a map (optionally) of format `(char: characterCode, size: defaultSize)` (note that the previous list support is now deprecated)
|
68
|
+
- Archetype has now been split into smaller projects
|
69
|
+
- the core will provide the most widely used functions/mixins with much opinion on your generated CSS
|
70
|
+
- things that are more specialized, opinionated, or heavy-handed have been moved to extensions, these extensions currently include:
|
71
|
+
- `archetype-grid`
|
72
|
+
- `archetype-theme`
|
73
|
+
- `archetype-base`
|
74
|
+
- `archetype-base-h5bp`
|
75
|
+
- `archetype-base-normalize`
|
76
|
+
- `archetype-base-reset`
|
77
|
+
- `archetype-base-hybrid`
|
78
|
+
- the goal of this split is to provide consumers with the most useful and non-intrusive features upfront while still offering (via extension) the robustness we've already built
|
6
79
|
|
7
80
|
## 0.0.1.pre.3 (pre-released)
|
8
81
|
|
9
82
|
### New Features:
|
10
83
|
|
11
|
-
- added `styleguide-component-exists
|
84
|
+
- added `styleguide-component-exists` method to check if a component/extension has already been registered in the theme
|
12
85
|
- added `memoize` compiler configuration to allow enabling/disabling the internal styleguide memoizer
|
13
|
-
- `glyph-icon
|
14
|
-
- added `unstyled-button
|
15
|
-
- added `prefixed-tag
|
86
|
+
- `glyph-icon` can now take `false` as an icon name and not output anything
|
87
|
+
- added `unstyled-button` method to remove default styling from a `<button>` element
|
88
|
+
- added `prefixed-tag` method for consistency when generating tag names
|
16
89
|
- added Chinese font stacks
|
17
|
-
- added wildcard support to `locale
|
18
|
-
- added `transparent-focusable
|
19
|
-
- added ability to customize `output-style
|
20
|
-
- added better support for targeting IE6/7 glyphs and `ie-pseudo
|
21
|
-
-
|
22
|
-
-
|
23
|
-
-
|
90
|
+
- added wildcard support to `locale` function (e.g. `locale(en_ ja_JP _DE)`)
|
91
|
+
- added `transparent-focusable` mixin for transparent background support in older IE
|
92
|
+
- added ability to customize `output-style` with `custom-output-styler` mixin and `has-custom-output-styler` function (NEEDS DOCUMENTATION)
|
93
|
+
- added better support for targeting IE6/7 glyphs and `ie-pseudo` generated elements (NEEDS DOCUMENTATION)
|
94
|
+
- made `unique` generated IDs genuinely unique
|
95
|
+
- added support for a `testing` config flag
|
96
|
+
- added support for `@extend` from a styleguide component
|
24
97
|
|
25
98
|
### Resolved Issues:
|
26
99
|
|
27
|
-
- quotes on strings passed to `associative
|
100
|
+
- quotes on strings passed to `associative` weren't being stripped correctly
|
28
101
|
- fixed some minor glyph issues
|
29
102
|
- out-of-order CSS issues in Ruby 1.8.7 are fixed using `Hashery::OrderedHash`
|
30
|
-
- fixed issue with `archetype-version
|
103
|
+
- fixed issue with `archetype-version` incorrectly matching comparators
|
31
104
|
|
32
105
|
### Tests:
|
33
106
|
|
@@ -45,10 +118,10 @@
|
|
45
118
|
- added support for `drop` and `styleguide` keywords in components
|
46
119
|
- `drop` allows you to drop previously defined styles within a component definition (e.g. if you need to remove defaults)
|
47
120
|
- `styleguide` in a component definition will insert the derived styles from a styleguide() call. this allows you to share styles between components
|
48
|
-
- added `styleguide-diff
|
49
|
-
- added `ie-pseudo
|
50
|
-
- added `stroke
|
51
|
-
- added `hide-element
|
121
|
+
- added `styleguide-diff` method
|
122
|
+
- added `ie-pseudo` methods to support dynamically generating pseudo :before and :after elements (using expressions)
|
123
|
+
- added `stroke` mixin to create a stroke line around text (or font icon)
|
124
|
+
- added `hide-element` mixin to hide elements from screen but keep them screen-reader accessible
|
52
125
|
- added basic support for fallback CSS values (e.g. border: red; border: rgba(255,0,0, 0.8);)
|
53
126
|
- added `$CONFIG_STATE_MAPPINGS` to simplify the mapping between state names and selectors
|
54
127
|
|
@@ -56,13 +129,13 @@
|
|
56
129
|
|
57
130
|
- loading spinners now use CSS3 animations and require some integration work
|
58
131
|
- updated default vertical/horizontal spacing to 5px
|
59
|
-
- `list-extend
|
132
|
+
- `list-extend` is now `associative-merge`
|
60
133
|
|
61
134
|
### Resolved Issues:
|
62
135
|
|
63
136
|
- nested inheritance would get corrupted (due to a volatile context being passed along)
|
64
137
|
- `$exclude` in `to-styles` wasn't taking a list of keys cleanly
|
65
|
-
- `font-family
|
138
|
+
- `font-family` and `lang` weren't respecting locale aliases
|
66
139
|
- fixed thread safety issues
|
67
140
|
|
68
141
|
### Documentation:
|
@@ -75,15 +148,15 @@
|
|
75
148
|
|
76
149
|
### New Features:
|
77
150
|
|
78
|
-
- `styleguide-add-component
|
151
|
+
- `styleguide-add-component`, `styleguide-extend-component`, and `styleguide` now take a `$theme` parameter
|
79
152
|
- `$CONFIG_THEME` can change the global theme
|
80
153
|
- `$CONFIG_STYLEGUIDE_DISABLE_SPRITES` will prevent styleguide sprites from being generated if set to `true`
|
81
154
|
- theme components are cached
|
82
|
-
- `styleguide
|
155
|
+
- `styleguide` calls are memoized
|
83
156
|
|
84
157
|
### Major Changes:
|
85
158
|
|
86
|
-
- `filter
|
159
|
+
- `filter` mixin is now `ie-filter` to prevent conflicts with Compass' `filter` mixin
|
87
160
|
- Compass overrides are no longer loaded as Archetype core
|
88
161
|
|
89
162
|
### Resolved Issues:
|
data/README.md
CHANGED
@@ -1,8 +1,10 @@
|
|
1
1
|
# Archetype
|
2
2
|
|
3
|
-
[![Build Status](https://travis-ci.org/linkedin/archetype.
|
3
|
+
[![Build Status](https://api.travis-ci.org/linkedin/archetype.svg)](https://travis-ci.org/linkedin/archetype) [![Gem Version](https://badge.fury.io/rb/archetype.svg)](http://badge.fury.io/rb/archetype)
|
4
|
+
[![Dependency Status](https://gemnasium.com/eoneill/archetype.svg)](https://gemnasium.com/eoneill/archetype)
|
4
5
|
|
5
|
-
Archetype is a
|
6
|
+
Archetype is a Compass/Sass based framework for authoring configurable, composable UI components and patterns.
|
7
|
+
The natural language syntax that Archetype provides allows your designers and developers to discuss UI compositions using the same vocabulary.
|
6
8
|
|
7
9
|
## Resources
|
8
10
|
|
@@ -15,11 +17,15 @@ Archetype is a UI pattern and component library for quickly iterating on and mai
|
|
15
17
|
- [Discussion](https://github.com/eoneill/archetype/issues)
|
16
18
|
- [Archetype configuration](http://www.archetypecss.com/documentation/configuration/)
|
17
19
|
|
20
|
+
## Developing Archetype
|
21
|
+
|
22
|
+
If you're looking to contribute to Archetype, check out the [CONTRIBUTING](CONTRIBUTING.md) article.
|
23
|
+
|
18
24
|
## Installation
|
19
25
|
|
20
26
|
### Install the gem
|
21
27
|
|
22
|
-
```
|
28
|
+
```sh
|
23
29
|
[sudo] gem install archetype --pre
|
24
30
|
```
|
25
31
|
|
@@ -27,7 +33,7 @@ Instead of installing the gem directly via the command line, we recommend using
|
|
27
33
|
|
28
34
|
### Creating a new project with Archetype
|
29
35
|
|
30
|
-
```
|
36
|
+
```sh
|
31
37
|
compass create ~/workspace/your-project -r archetype --using archetype
|
32
38
|
```
|
33
39
|
|
@@ -82,6 +88,6 @@ This project couldn't have been made possible without the amazing work by the fo
|
|
82
88
|
|
83
89
|
- Dave Gandy for his awesome work on [FontAwesome](http://fortawesome.github.com/Font-Awesome/)
|
84
90
|
- Chris Eppstein and other contributors of [Compass](http://compass-style.org/) for building an amazing framework, and for some great scaffolding code we've _borrowed_
|
85
|
-
- Nathan Weizenbaum and contributors for [making CSS fun again](http://sass-lang.com/)
|
91
|
+
- Hampton Catlin, Nathan Weizenbaum, Chris Eppstein and contributors for [making CSS fun again](http://sass-lang.com/)
|
86
92
|
- Nicolas Gallagher and Jonathan Neal for some [Normalize.css](https://github.com/necolas/normalize.css) greatness
|
87
93
|
- Nicolas Gallagher, Jonathan Neal, Kroc Camen, Paul Irish, and others for [HTML5 Boilerplate](http://html5boilerplate.com/)
|
data/VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
1.0.0.alpha.1
|
data/lib/archetype.rb
CHANGED
@@ -4,26 +4,27 @@ require 'compass'
|
|
4
4
|
# Initialize Archetype and register it as a Compass extension
|
5
5
|
#
|
6
6
|
module Archetype
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
@archetype
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
7
|
+
NAME = 'archetype'
|
8
|
+
|
9
|
+
# info
|
10
|
+
@archetype = {
|
11
|
+
:name => NAME,
|
12
|
+
:path => File.expand_path(File.join(File.dirname(__FILE__), ".."))
|
13
|
+
}
|
14
|
+
|
15
15
|
# initialize Archetype
|
16
16
|
def self.init
|
17
|
-
|
18
|
-
|
19
|
-
|
17
|
+
## register it
|
18
|
+
register
|
19
|
+
|
20
|
+
## setup configs
|
20
21
|
# locale
|
21
22
|
Compass::Configuration.add_configuration_property(:locale, "the user locale") do
|
22
23
|
'en_US'
|
23
24
|
end
|
24
|
-
#
|
25
|
-
Compass::Configuration.add_configuration_property(:
|
26
|
-
|
25
|
+
# locale_aliases
|
26
|
+
Compass::Configuration.add_configuration_property(:locale_aliases, "a mapping of locale name aliases") do
|
27
|
+
{}
|
27
28
|
end
|
28
29
|
# environment
|
29
30
|
Compass::Configuration.add_configuration_property(:environment, "current environment") do
|
@@ -33,17 +34,28 @@ module Archetype
|
|
33
34
|
Compass::Configuration.add_configuration_property(:memoize, "should the memoizer be used to improve compilation speed") do
|
34
35
|
not (Compass.configuration.environment || :development).to_s.include?('dev')
|
35
36
|
end
|
36
|
-
#
|
37
|
-
Compass::Configuration.add_configuration_property(:
|
38
|
-
|
37
|
+
# meta
|
38
|
+
Compass::Configuration.add_configuration_property(:archetype_meta, "any meta data you want made available to the environment") do
|
39
|
+
{}
|
39
40
|
end
|
40
41
|
end
|
42
|
+
|
43
|
+
def self.name
|
44
|
+
NAME
|
45
|
+
end
|
46
|
+
|
47
|
+
private
|
48
|
+
|
49
|
+
## register as a Compass extension
|
50
|
+
def self.register
|
51
|
+
Compass::Frameworks.register(NAME, :path => @archetype[:path]);
|
52
|
+
end
|
41
53
|
end
|
42
54
|
|
43
55
|
# init
|
44
56
|
Archetype.init
|
45
57
|
|
46
58
|
# load dependencies
|
47
|
-
%w(functions sass_extensions).each do |lib|
|
59
|
+
%w(extensions functions sass_extensions).each do |lib|
|
48
60
|
require "archetype/#{lib}"
|
49
61
|
end
|
@@ -0,0 +1,152 @@
|
|
1
|
+
description = "Check a set of files for migration and back-compat issues"
|
2
|
+
if @description.nil?
|
3
|
+
DELIMITER = "\n "
|
4
|
+
DATA = {
|
5
|
+
'1.0.0.alpha.1' => {
|
6
|
+
:notice => %q{Archetype now requires Sass 3.3+ and Compass 0.13+},
|
7
|
+
:tests => {
|
8
|
+
:sacss => [
|
9
|
+
{
|
10
|
+
:pattern => /(gradient[_-]with[_-]deg|[_-]isLegacySupported)/m,
|
11
|
+
:message => 'mixin or function `$1` has been removed'
|
12
|
+
},
|
13
|
+
{
|
14
|
+
:pattern => /(?:\@include\s+|\+)(wrapper[_-]rtl|(?:padding|margin)(?:[_-](?:top|right|bottom|left))?|border(?:[_-](?:top|right|bottom|left))?[_-](?:width|color|style)|clear|float|text[_-]align|left|right|background[_-]position)\s*\(([^\)]*)/m,
|
15
|
+
:message => 'the RTL mixin `$1` has been deprecated, just use `$1: $2`'
|
16
|
+
},
|
17
|
+
{
|
18
|
+
:pattern => /(?:\@include\s+|\+)wrapper[_-]rtl/m,
|
19
|
+
:message => 'the RTL mixin `wrapper-rtl` has been deprecated'
|
20
|
+
},
|
21
|
+
{
|
22
|
+
:pattern => /[\:\s\(\{](rtl|reading[_-]direction)\s*\(/m,
|
23
|
+
:message => 'the RTL function `$1()` has been deprecated'
|
24
|
+
},
|
25
|
+
{
|
26
|
+
:pattern => /(?:styleguide[_-](?:add|extend)[_-]component)[^\;]*(inline-block)(?:\s+|\:)true/m,
|
27
|
+
:message => '`inline-block` has changed syntax within a styleguide component'
|
28
|
+
},
|
29
|
+
{
|
30
|
+
:pattern => /(?:styleguide[_-](?:add|extend)[_-]component)[^\;]*\s+\(?(gradient)(?:\s|\:)/m,
|
31
|
+
:message => 'use `background-image` instead of `$1` within your styleguide component'
|
32
|
+
},
|
33
|
+
{
|
34
|
+
:pattern => /(\$CONFIG_(?:STATE_MAPPINGS|BROWSER_VENDORS_HACK|OS_VENDORS_CLASS|SAFE_FONTS|LOADERS))\s*\:\s*\(\s*[^\:]+\s*\)(?: \!default)?\;/m,
|
35
|
+
:message => '`$1` is now a map structure instead of lists'
|
36
|
+
},
|
37
|
+
{
|
38
|
+
:pattern => /(?:(?:nth(?:-cyclic)?|associative)\s*\(\s*)(\$CONFIG_(?:STATE_MAPPINGS|BROWSER_VENDORS_HACK|OS_VENDORS_CLASS|SAFE_FONTS|LOADERS))/m,
|
39
|
+
:message => '`$1` is now a map structure instead of lists'
|
40
|
+
},
|
41
|
+
{
|
42
|
+
:pattern => /(\$CONFIG_GLYPHS_(?:NAME|VERSION|SVG_ID|BASE_PATH|EOT|FILES|THRESHOLD|MAPPINGS))/m,
|
43
|
+
:message => '`$1` is deprecated, use `register-glyph-library()` instead'
|
44
|
+
},
|
45
|
+
{
|
46
|
+
:pattern => /(\$CONFIG_GRID_DIRECTION)/m,
|
47
|
+
:message => '`$1` is deprecated'
|
48
|
+
},
|
49
|
+
{
|
50
|
+
:pattern => /(styleguide[_-]((?:sprite|image)(?:[_-][a-z]+)?))/m,
|
51
|
+
:message => '`$1` has been replaced with `-archetype-$2`'
|
52
|
+
},
|
53
|
+
{
|
54
|
+
:pattern => /(\$CONFIG_(?:KEYFRAMES|GLYPHS)_AUTO)/m,
|
55
|
+
:message => '`$1` has been deprecated, use `$CONFIG_RESET_AUTO` instead'
|
56
|
+
}
|
57
|
+
],
|
58
|
+
:rb => [],
|
59
|
+
:scss => [],
|
60
|
+
:sass => []
|
61
|
+
}
|
62
|
+
}
|
63
|
+
}
|
64
|
+
|
65
|
+
options = {
|
66
|
+
:from => ''
|
67
|
+
}
|
68
|
+
OptionParser.new do |opts|
|
69
|
+
opts.banner = description
|
70
|
+
opts.define_head "Usage: #{Archetype.name} migrate [path] [options]"
|
71
|
+
opts.separator ""
|
72
|
+
opts.separator "Example usage:"
|
73
|
+
opts.separator " archetype migrate /path/to/scss/ --from=0.0.1.alpha"
|
74
|
+
|
75
|
+
opts.on('-f', '--from VERSION', 'Archetype version migrating from') do |v|
|
76
|
+
options[:from] = v
|
77
|
+
end
|
78
|
+
|
79
|
+
opts.on('-h', '--help', 'shows this help message') do
|
80
|
+
puts opts
|
81
|
+
exit
|
82
|
+
end
|
83
|
+
|
84
|
+
if not @help.nil?
|
85
|
+
puts opts
|
86
|
+
exit
|
87
|
+
end
|
88
|
+
end.parse!
|
89
|
+
|
90
|
+
base = ARGV[1] || '.'
|
91
|
+
count = 0
|
92
|
+
files = {}
|
93
|
+
DATA.each do |version, obj|
|
94
|
+
if version > options[:from]
|
95
|
+
messages = []
|
96
|
+
messages << obj[:notice] if not obj[:notice].nil?
|
97
|
+
obj[:tests].each do |category, tests|
|
98
|
+
if not tests.nil? and not tests.empty?
|
99
|
+
ext = case category
|
100
|
+
when :rb
|
101
|
+
'.rb'
|
102
|
+
when :sass
|
103
|
+
'.sass'
|
104
|
+
when :scss
|
105
|
+
'.scss'
|
106
|
+
when :all
|
107
|
+
''
|
108
|
+
else
|
109
|
+
'.s[ac]ss'
|
110
|
+
end
|
111
|
+
|
112
|
+
Dir.glob(File.join(base, '**', "*#{ext}")) do |file|
|
113
|
+
contents = files[file]
|
114
|
+
message = []
|
115
|
+
|
116
|
+
tests.each do |test|
|
117
|
+
if contents.nil?
|
118
|
+
contents = ''
|
119
|
+
File.readlines(file).select do |line|
|
120
|
+
# strip off the comments and push it onto the contents
|
121
|
+
contents << line.gsub(/\s*((\/\/.*)|(\/\*(?!\*\/)?\*\/))/, '')
|
122
|
+
end
|
123
|
+
# cache the contents so we don't have to read it in again
|
124
|
+
files[file] = contents
|
125
|
+
end
|
126
|
+
|
127
|
+
if contents =~ test[:pattern]
|
128
|
+
contents.scan(test[:pattern]).each do |match|
|
129
|
+
message << test[:message].gsub(/\$1/, match[0] || '').gsub(/\$2/, match[1] || '')
|
130
|
+
count += 1
|
131
|
+
end
|
132
|
+
end
|
133
|
+
|
134
|
+
end
|
135
|
+
|
136
|
+
messages << "#{file}:#{DELIMITER}#{message.join(DELIMITER)}" unless message.empty?
|
137
|
+
end
|
138
|
+
end
|
139
|
+
end
|
140
|
+
puts "#{'='*20}\nv#{version}\n#{'-'*20}\n#{messages.join("\n\n")}" unless messages.empty?
|
141
|
+
end
|
142
|
+
end
|
143
|
+
|
144
|
+
if count > 0
|
145
|
+
puts "\n#{count} backward compatibility issue#{count > 1 ? 's' : ''} found!"
|
146
|
+
else
|
147
|
+
puts "\neverything else looks good!"
|
148
|
+
end
|
149
|
+
exit
|
150
|
+
else
|
151
|
+
@description = description
|
152
|
+
end
|