sirbi

gis-usatu

Dec 23rd, 2021
1,968
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 135.00 KB | None | 0 0
  1. <!DOCTYPE html>
  2.  
  3. <html lang="en" class="is-loaded is-ready has-scroll-init has-scroll-smooth has-scroll-scrolling" data-scroll-direction="vertical" data-direction="up">
  4.    <head>
  5.       <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  6.       <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
  7.       <meta name="apple-mobile-web-app-capable" content="yes">
  8.       <meta name="apple-mobile-web-app-status-bar-style" content="black">
  9.  
  10.       <meta name="msapplication-TileColor" content="#ffffff">
  11.       <meta name="msapplication-TileImage" content="assets/icons/ms-icon-144x144.png">
  12.       <meta name="theme-color" content="#ffffff">
  13.       <title>точно мой сайт</title>
  14.       <meta name="description" content="Lots of people want to ride with you in the limo, but what you want is someone who will take the bus with you when the limo breaks down.">
  15.       <script async="" src="./index2_files/js-id=UA-20462557-9.js" tppabs="https://www.googletagmanager.com/gtag/js?id=UA-20462557-9"></script><script>function gtag(){dataLayer.push(arguments)}window.dataLayer=window.dataLayer||[],gtag("js",new Date),gtag("config","UA-20462557-9");</script>
  16.       <link rel="preconnect" href="https://fonts.gstatic.com/">
  17.       <link href="./index2_files/css2-family=Michroma&amp;family=Roboto+Mono&amp;display=swap.css" tppabs="https://fonts.googleapis.com/css2?family=Michroma&amp;family=Roboto+Mono&amp;display=swap" rel="stylesheet">
  18. <!-------------------------------------------------------------------- CSS ----------------------------------------------------------------------------------->
  19.       <style>
  20. html.has-scroll-smooth {
  21.     overflow: hidden
  22. }
  23.  
  24. html.has-scroll-dragging {
  25.     -webkit-user-select: none;
  26.     -moz-user-select: none;
  27.     -ms-user-select: none;
  28.     user-select: none
  29. }
  30.  
  31. .has-scroll-smooth body {
  32.     overflow: hidden
  33. }
  34.  
  35. .has-scroll-smooth [data-scroll-container] {
  36.     min-height: 100vh
  37. }
  38.  
  39. [data-scroll-direction="horizontal"] [data-scroll-container] {
  40.     height: 100vh;
  41.     display: inline-block;
  42.     white-space: nowrap
  43. }
  44.  
  45. [data-scroll-direction="horizontal"] [data-scroll-section] {
  46.     display: inline-block;
  47.     vertical-align: top;
  48.     white-space: nowrap;
  49.     height: 100%
  50. }
  51.  
  52. .c-scrollbar {
  53.     position: absolute;
  54.     right: 0;
  55.     top: 0;
  56.     width: 11px;
  57.     height: 100%;
  58.     transform-origin: center right;
  59.     transition: transform 0.3s, opacity .3s;
  60.     opacity: 0
  61. }
  62.  
  63. .c-scrollbar:hover {
  64.     transform: scaleX(1.45)
  65. }
  66.  
  67. .c-scrollbar:hover,
  68. .has-scroll-dragging .c-scrollbar,
  69. .has-scroll-scrolling .c-scrollbar {
  70.     opacity: 1
  71. }
  72.  
  73. [data-scroll-direction="horizontal"] .c-scrollbar {
  74.     width: 100%;
  75.     height: 10px;
  76.     top: auto;
  77.     bottom: 0;
  78.     transform: scaleY(1)
  79. }
  80.  
  81. [data-scroll-direction="horizontal"] .c-scrollbar:hover {
  82.     transform: scaleY(1.3)
  83. }
  84.  
  85. .c-scrollbar_thumb {
  86.     position: absolute;
  87.     top: 0;
  88.     right: 0;
  89.     background-color: #000;
  90.     opacity: .5;
  91.     width: 7px;
  92.     border-radius: 10px;
  93.     margin: 2px;
  94.     cursor: -webkit-grab;
  95.     cursor: grab
  96. }
  97.  
  98. .has-scroll-dragging .c-scrollbar_thumb {
  99.     cursor: -webkit-grabbing;
  100.     cursor: grabbing
  101. }
  102.  
  103. [data-scroll-direction="horizontal"] .c-scrollbar_thumb {
  104.     right: auto;
  105.     bottom: 0
  106. }
  107.  
  108. * {
  109.     outline: none;
  110.     box-sizing: border-box
  111. }
  112.  
  113. body {
  114.     background-color: #1234c4;
  115.     color: #bababa;
  116.     margin: 0;
  117.     padding: 0;
  118.     font-family: "Michroma", sans-serif;
  119.     -webkit-text-size-adjust: 100%;
  120.     -webkit-font-smoothing: antialiased;
  121.     box-sizing: border-box;
  122.     transition: background-color .5s ease
  123. }
  124.  
  125. body.dark {
  126.     background-color: #171727
  127. }
  128.  
  129. a {
  130.     color: #fff;
  131.     text-decoration: none
  132. }
  133.  
  134. .loading_screen {
  135.     position: fixed;
  136.     top: 0;
  137.     left: 0;
  138.     width: 100vw;
  139.     height: 100vh;
  140.     background: #000;
  141.     z-index: 10;
  142.     transition: all 1s cubic-bezier(0.75, -0.01, 0.14, 1);
  143.     clip-path: inset(0% 0% 0% 0%)
  144. }
  145.  
  146. .loading_screen.hide {
  147.     pointer-events: none;
  148.     clip-path: inset(0% 0% 100% 0%)
  149. }
  150.  
  151. .loading_screen .loading_circle {
  152.     position: fixed;
  153.     width: 150vh;
  154.     height: 70vh;
  155.     top: 50%;
  156.     left: 50%;
  157.     transform: translate(-50%, -50%);
  158.     border-radius: 50%;
  159.     border: 2px solid #ffffff
  160. }
  161.  
  162. .evoulve_circle {
  163.     position: fixed;
  164.     width: 70vh;
  165.     height: 70vh;
  166.     top: 50%;
  167.     left: 50%;
  168.     transform: translate(-50%, -50%);
  169.     overflow: hidden;
  170.     border-radius: 50%
  171. }
  172.  
  173. .overlay,
  174. .show {
  175.     position: absolute;
  176.     width: 100%;
  177.     height: 100%;
  178.     top: 0;
  179.     left: 0;
  180.     overflow: hidden;
  181.     border-radius: 50%
  182. }
  183.  
  184. .light {
  185.     border-radius: 50%;
  186.     box-shadow: inset -200px 20px 80px #ffdb00;
  187.     mix-blend-mode: overlay;
  188.     opacity: 1
  189. }
  190.  
  191. .color {
  192.     background: #000;
  193.     mix-blend-mode: color;
  194.     opacity: .4
  195. }
  196.  
  197. .reflect {
  198.     border-radius: 50%;
  199.     box-shadow: inset -20px 20px 60px #fff;
  200.     mix-blend-mode: overlay;
  201.     opacity: 0
  202. }
  203.  
  204. .saturate {
  205.     background: #001670;
  206.     mix-blend-mode: lighten;
  207.     opacity: 1
  208. }
  209.  
  210. .grey {
  211.     background: #c1cdff;
  212.     mix-blend-mode: color;
  213.     transition: opacity .6s ease;
  214.     opacity: 0
  215. }
  216.  
  217. section {
  218.     min-height: 100vh;
  219.     position: relative;
  220.     z-index: 1;
  221.     justify-content: center;
  222.     align-items: center;
  223.     padding: 20vh 0;
  224.     overflow: hidden
  225. }
  226.  
  227. section.black {
  228.     background-color: #000
  229. }
  230.  
  231. section .wrapper {
  232.     width: 80%;
  233.     margin: 0 auto
  234. }
  235.  
  236. section .wrapper.intro {
  237.     padding: 30vh 0;
  238.     position: relative;
  239.     z-index: 2
  240. }
  241.  
  242. section h1 {
  243.     font-weight: 400;
  244.     width: 40vw;
  245.     top: -20vh;
  246.     font-size: 12vw;
  247.     word-wrap: break-word;
  248.     text-transform: uppercase;
  249.     position: relative;
  250.     line-height: 1;
  251.     margin: 0;
  252.     padding: 0
  253. }
  254.  
  255. section h1.bottom {
  256.     top: 0
  257. }
  258.  
  259. section h1 span {
  260.     position: relative;
  261.     display: inline-block
  262. }
  263.  
  264. section p {
  265.     text-transform: uppercase;
  266.     width: 100%;
  267.     font-size: 3vw;
  268.     letter-spacing: 3px;
  269.     margin-bottom: 0;
  270.     padding-bottom: 0
  271. }
  272. section p1 {
  273.     text-transform: uppercase;
  274.     width: 100%;
  275.     font-size: 10vw;
  276.     letter-spacing: 3px;
  277.     margin-bottom: 0;
  278.     padding-bottom: 0
  279. }
  280.  
  281. hr {
  282.     padding-bottom: 10vh;
  283.     margin-bottom: 10vh;
  284.     border: none;
  285.     border-bottom: 2px solid #bababa
  286. }
  287.  
  288. section .expertise {
  289.     display: flex;
  290.     justify-content: space-between
  291. }
  292.  
  293. section p.small {
  294.     text-transform: none;
  295.     width: 90%;
  296.     max-width: 300px;
  297.     font-size: 14px;
  298.     letter-spacing: 1px;
  299.     font-family: "Roboto Mono", monospace;
  300.     border-bottom: none;
  301.     padding-bottom: 0;
  302.     margin-bottom: 0
  303. }
  304.  
  305. section p.small1 {
  306.     text-transform: none;
  307.     width: 90%;
  308.     max-width: 300px;
  309.     font-size: 24px;
  310.     font-family: "Roboto Mono", monospace;
  311.     border-bottom: none;
  312.     padding-bottom: 0;
  313.     margin-bottom: 0;
  314.     position: center;
  315.     text-align: left;
  316. }
  317. section ul {
  318.     padding: 0;
  319.     width: 90%;
  320.     max-width: 400px;
  321.     margin-top: 150px
  322. }
  323.  
  324. section ul li {
  325.     padding: 10px 0;
  326.     list-style: none;
  327.     font-size: 14px;
  328.     letter-spacing: 1px;
  329.     font-family: "Roboto Mono", monospace;
  330.     border-bottom: 1px solid #BABABA;
  331.     display: flex;
  332.     justify-content: space-between
  333. }
  334.  
  335. section ul li span {
  336.     opacity: .5
  337. }
  338.  
  339. section .about {
  340.     position: absolute;
  341.     right: 5vw;
  342.     bottom: 20vh;
  343.     max-width: 250px;
  344.     width: 80%
  345. }
  346.  
  347. section .about p.small {
  348.     font-size: 11px;
  349.     text-transform: uppercase;
  350.     padding: 25px 0;
  351.     border-top: 1px solid #bababa
  352. }
  353.  
  354. section .about p.small  .arrow svg {
  355.     position: relative;
  356.     top: 5px;
  357.     left: 20px;
  358.     height: 25px;
  359.     width: 25px
  360. }
  361.  
  362. section .about p.small  .arrow.flipped svg {
  363.     transform: scaleY(-1)
  364. }
  365.  
  366. .arrow svg * {
  367.     fill: none;
  368.     stroke: #ffffff;
  369.     stroke-miterlimit: 10;
  370.     stroke-width: 3px
  371. }
  372.  
  373. .evoulve_wires {
  374.     position: fixed;
  375.     width: 70vh;
  376.     height: 70vh;
  377.     top: 50%;
  378.     left: 40%;
  379.     transform: translate(-50%, -50%)
  380. }
  381.  
  382. .evoulve_wires .evoulve_wires-inner {
  383.     width: 150%;
  384.     height: 50%;
  385.     background-color: #000;
  386.     position: center
  387. }
  388.  
  389. .evoulve_wires .evoulve_wires-overlay {
  390.     width: 100%;
  391.     height: 100%;
  392.     mix-blend-mode: overlay;
  393.     position: absolute;
  394.     top: 0;
  395.     left: 0;
  396.     opacity: .2
  397. }
  398.  
  399. .evoulve_wires img {
  400.     width: 100%;
  401.     height: 100%;
  402.     opacity: .3
  403. }
  404.  
  405. html:not(.has-scroll-smooth) section {
  406.     clip: rect(0, auto, auto, 0);
  407.     -webkit-clip-path: polygon(100% 0, 100% 100%, 0 100%, 0 0);
  408.     clip-path: polygon(100% 0, 100% 100%, 0 100%, 0 0)
  409. }
  410.  
  411. @media screen and (max-width: 500px) {
  412.     .evoulve_circle,
  413.     .evoulve_wires,
  414.     .loading_screen .loading_circle {
  415.         width: 70vw;
  416.         height: 70vw
  417.     }
  418.     section {
  419.         padding: 10vh 0
  420.     }
  421.     section p {
  422.         width: 100%;
  423.         font-size: 4vw;
  424.         line-height: 1.8;
  425.         letter-spacing: 1px;
  426.         padding-bottom: 10vw;
  427.         margin-bottom: 10vw
  428.     }
  429.     section h1 {
  430.         width: 60vw;
  431.         font-size: 20vw;
  432.         top: 0
  433.     }
  434.     section h1.bottom {
  435.         top: 0
  436.     }
  437.     section .wrapper.intro {
  438.         padding: 0
  439.     }
  440.     hr {
  441.         padding-bottom: 0;
  442.         margin-bottom: 50px;
  443.         margin-top: 0;
  444.         padding-top: 0
  445.     }
  446.     section .about {
  447.         left: 10vw;
  448.         bottom: 15vh
  449.     }
  450.     section ul {
  451.         margin-top: 50px;
  452.         padding-bottom: 50px
  453.     }
  454.     section .expertise {
  455.         display: block
  456.     }
  457. }
  458.   </style>
  459. <!-------------------------------------------------------------------- /CSS---------------------------------------------------------------------------------->
  460.    </head>
  461.    <body class="">
  462.       <div class="evoulve_circle">
  463. <!-------------------------------------------------------------------- Анимация ----------------------------------------------------------------------------->
  464.         <canvas id="glslCanvas" data-fragment="
  465. #ifdef GL_ES
  466. precision lowp float;
  467. #endif
  468. #define TAU 6.28318530718
  469. uniform vec2 u_resolution;
  470. uniform vec2 u_mouse;
  471. uniform float u_time;
  472. // EASE IN/OUT AROUND POINT //
  473. float pointEase(float x, float t, float r, float a) {
  474.    if (x<(t-r) || x >(t+r)) return 0.0;
  475.  
  476.     float n = 0.0;
  477.     x = t-x;
  478.     n = ((1.0 + cos((x * ((TAU/2.0) * (1.0/r))))) / 2.0) * a;
  479.     return n;
  480. }
  481.  
  482. void main() {
  483.     vec2 st = gl_FragCoord.xy/u_resolution;
  484.     float aspect = u_resolution.x / u_resolution.y;
  485.     float distort = st.x / st.y;
  486.     float t = u_time * 0.5;
  487.     float r = 0.8;
  488.  
  489.  
  490.     // move origins of circles //
  491.     float dx1 = 0.5 + (sin(t + 3000.00) * sin(t * 0.33) * 0.5);
  492.     float dy1 = 0.5 + (cos(t + 1000.00) * cos(t * 0.23) * 0.5);
  493.     float dx2 = 0.5 + (sin(t + 5000.00) * sin(t * 0.44) * 0.5);
  494.     float dy2 = 0.5 + (cos(t + 2000.00) * cos(t * 0.43) * 0.5);
  495.     float dx3 = 0.5 + (sin(t + 8000.00) * sin(t * 0.55) * 0.5);
  496.     float dy3 = 0.5 + (cos(t + 3000.00) * cos(t * 0.63) * 0.5);
  497.  
  498.  
  499.     // get sinuous amplitude based on distance from origins //
  500.     float x1 = pointEase(st.x, dx1, r, 1.0);
  501.     float y1 = pointEase(st.y, dy1, r * aspect, 1.0);
  502.     float a1 = x1 * y1;
  503.     float x2 = pointEase(st.x, dx2, r, 1.0);
  504.     float y2 = pointEase(st.y, dy2, r * aspect, 1.0);
  505.     float a2 = x2 * y2;
  506.     float x3 = pointEase(st.x, dx3, r, 1.0);
  507.     float y3 = pointEase(st.y, dy3, r * aspect, 1.0);
  508.     float a3 = x3 * y3;
  509.  
  510.     // colors //
  511.     vec3 c1 = (1.0 - (a2 * a3)) * a1 * vec3(1.0,0.0,1.0);
  512.     vec3 c2 = (1.0 - (a1 * a3)) * a2 * vec3(1.0,0.0,1.0);
  513.     vec3 c3 = (1.0 - (a1 * a2)) * a3 * vec3(1.0,0.0,1.0);
  514.     vec3 bg = vec3(0.1,0.0,0.0);
  515.  
  516.     vec3 color = (c1 + c2 - c3);
  517.     vec3 mixed = (0.0 - color) * bg;
  518.     color += bg;
  519.  
  520.  
  521.     gl_FragColor = vec4(color,1.0);
  522. }
  523. ">
  524.    
  525. </canvas>
  526. <!-------------------------------------------------------------------- /Анимация ----------------------------------------------------------------------------->
  527.          <div class="overlay color"></div>
  528.          <div class="overlay saturate"></div>
  529.          <!--
  530.         <embed src="msc.mp3" loop="true" autostart="false">
  531.         -->
  532.          <div class="overlay light"></div>
  533.          <div class="overlay reflect"></div>
  534.          <div class="overlay grey" id="grey" style="opacity: 0;"></div>
  535.       </div>
  536.       <div class="loading_screen hide" id="loading_screen">
  537.          <div class="loading_circle"></div>
  538.       </div>
  539.       <div id="js-scroll" class="main" data-scroll-container="">
  540.          <section data-scroll-section="" data-scroll-section-id="section0" style="transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1); opacity: 1; pointer-events: all;" data-scroll-section-inview="">
  541.             <div class="title wrapper">
  542.                <h1 data-scroll="" data-scroll-delay="0.09" data-scroll-speed="-6" data-scroll-offset="-50%, 20%" class="is-inview" style="transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 156.732, 0, 1);">кибер гис угату</h1>
  543.                <div class="about">
  544.                   <p class="small">да-да вот так могу</p>
  545.                   <p class="small">
  546.                      спускайся ниже
  547.                      <span class="arrow flipped">
  548.                         <svg viewBox="0 0 80 80" class="cl-t">
  549.                            <polyline points="19.89 15.25 64.03 15.25 64.03 59.33"></polyline>
  550.                            <line x1="64.03" y1="15.25" x2="14.03" y2="65.18"></line>
  551.                         </svg>
  552.                      </span>
  553.                   </p>
  554.                </div>
  555.             </div>
  556.          </section>
  557.          <section class="black" data-scroll-section="" data-scroll-section-id="section1" data-scroll-section-inview="" style="transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1); opacity: 1; pointer-events: all;">
  558.             <div class="evoulve_wires">
  559.                <div class="evoulve_wires-inner is-inview" data-scroll="" data-scroll-speed="-10" data-scroll-offset="-100%, -100%" style="transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, -1364.77, 0, 1);">
  560.                   <img src="./logo.png" tppabs="logo.png">
  561.                   <div id="bgOverlay" class="evoulve_wires-overlay" style="background-color: rgb(110, 247, 110);"></div>
  562.                </div>
  563.             </div>
  564.             <div class="intro wrapper is-inview" id="colorOverlay" data-scroll="" data-scroll-delay="0.07" data-scroll-speed="-3" data-scroll-offset="-50%, 20%" style="transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, -404.566, 0, 1); color: rgb(189, 219, 189);">
  565.                <p class="small">/ </p>
  566.                <!--
  567.               <p>All work must be graded on the credit</p>
  568.           -->
  569.            <p class="bottom">
  570. Геоинформационные системы — системы, предназначенные для сбора, хранения, анализа и графической визуализации пространственных данных и связанной с ними информации о представленных в ГИС объектах. </p>
  571.                <hr>
  572.                <div class="expertise">
  573.                   <p class="small">Ожидается большой проект под названием ГИС УГАТУ. Его разработка уже идет полным ходом. В будущем, эта система поможет решить многие логистические, технические и прочие проблемы. <br><br><br><br>/ </p>
  574.                   <ul>
  575.                      <li>... <span>01</span></li>
  576.                      <li>... <span>02</span></li>
  577.                      <li>... <span>03</span></li>
  578.                      <li>... <span>04</span></li>
  579.                      <li>... <span>05</span></li>
  580.                   </ul>
  581.                </div>
  582.             </div>
  583.          </section>
  584.          <section data-scroll-section="" data-scroll-section-id="section2" style="transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1); opacity: 0; pointer-events: none;">
  585.             <div data-scroll="" id="greyIn" data-scroll-offset="-30%, -100%" data-scroll-repeat="" class=""></div>
  586.             <div class="title wrapper">
  587.                <p1 class="bottom" data-scroll="" data-scroll-delay="0.09" data-scroll-speed="4" data-scroll-offset="-50%, 20%" style="transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 311.857, 0, 1);">
  588.                 сайт про гис угату
  589.                <p>
  590.                <div class="about">
  591.                   <p class="small" href="https://ugatu.su/"> © 2077.<br>сайт классный, будем считать что я его сделал</p>
  592.                   <p class="small">
  593.                      <a href="https://ugatu.su/">УГАТУ</a>
  594.                      <br></br>
  595.                      <a href="https://sun9-71.userapi.com/c858328/v858328710/1960d2/_3AwJbL0vwY.jpg">Дополнение</a>
  596.                      <span class="arrow">
  597.                         <!--
  598.                        <svg viewBox="0 0 80 80" class="cl-t">
  599.                           <polyline points="19.89 15.25 64.03 15.25 64.03 59.33"></polyline>
  600.                          
  601.                           <line x1="64.03" y1="15.25" x2="14.03" y2="65.18"></line>
  602.                       -->
  603.                         </svg>
  604.                      </span>
  605.                   </p>
  606.                </div>
  607.             </div>
  608.          </section>
  609.       </div>
  610. <!-------------------------------------------------------------------- JS ------------------------------------------------------------------------------------>
  611.       <script>
  612.         ! function() {
  613.     "use strict";
  614.  
  615.     function s(t, e) {
  616.         if (!(t instanceof e)) throw new TypeError("Cannot call a class as a function")
  617.     }
  618.  
  619.     function n(t, e) {
  620.         for (var i = 0; i < e.length; i++) {
  621.            var n = e[i];
  622.            n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(t, n.key, n)
  623.        }
  624.    }
  625.  
  626.    function t(t, e, i) {
  627.        return e && n(t.prototype, e), i && n(t, i), t
  628.    }
  629.  
  630.    function e(e, t) {
  631.        var i, n = Object.keys(e);
  632.        return Object.getOwnPropertySymbols && (i = Object.getOwnPropertySymbols(e), t && (i = i.filter(function(t) {
  633.            return Object.getOwnPropertyDescriptor(e, t).enumerable
  634.        })), n.push.apply(n, i)), n
  635.    }
  636.  
  637.    function o(s) {
  638.        for (var t = 1; t < arguments.length; t++) {
  639.            var r = null != arguments[t] ? arguments[t] : {};
  640.            t % 2 ? e(Object(r), !0).forEach(function(t) {
  641.                var e, i, n;
  642.                e = s, n = r[i = t], i in e ? Object.defineProperty(e, i, {
  643.                    value: n,
  644.                    enumerable: !0,
  645.                    configurable: !0,
  646.                    writable: !0
  647.                }) : e[i] = n
  648.            }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(s, Object.getOwnPropertyDescriptors(r)) : e(Object(r)).forEach(function(t) {
  649.                Object.defineProperty(s, t, Object.getOwnPropertyDescriptor(r, t))
  650.            })
  651.        }
  652.        return s
  653.    }
  654.  
  655.    function a(t, e) {
  656.        if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function");
  657.        t.prototype = Object.create(e && e.prototype, {
  658.            constructor: {
  659.                value: t,
  660.                writable: !0,
  661.                configurable: !0
  662.            }
  663.        }), e && i(t, e)
  664.    }
  665.  
  666.    function l(t) {
  667.        return (l = Object.setPrototypeOf ? Object.getPrototypeOf : function(t) {
  668.            return t.__proto__ || Object.getPrototypeOf(t)
  669.        })(t)
  670.    }
  671.  
  672.    function i(t, e) {
  673.        return (i = Object.setPrototypeOf || function(t, e) {
  674.            return t.__proto__ = e, t
  675.        })(t, e)
  676.    }
  677.  
  678.    function h(t) {
  679.        if (void 0 === t) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
  680.        return t
  681.    }
  682.  
  683.    function c(r) {
  684.        var o = function() {
  685.            if ("undefined" == typeof Reflect || !Reflect.construct) return !1;
  686.            if (Reflect.construct.sham) return !1;
  687.            if ("function" == typeof Proxy) return !0;
  688.            try {
  689.                return Date.prototype.toString.call(Reflect.construct(Date, [], function() {})), !0
  690.            } catch (t) {
  691.                return !1
  692.            }
  693.        }();
  694.        return function() {
  695.            var t, e, i, n, s = l(r);
  696.            return e = o ? (t = l(this).constructor, Reflect.construct(s, arguments, t)) : s.apply(this, arguments), i = this, !(n = e) || "object" != typeof n && "function" != typeof n ? h(i) : n
  697.        }
  698.    }
  699.  
  700.    function u(t, e, i) {
  701.        return (u = "undefined" != typeof Reflect && Reflect.get ? Reflect.get : function(t, e, i) {
  702.            var n = function(t, e) {
  703.                for (; !Object.prototype.hasOwnProperty.call(t, e) && null !== (t = l(t)););
  704.                return t
  705.            }(t, e);
  706.            if (n) {
  707.                var s = Object.getOwnPropertyDescriptor(n, e);
  708.                return s.get ? s.get.call(i) : s.value
  709.            }
  710.        })(t, e, i || t)
  711.    }
  712.  
  713.    function D(t, e) {
  714.        return function(t) {
  715.            if (Array.isArray(t)) return t
  716.        }(t) || function(t, e) {
  717.            if ("undefined" == typeof Symbol || !(Symbol.iterator in Object(t))) return;
  718.            var i = [],
  719.                n = !0,
  720.                s = !1,
  721.                r = void 0;
  722.            try {
  723.                for (var o, a = t[Symbol.iterator](); !(n = (o = a.next()).done) && (i.push(o.value), !e || i.length !== e); n = !0);
  724.            } catch (t) {
  725.                s = !0, r = t
  726.            } finally {
  727.                try {
  728.                    n || null == a.return || a.return()
  729.                } finally {
  730.                    if (s) throw r
  731.                }
  732.            }
  733.            return i
  734.        }(t, e) || r(t, e) || function() {
  735.            throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")
  736.        }()
  737.    }
  738.  
  739.    function y(t) {
  740.        return function(t) {
  741.            if (Array.isArray(t)) return d(t)
  742.        }(t) || function(t) {
  743.            if ("undefined" != typeof Symbol && Symbol.iterator in Object(t)) return Array.from(t)
  744.        }(t) || r(t) || function() {
  745.            throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")
  746.        }()
  747.    }
  748.  
  749.    function r(t, e) {
  750.        if (t) {
  751.            if ("string" == typeof t) return d(t, e);
  752.            var i = Object.prototype.toString.call(t).slice(8, -1);
  753.            return "Object" === i && t.constructor && (i = t.constructor.name), "Map" === i || "Set" === i ? Array.from(t) : "Arguments" === i || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i) ? d(t, e) : void 0
  754.        }
  755.    }
  756.  
  757.    function d(t, e) {
  758.        (null == e || e > t.length) && (e = t.length);
  759.         for (var i = 0, n = new Array(e); i < e; i++) n[i] = t[i];
  760.        return n
  761.    }
  762.    var f = {
  763.            el: document,
  764.            name: "scroll",
  765.            offset: [0, 0],
  766.            repeat: !1,
  767.            smooth: !1,
  768.            direction: "vertical",
  769.            gestureDirection: "vertical",
  770.            reloadOnContextChange: !1,
  771.            lerp: .1,
  772.            class: "is-inview",
  773.            scrollbarContainer: !1,
  774.            scrollbarClass: "c-scrollbar",
  775.            scrollingClass: "has-scroll-scrolling",
  776.            draggingClass: "has-scroll-dragging",
  777.            smoothClass: "has-scroll-smooth",
  778.            initClass: "has-scroll-init",
  779.            getSpeed: !1,
  780.            getDirection: !1,
  781.            scrollFromAnywhere: !1,
  782.            multiplier: 1,
  783.            firefoxMultiplier: 50,
  784.            touchMultiplier: 2,
  785.            resetNativeScroll: !0,
  786.            tablet: {
  787.                smooth: !1,
  788.                direction: "vertical",
  789.                gestureDirection: "vertical",
  790.                breakpoint: 1024
  791.            },
  792.            smartphone: {
  793.                smooth: !1,
  794.                direction: "vertical",
  795.                gestureDirection: "vertical"
  796.            }
  797.        },
  798.        m = function() {
  799.            function e() {
  800.                var t = 0 < arguments.length && void 0 !== arguments[0] ? arguments[0] : {};
  801.                s(this, e), Object.assign(this, f, t), this.smartphone = f.smartphone, t.smartphone && Object.assign(this.smartphone, t.smartphone), this.tablet = f.tablet, t.tablet && Object.assign(this.tablet, t.tablet), this.namespace = "locomotive", this.html = document.documentElement, this.windowHeight = window.innerHeight, this.windowWidth = window.innerWidth, this.windowMiddle = {
  802.                    x: this.windowWidth / 2,
  803.                    y: this.windowHeight / 2
  804.                }, this.els = {}, this.currentElements = {}, this.listeners = {}, this.hasScrollTicking = !1, this.hasCallEventSet = !1, this.checkScroll = this.checkScroll.bind(this), this.checkResize = this.checkResize.bind(this), this.checkEvent = this.checkEvent.bind(this), this.instance = {
  805.                    scroll: {
  806.                        x: 0,
  807.                        y: 0
  808.                    },
  809.                    limit: {
  810.                        x: this.html.offsetHeight,
  811.                        y: this.html.offsetHeight
  812.                    },
  813.                    currentElements: this.currentElements
  814.                }, this.isMobile ? this.isTablet ? this.context = "tablet" : this.context = "smartphone" : this.context = "desktop", this.isMobile && (this.direction = this[this.context].direction), "horizontal" === this.direction ? this.directionAxis = "x" : this.directionAxis = "y", this.getDirection && (this.instance.direction = null), this.getDirection && (this.instance.speed = 0), this.html.classList.add(this.initClass), window.addEventListener("resize", this.checkResize, !1)
  815.            }
  816.            return t(e, [{
  817.                key: "init",
  818.                value: function() {
  819.                    this.initEvents()
  820.                }
  821.            }, {
  822.                key: "checkScroll",
  823.                value: function() {
  824.                    this.dispatchScroll()
  825.                }
  826.            }, {
  827.                key: "checkResize",
  828.                value: function() {
  829.                    var t = this;
  830.                    this.resizeTick || (this.resizeTick = !0, requestAnimationFrame(function() {
  831.                        t.resize(), t.resizeTick = !1
  832.                    }))
  833.                }
  834.            }, {
  835.                key: "resize",
  836.                value: function() {}
  837.            }, {
  838.                key: "checkContext",
  839.                value: function() {
  840.                    var t;
  841.                    this.reloadOnContextChange && (this.isMobile = /Android|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) || "MacIntel" === navigator.platform && 1 < navigator.maxTouchPoints || this.windowWidth < this.tablet.breakpoint, this.isTablet = this.isMobile && this.windowWidth >= this.tablet.breakpoint, t = this.context, this.isMobile ? this.isTablet ? this.context = "tablet" : this.context = "smartphone" : this.context = "desktop", t != this.context && ("desktop" == t ? this.smooth : this[t].smooth) != ("desktop" == this.context ? this.smooth : this[this.context].smooth) && window.location.reload())
  842.                }
  843.            }, {
  844.                key: "initEvents",
  845.                value: function() {
  846.                    var e = this;
  847.                     this.scrollToEls = this.el.querySelectorAll("[data-".concat(this.name, "-to]")), this.setScrollTo = this.setScrollTo.bind(this), this.scrollToEls.forEach(function(t) {
  848.                         t.addEventListener("click", e.setScrollTo, !1)
  849.                     })
  850.                 }
  851.             }, {
  852.                 key: "setScrollTo",
  853.                 value: function(t) {
  854.                     t.preventDefault(), this.scrollTo(t.currentTarget.getAttribute("data-".concat(this.name, "-href")) || t.currentTarget.getAttribute("href"), {
  855.                         offset: t.currentTarget.getAttribute("data-".concat(this.name, "-offset"))
  856.                     })
  857.                 }
  858.             }, {
  859.                 key: "addElements",
  860.                 value: function() {}
  861.             }, {
  862.                 key: "detectElements",
  863.                 value: function(o) {
  864.                     var a = this,
  865.                         l = this.instance.scroll.y,
  866.                         h = l + this.windowHeight,
  867.                         c = this.instance.scroll.x,
  868.                         u = c + this.windowWidth;
  869.                     Object.entries(this.els).forEach(function(t) {
  870.                         var e, i, n = D(t, 2),
  871.                             s = n[0],
  872.                             r = n[1];
  873.                         !r || r.inView && !o || ("horizontal" === a.direction ? u >= r.left && c < r.right && a.setInView(r, s) : h >= r.top && l < r.bottom && a.setInView(r, s)), r && r.inView && ("horizontal" === a.direction ? (e = r.right - r.left, r.progress = (a.instance.scroll.x - (r.left - a.windowWidth)) / (e + a.windowWidth), (u < r.left || c > r.right) && a.setOutOfView(r, s)) : (i = r.bottom - r.top, r.progress = (a.instance.scroll.y - (r.top - a.windowHeight)) / (i + a.windowHeight), (h < r.top || l > r.bottom) && a.setOutOfView(r, s)))
  874.                    }), this.hasScrollTicking = !1
  875.                }
  876.            }, {
  877.                key: "setInView",
  878.                value: function(t, e) {
  879.                    this.els[e].inView = !0, t.el.classList.add(t.class), (this.currentElements[e] = t).call && this.hasCallEventSet && (this.dispatchCall(t, "enter"), t.repeat || (this.els[e].call = !1))
  880.                }
  881.            }, {
  882.                key: "setOutOfView",
  883.                value: function(t, e) {
  884.                    var i = this;
  885.                     this.els[e].inView = !1, Object.keys(this.currentElements).forEach(function(t) {
  886.                         t === e && delete i.currentElements[t]
  887.                    }), t.call && this.hasCallEventSet && this.dispatchCall(t, "exit"), t.repeat && t.el.classList.remove(t.class)
  888.                }
  889.            }, {
  890.                key: "dispatchCall",
  891.                value: function(t, e) {
  892.                    this.callWay = e, this.callValue = t.call.split(",").map(function(t) {
  893.                        return t.trim()
  894.                    }), this.callObj = t, 1 == this.callValue.length && (this.callValue = this.callValue[0]);
  895.                     var i = new Event(this.namespace + "call");
  896.                     this.el.dispatchEvent(i)
  897.                 }
  898.             }, {
  899.                 key: "dispatchScroll",
  900.                 value: function() {
  901.                     var t = new Event(this.namespace + "scroll");
  902.                     this.el.dispatchEvent(t)
  903.                 }
  904.             }, {
  905.                 key: "setEvents",
  906.                 value: function(t, e) {
  907.                     this.listeners[t] || (this.listeners[t] = []);
  908.                     var i = this.listeners[t];
  909.                     i.push(e), 1 === i.length && this.el.addEventListener(this.namespace + t, this.checkEvent, !1), "call" === t && (this.hasCallEventSet = !0, this.detectElements(!0))
  910.                }
  911.            }, {
  912.                key: "unsetEvents",
  913.                value: function(t, e) {
  914.                    var i, n;
  915.                     this.listeners[t] && ((n = (i = this.listeners[t]).indexOf(e)) < 0 || (i.splice(n, 1), 0 === i.index && this.el.removeEventListener(this.namespace + t, this.checkEvent, !1)))
  916.                }
  917.            }, {
  918.                key: "checkEvent",
  919.                value: function(t) {
  920.                    var e = this,
  921.                        i = t.type.replace(this.namespace, ""),
  922.                        n = this.listeners[i];
  923.                     n && 0 !== n.length && n.forEach(function(t) {
  924.                        switch (i) {
  925.                            case "scroll":
  926.                                return t(e.instance);
  927.                             case "call":
  928.                                 return t(e.callValue, e.callWay, e.callObj);
  929.                             default:
  930.                                 return t()
  931.                         }
  932.                     })
  933.                 }
  934.             }, {
  935.                 key: "startScroll",
  936.                 value: function() {}
  937.             }, {
  938.                 key: "stopScroll",
  939.                 value: function() {}
  940.             }, {
  941.                 key: "setScroll",
  942.                 value: function() {
  943.                     this.instance.scroll = {
  944.                         x: 0,
  945.                         y: 0
  946.                     }
  947.                 }
  948.             }, {
  949.                 key: "destroy",
  950.                 value: function() {
  951.                     var e = this;
  952.                     window.removeEventListener("resize", this.checkResize, !1), Object.keys(this.listeners).forEach(function(t) {
  953.                         e.el.removeEventListener(e.namespace + t, e.checkEvent, !1)
  954.                     }), this.listeners = {}, this.scrollToEls.forEach(function(t) {
  955.                         t.removeEventListener("click", e.setScrollTo, !1)
  956.                     }), this.html.classList.remove(this.initClass)
  957.                 }
  958.             }]), e
  959.         }(),
  960.         p = "undefined" != typeof globalThis ? globalThis : "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof self ? self : {};
  961.  
  962.     function g(t, e) {
  963.         return t(e = {
  964.             exports: {}
  965.         }, e.exports), e.exports
  966.     }
  967.     var v = g(function(t, e) {
  968.             t.exports = {
  969.                 polyfill: function() {
  970.                     var t, o, l, h, i, e, c = window,
  971.                         u = document;
  972.  
  973.                     function d(t, e) {
  974.                         this.scrollLeft = t, this.scrollTop = e
  975.                     }
  976.  
  977.                     function n(t) {
  978.                         if (null === t || "object" != typeof t || void 0 === t.behavior || "auto" === t.behavior || "instant" === t.behavior) return !0;
  979.                         if ("object" == typeof t && "smooth" === t.behavior) return !1;
  980.                         throw new TypeError("behavior member of ScrollOptions " + t.behavior + " is not a valid value for enumeration ScrollBehavior.")
  981.                     }
  982.  
  983.                     function s(t, e) {
  984.                         return "Y" === e ? t.clientHeight + i < t.scrollHeight : "X" === e ? t.clientWidth + i < t.scrollWidth : void 0
  985.                    }
  986.  
  987.                    function r(t, e) {
  988.                        var i = c.getComputedStyle(t, null)["overflow" + e];
  989.                        return "auto" === i || "scroll" === i
  990.                    }
  991.  
  992.                    function a(t) {
  993.                        for (; t !== u.body && !1 === (0, i = s(e = t, "Y") && r(e, "Y"), n = s(e, "X") && r(e, "X"), i || n);) t = t.parentNode || t.host;
  994.                        var e, i, n;
  995.                        return t
  996.                    }
  997.  
  998.                    function f(t) {
  999.                        var e, i, n, s, r = (h() - t.startTime) / o;
  1000.                        s = r = 1 < r ? 1 : r, e = .5 * (1 - Math.cos(Math.PI * s)), i = t.startX + (t.x - t.startX) * e, n = t.startY + (t.y - t.startY) * e, t.method.call(t.scrollable, i, n), i === t.x && n === t.y || c.requestAnimationFrame(f.bind(c, t))
  1001.                    }
  1002.  
  1003.                    function m(t, e, i) {
  1004.                        var n, s, r, o = h(),
  1005.                            a = t === u.body ? (s = (n = c).scrollX || c.pageXOffset, r = c.scrollY || c.pageYOffset, l.scroll) : (s = (n = t).scrollLeft, r = t.scrollTop, d);
  1006.                        f({
  1007.                            scrollable: n,
  1008.                            method: a,
  1009.                            startTime: o,
  1010.                            startX: s,
  1011.                            startY: r,
  1012.                            x: e,
  1013.                            y: i
  1014.                        })
  1015.                    }
  1016.                    "scrollBehavior" in u.documentElement.style && !0 !== c.__forceSmoothScrollPolyfill__ || (t = c.HTMLElement || c.Element, o = 468, l = {
  1017.                        scroll: c.scroll || c.scrollTo,
  1018.                        scrollBy: c.scrollBy,
  1019.                        elementScroll: t.prototype.scroll || d,
  1020.                        scrollIntoView: t.prototype.scrollIntoView
  1021.                    }, h = c.performance && c.performance.now ? c.performance.now.bind(c.performance) : Date.now, e = c.navigator.userAgent, i = new RegExp(["MSIE ", "Trident/", "Edge/"].join("|")).test(e) ? 1 : 0, c.scroll = c.scrollTo = function() {
  1022.                        void 0 !== arguments[0] && (!0 !== n(arguments[0]) ? m.call(c, u.body, void 0 !== arguments[0].left ? ~~arguments[0].left : c.scrollX || c.pageXOffset, void 0 !== arguments[0].top ? ~~arguments[0].top : c.scrollY || c.pageYOffset) : l.scroll.call(c, void 0 !== arguments[0].left ? arguments[0].left : "object" != typeof arguments[0] ? arguments[0] : c.scrollX || c.pageXOffset, void 0 !== arguments[0].top ? arguments[0].top : void 0 !== arguments[1] ? arguments[1] : c.scrollY || c.pageYOffset))
  1023.                    }, c.scrollBy = function() {
  1024.                        void 0 !== arguments[0] && (n(arguments[0]) ? l.scrollBy.call(c, void 0 !== arguments[0].left ? arguments[0].left : "object" != typeof arguments[0] ? arguments[0] : 0, void 0 !== arguments[0].top ? arguments[0].top : void 0 !== arguments[1] ? arguments[1] : 0) : m.call(c, u.body, ~~arguments[0].left + (c.scrollX || c.pageXOffset), ~~arguments[0].top + (c.scrollY || c.pageYOffset)))
  1025.                    }, t.prototype.scroll = t.prototype.scrollTo = function() {
  1026.                        if (void 0 !== arguments[0])
  1027.                            if (!0 !== n(arguments[0])) {
  1028.                                var t = arguments[0].left,
  1029.                                    e = arguments[0].top;
  1030.                                m.call(this, this, void 0 === t ? this.scrollLeft : ~~t, void 0 === e ? this.scrollTop : ~~e)
  1031.                            } else {
  1032.                                if ("number" == typeof arguments[0] && void 0 === arguments[1]) throw new SyntaxError("Value could not be converted");
  1033.                                l.elementScroll.call(this, void 0 !== arguments[0].left ? ~~arguments[0].left : "object" != typeof arguments[0] ? ~~arguments[0] : this.scrollLeft, void 0 !== arguments[0].top ? ~~arguments[0].top : void 0 !== arguments[1] ? ~~arguments[1] : this.scrollTop)
  1034.                            }
  1035.                    }, t.prototype.scrollBy = function() {
  1036.                        void 0 !== arguments[0] && (!0 !== n(arguments[0]) ? this.scroll({
  1037.                            left: ~~arguments[0].left + this.scrollLeft,
  1038.                            top: ~~arguments[0].top + this.scrollTop,
  1039.                            behavior: arguments[0].behavior
  1040.                        }) : l.elementScroll.call(this, void 0 !== arguments[0].left ? ~~arguments[0].left + this.scrollLeft : ~~arguments[0] + this.scrollLeft, void 0 !== arguments[0].top ? ~~arguments[0].top + this.scrollTop : ~~arguments[1] + this.scrollTop))
  1041.                    }, t.prototype.scrollIntoView = function() {
  1042.                        var t, e, i;
  1043.                        !0 !== n(arguments[0]) ? (e = (t = a(this)).getBoundingClientRect(), i = this.getBoundingClientRect(), t !== u.body ? (m.call(this, t, t.scrollLeft + i.left - e.left, t.scrollTop + i.top - e.top), "fixed" !== c.getComputedStyle(t).position && c.scrollBy({
  1044.                            left: e.left,
  1045.                            top: e.top,
  1046.                            behavior: "smooth"
  1047.                        })) : c.scrollBy({
  1048.                            left: i.left,
  1049.                            top: i.top,
  1050.                            behavior: "smooth"
  1051.                        })) : l.scrollIntoView.call(this, void 0 === arguments[0] || arguments[0])
  1052.                    })
  1053.                }
  1054.            }
  1055.        }),
  1056.        b = (v.polyfill, function() {
  1057.            a(n, m);
  1058.            var i = c(n);
  1059.  
  1060.            function n() {
  1061.                var t, e = 0 < arguments.length && void 0 !== arguments[0] ? arguments[0] : {};
  1062.                return s(this, n), (t = i.call(this, e)).resetNativeScroll && (history.scrollRestoration && (history.scrollRestoration = "manual"), window.scrollTo(0, 0)), window.addEventListener("scroll", t.checkScroll, !1), void 0 === window.smoothscrollPolyfill && (window.smoothscrollPolyfill = v, window.smoothscrollPolyfill.polyfill()), t
  1063.            }
  1064.            return t(n, [{
  1065.                key: "init",
  1066.                value: function() {
  1067.                    this.instance.scroll.y = window.pageYOffset, this.addElements(), this.detectElements(), u(l(n.prototype), "init", this).call(this)
  1068.                }
  1069.            }, {
  1070.                key: "checkScroll",
  1071.                value: function() {
  1072.                    var t = this;
  1073.                    u(l(n.prototype), "checkScroll", this).call(this), this.getDirection && this.addDirection(), this.getSpeed && (this.addSpeed(), this.speedTs = Date.now()), this.instance.scroll.y = window.pageYOffset, Object.entries(this.els).length && (this.hasScrollTicking || (requestAnimationFrame(function() {
  1074.                        t.detectElements()
  1075.                    }), this.hasScrollTicking = !0))
  1076.                }
  1077.            }, {
  1078.                key: "addDirection",
  1079.                value: function() {
  1080.                    window.pageYOffset > this.instance.scroll.y ? "down" !== this.instance.direction && (this.instance.direction = "down") : window.pageYOffset < this.instance.scroll.y && "up" !== this.instance.direction && (this.instance.direction = "up")
  1081.                }
  1082.            }, {
  1083.                key: "addSpeed",
  1084.                value: function() {
  1085.                    window.pageYOffset != this.instance.scroll.y ? this.instance.speed = (window.pageYOffset - this.instance.scroll.y) / Math.max(1, Date.now() - this.speedTs) : this.instance.speed = 0
  1086.                }
  1087.            }, {
  1088.                key: "resize",
  1089.                value: function() {
  1090.                    Object.entries(this.els).length && (this.windowHeight = window.innerHeight, this.updateElements())
  1091.                }
  1092.            }, {
  1093.                key: "addElements",
  1094.                value: function() {
  1095.                    var m = this;
  1096.                     this.els = {}, this.el.querySelectorAll("[data-" + this.name + "]").forEach(function(t, e) {
  1097.                         var i = t.getBoundingClientRect(),
  1098.                             n = t.dataset[m.name + "Class"] || m.class,
  1099.                             s = "string" == typeof t.dataset[m.name + "Id"] ? t.dataset[m.name + "Id"] : e,
  1100.                             r = i.top + m.instance.scroll.y,
  1101.                             o = i.left,
  1102.                             a = i.right,
  1103.                             l = r + t.offsetHeight,
  1104.                             h = "string" == typeof t.dataset[m.name + "Offset"] ? t.dataset[m.name + "Offset"].split(",") : m.offset,
  1105.                             c = t.dataset[m.name + "Repeat"],
  1106.                             u = t.dataset[m.name + "Call"],
  1107.                             c = "false" != c && (null != c || m.repeat),
  1108.                            d = m.getRelativeOffset(h),
  1109.                            f = {
  1110.                                el: t,
  1111.                                id: s,
  1112.                                class: n,
  1113.                                top: r + d[0],
  1114.                                bottom: l - d[1],
  1115.                                left: o,
  1116.                                right: a,
  1117.                                offset: h,
  1118.                                progress: 0,
  1119.                                repeat: c,
  1120.                                inView: !1,
  1121.                                call: u
  1122.                            };
  1123.                         m.els[s] = f, t.classList.contains(n) && m.setInView(m.els[s], s)
  1124.                    })
  1125.                }
  1126.            }, {
  1127.                key: "updateElements",
  1128.                value: function() {
  1129.                    var a = this;
  1130.                     Object.entries(this.els).forEach(function(t) {
  1131.                         var e = D(t, 2),
  1132.                             i = e[0],
  1133.                             n = e[1],
  1134.                             s = n.el.getBoundingClientRect().top + a.instance.scroll.y,
  1135.                             r = s + n.el.offsetHeight,
  1136.                             o = a.getRelativeOffset(n.offset);
  1137.                         a.els[i].top = s + o[0], a.els[i].bottom = r - o[1]
  1138.                     }), this.hasScrollTicking = !1
  1139.                 }
  1140.             }, {
  1141.                 key: "getRelativeOffset",
  1142.                 value: function(t) {
  1143.                     var e = [0, 0];
  1144.                     if (t)
  1145.                         for (var i = 0; i < t.length; i++) "string" == typeof t[i] ? t[i].includes("%") ? e[i] = parseInt(t[i].replace("%", "") * this.windowHeight / 100) : e[i] = parseInt(t[i]) : e[i] = t[i];
  1146.                    return e
  1147.                }
  1148.            }, {
  1149.                key: "scrollTo",
  1150.                value: function(t, e) {
  1151.                    var i = 1 < arguments.length && void 0 !== e ? e : {},
  1152.                        n = parseInt(i.offset) || 0,
  1153.                        s = !!i.callback && i.callback;
  1154.                    if ("string" == typeof t) {
  1155.                        if ("top" === t) t = this.html;
  1156.                        else if ("bottom" === t) t = this.html.offsetHeight - window.innerHeight;
  1157.                        else if (!(t = document.querySelector(t))) return
  1158.                    } else if ("number" == typeof t) t = parseInt(t);
  1159.                    else if (!t || !t.tagName) return void console.warn("`target` parameter is not valid");
  1160.                    n = "number" != typeof t ? t.getBoundingClientRect().top + n + this.instance.scroll.y : t + n, s && (n = n.toFixed(), window.addEventListener("scroll", function t() {
  1161.                        window.pageYOffset.toFixed() === n && (window.removeEventListener("scroll", t), s())
  1162.                    })), window.scrollTo({
  1163.                        top: n,
  1164.                        behavior: "smooth"
  1165.                    })
  1166.                }
  1167.            }, {
  1168.                key: "update",
  1169.                value: function() {
  1170.                    this.addElements(), this.detectElements()
  1171.                }
  1172.            }, {
  1173.                key: "destroy",
  1174.                value: function() {
  1175.                    u(l(n.prototype), "destroy", this).call(this), window.removeEventListener("scroll", this.checkScroll, !1)
  1176.                }
  1177.            }]), n
  1178.        }()),
  1179.        w = Object.getOwnPropertySymbols,
  1180.        E = Object.prototype.hasOwnProperty,
  1181.        T = Object.prototype.propertyIsEnumerable;
  1182.    var x = function() {
  1183.        try {
  1184.            if (!Object.assign) return;
  1185.            var t = new String("abc");
  1186.            if (t[5] = "de", "5" === Object.getOwnPropertyNames(t)[0]) return;
  1187.            for (var e = {}, i = 0; i < 10; i++) e["_" + String.fromCharCode(i)] = i;
  1188.            if ("0123456789" !== Object.getOwnPropertyNames(e).map(function(t) {
  1189.                    return e[t]
  1190.                }).join("")) return;
  1191.            var n = {};
  1192.            return "abcdefghijklmnopqrst".split("").forEach(function(t) {
  1193.                n[t] = t
  1194.            }), "abcdefghijklmnopqrst" !== Object.keys(Object.assign({}, n)).join("") ? void 0 : 1
  1195.        } catch (t) {
  1196.            return
  1197.        }
  1198.    }() ? Object.assign : function(t, e) {
  1199.        for (var i, n, s = function(t) {
  1200.                if (null == t) throw new TypeError("Object.assign cannot be called with null or undefined");
  1201.                return Object(t)
  1202.            }(t), r = 1; r < arguments.length; r++) {
  1203.            for (var o in i = Object(arguments[r])) E.call(i, o) && (s[o] = i[o]);
  1204.            if (w) {
  1205.                n = w(i);
  1206.                for (var a = 0; a < n.length; a++) T.call(i, n[a]) && (s[n[a]] = i[n[a]])
  1207.            }
  1208.        }
  1209.        return s
  1210.    };
  1211.  
  1212.    function S() {}
  1213.    S.prototype = {
  1214.        on: function(t, e, i) {
  1215.            var n = this.e || (this.e = {});
  1216.            return (n[t] || (n[t] = [])).push({
  1217.                fn: e,
  1218.                ctx: i
  1219.            }), this
  1220.        },
  1221.        once: function(t, e, i) {
  1222.            var n = this;
  1223.  
  1224.            function s() {
  1225.                n.off(t, s), e.apply(i, arguments)
  1226.            }
  1227.            return s._ = e, this.on(t, s, i)
  1228.        },
  1229.        emit: function(t) {
  1230.            for (var e = [].slice.call(arguments, 1), i = ((this.e || (this.e = {}))[t] || []).slice(), n = 0, s = i.length; n < s; n++) i[n].fn.apply(i[n].ctx, e);
  1231.            return this
  1232.        },
  1233.        off: function(t, e) {
  1234.            var i = this.e || (this.e = {}),
  1235.                n = i[t],
  1236.                s = [];
  1237.            if (n && e)
  1238.                for (var r = 0, o = n.length; r < o; r++) n[r].fn !== e && n[r].fn._ !== e && s.push(n[r]);
  1239.            return s.length ? i[t] = s : delete i[t], this
  1240.        }
  1241.    };
  1242.  
  1243.    function A(t) {
  1244.        if (!t) return console.warn("bindAll requires at least one argument.");
  1245.        var e = Array.prototype.slice.call(arguments, 1);
  1246.        if (0 === e.length)
  1247.            for (var i in t) O.call(t, i) && "function" == typeof t[i] && "[object Function]" == L.call(t[i]) && e.push(i);
  1248.        for (var n = 0; n < e.length; n++) {
  1249.            var s = e[n];
  1250.            t[s] = function(t, e) {
  1251.                return function() {
  1252.                    return t.apply(e, arguments)
  1253.                }
  1254.            }(t[s], t)
  1255.        }
  1256.    }
  1257.    var R = S,
  1258.        _ = g(function(t, e) {
  1259.            (function() {
  1260.                function t(t, e, i, n) {
  1261.                    this.stability = null != t ? Math.abs(t) : 8, this.sensitivity = null != e ? 1 + Math.abs(e) : 100, this.tolerance = null != i ? 1 + Math.abs(i) : 1.1, this.delay = null != n ? n : 150, this.lastUpDeltas = function() {
  1262.                        for (var t = [], e = 1, i = 2 * this.stability; 1 <= i ? e <= i : i <= e; 1 <= i ? e++ : e--) t.push(null);
  1263.                        return t
  1264.                    }.call(this), this.lastDownDeltas = function() {
  1265.                        for (var t = [], e = 1, i = 2 * this.stability; 1 <= i ? e <= i : i <= e; 1 <= i ? e++ : e--) t.push(null);
  1266.                        return t
  1267.                    }.call(this), this.deltasTimestamp = function() {
  1268.                        for (var t = [], e = 1, i = 2 * this.stability; 1 <= i ? e <= i : i <= e; 1 <= i ? e++ : e--) t.push(null);
  1269.                        return t
  1270.                    }.call(this)
  1271.                }(null !== e ? e : this).Lethargy = (t.prototype.check = function(t) {
  1272.                    var e;
  1273.                    return null != (t = t.originalEvent || t).wheelDelta ? e = t.wheelDelta : null != t.deltaY ? e = -40 * t.deltaY : null == t.detail && 0 !== t.detail || (e = -40 * t.detail), this.deltasTimestamp.push(Date.now()), this.deltasTimestamp.shift(), 0 < e ? (this.lastUpDeltas.push(e), this.lastUpDeltas.shift(), this.isInertia(1)) : (this.lastDownDeltas.push(e), this.lastDownDeltas.shift(), this.isInertia(-1))
  1274.                }, t.prototype.isInertia = function(t) {
  1275.                    var e, i, n, s, r, o, a = -1 === t ? this.lastDownDeltas : this.lastUpDeltas;
  1276.                    return null === a[0] ? t : !(this.deltasTimestamp[2 * this.stability - 2] + this.delay > Date.now() && a[0] === a[2 * this.stability - 1]) && (i = a.slice(0, this.stability), e = a.slice(this.stability, 2 * this.stability), o = i.reduce(function(t, e) {
  1277.                        return t + e
  1278.                    }), s = e.reduce(function(t, e) {
  1279.                        return t + e
  1280.                    }), r = o / i.length, n = s / e.length, Math.abs(r) < Math.abs(n * this.tolerance) && this.sensitivity < Math.abs(n) && t)
  1281.                }, t.prototype.showLastUpDeltas = function() {
  1282.                    return this.lastUpDeltas
  1283.                }, t.prototype.showLastDownDeltas = function() {
  1284.                    return this.lastDownDeltas
  1285.                }, t)
  1286.            }).call(p)
  1287.        }),
  1288.        k = {
  1289.            hasWheelEvent: "onwheel" in document,
  1290.            hasMouseWheelEvent: "onmousewheel" in document,
  1291.            hasTouch: "ontouchstart" in window || window.TouchEvent || window.DocumentTouch && document instanceof DocumentTouch,
  1292.            hasTouchWin: navigator.msMaxTouchPoints && 1 < navigator.msMaxTouchPoints,
  1293.            hasPointer: !!window.navigator.msPointerEnabled,
  1294.            hasKeyDown: "onkeydown" in document,
  1295.            isFirefox: -1 < navigator.userAgent.indexOf("Firefox")
  1296.        },
  1297.        L = Object.prototype.toString,
  1298.        O = Object.prototype.hasOwnProperty;
  1299.     var M = _.Lethargy,
  1300.         P = "virtualscroll",
  1301.         C = H,
  1302.         X = 37,
  1303.         U = 38,
  1304.         B = 39,
  1305.         F = 40,
  1306.         I = 32;
  1307.  
  1308.     function H(t) {
  1309.         A(this, "_onWheel", "_onMouseWheel", "_onTouchStart", "_onTouchMove", "_onKeyDown"), this.el = window, t && t.el && (this.el = t.el, delete t.el), this.options = x({
  1310.            mouseMultiplier: 1,
  1311.            touchMultiplier: 2,
  1312.            firefoxMultiplier: 15,
  1313.            keyStep: 120,
  1314.            preventTouch: !1,
  1315.            unpreventTouchClass: "vs-touchmove-allowed",
  1316.            limitInertia: !1,
  1317.            useKeyboard: !0,
  1318.            useTouch: !0
  1319.        }, t), this.options.limitInertia && (this._lethargy = new M), this._emitter = new R, this._event = {
  1320.            y: 0,
  1321.            x: 0,
  1322.            deltaX: 0,
  1323.            deltaY: 0
  1324.        }, this.touchStartX = null, this.touchStartY = null, this.bodyTouchAction = null, void 0 !== this.options.passive && (this.listenerOptions = {
  1325.            passive: this.options.passive
  1326.        })
  1327.    }
  1328.  
  1329.    function j(t, e, i) {
  1330.        return (1 - i) * t + i * e
  1331.    }
  1332.  
  1333.    function W(t) {
  1334.        var e = {};
  1335.         if (window.getComputedStyle) {
  1336.             var i = getComputedStyle(t),
  1337.                 n = i.transform || i.webkitTransform || i.mozTransform,
  1338.                 s = n.match(/^matrix3d\((.+)\)$/);
  1339.             return s ? (e.x = s ? parseFloat(s[1].split(", ")[12]) : 0, e.y = s ? parseFloat(s[1].split(", ")[13]) : 0) : (s = n.match(/^matrix\((.+)\)$/), e.x = s ? parseFloat(s[1].split(", ")[4]) : 0, e.y = s ? parseFloat(s[1].split(", ")[5]) : 0), e
  1340.         }
  1341.     }
  1342.  
  1343.     function Y(t) {
  1344.         for (var e = []; t && t !== document; t = t.parentNode) e.push(t);
  1345.         return e
  1346.     }
  1347.     H.prototype._notify = function(t) {
  1348.         var e = this._event;
  1349.         e.x += e.deltaX, e.y += e.deltaY, this._emitter.emit(P, {
  1350.             x: e.x,
  1351.             y: e.y,
  1352.             deltaX: e.deltaX,
  1353.             deltaY: e.deltaY,
  1354.             originalEvent: t
  1355.         })
  1356.     }, H.prototype._onWheel = function(t) {
  1357.         var e, i = this.options;
  1358.         this._lethargy && !1 === this._lethargy.check(t) || ((e = this._event).deltaX = t.wheelDeltaX || -1 * t.deltaX, e.deltaY = t.wheelDeltaY || -1 * t.deltaY, k.isFirefox && 1 == t.deltaMode && (e.deltaX *= i.firefoxMultiplier, e.deltaY *= i.firefoxMultiplier), e.deltaX *= i.mouseMultiplier, e.deltaY *= i.mouseMultiplier, this._notify(t))
  1359.    }, H.prototype._onMouseWheel = function(t) {
  1360.        var e;
  1361.         this.options.limitInertia && !1 === this._lethargy.check(t) || ((e = this._event).deltaX = t.wheelDeltaX ? t.wheelDeltaX : 0, e.deltaY = t.wheelDeltaY ? t.wheelDeltaY : t.wheelDelta, this._notify(t))
  1362.    }, H.prototype._onTouchStart = function(t) {
  1363.        var e = t.targetTouches ? t.targetTouches[0] : t;
  1364.         this.touchStartX = e.pageX, this.touchStartY = e.pageY
  1365.     }, H.prototype._onTouchMove = function(t) {
  1366.         var e = this.options;
  1367.         e.preventTouch && !t.target.classList.contains(e.unpreventTouchClass) && t.preventDefault();
  1368.         var i = this._event,
  1369.             n = t.targetTouches ? t.targetTouches[0] : t;
  1370.         i.deltaX = (n.pageX - this.touchStartX) * e.touchMultiplier, i.deltaY = (n.pageY - this.touchStartY) * e.touchMultiplier, this.touchStartX = n.pageX, this.touchStartY = n.pageY, this._notify(t)
  1371.     }, H.prototype._onKeyDown = function(t) {
  1372.         var e = this._event;
  1373.         e.deltaX = e.deltaY = 0;
  1374.         var i = window.innerHeight - 40;
  1375.         switch (t.keyCode) {
  1376.             case X:
  1377.             case U:
  1378.                 e.deltaY = this.options.keyStep;
  1379.                 break;
  1380.             case B:
  1381.             case F:
  1382.                 e.deltaY = -this.options.keyStep;
  1383.                 break;
  1384.             case t.shiftKey:
  1385.                 e.deltaY = i;
  1386.                 break;
  1387.             case I:
  1388.                 e.deltaY = -i;
  1389.                 break;
  1390.             default:
  1391.                 return
  1392.         }
  1393.         this._notify(t)
  1394.     }, H.prototype._bind = function() {
  1395.         k.hasWheelEvent && this.el.addEventListener("wheel", this._onWheel, this.listenerOptions), k.hasMouseWheelEvent && this.el.addEventListener("mousewheel", this._onMouseWheel, this.listenerOptions), k.hasTouch && this.options.useTouch && (this.el.addEventListener("touchstart", this._onTouchStart, this.listenerOptions), this.el.addEventListener("touchmove", this._onTouchMove, this.listenerOptions)), k.hasPointer && k.hasTouchWin && (this.bodyTouchAction = document.body.style.msTouchAction, document.body.style.msTouchAction = "none", this.el.addEventListener("MSPointerDown", this._onTouchStart, !0), this.el.addEventListener("MSPointerMove", this._onTouchMove, !0)), k.hasKeyDown && this.options.useKeyboard && document.addEventListener("keydown", this._onKeyDown)
  1396.    }, H.prototype._unbind = function() {
  1397.        k.hasWheelEvent && this.el.removeEventListener("wheel", this._onWheel), k.hasMouseWheelEvent && this.el.removeEventListener("mousewheel", this._onMouseWheel), k.hasTouch && (this.el.removeEventListener("touchstart", this._onTouchStart), this.el.removeEventListener("touchmove", this._onTouchMove)), k.hasPointer && k.hasTouchWin && (document.body.style.msTouchAction = this.bodyTouchAction, this.el.removeEventListener("MSPointerDown", this._onTouchStart, !0), this.el.removeEventListener("MSPointerMove", this._onTouchMove, !0)), k.hasKeyDown && this.options.useKeyboard && document.removeEventListener("keydown", this._onKeyDown)
  1398.    }, H.prototype.on = function(t, e) {
  1399.        this._emitter.on(P, t, e);
  1400.         var i = this._emitter.e;
  1401.         i && i[P] && 1 === i[P].length && this._bind()
  1402.    }, H.prototype.off = function(t, e) {
  1403.        this._emitter.off(P, t, e);
  1404.         var i = this._emitter.e;
  1405.         (!i[P] || i[P].length <= 0) && this._unbind()
  1406.    }, H.prototype.reset = function() {
  1407.        var t = this._event;
  1408.        t.x = 0, t.y = 0
  1409.    }, H.prototype.destroy = function() {
  1410.        this._emitter.off(), this._unbind()
  1411.    };
  1412.    var N = 4,
  1413.        z = 1e-7,
  1414.        V = 10,
  1415.        G = "function" == typeof Float32Array;
  1416.  
  1417.    function q(t, e) {
  1418.        return 1 - 3 * e + 3 * t
  1419.    }
  1420.  
  1421.    function K(t, e) {
  1422.        return 3 * e - 6 * t
  1423.    }
  1424.  
  1425.    function Q(t, e, i) {
  1426.        return ((q(e, i) * t + K(e, i)) * t + 3 * e) * t
  1427.    }
  1428.  
  1429.    function $(t, e, i) {
  1430.        return 3 * q(e, i) * t * t + 2 * K(e, i) * t + 3 * e
  1431.    }
  1432.  
  1433.    function J(t) {
  1434.        return t
  1435.    }
  1436.  
  1437.    function Z(r, e, o, i) {
  1438.        if (!(0 <= r && r <= 1 && 0 <= o && o <= 1)) throw new Error("bezier x values must be in [0, 1] range");
  1439.        if (r === e && o === i) return J;
  1440.        for (var a = new(G ? Float32Array : Array)(11), t = 0; t < 11; ++t) a[t] = Q(.1 * t, r, o);
  1441.  
  1442.        function n(t) {
  1443.            for (var e = 0, i = 1; 10 !== i && a[i] <= t; ++i) e += .1;
  1444.            var n = e + .1 * ((t - a[--i]) / (a[i + 1] - a[i])),
  1445.                s = $(n, r, o);
  1446.            return .001 <= s ? function(t, e, i, n) {
  1447.                for (var s = 0; s < N; ++s) {
  1448.                    var r = $(e, i, n);
  1449.                    if (0 === r) return e;
  1450.                    e -= (Q(e, i, n) - t) / r
  1451.                }
  1452.                return e
  1453.            }(t, n, r, o) : 0 === s ? n : function(t, e, i, n, s) {
  1454.                for (var r, o, a = 0; 0 < (r = Q(o = e + (i - e) / 2, n, s) - t) ? i = o : e = o, Math.abs(r) > z && ++a < V;);
  1455.                 return o
  1456.             }(t, e, e + .1, r, o)
  1457.         }
  1458.         return function(t) {
  1459.             return 0 === t ? 0 : 1 === t ? 1 : Q(n(t), e, i)
  1460.         }
  1461.     }
  1462.     var tt = 38,
  1463.         et = 40,
  1464.         it = 32,
  1465.         nt = 9,
  1466.         st = 33,
  1467.         rt = 34,
  1468.         ot = 36,
  1469.         at = 35,
  1470.         lt = function() {
  1471.             a(r, m);
  1472.             var i = c(r);
  1473.  
  1474.             function r() {
  1475.                 var t, e = 0 < arguments.length && void 0 !== arguments[0] ? arguments[0] : {};
  1476.                return s(this, r), history.scrollRestoration && (history.scrollRestoration = "manual"), window.scrollTo(0, 0), (t = i.call(this, e)).inertia && (t.lerp = .1 * t.inertia), t.isScrolling = !1, t.isDraggingScrollbar = !1, t.isTicking = !1, t.hasScrollTicking = !1, t.parallaxElements = {}, t.stop = !1, t.scrollbarContainer = e.scrollbarContainer, t.checkKey = t.checkKey.bind(h(t)), window.addEventListener("keydown", t.checkKey, !1), t
  1477.            }
  1478.            return t(r, [{
  1479.                key: "init",
  1480.                value: function() {
  1481.                    var e = this;
  1482.                    this.html.classList.add(this.smoothClass), this.html.setAttribute("data-".concat(this.name, "-direction"), this.direction), this.instance = o({
  1483.                        delta: {
  1484.                            x: 0,
  1485.                            y: 0
  1486.                        }
  1487.                    }, this.instance), this.vs = new C({
  1488.                        el: this.scrollFromAnywhere ? document : this.el,
  1489.                        mouseMultiplier: -1 < navigator.platform.indexOf("Win") ? 1 : .4,
  1490.                        firefoxMultiplier: this.firefoxMultiplier,
  1491.                        touchMultiplier: this.touchMultiplier,
  1492.                        useKeyboard: !1,
  1493.                        passive: !0
  1494.                    }), this.vs.on(function(t) {
  1495.                        e.stop || e.isDraggingScrollbar || requestAnimationFrame(function() {
  1496.                            e.updateDelta(t), e.isScrolling || e.startScrolling()
  1497.                        })
  1498.                    }), this.setScrollLimit(), this.initScrollBar(), this.addSections(), this.addElements(), this.checkScroll(!0), this.transformElements(!0, !0), u(l(r.prototype), "init", this).call(this)
  1499.                }
  1500.            }, {
  1501.                key: "setScrollLimit",
  1502.                value: function() {
  1503.                    if (this.instance.limit.y = this.el.offsetHeight - this.windowHeight, "horizontal" === this.direction) {
  1504.                        for (var t = 0, e = this.el.children, i = 0; i < e.length; i++) t += e[i].offsetWidth;
  1505.                        this.instance.limit.x = t - this.windowWidth
  1506.                    }
  1507.                }
  1508.            }, {
  1509.                key: "startScrolling",
  1510.                value: function() {
  1511.                    this.startScrollTs = Date.now(), this.isScrolling = !0, this.checkScroll(), this.html.classList.add(this.scrollingClass)
  1512.                }
  1513.            }, {
  1514.                key: "stopScrolling",
  1515.                value: function() {
  1516.                    cancelAnimationFrame(this.checkScrollRaf), this.scrollToRaf && (cancelAnimationFrame(this.scrollToRaf), this.scrollToRaf = null), this.isScrolling = !1, this.instance.scroll.y = Math.round(this.instance.scroll.y), this.html.classList.remove(this.scrollingClass)
  1517.                }
  1518.            }, {
  1519.                key: "checkKey",
  1520.                value: function(t) {
  1521.                    var e = this;
  1522.                    if (this.stop) t.keyCode == nt && requestAnimationFrame(function() {
  1523.                        e.html.scrollTop = 0, document.body.scrollTop = 0, e.html.scrollLeft = 0, document.body.scrollLeft = 0
  1524.                    });
  1525.                    else {
  1526.                        switch (t.keyCode) {
  1527.                            case nt:
  1528.                                requestAnimationFrame(function() {
  1529.                                    e.html.scrollTop = 0, document.body.scrollTop = 0, e.html.scrollLeft = 0, document.body.scrollLeft = 0, e.scrollTo(document.activeElement, -window.innerHeight / 2)
  1530.                                });
  1531.                                break;
  1532.                            case tt:
  1533.                                this.instance.delta[this.directionAxis] -= 240;
  1534.                                break;
  1535.                            case et:
  1536.                                this.instance.delta[this.directionAxis] += 240;
  1537.                                break;
  1538.                            case st:
  1539.                                this.instance.delta[this.directionAxis] -= window.innerHeight;
  1540.                                break;
  1541.                            case rt:
  1542.                                this.instance.delta[this.directionAxis] += window.innerHeight;
  1543.                                break;
  1544.                            case ot:
  1545.                                this.instance.delta[this.directionAxis] -= this.instance.limit[this.directionAxis];
  1546.                                break;
  1547.                            case at:
  1548.                                this.instance.delta[this.directionAxis] += this.instance.limit[this.directionAxis];
  1549.                                break;
  1550.                            case it:
  1551.                                document.activeElement instanceof HTMLInputElement || document.activeElement instanceof HTMLTextAreaElement || (t.shiftKey ? this.instance.delta[this.directionAxis] -= window.innerHeight : this.instance.delta[this.directionAxis] += window.innerHeight);
  1552.                                break;
  1553.                            default:
  1554.                                return
  1555.                        }
  1556.                        this.instance.delta[this.directionAxis] < 0 && (this.instance.delta[this.directionAxis] = 0), this.instance.delta[this.directionAxis] > this.instance.limit[this.directionAxis] && (this.instance.delta[this.directionAxis] = this.instance.limit[this.directionAxis]), this.stopScrolling(), this.isScrolling = !0, this.checkScroll(), this.html.classList.add(this.scrollingClass)
  1557.                    }
  1558.                }
  1559.            }, {
  1560.                key: "checkScroll",
  1561.                value: function(t) {
  1562.                    var e, i, n, s = this;
  1563.                     (0 < arguments.length && void 0 !== t && t || this.isScrolling || this.isDraggingScrollbar) && (this.hasScrollTicking || (this.checkScrollRaf = requestAnimationFrame(function() {
  1564.                        return s.checkScroll()
  1565.                    }), this.hasScrollTicking = !0), this.updateScroll(), e = Math.abs(this.instance.delta[this.directionAxis] - this.instance.scroll[this.directionAxis]), i = Date.now() - this.startScrollTs, !this.animatingScroll && 100 < i && (e < .5 && 0 != this.instance.delta[this.directionAxis] || e < .5 && 0 == this.instance.delta[this.directionAxis]) && this.stopScrolling(), Object.entries(this.sections).forEach(function(t) {
  1566.                        var e = D(t, 2),
  1567.                            i = (e[0], e[1]);
  1568.                        i.persistent || s.instance.scroll[s.directionAxis] > i.offset[s.directionAxis] && s.instance.scroll[s.directionAxis] < i.limit[s.directionAxis] ? ("horizontal" === s.direction ? s.transform(i.el, -s.instance.scroll[s.directionAxis], 0) : s.transform(i.el, 0, -s.instance.scroll[s.directionAxis]), i.inView || (i.inView = !0, i.el.style.opacity = 1, i.el.style.pointerEvents = "all", i.el.setAttribute("data-".concat(s.name, "-section-inview"), ""))) : (i.inView && (i.inView = !1, i.el.style.opacity = 0, i.el.style.pointerEvents = "none", i.el.removeAttribute("data-".concat(s.name, "-section-inview"))), s.transform(i.el, 0, 0))
  1569.                    }), this.getDirection && this.addDirection(), this.getSpeed && (this.addSpeed(), this.speedTs = Date.now()), this.detectElements(), this.transformElements(), this.hasScrollbar && (n = this.instance.scroll[this.directionAxis] / this.instance.limit[this.directionAxis] * this.scrollBarLimit[this.directionAxis], "horizontal" === this.direction ? this.transform(this.scrollbarThumb, n, 0) : this.transform(this.scrollbarThumb, 0, n)), u(l(r.prototype), "checkScroll", this).call(this), this.hasScrollTicking = !1)
  1570.                }
  1571.            }, {
  1572.                key: "resize",
  1573.                value: function() {
  1574.                    this.windowHeight = window.innerHeight, this.windowWidth = window.innerWidth, this.checkContext(), this.windowMiddle = {
  1575.                        x: this.windowWidth / 2,
  1576.                        y: this.windowHeight / 2
  1577.                    }, this.update()
  1578.                }
  1579.            }, {
  1580.                key: "updateDelta",
  1581.                value: function(t) {
  1582.                    var e = this[this.context] && this[this.context].gestureDirection ? this[this.context].gestureDirection : this.gestureDirection,
  1583.                        i = "both" === e ? t.deltaX + t.deltaY : "vertical" !== e && "horizontal" === e ? t.deltaX : t.deltaY;
  1584.                     this.instance.delta[this.directionAxis] -= i * this.multiplier, this.instance.delta[this.directionAxis] < 0 && (this.instance.delta[this.directionAxis] = 0), this.instance.delta[this.directionAxis] > this.instance.limit[this.directionAxis] && (this.instance.delta[this.directionAxis] = this.instance.limit[this.directionAxis])
  1585.                }
  1586.            }, {
  1587.                key: "updateScroll",
  1588.                value: function() {
  1589.                    this.isScrolling || this.isDraggingScrollbar ? this.instance.scroll[this.directionAxis] = j(this.instance.scroll[this.directionAxis], this.instance.delta[this.directionAxis], this.lerp) : this.instance.scroll[this.directionAxis] > this.instance.limit[this.directionAxis] ? this.setScroll(this.instance.scroll[this.directionAxis], this.instance.limit[this.directionAxis]) : this.instance.scroll.y < 0 ? this.setScroll(this.instance.scroll[this.directionAxis], 0) : this.setScroll(this.instance.scroll[this.directionAxis], this.instance.delta[this.directionAxis])
  1590.                }
  1591.            }, {
  1592.                key: "addDirection",
  1593.                value: function() {
  1594.                    this.instance.delta.y > this.instance.scroll.y ? "down" !== this.instance.direction && (this.instance.direction = "down") : this.instance.delta.y < this.instance.scroll.y && "up" !== this.instance.direction && (this.instance.direction = "up"), this.instance.delta.x > this.instance.scroll.x ? "right" !== this.instance.direction && (this.instance.direction = "right") : this.instance.delta.x < this.instance.scroll.x && "left" !== this.instance.direction && (this.instance.direction = "left")
  1595.                }
  1596.            }, {
  1597.                key: "addSpeed",
  1598.                value: function() {
  1599.                    this.instance.delta[this.directionAxis] != this.instance.scroll[this.directionAxis] ? this.instance.speed = (this.instance.delta[this.directionAxis] - this.instance.scroll[this.directionAxis]) / Math.max(1, Date.now() - this.speedTs) : this.instance.speed = 0
  1600.                }
  1601.            }, {
  1602.                key: "initScrollBar",
  1603.                value: function() {
  1604.                    if (this.scrollbar = document.createElement("span"), this.scrollbarThumb = document.createElement("span"), this.scrollbar.classList.add("".concat(this.scrollbarClass)), this.scrollbarThumb.classList.add("".concat(this.scrollbarClass, "_thumb")), this.scrollbar.append(this.scrollbarThumb), this.scrollbarContainer ? this.scrollbarContainer.append(this.scrollbar) : document.body.append(this.scrollbar), this.getScrollBar = this.getScrollBar.bind(this), this.releaseScrollBar = this.releaseScrollBar.bind(this), this.moveScrollBar = this.moveScrollBar.bind(this), this.scrollbarThumb.addEventListener("mousedown", this.getScrollBar), window.addEventListener("mouseup", this.releaseScrollBar), window.addEventListener("mousemove", this.moveScrollBar), this.hasScrollbar = !1, "horizontal" == this.direction) {
  1605.                        if (this.instance.limit.x + this.windowWidth <= this.windowWidth) return
  1606.                    } else if (this.instance.limit.y + this.windowHeight <= this.windowHeight) return;
  1607.                     this.hasScrollbar = !0, this.scrollbarBCR = this.scrollbar.getBoundingClientRect(), this.scrollbarHeight = this.scrollbarBCR.height, this.scrollbarWidth = this.scrollbarBCR.width, "horizontal" === this.direction ? this.scrollbarThumb.style.width = "".concat(this.scrollbarWidth * this.scrollbarWidth / (this.instance.limit.x + this.scrollbarWidth), "px") : this.scrollbarThumb.style.height = "".concat(this.scrollbarHeight * this.scrollbarHeight / (this.instance.limit.y + this.scrollbarHeight), "px"), this.scrollbarThumbBCR = this.scrollbarThumb.getBoundingClientRect(), this.scrollBarLimit = {
  1608.                         x: this.scrollbarWidth - this.scrollbarThumbBCR.width,
  1609.                         y: this.scrollbarHeight - this.scrollbarThumbBCR.height
  1610.                     }
  1611.                 }
  1612.             }, {
  1613.                 key: "reinitScrollBar",
  1614.                 value: function() {
  1615.                     if (this.hasScrollbar = !1, "horizontal" == this.direction) {
  1616.                         if (this.instance.limit.x + this.windowWidth <= this.windowWidth) return
  1617.                    } else if (this.instance.limit.y + this.windowHeight <= this.windowHeight) return;
  1618.                    this.hasScrollbar = !0, this.scrollbarBCR = this.scrollbar.getBoundingClientRect(), this.scrollbarHeight = this.scrollbarBCR.height, this.scrollbarWidth = this.scrollbarBCR.width, "horizontal" === this.direction ? this.scrollbarThumb.style.width = "".concat(this.scrollbarWidth * this.scrollbarWidth / (this.instance.limit.x + this.scrollbarWidth), "px") : this.scrollbarThumb.style.height = "".concat(this.scrollbarHeight * this.scrollbarHeight / (this.instance.limit.y + this.scrollbarHeight), "px"), this.scrollbarThumbBCR = this.scrollbarThumb.getBoundingClientRect(), this.scrollBarLimit = {
  1619.                        x: this.scrollbarWidth - this.scrollbarThumbBCR.width,
  1620.                        y: this.scrollbarHeight - this.scrollbarThumbBCR.height
  1621.                    }
  1622.                }
  1623.            }, {
  1624.                key: "destroyScrollBar",
  1625.                value: function() {
  1626.                    this.scrollbarThumb.removeEventListener("mousedown", this.getScrollBar), window.removeEventListener("mouseup", this.releaseScrollBar), window.removeEventListener("mousemove", this.moveScrollBar), this.scrollbar.remove()
  1627.                }
  1628.            }, {
  1629.                key: "getScrollBar",
  1630.                value: function() {
  1631.                    this.isDraggingScrollbar = !0, this.checkScroll(), this.html.classList.remove(this.scrollingClass), this.html.classList.add(this.draggingClass)
  1632.                }
  1633.            }, {
  1634.                key: "releaseScrollBar",
  1635.                value: function() {
  1636.                    this.isDraggingScrollbar = !1, this.html.classList.add(this.scrollingClass), this.html.classList.remove(this.draggingClass)
  1637.                }
  1638.            }, {
  1639.                key: "moveScrollBar",
  1640.                value: function(i) {
  1641.                    var n = this;
  1642.                    this.isDraggingScrollbar && requestAnimationFrame(function() {
  1643.                        var t = 100 * (i.clientX - n.scrollbarBCR.left) / n.scrollbarWidth * n.instance.limit.x / 100,
  1644.                            e = 100 * (i.clientY - n.scrollbarBCR.top) / n.scrollbarHeight * n.instance.limit.y / 100;
  1645.                        0 < e && e < n.instance.limit.y && (n.instance.delta.y = e), 0 < t && t < n.instance.limit.x && (n.instance.delta.x = t)
  1646.                    })
  1647.                }
  1648.            }, {
  1649.                key: "addElements",
  1650.                value: function() {
  1651.                    var L = this;
  1652.                    this.els = {}, this.parallaxElements = {}, this.el.querySelectorAll("[data-".concat(this.name, "]")).forEach(function(t, e) {
  1653.                        var i, n, s, r, o, a = Y(t),
  1654.                            l = Object.entries(L.sections).map(function(t) {
  1655.                                var e = D(t, 2);
  1656.                                e[0];
  1657.                                return e[1]
  1658.                            }).find(function(t) {
  1659.                                return a.includes(t.el)
  1660.                            }),
  1661.                            h = t.dataset[L.name + "Class"] || L.class,
  1662.                            c = "string" == typeof t.dataset[L.name + "Id"] ? t.dataset[L.name + "Id"] : "el" + e,
  1663.                            u = t.dataset[L.name + "Repeat"],
  1664.                            d = t.dataset[L.name + "Call"],
  1665.                            f = t.dataset[L.name + "Position"],
  1666.                            m = t.dataset[L.name + "Delay"],
  1667.                            p = t.dataset[L.name + "Direction"],
  1668.                            g = "string" == typeof t.dataset[L.name + "Sticky"],
  1669.                            v = !!t.dataset[L.name + "Speed"] && parseFloat(t.dataset[L.name + "Speed"]) / 10,
  1670.                            y = "string" == typeof t.dataset[L.name + "Offset"] ? t.dataset[L.name + "Offset"].split(",") : L.offset,
  1671.                            b = t.dataset[L.name + "Target"],
  1672.                            w = void 0 !== b ? document.querySelector("".concat(b)) : t,
  1673.                            E = w.getBoundingClientRect(),
  1674.                            T = null === l || l.inView ? (i = E.top + L.instance.scroll.y - W(w).y, E.left + L.instance.scroll.x - W(w).x) : (i = E.top - W(l.el).y - W(w).y, E.left - W(l.el).x - W(w).x),
  1675.                            x = i + w.offsetHeight,
  1676.                            S = T + w.offsetWidth,
  1677.                            A = {
  1678.                                x: (S - T) / 2 + T,
  1679.                                y: (x - i) / 2 + i
  1680.                            };
  1681.                        g && (s = (n = t.getBoundingClientRect()).top, o = {
  1682.                            x: (r = n.left) - T,
  1683.                            y: s - i
  1684.                        }, i += window.innerHeight, T += window.innerWidth, x = s + w.offsetHeight - t.offsetHeight - o[L.directionAxis], A = {
  1685.                            x: ((S = r + w.offsetWidth - t.offsetWidth - o[L.directionAxis]) - T) / 2 + T,
  1686.                            y: (x - i) / 2 + i
  1687.                        }), u = "false" != u && (null != u || L.repeat);
  1688.                        var R = [0, 0];
  1689.                        if (y)
  1690.                            if ("horizontal" === L.direction) {
  1691.                                for (var _ = 0; _ < y.length; _++) "string" == typeof y[_] ? y[_].includes("%") ? R[_] = parseInt(y[_].replace("%", "") * L.windowWidth / 100) : R[_] = parseInt(y[_]) : R[_] = y[_];
  1692.                                T += R[0], S -= R[1]
  1693.                            } else {
  1694.                                for (_ = 0; _ < y.length; _++) "string" == typeof y[_] ? y[_].includes("%") ? R[_] = parseInt(y[_].replace("%", "") * L.windowHeight / 100) : R[_] = parseInt(y[_]) : R[_] = y[_];
  1695.                                i += R[0], x -= R[1]
  1696.                            } var k = {
  1697.                            el: t,
  1698.                            id: c,
  1699.                            class: h,
  1700.                            section: l,
  1701.                            top: i,
  1702.                            middle: A,
  1703.                            bottom: x,
  1704.                            left: T,
  1705.                            right: S,
  1706.                            offset: y,
  1707.                            progress: 0,
  1708.                            repeat: u,
  1709.                            inView: !1,
  1710.                            call: d,
  1711.                            speed: v,
  1712.                            delay: m,
  1713.                            position: f,
  1714.                            target: w,
  1715.                            direction: p,
  1716.                            sticky: g
  1717.                        };
  1718.                        L.els[c] = k, t.classList.contains(h) && L.setInView(L.els[c], c), !1 === v && !g || (L.parallaxElements[c] = k)
  1719.                    })
  1720.                }
  1721.            }, {
  1722.                key: "addSections",
  1723.                value: function() {
  1724.                    var l = this;
  1725.                    this.sections = {};
  1726.                    var t = this.el.querySelectorAll("[data-".concat(this.name, "-section]"));
  1727.                    0 === t.length && (t = [this.el]), t.forEach(function(t, e) {
  1728.                        var i = "string" == typeof t.dataset[l.name + "Id"] ? t.dataset[l.name + "Id"] : "section" + e,
  1729.                            n = t.getBoundingClientRect(),
  1730.                            s = {
  1731.                                x: n.left - 1.5 * window.innerWidth - W(t).x,
  1732.                                y: n.top - 1.5 * window.innerHeight - W(t).y
  1733.                            },
  1734.                            r = {
  1735.                                x: s.x + n.width + 2 * window.innerWidth,
  1736.                                y: s.y + n.height + 2 * window.innerHeight
  1737.                            },
  1738.                            o = "string" == typeof t.dataset[l.name + "Persistent"];
  1739.                        t.setAttribute("data-scroll-section-id", i);
  1740.                        var a = {
  1741.                            el: t,
  1742.                            offset: s,
  1743.                            limit: r,
  1744.                            inView: !1,
  1745.                            persistent: o,
  1746.                            id: i
  1747.                        };
  1748.                        l.sections[i] = a
  1749.                    })
  1750.                }
  1751.            }, {
  1752.                key: "transform",
  1753.                value: function(t, e, i, n) {
  1754.                    var s, r, o, a;
  1755.                    s = n ? (o = j((r = W(t)).x, e, n), a = j(r.y, i, n), "matrix3d(1,0,0.00,0,0.00,1,0.00,0,0,0,1,0,".concat(o, ",").concat(a, ",0,1)")) : "matrix3d(1,0,0.00,0,0.00,1,0.00,0,0,0,1,0,".concat(e, ",").concat(i, ",0,1)"), t.style.webkitTransform = s, t.style.msTransform = s, t.style.transform = s
  1756.                }
  1757.            }, {
  1758.                key: "transformElements",
  1759.                value: function(s, t) {
  1760.                    var r = this,
  1761.                        o = 1 < arguments.length && void 0 !== t && t,
  1762.                        a = this.instance.scroll.x + this.windowWidth,
  1763.                        l = this.instance.scroll.y + this.windowHeight,
  1764.                        h = {
  1765.                            x: this.instance.scroll.x + this.windowMiddle.x,
  1766.                            y: this.instance.scroll.y + this.windowMiddle.y
  1767.                        };
  1768.                    Object.entries(this.parallaxElements).forEach(function(t) {
  1769.                        var e = D(t, 2),
  1770.                            i = (e[0], e[1]),
  1771.                            n = s ? 0 : !1;
  1772.                        if (i.inView || o) switch (i.position) {
  1773.                            case "top":
  1774.                                n = r.instance.scroll[r.directionAxis] * -i.speed;
  1775.                                break;
  1776.                            case "elementTop":
  1777.                                n = (l - i.top) * -i.speed;
  1778.                                break;
  1779.                            case "bottom":
  1780.                                n = (r.instance.limit[r.directionAxis] - l + r.windowHeight) * i.speed;
  1781.                                break;
  1782.                            case "left":
  1783.                                n = r.instance.scroll[r.directionAxis] * -i.speed;
  1784.                                break;
  1785.                            case "elementLeft":
  1786.                                n = (a - i.left) * -i.speed;
  1787.                                break;
  1788.                            case "right":
  1789.                                n = (r.instance.limit[r.directionAxis] - a + r.windowHeight) * i.speed;
  1790.                                break;
  1791.                            default:
  1792.                                n = (h[r.directionAxis] - i.middle[r.directionAxis]) * -i.speed
  1793.                        }
  1794.                        i.sticky && (n = i.inView ? "horizontal" === r.direction ? r.instance.scroll.x - i.left + window.innerWidth : r.instance.scroll.y - i.top + window.innerHeight : "horizontal" === r.direction ? r.instance.scroll.x < i.left - window.innerWidth && r.instance.scroll.x < i.left - window.innerWidth / 2 ? 0 : r.instance.scroll.x > i.right && r.instance.scroll.x > i.right + 100 && i.right - i.left + window.innerWidth : r.instance.scroll.y < i.top - window.innerHeight && r.instance.scroll.y < i.top - window.innerHeight / 2 ? 0 : r.instance.scroll.y > i.bottom && r.instance.scroll.y > i.bottom + 100 && i.bottom - i.top + window.innerHeight), !1 !== n && ("horizontal" === i.direction || "horizontal" === r.direction && "vertical" !== i.direction ? r.transform(i.el, n, 0, !s && i.delay) : r.transform(i.el, 0, n, !s && i.delay))
  1795.                    })
  1796.                }
  1797.            }, {
  1798.                key: "scrollTo",
  1799.                value: function(t, e) {
  1800.                    var i = this,
  1801.                        n = 1 < arguments.length && void 0 !== e ? e : {},
  1802.                        s = parseInt(n.offset) || 0,
  1803.                        r = n.duration || 1e3,
  1804.                        o = n.easing || [.25, 0, .35, 1],
  1805.                        a = !!n.disableLerp,
  1806.                        l = !!n.callback && n.callback,
  1807.                        o = Z.apply(void 0, y(o));
  1808.                     if ("string" == typeof t) {
  1809.                         if ("top" === t) t = 0;
  1810.                         else if ("bottom" === t) t = this.instance.limit.y;
  1811.                         else if ("left" === t) t = 0;
  1812.                         else if ("right" === t) t = this.instance.limit.x;
  1813.                         else if (!(t = document.querySelector(t))) return
  1814.                     } else if ("number" == typeof t) t = parseInt(t);
  1815.                     else if (!t || !t.tagName) return void console.warn("`target` parameter is not valid");
  1816.                     if ("number" != typeof t) {
  1817.                         if (!Y(t).includes(this.el)) return;
  1818.                         var h = t.getBoundingClientRect(),
  1819.                             c = h.top,
  1820.                             u = h.left,
  1821.                             d = Y(t).find(function(e) {
  1822.                                 return Object.entries(i.sections).map(function(t) {
  1823.                                     var e = D(t, 2);
  1824.                                     e[0];
  1825.                                     return e[1]
  1826.                                 }).find(function(t) {
  1827.                                     return t.el == e
  1828.                                 })
  1829.                             }),
  1830.                             f = 0,
  1831.                             f = d ? W(d)[this.directionAxis] : -this.instance.scroll[this.directionAxis],
  1832.                             s = "horizontal" === this.direction ? u + s - f : c + s - f
  1833.                     } else s = t + s;
  1834.  
  1835.                     function m(t) {
  1836.                         a ? "horizontal" === i.direction ? i.setScroll(p + g * t, i.instance.delta.y) : i.setScroll(i.instance.delta.x, p + g * t) : i.instance.delta[i.directionAxis] = p + g * t
  1837.                     }
  1838.                     var p = parseFloat(this.instance.delta[this.directionAxis]),
  1839.                         g = Math.max(0, Math.min(s, this.instance.limit[this.directionAxis])) - p;
  1840.                     this.animatingScroll = !0, this.stopScrolling(), this.startScrolling();
  1841.                     var v = Date.now();
  1842.                     ! function t() {
  1843.                         var e = (Date.now() - v) / r;
  1844.                         1 < e ? (m(1), i.animatingScroll = !1, 0 == r && i.update(), l && l()) : (i.scrollToRaf = requestAnimationFrame(t), m(o(e)))
  1845.                    }()
  1846.                }
  1847.            }, {
  1848.                key: "update",
  1849.                value: function() {
  1850.                    this.setScrollLimit(), this.addSections(), this.addElements(), this.detectElements(), this.updateScroll(), this.transformElements(!0), this.reinitScrollBar(), this.checkScroll(!0)
  1851.                }
  1852.            }, {
  1853.                key: "startScroll",
  1854.                value: function() {
  1855.                    this.stop = !1
  1856.                }
  1857.            }, {
  1858.                key: "stopScroll",
  1859.                value: function() {
  1860.                    this.stop = !0
  1861.                }
  1862.            }, {
  1863.                key: "setScroll",
  1864.                value: function(t, e) {
  1865.                    this.instance = o(o({}, this.instance), {}, {
  1866.                        scroll: {
  1867.                            x: t,
  1868.                            y: e
  1869.                        },
  1870.                        delta: {
  1871.                            x: t,
  1872.                            y: e
  1873.                        },
  1874.                        speed: 0
  1875.                    })
  1876.                }
  1877.            }, {
  1878.                key: "destroy",
  1879.                value: function() {
  1880.                    u(l(r.prototype), "destroy", this).call(this), this.stopScrolling(), this.html.classList.remove(this.smoothClass), this.vs.destroy(), this.destroyScrollBar(), window.removeEventListener("keydown", this.checkKey, !1)
  1881.                }
  1882.            }]), r
  1883.        }(),
  1884.        ht = function() {
  1885.            function e() {
  1886.                var t = 0 < arguments.length && void 0 !== arguments[0] ? arguments[0] : {};
  1887.                s(this, e), this.options = t, Object.assign(this, f, t), this.smartphone = f.smartphone, t.smartphone && Object.assign(this.smartphone, t.smartphone), this.tablet = f.tablet, t.tablet && Object.assign(this.tablet, t.tablet), this.smooth || "horizontal" != this.direction || console.warn("🚨 `smooth:false` & `horizontal` direction are not yet compatible"), this.tablet.smooth || "horizontal" != this.tablet.direction || console.warn("🚨 `smooth:false` & `horizontal` direction are not yet compatible (tablet)"), this.smartphone.smooth || "horizontal" != this.smartphone.direction || console.warn("🚨 `smooth:false` & `horizontal` direction are not yet compatible (smartphone)"), this.init()
  1888.            }
  1889.            return t(e, [{
  1890.                key: "init",
  1891.                value: function() {
  1892.                    var t, e;
  1893.                    this.options.isMobile = /Android|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) || "MacIntel" === navigator.platform && 1 < navigator.maxTouchPoints || window.innerWidth < this.tablet.breakpoint, this.options.isTablet = this.options.isMobile && window.innerWidth >= this.tablet.breakpoint, this.smooth && !this.options.isMobile || this.tablet.smooth && this.options.isTablet || this.smartphone.smooth && this.options.isMobile && !this.options.isTablet ? this.scroll = new lt(this.options) : this.scroll = new b(this.options), this.scroll.init(), window.location.hash && (t = window.location.hash.slice(1, window.location.hash.length), (e = document.getElementById(t)) && this.scroll.scrollTo(e))
  1894.                }
  1895.            }, {
  1896.                key: "update",
  1897.                value: function() {
  1898.                    this.scroll.update()
  1899.                }
  1900.            }, {
  1901.                key: "start",
  1902.                value: function() {
  1903.                    this.scroll.startScroll()
  1904.                }
  1905.            }, {
  1906.                key: "stop",
  1907.                value: function() {
  1908.                    this.scroll.stopScroll()
  1909.                }
  1910.            }, {
  1911.                key: "scrollTo",
  1912.                value: function(t, e) {
  1913.                    this.scroll.scrollTo(t, e)
  1914.                }
  1915.            }, {
  1916.                key: "setScroll",
  1917.                value: function(t, e) {
  1918.                    this.scroll.setScroll(t, e)
  1919.                }
  1920.            }, {
  1921.                key: "on",
  1922.                value: function(t, e) {
  1923.                    this.scroll.setEvents(t, e)
  1924.                }
  1925.            }, {
  1926.                key: "off",
  1927.                value: function(t, e) {
  1928.                    this.scroll.unsetEvents(t, e)
  1929.                }
  1930.            }, {
  1931.                key: "destroy",
  1932.                value: function() {
  1933.                    this.scroll.destroy()
  1934.                }
  1935.            }]), e
  1936.        }();
  1937.     ! function() {
  1938.         document.documentElement.classList.add("is-loaded"), document.documentElement.classList.remove("is-loading"), setTimeout(function() {
  1939.             document.documentElement.classList.add("is-ready")
  1940.         }, 300);
  1941.         var e = {
  1942.             el: document.querySelector("#js-scroll"),
  1943.             smooth: !0,
  1944.             getSpeed: !0,
  1945.             getDirection: !0
  1946.         };
  1947.         "true" == document.querySelector("#js-scroll").getAttribute("data-horizontal") && (e.direction = "horizontal", e.gestureDirection = "both", e.tablet = {
  1948.            smooth: !0,
  1949.            direction: "horizontal",
  1950.            horizontalGesture: !0
  1951.        }, e.smartphone = {
  1952.            smooth: !1
  1953.        }, e.reloadOnContextChange = !0), setTimeout(function() {
  1954.            var t = new ht(e),
  1955.                i = document.getElementById("bgOverlay"),
  1956.                n = document.getElementById("colorOverlay"),
  1957.                s = document.getElementById("greyIn");
  1958.             t.on("scroll", function(t) {
  1959.                 var e = 120 + 360 * t.scroll.y / 2e3;
  1960.                 i.style.backgroundColor = "hsl(".concat(e, ", 90%, 70%)"), n.style.color = "hsl(".concat(e, ", 30%, 80%)"), document.documentElement.setAttribute("data-direction", t.direction), s.classList.contains("is-inview") ? (document.getElementById("grey").style.opacity = 1, document.body.classList.add("dark")) : (document.getElementById("grey").style.opacity = 0, document.body.classList.remove("dark"))
  1961.             })
  1962.         }, 1e3)
  1963.     }()
  1964. }(),
  1965. function(t, e) {
  1966.     "object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : t.GlslCanvas = e()
  1967. }(this, function() {
  1968.    "use strict";
  1969.     var t, e, i, n = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof self ? self : {},
  1970.         s = "undefined" != typeof window ? window : n,
  1971.         o = function(t) {
  1972.             var e = r.call(t);
  1973.             return "[object Function]" === e || "function" == typeof t && "[object RegExp]" !== e || "undefined" != typeof window && (t === window.setTimeout || t === window.alert || t === window.confirm || t === window.prompt)
  1974.        },
  1975.        r = Object.prototype.toString,
  1976.        a = (e = t = {
  1977.            exports: {}
  1978.        }, i = t.exports, (i = e.exports = function(t) {
  1979.            return t.replace(/^\s*|\s*$/g, "")
  1980.        }).left = function(t) {
  1981.            return t.replace(/^\s*/, "")
  1982.        }, i.right = function(t) {
  1983.            return t.replace(/\s*$/, "")
  1984.        }, t.exports),
  1985.        l = Object.prototype.toString,
  1986.        h = Object.prototype.hasOwnProperty,
  1987.        g = function(t) {
  1988.            if (!t) return {};
  1989.             var r = {};
  1990.             return function(t, e, i) {
  1991.                 if (!o(e)) throw new TypeError("iterator must be a function");
  1992.                 arguments.length < 3 && (i = this), ("[object Array]" === l.call(t) ? function(t, e, i) {
  1993.                    for (var n = 0, s = t.length; n < s; n++) h.call(t, n) && e.call(i, t[n], n, t)
  1994.                } : "string" == typeof t ? function(t, e, i) {
  1995.                    for (var n = 0, s = t.length; n < s; n++) e.call(i, t.charAt(n), n, t)
  1996.                } : function(t, e, i) {
  1997.                    for (var n in t) h.call(t, n) && e.call(i, t[n], n, t)
  1998.                })(t, e, i)
  1999.            }(a(t).split("\n"), function(t) {
  2000.                var e, i = t.indexOf(":"),
  2001.                    n = a(t.slice(0, i)).toLowerCase(),
  2002.                    s = a(t.slice(i + 1));
  2003.                void 0 === r[n] ? r[n] = s : (e = r[n], "[object Array]" === Object.prototype.toString.call(e) ? r[n].push(s) : r[n] = [r[n], s])
  2004.            }), r
  2005.        },
  2006.        c = function() {
  2007.            for (var t = {}, e = 0; e < arguments.length; e++) {
  2008.                var i = arguments[e];
  2009.                for (var n in i) u.call(i, n) && (t[n] = i[n])
  2010.            }
  2011.            return t
  2012.        },
  2013.        u = Object.prototype.hasOwnProperty,
  2014.        f = v,
  2015.        d = v;
  2016.  
  2017.    function m(t, e, i) {
  2018.        var n = t;
  2019.        return o(e) ? (i = e, "string" == typeof t && (n = {
  2020.            uri: t
  2021.        })) : n = c(e, {
  2022.            uri: t
  2023.        }), n.callback = i, n
  2024.    }
  2025.  
  2026.    function v(t, e, i) {
  2027.        return p(e = m(t, e, i))
  2028.    }
  2029.  
  2030.    function p(n) {
  2031.        if (void 0 === n.callback) throw new Error("callback argument missing");
  2032.  
  2033.        function s(t, e, i) {
  2034.            r || (r = !0, n.callback(t, e, i))
  2035.        }
  2036.        var r = !1;
  2037.  
  2038.        function e(t) {
  2039.            return clearTimeout(a), t instanceof Error || (t = new Error("" + (t || "Unknown XMLHttpRequest Error"))), t.statusCode = 0, s(t, p)
  2040.        }
  2041.  
  2042.        function t() {
  2043.            if (!o) {
  2044.                var t;
  2045.                clearTimeout(a), t = n.useXDR && void 0 === l.status ? 200 : 1223 === l.status ? 204 : l.status;
  2046.                var e = p,
  2047.                    i = null;
  2048.                return 0 !== t ? (e = {
  2049.                    body: function() {
  2050.                        var t = void 0,
  2051.                            t = l.response ? l.response : l.responseText || function(t) {
  2052.                                try {
  2053.                                    if ("document" === t.responseType) return t.responseXML;
  2054.                                    var e = t.responseXML && "parsererror" === t.responseXML.documentElement.nodeName;
  2055.                                    if ("" === t.responseType && !e) return t.responseXML
  2056.                                } catch (t) {}
  2057.                                return null
  2058.                            }(l);
  2059.                        if (m) try {
  2060.                            t = JSON.parse(t)
  2061.                        } catch (t) {}
  2062.                        return t
  2063.                    }(),
  2064.                    statusCode: t,
  2065.                    method: c,
  2066.                    headers: {},
  2067.                    url: h,
  2068.                    rawRequest: l
  2069.                }, l.getAllResponseHeaders && (e.headers = g(l.getAllResponseHeaders()))) : i = new Error("Internal XMLHttpRequest Error"), s(i, e, e.body)
  2070.            }
  2071.        }
  2072.        var i, o, a, l = n.xhr || null,
  2073.            h = (l = l || (n.cors || n.useXDR ? new v.XDomainRequest : new v.XMLHttpRequest)).url = n.uri || n.url,
  2074.            c = l.method = n.method || "GET",
  2075.            u = n.body || n.data,
  2076.            d = l.headers = n.headers || {},
  2077.            f = !!n.sync,
  2078.            m = !1,
  2079.            p = {
  2080.                body: void 0,
  2081.                headers: {},
  2082.                statusCode: 0,
  2083.                method: c,
  2084.                url: h,
  2085.                rawRequest: l
  2086.            };
  2087.        if ("json" in n && !1 !== n.json && (m = !0, d.accept || d.Accept || (d.Accept = "application/json"), "GET" !== c && "HEAD" !== c && (d["content-type"] || d["Content-Type"] || (d["Content-Type"] = "application/json"), u = JSON.stringify(!0 === n.json ? u : n.json))), l.onreadystatechange = function() {
  2088.                4 === l.readyState && setTimeout(t, 0)
  2089.            }, l.onload = t, l.onerror = e, l.onprogress = function() {}, l.onabort = function() {
  2090.                o = !0
  2091.            }, l.ontimeout = e, l.open(c, h, !f, n.username, n.password), f || (l.withCredentials = !!n.withCredentials), !f && 0 < n.timeout && (a = setTimeout(function() {
  2092.                var t;
  2093.                o || (o = !0, l.abort("timeout"), (t = new Error("XMLHttpRequest timeout")).code = "ETIMEDOUT", e(t))
  2094.            }, n.timeout)), l.setRequestHeader)
  2095.            for (i in d) d.hasOwnProperty(i) && l.setRequestHeader(i, d[i]);
  2096.        else if (n.headers && ! function(t) {
  2097.                for (var e in t)
  2098.                    if (t.hasOwnProperty(e)) return;
  2099.                return 1
  2100.            }(n.headers)) throw new Error("Headers cannot be set on an XDomainRequest object");
  2101.        return "responseType" in n && (l.responseType = n.responseType), "beforeSend" in n && "function" == typeof n.beforeSend && n.beforeSend(l), l.send(u || null), l
  2102.    }
  2103.    v.XMLHttpRequest = s.XMLHttpRequest || function() {}, v.XDomainRequest = "withCredentials" in new v.XMLHttpRequest ? v.XMLHttpRequest : s.XDomainRequest,
  2104.        function(t) {
  2105.            for (var e = 0; e < t.length; e++) ! function(n) {
  2106.                v["delete" === n ? "del" : n] = function(t, e, i) {
  2107.                    return (e = m(t, e, i)).method = n.toUpperCase(), p(e)
  2108.                }
  2109.            }(t[e])
  2110.        }(["get", "put", "post", "patch", "head", "delete"]), f.default = d;
  2111.    var y = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(t) {
  2112.        return typeof t
  2113.    } : function(t) {
  2114.        return t && "function" == typeof Symbol && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t
  2115.    };
  2116.  
  2117.    function b(t, e, i) {
  2118.        return e && E(t.prototype, e), i && E(t, i), t
  2119.    }
  2120.    var w = function(t, e) {
  2121.        if (!(t instanceof e)) throw new TypeError("Cannot call a class as a function")
  2122.    };
  2123.  
  2124.    function E(t, e) {
  2125.        for (var i = 0; i < e.length; i++) {
  2126.            var n = e[i];
  2127.            n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(t, n.key, n)
  2128.        }
  2129.    }
  2130.    var T = function(t) {
  2131.            if (Array.isArray(t)) {
  2132.                for (var e = 0, i = Array(t.length); e < t.length; e++) i[e] = t[e];
  2133.                return i
  2134.            }
  2135.            return Array.from(t)
  2136.        },
  2137.        x = "",
  2138.        S = '\n\tThis page requires a browser that supports WebGL.<br/>\n\t<a href="http://get.webgl.org/">Click here to upgrade your browser.</a>\n',
  2139.         A = '\n\tIt does not appear your computer can support WebGL.<br/>\n\t<a href="http://get.webgl.org/troubleshooting/">Click here for more information.</a>\n',
  2140.         R = 1,
  2141.         _ = 2;
  2142.  
  2143.     function k(t, e, i, n) {
  2144.         var s = t.gl,
  2145.             r = s.createShader(i);
  2146.         return s.shaderSource(r, e), s.compileShader(r), s.getShaderParameter(r, s.COMPILE_STATUS) ? r : (x = s.getShaderInfoLog(r), console.error("*** Error compiling shader " + r + ":" + x), t.trigger("error", {
  2147.             shader: r,
  2148.             source: e,
  2149.             type: i,
  2150.             error: x,
  2151.             offset: n || 0
  2152.         }), s.deleteShader(r), null)
  2153.     }
  2154.  
  2155.     function L(t, e, i, n) {
  2156.         for (var s = t.gl, r = s.createProgram(), o = 0; o < e.length; ++o) s.attachShader(r, e[o]);
  2157.        if (i)
  2158.            for (var a = 0; a < i.length; ++a) s.bindAttribLocation(r, n ? n[a] : a, i[a]);
  2159.        return s.linkProgram(r), s.getProgramParameter(r, s.LINK_STATUS) ? r : (x = s.getProgramInfoLog(r), console.log("Error in program linking:" + x), s.deleteProgram(r), null)
  2160.    }
  2161.  
  2162.    function D(t) {
  2163.        return 0 == (t & t - 1)
  2164.    }
  2165.  
  2166.    function O(t) {
  2167.        var m = new Set;
  2168.        return Object.assign(t, {
  2169.            on: function(t, e) {
  2170.                var i = {};
  2171.                i[t] = e, m.add(i)
  2172.            },
  2173.            off: function(t, e) {
  2174.                if (e) {
  2175.                    var i = {};
  2176.                    i[t] = e, m.delete(i)
  2177.                } else {
  2178.                    var n = !0,
  2179.                        s = !1,
  2180.                        r = void 0;
  2181.                    try {
  2182.                        for (var o, a = m[Symbol.iterator](); !(n = (o = a.next()).done); n = !0) {
  2183.                            var l = o.value,
  2184.                                h = !0,
  2185.                                c = !1,
  2186.                                u = void 0;
  2187.                            try {
  2188.                                for (var d, f = Object.keys(l)[Symbol.iterator](); !(h = (d = f.next()).done); h = !0)
  2189.                                    if (d.value === t) return void m.delete(l)
  2190.                            } catch (t) {
  2191.                                c = !0, u = t
  2192.                            } finally {
  2193.                                try {
  2194.                                    !h && f.return && f.return()
  2195.                                } finally {
  2196.                                    if (c) throw u
  2197.                                }
  2198.                            }
  2199.                        }
  2200.                    } catch (t) {
  2201.                        s = !0, r = t
  2202.                    } finally {
  2203.                        try {
  2204.                            !n && a.return && a.return()
  2205.                        } finally {
  2206.                            if (s) throw r
  2207.                        }
  2208.                    }
  2209.                }
  2210.            },
  2211.            listSubscriptions: function() {
  2212.                var t = !0,
  2213.                    e = !1,
  2214.                    i = void 0;
  2215.                try {
  2216.                    for (var n, s = m[Symbol.iterator](); !(t = (n = s.next()).done); t = !0) {
  2217.                        var r = n.value;
  2218.                        console.log(r)
  2219.                    }
  2220.                } catch (t) {
  2221.                    e = !0, i = t
  2222.                } finally {
  2223.                    try {
  2224.                        !t && s.return && s.return()
  2225.                    } finally {
  2226.                        if (e) throw i
  2227.                    }
  2228.                }
  2229.            },
  2230.            subscribe: function(t) {
  2231.                m.add(t)
  2232.            },
  2233.            unsubscribe: function(t) {
  2234.                m.delete(t)
  2235.            },
  2236.            unsubscribeAll: function() {
  2237.                m.clear()
  2238.            },
  2239.            trigger: function(t) {
  2240.                for (var e = arguments.length, i = Array(1 < e ? e - 1 : 0), n = 1; n < e; n++) i[n - 1] = arguments[n];
  2241.                var s = !0,
  2242.                    r = !1,
  2243.                    o = void 0;
  2244.                try {
  2245.                    for (var a, l = m[Symbol.iterator](); !(s = (a = l.next()).done); s = !0) {
  2246.                        var h = a.value;
  2247.                        "function" == typeof h[t] && h[t].apply(h, T(i))
  2248.                    }
  2249.                } catch (t) {
  2250.                    r = !0, o = t
  2251.                } finally {
  2252.                    try {
  2253.                        !s && l.return && l.return()
  2254.                    } finally {
  2255.                        if (r) throw o
  2256.                    }
  2257.                }
  2258.            }
  2259.        })
  2260.    }
  2261.    var M = (b(P, [{
  2262.        key: "destroy",
  2263.        value: function() {
  2264.            this.valid && (this.gl.deleteTexture(this.texture), this.texture = null, delete this.data, this.data = null, this.valid = !1)
  2265.        }
  2266.    }, {
  2267.        key: "bind",
  2268.        value: function(t) {
  2269.            this.valid && ("number" == typeof t && P.activeUnit !== t && (this.gl.activeTexture(this.gl.TEXTURE0 + t), P.activeUnit = t), P.activeTexture !== this.texture && (this.gl.bindTexture(this.gl.TEXTURE_2D, this.texture), P.activeTexture = this.texture))
  2270.        }
  2271.    }, {
  2272.        key: "load",
  2273.        value: function(t) {
  2274.            var e = 0 < arguments.length && void 0 !== t ? t : {};
  2275.            this.loading = null, "string" == typeof e.url ? void 0 !== this.url && e.url === this.url || this.setUrl(e.url, e) : e.element ? this.setElement(e.element, e) : e.data && e.width && e.height && this.setData(e.width, e.height, e.data, e)
  2276.        }
  2277.    }, {
  2278.        key: "setUrl",
  2279.        value: function(r, t) {
  2280.            var o = this,
  2281.                a = 1 < arguments.length && void 0 !== t ? t : {};
  2282.            if (this.valid) return this.url = r, this.source = this.url, this.sourceType = "url", this.loading = new Promise(function(e, t) {
  2283.                var i = r.split(".").pop().toLowerCase(),
  2284.                    n = "ogv" === i || "webm" === i || "mp4" === i,
  2285.                    s = void 0;
  2286.                n ? ((s = document.createElement("video")).autoplay = !0, a.filtering = "nearest") : s = new Image, s.onload = function() {
  2287.                    try {
  2288.                        o.setElement(s, a)
  2289.                    } catch (t) {
  2290.                        console.log("Texture '" + o.name + "': failed to load url: '" + o.source + "'", t, a)
  2291.                    }
  2292.                    e(o)
  2293.                }, s.onerror = function(t) {
  2294.                    console.log("Texture '" + o.name + "': failed to load url: '" + o.source + "'", t, a), e(o)
  2295.                }, /^((?!chrome|android).)*safari/i.test(navigator.userAgent) && "data:" === o.source.slice(0, 5) || (s.crossOrigin = "anonymous"), s.src = o.source, n && o.setElement(s, a)
  2296.            }), this.loading
  2297.        }
  2298.    }, {
  2299.        key: "setData",
  2300.        value: function(t, e, i, n) {
  2301.            var s = 3 < arguments.length && void 0 !== n ? n : {};
  2302.            return this.width = t, this.height = e, this.source = i, this.sourceType = "data", this.update(s), this.setFiltering(s), this.loading = Promise.resolve(this), this.loading
  2303.        }
  2304.    }, {
  2305.        key: "setElement",
  2306.        value: function(t, e) {
  2307.            var i, n = this,
  2308.                s = t;
  2309.            return "string" == typeof t && (t = document.querySelector(t)), t instanceof HTMLCanvasElement || t instanceof HTMLImageElement || t instanceof HTMLVideoElement ? (this.source = t, this.sourceType = "element", t instanceof HTMLVideoElement ? (t.addEventListener("canplaythrough", function() {
  2310.                n.intervalID = setInterval(function() {
  2311.                    n.update(e)
  2312.                }, 15)
  2313.            }, !0), t.addEventListener("ended", function() {
  2314.                t.currentTime = 0, t.play()
  2315.            }, !0)) : this.update(e), this.setFiltering(e)) : (i = "the 'element' parameter (`element: " + JSON.stringify(s) + "`) must be a CSS ", i += "selector string, or a <canvas>, <image> or <video> object", console.log("Texture '" + this.name + "': " + i, e)), this.loading = Promise.resolve(this), this.loading
  2316.         }
  2317.     }, {
  2318.         key: "update",
  2319.         value: function(t) {
  2320.             var e = 0 < arguments.length && void 0 !== t ? t : {};
  2321.            this.valid && (this.bind(), this.gl.pixelStorei(this.gl.UNPACK_FLIP_Y_WEBGL, !1 !== e.UNPACK_FLIP_Y_WEBGL), this.gl.pixelStorei(this.gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, e.UNPACK_PREMULTIPLY_ALPHA_WEBGL || !1), "element" === this.sourceType && (this.source instanceof HTMLCanvasElement || this.source instanceof HTMLVideoElement || this.source instanceof HTMLImageElement && this.source.complete) ? (this.source instanceof HTMLVideoElement ? (this.width = this.source.videoWidth, this.height = this.source.videoHeight) : (this.width = this.source.width, this.height = this.source.height), this.gl.texImage2D(this.gl.TEXTURE_2D, 0, this.gl.RGBA, this.gl.RGBA, this.gl.UNSIGNED_BYTE, this.source)) : "data" === this.sourceType && this.gl.texImage2D(this.gl.TEXTURE_2D, 0, this.gl.RGBA, this.width, this.height, 0, this.gl.RGBA, this.gl.UNSIGNED_BYTE, this.source), this.trigger("loaded", this))
  2322.        }
  2323.    }, {
  2324.        key: "setFiltering",
  2325.        value: function(t) {
  2326.            var e, i, n = 0 < arguments.length && void 0 !== t ? t : {};
  2327.            this.valid && (this.powerOf2 = D(this.width) && D(this.height), e = this.powerOf2 ? "mipmap" : "linear", this.filtering = n.filtering || e, i = this.gl, this.bind(), this.powerOf2 ? (i.texParameteri(i.TEXTURE_2D, i.TEXTURE_WRAP_S, n.TEXTURE_WRAP_S || n.repeat && i.REPEAT || i.CLAMP_TO_EDGE), i.texParameteri(i.TEXTURE_2D, i.TEXTURE_WRAP_T, n.TEXTURE_WRAP_T || n.repeat && i.REPEAT || i.CLAMP_TO_EDGE), "mipmap" === this.filtering ? (i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MIN_FILTER, i.LINEAR_MIPMAP_LINEAR), i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MAG_FILTER, i.LINEAR), i.generateMipmap(i.TEXTURE_2D)) : "linear" === this.filtering ? (i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MIN_FILTER, i.LINEAR), i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MAG_FILTER, i.LINEAR)) : "nearest" === this.filtering && (i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MIN_FILTER, i.NEAREST), i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MAG_FILTER, i.NEAREST))) : (i.texParameteri(i.TEXTURE_2D, i.TEXTURE_WRAP_S, i.CLAMP_TO_EDGE), i.texParameteri(i.TEXTURE_2D, i.TEXTURE_WRAP_T, i.CLAMP_TO_EDGE), "mipmap" === this.filtering && (this.filtering = "linear"), "nearest" === this.filtering ? (i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MIN_FILTER, i.NEAREST), i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MAG_FILTER, i.NEAREST)) : (i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MIN_FILTER, i.LINEAR), i.texParameteri(i.TEXTURE_2D, i.TEXTURE_MAG_FILTER, i.LINEAR))))
  2328.        }
  2329.    }]), P);
  2330.  
  2331.    function P(t, e) {
  2332.        var i = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : {};
  2333.        w(this, P), O(this), this.gl = t, this.texture = t.createTexture(), this.texture && (this.valid = !0), this.bind(), this.name = e, this.source = null, this.sourceType = null, this.loading = null, this.setData(1, 1, new Uint8Array([0, 0, 0, 255]), {
  2334.            filtering: "linear"
  2335.        }), this.setFiltering(i.filtering), this.load(i)
  2336.    }
  2337.    M.getMaxTextureSize = function(t) {
  2338.        return t.getParameter(t.MAX_TEXTURE_SIZE)
  2339.    }, M.activeUnit = -1;
  2340.    var C = (b(X, [{
  2341.        key: "destroy",
  2342.        value: function() {
  2343.            for (var t in cancelAnimationFrame(this.animationFrameRequest), this.animated = !1, this.isValid = !1, this.textures) t.destroy && t.destroy();
  2344.            for (var e in this.textures = {}, this.attribs) this.gl.deleteBuffer(this.attribs[e]);
  2345.            for (var i in this.gl.useProgram(null), this.gl.deleteProgram(this.program), this.buffers) {
  2346.                var n = this.buffers[i];
  2347.                this.gl.deleteProgram(n.program)
  2348.            }
  2349.            this.program = null, this.gl = null
  2350.        }
  2351.    }, {
  2352.        key: "load",
  2353.        value: function(t, e) {
  2354.            if (e && (this.vertexString = e), t && (this.fragmentString = t), this.animated = !1, this.nDelta = (this.fragmentString.match(/u_delta/g) || []).length, this.nTime = (this.fragmentString.match(/u_time/g) || []).length, this.nDate = (this.fragmentString.match(/u_date/g) || []).length, this.nMouse = (this.fragmentString.match(/u_mouse/g) || []).length, this.animated = 1 < this.nDate || 1 < this.nTime || 1 < this.nMouse, this.fragmentString.search(/sampler2D/g))
  2355.                for (var i = this.fragmentString.split("\n"), n = 0; n < i.length; n++) {
  2356.                    var s, r = i[n].match(/uniform\s*sampler2D\s*([\w]*);\s*\/\/\s*([\w|\:\/\/|\.|\-|\_]*)/i);
  2357.                    if (r && (s = r[2].split(".").pop().toLowerCase(), r[1] && r[2] && ("jpg" === s || "jpeg" === s || "png" === s || "ogv" === s || "webm" === s || "mp4" === s) && this.setUniform(r[1], r[2])), i[n].match(/\s*void\s*main\s*/g)) break
  2358.                }
  2359.            var o = k(this, this.vertexString, this.gl.VERTEX_SHADER),
  2360.                a = k(this, this.fragmentString, this.gl.FRAGMENT_SHADER);
  2361.            a ? this.isValid = !0 : (a = k(this, "void main(){\n\tgl_FragColor=vec4(1.0);\n}", this.gl.FRAGMENT_SHADER), this.isValid = !1);
  2362.            var l = L(this, [o, a]);
  2363.            this.gl.useProgram(l), this.gl.deleteShader(o), this.gl.deleteShader(a), this.program = l, this.change = !0, this.BUFFER_COUNT = 0;
  2364.            var h = this.getBuffers(this.fragmentString);
  2365.            Object.keys(h).length && this.loadPrograms(h), this.buffers = h, this.texureIndex = this.BUFFER_COUNT, this.trigger("load", {}), this.forceRender = !0, this.render()
  2366.        }
  2367.    }, {
  2368.        key: "test",
  2369.        value: function(s, r, o) {
  2370.            var a = this.vertexString,
  2371.                l = this.fragmentString,
  2372.                h = this.paused,
  2373.                c = this.gl.getExtension("EXT_disjoint_timer_query"),
  2374.                u = c.createQueryEXT(),
  2375.                d = this.isValid;
  2376.            (r || o) && (this.load(r, o), d = this.isValid, this.forceRender = !0, this.render()), this.paused = !0, c.beginQueryEXT(c.TIME_ELAPSED_EXT, u), this.forceRender = !0, this.render(), c.endQueryEXT(c.TIME_ELAPSED_EXT);
  2377.            var f = this;
  2378.            ! function t() {
  2379.                f.forceRender = !0, f.render();
  2380.                var e, i = c.getQueryObjectEXT(u, c.QUERY_RESULT_AVAILABLE_EXT),
  2381.                    n = f.gl.getParameter(c.GPU_DISJOINT_EXT);
  2382.                i && !n ? (e = {
  2383.                    wasValid: d,
  2384.                    frag: r || f.fragmentString,
  2385.                    vert: o || f.vertexString,
  2386.                    timeElapsedMs: c.getQueryObjectEXT(u, c.QUERY_RESULT_EXT) / 1e6
  2387.                }, f.paused = h, (r || o) && f.load(l, a), s(e)) : window.requestAnimationFrame(t)
  2388.            }()
  2389.        }
  2390.    }, {
  2391.        key: "loadTexture",
  2392.        value: function(t, e, i) {
  2393.            var n = this;
  2394.            i = i || {}, "string" == typeof e ? i.url = e : "object" === (void 0 === e ? "undefined" : y(e)) && e.data && e.width && e.height ? (i.data = e.data, i.width = e.width, i.height = e.height) : "object" === (void 0 === e ? "undefined" : y(e)) && (i.element = e), this.textures[t] ? this.textures[t] && (this.textures[t].load(i), this.textures[t].on("loaded", function(t) {
  2395.                n.forceRender = !0
  2396.            })) : (this.textures[t] = new M(this.gl, t, i), this.textures[t].on("loaded", function(t) {
  2397.                n.forceRender = !0
  2398.            }))
  2399.        }
  2400.    }, {
  2401.        key: "refreshUniforms",
  2402.        value: function() {
  2403.            this.uniforms = {}
  2404.        }
  2405.    }, {
  2406.        key: "setUniform",
  2407.        value: function(t) {
  2408.            for (var e = {}, i = arguments.length, n = Array(1 < i ? i - 1 : 0), s = 1; s < i; s++) n[s - 1] = arguments[s];
  2409.            e[t] = n, this.setUniforms(e)
  2410.        }
  2411.    }, {
  2412.        key: "setUniforms",
  2413.        value: function(t) {
  2414.            var e = function t(e, i) {
  2415.                var n = 1 < arguments.length && void 0 !== i ? i : null,
  2416.                    s = [];
  2417.                for (var r in e) {
  2418.                    var o = e[r],
  2419.                        a = void 0;
  2420.                    if (n && (r = n + "." + r), "number" == typeof o) s.push({
  2421.                        type: "float",
  2422.                        method: "1f",
  2423.                        name: r,
  2424.                        value: o
  2425.                    });
  2426.                    else if (Array.isArray(o)) {
  2427.                        if ("number" == typeof o[0]) 1 === o.length ? s.push({
  2428.                            type: "float",
  2429.                            method: "1f",
  2430.                            name: r,
  2431.                            value: o
  2432.                        }) : 2 <= o.length && o.length <= 4 ? s.push({
  2433.                            type: "vec" + o.length,
  2434.                            method: o.length + "fv",
  2435.                            name: r,
  2436.                            value: o
  2437.                        }) : 4 < o.length && s.push({
  2438.                            type: "float[]",
  2439.                            method: "1fv",
  2440.                            name: r + "[0]",
  2441.                            value: o
  2442.                        });
  2443.                        else if ("string" == typeof o[0]) s.push({
  2444.                            type: "sampler2D",
  2445.                            method: "1i",
  2446.                            name: r,
  2447.                            value: o
  2448.                        });
  2449.                        else if (Array.isArray(o[0]) && "number" == typeof o[0][0]) {
  2450.                            if (2 <= o[0].length && o[0].length <= 4)
  2451.                                for (a = 0; a < o.length; a++) s.push({
  2452.                                    type: "vec" + o[0].length,
  2453.                                    method: o[a].length + "fv",
  2454.                                    name: r + "[" + a + "]",
  2455.                                    value: o[a]
  2456.                                })
  2457.                        } else if ("object" === y(o[0]))
  2458.                            for (a = 0; a < o.length; a++) s.push.apply(s, T(t(o[a], r + "[" + a + "]")))
  2459.                    } else "boolean" == typeof o ? s.push({
  2460.                        type: "bool",
  2461.                        method: "1i",
  2462.                        name: r,
  2463.                        value: o
  2464.                    }) : "string" == typeof o ? s.push({
  2465.                        type: "sampler2D",
  2466.                        method: "1i",
  2467.                        name: r,
  2468.                        value: o
  2469.                    }) : "object" === (void 0 === o ? "undefined" : y(o)) && s.push.apply(s, T(t(o, r)))
  2470.                }
  2471.                return s
  2472.            }(t);
  2473.            for (var i in e) "sampler2D" === e[i].type ? this.loadTexture(e[i].name, e[i].value[0]) : this.uniform(e[i].method, e[i].type, e[i].name, e[i].value);
  2474.            this.forceRender = !0
  2475.        }
  2476.    }, {
  2477.        key: "setMouse",
  2478.        value: function(t) {
  2479.            var e, i, n = this.canvas.getBoundingClientRect();
  2480.            t && t.x && t.x >= n.left && t.x <= n.right && t.y && t.y >= n.top && t.y <= n.bottom && (e = (t.x - n.left) * this.realToCSSPixels, i = this.canvas.height - (t.y - n.top) * this.realToCSSPixels, this.uniform("2f", "vec2", "u_mouse", e, i))
  2481.        }
  2482.    }, {
  2483.        key: "uniform",
  2484.        value: function(t, e, i) {
  2485.            this.uniforms[i] = this.uniforms[i] || {};
  2486.             for (var n, s, r = this.uniforms[i], o = arguments.length, a = Array(3 < o ? o - 3 : 0), l = 3; l < o; l++) a[l - 3] = arguments[l];
  2487.            if (s = a, (n = r.value) && s && n.toString() !== s.toString() || this.change || !r.location || !r.value)
  2488.                for (var h in r.name = i, r.type = e, r.value = a, r.method = "uniform" + t, this.gl.useProgram(this.program), r.location = this.gl.getUniformLocation(this.program, i), this.gl[r.method].apply(this.gl, [r.location].concat(r.value)), this.buffers) {
  2489.                    var c = this.buffers[h];
  2490.                    this.gl.useProgram(c.program);
  2491.                    var u = this.gl.getUniformLocation(c.program, i);
  2492.                    this.gl[r.method].apply(this.gl, [u].concat(r.value))
  2493.                }
  2494.        }
  2495.    }, {
  2496.        key: "uniformTexture",
  2497.        value: function(t, e, i) {
  2498.            if (void 0 === this.textures[t]) this.loadTexture(t, e, i);
  2499.            else {
  2500.                for (var n in this.uniform("1i", "sampler2D", t, this.texureIndex), this.buffers) {
  2501.                    var s = this.buffers[n];
  2502.                    this.gl.useProgram(s.program), this.gl.activeTexture(this.gl.TEXTURE0 + this.texureIndex), this.gl.bindTexture(this.gl.TEXTURE_2D, this.textures[t].texture)
  2503.                }
  2504.                this.gl.useProgram(this.program), this.gl.activeTexture(this.gl.TEXTURE0 + this.texureIndex), this.gl.bindTexture(this.gl.TEXTURE_2D, this.textures[t].texture), this.uniform("2f", "vec2", t + "Resolution", this.textures[t].width, this.textures[t].height)
  2505.            }
  2506.        }
  2507.    }, {
  2508.        key: "resize",
  2509.        value: function() {
  2510.            if (this.width === this.canvas.clientWidth && this.height === this.canvas.clientHeight) return !1;
  2511.            this.realToCSSPixels = window.devicePixelRatio || 1;
  2512.            var t = Math.floor(this.gl.canvas.clientWidth * this.realToCSSPixels),
  2513.                e = Math.floor(this.gl.canvas.clientHeight * this.realToCSSPixels);
  2514.            return this.gl.canvas.width === t && this.gl.canvas.height === e || (this.gl.canvas.width = t, this.gl.canvas.height = e, this.gl.viewport(0, 0, this.gl.canvas.width, this.gl.canvas.height)), this.width = this.canvas.clientWidth, this.height = this.canvas.clientHeight, this.resizeSwappableBuffers(), !0
  2515.        }
  2516.    }, {
  2517.        key: "render",
  2518.        value: function() {
  2519.            var t;
  2520.            if (this.visible = 0 < (t = this.canvas).getBoundingClientRect().top + t.height && t.getBoundingClientRect().top < (window.innerHeight || document.documentElement.clientHeight), this.forceRender || this.change || this.animated && this.visible && !this.paused) {
  2521.                var e = new Date,
  2522.                    i = performance.now();
  2523.                for (var n in this.timeDelta = (i - this.timePrev) / 1e3, this.timePrev = i, 1 < this.nDelta && this.uniform("1f", "float", "u_delta", this.timeDelta), 1 < this.nTime && this.uniform("1f", "float", "u_time", (i - this.timeLoad) / 1e3), this.nDate && this.uniform("4f", "float", "u_date", e.getFullYear(), e.getMonth(), e.getDate(), 3600 * e.getHours() + 60 * e.getMinutes() + e.getSeconds() + .001 * e.getMilliseconds()), this.uniform("2f", "vec2", "u_resolution", this.canvas.width, this.canvas.height), this.buffers) {
  2524.                    var s = this.buffers[n];
  2525.                    this.uniform("1i", "sampler2D", s.name, s.bundle.input.index)
  2526.                }
  2527.                for (var r in this.texureIndex = this.BUFFER_COUNT, this.textures) this.uniformTexture(r), this.texureIndex++;
  2528.                this.renderPrograms(), this.trigger("render", {}), this.change = !1, this.forceRender = !1
  2529.            }
  2530.        }
  2531.    }, {
  2532.        key: "pause",
  2533.        value: function() {
  2534.            this.paused = !0
  2535.        }
  2536.    }, {
  2537.        key: "play",
  2538.        value: function() {
  2539.            this.paused = !1
  2540.        }
  2541.    }, {
  2542.        key: "renderPrograms",
  2543.        value: function() {
  2544.            var t = this.gl,
  2545.                e = t.canvas.width,
  2546.                i = t.canvas.height;
  2547.            for (var n in t.viewport(0, 0, e, i), this.buffers) {
  2548.                var s = this.buffers[n];
  2549.                s.bundle.render(e, i, s.program, s.name), t.bindFramebuffer(t.FRAMEBUFFER, null)
  2550.            }
  2551.            t.useProgram(this.program), t.drawArrays(t.TRIANGLES, 0, 6)
  2552.        }
  2553.    }, {
  2554.        key: "getBuffers",
  2555.        value: function(e) {
  2556.            var i = {};
  2557.            return e && e.replace(/(?:^\s*)((?:#if|#elif)(?:\s*)(defined\s*\(\s*BUFFER_)(\d+)(?:\s*\))|(?:#ifdef)(?:\s*BUFFER_)(\d+)(?:\s*))/gm, function() {
  2558.                var t = arguments[3] || arguments[4];
  2559.                i["u_buffer" + t] = {
  2560.                    fragment: "#define BUFFER_" + t + "\n" + e
  2561.                }
  2562.            }), i
  2563.        }
  2564.    }, {
  2565.        key: "loadPrograms",
  2566.        value: function(t) {
  2567.            var e = this,
  2568.                i = this.gl,
  2569.                n = k(e, e.vertexString, i.VERTEX_SHADER);
  2570.            for (var s in t) {
  2571.                var r = t[s],
  2572.                    o = k(e, r.fragment, i.FRAGMENT_SHADER, 1);
  2573.                o ? e.isValid = !0 : (o = k(e, "void main(){\n\tgl_FragColor=vec4(1.0);\n}", i.FRAGMENT_SHADER), e.isValid = !1);
  2574.                var a = L(e, [n, o]);
  2575.                r.name = s, r.program = a, r.bundle = e.createSwappableBuffer(e.canvas.width, e.canvas.height, a), i.deleteShader(o)
  2576.            }
  2577.            i.deleteShader(n)
  2578.        }
  2579.    }, {
  2580.        key: "createSwappableBuffer",
  2581.        value: function(t, e, i) {
  2582.            var n = this.createBuffer(t, e, i),
  2583.                s = this.createBuffer(t, e, i),
  2584.                r = this.gl;
  2585.            return {
  2586.                input: n,
  2587.                output: s,
  2588.                swap: function() {
  2589.                    var t = n;
  2590.                    n = s, s = t, this.input = n, this.output = s
  2591.                },
  2592.                render: function(t, e, i) {
  2593.                    r.useProgram(i), r.viewport(0, 0, t, e), r.bindFramebuffer(r.FRAMEBUFFER, this.input.buffer), r.framebufferTexture2D(r.FRAMEBUFFER, r.COLOR_ATTACHMENT0, r.TEXTURE_2D, this.output.texture, 0), r.drawArrays(r.TRIANGLES, 0, 6), this.swap()
  2594.                },
  2595.                resize: function(t, e, i) {
  2596.                    r.useProgram(i), r.viewport(0, 0, t, e), this.input.resize(t, e), this.output.resize(t, e)
  2597.                }
  2598.            }
  2599.        }
  2600.    }, {
  2601.        key: "createBuffer",
  2602.        value: function(t, e) {
  2603.            var l = this.gl,
  2604.                h = this.BUFFER_COUNT;
  2605.            this.BUFFER_COUNT += 2, l.getExtension("OES_texture_float");
  2606.            var c = l.createTexture();
  2607.            l.activeTexture(l.TEXTURE0 + h), l.bindTexture(l.TEXTURE_2D, c), l.texImage2D(l.TEXTURE_2D, 0, l.RGBA, t, e, 0, l.RGBA, l.FLOAT, null), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_MIN_FILTER, l.NEAREST), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_MAG_FILTER, l.NEAREST), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_WRAP_S, l.CLAMP_TO_EDGE), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_WRAP_T, l.CLAMP_TO_EDGE);
  2608.            var u = l.createFramebuffer();
  2609.            return {
  2610.                index: h,
  2611.                texture: c,
  2612.                buffer: u,
  2613.                W: t,
  2614.                H: e,
  2615.                resize: function(t, e) {
  2616.                    l.bindFramebuffer(l.FRAMEBUFFER, u);
  2617.                    var i = Math.min(t, this.W),
  2618.                        n = Math.min(e, this.H),
  2619.                        s = new Float32Array(i * n * 4);
  2620.                    l.readPixels(0, 0, i, n, l.RGBA, l.FLOAT, s), l.bindFramebuffer(l.FRAMEBUFFER, null);
  2621.                    var r = h + 1,
  2622.                        o = l.createTexture();
  2623.                    l.activeTexture(l.TEXTURE0 + r), l.bindTexture(l.TEXTURE_2D, o), l.texImage2D(l.TEXTURE_2D, 0, l.RGBA, t, e, 0, l.RGBA, l.FLOAT, null), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_MIN_FILTER, l.NEAREST), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_MAG_FILTER, l.NEAREST), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_WRAP_S, l.CLAMP_TO_EDGE), l.texParameteri(l.TEXTURE_2D, l.TEXTURE_WRAP_T, l.CLAMP_TO_EDGE), l.texSubImage2D(l.TEXTURE_2D, 0, 0, 0, i, n, l.RGBA, l.FLOAT, s);
  2624.                    var a = l.createFramebuffer();
  2625.                    l.bindFramebuffer(l.FRAMEBUFFER, null), l.deleteTexture(c), l.activeTexture(l.TEXTURE0 + h), l.bindTexture(l.TEXTURE_2D, o), h = this.index = h, c = this.texture = o, u = this.buffer = a, this.W = t, this.H = e
  2626.                }
  2627.            }
  2628.        }
  2629.    }, {
  2630.        key: "resizeSwappableBuffers",
  2631.        value: function() {
  2632.            var t = this.gl,
  2633.                e = t.canvas.width,
  2634.                i = t.canvas.height;
  2635.            for (var n in t.viewport(0, 0, e, i), this.buffers) {
  2636.                var s = this.buffers[n];
  2637.                s.bundle.resize(e, i, s.program, s.name)
  2638.            }
  2639.            t.useProgram(this.program)
  2640.        }
  2641.    }, {
  2642.        key: "version",
  2643.        value: function() {
  2644.            return "0.1.7"
  2645.        }
  2646.    }]), X);
  2647.  
  2648.    function X(t, e, i) {
  2649.        var n = this;
  2650.        w(this, X), O(this), e = e || {}, i = i || {}, !t.hasAttribute("data-fullscreen") || "1" != t.getAttribute("data-fullscreen") && "true" != t.getAttribute("data-fullscreen") ? (this.width = t.clientWidth, this.height = t.clientHeight) : (this.width = window.innerWidth, this.height = window.innerHeight, t.width = window.innerWidth, t.height = window.innerHeight), this.canvas = t, this.gl = void 0, this.program = void 0, this.textures = {}, this.buffers = {}, this.uniforms = {}, this.vbo = {}, this.isValid = !1, this.animationFrameRequest = void 0, this.BUFFER_COUNT = 0, this.vertexString = e.vertexString || "\n#ifdef GL_ES\nprecision mediump float;\n#endif\n\nattribute vec2 a_position;\nattribute vec2 a_texcoord;\n\nvarying vec2 v_texcoord;\n\nvoid main(){\n gl_Position=vec4(a_position, 0.0, 1.0);\n v_texcoord=a_texcoord;\n}\n", this.fragmentString = e.fragmentString || "\n#ifdef GL_ES\nprecision mediump float;\n#endif\n\nvarying vec2 v_texcoord;\n\nvoid main(){\n gl_FragColor=vec4(0.0);\n}\n";
  2651.        var s, r, o = function(n, t, s) {
  2652.            function e(t, e) {
  2653.                var i;
  2654.                "function" == typeof s ? s(t) : (i = n.parentNode) && (i.innerHTML = '\n<table style="background-color: #8CE; width: 100%; height: 100%;"><tr>\n<td align="center">\n<div style="display: table-cell; vertical-align: middle;">\n<div style="">' + e + "</div>\n</div>\n</td></tr></table>\n")
  2655.             }
  2656.             if (!window.WebGLRenderingContext) return e(R, S), null;
  2657.             var i = function(t, e) {
  2658.                 for (var i = ["webgl", "experimental-webgl"], n = null, s = 0; s < i.length; ++s) try {
  2659.                    n = t.getContext(i[s], e)
  2660.                } catch (t) {
  2661.                    if (n) break
  2662.                }
  2663.                return n
  2664.            }(n, t);
  2665.            return i ? i.getExtension("OES_standard_derivatives") : e(_, A), i
  2666.        }(t, e, i.onError);
  2667.        if (o && (this.gl = o, this.timeLoad = this.timePrev = performance.now(), this.timeDelta = 0, this.forceRender = !0, this.paused = !1, this.realToCSSPixels = window.devicePixelRatio || 1, t.style.backgroundColor = e.backgroundColor || "rgba(1,1,1,0)", t.hasAttribute("data-fragment") ? this.fragmentString = t.getAttribute("data-fragment") : t.hasAttribute("data-fragment-url") && (s = t.getAttribute("data-fragment-url"), f.get(s, function(t, e, i) {
  2668.                n.load(i, n.vertexString)
  2669.            })), t.hasAttribute("data-vertex") ? this.vertexString = t.getAttribute("data-vertex") : t.hasAttribute("data-vertex-url") && (r = t.getAttribute("data-vertex-url"), f.get(r, function(t, e, i) {
  2670.                n.load(n.fragmentString, i)
  2671.            })), this.load(), this.program)) {
  2672.            var a = o.getAttribLocation(this.program, "a_texcoord");
  2673.            this.vbo.texCoords = o.createBuffer(), this.gl.bindBuffer(o.ARRAY_BUFFER, this.vbo.texCoords), this.gl.bufferData(o.ARRAY_BUFFER, new Float32Array([0, 0, 1, 0, 0, 1, 0, 1, 1, 0, 1, 1]), o.STATIC_DRAW), this.gl.enableVertexAttribArray(a), this.gl.vertexAttribPointer(a, 2, o.FLOAT, !1, 0, 0);
  2674.            var l = o.getAttribLocation(this.program, "a_position");
  2675.            if (this.vbo.vertices = o.createBuffer(), this.gl.bindBuffer(o.ARRAY_BUFFER, this.vbo.vertices), this.gl.bufferData(o.ARRAY_BUFFER, new Float32Array([-1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, 1]), o.STATIC_DRAW), this.gl.enableVertexAttribArray(l), this.gl.vertexAttribPointer(l, 2, o.FLOAT, !1, 0, 0), t.hasAttribute("data-textures")) {
  2676.                var h = t.getAttribute("data-textures").split(",");
  2677.                for (var c in h) this.setUniform("u_tex" + c, h[c])
  2678.            }
  2679.            var u = {
  2680.                x: 0,
  2681.                y: 0
  2682.            };
  2683.            document.addEventListener("mousemove", function(t) {
  2684.                u.x = t.clientX || t.pageX, u.y = t.clientY || t.pageY
  2685.            }, !1);
  2686.            var d = this;
  2687.            return this.setMouse({
  2688.                    x: 0,
  2689.                    y: 0
  2690.                }),
  2691.                function t() {
  2692.                    1 < d.nMouse && d.setMouse(u), d.resize() && (d.forceRender = !0), d.render(), d.animationFrameRequest = window.requestAnimationFrame(t)
  2693.                }(), this
  2694.        }
  2695.    }
  2696.    return window.addEventListener("load", function() {
  2697.        ! function() {
  2698.            var t = document.getElementsByClassName("glslCanvas");
  2699.            if (0 < t.length) {
  2700.                window.glslCanvases = [];
  2701.                for (var e = 0; e < t.length; e++) {
  2702.                    var i = new C(t[e]);
  2703.                    i.isValid && window.glslCanvases.push(i)
  2704.                }
  2705.            }
  2706.        }()
  2707.    }), C
  2708. });
  2709. </script>
  2710. <script>
  2711. function triggerResize() {
  2712.     var ev = document.createEvent('HTMLEvents');
  2713.     ev.initEvent('resize', true, false);
  2714.     window.dispatchEvent(ev)
  2715. };
  2716. document.addEventListener('DOMContentLoaded', () => {
  2717.     var canvas = document.getElementById("glslCanvas");
  2718.     var sandbox = new GlslCanvas(canvas);
  2719.     var loading = document.getElementById("loading_screen");
  2720.     setTimeout(function() {
  2721.         canvas.classList.add('show')
  2722.     }, 0);
  2723.     setTimeout(function() {
  2724.         triggerResize();
  2725.         loading.classList.add('hide')
  2726.     }, 1000)
  2727. });
  2728.         </script>
  2729. <!-------------------------------------------------------------------- /JS ----------------------------------------------------------------------------------->
  2730.         <span class="c-scrollbar">
  2731.             <span class="c-scrollbar_thumb" style="height: 256.191px; transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);">
  2732.            </span>
  2733.       </span>
  2734.    </body>
  2735. </html>
Advertisement
Add Comment
Please, Sign In to add comment