From 30a5936a9c513a15a9bb6e70cdc63286ba9b7154 Mon Sep 17 00:00:00 2001 From: Yury Date: Fri, 5 Mar 2021 17:33:49 +0300 Subject: [PATCH 1/4] refactor: use variables for font-weights --- src/Styles.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Styles.js b/src/Styles.js index b68850e..23e2026 100644 --- a/src/Styles.js +++ b/src/Styles.js @@ -125,7 +125,7 @@ a:hover { cursor: pointer; margin-bottom: 4px; display: inline-block; - font-weight: 500; + font-weight: var(--api-summary-endpoint-path-font-weight, 500); color: var(--link-color, #0277BD); margin: 4px 0; word-break: break-all; @@ -142,7 +142,7 @@ a:hover { } .section.endpoints-title { - font-weight: 500; + font-weight: var(--arc-font-title-font-weight, 500); } .endpoint-path-name { From 62596c060a17a52f0b46c14db632b6dd0cd6d27f Mon Sep 17 00:00:00 2001 From: Yury Date: Fri, 5 Mar 2021 17:34:30 +0300 Subject: [PATCH 2/4] feat: use existing variables to style endpoints title --- src/Styles.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Styles.js b/src/Styles.js index 23e2026..b9dbfba 100644 --- a/src/Styles.js +++ b/src/Styles.js @@ -143,6 +143,10 @@ a:hover { .section.endpoints-title { font-weight: var(--arc-font-title-font-weight, 500); + color: var(--arc-font-title-color); + font-weight: var(--arc-font-title-font-weight); + line-height: var(--arc-font-title-line-height); + font-size: var(--arc-font-title-font-size); } .endpoint-path-name { From d5717fcded90931658501cef3cbb8e4657489f48 Mon Sep 17 00:00:00 2001 From: Yury Date: Fri, 5 Mar 2021 17:35:30 +0300 Subject: [PATCH 3/4] feat: add variable to adjust section heading color --- src/Styles.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Styles.js b/src/Styles.js index b9dbfba..eab0a8c 100644 --- a/src/Styles.js +++ b/src/Styles.js @@ -56,6 +56,7 @@ arc-marked { } label.section { + color: var(--arc-font-subhead-color); font-weight: var(--arc-font-subhead-font-weight); line-height: var(--arc-font-subhead-line-height); /* font-size: 18px; */ From aa0a944417f9318506914f23d0bb10c374a774f0 Mon Sep 17 00:00:00 2001 From: Yury Date: Fri, 5 Mar 2021 17:35:58 +0300 Subject: [PATCH 4/4] docs: adjust readme formatting --- README.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 1447652..d1ba1f9 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ [![Published on webcomponents.org](https://img.shields.io/badge/webcomponents.org-published-blue.svg)](https://www.webcomponents.org/element/@api-components/api-summary) -# api-summary +# <api-summary> A component that renders basic information about an API. It uses AMF model to render the view. @@ -17,7 +17,8 @@ For compatibility with previous model version use `3.x.x` version of the compone ## Usage ### Installation -``` + +```sh npm install --save @api-components/api-summary ``` @@ -86,7 +87,7 @@ class SampleElement extends PolymerElement { customElements.define('sample-element', SampleElement); ``` -### Installation +## Development ```sh git clone https://github.com/advanced-rest-client/api-summary