GithubHelp home page GithubHelp logo

scriptex / itcss Goto Github PK

View Code? Open in Web Editor NEW
18.0 3.0 2.0 765 KB

Starter CSS boilerplate utilizing the ITCSS pattern

Home Page: https://itcss.atanas.info/

License: MIT License

CSS 96.30% JavaScript 3.70%
css-boilerplate itcss-boilerplate

itcss's Introduction

Inverted Triangle CSS Visualization

ITCSS

Travis CI Github Build Codacy Badge Codebeat Badge CodeFactor Badge DeepScan grade Analytics

A starter boilerplate based on the ITCSS (Inverted Triangle CSS) methodology.

Visitor stats

GitHub stars GitHub forks GitHub watchers GitHub followers

Code stats

GitHub code size in bytes GitHub repo size GitHub language count GitHub top language GitHub last commit

About

ITCSS is a mobile-first, responsive, battle-tested CSS framework based on the ITCSS methodology utilizing the BEM methodology.

This boilerplate is intented to be used as a starting point in your application. You should use this as a foundation for your CSS and build on top of it.

If you want to use the full capabilities of this boilerplate such as variables, mixins, etc., then you should include it in your PostCSS files.

You should also install the required PostCSS plugins and configure your PostCSS environment following the configuration file here

You can also use the build which is plain CSS but lacks mixins, custom media queries and other useful tools.

Install

# Via NPM
npm i itcss

# Via Yarn
yarn add itcss

Usage

If you are using a module bundler (such as Webpack, Parcel, Browserify):

# In your CSS entrypoint
@import 'itcss';

# Or if the above does not resolve, try
@import 'itcss/index.css';

There are several predefined variables which you can overwrite:

:root {
	/* Color Variables */
	--color-base: #333;
	--color-primary: #fff;
	--color-secondary: #000;
	--color-action: #ef4c23;

	/* Text Variables */
	--font-sans-serif: sans-serif;
	--font-serif: serif;
	--font-monospace: monospace;
	--font-size-base: 1rem;
	--line-height-base: 1.35;
	--font-size-h1: 2rem;
	--font-size-h2: 1.75rem;
	--font-size-h3: 1.5rem;
	--font-size-h4: 1.25rem;
	--font-size-h5: var(--font-size-base);
	--font-size-h6: 0.75rem;

	/* Transition Variables */
	--timing: 0.4s;
	--easing: ease-in-out;

	/* Spacing between grid items */
	$gap: 0.5rem;

	/* Number of columns in the grid */
	$columns: 12;

	/* The maximum width of the shell container */
	--shell-width: 75rem;

	/* The left and right padding of the shell container */
	$shell-gap: 1rem;

	/* A list of responsive breakpoint names */
	--breakpoints: (xs, sm, md, lg, xl);

	/* A list of display properties */
	--displays: (block, inline, inline-block, flex, inline-flex);

	/* A list of text alignment properties */
	--alignments: (center: center, right: right, left: left, justify: justify);
}

You should place the overwriting variables after the @import statement.

Supported browsers

This boilerplate is using the most recent version of the CSS specification. In order to support more browsers you must use a tool such as PostCSS. The combined and built version of this boilerplate is using the Postcss-Preset-Env in stage: 0. This means that you can use the most recent CSS features and be sure that they will work older browsers.

The combined and built version of this boilerplate has been tested and works in all evergreen browsers (Chrome, Firefox, Edge, Opera, Safari, Brave, Vivaldi, iOS Safari, Chrome on Android, Samsung Internet) and IE 10+.

In order to do so in your setup, please refer to the postcss.config.js file.

Available files, selectors, variables and their usage

Settings

  • _colors.css - contains CSS custom properties declared to the :root node for all colors
  • _text.css - contains CSS custom properties declared to the :root node for all font settings
  • _transitions.css - contains CSS custom properties declared to the :root node for transition duration and timing function
  • _variables.css - contains CSS custom properties declared to the :root node for all other variables/settings

