@fluid-topics/ft-search-bar 0.3.4 → 0.3.5
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.
|
@@ -250,7 +250,7 @@ const V=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===V)return null==t?void 0:t
|
|
|
250
250
|
</div>
|
|
251
251
|
<slot></slot>
|
|
252
252
|
</div>
|
|
253
|
-
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){t.has("visible")&&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.position){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(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2
|
|
253
|
+
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){t.has("visible")&&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.position){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(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2;let s=0,r=0;switch(this.position){case"top":r=-this.tooltip.clientHeight,s=o;break;case"bottom":r=e.height,s=o;break;case"left":r=i,s=-this.tooltip.clientWidth;break;case"right":r=i,s=e.width}e.left+s+this.tooltip.clientWidth>window.innerWidth&&(s=window.innerWidth-this.tooltip.clientWidth-e.left),e.left+s<0&&(s=0);const n=this.tooltip.style;n.left=s+"px",n.top=r+"px",n.maxWidth=Math.max(e.width,150)+"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())}}ue.elementDefinitions={"ft-typography":Yt},ue.styles=i.css`
|
|
254
254
|
.ft-tooltip--container {
|
|
255
255
|
display: block;
|
|
256
256
|
position: relative;
|
|
@@ -410,7 +410,7 @@ const V=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===V)return null==t?void 0:t
|
|
|
410
410
|
box-shadow: 0px 0px 0px transparent;
|
|
411
411
|
border: 0px solid transparent;
|
|
412
412
|
text-shadow: 0px 0px 0px transparent;
|
|
413
|
-
font-size:
|
|
413
|
+
font-size: ${Be.fontSize};
|
|
414
414
|
}
|
|
415
415
|
|
|
416
416
|
button:hover {
|
|
@@ -439,8 +439,7 @@ const V=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===V)return null==t?void 0:t
|
|
|
439
439
|
border: none;
|
|
440
440
|
pointer-events: auto;
|
|
441
441
|
|
|
442
|
-
--ft-button-internal-
|
|
443
|
-
--ft-button-internal-line-height: calc(var(--ft-button-internal-font-size) + 2px);
|
|
442
|
+
--ft-button-internal-line-height: calc(${Be.fontSize} + 2px);
|
|
444
443
|
--ft-button-internal-color: ${Be.color};
|
|
445
444
|
${e.setVariable(ke.size,Be.iconSize)};
|
|
446
445
|
--ft-button-internal-vertical-padding: 6px;
|
|
@@ -496,7 +495,7 @@ const V=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===V)return null==t?void 0:t
|
|
|
496
495
|
text-overflow: ellipsis;
|
|
497
496
|
display: block;
|
|
498
497
|
margin: 0 var(--ft-button-internal-horizontal-padding);
|
|
499
|
-
${e.setVariable(Nt.fontSize,"
|
|
498
|
+
${e.setVariable(Nt.fontSize,"1em")};
|
|
500
499
|
${e.setVariable(Nt.lineHeight,"var(--ft-button-internal-content-height)")};
|
|
501
500
|
}
|
|
502
501
|
|
|
@@ -364,7 +364,7 @@ const Qe=Et(class extends zt{constructor(t){var e;if(super(t),t.type!==Ot||"clas
|
|
|
364
364
|
</div>
|
|
365
365
|
<slot></slot>
|
|
366
366
|
</div>
|
|
367
|
-
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){t.has("visible")&&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.position){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(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2
|
|
367
|
+
`}update(t){t.has("visible")&&!this.visible&&this.resetTooltipContent(),super.update(t)}contentAvailableCallback(t){t.has("visible")&&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.position){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(){this.resetTooltipContent();const t=this.slottedElement;if(this.tooltip&&t){const e=t.getBoundingClientRect(),i=(e.height-this.tooltip.clientHeight)/2,o=(e.width-this.tooltip.clientWidth)/2;let s=0,n=0;switch(this.position){case"top":n=-this.tooltip.clientHeight,s=o;break;case"bottom":n=e.height,s=o;break;case"left":n=i,s=-this.tooltip.clientWidth;break;case"right":n=i,s=e.width}e.left+s+this.tooltip.clientWidth>window.innerWidth&&(s=window.innerWidth-this.tooltip.clientWidth-e.left),e.left+s<0&&(s=0);const r=this.tooltip.style;r.left=s+"px",r.top=n+"px",r.maxWidth=Math.max(e.width,150)+"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())}}pi.elementDefinitions={"ft-typography":Ve},pi.styles=g`
|
|
368
368
|
.ft-tooltip--container {
|
|
369
369
|
display: block;
|
|
370
370
|
position: relative;
|
|
@@ -530,7 +530,7 @@ class ui extends zt{constructor(t){if(super(t),this.it=q,t.type!==Ct)throw Error
|
|
|
530
530
|
box-shadow: 0px 0px 0px transparent;
|
|
531
531
|
border: 0px solid transparent;
|
|
532
532
|
text-shadow: 0px 0px 0px transparent;
|
|
533
|
-
font-size:
|
|
533
|
+
font-size: ${Ci.fontSize};
|
|
534
534
|
}
|
|
535
535
|
|
|
536
536
|
button:hover {
|
|
@@ -559,8 +559,7 @@ class ui extends zt{constructor(t){if(super(t),this.it=q,t.type!==Ct)throw Error
|
|
|
559
559
|
border: none;
|
|
560
560
|
pointer-events: auto;
|
|
561
561
|
|
|
562
|
-
--ft-button-internal-
|
|
563
|
-
--ft-button-internal-line-height: calc(var(--ft-button-internal-font-size) + 2px);
|
|
562
|
+
--ft-button-internal-line-height: calc(${Ci.fontSize} + 2px);
|
|
564
563
|
--ft-button-internal-color: ${Ci.color};
|
|
565
564
|
${bt(wi.size,Ci.iconSize)};
|
|
566
565
|
--ft-button-internal-vertical-padding: 6px;
|
|
@@ -616,7 +615,7 @@ class ui extends zt{constructor(t){if(super(t),this.it=q,t.type!==Ct)throw Error
|
|
|
616
615
|
text-overflow: ellipsis;
|
|
617
616
|
display: block;
|
|
618
617
|
margin: 0 var(--ft-button-internal-horizontal-padding);
|
|
619
|
-
${bt(je.fontSize,"
|
|
618
|
+
${bt(je.fontSize,"1em")};
|
|
620
619
|
${bt(je.lineHeight,"var(--ft-button-internal-content-height)")};
|
|
621
620
|
}
|
|
622
621
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-search-bar",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.5",
|
|
4
4
|
"description": "Search bar component using Fluid Topics public API",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Lit"
|
|
@@ -19,18 +19,18 @@
|
|
|
19
19
|
"url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@fluid-topics/ft-accordion": "0.3.
|
|
23
|
-
"@fluid-topics/ft-button": "0.3.
|
|
24
|
-
"@fluid-topics/ft-chip": "0.3.
|
|
25
|
-
"@fluid-topics/ft-filter": "0.3.
|
|
26
|
-
"@fluid-topics/ft-icon": "0.3.
|
|
27
|
-
"@fluid-topics/ft-select": "0.3.
|
|
28
|
-
"@fluid-topics/ft-size-watcher": "0.3.
|
|
29
|
-
"@fluid-topics/ft-skeleton": "0.3.
|
|
30
|
-
"@fluid-topics/ft-snap-scroll": "0.3.
|
|
31
|
-
"@fluid-topics/ft-tooltip": "0.3.
|
|
32
|
-
"@fluid-topics/ft-typography": "0.3.
|
|
33
|
-
"@fluid-topics/ft-wc-utils": "0.3.
|
|
22
|
+
"@fluid-topics/ft-accordion": "0.3.5",
|
|
23
|
+
"@fluid-topics/ft-button": "0.3.5",
|
|
24
|
+
"@fluid-topics/ft-chip": "0.3.5",
|
|
25
|
+
"@fluid-topics/ft-filter": "0.3.5",
|
|
26
|
+
"@fluid-topics/ft-icon": "0.3.5",
|
|
27
|
+
"@fluid-topics/ft-select": "0.3.5",
|
|
28
|
+
"@fluid-topics/ft-size-watcher": "0.3.5",
|
|
29
|
+
"@fluid-topics/ft-skeleton": "0.3.5",
|
|
30
|
+
"@fluid-topics/ft-snap-scroll": "0.3.5",
|
|
31
|
+
"@fluid-topics/ft-tooltip": "0.3.5",
|
|
32
|
+
"@fluid-topics/ft-typography": "0.3.5",
|
|
33
|
+
"@fluid-topics/ft-wc-utils": "0.3.5",
|
|
34
34
|
"lit": "2.2.8"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
@@ -39,5 +39,5 @@
|
|
|
39
39
|
"peerDependencies": {
|
|
40
40
|
"@fluid-topics/public-api": "1.0.18"
|
|
41
41
|
},
|
|
42
|
-
"gitHead": "
|
|
42
|
+
"gitHead": "a8d8a3bf89bac6275c44c4aa7f966e557a94454f"
|
|
43
43
|
}
|