@pandacss/generator 0.0.2 → 0.3.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/LICENSE.md +1 -1
- package/dist/index.d.ts +64 -85
- package/dist/index.js +832 -425
- package/dist/index.mjs +832 -419
- package/package.json +10 -9
package/LICENSE.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import * as _pandacss_token_dictionary from '@pandacss/token-dictionary';
|
|
2
|
-
import * as _pandacss_core from '@pandacss/core';
|
|
3
1
|
import * as _pandacss_types_dist_shared from '@pandacss/types/dist/shared';
|
|
2
|
+
import * as _pandacss_core from '@pandacss/core';
|
|
3
|
+
import * as _pandacss_token_dictionary from '@pandacss/token-dictionary';
|
|
4
|
+
import * as _pandacss_types_dist_config from '@pandacss/types/dist/config';
|
|
4
5
|
import * as _pandacss_types from '@pandacss/types';
|
|
5
|
-
import {
|
|
6
|
+
import { ConfigResultWithHooks } from '@pandacss/types';
|
|
6
7
|
|
|
7
|
-
declare const getEngine: (conf:
|
|
8
|
+
declare const getEngine: (conf: ConfigResultWithHooks) => {
|
|
8
9
|
patterns: {
|
|
9
10
|
transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
|
|
10
11
|
nodes: {
|
|
@@ -13,8 +14,8 @@ declare const getEngine: (conf: LoadConfigResult) => {
|
|
|
13
14
|
props: string[];
|
|
14
15
|
baseName: string;
|
|
15
16
|
}[];
|
|
16
|
-
patterns: Record<string, _pandacss_types.
|
|
17
|
-
getConfig: (name: string) => _pandacss_types.
|
|
17
|
+
patterns: Record<string, _pandacss_types.PatternConfig>;
|
|
18
|
+
getConfig: (name: string) => _pandacss_types.PatternConfig;
|
|
18
19
|
getNames: (name: string) => {
|
|
19
20
|
name: string;
|
|
20
21
|
upperName: string;
|
|
@@ -25,7 +26,7 @@ declare const getEngine: (conf: LoadConfigResult) => {
|
|
|
25
26
|
details: {
|
|
26
27
|
props: string[];
|
|
27
28
|
blocklistType: string;
|
|
28
|
-
config: _pandacss_types.
|
|
29
|
+
config: _pandacss_types.PatternConfig;
|
|
29
30
|
name: string;
|
|
30
31
|
upperName: string;
|
|
31
32
|
dashName: string;
|
|
@@ -35,41 +36,12 @@ declare const getEngine: (conf: LoadConfigResult) => {
|
|
|
35
36
|
getFnName: (jsx: string) => string;
|
|
36
37
|
isEmpty: () => boolean;
|
|
37
38
|
};
|
|
38
|
-
recipes: {
|
|
39
|
-
nodes: {
|
|
40
|
-
type: "recipe";
|
|
41
|
-
name: string;
|
|
42
|
-
props: string[];
|
|
43
|
-
baseName: string;
|
|
44
|
-
jsx: (string | RegExp)[];
|
|
45
|
-
match: RegExp;
|
|
46
|
-
}[];
|
|
47
|
-
recipes: Record<string, _pandacss_types.RecipeConfig<Record<string, _pandacss_types.AnyRecipeConfig>>>;
|
|
48
|
-
getConfig: (name: string) => _pandacss_types.AnyRecipeConfig | undefined;
|
|
49
|
-
getNames: (name: string) => {
|
|
50
|
-
upperName: string;
|
|
51
|
-
dashName: string;
|
|
52
|
-
jsxName: string;
|
|
53
|
-
};
|
|
54
|
-
details: {
|
|
55
|
-
config: _pandacss_types.RecipeConfig<Record<string, _pandacss_types.AnyRecipeConfig>>;
|
|
56
|
-
variantKeyMap: {
|
|
57
|
-
[k: string]: string[];
|
|
58
|
-
};
|
|
59
|
-
upperName: string;
|
|
60
|
-
dashName: string;
|
|
61
|
-
jsxName: string;
|
|
62
|
-
}[];
|
|
63
|
-
getFnName: (jsx: string) => string;
|
|
64
|
-
splitProps: (name: string, props: Record<string, any>) => Record<string, any>[];
|
|
65
|
-
isEmpty: () => boolean;
|
|
66
|
-
};
|
|
67
39
|
jsx: {
|
|
68
40
|
factoryName: string;
|
|
69
41
|
upperName: string;
|
|
70
42
|
typeName: string;
|
|
71
43
|
componentName: string;
|
|
72
|
-
framework:
|
|
44
|
+
framework: _pandacss_types_dist_config.JsxFramework | undefined;
|
|
73
45
|
};
|
|
74
46
|
paths: {
|
|
75
47
|
get: (file?: string | undefined) => string[];
|
|
@@ -88,16 +60,34 @@ declare const getEngine: (conf: LoadConfigResult) => {
|
|
|
88
60
|
import(mod: string, file: string): string;
|
|
89
61
|
export(file: string): string;
|
|
90
62
|
};
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
63
|
+
studio: {
|
|
64
|
+
outdir: string;
|
|
65
|
+
logo?: string | undefined;
|
|
66
|
+
inject?: {
|
|
67
|
+
head?: string | undefined;
|
|
68
|
+
body?: string | undefined;
|
|
69
|
+
} | undefined;
|
|
70
|
+
};
|
|
71
|
+
hash: {
|
|
72
|
+
tokens: boolean | undefined;
|
|
73
|
+
className: boolean | undefined;
|
|
74
|
+
};
|
|
75
|
+
prefix: {
|
|
76
|
+
tokens: string | undefined;
|
|
77
|
+
className: string | undefined;
|
|
78
|
+
};
|
|
95
79
|
tokens: _pandacss_token_dictionary.TokenDictionary;
|
|
96
|
-
|
|
97
|
-
dependencies: string[];
|
|
98
|
-
createSheet: (options?: _pandacss_core.StylesheetOptions | undefined) => _pandacss_core.Stylesheet;
|
|
80
|
+
utility: _pandacss_core.Utility;
|
|
99
81
|
properties: string[];
|
|
100
82
|
isValidProperty: (key: string) => boolean;
|
|
83
|
+
recipes: _pandacss_core.Recipes;
|
|
84
|
+
conditions: _pandacss_core.Conditions;
|
|
85
|
+
createSheetContext: () => _pandacss_core.StylesheetContext;
|
|
86
|
+
createSheet: (options?: Pick<_pandacss_core.StylesheetOptions, "content"> | undefined) => _pandacss_core.Stylesheet;
|
|
87
|
+
hooks: _pandacss_types.PandaHookable;
|
|
88
|
+
path: string;
|
|
89
|
+
config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "include" | "outdir" | "cwd">>;
|
|
90
|
+
dependencies: string[];
|
|
101
91
|
};
|
|
102
92
|
type Context = ReturnType<typeof getEngine>;
|
|
103
93
|
|
|
@@ -139,50 +129,28 @@ declare namespace messages {
|
|
|
139
129
|
};
|
|
140
130
|
}
|
|
141
131
|
|
|
142
|
-
declare const createGenerator: (conf:
|
|
132
|
+
declare const createGenerator: (conf: ConfigResultWithHooks) => {
|
|
143
133
|
config: _pandacss_types_dist_shared.UnwrapExtend<_pandacss_types.RequiredBy<_pandacss_types.Config, "include" | "outdir" | "cwd">>;
|
|
144
134
|
path: string;
|
|
145
135
|
conditions: _pandacss_core.Conditions;
|
|
146
136
|
utility: _pandacss_core.Utility;
|
|
137
|
+
hash: {
|
|
138
|
+
tokens: boolean | undefined;
|
|
139
|
+
className: boolean | undefined;
|
|
140
|
+
};
|
|
141
|
+
prefix: {
|
|
142
|
+
tokens: string | undefined;
|
|
143
|
+
className: string | undefined;
|
|
144
|
+
};
|
|
147
145
|
tokens: _pandacss_token_dictionary.TokenDictionary;
|
|
148
146
|
jsx: {
|
|
149
147
|
factoryName: string;
|
|
150
148
|
upperName: string;
|
|
151
149
|
typeName: string;
|
|
152
150
|
componentName: string;
|
|
153
|
-
framework:
|
|
154
|
-
};
|
|
155
|
-
recipes: {
|
|
156
|
-
nodes: {
|
|
157
|
-
type: "recipe";
|
|
158
|
-
name: string;
|
|
159
|
-
props: string[];
|
|
160
|
-
baseName: string;
|
|
161
|
-
jsx: (string | RegExp)[];
|
|
162
|
-
match: RegExp;
|
|
163
|
-
}[];
|
|
164
|
-
recipes: Record<string, _pandacss_types.RecipeConfig<Record<string, _pandacss_types.AnyRecipeConfig>>>;
|
|
165
|
-
getConfig: (name: string) => _pandacss_types.AnyRecipeConfig | undefined;
|
|
166
|
-
getNames: (name: string) => {
|
|
167
|
-
upperName: string;
|
|
168
|
-
dashName: string;
|
|
169
|
-
jsxName: string;
|
|
170
|
-
};
|
|
171
|
-
details: {
|
|
172
|
-
config: _pandacss_types.RecipeConfig<Record<string, _pandacss_types.AnyRecipeConfig>>;
|
|
173
|
-
variantKeyMap: {
|
|
174
|
-
[k: string]: string[];
|
|
175
|
-
};
|
|
176
|
-
upperName: string;
|
|
177
|
-
dashName: string;
|
|
178
|
-
jsxName: string;
|
|
179
|
-
}[];
|
|
180
|
-
getFnName: (jsx: string) => string;
|
|
181
|
-
splitProps: (name: string, props: Record<string, any>) => Record<string, any>[];
|
|
182
|
-
isEmpty: () => boolean;
|
|
151
|
+
framework: _pandacss_types_dist_config.JsxFramework | undefined;
|
|
183
152
|
};
|
|
184
|
-
|
|
185
|
-
dependencies: string[];
|
|
153
|
+
recipes: _pandacss_core.Recipes;
|
|
186
154
|
patterns: {
|
|
187
155
|
transform: (name: string, data: _pandacss_types.Dict) => _pandacss_types.SystemStyleObject;
|
|
188
156
|
nodes: {
|
|
@@ -191,8 +159,8 @@ declare const createGenerator: (conf: LoadConfigResult) => {
|
|
|
191
159
|
props: string[];
|
|
192
160
|
baseName: string;
|
|
193
161
|
}[];
|
|
194
|
-
patterns: Record<string, _pandacss_types.
|
|
195
|
-
getConfig: (name: string) => _pandacss_types.
|
|
162
|
+
patterns: Record<string, _pandacss_types.PatternConfig>;
|
|
163
|
+
getConfig: (name: string) => _pandacss_types.PatternConfig;
|
|
196
164
|
getNames: (name: string) => {
|
|
197
165
|
name: string;
|
|
198
166
|
upperName: string;
|
|
@@ -203,7 +171,7 @@ declare const createGenerator: (conf: LoadConfigResult) => {
|
|
|
203
171
|
details: {
|
|
204
172
|
props: string[];
|
|
205
173
|
blocklistType: string;
|
|
206
|
-
config: _pandacss_types.
|
|
174
|
+
config: _pandacss_types.PatternConfig;
|
|
207
175
|
name: string;
|
|
208
176
|
upperName: string;
|
|
209
177
|
dashName: string;
|
|
@@ -213,15 +181,23 @@ declare const createGenerator: (conf: LoadConfigResult) => {
|
|
|
213
181
|
getFnName: (jsx: string) => string;
|
|
214
182
|
isEmpty: () => boolean;
|
|
215
183
|
};
|
|
216
|
-
|
|
184
|
+
studio: {
|
|
185
|
+
outdir: string;
|
|
186
|
+
logo?: string | undefined;
|
|
187
|
+
inject?: {
|
|
188
|
+
head?: string | undefined;
|
|
189
|
+
body?: string | undefined;
|
|
190
|
+
} | undefined;
|
|
191
|
+
};
|
|
192
|
+
hooks: _pandacss_types.PandaHookable;
|
|
193
|
+
createSheet: (options?: Pick<_pandacss_core.StylesheetOptions, "content"> | undefined) => _pandacss_core.Stylesheet;
|
|
217
194
|
properties: string[];
|
|
218
|
-
isValidProperty: (key: string) => boolean;
|
|
219
195
|
getArtifacts: () => _pandacss_types.Artifact[];
|
|
220
196
|
getCss: (options: {
|
|
221
197
|
files: string[];
|
|
222
198
|
resolve?: boolean | undefined;
|
|
223
199
|
}) => string;
|
|
224
|
-
getParserCss: (result: _pandacss_types.
|
|
200
|
+
getParserCss: (result: _pandacss_types.ParserResultType) => string | undefined;
|
|
225
201
|
messages: {
|
|
226
202
|
artifactsGenerated: () => string;
|
|
227
203
|
configExists: (cmd: string) => string;
|
|
@@ -248,6 +224,9 @@ declare const createGenerator: (conf: LoadConfigResult) => {
|
|
|
248
224
|
import(mod: string, file: string): string;
|
|
249
225
|
export(file: string): string;
|
|
250
226
|
};
|
|
227
|
+
isValidProperty: (key: string) => boolean;
|
|
228
|
+
createSheetContext: () => _pandacss_core.StylesheetContext;
|
|
229
|
+
dependencies: string[];
|
|
251
230
|
parserOptions: {
|
|
252
231
|
importMap: {
|
|
253
232
|
css: string;
|
|
@@ -272,8 +251,8 @@ declare const createGenerator: (conf: LoadConfigResult) => {
|
|
|
272
251
|
match: RegExp;
|
|
273
252
|
})[];
|
|
274
253
|
};
|
|
275
|
-
getRecipeName: (
|
|
276
|
-
getRecipeByName: (name: string) => _pandacss_types.
|
|
254
|
+
getRecipeName: (jsxName: string) => string;
|
|
255
|
+
getRecipeByName: (name: string) => _pandacss_types.RecipeConfig | undefined;
|
|
277
256
|
};
|
|
278
257
|
};
|
|
279
258
|
type Generator = ReturnType<typeof createGenerator>;
|