{"version":3,"names":["progressCss","CalciteProgressStyle0","Progress","render","isDeterminate","this","type","barStyles","width","value","dir","getElementDir","el","h","key","label","text","role","class","bar","indeterminate","CSS_UTILITY","rtl","reversed","style"],"sources":["src/components/progress/progress.scss?tag=calcite-progress&encapsulation=shadow","src/components/progress/progress.tsx"],"sourcesContent":["/**\n* CSS Custom Properties\n*\n* These properties can be overridden using the component's tag as selector.\n*\n* @prop --calcite-progress-background-color: Specifies the component's background color.\n* @prop --calcite-progress-fill-color: Specifies the component's fill color.\n* @prop --calcite-progress-text-color: Specifies the component's text color.\n*/\n\n@import \"../../assets/styles/animation\";\n\n:host {\n @apply relative block w-full;\n}\n\n.track,\n.bar {\n @apply absolute top-0;\n block-size: 2px;\n}\n\n.track {\n @apply z-default w-full overflow-hidden;\n background-color: var(--calcite-progress-background-color, var(--calcite-color-border-3));\n}\n\n.bar {\n @apply z-default;\n\n background-color: var(--calcite-progress-fill-color, var(--calcite-color-brand));\n}\n\n@media (forced-colors: active) {\n .track {\n background-color: highlightText;\n }\n .bar {\n background-color: linkText;\n }\n}\n\n.indeterminate {\n @apply w-1/5;\n animation: looping-progress-bar-ani scale-duration(--calcite-internal-animation-timing-medium, 11) linear infinite;\n &.calcite--rtl {\n animation-name: looping-progress-bar-ani-rtl;\n }\n}\n\n.reversed {\n animation-direction: reverse;\n}\n\n.text {\n @apply text-n2h px-0 pt-4 pb-0 text-center font-medium;\n color: var(--calcite-progress-text-color, var(--calcite-color-text-2));\n}\n\n@keyframes looping-progress-bar-ani {\n 0% {\n transform: translate3d(-100%, 0, 0);\n }\n 50% {\n inline-size: 40%;\n }\n 100% {\n transform: translate3d(600%, 0, 0);\n }\n}\n\n@keyframes looping-progress-bar-ani-rtl {\n 0% {\n transform: translate3d(100%, 0, 0);\n }\n 50% {\n inline-size: 40%;\n }\n 100% {\n transform: translate3d(-600%, 0, 0);\n }\n}\n\n@include base-component();\n","import { Component, Element, h, Prop, VNode } from \"@stencil/core\";\nimport { getElementDir } from \"../../utils/dom\";\nimport { CSS_UTILITY } from \"../../utils/resources\";\n@Component({\n tag: \"calcite-progress\",\n styleUrl: \"progress.scss\",\n shadow: true,\n})\nexport class Progress {\n @Element() el: HTMLCalciteProgressElement;\n\n /**\n * Specifies the component type.\n *\n * Use `\"indeterminate\"` if finding actual progress value is impossible.\n *\n */\n @Prop({ reflect: true }) type: \"indeterminate\" | \"determinate\" = \"determinate\";\n\n /** When `type` is `\"determinate\"`, the component's progress value with a range of 0.0 - 1.0. */\n @Prop() value = 0;\n\n /** Accessible name for the component. */\n @Prop() label: string;\n\n /** Text that displays under the component's indicator. */\n @Prop() text: string;\n\n /** When `true` and for `\"indeterminate\"` progress bars, reverses the animation direction. */\n @Prop({ reflect: true }) reversed = false;\n\n render(): VNode {\n const isDeterminate = this.type === \"determinate\";\n const barStyles = isDeterminate ? { width: `${this.value * 100}%` } : {};\n const dir = getElementDir(this.el);\n return (\n