app(
id = rustploy,
single_instance = true,
remember_geometry = true,
size = "1280 820",
min_size = "640 680",
icon = "views/assets/rustploy.png",
decorations = false,
font = "JetBrains Mono",
application_id = "rustploy-gui",
antialiasing = false,
toast_period = 250,
) {
resources {
link(rel = theme, href = "views/styles/theme.json")
link(rel = stylesheet, href = "views/styles/app.gss")
font(src = "assets/fonts/JetBrainsMono-Regular.ttf", family = "JetBrains Mono")
font(src = "assets/fonts/JetBrainsMono-Bold.ttf")
tray(icon = "views/assets/rustploy.png", tooltip = Rustploy) {
item(label = "Open Rustploy", on_click = tray:open)
check(label = Notifications, checked = @__notifications, on_click = notifications:toggle)
separator
item(label = "Quit Rustploy", on_click = tray:quit)
}
}
screen(name = app, initial = true, title = Rustploy) {
resources {
link(rel = import, href = login.component.gv, as = Login)
link(rel = import, href = shell.component.gv, as = Shell)
script(src = "scripts/app.luau")
}
column(class = screen) {
row(class = resize__top) {
column(class = "resize__corner resize__corner--nw", on_press = window:resize:nw)
column(class = resize__edge-h, on_press = window:resize:n)
column(class = "resize__corner resize__corner--ne", on_press = window:resize:ne)
}
row(class = resize__mid) {
column(class = resize__edge-v, on_press = window:resize:w)
column(class = resize__body) {
row(class = titlebar) {
row(
class = titlebar__drag,
on_press = window:drag,
on_double_click = window:maximize,
) {
text("●", class = titlebar__dot)
text("{t('common.rustploy')}", class = titlebar__title)
}
button(class = titlebar__btn, on_click = window:minimize, text = "—")
if @glacier_window_maximized {
button(class = titlebar__btn, on_click = window:maximize) {
container(class = titlebar__icon-box) {
svg(class = titlebar__icon, src = "assets/icons/win_restore.svg")
}
}
} else {
button(class = titlebar__btn, on_click = window:maximize) {
container(class = titlebar__icon-box) {
svg(
class = titlebar__icon,
src = "assets/icons/win_maximize.svg"
)
}
}
}
button(
class = "titlebar__btn titlebar__btn--close",
on_click = window:close,
text = "✕"
)
}
if @screen == "login" {
Login
} else {
Shell
}
}
column(class = resize__edge-v, on_press = window:resize:e)
}
row(class = resize__bottom) {
column(class = "resize__corner resize__corner--sw", on_press = window:resize:sw)
column(class = resize__edge-h, on_press = window:resize:s)
column(class = "resize__corner resize__corner--se", on_press = window:resize:se)
}
}
}
screen(name = log, src = "log_window.screen.gv")
screen(name = new_job, src = "new_job_window.screen.gv")
screen(name = new_service, src = "new_service_window.screen.gv")
screen(name = new_project, src = "new_project_form.screen.gv")
screen(name = new_registry_token, src = "new_registry_token_window.screen.gv")
screen(name = service_export, src = "service_export_window.screen.gv")
screen(name = services_reorder, src = "services_reorder_window.screen.gv")
}