@fluid-topics/ft-filterable-table 1.1.12 → 1.1.13
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.
|
@@ -1118,7 +1118,7 @@ const Ke={fontSize:e.FtCssVariableFactory.create("--ft-text-field-font-size","",
|
|
|
1118
1118
|
@focusin=${this.onHover}
|
|
1119
1119
|
@focusout=${this.onOut}
|
|
1120
1120
|
@touchstart=${this.onTouch}>
|
|
1121
|
-
<slot part="slot"></slot>
|
|
1121
|
+
<slot part="slot" @click=${this.onClick}></slot>
|
|
1122
1122
|
<div part="tooltip" role="tooltip" inert
|
|
1123
1123
|
class="ft-tooltip ft-tooltip--${this.validPosition}"
|
|
1124
1124
|
?hidden=${!this.visible}>
|
|
@@ -1128,7 +1128,7 @@ const Ke={fontSize:e.FtCssVariableFactory.create("--ft-text-field-font-size","",
|
|
|
1128
1128
|
</div>
|
|
1129
1129
|
</div>
|
|
1130
1130
|
</div>
|
|
1131
|
-
`}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((e=>t.has(e)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){var t;this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",li(this.slottedElement,this.tooltip,{platform:{...ai,getOffsetParent:t=>ai.getOffsetParent(t,si)},middleware:[(t={crossAxis:!0},void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:o,y:i,placement:r}=e,{mainAxis:n=!0,crossAxis:a=!1,limiter:l={fn:t=>{let{x:e,y:o}=t;return{x:e,y:o}}},...s}=mo(t,e),c={x:o,y:i},f=await ko(e,s),p=No(xo(r)),d=Oo(p);let h=c[d],u=c[p];if(n){const t="y"===d?"bottom":"right";h=bo(h+f["y"===d?"top":"left"],h,h-f[t])}if(a){const t="y"===p?"bottom":"right";u=bo(u+f["y"===p?"top":"left"],u,u-f[t])}const g=l.fn({...e,[d]:h,[p]:u});return{...g,data:{x:g.x-o,y:g.y-i}}}}),Ro({allowedPlacements:[this.position]})]}).then((({x:t,y:e})=>{this.tooltip&&(this.tooltip.style.left=`${t}px`,this.tooltip.style.top=`${e}px`)}))),this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}correctOutOfWindowPixels(t,e){return Math.max(t,Math.min(0,-e))}}pi.elementDefinitions={"ft-typography":se},pi.styles=lo,fi([i.property()],pi.prototype,"text",void 0),fi([i.property({type:Boolean})],pi.prototype,"manual",void 0),fi([i.property({type:Boolean})],pi.prototype,"inline",void 0),fi([i.property({type:Number})],pi.prototype,"delay",void 0),fi([i.property()],pi.prototype,"position",void 0),fi([i.queryAssignedNodes()],pi.prototype,"slotNodes",void 0),fi([i.query(".ft-tooltip--container")],pi.prototype,"container",void 0),fi([i.query(".ft-tooltip")],pi.prototype,"tooltip",void 0),fi([i.query(".ft-tooltip--content")],pi.prototype,"tooltipContent",void 0),fi([i.state()],pi.prototype,"visible",void 0),fi([i.eventOptions({passive:!0})],pi.prototype,"onTouch",null),fi([i.eventOptions({passive:!0})],pi.prototype,"onHover",null),fi([i.eventOptions({passive:!0})],pi.prototype,"onOut",null),e.customElement("ft-tooltip")(pi);class di extends e.FtLitElement{render(){return o.html`
|
|
1131
|
+
`}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((e=>t.has(e)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){var t;this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",li(this.slottedElement,this.tooltip,{platform:{...ai,getOffsetParent:t=>ai.getOffsetParent(t,si)},middleware:[(t={crossAxis:!0},void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:o,y:i,placement:r}=e,{mainAxis:n=!0,crossAxis:a=!1,limiter:l={fn:t=>{let{x:e,y:o}=t;return{x:e,y:o}}},...s}=mo(t,e),c={x:o,y:i},f=await ko(e,s),p=No(xo(r)),d=Oo(p);let h=c[d],u=c[p];if(n){const t="y"===d?"bottom":"right";h=bo(h+f["y"===d?"top":"left"],h,h-f[t])}if(a){const t="y"===p?"bottom":"right";u=bo(u+f["y"===p?"top":"left"],u,u-f[t])}const g=l.fn({...e,[d]:h,[p]:u});return{...g,data:{x:g.x-o,y:g.y-i}}}}),Ro({allowedPlacements:[this.position]})]}).then((({x:t,y:e})=>{this.tooltip&&(this.tooltip.style.left=`${t}px`,this.tooltip.style.top=`${e}px`)}))),this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}onClick(){this.manual||(this.revealDebouncer.cancel(),this.hide())}correctOutOfWindowPixels(t,e){return Math.max(t,Math.min(0,-e))}}pi.elementDefinitions={"ft-typography":se},pi.styles=lo,fi([i.property()],pi.prototype,"text",void 0),fi([i.property({type:Boolean})],pi.prototype,"manual",void 0),fi([i.property({type:Boolean})],pi.prototype,"inline",void 0),fi([i.property({type:Number})],pi.prototype,"delay",void 0),fi([i.property()],pi.prototype,"position",void 0),fi([i.queryAssignedNodes()],pi.prototype,"slotNodes",void 0),fi([i.query(".ft-tooltip--container")],pi.prototype,"container",void 0),fi([i.query(".ft-tooltip")],pi.prototype,"tooltip",void 0),fi([i.query(".ft-tooltip--content")],pi.prototype,"tooltipContent",void 0),fi([i.state()],pi.prototype,"visible",void 0),fi([i.eventOptions({passive:!0})],pi.prototype,"onTouch",null),fi([i.eventOptions({passive:!0})],pi.prototype,"onHover",null),fi([i.eventOptions({passive:!0})],pi.prototype,"onOut",null),fi([i.eventOptions({passive:!0})],pi.prototype,"onClick",null),e.customElement("ft-tooltip")(pi);class di extends e.FtLitElement{render(){return o.html`
|
|
1132
1132
|
<div class="ft-loader">
|
|
1133
1133
|
<div></div>
|
|
1134
1134
|
<div></div>
|
|
@@ -1263,7 +1263,7 @@ const ar={fontSize:$e.create("--ft-text-field-font-size","","SIZE","14px"),label
|
|
|
1263
1263
|
@focusin=${this.onHover}
|
|
1264
1264
|
@focusout=${this.onOut}
|
|
1265
1265
|
@touchstart=${this.onTouch}>
|
|
1266
|
-
<slot part="slot"></slot>
|
|
1266
|
+
<slot part="slot" @click=${this.onClick}></slot>
|
|
1267
1267
|
<div part="tooltip" role="tooltip" inert
|
|
1268
1268
|
class="ft-tooltip ft-tooltip--${this.validPosition}"
|
|
1269
1269
|
?hidden=${!this.visible}>
|
|
@@ -1273,7 +1273,7 @@ const ar={fontSize:$e.create("--ft-text-field-font-size","","SIZE","14px"),label
|
|
|
1273
1273
|
</div>
|
|
1274
1274
|
</div>
|
|
1275
1275
|
</div>
|
|
1276
|
-
`}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((e=>t.has(e)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){var t;this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",In(this.slottedElement,this.tooltip,{platform:{...Un,getOffsetParent:t=>Un.getOffsetParent(t,Ln)},middleware:[(t={crossAxis:!0},void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:o,y:i,placement:r}=e,{mainAxis:n=!0,crossAxis:a=!1,limiter:s={fn:t=>{let{x:e,y:o}=t;return{x:e,y:o}}},...l}=Mr(t,e),c={x:o,y:i},f=await qr(e,l),p=_r(Pr(r)),d=jr(p);let h=c[d],u=c[p];if(n){const t="y"===d?"bottom":"right";h=Ar(h+f["y"===d?"top":"left"],h,h-f[t])}if(a){const t="y"===p?"bottom":"right";u=Ar(u+f["y"===p?"top":"left"],u,u-f[t])}const y=s.fn({...e,[d]:h,[p]:u});return{...y,data:{x:y.x-o,y:y.y-i}}}}),Qr({allowedPlacements:[this.position]})]}).then((({x:t,y:e})=>{this.tooltip&&(this.tooltip.style.left=`${t}px`,this.tooltip.style.top=`${e}px`)}))),this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}correctOutOfWindowPixels(t,e){return Math.max(t,Math.min(0,-e))}}Fn.elementDefinitions={"ft-typography":Li},Fn.styles=Ir,zn([N()],Fn.prototype,"text",void 0),zn([N({type:Boolean})],Fn.prototype,"manual",void 0),zn([N({type:Boolean})],Fn.prototype,"inline",void 0),zn([N({type:Number})],Fn.prototype,"delay",void 0),zn([N()],Fn.prototype,"position",void 0),zn([U()],Fn.prototype,"slotNodes",void 0),zn([R(".ft-tooltip--container")],Fn.prototype,"container",void 0),zn([R(".ft-tooltip")],Fn.prototype,"tooltip",void 0),zn([R(".ft-tooltip--content")],Fn.prototype,"tooltipContent",void 0),zn([C()],Fn.prototype,"visible",void 0),zn([E({passive:!0})],Fn.prototype,"onTouch",null),zn([E({passive:!0})],Fn.prototype,"onHover",null),zn([E({passive:!0})],Fn.prototype,"onOut",null),L("ft-tooltip")(Fn);class Zn extends Be{render(){return ne`
|
|
1276
|
+
`}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((e=>t.has(e)))&&this.visible&&this.positionTooltip()}show(t){this.visible=!0,null!=t&&this.hideDebounce.run((()=>this.hide()),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){var t;this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",In(this.slottedElement,this.tooltip,{platform:{...Un,getOffsetParent:t=>Un.getOffsetParent(t,Ln)},middleware:[(t={crossAxis:!0},void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:o,y:i,placement:r}=e,{mainAxis:n=!0,crossAxis:a=!1,limiter:s={fn:t=>{let{x:e,y:o}=t;return{x:e,y:o}}},...l}=Mr(t,e),c={x:o,y:i},f=await qr(e,l),p=_r(Pr(r)),d=jr(p);let h=c[d],u=c[p];if(n){const t="y"===d?"bottom":"right";h=Ar(h+f["y"===d?"top":"left"],h,h-f[t])}if(a){const t="y"===p?"bottom":"right";u=Ar(u+f["y"===p?"top":"left"],u,u-f[t])}const y=s.fn({...e,[d]:h,[p]:u});return{...y,data:{x:y.x-o,y:y.y-i}}}}),Qr({allowedPlacements:[this.position]})]}).then((({x:t,y:e})=>{this.tooltip&&(this.tooltip.style.left=`${t}px`,this.tooltip.style.top=`${e}px`)}))),this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}onClick(){this.manual||(this.revealDebouncer.cancel(),this.hide())}correctOutOfWindowPixels(t,e){return Math.max(t,Math.min(0,-e))}}Fn.elementDefinitions={"ft-typography":Li},Fn.styles=Ir,zn([N()],Fn.prototype,"text",void 0),zn([N({type:Boolean})],Fn.prototype,"manual",void 0),zn([N({type:Boolean})],Fn.prototype,"inline",void 0),zn([N({type:Number})],Fn.prototype,"delay",void 0),zn([N()],Fn.prototype,"position",void 0),zn([U()],Fn.prototype,"slotNodes",void 0),zn([R(".ft-tooltip--container")],Fn.prototype,"container",void 0),zn([R(".ft-tooltip")],Fn.prototype,"tooltip",void 0),zn([R(".ft-tooltip--content")],Fn.prototype,"tooltipContent",void 0),zn([C()],Fn.prototype,"visible",void 0),zn([E({passive:!0})],Fn.prototype,"onTouch",null),zn([E({passive:!0})],Fn.prototype,"onHover",null),zn([E({passive:!0})],Fn.prototype,"onOut",null),zn([E({passive:!0})],Fn.prototype,"onClick",null),L("ft-tooltip")(Fn);class Zn extends Be{render(){return ne`
|
|
1277
1277
|
<div class="ft-loader">
|
|
1278
1278
|
<div></div>
|
|
1279
1279
|
<div></div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-filterable-table",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.13",
|
|
4
4
|
"description": "A dynamic table with filters",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Lit"
|
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@fluid-topics/ft-button": "1.1.
|
|
26
|
-
"@fluid-topics/ft-select": "1.1.
|
|
27
|
-
"@fluid-topics/ft-text-field": "1.1.
|
|
28
|
-
"@fluid-topics/ft-wc-utils": "1.1.
|
|
25
|
+
"@fluid-topics/ft-button": "1.1.13",
|
|
26
|
+
"@fluid-topics/ft-select": "1.1.13",
|
|
27
|
+
"@fluid-topics/ft-text-field": "1.1.13",
|
|
28
|
+
"@fluid-topics/ft-wc-utils": "1.1.13",
|
|
29
29
|
"lit": "3.1.0"
|
|
30
30
|
},
|
|
31
|
-
"gitHead": "
|
|
31
|
+
"gitHead": "6678af642af51eb1590bccbeeb0de8cbc5938ab1"
|
|
32
32
|
}
|