diff --git a/src/pages/settings/panes/Appearance.tsx b/src/pages/settings/panes/Appearance.tsx
index e293fe8e..9cf9ef9c 100644
--- a/src/pages/settings/panes/Appearance.tsx
+++ b/src/pages/settings/panes/Appearance.tsx
@@ -372,7 +372,7 @@ export function Component(props: Props) {
}
/>
- {x}
+ {x}
{
settings: state.settings,
};
});
+
+function getContrastingColour(hex: string){
+ hex = hex.replace("#", "");
+ const r = parseInt(hex.substr(0,2),16);
+ const g = parseInt(hex.substr(2,2),16);
+ const b = parseInt(hex.substr(4,2),16);
+ const cc = ((r*299)+(g*587)+(b*114))/1000;
+ return (cc >= 128) ? 'black' : 'white';
+}