@pandacss/studio 0.3.0 → 0.3.2

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.
Files changed (96) hide show
  1. package/LICENSE.md +1 -1
  2. package/package.json +8 -8
  3. package/src/components/analyzer/category-utilities.tsx +12 -4
  4. package/src/components/analyzer/data-combobox.tsx +50 -27
  5. package/src/components/analyzer/data-table.tsx +5 -9
  6. package/src/components/analyzer/external-icon.tsx +1 -1
  7. package/src/components/analyzer/report-item-columns.tsx +1 -1
  8. package/src/components/analyzer/report-item-link.tsx +1 -1
  9. package/src/components/analyzer/truncated-text.tsx +3 -1
  10. package/src/components/analyzer/utility-details.tsx +31 -25
  11. package/src/components/color-item.tsx +1 -1
  12. package/src/components/colors.tsx +12 -3
  13. package/src/components/icons.tsx +49 -0
  14. package/src/components/input.tsx +3 -3
  15. package/src/components/semantic-color.tsx +25 -19
  16. package/src/components/token-analyzer.tsx +7 -5
  17. package/src/layouts/Layout.astro +1 -1
  18. package/src/layouts/Sidebar.astro +2 -2
  19. package/styled-system/chunks/src__components__analyzer__category-utilities.css +21 -173
  20. package/styled-system/chunks/src__components__analyzer__data-combobox.css +63 -205
  21. package/styled-system/chunks/src__components__analyzer__data-table.css +8 -0
  22. package/styled-system/chunks/src__components__analyzer__report-item-columns.css +12 -4
  23. package/styled-system/chunks/src__components__analyzer__report-item-link.css +10 -106
  24. package/styled-system/chunks/src__components__analyzer__truncated-text.css +4 -16
  25. package/styled-system/chunks/src__components__analyzer__utility-details.css +32 -120
  26. package/styled-system/chunks/src__components__color-item.css +2 -2
  27. package/styled-system/chunks/src__components__colors.css +10 -2
  28. package/styled-system/chunks/src__components__semantic-color.css +28 -8
  29. package/styled-system/chunks/src__components__token-analyzer.css +18 -1361
  30. package/styled-system/chunks/src__layouts__Sidebar.css +4 -4
  31. package/styled-system/css/css.d.ts +1 -0
  32. package/styled-system/css/cva.d.ts +1 -0
  33. package/styled-system/css/cx.d.ts +1 -0
  34. package/styled-system/css/index.d.ts +1 -0
  35. package/styled-system/jsx/aspect-ratio.d.ts +1 -0
  36. package/styled-system/jsx/box.d.ts +1 -0
  37. package/styled-system/jsx/center.d.ts +1 -0
  38. package/styled-system/jsx/circle.d.ts +1 -0
  39. package/styled-system/jsx/container.d.ts +1 -0
  40. package/styled-system/jsx/divider.d.ts +1 -0
  41. package/styled-system/jsx/factory.d.ts +1 -0
  42. package/styled-system/jsx/flex.d.ts +1 -0
  43. package/styled-system/jsx/float.d.ts +1 -0
  44. package/styled-system/jsx/grid-item.d.ts +1 -0
  45. package/styled-system/jsx/grid.d.ts +1 -0
  46. package/styled-system/jsx/hstack.d.ts +1 -0
  47. package/styled-system/jsx/index.d.ts +1 -0
  48. package/styled-system/jsx/link-box.d.ts +1 -0
  49. package/styled-system/jsx/link-overlay.d.ts +1 -0
  50. package/styled-system/jsx/spacer.d.ts +1 -0
  51. package/styled-system/jsx/square.d.ts +1 -0
  52. package/styled-system/jsx/stack.d.ts +1 -0
  53. package/styled-system/jsx/styled-link.d.ts +1 -0
  54. package/styled-system/jsx/vstack.d.ts +1 -0
  55. package/styled-system/jsx/wrap.d.ts +1 -0
  56. package/styled-system/patterns/aspect-ratio.d.ts +1 -0
  57. package/styled-system/patterns/box.d.ts +1 -0
  58. package/styled-system/patterns/center.d.ts +1 -0
  59. package/styled-system/patterns/circle.d.ts +1 -0
  60. package/styled-system/patterns/container.d.ts +1 -0
  61. package/styled-system/patterns/divider.d.ts +1 -0
  62. package/styled-system/patterns/flex.d.ts +1 -0
  63. package/styled-system/patterns/float.d.ts +1 -0
  64. package/styled-system/patterns/grid-item.d.ts +1 -0
  65. package/styled-system/patterns/grid.d.ts +1 -0
  66. package/styled-system/patterns/hstack.d.ts +1 -0
  67. package/styled-system/patterns/index.d.ts +1 -0
  68. package/styled-system/patterns/link-box.d.ts +1 -0
  69. package/styled-system/patterns/link-overlay.d.ts +1 -0
  70. package/styled-system/patterns/spacer.d.ts +1 -0
  71. package/styled-system/patterns/square.d.ts +1 -0
  72. package/styled-system/patterns/stack.d.ts +1 -0
  73. package/styled-system/patterns/styled-link.d.ts +1 -0
  74. package/styled-system/patterns/vstack.d.ts +1 -0
  75. package/styled-system/patterns/wrap.d.ts +1 -0
  76. package/styled-system/styles.css +80 -92
  77. package/styled-system/tokens/index.d.ts +1 -0
  78. package/styled-system/tokens/tokens.d.ts +1 -0
  79. package/styled-system/types/composition.d.ts +1 -0
  80. package/styled-system/types/conditions.d.ts +1 -0
  81. package/styled-system/types/csstype.d.ts +1 -0
  82. package/styled-system/types/global.d.ts +6 -5
  83. package/styled-system/types/helpers.d.ts +1 -0
  84. package/styled-system/types/index.d.ts +3 -2
  85. package/styled-system/types/jsx.d.ts +1 -0
  86. package/styled-system/types/parts.d.ts +1 -0
  87. package/styled-system/types/pattern.d.ts +8 -6
  88. package/styled-system/types/prop-type.d.ts +1 -0
  89. package/styled-system/types/recipe.d.ts +1 -0
  90. package/styled-system/types/selectors.d.ts +1 -0
  91. package/styled-system/types/style-props.d.ts +4 -3
  92. package/styled-system/types/system-types.d.ts +1 -0
  93. package/styled-system/jsx/absolute-center.d.ts +0 -8
  94. package/styled-system/jsx/absolute-center.mjs +0 -9
  95. package/styled-system/patterns/absolute-center.d.ts +0 -14
  96. package/styled-system/patterns/absolute-center.mjs +0 -23
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  export type Token = "easings.default" | "easings.linear" | "easings.in" | "easings.out" | "easings.in-out" | "durations.fastest" | "durations.faster" | "durations.fast" | "durations.normal" | "durations.slow" | "durations.slower" | "durations.slowest" | "radii.xs" | "radii.sm" | "radii.md" | "radii.lg" | "radii.xl" | "radii.2xl" | "radii.3xl" | "radii.full" | "fontWeights.thin" | "fontWeights.extralight" | "fontWeights.light" | "fontWeights.normal" | "fontWeights.medium" | "fontWeights.semibold" | "fontWeights.bold" | "fontWeights.extrabold" | "fontWeights.black" | "lineHeights.none" | "lineHeights.tight" | "lineHeights.snug" | "lineHeights.normal" | "lineHeights.relaxed" | "lineHeights.loose" | "fonts.sans" | "fonts.serif" | "fonts.mono" | "letterSpacings.tighter" | "letterSpacings.tight" | "letterSpacings.normal" | "letterSpacings.wide" | "letterSpacings.wider" | "letterSpacings.widest" | "fontSizes.2xs" | "fontSizes.xs" | "fontSizes.sm" | "fontSizes.md" | "fontSizes.lg" | "fontSizes.xl" | "fontSizes.2xl" | "fontSizes.3xl" | "fontSizes.4xl" | "fontSizes.5xl" | "fontSizes.6xl" | "fontSizes.7xl" | "fontSizes.8xl" | "fontSizes.9xl" | "shadows.xs" | "shadows.sm" | "shadows.md" | "shadows.lg" | "shadows.xl" | "shadows.2xl" | "shadows.inner" | "blurs.sm" | "blurs.base" | "blurs.md" | "blurs.lg" | "blurs.xl" | "blurs.2xl" | "blurs.3xl" | "spacing.1" | "spacing.2" | "spacing.3" | "spacing.4" | "spacing.5" | "spacing.6" | "spacing.7" | "spacing.8" | "spacing.9" | "spacing.10" | "spacing.11" | "spacing.12" | "spacing.14" | "spacing.16" | "spacing.20" | "spacing.24" | "spacing.28" | "spacing.32" | "spacing.36" | "spacing.40" | "spacing.44" | "spacing.48" | "spacing.52" | "spacing.56" | "spacing.60" | "spacing.64" | "spacing.72" | "spacing.80" | "spacing.96" | "spacing.0.5" | "spacing.1.5" | "spacing.2.5" | "spacing.3.5" | "sizes.1" | "sizes.2" | "sizes.3" | "sizes.4" | "sizes.5" | "sizes.6" | "sizes.7" | "sizes.8" | "sizes.9" | "sizes.10" | "sizes.11" | "sizes.12" | "sizes.14" | "sizes.16" | "sizes.20" | "sizes.24" | "sizes.28" | "sizes.32" | "sizes.36" | "sizes.40" | "sizes.44" | "sizes.48" | "sizes.52" | "sizes.56" | "sizes.60" | "sizes.64" | "sizes.72" | "sizes.80" | "sizes.96" | "sizes.0.5" | "sizes.1.5" | "sizes.2.5" | "sizes.3.5" | "sizes.xs" | "sizes.sm" | "sizes.md" | "sizes.lg" | "sizes.xl" | "sizes.2xl" | "sizes.3xl" | "sizes.4xl" | "sizes.5xl" | "sizes.6xl" | "sizes.7xl" | "sizes.8xl" | "sizes.prose" | "sizes.full" | "sizes.min" | "sizes.max" | "sizes.fit" | "sizes.breakpoint-sm" | "sizes.breakpoint-md" | "sizes.breakpoint-lg" | "sizes.breakpoint-xl" | "sizes.breakpoint-2xl" | "animations.spin" | "animations.ping" | "animations.pulse" | "animations.bounce" | "colors.current" | "colors.black" | "colors.white" | "colors.transparent" | "colors.rose.50" | "colors.rose.100" | "colors.rose.200" | "colors.rose.300" | "colors.rose.400" | "colors.rose.500" | "colors.rose.600" | "colors.rose.700" | "colors.rose.800" | "colors.rose.900" | "colors.pink.50" | "colors.pink.100" | "colors.pink.200" | "colors.pink.300" | "colors.pink.400" | "colors.pink.500" | "colors.pink.600" | "colors.pink.700" | "colors.pink.800" | "colors.pink.900" | "colors.fuchsia.50" | "colors.fuchsia.100" | "colors.fuchsia.200" | "colors.fuchsia.300" | "colors.fuchsia.400" | "colors.fuchsia.500" | "colors.fuchsia.600" | "colors.fuchsia.700" | "colors.fuchsia.800" | "colors.fuchsia.900" | "colors.purple.50" | "colors.purple.100" | "colors.purple.200" | "colors.purple.300" | "colors.purple.400" | "colors.purple.500" | "colors.purple.600" | "colors.purple.700" | "colors.purple.800" | "colors.purple.900" | "colors.indigo.50" | "colors.indigo.100" | "colors.indigo.200" | "colors.indigo.300" | "colors.indigo.400" | "colors.indigo.500" | "colors.indigo.600" | "colors.indigo.700" | "colors.indigo.800" | "colors.indigo.900" | "colors.blue.50" | "colors.blue.100" | "colors.blue.200" | "colors.blue.300" | "colors.blue.400" | "colors.blue.500" | "colors.blue.600" | "colors.blue.700" | "colors.blue.800" | "colors.blue.900" | "colors.sky.50" | "colors.sky.100" | "colors.sky.200" | "colors.sky.300" | "colors.sky.400" | "colors.sky.500" | "colors.sky.600" | "colors.sky.700" | "colors.sky.800" | "colors.sky.900" | "colors.cyan.50" | "colors.cyan.100" | "colors.cyan.200" | "colors.cyan.300" | "colors.cyan.400" | "colors.cyan.500" | "colors.cyan.600" | "colors.cyan.700" | "colors.cyan.800" | "colors.cyan.900" | "colors.teal.50" | "colors.teal.100" | "colors.teal.200" | "colors.teal.300" | "colors.teal.400" | "colors.teal.500" | "colors.teal.600" | "colors.teal.700" | "colors.teal.800" | "colors.teal.900" | "colors.green.50" | "colors.green.100" | "colors.green.200" | "colors.green.300" | "colors.green.400" | "colors.green.500" | "colors.green.600" | "colors.green.700" | "colors.green.800" | "colors.green.900" | "colors.lime.50" | "colors.lime.100" | "colors.lime.200" | "colors.lime.300" | "colors.lime.400" | "colors.lime.500" | "colors.lime.600" | "colors.lime.700" | "colors.lime.800" | "colors.lime.900" | "colors.yellow.50" | "colors.yellow.100" | "colors.yellow.200" | "colors.yellow.300" | "colors.yellow.400" | "colors.yellow.500" | "colors.yellow.600" | "colors.yellow.700" | "colors.yellow.800" | "colors.yellow.900" | "colors.orange.50" | "colors.orange.100" | "colors.orange.200" | "colors.orange.300" | "colors.orange.400" | "colors.orange.500" | "colors.orange.600" | "colors.orange.700" | "colors.orange.800" | "colors.orange.900" | "colors.red.50" | "colors.red.100" | "colors.red.200" | "colors.red.300" | "colors.red.400" | "colors.red.500" | "colors.red.600" | "colors.red.700" | "colors.red.800" | "colors.red.900" | "colors.gray.50" | "colors.gray.100" | "colors.gray.200" | "colors.gray.300" | "colors.gray.400" | "colors.gray.500" | "colors.gray.600" | "colors.gray.700" | "colors.gray.800" | "colors.gray.900" | "colors.slate.50" | "colors.slate.100" | "colors.slate.200" | "colors.slate.300" | "colors.slate.400" | "colors.slate.500" | "colors.slate.600" | "colors.slate.700" | "colors.slate.800" | "colors.slate.900" | "colors.neutral.50" | "colors.neutral.100" | "colors.neutral.200" | "colors.neutral.300" | "colors.neutral.400" | "colors.neutral.500" | "colors.neutral.600" | "colors.neutral.700" | "colors.neutral.800" | "colors.neutral.900" | "colors.neutral.950" | "assets.check" | "breakpoints.sm" | "breakpoints.md" | "breakpoints.lg" | "breakpoints.xl" | "breakpoints.2xl" | "shadows.inset" | "colors.text" | "colors.bg" | "colors.card" | "colors.border" | "spacing.-1" | "spacing.-2" | "spacing.-3" | "spacing.-4" | "spacing.-5" | "spacing.-6" | "spacing.-7" | "spacing.-8" | "spacing.-9" | "spacing.-10" | "spacing.-11" | "spacing.-12" | "spacing.-14" | "spacing.-16" | "spacing.-20" | "spacing.-24" | "spacing.-28" | "spacing.-32" | "spacing.-36" | "spacing.-40" | "spacing.-44" | "spacing.-48" | "spacing.-52" | "spacing.-56" | "spacing.-60" | "spacing.-64" | "spacing.-72" | "spacing.-80" | "spacing.-96" | "spacing.-0.5" | "spacing.-1.5" | "spacing.-2.5" | "spacing.-3.5" | "colors.colorPalette.50" | "colors.colorPalette.100" | "colors.colorPalette.200" | "colors.colorPalette.300" | "colors.colorPalette.400" | "colors.colorPalette.500" | "colors.colorPalette.600" | "colors.colorPalette.700" | "colors.colorPalette.800" | "colors.colorPalette.900" | "colors.colorPalette.950"
2
3
 
