@deneb-ui/cli 2.0.85 → 2.0.87

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/index.js CHANGED
@@ -1502,12 +1502,13 @@ if (command === 'validate' && (commandArgs[0] === 'and' || commandArgs[0] === '&
1502
1502
  commandArgs = commandArgs.slice(2);
1503
1503
  }
1504
1504
 
1505
- if (command === 'init') {
1505
+ if (command === 'init' || command === 'arc') {
1506
1506
  let targetInput = '.';
1507
1507
  let recipeName = null;
1508
1508
  let dryRun = false;
1509
1509
  let explain = false;
1510
1510
  let legacy = false;
1511
+ let strict = false;
1511
1512
  let telemetry = 'off';
1512
1513
  let aiEnabled = false;
1513
1514
  let aiDryRun = false;
@@ -1523,6 +1524,8 @@ if (command === 'init') {
1523
1524
  explain = true;
1524
1525
  } else if (arg === '--legacy') {
1525
1526
  legacy = true;
1527
+ } else if (arg === '--strict') {
1528
+ strict = true;
1526
1529
  } else if (arg === '--ai') {
1527
1530
  aiEnabled = true;
1528
1531
  } else if (arg === '--ai-dry-run') {
@@ -1536,10 +1539,44 @@ if (command === 'init') {
1536
1539
  targetInput = arg;
1537
1540
  }
1538
1541
  }
1539
- initProject(targetInput, { recipeName, dryRun, explain, legacy, telemetry, aiEnabled, aiDryRun }).catch((err) => {
1542
+ initProject(targetInput, { recipeName, dryRun, explain, legacy, strict, telemetry, aiEnabled, aiDryRun }).catch((err) => {
1540
1543
  console.error(`\x1b[31mError:\x1b[0m ${err.message}`);
1541
1544
  process.exit(1);
1542
1545
  });
1546
+ } else if (command === 'explain') {
1547
+ const fileInput = commandArgs.find((a) => !a.startsWith('-'));
1548
+ if (!fileInput) {
1549
+ console.error('\x1b[31mError:\x1b[0m Please specify a component file to explain (e.g. deneb explain src/components/Hero.tsx)');
1550
+ process.exit(1);
1551
+ }
1552
+ const isJson = commandArgs.includes('--json');
1553
+ try {
1554
+ const { explainFile, printExplanation } = require('../src/arc/explain.cjs');
1555
+ const explanation = explainFile(fileInput, { root: '.' });
1556
+ if (isJson) {
1557
+ console.log(JSON.stringify(explanation, null, 2));
1558
+ } else {
1559
+ printExplanation(explanation);
1560
+ }
1561
+ } catch (err) {
1562
+ console.error(`\x1b[31mError:\x1b[0m ${err.message}`);
1563
+ process.exit(1);
1564
+ }
1565
+ } else if (command === 'diff') {
1566
+ let targetInput = commandArgs.find((a) => !a.startsWith('-')) || '.';
1567
+ const isJson = commandArgs.includes('--json');
1568
+ try {
1569
+ const { generateArcDiff, printDiff } = require('../src/arc/diff.cjs');
1570
+ const diffs = generateArcDiff(targetInput);
1571
+ if (isJson) {
1572
+ console.log(JSON.stringify(diffs, null, 2));
1573
+ } else {
1574
+ printDiff(diffs);
1575
+ }
1576
+ } catch (err) {
1577
+ console.error(`\x1b[31mError:\x1b[0m ${err.message}`);
1578
+ process.exit(1);
1579
+ }
1543
1580
  } else if (command === 'create') {
1544
1581
  createTemplate(commandArgs[0]);
1545
1582
  } else if (command === 'add') {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deneb-ui/cli",
3
- "version": "2.0.85",
3
+ "version": "2.0.87",
4
4
  "description": "Official DENEB CLI — scaffold, convert, validate, and package Fivora-ready storefront templates.",
5
5
  "bin": {
6
6
  "deneb": "bin/index.js",
@@ -49,7 +49,7 @@
49
49
  "license": "MIT",
50
50
  "dependencies": {
51
51
  "@babel/parser": "^7.28.0",
52
- "@deneb-ui/core": "^2.0.85",
52
+ "@deneb-ui/core": "^2.0.87",
53
53
  "@octokit/rest": "^22.0.1",
54
54
  "adm-zip": "^0.6.0",
55
55
  "dotenv": "^17.4.2",