iya-sts
    Preparing search index...

    A page's forms' choices across a redirect. A static utility class.

    Index
    MAX_AGE_MS: number = ...

    How long what was kept may be put back, in milliseconds.

    • What one form holds, as kept across a sign-in.

      Parameters

      • form: any

        the form

      • pending: boolean

        whether it is the form being sent

      Returns any

      { action, pending, fields }

    • Whether a form control's value may be kept across a sign-in: never a password, a file, a hidden field, a button, or a control named or marked for a secret.

      Parameters

      • el: any

        the control

      Returns boolean

      true when it is kept

    • Puts kept values back into the forms drawn: the same form by its place and its address, the same control by its name and order.

      Parameters

      • forms: any[]

        the forms drawn, in document order

      • saved: any[]

        formSnapshot()'s answers, in the same order

      Returns any

      { restored, unplaced }, counts of values

    • Keeps the forms' choices in sessionStorage, for after a redirect. Storage refused or full keeps nothing, and the redirect still goes.

      Parameters

      • env: any

        the browser's objects: document, sessionStorage, and now where a test gives one

      • key: string

        the storage key

      • facts: any

        { prefix, path, subject, submitting }: the realm, the page, the person, and the form being sent, if any

      Returns boolean

      whether anything was kept

    • After a sign-in that left the page: reads what was kept once, removes it, and puts it back for the same realm, page and person.

      Parameters

      • env: any

        the browser's objects: document, sessionStorage, now

      • key: string

        the storage key

      • facts: any

        { prefix, path, subject } of the page now drawn

      Returns any

      { state, restored, unplaced }: state is none (nothing for this page), other (another person signed in) or restored