import 'package:flutter/material.dart';
import 'package:wyatt_ui_components/wyatt_wyatt_ui_components.dart';

class CustomBottomNavigationBar extends BottomNavigationBarComponent {
  const CustomBottomNavigationBar({
    super.currentIndex,
    super.onTap,
    super.key,
  });

  @override
  Widget build(BuildContext context) => BottomNavigationBar(
        currentIndex: currentIndex,
        onTap: (index) => super.onTap?.call(context, index),
        items: const [
          BottomNavigationBarItem(
            label: 'Icon 1',
            icon: Icon(
              Icons.nearby_off,
            ),
          ),
          BottomNavigationBarItem(
            label: 'Icon 2',
            icon: Icon(
              Icons.dangerous,
            ),
          ),
        ],
      );

  @override
  CustomBottomNavigationBar? configure({
    void Function(BuildContext, int)? onTap,
    int currentIndex = 0,
  }) =>
      CustomBottomNavigationBar(
        onTap: onTap ?? this.onTap,
        currentIndex: currentIndex,
      );
}
