{"version":3,"file":"allianz-ng-aquila-progressbar.mjs","names":[],"sources":["../../../projects/ng-aquila/src/progressbar/progressbar.component.ts","../../../projects/ng-aquila/src/progressbar/progressbar.component.html","../../../projects/ng-aquila/src/progressbar/progressbar.module.ts"],"sourcesContent":["import { NgStyle } from '@angular/common';\nimport {\n  booleanAttribute,\n  ChangeDetectionStrategy,\n  Component,\n  input,\n  numberAttribute,\n} from '@angular/core';\n\nexport type NxProgressbarColorScheme = 'default' | 'positive';\n\n@Component({\n  selector: 'nx-progressbar',\n  templateUrl: './progressbar.component.html',\n  changeDetection: ChangeDetectionStrategy.OnPush,\n  styleUrls: ['./progressbar.component.scss'],\n  host: {\n    '[attr.aria-valuenow]': 'value()',\n    '[attr.role]': '\"progressbar\"',\n    '[attr.aria-valuemax]': 'this.max()',\n    '[attr.aria-valuemin]': 'this.min()',\n    '[attr.aria-label]': 'this.ariaLabel()',\n    '[attr.aria-labelledby]': 'this.ariaLabelledBy()',\n    '[class.positive]': 'this.colorScheme() === \"positive\"',\n    '[class.transparent-background]': 'this.transparentBackground()',\n  },\n  imports: [NgStyle],\n})\nexport class NxProgressbarComponent {\n  /** Overrides the `aria-label` of the nx-progressbar. Defaults to \"Progress\" */\n  readonly ariaLabel = input<string | undefined>('Progress');\n\n  /** Sets the `aria-labelledby` of the nx-progressbar */\n  readonly ariaLabelledBy = input<string>();\n\n  /** Sets the value of the progress bar. Defaults to zero. Mirrored to aria-valuenow. */\n  readonly value = input(0, { transform: numberAttribute });\n\n  /** The minimum value of the progress bar. Used for percentage calculation and mirrored to `aria-valuemin`. Defaults to 0 */\n  readonly min = input(0, { transform: numberAttribute });\n\n  /** The maximum value of the progress bar. Used for percentage calculation and mirrored to `aria-valuemax`. Defaults to 1 */\n  readonly max = input(1, { transform: numberAttribute });\n\n  /** Sets the color scheme of the progress bar indicator. Defaults to \"default\" */\n  readonly colorScheme = input<NxProgressbarColorScheme>('default');\n\n  /** Makes the background transparent. Defaults to false */\n  readonly transparentBackground = input(false, { transform: booleanAttribute });\n\n  _primaryTransform() {\n    const scale = (this.value() - this.min()) / (this.max() - this.min());\n    return { transform: `scaleX(${scale})` };\n  }\n}\n","<div class=\"nx-progress__track\">\n  <div class=\"nx-progress__indicator\" [ngStyle]=\"_primaryTransform()\"></div>\n</div>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { NxProgressbarComponent } from './progressbar.component';\n\n@NgModule({\n  imports: [CommonModule, NxProgressbarComponent],\n  exports: [NxProgressbarComponent],\n  providers: [],\n})\nexport class NxProgressbarModule {}\n"],"mappings":";;;AA4BA,IAAa,yBAAb,MAAa,uBAAsB;CAjBnC,cAAA;EAmBW,KAAA,YAAY,MAA0B,YAAW,GAAA,YAAA,CAAA,EAAA,WAAA,YAAA,CAAA,+BAAA,CAAA,CAAA;EAGjD,KAAA,iBAAiB,MAAe,GAAA,YAAA,CAAA,QAAA,EAAA,WAAA,iBAAA,CAAA,+BAAA,CAAA,CAAA;EAGhC,KAAA,QAAQ,MAAM,GAAC;GAAA,GAAA,YAAA,EAAA,WAAA,QAAA,+BAAA,CAAA;GAAI,WAAW;EAAe,CAAA;EAG7C,KAAA,MAAM,MAAM,GAAC;GAAA,GAAA,YAAA,EAAA,WAAA,MAAA,+BAAA,CAAA;GAAI,WAAW;EAAe,CAAA;EAG3C,KAAA,MAAM,MAAM,GAAC;GAAA,GAAA,YAAA,EAAA,WAAA,MAAA,+BAAA,CAAA;GAAI,WAAW;EAAe,CAAA;EAG3C,KAAA,cAAc,MAAgC,WAAU,GAAA,YAAA,CAAA,EAAA,WAAA,cAAA,CAAA,+BAAA,CAAA,CAAA;EAGxD,KAAA,wBAAwB,MAAM,OAAK;GAAA,GAAA,YAAA,EAAA,WAAA,wBAAA,+BAAA,CAAA;GAAI,WAAW;EAAgB,CAAA;CAM5E;CAJC,oBAAiB;EAEf,OAAO,EAAE,WAAW,WADL,KAAK,MAAK,IAAK,KAAK,IAAG,MAAO,KAAK,IAAG,IAAK,KA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