Skip to content
Razor catalogue

On this page

@addTagHelper *, Webority.Ui.Razor

The change list

The changes a person is about to save, each with the value it was and the value it becomes.

Two changes
  • Invoice prefixWas INVNow BILL
  • Zoho Books writesWas OffNow OnStarts writing to the ledger at once.
Show code
<app-change-list>
    <app-change-item label="Invoice prefix" was="INV" now="BILL"></app-change-item>
    <app-change-item label="Zoho Books writes" was="Off" now="On" note="Starts writing to the ledger at once."></app-change-item>
</app-change-list>
A change with no earlier value
The was line is left out.
  • SyncNow On
Show code
<app-change-list>
    <app-change-item label="Sync" now="On"></app-change-item>
</app-change-list>

Inside a confirm dialog

A critical change saves only after the person types the confirm word.

Typed word before saving
The confirm button stays off until WRITE is typed.
Show code
<app-button variant="Outline" data-wui-open="#scWritesConfirm">Turn on Zoho Books writes</app-button>
<app-confirm-dialog id="scWritesConfirm"
    title="Turn on Zoho Books writes?"
    description="Starts writing to the ledger at once."
    confirm-phrase="WRITE"
    confirm-label="Turn on writes"></app-confirm-dialog>

Guidance

What to do, and what to avoid.

Use it when

  • A person is about to save a change and must read what it replaces before confirming.
  • A risky change needs its was and now values listed in the confirm dialog or the setting's confirm panel.

Reach for something else when

  • The values are read only and shown as facts about a record. → AppDescriptions
  • The change is confirmed without showing its values. → AppConfirmDialog alone

Show both values

Do
  • Invoice prefixWas INVNow BILL

Show the value it was and the value it becomes, so the person can compare them.

Avoid
  • Invoice prefix

A change with no values tells the person nothing about what will change.

Reference

Try every prop, read the full list, and check keyboard and screen reader behaviour.

two changes no earlier value empty
  • Invoice prefixWas INVNow BILL
  • Zoho Books writesWas OffNow OnStarts writing to the ledger at once.
React, generated from the controls
<AppChangeList items={changes} />
Razor, the same props
<app-change-list>
    <app-change-item label="Invoice prefix" was="INV" now="BILL"></app-change-item>
    <app-change-item label="Zoho Books writes" was="Off" now="On" note="Starts writing to the ledger at once."></app-change-item>
</app-change-list>

5 props.

Less common 5 props

PropTypeDefaultDescription
classdefault - string - Extra classes on the list's root element.
labeldefault - string - On app-change-item: the setting or field name (required).
wasdefault - string - On app-change-item: the value before the change. Left out when there is none.
nowdefault - string - On app-change-item: the value after the change.
notedefault - string - On app-change-item: one line of context, such as what the change does.

Screen reader

2 notes
  • Renders an unordered list: each change is one item, its label first, then the was value and the now value.
  • The words Was and Now are text, so the change reads the same without colour.

Do and avoid

1 pairs

Show both values

Do
  • Invoice prefixWas INVNow BILL

Show the value it was and the value it becomes, so the person can compare them.

Avoid
  • Invoice prefix

A change with no values tells the person nothing about what will change.