@xoxno/types 1.0.59 → 1.0.61
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/cosmos-db/cosmos-db-paginated-response.dto.d.ts +6 -0
- package/dist/cosmos-db/cosmos-db-paginated-response.dto.js +31 -1
- package/dist/cosmos-db/paginated-responses.d.ts +2 -2
- package/dist/cosmos-db/paginated-responses.js +1 -1
- package/dist/requests/nft-activity-data/marketplace-activity.enum.d.ts +2 -1
- package/dist/requests/nft-activity-data/marketplace-activity.enum.js +1 -0
- package/package.json +1 -1
|
@@ -4,6 +4,12 @@ export declare class CosmosPaginatedResponse<T> {
|
|
|
4
4
|
resources: T[];
|
|
5
5
|
constructor(resources: T[], count: number | null, hasMoreResults: boolean);
|
|
6
6
|
}
|
|
7
|
+
export declare class CosmosPaginatedSingleResponse<T> {
|
|
8
|
+
count: number | null;
|
|
9
|
+
hasMoreResults: boolean;
|
|
10
|
+
resources: T;
|
|
11
|
+
constructor(resources: T, count: number | null, hasMoreResults: boolean);
|
|
12
|
+
}
|
|
7
13
|
export declare function createCosmosPaginatedResponse<T>(type: new () => T): {
|
|
8
14
|
new (resources: T[], count: number | null, hasMoreResults: boolean): {
|
|
9
15
|
resources: T[];
|
|
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.CosmosPaginatedResponse = void 0;
|
|
12
|
+
exports.CosmosPaginatedSingleResponse = exports.CosmosPaginatedResponse = void 0;
|
|
13
13
|
exports.createCosmosPaginatedResponse = createCosmosPaginatedResponse;
|
|
14
14
|
const swagger_1 = require("@nestjs/swagger");
|
|
15
15
|
class CosmosPaginatedResponse {
|
|
@@ -44,6 +44,36 @@ __decorate([
|
|
|
44
44
|
}),
|
|
45
45
|
__metadata("design:type", Array)
|
|
46
46
|
], CosmosPaginatedResponse.prototype, "resources", void 0);
|
|
47
|
+
class CosmosPaginatedSingleResponse {
|
|
48
|
+
constructor(resources, count, hasMoreResults) {
|
|
49
|
+
this.hasMoreResults = false;
|
|
50
|
+
this.resources = resources;
|
|
51
|
+
this.count = count;
|
|
52
|
+
this.hasMoreResults = hasMoreResults;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
exports.CosmosPaginatedSingleResponse = CosmosPaginatedSingleResponse;
|
|
56
|
+
__decorate([
|
|
57
|
+
(0, swagger_1.ApiProperty)({
|
|
58
|
+
description: 'Total number of documents',
|
|
59
|
+
example: 100,
|
|
60
|
+
required: false,
|
|
61
|
+
}),
|
|
62
|
+
__metadata("design:type", Object)
|
|
63
|
+
], CosmosPaginatedSingleResponse.prototype, "count", void 0);
|
|
64
|
+
__decorate([
|
|
65
|
+
(0, swagger_1.ApiProperty)({
|
|
66
|
+
description: 'Indicates if there are more documents available',
|
|
67
|
+
example: true,
|
|
68
|
+
}),
|
|
69
|
+
__metadata("design:type", Boolean)
|
|
70
|
+
], CosmosPaginatedSingleResponse.prototype, "hasMoreResults", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, swagger_1.ApiProperty)({
|
|
73
|
+
description: 'List of documents',
|
|
74
|
+
}),
|
|
75
|
+
__metadata("design:type", Object)
|
|
76
|
+
], CosmosPaginatedSingleResponse.prototype, "resources", void 0);
|
|
47
77
|
function createCosmosPaginatedResponse(type) {
|
|
48
78
|
class PaginatedResponse extends CosmosPaginatedResponse {
|
|
49
79
|
constructor() {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { OwnerDto } from '../common/owner.dto';
|
|
2
2
|
import { GlobalSearchResourcesDto } from '../entities/search-data/search.dto';
|
|
3
|
-
import { CosmosPaginatedResponse } from './cosmos-db-paginated-response.dto';
|
|
3
|
+
import { CosmosPaginatedResponse, CosmosPaginatedSingleResponse } from './cosmos-db-paginated-response.dto';
|
|
4
4
|
import { NftActivityDocHydrated } from './documents/activity/nft-activity.doc';
|
|
5
5
|
import { ChatMessageDocHydrated } from './documents/chat/chat-message.doc';
|
|
6
6
|
import { UserBlockDocHydrated } from './documents/chat/user-block.doc';
|
|
@@ -17,7 +17,7 @@ export declare class EventReferralConfigPaginated extends CosmosPaginatedRespons
|
|
|
17
17
|
}
|
|
18
18
|
export declare class EventReferralPaginated extends CosmosPaginatedResponse<EventReferralDoc> {
|
|
19
19
|
}
|
|
20
|
-
export declare class GlobalSearchResourcesPaginated extends
|
|
20
|
+
export declare class GlobalSearchResourcesPaginated extends CosmosPaginatedSingleResponse<GlobalSearchResourcesDto> {
|
|
21
21
|
}
|
|
22
22
|
export declare class UserBlockPaginated extends CosmosPaginatedResponse<UserBlockDocHydrated> {
|
|
23
23
|
}
|
|
@@ -8,7 +8,7 @@ exports.EventReferralConfigPaginated = EventReferralConfigPaginated;
|
|
|
8
8
|
class EventReferralPaginated extends cosmos_db_paginated_response_dto_1.CosmosPaginatedResponse {
|
|
9
9
|
}
|
|
10
10
|
exports.EventReferralPaginated = EventReferralPaginated;
|
|
11
|
-
class GlobalSearchResourcesPaginated extends cosmos_db_paginated_response_dto_1.
|
|
11
|
+
class GlobalSearchResourcesPaginated extends cosmos_db_paginated_response_dto_1.CosmosPaginatedSingleResponse {
|
|
12
12
|
}
|
|
13
13
|
exports.GlobalSearchResourcesPaginated = GlobalSearchResourcesPaginated;
|
|
14
14
|
class UserBlockPaginated extends cosmos_db_paginated_response_dto_1.CosmosPaginatedResponse {
|
|
@@ -16,5 +16,6 @@ export declare enum MarketplaceActivity {
|
|
|
16
16
|
OFFER_TRADE = "offerTrade",
|
|
17
17
|
GLOBAL_OFFER_TRADE = "globalOfferTrade",
|
|
18
18
|
DEPOSIT = "deposit",
|
|
19
|
-
WITHDRAW_DEPOSIT = "withdrawDeposit"
|
|
19
|
+
WITHDRAW_DEPOSIT = "withdrawDeposit",
|
|
20
|
+
SET_COLLECTION_CONFIG = "setCollectionConfig"
|
|
20
21
|
}
|
|
@@ -21,4 +21,5 @@ var MarketplaceActivity;
|
|
|
21
21
|
MarketplaceActivity["GLOBAL_OFFER_TRADE"] = "globalOfferTrade";
|
|
22
22
|
MarketplaceActivity["DEPOSIT"] = "deposit";
|
|
23
23
|
MarketplaceActivity["WITHDRAW_DEPOSIT"] = "withdrawDeposit";
|
|
24
|
+
MarketplaceActivity["SET_COLLECTION_CONFIG"] = "setCollectionConfig";
|
|
24
25
|
})(MarketplaceActivity || (exports.MarketplaceActivity = MarketplaceActivity = {}));
|