From 5d48321534c5d1012f6ad411472e5ce963920952 Mon Sep 17 00:00:00 2001 From: Vlad Moroz Date: Thu, 21 Nov 2024 18:18:38 +0100 Subject: [PATCH 1/3] Upgrade Tailwind --- docs/package.json | 6 +- .../demos/hero/css-modules/index.module.css | 3 +- .../dialog/demos/hero/tailwind/index.tsx | 6 +- docs/src/app/new/layout.css | 2 + docs/src/app/new/layout.tsx | 10 +- docs/src/components/GhostButton.css | 7 + docs/src/components/Select.css | 1 + docs/src/components/demo/index.css | 14 ++ package.json | 8 +- pnpm-lock.yaml | 175 +++++++++--------- prettier.config.js | 1 + 11 files changed, 130 insertions(+), 103 deletions(-) diff --git a/docs/package.json b/docs/package.json index 41a4b9311..d365739b7 100644 --- a/docs/package.json +++ b/docs/package.json @@ -76,7 +76,7 @@ "@mui/internal-docs-utils": "^1.0.15", "@mui/internal-scripts": "^1.0.26", "@mui/internal-test-utils": "https://pkg.csb.dev/mui/material-ui/commit/92c23999/@mui/internal-test-utils", - "@tailwindcss/postcss": "4.0.0-alpha.34", + "@tailwindcss/postcss": "4.0.0-alpha.36", "@types/chai": "^4.3.20", "@types/gtag.js": "^0.0.20", "@types/hast": "^3.0.4", @@ -89,10 +89,10 @@ "framer-motion": "^11.11.11", "fs-extra": "^11.2.0", "mdast-util-mdx-jsx": "^3.1.3", - "prettier": "^3.2.5", + "prettier": "^3.3.3", "rimraf": "^5.0.10", "serve": "^14.2.4", - "tailwindcss": "4.0.0-alpha.34", + "tailwindcss": "4.0.0-alpha.36", "unified": "^11.0.5", "webpack-bundle-analyzer": "^4.10.2", "yargs": "^17.7.2" diff --git a/docs/src/app/new/(content)/components/dialog/demos/hero/css-modules/index.module.css b/docs/src/app/new/(content)/components/dialog/demos/hero/css-modules/index.module.css index 4446d1c16..251a47781 100644 --- a/docs/src/app/new/(content)/components/dialog/demos/hero/css-modules/index.module.css +++ b/docs/src/app/new/(content)/components/dialog/demos/hero/css-modules/index.module.css @@ -9,7 +9,7 @@ background-color: var(--color-gray-50); font: inherit; font-weight: 500; - color: var(--color-gray-900); + color: var(--color-gray-950); outline: 1px solid var(--color-gray-200); user-select: none; @@ -59,6 +59,7 @@ border-radius: 0.5rem; border: 1px solid var(--color-gray-300); background-color: var(--color-gray-50); + color: var(--color-gray-950); outline: 0; transition: all 150ms; diff --git a/docs/src/app/new/(content)/components/dialog/demos/hero/tailwind/index.tsx b/docs/src/app/new/(content)/components/dialog/demos/hero/tailwind/index.tsx index a072a98d8..8ba5fe55b 100644 --- a/docs/src/app/new/(content)/components/dialog/demos/hero/tailwind/index.tsx +++ b/docs/src/app/new/(content)/components/dialog/demos/hero/tailwind/index.tsx @@ -4,18 +4,18 @@ import { Dialog } from '@base-ui-components/react/Dialog'; export default function ExampleDialog() { return ( - + View notifications - + Your notifications You are all caught up. Good job! - + Close diff --git a/docs/src/app/new/layout.css b/docs/src/app/new/layout.css index 4df4e3946..f5833a879 100644 --- a/docs/src/app/new/layout.css +++ b/docs/src/app/new/layout.css @@ -1,4 +1,6 @@ html { + color-scheme: light dark; + /* macOS overscroll background */ background-color: #000; } diff --git a/docs/src/app/new/layout.tsx b/docs/src/app/new/layout.tsx index 00b278b36..aeecaecd7 100644 --- a/docs/src/app/new/layout.tsx +++ b/docs/src/app/new/layout.tsx @@ -5,12 +5,12 @@ import './layout.css'; export default function Layout({ children }: React.PropsWithChildren) { return (
- - + +
- - -
{children}
+ + +
{children}
); diff --git a/docs/src/components/GhostButton.css b/docs/src/components/GhostButton.css index f6820d1ac..b2e8a1fb5 100644 --- a/docs/src/components/GhostButton.css +++ b/docs/src/components/GhostButton.css @@ -1,5 +1,12 @@ @layer components { .GhostButton { + /* Reset browser defaults */ + background: none; + border-radius: 0; + border: none; + color: inherit; + padding: 0; + @apply text-xs; color: var(--color-gray); cursor: default; diff --git a/docs/src/components/Select.css b/docs/src/components/Select.css index 007e7aa80..f8299e887 100644 --- a/docs/src/components/Select.css +++ b/docs/src/components/Select.css @@ -8,6 +8,7 @@ .SelectOption { @apply text-xs; + outline: 0; display: grid; grid-template-columns: 1rem auto; align-items: center; diff --git a/docs/src/components/demo/index.css b/docs/src/components/demo/index.css index 888277af6..f9f237b18 100644 --- a/docs/src/components/demo/index.css +++ b/docs/src/components/demo/index.css @@ -89,6 +89,13 @@ } .DemoTab { + /* Reset browser defaults */ + background: none; + border-radius: 0; + border: none; + color: inherit; + padding: 0; + font-family: var(--font-mono); font-size: 0.8125rem; line-height: 1.25rem; @@ -225,6 +232,13 @@ } .DemoCollapseButton { + /* Reset browser defaults */ + background: none; + border-radius: 0; + border: none; + color: inherit; + padding: 0; + @apply text-xs; background-color: var(--color-gray-50); cursor: default; diff --git a/package.json b/package.json index 2a2331fd7..99cdcffed 100644 --- a/package.json +++ b/package.json @@ -88,7 +88,7 @@ "@next/eslint-plugin-next": "^14.2.17", "@octokit/rest": "^20.1.1", "@playwright/test": "1.48.2", - "@tailwindcss/postcss": "4.0.0-alpha.34", + "@tailwindcss/postcss": "4.0.0-alpha.36", "@types/fs-extra": "^11.0.4", "@types/lodash": "^4.17.13", "@types/mocha": "^10.0.8", @@ -154,8 +154,8 @@ "postcss": "^8.4.47", "postcss-loader": "^8.1.1", "postcss-styled-syntax": "^0.6.4", - "prettier": "^3.2.5", - "prettier-plugin-tailwindcss": "^0.6.8", + "prettier": "^3.3.3", + "prettier-plugin-tailwindcss": "^0.6.9", "pretty-quick": "^4.0.0", "process": "^0.11.10", "react": "19.0.0-rc-fb9a90fa48-20240614", @@ -168,7 +168,7 @@ "style-loader": "^4.0.0", "stylelint": "^16.4.0", "stylelint-config-standard": "^36.0.1", - "tailwindcss": "4.0.0-alpha.34", + "tailwindcss": "4.0.0-alpha.36", "terser": "^5.31.0", "terser-webpack-plugin": "^5.3.10", "tsx": "^4.8.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 66a174ced..aa6a3ec8b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -83,8 +83,8 @@ importers: specifier: 1.48.2 version: 1.48.2 '@tailwindcss/postcss': - specifier: 4.0.0-alpha.34 - version: 4.0.0-alpha.34 + specifier: 4.0.0-alpha.36 + version: 4.0.0-alpha.36 '@types/fs-extra': specifier: ^11.0.4 version: 11.0.4 @@ -281,14 +281,14 @@ importers: specifier: ^0.6.4 version: 0.6.4(postcss@8.4.47) prettier: - specifier: ^3.2.5 - version: 3.2.5 + specifier: ^3.3.3 + version: 3.3.3 prettier-plugin-tailwindcss: specifier: ^0.6.8 - version: 0.6.8(prettier@3.2.5) + version: 0.6.9(prettier@3.3.3) pretty-quick: specifier: ^4.0.0 - version: 4.0.0(prettier@3.2.5) + version: 4.0.0(prettier@3.3.3) process: specifier: ^0.11.10 version: 0.11.10 @@ -323,8 +323,8 @@ importers: specifier: ^36.0.1 version: 36.0.1(stylelint@16.4.0(typescript@5.6.3)) tailwindcss: - specifier: 4.0.0-alpha.34 - version: 4.0.0-alpha.34 + specifier: 4.0.0-alpha.36 + version: 4.0.0-alpha.36 terser: specifier: ^5.31.0 version: 5.31.0 @@ -540,8 +540,8 @@ importers: specifier: https://pkg.csb.dev/mui/material-ui/commit/92c23999/@mui/internal-test-utils version: https://pkg.csb.dev/mui/material-ui/commit/92c23999/@mui/internal-test-utils(@babel/core@7.26.0)(react-dom@19.0.0-rc-fb9a90fa48-20240614(react@19.0.0-rc-fb9a90fa48-20240614))(react@19.0.0-rc-fb9a90fa48-20240614)(types-react-dom@19.0.0-rc.1)(types-react@19.0.0-rc.1) '@tailwindcss/postcss': - specifier: 4.0.0-alpha.34 - version: 4.0.0-alpha.34 + specifier: 4.0.0-alpha.36 + version: 4.0.0-alpha.36 '@types/chai': specifier: ^4.3.20 version: 4.3.20 @@ -579,8 +579,8 @@ importers: specifier: ^3.1.3 version: 3.1.3 prettier: - specifier: ^3.2.5 - version: 3.2.5 + specifier: ^3.3.3 + version: 3.3.3 rimraf: specifier: ^5.0.10 version: 5.0.10 @@ -588,8 +588,8 @@ importers: specifier: ^14.2.4 version: 14.2.4 tailwindcss: - specifier: 4.0.0-alpha.34 - version: 4.0.0-alpha.34 + specifier: 4.0.0-alpha.36 + version: 4.0.0-alpha.36 unified: specifier: ^11.0.5 version: 11.0.5 @@ -2909,81 +2909,81 @@ packages: '@swc/helpers@0.5.13': resolution: {integrity: sha512-UoKGxQ3r5kYI9dALKJapMmuK+1zWM/H17Z1+iwnNmzcJRnfFuevZs375TA5rW31pu4BS4NoSy1fRsexDXfWn5w==} - '@tailwindcss/node@4.0.0-alpha.34': - resolution: {integrity: sha512-AZiYQCGqbRMe+fEu2sJZp7dLYOG/7JCRI16QRodn+gJ4ZSeTrv22dRb/VKV+c7ate3W+/RTS8ToKPmo4VT/SHw==} + '@tailwindcss/node@4.0.0-alpha.36': + resolution: {integrity: sha512-SQDP+Dxx6R3uMvgSIFm/gfZT4wK5pl3P2cJO2FfEHyO2NebRED4+QhP4FG2voTLfZiukRFESkuOjte1618Rc0w==} - '@tailwindcss/oxide-android-arm64@4.0.0-alpha.34': - resolution: {integrity: sha512-bkTCHLkHaR4nfKegCXJHakf9IXC0JiqVHWO+eI8W7D1WSfU8kixnSVrYOElaRO+72MseFQ6JK+WNnirftP+xQg==} + '@tailwindcss/oxide-android-arm64@4.0.0-alpha.36': + resolution: {integrity: sha512-sDA2JOnxX7o1kQMJzWEOqPBsgstpnYLlyMCsh78ZF+cdcnTzBuarMRBCmLbrdIKALlQLRHWCR/yccaXNxh6plQ==} engines: {node: '>= 10'} cpu: [arm64] os: [android] - '@tailwindcss/oxide-darwin-arm64@4.0.0-alpha.34': - resolution: {integrity: sha512-Il1l88Hjjb8lGzyF2xOPsb3xaV4KeBmqRXdUC8E2oSHUzAiZAJZSxhbB1f8o7ZRyLGAgwnHe1jHYZ8NSE9u/HQ==} + '@tailwindcss/oxide-darwin-arm64@4.0.0-alpha.36': + resolution: {integrity: sha512-rqF0A99RDcLz4EOsIdSHU2OfyGSXhGNZ9UTN2qvhHuaDYGWIOm4OAiAhpRRSQL9bh5DNEtEwQT0eWnMpOmCeDQ==} engines: {node: '>= 10'} cpu: [arm64] os: [darwin] - '@tailwindcss/oxide-darwin-x64@4.0.0-alpha.34': - resolution: {integrity: sha512-6EfsqKPLNaeVo6pTn4bN4ApvHbLkn8mk0+HS2LrDOE8kmAIGYtyhyvBh1fZY8cb7wBxxqnTWz9fVhLHkTgPSrQ==} + '@tailwindcss/oxide-darwin-x64@4.0.0-alpha.36': + resolution: {integrity: sha512-FiEWPxxaMCuudXnxglfpeI9hu7OJ1zyn2ZPRFna92GI2jCKhQmYkyrbcKtgZRx/GDUcTRSq4Wx16XMfCCNxP2g==} engines: {node: '>= 10'} cpu: [x64] os: [darwin] - '@tailwindcss/oxide-freebsd-x64@4.0.0-alpha.34': - resolution: {integrity: sha512-eGgP5txixVU9Km7PPrCSZ4mLbboIKmV3hlasdyiCVIrEDnj40jo7r8/NqXpHtQbf/39mlsXzyDUtz2kP/HfgBQ==} + '@tailwindcss/oxide-freebsd-x64@4.0.0-alpha.36': + resolution: {integrity: sha512-COCw/4AIgcDmWJBpk+hpU03DNcnb2yoanMSy1wMwrwc2OnXMvxOVY3SjcsSYbP2E2wcQJXn/kGgMPvQa0yzdmw==} engines: {node: '>= 10'} cpu: [x64] os: [freebsd] - '@tailwindcss/oxide-linux-arm-gnueabihf@4.0.0-alpha.34': - resolution: {integrity: sha512-iqefLskJthiTXvT+SyOG6Rcq2+xWKoOmKcYmGFIYJ4Dd48KXoaz9nxBSJx6IySRDqTkDcDR9kKr5+zbztaryPA==} + '@tailwindcss/oxide-linux-arm-gnueabihf@4.0.0-alpha.36': + resolution: {integrity: sha512-+gRJ1jmJs4yi1tjsSi5nODLA6jpW35KuPp+iq5a/HU3LsnVwRH0kRx2XCOVWzpDUjZZJTRw9vCDEHSUZ434hcw==} engines: {node: '>= 10'} cpu: [arm] os: [linux] - '@tailwindcss/oxide-linux-arm64-gnu@4.0.0-alpha.34': - resolution: {integrity: sha512-JJJS8MfXtf2UlkGqEGBXLGTHLC6u7sqCAQ6hygB70ahPvFCBJgEmxMU4vFoIntoreUT+CzT6S3z1NCchI7ArjA==} + '@tailwindcss/oxide-linux-arm64-gnu@4.0.0-alpha.36': + resolution: {integrity: sha512-uaXXFNn3bzbFmylRuHtRIIXGl6b14Ufk+ZTOHhBLnzOnXZd01Gs0QgYbxG9UP1mqQUm90MFFb1yQq03c5tuqeg==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - '@tailwindcss/oxide-linux-arm64-musl@4.0.0-alpha.34': - resolution: {integrity: sha512-Uf1gpoj0toh/ofojNxn/Q/pRVMHLvN1P18ukzjp0xwY6Lnr78w9yc955L7eXN9FUGzzjL2mjJE1fFBsGR85qmg==} + '@tailwindcss/oxide-linux-arm64-musl@4.0.0-alpha.36': + resolution: {integrity: sha512-j9oazW3+3AHGWDkCXEOvATBjPrr9Db+Ynj3QR20/5BAF8Cxz4I+YZRa2Gt1A02ZeEfjRFOJN0joVkpMkhdJXvQ==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - '@tailwindcss/oxide-linux-x64-gnu@4.0.0-alpha.34': - resolution: {integrity: sha512-tOohkIUVzwIp3m5EqL5iTYlAj5M4FH+bHMmV09zitcbd6Kl3hbMfrmtPx/EAlCqjEHMMgBbhd61grOSbWe5lIA==} + '@tailwindcss/oxide-linux-x64-gnu@4.0.0-alpha.36': + resolution: {integrity: sha512-dgEAweIuIhhDTYyaT7FOKpsP/UsOv/uZAQFwAXTEtn348x8VO3sO/O4exDmZ0/4WbrQ2inE+T8iHZSdmoC65KQ==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - '@tailwindcss/oxide-linux-x64-musl@4.0.0-alpha.34': - resolution: {integrity: sha512-WBVvFt69MZAy9uMMX9h7H6MJJmdIoRj2QJJA8p9VOxFwoEhO9cc/DnXIP6pWajibwzC47PevIUgvNFIXdg4t9Q==} + '@tailwindcss/oxide-linux-x64-musl@4.0.0-alpha.36': + resolution: {integrity: sha512-rwY1Y5n1NCZe8q+eyeZAwDXvw+cjPTBqfoWPF9eYjxQHyL+9FT1J9aUMKCPhbuMqn8BkaP54vEvGsqG39ccCmA==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - '@tailwindcss/oxide-win32-arm64-msvc@4.0.0-alpha.34': - resolution: {integrity: sha512-rwuBrvlWgY0/VZzyiV/HRZdHEorrqf/BY2R+LeS/meo4oW2eHNnjl8+GUN6M1XMWyYiGsoEyokxE1BpQQb5g+A==} + '@tailwindcss/oxide-win32-arm64-msvc@4.0.0-alpha.36': + resolution: {integrity: sha512-5nZYJUu2mhY1guBABAHjWHsYQHn+XjFlDYC3JOU53FKrT8jhbFcePWvrBDPf85ykzGsabbpphCMKrfGR5A30Gg==} engines: {node: '>= 10'} cpu: [arm64] os: [win32] - '@tailwindcss/oxide-win32-x64-msvc@4.0.0-alpha.34': - resolution: {integrity: sha512-WRk86AAnSuZYbPPG1VjNzal+VqHLr9XaZWO7SVfZHB0yl+oCSqNi57eohjfi9X6/h6hZfpF+jqB7m/Nf4iMdrg==} + '@tailwindcss/oxide-win32-x64-msvc@4.0.0-alpha.36': + resolution: {integrity: sha512-ykj5jLuWZwL6MF/UU46eZ97r8qmUZEwXKzJS9lK4Cktg9W9iBkDBXdX0/MKYLmsZGGtt4kj4KmYWqUAVgIWwZg==} engines: {node: '>= 10'} cpu: [x64] os: [win32] - '@tailwindcss/oxide@4.0.0-alpha.34': - resolution: {integrity: sha512-tvC/Fkq7vWxFTgyWrM8czxgMwYiqfY3/pxV/e6bbTaX/Z7ZomukDErVTyExI67e4igjq4/P5VWdbSiM+bBAXOw==} + '@tailwindcss/oxide@4.0.0-alpha.36': + resolution: {integrity: sha512-vFnXcKgMsbWpU4iy5TYA1SOl1vkQYbZXmHj7uQbTRnGaSn3LirumO0uideaciF4NIx+Gb99GnB5ro6G8uXN90Q==} engines: {node: '>= 10'} - '@tailwindcss/postcss@4.0.0-alpha.34': - resolution: {integrity: sha512-vxzEVJoGeYTjPh7VhhrsAXg+c8CqJ9GrtP9ugNRURFOos7PPKvNRS4k5vATLAJDrfPZgF2pHXtbjyunsLCEWSQ==} + '@tailwindcss/postcss@4.0.0-alpha.36': + resolution: {integrity: sha512-xpf4N8yne/QqdXWoTR0jrkRVruDnRglLJ4kXxU5ig6FY9mauEueyh+Lo2HJgSU9JZRRQ8skEYGIGTfIK3B0WvQ==} '@testing-library/dom@10.4.0': resolution: {integrity: sha512-pemlzrSESWbdAloYml3bAJMEfNh1Z7EduzqPKprCH5S341frlpYnUEW0H72dLxa6IsYr+mPno20GiSm+h9dEdQ==} @@ -6162,8 +6162,8 @@ packages: resolution: {integrity: sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q==} hasBin: true - jiti@2.3.3: - resolution: {integrity: sha512-EX4oNDwcXSivPrw2qKH2LB5PoFxEvgtv2JgwW0bU858HoLQ+kutSvjLMUqBd0PeJYEinLWhoI9Ol0eYMqj/wNQ==} + jiti@2.4.0: + resolution: {integrity: sha512-H5UpaUI+aHOqZXlYOaFP/8AzKsg+guWu+Pr3Y8i7+Y3zr1aXAvCvTAQ1RxSc6oVD8R8c7brgNtTVP91E7upH/g==} hasBin: true js-tokens@4.0.0: @@ -7719,8 +7719,8 @@ packages: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} engines: {node: '>= 0.8.0'} - prettier-plugin-tailwindcss@0.6.8: - resolution: {integrity: sha512-dGu3kdm7SXPkiW4nzeWKCl3uoImdd5CTZEJGxyypEPL37Wj0HT2pLqjrvSei1nTeuQfO4PUfjeW5cTUNRLZ4sA==} + prettier-plugin-tailwindcss@0.6.9: + resolution: {integrity: sha512-r0i3uhaZAXYP0At5xGfJH876W3HHGHDp+LCRUJrs57PBeQ6mYHMwr25KH8NPX44F2yGTvdnH7OqCshlQx183Eg==} engines: {node: '>=14.21.3'} peerDependencies: '@ianvs/prettier-plugin-sort-imports': '*' @@ -7774,8 +7774,8 @@ packages: prettier-plugin-svelte: optional: true - prettier@3.2.5: - resolution: {integrity: sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A==} + prettier@3.3.3: + resolution: {integrity: sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==} engines: {node: '>=14'} hasBin: true @@ -8741,8 +8741,8 @@ packages: resolution: {integrity: sha512-w2sfv80nrAh2VCbqR5AK27wswXhqcck2AhfnNW76beQXskGZ1V12GwS//yYVa3d3fcvAip2OUnbDAjW2k3v9fA==} engines: {node: '>=10.0.0'} - tailwindcss@4.0.0-alpha.34: - resolution: {integrity: sha512-SST1h774z+bVCLTpRz4TYpjJLIcomZH1HBF4OPY1YusONUYqg0/XTq0N++12mNeyu6mK7VbFIkkNtf636yudWQ==} + tailwindcss@4.0.0-alpha.36: + resolution: {integrity: sha512-dbI1o+KJ+anCe/RI7/RuaG8IReQromxF2DLgPQCIQALzfXrosfX9UovahoNRXvyCaAqRP5KWQGagvvTmW44irQ==} tapable@0.1.10: resolution: {integrity: sha512-jX8Et4hHg57mug1/079yitEKWGB3LCwoxByLsNim89LABq8NqgiX+6iYVOsq0vX8uJHkU+DZ5fnq95f800bEsQ==} @@ -12048,66 +12048,67 @@ snapshots: dependencies: tslib: 2.6.2 - '@tailwindcss/node@4.0.0-alpha.34': + '@tailwindcss/node@4.0.0-alpha.36': dependencies: enhanced-resolve: 5.17.1 - jiti: 2.3.3 + jiti: 2.4.0 + tailwindcss: 4.0.0-alpha.36 - '@tailwindcss/oxide-android-arm64@4.0.0-alpha.34': + '@tailwindcss/oxide-android-arm64@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-darwin-arm64@4.0.0-alpha.34': + '@tailwindcss/oxide-darwin-arm64@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-darwin-x64@4.0.0-alpha.34': + '@tailwindcss/oxide-darwin-x64@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-freebsd-x64@4.0.0-alpha.34': + '@tailwindcss/oxide-freebsd-x64@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-linux-arm-gnueabihf@4.0.0-alpha.34': + '@tailwindcss/oxide-linux-arm-gnueabihf@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-linux-arm64-gnu@4.0.0-alpha.34': + '@tailwindcss/oxide-linux-arm64-gnu@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-linux-arm64-musl@4.0.0-alpha.34': + '@tailwindcss/oxide-linux-arm64-musl@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-linux-x64-gnu@4.0.0-alpha.34': + '@tailwindcss/oxide-linux-x64-gnu@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-linux-x64-musl@4.0.0-alpha.34': + '@tailwindcss/oxide-linux-x64-musl@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-win32-arm64-msvc@4.0.0-alpha.34': + '@tailwindcss/oxide-win32-arm64-msvc@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide-win32-x64-msvc@4.0.0-alpha.34': + '@tailwindcss/oxide-win32-x64-msvc@4.0.0-alpha.36': optional: true - '@tailwindcss/oxide@4.0.0-alpha.34': + '@tailwindcss/oxide@4.0.0-alpha.36': optionalDependencies: - '@tailwindcss/oxide-android-arm64': 4.0.0-alpha.34 - '@tailwindcss/oxide-darwin-arm64': 4.0.0-alpha.34 - '@tailwindcss/oxide-darwin-x64': 4.0.0-alpha.34 - '@tailwindcss/oxide-freebsd-x64': 4.0.0-alpha.34 - '@tailwindcss/oxide-linux-arm-gnueabihf': 4.0.0-alpha.34 - '@tailwindcss/oxide-linux-arm64-gnu': 4.0.0-alpha.34 - '@tailwindcss/oxide-linux-arm64-musl': 4.0.0-alpha.34 - '@tailwindcss/oxide-linux-x64-gnu': 4.0.0-alpha.34 - '@tailwindcss/oxide-linux-x64-musl': 4.0.0-alpha.34 - '@tailwindcss/oxide-win32-arm64-msvc': 4.0.0-alpha.34 - '@tailwindcss/oxide-win32-x64-msvc': 4.0.0-alpha.34 - - '@tailwindcss/postcss@4.0.0-alpha.34': + '@tailwindcss/oxide-android-arm64': 4.0.0-alpha.36 + '@tailwindcss/oxide-darwin-arm64': 4.0.0-alpha.36 + '@tailwindcss/oxide-darwin-x64': 4.0.0-alpha.36 + '@tailwindcss/oxide-freebsd-x64': 4.0.0-alpha.36 + '@tailwindcss/oxide-linux-arm-gnueabihf': 4.0.0-alpha.36 + '@tailwindcss/oxide-linux-arm64-gnu': 4.0.0-alpha.36 + '@tailwindcss/oxide-linux-arm64-musl': 4.0.0-alpha.36 + '@tailwindcss/oxide-linux-x64-gnu': 4.0.0-alpha.36 + '@tailwindcss/oxide-linux-x64-musl': 4.0.0-alpha.36 + '@tailwindcss/oxide-win32-arm64-msvc': 4.0.0-alpha.36 + '@tailwindcss/oxide-win32-x64-msvc': 4.0.0-alpha.36 + + '@tailwindcss/postcss@4.0.0-alpha.36': dependencies: '@alloc/quick-lru': 5.2.0 - '@tailwindcss/node': 4.0.0-alpha.34 - '@tailwindcss/oxide': 4.0.0-alpha.34 + '@tailwindcss/node': 4.0.0-alpha.36 + '@tailwindcss/oxide': 4.0.0-alpha.36 lightningcss: 1.27.0 postcss: 8.4.47 - tailwindcss: 4.0.0-alpha.34 + tailwindcss: 4.0.0-alpha.36 '@testing-library/dom@10.4.0': dependencies: @@ -15933,7 +15934,7 @@ snapshots: jiti@1.21.0: {} - jiti@2.3.3: {} + jiti@2.4.0: {} js-tokens@4.0.0: {} @@ -18008,11 +18009,11 @@ snapshots: prelude-ls@1.2.1: {} - prettier-plugin-tailwindcss@0.6.8(prettier@3.2.5): + prettier-plugin-tailwindcss@0.6.9(prettier@3.3.3): dependencies: - prettier: 3.2.5 + prettier: 3.3.3 - prettier@3.2.5: {} + prettier@3.3.3: {} pretty-error@4.0.0: dependencies: @@ -18035,7 +18036,7 @@ snapshots: dependencies: parse-ms: 4.0.0 - pretty-quick@4.0.0(prettier@3.2.5): + pretty-quick@4.0.0(prettier@3.3.3): dependencies: execa: 5.1.1 find-up: 5.0.0 @@ -18043,7 +18044,7 @@ snapshots: mri: 1.2.0 picocolors: 1.1.0 picomatch: 3.0.1 - prettier: 3.2.5 + prettier: 3.3.3 tslib: 2.6.2 prettyjson@1.2.5: @@ -19242,7 +19243,7 @@ snapshots: string-width: 4.2.3 strip-ansi: 6.0.1 - tailwindcss@4.0.0-alpha.34: {} + tailwindcss@4.0.0-alpha.36: {} tapable@0.1.10: {} diff --git a/prettier.config.js b/prettier.config.js index 2553a2273..2ffd6d1a2 100644 --- a/prettier.config.js +++ b/prettier.config.js @@ -3,6 +3,7 @@ module.exports = { singleQuote: true, trailingComma: 'all', plugins: ['prettier-plugin-tailwindcss'], + tailwindStylesheet: './docs/src/styles.css', overrides: [ { files: ['docs/**/*.md', 'docs/src/app/**/*.{js,tsx}', 'docs/data/**/*.{js,tsx}'], From 5a52c49b729ecf07ade72272dc1b327b217e54df Mon Sep 17 00:00:00 2001 From: Vlad Moroz Date: Thu, 21 Nov 2024 18:22:07 +0100 Subject: [PATCH 2/3] Run prettier on everything --- docs/src/components/content/PackageManagerSnippet.tsx | 6 +++--- docs/src/mdx-components.tsx | 2 +- packages/react/src/Collapsible/Panel/useCollapsiblePanel.ts | 2 +- packages/react/src/Composite/List/useCompositeListItem.ts | 2 +- .../react/src/Field/Control/useFieldControlValidation.ts | 2 +- packages/react/src/Progress/Root/useProgressRoot.ts | 2 +- packages/react/src/Slider/Thumb/useSliderThumb.ts | 2 +- packages/react/src/useButton/useButton.ts | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/docs/src/components/content/PackageManagerSnippet.tsx b/docs/src/components/content/PackageManagerSnippet.tsx index 32ab1403b..4cef00acc 100644 --- a/docs/src/components/content/PackageManagerSnippet.tsx +++ b/docs/src/components/content/PackageManagerSnippet.tsx @@ -38,7 +38,7 @@ export function PackageManagerSnippet(props: PackageManagerSnippetProps) { export function Npm(props: React.PropsWithChildren) { return ( - + @@ -48,7 +48,7 @@ export function Npm(props: React.PropsWithChildren) { export function Pnpm(props: React.PropsWithChildren) { return ( - + @@ -58,7 +58,7 @@ export function Pnpm(props: React.PropsWithChildren) { export function Yarn(props: React.PropsWithChildren) { return ( - + diff --git a/docs/src/mdx-components.tsx b/docs/src/mdx-components.tsx index 6c4ce468c..006efbc78 100644 --- a/docs/src/mdx-components.tsx +++ b/docs/src/mdx-components.tsx @@ -57,7 +57,7 @@ export const mdxComponents: MDXComponents = { AttributesTable: (props) => , CssVariablesTable: (props) => , PropsTable: (props) => , - Subtitle: (props) =>

, + Subtitle: (props) =>

, }; export const inlineMdxComponents: MDXComponents = { diff --git a/packages/react/src/Collapsible/Panel/useCollapsiblePanel.ts b/packages/react/src/Collapsible/Panel/useCollapsiblePanel.ts index 7b7f1946b..d5d824fc2 100644 --- a/packages/react/src/Collapsible/Panel/useCollapsiblePanel.ts +++ b/packages/react/src/Collapsible/Panel/useCollapsiblePanel.ts @@ -145,7 +145,7 @@ export function useCollapsiblePanel( element.style.animationName = shouldCancelAnimation ? 'none' : originalAnimationName; element.style.transitionDuration = shouldCancelAnimation ? '0s' - : originalTransitionDuration ?? ''; + : (originalTransitionDuration ?? ''); runOnceAnimationsFinish(() => { ReactDOM.flushSync(() => { diff --git a/packages/react/src/Composite/List/useCompositeListItem.ts b/packages/react/src/Composite/List/useCompositeListItem.ts index 7a93d5621..c4cd337da 100644 --- a/packages/react/src/Composite/List/useCompositeListItem.ts +++ b/packages/react/src/Composite/List/useCompositeListItem.ts @@ -39,7 +39,7 @@ export function useCompositeListItem( elementsRef.current[index] = node; if (labelsRef) { const isLabelDefined = label !== undefined; - labelsRef.current[index] = isLabelDefined ? label : node?.textContent ?? null; + labelsRef.current[index] = isLabelDefined ? label : (node?.textContent ?? null); } } }, diff --git a/packages/react/src/Field/Control/useFieldControlValidation.ts b/packages/react/src/Field/Control/useFieldControlValidation.ts index 9c6b45a17..c47c9b360 100644 --- a/packages/react/src/Field/Control/useFieldControlValidation.ts +++ b/packages/react/src/Field/Control/useFieldControlValidation.ts @@ -90,7 +90,7 @@ export function useFieldControlValidation() { const nextValidityData = { value, state: nextState, - error: Array.isArray(result) ? result[0] : result ?? element.validationMessage, + error: Array.isArray(result) ? result[0] : (result ?? element.validationMessage), errors: validationErrors, initialValue: validityData.initialValue, }; diff --git a/packages/react/src/Progress/Root/useProgressRoot.ts b/packages/react/src/Progress/Root/useProgressRoot.ts index 31fdc5f41..282882dae 100644 --- a/packages/react/src/Progress/Root/useProgressRoot.ts +++ b/packages/react/src/Progress/Root/useProgressRoot.ts @@ -42,7 +42,7 @@ function useProgressRoot(parameters: useProgressRoot.Parameters): useProgressRoo 'aria-valuenow': value ?? undefined, 'aria-valuetext': getAriaValueText ? getAriaValueText(value) - : ariaValuetext ?? getDefaultAriaValueText(value), + : (ariaValuetext ?? getDefaultAriaValueText(value)), dir: direction, role: 'progressbar', }), diff --git a/packages/react/src/Slider/Thumb/useSliderThumb.ts b/packages/react/src/Slider/Thumb/useSliderThumb.ts index e1bc15ee4..74ca2b18e 100644 --- a/packages/react/src/Slider/Thumb/useSliderThumb.ts +++ b/packages/react/src/Slider/Thumb/useSliderThumb.ts @@ -247,7 +247,7 @@ export function useSliderThumb(parameters: useSliderThumb.Parameters): useSlider 'aria-valuenow': thumbValue, 'aria-valuetext': getAriaValueText ? getAriaValueText(thumbValue, index) - : ariaValuetext ?? getDefaultAriaValueText(sliderValues, index), + : (ariaValuetext ?? getDefaultAriaValueText(sliderValues, index)), 'data-index': index, disabled, id: inputId, diff --git a/packages/react/src/useButton/useButton.ts b/packages/react/src/useButton/useButton.ts index 1a7bd3fe6..b34bc0a63 100644 --- a/packages/react/src/useButton/useButton.ts +++ b/packages/react/src/useButton/useButton.ts @@ -108,7 +108,7 @@ export function useButton(parameters: useButton.Parameters = {}): useButton.Retu buttonProps.tabIndex = tabIndex ?? 0; if (disabled) { buttonProps['aria-disabled'] = disabled as boolean; - buttonProps.tabIndex = focusableWhenDisabled ? tabIndex ?? 0 : -1; + buttonProps.tabIndex = focusableWhenDisabled ? (tabIndex ?? 0) : -1; } } From 834c075b292b29b8618dd386f3430ff70e078379 Mon Sep 17 00:00:00 2001 From: Vlad Moroz Date: Thu, 21 Nov 2024 18:28:39 +0100 Subject: [PATCH 3/3] Update lockfile --- pnpm-lock.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index aa6a3ec8b..1faa294dd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -284,7 +284,7 @@ importers: specifier: ^3.3.3 version: 3.3.3 prettier-plugin-tailwindcss: - specifier: ^0.6.8 + specifier: ^0.6.9 version: 0.6.9(prettier@3.3.3) pretty-quick: specifier: ^4.0.0