text-code-edit

text-code-edit is a skill for Claude Code, Codex from meitu/meitu-skills. It costs 65 tokens per session (1,615 once invoked), scanned A, original, MIT.

A tool for editing existing React, TSX, or JSX source code, including its styles, components, layout, and interactions.

In plain words
What is it for?
Use it to adjust an existing React page, such as changing colors, adding or removing components, or modifying its layout.
Why use it?
It supports iterative changes without requiring the page to be rebuilt from scratch each time.

Skill for Claude CodeCodex

Which agent this was written for is unclear — built for openclaw. Also seen: built for openclaw.

Good fit Use it to adjust an existing React page, such as changing colors, adding or removing components, or modifying its layout.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/meitu/meitu-skills/text-code-edit
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add meitu/meitu-skills --skill text-code-edit
Clone the repo
git clone --depth 1 https://github.com/meitu/meitu-skills

Made for: Claude Code, Codex.

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 text-code-edit

README.md
[![agentmods](https://agentmods.dev/badge/skills/meitu/meitu-skills/text-code-edit/github.svg)](https://agentmods.dev/skills/meitu/meitu-skills/text-code-edit)
Your own site
<a href="https://agentmods.dev/skills/meitu/meitu-skills/text-code-edit"><img src="https://agentmods.dev/badge/skills/meitu/meitu-skills/text-code-edit/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 text-code-edit

Your own site · 80×15
<a href="https://agentmods.dev/skills/meitu/meitu-skills/text-code-edit"><img src="https://agentmods.dev/badge/skills/meitu/meitu-skills/text-code-edit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 65 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,615 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 5 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Privilege Escalation · line 5
    Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
    Fix: Remove references to credential paths. Use environment variables or secrets managers. For docs, use placeholder paths (e.g., /path/to/config). Never load .env or token files in production code paths.
  • high Privilege Escalation · line 9
    Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
    Fix: Remove references to credential paths. Use environment variables or secrets managers. For docs, use placeholder paths (e.g., /path/to/config). Never load .env or token files in production code paths.
  • high Privilege Escalation · line 11
    Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
    Fix: Remove references to credential paths. Use environment variables or secrets managers. For docs, use placeholder paths (e.g., /path/to/config). Never load .env or token files in production code paths.
  • high Privilege Escalation · line 17
    Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
    Fix: Remove references to credential paths. Use environment variables or secrets managers. For docs, use placeholder paths (e.g., /path/to/config). Never load .env or token files in production code paths.
  • medium Rogue Agent · line 21
    Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
    Fix: Remove any persistence mechanisms (cron jobs, startup scripts, state files). Skills should not maintain state across sessions without explicit user consent.
How audits are shown
Origin original No closer match found 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.00065 $0.01615
Opus 5.5 $0.00026 $0.00646
Sonnet 5.5 $0.00013 $0.00323
Haiku 4.5 $0.00006 $0.00161

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

Security

Grade A, and why

text-code-edit 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

Copies of this mod

4 near-identical copies found in the catalogue:

skills/text-code-edit/SKILL.md · 148 lines

How it starts

The opening of the file, as written. The whole thing — 148 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Text Code Edit(代码编辑)

Overview

对已有 React/TSX/JSX 源码做样式调整、组件修改、交互/布局调整;支持多轮迭代,可自动串联上下文中最近一次 text-code 生成的 code_url。不处理:从零生成(无已有源码)、非 React/HTML 框架、后端代码、像素级还原。

API Mapping

场景 后端 API
React/TSX 源码编辑 text_code_edit

model 映射:

  • auto(默认)/ 不传 → 按路由规则决策
  • pretzel_pro / pretzel_lite → 直接指定
  • 模型回退链:pretzel_pro → pretzel_lite

Dependencies

  • meitu-cli: >=2.0.6
  • 凭证:CONFIG AKSK → meitu tools update;EXEC AKSK → 跑命令(见根 CONFIG.md)
  • 环境变量:MEITU_OPENAPI_TOOL_TASK_MODE=command

Core Workflow

Preflight → Execute → Deliver

Preflight

  1. meitu --version ≥ 2.0.6
  2. meitu auth verify --json
  3. 确认 registry 含 text-code-edit
  4. 解析 output_dir:openclaw.yaml → ./output/;else → ~/.openclaw/workspace/visual/output/text-code-edit/
  5. 解析 source_code_url:
    • 用户提供 → 直接用
    • 用户未提供 + 上下文有最近生成的 code_url → 自动取上下文
    • 两者都无 → 提示"请提供源码链接"

Execute

触发信号 / 路由规则

场景 判定关键词 路由
修改已有源码 改代码、调样式、加组件、删组件、换颜色、改布局 text_code_edit
上下文有 code_url 改刚才的代码 自动取上下文 code_url
用户说"重新做一个 / 从头开始" -- 不属于本工具(走 text-code)
非 React/HTML 源码 .py/.java 等 返回"仅支持 React/HTML 代码修改"

参数定义

参数 类型 必填 范围 默认值 说明
prompt STRING 是 -- -- 修改描述。缺失 → 追问
source_code_url STRING 是 -- -- .tsx/.jsx 源码 URL。缺失时取上下文最近 code_url,仍无 → 追问
model ENUM 否 auto / pretzel_pro / pretzel_lite pretzel_pro 模型选择
image_list ARRAY 否 -- [] 参考图片 URL 列表
video_list ARRAY 否 -- [] 参考视频 URL 列表
prompt_name STRING 否 -- -- 系统提示词名称

工具调用

基础编辑:

meitu text-code-edit \
  --skill_name skill_text-code-edit \
  --prompt "{modification_description}" \
  --source_code_url "{code_url}" \
  --json --download-dir {output_dir}

带参考图片 + 指定模型:

meitu text-code-edit \
  --skill_name skill_text-code-edit \
  --prompt "{modification_description}" \
  --source_code_url "{code_url}" \
  --model pretzel_pro \
  --image_list "{ref_url}" \
  --json --download-dir {output_dir}

Read the full file on GitHub · 148 lines

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 · 148 lines · 65 tokens per session scan A 32b053aa509a

Subscribe to this mod's changes

text-code-edit is a skill published in the GitHub repository meitu/meitu-skills (36 stars, last pushed 2mo ago), licensed MIT. It adds 65 tokens to every session and 1,615 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

text-code-edit compared with skills from other repositories

text-code-edit next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
text-code-editmeitu/meitu-skillsSkill362mo agoMITA65Claude Code, Codex
build-ghost-appTryGhost/GhostSkill56kyesterdayMITA44Claude Code, Codex
chakra-ui-builderchakra-ui/chakra-uiSkill41kyesterdayMITA214Claude Code, Codex
material-ui-tailwindmui/material-uiSkill99kyesterdayMITA67Claude Code, Codex
fuzzy-rankingTanStack/tableSkill29k4d agoMITA62Claude Code, Codex
r3f-best-practiceszebbern/claude-code-guideSkill4.7k3d agoMITA74Claude Code, Codex
git-safetytamagui/tamaguiSkill14kyesterdayMITA0Claude Code