@pikacss/core 0.0.30 → 0.0.31

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/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
- "version": "0.0.30",
7
+ "version": "0.0.31",
8
8
  "author": "DevilTea <ch19980814@gmail.com>",
9
9
  "license": "MIT",
10
10
  "repository": {
@@ -35,7 +35,7 @@
35
35
  },
36
36
  "main": "dist/index.cjs",
37
37
  "module": "dist/index.mjs",
38
- "types": "dist/index.d.ts",
38
+ "types": "dist/index.d.mts",
39
39
  "files": [
40
40
  "dist"
41
41
  ],
@@ -43,8 +43,7 @@
43
43
  "csstype": "^3.1.3"
44
44
  },
45
45
  "scripts": {
46
- "build": "unbuild",
47
- "stub": "unbuild --stub",
46
+ "build": "tsdown",
48
47
  "typecheck": "pnpm typecheck:package && pnpm typecheck:test",
49
48
  "typecheck:package": "tsc --project ./tsconfig.package.json --noEmit",
50
49
  "typecheck:test": "tsc --project ./tsconfig.tests.json --noEmit",
package/dist/index.d.ts DELETED
@@ -1,539 +0,0 @@
1
- import * as _pikacss_core from '@pikacss/core';
2
- import * as CSS from 'csstype';
3
-
4
- interface ImportantConfig {
5
- default?: boolean;
6
- }
7
- declare module '@pikacss/core' {
8
- interface EngineConfig {
9
- important?: ImportantConfig;
10
- }
11
- }
12
-
13
- interface Progress {
14
- from?: ResolvedProperties;
15
- to?: ResolvedProperties;
16
- [K: `${number}%`]: ResolvedProperties;
17
- }
18
- type Keyframes = string | [name: string, frames?: Progress, autocomplete?: string[], pruneUnused?: boolean] | {
19
- name: string;
20
- frames?: Progress;
21
- autocomplete?: string[];
22
- pruneUnused?: boolean;
23
- };
24
- interface KeyframesConfig {
25
- /**
26
- * Define CSS @keyframes animations with support for frame definitions
27
- * and autocomplete suggestions.
28
- *
29
- * @default []
30
- * @example
31
- * ```ts
32
- * {
33
- * keyframes: [
34
- * // Basic animation
35
- * ['fade', {
36
- * from: { opacity: 0 },
37
- * to: { opacity: 1 }
38
- * }],
39
- * // With autocomplete suggestions
40
- * ['slide', {
41
- * from: { transform: 'translateX(-100%)' },
42
- * to: { transform: 'translateX(0)' }
43
- * }, ['slide 0.3s ease']]
44
- * ]
45
- * }
46
- * ```
47
- */
48
- keyframes: Keyframes[];
49
- /**
50
- * Whether to prune unused keyframes from the final CSS.
51
- *
52
- * @default true
53
- */
54
- pruneUnused?: boolean;
55
- }
56
- declare module '@pikacss/core' {
57
- interface EngineConfig {
58
- keyframes?: KeyframesConfig;
59
- }
60
- interface Engine {
61
- keyframes: {
62
- store: Map<string, ResolvedKeyframesConfig>;
63
- add: (...list: Keyframes[]) => void;
64
- };
65
- }
66
- }
67
- interface ResolvedKeyframesConfig {
68
- name: string;
69
- frames: Progress | Nullish;
70
- pruneUnused: boolean;
71
- autocomplete: string[];
72
- }
73
-
74
- interface ResolvedResult<T> {
75
- value: T;
76
- }
77
- interface StaticRule<T> {
78
- key: string;
79
- string: string;
80
- resolved: T;
81
- }
82
- interface DynamicRule<T> {
83
- key: string;
84
- stringPattern: RegExp;
85
- createResolved: (matched: RegExpMatchArray) => Awaitable<T>;
86
- }
87
- declare abstract class AbstractResolver<T> {
88
- protected _resolvedResultsMap: Map<string, ResolvedResult<T>>;
89
- staticRulesMap: Map<string, StaticRule<T>>;
90
- dynamicRulesMap: Map<string, DynamicRule<T>>;
91
- onResolved: (string: string, type: 'static' | 'dynamic', result: ResolvedResult<T>) => void;
92
- get staticRules(): StaticRule<T>[];
93
- get dynamicRules(): DynamicRule<T>[];
94
- addStaticRule(rule: StaticRule<T>): this;
95
- removeStaticRule(key: string): this;
96
- addDynamicRule(rule: DynamicRule<T>): this;
97
- removeDynamicRule(key: string): this;
98
- _resolve(string: string): Promise<ResolvedResult<T> | Nullish>;
99
- _setResolvedResult(string: string, resolved: T): void;
100
- }
101
-
102
- type Selector = string | [selector: RegExp, value: (matched: RegExpMatchArray) => Awaitable<Arrayable<UnionString | ResolvedSelector>>, autocomplete?: Arrayable<string>] | [selector: string, value: Arrayable<UnionString | ResolvedSelector>] | {
103
- selector: RegExp;
104
- value: (matched: RegExpMatchArray) => Awaitable<Arrayable<UnionString | ResolvedSelector>>;
105
- autocomplete?: Arrayable<string>;
106
- } | {
107
- selector: string;
108
- value: Arrayable<UnionString | ResolvedSelector>;
109
- };
110
- interface SelectorsConfig {
111
- /**
112
- * Define custom selectors with support for dynamic and static selectors.
113
- *
114
- * @default []
115
- * @example
116
- * ```ts
117
- * {
118
- * selectors: [
119
- * // Static selector
120
- * ['hover', '$:hover'],
121
- * // Dynamic selector
122
- * [/^screen-(\d+)$/, m => `@media (min-width: ${m[1]}px)`,
123
- * ['screen-768', 'screen-1024']], // Autocomplete suggestions
124
- * ]
125
- * }
126
- * ```
127
- */
128
- selectors: Selector[];
129
- }
130
- declare module '@pikacss/core' {
131
- interface EngineConfig {
132
- selectors?: SelectorsConfig;
133
- }
134
- interface Engine {
135
- selectors: {
136
- resolver: SelectorResolver;
137
- add: (...list: Selector[]) => void;
138
- };
139
- }
140
- }
141
- declare class SelectorResolver extends AbstractResolver<string[]> {
142
- resolve(selector: string): Promise<string[]>;
143
- }
144
-
145
- type Shortcut = string | [shortcut: RegExp, value: (matched: RegExpMatchArray) => Awaitable<Arrayable<ResolvedStyleItem>>, autocomplete?: Arrayable<string>] | {
146
- shortcut: RegExp;
147
- value: (matched: RegExpMatchArray) => Awaitable<Arrayable<ResolvedStyleItem>>;
148
- autocomplete?: Arrayable<string>;
149
- } | [shortcut: string, value: Arrayable<ResolvedStyleItem>] | {
150
- shortcut: string;
151
- value: Arrayable<ResolvedStyleItem>;
152
- };
153
- interface ShortcutsConfig {
154
- /**
155
- * Define style shortcuts for reusable style combinations.
156
- *
157
- * @default []
158
- * @example
159
- * ```ts
160
- * {
161
- * shortcuts: [
162
- * // Static shortcut
163
- * ['flex-center', {
164
- * display: 'flex',
165
- * alignItems: 'center',
166
- * justifyContent: 'center'
167
- * }],
168
- * // Dynamic shortcut
169
- * [/^m-(\d+)$/, m => ({ margin: `${m[1]}px` }),
170
- * ['m-4', 'm-8']] // Autocomplete suggestions
171
- * ]
172
- * }
173
- * ```
174
- */
175
- shortcuts: Shortcut[];
176
- }
177
- declare module '@pikacss/core' {
178
- interface EngineConfig {
179
- shortcuts?: ShortcutsConfig;
180
- }
181
- interface Engine {
182
- shortcuts: {
183
- resolver: ShortcutResolver;
184
- add: (...list: Shortcut[]) => void;
185
- };
186
- }
187
- }
188
- declare class ShortcutResolver extends AbstractResolver<StyleItem$1[]> {
189
- resolve(shortcut: string): Promise<StyleItem$1[]>;
190
- }
191
-
192
- type ResolvedCSSProperty = keyof ResolvedCSSProperties;
193
- type ResolvedCSSVarProperty = ResolvedCSSProperty extends infer T ? T extends `--${string}` ? T : never : never;
194
- interface VariableAutocomplete {
195
- /**
196
- * Specify the properties that the variable can be used as a value of.
197
- *
198
- * @default ['*']
199
- */
200
- asValueOf?: Arrayable<UnionString | '*' | '-' | ResolvedCSSProperty>;
201
- /**
202
- * Whether to add the variable as a CSS property.
203
- *
204
- * @default true
205
- */
206
- asProperty?: boolean;
207
- }
208
- interface VariableObject {
209
- value?: ResolvedCSSProperties[`--${string}`];
210
- autocomplete?: VariableAutocomplete;
211
- pruneUnused?: boolean;
212
- }
213
- type Variable = ResolvedCSSProperties[`--${string}`] | VariableObject;
214
- type VariablesDefinition = {
215
- [key in UnionString | ResolvedSelector | (`--${string}` & {}) | ResolvedCSSVarProperty]?: Variable | VariablesDefinition;
216
- };
217
- interface VariablesConfig {
218
- /**
219
- * Define CSS variables with support for static values and autocomplete configuration.
220
- *
221
- * @default {}
222
- * @example
223
- * ```ts
224
- * {
225
- * variables: {
226
- * // The variable with value "null" will not be included in the final CSS, but can be used in autocompletion.
227
- * '--external-var': null,
228
- *
229
- * '--color-bg': '#fff',
230
- * '--color-text': '#000',
231
- *
232
- * '[data-theme="dark"]': {
233
- * '--color-bg': '#000',
234
- * '--color-text': '#fff',
235
- * },
236
- * },
237
- * }
238
- * ```
239
- */
240
- variables: VariablesDefinition;
241
- /**
242
- * Whether to prune unused variables from the final CSS.
243
- *
244
- * @default true
245
- */
246
- pruneUnused?: boolean;
247
- /**
248
- * A list of CSS variables that should always be included in the final CSS, you can use this to prevent certain variables from being pruned.
249
- *
250
- * @default []
251
- * @example
252
- * ```ts
253
- * {
254
- * variables: {
255
- * safeList: ['--external-var', '--color-bg', '--color-text'],
256
- * },
257
- * }
258
- * ```
259
- */
260
- safeList?: ((`--${string}` & {}) | ResolvedCSSVarProperty)[];
261
- }
262
- declare module '@pikacss/core' {
263
- interface EngineConfig {
264
- variables?: VariablesConfig;
265
- }
266
- interface Engine {
267
- variables: {
268
- store: Map<string, ResolvedVariable[]>;
269
- add: (variables: VariablesDefinition) => void;
270
- };
271
- }
272
- }
273
- interface ResolvedVariable {
274
- name: string;
275
- value: PropertyValue;
276
- selector: string[];
277
- pruneUnused: boolean;
278
- autocomplete: {
279
- asValueOf: string[];
280
- asProperty: boolean;
281
- };
282
- }
283
-
284
- type Nullish = null | undefined;
285
- type UnionString = string & {};
286
- type UnionNumber = number & {};
287
- type Arrayable<T> = T | T[];
288
- type Awaitable<T> = T | Promise<T>;
289
- type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never;
290
- type IsEqual<X, Y> = (<T>() => T extends X ? 1 : 2) extends (<T>() => T extends Y ? 1 : 2) ? true : false;
291
- type IsNever<T> = [T] extends [never] ? true : false;
292
- type Simplify<T> = {
293
- [K in keyof T]: T[K];
294
- } & {};
295
- type ToKebab<T extends string> = T extends `${infer A}${infer B}` ? [A extends Uppercase<A> ? 1 : 0, A extends Lowercase<A> ? 1 : 0] extends [1, 0] ? `-${Lowercase<A>}${ToKebab<`${B}`>}` : `${A}${ToKebab<`${B}`>}` : T;
296
- type FromKebab<T extends string> = T extends `--${string}` ? T : T extends `-${infer A}${infer B}` ? `${Uppercase<A>}${FromKebab<`${B}`>}` : T extends `${infer A}${infer B}` ? `${A}${FromKebab<`${B}`>}` : T;
297
- type GetValue<Obj extends Record<string, any>, K extends string> = (IsEqual<Obj, object> | IsEqual<Obj, {}> | IsEqual<Obj[K], unknown>) extends false ? Obj[K] : never;
298
- type ResolveFrom<T, Key extends string, I, Fallback extends I> = Key extends keyof T ? T[Key] extends I ? T[Key] : Fallback : Fallback;
299
-
300
- interface ResolvedAutocompleteConfig {
301
- selectors: Set<string>;
302
- styleItemStrings: Set<string>;
303
- extraProperties: Set<string>;
304
- extraCssProperties: Set<string>;
305
- properties: Map<string, string[]>;
306
- cssProperties: Map<string, (string | number)[]>;
307
- }
308
- interface _Autocomplete {
309
- Selector: UnionString;
310
- StyleItemString: UnionString;
311
- ExtraProperty: UnionString;
312
- ExtraCssProperty: UnionString;
313
- PropertiesValue: Record<string, unknown>;
314
- CssPropertiesValue: Record<string, UnionString | UnionNumber>;
315
- }
316
- type DefineAutocomplete<A extends _Autocomplete> = A;
317
- type EmptyAutocomplete = DefineAutocomplete<{
318
- Selector: never;
319
- StyleItemString: never;
320
- ExtraProperty: never;
321
- ExtraCssProperty: never;
322
- PropertiesValue: never;
323
- CssPropertiesValue: never;
324
- }>;
325
-
326
- type DefineHooks<Hooks extends Record<string, [type: 'sync' | 'async', payload: any, returnValue?: any]>> = Hooks;
327
- type EngineHooksDefinition = DefineHooks<{
328
- configureRawConfig: ['async', config: EngineConfig];
329
- rawConfigConfigured: ['sync', config: EngineConfig, void];
330
- configureResolvedConfig: ['async', resolvedConfig: ResolvedEngineConfig];
331
- configureEngine: ['async', engine: Engine];
332
- transformSelectors: ['async', selectors: string[]];
333
- transformStyleItems: ['async', styleItems: ResolvedStyleItem[]];
334
- transformStyleDefinitions: ['async', styleDefinitions: ResolvedStyleDefinition[]];
335
- preflightUpdated: ['sync', void];
336
- atomicStyleAdded: ['sync', AtomicStyle];
337
- autocompleteConfigUpdated: ['sync', void];
338
- }>;
339
- type EnginePluginHooksOptions = {
340
- [K in keyof EngineHooksDefinition]?: EngineHooksDefinition[K][0] extends 'async' ? (...params: EngineHooksDefinition[K][1] extends void ? [] : [payload: EngineHooksDefinition[K][1]]) => Awaitable<EngineHooksDefinition[K][1] | void> : (...params: EngineHooksDefinition[K][1] extends void ? [] : [payload: EngineHooksDefinition[K][1]]) => EngineHooksDefinition[K][1] | void;
341
- };
342
- interface EnginePlugin extends EnginePluginHooksOptions {
343
- name: string;
344
- order?: 'pre' | 'post';
345
- }
346
- declare function defineEnginePlugin(plugin: EnginePlugin): EnginePlugin;
347
-
348
- interface PikaAugment {
349
- }
350
- type PropertyValue = string | number | [value: string | number, fallback: (string | number)[]] | Nullish;
351
- type Properties$1 = Record<string, PropertyValue>;
352
- interface StyleDefinition$1 {
353
- [K: string]: PropertyValue | StyleDefinition$1 | StyleItem$1[];
354
- }
355
- type StyleItem$1 = string | StyleDefinition$1;
356
- interface ExtractedStyleContent {
357
- selector: string[];
358
- property: string;
359
- value: string[] | Nullish;
360
- }
361
- interface StyleContent {
362
- selector: string[];
363
- property: string;
364
- value: string[];
365
- }
366
- interface AtomicStyle {
367
- id: string;
368
- content: StyleContent;
369
- }
370
- interface CSSStyleBlockBody {
371
- properties: {
372
- property: string;
373
- value: string;
374
- }[];
375
- children?: CSSStyleBlocks;
376
- }
377
- type CSSStyleBlocks = Map<string, CSSStyleBlockBody>;
378
-
379
- type ResolvedAutocomplete = ResolveFrom<PikaAugment, 'Autocomplete', _Autocomplete, EmptyAutocomplete>;
380
- type ResolvedSelector = ResolveFrom<PikaAugment, 'Selector', string, string>;
381
- type ResolvedProperties = ResolveFrom<PikaAugment, 'Properties', any, Properties$1>;
382
- type ResolvedCSSProperties = Omit<ResolvedProperties, ResolvedAutocomplete['ExtraProperty']>;
383
- type ResolvedStyleDefinition = ResolveFrom<PikaAugment, 'StyleDefinition', any, StyleDefinition$1>;
384
- type ResolvedStyleItem = ResolveFrom<PikaAugment, 'StyleItem', any, StyleItem$1>;
385
-
386
- type PreflightDefinition = {
387
- [selector in UnionString | ResolvedSelector]?: ResolvedCSSProperties | PreflightDefinition;
388
- };
389
- type PreflightFn = (engine: Engine, isFormatted: boolean) => Awaitable<string | PreflightDefinition>;
390
- /**
391
- * PreflightConfig can be a string or a function that returns a string.
392
- *
393
- * 1. A string is a static preflight style.
394
- * 2. A function is a dynamic preflight style that can use the engine instance to generate styles.
395
- */
396
- type Preflight = string | PreflightDefinition | PreflightFn;
397
-
398
- interface EngineConfig {
399
- /**
400
- * Register plugins to extend PikaCSS functionality.
401
- *
402
- * @example
403
- * ```ts
404
- * {
405
- * plugins: [
406
- * icons(), // Add icon support
407
- * customPlugin() // Custom plugin
408
- * ]
409
- * }
410
- * ```
411
- */
412
- plugins?: EnginePlugin[];
413
- /**
414
- * Set the prefix for generated atomic style id.
415
- *
416
- * @default ''
417
- * @example
418
- * ```ts
419
- * {
420
- * prefix: 'pika-' // Generated atomic id will be 'pika-xxx'
421
- * }
422
- * ```
423
- */
424
- prefix?: string;
425
- /**
426
- * Set the default selector format. '%' will be replaced with the atomic style id.
427
- *
428
- * @default '.%'
429
- * @example
430
- * ```ts
431
- * {
432
- * defaultSelector: '.%' // Use with class attribute: <div class="a b c">
433
- * // or
434
- * defaultSelector: '[data-pika~="%"]' // Use with attribute selector: <div data-pika="a b c">
435
- * }
436
- * ```
437
- */
438
- defaultSelector?: string;
439
- /**
440
- * Define global CSS styles that will be injected before atomic styles.
441
- * Can be used for CSS variables, global animations, base styles, etc.
442
- *
443
- * @default []
444
- * @example
445
- * ```ts
446
- * {
447
- * preflights: [
448
- * // Use CSS string directly
449
- * ':root { --color: blue }',
450
- * // Or use function to generate dynamically
451
- * (engine) => ':root { --theme: dark }'
452
- * ]
453
- * }
454
- * ```
455
- */
456
- preflights?: Preflight[];
457
- }
458
- interface ResolvedEngineConfig {
459
- rawConfig: EngineConfig;
460
- prefix: string;
461
- defaultSelector: string;
462
- plugins: EnginePlugin[];
463
- preflights: PreflightFn[];
464
- autocomplete: ResolvedAutocompleteConfig;
465
- }
466
-
467
- type ExtractFn = (styleDefinition: StyleDefinition$1) => Promise<ExtractedStyleContent[]>;
468
-
469
- declare function defineEngineConfig(config: EngineConfig): EngineConfig;
470
- declare function createEngine(config?: EngineConfig): Promise<Engine>;
471
- declare class Engine {
472
- config: ResolvedEngineConfig;
473
- pluginHooks: {
474
- configureRawConfig: (plugins: _pikacss_core.EnginePlugin[], payload: EngineConfig) => Promise<EngineConfig>;
475
- rawConfigConfigured: (plugins: _pikacss_core.EnginePlugin[], payload: EngineConfig) => void;
476
- configureResolvedConfig: (plugins: _pikacss_core.EnginePlugin[], payload: ResolvedEngineConfig) => Promise<ResolvedEngineConfig>;
477
- configureEngine: (plugins: _pikacss_core.EnginePlugin[], payload: Engine) => Promise<Engine>;
478
- transformSelectors: (plugins: _pikacss_core.EnginePlugin[], payload: string[]) => Promise<string[]>;
479
- transformStyleItems: (plugins: _pikacss_core.EnginePlugin[], payload: StyleItem$1[]) => Promise<StyleItem$1[]>;
480
- transformStyleDefinitions: (plugins: _pikacss_core.EnginePlugin[], payload: StyleDefinition$1[]) => Promise<StyleDefinition$1[]>;
481
- preflightUpdated: (plugins: _pikacss_core.EnginePlugin[]) => void;
482
- atomicStyleAdded: (plugins: _pikacss_core.EnginePlugin[], payload: AtomicStyle) => AtomicStyle;
483
- autocompleteConfigUpdated: (plugins: _pikacss_core.EnginePlugin[]) => void;
484
- };
485
- extract: ExtractFn;
486
- store: {
487
- atomicStyleIds: Map<string, string>;
488
- atomicStyles: Map<string, AtomicStyle>;
489
- };
490
- constructor(config: ResolvedEngineConfig);
491
- notifyPreflightUpdated(): void;
492
- notifyAtomicStyleAdded(atomicStyle: AtomicStyle): void;
493
- notifyAutocompleteConfigUpdated(): void;
494
- appendAutocompleteSelectors(...selectors: string[]): void;
495
- appendAutocompleteStyleItemStrings(...styleItemStrings: string[]): void;
496
- appendAutocompleteExtraProperties(...properties: string[]): void;
497
- appendAutocompleteExtraCssProperties(...properties: string[]): void;
498
- appendAutocompletePropertyValues(property: string, ...tsTypes: string[]): void;
499
- appendAutocompleteCssPropertyValues(property: string, ...values: (string | number)[]): void;
500
- addPreflight(preflight: Preflight): void;
501
- use(...itemList: StyleItem$1[]): Promise<string[]>;
502
- renderPreflights(isFormatted: boolean): Promise<string>;
503
- renderAtomicStyles(isFormatted: boolean, options?: {
504
- atomicStyleIds?: string[];
505
- isPreview?: boolean;
506
- }): Promise<string>;
507
- }
508
-
509
- declare function setWarnFn(fn: (...args: any[]) => void): void;
510
- declare function warn(...args: any[]): void;
511
- declare function appendAutocompleteSelectors(config: Pick<ResolvedEngineConfig, 'autocomplete'>, ...selectors: string[]): void;
512
- declare function appendAutocompleteStyleItemStrings(config: Pick<ResolvedEngineConfig, 'autocomplete'>, ...styleItemStrings: string[]): void;
513
- declare function appendAutocompleteExtraProperties(config: Pick<ResolvedEngineConfig, 'autocomplete'>, ...properties: string[]): void;
514
- declare function appendAutocompleteExtraCssProperties(config: Pick<ResolvedEngineConfig, 'autocomplete'>, ...properties: string[]): void;
515
- declare function appendAutocompletePropertyValues(config: Pick<ResolvedEngineConfig, 'autocomplete'>, property: string, ...tsTypes: string[]): void;
516
- declare function appendAutocompleteCssPropertyValues(config: Pick<ResolvedEngineConfig, 'autocomplete'>, property: string, ...values: (string | number)[]): void;
517
- declare function renderCSSStyleBlocks(blocks: CSSStyleBlocks, isFormatted: boolean, depth?: number): string;
518
-
519
- interface CSSVariables {
520
- [K: (`--${string}` & {})]: UnionString | UnionNumber;
521
- }
522
- interface CSSProperties extends CSS.Properties, CSS.PropertiesHyphen, CSSVariables {
523
- }
524
- type CSSProperty = keyof CSSProperties;
525
- type MakePropertyValue<T> = T | [value: T, fallback: T[]] | Nullish;
526
- type Properties = {
527
- [Key in keyof CSSProperties | ResolvedAutocomplete['ExtraCssProperty'] | ResolvedAutocomplete['ExtraProperty']]?: Key extends ResolvedAutocomplete['ExtraProperty'] ? GetValue<ResolvedAutocomplete['PropertiesValue'], Key> : MakePropertyValue<Exclude<UnionString | UnionNumber | GetValue<CSSProperties, Key> | GetValue<ResolvedAutocomplete['CssPropertiesValue'], ToKebab<Key>> | GetValue<ResolvedAutocomplete['CssPropertiesValue'], FromKebab<Key>> | GetValue<ResolvedAutocomplete['CssPropertiesValue'], '*'>, Nullish>>;
528
- };
529
- type CSSPseudos = `${'$'}${CSS.Pseudos}`;
530
- type CSSBlockAtRules = Exclude<CSS.AtRules, '@charset' | 'import' | '@namespace'>;
531
- type CSSSelectors = CSSBlockAtRules | CSSPseudos;
532
- type WrapWithSelector<T> = {
533
- [S in UnionString | ResolvedAutocomplete['Selector'] | CSSSelectors]?: T | StyleItem[];
534
- };
535
- type MakeStyleDefinition<MaxDepth extends number, Tuple extends any[] = []> = Tuple['length'] extends MaxDepth ? Tuple[number] : Tuple['length'] extends 0 ? MakeStyleDefinition<MaxDepth, [Properties]> : MakeStyleDefinition<MaxDepth, [...Tuple, WrapWithSelector<[0, ...Tuple][Tuple['length']]>]>;
536
- type StyleDefinition = MakeStyleDefinition<5>;
537
- type StyleItem = UnionString | ResolvedAutocomplete['StyleItemString'] | StyleDefinition;
538
-
539
- export { type Arrayable, type Awaitable, type CSSProperty, type CSSSelectors, type CSSStyleBlockBody, type CSSStyleBlocks, type DefineAutocomplete, Engine, type EngineConfig, type EnginePlugin, type FromKebab, type GetValue, type IsEqual, type IsNever, type Nullish, type PikaAugment, type Properties, type ResolveFrom, type Simplify, type StyleDefinition, type StyleItem, type ToKebab, type UnionNumber, type UnionString, type UnionToIntersection, appendAutocompleteCssPropertyValues, appendAutocompleteExtraCssProperties, appendAutocompleteExtraProperties, appendAutocompletePropertyValues, appendAutocompleteSelectors, appendAutocompleteStyleItemStrings, createEngine, defineEngineConfig, defineEnginePlugin, renderCSSStyleBlocks, setWarnFn, warn };