Card Picker: Fix Clicking cards (#5425)

* fix

* reviews
This commit is contained in:
Zack Arnett 2020-04-02 17:52:43 -04:00 committed by GitHub
parent f5d834d130
commit 8eebf51447
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -200,6 +200,7 @@ export class HuiCardPicker extends LitElement {
background: var(--primary-background-color, #fafafa);
cursor: pointer;
box-sizing: border-box;
position: relative;
}
.card-header {
@ -242,6 +243,13 @@ export class HuiCardPicker extends LitElement {
align-items: center;
justify-content: center;
}
.overlay {
position: absolute;
width: 100%;
height: 100%;
z-index: 1;
}
`,
];
}
@ -297,7 +305,12 @@ export class HuiCardPicker extends LitElement {
}
return html`
<div class="card" @click="${this._cardPicked}" .config="${cardConfig}">
<div class="card">
<div
class="overlay"
@click=${this._cardPicked}
.config=${cardConfig}
></div>
<div
class="preview ${classMap({
description: !element || element.tagName === "HUI-ERROR-CARD",