@wrcb/cb-common 1.0.5 → 1.0.7
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/build/events/predictionFinished.d.ts +15 -0
- package/build/events/predictionFinished.js +2 -0
- package/build/events/predictionStarted.d.ts +15 -0
- package/build/events/predictionStarted.js +2 -0
- package/build/events/subjects.d.ts +5 -1
- package/build/events/subjects.js +4 -0
- package/build/events/types/{eventStatus.d.ts → predictionStatus.d.ts} +2 -3
- package/build/events/types/predictionStatus.js +11 -0
- package/build/index.d.ts +1 -1
- package/build/index.js +1 -1
- package/package.json +1 -1
- package/build/events/types/eventStatus.js +0 -12
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Subjects } from './subjects';
|
|
2
|
+
import { PredictionStatus } from './types/predictionStatus';
|
|
3
|
+
export interface PredictionFinishedEvent {
|
|
4
|
+
subject: Subjects.PredictionFinished;
|
|
5
|
+
data: {
|
|
6
|
+
id: string;
|
|
7
|
+
status: PredictionStatus;
|
|
8
|
+
title: string;
|
|
9
|
+
description: string;
|
|
10
|
+
market: {
|
|
11
|
+
id: string;
|
|
12
|
+
marketTitle: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Subjects } from './subjects';
|
|
2
|
+
import { PredictionStatus } from './types/predictionStatus';
|
|
3
|
+
export interface PredictionStartedEvent {
|
|
4
|
+
subject: Subjects.PredictionStarted;
|
|
5
|
+
data: {
|
|
6
|
+
id: string;
|
|
7
|
+
status: PredictionStatus;
|
|
8
|
+
title: string;
|
|
9
|
+
description: string;
|
|
10
|
+
market: {
|
|
11
|
+
id: string;
|
|
12
|
+
marketTitle: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
export declare enum Subjects {
|
|
2
2
|
CommentCreated = "comment:created",
|
|
3
|
-
CommentUpdated = "comment:updated"
|
|
3
|
+
CommentUpdated = "comment:updated",
|
|
4
|
+
PredictionCreated = "prediction:created",
|
|
5
|
+
PredictionStarted = "prediction:started",
|
|
6
|
+
PredictionFinished = "prediction:finished",
|
|
7
|
+
PredictionPaymentProcessed = "prediction:paymentprocessed"
|
|
4
8
|
}
|
package/build/events/subjects.js
CHANGED
|
@@ -5,4 +5,8 @@ var Subjects;
|
|
|
5
5
|
(function (Subjects) {
|
|
6
6
|
Subjects["CommentCreated"] = "comment:created";
|
|
7
7
|
Subjects["CommentUpdated"] = "comment:updated";
|
|
8
|
+
Subjects["PredictionCreated"] = "prediction:created";
|
|
9
|
+
Subjects["PredictionStarted"] = "prediction:started";
|
|
10
|
+
Subjects["PredictionFinished"] = "prediction:finished";
|
|
11
|
+
Subjects["PredictionPaymentProcessed"] = "prediction:paymentprocessed";
|
|
8
12
|
})(Subjects || (exports.Subjects = Subjects = {}));
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PredictionStatus = void 0;
|
|
4
|
+
var PredictionStatus;
|
|
5
|
+
(function (PredictionStatus) {
|
|
6
|
+
PredictionStatus["Created"] = "created";
|
|
7
|
+
// Confirmed = 'confirmed', // aposta que foi confirmada mas não iniciou o evento (preciso disso?)
|
|
8
|
+
PredictionStatus["Started"] = "started";
|
|
9
|
+
PredictionStatus["Finished"] = "finished";
|
|
10
|
+
PredictionStatus["PaymentProcessed"] = "payment:processed";
|
|
11
|
+
})(PredictionStatus || (exports.PredictionStatus = PredictionStatus = {}));
|
package/build/index.d.ts
CHANGED
|
@@ -13,5 +13,5 @@ export * from './events/basePublisher';
|
|
|
13
13
|
export * from './events/subjects';
|
|
14
14
|
export * from './events/commentCreatedEvent';
|
|
15
15
|
export * from './events/commentUpdatedEvent';
|
|
16
|
-
export * from './events/types/
|
|
16
|
+
export * from './events/types/predictionStatus';
|
|
17
17
|
export * from './events/types/marketStatus';
|
package/build/index.js
CHANGED
|
@@ -29,5 +29,5 @@ __exportStar(require("./events/basePublisher"), exports);
|
|
|
29
29
|
__exportStar(require("./events/subjects"), exports);
|
|
30
30
|
__exportStar(require("./events/commentCreatedEvent"), exports);
|
|
31
31
|
__exportStar(require("./events/commentUpdatedEvent"), exports);
|
|
32
|
-
__exportStar(require("./events/types/
|
|
32
|
+
__exportStar(require("./events/types/predictionStatus"), exports);
|
|
33
33
|
__exportStar(require("./events/types/marketStatus"), exports);
|
package/package.json
CHANGED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.EventStatus = void 0;
|
|
4
|
-
var EventStatus;
|
|
5
|
-
(function (EventStatus) {
|
|
6
|
-
EventStatus["Pending"] = "pending";
|
|
7
|
-
// Confirmed = 'confirmed', // aposta que foi confirmada mas não iniciou o evento (preciso disso?)
|
|
8
|
-
EventStatus["Started"] = "started";
|
|
9
|
-
EventStatus["Cancelled"] = "cancelled";
|
|
10
|
-
EventStatus["Finished"] = "finished";
|
|
11
|
-
EventStatus["PaymentProcessed"] = "payment:processed";
|
|
12
|
-
})(EventStatus || (exports.EventStatus = EventStatus = {}));
|