Social sign-in
Buttons that sign a person in with Google, GitHub or Apple, each with its own logo, in a stack or a row. The pressed one shows a spinner while the provider opens, and the provider used last can lead.
Examples
Default
Give the group onSignIn: the pressed button shows a spinner while the provider opens, and the others wait.
Row
layout='row' shows the logos alone, side by side, each named by its label and showing it as a tooltip.
Last used
Pass lastUsed, the provider the person signed in with last: it comes first, marked Last used.
Couldn’t reach GitHub. Try again in a moment.
Failure
A throw or a rejected promise from onSignIn puts the buttons back to rest, so the person can try again, as here after GitHub couldn’t be reached.
Labels
Each button’s children are its label, for a sign-up page or another language; lastUsedLabel translates the badge.
Installation
npx shadcn@latest add https://kinoui.com/r/social-sign-in.json- Files
lib/refs.tslib/reduce-motion.tslib/resize.tslib/swap.tsxcomponents/kino/badge.tsxcomponents/kino/spinner.tsxcomponents/kino/button.tsxlib/popup.tslib/glide.tsxcomponents/kino/tooltip.tsxlib/controllable.tslib/settle.tscomponents/kino/social-sign-in.tsx- Packages
@base-ui/reactclass-variance-authority- Global CSS
- the feels, the density tokens, the shape tokens and the success and warning colours
New to Kino? Installation covers what your project needs first and the @kino namespace.
API reference
SocialSignIn
SocialSignInButton
Data attributes
Accessibility
- Each button is a native
<button>named by its label; in a row, the label is itsaria-labeland its tooltip, and the logo is hidden. - The pressed button keeps focus and is marked
aria-busy, and the others are disabled, so two sign-ins never start at once. - Last used is read as the button’s description, once.
- The spinner shows only after 200ms and then stays at least 300ms, so a quick sign-in never flashes one.