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

@closerclick/closer-click-share

v0.3.0

Published

UI compartida de CloserClick para compartir un enlace: Web Component <closer-click-share> con QR autohosteado, copiar y botones de redes (WhatsApp/Telegram/X/Facebook/Web Share). Emite cc-share-shared y soporta el opt-in de acuse de apertura (track + .not

Downloads

63

Readme

@closerclick/closer-click-share

UI compartida del ecosistema CloserClick para compartir un enlace. Web Component <closer-click-share> (custom element, Shadow DOM) reutilizable por cualquier app (Vue o vanilla): el mismo modal de compartir para pronosticador, ajedrez, cuarenta, etc.

Muestra QR (autohosteado, generado en el cliente — sin servicios de terceros), el enlace con botón de copiar, y botones de redes (WhatsApp, Telegram, X, Facebook) + "Más" (Web Share API nativa).

Autohosteado, Shadow DOM, sin JS de terceros ni cookies, bilingüe es/en. No toca identidad/transporte/almacenamiento: solo recibe una URL ya armada (los datos de usuario viajan por #fragment, que no llega al servidor ni es indexable).

Uso

import '@closerclick/closer-click-share'
<closer-click-share lang="es"></closer-click-share>
const el = document.querySelector('closer-click-share')
el.url = 'https://cuarenta.closer.click/#table=ABC'
el.text = '¡Únete a mi mesa!'
el.open = true
el.addEventListener('cc-share-close', () => { el.open = false })

Atributos / propiedades

  • url — el enlace a compartir / del QR.
  • text — texto corto para las redes.
  • langes | en.
  • heading, hint — textos opcionales.
  • open — booleano: muestra/oculta el modal.
  • track — booleano: muestra el toggle "avísame cuando lo abran" (requiere inyectar .notifications).
  • category — categoría de prefs que togglea ese switch (default shareOpened).

Propiedad JS

  • .notifications — controlador de createNotifications(...) de @closerclick/closer-click-notifications. Si se inyecta y está el atributo track, el modal muestra el toggle de seguimiento (enciende la categoría + pide permiso de notificaciones).

Eventos

  • cc-share-close — al cerrar el modal.
  • cc-share-shared — al compartir; detail { url, method } con methodcopy|wa|tg|x|fb|native. Útil para que la app registre el seguimiento del contenido compartido.

Acuses de apertura (ligado a notificaciones)

El "atado" con notificaciones se completa con createShareReceipts(...) de @closerclick/closer-click-notifications: el que abre un enlace firmado manda el acuse (receipts.report), y el autor lo recibe como notificación (receipts.start). Este componente aporta el opt-in (track + .notifications) y el evento cc-share-shared. Ver el README de notificaciones.

Tema (variables CSS)

--ccs-bg, --ccs-text, --ccs-muted, --ccs-border, --ccs-accent, --ccs-accent-text, --ccs-input-bg, --ccs-overlay, --ccs-radius, --ccs-shadow.

Slot de acciones extra

<closer-click-share> admite botones adicionales del llamador via slot="actions" (p. ej. Imprimir / PDF):

<closer-click-share :url=... :open=...>
  <div slot="actions"><button @click=...>🖨 Imprimir</button></div>
</closer-click-share>