@bamboocss/types 1.13.2 → 1.15.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 CHANGED
@@ -20,30 +20,6 @@ export type CascadeLayer = 'reset' | 'base' | 'tokens' | 'recipes' | 'utilities'
20
20
 
21
21
  export type CascadeLayers = Record<CascadeLayer, string>
22
22
 
23
- export interface StudioOptions {
24
- /**
25
- * Used to customize the design system studio
26
- * @default { title: 'Bamboo', logo: '🎋' }
27
- */
28
- studio?: {
29
- /**
30
- * The output directory for the design system studio when the build command is run.
31
- */
32
- outdir?: string
33
- /**
34
- * The logo url for the design system studio.
35
- */
36
- logo?: string
37
- /**
38
- * Used to inject custom html into the head or body of the studio
39
- */
40
- inject?: {
41
- head?: string
42
- body?: string
43
- }
44
- }
45
- }
46
-
47
23
  export interface Patterns {
48
24
  [pattern: string]: PatternConfig
49
25
  }
@@ -495,7 +471,6 @@ export interface PluginsOptions {
495
471
 
496
472
  export interface Config
497
473
  extends
498
- StudioOptions,
499
474
  ExtendableOptions,
500
475
  CssgenOptions,
501
476
  CodegenOptions,
package/dist/parser.d.ts CHANGED
@@ -14,6 +14,7 @@ export interface ParserResultInterface {
14
14
  cva: Set<ResultItem>
15
15
  sva: Set<ResultItem>
16
16
  token: Set<ResultItem>
17
+ viewTransition: Set<ResultItem>
17
18
  recipe: Map<string, Set<ResultItem>>
18
19
  pattern: Map<string, Set<ResultItem>>
19
20
  filePath: string | undefined
@@ -24,6 +25,7 @@ export interface ParserResultInterface {
24
25
  setCva: (result: ResultItem) => void
25
26
  setSva: (result: ResultItem) => void
26
27
  setToken: (result: ResultItem) => void
28
+ setViewTransition: (result: ResultItem) => void
27
29
  setJsx: (result: ResultItem) => void
28
30
  setPattern: (name: string, result: ResultItem) => void
29
31
  setRecipe: (name: string, result: ResultItem) => void
@@ -39,5 +41,9 @@ export interface EncoderJson {
39
41
  grouped?: {
40
42
  [groupId: string]: string[]
41
43
  }
44
+ /** Bag class -> the `::view-transition-*` slot styles behind it. */
45
+ viewTransitions?: {
46
+ [className: string]: Record<string, any>
47
+ }
42
48
  }
43
49
  }
@@ -39,3 +39,15 @@ export interface RecipeBaseResult extends GroupedResult {
39
39
  export interface GroupedStyleResultDetails extends Pick<AtomicStyleResult, 'hash' | 'entry' | 'conditions'> {
40
40
  result: StyleResultObject
41
41
  }
42
+
43
+ export interface ViewTransitionResult {
44
+ className: string
45
+ /**
46
+ * Selector -> authored style object, the shape `globalCss` takes.
47
+ *
48
+ * Unlike every other result here this is *not* transformed yet: the bodies target
49
+ * `::view-transition-*` pseudo-elements, so they are serialized whole at emit rather
50
+ * than atomized into classes.
51
+ */
52
+ styles: StyleResultObject
53
+ }
@@ -89,6 +89,21 @@ export type NestedCssProperties = Nested<CssProperties>
89
89
 
90
90
  export type SystemStyleObject = Nested<(SystemProperties | GenericProperties) & CssVarProperties>
91
91
 
92
+ /**
93
+ * The four `::view-transition-*` pseudo-elements a `viewTransition()` bag can style.
94
+ *
95
+ * `imagePair` is camelCase here and emitted as `::view-transition-image-pair`, matching
96
+ * how every other property in a style object is authored.
97
+ */
98
+ export interface ViewTransitionStyleObject {
99
+ group?: SystemStyleObject
100
+ imagePair?: SystemStyleObject
101
+ old?: SystemStyleObject
102
+ new?: SystemStyleObject
103
+ }
104
+
105
+ export type ViewTransitionFn = (options: ViewTransitionStyleObject) => string
106
+
92
107
  export interface GlobalStyleObject {
93
108
  [selector: string]: SystemStyleObject
94
109
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bamboocss/types",
3
- "version": "1.13.2",
3
+ "version": "1.15.0",
4
4
  "description": "The types for css bamboo",
5
5
  "homepage": "https://bamboocss.com",
6
6
  "license": "MIT",
@@ -32,7 +32,7 @@
32
32
  "ncp": "2.0.0",
33
33
  "pkg-types": "2.3.0",
34
34
  "ts-morph": "28.0.0",
35
- "@bamboocss/extractor": "1.13.2"
35
+ "@bamboocss/extractor": "1.15.0"
36
36
  },
37
37
  "scripts": {
38
38
  "dev": "tsx scripts/watch.ts",