github chakra-ui/panda @pandacss/config@0.34.2

latest releases: @pandacss/preset-base@0.53.3, @pandacss/types@0.53.3, @pandacss/token-dictionary@0.53.3...
13 months ago

Patch Changes

  • 58388de: Fix a false positive with the validation check that reported Missing token when using a color opacity modifier in
    config tokens or semanticTokens

    import { defineConfig } from "@pandacss/dev";
    
    export default defineConfig({
      validation: "warn",
      conditions: {
        light: ".light &",
        dark: ".dark &",
      },
      theme: {
        tokens: {
          colors: {
            blue: { 500: { value: "blue" } },
            green: { 500: { value: "green" } },
          },
          opacity: {
            half: { value: 0.5 },
          },
        },
        semanticTokens: {
          colors: {
            secondary: {
              value: {
                base: "red",
                _light: "{colors.blue.500/32}",
                _dark: "{colors.green.500/half}",
              },
            },
          },
        },
      },
    });

    Would incorrectly report:

    • [tokens] Missing token: colors.green.500/half used in config.semanticTokens.colors.secondary
    • [tokens] Missing token: colors.blue.500/32 used in config.semanticTokens.colors.secondary
    • @pandacss/types@0.34.2
    • @pandacss/logger@0.34.2
    • @pandacss/preset-base@0.34.2
    • @pandacss/preset-panda@0.34.2
    • @pandacss/shared@0.34.2

Don't miss a new panda release

NewReleases is sending notifications on new releases.