Skip to content

Conversation

@samuelstroschein
Copy link
Member

@samuelstroschein samuelstroschein commented Jan 20, 2026

Implemented resolveRelativeUrl to handle markdown link resolution and added resolveHtmlAssetLinks to rewrite markdown page links. Updated loadMarketplacePage to utilize these functions and included comprehensive tests for both new functions in marketplaceData.test.ts.


Note

Enhances marketplace markdown rendering with robust link handling.

  • Introduces resolveRelativeUrl (supports optional .md appending for raw GitHub bases) and resolveHtmlAssetLinks to rewrite href/src in rendered HTML
  • Builds a page link map via buildMarketplacePageLinkMap to convert known markdown page links to internal marketplace routes (preserving query/hash)
  • Integrates link rewriting into loadMarketplacePage for regular, README, and mirror pages; updates resolveFrontmatterLinks to use new resolver
  • Adds comprehensive tests in marketplaceData.test.ts; minor formatting fix in og-image.test.ts

Written by Cursor Bugbot for commit b4fc681. This will update automatically on new commits. Configure here.

Implemented resolveRelativeUrl to handle markdown link resolution and added resolveHtmlAssetLinks to rewrite markdown page links. Updated loadMarketplacePage to utilize these functions and included comprehensive tests for both new functions in marketplaceData.test.ts.
@changeset-bot
Copy link

changeset-bot bot commented Jan 20, 2026

⚠️ No Changeset found

Latest commit: b4fc681

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f57902b051

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Updated resolveHtmlAssetLinks to include search and hash parameters in resolved links. Added extractSearchAndHash function to extract these components from URLs. Improved appendMarkdownExtensionIfNeeded to handle markdown extensions more effectively with a new getMarkdownExtension function.
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 20, 2026

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
inlang-website b4fc681 Commit Preview URL

Branch Preview URL
Jan 20 2026, 10:14 PM

cursor[bot]

This comment was marked as outdated.

…tension handling

Updated the resolveRelativeUrl function to include an options parameter for controlling the appending of markdown extensions. Adjusted related functions and tests to utilize this new feature, ensuring consistent link resolution behavior across the application.
cursor[bot]

This comment was marked as outdated.

…nsions

Updated the getMarkdownExtension function to first attempt URL parsing for baseUrl, ensuring it correctly identifies markdown extensions in the pathname. Added error handling to fallback on the original string check if URL parsing fails.
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

…on handling

Refactored the resolveRelativeUrl function to improve markdown extension appending logic based on URL type. Introduced helper functions to determine when to append extensions and to handle URL parsing more effectively. Added a new test case to validate behavior with base URLs containing query strings.
@samuelstroschein samuelstroschein merged commit d0b71b9 into main Jan 20, 2026
4 checks passed
@samuelstroschein samuelstroschein deleted the fix-rendering branch January 20, 2026 22:28
@github-actions github-actions bot locked and limited conversation to collaborators Jan 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants