1.1.1 • Published 4 months ago

schertech_shapes v1.1.1

Weekly downloads
-
License
ISC
Repository
-
Last release
4 months ago

Schertech 2d

A short description.

Constrains:

  • For each type div id must be unique.

Installation

npm i schertech_shapes

HTML

<div id="divid" class="svg-container"></div>

CSS

.svg-container {
  width: 100em;
  height: 40em;
  resize: both;
  overflow: auto;
  border: 1px dashed #aaa;
 }

 svg {
  width: 100%;
  height: 100%;
 }

Typescript/JavaScript

Type Bar

For type one height, weight and a div id is required.

import {ShapeFactory,ShapeType} from "schertech_shapes";

new ShapeFactory(ShapeType.One,"#divid", { height: 200, width: 600 });

Type Perforated Disk

For type one height, weight, a div and radius id is required.

import {ShapeFactory,ShapeType} from "schertech_shapes";

new  ShapeFactory(ShapeType.Two,"#divid", { height: 600, width: 600,innerWidth: 200,radiusOne:10,radiusTwo:10,radiusThree:10,radiusFour:10});

Type Ring

For type one height, weight, inner width and a div id is required.

import {ShapeFactory,ShapeType} from "schertech_shapes";

new ShapeFactory(ShapeType.Three,"#divid", { height: 100, width: 600,innerWidth: 400,});

Type Disk

For type one height, weight and a div id is required.

import {ShapeFactory,ShapeType} from "schertech_shapes";

new ShapeFactory(ShapeType.Four,"#divid", { height: 100, width: 600});

Type Pipe

For type one height, weight, inner height and a div id is required.

import {ShapeFactory,ShapeType} from "schertech_shapes";

new ShapeFactory(ShapeType.Five,"#divid", { height: 200, width: 200,innerHeight:50});

Shapes

Type Bar

For type one height, weight and a div id is required. Alt text

Type Perforated Disk

For type one height, weight, a div and radius id is required. Alt text

Type Ring

For type one height, weight, inner width and a div id is required. Alt text

Type Disk

For type one height, weight and a div id is required. Alt text

Type Pipe

For type one height, weight, inner height and a div id is required.

Alt text

1.1.1

4 months ago

1.1.0

4 months ago

1.0.11

5 months ago

1.0.15

5 months ago

1.0.14

5 months ago

1.0.13

5 months ago

1.0.12

5 months ago

1.0.10

5 months ago

1.0.9

5 months ago

1.0.8

5 months ago

1.0.7

5 months ago

1.0.6

5 months ago

1.0.5

5 months ago

1.0.4

5 months ago

1.0.3

5 months ago

1.0.2

5 months ago

1.0.1

5 months ago

1.0.0

5 months ago