Skip to content

Commit 0910231

Browse files
fix: set display: contents on custom elements for proper layout participation (#104)
Fixes #103.
1 parent 3acc00c commit 0910231

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

app/assets/javascript/devise/webauthn.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ function isWebAuthnSupported() {
99

1010
export class WebauthnCreateElement extends HTMLElement {
1111
connectedCallback() {
12+
this.style.display = 'contents';
13+
1214
if (!isWebAuthnSupported()) {
1315
this.handleWebauthnUnsupported();
1416
return;
@@ -88,6 +90,8 @@ export class WebauthnCreateElement extends HTMLElement {
8890

8991
export class WebauthnGetElement extends HTMLElement {
9092
connectedCallback() {
93+
this.style.display = 'contents';
94+
9195
if (!isWebAuthnSupported()) {
9296
this.handleWebauthnUnsupported();
9397
return;

0 commit comments

Comments
 (0)