@seyuna/postcss 1.0.0-canary.16 → 1.0.0-canary.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/at-rules/color-scheme.d.ts +1 -1
- package/dist/at-rules/color.d.ts +1 -1
- package/dist/at-rules/color.js +1 -1
- package/dist/at-rules/container.d.ts +1 -1
- package/dist/at-rules/index.d.ts +1 -1
- package/dist/at-rules/index.js +3 -3
- package/dist/config.d.ts +2 -2
- package/dist/errors.d.ts +1 -1
- package/dist/functions/color.d.ts +1 -1
- package/dist/functions/index.d.ts +1 -1
- package/dist/functions/index.js +2 -2
- package/dist/functions/theme.d.ts +1 -1
- package/dist/helpers.d.ts +1 -1
- package/dist/helpers.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/parser.d.ts +1 -1
- package/dist/parser.js +1 -1
- package/dist/plugin.d.ts +1 -1
- package/dist/plugin.js +4 -4
- package/package.json +2 -1
- package/src/at-rules/color-scheme.ts +1 -1
- package/src/at-rules/color.ts +2 -2
- package/src/at-rules/container.ts +1 -1
- package/src/at-rules/index.ts +4 -4
- package/src/config.ts +2 -2
- package/src/errors.ts +1 -1
- package/src/functions/color.ts +1 -1
- package/src/functions/index.ts +3 -3
- package/src/functions/theme.ts +1 -1
- package/src/helpers.ts +2 -2
- package/src/index.ts +2 -2
- package/src/parser.ts +2 -2
- package/src/plugin.ts +4 -4
- package/test-import.mjs +2 -0
- package/tsconfig.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
# [1.0.0-canary.17](https://github.com/seyuna-corp/seyuna-postcss/compare/v1.0.0-canary.16...v1.0.0-canary.17) (2026-01-10)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* transition to proper ESM with correct file extensions ([b330b4f](https://github.com/seyuna-corp/seyuna-postcss/commit/b330b4fcd3394b78ecc39ef5f23f5e993bd425be))
|
|
7
|
+
|
|
1
8
|
# [1.0.0-canary.16](https://github.com/seyuna-corp/seyuna-postcss/compare/v1.0.0-canary.15...v1.0.0-canary.16) (2026-01-10)
|
|
2
9
|
|
|
3
10
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { AtRule } from "postcss";
|
|
2
|
-
import { PluginContext } from "../config";
|
|
2
|
+
import { PluginContext } from "../config.js";
|
|
3
3
|
export declare const light: (atRule: AtRule, context: PluginContext) => void;
|
|
4
4
|
export declare const dark: (atRule: AtRule, context: PluginContext) => void;
|
package/dist/at-rules/color.d.ts
CHANGED
package/dist/at-rules/color.js
CHANGED
package/dist/at-rules/index.d.ts
CHANGED
package/dist/at-rules/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { eachStandardColor, eachFixedColor } from "./color";
|
|
2
|
-
import container from "./container";
|
|
3
|
-
import { light, dark } from "./color-scheme";
|
|
1
|
+
import { eachStandardColor, eachFixedColor } from "./color.js";
|
|
2
|
+
import container from "./container.js";
|
|
3
|
+
import { light, dark } from "./color-scheme.js";
|
|
4
4
|
// Ordered array ensures execution order
|
|
5
5
|
export const atRuleHandlers = [
|
|
6
6
|
{ name: "each-standard-color", handler: eachStandardColor },
|
package/dist/config.d.ts
CHANGED
package/dist/errors.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PluginContext } from "../config";
|
|
1
|
+
import { PluginContext } from "../config.js";
|
|
2
2
|
export declare function sc(context: PluginContext, name: string, alpha?: string, lightness?: string, chroma?: string): string;
|
|
3
3
|
export declare function fc(context: PluginContext, name: string, alpha?: string, lightness?: string, chroma?: string): string;
|
|
4
4
|
export declare function alpha(context: PluginContext, color: string, value: string): string;
|
package/dist/functions/index.js
CHANGED
package/dist/helpers.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Rule, ChildNode, AtRule } from "postcss";
|
|
2
|
-
import { PluginContext } from "./config";
|
|
2
|
+
import { PluginContext } from "./config.js";
|
|
3
3
|
/**
|
|
4
4
|
* Helper: clone nodes and replace {name} placeholders safely
|
|
5
5
|
* Returns only valid Rules or Declarations (never raw AtRules)
|
package/dist/helpers.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
declare const plugin: import("postcss").PluginCreator<import("./config").PluginOptions> & {
|
|
1
|
+
declare const plugin: import("postcss").PluginCreator<import("./config.js").PluginOptions> & {
|
|
2
2
|
postcss: boolean;
|
|
3
|
-
functions: Record<string, import("./functions").FnHandler>;
|
|
3
|
+
functions: Record<string, import("./functions/index.js").FnHandler>;
|
|
4
4
|
};
|
|
5
5
|
export default plugin;
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { dynamicFunctionsPlugin } from './plugin';
|
|
2
|
-
import { functions } from './functions';
|
|
1
|
+
import { dynamicFunctionsPlugin } from './plugin.js';
|
|
2
|
+
import { functions } from './functions/index.js';
|
|
3
3
|
// CommonJS-friendly export
|
|
4
4
|
const plugin = Object.assign(dynamicFunctionsPlugin, {
|
|
5
5
|
postcss: true,
|
package/dist/parser.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { Node } from 'postcss';
|
|
2
|
-
import { PluginContext } from './config';
|
|
2
|
+
import { PluginContext } from './config.js';
|
|
3
3
|
export type FunctionMap = Record<string, (context: PluginContext, ...args: string[]) => string>;
|
|
4
4
|
export declare function processFunctions(value: string, fnMap: FunctionMap, node: Node, context: PluginContext): string;
|
package/dist/parser.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import valueParser from 'postcss-value-parser';
|
|
2
|
-
import { reportError } from './errors';
|
|
2
|
+
import { reportError } from './errors.js';
|
|
3
3
|
export function processFunctions(value, fnMap, node, context) {
|
|
4
4
|
const parsed = valueParser(value);
|
|
5
5
|
// Helper to process nodes recursively (inner-first)
|
package/dist/plugin.d.ts
CHANGED
package/dist/plugin.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { functions } from "./functions";
|
|
2
|
-
import { atRuleHandlers } from "./at-rules";
|
|
3
|
-
import { loadConfig } from "./config";
|
|
4
|
-
import { processFunctions } from "./parser";
|
|
1
|
+
import { functions } from "./functions/index.js";
|
|
2
|
+
import { atRuleHandlers } from "./at-rules/index.js";
|
|
3
|
+
import { loadConfig } from "./config.js";
|
|
4
|
+
import { processFunctions } from "./parser.js";
|
|
5
5
|
export const dynamicFunctionsPlugin = (opts = {}) => {
|
|
6
6
|
const { config, options } = loadConfig(opts);
|
|
7
7
|
const fnMap = { ...functions, ...opts.functions };
|
package/package.json
CHANGED
package/src/at-rules/color.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AtRule } from "postcss";
|
|
2
|
-
import { PluginContext } from "../config";
|
|
3
|
-
import { generateRules } from "../helpers";
|
|
2
|
+
import { PluginContext } from "../config.js";
|
|
3
|
+
import { generateRules } from "../helpers.js";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Handler for @each-standard-color
|
package/src/at-rules/index.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { AtRule } from "postcss";
|
|
2
|
-
import { eachStandardColor, eachFixedColor } from "./color";
|
|
3
|
-
import container from "./container";
|
|
4
|
-
import { light, dark } from "./color-scheme";
|
|
5
|
-
import { PluginContext } from "../config";
|
|
2
|
+
import { eachStandardColor, eachFixedColor } from "./color.js";
|
|
3
|
+
import container from "./container.js";
|
|
4
|
+
import { light, dark } from "./color-scheme.js";
|
|
5
|
+
import { PluginContext } from "../config.js";
|
|
6
6
|
|
|
7
7
|
// Each handler has a name (matches the at-rule) and the function
|
|
8
8
|
export interface AtRuleHandler {
|
package/src/config.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import fs from 'fs';
|
|
2
2
|
import path from 'path';
|
|
3
|
-
import { SeyunaConfig } from './types';
|
|
4
|
-
import { FunctionMap } from './parser';
|
|
3
|
+
import { SeyunaConfig } from './types.js';
|
|
4
|
+
import { FunctionMap } from './parser.js';
|
|
5
5
|
|
|
6
6
|
export interface PluginOptions {
|
|
7
7
|
configPath?: string;
|
package/src/errors.ts
CHANGED
package/src/functions/color.ts
CHANGED
package/src/functions/index.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { sc, fc, alpha, lighten, darken, contrast } from "./color";
|
|
2
|
-
import { theme } from "./theme";
|
|
3
|
-
import { PluginContext } from "../config";
|
|
1
|
+
import { sc, fc, alpha, lighten, darken, contrast } from "./color.js";
|
|
2
|
+
import { theme } from "./theme.js";
|
|
3
|
+
import { PluginContext } from "../config.js";
|
|
4
4
|
|
|
5
5
|
export type FnHandler = (context: PluginContext, ...args: string[]) => string;
|
|
6
6
|
|
package/src/functions/theme.ts
CHANGED
package/src/helpers.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Rule, ChildNode, Declaration, AtRule } from "postcss";
|
|
2
|
-
import { processFunctions } from "./parser";
|
|
3
|
-
import { PluginContext } from "./config";
|
|
2
|
+
import { processFunctions } from "./parser.js";
|
|
3
|
+
import { PluginContext } from "./config.js";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Helper: clone nodes and replace {name} placeholders safely
|
package/src/index.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { dynamicFunctionsPlugin } from './plugin';
|
|
2
|
-
import { functions } from './functions';
|
|
1
|
+
import { dynamicFunctionsPlugin } from './plugin.js';
|
|
2
|
+
import { functions } from './functions/index.js';
|
|
3
3
|
|
|
4
4
|
// CommonJS-friendly export
|
|
5
5
|
const plugin = Object.assign(dynamicFunctionsPlugin, {
|
package/src/parser.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import valueParser from 'postcss-value-parser';
|
|
2
2
|
import { Node } from 'postcss';
|
|
3
|
-
import { PluginContext } from './config';
|
|
4
|
-
import { reportError } from './errors';
|
|
3
|
+
import { PluginContext } from './config.js';
|
|
4
|
+
import { reportError } from './errors.js';
|
|
5
5
|
|
|
6
6
|
export type FunctionMap = Record<string, (context: PluginContext, ...args: string[]) => string>;
|
|
7
7
|
|
package/src/plugin.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { PluginCreator } from "postcss";
|
|
2
|
-
import { functions } from "./functions";
|
|
3
|
-
import { atRuleHandlers } from "./at-rules";
|
|
4
|
-
import { loadConfig, PluginOptions as ConfigOptions, PluginContext } from "./config";
|
|
5
|
-
import { processFunctions, FunctionMap } from "./parser";
|
|
2
|
+
import { functions } from "./functions/index.js";
|
|
3
|
+
import { atRuleHandlers } from "./at-rules/index.js";
|
|
4
|
+
import { loadConfig, PluginOptions as ConfigOptions, PluginContext } from "./config.js";
|
|
5
|
+
import { processFunctions, FunctionMap } from "./parser.js";
|
|
6
6
|
|
|
7
7
|
export const dynamicFunctionsPlugin: PluginCreator<ConfigOptions> = (
|
|
8
8
|
opts = {}
|
package/test-import.mjs
ADDED
package/tsconfig.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"compilerOptions": {
|
|
3
3
|
"target": "ES2020",
|
|
4
|
-
"module": "
|
|
4
|
+
"module": "NodeNext",
|
|
5
5
|
"lib": ["ES2020"],
|
|
6
6
|
"declaration": true,
|
|
7
7
|
"outDir": "dist",
|
|
8
8
|
"strict": true,
|
|
9
|
-
"moduleResolution": "
|
|
9
|
+
"moduleResolution": "NodeNext",
|
|
10
10
|
"esModuleInterop": true,
|
|
11
11
|
"skipLibCheck": true
|
|
12
12
|
},
|