-
Notifications
You must be signed in to change notification settings - Fork 202
/
Copy pathconcept.ts
76 lines (72 loc) · 1.32 KB
/
concept.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
import { UnresolvedLink } from './link'
import { LocaleCode } from './locale'
type ISODateString = string
export type ConceptSys = {
id: string
type: 'TaxonomyConcept'
createdAt: ISODateString
updatedAt: ISODateString
version: number
}
export interface Concept<Locales extends LocaleCode> {
sys: ConceptSys
uri?: string
prefLabel: {
[locale in Locales]: string
}
altLabels?: {
[locale in Locales]: string[]
}
hiddenLabels?: {
[locale in Locales]: string[]
}
note?:
| {
[locale in Locales]: string
}
| null
changeNote?:
| {
[locale in Locales]: string
}
| null
definition?:
| {
[locale in Locales]: string
}
| null
editorialNote?:
| {
[locale in Locales]: string
}
| null
example?:
| {
[locale in Locales]: string
}
| null
historyNote?:
| {
[locale in Locales]: string
}
| null
scopeNote?:
| {
[locale in Locales]: string
}
| null
notations?: string[]
broader?: UnresolvedLink<'TaxonomyConcept'>[]
related?: UnresolvedLink<'TaxonomyConcept'>[]
}
export type ConceptCollection<Locale extends LocaleCode> = {
sys: {
type: 'Array'
}
items: Concept<Locale>[]
limit: number
pages?: {
prev?: string
next?: string
}
}