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AI,UAAU,SAAI,UAAU,WAAM,YAAY,SAAI,QAAQ,SAAI,GAAK,CAAC;AACtF,CAAC;AAOD;IAAA;IAOA,CAAC;IANQ,8BAAO,GAAd;QACE,MAAM,CAAC;YACL,QAAQ,EAAE,sBAAsB;YAChC,SAAS,EAAE,EAAE;SACd,CAAC;IACJ,CAAC;IAVH;QAAC,QAAQ,CAAC;YACR,OAAO,EAAE,CAAC,gBAAgB,EAAE,SAAS,CAAC;YACtC,YAAY,EAAE,CAAC,gBAAgB,EAAE,SAAS,CAAC;SAC5C,CAAC;;8BAAA;IAQF,6BAAC;AAAD,CAPA,AAOC,IAAA","file":"progress-circle/progress-circle.js","sourcesContent":["import {\n NgModule,\n ModuleWithProviders,\n Component,\n HostBinding,\n ChangeDetectorRef,\n ChangeDetectionStrategy,\n OnDestroy,\n Input\n} from '@angular/core';\n\n// TODO(josephperrott): Benchpress tests.\n\n/** A single degree in radians. */\nconst DEGREE_IN_RADIANS = Math.PI / 180;\n/** Duration of the indeterminate animation. */\nconst DURATION_INDETERMINATE = 667;\n/** Duration of the indeterminate animation. */\nconst DURATION_DETERMINATE = 225;\n/** Start animation value of the indeterminate animation */\nconst startIndeterminate = 3;\n/** End animation value of the indeterminate animation */\nconst endIndeterminate = 80;\n\n\nexport type ProgressCircleMode = 'determinate' | 'indeterminate';\n\ntype EasingFn = (currentTime: number, startValue: number,\n changeInValue: number, duration: number) => number\n\n\n/**\n * <md-progress-circle> component.\n */\n@Component({\n moduleId: module.id,\n selector: 'md-progress-circle',\n host: {\n 'role': 'progressbar',\n '[attr.aria-valuemin]': '_ariaValueMin',\n '[attr.aria-valuemax]': '_ariaValueMax',\n },\n templateUrl: 'progress-circle.html',\n styleUrls: ['progress-circle.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class MdProgressCircle implements OnDestroy {\n /** The id of the last requested animation. */\n private _lastAnimationId: number = 0;\n\n /** The id of the indeterminate interval. */\n private _interdeterminateInterval: number;\n\n /**\n * Values for aria max and min are only defined as numbers when in a determinate mode. We do this\n * because voiceover does not report the progress indicator as indeterminate if the aria min\n * and/or max value are number values.\n */\n get _ariaValueMin() {\n return this.mode == 'determinate' ? 0 : null;\n }\n\n get _ariaValueMax() {\n return this.mode == 'determinate' ? 100 : null;\n }\n\n /** TODO: internal */\n get interdeterminateInterval() {\n return this._interdeterminateInterval;\n }\n /** TODO: internal */\n set interdeterminateInterval(interval: number) {\n clearInterval(this._interdeterminateInterval);\n this._interdeterminateInterval = interval;\n }\n\n /** The current path value, representing the progress circle. */\n private _currentPath: string;\n\n /** TODO: internal */\n get currentPath() {\n return this._currentPath;\n }\n set currentPath(path: string) {\n this._currentPath = path;\n // Mark for check as our ChangeDetectionStrategy is OnPush, when changes come from within the\n // component, change detection must be called for.\n this._changeDetectorRef.markForCheck();\n }\n\n /** Clean up any animations that were running. */\n ngOnDestroy() {\n this._cleanupIndeterminateAnimation();\n }\n\n /**\n * Value of the progress circle.\n *\n * Input:number\n * _value is bound to the host as the attribute aria-valuenow.\n */\n private _value: number;\n @Input()\n @HostBinding('attr.aria-valuenow')\n get value() {\n if (this.mode == 'determinate') {\n return this._value;\n }\n }\n set value(v: number) {\n if (v && this.mode == 'determinate') {\n let newValue = clamp(v);\n this._animateCircle((this.value || 0), newValue, linearEase, DURATION_DETERMINATE, 0);\n this._value = newValue;\n }\n }\n\n /**\n * Mode of the progress circle\n *\n * Input must be one of the values from ProgressMode, defaults to 'determinate'.\n * mode is bound to the host as the attribute host.\n */\n @HostBinding('attr.mode')\n @Input()\n get mode() {\n return this._mode;\n }\n set mode(m: ProgressCircleMode) {\n if (m == 'indeterminate') {\n this._startIndeterminateAnimation();\n } else {\n this._cleanupIndeterminateAnimation();\n }\n this._mode = m;\n }\n private _mode: ProgressCircleMode = 'determinate';\n\n constructor(private _changeDetectorRef: ChangeDetectorRef) {\n }\n\n\n /**\n * Animates the circle from one percentage value to another.\n *\n * @param animateFrom The percentage of the circle filled starting the animation.\n * @param animateTo The percentage of the circle filled ending the animation.\n * @param ease The easing function to manage the pace of change in the animation.\n * @param duration The length of time to show the animation, in milliseconds.\n * @param rotation The starting angle of the circle fill, with 0° represented at the top center\n * of the circle.\n */\n private _animateCircle(animateFrom: number, animateTo: number, ease: EasingFn,\n duration: number, rotation: number) {\n let id = ++this._lastAnimationId;\n let startTime = Date.now();\n let changeInValue = animateTo - animateFrom;\n\n // No need to animate it if the values are the same\n if (animateTo === animateFrom) {\n this.currentPath = getSvgArc(animateTo, rotation);\n } else {\n let animation = () => {\n let elapsedTime = Math.max(0, Math.min(Date.now() - startTime, duration));\n\n this.currentPath = getSvgArc(\n ease(elapsedTime, animateFrom, changeInValue, duration),\n rotation\n );\n\n // Prevent overlapping animations by checking if a new animation has been called for and\n // if the animation has lasted long than the animation duration.\n if (id === this._lastAnimationId && elapsedTime < duration) {\n requestAnimationFrame(animation);\n }\n };\n requestAnimationFrame(animation);\n }\n }\n\n\n /**\n * Starts the indeterminate animation interval, if it is not already running.\n */\n private _startIndeterminateAnimation() {\n let rotationStartPoint = 0;\n let start = startIndeterminate;\n let end = endIndeterminate;\n let duration = DURATION_INDETERMINATE;\n let animate = () => {\n this._animateCircle(start, end, materialEase, duration, rotationStartPoint);\n // Prevent rotation from reaching Number.MAX_SAFE_INTEGER.\n rotationStartPoint = (rotationStartPoint + end) % 100;\n let temp = start;\n start = -end;\n end = -temp;\n };\n\n if (!this.interdeterminateInterval) {\n this.interdeterminateInterval = setInterval(\n animate, duration + 50, 0, false);\n animate();\n }\n }\n\n\n /**\n * Removes interval, ending the animation.\n */\n private _cleanupIndeterminateAnimation() {\n this.interdeterminateInterval = null;\n }\n}\n\n\n/**\n * <md-spinner> component.\n *\n * This is a component definition to be used as a convenience reference to create an\n * indeterminate <md-progress-circle> instance.\n */\n@Component({\n moduleId: module.id,\n selector: 'md-spinner',\n host: {\n 'role': 'progressbar',\n 'mode': 'indeterminate',\n },\n templateUrl: 'progress-circle.html',\n styleUrls: ['progress-circle.css'],\n})\nexport class MdSpinner extends MdProgressCircle {\n constructor(changeDetectorRef: ChangeDetectorRef) {\n super(changeDetectorRef);\n this.mode = 'indeterminate';\n }\n}\n\n\n/**\n * Module functions.\n */\n\n/** Clamps a value to be between 0 and 100. */\nfunction clamp(v: number) {\n return Math.max(0, Math.min(100, v));\n}\n\n\n/**\n * Converts Polar coordinates to Cartesian.\n */\nfunction polarToCartesian(radius: number, pathRadius: number, angleInDegrees: number) {\n let angleInRadians = (angleInDegrees - 90) * DEGREE_IN_RADIANS;\n\n return (radius + (pathRadius * Math.cos(angleInRadians))) +\n ',' + (radius + (pathRadius * Math.sin(angleInRadians)));\n}\n\n\n/**\n * Easing function for linear animation.\n */\nfunction linearEase(currentTime: number, startValue: number,\n changeInValue: number, duration: number) {\n return changeInValue * currentTime / duration + startValue;\n}\n\n\n/**\n * Easing function to match material design indeterminate animation.\n */\nfunction materialEase(currentTime: number, startValue: number,\n changeInValue: number, duration: number) {\n let time = currentTime / duration;\n let timeCubed = Math.pow(time, 3);\n let timeQuad = Math.pow(time, 4);\n let timeQuint = Math.pow(time, 5);\n return startValue + changeInValue * ((6 * timeQuint) + (-15 * timeQuad) + (10 * timeCubed));\n\n}\n\n\n/**\n * Determines the path value to define the arc. Converting percentage values to to polar\n * coordinates on the circle, and then to cartesian coordinates in the viewport.\n *\n * @param currentValue The current percentage value of the progress circle, the percentage of the\n * circle to fill.\n * @param rotation The starting point of the circle with 0 being the 0 degree point.\n * @return A string for an SVG path representing a circle filled from the starting point to the\n * percentage value provided.\n */\nfunction getSvgArc(currentValue: number, rotation: number) {\n // The angle can't be exactly 360, because the arc becomes hidden.\n let maximumAngle = 359.99 / 100;\n let startPoint = rotation || 0;\n let radius = 50;\n let pathRadius = 40;\n\n let startAngle = startPoint * maximumAngle;\n let endAngle = currentValue * maximumAngle;\n let start = polarToCartesian(radius, pathRadius, startAngle);\n let end = polarToCartesian(radius, pathRadius, endAngle + startAngle);\n let arcSweep = endAngle < 0 ? 0 : 1;\n let largeArcFlag: number;\n\n if (endAngle < 0) {\n largeArcFlag = endAngle >= -180 ? 0 : 1;\n } else {\n largeArcFlag = endAngle <= 180 ? 0 : 1;\n }\n\n return `M${start}A${pathRadius},${pathRadius} 0 ${largeArcFlag},${arcSweep} ${end}`;\n}\n\n\n@NgModule({\n exports: [MdProgressCircle, MdSpinner],\n declarations: [MdProgressCircle, MdSpinner],\n})\nexport class MdProgressCircleModule {\n static forRoot(): ModuleWithProviders {\n return {\n ngModule: MdProgressCircleModule,\n providers: []\n };\n }\n}\n"],"sourceRoot":"/source/"}
\No newline at end of file