dugway 1.3.2 → 1.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c46df5b017cc39075c1f2d19590a5eb0e970bcf061adc03e92c59995d4fe8755
4
- data.tar.gz: 22df3b32d09c165b465f3b2cde61843d5c5ee87e709b9ec7bc4b170d90769a76
3
+ metadata.gz: a5d2312c447465c6aff5ea742614d8ceeb34047fa36ebe5cfcaea8ee017794d5
4
+ data.tar.gz: 2d0d9cdea5b3d8e99a1f37e9d99b7fab6d106dc6791cec4529573da3217e5c75
5
5
  SHA512:
6
- metadata.gz: 9ba8e565450c1961bdde6512f23edb936bb3750c38dea596d3c2932777b935d6b5f5882797b8cb40690d35f7df210e04ce7d1450958e07b882c0bb13dcd2d200
7
- data.tar.gz: 284359b7d153a8c92cb021c7e4211049201ac8626fe7e1a17c08cef4f574dcf603cfbd2c0abd3c0811956520d6af46fd27d1e4327d807024f4c42993b355183d
6
+ metadata.gz: efd14320f6ca5c8b3a691adc371e6ef678467ea3cdc5cd0164f166de04549c3c5c45fb68cd19ec2cccd307ad56f09605f7b317e659b6dca556f14a03670cda0c
7
+ data.tar.gz: b19554612dfb5a8701f05d865048f2c18c0698eadfffa45075f72aa56aa476f80f6aacb292d7f45a27af9dad89dd19b41627cab7860682beef6506010f013005
@@ -36,7 +36,9 @@ module Dugway
36
36
 
37
37
  listener = Listen.to('.', only: /\.(css|html|jpg|js|json|png|sass|svg)$/) do |modified|
38
38
  puts "Theme files changed, restarting server..."
39
- exec "dugway server"
39
+ args = [RbConfig.ruby, '-S', 'dugway', 'server', '--host', options[:host], '--port', options[:port].to_s, '--server', options[:server]]
40
+ args << '--suppress_warnings' if options[:suppress_warnings]
41
+ exec(*args)
40
42
  end
41
43
 
42
44
  Thread.new { listener.start }
data/lib/dugway/theme.rb CHANGED
@@ -241,7 +241,7 @@ module Dugway
241
241
 
242
242
  if style['colors'].is_a?(Hash) && !style['colors'].empty?
243
243
  style['colors'].each do |key, color|
244
- unless color =~ /^#[0-9A-Fa-f]{6}$/
244
+ unless color =~ /^(#[0-9A-Fa-f]{6}|transparent)$/
245
245
  @errors << "Style '#{style['style_name']}' - Invalid color value '#{color}' for color '#{key}'"
246
246
  end
247
247
  end
@@ -1,3 +1,3 @@
1
1
  module Dugway
2
- VERSION = "1.3.2"
2
+ VERSION = "1.3.3"
3
3
  end
@@ -370,6 +370,22 @@ describe Dugway::Theme do
370
370
  theme.valid?.should be(false)
371
371
  theme.errors.should include('Style in group \'Classic\' - Missing style_name')
372
372
  end
373
+
374
+ it "allows transparent as a valid color value" do
375
+ settings = valid_settings.dup
376
+ settings['preset_styles']['presets'].first['styles'].first['colors']['background_color'] = 'transparent'
377
+ theme.stub(:settings) { settings }
378
+ theme.valid?.should be(true)
379
+ theme.errors.should be_empty
380
+ end
381
+
382
+ it "rejects invalid color values" do
383
+ settings = valid_settings.dup
384
+ settings['preset_styles']['presets'].first['styles'].first['colors']['background_color'] = 'not-a-color'
385
+ theme.stub(:settings) { settings }
386
+ theme.valid?.should be(false)
387
+ theme.errors.should include("Style 'Style 1' - Invalid color value 'not-a-color' for color 'background_color'")
388
+ end
373
389
  end
374
390
 
375
391
  describe "when missing option descriptions" do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dugway
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.2
4
+ version: 1.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Big Cartel
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-09-29 00:00:00.000000000 Z
11
+ date: 2025-10-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler