MCPcopy Create free account
hub / github.com/Ashutosh00710/github-readme-activity-graph / onThemeChange

Function onThemeChange

script.js:64–82  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

62};
63// Handle theme selection
64const onThemeChange = () => {
65 const selected = elements.themeSelect.value;
66 const theme = themes[selected] || themes.default;
67 // Update color pickers
68 inputElements.bgInput.value = theme.bgColor;
69 inputElements.lineInput.value = theme.line;
70 inputElements.pointInput.value = theme.point;
71 inputElements.ltgInput.value = theme.color;
72 // Update valueToCopy
73 valueToCopy.bgColor = theme.bgColor;
74 valueToCopy.line = theme.line;
75 valueToCopy.point = theme.point;
76 valueToCopy.color = theme.color;
77 // Update UI colors
78 changeBgColor();
79 changeLineColor();
80 changeLabelsAndGridColor();
81 changePointColor();
82};
83
84const inputElements = {
85 bgInput: document.getElementById('bgColor'),

Callers

nothing calls this directly

Calls 4

changeBgColorFunction · 0.85
changeLineColorFunction · 0.85
changeLabelsAndGridColorFunction · 0.85
changePointColorFunction · 0.85

Tested by

no test coverage detected