Skip to content

Commit

Permalink
Switch order of schemata and types in model explorer
Browse files Browse the repository at this point in the history
Visitors are more likely to look up schema docs than property type documentation.
  • Loading branch information
tillprochaska committed Nov 25, 2022
1 parent 1f5bcc7 commit 97d2304
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
20 changes: 10 additions & 10 deletions site/src/components/explorer/ExplorerNav.astro
Original file line number Diff line number Diff line change
Expand Up @@ -18,25 +18,25 @@ const basePath = Astro.site?.pathname || '';
---

<Nav slot="sidebar">
<NavSection title="Types">
<NavSection title="Schemata">
{
types.map((type) => (
schemata.map((schema) => (
<NavItem
link={path.join(basePath, '/explorer/types/', type.name)}
active={type.name === activeType?.name}
title={type.label}
link={path.join(basePath, '/explorer/schemata/', schema.name)}
active={schema.name === activeSchema?.name}
title={schema.label}
/>
))
}
</NavSection>

<NavSection title="Schemata">
<NavSection title="Types">
{
schemata.map((schema) => (
types.map((type) => (
<NavItem
link={path.join(basePath, '/explorer/schemata/', schema.name)}
active={schema.name === activeSchema?.name}
title={schema.label}
link={path.join(basePath, '/explorer/types/', type.name)}
active={type.name === activeType?.name}
title={type.label}
/>
))
}
Expand Down
8 changes: 4 additions & 4 deletions site/src/pages/explorer/index.astro
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ const model = new Model(defaultModel);
</header>

<div>
<h2 id="types" class="beta">Types</h2>
<PropertyTypesIndexTable />
<h2 id="schemata" class="beta">Schemata</h2>
<SchemataIndexTable />
</div>

<div>
<h2 id="schemata" class="beta">Schemata</h2>
<SchemataIndexTable />
<h2 id="types" class="beta">Types</h2>
<PropertyTypesIndexTable />
</div>
</Stack>
</DefaultLayout>

0 comments on commit 97d2304

Please sign in to comment.