shipd_style 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (59) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +25 -0
  3. data/.ruby-gemset +1 -0
  4. data/.ruby-version +1 -0
  5. data/Gemfile +3 -0
  6. data/Gemfile.lock +37 -0
  7. data/LICENSE.txt +22 -0
  8. data/README.md +140 -0
  9. data/Rakefile +2 -0
  10. data/config.rb +25 -0
  11. data/demo/carousel.html +79 -0
  12. data/demo/desktop-styles.html +80 -0
  13. data/demo/dialog.html +143 -0
  14. data/demo/index.html +63 -0
  15. data/demo/mobile-styles.html +253 -0
  16. data/demo/responsive-columns.html +87 -0
  17. data/demo/tablet-styles.html +79 -0
  18. data/lib/sass/_shipd-variables.scss +6 -0
  19. data/lib/sass/desktop/_button-form-elements.scss +15 -0
  20. data/lib/sass/desktop/_grid.scss +37 -0
  21. data/lib/sass/desktop/_layout-elements.scss +10 -0
  22. data/lib/sass/desktop/_typography.scss +6 -0
  23. data/lib/sass/desktop/_variable_overrides.scss +2 -0
  24. data/lib/sass/desktop/_variables.scss +2 -0
  25. data/lib/sass/mobile/_grid.scss +41 -0
  26. data/lib/sass/mobile/_oo-styles.scss +218 -0
  27. data/lib/sass/mobile/_typography.scss +50 -0
  28. data/lib/sass/mobile/widgets/_buttons.scss +134 -0
  29. data/lib/sass/mobile/widgets/_carousel.scss +16 -0
  30. data/lib/sass/mobile/widgets/_dialog-overlay.scss +37 -0
  31. data/lib/sass/mobile/widgets/_form-elements.scss +80 -0
  32. data/lib/sass/mobile/widgets/_header.scss +6 -0
  33. data/lib/sass/mobile/widgets/_page-layout.scss +9 -0
  34. data/lib/sass/shipd-all.scss +9 -0
  35. data/lib/sass/shipd-desktop.scss +9 -0
  36. data/lib/sass/shipd-mobile.scss +20 -0
  37. data/lib/sass/shipd-tablet.scss +9 -0
  38. data/lib/sass/tablet/_button-form-elements.scss +15 -0
  39. data/lib/sass/tablet/_grid.scss +39 -0
  40. data/lib/sass/tablet/_layout-elements.scss +15 -0
  41. data/lib/sass/tablet/_typography.scss +6 -0
  42. data/lib/sass/tablet/_variable_overrides.scss +2 -0
  43. data/lib/sass/tablet/_variables.scss +2 -0
  44. data/lib/sass/variables/_colors.scss +43 -0
  45. data/lib/sass/variables/_font.scss +7 -0
  46. data/lib/sass/variables/_form_spacing.scss +4 -0
  47. data/lib/sass/variables/_misc.scss +5 -0
  48. data/lib/sass/variables/_mixins.scss +45 -0
  49. data/lib/sass/variables/_spacing.scss +4 -0
  50. data/lib/shipd_style/copy_stylesheets.rb +16 -0
  51. data/lib/shipd_style/shipd_style.rake +9 -0
  52. data/lib/shipd_style/tasks.rb +3 -0
  53. data/lib/shipd_style/version.rb +3 -0
  54. data/lib/shipd_style.rb +5 -0
  55. data/lib/templates/carousel.html +6 -0
  56. data/lib/templates/dialog.html +15 -0
  57. data/lib/templates/page-layout.html +4 -0
  58. data/shipd_style.gemspec +25 -0
  59. metadata +144 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 1fcfe4745e1adb96b630b5135a75b3d32c9ba94b
