Software: Apache. PHP/8.1.30 uname -a: Linux server1.tuhinhossain.com 5.15.0-163-generic #173-Ubuntu SMP Tue Oct 14 17:51:00 UTC uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root) Safe-mode: OFF (not secure) /home/picotech/domains/rentals.picotech.app/public_html/node_modules/css-tree/lib/syntax/node/ drwxr-xr-x | |
| Viewing file: Select action/file-type: import {
Delim,
Number as NumberToken,
Function as FunctionToken
} from '../../tokenizer/index.js';
const SOLIDUS = 0x002F; // U+002F SOLIDUS (/)
// Media Queries Level 3 defines terms of <ratio> as a positive (not zero or negative)
// integers (see https://drafts.csswg.org/mediaqueries-3/#values)
// However, Media Queries Level 4 removes any definition of values
// (see https://drafts.csswg.org/mediaqueries-4/#values) and refers to
// CSS Values and Units for detail. In CSS Values and Units Level 4 a <ratio>
// definition was added (see https://drafts.csswg.org/css-values-4/#ratios) which
// defines ratio as "<number [0,∞]> [ / <number [0,∞]> ]?" and based on it
// any constrains on terms were removed. Parser also doesn't test numbers
// in any way to make possible for linting and fixing them by the tools using CSSTree.
// An additional syntax examination may be applied by a lexer.
function consumeTerm() {
this.skipSC();
switch (this.tokenType) {
case NumberToken:
return this.Number();
case FunctionToken:
return this.Function(this.readSequence, this.scope.Value);
default:
this.error('Number of function is expected');
}
}
export const name = 'Ratio';
export const structure = {
left: ['Number', 'Function'],
right: ['Number', 'Function', null]
};
// <number [0,∞]> [ / <number [0,∞]> ]?
export function parse() {
const start = this.tokenStart;
const left = consumeTerm.call(this);
let right = null;
this.skipSC();
if (this.isDelim(SOLIDUS)) {
this.eatDelim(SOLIDUS);
right = consumeTerm.call(this);
}
return {
type: 'Ratio',
loc: this.getLocation(start, this.tokenStart),
left,
right
};
}
export function generate(node) {
this.node(node.left);
this.token(Delim, '/');
if (node.right) {
this.node(node.right);
} else {
this.node(NumberToken, 1);
}
}
|
:: Command execute :: | |
--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0033 ]-- |