import 'package:flutter/material.dart';
import 'package:flutter_bloc/flutter_bloc.dart';
import 'package:tanami_app/features/MainScreens/Invest/presentation/bloc/tab_bloc.dart';
import 'package:tanami_app/features/MainScreens/Portfolio/presentation/bloc/carousel/carousel_bloc.dart';

import '../../../../../core/styles/app_color.dart';
import '../../../../../core/styles/app_text.dart';
import '../../../../../shared/components/text_widget.dart';
import 'invest_layout.dart';

class InvestScreen extends StatefulWidget {
  const InvestScreen({super.key});

  @override
  State<InvestScreen> createState() => _InvestScreenState();
}

class _InvestScreenState extends State<InvestScreen> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: AppColor.plainWhite,
      appBar: AppBar(
        centerTitle: false,
        backgroundColor: AppColor.plainWhite,
        elevation: 0,
        scrolledUnderElevation: 0,
        automaticallyImplyLeading: false,
        title: TextWidget().text22W700(
          AppText.investText,
          clr: AppColor.charcoalColor,
        ),
        titleSpacing: 16,
      ),
      body: MultiBlocProvider(
        providers: [
          BlocProvider(
            // Create an instance of the OnboardingBloc
            create: (context) => TabBloc(),
          ),
          BlocProvider(
            // Create an instance of the OnboardingBloc
            create: (context) => CarouselBloc(),
          ),
        ],
        child: const InvestLayout(),
      ),
    );
  }
}
