@@ -260,7 +259,7 @@
const tooltip = action.tooltip
if (tooltip) {
- tippy(el, {
+ const tippyInstance = tippy(el, {
content: `
${tooltip.title || ''}
@@ -277,6 +276,21 @@
maxWidth: 'none',
appendTo: document.getElementById('flow-diagram'),
offset: [0, 10],
+ onShow() {
+ const stepEl = el.closest('.action')
+ stepEl.classList.add('tooltip-open')
+ },
+ onHide() {
+ const stepEl = el.closest('.action')
+ stepEl.classList.remove('tooltip-open')
+ }
+ })
+
+ el.addEventListener('touchend', e => {
+ e.preventDefault()
+ e.stopPropagation()
+ tippy.hideAll()
+ tippyInstance.show()
})
}
}
@@ -329,10 +343,10 @@
a.action {
color: inherit;
}
- .action.hasHoverState:hover .dot-graphic {
+ .action.tooltip-open .dot-graphic {
background-color: #416EDA;
}
- .action.hasHoverState:hover .block {
+ .action.tooltip-open .block {
background-color: #416EDA;
color: white;
}
diff --git a/docs/extra.css b/docs/extra.css
index e3599627..a971d398 100644
--- a/docs/extra.css
+++ b/docs/extra.css
@@ -3,6 +3,7 @@
body {
overflow-wrap: break-word;
+ overflow-x: hidden;
}
p {