@pandacss/generator 1.4.1 → 1.4.3
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.js +71 -41
- package/dist/index.mjs +71 -41
- package/package.json +9 -8
package/dist/index.js
CHANGED
|
@@ -36,6 +36,7 @@ module.exports = __toCommonJS(index_exports);
|
|
|
36
36
|
|
|
37
37
|
// src/generator.ts
|
|
38
38
|
var import_core5 = require("@pandacss/core");
|
|
39
|
+
var import_shared7 = require("@pandacss/shared");
|
|
39
40
|
var import_ts_pattern15 = require("ts-pattern");
|
|
40
41
|
|
|
41
42
|
// src/artifacts/setup-artifacts.ts
|
|
@@ -2638,7 +2639,7 @@ export interface AsProps {
|
|
|
2638
2639
|
as?: ElementType | undefined
|
|
2639
2640
|
}
|
|
2640
2641
|
|
|
2641
|
-
export type ElementType
|
|
2642
|
+
export type ElementType = keyof JSX.IntrinsicElements | Component<any>
|
|
2642
2643
|
|
|
2643
2644
|
export interface ${componentName}<T extends ElementType, P extends Dict = {}> {
|
|
2644
2645
|
(props: JsxHTMLProps<ComponentProps<T> & UnstyledProps & AsProps, Assign<JsxStyleProps, P>>): JSX.Element
|
|
@@ -2695,7 +2696,7 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2695
2696
|
${ctx.file.import(factoryName, "./factory")}
|
|
2696
2697
|
${ctx.file.import("getDisplayName", "./factory-helper")}
|
|
2697
2698
|
import { createComponent, mergeProps } from 'solid-js/web'
|
|
2698
|
-
import { createContext,
|
|
2699
|
+
import { createContext, createMemo, splitProps, useContext } from 'solid-js'
|
|
2699
2700
|
|
|
2700
2701
|
export function createStyleContext(recipe) {
|
|
2701
2702
|
const StyleContext = createContext({})
|
|
@@ -2706,35 +2707,39 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2706
2707
|
const { unstyled, ...restProps } = props
|
|
2707
2708
|
if (unstyled) return restProps
|
|
2708
2709
|
if (isConfigRecipe) {
|
|
2709
|
-
return { ...restProps,
|
|
2710
|
+
return { ...restProps, class: cx(slotStyles, restProps.class) }
|
|
2710
2711
|
}
|
|
2711
2712
|
${import_outdent34.outdent.string(
|
|
2712
2713
|
(0, import_ts_pattern11.match)(ctx.config.jsxStyleProps).with("all", () => `return { ...slotStyles, ...restProps }`).with("minimal", () => `return { ...restProps, css: css.raw(slotStyles, restProps.css) }`).with("none", () => `return { ...restProps, class: cx(css(slotStyles), restProps.class) }`).otherwise(() => `return restProps`)
|
|
2713
2714
|
)}
|
|
2714
2715
|
}
|
|
2715
|
-
|
|
2716
2716
|
|
|
2717
2717
|
const withRootProvider = (Component, options) => {
|
|
2718
2718
|
const WithRootProvider = (props) => {
|
|
2719
|
-
const
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2719
|
+
const [variantProps, otherProps] = svaFn.splitVariantProps(props)
|
|
2720
|
+
const [local, propsWithoutChildren] = splitProps(otherProps, ['children'])
|
|
2721
|
+
|
|
2722
|
+
const slotStyles = createMemo(() => {
|
|
2723
|
+
const styles = isConfigRecipe ? svaFn(variantProps) : svaFn.raw(variantProps)
|
|
2724
|
+
styles._classNameMap = svaFn.classNameMap
|
|
2725
|
+
return styles
|
|
2726
|
+
})
|
|
2724
2727
|
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
return {
|
|
2728
|
+
const mergedProps = createMemo(() => {
|
|
2729
|
+
if (!options?.defaultProps) return propsWithoutChildren
|
|
2730
|
+
return { ...options.defaultProps, ...propsWithoutChildren }
|
|
2728
2731
|
})
|
|
2729
2732
|
|
|
2730
2733
|
return createComponent(StyleContext.Provider, {
|
|
2731
|
-
value
|
|
2734
|
+
get value() {
|
|
2735
|
+
return slotStyles()
|
|
2736
|
+
},
|
|
2732
2737
|
get children() {
|
|
2733
2738
|
return createComponent(
|
|
2734
2739
|
Component,
|
|
2735
|
-
mergeProps(
|
|
2740
|
+
mergeProps(mergedProps, {
|
|
2736
2741
|
get children() {
|
|
2737
|
-
return
|
|
2742
|
+
return local.children
|
|
2738
2743
|
},
|
|
2739
2744
|
}),
|
|
2740
2745
|
)
|
|
@@ -2744,7 +2749,6 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2744
2749
|
|
|
2745
2750
|
const componentName = getDisplayName(Component)
|
|
2746
2751
|
WithRootProvider.displayName = \`withRootProvider(\${componentName})\`
|
|
2747
|
-
|
|
2748
2752
|
return WithRootProvider
|
|
2749
2753
|
}
|
|
2750
2754
|
|
|
@@ -2752,29 +2756,37 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2752
2756
|
const StyledComponent = ${factoryName}(Component, {}, options)
|
|
2753
2757
|
|
|
2754
2758
|
const WithProvider = (props) => {
|
|
2755
|
-
const
|
|
2756
|
-
|
|
2759
|
+
const [variantProps, restProps] = svaFn.splitVariantProps(props)
|
|
2760
|
+
const [local, propsWithoutChildren] = splitProps(restProps, ["children"])
|
|
2757
2761
|
|
|
2758
|
-
|
|
2759
|
-
|
|
2762
|
+
const slotStyles = createMemo(() => {
|
|
2763
|
+
const styles = isConfigRecipe ? svaFn(variantProps) : svaFn.raw(variantProps)
|
|
2764
|
+
styles._classNameMap = svaFn.classNameMap
|
|
2765
|
+
return styles
|
|
2766
|
+
})
|
|
2760
2767
|
|
|
2761
|
-
|
|
2762
|
-
const
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
|
|
2768
|
+
const resolvedProps = createMemo(() => {
|
|
2769
|
+
const propsWithClass = {
|
|
2770
|
+
...propsWithoutChildren,
|
|
2771
|
+
class: propsWithoutChildren.class ?? options?.defaultProps?.class,
|
|
2772
|
+
}
|
|
2773
|
+
const resolved = getResolvedProps(propsWithClass, slotStyles()[slot])
|
|
2774
|
+
resolved.class = cx(resolved.class, slotStyles()._classNameMap[slot])
|
|
2775
|
+
return resolved
|
|
2766
2776
|
})
|
|
2767
2777
|
|
|
2768
2778
|
return createComponent(StyleContext.Provider, {
|
|
2769
|
-
value
|
|
2779
|
+
get value() {
|
|
2780
|
+
return slotStyles()
|
|
2781
|
+
},
|
|
2770
2782
|
get children() {
|
|
2771
2783
|
return createComponent(
|
|
2772
2784
|
StyledComponent,
|
|
2773
|
-
mergeProps(
|
|
2785
|
+
mergeProps(resolvedProps, {
|
|
2774
2786
|
get children() {
|
|
2775
|
-
return
|
|
2787
|
+
return local.children
|
|
2776
2788
|
},
|
|
2777
|
-
})
|
|
2789
|
+
})
|
|
2778
2790
|
)
|
|
2779
2791
|
},
|
|
2780
2792
|
})
|
|
@@ -2782,7 +2794,6 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2782
2794
|
|
|
2783
2795
|
const componentName = getDisplayName(Component)
|
|
2784
2796
|
WithProvider.displayName = \`withProvider(\${componentName})\`
|
|
2785
|
-
|
|
2786
2797
|
return WithProvider
|
|
2787
2798
|
}
|
|
2788
2799
|
|
|
@@ -2791,19 +2802,30 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2791
2802
|
|
|
2792
2803
|
const WithContext = (props) => {
|
|
2793
2804
|
const slotStyles = useContext(StyleContext)
|
|
2794
|
-
const
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2805
|
+
const [local, propsWithoutChildren] = splitProps(props, ["children"])
|
|
2806
|
+
|
|
2807
|
+
const resolvedProps = createMemo(() => {
|
|
2808
|
+
const propsWithClass = {
|
|
2809
|
+
...propsWithoutChildren,
|
|
2810
|
+
class: propsWithoutChildren.class ?? options?.defaultProps?.class,
|
|
2811
|
+
}
|
|
2812
|
+
const resolved = getResolvedProps(propsWithClass, slotStyles[slot])
|
|
2813
|
+
resolved.class = cx(resolved.class, slotStyles._classNameMap?.[slot])
|
|
2814
|
+
return resolved
|
|
2799
2815
|
})
|
|
2800
2816
|
|
|
2801
|
-
return createComponent(
|
|
2817
|
+
return createComponent(
|
|
2818
|
+
StyledComponent,
|
|
2819
|
+
mergeProps(resolvedProps, {
|
|
2820
|
+
get children() {
|
|
2821
|
+
return local.children
|
|
2822
|
+
},
|
|
2823
|
+
})
|
|
2824
|
+
)
|
|
2802
2825
|
}
|
|
2803
2826
|
|
|
2804
2827
|
const componentName = getDisplayName(Component)
|
|
2805
2828
|
WithContext.displayName = \`withContext(\${componentName})\`
|
|
2806
|
-
|
|
2807
2829
|
return WithContext
|
|
2808
2830
|
}
|
|
2809
2831
|
|
|
@@ -2824,10 +2846,11 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2824
2846
|
unstyled?: boolean | undefined
|
|
2825
2847
|
}
|
|
2826
2848
|
|
|
2827
|
-
interface WithProviderOptions<P
|
|
2849
|
+
interface WithProviderOptions<P> {
|
|
2828
2850
|
defaultProps?: Partial<P> | undefined
|
|
2829
2851
|
}
|
|
2830
|
-
|
|
2852
|
+
|
|
2853
|
+
type ElementType = keyof JSX.IntrinsicElements | Component<any>
|
|
2831
2854
|
|
|
2832
2855
|
type SvaFn<S extends string = any> = SlotRecipeRuntimeFn<S, any>
|
|
2833
2856
|
interface SlotRecipeFn {
|
|
@@ -2837,7 +2860,11 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2837
2860
|
}
|
|
2838
2861
|
type SlotRecipe = SvaFn | SlotRecipeFn
|
|
2839
2862
|
|
|
2840
|
-
type InferSlot<R extends SlotRecipe> = R extends SlotRecipeFn
|
|
2863
|
+
type InferSlot<R extends SlotRecipe> = R extends SlotRecipeFn
|
|
2864
|
+
? R['__slot']
|
|
2865
|
+
: R extends SvaFn<infer S>
|
|
2866
|
+
? S
|
|
2867
|
+
: never
|
|
2841
2868
|
|
|
2842
2869
|
type StyleContextProvider<T extends ElementType, R extends SlotRecipe> = Component<
|
|
2843
2870
|
JsxHTMLProps<ComponentProps<T> & UnstyledProps, Assign<RecipeVariantProps<R>, JsxStyleProps>>
|
|
@@ -5628,7 +5655,10 @@ var Generator = class extends import_core5.Context {
|
|
|
5628
5655
|
};
|
|
5629
5656
|
appendCssOfType = (type, sheet) => {
|
|
5630
5657
|
(0, import_ts_pattern15.match)(type).with("preflight", () => generateResetCss(this, sheet)).with("tokens", () => generateTokenCss(this, sheet)).with("static", () => generateStaticCss(this, sheet)).with("global", () => generateGlobalCss(this, sheet)).with("keyframes", () => generateKeyframeCss(this, sheet)).otherwise(() => {
|
|
5631
|
-
throw new
|
|
5658
|
+
throw new import_shared7.PandaError(
|
|
5659
|
+
"UNKNOWN_ARTIFACT",
|
|
5660
|
+
`Unknown CSS artifact type: "${type}". Expected one of: preflight, tokens, static, global, keyframes`
|
|
5661
|
+
);
|
|
5632
5662
|
});
|
|
5633
5663
|
};
|
|
5634
5664
|
appendLayerParams = (sheet) => {
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
// src/generator.ts
|
|
2
2
|
import { Context as Context2 } from "@pandacss/core";
|
|
3
|
+
import { PandaError } from "@pandacss/shared";
|
|
3
4
|
import { match as match15 } from "ts-pattern";
|
|
4
5
|
|
|
5
6
|
// src/artifacts/setup-artifacts.ts
|
|
@@ -2602,7 +2603,7 @@ export interface AsProps {
|
|
|
2602
2603
|
as?: ElementType | undefined
|
|
2603
2604
|
}
|
|
2604
2605
|
|
|
2605
|
-
export type ElementType
|
|
2606
|
+
export type ElementType = keyof JSX.IntrinsicElements | Component<any>
|
|
2606
2607
|
|
|
2607
2608
|
export interface ${componentName}<T extends ElementType, P extends Dict = {}> {
|
|
2608
2609
|
(props: JsxHTMLProps<ComponentProps<T> & UnstyledProps & AsProps, Assign<JsxStyleProps, P>>): JSX.Element
|
|
@@ -2659,7 +2660,7 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2659
2660
|
${ctx.file.import(factoryName, "./factory")}
|
|
2660
2661
|
${ctx.file.import("getDisplayName", "./factory-helper")}
|
|
2661
2662
|
import { createComponent, mergeProps } from 'solid-js/web'
|
|
2662
|
-
import { createContext,
|
|
2663
|
+
import { createContext, createMemo, splitProps, useContext } from 'solid-js'
|
|
2663
2664
|
|
|
2664
2665
|
export function createStyleContext(recipe) {
|
|
2665
2666
|
const StyleContext = createContext({})
|
|
@@ -2670,35 +2671,39 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2670
2671
|
const { unstyled, ...restProps } = props
|
|
2671
2672
|
if (unstyled) return restProps
|
|
2672
2673
|
if (isConfigRecipe) {
|
|
2673
|
-
return { ...restProps,
|
|
2674
|
+
return { ...restProps, class: cx(slotStyles, restProps.class) }
|
|
2674
2675
|
}
|
|
2675
2676
|
${outdent34.string(
|
|
2676
2677
|
match11(ctx.config.jsxStyleProps).with("all", () => `return { ...slotStyles, ...restProps }`).with("minimal", () => `return { ...restProps, css: css.raw(slotStyles, restProps.css) }`).with("none", () => `return { ...restProps, class: cx(css(slotStyles), restProps.class) }`).otherwise(() => `return restProps`)
|
|
2677
2678
|
)}
|
|
2678
2679
|
}
|
|
2679
|
-
|
|
2680
2680
|
|
|
2681
2681
|
const withRootProvider = (Component, options) => {
|
|
2682
2682
|
const WithRootProvider = (props) => {
|
|
2683
|
-
const
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2683
|
+
const [variantProps, otherProps] = svaFn.splitVariantProps(props)
|
|
2684
|
+
const [local, propsWithoutChildren] = splitProps(otherProps, ['children'])
|
|
2685
|
+
|
|
2686
|
+
const slotStyles = createMemo(() => {
|
|
2687
|
+
const styles = isConfigRecipe ? svaFn(variantProps) : svaFn.raw(variantProps)
|
|
2688
|
+
styles._classNameMap = svaFn.classNameMap
|
|
2689
|
+
return styles
|
|
2690
|
+
})
|
|
2688
2691
|
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
return {
|
|
2692
|
+
const mergedProps = createMemo(() => {
|
|
2693
|
+
if (!options?.defaultProps) return propsWithoutChildren
|
|
2694
|
+
return { ...options.defaultProps, ...propsWithoutChildren }
|
|
2692
2695
|
})
|
|
2693
2696
|
|
|
2694
2697
|
return createComponent(StyleContext.Provider, {
|
|
2695
|
-
value
|
|
2698
|
+
get value() {
|
|
2699
|
+
return slotStyles()
|
|
2700
|
+
},
|
|
2696
2701
|
get children() {
|
|
2697
2702
|
return createComponent(
|
|
2698
2703
|
Component,
|
|
2699
|
-
mergeProps(
|
|
2704
|
+
mergeProps(mergedProps, {
|
|
2700
2705
|
get children() {
|
|
2701
|
-
return
|
|
2706
|
+
return local.children
|
|
2702
2707
|
},
|
|
2703
2708
|
}),
|
|
2704
2709
|
)
|
|
@@ -2708,7 +2713,6 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2708
2713
|
|
|
2709
2714
|
const componentName = getDisplayName(Component)
|
|
2710
2715
|
WithRootProvider.displayName = \`withRootProvider(\${componentName})\`
|
|
2711
|
-
|
|
2712
2716
|
return WithRootProvider
|
|
2713
2717
|
}
|
|
2714
2718
|
|
|
@@ -2716,29 +2720,37 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2716
2720
|
const StyledComponent = ${factoryName}(Component, {}, options)
|
|
2717
2721
|
|
|
2718
2722
|
const WithProvider = (props) => {
|
|
2719
|
-
const
|
|
2720
|
-
|
|
2723
|
+
const [variantProps, restProps] = svaFn.splitVariantProps(props)
|
|
2724
|
+
const [local, propsWithoutChildren] = splitProps(restProps, ["children"])
|
|
2721
2725
|
|
|
2722
|
-
|
|
2723
|
-
|
|
2726
|
+
const slotStyles = createMemo(() => {
|
|
2727
|
+
const styles = isConfigRecipe ? svaFn(variantProps) : svaFn.raw(variantProps)
|
|
2728
|
+
styles._classNameMap = svaFn.classNameMap
|
|
2729
|
+
return styles
|
|
2730
|
+
})
|
|
2724
2731
|
|
|
2725
|
-
|
|
2726
|
-
const
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2732
|
+
const resolvedProps = createMemo(() => {
|
|
2733
|
+
const propsWithClass = {
|
|
2734
|
+
...propsWithoutChildren,
|
|
2735
|
+
class: propsWithoutChildren.class ?? options?.defaultProps?.class,
|
|
2736
|
+
}
|
|
2737
|
+
const resolved = getResolvedProps(propsWithClass, slotStyles()[slot])
|
|
2738
|
+
resolved.class = cx(resolved.class, slotStyles()._classNameMap[slot])
|
|
2739
|
+
return resolved
|
|
2730
2740
|
})
|
|
2731
2741
|
|
|
2732
2742
|
return createComponent(StyleContext.Provider, {
|
|
2733
|
-
value
|
|
2743
|
+
get value() {
|
|
2744
|
+
return slotStyles()
|
|
2745
|
+
},
|
|
2734
2746
|
get children() {
|
|
2735
2747
|
return createComponent(
|
|
2736
2748
|
StyledComponent,
|
|
2737
|
-
mergeProps(
|
|
2749
|
+
mergeProps(resolvedProps, {
|
|
2738
2750
|
get children() {
|
|
2739
|
-
return
|
|
2751
|
+
return local.children
|
|
2740
2752
|
},
|
|
2741
|
-
})
|
|
2753
|
+
})
|
|
2742
2754
|
)
|
|
2743
2755
|
},
|
|
2744
2756
|
})
|
|
@@ -2746,7 +2758,6 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2746
2758
|
|
|
2747
2759
|
const componentName = getDisplayName(Component)
|
|
2748
2760
|
WithProvider.displayName = \`withProvider(\${componentName})\`
|
|
2749
|
-
|
|
2750
2761
|
return WithProvider
|
|
2751
2762
|
}
|
|
2752
2763
|
|
|
@@ -2755,19 +2766,30 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2755
2766
|
|
|
2756
2767
|
const WithContext = (props) => {
|
|
2757
2768
|
const slotStyles = useContext(StyleContext)
|
|
2758
|
-
const
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
|
|
2769
|
+
const [local, propsWithoutChildren] = splitProps(props, ["children"])
|
|
2770
|
+
|
|
2771
|
+
const resolvedProps = createMemo(() => {
|
|
2772
|
+
const propsWithClass = {
|
|
2773
|
+
...propsWithoutChildren,
|
|
2774
|
+
class: propsWithoutChildren.class ?? options?.defaultProps?.class,
|
|
2775
|
+
}
|
|
2776
|
+
const resolved = getResolvedProps(propsWithClass, slotStyles[slot])
|
|
2777
|
+
resolved.class = cx(resolved.class, slotStyles._classNameMap?.[slot])
|
|
2778
|
+
return resolved
|
|
2763
2779
|
})
|
|
2764
2780
|
|
|
2765
|
-
return createComponent(
|
|
2781
|
+
return createComponent(
|
|
2782
|
+
StyledComponent,
|
|
2783
|
+
mergeProps(resolvedProps, {
|
|
2784
|
+
get children() {
|
|
2785
|
+
return local.children
|
|
2786
|
+
},
|
|
2787
|
+
})
|
|
2788
|
+
)
|
|
2766
2789
|
}
|
|
2767
2790
|
|
|
2768
2791
|
const componentName = getDisplayName(Component)
|
|
2769
2792
|
WithContext.displayName = \`withContext(\${componentName})\`
|
|
2770
|
-
|
|
2771
2793
|
return WithContext
|
|
2772
2794
|
}
|
|
2773
2795
|
|
|
@@ -2788,10 +2810,11 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2788
2810
|
unstyled?: boolean | undefined
|
|
2789
2811
|
}
|
|
2790
2812
|
|
|
2791
|
-
interface WithProviderOptions<P
|
|
2813
|
+
interface WithProviderOptions<P> {
|
|
2792
2814
|
defaultProps?: Partial<P> | undefined
|
|
2793
2815
|
}
|
|
2794
|
-
|
|
2816
|
+
|
|
2817
|
+
type ElementType = keyof JSX.IntrinsicElements | Component<any>
|
|
2795
2818
|
|
|
2796
2819
|
type SvaFn<S extends string = any> = SlotRecipeRuntimeFn<S, any>
|
|
2797
2820
|
interface SlotRecipeFn {
|
|
@@ -2801,7 +2824,11 @@ function generateSolidCreateStyleContext(ctx) {
|
|
|
2801
2824
|
}
|
|
2802
2825
|
type SlotRecipe = SvaFn | SlotRecipeFn
|
|
2803
2826
|
|
|
2804
|
-
type InferSlot<R extends SlotRecipe> = R extends SlotRecipeFn
|
|
2827
|
+
type InferSlot<R extends SlotRecipe> = R extends SlotRecipeFn
|
|
2828
|
+
? R['__slot']
|
|
2829
|
+
: R extends SvaFn<infer S>
|
|
2830
|
+
? S
|
|
2831
|
+
: never
|
|
2805
2832
|
|
|
2806
2833
|
type StyleContextProvider<T extends ElementType, R extends SlotRecipe> = Component<
|
|
2807
2834
|
JsxHTMLProps<ComponentProps<T> & UnstyledProps, Assign<RecipeVariantProps<R>, JsxStyleProps>>
|
|
@@ -5592,7 +5619,10 @@ var Generator = class extends Context2 {
|
|
|
5592
5619
|
};
|
|
5593
5620
|
appendCssOfType = (type, sheet) => {
|
|
5594
5621
|
match15(type).with("preflight", () => generateResetCss(this, sheet)).with("tokens", () => generateTokenCss(this, sheet)).with("static", () => generateStaticCss(this, sheet)).with("global", () => generateGlobalCss(this, sheet)).with("keyframes", () => generateKeyframeCss(this, sheet)).otherwise(() => {
|
|
5595
|
-
throw new
|
|
5622
|
+
throw new PandaError(
|
|
5623
|
+
"UNKNOWN_ARTIFACT",
|
|
5624
|
+
`Unknown CSS artifact type: "${type}". Expected one of: preflight, tokens, static, global, keyframes`
|
|
5625
|
+
);
|
|
5596
5626
|
});
|
|
5597
5627
|
};
|
|
5598
5628
|
appendLayerParams = (sheet) => {
|
package/package.json
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pandacss/generator",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.3",
|
|
4
4
|
"description": "The css generator for css panda",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
8
8
|
"author": "Segun Adebayo <joseshegs@gmail.com>",
|
|
9
|
+
"license": "MIT",
|
|
9
10
|
"sideEffects": false,
|
|
10
11
|
"homepage": "https://panda-css.com",
|
|
11
12
|
"repository": {
|
|
@@ -35,14 +36,14 @@
|
|
|
35
36
|
"javascript-stringify": "2.1.0",
|
|
36
37
|
"outdent": " ^0.8.0",
|
|
37
38
|
"pluralize": "8.0.0",
|
|
38
|
-
"postcss": "8.
|
|
39
|
+
"postcss": "8.5.6",
|
|
39
40
|
"ts-pattern": "5.8.0",
|
|
40
|
-
"@pandacss/core": "1.4.
|
|
41
|
-
"@pandacss/is-valid-prop": "^1.4.
|
|
42
|
-
"@pandacss/logger": "1.4.
|
|
43
|
-
"@pandacss/shared": "1.4.
|
|
44
|
-
"@pandacss/token-dictionary": "1.4.
|
|
45
|
-
"@pandacss/types": "1.4.
|
|
41
|
+
"@pandacss/core": "1.4.3",
|
|
42
|
+
"@pandacss/is-valid-prop": "^1.4.3",
|
|
43
|
+
"@pandacss/logger": "1.4.3",
|
|
44
|
+
"@pandacss/shared": "1.4.3",
|
|
45
|
+
"@pandacss/token-dictionary": "1.4.3",
|
|
46
|
+
"@pandacss/types": "1.4.3"
|
|
46
47
|
},
|
|
47
48
|
"devDependencies": {
|
|
48
49
|
"@types/pluralize": "0.0.33"
|