mirror of
https://github.com/twbs/bootstrap.git
synced 2024-11-28 10:24:19 +01:00
This commit is contained in:
parent
0816e952ea
commit
6d19cad5db
@ -17,7 +17,6 @@ export default () => {
|
||||
// Insert copy to clipboard button before .highlight
|
||||
const btnTitle = 'Copy to clipboard'
|
||||
const btnEdit = 'Edit on StackBlitz'
|
||||
// const btnTheme = 'Toggle local theme'
|
||||
|
||||
const btnHtml = [
|
||||
'<div class="bd-code-snippet">',
|
||||
@ -52,7 +51,6 @@ export default () => {
|
||||
|
||||
snippetButtonTooltip('.btn-clipboard', btnTitle)
|
||||
snippetButtonTooltip('.btn-edit', btnEdit)
|
||||
// snippetButtonTooltip('.btn-theme', btnTheme)
|
||||
|
||||
const clipboard = new ClipboardJS('.btn-clipboard', {
|
||||
target: trigger => trigger.closest('.bd-code-snippet').querySelector('.highlight'),
|
||||
|
@ -73,7 +73,7 @@
|
||||
const theme = toggle.getAttribute('data-bs-theme-value')
|
||||
|
||||
if (toggle.closest('.bd-code-snippet')) {
|
||||
setTheme(theme, toggle.closest('.bd-code-snippet').firstChild)
|
||||
setTheme(theme, toggle.closest('.bd-code-snippet').firstElementChild)
|
||||
showActiveTheme(theme, true, toggle.closest('.dropdown-menu').previousElementSibling)
|
||||
} else {
|
||||
setStoredTheme(theme)
|
||||
|
Loading…
Reference in New Issue
Block a user