lyco 1.2.7 → 1.2.8
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/dist/index.cjs.js +185 -208
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +321 -344
- package/dist/index.es.js.map +1 -1
- package/dist/types/components/core.d.ts +0 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
@@ -1,47 +1,24 @@
|
|
1
|
-
import{html as e}from"lit";
|
2
|
-
|
3
|
-
* @license
|
4
|
-
* Copyright 2017 Google LLC
|
5
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
6
|
-
*/
|
7
|
-
const t=globalThis,n=t.trustedTypes,r=n?n.createPolicy(`lit-html`,{createHTML:e=>e}):void 0,i=`$lit$`,a=`lit$${Math.random().toFixed(9).slice(2)}$`,o=`?`+a,s=`<${o}>`,c=document,l=()=>c.createComment(``),u=e=>e===null||typeof e!=`object`&&typeof e!=`function`,d=Array.isArray,f=e=>d(e)||typeof e?.[Symbol.iterator]==`function`,p=`[
|
8
|
-
\f\r]`,m=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,h=/-->/g,g=/>/g,_=RegExp(`>|${p}(?:([^\\s"'>=/]+)(${p}*=${p}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,`g`),v=/'/g,y=/"/g,b=/^(?:script|style|textarea|title)$/i,x=e=>(t,...n)=>({_$litType$:e,strings:t,values:n}),ee=x(1),S=x(2),C=x(3),w=Symbol.for(`lit-noChange`),T=Symbol.for(`lit-nothing`),E=new WeakMap,D=c.createTreeWalker(c,129);function O(e,t){if(!d(e)||!e.hasOwnProperty(`raw`))throw Error(`invalid template strings array`);return r===void 0?t:r.createHTML(t)}const k=(e,t)=>{let n=e.length-1,r=[],o,c=t===2?`<svg>`:t===3?`<math>`:``,l=m;for(let t=0;t<n;t++){let n=e[t],u,d,f=-1,p=0;for(;p<n.length&&(l.lastIndex=p,d=l.exec(n),d!==null);)p=l.lastIndex,l===m?d[1]===`!--`?l=h:d[1]===void 0?d[2]===void 0?d[3]!==void 0&&(l=_):(b.test(d[2])&&(o=RegExp(`</`+d[2],`g`)),l=_):l=g:l===_?d[0]===`>`?(l=o??m,f=-1):d[1]===void 0?f=-2:(f=l.lastIndex-d[2].length,u=d[1],l=d[3]===void 0?_:d[3]===`"`?y:v):l===y||l===v?l=_:l===h||l===g?l=m:(l=_,o=void 0);let x=l===_&&e[t+1].startsWith(`/>`)?` `:``;c+=l===m?n+s:f>=0?(r.push(u),n.slice(0,f)+i+n.slice(f)+a+x):n+a+(f===-2?t:x)}return[O(e,c+(e[n]||`<?>`)+(t===2?`</svg>`:t===3?`</math>`:``)),r]};var A=class e{constructor({strings:t,_$litType$:r},s){let c;this.parts=[];let u=0,d=0,f=t.length-1,p=this.parts,[m,h]=k(t,r);if(this.el=e.createElement(m,s),D.currentNode=this.el.content,r===2||r===3){let e=this.el.content.firstChild;e.replaceWith(...e.childNodes)}for(;(c=D.nextNode())!==null&&p.length<f;){if(c.nodeType===1){if(c.hasAttributes())for(let e of c.getAttributeNames())if(e.endsWith(i)){let t=h[d++],n=c.getAttribute(e).split(a),r=/([.?@])?(.*)/.exec(t);p.push({type:1,index:u,name:r[2],strings:n,ctor:r[1]===`.`?F:r[1]===`?`?I:r[1]===`@`?L:P}),c.removeAttribute(e)}else e.startsWith(a)&&(p.push({type:6,index:u}),c.removeAttribute(e));if(b.test(c.tagName)){let e=c.textContent.split(a),t=e.length-1;if(t>0){c.textContent=n?n.emptyScript:``;for(let n=0;n<t;n++)c.append(e[n],l()),D.nextNode(),p.push({type:2,index:++u});c.append(e[t],l())}}}else if(c.nodeType===8)if(c.data===o)p.push({type:2,index:u});else{let e=-1;for(;(e=c.data.indexOf(a,e+1))!==-1;)p.push({type:7,index:u}),e+=a.length-1}u++}}static createElement(e,t){let n=c.createElement(`template`);return n.innerHTML=e,n}};function j(e,t,n=e,r){var i,a;if(t===w)return t;let o=r===void 0?n._$Cl:(i=n._$Co)?.[r],s=u(t)?void 0:t._$litDirective$;return o?.constructor!==s&&(o==null||(a=o._$AO)==null||a.call(o,!1),s===void 0?o=void 0:(o=new s(e),o._$AT(e,n,r)),r===void 0?n._$Cl=o:(n._$Co??=[])[r]=o),o!==void 0&&(t=j(e,o._$AS(e,t.values),o,r)),t}var M=class{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){let{el:{content:t},parts:n}=this._$AD,r=(e?.creationScope??c).importNode(t,!0);D.currentNode=r;let i=D.nextNode(),a=0,o=0,s=n[0];for(;s!==void 0;){if(a===s.index){let t;s.type===2?t=new N(i,i.nextSibling,this,e):s.type===1?t=new s.ctor(i,s.name,s.strings,this,e):s.type===6&&(t=new R(i,this,e)),this._$AV.push(t),s=n[++o]}a!==s?.index&&(i=D.nextNode(),a++)}return D.currentNode=c,r}p(e){let t=0;for(let n of this._$AV)n!==void 0&&(n.strings===void 0?n._$AI(e[t]):(n._$AI(e,n,t),t+=n.strings.length-2)),t++}},N=class e{get _$AU(){var e;return(e=this._$AM)?._$AU??this._$Cv}constructor(e,t,n,r){this.type=2,this._$AH=T,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=n,this.options=r,this._$Cv=r?.isConnected??!0}get parentNode(){let e=this._$AA.parentNode,t=this._$AM;return t!==void 0&&e?.nodeType===11&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=j(this,e,t),u(e)?e===T||e==null||e===``?(this._$AH!==T&&this._$AR(),this._$AH=T):e!==this._$AH&&e!==w&&this._(e):e._$litType$===void 0?e.nodeType===void 0?f(e)?this.k(e):this._(e):this.T(e):this.$(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==T&&u(this._$AH)?this._$AA.nextSibling.data=e:this.T(c.createTextNode(e)),this._$AH=e}$(e){var t;let{values:n,_$litType$:r}=e,i=typeof r==`number`?this._$AC(e):(r.el===void 0&&(r.el=A.createElement(O(r.h,r.h[0]),this.options)),r);if((t=this._$AH)?._$AD===i)this._$AH.p(n);else{let e=new M(i,this),t=e.u(this.options);e.p(n),this.T(t),this._$AH=e}}_$AC(e){let t=E.get(e.strings);return t===void 0&&E.set(e.strings,t=new A(e)),t}k(t){d(this._$AH)||(this._$AH=[],this._$AR());let n=this._$AH,r,i=0;for(let a of t)i===n.length?n.push(r=new e(this.O(l()),this.O(l()),this,this.options)):r=n[i],r._$AI(a),i++;i<n.length&&(this._$AR(r&&r._$AB.nextSibling,i),n.length=i)}_$AR(e=this._$AA.nextSibling,t){var n;for((n=this._$AP)?.call(this,!1,!0,t);e&&e!==this._$AB;){let t=e.nextSibling;e.remove(),e=t}}setConnected(e){var t;this._$AM===void 0&&(this._$Cv=e,(t=this._$AP)?.call(this,e))}},P=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,n,r,i){this.type=1,this._$AH=T,this._$AN=void 0,this.element=e,this.name=t,this._$AM=r,this.options=i,n.length>2||n[0]!==``||n[1]!==``?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=T}_$AI(e,t=this,n,r){let i=this.strings,a=!1;if(i===void 0)e=j(this,e,t,0),a=!u(e)||e!==this._$AH&&e!==w,a&&(this._$AH=e);else{let r=e,o,s;for(e=i[0],o=0;o<i.length-1;o++)s=j(this,r[n+o],t,o),s===w&&(s=this._$AH[o]),a||=!u(s)||s!==this._$AH[o],s===T?e=T:e!==T&&(e+=(s??``)+i[o+1]),this._$AH[o]=s}a&&!r&&this.j(e)}j(e){e===T?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e??``)}},F=class extends P{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===T?void 0:e}},I=class extends P{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==T)}},L=class extends P{constructor(e,t,n,r,i){super(e,t,n,r,i),this.type=5}_$AI(e,t=this){if((e=j(this,e,t,0)??T)===w)return;let n=this._$AH,r=e===T&&n!==T||e.capture!==n.capture||e.once!==n.once||e.passive!==n.passive,i=e!==T&&(n===T||r);r&&this.element.removeEventListener(this.name,this,n),i&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){var t;typeof this._$AH==`function`?this._$AH.call((t=this.options)?.host??this.element,e):this._$AH.handleEvent(e)}},R=class{constructor(e,t,n){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=n}get _$AU(){return this._$AM._$AU}_$AI(e){j(this,e)}};const te={M:i,P:a,A:o,C:1,L:k,R:M,D:f,V:j,I:N,H:P,N:I,U:L,B:F,F:R},ne=t.litHtmlPolyfillSupport;ne?.(A,N),(t.litHtmlVersions??=[]).push(`3.3.0`);
|
9
|
-
/**
|
10
|
-
* @license
|
11
|
-
* Copyright 2017 Google LLC
|
12
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
13
|
-
*/
|
14
|
-
const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML:1,SVG:2,MATHML:3},oe=(e,t)=>t===void 0?e?._$litType$!==void 0:e?._$litType$===t,se=e=>{var t;return(e==null||(t=e._$litType$)==null?void 0:t.h)!=null},ce=e=>e?._$litDirective$!==void 0,le=e=>e?._$litDirective$,ue=e=>e.strings===void 0,de=()=>document.createComment(``),fe=(e,t,n)=>{let r=e._$AA.parentNode,i=t===void 0?e._$AB:t._$AA;if(n===void 0){let t=r.insertBefore(de(),i),a=r.insertBefore(de(),i);n=new re(t,a,e,e.options)}else{let t=n._$AB.nextSibling,o=n._$AM,s=o!==e;if(s){var a;let t;(a=n._$AQ)?.call(n,e),n._$AM=e,n._$AP!==void 0&&(t=e._$AU)!==o._$AU&&n._$AP(t)}if(t!==i||s){let e=n._$AA;for(;e!==t;){let t=e.nextSibling;r.insertBefore(e,i),e=t}}}return n},pe=(e,t,n=e)=>(e._$AI(t,n),e),me={},he=(e,t=me)=>e._$AH=t,ge=e=>e._$AH,_e=e=>{var t;(t=e._$AP)?.call(e,!1,!0);let n=e._$AA,r=e._$AB.nextSibling;for(;n!==r;){let e=n.nextSibling;n.remove(),n=e}},ve=e=>{e._$AR()},ye={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},be=e=>(...t)=>({_$litDirective$:e,values:t});var xe=class{constructor(e){}get _$AU(){return this._$AM._$AU}_$AT(e,t,n){this._$Ct=e,this._$AM=t,this._$Ci=n}_$AS(e,t){return this.update(e,t)}update(e,t){return this.render(...t)}};
|
15
|
-
/**
|
16
|
-
* @license
|
17
|
-
* Copyright 2017 Google LLC
|
18
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
19
|
-
*/const z=(e,t)=>{var n;let r=e._$AN;if(r===void 0)return!1;for(let e of r)(n=e._$AO)?.call(e,t,!1),z(e,t);return!0},B=e=>{let t,n;do{if((t=e._$AM)===void 0)break;n=t._$AN,n.delete(e),e=t}while(n?.size===0)},Se=e=>{for(let t;t=e._$AM;e=t){let n=t._$AN;if(n===void 0)t._$AN=n=new Set;else if(n.has(e))break;n.add(e),Te(t)}};function Ce(e){this._$AN===void 0?this._$AM=e:(B(this),this._$AM=e,Se(this))}function we(e,t=!1,n=0){let r=this._$AH,i=this._$AN;if(i!==void 0&&i.size!==0)if(t)if(Array.isArray(r))for(let e=n;e<r.length;e++)z(r[e],!1),B(r[e]);else r!=null&&(z(r,!1),B(r));else z(this,e)}const Te=e=>{e.type==ye.CHILD&&(e._$AP??=we,e._$AQ??=Ce)};var Ee=class extends xe{constructor(){super(...arguments),this._$AN=void 0}_$AT(e,t,n){super._$AT(e,t,n),Se(this),this.isConnected=e._$AU}_$AO(e,t=!0){var n,r;e!==this.isConnected&&(this.isConnected=e,e?(n=this.reconnected)?.call(this):(r=this.disconnected)?.call(this)),t&&(z(this,e),B(this))}setValue(e){if(ue(this._$Ct))this._$Ct._$AI(e,this);else{let t=[...this._$Ct._$AH];t[this._$Ci]=e,this._$Ct._$AI(t,this,0)}}disconnected(){}reconnected(){}};
|
20
|
-
/**
|
21
|
-
* @license
|
22
|
-
* Copyright 2020 Google LLC
|
23
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
24
|
-
*/const De=()=>new Oe;var Oe=class{};const V=new WeakMap,H=be(class extends Ee{render(e){return T}update(e,[t]){var n;let r=t!==this.G;return r&&this.G!==void 0&&this.rt(void 0),(r||this.lt!==this.ct)&&(this.G=t,this.ht=(n=e.options)?.host,this.rt(this.ct=e.element)),T}rt(e){if(this.isConnected||(e=void 0),typeof this.G==`function`){let t=this.ht??globalThis,n=V.get(t);n===void 0&&(n=new WeakMap,V.set(t,n)),n.get(this.G)!==void 0&&this.G.call(this.ht,void 0),n.set(this.G,e),e!==void 0&&this.G.call(this.ht,e)}else this.G.value=e}get lt(){var e,t;return typeof this.G==`function`?(e=V.get(this.ht??globalThis))?.get(this.G):(t=this.G)?.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}}),ke=Symbol(`___LYCO_NULL___`);function U(t){return t?typeof t==`function`?t():t:e``}function W(t,n){let r=n??(e=>e);if(t===void 0)return e``;if(Array.isArray(t))return t.map((e,t)=>r(U(e),t,!0,!1));if(typeof t!=`function`)return r(U(t),void 0,!1,!1);let i=t();return Array.isArray(i)?i.map((e,t)=>r(U(e),t,!0,!1)):r(U(i),void 0,!1,!0)}function Ae(e){let t=Math.random().toString(36).substring(2,15);return e?`lyco-${e}-${t}`:`lyco-${t}`}function je(e,t){let n=t??(e=>e),r=e=>n(U(e));return e?r(e):r}function Me(e,t,n){let r=t??(e=>e),i=e=>r(W(e,n));return e?i(e):i}const G=e=>({init:!1,prefix:e,className:ke}),K={"GridBreakpoint::grid-breakpoint":G(`grid-breakpoint`),"Hidden::hidden-container":G(`hidden-container`),"ListGroup::list-group":G(`list-group`),"ScrollBar::scrollbar-container":G(`scrollbar-container`),"SkeletonLoader::skeleton-shimmer":G(`skeleton-shimmer`),"Swiper::swiper":G(`swiper`),"Table::table":G(`table`),"WaterFlow::waterflow":G(`waterflow`),"AutoFitGrid::auto-fit-grid":G(`auto-fit-grid`),"GridCol::grid-col":G(`grid-col`),"GridRow::grid-row":G(`grid-row`),"List::list":G(`list`)};function q(e){let t=K[e];return t.init||(K[e].init=!0,K[e].className=Ae(t.prefix)),K[e].className===ke?Ae(t.prefix):K[e].className}const J={all:{value:0}};function Y(e){var t;return(t=J[e])?.value||(J[e]={value:0}),J[e].value}function X(t,n){return J.all={value:J.all.value+1},J[t]===void 0?J[t]={value:0}:J[t].value=J[t].value+1,e`
|
25
|
-
<!-- ${t} - ${J[t].value} -->
|
1
|
+
import{html as e}from"lit";import{createRef as t,ref as n}from"lit/directives/ref.js";const r=Symbol(`___LYCO_NULL___`);function i(t){return t?typeof t==`function`?t():t:e``}function a(t,n){let r=n??(e=>e);if(t===void 0)return e``;if(Array.isArray(t))return t.map((e,t)=>r(i(e),t,!0,!1));if(typeof t!=`function`)return r(i(t),void 0,!1,!1);let a=t();return Array.isArray(a)?a.map((e,t)=>r(i(e),t,!0,!1)):r(i(a),void 0,!1,!0)}function o(e){let t=Math.random().toString(36).substring(2,15);return e?`lyco-${e}-${t}`:`lyco-${t}`}function s(e,t){let n=t??(e=>e),r=e=>n(i(e));return e?r(e):r}function c(e,t,n){let r=t??(e=>e),i=e=>r(a(e,n));return e?i(e):i}const l=e=>({init:!1,prefix:e,className:r}),u={"GridBreakpoint::grid-breakpoint":l(`grid-breakpoint`),"Hidden::hidden-container":l(`hidden-container`),"ListGroup::list-group":l(`list-group`),"ScrollBar::scrollbar-container":l(`scrollbar-container`),"SkeletonLoader::skeleton-shimmer":l(`skeleton-shimmer`),"Swiper::swiper":l(`swiper`),"Table::table":l(`table`),"WaterFlow::waterflow":l(`waterflow`),"AutoFitGrid::auto-fit-grid":l(`auto-fit-grid`),"GridCol::grid-col":l(`grid-col`),"GridRow::grid-row":l(`grid-row`),"List::list":l(`list`)};function d(e){let t=u[e];return t.init||(u[e].init=!0,u[e].className=o(t.prefix)),u[e].className===r?o(t.prefix):u[e].className}const f={all:{value:0}};function p(e){var t;return(t=f[e])?.value||(f[e]={value:0}),f[e].value}function m(t,n){return f.all={value:f.all.value+1},f[t]===void 0?f[t]={value:0}:f[t].value=f[t].value+1,e`
|
2
|
+
<!-- ${t} - ${f[t].value} -->
|
26
3
|
${n}
|
27
|
-
`}function
|
4
|
+
`}function h(e,t,n){t.forEach(([t,r])=>{n.has(t)&&e.removeEventListener(t,n.get(t));let i,a;typeof r==`function`?(i=r,a=void 0):(i=r.handler,a=r.options);let o=e=>i(e);e.addEventListener(t,o,a),n.set(t,o)})}function g(e){let t=new Map,n=Object.entries(e);return{bind(e){h(e,n,t)},unbindAll(){t.clear()}}}function _(t,r){if(r===void 0){let n=n=>_(t,n??e``);return n.html=(n,...r)=>_(t,e(n,...r)),n}let a=t?.fadeBg??`rgba(0,0,0,0.7)`,o=t?.zIndex??2e3,s=g(t?.on??{});return e`
|
28
5
|
<div
|
29
|
-
${
|
6
|
+
${n(e=>{e?s.bind(e):s.unbindAll()})}
|
30
7
|
style="
|
31
8
|
position: fixed;
|
32
9
|
top: 0; left: 0; right: 0; bottom: 0;
|
33
|
-
background: ${
|
34
|
-
z-index: ${
|
10
|
+
background: ${a};
|
11
|
+
z-index: ${o};
|
35
12
|
display: flex;
|
36
13
|
justify-content: center;
|
37
14
|
align-items: center;
|
38
15
|
"
|
39
16
|
>
|
40
|
-
${
|
17
|
+
${i(r)}
|
41
18
|
</div>
|
42
|
-
`}function
|
19
|
+
`}function v(t,r){let i=g(t?.on??{});return r===void 0?n=>v(t,n??[e``]):e`
|
43
20
|
<div
|
44
|
-
${
|
21
|
+
${n(e=>{e?i.bind(e):i.unbindAll()})}
|
45
22
|
.class="${t?.className}"
|
46
23
|
style="
|
47
24
|
display: flex;
|
@@ -50,234 +27,234 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
50
27
|
${t?.style??``}
|
51
28
|
"
|
52
29
|
>
|
53
|
-
${
|
30
|
+
${a(r)}
|
54
31
|
</div>
|
55
|
-
`}function
|
32
|
+
`}function y(t,r){if(r===void 0){let n=n=>y(t,n??e``);return n.html=(n,...r)=>y(t,e(n,...r)),n}let a=t?.direction??`row`,o=g(t?.on??{});return e`
|
56
33
|
<div
|
57
|
-
${
|
34
|
+
${n(e=>{e?o.bind(e):o.unbindAll()})}
|
58
35
|
style="
|
59
36
|
display: flex;
|
60
|
-
flex-direction: ${
|
37
|
+
flex-direction: ${a};
|
61
38
|
${t?.justify?`justify-content: ${t.justify};`:``}
|
62
39
|
${t?.align?`align-items: ${t.align};`:``}
|
63
40
|
${t?.gap?`gap: ${t.gap};`:``}
|
64
41
|
"
|
65
42
|
>
|
66
|
-
${
|
43
|
+
${i(r)}
|
67
44
|
</div>
|
68
|
-
`}function
|
45
|
+
`}function b(t,r){if(r===void 0){let n=n=>b(t,n??e``);return n.html=(n,...r)=>b(t,e(n,...r)),n}let a=g(t?.on??{});return e`
|
69
46
|
<div
|
70
|
-
${
|
47
|
+
${n(e=>{e?a.bind(e):a.unbindAll()})}
|
71
48
|
style="break-inside: avoid; margin-bottom: 16px;"
|
72
49
|
>
|
73
|
-
${
|
50
|
+
${i(r)}
|
74
51
|
</div>
|
75
|
-
`}function
|
52
|
+
`}function x(t,r){if(r===void 0)return n=>x(t,n??[e``]);let i=t?.columns??1,o=g(t?.on??{});return e`
|
76
53
|
<div
|
77
|
-
${
|
54
|
+
${n(e=>{e?o.bind(e):o.unbindAll()})}
|
78
55
|
style="
|
79
56
|
display: grid;
|
80
|
-
grid-template-columns: repeat(${
|
57
|
+
grid-template-columns: repeat(${i}, 1fr);
|
81
58
|
${t?.gap?`gap: ${t.gap};`:``}
|
82
59
|
"
|
83
60
|
>
|
84
|
-
${
|
61
|
+
${a(r)}
|
85
62
|
</div>
|
86
|
-
`}function
|
87
|
-
.${
|
63
|
+
`}function S(t,r){if(r===void 0){let n=n=>S(t,n??e``);return n.html=(n,...r)=>S(t,e(n,...r)),n}let a=p(`GridCol`),o=d(`GridCol::grid-col`)+`-lyco-now-`+a,s=t?.gap?`column-gap: ${t.gap};`:``,c=`
|
64
|
+
.${o} {
|
88
65
|
display: grid;
|
89
66
|
grid-auto-flow: column;
|
90
|
-
${
|
67
|
+
${s}
|
91
68
|
}
|
92
|
-
`,
|
69
|
+
`,l=g(t?.on??{});return m(`GridCol`,e`
|
93
70
|
<style>
|
94
|
-
${
|
71
|
+
${c}
|
95
72
|
</style>
|
96
73
|
<div
|
97
|
-
${
|
98
|
-
class="${
|
74
|
+
${n(e=>{e?l.bind(e):l.unbindAll()})}
|
75
|
+
class="${o}"
|
99
76
|
>
|
100
|
-
${
|
77
|
+
${i(r)}
|
101
78
|
</div>
|
102
|
-
`)}function
|
79
|
+
`)}function C(t,r){if(r===void 0){let n=n=>C(t,n??e``);return n.html=(n,...r)=>C(t,e(n,...r)),n}let a=g(t?.on??{});return e`
|
103
80
|
<div
|
104
|
-
${
|
81
|
+
${n(e=>{e?a.bind(e):a.unbindAll()})}
|
105
82
|
style="${t?.span?`grid-column: span ${t.span};`:``}"
|
106
83
|
>
|
107
|
-
${
|
84
|
+
${i(r)}
|
108
85
|
</div>
|
109
|
-
`}function
|
110
|
-
.${
|
86
|
+
`}function w(t,r){if(r===void 0){let n=n=>w(t,n??e``);return n.html=(n,...r)=>w(t,e(n,...r)),n}let a=p(`GridRow`),o=d(`GridRow::grid-row`)+`-lyco-now-`+a,s=t?.gap?`row-gap: ${t.gap};`:``,c=`
|
87
|
+
.${o} {
|
111
88
|
display: grid;
|
112
89
|
grid-auto-flow: row;
|
113
|
-
${
|
90
|
+
${s}
|
114
91
|
}
|
115
|
-
`,
|
92
|
+
`,l=g(t?.on??{});return m(`GridRow`,e`
|
116
93
|
<style>
|
117
|
-
${
|
94
|
+
${c}
|
118
95
|
</style>
|
119
96
|
<div
|
120
|
-
${
|
121
|
-
class="${
|
97
|
+
${n(e=>{e?l.bind(e):l.unbindAll()})}
|
98
|
+
class="${o}"
|
122
99
|
>
|
123
|
-
${
|
100
|
+
${i(r)}
|
124
101
|
</div>
|
125
|
-
`)}function
|
102
|
+
`)}function T(t,r){if(r===void 0)return n=>T(t,n??[e``]);let i=g(t?.on??{});return e`
|
126
103
|
<div
|
127
|
-
${
|
104
|
+
${n(e=>{e?i.bind(e):i.unbindAll()})}
|
128
105
|
style="
|
129
106
|
display: flex;
|
130
107
|
flex-direction: row;
|
131
108
|
${t?.space?`gap: ${t.space};`:``}
|
132
109
|
"
|
133
110
|
>
|
134
|
-
${
|
111
|
+
${a(r)}
|
135
112
|
</div>
|
136
|
-
`}function
|
113
|
+
`}function E(t,r){if(r===void 0){let n=n=>E(t,n??e``);return n.html=(n,...r)=>E(t,e(n,...r)),n}let a=t?.columnCount??3,o=t?.gap??`16px`,s=p(`WaterFlow`),c=d(`WaterFlow::waterflow`)+`-lyco-now-${s}`,l=`
|
137
114
|
/* 使用 CSS 类来控制多列布局 */
|
138
|
-
.${
|
139
|
-
column-count: ${
|
140
|
-
column-gap: ${typeof
|
115
|
+
.${c} {
|
116
|
+
column-count: ${a};
|
117
|
+
column-gap: ${typeof o==`number`?`${o}px`:o};
|
141
118
|
}
|
142
119
|
/* 子元素如果是块级元素,需要让它们适应多列流式布局 */
|
143
|
-
.${
|
120
|
+
.${c} > * {
|
144
121
|
display: inline-block;
|
145
122
|
width: 100%;
|
146
123
|
}
|
147
|
-
`,
|
124
|
+
`,u=g(t?.on??{});return m(`WaterFlow`,e`
|
148
125
|
<style>
|
149
|
-
${
|
126
|
+
${l}
|
150
127
|
</style>
|
151
128
|
|
152
129
|
<div
|
153
|
-
${
|
154
|
-
class="${
|
130
|
+
${n(e=>{e?u.bind(e):u.unbindAll()})}
|
131
|
+
class="${c}"
|
155
132
|
>
|
156
|
-
${
|
133
|
+
${i(r)}
|
157
134
|
</div>
|
158
|
-
`)}function
|
135
|
+
`)}function D(t,r){if(r===void 0){let n=n=>D(t,n??e``);return n.html=(n,...r)=>D(t,e(n,...r)),n}let a=t?.gap??`0px`,o=t?.firstHeight??`50%`,s=e``,c=e``;if(typeof r==`function`){var l;let t=(l=r.call)?.call(r,null)??[];s=t[0]??e``,c=t[1]??e``}else s=i(r);let u=g(t?.on??{});return e`
|
159
136
|
<div
|
160
|
-
${
|
137
|
+
${n(e=>{e?u.bind(e):u.unbindAll()})}
|
161
138
|
style="
|
162
139
|
display: flex;
|
163
140
|
flex-direction: column;
|
164
141
|
width: 100%;
|
165
142
|
height: 100%;
|
166
|
-
gap: ${
|
143
|
+
gap: ${a};
|
167
144
|
"
|
168
145
|
>
|
169
|
-
<div style="flex: 0 0 ${
|
170
|
-
<div style="flex: 1 1 auto; overflow: auto;">${
|
146
|
+
<div style="flex: 0 0 ${o}; overflow: auto;">${s}</div>
|
147
|
+
<div style="flex: 1 1 auto; overflow: auto;">${c}</div>
|
171
148
|
</div>
|
172
|
-
`}function
|
149
|
+
`}function O(t,r){if(r===void 0){let n=n=>O(t,n??e``);return n.html=(n,...r)=>O(t,e(n,...r)),n}let a=t?.gap??`0px`,o=t?.firstWidth??`50%`,s=e``,c=e``;if(typeof r==`function`){var l;let t=(l=r.call)?.call(r,null)??[];s=t[0]??e``,c=t[1]??e``}else s=i(r);let u=g(t?.on??{});return e`
|
173
150
|
<div
|
174
|
-
${
|
151
|
+
${n(e=>{e?u.bind(e):u.unbindAll()})}
|
175
152
|
style="
|
176
153
|
display: flex;
|
177
154
|
flex-direction: row;
|
178
155
|
width: 100%;
|
179
156
|
height: 100%;
|
180
|
-
gap: ${
|
157
|
+
gap: ${a};
|
181
158
|
"
|
182
159
|
>
|
183
|
-
<div style="flex: 0 0 ${
|
184
|
-
<div style="flex: 1 1 auto; overflow: auto;">${
|
160
|
+
<div style="flex: 0 0 ${o}; overflow: auto;">${s}</div>
|
161
|
+
<div style="flex: 1 1 auto; overflow: auto;">${c}</div>
|
185
162
|
</div>
|
186
|
-
`}function
|
187
|
-
.${
|
188
|
-
${
|
189
|
-
width: ${
|
190
|
-
height: ${
|
163
|
+
`}function k(t,r){if(r===void 0){let n=n=>k(t,n??e``);return n.html=(n,...r)=>k(t,e(n,...r)),n}let a=t?.direction??`vertical`,o=t?.height??`100%`,s=t?.width??`100%`,c=t?.customCss??``,l=p(`ScrollBar`),u=t?.className??d(`ScrollBar::scrollbar-container`)+`-lyco-now-`+l,f=a===`horizontal`?`overflow-x: auto; overflow-y: hidden`:`overflow-y: auto; overflow-x: hidden`,h=`
|
164
|
+
.${u} {
|
165
|
+
${f};
|
166
|
+
width: ${s};
|
167
|
+
height: ${o};
|
191
168
|
}
|
192
|
-
.${
|
169
|
+
.${u}::-webkit-scrollbar {
|
193
170
|
width: 8px;
|
194
171
|
height: 8px;
|
195
172
|
}
|
196
|
-
.${
|
173
|
+
.${u}::-webkit-scrollbar-thumb {
|
197
174
|
background-color: rgba(0, 0, 0, 0.2);
|
198
175
|
border-radius: 4px;
|
199
176
|
}
|
200
|
-
.${
|
177
|
+
.${u}::-webkit-scrollbar-track {
|
201
178
|
background: rgba(0, 0, 0, 0.05);
|
202
179
|
}
|
203
|
-
${
|
204
|
-
`,
|
180
|
+
${c}
|
181
|
+
`,_=g(t?.on??{});return m(`ScrollBar`,e`
|
205
182
|
<style>
|
206
|
-
${
|
183
|
+
${h}
|
207
184
|
</style>
|
208
185
|
<div
|
209
|
-
${
|
210
|
-
class="${
|
186
|
+
${n(e=>{e?_.bind(e):_.unbindAll()})}
|
187
|
+
class="${u}"
|
211
188
|
>
|
212
|
-
${
|
189
|
+
${i(r)}
|
213
190
|
</div>
|
214
|
-
`)}function
|
191
|
+
`)}function A(t,r){if(r===void 0)return n=>A(t,n??[e``]);let i=t?.sidebarWidth??`240px`,o=t?.sidebarPosition??`left`,s=t?.gap??`0px`,c=e``,l=e``;if(typeof r==`function`){var u;let t=(u=r.call)?.call(r,null)??[];c=t[0]??e``,l=t[1]??e``}else l=a(r);let d=g(t?.on??{});return e`
|
215
192
|
<div
|
216
|
-
${
|
193
|
+
${n(e=>{e?d.bind(e):d.unbindAll()})}
|
217
194
|
style="
|
218
195
|
display: flex;
|
219
|
-
flex-direction: ${
|
196
|
+
flex-direction: ${o===`left`?`row`:`row-reverse`};
|
220
197
|
width: 100%;
|
221
198
|
height: 100%;
|
222
|
-
gap: ${
|
199
|
+
gap: ${s};
|
223
200
|
"
|
224
201
|
>
|
225
|
-
<div style="flex: 0 0 ${
|
226
|
-
<div style="flex: 1 1 auto; overflow: auto;">${
|
202
|
+
<div style="flex: 0 0 ${i}; overflow: auto;">${c}</div>
|
203
|
+
<div style="flex: 1 1 auto; overflow: auto;">${l}</div>
|
227
204
|
</div>
|
228
|
-
`}function
|
229
|
-
<div class="${
|
230
|
-
${Array.from({length:
|
205
|
+
`}function j(t={},r){if(r===void 0)return n=>j(t,n??[e``]);let i=p(`Swiper`),{gap:a=`8px`,snapType:o=`mandatory`,height:s=`auto`,width:c=`100%`,className:l=d(`Swiper::swiper`)+`-lyco-now-${i}`,direction:u=`x`,scrollBehavior:f=`smooth`,align:h=`start`,showNavigation:_=!0,navigationPosition:v=`inside`,showPagination:y=!0,paginationType:b=`dots`,autoPlay:x=!1,interval:S=3e3,loop:C=!1,touchEnabled:w=!0,mouseWheel:T=!1,onSlideChange:E,on:D}=t,O=l,k=O+`-container`,A=O+`-slide`,M=O+`-navigation`,N=O+`-pagination`,P;P=r?typeof r==`function`?r():r:[];let F=P.length,[I,L]=(()=>{let e={value:0};return[()=>e.value,t=>{let n=Math.max(0,Math.min(t,F-1));e.value!==n&&(e.value=n,E?.(n))}]})(),R=e=>{let t=typeof document<`u`?document.querySelector(`.${k}`):null;if(!t)return;let n=t.querySelectorAll(`.${A}`);if(e<0||e>=n.length)return;let r=n[e],i=r.getBoundingClientRect(),a=t.getBoundingClientRect(),o;u===`x`?(o=r.offsetLeft-t.offsetLeft,h===`center`?o-=(a.width-i.width)/2:h===`end`&&(o-=a.width-i.width),t.scrollTo({left:o,behavior:f})):(o=r.offsetTop-t.offsetTop,h===`center`?o-=(a.height-i.height)/2:h===`end`&&(o-=a.height-i.height),t.scrollTo({top:o,behavior:f})),L(e)},z=()=>{let e=I()+1>=F?C?0:I():I()+1;R(e)},B=()=>{let e=I()-1<0?C?F-1:I():I()-1;R(e)},V=()=>{let e=typeof document<`u`?document.querySelector(`.${k}`):null;if(!e)return;let t=e.querySelectorAll(`.${A}`),n=0,r=1/0;t.forEach((t,i)=>{let a=t.getBoundingClientRect(),o=e.getBoundingClientRect(),s;if(u===`x`){let e=a.left+a.width/2-(o.left+o.width/2);s=Math.abs(e)}else{let e=a.top+a.height/2-(o.top+o.height/2);s=Math.abs(e)}s<r&&(r=s,n=i)}),L(n)},H=e=>{if(!w)return;let t=e.touches[0],n=e.currentTarget;n.dataset.touchStartX=t.clientX.toString(),n.dataset.touchStartY=t.clientY.toString()},U=e=>{if(!w)return;let t=e.touches[0],n=e.currentTarget,r=parseFloat(n.dataset.touchStartX||`0`),i=parseFloat(n.dataset.touchStartY||`0`),a=t.clientX-r,o=t.clientY-i;(Math.abs(a)>Math.abs(o)||u===`x`)&&e.preventDefault()},W=e=>{if(!w)return;let t=e.currentTarget,n=parseFloat(t.dataset.touchStartX||`0`),r=parseFloat(t.dataset.touchStartY||`0`);if(!n&&!r)return;let i=e.changedTouches[0],a=i.clientX-n,o=i.clientY-r,s=Math.max(Math.abs(a),Math.abs(o))>30;s&&(u===`x`?a>0?B():z():o>0?B():z()),delete t.dataset.touchStartX,delete t.dataset.touchStartY},G=e=>{T&&(e.preventDefault(),e.deltaY>0?z():B())},K=e=>{if(!x||!e)return;let t,n=()=>{t=setInterval(z,S)},r=()=>{clearInterval(t)};return e.addEventListener(`mouseenter`,r),e.addEventListener(`mouseleave`,n),n(),()=>{clearInterval(t),e.removeEventListener(`mouseenter`,r),e.removeEventListener(`mouseleave`,n)}},q=()=>{let e=typeof document<`u`?document.querySelector(`.${k}`):null;if(!e)return;let t=[];e.addEventListener(`scroll`,V),t.push(()=>e.removeEventListener(`scroll`,V)),w&&(e.addEventListener(`touchstart`,H),e.addEventListener(`touchmove`,U,{passive:!1}),e.addEventListener(`touchend`,W),t.push(()=>e.removeEventListener(`touchstart`,H)),t.push(()=>e.removeEventListener(`touchmove`,U)),t.push(()=>e.removeEventListener(`touchend`,W))),T&&(e.addEventListener(`wheel`,G,{passive:!1}),t.push(()=>e.removeEventListener(`wheel`,G)));let n=K(e);return n&&t.push(n),R(0),()=>t.forEach(e=>e())};typeof window<`u`&&typeof document<`u`&&setTimeout(q,0);let J=e`
|
206
|
+
<div class="${N}">
|
207
|
+
${Array.from({length:F},(t,n)=>e`
|
231
208
|
<button
|
232
|
-
class="${n===
|
233
|
-
@click=${()=>
|
209
|
+
class="${n===I()?`active`:``}"
|
210
|
+
@click=${()=>R(n)}
|
234
211
|
></button>
|
235
212
|
`)}
|
236
213
|
</div>
|
237
|
-
`,
|
238
|
-
<div class="${
|
239
|
-
<span class="current">${
|
214
|
+
`,Y=e`
|
215
|
+
<div class="${N} fraction">
|
216
|
+
<span class="current">${I()+1}</span>
|
240
217
|
<span class="separator">/</span>
|
241
|
-
<span class="total">${
|
218
|
+
<span class="total">${F}</span>
|
242
219
|
</div>
|
243
|
-
`,
|
244
|
-
<div class="${
|
220
|
+
`,ee=e`
|
221
|
+
<div class="${N} progressbar">
|
245
222
|
<div
|
246
223
|
class="progress"
|
247
|
-
style="width: ${
|
224
|
+
style="width: ${F>1?I()/(F-1)*100:0}%"
|
248
225
|
></div>
|
249
226
|
</div>
|
250
|
-
`,
|
251
|
-
<div class="${
|
252
|
-
<button class="prev" @click=${
|
253
|
-
<button class="next" @click=${
|
227
|
+
`,te=e`
|
228
|
+
<div class="${M}">
|
229
|
+
<button class="prev" @click=${B}>◀</button>
|
230
|
+
<button class="next" @click=${z}>▶</button>
|
254
231
|
</div>
|
255
|
-
`,
|
256
|
-
.${
|
232
|
+
`,X=`
|
233
|
+
.${O} {
|
257
234
|
position: relative;
|
258
235
|
overflow: hidden;
|
259
|
-
width: ${
|
260
|
-
height: ${
|
236
|
+
width: ${c};
|
237
|
+
height: ${s};
|
261
238
|
}
|
262
239
|
|
263
|
-
.${
|
240
|
+
.${k} {
|
264
241
|
width: 100%;
|
265
242
|
height: 100%;
|
266
243
|
overflow: auto;
|
267
|
-
scroll-snap-type: ${
|
244
|
+
scroll-snap-type: ${u+` `+o};
|
268
245
|
-webkit-overflow-scrolling: touch;
|
269
|
-
scroll-behavior: ${
|
270
|
-
gap: ${
|
246
|
+
scroll-behavior: ${f};
|
247
|
+
gap: ${a};
|
271
248
|
display: flex;
|
272
|
-
flex-direction: ${
|
249
|
+
flex-direction: ${u===`x`?`row`:`column`};
|
273
250
|
}
|
274
251
|
|
275
|
-
.${
|
276
|
-
scroll-snap-align: ${
|
252
|
+
.${A} {
|
253
|
+
scroll-snap-align: ${h};
|
277
254
|
flex-shrink: 0;
|
278
255
|
}
|
279
256
|
|
280
|
-
.${
|
257
|
+
.${M} {
|
281
258
|
position: absolute;
|
282
259
|
top: 50%;
|
283
260
|
left: 0;
|
@@ -286,10 +263,10 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
286
263
|
display: flex;
|
287
264
|
justify-content: space-between;
|
288
265
|
pointer-events: none;
|
289
|
-
padding: ${
|
266
|
+
padding: ${v===`outside`?`0 1rem`:`0 0.5rem`};
|
290
267
|
}
|
291
268
|
|
292
|
-
.${
|
269
|
+
.${M} button {
|
293
270
|
width: 2.5rem;
|
294
271
|
height: 2.5rem;
|
295
272
|
border-radius: 50%;
|
@@ -304,11 +281,11 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
304
281
|
transition: background-color 0.3s;
|
305
282
|
}
|
306
283
|
|
307
|
-
.${
|
284
|
+
.${M} button:hover {
|
308
285
|
background-color: rgba(0, 0, 0, 0.8);
|
309
286
|
}
|
310
287
|
|
311
|
-
.${
|
288
|
+
.${N} {
|
312
289
|
position: absolute;
|
313
290
|
bottom: 1rem;
|
314
291
|
left: 0;
|
@@ -318,7 +295,7 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
318
295
|
gap: 0.5rem;
|
319
296
|
align-items: center;
|
320
297
|
}
|
321
|
-
.${
|
298
|
+
.${N} button {
|
322
299
|
width: 0.75rem;
|
323
300
|
height: 0.75rem;
|
324
301
|
border-radius: 50%;
|
@@ -327,12 +304,12 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
327
304
|
cursor: pointer;
|
328
305
|
transition: background-color 0.3s, transform 0.3s;
|
329
306
|
}
|
330
|
-
.${
|
307
|
+
.${N} button.active {
|
331
308
|
background-color: white;
|
332
309
|
transform: scale(1.2);
|
333
310
|
}
|
334
311
|
|
335
|
-
.${
|
312
|
+
.${N}.fraction {
|
336
313
|
position: absolute;
|
337
314
|
bottom: 1rem;
|
338
315
|
left: 50%;
|
@@ -344,7 +321,7 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
344
321
|
gap: 0.25rem;
|
345
322
|
}
|
346
323
|
|
347
|
-
.${
|
324
|
+
.${N}.progressbar {
|
348
325
|
position: absolute;
|
349
326
|
bottom: 0.5rem;
|
350
327
|
left: 0;
|
@@ -352,84 +329,84 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
352
329
|
height: 0.25rem;
|
353
330
|
background-color: rgba(255, 255, 255, 0.2);
|
354
331
|
}
|
355
|
-
.${
|
332
|
+
.${N}.progressbar .progress {
|
356
333
|
height: 100%;
|
357
334
|
background-color: white;
|
358
335
|
transition: width 0.3s;
|
359
336
|
}
|
360
|
-
`,
|
337
|
+
`,Z=g(D??{});return m(`Swiper`,e`
|
361
338
|
<style>
|
362
|
-
${
|
339
|
+
${X}
|
363
340
|
</style>
|
364
341
|
|
365
342
|
<div
|
366
|
-
${
|
367
|
-
class="${
|
343
|
+
${n(e=>{e?Z.bind(e):Z.unbindAll()})}
|
344
|
+
class="${O}"
|
368
345
|
>
|
369
|
-
<div class="${
|
370
|
-
${
|
371
|
-
<div class="${
|
346
|
+
<div class="${k}">
|
347
|
+
${P.map((t,n)=>e`
|
348
|
+
<div class="${A} --slide-${n}" key=${n}>
|
372
349
|
${t}
|
373
350
|
</div>
|
374
351
|
`)}
|
375
352
|
</div>
|
376
353
|
|
377
|
-
${
|
378
|
-
${
|
379
|
-
${
|
380
|
-
${
|
354
|
+
${_?te:null}
|
355
|
+
${y&&b===`dots`?J:null}
|
356
|
+
${y&&b===`fraction`?Y:null}
|
357
|
+
${y&&b===`progressbar`?ee:null}
|
381
358
|
</div>
|
382
|
-
`)}function
|
359
|
+
`)}function M(t,r){let a=t?.top?`top: ${t.top};`:``,o=t?.right?`right: ${t.right};`:``,c=t?.bottom?`bottom: ${t.bottom};`:``,l=t?.left?`left: ${t.left};`:``,u=t?.width?`width: ${t.width};`:``,d=t?.height?`height: ${t.height};`:``,f=typeof t?.zIndex==`number`?`z-index: ${t.zIndex};`:``,p=t?.style?t.style:``,m=t?.className?t.className:``,h=g(t?.on??{}),_=t=>e`
|
383
360
|
<div
|
384
|
-
${
|
385
|
-
class="${
|
361
|
+
${n(e=>{e?h.bind(e):h.unbindAll()})}
|
362
|
+
class="${m}"
|
386
363
|
style="
|
387
364
|
position: absolute;
|
388
|
-
${
|
389
|
-
${
|
390
|
-
${
|
391
|
-
${
|
365
|
+
${a} ${o} ${c} ${l}
|
366
|
+
${u} ${d}
|
367
|
+
${f}
|
368
|
+
${p}
|
392
369
|
"
|
393
370
|
>
|
394
|
-
${
|
371
|
+
${i(t)}
|
395
372
|
</div>
|
396
|
-
`;return
|
373
|
+
`;return s(r,_)}function N(t,r){let i=t?.width??`300px`,a=t?.height??`auto`,o=t?.top??`20%`,s=t?.bottom??`auto`,l=t?.left??`50%`,u=t?.right??`auto`,d=l===`auto`?``:`transform: translateX(-50%);`,f=t?.background??`rgba(255, 255, 255, 0.3)`,p=t?.blur??`10px`,m=t?.borderRadius??`12px`,h=t?.padding??`16px`,_=t?.zIndex??1e3,v=g(t?.on??{}),y=t=>e`
|
397
374
|
<div
|
398
|
-
${
|
375
|
+
${n(e=>{e?v.bind(e):v.unbindAll()})}
|
399
376
|
style="
|
400
377
|
position: fixed;
|
401
|
-
top: ${
|
402
|
-
bottom: ${
|
403
|
-
left: ${
|
404
|
-
right: ${
|
405
|
-
${
|
406
|
-
width: ${
|
407
|
-
height: ${
|
408
|
-
background: ${
|
409
|
-
backdrop-filter: blur(${
|
410
|
-
-webkit-backdrop-filter: blur(${
|
411
|
-
border-radius: ${
|
412
|
-
padding: ${
|
378
|
+
top: ${o};
|
379
|
+
bottom: ${s};
|
380
|
+
left: ${l};
|
381
|
+
right: ${u};
|
382
|
+
${d}
|
383
|
+
width: ${i};
|
384
|
+
height: ${a};
|
385
|
+
background: ${f};
|
386
|
+
backdrop-filter: blur(${p});
|
387
|
+
-webkit-backdrop-filter: blur(${p});
|
388
|
+
border-radius: ${m};
|
389
|
+
padding: ${h};
|
413
390
|
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
|
414
|
-
z-index: ${
|
391
|
+
z-index: ${_};
|
415
392
|
display: flex;
|
416
393
|
flex-direction: column;
|
417
394
|
"
|
418
395
|
>
|
419
396
|
${t}
|
420
397
|
</div>
|
421
|
-
`;return
|
398
|
+
`;return c(r,void 0,y)}function P(t,r){if(r===void 0)return n=>P(t,n??[e``]);let i=`${100/t.ratio}%`,o=t.maxWidth?`max-width: ${t.maxWidth};`:``,s=t.background?`background: ${t.background};`:``,c=t.overflow??`hidden`,l=g(t.on??{});return e`
|
422
399
|
<div
|
423
|
-
${
|
400
|
+
${n(e=>{e?l.bind(e):l.unbindAll()})}
|
424
401
|
style="
|
425
402
|
position: relative;
|
426
403
|
width: 100%;
|
427
|
-
${
|
428
|
-
${
|
429
|
-
overflow: ${
|
404
|
+
${o}
|
405
|
+
${s}
|
406
|
+
overflow: ${c};
|
430
407
|
"
|
431
408
|
>
|
432
|
-
<div style="width: 100%; padding-top: ${
|
409
|
+
<div style="width: 100%; padding-top: ${i};"></div>
|
433
410
|
<div
|
434
411
|
style="
|
435
412
|
position: absolute;
|
@@ -439,34 +416,34 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
439
416
|
height: 100%;
|
440
417
|
"
|
441
418
|
>
|
442
|
-
${
|
419
|
+
${a(r)}
|
443
420
|
</div>
|
444
421
|
</div>
|
445
|
-
`}function
|
446
|
-
.${
|
422
|
+
`}function F(t,r){if(r===void 0){let n=e=>F(t,e);return n.html=(n,...r)=>F(t,e(n,...r)),n}let a=p(`AutoFitGrid`),o=d(`AutoFitGrid::auto-fit-grid`)+`-lyco-now-`+a,s=t?.gap??`16px`,c=`
|
423
|
+
.${o} {
|
447
424
|
display: grid;
|
448
425
|
grid-template-columns: repeat(auto-fit, minmax(${t.minItemWidth}, 1fr));
|
449
|
-
gap: ${
|
426
|
+
gap: ${s};
|
450
427
|
}
|
451
|
-
`,
|
428
|
+
`,l=g(t.on??{});return m(`AutoFitGrid`,e`
|
452
429
|
<style>
|
453
|
-
${
|
430
|
+
${c}
|
454
431
|
</style>
|
455
432
|
<div
|
456
|
-
class="${
|
457
|
-
${
|
433
|
+
class="${o}"
|
434
|
+
${n(e=>{e?l.bind(e):l.unbindAll()})}
|
458
435
|
>
|
459
|
-
${
|
436
|
+
${i(r)}
|
460
437
|
</div>
|
461
|
-
`)}function
|
438
|
+
`)}function I(t,r){if(r===void 0)return n=>I(t,n??[e``]);let i=t?.size??`32px`,o=t?.overlap??`-8px`,s=g(t?.on??{}),c=(t,n)=>e`
|
462
439
|
<div
|
463
440
|
style="
|
464
|
-
width: ${
|
465
|
-
height: ${
|
441
|
+
width: ${i};
|
442
|
+
height: ${i};
|
466
443
|
border-radius: 50%;
|
467
444
|
overflow: hidden;
|
468
445
|
border: 2px solid #fff;
|
469
|
-
margin-left: ${n===0?`0`:
|
446
|
+
margin-left: ${n===0?`0`:o};
|
470
447
|
box-sizing: content-box;
|
471
448
|
"
|
472
449
|
>
|
@@ -474,137 +451,137 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
474
451
|
</div>
|
475
452
|
`;return e`
|
476
453
|
<div
|
477
|
-
${
|
454
|
+
${n(e=>{e?s.bind(e):s.unbindAll()})}
|
478
455
|
style="display: flex; align-items: center;"
|
479
456
|
>
|
480
|
-
${
|
457
|
+
${a(r,c)}
|
481
458
|
</div>
|
482
|
-
`}function
|
459
|
+
`}function L(t,r){if(r===void 0){let n=n=>L(t,n??e``);return n.html=(n,...r)=>L(t,e(n,...r)),n}let a=t?.position??`top-right`,o=t?.size??`16px`,s=t?.background??`red`,c=t?.color??`#fff`,[l,u,d,f]=[a.includes(`top`)?`0`:`auto`,a.includes(`right`)?`0`:`auto`,a.includes(`bottom`)?`0`:`auto`,a.includes(`left`)?`0`:`auto`],p=g(t?.on??{});return e`
|
483
460
|
<div style="position: relative; display: inline-block;">
|
484
|
-
${
|
461
|
+
${i(r)}
|
485
462
|
<div
|
486
|
-
${
|
463
|
+
${n(e=>{e?p.bind(e):p.unbindAll()})}
|
487
464
|
style="
|
488
465
|
position: absolute;
|
489
|
-
top: ${
|
490
|
-
right: ${
|
491
|
-
bottom: ${
|
492
|
-
left: ${
|
493
|
-
width: ${
|
494
|
-
height: ${
|
495
|
-
background: ${
|
496
|
-
color: ${
|
497
|
-
font-size: calc(${
|
466
|
+
top: ${l};
|
467
|
+
right: ${u};
|
468
|
+
bottom: ${d};
|
469
|
+
left: ${f};
|
470
|
+
width: ${o};
|
471
|
+
height: ${o};
|
472
|
+
background: ${s};
|
473
|
+
color: ${c};
|
474
|
+
font-size: calc(${o} * 0.6);
|
498
475
|
border-radius: 50%;
|
499
476
|
display: flex;
|
500
477
|
justify-content: center;
|
501
478
|
align-items: center;
|
502
|
-
transform: translate(${
|
479
|
+
transform: translate(${f===`0`?`-50%`:`0`}, ${l===`0`?`-50%`:`0`});
|
503
480
|
"
|
504
481
|
>
|
505
482
|
${t?.content??``}
|
506
483
|
</div>
|
507
484
|
</div>
|
508
|
-
`}function
|
485
|
+
`}function R(e,t){return e?n=>{typeof e==`function`?e(n):e.current=n,typeof t==`function`?t(n):t.current=n}:t}function z(r,i){if(!i)return e=>z(r,e??t());let a=g(r?.on??{}),o=R(i,e=>{e?a.bind(e):a.unbindAll()});return e`
|
509
486
|
<canvas
|
510
|
-
${
|
511
|
-
.class=${
|
512
|
-
style=${
|
487
|
+
${n(o)}
|
488
|
+
.class=${r?.className}
|
489
|
+
style=${r?.style??``}
|
513
490
|
></canvas>
|
514
|
-
`}function
|
491
|
+
`}function B(t,r){if(r===void 0)return n=>B(t,n??[e``]);let i=t?.padding??`16px`,o=t?.borderRadius??`8px`,s=t?.shadow??`0 2px 8px rgba(0,0,0,0.1)`,c=t?.background??`#fff`,l=g(t?.on??{});return e`
|
515
492
|
<div
|
516
|
-
${
|
493
|
+
${n(e=>{e?l.bind(e):l.unbindAll()})}
|
517
494
|
style="
|
518
|
-
background: ${
|
519
|
-
border-radius: ${
|
520
|
-
box-shadow: ${
|
521
|
-
padding: ${
|
495
|
+
background: ${c};
|
496
|
+
border-radius: ${o};
|
497
|
+
box-shadow: ${s};
|
498
|
+
padding: ${i};
|
522
499
|
box-sizing: border-box;
|
523
500
|
"
|
524
501
|
>
|
525
|
-
${
|
502
|
+
${a(r)}
|
526
503
|
</div>
|
527
|
-
`}function
|
504
|
+
`}function V(t,r){if(r===void 0){let n=n=>V(t,n??e``);return n.html=(n,...r)=>V(t,e(n,...r)),n}let a=t?.width?`width: ${t.width};`:``,o=t?.height?`height: ${t.height};`:``,s=t?.background?`background: ${t.background};`:``,c=g(t?.on??{});return e`
|
528
505
|
<div
|
529
|
-
${
|
506
|
+
${n(e=>{e?c.bind(e):c.unbindAll()})}
|
530
507
|
style="
|
531
508
|
display: flex;
|
532
509
|
justify-content: center;
|
533
510
|
align-items: center;
|
534
|
-
${
|
511
|
+
${a} ${o} ${s}
|
535
512
|
"
|
536
513
|
>
|
537
|
-
${
|
514
|
+
${i(r)}
|
538
515
|
</div>
|
539
|
-
`}function
|
516
|
+
`}function H(t,r){if(r===void 0)return n=>H(t,n??[e``]);let i=t?.maxWidth??`1024px`,o=t?.padding??`0 16px`,s=t?.background?`background: ${t.background};`:``,c=t?.fullHeight?`height: 100%;`:``,l=g(t?.on??{});return e`
|
540
517
|
<div
|
541
|
-
${
|
518
|
+
${n(e=>{e?l.bind(e):l.unbindAll()})}
|
542
519
|
style="
|
543
520
|
width: 100%;
|
544
|
-
max-width: ${
|
521
|
+
max-width: ${i};
|
545
522
|
margin-left: auto;
|
546
523
|
margin-right: auto;
|
547
|
-
padding: ${
|
548
|
-
${
|
549
|
-
${
|
524
|
+
padding: ${o};
|
525
|
+
${s}
|
526
|
+
${c}
|
550
527
|
box-sizing: border-box;
|
551
528
|
"
|
552
529
|
>
|
553
|
-
${
|
530
|
+
${a(r)}
|
554
531
|
</div>
|
555
|
-
`}function
|
556
|
-
${
|
557
|
-
style="${
|
558
|
-
></div>`}function
|
532
|
+
`}function U(t){let r=t?.orientation??`horizontal`,i=t?.thickness??`1px`,a=t?.color??`#e0e0e0`,o=t?.margin??(r===`horizontal`?`8px 0`:`0 8px`),s=g(t?.on??{}),c=r===`horizontal`?`width: 100%; height: ${i}; background: ${a}; margin: ${o};`:`width: ${i}; height: 100%; background: ${a}; margin: ${o};`;return e`<div
|
533
|
+
${n(e=>{e?s.bind(e):s.unbindAll()})}
|
534
|
+
style="${c}"
|
535
|
+
></div>`}function W(t,r){if(r===void 0){let n=n=>W(t,n??e``);return n.html=(n,...r)=>W(t,e(n,...r)),n}let a=t?.columns??4,o=t?.gap??`24px`,s=t?.background??`#f8f8f8`,c=t?.padding??`40px 16px`,l=g(t?.on??{});return e`
|
559
536
|
<div
|
560
|
-
${
|
537
|
+
${n(e=>{e?l.bind(e):l.unbindAll()})}
|
561
538
|
style="
|
562
539
|
width: 100%;
|
563
|
-
background: ${
|
564
|
-
padding: ${
|
540
|
+
background: ${s};
|
541
|
+
padding: ${c};
|
565
542
|
box-sizing: border-box;
|
566
543
|
"
|
567
544
|
>
|
568
545
|
<div
|
569
546
|
style="
|
570
547
|
display: grid;
|
571
|
-
grid-template-columns: repeat(${
|
572
|
-
gap: ${
|
548
|
+
grid-template-columns: repeat(${a}, 1fr);
|
549
|
+
gap: ${o};
|
573
550
|
"
|
574
551
|
>
|
575
|
-
${
|
552
|
+
${i(r)}
|
576
553
|
</div>
|
577
554
|
<div style="text-align: center; margin-top: 24px; color: #666;">
|
578
555
|
© ${new Date().getFullYear()} Your Company. All rights reserved.
|
579
556
|
</div>
|
580
557
|
</div>
|
581
|
-
`}function
|
582
|
-
`+
|
558
|
+
`}function G(e,t){return t?e.map((e,n)=>t(e,n)):t=>e.map((e,n)=>t(e,n))}function K(t,r){if(r===void 0){let n=n=>K(t,n??e``);return n.html=(n,...r)=>K(t,e(n,...r)),n}let a=t.defaultColumns??1,o=t.gap??`16px`,s=p(`GridBreakpoint`),c=t.className??d(`GridBreakpoint::grid-breakpoint`)+`-lyco-now-`+s,l=Object.entries(t.breakpoints).map(([e,t])=>`@media`+e+`{
|
559
|
+
`+c+`{ grid-template-columns: repeat(`+t+`, 1fr); }
|
583
560
|
}`).join(`
|
584
|
-
`),
|
585
|
-
.${
|
561
|
+
`),u=`
|
562
|
+
.${c} {
|
586
563
|
display: grid;
|
587
|
-
grid-template-columns: repeat(${
|
588
|
-
gap: ${
|
564
|
+
grid-template-columns: repeat(${a}, 1fr);
|
565
|
+
gap: ${o};
|
589
566
|
}
|
590
|
-
${
|
567
|
+
${l}`,f=g(t?.on??{});return m(`GridBreakpoint`,e`
|
591
568
|
<style>
|
592
|
-
${
|
569
|
+
${u}
|
593
570
|
</style>
|
594
571
|
<div
|
595
|
-
${
|
596
|
-
class="${
|
572
|
+
${n(e=>{e?f.bind(e):f.unbindAll()})}
|
573
|
+
class="${c}"
|
597
574
|
>
|
598
|
-
${
|
575
|
+
${i(r)}
|
599
576
|
</div>
|
600
|
-
`)}function
|
577
|
+
`)}function q(t,r){if(r===void 0)return n=>q(t,n??[e``]);let i=t?.backgroundImage?`background-image: url('${t.backgroundImage}');`:``,o=t?.height??`400px`,s=t?.overlayColor??`rgba(0, 0, 0, 0.3)`,c=g(t?.on??{});return e`
|
601
578
|
<div
|
602
|
-
${
|
579
|
+
${n(e=>{e?c.bind(e):c.unbindAll()})}
|
603
580
|
style="
|
604
581
|
position: relative;
|
605
582
|
width: 100%;
|
606
|
-
height: ${
|
607
|
-
${
|
583
|
+
height: ${o};
|
584
|
+
${i}
|
608
585
|
background-size: cover;
|
609
586
|
background-position: center;
|
610
587
|
"
|
@@ -613,7 +590,7 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
613
590
|
style="
|
614
591
|
position: absolute;
|
615
592
|
top: 0; left: 0; right: 0; bottom: 0;
|
616
|
-
background: ${
|
593
|
+
background: ${s};
|
617
594
|
"
|
618
595
|
></div>
|
619
596
|
<div
|
@@ -632,194 +609,194 @@ const{I:re}=te,ie=e=>e===null||typeof e!=`object`&&typeof e!=`function`,ae={HTML
|
|
632
609
|
box-sizing: border-box;
|
633
610
|
"
|
634
611
|
>
|
635
|
-
${
|
612
|
+
${a(r)}
|
636
613
|
</div>
|
637
614
|
</div>
|
638
|
-
`}function
|
639
|
-
@media not ${
|
640
|
-
.${
|
615
|
+
`}function J(t,r){if(r===void 0){let n=n=>J(t,n??e``);return n.html=(n,...r)=>J(t,e(n,...r)),n}let a=t?.breakpoint??`(max-width: 600px)`,o=t?.mode??`hide`,s=p(`Hidden`),c=t?.className??d(`Hidden::hidden-container`)+`-lyco-now-`+s,l=o===`hide`?`@media ${a} { .${c} { display: none !important; } }`:`@media ${a} { .${c} { display: block !important; } }
|
616
|
+
@media not ${a} { .${c} { display: none !important; } }`,u=`
|
617
|
+
.${c} {
|
641
618
|
display: block;
|
642
619
|
}
|
643
|
-
${
|
620
|
+
${l}`,f=g(t?.on??{});return m(`Hidden`,e`
|
644
621
|
<style>
|
645
|
-
${
|
622
|
+
${u}
|
646
623
|
</style>
|
647
624
|
<div
|
648
|
-
${
|
649
|
-
class="${
|
625
|
+
${n(e=>{e?f.bind(e):f.unbindAll()})}
|
626
|
+
class="${c}"
|
650
627
|
>
|
651
|
-
${
|
628
|
+
${i(r)}
|
652
629
|
</div>
|
653
|
-
`)}function
|
654
|
-
ul.${
|
630
|
+
`)}function Y(t){return e` <li>${a(t)}</li> `}function ee(t,n){let r=t?.bordered?`border: 1px solid #ddd; border-radius: 4px`:``,i=t?.striped?`li:nth-child(even) { background: #f9f9f9; }`:``,o=t?.hover?`li:hover { background: #f1f1f1; cursor: pointer; }`:``,s=p(`List`),c=t?.className??d(`List::list`)+`-lyco-now-${s}`,l=`
|
631
|
+
ul.${c} {
|
655
632
|
list-style: none;
|
656
633
|
margin: 0;
|
657
634
|
padding: 0;
|
658
635
|
${r};
|
659
636
|
}
|
660
|
-
ul.${
|
637
|
+
ul.${c} li {
|
661
638
|
padding: 12px 16px;
|
662
639
|
${t?.bordered?`border-bottom: 1px solid #ddd`:``};
|
663
640
|
}
|
664
|
-
ul.${
|
641
|
+
ul.${c} li:last-child {
|
665
642
|
${t?.bordered?`border-bottom: none`:``};
|
666
643
|
}
|
667
644
|
${i}
|
668
|
-
${
|
669
|
-
`.toString(),
|
645
|
+
${o}
|
646
|
+
`.toString(),u=t=>m(`List`,e`
|
670
647
|
<style>
|
671
|
-
${
|
648
|
+
${l}
|
672
649
|
</style>
|
673
|
-
<ul class="${
|
674
|
-
${
|
650
|
+
<ul class="${c}">
|
651
|
+
${a(t)}
|
675
652
|
</ul>
|
676
|
-
`);return n===void 0?
|
677
|
-
ul.${
|
653
|
+
`);return n===void 0?u:u(n)}function te(t,r){let i=t?.bordered?`border: 1px solid #ddd; border-radius: 4px`:``,o=t?.striped?`li:nth-child(even) { background: #f9f9f9; }`:``,s=t?.hover?`li:hover { background: #f1f1f1; cursor: pointer; }`:``,l=p(`ListGroup`),u=t?.className??d(`ListGroup::list-group`)+`-lyco-now-`+l,f=(t,n,r,i)=>r?e` <li>${t}</li> `:t,h=`
|
654
|
+
ul.${u} {
|
678
655
|
list-style: none;
|
679
656
|
margin: 0;
|
680
657
|
padding: 0;
|
681
|
-
${
|
658
|
+
${i};
|
682
659
|
}
|
683
|
-
ul.${
|
660
|
+
ul.${u} li {
|
684
661
|
padding: 12px 16px;
|
685
662
|
${t?.bordered?`border-bottom: 1px solid #ddd`:``};
|
686
663
|
}
|
687
|
-
ul.${
|
664
|
+
ul.${u} li:last-child {
|
688
665
|
${t?.bordered?`border-bottom: none`:``};
|
689
666
|
}
|
690
|
-
${
|
691
|
-
${
|
692
|
-
`,
|
667
|
+
${o}
|
668
|
+
${s}
|
669
|
+
`,_=g(t?.on??{}),v=t=>m(`ListGroup`,e`
|
693
670
|
<style>
|
694
|
-
${
|
671
|
+
${h}
|
695
672
|
</style>
|
696
673
|
<ul
|
697
|
-
${
|
698
|
-
class="${
|
674
|
+
${n(e=>{e?_.bind(e):_.unbindAll()})}
|
675
|
+
class="${u}"
|
699
676
|
>
|
700
|
-
${
|
677
|
+
${a(t,f)}
|
701
678
|
</ul>
|
702
|
-
`);return
|
679
|
+
`);return c(r,v)}function X(t,r){if(r===void 0)return n=>X(t,n??[e``]);let i=t?.background??`rgba(0, 0, 0, 0.5)`,o=t?.zIndex??1e3,s=t?.fullScreen!==!1,c=g(t?.on??{});return e`
|
703
680
|
<div
|
704
|
-
${
|
681
|
+
${n(e=>{e?c.bind(e):c.unbindAll()})}
|
705
682
|
style="
|
706
|
-
position: ${
|
683
|
+
position: ${s?`fixed`:`absolute`};
|
707
684
|
top: 0; left: 0; right: 0; bottom: 0;
|
708
|
-
background: ${
|
709
|
-
z-index: ${
|
685
|
+
background: ${i};
|
686
|
+
z-index: ${o};
|
710
687
|
display: flex;
|
711
688
|
justify-content: center;
|
712
689
|
align-items: center;
|
713
690
|
"
|
714
691
|
>
|
715
|
-
${
|
692
|
+
${a(r)}
|
716
693
|
</div>
|
717
|
-
`}function
|
694
|
+
`}function Z(t,r){if(r===void 0){let n=n=>Z(t,n??e``);return n.html=(n,...r)=>Z(t,e(n,...r)),n}let a=t?.width?`width: ${t.width};`:``,o=t?.height?`height: ${t.height};`:``,s=t?.background?`background: ${t.background};`:``,c=g(t?.on??{});return e`
|
718
695
|
<div
|
719
|
-
${
|
696
|
+
${n(e=>{e?c.bind(e):c.unbindAll()})}
|
720
697
|
style="
|
721
698
|
position: relative;
|
722
|
-
${
|
699
|
+
${a} ${o} ${s}
|
723
700
|
overflow: hidden;
|
724
701
|
"
|
725
702
|
>
|
726
|
-
${
|
703
|
+
${i(r)}
|
727
704
|
</div>
|
728
|
-
`}function
|
729
|
-
${
|
730
|
-
style="${
|
731
|
-
></div>`}function
|
705
|
+
`}function ne(t){let r=t?.width?`width: ${t.width};`:``,i=t?.height?`height: ${t.height};`:``,a=g(t?.on??{});return e`<div
|
706
|
+
${n(e=>{e?a.bind(e):a.unbindAll()})}
|
707
|
+
style="${r} ${i}"
|
708
|
+
></div>`}function re(t){let r=t?.type??`rect`,i=t?.width??`100%`,a=t?.height??`16px`,o=t?.borderRadius??`4px`,s=t?.animation!==!1,c=p(`SkeletonLoader`),l=t?.className??d(`SkeletonLoader::skeleton-shimmer`)+`-lyco-now-`+c,u=r===`circle`?`border-radius: 50%; width: ${i}; height: ${i}`:`border-radius: ${o}; width: ${i}; height: ${a}`,f=g(t?.on??{});return m(`SkeletonLoader`,e`
|
732
709
|
<style>
|
733
710
|
${`
|
734
|
-
@keyframes ${
|
711
|
+
@keyframes ${l+`-shimmer`} {
|
735
712
|
0% { background-color: #eee; }
|
736
713
|
50% { background-color: #ddd; }
|
737
714
|
100% { background-color: #eee; }
|
738
715
|
}
|
739
716
|
`}
|
740
|
-
.${
|
741
|
-
${
|
717
|
+
.${l} {
|
718
|
+
${u};
|
742
719
|
background-color: #eee;
|
743
|
-
${
|
720
|
+
${s?`animation: ${l+`-shimmer`} 1.2s infinite ease-in-out`:``};
|
744
721
|
}
|
745
722
|
</style>
|
746
723
|
<div
|
747
|
-
${
|
748
|
-
class="${
|
724
|
+
${n(e=>{e?f.bind(e):f.unbindAll()})}
|
725
|
+
class="${l}"
|
749
726
|
></div>
|
750
|
-
`)}function
|
751
|
-
${
|
727
|
+
`)}function ie(t){let r=g(t?.on??{});return e`<div
|
728
|
+
${n(e=>{e?r.bind(e):r.unbindAll()})}
|
752
729
|
style="flex: 1 1 auto;"
|
753
|
-
></div>`}function
|
730
|
+
></div>`}function Q(t,r){if(r===void 0){let n=n=>Q(t,n??e``);return n.html=(n,...r)=>Q(t,e(n,...r)),n}let a=t?.top?`top: ${t.top};`:``,o=t?.bottom?`bottom: ${t.bottom};`:``,s=typeof t?.zIndex==`number`?`z-index: ${t.zIndex};`:``,c=g(t?.on??{});return e`
|
754
731
|
<div
|
755
|
-
${
|
732
|
+
${n(e=>{e?c.bind(e):c.unbindAll()})}
|
756
733
|
style="
|
757
734
|
position: sticky;
|
758
|
-
${
|
759
|
-
${
|
735
|
+
${a} ${o}
|
736
|
+
${s}
|
760
737
|
"
|
761
738
|
>
|
762
|
-
${
|
739
|
+
${i(r)}
|
763
740
|
</div>
|
764
|
-
`}function
|
765
|
-
.${
|
766
|
-
`:``,
|
767
|
-
.${
|
768
|
-
`:``,
|
769
|
-
.${
|
770
|
-
`:``,
|
741
|
+
`}function $(t,r){if(r===void 0){let n=n=>$(t,n??e``);return n.html=(n,...r)=>$(t,e(n,...r)),n}let a=p(`Table`),o=t?.className??d(`Table::table`)+`-lyco-now-${a}`,s=t?.striped?`
|
742
|
+
.${o} tr:nth-child(even) { background: #f9f9f9; }
|
743
|
+
`:``,c=t?.hover?`
|
744
|
+
.${o} tr:hover { background: #f1f1f1; }
|
745
|
+
`:``,l=t?.bordered?`
|
746
|
+
.${o}, .${o} th, .${o} td { border: 1px solid #ddd; }
|
747
|
+
`:``,u=`
|
771
748
|
/* 将表格包裹在带有 _className 的 div 里,使后续 CSS 作用于该 div 下的 table */
|
772
|
-
.${
|
749
|
+
.${o} table {
|
773
750
|
width: 100%;
|
774
751
|
border-collapse: collapse;
|
775
752
|
}
|
776
|
-
.${
|
777
|
-
.${
|
753
|
+
.${o} th,
|
754
|
+
.${o} td {
|
778
755
|
padding: 8px 12px;
|
779
756
|
text-align: left;
|
780
757
|
}
|
781
|
-
${a}
|
782
|
-
${o}
|
783
758
|
${s}
|
784
|
-
|
759
|
+
${c}
|
760
|
+
${l}
|
761
|
+
`,f=g(t?.on??{});return m(`Table`,e`
|
785
762
|
<style>
|
786
|
-
${
|
763
|
+
${u}
|
787
764
|
</style>
|
788
765
|
|
789
766
|
<div
|
790
|
-
${
|
791
|
-
class="${
|
767
|
+
${n(e=>{e?f.bind(e):f.unbindAll()})}
|
768
|
+
class="${o}"
|
792
769
|
>
|
793
770
|
<table>
|
794
|
-
${
|
771
|
+
${i(r)}
|
795
772
|
</table>
|
796
773
|
</div>
|
797
|
-
`)}function
|
774
|
+
`)}function ae(t,r){let i=t?.direction??`row`,o=g(t?.on??{});return r===void 0?n=>ae(t,n??e``):e`
|
798
775
|
<div
|
799
|
-
${
|
776
|
+
${n(e=>{e?o.bind(e):o.unbindAll()})}
|
800
777
|
style="
|
801
778
|
display: flex;
|
802
|
-
flex-direction: ${
|
779
|
+
flex-direction: ${i};
|
803
780
|
flex-wrap: wrap;
|
804
781
|
${t?.gap?`gap: ${t.gap};`:``}
|
805
782
|
${t?.align?`align-items: ${t.align};`:``}
|
806
783
|
${t?.justify?`justify-content: ${t.justify};`:``}
|
807
784
|
"
|
808
785
|
>
|
809
|
-
${
|
786
|
+
${a(r)}
|
810
787
|
</div>
|
811
|
-
`}function
|
788
|
+
`}function oe(t,r){let i=t?.width?`width: ${t.width};`:``,o=t?.height?`height: ${t.height};`:``,s=t?.background?`background: ${t.background};`:``,c=g(t?.on??{});if(r===void 0)return n=>oe(t,n??[e``]);let l=`flex-start`,u=`flex-start`;switch(t?.align){case`top-right`:l=`flex-end`,u=`flex-start`;break;case`center`:l=`center`,u=`center`;break;case`bottom-left`:l=`flex-start`,u=`flex-end`;break;case`bottom-right`:l=`flex-end`,u=`flex-end`;break;default:l=`flex-start`,u=`flex-start`}return e`
|
812
789
|
<div
|
813
|
-
${
|
790
|
+
${n(e=>{e?c.bind(e):c.unbindAll()})}
|
814
791
|
style="
|
815
792
|
position: relative;
|
816
793
|
display: flex;
|
817
|
-
justify-content: ${
|
818
|
-
align-items: ${
|
819
|
-
${
|
794
|
+
justify-content: ${l};
|
795
|
+
align-items: ${u};
|
796
|
+
${i} ${o} ${s}
|
820
797
|
"
|
821
798
|
>
|
822
|
-
${
|
799
|
+
${a(r)}
|
823
800
|
</div>
|
824
|
-
`}export{
|
801
|
+
`}export{M as AbsoluteBox,N as AcrylicBar,P as AspectRatio,F as AutoFitGrid,I as AvatarStack,L as Badge,z as Canvas,B as Card,V as Center,v as Column,D as ColumnSplit,H as Container,U as Divider,y as Flex,b as FlowItem,W as FooterLayout,G as ForEach,x as Grid,K as GridBreakpoint,S as GridCol,C as GridItem,w as GridRow,q as HeroSection,J as Hidden,_ as LightboxContainer,ee as List,te as ListGroup,Y as ListItem,X as Overlay,Z as PositionContainer,T as Row,O as RowSplit,k as ScrollBar,A as SideBarContainer,ne as SizedBox,re as SkeletonLoader,ie as Spacer,Q as Sticky,j as Swiper,$ as Table,E as WaterFlow,ae as Wrap,oe as ZStack};
|
825
802
|
//# sourceMappingURL=index.es.js.map
|