Skip to content

Commit f478b98

Browse files
daKmoRMikhail Bashkirov
authored andcommitted
feat(button): add template hooks for before/after default slot
1 parent 8d81f84 commit f478b98

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

packages/button/src/LionButton.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,25 @@ export class LionButton extends DelegateMixin(SlotMixin(LionLitElement)) {
2222
render() {
2323
return html`
2424
<div class="btn">
25+
${this._renderBefore()}
2526
<slot></slot>
27+
${this._renderAfter()}
2628
<slot name="_button"></slot>
2729
<div class="click-area" @click="${this.__clickDelegationHandler}"></div>
2830
</div>
2931
`;
3032
}
3133

34+
// eslint-disable-next-line class-methods-use-this
35+
_renderBefore() {
36+
return html``;
37+
}
38+
39+
// eslint-disable-next-line class-methods-use-this
40+
_renderAfter() {
41+
return html``;
42+
}
43+
3244
static get styles() {
3345
return [
3446
css`

0 commit comments

Comments
 (0)