Skip to content

Commit 2aef191

Browse files
authored
Add Specification Numbering (json-api#1580)
Address oversight of specification numbering scope issue in json-api#1574. From the original PR: Citing the specification can be cumbersome. Following RFC numbering formats, the specification is numbered following ISO 2145 at each HEADER element, e.g., `h1`, `h2`, &tc. The numbers are CSS "generated" content and provide support for the additive focus of the specification. The paragraph glyph is repositioned absolutely, relative to the header. The `_config.yml` is updated to support building. bundle otherwise failed on Ruby 2.7.x. Updated the exclusions file for IntelliJ. Regarding the `_config.yml` change, I followed the README instructions and found that the site would not build with Ruby 2.3 installed on the Mac. I upgraded to Ruby 2.7 via homebrew—required as the Jekyll markdown gem would not compile—and encountered the same problem. Some research, i.e., SO-fu, found numerous posts regarding the vendor gem path with regards to Jekyll test files. Adding this line corrected the problem. The move to Ruby 2.7 appears to have generated updates to the map file.
1 parent 759c1a4 commit 2aef191

File tree

6 files changed

+88
-30
lines changed

6 files changed

+88
-30
lines changed

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,13 @@ Gemfile.lock
1212
# Ignore the build directory
1313
/public
1414

15+
# Ignore IntelliJ's config
16+
*.iml
17+
/.idea
18+
19+
# Ignore Ruby vendor
20+
/vendor
21+
1522
# Ignore Sass' cache
1623
/.sass-cache
1724

_config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ exclude:
4444
- .gitignore
4545
- ./public
4646
- ./stylesheets/*.scss
47+
- vendor
4748

4849
port: 9876
4950

_layouts/page.html

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -4,34 +4,35 @@
44
{% include global_head_assets.html %}
55

66
{% comment %}
7-
Below, we're either dealing with a generic page or a page from the
8-
specification collection. For generic pages, we get a title just by
9-
reading page.title but, for specification pages, we build their title
10-
dynamically to take into account the page's version number and its
11-
relationship to the latest version.
7+
Below, we're either dealing with a generic page or a page from the
8+
specification collection. For generic pages, we get a title just by
9+
reading page.title but, for specification pages, we build their title
10+
dynamically to take into account the page's version number and its
11+
relationship to the latest version.
1212
{% endcomment %}
1313

1414
{% if page.is_spec_page %}
15-
{% capture page_title %}
16-
{% include title_for_version.md is_latest_version=page.is_latest_version version=page.version %}
17-
{% endcapture %}
15+
{% assign class_spec='class="spec_page"' %}
16+
{% capture page_title %}
17+
{% include title_for_version.md is_latest_version=page.is_latest_version version=page.version %}
18+
{% endcapture %}
1819
{% else %}
19-
{% assign page_title = page.title %}
20+
{% assign page_title = page.title %}
2021
{% endif %}
2122
<title>JSON:API &mdash; {{ page_title|strip }}</title>
2223
</head>
2324

24-
<body>
25-
{% include site_navigation.html %}
26-
{% if page.show_masthead %}
27-
<header>
28-
<div class="content">
29-
<h1 id="json-api">JSON:API</h1>
30-
<h2>A specification for building APIs in JSON</h2>
31-
<div class="quicklinks">
32-
{% for link in site.quicklinks %}
33-
<a href="{{link.url}}" title="{{link.title}}">{{link.title}}</a>
34-
{% endfor %}
25+
<body {{ class_spec }}>
26+
{% include site_navigation.html %}
27+
{% if page.show_masthead %}
28+
<header>
29+
<div class="content">
30+
<h1 id="json-api">JSON:API</h1>
31+
<h2>A specification for building APIs in JSON</h2>
32+
<div class="quicklinks">
33+
{% for link in site.quicklinks %}
34+
<a href="{{link.url}}" title="{{link.title}}">{{link.title}}</a>
35+
{% endfor %}
3536
</div>
3637
{% if site.announcement %}
3738
<div class="announcement">

stylesheets/all.css

Lines changed: 24 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

stylesheets/all.css.map

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy