@tokenami/config 0.0.73 → 0.0.74

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/index.d.cts CHANGED
@@ -24,14 +24,15 @@ type Selectors = {
24
24
  [name: string]: Selector;
25
25
  };
26
26
  type Aliases = Record<string, CSSProperty[]>;
27
- type Properties = Partial<Record<CSSProperty | string, string[]>>;
27
+ type Properties = Partial<Record<CSSProperty | (string & {}), string[]>>;
28
+ type CustomProperties = Record<string, string[]>;
28
29
  type ExactTheme<T> = T extends ThemeModes ? {
29
30
  [K in keyof T]: K extends 'root' | 'modes' ? T[K] : never;
30
31
  } : {};
31
32
  type ExactThemeKey<T> = ('grid' | 'number') | (T extends ThemeModes ? keyof T['modes'][keyof T['modes']] | keyof T['root'] : T extends Theme ? keyof T : string);
32
33
  type ExactThemeModes<M> = M extends ThemeMode ? ThemeModes<UnionToIntersection<M[keyof M]>> : {};
33
34
  type ExactProperties<P, T> = Partial<Record<keyof P, ExactThemeKey<T>[]>>;
34
- interface Config<T extends ThemeConfig = ThemeConfig, P extends Properties = Properties> {
35
+ interface Config<T extends ThemeConfig = ThemeConfig, P extends Properties = Properties, C extends CustomProperties = CustomProperties> {
35
36
  include: string[];
36
37
  exclude?: string[];
37
38
  grid?: string;
@@ -47,6 +48,7 @@ interface Config<T extends ThemeConfig = ThemeConfig, P extends Properties = Pro
47
48
  selectors?: Selectors;
48
49
  aliases?: Aliases;
49
50
  properties?: P & ExactProperties<P, T>;
51
+ customProperties?: C & ExactProperties<C, T>;
50
52
  }
51
53
  type UnionToIntersection<U> = (U extends any ? (x: U) => void : never) extends (x: infer I) => void ? I : never;
52
54
  type ExactConfig<Shape, T> = T extends Shape ? keyof T extends keyof Shape ? keyof Shape extends keyof T ? T : Shape : Shape : Shape;
package/dist/index.d.ts CHANGED
@@ -24,14 +24,15 @@ type Selectors = {
24
24
  [name: string]: Selector;
25
25
  };
26
26
  type Aliases = Record<string, CSSProperty[]>;
27
- type Properties = Partial<Record<CSSProperty | string, string[]>>;
27
+ type Properties = Partial<Record<CSSProperty | (string & {}), string[]>>;
28
+ type CustomProperties = Record<string, string[]>;
28
29
  type ExactTheme<T> = T extends ThemeModes ? {
29
30
  [K in keyof T]: K extends 'root' | 'modes' ? T[K] : never;
30
31
  } : {};
31
32
  type ExactThemeKey<T> = ('grid' | 'number') | (T extends ThemeModes ? keyof T['modes'][keyof T['modes']] | keyof T['root'] : T extends Theme ? keyof T : string);
32
33
  type ExactThemeModes<M> = M extends ThemeMode ? ThemeModes<UnionToIntersection<M[keyof M]>> : {};
33
34
  type ExactProperties<P, T> = Partial<Record<keyof P, ExactThemeKey<T>[]>>;
34
- interface Config<T extends ThemeConfig = ThemeConfig, P extends Properties = Properties> {
35
+ interface Config<T extends ThemeConfig = ThemeConfig, P extends Properties = Properties, C extends CustomProperties = CustomProperties> {
35
36
  include: string[];
36
37
  exclude?: string[];
37
38
  grid?: string;
@@ -47,6 +48,7 @@ interface Config<T extends ThemeConfig = ThemeConfig, P extends Properties = Pro
47
48
  selectors?: Selectors;
48
49
  aliases?: Aliases;
49
50
  properties?: P & ExactProperties<P, T>;
51
+ customProperties?: C & ExactProperties<C, T>;
50
52
  }
51
53
  type UnionToIntersection<U> = (U extends any ? (x: U) => void : never) extends (x: infer I) => void ? I : never;
52
54
  type ExactConfig<Shape, T> = T extends Shape ? keyof T extends keyof Shape ? keyof Shape extends keyof T ? T : Shape : Shape : Shape;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tokenami/config",
3
- "version": "0.0.73",
3
+ "version": "0.0.74",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -38,5 +38,5 @@
38
38
  "tsup": "^7.0.0",
39
39
  "typescript": "^5.1.3"
40
40
  },
41
- "gitHead": "9635ef203a3075788c4736b48f84114b6752ece7"
41
+ "gitHead": "eab35bee7eb2892db9a5ada8fe8fd8ee0fa16708"
42
42
  }