mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-08-28 12:43:06 +08:00
Merge pull request #6089 from danmarshall/master
added layer to Maker.js 0.4.3
This commit is contained in:
@@ -116,6 +116,15 @@ function test() {
|
||||
new makerjs.paths.Chord(paths.arc);
|
||||
new makerjs.paths.Parallel(paths.line, 4, [1,1]);
|
||||
|
||||
//paths.line.layer = "0";
|
||||
|
||||
var x: MakerJs.IPathLine = {
|
||||
type: "line",
|
||||
origin: [9,9],
|
||||
end: [8,8],
|
||||
layer: "4"
|
||||
};
|
||||
|
||||
return paths;
|
||||
}
|
||||
|
||||
|
||||
Vendored
+12
-4
@@ -96,11 +96,15 @@ declare module MakerJs {
|
||||
/**
|
||||
* The type of the path, e.g. "line", "circle", or "arc". These strings are enumerated in pathType.
|
||||
*/
|
||||
type: string;
|
||||
"type": string;
|
||||
/**
|
||||
* The main point of reference for this path.
|
||||
*/
|
||||
origin: IPoint;
|
||||
/**
|
||||
* Optional layer of this path.
|
||||
*/
|
||||
layer?: string;
|
||||
}
|
||||
/**
|
||||
* Test to see if an object implements the required properties of a path.
|
||||
@@ -193,7 +197,7 @@ declare module MakerJs {
|
||||
/**
|
||||
* Key is the type of a path, value is a function which accepts a path object a point object as its parameters.
|
||||
*/
|
||||
[type: string]: (id: string, pathValue: IPath, origin: IPoint) => void;
|
||||
[type: string]: (id: string, pathValue: IPath, origin: IPoint, layer: string) => void;
|
||||
}
|
||||
/**
|
||||
* String-based enumeration of all paths types.
|
||||
@@ -276,7 +280,7 @@ declare module MakerJs {
|
||||
/**
|
||||
* A model may want to specify its type, but this value is not employed yet.
|
||||
*/
|
||||
type?: string;
|
||||
"type"?: string;
|
||||
/**
|
||||
* Optional array of path objects in this model.
|
||||
*/
|
||||
@@ -293,6 +297,10 @@ declare module MakerJs {
|
||||
* An author may wish to add notes to this model instance.
|
||||
*/
|
||||
notes?: string;
|
||||
/**
|
||||
* Optional layer of this model.
|
||||
*/
|
||||
layer?: string;
|
||||
}
|
||||
/**
|
||||
* Test to see if an object implements the required properties of a model.
|
||||
@@ -844,7 +852,7 @@ declare module MakerJs.exporter {
|
||||
* @param pathToExport The path to export.
|
||||
* @param offset The offset position of the path.
|
||||
*/
|
||||
exportPath(id: string, pathToExport: IPath, offset: IPoint): void;
|
||||
exportPath(id: string, pathToExport: IPath, offset: IPoint, layer: string): void;
|
||||
/**
|
||||
* Export a model.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user