AGENT SKILL

浏览器画布渲染验证

browser-canvas-validation

首先使用 Copilot 浏览器画布(browser canvas)进行渲染路由检查、交互测试、截图以及视觉、响应式或无障碍方面的证据收集。仅在画布无法执行某项必需检查时,才使用已配置的隔离 Playwright MCP。

适用职业测试工程师
License 许可
MIT
所属仓库
github/replica
最近更新
2026-11-15
Stars
★ 273
Forks
35

01 前言 Front Matter

name
browser-canvas-validation
description
Use the Copilot browser canvas first for rendered route checks, interaction tests, screenshots and visual, responsive or accessibility evidence. Use configured isolated Playwright MCP only when the canvas is unavailable for a required check.

02 资源文件 1

03 SKILL.md 正文

Browser canvas validation

Canvas inspection requires a Copilot host exposing the browser canvas. It is not a universal browser API. A repository-configured isolated Playwright MCP fallback can cover authorized checks only when the canvas is unavailable for that check. This policy also governs browser evidence gathered by other skills and agent work. Existing automated suites and CI/capture drivers remain unchanged. Default to read-only validation of the requested outcome. A validation request does not authorize source fixes, commits, publishing or real application mutations. Use approved test state and confirm side effects before submissions, deletion, messages or changes to authentication.

Required reads and dependencies

Read context resolution and the complete workflow before driving a page. Install product-design for the shared resolver and scenario policy. The optional agent-browser fallback is needed only for an explicit CLI-only request or a named requirement neither the canvas nor configured MCP fallback can meet, not for ordinary checks. If a required companion or sibling skill is missing, stop and name its path before checks. Do not auto-install dependencies.

Select the first existing root, .agents/context/, then .github/contexts/. Read the applicable BROWSER-VALIDATION.md sections and owner topics for target/readiness, canvas identifiers, safe state and recovery. In the shared template, these are Target and readiness, Canvas host and identifiers, Sessions, safe state and artifacts, and Recovery and cleanup. Read Configured Playwright MCP fallback or Existing CLI adapter only when that fallback is needed.

Read the applicable REPOSITORY.md section for the target (Where UI lives in the shared template), Commands when a command is needed, and Constraints for relevant permissions or lifecycle. Follow applicable owner links. If a consumer uses different headings, select the equivalent sections by owner rather than reading the entire file.

Read PRODUCT-DESIGN.md when expected product behavior is unresolved, when assessing scenario behavior or fidelity, or when checking forms, persistence, destructive actions or externally visible changes. A fully specified, read-only route or menu check can use the request as its expected outcome. Read DESIGN-SYSTEM.md for component-specific assertions, ACCESSIBILITY.md for accessibility checks and RESPONSIVE-DESIGN.md for responsive checks. No manifest or canvas-specific pack file is required. Never mix roots.

Missing required context stops validation. Report the selected root/file and offer setup-skills to author or refresh context under the shared resolution rules. Do not invoke it automatically. Never read drafts as active context. Follow relevant owner links and evidence anchors, preserve proposed-default labels and disclose conflicts. Read the complete applicable owner sections, not unrelated sections or topics. Product context owns scenarios and state policy. Browser context owns target URL, server, routes and recovery.

Use only permitted sources. Do not research remotely or broaden exclusions during validation. Request explicit refresh if required documentation is stale or missing. A document with gaps does not prove runtime capabilities.

Runtime contract

Do not discover canvas capabilities for source-only tasks. For rendered checks, identify the browser canvas and inspect its actual schemas before the first required operation. Reuse a schema already discovered for the same provider in this session. Rediscover only after provider reload/reconnect, a schema mismatch or an explicit request to check for changed capabilities; a timeout alone does not invalidate it. Never carry schemas across providers or sessions.

If the browser canvas or required tools are absent, report the blocker and use only the explicit configured MCP handoff in WORKFLOW.md when applicable. Use the advertised open input and action schemas; no frozen action list overrides the runtime.

Keep the canvas type and caller-chosen instanceId handle distinct. Address the panel with that handle through invoke_canvas_action. If the advertised action needs no separate page identifier, call it directly; do not wait for a page-acquisition tool. Reuse a context-declared session handle when appropriate. Only when an action schema requires a separate page identifier, obtain it from runtime results or an explicit supported host contract. If discovery and returned identifiers cannot satisfy an action schema, report the mismatch and stop rather than inventing a value or an unavailable tool. Missing required page acquisition may use the same explicit MCP handoff; it is not an action failure or permission to infer IDs. A missing action can use that handoff for the affected assertion only; keep supported checks in the canvas.

Open/reuse once, read fresh rendered structure, assert the target rendered, then act using observed elements and advertised actions. Re-read after DOM changes, navigation or reload before using refs. Do not assume a click returns a snapshot or that scoped reads/batching exist. Details and recovery are in WORKFLOW.md.

Output

Report target, context document paths, runtime, tested state/flow, assertions and evidence. Separate confirmed failures from unavailable or untested assertions. An overall pass requires every applicable requested assertion to be verified. No render, missing evidence or unavailable runtime means failed or incomplete validation. Static checks do not prove live browser behavior. Do not automatically run broader design, accessibility, responsive or cross-browser audits.

04 同仓库更多 Skills

github
github/replica

create-prototype-from-production

Use when asked to copy, clone, replicate or recreate a live production website or web app as a Replica prototype from its URL, such as "create a prototype from https://example.com" or "replicate this site for a demo". Do not use for building a new design from a brief, or for changing an existing prototype.

★ 273
github
github/replica

页面视觉设计评审

visual-design-review

依据使用方自有的产品与设计系统指南,审查页面层级、分组、密度、操作及状态设计。当用户要求视觉设计评审、页面点评,或询问新页面是否清晰传达其任务时使用。

界面设计师视觉设计
★ 273
github
github/replica

技能共享源配置与上下文起草

setup-skills

配置共享源,并使用独立的 writer 起草上下文。普通/全新设置会提供用户指定包的安装,并复用内置浏览器能力,仅在确有证据表明必要检查存在缺口时才添加浏览器工具。适用于设置、源修复、编写上下文或刷新草稿。仅配置模式会跳过工具安装和编写;安装和激活需要单独批准。

AI 工程师插件与技能管理
★ 273
github
github/replica

Hub 反馈设计主题提炼

review-hub-feedback

通过发现、独立判断和综合归纳,审查 Hub 反馈以提炼可复用的设计主题。不进行诊断或优化。

界面设计师用户反馈处理
★ 273
github
github/replica

UI 响应式布局审计

responsive-audit

使用使用者上下文和浏览器工具,跨产品定义的视口审查 UI 布局、溢出和导航。当用户要求检查响应式、测试移动端布局或审查断点行为时使用。

软件开发工程师前端开发与界面实现
★ 273
github
github/replica

Replica 原型控件创建与绑定

prototype-controls

创建并连接 Replica 原型控件。当用户要求添加或修改下拉框、滑块、输入框、切换开关或操作按钮(用于配置变体、场景、可见 UI、应用状态或数据源)时使用,即使未使用画布术语也一样。涵盖声明、类型化绑定、默认值、条件、重置和动作。仅涉及产品 UI 表单字段和筛选器时,应使用 create-prototype。

界面设计师低代码应用开发
★ 273