rfellows opened a new pull request, #11248:
URL: https://github.com/apache/nifi/pull/11248

   # Summary
   
   [NIFI-15855](https://issues.apache.org/jira/browse/NIFI-15855)
   
   Completes the connector wizard property-input behavior for `SECRET` and 
`BOOLEAN` property descriptors in `connector-property-input`. The 
`availableSecrets` / `secretsLoading` / `secretsError` inputs were declared but 
unused in the previous wizard PR; this change wires them through and switches 
`BOOLEAN` rendering to a slide-toggle to match the rest of the wizard's input 
controls.
   
   ## Changes
   
   ### `SECRET`
   
   - Render `SECRET` properties via `<searchable-select>` instead of a plain 
text input.
   - Form value is the composite key 
`providerId::providerName::fullyQualifiedName`, built by `buildSecretKey()`. 
The parent `connector-configuration-step` already unpacks this on save via 
`parseSecretKey()`.
   - Group options by provider name, falling back to `"Provider - Group"` when 
a provider owns multiple groups.
   - Orphan handling: a saved value not present in the loaded secrets renders 
as a disabled `"…fqn… (no longer available)"` option grouped under the saved 
provider name. A pre-load placeholder is shown while secrets are still loading.
   - Provider-rename auto-fix: when a saved value matches a current secret by 
`providerId + fullyQualifiedName` but the `providerName` has changed, the form 
value is rewritten to the new composite key after the next render 
(`afterNextRender` + `runInInjectionContext`).
   - `secretsError` flips the `<searchable-select>` into its `loadError` state 
with the message `"Failed to load secrets"` and suppresses the description hint.
   - Inline progress spinner with `"Loading secrets..."` while 
`secretsLoading()` is true; placeholder text follows the four `SECRET` states 
(`Loading secrets...`, `Failed to load secrets`, `No secrets available`, 
`Select a secret`).
   
   <img width="1468" height="1314" alt="Screenshot 2026-05-13 at 13 10 23" 
src="https://github.com/user-attachments/assets/89aa74c4-cb23-4f0d-b376-4f18a1d6eda9";
 />
   
   
   ### `BOOLEAN`
   
   - Replace `<mat-checkbox>` with `<mat-slide-toggle>`: label on the left, 
toggle on the right, description below. `writeValue` already coerces `'true'` / 
`true` / other to a boolean, so no API change for parent consumers.
   
   <img width="1333" height="687" alt="Screenshot 2026-05-13 at 13 11 07" 
src="https://github.com/user-attachments/assets/397ae477-d414-40ca-be99-40177c865abe";
 />
   
   
   ## Reviewer notes
   
   - **`BOOLEAN` rendering change.** This is the first use of 
`<mat-slide-toggle>` for a property descriptor in `nifi-frontend`; the existing 
slide-toggles in the codebase (e.g. bulletin-board, update-attribute rule 
listing) are ad-hoc UI mode switches. The toggle uses Material's default 
dash/check thumb icon for visual consistency with those. 
   - **`SECRET` form value contract.** The form value is the composite key, not 
`secret.id`. The existing parent already depends on this; any future consumer 
reading the value directly must use `parseSecretKey()` to unpack it.
   - No parent or store changes. `availableSecrets` / `secretsLoading` / 
`secretsError` are already populated upstream and passed in via 
`connector-configuration-step`.
   
   ## Testing
   
   - `connector-property-input.component.spec.ts` extended from 37 to 50 tests.
     - 12 `SECRET` tests: option shape, single-group vs multi-group label 
format, post-load orphan, pre-load orphan, provider-rename auto-fix, 
`loadError` wiring (including empty-string short-circuit), inline spinner 
show/hide, placeholder state transitions.
     - 5 `BOOLEAN` tests: slide-toggle rendering, parent → child form sync, 
toggle → parent round-trip via native input click, `writeValue('true')` truthy 
coercion, `writeValue('false')` falsy coercion.
   - Full shared lib suite (741 tests) passes; `nx lint shared` and prettier 
are clean.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to