Skip to content

Commit

Permalink
Sort schema tables by name
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyMcCormick committed Sep 30, 2024
1 parent 9bc63c8 commit 0f39170
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions browser/_layouts/schema.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
{% include _header.html %}
</head>
<body>
{%- assign sorted_tables = site.data[page.schema].tables | sort: 'name' %}
<div id="container">
<nav id="sidebar">
{% include _logo.html %}
Expand All @@ -15,7 +16,7 @@
<ul>
<li><a href="">{{ page.title }}</a></li>
<ul>
{%- for table in site.data[page.schema].tables %}
{%- for table in sorted_tables %}
<li><a href="{{ table['@id'] }}">{{ table.name }}</a></li>
{%- endfor %}
</ul>
Expand All @@ -29,7 +30,7 @@
<main class="main-content">
<h1>{{ page.title }}</h1>
{{ content }}
{%- for table in site.data[page.schema].tables %}
{%- for table in sorted_tables %}
<section id="{{ table['@id'] | remove:'#' }}">
<h2>{{ table.name }}</h2>
<p>{{ table.description }}</p>
Expand Down

0 comments on commit 0f39170

Please sign in to comment.