118 lines
3.8 KiB
Dart
118 lines
3.8 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:footer/footer.dart';
|
|
import 'package:footer/footer_view.dart';
|
|
import 'package:url_launcher/url_launcher.dart';
|
|
import 'package:zontreck/Constants.dart';
|
|
import 'package:zontreck/pages/LoginAccount.dart';
|
|
import 'package:zontreck/pages/OpenSim.dart';
|
|
import 'package:zontreck/pages/Portfolio.dart';
|
|
import 'package:zontreck/pages/RegisterAccount.dart';
|
|
import 'package:zontreck/pages/libac.dart';
|
|
import 'package:zontreck/pages/nbt/NBTEditor.dart';
|
|
import 'package:zontreck/pages/shitbot.dart';
|
|
|
|
class MainPage extends StatelessWidget {
|
|
const MainPage({super.key});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return MaterialApp(
|
|
routes: {
|
|
"/": (context) => const HomePage(),
|
|
"/opensim": (context) => const OpenSimPage(),
|
|
"/opensim/register": (context) => const RegisterAccountPage(),
|
|
"/opensim/login": (context) => const LoginAccountPage(),
|
|
"/portfolio": (context) => const PortfolioPage(),
|
|
"/portfolio/coun": (context) => const CardsOfUtterNonsense(),
|
|
"/portfolio/libac": (context) => const LibACAbout(),
|
|
"/portfolio/nbteditor": (context) => AboutNBTEditor(),
|
|
"/shitbot": (context) => ShitBotProductPage()
|
|
},
|
|
theme: ThemeData.dark(),
|
|
);
|
|
}
|
|
}
|
|
|
|
class HomePage extends StatefulWidget {
|
|
const HomePage({super.key});
|
|
|
|
@override
|
|
HomePageState createState() => HomePageState();
|
|
}
|
|
|
|
class HomePageState extends State<HomePage> {
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Scaffold(
|
|
appBar: AppBar(
|
|
backgroundColor: Constants.TITLEBAR_COLOR,
|
|
title: const Text("Zontreck.com"),
|
|
),
|
|
body: FooterView(
|
|
footer: Footer(
|
|
alignment: Alignment.center,
|
|
backgroundColor: ThemeData.dark().focusColor,
|
|
child: const Text("${Constants.COPYRIGHT}\n${Constants.VERSION}")),
|
|
children: const [
|
|
Column(
|
|
children: [
|
|
Center(
|
|
child: ListTile(
|
|
title: Text(
|
|
"Zontreck.com is owned by, and operated by, Piccari Creations")),
|
|
),
|
|
ListTile(
|
|
title: Text(
|
|
"This site acts as both my portfolio, and as a portal to various different parts of my server"),
|
|
),
|
|
Text("Thank you for visiting"),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
drawer: Drawer(
|
|
elevation: 8,
|
|
backgroundColor: Constants.DRAWER_COLOR,
|
|
child: Column(
|
|
children: [
|
|
const DrawerHeader(
|
|
child: Column(
|
|
children: [
|
|
Text("Zontreck.com"),
|
|
Text(""),
|
|
Text("Copyright 2024"),
|
|
Text("Piccari Creations")
|
|
],
|
|
)),
|
|
ListTile(
|
|
title: const Text("O P E N S I M"),
|
|
leading: const Icon(Icons.front_hand_outlined),
|
|
subtitle:
|
|
const Text("OpenSim management interface for private grid"),
|
|
onTap: () {
|
|
Navigator.pushNamed(context, "/opensim");
|
|
},
|
|
),
|
|
ListTile(
|
|
title: const Text("P O R T F O L I O"),
|
|
subtitle: const Text("View my work"),
|
|
leading: const Icon(Icons.book_online),
|
|
onTap: () {
|
|
Navigator.pushNamed(context, "/portfolio");
|
|
},
|
|
),
|
|
ListTile(
|
|
title: Text("J E N K I N S"),
|
|
subtitle: Text("CI/CD Server"),
|
|
leading: Icon(Icons.build),
|
|
onTap: () async {
|
|
await launchUrl(
|
|
Uri(host: "ci.zontreck.com", port: 443, scheme: "https"));
|
|
},
|
|
)
|
|
],
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|