Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(docs): use iframes instead of in-page examples #750

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

ppvg
Copy link
Member

@ppvg ppvg commented Jan 15, 2025

This PR refactors the way header and sidemenu examples are presented. Instead of "abusing" the docs page itself, the visual examples are now on separate pages and presented in the docs in iframes.

Not "abusing" the page itself removes the need for layout overrides, removing the need for the (docs) route group.

@ppvg ppvg requested a review from a team as a code owner January 15, 2025 09:40
Copy link
Contributor

@reinschaap reinschaap left a comment

Choose a reason for hiding this comment

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

Great work, see my suggestions to improve. Decline them if you want to, no problem...

docs/src/routes/components/header-navigation/+page.svelte Outdated Show resolved Hide resolved
Comment on lines +22 to +28
<li><a href="#example-navigation">Navigatie</a></li>
<li><a href="#example-with-content-wrapper">Navigatie met content wrapper</a></li>
<li><a href="#example-with-search">Navigatie met zoekveld</a></li>
<li><a href="#example-with-logo">Navigatie en logo</a></li>
<li><a href="#example-with-multiple-menus">Navigatie met meerdere menu's</a></li>
<li><a href="#example-with-form-button">Navigatie met formulier-knop</a></li>
<li><a href="#example-with-logo-above">Navigatie met logo bovenaan</a></li>
Copy link
Contributor

@reinschaap reinschaap Jan 15, 2025

Choose a reason for hiding this comment

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

Suggested change
<li><a href="#example-navigation">Navigatie</a></li>
<li><a href="#example-with-content-wrapper">Navigatie met content wrapper</a></li>
<li><a href="#example-with-search">Navigatie met zoekveld</a></li>
<li><a href="#example-with-logo">Navigatie en logo</a></li>
<li><a href="#example-with-multiple-menus">Navigatie met meerdere menu's</a></li>
<li><a href="#example-with-form-button">Navigatie met formulier-knop</a></li>
<li><a href="#example-with-logo-above">Navigatie met logo bovenaan</a></li>
<li><a href="#example-navigation">Navigatie</a></li>
<li><a href="#example-navigation-with-content-wrapper">Navigatie met content wrapper</a></li>
<li><a href="#example-navigation-with-search">Navigatie met zoekveld</a></li>
<li><a href="#example-navigation-with-logo">Navigatie en logo</a></li>
<li><a href="#example-navigation-with-multiple-menus">Navigatie met meerdere menu's</a></li>
<li><a href="#example-navigation-with-form-button">Navigatie met formulier-knop</a></li>
<li><a href="#example-navigation-with-logo-above">Navigatie met logo bovenaan</a></li>

Ik heb deze nog explicietere benaming ook doorgevoerd in de targets (zie verderop)

Copy link
Member Author

Choose a reason for hiding this comment

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

The URLs are /components/header-navigation#example-*, I intentionally left off the extra navigation, except for #example-navigation because I thought just #example would be too similar to #examples. But perhaps we can think of a better name than "Navigation" for the first example and solve two naming issues with one... ehm... stone?

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds like a plan

`}
/>

<h3 id="example-with-content-wrapper">Navigatie met content wrapper</h3>
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
<h3 id="example-with-content-wrapper">Navigatie met content wrapper</h3>
<h3 id="example-navigation-with-content-wrapper">Navigatie met content wrapper</h3>

`}
/>

<h3 id="example-with-search">Navigatie met zoekveld</h3>
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
<h3 id="example-with-search">Navigatie met zoekveld</h3>
<h3 id="example-navigation-with-search">Navigatie met zoekveld</h3>

`}
/>

<h3 id="example-with-logo">Navigatie en logo</h3>
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
<h3 id="example-with-logo">Navigatie en logo</h3>
<h3 id="example-navigation-with-logo">Navigatie en logo</h3>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants