Error "Cannot set properties of null (setting 'onclick')"
edersong opened this issue · comments
I have the same problem if I use name: '' in my card, maybe it's the reason for this.
Example:
columns:
- data: entity_picture
align: center
name: ''
icon: mdi:gas-station
modify: '''<img src="'' + x + ''"style="height: 35px;width:100%">'''
I add a space for the name and it works (I want only an icon for my colomn)
columns:
- data: entity_picture
align: center
name: ' '
icon: mdi:gas-station
modify: '''<img src="'' + x + ''"style="height: 35px;width:100%">'''
I had HTML TITLE tags on my names to give info on a mouse over.
Once I removed those, the error went away.
The fix for this is in my repo. If you need it sooner or want to help me test it and are in a position to update flex-table-card.js
manually, it is here:
https://github.com/EdLeckert/flex-table-card/tree/fix-generate-new-id-for-onclick-error
The fix for this is in my repo. If you need it sooner or want to help me test it and are in a position to update
flex-table-card.js
manually, it is here:
https://github.com/EdLeckert/flex-table-card/tree/fix-generate-new-id-for-onclick-error
It works for me ! Thx for this quick hotfix 😃
Did not work in my situation.
Here is the column code that is at issue:
- name: >-
<div title="Clinch Indicator: * : Clinched Best League
Record z : Clinched Playoff Birth x : Clinched
Division - : In The Hunt e : Eliminated">C</div>
data: entries
modify: >-
if(typeof x.stats.find(y=>y.abbreviation == 'CLINCH') !==
'undefined' ){x.stats.find(y=>y.abbreviation ==
'CLINCH').displayValue}else{'-'}
If I remove the HTML, it works fine.
Let me know if you need more code for the whole card.
Thanks
@JeffCrum1: What behavior or error are you seeing?
I'm getting the character "C" with the key for "Clinch Indicator" on hover. I don't have the data to make the modify
work, but the name
works fine for me.
So sorry. I didn't realize I needed to delete the .gz file when manually updating.
All good now!
Thanks for your very quick response!!!
there also is a 0.7.5 release now with all the fixes included...