Skip to content

Commit

Permalink
Resolve attribute and icon alignment issues in compact mode, per #5
Browse files Browse the repository at this point in the history
  • Loading branch information
lizsugar committed May 20, 2022
1 parent 270cb13 commit f28cb31
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions dist/slider-button-card.js
Original file line number Diff line number Diff line change
Expand Up @@ -8126,7 +8126,9 @@ let SliderButtonCard = class SliderButtonCard extends LitElement {
color: var(--disabled-text-color);
}
.compact .icon {
position: relative;
float: left;
bottom: 0px;
}
/* --- TEXT --- */
Expand Down Expand Up @@ -8219,6 +8221,12 @@ let SliderButtonCard = class SliderButtonCard extends LitElement {
*/
}
.compact .attribute {
display: inline-block;
max-width: calc(100% - 0em);
overflow: hidden;
}
.oneliner {
color: var(--state-color-on, var(--label-badge-text-color, white));
text-overflow: ellipsis;
Expand Down
8 changes: 8 additions & 0 deletions src/slider-button-card.ts
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,9 @@ export class SliderButtonCard extends LitElement implements LovelaceCard {
color: var(--disabled-text-color);
}
.compact .icon {
position: relative;
float: left;
bottom: 0px;
}
/* --- TEXT --- */
Expand Down Expand Up @@ -648,6 +650,12 @@ export class SliderButtonCard extends LitElement implements LovelaceCard {
*/
}
.compact .attribute {
display: inline-block;
max-width: calc(100% - 0em);
overflow: hidden;
}
.oneliner {
color: var(--state-color-on, var(--label-badge-text-color, white));
text-overflow: ellipsis;
Expand Down

0 comments on commit f28cb31

Please sign in to comment.