Skip to content

Commit

Permalink
fix: round grid_power_169 & inverter_power_175
Browse files Browse the repository at this point in the history
  • Loading branch information
slipx06 committed Oct 1, 2023
1 parent ea28e17 commit 0ddacb2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "sunsynk-power-flow-card",
"version": "2.7.0",
"version": "2.7.1",
"description": "A customizable Home Assistant card to emulate the Sunsynk System flow that's displayed on the Inverter screen.",
"main": "sunsynk-power-flow-card.js",
"scripts": {
Expand Down
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1024,10 +1024,10 @@ export class SunsynkPowerFlowCard extends LitElement {
<text id="battery_current_191" x="41" y="336" display="${config.entities.battery_current_191 === 'none' || config.show_battery === false ? 'none' : ''}" fill=${battery_colour} class="${font !== true ? 'st14' : 'st4'} st8">${config.battery.show_absolute === true ? Math.abs(parseFloat(stateObj35.state)).toFixed(1) : parseFloat(stateObj35.state).toFixed(1)} A</text>
</a>
<a href="#" @click=${(e) => this.handlePopup(e, config.entities.inverter_power_175)}>
<text id="inverter_power_175" x="180.5" y="178" display="${config.entities.inverter_power_175 === 'none' ? 'none' : ''}" class="${font !== true ? 'st14' : 'st4'} st8" fill="${inverter_colour}">${config.inverter.auto_scale === true ? `${convertValue(stateObj22.state, round) || 0}` : `${stateObj22.state || 0} W`}</text>
<text id="inverter_power_175" x="180.5" y="178" display="${config.entities.inverter_power_175 === 'none' ? 'none' : ''}" class="${font !== true ? 'st14' : 'st4'} st8" fill="${inverter_colour}">${config.inverter.auto_scale === true ? `${convertValue(stateObj22.state, round) || 0}` : `${parseFloat(stateObj22.state).toFixed(0) || 0} W`}</text>
</a>
<a href="#" @click=${(e) => this.handlePopup(e, config.entities.grid_power_169)}>
<text id="grid_power_169" x="270" y="209" display="${config.entities.grid_power_169 === 'none' ? 'none' : ''}" class="${font !== true ? 'st14' : 'st4'} st8" fill="${grid_colour}">${config.grid.auto_scale === true ? `${convertValue(stateObj23.state, round) || 0}` : `${stateObj23.state || 0} W`}</text>
<text id="grid_power_169" x="270" y="209" display="${config.entities.grid_power_169 === 'none' ? 'none' : ''}" class="${font !== true ? 'st14' : 'st4'} st8" fill="${grid_colour}">${config.grid.auto_scale === true ? `${convertValue(stateObj23.state, round) || 0}` : `${parseFloat(stateObj23.state).toFixed(0) || 0} W`}</text>
</a>
<a href="#" @click=${(e) => this.handlePopup(e, config.entities.pv1_voltage_109)}>
<text id="pv1_voltage" x="41" y="78.5" class="st3 left-align" display="${config.show_solar === false || !config.entities.pv1_voltage_109 || config.entities.pv1_voltage_109 === 'none' ? 'none' : ''}" fill="${solar_colour}" >${parseFloat(stateObj16.state).toFixed(1)} V</text>
Expand Down

0 comments on commit 0ddacb2

Please sign in to comment.