@confed/sanity-types 0.1.2 → 0.1.3-2510301609
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/README.md +97 -41
- package/package.json +1 -1
- package/sanity.types.ts +795 -33
package/README.md
CHANGED
|
@@ -2,31 +2,76 @@
|
|
|
2
2
|
|
|
3
3
|
A TypeScript types package for the Confederation College Sanity CMS backend. This package provides auto-generated TypeScript definitions for all Sanity schema types, ensuring type safety across your frontend applications and API integrations.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
## Quick Start
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
### Installation
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
```bash
|
|
10
|
+
npm install @confed/sanity-types
|
|
11
|
+
```
|
|
10
12
|
|
|
11
|
-
|
|
12
|
-
2. **GROQ queries** - Any TypeScript/JavaScript files in the `src/` directory that contain GROQ queries
|
|
13
|
+
### Basic Usage
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
```typescript
|
|
16
|
+
import type {Program, Event, Person} from '@confed/sanity-types'
|
|
15
17
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
18
|
+
// Use types in your components or API functions
|
|
19
|
+
const program: Program = {
|
|
20
|
+
_id: 'program-123',
|
|
21
|
+
_type: 'program',
|
|
22
|
+
_createdAt: '2024-01-01T00:00:00Z',
|
|
23
|
+
_updatedAt: '2024-01-01T00:00:00Z',
|
|
24
|
+
_rev: 'rev-123',
|
|
25
|
+
name: 'Computer Programming',
|
|
26
|
+
slug: {_type: 'slug', current: 'computer-programming'},
|
|
27
|
+
// ... other required fields
|
|
28
|
+
}
|
|
23
29
|
|
|
24
|
-
|
|
30
|
+
// Type-safe event handling
|
|
31
|
+
const handleEvent = (event: Event) => {
|
|
32
|
+
console.log(event.title) // Full IntelliSense support
|
|
33
|
+
console.log(event.startDate) // Type-safe date access
|
|
34
|
+
}
|
|
35
|
+
```
|
|
25
36
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
37
|
+
### Advanced Usage
|
|
38
|
+
|
|
39
|
+
```typescript
|
|
40
|
+
// Import multiple types
|
|
41
|
+
import type {
|
|
42
|
+
Program,
|
|
43
|
+
School,
|
|
44
|
+
Campus,
|
|
45
|
+
Person,
|
|
46
|
+
SanityImageAsset,
|
|
47
|
+
PtBasic
|
|
48
|
+
} from '@confed/sanity-types'
|
|
49
|
+
|
|
50
|
+
// Use with React components
|
|
51
|
+
interface ProgramCardProps {
|
|
52
|
+
program: Program
|
|
53
|
+
school?: School
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
const ProgramCard: React.FC<ProgramCardProps> = ({ program, school }) => {
|
|
57
|
+
return (
|
|
58
|
+
<div>
|
|
59
|
+
<h2>{program.name}</h2>
|
|
60
|
+
{school && <p>School: {school.name}</p>}
|
|
61
|
+
{program.description && (
|
|
62
|
+
<div>{/* Portable text content */}</div>
|
|
63
|
+
)}
|
|
64
|
+
</div>
|
|
65
|
+
)
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
// Use with API functions
|
|
69
|
+
async function fetchProgram(id: string): Promise<Program | null> {
|
|
70
|
+
const response = await fetch(`/api/programs/${id}`)
|
|
71
|
+
if (!response.ok) return null
|
|
72
|
+
return response.json() as Promise<Program>
|
|
73
|
+
}
|
|
74
|
+
```
|
|
30
75
|
|
|
31
76
|
## Available Types
|
|
32
77
|
|
|
@@ -77,35 +122,36 @@ The generated types provide:
|
|
|
77
122
|
- **`Geopoint`** - Geographic coordinates
|
|
78
123
|
- **`MediaTag`** - Media tagging system
|
|
79
124
|
|
|
80
|
-
##
|
|
125
|
+
## How It Works
|
|
81
126
|
|
|
82
|
-
|
|
83
|
-
npm install @confed/sanity-types
|
|
84
|
-
```
|
|
127
|
+
This package uses [Sanity TypeGen](https://www.sanity.io/docs/sanity-typegen) to automatically generate TypeScript definitions from your Sanity schema. The types are generated from:
|
|
85
128
|
|
|
86
|
-
|
|
129
|
+
1. **Schema definitions** (`schema.json`) - Contains all your content type schemas
|
|
130
|
+
2. **GROQ queries** - Any TypeScript/JavaScript files in the `src/` directory that contain GROQ queries
|
|
87
131
|
|
|
88
|
-
|
|
89
|
-
import type {Program, Event, Person} from '@confed/sanity-types'
|
|
132
|
+
### Complete Workflow:
|
|
90
133
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
134
|
+
1. **Schema Changes** → You modify Sanity schemas
|
|
135
|
+
2. **Local Generation** → Pre-commit hook generates types automatically
|
|
136
|
+
3. **Commit** → Types and schema changes committed together
|
|
137
|
+
4. **CI/CD Trigger** → GitHub Actions workflow runs on push
|
|
138
|
+
5. **Verification** → Types regenerated in CI for verification
|
|
139
|
+
6. **Publishing** → If types changed, version bumped and published to npm
|
|
140
|
+
7. **Sanity Deployment** → Separate workflow deploys Sanity Studio (handled by `.github/workflows/deploy-sanity.yml`)
|
|
141
|
+
8. **No Circular Commits** → CI never commits back to your repository
|
|
142
|
+
|
|
143
|
+
The generated types provide:
|
|
144
|
+
|
|
145
|
+
- Full type safety for all your content types
|
|
146
|
+
- IntelliSense and autocomplete in your IDE
|
|
147
|
+
- Compile-time error checking for content structure
|
|
148
|
+
- Reference type safety for cross-referenced documents
|
|
103
149
|
|
|
104
150
|
## Keeping Types Up to Date
|
|
105
151
|
|
|
106
152
|
The types in this package are automatically generated and should **never be manually edited**. This project is configured with automatic type generation on every commit, so types stay current automatically.
|
|
107
153
|
|
|
108
|
-
**Current Status:**
|
|
154
|
+
**Current Status:** Types are regenerated on every commit via Husky pre-commit hooks, and automatically published to npm via CI/CD when changes are detected.
|
|
109
155
|
|
|
110
156
|
**Workflow:**
|
|
111
157
|
|
|
@@ -156,17 +202,27 @@ git commit -m "your message"
|
|
|
156
202
|
|
|
157
203
|
### 4. CI/CD Integration (Automated Publishing)
|
|
158
204
|
|
|
159
|
-
This project has automated CI/CD that
|
|
205
|
+
This project has automated CI/CD workflows that handle different concerns:
|
|
206
|
+
|
|
207
|
+
**Types Publishing** (`.github/workflows/publish-types.yml`):
|
|
160
208
|
|
|
161
209
|
```yaml
|
|
162
|
-
# .github/workflows/publish-types.yml
|
|
163
210
|
# Automatically runs on schema changes:
|
|
164
211
|
# - Generates types in CI for verification
|
|
165
212
|
# - Bumps version and publishes to npm if types changed
|
|
166
213
|
# - Does NOT commit back to repository (no circular commits)
|
|
167
214
|
```
|
|
168
215
|
|
|
169
|
-
**
|
|
216
|
+
**Sanity Studio Deployment** (`.github/workflows/deploy-sanity.yml`):
|
|
217
|
+
|
|
218
|
+
```yaml
|
|
219
|
+
# Automatically deploys Sanity Studio on schema/config changes:
|
|
220
|
+
# - Builds the Sanity Studio
|
|
221
|
+
# - Deploys to Sanity hosting
|
|
222
|
+
# - Separate from types publishing workflow
|
|
223
|
+
```
|
|
224
|
+
|
|
225
|
+
**Note:** The CI workflows are separated by concern. Type generation and commits are handled locally via pre-commit hooks.
|
|
170
226
|
|
|
171
227
|
## Configuration
|
|
172
228
|
|
package/package.json
CHANGED
package/sanity.types.ts
CHANGED
|
@@ -13,6 +13,575 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
// Source: schema.json
|
|
16
|
+
export type MediaTextSection = {
|
|
17
|
+
_type: 'mediaTextSection'
|
|
18
|
+
text: Array<
|
|
19
|
+
| {
|
|
20
|
+
children?: Array<{
|
|
21
|
+
marks?: Array<string>
|
|
22
|
+
text?: string
|
|
23
|
+
_type: 'span'
|
|
24
|
+
_key: string
|
|
25
|
+
}>
|
|
26
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
27
|
+
listItem?: 'bullet' | 'number'
|
|
28
|
+
markDefs?: Array<{
|
|
29
|
+
href?: string
|
|
30
|
+
openInNewTab?: boolean
|
|
31
|
+
_type: 'link'
|
|
32
|
+
_key: string
|
|
33
|
+
}>
|
|
34
|
+
level?: number
|
|
35
|
+
_type: 'block'
|
|
36
|
+
_key: string
|
|
37
|
+
}
|
|
38
|
+
| {
|
|
39
|
+
asset?: {
|
|
40
|
+
_ref: string
|
|
41
|
+
_type: 'reference'
|
|
42
|
+
_weak?: boolean
|
|
43
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
44
|
+
}
|
|
45
|
+
media?: unknown
|
|
46
|
+
hotspot?: SanityImageHotspot
|
|
47
|
+
crop?: SanityImageCrop
|
|
48
|
+
altText: string
|
|
49
|
+
caption?: string
|
|
50
|
+
_type: 'figure'
|
|
51
|
+
_key: string
|
|
52
|
+
}
|
|
53
|
+
| ({
|
|
54
|
+
_key: string
|
|
55
|
+
} & PtButton)
|
|
56
|
+
| {
|
|
57
|
+
url: string
|
|
58
|
+
title?: string
|
|
59
|
+
_type: 'ptYoutubeVideo'
|
|
60
|
+
_key: string
|
|
61
|
+
}
|
|
62
|
+
| {
|
|
63
|
+
body: Array<{
|
|
64
|
+
children?: Array<{
|
|
65
|
+
marks?: Array<string>
|
|
66
|
+
text?: string
|
|
67
|
+
_type: 'span'
|
|
68
|
+
_key: string
|
|
69
|
+
}>
|
|
70
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
71
|
+
listItem?: 'bullet' | 'number'
|
|
72
|
+
markDefs?: Array<{
|
|
73
|
+
href?: string
|
|
74
|
+
openInNewTab?: boolean
|
|
75
|
+
_type: 'link'
|
|
76
|
+
_key: string
|
|
77
|
+
}>
|
|
78
|
+
level?: number
|
|
79
|
+
_type: 'block'
|
|
80
|
+
_key: string
|
|
81
|
+
}>
|
|
82
|
+
kind: 'info' | 'tip' | 'important' | 'warning' | 'caution'
|
|
83
|
+
_type: 'note'
|
|
84
|
+
_key: string
|
|
85
|
+
}
|
|
86
|
+
| ({
|
|
87
|
+
_key: string
|
|
88
|
+
} & Table)
|
|
89
|
+
| {
|
|
90
|
+
title?: string
|
|
91
|
+
embedCode: Code
|
|
92
|
+
height?: number
|
|
93
|
+
responsive?: boolean
|
|
94
|
+
_type: 'embed'
|
|
95
|
+
_key: string
|
|
96
|
+
}
|
|
97
|
+
>
|
|
98
|
+
buttons?: Array<
|
|
99
|
+
{
|
|
100
|
+
_key: string
|
|
101
|
+
} & PtButton
|
|
102
|
+
>
|
|
103
|
+
image: {
|
|
104
|
+
asset?: {
|
|
105
|
+
_ref: string
|
|
106
|
+
_type: 'reference'
|
|
107
|
+
_weak?: boolean
|
|
108
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
109
|
+
}
|
|
110
|
+
media?: unknown
|
|
111
|
+
hotspot?: SanityImageHotspot
|
|
112
|
+
crop?: SanityImageCrop
|
|
113
|
+
altText: string
|
|
114
|
+
caption?: string
|
|
115
|
+
_type: 'accessibleImage'
|
|
116
|
+
}
|
|
117
|
+
options?: {
|
|
118
|
+
backgroundColor?: 'light' | 'dark' | 'white' | 'black'
|
|
119
|
+
imagePosition?: 'left' | 'right'
|
|
120
|
+
spacing?: 'default' | 'minimum' | 'none'
|
|
121
|
+
reverseOnMobile?: boolean
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
export type RichTextSection = {
|
|
126
|
+
_type: 'richTextSection'
|
|
127
|
+
content?: Array<
|
|
128
|
+
| {
|
|
129
|
+
children?: Array<{
|
|
130
|
+
marks?: Array<string>
|
|
131
|
+
text?: string
|
|
132
|
+
_type: 'span'
|
|
133
|
+
_key: string
|
|
134
|
+
}>
|
|
135
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
136
|
+
listItem?: 'bullet' | 'number'
|
|
137
|
+
markDefs?: Array<{
|
|
138
|
+
href?: string
|
|
139
|
+
openInNewTab?: boolean
|
|
140
|
+
_type: 'link'
|
|
141
|
+
_key: string
|
|
142
|
+
}>
|
|
143
|
+
level?: number
|
|
144
|
+
_type: 'block'
|
|
145
|
+
_key: string
|
|
146
|
+
}
|
|
147
|
+
| {
|
|
148
|
+
asset?: {
|
|
149
|
+
_ref: string
|
|
150
|
+
_type: 'reference'
|
|
151
|
+
_weak?: boolean
|
|
152
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
153
|
+
}
|
|
154
|
+
media?: unknown
|
|
155
|
+
hotspot?: SanityImageHotspot
|
|
156
|
+
crop?: SanityImageCrop
|
|
157
|
+
altText: string
|
|
158
|
+
caption?: string
|
|
159
|
+
_type: 'figure'
|
|
160
|
+
_key: string
|
|
161
|
+
}
|
|
162
|
+
| ({
|
|
163
|
+
_key: string
|
|
164
|
+
} & PtButton)
|
|
165
|
+
| {
|
|
166
|
+
url: string
|
|
167
|
+
title?: string
|
|
168
|
+
_type: 'ptYoutubeVideo'
|
|
169
|
+
_key: string
|
|
170
|
+
}
|
|
171
|
+
| {
|
|
172
|
+
body: Array<{
|
|
173
|
+
children?: Array<{
|
|
174
|
+
marks?: Array<string>
|
|
175
|
+
text?: string
|
|
176
|
+
_type: 'span'
|
|
177
|
+
_key: string
|
|
178
|
+
}>
|
|
179
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
180
|
+
listItem?: 'bullet' | 'number'
|
|
181
|
+
markDefs?: Array<{
|
|
182
|
+
href?: string
|
|
183
|
+
openInNewTab?: boolean
|
|
184
|
+
_type: 'link'
|
|
185
|
+
_key: string
|
|
186
|
+
}>
|
|
187
|
+
level?: number
|
|
188
|
+
_type: 'block'
|
|
189
|
+
_key: string
|
|
190
|
+
}>
|
|
191
|
+
kind: 'info' | 'tip' | 'important' | 'warning' | 'caution'
|
|
192
|
+
_type: 'note'
|
|
193
|
+
_key: string
|
|
194
|
+
}
|
|
195
|
+
| ({
|
|
196
|
+
_key: string
|
|
197
|
+
} & Table)
|
|
198
|
+
| {
|
|
199
|
+
title?: string
|
|
200
|
+
embedCode: Code
|
|
201
|
+
height?: number
|
|
202
|
+
responsive?: boolean
|
|
203
|
+
_type: 'embed'
|
|
204
|
+
_key: string
|
|
205
|
+
}
|
|
206
|
+
>
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
export type GallerySection = {
|
|
210
|
+
_type: 'gallerySection'
|
|
211
|
+
title?: string
|
|
212
|
+
introduction?: Array<
|
|
213
|
+
| {
|
|
214
|
+
children?: Array<{
|
|
215
|
+
marks?: Array<string>
|
|
216
|
+
text?: string
|
|
217
|
+
_type: 'span'
|
|
218
|
+
_key: string
|
|
219
|
+
}>
|
|
220
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
221
|
+
listItem?: 'bullet' | 'number'
|
|
222
|
+
markDefs?: Array<{
|
|
223
|
+
href?: string
|
|
224
|
+
openInNewTab?: boolean
|
|
225
|
+
_type: 'link'
|
|
226
|
+
_key: string
|
|
227
|
+
}>
|
|
228
|
+
level?: number
|
|
229
|
+
_type: 'block'
|
|
230
|
+
_key: string
|
|
231
|
+
}
|
|
232
|
+
| {
|
|
233
|
+
asset?: {
|
|
234
|
+
_ref: string
|
|
235
|
+
_type: 'reference'
|
|
236
|
+
_weak?: boolean
|
|
237
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
238
|
+
}
|
|
239
|
+
media?: unknown
|
|
240
|
+
hotspot?: SanityImageHotspot
|
|
241
|
+
crop?: SanityImageCrop
|
|
242
|
+
altText: string
|
|
243
|
+
caption?: string
|
|
244
|
+
_type: 'figure'
|
|
245
|
+
_key: string
|
|
246
|
+
}
|
|
247
|
+
| ({
|
|
248
|
+
_key: string
|
|
249
|
+
} & PtButton)
|
|
250
|
+
| {
|
|
251
|
+
url: string
|
|
252
|
+
title?: string
|
|
253
|
+
_type: 'ptYoutubeVideo'
|
|
254
|
+
_key: string
|
|
255
|
+
}
|
|
256
|
+
| {
|
|
257
|
+
body: Array<{
|
|
258
|
+
children?: Array<{
|
|
259
|
+
marks?: Array<string>
|
|
260
|
+
text?: string
|
|
261
|
+
_type: 'span'
|
|
262
|
+
_key: string
|
|
263
|
+
}>
|
|
264
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
265
|
+
listItem?: 'bullet' | 'number'
|
|
266
|
+
markDefs?: Array<{
|
|
267
|
+
href?: string
|
|
268
|
+
openInNewTab?: boolean
|
|
269
|
+
_type: 'link'
|
|
270
|
+
_key: string
|
|
271
|
+
}>
|
|
272
|
+
level?: number
|
|
273
|
+
_type: 'block'
|
|
274
|
+
_key: string
|
|
275
|
+
}>
|
|
276
|
+
kind: 'info' | 'tip' | 'important' | 'warning' | 'caution'
|
|
277
|
+
_type: 'note'
|
|
278
|
+
_key: string
|
|
279
|
+
}
|
|
280
|
+
| ({
|
|
281
|
+
_key: string
|
|
282
|
+
} & Table)
|
|
283
|
+
| {
|
|
284
|
+
title?: string
|
|
285
|
+
embedCode: Code
|
|
286
|
+
height?: number
|
|
287
|
+
responsive?: boolean
|
|
288
|
+
_type: 'embed'
|
|
289
|
+
_key: string
|
|
290
|
+
}
|
|
291
|
+
>
|
|
292
|
+
images?: Array<{
|
|
293
|
+
asset?: {
|
|
294
|
+
_ref: string
|
|
295
|
+
_type: 'reference'
|
|
296
|
+
_weak?: boolean
|
|
297
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
298
|
+
}
|
|
299
|
+
media?: unknown
|
|
300
|
+
hotspot?: SanityImageHotspot
|
|
301
|
+
crop?: SanityImageCrop
|
|
302
|
+
altText: string
|
|
303
|
+
caption?: string
|
|
304
|
+
_type: 'accessibleImage'
|
|
305
|
+
_key: string
|
|
306
|
+
}>
|
|
307
|
+
layout?: 'grid' | 'carousel'
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
export type StaffListSection = {
|
|
311
|
+
_type: 'staffListSection'
|
|
312
|
+
title?: string
|
|
313
|
+
intro?: Array<
|
|
314
|
+
| {
|
|
315
|
+
children?: Array<{
|
|
316
|
+
marks?: Array<string>
|
|
317
|
+
text?: string
|
|
318
|
+
_type: 'span'
|
|
319
|
+
_key: string
|
|
320
|
+
}>
|
|
321
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
322
|
+
listItem?: 'bullet' | 'number'
|
|
323
|
+
markDefs?: Array<{
|
|
324
|
+
href?: string
|
|
325
|
+
openInNewTab?: boolean
|
|
326
|
+
_type: 'link'
|
|
327
|
+
_key: string
|
|
328
|
+
}>
|
|
329
|
+
level?: number
|
|
330
|
+
_type: 'block'
|
|
331
|
+
_key: string
|
|
332
|
+
}
|
|
333
|
+
| {
|
|
334
|
+
asset?: {
|
|
335
|
+
_ref: string
|
|
336
|
+
_type: 'reference'
|
|
337
|
+
_weak?: boolean
|
|
338
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
339
|
+
}
|
|
340
|
+
media?: unknown
|
|
341
|
+
hotspot?: SanityImageHotspot
|
|
342
|
+
crop?: SanityImageCrop
|
|
343
|
+
altText: string
|
|
344
|
+
caption?: string
|
|
345
|
+
_type: 'figure'
|
|
346
|
+
_key: string
|
|
347
|
+
}
|
|
348
|
+
| ({
|
|
349
|
+
_key: string
|
|
350
|
+
} & PtButton)
|
|
351
|
+
| {
|
|
352
|
+
url: string
|
|
353
|
+
title?: string
|
|
354
|
+
_type: 'ptYoutubeVideo'
|
|
355
|
+
_key: string
|
|
356
|
+
}
|
|
357
|
+
| {
|
|
358
|
+
body: Array<{
|
|
359
|
+
children?: Array<{
|
|
360
|
+
marks?: Array<string>
|
|
361
|
+
text?: string
|
|
362
|
+
_type: 'span'
|
|
363
|
+
_key: string
|
|
364
|
+
}>
|
|
365
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
366
|
+
listItem?: 'bullet' | 'number'
|
|
367
|
+
markDefs?: Array<{
|
|
368
|
+
href?: string
|
|
369
|
+
openInNewTab?: boolean
|
|
370
|
+
_type: 'link'
|
|
371
|
+
_key: string
|
|
372
|
+
}>
|
|
373
|
+
level?: number
|
|
374
|
+
_type: 'block'
|
|
375
|
+
_key: string
|
|
376
|
+
}>
|
|
377
|
+
kind: 'info' | 'tip' | 'important' | 'warning' | 'caution'
|
|
378
|
+
_type: 'note'
|
|
379
|
+
_key: string
|
|
380
|
+
}
|
|
381
|
+
| ({
|
|
382
|
+
_key: string
|
|
383
|
+
} & Table)
|
|
384
|
+
| {
|
|
385
|
+
title?: string
|
|
386
|
+
embedCode: Code
|
|
387
|
+
height?: number
|
|
388
|
+
responsive?: boolean
|
|
389
|
+
_type: 'embed'
|
|
390
|
+
_key: string
|
|
391
|
+
}
|
|
392
|
+
>
|
|
393
|
+
staffMembers?: Array<{
|
|
394
|
+
_ref: string
|
|
395
|
+
_type: 'reference'
|
|
396
|
+
_weak?: boolean
|
|
397
|
+
_key: string
|
|
398
|
+
[internalGroqTypeReferenceTo]?: 'person'
|
|
399
|
+
}>
|
|
400
|
+
layout?: 'grid' | 'list' | 'cards'
|
|
401
|
+
displayOptions?: {
|
|
402
|
+
showPhotos?: boolean
|
|
403
|
+
showContactInfo?: boolean
|
|
404
|
+
showDescription?: boolean
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
export type FaqSection = {
|
|
409
|
+
_type: 'faqSection'
|
|
410
|
+
title?: string
|
|
411
|
+
intro?: Array<
|
|
412
|
+
| {
|
|
413
|
+
children?: Array<{
|
|
414
|
+
marks?: Array<string>
|
|
415
|
+
text?: string
|
|
416
|
+
_type: 'span'
|
|
417
|
+
_key: string
|
|
418
|
+
}>
|
|
419
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
420
|
+
listItem?: 'bullet' | 'number'
|
|
421
|
+
markDefs?: Array<{
|
|
422
|
+
href?: string
|
|
423
|
+
openInNewTab?: boolean
|
|
424
|
+
_type: 'link'
|
|
425
|
+
_key: string
|
|
426
|
+
}>
|
|
427
|
+
level?: number
|
|
428
|
+
_type: 'block'
|
|
429
|
+
_key: string
|
|
430
|
+
}
|
|
431
|
+
| {
|
|
432
|
+
asset?: {
|
|
433
|
+
_ref: string
|
|
434
|
+
_type: 'reference'
|
|
435
|
+
_weak?: boolean
|
|
436
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
437
|
+
}
|
|
438
|
+
media?: unknown
|
|
439
|
+
hotspot?: SanityImageHotspot
|
|
440
|
+
crop?: SanityImageCrop
|
|
441
|
+
altText: string
|
|
442
|
+
caption?: string
|
|
443
|
+
_type: 'figure'
|
|
444
|
+
_key: string
|
|
445
|
+
}
|
|
446
|
+
| ({
|
|
447
|
+
_key: string
|
|
448
|
+
} & PtButton)
|
|
449
|
+
| {
|
|
450
|
+
url: string
|
|
451
|
+
title?: string
|
|
452
|
+
_type: 'ptYoutubeVideo'
|
|
453
|
+
_key: string
|
|
454
|
+
}
|
|
455
|
+
| {
|
|
456
|
+
body: Array<{
|
|
457
|
+
children?: Array<{
|
|
458
|
+
marks?: Array<string>
|
|
459
|
+
text?: string
|
|
460
|
+
_type: 'span'
|
|
461
|
+
_key: string
|
|
462
|
+
}>
|
|
463
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
464
|
+
listItem?: 'bullet' | 'number'
|
|
465
|
+
markDefs?: Array<{
|
|
466
|
+
href?: string
|
|
467
|
+
openInNewTab?: boolean
|
|
468
|
+
_type: 'link'
|
|
469
|
+
_key: string
|
|
470
|
+
}>
|
|
471
|
+
level?: number
|
|
472
|
+
_type: 'block'
|
|
473
|
+
_key: string
|
|
474
|
+
}>
|
|
475
|
+
kind: 'info' | 'tip' | 'important' | 'warning' | 'caution'
|
|
476
|
+
_type: 'note'
|
|
477
|
+
_key: string
|
|
478
|
+
}
|
|
479
|
+
| ({
|
|
480
|
+
_key: string
|
|
481
|
+
} & Table)
|
|
482
|
+
| {
|
|
483
|
+
title?: string
|
|
484
|
+
embedCode: Code
|
|
485
|
+
height?: number
|
|
486
|
+
responsive?: boolean
|
|
487
|
+
_type: 'embed'
|
|
488
|
+
_key: string
|
|
489
|
+
}
|
|
490
|
+
>
|
|
491
|
+
layout?: 'accordion' | 'list' | 'twoCols'
|
|
492
|
+
items?: Array<
|
|
493
|
+
{
|
|
494
|
+
_key: string
|
|
495
|
+
} & FaqItem
|
|
496
|
+
>
|
|
497
|
+
}
|
|
498
|
+
|
|
499
|
+
export type FaqItem = {
|
|
500
|
+
_type: 'faqItem'
|
|
501
|
+
question: string
|
|
502
|
+
answer: Array<
|
|
503
|
+
| {
|
|
504
|
+
children?: Array<{
|
|
505
|
+
marks?: Array<string>
|
|
506
|
+
text?: string
|
|
507
|
+
_type: 'span'
|
|
508
|
+
_key: string
|
|
509
|
+
}>
|
|
510
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
511
|
+
listItem?: 'bullet' | 'number'
|
|
512
|
+
markDefs?: Array<{
|
|
513
|
+
href?: string
|
|
514
|
+
openInNewTab?: boolean
|
|
515
|
+
_type: 'link'
|
|
516
|
+
_key: string
|
|
517
|
+
}>
|
|
518
|
+
level?: number
|
|
519
|
+
_type: 'block'
|
|
520
|
+
_key: string
|
|
521
|
+
}
|
|
522
|
+
| {
|
|
523
|
+
asset?: {
|
|
524
|
+
_ref: string
|
|
525
|
+
_type: 'reference'
|
|
526
|
+
_weak?: boolean
|
|
527
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
528
|
+
}
|
|
529
|
+
media?: unknown
|
|
530
|
+
hotspot?: SanityImageHotspot
|
|
531
|
+
crop?: SanityImageCrop
|
|
532
|
+
altText: string
|
|
533
|
+
caption?: string
|
|
534
|
+
_type: 'figure'
|
|
535
|
+
_key: string
|
|
536
|
+
}
|
|
537
|
+
| ({
|
|
538
|
+
_key: string
|
|
539
|
+
} & PtButton)
|
|
540
|
+
| {
|
|
541
|
+
url: string
|
|
542
|
+
title?: string
|
|
543
|
+
_type: 'ptYoutubeVideo'
|
|
544
|
+
_key: string
|
|
545
|
+
}
|
|
546
|
+
| {
|
|
547
|
+
body: Array<{
|
|
548
|
+
children?: Array<{
|
|
549
|
+
marks?: Array<string>
|
|
550
|
+
text?: string
|
|
551
|
+
_type: 'span'
|
|
552
|
+
_key: string
|
|
553
|
+
}>
|
|
554
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
555
|
+
listItem?: 'bullet' | 'number'
|
|
556
|
+
markDefs?: Array<{
|
|
557
|
+
href?: string
|
|
558
|
+
openInNewTab?: boolean
|
|
559
|
+
_type: 'link'
|
|
560
|
+
_key: string
|
|
561
|
+
}>
|
|
562
|
+
level?: number
|
|
563
|
+
_type: 'block'
|
|
564
|
+
_key: string
|
|
565
|
+
}>
|
|
566
|
+
kind: 'info' | 'tip' | 'important' | 'warning' | 'caution'
|
|
567
|
+
_type: 'note'
|
|
568
|
+
_key: string
|
|
569
|
+
}
|
|
570
|
+
| ({
|
|
571
|
+
_key: string
|
|
572
|
+
} & Table)
|
|
573
|
+
| {
|
|
574
|
+
title?: string
|
|
575
|
+
embedCode: Code
|
|
576
|
+
height?: number
|
|
577
|
+
responsive?: boolean
|
|
578
|
+
_type: 'embed'
|
|
579
|
+
_key: string
|
|
580
|
+
}
|
|
581
|
+
>
|
|
582
|
+
anchorId?: Slug
|
|
583
|
+
}
|
|
584
|
+
|
|
16
585
|
export type MenuItem = {
|
|
17
586
|
_type: 'menuItem'
|
|
18
587
|
link: Link
|
|
@@ -100,21 +669,59 @@ export type PtBasic = Array<
|
|
|
100
669
|
_type: 'figure'
|
|
101
670
|
_key: string
|
|
102
671
|
}
|
|
103
|
-
| {
|
|
104
|
-
variant?: 'primary' | 'outlined'
|
|
105
|
-
text: string
|
|
106
|
-
link: string
|
|
107
|
-
_type: 'ptButton'
|
|
672
|
+
| ({
|
|
108
673
|
_key: string
|
|
109
|
-
}
|
|
674
|
+
} & PtButton)
|
|
110
675
|
| {
|
|
111
676
|
url: string
|
|
112
677
|
title?: string
|
|
113
678
|
_type: 'ptYoutubeVideo'
|
|
114
679
|
_key: string
|
|
115
680
|
}
|
|
681
|
+
| {
|
|
682
|
+
body: Array<{
|
|
683
|
+
children?: Array<{
|
|
684
|
+
marks?: Array<string>
|
|
685
|
+
text?: string
|
|
686
|
+
_type: 'span'
|
|
687
|
+
_key: string
|
|
688
|
+
}>
|
|
689
|
+
style?: 'normal' | 'lead' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'blockquote'
|
|
690
|
+
listItem?: 'bullet' | 'number'
|
|
691
|
+
markDefs?: Array<{
|
|
692
|
+
href?: string
|
|
693
|
+
openInNewTab?: boolean
|
|
694
|
+
_type: 'link'
|
|
695
|
+
_key: string
|
|
696
|
+
}>
|
|
697
|
+
level?: number
|
|
698
|
+
_type: 'block'
|
|
699
|
+
_key: string
|
|
700
|
+
}>
|
|
701
|
+
kind: 'info' | 'tip' | 'important' | 'warning' | 'caution'
|
|
702
|
+
_type: 'note'
|
|
703
|
+
_key: string
|
|
704
|
+
}
|
|
705
|
+
| ({
|
|
706
|
+
_key: string
|
|
707
|
+
} & Table)
|
|
708
|
+
| {
|
|
709
|
+
title?: string
|
|
710
|
+
embedCode: Code
|
|
711
|
+
height?: number
|
|
712
|
+
responsive?: boolean
|
|
713
|
+
_type: 'embed'
|
|
714
|
+
_key: string
|
|
715
|
+
}
|
|
116
716
|
>
|
|
117
717
|
|
|
718
|
+
export type PtButton = {
|
|
719
|
+
_type: 'ptButton'
|
|
720
|
+
variant?: 'primary' | 'outlined'
|
|
721
|
+
text: string
|
|
722
|
+
link: string
|
|
723
|
+
}
|
|
724
|
+
|
|
118
725
|
export type Figure = {
|
|
119
726
|
_type: 'figure'
|
|
120
727
|
asset?: {
|
|
@@ -290,7 +897,7 @@ export type NewsArticle = {
|
|
|
290
897
|
_type: 'accessibleImage'
|
|
291
898
|
}
|
|
292
899
|
body?: PtBasic
|
|
293
|
-
categories: Array<'media' | 'students' | 'employee'>
|
|
900
|
+
categories: Array<'media' | 'students' | 'employee' | 'alumni'>
|
|
294
901
|
dateCreated?: string
|
|
295
902
|
seo?: Seo
|
|
296
903
|
}
|
|
@@ -303,7 +910,45 @@ export type Webpage = {
|
|
|
303
910
|
_rev: string
|
|
304
911
|
title: string
|
|
305
912
|
slug: Slug
|
|
913
|
+
heroDescription?: string
|
|
914
|
+
heroButtons?: Array<
|
|
915
|
+
{
|
|
916
|
+
_key: string
|
|
917
|
+
} & PtButton
|
|
918
|
+
>
|
|
919
|
+
mainImage?: {
|
|
920
|
+
asset?: {
|
|
921
|
+
_ref: string
|
|
922
|
+
_type: 'reference'
|
|
923
|
+
_weak?: boolean
|
|
924
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
925
|
+
}
|
|
926
|
+
media?: unknown
|
|
927
|
+
hotspot?: SanityImageHotspot
|
|
928
|
+
crop?: SanityImageCrop
|
|
929
|
+
altText: string
|
|
930
|
+
caption?: string
|
|
931
|
+
_type: 'accessibleImage'
|
|
932
|
+
}
|
|
933
|
+
introduction?: string
|
|
306
934
|
body?: PtBasic
|
|
935
|
+
pageBuilder?: Array<
|
|
936
|
+
| ({
|
|
937
|
+
_key: string
|
|
938
|
+
} & MediaTextSection)
|
|
939
|
+
| ({
|
|
940
|
+
_key: string
|
|
941
|
+
} & FaqSection)
|
|
942
|
+
| ({
|
|
943
|
+
_key: string
|
|
944
|
+
} & StaffListSection)
|
|
945
|
+
| ({
|
|
946
|
+
_key: string
|
|
947
|
+
} & GallerySection)
|
|
948
|
+
| ({
|
|
949
|
+
_key: string
|
|
950
|
+
} & RichTextSection)
|
|
951
|
+
>
|
|
307
952
|
parentPage?:
|
|
308
953
|
| {
|
|
309
954
|
_ref: string
|
|
@@ -330,8 +975,36 @@ export type Webpage = {
|
|
|
330
975
|
[internalGroqTypeReferenceTo]?: 'area'
|
|
331
976
|
}
|
|
332
977
|
pageType: 'webpage' | 'department'
|
|
978
|
+
departmentContactDetails?: PtBasic
|
|
333
979
|
isPublished?: boolean
|
|
334
|
-
|
|
980
|
+
relatedMenu?: {
|
|
981
|
+
_ref: string
|
|
982
|
+
_type: 'reference'
|
|
983
|
+
_weak?: boolean
|
|
984
|
+
[internalGroqTypeReferenceTo]?: 'menu'
|
|
985
|
+
}
|
|
986
|
+
seo?: Seo
|
|
987
|
+
}
|
|
988
|
+
|
|
989
|
+
export type Facility = {
|
|
990
|
+
_id: string
|
|
991
|
+
_type: 'facility'
|
|
992
|
+
_createdAt: string
|
|
993
|
+
_updatedAt: string
|
|
994
|
+
_rev: string
|
|
995
|
+
title: string
|
|
996
|
+
slug: Slug
|
|
997
|
+
campus: {
|
|
998
|
+
_ref: string
|
|
999
|
+
_type: 'reference'
|
|
1000
|
+
_weak?: boolean
|
|
1001
|
+
[internalGroqTypeReferenceTo]?: 'campus'
|
|
1002
|
+
}
|
|
1003
|
+
description?: PtBasic
|
|
1004
|
+
isActive?: boolean
|
|
1005
|
+
address?: CanadianAddress
|
|
1006
|
+
tourLink?: string
|
|
1007
|
+
image?: {
|
|
335
1008
|
asset?: {
|
|
336
1009
|
_ref: string
|
|
337
1010
|
_type: 'reference'
|
|
@@ -345,9 +1018,33 @@ export type Webpage = {
|
|
|
345
1018
|
caption?: string
|
|
346
1019
|
_type: 'accessibleImage'
|
|
347
1020
|
}
|
|
1021
|
+
gallery?: Array<{
|
|
1022
|
+
asset?: {
|
|
1023
|
+
_ref: string
|
|
1024
|
+
_type: 'reference'
|
|
1025
|
+
_weak?: boolean
|
|
1026
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
1027
|
+
}
|
|
1028
|
+
media?: unknown
|
|
1029
|
+
hotspot?: SanityImageHotspot
|
|
1030
|
+
crop?: SanityImageCrop
|
|
1031
|
+
altText: string
|
|
1032
|
+
caption?: string
|
|
1033
|
+
_type: 'accessibleImage'
|
|
1034
|
+
_key: string
|
|
1035
|
+
}>
|
|
348
1036
|
seo?: Seo
|
|
349
1037
|
}
|
|
350
1038
|
|
|
1039
|
+
export type CanadianAddress = {
|
|
1040
|
+
_type: 'canadianAddress'
|
|
1041
|
+
streetAddress: string
|
|
1042
|
+
city: string
|
|
1043
|
+
province: 'AB' | 'BC' | 'MB' | 'NB' | 'NL' | 'NT' | 'NS' | 'NU' | 'ON' | 'PE' | 'QC' | 'SK' | 'YT'
|
|
1044
|
+
postalCode: string
|
|
1045
|
+
country?: string
|
|
1046
|
+
}
|
|
1047
|
+
|
|
351
1048
|
export type ProgramFile = {
|
|
352
1049
|
_id: string
|
|
353
1050
|
_type: 'programFile'
|
|
@@ -355,7 +1052,6 @@ export type ProgramFile = {
|
|
|
355
1052
|
_updatedAt: string
|
|
356
1053
|
_rev: string
|
|
357
1054
|
title: string
|
|
358
|
-
description?: string
|
|
359
1055
|
file: {
|
|
360
1056
|
asset?: {
|
|
361
1057
|
_ref: string
|
|
@@ -373,6 +1069,7 @@ export type ProgramFile = {
|
|
|
373
1069
|
| 'courseOutline'
|
|
374
1070
|
| 'studentGuide'
|
|
375
1071
|
| 'other'
|
|
1072
|
+
description?: string
|
|
376
1073
|
isActive?: boolean
|
|
377
1074
|
}
|
|
378
1075
|
|
|
@@ -421,10 +1118,10 @@ export type Campus = {
|
|
|
421
1118
|
_updatedAt: string
|
|
422
1119
|
_rev: string
|
|
423
1120
|
title: string
|
|
424
|
-
slug: Slug
|
|
425
1121
|
code: string
|
|
1122
|
+
city?: string
|
|
1123
|
+
slug: Slug
|
|
426
1124
|
isEnabled?: boolean
|
|
427
|
-
description?: string
|
|
428
1125
|
image?: {
|
|
429
1126
|
asset?: {
|
|
430
1127
|
_ref: string
|
|
@@ -439,6 +1136,16 @@ export type Campus = {
|
|
|
439
1136
|
caption?: string
|
|
440
1137
|
_type: 'accessibleImage'
|
|
441
1138
|
}
|
|
1139
|
+
description?: PtBasic
|
|
1140
|
+
virtualTourUrl?: string
|
|
1141
|
+
staff?: Array<{
|
|
1142
|
+
_ref: string
|
|
1143
|
+
_type: 'reference'
|
|
1144
|
+
_weak?: boolean
|
|
1145
|
+
_key: string
|
|
1146
|
+
[internalGroqTypeReferenceTo]?: 'person'
|
|
1147
|
+
}>
|
|
1148
|
+
seo?: Seo
|
|
442
1149
|
}
|
|
443
1150
|
|
|
444
1151
|
export type Area = {
|
|
@@ -480,7 +1187,7 @@ export type ProgramIntake = {
|
|
|
480
1187
|
[internalGroqTypeReferenceTo]?: 'program'
|
|
481
1188
|
}
|
|
482
1189
|
programCode: string
|
|
483
|
-
season: 'Fall' | 'Winter' | 'Spring' | 'Summer' | 'Any Time'
|
|
1190
|
+
season: 'Fall' | 'Winter' | 'Spring' | 'Summer' | 'Fall, Winter, Spring' | 'Any Time'
|
|
484
1191
|
duration: {
|
|
485
1192
|
_ref: string
|
|
486
1193
|
_type: 'reference'
|
|
@@ -575,6 +1282,21 @@ export type Program = {
|
|
|
575
1282
|
caption?: string
|
|
576
1283
|
_type: 'accessibleImage'
|
|
577
1284
|
}
|
|
1285
|
+
gallery?: Array<{
|
|
1286
|
+
asset?: {
|
|
1287
|
+
_ref: string
|
|
1288
|
+
_type: 'reference'
|
|
1289
|
+
_weak?: boolean
|
|
1290
|
+
[internalGroqTypeReferenceTo]?: 'sanity.imageAsset'
|
|
1291
|
+
}
|
|
1292
|
+
media?: unknown
|
|
1293
|
+
hotspot?: SanityImageHotspot
|
|
1294
|
+
crop?: SanityImageCrop
|
|
1295
|
+
altText: string
|
|
1296
|
+
caption?: string
|
|
1297
|
+
_type: 'accessibleImage'
|
|
1298
|
+
_key: string
|
|
1299
|
+
}>
|
|
578
1300
|
school?: {
|
|
579
1301
|
_ref: string
|
|
580
1302
|
_type: 'reference'
|
|
@@ -709,12 +1431,14 @@ export type Credential = {
|
|
|
709
1431
|
category:
|
|
710
1432
|
| 'certificate'
|
|
711
1433
|
| 'diploma'
|
|
712
|
-
| 'advancedDiploma'
|
|
713
1434
|
| 'degree'
|
|
1435
|
+
| 'apprenticeship'
|
|
714
1436
|
| 'microCredential'
|
|
715
1437
|
| 'recognition'
|
|
716
1438
|
| 'externalCertification'
|
|
1439
|
+
credentialScope?: 'postsecondary' | 'vocational' | 'apprenticeship'
|
|
717
1440
|
description?: string
|
|
1441
|
+
sortOrder: number
|
|
718
1442
|
isEnabled?: boolean
|
|
719
1443
|
}
|
|
720
1444
|
|
|
@@ -769,7 +1493,14 @@ export type Person = {
|
|
|
769
1493
|
lastName: string
|
|
770
1494
|
suffixes?: Array<string>
|
|
771
1495
|
slug: Slug
|
|
772
|
-
|
|
1496
|
+
email?: string
|
|
1497
|
+
phone?: string
|
|
1498
|
+
mobilePhone?: string
|
|
1499
|
+
socialLinks?: Array<{
|
|
1500
|
+
platform?: string
|
|
1501
|
+
url?: string
|
|
1502
|
+
_key: string
|
|
1503
|
+
}>
|
|
773
1504
|
image?: {
|
|
774
1505
|
asset?: {
|
|
775
1506
|
_ref: string
|
|
@@ -784,14 +1515,11 @@ export type Person = {
|
|
|
784
1515
|
caption?: string
|
|
785
1516
|
_type: 'accessibleImage'
|
|
786
1517
|
}
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
_key: string
|
|
793
|
-
}>
|
|
794
|
-
siteRoles?: Array<'faculty' | 'staff' | 'recruitment' | 'testimonial' | 'dean'>
|
|
1518
|
+
jobTitle?: string
|
|
1519
|
+
siteRoles?: Array<
|
|
1520
|
+
'faculty' | 'staff' | 'recruitment' | 'internationalRecruitment' | 'testimonial' | 'dean'
|
|
1521
|
+
>
|
|
1522
|
+
recruitmentConnectLink?: string
|
|
795
1523
|
affiliations?: Array<{
|
|
796
1524
|
program?: {
|
|
797
1525
|
_ref: string
|
|
@@ -838,6 +1566,28 @@ export type AccessibleImage = {
|
|
|
838
1566
|
caption?: string
|
|
839
1567
|
}
|
|
840
1568
|
|
|
1569
|
+
export type Code = {
|
|
1570
|
+
_type: 'code'
|
|
1571
|
+
language?: string
|
|
1572
|
+
filename?: string
|
|
1573
|
+
code?: string
|
|
1574
|
+
highlightedLines?: Array<number>
|
|
1575
|
+
}
|
|
1576
|
+
|
|
1577
|
+
export type Table = {
|
|
1578
|
+
_type: 'table'
|
|
1579
|
+
rows?: Array<
|
|
1580
|
+
{
|
|
1581
|
+
_key: string
|
|
1582
|
+
} & TableRow
|
|
1583
|
+
>
|
|
1584
|
+
}
|
|
1585
|
+
|
|
1586
|
+
export type TableRow = {
|
|
1587
|
+
_type: 'tableRow'
|
|
1588
|
+
cells?: Array<string>
|
|
1589
|
+
}
|
|
1590
|
+
|
|
841
1591
|
export type MediaTag = {
|
|
842
1592
|
_id: string
|
|
843
1593
|
_type: 'media.tag'
|
|
@@ -868,25 +1618,25 @@ export type SanityImagePalette = {
|
|
|
868
1618
|
|
|
869
1619
|
export type SanityImageDimensions = {
|
|
870
1620
|
_type: 'sanity.imageDimensions'
|
|
871
|
-
height
|
|
872
|
-
width
|
|
873
|
-
aspectRatio
|
|
1621
|
+
height: number
|
|
1622
|
+
width: number
|
|
1623
|
+
aspectRatio: number
|
|
874
1624
|
}
|
|
875
1625
|
|
|
876
1626
|
export type SanityImageHotspot = {
|
|
877
1627
|
_type: 'sanity.imageHotspot'
|
|
878
|
-
x
|
|
879
|
-
y
|
|
880
|
-
height
|
|
881
|
-
width
|
|
1628
|
+
x: number
|
|
1629
|
+
y: number
|
|
1630
|
+
height: number
|
|
1631
|
+
width: number
|
|
882
1632
|
}
|
|
883
1633
|
|
|
884
1634
|
export type SanityImageCrop = {
|
|
885
1635
|
_type: 'sanity.imageCrop'
|
|
886
|
-
top
|
|
887
|
-
bottom
|
|
888
|
-
left
|
|
889
|
-
right
|
|
1636
|
+
top: number
|
|
1637
|
+
bottom: number
|
|
1638
|
+
left: number
|
|
1639
|
+
right: number
|
|
890
1640
|
}
|
|
891
1641
|
|
|
892
1642
|
export type SanityFileAsset = {
|
|
@@ -966,14 +1716,23 @@ export type SanityAssetSourceData = {
|
|
|
966
1716
|
}
|
|
967
1717
|
|
|
968
1718
|
export type AllSanitySchemaTypes =
|
|
1719
|
+
| MediaTextSection
|
|
1720
|
+
| RichTextSection
|
|
1721
|
+
| GallerySection
|
|
1722
|
+
| StaffListSection
|
|
1723
|
+
| FaqSection
|
|
1724
|
+
| FaqItem
|
|
969
1725
|
| MenuItem
|
|
970
1726
|
| Link
|
|
971
1727
|
| PtBasic
|
|
1728
|
+
| PtButton
|
|
972
1729
|
| Figure
|
|
973
1730
|
| Redirect
|
|
974
1731
|
| Event
|
|
975
1732
|
| NewsArticle
|
|
976
1733
|
| Webpage
|
|
1734
|
+
| Facility
|
|
1735
|
+
| CanadianAddress
|
|
977
1736
|
| ProgramFile
|
|
978
1737
|
| Testimonial
|
|
979
1738
|
| Campus
|
|
@@ -988,6 +1747,9 @@ export type AllSanitySchemaTypes =
|
|
|
988
1747
|
| School
|
|
989
1748
|
| Person
|
|
990
1749
|
| AccessibleImage
|
|
1750
|
+
| Code
|
|
1751
|
+
| Table
|
|
1752
|
+
| TableRow
|
|
991
1753
|
| MediaTag
|
|
992
1754
|
| SanityImagePaletteSwatch
|
|
993
1755
|
| SanityImagePalette
|