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

primary-style

v1.0.0-beta.0

Published

A library for basic style write with scss

Downloads

1

Readme

primary-style

Browser basic styles and useful class.

Installation And Usage

yarn add primary-style
import 'primary-style';

Features

  • Page defaults

From Bootstrap

The <html> and <body> elements are updated to provide better page-wide defaults. More specifically:

* The box-sizing is globally set on every element—including *::before and *::after, to border-box. This ensures that the declared width of element is never exceeded due to padding or border.

* No base font-size is declared on the <html>, but 16px is assumed (the browser default). font-size: 1rem is applied on the <body> for easy responsive type-scaling via media queries while respecting user preferences and ensuring a more accessible approach.

* The <body> also sets a global font-family, line-height, and text-align. This is inherited later by some form elements to prevent font inconsistencies.

* For safety, the <body> has a declared background-color, defaulting to #fff.
html {
  box-sizing: border-box;
  line-height: 1.15; // Correct the line height in all browsers.
  height: 100%; // make full height
  -webkit-text-size-adjust: 100%; // 4
  -ms-text-size-adjust: 100%; // 4
  -ms-overflow-style: scrollbar; // 5
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0); // 6
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

// 1. Set an explicit initial text-align value so that we can later use the
//    the `inherit` value on things like `<th>` elements.

body {
  background-color: #fff;
  color: #34374c;
  display: flex;
  flex-direction: column;
  font-family: 'Microsoft Yahei', Arial, Helvetica, sans-serif;
  font-size: 1rem;
  height: 100%;
  margin: 0;
  text-align: left; // 1
}
  • Font size

Use class font-10, the font size is 10px. The size also could be oneof [10, 12, 14, 16, 18, 20, 22, 24, 28, 30, 32, 36, 48, 64, 72];

  • Layout

${size} is oneOf

[1, 2, 4, 5, 6, 8, 10, 12, 15, 16, 18, 20, 22, 24, 26, 28, 32, 48, 64, 72, 100, 120]

Support:

.pl-${size} {
  padding-left: #{$size}px;
}
/* Others like this */
/*
pr-${size}
pt-${size}
pb-${size}

mr-${size}
ml-${size}
mt-${size}
mb-${size}
*/

.no-padding {
  padding: 0;
}
.no-margin {
  margin: 0;
}
.full-width {
  width: 100%;
}
.full-height {
  height: 100%;
}
  • Definate Scrollbar default style

Plan

  • [ ] Add colors
  • [ ] Could extention by scss variable