@bedrock-layout/solid 1.1.4 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.cjs.js +1 -1
- package/lib/index.m.js +273 -205
- package/lib/index.umd.js +1 -1
- package/package.json +4 -3
package/lib/index.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Y=require("open-props"),l=require("solid-js"),P=require("@bedrock-layout/register-resize-callback"),Z=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected"],K=new Set(["className","value","readOnly","formNoValidate","isMap","noModule","playsInline",...Z]),p=new Set(["innerHTML","textContent","innerText","children"]),ee=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),te=Object.assign(Object.create(null),{class:"className",formnovalidate:{$:"formNoValidate",BUTTON:1,INPUT:1},ismap:{$:"isMap",IMG:1},nomodule:{$:"noModule",SCRIPT:1},playsinline:{$:"playsInline",VIDEO:1},readonly:{$:"readOnly",INPUT:1,TEXTAREA:1}});function ne(e,t){const n=te[e];return typeof n=="object"?n[t]?n.$:void 0:n}const ie=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),se=new Set(["altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","set","stop","svg","switch","symbol","text","textPath","tref","tspan","use","view","vkern"]),re={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"};function oe(e,t,n){let i=n.length,s=t.length,o=i,c=0,r=0,f=t[s-1].nextSibling,a=null;for(;c<s||r<o;){if(t[c]===n[r]){c++,r++;continue}for(;t[s-1]===n[o-1];)s--,o--;if(s===c){const d=o<i?r?n[r-1].nextSibling:n[o-r]:f;for(;r<o;)e.insertBefore(n[r++],d)}else if(o===r)for(;c<s;)(!a||!a.has(t[c]))&&t[c].remove(),c++;else if(t[c]===n[o-1]&&n[r]===t[s-1]){const d=t[--s].nextSibling;e.insertBefore(n[r++],t[c++].nextSibling),e.insertBefore(n[--o],d),t[s]=n[o]}else{if(!a){a=new Map;let u=r;for(;u<o;)a.set(n[u],u++)}const d=a.get(t[c]);if(d!=null)if(r<d&&d<o){let u=c,h=1,C;for(;++u<s&&u<o&&!((C=a.get(t[u]))==null||C!==d+h);)h++;if(h>d-r){const M=t[c];for(;r<d;)e.insertBefore(n[r++],M)}else e.replaceChild(n[r++],t[c++])}else c++;else t[c++].remove()}}}const L="_$DX_DELEGATE";function v(e,t,n){let i;const s=()=>{const c=document.createElement("template");return c.innerHTML=e,n?c.content.firstChild.firstChild:c.content.firstChild},o=t?()=>l.untrack(()=>document.importNode(i||(i=s()),!0)):()=>(i||(i=s())).cloneNode(!0);return o.cloneNode=o,o}function ce(e,t=window.document){const n=t[L]||(t[L]=new Set);for(let i=0,s=e.length;i<s;i++){const o=e[i];n.has(o)||(n.add(o),t.addEventListener(o,be))}}function T(e,t,n){n==null?e.removeAttribute(t):e.setAttribute(t,n)}function le(e,t,n,i){i==null?e.removeAttributeNS(t,n):e.setAttributeNS(t,n,i)}function fe(e,t){t==null?e.removeAttribute("class"):e.className=t}function ae(e,t,n,i){if(i)Array.isArray(n)?(e[`$$${t}`]=n[0],e[`$$${t}Data`]=n[1]):e[`$$${t}`]=n;else if(Array.isArray(n)){const s=n[0];e.addEventListener(t,n[0]=o=>s.call(e,n[1],o))}else e.addEventListener(t,n)}function de(e,t,n={}){const i=Object.keys(t||{}),s=Object.keys(n);let o,c;for(o=0,c=s.length;o<c;o++){const r=s[o];!r||r==="undefined"||t[r]||(R(e,r,!1),delete n[r])}for(o=0,c=i.length;o<c;o++){const r=i[o],f=!!t[r];!r||r==="undefined"||n[r]===f||!f||(R(e,r,!0),n[r]=f)}return n}function G(e,t,n){if(!t)return n?T(e,"style"):t;const i=e.style;if(typeof t=="string")return i.cssText=t;typeof n=="string"&&(i.cssText=n=void 0),n||(n={}),t||(t={});let s,o;for(o in n)t[o]==null&&i.removeProperty(o),delete n[o];for(o in t)s=t[o],s!==n[o]&&(i.setProperty(o,s),n[o]=s);return n}function ue(e,t={},n,i){const s={};return i||l.createRenderEffect(()=>s.children=x(e,t.children,s.children)),l.createRenderEffect(()=>t.ref&&t.ref(e)),l.createRenderEffect(()=>ye(e,t,n,!0,s,!0)),s}function me(e,t,n){return l.untrack(()=>e(t,n))}function H(e,t,n,i){if(n!==void 0&&!i&&(i=[]),typeof t!="function")return x(e,t,i,n);l.createRenderEffect(s=>x(e,t(),s,n),i)}function ye(e,t,n,i,s={},o=!1){t||(t={});for(const c in s)if(!(c in t)){if(c==="children")continue;s[c]=W(e,c,null,s[c],n,o)}for(const c in t){if(c==="children"){i||x(e,t.children);continue}const r=t[c];s[c]=W(e,c,r,s[c],n,o)}}function ge(e){let t,n;if(!l.sharedConfig.context||!(t=l.sharedConfig.registry.get(n=$e()))){if(l.sharedConfig.context&&console.warn("Unable to find DOM nodes for hydration key:",n),!e)throw new Error("Unrecoverable Hydration Mismatch. No template for key: "+n);return e()}return l.sharedConfig.completed&&l.sharedConfig.completed.add(t),l.sharedConfig.registry.delete(n),t}function he(e){return e.toLowerCase().replace(/-([a-z])/g,(t,n)=>n.toUpperCase())}function R(e,t,n){const i=t.trim().split(/\s+/);for(let s=0,o=i.length;s<o;s++)e.classList.toggle(i[s],n)}function W(e,t,n,i,s,o){let c,r,f,a,d;if(t==="style")return G(e,n,i);if(t==="classList")return de(e,n,i);if(n===i)return i;if(t==="ref")o||n(e);else if(t.slice(0,3)==="on:"){const u=t.slice(3);i&&e.removeEventListener(u,i),n&&e.addEventListener(u,n)}else if(t.slice(0,10)==="oncapture:"){const u=t.slice(10);i&&e.removeEventListener(u,i,!0),n&&e.addEventListener(u,n,!0)}else if(t.slice(0,2)==="on"){const u=t.slice(2).toLowerCase(),h=ie.has(u);if(!h&&i){const C=Array.isArray(i)?i[0]:i;e.removeEventListener(u,C)}(h||n)&&(ae(e,u,n,h),h&&ce([u]))}else if(t.slice(0,5)==="attr:")T(e,t.slice(5),n);else if((d=t.slice(0,5)==="prop:")||(f=p.has(t))||!s&&((a=ne(t,e.tagName))||(r=K.has(t)))||(c=e.nodeName.includes("-")))d&&(t=t.slice(5),r=!0),t==="class"||t==="className"?fe(e,n):c&&!r&&!f?e[he(t)]=n:e[a||t]=n;else{const u=s&&t.indexOf(":")>-1&&re[t.split(":")[0]];u?le(e,u,t,n):T(e,ee[t]||t,n)}return n}function be(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),l.sharedConfig.registry&&!l.sharedConfig.done&&(l.sharedConfig.done=_$HY.done=!0);n;){const i=n[t];if(i&&!n.disabled){const s=n[`${t}Data`];if(s!==void 0?i.call(n,s,e):i.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function x(e,t,n,i,s){if(l.sharedConfig.context){!n&&(n=[...e.childNodes]);let r=[];for(let f=0;f<n.length;f++){const a=n[f];a.nodeType===8&&a.data.slice(0,2)==="!$"?a.remove():r.push(a)}n=r}for(;typeof n=="function";)n=n();if(t===n)return n;const o=typeof t,c=i!==void 0;if(e=c&&n[0]&&n[0].parentNode||e,o==="string"||o==="number"){if(l.sharedConfig.context)return n;if(o==="number"&&(t=t.toString()),c){let r=n[0];r&&r.nodeType===3?r.data=t:r=document.createTextNode(t),n=S(e,n,i,r)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||o==="boolean"){if(l.sharedConfig.context)return n;n=S(e,n,i)}else{if(o==="function")return l.createRenderEffect(()=>{let r=t();for(;typeof r=="function";)r=r();n=x(e,r,n,i)}),()=>n;if(Array.isArray(t)){const r=[],f=n&&Array.isArray(n);if(O(r,t,n,s))return l.createRenderEffect(()=>n=x(e,r,n,i,!0)),()=>n;if(l.sharedConfig.context){if(!r.length)return n;for(let a=0;a<r.length;a++)if(r[a].parentNode)return n=r}if(r.length===0){if(n=S(e,n,i),c)return n}else f?n.length===0?B(e,r,i):oe(e,n,r):(n&&S(e),B(e,r));n=r}else if(t.nodeType){if(l.sharedConfig.context&&t.parentNode)return n=c?[t]:t;if(Array.isArray(n)){if(c)return n=S(e,n,i,t);S(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}else console.warn("Unrecognized value. Skipped inserting",t)}return n}function O(e,t,n,i){let s=!1;for(let o=0,c=t.length;o<c;o++){let r=t[o],f=n&&n[o],a;if(!(r==null||r===!0||r===!1))if((a=typeof r)=="object"&&r.nodeType)e.push(r);else if(Array.isArray(r))s=O(e,r,f)||s;else if(a==="function")if(i){for(;typeof r=="function";)r=r();s=O(e,Array.isArray(r)?r:[r],Array.isArray(f)?f:[f])||s}else e.push(r),s=!0;else{const d=String(r);f&&f.nodeType===3&&f.data===d?e.push(f):e.push(document.createTextNode(d))}}return s}function B(e,t,n=null){for(let i=0,s=t.length;i<s;i++)e.insertBefore(t[i],n)}function S(e,t,n,i){if(n===void 0)return e.textContent="";const s=i||document.createTextNode("");if(t.length){let o=!1;for(let c=t.length-1;c>=0;c--){const r=t[c];if(s!==r){const f=r.parentNode===e;!o&&!c?f?e.replaceChild(s,r):e.insertBefore(s,n):f&&r.remove()}else o=!0}}else e.insertBefore(s,n);return[s]}function $e(){const e=l.sharedConfig.context;return`${e.id}${e.count++}`}const Ce="http://www.w3.org/2000/svg";function Se(e,t=!1){return t?document.createElementNS(Ce,e):document.createElement(e)}function xe(e){const[t,n]=l.splitProps(e,["component"]),i=l.createMemo(()=>t.component);return l.createMemo(()=>{const s=i();switch(typeof s){case"function":return Object.assign(s,{[l.$DEVCOMP]:!0}),l.untrack(()=>s(n));case"string":const o=se.has(s),c=l.sharedConfig.context?ge():Se(s,o);return ue(c,n,o),c}})}function j(e){return e??void 0}function m(e,t){return Object.keys(e).filter(n=>!t.includes(n)).reduce((n,i)=>Object.defineProperty({...n},i,{get(){return e[i]},configurable:!0,enumerable:!0}),{})}function y(e,t){return l.createComponent(xe,l.mergeProps({get component(){return e()}},t))}function g(e){return Object.values(e).every(t=>typeof t=="function")?Object.keys(e).reduce((t,n)=>{const i=e[n];return Object.defineProperty({...t},n,{get(){return i()},configurable:!0,enumerable:!0})},{}):new Error("Please provide an object with accessor values only.")}const V=/^--\D{1}.{0,100}$/;function _(e){return V.test(e)}function E(e){return typeof e!="string"?!1:[/^[0-9]{0,10000}\.?[0-9]{1,10000}(vmin|vmax|vh|vw|%|ch|ex|em|rem|in|cm|mm|pt|pc|px)$/,/^var\(--\D{1}.{0,100}\)$/,V].some(t=>t.test(e))}const{sizeXxs:we,sizeXs:je,sizeSm:Ae,sizeMd:Pe,sizeLg:Ee,sizeXl:Me,sizeXxl:Ie,sizeContent1:Te,sizeContent2:Oe,sizeContent3:ze,sizeHeader1:ke,sizeHeader2:Ne,sizeHeader3:Le,size000:Re,size00:We,size1:Be,size2:De,size3:ve,size4:Ge,size5:He,size6:Ve,size7:_e,size8:Fe,size9:Xe,size10:Ue,size11:qe,size12:Qe,size13:Je,size14:Ye,size15:Ze}=Y,Ke={size000:Re,size00:We,size1:Be,size2:De,size3:ve,size4:Ge,size5:He,size6:Ve,size7:_e,size8:Fe,size9:Xe,size10:Ue,size11:qe,size12:Qe,size13:Je,size14:Ye,size15:Ze},pe={sizeXxs:we,sizeXs:je,sizeSm:Ae,sizeMd:Pe,sizeLg:Ee,sizeXl:Me,sizeXxl:Ie,sizeContent1:Te,sizeContent2:Oe,sizeContent3:ze,sizeHeader1:ke,sizeHeader2:Ne,sizeHeader3:Le},F=Ke,X=pe;function U(e){return e.reduce((t,[n,i])=>({...t,[n]:i}),{})}function z(e,t){if(t!==void 0)return typeof t=="number"&&t>=0?`${t}px`:typeof t=="string"&&E(t)?_(t)?`var(${t})`:t:j(b(e,t))}function b(e,t){const n=e.space??F,i=U(Object.entries(n).map(([s,o])=>[s,typeof o=="number"?`${o}px`:o]));return j(i[t])}function A(e,t){if(t===void 0)return;if(typeof t=="number"&&t>=0)return`${t}px`;if(typeof t=="string"&&E(t))return _(t)?`var(${t})`:t;const n=e.sizes??X,i=U(Object.entries(n).map(([s,o])=>[s,typeof o=="number"?`${o}px`:o]));return j(i[t])}function et(e){return e===void 0?"100%":typeof e=="number"?`${e}px`:e}function tt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),n=()=>`--maxWidth: ${et(e.maxWidth)};`,i=()=>e.centerText?"center-text":"",s=()=>e.centerChildren?"center-children":"",o=()=>[i(),s()].filter(Boolean).join(" "),c=()=>[t(),n()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","maxWidth","centerText","centerChildren"]),g({style:c,"data-bedrock-center":o})))}const q=l.createContext({});function nt(e){return l.createComponent(q.Provider,{get value(){return e.theme},get children(){return e.children}})}function $(){try{return l.useContext(q)}catch{return{}}}function it(e,t){return A(e,t)}function st(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"}`,s=()=>`--minItemWidth: ${it(t,e.minItemWidth)}`,o=()=>e.noStretchedColumns===!0?"no-stretched-columns":"",c=()=>[n(),i(),s()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","minItemWidth","noStretchedColumns"]),g({style:c,"data-bedrock-column-drop":o})))}function rt(e,t){const[n,i]=l.createSignal(!1),[s,o]=l.createSignal();return l.onMount(()=>(P.init(),0)),l.createEffect(()=>{if(j(s())===void 0)return 0;t&&t(s());const c=P.registerCallback(s(),r=>{var a;const f=((a=r.borderBoxSize)==null?void 0:a.inlineSize)??r.contentRect.width;if(f>0){const d=f<=e;i(d)}return 0});return l.onCleanup(c),0}),[n,o]}function ot(e){return Array.isArray(e)&&e.length===2&&e.every(Number.isFinite)||typeof e=="string"&&/^\d{1,1000} {0,1}\/ {0,1}\d{1,1000}$/.test(e)}function ct(e){return Array.isArray(e)?e.join("/"):e}function lt(e){return ot(e)?ct(e):void 0}function ft(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),n=()=>lt(e.ratio),i=()=>n()?`--ratio: ${n()}`:"",s=()=>typeof e.position=="string"?`--position: ${e.position}`:"50%",o=()=>[t(),i(),s()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","ratio","position"]),g({style:o,"data-bedrock-frame":()=>""})))}function Q(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth??0}px`};`,o=()=>[n(),i(),s()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","minItemWidth"]),g({style:o,"data-bedrock-grid":()=>""})))}const w=96;function J(e){const t=String(e),n=parseFloat(t),[,i]=t.match(/[\d.\-+]*\s*(.*)/)??["",""];return[n,i]}function N(e,t){if(!e)return;const n=t??document.body,i=(e??"px").trim().toLowerCase();switch(i){case"vmin":case"vmax":case"vh":case"vw":case"%":return;case"ch":case"ex":return at(i,n);case"em":return k(n,"font-size");case"rem":return k(document.body,"font-size");case"in":return w;case"cm":return w/2.54;case"mm":return w/25.4;case"pt":return w/72;case"pc":return w/6;case"px":return 1;default:{const[s,o]=J(i);if(isNaN(s))return;if(!o)return s;const c=N(o,t);return typeof c=="number"?s*c:void 0}}}function k(e,t){const[n,i]=J(getComputedStyle(e).getPropertyValue(t));return n*(N(i,e)??1)}function at(e,t){const n=document.createElement("div");n.style.height="128"+e,t.appendChild(n);const i=k(n,"height")/128;return t.removeChild(n),i}const dt=v("<div>"),I=1,ut=typeof window=="object"&&typeof document=="object"&&document.nodeType===9,mt=e=>{const[t,n]=l.createSignal(1),[i,s]=l.createSignal(),o=$();return l.onMount(()=>(P.init(),0)),l.createEffect(()=>{const c=j(i());if(c===void 0)return;const r=P.registerCallback(c,({target:f})=>{n(1);const a=e.gutter?b(o,e.gutter)??"1px":"1px",d=ut?N(a,f):void 0,u=Math.max(d??I,I),[h]=Array.from(f.children),C=1+Math.min(f.scrollHeight,h.scrollHeight),M=Math.max(Math.ceil(C/u),I);return n(M),0});return l.onCleanup(r),0}),(()=>{const c=dt();return me(s,c),H(c,()=>e.children),l.createRenderEffect(r=>G(c,`grid-row: span ${t()};`,r)),c})()},yt=e=>{const t=l.children(()=>e.children),i=[].concat(t()).filter(Boolean).map(s=>l.createComponent(mt,{get gutter(){return e.gutter},children:s}));return l.createComponent(Q,l.mergeProps({style:"grid-template-rows: 1px;"},e,{children:i}))},gt={start:"justify:start",end:"justify:end",center:"justify:center"},ht={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function bt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((f,[a,d])=>f+`${a}:${d};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>e.justify!==void 0?gt[e.justify]:void 0,o=()=>e.align!==void 0?ht[e.align]:void 0,c=()=>[n(),i()].join("; "),r=()=>[s(),o()].filter(Boolean).join(" ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","justify","align"]),g({style:c,"data-bedrock-inline-cluster":r})))}const $t={start:"justify:start",end:"justify:end",center:"justify:center"},Ct={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function St(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((u,[h,C])=>u+`${h}:${C};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,o=()=>e.switchAt?`--switchAt: ${A(t,e.switchAt)??"0px"};`:"",c=()=>e.justify!==void 0?$t[e.justify]:void 0,r=()=>e.align!==void 0?Ct[e.align]:void 0,f=()=>e.stretch?`stretch:${e.stretch}`:void 0,a=()=>[n(),i(),o(),s()].join("; "),d=()=>[c(),r(),f()].filter(Boolean).join(" ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","justify","align","stretch","switchAt"]),g({style:a,"data-bedrock-inline":d})))}const xt=e=>({left:"padding-inline-start",right:"padding-inline-end",top:"padding-block-start",bottom:"padding-block-end",inlineStart:"padding-inline-start",inlineEnd:"padding-inline-end",blockStart:"padding-block-start",blockEnd:"padding-block-end"})[e],wt=(e,t)=>{if(!t)return"";if(Array.isArray(t)&&t.length>4)throw new Error("padding arrays can only be 4 or less in length");const n=typeof t=="object"&&!Array.isArray(t)?Object.entries(t).reduce((i,[s,o])=>({...i,[xt(s)]:z(e,o)??"0px"}),{}):{padding:Array.from(Array.isArray(t)?t:[t]).map(i=>z(e,i)??"0px").join(" ")};return Object.entries(n).reduce((i,[s,o])=>i+`${s}:${o};`,"")};function jt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,r])=>o+`${c}:${r};`,""),i=()=>wt(t,e.padding),s=()=>[n(),i()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","padding"]),g({style:s,"data-bedrock-padbox":()=>""})))}function At(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>{switch(e.snapType){case"none":return"snapType:none";case"proximity":return"snapType:proximity";case"mandatory":return"snapType:mandatory";default:return"snapType:none"}},o=()=>[n(),i()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter"]),g({style:o,"data-bedrock-reel":s})))}const D={"1/4":"fraction:1/4","1/3":"fraction:1/3","1/2":"fraction:1/2","2/3":"fraction:2/3","3/4":"fraction:3/4","auto-start":"fraction:auto-start","auto-end":"fraction:auto-end"};function Pt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((f,[a,d])=>f+`${a}:${d};`,""),i=()=>e.switchAt?`--switchAt: ${A(t,e.switchAt)??"0px"};`:"",s=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,o=()=>D[e.fraction??"1/2"]??D["1/2"],c=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,r=()=>[n(),s(),i(),c()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","fraction"]),g({style:r,"data-bedrock-split":o})))}function Et(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,r])=>o+`${c}:${r};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>[n(),i()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter"]),g({style:s,"data-bedrock-stack":()=>""})))}const Mt=v("<div data-bedrock-cover-centered>");function It(e){return typeof e=="number"?`${e}px`:e&&E(e)?e:"100vh"}function Tt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>`--minHeight: ${It(e.minHeight)};`,o=()=>e.stretchContent===!0?"stretch-content":"",c=()=>[n(),i(),s()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","minHeight","stretchContent"]),g({style:c,"data-bedrock-cover":o})))}function Ot(e){const[t,n]=l.splitProps(e,["children","top","bottom"]);return l.createComponent(Tt,l.mergeProps(n,{get children(){return[l.createMemo(()=>t.top),(()=>{const i=Mt();return H(i,()=>t.children),i})(),l.createMemo(()=>t.bottom)]}}))}function zt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>`--columns: ${e.columns&&e.columns>0?e.columns:1};`,o=()=>e.switchAt?`--switchAt: ${A(t,e.switchAt)??"0px"};`:"",c=()=>[n(),i(),s(),o()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","columns","switchAt"]),g({style:c,"data-bedrock-columns":()=>""})))}const kt=e=>typeof e=="number"?e:1;function Nt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),n=()=>`--span: ${kt(e.span)};`,i=()=>e.offsetStart&&e.offsetStart>0?`--offsetStart: ${e.offsetStart};`:"",s=()=>e.offsetEnd&&e.offsetEnd>0?`--offsetEnd: ${e.offsetEnd};`:"",o=()=>[t(),n(),i(),s()].join("; ");return y(()=>e.as??"div",l.mergeProps(m(e,["as","span","offsetStart","offsetEnd"]),g({style:o,"data-bedrock-column":()=>""})))}exports.Center=tt;exports.Column=Nt;exports.ColumnDrop=st;exports.Columns=zt;exports.Cover=Ot;exports.Frame=ft;exports.Grid=Q;exports.Inline=St;exports.InlineCluster=bt;exports.MasonryGrid=yt;exports.PadBox=jt;exports.Reel=At;exports.Split=Pt;exports.Stack=Et;exports.ThemeProvider=nt;exports.checkIsCSSLength=E;exports.createContainerQuery=rt;exports.getSafeGutter=z;exports.getSizeValue=A;exports.getSpacingValue=b;exports.sizes=X;exports.spacing=F;exports.useTheme=$;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Y=require("open-props"),l=require("solid-js"),P=require("@bedrock-layout/register-resize-callback"),Z=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected"],K=new Set(["className","value","readOnly","formNoValidate","isMap","noModule","playsInline",...Z]),p=new Set(["innerHTML","textContent","innerText","children"]),ee=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),te=Object.assign(Object.create(null),{class:"className",formnovalidate:{$:"formNoValidate",BUTTON:1,INPUT:1},ismap:{$:"isMap",IMG:1},nomodule:{$:"noModule",SCRIPT:1},playsinline:{$:"playsInline",VIDEO:1},readonly:{$:"readOnly",INPUT:1,TEXTAREA:1}});function ne(e,t){const n=te[e];return typeof n=="object"?n[t]?n.$:void 0:n}const ie=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),se=new Set(["altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","set","stop","svg","switch","symbol","text","textPath","tref","tspan","use","view","vkern"]),re={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"};function oe(e,t,n){let i=n.length,s=t.length,o=i,c=0,r=0,f=t[s-1].nextSibling,a=null;for(;c<s||r<o;){if(t[c]===n[r]){c++,r++;continue}for(;t[s-1]===n[o-1];)s--,o--;if(s===c){const u=o<i?r?n[r-1].nextSibling:n[o-r]:f;for(;r<o;)e.insertBefore(n[r++],u)}else if(o===r)for(;c<s;)(!a||!a.has(t[c]))&&t[c].remove(),c++;else if(t[c]===n[o-1]&&n[r]===t[s-1]){const u=t[--s].nextSibling;e.insertBefore(n[r++],t[c++].nextSibling),e.insertBefore(n[--o],u),t[s]=n[o]}else{if(!a){a=new Map;let d=r;for(;d<o;)a.set(n[d],d++)}const u=a.get(t[c]);if(u!=null)if(r<u&&u<o){let d=c,h=1,C;for(;++d<s&&d<o&&!((C=a.get(t[d]))==null||C!==u+h);)h++;if(h>u-r){const I=t[c];for(;r<u;)e.insertBefore(n[r++],I)}else e.replaceChild(n[r++],t[c++])}else c++;else t[c++].remove()}}}const L="_$DX_DELEGATE";function G(e,t,n){let i;const s=()=>{const c=document.createElement("template");return c.innerHTML=e,n?c.content.firstChild.firstChild:c.content.firstChild},o=t?()=>l.untrack(()=>document.importNode(i||(i=s()),!0)):()=>(i||(i=s())).cloneNode(!0);return o.cloneNode=o,o}function ce(e,t=window.document){const n=t[L]||(t[L]=new Set);for(let i=0,s=e.length;i<s;i++){const o=e[i];n.has(o)||(n.add(o),t.addEventListener(o,be))}}function M(e,t,n){l.sharedConfig.context||(n==null?e.removeAttribute(t):e.setAttribute(t,n))}function le(e,t,n,i){l.sharedConfig.context||(i==null?e.removeAttributeNS(t,n):e.setAttributeNS(t,n,i))}function fe(e,t){l.sharedConfig.context||(t==null?e.removeAttribute("class"):e.className=t)}function ae(e,t,n,i){if(i)Array.isArray(n)?(e[`$$${t}`]=n[0],e[`$$${t}Data`]=n[1]):e[`$$${t}`]=n;else if(Array.isArray(n)){const s=n[0];e.addEventListener(t,n[0]=o=>s.call(e,n[1],o))}else e.addEventListener(t,n)}function ue(e,t,n={}){const i=Object.keys(t||{}),s=Object.keys(n);let o,c;for(o=0,c=s.length;o<c;o++){const r=s[o];!r||r==="undefined"||t[r]||(R(e,r,!1),delete n[r])}for(o=0,c=i.length;o<c;o++){const r=i[o],f=!!t[r];!r||r==="undefined"||n[r]===f||!f||(R(e,r,!0),n[r]=f)}return n}function v(e,t,n){if(!t)return n?M(e,"style"):t;const i=e.style;if(typeof t=="string")return i.cssText=t;typeof n=="string"&&(i.cssText=n=void 0),n||(n={}),t||(t={});let s,o;for(o in n)t[o]==null&&i.removeProperty(o),delete n[o];for(o in t)s=t[o],s!==n[o]&&(i.setProperty(o,s),n[o]=s);return n}function de(e,t={},n,i){const s={};return i||l.createRenderEffect(()=>s.children=x(e,t.children,s.children)),l.createRenderEffect(()=>t.ref&&t.ref(e)),l.createRenderEffect(()=>ge(e,t,n,!0,s,!0)),s}function me(e,t,n){return l.untrack(()=>e(t,n))}function H(e,t,n,i){if(n!==void 0&&!i&&(i=[]),typeof t!="function")return x(e,t,i,n);l.createRenderEffect(s=>x(e,t(),s,n),i)}function ge(e,t,n,i,s={},o=!1){t||(t={});for(const c in s)if(!(c in t)){if(c==="children")continue;s[c]=W(e,c,null,s[c],n,o)}for(const c in t){if(c==="children"){i||x(e,t.children);continue}const r=t[c];s[c]=W(e,c,r,s[c],n,o)}}function ye(e){let t,n;return!l.sharedConfig.context||!(t=l.sharedConfig.registry.get(n=$e()))?e():(l.sharedConfig.completed&&l.sharedConfig.completed.add(t),l.sharedConfig.registry.delete(n),t)}function he(e){return e.toLowerCase().replace(/-([a-z])/g,(t,n)=>n.toUpperCase())}function R(e,t,n){const i=t.trim().split(/\s+/);for(let s=0,o=i.length;s<o;s++)e.classList.toggle(i[s],n)}function W(e,t,n,i,s,o){let c,r,f,a,u;if(t==="style")return v(e,n,i);if(t==="classList")return ue(e,n,i);if(n===i)return i;if(t==="ref")o||n(e);else if(t.slice(0,3)==="on:"){const d=t.slice(3);i&&e.removeEventListener(d,i),n&&e.addEventListener(d,n)}else if(t.slice(0,10)==="oncapture:"){const d=t.slice(10);i&&e.removeEventListener(d,i,!0),n&&e.addEventListener(d,n,!0)}else if(t.slice(0,2)==="on"){const d=t.slice(2).toLowerCase(),h=ie.has(d);if(!h&&i){const C=Array.isArray(i)?i[0]:i;e.removeEventListener(d,C)}(h||n)&&(ae(e,d,n,h),h&&ce([d]))}else if(t.slice(0,5)==="attr:")M(e,t.slice(5),n);else if((u=t.slice(0,5)==="prop:")||(f=p.has(t))||!s&&((a=ne(t,e.tagName))||(r=K.has(t)))||(c=e.nodeName.includes("-"))){if(u)t=t.slice(5),r=!0;else if(l.sharedConfig.context)return n;t==="class"||t==="className"?fe(e,n):c&&!r&&!f?e[he(t)]=n:e[a||t]=n}else{const d=s&&t.indexOf(":")>-1&&re[t.split(":")[0]];d?le(e,d,t,n):M(e,ee[t]||t,n)}return n}function be(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),l.sharedConfig.registry&&!l.sharedConfig.done&&(l.sharedConfig.done=_$HY.done=!0);n;){const i=n[t];if(i&&!n.disabled){const s=n[`${t}Data`];if(s!==void 0?i.call(n,s,e):i.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function x(e,t,n,i,s){if(l.sharedConfig.context){!n&&(n=[...e.childNodes]);let r=[];for(let f=0;f<n.length;f++){const a=n[f];a.nodeType===8&&a.data.slice(0,2)==="!$"?a.remove():r.push(a)}n=r}for(;typeof n=="function";)n=n();if(t===n)return n;const o=typeof t,c=i!==void 0;if(e=c&&n[0]&&n[0].parentNode||e,o==="string"||o==="number"){if(l.sharedConfig.context)return n;if(o==="number"&&(t=t.toString()),c){let r=n[0];r&&r.nodeType===3?r.data=t:r=document.createTextNode(t),n=S(e,n,i,r)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||o==="boolean"){if(l.sharedConfig.context)return n;n=S(e,n,i)}else{if(o==="function")return l.createRenderEffect(()=>{let r=t();for(;typeof r=="function";)r=r();n=x(e,r,n,i)}),()=>n;if(Array.isArray(t)){const r=[],f=n&&Array.isArray(n);if(z(r,t,n,s))return l.createRenderEffect(()=>n=x(e,r,n,i,!0)),()=>n;if(l.sharedConfig.context){if(!r.length)return n;if(i===void 0)return[...e.childNodes];let a=r[0],u=[a];for(;(a=a.nextSibling)!==i;)u.push(a);return n=u}if(r.length===0){if(n=S(e,n,i),c)return n}else f?n.length===0?B(e,r,i):oe(e,n,r):(n&&S(e),B(e,r));n=r}else if(t.nodeType){if(l.sharedConfig.context&&t.parentNode)return n=c?[t]:t;if(Array.isArray(n)){if(c)return n=S(e,n,i,t);S(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}}return n}function z(e,t,n,i){let s=!1;for(let o=0,c=t.length;o<c;o++){let r=t[o],f=n&&n[o],a;if(!(r==null||r===!0||r===!1))if((a=typeof r)=="object"&&r.nodeType)e.push(r);else if(Array.isArray(r))s=z(e,r,f)||s;else if(a==="function")if(i){for(;typeof r=="function";)r=r();s=z(e,Array.isArray(r)?r:[r],Array.isArray(f)?f:[f])||s}else e.push(r),s=!0;else{const u=String(r);f&&f.nodeType===3&&f.data===u?e.push(f):e.push(document.createTextNode(u))}}return s}function B(e,t,n=null){for(let i=0,s=t.length;i<s;i++)e.insertBefore(t[i],n)}function S(e,t,n,i){if(n===void 0)return e.textContent="";const s=i||document.createTextNode("");if(t.length){let o=!1;for(let c=t.length-1;c>=0;c--){const r=t[c];if(s!==r){const f=r.parentNode===e;!o&&!c?f?e.replaceChild(s,r):e.insertBefore(s,n):f&&r.remove()}else o=!0}}else e.insertBefore(s,n);return[s]}function $e(){const e=l.sharedConfig.context;return`${e.id}${e.count++}`}const Ce="http://www.w3.org/2000/svg";function Se(e,t=!1){return t?document.createElementNS(Ce,e):document.createElement(e)}function xe(e){const[t,n]=l.splitProps(e,["component"]),i=l.createMemo(()=>t.component);return l.createMemo(()=>{const s=i();switch(typeof s){case"function":return l.untrack(()=>s(n));case"string":const o=se.has(s),c=l.sharedConfig.context?ye():Se(s,o);return de(c,n,o),c}})}function j(e){return e??void 0}function m(e,t){return Object.keys(e).filter(n=>!t.includes(n)).reduce((n,i)=>Object.defineProperty({...n},i,{get(){return e[i]},configurable:!0,enumerable:!0}),{})}function g(e,t){return l.createComponent(xe,l.mergeProps({get component(){return e()}},t))}function y(e){return Object.values(e).every(t=>typeof t=="function")?Object.keys(e).reduce((t,n)=>{const i=e[n];return Object.defineProperty({...t},n,{get(){return i()},configurable:!0,enumerable:!0})},{}):new Error("Please provide an object with accessor values only.")}const _=/^--\D{1}.{0,100}$/;function F(e){return _.test(e)}function E(e){return typeof e!="string"?!1:[/^[0-9]{0,10000}\.?[0-9]{1,10000}(vmin|vmax|vh|vw|%|ch|ex|em|rem|in|cm|mm|pt|pc|px)$/,/^var\(--\D{1}.{0,100}\)$/,_].some(t=>t.test(e))}const{sizeXxs:we,sizeXs:je,sizeSm:Ae,sizeMd:Pe,sizeLg:Ee,sizeXl:Ie,sizeXxl:Te,sizeContent1:Me,sizeContent2:ze,sizeContent3:Oe,sizeHeader1:ke,sizeHeader2:Ne,sizeHeader3:Le,size000:Re,size00:We,size1:Be,size2:De,size3:Ge,size4:ve,size5:He,size6:_e,size7:Fe,size8:Ve,size9:Xe,size10:qe,size11:Ue,size12:Qe,size13:Je,size14:Ye,size15:Ze}=Y,Ke={size000:Re,size00:We,size1:Be,size2:De,size3:Ge,size4:ve,size5:He,size6:_e,size7:Fe,size8:Ve,size9:Xe,size10:qe,size11:Ue,size12:Qe,size13:Je,size14:Ye,size15:Ze},pe={sizeXxs:we,sizeXs:je,sizeSm:Ae,sizeMd:Pe,sizeLg:Ee,sizeXl:Ie,sizeXxl:Te,sizeContent1:Me,sizeContent2:ze,sizeContent3:Oe,sizeHeader1:ke,sizeHeader2:Ne,sizeHeader3:Le},V=Ke,X=pe;function q(e){return e.reduce((t,[n,i])=>({...t,[n]:i}),{})}function O(e,t){if(t!==void 0)return typeof t=="number"&&t>=0?`${t}px`:typeof t=="string"&&E(t)?F(t)?`var(${t})`:t:j(b(e,t))}function b(e,t){const n=e.space??V,i=q(Object.entries(n).map(([s,o])=>[s,typeof o=="number"?`${o}px`:o]));return j(i[t])}function A(e,t){if(t===void 0)return;if(typeof t=="number"&&t>=0)return`${t}px`;if(typeof t=="string"&&E(t))return F(t)?`var(${t})`:t;const n=e.sizes??X,i=q(Object.entries(n).map(([s,o])=>[s,typeof o=="number"?`${o}px`:o]));return j(i[t])}function et(e){return e===void 0?"100%":typeof e=="number"?`${e}px`:e}function tt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),n=()=>`--maxWidth: ${et(e.maxWidth)};`,i=()=>e.centerText?"center-text":"",s=()=>e.centerChildren?"center-children":"",o=()=>[i(),s()].filter(Boolean).join(" "),c=()=>[t(),n()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","maxWidth","centerText","centerChildren"]),y({style:c,"data-bedrock-center":o})))}const U=l.createContext({});function nt(e){return l.createComponent(U.Provider,{get value(){return e.theme},get children(){return e.children}})}function $(){try{return l.useContext(U)}catch{return{}}}function it(e,t){return A(e,t)}function st(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"}`,s=()=>`--minItemWidth: ${it(t,e.minItemWidth)}`,o=()=>e.noStretchedColumns===!0?"no-stretched-columns":"",c=()=>[n(),i(),s()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","minItemWidth","noStretchedColumns"]),y({style:c,"data-bedrock-column-drop":o})))}function rt(e,t){const[n,i]=l.createSignal(!1),[s,o]=l.createSignal();return l.onMount(()=>(P.init(),0)),l.createEffect(()=>{if(j(s())===void 0)return 0;t&&t(s());const c=P.registerCallback(s(),r=>{var a;const f=((a=r.borderBoxSize)==null?void 0:a.inlineSize)??r.contentRect.width;if(f>0){const u=f<=e;i(u)}return 0});return l.onCleanup(c),0}),[n,o]}function ot(e){return Array.isArray(e)&&e.length===2&&e.every(Number.isFinite)||typeof e=="string"&&/^\d{1,1000} {0,1}\/ {0,1}\d{1,1000}$/.test(e)}function ct(e){return Array.isArray(e)?e.join("/"):e}function lt(e){return ot(e)?ct(e):void 0}function ft(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),n=()=>lt(e.ratio),i=()=>n()?`--ratio: ${n()}`:"",s=()=>typeof e.position=="string"?`--position: ${e.position}`:"50%",o=()=>[t(),i(),s()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","ratio","position"]),y({style:o,"data-bedrock-frame":()=>""})))}function Q(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth??0}px`};`,o=()=>[n(),i(),s()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","minItemWidth"]),y({style:o,"data-bedrock-grid":()=>""})))}const w=96;function J(e){const t=String(e),n=parseFloat(t),[,i]=t.match(/[\d.\-+]*\s*(.*)/)??["",""];return[n,i]}function N(e,t){if(!e)return;const n=t??document.body,i=(e??"px").trim().toLowerCase();switch(i){case"vmin":case"vmax":case"vh":case"vw":case"%":return;case"ch":case"ex":return at(i,n);case"em":return k(n,"font-size");case"rem":return k(document.body,"font-size");case"in":return w;case"cm":return w/2.54;case"mm":return w/25.4;case"pt":return w/72;case"pc":return w/6;case"px":return 1;default:{const[s,o]=J(i);if(isNaN(s))return;if(!o)return s;const c=N(o,t);return typeof c=="number"?s*c:void 0}}}function k(e,t){const[n,i]=J(getComputedStyle(e).getPropertyValue(t));return n*(N(i,e)??1)}function at(e,t){const n=document.createElement("div");n.style.height="128"+e,t.appendChild(n);const i=k(n,"height")/128;return t.removeChild(n),i}const ut=G("<div>"),T=1,dt=typeof window=="object"&&typeof document=="object"&&document.nodeType===9,mt=e=>{const[t,n]=l.createSignal(1),[i,s]=l.createSignal(),o=$();return l.onMount(()=>(P.init(),0)),l.createEffect(()=>{const c=j(i());if(c===void 0)return;const r=P.registerCallback(c,({target:f})=>{n(1);const a=e.gutter?b(o,e.gutter)??"1px":"1px",u=dt?N(a,f):void 0,d=Math.max(u??T,T),[h]=Array.from(f.children),C=1+Math.min(f.scrollHeight,h.scrollHeight),I=Math.max(Math.ceil(C/d),T);return n(I),0});return l.onCleanup(r),0}),(()=>{const c=ut();return me(s,c),H(c,()=>e.children),l.createRenderEffect(r=>v(c,`grid-row: span ${t()};`,r)),c})()},gt=e=>{const t=l.children(()=>e.children),i=[].concat(t()).filter(Boolean).map(s=>l.createComponent(mt,{get gutter(){return e.gutter},children:s}));return l.createComponent(Q,l.mergeProps({style:"grid-template-rows: 1px;"},e,{children:i}))},yt={start:"justify:start",end:"justify:end",center:"justify:center"},ht={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function bt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((f,[a,u])=>f+`${a}:${u};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>e.justify!==void 0?yt[e.justify]:void 0,o=()=>e.align!==void 0?ht[e.align]:void 0,c=()=>[n(),i()].join("; "),r=()=>[s(),o()].filter(Boolean).join(" ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","justify","align"]),y({style:c,"data-bedrock-inline-cluster":r})))}const $t={start:"justify:start",end:"justify:end",center:"justify:center"},Ct={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function St(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((d,[h,C])=>d+`${h}:${C};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,o=()=>e.switchAt?`--switchAt: ${A(t,e.switchAt)??"0px"};`:"",c=()=>e.justify!==void 0?$t[e.justify]:void 0,r=()=>e.align!==void 0?Ct[e.align]:void 0,f=()=>e.stretch?`stretch:${e.stretch}`:void 0,a=()=>[n(),i(),o(),s()].join("; "),u=()=>[c(),r(),f()].filter(Boolean).join(" ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","justify","align","stretch","switchAt"]),y({style:a,"data-bedrock-inline":u})))}const xt=e=>({left:"padding-inline-start",right:"padding-inline-end",top:"padding-block-start",bottom:"padding-block-end",inlineStart:"padding-inline-start",inlineEnd:"padding-inline-end",blockStart:"padding-block-start",blockEnd:"padding-block-end"})[e],wt=(e,t)=>{if(!t)return"";if(Array.isArray(t)&&t.length>4)throw new Error("padding arrays can only be 4 or less in length");const n=typeof t=="object"&&!Array.isArray(t)?Object.entries(t).reduce((i,[s,o])=>({...i,[xt(s)]:O(e,o)??"0px"}),{}):{padding:Array.from(Array.isArray(t)?t:[t]).map(i=>O(e,i)??"0px").join(" ")};return Object.entries(n).reduce((i,[s,o])=>i+`${s}:${o};`,"")};function jt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,r])=>o+`${c}:${r};`,""),i=()=>wt(t,e.padding),s=()=>[n(),i()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","padding"]),y({style:s,"data-bedrock-padbox":()=>""})))}function At(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>{switch(e.snapType){case"none":return"snapType:none";case"proximity":return"snapType:proximity";case"mandatory":return"snapType:mandatory";default:return"snapType:none"}},o=()=>[n(),i()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter"]),y({style:o,"data-bedrock-reel":s})))}const D={"1/4":"fraction:1/4","1/3":"fraction:1/3","1/2":"fraction:1/2","2/3":"fraction:2/3","3/4":"fraction:3/4","auto-start":"fraction:auto-start","auto-end":"fraction:auto-end"};function Pt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((f,[a,u])=>f+`${a}:${u};`,""),i=()=>e.switchAt?`--switchAt: ${A(t,e.switchAt)??"0px"};`:"",s=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,o=()=>D[e.fraction??"1/2"]??D["1/2"],c=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,r=()=>[n(),s(),i(),c()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","fraction"]),y({style:r,"data-bedrock-split":o})))}function Et(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,r])=>o+`${c}:${r};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>[n(),i()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter"]),y({style:s,"data-bedrock-stack":()=>""})))}const It=G("<div data-bedrock-cover-centered>");function Tt(e){return typeof e=="number"?`${e}px`:e&&E(e)?e:"100vh"}function Mt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>`--minHeight: ${Tt(e.minHeight)};`,o=()=>e.stretchContent===!0?"stretch-content":"",c=()=>[n(),i(),s()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","minHeight","stretchContent"]),y({style:c,"data-bedrock-cover":o})))}function zt(e){const[t,n]=l.splitProps(e,["children","top","bottom"]);return l.createComponent(Mt,l.mergeProps(n,{get children(){return[l.createMemo(()=>t.top),(()=>{const i=It();return H(i,()=>t.children),i})(),l.createMemo(()=>t.bottom)]}}))}function Ot(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((r,[f,a])=>r+`${f}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>`--columns: ${e.columns&&e.columns>0?e.columns:1};`,o=()=>e.switchAt?`--switchAt: ${A(t,e.switchAt)??"0px"};`:"",c=()=>[n(),i(),s(),o()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","gutter","columns","switchAt"]),y({style:c,"data-bedrock-columns":()=>""})))}const kt=e=>typeof e=="number"?e:1;function Nt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[r,f])=>c+`${r}:${f};`,""),n=()=>`--span: ${kt(e.span)};`,i=()=>e.offsetStart&&e.offsetStart>0?`--offsetStart: ${e.offsetStart};`:"",s=()=>e.offsetEnd&&e.offsetEnd>0?`--offsetEnd: ${e.offsetEnd};`:"",o=()=>[t(),n(),i(),s()].join("; ");return g(()=>e.as??"div",l.mergeProps(m(e,["as","span","offsetStart","offsetEnd"]),y({style:o,"data-bedrock-column":()=>""})))}exports.Center=tt;exports.Column=Nt;exports.ColumnDrop=st;exports.Columns=Ot;exports.Cover=zt;exports.Frame=ft;exports.Grid=Q;exports.Inline=St;exports.InlineCluster=bt;exports.MasonryGrid=gt;exports.PadBox=jt;exports.Reel=At;exports.Split=Pt;exports.Stack=Et;exports.ThemeProvider=nt;exports.checkIsCSSLength=E;exports.createContainerQuery=rt;exports.getSafeGutter=O;exports.getSizeValue=A;exports.getSpacingValue=b;exports.sizes=X;exports.spacing=V;exports.useTheme=$;
|
package/lib/index.m.js
CHANGED
|
@@ -1,10 +1,50 @@
|
|
|
1
1
|
import se from "open-props";
|
|
2
|
-
import { createRenderEffect as w, sharedConfig as d, splitProps as V, createMemo as
|
|
2
|
+
import { createRenderEffect as w, sharedConfig as d, splitProps as V, createMemo as T, untrack as W, createComponent as E, mergeProps as y, createContext as oe, useContext as ce, createSignal as O, onMount as X, createEffect as U, onCleanup as q, children as re } from "solid-js";
|
|
3
3
|
import { init as Q, registerCallback as Y } from "@bedrock-layout/register-resize-callback";
|
|
4
|
-
const
|
|
4
|
+
const le = [
|
|
5
|
+
"allowfullscreen",
|
|
6
|
+
"async",
|
|
7
|
+
"autofocus",
|
|
8
|
+
"autoplay",
|
|
9
|
+
"checked",
|
|
10
|
+
"controls",
|
|
11
|
+
"default",
|
|
12
|
+
"disabled",
|
|
13
|
+
"formnovalidate",
|
|
14
|
+
"hidden",
|
|
15
|
+
"indeterminate",
|
|
16
|
+
"inert",
|
|
17
|
+
"ismap",
|
|
18
|
+
"loop",
|
|
19
|
+
"multiple",
|
|
20
|
+
"muted",
|
|
21
|
+
"nomodule",
|
|
22
|
+
"novalidate",
|
|
23
|
+
"open",
|
|
24
|
+
"playsinline",
|
|
25
|
+
"readonly",
|
|
26
|
+
"required",
|
|
27
|
+
"reversed",
|
|
28
|
+
"seamless",
|
|
29
|
+
"selected"
|
|
30
|
+
], fe = /* @__PURE__ */ new Set([
|
|
31
|
+
"className",
|
|
32
|
+
"value",
|
|
33
|
+
"readOnly",
|
|
34
|
+
"formNoValidate",
|
|
35
|
+
"isMap",
|
|
36
|
+
"noModule",
|
|
37
|
+
"playsInline",
|
|
38
|
+
...le
|
|
39
|
+
]), ae = /* @__PURE__ */ new Set([
|
|
40
|
+
"innerHTML",
|
|
41
|
+
"textContent",
|
|
42
|
+
"innerText",
|
|
43
|
+
"children"
|
|
44
|
+
]), ue = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
|
|
5
45
|
className: "class",
|
|
6
46
|
htmlFor: "for"
|
|
7
|
-
}),
|
|
47
|
+
}), de = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
|
|
8
48
|
class: "className",
|
|
9
49
|
formnovalidate: {
|
|
10
50
|
$: "formNoValidate",
|
|
@@ -29,11 +69,34 @@ const fe = ["allowfullscreen", "async", "autofocus", "autoplay", "checked", "con
|
|
|
29
69
|
TEXTAREA: 1
|
|
30
70
|
}
|
|
31
71
|
});
|
|
32
|
-
function
|
|
33
|
-
const n =
|
|
72
|
+
function ye(e, t) {
|
|
73
|
+
const n = de[e];
|
|
34
74
|
return typeof n == "object" ? n[t] ? n.$ : void 0 : n;
|
|
35
75
|
}
|
|
36
|
-
const
|
|
76
|
+
const me = /* @__PURE__ */ new Set([
|
|
77
|
+
"beforeinput",
|
|
78
|
+
"click",
|
|
79
|
+
"dblclick",
|
|
80
|
+
"contextmenu",
|
|
81
|
+
"focusin",
|
|
82
|
+
"focusout",
|
|
83
|
+
"input",
|
|
84
|
+
"keydown",
|
|
85
|
+
"keyup",
|
|
86
|
+
"mousedown",
|
|
87
|
+
"mousemove",
|
|
88
|
+
"mouseout",
|
|
89
|
+
"mouseover",
|
|
90
|
+
"mouseup",
|
|
91
|
+
"pointerdown",
|
|
92
|
+
"pointermove",
|
|
93
|
+
"pointerout",
|
|
94
|
+
"pointerover",
|
|
95
|
+
"pointerup",
|
|
96
|
+
"touchend",
|
|
97
|
+
"touchmove",
|
|
98
|
+
"touchstart"
|
|
99
|
+
]), he = /* @__PURE__ */ new Set([
|
|
37
100
|
"altGlyph",
|
|
38
101
|
"altGlyphDef",
|
|
39
102
|
"altGlyphItem",
|
|
@@ -110,11 +173,11 @@ const he = /* @__PURE__ */ new Set(["beforeinput", "click", "dblclick", "context
|
|
|
110
173
|
"use",
|
|
111
174
|
"view",
|
|
112
175
|
"vkern"
|
|
113
|
-
]),
|
|
176
|
+
]), ge = {
|
|
114
177
|
xlink: "http://www.w3.org/1999/xlink",
|
|
115
178
|
xml: "http://www.w3.org/XML/1998/namespace"
|
|
116
179
|
};
|
|
117
|
-
function
|
|
180
|
+
function $e(e, t, n) {
|
|
118
181
|
let i = n.length, s = t.length, c = i, r = 0, o = 0, l = t[s - 1].nextSibling, f = null;
|
|
119
182
|
for (; r < s || o < c; ) {
|
|
120
183
|
if (t[r] === n[o]) {
|
|
@@ -147,9 +210,9 @@ function be(e, t, n) {
|
|
|
147
210
|
for (; ++u < s && u < c && !((S = f.get(t[u])) == null || S !== a + $); )
|
|
148
211
|
$++;
|
|
149
212
|
if ($ > a - o) {
|
|
150
|
-
const
|
|
213
|
+
const z = t[r];
|
|
151
214
|
for (; o < a; )
|
|
152
|
-
e.insertBefore(n[o++],
|
|
215
|
+
e.insertBefore(n[o++], z);
|
|
153
216
|
} else
|
|
154
217
|
e.replaceChild(n[o++], t[r++]);
|
|
155
218
|
} else
|
|
@@ -159,7 +222,7 @@ function be(e, t, n) {
|
|
|
159
222
|
}
|
|
160
223
|
}
|
|
161
224
|
}
|
|
162
|
-
const
|
|
225
|
+
const D = "_$DX_DELEGATE";
|
|
163
226
|
function J(e, t, n) {
|
|
164
227
|
let i;
|
|
165
228
|
const s = () => {
|
|
@@ -168,23 +231,23 @@ function J(e, t, n) {
|
|
|
168
231
|
}, c = t ? () => W(() => document.importNode(i || (i = s()), !0)) : () => (i || (i = s())).cloneNode(!0);
|
|
169
232
|
return c.cloneNode = c, c;
|
|
170
233
|
}
|
|
171
|
-
function
|
|
172
|
-
const n = t[
|
|
234
|
+
function be(e, t = window.document) {
|
|
235
|
+
const n = t[D] || (t[D] = /* @__PURE__ */ new Set());
|
|
173
236
|
for (let i = 0, s = e.length; i < s; i++) {
|
|
174
237
|
const c = e[i];
|
|
175
|
-
n.has(c) || (n.add(c), t.addEventListener(c,
|
|
238
|
+
n.has(c) || (n.add(c), t.addEventListener(c, Oe));
|
|
176
239
|
}
|
|
177
240
|
}
|
|
178
|
-
function
|
|
179
|
-
n == null ? e.removeAttribute(t) : e.setAttribute(t, n);
|
|
241
|
+
function N(e, t, n) {
|
|
242
|
+
d.context || (n == null ? e.removeAttribute(t) : e.setAttribute(t, n));
|
|
180
243
|
}
|
|
181
|
-
function
|
|
182
|
-
i == null ? e.removeAttributeNS(t, n) : e.setAttributeNS(t, n, i);
|
|
244
|
+
function xe(e, t, n, i) {
|
|
245
|
+
d.context || (i == null ? e.removeAttributeNS(t, n) : e.setAttributeNS(t, n, i));
|
|
183
246
|
}
|
|
184
|
-
function
|
|
185
|
-
t == null ? e.removeAttribute("class") : e.className = t;
|
|
247
|
+
function Se(e, t) {
|
|
248
|
+
d.context || (t == null ? e.removeAttribute("class") : e.className = t);
|
|
186
249
|
}
|
|
187
|
-
function
|
|
250
|
+
function we(e, t, n, i) {
|
|
188
251
|
if (i)
|
|
189
252
|
Array.isArray(n) ? (e[`$$${t}`] = n[0], e[`$$${t}Data`] = n[1]) : e[`$$${t}`] = n;
|
|
190
253
|
else if (Array.isArray(n)) {
|
|
@@ -193,22 +256,22 @@ function je(e, t, n, i) {
|
|
|
193
256
|
} else
|
|
194
257
|
e.addEventListener(t, n);
|
|
195
258
|
}
|
|
196
|
-
function
|
|
259
|
+
function je(e, t, n = {}) {
|
|
197
260
|
const i = Object.keys(t || {}), s = Object.keys(n);
|
|
198
261
|
let c, r;
|
|
199
262
|
for (c = 0, r = s.length; c < r; c++) {
|
|
200
263
|
const o = s[c];
|
|
201
|
-
!o || o === "undefined" || t[o] || (
|
|
264
|
+
!o || o === "undefined" || t[o] || (G(e, o, !1), delete n[o]);
|
|
202
265
|
}
|
|
203
266
|
for (c = 0, r = i.length; c < r; c++) {
|
|
204
267
|
const o = i[c], l = !!t[o];
|
|
205
|
-
!o || o === "undefined" || n[o] === l || !l || (
|
|
268
|
+
!o || o === "undefined" || n[o] === l || !l || (G(e, o, !0), n[o] = l);
|
|
206
269
|
}
|
|
207
270
|
return n;
|
|
208
271
|
}
|
|
209
272
|
function Z(e, t, n) {
|
|
210
273
|
if (!t)
|
|
211
|
-
return n ?
|
|
274
|
+
return n ? N(e, "style") : t;
|
|
212
275
|
const i = e.style;
|
|
213
276
|
if (typeof t == "string")
|
|
214
277
|
return i.cssText = t;
|
|
@@ -220,11 +283,13 @@ function Z(e, t, n) {
|
|
|
220
283
|
s = t[c], s !== n[c] && (i.setProperty(c, s), n[c] = s);
|
|
221
284
|
return n;
|
|
222
285
|
}
|
|
223
|
-
function
|
|
286
|
+
function Ae(e, t = {}, n, i) {
|
|
224
287
|
const s = {};
|
|
225
|
-
return i || w(
|
|
288
|
+
return i || w(
|
|
289
|
+
() => s.children = A(e, t.children, s.children)
|
|
290
|
+
), w(() => t.ref && t.ref(e)), w(() => Ee(e, t, n, !0, s, !0)), s;
|
|
226
291
|
}
|
|
227
|
-
function
|
|
292
|
+
function Ce(e, t, n) {
|
|
228
293
|
return W(() => e(t, n));
|
|
229
294
|
}
|
|
230
295
|
function K(e, t, n, i) {
|
|
@@ -232,7 +297,7 @@ function K(e, t, n, i) {
|
|
|
232
297
|
return A(e, t, i, n);
|
|
233
298
|
w((s) => A(e, t(), s, n), i);
|
|
234
299
|
}
|
|
235
|
-
function
|
|
300
|
+
function Ee(e, t, n, i, s = {}, c = !1) {
|
|
236
301
|
t || (t = {});
|
|
237
302
|
for (const r in s)
|
|
238
303
|
if (!(r in t)) {
|
|
@@ -251,17 +316,12 @@ function Oe(e, t, n, i, s = {}, c = !1) {
|
|
|
251
316
|
}
|
|
252
317
|
function Ie(e) {
|
|
253
318
|
let t, n;
|
|
254
|
-
|
|
255
|
-
if (d.context && console.warn("Unable to find DOM nodes for hydration key:", n), !e)
|
|
256
|
-
throw new Error("Unrecoverable Hydration Mismatch. No template for key: " + n);
|
|
257
|
-
return e();
|
|
258
|
-
}
|
|
259
|
-
return d.completed && d.completed.add(t), d.registry.delete(n), t;
|
|
319
|
+
return !d.context || !(t = d.registry.get(n = Pe())) ? e() : (d.completed && d.completed.add(t), d.registry.delete(n), t);
|
|
260
320
|
}
|
|
261
321
|
function Te(e) {
|
|
262
322
|
return e.toLowerCase().replace(/-([a-z])/g, (t, n) => n.toUpperCase());
|
|
263
323
|
}
|
|
264
|
-
function
|
|
324
|
+
function G(e, t, n) {
|
|
265
325
|
const i = t.trim().split(/\s+/);
|
|
266
326
|
for (let s = 0, c = i.length; s < c; s++)
|
|
267
327
|
e.classList.toggle(i[s], n);
|
|
@@ -271,7 +331,7 @@ function H(e, t, n, i, s, c) {
|
|
|
271
331
|
if (t === "style")
|
|
272
332
|
return Z(e, n, i);
|
|
273
333
|
if (t === "classList")
|
|
274
|
-
return
|
|
334
|
+
return je(e, n, i);
|
|
275
335
|
if (n === i)
|
|
276
336
|
return i;
|
|
277
337
|
if (t === "ref")
|
|
@@ -283,23 +343,27 @@ function H(e, t, n, i, s, c) {
|
|
|
283
343
|
const u = t.slice(10);
|
|
284
344
|
i && e.removeEventListener(u, i, !0), n && e.addEventListener(u, n, !0);
|
|
285
345
|
} else if (t.slice(0, 2) === "on") {
|
|
286
|
-
const u = t.slice(2).toLowerCase(), $ =
|
|
346
|
+
const u = t.slice(2).toLowerCase(), $ = me.has(u);
|
|
287
347
|
if (!$ && i) {
|
|
288
348
|
const S = Array.isArray(i) ? i[0] : i;
|
|
289
349
|
e.removeEventListener(u, S);
|
|
290
350
|
}
|
|
291
|
-
($ || n) && (
|
|
351
|
+
($ || n) && (we(e, u, n, $), $ && be([u]));
|
|
292
352
|
} else if (t.slice(0, 5) === "attr:")
|
|
293
|
-
|
|
294
|
-
else if ((a = t.slice(0, 5) === "prop:") || (l =
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
353
|
+
N(e, t.slice(5), n);
|
|
354
|
+
else if ((a = t.slice(0, 5) === "prop:") || (l = ae.has(t)) || !s && ((f = ye(t, e.tagName)) || (o = fe.has(t))) || (r = e.nodeName.includes("-"))) {
|
|
355
|
+
if (a)
|
|
356
|
+
t = t.slice(5), o = !0;
|
|
357
|
+
else if (d.context)
|
|
358
|
+
return n;
|
|
359
|
+
t === "class" || t === "className" ? Se(e, n) : r && !o && !l ? e[Te(t)] = n : e[f || t] = n;
|
|
360
|
+
} else {
|
|
361
|
+
const u = s && t.indexOf(":") > -1 && ge[t.split(":")[0]];
|
|
362
|
+
u ? xe(e, u, t, n) : N(e, ue[t] || t, n);
|
|
299
363
|
}
|
|
300
364
|
return n;
|
|
301
365
|
}
|
|
302
|
-
function
|
|
366
|
+
function Oe(e) {
|
|
303
367
|
const t = `$$${e.type}`;
|
|
304
368
|
let n = e.composedPath && e.composedPath()[0] || e.target;
|
|
305
369
|
for (e.target !== n && Object.defineProperty(e, "target", {
|
|
@@ -357,20 +421,23 @@ function A(e, t, n, i, s) {
|
|
|
357
421
|
}), () => n;
|
|
358
422
|
if (Array.isArray(t)) {
|
|
359
423
|
const o = [], l = n && Array.isArray(n);
|
|
360
|
-
if (
|
|
424
|
+
if (k(o, t, n, s))
|
|
361
425
|
return w(() => n = A(e, o, n, i, !0)), () => n;
|
|
362
426
|
if (d.context) {
|
|
363
427
|
if (!o.length)
|
|
364
428
|
return n;
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
429
|
+
if (i === void 0)
|
|
430
|
+
return [...e.childNodes];
|
|
431
|
+
let f = o[0], a = [f];
|
|
432
|
+
for (; (f = f.nextSibling) !== i; )
|
|
433
|
+
a.push(f);
|
|
434
|
+
return n = a;
|
|
368
435
|
}
|
|
369
436
|
if (o.length === 0) {
|
|
370
437
|
if (n = j(e, n, i), r)
|
|
371
438
|
return n;
|
|
372
439
|
} else
|
|
373
|
-
l ? n.length === 0 ?
|
|
440
|
+
l ? n.length === 0 ? v(e, o, i) : $e(e, n, o) : (n && j(e), v(e, o));
|
|
374
441
|
n = o;
|
|
375
442
|
} else if (t.nodeType) {
|
|
376
443
|
if (d.context && t.parentNode)
|
|
@@ -382,12 +449,11 @@ function A(e, t, n, i, s) {
|
|
|
382
449
|
} else
|
|
383
450
|
n == null || n === "" || !e.firstChild ? e.appendChild(t) : e.replaceChild(t, e.firstChild);
|
|
384
451
|
n = t;
|
|
385
|
-
}
|
|
386
|
-
console.warn("Unrecognized value. Skipped inserting", t);
|
|
452
|
+
}
|
|
387
453
|
}
|
|
388
454
|
return n;
|
|
389
455
|
}
|
|
390
|
-
function
|
|
456
|
+
function k(e, t, n, i) {
|
|
391
457
|
let s = !1;
|
|
392
458
|
for (let c = 0, r = t.length; c < r; c++) {
|
|
393
459
|
let o = t[c], l = n && n[c], f;
|
|
@@ -395,12 +461,16 @@ function N(e, t, n, i) {
|
|
|
395
461
|
if ((f = typeof o) == "object" && o.nodeType)
|
|
396
462
|
e.push(o);
|
|
397
463
|
else if (Array.isArray(o))
|
|
398
|
-
s =
|
|
464
|
+
s = k(e, o, l) || s;
|
|
399
465
|
else if (f === "function")
|
|
400
466
|
if (i) {
|
|
401
467
|
for (; typeof o == "function"; )
|
|
402
468
|
o = o();
|
|
403
|
-
s =
|
|
469
|
+
s = k(
|
|
470
|
+
e,
|
|
471
|
+
Array.isArray(o) ? o : [o],
|
|
472
|
+
Array.isArray(l) ? l : [l]
|
|
473
|
+
) || s;
|
|
404
474
|
} else
|
|
405
475
|
e.push(o), s = !0;
|
|
406
476
|
else {
|
|
@@ -410,7 +480,7 @@ function N(e, t, n, i) {
|
|
|
410
480
|
}
|
|
411
481
|
return s;
|
|
412
482
|
}
|
|
413
|
-
function
|
|
483
|
+
function v(e, t, n = null) {
|
|
414
484
|
for (let i = 0, s = t.length; i < s; i++)
|
|
415
485
|
e.insertBefore(t[i], n);
|
|
416
486
|
}
|
|
@@ -432,30 +502,28 @@ function j(e, t, n, i) {
|
|
|
432
502
|
e.insertBefore(s, n);
|
|
433
503
|
return [s];
|
|
434
504
|
}
|
|
435
|
-
function
|
|
505
|
+
function Pe() {
|
|
436
506
|
const e = d.context;
|
|
437
507
|
return `${e.id}${e.count++}`;
|
|
438
508
|
}
|
|
439
509
|
const ze = "http://www.w3.org/2000/svg";
|
|
440
|
-
function
|
|
510
|
+
function Me(e, t = !1) {
|
|
441
511
|
return t ? document.createElementNS(ze, e) : document.createElement(e);
|
|
442
512
|
}
|
|
443
513
|
function Ne(e) {
|
|
444
|
-
const [t, n] = V(e, ["component"]), i =
|
|
445
|
-
return
|
|
514
|
+
const [t, n] = V(e, ["component"]), i = T(() => t.component);
|
|
515
|
+
return T(() => {
|
|
446
516
|
const s = i();
|
|
447
517
|
switch (typeof s) {
|
|
448
518
|
case "function":
|
|
449
|
-
return
|
|
450
|
-
[oe]: !0
|
|
451
|
-
}), W(() => s(n));
|
|
519
|
+
return W(() => s(n));
|
|
452
520
|
case "string":
|
|
453
|
-
const c =
|
|
454
|
-
return
|
|
521
|
+
const c = he.has(s), r = d.context ? Ie() : Me(s, c);
|
|
522
|
+
return Ae(r, n, c), r;
|
|
455
523
|
}
|
|
456
524
|
});
|
|
457
525
|
}
|
|
458
|
-
function
|
|
526
|
+
function I(e) {
|
|
459
527
|
return e ?? void 0;
|
|
460
528
|
}
|
|
461
529
|
function m(e, t) {
|
|
@@ -498,69 +566,69 @@ function B(e) {
|
|
|
498
566
|
return typeof e != "string" ? !1 : [/^[0-9]{0,10000}\.?[0-9]{1,10000}(vmin|vmax|vh|vw|%|ch|ex|em|rem|in|cm|mm|pt|pc|px)$/, /^var\(--\D{1}.{0,100}\)$/, p].some((t) => t.test(e));
|
|
499
567
|
}
|
|
500
568
|
const {
|
|
501
|
-
sizeXxs:
|
|
502
|
-
sizeXs:
|
|
503
|
-
sizeSm:
|
|
504
|
-
sizeMd:
|
|
569
|
+
sizeXxs: ke,
|
|
570
|
+
sizeXs: Le,
|
|
571
|
+
sizeSm: We,
|
|
572
|
+
sizeMd: Be,
|
|
505
573
|
sizeLg: Re,
|
|
506
|
-
sizeXl:
|
|
507
|
-
sizeXxl:
|
|
508
|
-
sizeContent1:
|
|
509
|
-
sizeContent2:
|
|
510
|
-
sizeContent3:
|
|
511
|
-
sizeHeader1:
|
|
512
|
-
sizeHeader2:
|
|
513
|
-
sizeHeader3:
|
|
514
|
-
size000:
|
|
515
|
-
size00:
|
|
516
|
-
size1:
|
|
517
|
-
size2:
|
|
518
|
-
size3:
|
|
519
|
-
size4:
|
|
520
|
-
size5:
|
|
521
|
-
size6:
|
|
522
|
-
size7:
|
|
523
|
-
size8:
|
|
524
|
-
size9:
|
|
525
|
-
size10:
|
|
526
|
-
size11:
|
|
527
|
-
size12:
|
|
528
|
-
size13:
|
|
529
|
-
size14:
|
|
530
|
-
size15:
|
|
531
|
-
} = se,
|
|
532
|
-
size000:
|
|
533
|
-
size00:
|
|
534
|
-
size1:
|
|
535
|
-
size2:
|
|
536
|
-
size3:
|
|
537
|
-
size4:
|
|
538
|
-
size5:
|
|
539
|
-
size6:
|
|
540
|
-
size7:
|
|
541
|
-
size8:
|
|
542
|
-
size9:
|
|
543
|
-
size10:
|
|
544
|
-
size11:
|
|
545
|
-
size12:
|
|
546
|
-
size13:
|
|
547
|
-
size14:
|
|
548
|
-
size15:
|
|
549
|
-
},
|
|
550
|
-
sizeXxs:
|
|
551
|
-
sizeXs:
|
|
552
|
-
sizeSm:
|
|
553
|
-
sizeMd:
|
|
574
|
+
sizeXl: De,
|
|
575
|
+
sizeXxl: Ge,
|
|
576
|
+
sizeContent1: He,
|
|
577
|
+
sizeContent2: ve,
|
|
578
|
+
sizeContent3: _e,
|
|
579
|
+
sizeHeader1: Fe,
|
|
580
|
+
sizeHeader2: Ve,
|
|
581
|
+
sizeHeader3: Xe,
|
|
582
|
+
size000: Ue,
|
|
583
|
+
size00: qe,
|
|
584
|
+
size1: Qe,
|
|
585
|
+
size2: Ye,
|
|
586
|
+
size3: Je,
|
|
587
|
+
size4: Ze,
|
|
588
|
+
size5: Ke,
|
|
589
|
+
size6: pe,
|
|
590
|
+
size7: et,
|
|
591
|
+
size8: tt,
|
|
592
|
+
size9: nt,
|
|
593
|
+
size10: it,
|
|
594
|
+
size11: st,
|
|
595
|
+
size12: ot,
|
|
596
|
+
size13: ct,
|
|
597
|
+
size14: rt,
|
|
598
|
+
size15: lt
|
|
599
|
+
} = se, ft = {
|
|
600
|
+
size000: Ue,
|
|
601
|
+
size00: qe,
|
|
602
|
+
size1: Qe,
|
|
603
|
+
size2: Ye,
|
|
604
|
+
size3: Je,
|
|
605
|
+
size4: Ze,
|
|
606
|
+
size5: Ke,
|
|
607
|
+
size6: pe,
|
|
608
|
+
size7: et,
|
|
609
|
+
size8: tt,
|
|
610
|
+
size9: nt,
|
|
611
|
+
size10: it,
|
|
612
|
+
size11: st,
|
|
613
|
+
size12: ot,
|
|
614
|
+
size13: ct,
|
|
615
|
+
size14: rt,
|
|
616
|
+
size15: lt
|
|
617
|
+
}, at = {
|
|
618
|
+
sizeXxs: ke,
|
|
619
|
+
sizeXs: Le,
|
|
620
|
+
sizeSm: We,
|
|
621
|
+
sizeMd: Be,
|
|
554
622
|
sizeLg: Re,
|
|
555
|
-
sizeXl:
|
|
556
|
-
sizeXxl:
|
|
557
|
-
sizeContent1:
|
|
558
|
-
sizeContent2:
|
|
559
|
-
sizeContent3:
|
|
560
|
-
sizeHeader1:
|
|
561
|
-
sizeHeader2:
|
|
562
|
-
sizeHeader3:
|
|
563
|
-
},
|
|
623
|
+
sizeXl: De,
|
|
624
|
+
sizeXxl: Ge,
|
|
625
|
+
sizeContent1: He,
|
|
626
|
+
sizeContent2: ve,
|
|
627
|
+
sizeContent3: _e,
|
|
628
|
+
sizeHeader1: Fe,
|
|
629
|
+
sizeHeader2: Ve,
|
|
630
|
+
sizeHeader3: Xe
|
|
631
|
+
}, ut = ft, dt = at;
|
|
564
632
|
function te(e) {
|
|
565
633
|
return e.reduce((t, [n, i]) => ({
|
|
566
634
|
...t,
|
|
@@ -569,11 +637,11 @@ function te(e) {
|
|
|
569
637
|
}
|
|
570
638
|
function _(e, t) {
|
|
571
639
|
if (t !== void 0)
|
|
572
|
-
return typeof t == "number" && t >= 0 ? `${t}px` : typeof t == "string" && B(t) ? ee(t) ? `var(${t})` : t :
|
|
640
|
+
return typeof t == "number" && t >= 0 ? `${t}px` : typeof t == "string" && B(t) ? ee(t) ? `var(${t})` : t : I(b(e, t));
|
|
573
641
|
}
|
|
574
642
|
function b(e, t) {
|
|
575
|
-
const n = e.space ??
|
|
576
|
-
return
|
|
643
|
+
const n = e.space ?? ut, i = te(Object.entries(n).map(([s, c]) => [s, typeof c == "number" ? `${c}px` : c]));
|
|
644
|
+
return I(i[t]);
|
|
577
645
|
}
|
|
578
646
|
function P(e, t) {
|
|
579
647
|
if (t === void 0)
|
|
@@ -582,20 +650,20 @@ function P(e, t) {
|
|
|
582
650
|
return `${t}px`;
|
|
583
651
|
if (typeof t == "string" && B(t))
|
|
584
652
|
return ee(t) ? `var(${t})` : t;
|
|
585
|
-
const n = e.sizes ??
|
|
586
|
-
return
|
|
653
|
+
const n = e.sizes ?? dt, i = te(Object.entries(n).map(([s, c]) => [s, typeof c == "number" ? `${c}px` : c]));
|
|
654
|
+
return I(i[t]);
|
|
587
655
|
}
|
|
588
|
-
function
|
|
656
|
+
function yt(e) {
|
|
589
657
|
return e === void 0 ? "100%" : typeof e == "number" ? `${e}px` : e;
|
|
590
658
|
}
|
|
591
|
-
function
|
|
592
|
-
const t = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((o, [l, f]) => o + `${l}:${f};`, ""), n = () => `--maxWidth: ${
|
|
659
|
+
function Bt(e) {
|
|
660
|
+
const t = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((o, [l, f]) => o + `${l}:${f};`, ""), n = () => `--maxWidth: ${yt(e.maxWidth)};`, i = () => e.centerText ? "center-text" : "", s = () => e.centerChildren ? "center-children" : "", c = () => [i(), s()].filter(Boolean).join(" "), r = () => [t(), n()].join("; ");
|
|
593
661
|
return h(() => e.as ?? "div", y(m(e, ["as", "maxWidth", "centerText", "centerChildren"]), g({
|
|
594
662
|
style: r,
|
|
595
663
|
"data-bedrock-center": c
|
|
596
664
|
})));
|
|
597
665
|
}
|
|
598
|
-
const ne =
|
|
666
|
+
const ne = oe({});
|
|
599
667
|
function Rt(e) {
|
|
600
668
|
return E(ne.Provider, {
|
|
601
669
|
get value() {
|
|
@@ -608,25 +676,25 @@ function Rt(e) {
|
|
|
608
676
|
}
|
|
609
677
|
function x() {
|
|
610
678
|
try {
|
|
611
|
-
return
|
|
679
|
+
return ce(ne);
|
|
612
680
|
} catch {
|
|
613
681
|
return {};
|
|
614
682
|
}
|
|
615
683
|
}
|
|
616
|
-
function
|
|
684
|
+
function mt(e, t) {
|
|
617
685
|
return P(e, t);
|
|
618
686
|
}
|
|
619
|
-
function
|
|
620
|
-
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((o, [l, f]) => o + `${l}:${f};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"}`, s = () => `--minItemWidth: ${
|
|
687
|
+
function Dt(e) {
|
|
688
|
+
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((o, [l, f]) => o + `${l}:${f};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"}`, s = () => `--minItemWidth: ${mt(t, e.minItemWidth)}`, c = () => e.noStretchedColumns === !0 ? "no-stretched-columns" : "", r = () => [n(), i(), s()].join("; ");
|
|
621
689
|
return h(() => e.as ?? "div", y(m(e, ["as", "gutter", "minItemWidth", "noStretchedColumns"]), g({
|
|
622
690
|
style: r,
|
|
623
691
|
"data-bedrock-column-drop": c
|
|
624
692
|
})));
|
|
625
693
|
}
|
|
626
|
-
function
|
|
627
|
-
const [n, i] =
|
|
694
|
+
function Gt(e, t) {
|
|
695
|
+
const [n, i] = O(!1), [s, c] = O();
|
|
628
696
|
return X(() => (Q(), 0)), U(() => {
|
|
629
|
-
if (
|
|
697
|
+
if (I(s()) === void 0)
|
|
630
698
|
return 0;
|
|
631
699
|
t && t(s());
|
|
632
700
|
const r = Y(s(), (o) => {
|
|
@@ -641,23 +709,23 @@ function Ht(e, t) {
|
|
|
641
709
|
return q(r), 0;
|
|
642
710
|
}), [n, c];
|
|
643
711
|
}
|
|
644
|
-
function
|
|
712
|
+
function ht(e) {
|
|
645
713
|
return Array.isArray(e) && e.length === 2 && e.every(Number.isFinite) || typeof e == "string" && /^\d{1,1000} {0,1}\/ {0,1}\d{1,1000}$/.test(e);
|
|
646
714
|
}
|
|
647
|
-
function
|
|
715
|
+
function gt(e) {
|
|
648
716
|
return Array.isArray(e) ? e.join("/") : e;
|
|
649
717
|
}
|
|
650
|
-
function
|
|
651
|
-
return
|
|
718
|
+
function $t(e) {
|
|
719
|
+
return ht(e) ? gt(e) : void 0;
|
|
652
720
|
}
|
|
653
|
-
function
|
|
654
|
-
const t = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((r, [o, l]) => r + `${o}:${l};`, ""), n = () =>
|
|
721
|
+
function Ht(e) {
|
|
722
|
+
const t = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((r, [o, l]) => r + `${o}:${l};`, ""), n = () => $t(e.ratio), i = () => n() ? `--ratio: ${n()}` : "", s = () => typeof e.position == "string" ? `--position: ${e.position}` : "50%", c = () => [t(), i(), s()].join("; ");
|
|
655
723
|
return h(() => e.as ?? "div", y(m(e, ["as", "ratio", "position"]), g({
|
|
656
724
|
style: c,
|
|
657
725
|
"data-bedrock-frame": () => ""
|
|
658
726
|
})));
|
|
659
727
|
}
|
|
660
|
-
function
|
|
728
|
+
function bt(e) {
|
|
661
729
|
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((r, [o, l]) => r + `${o}:${l};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => `--minItemWidth: ${typeof e.minItemWidth == "string" ? e.minItemWidth : `${e.minItemWidth ?? 0}px`};`, c = () => [n(), i(), s()].join("; ");
|
|
662
730
|
return h(() => e.as ?? "div", y(m(e, ["as", "gutter", "minItemWidth"]), g({
|
|
663
731
|
style: c,
|
|
@@ -669,7 +737,7 @@ function ie(e) {
|
|
|
669
737
|
const t = String(e), n = parseFloat(t), [, i] = t.match(/[\d.\-+]*\s*(.*)/) ?? ["", ""];
|
|
670
738
|
return [n, i];
|
|
671
739
|
}
|
|
672
|
-
function
|
|
740
|
+
function R(e, t) {
|
|
673
741
|
if (!e)
|
|
674
742
|
return;
|
|
675
743
|
const n = t ?? document.body, i = (e ?? "px").trim().toLowerCase();
|
|
@@ -682,7 +750,7 @@ function D(e, t) {
|
|
|
682
750
|
return;
|
|
683
751
|
case "ch":
|
|
684
752
|
case "ex":
|
|
685
|
-
return
|
|
753
|
+
return xt(i, n);
|
|
686
754
|
case "em":
|
|
687
755
|
return L(n, "font-size");
|
|
688
756
|
case "rem":
|
|
@@ -705,7 +773,7 @@ function D(e, t) {
|
|
|
705
773
|
return;
|
|
706
774
|
if (!c)
|
|
707
775
|
return s;
|
|
708
|
-
const r =
|
|
776
|
+
const r = R(c, t);
|
|
709
777
|
return typeof r == "number" ? s * r : void 0;
|
|
710
778
|
}
|
|
711
779
|
}
|
|
@@ -714,62 +782,62 @@ function L(e, t) {
|
|
|
714
782
|
const [n, i] = ie(
|
|
715
783
|
getComputedStyle(e).getPropertyValue(t)
|
|
716
784
|
);
|
|
717
|
-
return n * (
|
|
785
|
+
return n * (R(i, e) ?? 1);
|
|
718
786
|
}
|
|
719
|
-
function
|
|
787
|
+
function xt(e, t) {
|
|
720
788
|
const n = document.createElement("div");
|
|
721
789
|
n.style.height = "128" + e, t.appendChild(n);
|
|
722
790
|
const i = L(n, "height") / 128;
|
|
723
791
|
return t.removeChild(n), i;
|
|
724
792
|
}
|
|
725
|
-
const
|
|
726
|
-
const [t, n] =
|
|
793
|
+
const St = /* @__PURE__ */ J("<div>"), M = 1, wt = typeof window == "object" && typeof document == "object" && document.nodeType === 9, jt = (e) => {
|
|
794
|
+
const [t, n] = O(1), [i, s] = O(), c = x();
|
|
727
795
|
return X(() => (Q(), 0)), U(() => {
|
|
728
|
-
const r =
|
|
796
|
+
const r = I(i());
|
|
729
797
|
if (r === void 0)
|
|
730
798
|
return;
|
|
731
799
|
const o = Y(r, ({
|
|
732
800
|
target: l
|
|
733
801
|
}) => {
|
|
734
802
|
n(1);
|
|
735
|
-
const f = e.gutter ? b(c, e.gutter) ?? "1px" : "1px", a =
|
|
736
|
-
return n(
|
|
803
|
+
const f = e.gutter ? b(c, e.gutter) ?? "1px" : "1px", a = wt ? R(f, l) : void 0, u = Math.max(a ?? M, M), [$] = Array.from(l.children), S = 1 + Math.min(l.scrollHeight, $.scrollHeight), z = Math.max(Math.ceil(S / u), M);
|
|
804
|
+
return n(z), 0;
|
|
737
805
|
});
|
|
738
806
|
return q(o), 0;
|
|
739
807
|
}), (() => {
|
|
740
|
-
const r =
|
|
741
|
-
return
|
|
808
|
+
const r = St();
|
|
809
|
+
return Ce(s, r), K(r, () => e.children), w((o) => Z(r, `grid-row: span ${t()};`, o)), r;
|
|
742
810
|
})();
|
|
743
|
-
},
|
|
744
|
-
const t =
|
|
811
|
+
}, vt = (e) => {
|
|
812
|
+
const t = re(() => e.children), i = [].concat(t()).filter(Boolean).map((s) => E(jt, {
|
|
745
813
|
get gutter() {
|
|
746
814
|
return e.gutter;
|
|
747
815
|
},
|
|
748
816
|
children: s
|
|
749
817
|
}));
|
|
750
|
-
return E(
|
|
818
|
+
return E(bt, y({
|
|
751
819
|
style: "grid-template-rows: 1px;"
|
|
752
820
|
}, e, {
|
|
753
821
|
children: i
|
|
754
822
|
}));
|
|
755
|
-
},
|
|
823
|
+
}, At = {
|
|
756
824
|
start: "justify:start",
|
|
757
825
|
end: "justify:end",
|
|
758
826
|
center: "justify:center"
|
|
759
|
-
},
|
|
827
|
+
}, Ct = {
|
|
760
828
|
start: "align:start",
|
|
761
829
|
end: "align:end",
|
|
762
830
|
center: "align:center",
|
|
763
831
|
stretch: "align:stretch"
|
|
764
832
|
};
|
|
765
|
-
function
|
|
766
|
-
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((l, [f, a]) => l + `${f}:${a};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => e.justify !== void 0 ?
|
|
833
|
+
function _t(e) {
|
|
834
|
+
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((l, [f, a]) => l + `${f}:${a};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => e.justify !== void 0 ? At[e.justify] : void 0, c = () => e.align !== void 0 ? Ct[e.align] : void 0, r = () => [n(), i()].join("; "), o = () => [s(), c()].filter(Boolean).join(" ");
|
|
767
835
|
return h(() => e.as ?? "div", y(m(e, ["as", "gutter", "justify", "align"]), g({
|
|
768
836
|
style: r,
|
|
769
837
|
"data-bedrock-inline-cluster": o
|
|
770
838
|
})));
|
|
771
839
|
}
|
|
772
|
-
const
|
|
840
|
+
const Et = {
|
|
773
841
|
start: "justify:start",
|
|
774
842
|
end: "justify:end",
|
|
775
843
|
center: "justify:center"
|
|
@@ -779,8 +847,8 @@ const Ot = {
|
|
|
779
847
|
center: "align:center",
|
|
780
848
|
stretch: "align:stretch"
|
|
781
849
|
};
|
|
782
|
-
function
|
|
783
|
-
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((u, [$, S]) => u + `${$}:${S};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => e.minItemWidth ? `--minItemWidth: ${typeof e.minItemWidth == "string" ? e.minItemWidth : `${e.minItemWidth}px`};` : void 0, c = () => e.switchAt ? `--switchAt: ${P(t, e.switchAt) ?? "0px"};` : "", r = () => e.justify !== void 0 ?
|
|
850
|
+
function Ft(e) {
|
|
851
|
+
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((u, [$, S]) => u + `${$}:${S};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => e.minItemWidth ? `--minItemWidth: ${typeof e.minItemWidth == "string" ? e.minItemWidth : `${e.minItemWidth}px`};` : void 0, c = () => e.switchAt ? `--switchAt: ${P(t, e.switchAt) ?? "0px"};` : "", r = () => e.justify !== void 0 ? Et[e.justify] : void 0, o = () => e.align !== void 0 ? It[e.align] : void 0, l = () => e.stretch ? `stretch:${e.stretch}` : void 0, f = () => [n(), i(), c(), s()].join("; "), a = () => [r(), o(), l()].filter(Boolean).join(" ");
|
|
784
852
|
return h(() => e.as ?? "div", y(m(e, ["as", "gutter", "justify", "align", "stretch", "switchAt"]), g({
|
|
785
853
|
style: f,
|
|
786
854
|
"data-bedrock-inline": a
|
|
@@ -795,7 +863,7 @@ const Tt = (e) => ({
|
|
|
795
863
|
inlineEnd: "padding-inline-end",
|
|
796
864
|
blockStart: "padding-block-start",
|
|
797
865
|
blockEnd: "padding-block-end"
|
|
798
|
-
})[e],
|
|
866
|
+
})[e], Ot = (e, t) => {
|
|
799
867
|
if (!t)
|
|
800
868
|
return "";
|
|
801
869
|
if (Array.isArray(t) && t.length > 4)
|
|
@@ -808,14 +876,14 @@ const Tt = (e) => ({
|
|
|
808
876
|
};
|
|
809
877
|
return Object.entries(n).reduce((i, [s, c]) => i + `${s}:${c};`, "");
|
|
810
878
|
};
|
|
811
|
-
function
|
|
812
|
-
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((c, [r, o]) => c + `${r}:${o};`, ""), i = () =>
|
|
879
|
+
function Vt(e) {
|
|
880
|
+
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((c, [r, o]) => c + `${r}:${o};`, ""), i = () => Ot(t, e.padding), s = () => [n(), i()].join("; ");
|
|
813
881
|
return h(() => e.as ?? "div", y(m(e, ["as", "padding"]), g({
|
|
814
882
|
style: s,
|
|
815
883
|
"data-bedrock-padbox": () => ""
|
|
816
884
|
})));
|
|
817
885
|
}
|
|
818
|
-
function
|
|
886
|
+
function Xt(e) {
|
|
819
887
|
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((r, [o, l]) => r + `${o}:${l};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => {
|
|
820
888
|
switch (e.snapType) {
|
|
821
889
|
case "none":
|
|
@@ -842,43 +910,43 @@ const F = {
|
|
|
842
910
|
"auto-start": "fraction:auto-start",
|
|
843
911
|
"auto-end": "fraction:auto-end"
|
|
844
912
|
};
|
|
845
|
-
function
|
|
913
|
+
function Ut(e) {
|
|
846
914
|
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((l, [f, a]) => l + `${f}:${a};`, ""), i = () => e.switchAt ? `--switchAt: ${P(t, e.switchAt) ?? "0px"};` : "", s = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, c = () => F[e.fraction ?? "1/2"] ?? F["1/2"], r = () => e.minItemWidth ? `--minItemWidth: ${typeof e.minItemWidth == "string" ? e.minItemWidth : `${e.minItemWidth}px`};` : void 0, o = () => [n(), s(), i(), r()].join("; ");
|
|
847
915
|
return h(() => e.as ?? "div", y(m(e, ["as", "gutter", "fraction"]), g({
|
|
848
916
|
style: o,
|
|
849
917
|
"data-bedrock-split": c
|
|
850
918
|
})));
|
|
851
919
|
}
|
|
852
|
-
function
|
|
920
|
+
function qt(e) {
|
|
853
921
|
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((c, [r, o]) => c + `${r}:${o};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => [n(), i()].join("; ");
|
|
854
922
|
return h(() => e.as ?? "div", y(m(e, ["as", "gutter"]), g({
|
|
855
923
|
style: s,
|
|
856
924
|
"data-bedrock-stack": () => ""
|
|
857
925
|
})));
|
|
858
926
|
}
|
|
859
|
-
const
|
|
927
|
+
const Pt = /* @__PURE__ */ J("<div data-bedrock-cover-centered>");
|
|
860
928
|
function zt(e) {
|
|
861
929
|
return typeof e == "number" ? `${e}px` : e && B(e) ? e : "100vh";
|
|
862
930
|
}
|
|
863
|
-
function
|
|
931
|
+
function Mt(e) {
|
|
864
932
|
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((o, [l, f]) => o + `${l}:${f};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => `--minHeight: ${zt(e.minHeight)};`, c = () => e.stretchContent === !0 ? "stretch-content" : "", r = () => [n(), i(), s()].join("; ");
|
|
865
933
|
return h(() => e.as ?? "div", y(m(e, ["as", "minHeight", "stretchContent"]), g({
|
|
866
934
|
style: r,
|
|
867
935
|
"data-bedrock-cover": c
|
|
868
936
|
})));
|
|
869
937
|
}
|
|
870
|
-
function
|
|
938
|
+
function Qt(e) {
|
|
871
939
|
const [t, n] = V(e, ["children", "top", "bottom"]);
|
|
872
|
-
return E(
|
|
940
|
+
return E(Mt, y(n, {
|
|
873
941
|
get children() {
|
|
874
|
-
return [
|
|
875
|
-
const i =
|
|
942
|
+
return [T(() => t.top), (() => {
|
|
943
|
+
const i = Pt();
|
|
876
944
|
return K(i, () => t.children), i;
|
|
877
|
-
})(),
|
|
945
|
+
})(), T(() => t.bottom)];
|
|
878
946
|
}
|
|
879
947
|
}));
|
|
880
948
|
}
|
|
881
|
-
function
|
|
949
|
+
function Yt(e) {
|
|
882
950
|
const t = x(), n = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((o, [l, f]) => o + `${l}:${f};`, ""), i = () => `--gutter: ${b(t, e.gutter ?? "size00") ?? "0px"};`, s = () => `--columns: ${e.columns && e.columns > 0 ? e.columns : 1};`, c = () => e.switchAt ? `--switchAt: ${P(t, e.switchAt) ?? "0px"};` : "", r = () => [n(), i(), s(), c()].join("; ");
|
|
883
951
|
return h(() => e.as ?? "div", y(m(e, ["as", "gutter", "columns", "switchAt"]), g({
|
|
884
952
|
style: r,
|
|
@@ -886,7 +954,7 @@ function Jt(e) {
|
|
|
886
954
|
})));
|
|
887
955
|
}
|
|
888
956
|
const Nt = (e) => typeof e == "number" ? e : 1;
|
|
889
|
-
function
|
|
957
|
+
function Jt(e) {
|
|
890
958
|
const t = () => typeof e.style == "string" ? e.style : Object.entries(e.style ?? {}).reduce((r, [o, l]) => r + `${o}:${l};`, ""), n = () => `--span: ${Nt(e.span)};`, i = () => e.offsetStart && e.offsetStart > 0 ? `--offsetStart: ${e.offsetStart};` : "", s = () => e.offsetEnd && e.offsetEnd > 0 ? `--offsetEnd: ${e.offsetEnd};` : "", c = () => [t(), n(), i(), s()].join("; ");
|
|
891
959
|
return h(() => e.as ?? "div", y(m(e, ["as", "span", "offsetStart", "offsetEnd"]), g({
|
|
892
960
|
style: c,
|
|
@@ -894,27 +962,27 @@ function Zt(e) {
|
|
|
894
962
|
})));
|
|
895
963
|
}
|
|
896
964
|
export {
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
965
|
+
Bt as Center,
|
|
966
|
+
Jt as Column,
|
|
967
|
+
Dt as ColumnDrop,
|
|
968
|
+
Yt as Columns,
|
|
969
|
+
Qt as Cover,
|
|
970
|
+
Ht as Frame,
|
|
971
|
+
bt as Grid,
|
|
972
|
+
Ft as Inline,
|
|
973
|
+
_t as InlineCluster,
|
|
974
|
+
vt as MasonryGrid,
|
|
975
|
+
Vt as PadBox,
|
|
976
|
+
Xt as Reel,
|
|
977
|
+
Ut as Split,
|
|
978
|
+
qt as Stack,
|
|
911
979
|
Rt as ThemeProvider,
|
|
912
980
|
B as checkIsCSSLength,
|
|
913
|
-
|
|
981
|
+
Gt as createContainerQuery,
|
|
914
982
|
_ as getSafeGutter,
|
|
915
983
|
P as getSizeValue,
|
|
916
984
|
b as getSpacingValue,
|
|
917
|
-
|
|
918
|
-
|
|
985
|
+
dt as sizes,
|
|
986
|
+
ut as spacing,
|
|
919
987
|
x as useTheme
|
|
920
988
|
};
|
package/lib/index.umd.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(u,A){typeof exports=="object"&&typeof module<"u"?A(exports,require("open-props"),require("solid-js"),require("@bedrock-layout/register-resize-callback")):typeof define=="function"&&define.amd?define(["exports","open-props","solid-js","@bedrock-layout/register-resize-callback"],A):(u=typeof globalThis<"u"?globalThis:u||self,A(u.solid={},u.OpenProps,u.solidJs,u.registerResizeCallback))})(this,function(u,A,f,T){"use strict";const p=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected"],J=new Set(["className","value","readOnly","formNoValidate","isMap","noModule","playsInline",...p]),ee=new Set(["innerHTML","textContent","innerText","children"]),te=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),ne=Object.assign(Object.create(null),{class:"className",formnovalidate:{$:"formNoValidate",BUTTON:1,INPUT:1},ismap:{$:"isMap",IMG:1},nomodule:{$:"noModule",SCRIPT:1},playsinline:{$:"playsInline",VIDEO:1},readonly:{$:"readOnly",INPUT:1,TEXTAREA:1}});function ie(e,t){const n=ne[e];return typeof n=="object"?n[t]?n.$:void 0:n}const re=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),ce=new Set(["altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","set","stop","svg","switch","symbol","text","textPath","tref","tspan","use","view","vkern"]),oe={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"};function se(e,t,n){let i=n.length,r=t.length,o=i,s=0,c=0,a=t[r-1].nextSibling,l=null;for(;s<r||c<o;){if(t[s]===n[c]){s++,c++;continue}for(;t[r-1]===n[o-1];)r--,o--;if(r===s){const d=o<i?c?n[c-1].nextSibling:n[o-c]:a;for(;c<o;)e.insertBefore(n[c++],d)}else if(o===c)for(;s<r;)(!l||!l.has(t[s]))&&t[s].remove(),s++;else if(t[s]===n[o-1]&&n[c]===t[r-1]){const d=t[--r].nextSibling;e.insertBefore(n[c++],t[s++].nextSibling),e.insertBefore(n[--o],d),t[r]=n[o]}else{if(!l){l=new Map;let m=c;for(;m<o;)l.set(n[m],m++)}const d=l.get(t[s]);if(d!=null)if(c<d&&d<o){let m=s,C=1,S;for(;++m<r&&m<o&&!((S=l.get(t[m]))==null||S!==d+C);)C++;if(C>d-c){const W=t[s];for(;c<d;)e.insertBefore(n[c++],W)}else e.replaceChild(n[c++],t[s++])}else s++;else t[s++].remove()}}}const R="_$DX_DELEGATE";function B(e,t,n){let i;const r=()=>{const s=document.createElement("template");return s.innerHTML=e,n?s.content.firstChild.firstChild:s.content.firstChild},o=t?()=>f.untrack(()=>document.importNode(i||(i=r()),!0)):()=>(i||(i=r())).cloneNode(!0);return o.cloneNode=o,o}function fe(e,t=window.document){const n=t[R]||(t[R]=new Set);for(let i=0,r=e.length;i<r;i++){const o=e[i];n.has(o)||(n.add(o),t.addEventListener(o,$e))}}function I(e,t,n){n==null?e.removeAttribute(t):e.setAttribute(t,n)}function ae(e,t,n,i){i==null?e.removeAttributeNS(t,n):e.setAttributeNS(t,n,i)}function le(e,t){t==null?e.removeAttribute("class"):e.className=t}function ue(e,t,n,i){if(i)Array.isArray(n)?(e[`$$${t}`]=n[0],e[`$$${t}Data`]=n[1]):e[`$$${t}`]=n;else if(Array.isArray(n)){const r=n[0];e.addEventListener(t,n[0]=o=>r.call(e,n[1],o))}else e.addEventListener(t,n)}function de(e,t,n={}){const i=Object.keys(t||{}),r=Object.keys(n);let o,s;for(o=0,s=r.length;o<s;o++){const c=r[o];!c||c==="undefined"||t[c]||(G(e,c,!1),delete n[c])}for(o=0,s=i.length;o<s;o++){const c=i[o],a=!!t[c];!c||c==="undefined"||n[c]===a||!a||(G(e,c,!0),n[c]=a)}return n}function D(e,t,n){if(!t)return n?I(e,"style"):t;const i=e.style;if(typeof t=="string")return i.cssText=t;typeof n=="string"&&(i.cssText=n=void 0),n||(n={}),t||(t={});let r,o;for(o in n)t[o]==null&&i.removeProperty(o),delete n[o];for(o in t)r=t[o],r!==n[o]&&(i.setProperty(o,r),n[o]=r);return n}function me(e,t={},n,i){const r={};return i||f.createRenderEffect(()=>r.children=w(e,t.children,r.children)),f.createRenderEffect(()=>t.ref&&t.ref(e)),f.createRenderEffect(()=>ge(e,t,n,!0,r,!0)),r}function ye(e,t,n){return f.untrack(()=>e(t,n))}function v(e,t,n,i){if(n!==void 0&&!i&&(i=[]),typeof t!="function")return w(e,t,i,n);f.createRenderEffect(r=>w(e,t(),r,n),i)}function ge(e,t,n,i,r={},o=!1){t||(t={});for(const s in r)if(!(s in t)){if(s==="children")continue;r[s]=H(e,s,null,r[s],n,o)}for(const s in t){if(s==="children"){i||w(e,t.children);continue}const c=t[s];r[s]=H(e,s,c,r[s],n,o)}}function he(e){let t,n;if(!f.sharedConfig.context||!(t=f.sharedConfig.registry.get(n=Ce()))){if(f.sharedConfig.context&&console.warn("Unable to find DOM nodes for hydration key:",n),!e)throw new Error("Unrecoverable Hydration Mismatch. No template for key: "+n);return e()}return f.sharedConfig.completed&&f.sharedConfig.completed.add(t),f.sharedConfig.registry.delete(n),t}function be(e){return e.toLowerCase().replace(/-([a-z])/g,(t,n)=>n.toUpperCase())}function G(e,t,n){const i=t.trim().split(/\s+/);for(let r=0,o=i.length;r<o;r++)e.classList.toggle(i[r],n)}function H(e,t,n,i,r,o){let s,c,a,l,d;if(t==="style")return D(e,n,i);if(t==="classList")return de(e,n,i);if(n===i)return i;if(t==="ref")o||n(e);else if(t.slice(0,3)==="on:"){const m=t.slice(3);i&&e.removeEventListener(m,i),n&&e.addEventListener(m,n)}else if(t.slice(0,10)==="oncapture:"){const m=t.slice(10);i&&e.removeEventListener(m,i,!0),n&&e.addEventListener(m,n,!0)}else if(t.slice(0,2)==="on"){const m=t.slice(2).toLowerCase(),C=re.has(m);if(!C&&i){const S=Array.isArray(i)?i[0]:i;e.removeEventListener(m,S)}(C||n)&&(ue(e,m,n,C),C&&fe([m]))}else if(t.slice(0,5)==="attr:")I(e,t.slice(5),n);else if((d=t.slice(0,5)==="prop:")||(a=ee.has(t))||!r&&((l=ie(t,e.tagName))||(c=J.has(t)))||(s=e.nodeName.includes("-")))d&&(t=t.slice(5),c=!0),t==="class"||t==="className"?le(e,n):s&&!c&&!a?e[be(t)]=n:e[l||t]=n;else{const m=r&&t.indexOf(":")>-1&&oe[t.split(":")[0]];m?ae(e,m,t,n):I(e,te[t]||t,n)}return n}function $e(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),f.sharedConfig.registry&&!f.sharedConfig.done&&(f.sharedConfig.done=_$HY.done=!0);n;){const i=n[t];if(i&&!n.disabled){const r=n[`${t}Data`];if(r!==void 0?i.call(n,r,e):i.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function w(e,t,n,i,r){if(f.sharedConfig.context){!n&&(n=[...e.childNodes]);let c=[];for(let a=0;a<n.length;a++){const l=n[a];l.nodeType===8&&l.data.slice(0,2)==="!$"?l.remove():c.push(l)}n=c}for(;typeof n=="function";)n=n();if(t===n)return n;const o=typeof t,s=i!==void 0;if(e=s&&n[0]&&n[0].parentNode||e,o==="string"||o==="number"){if(f.sharedConfig.context)return n;if(o==="number"&&(t=t.toString()),s){let c=n[0];c&&c.nodeType===3?c.data=t:c=document.createTextNode(t),n=j(e,n,i,c)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||o==="boolean"){if(f.sharedConfig.context)return n;n=j(e,n,i)}else{if(o==="function")return f.createRenderEffect(()=>{let c=t();for(;typeof c=="function";)c=c();n=w(e,c,n,i)}),()=>n;if(Array.isArray(t)){const c=[],a=n&&Array.isArray(n);if(O(c,t,n,r))return f.createRenderEffect(()=>n=w(e,c,n,i,!0)),()=>n;if(f.sharedConfig.context){if(!c.length)return n;for(let l=0;l<c.length;l++)if(c[l].parentNode)return n=c}if(c.length===0){if(n=j(e,n,i),s)return n}else a?n.length===0?V(e,c,i):se(e,n,c):(n&&j(e),V(e,c));n=c}else if(t.nodeType){if(f.sharedConfig.context&&t.parentNode)return n=s?[t]:t;if(Array.isArray(n)){if(s)return n=j(e,n,i,t);j(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}else console.warn("Unrecognized value. Skipped inserting",t)}return n}function O(e,t,n,i){let r=!1;for(let o=0,s=t.length;o<s;o++){let c=t[o],a=n&&n[o],l;if(!(c==null||c===!0||c===!1))if((l=typeof c)=="object"&&c.nodeType)e.push(c);else if(Array.isArray(c))r=O(e,c,a)||r;else if(l==="function")if(i){for(;typeof c=="function";)c=c();r=O(e,Array.isArray(c)?c:[c],Array.isArray(a)?a:[a])||r}else e.push(c),r=!0;else{const d=String(c);a&&a.nodeType===3&&a.data===d?e.push(a):e.push(document.createTextNode(d))}}return r}function V(e,t,n=null){for(let i=0,r=t.length;i<r;i++)e.insertBefore(t[i],n)}function j(e,t,n,i){if(n===void 0)return e.textContent="";const r=i||document.createTextNode("");if(t.length){let o=!1;for(let s=t.length-1;s>=0;s--){const c=t[s];if(r!==c){const a=c.parentNode===e;!o&&!s?a?e.replaceChild(r,c):e.insertBefore(r,n):a&&c.remove()}else o=!0}}else e.insertBefore(r,n);return[r]}function Ce(){const e=f.sharedConfig.context;return`${e.id}${e.count++}`}const Se="http://www.w3.org/2000/svg";function we(e,t=!1){return t?document.createElementNS(Se,e):document.createElement(e)}function je(e){const[t,n]=f.splitProps(e,["component"]),i=f.createMemo(()=>t.component);return f.createMemo(()=>{const r=i();switch(typeof r){case"function":return Object.assign(r,{[f.$DEVCOMP]:!0}),f.untrack(()=>r(n));case"string":const o=ce.has(r),s=f.sharedConfig.context?he():we(r,o);return me(s,n,o),s}})}function x(e){return e??void 0}function y(e,t){return Object.keys(e).filter(n=>!t.includes(n)).reduce((n,i)=>Object.defineProperty({...n},i,{get(){return e[i]},configurable:!0,enumerable:!0}),{})}function g(e,t){return f.createComponent(je,f.mergeProps({get component(){return e()}},t))}function h(e){return Object.values(e).every(t=>typeof t=="function")?Object.keys(e).reduce((t,n)=>{const i=e[n];return Object.defineProperty({...t},n,{get(){return i()},configurable:!0,enumerable:!0})},{}):new Error("Please provide an object with accessor values only.")}const _=/^--\D{1}.{0,100}$/;function F(e){return _.test(e)}function M(e){return typeof e!="string"?!1:[/^[0-9]{0,10000}\.?[0-9]{1,10000}(vmin|vmax|vh|vw|%|ch|ex|em|rem|in|cm|mm|pt|pc|px)$/,/^var\(--\D{1}.{0,100}\)$/,_].some(t=>t.test(e))}const{sizeXxs:Ae,sizeXs:xe,sizeSm:Pe,sizeMd:Ee,sizeLg:Te,sizeXl:Me,sizeXxl:Ie,sizeContent1:Oe,sizeContent2:ke,sizeContent3:ze,sizeHeader1:Ne,sizeHeader2:Le,sizeHeader3:We,size000:Re,size00:Be,size1:De,size2:ve,size3:Ge,size4:He,size5:Ve,size6:_e,size7:Fe,size8:Xe,size9:Ue,size10:qe,size11:Qe,size12:Ye,size13:Ze,size14:Ke,size15:pe}=A,Je={size000:Re,size00:Be,size1:De,size2:ve,size3:Ge,size4:He,size5:Ve,size6:_e,size7:Fe,size8:Xe,size9:Ue,size10:qe,size11:Qe,size12:Ye,size13:Ze,size14:Ke,size15:pe},et={sizeXxs:Ae,sizeXs:xe,sizeSm:Pe,sizeMd:Ee,sizeLg:Te,sizeXl:Me,sizeXxl:Ie,sizeContent1:Oe,sizeContent2:ke,sizeContent3:ze,sizeHeader1:Ne,sizeHeader2:Le,sizeHeader3:We},X=Je,U=et;function q(e){return e.reduce((t,[n,i])=>({...t,[n]:i}),{})}function k(e,t){if(t!==void 0)return typeof t=="number"&&t>=0?`${t}px`:typeof t=="string"&&M(t)?F(t)?`var(${t})`:t:x(b(e,t))}function b(e,t){const n=e.space??X,i=q(Object.entries(n).map(([r,o])=>[r,typeof o=="number"?`${o}px`:o]));return x(i[t])}function P(e,t){if(t===void 0)return;if(typeof t=="number"&&t>=0)return`${t}px`;if(typeof t=="string"&&M(t))return F(t)?`var(${t})`:t;const n=e.sizes??U,i=q(Object.entries(n).map(([r,o])=>[r,typeof o=="number"?`${o}px`:o]));return x(i[t])}function tt(e){return e===void 0?"100%":typeof e=="number"?`${e}px`:e}function nt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),n=()=>`--maxWidth: ${tt(e.maxWidth)};`,i=()=>e.centerText?"center-text":"",r=()=>e.centerChildren?"center-children":"",o=()=>[i(),r()].filter(Boolean).join(" "),s=()=>[t(),n()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","maxWidth","centerText","centerChildren"]),h({style:s,"data-bedrock-center":o})))}const Q=f.createContext({});function it(e){return f.createComponent(Q.Provider,{get value(){return e.theme},get children(){return e.children}})}function $(){try{return f.useContext(Q)}catch{return{}}}function rt(e,t){return P(e,t)}function ct(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"}`,r=()=>`--minItemWidth: ${rt(t,e.minItemWidth)}`,o=()=>e.noStretchedColumns===!0?"no-stretched-columns":"",s=()=>[n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","minItemWidth","noStretchedColumns"]),h({style:s,"data-bedrock-column-drop":o})))}function ot(e,t){const[n,i]=f.createSignal(!1),[r,o]=f.createSignal();return f.onMount(()=>(T.init(),0)),f.createEffect(()=>{if(x(r())===void 0)return 0;t&&t(r());const s=T.registerCallback(r(),c=>{var l;const a=((l=c.borderBoxSize)==null?void 0:l.inlineSize)??c.contentRect.width;if(a>0){const d=a<=e;i(d)}return 0});return f.onCleanup(s),0}),[n,o]}function st(e){return Array.isArray(e)&&e.length===2&&e.every(Number.isFinite)||typeof e=="string"&&/^\d{1,1000} {0,1}\/ {0,1}\d{1,1000}$/.test(e)}function ft(e){return Array.isArray(e)?e.join("/"):e}function at(e){return st(e)?ft(e):void 0}function lt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((s,[c,a])=>s+`${c}:${a};`,""),n=()=>at(e.ratio),i=()=>n()?`--ratio: ${n()}`:"",r=()=>typeof e.position=="string"?`--position: ${e.position}`:"50%",o=()=>[t(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","ratio","position"]),h({style:o,"data-bedrock-frame":()=>""})))}function Y(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((s,[c,a])=>s+`${c}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth??0}px`};`,o=()=>[n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","minItemWidth"]),h({style:o,"data-bedrock-grid":()=>""})))}const E=96;function Z(e){const t=String(e),n=parseFloat(t),[,i]=t.match(/[\d.\-+]*\s*(.*)/)??["",""];return[n,i]}function z(e,t){if(!e)return;const n=t??document.body,i=(e??"px").trim().toLowerCase();switch(i){case"vmin":case"vmax":case"vh":case"vw":case"%":return;case"ch":case"ex":return ut(i,n);case"em":return N(n,"font-size");case"rem":return N(document.body,"font-size");case"in":return E;case"cm":return E/2.54;case"mm":return E/25.4;case"pt":return E/72;case"pc":return E/6;case"px":return 1;default:{const[r,o]=Z(i);if(isNaN(r))return;if(!o)return r;const s=z(o,t);return typeof s=="number"?r*s:void 0}}}function N(e,t){const[n,i]=Z(getComputedStyle(e).getPropertyValue(t));return n*(z(i,e)??1)}function ut(e,t){const n=document.createElement("div");n.style.height="128"+e,t.appendChild(n);const i=N(n,"height")/128;return t.removeChild(n),i}const dt=B("<div>"),L=1,mt=typeof window=="object"&&typeof document=="object"&&document.nodeType===9,yt=e=>{const[t,n]=f.createSignal(1),[i,r]=f.createSignal(),o=$();return f.onMount(()=>(T.init(),0)),f.createEffect(()=>{const s=x(i());if(s===void 0)return;const c=T.registerCallback(s,({target:a})=>{n(1);const l=e.gutter?b(o,e.gutter)??"1px":"1px",d=mt?z(l,a):void 0,m=Math.max(d??L,L),[C]=Array.from(a.children),S=1+Math.min(a.scrollHeight,C.scrollHeight),W=Math.max(Math.ceil(S/m),L);return n(W),0});return f.onCleanup(c),0}),(()=>{const s=dt();return ye(r,s),v(s,()=>e.children),f.createRenderEffect(c=>D(s,`grid-row: span ${t()};`,c)),s})()},gt=e=>{const t=f.children(()=>e.children),i=[].concat(t()).filter(Boolean).map(r=>f.createComponent(yt,{get gutter(){return e.gutter},children:r}));return f.createComponent(Y,f.mergeProps({style:"grid-template-rows: 1px;"},e,{children:i}))},ht={start:"justify:start",end:"justify:end",center:"justify:center"},bt={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function $t(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((a,[l,d])=>a+`${l}:${d};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>e.justify!==void 0?ht[e.justify]:void 0,o=()=>e.align!==void 0?bt[e.align]:void 0,s=()=>[n(),i()].join("; "),c=()=>[r(),o()].filter(Boolean).join(" ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","justify","align"]),h({style:s,"data-bedrock-inline-cluster":c})))}const Ct={start:"justify:start",end:"justify:end",center:"justify:center"},St={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function wt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((m,[C,S])=>m+`${C}:${S};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,o=()=>e.switchAt?`--switchAt: ${P(t,e.switchAt)??"0px"};`:"",s=()=>e.justify!==void 0?Ct[e.justify]:void 0,c=()=>e.align!==void 0?St[e.align]:void 0,a=()=>e.stretch?`stretch:${e.stretch}`:void 0,l=()=>[n(),i(),o(),r()].join("; "),d=()=>[s(),c(),a()].filter(Boolean).join(" ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","justify","align","stretch","switchAt"]),h({style:l,"data-bedrock-inline":d})))}const jt=e=>({left:"padding-inline-start",right:"padding-inline-end",top:"padding-block-start",bottom:"padding-block-end",inlineStart:"padding-inline-start",inlineEnd:"padding-inline-end",blockStart:"padding-block-start",blockEnd:"padding-block-end"})[e],At=(e,t)=>{if(!t)return"";if(Array.isArray(t)&&t.length>4)throw new Error("padding arrays can only be 4 or less in length");const n=typeof t=="object"&&!Array.isArray(t)?Object.entries(t).reduce((i,[r,o])=>({...i,[jt(r)]:k(e,o)??"0px"}),{}):{padding:Array.from(Array.isArray(t)?t:[t]).map(i=>k(e,i)??"0px").join(" ")};return Object.entries(n).reduce((i,[r,o])=>i+`${r}:${o};`,"")};function xt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[s,c])=>o+`${s}:${c};`,""),i=()=>At(t,e.padding),r=()=>[n(),i()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","padding"]),h({style:r,"data-bedrock-padbox":()=>""})))}function Pt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((s,[c,a])=>s+`${c}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>{switch(e.snapType){case"none":return"snapType:none";case"proximity":return"snapType:proximity";case"mandatory":return"snapType:mandatory";default:return"snapType:none"}},o=()=>[n(),i()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter"]),h({style:o,"data-bedrock-reel":r})))}const K={"1/4":"fraction:1/4","1/3":"fraction:1/3","1/2":"fraction:1/2","2/3":"fraction:2/3","3/4":"fraction:3/4","auto-start":"fraction:auto-start","auto-end":"fraction:auto-end"};function Et(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((a,[l,d])=>a+`${l}:${d};`,""),i=()=>e.switchAt?`--switchAt: ${P(t,e.switchAt)??"0px"};`:"",r=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,o=()=>K[e.fraction??"1/2"]??K["1/2"],s=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,c=()=>[n(),r(),i(),s()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","fraction"]),h({style:c,"data-bedrock-split":o})))}function Tt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[s,c])=>o+`${s}:${c};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>[n(),i()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter"]),h({style:r,"data-bedrock-stack":()=>""})))}const Mt=B("<div data-bedrock-cover-centered>");function It(e){return typeof e=="number"?`${e}px`:e&&M(e)?e:"100vh"}function Ot(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>`--minHeight: ${It(e.minHeight)};`,o=()=>e.stretchContent===!0?"stretch-content":"",s=()=>[n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","minHeight","stretchContent"]),h({style:s,"data-bedrock-cover":o})))}function kt(e){const[t,n]=f.splitProps(e,["children","top","bottom"]);return f.createComponent(Ot,f.mergeProps(n,{get children(){return[f.createMemo(()=>t.top),(()=>{const i=Mt();return v(i,()=>t.children),i})(),f.createMemo(()=>t.bottom)]}}))}function zt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>`--columns: ${e.columns&&e.columns>0?e.columns:1};`,o=()=>e.switchAt?`--switchAt: ${P(t,e.switchAt)??"0px"};`:"",s=()=>[n(),i(),r(),o()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","columns","switchAt"]),h({style:s,"data-bedrock-columns":()=>""})))}const Nt=e=>typeof e=="number"?e:1;function Lt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((s,[c,a])=>s+`${c}:${a};`,""),n=()=>`--span: ${Nt(e.span)};`,i=()=>e.offsetStart&&e.offsetStart>0?`--offsetStart: ${e.offsetStart};`:"",r=()=>e.offsetEnd&&e.offsetEnd>0?`--offsetEnd: ${e.offsetEnd};`:"",o=()=>[t(),n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","span","offsetStart","offsetEnd"]),h({style:o,"data-bedrock-column":()=>""})))}u.Center=nt,u.Column=Lt,u.ColumnDrop=ct,u.Columns=zt,u.Cover=kt,u.Frame=lt,u.Grid=Y,u.Inline=wt,u.InlineCluster=$t,u.MasonryGrid=gt,u.PadBox=xt,u.Reel=Pt,u.Split=Et,u.Stack=Tt,u.ThemeProvider=it,u.checkIsCSSLength=M,u.createContainerQuery=ot,u.getSafeGutter=k,u.getSizeValue=P,u.getSpacingValue=b,u.sizes=U,u.spacing=X,u.useTheme=$,Object.defineProperty(u,Symbol.toStringTag,{value:"Module"})});
|
|
1
|
+
(function(u,x){typeof exports=="object"&&typeof module<"u"?x(exports,require("open-props"),require("solid-js"),require("@bedrock-layout/register-resize-callback")):typeof define=="function"&&define.amd?define(["exports","open-props","solid-js","@bedrock-layout/register-resize-callback"],x):(u=typeof globalThis<"u"?globalThis:u||self,x(u.solid={},u.OpenProps,u.solidJs,u.registerResizeCallback))})(this,function(u,x,f,T){"use strict";const p=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected"],J=new Set(["className","value","readOnly","formNoValidate","isMap","noModule","playsInline",...p]),ee=new Set(["innerHTML","textContent","innerText","children"]),te=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),ne=Object.assign(Object.create(null),{class:"className",formnovalidate:{$:"formNoValidate",BUTTON:1,INPUT:1},ismap:{$:"isMap",IMG:1},nomodule:{$:"noModule",SCRIPT:1},playsinline:{$:"playsInline",VIDEO:1},readonly:{$:"readOnly",INPUT:1,TEXTAREA:1}});function ie(e,t){const n=ne[e];return typeof n=="object"?n[t]?n.$:void 0:n}const re=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),ce=new Set(["altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","set","stop","svg","switch","symbol","text","textPath","tref","tspan","use","view","vkern"]),se={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"};function oe(e,t,n){let i=n.length,r=t.length,s=i,o=0,c=0,a=t[r-1].nextSibling,l=null;for(;o<r||c<s;){if(t[o]===n[c]){o++,c++;continue}for(;t[r-1]===n[s-1];)r--,s--;if(r===o){const d=s<i?c?n[c-1].nextSibling:n[s-c]:a;for(;c<s;)e.insertBefore(n[c++],d)}else if(s===c)for(;o<r;)(!l||!l.has(t[o]))&&t[o].remove(),o++;else if(t[o]===n[s-1]&&n[c]===t[r-1]){const d=t[--r].nextSibling;e.insertBefore(n[c++],t[o++].nextSibling),e.insertBefore(n[--s],d),t[r]=n[s]}else{if(!l){l=new Map;let m=c;for(;m<s;)l.set(n[m],m++)}const d=l.get(t[o]);if(d!=null)if(c<d&&d<s){let m=o,C=1,S;for(;++m<r&&m<s&&!((S=l.get(t[m]))==null||S!==d+C);)C++;if(C>d-c){const W=t[o];for(;c<d;)e.insertBefore(n[c++],W)}else e.replaceChild(n[c++],t[o++])}else o++;else t[o++].remove()}}}const R="_$DX_DELEGATE";function B(e,t,n){let i;const r=()=>{const o=document.createElement("template");return o.innerHTML=e,n?o.content.firstChild.firstChild:o.content.firstChild},s=t?()=>f.untrack(()=>document.importNode(i||(i=r()),!0)):()=>(i||(i=r())).cloneNode(!0);return s.cloneNode=s,s}function fe(e,t=window.document){const n=t[R]||(t[R]=new Set);for(let i=0,r=e.length;i<r;i++){const s=e[i];n.has(s)||(n.add(s),t.addEventListener(s,$e))}}function M(e,t,n){f.sharedConfig.context||(n==null?e.removeAttribute(t):e.setAttribute(t,n))}function ae(e,t,n,i){f.sharedConfig.context||(i==null?e.removeAttributeNS(t,n):e.setAttributeNS(t,n,i))}function le(e,t){f.sharedConfig.context||(t==null?e.removeAttribute("class"):e.className=t)}function ue(e,t,n,i){if(i)Array.isArray(n)?(e[`$$${t}`]=n[0],e[`$$${t}Data`]=n[1]):e[`$$${t}`]=n;else if(Array.isArray(n)){const r=n[0];e.addEventListener(t,n[0]=s=>r.call(e,n[1],s))}else e.addEventListener(t,n)}function de(e,t,n={}){const i=Object.keys(t||{}),r=Object.keys(n);let s,o;for(s=0,o=r.length;s<o;s++){const c=r[s];!c||c==="undefined"||t[c]||(v(e,c,!1),delete n[c])}for(s=0,o=i.length;s<o;s++){const c=i[s],a=!!t[c];!c||c==="undefined"||n[c]===a||!a||(v(e,c,!0),n[c]=a)}return n}function D(e,t,n){if(!t)return n?M(e,"style"):t;const i=e.style;if(typeof t=="string")return i.cssText=t;typeof n=="string"&&(i.cssText=n=void 0),n||(n={}),t||(t={});let r,s;for(s in n)t[s]==null&&i.removeProperty(s),delete n[s];for(s in t)r=t[s],r!==n[s]&&(i.setProperty(s,r),n[s]=r);return n}function me(e,t={},n,i){const r={};return i||f.createRenderEffect(()=>r.children=j(e,t.children,r.children)),f.createRenderEffect(()=>t.ref&&t.ref(e)),f.createRenderEffect(()=>ge(e,t,n,!0,r,!0)),r}function ye(e,t,n){return f.untrack(()=>e(t,n))}function G(e,t,n,i){if(n!==void 0&&!i&&(i=[]),typeof t!="function")return j(e,t,i,n);f.createRenderEffect(r=>j(e,t(),r,n),i)}function ge(e,t,n,i,r={},s=!1){t||(t={});for(const o in r)if(!(o in t)){if(o==="children")continue;r[o]=H(e,o,null,r[o],n,s)}for(const o in t){if(o==="children"){i||j(e,t.children);continue}const c=t[o];r[o]=H(e,o,c,r[o],n,s)}}function he(e){let t,n;return!f.sharedConfig.context||!(t=f.sharedConfig.registry.get(n=Ce()))?e():(f.sharedConfig.completed&&f.sharedConfig.completed.add(t),f.sharedConfig.registry.delete(n),t)}function be(e){return e.toLowerCase().replace(/-([a-z])/g,(t,n)=>n.toUpperCase())}function v(e,t,n){const i=t.trim().split(/\s+/);for(let r=0,s=i.length;r<s;r++)e.classList.toggle(i[r],n)}function H(e,t,n,i,r,s){let o,c,a,l,d;if(t==="style")return D(e,n,i);if(t==="classList")return de(e,n,i);if(n===i)return i;if(t==="ref")s||n(e);else if(t.slice(0,3)==="on:"){const m=t.slice(3);i&&e.removeEventListener(m,i),n&&e.addEventListener(m,n)}else if(t.slice(0,10)==="oncapture:"){const m=t.slice(10);i&&e.removeEventListener(m,i,!0),n&&e.addEventListener(m,n,!0)}else if(t.slice(0,2)==="on"){const m=t.slice(2).toLowerCase(),C=re.has(m);if(!C&&i){const S=Array.isArray(i)?i[0]:i;e.removeEventListener(m,S)}(C||n)&&(ue(e,m,n,C),C&&fe([m]))}else if(t.slice(0,5)==="attr:")M(e,t.slice(5),n);else if((d=t.slice(0,5)==="prop:")||(a=ee.has(t))||!r&&((l=ie(t,e.tagName))||(c=J.has(t)))||(o=e.nodeName.includes("-"))){if(d)t=t.slice(5),c=!0;else if(f.sharedConfig.context)return n;t==="class"||t==="className"?le(e,n):o&&!c&&!a?e[be(t)]=n:e[l||t]=n}else{const m=r&&t.indexOf(":")>-1&&se[t.split(":")[0]];m?ae(e,m,t,n):M(e,te[t]||t,n)}return n}function $e(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),f.sharedConfig.registry&&!f.sharedConfig.done&&(f.sharedConfig.done=_$HY.done=!0);n;){const i=n[t];if(i&&!n.disabled){const r=n[`${t}Data`];if(r!==void 0?i.call(n,r,e):i.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function j(e,t,n,i,r){if(f.sharedConfig.context){!n&&(n=[...e.childNodes]);let c=[];for(let a=0;a<n.length;a++){const l=n[a];l.nodeType===8&&l.data.slice(0,2)==="!$"?l.remove():c.push(l)}n=c}for(;typeof n=="function";)n=n();if(t===n)return n;const s=typeof t,o=i!==void 0;if(e=o&&n[0]&&n[0].parentNode||e,s==="string"||s==="number"){if(f.sharedConfig.context)return n;if(s==="number"&&(t=t.toString()),o){let c=n[0];c&&c.nodeType===3?c.data=t:c=document.createTextNode(t),n=w(e,n,i,c)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||s==="boolean"){if(f.sharedConfig.context)return n;n=w(e,n,i)}else{if(s==="function")return f.createRenderEffect(()=>{let c=t();for(;typeof c=="function";)c=c();n=j(e,c,n,i)}),()=>n;if(Array.isArray(t)){const c=[],a=n&&Array.isArray(n);if(O(c,t,n,r))return f.createRenderEffect(()=>n=j(e,c,n,i,!0)),()=>n;if(f.sharedConfig.context){if(!c.length)return n;if(i===void 0)return[...e.childNodes];let l=c[0],d=[l];for(;(l=l.nextSibling)!==i;)d.push(l);return n=d}if(c.length===0){if(n=w(e,n,i),o)return n}else a?n.length===0?_(e,c,i):oe(e,n,c):(n&&w(e),_(e,c));n=c}else if(t.nodeType){if(f.sharedConfig.context&&t.parentNode)return n=o?[t]:t;if(Array.isArray(n)){if(o)return n=w(e,n,i,t);w(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}}return n}function O(e,t,n,i){let r=!1;for(let s=0,o=t.length;s<o;s++){let c=t[s],a=n&&n[s],l;if(!(c==null||c===!0||c===!1))if((l=typeof c)=="object"&&c.nodeType)e.push(c);else if(Array.isArray(c))r=O(e,c,a)||r;else if(l==="function")if(i){for(;typeof c=="function";)c=c();r=O(e,Array.isArray(c)?c:[c],Array.isArray(a)?a:[a])||r}else e.push(c),r=!0;else{const d=String(c);a&&a.nodeType===3&&a.data===d?e.push(a):e.push(document.createTextNode(d))}}return r}function _(e,t,n=null){for(let i=0,r=t.length;i<r;i++)e.insertBefore(t[i],n)}function w(e,t,n,i){if(n===void 0)return e.textContent="";const r=i||document.createTextNode("");if(t.length){let s=!1;for(let o=t.length-1;o>=0;o--){const c=t[o];if(r!==c){const a=c.parentNode===e;!s&&!o?a?e.replaceChild(r,c):e.insertBefore(r,n):a&&c.remove()}else s=!0}}else e.insertBefore(r,n);return[r]}function Ce(){const e=f.sharedConfig.context;return`${e.id}${e.count++}`}const Se="http://www.w3.org/2000/svg";function je(e,t=!1){return t?document.createElementNS(Se,e):document.createElement(e)}function we(e){const[t,n]=f.splitProps(e,["component"]),i=f.createMemo(()=>t.component);return f.createMemo(()=>{const r=i();switch(typeof r){case"function":return f.untrack(()=>r(n));case"string":const s=ce.has(r),o=f.sharedConfig.context?he():je(r,s);return me(o,n,s),o}})}function A(e){return e??void 0}function y(e,t){return Object.keys(e).filter(n=>!t.includes(n)).reduce((n,i)=>Object.defineProperty({...n},i,{get(){return e[i]},configurable:!0,enumerable:!0}),{})}function g(e,t){return f.createComponent(we,f.mergeProps({get component(){return e()}},t))}function h(e){return Object.values(e).every(t=>typeof t=="function")?Object.keys(e).reduce((t,n)=>{const i=e[n];return Object.defineProperty({...t},n,{get(){return i()},configurable:!0,enumerable:!0})},{}):new Error("Please provide an object with accessor values only.")}const F=/^--\D{1}.{0,100}$/;function V(e){return F.test(e)}function I(e){return typeof e!="string"?!1:[/^[0-9]{0,10000}\.?[0-9]{1,10000}(vmin|vmax|vh|vw|%|ch|ex|em|rem|in|cm|mm|pt|pc|px)$/,/^var\(--\D{1}.{0,100}\)$/,F].some(t=>t.test(e))}const{sizeXxs:xe,sizeXs:Ae,sizeSm:Pe,sizeMd:Ee,sizeLg:Te,sizeXl:Ie,sizeXxl:Me,sizeContent1:Oe,sizeContent2:ze,sizeContent3:ke,sizeHeader1:Ne,sizeHeader2:Le,sizeHeader3:We,size000:Re,size00:Be,size1:De,size2:Ge,size3:ve,size4:He,size5:_e,size6:Fe,size7:Ve,size8:Xe,size9:qe,size10:Ue,size11:Qe,size12:Ye,size13:Ze,size14:Ke,size15:pe}=x,Je={size000:Re,size00:Be,size1:De,size2:Ge,size3:ve,size4:He,size5:_e,size6:Fe,size7:Ve,size8:Xe,size9:qe,size10:Ue,size11:Qe,size12:Ye,size13:Ze,size14:Ke,size15:pe},et={sizeXxs:xe,sizeXs:Ae,sizeSm:Pe,sizeMd:Ee,sizeLg:Te,sizeXl:Ie,sizeXxl:Me,sizeContent1:Oe,sizeContent2:ze,sizeContent3:ke,sizeHeader1:Ne,sizeHeader2:Le,sizeHeader3:We},X=Je,q=et;function U(e){return e.reduce((t,[n,i])=>({...t,[n]:i}),{})}function z(e,t){if(t!==void 0)return typeof t=="number"&&t>=0?`${t}px`:typeof t=="string"&&I(t)?V(t)?`var(${t})`:t:A(b(e,t))}function b(e,t){const n=e.space??X,i=U(Object.entries(n).map(([r,s])=>[r,typeof s=="number"?`${s}px`:s]));return A(i[t])}function P(e,t){if(t===void 0)return;if(typeof t=="number"&&t>=0)return`${t}px`;if(typeof t=="string"&&I(t))return V(t)?`var(${t})`:t;const n=e.sizes??q,i=U(Object.entries(n).map(([r,s])=>[r,typeof s=="number"?`${s}px`:s]));return A(i[t])}function tt(e){return e===void 0?"100%":typeof e=="number"?`${e}px`:e}function nt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),n=()=>`--maxWidth: ${tt(e.maxWidth)};`,i=()=>e.centerText?"center-text":"",r=()=>e.centerChildren?"center-children":"",s=()=>[i(),r()].filter(Boolean).join(" "),o=()=>[t(),n()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","maxWidth","centerText","centerChildren"]),h({style:o,"data-bedrock-center":s})))}const Q=f.createContext({});function it(e){return f.createComponent(Q.Provider,{get value(){return e.theme},get children(){return e.children}})}function $(){try{return f.useContext(Q)}catch{return{}}}function rt(e,t){return P(e,t)}function ct(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"}`,r=()=>`--minItemWidth: ${rt(t,e.minItemWidth)}`,s=()=>e.noStretchedColumns===!0?"no-stretched-columns":"",o=()=>[n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","minItemWidth","noStretchedColumns"]),h({style:o,"data-bedrock-column-drop":s})))}function st(e,t){const[n,i]=f.createSignal(!1),[r,s]=f.createSignal();return f.onMount(()=>(T.init(),0)),f.createEffect(()=>{if(A(r())===void 0)return 0;t&&t(r());const o=T.registerCallback(r(),c=>{var l;const a=((l=c.borderBoxSize)==null?void 0:l.inlineSize)??c.contentRect.width;if(a>0){const d=a<=e;i(d)}return 0});return f.onCleanup(o),0}),[n,s]}function ot(e){return Array.isArray(e)&&e.length===2&&e.every(Number.isFinite)||typeof e=="string"&&/^\d{1,1000} {0,1}\/ {0,1}\d{1,1000}$/.test(e)}function ft(e){return Array.isArray(e)?e.join("/"):e}function at(e){return ot(e)?ft(e):void 0}function lt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,a])=>o+`${c}:${a};`,""),n=()=>at(e.ratio),i=()=>n()?`--ratio: ${n()}`:"",r=()=>typeof e.position=="string"?`--position: ${e.position}`:"50%",s=()=>[t(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","ratio","position"]),h({style:s,"data-bedrock-frame":()=>""})))}function Y(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,a])=>o+`${c}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth??0}px`};`,s=()=>[n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","minItemWidth"]),h({style:s,"data-bedrock-grid":()=>""})))}const E=96;function Z(e){const t=String(e),n=parseFloat(t),[,i]=t.match(/[\d.\-+]*\s*(.*)/)??["",""];return[n,i]}function k(e,t){if(!e)return;const n=t??document.body,i=(e??"px").trim().toLowerCase();switch(i){case"vmin":case"vmax":case"vh":case"vw":case"%":return;case"ch":case"ex":return ut(i,n);case"em":return N(n,"font-size");case"rem":return N(document.body,"font-size");case"in":return E;case"cm":return E/2.54;case"mm":return E/25.4;case"pt":return E/72;case"pc":return E/6;case"px":return 1;default:{const[r,s]=Z(i);if(isNaN(r))return;if(!s)return r;const o=k(s,t);return typeof o=="number"?r*o:void 0}}}function N(e,t){const[n,i]=Z(getComputedStyle(e).getPropertyValue(t));return n*(k(i,e)??1)}function ut(e,t){const n=document.createElement("div");n.style.height="128"+e,t.appendChild(n);const i=N(n,"height")/128;return t.removeChild(n),i}const dt=B("<div>"),L=1,mt=typeof window=="object"&&typeof document=="object"&&document.nodeType===9,yt=e=>{const[t,n]=f.createSignal(1),[i,r]=f.createSignal(),s=$();return f.onMount(()=>(T.init(),0)),f.createEffect(()=>{const o=A(i());if(o===void 0)return;const c=T.registerCallback(o,({target:a})=>{n(1);const l=e.gutter?b(s,e.gutter)??"1px":"1px",d=mt?k(l,a):void 0,m=Math.max(d??L,L),[C]=Array.from(a.children),S=1+Math.min(a.scrollHeight,C.scrollHeight),W=Math.max(Math.ceil(S/m),L);return n(W),0});return f.onCleanup(c),0}),(()=>{const o=dt();return ye(r,o),G(o,()=>e.children),f.createRenderEffect(c=>D(o,`grid-row: span ${t()};`,c)),o})()},gt=e=>{const t=f.children(()=>e.children),i=[].concat(t()).filter(Boolean).map(r=>f.createComponent(yt,{get gutter(){return e.gutter},children:r}));return f.createComponent(Y,f.mergeProps({style:"grid-template-rows: 1px;"},e,{children:i}))},ht={start:"justify:start",end:"justify:end",center:"justify:center"},bt={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function $t(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((a,[l,d])=>a+`${l}:${d};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>e.justify!==void 0?ht[e.justify]:void 0,s=()=>e.align!==void 0?bt[e.align]:void 0,o=()=>[n(),i()].join("; "),c=()=>[r(),s()].filter(Boolean).join(" ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","justify","align"]),h({style:o,"data-bedrock-inline-cluster":c})))}const Ct={start:"justify:start",end:"justify:end",center:"justify:center"},St={start:"align:start",end:"align:end",center:"align:center",stretch:"align:stretch"};function jt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((m,[C,S])=>m+`${C}:${S};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,s=()=>e.switchAt?`--switchAt: ${P(t,e.switchAt)??"0px"};`:"",o=()=>e.justify!==void 0?Ct[e.justify]:void 0,c=()=>e.align!==void 0?St[e.align]:void 0,a=()=>e.stretch?`stretch:${e.stretch}`:void 0,l=()=>[n(),i(),s(),r()].join("; "),d=()=>[o(),c(),a()].filter(Boolean).join(" ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","justify","align","stretch","switchAt"]),h({style:l,"data-bedrock-inline":d})))}const wt=e=>({left:"padding-inline-start",right:"padding-inline-end",top:"padding-block-start",bottom:"padding-block-end",inlineStart:"padding-inline-start",inlineEnd:"padding-inline-end",blockStart:"padding-block-start",blockEnd:"padding-block-end"})[e],xt=(e,t)=>{if(!t)return"";if(Array.isArray(t)&&t.length>4)throw new Error("padding arrays can only be 4 or less in length");const n=typeof t=="object"&&!Array.isArray(t)?Object.entries(t).reduce((i,[r,s])=>({...i,[wt(r)]:z(e,s)??"0px"}),{}):{padding:Array.from(Array.isArray(t)?t:[t]).map(i=>z(e,i)??"0px").join(" ")};return Object.entries(n).reduce((i,[r,s])=>i+`${r}:${s};`,"")};function At(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((s,[o,c])=>s+`${o}:${c};`,""),i=()=>xt(t,e.padding),r=()=>[n(),i()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","padding"]),h({style:r,"data-bedrock-padbox":()=>""})))}function Pt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,a])=>o+`${c}:${a};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>{switch(e.snapType){case"none":return"snapType:none";case"proximity":return"snapType:proximity";case"mandatory":return"snapType:mandatory";default:return"snapType:none"}},s=()=>[n(),i()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter"]),h({style:s,"data-bedrock-reel":r})))}const K={"1/4":"fraction:1/4","1/3":"fraction:1/3","1/2":"fraction:1/2","2/3":"fraction:2/3","3/4":"fraction:3/4","auto-start":"fraction:auto-start","auto-end":"fraction:auto-end"};function Et(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((a,[l,d])=>a+`${l}:${d};`,""),i=()=>e.switchAt?`--switchAt: ${P(t,e.switchAt)??"0px"};`:"",r=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,s=()=>K[e.fraction??"1/2"]??K["1/2"],o=()=>e.minItemWidth?`--minItemWidth: ${typeof e.minItemWidth=="string"?e.minItemWidth:`${e.minItemWidth}px`};`:void 0,c=()=>[n(),r(),i(),o()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","fraction"]),h({style:c,"data-bedrock-split":s})))}function Tt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((s,[o,c])=>s+`${o}:${c};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>[n(),i()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter"]),h({style:r,"data-bedrock-stack":()=>""})))}const It=B("<div data-bedrock-cover-centered>");function Mt(e){return typeof e=="number"?`${e}px`:e&&I(e)?e:"100vh"}function Ot(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>`--minHeight: ${Mt(e.minHeight)};`,s=()=>e.stretchContent===!0?"stretch-content":"",o=()=>[n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","minHeight","stretchContent"]),h({style:o,"data-bedrock-cover":s})))}function zt(e){const[t,n]=f.splitProps(e,["children","top","bottom"]);return f.createComponent(Ot,f.mergeProps(n,{get children(){return[f.createMemo(()=>t.top),(()=>{const i=It();return G(i,()=>t.children),i})(),f.createMemo(()=>t.bottom)]}}))}function kt(e){const t=$(),n=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((c,[a,l])=>c+`${a}:${l};`,""),i=()=>`--gutter: ${b(t,e.gutter??"size00")??"0px"};`,r=()=>`--columns: ${e.columns&&e.columns>0?e.columns:1};`,s=()=>e.switchAt?`--switchAt: ${P(t,e.switchAt)??"0px"};`:"",o=()=>[n(),i(),r(),s()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","gutter","columns","switchAt"]),h({style:o,"data-bedrock-columns":()=>""})))}const Nt=e=>typeof e=="number"?e:1;function Lt(e){const t=()=>typeof e.style=="string"?e.style:Object.entries(e.style??{}).reduce((o,[c,a])=>o+`${c}:${a};`,""),n=()=>`--span: ${Nt(e.span)};`,i=()=>e.offsetStart&&e.offsetStart>0?`--offsetStart: ${e.offsetStart};`:"",r=()=>e.offsetEnd&&e.offsetEnd>0?`--offsetEnd: ${e.offsetEnd};`:"",s=()=>[t(),n(),i(),r()].join("; ");return g(()=>e.as??"div",f.mergeProps(y(e,["as","span","offsetStart","offsetEnd"]),h({style:s,"data-bedrock-column":()=>""})))}u.Center=nt,u.Column=Lt,u.ColumnDrop=ct,u.Columns=kt,u.Cover=zt,u.Frame=lt,u.Grid=Y,u.Inline=jt,u.InlineCluster=$t,u.MasonryGrid=gt,u.PadBox=At,u.Reel=Pt,u.Split=Et,u.Stack=Tt,u.ThemeProvider=it,u.checkIsCSSLength=I,u.createContainerQuery=st,u.getSafeGutter=z,u.getSizeValue=P,u.getSpacingValue=b,u.sizes=q,u.spacing=X,u.useTheme=$,Object.defineProperty(u,Symbol.toStringTag,{value:"Module"})});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bedrock-layout/solid",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.6",
|
|
4
4
|
"description": "Solid Foundational Layout Primitives for your Solid-js App",
|
|
5
5
|
"info": "Solid Bedrock Layout is a Solid.js port of the Bedrock Layout primitives written for react. Bedrock primitives are built to allow you to compose them together to create your own custom layouts. Many 'complex' layouts can be created by composing Bedrock Layout Primitives",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"types": "lib/index.d.ts",
|
|
36
36
|
"exports": {
|
|
37
37
|
".": {
|
|
38
|
+
"types": "./lib/index.d.ts",
|
|
38
39
|
"import": "./lib/index.m.js",
|
|
39
40
|
"require": "./lib/index.umd.js"
|
|
40
41
|
}
|
|
@@ -55,7 +56,7 @@
|
|
|
55
56
|
"solid-js": "^1.3.7"
|
|
56
57
|
},
|
|
57
58
|
"dependencies": {
|
|
58
|
-
"@bedrock-layout/register-resize-callback": "^2.0.
|
|
59
|
+
"@bedrock-layout/register-resize-callback": "^2.0.5"
|
|
59
60
|
},
|
|
60
61
|
"scripts": {
|
|
61
62
|
"test": "echo \"Error: run tests from root\" && exit 1",
|
|
@@ -70,5 +71,5 @@
|
|
|
70
71
|
"bugs": {
|
|
71
72
|
"url": "https://github.com/Bedrock-Layouts/Solid-Bedrock/issues"
|
|
72
73
|
},
|
|
73
|
-
"gitHead": "
|
|
74
|
+
"gitHead": "5c31745bde882a10a55f41bb3aecf7057d4f81f9"
|
|
74
75
|
}
|