-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Add signed add-on capability and adjust max rating #11703
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -16,8 +16,11 @@ import { | |||||||||||||
| mdiNumeric4, | ||||||||||||||
| mdiNumeric5, | ||||||||||||||
| mdiNumeric6, | ||||||||||||||
| mdiNumeric7, | ||||||||||||||
| mdiNumeric8, | ||||||||||||||
| mdiPound, | ||||||||||||||
| mdiShield, | ||||||||||||||
| mdiLinkLock, | ||||||||||||||
| } from "@mdi/js"; | ||||||||||||||
| import { css, CSSResultGroup, html, LitElement, TemplateResult } from "lit"; | ||||||||||||||
| import { customElement, property, state } from "lit/decorators"; | ||||||||||||||
|
|
@@ -84,6 +87,8 @@ const RATING_ICON = { | |||||||||||||
| 4: mdiNumeric4, | ||||||||||||||
| 5: mdiNumeric5, | ||||||||||||||
| 6: mdiNumeric6, | ||||||||||||||
| 7: mdiNumeric7, | ||||||||||||||
| 8: mdiNumeric8, | ||||||||||||||
| }; | ||||||||||||||
|
|
||||||||||||||
| @customElement("hassio-addon-info") | ||||||||||||||
|
|
@@ -234,8 +239,8 @@ class HassioAddonInfo extends LitElement { | |||||||||||||
| <ha-chip | ||||||||||||||
| hasIcon | ||||||||||||||
| class=${classMap({ | ||||||||||||||
| green: [5, 6].includes(Number(this.addon.rating)), | ||||||||||||||
| yellow: [3, 4].includes(Number(this.addon.rating)), | ||||||||||||||
| green: [6, 7, 8].includes(Number(this.addon.rating)), | ||||||||||||||
| yellow: [3, 4, 5].includes(Number(this.addon.rating)), | ||||||||||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This yellow could be a bit darker. It's hard to read with white text.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's using this frontend/src/resources/ha-style.ts Lines 53 to 58 in 3a664d4
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. alright let's keep it for now. |
||||||||||||||
| red: [1, 2].includes(Number(this.addon.rating)), | ||||||||||||||
|
ludeeus marked this conversation as resolved.
Outdated
|
||||||||||||||
| })} | ||||||||||||||
| @click=${this._showMoreInfo} | ||||||||||||||
|
|
@@ -364,6 +369,16 @@ class HassioAddonInfo extends LitElement { | |||||||||||||
| </ha-chip> | ||||||||||||||
| ` | ||||||||||||||
| : ""} | ||||||||||||||
| ${this.addon.signed | ||||||||||||||
| ? html` | ||||||||||||||
| <ha-chip hasIcon @click=${this._showMoreInfo} id="signed"> | ||||||||||||||
| <ha-svg-icon slot="icon" .path=${mdiLinkLock}></ha-svg-icon> | ||||||||||||||
| ${this.supervisor.localize( | ||||||||||||||
| "addon.dashboard.capability.label.signed" | ||||||||||||||
| )} | ||||||||||||||
| </ha-chip> | ||||||||||||||
| ` | ||||||||||||||
| : ""} | ||||||||||||||
| </div> | ||||||||||||||
|
ludeeus marked this conversation as resolved.
Outdated
|
||||||||||||||
|
|
||||||||||||||
| <div class="description light-color"> | ||||||||||||||
|
|
||||||||||||||
Uh oh!
There was an error while loading. Please reload this page.