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 🙏

© 2024 – Pkg Stats / Ryan Hefner

@actsis/docusaurus-theme

v4.2.2

Published

A collection of components and style overrides for Docusaurus pages in actsis docs

Downloads

20

Readme

Actsis Docusaurus theme

Este tema agrega anulaciones de estilo y nuevos componentes para crear páginas de proyecto basadas en Docusaurus.

To get started (WIP)

  1. Crea un nuevo proyecto de Docusaurus (with the classic theme!): npx create-docusaurus@latest my-website classic

  2. Instale el paquete del tema Actsis Docusaurus: npm i @actsis/docusaurus-theme

  3. Configurar Docusaurus:

    • Abra el archivo de configuración (docusaurus.config.js)

    • Edita tu title, tagline y favicon

    • Edita la barra de navegación:

      • Eliminar title del objeto navbar
      • Configure el logo y los items del menú (evite el anidamiento de varios niveles si es posible)
    • Editar el pie de página

      footer: {
              links: [
                  {
                      title: 'Community',
                      items: [
                          {
                              label: '',
                              href: 'https://...',
                              icon: '',
                          },
                          ...
                      ],
                  },
              ],
      }

      Nota: busque el icono en el componente Icono del paquete (también incluirá una lista en algún momento)

    • Editar el copyright

    • En la parte superior del archivo agregue:

      const darkCodeTheme = require('prism-react-renderer/themes/dracula');
    • Agregue estos al final de la configuración, justo después de copyright:

       prism: {
          theme: darkCodeTheme,
       },
       colorMode: {
          defaultMode: 'light',
          disableSwitch: true,
          respectPrefersColorScheme: false,
       },
  4. Anular algunos de los componentes predeterminados

    • Reemplazar el pie de página

      • Vaya a src/theme y cree una carpeta Footer en él

      • Cree un archivo index.js con los siguientes contenidos:

         import React from 'react';
         import { useThemeConfig } from '@docusaurus/theme-common';
        
         import { Footer as ActsisFooter } from '@actsis/docusaurus-theme';
        
         function Footer() {
            const { footer } = useThemeConfig();
        
            return (
               <ActsisFooter footer={footer} />
            );
         }
        
         export default React.memo(Footer);
    • Reemplazar el contenido de la página de listado del blog.

      • Vaya a src/theme y cree una carpeta BlogListPage en ella

      • Cree un archivo index.js con los siguientes contenidos:

          import React from 'react';
          import clsx from 'clsx';
          import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
          import {
             PageMetadata,
             HtmlClassNameProvider,
             ThemeClassNames,
          } from '@docusaurus/theme-common';
          import BlogLayout from '@theme/BlogLayout';
          import BlogListPaginator from '@theme/BlogListPaginator';
          import SearchMetadata from '@theme/SearchMetadata';
          import BlogPostItems from '@theme/BlogPostItems';
          import { EsOpenSource } from '../sections/os-projects';
          import { EsOsFreebies } from '../sections/os-freebies';
        
          function BlogListPageMetadata(props) {
             const { metadata } = props;
             const {
                siteConfig: { title: siteTitle },
             } = useDocusaurusContext();
             const { blogDescription, blogTitle, permalink } = metadata;
             const isBlogOnlyMode = permalink === '/';
             const title = isBlogOnlyMode ? siteTitle : blogTitle;
             return (
                <>
                   <PageMetadata title={title} description={blogDescription} />
                   <SearchMetadata tag='blog_posts_list' />
                </>
             );
          }
        
          function BlogListPageContent(props) {
             const { metadata, items } = props;
        
             return (
                <BlogLayout>
                   <h1 className='es-big-title'>Typing as <wbr /> we code</h1>
        
                   <div className='es-blog-grid'>
                      <BlogPostItems items={items} />
                   </div>
        
                   <BlogListPaginator metadata={metadata} />
                   <EsOpenSource gray />
                   <EsOsFreebies gray />
                </BlogLayout>
             );
          }
        
          export default function BlogListPage(props) {
             return (
                <HtmlClassNameProvider
                   className={clsx(
                      ThemeClassNames.wrapper.blogPages,
                      ThemeClassNames.page.blogListPage,
                   )}>
                   <BlogListPageMetadata {...props} />
                   <BlogListPageContent {...props} />
                </HtmlClassNameProvider>
             );
          }

        (asegúrese de reemplazar cualquier contenido genérico aquí, como IconLinkCards)

  • Reemplace las tarjetas de Admonition - Vaya a src/theme y cree una carpeta Admonition en él - Cree un archivo index.js con los siguientes contenidos:

        ```jsx
          import React from 'react';
          import { AdmonitionCard } from '@actsis/docusaurus-theme';
    
          export default function Admonition(props) {
             return (
                <AdmonitionCard {...props} />
             );
          }
        ```
  1. Cree su sitio npm start y verifique todo

Componentes incorporados

Descripción más detallada próximamente

  • CtaCards
  • CtaImageButton
  • FeatureShowcase
  • Hero
  • IconLinkCards
  • ImageAndText
  • ActsisLogo
  • ShowcaseCard
  • TextCards
  • icons