diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000..72bd915 --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @cloudnode-pro/development diff --git a/.github/dependabot.yaml b/.github/dependabot.yaml new file mode 100644 index 0000000..0840537 --- /dev/null +++ b/.github/dependabot.yaml @@ -0,0 +1,19 @@ +version: 2 +updates: + - package-ecosystem: npm + directory: / + schedule: + interval: weekly + day: monday + time: "06:00" + reviewers: + - cloudnode-pro/development + + - package-ecosystem: github-actions + directory: / + schedule: + interval: weekly + day: monday + time: "06:00" + reviewers: + - cloudnode-pro/development diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 21a13b8..d7a7712 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -12,8 +12,8 @@ jobs: contents: read id-token: write steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 20 registry-url: https://registry.npmjs.org/ diff --git a/LICENSE b/LICENSE deleted file mode 100644 index 6a3ec1f..0000000 --- a/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2024 Cloudnode OÜ. - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/README.md b/README.md index 673310f..f5e6354 100644 --- a/README.md +++ b/README.md @@ -2,13 +2,24 @@ This plugin allows you to target parent nodes with a child that has `:focus-visible`. -## Usage +## Installation Install as dev-dependency using: ```sh npm i -D tailwindcss-focus-visible-within ``` + +### Tailwind CSS v4 + +Add the plugin to your style sheet: + +```css +@plugin "tailwindcss-focus-visible-within"; +``` + +### Tailwind CSS v3 + Add the plugin to your `tailwind.config.js`: ```js @@ -17,12 +28,15 @@ module.exports = { // … }, plugins: [ - require('tailwindcss-focus-visible-within') + require("tailwindcss-focus-visible-within") // … ], } ``` -You can now apply Tailwind classes to a parent node that has an element child with the `focus-visible` state. + +## Usage + +You can apply Tailwind CSS classes to a parent node that has an element child with the `focus-visible` state. ```html
diff --git a/UNLICENSE b/UNLICENSE new file mode 100644 index 0000000..efb9808 --- /dev/null +++ b/UNLICENSE @@ -0,0 +1,24 @@ +This is free and unencumbered software released into the public domain. + +Anyone is free to copy, modify, publish, use, compile, sell, or +distribute this software, either in source code form or as a compiled +binary, for any purpose, commercial or non-commercial, and by any +means. + +In jurisdictions that recognize copyright laws, the author or authors +of this software dedicate any and all copyright interest in the +software to the public domain. We make this dedication for the benefit +of the public at large and to the detriment of our heirs and +successors. We intend this dedication to be an overt act of +relinquishment in perpetuity of all present and future rights to this +software under copyright law. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +For more information, please refer to diff --git a/package-lock.json b/package-lock.json index 6a71d62..f961eb1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7,7 +7,7 @@ "": { "name": "tailwindcss-focus-visible-within", "version": "0.0.0-dev", - "license": "MIT", + "license": "Unlicense", "peerDependencies": { "tailwindcss": "^3.4.1" } diff --git a/package.json b/package.json index 65af6a0..547d164 100644 --- a/package.json +++ b/package.json @@ -18,12 +18,12 @@ "tailwindcss-plugin" ], "author": "Cloudnode", - "license": "MIT", + "license": "Unlicense", "bugs": { "url": "https://github.com/cloudnode-pro/tailwindcss-focus-visible-within/issues" }, "homepage": "https://github.com/cloudnode-pro/tailwindcss-focus-visible-within#readme", "peerDependencies": { - "tailwindcss": "^3.4.1" + "tailwindcss": "^3.4.1 || ^4.0.0" } }