shipyard-framework 0.5.82 → 0.5.83

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 27e61f49bdbd5ae0eeba8e929285f5cfaeda2a52df04b9a91a24bbce7b386b20
4
- data.tar.gz: 6148ea0dd24160e5416f2990fd36960edfbb901140c689579073ab44a2233236
3
+ metadata.gz: c847bd8a06897c01bf0f4aea3acba561a85e48d146c3bfe66f6e78a5254aca1d
4
+ data.tar.gz: 7175c8a635a4997e26ca3c3653413464a96dd15a3a396b3be4f20ce05afbe070
5
5
  SHA512:
6
- metadata.gz: af369bcfb123990a1996bbb1a29f63ecd582f653d06bbacc9b735284cbcb537b00d87a0c6067fd7421c5fe889ffb739ec566e2f51232ceff553575a6a774826f
7
- data.tar.gz: 77dcacad8a505853a62b8d2fc09fc56275b89038c807bc1fe423ddefea3df11c935465b3f140b0fc9f56122241f381c4bd8f7b728804599bac11ef1899a69609
6
+ metadata.gz: 3da5f028fc98e941950f381d994c61ca8dc77988ee1822eb5e35225eb31ad0312de01bc76d73c8ec2e46e3424879194634bb0f543298a5ab917922556caf78f1
7
+ data.tar.gz: c0d206953934307ceae826e6cae57dfc31f7a581352ac5fdd34930e72f18517337c54ae38af47878b22325aa71b93c20ebbeee4faae68753902cebce04ed2b2b
@@ -4,3 +4,4 @@
4
4
  @import "variables/grid"
5
5
  @import "variables/misc"
6
6
  @import "variables/components"
7
+ @import "variables/opacities"
@@ -1,4 +1,4 @@
1
1
  .o
2
- @each $value in (95, 90, 85, 80, 75, 70, 65, 60, 55, 50, 45, 40, 35, 30, 25, 20, 15, 10, 05, 0)
3
- &-#{$value}
4
- opacity: $value / 100
2
+ @each $opacity, $value in $opacities
3
+ &-#{$opacity}
4
+ opacity: $value
@@ -0,0 +1,22 @@
1
+ $opacities: (
2
+ '95': .95,
3
+ '90': .9,
4
+ '85': .85,
5
+ '80': .8,
6
+ '75': .75,
7
+ '70': .7,
8
+ '65': .65,
9
+ '60': .6,
10
+ '55': .55,
11
+ '50': .5,
12
+ '45': .45,
13
+ '40': .4,
14
+ '35': .35,
15
+ '30': .3,
16
+ '25': .25,
17
+ '20': .2,
18
+ '15': .15,
19
+ '10': .1,
20
+ '05': .05,
21
+ '0': 0
22
+ ) !default;
@@ -1,3 +1,3 @@
1
1
  module Shipyard
2
- VERSION = '0.5.82'
2
+ VERSION = '0.5.83'
3
3
  end
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ..
3
3
  specs:
4
- shipyard-framework (0.5.82)
4
+ shipyard-framework (0.5.83)
5
5
  actionview (~> 5.0)
6
6
  sprockets-es6 (~> 0.9.2)
7
7
 
@@ -0,0 +1,12 @@
1
+ module Jekyll
2
+ module OpacityCssClassFilter
3
+ def opacity_css_class(value, decimal='')
4
+ css = ''
5
+ css += decimal if value > 0
6
+ css += value == 5 ? "0#{value}" : "#{value}"
7
+ css
8
+ end
9
+ end
10
+ end
11
+
12
+ Liquid::Template.register_filter(Jekyll::OpacityCssClassFilter)
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  title: Shipyard Utilities
3
3
  description: The utility classes below can be applied to any component to override or extend the base styles of the component.
4
- utilities: [Accordion, Responsive, Grid, Typography, Margin & Padding, Colors, Border Radius, Position]
4
+ utilities: [Accordion, Responsive, Grid, Typography, Margin & Padding, Colors, Border Radius, Position, Opacity]
5
5
  ---
6
6
 
7
7
  {% include page-heading.html page=page %}
@@ -0,0 +1,25 @@
1
+ ---
2
+ title: Opacity Utilities
3
+ description: Shipyard's opacity utilities are useful when you need to overwrite the default opacity of a component.
4
+ options: [0,05,10,15,20,25,30,35,40,45,50,55,60,65,70,75,80,85,90,95]
5
+ ---
6
+
7
+ {% include page-heading.html page=page %}
8
+
9
+ ---
10
+
11
+ <ul class="col-container strong align-center">
12
+ {% for option in page.options reversed -%}
13
+ <li class="col col-20 margin-bottom-sm">
14
+ <div class="bg-gray-dark white rounded-sm padding-xs o-{{ option | opacity_css_class }}">
15
+ .{{ option | opacity_css_class }}
16
+ </div>
17
+ </li>
18
+ {% endfor -%}
19
+ </ul>
20
+
21
+ ```css
22
+ {% for option in page.options reversed -%}
23
+ .o-{{ option | opacity_css_class }} { opacity: {{ option | opacity_css_class: '.' }} }
24
+ {% endfor -%}
25
+ ```
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shipyard-framework
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.82
4
+ version: 0.5.83
5
5
  platform: ruby
6
6
  authors:
7
7
  - Codeship
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-12-08 00:00:00.000000000 Z
11
+ date: 2017-12-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: actionview
@@ -269,6 +269,7 @@ files:
269
269
  - assets/stylesheets/shipyard/variables/_components.scss
270
270
  - assets/stylesheets/shipyard/variables/_grid.sass
271
271
  - assets/stylesheets/shipyard/variables/_misc.sass
272
+ - assets/stylesheets/shipyard/variables/_opacities.scss
272
273
  - assets/stylesheets/shipyard/variables/_typography.sass
273
274
  - ci/build.rb
274
275
  - ci/deploy
@@ -329,6 +330,7 @@ files:
329
330
  - styleguide/_plugins/color_css_class.rb
330
331
  - styleguide/_plugins/component_css_class.rb
331
332
  - styleguide/_plugins/icon_item.rb
333
+ - styleguide/_plugins/opacity_css_class.rb
332
334
  - styleguide/components/alerts.md
333
335
  - styleguide/components/boxes.md
334
336
  - styleguide/components/buttons.md
@@ -357,6 +359,7 @@ files:
357
359
  - styleguide/utilities/grid.md
358
360
  - styleguide/utilities/index.md
359
361
  - styleguide/utilities/margin-padding.md
362
+ - styleguide/utilities/opacity.md
360
363
  - styleguide/utilities/position.md
361
364
  - styleguide/utilities/responsive.md
362
365
  - styleguide/utilities/typography.md