Model Context Protocol

Where Finance Meets Secure AI

Maxio MCP connects your governed financial data and logic to trusted AI tools, giving finance and RevOps teams a faster and more controlled way to work with the information they rely on.

What is Model Context Protocol?

Maxio MCP (Model Context Protocol) is the secure AI layer for finance. It links the structured financial data and logic inside Maxio to the AI tools your team already uses.

Equip Finance and RevOps leaders with governed, auditable natural-language access to data exploration, reporting, and approved tasks, ensuring a modern workflow that remains both accurate and compliant.

Maxio AI MCP model interface with revenue, usage, and subscription analytics.


Why It Matters

Finance teams benefit from MCP in four key ways.

Secure access to your financial data

Secure access to your financial data

Give approved AI tools a safe, governed way to access your Maxio data — no exports, no manual consolidation needed.

Outputs reflect your financial model

Outputs reflect your financial model

AI responses follow Maxio’s definitions and structure, so insights match your actual revenue, billing, and subscription logic.

Reports and approved actions become faster

Reports and approved actions become faster

Use natural language to generate reports or request approved billing actions while MCP manages secure access behind the scenes.

You keep full control and oversight

You keep full control and oversight

Permissions, scoped access, and audit logs stay enforced, allowing safe AI use without exposing sensitive financial data.





What You Can Do with Maxio MCP

Here are a few examples of workflows Maxio MCP can support.

Governance and Control

Maxio MCP enforces your existing permissions so AI can only access the data and actions you explicitly allow. Every interaction is authenticated and logged, giving you full visibility and compliance without adding new oversight work.

Maxio AI MCP Model Context Protocol for financial and business management.


See Maxio MCP in Action




“The new Maxio MCP has dramatically cut the time I spend on reporting. I’ve been using Maxio MCP with Claude, I can just ask for the data I need and it does all the heavy lifting. I get everything I need in seconds instead of digging through multiple screens.”

AI MCP Model Context Protocol for Maxio platform.

Drew Weik

Revenue Operations Manager

