Skip to content

New visual design including document outline navigation #531

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

Closed
wants to merge 26 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
eaeb322
Implemented basics of new design
wvteijlingen Mar 27, 2015
16112e8
Changed h3s to h2s on FAQ page
wvteijlingen Mar 27, 2015
e200686
Sidebar affix, CSS vendor prefixes
wvteijlingen Mar 29, 2015
b204b60
Moved Javascript to all.js
wvteijlingen Mar 30, 2015
8fca33a
Removed fixed width from quicklinks
wvteijlingen Mar 30, 2015
0dfe392
Renamed quicklinks, format, examples
wvteijlingen Mar 30, 2015
dcd1f51
Improved responsiveness
wvteijlingen Mar 30, 2015
5e20173
Removed old styling for code blocks
wvteijlingen Mar 30, 2015
2ea25ae
Added social links to footer
wvteijlingen Mar 30, 2015
66a372d
Changed typography to Helvetica Neue
wvteijlingen Mar 30, 2015
0bac6ab
Improved responsiveness of header
wvteijlingen Mar 30, 2015
a73fdb0
Fixed respsonsive bug with logo
wvteijlingen Mar 30, 2015
5326d61
Updated quicklinks margin
wvteijlingen Mar 30, 2015
e570ef2
Updated Sketch design
wvteijlingen Mar 30, 2015
2eb27ca
Merged from upstream gh-pages
wvteijlingen Mar 30, 2015
53a4731
Removed separate header and footer includes.
wvteijlingen Mar 30, 2015
c83c39e
Removed old logo images.
wvteijlingen Mar 30, 2015
974a950
Renamed page 'format' to 'specification'.
wvteijlingen Mar 30, 2015
459688a
Optimized logo SVG.
wvteijlingen Mar 30, 2015
e539b32
Updated SVG logo to use paths instead of text.
wvteijlingen Mar 30, 2015
ae8da53
Added logo to navigation bar.
wvteijlingen Mar 30, 2015
39c13f7
Design update.
wvteijlingen Mar 30, 2015
a04d120
Removed code collapsing from Javascript.
wvteijlingen Mar 30, 2015
ee9fa8d
Added a check to prevent creation of document outline when no sidebar…
wvteijlingen Mar 30, 2015
8d29230
Removed trailing dot from index page title.
wvteijlingen Mar 30, 2015
3f368b4
Made header logo src absolute.
wvteijlingen Mar 30, 2015
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ gem "rake", "~> 10.0"
gem "jekyll", "~> 1.0"
gem "redcarpet", "~> 2.2"
gem "rb-fsevent", "~> 0.9"
gem "compass", "~> 0.12"
gem "sass", "~> 3.2"
gem "compass", "~> 1.0"
gem "sass", "~> 3.4"
gem "launchy", "~> 2.3"
gem "redcard", "~> 1.0"
10 changes: 8 additions & 2 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ pygments: false
port: 9876

navigation:
- title: Format
url: /format/
- title: Specification
url: /specification/
- title: Extensions
url: /extensions/
- title: Recommendations
Expand All @@ -29,3 +29,9 @@ navigation:
url: /faq/
- title: About
url: /about/

quicklinks:
- title: View the specification
url: /specification/
- title: Contribute on Github
url: https://github.com/json-api/json-api
33 changes: 0 additions & 33 deletions _includes/footer.html

This file was deleted.

20 changes: 0 additions & 20 deletions _includes/header.html

This file was deleted.

77 changes: 58 additions & 19 deletions _layouts/page.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,38 +2,77 @@
<html>
<head>
<meta charset="utf-8">

<!-- Always force latest IE rendering engine or request Chrome Frame -->
<meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
<meta name="viewport" content="width=device-width, initial-scale=1">

<!-- Use title if it's in the page YAML frontmatter -->
<title>JSON API :: {{ page..title }}</title>
<title>JSON:API - {{ page.title }}</title>

