@frontman-ai/astro 0.1.3 → 0.1.5

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/index.d.ts ADDED
@@ -0,0 +1,75 @@
1
+ import type { AstroIntegration } from "astro";
2
+
3
+ export interface FrontmanConfig {
4
+ /**
5
+ * Path to the project root directory.
6
+ * @default process.env.PROJECT_ROOT || process.env.PWD || "."
7
+ */
8
+ projectRoot?: string;
9
+
10
+ /**
11
+ * Root for resolving source file paths from Astro's `data-astro-source-file` attributes.
12
+ * In a monorepo, this is typically the monorepo root.
13
+ * @default projectRoot
14
+ */
15
+ sourceRoot?: string;
16
+
17
+ /**
18
+ * URL prefix for Frontman routes (UI and API endpoints).
19
+ * @default "frontman"
20
+ */
21
+ basePath?: string;
22
+
23
+ /**
24
+ * Server name included in tool responses.
25
+ * @default "frontman-astro"
26
+ */
27
+ serverName?: string;
28
+
29
+ /**
30
+ * Server version included in tool responses.
31
+ * @default "1.0.0"
32
+ */
33
+ serverVersion?: string;
34
+
35
+ /**
36
+ * Frontman server host for client connections.
37
+ * Can also be set via the `FRONTMAN_HOST` environment variable.
38
+ * @default "api.frontman.sh"
39
+ */
40
+ host?: string;
41
+
42
+ /**
43
+ * URL to the Frontman client bundle. Override for custom client builds.
44
+ * Must include a `host` query parameter.
45
+ * @default auto-generated from host
46
+ */
47
+ clientUrl?: string;
48
+
49
+ /**
50
+ * Use a light theme for the Frontman UI.
51
+ * @default false
52
+ */
53
+ isLightTheme?: boolean;
54
+ }
55
+
56
+ /**
57
+ * Astro integration for Frontman — AI-powered development tools.
58
+ *
59
+ * @example
60
+ * ```js
61
+ * import { defineConfig } from 'astro/config';
62
+ * import frontman from '@frontman-ai/astro';
63
+ *
64
+ * export default defineConfig({
65
+ * integrations: [frontman({ projectRoot: import.meta.dirname })],
66
+ * });
67
+ * ```
68
+ */
69
+ export default function frontman(config?: FrontmanConfig): AstroIntegration;
70
+
71
+ /**
72
+ * Named export of the integration factory.
73
+ * Alias for the default export.
74
+ */
75
+ export { frontman as frontmanIntegration };
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@frontman-ai/astro",
3
- "version": "0.1.3",
3
+ "version": "0.1.5",
4
4
  "description": "Astro integration for Frontman",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Frontman AI",
7
7
  "repository": {
8
8
  "type": "git",
9
- "url": "https://github.com/frontman-ai/frontman.git",
9
+ "url": "git+https://github.com/frontman-ai/frontman.git",
10
10
  "directory": "libs/frontman-astro"
11
11
  },
12
12
  "homepage": "https://frontman.sh",
@@ -14,23 +14,29 @@
14
14
  "url": "https://github.com/frontman-ai/frontman/issues"
15
15
  },
16
16
  "keywords": [
17
- "frontman",
18
17
  "astro",
18
+ "astro-integration",
19
+ "withastro",
20
+ "frontman",
21
+ "devtools",
22
+ "dev-toolbar",
19
23
  "ai",
20
24
  "development"
21
25
  ],
22
26
  "type": "module",
23
27
  "main": "./dist/index.js",
28
+ "types": "./index.d.ts",
24
29
  "exports": {
25
- ".": "./dist/index.js",
30
+ ".": {
31
+ "types": "./index.d.ts",
32
+ "import": "./dist/index.js"
33
+ },
26
34
  "./integration": "./dist/integration.js",
27
35
  "./toolbar": "./dist/toolbar.js"
28
36
  },
29
- "bin": {
30
- "frontman-ai-astro": "./dist/cli.js"
31
- },
32
37
  "files": [
33
38
  "dist",
39
+ "index.d.ts",
34
40
  "README.md"
35
41
  ],
36
42
  "scripts": {
@@ -39,6 +45,9 @@
39
45
  "build": "yarn build:rescript && yarn build:bundle",
40
46
  "prepublishOnly": "yarn build"
41
47
  },
48
+ "engines": {
49
+ "node": ">=18.0.0"
50
+ },
42
51
  "peerDependencies": {
43
52
  "astro": "^5.0.0"
44
53
  },
@@ -46,8 +55,13 @@
46
55
  "access": "public"
47
56
  },
48
57
  "devDependencies": {
49
- "@rescript/webapi": "catalog:",
58
+ "@frontman/bindings": "*",
59
+ "@frontman/frontman-core": "*",
60
+ "@frontman/frontman-protocol": "*",
61
+ "@rescript/runtime": "12.0.0-beta.14",
62
+ "@rescript/webapi": "*",
50
63
  "@vitest/ui": "catalog:",
64
+ "dom-element-to-component-source": "0.5.0",
51
65
  "rescript": "catalog:",
52
66
  "rescript-vitest": "catalog:",
53
67
  "sury": "catalog:",