Maxio AI MCP Model Protocol for Financial Data Integration.
#mx-combine-pbr-block_dcc107b307c0d5d1b340e96b095700de.mx-combine-pbr { display: block; padding: 60px 0px; background: #ffffff; max-width: 100vw; overflow: hidden; } .mx-combine-pbr__container { width: 100%; max-width: 1280px; padding: 0 24px; margin: auto; } .mx-combine-pbr__main { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 55px; align-self: stretch; } .mx-combine-pbr__image-wrap { display: flex; justify-content: center; align-items: center; width: 610px; flex: none; } .mx-combine-pbr__image { display: block; max-width: 100%; height: auto; } .mx-combine-pbr__content { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 0px; flex: 1 0 0; } .mx-combine-pbr__heading { align-self: stretch; color: #000; text-align: left; font-family: ‘Test Founders Grotesk’, ‘Founders Grotesk’, Founders Grotesk, ui-sans-serif, system-ui, sans-serif; font-size: 48px; line-height: 48px; font-weight: 500; margin: 0 0 20px; padding: 0; } .mx-combine-pbr__cta { display: inline-flex; flex-wrap: wrap; align-items: center; justify-content: center; border-radius: 3px; background: #0042FF; color: #FFFFFF; font-size: 20px; font-style: normal; font-weight: 500; line-height: 28px; padding: 10px 40px; margin-top: 20px; letter-spacing: 0; border: none; min-width: 176px; transition: background 0.3s linear; } .mx-combine-pbr__cta:hover { background: #0036CC; } .mx-combine-pbr .mx-combine-pbr__description p, .mx-combine-pbr .mx-combine-pbr__description a, .mx-combine-pbr .mx-combine-pbr__description li { color: #000000; font-size: 20px; font-style: normal; font-weight: 300; line-height: 28px; } .mx-combine-pbr .mx-combine-pbr__description p, .mx-combine-pbr .mx-combine-pbr__description ul { margin-bottom: 12px; } .mx-combine-pbr .mx-combine-pbr__description li { position: relative; padding-left: 30px } .mx-combine-pbr .mx-combine-pbr__description li:before { content: ”; position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 4px; height: 4px; background: #000000; border-radius: 50%; } .mx-combine-pbr .mx-combine-pbr__description a { text-decoration: underline; text-decoration-skip-ink: none; text-underline-offset: 4px; text-decoration-thickness: 1px; } .mx-combine-pbr .mx-combine-pbr__description a:hover { color: #000000; text-decoration: none; } .mx-combine-pbr.mx-switch .mx-combine-pbr__main { flex-direction: row-reverse; } /* Style 2 */ .mx-combine-pbr.mx-style-two .mx-combine-pbr__heading { background: linear-gradient(90deg, #000 19.1%, #002EB2 80.25%); background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent; font-size: 56px; font-style: normal; font-weight: 500; line-height: 56px; margin-bottom: 16px; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__description p { color: #2D2D30; font-size: 24px; font-style: normal; font-weight: 300; line-height: 31px; margin-bottom: 16px; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__description li { color: #000000; font-size: 20px; font-style: normal; font-weight: 500 !important; line-height: 28px; margin-bottom: 12px; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__cta { margin-top: 12px; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__description li { padding-left: 36px; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__description li:before { content: ”; background: url(“data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xMi41NzI1IDUuNDk4MDVMMTguNSAxMS40MjU2VjEyLjU3NDZMMTIuNTcyNyAxOC41MDE5TDExLjQyMzcgMTcuMzUyOUwxNS4xNTE0IDEzLjYyNTFMMTQuMzM4OSAxMi44MTI2TDUuNSAxMi44MTI2VjExLjE4NzZMMTQuMzM4OSAxMS4xODc2TDE1LjE1MTQgMTAuMzc1MUwxMS40MjM0IDYuNjQ3MDlMMTIuNTcyNSA1LjQ5ODA1WiIgZmlsbD0iIzAwNDJGRiIvPgo8L3N2Zz4=”); width: 24px; height: 24px; top: 2px; left: 0; transform: none; } @media all and (max-width: 1279.98px) { #mx-combine-pbr-block_dcc107b307c0d5d1b340e96b095700de.mx-combine-pbr { padding: 60px 0px; } .mx-combine-pbr__main { max-width: 720px; margin: 0 auto; flex-direction: column-reverse; align-items: center; gap: 0px; } .mx-combine-pbr.mx-style-one .mx-combine-pbr__main { flex-direction: column; } .mx-combine-pbr.mx-style-one .mx-combine-pbr__content { margin-bottom: 0; margin-top: 8px; } .mx-combine-pbr__image-wrap { width: 100%; max-width: 610px; margin: 0 auto;} .mx-combine-pbr__content { align-items: center; margin-bottom: 64px; } .mx-combine-pbr__heading { text-align: center; margin: 0 0 32px; } .mx-combine-pbr.has-description .mx-combine-pbr__heading { text-align: left; } .mx-combine-pbr.mx-switch .mx-combine-pbr__main { flex-direction: column-reverse; } } @media(max-width: 1024.98px) { .mx-combine-pbr.mx-style-two .mx-combine-pbr__heading { text-align: left; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__content { align-items: flex-start; } } @media all and (max-width: 639.98px) { #mx-combine-pbr-block_dcc107b307c0d5d1b340e96b095700de.mx-combine-pbr { padding: 64px 0px; } .mx-combine-pbr__main { gap: 0; } .mx-combine-pbr__image-wrap { width: 100%; max-width: 610px; margin: 0 auto;} .mx-combine-pbr__content { align-items: flex-start; } .mx-combine-pbr__heading { text-align: left; font-size: 32px; line-height: 32px; margin-bottom: 16px; } .mx-combine-pbr__cta { padding: 10px 36px; min-width: 165px; margin-top: 16px; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__heading { font-size: 36px; line-height: 36px; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__cta { width: 100%; max-width: 100%; } .mx-combine-pbr.mx-style-two .mx-combine-pbr__content { margin-bottom: 48px; } }
pbr-subscription-billing-desktop-01

Streamline finance workflows with AI-powered support that’s safe, reliable, and fully within your control.

