@@ -207,7 +207,7 @@ export default class SdSelect extends SolidElement implements SolidFormControl {
207207 @property ( ) getTag : ( option : SdOption , index : number ) => TemplateResult | string | HTMLElement = option => {
208208 return html `
209209 <sd- tag
210- class= "relative z-10"
210+ class= "relative z-10 min-w-0 max-w-full "
211211 ?dis abled= ${ this . disabled }
212212 part= "tag"
213213 exportparts = "
@@ -693,7 +693,7 @@ export default class SdSelect extends SolidElement implements SolidFormControl {
693693 if ( index < this . maxOptionsVisible || this . maxOptionsVisible <= 0 ) {
694694 const tag = this . getTag ( option , index ) ;
695695 // Wrap so we can handle the remove
696- return html ` <div @sd-remove = ${ ( e : CustomEvent ) => this . handleTagRemove ( e , option ) } >
696+ return html ` <div @sd-remove = ${ ( e : CustomEvent ) => this . handleTagRemove ( e , option ) } class = "max-w-full" >
697697 ${ typeof tag === 'string' ? unsafeHTML ( tag ) : tag }
698698 </ div> ` ;
699699 }
@@ -703,7 +703,7 @@ export default class SdSelect extends SolidElement implements SolidFormControl {
703703 return [
704704 html `
705705 <sd- tag
706- class= "z-10"
706+ class= "z-10 min-w-0 max-w-full "
707707 ?dis abled= ${ this . disabled }
708708 part= "tag"
709709 exportparts = "
@@ -1047,7 +1047,7 @@ export default class SdSelect extends SolidElement implements SolidFormControl {
10471047 >
10481048 <div
10491049 class= ${ cx (
1050- 'input-container items-center w-full h-full px-4 flex' ,
1050+ 'input-container items-center w-full h-full px-4 flex min-w-0 ' ,
10511051 {
10521052 sm : 'py-1' ,
10531053 md : 'py-1' ,
@@ -1061,7 +1061,7 @@ export default class SdSelect extends SolidElement implements SolidFormControl {
10611061 for m= ${ this . form }
10621062 part= "display-input"
10631063 class = ${ cx (
1064- 'top-0 left-0 appearance-none outline-none flex-grow bg-transparent flex-1 placeholder:text-neutral-700' ,
1064+ 'top-0 left-0 appearance-none outline-none flex-grow bg-transparent flex-1 placeholder:text-neutral-700 min-w-0 ' ,
10651065 cursorStyles ,
10661066 this . multiple && this . useTags && this . value . length > 0 ? 'hidden' : '' ,
10671067 this . size === 'sm'
@@ -1094,10 +1094,10 @@ export default class SdSelect extends SolidElement implements SolidFormControl {
10941094 tabindex= "-1"
10951095 / >
10961096
1097- ${ this . multiple && this . useTags
1097+ ${ this . multiple && this . useTags && this . tags && this . tags . length > 0
10981098 ? html ` <div
10991099 part= "tags"
1100- class = ${ cx ( 'flex-grow flex flex-wrap items-center gap-1' , this . floatingLabel && 'pt-6' ) }
1100+ class = ${ cx ( 'flex-grow flex flex-wrap items-center gap-1 min-w-0 ' , this . floatingLabel && 'pt-6' ) }
11011101 >
11021102 ${ this . tags }
11031103 </ div> `
@@ -1126,7 +1126,7 @@ export default class SdSelect extends SolidElement implements SolidFormControl {
11261126 class = ${ cx (
11271127 'select__clear flex justify-center' ,
11281128 iconMarginLeft ,
1129- this . value . length > 0 ? 'visible' : 'invisible '
1129+ this . value . length > 0 ? 'visible' : 'hidden '
11301130 ) }
11311131 type= "butto n"
11321132 aria- label= ${ this . localize . term ( 'clearEntry' ) }
0 commit comments