Skip to content

Commit a9e75fc

Browse files
authored
Merge branch 'main' into 2955-add-openfort-signer-guide
2 parents 317f71b + 4035907 commit a9e75fc

2,814 files changed

Lines changed: 4075 additions & 98640 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.cursor/rules/content-types.mdc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,15 +68,15 @@ Examples:
6868
- Describe and only describe. Be austere, neutral, and factual.
6969
- Match the parameter format used in surrounding reference pages. Some areas use tables (name,
7070
type, required/optional, description); others use nested bulleted lists (for example, JSON-RPC
71-
method docs in Services). Be consistent with the existing convention in the same product section.
71+
method docs in Snaps). Be consistent with the existing convention in the same product section.
7272
- Adopt standard patterns. Consistent structure lets readers find information quickly.
7373
- Mirror the structure of the API or code itself (for example, one section per method or endpoint).
7474
- Include short usage examples to illustrate parameters and return values.
7575
- Keep explanatory prose to the minimum needed to use the API correctly.
7676
- Do not include tutorials or extended how-to steps.
7777
- Examples: `snaps/reference/config-options.md`,
7878
`smart-accounts-kit/reference/delegation/delegation-scopes.md`,
79-
`services/reference/solana/json-rpc-methods`
79+
`snaps/reference/snaps-api/wallet_snap`
8080

8181
### `tutorials/` - Tutorial
8282

.cursor/rules/contributor-workflow.mdc

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,16 @@ the requirements that are most often missed.
1212

1313
Every new documentation page must be added to the appropriate sidebar file:
1414

