@salty-css/react 0.0.1-alpha.267 → 0.0.1-alpha.269
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/dynamic-styles.cjs +2 -2
- package/dynamic-styles.d.ts +2 -1
- package/dynamic-styles.js +5 -4
- package/package.json +2 -2
package/dynamic-styles.cjs
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("@salty-css/core/parsers"),
|
2
|
-
`);return
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("react/jsx-runtime"),n=require("@salty-css/core/parsers"),a=async({scope:e,styles:s})=>{const t=(await n.parseStyles(s,e)).join(`
|
2
|
+
`);return r.jsx("style",{children:t})};exports.DynamicStyles=a;
|
package/dynamic-styles.d.ts
CHANGED
@@ -1,8 +1,9 @@
|
|
1
1
|
import { BaseStyles } from '@salty-css/core/types';
|
2
2
|
/**
|
3
3
|
* Add any dynamic styles to your app with a custom scope.
|
4
|
+
* Note: this works only with server components.
|
4
5
|
*/
|
5
6
|
export declare const DynamicStyles: ({ scope, styles }: {
|
6
7
|
scope: string;
|
7
8
|
styles: BaseStyles;
|
8
|
-
}) => Promise<import("react").JSX.Element>;
|
9
|
+
}) => Promise<import("react/jsx-runtime").JSX.Element>;
|
package/dynamic-styles.js
CHANGED
@@ -1,8 +1,9 @@
|
|
1
|
-
import {
|
2
|
-
|
3
|
-
|
1
|
+
import { jsx as n } from "react/jsx-runtime";
|
2
|
+
import { parseStyles as e } from "@salty-css/core/parsers";
|
3
|
+
const c = async ({ scope: r, styles: s }) => {
|
4
|
+
const t = (await e(s, r)).join(`
|
4
5
|
`);
|
5
|
-
return /* @__PURE__ */
|
6
|
+
return /* @__PURE__ */ n("style", { children: t });
|
6
7
|
};
|
7
8
|
export {
|
8
9
|
c as DynamicStyles
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@salty-css/react",
|
3
|
-
"version": "0.0.1-alpha.
|
3
|
+
"version": "0.0.1-alpha.269",
|
4
4
|
"main": "./dist/index.js",
|
5
5
|
"module": "./dist/index.mjs",
|
6
6
|
"typings": "./dist/index.d.ts",
|
@@ -70,7 +70,7 @@
|
|
70
70
|
}
|
71
71
|
},
|
72
72
|
"dependencies": {
|
73
|
-
"@salty-css/core": "^0.0.1-alpha.
|
73
|
+
"@salty-css/core": "^0.0.1-alpha.269",
|
74
74
|
"clsx": ">=2.x",
|
75
75
|
"react": ">=19.x || >=18.3.x"
|
76
76
|
}
|