package com.kaixed.kchat.ui.activity

import android.os.Bundle
import androidx.activity.enableEdgeToEdge
import androidx.appcompat.app.AppCompatActivity
import androidx.constraintlayout.widget.ConstraintSet
import com.kaixed.kchat.databinding.ActivityContactUpdatesBinding
import com.kaixed.kchat.utils.DensityUtil

class ContactUpdatesActivity : AppCompatActivity() {
    private lateinit var binding: ActivityContactUpdatesBinding
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        enableEdgeToEdge()
        binding = ActivityContactUpdatesBinding.inflate(layoutInflater)
        setContentView(binding.root)

        val constraintSet = ConstraintSet()
        constraintSet.clone(binding.main)

        constraintSet.connect(
            binding.ifvAvatar.id,
            ConstraintSet.START,
            ConstraintSet.PARENT_ID,
            ConstraintSet.START,
            DensityUtil.dpToPx(this, 10)
        )

        constraintSet.connect(
            binding.tvContent.id,
            ConstraintSet.START,
            binding.ifvAvatar.id,
            ConstraintSet.END,
            DensityUtil.dpToPx(this, 10)
        )
        constraintSet.applyTo(binding.main)
    }
}
