@pandacss/generator 0.7.0 → 0.9.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/dist/index.d.mts CHANGED
@@ -3,22 +3,14 @@ import * as _pandacss_core from '@pandacss/core';
3
3
  import * as _pandacss_token_dictionary from '@pandacss/token-dictionary';
4
4
  import * as _pandacss_types from '@pandacss/types';
5
5
  import { ConfigResultWithHooks, TSConfig } from '@pandacss/types';
6
- import * as _pandacss_core_src_types from '@pandacss/core/src/types';
7
6
 
8
7
  declare const getEngine: (conf: ConfigResultWithHooks) => {
9
8
  patterns: {
10
- transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
11
- nodes: {
12
- type: "pattern";
13
- name: string;
14
- props: string[];
15
- baseName: string;
16
- }[];
17
- patterns: Record<string, _pandacss_types.PatternConfig>;
18
9
  getConfig: (name: string) => _pandacss_types.PatternConfig;
10
+ transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
19
11
  getNames: (name: string) => {
20
- name: string;
21
12
  upperName: string;
13
+ baseName: string;
22
14
  dashName: string;
23
15
  styleFnName: string;
24
16
  jsxName: string;
@@ -27,13 +19,29 @@ declare const getEngine: (conf: ConfigResultWithHooks) => {
27
19
  props: string[];
28
20
  blocklistType: string;
29
21
  config: _pandacss_types.PatternConfig;
30
- name: string;
22
+ type: "pattern";
23
+ match: RegExp;
24
+ jsx: (string | RegExp)[];
25
+ upperName: string;
26
+ baseName: string;
27
+ dashName: string;
28
+ styleFnName: string;
29
+ jsxName: string;
30
+ }[];
31
+ getFnName: (jsxName: string) => string;
32
+ filter: (jsxName: string) => {
33
+ props: string[];
34
+ blocklistType: string;
35
+ config: _pandacss_types.PatternConfig;
36
+ type: "pattern";
37
+ match: RegExp;
38
+ jsx: (string | RegExp)[];
31
39
  upperName: string;
40
+ baseName: string;
32
41
  dashName: string;
33
42
  styleFnName: string;
34
43
  jsxName: string;
35
44
  }[];
36
- getFnName: (jsx: string) => string;
37
45
  isEmpty: () => boolean;
38
46
  };
39
47
  jsx: {
@@ -41,7 +49,7 @@ declare const getEngine: (conf: ConfigResultWithHooks) => {
41
49
  upperName: string;
42
50
  typeName: string;
43
51
  componentName: string;
44
- framework: ("solid" | "react" | "preact" | "vue" | "qwik") | undefined;
52
+ framework: ("react" | "solid" | "preact" | "vue" | "qwik") | undefined;
45
53
  };
46
54
  paths: {
47
55
  get: (file?: string | undefined) => string[];
@@ -87,8 +95,9 @@ declare const getEngine: (conf: ConfigResultWithHooks) => {
87
95
  createSheet: (options?: Pick<_pandacss_core.StylesheetOptions, "content"> | undefined) => _pandacss_core.Stylesheet;
88
96
  hooks: _pandacss_types.PandaHookable;
89
97
  path: string;
90
- config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "include" | "outdir" | "cwd">>;
98
+ config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "outdir" | "cwd" | "include">>;
91
99
  tsconfig?: TSConfig | undefined;
100
+ tsOptions?: _pandacss_types.ConfigTsOptions | undefined;
92
101
  tsconfigFile?: string | undefined;
93
102
  dependencies: string[];
94
103
  };
@@ -155,43 +164,77 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
155
164
  };
156
165
  parserOptions: {
157
166
  importMap: {
158
- css: string;
159
- recipe: string;
160
- pattern: string;
161
- jsx: string;
167
+ css: string[];
168
+ recipe: string[];
169
+ pattern: string[];
170
+ jsx: string[];
162
171
  };
163
172
  jsx: {
164
173
  factory: string;
165
174
  isStyleProp: (key: string) => boolean;
166
175
  nodes: ({
167
- type: "pattern";
168
- name: string;
169
176
  props: string[];
177
+ blocklistType: string;
178
+ config: _pandacss_types.PatternConfig;
179
+ type: "pattern";
180
+ match: RegExp;
181
+ jsx: (string | RegExp)[];
182
+ upperName: string;
170
183
  baseName: string;
184
+ dashName: string;
185
+ styleFnName: string;
186
+ jsxName: string;
171
187
  } | {
172
- type: "recipe";
173
- name: string;
174
- props: string[];
175
188
  baseName: string;
189
+ type: "recipe";
190
+ variantKeys: string[];
191
+ variantKeyMap: Record<string, string[]>;
176
192
  jsx: (string | RegExp)[];
193
+ upperName: string;
194
+ dashName: string;
195
+ jsxName: string;
177
196
  match: RegExp;
197
+ config: _pandacss_types.RecipeConfig;
198
+ splitProps: (props: _pandacss_types.Dict) => [_pandacss_types.Dict, _pandacss_types.Dict];
199
+ props: string[];
178
200
  })[];
179
201
  };
180
- getRecipesByJsxName: (jsxName: string) => _pandacss_core_src_types.RecipeNode[];
181
- };
182
- patterns: {
183
- transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
184
- nodes: {
185
- type: "pattern";
186
- name: string;
202
+ getRecipesByJsxName: (jsxName: string) => {
203
+ baseName: string;
204
+ type: "recipe";
205
+ variantKeys: string[];
206
+ variantKeyMap: Record<string, string[]>;
207
+ jsx: (string | RegExp)[];
208
+ upperName: string;
209
+ dashName: string;
210
+ jsxName: string;
211
+ match: RegExp;
212
+ config: _pandacss_types.RecipeConfig;
213
+ splitProps: (props: _pandacss_types.Dict) => [_pandacss_types.Dict, _pandacss_types.Dict];
214
+ props: string[];
215
+ }[];
216
+ getPatternsByJsxName: (jsxName: string) => {
187
217
  props: string[];
218
+ blocklistType: string;
219
+ config: _pandacss_types.PatternConfig;
220
+ type: "pattern";
221
+ match: RegExp;
222
+ jsx: (string | RegExp)[];
223
+ upperName: string;
188
224
  baseName: string;
225
+ dashName: string;
226
+ styleFnName: string;
227
+ jsxName: string;
189
228
  }[];
190
- patterns: Record<string, _pandacss_types.PatternConfig>;
229
+ compilerOptions: any;
230
+ tsOptions: _pandacss_types.ConfigTsOptions | undefined;
231
+ };
232
+ patterns: {
191
233
  getConfig: (name: string) => _pandacss_types.PatternConfig;
234
+ transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
192
235
  getNames: (name: string) => {
193
- name: string;
194
236
  upperName: string;
237
+ baseName: string;
195
238
  dashName: string;
196
239
  styleFnName: string;
197
240
  jsxName: string;
@@ -200,13 +243,29 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
200
243
  props: string[];
201
244
  blocklistType: string;
202
245
  config: _pandacss_types.PatternConfig;
203
- name: string;
246
+ type: "pattern";
247
+ match: RegExp;
248
+ jsx: (string | RegExp)[];
204
249
  upperName: string;
250
+ baseName: string;
251
+ dashName: string;
252
+ styleFnName: string;
253
+ jsxName: string;
254
+ }[];
255
+ getFnName: (jsxName: string) => string;
256
+ filter: (jsxName: string) => {
257
+ props: string[];
258
+ blocklistType: string;
259
+ config: _pandacss_types.PatternConfig;
260
+ type: "pattern";
261
+ match: RegExp;
262
+ jsx: (string | RegExp)[];
263
+ upperName: string;
264
+ baseName: string;
205
265
  dashName: string;
206
266
  styleFnName: string;
207
267
  jsxName: string;
208
268
  }[];
209
- getFnName: (jsx: string) => string;
210
269
  isEmpty: () => boolean;
211
270
  };
212
271
  jsx: {
@@ -214,7 +273,7 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
214
273
  upperName: string;
215
274
  typeName: string;
216
275
  componentName: string;
217
- framework: ("solid" | "react" | "preact" | "vue" | "qwik") | undefined;
276
+ framework: ("react" | "solid" | "preact" | "vue" | "qwik") | undefined;
218
277
  };
219
278
  paths: {
220
279
  get: (file?: string | undefined) => string[];
@@ -260,8 +319,9 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
260
319
  createSheet: (options?: Pick<_pandacss_core.StylesheetOptions, "content"> | undefined) => _pandacss_core.Stylesheet;
261
320
  hooks: _pandacss_types.PandaHookable;
262
321
  path: string;
263
- config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "include" | "outdir" | "cwd">>;
322
+ config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "outdir" | "cwd" | "include">>;
264
323
  tsconfig?: TSConfig | undefined;
324
+ tsOptions?: _pandacss_types.ConfigTsOptions | undefined;
265
325
  tsconfigFile?: string | undefined;
266
326
  dependencies: string[];
267
327
  };
package/dist/index.d.ts CHANGED
@@ -3,22 +3,14 @@ import * as _pandacss_core from '@pandacss/core';
3
3
  import * as _pandacss_token_dictionary from '@pandacss/token-dictionary';
4
4
  import * as _pandacss_types from '@pandacss/types';
5
5
  import { ConfigResultWithHooks, TSConfig } from '@pandacss/types';
6
- import * as _pandacss_core_src_types from '@pandacss/core/src/types';
7
6
 
8
7
  declare const getEngine: (conf: ConfigResultWithHooks) => {
9
8
  patterns: {
10
- transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
11
- nodes: {
12
- type: "pattern";
13
- name: string;
14
- props: string[];
15
- baseName: string;
16
- }[];
17
- patterns: Record<string, _pandacss_types.PatternConfig>;
18
9
  getConfig: (name: string) => _pandacss_types.PatternConfig;
10
+ transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
19
11
  getNames: (name: string) => {
20
- name: string;
21
12
  upperName: string;
13
+ baseName: string;
22
14
  dashName: string;
23
15
  styleFnName: string;
24
16
  jsxName: string;
@@ -27,13 +19,29 @@ declare const getEngine: (conf: ConfigResultWithHooks) => {
27
19
  props: string[];
28
20
  blocklistType: string;
29
21
  config: _pandacss_types.PatternConfig;
30
- name: string;
22
+ type: "pattern";
23
+ match: RegExp;
24
+ jsx: (string | RegExp)[];
25
+ upperName: string;
26
+ baseName: string;
27
+ dashName: string;
28
+ styleFnName: string;
29
+ jsxName: string;
30
+ }[];
31
+ getFnName: (jsxName: string) => string;
32
+ filter: (jsxName: string) => {
33
+ props: string[];
34
+ blocklistType: string;
35
+ config: _pandacss_types.PatternConfig;
36
+ type: "pattern";
37
+ match: RegExp;
38
+ jsx: (string | RegExp)[];
31
39
  upperName: string;
40
+ baseName: string;
32
41
  dashName: string;
33
42
  styleFnName: string;
34
43
  jsxName: string;
35
44
  }[];
36
- getFnName: (jsx: string) => string;
37
45
  isEmpty: () => boolean;
38
46
  };
39
47
  jsx: {
@@ -41,7 +49,7 @@ declare const getEngine: (conf: ConfigResultWithHooks) => {
41
49
  upperName: string;
42
50
  typeName: string;
43
51
  componentName: string;
44
- framework: ("solid" | "react" | "preact" | "vue" | "qwik") | undefined;
52
+ framework: ("react" | "solid" | "preact" | "vue" | "qwik") | undefined;
45
53
  };
46
54
  paths: {
47
55
  get: (file?: string | undefined) => string[];
@@ -87,8 +95,9 @@ declare const getEngine: (conf: ConfigResultWithHooks) => {
87
95
  createSheet: (options?: Pick<_pandacss_core.StylesheetOptions, "content"> | undefined) => _pandacss_core.Stylesheet;
88
96
  hooks: _pandacss_types.PandaHookable;
89
97
  path: string;
90
- config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "include" | "outdir" | "cwd">>;
98
+ config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "outdir" | "cwd" | "include">>;
91
99
  tsconfig?: TSConfig | undefined;
100
+ tsOptions?: _pandacss_types.ConfigTsOptions | undefined;
92
101
  tsconfigFile?: string | undefined;
93
102
  dependencies: string[];
94
103
  };
@@ -155,43 +164,77 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
155
164
  };
156
165
  parserOptions: {
157
166
  importMap: {
158
- css: string;
159
- recipe: string;
160
- pattern: string;
161
- jsx: string;
167
+ css: string[];
168
+ recipe: string[];
169
+ pattern: string[];
170
+ jsx: string[];
162
171
  };
163
172
  jsx: {
164
173
  factory: string;
165
174
  isStyleProp: (key: string) => boolean;
166
175
  nodes: ({
167
- type: "pattern";
168
- name: string;
169
176
  props: string[];
177
+ blocklistType: string;
178
+ config: _pandacss_types.PatternConfig;
179
+ type: "pattern";
180
+ match: RegExp;
181
+ jsx: (string | RegExp)[];
182
+ upperName: string;
170
183
  baseName: string;
184
+ dashName: string;
185
+ styleFnName: string;
186
+ jsxName: string;
171
187
  } | {
172
- type: "recipe";
173
- name: string;
174
- props: string[];
175
188
  baseName: string;
189
+ type: "recipe";
190
+ variantKeys: string[];
191
+ variantKeyMap: Record<string, string[]>;
176
192
  jsx: (string | RegExp)[];
193
+ upperName: string;
194
+ dashName: string;
195
+ jsxName: string;
177
196
  match: RegExp;
197
+ config: _pandacss_types.RecipeConfig;
198
+ splitProps: (props: _pandacss_types.Dict) => [_pandacss_types.Dict, _pandacss_types.Dict];
199
+ props: string[];
178
200
  })[];
179
201
  };
180
- getRecipesByJsxName: (jsxName: string) => _pandacss_core_src_types.RecipeNode[];
181
- };
182
- patterns: {
183
- transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
184
- nodes: {
185
- type: "pattern";
186
- name: string;
202
+ getRecipesByJsxName: (jsxName: string) => {
203
+ baseName: string;
204
+ type: "recipe";
205
+ variantKeys: string[];
206
+ variantKeyMap: Record<string, string[]>;
207
+ jsx: (string | RegExp)[];
208
+ upperName: string;
209
+ dashName: string;
210
+ jsxName: string;
211
+ match: RegExp;
212
+ config: _pandacss_types.RecipeConfig;
213
+ splitProps: (props: _pandacss_types.Dict) => [_pandacss_types.Dict, _pandacss_types.Dict];
214
+ props: string[];
215
+ }[];
216
+ getPatternsByJsxName: (jsxName: string) => {
187
217
  props: string[];
218
+ blocklistType: string;
219
+ config: _pandacss_types.PatternConfig;
220
+ type: "pattern";
221
+ match: RegExp;
222
+ jsx: (string | RegExp)[];
223
+ upperName: string;
188
224
  baseName: string;
225
+ dashName: string;
226
+ styleFnName: string;
227
+ jsxName: string;
189
228
  }[];
190
- patterns: Record<string, _pandacss_types.PatternConfig>;
229
+ compilerOptions: any;
230
+ tsOptions: _pandacss_types.ConfigTsOptions | undefined;
231
+ };
232
+ patterns: {
191
233
  getConfig: (name: string) => _pandacss_types.PatternConfig;
234
+ transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
192
235
  getNames: (name: string) => {
193
- name: string;
194
236
  upperName: string;
237
+ baseName: string;
195
238
  dashName: string;
196
239
  styleFnName: string;
197
240
  jsxName: string;
@@ -200,13 +243,29 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
200
243
  props: string[];
201
244
  blocklistType: string;
202
245
  config: _pandacss_types.PatternConfig;
203
- name: string;
246
+ type: "pattern";
247
+ match: RegExp;
248
+ jsx: (string | RegExp)[];
204
249
  upperName: string;
250
+ baseName: string;
251
+ dashName: string;
252
+ styleFnName: string;
253
+ jsxName: string;
254
+ }[];
255
+ getFnName: (jsxName: string) => string;
256
+ filter: (jsxName: string) => {
257
+ props: string[];
258
+ blocklistType: string;
259
+ config: _pandacss_types.PatternConfig;
260
+ type: "pattern";
261
+ match: RegExp;
262
+ jsx: (string | RegExp)[];
263
+ upperName: string;
264
+ baseName: string;
205
265
  dashName: string;
206
266
  styleFnName: string;
207
267
  jsxName: string;
208
268
  }[];
209
- getFnName: (jsx: string) => string;
210
269
  isEmpty: () => boolean;
211
270
  };
212
271
  jsx: {
@@ -214,7 +273,7 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
214
273
  upperName: string;
215
274
  typeName: string;
216
275
  componentName: string;
217
- framework: ("solid" | "react" | "preact" | "vue" | "qwik") | undefined;
276
+ framework: ("react" | "solid" | "preact" | "vue" | "qwik") | undefined;
218
277
  };
219
278
  paths: {
220
279
  get: (file?: string | undefined) => string[];
@@ -260,8 +319,9 @@ declare const createGenerator: (conf: ConfigResultWithHooks) => {
260
319
  createSheet: (options?: Pick<_pandacss_core.StylesheetOptions, "content"> | undefined) => _pandacss_core.Stylesheet;
261
320
  hooks: _pandacss_types.PandaHookable;
262
321
  path: string;
263
- config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "include" | "outdir" | "cwd">>;
322
+ config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "outdir" | "cwd" | "include">>;
264
323
  tsconfig?: TSConfig | undefined;
324
+ tsOptions?: _pandacss_types.ConfigTsOptions | undefined;
265
325
  tsconfigFile?: string | undefined;
266
326
  dependencies: string[];
267
327
  };