From 39213ba1c6006a90915b526ff2ac5d29cdf8d351 Mon Sep 17 00:00:00 2001 From: Christian Wick Date: Mon, 28 Jun 2021 13:01:42 +0200 Subject: [PATCH] Reverting Introduction Sidebare to "hardcoded" for now. --- docs/.vuepress/config.js | 1 + docs/.vuepress/nav/left/guides.js | 61 +++--- .../theme/components/PageReference.vue | 8 +- .../theme/components/PageResource.vue | 205 ++++++++++-------- .../reference/rest/v1/merchant.balance/get.md | 43 +++- package.json | 5 +- yarn.lock | 18 ++ 7 files changed, 211 insertions(+), 130 deletions(-) diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index ebd4d6c..2a9d45a 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -202,6 +202,7 @@ module.exports = (ctx) => ({ '.vuepress/nav/top/mainNav.js', // Sidebars '.vuepress/nav/sidebars.js', + '.vuepress/nav/left/guides.js', '.vuepress/nav/left/rest/rest.js', '.vuepress/nav/left/rest/v1/summary.js', '.vuepress/nav/left/rest/v1/resources.js', diff --git a/docs/.vuepress/nav/left/guides.js b/docs/.vuepress/nav/left/guides.js index 6addfc8..74263da 100644 --- a/docs/.vuepress/nav/left/guides.js +++ b/docs/.vuepress/nav/left/guides.js @@ -1,39 +1,40 @@ -const introduction = require('./guides/introduction.js'); +// const introduction = require('./guides/introduction.js'); const quickstarts = require('./guides/quickstarts.js'); const tutorials = require('./guides/tutorials.js'); const best_practices = require('./guides/best-practices.js'); - const overview = { - title: 'Overview', - collapsable: false, - sidebarDepth: 0, - children: [ - ['/api/guides/', 'Settle API Overview'], - ], -} - -module.exports = [ - overview, - introduction, - quickstarts, - tutorials, - best_practices, -] + title: 'Overview', + collapsable: false, + sidebarDepth: 0, + children: [['/api/guides/', 'Settle API Overview']], +}; +/** + * @todo #96 @rexgnu Edit the Introductions Sidabar here. Documents are found in '/docs/api/guides/introduction'. + */ +const introduction = { + title: 'Introduction', // required + collapsable: false, + sidebarDepth: 0, + children: [ + '/api/guides/introduction/interacting', + '/api/guides/introduction/callbacks', + '/api/guides/introduction/error-responses', + '/api/guides/introduction/media-type', + '/api/guides/introduction/a-note-on-settle-api-users', + '/api/guides/introduction/versioning', + ['/api/guides/introduction/resiliency', 'Resiliency'], + ], +}; -// function getIntroductionSidebar() { -// return [ -// '/introduction/', -// '/introduction/interacting', -// '/introduction/callbacks', -// '/introduction/error-responses', -// '/introduction/media-type', -// '/introduction/a-note-on-settle-api-users', -// '/introduction/versioning', -// ['/introduction/resiliency', 'Resiliency'], -// ]; -// } +module.exports = [ + overview, + introduction, + // quickstarts, + tutorials, + // best_practices, +]; // function getGuidesSidebar() { // return [ @@ -46,4 +47,4 @@ module.exports = [ // '/guides/permission-requests', // '/guides/qr-acceptance', // ]; -// } \ No newline at end of file +// } diff --git a/docs/.vuepress/theme/components/PageReference.vue b/docs/.vuepress/theme/components/PageReference.vue index af5ac9c..5f10312 100644 --- a/docs/.vuepress/theme/components/PageReference.vue +++ b/docs/.vuepress/theme/components/PageReference.vue @@ -68,14 +68,10 @@ The above services has the following endpoints (resources), and all methods below are relative to its parent method (service endpoint).

-
+
-
+

-

- # Status Codes -

- -
-

- # Schema -

-
-
-

- # - {{ type.name }} +
+

+ # Status Codes

    -
  • - Type: - - - {{ type.$ref }} - - {{ type.type }} -
  • - -
  • - Required: - {{ type.required }} -
  • -
  • - Enum: {{ type.enum }} -
  • -
  • - Default: {{ type.default }} -
  • -
  • - Length: {{ type.minLength }} -
  • -
  • - Length: ≥ {{ type.minLength }} -
  • -
  • - Length: ≤ {{ type.maxLength }} -
  • -
  • - Value: ≥ {{ type.minimum }} -
  • -
  • - Value: ≤ {{ type.maximum }} -
  • -
  • - RegExp: {{ type.pattern }} +
  • + {{ code.code }} --> + {{ code.title }}, {{ code.description }}
-

{{ type.description }}

+
+

+ # Schema +

+
+
+

+ # + {{ type.name }} +

+
    +
  • + Type: + + + {{ type.$ref }} + + {{ type.type }} +
  • + +
  • + Required: + {{ type.required }} +
  • +
  • + Enum: {{ type.enum }} +
  • +
  • + Default: {{ type.default }} +
  • +
  • + Length: {{ type.minLength }} +
  • +
  • + Length: ≥ {{ type.minLength }} +
  • +
  • + Length: ≤ {{ type.maxLength }} +
  • +
  • + Value: ≥ {{ type.minimum }} +
  • +
  • + Value: ≤ {{ type.maximum }} +
  • +
  • + RegExp: {{ type.pattern }} +
  • +
+

{{ type.description }}

+
+
+
+
+ --> + +