diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2021-11-15 00:47:13 +0100 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2021-11-15 00:47:13 +0100 |
commit | ecdb4b7eeb42dc859cfd6aa31634b423b72c50bd (patch) | |
tree | b910e8d3c6661f2b7e401ae18097f643d5cdd585 /static/components/vevent.ts | |
parent | Reword popup visible attribute. (diff) | |
download | calp-ecdb4b7eeb42dc859cfd6aa31634b423b72c50bd.tar.gz calp-ecdb4b7eeb42dc859cfd6aa31634b423b72c50bd.tar.xz |
Rework some drawing and how calendar is accessed.
Diffstat (limited to 'static/components/vevent.ts')
-rw-r--r-- | static/components/vevent.ts | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/static/components/vevent.ts b/static/components/vevent.ts index de232794..d957c7c8 100644 --- a/static/components/vevent.ts +++ b/static/components/vevent.ts @@ -26,6 +26,7 @@ class ComponentVEvent extends HTMLElement { } this.uid = real_uid; + this.dataset.uid = uid; vcal_objects.get(this.uid)?.register(this); @@ -36,9 +37,9 @@ class ComponentVEvent extends HTMLElement { } connectedCallback() { - let uid, v; - if ((uid = this.dataset.uid)) { - v = vcal_objects.get(uid) + let uid = this.dataset.uid + if (uid) { + let v = vcal_objects.get(uid) if (v) this.redraw(v); } } |