Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/BootstrapBlazor/Components/RibbonTab/RibbonTab.razor.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,13 @@ import EventHandler from "../../modules/event-handler.js"

export function init(id, invoke, callback) {
const el = document.getElementById(id)
const headerEl = el.querySelector('.ribbon-header')
const rt = {
element: el, invoke, callback,
element: el, headerEl, invoke, callback,
handlerClick: e => {
const isFloat = el.classList.contains('is-float')
const isFloat = headerEl.classList.contains('is-float')
if (isFloat) {
const expanded = el.classList.contains('is-expand')
const expanded = headerEl.classList.contains('is-expand')
if (expanded) {
const ribbonBody = e.target.closest('.ribbon-body');
if (ribbonBody) {
Expand Down