Download node_modules/autoprefixer/lib/hacks/grid-area.js from jayvatliq/car-view-classifier-frontend: direct link, hf CLI and curl.
- Browser
- Download file 891 Bytes
-
https://huggingface.co/spaces/jayvatliq/car-view-classifier-frontend/resolve/main/node_modules/autoprefixer/lib/hacks/grid-area.js
- Command line
-
hf download hf://spaces/jayvatliq/car-view-classifier-frontend/node_modules/autoprefixer/lib/hacks/grid-area.js
-
curl -L -o grid-area.js https://huggingface.co/spaces/jayvatliq/car-view-classifier-frontend/resolve/main/node_modules/autoprefixer/lib/hacks/grid-area.js
891 Bytes
| let Declaration = require('../declaration') | |
| let utils = require('./grid-utils') | |
| class GridArea extends Declaration { | |
| /** | |
| * Translate grid-area to separate -ms- prefixed properties | |
| */ | |
| insert(decl, prefix, prefixes, result) { | |
| if (prefix !== '-ms-') return super.insert(decl, prefix, prefixes) | |
| let values = utils.parse(decl) | |
| let [rowStart, rowSpan] = utils.translate(values, 0, 2) | |
| let [columnStart, columnSpan] = utils.translate(values, 1, 3) | |
| ;[ | |
| ['grid-row', rowStart], | |
| ['grid-row-span', rowSpan], | |
| ['grid-column', columnStart], | |
| ['grid-column-span', columnSpan] | |
| ].forEach(([prop, value]) => { | |
| utils.insertDecl(decl, prop, value) | |
| }) | |
| utils.warnTemplateSelectorNotFound(decl, result) | |
| utils.warnIfGridRowColumnExists(decl, result) | |
| return undefined | |
| } | |
| } | |
| GridArea.names = ['grid-area'] | |
| module.exports = GridArea | |