import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/buttons/borderedButton.dart';
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
import 'package:flutter/material.dart';

class ViewAllHomeWidget extends StatelessWidget {
  final String title;
  final Widget navigationWidget;

  ViewAllHomeWidget(this.title, this.navigationWidget);

  @override
  Widget build(BuildContext context) {
    return Container(
      margin: EdgeInsets.fromLTRB(16, 10, 16, 10),
      child: Row(
        mainAxisAlignment: MainAxisAlignment.spaceBetween,
        children: [
          Texts(
            title,
            color: Color(0xff2E303A),
            fontWeight: FontWeight.w700,
            fontSize: 19,
          ),
          InkWell(
            onTap: () {
              Navigator.push(context,
                  MaterialPageRoute(builder: (context) => navigationWidget));
            },
            child: Texts(
              TranslationBase.of(context).viewAll,
              color: Color(0xffD02127),
              decoration: TextDecoration.underline,
              fontWeight: FontWeight.w600,
              fontSize: 12.0,
            ),
          ),
          // BorderedButton(
          //   TranslationBase.of(context).viewAll,
          //   hasBorder: true,
          //   borderColor: Colors.green,
          //   textColor: Colors.green,
          //   fontWeight: FontWeight.bold,
          //   vPadding: 6,
          //   hPadding: 14,
          //   handler: () {
          //     Navigator.push(context,
          //         MaterialPageRoute(builder: (context) => navigationWidget));
          //   },
          // ),
        ],
      ),
    );
  }
}
