- Pin Dockerfile to Go 1.23 to match go.mod - Record README front-door audit findings
65 lines
3.2 KiB
HTML
65 lines
3.2 KiB
HTML
{{- /* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial */ -}}
|
|
{{- /* SPDX-FileCopyrightText: 2025-2026 Christian Galo */ -}}
|
|
|
|
{{/* operator_integration_settings.html
|
|
Integration settings: one generic template for every installed
|
|
integration, rendered from its declared ConfigSpec below the
|
|
Integrations trail. Every key, secret ones included, is a row of one
|
|
declared form (operator.integration.settings, form-library, spec
|
|
integration-settings) rendered through the form part in the Table
|
|
family: the key and its usage in the first column, the effective
|
|
value and the winning source in the two cells this file renders, the
|
|
control last, and one Save below the table (design D21). A secret key
|
|
is a static row: it states where the value is set and offers no
|
|
control, which is why there is no second table below the form any
|
|
more. Overrides apply on restart; the Pending-restart badge marks a
|
|
row whose stored state differs from the boot-effective value.
|
|
|
|
A row keeps to its subject (design D9, typed-config-keys): the
|
|
Effective cell (settingsEffectiveCell) holds the value in force alone,
|
|
and the Source cell (settingsSourceCell) holds its badge alone;
|
|
neither describes the stored override any more. Clear and the Pending
|
|
restart badge describe the override, so both render in the Override
|
|
cell instead, under the control, on one line
|
|
(settingsOverrideCell, rendered into Binding.ControlFooters by
|
|
settingsControlFooters). All three are the page's own, rendered
|
|
through SafeTemplates.Fragment: the badges belong to this surface, not
|
|
to the form library, and go through the shared statusBadge part like
|
|
every other badge in the console.
|
|
|
|
Every control on this page sets a value and nothing else; removing a
|
|
stored override is the row's own Clear, an action trigger on
|
|
DELETE /operator/integrations/{integrationKey}/settings/{key} that
|
|
carries no confirm modal because the same override can be set again
|
|
from the same row (design D21 round 5). CSRF rides the shell's
|
|
hx-headers:inherited, the path every operator trigger takes. */}}
|
|
{{ template "pageHeader" .Header }}
|
|
<p class="text-muted small">Saved changes apply when the application restarts.</p>
|
|
|
|
{{ template "form" .Form }}
|
|
|
|
{{ define "settingsEffectiveCell" }}
|
|
{{- if .Secret -}}
|
|
{{ if .SecretSet }}<span class="text-muted">Set</span>{{ else }}{{ template "statusBadge" .NotSetBadge }}{{ end }}
|
|
{{- else -}}
|
|
{{ if .Effective }}<code>{{ .Effective }}</code>{{ else }}{{ template "statusBadge" .NotSetBadge }}{{ end }}
|
|
{{- end -}}
|
|
{{ end }}
|
|
|
|
{{ define "settingsSourceCell" }}{{ template "statusBadge" .SourceBadge }}{{ end }}
|
|
|
|
{{ define "settingsOverrideCell" }}
|
|
{{- if or .HasOverride .PendingRestart -}}
|
|
<div class="d-flex align-items-center gap-2 mt-1">
|
|
{{- if .HasOverride }}
|
|
<button type="button" class="btn btn-outline-secondary btn-sm"
|
|
hx-delete="{{ routeURL "/operator/integrations/{integrationKey}/settings/{key}" .IntegrationKey .Key }}"
|
|
hx-target="#operator-body" hx-swap="innerHTML">
|
|
Clear
|
|
</button>
|
|
{{- end -}}
|
|
{{- if .PendingRestart }} {{ template "statusBadge" .PendingBadge }}{{ end }}
|
|
</div>
|
|
{{- end -}}
|
|
{{ end }}
|