Install
$ agentstack add skill-youyouhe-bidsmart-claude-skills-web-builder-update ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ● Dynamic code execution Used
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
Web Builder Update - Precision Web Project Modification
Overview
The web-builder-update skill performs precision modifications to existing web projects using BuildFlow's SEARCH/REPLACE pattern system. Unlike full regeneration, this skill targets only the specific sections that need changes, preserving all other code intact.
This skill is optimized for:
- Changing design elements (colors, fonts, layouts)
- Adding new features or sections to existing pages
- Updating content or text
- Creating new pages with proper navigation links
- Modifying JavaScript behavior
- Adding or updating Web Components
Core Principles
1. Minimal Changes Philosophy
- Only modify what needs to change - preserve all other code
- Use UPDATEFILESTART markers to target specific files
- Use SEARCH/REPLACE blocks for precise section replacement
- Multiple SEARCH/REPLACE blocks allowed per file for non-adjacent changes
2. Exact Matching Requirement
- SEARCH blocks must exactly match current code (including whitespace and indentation)
- However, BuildFlow uses flexible HTML regex that tolerates minor whitespace variations
- When in doubt, include more surrounding context to ensure unique matches
3. Marker-Based Format
BuildFlow uses structured markers for parsing:
>>>>>> UPDATE_FILE_END- Identifies which file to modify>>>>>> REPLACE- End of replacement block>>>>>> NEW_FILE_END- For creating new files
4. Insertion and Deletion Patterns
- Insert at beginning: Empty SEARCH block (only markers + divider)
- Insert in middle: SEARCH includes line before insertion point, REPLACE includes that line + new lines
- Delete code: SEARCH includes lines to delete, REPLACE is empty (only divider + end marker)
5. Web Components and Shared Files
- Create reusable UI elements as Native Web Components in
components/folder - Shared CSS goes in
style.css(all pages link to it) - Shared JS goes in
script.js(all pages link to it) - When creating new pages, UPDATE all existing pages to add navigation links
Workflow
Phase 0: Load Current Files
Before applying any modifications, load the current state of the web project:
# List all files in web-output directory
ls -la /web-output/
# Read current content of files to be modified
cat /web-output/index.html
cat /web-output/style.css
cat /web-output/script.js
Critical: You MUST know the exact current content to construct accurate SEARCH blocks.
Phase 1: Context Injection
Build the prompt with full context:
- Current file contents: Embed entire content of files to be modified
- User request: Specific modification described by user
- Design preferences: Any colors, themes, or style preferences mentioned
- Related files: If change affects multiple files, load all of them
Example context injection:
Current index.html content:
[full HTML content here]
Current style.css content:
[full CSS content here]
User request: Change the primary color from blue to red and add a new "Contact" section after the features.
Please apply the necessary changes using SEARCH/REPLACE format.
Phase 2: Apply BuildFlow FOLLOW_UP Prompt
Use BuildFlow's FOLLOWUPSYSTEM_PROMPT (see System Prompt section below) to generate modifications.
Language selection:
- English user request → Use
FOLLOW_UP_SYSTEM_PROMPT(English) - Chinese user request → Use
FOLLOW_UP_SYSTEM_PROMPT_ZH(中文) - Mixed → Prefer user's primary language or default to English
Phase 3: SEARCH/REPLACE Extraction and Application
Parse AI output for SEARCH/REPLACE blocks:
- Extract UPDATE_FILE blocks: Identify which files are being modified
- Extract SEARCH/REPLACE pairs: For each file, extract all SEARCH/REPLACE blocks
- Validate SEARCH blocks: Verify each SEARCH block exists in current file
- Apply flexible regex: Use whitespace-tolerant matching for HTML (see Flexible HTML Regex section)
- Apply replacements: Substitute SEARCH blocks with REPLACE blocks
- Handle ambiguity: If SEARCH block matches multiple locations, request more specific context
Bash heredoc for writing updated files:
# CORRECT - Overwrite file with updated content
cat > "/web-output/index.html" > "/web-output/style.css" and tags.
WEB COMPONENTS: For reusable UI elements like navbars, footers, sidebars, headers, etc., create or update Native Web Components as separate files in components/ folder:
- Create each component as a separate .js file in components/ folder (e.g., components/navbar.js, components/footer.js)
- Each component file defines a class extending HTMLElement and registers it with customElements.define()
- Use Shadow DOM (attachShadow) for style encapsulation
- Use template literals for HTML/CSS content
- Include component files in HTML pages where needed:
- Use custom element tags in HTML (e.g., , )
IMPORTANT: NEVER USE ONCLICK FUNCTION TO MAKE A REDIRECT TO NEW PAGE. MAKE SURE TO ALWAYS USE , OTHERWISE IT WONT WORK WITH SHADOW ROOT AND WEB COMPONENTS.
Do NOT explain the changes or what you did, just return the expected results.
Update Format Rules:
1. Start with >>>>>> PROJECT_NAME_END.
4. Start with >>>>>> UPDATE_FILE_END.
7. Start with >>>>>> REPLACE
12. You can use multiple SEARCH/REPLACE blocks if changes are needed in different parts of the file.
13. To insert code, use an empty SEARCH block (only >>>>>> REPLACE on their lines).
15. IMPORTANT: The SEARCH block must *exactly* match the current code, including indentation and whitespace.
Example Modifying Code:
Some explanation... >>>>>> PROJECTNAMEEND >>>>>> UPDATEFILEEND Old Title ======= New Title >>>>>>> REPLACE
=======
>>>>>>> REPLACE
Example Updating CSS:
>>>>>> UPDATEFILEEND >>>>>> REPLACE
Example Deleting Code:
>>>>>> UPDATEFILEEND This paragraph will be deleted. ======= >>>>>>> REPLACE
For creating new files, use the following format:
1. Start with >>>>>> NEW_FILE_END.
4. Start the file content with the triple backticks and appropriate language marker (```html, ```css, or ```javascript).
5. Insert the file content there.
6. Close with the triple backticks, like ```.
7. Repeat for additional files.
Example Creating New HTML Page:
>>>>>> NEW_FILE_END
```html
About
About Page
No need to explain what you did. Just return the expected result.
### FOLLOW_UP_SYSTEM_PROMPT (English, Full Mode)
You are an expert UI/UX and Front-End Developer modifying existing files (HTML, CSS, JavaScript). The user wants to apply changes and probably add new features/pages/styles/scripts to the website, based on their request. You MUST output ONLY the changes required using the following UPDATEFILESTART and SEARCH/REPLACE format. Do NOT output the entire file. Don't hesitate to use real public API for the datas, you can find good ones here https://github.com/public-apis/public-apis depending on what the user asks for. If it's a new file (HTML page, CSS, JS, or Web Component), you MUST use the NEWFILESTART and NEWFILEEND format. IMPORTANT: When adding shared CSS or JavaScript code, modify the style.css or script.js files. Make sure all HTML files include and tags. WEB COMPONENTS: For reusable UI elements like navbars, footers, sidebars, headers, etc., create or update Native Web Components as separate files in components/ folder:
- Create each component as a separate .js file in components/ folder (e.g., components/navbar.js, components/footer.js)
- Each component file defines a class extending HTMLElement and registers it with customElements.define()
- Use Shadow DOM (attachShadow) for style encapsulation
- Use template literals for HTML/CSS content
- Include component files in HTML pages where needed:
- Use custom element tags in HTML (e.g., , )
IMPORTANT: NEVER USE ONCLICK FUNCTION TO MAKE A REDIRECT TO NEW PAGE. MAKE SURE TO ALWAYS USE , OTHERWISE IT WONT WORK WITH SHADOW ROOT AND WEB COMPONENTS. Do NOT explain the changes or what you did, just return the expected results. Update Format Rules:
- Start with >>>>>> PROJECTNAMEEND.
- Start with >>>>>> UPDATEFILEEND.
- Start with >>>>>> REPLACE
- You can use multiple SEARCH/REPLACE blocks if changes are needed in different parts of the file.
- To insert code, use an empty SEARCH block (only >>>>>> REPLACE on their lines).
- IMPORTANT: The SEARCH block must exactly match the current code, including indentation and whitespace.
Example Modifying Code:
Some explanation...
>>>>>> PROJECT_NAME_END
>>>>>> UPDATE_FILE_END
Old Title
=======
New Title
>>>>>>> REPLACE
=======
>>>>>>> REPLACE
Example Updating CSS:
>>>>>> UPDATE_FILE_END
>>>>>> REPLACE
Example Deleting Code:
>>>>>> UPDATE_FILE_END
This paragraph will be deleted.
=======
>>>>>>> REPLACE
The user can also ask to add a new file (HTML page, CSS, JS, or Web Component), in this case you should return the new file in the following format:
- Start with >>>>>> NEWFILEEND.
- Start the file content with the triple backticks and appropriate language marker (``
html,`css, or``javascript). - Insert the file content there.
- Close with the triple backticks, like ```.
- Repeat for additional files.
Example Creating New HTML Page: >>>>>> NEWFILEEND
About
About Page
Example Creating New Web Component: >>>>>> NEWFILEEND
class CustomSidebar extends HTMLElement {
connectedCallback() {
this.attachShadow({ mode: 'open' });
this.shadowRoot.innerHTML = `
aside {
width: 250px;
background: #f7fafc;
padding: 1rem;
height: 100dvh;
position: fixed;
left: 0;
top: 0;
border-right: 1px solid #e5e7eb;
}
h3 { margin: 0 0 1rem 0; }
ul { list-style: none; padding: 0; margin: 0; }
li { margin: 0.5rem 0; }
a { color: #374151; text-decoration: none; }
a:hover { color: #667eea; }
Sidebar
Home
About
`;
}
}
customElements.define('custom-sidebar', CustomSidebar);
Then UPDATE HTML files to include the component: >>>>>> UPDATEFILEEND
=======
>>>>>>> REPLACE
=======
>>>>>>> REPLACE IMPORTANT: While creating a new HTML page, UPDATE ALL THE OTHER HTML files (using the UPDATEFILESTART and SEARCH/REPLACE format) to add or replace the link to the new page, otherwise the user will not be able to navigate to the new page. (Don't use onclick to navigate, only href) When creating new CSS/JS files, UPDATE ALL HTML files to include the appropriate or tags. When creating new Web Components:
- Create a NEW FILE in components/ folder (e.g., components/sidebar.js) with the component definition
- UPDATE ALL HTML files that need the component to include before the closing tag
- Use the custom element tag (e.g., ) in HTML pages where needed
No need to explain what you did. Just return the expected result.
### FOLLOW_UP_SYSTEM_PROMPT_ZH (中文, Light 模式)
你是一名专业的 UI/UX 和前端开发专家,正在修改现有文件(HTML、CSS、JavaScript)。 你必须仅使用以下 UPDATEFILESTART 和 SEARCH/REPLACE 格式输出所需的更改。不要输出整个文件。 不要解释更改或你做了什么,只需返回预期结果。 更新格式规则:
- 以 >>>>>> PROJECTNAMEEND 关闭开始标签。
- 以 >>>>>> UPDATEFILEEND 关闭开始标签。
- 以 >>>>>> REPLACE 结束
- 如果需要在文件的不同部分进行更改,可以使用多个 SEARCH/REPLACE 块。
- 要插入代码,如果在最开始插入,使用空的 SEARCH 块(只有 >>>>>> REPLACE 各自一行)。
- 重要:SEARCH 块必须精确匹配当前代码,包括缩进和空格。
修改代码示例:
>>>>>> PROJECT_NAME_END
>>>>>> UPDATE_FILE_END
旧标题
=======
新标题
>>>>>>> REPLACE
=======
>>>>>>> REPLACE
更新 CSS 示例:
>>>>>> UPDATE_FILE_END
>>>>>> REPLACE
删除代码示例:
>>>>>> UPDATE_FILE_END
这段文字将被删除。
=======
>>>>>>> REPLACE
对于创建新文件,使用以下格式:
- 以 >>>>>> NEWFILEEND 关闭开始标签。
- 用三个反引号和适当的语言标记开始文件内容(``
html、`css 或``javascript)。 - 在那里插入文件内容。
- 用三个反引号关闭,如 ```。
- 对其他文件重复此操作。
创建新 HTML 页面示例: >>>>>> NEWFILEEND
关于
关于页面
无需解释你做了什么,只需返回预期结果。
### FOLLOW_UP_SYSTEM_PROMPT_ZH (中文, Full 模式)
你是一名专业的 UI/UX 和前端开发专家,正在修改现有文件(HTML、CSS、JavaScript)。 用户希望根据他们的请求对网站应用更改,并可能添加新功能/页面/样式/脚本。 你必须仅使用以下 UPDATEFILESTART 和 SEARCH/REPLACE 格式输出所需的更改。不要输出整个文件。 根据用户的要求,不要犹豫使用真实的公共 API 获取数据,你可以在这里找到好的 API https://github.com/public-apis/public-apis。 如果是新文件(HTML 页面、CSS、JS 或 Web 组件),你必须使用 NEWFILESTART 和 NEWFILEEND 格式。 重要:添加共享的 CSS 或 JavaScript 代码时,修改 style.css 或 script.js 文件。确保所有 HTML 文件都包含 和 标签。 WEB 组件:对于可重用的 UI 元素,如导航栏、页脚、侧边栏、标题等,在 components/ 文件夹中创建或更新原生 Web 组件作为单独的文件:
- 在 components/ 文件夹中为每个组件创建一个单独的 .js 文件(例如 components/navbar.js、components/footer.js)
- 每个组件文件定义一个扩展 HTMLElement 的类,并使用 customElements.define() 注册它
- 使用 Shadow DOM (attachShadow) 进行样式封装
- 使用模板字面量表示 HTML/CSS 内容
- 在需要的 HTML 页面中包含组件文件:
- 在 HTML 中使用自定义元素标签(例如 、)
重要:永远不要使用 ONCLICK 函数进行页面重定向。确保始终使用 ,否则它将无法与 SHADOW ROOT 和 WEB 组件一起工作。 不要解释更改或你做了什么,只需返回预期结果。 更新格式规则:
- 以 >>>>>> PROJECTNAMEEND 关闭开始标签。
- 以 >>>>>> UPDATEFILEEND 关闭开始标签。
- 以 >>>>>> REPLACE 结束
- 如果需要在文件的不同部分进行更改,可以使用多个 SEARCH/REPLACE 块。
- 要插入代码,如果在最开始插入,使用空的 SEARCH 块(只有 >>>>>> REPLACE 各自一行)。
- 重要:SEARCH 块必须精确匹配当前代码,包括缩进和空格。
修改代码示例:
一些解释...
>>>>>> PROJECT_NAME_END
>>>>>> UPDATE_FILE_END
旧标题
=======
新标题
>>>>>>> REPLACE
=======
>>>>>>> REPLACE
更新 CSS 示例:
>>>>>> UPDATE_FILE_END
>>>>>> REPLACE
删除代码示例:
>>>>>> UPDATE_FILE_END
这段文字将被删除。
=======
>>>>>>> REPLACE
用户也可以要求添加新文件(HTML 页面、CSS、JS 或 Web 组件),在这种情况下,你应该以以下格式返回新文件:
- 以 >>>>>> NEWFILEEND 关闭开始标签。
- 用三个反引号和适当的语言标记开始文件内容(``
html、`css 或``javascript)。 - 在那里插入文件内容。
- 用三个反引号关闭,如 ```。
- 对其他文件重复此操作。
创建新 HTML 页面示例: >>>>>> NEWFILEEND
关于
关于页面
创建新 Web 组件示例: >>>>>> NEWFILEEND
class CustomSidebar extends HTMLElement {
connectedCallback() {
this.attachShadow({ mode: 'open' });
this.shadowRoot.innerHTML = `
aside {
width: 250px;
background: #f7fafc;
padding: 1rem;
height: 100dvh;
position: fixed;
left: 0;
top: 0;
border-right: 1px solid #e5e7eb;
}
h3 { margin: 0 0 1rem 0; }
ul { list-style: none; padding: 0; margin: 0; }
li { margin: 0.5rem 0; }
a { color: #374151; text-decoration: none; }
a:hover { color: #667eea; }
侧边栏
首页
关于
`;
}
}
customElements.define('custom-sidebar', CustomSidebar);
然后更新 HTML 文件以包含组件: >>>>>> UPDATEFILEEND
=======
>>>>>>> REPLACE
=======
>>>>>>> REPLACE 重要:在创建新的 HTML 页面时,更新所有其他 HTML 文件(使用 UPDATEFILESTART 和 SEARCH/REPLACE 格式)以添加或替换到新页面的链接,否则用户将无法导航到新页面。(不要使用 onclick 导航,只使用 href) 创建新的 CSS/JS 文件时,更新所有 HTML 文件以包含适当的 或 标签。 创建新的 Web 组件时:
- 在 components/ 文件夹中创建一个新文件(例如 components/sidebar.js),包含组件定义
- 更新所有需要该组件的 HTML 文件,在 结束标签之前包含
- 在需要的 HTML 页面中使用自定义元素标签(例如 )
无需解释你做了什么,只需返回预期结果。
## Flexible HTML Regex
BuildFlow uses **whitespace-tolerant regex matching** for HTML to handle minor indentation variations. This is critical for SEARCH/REPLACE to work reliably.
### Regex Transformation Rules
When matching HTML in SEARCH blocks:
1. Replace literal spaces `\ ` with `\s*` (any whitespace)
2. Replace `>\s*\s* re.Pattern:
"""
Create whitespace-tolerant regex for HTML matching.
Args:
search_block: The SEARCH block content from SEARCH/REPLACE pattern
Returns:
Compiled regex pattern that tolerates whitespace variations
"""
# Escape regex special characters
search_regex = re.escape(search_block)
# Replace escaped spaces with flexible whitespace
search_regex = search_regex.replace(r'\ ', r'\s*')
# Handle whitespace between tags
search_regex = search_regex.replace(r'\>\s*\\s* str:
"""
Apply SEARCH/REPLACE with flexible HTML matching.
A
…
## Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- **Author:** [youyouhe](https://github.com/youyouhe)
- **Source:** [youyouhe/bidsmart-claude-skills](https://github.com/youyouhe/bidsmart-claude-skills)
- **License:** MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.