mirror of
https://github.com/konvajs/konva.git
synced 2025-06-28 00:14:29 +08:00
add types
This commit is contained in:
parent
a4980fccdc
commit
09f2838d43
@ -1,13 +1,13 @@
|
|||||||
import { Factory } from '../Factory';
|
import { Factory } from '../Factory';
|
||||||
import { Shape, ShapeConfig } from '../Shape';
|
|
||||||
import { _registerNode } from '../Global';
|
import { _registerNode } from '../Global';
|
||||||
|
import { Shape, ShapeConfig } from '../Shape';
|
||||||
|
|
||||||
import { GetSet, PathSegment } from '../types';
|
|
||||||
import {
|
import {
|
||||||
getCubicArcLength,
|
getCubicArcLength,
|
||||||
getQuadraticArcLength,
|
getQuadraticArcLength,
|
||||||
t2length,
|
t2length,
|
||||||
} from '../BezierFunctions';
|
} from '../BezierFunctions';
|
||||||
|
import { GetSet, PathSegment } from '../types';
|
||||||
|
|
||||||
export interface PathConfig extends ShapeConfig {
|
export interface PathConfig extends ShapeConfig {
|
||||||
data?: string;
|
data?: string;
|
||||||
@ -858,15 +858,15 @@ export class Path extends Shape<PathConfig> {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
static convertEndpointToCenterParameterization(
|
static convertEndpointToCenterParameterization(
|
||||||
x1,
|
x1: number,
|
||||||
y1,
|
y1: number,
|
||||||
x2,
|
x2: number,
|
||||||
y2,
|
y2: number,
|
||||||
fa,
|
fa: number,
|
||||||
fs,
|
fs: number,
|
||||||
rx,
|
rx: number,
|
||||||
ry,
|
ry: number,
|
||||||
psiDeg
|
psiDeg: number
|
||||||
) {
|
) {
|
||||||
// Derived from: http://www.w3.org/TR/SVG/implnote.html#ArcImplementationNotes
|
// Derived from: http://www.w3.org/TR/SVG/implnote.html#ArcImplementationNotes
|
||||||
const psi = psiDeg * (Math.PI / 180.0);
|
const psi = psiDeg * (Math.PI / 180.0);
|
||||||
|
Loading…
Reference in New Issue
Block a user