<link href='http://fonts.googleapis.com/css?family=Titillium+Web:400,600,700,900' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Titillium+Web:400,300,600' rel='stylesheet' type='text/css'>
<link href="/stylesheets/normalize.css" media="screen" rel="stylesheet" type="text/css" />
<link href="/stylesheets/highlight.css" media="screen" rel="stylesheet" type="text/css" />
<link href="/stylesheets/all.css" media="screen" rel="stylesheet" type="text/css" />
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
<script src="/javascripts/all.js" type="text/javascript"></script>
<script src="/javascripts/highlight.pack.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
</head>

<body>
{% include header.html %}
<article>

<section>
{% if page.show_masthead %}
<div class="masthead">
<img src="/images/jsonapi@1.3x.png">
<h1>{{ page.title }}</h1>
<nav class="site-nav">
<ul>
{% assign url = page.url|remove:'index.html' %}
<li class="logo{% if url == '/' %} active{% endif %}"><a href="/" title="JSON:API"><img src="/images/logo-header.svg"></a></li>
{% for link in site.navigation %}
<li {% if url == link.url %}class="active"{% endif %}><a href="{{link.url}}" title="{{link.title}}">{{link.title}}</a></li>
{% endfor %}
</ul>
</nav>
{% if page.show_masthead %}
<header>
<div class="content">
<h1>JSON:API</h1>
<div class="quicklinks">
{% for link in site.quicklinks %}
<a href="{{link.url}}" title="{{link.title}}">{{link.title}}</a>
{% endfor %}
</div>
</div>
</header>
{% endif %}
<div class="site-wrapper">
{% if page.show_sidebar %}
<div class="sidebar">
<nav class="document-outline" id="document-outline">
<h2>{{ page.title }}</h2>
</nav>
</div>
{% else %}
<h1>{{ page.title }}</h1>
{% endif %}
{{ content }}
</section>
</article>
{% include footer.html %}
{% endif %}
<div class="content">
<section>
{{ content }}
</section>
</div>
</div>
<footer>
<span>Built with <a href="http://jekyllrb.com/">Jekyll</a> and <a href="http://softwaremaniacs.org/soft/highlight/en/">Highlight.js</a></span>
<span>Hosted by <a href="http://pages.github.com/">GitHub Pages</a></span>
<span>Generated at {{ site.time | date_to_xmlschema }}</span>
<span class="social-links">
<a class="twitter" href="http://twitter.com/jsonapi"><i class="icon-twitter"></i><span>Twitter</span></a>
<a class="github" href="https://github.com/json-api"><i class="icon-github"></i><span>GitHub</span></a>
<a class="googleplus" href="https://groups.google.com/forum/?fromgroups#!forum/jsonapi"><i class="icon-gplus"></i><span>Google</span></a>
</span>
</footer>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');

ga('create', 'UA-40609539-1', 'jsonapi.org');
ga('send', 'pageview');

</script>
</body>
</html>
Binary file added design/jsonapi.sketch
Binary file not shown.
Binary file removed design/jsonapi.sketch/Data
Binary file not shown.
20 changes: 0 additions & 20 deletions design/jsonapi.sketch/metadata

This file was deleted.

1 change: 0 additions & 1 deletion design/jsonapi.sketch/version

This file was deleted.

4 changes: 2 additions & 2 deletions extensions/bulk/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ It provides support for performing multiple operations in a request,
including adding and removing multiple resources.

