shadcn.io is not affiliated with official shadcn/ui
Stats Sidebar Login Block for React
A split sign-in page for uptime monitoring: the form at the start and four figures on hairline cells at the end, with a 30 days and 12 months switch that rolls the digits to the other period's numbers.
Installation
Overview
Put numbers next to the sign-in, with this stats sidebar login block for React with Base UI. It's the sign-in of Pulsewick, uptime monitoring: the page's side rails run its full height, and one band crosses the screen between two rules, split in two by a divider that meets both with a plus mark. The form is at the start: the product's mark, one outline Button to continue with Google behind a two-letter tile, an "or" rule, a Field for the email, a Password Input with its show and hide toggle and a "Forgot password?" link, and the Shine Button. At the end, four figures sit on hairline cells, each a label over its value: teams watching, platform uptime, countries and average rating. A Toggle Group of 30 days and 12 months rewrites them from a typed table and the Sliding Number digits roll to the new values, while the cells keep their size. The form is checked when it is sent, each problem under its field with focus on the first, and a good press shows the result in the form's own space. On a phone the figures are gone and the form fills the screen. For any sign-in that wants to say how many people already rely on it.
FAQ
What happens when I sign in, and where do the figures come from?
Nothing leaves the page. Sign in waits under a spinner for less than a second, then shows "You're signed in" with the address you typed, and a polite status message says nothing was sent; Continue with Google shows where a real one would send you, with a way back. The figures are example values for a fictional product, typed in FIGURES with one number for each period and an AS_OF day shown beside them. For real, read them from your own statistics service, say when they were measured, and don't show a figure you can't back up: a made-up uptime or user count on a sign-in page is a claim.
How does the period switch work?
Each figure holds its 30-day and 12-month numbers and the switch picks which one shows. The Sliding Number rolls only the digits that changed, and with reduced motion the digits change in place. The cells are the same size in both periods, so nothing moves, and a polite status message says which period is showing. It is a single-choice group: arrow keys move between the two chips and one is always on.
How do screen readers read the figures?
Each cell is a term and its value in a description list, so a reader hears "Platform uptime, 99.98%". The rolling digits are drawn from a hidden column of numbers marked aria-hidden, and the real value is written once in text for assistive technology, so the digits never read as a jumble and the number is right in every period.
Why are the figures hidden on a phone?
Because the page's job on a small screen is to get you signed in: the form fills the width and Sign in ends on the first screen. The aside is decoration around that job, so below 1024 pixels it is dropped rather than stacked under the form. If you want the numbers on phones, put one line of them under the heading.
Is it usable with a keyboard and a screen reader?
Yes. Tab runs through the provider row, the email, the password, its show and hide toggle, Forgot password, Sign in, the quiet link and the period switch, where the arrow keys move between chips. Enter in either field signs in. Each problem is tied to its field, focus goes to the first, and after signing in it moves to the result's heading while a polite status message says what happened.
Related
- Pro
Split Product Sketch Login
Split with a panelA split sign-in page for a grocery delivery service: the form at the end beside a drawn sketch of the product (a basket, a delivery slot and a total in an inset frame), with Remember me and a simulated sign-in.
- Pro
Testimonial Sidebar Login
Social proofA split sign-in page for a mentoring platform: the form with a Continue with Google row beside one pull-quote in an inset frame, with initials, a name and role, five stars and a Read the story link.
- Pro
Feature Tour Login
Split with a panelA split sign-in page for a spreadsheet that works like a database: the form beside a wide three-tab tour (Boards, Timeline, Reports), each tab a drawn greyscale view of one table and a sentence.
- Pro
Trusted Brands Login
Social proofA sign-in page for accounting software with a still strip of eight customer wordmarks under the form and a sector filter that dims the wordmarks outside the chosen sector instead of hiding or moving them.
- Pro
Centered Sign In Login
Centered formA full-height sign-in page for a team chat app: the product's mark, Google and GitHub rows with lettermark tiles, an or rule, email and password checked on submit, and one Sign in button with a simulated wait and its result.
- Pro
Donut Pill Legend Stats
Parts of a wholeA traffic-source donut over a row of pill toggles: switch a source off and its arc leaves the ring, the others grow to fill it, and the shares and the total in the middle are worked out again.