From df5a86f0d807089f6ff95d4db016e6d777c57c89 Mon Sep 17 00:00:00 2001 From: Steven Marks Date: Thu, 14 Sep 2023 20:39:28 +0000 Subject: [PATCH] fix: calendar view currentDay becomes distorted --- src/index.ts | 4 ++-- src/style.ts | 13 ++++++------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/index.ts b/src/index.ts index d1dd3ddf..fa6238bf 100644 --- a/src/index.ts +++ b/src/index.ts @@ -608,8 +608,8 @@ export class AtomicCalendarRevive extends LitElement { style="${dayStyleOtherMonth}${dayStyleSat}${dayStyleSun}${dayStyleClicked} --cal-grid-color: ${this._config .calGridColor}; --cal-day-color: ${this._config.calDayColor}" > -
-
${day.date.date()}
+
+
${day.date.date()}
${handleCalendarIcons(day)}
diff --git a/src/style.ts b/src/style.ts index a798af9b..f5fa2788 100644 --- a/src/style.ts +++ b/src/style.ts @@ -299,17 +299,16 @@ export const styles: CSSResultGroup = css` margin: auto; } - .calDay.currentDay { + .currentDay { + position: relative; + width: 20px; height: 20px; background-color: var(--primary-color); + color: var(--text-primary-color) !important; + text-align: center; + line-height: 20px; border-radius: 50%; display: inline-block; - text-align: center; - white-space: nowrap; - width: max-content; - min-width: 20px; - line-height: 140%; - color: var(--text-primary-color) !important; } tr.cal {