window.onload = () => { if(document.querySelectorAll('.faq-item-heading').length > 0) { document.querySelectorAll('.faq-item-heading').forEach(heading => heading.addEventListener('click', () => { const item = heading.closest('.faq-item'); document.querySelectorAll('.faq-item').forEach(i => i.classList.toggle('active', i === item && !item.classList.contains('active'))); }) ); } if(document.querySelectorAll('.mx-accordion-slider').length > 0) { initAccordianSlider(); } if(document.querySelectorAll('.mx-one-platform').length > 0) { initMxOnePlatformTab(); } /* Hero Email */ initHeroEmail(); /* Flexible Pricing Slider */ initPriceSlider(); /* Review Slider */ initReviewSlider(); /* Explore B2B */ initExploreFnBPlatformSlider(); /* Animated Headlines */ initAnimatedHeadlines(); }; function initAnimatedHeadlines() { let animated_headline = new Splide('.mx-animated-headline', { direction: 'ttb', // top-to-bottom height: '68px', wheel: false, // optional: allow scroll wheel navigation autoplay: true, interval: 5000, type: 'loop', arrows: false, drag: false, pagination: false, easing: 'cubic-bezier(0.25, 1, 0.5, 1)', breakpoints: { 767: { height: '40px', } } }); animated_headline.mount(); } /* Explore B2B */ function initExploreFnBPlatformSlider() { let review_splide = null; let is_rp_slider_autoplay = 1; let sliderSelector = '.mx-explore-fnb-platform__slider[data-is-slider="true"]'; let check_fnb_platform_slider; // Helper: move Splide pagination to custom container function movePaginationToCustomContainer(instance) { const custom = document.querySelector('.mx-explore-fnb-platform__slider-pagination'); const pagination = instance.root.querySelector('.splide__pagination'); if (custom && pagination && !custom.contains(pagination)) { custom.appendChild(pagination); } } // Function to initialize the slider function createSlider() { const sliderEl = document.querySelector(sliderSelector); if (!sliderEl || typeof window.Splide === 'undefined') return; review_splide = new Splide(sliderEl, { pagination: true, type: 'loop', gap: '48px', autoWidth: true, autoplay: false, interval: 5000, arrows: false, flickPower: 50, flickMaxPages: 1, focus: 0, omitEnd: true, breakpoints: { 767: { autoWidth: false, perPage: 1, gap: '0', }, }, }); review_splide.on('mounted', function () { movePaginationToCustomContainer(review_splide); document.addEventListener("scroll", function() { if (isInViewport(sliderEl) && is_rp_slider_autoplay === 1) { if (review_splide.Components.Autoplay && !review_splide.options.autoplay) { review_splide.Components.Autoplay.play(); review_splide.options = { autoplay: true }; } } }); /* window.onscroll = () => { if (isInViewport(sliderEl) && is_rp_slider_autoplay === 1) { if (review_splide.Components.Autoplay && !review_splide.options.autoplay) { review_splide.Components.Autoplay.play(); review_splide.options = { autoplay: true }; } } }; */ const platformWrapper = document.querySelector('.mx-explore-fnb-platform'); if (platformWrapper) { platformWrapper.addEventListener('click', (e) => { if ( e.target.classList.contains('splide__pagination__page') || e.target.classList.contains('mx-explore-fnb-platform__card') ) { is_rp_slider_autoplay = 2; if (review_splide.Components.Autoplay) { review_splide.Components.Autoplay.pause(); review_splide.options = { autoplay: false }; } } }); } }); review_splide.on('pagination:mounted', function () { movePaginationToCustomContainer(review_splide); }); review_splide.mount(); console.log('✅ Splide initialized'); } // Function to destroy slider if it exists function destroySlider() { if (review_splide) { review_splide.destroy(true); review_splide = null; console.log('🛑 Splide destroyed'); } } // Function to handle slider creation based on viewport width function handleResponsiveSlider() { const viewportWidth = window.innerWidth; if (viewportWidth >= 1024) { if (!review_splide) createSlider(); } else { destroySlider(); } } // Wait for Splide and slider element check_fnb_platform_slider = setInterval(() => { if (typeof window.Splide !== 'undefined' && document.querySelector(sliderSelector)) { clearInterval(check_fnb_platform_slider); handleResponsiveSlider(); window.addEventListener('resize', () => { handleResponsiveSlider(); }); } }, 300); } function initReviewSlider() { let check_review_slider = setInterval(() => { if(typeof window.Splide !== 'undefined' && document.querySelectorAll('.mx-cust-review').length > 0) { clearInterval(check_review_slider); let is_rp_slider_autoplay = 1; var review_splide = new Splide('.mx-cust-review-slider', { pagination: true, type: 'loop', gap: '20px', autoWidth: true, autoplay: false, interval: 5000, arrows: false, flickPower: 50, /* Lower value = less aggressive flicking */ flickMaxPages: 1, /* Limit to 1 page per flick */ focus: 0, /* Focus on first visible slide */ omitEnd: true, breakpoints: { 767: { autoWidth: false, perPage: 1, gap: '0', } } }); // Move pagination to custom container function movePaginationToCustomContainer(instance) { var custom = document.querySelector('.mx-cust-review-slider-pagination'); var pagination = instance.root.querySelector('.splide__pagination'); if (custom && pagination && !custom.contains(pagination)) { custom.appendChild(pagination); } } review_splide.on('mounted', function () { console.log('--testing--'); movePaginationToCustomContainer(review_splide); document.addEventListener("scroll", function() { if(isInViewport(document.querySelector('.mx-cust-review')) && is_rp_slider_autoplay == 1) { if(review_splide.Components.Autoplay && !review_splide.options.autoplay) { review_splide.Components.Autoplay.play(); review_splide.options = { autoplay: true }; } } }); /* window.onscroll = () => { if(isInViewport(document.querySelector('.mx-cust-review')) && is_rp_slider_autoplay == 1) { if(review_splide.Components.Autoplay && !review_splide.options.autoplay) { review_splide.Components.Autoplay.play(); review_splide.options = { autoplay: true }; } } }; */ document.querySelector('.mx-cust-review').addEventListener('click', (e) => { if(e.target.classList.contains('splide__pagination__page')) { is_rp_slider_autoplay = 2; if(review_splide.Components.Autoplay) { review_splide.Components.Autoplay.pause(); // pause immediately review_splide.options = { autoplay: false }; // disable autoplay for future } } if(e.target.classList.contains('mx-cust-review-card')) { is_rp_slider_autoplay = 2; if(review_splide.Components.Autoplay) { review_splide.Components.Autoplay.pause(); // pause immediately review_splide.options = { autoplay: false }; // disable autoplay for future } } }); }); review_splide.on('drag', () => { if(window.innerWidth 0 && document.querySelectorAll('.mx-wrapper .email-cta-wrap .email-cta').length > 0 && document.querySelectorAll('.mx-wrapper .email-cta-wrap input').length > 0 ) { // Email Popup let formWrap = document.querySelector('.mx-form-popup .mx-form-wrap'); let emailcta = document.querySelector('.mx-wrapper .email-cta-wrap .email-cta'); let email = document.querySelector('.mx-wrapper .email-cta-wrap input'); email.addEventListener('focus', function () { email.closest('.email-cta-wrap').classList.add('focused'); email.closest('.email-cta-wrap').classList.remove('filled'); }); email.addEventListener('blur', function () { email.closest('.email-cta-wrap').classList.remove('focused'); if (email.value === '') { email.closest('.email-cta-wrap').classList.remove('filled'); } else { email.closest('.email-cta-wrap').classList.add('filled'); } }); email.addEventListener('keypress', function (e) { if (e.key === 'Enter') { emailcta.click(); email.blur(); } }); emailcta.addEventListener('click', function(event) { const heroemailValue = email.value; const iframe = document.querySelector('.mx-form-popup iframe'); iframe.contentWindow.postMessage({ storeemail: heroemailValue }, '*'); document.body.classList.add('show-modal'); event.stopPropagation(); }); document.querySelector('.mx-form-popup .popup-close').addEventListener('click',function(){ document.body.classList.remove('show-modal'); }); document.addEventListener('click', (e) => { if (!formWrap.contains(e.target) && !emailcta.contains(e.target)) { document.body.classList.remove('show-modal'); } if (e.target.classList.contains('email-cta')) { e.preventDefault(); const heroemailValue = email.value; const iframe = document.querySelector('.mx-form-popup iframe'); iframe.contentWindow.postMessage({ storeemail: heroemailValue }, '*'); document.body.classList.add('show-modal'); event.stopPropagation(); } }); } } function initPriceSlider() { if(typeof window.Splide != 'undefined' && document.querySelectorAll('.mx-flexible-pricing-slider').length > 0) { let is_slider_autoplay = 1; let pricing_slider = new Splide('.mx-flexible-pricing-slider', { type: 'loop', fixedWidth : '500px', gap: '24px', pagination: false, autoplay: false, interval: 5000, pauseOnHover: false, pauseOnFocus: false, breakpoints: { 640: { fixedWidth : '300px', gap: '16px', }, }, }); pricing_slider.on('mounted refreshed', () => { document.addEventListener("scroll", function() { if(isInViewport(document.querySelector('.mx-flexible-pricing-slider')) && is_slider_autoplay == 1) { if(pricing_slider.Components.Autoplay && !pricing_slider.options.autoplay) { pricing_slider.Components.Autoplay.play(); pricing_slider.options = { autoplay: true }; } } }); /* window.onscroll = () => { if(isInViewport(document.querySelector('.mx-flexible-pricing-slider')) && is_slider_autoplay == 1) { if(pricing_slider.Components.Autoplay && !pricing_slider.options.autoplay) { pricing_slider.Components.Autoplay.play(); pricing_slider.options = { autoplay: true }; } } }; */ document.querySelector('.mx-flexible-pricing-slider').addEventListener('click', (e) => { if(e.target.classList.contains('splide__arrow') && e.target.classList.contains('splide__arrow--prev')) { is_slider_autoplay = 2; if(pricing_slider.Components.Autoplay) { pricing_slider.Components.Autoplay.pause(); // pause immediately pricing_slider.options = { autoplay: false }; // disable autoplay for future } } if(e.target.classList.contains('splide__arrow') && e.target.classList.contains('splide__arrow--next')) { is_slider_autoplay = 2; if(pricing_slider.Components.Autoplay) { pricing_slider.Components.Autoplay.pause(); // pause immediately pricing_slider.options = { autoplay: false }; // disable autoplay for future } } }); }); // Pause Autoplay document.querySelectorAll('.mx-flexible-pricing-slider .mx-flexible-pricing-col').forEach( col => { col.addEventListener('click', () => { is_slider_autoplay = 2; if(pricing_slider.Components.Autoplay) { pricing_slider.Components.Autoplay.pause(); // pause immediately pricing_slider.options = { autoplay: false }; // disable autoplay for future } }); }); pricing_slider.mount(); } } function initAccordianSlider() { const DURATION = 8000; // 7 seconds const accordionContents = document.querySelector('.mx-features-accordion__contents'); const NoOfAccordion = accordionContents.querySelectorAll('.content').length; let currenctActive = 0; let currentSlideProgress = 0; let autoSlide = true; let accordionPaused = false; // New flag to track pause state // Initialize Accordion active item accordionContents.children[currenctActive].classList.add('active'); //check if .mx-features-accordion is in view const observer = new IntersectionObserver((entries, observer) => { entries.forEach(entry => { if (entry.isIntersecting) { if (!accordionPaused) { autoSlide = true; } } else { autoSlide = false; } }); }, { rootMargin: "0px 0px -50% 0px" }); observer.observe(document.querySelector('.mx-features-accordion')); // Add event listeners to accordion navigation items for hover functionality Array.from(accordionContents.children).forEach((item, index) => { item.querySelector('.mx-features-accordion__item').addEventListener('click', (e) => { e.preventDefault(); accordionPaused = true; // Pause the accordion autoSlide = false; e.target.closest('.mx-features-accordion__item').classList.add('acc-paused'); if (currenctActive !== index) { changeAccordionActiveItem(index); } }); item.addEventListener('mouseenter', (e) => { e.preventDefault(); // if (currenctActive === index) { autoSlide = false; // } }); item.addEventListener('mouseleave', (e) => { e.preventDefault(); // if (currenctActive === index) { if (!accordionPaused) { autoSlide = true; } // } }); }); // Running Interval const autoSlideInterval = setInterval(function () { if (!autoSlide || accordionPaused) return; if (currentSlideProgress >= 100) { currenctActive = (currenctActive + 1 >= NoOfAccordion) ? 0 : (currenctActive + 1); changeAccordionActiveItem(currenctActive); } else { currentSlideProgress = currentSlideProgress + (100 * 200 / DURATION); progressBarWidthAnimation(currenctActive, currentSlideProgress); } }, 200); // Methods function progressBarWidthAnimation(active, width) { Array.from(accordionContents.children)[active].querySelector('.mx-features-accordion__item .progress_bar').style.width = `${width}%`; } function changeAccordionActiveItem(current) { currentSlideProgress = 0; currenctActive = current; // Remove all active classes for (let i = 0; i { head.classList.toggle('mx-one-platform__head--active', i === index); const fillCircle = head.querySelector('.mx-one-platform__progress-fill'); if (fillCircle) { fillCircle.style.transition = 'none'; fillCircle.style.strokeDashoffset = 69.12; if (i === index && resetTimer && !userTriggered) { void fillCircle.getBoundingClientRect(); // force reflow fillCircle.style.transition = `stroke-dashoffset ${options.autoplayTimer}ms linear`; fillCircle.style.strokeDashoffset = 0; } } }); bodies.forEach((body, i) => { body.classList.toggle('mx-one-platform__body--active', i === index); }); activeIndex = index; ensureVisible(index); // reset timing tracking progressStartTime = Date.now(); progressRemaining = options.autoplayTimer; } // smoothly scroll the heads wrapper so the active tab is visible function ensureVisible(index) { const wrapper = section.querySelector('.mx-one-platform__heads-wrapper'); const activeHead = heads[index]; const wrapperRect = wrapper.getBoundingClientRect(); const activeRect = activeHead.getBoundingClientRect(); const sidePadding = 40; const scrollLeft = wrapper.scrollLeft + (activeRect.left - wrapperRect.left) - (wrapperRect.width / 2 - activeRect.width / 2); const targetScroll = Math.max(0, scrollLeft - sidePadding); wrapper.scrollTo({ left: targetScroll, behavior: "smooth" }); } // goto next tab function nextTab() { let next = (activeIndex + 1) % heads.length; setActive(next); } // start autoplay function startAutoplay() { if (timer || autoplayStoppedByUser) return; progressStartTime = Date.now(); timer = setTimeout(() => { nextTab(); stopAutoplay(); startAutoplay(); // restart cycle }, progressRemaining); } // stop autoplay function stopAutoplay() { if (timer) clearTimeout(timer); timer = null; } // pause autoplay (on hover) function pauseAutoplay() { if (paused || autoplayStoppedByUser) return; paused = true; // calculate remaining time const elapsed = Date.now() - progressStartTime; progressRemaining = Math.max(0, progressRemaining - elapsed); stopAutoplay(); // pause stroke animation const activeFill = heads[activeIndex].querySelector('.mx-one-platform__progress-fill'); if (activeFill) { const computedStyle = window.getComputedStyle(activeFill); const matrix = computedStyle.transform; // get current stroke progress const dashoffset = parseFloat(computedStyle.strokeDashoffset); activeFill.style.transition = 'none'; activeFill.style.strokeDashoffset = dashoffset; } } // resume autoplay (on hover out) function resumeAutoplay() { if (!paused || autoplayStoppedByUser) return; paused = false; const activeFill = heads[activeIndex].querySelector('.mx-one-platform__progress-fill'); if (activeFill) { void activeFill.getBoundingClientRect(); // reflow activeFill.style.transition = `stroke-dashoffset ${progressRemaining}ms linear`; activeFill.style.strokeDashoffset = 0; } progressStartTime = Date.now(); startAutoplay(); } // attach click listeners to tabs heads.forEach(head => { head.addEventListener('click', () => { setActive(+head.dataset.index, true, true); autoplayStoppedByUser = true; stopAutoplay(); }); }); // hover pause/resume handlers on the whole section tab_heads.forEach(head => { head.addEventListener('mouseenter', () => { if(head.classList.contains('mx-one-platform__head--active')) { pauseAutoplay(); } }); head.addEventListener('mouseleave', () => { if(head.classList.contains('mx-one-platform__head--active')) { resumeAutoplay(); } }); }); tab_UI.forEach(body => { body.addEventListener('mouseenter', pauseAutoplay); body.addEventListener('mouseleave', resumeAutoplay); }); // start autoplay when section comes into view const observer = new IntersectionObserver(entries => { entries.forEach(entry => { if (entry.isIntersecting && !autoplayStarted) { autoplayStarted = true; setActive(0); startAutoplay(); observer.disconnect(); } }); }, { threshold: 0.5 }); observer.observe(section); } // To check if element is in viewport function isInViewport(el) { const rect = el.getBoundingClientRect(); return ( rect.top 0 ); }