Skip to content

Commit 8ddc74f

Browse files
committed
raycast: address greptile review on raycast/extensions#27449
Mirrors the fixes pushed to the PR branch: - arguments block on copy-cli - drop @raycast/utils - Preferences.Extract instead of manual Prefs - Designlang title-case - CHANGELOG.md
1 parent 991fec4 commit 8ddc74f

3 files changed

Lines changed: 20 additions & 7 deletions

File tree

raycast-extension/CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Designlang Changelog
2+
3+
## [Initial Release] - {PR_MERGE_DATE}
4+
5+
- **Extract Design From URL** — runs `npx designlang <url>` and opens the output folder when ready. Optional "full" toggle pulls screenshots, responsive captures, and interaction states.
6+
- **Score Website Design** — rates a site's design-system quality across 7 categories (color discipline, typography, spacing, shadows, radii, accessibility, tokenization) and reports an overall A–F grade.
7+
- **Copy CLI Command For URL** — accepts a URL argument and copies `npx designlang <url>` to the clipboard.
8+
- One preference: `outputDir` (default `~/designlang-output`).

raycast-extension/package.json

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"$schema": "https://www.raycast.com/schemas/extension.json",
33
"name": "designlang",
4-
"title": "designlang",
4+
"title": "Designlang",
55
"description": "Extract design tokens from any website — colors, typography, spacing, shadows, shadcn/Tailwind/Figma outputs.",
66
"icon": "icon.png",
77
"author": "masyv",
@@ -25,7 +25,15 @@
2525
"name": "copy-cli",
2626
"title": "Copy CLI Command For URL",
2727
"description": "Copy `npx designlang <url>` to your clipboard.",
28-
"mode": "no-view"
28+
"mode": "no-view",
29+
"arguments": [
30+
{
31+
"name": "url",
32+
"placeholder": "https://stripe.com",
33+
"type": "text",
34+
"required": true
35+
}
36+
]
2937
}
3038
],
3139
"preferences": [
@@ -39,8 +47,7 @@
3947
}
4048
],
4149
"dependencies": {
42-
"@raycast/api": "^1.80.0",
43-
"@raycast/utils": "^1.17.0"
50+
"@raycast/api": "^1.80.0"
4451
},
4552
"devDependencies": {
4653
"@raycast/eslint-config": "^1.0.0",

raycast-extension/src/extract.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ import { execFile } from "child_process";
1111
import { homedir } from "os";
1212
import { useState } from "react";
1313

14-
type Prefs = { outputDir?: string };
15-
1614
function resolveOutputDir(raw?: string) {
1715
const v = (raw || "~/designlang-output").trim();
1816
return v.startsWith("~") ? v.replace(/^~/, homedir()) : v;
@@ -24,7 +22,7 @@ function normalizeUrl(u: string) {
2422
}
2523

2624
export default function Command() {
27-
const prefs = getPreferenceValues<Prefs>();
25+
const prefs = getPreferenceValues<Preferences.Extract>();
2826
const [url, setUrl] = useState("");
2927
const [full, setFull] = useState(false);
3028

0 commit comments

Comments
 (0)