34 lines
853 B
TypeScript
Raw Normal View History

2024-11-08 18:53:30 +00:00
import { Button } from "tamagui";
import React from "react";
import Drawer from "expo-router/drawer";
import HostsList from "./components/hosts-list";
2024-11-09 10:33:07 +00:00
import HostForm, { hostFormModal } from "./components/form";
import Icons from "@/components/ui/icons";
import { initialValues } from "./schema/form";
2024-11-09 18:57:36 +00:00
import KeyForm from "../keychains/components/form";
2024-11-08 18:53:30 +00:00
export default function HostsPage() {
return (
<>
<Drawer.Screen
options={{
headerRight: () => (
2024-11-09 10:33:07 +00:00
<Button
bg="$colorTransparent"
icon={<Icons name="plus" size={24} />}
onPress={() => hostFormModal.onOpen(initialValues)}
$gtSm={{ mr: "$3" }}
>
New
2024-11-08 18:53:30 +00:00
</Button>
),
}}
/>
<HostsList />
2024-11-09 10:33:07 +00:00
<HostForm />
2024-11-09 18:57:36 +00:00
<KeyForm />
2024-11-08 18:53:30 +00:00
</>
);
}