sassc-embedded 1.80.1 → 1.80.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: 7bcb2ad67ca13ea4108da3411010d0ba6174be0c81344ba4e872c72a975de4e8
4
- data.tar.gz: 7c4fb6fb6f586c1a1df518969919621684f7db14ee714565d09a7ba84aa944a0
3
+ metadata.gz: aabfdfe0d75fc8819353db51045dcbda01b95bb39355aadcf161dc8f126873e9
4
+ data.tar.gz: c5d1afb014833593a3ed73467f746f257fc7c1e87b2d01eae35503ebcfeb2ab6
5
5
  SHA512:
6
- metadata.gz: 995360f534fdb95387ea7265bab5648d36ad1d87581c48343985b43552182c39b037f9636c6d46e0796f1c2fdf69c54e377b2a1618b696d3505a3766339240e4
7
- data.tar.gz: 2bbb05391583018d90900043363bd97fec65626488c22d992518fc8b8c6fe23fde4f653cb7ec0fadb8ae48a67526bcbd7b4ff53236cce269eab8ee3bdf1fe407
6
+ metadata.gz: f82517d2f6303cc6c502377c47be29831424ac22ef8d6ad37ecb3f86477d3e456ba8c53481aacbd2f3ff5e3e53e8ba7b20a3948e99b639f6719ce348ecfdc9bc
7
+ data.tar.gz: c1ce5a02d6de472499faecd0b45d367c79e57e8f0f639e234147ad1da0b35e2faec4b42ff13b5acfff5702031e2d54857b166fe711a9c036c9d14666b815a724
@@ -2,6 +2,6 @@
2
2
 
3
3
  module SassC
4
4
  module Embedded
5
- VERSION = '1.80.1'
5
+ VERSION = '1.80.3'
6
6
  end
7
7
  end
@@ -13,8 +13,6 @@ module SassC
13
13
  remove_method(:render) if public_method_defined?(:render, false)
14
14
 
15
15
  def render
16
- return @template.dup if @template.empty?
17
-
18
16
  result = ::Sass.compile_string(
19
17
  @template,
20
18
  importer: (NoopImporter unless @options[:importer].nil?),
@@ -43,15 +41,15 @@ module SassC
43
41
  @loaded_urls = result.loaded_urls
44
42
  @source_map = result.source_map
45
43
 
46
- css = result.css
47
- css += "\n" unless css.empty?
44
+ css = result.css.encode(@template.encoding)
45
+ css << "\n" unless css.empty?
48
46
  unless @source_map.nil? || omit_source_map_url?
49
47
  source_mapping_url = if source_map_embed?
50
48
  "data:application/json;base64,#{[@source_map].pack('m0')}"
51
49
  else
52
50
  Uri.file_urls_to_relative_url(source_map_file_url, file_url)
53
51
  end
54
- css += "\n/*# sourceMappingURL=#{source_mapping_url} */"
52
+ css << "\n/*# sourceMappingURL=#{source_mapping_url} */"
55
53
  end
56
54
  css
57
55
  rescue ::Sass::CompileError => e
@@ -108,18 +106,14 @@ module SassC
108
106
  remove_method(:output_style) if private_method_defined?(:output_style, false)
109
107
 
110
108
  def output_style
111
- @output_style ||= begin
112
- style = @options.fetch(:style, :sass_style_nested).to_s.delete_prefix('sass_style_').to_sym
113
-
114
- case style
115
- when :nested, :compact, :expanded
116
- :expanded
117
- when :compressed
118
- :compressed
119
- else
120
- raise InvalidStyleError
121
- end
122
- end
109
+ @output_style ||= case @options.fetch(:style, :sass_style_nested).to_sym
110
+ when :nested, :expanded, :compact, :sass_style_nested, :sass_style_expanded, :sass_style_compact
111
+ :expanded
112
+ when :compressed, :sass_style_compressed
113
+ :compressed
114
+ else
115
+ raise InvalidStyleError
116
+ end
123
117
  end
124
118
 
125
119
  def syntax
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sassc-embedded
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.80.1
4
+ version: 1.80.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - なつき
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2024-10-17 00:00:00.000000000 Z
10
+ date: 2025-02-21 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: sass-embedded
@@ -79,10 +78,9 @@ licenses:
79
78
  metadata:
80
79
  bug_tracker_uri: https://github.com/sass-contrib/sassc-embedded-shim-ruby/issues
81
80
  documentation_uri: https://rubydoc.info/gems/sassc
82
- source_code_uri: https://github.com/sass-contrib/sassc-embedded-shim-ruby/tree/v1.80.1
81
+ source_code_uri: https://github.com/sass-contrib/sassc-embedded-shim-ruby/tree/v1.80.3
83
82
  funding_uri: https://github.com/sponsors/ntkme
84
83
  rubygems_mfa_required: 'true'
85
- post_install_message:
86
84
  rdoc_options: []
87
85
  require_paths:
88
86
  - lib
@@ -98,8 +96,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
98
96
  - !ruby/object:Gem::Version
99
97
  version: '0'
100
98
  requirements: []
101
- rubygems_version: 3.5.16
102
- signing_key:
99
+ rubygems_version: 3.6.5
103
100
  specification_version: 4
104
101
  summary: Use dart-sass with SassC!
105
102
  test_files: []