文件操作 - IdSelector.js
返回文件管理
返回主菜单
删除本文件
文件: /var/www/OLD/node_modules/csso/node_modules/css-tree/lib/syntax/node/IdSelector.js
编辑文件内容
import { Hash, Delim } from '../../tokenizer/index.js'; export const name = 'IdSelector'; export const structure = { name: String }; export function parse() { const start = this.tokenStart; // TODO: check value is an ident this.eat(Hash); return { type: 'IdSelector', loc: this.getLocation(start, this.tokenStart), name: this.substrToCursor(start + 1) }; } export function generate(node) { // Using Delim instead of Hash is a hack to avoid for a whitespace between ident and id-selector // in safe mode (e.g. "a#id"), because IE11 doesn't allow a sequence <ident-token> <hash-token> // without a whitespace in values (e.g. "1px solid#000") this.token(Delim, '#' + node.name); }
修改文件时间
将文件时间修改为当前时间的前一年
删除文件