Skip to content

Commit 2525f37

Browse files
v0.7.2
# v0.7.2 — Provider Presets, Island System & Bug Fixes --- ## Features - **Island system** — extracted `Island` and `IslandFollowUpContentView` into the shared `@craft-agent/ui` package as reusable primitives for annotation follow-ups and inline content expansion (7c4ba6af, 2432b421, 4397b284) - **Minimax provider preset** — added Minimax as a built-in LLM connection preset with pre-configured base URL and model list (36cf45d5) - **Kimi (Coding) provider preset** — added Moonshot's Kimi Coding as a built-in LLM connection preset (c59d9d8d) - **OpenAI regional presets** — added OpenAI EU (`api.openai.eu`) and US (`api.openai.us`) regional API endpoint presets (bfc2be3c) - **App-level default thinking level** — thinking level (off / think / max) can now be set as an app-wide default that persists across sessions and app restarts; workspace-level overrides take precedence (f5593fb1, 7c0f2659) - **Local dev build mode** — new `CRAFT_DEV_RUNTIME` build flag resolves SDK and interceptor from the monorepo during development, with platform-aware bun fallback; adds `electron:dist:dev:{mac,win,linux}` scripts (506f2b02) ## Improvements - **Deferred SDK checks** — Anthropic SDK and runtime validation is now deferred from app startup to session creation (`strict: false` at boot, `strict: true` at session start), allowing the app to open windows even when SDK/interceptor/Bun are not yet available (cc70ce76) - **Staged typecheck flow** — pre-commit hook now runs targeted typecheck only on packages touched by staged files instead of a full monorepo typecheck (538b12f4) - **Toast theming** — Sonner toast description text and close button now respect the active theme tokens instead of using hardcoded colors (59cfeab4, caea757f) - **Branch creation hardening** — strict SDK-fork semantics for new branches; non-whitespace preflight prompt prevents Anthropic `invalid_request` errors on branched sessions (9a2f5ed2) ## Bug Fixes - **Google OAuth error misclassification** — `access_denied` from a user clicking Cancel was incorrectly shown as "app is blocked by administrator"; fixed the boolean logic (`||` → `&&`) so the special message only appears when Google's error description mentions verification. Fixes [#300](#300) (partially) - **Status icon overrides ignored** — local status icon filenames were not being discovered due to a missing directory scan; also added `.webp` support to the icon filename pattern. Fixes [#358](#358) (f40d2e41, 0ffee7f6, c11819ef) - **Pi provider routing** — custom endpoints now correctly resolve the `piAuthProvider` field instead of requiring a preset selection. Fixes [#363](#363) (f40d2e41) - **Shared session still accessible after delete** — session delete now revokes the viewer share link via a DELETE request with a 5-second timeout, preventing deleted sessions from remaining publicly accessible. Fixes [#328](#328) (15e4830e, c11819ef) - **@mention autocomplete breaks after space** — file matching now uses subsequence search instead of prefix matching, so `app comp` correctly matches `app/components/...`. Fixes [#298](#298) (c939d930) - **CI bun.lock drift** — refreshed `bun.lock` and pinned bun version in CI to prevent `--frozen-lockfile` failures. Fixes [#359](#359) (9e9cebd2, 15e4830e) - **Transport banner overlaps TopBar** — the reconnection banner's Retry button was hidden behind the TopBar's help button; fixed by lifting the 48px TopBar offset to the shared parent container (71abeda4) - **Pi session directory on Windows** — session files were created in the wrong directory on Windows due to a path separator issue (d3e83985) - **Copilot OAuth subpath** — fixed incorrect OAuth callback path for Pi-based copilot authentication flows (430c6f3d) - **Connection error diagnostics** — client-only mode is now logged on startup; connection error messages include the server URL for easier debugging (ff7cf0b8) --- Special thanks to [@dragonguy888](https://github.com/dragonguy888), [@chouch0u](https://github.com/chouch0u), [@DocplannerLech](https://github.com/DocplannerLech), [@thomaszdxsn](https://github.com/thomaszdxsn), and [@ImLukeF](https://github.com/ImLukeF) for their PR contributions, and to [@jonzhan](https://github.com/jonzhan), [@Novtopro](https://github.com/Novtopro), [@lloydwu](https://github.com/lloydwu), [@alexzadeh](https://github.com/alexzadeh), [@galaxyboyleo](https://github.com/galaxyboyleo), and [@minak-collab](https://github.com/minak-collab) for reporting the issues addressed in this release.
1 parent 56fdf95 commit 2525f37

File tree

229 files changed

+14807
-2185
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

229 files changed

+14807
-2185
lines changed

.github/workflows/validate-server.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
- name: Setup Bun
1616
uses: oven-sh/setup-bun@v2
1717
with:
18-
bun-version: latest
18+
bun-version: "1.3.10"
1919

