pixelflut 1.6.0 → 1.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,33 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ /* eslint-disable no-magic-numbers */
11
+ import { describe, test } from 'vitest';
12
+ import { Pixelflut } from './index.js';
13
+ describe.skip('Pixelflut', () => {
14
+ const pf = new Pixelflut('localhost', 8080, 0);
15
+ test('sends a pixel', () => __awaiter(void 0, void 0, void 0, function* () {
16
+ const data = yield pf.sendPixel(200, 200, 'ff0000');
17
+ if (data) {
18
+ console.info(data);
19
+ }
20
+ }));
21
+ test('sends many pixels', () => __awaiter(void 0, void 0, void 0, function* () {
22
+ const pixels = Array.from(Array(100), (_, index) => ({
23
+ color: '00ff00',
24
+ xPosition: index,
25
+ yPosition: index,
26
+ }));
27
+ const data = yield pf.sendPixels(pixels);
28
+ if (data) {
29
+ console.info('data', data);
30
+ }
31
+ }));
32
+ });
33
+ //# sourceMappingURL=index.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.test.js","sourceRoot":"","sources":["../../src/index.test.ts"],"names":[],"mappings":";;;;;;;;;AAAA,qCAAqC;AACrC,OAAO,EAAC,QAAQ,EAAE,IAAI,EAAC,MAAM,QAAQ,CAAC;AACtC,OAAO,EAAC,SAAS,EAAC,MAAM,YAAY,CAAC;AAErC,QAAQ,CAAC,IAAI,CAAC,WAAW,EAAE,GAAG,EAAE;IAC9B,MAAM,EAAE,GAAG,IAAI,SAAS,CAAC,WAAW,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;IAE/C,IAAI,CAAC,eAAe,EAAE,GAAS,EAAE;QAC/B,MAAM,IAAI,GAAG,MAAM,EAAE,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,QAAQ,CAAC,CAAC;QACpD,IAAI,IAAI,EAAE;YACR,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;SACpB;IACH,CAAC,CAAA,CAAC,CAAC;IAEH,IAAI,CAAC,mBAAmB,EAAE,GAAS,EAAE;QACnC,MAAM,MAAM,GAAG,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,CAAC,CAAC;YACnD,KAAK,EAAE,QAAQ;YACf,SAAS,EAAE,KAAK;YAChB,SAAS,EAAE,KAAK;SACjB,CAAC,CAAC,CAAC;QAEJ,MAAM,IAAI,GAAG,MAAM,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;QACzC,IAAI,IAAI,EAAE;YACR,OAAO,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;SAC5B;IACH,CAAC,CAAA,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,24 @@
1
+ /* eslint-disable no-magic-numbers */
2
+ import { describe, test } from 'vitest';
3
+ import { Pixelflut } from './index.js';
4
+ describe.skip('Pixelflut', () => {
5
+ const pf = new Pixelflut('localhost', 8080, 0);
6
+ test('sends a pixel', async () => {
7
+ const data = await pf.sendPixel(200, 200, 'ff0000');
8
+ if (data) {
9
+ console.info(data);
10
+ }
11
+ });
12
+ test('sends many pixels', async () => {
13
+ const pixels = Array.from(Array(100), (_, index) => ({
14
+ color: '00ff00',
15
+ xPosition: index,
16
+ yPosition: index,
17
+ }));
18
+ const data = await pf.sendPixels(pixels);
19
+ if (data) {
20
+ console.info('data', data);
21
+ }
22
+ });
23
+ });
24
+ //# sourceMappingURL=index.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.test.js","sourceRoot":"","sources":["../../src/index.test.ts"],"names":[],"mappings":"AAAA,qCAAqC;AACrC,OAAO,EAAC,QAAQ,EAAE,IAAI,EAAC,MAAM,QAAQ,CAAC;AACtC,OAAO,EAAC,SAAS,EAAC,MAAM,YAAY,CAAC;AAErC,QAAQ,CAAC,IAAI,CAAC,WAAW,EAAE,GAAG,EAAE;IAC9B,MAAM,EAAE,GAAG,IAAI,SAAS,CAAC,WAAW,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;IAE/C,IAAI,CAAC,eAAe,EAAE,KAAK,IAAI,EAAE;QAC/B,MAAM,IAAI,GAAG,MAAM,EAAE,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,QAAQ,CAAC,CAAC;QACpD,IAAI,IAAI,EAAE;YACR,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;SACpB;IACH,CAAC,CAAC,CAAC;IAEH,IAAI,CAAC,mBAAmB,EAAE,KAAK,IAAI,EAAE;QACnC,MAAM,MAAM,GAAG,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,CAAC,CAAC;YACnD,KAAK,EAAE,QAAQ;YACf,SAAS,EAAE,KAAK;YAChB,SAAS,EAAE,KAAK;SACjB,CAAC,CAAC,CAAC;QAEJ,MAAM,IAAI,GAAG,MAAM,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;QACzC,IAAI,IAAI,EAAE;YACR,OAAO,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;SAC5B;IACH,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,8 +1,6 @@
1
1
  {
2
2
  "author": "Florian Imdahl <git@ffflorian.de>",
3
- "bin": {
4
- "pixelflut": "dist/cjs/cli.js"
5
- },
3
+ "bin": "dist/cjs/cli.js",
6
4
  "description": "Flood pixels",
7
5
  "devDependencies": {
8
6
  "rimraf": "5.0.5",
@@ -24,9 +22,9 @@
24
22
  "dist": "yarn clean && yarn build",
25
23
  "generate:packagejson": "../../bin/generate-hybrid-package-json.sh",
26
24
  "start": "ts-node-esm src/cli.ts",
27
- "test": "ts-node-esm -P tsconfig.jasmine.json ../../node_modules/.bin/jasmine"
25
+ "test": "vitest run"
28
26
  },
29
27
  "type": "module",
30
- "version": "1.6.0",
31
- "gitHead": "e7bb24502cde477597fa401ea467f8d463323cda"
28
+ "version": "1.6.2",
29
+ "gitHead": "f5134e8663185ed1ff19e0291a7a2da86c0aa39e"
32
30
  }