@jasonshimmy/custom-elements-runtime 1.0.7 → 1.0.9

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.
@@ -1,12 +1,8 @@
1
+ /**
2
+ * Optimized JIT CSS implementation with reduced bloat and enhanced utilities
3
+ */
1
4
  /**
2
5
  * CSS template literal
3
- *
4
- * This doesn't sanitize CSS values.
5
- * Runtime does that for us.
6
- *
7
- * @param strings
8
- * @param values
9
- * @returns
10
6
  */
11
7
  export declare function css(strings: TemplateStringsArray, ...values: unknown[]): string;
12
8
  /**
@@ -15,23 +11,19 @@ export declare function css(strings: TemplateStringsArray, ...values: unknown[])
15
11
  export declare function minifyCSS(css: string): string;
16
12
  export declare function getBaseResetSheet(): CSSStyleSheet;
17
13
  export declare function sanitizeCSS(css: string): string;
18
- /**
19
- * Minimal Shadow DOM reset
20
- */
21
14
  export declare const baseReset: string;
22
- /**
23
- * JIT CSS implementation
24
- */
25
15
  type CSSMap = Record<string, string>;
26
16
  type SelectorVariantMap = Record<string, (selector: string, body: string) => string>;
27
17
  type MediaVariantMap = Record<string, string>;
28
18
  export declare const colors: Record<string, Record<string, string>>;
29
19
  export declare const spacing = "0.25rem";
30
- export declare const utilityMap: CSSMap;
31
20
  export declare const spacingProps: Record<string, string[]>;
21
+ export declare const utilityMap: CSSMap;
32
22
  export declare const selectorVariants: SelectorVariantMap;
33
23
  export declare const mediaVariants: MediaVariantMap;
24
+ export declare const containerVariants: MediaVariantMap;
34
25
  export declare const responsiveOrder: string[];
26
+ export declare const containerOrder: string[];
35
27
  export declare function parseSpacing(className: string): string | null;
36
28
  export declare function hexToRgb(hex: string): string;
37
29
  export declare function parseColorClass(className: string): string | null;
@@ -41,27 +33,14 @@ export declare function parseOpacityModifier(className: string): {
41
33
  };
42
34
  export declare function parseColorWithOpacity(className: string): string | null;
43
35
  /**
44
- * Parse opacity utility class (e.g., opacity-25)
45
- * Returns CSS rule string or null if not valid
36
+ * Parse gradient color stop utilities like from-red-500, to-blue-600, via-green-400
46
37
  */
38
+ export declare function parseGradientColorStop(className: string): string | null;
47
39
  export declare function parseOpacity(className: string): string | null;
48
- /**
49
- * Arbitrary value parser — supports:
50
- * - prop-[value]
51
- */
52
40
  export declare function parseArbitrary(className: string): string | null;
53
- /**
54
- * Parse arbitrary variant from class name.
55
- * Supports [attr=value]:utility or foo-[bar]:utility
56
- */
57
41
  export declare function parseArbitraryVariant(token: string): string | null;
58
42
  export declare function escapeClassName(name: string): string;
59
43
  export declare function extractClassesFromHTML(html: string): string[];
60
- /**
61
- * JIT CSS generation with throttling and memoization.
62
- * Only regenerates CSS if HTML changes and enough time has passed.
63
- * Caches results for repeated HTML inputs.
64
- */
65
44
  export declare const jitCssCache: Map<string, {
66
45
  css: string;
67
46
  timestamp: number;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@jasonshimmy/custom-elements-runtime",
3
3
  "description": "A powerful, modern, and lightweight runtime for creating reactive web components with TypeScript",
4
- "version": "1.0.7",
4
+ "version": "1.0.9",
5
5
  "type": "module",
6
6
  "keywords": [
7
7
  "web-components",