shadcn.io is not affiliated with official shadcn/ui
Electrician Services Estimate Profile Block for React
An electrician profile as a flat-rate job estimate: a menu of services in three category tabs with an Add toggle each, and a start cell that works out the subtotal, call-out fee, an emergency surcharge switch, the total and the time on site.
Installation
Overview
Let a homeowner see what a visit costs before they ask for it, with this electrician profile for React with Base UI. A compact header holds the title and one sentence, and the hairline frame under it opens on the electrician: initials, name, role, place and opening days. The start cell is the estimate: a total in tabular figures, the time expected on site, a Switch for an emergency visit within four hours with its surcharge, and a Data List of the services added, the call-out fee, which is waived on a big enough job, and the emergency surcharge. The main cell is the menu: three Tabs (repairs, installs, safety checks), each a ruled list of four services with its time, its flat price and an Add Toggle that fills solid when it is on. The foot, ruled by Guides, holds a polite status line and a Shine Button that requests the visit. Every figure is worked out from the typed prices, and the estimate says it is not a quote. It's built from Tabs, Toggle, Switch, Data List, Badge, Avatar, Shine Button and Guides, with a CSS entrance only. For a home-services marketplace, a contractor directory or any profile that sells by the job.
FAQ
How do I fill it with my own services and fees?
Edit CATEGORIES: each category has services with an id, a name, a flat price in dollars and the minutes the job takes on site. CALL_OUT is the call-out fee, WAIVED_FROM is the job size from which it is waived, and EMERGENCY is the flat surcharge for a visit within four hours. The subtotal, the fees, the total and the time on site are all worked out from the services that are on, so nothing is typed twice. Keep every category at the same number of services so the menu keeps its height when you switch tabs.
How is the estimate worked out?
The subtotal is the sum of the services added. The call-out fee is added once for the visit, unless the subtotal reaches the waiver, in which case the line says Waived; with nothing added there is no fee at all. The emergency surcharge is added only while the switch is on and at least one service is added. The total is those three lines, and the time on site is the sum of the minutes, shown as hours and minutes. The note under the lines says it is an estimate, not a quote.
What does Request this visit do?
Nothing leaves the page. With services added it records the request and the status line says Requested in this demo and that nothing was sent; with none added it says to add a service first. Every change to the menu or the switch has its own line, so the status always says what just happened. To make it real, send the services, the switch and the total to your own booking API in the submit handler and show its answer in the same line.
Do the tabs keep what I added?
Yes. The added services belong to the page, not to a tab, so switching between repairs, installs and safety checks keeps everything and the estimate keeps adding it up. An added service shows a check and a solid button wherever you see it. Arrow keys move between the tabs, and the panel follows the tab you choose.
Is it accessible?
Each Add button is named for its service, so several rows never share the same name, and its pressed state is announced. The switch is named, the estimate is a description list, and the status line is a polite live region present from the start. Prices keep their order in a right-to-left layout, and nothing depends on colour: an added service shows a check as well as a fill.
How does it look on a phone?
The estimate comes first, then the tabs and the menu under it, each service on one line with its price and the Add button. The foot with the request stays pinned to the bottom of the screen while the panel scrolls, and settles at the panel's end from the medium breakpoint. The opening days badge in the person band is hidden below the small breakpoint.
Related
- Pro
Tattoo Piece Estimator Profile
Quotes and servicesA tattoo artist profile as a piece estimator: placement, size and style in, a price range, hours and sessions out, with the sum written out and the studio's hours beside it.
- Pro
Plumber Reviews by Service Area Profile
Credentials and proofA plumber profile with reviews by service area: a drawn greyscale map of six zones in three distance rings, each a button with its average rating, and for the chosen zone its reply time, call-out fee and three reviews with stars, the job and the plumber's reply.
- Pro
Tutor Lesson Planner Profile
Quotes and servicesA tutor profile as a lesson planner: a subject menu, lessons a week on a slider, a block of 4, 8 or 12 weeks, the cost worked out line by line, and the next free times for a trial lesson.
- Pro
Service Provider Reviews
By industryReviews of a local plumbing and heating firm with a profile column, a job-type group that re-derives the rating, services and project cost on each review and the firm's replies.
- Pro
Invoice Preview Pricing
Comparison tablesThree payroll plans as itemised monthly invoices: pick a headcount and each plan's bill adds up line by line, with its total and call to action at the top of its column.
- Pro
Illustrator Commission Builder Profile
Quotes and servicesAn illustrator profile as a commission builder beside her drawn pieces: eight pieces as one radio group, and a size, a character count, a background and a turnaround that work the price and the delivery day out line by line.