Tools

  • _chevron.css - a mixin for a directional arrow icon

    Usage:

    /* prettier-ignore */
    @mixin chevron
    	2rem /* width and height */,
    	0 0 1px 1px /* border width */,
    	var(--color-action) /* border color */,
    	-5px 0 0 0.5em /* margin */,
    	-135deg /* rotation */;
  • _flexbox.css - a set of mixins for flexbox

    Contains several mixins:

    /* General purpose flex container */
    /* prettier-ignore */
    @mixin flex
    	center /* align-items */,
    	flex-end /* justify-content */,
        wrap /* flex-wrap */,
        row /* flex-direction */,
        flex /* display */;
    
    /* Flex container with flex-direction set to "row" */
    /* prettier-ignore */
    @mixin flex-row
    	no-wrap /* wrap */,
    	center /* align-items */,
    	flex-end /* justify-content */;
    
    /* Flex container with flex-direction set to "column" */
    /* prettier-ignore */
    @mixin flex-column
    	no-wrap /* wrap */
    	center /* align-items */
    	flex-end /* justify-content */;
    
    /* Inline-flex container with flex-direction set to "row" */
    /* prettier-ignore */
    @mixin inline-flex-row
    	no-wrap /* wrap */,
    	center /* align-items */,
    	flex-end /* justify-content */;
    
    /* Inline-flex container with flex-direction set to "column" */
    /* prettier-ignore */
    @mixin inline-flex-column
    	no-wrap /* wrap */
    	center /* align-items */
    	flex-end /* justify-content */;
    
    /* Inline-flex container with flex-direction set to "row" */
    /* prettier-ignore */
    @mixin inline-flex-row
    	no-wrap /* wrap */,
    	center /* align-items */,
    	flex-end /* justify-content */;
    
    /* Inline-flex container with flex-direction set to "column" */
    /* prettier-ignore */
    @mixin inline-flex-column
    	no-wrap /* wrap */
    	center /* align-items */
    	flex-end /* justify-content */;
  • _media-queries.css - mixins for all supported media queries

    Custom media queries:

    /* (max-width: 1439px) */
    @media (--small-desktop) {
    }
    
    /* (max-width: 1279px) */
    @media (--tablet-landscape) {
    }
    
    /* (max-width: 1023px) */
    @media (--tablet-portrait) {
    }
    
    /* (max-width: 767px) */
    @media (--mobile) {
    }
    
    /* (max-width: 767px) */
    @media (--xs) {
    }
    
    /* (min-width: 768px) and (max-width: 1023px) */
    @media (--sm) {
    }
    
    /* (min-width: 1024px) and (max-width: 1279px) */
    @media (--md) {
    }
    
    /* (min-width: 1280px) and (max-width: 1439px) */
    @media (--lg) {
    }
    
    /* (min-width: 1439px) */
    @media (--xl) {
    }
    
    /* (min-width: 0) */
    @media (--xs-up) {
    }
    /* (min-width: 768px) */
    @media (--sm-up) {
    }
    /* (min-width: 1024px) */
    @media (--md-up) {
    }
    /* (min-width: 1280px) */
    @media (--lg-up) {
    }
    /* (min-width: 1439px) */
    @media (--xl-up) {
    }
    
    /* (prefers-reduced-motion: reduce) */
    @media (--reduced-motion) {
    }
    
    /* hover support */
    @media (--hover) {
    } ;
  • _mixins.css - all other mixins

    Available mixins:

    /* absolutely positions an element with known dimensions in the center of their relative parent element */
    @mixin centered;
    
    /**
    	generates rules for responsive helpers
    	$breakpoint: a breakpoint prefix such as xs, sm, md, lg or xl
    */
    @mixin breakpoint-helpers $breakpoint;
    
    /* creates !important declaration for the given $display argument */
    @mixin display $value;
    
    /**
    	generates rules for grid columns for a given breakpoint
    	$breakpoint: a breakpoint prefix such as xs, sm, md, lg or xl
    */
    @mixin grid $breakpoint;

Generic

  • _form-elements.css - default styles for form elements
  • _reset.css - additional browser reset and normalize (normalize.css is also included)
  • _transitions.css - default transitions for focusable/active elements

Elements

  • _document.css - default styles for the body element
  • _headings.css - default styles for all heading (h1 - h6) tags
  • _links.css - default styles for anchors
  • _texts.css - default styles for text elements

