Skip to content

Commit

Permalink
add dist
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyson Decker committed Mar 9, 2022
1 parent 2d1193b commit 9660ca8
Show file tree
Hide file tree
Showing 14 changed files with 85 additions and 52 deletions.
19 changes: 19 additions & 0 deletions dist/enums.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
export declare enum CubePlane {
X = "x",
Y = "y",
Z = "z"
}
export declare enum Side {
L = "L",
R = "R",
U = "U",
D = "D",
F = "F",
B = "B"
}
export declare enum Modifier {
Double = "2",
CounterClockwise = "'",
Clockwise = ""
}
//# sourceMappingURL=enums.d.ts.map
1 change: 1 addition & 0 deletions dist/enums.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions dist/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export declare const cube: (size?: number, numTurns?: number) => String;
export declare const megaminx: () => String;
export declare const pyraminx: (numTurns?: number) => String;
export declare const skewb: (numTurns?: number) => String;
export declare const square1: (numTurns?: number) => any;
//# sourceMappingURL=index.d.ts.map
1 change: 1 addition & 0 deletions dist/index.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 0 additions & 8 deletions dist/index.html

This file was deleted.

2 changes: 1 addition & 1 deletion dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

33 changes: 33 additions & 0 deletions dist/scrambler/scrambler.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
/**
* planes of rotation
* for examples a cube rototes on x,y,z axis
* we don't want to generate two turns in a
* row on the same axis
*/
export declare type RotationPlane = string;
/**
* possible faces to rotate on the puzzle
* (ex, 3x3 has UFLRB)
*/
export declare type Face = string;
/**
* clockwise, counterclockwise...
*/
export declare type Modifer = string;
export declare type PlaneMapping = {
[face: string]: RotationPlane;
};
export declare type Turn = {
face: Face;
depth: number;
modifier: Modifer;
};
export declare const generateCubeScramble: (size?: number, numTurns?: number) => Turn[];
/**
* generates a pochman scramble for the megaminx
*/
export declare const generateMegaminxScramble: (sequenceLength?: number, numSequences?: number) => Turn[][];
export declare const generateSkewbScramble: (numTurns?: number) => Turn[];
export declare const generatePyraminxScramble: (numTurns?: number) => Turn[];
export declare const generateSquare1Scramble: (numTurns?: number) => any;
//# sourceMappingURL=scrambler.d.ts.map
1 change: 1 addition & 0 deletions dist/scrambler/scrambler.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions dist/util.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export declare function randomElement<T>(array: T[]): T;
export declare function shuffle<T>(array: T[]): T[];
//# sourceMappingURL=util.d.ts.map
1 change: 1 addition & 0 deletions dist/util.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

37 changes: 0 additions & 37 deletions index.d.ts

This file was deleted.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
{
"name": "sr-scrambler",
"version": "2.0.0",
"version": "2.0.1",
"description": "utilitiy to generate scrambles for twisty puzzles (rubiks cube, megaminx, pyraminx, skewb, square1)",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build": "webpack --mode production --config webpack.config.js",
Expand Down
20 changes: 16 additions & 4 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,21 @@
{
"compilerOptions": {
"outDir": "./dist/",
"noImplicitAny": true,
"noImplicitAny": false,
"module": "es6",
"target": "es5",
"target": "es6",
"allowJs": true,
}
}
"moduleResolution": "node",
"isolatedModules": true,
"esModuleInterop": true,
"declaration": true,
"declarationMap": true
},
"include": [
"./src"
],
"exclude": [
"./tests",
"./node_modules"
]
}

0 comments on commit 9660ca8

Please sign in to comment.