Your development workspace
This app is private. Sign in with your authorized Google account.
Give single-select indicators a deliberate trailing inset and reserve enough space so text cannot collide with them. Do not assume native arrows follow horizontal padding. Share the treatment across form variants and verify the final cascade and narrow layouts.
| 1 | function DocumentSelect() { |
| 2 | return <label>Document type |
| 3 | <select style={{ padding: '12px 16px' }}> |
| 4 | <option>Identity card</option> |
| 5 | <option>Student identification card</option> |
| 6 | </select> |
| 7 | </label> |
| 8 | } |
Explanation (EN)
The field sets text padding but leaves the browser indicator placement unchecked. In the affected browser the collapsed arrow remains pressed against the edge.
Objašnjenje (HR)
Polje ima razmak za tekst, ali položaj strelice preglednika nije provjeren. U pogođenom pregledniku strelica ostaje uz sam rub.
| 1 | function DocumentSelect() { |
| 2 | return <label>Document type |
| 3 | <span style={{ display: 'block', position: 'relative' }}> |
| 4 | <select style={{ width: '100%', appearance: 'none', padding: '12px 52px 12px 16px' }}> |
| 5 | <option>Identity card</option> |
| 6 | <option>Student identification card</option> |
| 7 | </select> |
| 8 | <svg aria-hidden="true" width="18" height="18" viewBox="0 0 24 24" |
| 9 | fill="none" stroke="currentColor" strokeWidth="2" |
| 10 | style={{ position: 'absolute', insetInlineEnd: 16, top: '50%', transform: 'translateY(-50%)', pointerEvents: 'none' }}> |
| 11 | <path d="m6 9 6 6 6-6" /> |
| 12 | </svg> |
| 13 | </span> |
| 14 | </label> |
| 15 | } |
Explanation (EN)
A decorative indicator has a defined inset and reserved text area. Pointer events reach the native select, which retains its label and selection behavior. Use an existing shared control when available.
Objašnjenje (HR)
Dekorativna strelica ima zadan odmak i rezerviran prostor za tekst. Dodir prolazi do izvornog selecta, koji zadržava oznaku i odabir. Prednost ima postojeća zajednička kontrola.
Apply when adding, styling or reviewing a native single-select or correcting a flush dropdown arrow. Inspect the collapsed control, not only the option list. Check all shared form variants, long labels and narrow viewports after background and padding shorthands have resolved. Preserve labels, focus, keyboard access and touch behavior. Background-image indicators need a forced-colors fallback.
Primijeniti pri dodavanju ili stiliziranju jednostrukog selecta te ispravljanju strelice uz rub. Provjeriti zatvoreno polje, ne samo popis opcija. Provjeriti sve varijante obrasca, duge nazive i male zaslone nakon primjene background i padding shorthanda. Sačuvati oznake, fokus, tipkovnicu i dodir. Strelica iz pozadinske slike treba zamjenu u prisilnim bojama.
Keep native or design-system indicators when their final inset and text clearance are already verified. Multiple-select and visible listbox controls do not require a dropdown chevron. Forced-colors mode may intentionally restore native appearance.
Zadržati izvornu ili zajedničku kontrolu ako su stvarni razmak strelice i prostor za tekst već provjereni. Višestruki odabir i otvoreni popis ne trebaju strelicu padajućeg polja. Prisilne boje mogu namjerno vratiti izvorni prikaz.
Use this to align rules with the senior-level structure (P0/P1/P2, scope, exceptions/tradeoffs).