#pragma once
#include "configobject.hpp"
#include <qqmlintegration.h>

namespace ZShell::config {

class Nightlight : public ConfigObject {
	Q_OBJECT
	QML_ANONYMOUS

	CFG_PROPERTY(bool, schedule, true)
	CFG_PROPERTY(int, scheduleStart, 1200)
	CFG_PROPERTY(int, scheduleEnd, 570)
	CFG_PROPERTY(bool, useNative, true)
	CFG_PROPERTY(int, fadeDuration, 2000)
	CFG_PROPERTY(int, temp, 2600)

	public:
	explicit Nightlight(QObject* parent = nullptr) : ConfigObject(parent) {}
};

class Display : public ConfigObject {
	Q_OBJECT
	QML_ANONYMOUS

	CONFIG_SUBOBJECT(Nightlight, nightlight)

	public:
	explicit Display(QObject* parent = nullptr)
		: ConfigObject(parent), m_nightlight(new Nightlight(this)) {}
};

} // namespace ZShell::config
