Exported the popup part of the dropdown component (#2078)

pull/2101/head
Alex Andres 2024-06-21 19:34:27 +02:00 zatwierdzone przez GitHub
rodzic d7e9d717c2
commit a5c3971a17
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: B5690EEEBB952194
1 zmienionych plików z 3 dodań i 1 usunięć

Wyświetl plik

@ -34,7 +34,8 @@ import type SlMenu from '../menu/menu.js';
* @event sl-hide - Emitted when the dropdown closes. * @event sl-hide - Emitted when the dropdown closes.
* @event sl-after-hide - Emitted after the dropdown closes and all animations are complete. * @event sl-after-hide - Emitted after the dropdown closes and all animations are complete.
* *
* @csspart base - The component's base wrapper. * @csspart base - The component's base wrapper, an `<sl-popup>` element.
* @csspart base__popup - The popup's exported `popup` part. Use this to target the tooltip's popup container.
* @csspart trigger - The container that wraps the trigger. * @csspart trigger - The container that wraps the trigger.
* @csspart panel - The panel that gets shown when the dropdown is open. * @csspart panel - The panel that gets shown when the dropdown is open.
* *
@ -406,6 +407,7 @@ export default class SlDropdown extends ShoelaceElement {
return html` return html`
<sl-popup <sl-popup
part="base" part="base"
exportparts="popup:base__popup"
id="dropdown" id="dropdown"
placement=${this.placement} placement=${this.placement}
distance=${this.distance} distance=${this.distance}