From 89eec9fde65ae348e6a9c3cb6416c7846b2dc19b Mon Sep 17 00:00:00 2001 From: George J Padayatti Date: Mon, 25 Sep 2023 14:26:13 +0530 Subject: [PATCH] Upd: change rapidocs configuration Signed-off-by: George J Padayatti --- openapi/v2023.8.1/index.html | 91 ++++++++++++++++++---------------- openapi/v2023.8.2/bundled.yaml | 2 +- openapi/v2023.8.2/index.html | 89 +++++++++++++++++---------------- openapi/v2023.8.2/index.yaml | 5 +- 4 files changed, 99 insertions(+), 88 deletions(-) diff --git a/openapi/v2023.8.1/index.html b/openapi/v2023.8.1/index.html index 3bcfd63..13a0dc6 100644 --- a/openapi/v2023.8.1/index.html +++ b/openapi/v2023.8.1/index.html @@ -3,8 +3,8 @@ - - GovStack Consent BB APIs + + GovStack Consent Building Block APIs { const rapiDocElement = document.querySelector("rapi-doc"); - if (window.innerWidth <= 768) { - // Assuming 768px as the breakpoint for tablet size - rapiDocElement.setAttribute("render-style", "read"); // for sizes less than a tablet - - // Function to apply the style when the element is available - const applyStyleToApiInfo = () => { - const mainContentElement = - rapiDocElement.shadowRoot.querySelector(".main-content"); - const apiInfoElement = - rapiDocElement.shadowRoot.querySelector("#api-info"); - const labelOperationPathElements = - rapiDocElement.shadowRoot.querySelectorAll( - "[part*='section-operation-webhook-method']" - ); - - if ( - apiInfoElement && - labelOperationPathElements && - mainContentElement - ) { - mainContentElement.style.padding = "10px"; - apiInfoElement.style.marginLeft = "0"; - labelOperationPathElements.forEach(function (element) { - element.style.overflowX = "scroll"; - }); - observer.disconnect(); // Stop observing once style is applied - } - }; + // Function to apply the style when the element is available + const applyStyleToApiInfo = () => { + const header = + rapiDocElement.shadowRoot.querySelector(".main-header"); + const mainContentElement = + rapiDocElement.shadowRoot.querySelector(".main-content"); + const apiInfoElement = + rapiDocElement.shadowRoot.querySelector("#api-info"); + const labelOperationPathElements = + rapiDocElement.shadowRoot.querySelectorAll( + "[part*='section-operation-webhook-method']" + ); - // Observe changes in the Shadow DOM - const observer = new MutationObserver(applyStyleToApiInfo); - if (rapiDocElement.shadowRoot) { - observer.observe(rapiDocElement.shadowRoot, { - childList: true, - subtree: true, + if ( + apiInfoElement && + labelOperationPathElements && + mainContentElement && + header + ) { + mainContentElement.style.padding = "10px"; + apiInfoElement.style.marginLeft = "0"; + header.style.padding = "8px 4px 8px 16px"; + labelOperationPathElements.forEach(function (element) { + element.style.overflowX = "scroll"; }); - applyStyleToApiInfo(); // Try applying the style immediately in case the element is already there + observer.disconnect(); // Stop observing once style is applied } + }; + + // Observe changes in the Shadow DOM + const observer = new MutationObserver(applyStyleToApiInfo); + if (rapiDocElement.shadowRoot) { + observer.observe(rapiDocElement.shadowRoot, { + childList: true, + subtree: true, + }); + applyStyleToApiInfo(); // Try applying the style immediately in case the element is already there + } + if (window.innerWidth <= 768) { + // Assuming 768px as the breakpoint for tablet size + rapiDocElement.setAttribute("render-style", "view"); // for sizes less than a tablet } else { - rapiDocElement.setAttribute("render-style", "focused"); // for sizes greater than a tablet + rapiDocElement.setAttribute("render-style", "view"); // for sizes greater than a tablet } }); diff --git a/openapi/v2023.8.2/bundled.yaml b/openapi/v2023.8.2/bundled.yaml index 44cfb25..c78e2aa 100644 --- a/openapi/v2023.8.2/bundled.yaml +++ b/openapi/v2023.8.2/bundled.yaml @@ -1,7 +1,7 @@ openapi: 3.0.0 info: version: 2023.8.2 - title: GovStack Consent BB APIs + title: Consent Building Block APIs description: | The Consent Building Block enables services for individuals to approve the use of their personal data by defining the principles, functions, and architecture of an information system. For organisations that process personal data, it provides the ability to know the individual's will and legitimately process such personal data. The Consent Building Block is a process-oriented GovStack Building Block facilitating auditable bilateral agreements within a multi-agent environment that integrates with most other Building Blocks. contact: diff --git a/openapi/v2023.8.2/index.html b/openapi/v2023.8.2/index.html index 7b27c82..13a0dc6 100644 --- a/openapi/v2023.8.2/index.html +++ b/openapi/v2023.8.2/index.html @@ -3,8 +3,8 @@ - - GovStack Consent BB APIs + + GovStack Consent Building Block APIs { const rapiDocElement = document.querySelector("rapi-doc"); - if (window.innerWidth <= 768) { - // Assuming 768px as the breakpoint for tablet size - rapiDocElement.setAttribute("render-style", "read"); // for sizes less than a tablet - - // Function to apply the style when the element is available - const applyStyleToApiInfo = () => { - const mainContentElement = - rapiDocElement.shadowRoot.querySelector(".main-content"); - const apiInfoElement = - rapiDocElement.shadowRoot.querySelector("#api-info"); - const labelOperationPathElements = - rapiDocElement.shadowRoot.querySelectorAll( - "[part*='section-operation-webhook-method']" - ); - - if ( - apiInfoElement && - labelOperationPathElements && - mainContentElement - ) { - mainContentElement.style.padding = "10px"; - apiInfoElement.style.marginLeft = "0"; - labelOperationPathElements.forEach(function (element) { - element.style.overflowX = "scroll"; - }); - observer.disconnect(); // Stop observing once style is applied - } - }; + // Function to apply the style when the element is available + const applyStyleToApiInfo = () => { + const header = + rapiDocElement.shadowRoot.querySelector(".main-header"); + const mainContentElement = + rapiDocElement.shadowRoot.querySelector(".main-content"); + const apiInfoElement = + rapiDocElement.shadowRoot.querySelector("#api-info"); + const labelOperationPathElements = + rapiDocElement.shadowRoot.querySelectorAll( + "[part*='section-operation-webhook-method']" + ); - // Observe changes in the Shadow DOM - const observer = new MutationObserver(applyStyleToApiInfo); - if (rapiDocElement.shadowRoot) { - observer.observe(rapiDocElement.shadowRoot, { - childList: true, - subtree: true, + if ( + apiInfoElement && + labelOperationPathElements && + mainContentElement && + header + ) { + mainContentElement.style.padding = "10px"; + apiInfoElement.style.marginLeft = "0"; + header.style.padding = "8px 4px 8px 16px"; + labelOperationPathElements.forEach(function (element) { + element.style.overflowX = "scroll"; }); - applyStyleToApiInfo(); // Try applying the style immediately in case the element is already there + observer.disconnect(); // Stop observing once style is applied } + }; + + // Observe changes in the Shadow DOM + const observer = new MutationObserver(applyStyleToApiInfo); + if (rapiDocElement.shadowRoot) { + observer.observe(rapiDocElement.shadowRoot, { + childList: true, + subtree: true, + }); + applyStyleToApiInfo(); // Try applying the style immediately in case the element is already there + } + if (window.innerWidth <= 768) { + // Assuming 768px as the breakpoint for tablet size + rapiDocElement.setAttribute("render-style", "view"); // for sizes less than a tablet } else { - rapiDocElement.setAttribute("render-style", "focused"); // for sizes greater than a tablet + rapiDocElement.setAttribute("render-style", "view"); // for sizes greater than a tablet } }); diff --git a/openapi/v2023.8.2/index.yaml b/openapi/v2023.8.2/index.yaml index e2afe6a..be328c8 100644 --- a/openapi/v2023.8.2/index.yaml +++ b/openapi/v2023.8.2/index.yaml @@ -1,7 +1,7 @@ openapi: "3.0.0" info: version: "2023.8.2" - title: "GovStack Consent BB APIs" + title: "Consent Building Block APIs" description: > The Consent Building Block enables services for individuals to approve the use of their personal data by defining the principles, functions, and architecture @@ -208,8 +208,7 @@ paths: $ref: "./paths/config/getRecentWebhookDeliveryByID.yaml" /v2/config/webhooks/{webhookId}/delivery/{deliveryId}/redeliver: $ref: "./paths/config/redeliverWebhook.yaml" - - + components: schemas: Log: