PagerMaid-Pyro/pagermaid/web/pages/main.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

41 lines
1.3 KiB
Python
Raw Normal View History

2023-01-31 16:24:56 +00:00
from amis import App, PageSchema, Tpl, Page, Flex
from pagermaid.web.html import get_footer, get_github_logo
from pagermaid.web.pages.command_alias import page as command_alias_page
from pagermaid.web.pages.ignore_groups import page as ignore_groups_page
from pagermaid.web.pages.home_page import page as home_page
from pagermaid.web.pages.plugin_local_manage import page as plugin_local_manage_page
from pagermaid.web.pages.plugin_remote_manage import page as plugin_remote_manage_page
github_logo = Tpl(
2023-03-12 03:56:01 +00:00
className="w-full",
2023-01-31 16:24:56 +00:00
tpl=get_github_logo(),
)
2023-03-12 03:56:01 +00:00
header = Flex(
className="w-full", justify="flex-end", alignItems="flex-end", items=[github_logo]
)
2023-01-31 16:24:56 +00:00
admin_app = App(
2023-03-12 03:56:01 +00:00
brandName="pagermaid",
logo="https://xtaolabs.com/pagermaid-logo.png",
2023-01-31 16:24:56 +00:00
header=header,
pages=[
{
2023-03-12 03:56:01 +00:00
"children": [
2023-01-31 16:24:56 +00:00
home_page,
2023-03-12 03:56:01 +00:00
PageSchema(
label="Bot 设置",
icon="fa fa-wrench",
children=[command_alias_page, ignore_groups_page],
),
PageSchema(
label="插件管理",
icon="fa fa-cube",
children=[plugin_local_manage_page, plugin_remote_manage_page],
),
2023-01-31 16:24:56 +00:00
]
}
],
footer=get_footer(),
)
2023-03-12 03:56:01 +00:00
blank_page = Page(title="PagerMaid-Pyro 404", body="404")