diff --git a/README.md b/README.md index d255ab1..d8f12f5 100644 --- a/README.md +++ b/README.md @@ -120,6 +120,7 @@ Can be specified by color name, hexadecimal, rgb, rgba, hsl, hsla, basically any | `restriction-lock-row-margin-left` | `24px` | Manually bump the left margin of the lock icon in rows | | `restriction-lock-icon-height` | `24px` | Lock icon height | | `restriction-lock-icon-width` | `24px` | Lock icon width | +| `restriction-lock-opacity` | `0.5` | Lock icon opacity | ## Example Configurations diff --git a/package.json b/package.json index 6152092..6626018 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "restriction-card", - "version": "1.2.0", + "version": "1.2.1", "description": "Lovelace restriction-card", "keywords": [ "home-assistant", @@ -48,4 +48,4 @@ "lint": "eslint src/*.ts", "rollup": "rollup -c" } -} +} \ No newline at end of file diff --git a/src/const.ts b/src/const.ts index 38e11f4..6a82ac0 100644 --- a/src/const.ts +++ b/src/const.ts @@ -1 +1 @@ -export const CARD_VERSION = '1.2.0'; +export const CARD_VERSION = '1.2.1'; diff --git a/src/restriction-card.ts b/src/restriction-card.ts index dd82323..f9267cb 100644 --- a/src/restriction-card.ts +++ b/src/restriction-card.ts @@ -229,6 +229,7 @@ class RestrictionCard extends LitElement implements LovelaceCard { --lock-row-margin-left: var(--restriction-lock-row-margin-left, 24px); --lock-icon-height: var(--restriction-lock-icon-height, var(--iron-icon-height, 24px)); --lock-icon-width: var(--restriction-lock-icon-width, var(--iron-icon-width, 24px)); + --lock-opacity: var(--restriction-lock-opacity, 0.5); } ha-icon { --iron-icon-height: var(--lock-icon-height); @@ -237,7 +238,6 @@ class RestrictionCard extends LitElement implements LovelaceCard { #overlay { align-items: flex-start; padding: 8px 7px; - opacity: 0.5; position: absolute; left: 0; right: 0; @@ -252,6 +252,7 @@ class RestrictionCard extends LitElement implements LovelaceCard { } #lock { margin-left: var(--lock-margin-left); + opacity: var(--lock-opacity); } .row { margin-left: var(--lock-row-margin-left) !important;