Skip to content
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

Is it possible to hide somehow icon and name? #341

Open
denveronly opened this issue Aug 4, 2024 · 7 comments
Open

Is it possible to hide somehow icon and name? #341

denveronly opened this issue Aug 4, 2024 · 7 comments

Comments

@denveronly
Copy link

denveronly commented Aug 4, 2024

Hey all, i tried everything but i just cant hide the icon and name.
i tried card-mod but it doesnt work.

image

my code looks like this
`

  • entity: script.update_solar_forecast
    type: custom:multiple-entity-row
    name: Solcast
    state_header: Update
    show_icon: false
    toggle: true
    state_color: false
    icon: mdi:solar-power
    entities:
    - entity: sensor.solcast_pv_forecast_forecast_today
    name: Today
    format: precision0
    tap_action:
    action: more-info
    - entity: sensor.solcast_pv_forecast_forecast_tomorrow
    name: Tomm
    format: precision0
    tap_action:
    action: more-info
    - entity: sensor.solcast_pv_forecast_forecast_day_3
    name: Day3
    format: precision0
    tap_action:
    action: more-info
    - entity: sensor.solcast_pv_forecast_forecast_day_4
    name: Day4
    format: precision0
    tap_action:
    action: more-info
    - entity: sensor.solcast_pv_forecast_forecast_day_5
    name: Day5
    format: precision0
    tap_action:
    action: more-info
    - entity: sensor.solcast_pv_forecast_forecast_day_6
    name: Day6
    format: precision0
    tap_action:
    action: more-info
    card_mod:
    style: |
    hui-generic-entity-row {
    display: none;
    }
    `
@kwkid
Copy link

kwkid commented Sep 3, 2024

forget about card_mod...this is way i use

where you have
entity: script.update_solar_forecast
type: custom:multiple-entity-row
name: Solcast
state_header: Update
show_icon: false
toggle: true
state_color: false
icon: mdi:solar-power

try
entity: script.update_solar_forecast
type: custom:multiple-entity-row
name: ' '
state_header: Update
show_icon: false
toggle: true
state_color: false
icon: mdi:none

@ildar170975
Copy link

forget about card_mod

I would not be so confident since in SOME use-cases this advice may not give a desired effect since entities-row element will occupy SOME part of a row, not a whole row.

2 OP: ask in the main card-mod thread of Community (in case you have not asked already but have not closed this issue yet).

@Airblader
Copy link

FWIW, choosing a non-existing icon seems to work for me. For the name you can use name: ''.

@nicknol
Copy link

nicknol commented Sep 17, 2024

according to the documentation you could suppress the name by setting it to false.
name: false

@ildar170975
Copy link

according to the documentation you could suppress the name by setting it to false.
name: false

This is not about the main entity.

@nicknol
Copy link

nicknol commented Sep 18, 2024

perhaps I didn't get the point.
For me name: false works for all entities: for the main entity but as well for the secondary entities.
It needs to be set per entity.

@ildar170975
Copy link

ildar170975 commented Sep 18, 2024

For me name: false works for all entities: for the main entity but as well for the secondary entities.

I was wrong.
Yes, name: false works for the main entity as well:
изображение

There is a confusion in Docs: for additional entities it is said clearly about false, for the main entity - it is not:
изображение

But anyway, hiding an icon by setting an empty/non-existing icon + hiding a name MAY help in some case - and MAY NOT in case of many additional entities (as it was already noted):

type: entities
entities:
  - type: custom:multiple-entity-row
    entity: sun.sun
    entities:
      - &ref_icon
        entity: sun.sun
        icon: true
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
  - type: custom:multiple-entity-row
    entity: sun.sun
    entities:
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
  - type: custom:multiple-entity-row
    entity: sun.sun
    entities:
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
  - type: custom:multiple-entity-row
    entity: sun.sun
    entities:
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
  - type: custom:multiple-entity-row
    entity: sun.sun
    name: false 
    icon: mdi:none
    entities:
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon
      - *ref_icon

изображение

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants