export default (configuration) => {
    return `
    
    package ${configuration.packageName}.adapters 

   
    import ${configuration.name}.databinding.ItemBroadcastVideoBinding
    import android.view.LayoutInflater
    import android.view.ViewGroup
    import androidx.recyclerview.widget.RecyclerView
    import ${configuration.packageName}.model.remote.GetVideoListResponse


    class VideosAdapter(var list: List<GetVideoListResponse>) :
    RecyclerView.Adapter<VideosAdapter.ViewHolderItem>() {
    override fun onCreateViewHolder(viewGroup: ViewGroup, i: Int): ViewHolderItem {
        val binding =
            ItemBroadcastVideoBinding.inflate(LayoutInflater.from(viewGroup.context), viewGroup, false)
        return ViewHolderItem(binding)
    }

    override fun onBindViewHolder(viewHolderItem: ViewHolderItem, i: Int) {
        val category = list[i]

        //viewHolderItem.binding.imageView.loadImageFromUrl(category.video_url)
        viewHolderItem.binding.tvName.text = category.title
        viewHolderItem.binding.tvCountry.text = ""
        viewHolderItem.binding.tvUploadTime.text = category.update_at
        viewHolderItem.binding.tvPrice.text = category.price

    }

    override fun getItemCount(): Int {
        return list.size
    }

    inner class ViewHolderItem(var binding: ItemBroadcastVideoBinding) : RecyclerView.ViewHolder(
        binding.root
    )

    fun updateData(newData: List<GetVideoListResponse>) {
        list = newData
        notifyDataSetChanged()
    }
}
    
    
    
      `;
  };
  