Objects

  • _grid.css - a grid system

    Available selectors are:

    /* defines a grid container */
    .o-grid {
    }
    
    /* defines a grid item */
    .o-grid__item {
    }
    
    /**
    	depending on the --breakpoints variables
    	the following selectors will vary.
    	1 means 1/12 of the available width.
    	12 means all of the available width.
    	Here are the defaults
    */
    /* From 0 to 767px */
    .xs-1 to .xs-12
    /* From 768px to 1023px */
    .sm-1 to .sm-12
    /* From 1024px to 1279px */
    .md-1 to .md-12
    /* From 1280px to 1439px */
    .lg-1 to .lg-12
    /* From 1440px above */
    .xl-1 to .xl-12;
  • _main.css - styles for the main element

    Available selectors are:

    /* defines the main content. used with <main> element */
    .o-main {
    }
  • _shell.css - styles for the site container

    Available selectors are:

    /* defines the site container */
    .o-shell {
    }
    
    /* defines the site container as flex container */
    .o-shell--flex {
    }
    
    /* makes the site container take the whole browser width */
    .o-shell--fluid {
    }
  • _wrapper.css - styles for the site wrapper

    Available selectors are:

    /* defines the parent container of all other elements. usually the only child of the <body> element */
    .o-wrapper {
    }

Components

  • _btn.css - default styles for the buttons

    Available selectors are:

    /* default styles for a button */
    .c-btn {
    }
    
    /* makes the button fill its parent's width */
    .c-btn--block {
    }
  • _list.css - default styles for lists. A list is an element with a classname which starts with c-list

Utilities

  • _align.css - alignment class utilities

    Available selectors are:

    /* align to the left */
    .alignleft {
    }
    
    /* align to the right */
    .alignright {
    }
    
    /* clear the alignment */
    .alignnone {
    }
    
    /* clear the alignment and center horizontally */
    .aligncenter {
    }
  • _clear.scss - utilites to clear after floats

    Available selectors are:

    /* clear both */
    .clear {
    }
    /* clear right */
    .clear-right {
    }
    /* clear left */
    .clear-left {
    }
  • _fullsize-background.css - helper for background image

    Available selectors are:

    /* makes the element's background image take the whole size of the element using "background-size: cover" */
    .fullsize-background {
    }
  • _hidden.css - helper class/attribute for hidden elements

    Available selectors are:

    .hidden,
    [hidden] {
    }
  • _preferences.css - contains user preferences settings such as reduced-motion or prefers-color-scheme preferences.

  • _responsive-utilities.css - helpers for showing/hiding elements on different resolutions. For resolutions reference please check the media queries section.

    Available selectors are:

    .visible-xs-block {
    }
    .visible-xs-inline {
    }
    .visible-xs-inline-block {
    }
    .visible-xs-flex {
    }
    .visible-xs-inline-flex {
    }
    .visible-sm-block {
    }
    .visible-sm-inline {
    }
    .visible-sm-inline-block {
    }
    .visible-sm-flex {
    }
    .visible-sm-inline-flex {
    }
    .visible-md-block {
    }
    .visible-md-inline {
    }
    .visible-md-inline-block {
    }
    .visible-md-flex {
    }
    .visible-md-inline-flex {
    }
    .visible-lg-block {
    }
    .visible-lg-inline {
    }
    .visible-lg-inline-block {
    }
    .visible-lg-flex {
    }
    .visible-lg-inline-flex {
    }
    .visible-xl-block {
    }
    .visible-xl-inline {
    }
    .visible-xl-inline-block {
    }
    .visible-xl-flex {
    }
    .visible-xl-inline-flex {
    }
    .hidden-xs {
    }
    .hidden-sm {
    }
    .hidden-md {
    }
    .hidden-lg {
    }
    .hidden-xl {
    }
  • _text-align.css - text alignment utilities

    Available selectors are:

    /* align text to the left */
    .text-left {
    }
    /* align text to the center */
    .text-center {
    }
    /* align text to the right */
    .text-right {
    }
    /* align text to the right */
    .text-justify {
    }

LICENSE

MIT


Connect with me:

                     

Support and sponsor my work:

itcss's People

Contributors

dependabot[bot] avatar greenkeeper[bot] avatar renovate-bot avatar renovate[bot] avatar scriptex avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

itcss's Issues

CVE-2021-23364 (Medium) detected in browserslist-4.16.3.tgz

CVE-2021-23364 - Medium Severity Vulnerability

Vulnerable Library - browserslist-4.16.3.tgz

Share target browsers between different front-end tools, like Autoprefixer, Stylelint and babel-env-preset

Library home page: https://registry.npmjs.org/browserslist/-/browserslist-4.16.3.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/browserslist/package.json

Dependency Hierarchy:

  • browserslist-4.16.3.tgz (Vulnerable Library)

Found in base branch: master

Vulnerability Details

