import 'package:flutter/material.dart';
import 'package:mohem_flutter_app/classes/colors.dart';
import 'package:mohem_flutter_app/extensions/int_extensions.dart';
import 'package:mohem_flutter_app/extensions/string_extensions.dart';
import 'package:mohem_flutter_app/extensions/widget_extensions.dart';

class ItemDetailView extends StatelessWidget {
  final String title;
  final String value;
  const ItemDetailView(this.title, this.value, {Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Row(
      crossAxisAlignment: CrossAxisAlignment.start,
      children: [
        "$title:".toText12(isBold: true, color: const Color(0xff2D3238)),
        6.width,
        (value.isEmpty ? "--" : value).toText12(color: MyColors.normalTextColor).expanded,
      ],
    );
  }
}
