package com.zaojiao.app.feat.home.personal

import androidx.compose.foundation.Image
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.geometry.Size
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import com.zaojiao.app.feat.home.R
import com.zaojiao.component.common.Colors
import com.zaojiao.component.common.Icons
import com.zaojiao.component.common.Spacer

@Composable
fun HomePersonalUserBar() {
    Row(
        modifier = Modifier
            .padding(bottom = 9.dp)
            .padding(top = 16.dp)
            .padding(horizontal = 16.dp),
        verticalAlignment = Alignment.CenterVertically,
    ) {
        Image(
            painter = painterResource(id = R.mipmap.default_avatar),
            contentDescription = "用户头像",
            modifier = Modifier.size(70.dp, 70.dp)
        )
        Spacer(width = 12.dp)
        Text(
            text = "逻辑狗",
            modifier = Modifier.weight(1f),
            style = TextStyle(
                fontSize = 18.sp,
                lineHeight = 18.sp,
                fontWeight = FontWeight.Medium,
                color = Colors.FF000000,
            ),
        )
        Text(
            text = "个人主页",
        )
        Spacer(width = 7.dp)
        Icons.Forward(
            size = Size(5f, 8f),
            color = Colors.FF999999,
            width = 1.dp,
        )
    }
}
