@trimble-oss/moduswebcomponents
Version:
Modus Web Components is a modern, accessible UI library built with Stencil JS that provides reusable web components following Trimble's Modus design system. This updated version focuses on improved flexibility, enhanced theming options, comprehensive cust
1 lines • 1.14 kB
JavaScript
import{r as s,h as t,H as e,g as o}from"./p-dzXW86AR.js";import{i as r}from"./p-B5lx0dpl.js";const a=class{constructor(t){s(this,t),this.inheritedAttributes={},this.customClass="",this.steps=[]}componentWillLoad(){this.inheritedAttributes=r(this.el)}getClasses(){const s=["modus-wc-steps"],t=(({orientation:s})=>{let t="";if(s)switch(s){case"horizontal":break;case"vertical":t=`${t} modus-wc-steps-vertical`}return t.trim()})({orientation:this.orientation});return t&&s.push(t),this.customClass&&s.push(this.customClass),s.join(" ")}getClassesForStep(s){const t=["modus-wc-step"];return s.color&&t.push(`modus-wc-step-${s.color}`),s.customClass&&t.push(s.customClass),t.join(" ")}render(){return t(e,{key:"87810b2939a252f6a75b85db35867208128ce300"},t("div",Object.assign({key:"2a504211de0846933293b7c5ee6348d47a354a3d",class:this.getClasses()},this.inheritedAttributes),this.steps.map(((s,e)=>t("li",{class:this.getClassesForStep(s),key:e,"data-content":s.content},s.label)))))}get el(){return o(this)}};a.style="modus-wc-stepper .modus-wc-steps .modus-wc-step{--fallback-b3:var(--modus-wc-color-base-200)}";export{a as modus_wc_stepper}