Skip to content

Screens

A Screen is one piece of payroll UI. You list the Screens a person may see when you create a Session, then render one at a time with <friendly-payroll>.

Each Screen carries exactly the access it needs, so you never assign roles. Give people access by choosing which Screens their Sessions include.

For someone at the business: an owner, admin or bookkeeper. The Session has no worker, except for Screens that are about one Worker.

ScreenNeeds a workerExtra events
employer-dashboardNo—
employer-onboardingNo—
employer-onboard-workersNo—
payroll-run-listNo—
run-payrollNorunpayrollview, runpayrollclick, runpayrollcompleted
employer-setup-personalizationNo—
employer-taxes-setupNo—
employer-sign-documentsNo—
employer-pay-groupsNo—
employer-address-listNo—
employer-bank-accountsNobankaccountauthorized, bankaccountcreated, bankaccountverified
employer-profileNo—
employer-documentsNo—
employer-reportsNo—
worker-profileYes—
onboard-workerYes—

For a Worker looking at their own pay and documents. The Session must include the worker.

ScreenExtra events
worker-onboarding—
worker-self-managed-profile—
worker-payment-list—
worker-documents—

Some Screens accept options. Pass them through the options attribute or property, or the options prop in React. The ScreenOptions type in @friendlypayroll/embed lists the options for every Screen. Common ones:

Screen Option Description
employer-onboarding includeSteps Which onboarding steps to show, e.g. ["tax-info", "pay-schedule", "add-company-bank"].
employer-dashboard showPayrollRunReports Show reports for each payroll run.
employer-profile includeCards Which sections to show, e.g. ["business", "addresses", "banks"].
worker-profile includeCards Which sections to show, e.g. ["personal", "compensations", "pay-distributions"].
worker-self-managed-profile includeCards ["personal", "pay-distributions", "taxes-setup"].
worker-onboarding showWelcomeView Show the welcome step.
Several setup Screens title, closeDisabled Override the heading, or hide the close button.

IDs and display mode are always set by Friendly Payroll, and any you pass are ignored.