Custom menu elements lost on certain re-renders
See original GitHub issueChecklist:
- I updated to the latest version available
- I cleared the cache of my browser
Release with the issue: 1.2.1 Last working release (if known):
Browser and Operating System: Microsoft Edge / Chrome
Description of problem: When adding elements to the card like scripts etc They wont be shown. Sometimes it shows but sometimes not.
Javascript errors shown in the web inspector (if applicable):
nothing in console
Additional information: here my card config:
## Created by Thorsten Fröhlich
## More-page add-on: Camera
## Version: 1.0.0
- type: custom:swipe-card
cards:
- type: custom:frigate-card
camera_entity: camera.front_door
view_default: live
live_preload: true
# live_provider: frigate
autoplay_clip: true
dimensions:
aspect_ratio_mode: static
controls: {}
menu_mode: hidden-right
# webrtc: {}
elements:
- type: custom:frigate-card-menu-state-icon
entity: script.restart_foscam
tap_action:
action: toggle
- type: custom:frigate-card-menu-state-icon
entity: script.preset_garage
tap_action:
action: toggle
- type: custom:frigate-card-menu-state-icon
entity: script.preset_street
tap_action:
action: toggle
- type: custom:frigate-card-menu-state-icon
entity: script.preset_maindoor
tap_action:
action: toggle
# - type: state-badge
# entity: sensor.date_time
# style:
# right: '52px'
# top: '80px'
# # color: rgba(0,0,0,0)
# opacity: 1.0
- type: custom:frigate-card
camera_entity: camera.garden
view_default: live
# live_provider: frigate-jsmpeg
autoplay_clip: true
live_preload: true
dimensions:
aspect_ratio_mode: static
controls: {}
menu_mode: overlay-right
# webrtc: {}
elements:
- type: conditional
conditions:
- entity: light.garden
state: "on"
elements:
- type: custom:frigate-card-menu-state-icon
entity: light.garden
tap_action:
action: toggle
- type: custom:frigate-card
camera_entity: camera.garden_upstairs_2
view_default: live
live_preload: true
# live_provider: frigate-jsmpeg
autoplay_clip: true
dimensions:
aspect_ratio_mode: static
controls: {}
menu_mode: overlay-right
# webrtc: {}
- type: custom:frigate-card
camera_entity: camera.garage
view_default: live
# live_provider: frigate-jsmpeg
autoplay_clip: true
live_preload: true
dimensions:
aspect_ratio_mode: static
controls: {}
menu_mode: overlay-right
# webrtc: {}
elements:
- type: custom:frigate-card-menu-state-icon
entity: light.garage
tap_action:
action: toggle
# - type: conditional
# conditions:
# - entity: light.garage
# state: 'on'
# elements:
# - type: custom:frigate-card-menu-state-icon
# entity: light.garage
# tap_action:
# action: toggle
More info: When the page loads I can see super shortly the icons but they disappear directly after finished loading
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (5 by maintainers)
Top Results From Across the Web
React Material-UI menu anchor lost because of re-rendered ...
It turns out that a hook is needed. const innerListType = React.useMemo(() => { return React.forwardRef((props, ref) => ( <List ...
Read more >How to prevent re-renders on React functional components ...
React.memo() allows you to avoid multiple re-renders for functional components. ... But it does lose some of features that the React.
Read more >Preventing infinite re-renders when using useEffect and ...
React's useEffect hook is an incredibly useful tool for fetching data, but if you're not careful, can cause infinite re-renders.
Read more >[TextField] loses focus on rerender · Issue #783 · mui/material-ui
My TextFields are losing focus on re-render. I'm setting the value prop of the TextField , so it is a controlled component. I...
Read more >How to stop re-rendering lists in React? - Alex Sidorenko
This happens because we put items as a dependency for useCallback . Every time items update, useCallback returns a new reference of the...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@thundergreen Yup, already fixed, see pinned issue. Will be in the next build, fairly shortly.
Latest home assistant version has a change in icons which leads to icons not loading in addition to this issue . This card needs an upgrade ladies and gentlemen 🧐😊