Fix code quality violations and exclude Manifest from checks
Document application modes (development/debug/production) Add global file drop handler, order column normalization, SPA hash fix Serve CDN assets via /_vendor/ URLs instead of merging into bundles Add production minification with license preservation Improve JSON formatting for debugging and production optimization Add CDN asset caching with CSS URL inlining for production builds Add three-mode system (development, debug, production) Update Manifest CLAUDE.md to reflect helper class architecture Refactor Manifest.php into helper classes for better organization Pre-manifest-refactor checkpoint: Add app_mode documentation 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
27
node_modules/csso/lib/clean/Rule.js
generated
vendored
27
node_modules/csso/lib/clean/Rule.js
generated
vendored
@@ -1,10 +1,12 @@
|
||||
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
||||
var walk = require('css-tree').walk;
|
||||
var { hasNoChildren } = require('./utils');
|
||||
import { walk, keyword } from 'css-tree';
|
||||
import { hasNoChildren } from './utils.js';
|
||||
|
||||
const { hasOwnProperty } = Object.prototype;
|
||||
const skipUsageFilteringAtrule = new Set(['keyframes']);
|
||||
|
||||
function cleanUnused(selectorList, usageData) {
|
||||
selectorList.children.each(function(selector, item, list) {
|
||||
var shouldRemove = false;
|
||||
selectorList.children.forEach((selector, item, list) => {
|
||||
let shouldRemove = false;
|
||||
|
||||
walk(selector, function(node) {
|
||||
// ignore nodes in nested selectors
|
||||
@@ -71,19 +73,24 @@ function cleanUnused(selectorList, usageData) {
|
||||
}
|
||||
});
|
||||
|
||||
return selectorList.children.isEmpty();
|
||||
return selectorList.children.isEmpty;
|
||||
}
|
||||
|
||||
module.exports = function cleanRule(node, item, list, options) {
|
||||
export default function cleanRule(node, item, list, options) {
|
||||
if (hasNoChildren(node.prelude) || hasNoChildren(node.block)) {
|
||||
list.remove(item);
|
||||
return;
|
||||
}
|
||||
|
||||
var usageData = options.usage;
|
||||
// avoid usage filtering for some at-rules
|
||||
if (this.atrule && skipUsageFilteringAtrule.has(keyword(this.atrule.name).basename)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (usageData && (usageData.whitelist !== null || usageData.blacklist !== null)) {
|
||||
cleanUnused(node.prelude, usageData);
|
||||
const { usage } = options;
|
||||
|
||||
if (usage && (usage.whitelist !== null || usage.blacklist !== null)) {
|
||||
cleanUnused(node.prelude, usage);
|
||||
|
||||
if (hasNoChildren(node.prelude)) {
|
||||
list.remove(item);
|
||||
|
||||
Reference in New Issue
Block a user