turbo_boost-elements 0.0.15 → 0.0.16
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dde37569491dc5b14ce6a5d03fed201a975320ebeb87de4b6f0c8685e828c539
|
4
|
+
data.tar.gz: 74e7a37abe28bdaad47b0eda35ed7b2c6c313282d37f49c98f8f890de85016cb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '091350a4cc4d3d3359201201ad584d75845d230bd37f3e992c77a255560c53b1fdb7b05f79fa7d184c7d2e6e0ee372ec966e75cef9205decb6948d1b381b6cf0'
|
7
|
+
data.tar.gz: da7f0b644afdbd3b3f23abbacccadd17e847ae1a570a20a4b8f35d39dcdd1485c166662de87dabeb5b7270e91be9b5f48828d35eb13b7cdaf87163aece811278
|
data/README.md
CHANGED
@@ -197,8 +197,8 @@ TurboBoost.devtools.start()
|
|
197
197
|
|
198
198
|
1. Run `yarn` and `bundle` to pick up the latest
|
199
199
|
1. Bump version number at `lib/turbo_boost/elements/version.rb`. Pre-release versions use `.preN`
|
200
|
-
1. Run `rake build` and `yarn build`
|
201
200
|
1. Run `bin/standardize`
|
201
|
+
1. Run `rake build` and `yarn build`
|
202
202
|
1. Commit and push changes to GitHub
|
203
203
|
1. Run `rake release`
|
204
204
|
1. Run `yarn publish --no-git-tag-version --access public`
|
@@ -1,4 +1,4 @@
|
|
1
|
-
var Be=Object.defineProperty,De=Object.defineProperties,He=Object.getOwnPropertyDescriptors,se=Object.getOwnPropertySymbols,Re=Object.prototype.hasOwnProperty,je=Object.prototype.propertyIsEnumerable,ie=(e,t,o)=>t in e?Be(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,l=(e,t)=>{for(var o in t||(t={}))Re.call(t,o)&&ie(e,o,t[o]);if(se)for(var o of se(t))je.call(t,o)&&ie(e,o,t[o]);return e},b=(e,t)=>De(e,He(t)),Me=class{get element(){return document.querySelector('meta[name="turbo-boost"]')}get token(){return this.element.getAttribute("content")}get busy(){return this.element.dataset.busy==="true"}set busy(e){return this.element.dataset.busy=!!e}},d=new Me,c={start:"turbo-boost:command:start",success:"turbo-boost:command:success",finish:"turbo-boost:command:finish",abort:"turbo-boost:command:abort",clientError:"turbo-boost:command:client-error",serverError:"turbo-boost:command:server-error"},f={stateLoad:"turbo-boost:state:load",stateChange:"turbo-boost:state:change"},h=l(l({},c),f);function m(e,t,o={}){return new Promise(r=>{o=o||{},o.detail=o.detail||{},t=t||document;let n=new CustomEvent(e,b(l({},o),{bubbles:!0}));t.dispatchEvent(n),r(n)})}var P;function R(e,t=null){if(!e||typeof e!="object")return e;let o=new Proxy(e,{deleteProperty(r,n){return delete r[n],m(f.stateChange,d.element,{detail:{state:P}}),!0},set(r,n,s,i){return r[n]=R(s,this),m(f.stateChange,d.element,{detail:{state:P}}),!0}});if(Array.isArray(e))e.forEach((r,n)=>e[n]=R(r,o));else if(typeof e=="object")for(let[r,n]of Object.entries(e))e[r]=R(n,o);return t||(P=o),o}var qe=R,W,E,C,le;function ue(){if(!d.element)return w();let e=atob(d.element.dataset.state);C={},E=qe(JSON.parse(e)),W=l({},E),delete d.element.dataset.clientStateChange,setTimeout(()=>m(f.stateLoad,d.element,{detail:{state:E}}))}function w(){clearTimeout(le),le=setTimeout(ue,10)}W||ue();addEventListener("DOMContentLoaded",w);addEventListener("load",w);addEventListener("turbo:load",w);addEventListener("turbo:frame-load",w);addEventListener(c.success,w);addEventListener(f.stateChange,e=>{C={};for(let[t,o]of Object.entries(E))W[t]!==o&&(C[t]=o);d.element.dataset.clientStateChange=!0,d.element.dataset.state=btoa(JSON.stringify(E))});var j={events:f,get current(){return E},get delta(){return C},get payloadChunks(){return btoa(JSON.stringify(C)).match(/.{1,2000}/g)}};function Ne(e){let t="<html",o="</html",r=e.indexOf(t),n=e.lastIndexOf(o);if(r>=0&&n>=0){let s=e.slice(e.indexOf(">",r)+1,n);document.documentElement.innerHTML=s}}function Pe(e){document.body.insertAdjacentHTML("beforeend",e)}var A={append:Pe,replaceDocument:Ne},M={};function Ie(e){M[e.id]=e}function ze(e){delete M[e]}var me={add:Ie,remove:ze,get commands(){return[...Object.values(M)]},get length(){return Object.keys(M).length}};function he(e){e.detail.endedAt=Date.now(),e.detail.milliseconds=e.detail.endedAt-e.detail.startedAt,setTimeout(()=>m(c.finish,e.target,{detail:e.detail}),25)}addEventListener(c.serverError,he);addEventListener(c.success,he);addEventListener(c.finish,e=>me.remove(e.detail.id),!0);var X={events:c},z={};addEventListener("turbo:before-fetch-request",e=>{let t=e.target.closest("turbo-frame"),{fetchOptions:o}=e.detail;if(d.busy){let r=["text/vnd.turbo-boost.html",o.headers.Accept];r=r.filter(n=>n&&n.trim().length>0).join(", "),o.headers.Accept=r,o.headers["TurboBoost-Token"]=d.token}j.payloadChunks.forEach((r,n)=>{o.headers[`TurboBoost-State-${n.toString().padStart(4,"0")}`]=r})});addEventListener("turbo:before-fetch-response",e=>{let t=e.target.closest("turbo-frame"),{fetchResponse:o}=e.detail;if(t&&(z[t.id]=t.src),o.header("TurboBoost")){if(o.statusCode<200||o.statusCode>399){let r=`Server returned a ${o.statusCode} status code! TurboBoost Commands require 2XX-3XX status codes.`;m(X.events.clientError,document,{detail:b(l({},e.detail),{error:r})},!0)}o.header("TurboBoost")==="Append"&&(e.preventDefault(),o.responseText.then(r=>A.append(r)))}});addEventListener("turbo:frame-load",e=>{let t=e.target.closest("turbo-frame");t.dataset.turboBoostSrc=z[t.id]||t.src||t.dataset.turboBoostSrc,delete z[t.id]});var _e={frameAttribute:"data-turbo-frame",methodAttribute:"data-turbo-method",commandAttribute:"data-turbo-command",confirmAttribute:"data-turbo-confirm"},u=l({},_e),ge={method:e=>Promise.resolve(confirm(e))},Fe=e=>e.detail.driver==="method",We=e=>{if(e.detail.driver!=="form")return!1;let t=e.target,o=t.closest("turbo-frame"),r=t.closest(`[${u.frameAttribute}]`);return!!(o||r)},Xe=e=>Fe(e)||We(e);document.addEventListener(c.start,async e=>{let t=e.target.getAttribute(u.confirmAttribute);!t||(e.detail.confirmation=!0,Xe(e))||await ge.method(t)||e.preventDefault()});var Je=ge,g=[],_;function Ge(e,t){let o=g.find(r=>r.name===e);return o&&g.splice(g.indexOf(o),1),g=[{name:e,selectors:t},...g],document.removeEventListener(e,_,!0),document.addEventListener(e,_,!0),l({},g.find(r=>r.name===e))}function Ve(e){return g.find(t=>t.selectors.find(o=>Array.from(document.querySelectorAll(o)).find(r=>r===e)))}function Ue(e,t){let o=Ve(t);return o&&o.name===e}var p={register:Ge,isRegisteredForElement:Ue,get events(){return[...g]},set handler(e){_=e}};function Ke(e){return e.closest(`[${u.commandAttribute}]`)}function Qe(e){return e.closest("turbo-frame[src]")||e.closest("turbo-frame[data-turbo-frame-src]")||e.closest("turbo-frame")}function Ye(e,t={}){if(e.tagName.toLowerCase()!=="select")return t.value=e.value||null;if(!e.multiple)return t.value=e.options[e.selectedIndex].value;t.values=Array.from(e.options).reduce((o,r)=>(r.selected&&o.push(r.value),o),[])}function Ze(e){let t=Array.from(e.attributes).reduce((o,r)=>{let n=r.value;return o[r.name]=n,o},{});return t.tag=e.tagName,t.checked=!!e.checked,t.disabled=!!e.disabled,Ye(e,t),delete t.class,delete t.action,delete t.href,delete t[u.commandAttribute],delete t[u.frameAttribute],t}var J={buildAttributePayload:Ze,findClosestCommand:Ke,findClosestFrameWithSource:Qe};function et(e,t={}){t.token=d.token;let o=document.createElement("input");o.type="hidden",o.name="turbo_boost_command",o.value=JSON.stringify(t),e.appendChild(o)}var tt={invokeCommand:et};function ot(e,t={}){let o=document.createElement("a");o.href=e;let r=new URL(o);return r.searchParams.set("turbo_boost_command",JSON.stringify(t)),r}var G={build:ot};function rt(e,t){let o=t.src;t=l({},t),delete t.src,e.src=G.build(o,t)}var ae={invokeCommand:rt};function nt(e,t={}){let o=t.src;t=l({},t),delete t.src,delete t.href,e.setAttribute("href",G.build(o,t))}var st={invokeCommand:nt};function it(e){let t=e.target;m(X.events.abort,document,{detail:b(l({},e.detail),{xhr:t})})}function F(e){let t=e.target;t.getResponseHeader("TurboBoost")==="Append"||t.getResponseHeader("Content-Type").startsWith("text/vnd.turbo-boost.html")?A.append(t.responseText):A.replaceDocument(t.responseText);let o=`Server returned a ${t.status} status code! TurboBoost Commands require 2XX-3XX status codes.`;m(X.events.clientError,document,{detail:b(l({},e.detail),{error:o,xhr:t})},!0)}function lt(e){let t=e.target;if(t.status<200||t.status>399)return F(e);let o=t.responseText;t.getResponseHeader("TurboBoost")==="Append"||t.getResponseHeader("Content-Type").startsWith("text/vnd.turbo-boost.html")?A.append(t.responseText):A.replaceDocument(t.responseText)}function at(e){let t=e.src;e=l({},e),delete e.src;try{let o=new XMLHttpRequest;o.open("GET",G.build(t,e),!0),o.setRequestHeader("Accept","text/vnd.turbo-boost.html, text/html, application/xhtml+xml"),o.setRequestHeader("TurboBoost-Token",d.token),j.payloadChunks.forEach((r,n)=>o.setRequestHeader(`TurboBoost-State-${n.toString().padStart(4,"0")}`,r)),o.addEventListener("abort",it),o.addEventListener("error",F),o.addEventListener("load",lt),o.send()}catch(o){let r=`Unexpected error sending HTTP request! ${o.message}`;F(o,{detail:{message:r}})}}var dt={invokeCommand:at};function I(e,t){return t=t||{dataset:{}},e.href||t.src||t.dataset.turboBoostSrc||location.href}function ct(e){let t=J.findClosestFrameWithSource(e),{turboFrame:o,turboMethod:r}=e.dataset;return e.tagName.toLowerCase()==="form"?{name:"form",reason:"Element is a form.",frame:t,src:e.action,invokeCommand:tt.invokeCommand}:r&&r.length>0?{name:"method",reason:"Element defines data-turbo-method.",frame:t,src:e.href,invokeCommand:st.invokeCommand}:o&&o!=="_self"?(t=document.getElementById(o),{name:"frame",reason:"element targets a frame that is not _self",frame:t,src:I(e,t),invokeCommand:ae.invokeCommand}):(!o||o==="_self")&&t?{name:"frame",reason:"element does NOT target a frame or targets _self and is contained by a frame",frame:t,src:I(e,t),invokeCommand:ae.invokeCommand}:{name:"window",reason:"element matches one or more of the following conditions (targets _top, does NOT target a frame, is NOT contained by a frame)",frame:null,src:I(e),invokeCommand:dt.invokeCommand}}var de={find:ct},q="unknown",be={debug:Object.values(h),info:Object.values(h),warn:[h.abort,h.clientError,h.serverError],error:[h.clientError,h.serverError],unknown:[]};Object.values(h).forEach(e=>{addEventListener(e,t=>{if(be[q].includes(t.type)){let{target:o,detail:r}=t;console[q](t.type,{target:o,detail:r})}})});var ut={get level(){return q},set level(e){return Object.keys(be).includes(e)||(e="unknown"),q=e}};function mt(){return([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,e=>(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16))}var ht={v4:mt};function ce(e,t){return{id:e,name:t.getAttribute(u.commandAttribute),elementId:t.id.length>0?t.id:null,elementAttributes:J.buildAttributePayload(t),startedAt:Date.now()}}async function gt(e){let t,o={};try{if(t=J.findClosestCommand(e.target),!t||!p.isRegisteredForElement(e.type,t))return;let r=`turbo-command-${ht.v4()}`,n=de.find(t),s=b(l({},ce(r,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),i=await m(c.start,t,{cancelable:!0,detail:s});if(i.defaultPrevented||i.detail.confirmation&&e.defaultPrevented)return m(c.abort,t,{detail:{message:`An event handler for '${c.start}' prevented default behavior and blocked command invocation!`,source:i}});switch(n=de.find(t),s=b(l({},ce(r,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),me.add(s),["frame","window"].includes(n.name)&&e.preventDefault(),d.busy=!0,setTimeout(()=>d.busy=!1,10),n.name){case"method":return n.invokeCommand(t,s);case"form":return n.invokeCommand(t,s);case"frame":return n.invokeCommand(n.frame,s);case"window":return n.invokeCommand(s)}}catch(r){m(c.clientError,t,{detail:b(l({},o),{error:r})})}}self.TurboBoost=self.TurboBoost||{};self.TurboBoost=b(l({},self.TurboBoost),{stateEvents:f,get state(){return j.current},get stateDelta(){return j.delta}});self.TurboBoost.Commands||(p.handler=gt,p.register("click",[`[${u.commandAttribute}]`]),p.register("submit",[`form[${u.commandAttribute}]`]),p.register("change",[`input[${u.commandAttribute}]`,`select[${u.commandAttribute}]`,`textarea[${u.commandAttribute}]`]),self.TurboBoost.Commands={confirmation:Je,logger:ut,schema:u,events:c,registerEventDelegate:p.register,get eventDelegates(){return p.events}});var Nt=self.TurboBoost.Commands;var bt=Object.defineProperty,pt=Object.defineProperties,ft=Object.getOwnPropertyDescriptors,pe=Object.getOwnPropertySymbols,vt=Object.prototype.hasOwnProperty,yt=Object.prototype.propertyIsEnumerable,fe=(e,t,o)=>t in e?bt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,k=(e,t)=>{for(var o in t||(t={}))vt.call(t,o)&&fe(e,o,t[o]);if(pe)for(var o of pe(t))yt.call(t,o)&&fe(e,o,t[o]);return e},T=(e,t)=>pt(e,ft(t));function Et(e){let t=document.createElement("template");return t.innerHTML=e,t}function ee(e,t){t=t||document.body;let o=Et(e).content.cloneNode(!0).querySelector("*");return t.appendChild(o)}function V(e,t={}){if(!e)return;Y(e);let{outline:o,outlineOffset:r}=t;o=o||"dashed 3px red",r=r||"0px",e.originalStyles=e.originalStyles||{display:e.style.display,minHeight:e.style.minHeight,minWidth:e.style.minWidth,outline:e.style.outline,outlineOffset:e.style.outlineOffset},getComputedStyle(e).display.match(/^inline$/i)&&e.offsetWidth===0&&e.offsetHeight===0&&(e.style.display="inline-block",e.style.minHeight="2px",e.style.minWidth="2px"),e.style.outline=o,e.style.outlineOffset=r,e.dataset.turboBoostHighlight=!0}function Y(e){if(e){if(e.originalStyles){for(let[t,o]of Object.entries(e.originalStyles))o?e.style[t]=o:e.style[t]="";delete e.originalStyles}delete e.dataset.turboBoostHighlight}}function U(e){if(!e)return{};let t=e.getBoundingClientRect(),o=e.offsetWidth,r=e.offsetHeight,n=t.top+window.scrollY,s=t.left+window.scrollX,i=s+o,L=n+r;return{top:n,left:s,right:i,bottom:L,width:o,height:r}}function $(e){try{e()}catch(t){}}var wt=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}),this.shadowRoot.innerHTML=this.html,this.labelElement.addEventListener("click",e=>{e.preventDefault(),this.toggle()}),this.checkboxElement.addEventListener("change",e=>this.dispatchEvent(new CustomEvent("change",{bubbles:!0})))}toggle(){this.checked?this.uncheck():this.check()}check(){this.checkboxElement.checked=!0,this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))}uncheck(){this.checkboxElement.checked=!1,this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))}get name(){return this.getAttribute("name")}get checked(){return this.checkboxElement.checked}get checkboxElement(){return this.shadowRoot.querySelector("input")}get labelElement(){return this.shadowRoot.querySelector("label")}get html(){return`
|
1
|
+
var Fe=Object.defineProperty,We=Object.defineProperties,Xe=Object.getOwnPropertyDescriptors,ue=Object.getOwnPropertySymbols,Je=Object.prototype.hasOwnProperty,Ge=Object.prototype.propertyIsEnumerable,ce=(e,t,o)=>t in e?Fe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,l=(e,t)=>{for(var o in t||(t={}))Je.call(t,o)&&ce(e,o,t[o]);if(ue)for(var o of ue(t))Ge.call(t,o)&&ce(e,o,t[o]);return e},p=(e,t)=>We(e,Xe(t)),Ve=class{get element(){return document.querySelector('meta[name="turbo-boost"]')}get token(){return this.element.getAttribute("content")}get busy(){return this.element.dataset.busy==="true"}set busy(e){return this.element.dataset.busy=!!e}},d=new Ve,u={start:"turbo-boost:command:start",success:"turbo-boost:command:success",finish:"turbo-boost:command:finish",abort:"turbo-boost:command:abort",clientError:"turbo-boost:command:client-error",serverError:"turbo-boost:command:server-error"},v={stateLoad:"turbo-boost:state:load",stateChange:"turbo-boost:state:change"},g=l(l({},u),v);function h(e,t,o={}){return new Promise(r=>{o=o||{},o.detail=o.detail||{},t=t||document;let n=new CustomEvent(e,p(l({},o),{bubbles:!0}));t.dispatchEvent(n),r(n)})}var W;function q(e,t=null){if(!e||typeof e!="object")return e;let o=new Proxy(e,{deleteProperty(r,n){return delete r[n],h(v.stateChange,d.element,{detail:{state:W}}),!0},set(r,n,i,s){return r[n]=q(i,this),h(v.stateChange,d.element,{detail:{state:W}}),!0}});if(Array.isArray(e))e.forEach((r,n)=>e[n]=q(r,o));else if(typeof e=="object")for(let[r,n]of Object.entries(e))e[r]=q(n,o);return t||(W=o),o}var Ue=q,U,k,$,he;function pe(){if(!d.element)return T();let e=atob(d.element.dataset.state);$={},k=Ue(JSON.parse(e)),U=l({},k),delete d.element.dataset.clientStateChange,setTimeout(()=>h(v.stateLoad,d.element,{detail:{state:k}}))}function T(){clearTimeout(he),he=setTimeout(pe,10)}U||pe();addEventListener("DOMContentLoaded",T);addEventListener("load",T);addEventListener("turbo:load",T);addEventListener("turbo:frame-load",T);addEventListener(u.success,T);addEventListener(v.stateChange,e=>{$={};for(let[t,o]of Object.entries(k))U[t]!==o&&($[t]=o);d.element.dataset.clientStateChange=!0,d.element.dataset.state=btoa(JSON.stringify(k))});var M={events:v,get current(){return k},get delta(){return $},get payloadChunks(){return btoa(JSON.stringify($)).match(/.{1,2000}/g)}};function Ke(e){let t="<html",o="</html",r=e.indexOf(t),n=e.lastIndexOf(o);if(r>=0&&n>=0){let i=e.slice(e.indexOf(">",r)+1,n);document.documentElement.innerHTML=i}}function Qe(e){document.body.insertAdjacentHTML("beforeend",e)}var O={append:Qe,replaceDocument:Ke},P={};function Ye(e){P[e.id]=e}function Ze(e){delete P[e]}var fe={add:Ye,remove:Ze,get commands(){return[...Object.values(P)]},get length(){return Object.keys(P).length}};function ve(e){e.detail.endedAt=Date.now(),e.detail.milliseconds=e.detail.endedAt-e.detail.startedAt,setTimeout(()=>h(u.finish,e.target,{detail:e.detail}),25)}addEventListener(u.serverError,ve);addEventListener(u.success,ve);addEventListener(u.finish,e=>fe.remove(e.detail.id),!0);var K={events:u},J={};addEventListener("turbo:before-fetch-request",e=>{let t=e.target.closest("turbo-frame"),{fetchOptions:o}=e.detail;if(d.busy){let r=["text/vnd.turbo-boost.html",o.headers.Accept];r=r.filter(n=>n&&n.trim().length>0).join(", "),o.headers.Accept=r,o.headers["TurboBoost-Token"]=d.token}M.payloadChunks.forEach((r,n)=>{o.headers[`TurboBoost-State-${n.toString().padStart(4,"0")}`]=r})});addEventListener("turbo:before-fetch-response",e=>{let t=e.target.closest("turbo-frame"),{fetchResponse:o}=e.detail;if(t&&(J[t.id]=t.src),o.header("TurboBoost")){if(o.statusCode<200||o.statusCode>399){let r=`Server returned a ${o.statusCode} status code! TurboBoost Commands require 2XX-3XX status codes.`;h(K.events.clientError,document,{detail:p(l({},e.detail),{error:r})},!0)}o.header("TurboBoost")==="Append"&&(e.preventDefault(),o.responseText.then(r=>O.append(r)))}});addEventListener("turbo:frame-load",e=>{let t=e.target.closest("turbo-frame");t.dataset.turboBoostSrc=J[t.id]||t.src||t.dataset.turboBoostSrc,delete J[t.id]});var et={frameAttribute:"data-turbo-frame",methodAttribute:"data-turbo-method",commandAttribute:"data-turbo-command",confirmAttribute:"data-turbo-confirm"},c=l({},et),ye={method:e=>Promise.resolve(confirm(e))},tt=e=>e.detail.driver==="method",ot=e=>{if(e.detail.driver!=="form")return!1;let t=e.target,o=t.closest("turbo-frame"),r=t.closest(`[${c.frameAttribute}]`);return!!(o||r)},rt=e=>tt(e)||ot(e);document.addEventListener(u.start,async e=>{let t=e.target.getAttribute(c.confirmAttribute);!t||(e.detail.confirmation=!0,rt(e))||await ye.method(t)||e.preventDefault()});var nt=ye,b=[],G;function it(e,t){let o=b.find(r=>r.name===e);return o&&b.splice(b.indexOf(o),1),b=[{name:e,selectors:t},...b],document.removeEventListener(e,G,!0),document.addEventListener(e,G,!0),l({},b.find(r=>r.name===e))}function st(e){return b.find(t=>t.selectors.find(o=>Array.from(document.querySelectorAll(o)).find(r=>r===e)))}function lt(e,t){let o=st(t);return o&&o.name===e}var f={register:it,isRegisteredForElement:lt,get events(){return[...b]},set handler(e){G=e}};function at(e){return e.closest(`[${c.commandAttribute}]`)}function dt(e){return e.closest("turbo-frame[src]")||e.closest("turbo-frame[data-turbo-frame-src]")||e.closest("turbo-frame")}function ut(e,t={}){if(e.tagName.toLowerCase()!=="select")return t.value=e.value||null;if(!e.multiple)return t.value=e.options[e.selectedIndex].value;t.values=Array.from(e.options).reduce((o,r)=>(r.selected&&o.push(r.value),o),[])}function ct(e){let t=Array.from(e.attributes).reduce((o,r)=>{let n=r.value;return o[r.name]=n,o},{});return t.tag=e.tagName,t.checked=!!e.checked,t.disabled=!!e.disabled,ut(e,t),delete t.class,delete t.action,delete t.href,delete t[c.commandAttribute],delete t[c.frameAttribute],t}var Q={buildAttributePayload:ct,findClosestCommand:at,findClosestFrameWithSource:dt};function ht(e,t={}){t.token=d.token;let o=document.createElement("input");o.type="hidden",o.name="turbo_boost_command",o.value=JSON.stringify(t),e.appendChild(o)}var mt={invokeCommand:ht};function gt(e,t={}){let o=document.createElement("a");o.href=e;let r=new URL(o);return r.searchParams.set("turbo_boost_command",JSON.stringify(t)),r}var Y={build:gt};function bt(e,t){let o=t.src;t=l({},t),delete t.src,e.src=Y.build(o,t)}var me={invokeCommand:bt};function pt(e,t={}){let o=t.src;t=l({},t),delete t.src,delete t.href,e.setAttribute("href",Y.build(o,t))}var ft={invokeCommand:pt};function vt(e){let t=e.target;h(K.events.abort,document,{detail:p(l({},e.detail),{xhr:t})})}function V(e){let t=e.target;t.getResponseHeader("TurboBoost")==="Append"||t.getResponseHeader("Content-Type").startsWith("text/vnd.turbo-boost.html")?O.append(t.responseText):O.replaceDocument(t.responseText);let o=`Server returned a ${t.status} status code! TurboBoost Commands require 2XX-3XX status codes.`;h(K.events.clientError,document,{detail:p(l({},e.detail),{error:o,xhr:t})},!0)}function yt(e){let t=e.target;if(t.status<200||t.status>399)return V(e);let o=t.responseText;t.getResponseHeader("TurboBoost")==="Append"||t.getResponseHeader("Content-Type").startsWith("text/vnd.turbo-boost.html")?O.append(t.responseText):O.replaceDocument(t.responseText)}function Et(e){let t=e.src;e=l({},e),delete e.src;try{let o=new XMLHttpRequest;o.open("GET",Y.build(t,e),!0),o.setRequestHeader("Accept","text/vnd.turbo-boost.html, text/html, application/xhtml+xml"),o.setRequestHeader("TurboBoost-Token",d.token),M.payloadChunks.forEach((r,n)=>o.setRequestHeader(`TurboBoost-State-${n.toString().padStart(4,"0")}`,r)),o.addEventListener("abort",vt),o.addEventListener("error",V),o.addEventListener("load",yt),o.send()}catch(o){let r=`Unexpected error sending HTTP request! ${o.message}`;V(o,{detail:{message:r}})}}var wt={invokeCommand:Et};function X(e,t){return t=t||{dataset:{}},e.href||t.src||t.dataset.turboBoostSrc||location.href}function kt(e){let t=Q.findClosestFrameWithSource(e),{turboFrame:o,turboMethod:r}=e.dataset;return e.tagName.toLowerCase()==="form"?{name:"form",reason:"Element is a form.",frame:t,src:e.action,invokeCommand:mt.invokeCommand}:r&&r.length>0?{name:"method",reason:"Element defines data-turbo-method.",frame:t,src:e.href,invokeCommand:ft.invokeCommand}:o&&o!=="_self"?(t=document.getElementById(o),{name:"frame",reason:"element targets a frame that is not _self",frame:t,src:X(e,t),invokeCommand:me.invokeCommand}):(!o||o==="_self")&&t?{name:"frame",reason:"element does NOT target a frame or targets _self and is contained by a frame",frame:t,src:X(e,t),invokeCommand:me.invokeCommand}:{name:"window",reason:"element matches one or more of the following conditions (targets _top, does NOT target a frame, is NOT contained by a frame)",frame:null,src:X(e),invokeCommand:wt.invokeCommand}}var ge={find:kt},N="unknown",Ee={debug:Object.values(g),info:Object.values(g),warn:[g.abort,g.clientError,g.serverError],error:[g.clientError,g.serverError],unknown:[]};Object.values(g).forEach(e=>{addEventListener(e,t=>{if(Ee[N].includes(t.type)){let{target:o,detail:r}=t;console[N](t.type,{target:o,detail:r})}})});var Tt={get level(){return N},set level(e){return Object.keys(Ee).includes(e)||(e="unknown"),N=e}};function xt(){return([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,e=>(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16))}var Lt={v4:xt};function be(e,t){return{id:e,name:t.getAttribute(c.commandAttribute),elementId:t.id.length>0?t.id:null,elementAttributes:Q.buildAttributePayload(t),startedAt:Date.now()}}async function St(e){let t,o={};try{if(t=Q.findClosestCommand(e.target),!t||!f.isRegisteredForElement(e.type,t))return;let r=`turbo-command-${Lt.v4()}`,n=ge.find(t),i=p(l({},be(r,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),s=await h(u.start,t,{cancelable:!0,detail:i});if(s.defaultPrevented||s.detail.confirmation&&e.defaultPrevented)return h(u.abort,t,{detail:{message:`An event handler for '${u.start}' prevented default behavior and blocked command invocation!`,source:s}});switch(n=ge.find(t),i=p(l({},be(r,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),fe.add(i),["frame","window"].includes(n.name)&&e.preventDefault(),d.busy=!0,setTimeout(()=>d.busy=!1,10),n.name){case"method":return n.invokeCommand(t,i);case"form":return n.invokeCommand(t,i);case"frame":return n.invokeCommand(n.frame,i);case"window":return n.invokeCommand(i)}}catch(r){h(u.clientError,t,{detail:p(l({},o),{error:r})})}}self.TurboBoost=self.TurboBoost||{};self.TurboBoost=p(l({},self.TurboBoost),{stateEvents:v,get state(){return M.current},get stateDelta(){return M.delta}});self.TurboBoost.Commands||(f.handler=St,f.register("click",[`[${c.commandAttribute}]`]),f.register("submit",[`form[${c.commandAttribute}]`]),f.register("change",[`input[${c.commandAttribute}]`,`select[${c.commandAttribute}]`,`textarea[${c.commandAttribute}]`]),self.TurboBoost.Commands={confirmation:nt,logger:Tt,schema:c,events:u,registerEventDelegate:f.register,get eventDelegates(){return f.events}});var Qt=self.TurboBoost.Commands;var Ct=Object.defineProperty,At=Object.defineProperties,$t=Object.getOwnPropertyDescriptors,we=Object.getOwnPropertySymbols,Ot=Object.prototype.hasOwnProperty,Dt=Object.prototype.propertyIsEnumerable,ke=(e,t,o)=>t in e?Ct(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,x=(e,t)=>{for(var o in t||(t={}))Ot.call(t,o)&&ke(e,o,t[o]);if(we)for(var o of we(t))Dt.call(t,o)&&ke(e,o,t[o]);return e},L=(e,t)=>At(e,$t(t)),m=(e,t)=>()=>(e&&(t=e(e=0)),t);function Bt(e){let t=document.createElement("template");return t.innerHTML=e,t}function se(e,t){t=t||document.body;let o=Bt(e).content.cloneNode(!0).querySelector("*");return t.appendChild(o)}function Z(e,t={}){if(!e)return;re(e);let{outline:o,outlineOffset:r}=t;o=o||"dashed 3px red",r=r||"0px",e.originalStyles=e.originalStyles||{display:e.style.display,minHeight:e.style.minHeight,minWidth:e.style.minWidth,outline:e.style.outline,outlineOffset:e.style.outlineOffset},getComputedStyle(e).display.match(/^inline$/i)&&e.offsetWidth===0&&e.offsetHeight===0&&(e.style.display="inline-block",e.style.minHeight="2px",e.style.minWidth="2px"),e.style.outline=o,e.style.outlineOffset=r,e.dataset.turboBoostHighlight=!0}function re(e){if(e){if(e.originalStyles){for(let[t,o]of Object.entries(e.originalStyles))o?e.style[t]=o:e.style[t]="";delete e.originalStyles}delete e.dataset.turboBoostHighlight}}function ee(e){if(!e)return{};let t=e.getBoundingClientRect(),o=e.offsetWidth,r=e.offsetHeight,n=t.top+window.scrollY,i=t.left+window.scrollX,s=i+o,C=n+r;return{top:n,left:i,right:s,bottom:C,width:o,height:r}}function D(e){try{e()}catch(t){}}var le=m(()=>{}),$e,Ht=m(()=>{$e=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}),this.shadowRoot.innerHTML=this.html,this.labelElement.addEventListener("click",e=>{e.preventDefault(),this.toggle()}),this.checkboxElement.addEventListener("change",e=>this.dispatchEvent(new CustomEvent("change",{bubbles:!0})))}toggle(){this.checked?this.uncheck():this.check()}check(){this.checkboxElement.checked=!0,this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))}uncheck(){this.checkboxElement.checked=!1,this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))}get name(){return this.getAttribute("name")}get checked(){return this.checkboxElement.checked}get checkboxElement(){return this.shadowRoot.querySelector("input")}get labelElement(){return this.shadowRoot.querySelector("label")}get html(){return`
|
2
2
|
<style>${this.stylesheet}</style>
|
3
3
|
<div>
|
4
4
|
<input name="checkbox" type="checkbox">
|
@@ -21,7 +21,7 @@ var Be=Object.defineProperty,De=Object.defineProperties,He=Object.getOwnProperty
|
|
21
21
|
label {
|
22
22
|
color: black;
|
23
23
|
}
|
24
|
-
`}},
|
24
|
+
`}}}),Oe,Rt=m(()=>{le(),Oe=class extends HTMLElement{constructor(){super(),this.enabledDevtools={},this.attachShadow({mode:"open"}),this.shadowRoot.innerHTML=this.html,this.shadowRoot.querySelector("button").addEventListener("click",()=>this.dispatchEvent(new CustomEvent("turbo-boost:devtools-close",{bubbles:!0}))),this.addEventListener("change",e=>{let t=e.target,{checked:o,name:r}=t;o?this.enableDevtool(r):this.disableDevtool(r)})}enableDevtool(e){this.enabledDevtools[e]||(this.enabledDevtools[e]=!0,this.dispatchEvent(new CustomEvent("turbo-boost:devtool-enable",{bubbles:!0,detail:{name:e}})))}disableDevtool(e){this.enabledDevtools[e]&&(delete this.enabledDevtools[e],this.dispatchEvent(new CustomEvent("turbo-boost:devtool-disable",{bubbles:!0,detail:{name:e}})))}close(){this.devtoolElements.forEach(e=>{e.checked&&e.uncheck()}),this.remove()}get devtoolElements(){return this.querySelectorAll('[slot="devtool"]')}get closeElement(){return this.querySelector("button")}get html(){return`
|
25
25
|
<style>${this.stylesheet}</style>
|
26
26
|
<div>
|
27
27
|
<img src="https://ik.imagekit.io/hopsoft/turbo-boost-logo_zHiiimlvT.webp?ik-sdk-version=javascript-1.4.3&updatedAt=1671722004342">
|
@@ -89,7 +89,7 @@ var Be=Object.defineProperty,De=Object.defineProperties,He=Object.getOwnProperty
|
|
89
89
|
button:hover {
|
90
90
|
opacity: 1;
|
91
91
|
}
|
92
|
-
`}},
|
92
|
+
`}}}),De,jt=m(()=>{De=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}),this.shadowRoot.innerHTML=this.html}connectedCallback(){let e=localStorage.getItem(`turbo-boost-devtools-${location.href}-${this.id}-transform`);e&&(this.style.transform=e)}disconnectedCallback(){this.id!=="undefined"&&this.id!==""&&localStorage.setItem(`turbo-boost-devtools-${location.href}-${this.id}-transform`,this.style.transform)}get color(){return this.getAttribute("color")||"darkslategray"}get backgroundColor(){return this.getAttribute("background-color")||"gainsboro"}get position(){return this.getAttribute("position")||"top"}get html(){return`
|
93
93
|
<style>${this.stylesheet}</style>
|
94
94
|
<div role="container">
|
95
95
|
<div role="title">
|
@@ -183,38 +183,59 @@ var Be=Object.defineProperty,De=Object.defineProperties,He=Object.getOwnProperty
|
|
183
183
|
slot[name="content-bottom"] {
|
184
184
|
color: red;
|
185
185
|
}
|
186
|
-
`}}
|
186
|
+
`}}});function qt(e){return e.global&&self[e.global]||document.querySelector(`[src='${e.src}']`)?!0:y.includes(e)}function Mt(e){if(qt(e))return;y.push(e);let{src:t,integrity:o}=e,r=document.createElement("script");r.setAttribute("src",t),r.setAttribute("crossorigin","anonymous"),r.setAttribute("referrerpolicy","no-referrer"),o&&r.setAttribute("integrity",o),document.head.appendChild(r)}function Be(e){if(!y.includes(e))return;y.splice(y.indexOf(e),1);let{src:t}=e,o=document.querySelector(`script[src='${t}']`);o&&o.remove(),e.global&&self[e.global]&&(self[e.global]=null)}function Pt(){[...y].forEach(e=>Be(e))}var y,Te,S,Nt=m(()=>{y=[],Te={LeaderLine:{src:"https://cdnjs.cloudflare.com/ajax/libs/leader-line/1.0.7/leader-line.min.js",integrity:"sha512-0dNdzMjpT6pJdFGF1DwybFCfm3K/lzHhxaMXC/92J9/DZujHlqYFqmhTOAoD0o+LkeEsVK2ar/ESs7/Q2B6wJg==",global:"LeaderLine"},PlainDraggable:{src:"https://cdn.jsdelivr.net/npm/plain-draggable@2.5.14/plain-draggable.min.js",global:"PlainDraggable"}},S=L(x({},Te),{add:Mt,remove:Be,removeAll:Pt})});function He(){if(a)try{new PlainDraggable(a)}catch(e){setTimeout(He,200)}}function ne(){je()||(a.close(),a.dispatchEvent(new CustomEvent("turbo-boost:devtools-stop",{bubbles:!0})),a=null,S.removeAll())}function Re(){_()||(S.add(S.LeaderLine),S.add(S.PlainDraggable),a=se("<turbo-boost-devtool-supervisor></turbo-boost-devtool-supervisor>"),setTimeout(He,200),a.dispatchEvent(new CustomEvent("turbo-boost:devtools-start",{bubbles:!0})))}function It(){let e=a?Object.keys(a.enabledDevtools):[];ne(),Re(),a.devtoolElements.forEach(t=>{e.includes(t.name)&&t.check()})}function _(){return!!a}function je(){return!_()}function qe(){clearTimeout(xe),xe=setTimeout(It,25)}function B(){_()&&qe()}function zt(e,t){if(a)return se(`
|
187
187
|
<turbo-boost-devtool name="${e}" slot="devtool">
|
188
188
|
<span slot="label">${t}</span>
|
189
189
|
</turbo-boost-devtool>
|
190
|
-
`,a)}function
|
191
|
-
<turbo-boost-devtool-tooltip id="${
|
190
|
+
`,a)}function _t(e){return a?a.enabledDevtools[e]:!1}var a,xe,I,Me=m(()=>{le(),Ht(),Rt(),jt(),Nt(),customElements.define("turbo-boost-devtool",$e),customElements.define("turbo-boost-devtool-supervisor",Oe),customElements.define("turbo-boost-devtool-tooltip",De),addEventListener("turbo:load",B),addEventListener("turbo-frame:load",B),addEventListener("turbo-boost:devtools-connect",B),addEventListener("turbo-boost:devtools-close",ne),window.TurboBoost&&(addEventListener(TurboBoost.Commands.events.success,B),addEventListener(TurboBoost.Commands.events.finish,B)),I={enabled:_t,register:zt,start:Re,stop:ne,restart:qe,get started(){return _()},get stopped(){return je()}}});function te(e,t,o,r={}){let{backgroundColor:n,color:i,position:s,id:C}=r;return i=i||"white",s=s||"top",se(`
|
191
|
+
<turbo-boost-devtool-tooltip id="${C}" position="${s}" background-color="${n}" color="${i}">
|
192
192
|
<div slot='title'>${e}</div>
|
193
193
|
<div slot='subtitle'>${t}</div>
|
194
194
|
${o}
|
195
195
|
</turbo-boost-devtool-tooltip>
|
196
|
-
`)}var
|
196
|
+
`)}var oe,H,Ft=m(()=>{Me(),le(),H=class{constructor(e){this.delegate=e;let t,o=()=>{clearTimeout(t),t=setTimeout(this.hide({active:!1}),25)};this.eventListeners["turbo-boost:devtool-enable"]=r=>{let{name:n}=r.detail;n===this.delegate.name&&(Z(this.delegate.triggerElement,{outline:"3px dashed blueviolet",outlineOffset:"2px"}),this.hide({active:!1}),this.active&&this.show())},this.eventListeners["turbo-boost:devtool-disable"]=r=>{let{name:n}=r.detail;n===this.delegate.name&&re(this.delegate.triggerElement)},this.eventListeners.click=r=>{r.target.closest("turbo-boost-devtool-tooltip")||o()},this.eventListeners["turbo:load"]=o,this.eventListeners["turbo-frame:load"]=o,window.TurboBoost&&(this.eventListeners[TurboBoost.Commands.events.finish]=o),this.registerEventListeners()}registerEventListeners(){Object.entries(this.eventListeners).forEach(([e,t])=>{addEventListener(e,t)})}unregisterEventListeners(){Object.entries(this.eventListeners).forEach(([e,t])=>{removeEventListener(e,t)})}get eventListeners(){return this._eventListeners||(this._eventListeners={})}show(){if(!this.enabled||this.active)return;this.active=!0,this.hide({active:!0}),Z(this.delegate.targetElement,{outline:"3px dashed darkcyan",outlineOffset:"-2px"}),Z(this.delegate.morphElement,{outline:"3px dashed chocolate",outlineOffset:"3px"}),this.renderingTooltip=this.createRenderingTooltip(),this.targetTooltip=this.createTargetTooltip(),this.triggerTooltip=this.createTriggerTooltip(this.targetTooltip,this.renderingTooltip),document.querySelectorAll(".leader-line").forEach(t=>t.style.zIndex=1e5);let e={morph:{partial:this.delegate.triggerElement.renders,id:this.delegate.triggerElement.morphs,status:this.delegate.morphElement?"OK":"Not Found"},trigger:{partial:null,id:null,status:"Not Found"},target:{partial:null,id:null,status:"Not Found"}};this.delegate.triggerElement&&(e.trigger={partial:this.delegate.triggerElement.partial,id:this.delegate.triggerElement.id,status:"OK"},e.target.id=this.delegate.triggerElement.controls),this.delegate.targetElement&&(e.target={partial:this.delegate.targetElement.partial,dom_id:this.delegate.targetElement.id,status:"OK"}),console.table(e)}hide({active:e=!1}){document.querySelectorAll("turbo-boost-devtool-tooltip").forEach(t=>{D(()=>t.line.remove()),D(()=>t.drag.remove()),D(()=>t.lineToRendering.remove()),D(()=>t.lineToTarget.remove()),D(()=>t.remove())}),document.querySelectorAll("[data-turbo-boost-highlight]").forEach(t=>{t.tagName.match(/turbo-boost-toggle-trigger/i)||re(t)}),this.active=e}get active(){return oe===this.delegate}set active(e){e?oe=this.delegate:oe=null}get enabled(){return I.enabled(this.delegate.name)}static register(e,t){I.register(e,t)}createRenderingTooltip(){if(!this.delegate.triggerElement.renders)return console.debug("Unable to create the rendering tooltip! The trigger element must set the 'renders' attribute.");if(!this.delegate.triggerElement.morphs)return console.debug(`Unable to create the rendering tooltip! The trigger element specified the 'morphs' attrbiute but no element matches the DOM id: '${this.triggerElement.morphs}'`);let e=`
|
197
197
|
<svg xmlns="http://www.w3.org/2000/svg" style="display:inline-block;" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 19l7-7 3 3-7 7-3-3z"></path><path d="M18 13l-1.5-7.5L2 2l3.5 14.5L13 18l5-5z"></path><path d="M2 2l7.586 7.586"></path><circle cx="11" cy="11" r="2"></circle></svg>
|
198
198
|
RENDERING - <${this.delegate.triggerElement.tagName.toLowerCase()}>
|
199
199
|
`,t=`
|
200
200
|
<b>partial</b>: ${this.delegate.triggerElement.renders||"unknown"}<br>
|
201
201
|
<b>morphs</b>: ${this.delegate.triggerElement.morphs||"unknown"}<br>
|
202
|
-
`,o=
|
202
|
+
`,o=te(e,t,`
|
203
203
|
<div slot="content-top" style="font-size:85%; font-style:italic; font-weight:100;">
|
204
204
|
The <b>TRIGGER</b> toggles the <b>TARGET</b> then renders the partial & morphs the element.<br>
|
205
205
|
</div>
|
206
|
-
`,{id:`${this.delegate.id}-rendering`,backgroundColor:"lightyellow",color:"chocolate"}),r=
|
206
|
+
`,{id:`${this.delegate.id}-rendering`,backgroundColor:"lightyellow",color:"chocolate"}),r=ee(this.delegate.morphElement),n=Math.ceil(r.top+r.height/2-o.offsetHeight/2),i=Math.ceil(r.left+r.width+100);return o.style.top=`${n}px`,o.style.left=`${i}px`,o.line=new LeaderLine(o,this.delegate.morphElement,L(x({},this.leaderLineOptions),{color:"chocolate"})),o.drag=new PlainDraggable(o),o}createTargetTooltip(){var e,t;if(!this.delegate.targetElement)return console.debug(`Unable to create the target tooltip! No element matches the DOM id: '${this.delegate.triggerElement.controls}'`);let o=`
|
207
207
|
<svg xmlns="http://www.w3.org/2000/svg" style="display:inline-block;" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><circle cx="12" cy="12" r="6"></circle><circle cx="12" cy="12" r="2"></circle></svg>
|
208
208
|
TARGET - <${this.delegate.targetElement.tagName.toLowerCase()}>
|
209
|
-
`,r=
|
209
|
+
`,r=te(o,((e=this.delegate.targetTooltipData)==null?void 0:e.subtitle)||"",((t=this.delegate.targetTooltipData)==null?void 0:t.content)||"",{id:`${this.delegate.id}-target`,backgroundColor:"lightcyan",color:"darkcyan",position:"bottom"}),n=ee(this.delegate.targetElement),i=Math.ceil(n.top+r.offsetHeight),s=Math.ceil(n.left+n.width+r.offsetWidth/3);return r.style.top=`${i}px`,r.style.left=`${s}px`,r.line=new LeaderLine(r,this.delegate.targetElement,L(x({},this.leaderLineOptions),{color:"darkcyan"})),r.drag=new PlainDraggable(r),r}createTriggerTooltip(e,t){var o,r;if(!this.delegate.triggerElement)return;let n=`
|
210
210
|
<svg xmlns="http://www.w3.org/2000/svg" style="display:inline;" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><polygon points="13 2 3 14 12 14 11 22 21 10 12 10 13 2"></polygon></svg>
|
211
211
|
TRIGGER - <${this.delegate.triggerElement.tagName.toLowerCase()}>
|
212
|
-
`,
|
212
|
+
`,i=te(n,((o=this.delegate.triggerTooltipData)==null?void 0:o.subtitle)||"",((r=this.delegate.triggerTooltipData)==null?void 0:r.content)||"",{id:`${this.delegate.id}-trigger`,backgroundColor:"lavender",color:"blueviolet"}),s=ee(this.delegate.triggerElement),C=Math.ceil(s.top-i.offsetHeight*2),_e=Math.ceil(s.left+s.width+i.offsetWidth/3);return i.style.top=`${C}px`,i.style.left=`${_e}px`,i.line=new LeaderLine(this.delegate.triggerElement,i,L(x({},this.leaderLineOptions),{color:"blueviolet"})),e&&(i.lineToTarget=new LeaderLine(i,e,L(x({},this.leaderLineOptions),{color:"blueviolet",middleLabel:this.delegate.targetLineLabel,size:2.1})),e.drag.onMove=()=>{var A,de;e.line.position(),(A=i.lineToTarget)==null||A.position(),(de=i.lineToRendering)==null||de.position()}),t&&(i.lineToRendering=new LeaderLine(i,t,L(x({},this.leaderLineOptions),{color:"blueviolet",middleLabel:this.delegate.renderingLineLabel,size:2.1})),t.drag.onMove=()=>{var A;t.line.position(),i.lineToTarget&&i.lineToTarget.position(),(A=i.lineToRendering)==null||A.position()}),i.drag=new PlainDraggable(i),i.drag.onMove=()=>{i.line.position(),i.lineToTarget&&i.lineToTarget.position(),i.lineToRendering&&i.lineToRendering.position()},i}get leaderLineOptions(){return{dash:{animation:!0},dropShadow:{opacity:.3},endPlug:"arrow3",endPlugSize:1.7,size:3,startPlug:"disc",startPlugSize:1}}}}),Wt={};function Le(e){Object.defineProperties(e,{targetTooltipData:{get(){return{subtitle:`
|
213
|
+
<b>identifier</b>: ${e.identifier}<br>
|
214
|
+
<b>query</b>: ${e.query}
|
215
|
+
`,content:`
|
216
|
+
<div slot="content-top">
|
217
|
+
<svg xmlns="http://www.w3.org/2000/svg" style="display:inline-block;" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentcolor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><polygon points="12 2 2 7 12 12 22 7 12 2"></polygon><polyline points="2 17 12 22 22 17"></polyline><polyline points="2 12 12 17 22 12"></polyline></svg>
|
218
|
+
<b>element log</b>
|
219
|
+
</div>
|
220
|
+
${e.targetElementLog.queue.slice(-10).map(t=>`<div slot="content">${t}</div>`).join("")}
|
221
|
+
`}}},triggerTooltipData:{get(){return{subtitle:`
|
222
|
+
<b>identifier</b>: ${this.identifier}<br>
|
223
|
+
<b>only</b>: ${this.getAttribute("only")||""}<br>
|
224
|
+
<b>url</b>: ${this.getAttribute("url")||location.href}<br>
|
225
|
+
<b>debounce (client-side)</b>: ${this.debounce}<br>
|
226
|
+
<b>ignore-inner-updates</b>: ${this.hasAttribute("ignore-inner-updates")}
|
227
|
+
`,content:`
|
228
|
+
<div slot="content-top">
|
229
|
+
<svg xmlns="http://www.w3.org/2000/svg" style="display:inline-block;" width="16" height="16" viewbox="0 0 24 24" fill="none" stroke="currentcolor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><polygon points="12 2 2 7 12 12 22 7 12 2"></polygon><polyline points="2 17 12 22 22 17"></polyline><polyline points="2 12 12 17 22 12"></polyline></svg>
|
230
|
+
<b>element log</b>
|
231
|
+
</div>
|
232
|
+
${e.triggerElementLog.queue.slice(-10).map(t=>`<div slot="content">${t}</div>`).join("")}
|
233
|
+
`}}}})}function Xt(){document.addEventListener("turbo-boost:devtools-start",()=>H.register("updates-for","updates-for")),window.CableReady.devtools=F,document.addEventListener("turbo:load",()=>{document.querySelectorAll("updates-for").forEach(e=>{z(e,"updates-for","updates"),Le(e),e.initializeDevtool()}),document.querySelectorAll("cable-ready-updates-for").forEach(e=>{z(e,"updates-for","updates"),Le(e),e.initializeDevtool()}),CableReady.devtools.start()})}var Jt=m(()=>{ie(),ie(),Xt()});function z(e,t,o){Object.assign(e,{initializeDevtool(){let r=()=>this.devtool.show();addEventListener("turbo-boost:devtools-start",()=>{this.devtool=new H(this),this.addEventListener("mouseenter",r)}),addEventListener("turbo-boost:devtools-stop",()=>{this.removeEventListener("mouseenter",r),this.removeDevtool()}),this.dispatchEvent(new CustomEvent("turbo-boost:devtools-connect",{bubbles:!0}))},hideDevtool(){var r;(r=this.devtool)==null||r.hide({active:!1})},removeDevtool(){this.devtool.hide({active:!1}),this.devtool.unregisterEventListeners(),delete this.devtool},name:t,targetLineLabel:o}),["triggerElement","morphElement","targetElement"].filter(r=>e[r]===void 0).forEach(r=>{Object.defineProperty(e,r,{get(){return e}})})}var Se,Ce,Ae,F,ie=m(()=>{Me(),Ft(),{restart:Se,start:Ce,stop:Ae}=I,(async()=>window.CableReady&&await Promise.resolve().then(()=>(Jt(),Wt)))(),F={restart:Se,start:Ce,stop:Ae}});ie();var E=class extends HTMLElement{constructor(t){super(),this.devtool="unknown",this.attachShadow({mode:"open"}),this.shadowRoot.innerHTML=t||"<slot></slot>"}connectedCallback(){this.ensureId()}ensureId(){this.id.trim().length||(this.id=`${this.tagName}-${this.uuidv4()}`.toLowerCase())}uuidv4(){return([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,t=>(t^crypto.getRandomValues(new Uint8Array(1))[0]&15>>t/4).toString(16))}get viewStack(){let t=this.getAttribute("view-stack");return t?JSON.parse(t):[]}get partial(){return this.viewStack[0]}};var Gt=`
|
213
234
|
<turbo-boost>
|
214
235
|
<slot name="busy" hidden></slot>
|
215
236
|
<slot></slot>
|
216
237
|
</turbo-boost>
|
217
|
-
`,
|
238
|
+
`,Pe=100,ae=400,w=class extends E{constructor(){super(Gt)}showBusyElement(){clearTimeout(this.showBusyElementTimeout),clearTimeout(this.hideBusyElementTimeout),this.busyElement&&(this.busyStartedAt=Date.now()+Pe,this.showBusyElementTimeout=setTimeout(()=>{this.busySlotElement.hidden=!1,this.defaultSlotElement.hidden=!0},Pe))}hideBusyElement(){if(clearTimeout(this.showBusyElementTimeout),clearTimeout(this.hideBusyElementTimeout),!this.busyElement)return;let t=ae-(Date.now()-this.busyStartedAt);t<0&&(t=0),delete this.busyStartedAt,this.hideBusyElementTimeout=setTimeout(()=>{this.busySlotElement.hidden=!0,this.defaultSlotElement.hidden=!1},t)}get busyElement(){return this.querySelector(':scope > [slot="busy"]')}get busySlotElement(){return this.shadowRoot.querySelector('slot[name="busy"]')}get defaultSlotElement(){return this.shadowRoot.querySelector("slot:not([name])")}get busy(){return this.getAttribute("busy")==="true"}set busy(t){t=!!t,this.busy!==t&&(this.setAttribute("busy",t),t?this.showBusyElement():this.hideBusyElement())}get busyStartedAt(){return this.dataset.busyStartedAt?Number(this.dataset.busyStartedAt):0}set busyStartedAt(t){this.dataset.busyStartedAt=t}};var R=class extends w{connectedCallback(){super.connectedCallback(),this.mouseenterHandler=this.onMouseenter.bind(this),this.addEventListener("mouseenter",this.mouseenterHandler),this.collapseHandler=this.collapse.bind(this),this.collapseNowHandler=this.collapseNow.bind(this),this.collapseOn.forEach(t=>{let o=t.split("@"),r=o[0];o.length>1?(o[1].match(/^self|window$/)?self:self[o[1]]).addEventListener(r,this.collapseNowHandler):this.addEventListener(r,this.collapseHandler)})}disconnectedCallback(){this.removeEventListener("mouseenter",this.mouseenterHandler),this.collapseOn.forEach(t=>{let o=t.split("@"),r=o[0];o.length>1?(o[1].match(/^self|window$/)?self:self[o[1]]).removeEventListener(r,this.collapseNowHandler):this.removeEventListener(r,this.collapseHandler)})}cacheHTML(){}renderCachedHTML(){}onMouseenter(){clearTimeout(this.collapseTimeout)}collapse(t=250){if(clearTimeout(this.collapseTimeout),!this.busy){if(typeof t!="number"&&(t=250),t>0)return this.collapseTimeout=setTimeout(()=>this.collapse(0),t);this.innerHTML="";try{this.expanded=!1,this.triggerElement.hideDevtool()}catch(o){}}}collapseNow(t){t.target.closest("turbo-boost-devtool-tooltip")||this.collapse(0)}collapseMatches(){document.querySelectorAll(this.collapseSelector).forEach(t=>{t.id!==this.id&&t.collapse&&t.collapse(0)})}get collapseSelector(){return this.triggerElement.collapseSelector||this.getAttribute("collapse-selector")}get focusSelector(){return this.getAttribute("focus-selector")}get triggerElement(){return document.getElementById(this.labeledBy)}get triggerElements(){return document.querySelectorAll(`[aria-controls="${this.id}"]`)}get labeledBy(){return this.getAttribute("aria-labeledby")}set labeledBy(t){return this.setAttribute("aria-labeledby",t)}get collapseOn(){let t=this.getAttribute("collapse-on");return t?JSON.parse(t):[]}get expanded(){return this.triggerElement?this.triggerElement.expanded:!1}set expanded(t){this.triggerElements.forEach(o=>o.expanded=t)}get busy(){return this.triggerElement&&this.triggerElement.busy}};var Ne;function Vt(e){["bold","bullet","code","heading1","href","italic","number","quote","strike"].forEach(o=>e.deactivateAttribute(o))}function Ut(e){if(e.value.length===0)return;let t=e.editor,o=[];for(;o[0]!==t.getSelectedRange()[0]&&o[1]!==t.getSelectedRange()[1];)o=t.getSelectedRange(),t.moveCursorInDirection("forward");t.insertString(" "),t.moveCursorInDirection("forward"),t.setSelectedRange([o[1],t.getSelectedRange()[1]]),Vt(t),t.setSelectedRange([t.getSelectedRange()[1],t.getSelectedRange()[1]])}function Kt(e){clearTimeout(Ne),Ne=setTimeout(()=>{if(!e)return;e.focus();let t=e.closest("trix-editor");try{t?Ut(t):e.selectionStart=e.selectionEnd=e.value.length}catch(o){}finally{e.scrollIntoView({block:"center",behavior:"smooth"})}},100)}var Ie=e=>Kt(e);document.addEventListener("turbo-boost:devtools-start",()=>H.register("toggle","toggles"));var ze,j=class extends w{constructor(){super(),z(this,"toggle","toggles")}connectedCallback(){super.connectedCallback();let{start:t}=TurboBoost.Commands.events;this.commandStartHandler=this.onCommandStart.bind(this),this.addEventListener(t,this.commandStartHandler);let{before:o}=TurboBoost.Streams.invokeEvents;this.beforeInvokeHandler=this.onBeforeInvoke.bind(this),addEventListener(o,this.beforeInvokeHandler),this.initializeDevtool()}disconnectedCallback(){setTimeout(()=>{let{start:t}=TurboBoost.Commands.events;this.removeEventListener(t,this.commandStartHandler);let{before:o}=TurboBoost.Streams.invokeEvents;removeEventListener(o,this.beforeInvokeHandler),this.removeDevtool()},1e3)}onCommandStart(t){ze=this.focusSelector,this.targetElement.labeledBy=this.id,this.targetElement.collapseMatches(),this.busy=!0}onBeforeInvoke(t){if(t.detail.method!=="morph"||t.target.id!==this.morphs)return;let o=`turbo-boost-toggle-target[aria-labeledby="${this.id}"]`;if(!t.target.querySelector(o))return;let r=Date.now()-this.busyStartedAt,n=ae-r;n<10&&(n=10),t.detail.invoke={delay:n},setTimeout(()=>{this.busy=!1,this.morphToggleTriggerElements.forEach(i=>i.busy=!1)},n-10),setTimeout(()=>Ie(this.targetElement.querySelector(ze)),n+100)}get sharedViews(){if(!this.targetElement)return[];if(!this.targetElement.viewStack)return[];let t=(o,r)=>(this.targetElement.viewStack.includes(r)&&o.push(r),o);return this.viewStack.reduce(t.bind(this),[])}get renders(){return this.getAttribute("renders")}get morphs(){return this.getAttribute("morphs")}get morphToggleTriggerElements(){return Array.from(this.morphElement.querySelectorAll("turbo-boost-toggle-trigger"))}get controls(){return this.getAttribute("aria-controls")}get collapseSelector(){return this.getAttribute("collapse-selector")}get focusSelector(){return this.getAttribute("focus-selector")||this.targetElement.focusSelector}get remember(){return this.getAttribute("remember")==="true"}set remember(t){return this.setAttribute("remember",!!t)}get expanded(){return this.getAttribute("aria-expanded")==="true"}set expanded(t){this.setAttribute("aria-expanded",!!t)}get collapsed(){return!this.expanded}get command(){return this.dataset.turboCommand}get renderingLineLabel(){return"renders & morphs"}get morphElement(){return this.morphs?document.getElementById(this.morphs):null}get targetElement(){return this.controls?document.getElementById(this.controls):null}get triggerTooltipData(){let t=this.triggerElement.viewStack.reverse().map((o,r)=>this.triggerElement.sharedViews.includes(o)?`<div slot="content">${r+1}. ${o}</div>`:`<div slot="content-bottom">${r+1}. ${o}</div>`,this).join("");return{subtitle:`
|
218
239
|
<b>id</b>: ${this.triggerElement.id}<br>
|
219
240
|
<b>aria-controls</b>: ${this.triggerElement.controls}<br>
|
220
241
|
<b>aria-expanded</b>: ${this.triggerElement.expanded}<br>
|
@@ -233,5 +254,5 @@ var Be=Object.defineProperty,De=Object.defineProperties,He=Object.getOwnProperty
|
|
233
254
|
<b>View Stack</b>
|
234
255
|
</div>
|
235
256
|
${t}
|
236
|
-
`}}};customElements.define("turbo-boost",
|
257
|
+
`}}};customElements.define("turbo-boost",E);customElements.define("turbo-boost-toggle-target",R);customElements.define("turbo-boost-toggle-trigger",j);self.TurboBoost=self.TurboBoost||{};self.TurboBoost.devtools=F;self.TurboBoost.Elements={};var ko=self.TurboBoost.Elements;export{ko as default};
|
237
258
|
//# sourceMappingURL=elements.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
|
-
"sources": ["../../../../node_modules/@turbo-boost/commands/app/assets/builds/@turbo-boost/commands.js", "../../../../node_modules/@turbo-boost/devtools/src/utils/dom.js", "../../../../node_modules/@turbo-boost/devtools/src/elements/devtool_element.js", "../../../../node_modules/@turbo-boost/devtools/src/elements/supervisor_element.js", "../../../../node_modules/@turbo-boost/devtools/src/elements/tooltip_element.js", "../../../../node_modules/@turbo-boost/devtools/src/dependencies.js", "../../../../node_modules/@turbo-boost/devtools/src/supervisor.js", "../../../../node_modules/@turbo-boost/devtools/src/devtool.js", "../../../../node_modules/@turbo-boost/devtools/src/index.js", "../../../javascript/elements/turbo_boost_element/index.js", "../../../javascript/elements/toggle_elements/toggle_element/index.js", "../../../javascript/elements/toggle_elements/target_element/index.js", "../../../javascript/elements/toggle_elements/trigger_element/focus.js", "../../../javascript/elements/toggle_elements/trigger_element/index.js", "../../../javascript/elements/index.js", "../../../javascript/index.js"],
|
4
|
-
"sourcesContent": ["var Z=Object.defineProperty,ee=Object.defineProperties;var te=Object.getOwnPropertyDescriptors;var X=Object.getOwnPropertySymbols;var re=Object.prototype.hasOwnProperty,oe=Object.prototype.propertyIsEnumerable;var _=(e,t,r)=>t in e?Z(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,s=(e,t)=>{for(var r in t||(t={}))re.call(t,r)&&_(e,r,t[r]);if(X)for(var r of X(t))oe.call(t,r)&&_(e,r,t[r]);return e},u=(e,t)=>ee(e,te(t));var O=class{get element(){return document.querySelector('meta[name=\"turbo-boost\"]')}get token(){return this.element.getAttribute(\"content\")}get busy(){return this.element.dataset.busy===\"true\"}set busy(t){return this.element.dataset.busy=!!t}},a=new O;var i={start:\"turbo-boost:command:start\",success:\"turbo-boost:command:success\",finish:\"turbo-boost:command:finish\",abort:\"turbo-boost:command:abort\",clientError:\"turbo-boost:command:client-error\",serverError:\"turbo-boost:command:server-error\"},l={stateLoad:\"turbo-boost:state:load\",stateChange:\"turbo-boost:state:change\"},f=s(s({},i),l);function d(e,t,r={}){return new Promise(o=>{r=r||{},r.detail=r.detail||{},t=t||document;let n=new CustomEvent(e,u(s({},r),{bubbles:!0}));t.dispatchEvent(n),o(n)})}var B;function k(e,t=null){if(!e||typeof e!=\"object\")return e;let r=new Proxy(e,{deleteProperty(o,n){return delete o[n],d(l.stateChange,a.element,{detail:{state:B}}),!0},set(o,n,c,A){return o[n]=k(c,this),d(l.stateChange,a.element,{detail:{state:B}}),!0}});if(Array.isArray(e))e.forEach((o,n)=>e[n]=k(o,r));else if(typeof e==\"object\")for(let[o,n]of Object.entries(e))e[o]=k(n,r);return t||(B=r),r}var F=k;var D,g,C,N;function J(){if(!a.element)return E();let e=atob(a.element.dataset.state);C={},g=F(JSON.parse(e)),D=s({},g),delete a.element.dataset.clientStateChange,setTimeout(()=>d(l.stateLoad,a.element,{detail:{state:g}}))}function E(){clearTimeout(N),N=setTimeout(J,10)}D||J();addEventListener(\"DOMContentLoaded\",E);addEventListener(\"load\",E);addEventListener(\"turbo:load\",E);addEventListener(\"turbo:frame-load\",E);addEventListener(i.success,E);addEventListener(l.stateChange,e=>{C={};for(let[t,r]of Object.entries(g))D[t]!==r&&(C[t]=r);a.element.dataset.clientStateChange=!0,a.element.dataset.state=btoa(JSON.stringify(g))});var h={events:l,get current(){return g},get delta(){return C},get payloadChunks(){return btoa(JSON.stringify(C)).match(/.{1,2000}/g)}};function ne(e){let t=\"<html\",r=\"</html\",o=e.indexOf(t),n=e.lastIndexOf(r);if(o>=0&&n>=0){let c=e.slice(e.indexOf(\">\",o)+1,n);document.documentElement.innerHTML=c}}function se(e){document.body.insertAdjacentHTML(\"beforeend\",e)}var v={append:se,replaceDocument:ne};var L={};function ae(e){L[e.id]=e}function ie(e){delete L[e]}var S={add:ae,remove:ie,get commands(){return[...Object.values(L)]},get length(){return Object.keys(L).length}};function M(e){e.detail.endedAt=Date.now(),e.detail.milliseconds=e.detail.endedAt-e.detail.startedAt,setTimeout(()=>d(i.finish,e.target,{detail:e.detail}),25)}addEventListener(i.serverError,M);addEventListener(i.success,M);addEventListener(i.finish,e=>S.remove(e.detail.id),!0);var T={events:i};var R={};addEventListener(\"turbo:before-fetch-request\",e=>{let t=e.target.closest(\"turbo-frame\"),{fetchOptions:r}=e.detail;if(a.busy){let o=[\"text/vnd.turbo-boost.html\",r.headers.Accept];o=o.filter(n=>n&&n.trim().length>0).join(\", \"),r.headers.Accept=o,r.headers[\"TurboBoost-Token\"]=a.token}h.payloadChunks.forEach((o,n)=>{r.headers[`TurboBoost-State-${n.toString().padStart(4,\"0\")}`]=o})});addEventListener(\"turbo:before-fetch-response\",e=>{let t=e.target.closest(\"turbo-frame\"),{fetchResponse:r}=e.detail;if(t&&(R[t.id]=t.src),r.header(\"TurboBoost\")){if(r.statusCode<200||r.statusCode>399){let o=`Server returned a ${r.statusCode} status code! TurboBoost Commands require 2XX-3XX status codes.`;d(T.events.clientError,document,{detail:u(s({},e.detail),{error:o})},!0)}r.header(\"TurboBoost\")===\"Append\"&&(e.preventDefault(),r.responseText.then(o=>v.append(o)))}});addEventListener(\"turbo:frame-load\",e=>{let t=e.target.closest(\"turbo-frame\");t.dataset.turboBoostSrc=R[t.id]||t.src||t.dataset.turboBoostSrc,delete R[t.id]});var de={frameAttribute:\"data-turbo-frame\",methodAttribute:\"data-turbo-method\",commandAttribute:\"data-turbo-command\",confirmAttribute:\"data-turbo-confirm\"},m=s({},de);var j={method:e=>Promise.resolve(confirm(e))},me=e=>e.detail.driver===\"method\",ue=e=>{if(e.detail.driver!==\"form\")return!1;let t=e.target,r=t.closest(\"turbo-frame\"),o=t.closest(`[${m.frameAttribute}]`);return!!(r||o)},ce=e=>me(e)||ue(e);document.addEventListener(i.start,async e=>{let t=e.target.getAttribute(m.confirmAttribute);if(!t||(e.detail.confirmation=!0,ce(e)))return;await j.method(t)||e.preventDefault()});var W=j;var b=[],$;function le(e,t){let r=b.find(o=>o.name===e);return r&&b.splice(b.indexOf(r),1),b=[{name:e,selectors:t},...b],document.removeEventListener(e,$,!0),document.addEventListener(e,$,!0),s({},b.find(o=>o.name===e))}function fe(e){return b.find(t=>t.selectors.find(r=>Array.from(document.querySelectorAll(r)).find(o=>o===e)))}function be(e,t){let r=fe(t);return r&&r.name===e}var p={register:le,isRegisteredForElement:be,get events(){return[...b]},set handler(e){$=e}};function pe(e){return e.closest(`[${m.commandAttribute}]`)}function he(e){return e.closest(\"turbo-frame[src]\")||e.closest(\"turbo-frame[data-turbo-frame-src]\")||e.closest(\"turbo-frame\")}function ve(e,t={}){if(e.tagName.toLowerCase()!==\"select\")return t.value=e.value||null;if(!e.multiple)return t.value=e.options[e.selectedIndex].value;t.values=Array.from(e.options).reduce((r,o)=>(o.selected&&r.push(o.value),r),[])}function ge(e){let t=Array.from(e.attributes).reduce((r,o)=>{let n=o.value;return r[o.name]=n,r},{});return t.tag=e.tagName,t.checked=!!e.checked,t.disabled=!!e.disabled,ve(e,t),delete t.class,delete t.action,delete t.href,delete t[m.commandAttribute],delete t[m.frameAttribute],t}var y={buildAttributePayload:ge,findClosestCommand:pe,findClosestFrameWithSource:he};function Ee(e,t={}){t.token=a.token;let r=document.createElement(\"input\");r.type=\"hidden\",r.name=\"turbo_boost_command\",r.value=JSON.stringify(t),e.appendChild(r)}var U={invokeCommand:Ee};function xe(e,t={}){let r=document.createElement(\"a\");r.href=e;let o=new URL(r);return o.searchParams.set(\"turbo_boost_command\",JSON.stringify(t)),o}var x={build:xe};function Ce(e,t){let r=t.src;t=s({},t),delete t.src,e.src=x.build(r,t)}var H={invokeCommand:Ce};function Te(e,t={}){let r=t.src;t=s({},t),delete t.src,delete t.href,e.setAttribute(\"href\",x.build(r,t))}var V={invokeCommand:Te};function ye(e){let t=e.target;d(T.events.abort,document,{detail:u(s({},e.detail),{xhr:t})})}function P(e){let t=e.target;t.getResponseHeader(\"TurboBoost\")===\"Append\"||t.getResponseHeader(\"Content-Type\").startsWith(\"text/vnd.turbo-boost.html\")?v.append(t.responseText):v.replaceDocument(t.responseText);let o=`Server returned a ${t.status} status code! TurboBoost Commands require 2XX-3XX status codes.`;d(T.events.clientError,document,{detail:u(s({},e.detail),{error:o,xhr:t})},!0)}function Ae(e){let t=e.target;if(t.status<200||t.status>399)return P(e);let r=t.responseText;t.getResponseHeader(\"TurboBoost\")===\"Append\"||t.getResponseHeader(\"Content-Type\").startsWith(\"text/vnd.turbo-boost.html\")?v.append(t.responseText):v.replaceDocument(t.responseText)}function ke(e){let t=e.src;e=s({},e),delete e.src;try{let r=new XMLHttpRequest;r.open(\"GET\",x.build(t,e),!0),r.setRequestHeader(\"Accept\",\"text/vnd.turbo-boost.html, text/html, application/xhtml+xml\"),r.setRequestHeader(\"TurboBoost-Token\",a.token),h.payloadChunks.forEach((o,n)=>r.setRequestHeader(`TurboBoost-State-${n.toString().padStart(4,\"0\")}`,o)),r.addEventListener(\"abort\",ye),r.addEventListener(\"error\",P),r.addEventListener(\"load\",Ae),r.send()}catch(r){let o=`Unexpected error sending HTTP request! ${r.message}`;P(r,{detail:{message:o}})}}var G={invokeCommand:ke};function q(e,t){return t=t||{dataset:{}},e.href||t.src||t.dataset.turboBoostSrc||location.href}function Le(e){let t=y.findClosestFrameWithSource(e),{turboFrame:r,turboMethod:o}=e.dataset;return e.tagName.toLowerCase()===\"form\"?{name:\"form\",reason:\"Element is a form.\",frame:t,src:e.action,invokeCommand:U.invokeCommand}:o&&o.length>0?{name:\"method\",reason:\"Element defines data-turbo-method.\",frame:t,src:e.href,invokeCommand:V.invokeCommand}:r&&r!==\"_self\"?(t=document.getElementById(r),{name:\"frame\",reason:\"element targets a frame that is not _self\",frame:t,src:q(e,t),invokeCommand:H.invokeCommand}):(!r||r===\"_self\")&&t?{name:\"frame\",reason:\"element does NOT target a frame or targets _self and is contained by a frame\",frame:t,src:q(e,t),invokeCommand:H.invokeCommand}:{name:\"window\",reason:\"element matches one or more of the following conditions (targets _top, does NOT target a frame, is NOT contained by a frame)\",frame:null,src:q(e),invokeCommand:G.invokeCommand}}var I={find:Le};var w=\"unknown\",z={debug:Object.values(f),info:Object.values(f),warn:[f.abort,f.clientError,f.serverError],error:[f.clientError,f.serverError],unknown:[]};Object.values(f).forEach(e=>{addEventListener(e,t=>{if(z[w].includes(t.type)){let{target:r,detail:o}=t;console[w](t.type,{target:r,detail:o})}})});var K={get level(){return w},set level(e){return Object.keys(z).includes(e)||(e=\"unknown\"),w=e}};function Se(){return([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,e=>(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16))}var Q={v4:Se};function Y(e,t){return{id:e,name:t.getAttribute(m.commandAttribute),elementId:t.id.length>0?t.id:null,elementAttributes:y.buildAttributePayload(t),startedAt:Date.now()}}async function we(e){let t,r={};try{if(t=y.findClosestCommand(e.target),!t||!p.isRegisteredForElement(e.type,t))return;let o=`turbo-command-${Q.v4()}`,n=I.find(t),c=u(s({},Y(o,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),A=await d(i.start,t,{cancelable:!0,detail:c});if(A.defaultPrevented||A.detail.confirmation&&e.defaultPrevented)return d(i.abort,t,{detail:{message:`An event handler for '${i.start}' prevented default behavior and blocked command invocation!`,source:A}});switch(n=I.find(t),c=u(s({},Y(o,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),S.add(c),[\"frame\",\"window\"].includes(n.name)&&e.preventDefault(),a.busy=!0,setTimeout(()=>a.busy=!1,10),n.name){case\"method\":return n.invokeCommand(t,c);case\"form\":return n.invokeCommand(t,c);case\"frame\":return n.invokeCommand(n.frame,c);case\"window\":return n.invokeCommand(c)}}catch(o){d(i.clientError,t,{detail:u(s({},r),{error:o})})}}self.TurboBoost=self.TurboBoost||{};self.TurboBoost=u(s({},self.TurboBoost),{stateEvents:l,get state(){return h.current},get stateDelta(){return h.delta}});self.TurboBoost.Commands||(p.handler=we,p.register(\"click\",[`[${m.commandAttribute}]`]),p.register(\"submit\",[`form[${m.commandAttribute}]`]),p.register(\"change\",[`input[${m.commandAttribute}]`,`select[${m.commandAttribute}]`,`textarea[${m.commandAttribute}]`]),self.TurboBoost.Commands={confirmation:W,logger:K,schema:m,events:i,registerEventDelegate:p.register,get eventDelegates(){return p.events}});var Qt=self.TurboBoost.Commands;export{Qt as default};\n//# sourceMappingURL=commands.js.map\n", "export function template (html) {\n let template = document.createElement('template')\n template.innerHTML = html\n return template\n}\n\nexport function appendHTML (html, parent) {\n parent = parent || document.body\n const clone = template(html).content.cloneNode(true)\n const child = clone.querySelector('*')\n return parent.appendChild(child)\n}\n\nexport function addHighlight (element, options = {}) {\n if (!element) return\n removeHighlight(element)\n let { outline, outlineOffset } = options\n\n outline = outline || 'dashed 3px red'\n outlineOffset = outlineOffset || '0px'\n\n element.originalStyles = element.originalStyles || {\n display: element.style.display,\n minHeight: element.style.minHeight,\n minWidth: element.style.minWidth,\n outline: element.style.outline,\n outlineOffset: element.style.outlineOffset\n }\n\n if (\n getComputedStyle(element).display.match(/^inline$/i) &&\n element.offsetWidth === 0 &&\n element.offsetHeight === 0\n ) {\n element.style.display = 'inline-block'\n element.style.minHeight = '2px'\n element.style.minWidth = '2px'\n }\n element.style.outline = outline\n element.style.outlineOffset = outlineOffset\n element.dataset.turboBoostHighlight = true\n}\n\nexport function removeHighlight (element) {\n if (!element) return\n if (element.originalStyles) {\n for (const [key, value] of Object.entries(element.originalStyles))\n value ? (element.style[key] = value) : (element.style[key] = '')\n delete element.originalStyles\n }\n delete element.dataset.turboBoostHighlight\n}\n\nexport function coordinates (element) {\n if (!element) return {}\n const rect = element.getBoundingClientRect()\n const width = element.offsetWidth\n const height = element.offsetHeight\n const top = rect.top + window.scrollY\n const left = rect.left + window.scrollX\n const right = left + width\n const bottom = top + height\n return { top, left, right, bottom, width, height }\n}\n\nexport function attempt (callback) {\n try {\n callback()\n } catch {}\n}\n", "export default class DevtoolElement extends HTMLElement {\n constructor () {\n super()\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = this.html\n this.labelElement.addEventListener('click', event => {\n event.preventDefault()\n this.toggle()\n })\n this.checkboxElement.addEventListener('change', event =>\n this.dispatchEvent(new CustomEvent('change', { bubbles: true }))\n )\n }\n\n toggle () {\n this.checked ? this.uncheck() : this.check()\n }\n\n check () {\n this.checkboxElement.checked = true\n this.dispatchEvent(new CustomEvent('change', { bubbles: true }))\n }\n\n uncheck () {\n this.checkboxElement.checked = false\n this.dispatchEvent(new CustomEvent('change', { bubbles: true }))\n }\n\n get name () {\n return this.getAttribute('name')\n }\n\n get checked () {\n return this.checkboxElement.checked\n }\n\n get checkboxElement () {\n return this.shadowRoot.querySelector('input')\n }\n\n get labelElement () {\n return this.shadowRoot.querySelector('label')\n }\n\n get html () {\n return `\n <style>${this.stylesheet}</style>\n <div>\n <input name=\"checkbox\" type=\"checkbox\">\n <label for=\"checkbox\"><slot name=\"label\"></slot></label>\n </div>\n `\n }\n\n get stylesheet () {\n return `\n :host, :host * {\n cursor: pointer;\n }\n\n div {\n display: flex;\n margin-right: 10px;\n }\n\n input:checked + label{\n font-weight: bold;\n }\n\n label {\n color: black;\n }\n `\n }\n}\n", "import { appendHTML } from '../utils/dom.js'\n\nexport default class SupervisorElement extends HTMLElement {\n constructor () {\n super()\n this.enabledDevtools = {}\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = this.html\n this.shadowRoot.querySelector('button').addEventListener('click', () =>\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-close', {\n bubbles: true\n })\n )\n )\n\n this.addEventListener('change', event => {\n const devtoolElement = event.target\n const { checked, name } = devtoolElement\n checked ? this.enableDevtool(name) : this.disableDevtool(name)\n })\n }\n\n enableDevtool (name) {\n if (this.enabledDevtools[name]) return\n this.enabledDevtools[name] = true\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtool-enable', {\n bubbles: true,\n detail: { name: name }\n })\n )\n }\n\n disableDevtool (name) {\n if (!this.enabledDevtools[name]) return\n delete this.enabledDevtools[name]\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtool-disable', {\n bubbles: true,\n detail: { name: name }\n })\n )\n }\n\n close () {\n this.devtoolElements.forEach(el => {\n if (el.checked) el.uncheck()\n })\n this.remove()\n }\n\n get devtoolElements () {\n return this.querySelectorAll('[slot=\"devtool\"]')\n }\n\n get closeElement () {\n return this.querySelector('button')\n }\n\n get html () {\n return `\n <style>${this.stylesheet}</style>\n <div>\n <img src=\"https://ik.imagekit.io/hopsoft/turbo-boost-logo_zHiiimlvT.webp?ik-sdk-version=javascript-1.4.3&updatedAt=1671722004342\">\n <slot name=\"devtool\"></slot>\n <button>\u2715</button>\n </div>\n `\n }\n\n get stylesheet () {\n return `\n :host {\n background-color: gainsboro;\n border-radius: 5px;\n bottom: 20px;\n display: block;\n filter: drop-shadow(3px 3px 3px rgba(0,0,0,0.3));\n left: 50%;\n outline-offset: 1px;\n outline: solid 2px black;\n padding: 5px 10px;\n position: fixed;\n transform: translateX(-50%);\n z-index: 8999;\n }\n\n * {\n -webkit-user-select: none;\n font-family: helvetica, sans-serif;\n font-size: 1rem;\n user-select: none;\n }\n\n img {\n align-self: center;\n cursor: grab;\n height: 25px;\n margin-left: -5px;\n vertical-align: middle;\n }\n\n div {\n display: flex;\n gap: 0 5px;\n position: relative;\n }\n\n [slot=\"devtool\"] {\n align-self: center;\n }\n\n button {\n align-self: center;\n background-color: darkgray;\n border-radius: 50%;\n border: none;\n color: black;\n cursor: pointer;\n font-size: 10px;\n height: 18px;\n line-height: 18px;\n margin-right: -5px;\n opacity: 0.5;\n outline: solid 1px black;\n padding: 0 2px;\n width: 18px;\n }\n\n button:hover {\n opacity: 1;\n }\n `\n }\n}\n", "export default class TooltipElement extends HTMLElement {\n constructor () {\n super()\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = this.html\n }\n\n connectedCallback () {\n const savedTransform = localStorage.getItem(\n `turbo-boost-devtools-${location.href}-${this.id}-transform`\n )\n\n if (savedTransform) {\n this.style.transform = savedTransform\n }\n }\n\n disconnectedCallback () {\n if (this.id !== 'undefined' && this.id !== '') {\n localStorage.setItem(\n `turbo-boost-devtools-${location.href}-${this.id}-transform`,\n this.style.transform\n )\n }\n }\n\n get color () {\n return this.getAttribute('color') || 'darkslategray'\n }\n\n get backgroundColor () {\n return this.getAttribute('background-color') || 'gainsboro'\n }\n\n get position () {\n return this.getAttribute('position') || 'top'\n }\n\n get html () {\n return `\n <style>${this.stylesheet}</style>\n <div role=\"container\">\n <div role=\"title\">\n <slot name=\"title\"></slot>\n <img src=\"https://ik.imagekit.io/hopsoft/turbo-boost-logo_zHiiimlvT.webp?ik-sdk-version=javascript-1.4.3&updatedAt=1671722004342\">\n </div>\n <slot name=\"subtitle\"></slot>\n <slot name=\"content-top\"></slot>\n <slot name=\"content\"></slot>\n <slot name=\"content-bottom\"></slot>\n </div>\n `\n }\n\n get stylesheet () {\n return `\n :host {\n display: block;\n position: absolute;\n z-index: 8999;\n }\n\n * {\n color: ${this.color}\n font-size: 1rem;\n }\n\n [role=\"container\"] {\n background-color: ${this.backgroundColor};\n border-radius: 15px;\n filter: drop-shadow(3px 3px 3px rgba(0,0,0,0.3));\n font-family: monospace;\n min-height: 30px;\n min-width: 100px;\n opacity: 0.9;\n outline-offset: 1px;\n outline: dashed 3px ${this.color};\n padding: 12px;\n position: relative;\n white-space: nowrap;\n }\n\n [role=\"title\"] {\n display: flex;\n }\n\n [role=\"title\"] slot[name=\"title\"] {\n color: ${this.color};\n display: block;\n flex-grow: 1;\n font-weight: bold;\n }\n\n [role=\"title\"] img {\n height: 25px;\n vertical-align: middle;\n }\n\n slot[name=\"subtitle\"] {\n border-bottom: dotted 1px ${this.color};\n border-top: dotted 1px ${this.color};\n color: ${this.color};\n display: block;\n font-size: 0.8rem;\n font-weight: lighter;\n margin-bottom: 12px;\n margin-top: 8px;\n padding-bottom: 4px;\n padding-top: 4px;\n width: 100%;\n }\n\n slot[name=\"content-top\"],\n slot[name=\"content\"],\n slot[name=\"content-bottom\"] {\n display: block;\n font-weight: normal;\n }\n\n slot[name=\"content-top\"] {\n color: ${this.color};\n margin-bottom: 8px;\n }\n\n slot[name=\"content\"],\n slot[name=\"content-bottom\"] {\n opacity: 0.7;\n padding-left: 12px;\n }\n\n slot[name=\"content\"] {\n color: ${this.color};\n }\n\n slot[name=\"content-bottom\"] {\n color: red;\n }\n `\n }\n}\n", "const added = []\n\nconst dependencies = {\n LeaderLine: {\n src:\n 'https://cdnjs.cloudflare.com/ajax/libs/leader-line/1.0.7/leader-line.min.js',\n integrity:\n 'sha512-0dNdzMjpT6pJdFGF1DwybFCfm3K/lzHhxaMXC/92J9/DZujHlqYFqmhTOAoD0o+LkeEsVK2ar/ESs7/Q2B6wJg==',\n global: 'LeaderLine'\n },\n\n PlainDraggable: {\n src:\n 'https://cdn.jsdelivr.net/npm/plain-draggable@2.5.14/plain-draggable.min.js',\n global: 'PlainDraggable'\n }\n}\n\nfunction exists (dependency) {\n if (dependency.global && self[dependency.global]) return true\n if (document.querySelector(`[src='${dependency.src}']`)) return true\n return added.includes(dependency)\n}\n\nfunction add (dependency) {\n if (exists(dependency)) return\n added.push(dependency)\n\n const { src, integrity } = dependency\n const script = document.createElement('script')\n script.setAttribute('src', src)\n script.setAttribute('crossorigin', 'anonymous')\n script.setAttribute('referrerpolicy', 'no-referrer')\n if (integrity) script.setAttribute('integrity', integrity)\n document.head.appendChild(script)\n}\n\nfunction remove (dependency) {\n if (!added.includes(dependency)) return\n added.splice(added.indexOf(dependency), 1)\n\n const { src } = dependency\n const el = document.querySelector(`script[src='${src}']`)\n if (el) el.remove()\n if (dependency.global && self[dependency.global])\n self[dependency.global] = null\n}\n\nfunction removeAll () {\n ;[...added].forEach(dependency => remove(dependency))\n}\n\nexport default { ...dependencies, add, remove, removeAll }\n", "import { appendHTML } from './utils/dom'\nimport DevtoolElement from './elements/devtool_element'\nimport SupervisorElement from './elements/supervisor_element'\nimport TooltipElement from './elements/tooltip_element'\nimport dependencies from './dependencies'\n\ncustomElements.define('turbo-boost-devtool', DevtoolElement)\ncustomElements.define('turbo-boost-devtool-supervisor', SupervisorElement)\ncustomElements.define('turbo-boost-devtool-tooltip', TooltipElement)\n\nlet supervisorElement\n\nfunction makeDraggable () {\n if (!supervisorElement) return\n try {\n new PlainDraggable(supervisorElement)\n } catch {\n setTimeout(makeDraggable, 200)\n }\n}\n\nfunction stop () {\n if (stopped()) return\n supervisorElement.close()\n supervisorElement.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-stop', {\n bubbles: true\n })\n )\n supervisorElement = null\n dependencies.removeAll()\n}\n\nfunction start () {\n if (started()) return\n dependencies.add(dependencies.LeaderLine)\n dependencies.add(dependencies.PlainDraggable)\n supervisorElement = appendHTML(\n '<turbo-boost-devtool-supervisor></turbo-boost-devtool-supervisor>'\n )\n setTimeout(makeDraggable, 200)\n supervisorElement.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-start', {\n bubbles: true\n })\n )\n}\n\nfunction restart () {\n const enabledList = supervisorElement\n ? Object.keys(supervisorElement.enabledDevtools)\n : []\n\n stop()\n start()\n\n supervisorElement.devtoolElements.forEach(el => {\n if (enabledList.includes(el.name)) el.check()\n })\n}\n\nfunction started () {\n return !!supervisorElement\n}\n\nfunction stopped () {\n return !started()\n}\n\nlet restartTimeout\nfunction debouncedRestart () {\n clearTimeout(restartTimeout)\n restartTimeout = setTimeout(restart, 25)\n}\n\nfunction autoRestart () {\n if (started()) debouncedRestart()\n}\n\naddEventListener('turbo:load', autoRestart)\naddEventListener('turbo-frame:load', autoRestart)\naddEventListener('turbo-boost:devtools-connect', autoRestart)\naddEventListener('turbo-boost:devtools-close', stop)\n\nif (window.TurboBoost) {\n addEventListener(TurboBoost.Commands.events.success, autoRestart)\n addEventListener(TurboBoost.Commands.events.finish, autoRestart)\n}\n\nfunction register (name, label) {\n if (!supervisorElement) return\n return appendHTML(\n `\n <turbo-boost-devtool name=\"${name}\" slot=\"devtool\">\n <span slot=\"label\">${label}</span>\n </turbo-boost-devtool>\n `,\n supervisorElement\n )\n}\n\nfunction enabled (name) {\n if (!supervisorElement) return false\n return supervisorElement.enabledDevtools[name]\n}\n\nexport default {\n enabled,\n register,\n start,\n stop,\n restart: debouncedRestart,\n get started () {\n return started()\n },\n get stopped () {\n return stopped()\n }\n}\n", "// Icons courtesy of https://feathericons.com/\nimport supervisor from './supervisor'\nimport {\n appendHTML,\n addHighlight,\n attempt,\n coordinates,\n removeHighlight\n} from './utils/dom.js'\n\nfunction appendTooltip (title, subtitle, content, options = {}) {\n let { backgroundColor, color, position, id } = options\n color = color || 'white'\n position = position || 'top'\n return appendHTML(`\n <turbo-boost-devtool-tooltip id=\"${id}\" position=\"${position}\" background-color=\"${backgroundColor}\" color=\"${color}\">\n <div slot='title'>${title}</div>\n <div slot='subtitle'>${subtitle}</div>\n ${content}\n </turbo-boost-devtool-tooltip>\n `)\n}\n\nlet activeTarget\n\nexport default class Devtool {\n constructor (delegate) {\n this.delegate = delegate\n\n let hideTimeout\n const debouncedHide = () => {\n clearTimeout(hideTimeout)\n hideTimeout = setTimeout(this.hide({ active: false }), 25)\n }\n\n this.eventListeners['turbo-boost:devtool-enable'] = event => {\n // LeaderLine.positionByWindowResize = false\n const { name } = event.detail\n if (name !== this.delegate.name) return\n\n addHighlight(this.delegate.triggerElement, {\n outline: '3px dashed blueviolet',\n outlineOffset: '2px'\n })\n\n this.hide({ active: false })\n if (this.active) this.show()\n }\n\n this.eventListeners['turbo-boost:devtool-disable'] = event => {\n const { name } = event.detail\n if (name === this.delegate.name)\n removeHighlight(this.delegate.triggerElement)\n }\n\n this.eventListeners['click'] = event => {\n if (event.target.closest('turbo-boost-devtool-tooltip')) return\n debouncedHide()\n }\n\n this.eventListeners['turbo:load'] = debouncedHide\n this.eventListeners['turbo-frame:load'] = debouncedHide\n if (window.TurboBoost) {\n this.eventListeners[TurboBoost.Commands.events.finish] = debouncedHide\n }\n\n this.registerEventListeners()\n }\n\n registerEventListeners () {\n Object.entries(this.eventListeners).forEach(([type, listener]) => {\n addEventListener(type, listener)\n })\n }\n\n unregisterEventListeners () {\n Object.entries(this.eventListeners).forEach(([type, listener]) => {\n removeEventListener(type, listener)\n })\n }\n\n get eventListeners () {\n return this._eventListeners || (this._eventListeners = {})\n }\n\n show () {\n if (!this.enabled) return\n\n if (this.active) return\n this.active = true\n\n this.hide({ active: true })\n\n addHighlight(this.delegate.targetElement, {\n outline: '3px dashed darkcyan',\n outlineOffset: '-2px'\n })\n\n addHighlight(this.delegate.morphElement, {\n outline: '3px dashed chocolate',\n outlineOffset: '3px'\n })\n\n this.renderingTooltip = this.createRenderingTooltip()\n this.targetTooltip = this.createTargetTooltip()\n this.triggerTooltip = this.createTriggerTooltip(\n this.targetTooltip,\n this.renderingTooltip\n )\n\n document\n .querySelectorAll('.leader-line')\n .forEach(el => (el.style.zIndex = 100000))\n\n const data = {\n morph: {\n partial: this.delegate.triggerElement.renders,\n id: this.delegate.triggerElement.morphs,\n status: this.delegate.morphElement ? 'OK' : 'Not Found'\n },\n trigger: { partial: null, id: null, status: 'Not Found' },\n target: { partial: null, id: null, status: 'Not Found' }\n }\n\n if (this.delegate.triggerElement) {\n data.trigger = {\n partial: this.delegate.triggerElement.partial,\n id: this.delegate.triggerElement.id,\n status: 'OK'\n }\n data.target.id = this.delegate.triggerElement.controls\n }\n\n if (this.delegate.targetElement)\n data.target = {\n partial: this.delegate.targetElement.partial,\n dom_id: this.delegate.targetElement.id,\n status: 'OK'\n }\n\n console.table(data)\n }\n\n hide ({ active: active = false }) {\n document\n .querySelectorAll('turbo-boost-devtool-tooltip')\n .forEach(tooltip => {\n attempt(() => tooltip.line.remove())\n attempt(() => tooltip.drag.remove())\n attempt(() => tooltip.lineToRendering.remove())\n attempt(() => tooltip.lineToTarget.remove())\n attempt(() => tooltip.remove())\n })\n\n document.querySelectorAll('[data-turbo-boost-highlight]').forEach(el => {\n if (!el.tagName.match(/turbo-boost-toggle-trigger/i)) removeHighlight(el)\n })\n\n this.active = active\n }\n\n get active () {\n return activeTarget === this.delegate\n }\n\n set active (value) {\n if (value) activeTarget = this.delegate\n else activeTarget = null\n }\n\n get enabled () {\n return supervisor.enabled(this.delegate.name)\n }\n\n static register (name, label) {\n supervisor.register(name, label)\n }\n\n createRenderingTooltip () {\n if (!this.delegate.triggerElement.renders)\n return console.debug(\n `Unable to create the rendering tooltip! The trigger element must set the 'renders' attribute.`\n )\n\n if (!this.delegate.triggerElement.morphs)\n return console.debug(\n `Unable to create the rendering tooltip! The trigger element specified the 'morphs' attrbiute but no element matches the DOM id: '${this.triggerElement.morphs}'`\n )\n\n const title = `\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M12 19l7-7 3 3-7 7-3-3z\"></path><path d=\"M18 13l-1.5-7.5L2 2l3.5 14.5L13 18l5-5z\"></path><path d=\"M2 2l7.586 7.586\"></path><circle cx=\"11\" cy=\"11\" r=\"2\"></circle></svg>\n RENDERING - <${this.delegate.triggerElement.tagName.toLowerCase()}>\n `\n const subtitle = `\n <b>partial</b>: ${this.delegate.triggerElement.renders || 'unknown'}<br>\n <b>morphs</b>: ${this.delegate.triggerElement.morphs || 'unknown'}<br>\n `\n const content = `\n <div slot=\"content-top\" style=\"font-size:85%; font-style:italic; font-weight:100;\">\n The <b>TRIGGER</b> toggles the <b>TARGET</b> then renders the partial & morphs the element.<br>\n </div>\n `\n const tooltip = appendTooltip(title, subtitle, content, {\n id: `${this.delegate.id}-rendering`,\n backgroundColor: 'lightyellow',\n color: 'chocolate'\n })\n\n const coords = coordinates(this.delegate.morphElement)\n const top = Math.ceil(\n coords.top + coords.height / 2 - tooltip.offsetHeight / 2\n )\n const left = Math.ceil(coords.left + coords.width + 100)\n tooltip.style.top = `${top}px`\n tooltip.style.left = `${left}px`\n\n tooltip.line = new LeaderLine(tooltip, this.delegate.morphElement, {\n ...this.leaderLineOptions,\n color: 'chocolate'\n })\n\n tooltip.drag = new PlainDraggable(tooltip)\n return tooltip\n }\n\n createTargetTooltip () {\n if (!this.delegate.targetElement)\n return console.debug(\n `Unable to create the target tooltip! No element matches the DOM id: '${this.delegate.triggerElement.controls}'`\n )\n\n const title = `\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><circle cx=\"12\" cy=\"12\" r=\"10\"></circle><circle cx=\"12\" cy=\"12\" r=\"6\"></circle><circle cx=\"12\" cy=\"12\" r=\"2\"></circle></svg>\n TARGET - <${this.delegate.targetElement.tagName.toLowerCase()}>\n `\n\n const tooltip = appendTooltip(\n title,\n this.delegate.targetTooltipData?.subtitle || '',\n this.delegate.targetTooltipData?.content || '',\n {\n id: `${this.delegate.id}-target`,\n backgroundColor: 'lightcyan',\n color: 'darkcyan',\n position: 'bottom'\n }\n )\n\n const coords = coordinates(this.delegate.targetElement)\n const top = Math.ceil(coords.top + tooltip.offsetHeight)\n const left = Math.ceil(coords.left + coords.width + tooltip.offsetWidth / 3)\n tooltip.style.top = `${top}px`\n tooltip.style.left = `${left}px`\n\n tooltip.line = new LeaderLine(tooltip, this.delegate.targetElement, {\n ...this.leaderLineOptions,\n color: 'darkcyan'\n })\n\n tooltip.drag = new PlainDraggable(tooltip)\n return tooltip\n }\n\n createTriggerTooltip (targetTooltip, renderingTooltip) {\n if (!this.delegate.triggerElement) return\n const title = `\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"13 2 3 14 12 14 11 22 21 10 12 10 13 2\"></polygon></svg>\n TRIGGER - <${this.delegate.triggerElement.tagName.toLowerCase()}>\n `\n\n const tooltip = appendTooltip(\n title,\n this.delegate.triggerTooltipData?.subtitle || '',\n this.delegate.triggerTooltipData?.content || '',\n {\n id: `${this.delegate.id}-trigger`,\n backgroundColor: 'lavender',\n color: 'blueviolet'\n }\n )\n\n const coords = coordinates(this.delegate.triggerElement)\n const top = Math.ceil(coords.top - tooltip.offsetHeight * 2)\n const left = Math.ceil(coords.left + coords.width + tooltip.offsetWidth / 3)\n tooltip.style.top = `${top}px`\n tooltip.style.left = `${left}px`\n\n tooltip.line = new LeaderLine(this.delegate.triggerElement, tooltip, {\n ...this.leaderLineOptions,\n color: 'blueviolet'\n })\n\n if (targetTooltip) {\n tooltip.lineToTarget = new LeaderLine(tooltip, targetTooltip, {\n ...this.leaderLineOptions,\n color: 'blueviolet',\n middleLabel: this.delegate.targetLineLabel,\n size: 2.1\n })\n\n targetTooltip.drag.onMove = () => {\n targetTooltip.line.position()\n tooltip.lineToTarget?.position()\n tooltip.lineToRendering?.position()\n }\n }\n\n if (renderingTooltip) {\n tooltip.lineToRendering = new LeaderLine(tooltip, renderingTooltip, {\n ...this.leaderLineOptions,\n color: 'blueviolet',\n middleLabel: this.delegate.renderingLineLabel,\n size: 2.1\n })\n\n renderingTooltip.drag.onMove = () => {\n renderingTooltip.line.position()\n if (tooltip.lineToTarget) tooltip.lineToTarget.position()\n tooltip.lineToRendering?.position()\n }\n }\n\n tooltip.drag = new PlainDraggable(tooltip)\n tooltip.drag.onMove = () => {\n tooltip.line.position()\n if (tooltip.lineToTarget) tooltip.lineToTarget.position()\n if (tooltip.lineToRendering) tooltip.lineToRendering.position()\n }\n\n return tooltip\n }\n\n get leaderLineOptions () {\n return {\n dash: { animation: true },\n dropShadow: { opacity: 0.3 },\n endPlug: 'arrow3',\n endPlugSize: 1.7,\n size: 3,\n startPlug: 'disc',\n startPlugSize: 1\n }\n }\n}\n", "import supervisor from './supervisor'\nimport Devtool from './devtool'\n\nconst { restart, start, stop } = supervisor\n\nfunction decorateElementWithDevtool (element, name, label) {\n Object.assign(element, {\n initializeDevtool () {\n const mouseenter = () => this.devtool.show()\n\n addEventListener('turbo-boost:devtools-start', () => {\n this.devtool = new Devtool(this)\n this.addEventListener('mouseenter', mouseenter)\n })\n\n addEventListener('turbo-boost:devtools-stop', () => {\n this.removeEventListener('mouseenter', mouseenter)\n this.removeDevtool()\n })\n\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-connect', { bubbles: true })\n )\n },\n hideDevtool () {\n this.devtool?.hide({ active: false })\n },\n removeDevtool () {\n this.devtool.hide({ active: false })\n this.devtool.unregisterEventListeners()\n delete this.devtool\n },\n name,\n targetLineLabel: label\n })\n\n Object.defineProperties(element, {\n // the element references below are defaults to be overriden if necessary\n triggerElement: {\n get () {\n return element\n }\n },\n\n morphElement: {\n get () {\n return element\n }\n },\n\n targetElement: {\n get () {\n return element\n }\n }\n })\n}\n\nexport { Devtool, decorateElementWithDevtool }\n\nexport default { restart, start, stop }\n", "export default class TurboBoostElement extends HTMLElement {\n constructor(html) {\n super()\n this.devtool = 'unknown'\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = html || '<slot></slot>'\n }\n\n connectedCallback() {\n this.ensureId()\n }\n\n ensureId() {\n if (this.id.trim().length) return\n this.id = `${this.tagName}-${this.uuidv4()}`.toLowerCase()\n }\n\n // SEE: https://stackoverflow.com/questions/105034/how-do-i-create-a-guid-uuid\n uuidv4() {\n return ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, c =>\n (c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16)\n )\n }\n\n get viewStack() {\n const value = this.getAttribute('view-stack')\n if (!value) return []\n return JSON.parse(value)\n }\n\n get partial() {\n return this.viewStack[0]\n }\n}\n", "import TurboBoostElement from '../../turbo_boost_element'\n\nconst html = `\n <turbo-boost>\n <slot name=\"busy\" hidden></slot>\n <slot></slot>\n </turbo-boost>\n`\n\nexport const busyDelay = 100 // milliseconds - time to wait before showing busy element\nexport const busyDuration = 400 // milliseconds - minimum time that busy element is shown\n\nexport default class ToggleElement extends TurboBoostElement {\n constructor() {\n super(html)\n }\n\n // TODO: Should we timeout after a theoretical max wait time?\n // The idea being that a server error occurred and the toggle failed.\n showBusyElement() {\n clearTimeout(this.showBusyElementTimeout)\n clearTimeout(this.hideBusyElementTimeout)\n\n if (!this.busyElement) return\n\n this.busyStartedAt = Date.now() + busyDelay\n this.showBusyElementTimeout = setTimeout(() => {\n this.busySlotElement.hidden = false\n this.defaultSlotElement.hidden = true\n }, busyDelay)\n }\n\n hideBusyElement() {\n clearTimeout(this.showBusyElementTimeout)\n clearTimeout(this.hideBusyElementTimeout)\n\n if (!this.busyElement) return\n\n let delay = busyDuration - (Date.now() - this.busyStartedAt)\n if (delay < 0) delay = 0\n\n delete this.busyStartedAt\n this.hideBusyElementTimeout = setTimeout(() => {\n this.busySlotElement.hidden = true\n this.defaultSlotElement.hidden = false\n }, delay)\n }\n\n get busyElement() {\n return this.querySelector(':scope > [slot=\"busy\"]')\n }\n\n get busySlotElement() {\n return this.shadowRoot.querySelector('slot[name=\"busy\"]')\n }\n\n get defaultSlotElement() {\n return this.shadowRoot.querySelector('slot:not([name])')\n }\n\n // indicates if an rpc call is active/busy\n get busy() {\n return this.getAttribute('busy') === 'true'\n }\n\n // indicates if an rpc call is active/busy\n set busy(value) {\n value = !!value\n if (this.busy === value) return\n this.setAttribute('busy', value)\n if (value) this.showBusyElement()\n else this.hideBusyElement()\n }\n\n get busyStartedAt() {\n if (!this.dataset.busyStartedAt) return 0\n return Number(this.dataset.busyStartedAt)\n }\n\n set busyStartedAt(value) {\n this.dataset.busyStartedAt = value\n }\n}\n", "import ToggleElement from '../toggle_element'\n\nexport default class ToggleTargetElement extends ToggleElement {\n connectedCallback() {\n super.connectedCallback()\n\n this.mouseenterHandler = this.onMouseenter.bind(this)\n this.addEventListener('mouseenter', this.mouseenterHandler)\n\n this.collapseHandler = this.collapse.bind(this)\n this.collapseNowHandler = this.collapseNow.bind(this)\n\n this.collapseOn.forEach(entry => {\n const parts = entry.split('@')\n const name = parts[0]\n\n if (parts.length > 1) {\n const target = parts[1].match(/^self|window$/) ? self : self[parts[1]]\n target.addEventListener(name, this.collapseNowHandler)\n } else {\n this.addEventListener(name, this.collapseHandler)\n }\n })\n }\n\n disconnectedCallback() {\n this.removeEventListener('mouseenter', this.mouseenterHandler)\n\n this.collapseOn.forEach(entry => {\n const parts = entry.split('@')\n const name = parts[0]\n\n if (parts.length > 1) {\n const target = parts[1].match(/^self|window$/) ? self : self[parts[1]]\n target.removeEventListener(name, this.collapseNowHandler)\n } else {\n this.removeEventListener(name, this.collapseHandler)\n }\n })\n }\n\n // TODO: get cached content working properly\n // perhaps use a mechanic other than morph\n\n // TODO: implement cache (similar to Turbo Drive restoration visit)\n cacheHTML() {\n // this.cachedHTML = this.innerHTML\n }\n\n // TODO: implement cache (similar to Turbo Drive restoration visit)\n renderCachedHTML() {\n // if (!this.cachedHTML) return\n // this.innerHTML = this.cachedHTML\n }\n\n onMouseenter() {\n clearTimeout(this.collapseTimeout)\n }\n\n collapse(delay = 250) {\n clearTimeout(this.collapseTimeout)\n if (this.busy) return\n if (typeof delay !== 'number') delay = 250\n\n if (delay > 0) return (this.collapseTimeout = setTimeout(() => this.collapse(0), delay))\n\n this.innerHTML = ''\n try {\n this.expanded = false\n this.triggerElement.hideDevtool()\n } catch {}\n }\n\n collapseNow(event) {\n if (event.target.closest('turbo-boost-devtool-tooltip')) return\n this.collapse(0)\n }\n\n collapseMatches() {\n document.querySelectorAll(this.collapseSelector).forEach(el => {\n if (el.id === this.id) return\n if (el.collapse) el.collapse(0)\n })\n }\n\n get collapseSelector() {\n return this.triggerElement.collapseSelector || this.getAttribute('collapse-selector')\n }\n\n get focusSelector() {\n return this.getAttribute('focus-selector')\n }\n\n // the active trigger\n get triggerElement() {\n return document.getElementById(this.labeledBy)\n }\n\n // all triggers\n get triggerElements() {\n return document.querySelectorAll(`[aria-controls=\"${this.id}\"]`)\n }\n\n // the dom id of the active trigger\n get labeledBy() {\n return this.getAttribute('aria-labeledby')\n }\n\n set labeledBy(value) {\n return this.setAttribute('aria-labeledby', value)\n }\n\n get collapseOn() {\n const value = this.getAttribute('collapse-on')\n if (!value) return []\n return JSON.parse(value)\n }\n\n get expanded() {\n return this.triggerElement ? this.triggerElement.expanded : false\n }\n\n set expanded(value) {\n this.triggerElements.forEach(el => (el.expanded = value))\n }\n\n get busy() {\n return this.triggerElement && this.triggerElement.busy\n }\n}\n", "let focusTimeout\n\nfunction deactivateTrixAttributes(editor) {\n const attributes = ['bold', 'bullet', 'code', 'heading1', 'href', 'italic', 'number', 'quote', 'strike']\n attributes.forEach(name => editor.deactivateAttribute(name))\n}\n\nfunction focusTrixEditorElement(element) {\n if (element.value.length === 0) return\n\n const editor = element.editor\n\n // move cursor to the end\n let lastRange = []\n while (lastRange[0] !== editor.getSelectedRange()[0] && lastRange[1] !== editor.getSelectedRange()[1]) {\n lastRange = editor.getSelectedRange()\n editor.moveCursorInDirection('forward')\n }\n\n // insert an empty char and select it\n editor.insertString(' ')\n editor.moveCursorInDirection('forward')\n editor.setSelectedRange([lastRange[1], editor.getSelectedRange()[1]])\n\n // deactivate all trix features for the selection\n deactivateTrixAttributes(editor)\n\n // move cursor to end and collapse the selection\n editor.setSelectedRange([editor.getSelectedRange()[1], editor.getSelectedRange()[1]])\n}\n\nfunction debouncedFocus(element) {\n clearTimeout(focusTimeout)\n\n focusTimeout = setTimeout(() => {\n if (!element) return\n\n element.focus()\n const trixEditorElement = element.closest('trix-editor')\n\n try {\n if (trixEditorElement) {\n focusTrixEditorElement(trixEditorElement)\n } else {\n element.selectionStart = element.selectionEnd = element.value.length\n }\n } catch (_) {\n } finally {\n element.scrollIntoView({ block: 'center', behavior: 'smooth' })\n }\n }, 100)\n}\n\nexport default element => debouncedFocus(element)\n", "import { Devtool, decorateElementWithDevtool } from '@turbo-boost/devtools'\n\nimport ToggleElement, { busyDuration } from '../toggle_element'\nimport focus from './focus'\n\ndocument.addEventListener('turbo-boost:devtools-start', () => Devtool.register('toggle', 'toggles'))\n\nlet currentFocusSelector\n\nexport default class ToggleTriggerElement extends ToggleElement {\n constructor() {\n super()\n\n decorateElementWithDevtool(this, 'toggle', 'toggles')\n }\n\n connectedCallback() {\n super.connectedCallback()\n\n const { start: commandStartEvent } = TurboBoost.Commands.events\n this.commandStartHandler = this.onCommandStart.bind(this)\n this.addEventListener(commandStartEvent, this.commandStartHandler)\n\n const { before: beforeInvokeEvent } = TurboBoost.Streams.invokeEvents\n this.beforeInvokeHandler = this.onBeforeInvoke.bind(this)\n addEventListener(beforeInvokeEvent, this.beforeInvokeHandler)\n\n // fires after receiving the toggle morph Turbo Stream but before it is executed\n // this.addEventListener(TurboBoost.Commands.events.success, event => {\n // // TODO: imlement cache, this.targetElement.cacheHTML()\n // })\n\n this.initializeDevtool()\n }\n\n disconnectedCallback() {\n // delay cleanup because the trigger may have been morphed out of the DOM,\n // but it's needed to apply behavior like focus etc...\n setTimeout(() => {\n const { start: commandStartEvent } = TurboBoost.Commands.events\n this.removeEventListener(commandStartEvent, this.commandStartHandler)\n\n const { before: beforeInvokeEvent } = TurboBoost.Streams.invokeEvents\n removeEventListener(beforeInvokeEvent, this.beforeInvokeHandler)\n\n this.removeDevtool()\n }, 1000)\n }\n\n onCommandStart(event) {\n currentFocusSelector = this.focusSelector\n this.targetElement.labeledBy = this.id\n this.targetElement.collapseMatches()\n this.busy = true\n // TODO: implement cache - this.targetElement.renderCachedHTML()\n }\n\n // runs before an invoke turbo stream is executed\n onBeforeInvoke(event) {\n // return early if we're not the element responsible for this invoke\n if (event.detail.method !== 'morph') return\n if (event.target.id !== this.morphs) return\n const selector = `turbo-boost-toggle-target[aria-labeledby=\"${this.id}\"]`\n if (!event.target.querySelector(selector)) return\n\n // ensure the busy element is shown long enough for a good user experience\n // we accomplish this by modifying the event.detail with invoke instructions i.e. { delay }\n // SEE: the TurboBoost Streams library for details on how this works\n const duration = Date.now() - this.busyStartedAt\n let delay = busyDuration - duration\n if (delay < 10) delay = 10\n event.detail.invoke = { delay }\n\n // runs before the morph is executed\n setTimeout(() => {\n this.busy = false\n this.morphToggleTriggerElements.forEach(el => (el.busy = false))\n }, delay - 10)\n\n // runs after the morph is executed\n setTimeout(() => focus(this.targetElement.querySelector(currentFocusSelector)), delay + 100)\n }\n\n // a list of views shared between the trigger and target\n get sharedViews() {\n if (!this.targetElement) return []\n if (!this.targetElement.viewStack) return []\n const reducer = (memo, view) => {\n if (this.targetElement.viewStack.includes(view)) memo.push(view)\n return memo\n }\n return this.viewStack.reduce(reducer.bind(this), [])\n }\n\n // the partial to render\n get renders() {\n return this.getAttribute('renders')\n }\n\n // the renderered partial's top wrapping dom_id\n get morphs() {\n return this.getAttribute('morphs')\n }\n\n // all toggle elements contained by the `morphElement`\n get morphToggleTriggerElements() {\n return Array.from(this.morphElement.querySelectorAll('turbo-boost-toggle-trigger'))\n }\n\n // the target's dom_id\n get controls() {\n return this.getAttribute('aria-controls')\n }\n\n get collapseSelector() {\n return this.getAttribute('collapse-selector')\n }\n\n get focusSelector() {\n return this.getAttribute('focus-selector') || this.targetElement.focusSelector\n }\n\n // indicates if the toggle state should be remembered across requests\n get remember() {\n return this.getAttribute('remember') === 'true'\n }\n\n set remember(value) {\n return this.setAttribute('remember', !!value)\n }\n\n // indicates if the target is expanded\n get expanded() {\n return this.getAttribute('aria-expanded') === 'true'\n }\n\n set expanded(value) {\n this.setAttribute('aria-expanded', !!value)\n }\n\n // indicates if the target is expanded\n get collapsed() {\n return !this.expanded\n }\n\n // ------ DevToolDelegate ------\n get command() {\n return this.dataset.turboCommand\n }\n\n get renderingLineLabel() {\n return 'renders & morphs'\n }\n\n // the morph element\n get morphElement() {\n if (!this.morphs) return null\n return document.getElementById(this.morphs)\n }\n\n // the target element\n get targetElement() {\n if (!this.controls) return null\n return document.getElementById(this.controls)\n }\n\n get triggerTooltipData() {\n let content = this.triggerElement.viewStack\n .reverse()\n .map((view, index) => {\n return this.triggerElement.sharedViews.includes(view)\n ? `<div slot=\"content\">${index + 1}. ${view}</div>`\n : `<div slot=\"content-bottom\">${index + 1}. ${view}</div>`\n }, this)\n .join('')\n\n return {\n subtitle: `\n <b>id</b>: ${this.triggerElement.id}<br>\n <b>aria-controls</b>: ${this.triggerElement.controls}<br>\n <b>aria-expanded</b>: ${this.triggerElement.expanded}<br>\n <b>remember</b>: ${this.triggerElement.remember}<br>\n `,\n content: `\n <div slot=\"content-top\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"12 2 2 7 12 12 22 7 12 2\"></polygon><polyline points=\"2 17 12 22 22 17\"></polyline><polyline points=\"2 12 12 17 22 12\"></polyline></svg>\n <b>View Stack</b>\n </div>\n ${content}\n `\n }\n }\n\n get targetTooltipData() {\n let content = this.targetElement.viewStack\n .reverse()\n .map((view, index) => {\n return this.triggerElement.sharedViews.includes(view)\n ? `<div slot=\"content\">${index + 1}. ${view}</div>`\n : `<div slot=\"content-bottom\">${index + 1}. ${view}</div>`\n }, this)\n .join('')\n\n return {\n subtitle: `<b>id</b>: ${this.targetElement.id}<br>\n <b>aria-labeled-by</b>: ${this.targetElement.labeledBy}<br>\n`,\n content: `\n <div slot=\"content-top\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"12 2 2 7 12 12 22 7 12 2\"></polygon><polyline points=\"2 17 12 22 22 17\"></polyline><polyline points=\"2 12 12 17 22 12\"></polyline></svg>\n <b>View Stack</b>\n </div>\n ${content}\n `\n }\n }\n}\n", "import TurboBoostElement from './turbo_boost_element'\nimport ToggleTargetElement from './toggle_elements/target_element'\nimport ToggleTriggerElement from './toggle_elements/trigger_element'\n\n// Valid custom element names: https://html.spec.whatwg.org/#valid-custom-element-name\n\ncustomElements.define('turbo-boost', TurboBoostElement)\ncustomElements.define('turbo-boost-toggle-target', ToggleTargetElement)\ncustomElements.define('turbo-boost-toggle-trigger', ToggleTriggerElement)\n", "import '@turbo-boost/commands'\nimport devtools from '@turbo-boost/devtools'\nimport './elements'\n\nself.TurboBoost = self.TurboBoost || {}\nself.TurboBoost.devtools = devtools\nself.TurboBoost.Elements = {}\n\nexport default self.TurboBoost.Elements\n"],
|
5
|
-
"mappings": "AAAA,IAAIA,GAAE,OAAO,eAAeC,GAAG,OAAO,iBAAqBC,GAAG,OAAO,0BAA8BC,GAAE,OAAO,sBAA0BC,GAAG,OAAO,UAAU,eAAeC,GAAG,OAAO,UAAU,qBAAyBC,GAAE,CAAC,EAAE,EAAEC,IAAI,KAAK,EAAEP,GAAE,EAAE,EAAE,CAAC,WAAW,GAAG,aAAa,GAAG,SAAS,GAAG,MAAMO,CAAC,CAAC,EAAE,EAAE,CAAC,EAAEA,EAAEC,EAAE,CAAC,EAAE,IAAI,CAAC,QAAQD,KAAK,IAAI,EAAE,CAAC,GAAGH,GAAG,KAAK,EAAEG,CAAC,GAAGD,GAAE,EAAEC,EAAE,EAAEA,CAAC,CAAC,EAAE,GAAGJ,GAAE,QAAQI,KAAKJ,GAAE,CAAC,EAAEE,GAAG,KAAK,EAAEE,CAAC,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AC/B,QAAQ,EACR,IAAI,CAACF,EAAMG,IACH,KAAK,eAAe,YAAY,SAASH,CAAI,EAChD,uBAAuBG,EAAQ,CAAC,KAAKH,CAAI,SACzC,8BAA8BG,EAAQ,CAAC,KAAKH,CAAI,SACnD,IAAI,EACN,KAAK,EAAE,EAEV,MAAO,CACL,SAAU;AAAA,mBACG,KAAK,eAAe,EAAE;AAAA,8BACX,KAAK,eAAe,QAAQ;AAAA,8BAC5B,KAAK,eAAe,QAAQ;AAAA,yBACjC,KAAK,eAAe,QAAQ;AAAA,MAE/C,QAAS;AAAA;AAAA;AAAA;AAAA;AAAA,QAKPE,CAAO;AAAA,KAEX,CACF,CAEA,IAAI,mBAAoB,CACtB,IAAIA,EAAU,KAAK,cAAc,UAC9B,QAAQ,EACR,IAAI,CAACF,EAAMG,IACH,KAAK,eAAe,YAAY,SAASH,CAAI,EAChD,uBAAuBG,EAAQ,CAAC,KAAKH,CAAI,SACzC,8BAA8BG,EAAQ,CAAC,KAAKH,CAAI,SACnD,IAAI,EACN,KAAK,EAAE,EAEV,MAAO,CACL,SAAU,cAAc,KAAK,cAAc,EAAE;AAAA,gCACnB,KAAK,cAAc,SAAS;AAAA,EAEtD,QAAS;AAAA;AAAA;AAAA;AAAA;AAAA,QAKPE,CAAO;AAAA,KAEX,CACF,CACF,EClNA,eAAe,OAAO,cAAeE,CAAiB,EACtD,eAAe,OAAO,4BAA6BC,CAAmB,EACtE,eAAe,OAAO,6BAA8BC,CAAoB,ECJxE,KAAK,WAAa,KAAK,YAAc,CAAC,EACtC,KAAK,WAAW,SAAWC,GAC3B,KAAK,WAAW,SAAW,CAAC,EAE5B,IAAOC,GAAQ,KAAK,WAAW",
|
6
|
-
"names": ["Z", "ee", "te", "X", "re", "oe", "_", "r", "s", "u", "O", "t", "a", "i", "l", "f", "d", "o", "B", "k", "c", "A", "F", "D", "g", "N", "J", "E", "h", "ne", "se", "v", "L", "ae", "ie", "S", "M", "T", "R", "de", "m", "j", "me", "ue", "ce", "W", "
|
3
|
+
"sources": ["../../../../node_modules/@turbo-boost/commands/app/assets/builds/@turbo-boost/commands.js", "../../../../node_modules/@turbo-boost/devtools/src/utils/dom.js", "../../../../node_modules/@turbo-boost/devtools/src/elements/devtool_element.js", "../../../../node_modules/@turbo-boost/devtools/src/elements/supervisor_element.js", "../../../../node_modules/@turbo-boost/devtools/src/elements/tooltip_element.js", "../../../../node_modules/@turbo-boost/devtools/src/dependencies.js", "../../../../node_modules/@turbo-boost/devtools/src/supervisor.js", "../../../../node_modules/@turbo-boost/devtools/src/devtool.js", "../../../../node_modules/@turbo-boost/devtools/src/delegates/cable_ready.js", "../../../../node_modules/@turbo-boost/devtools/src/index.js", "../../../javascript/elements/turbo_boost_element/index.js", "../../../javascript/elements/toggle_elements/toggle_element/index.js", "../../../javascript/elements/toggle_elements/target_element/index.js", "../../../javascript/elements/toggle_elements/trigger_element/focus.js", "../../../javascript/elements/toggle_elements/trigger_element/index.js", "../../../javascript/elements/index.js", "../../../javascript/index.js"],
|
4
|
+
"sourcesContent": ["var Z=Object.defineProperty,ee=Object.defineProperties;var te=Object.getOwnPropertyDescriptors;var X=Object.getOwnPropertySymbols;var re=Object.prototype.hasOwnProperty,oe=Object.prototype.propertyIsEnumerable;var _=(e,t,r)=>t in e?Z(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,s=(e,t)=>{for(var r in t||(t={}))re.call(t,r)&&_(e,r,t[r]);if(X)for(var r of X(t))oe.call(t,r)&&_(e,r,t[r]);return e},u=(e,t)=>ee(e,te(t));var O=class{get element(){return document.querySelector('meta[name=\"turbo-boost\"]')}get token(){return this.element.getAttribute(\"content\")}get busy(){return this.element.dataset.busy===\"true\"}set busy(t){return this.element.dataset.busy=!!t}},a=new O;var i={start:\"turbo-boost:command:start\",success:\"turbo-boost:command:success\",finish:\"turbo-boost:command:finish\",abort:\"turbo-boost:command:abort\",clientError:\"turbo-boost:command:client-error\",serverError:\"turbo-boost:command:server-error\"},l={stateLoad:\"turbo-boost:state:load\",stateChange:\"turbo-boost:state:change\"},f=s(s({},i),l);function d(e,t,r={}){return new Promise(o=>{r=r||{},r.detail=r.detail||{},t=t||document;let n=new CustomEvent(e,u(s({},r),{bubbles:!0}));t.dispatchEvent(n),o(n)})}var B;function k(e,t=null){if(!e||typeof e!=\"object\")return e;let r=new Proxy(e,{deleteProperty(o,n){return delete o[n],d(l.stateChange,a.element,{detail:{state:B}}),!0},set(o,n,c,A){return o[n]=k(c,this),d(l.stateChange,a.element,{detail:{state:B}}),!0}});if(Array.isArray(e))e.forEach((o,n)=>e[n]=k(o,r));else if(typeof e==\"object\")for(let[o,n]of Object.entries(e))e[o]=k(n,r);return t||(B=r),r}var F=k;var D,g,C,N;function J(){if(!a.element)return E();let e=atob(a.element.dataset.state);C={},g=F(JSON.parse(e)),D=s({},g),delete a.element.dataset.clientStateChange,setTimeout(()=>d(l.stateLoad,a.element,{detail:{state:g}}))}function E(){clearTimeout(N),N=setTimeout(J,10)}D||J();addEventListener(\"DOMContentLoaded\",E);addEventListener(\"load\",E);addEventListener(\"turbo:load\",E);addEventListener(\"turbo:frame-load\",E);addEventListener(i.success,E);addEventListener(l.stateChange,e=>{C={};for(let[t,r]of Object.entries(g))D[t]!==r&&(C[t]=r);a.element.dataset.clientStateChange=!0,a.element.dataset.state=btoa(JSON.stringify(g))});var h={events:l,get current(){return g},get delta(){return C},get payloadChunks(){return btoa(JSON.stringify(C)).match(/.{1,2000}/g)}};function ne(e){let t=\"<html\",r=\"</html\",o=e.indexOf(t),n=e.lastIndexOf(r);if(o>=0&&n>=0){let c=e.slice(e.indexOf(\">\",o)+1,n);document.documentElement.innerHTML=c}}function se(e){document.body.insertAdjacentHTML(\"beforeend\",e)}var v={append:se,replaceDocument:ne};var L={};function ae(e){L[e.id]=e}function ie(e){delete L[e]}var S={add:ae,remove:ie,get commands(){return[...Object.values(L)]},get length(){return Object.keys(L).length}};function M(e){e.detail.endedAt=Date.now(),e.detail.milliseconds=e.detail.endedAt-e.detail.startedAt,setTimeout(()=>d(i.finish,e.target,{detail:e.detail}),25)}addEventListener(i.serverError,M);addEventListener(i.success,M);addEventListener(i.finish,e=>S.remove(e.detail.id),!0);var T={events:i};var R={};addEventListener(\"turbo:before-fetch-request\",e=>{let t=e.target.closest(\"turbo-frame\"),{fetchOptions:r}=e.detail;if(a.busy){let o=[\"text/vnd.turbo-boost.html\",r.headers.Accept];o=o.filter(n=>n&&n.trim().length>0).join(\", \"),r.headers.Accept=o,r.headers[\"TurboBoost-Token\"]=a.token}h.payloadChunks.forEach((o,n)=>{r.headers[`TurboBoost-State-${n.toString().padStart(4,\"0\")}`]=o})});addEventListener(\"turbo:before-fetch-response\",e=>{let t=e.target.closest(\"turbo-frame\"),{fetchResponse:r}=e.detail;if(t&&(R[t.id]=t.src),r.header(\"TurboBoost\")){if(r.statusCode<200||r.statusCode>399){let o=`Server returned a ${r.statusCode} status code! TurboBoost Commands require 2XX-3XX status codes.`;d(T.events.clientError,document,{detail:u(s({},e.detail),{error:o})},!0)}r.header(\"TurboBoost\")===\"Append\"&&(e.preventDefault(),r.responseText.then(o=>v.append(o)))}});addEventListener(\"turbo:frame-load\",e=>{let t=e.target.closest(\"turbo-frame\");t.dataset.turboBoostSrc=R[t.id]||t.src||t.dataset.turboBoostSrc,delete R[t.id]});var de={frameAttribute:\"data-turbo-frame\",methodAttribute:\"data-turbo-method\",commandAttribute:\"data-turbo-command\",confirmAttribute:\"data-turbo-confirm\"},m=s({},de);var j={method:e=>Promise.resolve(confirm(e))},me=e=>e.detail.driver===\"method\",ue=e=>{if(e.detail.driver!==\"form\")return!1;let t=e.target,r=t.closest(\"turbo-frame\"),o=t.closest(`[${m.frameAttribute}]`);return!!(r||o)},ce=e=>me(e)||ue(e);document.addEventListener(i.start,async e=>{let t=e.target.getAttribute(m.confirmAttribute);if(!t||(e.detail.confirmation=!0,ce(e)))return;await j.method(t)||e.preventDefault()});var W=j;var b=[],$;function le(e,t){let r=b.find(o=>o.name===e);return r&&b.splice(b.indexOf(r),1),b=[{name:e,selectors:t},...b],document.removeEventListener(e,$,!0),document.addEventListener(e,$,!0),s({},b.find(o=>o.name===e))}function fe(e){return b.find(t=>t.selectors.find(r=>Array.from(document.querySelectorAll(r)).find(o=>o===e)))}function be(e,t){let r=fe(t);return r&&r.name===e}var p={register:le,isRegisteredForElement:be,get events(){return[...b]},set handler(e){$=e}};function pe(e){return e.closest(`[${m.commandAttribute}]`)}function he(e){return e.closest(\"turbo-frame[src]\")||e.closest(\"turbo-frame[data-turbo-frame-src]\")||e.closest(\"turbo-frame\")}function ve(e,t={}){if(e.tagName.toLowerCase()!==\"select\")return t.value=e.value||null;if(!e.multiple)return t.value=e.options[e.selectedIndex].value;t.values=Array.from(e.options).reduce((r,o)=>(o.selected&&r.push(o.value),r),[])}function ge(e){let t=Array.from(e.attributes).reduce((r,o)=>{let n=o.value;return r[o.name]=n,r},{});return t.tag=e.tagName,t.checked=!!e.checked,t.disabled=!!e.disabled,ve(e,t),delete t.class,delete t.action,delete t.href,delete t[m.commandAttribute],delete t[m.frameAttribute],t}var y={buildAttributePayload:ge,findClosestCommand:pe,findClosestFrameWithSource:he};function Ee(e,t={}){t.token=a.token;let r=document.createElement(\"input\");r.type=\"hidden\",r.name=\"turbo_boost_command\",r.value=JSON.stringify(t),e.appendChild(r)}var U={invokeCommand:Ee};function xe(e,t={}){let r=document.createElement(\"a\");r.href=e;let o=new URL(r);return o.searchParams.set(\"turbo_boost_command\",JSON.stringify(t)),o}var x={build:xe};function Ce(e,t){let r=t.src;t=s({},t),delete t.src,e.src=x.build(r,t)}var H={invokeCommand:Ce};function Te(e,t={}){let r=t.src;t=s({},t),delete t.src,delete t.href,e.setAttribute(\"href\",x.build(r,t))}var V={invokeCommand:Te};function ye(e){let t=e.target;d(T.events.abort,document,{detail:u(s({},e.detail),{xhr:t})})}function P(e){let t=e.target;t.getResponseHeader(\"TurboBoost\")===\"Append\"||t.getResponseHeader(\"Content-Type\").startsWith(\"text/vnd.turbo-boost.html\")?v.append(t.responseText):v.replaceDocument(t.responseText);let o=`Server returned a ${t.status} status code! TurboBoost Commands require 2XX-3XX status codes.`;d(T.events.clientError,document,{detail:u(s({},e.detail),{error:o,xhr:t})},!0)}function Ae(e){let t=e.target;if(t.status<200||t.status>399)return P(e);let r=t.responseText;t.getResponseHeader(\"TurboBoost\")===\"Append\"||t.getResponseHeader(\"Content-Type\").startsWith(\"text/vnd.turbo-boost.html\")?v.append(t.responseText):v.replaceDocument(t.responseText)}function ke(e){let t=e.src;e=s({},e),delete e.src;try{let r=new XMLHttpRequest;r.open(\"GET\",x.build(t,e),!0),r.setRequestHeader(\"Accept\",\"text/vnd.turbo-boost.html, text/html, application/xhtml+xml\"),r.setRequestHeader(\"TurboBoost-Token\",a.token),h.payloadChunks.forEach((o,n)=>r.setRequestHeader(`TurboBoost-State-${n.toString().padStart(4,\"0\")}`,o)),r.addEventListener(\"abort\",ye),r.addEventListener(\"error\",P),r.addEventListener(\"load\",Ae),r.send()}catch(r){let o=`Unexpected error sending HTTP request! ${r.message}`;P(r,{detail:{message:o}})}}var G={invokeCommand:ke};function q(e,t){return t=t||{dataset:{}},e.href||t.src||t.dataset.turboBoostSrc||location.href}function Le(e){let t=y.findClosestFrameWithSource(e),{turboFrame:r,turboMethod:o}=e.dataset;return e.tagName.toLowerCase()===\"form\"?{name:\"form\",reason:\"Element is a form.\",frame:t,src:e.action,invokeCommand:U.invokeCommand}:o&&o.length>0?{name:\"method\",reason:\"Element defines data-turbo-method.\",frame:t,src:e.href,invokeCommand:V.invokeCommand}:r&&r!==\"_self\"?(t=document.getElementById(r),{name:\"frame\",reason:\"element targets a frame that is not _self\",frame:t,src:q(e,t),invokeCommand:H.invokeCommand}):(!r||r===\"_self\")&&t?{name:\"frame\",reason:\"element does NOT target a frame or targets _self and is contained by a frame\",frame:t,src:q(e,t),invokeCommand:H.invokeCommand}:{name:\"window\",reason:\"element matches one or more of the following conditions (targets _top, does NOT target a frame, is NOT contained by a frame)\",frame:null,src:q(e),invokeCommand:G.invokeCommand}}var I={find:Le};var w=\"unknown\",z={debug:Object.values(f),info:Object.values(f),warn:[f.abort,f.clientError,f.serverError],error:[f.clientError,f.serverError],unknown:[]};Object.values(f).forEach(e=>{addEventListener(e,t=>{if(z[w].includes(t.type)){let{target:r,detail:o}=t;console[w](t.type,{target:r,detail:o})}})});var K={get level(){return w},set level(e){return Object.keys(z).includes(e)||(e=\"unknown\"),w=e}};function Se(){return([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,e=>(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16))}var Q={v4:Se};function Y(e,t){return{id:e,name:t.getAttribute(m.commandAttribute),elementId:t.id.length>0?t.id:null,elementAttributes:y.buildAttributePayload(t),startedAt:Date.now()}}async function we(e){let t,r={};try{if(t=y.findClosestCommand(e.target),!t||!p.isRegisteredForElement(e.type,t))return;let o=`turbo-command-${Q.v4()}`,n=I.find(t),c=u(s({},Y(o,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),A=await d(i.start,t,{cancelable:!0,detail:c});if(A.defaultPrevented||A.detail.confirmation&&e.defaultPrevented)return d(i.abort,t,{detail:{message:`An event handler for '${i.start}' prevented default behavior and blocked command invocation!`,source:A}});switch(n=I.find(t),c=u(s({},Y(o,t)),{driver:n.name,frameId:n.frame?n.frame.id:null,src:n.src}),S.add(c),[\"frame\",\"window\"].includes(n.name)&&e.preventDefault(),a.busy=!0,setTimeout(()=>a.busy=!1,10),n.name){case\"method\":return n.invokeCommand(t,c);case\"form\":return n.invokeCommand(t,c);case\"frame\":return n.invokeCommand(n.frame,c);case\"window\":return n.invokeCommand(c)}}catch(o){d(i.clientError,t,{detail:u(s({},r),{error:o})})}}self.TurboBoost=self.TurboBoost||{};self.TurboBoost=u(s({},self.TurboBoost),{stateEvents:l,get state(){return h.current},get stateDelta(){return h.delta}});self.TurboBoost.Commands||(p.handler=we,p.register(\"click\",[`[${m.commandAttribute}]`]),p.register(\"submit\",[`form[${m.commandAttribute}]`]),p.register(\"change\",[`input[${m.commandAttribute}]`,`select[${m.commandAttribute}]`,`textarea[${m.commandAttribute}]`]),self.TurboBoost.Commands={confirmation:W,logger:K,schema:m,events:i,registerEventDelegate:p.register,get eventDelegates(){return p.events}});var Qt=self.TurboBoost.Commands;export{Qt as default};\n//# sourceMappingURL=commands.js.map\n", "export function template (html) {\n let template = document.createElement('template')\n template.innerHTML = html\n return template\n}\n\nexport function appendHTML (html, parent) {\n parent = parent || document.body\n const clone = template(html).content.cloneNode(true)\n const child = clone.querySelector('*')\n return parent.appendChild(child)\n}\n\nexport function addHighlight (element, options = {}) {\n if (!element) return\n removeHighlight(element)\n let { outline, outlineOffset } = options\n\n outline = outline || 'dashed 3px red'\n outlineOffset = outlineOffset || '0px'\n\n element.originalStyles = element.originalStyles || {\n display: element.style.display,\n minHeight: element.style.minHeight,\n minWidth: element.style.minWidth,\n outline: element.style.outline,\n outlineOffset: element.style.outlineOffset\n }\n\n if (\n getComputedStyle(element).display.match(/^inline$/i) &&\n element.offsetWidth === 0 &&\n element.offsetHeight === 0\n ) {\n element.style.display = 'inline-block'\n element.style.minHeight = '2px'\n element.style.minWidth = '2px'\n }\n element.style.outline = outline\n element.style.outlineOffset = outlineOffset\n element.dataset.turboBoostHighlight = true\n}\n\nexport function removeHighlight (element) {\n if (!element) return\n if (element.originalStyles) {\n for (const [key, value] of Object.entries(element.originalStyles))\n value ? (element.style[key] = value) : (element.style[key] = '')\n delete element.originalStyles\n }\n delete element.dataset.turboBoostHighlight\n}\n\nexport function coordinates (element) {\n if (!element) return {}\n const rect = element.getBoundingClientRect()\n const width = element.offsetWidth\n const height = element.offsetHeight\n const top = rect.top + window.scrollY\n const left = rect.left + window.scrollX\n const right = left + width\n const bottom = top + height\n return { top, left, right, bottom, width, height }\n}\n\nexport function attempt (callback) {\n try {\n callback()\n } catch {}\n}\n", "export default class DevtoolElement extends HTMLElement {\n constructor () {\n super()\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = this.html\n this.labelElement.addEventListener('click', event => {\n event.preventDefault()\n this.toggle()\n })\n this.checkboxElement.addEventListener('change', event =>\n this.dispatchEvent(new CustomEvent('change', { bubbles: true }))\n )\n }\n\n toggle () {\n this.checked ? this.uncheck() : this.check()\n }\n\n check () {\n this.checkboxElement.checked = true\n this.dispatchEvent(new CustomEvent('change', { bubbles: true }))\n }\n\n uncheck () {\n this.checkboxElement.checked = false\n this.dispatchEvent(new CustomEvent('change', { bubbles: true }))\n }\n\n get name () {\n return this.getAttribute('name')\n }\n\n get checked () {\n return this.checkboxElement.checked\n }\n\n get checkboxElement () {\n return this.shadowRoot.querySelector('input')\n }\n\n get labelElement () {\n return this.shadowRoot.querySelector('label')\n }\n\n get html () {\n return `\n <style>${this.stylesheet}</style>\n <div>\n <input name=\"checkbox\" type=\"checkbox\">\n <label for=\"checkbox\"><slot name=\"label\"></slot></label>\n </div>\n `\n }\n\n get stylesheet () {\n return `\n :host, :host * {\n cursor: pointer;\n }\n\n div {\n display: flex;\n margin-right: 10px;\n }\n\n input:checked + label{\n font-weight: bold;\n }\n\n label {\n color: black;\n }\n `\n }\n}\n", "import { appendHTML } from '../utils/dom.js'\n\nexport default class SupervisorElement extends HTMLElement {\n constructor () {\n super()\n this.enabledDevtools = {}\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = this.html\n this.shadowRoot.querySelector('button').addEventListener('click', () =>\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-close', {\n bubbles: true\n })\n )\n )\n\n this.addEventListener('change', event => {\n const devtoolElement = event.target\n const { checked, name } = devtoolElement\n checked ? this.enableDevtool(name) : this.disableDevtool(name)\n })\n }\n\n enableDevtool (name) {\n if (this.enabledDevtools[name]) return\n this.enabledDevtools[name] = true\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtool-enable', {\n bubbles: true,\n detail: { name: name }\n })\n )\n }\n\n disableDevtool (name) {\n if (!this.enabledDevtools[name]) return\n delete this.enabledDevtools[name]\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtool-disable', {\n bubbles: true,\n detail: { name: name }\n })\n )\n }\n\n close () {\n this.devtoolElements.forEach(el => {\n if (el.checked) el.uncheck()\n })\n this.remove()\n }\n\n get devtoolElements () {\n return this.querySelectorAll('[slot=\"devtool\"]')\n }\n\n get closeElement () {\n return this.querySelector('button')\n }\n\n get html () {\n return `\n <style>${this.stylesheet}</style>\n <div>\n <img src=\"https://ik.imagekit.io/hopsoft/turbo-boost-logo_zHiiimlvT.webp?ik-sdk-version=javascript-1.4.3&updatedAt=1671722004342\">\n <slot name=\"devtool\"></slot>\n <button>\u2715</button>\n </div>\n `\n }\n\n get stylesheet () {\n return `\n :host {\n background-color: gainsboro;\n border-radius: 5px;\n bottom: 20px;\n display: block;\n filter: drop-shadow(3px 3px 3px rgba(0,0,0,0.3));\n left: 50%;\n outline-offset: 1px;\n outline: solid 2px black;\n padding: 5px 10px;\n position: fixed;\n transform: translateX(-50%);\n z-index: 8999;\n }\n\n * {\n -webkit-user-select: none;\n font-family: helvetica, sans-serif;\n font-size: 1rem;\n user-select: none;\n }\n\n img {\n align-self: center;\n cursor: grab;\n height: 25px;\n margin-left: -5px;\n vertical-align: middle;\n }\n\n div {\n display: flex;\n gap: 0 5px;\n position: relative;\n }\n\n [slot=\"devtool\"] {\n align-self: center;\n }\n\n button {\n align-self: center;\n background-color: darkgray;\n border-radius: 50%;\n border: none;\n color: black;\n cursor: pointer;\n font-size: 10px;\n height: 18px;\n line-height: 18px;\n margin-right: -5px;\n opacity: 0.5;\n outline: solid 1px black;\n padding: 0 2px;\n width: 18px;\n }\n\n button:hover {\n opacity: 1;\n }\n `\n }\n}\n", "export default class TooltipElement extends HTMLElement {\n constructor () {\n super()\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = this.html\n }\n\n connectedCallback () {\n const savedTransform = localStorage.getItem(\n `turbo-boost-devtools-${location.href}-${this.id}-transform`\n )\n\n if (savedTransform) {\n this.style.transform = savedTransform\n }\n }\n\n disconnectedCallback () {\n if (this.id !== 'undefined' && this.id !== '') {\n localStorage.setItem(\n `turbo-boost-devtools-${location.href}-${this.id}-transform`,\n this.style.transform\n )\n }\n }\n\n get color () {\n return this.getAttribute('color') || 'darkslategray'\n }\n\n get backgroundColor () {\n return this.getAttribute('background-color') || 'gainsboro'\n }\n\n get position () {\n return this.getAttribute('position') || 'top'\n }\n\n get html () {\n return `\n <style>${this.stylesheet}</style>\n <div role=\"container\">\n <div role=\"title\">\n <slot name=\"title\"></slot>\n <img src=\"https://ik.imagekit.io/hopsoft/turbo-boost-logo_zHiiimlvT.webp?ik-sdk-version=javascript-1.4.3&updatedAt=1671722004342\">\n </div>\n <slot name=\"subtitle\"></slot>\n <slot name=\"content-top\"></slot>\n <slot name=\"content\"></slot>\n <slot name=\"content-bottom\"></slot>\n </div>\n `\n }\n\n get stylesheet () {\n return `\n :host {\n display: block;\n position: absolute;\n z-index: 8999;\n }\n\n * {\n color: ${this.color}\n font-size: 1rem;\n }\n\n [role=\"container\"] {\n background-color: ${this.backgroundColor};\n border-radius: 15px;\n filter: drop-shadow(3px 3px 3px rgba(0,0,0,0.3));\n font-family: monospace;\n min-height: 30px;\n min-width: 100px;\n opacity: 0.9;\n outline-offset: 1px;\n outline: dashed 3px ${this.color};\n padding: 12px;\n position: relative;\n white-space: nowrap;\n }\n\n [role=\"title\"] {\n display: flex;\n }\n\n [role=\"title\"] slot[name=\"title\"] {\n color: ${this.color};\n display: block;\n flex-grow: 1;\n font-weight: bold;\n }\n\n [role=\"title\"] img {\n height: 25px;\n vertical-align: middle;\n }\n\n slot[name=\"subtitle\"] {\n border-bottom: dotted 1px ${this.color};\n border-top: dotted 1px ${this.color};\n color: ${this.color};\n display: block;\n font-size: 0.8rem;\n font-weight: lighter;\n margin-bottom: 12px;\n margin-top: 8px;\n padding-bottom: 4px;\n padding-top: 4px;\n width: 100%;\n }\n\n slot[name=\"content-top\"],\n slot[name=\"content\"],\n slot[name=\"content-bottom\"] {\n display: block;\n font-weight: normal;\n }\n\n slot[name=\"content-top\"] {\n color: ${this.color};\n margin-bottom: 8px;\n }\n\n slot[name=\"content\"],\n slot[name=\"content-bottom\"] {\n opacity: 0.7;\n padding-left: 12px;\n }\n\n slot[name=\"content\"] {\n color: ${this.color};\n }\n\n slot[name=\"content-bottom\"] {\n color: red;\n }\n `\n }\n}\n", "const added = []\n\nconst dependencies = {\n LeaderLine: {\n src:\n 'https://cdnjs.cloudflare.com/ajax/libs/leader-line/1.0.7/leader-line.min.js',\n integrity:\n 'sha512-0dNdzMjpT6pJdFGF1DwybFCfm3K/lzHhxaMXC/92J9/DZujHlqYFqmhTOAoD0o+LkeEsVK2ar/ESs7/Q2B6wJg==',\n global: 'LeaderLine'\n },\n\n PlainDraggable: {\n src:\n 'https://cdn.jsdelivr.net/npm/plain-draggable@2.5.14/plain-draggable.min.js',\n global: 'PlainDraggable'\n }\n}\n\nfunction exists (dependency) {\n if (dependency.global && self[dependency.global]) return true\n if (document.querySelector(`[src='${dependency.src}']`)) return true\n return added.includes(dependency)\n}\n\nfunction add (dependency) {\n if (exists(dependency)) return\n added.push(dependency)\n\n const { src, integrity } = dependency\n const script = document.createElement('script')\n script.setAttribute('src', src)\n script.setAttribute('crossorigin', 'anonymous')\n script.setAttribute('referrerpolicy', 'no-referrer')\n if (integrity) script.setAttribute('integrity', integrity)\n document.head.appendChild(script)\n}\n\nfunction remove (dependency) {\n if (!added.includes(dependency)) return\n added.splice(added.indexOf(dependency), 1)\n\n const { src } = dependency\n const el = document.querySelector(`script[src='${src}']`)\n if (el) el.remove()\n if (dependency.global && self[dependency.global])\n self[dependency.global] = null\n}\n\nfunction removeAll () {\n ;[...added].forEach(dependency => remove(dependency))\n}\n\nexport default { ...dependencies, add, remove, removeAll }\n", "import { appendHTML } from './utils/dom'\nimport DevtoolElement from './elements/devtool_element'\nimport SupervisorElement from './elements/supervisor_element'\nimport TooltipElement from './elements/tooltip_element'\nimport dependencies from './dependencies'\n\ncustomElements.define('turbo-boost-devtool', DevtoolElement)\ncustomElements.define('turbo-boost-devtool-supervisor', SupervisorElement)\ncustomElements.define('turbo-boost-devtool-tooltip', TooltipElement)\n\nlet supervisorElement\n\nfunction makeDraggable () {\n if (!supervisorElement) return\n try {\n new PlainDraggable(supervisorElement)\n } catch {\n setTimeout(makeDraggable, 200)\n }\n}\n\nfunction stop () {\n if (stopped()) return\n supervisorElement.close()\n supervisorElement.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-stop', {\n bubbles: true\n })\n )\n supervisorElement = null\n dependencies.removeAll()\n}\n\nfunction start () {\n if (started()) return\n dependencies.add(dependencies.LeaderLine)\n dependencies.add(dependencies.PlainDraggable)\n supervisorElement = appendHTML(\n '<turbo-boost-devtool-supervisor></turbo-boost-devtool-supervisor>'\n )\n setTimeout(makeDraggable, 200)\n supervisorElement.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-start', {\n bubbles: true\n })\n )\n}\n\nfunction restart () {\n const enabledList = supervisorElement\n ? Object.keys(supervisorElement.enabledDevtools)\n : []\n\n stop()\n start()\n\n supervisorElement.devtoolElements.forEach(el => {\n if (enabledList.includes(el.name)) el.check()\n })\n}\n\nfunction started () {\n return !!supervisorElement\n}\n\nfunction stopped () {\n return !started()\n}\n\nlet restartTimeout\nfunction debouncedRestart () {\n clearTimeout(restartTimeout)\n restartTimeout = setTimeout(restart, 25)\n}\n\nfunction autoRestart () {\n if (started()) debouncedRestart()\n}\n\naddEventListener('turbo:load', autoRestart)\naddEventListener('turbo-frame:load', autoRestart)\naddEventListener('turbo-boost:devtools-connect', autoRestart)\naddEventListener('turbo-boost:devtools-close', stop)\n\nif (window.TurboBoost) {\n addEventListener(TurboBoost.Commands.events.success, autoRestart)\n addEventListener(TurboBoost.Commands.events.finish, autoRestart)\n}\n\nfunction register (name, label) {\n if (!supervisorElement) return\n return appendHTML(\n `\n <turbo-boost-devtool name=\"${name}\" slot=\"devtool\">\n <span slot=\"label\">${label}</span>\n </turbo-boost-devtool>\n `,\n supervisorElement\n )\n}\n\nfunction enabled (name) {\n if (!supervisorElement) return false\n return supervisorElement.enabledDevtools[name]\n}\n\nexport default {\n enabled,\n register,\n start,\n stop,\n restart: debouncedRestart,\n get started () {\n return started()\n },\n get stopped () {\n return stopped()\n }\n}\n", "// Icons courtesy of https://feathericons.com/\nimport supervisor from './supervisor'\nimport {\n appendHTML,\n addHighlight,\n attempt,\n coordinates,\n removeHighlight\n} from './utils/dom.js'\n\nfunction appendTooltip (title, subtitle, content, options = {}) {\n let { backgroundColor, color, position, id } = options\n color = color || 'white'\n position = position || 'top'\n return appendHTML(`\n <turbo-boost-devtool-tooltip id=\"${id}\" position=\"${position}\" background-color=\"${backgroundColor}\" color=\"${color}\">\n <div slot='title'>${title}</div>\n <div slot='subtitle'>${subtitle}</div>\n ${content}\n </turbo-boost-devtool-tooltip>\n `)\n}\n\nlet activeTarget\n\nexport default class Devtool {\n constructor (delegate) {\n this.delegate = delegate\n\n let hideTimeout\n const debouncedHide = () => {\n clearTimeout(hideTimeout)\n hideTimeout = setTimeout(this.hide({ active: false }), 25)\n }\n\n this.eventListeners['turbo-boost:devtool-enable'] = event => {\n // LeaderLine.positionByWindowResize = false\n const { name } = event.detail\n if (name !== this.delegate.name) return\n\n addHighlight(this.delegate.triggerElement, {\n outline: '3px dashed blueviolet',\n outlineOffset: '2px'\n })\n\n this.hide({ active: false })\n if (this.active) this.show()\n }\n\n this.eventListeners['turbo-boost:devtool-disable'] = event => {\n const { name } = event.detail\n if (name === this.delegate.name)\n removeHighlight(this.delegate.triggerElement)\n }\n\n this.eventListeners['click'] = event => {\n if (event.target.closest('turbo-boost-devtool-tooltip')) return\n debouncedHide()\n }\n\n this.eventListeners['turbo:load'] = debouncedHide\n this.eventListeners['turbo-frame:load'] = debouncedHide\n if (window.TurboBoost) {\n this.eventListeners[TurboBoost.Commands.events.finish] = debouncedHide\n }\n\n this.registerEventListeners()\n }\n\n registerEventListeners () {\n Object.entries(this.eventListeners).forEach(([type, listener]) => {\n addEventListener(type, listener)\n })\n }\n\n unregisterEventListeners () {\n Object.entries(this.eventListeners).forEach(([type, listener]) => {\n removeEventListener(type, listener)\n })\n }\n\n get eventListeners () {\n return this._eventListeners || (this._eventListeners = {})\n }\n\n show () {\n if (!this.enabled) return\n\n if (this.active) return\n this.active = true\n\n this.hide({ active: true })\n\n addHighlight(this.delegate.targetElement, {\n outline: '3px dashed darkcyan',\n outlineOffset: '-2px'\n })\n\n addHighlight(this.delegate.morphElement, {\n outline: '3px dashed chocolate',\n outlineOffset: '3px'\n })\n\n this.renderingTooltip = this.createRenderingTooltip()\n this.targetTooltip = this.createTargetTooltip()\n this.triggerTooltip = this.createTriggerTooltip(\n this.targetTooltip,\n this.renderingTooltip\n )\n\n document\n .querySelectorAll('.leader-line')\n .forEach(el => (el.style.zIndex = 100000))\n\n const data = {\n morph: {\n partial: this.delegate.triggerElement.renders,\n id: this.delegate.triggerElement.morphs,\n status: this.delegate.morphElement ? 'OK' : 'Not Found'\n },\n trigger: { partial: null, id: null, status: 'Not Found' },\n target: { partial: null, id: null, status: 'Not Found' }\n }\n\n if (this.delegate.triggerElement) {\n data.trigger = {\n partial: this.delegate.triggerElement.partial,\n id: this.delegate.triggerElement.id,\n status: 'OK'\n }\n data.target.id = this.delegate.triggerElement.controls\n }\n\n if (this.delegate.targetElement)\n data.target = {\n partial: this.delegate.targetElement.partial,\n dom_id: this.delegate.targetElement.id,\n status: 'OK'\n }\n\n console.table(data)\n }\n\n hide ({ active: active = false }) {\n document\n .querySelectorAll('turbo-boost-devtool-tooltip')\n .forEach(tooltip => {\n attempt(() => tooltip.line.remove())\n attempt(() => tooltip.drag.remove())\n attempt(() => tooltip.lineToRendering.remove())\n attempt(() => tooltip.lineToTarget.remove())\n attempt(() => tooltip.remove())\n })\n\n document.querySelectorAll('[data-turbo-boost-highlight]').forEach(el => {\n if (!el.tagName.match(/turbo-boost-toggle-trigger/i)) removeHighlight(el)\n })\n\n this.active = active\n }\n\n get active () {\n return activeTarget === this.delegate\n }\n\n set active (value) {\n if (value) activeTarget = this.delegate\n else activeTarget = null\n }\n\n get enabled () {\n return supervisor.enabled(this.delegate.name)\n }\n\n static register (name, label) {\n supervisor.register(name, label)\n }\n\n createRenderingTooltip () {\n if (!this.delegate.triggerElement.renders)\n return console.debug(\n `Unable to create the rendering tooltip! The trigger element must set the 'renders' attribute.`\n )\n\n if (!this.delegate.triggerElement.morphs)\n return console.debug(\n `Unable to create the rendering tooltip! The trigger element specified the 'morphs' attrbiute but no element matches the DOM id: '${this.triggerElement.morphs}'`\n )\n\n const title = `\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M12 19l7-7 3 3-7 7-3-3z\"></path><path d=\"M18 13l-1.5-7.5L2 2l3.5 14.5L13 18l5-5z\"></path><path d=\"M2 2l7.586 7.586\"></path><circle cx=\"11\" cy=\"11\" r=\"2\"></circle></svg>\n RENDERING - <${this.delegate.triggerElement.tagName.toLowerCase()}>\n `\n const subtitle = `\n <b>partial</b>: ${this.delegate.triggerElement.renders || 'unknown'}<br>\n <b>morphs</b>: ${this.delegate.triggerElement.morphs || 'unknown'}<br>\n `\n const content = `\n <div slot=\"content-top\" style=\"font-size:85%; font-style:italic; font-weight:100;\">\n The <b>TRIGGER</b> toggles the <b>TARGET</b> then renders the partial & morphs the element.<br>\n </div>\n `\n const tooltip = appendTooltip(title, subtitle, content, {\n id: `${this.delegate.id}-rendering`,\n backgroundColor: 'lightyellow',\n color: 'chocolate'\n })\n\n const coords = coordinates(this.delegate.morphElement)\n const top = Math.ceil(\n coords.top + coords.height / 2 - tooltip.offsetHeight / 2\n )\n const left = Math.ceil(coords.left + coords.width + 100)\n tooltip.style.top = `${top}px`\n tooltip.style.left = `${left}px`\n\n tooltip.line = new LeaderLine(tooltip, this.delegate.morphElement, {\n ...this.leaderLineOptions,\n color: 'chocolate'\n })\n\n tooltip.drag = new PlainDraggable(tooltip)\n return tooltip\n }\n\n createTargetTooltip () {\n if (!this.delegate.targetElement)\n return console.debug(\n `Unable to create the target tooltip! No element matches the DOM id: '${this.delegate.triggerElement.controls}'`\n )\n\n const title = `\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><circle cx=\"12\" cy=\"12\" r=\"10\"></circle><circle cx=\"12\" cy=\"12\" r=\"6\"></circle><circle cx=\"12\" cy=\"12\" r=\"2\"></circle></svg>\n TARGET - <${this.delegate.targetElement.tagName.toLowerCase()}>\n `\n\n const tooltip = appendTooltip(\n title,\n this.delegate.targetTooltipData?.subtitle || '',\n this.delegate.targetTooltipData?.content || '',\n {\n id: `${this.delegate.id}-target`,\n backgroundColor: 'lightcyan',\n color: 'darkcyan',\n position: 'bottom'\n }\n )\n\n const coords = coordinates(this.delegate.targetElement)\n const top = Math.ceil(coords.top + tooltip.offsetHeight)\n const left = Math.ceil(coords.left + coords.width + tooltip.offsetWidth / 3)\n tooltip.style.top = `${top}px`\n tooltip.style.left = `${left}px`\n\n tooltip.line = new LeaderLine(tooltip, this.delegate.targetElement, {\n ...this.leaderLineOptions,\n color: 'darkcyan'\n })\n\n tooltip.drag = new PlainDraggable(tooltip)\n return tooltip\n }\n\n createTriggerTooltip (targetTooltip, renderingTooltip) {\n if (!this.delegate.triggerElement) return\n const title = `\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"13 2 3 14 12 14 11 22 21 10 12 10 13 2\"></polygon></svg>\n TRIGGER - <${this.delegate.triggerElement.tagName.toLowerCase()}>\n `\n\n const tooltip = appendTooltip(\n title,\n this.delegate.triggerTooltipData?.subtitle || '',\n this.delegate.triggerTooltipData?.content || '',\n {\n id: `${this.delegate.id}-trigger`,\n backgroundColor: 'lavender',\n color: 'blueviolet'\n }\n )\n\n const coords = coordinates(this.delegate.triggerElement)\n const top = Math.ceil(coords.top - tooltip.offsetHeight * 2)\n const left = Math.ceil(coords.left + coords.width + tooltip.offsetWidth / 3)\n tooltip.style.top = `${top}px`\n tooltip.style.left = `${left}px`\n\n tooltip.line = new LeaderLine(this.delegate.triggerElement, tooltip, {\n ...this.leaderLineOptions,\n color: 'blueviolet'\n })\n\n if (targetTooltip) {\n tooltip.lineToTarget = new LeaderLine(tooltip, targetTooltip, {\n ...this.leaderLineOptions,\n color: 'blueviolet',\n middleLabel: this.delegate.targetLineLabel,\n size: 2.1\n })\n\n targetTooltip.drag.onMove = () => {\n targetTooltip.line.position()\n tooltip.lineToTarget?.position()\n tooltip.lineToRendering?.position()\n }\n }\n\n if (renderingTooltip) {\n tooltip.lineToRendering = new LeaderLine(tooltip, renderingTooltip, {\n ...this.leaderLineOptions,\n color: 'blueviolet',\n middleLabel: this.delegate.renderingLineLabel,\n size: 2.1\n })\n\n renderingTooltip.drag.onMove = () => {\n renderingTooltip.line.position()\n if (tooltip.lineToTarget) tooltip.lineToTarget.position()\n tooltip.lineToRendering?.position()\n }\n }\n\n tooltip.drag = new PlainDraggable(tooltip)\n tooltip.drag.onMove = () => {\n tooltip.line.position()\n if (tooltip.lineToTarget) tooltip.lineToTarget.position()\n if (tooltip.lineToRendering) tooltip.lineToRendering.position()\n }\n\n return tooltip\n }\n\n get leaderLineOptions () {\n return {\n dash: { animation: true },\n dropShadow: { opacity: 0.3 },\n endPlug: 'arrow3',\n endPlugSize: 1.7,\n size: 3,\n startPlug: 'disc',\n startPlugSize: 1\n }\n }\n}\n", "import devtools from '..'\nimport { Devtool, decorateElementWithDevtool } from '..'\n\nfunction defineTooltipData (element) {\n Object.defineProperties(element, {\n targetTooltipData: {\n get () {\n return {\n subtitle: `\n <b>identifier</b>: ${element.identifier}<br>\n <b>query</b>: ${element.query}\n `,\n content: `\n <div slot=\"content-top\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewbox=\"0 0 24 24\" fill=\"none\" stroke=\"currentcolor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"12 2 2 7 12 12 22 7 12 2\"></polygon><polyline points=\"2 17 12 22 22 17\"></polyline><polyline points=\"2 12 12 17 22 12\"></polyline></svg>\n <b>element log</b>\n </div>\n ${element.targetElementLog.queue\n .slice(-10)\n .map(logEntry => `<div slot=\"content\">${logEntry}</div>`)\n .join('')}\n `\n }\n }\n },\n\n triggerTooltipData: {\n get () {\n return {\n subtitle: `\n <b>identifier</b>: ${this.identifier}<br>\n <b>only</b>: ${this.getAttribute('only') || ''}<br>\n <b>url</b>: ${this.getAttribute('url') || location.href}<br>\n <b>debounce (client-side)</b>: ${this.debounce}<br>\n <b>ignore-inner-updates</b>: ${this.hasAttribute(\n 'ignore-inner-updates'\n )}\n `,\n content: `\n <div slot=\"content-top\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewbox=\"0 0 24 24\" fill=\"none\" stroke=\"currentcolor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"12 2 2 7 12 12 22 7 12 2\"></polygon><polyline points=\"2 17 12 22 22 17\"></polyline><polyline points=\"2 12 12 17 22 12\"></polyline></svg>\n <b>element log</b>\n </div>\n ${element.triggerElementLog.queue\n .slice(-10)\n .map(logEntry => `<div slot=\"content\">${logEntry}</div>`)\n .join('')}\n `\n }\n }\n }\n })\n}\n\nfunction initialize () {\n document.addEventListener('turbo-boost:devtools-start', () =>\n Devtool.register('updates-for', 'updates-for')\n )\n\n window.CableReady.devtools = devtools\n\n document.addEventListener('turbo:load', () => {\n document.querySelectorAll('updates-for').forEach(element => {\n decorateElementWithDevtool(element, 'updates-for', 'updates')\n defineTooltipData(element)\n element.initializeDevtool()\n })\n\n document.querySelectorAll('cable-ready-updates-for').forEach(element => {\n decorateElementWithDevtool(element, 'updates-for', 'updates')\n defineTooltipData(element)\n element.initializeDevtool()\n })\n\n CableReady.devtools.start()\n })\n}\n\ninitialize()\n", "import supervisor from './supervisor'\nimport Devtool from './devtool'\n\nconst { restart, start, stop } = supervisor\n\nfunction decorateElementWithDevtool (element, name, label) {\n Object.assign(element, {\n initializeDevtool () {\n const mouseenter = () => this.devtool.show()\n\n addEventListener('turbo-boost:devtools-start', () => {\n this.devtool = new Devtool(this)\n this.addEventListener('mouseenter', mouseenter)\n })\n\n addEventListener('turbo-boost:devtools-stop', () => {\n this.removeEventListener('mouseenter', mouseenter)\n this.removeDevtool()\n })\n\n this.dispatchEvent(\n new CustomEvent('turbo-boost:devtools-connect', { bubbles: true })\n )\n },\n hideDevtool () {\n this.devtool?.hide({ active: false })\n },\n removeDevtool () {\n this.devtool.hide({ active: false })\n this.devtool.unregisterEventListeners()\n delete this.devtool\n },\n name,\n targetLineLabel: label\n })\n\n // the element references below are defaults that are placed on the receiver if not present\n const properties = ['triggerElement', 'morphElement', 'targetElement']\n\n properties\n .filter(property => {\n return element[property] === undefined\n })\n .forEach(property => {\n Object.defineProperty(element, property, {\n get () {\n return element\n }\n })\n })\n}\n\n;(async () => {\n // we cannot detect customElements.get(\"cable-ready-updates-for\") because they are lazily initialized\n if (window.CableReady) await import('./delegates/cable_ready.js')\n})()\n\nexport { Devtool, decorateElementWithDevtool }\n\nexport default { restart, start, stop }\n", "export default class TurboBoostElement extends HTMLElement {\n constructor(html) {\n super()\n this.devtool = 'unknown'\n this.attachShadow({ mode: 'open' })\n this.shadowRoot.innerHTML = html || '<slot></slot>'\n }\n\n connectedCallback() {\n this.ensureId()\n }\n\n ensureId() {\n if (this.id.trim().length) return\n this.id = `${this.tagName}-${this.uuidv4()}`.toLowerCase()\n }\n\n // SEE: https://stackoverflow.com/questions/105034/how-do-i-create-a-guid-uuid\n uuidv4() {\n return ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, c =>\n (c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16)\n )\n }\n\n get viewStack() {\n const value = this.getAttribute('view-stack')\n if (!value) return []\n return JSON.parse(value)\n }\n\n get partial() {\n return this.viewStack[0]\n }\n}\n", "import TurboBoostElement from '../../turbo_boost_element'\n\nconst html = `\n <turbo-boost>\n <slot name=\"busy\" hidden></slot>\n <slot></slot>\n </turbo-boost>\n`\n\nexport const busyDelay = 100 // milliseconds - time to wait before showing busy element\nexport const busyDuration = 400 // milliseconds - minimum time that busy element is shown\n\nexport default class ToggleElement extends TurboBoostElement {\n constructor() {\n super(html)\n }\n\n // TODO: Should we timeout after a theoretical max wait time?\n // The idea being that a server error occurred and the toggle failed.\n showBusyElement() {\n clearTimeout(this.showBusyElementTimeout)\n clearTimeout(this.hideBusyElementTimeout)\n\n if (!this.busyElement) return\n\n this.busyStartedAt = Date.now() + busyDelay\n this.showBusyElementTimeout = setTimeout(() => {\n this.busySlotElement.hidden = false\n this.defaultSlotElement.hidden = true\n }, busyDelay)\n }\n\n hideBusyElement() {\n clearTimeout(this.showBusyElementTimeout)\n clearTimeout(this.hideBusyElementTimeout)\n\n if (!this.busyElement) return\n\n let delay = busyDuration - (Date.now() - this.busyStartedAt)\n if (delay < 0) delay = 0\n\n delete this.busyStartedAt\n this.hideBusyElementTimeout = setTimeout(() => {\n this.busySlotElement.hidden = true\n this.defaultSlotElement.hidden = false\n }, delay)\n }\n\n get busyElement() {\n return this.querySelector(':scope > [slot=\"busy\"]')\n }\n\n get busySlotElement() {\n return this.shadowRoot.querySelector('slot[name=\"busy\"]')\n }\n\n get defaultSlotElement() {\n return this.shadowRoot.querySelector('slot:not([name])')\n }\n\n // indicates if an rpc call is active/busy\n get busy() {\n return this.getAttribute('busy') === 'true'\n }\n\n // indicates if an rpc call is active/busy\n set busy(value) {\n value = !!value\n if (this.busy === value) return\n this.setAttribute('busy', value)\n if (value) this.showBusyElement()\n else this.hideBusyElement()\n }\n\n get busyStartedAt() {\n if (!this.dataset.busyStartedAt) return 0\n return Number(this.dataset.busyStartedAt)\n }\n\n set busyStartedAt(value) {\n this.dataset.busyStartedAt = value\n }\n}\n", "import ToggleElement from '../toggle_element'\n\nexport default class ToggleTargetElement extends ToggleElement {\n connectedCallback() {\n super.connectedCallback()\n\n this.mouseenterHandler = this.onMouseenter.bind(this)\n this.addEventListener('mouseenter', this.mouseenterHandler)\n\n this.collapseHandler = this.collapse.bind(this)\n this.collapseNowHandler = this.collapseNow.bind(this)\n\n this.collapseOn.forEach(entry => {\n const parts = entry.split('@')\n const name = parts[0]\n\n if (parts.length > 1) {\n const target = parts[1].match(/^self|window$/) ? self : self[parts[1]]\n target.addEventListener(name, this.collapseNowHandler)\n } else {\n this.addEventListener(name, this.collapseHandler)\n }\n })\n }\n\n disconnectedCallback() {\n this.removeEventListener('mouseenter', this.mouseenterHandler)\n\n this.collapseOn.forEach(entry => {\n const parts = entry.split('@')\n const name = parts[0]\n\n if (parts.length > 1) {\n const target = parts[1].match(/^self|window$/) ? self : self[parts[1]]\n target.removeEventListener(name, this.collapseNowHandler)\n } else {\n this.removeEventListener(name, this.collapseHandler)\n }\n })\n }\n\n // TODO: get cached content working properly\n // perhaps use a mechanic other than morph\n\n // TODO: implement cache (similar to Turbo Drive restoration visit)\n cacheHTML() {\n // this.cachedHTML = this.innerHTML\n }\n\n // TODO: implement cache (similar to Turbo Drive restoration visit)\n renderCachedHTML() {\n // if (!this.cachedHTML) return\n // this.innerHTML = this.cachedHTML\n }\n\n onMouseenter() {\n clearTimeout(this.collapseTimeout)\n }\n\n collapse(delay = 250) {\n clearTimeout(this.collapseTimeout)\n if (this.busy) return\n if (typeof delay !== 'number') delay = 250\n\n if (delay > 0) return (this.collapseTimeout = setTimeout(() => this.collapse(0), delay))\n\n this.innerHTML = ''\n try {\n this.expanded = false\n this.triggerElement.hideDevtool()\n } catch {}\n }\n\n collapseNow(event) {\n if (event.target.closest('turbo-boost-devtool-tooltip')) return\n this.collapse(0)\n }\n\n collapseMatches() {\n document.querySelectorAll(this.collapseSelector).forEach(el => {\n if (el.id === this.id) return\n if (el.collapse) el.collapse(0)\n })\n }\n\n get collapseSelector() {\n return this.triggerElement.collapseSelector || this.getAttribute('collapse-selector')\n }\n\n get focusSelector() {\n return this.getAttribute('focus-selector')\n }\n\n // the active trigger\n get triggerElement() {\n return document.getElementById(this.labeledBy)\n }\n\n // all triggers\n get triggerElements() {\n return document.querySelectorAll(`[aria-controls=\"${this.id}\"]`)\n }\n\n // the dom id of the active trigger\n get labeledBy() {\n return this.getAttribute('aria-labeledby')\n }\n\n set labeledBy(value) {\n return this.setAttribute('aria-labeledby', value)\n }\n\n get collapseOn() {\n const value = this.getAttribute('collapse-on')\n if (!value) return []\n return JSON.parse(value)\n }\n\n get expanded() {\n return this.triggerElement ? this.triggerElement.expanded : false\n }\n\n set expanded(value) {\n this.triggerElements.forEach(el => (el.expanded = value))\n }\n\n get busy() {\n return this.triggerElement && this.triggerElement.busy\n }\n}\n", "let focusTimeout\n\nfunction deactivateTrixAttributes(editor) {\n const attributes = ['bold', 'bullet', 'code', 'heading1', 'href', 'italic', 'number', 'quote', 'strike']\n attributes.forEach(name => editor.deactivateAttribute(name))\n}\n\nfunction focusTrixEditorElement(element) {\n if (element.value.length === 0) return\n\n const editor = element.editor\n\n // move cursor to the end\n let lastRange = []\n while (lastRange[0] !== editor.getSelectedRange()[0] && lastRange[1] !== editor.getSelectedRange()[1]) {\n lastRange = editor.getSelectedRange()\n editor.moveCursorInDirection('forward')\n }\n\n // insert an empty char and select it\n editor.insertString(' ')\n editor.moveCursorInDirection('forward')\n editor.setSelectedRange([lastRange[1], editor.getSelectedRange()[1]])\n\n // deactivate all trix features for the selection\n deactivateTrixAttributes(editor)\n\n // move cursor to end and collapse the selection\n editor.setSelectedRange([editor.getSelectedRange()[1], editor.getSelectedRange()[1]])\n}\n\nfunction debouncedFocus(element) {\n clearTimeout(focusTimeout)\n\n focusTimeout = setTimeout(() => {\n if (!element) return\n\n element.focus()\n const trixEditorElement = element.closest('trix-editor')\n\n try {\n if (trixEditorElement) {\n focusTrixEditorElement(trixEditorElement)\n } else {\n element.selectionStart = element.selectionEnd = element.value.length\n }\n } catch (_) {\n } finally {\n element.scrollIntoView({ block: 'center', behavior: 'smooth' })\n }\n }, 100)\n}\n\nexport default element => debouncedFocus(element)\n", "import { Devtool, decorateElementWithDevtool } from '@turbo-boost/devtools'\n\nimport ToggleElement, { busyDuration } from '../toggle_element'\nimport focus from './focus'\n\ndocument.addEventListener('turbo-boost:devtools-start', () => Devtool.register('toggle', 'toggles'))\n\nlet currentFocusSelector\n\nexport default class ToggleTriggerElement extends ToggleElement {\n constructor() {\n super()\n\n decorateElementWithDevtool(this, 'toggle', 'toggles')\n }\n\n connectedCallback() {\n super.connectedCallback()\n\n const { start: commandStartEvent } = TurboBoost.Commands.events\n this.commandStartHandler = this.onCommandStart.bind(this)\n this.addEventListener(commandStartEvent, this.commandStartHandler)\n\n const { before: beforeInvokeEvent } = TurboBoost.Streams.invokeEvents\n this.beforeInvokeHandler = this.onBeforeInvoke.bind(this)\n addEventListener(beforeInvokeEvent, this.beforeInvokeHandler)\n\n // fires after receiving the toggle morph Turbo Stream but before it is executed\n // this.addEventListener(TurboBoost.Commands.events.success, event => {\n // // TODO: imlement cache, this.targetElement.cacheHTML()\n // })\n\n this.initializeDevtool()\n }\n\n disconnectedCallback() {\n // delay cleanup because the trigger may have been morphed out of the DOM,\n // but it's needed to apply behavior like focus etc...\n setTimeout(() => {\n const { start: commandStartEvent } = TurboBoost.Commands.events\n this.removeEventListener(commandStartEvent, this.commandStartHandler)\n\n const { before: beforeInvokeEvent } = TurboBoost.Streams.invokeEvents\n removeEventListener(beforeInvokeEvent, this.beforeInvokeHandler)\n\n this.removeDevtool()\n }, 1000)\n }\n\n onCommandStart(event) {\n currentFocusSelector = this.focusSelector\n this.targetElement.labeledBy = this.id\n this.targetElement.collapseMatches()\n this.busy = true\n // TODO: implement cache - this.targetElement.renderCachedHTML()\n }\n\n // runs before an invoke turbo stream is executed\n onBeforeInvoke(event) {\n // return early if we're not the element responsible for this invoke\n if (event.detail.method !== 'morph') return\n if (event.target.id !== this.morphs) return\n const selector = `turbo-boost-toggle-target[aria-labeledby=\"${this.id}\"]`\n if (!event.target.querySelector(selector)) return\n\n // ensure the busy element is shown long enough for a good user experience\n // we accomplish this by modifying the event.detail with invoke instructions i.e. { delay }\n // SEE: the TurboBoost Streams library for details on how this works\n const duration = Date.now() - this.busyStartedAt\n let delay = busyDuration - duration\n if (delay < 10) delay = 10\n event.detail.invoke = { delay }\n\n // runs before the morph is executed\n setTimeout(() => {\n this.busy = false\n this.morphToggleTriggerElements.forEach(el => (el.busy = false))\n }, delay - 10)\n\n // runs after the morph is executed\n setTimeout(() => focus(this.targetElement.querySelector(currentFocusSelector)), delay + 100)\n }\n\n // a list of views shared between the trigger and target\n get sharedViews() {\n if (!this.targetElement) return []\n if (!this.targetElement.viewStack) return []\n const reducer = (memo, view) => {\n if (this.targetElement.viewStack.includes(view)) memo.push(view)\n return memo\n }\n return this.viewStack.reduce(reducer.bind(this), [])\n }\n\n // the partial to render\n get renders() {\n return this.getAttribute('renders')\n }\n\n // the renderered partial's top wrapping dom_id\n get morphs() {\n return this.getAttribute('morphs')\n }\n\n // all toggle elements contained by the `morphElement`\n get morphToggleTriggerElements() {\n return Array.from(this.morphElement.querySelectorAll('turbo-boost-toggle-trigger'))\n }\n\n // the target's dom_id\n get controls() {\n return this.getAttribute('aria-controls')\n }\n\n get collapseSelector() {\n return this.getAttribute('collapse-selector')\n }\n\n get focusSelector() {\n return this.getAttribute('focus-selector') || this.targetElement.focusSelector\n }\n\n // indicates if the toggle state should be remembered across requests\n get remember() {\n return this.getAttribute('remember') === 'true'\n }\n\n set remember(value) {\n return this.setAttribute('remember', !!value)\n }\n\n // indicates if the target is expanded\n get expanded() {\n return this.getAttribute('aria-expanded') === 'true'\n }\n\n set expanded(value) {\n this.setAttribute('aria-expanded', !!value)\n }\n\n // indicates if the target is expanded\n get collapsed() {\n return !this.expanded\n }\n\n // ------ DevToolDelegate ------\n get command() {\n return this.dataset.turboCommand\n }\n\n get renderingLineLabel() {\n return 'renders & morphs'\n }\n\n // the morph element\n get morphElement() {\n if (!this.morphs) return null\n return document.getElementById(this.morphs)\n }\n\n // the target element\n get targetElement() {\n if (!this.controls) return null\n return document.getElementById(this.controls)\n }\n\n get triggerTooltipData() {\n let content = this.triggerElement.viewStack\n .reverse()\n .map((view, index) => {\n return this.triggerElement.sharedViews.includes(view)\n ? `<div slot=\"content\">${index + 1}. ${view}</div>`\n : `<div slot=\"content-bottom\">${index + 1}. ${view}</div>`\n }, this)\n .join('')\n\n return {\n subtitle: `\n <b>id</b>: ${this.triggerElement.id}<br>\n <b>aria-controls</b>: ${this.triggerElement.controls}<br>\n <b>aria-expanded</b>: ${this.triggerElement.expanded}<br>\n <b>remember</b>: ${this.triggerElement.remember}<br>\n `,\n content: `\n <div slot=\"content-top\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"12 2 2 7 12 12 22 7 12 2\"></polygon><polyline points=\"2 17 12 22 22 17\"></polyline><polyline points=\"2 12 12 17 22 12\"></polyline></svg>\n <b>View Stack</b>\n </div>\n ${content}\n `\n }\n }\n\n get targetTooltipData() {\n let content = this.targetElement.viewStack\n .reverse()\n .map((view, index) => {\n return this.triggerElement.sharedViews.includes(view)\n ? `<div slot=\"content\">${index + 1}. ${view}</div>`\n : `<div slot=\"content-bottom\">${index + 1}. ${view}</div>`\n }, this)\n .join('')\n\n return {\n subtitle: `<b>id</b>: ${this.targetElement.id}<br>\n <b>aria-labeled-by</b>: ${this.targetElement.labeledBy}<br>\n`,\n content: `\n <div slot=\"content-top\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" style=\"display:inline-block;\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><polygon points=\"12 2 2 7 12 12 22 7 12 2\"></polygon><polyline points=\"2 17 12 22 22 17\"></polyline><polyline points=\"2 12 12 17 22 12\"></polyline></svg>\n <b>View Stack</b>\n </div>\n ${content}\n `\n }\n }\n}\n", "import TurboBoostElement from './turbo_boost_element'\nimport ToggleTargetElement from './toggle_elements/target_element'\nimport ToggleTriggerElement from './toggle_elements/trigger_element'\n\n// Valid custom element names: https://html.spec.whatwg.org/#valid-custom-element-name\n\ncustomElements.define('turbo-boost', TurboBoostElement)\ncustomElements.define('turbo-boost-toggle-target', ToggleTargetElement)\ncustomElements.define('turbo-boost-toggle-trigger', ToggleTriggerElement)\n", "import '@turbo-boost/commands'\nimport devtools from '@turbo-boost/devtools'\nimport './elements'\n\nself.TurboBoost = self.TurboBoost || {}\nself.TurboBoost.devtools = devtools\nself.TurboBoost.Elements = {}\n\nexport default self.TurboBoost.Elements\n"],
|
5
|
+
"mappings": "AAAA,IAAIA,GAAE,OAAO,eAAeC,GAAG,OAAO,iBAAqBC,GAAG,OAAO,0BAA8BC,GAAE,OAAO,sBAA0BC,GAAG,OAAO,UAAU,eAAeC,GAAG,OAAO,UAAU,qBAAyBC,GAAE,CAAC,EAAE,EAAEC,IAAI,KAAK,EAAEP,GAAE,EAAE,EAAE,CAAC,WAAW,GAAG,aAAa,GAAG,SAAS,GAAG,MAAMO,CAAC,CAAC,EAAE,EAAE,CAAC,EAAEA,EAAEC,EAAE,CAAC,EAAE,IAAI,CAAC,QAAQD,KAAK,IAAI,EAAE,CAAC,GAAGH,GAAG,K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AO;AAAA,KAEX,CACF,CAEA,IAAI,mBAAoB,CACtB,IAAIA,EAAU,KAAK,cAAc,UAC9B,QAAQ,EACR,IAAI,CAACF,EAAMG,IACH,KAAK,eAAe,YAAY,SAASH,CAAI,EAChD,uBAAuBG,EAAQ,CAAC,KAAKH,CAAI,SACzC,8BAA8BG,EAAQ,CAAC,KAAKH,CAAI,SACnD,IAAI,EACN,KAAK,EAAE,EAEV,MAAO,CACL,SAAU,cAAc,KAAK,cAAc,EAAE;AAAA,gCACnB,KAAK,cAAc,SAAS;AAAA,EAEtD,QAAS;AAAA;AAAA;AAAA;AAAA;AAAA,QAKPE,CAAO;AAAA,KAEX,CACF,CACF,EClNA,eAAe,OAAO,cAAeE,CAAiB,EACtD,eAAe,OAAO,4BAA6BC,CAAmB,EACtE,eAAe,OAAO,6BAA8BC,CAAoB,ECJxE,KAAK,WAAa,KAAK,YAAc,CAAC,EACtC,KAAK,WAAW,SAAWC,EAC3B,KAAK,WAAW,SAAW,CAAC,EAE5B,IAAOC,GAAQ,KAAK,WAAW",
|
6
|
+
"names": ["Z", "ee", "te", "X", "re", "oe", "_", "r", "s", "u", "O", "t", "a", "i", "l", "f", "d", "o", "B", "k", "c", "A", "F", "D", "g", "C", "N", "J", "E", "h", "ne", "se", "v", "L", "ae", "ie", "S", "M", "T", "R", "de", "m", "j", "me", "ue", "ce", "W", "$", "le", "fe", "be", "p", "pe", "he", "ve", "ge", "y", "Ee", "U", "xe", "x", "Ce", "H", "Te", "V", "ye", "P", "Ae", "ke", "G", "q", "Le", "I", "w", "z", "K", "Se", "Q", "Y", "we", "template", "html", "appendHTML", "parent", "child", "addHighlight", "element", "options", "removeHighlight", "outline", "outlineOffset", "key", "value", "coordinates", "rect", "width", "height", "top", "left", "right", "bottom", "attempt", "callback", "e", "init_dom", "__esmMin", "DevtoolElement", "init_devtool_element", "event", "SupervisorElement", "init_supervisor_element", "devtoolElement", "checked", "name", "el", "TooltipElement", "init_tooltip_element", "savedTransform", "exists", "dependency", "added", "add", "src", "integrity", "script", "remove", "removeAll", "dependencies", "dependencies_default", "init_dependencies", "__spreadProps", "__spreadValues", "makeDraggable", "supervisorElement", "stop", "stopped", "start", "started", "restart", "enabledList", "debouncedRestart", "restartTimeout", "autoRestart", "register", "label", "enabled", "supervisor_default", "init_supervisor", "appendTooltip", "title", "subtitle", "content", "backgroundColor", "color", "position", "id", "activeTarget", "Devtool", "init_devtool", "delegate", "hideTimeout", "debouncedHide", "type", "listener", "data", "active", "tooltip", "coords", "_a", "_b", "targetTooltip", "renderingTooltip", "cable_ready_exports", "defineTooltipData", "logEntry", "initialize", "src_default", "decorateElementWithDevtool", "init_cable_ready", "init_src", "mouseenter", "property", "Q", "ut", "O", "TurboBoostElement", "html", "c", "value", "html", "busyDelay", "busyDuration", "ToggleElement", "TurboBoostElement", "delay", "value", "ToggleTargetElement", "ToggleElement", "entry", "parts", "name", "delay", "e", "event", "el", "value", "focusTimeout", "deactivateTrixAttributes", "editor", "name", "focusTrixEditorElement", "element", "lastRange", "debouncedFocus", "trixEditorElement", "_", "focus_default", "g", "currentFocusSelector", "ToggleTriggerElement", "ToggleElement", "M", "commandStartEvent", "beforeInvokeEvent", "event", "selector", "duration", "delay", "busyDuration", "el", "focus_default", "reducer", "memo", "view", "value", "content", "index", "TurboBoostElement", "ToggleTargetElement", "ToggleTriggerElement", "V", "javascript_default"]
|
7
7
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"inputs":{"node_modules/@turbo-boost/commands/app/assets/builds/@turbo-boost/commands.js":{"bytes":11151,"imports":[],"format":"esm"},"node_modules/@turbo-boost/devtools/dist/@turbo-boost/devtools.js":{"bytes":
|
1
|
+
{"inputs":{"node_modules/@turbo-boost/commands/app/assets/builds/@turbo-boost/commands.js":{"bytes":11151,"imports":[],"format":"esm"},"node_modules/@turbo-boost/devtools/dist/@turbo-boost/devtools.js":{"bytes":21880,"imports":[],"format":"esm"},"app/javascript/elements/turbo_boost_element/index.js":{"bytes":844,"imports":[],"format":"esm"},"app/javascript/elements/toggle_elements/toggle_element/index.js":{"bytes":2193,"imports":[{"path":"app/javascript/elements/turbo_boost_element/index.js","kind":"import-statement","original":"../../turbo_boost_element"}],"format":"esm"},"app/javascript/elements/toggle_elements/target_element/index.js":{"bytes":3370,"imports":[{"path":"app/javascript/elements/toggle_elements/toggle_element/index.js","kind":"import-statement","original":"../toggle_element"}],"format":"esm"},"app/javascript/elements/toggle_elements/trigger_element/focus.js":{"bytes":1585,"imports":[],"format":"esm"},"app/javascript/elements/toggle_elements/trigger_element/index.js":{"bytes":7168,"imports":[{"path":"node_modules/@turbo-boost/devtools/dist/@turbo-boost/devtools.js","kind":"import-statement","original":"@turbo-boost/devtools"},{"path":"app/javascript/elements/toggle_elements/toggle_element/index.js","kind":"import-statement","original":"../toggle_element"},{"path":"app/javascript/elements/toggle_elements/trigger_element/focus.js","kind":"import-statement","original":"./focus"}],"format":"esm"},"app/javascript/elements/index.js":{"bytes":481,"imports":[{"path":"app/javascript/elements/turbo_boost_element/index.js","kind":"import-statement","original":"./turbo_boost_element"},{"path":"app/javascript/elements/toggle_elements/target_element/index.js","kind":"import-statement","original":"./toggle_elements/target_element"},{"path":"app/javascript/elements/toggle_elements/trigger_element/index.js","kind":"import-statement","original":"./toggle_elements/trigger_element"}],"format":"esm"},"app/javascript/index.js":{"bytes":244,"imports":[{"path":"node_modules/@turbo-boost/commands/app/assets/builds/@turbo-boost/commands.js","kind":"import-statement","original":"@turbo-boost/commands"},{"path":"node_modules/@turbo-boost/devtools/dist/@turbo-boost/devtools.js","kind":"import-statement","original":"@turbo-boost/devtools"},{"path":"app/javascript/elements/index.js","kind":"import-statement","original":"./elements"}],"format":"esm"}},"outputs":{"app/assets/builds/@turbo-boost/elements.js.map":{"imports":[],"exports":[],"inputs":{},"bytes":97900},"app/assets/builds/@turbo-boost/elements.js":{"imports":[],"exports":["default"],"entryPoint":"app/javascript/index.js","inputs":{"node_modules/@turbo-boost/commands/app/assets/builds/@turbo-boost/commands.js":{"bytesInOutput":11085},"node_modules/@turbo-boost/devtools/dist/@turbo-boost/devtools.js":{"bytesInOutput":21828},"app/javascript/elements/turbo_boost_element/index.js":{"bytesInOutput":541},"app/javascript/elements/toggle_elements/toggle_element/index.js":{"bytesInOutput":1284},"app/javascript/elements/toggle_elements/target_element/index.js":{"bytesInOutput":2040},"app/javascript/elements/toggle_elements/trigger_element/focus.js":{"bytesInOutput":768},"app/javascript/elements/toggle_elements/trigger_element/index.js":{"bytesInOutput":4297},"app/javascript/elements/index.js":{"bytesInOutput":146},"app/javascript/index.js":{"bytesInOutput":123}},"bytes":42172}}}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: turbo_boost-elements
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.16
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nate Hopkins (hopsoft)
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-08-
|
11
|
+
date: 2023-08-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|