@webmate-studio/builder 0.2.114 → 0.2.116

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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webmate-studio/builder",
3
- "version": "0.2.114",
3
+ "version": "0.2.116",
4
4
  "type": "module",
5
5
  "description": "Webmate Studio Component Builder",
6
6
  "keywords": [
@@ -24,6 +24,8 @@
24
24
  "./build-service.js": "./build-service.js",
25
25
  "./src/css-deduplicator.js": "./src/css-deduplicator.js",
26
26
  "./src/design-tokens.js": "./src/design-tokens.js",
27
+ "./src/template-processor.js": "./src/template-processor.js",
28
+ "./src/markdown.js": "./src/markdown.js",
27
29
  "./dist/motion-runtime.min.js": "./dist/motion-runtime.min.js"
28
30
  },
29
31
  "bin": {
@@ -54,7 +54,12 @@ function generateSemanticColorUtilities(tokens) {
54
54
  'textAccentMuted': 'text-accent-muted',
55
55
  'borderAccentBase': 'border-accent-default',
56
56
  'borderAccentSubtle': 'border-accent-subtle',
57
- 'borderAccentMuted': 'border-accent-muted'
57
+ 'borderAccentMuted': 'border-accent-muted',
58
+
59
+ // Text-on-background colors
60
+ 'textOnPrimary': 'text-on-primary',
61
+ 'textOnSecondary': 'text-on-secondary',
62
+ 'textOnAccent': 'text-on-accent'
58
63
  };
59
64
 
60
65
  // Collect unique class names (deduplicate)
@@ -242,7 +247,12 @@ export const defaultDesignTokens = {
242
247
  // Border Colors (Accent)
243
248
  borderAccentBase: '#8b5cf6', // violet-500
244
249
  borderAccentSubtle: '#a78bfa', // violet-400
245
- borderAccentMuted: '#c4b5fd' // violet-300
250
+ borderAccentMuted: '#c4b5fd', // violet-300
251
+
252
+ // Text-on-Background Colors (for text on colored backgrounds)
253
+ textOnPrimary: '#ffffff', // Text on bg-primary
254
+ textOnSecondary: '#ffffff', // Text on bg-secondary
255
+ textOnAccent: '#ffffff' // Text on bg-accent
246
256
  },
247
257
 
248
258
  typography: {
@@ -671,6 +681,11 @@ export function generateTailwindV4Theme(tokens) {
671
681
  if (tokens.colors.borderSubtle) lines.push(` --color-border-subtle: ${tokens.colors.borderSubtle};`);
672
682
  if (tokens.colors.borderMuted) lines.push(` --color-border-muted: ${tokens.colors.borderMuted};`);
673
683
 
684
+ // Text-on-background colors
685
+ if (tokens.colors.textOnPrimary) lines.push(` --color-text-on-primary: ${tokens.colors.textOnPrimary};`);
686
+ if (tokens.colors.textOnSecondary) lines.push(` --color-text-on-secondary: ${tokens.colors.textOnSecondary};`);
687
+ if (tokens.colors.textOnAccent) lines.push(` --color-text-on-accent: ${tokens.colors.textOnAccent};`);
688
+
674
689
  // Basic colors
675
690
  if (tokens.colors.white) lines.push(` --color-white: ${tokens.colors.white};`);
676
691
  if (tokens.colors.black) lines.push(` --color-black: ${tokens.colors.black};`);
package/src/safe-html.js CHANGED
@@ -24,6 +24,10 @@ class SafeHtml {
24
24
  valueOf() {
25
25
  return this.html;
26
26
  }
27
+
28
+ toJSON() {
29
+ return this.html;
30
+ }
27
31
  }
28
32
 
29
33
  export { SafeHtml };