portable-agent-layer 0.43.1 → 0.44.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.
|
@@ -12,7 +12,7 @@ const DEFAULT_PALETTE = [
|
|
|
12
12
|
];
|
|
13
13
|
|
|
14
14
|
function colorForLevel(index: number, total: number, palette: string[]): string {
|
|
15
|
-
if (total <= 1) return palette
|
|
15
|
+
if (total <= 1) return palette.at(-1) ?? palette[0];
|
|
16
16
|
const t = index / (total - 1); // 0..1
|
|
17
17
|
const pos = t * (palette.length - 1);
|
|
18
18
|
return palette[Math.round(pos)];
|
|
@@ -20,7 +20,7 @@ function colorForLevel(index: number, total: number, palette: string[]): string
|
|
|
20
20
|
|
|
21
21
|
// Mix a hex color toward white by `amount` (0..1). 0.9 → soft tint.
|
|
22
22
|
function lighten(hex: string, amount: number): string {
|
|
23
|
-
const m =
|
|
23
|
+
const m = /^#([0-9a-f]{6})$/i.exec(hex);
|
|
24
24
|
if (!m) return hex;
|
|
25
25
|
const n = parseInt(m[1], 16);
|
|
26
26
|
const r = (n >> 16) & 255;
|
|
@@ -22,7 +22,7 @@ interface ScoreBadgeProps {
|
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
function step(score: number, maxScore: number, palette: typeof DEFAULT_STEPS) {
|
|
25
|
-
if (maxScore <= 1) return palette
|
|
25
|
+
if (maxScore <= 1) return palette.at(-1) ?? palette[0];
|
|
26
26
|
const clamped = Math.max(1, Math.min(score, maxScore));
|
|
27
27
|
const t = (clamped - 1) / (maxScore - 1);
|
|
28
28
|
const idx = Math.round(t * (palette.length - 1));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "portable-agent-layer",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.44.0",
|
|
4
4
|
"description": "PAL — Portable Agent Layer: persistent personal context for AI coding assistants",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -63,6 +63,7 @@
|
|
|
63
63
|
"@biomejs/biome": "2.4.15",
|
|
64
64
|
"@commitlint/cli": "21.0.1",
|
|
65
65
|
"@commitlint/config-conventional": "21.0.1",
|
|
66
|
+
"@konvert7/klint": "0.19.2",
|
|
66
67
|
"@opencode-ai/plugin": "latest",
|
|
67
68
|
"@semantic-release/changelog": "^6.0.3",
|
|
68
69
|
"@semantic-release/git": "^10.0.1",
|
|
@@ -79,7 +80,6 @@
|
|
|
79
80
|
},
|
|
80
81
|
"dependencies": {
|
|
81
82
|
"@clack/prompts": "^1.4.0",
|
|
82
|
-
"@konvert7/klint": "0.4.0",
|
|
83
83
|
"adm-zip": "^0.5.17",
|
|
84
84
|
"marked": "18.0.4",
|
|
85
85
|
"pdf-lib": "1.17.1",
|