dominate 0.1.7 → 0.1.8

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
  SHA1:
3
- metadata.gz: 9c1400088bbf6912de35de8603f32b9ced944c1e
4
- data.tar.gz: 567983d23410a20dc5345ea7e2604634c4773b2f
3
+ metadata.gz: 9f276d7e323d69a6ea4c0cf5917eb5143094ff4c
4
+ data.tar.gz: 5f903780aa92a50e1b59df5429537f452be1a404
5
5
  SHA512:
6
- metadata.gz: 534cf36a5da54a097a0a024d3768aeb016f143af2ad3f9e9b31191e853f2f24f8a2a9e73fa26ac1d6b3bc90176e00e7e009119dd05dd0be735c97483fafff527
7
- data.tar.gz: 5072be8a698f922d1f8bf8839874acfd31f44426b8a171fb503ff11980cb33850c1fad5cac9a457c37c45dcfb8664b2d17abee6e848f7cfc61c3b1948f32c29b
6
+ metadata.gz: 36a51e10d802d09e63e3c840efab5ccfacf39322b4de97dc61cb699b8a7653e95e82c4c5264de01a485a6b246287e306edd6d38e11e4e217792d5a28d26cb077
7
+ data.tar.gz: f51a2fa79311b8b63f20a2c8901b6a0c06adf9f6f4c4c80b802ae60c97edb555e13dcab7ded7204845ab099ffe4e6259c87b60e0cca8598ff9642dd72b28d85b
data/dominate.gemspec CHANGED
@@ -20,6 +20,7 @@ Gem::Specification.new do |spec|
20
20
 
21
21
  spec.add_dependency "nokogiri"
22
22
  spec.add_dependency "tilt"
23
+ spec.add_dependency "nokogiri-styles"
23
24
 
24
25
  spec.add_development_dependency "bundler", "~> 1.3"
25
26
  spec.add_development_dependency "rake"
@@ -1,3 +1,3 @@
1
1
  module Dominate
2
- VERSION = "0.1.7"
2
+ VERSION = "0.1.8"
3
3
  end
data/lib/dominate.rb CHANGED
@@ -1,4 +1,5 @@
1
1
  require "nokogiri"
2
+ require "nokogiri-styles"
2
3
  require "tilt"
3
4
  require "dominate/version"
4
5
  require "dominate/inflectors"
@@ -100,4 +100,16 @@ scope 'dominate' do
100
100
  assert dom.html['Moo']
101
101
  assert dom.html['Cow']
102
102
  end
103
+
104
+ test 'styles' do
105
+ dom = Dominate::HTML.file 'flat'
106
+ dom.scope(:flat).apply ['moo', 'cow'] do |node|
107
+ styles = node.styles
108
+ styles['color'] = '#000'
109
+
110
+ node.styles = styles
111
+ end
112
+
113
+ assert dom.html['#000']
114
+ end
103
115
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dominate
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - cj
@@ -38,6 +38,20 @@ dependencies:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: nokogiri-styles
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
41
55
  - !ruby/object:Gem::Dependency
42
56
  name: bundler
43
57
  requirement: !ruby/object:Gem::Requirement