sassc-embedded 1.5.2 → 1.5.3

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: 34c4811b38299f8c49a35d9b8b87d23d610406fd94ce7f8075ac03313db70a23
4
- data.tar.gz: 390d007373427c76c86c3bf4a9c7e8610dc99da6524bfc3546138b6f63b4fc83
3
+ metadata.gz: b84338d9d4ffba85e3b720f4a2683710800e9f44b15d03f0763de93882963a7a
4
+ data.tar.gz: 8e0945ad581b851d3dae2415f9f7f9c3699c270b6e617444025a58612940ae08
5
5
  SHA512:
6
- metadata.gz: cc3c3f6ee78f82364b1ea56e44ae8e0006b9def7cf27492b7eb4a8e40fc47d7df99b2e10c125a285d19627964d7bb6f0f195049772351885df187725ed1fd14b
7
- data.tar.gz: bbf300fce0ae4ea93219a10e321038fa22126f337303b02e2837dc808d2fc06a0ead8c733f2ee2591ee51c198037a9ef4d476772d1c723d58188f04e20b26f15
6
+ metadata.gz: 1c0f74d8531765a1d0e615227b5135fe80a1c44632241dd6eed7ca004ad2ffb64b92c1617ca298c9d31883fbb78dabc5144601399efb0ece8b1ee9862d2017c7
7
+ data.tar.gz: e51bb48f861c668d5f31a1b9bc101c2d112baf4145d80a483f38c8a779114ba2f9454b6a278e706fc2726c555058eed7a5dca338ee4dc4e3c4552846c80e2db1
@@ -2,6 +2,6 @@
2
2
 
3
3
  module SassC
4
4
  module Embedded
5
- VERSION = '1.5.2'
5
+ VERSION = '1.5.3'
6
6
  end
7
7
  end
@@ -204,7 +204,7 @@ module SassC
204
204
  class << self
205
205
  def resolve_path(path, from_import)
206
206
  ext = File.extname(path)
207
- unless ext.empty?
207
+ if ['.sass', '.scss', '.css'].include?(ext)
208
208
  if from_import
209
209
  result = exactly_one(try_path("#{without_ext(path)}.import#{ext}"))
210
210
  return result unless result.nil?
@@ -212,6 +212,15 @@ module SassC
212
212
  return exactly_one(try_path(path))
213
213
  end
214
214
 
215
+ unless ext.empty?
216
+ if from_import
217
+ result = exactly_one(try_path("#{without_ext(path)}.import#{ext}"))
218
+ return result unless result.nil?
219
+ end
220
+ result = exactly_one(try_path(path))
221
+ return result unless result.nil?
222
+ end
223
+
215
224
  if from_import
216
225
  result = exactly_one(try_path_with_ext("#{path}.import"))
217
226
  return result unless result.nil?
@@ -298,7 +307,9 @@ module SassC
298
307
 
299
308
  path = URL.parse(url).route_from(@parent_urls.last).to_s
300
309
  resolved = resolve_path(path, URL.file_url_to_path(@parent_urls.last), from_import)
301
- return resolved.nil? ? nil : URL.path_to_file_url(resolved)
310
+ return URL.path_to_file_url(resolved) unless resolved.nil?
311
+
312
+ return
302
313
  end
303
314
 
304
315
  return unless url.start_with?(Protocol::FILE)
@@ -358,14 +369,7 @@ module SassC
358
369
  end
359
370
 
360
371
  def syntax(path)
361
- case File.extname(path)
362
- when '.sass'
363
- :indented
364
- when '.css'
365
- :css
366
- else
367
- :scss
368
- end
372
+ File.extname(path) == '.sass' ? :indented : :scss
369
373
  end
370
374
 
371
375
  def imports_to_native(imports)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sassc-embedded
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.2
4
+ version: 1.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - なつき
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-04-04 00:00:00.000000000 Z
11
+ date: 2022-04-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sassc
@@ -86,14 +86,14 @@ dependencies:
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: 0.18.0
89
+ version: 0.19.0
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: 0.18.0
96
+ version: 0.19.0
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: rubocop-performance
99
99
  requirement: !ruby/object:Gem::Requirement
@@ -138,8 +138,8 @@ homepage: https://github.com/ntkme/sassc-embedded-polyfill-ruby
138
138
  licenses:
139
139
  - MIT
140
140
  metadata:
141
- documentation_uri: https://rubydoc.info/gems/sassc-embedded/1.5.2
142
- source_code_uri: https://github.com/ntkme/sassc-embedded-polyfill-ruby/tree/v1.5.2
141
+ documentation_uri: https://rubydoc.info/gems/sassc-embedded/1.5.3
142
+ source_code_uri: https://github.com/ntkme/sassc-embedded-polyfill-ruby/tree/v1.5.3
143
143
  funding_uri: https://github.com/sponsors/ntkme
144
144
  post_install_message:
145
145
  rdoc_options: []