DayInfo

data class DayInfo(val label: String?, val isHoliday: Boolean = false, val tags: List<String> = emptyList(), val priority: Int = DayInfoPriority.DEFAULT, val colorArgb: Long? = null, val payload: Any? = null)

Secondary information for one day, returned by DayInfoProvider.info.

Constructors

Link copied to clipboard
constructor(label: String?, isHoliday: Boolean = false, tags: List<String> = emptyList(), priority: Int = DayInfoPriority.DEFAULT, colorArgb: Long? = null, payload: Any? = null)

Properties

Link copied to clipboard

Optional label color as a packed 0xAARRGGBB ARGB value (for example 0xFFC62828), or null to use the theme color. The alpha byte is required: a 24-bit 0xRRGGBB value has alpha 0x00 and is fully transparent.

Link copied to clipboard

Whether the day is a holiday (rendered with the holiday label color).

Link copied to clipboard

Short text shown under the day number, or null for none.

Link copied to clipboard
val payload: Any?

Arbitrary data attached by the provider (for example LunarDayMetadata from orrery-lunar), passed through unchanged. Read it with payloadAs.

Link copied to clipboard

Precedence when providers are combined with DayInfoProvider.plus: the entry with the higher value supplies label, colorArgb and payload. Use the tiers in DayInfoPriority; defaults to DayInfoPriority.DEFAULT.

Link copied to clipboard

Free-form tags for filtering or styling.

Functions

Link copied to clipboard
inline fun <T> DayInfo.payloadAs(): T?

Type-safe extraction of DayInfo.payload, returning null if absent or of a different type.