3
4
  export type ColorPalette = "rose" | "pink" | "fuchsia" | "purple" | "indigo" | "blue" | "sky" | "cyan" | "teal" | "green" | "lime" | "yellow" | "orange" | "red" | "gray" | "slate" | "neutral"
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { CompositionStyleObject } from './system-types'
2
3
 
3
4
  type Recursive<T> = {
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { AnySelector, Selectors } from './selectors'
2
3
 
3
4
  export type Conditions = {
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  export {};
2
3
 
3
4
  export type PropertyValue<TValue> = TValue extends Array<infer AValue>
@@ -1,8 +1,9 @@
1
- import { RecipeVariantRecord, RecipeConfig } from './recipe'
2
- import { Parts } from './parts'
3
- import { PatternConfig } from './pattern'
4
- import { GlobalStyleObject, SystemStyleObject } from './system-types'
5
- import { CompositionStyles } from './composition'
1
+ /* eslint-disable */
2
+ import type { RecipeVariantRecord, RecipeConfig } from './recipe'
3
+ import type { Parts } from './parts'
4
+ import type { PatternConfig } from './pattern'
5
+ import type { GlobalStyleObject, SystemStyleObject } from './system-types'
6
+ import type { CompositionStyles } from './composition'
6
7
 
7
8
  declare module '@pandacss/dev' {
8
9
  export function defineRecipe<V extends RecipeVariantRecord>(config: RecipeConfig<V>): RecipeConfig
@@ -1 +1,2 @@
1
+ /* eslint-disable */
1
2
  export type Pretty<T> = T extends infer U ? { [K in keyof U]: U[K] } : never
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import './global'
2
- export { ConditionalValue } from './conditions'
3
- export { GlobalStyleObject, JsxStyleProps, SystemStyleObject } from './system-types'
3
+ export type { ConditionalValue } from './conditions'
4
+ export type { GlobalStyleObject, JsxStyleProps, SystemStyleObject } from './system-types'
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { ComponentProps, ElementType } from 'react'
2
3
  import type { Assign, JsxStyleProps, JsxHTMLProps } from './system-types'
3
4
  import type { RecipeDefinition, RecipeSelection, RecipeVariantRecord } from './recipe'
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  export type Part = {
2
3
  selector: string
3
4
  }
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { CssProperty, SystemStyleObject } from './system-types'
2
3
  import type { TokenCategory } from '../tokens'
3
4
 
@@ -14,7 +15,11 @@ export type PatternHelpers = {
14
15
  map: (value: any, fn: (value: string) => string | undefined) => any
15
16
  }
16
17
 
17
- export type PatternConfig<T = PatternProperty> = {
18
+ type PatternProperties = Record<string, PatternProperty>
19
+
20
+ type Props<T> = Record<LiteralUnion<keyof T>, any>
21
+
22
+ export type PatternConfig<T extends PatternProperties = PatternProperties> = {
18
23
  /**
19
24
  * The description of the pattern. This will be used in the JSDoc comment.
20
25
  */
@@ -27,14 +32,11 @@ export type PatternConfig<T = PatternProperty> = {
27
32
  /**
28
33
  * The properties of the pattern.
29
34
  */
30
- properties: T extends Record<string, PatternProperty> ? T : Record<string, PatternProperty>
35
+ properties: T
31
36
  /**
32
37
  * The css object this pattern will generate.
33
38
  */
34
- transform?: (
35
- props: T extends Record<infer Keys, PatternProperty> ? Record<Keys, any> : Record<string, PatternProperty>,
36
- helpers: PatternHelpers,
37
- ) => SystemStyleObject
39
+ transform?: (props: Props<T>, helpers: PatternHelpers) => SystemStyleObject
38
40
  /**
39
41
  * The jsx element name this pattern will generate.
40
42
  */
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { ConditionalValue } from './conditions';
2
3
  import type { CssProperties } from './system-types'
3
4
  import type { Tokens } from '../tokens'
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { SystemStyleObject } from './system-types'
2
3
 
3
4
  type Pretty<T> = T extends infer U ? { [K in keyof U]: U[K] } : never
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { Pseudos } from './csstype'
2
3
 
3
4
  type AriaAttributes =
@@ -1,6 +1,7 @@
1
- import { ConditionalValue } from './conditions'
2
- import { PropertyValue } from './prop-type'
3
- import { Token } from '../tokens'
1
+ /* eslint-disable */
2
+ import type { ConditionalValue } from './conditions'
3
+ import type { PropertyValue } from './prop-type'
4
+ import type { Token } from '../tokens'
4
5
 
5
6
  export type CssVarProperties = {
6
7
  [key in `--${string}`]?: ConditionalValue<Token | (string & {}) | (number & {})>
@@ -1,3 +1,4 @@
1
+ /* eslint-disable */
1
2
  import type { ConditionalValue, Conditions, Nested } from './conditions'
2
3
  import type { PropertiesFallback } from './csstype'
3
4
  import type { SystemProperties, CssVarProperties } from './style-props'
@@ -1,8 +0,0 @@
1
- import type { FunctionComponent } from 'react'
2
- import type { AbsoluteCenterProperties } from '../patterns/absolute-center'
3
- import type { HTMLPandaProps } from '../types/jsx'
4
-
5
- export type AbsoluteCenterProps = AbsoluteCenterProperties & Omit<HTMLPandaProps<'div'>, keyof AbsoluteCenterProperties >
6
-
7
-
8
- export declare const AbsoluteCenter: FunctionComponent<AbsoluteCenterProps>
@@ -1,9 +0,0 @@
1
- import { createElement, forwardRef } from 'react'
2
- import { panda } from './factory.mjs'
3
- import { getAbsoluteCenterStyle } from '../patterns/absolute-center.mjs'
4
-
5
- export const AbsoluteCenter = forwardRef(function AbsoluteCenter(props, ref) {
6
- const { axis, ...restProps } = props
7
- const styleProps = getAbsoluteCenterStyle({ axis })
8
- return createElement(panda.div, { ref, ...styleProps, ...restProps })
9
- })
@@ -1,14 +0,0 @@
1
- import type { SystemStyleObject, ConditionalValue } from '../types'
2
- import type { PropertyValue } from '../types/prop-type'
3
- import type { Properties } from '../types/csstype'
4
- import type { Tokens } from '../tokens'
5
-
6
- export type AbsoluteCenterProperties = {
7
- axis?: ConditionalValue<"x" | "y" | "both">
8
- }
9
-
10
-
11
- type AbsoluteCenterOptions = AbsoluteCenterProperties & Omit<SystemStyleObject, keyof AbsoluteCenterProperties >
12
-
13
-
14
- export declare function absoluteCenter(options?: AbsoluteCenterOptions): string
@@ -1,23 +0,0 @@
1
- import { mapObject } from '../helpers.mjs'
2
- import { css } from '../css/index.mjs'
3
-
4
- const absoluteCenterConfig = {
5
- transform(props, { map }) {
6
- const { axis = 'both', ...rest } = props
7
- return {
8
- position: 'absolute',
9
- insetBlockStart: map(axis, (v) => (v === 'x' ? 'auto' : '50%')),
10
- insetInlineStart: map(axis, (v) => (v === 'y' ? 'auto' : '50%')),
11
- transform: map(axis, (v) =>
12
- v === 'both' ? 'translate(-50%, -50%)' : v === 'x' ? 'translateX(-50%)' : 'translateY(-50%)',
13
- ),
14
- maxWidth: '100%',
15
- maxHeight: '100%',
16
- ...rest,
17
- }
18
- },
19
- }
20
-
21
- export const getAbsoluteCenterStyle = (styles = {}) => absoluteCenterConfig.transform(styles, { map: mapObject })
22
-
23
- export const absoluteCenter = (styles) => css(getAbsoluteCenterStyle(styles))