
Product
Introducing Webhook Events for Alert Changes
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.
include-media-spread
Advanced tools
An include-media plugin for spreading css properties over the breakpoints
An include-media plugin for spreading css properties over breakpoints
This plugin calculates the difference between property values and distributes them through your include-media breakpoints.
Example
@import 'include-media';
@import 'include-media-spread';
$breakpoints: (small: 480px, medium: 768px, large: 1024px);
.heading-1 {
@include spread(font-size, 1rem, 3rem);
}
Generates
/* Mobile first*/
.heading-1 {
font-size: 1rem;
}
@media (min-width: 480px) {
.heading-1 {
font-size: 1.67rem;
}
}
@media (min-width: 768px) {
.heading-1 {
font-size: 2.33rem;
}
}
@media (min-width: 1024px) {
.heading-1 {
font-size: 3rem;
}
}
Spread also allows you to pass a ease argument to accelerate or decelerate through the difference in values
// ease options - linear (default), in-quad, out-quad, in-cubic, out-cubic, in-quart, out-quart, in-quint, out-quint
.heading-1 {
// value increases on a curve, accelerating
@include spread(font-size, 1rem, 3rem, 'in-quad');
}
Allows you to pass top/right/bottom/left values and spread will calculate the difference between the single and multi values.
Example
.module-block {
@include spread(padding, 15px, 20px 30px 10px);
}
Generates
.module-block {
padding: 15px;
}
@media (min-width: 480px) {
.module-block {
padding: 16.67px 20px 13.33px 20px;
}
}
@media (min-width: 768px) {
.module-block {
padding: 18.33px 25px 11.67px 25px;
}
}
@media (min-width: 1024px) {
.module-block {
padding: 20px 30px 10px 30px;
}
}
You can either override globally the breakpoints Include Media Spread will use by default by setting $ims-breakpoints. By default it uses the default include-media breakpoints.
Example
$my-breakpoints: (small: 340px, large: 1000px);
$ims-breakpoints: $my-breakpoints;
@import 'include-media-spread';
Or you to pass custom-breakpoint per mixin.
Example
$custom-breakpoints: (small: 15em, large: 40em);
.module-block {
@include spread(padding, 10px, 30px, $breakpoints: $custom-breakpoints);
}
Generates
.module-block {
padding: 10px;
}
@media (min-width: 15em) {
.module-block {
padding: 20px;
}
}
@media (min-width: 40em) {
.module-block {
padding: 30px;
}
}
bower install include-media-spreadCredit to Doug Avery who a lot of code was borrowed from.
FAQs
An include-media plugin for spreading css properties over the breakpoints
The npm package include-media-spread receives a total of 12 weekly downloads. As such, include-media-spread popularity was classified as not popular.
We found that include-media-spread 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.

Product
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.

Security News
ENISA has become a CVE Program Root, giving the EU a central authority for coordinating vulnerability reporting, disclosure, and cross-border response.

Product
Socket now scans OpenVSX extensions, giving teams early detection of risky behaviors, hidden capabilities, and supply chain threats in developer tools.