Socket
Book a DemoInstallSign in
Socket

@288-toolkit/css

Package Overview
Dependencies
Maintainers
2
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@288-toolkit/css

```sh npm i @288-toolkit/css ```

latest
npmnpm
Version
3.0.0
Version published
Maintainers
2
Created
Source

Css

npm i @288-toolkit/css

A collection of useful css files. Must be used with Tailwindcss.

viewport.css

Makes rem units responsive between 2 viewport sizes.

When the viewport is below the min, 1 rem equals 9px, which is the smallest value allowed by Safari.

When the viewport is above the max, 1 rem equals 10px.

When the viewport is between min and max, 1 rem is tied to the viewport width. The scaling factor changes at one breakpoint between min and max, called bp.

rem value in px based on the viewport

Between min and --viewport-bp, which is 800 by default, 1 rem equals 2vw. Between --viewport-bp and --viewport-max, which is 1600 by default, 1 rem equals 1vw.

For the styles to work properly, you must define those 3 points in your tailwind config screens.

We recommend the following values.

export default {
	theme: {
		screens: {
			min: '360px',
			bp: '800px',
			max: '1600px
		}
	}
}

Note that if you modify bp or max, you must also set the same value in their respective css variables on the :root.

export default {
	theme: {
		screens: {
			min: '360px',
			bp: '1000px',
			max: '1800px
		}
	}
}
:root {
	--viewport-bp: 1000;
	--viewport-max: 1800;
}

reset.css

A css reset, added on top of Tailwind's own preflight.css.

FAQs

Package last updated on 30 Apr 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.