// import 'package:crab_ui/email.dart'; import 'api_service.dart'; import 'package:flutter/material.dart'; import 'email.dart'; import 'api_service.dart'; import 'dart:html' as html; import 'dart:ui_web' as ui; class HomeScreen extends StatefulWidget { @override _HomeScreenState createState() => _HomeScreenState(); } class _HomeScreenState extends State { @override void initState() { super.initState(); // // Register the HTML element ui.platformViewRegistry.registerViewFactory( 'html-view11', (int viewId) => html.IFrameElement() ..width = '100%' ..height = '100%' ..srcdoc = r""" There's no time to waste: Find your size!
sort by [author] [dates] [subjects]

There's no time to waste: Find your size! Atom Feed

Back
There's no time to waste: Find your size!
From: "GLOBO" <globoshoes@mailing.globoshoes.com>
Date: 2023-12-30T23:00:48+01:00
More Message-Id: 0.0.D.710.1DA3B6BA55A6D60.0@mta-2d567751.ip4.emsmtp.com
To: <sokolovskiiyura@gmail.com>
Reply [Export]
""" ..style.border = 'none', ); } bool _isSidebarOpen = true; @override Widget build(BuildContext context) { return Scaffold( body: Stack( children: [ Row( children: [ // Sidebar if (_isSidebarOpen) Container( width: 70, color: Color.fromARGB(17, 96, 122, 135), child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ ListTile( leading: Icon(Icons.home), onTap: () { // Navigate to Home }, ), ListTile( leading: Icon(Icons.settings), onTap: () { // Navigate to Settings }, ), ListTile( leading: Icon(Icons.email), onTap: () { Navigator.push( context, MaterialPageRoute( builder: (context) => EmailPage()), ); }, ), Spacer(), Padding( padding: const EdgeInsets.all(8.0), child: Align( alignment: Alignment.bottomLeft, child: IconButton( icon: Icon(Icons.close, color: Colors.white), onPressed: () { setState(() { _isSidebarOpen = false; }); }, ), ), ), ], ), ), // Main content Expanded( child: Column( children: [ Container( padding: EdgeInsets.fromLTRB(8.0, 8.0, 8.0, 4.0), color: Color.fromARGB(42, 36, 102, 132), child: Row( mainAxisAlignment: MainAxisAlignment.center, children: [ Container( width: 800, height: 40, child: TextField( decoration: InputDecoration( hintText: 'Search...', border: OutlineInputBorder(), prefixIcon: Icon(Icons.search), ), ), ), ], ), ), Container( padding: EdgeInsets.all(0.0), color: Color.fromARGB(42, 36, 102, 132), child: Row( children: [ Container( height: 2, ) ], ), ), Container( padding: EdgeInsets.all(8.0), color: Colors.white, child: Row( children: [ Container( child: Text('hiiiiiii'), ), ], ), ), Container( child: Expanded( // child: EmailPage(), child: HtmlElementView(viewType: 'html-view11',),), ), // Expanded( // child: Center( // child: EmailPage(), // ), // ) ], ), ), ], ), if (!_isSidebarOpen) Positioned( bottom: 16, left: 16, child: FloatingActionButton( child: Icon(Icons.menu), onPressed: () { setState(() { _isSidebarOpen = true; }); }, ), ), ], ), ); } }