2020
- name: Install dependencies
2121
run: bun install --frozen-lockfile

.github/workflows/validate.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- name: Setup Bun
2323
uses: oven-sh/setup-bun@v2
2424
with:
25-
bun-version: latest
25+
bun-version: "1.3.10"
2626

2727
- name: Install uv
2828
uses: astral-sh/setup-uv@v5

apps/cli/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@craft-agent/cli",
3-
"version": "0.7.1",
3+
"version": "0.7.2",
44
"description": "Terminal client for Craft Agent server",
55
"type": "module",
66
"main": "src/index.ts",

apps/electron/electron-builder.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
appId: com.lukilabs.craft-agent
22
productName: Craft Agents
3-
copyright: Copyright © 2025 Craft Docs Ltd.
3+
copyright: Copyright © 2026 Craft Docs Ltd.
44

55
electronVersion: "39.2.7"
66

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
import { describe, expect, it } from 'bun:test'
2+
import { Linter } from 'eslint'
3+
import { createRequire } from 'node:module'
4+
5+
const require = createRequire(import.meta.url)
6+
const rule = require('../no-hardcoded-z-index.cjs')
7+
8+
function runRule(code: string) {
9+
const linter = new Linter({ configType: 'eslintrc' })
10+
linter.defineRule('craft-styles/no-hardcoded-z-index', rule)
11+
12+
return linter.verify(code, {
13+
parserOptions: {
14+
ecmaVersion: 'latest',
15+
sourceType: 'module',
16+
},
17+
rules: {
18+
'craft-styles/no-hardcoded-z-index': 'error',
19+
},
20+
})
21+
}
22+
23+
describe('no-hardcoded-z-index (electron)', () => {
24+
it('flags hardcoded default in destructured props', () => {
25+
const messages = runRule('function Comp({ zIndex = 50 }) { return zIndex }')
26+
expect(messages.length).toBe(1)
27+
expect(messages[0]?.message).toContain('Avoid hardcoded zIndex values')
28+
})
29+
30+
it('flags hardcoded default in object destructuring', () => {
31+
const messages = runRule('const { zIndex = 50 } = props')
32+
expect(messages.length).toBe(1)
33+
})
34+
35+
it('allows token-based zIndex default values', () => {
36+
const messages = runRule("const { zIndex = 'var(--z-floating-menu, 400)' } = props")
37+
expect(messages.length).toBe(0)
38+
})
39+
40+
it('continues to flag hardcoded style zIndex literals', () => {
41+
const messages = runRule('const style = { zIndex: 400 }')
42+
expect(messages.length).toBe(1)
43+
})
44+
})

apps/electron/eslint-rules/no-hardcoded-z-index.cjs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,10 @@ module.exports = {
103103
)
104104
}
105105

106+
function isZIndexIdentifier(node) {
107+
return node && node.type === 'Identifier' && node.name === 'zIndex'
108+
}
109+
106110
return {
107111
Property(node) {
108112
if (!isZIndexPropertyName(node.key)) return
@@ -111,6 +115,13 @@ module.exports = {
111115
}
112116
},
113117

118+
AssignmentPattern(node) {
119+
if (!isZIndexIdentifier(node.left)) return
120+
if (isHardcodedLiteralValue(node.right)) {
121+
context.report({ node: node.right, messageId: 'noHardcodedZIndex' })
122+
}
123+
},
124+
114125
AssignmentExpression(node) {
115126
if (!isStyleZIndexMemberExpression(node.left)) return
116127
if (isHardcodedLiteralValue(node.right)) {

apps/electron/eslint-rules/no-nonstandard-shadows.cjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ module.exports = {
5050
'shadow-thin',
5151
'shadow-middle',
5252
'shadow-strong',
53-
'shadow-focused',
53+
'shadow-panel-focused',
5454
'shadow-modal-small',
5555
'shadow-bottom-border',
5656
'shadow-bottom-border-thin',

apps/electron/eslint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ export default [
125125
'shadow-thin',
126126
'shadow-middle',
127127
'shadow-strong',
128-
'shadow-focused',
128+
'shadow-panel-focused',
129129
'shadow-modal-small',
130130
'shadow-bottom-border',
131131
'shadow-bottom-border-thin',

apps/electron/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@craft-agent/electron",
3-
"version": "0.7.1",
3+
"version": "0.7.2",
44
"description": "Electron desktop app for Craft Agents",
55
"main": "dist/main.cjs",
66
"private": true,
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/sh
2+
ENTRY="${CRAFT_COMMANDS_ENTRY:-$CRAFT_CLI_ENTRY}"
3+
export CRAFT_CLI_JSON_ONLY="${CRAFT_CLI_JSON_ONLY:-1}"
4+
exec "${CRAFT_BUN:-bun}" run "$ENTRY" "$@"

0 commit comments

Comments
 (0)