tailwind_merge 0.2.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +1 -27
- data/README.md +1 -1
- data/Rakefile +6 -0
- data/lib/tailwind_merge/config.rb +8 -8
- data/lib/tailwind_merge/validators.rb +1 -1
- data/lib/tailwind_merge/version.rb +1 -1
- metadata +6 -7
- data/script/generate_changelog +0 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b6224f510ea4b41c69dcfd5afebd2275a160f35a4bd0d566abf939de17467e73
|
4
|
+
data.tar.gz: 703cde0f5f4995926c368abd799db4a2b39a495ad8563958d6efe6a5b10c1e1b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 20a49d6ed7f51d50c9397e187ec1ebd5244b9ad3757008d7dadbdae866a2660d29b2cec4b55e39f1daea444ba3f2acec1a0d3a24217d5a0f4888ba932c7b259a
|
7
|
+
data.tar.gz: c11f641d5314e975bfd0cdfe7e25e5b21245645bec46649b7ffbe1c35dedeff94951a3984bb6dce9f99852e6c393f4a1e402489b1d7286466aacbe11991de8f4
|
data/CHANGELOG.md
CHANGED
@@ -1,30 +1,4 @@
|
|
1
|
-
|
1
|
+
**Full Changelog**: https://github.com/gjtorikian/tailwind_merge/compare/v0.3.0...v0.3.1
|
2
2
|
|
3
|
-
## [v0.1.3](https://github.com/gjtorikian/tailwind_merge/tree/v0.1.3) (2022-10-11)
|
4
3
|
|
5
|
-
[Full Changelog](https://github.com/gjtorikian/tailwind_merge/compare/v0.1.2...v0.1.3)
|
6
4
|
|
7
|
-
## [v0.1.2](https://github.com/gjtorikian/tailwind_merge/tree/v0.1.2) (2022-10-11)
|
8
|
-
|
9
|
-
[Full Changelog](https://github.com/gjtorikian/tailwind_merge/compare/v0.1.1...v0.1.2)
|
10
|
-
|
11
|
-
## [v0.1.1](https://github.com/gjtorikian/tailwind_merge/tree/v0.1.1) (2022-10-11)
|
12
|
-
|
13
|
-
[Full Changelog](https://github.com/gjtorikian/tailwind_merge/compare/v0.1.0...v0.1.1)
|
14
|
-
|
15
|
-
**Closed issues:**
|
16
|
-
|
17
|
-
- Should arrays be supported? [\#1](https://github.com/gjtorikian/tailwind_merge/issues/1)
|
18
|
-
|
19
|
-
**Merged pull requests:**
|
20
|
-
|
21
|
-
- Fix h-min [\#3](https://github.com/gjtorikian/tailwind_merge/pull/3) ([gjtorikian](https://github.com/gjtorikian))
|
22
|
-
- Fix example in README [\#2](https://github.com/gjtorikian/tailwind_merge/pull/2) ([marcoroth](https://github.com/marcoroth))
|
23
|
-
|
24
|
-
## [v0.1.0](https://github.com/gjtorikian/tailwind_merge/tree/v0.1.0) (2022-08-15)
|
25
|
-
|
26
|
-
[Full Changelog](https://github.com/gjtorikian/tailwind_merge/compare/e748f00d53e86ece8ce2543735f3327cb30c1959...v0.1.0)
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)*
|
data/README.md
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Utility function to efficiently merge [Tailwind CSS](https://tailwindcss.com/) classes without style conflicts. Essentially, a Ruby port of [tailwind-merge](https://github.com/dcastil/tailwind-merge).
|
4
4
|
|
5
|
-
Supports Tailwind v3.0
|
5
|
+
Supports Tailwind v3.0 up to v3.2.
|
6
6
|
|
7
7
|
## Installation
|
8
8
|
|
data/Rakefile
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require "bundler/gem_tasks"
|
4
|
+
require "rubygems/package_task"
|
4
5
|
require "rake/testtask"
|
5
6
|
|
6
7
|
Rake::TestTask.new(:test) do |t|
|
@@ -12,3 +13,8 @@ end
|
|
12
13
|
require "rubocop/rake_task"
|
13
14
|
|
14
15
|
RuboCop::RakeTask.new
|
16
|
+
|
17
|
+
GEMSPEC = Bundler.load_gemspec("tailwind_merge.gemspec")
|
18
|
+
gem_path = Gem::PackageTask.new(GEMSPEC).define
|
19
|
+
desc "Package the ruby gem"
|
20
|
+
task "package" => [gem_path]
|
@@ -300,7 +300,7 @@ module TailwindMerge
|
|
300
300
|
# Visibility
|
301
301
|
# @see https://tailwindcss.com/docs/visibility
|
302
302
|
##
|
303
|
-
"visibility" => ["visible", "invisible"],
|
303
|
+
"visibility" => ["visible", "invisible", "collapse"],
|
304
304
|
##
|
305
305
|
# Z-Index
|
306
306
|
# @see https://tailwindcss.com/docs/z-index
|
@@ -431,7 +431,7 @@ module TailwindMerge
|
|
431
431
|
# Align Content
|
432
432
|
# @see https://tailwindcss.com/docs/align-content
|
433
433
|
##
|
434
|
-
"align-content" => [{
|
434
|
+
"align-content" => [{ content: [*ALIGN.call, "baseline"] }],
|
435
435
|
##
|
436
436
|
# Align Items
|
437
437
|
# @see https://tailwindcss.com/docs/align-items
|
@@ -446,12 +446,12 @@ module TailwindMerge
|
|
446
446
|
# Place Content
|
447
447
|
# @see https://tailwindcss.com/docs/place-content
|
448
448
|
##
|
449
|
-
"place-content" => [{ "place-content" => [*ALIGN.call, "stretch"] }],
|
449
|
+
"place-content" => [{ "place-content" => [*ALIGN.call, "baseline", "stretch"] }],
|
450
450
|
##
|
451
451
|
# Place Items
|
452
452
|
# @see https://tailwindcss.com/docs/place-items
|
453
453
|
##
|
454
|
-
"place-items" => [{ "place-items" => ["start", "end", "center", "stretch"] }],
|
454
|
+
"place-items" => [{ "place-items" => ["start", "end", "center", "baseline", "stretch"] }],
|
455
455
|
##
|
456
456
|
# Place Self
|
457
457
|
# @see https://tailwindcss.com/docs/place-self
|
@@ -793,7 +793,7 @@ module TailwindMerge
|
|
793
793
|
# Word Break
|
794
794
|
# @see https://tailwindcss.com/docs/word-break
|
795
795
|
##
|
796
|
-
"break" => [{ "break" => ["normal", "words", "all"] }],
|
796
|
+
"break" => [{ "break" => ["normal", "words", "all", "keep"] }],
|
797
797
|
##
|
798
798
|
# Content
|
799
799
|
# @see https://tailwindcss.com/docs/content
|
@@ -1034,7 +1034,7 @@ module TailwindMerge
|
|
1034
1034
|
# Outline Style
|
1035
1035
|
# @see https://tailwindcss.com/docs/outline-style
|
1036
1036
|
##
|
1037
|
-
"outline-style" => [{ "outline" => ["", *LINE_STYLES.call
|
1037
|
+
"outline-style" => [{ "outline" => ["", *LINE_STYLES.call] }],
|
1038
1038
|
##
|
1039
1039
|
# Outline Offset
|
1040
1040
|
# @see https://tailwindcss.com/docs/outline-offset
|
@@ -1540,7 +1540,7 @@ module TailwindMerge
|
|
1540
1540
|
# Fill
|
1541
1541
|
# @see https://tailwindcss.com/docs/fill
|
1542
1542
|
##
|
1543
|
-
"fill" => [{ "fill" => [COLORS] }],
|
1543
|
+
"fill" => [{ "fill" => [COLORS, "none"] }],
|
1544
1544
|
##
|
1545
1545
|
# Stroke Width
|
1546
1546
|
# @see https://tailwindcss.com/docs/stroke-width
|
@@ -1550,7 +1550,7 @@ module TailwindMerge
|
|
1550
1550
|
# Stroke
|
1551
1551
|
# @see https://tailwindcss.com/docs/stroke
|
1552
1552
|
##
|
1553
|
-
"stroke" => [{ "stroke" => [COLORS] }],
|
1553
|
+
"stroke" => [{ "stroke" => [COLORS, "none"] }],
|
1554
1554
|
# Accessibility
|
1555
1555
|
##
|
1556
1556
|
# Screen Readers
|
@@ -18,7 +18,7 @@ module TailwindMerge
|
|
18
18
|
|
19
19
|
ARBITRARY_VALUE_REGEX = /^\[(.+)\]$/
|
20
20
|
FRACTION_REGEX = %r{^\d+/\d+$}
|
21
|
-
LENGTH_UNIT_REGEX = /\d+(%|px|em|
|
21
|
+
LENGTH_UNIT_REGEX = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh)/
|
22
22
|
TSHIRT_UNIT_REGEX = /^(\d+)?(xs|sm|md|lg|xl)$/
|
23
23
|
# Shadow always begins with x and y offset separated by underscore
|
24
24
|
SHADOW_REGEX = /^-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tailwind_merge
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Garen J. Torikian
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: lru_redux
|
@@ -122,7 +122,7 @@ dependencies:
|
|
122
122
|
- - ">="
|
123
123
|
- !ruby/object:Gem::Version
|
124
124
|
version: '0'
|
125
|
-
description:
|
125
|
+
description:
|
126
126
|
email:
|
127
127
|
- gjtorikian@gmail.com
|
128
128
|
executables: []
|
@@ -140,7 +140,6 @@ files:
|
|
140
140
|
- lib/tailwind_merge/config.rb
|
141
141
|
- lib/tailwind_merge/validators.rb
|
142
142
|
- lib/tailwind_merge/version.rb
|
143
|
-
- script/generate_changelog
|
144
143
|
- tailwind_merge.gemspec
|
145
144
|
homepage: https://www.github.com/gjtorikian/tailwind_merge
|
146
145
|
licenses:
|
@@ -149,7 +148,7 @@ metadata:
|
|
149
148
|
funding_uri: https://github.com/sponsors/gjtorikian/
|
150
149
|
rubygems_mfa_required: 'true'
|
151
150
|
homepage_uri: https://www.github.com/gjtorikian/tailwind_merge
|
152
|
-
post_install_message:
|
151
|
+
post_install_message:
|
153
152
|
rdoc_options: []
|
154
153
|
require_paths:
|
155
154
|
- lib
|
@@ -168,7 +167,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
168
167
|
version: '0'
|
169
168
|
requirements: []
|
170
169
|
rubygems_version: 3.3.7
|
171
|
-
signing_key:
|
170
|
+
signing_key:
|
172
171
|
specification_version: 4
|
173
172
|
summary: Utility function to efficiently merge Tailwind CSS classes without style
|
174
173
|
conflicts.
|
data/script/generate_changelog
DELETED