nicot 1.4.1 → 1.4.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.
@@ -1,5 +1,5 @@
1
- import { AnyClass, ClassType } from 'nesties';
2
- import { OperationObject } from '@nestjs/swagger/dist/interfaces/open-api-spec.interface';
1
+ import type { AnyClass, ClassType } from 'nesties';
2
+ import { ApiOperationOptions } from '@nestjs/swagger';
3
3
  import { CrudBase, CrudOptions } from './crud-base';
4
4
  import { PageSettingsDto } from './bases';
5
5
  import { CursorPaginationDto } from './dto';
@@ -21,7 +21,7 @@ export interface RestfulFactoryOptions<T, O extends keyof T = never, W extends k
21
21
  skipNonQueryableFields?: boolean;
22
22
  upsertIncludeRelations?: boolean;
23
23
  }
24
- export interface ResourceOptions extends Partial<OperationObject> {
24
+ export interface ResourceOptions extends ApiOperationOptions {
25
25
  prefix?: string;
26
26
  }
27
27
  export declare class RestfulFactory<T extends {
@@ -0,0 +1,3 @@
1
+ import type { ApiPropertyOptions } from '@nestjs/swagger';
2
+ import type { AnyClass } from 'nesties';
3
+ export declare const getApiProperty: (cls: AnyClass, key: string) => ApiPropertyOptions;
@@ -1,2 +1,2 @@
1
- import { AnyClass } from 'nesties';
1
+ import type { AnyClass } from 'nesties';
2
2
  export declare const PatchColumnsInGet: <C extends AnyClass>(cl: C, originalCl?: AnyClass, fieldsToOmit?: string[]) => C;
@@ -0,0 +1,23 @@
1
+ export interface SwaggerDecorators {
2
+ API_OPERATION: string;
3
+ API_RESPONSE: string;
4
+ API_PRODUCES: string;
5
+ API_CONSUMES: string;
6
+ API_TAGS: string;
7
+ API_WEBHOOK: string;
8
+ API_CALLBACKS: string;
9
+ API_PARAMETERS: string;
10
+ API_HEADERS: string;
11
+ API_MODEL_PROPERTIES: string;
12
+ API_MODEL_PROPERTIES_ARRAY: string;
13
+ API_SECURITY: string;
14
+ API_EXCLUDE_ENDPOINT: string;
15
+ API_INCLUDE_ENDPOINT: string;
16
+ API_EXCLUDE_CONTROLLER: string;
17
+ API_EXTRA_MODELS: string;
18
+ API_EXTENSION: string;
19
+ API_SCHEMA: string;
20
+ API_DEFAULT_GETTER: string;
21
+ API_LINK: string;
22
+ }
23
+ export declare const DECORATORS: SwaggerDecorators;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "nicot",
3
3
  "description": "Nest.js interacting with class-validator + OpenAPI + TypeORM for Nest.js Restful API development.",
4
- "version": "1.4.1",
4
+ "version": "1.4.2",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.mjs",
7
7
  "types": "dist/index.d.ts",
@@ -68,6 +68,7 @@
68
68
  "devDependencies": {
69
69
  "@nestjs/core": "^11.0.14",
70
70
  "@nestjs/platform-express": "^11.0.14",
71
+ "@nestjs/swagger": "^11.4.4",
71
72
  "@nestjs/testing": "^11.0.14",
72
73
  "@nestjs/typeorm": "^11.0.1",
73
74
  "@types/jest": "^29.5.14",
@@ -103,7 +104,7 @@
103
104
  },
104
105
  "dependencies": {
105
106
  "lodash": "^4.17.21",
106
- "nesties": "^1.1.33",
107
+ "nesties": "^1.1.34",
107
108
  "nfkit": "^1.0.13",
108
109
  "p-queue": "6.6.2",
109
110
  "reflect-metadata": "^0.2.2",