UNPKG

@instructure/quiz-interactions

Version:

A React UI component Library for quiz interaction types.

17 lines (15 loc) 513 B
// Ellipse polyfill for ie11 based on https://github.com/google/canvas-5-polyfill export function ellipse(x, y, radiusX, radiusY, rotation, startAngle, endAngle, antiClockwise) { this.save() this.translate(x, y) this.rotate(rotation) this.scale(radiusX, radiusY) this.arc(0, 0, 1, startAngle, endAngle, antiClockwise) this.restore() } if ( typeof CanvasRenderingContext2D !== 'undefined' && !CanvasRenderingContext2D.prototype.ellipse ) { CanvasRenderingContext2D.prototype.ellipse = ellipse }