summaryrefslogtreecommitdiff
path: root/node_modules/postcss-color-hex-alpha
diff options
context:
space:
mode:
authorlittleblack111 <littleblack11111@gmail.com>2026-05-18 23:10:59 +0800
committerlittleblack111 <littleblack11111@gmail.com>2026-05-18 23:41:44 +0800
commitfc87c009806dcc98867f6b58efe29b042aa01dee (patch)
tree8f59b3f4a5b66e9dfef2d40c8d318e258a521228 /node_modules/postcss-color-hex-alpha
parent3336b2356ee6152d9c6ae59bd9b87ccbc0958407 (diff)
node: updatemain
Diffstat (limited to 'node_modules/postcss-color-hex-alpha')
-rw-r--r--node_modules/postcss-color-hex-alpha/CHANGELOG.md21
-rw-r--r--node_modules/postcss-color-hex-alpha/LICENSE.md21
-rw-r--r--node_modules/postcss-color-hex-alpha/README.md85
-rw-r--r--node_modules/postcss-color-hex-alpha/dist/index.cjs1
-rw-r--r--node_modules/postcss-color-hex-alpha/dist/index.d.ts12
-rw-r--r--node_modules/postcss-color-hex-alpha/dist/index.mjs1
-rw-r--r--node_modules/postcss-color-hex-alpha/package.json87
7 files changed, 0 insertions, 228 deletions
diff --git a/node_modules/postcss-color-hex-alpha/CHANGELOG.md b/node_modules/postcss-color-hex-alpha/CHANGELOG.md
deleted file mode 100644
index f92bca0c..00000000
--- a/node_modules/postcss-color-hex-alpha/CHANGELOG.md
+++ /dev/null
@@ -1,21 +0,0 @@
-# Changes to PostCSS Color Hex Alpha
-
-### 9.0.4
-
-_February 19, 2024_
-
-- Reuse code with `@csstools/utilities`
-
-### 9.0.3
-
-_December 15, 2023_
-
-- Fix type definitions
-
-### 9.0.2
-
-_February 6, 2023_
-
-- Reduce the amount of duplicate fallback CSS.
-
-[Full CHANGELOG](https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-hex-alpha/CHANGELOG.md)
diff --git a/node_modules/postcss-color-hex-alpha/LICENSE.md b/node_modules/postcss-color-hex-alpha/LICENSE.md
deleted file mode 100644
index 6d704708..00000000
--- a/node_modules/postcss-color-hex-alpha/LICENSE.md
+++ /dev/null
@@ -1,21 +0,0 @@
-# The MIT License (MIT)
-
-Copyright © PostCSS
-
-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/node_modules/postcss-color-hex-alpha/README.md b/node_modules/postcss-color-hex-alpha/README.md
deleted file mode 100644
index 43c61092..00000000
--- a/node_modules/postcss-color-hex-alpha/README.md
+++ /dev/null
@@ -1,85 +0,0 @@
-# PostCSS Color Hex Alpha [<img src="https://postcss.github.io/postcss/logo.svg" alt="PostCSS Logo" width="90" height="90" align="right">][PostCSS]
-
-[<img alt="npm version" src="https://img.shields.io/npm/v/postcss-color-hex-alpha.svg" height="20">][npm-url] [<img alt="Build Status" src="https://github.com/csstools/postcss-plugins/workflows/test/badge.svg" height="20">][cli-url] [<img alt="Discord" src="https://shields.io/badge/Discord-5865F2?logo=discord&logoColor=white">][discord]<br><br>[<img alt="Baseline Status" src="https://cssdb.org/images/badges-baseline/hexadecimal-alpha-notation.svg" height="20">][css-url] [<img alt="CSS Standard Status" src="https://cssdb.org/images/badges/hexadecimal-alpha-notation.svg" height="20">][css-url]
-
-```bash
-npm install postcss-color-hex-alpha --save-dev
-```
-
-[PostCSS Color Hex Alpha] lets you use 4 & 8 character hex color notation in
-CSS, following the [CSS Color Module] specification.
-
-```pcss
-body {
- background: #9d9c;
-}
-
-/* becomes */
-
-body {
- background: rgba(153,221,153,0.8);
-}
-```
-
-## Usage
-
-Add [PostCSS Color Hex Alpha] to your project:
-
-```bash
-npm install postcss postcss-color-hex-alpha --save-dev
-```
-
-Use it as a [PostCSS] plugin:
-
-```js
-const postcss = require('postcss');
-const postcssColorHexAlpha = require('postcss-color-hex-alpha');
-
-postcss([
- postcssColorHexAlpha(/* pluginOptions */)
-]).process(YOUR_CSS /*, processOptions */);
-```
-
-[PostCSS Color Hex Alpha] runs in all Node environments, with special
-instructions for:
-
-- [Node](INSTALL.md#node)
-- [PostCSS CLI](INSTALL.md#postcss-cli)
-- [PostCSS Load Config](INSTALL.md#postcss-load-config)
-- [Webpack](INSTALL.md#webpack)
-- [Next.js](INSTALL.md#nextjs)
-- [Gulp](INSTALL.md#gulp)
-- [Grunt](INSTALL.md#grunt)
-
-## Options
-
-### preserve
-
-The `preserve` option determines whether the original notation
-is preserved. By default, it is not preserved.
-
-```js
-postcssColorHexAlpha({ preserve: true })
-```
-
-```pcss
-body {
- background: #9d9c;
-}
-
-/* becomes */
-
-body {
- background: rgba(153,221,153,0.8);
- background: #9d9c;
-}
-```
-
-[cli-url]: https://github.com/csstools/postcss-plugins/actions/workflows/test.yml?query=workflow/test
-[css-url]: https://cssdb.org/#hexadecimal-alpha-notation
-[discord]: https://discord.gg/bUadyRwkJS
-[npm-url]: https://www.npmjs.com/package/postcss-color-hex-alpha
-
-[PostCSS]: https://github.com/postcss/postcss
-[PostCSS Color Hex Alpha]: https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-hex-alpha
-[CSS Color Module]: https://www.w3.org/TR/css-color-4/#hex-notation
diff --git a/node_modules/postcss-color-hex-alpha/dist/index.cjs b/node_modules/postcss-color-hex-alpha/dist/index.cjs
deleted file mode 100644
index bd64bbe9..00000000
--- a/node_modules/postcss-color-hex-alpha/dist/index.cjs
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";var e=require("postcss-value-parser"),s=require("@csstools/utilities");const creator=t=>{const r=Object.assign({preserve:!1},t);return{postcssPlugin:"postcss-color-hex-alpha",Declaration(t){if(!/#([0-9A-Fa-f]{4}(?:[0-9A-Fa-f]{4})?)\b/.test(t.value))return;if(s.hasFallback(t))return;const{value:a}=t,l=e(a);l.walk((e=>{if("function"===e.type&&"url"===e.value)return!1;isAlphaHex(e)&&hexa2rgba(e)}));const c=l.toString();c!==a&&(t.cloneBefore({value:c}),r.preserve||t.remove())}}};function isAlphaHex(e){return"word"===e.type&&/^#([0-9A-Fa-f]{4}(?:[0-9A-Fa-f]{4})?)$/.test(e.value)}creator.postcss=!0;const t=1e5,hexa2rgba=e=>{const s=e.value,r=`0x${5===s.length?s.slice(1).replace(/[0-9A-Fa-f]/g,"$&$&"):s.slice(1)}`,[a,l,c,n]=[parseInt(r.slice(2,4),16),parseInt(r.slice(4,6),16),parseInt(r.slice(6,8),16),Math.round(parseInt(r.slice(8,10),16)/255*t)/t];e.value=`rgba(${a},${l},${c},${n})`};module.exports=creator;
diff --git a/node_modules/postcss-color-hex-alpha/dist/index.d.ts b/node_modules/postcss-color-hex-alpha/dist/index.d.ts
deleted file mode 100644
index ce39d2bc..00000000
--- a/node_modules/postcss-color-hex-alpha/dist/index.d.ts
+++ /dev/null
@@ -1,12 +0,0 @@
-import type { PluginCreator } from 'postcss';
-
-declare const creator: PluginCreator<pluginOptions>;
-export default creator;
-
-/** postcss-color-hex-alpha plugin options */
-export declare type pluginOptions = {
- /** Preserve the original notation. default: false */
- preserve?: boolean;
-};
-
-export { }
diff --git a/node_modules/postcss-color-hex-alpha/dist/index.mjs b/node_modules/postcss-color-hex-alpha/dist/index.mjs
deleted file mode 100644
index d1d4624e..00000000
--- a/node_modules/postcss-color-hex-alpha/dist/index.mjs
+++ /dev/null
@@ -1 +0,0 @@
-import e from"postcss-value-parser";import{hasFallback as s}from"@csstools/utilities";const creator=t=>{const r=Object.assign({preserve:!1},t);return{postcssPlugin:"postcss-color-hex-alpha",Declaration(t){if(!/#([0-9A-Fa-f]{4}(?:[0-9A-Fa-f]{4})?)\b/.test(t.value))return;if(s(t))return;const{value:a}=t,l=e(a);l.walk((e=>{if("function"===e.type&&"url"===e.value)return!1;isAlphaHex(e)&&hexa2rgba(e)}));const o=l.toString();o!==a&&(t.cloneBefore({value:o}),r.preserve||t.remove())}}};function isAlphaHex(e){return"word"===e.type&&/^#([0-9A-Fa-f]{4}(?:[0-9A-Fa-f]{4})?)$/.test(e.value)}creator.postcss=!0;const t=1e5,hexa2rgba=e=>{const s=e.value,r=`0x${5===s.length?s.slice(1).replace(/[0-9A-Fa-f]/g,"$&$&"):s.slice(1)}`,[a,l,o,n]=[parseInt(r.slice(2,4),16),parseInt(r.slice(4,6),16),parseInt(r.slice(6,8),16),Math.round(parseInt(r.slice(8,10),16)/255*t)/t];e.value=`rgba(${a},${l},${o},${n})`};export{creator as default};
diff --git a/node_modules/postcss-color-hex-alpha/package.json b/node_modules/postcss-color-hex-alpha/package.json
deleted file mode 100644
index a05752f8..00000000
--- a/node_modules/postcss-color-hex-alpha/package.json
+++ /dev/null
@@ -1,87 +0,0 @@
-{
- "name": "postcss-color-hex-alpha",
- "description": "Use 4 & 8 character hex color notation in CSS",
- "version": "9.0.4",
- "contributors": [
- {
- "name": "Antonio Laguna",
- "email": "antonio@laguna.es",
- "url": "https://antonio.laguna.es"
- },
- {
- "name": "Romain Menke",
- "email": "romainmenke@gmail.com"
- },
- {
- "name": "Jonathan Neal",
- "email": "jonathantneal@hotmail.com"
- },
- {
- "name": "Maxime Thirouin"
- }
- ],
- "license": "MIT",
- "funding": [
- {
- "type": "github",
- "url": "https://github.com/sponsors/csstools"
- },
- {
- "type": "opencollective",
- "url": "https://opencollective.com/csstools"
- }
- ],
- "engines": {
- "node": "^14 || ^16 || >=18"
- },
- "type": "module",
- "main": "dist/index.cjs",
- "module": "dist/index.mjs",
- "exports": {
- ".": {
- "import": {
- "types": "./dist/index.d.ts",
- "default": "./dist/index.mjs"
- },
- "require": {
- "default": "./dist/index.cjs"
- }
- }
- },
- "files": [
- "CHANGELOG.md",
- "LICENSE.md",
- "README.md",
- "dist"
- ],
- "dependencies": {
- "@csstools/utilities": "^1.0.0",
- "postcss-value-parser": "^4.2.0"
- },
- "peerDependencies": {
- "postcss": "^8.4"
- },
- "homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-hex-alpha#readme",
- "repository": {
- "type": "git",
- "url": "https://github.com/csstools/postcss-plugins.git",
- "directory": "plugins/postcss-color-hex-alpha"
- },
- "bugs": "https://github.com/csstools/postcss-plugins/issues",
- "keywords": [
- "4-digit",
- "8-digit",
- "alpha",
- "color",
- "css",
- "csswg",
- "hex",
- "postcss",
- "postcss-plugin",
- "spec",
- "specification",
- "transparency",
- "transparent",
- "w3c"
- ]
-}