tailwind-variants 3.0.0 → 3.1.1
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/dist/config.d.ts +3 -1
- package/dist/index.d.ts +7 -3
- package/dist/lite.d.ts +3 -2
- package/dist/types.d.ts +1 -2
- package/dist/utils.d.ts +2 -2
- package/package.json +1 -1
package/dist/config.d.ts
CHANGED
|
@@ -3,6 +3,8 @@ import type {extendTailwindMerge} from "tailwind-merge";
|
|
|
3
3
|
type MergeConfig = Parameters<typeof extendTailwindMerge>[0];
|
|
4
4
|
type LegacyMergeConfig = Extract<MergeConfig, {extend?: unknown}>["extend"];
|
|
5
5
|
|
|
6
|
+
export type TWMergeConfig = MergeConfig & LegacyMergeConfig;
|
|
7
|
+
|
|
6
8
|
export type TWMConfig = {
|
|
7
9
|
/**
|
|
8
10
|
* Whether to merge the class names with `tailwind-merge` library.
|
|
@@ -15,7 +17,7 @@ export type TWMConfig = {
|
|
|
15
17
|
* The config object for `tailwind-merge` library.
|
|
16
18
|
* @see https://github.com/dcastil/tailwind-merge/blob/v2.2.0/docs/configuration.md
|
|
17
19
|
*/
|
|
18
|
-
twMergeConfig?:
|
|
20
|
+
twMergeConfig?: TWMergeConfig;
|
|
19
21
|
};
|
|
20
22
|
|
|
21
23
|
export type TVConfig = TWMConfig;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import {TVConfig, TWMConfig} from "./config";
|
|
2
|
-
import {CnOptions, CnReturn, TV} from "./types";
|
|
1
|
+
import type {TVConfig, TWMConfig, TWMergeConfig} from "./config.d.ts";
|
|
2
|
+
import type {CnOptions, CnReturn, TV} from "./types.d.ts";
|
|
3
3
|
|
|
4
|
-
export * from "./types";
|
|
4
|
+
export type * from "./types.d.ts";
|
|
5
5
|
|
|
6
|
+
// util function
|
|
6
7
|
export declare const cnBase: <T extends CnOptions>(...classes: T) => CnReturn;
|
|
7
8
|
|
|
8
9
|
export declare const cn: <T extends CnOptions>(...classes: T) => (config?: TWMConfig) => CnReturn;
|
|
@@ -11,3 +12,6 @@ export declare const cn: <T extends CnOptions>(...classes: T) => (config?: TWMCo
|
|
|
11
12
|
export declare const tv: TV;
|
|
12
13
|
|
|
13
14
|
export declare function createTV(config: TVConfig): TV;
|
|
15
|
+
|
|
16
|
+
// types
|
|
17
|
+
export type {TVConfig, TWMConfig, TWMergeConfig};
|
package/dist/lite.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {CnOptions, CnReturn, TVLite} from "./types";
|
|
1
|
+
import type {CnOptions, CnReturn, TVLite} from "./types.d.ts";
|
|
2
2
|
|
|
3
|
-
export * from "./types";
|
|
3
|
+
export type * from "./types.d.ts";
|
|
4
4
|
|
|
5
|
+
// util function
|
|
5
6
|
export declare const cnBase: <T extends CnOptions>(...classes: T) => CnReturn;
|
|
6
7
|
|
|
7
8
|
export declare const cn: <T extends CnOptions>(...classes: T) => CnReturn;
|
package/dist/types.d.ts
CHANGED
package/dist/utils.d.ts
CHANGED