Commit Graph

14 Commits (5abc03c21ebdeccea1678cd4721ae01fa09e3673)

Author SHA1 Message Date
G Johansson d785c4b0b1
Add optional category in OptionsFlow to holiday () 2024-12-17 20:20:26 +01:00
epenet 25aea140be
Cleanup unnecessary reconfigure_confirm from config flows () 2024-10-14 12:57:15 +02:00
epenet ac7dc03603
Do not cache the reconfigure entry in holiday config flow () 2024-10-09 17:09:24 +02:00
epenet c7739a7760
Align async_step_reconfigure type hints () 2024-10-03 17:54:51 +02:00
epenet f0f924a0a2
Use _get_reconfigure_entry in holiday () 2024-10-02 14:31:19 +02:00
epenet 46405d7738
Improve type hints in config_flow reconfigure step () 2024-10-01 22:21:54 +02:00
G Johansson d4f158d079
Add reconfigure step to holiday () 2024-03-23 22:55:05 +01:00
Marc Mueller 8809d3aa88
Add empty line after module docstring [g-i] () 2024-03-08 08:52:48 -05:00
Erik Montnemery e06446d0fa
Migrate integrations e-h to generic flowhandler () 2024-02-29 20:07:36 +01:00
Jan Rieger 9a81a29ce2
Let babel handle the locale separator in holiday () 2024-01-08 22:59:12 +01:00
G Johansson 648afe121d
Replace dash in language if needed ()
* Replace dash in language if needed

* Add tests
2023-12-28 20:16:14 +01:00
G Johansson b852eb7e23
Fix holiday HA language not supported () 2023-12-28 16:10:27 +01:00
Jan Rieger 81d05acd07
Address late review for Holiday () 2023-12-06 12:39:46 +01:00
Jan Rieger 244edb488b
Add Holiday integration ()
* Add Holiday integration

* Localize holiday names

* Changes based on review feedback

* Add tests

* Add device info

* Bump holidays to 0.36

* Default to Home Assistant country setting

* Update homeassistant/components/holiday/calendar.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Update homeassistant/components/holiday/calendar.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Update homeassistant/components/holiday/config_flow.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* black

* Move time

* Stop creating duplicate holiday calendars

* Set default language using python-holiday

* Use common translation

* Set _attr_name to None to fix friendly name

* Fix location

* Update homeassistant/components/holiday/__init__.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Update homeassistant/components/holiday/calendar.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Update homeassistant/components/holiday/calendar.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Update tests/components/holiday/test_init.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* cleanup

* Set up the integration and test the state

* Test that configuring more than one instance is rejected

* Set default_language to user's language, fallback to country's default language

* Improve tests

* Update homeassistant/components/holiday/calendar.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Cleanup

* Add next year so we don't run out

* Update tests/components/holiday/test_init.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Cleanup

* Set default language in `__init__`

* Add strict typing

* Change default language: HA's language `en` is `en_US` in holidays, apart from Canada

* CONF_PROVINCE can be None

* Fix test

* Fix default_language

* Refactor tests

* Province can be None

* Add test for translated title

* Address feedback

* Address feedback

* Change test to use service call

* Address feedback

* Apply suggestions from code review

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Changes based on review feedback

* Update homeassistant/components/holiday/calendar.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Update homeassistant/components/holiday/calendar.py

Co-authored-by: G Johansson <goran.johansson@shiftit.se>

* Add a test if next event is missing

* Rebase

* Set device to service

* Remove not needed translation key

---------

Co-authored-by: G Johansson <goran.johansson@shiftit.se>
2023-12-03 16:28:53 +01:00