@albi_scando/as-design-system-lib 1.10.2 → 1.10.3
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.
|
@@ -2124,7 +2124,7 @@ const ii = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
2124
2124
|
<div part="tooltip" class="tooltip" role="tooltip">
|
|
2125
2125
|
<slot name="content"></slot>
|
|
2126
2126
|
</div>
|
|
2127
|
-
`, Le = "*{box-sizing:border-box}:host{position:relative;display:inline-flex;align-items:center}.tooltip{position:absolute;z-index:var(--z-index-tooltip, 1070);bottom:calc(100% + .5rem);left:50%;transform:translate(-50%);padding:var(--spacing-1) var(--spacing-2);background-color:var(--color-bg-tertiary, #1e1e2e);color:var(--color-text-primary);font-family:var(--font-family-base);font-size:var(--font-size-xs);line-height:var(--line-height-normal);border-radius:var(--border-radius-md);box-shadow:var(--shadow-lg);white-space:nowrap;pointer-events:none;opacity:0;visibility:hidden;transition:opacity var(--transition-fast),visibility var(--transition-fast);max-width:16rem;white-space:normal;text-align:center}:host([placement=bottom]) .tooltip{bottom:auto;top:calc(100% + .5rem)}:host([placement=left]) .tooltip{bottom:auto;left:auto;right:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([placement=right]) .tooltip{bottom:auto;left:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([open]) .tooltip,:host(:hover) .tooltip,:host(:focus-within) .tooltip{opacity:1;visibility:visible}:host([follow-cursor]) .tooltip{position:fixed;bottom:auto;left:0;top:0;transform:none}:host([follow-cursor]) .tooltip{opacity:1;visibility:visible}", ut = new CSSStyleSheet();
|
|
2127
|
+
`, Le = "*{box-sizing:border-box}:host{position:relative;display:inline-flex;align-items:center}.tooltip{position:absolute;z-index:var(--z-index-tooltip, 1070);bottom:calc(100% + .5rem);left:50%;transform:translate(-50%);padding:var(--spacing-1) var(--spacing-2);background-color:var(--color-bg-tertiary, #1e1e2e);color:var(--color-text-primary);font-family:var(--font-family-base);font-size:var(--font-size-xs);line-height:var(--line-height-normal);border-radius:var(--border-radius-md);box-shadow:var(--shadow-lg);white-space:nowrap;pointer-events:none;opacity:0;visibility:hidden;transition:opacity var(--transition-fast),visibility var(--transition-fast);max-width:16rem;white-space:normal;text-align:center;overflow:hidden;word-wrap:break-word;overflow-wrap:break-word}:host([placement=bottom]) .tooltip{bottom:auto;top:calc(100% + .5rem)}:host([placement=left]) .tooltip{bottom:auto;left:auto;right:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([placement=right]) .tooltip{bottom:auto;left:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([open]) .tooltip,:host(:hover) .tooltip,:host(:focus-within) .tooltip{opacity:1;visibility:visible}:host([follow-cursor]) .tooltip{position:fixed;bottom:auto;left:0;top:0;transform:none}:host([follow-cursor]) .tooltip{opacity:1;visibility:visible}", ut = new CSSStyleSheet();
|
|
2128
2128
|
ut.replaceSync(Le);
|
|
2129
2129
|
class b extends HTMLElement {
|
|
2130
2130
|
static _placementAttribute = "placement";
|
|
@@ -170,7 +170,7 @@
|
|
|
170
170
|
<div part="tooltip" class="tooltip" role="tooltip">
|
|
171
171
|
<slot name="content"></slot>
|
|
172
172
|
</div>
|
|
173
|
-
`,Ce="*{box-sizing:border-box}:host{position:relative;display:inline-flex;align-items:center}.tooltip{position:absolute;z-index:var(--z-index-tooltip, 1070);bottom:calc(100% + .5rem);left:50%;transform:translate(-50%);padding:var(--spacing-1) var(--spacing-2);background-color:var(--color-bg-tertiary, #1e1e2e);color:var(--color-text-primary);font-family:var(--font-family-base);font-size:var(--font-size-xs);line-height:var(--line-height-normal);border-radius:var(--border-radius-md);box-shadow:var(--shadow-lg);white-space:nowrap;pointer-events:none;opacity:0;visibility:hidden;transition:opacity var(--transition-fast),visibility var(--transition-fast);max-width:16rem;white-space:normal;text-align:center}:host([placement=bottom]) .tooltip{bottom:auto;top:calc(100% + .5rem)}:host([placement=left]) .tooltip{bottom:auto;left:auto;right:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([placement=right]) .tooltip{bottom:auto;left:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([open]) .tooltip,:host(:hover) .tooltip,:host(:focus-within) .tooltip{opacity:1;visibility:visible}:host([follow-cursor]) .tooltip{position:fixed;bottom:auto;left:0;top:0;transform:none}:host([follow-cursor]) .tooltip{opacity:1;visibility:visible}",vt=new CSSStyleSheet;vt.replaceSync(Ce);class v extends HTMLElement{static _placementAttribute="placement";static _contentAttribute="content";static _openAttribute="open";static _followCursorAttribute="follow-cursor";_lastMouseX=0;_lastMouseY=0;constructor(){super(),this.attachShadow({mode:"open"}),this.shadowRoot?.adoptedStyleSheets.push(vt)}static get observedAttributes(){return[v._placementAttribute,v._contentAttribute,v._openAttribute,v._followCursorAttribute]}get placement(){return this.getAttribute(v._placementAttribute)??"top"}set placement(t){this.setAttribute(v._placementAttribute,t)}get content(){return this.getAttribute(v._contentAttribute)??""}set content(t){this.setAttribute(v._contentAttribute,t),this._updateContent(t)}get open(){return this.hasAttribute(v._openAttribute)}set open(t){t?this.setAttribute(v._openAttribute,""):this.removeAttribute(v._openAttribute)}get followCursor(){return this.hasAttribute(v._followCursorAttribute)}set followCursor(t){t?this.setAttribute(v._followCursorAttribute,""):this.removeAttribute(v._followCursorAttribute)}connectedCallback(){this._render(),this._attachEventListeners()}disconnectedCallback(){this._removeEventListeners()}attributeChangedCallback(t,e,i){i!==e&&(t===v._contentAttribute&&this._updateContent(i),t===v._followCursorAttribute&&(i!==null?this._attachEventListeners():this._removeEventListeners()))}_render(){if(this.shadowRoot===null)return;this.shadowRoot.innerHTML=De,this._updateContent(this.content);const t=this.shadowRoot.querySelector(".tooltip");if(t!=null){const e=`tooltip-${Math.random().toString(36).slice(2,7)}`;t.id=e}}_attachEventListeners(){this.removeEventListener("mousemove",this._handleMouseMove),this.removeEventListener("mouseleave",this._handleMouseLeave),this.removeEventListener("mouseenter",this._handleMouseEnter),this.followCursor&&(this.addEventListener("mouseenter",this._handleMouseEnter),this.addEventListener("mousemove",this._handleMouseMove),this.addEventListener("mouseleave",this._handleMouseLeave))}_removeEventListeners(){this.removeEventListener("mousemove",this._handleMouseMove),this.removeEventListener("mouseleave",this._handleMouseLeave),this.removeEventListener("mouseenter",this._handleMouseEnter)}_handleMouseEnter=()=>{const t=this.shadowRoot?.querySelector(".tooltip");t!=null&&(t.style.opacity="1",t.style.visibility="visible")};_handleMouseMove=t=>{this.followCursor&&(this._lastMouseX=t.clientX,this._lastMouseY=t.clientY,this._updateTooltipPosition())};_handleMouseLeave=()=>{const t=this.shadowRoot?.querySelector(".tooltip");t!=null&&(t.style.opacity="0",t.style.visibility="hidden",t.style.left="",t.style.top="")};_updateTooltipPosition(){const t=this.shadowRoot?.querySelector(".tooltip");if(t==null)return;const e=10;t.style.position="fixed",t.style.left=`${this._lastMouseX+e}px`,t.style.top=`${this._lastMouseY+e}px`,t.style.transform="none"}_updateContent(t){const e=this.shadowRoot?.querySelector(".tooltip");if(e!=null&&t!==null&&t!==""){const i=e.querySelector("slot");(i===null||i.assignedNodes().length===0)&&(e.textContent=t)}}}const Ue=Object.freeze(Object.defineProperty({__proto__:null,TooltipComponent:v,selector:Pe},Symbol.toStringTag,{value:"Module"})),Ke="ds-text-input",Ge=`<div part="wrapper" class="input-wrapper">
|
|
173
|
+
`,Ce="*{box-sizing:border-box}:host{position:relative;display:inline-flex;align-items:center}.tooltip{position:absolute;z-index:var(--z-index-tooltip, 1070);bottom:calc(100% + .5rem);left:50%;transform:translate(-50%);padding:var(--spacing-1) var(--spacing-2);background-color:var(--color-bg-tertiary, #1e1e2e);color:var(--color-text-primary);font-family:var(--font-family-base);font-size:var(--font-size-xs);line-height:var(--line-height-normal);border-radius:var(--border-radius-md);box-shadow:var(--shadow-lg);white-space:nowrap;pointer-events:none;opacity:0;visibility:hidden;transition:opacity var(--transition-fast),visibility var(--transition-fast);max-width:16rem;white-space:normal;text-align:center;overflow:hidden;word-wrap:break-word;overflow-wrap:break-word}:host([placement=bottom]) .tooltip{bottom:auto;top:calc(100% + .5rem)}:host([placement=left]) .tooltip{bottom:auto;left:auto;right:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([placement=right]) .tooltip{bottom:auto;left:calc(100% + .5rem);top:50%;transform:translateY(-50%)}:host([open]) .tooltip,:host(:hover) .tooltip,:host(:focus-within) .tooltip{opacity:1;visibility:visible}:host([follow-cursor]) .tooltip{position:fixed;bottom:auto;left:0;top:0;transform:none}:host([follow-cursor]) .tooltip{opacity:1;visibility:visible}",vt=new CSSStyleSheet;vt.replaceSync(Ce);class v extends HTMLElement{static _placementAttribute="placement";static _contentAttribute="content";static _openAttribute="open";static _followCursorAttribute="follow-cursor";_lastMouseX=0;_lastMouseY=0;constructor(){super(),this.attachShadow({mode:"open"}),this.shadowRoot?.adoptedStyleSheets.push(vt)}static get observedAttributes(){return[v._placementAttribute,v._contentAttribute,v._openAttribute,v._followCursorAttribute]}get placement(){return this.getAttribute(v._placementAttribute)??"top"}set placement(t){this.setAttribute(v._placementAttribute,t)}get content(){return this.getAttribute(v._contentAttribute)??""}set content(t){this.setAttribute(v._contentAttribute,t),this._updateContent(t)}get open(){return this.hasAttribute(v._openAttribute)}set open(t){t?this.setAttribute(v._openAttribute,""):this.removeAttribute(v._openAttribute)}get followCursor(){return this.hasAttribute(v._followCursorAttribute)}set followCursor(t){t?this.setAttribute(v._followCursorAttribute,""):this.removeAttribute(v._followCursorAttribute)}connectedCallback(){this._render(),this._attachEventListeners()}disconnectedCallback(){this._removeEventListeners()}attributeChangedCallback(t,e,i){i!==e&&(t===v._contentAttribute&&this._updateContent(i),t===v._followCursorAttribute&&(i!==null?this._attachEventListeners():this._removeEventListeners()))}_render(){if(this.shadowRoot===null)return;this.shadowRoot.innerHTML=De,this._updateContent(this.content);const t=this.shadowRoot.querySelector(".tooltip");if(t!=null){const e=`tooltip-${Math.random().toString(36).slice(2,7)}`;t.id=e}}_attachEventListeners(){this.removeEventListener("mousemove",this._handleMouseMove),this.removeEventListener("mouseleave",this._handleMouseLeave),this.removeEventListener("mouseenter",this._handleMouseEnter),this.followCursor&&(this.addEventListener("mouseenter",this._handleMouseEnter),this.addEventListener("mousemove",this._handleMouseMove),this.addEventListener("mouseleave",this._handleMouseLeave))}_removeEventListeners(){this.removeEventListener("mousemove",this._handleMouseMove),this.removeEventListener("mouseleave",this._handleMouseLeave),this.removeEventListener("mouseenter",this._handleMouseEnter)}_handleMouseEnter=()=>{const t=this.shadowRoot?.querySelector(".tooltip");t!=null&&(t.style.opacity="1",t.style.visibility="visible")};_handleMouseMove=t=>{this.followCursor&&(this._lastMouseX=t.clientX,this._lastMouseY=t.clientY,this._updateTooltipPosition())};_handleMouseLeave=()=>{const t=this.shadowRoot?.querySelector(".tooltip");t!=null&&(t.style.opacity="0",t.style.visibility="hidden",t.style.left="",t.style.top="")};_updateTooltipPosition(){const t=this.shadowRoot?.querySelector(".tooltip");if(t==null)return;const e=10;t.style.position="fixed",t.style.left=`${this._lastMouseX+e}px`,t.style.top=`${this._lastMouseY+e}px`,t.style.transform="none"}_updateContent(t){const e=this.shadowRoot?.querySelector(".tooltip");if(e!=null&&t!==null&&t!==""){const i=e.querySelector("slot");(i===null||i.assignedNodes().length===0)&&(e.textContent=t)}}}const Ue=Object.freeze(Object.defineProperty({__proto__:null,TooltipComponent:v,selector:Pe},Symbol.toStringTag,{value:"Module"})),Ke="ds-text-input",Ge=`<div part="wrapper" class="input-wrapper">
|
|
174
174
|
<label class="input-label" part="label"></label>
|
|
175
175
|
<div class="input-container">
|
|
176
176
|
<slot name="prefix" class="input-prefix"></slot>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@albi_scando/as-design-system-lib",
|
|
3
|
-
"version": "1.10.
|
|
3
|
+
"version": "1.10.3",
|
|
4
4
|
"description": "A library of reusable, strongly typed Web Components built with TypeScript, designed for creating consistent and maintainable user interfaces.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|