1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
// General (source / build, editável)
component {
resources {
link(rel = import, href = "general_compose.gv", as = GeneralCompose)
link(rel = import, href = "general_git.gv", as = GeneralGit)
link(rel = import, href = "general_zip.gv", as = GeneralZip)
link(rel = import, href = "general_gitea.gv", as = GeneralGitea)
}
scrollable(
direction = vertical,
class = u-fill-all,
) {
// O scrollable só renderiza o PRIMEIRO filho: os forms ficam numa coluna.
column(width = fill, spacing = 12) {
column(class = form-panel, if = @service_loading, equals = true) {
if @service_loading == "true" {
LoadingRow(note = "{t('general.loading_service_data')}")
}
}
form(
if = @service_loading,
not_equals = true,
name = general,
on_submit = general_save,
class = form-panel,
) {
// Serviços Compose (bancos/brokers) editam o YAML direto; não têm
// provider Git/Registry.
if @service_source_kind == "Compose" {
GeneralCompose
}
// Provider Git/conta-conectada/Zip — apenas para serviços não-Compose.
if @service_source_kind != "Compose" {
text("{t('general.provider')}", class = u-label-cap)
scroll(class = tabs__scroll, direction = horizontal) {
row(class = tabs__main) {
TabButton(
label = "{t('common.git')}",
current = @provider_tab,
target = git,
action = select_provider_tab:git,
)
template(if = @gitea_providers, not_empty) {
TabButton(
label = "{t('general.gitea_github')}",
current = @provider_tab,
target = gitea,
action = select_provider_tab:gitea,
)
}
TabButton(
label = "{t('general.zip')}",
current = @provider_tab,
target = zip,
action = select_provider_tab:zip,
)
}
}
hr
// ── Sub-aba Git: form de URL/imagem crua ───────────────
if @provider_tab == "git" {
GeneralGit
}
// ── Sub-aba Zip: upload de arquivo local com Dockerfile na raiz ─
if @provider_tab == "zip" {
GeneralZip
}
// ── Sub-aba conta conectada (Gitea/GitHub): picker conta/repo/branch ─
if @provider_tab == "gitea" {
GeneralGitea
}
}
}
}
}
}