@pandacss/types 2.2.0 → 2.3.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/config.d.ts +34 -1
- package/package.json +1 -1
package/dist/config.d.ts
CHANGED
|
@@ -221,7 +221,7 @@ interface JsxOptions {
|
|
|
221
221
|
/**
|
|
222
222
|
* The style props allowed on generated JSX components
|
|
223
223
|
* - When set to 'all', all style props are allowed.
|
|
224
|
-
* - When set to 'minimal', only the `css` prop
|
|
224
|
+
* - When set to 'minimal', only the `css` prop, props ending in `Css`, and a pattern's or recipe's own props are allowed.
|
|
225
225
|
* - When set to 'none', no style props are allowed and therefore the jsxFactory will not be importable.
|
|
226
226
|
*
|
|
227
227
|
* @default 'all'
|
|
@@ -242,6 +242,39 @@ interface JsxOptions {
|
|
|
242
242
|
* ```
|
|
243
243
|
*/
|
|
244
244
|
jsxStyleProps?: 'all' | 'minimal' | 'none'
|
|
245
|
+
/**
|
|
246
|
+
* Rules for which JSX components Panda extracts style props from.
|
|
247
|
+
* The last rule matching a component wins, over Panda's own detection.
|
|
248
|
+
*
|
|
249
|
+
* @example
|
|
250
|
+
* ```js
|
|
251
|
+
* jsxMatchTag: [
|
|
252
|
+
* { from: '@tanstack/react-table', ignore: true },
|
|
253
|
+
* { tag: /Button$/ },
|
|
254
|
+
* { tag: 'Card', props: ['padding', 'color'] },
|
|
255
|
+
* ]
|
|
256
|
+
* ```
|
|
257
|
+
*/
|
|
258
|
+
jsxMatchTag?: JsxMatchTagRule[]
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
export interface JsxMatchTagRule {
|
|
262
|
+
/**
|
|
263
|
+
* The component name as written in source, such as `Button` or `UI.Button`.
|
|
264
|
+
*/
|
|
265
|
+
tag?: string | RegExp
|
|
266
|
+
/**
|
|
267
|
+
* The import path the component comes from, as written in source.
|
|
268
|
+
*/
|
|
269
|
+
from?: string | RegExp
|
|
270
|
+
/**
|
|
271
|
+
* Extract only these style props.
|
|
272
|
+
*/
|
|
273
|
+
props?: string[]
|
|
274
|
+
/**
|
|
275
|
+
* Never extract style props from matching components.
|
|
276
|
+
*/
|
|
277
|
+
ignore?: boolean
|
|
245
278
|
}
|
|
246
279
|
|
|
247
280
|
interface CssgenOptions {
|