@props(['entry', 'unlocked', 'mode'])
{{--
One vault entry — outline, new-value field, test/save/forget — reusable
across every integration section on App\Livewire\Admin\Integrations. Kept
as its own component so a section can sit a secret and a plain setting
side by side (R20 exception: this is the page, not a table row) without
repeating this block per section.
Locked and unlocked are two genuinely different renders, not one hidden
behind CSS: while locked, nothing about the stored value — not even
whether one exists beyond the badge above this component — reaches the
page beyond a "gesperrt" note.
--}}
{{ $entry['label'] }}
{{-- The NAME OF THE SERVER VARIABLE, not the internal registry key.
It used to print `stripe.secret` — an identifier from
SecretVault::REGISTRY that means nothing on this page and is not
something an operator can type anywhere. The env name is: it is
what stands in the server file, it is what the .env tab of this
same page lists, and when the badge beside this says "Aus der
Serverdatei" it is the answer to "which line?". --}}
{{ $entry['envKey'] }}
{{-- Which of the two slots THIS card reads and writes right now —
fix round, Important: save()/render() resolve without a mode
argument, so they always act on OperatingMode::current()'s
slot, but nothing on the card said so. The badge in the
header above (Integrations::mode_title) is not enough: it is
not visible at the card an operator is about to type into,
and repeating "Testbetrieb"/"Livebetrieb" there would only
restate the MODE, not name the PLATZ a value lands in. Same
colours as that header badge, for one visual language. --}}
{{ __('secrets.slot.'.$mode->value) }}
{{-- Aufgezählt nach den zwei Enden statt nach jedem Wert einzeln:
grün heißt „liegt in DIESEM Platz", gelb heißt „nirgends", und
alles dazwischen (aus der Serverdatei, aus dem Live-Platz) ist
blau — in Kraft, aber woanders her. So bekommt ein künftiger
vierter Wert nicht still die Farbe von „Nicht gesetzt". --}}
{{ __('secrets.source_'.$entry['source']) }}
@if ($entry['multiline'])
{{-- A multi-line PEM key: a single-line password field would
mangle it on paste. Not masked — a textarea cannot mask
its content in any browser. --}}
{{ __('secrets.ssh_private_key_hint') }}
@error('entered.'.$entry['field'])
{{ $message }}
@enderror
@if ($entry['generatable'])
{{-- Neben dem Feld, nicht unten bei Speichern: es ist die
Alternative ZUM Einfügen, nicht ein weiterer Schritt
danach. Der erzeugte private Teil geht direkt in den
Tresor und erscheint nie in diesem Textfeld. --}}
{{-- Test first: a key that is saved and wrong fails later,
somewhere else, usually in front of a customer. --}}
@if ($entry['testable'])
{{ __('secrets.test') }}
@endif
{{ __('secrets.save') }}
@if ($entry['source'] === 'stored')
{{ __('secrets.forget') }}
@endif