figma-restoration-tools: Cursor rule for Cursor

.cursorrules

cursorrules is a cursor rule for Cursor from tianmuji/figma-restoration-tools. It costs 252 tokens per session, scanned A, a copy of project, MIT.

A set of rules for the Cursor code editor describing which project files are generated and how to add Vue components.

In plain words
What is it for?
Adding a component by creating its folder, index.vue, metadata.json, and images; the project then discovers it automatically. It also identifies generated files and lockfiles that should not be edited by hand.
Why use it?
It prevents manual edits to files maintained by automation and reduces the chance of registering components incorrectly.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

This is tianmuji/figma-restoration-tools's own configuration. It tells Cursor how to work on figma-restoration-tools itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything figma-restoration-tools configures →

Reuse

Borrowing it

Nothing to install: this file belongs to tianmuji/figma-restoration-tools. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/tianmuji/figma-restoration-tools/main/.cursorrules
Clone the repo
git clone --depth 1 https://github.com/tianmuji/figma-restoration-tools

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for cursorrules

README.md
[![agentmods](https://agentmods.dev/badge/rules/tianmuji/figma-restoration-tools/cursorrules/github.svg)](https://agentmods.dev/rules/tianmuji/figma-restoration-tools/cursorrules)
Your own site
<a href="https://agentmods.dev/rules/tianmuji/figma-restoration-tools/cursorrules"><img src="https://agentmods.dev/badge/rules/tianmuji/figma-restoration-tools/cursorrules/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for cursorrules

Your own site · 80×15
<a href="https://agentmods.dev/rules/tianmuji/figma-restoration-tools/cursorrules"><img src="https://agentmods.dev/badge/rules/tianmuji/figma-restoration-tools/cursorrules.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 252 This file is loaded in full into every session.
When invoked 252 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 94% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00252 $0.00252
Opus 5.5 $0.00101 $0.00101
Sonnet 5.5 $0.00050 $0.00050
Haiku 4.5 $0.00025 $0.00025

Measured 2mo ago against content hash 198d6de4f5b9, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

cursorrules scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

94% identical to project — 3 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.cursorrules · 28 lines

What it actually says

Cursor 编辑器规则配置

🚫 禁止修改的文件

以下文件由自动化系统维护,请勿手动修改:

组件自动注册文件

  • src/components/index.ts - 此文件使用 Vite glob import 自动扫描和注册所有组件
  • 规则: 当需要添加新组件时,只需在 src/components/ 下创建新的组件目录,无需修改此文件

自动生成的配置文件

  • *.generated.ts - 任何以 .generated.ts 结尾的文件
  • package-lock.json - NPM依赖锁定文件
  • yarn.lock - Yarn依赖锁定文件

✅ 添加新组件的正确方式

1. 创建组件目录结构

src/components/NewComponent/
├── index.vue           # Vue组件文件
├── metadata.json       # 组件元数据
└── images/            # 组件素材目录

2. 组件会自动被注册

  • src/components/index.ts 会自动发现并导出新组件
  • 无需手动添加 import 语句
  • 无需手动添加到导出列表
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 28 lines · 252 tokens per session scan A 198d6de4f5b9

Subscribe to this mod's changes

cursorrules is a cursor rule published in the GitHub repository tianmuji/figma-restoration-tools (0 stars, last pushed 1y ago), licensed MIT. It adds 252 tokens to every session, about $0.0010 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 94% identical to project, differing in 3 lines, and is treated as a copy.