fix slot names (#577)

This commit is contained in:
Cory LaViska
2025-01-21 12:52:41 -05:00
committed by GitHub
parent d1c1d689ce
commit 13b3342017
2 changed files with 4 additions and 5 deletions

View File

@@ -12,11 +12,10 @@ Components with the <wa-badge variant="warning" pill>Experimental</wa-badge> bad
During the alpha period, things might break! We take breaking changes very seriously, but sometimes they're necessary to make the final product that much better. We appreciate your patience!
:::
<!--
## Next
- Added `.wa-callout` utility class
-->
- Fixed slot names for `show-password-icon` and `hide-password-icon` in `<wa-input>` to more intuitively represent their functions
## 3.0.0-alpha.9

View File

@@ -475,15 +475,15 @@ export default class WaInput extends WebAwesomeFormAssociatedElement {
@click=${this.handlePasswordToggle}
tabindex="-1"
>
${this.passwordVisible
${!this.passwordVisible
? html`
<slot name="show-password-icon">
<wa-icon name="eye-slash" library="system" variant="regular"></wa-icon>
<wa-icon name="eye" library="system" variant="regular"></wa-icon>
</slot>
`
: html`
<slot name="hide-password-icon">
<wa-icon name="eye" library="system" variant="regular"></wa-icon>
<wa-icon name="eye-slash" library="system" variant="regular"></wa-icon>
</slot>
`}
</button>