Servers and clients **MUST** negotiate support for and use of the Bulk extension
[as described in the base specification](/format/#extending) using `bulk` as the
[as described in the base specification](/specification/#extending) using `bulk` as the
name of the extension.

## Bulk Operations <a href="#bulk-operations" id="bulk-operations" class="headerlink"></a>

[As mentioned in the base specification](/format/#crud), a request **MUST**
[As mentioned in the base specification](/specification/#crud), a request **MUST**
completely succeed or fail (in a single "transaction").

Therefore, any request that involves multiple operations **MUST** only
Expand Down
4 changes: 2 additions & 2 deletions extensions/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ JSON API can be extended in several ways:

* The `supported-ext` and `ext` media type parameters can be used to negotiate
support for extensions,
[as discussed in the base specification](/format#extending).
[as discussed in the base specification](/specification#extending).
Official and custom extensions to the specification are discussed below.

* Meta information can be included in several places in a document,
[as discussed in the base specification](/format/#document-structure-meta).
[as discussed in the base specification](/specification/#document-structure-meta).

* A profile can be specified in the top-level `meta` object, as discussed below.

Expand Down
2 changes: 1 addition & 1 deletion extensions/jsonpatch/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ For the sake of brevity, operatons requested with `PATCH` and conforming
with JSON Patch will be called "Patch operations".

Servers and clients **MUST** negotiate support for and use of the JSON Patch
extension [as described in the base specification](/format/#extending) using
extension [as described in the base specification](/specification/#extending) using
`jsonpatch` as the name of the extension.

## Patch Operations <a href="#patch-operations" id="patch-operations" class="headerlink"></a>
Expand Down
14 changes: 7 additions & 7 deletions faq/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ layout: page
title: Frequently Asked Questions
---

### Why is JSON API not versioned? <a href="#why-is-json-api-not-versioned" id="why-is-json-api-not-versioned" class="headerlink"></a>
## Why is JSON API not versioned? <a href="#why-is-json-api-not-versioned" id="why-is-json-api-not-versioned" class="headerlink"></a>

Once JSON API is stable, it will always be backwards compatible using a _never
remove, only add_ strategy.
[#46](https://github.com/json-api/json-api/issues/46)

### Why not use the HAL specification? <a href="#why-not-use-the-hal-specification" id="why-not-use-the-hal-specification" class="headerlink"></a>
## Why not use the HAL specification? <a href="#why-not-use-the-hal-specification" id="why-not-use-the-hal-specification" class="headerlink"></a>

There are several reasons:

Expand Down Expand Up @@ -37,7 +37,7 @@ It is extracted from a real-world library already used by a number of projects,
which has informed both the request/response aspects (absent from HAL) and the
interchange format itself.

### How to discover resource possible actions? <a href="#how-to-discover-resource-possible-actions" id="how-to-discover-resource-possible-actions" class="headerlink"></a>
## How to discover resource possible actions? <a href="#how-to-discover-resource-possible-actions" id="how-to-discover-resource-possible-actions" class="headerlink"></a>

You should use the OPTIONS HTTP method to discover what can be done with a
particular resource. The semantics of the methods returned by OPTIONS is defined
Expand All @@ -52,19 +52,19 @@ and capabilities and use the errors response to let users know. This error featu
is still pending to be included in the standard since is still in
[discussion](https://github.com/json-api/json-api/issues/7).

### Where's PUT? Can I use method *X* to do *Y*? <a href="#wheres-put" id="wheres-put" class="headerlink"></a>
## Where's PUT? Can I use method *X* to do *Y*? <a href="#wheres-put" id="wheres-put" class="headerlink"></a>

JSON API does not currently specify the use of the `PUT` method for any purpose.

Servers may complement the base specification by providing extra capabilities and
alternative ways of requesting certain operations (e.g., resource creation via
`PUT` in addition to `POST`).

### Is there a JSON Schema describing JSON API? <a href="#is-there-a-json-schema-describing-json-api" id="is-there-a-json-schema-describing-json-api" class="headerlink"></a>
## Is there a JSON Schema describing JSON API? <a href="#is-there-a-json-schema-describing-json-api" id="is-there-a-json-schema-describing-json-api" class="headerlink"></a>

Not currently, no. JSON Schema cannot fully represent the semantics of JSON API, and so any such schema would be partial anyway.

### Why are resource collections returned as arrays instead of sets keyed by ID?
## Why are resource collections returned as arrays instead of sets keyed by ID?

A JSON array is naturally ordered while sets require metadata to specify order
among members. Therefore, arrays allow for more natural sorting by default or
Expand All @@ -73,7 +73,7 @@ specified criteria.
In addition, JSON API allows read-only resources to be returned without IDs,
which would of course be incompatible with a set keyed by IDs.

### Why are related resources nested in an `included` object in a compound document?
## Why are related resources nested in an `included` object in a compound document?

Primary resources should be isolated because their order and number is often
significant. It's necessary to separate primary and related resources by more
Expand Down
Binary file removed images/jsonapi@0.7x.png
Binary file not shown.
Binary file removed images/jsonapi@1.3x.png
Binary file not shown.
Loading
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