1
0
mirror of https://github.com/thangisme/notes.git synced 2024-11-01 00:27:24 -04:00
notes/node_modules/postcss-less/dist/is-mixin-token.js
Patrick Marsceill b7b0d0d7bf
Initial commit
2017-03-09 13:16:08 -05:00

24 lines
676 B
JavaScript

'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = isMixinToken;
var _globals = require('./tokenizer/globals');
var unpaddedFractionalNumbersPattern = /\.[0-9]/;
function isMixinToken(token) {
var symbol = token[1];
var firstSymbolCode = symbol ? symbol[0].charCodeAt(0) : null;
return (firstSymbolCode === _globals.dot || firstSymbolCode === _globals.hash) &&
// ignore hashes used for colors
_globals.hashColorPattern.test(symbol) === false &&
// ignore dots used for unpadded fractional numbers
unpaddedFractionalNumbersPattern.test(symbol) === false;
}
module.exports = exports['default'];