25 lines
791 B
Python
25 lines
791 B
Python
from flask_wtf import FlaskForm
|
|
from wtforms import BooleanField, SelectField, SubmitField
|
|
|
|
|
|
THEME_CHOICES = (
|
|
("auto", "Use system setting"),
|
|
("light", "Light"),
|
|
("dark", "Dark"),
|
|
)
|
|
NOTIFICATION_CHOICES = (
|
|
("quiet", "Quiet — only essential reminders"),
|
|
("moderate", "Moderate — occasional reminders"),
|
|
("alert", "Alert — more visible reminders"),
|
|
)
|
|
|
|
|
|
class PreferencesForm(FlaskForm):
|
|
theme = SelectField("Color theme", choices=THEME_CHOICES)
|
|
dyslexia_font = BooleanField("Use a dyslexia-friendly reading style")
|
|
completion_chime = BooleanField("Play a gentle completion chime")
|
|
notification_frequency = SelectField(
|
|
"Future reminder frequency",
|
|
choices=NOTIFICATION_CHOICES,
|
|
)
|
|
submit = SubmitField("Save preferences")
|