Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Modern, modular, extensible button system designed for both rapid prototyping and production-ready applications
Modern, modular, extensible button system designed for both rapid prototyping and production-ready applications.
Made by the folks at Frameable
Just download and include the minified stylesheet on your website.
<link rel="stylesheet" href="/knopf.min.css">
You could also link to a CDN hosted file.
<link rel="stylesheet" href="https://unpkg.com/knopf.css/knopf.min.css">
Otherwise, you can use your favorite package manager to install it as a dependency.
npm install knopf.css
yarn add knopf.css
And then import it wherever you are importing your styles.
import 'knopf.css'
By including knopf you get a bunch of goodies out of the box; however, you should probably customize the styles to meet your design needs, and there are multiple ways of doing just that.
All of the base values can be changed by overriding the custom properties at root:
:root {
--knopf-hue: 164;
--knopf-saturation: 88%;
--knopf-luminosity: 28%;
}
<button class="knopf">
Button
</button>
You can also create your own class that sets new values for a particular instance:
.negative {
--knopf-hue: 356;
--knopf-saturation: 57%;
--knopf-luminosity: 51%;
}
<button class="knopf negative">
Button
</button>
As with any CSS library, you can override the base class to make it your own. This aproach still lets you take advantage of the existing properties, variables and modifiers.
.knopf.knopf {
--knopf-raised-height: 6px;
border-block-end-color: hsl(var(--knopf-hover-background-color));
border-block-end-width: var(--knopf-raised-height);
margin-block-start: calc(var(--knopf-raised-height) * -1);
}
.knopf.knopf:hover {
--knopf-raised-height: 2px;
border-block-end-color: hsl(var(--knopf-active-background-color));
}
<button class="knopf large wide pill">
Button
</button>
The same logic is applicable to all of the built-in modifiers, try out the playground to check them out.
I would also suggest taking a look at the source code for the full list of customizable custom properties.
You can see the full test suite on this pen.
Please read the contribution guidelines in order to make the contribution process easy and effective for everyone involved.
FAQs
Modern, modular, extensible button system designed for both rapid prototyping and production-ready applications
The npm package knopf.css receives a total of 107 weekly downloads. As such, knopf.css popularity was classified as not popular.
We found that knopf.css demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.