tailwindcss-rails 2.0.23-x64-mingw32 → 2.0.24-x64-mingw32

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: 78ada11439f00a3b12df303e67358ea97b61a6db0a8c16aee9942c25ec69e65e
4
- data.tar.gz: ab04440113f89e2992a2249d762914dac7ee515bcfbd24613e4cde8b33ef05f5
3
+ metadata.gz: 0f8fb15fe31eca2d83216fa171cc52c8ef1870325227ca93c00fe0ea566ec229
4
+ data.tar.gz: 4b137c797fa230a15c2f5b0ceb140de5075822a20aa0598c70cf435dc40c8207
5
5
  SHA512:
6
- metadata.gz: b5a674052e1976aec0035f7b3abbf629f0d47b7204ff129de5d10ccd6cee17a52f773ea7b278aed9b56f898699107b585e3e4260f360906c9b97b3a73b21ac59
7
- data.tar.gz: b583971f2ef888f2958bd755b6a5d528083a6b4b9ae6310fd8ce37d71af216494dff39c96186caf2c393e60048e790fdb0741bbbc8603ce7eb631a2be37dafaf
6
+ metadata.gz: ee3d9c6551a6a9946eabdc450ac82c379f33a922ef73d7d8a87e2deb29dae64b60ebd83e465209ef5bbe8c4c2a91b868aa9f511daf0a9a5b29e707ecd965fc28
7
+ data.tar.gz: 1e061c6a18895e9c80508a6484d8a9cd41a3c5b713fdae321d0fc3ad4ea3f4baba8e3795fc023154f68190b182368098bdc2eb26bfed8b65bc770b588197e386
@@ -62,7 +62,7 @@ module Tailwindcss
62
62
  "-o", Rails.root.join("app/assets/builds/tailwind.css").to_s,
63
63
  "-c", Rails.root.join("config/tailwind.config.js").to_s,
64
64
  ].tap do |command|
65
- command << "--minify" unless debug
65
+ command << "--minify" unless (debug || rails_css_compressor?)
66
66
  end
67
67
  end
68
68
 
@@ -72,6 +72,10 @@ module Tailwindcss
72
72
  command << "-p" if poll
73
73
  end
74
74
  end
75
+
76
+ def rails_css_compressor?
77
+ defined?(Rails) && Rails&.application&.config&.assets&.css_compressor.present?
78
+ end
75
79
  end
76
80
  end
77
81
  end
@@ -1,3 +1,3 @@
1
1
  module Tailwindcss
2
- VERSION = "2.0.23"
2
+ VERSION = "2.0.24"
3
3
  end
data/lib/tasks/build.rake CHANGED
@@ -1,6 +1,6 @@
1
1
  namespace :tailwindcss do
2
2
  desc "Build your Tailwind CSS"
3
- task :build do |_, args|
3
+ task build: :environment do |_, args|
4
4
  debug = args.extras.include?("debug")
5
5
  command = Tailwindcss::Commands.compile_command(debug: debug)
6
6
  puts command.inspect if args.extras.include?("verbose")
@@ -8,7 +8,7 @@ namespace :tailwindcss do
8
8
  end
9
9
 
10
10
  desc "Watch and build your Tailwind CSS on file changes"
11
- task :watch do |_, args|
11
+ task watch: :environment do |_, args|
12
12
  debug = args.extras.include?("debug")
13
13
  poll = args.extras.include?("poll")
14
14
  command = Tailwindcss::Commands.watch_command(debug: debug, poll: poll)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tailwindcss-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.23
4
+ version: 2.0.24
5
5
  platform: x64-mingw32
6
6
  authors:
7
7
  - David Heinemeier Hansson
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-02-19 00:00:00.000000000 Z
11
+ date: 2023-03-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties