Skip to content

Commit

Permalink
SAK-50525 Calendar promise may not have finished loading i18n data (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
maurercw authored Nov 1, 2024
1 parent 01623a5 commit 08c8363
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ export class SakaiCalendar extends LionCalendar {
${super.__renderNavigation()}
<div class="sakai-calendar__navigation__today">
<div>
<a id="today-button" href="javascript:;" @click=${this._todayClicked}>${this._i18n.today}</a>
<a id="today-button" href="javascript:;" @click=${this._todayClicked}>${this._i18n?.today}</a>
</div>
</div>
`;
Expand All @@ -149,14 +149,14 @@ export class SakaiCalendar extends LionCalendar {
</div>
` : nothing}
<div class="calendar-msg">${this._i18n.pinned_sites_message}</div>
<div class="calendar-msg">${this._i18n?.pinned_sites_message}</div>
<div id="container">
${super.render()}
${this._daysEvents?.length > 0 ? html`
<div id="days-events">
<div id="days-events-title">
${this._i18n.events_for} ${new Date(this._daysEvents[0].start).toLocaleDateString(undefined, { dateStyle: "medium" })}
${this._i18n?.events_for} ${new Date(this._daysEvents[0].start).toLocaleDateString(undefined, { dateStyle: "medium" })}
</div>
${this._daysEvents.map(e => html`
<div>
Expand Down

0 comments on commit 08c8363

Please sign in to comment.