import 'package:flutter/material.dart';

class ClickableAppBar extends StatelessWidget implements PreferredSizeWidget {
  final VoidCallback onTap;
  final AppBar appBar;
  const ClickableAppBar({required this.onTap, required this.appBar, super.key});

  @override
  Widget build(BuildContext context) =>
      GestureDetector(onTap: onTap, child: appBar);

  @override
  Size get preferredSize => appBar.preferredSize;
}
