Open EvenHub once without finishing sign in and the phone side form comes back
on every app start, with no way to close it. Back exits the app rather than
closing the form.
Three things combine:
- EvenHubStoreLayer.paint() opened the credential editor on its first paint
when no credentials were stored. First paint includes the restore of a
still-open EvenHub at startup, so an unfinished sign in put the form back
every time. handleInput already opens it on a click, so the auto open only
removed the choice of when.
- LayerActions.startTextSettingsEdit declares a fifth onCancel parameter, but
the DashboardController wiring forwarded four and the method accepted four.
Nothing failed to compile, because a 4-parameter function is assignable to a
5-parameter function type. That callback resets openCredentialEditor's
phoneEditor guard, so with it dropped the guard latched at "credentials":
the screen timeout hid the panel without resetting the state behind it, and
the form could then be neither closed nor reopened. ios-preview-controller.ts
already forwards all five, so this was the G2 path only.
- The panel has no Cancel control, so the keyboard's Done key on the password
field is the only way to end the edit. On an untouched form that reached
submitCredentials, which called enterLogin("Email and password are
required."), which reopens the editor. A loop with no exit.
The auto open is removed; onCancel is forwarded, stored and fired from
endTextSettingEdit, with finishTextSettingEdit clearing it first so a completed
edit does not also report a cancel; and a wholly empty submission is treated as
a cancel. A half-filled form is a real mistake and still reopens with the
message.
tests/evenhub-signin.test.cjs covers the open and close contract through the
existing load-typescript.cjs loader. Two of its five tests fail against the
current store-layer.ts and pass with this change.