Add massive collection of CSS, JavaScript and theme assets that were previously excluded: **CSS Files (681 total):** - HVAC plugin-specific styles (hvac-*.css): 34 files including dashboard, certificates, registration, mobile nav, accessibility fixes, animations, and welcome popup - Theme framework files (Astra, builder systems, layouts): 200+ files - Plugin compatibility styles (WooCommerce, WPForms, Elementor, Contact Form 7): 150+ files - WordPress core and editor styles: 50+ files - Responsive and RTL language support: 200+ files **JavaScript Files (400+ total):** - HVAC plugin functionality (hvac-*.js): 27 files including menu systems, dashboard enhancements, profile sharing, mobile responsive features, accessibility, and animations - Framework and library files: jQuery plugins, GSAP, AOS, Swiper, Chart.js, Lottie, Isotope - Plugin compatibility scripts: WPForms, WooCommerce, Elementor, Contact Form 7, LifterLMS - WordPress core functionality: customizer, admin, block editor compatibility - Third-party integrations: Stripe, SMTP, analytics, search functionality **Assets:** - Certificate background images and logos - Comprehensive theme styling infrastructure - Mobile-responsive design systems - Cross-browser compatibility assets - Performance-optimized minified versions **Updated .gitignore:** - Fixed asset directory whitelisting patterns to properly include CSS/JS/images - Added proper directory structure recognition (!/assets/css/, !/assets/js/, etc.) - Maintains security by excluding sensitive files while including essential assets This commit provides the complete frontend infrastructure needed for: - Full theme functionality and styling - Plugin feature implementations - Mobile responsiveness and accessibility - Cross-browser compatibility - Performance optimization - Developer workflow support
1 line
No EOL
3.9 KiB
JavaScript
1 line
No EOL
3.9 KiB
JavaScript
function uagbTimelineInit(){const e=document.querySelector("iframe[name='editor-canvas']");let t;var r=t=(e?e.contentDocument:document).querySelectorAll(".uagb-timeline");if(0!==r.length)for(const a of r){const _=a.querySelector(".uagb-timeline__line__inner"),s=a.querySelector(".uagb-timeline__line");var i=a.querySelectorAll(".uagb-timeline__marker"),l=a.querySelector(".uagb-timeline__field:nth-last-child(2)"),l=l||a.querySelector(".block-editor-block-list__block:last-child");const c=i[0],m=i[i.length-1];setTimeout(()=>{s.style.top=c?.offsetTop+"px"},300);var n,u,o,l=l?.offsetHeight,l=(a.classList.contains("uagb-timeline__arrow-center")?s.style.bottom=m?.offsetTop+"px":a.classList.contains("uagb-timeline__arrow-top")?(n=l-m?.offsetTop,s.style.bottom=n+"px"):a.classList.contains("uagb-timeline__arrow-bottom")&&(n=l-m?.offsetTop,s.style.bottom=n+"px"),3*i[0]?.offsetHeight),g=document?.documentElement?.clientHeight/2+l,i=document.body,l=document.documentElement,i=Math.max(i.scrollHeight,i.offsetHeight,l.clientHeight,l.scrollHeight,l.offsetHeight),l=i-m?.getBoundingClientRect()?.top,i=i-c?.getBoundingClientRect()?.top-l,l=c?.getBoundingClientRect()?.top+window?.scrollY-(window?.innerHeight-window?.innerHeight/3);l<document?.documentElement?.scrollTop&&((l=i/100*((document?.documentElement?.scrollTop-l)/i*100))<60+i&&(_.style.height=l+"px"));const d=a.querySelectorAll(".uagb-timeline__marker");let t=a.querySelectorAll(".uagb-timeline__field");0===t.length&&(t=a.querySelectorAll(".uagb-timeline__animate-border"));for(let e=0;e<d.length;e++)o=d[e].lastElementChild.getBoundingClientRect().top+window.scrollY,u=t[e].lastElementChild.getBoundingClientRect().top+window.scrollY,o=o-document.documentElement.scrollTop,u-document.documentElement.scrollTop<g?(t[e].classList.remove("out-view"),t[e].classList.add("in-view")):(t[e].classList.add("out-view"),t[e].classList.remove("in-view")),o<g?(d[e].classList.remove("uagb-timeline__out-view-icon"),d[e].classList.add("uagb-timeline__in-view-icon")):(d[e].classList.add("uagb-timeline__out-view-icon"),d[e].classList.remove("uagb-timeline__in-view-icon"))}}function UAGBTimelineClasses(l,e){e=document.querySelectorAll(e);if(0!==e.length){var n=Math.max(window.screen.width,window.innerWidth);for(const o of e){o.classList.remove("uagb-timeline__left-block","uagb-timeline__right-block","uagb-timeline__center-block");let e="",t=(n<=uagb_timeline_data.mobile_breakpoint?e="Mobile":n<=uagb_timeline_data.tablet_breakpoint&&(e="Tablet"),"left"===l["timelinAlignment"+e]?o.classList.add("uagb-timeline__left-block"):"right"===l["timelinAlignment"+e]?o.classList.add("uagb-timeline__right-block"):o.classList.add("uagb-timeline__center-block"),o.querySelectorAll(".wp-block-uagb-content-timeline-child")),i=0;for(const a of t=0===t.length?o.querySelectorAll(".uagb-timeline__field"):t){a.classList.remove("uagb-timeline__left","uagb-timeline__right");const s=a.querySelectorAll(".uagb-timeline__marker")[0],c=(s.classList.remove("uagb-timeline__left","uagb-timeline__right"),a.querySelectorAll(".uagb-timeline__events-inner-new")[0]);c.classList.remove("uagb-timeline__day-right","uagb-timeline__day-left"),"left"===l["timelinAlignment"+e]?(a.classList.add("uagb-timeline__left"),s.classList.add("uagb-timeline__left"),c.classList.add("uagb-timeline__day-left")):"right"===l["timelinAlignment"+e]?(a.classList.add("uagb-timeline__right"),s.classList.add("uagb-timeline__left"),c.classList.add("uagb-timeline__day-right")):"center"===l["timelinAlignment"+e]&&(i%2==0?(a.classList.add("uagb-timeline__right"),s.classList.add("uagb-timeline__right"),c.classList.add("uagb-timeline__day-right")):(a.classList.add("uagb-timeline__left"),s.classList.add("uagb-timeline__left"),c.classList.add("uagb-timeline__day-left"))),i++}}}}window.addEventListener("DOMContentLoaded",uagbTimelineInit),window.addEventListener("resize",uagbTimelineInit),window.addEventListener("scroll",uagbTimelineInit),document.addEventListener("UAGTimelineEditor",uagbTimelineInit); |