i18n(es): add missing docs in folder /es/storage-api.#220
Conversation
New files: - api-endpoint.mdx - index.mdx - javascript-helpers.mx
Dokploy Preview Deployment
|
📝 WalkthroughWalkthroughThis PR adds three new Spanish-language documentation files for the Storage API, including endpoint specifications, configuration examples, and JavaScript helpers documentation. A NoOpStorageService code example is included to illustrate storage manager implementation patterns. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Lunaria Status Overview🌕 This pull request will trigger status changes. Learn moreBy default, every PR changing files present in the Lunaria configuration's You can change this by adding one of the keywords present in the Tracked Files
Warnings reference
|
There was a problem hiding this comment.
Actionable comments posted: 4
🧹 Nitpick comments (1)
src/content/docs/es/storage-api/api-endpoint.mdx (1)
24-24: Heading hierarchy skips level 2 — consider adding an##parent section.
### Method: PUTand### Method: POST(h3) are the first headings on the page with no enclosing h2 parent section. This skips a heading level, which is an accessibility concern and can produce an unusual TOC structure (h3 entries floating at the top). A simple fix is wrapping both method sections under an## Endpoints(or## API Endpoints) h2.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/content/docs/es/storage-api/api-endpoint.mdx` at line 24, The page starts with h3 headings "### Method: PUT" and "### Method: POST" without an h2 parent; add an h2 like "## Endpoints" (or "## API Endpoints") above these sections and move/ensure both "### Method: PUT" and "### Method: POST" are nested under that h2 so heading hierarchy is correct and the TOC/accessibility is fixed.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@src/content/docs/es/storage-api/api-endpoint.mdx`:
- Around line 2-4: The frontmatter currently sets i18nReady: true while the
document body is still English; change the frontmatter key i18nReady from true
to false (i18nReady: false) for this page (the block containing title: API
Endpoint and description) so the page is not marked as translated until the
Spanish content is completed.
- Around line 28-37: The HTTP example block contains an invalid "Headers:" label
and an indented header line; update the PUT example in the code block (Storage
API - PUT /studiocms_api/storage/manager) to use proper HTTP wire format by
removing the "Headers:" prefix and placing the header as a top-level header line
(e.g., "x-storage-key: my-file.txt") alongside other headers like Host,
Content-Type, and Accept so each header is "Key: Value" on its own line.
In `@src/content/docs/es/storage-api/index.mdx`:
- Around line 2-4: The frontmatter flag i18nReady is set to true but the page
body (title/description and prose) is still in English; change the frontmatter
key i18nReady from true to false until the Spanish translation is completed and
verified (update i18nReady back to true once you add the translated content for
title/description and all prose).
In `@src/content/docs/es/storage-api/javascript-helpers.mdx`:
- Around line 2-5: The frontmatter flag i18nReady is set to true while the page
content (title, description, body) is still in English; update the frontmatter
key i18nReady to false until the Spanish translation is complete or replace the
English text with the translated Spanish content and then set i18nReady:
true—look for the i18nReady field in the document's frontmatter (the top
metadata block containing title/description) and change its boolean
appropriately.
---
Nitpick comments:
In `@src/content/docs/es/storage-api/api-endpoint.mdx`:
- Line 24: The page starts with h3 headings "### Method: PUT" and "### Method:
POST" without an h2 parent; add an h2 like "## Endpoints" (or "## API
Endpoints") above these sections and move/ensure both "### Method: PUT" and "###
Method: POST" are nested under that h2 so heading hierarchy is correct and the
TOC/accessibility is fixed.
| i18nReady: true | ||
| title: API Endpoint | ||
| description: Learn about the API endpoints available in the StudioCMS Storage API. |
There was a problem hiding this comment.
Content is not translated — i18nReady: true is premature.
Same as the other ES files: all prose remains in English. Set i18nReady: false until the page body is actually translated into Spanish.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@src/content/docs/es/storage-api/api-endpoint.mdx` around lines 2 - 4, The
frontmatter currently sets i18nReady: true while the document body is still
English; change the frontmatter key i18nReady from true to false (i18nReady:
false) for this page (the block containing title: API Endpoint and description)
so the page is not marked as translated until the Spanish content is completed.
| ```http title="Storage API - PUT /studiocms_api/storage/manager" | ||
| PUT /studiocms_api/storage/manager HTTP/1.1 | ||
| Host: example.com | ||
| Content-Type: application/octet-stream | ||
| Accept: application/json | ||
| Headers: | ||
| x-storage-key: my-file.txt | ||
|
|
||
| <file-content> | ||
| ``` |
There was a problem hiding this comment.
Invalid HTTP syntax in the PUT request example.
The Headers: label with an indented x-storage-key on the next line is not valid HTTP wire format. Headers in an HTTP request are written as flat Key: Value lines, not under a Headers: section prefix. As written, this may confuse readers and is technically incorrect documentation.
🐛 Proposed fix
PUT /studiocms_api/storage/manager HTTP/1.1
Host: example.com
Content-Type: application/octet-stream
Accept: application/json
-Headers:
- x-storage-key: my-file.txt
+x-storage-key: my-file.txt
<file-content>📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| ```http title="Storage API - PUT /studiocms_api/storage/manager" | |
| PUT /studiocms_api/storage/manager HTTP/1.1 | |
| Host: example.com | |
| Content-Type: application/octet-stream | |
| Accept: application/json | |
| Headers: | |
| x-storage-key: my-file.txt | |
| <file-content> | |
| ``` | |
| PUT /studiocms_api/storage/manager HTTP/1.1 | |
| Host: example.com | |
| Content-Type: application/octet-stream | |
| Accept: application/json | |
| x-storage-key: my-file.txt | |
| <file-content> |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@src/content/docs/es/storage-api/api-endpoint.mdx` around lines 28 - 37, The
HTTP example block contains an invalid "Headers:" label and an indented header
line; update the PUT example in the code block (Storage API - PUT
/studiocms_api/storage/manager) to use proper HTTP wire format by removing the
"Headers:" prefix and placing the header as a top-level header line (e.g.,
"x-storage-key: my-file.txt") alongside other headers like Host, Content-Type,
and Accept so each header is "Key: Value" on its own line.
| i18nReady: true | ||
| title: Overview | ||
| description: Learn about the Storage API in StudioCMS |
There was a problem hiding this comment.
Content is not translated — i18nReady: true is premature.
All prose remains in English. Set i18nReady: false until the Spanish translation is complete.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@src/content/docs/es/storage-api/index.mdx` around lines 2 - 4, The
frontmatter flag i18nReady is set to true but the page body (title/description
and prose) is still in English; change the frontmatter key i18nReady from true
to false until the Spanish translation is completed and verified (update
i18nReady back to true once you add the translated content for title/description
and all prose).
| i18nReady: true | ||
| title: JavaScript Helpers | ||
| description: Learn about the JavaScript helpers available in the StudioCMS Storage API. | ||
| tableOfContents: |
There was a problem hiding this comment.
Content is not translated — i18nReady: true is premature.
All prose text (title, description, and the full page body) is in English. In Starlight-based docs, i18nReady: true on a translated page signals the translation is complete and in sync with the English source. Marking this as ready while the content is still entirely in English will suppress any "needs translation" UI indicator and mislead users expecting Spanish content.
Either translate the content before setting i18nReady: true, or set it to false until translation is complete.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@src/content/docs/es/storage-api/javascript-helpers.mdx` around lines 2 - 5,
The frontmatter flag i18nReady is set to true while the page content (title,
description, body) is still in English; update the frontmatter key i18nReady to
false until the Spanish translation is complete or replace the English text with
the translated Spanish content and then set i18nReady: true—look for the
i18nReady field in the document's frontmatter (the top metadata block containing
title/description) and change its boolean appropriately.
New files:
Description
Summary by CodeRabbit