tering-serieuze-types 1.3.3 → 1.5.0

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.
package/dist/index.js ADDED
@@ -0,0 +1,55 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all)
7
+ __defProp(target, name, { get: all[name], enumerable: true });
8
+ };
9
+ var __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from === "object" || typeof from === "function") {
11
+ for (let key of __getOwnPropNames(from))
12
+ if (!__hasOwnProp.call(to, key) && key !== except)
13
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
+ }
15
+ return to;
16
+ };
17
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
+ var __decorateClass = (decorators, target, key, kind) => {
19
+ var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
20
+ for (var i = decorators.length - 1, decorator; i >= 0; i--)
21
+ if (decorator = decorators[i])
22
+ result = (kind ? decorator(target, key, result) : decorator(result)) || result;
23
+ if (kind && result)
24
+ __defProp(target, key, result);
25
+ return result;
26
+ };
27
+
28
+ // src/index.ts
29
+ var src_exports = {};
30
+ __export(src_exports, {
31
+ AddUserDto: () => AddUserDto,
32
+ PlayJingleDto: () => PlayJingleDto
33
+ });
34
+ module.exports = __toCommonJS(src_exports);
35
+ var import_swagger = require("@nestjs/swagger");
36
+ var import_class_validator = require("class-validator");
37
+ var PlayJingleDto = class {
38
+ };
39
+ __decorateClass([
40
+ (0, import_swagger.ApiProperty)({ type: String, example: "keeskankerkachel" })
41
+ ], PlayJingleDto.prototype, "folder", 2);
42
+ __decorateClass([
43
+ (0, import_swagger.ApiProperty)({ type: String, example: "aan.mp3" })
44
+ ], PlayJingleDto.prototype, "file", 2);
45
+ var AddUserDto = class {
46
+ };
47
+ __decorateClass([
48
+ (0, import_class_validator.IsEmail)(),
49
+ (0, import_swagger.ApiProperty)({ type: String, example: "info@example.com" })
50
+ ], AddUserDto.prototype, "email", 2);
51
+ // Annotate the CommonJS export names for ESM import in node:
52
+ 0 && (module.exports = {
53
+ AddUserDto,
54
+ PlayJingleDto
55
+ });
package/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  export * from './interfaces';
2
+ export * from './src';
2
3
 
3
4
  export type FlicButtonPayload = {
4
5
  bdAddr: string;
@@ -18,3 +19,4 @@ export type BrandweerPayload = {
18
19
  description: string;
19
20
  pubDate: Date;
20
21
  };
22
+
@@ -39,15 +39,7 @@ export interface WebsocketAction {
39
39
  data: any;
40
40
  }
41
41
 
42
- export interface PlayJingleDto {
43
- folder: string;
44
-
45
- file: string;
46
- }
47
42
 
48
- export interface AddUserDto {
49
- email: string;
50
- }
51
43
 
52
44
  export interface RemoveUserDto {
53
45
  id: number;
package/package.json CHANGED
@@ -1,14 +1,23 @@
1
1
  {
2
2
  "name": "tering-serieuze-types",
3
- "version": "1.3.3",
3
+ "version": "1.5.0",
4
4
  "description": "Tering serieuze types",
5
5
  "author": "Frank",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "https://gitlab.com/tering-serieuze-shit/tering-serieuze-types.git"
9
9
  },
10
+ "scripts": {
11
+ "build": "esbuild src/index.ts --bundle --platform=node --outfile=dist/index.js --packages=external"
12
+ },
13
+ "main": "dist/index.js",
10
14
  "types": "index.d.ts",
11
15
  "devDependencies": {
16
+ "esbuild": "^0.16.10",
12
17
  "prettier": "^2.8.0"
18
+ },
19
+ "dependencies": {
20
+ "@nestjs/swagger": "^6.1.4",
21
+ "class-validator": "^0.13.2"
13
22
  }
14
23
  }
package/src/index.ts ADDED
@@ -0,0 +1,16 @@
1
+ import { ApiProperty } from '@nestjs/swagger';
2
+ import { IsEmail } from 'class-validator';
3
+
4
+ export class PlayJingleDto {
5
+ @ApiProperty({ type: String, example: 'keeskankerkachel' })
6
+ folder: string;
7
+
8
+ @ApiProperty({ type: String, example: 'aan.mp3' })
9
+ file: string;
10
+ }
11
+
12
+ export class AddUserDto {
13
+ @IsEmail()
14
+ @ApiProperty({ type: String, example: 'info@example.com' })
15
+ email: string;
16
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,6 @@
1
+ // tsconfig.json
2
+ {
3
+ "compilerOptions": {
4
+ "experimentalDecorators": true
5
+ }
6
+ }