@pandacss/types 0.0.0-dev-20240315002504 → 0.0.0-dev-20240315003802

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 (2) hide show
  1. package/dist/config.d.ts +51 -1
  2. package/package.json +2 -2
package/dist/config.d.ts CHANGED
@@ -2,7 +2,7 @@ import type { TSConfig } from 'pkg-types'
2
2
  import type { Conditions, ExtendableConditions } from './conditions'
3
3
  import type { PandaHooks } from './hooks'
4
4
  import type { PatternConfig } from './pattern'
5
- import type { Keys, PathIn, RequiredBy } from './shared'
5
+ import type { Keys, LiteralUnion, PathIn, RequiredBy } from './shared'
6
6
  import type { StaticCssOptions } from './static-css'
7
7
  import type { ExtendableGlobalStyleObject, GlobalStyleObject } from './system-types'
8
8
  import type { ExtendableTheme, Theme } from './theme'
@@ -68,6 +68,10 @@ export interface PresetCore {
68
68
  * Common styling or layout patterns for your project.
69
69
  */
70
70
  patterns: Record<string, PatternConfig>
71
+ /**
72
+ * The css variables for your project.
73
+ */
74
+ globalVars: GlobalVarsDefinition
71
75
  }
72
76
 
73
77
  interface ExtendablePatterns {
@@ -79,6 +83,48 @@ interface ExtendableStaticCssOptions extends StaticCssOptions {
79
83
  extend?: StaticCssOptions | undefined
80
84
  }
81
85
 
86
+ export type CssPropertySyntax =
87
+ | '<length>'
88
+ | '<number>'
89
+ | '<percentage>'
90
+ | '<length-percentage>'
91
+ | '<color>'
92
+ | '<image>'
93
+ | '<url>'
94
+ | '<integer>'
95
+ | '<angle>'
96
+ | '<time>'
97
+ | '<resolution>'
98
+ | '<transform-function>'
99
+ | '<length> | <percentage>'
100
+
101
+ export interface CssPropertyDefinition {
102
+ /**
103
+ * Controls whether the custom property registration specified by @property inherits by default.
104
+ * @see https://developer.mozilla.org/en-US/docs/Web/CSS/@property/inherits
105
+ */
106
+ inherits: boolean
107
+ /**
108
+ * Sets the initial value for the property.
109
+ * @see https://developer.mozilla.org/en-US/docs/Web/CSS/@property/initial-value
110
+ */
111
+ initialValue: string
112
+ /**
113
+ * Describes the allowable syntax for the property.
114
+ * @see https://developer.mozilla.org/en-US/docs/Web/CSS/@property/syntax
115
+ */
116
+ syntax: LiteralUnion<CssPropertySyntax>
117
+ }
118
+
119
+ export interface GlobalVarsDefinition {
120
+ [key: string]: string | CssPropertyDefinition
121
+ }
122
+
123
+ interface ExtendableGlobalVars {
124
+ [key: string]: string | CssPropertyDefinition | ExtendableGlobalVars | undefined
125
+ extend?: ExtendableGlobalVars
126
+ }
127
+
82
128
  export interface ExtendableOptions {
83
129
  /**
84
130
  * The css selectors or media queries shortcuts.
@@ -105,6 +151,10 @@ export interface ExtendableOptions {
105
151
  * Common styling or layout patterns for your project.
106
152
  */
107
153
  patterns?: ExtendablePatterns
154
+ /**
155
+ * The css variables for your project.
156
+ */
157
+ globalVars?: ExtendableGlobalVars
108
158
  }
109
159
 
110
160
  export interface ImportMapInput {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pandacss/types",
3
- "version": "0.0.0-dev-20240315002504",
3
+ "version": "0.0.0-dev-20240315003802",
4
4
  "description": "The types for css panda",
5
5
  "main": "dist/index.d.ts",
6
6
  "author": "Segun Adebayo <joseshegs@gmail.com>",
@@ -30,7 +30,7 @@
30
30
  "microdiff": "1.3.2",
31
31
  "ncp": "2.0.0",
32
32
  "pkg-types": "1.0.3",
33
- "@pandacss/extractor": "0.0.0-dev-20240315002504"
33
+ "@pandacss/extractor": "0.0.0-dev-20240315003802"
34
34
  },
35
35
  "scripts": {
36
36
  "dev": "tsx scripts/watch.ts",