mirror of
https://github.com/jpawlowski/hass.tibber_prices.git
synced 2026-07-28 09:36:49 +00:00
Compare commits
No commits in common. "9efa7809d02ea274727f49acff88df765d7fc83a" and "27ab58bbf500d40c136cddc45ab0ae0d9bb1ff47" have entirely different histories.
9efa7809d0
...
27ab58bbf5
6 changed files with 9 additions and 13 deletions
2
.github/workflows/auto-assign.yml
vendored
2
.github/workflows/auto-assign.yml
vendored
|
|
@ -14,7 +14,7 @@ jobs:
|
||||||
issues: write
|
issues: write
|
||||||
steps:
|
steps:
|
||||||
- name: Assign issue to owner
|
- name: Assign issue to owner
|
||||||
uses: actions/github-script@v9
|
uses: actions/github-script@v7
|
||||||
with:
|
with:
|
||||||
script: |
|
script: |
|
||||||
await github.rest.issues.addAssignees({
|
await github.rest.issues.addAssignees({
|
||||||
|
|
|
||||||
4
.github/workflows/docusaurus.yml
vendored
4
.github/workflows/docusaurus.yml
vendored
|
|
@ -54,7 +54,7 @@ jobs:
|
||||||
|
|
||||||
# VERIFY GENERATED DOCS
|
# VERIFY GENERATED DOCS
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
uses: actions/setup-python@v6
|
uses: actions/setup-python@v5
|
||||||
with:
|
with:
|
||||||
python-version: '3.14'
|
python-version: '3.14'
|
||||||
|
|
||||||
|
|
@ -163,7 +163,7 @@ jobs:
|
||||||
uses: actions/configure-pages@v6
|
uses: actions/configure-pages@v6
|
||||||
|
|
||||||
- name: Upload artifact
|
- name: Upload artifact
|
||||||
uses: actions/upload-pages-artifact@v5
|
uses: actions/upload-pages-artifact@v4
|
||||||
with:
|
with:
|
||||||
path: ./deploy-root
|
path: ./deploy-root
|
||||||
|
|
||||||
|
|
|
||||||
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
|
|
@ -255,7 +255,7 @@ jobs:
|
||||||
|
|
||||||
- name: Create GitHub Release
|
- name: Create GitHub Release
|
||||||
if: steps.version_check.outputs.warning == ''
|
if: steps.version_check.outputs.warning == ''
|
||||||
uses: softprops/action-gh-release@v3
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
name: ${{ steps.release_notes.outputs.title }}
|
name: ${{ steps.release_notes.outputs.title }}
|
||||||
body: ${{ steps.release_notes.outputs.notes }}
|
body: ${{ steps.release_notes.outputs.notes }}
|
||||||
|
|
|
||||||
|
|
@ -65,14 +65,10 @@ def get_icon_color(
|
||||||
return BINARY_SENSOR_COLOR_MAPPING[key].get(state_key)
|
return BINARY_SENSOR_COLOR_MAPPING[key].get(state_key)
|
||||||
|
|
||||||
# Trend sensor colors (based on trend state)
|
# Trend sensor colors (based on trend state)
|
||||||
if (
|
if key.startswith("price_trend_") and isinstance(state_value, str):
|
||||||
key.startswith(("price_trend_", "price_outlook_", "price_trajectory_")) or key == "current_price_trend"
|
|
||||||
) and isinstance(state_value, str):
|
|
||||||
trend_colors = {
|
trend_colors = {
|
||||||
"strongly_rising": "var(--error-color)",
|
|
||||||
"rising": "var(--error-color)", # Red/Orange for rising prices
|
"rising": "var(--error-color)", # Red/Orange for rising prices
|
||||||
"falling": "var(--success-color)", # Green for falling prices
|
"falling": "var(--success-color)", # Green for falling prices
|
||||||
"strongly_falling": "var(--success-color)",
|
|
||||||
"stable": "var(--state-icon-color)", # Default gray for stable
|
"stable": "var(--state-icon-color)", # Default gray for stable
|
||||||
}
|
}
|
||||||
return trend_colors.get(state_value)
|
return trend_colors.get(state_value)
|
||||||
|
|
|
||||||
|
|
@ -91,7 +91,7 @@ def get_trend_icon(key: str, value: Any) -> str | None:
|
||||||
if key == "next_price_trend_change":
|
if key == "next_price_trend_change":
|
||||||
return None # Will be handled by sensor's icon property using attributes
|
return None # Will be handled by sensor's icon property using attributes
|
||||||
|
|
||||||
if not key.startswith(("price_trend_", "price_outlook_", "price_trajectory_")) and key != "current_price_trend":
|
if not key.startswith("price_trend_") and key != "current_price_trend":
|
||||||
return None
|
return None
|
||||||
|
|
||||||
if not isinstance(value, str):
|
if not isinstance(value, str):
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@ markers = [
|
||||||
|
|
||||||
[project.optional-dependencies]
|
[project.optional-dependencies]
|
||||||
test = [
|
test = [
|
||||||
"pytest>=9.0.3",
|
"pytest>=8.0.0",
|
||||||
"pytest-asyncio>=1.3.0",
|
"pytest-asyncio>=0.23.0",
|
||||||
"pytest-homeassistant-custom-component>=0.13.323",
|
"pytest-homeassistant-custom-component>=0.13.0",
|
||||||
]
|
]
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue