From c4bfffe1ff2f32d1d866a8f057b078ee5ad6fc83 Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 13:52:40 -0600 Subject: [PATCH 1/7] upgrade to tailwind 3.0 alpha, make config changes --- package.json | 2 +- tailwind.config.js | 4 +- yarn.lock | 163 ++++----------------------------------------- 3 files changed, 16 insertions(+), 153 deletions(-) diff --git a/package.json b/package.json index 36a729432..b14527dd3 100644 --- a/package.json +++ b/package.json @@ -107,7 +107,7 @@ "postcss-nesting": "^8.0.1", "prettier": "2.4.0", "rollup": "^2.52.7", - "tailwindcss": "^2.2.0", + "tailwindcss": "^3.0.0-alpha.2", "tailwindcss-children": "^2.1.0", "ts-node": "^9.1.1", "tsconfig-paths-webpack-plugin": "^3.5.1", diff --git a/tailwind.config.js b/tailwind.config.js index ae19cef6a..6aac9be10 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -9,9 +9,7 @@ const childrenPlugin = require('tailwindcss-children') /** @type {import('tailwindcss/tailwind-config').TailwindConfig} */ module.exports = { - mode: 'jit', - purge: ['./libs/ui/**/*.{ts,tsx,mdx}', './app/**/*.{ts,tsx}'], - darkMode: false, + content: ['./libs/ui/**/*.{ts,tsx,mdx}', './app/**/*.{ts,tsx}'], theme: { extend: { borderRadius: { diff --git a/yarn.lock b/yarn.lock index b2b6396b5..5e519280c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4786,7 +4786,7 @@ bytes@3.0.0: resolved "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz" integrity sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg= -bytes@3.1.0, bytes@^3.0.0: +bytes@3.1.0: version "3.1.0" resolved "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz" integrity sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg== @@ -5272,32 +5272,16 @@ color-name@1.1.3: resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= -color-name@^1.0.0, color-name@~1.1.4: +color-name@^1.1.4, color-name@~1.1.4: version "1.1.4" resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -color-string@^1.6.0: - version "1.6.0" - resolved "https://registry.npmjs.org/color-string/-/color-string-1.6.0.tgz" - integrity sha512-c/hGS+kRWJutUBEngKKmk4iH3sD59MBkoxVapS/0wgpCz2u7XsNloxknyvBhzwEs1IbV36D9PwqLPJ2DTu3vMA== - dependencies: - color-name "^1.0.0" - simple-swizzle "^0.2.2" - color-support@^1.1.2: version "1.1.3" resolved "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz" integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== -color@^4.0.1: - version "4.0.1" - resolved "https://registry.npmjs.org/color/-/color-4.0.1.tgz" - integrity sha512-rpZjOKN5O7naJxkH2Rx1sZzzBgaiWECc6BYXjeCE6kF0kcASJYbUq02u7JqIHwCb/j3NhV+QhRL2683aICeGZA== - dependencies: - color-convert "^2.0.1" - color-string "^1.6.0" - colorette@^1.2.2: version "1.2.2" resolved "https://registry.npmjs.org/colorette/-/colorette-1.2.2.tgz" @@ -5330,7 +5314,7 @@ commander@^4.1.1: resolved "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz" integrity sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA== -commander@^6.0.0, commander@^6.2.1: +commander@^6.2.1: version "6.2.1" resolved "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz" integrity sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA== @@ -5619,11 +5603,6 @@ crypto-browserify@^3.11.0: randombytes "^2.0.0" randomfill "^1.0.3" -css-color-names@^0.0.4: - version "0.0.4" - resolved "https://registry.npmjs.org/css-color-names/-/css-color-names-0.0.4.tgz" - integrity sha1-gIrcLnnPhHOAabZGyyDsJ762KeA= - css-loader@^3.6.0: version "3.6.0" resolved "https://registry.npmjs.org/css-loader/-/css-loader-3.6.0.tgz" @@ -5701,11 +5680,6 @@ css-tree@^1.1.2: mdn-data "2.0.14" source-map "^0.6.1" -css-unit-converter@^1.1.1: - version "1.1.2" - resolved "https://registry.npmjs.org/css-unit-converter/-/css-unit-converter-1.1.2.tgz" - integrity sha512-IiJwMC8rdZE0+xiEZHeru6YoONC4rfPMqGm2W85jMIbkFvv5nFTwJVFHam2eFrN6txmoUYFAFXiv8ICVeTO0MA== - css-what@^3.2.1: version "3.4.2" resolved "https://registry.npmjs.org/css-what/-/css-what-3.4.2.tgz" @@ -7219,15 +7193,6 @@ fs-extra@^0.30.0: path-is-absolute "^1.0.0" rimraf "^2.2.8" -fs-extra@^10.0.0: - version "10.0.0" - resolved "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz" - integrity sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ== - dependencies: - graceful-fs "^4.2.0" - jsonfile "^6.0.1" - universalify "^2.0.0" - fs-extra@^8.1: version "8.1.0" resolved "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz" @@ -7424,9 +7389,9 @@ glob-parent@^5.1.0, glob-parent@^5.1.2, glob-parent@~5.1.2: dependencies: is-glob "^4.0.1" -glob-parent@^6.0.1: +glob-parent@^6.0.2: version "6.0.2" - resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-6.0.2.tgz#6d237d99083950c79290f24c7642a3de9a28f9e3" integrity sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A== dependencies: is-glob "^4.0.3" @@ -7448,7 +7413,7 @@ glob-to-regexp@^0.4.0, glob-to-regexp@^0.4.1: resolved "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz" integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw== -glob@^7.0.0, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@^7.1.4, glob@^7.1.6: +glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@^7.1.4, glob@^7.1.6: version "7.2.0" resolved "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz" integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== @@ -7804,11 +7769,6 @@ header-case@^1.0.0: no-case "^2.2.0" upper-case "^1.1.3" -hex-color-regex@^1.1.0: - version "1.1.0" - resolved "https://registry.npmjs.org/hex-color-regex/-/hex-color-regex-1.1.0.tgz" - integrity sha512-l9sfDFsuqtOqKDsQdqrMRk0U85RZc0RtOR9yPI7mRVOa4FsR/BVnZ0shmQRM96Ji99kYZP/7hn1cedc1+ApsTQ== - highlight.js@^10.1.1, highlight.js@~10.7.0: version "10.7.3" resolved "https://registry.npmjs.org/highlight.js/-/highlight.js-10.7.3.tgz" @@ -7856,16 +7816,6 @@ hosted-git-info@^2.1.4: resolved "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz" integrity sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw== -hsl-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/hsl-regex/-/hsl-regex-1.0.0.tgz" - integrity sha1-1JMwx4ntgZ4nakwNJy3/owsY/m4= - -hsla-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/hsla-regex/-/hsla-regex-1.0.0.tgz" - integrity sha1-wc56MWjIxmFAM6S194d/OyJfnDg= - html-encoding-sniffer@^2.0.1: version "2.0.1" resolved "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-2.0.1.tgz" @@ -8233,11 +8183,6 @@ is-arrayish@^0.2.1: resolved "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz" integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= -is-arrayish@^0.3.1: - version "0.3.2" - resolved "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz" - integrity sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ== - is-bigint@^1.0.1: version "1.0.2" resolved "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.2.tgz" @@ -8286,18 +8231,6 @@ is-ci@^2.0.0: dependencies: ci-info "^2.0.0" -is-color-stop@^1.1.0: - version "1.1.0" - resolved "https://registry.npmjs.org/is-color-stop/-/is-color-stop-1.1.0.tgz" - integrity sha1-z/9HGu5N1cnhWFmPvhKWe1za00U= - dependencies: - css-color-names "^0.0.4" - hex-color-regex "^1.1.0" - hsl-regex "^1.0.0" - hsla-regex "^1.0.0" - rgb-regex "^1.0.1" - rgba-regex "^1.0.0" - is-core-module@^2.2.0: version "2.5.0" resolved "https://registry.npmjs.org/is-core-module/-/is-core-module-2.5.0.tgz" @@ -9469,11 +9402,6 @@ lodash.templatesettings@^4.0.0: dependencies: lodash._reinterpolate "^3.0.0" -lodash.topath@^4.5.2: - version "4.5.2" - resolved "https://registry.npmjs.org/lodash.topath/-/lodash.topath-4.5.2.tgz" - integrity sha1-NhY1Hzu6YZlKCTGYlmC9AyVP0Ak= - lodash.truncate@^4.4.2: version "4.4.2" resolved "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz" @@ -9941,11 +9869,6 @@ mkdirp@^1.0.3, mkdirp@^1.0.4: resolved "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz" integrity sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== -modern-normalize@^1.1.0: - version "1.1.0" - resolved "https://registry.npmjs.org/modern-normalize/-/modern-normalize-1.1.0.tgz" - integrity sha512-2lMlY1Yc1+CUy0gw4H95uNN7vjbpoED7NNRSBHE25nWfLBdmMzFCsPshlzbxHz+gYMcBEUN8V4pU16prcdPSgA== - mousetrap@^1.6.5: version "1.6.5" resolved "https://registry.npmjs.org/mousetrap/-/mousetrap-1.6.5.tgz" @@ -10069,13 +9992,6 @@ node-dir@^0.1.10, node-dir@^0.1.17: dependencies: minimatch "^3.0.2" -node-emoji@^1.11.0: - version "1.11.0" - resolved "https://registry.npmjs.org/node-emoji/-/node-emoji-1.11.0.tgz" - integrity sha512-wo2DpQkQp7Sjm2A0cq+sN7EHKO6Sl0ctXeBdFZrL9T9+UywORbufTcTZxom8YqpLQt/FqNMUkOpkZrJVYSKD3A== - dependencies: - lodash "^4.17.21" - node-fetch@^2.6.1: version "2.6.1" resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.1.tgz" @@ -10997,11 +10913,6 @@ postcss-selector-parser@^6.0.0, postcss-selector-parser@^6.0.2, postcss-selector cssesc "^3.0.0" util-deprecate "^1.0.2" -postcss-value-parser@^3.3.0: - version "3.3.1" - resolved "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-3.3.1.tgz" - integrity sha512-pISE66AbVkp4fDQ7VHBwRNXzAAKJjw4Vw7nWI/+Q3vuly7SNfgYXvm6i5IgFylHGK5sP/xHAbB7N49OS4gWNyQ== - postcss-value-parser@^4.0.0, postcss-value-parser@^4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.1.0.tgz" @@ -11015,7 +10926,7 @@ postcss@^7.0.14, postcss@^7.0.26, postcss@^7.0.32, postcss@^7.0.35, postcss@^7.0 picocolors "^0.2.1" source-map "^0.6.1" -postcss@^8.1.6, postcss@^8.2.1, postcss@^8.2.15, postcss@^8.2.9, postcss@^8.3.6: +postcss@^8.1.6, postcss@^8.2.15, postcss@^8.2.9, postcss@^8.3.6: version "8.3.9" resolved "https://registry.npmjs.org/postcss/-/postcss-8.3.9.tgz" integrity sha512-f/ZFyAKh9Dnqytx5X62jgjhhzttjZS7hMsohcI7HEI5tjELX/HxCy3EFhsRxyzGvrzFF+82XPvCS8T9TFleVJw== @@ -11237,16 +11148,6 @@ punycode@^2.1.0, punycode@^2.1.1: resolved "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== -purgecss@^4.0.3: - version "4.0.3" - resolved "https://registry.npmjs.org/purgecss/-/purgecss-4.0.3.tgz" - integrity sha512-PYOIn5ibRIP34PBU9zohUcCI09c7drPJJtTDAc0Q6QlRz2/CHQ8ywGLdE7ZhxU2VTqB7p5wkvj5Qcm05Rz3Jmw== - dependencies: - commander "^6.0.0" - glob "^7.0.0" - postcss "^8.2.1" - postcss-selector-parser "^6.0.2" - q@^1.1.2: version "1.5.1" resolved "https://registry.npmjs.org/q/-/q-1.5.1.tgz" @@ -11708,14 +11609,6 @@ redent@^3.0.0: indent-string "^4.0.0" strip-indent "^3.0.0" -reduce-css-calc@^2.1.8: - version "2.1.8" - resolved "https://registry.npmjs.org/reduce-css-calc/-/reduce-css-calc-2.1.8.tgz" - integrity sha512-8liAVezDmUcH+tdzoEGrhfbGcP7nOV4NkGE3a74+qqvE7nt9i4sKLGBuZNOnpI4WiGksiNPklZxva80061QiPg== - dependencies: - css-unit-converter "^1.1.1" - postcss-value-parser "^3.3.0" - refractor@^3.1.0: version "3.3.1" resolved "https://registry.npmjs.org/refractor/-/refractor-3.3.1.tgz" @@ -11985,16 +11878,6 @@ reusify@^1.0.4: resolved "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz" integrity sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw== -rgb-regex@^1.0.1: - version "1.0.1" - resolved "https://registry.npmjs.org/rgb-regex/-/rgb-regex-1.0.1.tgz" - integrity sha1-wODWiC3w4jviVKR16O3UGRX+rrE= - -rgba-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/rgba-regex/-/rgba-regex-1.0.0.tgz" - integrity sha1-QzdOLiyglosO8VI0YLfXMP8i7rM= - rimraf@3.0.2, rimraf@^3.0.0, rimraf@^3.0.2: version "3.0.2" resolved "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz" @@ -12342,13 +12225,6 @@ signal-exit@^3.0.0, signal-exit@^3.0.2: resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz" integrity sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA== -simple-swizzle@^0.2.2: - version "0.2.2" - resolved "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz" - integrity sha1-pNprY1/8zMoz9w0Xy5JZLeleVXo= - dependencies: - is-arrayish "^0.3.1" - sisteransi@^1.0.5: version "1.0.5" resolved "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz" @@ -12901,30 +12777,22 @@ tailwindcss-children@^2.1.0: lodash "^4.17.15" postcss-selector-parser "^6.0.2" -tailwindcss@^2.2.0: - version "2.2.17" - resolved "https://registry.npmjs.org/tailwindcss/-/tailwindcss-2.2.17.tgz" - integrity sha512-WgRpn+Pxn7eWqlruxnxEbL9ByVRWi3iC10z4b6dW0zSdnkPVC4hPMSWLQkkW8GCyBIv/vbJ0bxIi9dVrl4CfoA== +tailwindcss@^3.0.0-alpha.2: + version "3.0.0-alpha.2" + resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.0.0-alpha.2.tgz#9f0f797aeabc0294169d732f3379538222e0a44a" + integrity sha512-DLPLL927a05mhwTAPMPgSk1EFLAsWc0qmZeB1yHDSRAj/Bfn0nvdFTqj2u/8FnM5EiS20nsqCZ/HFfXzzaFOZg== dependencies: arg "^5.0.1" - bytes "^3.0.0" chalk "^4.1.2" chokidar "^3.5.2" - color "^4.0.1" + color-name "^1.1.4" cosmiconfig "^7.0.1" detective "^5.2.0" didyoumean "^1.2.2" dlv "^1.1.3" fast-glob "^3.2.7" - fs-extra "^10.0.0" - glob-parent "^6.0.1" - html-tags "^3.1.0" - is-color-stop "^1.1.0" - is-glob "^4.0.1" - lodash "^4.17.21" - lodash.topath "^4.5.2" - modern-normalize "^1.1.0" - node-emoji "^1.11.0" + glob-parent "^6.0.2" + is-glob "^4.0.3" normalize-path "^3.0.0" object-hash "^2.2.0" postcss-js "^3.0.3" @@ -12932,10 +12800,7 @@ tailwindcss@^2.2.0: postcss-nested "5.0.6" postcss-selector-parser "^6.0.6" postcss-value-parser "^4.1.0" - pretty-hrtime "^1.0.3" - purgecss "^4.0.3" quick-lru "^5.1.1" - reduce-css-calc "^2.1.8" resolve "^1.20.0" tmp "^0.2.1" From 417ee19c1d183e9f66791cdd74055e0f7fab5d03 Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 15:03:25 -0600 Subject: [PATCH 2/7] rewrite svg: w/ new addVariant API https://github.com/tailwindlabs/tailwindcss/pull/5809 --- tailwind.config.js | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/tailwind.config.js b/tailwind.config.js index 6aac9be10..5dd2bfa2b 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -74,13 +74,7 @@ module.exports = { plugins: [ // imitation of the twin.macro svg: variant. svg:text-green-500 puts green // on an SVG that's an immediate child of the element - plugin(function ({ addVariant, e }) { - addVariant('svg', ({ modifySelectors, separator }) => { - modifySelectors( - ({ className }) => `.${e(`svg${separator}${className}`)} > svg` - ) - }) - }), + plugin(({ addVariant }) => addVariant('svg', '& > svg')), childrenPlugin, ], /** From e1dacaf24f7ee2c4b0b445749758f42fdb10dc0e Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 15:18:06 -0600 Subject: [PATCH 3/7] first first-of-type:before: order issue (tw fix in next alpha) https://github.com/tailwindlabs/tailwindcss/issues/6112 https://github.com/tailwindlabs/tailwindcss/issues/6016 https://github.com/tailwindlabs/tailwindcss/pull/6018 --- libs/ui/lib/breadcrumbs/Breadcrumbs.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/ui/lib/breadcrumbs/Breadcrumbs.tsx b/libs/ui/lib/breadcrumbs/Breadcrumbs.tsx index 56c9ec8d7..d2b1f6de9 100644 --- a/libs/ui/lib/breadcrumbs/Breadcrumbs.tsx +++ b/libs/ui/lib/breadcrumbs/Breadcrumbs.tsx @@ -11,7 +11,7 @@ export const Breadcrumbs = ({ data }: BreadcrumbsProps) => (
    {data.map(({ href, label }) => (
  1. From 53b37b53937f9fd6985ffad90c55100988169523 Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 15:18:29 -0600 Subject: [PATCH 4/7] replace tailwindcss-children plugin with new custom addVariant --- libs/ui/lib/radio/Radio.tsx | 2 +- package.json | 1 - tailwind.config.js | 10 +--------- yarn.lock | 8 -------- 4 files changed, 2 insertions(+), 19 deletions(-) diff --git a/libs/ui/lib/radio/Radio.tsx b/libs/ui/lib/radio/Radio.tsx index be7c730e6..930ea2383 100644 --- a/libs/ui/lib/radio/Radio.tsx +++ b/libs/ui/lib/radio/Radio.tsx @@ -44,7 +44,7 @@ const cardLabelStyles = ` peer-disabled:hover:bg-gray-500 children:py-2 children:px-4 children:-mx-4 children:border-gray-400 - children:first:-mt-2 children:last:-mb-2 + first:children:-mt-2 last:children:-mb-2 peer-checked:children:border-green-500 cursor-pointer peer-disabled:cursor-default ` diff --git a/package.json b/package.json index b14527dd3..3322d73e6 100644 --- a/package.json +++ b/package.json @@ -108,7 +108,6 @@ "prettier": "2.4.0", "rollup": "^2.52.7", "tailwindcss": "^3.0.0-alpha.2", - "tailwindcss-children": "^2.1.0", "ts-node": "^9.1.1", "tsconfig-paths-webpack-plugin": "^3.5.1", "typescript": "~4.4.2", diff --git a/tailwind.config.js b/tailwind.config.js index 5dd2bfa2b..3f538115c 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -3,9 +3,6 @@ /** @type {import('tailwindcss/lib/util/createPlugin').default} */ // @ts-ignore const plugin = require('tailwindcss/plugin') -const defaultConfig = require('tailwindcss/defaultConfig') - -const childrenPlugin = require('tailwindcss-children') /** @type {import('tailwindcss/tailwind-config').TailwindConfig} */ module.exports = { @@ -75,11 +72,6 @@ module.exports = { // imitation of the twin.macro svg: variant. svg:text-green-500 puts green // on an SVG that's an immediate child of the element plugin(({ addVariant }) => addVariant('svg', '& > svg')), - childrenPlugin, + plugin(({ addVariant }) => addVariant('children', '& > *')), ], - /** - * TODO: This isn't respected, need an upstream fix. - * @see https://github.com/tailwindlabs/tailwindcss/issues/3949 - */ - variantOrder: ['children', ...defaultConfig.variantOrder, 'svg'], } diff --git a/yarn.lock b/yarn.lock index 5e519280c..9a4a6a117 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12769,14 +12769,6 @@ table@^6.0.9: string-width "^4.2.3" strip-ansi "^6.0.1" -tailwindcss-children@^2.1.0: - version "2.1.0" - resolved "https://registry.npmjs.org/tailwindcss-children/-/tailwindcss-children-2.1.0.tgz" - integrity sha512-ND+qLjco864/h85VUhF8LpNimZefcskGUdt9R94NXA+QWNqKVp5HmfILYgPioCZ+zUr7LmV+C6ijpaiwTSKZxA== - dependencies: - lodash "^4.17.15" - postcss-selector-parser "^6.0.2" - tailwindcss@^3.0.0-alpha.2: version "3.0.0-alpha.2" resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.0.0-alpha.2.tgz#9f0f797aeabc0294169d732f3379538222e0a44a" From b4df62f1f39a577c013f61587ae31022be0cc633 Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 15:38:11 -0600 Subject: [PATCH 5/7] oh yeah... use stroke-green-500 --- app/pages/ProjectsPage.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/pages/ProjectsPage.tsx b/app/pages/ProjectsPage.tsx index a96b6a7f0..df895b322 100644 --- a/app/pages/ProjectsPage.tsx +++ b/app/pages/ProjectsPage.tsx @@ -27,7 +27,7 @@ const Metric = ({ label, value, className }: MetricProps) => (
    {value}
    - +
    From 7598d78bdb4afdd7cd62df7849ecc2c30deb0326 Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 15:52:14 -0600 Subject: [PATCH 6/7] each variant doesn't need its own plugin --- tailwind.config.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tailwind.config.js b/tailwind.config.js index 3f538115c..95914b108 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -69,9 +69,11 @@ module.exports = { }, }, plugins: [ - // imitation of the twin.macro svg: variant. svg:text-green-500 puts green - // on an SVG that's an immediate child of the element - plugin(({ addVariant }) => addVariant('svg', '& > svg')), - plugin(({ addVariant }) => addVariant('children', '& > *')), + plugin(({ addVariant }) => { + // imitation of the twin.macro svg: variant. svg:text-green-500 puts green + // on an SVG that's an immediate child of the element + addVariant('svg', '& > svg') + addVariant('children', '& > *') + }), ], } From 243b10775bff37a216f0167115b774ad040492d0 Mon Sep 17 00:00:00 2001 From: David Crespo Date: Tue, 16 Nov 2021 18:20:11 -0600 Subject: [PATCH 7/7] update yarn.lock after merging main --- yarn.lock | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/yarn.lock b/yarn.lock index 35c781f68..ad0264b60 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5728,6 +5728,11 @@ css-tree@^1.1.2: mdn-data "2.0.14" source-map "^0.6.1" +css-unit-converter@^1.1.1: + version "1.1.2" + resolved "https://registry.yarnpkg.com/css-unit-converter/-/css-unit-converter-1.1.2.tgz#4c77f5a1954e6dbff60695ecb214e3270436ab21" + integrity sha512-IiJwMC8rdZE0+xiEZHeru6YoONC4rfPMqGm2W85jMIbkFvv5nFTwJVFHam2eFrN6txmoUYFAFXiv8ICVeTO0MA== + css-what@^3.2.1: version "3.4.2" resolved "https://registry.npmjs.org/css-what/-/css-what-3.4.2.tgz" @@ -9543,11 +9548,6 @@ lodash.throttle@^4.1.1: resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz#c23e91b710242ac70c37f1e1cda9274cc39bf2f4" integrity sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ= -lodash.topath@^4.5.2: - version "4.5.2" - resolved "https://registry.npmjs.org/lodash.topath/-/lodash.topath-4.5.2.tgz" - integrity sha1-NhY1Hzu6YZlKCTGYlmC9AyVP0Ak= - lodash.truncate@^4.4.2: version "4.4.2" resolved "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz" @@ -11064,6 +11064,11 @@ postcss-selector-parser@^6.0.0, postcss-selector-parser@^6.0.2, postcss-selector cssesc "^3.0.0" util-deprecate "^1.0.2" +postcss-value-parser@^3.3.0: + version "3.3.1" + resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-3.3.1.tgz#9ff822547e2893213cf1c30efa51ac5fd1ba8281" + integrity sha512-pISE66AbVkp4fDQ7VHBwRNXzAAKJjw4Vw7nWI/+Q3vuly7SNfgYXvm6i5IgFylHGK5sP/xHAbB7N49OS4gWNyQ== + postcss-value-parser@^4.0.0, postcss-value-parser@^4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.1.0.tgz" @@ -11828,6 +11833,14 @@ redent@^3.0.0: indent-string "^4.0.0" strip-indent "^3.0.0" +reduce-css-calc@^2.1.8: + version "2.1.8" + resolved "https://registry.yarnpkg.com/reduce-css-calc/-/reduce-css-calc-2.1.8.tgz#7ef8761a28d614980dc0c982f772c93f7a99de03" + integrity sha512-8liAVezDmUcH+tdzoEGrhfbGcP7nOV4NkGE3a74+qqvE7nt9i4sKLGBuZNOnpI4WiGksiNPklZxva80061QiPg== + dependencies: + css-unit-converter "^1.1.1" + postcss-value-parser "^3.3.0" + refractor@^3.1.0: version "3.3.1" resolved "https://registry.npmjs.org/refractor/-/refractor-3.3.1.tgz"