yummies 4.0.0 → 4.1.0
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/css.d.ts +7 -0
- package/css.d.ts.map +1 -1
- package/css.js +10 -0
- package/package.json +2 -1
package/css.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { cva as cvaLib } from 'class-variance-authority';
|
|
1
2
|
import clsx from 'clsx';
|
|
2
3
|
/**
|
|
3
4
|
* Перевод значения в пикселях в rem строковое
|
|
@@ -7,4 +8,10 @@ export declare const toRem: (px: number, remValue?: number) => string;
|
|
|
7
8
|
* classNames/clsx но с примесями tailwind-merge
|
|
8
9
|
*/
|
|
9
10
|
export declare const cx: (...args: Parameters<typeof clsx>) => string;
|
|
11
|
+
/**
|
|
12
|
+
* Class Variance Authority но с примесями tailwind-merge
|
|
13
|
+
*
|
|
14
|
+
* https://cva.style/docs
|
|
15
|
+
*/
|
|
16
|
+
export declare const cva: typeof cvaLib;
|
|
10
17
|
//# sourceMappingURL=css.d.ts.map
|
package/css.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../src/css.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,MAAM,CAAC;AAGxB;;GAEG;AACH,eAAO,MAAM,KAAK,GAAI,IAAI,MAAM,EAAE,iBAAa,WAA0B,CAAC;AAE1E;;GAEG;AACH,eAAO,MAAM,EAAE,GAAI,GAAG,MAAM,UAAU,CAAC,OAAO,IAAI,CAAC,WAA2B,CAAC"}
|
|
1
|
+
{"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../src/css.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,IAAI,MAAM,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,IAAI,MAAM,MAAM,CAAC;AAGxB;;GAEG;AACH,eAAO,MAAM,KAAK,GAAI,IAAI,MAAM,EAAE,iBAAa,WAA0B,CAAC;AAE1E;;GAEG;AACH,eAAO,MAAM,EAAE,GAAI,GAAG,MAAM,UAAU,CAAC,OAAO,IAAI,CAAC,WAA2B,CAAC;AAE/E;;;;GAIG;AACH,eAAO,MAAM,GAAG,EAGH,OAAO,MAAM,CAAC"}
|
package/css.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { cva as cvaLib } from 'class-variance-authority';
|
|
1
2
|
import clsx from 'clsx';
|
|
2
3
|
import { twMerge } from 'tailwind-merge';
|
|
3
4
|
/**
|
|
@@ -8,3 +9,12 @@ export const toRem = (px, remValue = 16) => `${px / remValue}rem`;
|
|
|
8
9
|
* classNames/clsx но с примесями tailwind-merge
|
|
9
10
|
*/
|
|
10
11
|
export const cx = (...args) => twMerge(clsx(...args));
|
|
12
|
+
/**
|
|
13
|
+
* Class Variance Authority но с примесями tailwind-merge
|
|
14
|
+
*
|
|
15
|
+
* https://cva.style/docs
|
|
16
|
+
*/
|
|
17
|
+
export const cva = ((...args) => {
|
|
18
|
+
const schema = cvaLib(...args);
|
|
19
|
+
return (...inputArgs) => twMerge(schema(...inputArgs));
|
|
20
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "yummies",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.1.0",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"author": "js2me",
|
|
6
6
|
"license": "MIT",
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
},
|
|
17
17
|
"dependencies": {
|
|
18
18
|
"@types/insane": "^1.0.0",
|
|
19
|
+
"class-variance-authority": "^0.7.1",
|
|
19
20
|
"clsx": "^2.1.1",
|
|
20
21
|
"dayjs": "^1.11.13",
|
|
21
22
|
"insane": "^2.6.2",
|