shoelace-style/shoelace

The clear button for input collapse when the input has a small width

Open

#2,414 opened on Mar 30, 2025

View on GitHub
 (0 comments) (1 reaction) (0 assignees)TypeScript (922 forks)github user discovery
bugfixed-in-wagood first issuehelp wanted

Repository metrics

Stars
 (13,867 stars)
PR merge metrics
 (No merged PRs in 30d)

Description

Describe the bug

When a the sl-input has a small width, e.g. 8rem, the clear button of the input has a smaller width than usual.

To Reproduce

<sl-input clearable value="1234"></sl-input>
sl-input {
  max-width: 8rem
}

Demo

https://codepen.io/fsujvjic-the-reactor/pen/GgRYzXe

Browser / OS

  • OS: Windows
  • Browser: Firefox
  • Browser version: 136.0.4

Contributor guide