cryptic-clock/src/pkjs/config.js
2025-12-13 19:18:16 +01:00

72 lines
1.7 KiB
JavaScript

module.exports = [
{
type: "section",
items: [
{
type: "heading",
defaultValue: "Colors",
},
{
label: "Background Color",
messageKey: "BACKGROUND_COLOR",
type: "color",
defaultValue: "#FFFFFF",
allowGray: true,
},
{
label: "Digit Color",
messageKey: "DIGIT_COLOR",
type: "color",
defaultValue: "#000000",
allowGray: true,
},
{
label: "Frame Color",
messageKey: "FRAME_COLOR",
type: "color",
defaultValue: "#00000",
allowGray: true,
},
]
},
{
type: "section",
items: [
{
type: "heading",
defaultValue: "Time Format",
},
{
label: "Time Format",
messageKey: "TIME_FORMAT_OVERRIDE",
type: "select",
options: [
{label: "Use system", value: 0},
{label: "12 hour", value: 12},
{label: "24 hour", value: 24},
],
defaultValue: 0,
},
{
label: "12h Range",
description: "Most people want '1:00 to 12:59'. Some countries use '0:00 to 11:59' instead.",
messageKey: "12H_START",
type: "select",
options: Array.from({length: 12}, (_, i) => ({value: i, label: `${i}:00 to ${i + 11}:59`})),
defaultValue: 1,
},
{
label: "24h Range",
description: "Most people want '0:00 to 23:59'.",
messageKey: "24H_START",
type: "select",
options: Array.from({length: 24}, (_, i) => ({value: i, label: `${i}:00 to ${i + 23}:59`})),
defaultValue: 0,
},
]
},
{
type: "submit",
defaultValue: "Save Settings",
},
];