4
+ data.tar.gz: cf6f72cdde22a71e86a18040c35c9b6cdecf2ef8
5
+ SHA512:
6
+ metadata.gz: 154e4ed8c34022be1cee9e897be249c98906cbd98be1b85e2597f4436e726b36921219109682a42fcb799e5a9aae08461cd538a60a6fa5ef2172a8f722edd14d
7
+ data.tar.gz: 441a3f6b33cdd0f8637e9cb42f9826136ca3c6297c89d1d6d01e4ddd802c58256fb05f34d57bf3accb57c34c36dcbf2e615eef8b8f2c925f191993f4d1fe7097
data/.gitignore ADDED
@@ -0,0 +1,25 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
18
+ *.bundle
19
+ *.so
20
+ *.o
21
+ *.a
22
+ mkmf.log
23
+
24
+ .sass-cache/
25
+ lib/sass/*.css
data/.ruby-gemset ADDED
@@ -0,0 +1 @@
1
+ shipd-style
data/.ruby-version ADDED
@@ -0,0 +1 @@
1
+ 2.1.2
data/Gemfile ADDED
@@ -0,0 +1,3 @@
1
+ source "https://rubygems.org"
2
+
3
+ gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,37 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ shipd_style (0.1.0)
5
+ compass
6
+
7
+ GEM
8
+ remote: https://rubygems.org/
9
+ specs:
10
+ chunky_png (1.3.3)
11
+ compass (1.0.3)
12
+ chunky_png (~> 1.2)
13
+ compass-core (~> 1.0.2)
14
+ compass-import-once (~> 1.0.5)
15
+ rb-fsevent (>= 0.9.3)
16
+ rb-inotify (>= 0.9)
17
+ sass (>= 3.3.13, < 3.5)
18
+ compass-core (1.0.3)
19
+ multi_json (~> 1.0)
20
+ sass (>= 3.3.0, < 3.5)
21
+ compass-import-once (1.0.5)
22
+ sass (>= 3.2, < 3.5)
23
+ ffi (1.9.6)
24
+ multi_json (1.10.1)
25
+ rake (10.1.0)
26
+ rb-fsevent (0.9.4)
27
+ rb-inotify (0.9.5)
28
+ ffi (>= 0.5.0)
29
+ sass (3.4.11)
30
+
31
+ PLATFORMS
32
+ ruby
33
+
34
+ DEPENDENCIES
35
+ bundler (~> 1.6)
36
+ rake
37
+ shipd_style!
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2015 Kane Baccigalupi
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,140 @@
1
+ # Shipd Style
2
+
3
+ Shipd Style is a gem for building responsive web design. It can be used on its own, but it is also a component of the front end framework: [Prow](https://github.com/shipd/prow) which allows a full-extensible front-end build out without the need of a server.
4
+
5
+ Ship has a series of HTML demonstration pages for checking out all the responsive CSS3 goodness that Shipd Style has to offer.
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile:
10
+
11
+ gem 'shipd_style'
12
+
13
+ And then execute:
14
+
15
+ $ bundle
16
+
17
+ Or install it yourself as:
18
+
19
+ $ gem install 'shipd_style'
20
+
21
+ ## Usage
22
+
23
+ ### Compass with Copied files
24
+
25
+ ShipdStyle is available as a compass plugin, but the goal of ShipdStyle is for
26
+ the developer to have a good baseline on which to really own the responsive styles. Also, compass has a funky file locator that makes in really hard to get
27
+ to all the great modular partials that make ShipdStyle the modular framework that it is.
28
+
29
+ ShipdStyle therefore comes with some rake files to copy the base files into your
30
+ project.
31
+
32
+ rake shipd_style:copy_styles
33
+
34
+ Alternatively you can pass in a directory:
35
+
36
+ rake shipd_style:copy_styles[app/assets/stylesheets]
37
+
38
+ Compass can then take on the heavy lifting of compiling these files without worrying about the plugin:
39
+
40
+ compass compile
41
+
42
+ # -- or --
43
+
44
+ compass watch
45
+
46
+ Compass comes with a great many options and configurations. It is the source of truth when using it with these styles.
47
+
48
+ ### As a Compass project using ShipdStyle as a plugin:
49
+
50
+ Make a directory:
51
+
52
+ mkdir my_styles
53
+
54
+ Add a Gemfile with just the shipd_style gem:
55
+
56
+ source 'https://rubygems.org'
57
+
58
+ gem 'shipd_style'
59
+
60
+ ShipdStyle includes the compass dependency, so no need to add that.
61
+ Run the compass command to create a directory structure:
62
+
63
+ compass init
64
+
65
+ Import the files into your projects scss file. The compass default gives you
66
+ a screen.scss file to work with. Shipd uses mobile, tablet and desktop stylesheets. There are basic styles and then there are style sheets per widget. The the easy load stylesheets on the top level include everything.
67
+
68
+ @import "shipd-mobile"; // include all styles mobile
69
+ @import "shipd-tablet"; // includes progressive modifications for tablet
70
+ @import "shipd-desktop"; // includes progressive additions for desktop
71
+
72
+ // @import "shipd-all"; // one stylesheet that includes all three
73
+
74
+ // @import "mobile/grid"; // just pick and choose the ones you want!
75
+
76
+
77
+ Compile stylesheets with the 'shipd_style' plugin required:
78
+
79
+ compass compile -r shipd_style
80
+
81
+ Watch your library and have it automatically compile with this command:
82
+
83
+ compass watch -r shipd_style
84
+
85
+ Compass is a vast framework with any number of great command line options for
86
+ building exactly the stylesheets desired.
87
+
88
+ ### Use with Rails
89
+
90
+
91
+ ## Concepts
92
+
93
+ Getting CSS right for a responsive design that really looks different on different devices can be quite tedious. Over the last three years, we have reinventing this wheel again and again. It is now smaller, rounder and easier to use than ever.
94
+
95
+ ### Life without Responsive Design
96
+ Shipd Style is inspired by Stubornella's great framework [OOCSS](https://github.com/stubornella/oocss). We grabbed some of her core concepts about grids, single responsibility classes and divs, and we ran with it. It may be nothing like what she would recognize, but here are our guiding principles, which when mastered, make for great productivity:
97
+
98
+ __Rows & Units__
99
+ Layouts are broken into `.row`s. These rows contain any number of elements that float around, either left or right.
100
+
101
+ __IMPORTANT:__ _Rows and units can't have padding or margin._ Instead there divs are single responsibility, having either this row/unit width characteristic ... or they have padding and margin.
102
+
103
+ A typical structure looks like this:
104
+
105
+ <div class='row'>
106
+ <div class='inner border'>
107
+ <div class='unit size-1-2'>1/2 sized</div>
108
+ <div class='unit size-1-3'>1/3 sized</div>
109
+ <div class='unit-last'>the rest</div>
110
+ </div>
111
+ </div>
112
+
113
+ The row has an `inner` that provides padding. That div that also has a border. Borders take up width. Instead of doing lots of crazy CSS math that goes wrong all the time, padding, margin, outline and border goes on another div ... single responsibility divs.
114
+
115
+ ### Getting Responsive
116
+ This is all grand, but it happens often that we want a row in mobile view to be a 1/2 sized column in tablet, and 1/3 sized in desktop. Shipd Styles to the rescue. It turns out there are styles to do just that:
117
+
118
+ <div class='m-row t-unit d-unit t-size-1-2 d-size-1-3'>
119
+ <div class='m-row t-hidden d-hidden'>
120
+ I'm a mobile row
121
+ </div>
122
+ <div class='m-hidden t-row d-hidden'>
123
+ I'm a tablet half sized column
124
+ </div>
125
+ <div class='m-hidden t-hidden d-row'>
126
+ I'm a desktop 1/3 sized column
127
+ </div>
128
+ </div>
129
+
130
+ In this example, there is different content per layout that is hidden via some convenient styles. Completely different content per layout should be reserved for changing the order of content, or totally different content.
131
+
132
+ Full documentation of all the classes coming soon.
133
+
134
+ ## Contributing
135
+
136
+ 1. Fork it ( https://github.com/shipd/shipd-style/fork )
137
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
138
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
139
+ 4. Push to the branch (`git push origin my-new-feature`)
140
+ 5. Create a new Pull Request
data/Rakefile ADDED
@@ -0,0 +1,2 @@
1
+ require "bundler/gem_tasks"
2
+ import "lib/shipd_style/shipd_style.rake" # for testing
data/config.rb ADDED
@@ -0,0 +1,25 @@
1
+ require 'compass/import-once/activate'
2
+ # Require any additional compass plugins here.
3
+
4
+ # Set this to the root of your project when deployed:
5
+ http_path = "/"
6
+ css_dir = "stylesheets"
7
+ sass_dir = "sass"
8
+ images_dir = "images"
9
+ javascripts_dir = "javascripts"
10
+
11
+ # You can select your preferred output style here (can be overridden via the command line):
12
+ # output_style = :expanded or :nested or :compact or :compressed
13
+
14
+ # To enable relative paths to assets via compass helper functions. Uncomment:
15
+ relative_assets = true
16
+
17
+ # To disable debugging comments that display the original location of your selectors. Uncomment:
18
+ # line_comments = false
19
+
20
+
21
+ # If you prefer the indented syntax, you might want to regenerate this
22
+ # project again passing --syntax sass, or you can uncomment this:
23
+ # preferred_syntax = :sass
24
+ # and then run:
25
+ # sass-convert -R --from scss --to sass sass scss && rm -rf sass && mv scss sass
@@ -0,0 +1,79 @@
1
+ <!DOCTYPE HTML>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>Shipd Style - Carousel</title>
6
+ <meta name="viewport" content="initial-scale=1">
7
+ <link href="/favicon.ico" rel="shortcut icon" type="image/ico">
8
+ <link rel="stylesheet" href="../stylesheets/mobile.css">
9
+ <link rel="stylesheet" href="../stylesheets/tablet.css" media="screen and (min-width: 768px)">
10
+ <link rel="stylesheet" href="../stylesheets/desktop.css" media="screen and (min-width: 1024px)">
11
+ <link href='http://fonts.googleapis.com/css?family=Port+Lligat+Slab' rel='stylesheet' type='text/css'>
12
+
13
+ <style>
14
+ .my-carousel {
15
+ height: 300px;
16
+ }
17
+ </style>
18
+
19
+ <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
20
+
21
+ <script>
22
+ var setupcarousel = function() {
23
+ var slideWidth = $('.current-slide').width();
24
+ $('.current-slide').css({left: 0});
25
+ $('.next-slide').css({left: slideWidth});
26
+ };
27
+
28
+ var movecarouselLeft = function() {
29
+ var slideWidth = $('.current-slide').width();
30
+ $('.current-slide').css({left: -slideWidth});
31
+ $('.next-slide').css({left: 0});
32
+ $('.move-carousel-left').css({visibility: 'hidden'});
33
+ };
34
+
35
+ $(document).ready(function() {
36
+ setupcarousel();
37
+ $('.move-carousel-left').on('click', movecarouselLeft);
38
+ });
39
+ </script>
40
+ </head>
41
+ <body>
42
+ <div id="page">
43
+ <div class='inner'>
44
+ <div class='row'>
45
+ <h1 class='centered-content'>
46
+ <div class='unit size-1-3 move-carousel-left pointer-cursor'>&laquo;</div>
47
+ <div class='unit size-1-3'>Carousel</div>
48
+ <div class='unit size-1-3 move-carousel-right pointer-cursor'>&nbsp;<!--&raquo;--></div>
49
+ </h1>
50
+ </div>
51
+
52
+ <div class='spacer'></div>
53
+
54
+ <div class='carousel-container my-carousel row'>
55
+ <div class='carousel-window'>
56
+ <div class='carousel-slide background-accent current-slide'>
57
+ <h1 class='inner centered-content'>1</h1>
58
+ </div>
59
+ <div class='carousel-slide background-accent-2 next-slide'>
60
+ <h1 class='inner centered-content'>2</h1>
61
+ </div>
62
+ </div>
63
+ </div>
64
+
65
+ <p>
66
+ Because the carousel uses absolute and relative positioning,
67
+ you must set an explicit height on the .carousel-container.
68
+ Best practices dictates adding a class specific to your instance
69
+ of the carousel usage: such as a class 'my-great-carousel'.
70
+ Then the height is applied to the custom class, not all carousel objects.
71
+ </p>
72
+
73
+ <p>
74
+ The carousel requires some JS to set it in motion.
75
+ The transitions and positioning are pure CSS, but the triggering of the change position happens via JS.
76
+ </p>
77
+ </div>
78
+ </div>
79
+ </body>
@@ -0,0 +1,80 @@
1
+ <!DOCTYPE HTML>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>Shipd Style - Desktop Styles</title>
6
+ <meta name="viewport" content="initial-scale=1">
7
+ <link href="/favicon.ico" rel="shortcut icon" type="image/ico">
8
+ <link rel="stylesheet" href="../stylesheets/mobile.css">
9
+ <link rel="stylesheet" href="../stylesheets/tablet.css" media="screen and (min-width: 768px)">
10
+ <link rel="stylesheet" href="../stylesheets/desktop.css" media="screen and (min-width: 1024px)">
11
+ <link href='http://fonts.googleapis.com/css?family=Port+Lligat+Slab' rel='stylesheet' type='text/css'>
12
+ </head>
13
+ <body>
14
+ <div id="page">
15
+ <div id='header' class='row'>
16
+ <div class='inner overflown'>
17
+ <h1 class='unit'>Logo Land</h1>
18
+ <div class='unit spacer'></div>
19
+ <h4 class='unit-right'>menu?</h4>
20
+ </div>
21
+ </div>
22
+
23
+ <div class='inner'>
24
+ <h1>Hello Shippers - Welcome to Tablet View</h1>
25
+
26
+ <p>Life is pretty good as we are progressively enhancing the mobile view.</p>
27
+ <p>You have some extra styles.</p>
28
+ <ul class='bullet-list'>
29
+ <li>
30
+ t-size-X-X: Where 'X' is a number indicating size.
31
+ These are like the base case sizes: size-X-X.
32
+ The main differences is that these styles are provided for those cases
33
+ where you need a different layout of the same elements in mobile and tablet.
34
+ </li>
35
+ </ul>
36
+
37
+ <p>Also, the base sizes for text have been modified slightly for better usage on tablet</p>
38
+
39
+ <h1>h1: Hello World</h1>
40
+ <h2>h2: Hello World</h2>
41
+ <h3>h3: Hello World</h3>
42
+ <h4>h4: Hello World</h4>
43
+ <h5>h5: Hello World</h5>
44
+ <h6>h6: Hello World</h6>
45
+ <p>p: Hello World</p>
46
+ <div>div: Hello World</div>
47
+
48
+ <h1>Form Elements</h1>
49
+ <form>
50
+ <div class='inner border rounded'>
51
+ <div class='row'>
52
+ <div class='input-container'>
53
+ <input type="text" placeholder="hello"/>
54
+ </div>
55
+ </div>
56
+ <div class='row error'>
57
+ <h6 class='error-message'>Oh, holy error, batgirl!</h6>
58
+ <div class='input-container'>
59
+ <input type="text" placeholder="hello"/>
60
+ </div>
61
+ </div>
62
+ <div class='row'>
63
+ <div class='input-container'>
64
+ <textarea placeholder="hello"></textarea>
65
+ </div>
66
+ <h6 class='error-message'>Oh, holy error, batgirl!</h6>
67
+ </div>
68
+
69
+ <div class='row'>
70
+ <div class='unit size1of3'>
71
+ <div class='shadow-container'>
72
+ <a class='button'>Link Button</a>
73
+ </div>
74
+ </div>
75
+ </div>
76
+ </div>
77
+ </form>
78
+ </div>
79
+ </div>
80
+ </body>
data/demo/dialog.html ADDED
@@ -0,0 +1,143 @@
1
+ <!DOCTYPE HTML>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>Shipd Style - Dialog with Overlay</title>
6
+ <meta name="viewport" content="initial-scale=1">
7
+ <link href="/favicon.ico" rel="shortcut icon" type="image/ico">
8
+ <link rel="stylesheet" href="../stylesheets/mobile.css">
9
+ <link rel="stylesheet" href="../stylesheets/tablet.css" media="screen and (min-width: 768px)">
10
+ <link rel="stylesheet" href="../stylesheets/desktop.css" media="screen and (min-width: 1024px)">
11
+ <link href='http://fonts.googleapis.com/css?family=Port+Lligat+Slab' rel='stylesheet' type='text/css'>
12
+
13
+ <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
14
+
15
+ <style>
16
+ @media (min-width: 768px) {
17
+ .column-inner {
18
+ padding-left: 5px;
19
+ padding-right: 5px;
20
+ }
21
+
22
+ .layout-inner {
23
+ padding: 15px 10px;
24
+ }
25
+ }
26
+ </style>
27
+
28
+ <script>
29
+ var resizeOverlay = function() {
30
+ var height = $(document).height();
31
+ $('#overlay').height(height);
32
+ };
33
+
34
+ var hideDialog = function() {
35
+ $('#overlay').addClass("transparent");
36
+
37
+ setTimeout(function() {
38
+ $('#overlay').addClass('hidden');
39
+ $('.dialog-container').remove();
40
+ }, 1000);
41
+
42
+ setTimeout(function() {
43
+ $('.dialog-container').addClass('transparent');
44
+ }, 250);
45
+ };
46
+
47
+ $(document).ready(function() {
48
+ // animate in all the components
49
+ $('#overlay').removeClass('hidden').removeClass('transparent');
50
+ setTimeout(function() {
51
+ $('.dialog-container').removeClass('transparent');
52
+ }, 250);
53
+
54
+ $(window).on('resize orientationchange', resizeOverlay);
55
+ $('.close-dialog').click(hideDialog);
56
+ });
57
+ </script>
58
+ </head>
59
+ <body>
60
+ <div id='overlay' class='hidden transparent'>
61
+ <div class='dialog-container transparent'>
62
+ <div class='inner dialog-inner'>
63
+ <div class='dialog inner border rounded'>
64
+ <div class="close-dialog close-x">&times;</div>
65
+ <h1 class='inner-bottom'>Hello Dialog!</h1>
66
+ <p>
67
+ Sadly, mobile does not consistently handle fixed position elements.
68
+ So, it is recommended that you supplement this CSS with JS that inspects the page
69
+ size after load and increases the overlay height.
70
+ </p>
71
+ <p>
72
+ You kind of need JS to close a dialog anyway, with CSS transitions too.
73
+ </p>
74
+ <div class='unit'>
75
+ <div class='shadow-container'>
76
+ <a class='button close-dialog'>Ok then!</a>
77
+ </div>
78
+ </div>
79
+ </div>
80
+ </div>
81
+ </div>
82
+ </div>
83
+ <div id="page">
84
+ <div class='inner layout-inner'>
85
+ <div class='layout-inner inner'>
86
+ <h1 class="t-hidden d-hidden">Mobile View</h1>
87
+ <h1 class="m-hidden d-hidden">Tablet View</h1>
88
+ <h1 class="m-hidden t-hidden">Desktop View</h1>
89
+ </div>
90
+
91
+ <div class='m-row t-unit t-size-1-2 d-unit d-size-1-3'>
92
+ <div class='block column-inner'>
93
+ <div class='inner border rounded'>
94
+ <h4>Section 1</h4>
95
+ <p>
96
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo nisi ullamcorper velit gravida consectetur. Mauris cursus posuere urna eu aliquam. Aenean metus nulla, ullamcorper vel faucibus a, vulputate ac dui. Phasellus tempor dignissim odio, vel lacinia turpis dapibus a. In hac habitasse platea dictumst. Donec purus erat, fermentum sit amet maximus eu, gravida vitae ex. Ut sed lectus vitae turpis vulputate tincidunt. Pellentesque non egestas lacus, non porttitor dui. Aliquam volutpat lacus eget orci tincidunt, sit amet accumsan neque facilisis.
97
+ </p><p>
98
+ Nam quis ante non velit egestas venenatis. Praesent eleifend ante quis metus venenatis, dictum pharetra justo pretium. Vestibulum vitae egestas sem, ut iaculis massa. Donec sit amet erat in mi commodo commodo. Sed non diam in leo feugiat congue. Mauris tempus non arcu vitae malesuada. Maecenas non diam ac urna imperdiet hendrerit porttitor et felis. Sed ipsum ipsum, placerat ac diam eget, malesuada faucibus enim. Vivamus viverra, urna sed feugiat bibendum, ante mi hendrerit lorem, sit amet maximus diam justo ut est. In sollicitudin quis purus vel fringilla.
99
+ </p><p>
100
+ Vivamus porta luctus massa eu bibendum. Sed sodales vulputate efficitur. Phasellus semper tempor nisi in convallis. Cras dapibus fringilla odio sed fringilla. Phasellus a fringilla urna. Nunc vulputate viverra imperdiet. Suspendisse molestie, neque non auctor viverra, odio arcu volutpat ligula, sed pellentesque felis ante nec velit. Sed semper eleifend elit, vel eleifend nunc gravida at. Morbi ornare a nulla a rhoncus. Quisque dignissim dolor eget lorem ullamcorper auctor.
101
+ </p><p>
102
+ In sit amet orci et lectus tempor vehicula eu et augue. Quisque id est eleifend, tempor justo et, molestie nibh. Phasellus mattis hendrerit ultricies. Donec nec eros sed est euismod consequat. Nulla facilisi. Nulla quis semper turpis. Morbi vitae pellentesque risus. Vestibulum sodales, ante at imperdiet pulvinar, ipsum justo laoreet ex, non viverra metus nunc quis nunc.
103
+ </p>
104
+ </div>
105
+ </div>
106
+ </div>
107
+ <div class='spacer t-hidden d-hidden m-row'></div>
108
+ <div class='m-row t-unit t-size-1-2 d-unit d-size-1-3'>
109
+ <div class='block column-inner'>
110
+ <div class='inner border rounded'>
111
+ <h4>Section 2</h4>
112
+ <p>
113
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo nisi ullamcorper velit gravida consectetur. Mauris cursus posuere urna eu aliquam. Aenean metus nulla, ullamcorper vel faucibus a, vulputate ac dui. Phasellus tempor dignissim odio, vel lacinia turpis dapibus a. In hac habitasse platea dictumst. Donec purus erat, fermentum sit amet maximus eu, gravida vitae ex. Ut sed lectus vitae turpis vulputate tincidunt. Pellentesque non egestas lacus, non porttitor dui. Aliquam volutpat lacus eget orci tincidunt, sit amet accumsan neque facilisis.
114
+ </p><p>
115
+ Nam quis ante non velit egestas venenatis. Praesent eleifend ante quis metus venenatis, dictum pharetra justo pretium. Vestibulum vitae egestas sem, ut iaculis massa. Donec sit amet erat in mi commodo commodo. Sed non diam in leo feugiat congue. Mauris tempus non arcu vitae malesuada. Maecenas non diam ac urna imperdiet hendrerit porttitor et felis. Sed ipsum ipsum, placerat ac diam eget, malesuada faucibus enim. Vivamus viverra, urna sed feugiat bibendum, ante mi hendrerit lorem, sit amet maximus diam justo ut est. In sollicitudin quis purus vel fringilla.
116
+ </p><p>
117
+ Vivamus porta luctus massa eu bibendum. Sed sodales vulputate efficitur. Phasellus semper tempor nisi in convallis. Cras dapibus fringilla odio sed fringilla. Phasellus a fringilla urna. Nunc vulputate viverra imperdiet. Suspendisse molestie, neque non auctor viverra, odio arcu volutpat ligula, sed pellentesque felis ante nec velit. Sed semper eleifend elit, vel eleifend nunc gravida at. Morbi ornare a nulla a rhoncus. Quisque dignissim dolor eget lorem ullamcorper auctor.
118
+ </p><p>
119
+ In sit amet orci et lectus tempor vehicula eu et augue. Quisque id est eleifend, tempor justo et, molestie nibh. Phasellus mattis hendrerit ultricies. Donec nec eros sed est euismod consequat. Nulla facilisi. Nulla quis semper turpis. Morbi vitae pellentesque risus. Vestibulum sodales, ante at imperdiet pulvinar, ipsum justo laoreet ex, non viverra metus nunc quis nunc.
120
+ </p>
121
+ </div>
122
+ </div>
123
+ </div>
124
+ <div class='spacer d-hidden m-row t-row'></div>
125
+ <div class='m-row t-unit t-size-1-2 d-unit d-size-1-3'>
126
+ <div class='block column-inner'>
127
+ <div class='inner border rounded'>
128
+ <h4>Section 3</h4>
129
+ <p>
130
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo nisi ullamcorper velit gravida consectetur. Mauris cursus posuere urna eu aliquam. Aenean metus nulla, ullamcorper vel faucibus a, vulputate ac dui. Phasellus tempor dignissim odio, vel lacinia turpis dapibus a. In hac habitasse platea dictumst. Donec purus erat, fermentum sit amet maximus eu, gravida vitae ex. Ut sed lectus vitae turpis vulputate tincidunt. Pellentesque non egestas lacus, non porttitor dui. Aliquam volutpat lacus eget orci tincidunt, sit amet accumsan neque facilisis.
131
+ </p><p>
132
+ Nam quis ante non velit egestas venenatis. Praesent eleifend ante quis metus venenatis, dictum pharetra justo pretium. Vestibulum vitae egestas sem, ut iaculis massa. Donec sit amet erat in mi commodo commodo. Sed non diam in leo feugiat congue. Mauris tempus non arcu vitae malesuada. Maecenas non diam ac urna imperdiet hendrerit porttitor et felis. Sed ipsum ipsum, placerat ac diam eget, malesuada faucibus enim. Vivamus viverra, urna sed feugiat bibendum, ante mi hendrerit lorem, sit amet maximus diam justo ut est. In sollicitudin quis purus vel fringilla.
133
+ </p><p>
134
+ Vivamus porta luctus massa eu bibendum. Sed sodales vulputate efficitur. Phasellus semper tempor nisi in convallis. Cras dapibus fringilla odio sed fringilla. Phasellus a fringilla urna. Nunc vulputate viverra imperdiet. Suspendisse molestie, neque non auctor viverra, odio arcu volutpat ligula, sed pellentesque felis ante nec velit. Sed semper eleifend elit, vel eleifend nunc gravida at. Morbi ornare a nulla a rhoncus. Quisque dignissim dolor eget lorem ullamcorper auctor.
135
+ </p><p>
136
+ In sit amet orci et lectus tempor vehicula eu et augue. Quisque id est eleifend, tempor justo et, molestie nibh. Phasellus mattis hendrerit ultricies. Donec nec eros sed est euismod consequat. Nulla facilisi. Nulla quis semper turpis. Morbi vitae pellentesque risus. Vestibulum sodales, ante at imperdiet pulvinar, ipsum justo laoreet ex, non viverra metus nunc quis nunc.
137
+ </p>
138
+ </div>
139
+ </div>
140
+ </div>
141
+ </div>
142
+ </div>
143
+ </body>
data/demo/index.html ADDED
@@ -0,0 +1,63 @@
1
+ <!DOCTYPE HTML>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <title>Shipd Style - Demonstration</title>
6
+ <meta name="viewport" content="initial-scale=1">
7
+ <link href="/favicon.ico" rel="shortcut icon" type="image/ico">
8
+ <link rel="stylesheet" href="../stylesheets/mobile.css">
9
+ <link rel="stylesheet" href="../stylesheets/tablet.css" media="screen and (min-width: 768px)">
10
+ <link rel="stylesheet" href="../stylesheets/desktop.css" media="screen and (min-width: 1024px)">
11
+ <link href='http://fonts.googleapis.com/css?family=Port+Lligat+Slab' rel='stylesheet' type='text/css'>
12
+ </head>
13
+ <body>
14
+ <div id="page">
15
+ <div class='inner'>
16
+ <div class='unit m-row t-size-3-5 d-size-2-3'>
17
+ <div class="block inner-right">
18
+ <h1>Do it Shipd Style!</h1>
19
+ <hr>
20
+ <p>
21
+ <em><a href="https://github.com/shipd/shipd-style" target='_blank'>Shipd Style</a></em>
22
+ is a responsive design CSS framework. It is culled from 3 years of repeatedly crafting
23
+ mobile first designs, that layered on tablet and desktop functionality. With several great organizations,
24
+ we reinvented this wheel. Each time it got more round and simple.
25
+ </p>
26
+
27
+ <p>
28
+ The framework foundation is based on Stubornella's awesome
29
+ <a href="https://github.com/stubbornella/oocss" target="_blank">OOCSS</a>, which
30
+ separates concerns of box width from those of box padding &amp; margin. This makes
31
+ dealing with the IE box model differences pretty trivial. Developers
32
+ need to get in the habit and discipline of always creating a nested div for padding,
33
+ border and margin. But once that habit is well understood, designing is easy.
34
+ </p>
35
+
36
+ <p>
37
+ On top of that box model and grid managment system, we added a responsive design framework.
38
+ There are a set of sizes defined for the base case (mobile), and then additional sizes for
39
+ tablet and desktop. Front-end developers can change the size of element per layout. In mobile,
40
+ a container can show up at the bottom of the page, and in other layouts it can be a side-menu.
41
+ This page is one of those examples. The basic work can be done with markup and styling classes
42
+ alone.
43
+ </p>
44
+ </div>
45
+ </div>
46
+ <div class='m-row unit-right t-size-2-5 d-size-1-3 right'>
47
+ <div class='spacer m-hidden t-unit d-unit'></div>
48
+ <hr class='t-hidden d-hidden'>
49
+ <div class='unit'>
50
+ <h3>Demonstration Pages</h3>
51
+ <ul>
52
+ <li><a href="mobile-styles.html">Mobile Type &amp; Widgets</a></li>
53
+ <li><a href="tablet-styles.html">Tablet Type &amp; Widgets</a></li>
54
+ <li><a href="desktop-styles.html">Desktop Type &amp; Widgets</a></li>
55
+ <li><a href="responsive-columns.html">Responsive Columns</a></li>
56
+ <li><a href="dialog.html">Dialog with Overlay</a></li>
57
+ <li><a href="carousel.html">Carousel</a></li>
58
+ </ul>
59
+ </div>
60
+ </div>
61
+ </div>
62
+ </div>
63
+ </body>