silvery 0.19.2 → 0.21.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/README.md +9 -4
- package/dist/Text-Lq0dmj8-.mjs +239 -0
- package/dist/Text-Lq0dmj8-.mjs.map +1 -0
- package/dist/UPNG-Bo33r8rA.mjs +3 -0
- package/dist/UPNG-DosRPdF4.mjs +5075 -0
- package/dist/UPNG-DosRPdF4.mjs.map +1 -0
- package/dist/__vite-browser-external-2447137e-D_JM6skp.mjs +6 -0
- package/dist/__vite-browser-external-2447137e-D_JM6skp.mjs.map +1 -0
- package/dist/{animation-Cn64yepo.mjs → animation-ZMN2_XKv.mjs} +2 -2
- package/dist/animation-ZMN2_XKv.mjs.map +1 -0
- package/dist/{ansi-Cc33mW54.d.mts → ansi-2Xn0yatP.d.mts} +1 -1
- package/dist/{ansi-Cc33mW54.d.mts.map → ansi-2Xn0yatP.d.mts.map} +1 -1
- package/dist/{ansi-CLOitHKx.mjs → ansi-D1KQMAbf.mjs} +1 -1
- package/dist/{ansi-CLOitHKx.mjs.map → ansi-D1KQMAbf.mjs.map} +1 -1
- package/dist/ansi-yC4RyBNY.mjs +22441 -0
- package/dist/ansi-yC4RyBNY.mjs.map +1 -0
- package/dist/apng-CR08rIaH.mjs +58 -0
- package/dist/apng-CR08rIaH.mjs.map +1 -0
- package/dist/apng-DaHfVaVI.mjs +3 -0
- package/dist/assets/resvgjs.darwin-arm64-BtufyGW1.node +0 -0
- package/dist/assets/skia.darwin-arm64-DQs5sT6N.node +0 -0
- package/dist/backend-B-WYLUib.mjs +13396 -0
- package/dist/backend-B-WYLUib.mjs.map +1 -0
- package/dist/backends-CUtan80W.mjs +3 -0
- package/dist/backends-DIVYzKqd.mjs +1083 -0
- package/dist/backends-DIVYzKqd.mjs.map +1 -0
- package/dist/bound-term-0sPrrzH1.d.mts +4640 -0
- package/dist/bound-term-0sPrrzH1.d.mts.map +1 -0
- package/dist/canvas-1v7dPT-_.mjs +3 -0
- package/dist/canvas-CSuPOMNt.mjs +1442 -0
- package/dist/canvas-CSuPOMNt.mjs.map +1 -0
- package/dist/{chunk-Vs_PY4HZ.mjs → chunk-BSw8zbkd.mjs} +1 -1
- package/dist/cli-dvo0r2fs.mjs +4 -0
- package/dist/compare-CQodSH4G.mjs +376 -0
- package/dist/compare-CQodSH4G.mjs.map +1 -0
- package/dist/compare-DHlcxEYA.mjs +3 -0
- package/dist/context-BU5LkkIy.mjs.map +1 -1
- package/dist/devtools-CJdt5H0X.mjs +2 -0
- package/dist/{devtools-DxkSLXDA.mjs → devtools-DcQjgyjL.mjs} +5 -4
- package/dist/{devtools-DxkSLXDA.mjs.map → devtools-DcQjgyjL.mjs.map} +1 -1
- package/dist/easing-BI-ASGMO.d.mts +24 -0
- package/dist/easing-BI-ASGMO.d.mts.map +1 -0
- package/dist/{eta-Bb3RH3wh.mjs → eta-CJlGH06n.mjs} +1 -1
- package/dist/{eta-Bb3RH3wh.mjs.map → eta-CJlGH06n.mjs.map} +1 -1
- package/dist/flexily-zero-adapter-C3Vj0fPt.mjs +306 -0
- package/dist/flexily-zero-adapter-C3Vj0fPt.mjs.map +1 -0
- package/dist/{flexily-zero-adapter-CMxXhdOL.mjs → flexily-zero-adapter-C4lW_Ov5.mjs} +1 -1
- package/dist/fonts-BFmhXDv7.mjs +88 -0
- package/dist/fonts-BFmhXDv7.mjs.map +1 -0
- package/dist/gif-C_AjaT9d.mjs +188 -0
- package/dist/gif-C_AjaT9d.mjs.map +1 -0
- package/dist/gif-DaC4XrxA.mjs +3 -0
- package/dist/gifenc-BOUT-KFB.mjs +730 -0
- package/dist/gifenc-BOUT-KFB.mjs.map +1 -0
- package/dist/image-C2Birh2x.mjs +1252 -0
- package/dist/image-C2Birh2x.mjs.map +1 -0
- package/dist/index-BUMxS65f.d.mts +453 -0
- package/dist/index-BUMxS65f.d.mts.map +1 -0
- package/dist/{index-D3saHouR.d.mts → index-CSQf13CI.d.mts} +1057 -1133
- package/dist/index-CSQf13CI.d.mts.map +1 -0
- package/dist/{index-BXslOebb.d.mts → index-Cl9KKjQ_.d.mts} +4919 -3921
- package/dist/index-Cl9KKjQ_.d.mts.map +1 -0
- package/dist/index-XbNrPhWl.d.mts +336 -0
- package/dist/index-XbNrPhWl.d.mts.map +1 -0
- package/dist/index.d.mts +8 -5
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +14 -12
- package/dist/index.mjs.map +1 -1
- package/dist/key-mapping-CS-YD_cD.mjs +132 -0
- package/dist/key-mapping-CS-YD_cD.mjs.map +1 -0
- package/dist/key-mapping-Yn-Jgrij.mjs +3 -0
- package/dist/{layout-engine-B6Cdz1yZ.mjs → layout-engine-C07LEXWT.mjs} +1 -1
- package/dist/layout-engine-C2px0RJE.mjs +67 -0
- package/dist/layout-engine-C2px0RJE.mjs.map +1 -0
- package/dist/layout-signals-Cnw6xk8Q.mjs +988 -0
- package/dist/layout-signals-Cnw6xk8Q.mjs.map +1 -0
- package/dist/mouse-events-Dki3ISIp.mjs +1044 -0
- package/dist/mouse-events-Dki3ISIp.mjs.map +1 -0
- package/dist/{multi-progress-Bq9Oi_WI.mjs → multi-progress-CIRjrzma.mjs} +3 -3
- package/dist/{multi-progress-Bq9Oi_WI.mjs.map → multi-progress-CIRjrzma.mjs.map} +1 -1
- package/dist/{multi-progress-DAQC7eap.d.mts → multi-progress-DHZ2xUT2.d.mts} +2 -2
- package/dist/{multi-progress-DAQC7eap.d.mts.map → multi-progress-DHZ2xUT2.d.mts.map} +1 -1
- package/dist/{node-BeWlnCPY.mjs → node-CjM5Rt-M.mjs} +4 -4
- package/dist/node-CjM5Rt-M.mjs.map +1 -0
- package/dist/playwright-D5YiZcNS.mjs +76397 -0
- package/dist/playwright-D5YiZcNS.mjs.map +1 -0
- package/dist/png-codec-Dp84742B.mjs +36 -0
- package/dist/png-codec-Dp84742B.mjs.map +1 -0
- package/dist/png-codec-QwOtJ8Zs.mjs +3 -0
- package/dist/progress-DB_Xo071.mjs +675 -0
- package/dist/progress-DB_Xo071.mjs.map +1 -0
- package/dist/{progress-bar-CXE5Qfkd.mjs → progress-bar-oJwq22CR.mjs} +4 -4
- package/dist/{progress-bar-CXE5Qfkd.mjs.map → progress-bar-oJwq22CR.mjs.map} +1 -1
- package/dist/rasterizer-BRXrDdWx.mjs +3 -0
- package/dist/rasterizer-CpEhJvdR.mjs +296 -0
- package/dist/rasterizer-CpEhJvdR.mjs.map +1 -0
- package/dist/reconciler-DldIJB93.mjs +2083 -0
- package/dist/reconciler-DldIJB93.mjs.map +1 -0
- package/dist/{render-string-CDCeYkS3.mjs → render-string-BcoCpjCB.mjs} +1 -1
- package/dist/{render-string-Darrg7ku.mjs → render-string-DkQacASz.mjs} +2707 -549
- package/dist/render-string-DkQacASz.mjs.map +1 -0
- package/dist/resvg-js-DkOndZI3.mjs +203 -0
- package/dist/resvg-js-DkOndZI3.mjs.map +1 -0
- package/dist/runtime.d.mts +3 -2
- package/dist/runtime.mjs +3 -3
- package/dist/schemes-JjNp4aSl.mjs +2611 -0
- package/dist/schemes-JjNp4aSl.mjs.map +1 -0
- package/dist/{spinner-CGo34vyR.d.mts → spinner-CZINHpkV.d.mts} +2 -2
- package/dist/{spinner-CGo34vyR.d.mts.map → spinner-CZINHpkV.d.mts.map} +1 -1
- package/dist/{spinner-CeOmcuw_.mjs → spinner-D9lrHr8s.mjs} +7 -7
- package/dist/spinner-D9lrHr8s.mjs.map +1 -0
- package/dist/src-5w9QR6_8.mjs +1071 -0
- package/dist/src-5w9QR6_8.mjs.map +1 -0
- package/dist/src-BNTToU7l.mjs +4387 -0
- package/dist/src-BNTToU7l.mjs.map +1 -0
- package/dist/{src-CF-6UN01.mjs → src-BR4xNwdG.mjs} +10436 -2622
- package/dist/src-BR4xNwdG.mjs.map +1 -0
- package/dist/{types-Bk2yw9Qj.mjs → src-DKp-_OFG.mjs} +34 -94
- package/dist/src-DKp-_OFG.mjs.map +1 -0
- package/dist/src-bt8wSrfJ.mjs +258 -0
- package/dist/src-bt8wSrfJ.mjs.map +1 -0
- package/dist/src-e33Y6kNJ.mjs +3 -0
- package/dist/src-iDwu25UD.mjs +1814 -0
- package/dist/src-iDwu25UD.mjs.map +1 -0
- package/dist/steps-Bp2uNqnn.d.mts +202 -0
- package/dist/steps-Bp2uNqnn.d.mts.map +1 -0
- package/dist/svg-15lZZzxq.mjs +486 -0
- package/dist/svg-15lZZzxq.mjs.map +1 -0
- package/dist/svg-Cz0UXcDj.mjs +255 -0
- package/dist/svg-Cz0UXcDj.mjs.map +1 -0
- package/dist/svg-DY72a4HK.mjs +3 -0
- package/dist/svg-g1D6ErwR.d.mts +82 -0
- package/dist/svg-g1D6ErwR.d.mts.map +1 -0
- package/dist/term.d.mts +3 -0
- package/dist/term.mjs +9 -0
- package/dist/term.mjs.map +1 -0
- package/dist/theme.d.mts +95 -2
- package/dist/theme.d.mts.map +1 -0
- package/dist/theme.mjs +9 -3
- package/dist/theme.mjs.map +1 -0
- package/dist/{types-BH_v3iMT.d.mts → types-kt_fKR37.d.mts} +2 -15
- package/dist/types-kt_fKR37.d.mts.map +1 -0
- package/dist/ui/animation.d.mts +2 -1
- package/dist/ui/animation.mjs +1 -1
- package/dist/ui/ansi.d.mts +1 -1
- package/dist/ui/ansi.mjs +1 -1
- package/dist/ui/cli.d.mts +3 -3
- package/dist/ui/cli.mjs +5 -5
- package/dist/ui/display.d.mts +1 -1
- package/dist/ui/image.d.mts +2 -2
- package/dist/ui/image.mjs +2 -2
- package/dist/ui/input.d.mts +1 -1
- package/dist/ui/input.mjs +4 -2
- package/dist/ui/input.mjs.map +1 -1
- package/dist/ui/progress.d.mts +5 -249
- package/dist/ui/progress.mjs +5 -858
- package/dist/ui/react.d.mts +1 -1
- package/dist/ui/react.mjs +2 -2
- package/dist/ui/recording-chrome-react.d.mts +21 -0
- package/dist/ui/recording-chrome-react.d.mts.map +1 -0
- package/dist/ui/recording-chrome-react.mjs +105 -0
- package/dist/ui/recording-chrome-react.mjs.map +1 -0
- package/dist/ui/recording-chrome.d.mts +2 -0
- package/dist/ui/recording-chrome.mjs +2 -0
- package/dist/ui/utils.mjs +1 -1
- package/dist/ui/wrappers.d.mts +3 -3
- package/dist/ui/wrappers.mjs +2 -2
- package/dist/ui.d.mts +7 -6
- package/dist/ui.mjs +8 -7
- package/dist/{useLatest-Bg2x4bfP.d.mts → useLatest-DRDDVwjh.d.mts} +5 -25
- package/dist/useLatest-DRDDVwjh.d.mts.map +1 -0
- package/dist/{with-text-input-CRfoiFFG.d.mts → with-text-input-YeohVLeo.d.mts} +4 -55
- package/dist/with-text-input-YeohVLeo.d.mts.map +1 -0
- package/dist/wrapper-C70ATkVv.mjs +3527 -0
- package/dist/wrapper-C70ATkVv.mjs.map +1 -0
- package/dist/{wrappers-UTADQkSY.mjs → wrappers-BCUYITrY.mjs} +5 -157
- package/dist/wrappers-BCUYITrY.mjs.map +1 -0
- package/dist/{yoga-adapter-8oRGRw8V.mjs → yoga-adapter-BnZX1PAY.mjs} +28 -2
- package/dist/yoga-adapter-BnZX1PAY.mjs.map +1 -0
- package/dist/yoga-adapter-DxgsQ_gg.mjs +2 -0
- package/dist/zipBundle-3nqeDRtm.mjs +3 -0
- package/dist/zipBundle-VNAYFmqJ.mjs +2003 -0
- package/dist/zipBundle-VNAYFmqJ.mjs.map +1 -0
- package/package.json +20 -9
- package/dist/animation-Cn64yepo.mjs.map +0 -1
- package/dist/cli-BKp0YtBD.mjs +0 -4
- package/dist/devtools-9QY4teqI.mjs +0 -2
- package/dist/flexily-zero-adapter-BlQa46nr.mjs +0 -3385
- package/dist/flexily-zero-adapter-BlQa46nr.mjs.map +0 -1
- package/dist/image-CTII5QWI.mjs +0 -477
- package/dist/image-CTII5QWI.mjs.map +0 -1
- package/dist/index-BXslOebb.d.mts.map +0 -1
- package/dist/index-BnA7mNpo.d.mts +0 -175
- package/dist/index-BnA7mNpo.d.mts.map +0 -1
- package/dist/index-D3saHouR.d.mts.map +0 -1
- package/dist/layout-engine-ClUgv6jB.mjs +0 -50
- package/dist/layout-engine-ClUgv6jB.mjs.map +0 -1
- package/dist/node-BeWlnCPY.mjs.map +0 -1
- package/dist/reconciler-Cwgm8hRR.mjs +0 -8459
- package/dist/reconciler-Cwgm8hRR.mjs.map +0 -1
- package/dist/render-string-Darrg7ku.mjs.map +0 -1
- package/dist/spinner-CeOmcuw_.mjs.map +0 -1
- package/dist/src-B5GjfG7g.mjs +0 -4305
- package/dist/src-B5GjfG7g.mjs.map +0 -1
- package/dist/src-CChwjk0Z.mjs +0 -738
- package/dist/src-CChwjk0Z.mjs.map +0 -1
- package/dist/src-CF-6UN01.mjs.map +0 -1
- package/dist/src-NCKb8kE5.mjs +0 -2660
- package/dist/src-NCKb8kE5.mjs.map +0 -1
- package/dist/types-BH_v3iMT.d.mts.map +0 -1
- package/dist/types-Bk2yw9Qj.mjs.map +0 -1
- package/dist/ui/progress.d.mts.map +0 -1
- package/dist/ui/progress.mjs.map +0 -1
- package/dist/useLatest-Bg2x4bfP.d.mts.map +0 -1
- package/dist/with-text-input-CRfoiFFG.d.mts.map +0 -1
- package/dist/wrappers-UTADQkSY.mjs.map +0 -1
- package/dist/yoga-adapter-8oRGRw8V.mjs.map +0 -1
- package/dist/yoga-adapter-D_CcxSt5.mjs +0 -2
|
@@ -0,0 +1,255 @@
|
|
|
1
|
+
//#region packages/ag-react/src/ui/recording-chrome/spec.ts
|
|
2
|
+
const RECORDING_CHROME_STYLES = [
|
|
3
|
+
"none",
|
|
4
|
+
"macos",
|
|
5
|
+
"windows"
|
|
6
|
+
];
|
|
7
|
+
const MACOS_CONTROLS = [
|
|
8
|
+
{
|
|
9
|
+
glyph: "●",
|
|
10
|
+
color: "red"
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
glyph: "●",
|
|
14
|
+
color: "yellow"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
glyph: "●",
|
|
18
|
+
color: "green"
|
|
19
|
+
}
|
|
20
|
+
];
|
|
21
|
+
const WINDOWS_CONTROLS = [
|
|
22
|
+
{
|
|
23
|
+
glyph: "−",
|
|
24
|
+
color: "$fg-muted"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
glyph: "□",
|
|
28
|
+
color: "$fg-muted"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
glyph: "×",
|
|
32
|
+
color: "red"
|
|
33
|
+
}
|
|
34
|
+
];
|
|
35
|
+
function recordingChromeOverhead(style) {
|
|
36
|
+
switch (style) {
|
|
37
|
+
case "macos":
|
|
38
|
+
case "windows": return {
|
|
39
|
+
cols: 2,
|
|
40
|
+
rows: 5
|
|
41
|
+
};
|
|
42
|
+
default: return {
|
|
43
|
+
cols: 0,
|
|
44
|
+
rows: 2
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
function composeRecordingChromeSpec(options = {}) {
|
|
49
|
+
const style = options.style ?? "macos";
|
|
50
|
+
const title = options.title ?? "";
|
|
51
|
+
const alignment = options.alignment ?? "center";
|
|
52
|
+
switch (style) {
|
|
53
|
+
case "macos": return {
|
|
54
|
+
style,
|
|
55
|
+
title,
|
|
56
|
+
alignment,
|
|
57
|
+
hasChrome: true,
|
|
58
|
+
overhead: recordingChromeOverhead(style),
|
|
59
|
+
live: {
|
|
60
|
+
borderStyle: "round",
|
|
61
|
+
titleBar: {
|
|
62
|
+
controlsSide: "left",
|
|
63
|
+
controls: MACOS_CONTROLS,
|
|
64
|
+
separator: "·"
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
};
|
|
68
|
+
case "windows": return {
|
|
69
|
+
style,
|
|
70
|
+
title,
|
|
71
|
+
alignment,
|
|
72
|
+
hasChrome: true,
|
|
73
|
+
overhead: recordingChromeOverhead(style),
|
|
74
|
+
live: {
|
|
75
|
+
borderStyle: "single",
|
|
76
|
+
titleBar: {
|
|
77
|
+
controlsSide: "right",
|
|
78
|
+
controls: WINDOWS_CONTROLS,
|
|
79
|
+
separator: null
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
};
|
|
83
|
+
default: return {
|
|
84
|
+
style: "none",
|
|
85
|
+
title,
|
|
86
|
+
alignment,
|
|
87
|
+
hasChrome: false,
|
|
88
|
+
overhead: recordingChromeOverhead("none"),
|
|
89
|
+
live: {
|
|
90
|
+
borderStyle: "none",
|
|
91
|
+
titleBar: null
|
|
92
|
+
}
|
|
93
|
+
};
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
function recordingChromeSvgLayout(spec) {
|
|
97
|
+
switch (spec.style) {
|
|
98
|
+
case "macos": {
|
|
99
|
+
const padding = 28;
|
|
100
|
+
const margin = 24;
|
|
101
|
+
const windowBarSize = 38;
|
|
102
|
+
return {
|
|
103
|
+
windowBar: "colorful",
|
|
104
|
+
windowBarSize,
|
|
105
|
+
padding,
|
|
106
|
+
borderRadius: 10,
|
|
107
|
+
margin,
|
|
108
|
+
shadow: 14,
|
|
109
|
+
contentOffset: {
|
|
110
|
+
x: margin + padding,
|
|
111
|
+
y: margin + padding + windowBarSize
|
|
112
|
+
}
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
case "windows": {
|
|
116
|
+
const padding = 24;
|
|
117
|
+
const margin = 0;
|
|
118
|
+
const windowBarSize = 34;
|
|
119
|
+
return {
|
|
120
|
+
windowBar: "windows",
|
|
121
|
+
windowBarSize,
|
|
122
|
+
padding,
|
|
123
|
+
borderRadius: 0,
|
|
124
|
+
margin,
|
|
125
|
+
shadow: 0,
|
|
126
|
+
contentOffset: {
|
|
127
|
+
x: margin + padding,
|
|
128
|
+
y: margin + padding + windowBarSize
|
|
129
|
+
}
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
default: return {
|
|
133
|
+
windowBar: "none",
|
|
134
|
+
windowBarSize: 0,
|
|
135
|
+
padding: 0,
|
|
136
|
+
borderRadius: 0,
|
|
137
|
+
margin: 0,
|
|
138
|
+
shadow: 0,
|
|
139
|
+
contentOffset: {
|
|
140
|
+
x: 0,
|
|
141
|
+
y: 0
|
|
142
|
+
}
|
|
143
|
+
};
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
function recordingChromeSvgContentOffset(spec) {
|
|
147
|
+
return recordingChromeSvgLayout(spec).contentOffset;
|
|
148
|
+
}
|
|
149
|
+
function recordingChromeSpecToSvgOptions(spec) {
|
|
150
|
+
if (!spec.hasChrome) return {};
|
|
151
|
+
const layout = recordingChromeSvgLayout(spec);
|
|
152
|
+
const options = {
|
|
153
|
+
windowBar: layout.windowBar,
|
|
154
|
+
windowBarSize: layout.windowBarSize,
|
|
155
|
+
padding: layout.padding,
|
|
156
|
+
borderRadius: layout.borderRadius,
|
|
157
|
+
...spec.title ? { windowTitle: spec.title } : {}
|
|
158
|
+
};
|
|
159
|
+
if (layout.margin > 0) options.margin = layout.margin;
|
|
160
|
+
if (layout.shadow > 0) options.shadow = layout.shadow;
|
|
161
|
+
return options;
|
|
162
|
+
}
|
|
163
|
+
//#endregion
|
|
164
|
+
//#region packages/ag-react/src/ui/recording-chrome/svg.ts
|
|
165
|
+
function coord(value) {
|
|
166
|
+
return String(Math.round(value * 1e3) / 1e3);
|
|
167
|
+
}
|
|
168
|
+
function escapeXml(text) {
|
|
169
|
+
return text.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
170
|
+
}
|
|
171
|
+
function rgbToHex(color) {
|
|
172
|
+
return `#${color.r.toString(16).padStart(2, "0")}${color.g.toString(16).padStart(2, "0")}${color.b.toString(16).padStart(2, "0")}`;
|
|
173
|
+
}
|
|
174
|
+
function parseHex(color) {
|
|
175
|
+
const m = /^#([0-9a-fA-F]{6})$/.exec(color.trim());
|
|
176
|
+
if (!m) return null;
|
|
177
|
+
const n = Number.parseInt(m[1], 16);
|
|
178
|
+
return {
|
|
179
|
+
r: n >> 16 & 255,
|
|
180
|
+
g: n >> 8 & 255,
|
|
181
|
+
b: n & 255
|
|
182
|
+
};
|
|
183
|
+
}
|
|
184
|
+
function luminance(c) {
|
|
185
|
+
return (.2126 * c.r + .7152 * c.g + .0722 * c.b) / 255;
|
|
186
|
+
}
|
|
187
|
+
function deriveBarColor(themeBg) {
|
|
188
|
+
const rgb = parseHex(themeBg);
|
|
189
|
+
if (!rgb) return "#333333";
|
|
190
|
+
const shift = luminance(rgb) < .5 ? 28 : -28;
|
|
191
|
+
const clamp = (v) => Math.max(0, Math.min(255, v + shift));
|
|
192
|
+
return rgbToHex({
|
|
193
|
+
r: clamp(rgb.r),
|
|
194
|
+
g: clamp(rgb.g),
|
|
195
|
+
b: clamp(rgb.b)
|
|
196
|
+
});
|
|
197
|
+
}
|
|
198
|
+
function titleColorFor(barColor) {
|
|
199
|
+
const rgb = parseHex(barColor);
|
|
200
|
+
if (!rgb) return "#cccccc";
|
|
201
|
+
return luminance(rgb) < .5 ? "#cccccc" : "#333333";
|
|
202
|
+
}
|
|
203
|
+
function composeRecordingChromeSvg(options) {
|
|
204
|
+
const specLayout = options.spec ? recordingChromeSvgLayout(options.spec) : null;
|
|
205
|
+
const windowBar = specLayout?.windowBar ?? options.windowBar ?? "none";
|
|
206
|
+
if (windowBar === "none") return [];
|
|
207
|
+
const barWidth = options.barWidth;
|
|
208
|
+
const barHeight = options.barHeight ?? specLayout?.windowBarSize ?? 40;
|
|
209
|
+
const borderRadius = options.borderRadius ?? specLayout?.borderRadius ?? 0;
|
|
210
|
+
const themeBg = options.themeBackground;
|
|
211
|
+
const title = options.title ?? options.spec?.title ?? null;
|
|
212
|
+
const fontSize = options.fontSize ?? 16;
|
|
213
|
+
const titleFontSize = Math.max(13, Math.min(fontSize, Math.round(barHeight * .5)));
|
|
214
|
+
const parts = [];
|
|
215
|
+
const barColor = deriveBarColor(themeBg);
|
|
216
|
+
parts.push(`<rect width="${coord(barWidth)}" height="${coord(barHeight)}" rx="${coord(borderRadius)}" ry="${coord(borderRadius)}" fill="${barColor}"/>`);
|
|
217
|
+
if (borderRadius > 0) parts.push(`<rect y="${coord(barHeight - borderRadius)}" width="${coord(barWidth)}" height="${coord(borderRadius)}" fill="${barColor}"/>`);
|
|
218
|
+
const titleColor = titleColorFor(barColor);
|
|
219
|
+
if (windowBar === "windows") {
|
|
220
|
+
const slot = 46;
|
|
221
|
+
const glyphSize = 10;
|
|
222
|
+
const cy = barHeight / 2;
|
|
223
|
+
const closeX = barWidth - slot / 2;
|
|
224
|
+
const maxX = barWidth - slot * 1.5;
|
|
225
|
+
const minX = barWidth - slot * 2.5;
|
|
226
|
+
const half = glyphSize / 2;
|
|
227
|
+
parts.push(`<line x1="${coord(minX - half)}" y1="${coord(cy)}" x2="${coord(minX + half)}" y2="${coord(cy)}" stroke="${titleColor}" stroke-width="1.4"/>`);
|
|
228
|
+
parts.push(`<rect x="${coord(maxX - half)}" y="${coord(cy - half)}" width="${glyphSize}" height="${glyphSize}" fill="none" stroke="${titleColor}" stroke-width="1.4"/>`);
|
|
229
|
+
parts.push(`<line x1="${coord(closeX - half)}" y1="${coord(cy - half)}" x2="${coord(closeX + half)}" y2="${coord(cy + half)}" stroke="#e81123" stroke-width="1.6"/>`);
|
|
230
|
+
parts.push(`<line x1="${coord(closeX - half)}" y1="${coord(cy + half)}" x2="${coord(closeX + half)}" y2="${coord(cy - half)}" stroke="#e81123" stroke-width="1.6"/>`);
|
|
231
|
+
if (title) parts.push(`<text x="14" y="${coord(cy)}" font-size="${titleFontSize}" font-family="'Segoe UI', 'Helvetica Neue', Arial, sans-serif" fill="${titleColor}" dominant-baseline="central">${escapeXml(title)}</text>`);
|
|
232
|
+
return parts;
|
|
233
|
+
}
|
|
234
|
+
const dotRadius = 6;
|
|
235
|
+
const dotY = barHeight / 2;
|
|
236
|
+
const dotStartX = 20;
|
|
237
|
+
if (windowBar === "rings") {
|
|
238
|
+
parts.push(`<circle cx="${dotStartX}" cy="${coord(dotY)}" r="${dotRadius}" fill="none" stroke="#ff5f57" stroke-width="1.5"/>`);
|
|
239
|
+
parts.push(`<circle cx="${dotStartX + 20}" cy="${coord(dotY)}" r="${dotRadius}" fill="none" stroke="#febc2e" stroke-width="1.5"/>`);
|
|
240
|
+
parts.push(`<circle cx="${dotStartX + 40}" cy="${coord(dotY)}" r="${dotRadius}" fill="none" stroke="#28c840" stroke-width="1.5"/>`);
|
|
241
|
+
} else {
|
|
242
|
+
parts.push(`<circle cx="${dotStartX}" cy="${coord(dotY)}" r="${dotRadius}" fill="#ff5f57"/>`);
|
|
243
|
+
parts.push(`<circle cx="${dotStartX + 20}" cy="${coord(dotY)}" r="${dotRadius}" fill="#febc2e"/>`);
|
|
244
|
+
parts.push(`<circle cx="${dotStartX + 40}" cy="${coord(dotY)}" r="${dotRadius}" fill="#28c840"/>`);
|
|
245
|
+
}
|
|
246
|
+
if (title) {
|
|
247
|
+
const titleStartX = dotStartX + 40 + dotRadius + 14;
|
|
248
|
+
parts.push(`<text x="${titleStartX}" y="${coord(dotY)}" font-size="${titleFontSize}" font-family="'Helvetica Neue', Arial, sans-serif" font-weight="bold" fill="${titleColor}" dominant-baseline="central">${escapeXml(title)}</text>`);
|
|
249
|
+
}
|
|
250
|
+
return parts;
|
|
251
|
+
}
|
|
252
|
+
//#endregion
|
|
253
|
+
export { recordingChromeSpecToSvgOptions as a, recordingChromeOverhead as i, RECORDING_CHROME_STYLES as n, recordingChromeSvgContentOffset as o, composeRecordingChromeSpec as r, recordingChromeSvgLayout as s, composeRecordingChromeSvg as t };
|
|
254
|
+
|
|
255
|
+
//# sourceMappingURL=svg-Cz0UXcDj.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"svg-Cz0UXcDj.mjs","names":[],"sources":["../packages/ag-react/src/ui/recording-chrome/spec.ts","../packages/ag-react/src/ui/recording-chrome/svg.ts"],"sourcesContent":["export const RECORDING_CHROME_STYLES = [\"none\", \"macos\", \"windows\"] as const\n\nexport type RecordingChromeStyle = (typeof RECORDING_CHROME_STYLES)[number]\nexport type RecordingChromeAlignment = \"center\" | \"left\"\nexport type RecordingChromeBorderStyle = \"round\" | \"single\" | \"none\"\nexport type RecordingChromeControlSide = \"left\" | \"right\"\nexport type RecordingChromeSvgWindowBar = \"none\" | \"rings\" | \"colorful\" | \"windows\"\n\nexport interface RecordingChromeOverhead {\n cols: number\n rows: number\n}\n\nexport interface RecordingChromeControl {\n glyph: string\n color?: string\n}\n\nexport interface RecordingChromeTitleBarSpec {\n controlsSide: RecordingChromeControlSide\n controls: readonly RecordingChromeControl[]\n separator: string | null\n}\n\nexport interface RecordingChromeLiveSpec {\n borderStyle: RecordingChromeBorderStyle\n titleBar: RecordingChromeTitleBarSpec | null\n}\n\nexport interface RecordingChromeSpec {\n style: RecordingChromeStyle\n title: string\n alignment: RecordingChromeAlignment\n hasChrome: boolean\n overhead: RecordingChromeOverhead\n live: RecordingChromeLiveSpec\n}\n\nexport interface ComposeRecordingChromeSpecOptions {\n style?: RecordingChromeStyle\n title?: string\n alignment?: RecordingChromeAlignment\n}\n\nexport interface RecordingChromeSvgLayout {\n windowBar: RecordingChromeSvgWindowBar\n windowBarSize: number\n padding: number\n borderRadius: number\n margin: number\n shadow: number\n contentOffset: { x: number; y: number }\n}\n\nexport interface RecordingChromeSvgOptions {\n windowBar?: RecordingChromeSvgWindowBar\n windowBarSize?: number\n padding?: number\n borderRadius?: number\n margin?: number\n shadow?: number\n windowTitle?: string\n}\n\nconst MACOS_CONTROLS: readonly RecordingChromeControl[] = [\n { glyph: \"●\", color: \"red\" },\n { glyph: \"●\", color: \"yellow\" },\n { glyph: \"●\", color: \"green\" },\n]\n\nconst WINDOWS_CONTROLS: readonly RecordingChromeControl[] = [\n { glyph: \"−\", color: \"$fg-muted\" },\n { glyph: \"□\", color: \"$fg-muted\" },\n { glyph: \"×\", color: \"red\" },\n]\n\nexport function recordingChromeOverhead(style: RecordingChromeStyle): RecordingChromeOverhead {\n switch (style) {\n case \"macos\":\n case \"windows\":\n return { cols: 2, rows: 5 }\n case \"none\":\n default:\n return { cols: 0, rows: 2 }\n }\n}\n\nexport function composeRecordingChromeSpec(\n options: ComposeRecordingChromeSpecOptions = {},\n): RecordingChromeSpec {\n const style = options.style ?? \"macos\"\n const title = options.title ?? \"\"\n const alignment = options.alignment ?? \"center\"\n\n switch (style) {\n case \"macos\":\n return {\n style,\n title,\n alignment,\n hasChrome: true,\n overhead: recordingChromeOverhead(style),\n live: {\n borderStyle: \"round\",\n titleBar: {\n controlsSide: \"left\",\n controls: MACOS_CONTROLS,\n separator: \"·\",\n },\n },\n }\n case \"windows\":\n return {\n style,\n title,\n alignment,\n hasChrome: true,\n overhead: recordingChromeOverhead(style),\n live: {\n borderStyle: \"single\",\n titleBar: {\n controlsSide: \"right\",\n controls: WINDOWS_CONTROLS,\n separator: null,\n },\n },\n }\n case \"none\":\n default:\n return {\n style: \"none\",\n title,\n alignment,\n hasChrome: false,\n overhead: recordingChromeOverhead(\"none\"),\n live: {\n borderStyle: \"none\",\n titleBar: null,\n },\n }\n }\n}\n\nexport function recordingChromeSvgLayout(spec: RecordingChromeSpec): RecordingChromeSvgLayout {\n switch (spec.style) {\n case \"macos\": {\n const padding = 28\n const margin = 24\n const windowBarSize = 38\n return {\n windowBar: \"colorful\",\n windowBarSize,\n padding,\n borderRadius: 10,\n margin,\n shadow: 14,\n contentOffset: { x: margin + padding, y: margin + padding + windowBarSize },\n }\n }\n case \"windows\": {\n const padding = 24\n const margin = 0\n const windowBarSize = 34\n return {\n windowBar: \"windows\",\n windowBarSize,\n padding,\n borderRadius: 0,\n margin,\n shadow: 0,\n contentOffset: { x: margin + padding, y: margin + padding + windowBarSize },\n }\n }\n case \"none\":\n default:\n return {\n windowBar: \"none\",\n windowBarSize: 0,\n padding: 0,\n borderRadius: 0,\n margin: 0,\n shadow: 0,\n contentOffset: { x: 0, y: 0 },\n }\n }\n}\n\nexport function recordingChromeSvgContentOffset(spec: RecordingChromeSpec): {\n x: number\n y: number\n} {\n return recordingChromeSvgLayout(spec).contentOffset\n}\n\nexport function recordingChromeSpecToSvgOptions(\n spec: RecordingChromeSpec,\n): RecordingChromeSvgOptions {\n if (!spec.hasChrome) return {}\n const layout = recordingChromeSvgLayout(spec)\n const options: RecordingChromeSvgOptions = {\n windowBar: layout.windowBar,\n windowBarSize: layout.windowBarSize,\n padding: layout.padding,\n borderRadius: layout.borderRadius,\n ...(spec.title ? { windowTitle: spec.title } : {}),\n }\n if (layout.margin > 0) options.margin = layout.margin\n if (layout.shadow > 0) options.shadow = layout.shadow\n return options\n}\n","import {\n recordingChromeSvgLayout,\n type RecordingChromeSpec,\n type RecordingChromeSvgWindowBar,\n} from \"./spec\"\n\nexport interface ComposeRecordingChromeSvgOptions {\n spec?: RecordingChromeSpec\n windowBar?: RecordingChromeSvgWindowBar\n barWidth: number\n barHeight?: number\n borderRadius?: number\n themeBackground: string\n title?: string | null\n fontSize?: number\n}\n\ninterface RGB {\n r: number\n g: number\n b: number\n}\n\nfunction coord(value: number): string {\n return String(Math.round(value * 1000) / 1000)\n}\n\nfunction escapeXml(text: string): string {\n return text\n .replace(/&/g, \"&\")\n .replace(/</g, \"<\")\n .replace(/>/g, \">\")\n .replace(/\"/g, \""\")\n .replace(/'/g, \"'\")\n}\n\nfunction rgbToHex(color: RGB): string {\n const r = color.r.toString(16).padStart(2, \"0\")\n const g = color.g.toString(16).padStart(2, \"0\")\n const b = color.b.toString(16).padStart(2, \"0\")\n return `#${r}${g}${b}`\n}\n\nfunction parseHex(color: string): RGB | null {\n const m = /^#([0-9a-fA-F]{6})$/.exec(color.trim())\n if (!m) return null\n const n = Number.parseInt(m[1]!, 16)\n return { r: (n >> 16) & 0xff, g: (n >> 8) & 0xff, b: n & 0xff }\n}\n\nfunction luminance(c: RGB): number {\n return (0.2126 * c.r + 0.7152 * c.g + 0.0722 * c.b) / 255\n}\n\nfunction deriveBarColor(themeBg: string): string {\n const rgb = parseHex(themeBg)\n if (!rgb) return \"#333333\"\n const dark = luminance(rgb) < 0.5\n const shift = dark ? 28 : -28\n const clamp = (v: number) => Math.max(0, Math.min(255, v + shift))\n return rgbToHex({ r: clamp(rgb.r), g: clamp(rgb.g), b: clamp(rgb.b) })\n}\n\nfunction titleColorFor(barColor: string): string {\n const rgb = parseHex(barColor)\n if (!rgb) return \"#cccccc\"\n return luminance(rgb) < 0.5 ? \"#cccccc\" : \"#333333\"\n}\n\nexport function composeRecordingChromeSvg(options: ComposeRecordingChromeSvgOptions): string[] {\n const specLayout = options.spec ? recordingChromeSvgLayout(options.spec) : null\n const windowBar = specLayout?.windowBar ?? options.windowBar ?? \"none\"\n if (windowBar === \"none\") return []\n\n const barWidth = options.barWidth\n const barHeight = options.barHeight ?? specLayout?.windowBarSize ?? 40\n const borderRadius = options.borderRadius ?? specLayout?.borderRadius ?? 0\n const themeBg = options.themeBackground\n const title = options.title ?? options.spec?.title ?? null\n const fontSize = options.fontSize ?? 16\n\n const titleFontSize = Math.max(13, Math.min(fontSize, Math.round(barHeight * 0.5)))\n const parts: string[] = []\n const barColor = deriveBarColor(themeBg)\n\n parts.push(\n `<rect width=\"${coord(barWidth)}\" height=\"${coord(barHeight)}\" rx=\"${coord(borderRadius)}\" ry=\"${coord(borderRadius)}\" fill=\"${barColor}\"/>`,\n )\n if (borderRadius > 0) {\n parts.push(\n `<rect y=\"${coord(barHeight - borderRadius)}\" width=\"${coord(barWidth)}\" height=\"${coord(borderRadius)}\" fill=\"${barColor}\"/>`,\n )\n }\n\n const titleColor = titleColorFor(barColor)\n\n if (windowBar === \"windows\") {\n const slot = 46\n const glyphSize = 10\n const cy = barHeight / 2\n const closeX = barWidth - slot / 2\n const maxX = barWidth - slot * 1.5\n const minX = barWidth - slot * 2.5\n const half = glyphSize / 2\n parts.push(\n `<line x1=\"${coord(minX - half)}\" y1=\"${coord(cy)}\" x2=\"${coord(minX + half)}\" y2=\"${coord(cy)}\" stroke=\"${titleColor}\" stroke-width=\"1.4\"/>`,\n )\n parts.push(\n `<rect x=\"${coord(maxX - half)}\" y=\"${coord(cy - half)}\" width=\"${glyphSize}\" height=\"${glyphSize}\" fill=\"none\" stroke=\"${titleColor}\" stroke-width=\"1.4\"/>`,\n )\n parts.push(\n `<line x1=\"${coord(closeX - half)}\" y1=\"${coord(cy - half)}\" x2=\"${coord(closeX + half)}\" y2=\"${coord(cy + half)}\" stroke=\"#e81123\" stroke-width=\"1.6\"/>`,\n )\n parts.push(\n `<line x1=\"${coord(closeX - half)}\" y1=\"${coord(cy + half)}\" x2=\"${coord(closeX + half)}\" y2=\"${coord(cy - half)}\" stroke=\"#e81123\" stroke-width=\"1.6\"/>`,\n )\n if (title) {\n parts.push(\n `<text x=\"14\" y=\"${coord(cy)}\" font-size=\"${titleFontSize}\" font-family=\"'Segoe UI', 'Helvetica Neue', Arial, sans-serif\" fill=\"${titleColor}\" dominant-baseline=\"central\">${escapeXml(title)}</text>`,\n )\n }\n return parts\n }\n\n const dotRadius = 6\n const dotY = barHeight / 2\n const dotStartX = 20\n\n if (windowBar === \"rings\") {\n parts.push(\n `<circle cx=\"${dotStartX}\" cy=\"${coord(dotY)}\" r=\"${dotRadius}\" fill=\"none\" stroke=\"#ff5f57\" stroke-width=\"1.5\"/>`,\n )\n parts.push(\n `<circle cx=\"${dotStartX + 20}\" cy=\"${coord(dotY)}\" r=\"${dotRadius}\" fill=\"none\" stroke=\"#febc2e\" stroke-width=\"1.5\"/>`,\n )\n parts.push(\n `<circle cx=\"${dotStartX + 40}\" cy=\"${coord(dotY)}\" r=\"${dotRadius}\" fill=\"none\" stroke=\"#28c840\" stroke-width=\"1.5\"/>`,\n )\n } else {\n parts.push(`<circle cx=\"${dotStartX}\" cy=\"${coord(dotY)}\" r=\"${dotRadius}\" fill=\"#ff5f57\"/>`)\n parts.push(\n `<circle cx=\"${dotStartX + 20}\" cy=\"${coord(dotY)}\" r=\"${dotRadius}\" fill=\"#febc2e\"/>`,\n )\n parts.push(\n `<circle cx=\"${dotStartX + 40}\" cy=\"${coord(dotY)}\" r=\"${dotRadius}\" fill=\"#28c840\"/>`,\n )\n }\n\n if (title) {\n const titleStartX = dotStartX + 40 + dotRadius + 14\n parts.push(\n `<text x=\"${titleStartX}\" y=\"${coord(dotY)}\" font-size=\"${titleFontSize}\" font-family=\"'Helvetica Neue', Arial, sans-serif\" font-weight=\"bold\" fill=\"${titleColor}\" dominant-baseline=\"central\">${escapeXml(title)}</text>`,\n )\n }\n\n return parts\n}\n"],"mappings":";AAAA,MAAa,0BAA0B;CAAC;CAAQ;CAAS;CAAU;AAgEnE,MAAM,iBAAoD;CACxD;EAAE,OAAO;EAAK,OAAO;EAAO;CAC5B;EAAE,OAAO;EAAK,OAAO;EAAU;CAC/B;EAAE,OAAO;EAAK,OAAO;EAAS;CAC/B;AAED,MAAM,mBAAsD;CAC1D;EAAE,OAAO;EAAK,OAAO;EAAa;CAClC;EAAE,OAAO;EAAK,OAAO;EAAa;CAClC;EAAE,OAAO;EAAK,OAAO;EAAO;CAC7B;AAED,SAAgB,wBAAwB,OAAsD;AAC5F,SAAQ,OAAR;EACE,KAAK;EACL,KAAK,UACH,QAAO;GAAE,MAAM;GAAG,MAAM;GAAG;EAE7B,QACE,QAAO;GAAE,MAAM;GAAG,MAAM;GAAG;;;AAIjC,SAAgB,2BACd,UAA6C,EAAE,EAC1B;CACrB,MAAM,QAAQ,QAAQ,SAAS;CAC/B,MAAM,QAAQ,QAAQ,SAAS;CAC/B,MAAM,YAAY,QAAQ,aAAa;AAEvC,SAAQ,OAAR;EACE,KAAK,QACH,QAAO;GACL;GACA;GACA;GACA,WAAW;GACX,UAAU,wBAAwB,MAAM;GACxC,MAAM;IACJ,aAAa;IACb,UAAU;KACR,cAAc;KACd,UAAU;KACV,WAAW;KACZ;IACF;GACF;EACH,KAAK,UACH,QAAO;GACL;GACA;GACA;GACA,WAAW;GACX,UAAU,wBAAwB,MAAM;GACxC,MAAM;IACJ,aAAa;IACb,UAAU;KACR,cAAc;KACd,UAAU;KACV,WAAW;KACZ;IACF;GACF;EAEH,QACE,QAAO;GACL,OAAO;GACP;GACA;GACA,WAAW;GACX,UAAU,wBAAwB,OAAO;GACzC,MAAM;IACJ,aAAa;IACb,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];
|
|
3
|
+
type RecordingChromeStyle = (typeof RECORDING_CHROME_STYLES)[number];
|
|
4
|
+
type RecordingChromeAlignment = "center" | "left";
|
|
5
|
+
type RecordingChromeBorderStyle = "round" | "single" | "none";
|
|
6
|
+
type RecordingChromeControlSide = "left" | "right";
|
|
7
|
+
type RecordingChromeSvgWindowBar = "none" | "rings" | "colorful" | "windows";
|
|
8
|
+
interface RecordingChromeOverhead {
|
|
9
|
+
cols: number;
|
|
10
|
+
rows: number;
|
|
11
|
+
}
|
|
12
|
+
interface RecordingChromeControl {
|
|
13
|
+
glyph: string;
|
|
14
|
+
color?: string;
|
|
15
|
+
}
|
|
16
|
+
interface RecordingChromeTitleBarSpec {
|
|
17
|
+
controlsSide: RecordingChromeControlSide;
|
|
18
|
+
controls: readonly RecordingChromeControl[];
|
|
19
|
+
separator: string | null;
|
|
20
|
+
}
|
|
21
|
+
interface RecordingChromeLiveSpec {
|
|
22
|
+
borderStyle: RecordingChromeBorderStyle;
|
|
23
|
+
titleBar: RecordingChromeTitleBarSpec | null;
|
|
24
|
+
}
|
|
25
|
+
interface RecordingChromeSpec {
|
|
26
|
+
style: RecordingChromeStyle;
|
|
27
|
+
title: string;
|
|
28
|
+
alignment: RecordingChromeAlignment;
|
|
29
|
+
hasChrome: boolean;
|
|
30
|
+
overhead: RecordingChromeOverhead;
|
|
31
|
+
live: RecordingChromeLiveSpec;
|
|
32
|
+
}
|
|
33
|
+
interface ComposeRecordingChromeSpecOptions {
|
|
34
|
+
style?: RecordingChromeStyle;
|
|
35
|
+
title?: string;
|
|
36
|
+
alignment?: RecordingChromeAlignment;
|
|
37
|
+
}
|
|
38
|
+
interface RecordingChromeSvgLayout {
|
|
39
|
+
windowBar: RecordingChromeSvgWindowBar;
|
|
40
|
+
windowBarSize: number;
|
|
41
|
+
padding: number;
|
|
42
|
+
borderRadius: number;
|
|
43
|
+
margin: number;
|
|
44
|
+
shadow: number;
|
|
45
|
+
contentOffset: {
|
|
46
|
+
x: number;
|
|
47
|
+
y: number;
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
interface RecordingChromeSvgOptions {
|
|
51
|
+
windowBar?: RecordingChromeSvgWindowBar;
|
|
52
|
+
windowBarSize?: number;
|
|
53
|
+
padding?: number;
|
|
54
|
+
borderRadius?: number;
|
|
55
|
+
margin?: number;
|
|
56
|
+
shadow?: number;
|
|
57
|
+
windowTitle?: string;
|
|
58
|
+
}
|
|
59
|
+
declare function recordingChromeOverhead(style: RecordingChromeStyle): RecordingChromeOverhead;
|
|
60
|
+
declare function composeRecordingChromeSpec(options?: ComposeRecordingChromeSpecOptions): RecordingChromeSpec;
|
|
61
|
+
declare function recordingChromeSvgLayout(spec: RecordingChromeSpec): RecordingChromeSvgLayout;
|
|
62
|
+
declare function recordingChromeSvgContentOffset(spec: RecordingChromeSpec): {
|
|
63
|
+
x: number;
|
|
64
|
+
y: number;
|
|
65
|
+
};
|
|
66
|
+
declare function recordingChromeSpecToSvgOptions(spec: RecordingChromeSpec): RecordingChromeSvgOptions;
|
|
67
|
+
//#endregion
|
|
68
|
+
//#region packages/ag-react/src/ui/recording-chrome/svg.d.ts
|
|
69
|
+
interface ComposeRecordingChromeSvgOptions {
|
|
70
|
+
spec?: RecordingChromeSpec;
|
|
71
|
+
windowBar?: RecordingChromeSvgWindowBar;
|
|
72
|
+
barWidth: number;
|
|
73
|
+
barHeight?: number;
|
|
74
|
+
borderRadius?: number;
|
|
75
|
+
themeBackground: string;
|
|
76
|
+
title?: string | null;
|
|
77
|
+
fontSize?: number;
|
|
78
|
+
}
|
|
79
|
+
declare function composeRecordingChromeSvg(options: ComposeRecordingChromeSvgOptions): string[];
|
|
80
|
+
//#endregion
|
|
81
|
+
export { composeRecordingChromeSpec as _, RecordingChromeAlignment as a, recordingChromeSvgContentOffset as b, RecordingChromeControlSide as c, RecordingChromeSpec as d, RecordingChromeStyle as f, RecordingChromeTitleBarSpec as g, RecordingChromeSvgWindowBar as h, RECORDING_CHROME_STYLES as i, RecordingChromeLiveSpec as l, RecordingChromeSvgOptions as m, composeRecordingChromeSvg as n, RecordingChromeBorderStyle as o, RecordingChromeSvgLayout as p, ComposeRecordingChromeSpecOptions as r, RecordingChromeControl as s, ComposeRecordingChromeSvgOptions as t, RecordingChromeOverhead as u, recordingChromeOverhead as v, recordingChromeSvgLayout as x, recordingChromeSpecToSvgOptions as y };
|
|
82
|
+
//# sourceMappingURL=svg-g1D6ErwR.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"svg-g1D6ErwR.d.mts","names":[],"sources":["../packages/ag-react/src/ui/recording-chrome/spec.ts","../packages/ag-react/src/ui/recording-chrome/svg.ts"],"mappings":";cAAa,uBAAA;AAAA,KAED,oBAAA,WAA+B,uBAAA;AAAA,KAC/B,wBAAA;AAAA,KACA,0BAAA;AAAA,KACA,0BAAA;AAAA,KACA,2BAAA;AAAA,UAEK,uBAAA;EACf,IAAA;EACA,IAAA;AAAA;AAAA,UAGe,sBAAA;EACf,KAAA;EACA,KAAA;AAAA;AAAA,UAGe,2BAAA;EACf,YAAA,EAAc,0BAAA;EACd,QAAA,WAAmB,sBAAA;EACnB,SAAA;AAAA;AAAA,UAGe,uBAAA;EACf,WAAA,EAAa,0BAAA;EACb,QAAA,EAAU,2BAAA;AAAA;AAAA,UAGK,mBAAA;EACf,KAAA,EAAO,oBAAA;EACP,KAAA;EACA,SAAA,EAAW,wBAAA;EACX,SAAA;EACA,QAAA,EAAU,uBAAA;EACV,IAAA,EAAM,uBAAA;AAAA;AAAA,UAGS,iCAAA;EACf,KAAA,GAAQ,oBAAA;EACR,KAAA;EACA,SAAA,GAAY,wBAAA;AAAA;AAAA,UAGG,wBAAA;EACf,SAAA,EAAW,2BAAA;EACX,aAAA;EACA,OAAA;EACA,YAAA;EACA,MAAA;EACA,MAAA;EACA,aAAA;IAAiB,CAAA;IAAW,CAAA;EAAA;AAAA;AAAA,UAGb,yBAAA;EACf,SAAA,GAAY,2BAAA;EACZ,aAAA;EACA,OAAA;EACA,YAAA;EACA,MAAA;EACA,MAAA;EACA,WAAA;AAAA;AAAA,iBAec,uBAAA,CAAwB,KAAA,EAAO,oBAAA,GAAuB,uBAAA;AAAA,iBAWtD,0BAAA,CACd,OAAA,GAAS,iCAAA,GACR,mBAAA;AAAA,iBAsDa,wBAAA,CAAyB,IAAA,EAAM,mBAAA,GAAsB,wBAAA;AAAA,iBA4CrD,+BAAA,CAAgC,IAAA,EAAM,mBAAA;EACpD,CAAA;EACA,CAAA;AAAA;AAAA,iBAKc,+BAAA,CACd,IAAA,EAAM,mBAAA,GACL,yBAAA;;;UC9Lc,gCAAA;EACf,IAAA,GAAO,mBAAA;EACP,SAAA,GAAY,2BAAA;EACZ,QAAA;EACA,SAAA;EACA,YAAA;EACA,eAAA;EACA,KAAA;EACA,QAAA;AAAA;AAAA,iBAuDc,yBAAA,CAA0B,OAAA,EAAS,gCAAA"}
|
package/dist/term.d.mts
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { B as createTerminalProfile, F as defaultCaps, I as ColorProvenance, L as CreateTerminalProfileOptions, P as TerminalCaps, R as ProbeTerminalProfileOptions, V as probeTerminalProfile, z as TerminalProfile } from "./index-CSQf13CI.mjs";
|
|
2
|
+
import { A as term, Dt as SilveryMouseEvent, Et as MouseEventProps, F as ConsoleCaptureOptions, I as ConsoleStats, L as createConsole, M as Term, N as createTerm, Ot as SilveryWheelEvent, _ as createMouseEventProcessor, at as isMouseSequence, b as hitTest, c as HitTarget, d as MouseEventProcessorOptions, f as MouseEventProcessorState, g as createMouseEvent, h as createDoubleClickState, it as ParsedMouse, j as StyleChain, m as computeEnterLeave, nt as ConsoleEntry, o as HitRegion, ot as parseMouseSequence, p as checkDoubleClick, t as BoundTerm, v as createWheelEvent, x as processMouseEvent, y as dispatchMouseEvent } from "./bound-term-0sPrrzH1.mjs";
|
|
3
|
+
export { type BoundTerm, type ColorProvenance, type ConsoleCaptureOptions, type ConsoleEntry, type ConsoleStats, type CreateTerminalProfileOptions, type HitRegion, type HitTarget, type MouseEventProcessorOptions, type MouseEventProcessorState, type MouseEventProps, type ParsedMouse, type ProbeTerminalProfileOptions, type SilveryMouseEvent, type SilveryWheelEvent, type StyleChain, type Term, type TerminalCaps, type TerminalProfile, checkDoubleClick, computeEnterLeave, createConsole, createDoubleClickState, createMouseEvent, createMouseEventProcessor, createTerm, createTerminalProfile, createWheelEvent, defaultCaps, dispatchMouseEvent, hitTest, isMouseSequence, parseMouseSequence, probeTerminalProfile, processMouseEvent, term };
|
package/dist/term.mjs
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { M as createTerminalProfile, N as probeTerminalProfile, ft as defaultCaps, t as init_src } from "./src-BNTToU7l.mjs";
|
|
2
|
+
import { b as parseMouseSequence, i as createConsole, n as createTerm, t as term, y as isMouseSequence } from "./ansi-yC4RyBNY.mjs";
|
|
3
|
+
import { a as createDoubleClickState, c as createWheelEvent, d as hitTest, f as processMouseEvent, l as dispatchMouseEvent, n as checkDoubleClick, o as createMouseEvent, r as computeEnterLeave, s as createMouseEventProcessor } from "./mouse-events-Dki3ISIp.mjs";
|
|
4
|
+
//#region src/term.ts
|
|
5
|
+
init_src();
|
|
6
|
+
//#endregion
|
|
7
|
+
export { checkDoubleClick, computeEnterLeave, createConsole, createDoubleClickState, createMouseEvent, createMouseEventProcessor, createTerm, createTerminalProfile, createWheelEvent, defaultCaps, dispatchMouseEvent, hitTest, isMouseSequence, parseMouseSequence, probeTerminalProfile, processMouseEvent, term };
|
|
8
|
+
|
|
9
|
+
//# sourceMappingURL=term.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"term.mjs","names":[],"sources":["../src/term.ts"],"sourcesContent":["// silvery/term — terminal-specific user-facing surface\n//\n// Companion subpath to the main `silvery` barrel. The main barrel already\n// re-exports the commonly-needed terminal primitives (`Term`, `createTerm`,\n// `TerminalProfile`, `TerminalCaps`, etc.). This module is for terminal-\n// specific *additions* that consumers routinely reach for when they need\n// to interact with mouse events, terminal capabilities, or the bound-term\n// abstraction at a type level.\n//\n// Collisions between this surface and the top-level `silvery` exports are\n// resolved in favor of the top-level barrel — import the widely-used types\n// from `silvery` directly, and come here for the terminal-specific\n// additions.\n//\n// DO NOT `export *` from `@silvery/ag-term` here — the ag-term barrel\n// includes low-level pipeline/buffer/layout internals that should stay\n// internal. Pick the user-facing surface deliberately.\n\n// -----------------------------------------------------------------------------\n// Mouse events (DOM-level synthetic events)\n// -----------------------------------------------------------------------------\n//\n// `SilveryMouseEvent` / `SilveryWheelEvent` are the synthetic event objects\n// dispatched to `onClick`, `onMouseDown`, `onMouseEnter`, `onWheel`, etc.\n// Consumers that hand-roll mouse handlers on React refs type their callbacks\n// with these.\n\nexport {\n hitTest,\n createMouseEvent,\n createWheelEvent,\n dispatchMouseEvent,\n processMouseEvent,\n createMouseEventProcessor,\n checkDoubleClick,\n createDoubleClickState,\n computeEnterLeave,\n type SilveryMouseEvent,\n type SilveryWheelEvent,\n type MouseEventProcessorOptions,\n type MouseEventProcessorState,\n} from \"@silvery/ag-term/mouse-events\"\n\nexport type { MouseEventProps } from \"@silvery/ag/mouse-event-types\"\n\n// -----------------------------------------------------------------------------\n// Mouse parsing (SGR mode 1006 / X10 / any-event)\n// -----------------------------------------------------------------------------\n\nexport { parseMouseSequence, isMouseSequence, type ParsedMouse } from \"@silvery/ag-term/mouse\"\n\n// -----------------------------------------------------------------------------\n// Term — terminal abstraction\n// -----------------------------------------------------------------------------\n//\n// `Term` and `createTerm` are also exported from the main `silvery` barrel.\n// Re-exported here for convenience so terminal-focused code can import from\n// a single `silvery/term` module.\n\nexport { createTerm, term, createConsole } from \"@silvery/ag-term/ansi\"\nexport type {\n Term,\n StyleChain,\n ConsoleCaptureOptions,\n ConsoleStats,\n ConsoleEntry,\n} from \"@silvery/ag-term/ansi\"\n\n// `BoundTerm` — the app-bound term handle returned from `run()` / `render()`.\nexport type { BoundTerm } from \"@silvery/ag-term/bound-term\"\n\n// -----------------------------------------------------------------------------\n// Terminal capabilities & profile\n// -----------------------------------------------------------------------------\n\nexport type { TerminalCaps } from \"@silvery/ag-term/terminal-caps\"\nexport {\n createTerminalProfile,\n probeTerminalProfile,\n defaultCaps,\n type TerminalProfile,\n type ColorProvenance,\n type ProbeTerminalProfileOptions,\n type CreateTerminalProfileOptions,\n} from \"@silvery/ansi\"\n\n// -----------------------------------------------------------------------------\n// Hit registry (mouse dispatch internals useful to advanced consumers)\n// -----------------------------------------------------------------------------\n\nexport type { HitTarget, HitRegion } from \"@silvery/ag-term/hit-registry\"\n"],"mappings":";;;;UAoFsB"}
|
package/dist/theme.d.mts
CHANGED
|
@@ -1,2 +1,95 @@
|
|
|
1
|
-
import { $ as
|
|
2
|
-
|
|
1
|
+
import { $ as BorderRole, G as detectTheme, H as DetectThemeOptions, K as probeColors, Q as AccentRole, S as detectSchemeTheme, U as DetectedScheme, W as detectTerminalScheme, X as ColorScheme, Y as COLOR_SCHEME_FIELDS, _ as DetectSchemeOptions, _t as bakeFlat, at as DeriveOptions, b as SlotSource, ct as FlatTokens, dt as Roles, et as ContrastMode, ft as StatePair, gt as FlattenRule, ht as ThemeShape, it as DerivationTrace, lt as InteractiveRole, mt as Theme, nt as DeepPartial, ot as DesignSystem, pt as SurfaceRole, rt as DerivationStep, st as FlatToken, tt as CursorRole, ut as MutedRole, v as DetectSchemeResult, vt as defaultFlattenRule, x as detectScheme, y as DetectSource } from "./index-CSQf13CI.mjs";
|
|
2
|
+
import { $ as importBase16, A as everforestDark, B as oneDark, C as ayuMirage, D as snazzy, E as materialLight, F as rosePine, G as solarizedLight, H as tokyoNightDay, I as rosePineDawn, J as catppuccinFrappe, K as dracula, L as rosePineMoon, M as kanagawaDragon, N as kanagawaLotus, O as monokai, P as kanagawaWave, Q as exportBase16, R as gruvboxDark, S as ayuLight, T as materialDark, U as tokyoNightStorm, V as tokyoNight, W as solarizedDark, X as catppuccinMacchiato, Y as catppuccinLatte, Z as catppuccinMocha, _ as moonfly, _t as generateTheme, a as defaultDarkTheme, at as ThemeValidationResult, b as nightfox, c as getThemeByName, ct as validateColorScheme, d as edgeDark, dt as presetTheme, et as Base16Scheme, f as edgeLight, ft as quickTheme, g as nightfly, gt as fromPreset, h as oxocarbonLight, ht as fromColors, i as builtinThemes, it as THEME_TOKEN_KEYS, j as everforestLight, k as monokaiPro, l as modusOperandi, lt as autoGenerateTheme, m as oxocarbonDark, mt as fromBase16, n as ansi16LightTheme, nt as resolveAliases, o as defaultLightTheme, ot as validateTheme, p as sonokai, pt as assignPrimaryToSlot, q as nord, r as builtinPalettes, rt as resolveTokenAlias, s as getSchemeByName, st as ValidationResult, t as ansi16DarkTheme, tt as themeToCSSVars, u as modusVivendi, ut as createTheme, v as horizon, w as palenight, x as ayuDark, y as dawnfox, z as gruvboxLight } from "./index-BUMxS65f.mjs";
|
|
3
|
+
|
|
4
|
+
//#region packages/ansi/src/sterling/sterling.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* Sterling — the user-facing DesignSystem. `defineDesignSystem` wraps
|
|
7
|
+
* `rawSterling` with auto-`bakeFlat` (per `flatten: true`), so every
|
|
8
|
+
* returned Theme has both nested roles AND flat hyphen keys populated.
|
|
9
|
+
*/
|
|
10
|
+
declare const sterling: DesignSystem;
|
|
11
|
+
//#endregion
|
|
12
|
+
//#region packages/ansi/src/sterling/define.d.ts
|
|
13
|
+
/**
|
|
14
|
+
* Wrap a DesignSystem so every derivation method auto-applies `bakeFlat`
|
|
15
|
+
* per the `flatten` flag. Pass your raw system (one that returns nested
|
|
16
|
+
* themes) and this returns a user-facing system whose outputs have flat
|
|
17
|
+
* keys populated.
|
|
18
|
+
*/
|
|
19
|
+
declare function defineDesignSystem(def: DesignSystem): DesignSystem;
|
|
20
|
+
//#endregion
|
|
21
|
+
//#region packages/ansi/src/sterling/contrast.d.ts
|
|
22
|
+
/**
|
|
23
|
+
* Sterling contrast guardrails — D3 from sterling-preflight.md.
|
|
24
|
+
*
|
|
25
|
+
* Two modes:
|
|
26
|
+
* - `strict` — throw when a core role pair fails WCAG AA 4.5:1.
|
|
27
|
+
* Used by the catalog test (all 84 shipped schemes must pass).
|
|
28
|
+
* - `auto-lift` — adjust OKLCH lightness until AA passes (±0.04L increments
|
|
29
|
+
* up to ~0.20L). Logs at debug; silent by default. Used for user schemes
|
|
30
|
+
* at runtime.
|
|
31
|
+
*
|
|
32
|
+
* Pinned tokens (per-role overrides supplied by scheme authors) are excluded
|
|
33
|
+
* from auto-lift and from strict-mode enforcement — the author accepts the
|
|
34
|
+
* contrast consequence of pinning.
|
|
35
|
+
*/
|
|
36
|
+
/** WCAG AA threshold for normal text. */
|
|
37
|
+
declare const WCAG_AA = 4.5;
|
|
38
|
+
interface ContrastViolation {
|
|
39
|
+
readonly token: string;
|
|
40
|
+
readonly fg: string;
|
|
41
|
+
readonly bg: string;
|
|
42
|
+
readonly ratio: number;
|
|
43
|
+
readonly target: number;
|
|
44
|
+
}
|
|
45
|
+
declare class ContrastError extends Error {
|
|
46
|
+
readonly violations: readonly ContrastViolation[];
|
|
47
|
+
constructor(violations: readonly ContrastViolation[]);
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Verify `fg` on `bg` meets `target` ratio. Returns `null` when already
|
|
51
|
+
* passing; otherwise returns a ContrastViolation.
|
|
52
|
+
*/
|
|
53
|
+
declare function checkAA(token: string, fg: string, bg: string, target?: number): ContrastViolation | null;
|
|
54
|
+
/**
|
|
55
|
+
* Auto-lift `fg` against `bg` until the `target` contrast ratio is met,
|
|
56
|
+
* via OKLCH L shifts (hue + chroma preserved). Light bg → darken;
|
|
57
|
+
* dark bg → lighten.
|
|
58
|
+
*
|
|
59
|
+
* Implementation note: binary-searches the minimum L shift achieving the
|
|
60
|
+
* target. Falls back to a best-effort value if the target is unreachable
|
|
61
|
+
* (e.g., yellow against white can never hit 4.5:1 at any lightness while
|
|
62
|
+
* preserving yellow hue; the result is the darkest in-gamut yellow).
|
|
63
|
+
*/
|
|
64
|
+
declare function autoLift(fg: string, bg: string, target?: number): {
|
|
65
|
+
value: string;
|
|
66
|
+
lifted: boolean;
|
|
67
|
+
};
|
|
68
|
+
//#endregion
|
|
69
|
+
//#region packages/ansi/src/sterling/derive.d.ts
|
|
70
|
+
/**
|
|
71
|
+
* Derive a Theme's nested roles from a ColorScheme. Guardrails applied.
|
|
72
|
+
*/
|
|
73
|
+
declare function deriveRoles(scheme: ColorScheme, opts: DeriveOptions): {
|
|
74
|
+
roles: Roles;
|
|
75
|
+
mode: "light" | "dark";
|
|
76
|
+
trace: DerivationStep[];
|
|
77
|
+
violations: ContrastViolation[];
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* Derive a full Theme (pre-flatten) from a ColorScheme. Throws `ContrastError`
|
|
81
|
+
* in strict mode if any role pair fails WCAG AA. Callers typically wrap this
|
|
82
|
+
* with `flatten()` (from `flatten.ts`) to get the user-facing Theme.
|
|
83
|
+
*
|
|
84
|
+
* Returned Theme is NOT frozen and DOES NOT contain flat keys yet.
|
|
85
|
+
*/
|
|
86
|
+
declare function deriveTheme(scheme: ColorScheme, opts?: DeriveOptions): Omit<Theme, keyof FlatTokens>;
|
|
87
|
+
//#endregion
|
|
88
|
+
//#region packages/ansi/src/sterling/flat-tokens.d.ts
|
|
89
|
+
declare const STERLING_FLAT_TOKENS: readonly FlatToken[];
|
|
90
|
+
//#endregion
|
|
91
|
+
//#region packages/ansi/src/sterling/defaults.d.ts
|
|
92
|
+
declare function defaultScheme(mode?: "light" | "dark"): ColorScheme;
|
|
93
|
+
//#endregion
|
|
94
|
+
export { AccentRole, Base16Scheme, BorderRole, COLOR_SCHEME_FIELDS, ColorScheme, CursorRole, DesignSystem, DetectSchemeOptions, DetectSchemeResult, DetectSource, DetectThemeOptions, DetectedScheme, FlattenRule, InteractiveRole, MutedRole, STERLING_FLAT_TOKENS, SlotSource, StatePair, ContrastError as SterlingContrastError, ContrastMode as SterlingContrastMode, ContrastViolation as SterlingContrastViolation, DeepPartial as SterlingDeepPartial, DerivationStep as SterlingDerivationStep, DerivationTrace as SterlingDerivationTrace, DeriveOptions as SterlingDeriveOptions, FlatToken as SterlingFlatToken, FlatTokens as SterlingFlatTokens, Roles as SterlingRoles, Theme as SterlingTheme, SurfaceRole, THEME_TOKEN_KEYS, ThemeShape, ThemeValidationResult, ValidationResult, WCAG_AA, ansi16DarkTheme, ansi16LightTheme, assignPrimaryToSlot, autoGenerateTheme, ayuDark, ayuLight, ayuMirage, bakeFlat, builtinPalettes, builtinThemes, catppuccinFrappe, catppuccinLatte, catppuccinMacchiato, catppuccinMocha, createTheme, dawnfox, defaultDarkTheme, defaultFlattenRule, defaultLightTheme, defineDesignSystem, detectScheme, detectSchemeTheme, detectTerminalScheme, detectTheme, dracula, edgeDark, edgeLight, everforestDark, everforestLight, exportBase16, fromBase16, fromColors, fromPreset, generateTheme, getSchemeByName, getThemeByName, gruvboxDark, gruvboxLight, horizon, importBase16, kanagawaDragon, kanagawaLotus, kanagawaWave, materialDark, materialLight, modusOperandi, modusVivendi, monokai, monokaiPro, moonfly, nightfly, nightfox, nord, oneDark, oxocarbonDark, oxocarbonLight, palenight, presetTheme, probeColors, quickTheme, resolveAliases, resolveTokenAlias, rosePine, rosePineDawn, rosePineMoon, snazzy, solarizedDark, solarizedLight, sonokai, sterling, autoLift as sterlingAutoLift, checkAA as sterlingCheckAA, defaultScheme as sterlingDefaultScheme, deriveRoles as sterlingDeriveRoles, deriveTheme as sterlingDeriveTheme, themeToCSSVars, tokyoNight, tokyoNightDay, tokyoNightStorm, validateColorScheme, validateTheme };
|
|
95
|
+
//# sourceMappingURL=theme.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme.d.mts","names":[],"sources":["../packages/ansi/src/sterling/sterling.ts","../packages/ansi/src/sterling/define.ts","../packages/ansi/src/sterling/contrast.ts","../packages/ansi/src/sterling/derive.ts","../packages/ansi/src/sterling/flat-tokens.ts","../packages/ansi/src/sterling/defaults.ts"],"mappings":";;;;;;;;AEkBA;cFgJa,QAAA,EAAU,YAAA;;;;;;;;;iBC1GP,kBAAA,CAAmB,GAAA,EAAK,YAAA,GAAe,YAAA;;;;;;;AD0GvD;;;;;;;;AC1GA;;;cCtCa,OAAA;AAAA,UAYI,iBAAA;EAAA,SACN,KAAA;EAAA,SACA,EAAA;EAAA,SACA,EAAA;EAAA,SACA,KAAA;EAAA,SACA,MAAA;AAAA;AAAA,cAGE,aAAA,SAAsB,KAAA;EAAA,SACxB,UAAA,WAAqB,iBAAA;cAClB,UAAA,WAAqB,iBAAA;AAAA;;;;;iBAgBnB,OAAA,CACd,KAAA,UACA,EAAA,UACA,EAAA,UACA,MAAA,YACC,iBAAA;;;;;;;;;;;iBAiBa,QAAA,CACd,EAAA,UACA,EAAA,UACA,MAAA;EACG,KAAA;EAAe,MAAA;AAAA;;;;;AA5CpB;iBCiRgB,WAAA,CACd,MAAA,EAAQ,WAAA,EACR,IAAA,EAAM,aAAA;EAEN,KAAA,EAAO,KAAA;EACP,IAAA;EACA,KAAA,EAAO,cAAA;EACP,UAAA,EAAY,iBAAA;AAAA;;;;;;;;iBAmlBE,WAAA,CACd,MAAA,EAAQ,WAAA,EACR,IAAA,GAAM,aAAA,GACL,IAAA,CAAK,KAAA,QAAK,UAAA;;;cCv4BA,oBAAA,WAA+B,SAAA;;;iBCwD5B,aAAA,CAAc,IAAA,sBAAkC,WAAA"}
|
package/dist/theme.mjs
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
1
|
+
import { D as bakeFlat, L as detectTerminalScheme, O as defaultFlattenRule, R as detectTheme, a as STERLING_FLAT_TOKENS, at as deriveRoles, c as detectScheme, ct as WCAG_AA, i as defaultScheme, l as detectSchemeTheme, lt as autoLift, n as sterling, ot as deriveTheme, r as defineDesignSystem, st as ContrastError, u as COLOR_SCHEME_FIELDS, ut as checkAA, z as probeColors } from "./src-BNTToU7l.mjs";
|
|
2
|
+
import { A as monokaiPro, B as gruvboxLight, C as ayuLight, D as materialLight, E as materialDark, F as kanagawaWave, G as solarizedDark, H as tokyoNight, I as rosePine, J as nord, K as solarizedLight, L as rosePineDawn, M as everforestLight, N as kanagawaDragon, O as snazzy, P as kanagawaLotus, Q as catppuccinMocha, R as rosePineMoon, S as ayuDark, T as palenight, U as tokyoNightDay, V as oneDark, W as tokyoNightStorm, X as catppuccinLatte, Y as catppuccinFrappe, Z as catppuccinMacchiato, _ as nightfly, a as defaultDarkTheme, b as dawnfox, c as getThemeByName, d as modusVivendi, f as edgeDark, g as oxocarbonLight, h as oxocarbonDark, i as builtinThemes, j as everforestDark, k as monokai, m as sonokai, n as ansi16LightTheme, o as defaultLightTheme, p as edgeLight, q as dracula, r as builtinPalettes, s as getSchemeByName, t as ansi16DarkTheme, u as modusOperandi, v as moonfly, w as ayuMirage, x as nightfox, y as horizon, z as gruvboxDark } from "./schemes-JjNp4aSl.mjs";
|
|
3
|
+
import { _ as fromPreset, a as resolveAliases, c as validateTheme, d as createTheme, f as presetTheme, g as fromColors, h as fromBase16, i as themeToCSSVars, l as validateColorScheme, m as assignPrimaryToSlot, o as resolveTokenAlias, p as quickTheme, r as exportBase16, s as THEME_TOKEN_KEYS, t as init_src, u as autoGenerateTheme, v as importBase16, y as generateTheme } from "./src-5w9QR6_8.mjs";
|
|
4
|
+
//#region src/theme.ts
|
|
5
|
+
init_src();
|
|
6
|
+
//#endregion
|
|
7
|
+
export { COLOR_SCHEME_FIELDS, STERLING_FLAT_TOKENS, ContrastError as SterlingContrastError, THEME_TOKEN_KEYS, WCAG_AA, ansi16DarkTheme, ansi16LightTheme, assignPrimaryToSlot, autoGenerateTheme, ayuDark, ayuLight, ayuMirage, bakeFlat, builtinPalettes, builtinThemes, catppuccinFrappe, catppuccinLatte, catppuccinMacchiato, catppuccinMocha, createTheme, dawnfox, defaultDarkTheme, defaultFlattenRule, defaultLightTheme, defineDesignSystem, detectScheme, detectSchemeTheme, detectTerminalScheme, detectTheme, dracula, edgeDark, edgeLight, everforestDark, everforestLight, exportBase16, fromBase16, fromColors, fromPreset, generateTheme, getSchemeByName, getThemeByName, gruvboxDark, gruvboxLight, horizon, importBase16, kanagawaDragon, kanagawaLotus, kanagawaWave, materialDark, materialLight, modusOperandi, modusVivendi, monokai, monokaiPro, moonfly, nightfly, nightfox, nord, oneDark, oxocarbonDark, oxocarbonLight, palenight, presetTheme, probeColors, quickTheme, resolveAliases, resolveTokenAlias, rosePine, rosePineDawn, rosePineMoon, snazzy, solarizedDark, solarizedLight, sonokai, sterling, autoLift as sterlingAutoLift, checkAA as sterlingCheckAA, defaultScheme as sterlingDefaultScheme, deriveRoles as sterlingDeriveRoles, deriveTheme as sterlingDeriveTheme, themeToCSSVars, tokyoNight, tokyoNightDay, tokyoNightStorm, validateColorScheme, validateTheme };
|
|
8
|
+
|
|
9
|
+
//# sourceMappingURL=theme.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme.mjs","names":[],"sources":["../src/theme.ts"],"sourcesContent":["// silvery/theme — re-exports from @silvery/theme\n// Theme tokens, palettes, ThemeProvider, useTheme, color utilities\n\nexport * from \"@silvery/theme\"\n"],"mappings":""}
|
|
@@ -89,19 +89,6 @@ interface WithSpinnerOptions {
|
|
|
89
89
|
/** Color for the spinner */
|
|
90
90
|
color?: string;
|
|
91
91
|
}
|
|
92
|
-
/** Options for withProgress wrapper */
|
|
93
|
-
interface WithProgressOptions {
|
|
94
|
-
/** Map of phase keys to display names */
|
|
95
|
-
phases?: Record<string, string>;
|
|
96
|
-
/** Format string for progress bar */
|
|
97
|
-
format?: string;
|
|
98
|
-
/** Clear output on completion */
|
|
99
|
-
clearOnComplete?: boolean;
|
|
100
|
-
/** Show initial loading message after this many ms (default: 1000). Set to 0 to show immediately. */
|
|
101
|
-
showAfter?: number;
|
|
102
|
-
/** Initial loading message to show before progress starts (default: "Loading...") */
|
|
103
|
-
initialMessage?: string;
|
|
104
|
-
}
|
|
105
92
|
/** Task state for Tasks component */
|
|
106
93
|
interface TaskState {
|
|
107
94
|
id: string;
|
|
@@ -237,5 +224,5 @@ interface WithSelectOptions {
|
|
|
237
224
|
maxVisible?: number;
|
|
238
225
|
}
|
|
239
226
|
//#endregion
|
|
240
|
-
export { TextInputOptions as _, ProgressInfo as a,
|
|
241
|
-
//# sourceMappingURL=types-
|
|
227
|
+
export { TextInputOptions as _, ProgressInfo as a, WithSpinnerOptions as b, SpinnerOptions as c, StepProgress as d, TableColumn as f, TaskStatus as g, TaskState as h, ProgressGenerator as i, SpinnerProps as l, TaskProps as m, ProgressBarProps as n, SelectOption as o, TableProps as p, ProgressCallback as r, SelectProps as s, ProgressBarOptions as t, SpinnerStyle as u, TextInputProps as v, WithSelectOptions as y };
|
|
228
|
+
//# sourceMappingURL=types-kt_fKR37.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types-kt_fKR37.d.mts","names":[],"sources":["../packages/ag-react/src/ui/types.ts"],"mappings":";;AAKA;;;UAAiB,YAAA;EACf,KAAA;EACA,OAAA;EACA,KAAA;EACA,MAAA;AAAA;;AAiBF;;;;;;;;;AAUA;;;;UAViB,YAAA;EAaL;EAXV,KAAA;EAW2B;EAT3B,OAAA;EAS4B;EAP5B,KAAA;AAAA;;KAIU,gBAAA,IAAoB,IAAA,EAAM,YAAA;;KAG1B,iBAAA,aAA8B,SAAA;EAAY,OAAA;EAAiB,KAAA;AAAA,GAAiB,CAAA;;KAG5E,YAAA;AAGZ;AAAA,KAAY,UAAA;;UAGK,cAAA;EAHK;EAKpB,IAAA;EAF6B;EAI7B,KAAA,GAAQ,YAAA;EAImB;EAF3B,KAAA;EAFA;EAIA,MAAA,GAAS,MAAA,CAAO,WAAA;EAFhB;EAIA,UAAA;EAFS;EAIT,QAAA;AAAA;;UAIe,kBAAA;EAJP;EAMR,KAAA;EAFiC;EAIjC,MAAA;EAgBe;EAdf,KAAA;EAFA;EAIA,QAAA;EAAA;EAEA,UAAA;EAE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AQ1B,KAAA;AAAA;;UAIe,UAAA;EANf;EAQA,OAAA,EAAS,WAAA;EANJ;EAQL,IAAA,EAAM,KAAA,CAAM,MAAA;EAJG;EAMf,MAAA;AAAA;;UAIe,YAAA;EANT;EAQN,KAAA;EARW;EAUX,KAAA,EAAO,CAAA;AAAA;;UAIQ,WAAA;EAdH;EAgBZ,OAAA,EAAS,YAAA,CAAa,CAAA;EAdhB;EAgBN,KAAA,GAAQ,CAAA;EAZO;EAcf,QAAA,IAAY,KAAA,EAAO,CAAA;EAdQ;EAgB3B,UAAA;EAhB4B;EAkB5B,cAAA;EAdA;EAgBA,iBAAA,IAAqB,KAAA;AAAA;;UAIN,iBAAA;EAhBW;EAkB1B,OAAA;EAhBsB;EAkBtB,UAAA;AAAA"}
|
package/dist/ui/animation.d.mts
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { i as resolveEasing, n as EasingName, r as easings, t as EasingFn } from "../easing-BI-ASGMO.mjs";
|
|
2
|
+
import { a as useTransition, c as useAnimation, i as UseTransitionOptions, n as useTimeout, o as UseAnimationOptions, r as useInterval, s as UseAnimationResult, t as useLatest } from "../useLatest-DRDDVwjh.mjs";
|
|
2
3
|
export { EasingFn, EasingName, UseAnimationOptions, UseAnimationResult, UseTransitionOptions, easings, resolveEasing, useTransition as useAnimatedTransition, useAnimation, useInterval, useLatest, useTimeout };
|
package/dist/ui/animation.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as useAnimation, i as useTransition, n as useTimeout, o as easings, r as useInterval, s as resolveEasing, t as useLatest } from "../animation-
|
|
1
|
+
import { a as useAnimation, i as useTransition, n as useTimeout, o as easings, r as useInterval, s as resolveEasing, t as useLatest } from "../animation-ZMN2_XKv.mjs";
|
|
2
2
|
export { easings, resolveEasing, useTransition as useAnimatedTransition, useAnimation, useInterval, useLatest, useTimeout };
|
package/dist/ui/ansi.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as CURSOR_RESTORE, c as CURSOR_TO_START, d as getTerminalWidth, f as isTTY, h as writeLine, i as CURSOR_HIDE, l as cursorDown, m as write, n as CLEAR_LINE_END, o as CURSOR_SAVE, p as withCursor, r as CLEAR_SCREEN, s as CURSOR_SHOW, t as CLEAR_LINE, u as cursorUp } from "../ansi-
|
|
1
|
+
import { a as CURSOR_RESTORE, c as CURSOR_TO_START, d as getTerminalWidth, f as isTTY, h as writeLine, i as CURSOR_HIDE, l as cursorDown, m as write, n as CLEAR_LINE_END, o as CURSOR_SAVE, p as withCursor, r as CLEAR_SCREEN, s as CURSOR_SHOW, t as CLEAR_LINE, u as cursorUp } from "../ansi-2Xn0yatP.mjs";
|
|
2
2
|
export { CLEAR_LINE, CLEAR_LINE_END, CLEAR_SCREEN, CURSOR_HIDE, CURSOR_RESTORE, CURSOR_SAVE, CURSOR_SHOW, CURSOR_TO_START, cursorDown, cursorUp, getTerminalWidth, isTTY, withCursor, write, writeLine };
|
package/dist/ui/ansi.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as CURSOR_RESTORE, c as CURSOR_TO_START, d as getTerminalWidth, f as isTTY, h as writeLine, i as CURSOR_HIDE, l as cursorDown, m as write, n as CLEAR_LINE_END, o as CURSOR_SAVE, p as withCursor, r as CLEAR_SCREEN, s as CURSOR_SHOW, t as CLEAR_LINE, u as cursorUp } from "../ansi-
|
|
1
|
+
import { a as CURSOR_RESTORE, c as CURSOR_TO_START, d as getTerminalWidth, f as isTTY, h as writeLine, i as CURSOR_HIDE, l as cursorDown, m as write, n as CLEAR_LINE_END, o as CURSOR_SAVE, p as withCursor, r as CLEAR_SCREEN, s as CURSOR_SHOW, t as CLEAR_LINE, u as cursorUp } from "../ansi-D1KQMAbf.mjs";
|
|
2
2
|
export { CLEAR_LINE, CLEAR_LINE_END, CLEAR_SCREEN, CURSOR_HIDE, CURSOR_RESTORE, CURSOR_SAVE, CURSOR_SHOW, CURSOR_TO_START, cursorDown, cursorUp, getTerminalWidth, isTTY, withCursor, write, writeLine };
|