@brimble/models 3.7.91 → 3.7.93
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/collab-annotation.ts +4 -0
- package/collab-comment.ts +1 -1
- package/collab-push-subscription.ts +19 -0
- package/dist/collab-annotation.js +4 -0
- package/dist/collab-comment.js +1 -1
- package/dist/collab-push-subscription.d.ts +30 -0
- package/dist/collab-push-subscription.js +14 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +4 -2
- package/dist/types/collab-annotation.d.ts +4 -0
- package/dist/types/collab-comment.d.ts +1 -1
- package/dist/types/collab-push-subscription.d.ts +12 -0
- package/dist/types/collab-push-subscription.js +2 -0
- package/dist/types/index.d.ts +1 -0
- package/index.ts +3 -1
- package/package.json +1 -1
- package/types/collab-annotation.ts +4 -0
- package/types/collab-comment.ts +1 -1
- package/types/collab-push-subscription.ts +10 -0
- package/types/index.ts +1 -0
package/collab-annotation.ts
CHANGED
|
@@ -22,6 +22,10 @@ const collabAnnotationSchema = new Schema(
|
|
|
22
22
|
resolvedBy: { type: Schema.Types.ObjectId, ref: "User" },
|
|
23
23
|
guestName: { type: String },
|
|
24
24
|
guestEmail: { type: String },
|
|
25
|
+
githubPrCommentId: { type: Number },
|
|
26
|
+
githubPrCommentUrl: { type: String },
|
|
27
|
+
githubIssueUrl: { type: String },
|
|
28
|
+
githubIssueNumber: { type: Number },
|
|
25
29
|
},
|
|
26
30
|
{ timestamps: true, collection: "annotations" },
|
|
27
31
|
);
|
package/collab-comment.ts
CHANGED
|
@@ -15,7 +15,7 @@ const collabCommentSchema = new Schema(
|
|
|
15
15
|
{
|
|
16
16
|
annotationId: { type: Schema.Types.ObjectId, ref: "CollabAnnotation", required: true, index: true },
|
|
17
17
|
userId: { type: Schema.Types.ObjectId, ref: "User" },
|
|
18
|
-
body: { type: String
|
|
18
|
+
body: { type: String },
|
|
19
19
|
screenshot: { type: String },
|
|
20
20
|
attachments: { type: [collabAttachmentSchema], default: undefined },
|
|
21
21
|
guestName: { type: String },
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { model, Schema } from "mongoose";
|
|
2
|
+
import { ICollabPushSubscription } from "./types";
|
|
3
|
+
|
|
4
|
+
const collabPushSubscriptionSchema = new Schema(
|
|
5
|
+
{
|
|
6
|
+
userId: { type: Schema.Types.ObjectId, ref: "User", required: true, index: true },
|
|
7
|
+
endpoint: { type: String, required: true, unique: true },
|
|
8
|
+
keys: {
|
|
9
|
+
p256dh: { type: String, required: true },
|
|
10
|
+
auth: { type: String, required: true },
|
|
11
|
+
},
|
|
12
|
+
domain: { type: String, required: true, index: true },
|
|
13
|
+
},
|
|
14
|
+
{ timestamps: { createdAt: true, updatedAt: false }, collection: "push_subscriptions" }
|
|
15
|
+
);
|
|
16
|
+
|
|
17
|
+
collabPushSubscriptionSchema.index({ userId: 1, domain: 1 });
|
|
18
|
+
|
|
19
|
+
export default model<ICollabPushSubscription>("CollabPushSubscription", collabPushSubscriptionSchema);
|
|
@@ -21,6 +21,10 @@ const collabAnnotationSchema = new mongoose_1.Schema({
|
|
|
21
21
|
resolvedBy: { type: mongoose_1.Schema.Types.ObjectId, ref: "User" },
|
|
22
22
|
guestName: { type: String },
|
|
23
23
|
guestEmail: { type: String },
|
|
24
|
+
githubPrCommentId: { type: Number },
|
|
25
|
+
githubPrCommentUrl: { type: String },
|
|
26
|
+
githubIssueUrl: { type: String },
|
|
27
|
+
githubIssueNumber: { type: Number },
|
|
24
28
|
}, { timestamps: true, collection: "annotations" });
|
|
25
29
|
collabAnnotationSchema.index({ projectId: 1, pagePath: 1, status: 1 });
|
|
26
30
|
exports.default = (0, mongoose_1.model)("CollabAnnotation", collabAnnotationSchema);
|
package/dist/collab-comment.js
CHANGED
|
@@ -10,7 +10,7 @@ const collabAttachmentSchema = new mongoose_1.Schema({
|
|
|
10
10
|
const collabCommentSchema = new mongoose_1.Schema({
|
|
11
11
|
annotationId: { type: mongoose_1.Schema.Types.ObjectId, ref: "CollabAnnotation", required: true, index: true },
|
|
12
12
|
userId: { type: mongoose_1.Schema.Types.ObjectId, ref: "User" },
|
|
13
|
-
body: { type: String
|
|
13
|
+
body: { type: String },
|
|
14
14
|
screenshot: { type: String },
|
|
15
15
|
attachments: { type: [collabAttachmentSchema], default: undefined },
|
|
16
16
|
guestName: { type: String },
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose" />
|
|
25
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
26
|
+
import { ICollabPushSubscription } from "./types";
|
|
27
|
+
declare const _default: import("mongoose").Model<ICollabPushSubscription, {}, {}, {}, import("mongoose").Document<unknown, {}, ICollabPushSubscription> & ICollabPushSubscription & {
|
|
28
|
+
_id: import("mongoose").Types.ObjectId;
|
|
29
|
+
}, any>;
|
|
30
|
+
export default _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const mongoose_1 = require("mongoose");
|
|
4
|
+
const collabPushSubscriptionSchema = new mongoose_1.Schema({
|
|
5
|
+
userId: { type: mongoose_1.Schema.Types.ObjectId, ref: "User", required: true, index: true },
|
|
6
|
+
endpoint: { type: String, required: true, unique: true },
|
|
7
|
+
keys: {
|
|
8
|
+
p256dh: { type: String, required: true },
|
|
9
|
+
auth: { type: String, required: true },
|
|
10
|
+
},
|
|
11
|
+
domain: { type: String, required: true, index: true },
|
|
12
|
+
}, { timestamps: { createdAt: true, updatedAt: false }, collection: "push_subscriptions" });
|
|
13
|
+
collabPushSubscriptionSchema.index({ userId: 1, domain: 1 });
|
|
14
|
+
exports.default = (0, mongoose_1.model)("CollabPushSubscription", collabPushSubscriptionSchema);
|
package/dist/index.d.ts
CHANGED
|
@@ -41,7 +41,8 @@ export { default as CollabComment } from "./collab-comment";
|
|
|
41
41
|
export { default as CollabIntegration } from "./collab-integration";
|
|
42
42
|
export { default as CollabSettings } from "./collab-settings";
|
|
43
43
|
export { default as CollabShareToken } from "./collab-share-token";
|
|
44
|
-
export {
|
|
44
|
+
export { default as CollabPushSubscription } from "./collab-push-subscription";
|
|
45
|
+
export { IUser, IGit, IProject, IPreview, IProjectConnection, IFollowing, IIntegration, IEnv, IServer, IDomain, IToken, IMember, ITeam, IInstalledIntegration, ILog, ISubscription, ICard, IDns, IRole, IPermission, IMemberPermission, IWallet, IDbImage, IJob, ILicense, IPlanConfiguration, IAutoScalingGroup, IComputeChange, IRegion, IVolume, IFramework, BrimbleFrameworkType, ISettings, ILoadBalancerPort, IDomainRenewal, IWebhookCategory, IWebhookEvent, IWebhookSetting, IIntention, IProvider, IBranch, ICollabAnnotation, ICollabComment, ICollabAttachment, ICollabIntegration, ICollabSettings, ICollabShareToken, ICollabPushSubscription } from "./types";
|
|
45
46
|
export { GIT_TYPE, INTEGRATION_TYPES, INTEGRATION_PROVIDERS, OAUTH_PERMISSIONS, ENVIRONMENT, SERVER_STATUS, ROLES, SUBSCRIPTION_PLAN_TYPE, PROJECT_STATUS, SUBSCRIPTION_STATUS, CARD_TYPES, DNS_TYPE, PERMISSION_TYPE, REQUEST_TYPE, ServiceType, DatabaseEngine, JobStatus, LicenseStatus, REGION_CONTINENT, BUILD_DISABLED_BY, SERVER_PROTOCOL, FrameworkApplicationType, DomainRenewalStatus, NomadDeploymentStatus, BRANCH_TYPE, COLLAB_ANNOTATION_STATUS, COLLAB_INTEGRATION_TYPE, COLLAB_THEME, COLLAB_TOOLBAR_POSITION } from "./enum";
|
|
46
47
|
import mongoose from "mongoose";
|
|
47
48
|
export declare const connectToMongo: (mongoUrl: string, config?: mongoose.ConnectOptions) => Promise<void>;
|
package/dist/index.js
CHANGED
|
@@ -12,8 +12,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
12
12
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.
|
|
16
|
-
exports.healthCheckMongo = exports.closeMongo = exports.db = exports.connectToMongo = exports.COLLAB_TOOLBAR_POSITION = exports.COLLAB_THEME = exports.COLLAB_INTEGRATION_TYPE = exports.COLLAB_ANNOTATION_STATUS = exports.BRANCH_TYPE = exports.NomadDeploymentStatus = exports.DomainRenewalStatus = exports.FrameworkApplicationType = exports.SERVER_PROTOCOL = exports.BUILD_DISABLED_BY = exports.REGION_CONTINENT = exports.LicenseStatus = exports.JobStatus = exports.DatabaseEngine = exports.ServiceType = exports.REQUEST_TYPE = exports.PERMISSION_TYPE = exports.DNS_TYPE = exports.CARD_TYPES = exports.SUBSCRIPTION_STATUS = exports.PROJECT_STATUS = exports.SUBSCRIPTION_PLAN_TYPE = exports.ROLES = void 0;
|
|
15
|
+
exports.ENVIRONMENT = exports.OAUTH_PERMISSIONS = exports.INTEGRATION_PROVIDERS = exports.INTEGRATION_TYPES = exports.GIT_TYPE = exports.CollabPushSubscription = exports.CollabShareToken = exports.CollabSettings = exports.CollabIntegration = exports.CollabComment = exports.CollabAnnotation = exports.Branch = exports.Provider = exports.Intention = exports.WebhookSetting = exports.WebhookEvent = exports.WebhookCategory = exports.DomainRenewal = exports.LoadBalancerPort = exports.Settings = exports.Framework = exports.Volume = exports.Region = exports.ComputeChange = exports.AutoScalingGroup = exports.PlanConfiguration = exports.Liscense = exports.Job = exports.DbImage = exports.Wallet = exports.Server = exports.Card = exports.Subscription = exports.Log = exports.Role = exports.MemberPermission = exports.Permission = exports.Member = exports.Team = exports.Token = exports.Env = exports.Dns = exports.Domain = exports.Integration = exports.Following = exports.ProjectConnection = exports.Preview = exports.DeletedProject = exports.Project = exports.User = void 0;
|
|
16
|
+
exports.healthCheckMongo = exports.closeMongo = exports.db = exports.connectToMongo = exports.COLLAB_TOOLBAR_POSITION = exports.COLLAB_THEME = exports.COLLAB_INTEGRATION_TYPE = exports.COLLAB_ANNOTATION_STATUS = exports.BRANCH_TYPE = exports.NomadDeploymentStatus = exports.DomainRenewalStatus = exports.FrameworkApplicationType = exports.SERVER_PROTOCOL = exports.BUILD_DISABLED_BY = exports.REGION_CONTINENT = exports.LicenseStatus = exports.JobStatus = exports.DatabaseEngine = exports.ServiceType = exports.REQUEST_TYPE = exports.PERMISSION_TYPE = exports.DNS_TYPE = exports.CARD_TYPES = exports.SUBSCRIPTION_STATUS = exports.PROJECT_STATUS = exports.SUBSCRIPTION_PLAN_TYPE = exports.ROLES = exports.SERVER_STATUS = void 0;
|
|
17
17
|
var user_1 = require("./user");
|
|
18
18
|
Object.defineProperty(exports, "User", { enumerable: true, get: function () { return __importDefault(user_1).default; } });
|
|
19
19
|
var project_1 = require("./project");
|
|
@@ -101,6 +101,8 @@ var collab_settings_1 = require("./collab-settings");
|
|
|
101
101
|
Object.defineProperty(exports, "CollabSettings", { enumerable: true, get: function () { return __importDefault(collab_settings_1).default; } });
|
|
102
102
|
var collab_share_token_1 = require("./collab-share-token");
|
|
103
103
|
Object.defineProperty(exports, "CollabShareToken", { enumerable: true, get: function () { return __importDefault(collab_share_token_1).default; } });
|
|
104
|
+
var collab_push_subscription_1 = require("./collab-push-subscription");
|
|
105
|
+
Object.defineProperty(exports, "CollabPushSubscription", { enumerable: true, get: function () { return __importDefault(collab_push_subscription_1).default; } });
|
|
104
106
|
var enum_1 = require("./enum");
|
|
105
107
|
Object.defineProperty(exports, "GIT_TYPE", { enumerable: true, get: function () { return enum_1.GIT_TYPE; } });
|
|
106
108
|
Object.defineProperty(exports, "INTEGRATION_TYPES", { enumerable: true, get: function () { return enum_1.INTEGRATION_TYPES; } });
|
|
@@ -17,6 +17,10 @@ export interface ICollabAnnotation extends Document {
|
|
|
17
17
|
resolvedBy?: IUser;
|
|
18
18
|
guestName?: string;
|
|
19
19
|
guestEmail?: string;
|
|
20
|
+
githubPrCommentId?: number;
|
|
21
|
+
githubPrCommentUrl?: string;
|
|
22
|
+
githubIssueUrl?: string;
|
|
23
|
+
githubIssueNumber?: number;
|
|
20
24
|
createdAt: Date;
|
|
21
25
|
updatedAt: Date;
|
|
22
26
|
}
|
|
@@ -10,7 +10,7 @@ export interface ICollabAttachment {
|
|
|
10
10
|
export interface ICollabComment extends Document {
|
|
11
11
|
annotationId: ICollabAnnotation;
|
|
12
12
|
userId?: IUser;
|
|
13
|
-
body
|
|
13
|
+
body?: string;
|
|
14
14
|
screenshot?: string;
|
|
15
15
|
attachments?: ICollabAttachment[];
|
|
16
16
|
guestName?: string;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Document } from "mongoose";
|
|
2
|
+
import { IUser } from "./user";
|
|
3
|
+
export interface ICollabPushSubscription extends Document {
|
|
4
|
+
userId: IUser;
|
|
5
|
+
endpoint: string;
|
|
6
|
+
keys: {
|
|
7
|
+
p256dh: string;
|
|
8
|
+
auth: string;
|
|
9
|
+
};
|
|
10
|
+
domain: string;
|
|
11
|
+
createdAt: Date;
|
|
12
|
+
}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -43,3 +43,4 @@ export type { ICollabComment, ICollabAttachment } from "./collab-comment";
|
|
|
43
43
|
export type { ICollabIntegration } from "./collab-integration";
|
|
44
44
|
export type { ICollabSettings } from "./collab-settings";
|
|
45
45
|
export type { ICollabShareToken } from "./collab-share-token";
|
|
46
|
+
export type { ICollabPushSubscription } from "./collab-push-subscription";
|
package/index.ts
CHANGED
|
@@ -41,6 +41,7 @@ export { default as CollabComment } from "./collab-comment";
|
|
|
41
41
|
export { default as CollabIntegration } from "./collab-integration";
|
|
42
42
|
export { default as CollabSettings } from "./collab-settings";
|
|
43
43
|
export { default as CollabShareToken } from "./collab-share-token";
|
|
44
|
+
export { default as CollabPushSubscription } from "./collab-push-subscription";
|
|
44
45
|
|
|
45
46
|
export {
|
|
46
47
|
IUser,
|
|
@@ -89,7 +90,8 @@ export {
|
|
|
89
90
|
ICollabAttachment,
|
|
90
91
|
ICollabIntegration,
|
|
91
92
|
ICollabSettings,
|
|
92
|
-
ICollabShareToken
|
|
93
|
+
ICollabShareToken,
|
|
94
|
+
ICollabPushSubscription
|
|
93
95
|
} from "./types";
|
|
94
96
|
export {
|
|
95
97
|
GIT_TYPE,
|
package/package.json
CHANGED
|
@@ -18,6 +18,10 @@ export interface ICollabAnnotation extends Document {
|
|
|
18
18
|
resolvedBy?: IUser;
|
|
19
19
|
guestName?: string;
|
|
20
20
|
guestEmail?: string;
|
|
21
|
+
githubPrCommentId?: number;
|
|
22
|
+
githubPrCommentUrl?: string;
|
|
23
|
+
githubIssueUrl?: string;
|
|
24
|
+
githubIssueNumber?: number;
|
|
21
25
|
createdAt: Date;
|
|
22
26
|
updatedAt: Date;
|
|
23
27
|
}
|
package/types/collab-comment.ts
CHANGED
|
@@ -12,7 +12,7 @@ export interface ICollabAttachment {
|
|
|
12
12
|
export interface ICollabComment extends Document {
|
|
13
13
|
annotationId: ICollabAnnotation;
|
|
14
14
|
userId?: IUser;
|
|
15
|
-
body
|
|
15
|
+
body?: string;
|
|
16
16
|
screenshot?: string;
|
|
17
17
|
attachments?: ICollabAttachment[];
|
|
18
18
|
guestName?: string;
|
package/types/index.ts
CHANGED
|
@@ -43,3 +43,4 @@ export type { ICollabComment, ICollabAttachment } from "./collab-comment";
|
|
|
43
43
|
export type { ICollabIntegration } from "./collab-integration";
|
|
44
44
|
export type { ICollabSettings } from "./collab-settings";
|
|
45
45
|
export type { ICollabShareToken } from "./collab-share-token";
|
|
46
|
+
export type { ICollabPushSubscription } from "./collab-push-subscription";
|