brand-intent 0.4.4 → 0.4.5
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 +1 -1
- package/parser/purposeParser.ts +4 -0
package/package.json
CHANGED
package/parser/purposeParser.ts
CHANGED
|
@@ -63,6 +63,8 @@ export interface ParsedPurposeSlot {
|
|
|
63
63
|
itemGap?: number;
|
|
64
64
|
/** List layout direction: 'vertical' (default) or 'horizontal'. */
|
|
65
65
|
listDirection?: 'vertical' | 'horizontal';
|
|
66
|
+
/** When true, this slot is editable by the user in consume mode. Default: false. */
|
|
67
|
+
editable?: boolean;
|
|
66
68
|
typography: {
|
|
67
69
|
fontFamily: string;
|
|
68
70
|
fontWeight: number;
|
|
@@ -526,6 +528,8 @@ export function parsePurposeFile(content: string, fileName: string): ParsedPurpo
|
|
|
526
528
|
currentSlot.colorRef = prop.slice(6).trim();
|
|
527
529
|
continue;
|
|
528
530
|
}
|
|
531
|
+
if (prop === 'editable' || prop === 'editable: true' || prop === 'editable:true') { currentSlot.editable = true; continue; }
|
|
532
|
+
if (prop === 'editable: false' || prop === 'editable:false') { currentSlot.editable = false; continue; }
|
|
529
533
|
if (prop.startsWith('font:')) {
|
|
530
534
|
// "Die Grotesk 800" → family="Die Grotesk", weight=800 (legacy direct path)
|
|
531
535
|
const value = prop.slice(5).trim();
|