vivus 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +24 -8
- data/app/assets/stylesheets/vivus/core/mediaqueries.scss +0 -6
- data/lib/vivus/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3ba579c0104603530a05699aca452836ba2e2199
|
4
|
+
data.tar.gz: dcb10c4cf7ea92063e15d488e4bd8e6b2c7dc770
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: efaf0b8845ac29822e25b285a3d32a5065f1b727aa2c71eb7511dc40199e99e568ec45590a0cfc9718bbf067682cca2c0c3db7c4b33eca222c54a80030787f00
|
7
|
+
data.tar.gz: 87507c929e2c597e719b167757b8f333f954b24b8639c27709f2a1a9a5cff086f41a19e05aede9faaa3f3cbf115fd133aebae0b1d7b62a566b71d84715750790
|
data/README.md
CHANGED
@@ -1,12 +1,21 @@
|
|
1
|
-
# Vivus Styleguide
|
1
|
+
# Vivus Styleguide [<img src="https://travis-ci.org/markcipolla/vivus.svg?branch=master" />](https://travis-ci.org/markcipolla/vivus) [<img src="https://badge.fury.io/rb/vivus.svg" alt="Gem Version" height="18">](http://badge.fury.io/rb/vivus)
|
2
2
|
|
3
|
-
##
|
3
|
+
## Concept
|
4
4
|
|
5
5
|
Styleguides can be a pain to keep as a living documentation for your CSS.
|
6
6
|
|
7
|
+
The issue I had with various styleguide gems is that documenting your CSS in a not-hugely specific way is hard, and that keeping the HTML examples in another files means that there are three places your code needs to be updated and checked:
|
8
|
+
|
9
|
+
- In your CSS file,
|
10
|
+
- in your HTML Examples,
|
11
|
+
- and in the HTML that your app actually uses.
|
12
|
+
|
13
|
+
Too many times we'd had the styleguides become unusable as the HTML gets rewritten and the CSS updated.
|
14
|
+
|
7
15
|
By analysing the comments in your [SASS](http://sass-lang.com/) files, and by adding markdown to your stylesheets, you can generate a living, breathing documentation styleguide that has examples of how the CSS is used.
|
8
16
|
|
9
|
-
|
17
|
+
## Installation
|
18
|
+
Add this to your Gemfile:
|
10
19
|
```
|
11
20
|
gem 'vivus'
|
12
21
|
```
|
@@ -30,8 +39,11 @@ To document your CSS, use this as a template
|
|
30
39
|
Write some documentation explaining the use / concept of the CSS
|
31
40
|
you've got below. This bit will be markdown rendered.
|
32
41
|
|
42
|
+
This is optional, but really... why styleguide code you don't want
|
43
|
+
to document?
|
44
|
+
|
33
45
|
- You can use three backticks (`) to indicate a code block
|
34
|
-
-
|
46
|
+
- ```<div class="example"></div>```
|
35
47
|
- Code blocks will be syntax highlighted
|
36
48
|
|
37
49
|
When you've documented it nicely, use the Example markers to
|
@@ -41,12 +53,16 @@ Keeps your documentation right near the CSS.
|
|
41
53
|
So, if you update / refactor the CSS, update the HTML example if
|
42
54
|
need be.
|
43
55
|
|
44
|
-
[Example]
|
45
|
-
|
46
|
-
|
47
|
-
|
56
|
+
[Example]
|
57
|
+
<div class="example">
|
58
|
+
<p>This is optional, but kinda the point</p>
|
59
|
+
<a href="#" class="button">Some text</a>
|
60
|
+
</div>
|
48
61
|
[Url] A web address pointing to further documentation / example (optional)
|
49
62
|
*/
|
50
63
|
```
|
51
64
|
|
65
|
+
The only required ones are ```[Name]``` and ```[Section]```.
|
66
|
+
The rest are up to you to decide how much details you add.
|
67
|
+
|
52
68
|
This project rocks and uses MIT-LICENSE.
|
@@ -2,12 +2,6 @@
|
|
2
2
|
$media: "small";
|
3
3
|
}
|
4
4
|
|
5
|
-
// Below 320px add some optimisations to the small layout
|
6
|
-
//
|
7
|
-
@media only screen and (max-width: $tiny_max) {
|
8
|
-
@import "layouts/mediaqueries/tiny";
|
9
|
-
}
|
10
|
-
|
11
5
|
// This is the default layout (applied at the top of this file), but we re-define it here
|
12
6
|
// to ensure the $media variable is available and any special styles are added.
|
13
7
|
//
|
data/lib/vivus/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vivus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mark Cipolla
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-04-
|
11
|
+
date: 2014-04-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|