From 3f1c74b951621020a835bff157d30f6707cfb68b Mon Sep 17 00:00:00 2001 From: pk Date: Wed, 9 Aug 2023 00:24:41 +0200 Subject: [PATCH] Add parts --- tp-button.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tp-button.js b/tp-button.js index 7d4379d..560325a 100644 --- a/tp-button.js +++ b/tp-button.js @@ -123,8 +123,8 @@ class TpButton extends EventHelpers(LitElement) { render() { return html` -
-
+
+
${this.extended ? html` @@ -200,6 +200,10 @@ class TpButton extends EventHelpers(LitElement) { this.unlisten(this, 'keypress', '_keyPressed'); } + firstUpdated() { + this.listen(this, 'keypress', '_keyPressed'); + } + shouldUpdate(changes) { if (changes.has('submit') && this.submit) { this.extended = true;