-
Notifications
You must be signed in to change notification settings - Fork 70
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added OptionFlow and fixed formatting and typing issues (#316)
* Added OptionsFlow support * Formatted code * Corrected and added typing * Removed linting errors where possible * Added VSCode configuration files
- Loading branch information
Showing
11 changed files
with
326 additions
and
203 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,12 @@ | ||
.vscode | ||
/.vscode/* | ||
.vs | ||
**/__pycache__ | ||
/dist | ||
/build | ||
*.egg-info | ||
*.egg-info | ||
|
||
/config | ||
/.venv | ||
|
||
!/.vscode/settings.json | ||
!/.vscode/launch.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "Python Debugger: HomeAssistant", | ||
"type": "debugpy", | ||
"request": "launch", | ||
"module": "homeassistant", | ||
"args": [ | ||
"-v", | ||
"-c", | ||
"config" | ||
] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"cSpell.words": [ | ||
"hass" | ||
] | ||
} |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,29 @@ | ||
"""Constants for the Emporia Vue integration.""" | ||
|
||
import homeassistant.helpers.config_validation as cv | ||
import voluptuous as vol | ||
from homeassistant.const import CONF_EMAIL, CONF_PASSWORD | ||
|
||
DOMAIN = "emporia_vue" | ||
VUE_DATA = "vue_data" | ||
ENABLE_1S = "enable_1s" | ||
ENABLE_1M = "enable_1m" | ||
ENABLE_1D = "enable_1d" | ||
ENABLE_1MON = "enable_1mon" | ||
|
||
DOMAIN_SCHEMA = vol.Schema( | ||
{ | ||
vol.Required(CONF_EMAIL): cv.string, | ||
vol.Required(CONF_PASSWORD): cv.string, | ||
vol.Optional(ENABLE_1M, default=True): cv.boolean, # type: ignore | ||
vol.Optional(ENABLE_1D, default=True): cv.boolean, # type: ignore | ||
vol.Optional(ENABLE_1MON, default=True): cv.boolean, # type: ignore | ||
} | ||
) | ||
|
||
CONFIG_SCHEMA = vol.Schema( | ||
{ | ||
DOMAIN: DOMAIN_SCHEMA, | ||
}, | ||
extra=vol.ALLOW_EXTRA, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.