@contentful/experience-design-system-cli 2.37.1-dev-build-891d746a.0 → 2.37.1-dev-build-b65632a0.0
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/dist/app.js +19 -24
- package/dist/index.js +19 -25
- package/dist/package.json +1 -1
- package/dist/src/tui/home/home.theme.d.ts +1 -2
- package/legacy/dist/src/analyze/select/tui/components/ScrollablePanel.d.ts +2 -2
- package/legacy/dist/src/analyze/select/tui/theme.d.ts +1 -1
- package/legacy/dist/src/index.js +387 -398
- package/legacy/package.json +1 -1
- package/package.json +2 -2
package/legacy/dist/src/index.js
CHANGED
|
@@ -1560,6 +1560,39 @@ var init_agent_output = __esm({
|
|
|
1560
1560
|
}
|
|
1561
1561
|
});
|
|
1562
1562
|
|
|
1563
|
+
// packages/experience-design-system-cli-legacy/src/analyze/select/tui/theme.ts
|
|
1564
|
+
import { extendTheme, defaultTheme } from "@inkjs/ui";
|
|
1565
|
+
var PALETTE, INK_UI_THEME;
|
|
1566
|
+
var init_theme = __esm({
|
|
1567
|
+
"packages/experience-design-system-cli-legacy/src/analyze/select/tui/theme.ts"() {
|
|
1568
|
+
"use strict";
|
|
1569
|
+
PALETTE = {
|
|
1570
|
+
info: "#1773EB",
|
|
1571
|
+
link: "#58A6FF",
|
|
1572
|
+
success: "#00C459",
|
|
1573
|
+
error: "#E44F20",
|
|
1574
|
+
warning: "#FFDA00",
|
|
1575
|
+
fg: "#000000",
|
|
1576
|
+
inverse: "#FFFFFF",
|
|
1577
|
+
muted: "#8B8D91",
|
|
1578
|
+
border: "#C4D1DE",
|
|
1579
|
+
subtle: "#DDE5EC",
|
|
1580
|
+
bg: "#EFF2F6"
|
|
1581
|
+
};
|
|
1582
|
+
INK_UI_THEME = extendTheme(defaultTheme, {
|
|
1583
|
+
components: {
|
|
1584
|
+
ProgressBar: {
|
|
1585
|
+
styles: {
|
|
1586
|
+
completed: () => ({
|
|
1587
|
+
color: "blue"
|
|
1588
|
+
})
|
|
1589
|
+
}
|
|
1590
|
+
}
|
|
1591
|
+
}
|
|
1592
|
+
});
|
|
1593
|
+
}
|
|
1594
|
+
});
|
|
1595
|
+
|
|
1563
1596
|
// packages/experience-design-system-cli-legacy/src/tui/CommandCompletionView.tsx
|
|
1564
1597
|
import { Box, Text as Text2 } from "ink";
|
|
1565
1598
|
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
@@ -1576,16 +1609,16 @@ function CommandCompletionView({
|
|
|
1576
1609
|
" complete"
|
|
1577
1610
|
] }),
|
|
1578
1611
|
/* @__PURE__ */ jsx2(Box, { flexDirection: "column", marginTop: 1, children: rows.map((row) => /* @__PURE__ */ jsxs(Text2, { children: [
|
|
1579
|
-
/* @__PURE__ */ jsxs(Text2, {
|
|
1612
|
+
/* @__PURE__ */ jsxs(Text2, { color: PALETTE.muted, children: [
|
|
1580
1613
|
row.label,
|
|
1581
1614
|
" "
|
|
1582
1615
|
] }),
|
|
1583
1616
|
/* @__PURE__ */ jsx2(Text2, { children: row.value })
|
|
1584
1617
|
] }, row.label)) }),
|
|
1585
1618
|
/* @__PURE__ */ jsxs(Box, { marginTop: 1, children: [
|
|
1586
|
-
/* @__PURE__ */ jsx2(Text2, {
|
|
1619
|
+
/* @__PURE__ */ jsx2(Text2, { color: PALETTE.muted, children: "Run " }),
|
|
1587
1620
|
/* @__PURE__ */ jsx2(Text2, { children: command }),
|
|
1588
|
-
/* @__PURE__ */ jsxs(Text2, {
|
|
1621
|
+
/* @__PURE__ */ jsxs(Text2, { color: PALETTE.muted, children: [
|
|
1589
1622
|
" ",
|
|
1590
1623
|
instruction
|
|
1591
1624
|
] })
|
|
@@ -1595,6 +1628,7 @@ function CommandCompletionView({
|
|
|
1595
1628
|
var init_CommandCompletionView = __esm({
|
|
1596
1629
|
"packages/experience-design-system-cli-legacy/src/tui/CommandCompletionView.tsx"() {
|
|
1597
1630
|
"use strict";
|
|
1631
|
+
init_theme();
|
|
1598
1632
|
}
|
|
1599
1633
|
});
|
|
1600
1634
|
|
|
@@ -7490,7 +7524,7 @@ function ServerPreviewView({ preview, spaceId, environmentId }) {
|
|
|
7490
7524
|
components.removed.length,
|
|
7491
7525
|
" components to skip"
|
|
7492
7526
|
] }),
|
|
7493
|
-
/* @__PURE__ */ jsxs2(Text3, {
|
|
7527
|
+
/* @__PURE__ */ jsxs2(Text3, { color: PALETTE.muted, children: [
|
|
7494
7528
|
" \xB7 ",
|
|
7495
7529
|
components.unchanged.length,
|
|
7496
7530
|
" components unchanged"
|
|
@@ -7528,7 +7562,7 @@ function ServerPreviewView({ preview, spaceId, environmentId }) {
|
|
|
7528
7562
|
tokens.removed.length,
|
|
7529
7563
|
" to skip"
|
|
7530
7564
|
] }),
|
|
7531
|
-
/* @__PURE__ */ jsxs2(Text3, {
|
|
7565
|
+
/* @__PURE__ */ jsxs2(Text3, { color: PALETTE.muted, children: [
|
|
7532
7566
|
" \xB7 ",
|
|
7533
7567
|
tokens.unchanged.length,
|
|
7534
7568
|
" unchanged"
|
|
@@ -7542,12 +7576,13 @@ function ServerPreviewView({ preview, spaceId, environmentId }) {
|
|
|
7542
7576
|
] }, i)),
|
|
7543
7577
|
/* @__PURE__ */ jsx4(Text3, { children: " " })
|
|
7544
7578
|
] }),
|
|
7545
|
-
/* @__PURE__ */ jsx4(Text3, {
|
|
7579
|
+
/* @__PURE__ */ jsx4(Text3, { color: PALETTE.muted, children: " Press Q to exit." })
|
|
7546
7580
|
] });
|
|
7547
7581
|
}
|
|
7548
7582
|
var init_ServerPreviewView = __esm({
|
|
7549
7583
|
"packages/experience-design-system-cli-legacy/src/apply/tui/ServerPreviewView.tsx"() {
|
|
7550
7584
|
"use strict";
|
|
7585
|
+
init_theme();
|
|
7551
7586
|
}
|
|
7552
7587
|
});
|
|
7553
7588
|
|
|
@@ -7632,7 +7667,7 @@ function ServerApplyProgress({
|
|
|
7632
7667
|
error
|
|
7633
7668
|
] }),
|
|
7634
7669
|
/* @__PURE__ */ jsx5(Text4, { children: " " }),
|
|
7635
|
-
/* @__PURE__ */ jsx5(Text4, {
|
|
7670
|
+
/* @__PURE__ */ jsx5(Text4, { color: PALETTE.muted, children: " Press Q to exit." })
|
|
7636
7671
|
] })
|
|
7637
7672
|
] });
|
|
7638
7673
|
}
|
|
@@ -7661,7 +7696,7 @@ function ServerApplyDone({ operation, spaceId, environmentId, host }) {
|
|
|
7661
7696
|
operation.summary.failed,
|
|
7662
7697
|
" failed"
|
|
7663
7698
|
] }),
|
|
7664
|
-
operation.summary.failed === 0 && /* @__PURE__ */ jsx5(Text4, {
|
|
7699
|
+
operation.summary.failed === 0 && /* @__PURE__ */ jsx5(Text4, { color: PALETTE.muted, children: " All entities imported successfully." }),
|
|
7665
7700
|
failures.length > 0 && /* @__PURE__ */ jsxs3(Box3, { flexDirection: "column", children: [
|
|
7666
7701
|
/* @__PURE__ */ jsx5(Text4, { children: " " }),
|
|
7667
7702
|
/* @__PURE__ */ jsx5(Text4, { bold: true, children: " Failures:" }),
|
|
@@ -7673,7 +7708,7 @@ function ServerApplyDone({ operation, spaceId, environmentId, host }) {
|
|
|
7673
7708
|
": ",
|
|
7674
7709
|
item.id
|
|
7675
7710
|
] }),
|
|
7676
|
-
item.error && /* @__PURE__ */ jsxs3(Text4, {
|
|
7711
|
+
item.error && /* @__PURE__ */ jsxs3(Text4, { color: PALETTE.muted, children: [
|
|
7677
7712
|
" ",
|
|
7678
7713
|
formatItemError(item.error)
|
|
7679
7714
|
] })
|
|
@@ -7681,19 +7716,19 @@ function ServerApplyDone({ operation, spaceId, environmentId, host }) {
|
|
|
7681
7716
|
] }),
|
|
7682
7717
|
operation.sys.status === "succeeded" && operation.summary.succeeded > 0 && /* @__PURE__ */ jsxs3(Box3, { flexDirection: "column", children: [
|
|
7683
7718
|
/* @__PURE__ */ jsx5(Text4, { children: " " }),
|
|
7684
|
-
/* @__PURE__ */ jsx5(Text4, {
|
|
7719
|
+
/* @__PURE__ */ jsx5(Text4, { color: PALETTE.muted, children: " View your design system:" }),
|
|
7685
7720
|
/* @__PURE__ */ jsxs3(Text4, { color: "cyan", children: [
|
|
7686
7721
|
" ",
|
|
7687
7722
|
buildPostPushUrl({ host: host ?? "api.contentful.com", spaceId, environmentId })
|
|
7688
7723
|
] }),
|
|
7689
|
-
/* @__PURE__ */ jsx5(Text4, {
|
|
7724
|
+
/* @__PURE__ */ jsx5(Text4, { color: PALETTE.muted, children: " View your design tokens:" }),
|
|
7690
7725
|
/* @__PURE__ */ jsxs3(Text4, { color: "cyan", children: [
|
|
7691
7726
|
" ",
|
|
7692
7727
|
buildPostPushUrl({ host: host ?? "api.contentful.com", spaceId, environmentId, view: "design_tokens" })
|
|
7693
7728
|
] })
|
|
7694
7729
|
] }),
|
|
7695
7730
|
/* @__PURE__ */ jsx5(Text4, { children: " " }),
|
|
7696
|
-
/* @__PURE__ */ jsx5(Text4, {
|
|
7731
|
+
/* @__PURE__ */ jsx5(Text4, { color: PALETTE.muted, children: " Press Q to exit." })
|
|
7697
7732
|
] });
|
|
7698
7733
|
}
|
|
7699
7734
|
function formatItemError(error) {
|
|
@@ -7705,6 +7740,7 @@ var init_ServerApplyView = __esm({
|
|
|
7705
7740
|
init_ServerPreviewView();
|
|
7706
7741
|
init_contentful_urls();
|
|
7707
7742
|
init_error_parser();
|
|
7743
|
+
init_theme();
|
|
7708
7744
|
}
|
|
7709
7745
|
});
|
|
7710
7746
|
|
|
@@ -8423,7 +8459,7 @@ import { jsx as jsx6, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
|
8423
8459
|
function TopBar({ subcommand, hints }) {
|
|
8424
8460
|
return /* @__PURE__ */ jsxs4(Box4, { justifyContent: "space-between", children: [
|
|
8425
8461
|
/* @__PURE__ */ jsx6(Text5, { bold: true, children: "experience-design-system-cli " + subcommand }),
|
|
8426
|
-
/* @__PURE__ */ jsxs4(Text5, {
|
|
8462
|
+
/* @__PURE__ */ jsxs4(Text5, { color: PALETTE.muted, children: [
|
|
8427
8463
|
hints.map((h) => `[${h.key}] ${h.label}`).join(" "),
|
|
8428
8464
|
" v" + VERSION
|
|
8429
8465
|
] })
|
|
@@ -8434,6 +8470,7 @@ var init_TopBar = __esm({
|
|
|
8434
8470
|
"packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/TopBar.tsx"() {
|
|
8435
8471
|
"use strict";
|
|
8436
8472
|
init_cli_path();
|
|
8473
|
+
init_theme();
|
|
8437
8474
|
VERSION = JSON.parse(readFileSync4(join8(findPkgRoot(), "package.json"), "utf8")).version;
|
|
8438
8475
|
}
|
|
8439
8476
|
});
|
|
@@ -8579,7 +8616,7 @@ function ValidateView({ results, onExit }) {
|
|
|
8579
8616
|
return /* @__PURE__ */ jsxs5(Box5, { children: [
|
|
8580
8617
|
/* @__PURE__ */ jsx7(Text6, { color: r.valid ? "green" : "red", children: r.valid ? "\u2713" : "\u2717" }),
|
|
8581
8618
|
/* @__PURE__ */ jsx7(Text6, { children: " " + r.filePath.split("/").pop() }),
|
|
8582
|
-
/* @__PURE__ */ jsx7(Text6, {
|
|
8619
|
+
/* @__PURE__ */ jsx7(Text6, { color: PALETTE.muted, children: " " + r.format + " " }),
|
|
8583
8620
|
/* @__PURE__ */ jsx7(Text6, { color: r.valid ? "green" : "red", children: summaryText })
|
|
8584
8621
|
] }, r.filePath);
|
|
8585
8622
|
}),
|
|
@@ -8593,8 +8630,8 @@ function ValidateView({ results, onExit }) {
|
|
|
8593
8630
|
] }, r.filePath)) })
|
|
8594
8631
|
] }),
|
|
8595
8632
|
/* @__PURE__ */ jsxs5(Box5, { borderStyle: "single", paddingX: 1, justifyContent: "space-between", children: [
|
|
8596
|
-
/* @__PURE__ */ jsx7(Text6, {
|
|
8597
|
-
/* @__PURE__ */ jsx7(Text6, {
|
|
8633
|
+
/* @__PURE__ */ jsx7(Text6, { color: PALETTE.muted, children: allValid ? "All files valid" : invalidResults.length + " file" + (invalidResults.length === 1 ? "" : "s") + " invalid" }),
|
|
8634
|
+
/* @__PURE__ */ jsx7(Text6, { children: allValid ? "[q]" : "scroll \u2191\u2193 [q]" })
|
|
8598
8635
|
] })
|
|
8599
8636
|
] });
|
|
8600
8637
|
}
|
|
@@ -8604,6 +8641,7 @@ var init_ValidateView = __esm({
|
|
|
8604
8641
|
init_TopBar();
|
|
8605
8642
|
init_useImmediateInput();
|
|
8606
8643
|
init_list_scroll_input();
|
|
8644
|
+
init_theme();
|
|
8607
8645
|
}
|
|
8608
8646
|
});
|
|
8609
8647
|
|
|
@@ -9363,39 +9401,6 @@ var init_composition_options = __esm({
|
|
|
9363
9401
|
}
|
|
9364
9402
|
});
|
|
9365
9403
|
|
|
9366
|
-
// packages/experience-design-system-cli-legacy/src/analyze/select/tui/theme.ts
|
|
9367
|
-
import { extendTheme, defaultTheme } from "@inkjs/ui";
|
|
9368
|
-
var PALETTE, INK_UI_THEME;
|
|
9369
|
-
var init_theme = __esm({
|
|
9370
|
-
"packages/experience-design-system-cli-legacy/src/analyze/select/tui/theme.ts"() {
|
|
9371
|
-
"use strict";
|
|
9372
|
-
PALETTE = {
|
|
9373
|
-
info: "#1773EB",
|
|
9374
|
-
link: "#58A6FF",
|
|
9375
|
-
success: "#00C459",
|
|
9376
|
-
error: "#E44F20",
|
|
9377
|
-
warning: "#FFDA00",
|
|
9378
|
-
fg: "#000000",
|
|
9379
|
-
inverse: "#FFFFFF",
|
|
9380
|
-
muted: "#A6B5C7",
|
|
9381
|
-
border: "#C4D1DE",
|
|
9382
|
-
subtle: "#DDE5EC",
|
|
9383
|
-
bg: "#EFF2F6"
|
|
9384
|
-
};
|
|
9385
|
-
INK_UI_THEME = extendTheme(defaultTheme, {
|
|
9386
|
-
components: {
|
|
9387
|
-
ProgressBar: {
|
|
9388
|
-
styles: {
|
|
9389
|
-
completed: () => ({
|
|
9390
|
-
color: "blue"
|
|
9391
|
-
})
|
|
9392
|
-
}
|
|
9393
|
-
}
|
|
9394
|
-
}
|
|
9395
|
-
});
|
|
9396
|
-
}
|
|
9397
|
-
});
|
|
9398
|
-
|
|
9399
9404
|
// packages/experience-design-system-cli-legacy/src/import/tui/run-teaser.ts
|
|
9400
9405
|
function buildRunTeaserLine(runId) {
|
|
9401
9406
|
if (!runId) return "";
|
|
@@ -9492,13 +9497,13 @@ function PathPrompt({
|
|
|
9492
9497
|
label,
|
|
9493
9498
|
":"
|
|
9494
9499
|
] }),
|
|
9495
|
-
/* @__PURE__ */ jsx9(Text7, {
|
|
9500
|
+
/* @__PURE__ */ jsx9(Text7, { color: isPlaceholder ? PALETTE.muted : void 0, children: shown }),
|
|
9496
9501
|
/* @__PURE__ */ jsx9(Text7, { children: cursor })
|
|
9497
9502
|
] }),
|
|
9498
9503
|
/* @__PURE__ */ jsxs6(Box6, { gap: 3, children: [
|
|
9499
|
-
/* @__PURE__ */ jsx9(Text7, {
|
|
9500
|
-
/* @__PURE__ */ jsx9(Text7, {
|
|
9501
|
-
/* @__PURE__ */ jsx9(Text7, {
|
|
9504
|
+
/* @__PURE__ */ jsx9(Text7, { children: "[Enter] Confirm" }),
|
|
9505
|
+
/* @__PURE__ */ jsx9(Text7, { children: "[Tab] Autocomplete" }),
|
|
9506
|
+
/* @__PURE__ */ jsx9(Text7, { children: "[Esc] Cancel" })
|
|
9502
9507
|
] })
|
|
9503
9508
|
] });
|
|
9504
9509
|
}
|
|
@@ -9508,6 +9513,7 @@ var init_path_prompt = __esm({
|
|
|
9508
9513
|
init_useImmediateInput();
|
|
9509
9514
|
init_path_utils();
|
|
9510
9515
|
init_use_blinking_cursor();
|
|
9516
|
+
init_theme();
|
|
9511
9517
|
}
|
|
9512
9518
|
});
|
|
9513
9519
|
|
|
@@ -9712,7 +9718,7 @@ function CustomPromptBanner({ generatePromptPath }) {
|
|
|
9712
9718
|
"components: ",
|
|
9713
9719
|
generatePromptPath
|
|
9714
9720
|
] }) : null,
|
|
9715
|
-
/* @__PURE__ */ jsx10(Text8, { color: PALETTE.warning,
|
|
9721
|
+
/* @__PURE__ */ jsx10(Text8, { color: PALETTE.warning, children: "Bundled invariants (utility-wrapper rejection, description content rules) do NOT apply." })
|
|
9716
9722
|
] });
|
|
9717
9723
|
}
|
|
9718
9724
|
var init_CustomPromptBanner = __esm({
|
|
@@ -9801,44 +9807,44 @@ function RunningStep({
|
|
|
9801
9807
|
/* @__PURE__ */ jsx13(Box9, { gap: 1, marginTop: 1, flexDirection: "column", children: detailProgress ? /* @__PURE__ */ jsxs9(Fragment3, { children: [
|
|
9802
9808
|
/* @__PURE__ */ jsxs9(Box9, { gap: 2, children: [
|
|
9803
9809
|
/* @__PURE__ */ jsx13(Box9, { width: 40, children: /* @__PURE__ */ jsx13(ThemeProvider, { theme: INK_UI_THEME, children: /* @__PURE__ */ jsx13(ProgressBar, { value: Math.round(detailProgress.done / detailProgress.total * 100) }) }) }),
|
|
9804
|
-
/* @__PURE__ */ jsxs9(Text10, {
|
|
9810
|
+
/* @__PURE__ */ jsxs9(Text10, { color: PALETTE.muted, children: [
|
|
9805
9811
|
detailProgress.done,
|
|
9806
9812
|
"/",
|
|
9807
9813
|
detailProgress.total
|
|
9808
9814
|
] })
|
|
9809
9815
|
] }),
|
|
9810
|
-
/* @__PURE__ */ jsx13(Text10, {
|
|
9816
|
+
/* @__PURE__ */ jsx13(Text10, { color: PALETTE.muted, children: detail ?? "Running..." })
|
|
9811
9817
|
] }) : /* @__PURE__ */ jsxs9(Box9, { gap: 1, children: [
|
|
9812
9818
|
detailComplete ? /* @__PURE__ */ jsx13(Text10, { color: PALETTE.success, children: "\u2713" }) : spinner,
|
|
9813
|
-
/* @__PURE__ */ jsx13(Text10, {
|
|
9819
|
+
/* @__PURE__ */ jsx13(Text10, { color: PALETTE.muted, children: detail ?? "Running..." })
|
|
9814
9820
|
] }) }),
|
|
9815
9821
|
secondaryDetail !== void 0 && /* @__PURE__ */ jsx13(Box9, { gap: 1, flexDirection: "column", children: secondaryProgress ? /* @__PURE__ */ jsxs9(Fragment3, { children: [
|
|
9816
9822
|
/* @__PURE__ */ jsxs9(Box9, { gap: 2, children: [
|
|
9817
9823
|
/* @__PURE__ */ jsx13(Box9, { width: 40, children: /* @__PURE__ */ jsx13(ThemeProvider, { theme: INK_UI_THEME, children: /* @__PURE__ */ jsx13(ProgressBar, { value: Math.round(secondaryProgress.done / secondaryProgress.total * 100) }) }) }),
|
|
9818
|
-
/* @__PURE__ */ jsxs9(Text10, {
|
|
9824
|
+
/* @__PURE__ */ jsxs9(Text10, { color: PALETTE.muted, children: [
|
|
9819
9825
|
secondaryProgress.done,
|
|
9820
9826
|
"/",
|
|
9821
9827
|
secondaryProgress.total
|
|
9822
9828
|
] })
|
|
9823
9829
|
] }),
|
|
9824
|
-
/* @__PURE__ */ jsx13(Text10, {
|
|
9830
|
+
/* @__PURE__ */ jsx13(Text10, { color: PALETTE.muted, children: secondaryDetail })
|
|
9825
9831
|
] }) : /* @__PURE__ */ jsxs9(Box9, { gap: 1, children: [
|
|
9826
9832
|
secondaryComplete ? /* @__PURE__ */ jsx13(Text10, { color: PALETTE.success, children: "\u2713" }) : spinner,
|
|
9827
|
-
/* @__PURE__ */ jsx13(Text10, {
|
|
9833
|
+
/* @__PURE__ */ jsx13(Text10, { color: PALETTE.muted, children: secondaryDetail })
|
|
9828
9834
|
] }) }),
|
|
9829
9835
|
tertiaryDetail !== void 0 && /* @__PURE__ */ jsxs9(Box9, { gap: 1, children: [
|
|
9830
9836
|
tertiaryComplete ? /* @__PURE__ */ jsx13(Text10, { color: PALETTE.success, children: "\u2713" }) : spinner,
|
|
9831
|
-
/* @__PURE__ */ jsx13(Text10, {
|
|
9837
|
+
/* @__PURE__ */ jsx13(Text10, { color: PALETTE.muted, children: tertiaryDetail })
|
|
9832
9838
|
] }),
|
|
9833
9839
|
quaternaryDetail !== void 0 && /* @__PURE__ */ jsxs9(Box9, { gap: 1, children: [
|
|
9834
9840
|
quaternaryComplete ? /* @__PURE__ */ jsx13(Text10, { color: PALETTE.success, children: "\u2713" }) : spinner,
|
|
9835
|
-
/* @__PURE__ */ jsx13(Text10, {
|
|
9841
|
+
/* @__PURE__ */ jsx13(Text10, { color: PALETTE.muted, children: quaternaryDetail })
|
|
9836
9842
|
] }),
|
|
9837
9843
|
quinaryDetail !== void 0 && /* @__PURE__ */ jsxs9(Box9, { gap: 1, children: [
|
|
9838
9844
|
quinaryComplete ? /* @__PURE__ */ jsx13(Text10, { color: PALETTE.success, children: "\u2713" }) : spinner,
|
|
9839
|
-
/* @__PURE__ */ jsx13(Text10, {
|
|
9845
|
+
/* @__PURE__ */ jsx13(Text10, { color: PALETTE.muted, children: quinaryDetail })
|
|
9840
9846
|
] }),
|
|
9841
|
-
/* @__PURE__ */ jsx13(Box9, { marginTop: 1, children: /* @__PURE__ */ jsxs9(Text10, {
|
|
9847
|
+
/* @__PURE__ */ jsx13(Box9, { marginTop: 1, children: /* @__PURE__ */ jsxs9(Text10, { color: PALETTE.muted, children: [
|
|
9842
9848
|
"Elapsed: ",
|
|
9843
9849
|
elapsed
|
|
9844
9850
|
] }) })
|
|
@@ -9890,18 +9896,18 @@ function GateStep({
|
|
|
9890
9896
|
" ",
|
|
9891
9897
|
successMessage
|
|
9892
9898
|
] }),
|
|
9893
|
-
summary && /* @__PURE__ */ jsx14(Text11, {
|
|
9899
|
+
summary && /* @__PURE__ */ jsx14(Text11, { color: PALETTE.muted, children: summary }),
|
|
9894
9900
|
context && /* @__PURE__ */ jsx14(Box10, { marginTop: 1, children: /* @__PURE__ */ jsx14(Text11, { children: context }) }),
|
|
9895
9901
|
/* @__PURE__ */ jsxs10(Box10, { gap: 3, marginTop: 1, children: [
|
|
9896
|
-
/* @__PURE__ */ jsxs10(Text11, {
|
|
9902
|
+
/* @__PURE__ */ jsxs10(Text11, { children: [
|
|
9897
9903
|
"[Enter] ",
|
|
9898
9904
|
continueLabel
|
|
9899
9905
|
] }),
|
|
9900
|
-
showSkip && onSkip && /* @__PURE__ */ jsxs10(Text11, {
|
|
9906
|
+
showSkip && onSkip && /* @__PURE__ */ jsxs10(Text11, { children: [
|
|
9901
9907
|
"[a] ",
|
|
9902
9908
|
skipLabel
|
|
9903
9909
|
] }),
|
|
9904
|
-
/* @__PURE__ */ jsx14(Text11, {
|
|
9910
|
+
/* @__PURE__ */ jsx14(Text11, { children: "[q] Quit" })
|
|
9905
9911
|
] })
|
|
9906
9912
|
] });
|
|
9907
9913
|
}
|
|
@@ -9909,6 +9915,7 @@ var init_GateStep = __esm({
|
|
|
9909
9915
|
"packages/experience-design-system-cli-legacy/src/import/tui/steps/GateStep.tsx"() {
|
|
9910
9916
|
"use strict";
|
|
9911
9917
|
init_useImmediateInput();
|
|
9918
|
+
init_theme();
|
|
9912
9919
|
}
|
|
9913
9920
|
});
|
|
9914
9921
|
|
|
@@ -10038,7 +10045,7 @@ function CredentialsStep({
|
|
|
10038
10045
|
function renderField(label, value, field, masked = false) {
|
|
10039
10046
|
const isActive = activeField === field;
|
|
10040
10047
|
const display = masked ? "\u2022".repeat(value.length) : value;
|
|
10041
|
-
const fallback = field === "host" ? DEFAULT_CONFIGURED_HOST : /* @__PURE__ */ jsx15(Text12, {
|
|
10048
|
+
const fallback = field === "host" ? DEFAULT_CONFIGURED_HOST : /* @__PURE__ */ jsx15(Text12, { color: PALETTE.muted, children: "(empty)" });
|
|
10042
10049
|
return /* @__PURE__ */ jsxs11(Box11, { gap: 1, children: [
|
|
10043
10050
|
/* @__PURE__ */ jsx15(Text12, { color: isActive ? PALETTE.info : void 0, children: "?" }),
|
|
10044
10051
|
/* @__PURE__ */ jsxs11(Text12, { bold: isActive, children: [
|
|
@@ -10057,8 +10064,8 @@ function CredentialsStep({
|
|
|
10057
10064
|
/* @__PURE__ */ jsxs11(Box11, { flexDirection: "column", children: [
|
|
10058
10065
|
/* @__PURE__ */ jsx15(Text12, { children: initialSpaceId && initialCmaToken ? "Credentials pre-filled from the configuration settings." : "Enter the Contentful space you want to import into." }),
|
|
10059
10066
|
!(initialSpaceId && initialCmaToken) && /* @__PURE__ */ jsxs11(Fragment4, { children: [
|
|
10060
|
-
/* @__PURE__ */ jsx15(Text12, {
|
|
10061
|
-
/* @__PURE__ */ jsx15(Text12, {
|
|
10067
|
+
/* @__PURE__ */ jsx15(Text12, { color: PALETTE.muted, children: "These credentials are used both to align agent suggestions with what already exists in the space and to push your import at the end. Press S to skip and run without space context (push will be disabled)." }),
|
|
10068
|
+
/* @__PURE__ */ jsx15(Text12, { color: PALETTE.muted, children: "Tip: run experiences setup to save these to ~/.contentful/experience-design-system-cli/config.json so they pre-fill here automatically." })
|
|
10062
10069
|
] })
|
|
10063
10070
|
] }),
|
|
10064
10071
|
/* @__PURE__ */ jsxs11(Box11, { flexDirection: "column", children: [
|
|
@@ -10067,13 +10074,13 @@ function CredentialsStep({
|
|
|
10067
10074
|
renderField("CMA Token", cmaToken, "cmaToken", true),
|
|
10068
10075
|
renderField("API Host", host, "host")
|
|
10069
10076
|
] }),
|
|
10070
|
-
activeField === "host" && /* @__PURE__ */ jsx15(Text12, {
|
|
10077
|
+
activeField === "host" && /* @__PURE__ */ jsx15(Text12, { color: PALETTE.muted, children: "Default: api.contentful.com \xB7 EU spaces: api.eu.contentful.com" }),
|
|
10071
10078
|
displayError && /* @__PURE__ */ jsxs11(Text12, { color: PALETTE.error, children: [
|
|
10072
10079
|
"\u2717 ",
|
|
10073
10080
|
displayError
|
|
10074
10081
|
] }),
|
|
10075
10082
|
validating && !backgroundValidating && /* @__PURE__ */ jsx15(Text12, { color: PALETTE.info, children: generatePrefetchStatus === "running" ? "Validating credentials & finishing component generation..." : "Validating credentials..." }),
|
|
10076
|
-
!validating && generatePrefetchStatus === "running" && /* @__PURE__ */ jsx15(Text12, {
|
|
10083
|
+
!validating && generatePrefetchStatus === "running" && /* @__PURE__ */ jsx15(Text12, { color: PALETTE.muted, children: "Component generation in progress..." }),
|
|
10077
10084
|
!validating && generatePrefetchStatus === "complete" && /* @__PURE__ */ jsx15(Text12, { color: PALETTE.success, children: "Component generation complete." }),
|
|
10078
10085
|
!validating && generatePrefetchStatus === "failed" && /* @__PURE__ */ jsxs11(Text12, { color: PALETTE.warning, children: [
|
|
10079
10086
|
"Component generation failed",
|
|
@@ -10082,10 +10089,10 @@ function CredentialsStep({
|
|
|
10082
10089
|
onRetryPrefetch ? " Press R to retry now." : ""
|
|
10083
10090
|
] }),
|
|
10084
10091
|
/* @__PURE__ */ jsxs11(Box11, { gap: 3, children: [
|
|
10085
|
-
/* @__PURE__ */ jsx15(Text12, {
|
|
10086
|
-
/* @__PURE__ */ jsx15(Text12, {
|
|
10087
|
-
/* @__PURE__ */ jsx15(Text12, {
|
|
10088
|
-
onSkip && /* @__PURE__ */ jsx15(Text12, {
|
|
10092
|
+
/* @__PURE__ */ jsx15(Text12, { children: "[Enter] Next field / Submit" }),
|
|
10093
|
+
/* @__PURE__ */ jsx15(Text12, { children: "[Tab] Switch field" }),
|
|
10094
|
+
/* @__PURE__ */ jsx15(Text12, { children: "[q] Quit" }),
|
|
10095
|
+
onSkip && /* @__PURE__ */ jsx15(Text12, { children: "[s] Skip \u2014 review locally only (no push, no live preview)" })
|
|
10089
10096
|
] })
|
|
10090
10097
|
] });
|
|
10091
10098
|
}
|
|
@@ -10297,16 +10304,17 @@ import { Box as Box12, Text as Text13 } from "ink";
|
|
|
10297
10304
|
import { jsx as jsx16, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
10298
10305
|
function SpaceEnvironment({ spaceId, environmentId }) {
|
|
10299
10306
|
return /* @__PURE__ */ jsxs12(Box12, { gap: 1, marginTop: 1, children: [
|
|
10300
|
-
/* @__PURE__ */ jsx16(Text13, {
|
|
10307
|
+
/* @__PURE__ */ jsx16(Text13, { color: PALETTE.muted, children: "Space:" }),
|
|
10301
10308
|
/* @__PURE__ */ jsx16(Text13, { children: spaceId }),
|
|
10302
|
-
/* @__PURE__ */ jsx16(Text13, {
|
|
10303
|
-
/* @__PURE__ */ jsx16(Text13, {
|
|
10309
|
+
/* @__PURE__ */ jsx16(Text13, { color: PALETTE.muted, children: "/" }),
|
|
10310
|
+
/* @__PURE__ */ jsx16(Text13, { color: PALETTE.muted, children: "Environment:" }),
|
|
10304
10311
|
/* @__PURE__ */ jsx16(Text13, { children: environmentId })
|
|
10305
10312
|
] });
|
|
10306
10313
|
}
|
|
10307
10314
|
var init_SpaceEnvironment = __esm({
|
|
10308
10315
|
"packages/experience-design-system-cli-legacy/src/import/tui/components/SpaceEnvironment.tsx"() {
|
|
10309
10316
|
"use strict";
|
|
10317
|
+
init_theme();
|
|
10310
10318
|
}
|
|
10311
10319
|
});
|
|
10312
10320
|
|
|
@@ -10398,7 +10406,7 @@ function formatWindowIndicator(direction, count) {
|
|
|
10398
10406
|
return `${direction === "up" ? "\u2191" : "\u2193"} ${count} more`;
|
|
10399
10407
|
}
|
|
10400
10408
|
function WindowIndicator({ direction, count }) {
|
|
10401
|
-
return /* @__PURE__ */ jsx17(Text14, {
|
|
10409
|
+
return /* @__PURE__ */ jsx17(Text14, { color: PALETTE.muted, children: formatWindowIndicator(direction, count) });
|
|
10402
10410
|
}
|
|
10403
10411
|
var MIN_TERMINAL_PANEL_HEIGHT;
|
|
10404
10412
|
var init_windowed_panel = __esm({
|
|
@@ -10678,33 +10686,24 @@ function WizardPreviewStep({
|
|
|
10678
10686
|
title: diffExpanded ? `Diff (${diffLines.length} lines)` : "",
|
|
10679
10687
|
focused: false,
|
|
10680
10688
|
children: [
|
|
10681
|
-
activeLines.slice(boundedScrollOffset, boundedScrollOffset + viewportHeight).map((line) => /* @__PURE__ */ jsx18(
|
|
10682
|
-
|
|
10683
|
-
{
|
|
10684
|
-
color: line.color === "gray" ? void 0 : line.color,
|
|
10685
|
-
dimColor: line.color === "gray",
|
|
10686
|
-
wrap: "truncate-end",
|
|
10687
|
-
children: line.text
|
|
10688
|
-
},
|
|
10689
|
-
line.key
|
|
10690
|
-
)),
|
|
10691
|
-
/* @__PURE__ */ jsx18(Text15, { dimColor: true, wrap: "truncate-end", children: formatPreviewScrollIndicator(activeLines.length, boundedScrollOffset, viewportHeight) })
|
|
10689
|
+
activeLines.slice(boundedScrollOffset, boundedScrollOffset + viewportHeight).map((line) => /* @__PURE__ */ jsx18(Text15, { color: line.color === "gray" ? PALETTE.muted : line.color, wrap: "truncate-end", children: line.text }, line.key)),
|
|
10690
|
+
/* @__PURE__ */ jsx18(Text15, { color: PALETTE.muted, wrap: "truncate-end", children: formatPreviewScrollIndicator(activeLines.length, boundedScrollOffset, viewportHeight) })
|
|
10692
10691
|
]
|
|
10693
10692
|
}
|
|
10694
10693
|
)
|
|
10695
|
-
] }) : /* @__PURE__ */ jsx18(Text15, {
|
|
10694
|
+
] }) : /* @__PURE__ */ jsx18(Text15, { color: PALETTE.muted, children: "Nothing to push \u2014 everything is already up to date." }),
|
|
10696
10695
|
breakingWithImpact && /* @__PURE__ */ jsx18(Box14, { marginTop: 1, children: /* @__PURE__ */ jsx18(Text15, { color: PALETTE.error, bold: true, children: "\u26A0 Breaking changes will affect downstream entities. Press Enter to acknowledge and apply." }) }),
|
|
10697
10696
|
/* @__PURE__ */ jsx18(SpaceEnvironment, { spaceId, environmentId }),
|
|
10698
10697
|
/* @__PURE__ */ jsxs14(Box14, { gap: 3, marginTop: 1, children: [
|
|
10699
|
-
/* @__PURE__ */ jsx18(Text15, {
|
|
10700
|
-
/* @__PURE__ */ jsxs14(Text15, {
|
|
10698
|
+
/* @__PURE__ */ jsx18(Text15, { children: "[Enter] Push to Contentful" }),
|
|
10699
|
+
/* @__PURE__ */ jsxs14(Text15, { children: [
|
|
10701
10700
|
"[d] ",
|
|
10702
10701
|
diffExpanded ? "Hide" : "Show",
|
|
10703
10702
|
" diff"
|
|
10704
10703
|
] }),
|
|
10705
|
-
diffExpanded && /* @__PURE__ */ jsx18(Text15, {
|
|
10706
|
-
onEdit && /* @__PURE__ */ jsx18(Text15, {
|
|
10707
|
-
/* @__PURE__ */ jsx18(Text15, {
|
|
10704
|
+
diffExpanded && /* @__PURE__ */ jsx18(Text15, { children: "[\u2191\u2193] Scroll [f/b] Page" }),
|
|
10705
|
+
onEdit && /* @__PURE__ */ jsx18(Text15, { children: "[e] Edit definitions" }),
|
|
10706
|
+
/* @__PURE__ */ jsx18(Text15, { children: "[q] Cancel" })
|
|
10708
10707
|
] })
|
|
10709
10708
|
] });
|
|
10710
10709
|
}
|
|
@@ -10745,7 +10744,7 @@ function EntityRows({ entity, label }) {
|
|
|
10745
10744
|
}
|
|
10746
10745
|
function LinkRow({ title, url }) {
|
|
10747
10746
|
return /* @__PURE__ */ jsxs15(Box15, { flexDirection: "column", children: [
|
|
10748
|
-
/* @__PURE__ */ jsx19(Text16, {
|
|
10747
|
+
/* @__PURE__ */ jsx19(Text16, { color: PALETTE.muted, children: title }),
|
|
10749
10748
|
/* @__PURE__ */ jsx19(Text16, { color: PALETTE.link, children: url })
|
|
10750
10749
|
] });
|
|
10751
10750
|
}
|
|
@@ -10770,10 +10769,10 @@ function DoneStep({
|
|
|
10770
10769
|
const urlArgs = { host: host ?? "api.contentful.com", spaceId, environmentId };
|
|
10771
10770
|
return /* @__PURE__ */ jsxs15(Box15, { flexDirection: "column", gap: 1, paddingX: 2, paddingY: 1, children: [
|
|
10772
10771
|
success ? /* @__PURE__ */ jsx19(Text16, { bold: true, color: PALETTE.success, children: "Done!" }) : /* @__PURE__ */ jsx19(Text16, { bold: true, color: PALETTE.warning, children: "\u26A0 Finished with errors" }),
|
|
10773
|
-
totalPushed === 0 && totalFailed === 0 && !summary ? /* @__PURE__ */ jsx19(Text16, {
|
|
10772
|
+
totalPushed === 0 && totalFailed === 0 && !summary ? /* @__PURE__ */ jsx19(Text16, { color: PALETTE.muted, children: "Nothing was pushed \u2014 everything was already up to date." }) : /* @__PURE__ */ jsxs15(Box15, { flexDirection: "column", children: [
|
|
10774
10773
|
/* @__PURE__ */ jsx19(EntityRows, { entity: componentTypes, label: "Component Type" }),
|
|
10775
10774
|
/* @__PURE__ */ jsx19(EntityRows, { entity: designTokens, label: "Design Token" }),
|
|
10776
|
-
summary && /* @__PURE__ */ jsx19(Box15, { marginTop: 1, children: /* @__PURE__ */ jsxs15(Text16, {
|
|
10775
|
+
summary && /* @__PURE__ */ jsx19(Box15, { marginTop: 1, children: /* @__PURE__ */ jsxs15(Text16, { color: PALETTE.muted, children: [
|
|
10777
10776
|
"Push result: ",
|
|
10778
10777
|
summary.succeeded,
|
|
10779
10778
|
"/",
|
|
@@ -10808,7 +10807,7 @@ function DoneStep({
|
|
|
10808
10807
|
}
|
|
10809
10808
|
)
|
|
10810
10809
|
] }),
|
|
10811
|
-
/* @__PURE__ */ jsx19(Text16, {
|
|
10810
|
+
/* @__PURE__ */ jsx19(Text16, { children: "[Enter / q] Exit" })
|
|
10812
10811
|
] });
|
|
10813
10812
|
}
|
|
10814
10813
|
var ACTIONS;
|
|
@@ -10855,10 +10854,10 @@ function ErrorStep({
|
|
|
10855
10854
|
/* @__PURE__ */ jsx20(Text17, { color: PALETTE.error, children: message }),
|
|
10856
10855
|
/* @__PURE__ */ jsxs16(Box16, { gap: 3, marginTop: 1, children: [
|
|
10857
10856
|
onAcknowledgeBreakingChanges ? /* @__PURE__ */ jsxs16(Fragment7, { children: [
|
|
10858
|
-
/* @__PURE__ */ jsx20(Text17, {
|
|
10859
|
-
/* @__PURE__ */ jsx20(Text17, {
|
|
10860
|
-
] }) : /* @__PURE__ */ jsx20(Text17, {
|
|
10861
|
-
onRetryCredentials && /* @__PURE__ */ jsx20(Text17, {
|
|
10857
|
+
/* @__PURE__ */ jsx20(Text17, { children: "[Enter] Acknowledge and apply" }),
|
|
10858
|
+
/* @__PURE__ */ jsx20(Text17, { children: "[Esc / q] Exit" })
|
|
10859
|
+
] }) : /* @__PURE__ */ jsx20(Text17, { children: "[Enter / q] Exit" }),
|
|
10860
|
+
onRetryCredentials && /* @__PURE__ */ jsx20(Text17, { children: "[r] Re-enter credentials" })
|
|
10862
10861
|
] })
|
|
10863
10862
|
] });
|
|
10864
10863
|
}
|
|
@@ -10931,12 +10930,12 @@ function PushingStep({ stepNumber, totalSteps, progress }) {
|
|
|
10931
10930
|
/* @__PURE__ */ jsx22(StepHeader, { stepNumber, totalSteps, title: "Push to Contentful" }),
|
|
10932
10931
|
/* @__PURE__ */ jsx22(Text18, { children: "Writing component types and design tokens to your Contentful space..." }),
|
|
10933
10932
|
operationId && /* @__PURE__ */ jsxs17(Box17, { gap: 1, children: [
|
|
10934
|
-
/* @__PURE__ */ jsx22(Text18, {
|
|
10933
|
+
/* @__PURE__ */ jsx22(Text18, { color: PALETTE.muted, children: "Operation:" }),
|
|
10935
10934
|
/* @__PURE__ */ jsx22(Text18, { children: operationId })
|
|
10936
10935
|
] }),
|
|
10937
10936
|
showGlobal && progress && progress.kind === "progress" && /* @__PURE__ */ jsx22(Box17, { gap: 1, flexDirection: "column", children: /* @__PURE__ */ jsxs17(Box17, { gap: 2, children: [
|
|
10938
10937
|
/* @__PURE__ */ jsx22(Box17, { width: 40, children: /* @__PURE__ */ jsx22(ThemeProvider2, { theme: INK_UI_THEME, children: /* @__PURE__ */ jsx22(ProgressBar2, { value: Math.round(progress.processed / progress.total * 100) }) }) }),
|
|
10939
|
-
/* @__PURE__ */ jsxs17(Text18, {
|
|
10938
|
+
/* @__PURE__ */ jsxs17(Text18, { color: PALETTE.muted, children: [
|
|
10940
10939
|
progress.processed,
|
|
10941
10940
|
"/",
|
|
10942
10941
|
progress.total,
|
|
@@ -10944,10 +10943,10 @@ function PushingStep({ stepNumber, totalSteps, progress }) {
|
|
|
10944
10943
|
] })
|
|
10945
10944
|
] }) }),
|
|
10946
10945
|
showCurrent && /* @__PURE__ */ jsxs17(Box17, { gap: 1, children: [
|
|
10947
|
-
/* @__PURE__ */ jsx22(Text18, {
|
|
10946
|
+
/* @__PURE__ */ jsx22(Text18, { color: PALETTE.muted, children: "Now processing:" }),
|
|
10948
10947
|
/* @__PURE__ */ jsx22(Text18, { children: showCurrent })
|
|
10949
10948
|
] }),
|
|
10950
|
-
/* @__PURE__ */ jsx22(Box17, { marginTop: 1, children: /* @__PURE__ */ jsxs17(Text18, {
|
|
10949
|
+
/* @__PURE__ */ jsx22(Box17, { marginTop: 1, children: /* @__PURE__ */ jsxs17(Text18, { color: PALETTE.muted, children: [
|
|
10951
10950
|
"Elapsed: ",
|
|
10952
10951
|
elapsed
|
|
10953
10952
|
] }) })
|
|
@@ -10959,6 +10958,7 @@ var init_PushingStep = __esm({
|
|
|
10959
10958
|
init_StepHeader();
|
|
10960
10959
|
init_use_timed_spinner();
|
|
10961
10960
|
init_theme();
|
|
10961
|
+
init_theme();
|
|
10962
10962
|
}
|
|
10963
10963
|
});
|
|
10964
10964
|
|
|
@@ -19565,7 +19565,7 @@ function PreviewBadge({
|
|
|
19565
19565
|
badge,
|
|
19566
19566
|
highlighted = false
|
|
19567
19567
|
}) {
|
|
19568
|
-
return badge ? /* @__PURE__ */ jsx23(Text19, { color: badge.
|
|
19568
|
+
return badge ? /* @__PURE__ */ jsx23(Text19, { color: !highlighted && badge.dim ? PALETTE.muted : badge.color, bold: badge.bold, children: badge.char }) : /* @__PURE__ */ jsx23(Text19, { children: " " });
|
|
19569
19569
|
}
|
|
19570
19570
|
var init_Sidebar = __esm({
|
|
19571
19571
|
"packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/Sidebar.tsx"() {
|
|
@@ -20032,16 +20032,15 @@ function GroupedSidebar(props) {
|
|
|
20032
20032
|
return /* @__PURE__ */ jsxs19(Box19, { children: [
|
|
20033
20033
|
isCursor ? /* @__PURE__ */ jsx24(Text20, { color: PALETTE.info, bold: true, children: figures.pointer }) : /* @__PURE__ */ jsx24(Text20, { children: " " }),
|
|
20034
20034
|
/* @__PURE__ */ jsx24(PreviewBadge, { badge, highlighted: isSelected }),
|
|
20035
|
-
selectionStateByKey !== void 0 && (selGlyph && !isSynthetic ? /* @__PURE__ */ jsx24(Text20, { color:
|
|
20035
|
+
selectionStateByKey !== void 0 && (selGlyph && !isSynthetic ? /* @__PURE__ */ jsx24(Text20, { color: !isSelected && selDim ? PALETTE.muted : selColor, bold: selBold, children: " " + selGlyph }) : /* @__PURE__ */ jsx24(Text20, { children: " " })),
|
|
20036
20036
|
aiFlaggedByKey !== void 0 && (aiFlagged ? /* @__PURE__ */ jsx24(Text20, { color: PALETTE.warning, bold: true, children: " [\xD7]" }) : /* @__PURE__ */ jsx24(Text20, { children: " " })),
|
|
20037
20037
|
/* @__PURE__ */ jsxs19(
|
|
20038
20038
|
Text20,
|
|
20039
20039
|
{
|
|
20040
|
-
color: isSelected ? PALETTE.info : labelStyle.color,
|
|
20040
|
+
color: isSelected ? PALETTE.info : labelStyle.dim ? PALETTE.muted : labelStyle.color,
|
|
20041
20041
|
bold: isSelected || labelStyle.bold,
|
|
20042
20042
|
inverse: false,
|
|
20043
20043
|
underline: isSelected && !focused,
|
|
20044
|
-
dimColor: isSelected ? false : labelStyle.dim,
|
|
20045
20044
|
wrap: wrapLabels ? "wrap" : "truncate",
|
|
20046
20045
|
children: [
|
|
20047
20046
|
" ",
|
|
@@ -20049,7 +20048,7 @@ function GroupedSidebar(props) {
|
|
|
20049
20048
|
]
|
|
20050
20049
|
}
|
|
20051
20050
|
),
|
|
20052
|
-
inheritanceStyle.glyph && /* @__PURE__ */ jsx24(Text20, { color: inheritanceStyle.
|
|
20051
|
+
inheritanceStyle.glyph && /* @__PURE__ */ jsx24(Text20, { color: inheritanceStyle.dim ? PALETTE.muted : inheritanceStyle.color, bold: inheritanceStyle.bold, children: " " + inheritanceStyle.glyph })
|
|
20053
20052
|
] }, row.key);
|
|
20054
20053
|
}),
|
|
20055
20054
|
windowed && /* @__PURE__ */ jsx24(WindowIndicator, { direction: "down", count: allRows.length - end })
|
|
@@ -20331,12 +20330,12 @@ function SearchMatchSummary({
|
|
|
20331
20330
|
/* @__PURE__ */ jsxs20(Text21, { children: [
|
|
20332
20331
|
`/${query}`,
|
|
20333
20332
|
/* @__PURE__ */ jsx25(Text21, { color: PALETTE.info, children: "\u258E" }),
|
|
20334
|
-
query && /* @__PURE__ */ jsx25(Text21, {
|
|
20335
|
-
/* @__PURE__ */ jsx25(Text21, {
|
|
20333
|
+
query && /* @__PURE__ */ jsx25(Text21, { color: PALETTE.muted, children: formatSearchMatchSummary(matches, total) }),
|
|
20334
|
+
/* @__PURE__ */ jsx25(Text21, { children: " \xB7 [Esc] leave" })
|
|
20336
20335
|
] }),
|
|
20337
|
-
autocompleteCandidates.length > 1 && /* @__PURE__ */ jsx25(Text21, {
|
|
20336
|
+
autocompleteCandidates.length > 1 && /* @__PURE__ */ jsx25(Text21, { color: PALETTE.muted, children: ` possibilities: ${autocompleteCandidates.join(" \xB7 ").slice(0, 120)}` })
|
|
20338
20337
|
] }),
|
|
20339
|
-
!open && query && /* @__PURE__ */ jsx25(Box20, { marginTop, children: /* @__PURE__ */ jsx25(Text21, {
|
|
20338
|
+
!open && query && /* @__PURE__ */ jsx25(Box20, { marginTop, children: /* @__PURE__ */ jsx25(Text21, { children: `/${query}${formatSearchMatchSummary(matches, total)} \xB7 [Esc] clear` }) })
|
|
20340
20339
|
] });
|
|
20341
20340
|
}
|
|
20342
20341
|
var init_SearchMatchSummary = __esm({
|
|
@@ -20468,13 +20467,13 @@ function GotoBanner({
|
|
|
20468
20467
|
flexShrink: 0,
|
|
20469
20468
|
children: [
|
|
20470
20469
|
/* @__PURE__ */ jsx26(Text22, { bold: true, children: title }),
|
|
20471
|
-
moreAbove > 0 && /* @__PURE__ */ jsx26(Text22, {
|
|
20470
|
+
moreAbove > 0 && /* @__PURE__ */ jsx26(Text22, { color: PALETTE.muted, children: ` \u25B2 ${moreAbove} more` }),
|
|
20472
20471
|
visible.map((row, vi) => {
|
|
20473
20472
|
const i = start + vi;
|
|
20474
20473
|
return renderRow(row, i, i === highlightIndex);
|
|
20475
20474
|
}),
|
|
20476
|
-
moreBelow > 0 && /* @__PURE__ */ jsx26(Text22, {
|
|
20477
|
-
footerHint !== void 0 && /* @__PURE__ */ jsx26(Text22, {
|
|
20475
|
+
moreBelow > 0 && /* @__PURE__ */ jsx26(Text22, { color: PALETTE.muted, children: ` \u25BC ${moreBelow} more` }),
|
|
20476
|
+
footerHint !== void 0 && /* @__PURE__ */ jsx26(Text22, { color: PALETTE.muted, children: footerHint })
|
|
20478
20477
|
]
|
|
20479
20478
|
}
|
|
20480
20479
|
);
|
|
@@ -20577,7 +20576,7 @@ import { jsx as jsx28, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
|
20577
20576
|
function legendEntry(keyBracket, label, active = false) {
|
|
20578
20577
|
return /* @__PURE__ */ jsxs23(Text24, { children: [
|
|
20579
20578
|
/* @__PURE__ */ jsx28(Text24, { color: active ? PALETTE.warning : PALETTE.info, inverse: active, children: keyBracket }),
|
|
20580
|
-
/* @__PURE__ */ jsx28(Text24, { color: active ? PALETTE.warning : void 0, inverse: active,
|
|
20579
|
+
/* @__PURE__ */ jsx28(Text24, { color: active ? PALETTE.warning : void 0, inverse: active, children: " " + label })
|
|
20581
20580
|
] }, keyBracket + label);
|
|
20582
20581
|
}
|
|
20583
20582
|
var init_LegendEntry = __esm({
|
|
@@ -20591,7 +20590,7 @@ var init_LegendEntry = __esm({
|
|
|
20591
20590
|
import { Box as Box23 } from "ink";
|
|
20592
20591
|
import { jsxs as jsxs24 } from "react/jsx-runtime";
|
|
20593
20592
|
function CompactControlBar({ hasGroupRoots, searchActive }) {
|
|
20594
|
-
return /* @__PURE__ */ jsxs24(Box23, { borderStyle: "single", borderColor: PALETTE.border, paddingX: 1,
|
|
20593
|
+
return /* @__PURE__ */ jsxs24(Box23, { borderStyle: "single", borderColor: PALETTE.border, paddingX: 1, flexWrap: "wrap", columnGap: 2, children: [
|
|
20595
20594
|
legendEntry("[\u2191/\u2193]", "move"),
|
|
20596
20595
|
legendEntry("[a/r]", "accept/reject"),
|
|
20597
20596
|
legendEntry("[f]", "continue/finalize"),
|
|
@@ -20620,29 +20619,30 @@ function CounterStrip(props) {
|
|
|
20620
20619
|
const labelUnd = condensed ? "Und" : "Undecided";
|
|
20621
20620
|
const sep = condensed ? " | " : " ";
|
|
20622
20621
|
return /* @__PURE__ */ jsx29(Box24, { children: /* @__PURE__ */ jsxs25(Text25, { children: [
|
|
20623
|
-
/* @__PURE__ */ jsxs25(Text25, {
|
|
20622
|
+
/* @__PURE__ */ jsxs25(Text25, { color: PALETTE.muted, children: [
|
|
20624
20623
|
labelGrp,
|
|
20625
20624
|
" "
|
|
20626
20625
|
] }),
|
|
20627
20626
|
/* @__PURE__ */ jsx29(Text25, { bold: true, children: counters.groups }),
|
|
20628
|
-
/* @__PURE__ */ jsx29(Text25, {
|
|
20629
|
-
/* @__PURE__ */ jsxs25(Text25, {
|
|
20627
|
+
/* @__PURE__ */ jsx29(Text25, { color: PALETTE.muted, children: sep }),
|
|
20628
|
+
/* @__PURE__ */ jsxs25(Text25, { color: PALETTE.muted, children: [
|
|
20630
20629
|
labelRej,
|
|
20631
20630
|
" "
|
|
20632
20631
|
] }),
|
|
20633
20632
|
/* @__PURE__ */ jsx29(Text25, { bold: true, children: counters.rejected }),
|
|
20634
|
-
/* @__PURE__ */ jsx29(Text25, {
|
|
20635
|
-
/* @__PURE__ */ jsxs25(Text25, {
|
|
20633
|
+
/* @__PURE__ */ jsx29(Text25, { color: PALETTE.muted, children: sep }),
|
|
20634
|
+
/* @__PURE__ */ jsxs25(Text25, { color: PALETTE.muted, children: [
|
|
20636
20635
|
labelUnd,
|
|
20637
20636
|
" "
|
|
20638
20637
|
] }),
|
|
20639
20638
|
/* @__PURE__ */ jsx29(Text25, { bold: true, children: counters.undecided }),
|
|
20640
|
-
/* @__PURE__ */ jsx29(Text25, {
|
|
20639
|
+
/* @__PURE__ */ jsx29(Text25, { color: PALETTE.muted, children: sep })
|
|
20641
20640
|
] }) });
|
|
20642
20641
|
}
|
|
20643
20642
|
var init_CounterStrip = __esm({
|
|
20644
20643
|
"packages/experience-design-system-cli-legacy/src/import/tui/components/CounterStrip.tsx"() {
|
|
20645
20644
|
"use strict";
|
|
20645
|
+
init_theme();
|
|
20646
20646
|
}
|
|
20647
20647
|
});
|
|
20648
20648
|
|
|
@@ -21595,12 +21595,14 @@ function ScopeGateStepView({
|
|
|
21595
21595
|
return /* @__PURE__ */ jsx30(HelpOverlay, { sections: HELP_SECTIONS, handleInput: false, onClose: () => setShowHelp(false) });
|
|
21596
21596
|
}
|
|
21597
21597
|
return /* @__PURE__ */ jsxs26(Box25, { flexDirection: "column", paddingX: 2, children: [
|
|
21598
|
-
/* @__PURE__ */
|
|
21599
|
-
|
|
21600
|
-
|
|
21601
|
-
|
|
21598
|
+
/* @__PURE__ */ jsxs26(Box25, { flexDirection: "row", flexWrap: "wrap", children: [
|
|
21599
|
+
/* @__PURE__ */ jsx30(CounterStrip, { counters, totalWidth }),
|
|
21600
|
+
hasAnyAi && /* @__PURE__ */ jsxs26(Text26, { color: PALETTE.muted, children: [
|
|
21601
|
+
`${aiExcludedCount} component${aiExcludedCount === 1 ? "" : "s"} flagged by AI`,
|
|
21602
|
+
aiRows.length > 0 && /* @__PURE__ */ jsx30(Text26, { color: PALETTE.info, children: " \u2014 press [x] to see why" })
|
|
21603
|
+
] })
|
|
21602
21604
|
] }),
|
|
21603
|
-
hasCycles && /* @__PURE__ */ jsx30(Box25, { marginTop: 1, children: /* @__PURE__ */ jsx30(Text26, {
|
|
21605
|
+
hasCycles && /* @__PURE__ */ jsx30(Box25, { marginTop: 1, children: /* @__PURE__ */ jsx30(Text26, { color: PALETTE.muted, children: "If you must have components with cycles, select them together into the generate step and then use the editor to fix them." }) }),
|
|
21604
21606
|
/* @__PURE__ */ jsxs26(Box25, { flexDirection: "row", alignItems: "stretch", children: [
|
|
21605
21607
|
aiRationalePanel.isOpen ? /* @__PURE__ */ jsx30(
|
|
21606
21608
|
GotoBanner,
|
|
@@ -21673,13 +21675,13 @@ function ScopeGateStepView({
|
|
|
21673
21675
|
/* @__PURE__ */ jsx30(Text26, { color: PALETTE.warning, inverse: isCursor, children: " " + label })
|
|
21674
21676
|
] }, i);
|
|
21675
21677
|
}),
|
|
21676
|
-
/* @__PURE__ */ jsx30(Text26, {
|
|
21678
|
+
/* @__PURE__ */ jsx30(Text26, { children: "[\u2191/\u2193] move \xB7 [Enter] jump \xB7 [c/Esc] close" })
|
|
21677
21679
|
] }),
|
|
21678
21680
|
pendingRejectCascade && /* @__PURE__ */ jsxs26(Box25, { flexDirection: "column", borderStyle: "single", borderColor: PALETTE.warning, paddingX: 1, marginTop: 1, children: [
|
|
21679
21681
|
/* @__PURE__ */ jsx30(Text26, { bold: true, color: PALETTE.warning, children: `Rejecting ${pendingRejectCascade.target} will:` }),
|
|
21680
21682
|
pendingRejectCascade.ancestors.length > 0 && /* @__PURE__ */ jsx30(Text26, { children: `- Reject ancestors: ${pendingRejectCascade.ancestors.join(", ")}` }),
|
|
21681
21683
|
pendingRejectCascade.descendants.length > 0 && /* @__PURE__ */ jsx30(Text26, { children: `- Deselect descendants: ${pendingRejectCascade.descendants.join(", ")}` }),
|
|
21682
|
-
/* @__PURE__ */ jsx30(Text26, {
|
|
21684
|
+
/* @__PURE__ */ jsx30(Text26, { children: "[y] confirm \xB7 [n]/[Esc] cancel" })
|
|
21683
21685
|
] }),
|
|
21684
21686
|
/* @__PURE__ */ jsx30(
|
|
21685
21687
|
SearchMatchSummary,
|
|
@@ -21748,7 +21750,7 @@ function AddedColumn(props) {
|
|
|
21748
21750
|
const window = computeColumnWindow(entries.length, cursor, Math.max(1, visibleCount));
|
|
21749
21751
|
return /* @__PURE__ */ jsxs26(WindowedPanel, { width, height, title, focused, children: [
|
|
21750
21752
|
/* @__PURE__ */ jsx30(WindowIndicator, { direction: "up", count: window.above }),
|
|
21751
|
-
entries.length === 0 ? /* @__PURE__ */ jsx30(Text26, {
|
|
21753
|
+
entries.length === 0 ? /* @__PURE__ */ jsx30(Text26, { color: PALETTE.muted, children: "(none)" }) : entries.slice(window.start, window.end).map((entry, vi) => {
|
|
21752
21754
|
const i = window.start + vi;
|
|
21753
21755
|
const isSelected = i === cursor;
|
|
21754
21756
|
const isCursor = focused && isSelected;
|
|
@@ -22365,7 +22367,7 @@ function serializeState(state, originalJson) {
|
|
|
22365
22367
|
function Picker({ value, active }) {
|
|
22366
22368
|
return /* @__PURE__ */ jsxs27(Box26, { children: [
|
|
22367
22369
|
active && /* @__PURE__ */ jsx31(Text27, { color: PALETTE.warning, children: "\u2039" }),
|
|
22368
|
-
/* @__PURE__ */ jsx31(Text27, { color: active ? PALETTE.warning :
|
|
22370
|
+
/* @__PURE__ */ jsx31(Text27, { color: active ? PALETTE.warning : void 0, bold: active, children: value }),
|
|
22369
22371
|
active && /* @__PURE__ */ jsx31(Text27, { color: PALETTE.warning, children: "\u203A" })
|
|
22370
22372
|
] });
|
|
22371
22373
|
}
|
|
@@ -22380,7 +22382,7 @@ function InlinePropField({
|
|
|
22380
22382
|
width
|
|
22381
22383
|
}) {
|
|
22382
22384
|
return /* @__PURE__ */ jsxs27(Box26, { width, gap: 1, flexShrink: flexible ? 1 : 0, flexGrow: flexible ? 1 : 0, flexWrap: "wrap", children: [
|
|
22383
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22385
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, wrap: "truncate-end", children: [
|
|
22384
22386
|
focused ? "\u203A " : " ",
|
|
22385
22387
|
label
|
|
22386
22388
|
] }),
|
|
@@ -22401,11 +22403,11 @@ function DefaultValueRow({
|
|
|
22401
22403
|
focused
|
|
22402
22404
|
}) {
|
|
22403
22405
|
return /* @__PURE__ */ jsxs27(Box26, { gap: 1, flexWrap: "wrap", flexShrink: 0, children: [
|
|
22404
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22406
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, children: [
|
|
22405
22407
|
focused ? "\u203A " : " ",
|
|
22406
22408
|
"default:"
|
|
22407
22409
|
] }),
|
|
22408
|
-
active ? /* @__PURE__ */ jsx31(Picker, { value: display, active: true }) : /* @__PURE__ */ jsx31(Text27, {
|
|
22410
|
+
active ? /* @__PURE__ */ jsx31(Picker, { value: display, active: true }) : /* @__PURE__ */ jsx31(Text27, { wrap: "wrap", children: display })
|
|
22409
22411
|
] });
|
|
22410
22412
|
}
|
|
22411
22413
|
function RowLabel({
|
|
@@ -22451,7 +22453,7 @@ function EditableListItem({
|
|
|
22451
22453
|
if (isBeingEdited) {
|
|
22452
22454
|
return /* @__PURE__ */ jsx31(ValueInputRow, { mode: "edit", valueText, cursorVisible });
|
|
22453
22455
|
}
|
|
22454
|
-
return /* @__PURE__ */ jsx31(Box26, { gap: 1, paddingLeft: 2, children: /* @__PURE__ */ jsx31(Text27, { color: active ? PALETTE.info :
|
|
22456
|
+
return /* @__PURE__ */ jsx31(Box26, { gap: 1, paddingLeft: 2, children: /* @__PURE__ */ jsx31(Text27, { color: active ? PALETTE.info : void 0, children: active ? `${figures4.pointer} ${value}` : ` ${value}` }) });
|
|
22455
22457
|
}
|
|
22456
22458
|
function EditableValueList({
|
|
22457
22459
|
values,
|
|
@@ -22465,7 +22467,7 @@ function EditableValueList({
|
|
|
22465
22467
|
showAddInput
|
|
22466
22468
|
}) {
|
|
22467
22469
|
return /* @__PURE__ */ jsxs27(Fragment11, { children: [
|
|
22468
|
-
values.length === 0 && !editingValue && (emptyPaddingLeft === void 0 ? /* @__PURE__ */ jsx31(Text27, {
|
|
22470
|
+
values.length === 0 && !editingValue && (emptyPaddingLeft === void 0 ? /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: emptyMessage }) : /* @__PURE__ */ jsx31(Box26, { paddingLeft: emptyPaddingLeft, children: /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: emptyMessage }) })),
|
|
22469
22471
|
values.map((value, index) => /* @__PURE__ */ jsx31(
|
|
22470
22472
|
EditableListItem,
|
|
22471
22473
|
{
|
|
@@ -22491,11 +22493,11 @@ function DefaultSubRow({
|
|
|
22491
22493
|
const cursor = cursorVisible ? "\u2588" : " ";
|
|
22492
22494
|
if (prop.type === "richtext" || prop.type === "media" || prop.type === "link") {
|
|
22493
22495
|
return /* @__PURE__ */ jsxs27(Box26, { gap: 1, flexShrink: 0, children: [
|
|
22494
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22496
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, children: [
|
|
22495
22497
|
focused ? "\u203A " : " ",
|
|
22496
22498
|
"default:"
|
|
22497
22499
|
] }),
|
|
22498
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
22500
|
+
/* @__PURE__ */ jsx31(Text27, { color: focused ? void 0 : PALETTE.muted, children: "(not applicable)" })
|
|
22499
22501
|
] });
|
|
22500
22502
|
}
|
|
22501
22503
|
if (prop.type === "boolean") {
|
|
@@ -22505,11 +22507,11 @@ function DefaultSubRow({
|
|
|
22505
22507
|
if (prop.type === "enum") {
|
|
22506
22508
|
if (prop.values.length === 0) {
|
|
22507
22509
|
return /* @__PURE__ */ jsxs27(Box26, { gap: 1, flexShrink: 0, children: [
|
|
22508
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22510
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, children: [
|
|
22509
22511
|
focused ? "\u203A " : " ",
|
|
22510
22512
|
"default:"
|
|
22511
22513
|
] }),
|
|
22512
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
22514
|
+
/* @__PURE__ */ jsx31(Text27, { color: focused ? void 0 : PALETTE.muted, children: "(no values defined)" })
|
|
22513
22515
|
] });
|
|
22514
22516
|
}
|
|
22515
22517
|
const display = typeof prop.default === "string" && prop.default !== "" ? prop.default : "(unset)";
|
|
@@ -22518,7 +22520,7 @@ function DefaultSubRow({
|
|
|
22518
22520
|
const value = typeof prop.default === "string" ? prop.default : "";
|
|
22519
22521
|
if (active) {
|
|
22520
22522
|
return /* @__PURE__ */ jsxs27(Box26, { flexDirection: "row", flexShrink: 0, children: [
|
|
22521
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22523
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, children: [
|
|
22522
22524
|
focused ? "\u203A " : " ",
|
|
22523
22525
|
"default:"
|
|
22524
22526
|
] }),
|
|
@@ -22530,11 +22532,11 @@ function DefaultSubRow({
|
|
|
22530
22532
|
] });
|
|
22531
22533
|
}
|
|
22532
22534
|
return /* @__PURE__ */ jsxs27(Box26, { gap: 1, flexShrink: 0, children: [
|
|
22533
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22535
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, children: [
|
|
22534
22536
|
focused ? "\u203A " : " ",
|
|
22535
22537
|
"default:"
|
|
22536
22538
|
] }),
|
|
22537
|
-
/* @__PURE__ */ jsx31(Text27, { color: focused
|
|
22539
|
+
/* @__PURE__ */ jsx31(Text27, { color: focused || value ? void 0 : PALETTE.muted, children: value || "(none)" })
|
|
22538
22540
|
] });
|
|
22539
22541
|
}
|
|
22540
22542
|
function DescriptionField({
|
|
@@ -22550,15 +22552,15 @@ function DescriptionField({
|
|
|
22550
22552
|
}) {
|
|
22551
22553
|
if (compact) {
|
|
22552
22554
|
return /* @__PURE__ */ jsxs27(Box26, { gap: 1, flexWrap: "wrap", width, flexShrink: 0, children: [
|
|
22553
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22555
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, children: [
|
|
22554
22556
|
focused ? "\u203A " : " ",
|
|
22555
22557
|
label
|
|
22556
22558
|
] }),
|
|
22557
|
-
/* @__PURE__ */ jsx31(Text27, { wrap: "truncate-end",
|
|
22559
|
+
/* @__PURE__ */ jsx31(Text27, { wrap: "truncate-end", color: value ? void 0 : PALETTE.muted, children: value || "\u2014" })
|
|
22558
22560
|
] });
|
|
22559
22561
|
}
|
|
22560
22562
|
return /* @__PURE__ */ jsxs27(Box26, { paddingLeft, flexDirection: "column", width, flexShrink: 0, children: [
|
|
22561
|
-
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning :
|
|
22563
|
+
/* @__PURE__ */ jsxs27(Text27, { color: focused ? PALETTE.warning : PALETTE.muted, bold: focused, children: [
|
|
22562
22564
|
focused ? "\u203A " : " ",
|
|
22563
22565
|
label
|
|
22564
22566
|
] }),
|
|
@@ -22618,23 +22620,15 @@ function PropRow({
|
|
|
22618
22620
|
activeField
|
|
22619
22621
|
}
|
|
22620
22622
|
),
|
|
22621
|
-
/* @__PURE__ */ jsx31(InlinePropField, { label: "type:", focused: activeField === "type", children: editingField && activeField === "type" ? /* @__PURE__ */ jsx31(Picker, { value: prop.type, active: true }) : /* @__PURE__ */ jsx31(Text27, {
|
|
22623
|
+
/* @__PURE__ */ jsx31(InlinePropField, { label: "type:", focused: activeField === "type", children: editingField && activeField === "type" ? /* @__PURE__ */ jsx31(Picker, { value: prop.type, active: true }) : /* @__PURE__ */ jsx31(Text27, { children: prop.type }) })
|
|
22622
22624
|
] }),
|
|
22623
|
-
prop.type === "token" && /* @__PURE__ */ jsx31(InlinePropField, { label: "kind:", focused: activeField === "tokenKind", width, children: editingField && activeField === "tokenKind" ? /* @__PURE__ */ jsx31(Picker, { value: prop.tokenKind || DESIGN_TOKEN_TYPES2[0], active: true }) : /* @__PURE__ */ jsx31(Text27, {
|
|
22625
|
+
prop.type === "token" && /* @__PURE__ */ jsx31(InlinePropField, { label: "kind:", focused: activeField === "tokenKind", width, children: editingField && activeField === "tokenKind" ? /* @__PURE__ */ jsx31(Picker, { value: prop.tokenKind || DESIGN_TOKEN_TYPES2[0], active: true }) : /* @__PURE__ */ jsx31(Text27, { wrap: "wrap", children: prop.tokenKind || "\u2014" }) }),
|
|
22624
22626
|
prop.type === "enum" && /* @__PURE__ */ jsxs27(Box26, { gap: 1, flexWrap: "wrap", width, flexShrink: 0, children: [
|
|
22625
|
-
/* @__PURE__ */ jsxs27(
|
|
22626
|
-
|
|
22627
|
-
|
|
22628
|
-
|
|
22629
|
-
|
|
22630
|
-
dimColor: activeField !== "values",
|
|
22631
|
-
children: [
|
|
22632
|
-
activeField === "values" ? "\u203A " : " ",
|
|
22633
|
-
"values:"
|
|
22634
|
-
]
|
|
22635
|
-
}
|
|
22636
|
-
),
|
|
22637
|
-
/* @__PURE__ */ jsxs27(Text27, { color: activeField === "values" ? PALETTE.inverse : selected ? PALETTE.inverse : void 0, wrap: "wrap", children: [
|
|
22627
|
+
/* @__PURE__ */ jsxs27(Text27, { color: activeField === "values" ? PALETTE.warning : PALETTE.muted, bold: activeField === "values", children: [
|
|
22628
|
+
activeField === "values" ? "\u203A " : " ",
|
|
22629
|
+
"values:"
|
|
22630
|
+
] }),
|
|
22631
|
+
/* @__PURE__ */ jsxs27(Text27, { wrap: "wrap", children: [
|
|
22638
22632
|
"[",
|
|
22639
22633
|
prop.values.join(", "),
|
|
22640
22634
|
"]"
|
|
@@ -22651,37 +22645,28 @@ function PropRow({
|
|
|
22651
22645
|
}
|
|
22652
22646
|
),
|
|
22653
22647
|
prop.type === "token" && prop.category === "design" && /* @__PURE__ */ jsxs27(Box26, { gap: 1, flexWrap: "wrap", width, flexShrink: 0, children: [
|
|
22654
|
-
/* @__PURE__ */ jsxs27(
|
|
22655
|
-
|
|
22656
|
-
|
|
22657
|
-
|
|
22658
|
-
|
|
22659
|
-
dimColor: activeField !== "allowed",
|
|
22660
|
-
children: [
|
|
22661
|
-
activeField === "allowed" ? "\u203A " : " ",
|
|
22662
|
-
"allowed:"
|
|
22663
|
-
]
|
|
22664
|
-
}
|
|
22665
|
-
),
|
|
22666
|
-
editingField && activeField === "allowed" ? /* @__PURE__ */ jsx31(Box26, { width: Math.max(1, width - 4), borderStyle: "round", borderColor: PALETTE.warning, paddingX: 1, children: /* @__PURE__ */ jsx31(Text27, { dimColor: true, children: "press [t] to edit allowed tokens" }) }) : /* @__PURE__ */ jsx31(
|
|
22648
|
+
/* @__PURE__ */ jsxs27(Text27, { color: activeField === "allowed" ? PALETTE.warning : PALETTE.muted, bold: activeField === "allowed", children: [
|
|
22649
|
+
activeField === "allowed" ? "\u203A " : " ",
|
|
22650
|
+
"allowed:"
|
|
22651
|
+
] }),
|
|
22652
|
+
editingField && activeField === "allowed" ? /* @__PURE__ */ jsx31(Box26, { width: Math.max(1, width - 4), borderStyle: "round", borderColor: PALETTE.warning, paddingX: 1, children: /* @__PURE__ */ jsx31(Text27, { children: "press [t] to edit allowed tokens" }) }) : /* @__PURE__ */ jsx31(
|
|
22667
22653
|
Text27,
|
|
22668
22654
|
{
|
|
22669
|
-
color: activeField
|
|
22670
|
-
dimColor: prop.allowed.length === 0 && activeField !== "allowed",
|
|
22655
|
+
color: activeField !== "allowed" && prop.allowed.length === 0 ? PALETTE.muted : void 0,
|
|
22671
22656
|
wrap: "wrap",
|
|
22672
22657
|
children: prop.allowed.length > 0 ? prop.allowed.join(", ") : "(any)"
|
|
22673
22658
|
}
|
|
22674
22659
|
)
|
|
22675
22660
|
] }),
|
|
22676
|
-
selected && showRationale && rationale && rationale.trim().length > 0 && /* @__PURE__ */ jsx31(Box26, { paddingLeft: 2, children: /* @__PURE__ */ jsx31(Text27, {
|
|
22661
|
+
selected && showRationale && rationale && rationale.trim().length > 0 && /* @__PURE__ */ jsx31(Box26, { paddingLeft: 2, children: /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: (() => {
|
|
22677
22662
|
const max = Math.max(8, width - 8);
|
|
22678
22663
|
const text = `~ ${rationale}`;
|
|
22679
22664
|
return text.length > max ? text.slice(0, max - 1) + "\u2026" : text;
|
|
22680
22665
|
})() }) }, rowKey ? `rationale-${rowKey}` : void 0),
|
|
22681
22666
|
selected && prop.type === "enum" && activeField === "values" && /* @__PURE__ */ jsxs27(Box26, { paddingLeft: 2, flexDirection: "column", children: [
|
|
22682
22667
|
/* @__PURE__ */ jsxs27(Box26, { children: [
|
|
22683
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
22684
|
-
activeField === "values" && /* @__PURE__ */ jsx31(Text27, {
|
|
22668
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "values:" }),
|
|
22669
|
+
activeField === "values" && /* @__PURE__ */ jsx31(Text27, { children: " [a] add [e] edit [r] remove [\u2191\u2193] navigate [K/J] reorder" })
|
|
22685
22670
|
] }),
|
|
22686
22671
|
/* @__PURE__ */ jsx31(
|
|
22687
22672
|
EditableValueList,
|
|
@@ -22741,32 +22726,30 @@ function SlotRow({
|
|
|
22741
22726
|
/* @__PURE__ */ jsxs27(
|
|
22742
22727
|
Text27,
|
|
22743
22728
|
{
|
|
22744
|
-
color: activeField === "allowedComponents" ? PALETTE.warning :
|
|
22729
|
+
color: activeField === "allowedComponents" ? PALETTE.warning : PALETTE.muted,
|
|
22745
22730
|
bold: activeField === "allowedComponents",
|
|
22746
|
-
dimColor: activeField !== "allowedComponents",
|
|
22747
22731
|
children: [
|
|
22748
22732
|
activeField === "allowedComponents" ? "\u203A " : " ",
|
|
22749
22733
|
"allowed:"
|
|
22750
22734
|
]
|
|
22751
22735
|
}
|
|
22752
22736
|
),
|
|
22753
|
-
slot.allowedComponents.length === 0 ? /* @__PURE__ */ jsx31(Text27, {
|
|
22737
|
+
slot.allowedComponents.length === 0 ? /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "(any)" }) : /* @__PURE__ */ jsx31(Text27, { wrap: "wrap", children: slot.allowedComponents.join(", ") })
|
|
22754
22738
|
] }),
|
|
22755
22739
|
selected && editingField && activeField === "allowedComponents" && /* @__PURE__ */ jsxs27(Box26, { flexDirection: "column", children: [
|
|
22756
22740
|
/* @__PURE__ */ jsxs27(Box26, { children: [
|
|
22757
22741
|
/* @__PURE__ */ jsxs27(
|
|
22758
22742
|
Text27,
|
|
22759
22743
|
{
|
|
22760
|
-
color: activeField === "allowedComponents" ? PALETTE.warning :
|
|
22744
|
+
color: activeField === "allowedComponents" ? PALETTE.warning : PALETTE.muted,
|
|
22761
22745
|
bold: activeField === "allowedComponents",
|
|
22762
|
-
dimColor: activeField !== "allowedComponents",
|
|
22763
22746
|
children: [
|
|
22764
22747
|
activeField === "allowedComponents" ? "\u203A " : " ",
|
|
22765
22748
|
"allowed:"
|
|
22766
22749
|
]
|
|
22767
22750
|
}
|
|
22768
22751
|
),
|
|
22769
|
-
editingField && activeField === "allowedComponents" && /* @__PURE__ */ jsx31(Text27, {
|
|
22752
|
+
editingField && activeField === "allowedComponents" && /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: slot.allowedComponents.length > 0 ? " [a] add [e] edit [r] remove [\u2190\u2192] cycle [\u2191\u2193] navigate [K/J] reorder" : " [a] add [e] edit [r] remove [\u2191\u2193] navigate [K/J] reorder" })
|
|
22770
22753
|
] }),
|
|
22771
22754
|
/* @__PURE__ */ jsx31(
|
|
22772
22755
|
EditableValueList,
|
|
@@ -22782,21 +22765,21 @@ function SlotRow({
|
|
|
22782
22765
|
showAddInput: editingField && activeField === "allowedComponents"
|
|
22783
22766
|
}
|
|
22784
22767
|
),
|
|
22785
|
-
editingField && editingValue?.mode === "add" && activeField === "allowedComponents" && pickerCandidates !== null && /* @__PURE__ */ jsx31(Box26, { paddingLeft: 2, flexDirection: "column", children: pickerCandidates.length === 0 ? /* @__PURE__ */ jsx31(Text27, {
|
|
22768
|
+
editingField && editingValue?.mode === "add" && activeField === "allowedComponents" && pickerCandidates !== null && /* @__PURE__ */ jsx31(Box26, { paddingLeft: 2, flexDirection: "column", children: pickerCandidates.length === 0 ? /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "(no valid components to add \u2014 all remaining candidates would create cycles)" }) : (() => {
|
|
22786
22769
|
const filtered = valueText.length === 0 ? pickerCandidates : pickerCandidates.filter((n) => n.toLowerCase().includes(valueText.toLowerCase()));
|
|
22787
22770
|
if (filtered.length === 0) {
|
|
22788
|
-
return /* @__PURE__ */ jsx31(Text27, {
|
|
22771
|
+
return /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "(no candidates match \u2014 Enter to add as free text)" });
|
|
22789
22772
|
}
|
|
22790
22773
|
const cursor = pickerCursor % filtered.length;
|
|
22791
22774
|
const MAX_VISIBLE = 5;
|
|
22792
22775
|
const start = Math.max(0, Math.min(filtered.length - MAX_VISIBLE, cursor - 2));
|
|
22793
22776
|
const slice = filtered.slice(start, start + MAX_VISIBLE);
|
|
22794
22777
|
return /* @__PURE__ */ jsxs27(Box26, { flexDirection: "column", children: [
|
|
22795
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
22778
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: " candidates (\u2191\u2193 cycle, Enter to add):" }),
|
|
22796
22779
|
slice.map((name, i) => {
|
|
22797
22780
|
const absIdx = start + i;
|
|
22798
22781
|
const isCursor = absIdx === cursor;
|
|
22799
|
-
return /* @__PURE__ */ jsx31(Text27, { color: isCursor ? PALETTE.info :
|
|
22782
|
+
return /* @__PURE__ */ jsx31(Text27, { color: isCursor ? PALETTE.info : PALETTE.muted, children: isCursor ? ` ${figures4.pointer} ${name}` : ` ${name}` }, name);
|
|
22800
22783
|
})
|
|
22801
22784
|
] });
|
|
22802
22785
|
})() })
|
|
@@ -23627,15 +23610,15 @@ function FieldEditor({
|
|
|
23627
23610
|
return /* @__PURE__ */ jsxs27(Box26, { flexDirection: "column", width, borderStyle: "single", borderColor: PALETTE.error, children: [
|
|
23628
23611
|
/* @__PURE__ */ jsx31(Text27, { bold: true, color: PALETTE.error, children: "FIELD EDITOR \u2014 parse error" }),
|
|
23629
23612
|
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.error, children: parseErr }),
|
|
23630
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23613
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "Cannot display structured editor. Fix the JSON first." })
|
|
23631
23614
|
] });
|
|
23632
23615
|
}
|
|
23633
23616
|
if (props.length === 0 && slots.length === 0) {
|
|
23634
23617
|
return /* @__PURE__ */ jsxs27(Box26, { flexDirection: "column", width, borderStyle: "single", borderColor: PALETTE.warning, children: [
|
|
23635
23618
|
/* @__PURE__ */ jsx31(Text27, { bold: true, color: PALETTE.warning, children: "FIELD EDITOR \u2014 no fields" }),
|
|
23636
23619
|
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.warning, children: "\u26A0 No properties classified for this component. The LLM didn't find anything to classify." }),
|
|
23637
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23638
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23620
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "You can add fields manually below or reject this component." }),
|
|
23621
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "Enter to save \xB7 Esc to discard" })
|
|
23639
23622
|
] });
|
|
23640
23623
|
}
|
|
23641
23624
|
const hasEmptyProperties = props.length === 0 && slots.length === 0;
|
|
@@ -23909,16 +23892,16 @@ function FieldEditor({
|
|
|
23909
23892
|
const headerPath = path ?? "<unknown source path>";
|
|
23910
23893
|
if (!start || !end2 || !src) {
|
|
23911
23894
|
return /* @__PURE__ */ jsxs27(Box26, { flexDirection: "column", borderStyle: "single", borderColor: "gray", paddingX: 1, children: [
|
|
23912
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23913
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23914
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23895
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, bold: true, children: `source: ${headerPath}` }),
|
|
23896
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "(no source location captured for this prop)" }),
|
|
23897
|
+
/* @__PURE__ */ jsx31(Text27, { children: "[s] close" })
|
|
23915
23898
|
] });
|
|
23916
23899
|
}
|
|
23917
23900
|
const lines = src.split("\n").slice(Math.max(0, start - 1), end2);
|
|
23918
23901
|
return /* @__PURE__ */ jsxs27(Box26, { flexDirection: "column", borderStyle: "single", borderColor: "gray", paddingX: 1, children: [
|
|
23919
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23920
|
-
lines.map((ln, i) => /* @__PURE__ */ jsx31(Text27, {
|
|
23921
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23902
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, bold: true, children: `${headerPath}: lines ${start}\u2013${end2}` }),
|
|
23903
|
+
lines.map((ln, i) => /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: ln }, `source-line-${i}`)),
|
|
23904
|
+
/* @__PURE__ */ jsx31(Text27, { children: "[s] close \xB7 [Esc] close" })
|
|
23922
23905
|
] });
|
|
23923
23906
|
})(),
|
|
23924
23907
|
showHelp && /* @__PURE__ */ jsxs27(Box26, { flexDirection: "column", borderStyle: "round", borderColor: PALETTE.info, paddingX: 1, children: [
|
|
@@ -23947,10 +23930,10 @@ function FieldEditor({
|
|
|
23947
23930
|
/* @__PURE__ */ jsx31(Text27, { children: " " + componentRationaleKey.padEnd(16) + " toggle component rationale panel" }),
|
|
23948
23931
|
/* @__PURE__ */ jsx31(Text27, { children: " ? toggle this overlay" }),
|
|
23949
23932
|
/* @__PURE__ */ jsx31(Text27, { children: " " }),
|
|
23950
|
-
/* @__PURE__ */ jsx31(Text27, {
|
|
23933
|
+
/* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: "press ? or Esc to close" })
|
|
23951
23934
|
] }),
|
|
23952
23935
|
validationError && /* @__PURE__ */ jsx31(Text27, { color: PALETTE.error, children: "\u2717 " + validationError }),
|
|
23953
|
-
/* @__PURE__ */ jsx31(Box26, { paddingTop: 1, children: /* @__PURE__ */ jsx31(Text27, {
|
|
23936
|
+
/* @__PURE__ */ jsx31(Box26, { paddingTop: 1, children: /* @__PURE__ */ jsx31(Text27, { color: PALETTE.muted, children: modeLabel }) })
|
|
23954
23937
|
]
|
|
23955
23938
|
}
|
|
23956
23939
|
);
|
|
@@ -24013,16 +23996,16 @@ function RationaleLine({ line, active }) {
|
|
|
24013
23996
|
return /* @__PURE__ */ jsx32(Box27, { children: /* @__PURE__ */ jsx32(Text28, { children: " " }) });
|
|
24014
23997
|
}
|
|
24015
23998
|
if (line.kind === "heading") {
|
|
24016
|
-
return /* @__PURE__ */ jsx32(Box27, { children: /* @__PURE__ */ jsx32(Text28, { bold: true, color: PALETTE.info
|
|
23999
|
+
return /* @__PURE__ */ jsx32(Box27, { children: /* @__PURE__ */ jsx32(Text28, { bold: true, color: active ? PALETTE.info : PALETTE.muted, children: line.text }) });
|
|
24017
24000
|
}
|
|
24018
24001
|
if (line.kind === "label") {
|
|
24019
24002
|
return /* @__PURE__ */ jsxs28(Box27, { children: [
|
|
24020
24003
|
line.prefix && /* @__PURE__ */ jsx32(Text28, { children: line.prefix }),
|
|
24021
|
-
/* @__PURE__ */ jsx32(Text28, { bold: true, color: line.color
|
|
24022
|
-
line.suffix && /* @__PURE__ */ jsx32(Text28, {
|
|
24004
|
+
/* @__PURE__ */ jsx32(Text28, { bold: true, color: active ? line.color : PALETTE.muted, children: line.text }),
|
|
24005
|
+
line.suffix && /* @__PURE__ */ jsx32(Text28, { color: PALETTE.muted, children: line.suffix })
|
|
24023
24006
|
] });
|
|
24024
24007
|
}
|
|
24025
|
-
return /* @__PURE__ */ jsx32(Box27, { children: /* @__PURE__ */ jsx32(Text28, {
|
|
24008
|
+
return /* @__PURE__ */ jsx32(Box27, { children: /* @__PURE__ */ jsx32(Text28, { color: !active || line.dim ? PALETTE.muted : void 0, children: line.text }) });
|
|
24026
24009
|
}
|
|
24027
24010
|
var init_RationaleLine = __esm({
|
|
24028
24011
|
"packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/RationaleLine.tsx"() {
|
|
@@ -24109,9 +24092,9 @@ function ComponentRationalePanel({
|
|
|
24109
24092
|
borderStyle: "single",
|
|
24110
24093
|
borderColor: active ? PALETTE.inverse : void 0,
|
|
24111
24094
|
children: [
|
|
24112
|
-
/* @__PURE__ */ jsx33(Box28, { children: /* @__PURE__ */ jsx33(Text29, { bold: true,
|
|
24095
|
+
/* @__PURE__ */ jsx33(Box28, { children: /* @__PURE__ */ jsx33(Text29, { bold: true, color: active ? void 0 : PALETTE.muted, children: `Component rationale: ${data.name}` }) }),
|
|
24113
24096
|
visible.map((line, i) => /* @__PURE__ */ jsx33(RationaleLine, { line, active }, i)),
|
|
24114
|
-
/* @__PURE__ */ jsx33(Box28, { children: overflowed ? /* @__PURE__ */ jsx33(Text29, {
|
|
24097
|
+
/* @__PURE__ */ jsx33(Box28, { children: overflowed ? /* @__PURE__ */ jsx33(Text29, { children: `${visibleStart}-${visibleEnd}/${totalLines} [\u2191\u2193] scroll [I/Esc] close` }) : /* @__PURE__ */ jsx33(Text29, { children: "[I/Esc] close" }) })
|
|
24115
24098
|
]
|
|
24116
24099
|
}
|
|
24117
24100
|
);
|
|
@@ -24131,11 +24114,12 @@ var init_ComponentRationalePanel = __esm({
|
|
|
24131
24114
|
import { Text as Text30 } from "ink";
|
|
24132
24115
|
import { Fragment as Fragment12, jsx as jsx34 } from "react/jsx-runtime";
|
|
24133
24116
|
function HighlightedLine({ parts }) {
|
|
24134
|
-
return /* @__PURE__ */ jsx34(Fragment12, { children: parts.map((part, i) => /* @__PURE__ */ jsx34(Text30, { color: part.
|
|
24117
|
+
return /* @__PURE__ */ jsx34(Fragment12, { children: parts.map((part, i) => /* @__PURE__ */ jsx34(Text30, { color: part.dim ? PALETTE.muted : part.color, children: part.text }, i)) });
|
|
24135
24118
|
}
|
|
24136
24119
|
var init_HighlightedLine = __esm({
|
|
24137
24120
|
"packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/HighlightedLine.tsx"() {
|
|
24138
24121
|
"use strict";
|
|
24122
|
+
init_theme();
|
|
24139
24123
|
}
|
|
24140
24124
|
});
|
|
24141
24125
|
|
|
@@ -24143,7 +24127,7 @@ var init_HighlightedLine = __esm({
|
|
|
24143
24127
|
import { Box as Box29, Text as Text31 } from "ink";
|
|
24144
24128
|
import { Fragment as Fragment13, jsx as jsx35, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
24145
24129
|
function ScrollablePanel({
|
|
24146
|
-
|
|
24130
|
+
title,
|
|
24147
24131
|
width,
|
|
24148
24132
|
height,
|
|
24149
24133
|
active,
|
|
@@ -24156,10 +24140,10 @@ function ScrollablePanel({
|
|
|
24156
24140
|
const overflowed = totalLines > height;
|
|
24157
24141
|
return /* @__PURE__ */ jsxs30(Box29, { flexDirection: "column", width, height: height + 2, borderStyle: "single", borderColor, children: [
|
|
24158
24142
|
/* @__PURE__ */ jsxs30(Box29, { children: [
|
|
24159
|
-
|
|
24143
|
+
/* @__PURE__ */ jsx35(Text31, { bold: true, color: active ? void 0 : PALETTE.muted, children: title }),
|
|
24160
24144
|
overflowed && /* @__PURE__ */ jsxs30(Fragment13, { children: [
|
|
24161
24145
|
/* @__PURE__ */ jsx35(Box29, { flexGrow: 1 }),
|
|
24162
|
-
/* @__PURE__ */ jsx35(Text31, {
|
|
24146
|
+
/* @__PURE__ */ jsx35(Text31, { color: active ? void 0 : PALETTE.muted, children: `\u2195 ${visibleStart}-${visibleEnd}/${totalLines}` })
|
|
24163
24147
|
] })
|
|
24164
24148
|
] }),
|
|
24165
24149
|
children
|
|
@@ -24168,11 +24152,12 @@ function ScrollablePanel({
|
|
|
24168
24152
|
var init_ScrollablePanel = __esm({
|
|
24169
24153
|
"packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/ScrollablePanel.tsx"() {
|
|
24170
24154
|
"use strict";
|
|
24155
|
+
init_theme();
|
|
24171
24156
|
}
|
|
24172
24157
|
});
|
|
24173
24158
|
|
|
24174
24159
|
// packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/JsonPanel.tsx
|
|
24175
|
-
import { Box as Box30
|
|
24160
|
+
import { Box as Box30 } from "ink";
|
|
24176
24161
|
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
24177
24162
|
function highlightJson(line) {
|
|
24178
24163
|
const parts = [];
|
|
@@ -24227,7 +24212,7 @@ function JsonPanel({ label, value, scrollOffset, width, height, active }) {
|
|
|
24227
24212
|
return /* @__PURE__ */ jsx36(
|
|
24228
24213
|
ScrollablePanel,
|
|
24229
24214
|
{
|
|
24230
|
-
|
|
24215
|
+
title: label,
|
|
24231
24216
|
width,
|
|
24232
24217
|
height,
|
|
24233
24218
|
active,
|
|
@@ -24251,7 +24236,6 @@ var init_JsonPanel = __esm({
|
|
|
24251
24236
|
});
|
|
24252
24237
|
|
|
24253
24238
|
// packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/RationalePanel.tsx
|
|
24254
|
-
import { Text as Text33 } from "ink";
|
|
24255
24239
|
import { jsx as jsx37 } from "react/jsx-runtime";
|
|
24256
24240
|
function renderRationaleLines(rows, innerWidth) {
|
|
24257
24241
|
const out = [];
|
|
@@ -24288,7 +24272,7 @@ function RationalePanel({
|
|
|
24288
24272
|
return /* @__PURE__ */ jsx37(
|
|
24289
24273
|
ScrollablePanel,
|
|
24290
24274
|
{
|
|
24291
|
-
|
|
24275
|
+
title: `RATIONALE \u2014 ${componentName}`,
|
|
24292
24276
|
width,
|
|
24293
24277
|
height,
|
|
24294
24278
|
active,
|
|
@@ -24312,7 +24296,7 @@ var init_RationalePanel = __esm({
|
|
|
24312
24296
|
|
|
24313
24297
|
// packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/TokenReviewPanel.tsx
|
|
24314
24298
|
import figures5 from "figures";
|
|
24315
|
-
import { Box as Box31, Text as
|
|
24299
|
+
import { Box as Box31, Text as Text32 } from "ink";
|
|
24316
24300
|
import { jsx as jsx38, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
24317
24301
|
function collectTokenSuggestions(entry, availableTokens = []) {
|
|
24318
24302
|
return Object.entries(entry.$properties).filter(([, def]) => {
|
|
@@ -24356,19 +24340,19 @@ function TokenReviewPanel({
|
|
|
24356
24340
|
borderStyle: "single",
|
|
24357
24341
|
borderColor: active ? PALETTE.inverse : void 0,
|
|
24358
24342
|
children: [
|
|
24359
|
-
/* @__PURE__ */ jsx38(
|
|
24360
|
-
/* @__PURE__ */ jsx38(
|
|
24361
|
-
/* @__PURE__ */ jsx38(
|
|
24362
|
-
current.paths.length === 0 && /* @__PURE__ */ jsx38(
|
|
24343
|
+
/* @__PURE__ */ jsx38(Text32, { bold: true, color: active ? void 0 : PALETTE.muted, wrap: "truncate", children: `TOKEN REVIEW \u2014 ${componentName} \xB7 ${current.propName} (edit allowed)` }),
|
|
24344
|
+
/* @__PURE__ */ jsx38(Text32, { color: PALETTE.muted, wrap: "truncate", children: `select which tokens are allowed (${rangeLabel})` }),
|
|
24345
|
+
/* @__PURE__ */ jsx38(Text32, { children: " " }),
|
|
24346
|
+
current.paths.length === 0 && /* @__PURE__ */ jsx38(Text32, { color: PALETTE.muted, children: "(no compatible tokens found for this token kind)" }),
|
|
24363
24347
|
visiblePaths.map((path, i) => {
|
|
24364
24348
|
const pathIndex = scrollStart + i;
|
|
24365
24349
|
const checked = editSelection.has(path);
|
|
24366
24350
|
const focused = pathIndex === editCursor;
|
|
24367
|
-
return /* @__PURE__ */ jsx38(Box31, { children: /* @__PURE__ */ jsx38(
|
|
24351
|
+
return /* @__PURE__ */ jsx38(Box31, { children: /* @__PURE__ */ jsx38(Text32, { color: focused ? PALETTE.info : active ? void 0 : PALETTE.muted, bold: focused, wrap: "truncate", children: ` [${checked ? "x" : " "}] ${path}` }) }, path);
|
|
24368
24352
|
}),
|
|
24369
|
-
/* @__PURE__ */ jsx38(
|
|
24370
|
-
/* @__PURE__ */ jsx38(
|
|
24371
|
-
/* @__PURE__ */ jsx38(
|
|
24353
|
+
/* @__PURE__ */ jsx38(Text32, { children: " " }),
|
|
24354
|
+
/* @__PURE__ */ jsx38(Text32, { color: PALETTE.muted, wrap: "truncate", children: "[\u2191/\u2193] move [Space] toggle" }),
|
|
24355
|
+
/* @__PURE__ */ jsx38(Text32, { color: PALETTE.muted, wrap: "truncate", children: "[Ctrl+S] save [Esc] cancel" })
|
|
24372
24356
|
]
|
|
24373
24357
|
}
|
|
24374
24358
|
);
|
|
@@ -24382,18 +24366,18 @@ function TokenReviewPanel({
|
|
|
24382
24366
|
borderStyle: "single",
|
|
24383
24367
|
borderColor: active ? PALETTE.inverse : void 0,
|
|
24384
24368
|
children: [
|
|
24385
|
-
/* @__PURE__ */ jsx38(
|
|
24386
|
-
suggestions.length === 0 && /* @__PURE__ */ jsx38(
|
|
24369
|
+
/* @__PURE__ */ jsx38(Text32, { bold: true, color: active ? void 0 : PALETTE.muted, children: `TOKEN REVIEW \u2014 ${componentName}` }),
|
|
24370
|
+
suggestions.length === 0 && /* @__PURE__ */ jsx38(Text32, { color: PALETTE.muted, children: "(no token suggestions for this component)" }),
|
|
24387
24371
|
suggestions.map((s, i) => {
|
|
24388
24372
|
const focused = i === selectedRow;
|
|
24389
24373
|
return /* @__PURE__ */ jsxs31(Box31, { flexDirection: "column", children: [
|
|
24390
|
-
/* @__PURE__ */ jsx38(Box31, { children: /* @__PURE__ */ jsx38(
|
|
24391
|
-
/* @__PURE__ */ jsx38(
|
|
24392
|
-
/* @__PURE__ */ jsx38(
|
|
24374
|
+
/* @__PURE__ */ jsx38(Box31, { children: /* @__PURE__ */ jsx38(Text32, { color: focused ? PALETTE.info : active ? void 0 : PALETTE.muted, bold: focused, children: `${focused ? figures5.pointer : " "} ${s.propName}` }) }),
|
|
24375
|
+
/* @__PURE__ */ jsx38(Text32, { color: PALETTE.muted, children: ` suggested: ${s.suggested.join(", ")}` }),
|
|
24376
|
+
/* @__PURE__ */ jsx38(Text32, { color: PALETTE.muted, children: ` allowed: ${s.allowed.join(", ")}` })
|
|
24393
24377
|
] }, s.propName);
|
|
24394
24378
|
}),
|
|
24395
|
-
/* @__PURE__ */ jsx38(
|
|
24396
|
-
/* @__PURE__ */ jsx38(
|
|
24379
|
+
/* @__PURE__ */ jsx38(Text32, { children: " " }),
|
|
24380
|
+
/* @__PURE__ */ jsx38(Text32, { children: "[\u2191/\u2193] move [Enter] edit allowed [Esc] close" })
|
|
24397
24381
|
]
|
|
24398
24382
|
}
|
|
24399
24383
|
);
|
|
@@ -24406,7 +24390,7 @@ var init_TokenReviewPanel = __esm({
|
|
|
24406
24390
|
});
|
|
24407
24391
|
|
|
24408
24392
|
// packages/experience-design-system-cli-legacy/src/import/tui/steps/review-details-panel.tsx
|
|
24409
|
-
import { Text as
|
|
24393
|
+
import { Text as Text33 } from "ink";
|
|
24410
24394
|
import { Fragment as Fragment14, jsx as jsx39, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
24411
24395
|
function ReviewDetailsPanel({
|
|
24412
24396
|
selectedKey,
|
|
@@ -24481,9 +24465,9 @@ function ReviewDetailsPanel({
|
|
|
24481
24465
|
const sourceLineCount = Math.max(1, height - 4);
|
|
24482
24466
|
const lines = source ? source.split("\n").slice(panelScrollOffset, panelScrollOffset + sourceLineCount) : [];
|
|
24483
24467
|
return /* @__PURE__ */ jsxs32(FixedPanel, { width, height, borderStyle: "single", borderColor: sourceBorderColor, paddingLeft: 1, children: [
|
|
24484
|
-
/* @__PURE__ */ jsx39(
|
|
24485
|
-
source ? lines.map((line, index) => /* @__PURE__ */ jsx39(
|
|
24486
|
-
/* @__PURE__ */ jsx39(
|
|
24468
|
+
/* @__PURE__ */ jsx39(Text33, { color: PALETTE.muted, bold: true, wrap: "truncate-end", children: `source: ${headerPath}` }),
|
|
24469
|
+
source ? lines.map((line, index) => /* @__PURE__ */ jsx39(Text33, { color: PALETTE.muted, wrap: "truncate-end", children: line }, `source-line-${index}`)) : /* @__PURE__ */ jsx39(Text33, { color: PALETTE.muted, children: "(no source captured)" }),
|
|
24470
|
+
/* @__PURE__ */ jsx39(Text33, { color: PALETTE.muted, wrap: "truncate-end", children: "[s/Esc] close" })
|
|
24487
24471
|
] });
|
|
24488
24472
|
}
|
|
24489
24473
|
if (panelOpen === "token-review") {
|
|
@@ -24525,6 +24509,7 @@ var init_review_details_panel = __esm({
|
|
|
24525
24509
|
init_RationalePanel();
|
|
24526
24510
|
init_TokenReviewPanel();
|
|
24527
24511
|
init_windowed_panel();
|
|
24512
|
+
init_theme();
|
|
24528
24513
|
}
|
|
24529
24514
|
});
|
|
24530
24515
|
|
|
@@ -24610,7 +24595,7 @@ var init_ReviewDetailsEditor = __esm({
|
|
|
24610
24595
|
});
|
|
24611
24596
|
|
|
24612
24597
|
// packages/experience-design-system-cli-legacy/src/import/tui/components/ReviewComponentPanel.tsx
|
|
24613
|
-
import { Box as Box32, Text as
|
|
24598
|
+
import { Box as Box32, Text as Text34 } from "ink";
|
|
24614
24599
|
import { Fragment as Fragment15, jsx as jsx41, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
24615
24600
|
function buildReviewFieldEditor(reviewEditor, selectedJson, onExit, overrides = {}) {
|
|
24616
24601
|
return {
|
|
@@ -24651,17 +24636,17 @@ function ReviewEmptyComponentsWarning({
|
|
|
24651
24636
|
hidden
|
|
24652
24637
|
}) {
|
|
24653
24638
|
if (hidden || count === 0) return null;
|
|
24654
|
-
return /* @__PURE__ */ jsx41(
|
|
24639
|
+
return /* @__PURE__ */ jsx41(Text34, { color: PALETTE.warning, children: `\u26A0 ${count} component${count === 1 ? "" : "s"} had no classifiable props \u2014 review with care` });
|
|
24655
24640
|
}
|
|
24656
24641
|
function ReviewNoSelection() {
|
|
24657
|
-
return /* @__PURE__ */ jsx41(Box32, { flexGrow: 1, paddingLeft: 1, flexDirection: "column", children: /* @__PURE__ */ jsx41(
|
|
24642
|
+
return /* @__PURE__ */ jsx41(Box32, { flexGrow: 1, paddingLeft: 1, flexDirection: "column", children: /* @__PURE__ */ jsx41(Text34, { color: PALETTE.muted, children: "No component selected" }) });
|
|
24658
24643
|
}
|
|
24659
24644
|
function ReviewFinalizeError({
|
|
24660
24645
|
message,
|
|
24661
24646
|
hidden
|
|
24662
24647
|
}) {
|
|
24663
24648
|
if (hidden || !message) return null;
|
|
24664
|
-
return /* @__PURE__ */ jsx41(
|
|
24649
|
+
return /* @__PURE__ */ jsx41(Text34, { color: PALETTE.error, children: `\u26A0 ${message}` });
|
|
24665
24650
|
}
|
|
24666
24651
|
function ReviewPanelFooter({
|
|
24667
24652
|
reviewEditor,
|
|
@@ -24672,8 +24657,8 @@ function ReviewPanelFooter({
|
|
|
24672
24657
|
}) {
|
|
24673
24658
|
return /* @__PURE__ */ jsxs33(Fragment15, { children: [
|
|
24674
24659
|
reviewEditor.panelOpen === "token-review" ? " [\u2191/\u2193] move [Enter] edit allowed [Esc] close" : sidebarFocused ? sidebarFooter : reviewEditor.showJson ? " [\u2191\u2193] scroll [Ctrl+u/d] half-page [gg/G] top/bottom [Tab] focus list" : " [Tab] focus list (edit fields)" + (reviewEditor.currentTokenSuggestions().length > 0 ? " [t] token review" : ""),
|
|
24675
|
-
livePreview.status === "running" && /* @__PURE__ */ jsx41(
|
|
24676
|
-
livePreview.disabled && /* @__PURE__ */ jsx41(
|
|
24660
|
+
livePreview.status === "running" && /* @__PURE__ */ jsx41(Text34, { children: ` ${livePreviewSpinner} live preview` }),
|
|
24661
|
+
livePreview.disabled && /* @__PURE__ */ jsx41(Text34, { children: " \xB7 live preview disabled" })
|
|
24677
24662
|
] });
|
|
24678
24663
|
}
|
|
24679
24664
|
function ReviewComponentTitle({
|
|
@@ -24683,9 +24668,9 @@ function ReviewComponentTitle({
|
|
|
24683
24668
|
sidebarFocused
|
|
24684
24669
|
}) {
|
|
24685
24670
|
return /* @__PURE__ */ jsxs33(Box32, { paddingLeft: 2, paddingBottom: 1, children: [
|
|
24686
|
-
/* @__PURE__ */ jsx41(
|
|
24671
|
+
/* @__PURE__ */ jsx41(Text34, { bold: true, wrap: "truncate-end", children: selectedKey }),
|
|
24687
24672
|
/* @__PURE__ */ jsx41(Box32, { flexGrow: 1 }),
|
|
24688
|
-
/* @__PURE__ */ jsxs33(
|
|
24673
|
+
/* @__PURE__ */ jsxs33(Text34, { color: PALETTE.muted, wrap: "truncate-end", children: [
|
|
24689
24674
|
propCount,
|
|
24690
24675
|
" prop",
|
|
24691
24676
|
propCount !== 1 ? "s" : "",
|
|
@@ -24741,8 +24726,8 @@ function ReviewComponentPanel({
|
|
|
24741
24726
|
)
|
|
24742
24727
|
}
|
|
24743
24728
|
) }),
|
|
24744
|
-
/* @__PURE__ */ jsx41(Box32, { width: contentWidth, height: 1, flexShrink: 0, children: /* @__PURE__ */ jsx41(
|
|
24745
|
-
/* @__PURE__ */ jsx41(Box32, { width: contentWidth, height: 1, flexShrink: 0, children: /* @__PURE__ */ jsx41(
|
|
24729
|
+
/* @__PURE__ */ jsx41(Box32, { width: contentWidth, height: 1, flexShrink: 0, children: /* @__PURE__ */ jsx41(Text34, { color: saveError ? PALETTE.error : void 0, wrap: "truncate-end", children: saveError ? "\u2717 " + saveError : " " }) }),
|
|
24730
|
+
/* @__PURE__ */ jsx41(Box32, { width: contentWidth, height: 1, flexShrink: 0, children: /* @__PURE__ */ jsx41(Text34, { color: PALETTE.muted, wrap: "truncate-end", children: /* @__PURE__ */ jsx41(
|
|
24746
24731
|
ReviewPanelFooter,
|
|
24747
24732
|
{
|
|
24748
24733
|
reviewEditor,
|
|
@@ -24765,7 +24750,7 @@ var init_ReviewComponentPanel = __esm({
|
|
|
24765
24750
|
});
|
|
24766
24751
|
|
|
24767
24752
|
// packages/experience-design-system-cli-legacy/src/import/tui/components/ReviewStatus.tsx
|
|
24768
|
-
import { Box as Box33, Text as
|
|
24753
|
+
import { Box as Box33, Text as Text35 } from "ink";
|
|
24769
24754
|
import { jsx as jsx42, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
24770
24755
|
function countReviewStatuses(entries) {
|
|
24771
24756
|
return entries.reduce(
|
|
@@ -24779,13 +24764,13 @@ function countReviewStatuses(entries) {
|
|
|
24779
24764
|
);
|
|
24780
24765
|
}
|
|
24781
24766
|
function ReviewLoadingState() {
|
|
24782
|
-
return /* @__PURE__ */ jsx42(Box33, { paddingX: 2, paddingY: 1, children: /* @__PURE__ */ jsx42(
|
|
24767
|
+
return /* @__PURE__ */ jsx42(Box33, { paddingX: 2, paddingY: 1, children: /* @__PURE__ */ jsx42(Text35, { color: PALETTE.muted, children: "Loading generated definitions..." }) });
|
|
24783
24768
|
}
|
|
24784
24769
|
function ReviewLoadError({ message }) {
|
|
24785
24770
|
return /* @__PURE__ */ jsxs34(Box33, { flexDirection: "column", paddingX: 2, paddingY: 1, children: [
|
|
24786
|
-
/* @__PURE__ */ jsx42(
|
|
24787
|
-
/* @__PURE__ */ jsx42(
|
|
24788
|
-
/* @__PURE__ */ jsx42(
|
|
24771
|
+
/* @__PURE__ */ jsx42(Text35, { color: PALETTE.error, children: message }),
|
|
24772
|
+
/* @__PURE__ */ jsx42(Text35, { children: " " }),
|
|
24773
|
+
/* @__PURE__ */ jsx42(Text35, { children: "[q / Enter / Esc] Quit" })
|
|
24789
24774
|
] });
|
|
24790
24775
|
}
|
|
24791
24776
|
var init_ReviewStatus = __esm({
|
|
@@ -24919,7 +24904,7 @@ var init_runLivePreview = __esm({
|
|
|
24919
24904
|
});
|
|
24920
24905
|
|
|
24921
24906
|
// packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/FinalizeDialog.tsx
|
|
24922
|
-
import { Box as Box34, Text as
|
|
24907
|
+
import { Box as Box34, Text as Text36 } from "ink";
|
|
24923
24908
|
import { Fragment as Fragment16, jsx as jsx43, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
24924
24909
|
function FinalizeDialog({
|
|
24925
24910
|
accepted,
|
|
@@ -24949,50 +24934,50 @@ function FinalizeDialog({
|
|
|
24949
24934
|
const hasMoreBelow = offset + FINALIZE_REMOVED_WINDOW < removed.length;
|
|
24950
24935
|
const hasMoreAbove = offset > 0;
|
|
24951
24936
|
return /* @__PURE__ */ jsx43(Box34, { width: "100%", justifyContent: "center", children: /* @__PURE__ */ jsxs35(Box34, { flexDirection: "column", alignItems: "center", borderStyle: "round", padding: 1, width: 58, children: [
|
|
24952
|
-
/* @__PURE__ */ jsx43(
|
|
24953
|
-
/* @__PURE__ */ jsx43(
|
|
24954
|
-
/* @__PURE__ */ jsxs35(
|
|
24955
|
-
/* @__PURE__ */ jsxs35(
|
|
24937
|
+
/* @__PURE__ */ jsx43(Text36, { bold: true, children: "\u2500".repeat(22) + " Finalize " + "\u2500".repeat(22) }),
|
|
24938
|
+
/* @__PURE__ */ jsx43(Text36, { children: " " }),
|
|
24939
|
+
/* @__PURE__ */ jsxs35(Text36, { children: [
|
|
24940
|
+
/* @__PURE__ */ jsxs35(Text36, { color: PALETTE.success, children: [
|
|
24956
24941
|
accepted,
|
|
24957
24942
|
" accepted"
|
|
24958
24943
|
] }),
|
|
24959
|
-
/* @__PURE__ */ jsx43(
|
|
24960
|
-
/* @__PURE__ */ jsxs35(
|
|
24944
|
+
/* @__PURE__ */ jsx43(Text36, { children: " \xB7 " }),
|
|
24945
|
+
/* @__PURE__ */ jsxs35(Text36, { color: PALETTE.error, children: [
|
|
24961
24946
|
rejected,
|
|
24962
24947
|
" rejected"
|
|
24963
24948
|
] }),
|
|
24964
|
-
/* @__PURE__ */ jsx43(
|
|
24965
|
-
/* @__PURE__ */ jsxs35(
|
|
24949
|
+
/* @__PURE__ */ jsx43(Text36, { children: " \xB7 " }),
|
|
24950
|
+
/* @__PURE__ */ jsxs35(Text36, { color: PALETTE.muted, children: [
|
|
24966
24951
|
needsReview,
|
|
24967
24952
|
" unresolved"
|
|
24968
24953
|
] })
|
|
24969
24954
|
] }),
|
|
24970
|
-
/* @__PURE__ */ jsx43(
|
|
24955
|
+
/* @__PURE__ */ jsx43(Text36, { children: " " }),
|
|
24971
24956
|
noneAccepted && /* @__PURE__ */ jsxs35(Fragment16, { children: [
|
|
24972
|
-
/* @__PURE__ */ jsx43(
|
|
24973
|
-
/* @__PURE__ */ jsx43(
|
|
24974
|
-
/* @__PURE__ */ jsx43(
|
|
24957
|
+
/* @__PURE__ */ jsx43(Text36, { bold: true, color: PALETTE.warning, children: "\u26A0 No components are accepted \u2014 nothing will be pushed." }),
|
|
24958
|
+
/* @__PURE__ */ jsx43(Text36, { color: PALETTE.warning, children: "Accept at least one component ([a] a row, [A] accept all) to push." }),
|
|
24959
|
+
/* @__PURE__ */ jsx43(Text36, { children: " " })
|
|
24975
24960
|
] }),
|
|
24976
24961
|
!allResolved && /* @__PURE__ */ jsxs35(Fragment16, { children: [
|
|
24977
|
-
/* @__PURE__ */ jsx43(
|
|
24978
|
-
/* @__PURE__ */ jsx43(
|
|
24979
|
-
/* @__PURE__ */ jsx43(
|
|
24962
|
+
/* @__PURE__ */ jsx43(Text36, { color: PALETTE.warning, children: "\u26A0 " + needsReview + " unresolved component" + (needsReview === 1 ? "" : "s") + " will not be pushed." }),
|
|
24963
|
+
/* @__PURE__ */ jsx43(Text36, { color: PALETTE.warning, children: "Only explicitly accepted components ship." }),
|
|
24964
|
+
/* @__PURE__ */ jsx43(Text36, { children: " " })
|
|
24980
24965
|
] }),
|
|
24981
24966
|
/* @__PURE__ */ jsxs35(Box34, { flexDirection: "column", height: 2, children: [
|
|
24982
|
-
previewStatus === "running" ? /* @__PURE__ */ jsx43(
|
|
24983
|
-
/* @__PURE__ */ jsx43(
|
|
24967
|
+
previewStatus === "running" ? /* @__PURE__ */ jsx43(Text36, { color: PALETTE.muted, children: "Previewing deletions against the target space\u2026" }) : previewStatus === "error" ? /* @__PURE__ */ jsx43(Text36, { color: PALETTE.warning, children: "\u26A0 Could not preview deletions (the push will still proceed)." }) : /* @__PURE__ */ jsx43(Text36, { children: " " }),
|
|
24968
|
+
/* @__PURE__ */ jsx43(Text36, { children: " " })
|
|
24984
24969
|
] }),
|
|
24985
24970
|
previewStatus === "done" && removed.length > 0 && /* @__PURE__ */ jsxs35(Fragment16, { children: [
|
|
24986
|
-
/* @__PURE__ */ jsx43(
|
|
24987
|
-
hasMoreAbove && /* @__PURE__ */ jsx43(
|
|
24988
|
-
windowed.map((rc) => /* @__PURE__ */ jsx43(
|
|
24989
|
-
hasMoreBelow && /* @__PURE__ */ jsx43(
|
|
24990
|
-
removed.length > FINALIZE_REMOVED_WINDOW && /* @__PURE__ */ jsx43(
|
|
24991
|
-
/* @__PURE__ */ jsx43(
|
|
24971
|
+
/* @__PURE__ */ jsx43(Text36, { bold: true, color: PALETTE.error, children: removedComponentsHeader(removed.length, false) }),
|
|
24972
|
+
hasMoreAbove && /* @__PURE__ */ jsx43(Text36, { color: PALETTE.muted, children: "\u2191 more above" }),
|
|
24973
|
+
windowed.map((rc) => /* @__PURE__ */ jsx43(Text36, { color: PALETTE.error, children: removedComponentLine(rc) }, rc.id)),
|
|
24974
|
+
hasMoreBelow && /* @__PURE__ */ jsx43(Text36, { color: PALETTE.muted, children: "\u2193 more below" }),
|
|
24975
|
+
removed.length > FINALIZE_REMOVED_WINDOW && /* @__PURE__ */ jsx43(Text36, { children: "[\u2191\u2193] scroll deletions" }),
|
|
24976
|
+
/* @__PURE__ */ jsx43(Text36, { children: " " })
|
|
24992
24977
|
] }),
|
|
24993
|
-
/* @__PURE__ */ jsx43(
|
|
24994
|
-
/* @__PURE__ */ jsx43(
|
|
24995
|
-
/* @__PURE__ */ jsx43(
|
|
24978
|
+
/* @__PURE__ */ jsx43(Text36, { children: noneAccepted ? "Confirm exit with nothing accepted?" : allResolved ? "Save decisions and exit? All components resolved." : "Save decisions and exit?" }),
|
|
24979
|
+
/* @__PURE__ */ jsx43(Text36, { children: " " }),
|
|
24980
|
+
/* @__PURE__ */ jsx43(Text36, { children: "[y / Enter] Confirm [n / Esc] Cancel" })
|
|
24996
24981
|
] }) });
|
|
24997
24982
|
}
|
|
24998
24983
|
var FINALIZE_REMOVED_WINDOW;
|
|
@@ -25498,7 +25483,7 @@ var init_useReviewSurfaceState = __esm({
|
|
|
25498
25483
|
});
|
|
25499
25484
|
|
|
25500
25485
|
// packages/experience-design-system-cli-legacy/src/analyze/select/tui/components/QuitDialog.tsx
|
|
25501
|
-
import { Box as Box35, Text as
|
|
25486
|
+
import { Box as Box35, Text as Text37 } from "ink";
|
|
25502
25487
|
import { Fragment as Fragment17, jsx as jsx44, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
25503
25488
|
function QuitDialog({ hasUnsavedDrafts, onConfirm, onCancel }) {
|
|
25504
25489
|
useImmediateInput((input, key) => {
|
|
@@ -25509,15 +25494,15 @@ function QuitDialog({ hasUnsavedDrafts, onConfirm, onCancel }) {
|
|
|
25509
25494
|
}
|
|
25510
25495
|
});
|
|
25511
25496
|
return /* @__PURE__ */ jsxs36(Box35, { flexDirection: "column", borderStyle: "round", padding: 1, width: 50, children: [
|
|
25512
|
-
/* @__PURE__ */ jsx44(
|
|
25513
|
-
/* @__PURE__ */ jsx44(
|
|
25497
|
+
/* @__PURE__ */ jsx44(Text37, { bold: true, children: "\u2500".repeat(19) + " Quit " + "\u2500".repeat(19) }),
|
|
25498
|
+
/* @__PURE__ */ jsx44(Text37, { children: " " }),
|
|
25514
25499
|
hasUnsavedDrafts ? /* @__PURE__ */ jsxs36(Fragment17, { children: [
|
|
25515
|
-
/* @__PURE__ */ jsx44(
|
|
25516
|
-
/* @__PURE__ */ jsx44(
|
|
25517
|
-
/* @__PURE__ */ jsx44(
|
|
25518
|
-
] }) : /* @__PURE__ */ jsx44(
|
|
25519
|
-
/* @__PURE__ */ jsx44(
|
|
25520
|
-
/* @__PURE__ */ jsx44(
|
|
25500
|
+
/* @__PURE__ */ jsx44(Text37, { children: "You have unsaved draft edits." }),
|
|
25501
|
+
/* @__PURE__ */ jsx44(Text37, { children: "Session state is preserved \u2014 you can resume" }),
|
|
25502
|
+
/* @__PURE__ */ jsx44(Text37, { children: "by running the same review command again." })
|
|
25503
|
+
] }) : /* @__PURE__ */ jsx44(Text37, { children: "Session is saved. Quit without finalizing?" }),
|
|
25504
|
+
/* @__PURE__ */ jsx44(Text37, { children: " " }),
|
|
25505
|
+
/* @__PURE__ */ jsx44(Text37, { children: " [y / Enter] Quit [n / Esc] Stay" })
|
|
25521
25506
|
] });
|
|
25522
25507
|
}
|
|
25523
25508
|
var init_QuitDialog = __esm({
|
|
@@ -25528,7 +25513,7 @@ var init_QuitDialog = __esm({
|
|
|
25528
25513
|
});
|
|
25529
25514
|
|
|
25530
25515
|
// packages/experience-design-system-cli-legacy/src/import/tui/components/ReviewDialogs.tsx
|
|
25531
|
-
import { Box as Box36, Text as
|
|
25516
|
+
import { Box as Box36, Text as Text38 } from "ink";
|
|
25532
25517
|
import { Fragment as Fragment18, jsx as jsx45, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
25533
25518
|
function ReviewFinalizeDialogs({
|
|
25534
25519
|
showFinalize,
|
|
@@ -25586,11 +25571,11 @@ function ReviewStepDialogs({
|
|
|
25586
25571
|
function ReviewReloadDialog({ open }) {
|
|
25587
25572
|
if (!open) return null;
|
|
25588
25573
|
return /* @__PURE__ */ jsxs37(Box36, { flexDirection: "column", borderStyle: "round", borderColor: PALETTE.warning, paddingX: 1, children: [
|
|
25589
|
-
/* @__PURE__ */ jsx45(
|
|
25590
|
-
/* @__PURE__ */ jsx45(
|
|
25591
|
-
/* @__PURE__ */ jsx45(
|
|
25592
|
-
/* @__PURE__ */ jsx45(
|
|
25593
|
-
/* @__PURE__ */ jsx45(
|
|
25574
|
+
/* @__PURE__ */ jsx45(Text38, { bold: true, color: PALETTE.warning, children: "Reload from saved state?" }),
|
|
25575
|
+
/* @__PURE__ */ jsx45(Text38, { children: "Unsaved in-memory changes will be lost." }),
|
|
25576
|
+
/* @__PURE__ */ jsx45(Text38, { children: " " }),
|
|
25577
|
+
/* @__PURE__ */ jsx45(Text38, { children: " [Enter] Confirm" }),
|
|
25578
|
+
/* @__PURE__ */ jsx45(Text38, { children: " [Esc] Cancel" })
|
|
25594
25579
|
] });
|
|
25595
25580
|
}
|
|
25596
25581
|
var init_ReviewDialogs = __esm({
|
|
@@ -25992,7 +25977,7 @@ var init_useReviewPreview = __esm({
|
|
|
25992
25977
|
});
|
|
25993
25978
|
|
|
25994
25979
|
// packages/experience-design-system-cli-legacy/src/import/tui/components/LivePreviewSummary.tsx
|
|
25995
|
-
import { Box as Box37, Text as
|
|
25980
|
+
import { Box as Box37, Text as Text39 } from "ink";
|
|
25996
25981
|
import { jsx as jsx46, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
25997
25982
|
function LivePreviewSummary({
|
|
25998
25983
|
enabled,
|
|
@@ -26007,19 +25992,19 @@ function LivePreviewSummary({
|
|
|
26007
25992
|
const counts = { new: 0, changed: 0, removed: 0, breaking: 0 };
|
|
26008
25993
|
for (const annotation of previewAnnotations.values()) counts[annotation] += 1;
|
|
26009
25994
|
const hasCounts = counts.new + counts.changed + counts.removed + counts.breaking > 0;
|
|
26010
|
-
if (disabled) return /* @__PURE__ */ jsx46(
|
|
26011
|
-
if (status === "running" && !hasCounts) return /* @__PURE__ */ jsx46(
|
|
25995
|
+
if (disabled) return /* @__PURE__ */ jsx46(Text39, { color: PALETTE.muted, children: "Preview: disabled (creds rejected)" });
|
|
25996
|
+
if (status === "running" && !hasCounts) return /* @__PURE__ */ jsx46(Text39, { color: PALETTE.muted, children: `Preview: ${spinner} running...` });
|
|
26012
25997
|
if (!hasCounts) return null;
|
|
26013
25998
|
return /* @__PURE__ */ jsxs38(Box37, { children: [
|
|
26014
|
-
/* @__PURE__ */ jsx46(
|
|
26015
|
-
/* @__PURE__ */ jsx46(
|
|
26016
|
-
/* @__PURE__ */ jsx46(
|
|
26017
|
-
/* @__PURE__ */ jsx46(
|
|
26018
|
-
/* @__PURE__ */ jsx46(
|
|
26019
|
-
/* @__PURE__ */ jsx46(
|
|
26020
|
-
showRemovedListHint && removedCount > 0 && /* @__PURE__ */ jsx46(
|
|
26021
|
-
/* @__PURE__ */ jsx46(
|
|
26022
|
-
/* @__PURE__ */ jsx46(
|
|
25999
|
+
/* @__PURE__ */ jsx46(Text39, { children: "Preview: " }),
|
|
26000
|
+
/* @__PURE__ */ jsx46(Text39, { color: PALETTE.success, children: `${counts.new} new` }),
|
|
26001
|
+
/* @__PURE__ */ jsx46(Text39, { children: " \xB7 " }),
|
|
26002
|
+
/* @__PURE__ */ jsx46(Text39, { color: PALETTE.warning, children: `${counts.changed} changed` }),
|
|
26003
|
+
/* @__PURE__ */ jsx46(Text39, { children: " \xB7 " }),
|
|
26004
|
+
/* @__PURE__ */ jsx46(Text39, { color: PALETTE.muted, children: `${counts.removed} removed` }),
|
|
26005
|
+
showRemovedListHint && removedCount > 0 && /* @__PURE__ */ jsx46(Text39, { children: " ([d] removed list)" }),
|
|
26006
|
+
/* @__PURE__ */ jsx46(Text39, { children: " \xB7 " }),
|
|
26007
|
+
/* @__PURE__ */ jsx46(Text39, { color: PALETTE.error, bold: true, children: `${counts.breaking} breaking` })
|
|
26023
26008
|
] });
|
|
26024
26009
|
}
|
|
26025
26010
|
var init_LivePreviewSummary = __esm({
|
|
@@ -26032,7 +26017,7 @@ var init_LivePreviewSummary = __esm({
|
|
|
26032
26017
|
// packages/experience-design-system-cli-legacy/src/import/tui/steps/GenerateReviewStep.tsx
|
|
26033
26018
|
import { useCallback as useCallback7, useEffect as useEffect13, useMemo as useMemo3, useRef as useRef9, useState as useState19 } from "react";
|
|
26034
26019
|
import figures6 from "figures";
|
|
26035
|
-
import { Box as Box38, Text as
|
|
26020
|
+
import { Box as Box38, Text as Text40 } from "ink";
|
|
26036
26021
|
import { Fragment as Fragment19, jsx as jsx47, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
26037
26022
|
function sortComponentsForSidebar(components, cycleParticipants) {
|
|
26038
26023
|
const isEmpty2 = (entry) => Object.keys(entry.$properties ?? {}).length === 0 && Object.keys(entry.$slots ?? {}).length === 0;
|
|
@@ -26074,10 +26059,10 @@ function CyclePathLine({
|
|
|
26074
26059
|
highlightComponents = false,
|
|
26075
26060
|
highlightLine = false
|
|
26076
26061
|
}) {
|
|
26077
|
-
return /* @__PURE__ */ jsxs39(
|
|
26062
|
+
return /* @__PURE__ */ jsxs39(Text40, { color: highlightLine ? PALETTE.warning : void 0, children: [
|
|
26078
26063
|
prefix,
|
|
26079
26064
|
segments.map(
|
|
26080
|
-
(segment, index) => segment.kind === "slot" ? /* @__PURE__ */ jsx47(
|
|
26065
|
+
(segment, index) => segment.kind === "slot" ? /* @__PURE__ */ jsx47(Text40, { color: PALETTE.info, children: segment.text }, index) : segment.kind === "arrow" ? /* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: segment.text }, index) : /* @__PURE__ */ jsx47(Text40, { color: highlightComponents ? PALETTE.warning : void 0, children: segment.text }, index)
|
|
26081
26066
|
)
|
|
26082
26067
|
] });
|
|
26083
26068
|
}
|
|
@@ -26089,31 +26074,31 @@ function CycleDetailPanel({
|
|
|
26089
26074
|
height
|
|
26090
26075
|
}) {
|
|
26091
26076
|
const lines = [
|
|
26092
|
-
/* @__PURE__ */ jsx47(
|
|
26093
|
-
/* @__PURE__ */ jsx47(
|
|
26094
|
-
/* @__PURE__ */ jsx47(
|
|
26095
|
-
/* @__PURE__ */ jsx47(
|
|
26077
|
+
/* @__PURE__ */ jsx47(Text40, { bold: true, color: PALETTE.warning, children: `SLOT DEPENDENCY CYCLES (${cycles.length})` }, "cyc-title"),
|
|
26078
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: "push will fail until these are resolved" }, "cyc-sub"),
|
|
26079
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: "Reject a cycle member or remove a slot edge to break the cycle." }, "cyc-guidance"),
|
|
26080
|
+
/* @__PURE__ */ jsx47(Text40, { children: " " }, "cyc-space")
|
|
26096
26081
|
];
|
|
26097
26082
|
cycles.forEach((cycle, index) => {
|
|
26098
26083
|
const nodeCount = new Set(cycle.path).size;
|
|
26099
26084
|
const isCursor = index === cursor;
|
|
26100
26085
|
lines.push(
|
|
26101
|
-
/* @__PURE__ */ jsx47(
|
|
26086
|
+
/* @__PURE__ */ jsx47(Text40, { bold: true, inverse: isCursor, children: `${isCursor ? figures6.pointer : " "} Cycle ${index + 1} (${nodeCount} component${nodeCount === 1 ? "" : "s"}):` }, `cyc-h-${index}`),
|
|
26102
26087
|
/* @__PURE__ */ jsx47(CyclePathLine, { segments: formatCyclePathSegments(cycle, 16), prefix: " " }, `cyc-p-${index}`)
|
|
26103
26088
|
);
|
|
26104
26089
|
if (cycle.suggestedBreak) {
|
|
26105
26090
|
lines.push(
|
|
26106
|
-
/* @__PURE__ */ jsx47(
|
|
26091
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: ` Suggested fix: remove [${cycle.suggestedBreak.slotName}] from ${cycle.suggestedBreak.fromComponent}` }, `cyc-fix-${index}`)
|
|
26107
26092
|
);
|
|
26108
26093
|
}
|
|
26109
|
-
lines.push(/* @__PURE__ */ jsx47(
|
|
26094
|
+
lines.push(/* @__PURE__ */ jsx47(Text40, { children: " " }, `cyc-s-${index}`));
|
|
26110
26095
|
});
|
|
26111
26096
|
const footer = "[\u2191\u2193] move [Enter] fix cycle [c/q/Esc] close";
|
|
26112
26097
|
const viewportHeight = Math.max(1, height - 3);
|
|
26113
26098
|
const visible = lines.slice(scrollOffset, scrollOffset + viewportHeight - 1);
|
|
26114
26099
|
return /* @__PURE__ */ jsxs39(FixedPanel, { width, height, borderStyle: "round", borderColor: PALETTE.warning, paddingLeft: 1, children: [
|
|
26115
26100
|
visible,
|
|
26116
|
-
/* @__PURE__ */ jsx47(
|
|
26101
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: footer })
|
|
26117
26102
|
] });
|
|
26118
26103
|
}
|
|
26119
26104
|
function BreakCyclePanel({
|
|
@@ -26125,13 +26110,13 @@ function BreakCyclePanel({
|
|
|
26125
26110
|
height
|
|
26126
26111
|
}) {
|
|
26127
26112
|
return /* @__PURE__ */ jsxs39(FixedPanel, { width, height, borderStyle: "round", borderColor: PALETTE.warning, paddingLeft: 1, children: [
|
|
26128
|
-
/* @__PURE__ */ jsx47(
|
|
26113
|
+
/* @__PURE__ */ jsx47(Text40, { bold: true, color: PALETTE.warning, children: "BREAK CYCLE \u2014 remove a slot edge" }),
|
|
26129
26114
|
cycle && /* @__PURE__ */ jsx47(CyclePathLine, { segments: formatCyclePathSegments(cycle), prefix: " ", highlightComponents: true }),
|
|
26130
|
-
/* @__PURE__ */ jsx47(
|
|
26131
|
-
/* @__PURE__ */ jsx47(
|
|
26132
|
-
edges.length > 0 && /* @__PURE__ */ jsx47(
|
|
26133
|
-
edges.map((edge, index) => /* @__PURE__ */ jsx47(
|
|
26134
|
-
confirming ? /* @__PURE__ */ jsx47(
|
|
26115
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: cycle ? "Deleting an edge removes it from $allowedComponents (undo with Ctrl+Z)." : "No cycle highlighted." }),
|
|
26116
|
+
/* @__PURE__ */ jsx47(Text40, { children: " " }),
|
|
26117
|
+
edges.length > 0 && /* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: "remove slot edge:" }),
|
|
26118
|
+
edges.map((edge, index) => /* @__PURE__ */ jsx47(Text40, { inverse: index === cursor, children: `${index === cursor ? figures6.pointer : " "} remove '${edge.toComponent}' from ${edge.fromComponent}.$slots.${edge.slotName}.$allowedComponents` }, `${edge.fromComponent}-${edge.slotName}-${edge.toComponent}`)),
|
|
26119
|
+
confirming ? /* @__PURE__ */ jsx47(Text40, { bold: true, color: PALETTE.warning, children: "Delete this slot edge? [y] confirm [n] cancel" }) : /* @__PURE__ */ jsx47(Text40, { children: "[\u2191\u2193] move [Enter] delete [x/Esc] close" })
|
|
26135
26120
|
] });
|
|
26136
26121
|
}
|
|
26137
26122
|
function buildBreakingRows(breakingChanges) {
|
|
@@ -26177,7 +26162,7 @@ function deriveBreakingChanges(response) {
|
|
|
26177
26162
|
}
|
|
26178
26163
|
function GenerateReviewStep(props) {
|
|
26179
26164
|
if (!props.extractSessionId) {
|
|
26180
|
-
return /* @__PURE__ */ jsx47(Box38, { paddingX: 2, paddingY: 1, children: /* @__PURE__ */ jsx47(
|
|
26165
|
+
return /* @__PURE__ */ jsx47(Box38, { paddingX: 2, paddingY: 1, children: /* @__PURE__ */ jsx47(Text40, { color: PALETTE.error, children: "Error: no session ID \u2014 cannot load generated definitions." }) });
|
|
26181
26166
|
}
|
|
26182
26167
|
return /* @__PURE__ */ jsx47(GenerateReviewStepView, { ...props, extractSessionId: props.extractSessionId });
|
|
26183
26168
|
}
|
|
@@ -27095,14 +27080,14 @@ function GenerateReviewStepView({
|
|
|
27095
27080
|
),
|
|
27096
27081
|
/* @__PURE__ */ jsx47(ReviewReloadDialog, { open: showReloadDialog && !dialogOpen }),
|
|
27097
27082
|
removedComponents.length > 0 && !dialogOpen && /* @__PURE__ */ jsxs39(Box38, { flexDirection: "column", borderStyle: "round", borderColor: PALETTE.error, paddingX: 1, children: [
|
|
27098
|
-
/* @__PURE__ */ jsx47(
|
|
27083
|
+
/* @__PURE__ */ jsx47(Text40, { bold: true, color: PALETTE.error, children: removedComponentsHeader(removedComponents.length, true) }),
|
|
27099
27084
|
!removedBannerCollapsed && /* @__PURE__ */ jsxs39(Fragment19, { children: [
|
|
27100
|
-
/* @__PURE__ */ jsx47(
|
|
27101
|
-
removedComponents.map((rc) => /* @__PURE__ */ jsx47(
|
|
27085
|
+
/* @__PURE__ */ jsx47(Text40, { children: " " }),
|
|
27086
|
+
removedComponents.map((rc) => /* @__PURE__ */ jsx47(Text40, { children: removedComponentLine(rc) }, rc.id))
|
|
27102
27087
|
] })
|
|
27103
27088
|
] }),
|
|
27104
27089
|
breakingChanges.length > 0 && !dialogOpen && /* @__PURE__ */ jsx47(Box38, { paddingX: 1, children: /* @__PURE__ */ jsx47(
|
|
27105
|
-
|
|
27090
|
+
Text40,
|
|
27106
27091
|
{
|
|
27107
27092
|
color: PALETTE.warning,
|
|
27108
27093
|
children: `[b] ${breakingChanges.length} breaking change${breakingChanges.length === 1 ? "" : "s"}`
|
|
@@ -27113,10 +27098,10 @@ function GenerateReviewStepView({
|
|
|
27113
27098
|
const comp = row ? breakingChanges.find((b) => b.componentName === row.componentName) : void 0;
|
|
27114
27099
|
if (!comp) return null;
|
|
27115
27100
|
return /* @__PURE__ */ jsxs39(Box38, { flexDirection: "column", borderStyle: "round", borderColor: PALETTE.warning, paddingX: 1, children: [
|
|
27116
|
-
/* @__PURE__ */ jsx47(
|
|
27117
|
-
comp.impact && /* @__PURE__ */ jsx47(
|
|
27118
|
-
comp.changes.length === 0 ? /* @__PURE__ */ jsx47(
|
|
27119
|
-
/* @__PURE__ */ jsx47(
|
|
27101
|
+
/* @__PURE__ */ jsx47(Text40, { bold: true, color: PALETTE.warning, children: `Breaking changes \u2014 ${comp.componentName}` }),
|
|
27102
|
+
comp.impact && /* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: ` affects ${comp.impact.affectedExperiences} experience${comp.impact.affectedExperiences === 1 ? "" : "s"}, ${comp.impact.affectedFragments} fragment${comp.impact.affectedFragments === 1 ? "" : "s"}` }),
|
|
27103
|
+
comp.changes.length === 0 ? /* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: " (no enumerated changes)" }) : comp.changes.map((change, ci) => /* @__PURE__ */ jsx47(Text40, { children: ` \u2022 ${formatBreakingChange(change, comp.current)}` }, `bd-detail-${ci}`)),
|
|
27104
|
+
/* @__PURE__ */ jsx47(Text40, { children: "[D/Esc] close detail" })
|
|
27120
27105
|
] });
|
|
27121
27106
|
})(),
|
|
27122
27107
|
!dialogOpen && /* @__PURE__ */ jsx47(
|
|
@@ -27139,10 +27124,10 @@ function GenerateReviewStepView({
|
|
|
27139
27124
|
const members = stillRejected.filter((n) => participantSet.has(n)).sort();
|
|
27140
27125
|
const ancestors = stillRejected.filter((n) => !participantSet.has(n)).sort();
|
|
27141
27126
|
return /* @__PURE__ */ jsxs39(Box38, { flexDirection: "column", borderStyle: "single", borderColor: PALETTE.error, paddingX: 1, children: [
|
|
27142
|
-
/* @__PURE__ */ jsx47(
|
|
27143
|
-
members.length > 0 && /* @__PURE__ */ jsx47(
|
|
27144
|
-
ancestors.length > 0 && /* @__PURE__ */ jsx47(
|
|
27145
|
-
/* @__PURE__ */ jsx47(
|
|
27127
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.error, bold: true, children: `Cyclic component graph \u2014 auto-rejected ${stillRejected.length} component${stillRejected.length === 1 ? "" : "s"}:` }),
|
|
27128
|
+
members.length > 0 && /* @__PURE__ */ jsx47(Text40, { color: PALETTE.error, children: ` Cycle members: ${members.join(", ")}` }),
|
|
27129
|
+
ancestors.length > 0 && /* @__PURE__ */ jsx47(Text40, { color: PALETTE.error, children: ` Ancestors: ${ancestors.join(", ")}` }),
|
|
27130
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.muted, children: undoSnapshot ? " [Ctrl+Z] undo \xB7 [r]/[a] manually toggle \xB7 [F] continue" : " [r]/[a] manually toggle \xB7 [F] continue" })
|
|
27146
27131
|
] });
|
|
27147
27132
|
})(),
|
|
27148
27133
|
/* @__PURE__ */ jsx47(ReviewEmptyComponentsWarning, { count: emptyCount, hidden: dialogOpen }),
|
|
@@ -27257,7 +27242,7 @@ function GenerateReviewStepView({
|
|
|
27257
27242
|
) : /* @__PURE__ */ jsx47(ReviewNoSelection, {})
|
|
27258
27243
|
] }),
|
|
27259
27244
|
!dialogOpen && cycleRows.length > 0 && !cyclePanel.isOpen && !breakPanel.isOpen && /* @__PURE__ */ jsxs39(Box38, { flexDirection: "column", children: [
|
|
27260
|
-
/* @__PURE__ */ jsx47(
|
|
27245
|
+
/* @__PURE__ */ jsx47(Text40, { color: PALETTE.warning, children: `\u26A0 ${cycleRows.length} slot dependency cycle${cycleRows.length === 1 ? "" : "s"} detected \u2014 push will fail` }),
|
|
27261
27246
|
cycleRows.slice(0, 3).map((cycle, idx) => {
|
|
27262
27247
|
return /* @__PURE__ */ jsx47(
|
|
27263
27248
|
CyclePathLine,
|
|
@@ -27270,8 +27255,8 @@ function GenerateReviewStepView({
|
|
|
27270
27255
|
`cyc-banner-${idx}`
|
|
27271
27256
|
);
|
|
27272
27257
|
}),
|
|
27273
|
-
cycleRows.length > 3 && /* @__PURE__ */ jsx47(
|
|
27274
|
-
/* @__PURE__ */ jsx47(
|
|
27258
|
+
cycleRows.length > 3 && /* @__PURE__ */ jsx47(Text40, { color: PALETTE.warning, children: ` \u2026${cycleRows.length - 3} more` }),
|
|
27259
|
+
/* @__PURE__ */ jsx47(Text40, { children: " press [c] for detail" })
|
|
27275
27260
|
] }),
|
|
27276
27261
|
/* @__PURE__ */ jsx47(
|
|
27277
27262
|
SearchMatchSummary,
|
|
@@ -27674,7 +27659,7 @@ __export(WizardApp_exports, {
|
|
|
27674
27659
|
shouldRunMapTokens: () => shouldRunMapTokens
|
|
27675
27660
|
});
|
|
27676
27661
|
import { useEffect as useEffect14, useRef as useRef10, useState as useState20 } from "react";
|
|
27677
|
-
import { Box as Box39, Text as
|
|
27662
|
+
import { Box as Box39, Text as Text41 } from "ink";
|
|
27678
27663
|
import { join as join20, resolve as resolve18 } from "node:path";
|
|
27679
27664
|
import { appendFileSync as appendFileSync2, writeFileSync } from "node:fs";
|
|
27680
27665
|
import { access as access7, stat as stat5, writeFile as writeFile5 } from "node:fs/promises";
|
|
@@ -29435,7 +29420,7 @@ Tokens Path: ${state.tokensPath}`,
|
|
|
29435
29420
|
}
|
|
29436
29421
|
case "scope-gate": {
|
|
29437
29422
|
if (!state.extractSessionId) {
|
|
29438
|
-
return /* @__PURE__ */ jsx48(Box39, { paddingX: 2, paddingY: 1, children: /* @__PURE__ */ jsx48(
|
|
29423
|
+
return /* @__PURE__ */ jsx48(Box39, { paddingX: 2, paddingY: 1, children: /* @__PURE__ */ jsx48(Text41, { color: PALETTE.error, children: "Error: extract session ID missing \u2014 please re-run." }) });
|
|
29439
29424
|
}
|
|
29440
29425
|
const sessionId2 = state.extractSessionId;
|
|
29441
29426
|
const db = openPipelineDb();
|
|
@@ -30338,7 +30323,7 @@ var init_command7 = __esm({
|
|
|
30338
30323
|
|
|
30339
30324
|
// packages/experience-design-system-cli-legacy/src/setup/SetupStepper.tsx
|
|
30340
30325
|
import React14 from "react";
|
|
30341
|
-
import { Box as Box40, Text as
|
|
30326
|
+
import { Box as Box40, Text as Text42 } from "ink";
|
|
30342
30327
|
import { jsx as jsx49, jsxs as jsxs41 } from "react/jsx-runtime";
|
|
30343
30328
|
function stepLabel(step, title, state, wide) {
|
|
30344
30329
|
if (state === "complete") return wide ? `\u2713 ${title}` : "\u2713";
|
|
@@ -30356,8 +30341,8 @@ function SetupStepper({ activeStep, columns }) {
|
|
|
30356
30341
|
const step = index + 1;
|
|
30357
30342
|
const state = step < activeStep ? "complete" : step === activeStep ? "active" : "pending";
|
|
30358
30343
|
return /* @__PURE__ */ jsxs41(React14.Fragment, { children: [
|
|
30359
|
-
wide && index > 0 && /* @__PURE__ */ jsx49(
|
|
30360
|
-
/* @__PURE__ */ jsx49(
|
|
30344
|
+
wide && index > 0 && /* @__PURE__ */ jsx49(Text42, { color: PALETTE.muted, children: WIDE_SEPARATOR }),
|
|
30345
|
+
/* @__PURE__ */ jsx49(Text42, { bold: state === "active", color: state === "pending" ? PALETTE.muted : stepColor(state), children: stepLabel(step, title, state, wide) })
|
|
30361
30346
|
] }, step);
|
|
30362
30347
|
}) });
|
|
30363
30348
|
}
|
|
@@ -30376,23 +30361,23 @@ var init_SetupStepper = __esm({
|
|
|
30376
30361
|
});
|
|
30377
30362
|
|
|
30378
30363
|
// packages/experience-design-system-cli-legacy/src/setup/steps/StepLayout.tsx
|
|
30379
|
-
import { Box as Box41, Text as
|
|
30364
|
+
import { Box as Box41, Text as Text43 } from "ink";
|
|
30380
30365
|
import { jsx as jsx50, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
30381
30366
|
function StepLayout({ helpText, children, prompt }) {
|
|
30382
30367
|
return /* @__PURE__ */ jsxs42(Box41, { flexDirection: "column", children: [
|
|
30383
30368
|
children,
|
|
30384
30369
|
prompt && /* @__PURE__ */ jsx50(Box41, { marginTop: 1, children: prompt }),
|
|
30385
|
-
helpText && /* @__PURE__ */ jsx50(Box41, { marginTop: 1, children: /* @__PURE__ */ jsx50(
|
|
30370
|
+
helpText && /* @__PURE__ */ jsx50(Box41, { marginTop: 1, children: /* @__PURE__ */ jsx50(Text43, { color: PALETTE.muted, children: helpText }) })
|
|
30386
30371
|
] });
|
|
30387
30372
|
}
|
|
30388
30373
|
function StepSuccess({ children }) {
|
|
30389
|
-
return /* @__PURE__ */ jsxs42(
|
|
30374
|
+
return /* @__PURE__ */ jsxs42(Text43, { color: PALETTE.success, children: [
|
|
30390
30375
|
"\u2713 ",
|
|
30391
30376
|
children
|
|
30392
30377
|
] });
|
|
30393
30378
|
}
|
|
30394
30379
|
function StepWarning({ children }) {
|
|
30395
|
-
return /* @__PURE__ */ jsxs42(
|
|
30380
|
+
return /* @__PURE__ */ jsxs42(Text43, { color: PALETTE.warning, children: [
|
|
30396
30381
|
"\u26A0 ",
|
|
30397
30382
|
children
|
|
30398
30383
|
] });
|
|
@@ -30400,9 +30385,9 @@ function StepWarning({ children }) {
|
|
|
30400
30385
|
function StepValue({ label, value }) {
|
|
30401
30386
|
const color = value ? void 0 : PALETTE.warning;
|
|
30402
30387
|
return /* @__PURE__ */ jsxs42(Box41, { children: [
|
|
30403
|
-
/* @__PURE__ */ jsx50(Box41, { width: 2, children: /* @__PURE__ */ jsx50(
|
|
30404
|
-
/* @__PURE__ */ jsx50(Box41, { width: 20, flexShrink: 0, children: /* @__PURE__ */ jsx50(
|
|
30405
|
-
/* @__PURE__ */ jsx50(
|
|
30388
|
+
/* @__PURE__ */ jsx50(Box41, { width: 2, children: /* @__PURE__ */ jsx50(Text43, { color, children: value ? "" : "\u26A0" }) }),
|
|
30389
|
+
/* @__PURE__ */ jsx50(Box41, { width: 20, flexShrink: 0, children: /* @__PURE__ */ jsx50(Text43, { color, children: label }) }),
|
|
30390
|
+
/* @__PURE__ */ jsx50(Text43, { color, children: value || "(not set)" })
|
|
30406
30391
|
] });
|
|
30407
30392
|
}
|
|
30408
30393
|
var init_StepLayout = __esm({
|
|
@@ -30414,7 +30399,7 @@ var init_StepLayout = __esm({
|
|
|
30414
30399
|
|
|
30415
30400
|
// packages/experience-design-system-cli-legacy/src/setup/steps/CodingAgentScreen.tsx
|
|
30416
30401
|
import { useEffect as useEffect15, useRef as useRef11, useState as useState21 } from "react";
|
|
30417
|
-
import { Box as Box42, Text as
|
|
30402
|
+
import { Box as Box42, Text as Text44 } from "ink";
|
|
30418
30403
|
import { Select, TextInput } from "@inkjs/ui";
|
|
30419
30404
|
import { jsx as jsx51, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
30420
30405
|
async function detectAgents(exists = binaryExists) {
|
|
@@ -30473,7 +30458,7 @@ function CodingAgentScreen({ onDone, deps }) {
|
|
|
30473
30458
|
afterSelection(agent);
|
|
30474
30459
|
};
|
|
30475
30460
|
const chooser = (question, options, describe, onPick) => /* @__PURE__ */ jsxs43(Box42, { flexDirection: "column", children: [
|
|
30476
|
-
/* @__PURE__ */ jsx51(
|
|
30461
|
+
/* @__PURE__ */ jsx51(Text44, { children: question }),
|
|
30477
30462
|
/* @__PURE__ */ jsx51(Box42, { marginTop: 1, children: /* @__PURE__ */ jsx51(
|
|
30478
30463
|
Select,
|
|
30479
30464
|
{
|
|
@@ -30521,7 +30506,7 @@ function CodingAgentScreen({ onDone, deps }) {
|
|
|
30521
30506
|
{
|
|
30522
30507
|
helpText: AGENT_HELP,
|
|
30523
30508
|
prompt: /* @__PURE__ */ jsxs43(Box42, { children: [
|
|
30524
|
-
/* @__PURE__ */ jsx51(
|
|
30509
|
+
/* @__PURE__ */ jsx51(Text44, { children: "Model name (optional - press Enter for Codex default): " }),
|
|
30525
30510
|
/* @__PURE__ */ jsx51(
|
|
30526
30511
|
TextInput,
|
|
30527
30512
|
{
|
|
@@ -30533,18 +30518,18 @@ function CodingAgentScreen({ onDone, deps }) {
|
|
|
30533
30518
|
children: [
|
|
30534
30519
|
...notes,
|
|
30535
30520
|
/* @__PURE__ */ jsx51(StepWarning, { children: "No OPENAI_API_KEY \u2014 using ChatGPT account authentication." }, "no-key"),
|
|
30536
|
-
/* @__PURE__ */ jsx51(
|
|
30521
|
+
/* @__PURE__ */ jsx51(Text44, { color: PALETTE.muted, children: "Tip: run codex then type /model to browse all available models." }, "tip")
|
|
30537
30522
|
]
|
|
30538
30523
|
}
|
|
30539
30524
|
);
|
|
30540
30525
|
}
|
|
30541
30526
|
if (phase.kind === "installing") {
|
|
30542
|
-
return /* @__PURE__ */ jsx51(StepLayout, { helpText: AGENT_HELP, children: [...notes, /* @__PURE__ */ jsx51(
|
|
30527
|
+
return /* @__PURE__ */ jsx51(StepLayout, { helpText: AGENT_HELP, children: [...notes, /* @__PURE__ */ jsx51(Text44, { children: `Installing ${phase.agent.name}\u2026` }, "installing")] });
|
|
30543
30528
|
}
|
|
30544
30529
|
if (phase.kind === "failed") {
|
|
30545
|
-
return /* @__PURE__ */ jsx51(StepLayout, { helpText: AGENT_HELP, children: [...notes, /* @__PURE__ */ jsx51(
|
|
30530
|
+
return /* @__PURE__ */ jsx51(StepLayout, { helpText: AGENT_HELP, children: [...notes, /* @__PURE__ */ jsx51(Text44, { children: `\u2717 ${phase.message}` }, "failed")] });
|
|
30546
30531
|
}
|
|
30547
|
-
return /* @__PURE__ */ jsx51(
|
|
30532
|
+
return /* @__PURE__ */ jsx51(Text44, { color: PALETTE.muted, children: "Looking for a coding agent\u2026" });
|
|
30548
30533
|
}
|
|
30549
30534
|
var AGENT_HELP, SKIP_VALUE;
|
|
30550
30535
|
var init_CodingAgentScreen = __esm({
|
|
@@ -30554,6 +30539,7 @@ var init_CodingAgentScreen = __esm({
|
|
|
30554
30539
|
init_credentials_store();
|
|
30555
30540
|
init_shell();
|
|
30556
30541
|
init_StepLayout();
|
|
30542
|
+
init_theme();
|
|
30557
30543
|
AGENT_HELP = "Experiences import requires a coding agent to generate component definitions.";
|
|
30558
30544
|
SKIP_VALUE = "\0skip";
|
|
30559
30545
|
}
|
|
@@ -30561,7 +30547,7 @@ var init_CodingAgentScreen = __esm({
|
|
|
30561
30547
|
|
|
30562
30548
|
// packages/experience-design-system-cli-legacy/src/setup/steps/ContentfulCredentialsScreen.tsx
|
|
30563
30549
|
import { useEffect as useEffect16, useRef as useRef12, useState as useState22 } from "react";
|
|
30564
|
-
import { Box as Box43, Text as
|
|
30550
|
+
import { Box as Box43, Text as Text45 } from "ink";
|
|
30565
30551
|
import { PasswordInput, Select as Select2, TextInput as TextInput2 } from "@inkjs/ui";
|
|
30566
30552
|
import { Fragment as Fragment20, jsx as jsx52, jsxs as jsxs44 } from "react/jsx-runtime";
|
|
30567
30553
|
function envShadowingWarning(env) {
|
|
@@ -30580,7 +30566,7 @@ function ContentfulCredentialsScreen({ onDone }) {
|
|
|
30580
30566
|
useEffect16(() => {
|
|
30581
30567
|
void readExperiencesCredentials().then(setStored);
|
|
30582
30568
|
}, []);
|
|
30583
|
-
if (!stored) return /* @__PURE__ */ jsx52(
|
|
30569
|
+
if (!stored) return /* @__PURE__ */ jsx52(Text45, { color: PALETTE.muted, children: "Reading saved credentials\u2026" });
|
|
30584
30570
|
const currentHost = stored.host ?? DEFAULT_CONFIGURED_HOST;
|
|
30585
30571
|
const hasAny = Boolean(stored.spaceId || stored.environmentId || stored.cmaToken);
|
|
30586
30572
|
const allSet = Boolean(stored.spaceId && stored.environmentId && stored.cmaToken);
|
|
@@ -30588,7 +30574,7 @@ function ContentfulCredentialsScreen({ onDone }) {
|
|
|
30588
30574
|
const summary = /* @__PURE__ */ jsxs44(Fragment20, { children: [
|
|
30589
30575
|
shadowing && /* @__PURE__ */ jsx52(StepWarning, { children: shadowing }),
|
|
30590
30576
|
hasAny && /* @__PURE__ */ jsxs44(Box43, { flexDirection: "column", marginTop: shadowing ? 1 : 0, children: [
|
|
30591
|
-
/* @__PURE__ */ jsx52(
|
|
30577
|
+
/* @__PURE__ */ jsx52(Text45, { children: "Current values:" }),
|
|
30592
30578
|
/* @__PURE__ */ jsx52(StepValue, { label: "Space ID", value: stored.spaceId }),
|
|
30593
30579
|
/* @__PURE__ */ jsx52(StepValue, { label: "Environment ID", value: stored.environmentId }),
|
|
30594
30580
|
/* @__PURE__ */ jsx52(StepValue, { label: "CMA Token", value: stored.cmaToken ? maskToken(stored.cmaToken) : void 0 }),
|
|
@@ -30607,7 +30593,7 @@ function ContentfulCredentialsScreen({ onDone }) {
|
|
|
30607
30593
|
{
|
|
30608
30594
|
helpText,
|
|
30609
30595
|
prompt: /* @__PURE__ */ jsxs44(Box43, { flexDirection: "column", children: [
|
|
30610
|
-
/* @__PURE__ */ jsx52(
|
|
30596
|
+
/* @__PURE__ */ jsx52(Text45, { children: "Contentful credentials" }),
|
|
30611
30597
|
/* @__PURE__ */ jsx52(Box43, { marginTop: 1, children: /* @__PURE__ */ jsx52(
|
|
30612
30598
|
Select2,
|
|
30613
30599
|
{
|
|
@@ -30650,19 +30636,19 @@ function ContentfulCredentialsScreen({ onDone }) {
|
|
|
30650
30636
|
};
|
|
30651
30637
|
const prompts = {
|
|
30652
30638
|
spaceId: /* @__PURE__ */ jsxs44(Box43, { children: [
|
|
30653
|
-
/* @__PURE__ */ jsx52(
|
|
30639
|
+
/* @__PURE__ */ jsx52(Text45, { children: `Space ID${stored.spaceId ? ` [${stored.spaceId}]` : ""}: ` }),
|
|
30654
30640
|
/* @__PURE__ */ jsx52(TextInput2, { onSubmit: (v) => advance("spaceId", v) }, "spaceId")
|
|
30655
30641
|
] }),
|
|
30656
30642
|
environmentId: /* @__PURE__ */ jsxs44(Box43, { children: [
|
|
30657
|
-
/* @__PURE__ */ jsx52(
|
|
30643
|
+
/* @__PURE__ */ jsx52(Text45, { children: `Environment ID [${stored.environmentId || "master"}]: ` }),
|
|
30658
30644
|
/* @__PURE__ */ jsx52(TextInput2, { onSubmit: (v) => advance("environmentId", v) }, "environmentId")
|
|
30659
30645
|
] }),
|
|
30660
30646
|
cmaToken: /* @__PURE__ */ jsxs44(Box43, { children: [
|
|
30661
|
-
/* @__PURE__ */ jsx52(
|
|
30647
|
+
/* @__PURE__ */ jsx52(Text45, { children: `CMA token${stored.cmaToken ? " [press Enter to keep existing]" : " (paste here)"}: ` }),
|
|
30662
30648
|
/* @__PURE__ */ jsx52(PasswordInput, { onSubmit: (v) => advance("cmaToken", v) }, "cmaToken")
|
|
30663
30649
|
] }),
|
|
30664
30650
|
host: /* @__PURE__ */ jsxs44(Box43, { children: [
|
|
30665
|
-
/* @__PURE__ */ jsx52(
|
|
30651
|
+
/* @__PURE__ */ jsx52(Text45, { children: `API host [${currentHost}]: ` }),
|
|
30666
30652
|
/* @__PURE__ */ jsx52(TextInput2, { onSubmit: (v) => advance("host", v) }, "host")
|
|
30667
30653
|
] })
|
|
30668
30654
|
};
|
|
@@ -30675,6 +30661,7 @@ var init_ContentfulCredentialsScreen = __esm({
|
|
|
30675
30661
|
init_credentials_store();
|
|
30676
30662
|
init_host_utils();
|
|
30677
30663
|
init_StepLayout();
|
|
30664
|
+
init_theme();
|
|
30678
30665
|
ENV_KEYS = ["CONTENTFUL_SPACE_ID", "CONTENTFUL_ENVIRONMENT_ID", "CONTENTFUL_MANAGEMENT_TOKEN", "EDS_HOST"];
|
|
30679
30666
|
ENTER = "enter";
|
|
30680
30667
|
KEEP = "keep";
|
|
@@ -30684,7 +30671,7 @@ var init_ContentfulCredentialsScreen = __esm({
|
|
|
30684
30671
|
|
|
30685
30672
|
// packages/experience-design-system-cli-legacy/src/setup/steps/preferences/BooleanInput.tsx
|
|
30686
30673
|
import { useEffect as useEffect17, useState as useState23 } from "react";
|
|
30687
|
-
import { Box as Box44, Text as
|
|
30674
|
+
import { Box as Box44, Text as Text46 } from "ink";
|
|
30688
30675
|
import { Select as Select3 } from "@inkjs/ui";
|
|
30689
30676
|
import { jsx as jsx53, jsxs as jsxs45 } from "react/jsx-runtime";
|
|
30690
30677
|
function tick(labels, forOn, current) {
|
|
@@ -30704,7 +30691,7 @@ function BooleanInput({
|
|
|
30704
30691
|
useEffect17(() => {
|
|
30705
30692
|
void readExperiencesCredentials().then(setStored);
|
|
30706
30693
|
}, []);
|
|
30707
|
-
if (!stored) return /* @__PURE__ */ jsx53(
|
|
30694
|
+
if (!stored) return /* @__PURE__ */ jsx53(Text46, { color: PALETTE.muted, children: "Reading saved preferences\u2026" });
|
|
30708
30695
|
const current = read(stored) ?? fallback;
|
|
30709
30696
|
const submit = (value) => {
|
|
30710
30697
|
if (value === current) {
|
|
@@ -30718,7 +30705,7 @@ function BooleanInput({
|
|
|
30718
30705
|
{
|
|
30719
30706
|
helpText,
|
|
30720
30707
|
prompt: /* @__PURE__ */ jsxs45(Box44, { flexDirection: "column", children: [
|
|
30721
|
-
/* @__PURE__ */ jsx53(
|
|
30708
|
+
/* @__PURE__ */ jsx53(Text46, { children: question }),
|
|
30722
30709
|
/* @__PURE__ */ jsx53(Box44, { marginTop: 1, children: /* @__PURE__ */ jsx53(
|
|
30723
30710
|
Select3,
|
|
30724
30711
|
{
|
|
@@ -30740,6 +30727,7 @@ var init_BooleanInput = __esm({
|
|
|
30740
30727
|
"use strict";
|
|
30741
30728
|
init_credentials_store();
|
|
30742
30729
|
init_StepLayout();
|
|
30730
|
+
init_theme();
|
|
30743
30731
|
}
|
|
30744
30732
|
});
|
|
30745
30733
|
|
|
@@ -30791,7 +30779,7 @@ var init_ColorPreferenceScreen = __esm({
|
|
|
30791
30779
|
|
|
30792
30780
|
// packages/experience-design-system-cli-legacy/src/setup/steps/preferences/CustomPromptScreen.tsx
|
|
30793
30781
|
import { useEffect as useEffect18, useState as useState24 } from "react";
|
|
30794
|
-
import { Box as Box45, Text as
|
|
30782
|
+
import { Box as Box45, Text as Text47 } from "ink";
|
|
30795
30783
|
import { ConfirmInput, TextInput as TextInput3 } from "@inkjs/ui";
|
|
30796
30784
|
import { jsx as jsx56, jsxs as jsxs46 } from "react/jsx-runtime";
|
|
30797
30785
|
function parseCustomSkillPath(answer) {
|
|
@@ -30815,7 +30803,7 @@ function CustomPromptsScreen({ onDone }) {
|
|
|
30815
30803
|
useEffect18(() => {
|
|
30816
30804
|
void readExperiencesCredentials().then(setStored);
|
|
30817
30805
|
}, []);
|
|
30818
|
-
if (!stored) return /* @__PURE__ */ jsx56(
|
|
30806
|
+
if (!stored) return /* @__PURE__ */ jsx56(Text47, { color: PALETTE.muted, children: "Reading saved prompt paths\u2026" });
|
|
30819
30807
|
const submit = (answer) => {
|
|
30820
30808
|
const next = applyCustomSkillPath(stored, parseCustomSkillPath(answer));
|
|
30821
30809
|
void writeExperiencesCredentials(next).then(() => onDone("completed"));
|
|
@@ -30826,7 +30814,7 @@ function CustomPromptsScreen({ onDone }) {
|
|
|
30826
30814
|
{
|
|
30827
30815
|
helpText: CUSTOM_PROMPTS_HELP,
|
|
30828
30816
|
prompt: /* @__PURE__ */ jsxs46(Box45, { children: [
|
|
30829
|
-
/* @__PURE__ */ jsx56(
|
|
30817
|
+
/* @__PURE__ */ jsx56(Text47, { children: "Use your own prompt file instead of the built-in one? " }),
|
|
30830
30818
|
/* @__PURE__ */ jsx56(
|
|
30831
30819
|
ConfirmInput,
|
|
30832
30820
|
{
|
|
@@ -30844,7 +30832,7 @@ function CustomPromptsScreen({ onDone }) {
|
|
|
30844
30832
|
{
|
|
30845
30833
|
helpText: CUSTOM_PROMPTS_HELP,
|
|
30846
30834
|
prompt: /* @__PURE__ */ jsxs46(Box45, { children: [
|
|
30847
|
-
/* @__PURE__ */ jsx56(
|
|
30835
|
+
/* @__PURE__ */ jsx56(Text47, { children: customSkillPathQuestion(stored.generatePromptPath) }),
|
|
30848
30836
|
/* @__PURE__ */ jsx56(TextInput3, { onSubmit: submit })
|
|
30849
30837
|
] })
|
|
30850
30838
|
}
|
|
@@ -30856,6 +30844,7 @@ var init_CustomPromptScreen = __esm({
|
|
|
30856
30844
|
"use strict";
|
|
30857
30845
|
init_credentials_store();
|
|
30858
30846
|
init_StepLayout();
|
|
30847
|
+
init_theme();
|
|
30859
30848
|
CUSTOM_PROMPTS_HELP = "Replaces the built-in instructions the coding agent follows when it generates components.";
|
|
30860
30849
|
}
|
|
30861
30850
|
});
|
|
@@ -30885,7 +30874,7 @@ var init_DebugLogsScreen = __esm({
|
|
|
30885
30874
|
|
|
30886
30875
|
// packages/experience-design-system-cli-legacy/src/setup/steps/preferences/PreferencesMenu.tsx
|
|
30887
30876
|
import { useState as useState25 } from "react";
|
|
30888
|
-
import { Box as Box46, Text as
|
|
30877
|
+
import { Box as Box46, Text as Text48 } from "ink";
|
|
30889
30878
|
import { Select as Select4 } from "@inkjs/ui";
|
|
30890
30879
|
import { jsx as jsx58, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
30891
30880
|
function PreferencesMenu({ onDone }) {
|
|
@@ -30916,7 +30905,7 @@ function PreferenceList({ changed, onOpen, onDone }) {
|
|
|
30916
30905
|
{
|
|
30917
30906
|
helpText: PREFERENCES_MENU_HELP,
|
|
30918
30907
|
prompt: /* @__PURE__ */ jsxs47(Box46, { flexDirection: "column", children: [
|
|
30919
|
-
/* @__PURE__ */ jsx58(
|
|
30908
|
+
/* @__PURE__ */ jsx58(Text48, { children: "Preferences" }),
|
|
30920
30909
|
/* @__PURE__ */ jsx58(Box46, { marginTop: 1, children: /* @__PURE__ */ jsx58(
|
|
30921
30910
|
Select4,
|
|
30922
30911
|
{
|
|
@@ -31181,23 +31170,23 @@ var init_prerequisites = __esm({
|
|
|
31181
31170
|
|
|
31182
31171
|
// packages/experience-design-system-cli-legacy/src/setup/steps/prerequisites/PrerequisitesScreen.tsx
|
|
31183
31172
|
import { useEffect as useEffect19, useRef as useRef13, useState as useState26 } from "react";
|
|
31184
|
-
import { Box as Box47, Text as
|
|
31173
|
+
import { Box as Box47, Text as Text49 } from "ink";
|
|
31185
31174
|
import { ConfirmInput as ConfirmInput2 } from "@inkjs/ui";
|
|
31186
31175
|
import { jsx as jsx59, jsxs as jsxs48 } from "react/jsx-runtime";
|
|
31187
31176
|
function EventLine({ event }) {
|
|
31188
|
-
if (event.kind === "success") return /* @__PURE__ */ jsxs48(
|
|
31177
|
+
if (event.kind === "success") return /* @__PURE__ */ jsxs48(Text49, { color: PALETTE.success, children: [
|
|
31189
31178
|
"\u2713 ",
|
|
31190
31179
|
event.message
|
|
31191
31180
|
] });
|
|
31192
|
-
if (event.kind === "failure") return /* @__PURE__ */ jsxs48(
|
|
31181
|
+
if (event.kind === "failure") return /* @__PURE__ */ jsxs48(Text49, { color: PALETTE.error, children: [
|
|
31193
31182
|
"\u2717 ",
|
|
31194
31183
|
event.message
|
|
31195
31184
|
] });
|
|
31196
|
-
if (event.kind === "warning") return /* @__PURE__ */ jsxs48(
|
|
31185
|
+
if (event.kind === "warning") return /* @__PURE__ */ jsxs48(Text49, { color: PALETTE.warning, children: [
|
|
31197
31186
|
"\u26A0 ",
|
|
31198
31187
|
event.message
|
|
31199
31188
|
] });
|
|
31200
|
-
return /* @__PURE__ */ jsx59(
|
|
31189
|
+
return /* @__PURE__ */ jsx59(Text49, { children: event.message });
|
|
31201
31190
|
}
|
|
31202
31191
|
function PrerequisitesScreen({
|
|
31203
31192
|
repoRoot,
|
|
@@ -31240,7 +31229,7 @@ function PrerequisitesScreen({
|
|
|
31240
31229
|
StepLayout,
|
|
31241
31230
|
{
|
|
31242
31231
|
prompt: confirm ? /* @__PURE__ */ jsxs48(Box47, { children: [
|
|
31243
|
-
/* @__PURE__ */ jsxs48(
|
|
31232
|
+
/* @__PURE__ */ jsxs48(Text49, { children: [
|
|
31244
31233
|
confirm.question,
|
|
31245
31234
|
" "
|
|
31246
31235
|
] }),
|
|
@@ -31253,7 +31242,7 @@ function PrerequisitesScreen({
|
|
|
31253
31242
|
},
|
|
31254
31243
|
confirm.question
|
|
31255
31244
|
)
|
|
31256
|
-
] }) : /* @__PURE__ */ jsx59(
|
|
31245
|
+
] }) : /* @__PURE__ */ jsx59(Text49, { color: PALETTE.info, children: "\u27F3 Checking prerequisites\u2026" }),
|
|
31257
31246
|
children: /* @__PURE__ */ jsx59(Box47, { flexDirection: "column", children: events.map((event, index) => /* @__PURE__ */ jsx59(EventLine, { event }, `${index}-${event.message}`)) })
|
|
31258
31247
|
}
|
|
31259
31248
|
);
|
|
@@ -31275,7 +31264,7 @@ __export(SetupScreen_exports, {
|
|
|
31275
31264
|
formatSetupCompletionMessage: () => formatSetupCompletionMessage
|
|
31276
31265
|
});
|
|
31277
31266
|
import { useEffect as useEffect20, useRef as useRef14, useState as useState27 } from "react";
|
|
31278
|
-
import { Box as Box48, Text as
|
|
31267
|
+
import { Box as Box48, Text as Text50 } from "ink";
|
|
31279
31268
|
import { jsx as jsx60, jsxs as jsxs49 } from "react/jsx-runtime";
|
|
31280
31269
|
function countRequiredFailures(results) {
|
|
31281
31270
|
return results.filter((result) => result.required && result.status === "failed").length;
|
|
@@ -31366,8 +31355,8 @@ function SetupScreen({
|
|
|
31366
31355
|
}, []);
|
|
31367
31356
|
return /* @__PURE__ */ jsxs49(Box48, { flexDirection: "column", paddingX: 1, children: [
|
|
31368
31357
|
/* @__PURE__ */ jsxs49(Box48, { justifyContent: "space-between", columnGap: 1, ...columns !== void 0 ? { width: columns - 2 } : {}, children: [
|
|
31369
|
-
/* @__PURE__ */ jsx60(Box48, { flexShrink: 0, children: /* @__PURE__ */ jsx60(
|
|
31370
|
-
/* @__PURE__ */ jsx60(Box48, { flexShrink: 0, children: /* @__PURE__ */ jsxs49(
|
|
31358
|
+
/* @__PURE__ */ jsx60(Box48, { flexShrink: 0, children: /* @__PURE__ */ jsx60(Text50, { bold: true, children: "experiences setup" }) }),
|
|
31359
|
+
/* @__PURE__ */ jsx60(Box48, { flexShrink: 0, children: /* @__PURE__ */ jsxs49(Text50, { color: PALETTE.muted, children: [
|
|
31371
31360
|
"v",
|
|
31372
31361
|
version
|
|
31373
31362
|
] }) })
|
|
@@ -31379,22 +31368,22 @@ function SetupScreen({
|
|
|
31379
31368
|
function SetupSummary({ outcome, notice }) {
|
|
31380
31369
|
const requiredFailed = countRequiredFailures(outcome.results);
|
|
31381
31370
|
return /* @__PURE__ */ jsxs49(Box48, { flexDirection: "column", marginTop: 1, children: [
|
|
31382
|
-
/* @__PURE__ */ jsx60(
|
|
31371
|
+
/* @__PURE__ */ jsx60(Text50, { bold: true, children: "Summary" }),
|
|
31383
31372
|
outcome.results.map((result) => {
|
|
31384
31373
|
if (result.status === "completed") {
|
|
31385
|
-
return /* @__PURE__ */ jsxs49(
|
|
31374
|
+
return /* @__PURE__ */ jsxs49(Text50, { color: PALETTE.success, children: [
|
|
31386
31375
|
"\u2713 ",
|
|
31387
31376
|
result.name
|
|
31388
31377
|
] }, result.name);
|
|
31389
31378
|
}
|
|
31390
31379
|
if (result.status === "skipped") {
|
|
31391
|
-
return /* @__PURE__ */ jsxs49(
|
|
31380
|
+
return /* @__PURE__ */ jsxs49(Text50, { color: PALETTE.muted, children: [
|
|
31392
31381
|
"\u2013 ",
|
|
31393
31382
|
result.name,
|
|
31394
31383
|
" \u2014 skipped"
|
|
31395
31384
|
] }, result.name);
|
|
31396
31385
|
}
|
|
31397
|
-
return /* @__PURE__ */ jsxs49(
|
|
31386
|
+
return /* @__PURE__ */ jsxs49(Text50, { color: result.required ? PALETTE.error : PALETTE.warning, children: [
|
|
31398
31387
|
result.required ? "\u2717" : "\u26A0",
|
|
31399
31388
|
" ",
|
|
31400
31389
|
result.name,
|
|
@@ -31402,10 +31391,10 @@ function SetupSummary({ outcome, notice }) {
|
|
|
31402
31391
|
result.required ? "required" : "optional"
|
|
31403
31392
|
] }, result.name);
|
|
31404
31393
|
}),
|
|
31405
|
-
notice && /* @__PURE__ */ jsx60(Box48, { marginTop: 1, children: /* @__PURE__ */ jsx60(
|
|
31406
|
-
/* @__PURE__ */ jsx60(Box48, { marginTop: 1, children: /* @__PURE__ */ jsx60(
|
|
31407
|
-
requiredFailed > 0 && /* @__PURE__ */ jsx60(
|
|
31408
|
-
/* @__PURE__ */ jsx60(
|
|
31394
|
+
notice && /* @__PURE__ */ jsx60(Box48, { marginTop: 1, children: /* @__PURE__ */ jsx60(Text50, { color: PALETTE.warning, children: notice }) }),
|
|
31395
|
+
/* @__PURE__ */ jsx60(Box48, { marginTop: 1, children: /* @__PURE__ */ jsx60(Text50, { bold: true, color: requiredFailed === 0 ? PALETTE.success : PALETTE.warning, children: formatSetupCompletionMessage(outcome.results) }) }),
|
|
31396
|
+
requiredFailed > 0 && /* @__PURE__ */ jsx60(Text50, { color: PALETTE.muted, children: "Complete the steps above, then re-run experiences setup." }),
|
|
31397
|
+
/* @__PURE__ */ jsx60(Text50, { color: PALETTE.muted, children: "Run experiences doctor any time to re-check." })
|
|
31409
31398
|
] });
|
|
31410
31399
|
}
|
|
31411
31400
|
var init_SetupScreen = __esm({
|