diff options
author | crupest <crupest@outlook.com> | 2021-05-06 22:01:12 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2021-05-06 22:01:12 +0800 |
commit | dee1f495aec7cf29769080d5e4208abe32063d6f (patch) | |
tree | 560aa7c9bf673a78efb78cf1e709eab29d4fedf0 /FrontEnd/src/app/palette.ts | |
parent | aad014ed2961ce660e8a4d6474a6197bee41f69c (diff) | |
download | timeline-dee1f495aec7cf29769080d5e4208abe32063d6f.tar.gz timeline-dee1f495aec7cf29769080d5e4208abe32063d6f.tar.bz2 timeline-dee1f495aec7cf29769080d5e4208abe32063d6f.zip |
feat: Timeline color.
Diffstat (limited to 'FrontEnd/src/app/palette.ts')
-rw-r--r-- | FrontEnd/src/app/palette.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/FrontEnd/src/app/palette.ts b/FrontEnd/src/app/palette.ts index 98e7d814..c4f4f4f9 100644 --- a/FrontEnd/src/app/palette.ts +++ b/FrontEnd/src/app/palette.ts @@ -95,9 +95,11 @@ const paletteSubject: BehaviorSubject<Palette> = new BehaviorSubject<Palette>( export const palette$: Observable<Palette> = paletteSubject.asObservable(); palette$.subscribe((palette) => { - let styleTag = document.getElementById("timeline-palette-css"); + const styleTagId = "timeline-palette-css"; + let styleTag = document.getElementById(styleTagId); if (styleTag == null) { styleTag = document.createElement("style"); + styleTag.id = styleTagId; document.head.append(styleTag); } styleTag.innerHTML = generatePaletteCSS(palette); |