docs: preview banner#2518
Open
vladfrangu wants to merge 3 commits into
Open
Conversation
|
✅ Preview for this PR (commit |
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a visible “preview build” banner for PR deployments of the Apify Docs and updates theme CSS so the banner stays pinned at the top without the navbar sliding underneath.
Changes:
- Adds a Docusaurus
announcementBarthat appears only on preview/PR hostnames and links back to the PR on GitHub. - Adjusts theme CSS to make the announcement bar sticky and offset the navbar when the bar is present.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| apify-docs-theme/src/theme/custom.css | Pins the announcement bar to the viewport top and offsets the navbar to avoid overlap. |
| apify-docs-theme/src/config.js | Conditionally enables a PR preview announcement bar based on APIFY_DOCS_ABSOLUTE_URL. |
Comment on lines
+290
to
+292
| const absoluteUrl = new URL(process.env.APIFY_DOCS_ABSOLUTE_URL); | ||
|
|
||
| const { hostname } = absoluteUrl; |
|
|
||
| return { | ||
| id: 'apify-docs-preview-banner', | ||
| content: `You are visiting <a href="${githubUrl}" target="_blank">a preview build for PR ${prNumber}</a> of the Apify Docs.`, |
patrikbraborec
approved these changes
May 12, 2026
Contributor
|
I guess it's OK, I also added @TC-MO to check it. |
B4nan
approved these changes
May 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It ugle but that's fine :D