@warp-ds/elements 2.3.0-next.14 → 2.3.0-next.16
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/packages/attention/index.js +2 -2
- package/dist/packages/attention/index.js.map +2 -2
- package/dist/packages/attention/styles.js +1 -1
- package/dist/packages/slider/slider-thumb.js +1 -1
- package/dist/packages/slider/slider-thumb.js.map +2 -2
- package/dist/web-types.json +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { css } from 'lit';
|
|
2
|
-
export const styles = css `*,:before,:after{--w-rotate:0;--w-rotate-x:0;--w-rotate-y:0;--w-rotate-z:0;--w-scale-x:1;--w-scale-y:1;--w-scale-z:1;--w-skew-x:0;--w-skew-y:0;--w-translate-x:0;--w-translate-y:0;--w-translate-z:0}.hover\\:bg-clip-padding:hover{-webkit-background-clip:padding-box;background-clip:padding-box}.bg-transparent{background-color:#0000}.bg-\\[--w-color-button-primary-background\\]{background-color:var(--w-color-button-primary-background)}.bg-\\[--w-color-callout-background\\]{background-color:var(--w-color-callout-background)}.bg-\\[--w-s-color-surface-elevated-300\\]{background-color:var(--w-s-color-surface-elevated-300)}.hover\\:bg-\\[--w-color-button-pill-background-hover\\]:hover{background-color:var(--w-color-button-pill-background-hover)}.hover\\:bg-\\[--w-color-button-primary-background-hover\\]:hover{background-color:var(--w-color-button-primary-background-hover)}.active\\:bg-\\[--w-color-button-pill-background-active\\]:active{background-color:var(--w-color-button-pill-background-active)}.active\\:bg-\\[--w-color-button-primary-background-active\\]:active{background-color:var(--w-color-button-primary-background-active)}.border{border-width:1px}.border-0{border-width:0}.border-2{border-width:2px}.border-b-0{border-bottom-width:0}.border-r-0{border-right-width:0}.border-\\[--w-color-callout-border\\]{border-color:var(--w-color-callout-border)}.border-\\[--w-s-color-background-inverted\\]{border-color:var(--w-s-color-background-inverted)}.border-\\[--w-s-color-surface-elevated-300\\]{border-color:var(--w-s-color-surface-elevated-300)}.rounded-4{border-radius:4px}.rounded-8{border-radius:8px}.rounded-full{border-radius:9999px}.rounded-tl-4{border-top-left-radius:4px}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.contents{display:contents}.hidden{display:none}.hover\\:underline:hover,.focus\\:underline:focus,.active\\:underline:active{text-decoration-line:underline}.focusable:focus{outline:2px solid var(--w-s-color-border-focus);outline-offset:var(--w-outline-offset,1px)}.focusable:focus-visible{outline:2px solid var(--w-s-color-border-focus);outline-offset:var(--w-outline-offset,1px)}.focusable:not(:focus-visible){outline:none}.items-
|
|
2
|
+
export const styles = css `*,:before,:after{--w-rotate:0;--w-rotate-x:0;--w-rotate-y:0;--w-rotate-z:0;--w-scale-x:1;--w-scale-y:1;--w-scale-z:1;--w-skew-x:0;--w-skew-y:0;--w-translate-x:0;--w-translate-y:0;--w-translate-z:0}.hover\\:bg-clip-padding:hover{-webkit-background-clip:padding-box;background-clip:padding-box}.bg-transparent{background-color:#0000}.bg-\\[--w-color-button-primary-background\\]{background-color:var(--w-color-button-primary-background)}.bg-\\[--w-color-callout-background\\]{background-color:var(--w-color-callout-background)}.bg-\\[--w-s-color-surface-elevated-300\\]{background-color:var(--w-s-color-surface-elevated-300)}.hover\\:bg-\\[--w-color-button-pill-background-hover\\]:hover{background-color:var(--w-color-button-pill-background-hover)}.hover\\:bg-\\[--w-color-button-primary-background-hover\\]:hover{background-color:var(--w-color-button-primary-background-hover)}.active\\:bg-\\[--w-color-button-pill-background-active\\]:active{background-color:var(--w-color-button-pill-background-active)}.active\\:bg-\\[--w-color-button-primary-background-active\\]:active{background-color:var(--w-color-button-primary-background-active)}.border{border-width:1px}.border-0{border-width:0}.border-2{border-width:2px}.border-b-0{border-bottom-width:0}.border-r-0{border-right-width:0}.border-\\[--w-color-callout-border\\]{border-color:var(--w-color-callout-border)}.border-\\[--w-s-color-background-inverted\\]{border-color:var(--w-s-color-background-inverted)}.border-\\[--w-s-color-surface-elevated-300\\]{border-color:var(--w-s-color-surface-elevated-300)}.rounded-4{border-radius:4px}.rounded-8{border-radius:8px}.rounded-full{border-radius:9999px}.rounded-tl-4{border-top-left-radius:4px}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.contents{display:contents}.hidden{display:none}.hover\\:underline:hover,.focus\\:underline:focus,.active\\:underline:active{text-decoration-line:underline}.focusable:focus{outline:2px solid var(--w-s-color-border-focus);outline-offset:var(--w-outline-offset,1px)}.focusable:focus-visible{outline:2px solid var(--w-s-color-border-focus);outline-offset:var(--w-outline-offset,1px)}.focusable:not(:focus-visible){outline:none}.items-center{align-items:center}.-bottom-\\[8px\\]{bottom:-8px}.-left-\\[8px\\]{left:-8px}.-right-\\[8px\\]{right:-8px}.-top-\\[8px\\]{top:-8px}.justify-center{justify-content:center}.absolute{position:absolute}.relative{position:relative}.static{position:static}.z-50{z-index:50}.s-bg{background-color:var(--w-s-color-background)}.s-bg-disabled{background-color:var(--w-s-color-background-disabled)}.s-bg-inverted{background-color:var(--w-s-color-background-inverted)}.s-bg-negative{background-color:var(--w-s-color-background-negative)}.s-bg-subtle{background-color:var(--w-s-color-background-subtle)}.hover\\:s-bg-hover:hover{background-color:var(--w-s-color-background-hover)}.hover\\:s-bg-negative-hover:hover{background-color:var(--w-s-color-background-negative-hover)}.hover\\:s-bg-negative-subtle-hover:hover{background-color:var(--w-s-color-background-negative-subtle-hover)}.active\\:s-bg-active:active{background-color:var(--w-s-color-background-active)}.active\\:s-bg-negative-active:active{background-color:var(--w-s-color-background-negative-active)}.active\\:s-bg-negative-subtle-active:active{background-color:var(--w-s-color-background-negative-subtle-active)}.s-text{color:var(--w-s-color-text)}.s-text-inverted{color:var(--w-s-color-text-inverted)}.s-text-link{color:var(--w-s-color-text-link)}.s-text-negative{color:var(--w-s-color-text-negative)}.s-icon{color:var(--w-s-color-icon)}.hover\\:s-icon-hover:hover{color:var(--w-s-color-icon-hover)}.active\\:s-icon-active:active{color:var(--w-s-color-icon-active)}.s-border{border-color:var(--w-s-color-border)}.hover\\:s-border-hover:hover{border-color:var(--w-s-color-border-hover)}.active\\:s-border-active:active{border-color:var(--w-s-color-border-active)}.drop-shadow-m{filter:drop-shadow(0 3px 8px #4040403d)drop-shadow(0 3px 6px #40404029)}.shadow-m{box-shadow:var(--w-shadow-m)}.h-\\[14px\\]{height:14px}.w-\\[14px\\]{width:14px}.last-child\\:mb-0>:last-child{margin-bottom:0}.ml-8{margin-left:.8rem}.p-16{padding:1.6rem}.p-4{padding:.4rem}.px-16{padding-left:1.6rem;padding-right:1.6rem}.px-8{padding-left:.8rem;padding-right:.8rem}.py-6{padding-top:.6rem;padding-bottom:.6rem}.py-8{padding-top:.8rem;padding-bottom:.8rem}.font-bold{font-weight:700}.resize{resize:both}.translate-z-0{--w-translate-z:0rem;transform:translateX(var(--w-translate-x))translateY(var(--w-translate-y))translateZ(var(--w-translate-z))rotate(var(--w-rotate))rotateX(var(--w-rotate-x))rotateY(var(--w-rotate-y))rotateZ(var(--w-rotate-z))skewX(var(--w-skew-x))skewY(var(--w-skew-y))scaleX(var(--w-scale-x))scaleY(var(--w-scale-y))scaleZ(var(--w-scale-z))}.transform{transform:translateX(var(--w-translate-x))translateY(var(--w-translate-y))translateZ(var(--w-translate-z))rotate(var(--w-rotate))rotateX(var(--w-rotate-x))rotateY(var(--w-rotate-y))rotateZ(var(--w-rotate-z))skewX(var(--w-skew-x))skewY(var(--w-skew-y))scaleX(var(--w-scale-x))scaleY(var(--w-scale-y))scaleZ(var(--w-scale-z))}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-duration:.15s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.text-m{font-size:var(--w-font-size-m);line-height:var(--w-line-height-m)}.text-xs{font-size:var(--w-font-size-xs);line-height:var(--w-line-height-xs)}.leading-\\[24\\]{line-height:2.4rem}`;
|
|
@@ -2726,5 +2726,5 @@ var le=Object.defineProperty;var de=Object.getOwnPropertyDescriptor;var K=s=>{th
|
|
|
2726
2726
|
>${this.ariaDescription}</span
|
|
2727
2727
|
>
|
|
2728
2728
|
</div>
|
|
2729
|
-
`}};c=new WeakSet,O=function(){this._showTooltip=!0,this.shadowRoot.querySelector("w-attention").handleDone()},X=function(){this._showTooltip=!1},q=function(){this.range&&(this.value===""?this.range.value=this.boundaryValue:this.value&&(this.range.value=this.value))},H=async function(e,r){let a=Number.parseInt(e);if(this.allowValuesOutsideRange&&!r&&!(this.slot==="to"&&a>=Number(this.max)-1||this.slot==="from"&&a<=Number(this.min)+1)){let x=1/this.step;a=Math.round(a*x)/x,e=a.toString()}let d=Number.parseInt(this.max),m=Number.parseInt(this.min);if(!this.allowValuesOutsideRange&&(a>d||a<m))return this.invalid=!0,{shouldCancel:!0};if(e==="")return this.required&&(this.invalid=!0),{shouldCancel:!0};this.invalid&&(this.invalid=!1),this.value=e;let w=e===this.max||e===this.min,M=!1;if(this.slot){let f=getComputedStyle(this),x=f.getPropertyValue("--to"),F=f.getPropertyValue("--from");if(this.slot==="from"){let k=Math.min(Number.parseInt(x),this.allowValuesOutsideRange?d-1:d);a>k&&(M=!0,this.allowValuesOutsideRange&&w?this.value=String(k):this.value=x,r&&(this.invalid=!0,await this.updateComplete,this.textfield.value=e))}else{let k=Math.max(Number.parseInt(F),this.allowValuesOutsideRange?m+1:m);a<k&&(M=!0,this.allowValuesOutsideRange&&w?this.value=String(k):this.value=F,r&&(this.invalid=!0,await this.updateComplete,this.textfield.value=e))}}return M?{shouldCancel:!0}:(this.range.value=Math.min(Math.max(Number(e),Number(this.min)),Number(this.max)).toString(),this.value=this.allowValuesOutsideRange&&!r&&w?"":e,this.shadowRoot.querySelector("w-attention").handleDone(),{shouldCancel:!1})},B=async function(e){let r=e.currentTarget.tagName==="W-TEXTFIELD";if(e instanceof CustomEvent)return;let a=e.currentTarget.value;return(await g(this,c,H).call(this,a,r)).shouldCancel?(e.preventDefault(),!1):!0},ne=async function(e){if(e.key!=="ArrowLeft"&&e.key!=="ArrowRight")return;let r=Number(this.range.value),a=this.step||1,d;e.key==="ArrowLeft"?d=r-a:d=r+a,d=Math.min(Math.max(d,Number(this.min)),Number(this.max)),(await g(this,c,H).call(this,d.toString(),!1)).shouldCancel&&e.preventDefault()},l.shadowRootOptions={...te.shadowRootOptions,delegatesFocus:!0},l.styles=[ee,oe,re],h([V({attribute:"aria-label",reflect:!0})],l.prototype,"ariaLabel",2),h([V({attribute:"aria-description",reflect:!0})],l.prototype,"ariaDescription",2),h([V({reflect:!0})],l.prototype,"label",2),h([V({reflect:!0})],l.prototype,"name",2),h([V({reflect:!0})],l.prototype,"value",2),h([V({type:Boolean,reflect:!0})],l.prototype,"disabled",2),h([V({type:Boolean,reflect:!0})],l.prototype,"invalid",2),h([V({attribute:!1,reflect:!1})],l.prototype,"allowValuesOutsideRange",2),h([z()],l.prototype,"markers",2),h([z()],l.prototype,"required",2),h([z()],l.prototype,"step",2),h([z()],l.prototype,"min",2),h([z()],l.prototype,"max",2),h([z()],l.prototype,"suffix",2),h([z()],l.prototype,"formatter",2),h([ae('input[type="range"]')],l.prototype,"range",2),h([ae("w-textfield")],l.prototype,"textfield",2),h([z()],l.prototype,"_showTooltip",2),h([z()],l.prototype,"_inputHasFocus",2);customElements.get("w-slider-thumb")||customElements.define("w-slider-thumb",l);export{l as WarpSliderThumb};
|
|
2729
|
+
`}};c=new WeakSet,O=function(){this._showTooltip=!0,this.shadowRoot.querySelector("w-attention").handleDone()},X=function(){this._showTooltip=!1},q=function(){this.range&&(this.value===""?this.range.value=this.boundaryValue:this.value&&(this.range.value=this.value))},H=async function(e,r){let a=Number.parseInt(e);if(this.allowValuesOutsideRange&&!r&&this.step&&!(this.slot==="to"&&a>=Number(this.max)-1||this.slot==="from"&&a<=Number(this.min)+1)){let x=1/this.step;a=Math.round(a*x)/x,e=a.toString()}let d=Number.parseInt(this.max),m=Number.parseInt(this.min);if(!this.allowValuesOutsideRange&&(a>d||a<m))return this.invalid=!0,{shouldCancel:!0};if(e==="")return this.required&&(this.invalid=!0),{shouldCancel:!0};this.invalid&&(this.invalid=!1),this.value=e;let w=e===this.max||e===this.min,M=!1;if(this.slot){let f=getComputedStyle(this),x=f.getPropertyValue("--to"),F=f.getPropertyValue("--from");if(this.slot==="from"){let k=Math.min(Number.parseInt(x),this.allowValuesOutsideRange?d-1:d);a>k&&(M=!0,this.allowValuesOutsideRange&&w?this.value=String(k):this.value=x,r&&(this.invalid=!0,await this.updateComplete,this.textfield.value=e))}else{let k=Math.max(Number.parseInt(F),this.allowValuesOutsideRange?m+1:m);a<k&&(M=!0,this.allowValuesOutsideRange&&w?this.value=String(k):this.value=F,r&&(this.invalid=!0,await this.updateComplete,this.textfield.value=e))}}return M?{shouldCancel:!0}:(this.range.value=Math.min(Math.max(Number(e),Number(this.min)),Number(this.max)).toString(),this.value=this.allowValuesOutsideRange&&!r&&w?"":e,this.shadowRoot.querySelector("w-attention").handleDone(),{shouldCancel:!1})},B=async function(e){let r=e.currentTarget.tagName==="W-TEXTFIELD";if(e instanceof CustomEvent)return;let a=e.currentTarget.value;return(await g(this,c,H).call(this,a,r)).shouldCancel?(e.preventDefault(),!1):!0},ne=async function(e){if(e.key!=="ArrowLeft"&&e.key!=="ArrowRight")return;let r=Number(this.range.value),a=this.step||1,d;e.key==="ArrowLeft"?d=r-a:d=r+a,d=Math.min(Math.max(d,Number(this.min)),Number(this.max)),(await g(this,c,H).call(this,d.toString(),!1)).shouldCancel&&e.preventDefault()},l.shadowRootOptions={...te.shadowRootOptions,delegatesFocus:!0},l.styles=[ee,oe,re],h([V({attribute:"aria-label",reflect:!0})],l.prototype,"ariaLabel",2),h([V({attribute:"aria-description",reflect:!0})],l.prototype,"ariaDescription",2),h([V({reflect:!0})],l.prototype,"label",2),h([V({reflect:!0})],l.prototype,"name",2),h([V({reflect:!0})],l.prototype,"value",2),h([V({type:Boolean,reflect:!0})],l.prototype,"disabled",2),h([V({type:Boolean,reflect:!0})],l.prototype,"invalid",2),h([V({attribute:!1,reflect:!1})],l.prototype,"allowValuesOutsideRange",2),h([z()],l.prototype,"markers",2),h([z()],l.prototype,"required",2),h([z()],l.prototype,"step",2),h([z()],l.prototype,"min",2),h([z()],l.prototype,"max",2),h([z()],l.prototype,"suffix",2),h([z()],l.prototype,"formatter",2),h([ae('input[type="range"]')],l.prototype,"range",2),h([ae("w-textfield")],l.prototype,"textfield",2),h([z()],l.prototype,"_showTooltip",2),h([z()],l.prototype,"_inputHasFocus",2);customElements.get("w-slider-thumb")||customElements.define("w-slider-thumb",l);export{l as WarpSliderThumb};
|
|
2730
2730
|
//# sourceMappingURL=slider-thumb.js.map
|