The package browserslist from 4.0.0 and before 4.16.5 are vulnerable to Regular Expression Denial of Service (ReDoS) during parsing of queries.

Publish Date: 2021-04-28

URL: CVE-2021-23364

CVSS 3 Score Details (5.3)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: Low

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-23364

Release Date: 2021-04-28

Fix Resolution: browserslist - 4.16.5


Step up your Open Source Security Game with WhiteSource here

CVE-2021-3807 (Medium) detected in ansi-regex-2.1.1.tgz, ansi-regex-5.0.0.tgz

CVE-2021-3807 - Medium Severity Vulnerability

Vulnerable Libraries - ansi-regex-2.1.1.tgz, ansi-regex-5.0.0.tgz

ansi-regex-2.1.1.tgz

Regular expression for matching ANSI escape codes

Library home page: https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/ansi-regex/package.json

Dependency Hierarchy:

  • postcss-for-2.1.1.tgz (Root Library)
    • postcss-5.2.18.tgz
      • chalk-1.1.3.tgz
        • strip-ansi-3.0.1.tgz
          • ansi-regex-2.1.1.tgz (Vulnerable Library)
ansi-regex-5.0.0.tgz

Regular expression for matching ANSI escape codes

Library home page: https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/ansi-regex/package.json

Dependency Hierarchy:

  • postcss-cli-8.3.1.tgz (Root Library)
    • yargs-16.2.0.tgz
      • cliui-7.0.4.tgz
        • strip-ansi-6.0.0.tgz
          • ansi-regex-5.0.0.tgz (Vulnerable Library)

Found in HEAD commit: 7cd1535f94f334b981f4810c3d8cb7f1f4a2276d

Vulnerability Details

ansi-regex is vulnerable to Inefficient Regular Expression Complexity

Publish Date: 2021-09-17

URL: CVE-2021-3807

