Added classes to support formatting

This commit is contained in:
2026-01-26 21:32:26 +01:00
parent 3083f3b1fd
commit 9abb9dddfe
14 changed files with 2059 additions and 21 deletions

View File

@@ -0,0 +1,76 @@
# === Style Presets (DaisyUI 5) ===
# Keys use CSS property names (with hyphens)
DEFAULT_STYLE_PRESETS = {
"primary": {
"background-color": "var(--color-primary)",
"color": "var(--color-primary-content)",
},
"secondary": {
"background-color": "var(--color-secondary)",
"color": "var(--color-secondary-content)",
},
"accent": {
"background-color": "var(--color-accent)",
"color": "var(--color-accent-content)",
},
"neutral": {
"background-color": "var(--color-neutral)",
"color": "var(--color-neutral-content)",
},
"info": {
"background-color": "var(--color-info)",
"color": "var(--color-info-content)",
},
"success": {
"background-color": "var(--color-success)",
"color": "var(--color-success-content)",
},
"warning": {
"background-color": "var(--color-warning)",
"color": "var(--color-warning-content)",
},
"error": {
"background-color": "var(--color-error)",
"color": "var(--color-error-content)",
},
}
# === Formatter Presets ===
DEFAULT_FORMATTER_PRESETS = {
"EUR": {
"type": "number",
"suffix": "",
"thousands_sep": " ",
"decimal_sep": ",",
"precision": 2,
},
"USD": {
"type": "number",
"prefix": "$",
"thousands_sep": ",",
"decimal_sep": ".",
"precision": 2,
},
"percentage": {
"type": "number",
"suffix": "%",
"precision": 1,
"multiplier": 100,
},
"short_date": {
"type": "date",
"format": "%d/%m/%Y",
},
"iso_date": {
"type": "date",
"format": "%Y-%m-%d",
},
"yes_no": {
"type": "boolean",
"true_value": "Yes",
"false_value": "No",
},
}