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

Fix decimalSymbol for forecast #2534

Merged
merged 2 commits into from
Apr 12, 2021
Merged

Fix decimalSymbol for forecast #2534

merged 2 commits into from
Apr 12, 2021

Conversation

KristjanESPERANTO
Copy link
Contributor

With this, the decimalSymbol config also works at the forecast part of the new weather module.

This solves the issue #2530.

@codecov-io
Copy link

Codecov Report

Merging #2534 (5c2a0e5) into develop (f8769fc) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff            @@
##           develop    #2534   +/-   ##
========================================
  Coverage    39.90%   39.90%           
========================================
  Files           21       21           
  Lines         1629     1629           
========================================
  Hits           650      650           
  Misses         979      979           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f8769fc...5c2a0e5. Read the comment docs.

@@ -14,10 +14,10 @@
{% endif %}
<td class="bright weather-icon"><span class="wi weathericon wi-{{ f.weatherType }}"></span></td>
<td class="align-right bright max-temp">
{{ f.maxTemperature | roundValue | unit("temperature") }}
{{ f.maxTemperature | roundValue | decimalSymbol | unit("temperature") }}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if the order is important here... In the current njk the decimalSymbol is applied last...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried that first, but it didn't work.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I checked it again. In the forcast part it doesn't work if decimalSymbol is at the end.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How doesnt it work on your side? It looks ok if I move the dcimalSymbol to the end.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apparently I made the same mistake twice (insert the decimalSymbol inside the unit brackets). That couldn't work 🤦‍♂️. So it (decimalSymbol at the end) works if you do it right. Sorry.

Should I adjust my PR so that it is consistent with the current part?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I think consistency is king :-) Have a good monday!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed it 🙂

Copy link
Collaborator

@rejas rejas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thx for the quick PR

@MichMich MichMich merged commit 5809453 into MagicMirrorOrg:develop Apr 12, 2021
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

Successfully merging this pull request may close these issues.

4 participants