@apollo-annotation/schemas 0.1.17 → 0.1.19

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apollo-annotation/schemas",
3
- "version": "0.1.17",
3
+ "version": "0.1.19",
4
4
  "main": "./dist/index.js",
5
5
  "scripts": {
6
6
  "build": "tsc"
@@ -16,9 +16,9 @@
16
16
  "tslib": "^2.3.1"
17
17
  },
18
18
  "devDependencies": {
19
- "@apollo-annotation/mst": "^0.1.17",
19
+ "@apollo-annotation/mst": "^0.1.19",
20
20
  "@types/node": "^18.14.2",
21
- "typescript": "^5.1.6"
21
+ "typescript": "^5.5.3"
22
22
  },
23
23
  "publishConfig": {
24
24
  "access": "public"
@@ -14,10 +14,6 @@ export class Feature
14
14
  // Don't make this a @Prop since _id is already on a MongoDB document
15
15
  _id: Types.ObjectId
16
16
 
17
- // Here we store feature ID if it's given in attributes, otherwise gffId = _id as string
18
- @Prop()
19
- gffId: string
20
-
21
17
  @Prop({
22
18
  required: true,
23
19
  index: true,
@@ -33,23 +29,14 @@ export class Feature
33
29
  type: string
34
30
 
35
31
  @Prop({ required: true })
36
- start: number
32
+ min: number
37
33
 
38
34
  @Prop({ required: true })
39
- end: number
40
-
41
- @Prop()
42
- discontinuousLocations?: { start: number; end: number; phase?: 0 | 1 | 2 }[]
35
+ max: number
43
36
 
44
37
  @Prop()
45
38
  strand?: 1 | -1
46
39
 
47
- @Prop()
48
- score?: number
49
-
50
- @Prop()
51
- phase?: 0 | 1 | 2
52
-
53
40
  @Prop({ type: Map, of: [String] })
54
41
  attributes?: Record<string, string[]>
55
42
 
@@ -67,6 +54,6 @@ export const FeatureSchema = SchemaFactory.createForClass(Feature)
67
54
 
68
55
  FeatureSchema.add({ children: { type: Map, of: FeatureSchema } })
69
56
 
70
- FeatureSchema.index({ refSeq: 1, start: 1 })
71
- FeatureSchema.index({ refSeq: 1, end: 1 })
57
+ FeatureSchema.index({ refSeq: 1, min: 1 })
58
+ FeatureSchema.index({ refSeq: 1, max: 1 })
72
59
  FeatureSchema.index({ '$**': 'text' })
package/src/index.ts CHANGED
@@ -9,3 +9,4 @@ export * from './file.schema'
9
9
  export * from './refSeq.schema'
10
10
  export * from './refSeqChunk.schema'
11
11
  export * from './user.schema'
12
+ export * from './jbrowseConfig.schema'
@@ -0,0 +1,9 @@
1
+ import { Schema, SchemaFactory } from '@nestjs/mongoose'
2
+ import { Document } from 'mongoose'
3
+
4
+ export type JBrowseConfigDocument = JBrowseConfig & Document
5
+
6
+ @Schema({ strict: false })
7
+ export class JBrowseConfig {}
8
+
9
+ export const JBrowseConfigSchema = SchemaFactory.createForClass(JBrowseConfig)
@@ -24,6 +24,9 @@ export class RefSeq {
24
24
  @Prop()
25
25
  description: string
26
26
 
27
+ @Prop()
28
+ aliases: string[]
29
+
27
30
  @Prop({ required: true })
28
31
  length: number
29
32