xatriumcss 1.0.23 → 1.0.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/xatriumcss CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- require('../src/cli.js');
2
+ import '../src/cli.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xatriumcss",
3
- "version": "1.0.23",
3
+ "version": "1.0.25",
4
4
  "description": "Ultra-fast utility-first CSS framework",
5
5
  "main": "./src/index.js",
6
6
  "files": [
package/src/cli.js CHANGED
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- const { runParser, hasXatriumImport } = require('./parser');
4
- const path = require('path');
5
- const watcher = require('@parcel/watcher');
6
- const fs = require('fs');
3
+ import { runParser, hasXatriumImport } from './parser.js';
4
+ import path from 'path';
5
+ import watcher from '@parcel/watcher';
6
+ import fs from 'fs';
7
7
 
8
8
  // Parse command line arguments
9
9
  function parseArgs(argv) {
package/src/parser.js CHANGED
@@ -1,5 +1,5 @@
1
- const fs = require('fs');
2
- const { glob } = require('glob');
1
+ import fs from 'fs';
2
+ import { glob } from 'glob';
3
3
  import collectClasses from './collectClasses.js';
4
4
 
5
5
  // --- 1. Fill this array with all your CSS properties ---
@@ -1784,7 +1784,7 @@ let xatriumConfig = {
1784
1784
  }
1785
1785
  };
1786
1786
  let useRangeSyntax = xatriumConfig.settings?.query !== "min-max";
1787
- finalMixSpace = ['oklab', 'oklch', 'srgb', 'srgb-linear', 'lab', 'lch', 'xyz', 'hsl', 'hwb'].includes(xatriumConfig?.settings?.colorMix) ? xatriumConfig.settings.colorMix : 'oklab';
1787
+ let finalMixSpace = ['oklab', 'oklch', 'srgb', 'srgb-linear', 'lab', 'lch', 'xyz', 'hsl', 'hwb'].includes(xatriumConfig?.settings?.colorMix) ? xatriumConfig.settings.colorMix : 'oklab';
1788
1788
 
1789
1789
  // shade → mixAmount mapping in percentage
1790
1790
  const shadeMixMap = [
@@ -25702,7 +25702,7 @@ function formatCSS(raw) {
25702
25702
  .trim();
25703
25703
  }
25704
25704
 
25705
- function runParser(config) {
25705
+ export function runParser(config) {
25706
25706
  // Reset source config for each run
25707
25707
  global.xatriumSourceConfig = {
25708
25708
  basePath: null,
@@ -25903,7 +25903,7 @@ function runParser(config) {
25903
25903
  }
25904
25904
  }
25905
25905
 
25906
- const path = require('path');
25906
+ import path from 'path';
25907
25907
 
25908
25908
  function calculateFontSize(scaleName, multiplier, scale) {
25909
25909
  const mult = multiplier ? parseFloat(multiplier) : 1;
@@ -26616,7 +26616,7 @@ function parseTextClass(rawValue, opacity = false, important = false) {
26616
26616
  return { prop: "font-size", value: custom, alpha: null, lineHeight: null, important };
26617
26617
  }
26618
26618
 
26619
- function hasXatriumImport(inputCssPath) {
26619
+ export function hasXatriumImport(inputCssPath) {
26620
26620
  if (!fs.existsSync(inputCssPath)) {
26621
26621
  return false;
26622
26622
  }
@@ -26627,6 +26627,4 @@ function hasXatriumImport(inputCssPath) {
26627
26627
  const importRegex = /@import\s+['"]xatriumcss['"]/gi;
26628
26628
 
26629
26629
  return importRegex.test(content);
26630
- }
26631
-
26632
- module.exports = { runParser, hasXatriumImport };
26630
+ }