package com.gh.gamecenter.entity

import android.graphics.Color
import com.gh.gamecenter.common.entity.LinkEntity
import com.gh.gamecenter.feature.exposure.ExposureEvent
import com.google.gson.annotations.SerializedName

data class MultiTabNav(
    @SerializedName("_id")
    val id: String = "",
    val title: String = "",
    @SerializedName("link_multi_tab_nav")
    private val _linkMultiTabNav: List<LinkMultiTabNav>?
) {

    val linkMultiTabNav:List<LinkMultiTabNav>
        get() = _linkMultiTabNav?: emptyList()

    data class LinkMultiTabNav(
        @SerializedName("_id")
        val id: String = "",
        val name: String = "",
        val img: String = "",
        @SerializedName("tab_show_img")
        var showImgOnSelected: Boolean? = false, // 选中时是否显示图片
        @SerializedName("is_default_page")
        var default: Boolean = false, // 是否为默认显示页
        val link: LinkEntity? = null, // 通用链接
        var guide: BottomTab.Guide? = null, // 引导文案

        // 本地字段
        var style: TabStyle = TabStyle(),
        var showPullDownPush: Boolean = false,
        var exposureEvent: ExposureEvent? = null, // 绑定的曝光实体
    ) {
        data class TabStyle(
            var useLightStyle: Boolean = false,
            var primaryColor: Int = Color.WHITE,
            var offsetRatio: Float = 0F,
            var currentSelectColor: Int = 0,
            var isSlideBackgroundColorEnable: Boolean = false, // 是否启用首页轮播图背景颜色
            var isSlideBackgroundColorShow: Boolean = false, // 是否正在显示首页轮播图背景颜色
        )
    }
}