summaryrefslogtreecommitdiffstats
path: root/site/assets
diff options
context:
space:
mode:
Diffstat (limited to 'site/assets')
-rw-r--r--site/assets/js/code-examples.js13
-rw-r--r--site/assets/scss/_component-examples.scss7
2 files changed, 11 insertions, 9 deletions
diff --git a/site/assets/js/code-examples.js b/site/assets/js/code-examples.js
index e1f680e..3b03b17 100644
--- a/site/assets/js/code-examples.js
+++ b/site/assets/js/code-examples.js
@@ -20,18 +20,19 @@
const btnHtml = [
'<div class="bd-code-snippet">',
- ' <div class="bd-clipboard">',
- ' <button type="button" class="btn-clipboard">',
- ' <svg class="bi" role="img" aria-label="Copy"><use xlink:href="#clipboard"/></svg>',
- ' </button>',
- ' </div>',
+ ' <div class="bd-clipboard">',
+ ' <button type="button" class="btn-clipboard">',
+ ' <svg class="bi" role="img" aria-label="Copy"><use xlink:href="#clipboard"/></svg>',
+ ' </button>',
+ ' </div>',
'</div>'
].join('')
// Wrap programmatically code blocks and add copy btn.
document.querySelectorAll('.highlight')
.forEach(element => {
- if (!element.closest('.bd-example-snippet')) { // Ignore examples made be shortcode
+ // Ignore examples made by shortcode
+ if (!element.closest('.bd-example-snippet')) {
element.insertAdjacentHTML('beforebegin', btnHtml)
element.previousElementSibling.append(element)
}
diff --git a/site/assets/scss/_component-examples.scss b/site/assets/scss/_component-examples.scss
index 0f1018b..1d8caed 100644
--- a/site/assets/scss/_component-examples.scss
+++ b/site/assets/scss/_component-examples.scss
@@ -220,15 +220,16 @@
// scss-docs-start custom-tooltip
.custom-tooltip {
- --bs-tooltip-bg: var(--bs-primary);
+ --bs-tooltip-bg: var(--bd-violet-bg);
+ --bs-tooltip-color: var(--bs-white);
}
// scss-docs-end custom-tooltip
// scss-docs-start custom-popovers
.custom-popover {
--bs-popover-max-width: 200px;
- --bs-popover-border-color: var(--bs-primary);
- --bs-popover-header-bg: var(--bs-primary);
+ --bs-popover-border-color: var(--bd-violet-bg);
+ --bs-popover-header-bg: var(--bd-violet-bg);
--bs-popover-header-color: var(--bs-white);
--bs-popover-body-padding-x: 1rem;
--bs-popover-body-padding-y: .5rem;