fix: correct drakonwidget theme field names for proper light theme rendering
This commit is contained in:
1 parent
c88b55d470
commit
35ebd2c687
1 file changed
+26
-52
+26
-52
@@ -1282,60 +1282,34 @@ var drakonDiagram = {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// Theme customization for light theme
|
// Theme customization for light theme (correct drakonwidget field names)
|
||||||
var drakonTheme = {
|
var drakonTheme = {
|
||||||
name: "Light Theme",
|
background: '#ffffff',
|
||||||
id: "drakon-theme",
|
iconBack: '#ffffff',
|
||||||
colors: {
|
lines: '#9ca3af',
|
||||||
// Background
|
iconBorder: '#d1d5db',
|
||||||
backgroundColor: "#ffffff",
|
backText: '#111827',
|
||||||
// Main flow line (skewer)
|
color: '#111827',
|
||||||
mainFlowColor: "#9ca3af",
|
internalLine: '#111827',
|
||||||
// Side flow lines
|
|
||||||
sideFlowColor: "#9ca3af",
|
|
||||||
// Arrow colors
|
|
||||||
yesArrowColor: "#16a34a",
|
|
||||||
noArrowColor: "#ef4444",
|
|
||||||
// Node colors
|
|
||||||
actionFillColor: "#ffffff",
|
|
||||||
actionStrokeColor: "#d1d5db",
|
|
||||||
questionFillColor: "#ffffff",
|
|
||||||
questionStrokeColor: "#f59e0b",
|
|
||||||
branchFillColor: "#ffffff",
|
|
||||||
branchStrokeColor: "#16a34a",
|
|
||||||
endFillColor: "#f9fafb",
|
|
||||||
endStrokeColor: "#9ca3af",
|
|
||||||
// Text colors
|
|
||||||
actionTextColor: "#111827",
|
|
||||||
questionTextColor: "#92400e",
|
|
||||||
branchTextColor: "#15803d",
|
|
||||||
endTextColor: "#6b7280",
|
|
||||||
// Label colors
|
|
||||||
yesLabelColor: "#16a34a",
|
|
||||||
noLabelColor: "#ef4444",
|
|
||||||
yesLabelBgColor: "#dcfce7",
|
|
||||||
noLabelBgColor: "#fee2e2",
|
|
||||||
// Selection
|
|
||||||
selectedFillColor: "#fef3c7",
|
|
||||||
selectedStrokeColor: "#f59e0b",
|
|
||||||
// Common fate
|
|
||||||
commonFateColor: "#6b7280",
|
|
||||||
// Comment
|
|
||||||
commentFillColor: "#ffffff",
|
|
||||||
commentStrokeColor: "#d1d5db",
|
|
||||||
commentTextColor: "#4b5563",
|
|
||||||
},
|
|
||||||
// Icon sizes
|
|
||||||
action: { width: 200, height: 40 },
|
|
||||||
question: { width: 160, height: 60 },
|
|
||||||
branch: { width: 40, height: 24 },
|
|
||||||
end: { width: 160, height: 40 },
|
|
||||||
// Font
|
|
||||||
fontSize: 13,
|
|
||||||
fontFace: "Inter, sans-serif",
|
|
||||||
// Line widths
|
|
||||||
lineWidth: 1.5,
|
lineWidth: 1.5,
|
||||||
skewerLineWidth: 2,
|
borderWidth: 1.5,
|
||||||
|
shadowColor: '',
|
||||||
|
shadowBlur: 0,
|
||||||
|
shadowOffsetX: 0,
|
||||||
|
shadowOffsetY: 0,
|
||||||
|
guides: '#16a34a',
|
||||||
|
highlight: '#fef3c7',
|
||||||
|
candyFill: '#dcfce7',
|
||||||
|
candyBorder: '#16a34a',
|
||||||
|
valFill: '#f59e0b',
|
||||||
|
valBorder: '#92400e',
|
||||||
|
scrollBar: '#e5e7eb',
|
||||||
|
scrollBarHover: '#d1d5db',
|
||||||
|
commentBack: '#f3f4f6',
|
||||||
|
icons: {
|
||||||
|
branch: { iconBack: '#16a34a', font: '11px Inter, sans-serif' },
|
||||||
|
header: { font: '14px Inter, sans-serif' }
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// Initialize on load
|
// Initialize on load
|
||||||
|
|||||||
Reference in new issue
Block a user