Sha256: 505461ee5791f81b266d33317a6d15a3efb4287230d6a68deb743371ada266ba

Contents?: true

Size: 1005 Bytes

Versions: 19

Compression:

Stored size: 1005 Bytes

Contents

var TYPE = require('../../tokenizer').TYPE;

var STRING = TYPE.String;
var IDENTIFIER = TYPE.Identifier;
var URL = TYPE.Url;
var LEFTPARENTHESIS = TYPE.LeftParenthesis;

module.exports = {
    parse: {
        prelude: function() {
            var children = this.createList();

            this.scanner.skipSC();

            switch (this.scanner.tokenType) {
                case STRING:
                    children.push(this.String());
                    break;

                case URL:
                    children.push(this.Url());
                    break;

                default:
                    this.scanner.error('String or url() is expected');
            }

            if (this.scanner.lookupNonWSType(0) === IDENTIFIER ||
                this.scanner.lookupNonWSType(0) === LEFTPARENTHESIS) {
                children.push(this.WhiteSpace());
                children.push(this.MediaQueryList());
            }

            return children;
        },
        block: null
    }
};

Version data entries

19 entries across 18 versions & 4 rubygems

Version Path
disco_app-0.18.0 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.18.2 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.16.1 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.15.2 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.18.4 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.18.1 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.14.0 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
disco_app-0.13.6.pre.puma.pre.3 test/dummy/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
jester-data-8.0.0 node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
ezii-os-5.2.1 node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
ezii-os-2.0.1 node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
ezii-os-1.1.0 node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
ezii-os-1.0.0 node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
ezii-os-0.0.0.1.0 node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
ezii-os-0.0.0.0.1 node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
locomotivecms-4.0.0.alpha1 app/javascript/node_modules/css-tree/lib/syntax/atrule/import.js
locomotivecms-4.0.0.alpha1 app/javascript/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js
locomotivecms-3.4.0 app/javascript/node_modules/csso/node_modules/css-tree/lib/syntax/atrule/import.js