mirror of
https://github.com/shoelace-style/webawesome.git
synced 2026-01-12 04:09:12 +00:00
@@ -36,6 +36,7 @@ Components with the <wa-badge variant="warning">Experimental</wa-badge> badge sh
|
||||
- Fixed a bug in `<wa-input>` that prevented the value from changing when assigning non-string values to `value` [issue:1323]
|
||||
- Fixed a bug in `<wa-color-picker>` that prevent the picker from staying in the viewport
|
||||
- Fixed a bug that in `<wa-icon>` that caused `library`, `family`, `variant` and `name` to not reflect [pr:#1395]
|
||||
- Fixed a bug in `<wa-format-date>` and `<wa-relative-time>` that caused spaces to appear before and after the output [#1417]
|
||||
|
||||
## 3.0.0-beta.4
|
||||
|
||||
|
||||
@@ -66,23 +66,22 @@ export default class WaFormatDate extends WebAwesomeElement {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
return html`
|
||||
<time datetime=${date.toISOString()}>
|
||||
${this.localize.date(date, {
|
||||
weekday: this.weekday,
|
||||
era: this.era,
|
||||
year: this.year,
|
||||
month: this.month,
|
||||
day: this.day,
|
||||
hour: this.hour,
|
||||
minute: this.minute,
|
||||
second: this.second,
|
||||
timeZoneName: this.timeZoneName,
|
||||
timeZone: this.timeZone,
|
||||
hour12: hour12,
|
||||
})}
|
||||
</time>
|
||||
`;
|
||||
const displayDate = this.localize.date(date, {
|
||||
weekday: this.weekday,
|
||||
era: this.era,
|
||||
year: this.year,
|
||||
month: this.month,
|
||||
day: this.day,
|
||||
hour: this.hour,
|
||||
minute: this.minute,
|
||||
second: this.second,
|
||||
timeZoneName: this.timeZoneName,
|
||||
timeZone: this.timeZone,
|
||||
hour12: hour12,
|
||||
});
|
||||
|
||||
// No whitespace before or after
|
||||
return html`<time datetime=${date.toISOString()}>${displayDate}</time>`;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -99,7 +99,8 @@ export default class WaRelativeTime extends WebAwesomeElement {
|
||||
this.updateTimeout = setTimeout(() => this.requestUpdate(), nextInterval);
|
||||
}
|
||||
|
||||
return html` <time datetime=${this.isoTime}>${this.relativeTime}</time> `;
|
||||
// No whitespace before or after
|
||||
return html`<time datetime=${this.isoTime}>${this.relativeTime}</time>`;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user