CVSS 3 Score Details (5.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: N/A
    • Attack Complexity: N/A
    • Privileges Required: N/A
    • User Interaction: N/A
    • Scope: N/A
  • Impact Metrics:
    • Confidentiality Impact: N/A
    • Integrity Impact: N/A
    • Availability Impact: N/A

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: https://huntr.dev/bounties/5b3cf33b-ede0-4398-9974-800876dfd994/

Release Date: 2021-09-17

Fix Resolution: ansi-regex - 5.0.1,6.0.1


Step up your Open Source Security Game with WhiteSource here

Fix hover media query

Needs to be @custom-media --hover (-ms-high-contrast: none), (-ms-high-contrast: active), (-moz-touch-enabled: 0), (hover);
Also, install postcss-custom-media.

CVE-2021-35065 (High) detected in glob-parent-5.1.2.tgz

CVE-2021-35065 - High Severity Vulnerability

Vulnerable Library - glob-parent-5.1.2.tgz

Extract the non-magic parent path from a glob string.

Library home page: https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz

Path to dependency file: /package.json

Path to vulnerable library: /node_modules/glob-parent/package.json

Dependency Hierarchy:

  • postcss-mixins-9.0.1.tgz (Root Library)
    • fast-glob-3.2.7.tgz
      • glob-parent-5.1.2.tgz (Vulnerable Library)

Found in HEAD commit: 6fdb8fef5000389ed68a0912f073d85e5d890e52

Vulnerability Details

The package glob-parent before 6.0.1 are vulnerable to Regular Expression Denial of Service (ReDoS)

Publish Date: 2021-06-22

URL: CVE-2021-35065

CVSS 3 Score Details (7.5)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: High

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: gulpjs/glob-parent#49

Release Date: 2021-06-22

Fix Resolution: glob-parent - 6.0.1


Step up your Open Source Security Game with WhiteSource here

WS-2020-0070 (High) detected in lodash-4.17.15.tgz

WS-2020-0070 - High Severity Vulnerability

Vulnerable Library - lodash-4.17.15.tgz

Lodash modular utilities.

Library home page: https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz

Path to dependency file: /tmp/ws-scm/itcss/package.json

Path to vulnerable library: /tmp/ws-scm/itcss/node_modules/lodash/package.json

Dependency Hierarchy:

  • postcss-easy-import-3.0.0.tgz (Root Library)
    • lodash-4.17.15.tgz (Vulnerable Library)

Found in HEAD commit: 4314a1cc0db38026a1926fff9db498d805440097

Vulnerability Details

a prototype pollution vulnerability in lodash. It allows an attacker to inject properties on Object.prototype

Publish Date: 2020-04-28

URL: WS-2020-0070

CVSS 3 Score Details (8.1)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: High
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: High
    • Availability Impact: High

For more information on CVSS3 Scores, click here.


Step up your Open Source Security Game with WhiteSource here

CVE-2021-23343 (Medium) detected in path-parse-1.0.6.tgz

CVE-2021-23343 - Medium Severity Vulnerability

Vulnerable Library - path-parse-1.0.6.tgz

Node.js path.parse() ponyfill

Library home page: https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/path-parse/package.json

Dependency Hierarchy:

  • postcss-easy-import-3.0.0.tgz (Root Library)
    • resolve-1.20.0.tgz
      • path-parse-1.0.6.tgz (Vulnerable Library)

Found in HEAD commit: 1e4e1ea2f02b3b32321f0ecacf3e76bf624a51c7

Found in base branch: master

Vulnerability Details

All versions of package path-parse are vulnerable to Regular Expression Denial of Service (ReDoS) via splitDeviceRe, splitTailRe, and splitPathRe regular expressions. ReDoS exhibits polynomial worst-case time complexity.

Publish Date: 2021-05-04

URL: CVE-2021-23343

CVSS 3 Score Details (5.3)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: Low

For more information on CVSS3 Scores, click here.


Step up your Open Source Security Game with WhiteSource here

CVE-2019-20149 (Medium) detected in multiple libraries

CVE-2019-20149 - Medium Severity Vulnerability

Vulnerable Libraries - kind-of-3.2.2.tgz, kind-of-4.0.0.tgz, kind-of-6.0.2.tgz, kind-of-5.1.0.tgz

kind-of-3.2.2.tgz

Get the native type of a value.

Library home page: https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz

Path to dependency file: /tmp/ws-scm/itcss/package.json

Path to vulnerable library: /tmp/ws-scm/itcss/node_modules/is-accessor-descriptor/node_modules/kind-of/package.json

Dependency Hierarchy:

  • postcss-mixins-6.2.3.tgz (Root Library)
    • globby-8.0.2.tgz
      • fast-glob-2.2.7.tgz
        • micromatch-3.1.10.tgz
          • snapdragon-0.8.2.tgz
            • base-0.11.2.tgz
              • class-utils-0.3.6.tgz
                • static-extend-0.1.2.tgz
                  • object-copy-0.1.0.tgz
                    • kind-of-3.2.2.tgz (Vulnerable Library)
kind-of-4.0.0.tgz

Get the native type of a value.

Library home page: https://registry.npmjs.org/kind-of/-/kind-of-4.0.0.tgz

Path to dependency file: /tmp/ws-scm/itcss/package.json

Path to vulnerable library: /tmp/ws-scm/itcss/node_modules/has-values/node_modules/kind-of/package.json

Dependency Hierarchy:

  • postcss-mixins-6.2.3.tgz (Root Library)
    • globby-8.0.2.tgz
      • fast-glob-2.2.7.tgz
        • micromatch-3.1.10.tgz
          • snapdragon-0.8.2.tgz
            • base-0.11.2.tgz
              • cache-base-1.0.1.tgz
                • has-value-1.0.0.tgz
                  • has-values-1.0.0.tgz
                    • kind-of-4.0.0.tgz (Vulnerable Library)
kind-of-6.0.2.tgz

Get the native type of a value.

Library home page: https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz

Path to dependency file: /tmp/ws-scm/itcss/package.json

Path to vulnerable library: /tmp/ws-scm/itcss/node_modules/kind-of/package.json

Dependency Hierarchy:

  • postcss-mixins-6.2.3.tgz (Root Library)
    • globby-8.0.2.tgz
      • fast-glob-2.2.7.tgz
        • micromatch-3.1.10.tgz
          • kind-of-6.0.2.tgz (Vulnerable Library)
kind-of-5.1.0.tgz

Get the native type of a value.

Library home page: https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz

Path to dependency file: /tmp/ws-scm/itcss/package.json

Path to vulnerable library: /tmp/ws-scm/itcss/node_modules/is-descriptor/node_modules/kind-of/package.json

Dependency Hierarchy:

  • postcss-mixins-6.2.3.tgz (Root Library)
    • globby-8.0.2.tgz
      • fast-glob-2.2.7.tgz
        • micromatch-3.1.10.tgz
          • snapdragon-0.8.2.tgz
            • define-property-0.2.5.tgz
              • is-descriptor-0.1.6.tgz
                • kind-of-5.1.0.tgz (Vulnerable Library)

Found in HEAD commit: 4512e5baee019edc21505cc49ceeada1120aeca3

Vulnerability Details

ctorName in index.js in kind-of v6.0.2 allows external user input to overwrite certain internal attributes via a conflicting name, as demonstrated by 'constructor': {'name':'Symbol'}. Hence, a crafted payload can overwrite this builtin attribute to manipulate the type detection result.

Publish Date: 2019-12-30

URL: CVE-2019-20149

CVSS 2 Score Details (5.0)

Base Score Metrics not available


Step up your Open Source Security Game with WhiteSource here

Dependency Dashboard

This issue provides visibility into Renovate updates and their statuses. Learn more

This repository currently has no open or pending branches.


  • Check this box to trigger a request for Renovate to run again on this repository

CVE-2019-10744 (High) detected in lodash-4.17.11.tgz

CVE-2019-10744 - High Severity Vulnerability

Vulnerable Library - lodash-4.17.11.tgz

Lodash modular utilities.

Library home page: https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz

Path to dependency file: /itcss/package.json

Path to vulnerable library: /tmp/git/itcss/node_modules/lodash/package.json

Dependency Hierarchy:

  • postcss-easy-import-3.0.0.tgz (Root Library)
    • lodash-4.17.11.tgz (Vulnerable Library)

Found in HEAD commit: ded44892bfaeaf9ca844b91284e4862b1f58337d

Vulnerability Details

A Prototype Pollution vulnerability was found in lodash through version 4.17.11.

Publish Date: 2019-07-08

URL: CVE-2019-10744

CVSS 2 Score Details (7.4)

Base Score Metrics not available

Suggested Fix

Type: Upgrade version

Origin: lodash/lodash@a01e4fa

Release Date: 2019-07-08

Fix Resolution: 4.17.12


Step up your Open Source Security Game with WhiteSource here

Action Required: Fix Renovate Configuration

There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.

Error type: undefined. Note: this is a nested preset so please contact the preset author if you are unable to fix it yourself.

CVE-2021-23382 (Medium) detected in multiple libraries

CVE-2021-23382 - Medium Severity Vulnerability

Vulnerable Libraries - postcss-5.2.18.tgz, postcss-6.0.23.tgz, postcss-7.0.35.tgz

postcss-5.2.18.tgz

Tool for transforming styles with JS plugins

Library home page: https://registry.npmjs.org/postcss/-/postcss-5.2.18.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/postcss-extend/node_modules/postcss/package.json,itcss/node_modules/postcss-for/node_modules/postcss/package.json

Dependency Hierarchy:

  • postcss-extend-1.0.5.tgz (Root Library)
    • postcss-5.2.18.tgz (Vulnerable Library)
postcss-6.0.23.tgz

Tool for transforming styles with JS plugins

Library home page: https://registry.npmjs.org/postcss/-/postcss-6.0.23.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/postcss-import/node_modules/postcss/package.json,itcss/node_modules/postcss-easy-import/node_modules/postcss/package.json,itcss/node_modules/postcss-each-variables/node_modules/postcss/package.json

Dependency Hierarchy:

  • postcss-easy-import-3.0.0.tgz (Root Library)
    • postcss-6.0.23.tgz (Vulnerable Library)
postcss-7.0.35.tgz

Tool for transforming styles with JS plugins

Library home page: https://registry.npmjs.org/postcss/-/postcss-7.0.35.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/postcss-lab-function/node_modules/postcss/package.json,itcss/node_modules/css-prefers-color-scheme/node_modules/postcss/package.json,itcss/node_modules/postcss-attribute-case-insensitive/node_modules/postcss/package.json,itcss/node_modules/postcss-font-variant/node_modules/postcss/package.json,itcss/node_modules/postcss-focus-visible/node_modules/postcss/package.json,itcss/node_modules/postcss-color-gray/node_modules/postcss/package.json,itcss/node_modules/postcss-utilities/node_modules/postcss/package.json,itcss/node_modules/postcss-place/node_modules/postcss/package.json,itcss/node_modules/postcss-initial/node_modules/postcss/package.json,itcss/node_modules/postcss-color-mod-function/node_modules/postcss/package.json,itcss/node_modules/autoprefixer/node_modules/postcss/package.json,itcss/node_modules/postcss-overflow-shorthand/node_modules/postcss/package.json,itcss/node_modules/postcss-selector-matches/node_modules/postcss/package.json,itcss/node_modules/postcss-gap-properties/node_modules/postcss/package.json,itcss/node_modules/postcss-image-set-function/node_modules/postcss/package.json,itcss/node_modules/postcss-dir-pseudo-class/node_modules/postcss/package.json,itcss/node_modules/postcss-selector-not/node_modules/postcss/package.json,itcss/node_modules/postcss-simple-vars/node_modules/postcss/package.json,itcss/node_modules/postcss-color-rebeccapurple/node_modules/postcss/package.json,itcss/node_modules/postcss-double-position-gradients/node_modules/postcss/package.json,itcss/node_modules/postcss-preset-env/node_modules/postcss/package.json,itcss/node_modules/postcss-logical/node_modules/postcss/package.json,itcss/node_modules/postcss-pseudo-class-any-link/node_modules/postcss/package.json,itcss/node_modules/postcss-custom-properties/node_modules/postcss/package.json,itcss/node_modules/postcss-focus-within/node_modules/postcss/package.json,itcss/node_modules/postcss-media-minmax/node_modules/postcss/package.json,itcss/node_modules/postcss-nesting/node_modules/postcss/package.json,itcss/node_modules/css-has-pseudo/node_modules/postcss/package.json,itcss/node_modules/postcss-custom-selectors/node_modules/postcss/package.json,itcss/node_modules/postcss-page-break/node_modules/postcss/package.json,itcss/node_modules/postcss-color-hex-alpha/node_modules/postcss/package.json,itcss/node_modules/postcss-color-functional-notation/node_modules/postcss/package.json,itcss/node_modules/postcss-browser-comments/node_modules/postcss/package.json,itcss/node_modules/postcss-env-function/node_modules/postcss/package.json,itcss/node_modules/css-blank-pseudo/node_modules/postcss/package.json,itcss/node_modules/postcss-replace-overflow-wrap/node_modules/postcss/package.json,itcss/node_modules/postcss-normalize/node_modules/postcss/package.json

Dependency Hierarchy:

  • postcss-preset-env-6.7.0.tgz (Root Library)
    • postcss-dir-pseudo-class-5.0.0.tgz
      • postcss-7.0.35.tgz (Vulnerable Library)

Found in HEAD commit: 2ed1a1112b545fab4b7b6836f3241d9cfd835e36

Found in base branch: master

Vulnerability Details

The package postcss before 8.2.13 are vulnerable to Regular Expression Denial of Service (ReDoS) via getAnnotationURL() and loadAnnotation() in lib/previous-map.js. The vulnerable regexes are caused mainly by the sub-pattern /*\s* sourceMappingURL=(.*).

Publish Date: 2021-04-26

URL: CVE-2021-23382

CVSS 3 Score Details (5.3)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: Low

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-23382

Release Date: 2021-04-26

Fix Resolution: postcss - 8.2.13


Step up your Open Source Security Game with WhiteSource here

Optimize flexbox usage

Add a better and more comprehensive flexbox mixin.
Explore possible split and introduction of many smaller mixins.

CVE-2021-23368 (Medium) detected in postcss-7.0.35.tgz

CVE-2021-23368 - Medium Severity Vulnerability

Vulnerable Library - postcss-7.0.35.tgz

Tool for transforming styles with JS plugins

Library home page: https://registry.npmjs.org/postcss/-/postcss-7.0.35.tgz

Path to dependency file: itcss/package.json

Path to vulnerable library: itcss/node_modules/postcss-lab-function/node_modules/postcss/package.json,itcss/node_modules/css-prefers-color-scheme/node_modules/postcss/package.json,itcss/node_modules/postcss-attribute-case-insensitive/node_modules/postcss/package.json,itcss/node_modules/postcss-font-variant/node_modules/postcss/package.json,itcss/node_modules/postcss-focus-visible/node_modules/postcss/package.json,itcss/node_modules/postcss-color-gray/node_modules/postcss/package.json,itcss/node_modules/postcss-utilities/node_modules/postcss/package.json,itcss/node_modules/postcss-place/node_modules/postcss/package.json,itcss/node_modules/postcss-initial/node_modules/postcss/package.json,itcss/node_modules/postcss-color-mod-function/node_modules/postcss/package.json,itcss/node_modules/autoprefixer/node_modules/postcss/package.json,itcss/node_modules/postcss-overflow-shorthand/node_modules/postcss/package.json,itcss/node_modules/postcss-selector-matches/node_modules/postcss/package.json,itcss/node_modules/postcss-gap-properties/node_modules/postcss/package.json,itcss/node_modules/postcss-image-set-function/node_modules/postcss/package.json,itcss/node_modules/postcss-dir-pseudo-class/node_modules/postcss/package.json,itcss/node_modules/postcss-selector-not/node_modules/postcss/package.json,itcss/node_modules/postcss-simple-vars/node_modules/postcss/package.json,itcss/node_modules/postcss-color-rebeccapurple/node_modules/postcss/package.json,itcss/node_modules/postcss-double-position-gradients/node_modules/postcss/package.json,itcss/node_modules/postcss-preset-env/node_modules/postcss/package.json,itcss/node_modules/postcss-logical/node_modules/postcss/package.json,itcss/node_modules/postcss-pseudo-class-any-link/node_modules/postcss/package.json,itcss/node_modules/postcss-custom-properties/node_modules/postcss/package.json,itcss/node_modules/postcss-focus-within/node_modules/postcss/package.json,itcss/node_modules/postcss-media-minmax/node_modules/postcss/package.json,itcss/node_modules/postcss-nesting/node_modules/postcss/package.json,itcss/node_modules/css-has-pseudo/node_modules/postcss/package.json,itcss/node_modules/postcss-custom-selectors/node_modules/postcss/package.json,itcss/node_modules/postcss-page-break/node_modules/postcss/package.json,itcss/node_modules/postcss-color-hex-alpha/node_modules/postcss/package.json,itcss/node_modules/postcss-color-functional-notation/node_modules/postcss/package.json,itcss/node_modules/postcss-browser-comments/node_modules/postcss/package.json,itcss/node_modules/postcss-env-function/node_modules/postcss/package.json,itcss/node_modules/css-blank-pseudo/node_modules/postcss/package.json,itcss/node_modules/postcss-replace-overflow-wrap/node_modules/postcss/package.json,itcss/node_modules/postcss-normalize/node_modules/postcss/package.json

Dependency Hierarchy:

  • postcss-preset-env-6.7.0.tgz (Root Library)
    • postcss-dir-pseudo-class-5.0.0.tgz
      • postcss-7.0.35.tgz (Vulnerable Library)

Found in HEAD commit: 2ed1a1112b545fab4b7b6836f3241d9cfd835e36

Found in base branch: master

Vulnerability Details

The package postcss from 7.0.0 and before 8.2.10 are vulnerable to Regular Expression Denial of Service (ReDoS) during source map parsing.

Publish Date: 2021-04-12

URL: CVE-2021-23368

CVSS 3 Score Details (5.3)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Network
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: None
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: None
    • Integrity Impact: None
    • Availability Impact: Low

For more information on CVSS3 Scores, click here.

Suggested Fix

Type: Upgrade version

Origin: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-23368

Release Date: 2021-04-12

Fix Resolution: postcss -8.2.10


Step up your Open Source Security Game with WhiteSource here

Modern media queries

Introduce media queries for reduced motion or dark/light mode.

Example:

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

More examples and reference: https://developer.mozilla.org/en-US/docs/Web/CSS/@media

WS-2019-0063 (High) detected in js-yaml-3.13.1.tgz

WS-2019-0063 - High Severity Vulnerability

Vulnerable Library - js-yaml-3.13.1.tgz

YAML 1.2 parser and serializer

Library home page: https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz

Path to dependency file: /itcss/package.json

Path to vulnerable library: /tmp/git/itcss/node_modules/js-yaml/package.json

Dependency Hierarchy:

  • postcss-cli-6.1.3.tgz (Root Library)
    • postcss-load-config-2.1.0.tgz
      • cosmiconfig-5.2.1.tgz
        • js-yaml-3.13.1.tgz (Vulnerable Library)

Found in HEAD commit: c32174de5b94a392c8abeb1333a8c318f9d0455c

Vulnerability Details

Js-yaml prior to 3.13.1 are vulnerable to Code Injection. The load() function may execute arbitrary code injected through a malicious YAML file.

Publish Date: 2019-04-30

URL: WS-2019-0063

CVSS 2 Score Details (8.0)

Base Score Metrics not available

Suggested Fix

Type: Upgrade version

Origin: https://www.npmjs.com/advisories/813

Release Date: 2019-04-30

Fix Resolution: 3.13.1


Step up your Open Source Security Game with WhiteSource here

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.