Security News
38% of CISOs Fear They’re Not Moving Fast Enough on AI
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
stylus-lightning
Advanced tools
This is a small library of Stylus mixins and stylesheets. It's purpose built to include in the Site Lightning front-end development boilerplate (source code here). You might also find it useful on it's own.
Site Lightning uses Axis so this library is mostly just extra helpers on top of that.
npm install --save stylus-lightning
This library is dependent on using Axis for the hover-gradient()
mixin. Important! Make sure you import Axis first since this library overwrites the buggy transition()
mixin in Axis.
Like other Stylus libraries you need to use()
it when calling Stylus. Here's an example Gulp config using four other awesome Stylus libraries: Happy Grid, Downbeat, Rupture and Axis.
var stylus = require('gulp-stylus');
var lib = require('stylus-lightning');
var downbeat = require('downbeat');
var grid = require('happy-grid');
var rupture = require('rupture');
var axis = require('axis');
gulp.task('style', function() {
gulp.src('styles/main.styl')
.pipe(stylus({use: [lib(), downbeat(), rupture(), axis(), grid()]}))
.pipe(gulp.dest('./compiled/css'))
});
Then in your main.styl
just @import 'lib'
.
These two stylesheets add CSS to your output.
This is on top of normalize.css to give a nicer baseline for new styles.
font-smoothing
and text-rendering
full-width()
mixinmax-width 100%
)Print styles inspired by Hartija with some typography changes. Print styles in a @media
query so you don' have to worry about it.
Just a few mixins for now.
It's easier to layout your site so that it is contained to a max-width. But sometimes you want a section background to go full width but your content to still be contained. This is a bit of a hack but works great.
section.wide
full-width()
color black
Uses Axis to create a gradient background and style the :hover
to offset the gradient. Also sets the color to the element's color (or a color you pass) which is important if you are styling an anchor tag. When applied to an element (like a.button
for instance) with transition background-position .2s
you get a nice transition.
You can pass up to 4 args but only background-color
is required.
a.button
&.facebook
hover-gradient #425c9e
Set a specific ratio for background images and video iframe embeds.
Example:
.widescreen-video
ratio-box(16/9)
This is a reset to fix occassional problems caused by the way Axis caches Nib's transition mixin. Since it's only for vendor prefixing and I use Auto-prefixer I just want transition to work normally.
FAQs
Stylus library for Site Lightning.
The npm package stylus-lightning receives a total of 0 weekly downloads. As such, stylus-lightning popularity was classified as not popular.
We found that stylus-lightning 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.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.
Security News
Company News
Socket is joining TC54 to help develop standards for software supply chain security, contributing to the evolution of SBOMs, CycloneDX, and Package URL specifications.