package com.isidroid.c23.ext

import androidx.compose.ui.graphics.Color
import com.isidroid.c23.BuildConfig
import com.isidroid.c23.constant.AppBuildType
import com.isidroid.c23.data.source.settings.Settings
import kotlin.random.Random

fun isStage() = Settings.buildType == AppBuildType.STAGE
fun isDev() = Settings.buildType == AppBuildType.DEV
fun isMock() = Settings.buildType == AppBuildType.MOCK

fun isDebug() = BuildConfig.DEBUG || isDev() || isStage() || isMock()

fun randomColor(): Color {
    val random = Random.Default
    return Color(
        red = random.nextFloat(),
        green = random.nextFloat(),
        blue = random.nextFloat(),
        alpha = 1.0f
    )
}