appbar method

Widget appbar({
  1. required void backArrowAction()?,
  2. required void deleteButtonAction()?,
  3. required void onShareButtonAction()?,
})

Implementation

Widget appbar(
    {required void Function()? backArrowAction,
    required void Function()? deleteButtonAction,
    required void Function()? onShareButtonAction}) {
  return Padding(
    padding: const EdgeInsets.only(left: 10.0, right: 10.0, top: 10.0),
    child: Row(
      mainAxisAlignment: MainAxisAlignment.spaceBetween,
      children: [
        buttons(
            onPressed: backArrowAction,
            icon: Icon(
              Icons.arrow_back,
              color: iconColor,
              size: iconSize,
            ),
            shadowColor: Colors.black54),
        Row(
          children: [
            if (!kIsWeb)
              buttons(
                onPressed: onShareButtonAction,
                icon: Icon(
                  Icons.share,
                  color: iconColor,
                  size: iconSize,
                ),
                shadowColor: Colors.black54,
              ),
            buttons(
                onPressed: deleteButtonAction,
                icon: Icon(
                  Icons.delete_sharp,
                  color: iconColor,
                  size: iconSize,
                ),
                shadowColor: Colors.black54),
          ],
        ),
      ],
    ),
  );
}