@framer/agent 0.0.37 → 0.0.39
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/dist/cli.js
CHANGED
|
@@ -13,7 +13,7 @@ import { fileURLToPath } from 'url';
|
|
|
13
13
|
import net from 'net';
|
|
14
14
|
import { createTRPCClient, httpLink } from '@trpc/client';
|
|
15
15
|
|
|
16
|
-
/* @framer/ai CLI v0.0.
|
|
16
|
+
/* @framer/ai CLI v0.0.39 */
|
|
17
17
|
var __defProp = Object.defineProperty;
|
|
18
18
|
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
19
19
|
|
|
@@ -397,7 +397,7 @@ __name(markTelemetryNoticeShown, "markTelemetryNoticeShown");
|
|
|
397
397
|
// src/version.ts
|
|
398
398
|
var VERSION = (
|
|
399
399
|
// typeof is used to ensure this can be used just via tsx or node etc. without build
|
|
400
|
-
"0.0.
|
|
400
|
+
"0.0.39"
|
|
401
401
|
);
|
|
402
402
|
var trackingEndpoint = "https://events.framer.com/track";
|
|
403
403
|
var inProgressTrackings = /* @__PURE__ */ new Set();
|
|
@@ -1314,11 +1314,11 @@ var types = {
|
|
|
1314
1314
|
name: "AgentConversationCompletedResult",
|
|
1315
1315
|
description: "",
|
|
1316
1316
|
kind: "interface",
|
|
1317
|
-
references: [],
|
|
1317
|
+
references: ["AgentResponseMessage"],
|
|
1318
1318
|
members: [
|
|
1319
1319
|
{
|
|
1320
1320
|
name: "responseMessages",
|
|
1321
|
-
type: "readonly
|
|
1321
|
+
type: "readonly AgentResponseMessage[]",
|
|
1322
1322
|
description: "",
|
|
1323
1323
|
optional: false
|
|
1324
1324
|
}
|
|
@@ -1338,6 +1338,33 @@ var types = {
|
|
|
1338
1338
|
}
|
|
1339
1339
|
]
|
|
1340
1340
|
},
|
|
1341
|
+
agentresponsecontentpart: {
|
|
1342
|
+
name: "AgentResponseContentPart",
|
|
1343
|
+
description: "A content part of an assistant response message.\n\nReasoning and tool inputs are internal to the agent: reasoning content is omitted and tool\ncalls only expose the tool name and input. Text parts contain the user-facing response.",
|
|
1344
|
+
kind: "alias",
|
|
1345
|
+
alias: '{\n type: "reasoning";\n} | {\n type: "text";\n text: string;\n} | {\n type: "tool-call";\n toolName: string;\n input: unknown;\n}',
|
|
1346
|
+
references: []
|
|
1347
|
+
},
|
|
1348
|
+
agentresponsemessage: {
|
|
1349
|
+
name: "AgentResponseMessage",
|
|
1350
|
+
description: "An assistant message from an agent turn.\n\nA turn typically produces multiple messages: text emitted between tool calls is progress\nnarration, and the last message containing text is the agent\u2019s final response.",
|
|
1351
|
+
kind: "interface",
|
|
1352
|
+
references: ["AgentResponseContentPart"],
|
|
1353
|
+
members: [
|
|
1354
|
+
{
|
|
1355
|
+
name: "role",
|
|
1356
|
+
type: '"assistant"',
|
|
1357
|
+
description: "",
|
|
1358
|
+
optional: false
|
|
1359
|
+
},
|
|
1360
|
+
{
|
|
1361
|
+
name: "content",
|
|
1362
|
+
type: "readonly AgentResponseContentPart[]",
|
|
1363
|
+
description: "",
|
|
1364
|
+
optional: false
|
|
1365
|
+
}
|
|
1366
|
+
]
|
|
1367
|
+
},
|
|
1341
1368
|
agentturnoptions: {
|
|
1342
1369
|
name: "AgentTurnOptions",
|
|
1343
1370
|
description: "",
|
|
@@ -1355,6 +1382,12 @@ var types = {
|
|
|
1355
1382
|
type: "readonly string[]",
|
|
1356
1383
|
description: "Attach images to this agent turn by URL.\n\nURLs can be external or existing Framer asset URLs. They will be ingested into the\nproject's assets if needed, then made available to the agent as trusted attachment URLs.\n\nTip: if you have a local file (or bytes), upload it first (e.g. `framer.uploadImage(...)`) and\npass the returned asset URL here.",
|
|
1357
1384
|
optional: true
|
|
1385
|
+
},
|
|
1386
|
+
{
|
|
1387
|
+
name: "fileUrls",
|
|
1388
|
+
type: "readonly string[]",
|
|
1389
|
+
description: "Attach files to this agent turn by URL.\n\nURLs can be external or existing Framer asset URLs. They will be ingested into the\nproject's assets if needed, then made available to the agent as file attachments.",
|
|
1390
|
+
optional: true
|
|
1358
1391
|
}
|
|
1359
1392
|
]
|
|
1360
1393
|
},
|
|
@@ -1395,7 +1428,7 @@ var types = {
|
|
|
1395
1428
|
name: "AllMethods",
|
|
1396
1429
|
description: "",
|
|
1397
1430
|
kind: "alias",
|
|
1398
|
-
alias: "keyof {
|
|
1431
|
+
alias: "keyof { [K in Method as (typeof methodToMessageTypes)[K] extends [] ? never : K]: (typeof methodToMessageTypes)[K] }",
|
|
1399
1432
|
references: []
|
|
1400
1433
|
},
|
|
1401
1434
|
anyeditableattributes: {
|
|
@@ -1647,7 +1680,7 @@ var types = {
|
|
|
1647
1680
|
name: "AssetData",
|
|
1648
1681
|
description: "",
|
|
1649
1682
|
kind: "interface",
|
|
1650
|
-
references: ["WithOptionalName"],
|
|
1683
|
+
references: ["WithOptionalName$1"],
|
|
1651
1684
|
members: [
|
|
1652
1685
|
{
|
|
1653
1686
|
name: "url",
|
|
@@ -1656,7 +1689,7 @@ var types = {
|
|
|
1656
1689
|
optional: false
|
|
1657
1690
|
}
|
|
1658
1691
|
],
|
|
1659
|
-
extends: ["WithOptionalName"]
|
|
1692
|
+
extends: ["WithOptionalName$1"]
|
|
1660
1693
|
},
|
|
1661
1694
|
assetdatatransfer: {
|
|
1662
1695
|
name: "AssetDataTransfer",
|
|
@@ -2021,7 +2054,7 @@ var types = {
|
|
|
2021
2054
|
name: "BytesDataTransfer",
|
|
2022
2055
|
description: "",
|
|
2023
2056
|
kind: "alias",
|
|
2024
|
-
alias: 'BytesData & {\n
|
|
2057
|
+
alias: 'BytesData & {\n type: "bytes";\n}',
|
|
2025
2058
|
references: ["BytesData"]
|
|
2026
2059
|
},
|
|
2027
2060
|
canvasnode: {
|
|
@@ -2624,7 +2657,7 @@ var types = {
|
|
|
2624
2657
|
members: [
|
|
2625
2658
|
{
|
|
2626
2659
|
name: "location",
|
|
2627
|
-
type: "{\n
|
|
2660
|
+
type: "{\n x: number;\n y: number;\n }",
|
|
2628
2661
|
description: "Coordinates of the anchor point.",
|
|
2629
2662
|
optional: false
|
|
2630
2663
|
},
|
|
@@ -3267,7 +3300,7 @@ var types = {
|
|
|
3267
3300
|
name: "CustomCode",
|
|
3268
3301
|
description: "Custom HTML code settings for all injection locations, including disabled state.",
|
|
3269
3302
|
kind: "alias",
|
|
3270
|
-
alias: "Record<CustomCodeLocation, {\n
|
|
3303
|
+
alias: "Record<CustomCodeLocation, {\n disabled: boolean;\n html: string | null;\n}>",
|
|
3271
3304
|
references: ["CustomCodeLocation"]
|
|
3272
3305
|
},
|
|
3273
3306
|
customcodelocation: {
|
|
@@ -4012,14 +4045,14 @@ var types = {
|
|
|
4012
4045
|
name: "ExplicitPartial",
|
|
4013
4046
|
description: "The opposite of Partial, can't omit it. Useful for making sure that you don't forget to handle a\nnew property in all cases where objects are built.",
|
|
4014
4047
|
kind: "alias",
|
|
4015
|
-
alias: "{
|
|
4048
|
+
alias: "{ [P in keyof T]: T[P] | undefined }",
|
|
4016
4049
|
references: []
|
|
4017
4050
|
},
|
|
4018
4051
|
extractunmarshaledgradientattributes: {
|
|
4019
4052
|
name: "ExtractUnmarshaledGradientAttributes",
|
|
4020
4053
|
description: "",
|
|
4021
4054
|
kind: "alias",
|
|
4022
|
-
alias: "Omit<Extract<UnmarshaledGradient, {\n
|
|
4055
|
+
alias: "Omit<Extract<UnmarshaledGradient, {\n [classKey]: T[ClassKey];\n}>, ClassKey>",
|
|
4023
4056
|
references: ["Extract", "UnmarshaledGradient", "ClassKey"]
|
|
4024
4057
|
},
|
|
4025
4058
|
field: {
|
|
@@ -4299,7 +4332,7 @@ var types = {
|
|
|
4299
4332
|
name: "FontAttributes",
|
|
4300
4333
|
description: "",
|
|
4301
4334
|
kind: "alias",
|
|
4302
|
-
alias: "Prettify<Partial<{\n
|
|
4335
|
+
alias: "Prettify<Partial<{\n weight: FontWeight;\n style: FontStyle$1;\n}>>",
|
|
4303
4336
|
references: ["Prettify"]
|
|
4304
4337
|
},
|
|
4305
4338
|
fontcontrol: {
|
|
@@ -4358,6 +4391,12 @@ var types = {
|
|
|
4358
4391
|
type: "FontStyle$1 | null",
|
|
4359
4392
|
description: "",
|
|
4360
4393
|
optional: false
|
|
4394
|
+
},
|
|
4395
|
+
{
|
|
4396
|
+
name: "url",
|
|
4397
|
+
type: "string | null",
|
|
4398
|
+
description: "",
|
|
4399
|
+
optional: false
|
|
4361
4400
|
}
|
|
4362
4401
|
]
|
|
4363
4402
|
},
|
|
@@ -4854,8 +4893,8 @@ var types = {
|
|
|
4854
4893
|
name: "ImageData",
|
|
4855
4894
|
description: "",
|
|
4856
4895
|
kind: "interface",
|
|
4857
|
-
references: ["WithOptionalName", "ImageOptions"],
|
|
4858
|
-
extends: ["WithOptionalName", "ImageOptions"]
|
|
4896
|
+
references: ["WithOptionalName$1", "ImageOptions"],
|
|
4897
|
+
extends: ["WithOptionalName$1", "ImageOptions"]
|
|
4859
4898
|
},
|
|
4860
4899
|
imagedatafields: {
|
|
4861
4900
|
name: "ImageDataFields",
|
|
@@ -5012,7 +5051,7 @@ var types = {
|
|
|
5012
5051
|
name: "InitialState",
|
|
5013
5052
|
description: "",
|
|
5014
5053
|
kind: "alias",
|
|
5015
|
-
alias: '{\n
|
|
5054
|
+
alias: '{\n mode: Mode;\n intent: "plugin/open";\n} | {\n mode: PickModes<"collection" | "syncManagedCollection" | "configureManagedCollection">;\n intent: "collection/add";\n}',
|
|
5016
5055
|
references: []
|
|
5017
5056
|
},
|
|
5018
5057
|
inlinelocalizationvaluebylocale: {
|
|
@@ -5688,7 +5727,7 @@ var types = {
|
|
|
5688
5727
|
name: "LocalizedValueUpdate",
|
|
5689
5728
|
description: "",
|
|
5690
5729
|
kind: "alias",
|
|
5691
|
-
alias: '{\n
|
|
5730
|
+
alias: '{\n action: "set";\n value: string;\n needsReview?: boolean;\n} | {\n action: "clear";\n} | {\n action: "ignore";\n needsReview?: boolean;\n}',
|
|
5692
5731
|
references: []
|
|
5693
5732
|
},
|
|
5694
5733
|
location: {
|
|
@@ -6118,7 +6157,7 @@ var types = {
|
|
|
6118
6157
|
name: "NamedFileAssetInput",
|
|
6119
6158
|
description: "",
|
|
6120
6159
|
kind: "interface",
|
|
6121
|
-
references: ["WithOptionalName", "AssetInput"],
|
|
6160
|
+
references: ["WithOptionalName$1", "AssetInput"],
|
|
6122
6161
|
members: [
|
|
6123
6162
|
{
|
|
6124
6163
|
name: "file",
|
|
@@ -6127,7 +6166,7 @@ var types = {
|
|
|
6127
6166
|
optional: false
|
|
6128
6167
|
}
|
|
6129
6168
|
],
|
|
6130
|
-
extends: ["WithOptionalName"]
|
|
6169
|
+
extends: ["WithOptionalName$1"]
|
|
6131
6170
|
},
|
|
6132
6171
|
namedimageassetinput: {
|
|
6133
6172
|
name: "NamedImageAssetInput",
|
|
@@ -6201,7 +6240,7 @@ var types = {
|
|
|
6201
6240
|
name: "NodeRuntimeErrorResult",
|
|
6202
6241
|
description: "",
|
|
6203
6242
|
kind: "alias",
|
|
6204
|
-
alias: '{\n
|
|
6243
|
+
alias: '{\n type: "ModuleRuntimeError" | "ReactRenderingError";\n message: string;\n}',
|
|
6205
6244
|
references: []
|
|
6206
6245
|
},
|
|
6207
6246
|
nodetype: {
|
|
@@ -6292,7 +6331,7 @@ var types = {
|
|
|
6292
6331
|
name: "NullableRecord",
|
|
6293
6332
|
description: "Type helper to transform a interface so that each value can be null.",
|
|
6294
6333
|
kind: "alias",
|
|
6295
|
-
alias: "{
|
|
6334
|
+
alias: "{ [P in keyof T]-?: T[P] | null }",
|
|
6296
6335
|
references: []
|
|
6297
6336
|
},
|
|
6298
6337
|
numbercontrol: {
|
|
@@ -6446,7 +6485,7 @@ var types = {
|
|
|
6446
6485
|
name: "Ownership",
|
|
6447
6486
|
description: "",
|
|
6448
6487
|
kind: "alias",
|
|
6449
|
-
alias: '{\n
|
|
6488
|
+
alias: '{\n type: "project";\n} | {\n type: "external";\n name: string;\n}',
|
|
6450
6489
|
references: []
|
|
6451
6490
|
},
|
|
6452
6491
|
paddingcontrol: {
|
|
@@ -6501,7 +6540,7 @@ var types = {
|
|
|
6501
6540
|
name: "PerMethodPermissionMap",
|
|
6502
6541
|
description: "",
|
|
6503
6542
|
kind: "alias",
|
|
6504
|
-
alias: "{
|
|
6543
|
+
alias: "{ [K in ProtectedMethod]: boolean }",
|
|
6505
6544
|
references: []
|
|
6506
6545
|
},
|
|
6507
6546
|
pixelnumber: {
|
|
@@ -6681,13 +6720,13 @@ var types = {
|
|
|
6681
6720
|
},
|
|
6682
6721
|
{
|
|
6683
6722
|
name: "getLocaleLanguages",
|
|
6684
|
-
type: "() => Promise<{\n
|
|
6723
|
+
type: "() => Promise<{\n code: string;\n name: string;\n }[]>",
|
|
6685
6724
|
description: "@alpha",
|
|
6686
6725
|
optional: false
|
|
6687
6726
|
},
|
|
6688
6727
|
{
|
|
6689
6728
|
name: "getLocaleRegions",
|
|
6690
|
-
type: "(language: string) => Promise<{\n
|
|
6729
|
+
type: "(language: string) => Promise<{\n code: string;\n name: string;\n isCommon: boolean;\n }[]>",
|
|
6691
6730
|
description: "@alpha",
|
|
6692
6731
|
optional: false
|
|
6693
6732
|
},
|
|
@@ -6933,13 +6972,13 @@ var types = {
|
|
|
6933
6972
|
},
|
|
6934
6973
|
{
|
|
6935
6974
|
name: "addComponentInstance",
|
|
6936
|
-
type: "(options: {\n
|
|
6975
|
+
type: "(options: {\n url: string;\n attributes?: Partial<Record<string, unknown>>;\n parentId?: string;\n }) => Promise<SomeNodeData>",
|
|
6937
6976
|
description: "",
|
|
6938
6977
|
optional: false
|
|
6939
6978
|
},
|
|
6940
6979
|
{
|
|
6941
6980
|
name: "addDetachedComponentLayers",
|
|
6942
|
-
type: "(options: {\n
|
|
6981
|
+
type: "(options: {\n url: string;\n layout?: boolean;\n attributes?: Partial<Record<string, unknown>>;\n }) => Promise<SomeNodeData>",
|
|
6943
6982
|
description: "",
|
|
6944
6983
|
optional: false
|
|
6945
6984
|
},
|
|
@@ -7335,7 +7374,7 @@ var types = {
|
|
|
7335
7374
|
},
|
|
7336
7375
|
{
|
|
7337
7376
|
name: "createCodeFile",
|
|
7338
|
-
type: "(name: string, code: string, options?: {\n
|
|
7377
|
+
type: "(name: string, code: string, options?: {\n editViaPlugin?: boolean;\n }) => Promise<CodeFileData>",
|
|
7339
7378
|
description: "",
|
|
7340
7379
|
optional: false
|
|
7341
7380
|
},
|
|
@@ -7497,7 +7536,7 @@ var types = {
|
|
|
7497
7536
|
},
|
|
7498
7537
|
{
|
|
7499
7538
|
name: "getChangedPaths",
|
|
7500
|
-
type: "() => Promise<{\n
|
|
7539
|
+
type: "() => Promise<{\n added: string[];\n removed: string[];\n modified: string[];\n }>",
|
|
7501
7540
|
description: "@alpha",
|
|
7502
7541
|
optional: false
|
|
7503
7542
|
},
|
|
@@ -7521,7 +7560,7 @@ var types = {
|
|
|
7521
7560
|
},
|
|
7522
7561
|
{
|
|
7523
7562
|
name: "getAgentContext",
|
|
7524
|
-
type: "(options?: {\n
|
|
7563
|
+
type: "(options?: {\n pagePath?: string;\n }) => Promise<string>",
|
|
7525
7564
|
description: "@alpha",
|
|
7526
7565
|
optional: false
|
|
7527
7566
|
},
|
|
@@ -7587,49 +7626,49 @@ var types = {
|
|
|
7587
7626
|
},
|
|
7588
7627
|
{
|
|
7589
7628
|
name: "readProjectForAgent",
|
|
7590
|
-
type: "(queries: Record<string, unknown>[], options?: {\n
|
|
7629
|
+
type: "(queries: Record<string, unknown>[], options?: {\n pagePath?: string;\n }) => Promise<{\n results: unknown[];\n }>",
|
|
7591
7630
|
description: "@alpha",
|
|
7592
7631
|
optional: false
|
|
7593
7632
|
},
|
|
7594
7633
|
{
|
|
7595
7634
|
name: "readComponentControlsForAgent",
|
|
7596
|
-
type: "(input: {\n
|
|
7635
|
+
type: "(input: {\n componentIds: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7597
7636
|
description: "@alpha",
|
|
7598
7637
|
optional: false
|
|
7599
7638
|
},
|
|
7600
7639
|
{
|
|
7601
7640
|
name: "readIconSetControlsForAgent",
|
|
7602
|
-
type: "(input: {\n
|
|
7641
|
+
type: "(input: {\n iconSetNames: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7603
7642
|
description: "@alpha",
|
|
7604
7643
|
optional: false
|
|
7605
7644
|
},
|
|
7606
7645
|
{
|
|
7607
7646
|
name: "readIconsForAgent",
|
|
7608
|
-
type: "(input: {\n
|
|
7647
|
+
type: "(input: {\n iconSetName: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<string[]>",
|
|
7609
7648
|
description: "@alpha",
|
|
7610
7649
|
optional: false
|
|
7611
7650
|
},
|
|
7612
7651
|
{
|
|
7613
7652
|
name: "readLayoutTemplateControlsForAgent",
|
|
7614
|
-
type: "(input: {\n
|
|
7653
|
+
type: "(input: {\n layoutTemplateIds: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7615
7654
|
description: "@alpha",
|
|
7616
7655
|
optional: false
|
|
7617
7656
|
},
|
|
7618
7657
|
{
|
|
7619
7658
|
name: "readShaderControlsForAgent",
|
|
7620
|
-
type: "(input: {\n
|
|
7659
|
+
type: "(input: {\n shaderNames: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7621
7660
|
description: "@alpha",
|
|
7622
7661
|
optional: false
|
|
7623
7662
|
},
|
|
7624
7663
|
{
|
|
7625
7664
|
name: "applyAgentChanges",
|
|
7626
|
-
type: "(dsl: string, options?: {\n
|
|
7665
|
+
type: "(dsl: string, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7627
7666
|
description: "@alpha",
|
|
7628
7667
|
optional: false
|
|
7629
7668
|
},
|
|
7630
7669
|
{
|
|
7631
7670
|
name: "replaceTextForAgent",
|
|
7632
|
-
type: "(input: {\n
|
|
7671
|
+
type: "(input: {\n id: string;\n searchText: string;\n replaceText: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<boolean>",
|
|
7633
7672
|
description: "@alpha",
|
|
7634
7673
|
optional: false
|
|
7635
7674
|
},
|
|
@@ -7652,98 +7691,98 @@ var types = {
|
|
|
7652
7691
|
optional: false
|
|
7653
7692
|
},
|
|
7654
7693
|
{
|
|
7655
|
-
name: "
|
|
7656
|
-
type: "(
|
|
7694
|
+
name: "queryAnalyticsForAgent",
|
|
7695
|
+
type: "(input: {\n query: string;\n from: string;\n to?: string;\n }) => Promise<unknown[]>",
|
|
7657
7696
|
description: "@alpha",
|
|
7658
7697
|
optional: false
|
|
7659
7698
|
},
|
|
7660
7699
|
{
|
|
7661
7700
|
name: "flattenComponentInstanceForAgent",
|
|
7662
|
-
type: "(input: {\n
|
|
7701
|
+
type: "(input: {\n id: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7663
7702
|
description: "@alpha",
|
|
7664
7703
|
optional: false
|
|
7665
7704
|
},
|
|
7666
7705
|
{
|
|
7667
7706
|
name: "makeExternalComponentLocalForAgent",
|
|
7668
|
-
type: "(input: {\n
|
|
7707
|
+
type: "(input: {\n id: string;\n replaceAll?: boolean;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7669
7708
|
description: "@alpha",
|
|
7670
7709
|
optional: false
|
|
7671
7710
|
},
|
|
7672
7711
|
{
|
|
7673
7712
|
name: "getNodeForAgent",
|
|
7674
|
-
type: "(input: {\n
|
|
7713
|
+
type: "(input: {\n id: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7675
7714
|
description: "@alpha",
|
|
7676
7715
|
optional: false
|
|
7677
7716
|
},
|
|
7678
7717
|
{
|
|
7679
7718
|
name: "getNodesForAgent",
|
|
7680
|
-
type: "(input: {\n
|
|
7719
|
+
type: "(input: {\n ids: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7681
7720
|
description: "@alpha",
|
|
7682
7721
|
optional: false
|
|
7683
7722
|
},
|
|
7684
7723
|
{
|
|
7685
7724
|
name: "getNodesOfTypesForAgent",
|
|
7686
|
-
type: "(input: {\n
|
|
7725
|
+
type: "(input: {\n types: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7687
7726
|
description: "@alpha",
|
|
7688
7727
|
optional: false
|
|
7689
7728
|
},
|
|
7690
7729
|
{
|
|
7691
7730
|
name: "getDescendantsOfTypesForAgent",
|
|
7692
|
-
type: "(input: {\n
|
|
7731
|
+
type: "(input: {\n id: string;\n types: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7693
7732
|
description: "@alpha",
|
|
7694
7733
|
optional: false
|
|
7695
7734
|
},
|
|
7696
7735
|
{
|
|
7697
7736
|
name: "getRectForAgent",
|
|
7698
|
-
type: "(input: {\n
|
|
7737
|
+
type: "(input: {\n id: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<Rect | null>",
|
|
7699
7738
|
description: "@alpha",
|
|
7700
7739
|
optional: false
|
|
7701
7740
|
},
|
|
7702
7741
|
{
|
|
7703
7742
|
name: "getDescendantReferencesOfTypesForAgent",
|
|
7704
|
-
type: "(input: {\n
|
|
7743
|
+
type: "(input: {\n id: string;\n types: readonly string[];\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7705
7744
|
description: "@alpha",
|
|
7706
7745
|
optional: false
|
|
7707
7746
|
},
|
|
7708
7747
|
{
|
|
7709
7748
|
name: "getScopeNodeForAgent",
|
|
7710
|
-
type: "(input: {\n
|
|
7749
|
+
type: "(input: {\n id: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7711
7750
|
description: "@alpha",
|
|
7712
7751
|
optional: false
|
|
7713
7752
|
},
|
|
7714
7753
|
{
|
|
7715
7754
|
name: "getGroundNodeForAgent",
|
|
7716
|
-
type: "(input: {\n
|
|
7755
|
+
type: "(input: {\n id: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7717
7756
|
description: "@alpha",
|
|
7718
7757
|
optional: false
|
|
7719
7758
|
},
|
|
7720
7759
|
{
|
|
7721
7760
|
name: "getParentNodeForAgent",
|
|
7722
|
-
type: "(input: {\n
|
|
7761
|
+
type: "(input: {\n id: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7723
7762
|
description: "@alpha",
|
|
7724
7763
|
optional: false
|
|
7725
7764
|
},
|
|
7726
7765
|
{
|
|
7727
7766
|
name: "getAncestorsForAgent",
|
|
7728
|
-
type: "(input: {\n
|
|
7767
|
+
type: "(input: {\n id: string;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7729
7768
|
description: "@alpha",
|
|
7730
7769
|
optional: false
|
|
7731
7770
|
},
|
|
7732
7771
|
{
|
|
7733
7772
|
name: "serializeForAgent",
|
|
7734
|
-
type: "(input: {\n
|
|
7773
|
+
type: "(input: {\n id: string;\n depth?: number;\n attributeFilter?: readonly string[];\n ancestorPath?: boolean;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7735
7774
|
description: "@alpha",
|
|
7736
7775
|
optional: false
|
|
7737
7776
|
},
|
|
7738
7777
|
{
|
|
7739
7778
|
name: "serializeNodesForAgent",
|
|
7740
|
-
type: "(input: {\n
|
|
7779
|
+
type: "(input: {\n ids: readonly string[];\n depth?: number;\n attributeFilter?: readonly string[];\n ancestorPath?: boolean;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7741
7780
|
description: "@alpha",
|
|
7742
7781
|
optional: false
|
|
7743
7782
|
},
|
|
7744
7783
|
{
|
|
7745
7784
|
name: "paginateForAgent",
|
|
7746
|
-
type: "(input: {\n
|
|
7785
|
+
type: "(input: {\n items: readonly unknown[];\n keyName?: never;\n cursor?: never;\n } | {\n keyName: string;\n cursor: number;\n items?: never;\n }, options?: {\n pagePath?: string;\n }) => Promise<unknown>",
|
|
7747
7786
|
description: "@alpha",
|
|
7748
7787
|
optional: false
|
|
7749
7788
|
},
|
|
@@ -7930,7 +7969,7 @@ var types = {
|
|
|
7930
7969
|
name: "Prettify",
|
|
7931
7970
|
description: "This alias takes a type as its argument and returns a new type that has the same properties as\nthe original, but the properties are not intersected. This makes the new type easier to read and\nunderstand.\n\nExample:\n```ts\n// Original type:\n{ a: string; } & { b: number; } & { c: boolean; }\n\n// New type:\n{ a: string; b: number; c: boolean; }\n```",
|
|
7932
7971
|
kind: "alias",
|
|
7933
|
-
alias: "{
|
|
7972
|
+
alias: "{ [K in keyof T]: T[K] extends object ? Prettify<T[K]> : T[K] } & {}",
|
|
7934
7973
|
references: []
|
|
7935
7974
|
},
|
|
7936
7975
|
projectinfo: {
|
|
@@ -8085,8 +8124,8 @@ var types = {
|
|
|
8085
8124
|
alias: '"RadialGradient"',
|
|
8086
8125
|
references: []
|
|
8087
8126
|
},
|
|
8088
|
-
rect
|
|
8089
|
-
name: "Rect
|
|
8127
|
+
rect: {
|
|
8128
|
+
name: "Rect",
|
|
8090
8129
|
description: "",
|
|
8091
8130
|
kind: "interface",
|
|
8092
8131
|
references: [],
|
|
@@ -8319,7 +8358,7 @@ var types = {
|
|
|
8319
8358
|
},
|
|
8320
8359
|
{
|
|
8321
8360
|
name: "clip",
|
|
8322
|
-
type: "{\n
|
|
8361
|
+
type: "{\n x: number;\n y: number;\n width: number;\n height: number;\n }",
|
|
8323
8362
|
description: "Clip region in CSS pixels (before scale).\nCaptures only this portion of the node.",
|
|
8324
8363
|
optional: true
|
|
8325
8364
|
}
|
|
@@ -8423,13 +8462,13 @@ var types = {
|
|
|
8423
8462
|
members: [
|
|
8424
8463
|
{
|
|
8425
8464
|
name: "valuesBySource",
|
|
8426
|
-
type: "{\n
|
|
8465
|
+
type: "{\n errors: readonly LocalizationValueError[];\n }",
|
|
8427
8466
|
description: "Set one or more localized values",
|
|
8428
8467
|
optional: false
|
|
8429
8468
|
},
|
|
8430
8469
|
{
|
|
8431
8470
|
name: "statusByLocaleByGroup",
|
|
8432
|
-
type: "{\n
|
|
8471
|
+
type: "{\n errors: readonly LocalizationStatusByLocaleError[];\n }",
|
|
8433
8472
|
description: "Set the hidden locale IDs of one or more localization groups",
|
|
8434
8473
|
optional: false
|
|
8435
8474
|
}
|
|
@@ -8530,8 +8569,8 @@ var types = {
|
|
|
8530
8569
|
alias: 'Pick<ComponentInstancePlaceholderAttributes, "title" | "codePreview">',
|
|
8531
8570
|
references: ["ComponentInstancePlaceholderAttributes"]
|
|
8532
8571
|
},
|
|
8533
|
-
size: {
|
|
8534
|
-
name: "Size",
|
|
8572
|
+
size$1: {
|
|
8573
|
+
name: "Size$1",
|
|
8535
8574
|
description: "",
|
|
8536
8575
|
kind: "interface",
|
|
8537
8576
|
references: [],
|
|
@@ -8663,7 +8702,7 @@ var types = {
|
|
|
8663
8702
|
name: "StartAgentConversationResult",
|
|
8664
8703
|
description: "",
|
|
8665
8704
|
kind: "alias",
|
|
8666
|
-
alias: "({\n
|
|
8705
|
+
alias: "({\n conversationId: string;\n} & AgentConversationCompletedResult) | ({\n conversationId: string;\n} & AgentConversationNeedsClarificationResult)",
|
|
8667
8706
|
references: [
|
|
8668
8707
|
"AgentConversationCompletedResult",
|
|
8669
8708
|
"AgentConversationNeedsClarificationResult"
|
|
@@ -8859,7 +8898,7 @@ var types = {
|
|
|
8859
8898
|
name: "SVGData",
|
|
8860
8899
|
description: "",
|
|
8861
8900
|
kind: "interface",
|
|
8862
|
-
references: ["WithOptionalName"],
|
|
8901
|
+
references: ["WithOptionalName$1"],
|
|
8863
8902
|
members: [
|
|
8864
8903
|
{
|
|
8865
8904
|
name: "svg",
|
|
@@ -8868,7 +8907,7 @@ var types = {
|
|
|
8868
8907
|
optional: false
|
|
8869
8908
|
}
|
|
8870
8909
|
],
|
|
8871
|
-
extends: ["WithOptionalName"]
|
|
8910
|
+
extends: ["WithOptionalName$1"]
|
|
8872
8911
|
},
|
|
8873
8912
|
textalignment: {
|
|
8874
8913
|
name: "TextAlignment",
|
|
@@ -8909,7 +8948,7 @@ var types = {
|
|
|
8909
8948
|
name: "TextStyleAttributes",
|
|
8910
8949
|
description: "",
|
|
8911
8950
|
kind: "alias",
|
|
8912
|
-
alias: 'Prettify<Partial<Omit<TextStyleData, "id" | "color" | "font" | "boldFont" | "italicFont" | "boldItalicFont" | "breakpoints"> & {\n
|
|
8951
|
+
alias: 'Prettify<Partial<Omit<TextStyleData, "id" | "color" | "font" | "boldFont" | "italicFont" | "boldItalicFont" | "breakpoints"> & {\n color: ColorStyle | string;\n font: Font;\n boldFont: Font | null;\n italicFont: Font | null;\n boldItalicFont: Font | null;\n breakpoints: TextStyleBreakpointAttributes[];\n}> & AssetPath>',
|
|
8913
8952
|
references: ["Prettify", "TextStyleData", "AssetPath"]
|
|
8914
8953
|
},
|
|
8915
8954
|
textstylebreakpoint: {
|
|
@@ -9658,7 +9697,7 @@ var types = {
|
|
|
9658
9697
|
name: "UpdateFieldAttributes",
|
|
9659
9698
|
description: "The type of the `attributes` parameter of `Field.setAttributes`:\n\n```ts\nconst fileFieldAttributes: UpdateFieldAttributes<FileField> = {}\nfileFieldAttributes.allowedFileTypes = []\nfileField.setAttributes(fileFieldAttributes)\n```\n\nCan also use `typeof`:\n\n```ts\nconst fileFieldAttributes: UpdateFieldAttributes<typeof fileField> = {}\n```",
|
|
9660
9699
|
kind: "alias",
|
|
9661
|
-
alias: 'Omit<Extract<UpdateField, {\n
|
|
9700
|
+
alias: 'Omit<Extract<UpdateField, {\n type: T["type"];\n}>,\n"id" | "type">',
|
|
9662
9701
|
references: ["Extract", "UpdateField"]
|
|
9663
9702
|
},
|
|
9664
9703
|
updatefieldbase: {
|
|
@@ -9865,7 +9904,7 @@ var types = {
|
|
|
9865
9904
|
name: "UpdateVariableAttributes",
|
|
9866
9905
|
description: "",
|
|
9867
9906
|
kind: "alias",
|
|
9868
|
-
alias: 'Omit<Extract<UpdateVariable, {\n
|
|
9907
|
+
alias: 'Omit<Extract<UpdateVariable, {\n type: T["type"];\n}>, "type">',
|
|
9869
9908
|
references: ["Extract", "UpdateVariable"]
|
|
9870
9909
|
},
|
|
9871
9910
|
updatevariablebase: {
|
|
@@ -10892,8 +10931,8 @@ var types = {
|
|
|
10892
10931
|
alias: "Partial<WithFieldRequired>",
|
|
10893
10932
|
references: ["WithFieldRequired"]
|
|
10894
10933
|
},
|
|
10895
|
-
withoptionalname: {
|
|
10896
|
-
name: "WithOptionalName",
|
|
10934
|
+
withoptionalname$1: {
|
|
10935
|
+
name: "WithOptionalName$1",
|
|
10897
10936
|
description: "",
|
|
10898
10937
|
kind: "interface",
|
|
10899
10938
|
references: [],
|
|
@@ -12193,9 +12232,9 @@ var methodsByCategory = {
|
|
|
12193
12232
|
{
|
|
12194
12233
|
name: "getRect",
|
|
12195
12234
|
category: "ComponentInstanceNode",
|
|
12196
|
-
signature: "getRect(): Promise<Rect
|
|
12235
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
12197
12236
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
12198
|
-
references: ["Rect
|
|
12237
|
+
references: ["Rect"]
|
|
12199
12238
|
},
|
|
12200
12239
|
{
|
|
12201
12240
|
name: "getRuntimeError",
|
|
@@ -12465,9 +12504,9 @@ var methodsByCategory = {
|
|
|
12465
12504
|
{
|
|
12466
12505
|
name: "getRect",
|
|
12467
12506
|
category: "ComponentNode",
|
|
12468
|
-
signature: "getRect(): Promise<Rect
|
|
12507
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
12469
12508
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
12470
|
-
references: ["Rect
|
|
12509
|
+
references: ["Rect"]
|
|
12471
12510
|
},
|
|
12472
12511
|
{
|
|
12473
12512
|
name: "getVariables",
|
|
@@ -12690,9 +12729,9 @@ var methodsByCategory = {
|
|
|
12690
12729
|
{
|
|
12691
12730
|
name: "getRect",
|
|
12692
12731
|
category: "DesignPageNode",
|
|
12693
|
-
signature: "getRect(): Promise<Rect
|
|
12732
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
12694
12733
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
12695
|
-
references: ["Rect
|
|
12734
|
+
references: ["Rect"]
|
|
12696
12735
|
},
|
|
12697
12736
|
{
|
|
12698
12737
|
name: "navigateTo",
|
|
@@ -13020,6 +13059,13 @@ var methodsByCategory = {
|
|
|
13020
13059
|
description: "Specifies if the font is normal or _italic_.\n\nNote: This will be `null` for custom fonts since their weight isn't\ncalculated.",
|
|
13021
13060
|
references: ["FontStyle$1"]
|
|
13022
13061
|
},
|
|
13062
|
+
{
|
|
13063
|
+
name: "url",
|
|
13064
|
+
category: "Font",
|
|
13065
|
+
signature: "url: string | null",
|
|
13066
|
+
description: "URL of the font's primary file, which can be used to render the font\n(for example in an `@font-face` rule). Intended for previewing a font;\nit may not cover every unicode range on its own.\n\n`null` when the font has no downloadable source file.",
|
|
13067
|
+
references: []
|
|
13068
|
+
},
|
|
13023
13069
|
{
|
|
13024
13070
|
name: "weight",
|
|
13025
13071
|
category: "Font",
|
|
@@ -13211,9 +13257,9 @@ var methodsByCategory = {
|
|
|
13211
13257
|
{
|
|
13212
13258
|
name: "getRect",
|
|
13213
13259
|
category: "FrameNode",
|
|
13214
|
-
signature: "getRect(): Promise<Rect
|
|
13260
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
13215
13261
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
13216
|
-
references: ["Rect
|
|
13262
|
+
references: ["Rect"]
|
|
13217
13263
|
},
|
|
13218
13264
|
{
|
|
13219
13265
|
name: "gridAlignment",
|
|
@@ -13633,7 +13679,7 @@ var methodsByCategory = {
|
|
|
13633
13679
|
{
|
|
13634
13680
|
name: "addComponentInstance",
|
|
13635
13681
|
category: "framer",
|
|
13636
|
-
signature: "addComponentInstance({
|
|
13682
|
+
signature: "addComponentInstance({\n url,\n attributes,\n parentId\n }: AddComponentInstanceOptions): Promise<ComponentInstanceNode>",
|
|
13637
13683
|
description: "Add a component instance by module URL.\n\n@param url - The component module URL. Can be copied from the components panel.\n@param attributes - Optional component attributes.\n\n@returns The newly created component instance node.\n@category canvas",
|
|
13638
13684
|
references: ["AddComponentInstanceOptions", "ComponentInstanceNode"]
|
|
13639
13685
|
},
|
|
@@ -13650,7 +13696,7 @@ var methodsByCategory = {
|
|
|
13650
13696
|
{
|
|
13651
13697
|
name: "addDetachedComponentLayers",
|
|
13652
13698
|
category: "framer",
|
|
13653
|
-
signature: "addDetachedComponentLayers({
|
|
13699
|
+
signature: "addDetachedComponentLayers({\n url,\n layout,\n attributes\n }: AddDetachedComponentLayersOptions): Promise<FrameNode>",
|
|
13654
13700
|
description: "Adds the layers of a component by module URL.\n@category canvas",
|
|
13655
13701
|
references: ["AddDetachedComponentLayersOptions", "FrameNode"]
|
|
13656
13702
|
},
|
|
@@ -14007,9 +14053,9 @@ var methodsByCategory = {
|
|
|
14007
14053
|
{
|
|
14008
14054
|
name: "getRect",
|
|
14009
14055
|
category: "framer",
|
|
14010
|
-
signature: "getRect(nodeId: NodeId): Promise<Rect
|
|
14056
|
+
signature: "getRect(nodeId: NodeId): Promise<Rect | null>",
|
|
14011
14057
|
description: "Get the rect of a node\n@category canvas",
|
|
14012
|
-
references: ["Rect
|
|
14058
|
+
references: ["Rect"]
|
|
14013
14059
|
},
|
|
14014
14060
|
{
|
|
14015
14061
|
name: "getRedirects",
|
|
@@ -14213,7 +14259,7 @@ var methodsByCategory = {
|
|
|
14213
14259
|
name: "applyChanges",
|
|
14214
14260
|
category: "FramerAgentAPI",
|
|
14215
14261
|
signature: "applyChanges(dsl: string, options?: { pagePath?: string; }): Promise<unknown>",
|
|
14216
|
-
description: 'Applies commands to the canvas to create, update, remove, move, or duplicate nodes.\n\nThe command syntax is documented in the string returned by {@link getSystemPrompt}.\nEach call is scoped to a single page.\n\nCommands that fail (including syntax errors) are reported in the result\'s `errors`\nwithout blocking the remaining commands
|
|
14262
|
+
description: 'Applies commands to the canvas to create, update, remove, move, or duplicate nodes.\n\nThe command syntax is documented in the string returned by {@link getSystemPrompt}.\nEach call is scoped to a single page.\n\nCommands that fail (including syntax errors) are reported in the result\'s `errors`\nwithout blocking the remaining commands.\n\nThe result schema is documented in the string returned by {@link getSystemPrompt}.\n\n@param dsl - A string of commands separated by `;`. See {@link getSystemPrompt} for syntax.\n@param options.pagePath - Target page path (e.g. `"/about"`). Defaults to the active page.\n@returns The command status and errors, and the canonical system ids of created nodes.',
|
|
14217
14263
|
references: []
|
|
14218
14264
|
},
|
|
14219
14265
|
{
|
|
@@ -14324,9 +14370,9 @@ var methodsByCategory = {
|
|
|
14324
14370
|
{
|
|
14325
14371
|
name: "getRect",
|
|
14326
14372
|
category: "FramerAgentAPI",
|
|
14327
|
-
signature: "getRect(input: { id: string; }, options?: { pagePath?: string; }): Promise<Rect
|
|
14373
|
+
signature: "getRect(input: { id: string; }, options?: { pagePath?: string; }): Promise<Rect | null>",
|
|
14328
14374
|
description: 'Get the measured rect for a node.\n\n@param input - `{ id }`: the id of the node to measure.\n@param options.pagePath - Target page path (e.g. `"/about"`). Defaults to the active page.\n@returns The rounded measured rect, or `null` if no node with that id exists on the page.',
|
|
14329
|
-
references: ["Rect
|
|
14375
|
+
references: ["Rect"]
|
|
14330
14376
|
},
|
|
14331
14377
|
{
|
|
14332
14378
|
name: "getScopeNode",
|
|
@@ -14384,6 +14430,13 @@ var methodsByCategory = {
|
|
|
14384
14430
|
description: "Executes the publish flow on behalf of an agent.\n\nThe input schema is documented in the string returned by {@link getSystemPrompt}.\n\n@param input - Action-discriminated input object (preview / confirm_publish / deploy_to_production).\n@returns The action's result \u2014 status, publish URLs, and any errors, warnings, or changes.",
|
|
14385
14431
|
references: []
|
|
14386
14432
|
},
|
|
14433
|
+
{
|
|
14434
|
+
name: "queryAnalytics",
|
|
14435
|
+
category: "FramerAgentAPI",
|
|
14436
|
+
signature: "queryAnalytics(input: { query: string; from: string; to?: string | undefined; }): Promise<unknown[]>",
|
|
14437
|
+
description: "Runs a read-only analytics query against the current site.\n\nThe input schema is documented in the string returned by {@link getSystemPrompt}.\n\n@param input - Query input object (query / from / to). Dates are ISO strings.\n@returns The analytics rows returned by the query.",
|
|
14438
|
+
references: []
|
|
14439
|
+
},
|
|
14387
14440
|
{
|
|
14388
14441
|
name: "queryImages",
|
|
14389
14442
|
category: "FramerAgentAPI",
|
|
@@ -14447,13 +14500,6 @@ var methodsByCategory = {
|
|
|
14447
14500
|
description: 'Replaces text within a text-like node.\n\n@param input - `{ id, searchText, replaceText }`: the target node id, text to find, and replacement text.\n@param options.pagePath - Target page path (e.g. `"/about"`). Defaults to the active page.\n@returns `true` when text was replaced, or `false` when no matching text was found.',
|
|
14448
14501
|
references: []
|
|
14449
14502
|
},
|
|
14450
|
-
{
|
|
14451
|
-
name: "reviewChanges",
|
|
14452
|
-
category: "FramerAgentAPI",
|
|
14453
|
-
signature: "reviewChanges(): Promise<unknown>",
|
|
14454
|
-
description: "Reviews changes made by prior {@link applyChanges} calls in this session.\n\nConsumes accumulated diagnostics from the session's agent context. Command errors\nalready returned by {@link applyChanges} are not repeated here.\n\n@returns The session's accumulated changes, errors, warnings, and deferred trait reports.",
|
|
14455
|
-
references: []
|
|
14456
|
-
},
|
|
14457
14503
|
{
|
|
14458
14504
|
name: "serialize",
|
|
14459
14505
|
category: "FramerAgentAPI",
|
|
@@ -14503,7 +14549,7 @@ var methodsByCategory = {
|
|
|
14503
14549
|
{
|
|
14504
14550
|
name: "cloneWithAttributes",
|
|
14505
14551
|
category: "ImageAsset",
|
|
14506
|
-
signature: 'cloneWithAttributes({
|
|
14552
|
+
signature: 'cloneWithAttributes({\n altText,\n resolution\n }: Prettify<Partial<Pick<ImageAssetData, "altText" | "resolution">>>): ImageAsset',
|
|
14507
14553
|
description: "Clone this image asset, optionally overriding `altText` or `resolution`.\nThe clone shares the same underlying image data.",
|
|
14508
14554
|
references: ["Prettify", "ImageAssetData", "ImageAsset"]
|
|
14509
14555
|
},
|
|
@@ -14531,9 +14577,9 @@ var methodsByCategory = {
|
|
|
14531
14577
|
{
|
|
14532
14578
|
name: "measure",
|
|
14533
14579
|
category: "ImageAsset",
|
|
14534
|
-
signature: "measure(): Promise<Size>",
|
|
14580
|
+
signature: "measure(): Promise<Size$1>",
|
|
14535
14581
|
description: "Measure this image's natural dimensions.\n\n@returns The width and height in pixels. Warning: values may be zero.",
|
|
14536
|
-
references: ["Size"]
|
|
14582
|
+
references: ["Size$1"]
|
|
14537
14583
|
},
|
|
14538
14584
|
{
|
|
14539
14585
|
name: "resolution",
|
|
@@ -15077,9 +15123,9 @@ var methodsByCategory = {
|
|
|
15077
15123
|
{
|
|
15078
15124
|
name: "getRect",
|
|
15079
15125
|
category: "SVGNode",
|
|
15080
|
-
signature: "getRect(): Promise<Rect
|
|
15126
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
15081
15127
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
15082
|
-
references: ["Rect
|
|
15128
|
+
references: ["Rect"]
|
|
15083
15129
|
},
|
|
15084
15130
|
{
|
|
15085
15131
|
name: "height",
|
|
@@ -15310,9 +15356,9 @@ var methodsByCategory = {
|
|
|
15310
15356
|
{
|
|
15311
15357
|
name: "getRect",
|
|
15312
15358
|
category: "TextNode",
|
|
15313
|
-
signature: "getRect(): Promise<Rect
|
|
15359
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
15314
15360
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
15315
|
-
references: ["Rect
|
|
15361
|
+
references: ["Rect"]
|
|
15316
15362
|
},
|
|
15317
15363
|
{
|
|
15318
15364
|
name: "getText",
|
|
@@ -15872,9 +15918,9 @@ var methodsByCategory = {
|
|
|
15872
15918
|
{
|
|
15873
15919
|
name: "getRect",
|
|
15874
15920
|
category: "UnknownNode",
|
|
15875
|
-
signature: "getRect(): Promise<Rect
|
|
15921
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
15876
15922
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
15877
|
-
references: ["Rect
|
|
15923
|
+
references: ["Rect"]
|
|
15878
15924
|
},
|
|
15879
15925
|
{
|
|
15880
15926
|
name: "navigateTo",
|
|
@@ -16071,9 +16117,9 @@ var methodsByCategory = {
|
|
|
16071
16117
|
{
|
|
16072
16118
|
name: "getRect",
|
|
16073
16119
|
category: "VectorSetItemNode",
|
|
16074
|
-
signature: "getRect(): Promise<Rect
|
|
16120
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
16075
16121
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
16076
|
-
references: ["Rect
|
|
16122
|
+
references: ["Rect"]
|
|
16077
16123
|
},
|
|
16078
16124
|
{
|
|
16079
16125
|
name: "height",
|
|
@@ -16241,9 +16287,9 @@ var methodsByCategory = {
|
|
|
16241
16287
|
{
|
|
16242
16288
|
name: "getRect",
|
|
16243
16289
|
category: "VectorSetNode",
|
|
16244
|
-
signature: "getRect(): Promise<Rect
|
|
16290
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
16245
16291
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
16246
|
-
references: ["Rect
|
|
16292
|
+
references: ["Rect"]
|
|
16247
16293
|
},
|
|
16248
16294
|
{
|
|
16249
16295
|
name: "navigateTo",
|
|
@@ -16383,9 +16429,9 @@ var methodsByCategory = {
|
|
|
16383
16429
|
{
|
|
16384
16430
|
name: "getRect",
|
|
16385
16431
|
category: "WebPageNode",
|
|
16386
|
-
signature: "getRect(): Promise<Rect
|
|
16432
|
+
signature: "getRect(): Promise<Rect | null>",
|
|
16387
16433
|
description: "Get the bounding box of this node.\n\n@returns The bounding rectangle, or `null` if unavailable.",
|
|
16388
|
-
references: ["Rect
|
|
16434
|
+
references: ["Rect"]
|
|
16389
16435
|
},
|
|
16390
16436
|
{
|
|
16391
16437
|
name: "navigateTo",
|
|
@@ -15,7 +15,7 @@ import { createRequire } from 'module';
|
|
|
15
15
|
import * as vm from 'vm';
|
|
16
16
|
import isWsl from 'is-wsl';
|
|
17
17
|
|
|
18
|
-
/* @framer/ai relay server v0.0.
|
|
18
|
+
/* @framer/ai relay server v0.0.39 */
|
|
19
19
|
var __defProp = Object.defineProperty;
|
|
20
20
|
var __knownSymbol = (name2, symbol) => (symbol = Symbol[name2]) ? symbol : /* @__PURE__ */ Symbol.for("Symbol." + name2);
|
|
21
21
|
var __typeError = (msg) => {
|
|
@@ -200,7 +200,7 @@ __name(debug, "debug");
|
|
|
200
200
|
// src/version.ts
|
|
201
201
|
var VERSION = (
|
|
202
202
|
// typeof is used to ensure this can be used just via tsx or node etc. without build
|
|
203
|
-
"0.0.
|
|
203
|
+
"0.0.39"
|
|
204
204
|
);
|
|
205
205
|
|
|
206
206
|
// src/relay-client.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@framer/agent",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.39",
|
|
4
4
|
"description": "CLI and skills for connecting your AI agents to Framer.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": "./dist/cli.js",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"@trpc/client": "^11.17.0",
|
|
26
26
|
"@trpc/server": "^11.17.0",
|
|
27
27
|
"commander": "^12.1.0",
|
|
28
|
-
"framer-api": "^0.1.
|
|
28
|
+
"framer-api": "^0.1.24",
|
|
29
29
|
"is-wsl": "^3.1.1",
|
|
30
30
|
"zod": "^4.4.3"
|
|
31
31
|
},
|
package/skills/framer/SKILL.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: framer
|
|
3
3
|
description: >
|
|
4
|
-
Use when the user wants to design, edit, or publish a website or web page — creating layouts, editing sections, updating text or images, managing CMS collections and content, syncing external data, creating or modifying code components, managing color and text styles, handling localization, or publishing deployments. Trigger when the user mentions Framer, references their website or web pages, asks to edit designs, update site content, or work with any Framer project — even if they don't explicitly say 'Framer'.
|
|
4
|
+
Use when the user wants to design, edit, analyze, or publish a website or web page — creating layouts, editing sections, updating text or images, querying site analytics, managing CMS collections and content, syncing external data, creating or modifying code components, managing color and text styles, handling localization, or publishing deployments. Trigger when the user mentions Framer, references their website or web pages, asks to edit designs, update site content, analyze site traffic or conversions, or work with any Framer project — even if they don't explicitly say 'Framer'.
|
|
5
5
|
**Mandatory precondition**: run `{{FRAMER_AGENT_COMMAND}}@latest setup` and let it complete **BEFORE** loading this skill.
|
|
6
6
|
allowed-tools:
|
|
7
7
|
- 'Bash({{FRAMER_AGENT_COMMAND}}:*)'
|
|
@@ -22,6 +22,7 @@ If you didn't run this command before loading the skill, run it now:
|
|
|
22
22
|
What you can do with the Framer CLI:
|
|
23
23
|
|
|
24
24
|
- **Canvas Editing**: For design tasks — creating or editing pages, sections, layouts, recreating designs from screenshots, etc.
|
|
25
|
+
- **Analytics**: Query traffic, visitors, page views, conversions, and events.
|
|
25
26
|
- **CMS**: Create, read, update, delete collections and items. Sync external databases.
|
|
26
27
|
- **Styles**: Manage color and text styles. Sync design systems.
|
|
27
28
|
- **Code Components**: Create, edit, type-check, and add custom React components to the canvas.
|
|
@@ -93,7 +94,7 @@ projects/<safeProjectId>/
|
|
|
93
94
|
The generated `project-inventory.md` includes a snapshot of project context from `framer.agent.getContext()`, including pages, components, CMS data, styles, fonts, icons, and IDs when available.
|
|
94
95
|
The source template for generated project files lives at `projects/__template__/`. Files ending in `.template.md` are rendered into generated files without the `.template` marker.
|
|
95
96
|
|
|
96
|
-
Before
|
|
97
|
+
Before starting any task, read `projects/<safeProjectId>/index.md` first. It contains a **task map**: read every item marked required in its "Always" row, including `prompt/critical-reminders.md`, then the row that matches your work — and every additional row a multi-domain task touches. The map routes you to the exact `prompt/` sections, `recipes.md` entries, and implementation guides for that task; read only what the map points to.
|
|
97
98
|
|
|
98
99
|
Read `projects/<safeProjectId>/project-inventory.md` before using project-specific IDs, page paths, component names, CMS collection names, style preset names, or icon names. Treat it as a generated snapshot; when the project may have changed, use `{{FRAMER_AGENT_COMMAND}}@latest read-project` for fresh live project state.
|
|
99
100
|
|
|
@@ -145,15 +146,30 @@ Prefer `framer.agent.*` methods over regular plugin API methods when an agent-sp
|
|
|
145
146
|
|
|
146
147
|
### Execute Code
|
|
147
148
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
Name files `<sessionId>-<short-summary>.js`, for example `1-read-collections.js`.
|
|
149
|
+
For multiline or non-trivial code, use one `exec` call and send the code on stdin. In POSIX shells, use a quoted heredoc so the shell cannot expand `$`, backticks, or command substitutions in the JavaScript:
|
|
151
150
|
|
|
152
151
|
```bash
|
|
153
|
-
{{FRAMER_AGENT_COMMAND}}@latest exec -s 1
|
|
152
|
+
{{FRAMER_AGENT_COMMAND}}@latest exec -s 1 <<'FRAMER_EXEC'
|
|
153
|
+
const collections = await framer.getCollections();
|
|
154
|
+
state.collections = collections;
|
|
155
|
+
console.log(collections);
|
|
156
|
+
FRAMER_EXEC
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
In Windows PowerShell, use the equivalent single-quoted here-string to prevent interpolation and pipe it to `exec`:
|
|
160
|
+
|
|
161
|
+
```powershell
|
|
162
|
+
@'
|
|
163
|
+
const projectInfo = await framer.getProjectInfo();
|
|
164
|
+
console.log(projectInfo);
|
|
165
|
+
'@ | {{FRAMER_AGENT_COMMAND}}@latest exec -s 1
|
|
154
166
|
```
|
|
155
167
|
|
|
156
|
-
For short snippets,
|
|
168
|
+
For genuinely short snippets, use `-e <code>`:
|
|
169
|
+
|
|
170
|
+
```bash
|
|
171
|
+
{{FRAMER_AGENT_COMMAND}}@latest exec -s 1 -e 'console.log(await framer.getProjectInfo())'
|
|
172
|
+
```
|
|
157
173
|
|
|
158
174
|
### Use `state`
|
|
159
175
|
|
|
@@ -16,9 +16,10 @@ This `index.md` is the map. Read the **Always** row first — it is the core fou
|
|
|
16
16
|
|
|
17
17
|
| Doing… | Read before you start |
|
|
18
18
|
|---|---|
|
|
19
|
-
| **Always — every change** | All files are required: [[prompt/core-principles.md]] (layout, spacing, width, fills, overflow) · [[prompt/core-examples.md]] (worked DSL patterns) · [[prompt/implementation-strategy.md]] (pick creation/edit/recreation, write a design plan, settle reusable-systems + site-metadata) · [[prompt/updating-the-project.md]] (DSL grammar) · [[prompt/tools.md]] (
|
|
19
|
+
| **Always — every change** | All files are required: [[prompt/core-principles.md]] (layout, spacing, width, fills, overflow) · [[prompt/core-examples.md]] (worked DSL patterns) · [[prompt/implementation-strategy.md]] (pick creation/edit/recreation, write a design plan, settle reusable-systems + site-metadata) · [[prompt/updating-the-project.md]] (DSL grammar) · [[prompt/tools.md]] (available tools and when to use them). House rules: [[prompt/overview.md]], [[prompt/guardrails.md]], [[prompt/critical-reminders.md]]. |
|
|
20
20
|
| **Pages / sections** — create, redesign, add sections, visual polish, review | + [[prompt/design-rules.md]] · [[prompt/how-projects-work.md]] §Layout Recipe + §Width Rules + §Links |
|
|
21
21
|
| **Responsive breakpoints** | [[recipes.md]] § Responsive breakpoints · [[prompt/how-projects-work.md]] §Layout Recipe (rules 7–8) |
|
|
22
|
+
| **Analytics** — traffic, visitors, page views, conversions, events | guide **Analytics** |
|
|
22
23
|
| **CMS** — collections, items, fields, collection lists, CMS-backed content | [[prompt/how-projects-work.md]] §CMS · [[prompt/updating-the-project.md]] (variable/CMS DSL) · guide **CMS Collection Lists** |
|
|
23
24
|
| **CMS detail pages** | [[prompt/how-projects-work.md]] §CMS detail pages · guide **CMS Detail Pages** |
|
|
24
25
|
| **Components / variants / icons** | [[prompt/how-projects-work.md]] §Components + §Icons · guide **Buttons** or others as needed |
|