15-
| Product | Sidebar file |
16-
| ------------------- | ------------------------- |
17-
| MetaMask Connect | `mm-connect-sidebar.js` |
18-
| Embedded Wallets | `ew-sidebar.js` |
19-
| Smart Accounts Kit | `gator-sidebar.js` |
20-
| Agent Wallet | `agent-wallet-sidebar.js` |
21-
| Services | `services-sidebar.js` |
22-
| Developer dashboard | `dashboard-sidebar.js` |
23-
| Snaps | `snaps-sidebar.js` |
15+
| Product | Sidebar file |
16+
| ------------------ | ------------------------- |
17+
| MetaMask Connect | `mm-connect-sidebar.js` |
18+
| Embedded Wallets | `ew-sidebar.js` |
19+
| Smart Accounts Kit | `gator-sidebar.js` |
20+
| Agent Wallet | `agent-wallet-sidebar.js` |
21+
| Agent Wallet | `agent-wallet-sidebar.js` |
22+
| Snaps | `snaps-sidebar.js` |
23+
24+
Infura API and dashboard documentation is maintained in [docs.infura](https://github.com/INFURA/docs.infura), not in this repository. Link to `https://docs.infura.io/` from MetaMask docs when referencing Infura APIs or the Infura dashboard.
2425

2526
## Redirects
2627

@@ -43,7 +44,6 @@ Place images in the product's designated asset folder:
4344
- `metamask-connect/*/_assets/`
4445
- `static/img/embedded-wallets/` (Embedded Wallets product images)
4546
- `smart-accounts-kit/assets/`
46-
- `services/images/`
4747
- `snaps/assets/`
4848
- `static/img/` (for site-wide assets)
4949

@@ -85,6 +85,13 @@ that enforces Microsoft style, Consensys terminology, and spelling. Fix any lint
8585
requesting review. If a warning is a false positive, add the term to the Vale vocabulary file rather
8686
than rewriting valid technical language.
8787

88+
> **Warning:** Do not wire Vale into the Husky `pre-commit` hook (`lint-staged` in `package.json`).
89+
> Vale is intentionally CI-only. It frequently reports false positives on valid technical content
90+
> (for example, code identifiers like `wagmi-tab`, product names, and intentional ellipses) and lints
91+
> the entire staged file rather than just your diff, so running it on commit blocks unrelated,
92+
> pre-existing content and stalls otherwise-valid commits. Let the PR CI run Vale; contributors can
93+
> still run it on demand with `npm run docs:ci`.
94+
8895
## Pull requests
8996

9097
- Summarize what changed and why in the PR description. Do not just list files.

.cursor/rules/product-infura.mdc

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
description: Infura documentation has moved to docs.infura.io. Do not add Infura API or dashboard content to metamask-docs.
3+
alwaysApply: true
4+
---
5+
6+
# Infura documentation
7+
8+
Infura API reference, guides, and dashboard documentation are published at [docs.infura.io](https://docs.infura.io/).
9+
10+
- **Repository:** [INFURA/docs.infura](https://github.com/INFURA/docs.infura)
11+
- **Dashboard:** [app.infura.io](https://app.infura.io/)
12+
13+
When MetaMask product docs need to reference Infura:
14+
15+
- Use absolute links to `https://docs.infura.io/` (for example, `https://docs.infura.io/dashboard/get-started/create-api/`).
16+
- Do not recreate Infura content under `services/` or `developer-tools/dashboard/` in this repository.
17+
- The faucet remains on MetaMask docs at `/developer-tools/faucet/`.
18+
19+
Cross-domain redirects in `vercel.json` send legacy `/services/*` and `/developer-tools/dashboard/*`
20+
URLs to `https://docs.infura.io/`. List specific rules before the catch-all fallbacks; map renamed
21+
paths (for example `/services/gas-api/` → `https://docs.infura.io/reference/gas-api/`). The faucet
22+
stays on MetaMask docs at `/developer-tools/faucet/` and is not redirected.

.cursor/rules/product-services.mdc

Lines changed: 0 additions & 61 deletions
This file was deleted.

.cursor/skills/author-page/SKILL.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ Help create a new documentation page that follows MetaMask editorial standards f
1919
Ask the user for any information they have not already provided:
2020

2121
1. **Product area** - which product is this for? (MetaMask Connect, Embedded Wallets,
22-
Smart Accounts Kit, Services, Snaps, Developer Tools)
22+
Smart Accounts Kit, Agent Wallet, Snaps). Infura API and dashboard docs live at
23+
[Infura documentation](https://docs.infura.io/) and are not authored in this repository.
2324
2. **Content type** - what kind of page? (concept/explanation, how-to guide, quickstart,
2425
reference, tutorial, troubleshooting)
2526
3. **Topic** - what is the page about?
@@ -43,9 +44,9 @@ front-matter fields, intro style, and parameter formats.
4344

4445
Create the file with the correct structure for its content type.
4546

46-
### Frontmatter
47+
### Page metadata
4748

48-
Follow **Frontmatter** in `.cursor/rules/markdown-formatting.mdc` (required `description`,
49+
Follow page metadata rules in `.cursor/rules/markdown-formatting.mdc` (required `description`,
4950
recommended `keywords`, optional `sidebar_label` only when the nav label would otherwise be too
5051
long or wordy, and the `title` vs duplicate H1 rule). Do not repeat or contradict that rule here.
5152

@@ -217,11 +218,11 @@ description: <one sentence>
217218

218219
Fill in the scaffold with content based on what the user provides. Follow these rules:
219220

220-
- **Voice**: active, present tense, second person ("you"). Use contractions naturally.
221+
- **Voice**: active, present tense, second person ("you"). Use contractions where appropriate.
221222
- **First sentence**: get to the point. Answer "what" or "why" immediately.
222223
- **No em/en dashes**: use commas, parentheses, or semicolons.
223224
- **Sentence case** for all headings.
224-
- **One sentence per line**, wrapped at roughly 100 columns.
225+
- **One sentence per line**, wrapped at about 100 columns.
225226
- **Code blocks**: always include a language tag. Use `bash npm2yarn` for install commands.
226227
- **Terminology**: use the required forms from `terminology.mdc`.
227228
- **No marketing language**: no "powerful," "seamless," "best-in-class."
@@ -232,7 +233,7 @@ Fill in the scaffold with content based on what the user provides. Follow these
232233

233234
Before finishing, check:
234235

235-
- [ ] Frontmatter has `description`; add `sidebar_label` only when the default nav label would be
236+
- [ ] Page metadata includes `description`; add `sidebar_label` only when the default nav label would be
236237
too long or wordy (see `markdown-formatting.mdc`).
237238
- [ ] Opening paragraph answers "what" and "why" in the first 1-2 sentences.
238239
- [ ] Structure matches the content type.

.cursor/skills/style-review/SKILL.md

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@ The user provides a file path or directory to review. If not provided, ask what
2121
Read the file path to determine:
2222

2323
1. **Product area** - which product folder the file lives in (for example, `metamask-connect/`,
24-
`services/`, `snaps/`). Load the corresponding product rule from `.cursor/rules/product-*.mdc`.
25-
2. **Content type** - which subfolder determines the expected structure (for example, `concepts/`,
24+
`snaps/`, `agent-wallet/`). Load the corresponding product rule from `.cursor/rules/product-*.mdc`.
25+
For Infura content, use `.cursor/rules/product-infura.mdc` and link to Infura documentation.
26+
2. **Content type** - which folder determines the expected structure (for example, `concepts/`,
2627
`how-to/`, `reference/`). Use `.cursor/rules/content-types.mdc` for the mapping.
2728

2829
## Step 2: Run Vale (if available)
@@ -44,7 +45,7 @@ source of truth for full criteria, examples, and edge cases.
4445

4546
- Active voice and present tense used throughout.
4647
- Second person ("you"), not "the developer" or "users."
47-
- Contractions used naturally.
48+
- Contractions used where appropriate.
4849
- No marketing language, superlatives, or promotional tone.
4950
- No em dashes or en dashes; use commas, parentheses, or semicolons.
5051
- First sentence of each section gets to the point.
@@ -57,16 +58,16 @@ source of truth for full criteria, examples, and edge cases.
5758
"Chain Agnostic Improvement Proposal 25 (CAIP-25)"), short form on subsequent references.
5859
- Product-specific terminology matches the corresponding `product-*.mdc` rule file.
5960

60-
### Markdown formatting (markdown-formatting.mdc)
61+
### Markdown formatting (`markdown-formatting.mdc`)
6162

62-
- Lines wrapped at roughly 100 columns.
63+
- Lines wrapped at about 100 columns.
6364
- Each sentence on its own line.
6465
- Code blocks have a language tag.
6566
- Links use relative paths within the product, absolute paths across products.
6667
- Descriptive link text; no "click here" or bare URLs.
6768
- Admonitions use Docusaurus syntax and are not nested.
6869
- Tables are aligned in source Markdown.
69-
- No duplicate H1 if frontmatter contains a `title` field.
70+
- No duplicate H1 if page metadata contains a `title` field.
7071

7172
### Content type compliance (content-types.mdc)
7273

@@ -77,11 +78,11 @@ source of truth for full criteria, examples, and edge cases.
7778
- Quickstart pages: complete, copy-paste-and-run code.
7879
- Troubleshooting pages: symptom/error first, then fix.
7980

80-
### Frontmatter
81+
### Page metadata
8182

8283
- `description` field present (one sentence for SEO).
8384
- `sidebar_label` only when needed (default nav label would be too long or wordy); otherwise omit.
84-
- No duplicate H1 if `title` is set in frontmatter.
85+
- No duplicate H1 if `title` is set in page metadata.
8586

8687
### Contributor workflow (contributor-workflow.mdc)
8788

@@ -94,7 +95,7 @@ source of truth for full criteria, examples, and edge cases.
9495
Present findings as a structured report grouped by category. For each issue:
9596

9697
1. **Line number** - approximate location in the file.
97-
2. **Category** - Voice/Tone, Terminology, Formatting, Content Type, Frontmatter, or Workflow.
98+
2. **Category** - Voice/Tone, Terminology, Formatting, Content Type, Page metadata, or Workflow.
9899
3. **Issue** - what is wrong.
99100
4. **Suggestion** - how to fix it.
100101

@@ -123,7 +124,7 @@ Present findings as a structured report grouped by category. For each issue:
123124
- Page is in `concepts/` but contains numbered step-by-step instructions. Move steps to a
124125
how-to page and link to it.
125126
126-
### Frontmatter
127+
### Page metadata
127128
- Missing `description` field.
128129
```
129130

.github/workflows/ci.yml

Lines changed: 59 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,18 +102,75 @@ jobs:
102102
if: steps.changed-files.outputs.any_changed != 'true'
103103
run: echo "No matching changed files; Prettier check skipped."
104104

105+
# Vale checks spelling/style on changed .md/.mdx files and fails on real Vale errors,
106+
# matching what runs locally (scripts/docs-pre-commit-check.sh) so "passes locally"
107+
# means "passes on CI". The matrix keeps the required check names "Spelling (.md)" and
108+
# "Spelling (.mdx)". Vale runs directly (not via the reviewdog-based composite action)
109+
# so large PRs do not hit GitHub's 300-file diff limit, which is an infrastructure
110+
# failure unrelated to content.
105111
spelling:
106112
name: Spelling
107113
runs-on: ubuntu-latest
108114
strategy:
115+
fail-fast: false
109116
matrix:
110117
file-extensions: ['.md', '.mdx']
111118
steps:
112119
- uses: actions/checkout@v6
113120
with:
114121
fetch-depth: 0
115-
- name: Vale
116-
uses: Consensys/github-actions/docs-spelling-check@main
122+
- name: Checkout Vale config
123+
uses: actions/checkout@v6
124+
with:
125+
repository: Consensys/github-actions
126+
path: .github-actions
127+
- name: Changed files
128+
id: changed-files
129+
uses: tj-actions/changed-files@22103cc46bda19c2b464ffe86db46df6922fd323 # 47.0.5; pin matches docs-spelling-check
130+
with:
131+
path: .
132+
files: '**/*${{ matrix.file-extensions }}'
133+
separator: ','
134+
- name: Install Vale
135+
if: steps.changed-files.outputs.any_changed == 'true'
136+
env:
137+
VALE_VERSION: '3.15.1'
138+
run: |
139+
set -euo pipefail
140+
curl -sSfL "https://github.com/errata-ai/vale/releases/download/v${VALE_VERSION}/vale_${VALE_VERSION}_Linux_64-bit.tar.gz" -o /tmp/vale.tar.gz
141+
sudo tar -xzf /tmp/vale.tar.gz -C /usr/local/bin vale
142+
vale --version
143+
(cd .github-actions/docs-spelling-check && vale sync)
144+
- name: Run Vale
145+
if: steps.changed-files.outputs.any_changed == 'true'
146+
# Vale is advisory only and must not block merges: it produces false positives on
147+
# valid technical content (code identifiers like `wagmi-tab`, product names,
148+
# intentional ellipses). `continue-on-error` MUST be at the step (not the job) so
149+
# the job still concludes "success" and the required "Spelling" check passes while
150+
# findings stay visible in the logs. Job-level `continue-on-error` does not work
151+
# here: it only keeps the overall run green, but the job's own check run stays
152+
# "failure" and a required status check keeps blocking the merge.
153+
continue-on-error: true
154+
env:
155+
ALL_CHANGED_FILES: ${{ steps.changed-files.outputs.all_changed_files }}
156+
run: |
157+
set -euo pipefail
158+
files=()
159+
IFS=',' read -ra raw <<< "$ALL_CHANGED_FILES"
160+
for f in "${raw[@]}"; do
161+
f="${f#"${f%%[![:space:]]*}"}"
162+
f="${f%"${f##*[![:space:]]}"}"
163+
[ -z "$f" ] && continue
164+
[ -f "$f" ] && files+=("$f")
165+
done
166+
if [ ${#files[@]} -eq 0 ]; then
167+
echo "No existing ${{ matrix.file-extensions }} files to check."
168+
exit 0
169+
fi
170+
vale --config .github-actions/docs-spelling-check/.vale.ini "${files[@]}"
171+
- name: No spelling-scoped files changed
172+
if: steps.changed-files.outputs.any_changed != 'true'
173+
run: echo 'No matching changed files; Vale check skipped.'
117174

118175
linkCheck:
119176
name: Link Checking

.linkspector.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
dirs:
22
- ./smart-accounts-kit
3-
- ./developer-tools
43
- ./embedded-wallets
54
- ./metamask-connect
6-
- ./services
75
- ./snaps
86
excludedDirs:
97
- ./build
@@ -22,14 +20,15 @@ ignorePatterns:
2220
- pattern: '^http(s)?://help.figma.com'
2321
- pattern: '^http(s)?://metamask.io'
2422
- pattern: '^http(s)?://rivet.cloud'
23+
- pattern: '^http(s)?://tenderly\.co'
24+
- pattern: '^http(s)?://docs\.tenderly\.co($|/.*)'
2525
- pattern: '^http(s)?://app\.infura\.io($|/.*)'
2626
- pattern: '^http(s)?://docs.arbitrum.io($|/.*)'
2727
- pattern: '^/img/'
2828
- pattern: '^/smart-accounts-kit/'
2929
- pattern: '^/developer-tools/'
3030
- pattern: '^/embedded-wallets/'
3131
- pattern: '^/metamask-connect/'
32-
- pattern: '^/services/'
3332
- pattern: '^/snaps/'
3433
- pattern: '^/wallet/'
3534
- pattern: '^/tutorials/'
@@ -38,6 +37,7 @@ ignorePatterns:
3837
- pattern: 'https://0xfury.com/privacy'
3938
- pattern: '^https://docs.arbitrum.io'
4039
- pattern: '^https://nodefleet.org'
40+
- pattern: '^https://bwarelabs.com'
4141
aliveStatusCodes:
4242
- 200
4343
- 206

0 commit comments

Comments
 (0)