npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@ai-dico/social-login-buttons

v0.1.0

Published

Token-based Kakao, NAVER, Apple and Google login buttons

Readme

@ai-dico/social-login-buttons

Version 0.1.0 · ESM · Node >=18 · no runtime dependencies. Kakao, NAVER, Apple and Google buttons generated from the repository's tokens.json. The companion social_login_buttons gem renders byte-identical HTML for identical options.

npm install @ai-dico/social-login-buttons
import { renderButton, tokens, defineSocialLoginButton } from '@ai-dico/social-login-buttons';
import '@ai-dico/social-login-buttons/css'; // with a CSS-aware bundler

document.querySelector('#login').innerHTML = renderButton({ provider: 'kakao' });
defineSocialLoginButton();
<form method="post" action="/sessions">
  <social-login-button provider="naver" purpose="login" type="submit"
    name="provider" value="naver" logo-color="brand"></social-login-button>
</form>

Registration is optional, idempotent and safe during SSR. The element uses light DOM, redraws when options change, and contains a native button supporting form submission. Use kebab-case attributes (logo-color, apple-logo-src); numeric height is parsed. disabled, name, value and form are forwarded to the native button. attrs is available through renderButton, rather than a serialized component attribute.

| Option | Values | Default | | --- | --- | --- | | provider | kakao, naver, apple, google | required | | purpose | login, continue, signup, short | continue | | lang | ko, en | ko | | tone | brand, white, black, custom | brand | | theme | light, dark | light | | corner | official, 0, 4, 8, 12, pill | official | | height | official or a positive finite pixel number | 48 | | font | unified, brand | unified | | logoColor | brand, mono | brand | | layout | full, icon | full | | align | center, logo-left | center | | bg, fg, border | #RRGGBB; bg/fg required for custom, border optional | none | | appleLogoSrc | URL to your own official Apple logo file | no logo (icon layout shows the text "Apple") | | type | button, submit | button | | attrs | string attribute names and string values | none |

Additional attributes follow the canonical attributes in ASCII name order; values and labels escape & < > " '. Invalid option values, invalid attribute names, event handlers, and overrides of type, class, style, aria-label raise TypeError. Use attrs: { disabled: '' } for a boolean HTML attribute.

official height uses the web height (Google: 40px). Unified text is max(14, round(height / 3)), weight 500, including official-height mode. Brand text uses the provider's size or rounded size ratio and official weight. Explicit corners are never adjusted; pill is half the resolved height. Custom borders appear when background/page contrast is below 1.3 unless explicitly set. Custom brand logo selection uses relative luminance >0.5 for the white-tone palette. Google mono uses a clipped, zero-blur CSS drop shadow to match foreground color exactly.

.slb-stack provides a full-width vertical group; .slb-row arranges icons horizontally. Override the system font after the stylesheet with .slb { font-family: inherit; }. Rendering does not implement authentication or OAuth.

Apple artwork is not included. Obtain an appropriate file from Apple Design Resources, host it in your project and pass appleLogoSrc. The file is never tinted; without a URL the logo element is omitted and text stays centered (icon layout shows the short text "Apple" instead of an empty square).

Build from the repository root: node tools/gen-packages.mjs. Test here: node --test. src/index.js is maintained by hand; dist is generated. The npm tarball includes dist, README, LICENSE and the required package.json; source, fixtures and tests are excluded.

Code/tokens/docs: MIT. Provider logos and names are their respective owners' trademarks and are excluded from the MIT grant. This package is not affiliated with those companies.