Compare commits

...

3 Commits

Author SHA1 Message Date
Cory LaViska
ac376afbaa prevent card example from overflowing 2025-03-12 14:44:05 -04:00
Cory LaViska
1283a696a5 fix switch + tooltip behavior (#793) 2025-03-12 18:22:23 +00:00
Cory LaViska
d12b97b0b0 fix wa-pill and wa-input[pill] styles (#791) 2025-03-12 16:19:50 +00:00
5 changed files with 21 additions and 5 deletions

View File

@@ -19,13 +19,13 @@ icon: card
<div slot="footer">
<wa-button variant="brand" pill>More Info</wa-button>
<wa-rating></wa-rating>
<wa-rating label="Rating"></wa-rating>
</div>
</wa-card>
<style>
.card-overview {
max-width: 300px;
width: 300px;
}
.card-overview small {

View File

@@ -42,6 +42,14 @@ wa-code-demo::part(preview) {
<wa-input label="WA Input (url)" type="url"></wa-input>
```
## Pill shaped text fields
Add the `wa-pill` class to an `<input>` to make it pill-shaped.
```html {.example}
<label>Input <input type="text" placeholder="placeholder" class="wa-pill"></label>
```
## Color Picker
Basic:

View File

@@ -12,6 +12,11 @@ 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
- Fixed `wa-pill` class for text fields
- Fixed `pill` style for `<wa-input>` elements
## 3.0.0-alpha.11
### Color Palettes
@@ -20,6 +25,7 @@ During the alpha period, things might break! We take breaking changes very serio
- Added a `pink` scale to all color palettes
- Tweaked hues of all color palettes to make them more distinct and make their hues more intentional
- Dropped `violet` and `teal`, instead using `purple` and `cyan` (this is not just a renaming, the colors have been adjusted too).
- Fixed a bug in `<wa-switch>` that caused tooltips to work incorrectly when toggling the switch
### Design Tokens

View File

@@ -49,6 +49,7 @@ import styles from './switch.css';
*/
@customElement('wa-switch')
export default class WaSwitch extends WebAwesomeFormAssociatedElement {
static shadowRootOptions = { ...WebAwesomeFormAssociatedElement.shadowRootOptions, delegatesFocus: true };
static shadowStyle = [formControlStyles, sizeStyles, styles];
static get validators() {

View File

@@ -121,7 +121,8 @@ input:where(:not(
font: inherit;
}
.wa-pill,
:host([pill]) {
border-radius: var(--wa-border-radius-pill);
input.wa-pill,
textarea.wa-pill,
:host([pill]) .wa-text-field {
border-radius: var(--wa-border-radius-pill) !important;
}