import 'package:krow/core/presentation/widgets/ui_kit/kw_dropdown.dart';

extension StringExtensions on String {
  String capitalize() {
    if (isEmpty) return this;
    return this[0].toUpperCase() + substring(1).toLowerCase();
  }
}

extension StringToDropdownItem on String {
  KwDropDownItem<String>? toDropDownItem() {
    if (isEmpty) return null;

    return KwDropDownItem(data: this, title: this);
  }
}
