import 'package:doctor_app_flutter/config/size_config.dart';
import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
import 'package:flutter/material.dart';

class HeaderRow extends StatelessWidget {
  final String label;
  final String value;
  final bool isExpanded;

  const HeaderRow({Key? key, required this.label, required this.value, this.isExpanded =  false}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Row(
      crossAxisAlignment: CrossAxisAlignment.start,
      children: [
        AppText(
          label,
          isCopyable: true,
          fontSize: SizeConfig.getTextMultiplierBasedOnWidth() * 3,
          color: Color(0xFF575757),
          fontWeight: FontWeight.w600,
        ),
        SizedBox(
          width: 1,
        ),
        isExpanded?Expanded(child: AppText(
          value,
          fontSize: SizeConfig.getTextMultiplierBasedOnWidth() * 3.5,
          color: Color(0xFF2E303A),
          fontWeight: FontWeight.w700,
          isCopyable: true,
        ), ):
        AppText(
          value,
          fontSize: SizeConfig.getTextMultiplierBasedOnWidth() * 3.5,
          color: Color(0xFF2E303A),
          fontWeight: FontWeight.w700,
          isCopyable: true,
        ),
      ],
    );
  }
}
