From b1fc371f71b9868c78aa522e3c0da1f0fb4aa1cc Mon Sep 17 00:00:00 2001 From: Blessing Ene Anyebe Date: Thu, 25 Jul 2024 11:36:10 +0100 Subject: [PATCH] Modified spec page --- components/DocTable.tsx | 22 ++------- components/Sidebar.tsx | 15 ++++--- pages/draft-05/index.md | 4 +- pages/draft-06/index.md | 4 +- pages/draft-07/index.md | 4 +- pages/draft/2019-09/index.md | 4 +- pages/draft/2020-12/index.md | 4 +- pages/format4/body.md | 2 - pages/format4/index.md | 6 --- pages/format4/index.page.tsx | 45 ------------------- .../{release-note => release-notes}/index.md | 0 .../index.page.tsx | 2 +- 12 files changed, 18 insertions(+), 94 deletions(-) delete mode 100644 pages/format4/body.md delete mode 100644 pages/format4/index.md delete mode 100644 pages/format4/index.page.tsx rename pages/{release-note => release-notes}/index.md (100%) rename pages/{release-note => release-notes}/index.page.tsx (94%) diff --git a/components/DocTable.tsx b/components/DocTable.tsx index 906475b11..770a660ca 100644 --- a/components/DocTable.tsx +++ b/components/DocTable.tsx @@ -8,7 +8,7 @@ const DocTable = ({ frontmatter }: any) => { - - - - - - - -
+ Specification @@ -23,7 +23,7 @@ const DocTable = ({ frontmatter }: any) => {
+ Published @@ -31,7 +31,7 @@ const DocTable = ({ frontmatter }: any) => {
+ Authors @@ -41,7 +41,7 @@ const DocTable = ({ frontmatter }: any) => {
+ Metaschema @@ -54,20 +54,6 @@ const DocTable = ({ frontmatter }: any) => {
- Implementations - - - {frontmatter.Implementations} - -
diff --git a/components/Sidebar.tsx b/components/Sidebar.tsx index 032eb08ba..36231f500 100644 --- a/components/Sidebar.tsx +++ b/components/Sidebar.tsx @@ -133,14 +133,15 @@ const getReferencePath = [ '/implementers/interfaces', ]; const getSpecificationPath = [ - '/draft/2020-12/release-notes', - '/draft/2019-09/release-notes', - '/draft-07/json-schema-release-notes', - '/draft-06/json-schema-release-notes', - '/draft-05/readme', - '/draft-07/json-hyper-schema-release-notes', - '/draft-06/json-hyper-schema-release-notes', + '/draft/2020-12/', + '/draft/2019-09/', + '/draft-07/', + '/draft-06/', + '/draft-05/', '/specification-links', + '/migration', + '/release-notes', + '/json-hyper-schema', '/specification', ]; diff --git a/pages/draft-05/index.md b/pages/draft-05/index.md index 0a13d69be..157693d0c 100644 --- a/pages/draft-05/index.md +++ b/pages/draft-05/index.md @@ -4,12 +4,10 @@ Published: '21-April-2017' type: docs authors: ['Austin Wright', 'Henry Andrews', 'Ben Hutton', 'Greg Dennis'] Metaschema: 'https://json-schema.org/draft/2020-12/schema' -Implementations: 'https://bowtie.report/#/dialects/draft2020-12' Specification: 'https://json-schema.org/draft/2020-12/json-schema-core.html' -Status: 'Stable' --- -### Access all data connected to draft 05 +### Draft-05 Documents - Core: [draft-wright-json-schema-00](https://json-schema.org/draft-05/draft-wright-json-schema-00.pdf) ([changes](https://json-schema.org/draft-05/draft-wright-json-schema-00.pdf#appendix-B)) - Validation: [draft-wright-json-schema-validation-00](https://json-schema.org/draft-05/draft-wright-json-schema-validation-00.pdf) ([changes](https://json-schema.org/draft-05/draft-wright-json-schema-validation-00.pdf#appendix-B)) diff --git a/pages/draft-06/index.md b/pages/draft-06/index.md index 14f41a494..195a29c77 100644 --- a/pages/draft-06/index.md +++ b/pages/draft-06/index.md @@ -5,11 +5,9 @@ type: docs authors: ['Austin Wright', 'Henry Andrews', 'Ben Hutton', 'Greg Dennis'] Metaschema: 'https://json-schema.org/draft/2020-12/schema' Specification: 'https://json-schema.org/draft/2020-12/json-schema-core.html' -Implementations: 'https://bowtie.report/#/dialects/draft2020-12' -Status: 'Stable' --- -### Access all data connected to draft-06 +### Draft-06 Documents - Validation: [draft-wright-json-schema-validation-01](https://json-scheclsma.org/draft-06/draft-wright-json-schema-validation-01.html) ([changes](https://json-schema.org/draft-06/draft-wright-json-schema-validation-01.html#rfc.appendix.B)) ([schema migration FAQ](https://json-schema.org/draft-06/json-schema-release-notes)) - Hyper-Schema: [draft-wright-json-schema-hyperschema-01](https://json-schema.org/draft-06/draft-wright-json-schema-hyperschema-01.html) ([changes](https://json-schema.org/draft-06/draft-wright-json-schema-hyperschema-01.html#rfc.appendix.B)) ([hyper-schema migration FAQ](https://json-schema.org/draft-06/json-hyper-schema-release-notes)) diff --git a/pages/draft-07/index.md b/pages/draft-07/index.md index a1c8a7fba..3638e39b0 100644 --- a/pages/draft-07/index.md +++ b/pages/draft-07/index.md @@ -5,15 +5,13 @@ type: docs authors: ['Austin Wright', 'Henry Andrews', 'Ben Hutton', 'Greg Dennis'] Metaschema: 'https://json-schema.org/draft/2020-12/schema' Specification: 'https://json-schema.org/draft/2020-12/json-schema-core.html' -Implementations: 'https://bowtie.report/#/dialects/draft2020-12' -Status: 'Stable' --- ### Introduction The JSON Schema Draft-07 introduces various updates to enhance the functionality of JSON Schemas in contrast to maintaining backward compatibility with Draft-06. -### Access all data connected to draft 07 +### Draft-07 Documents - Core: [draft-handrews-json-schema-01](https://json-schema.org/draft-07/draft-handrews-json-schema-01.html) ([changes](https://json-schema.org/draft-07/draft-handrews-json-schema-01.html#rfc.appendix.B)) - Validation: [draft-handrews-json-schema-validation-01](https://json-schema.org/draft-07/draft-handrews-json-schema-validation-01.html) ([changes](https://json-schema.org/draft-07/draft-handrews-json-schema-validation-01.html#rfc.appendix.B)) diff --git a/pages/draft/2019-09/index.md b/pages/draft/2019-09/index.md index 175b345dc..cd36d0576 100644 --- a/pages/draft/2019-09/index.md +++ b/pages/draft/2019-09/index.md @@ -9,8 +9,6 @@ authors: - Greg Dennis Published: 17-September-2019 Metaschema: https://json-schema.org/draft/2020-12/schema -Implementations: https://bowtie.report/#/dialects/draft2020-12 -Status: Stable --- ### Introduction @@ -19,7 +17,7 @@ The JSON Schema Draft 2019-09 introduces updates and changes to improve the reli One significant update is the shift to HTTPS for all meta-schema URIs. While the URIs remain accessible over HTTP due to certain limitations, the recommended standard is now firmly HTTPS. -### Access all data connected to draft 2019-09 +### Draft 2019-09 Documents **\*NOTE:** All meta-schema URIs now use `https://`. While currently also available over plain HTTP due to the limitations of GitHub pages and the need to keep prior drafts available over HTTP, only the HTTPS URIs should be used.\* diff --git a/pages/draft/2020-12/index.md b/pages/draft/2020-12/index.md index e802dbfa5..5be03ef7e 100644 --- a/pages/draft/2020-12/index.md +++ b/pages/draft/2020-12/index.md @@ -4,9 +4,7 @@ Published: '16 June 2022' type: docs authors: ['Austin Wright', 'Henry Andrews', 'Ben Hutton', 'Greg Dennis'] Metaschema: 'https://json-schema.org/draft/2020-12/schema' -Implementations: 'https://bowtie.report/#/dialects/draft2020-12' Specification: 'https://json-schema.org/draft/2020-12/json-schema-core.html' -Status: 'Stable' --- ### Introduction @@ -23,7 +21,7 @@ Here's an overview of updates to Draft 2020-12; - **Embedded Schemas and Bundling**: Provides guidance on bundling schemas into a Compound Schema Document. - **Vocabulary Changes**: Separates the `format` vocabulary into `format-annotation` and `format-assertion`. -### Access all data connected to Draft 2020-12 +### Draft 2020-12 Documents - Specifications - Core: [draft-bhutton-json-schema-01](https://json-schema.org/draft/2020-12/draft-bhutton-json-schema-01.html) ([changes](https://json-schema.org/draft/2020-12/draft-bhutton-json-schema-01.html#appendix-G)) diff --git a/pages/format4/body.md b/pages/format4/body.md deleted file mode 100644 index 1006bd1a4..000000000 --- a/pages/format4/body.md +++ /dev/null @@ -1,2 +0,0 @@ - -### Hello from body.md \ No newline at end of file diff --git a/pages/format4/index.md b/pages/format4/index.md deleted file mode 100644 index adc1a34ad..000000000 --- a/pages/format4/index.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -title: Title -type: Type ---- - -### Hello from index.md diff --git a/pages/format4/index.page.tsx b/pages/format4/index.page.tsx deleted file mode 100644 index fe800f5e1..000000000 --- a/pages/format4/index.page.tsx +++ /dev/null @@ -1,45 +0,0 @@ -import React from 'react'; -import { getLayout } from '~/components/SiteLayout'; -import fs from 'fs'; -import matter from 'gray-matter'; -import StyledMarkdown from '~/components/StyledMarkdown'; -import { SectionContext } from '~/context'; - -export async function getStaticProps() { - const index = fs.readFileSync('pages/format4/index.md', 'utf-8'); - const main = fs.readFileSync('pages/format4/body.md', 'utf-8'); - const { content: indexContent, data: indexData } = matter(index); - const { content: bodyContent } = matter(main); - - const frontmatter = { ...indexData }; - return { - props: { - blocks: { - index: indexContent, - body: bodyContent, - }, - frontmatter, - }, - }; -} - -export default function ImplementationsPages({ - blocks, - frontmatter, -}: { - blocks: any; - frontmatter: any; -}) { - return ( - -
-

{frontmatter.title}

-

{frontmatter.type}

- - - -
-
- ); -} -ImplementationsPages.getLayout = getLayout; diff --git a/pages/release-note/index.md b/pages/release-notes/index.md similarity index 100% rename from pages/release-note/index.md rename to pages/release-notes/index.md diff --git a/pages/release-note/index.page.tsx b/pages/release-notes/index.page.tsx similarity index 94% rename from pages/release-note/index.page.tsx rename to pages/release-notes/index.page.tsx index f745f9325..e8f70f9d3 100644 --- a/pages/release-note/index.page.tsx +++ b/pages/release-notes/index.page.tsx @@ -6,7 +6,7 @@ import StyledMarkdown from '~/components/StyledMarkdown'; import { SectionContext } from '~/context'; export async function getStaticProps() { - const index = fs.readFileSync('pages/release-note/index.md', 'utf-8'); + const index = fs.readFileSync('pages/release-notes/index.md', 'utf-8'); // const main = fs.readFileSync('pages/draft-05/release-notes.md', 'utf-8'); const { content: indexContent, data: indexData } = matter(index); // const { content: bodyContent } = matter(main);