Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions app/presets.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@

log = logging.getLogger(__name__)

ORANGE = (255, 152, 0, 0)
ORANGE = (255, 126, 0, 0)
PURPLE = (128, 0, 255, 0)
RED = (255, 0, 0, 0)
GREEN = (0, 255, 0, 0)
WHITE = (0, 0, 0, 255)
BLUE = (0, 0, 255, 0)
YELLOW = (255, 236, 0, 0)


def default_presets() -> dict[str, Pattern]:
Expand All @@ -27,7 +28,13 @@ def default_presets() -> dict[str, Pattern]:
load with both sliders at the far left.
"""
return {
"Halloween": Pattern(slots=[Slot(rgbw=ORANGE, weight=80), Slot(rgbw=PURPLE, weight=20)]),
"Halloween": Pattern(
slots=[
Slot(rgbw=ORANGE, weight=80),
Slot(rgbw=PURPLE, weight=15),
Slot(rgbw=YELLOW, weight=5),
]
),
"Christmas": Pattern(
slots=[
Slot(rgbw=RED, weight=40),
Expand Down
15 changes: 15 additions & 0 deletions docs/releases/0.5.1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
Halloween gets a little yellow.

## What's changed

- **The built-in Halloween preset now has three colors:** a deeper orange (80%), purple (15%) and a touch of yellow (5%), where it used to be just orange and purple.

New installs start with the new Halloween. If you already run Dapple, your presets stay exactly as you left them, including Halloween. To get the new one, open Halloween in the pattern editor, add a yellow color, set the shares to 80, 15 and 5, and save it over the old one.

## Upgrading

`docker compose up -d` picks this up if you have `pull_policy: always`. Otherwise run `docker compose pull && docker compose up -d`. Your settings and saved presets carry over. To stay on this release, set the image line to:

```yaml
image: afraley/dapple:0.5.1
```
Binary file modified docs/ui.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "dapple-ui",
"private": true,
"license": "MIT",
"version": "0.5.0",
"version": "0.5.1",
"type": "module",
"scripts": {
"dev": "vite",
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "dapple"
version = "0.5.0"
version = "0.5.1"
description = "Static multi-color patterns for Twinkly light strands, with a REST API for Home Assistant"
requires-python = ">=3.12"
dependencies = [
Expand Down
4 changes: 2 additions & 2 deletions tests/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from app.config import AppConfig, ConfigStore, DeviceConfig, MqttConfig, load_config
from app.main import app
from app.models import DeviceInfo, DeviceResult, StrandSegment
from app.presets import PresetStore
from app.presets import PresetStore, default_presets
from app.state import StateStore

PATTERN = {
Expand Down Expand Up @@ -432,7 +432,7 @@ def test_apply_a_preset_to_a_group(client, manager):

assert body["ok"] is True
assert manager.applied[0][0] == "tree"
assert len(manager.applied[0][1].slots) == 2
assert manager.applied[0][1] == default_presets()["Halloween"]


def test_applying_a_preset_records_its_name(client):
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading