@nowline/core 0.2.0

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.
Files changed (69) hide show
  1. package/LICENSE +190 -0
  2. package/README.md +84 -0
  3. package/dist/generated/ast.d.ts +958 -0
  4. package/dist/generated/ast.d.ts.map +1 -0
  5. package/dist/generated/ast.js +795 -0
  6. package/dist/generated/ast.js.map +1 -0
  7. package/dist/generated/grammar.d.ts +7 -0
  8. package/dist/generated/grammar.d.ts.map +1 -0
  9. package/dist/generated/grammar.js +2509 -0
  10. package/dist/generated/grammar.js.map +1 -0
  11. package/dist/generated/module.d.ts +14 -0
  12. package/dist/generated/module.d.ts.map +1 -0
  13. package/dist/generated/module.js +21 -0
  14. package/dist/generated/module.js.map +1 -0
  15. package/dist/i18n/codes.d.ts +3 -0
  16. package/dist/i18n/codes.d.ts.map +1 -0
  17. package/dist/i18n/codes.js +54 -0
  18. package/dist/i18n/codes.js.map +1 -0
  19. package/dist/i18n/index.d.ts +17 -0
  20. package/dist/i18n/index.d.ts.map +1 -0
  21. package/dist/i18n/index.js +82 -0
  22. package/dist/i18n/index.js.map +1 -0
  23. package/dist/i18n/messages.en.d.ts +96 -0
  24. package/dist/i18n/messages.en.d.ts.map +1 -0
  25. package/dist/i18n/messages.en.js +57 -0
  26. package/dist/i18n/messages.en.js.map +1 -0
  27. package/dist/i18n/messages.fr-CA.d.ts +3 -0
  28. package/dist/i18n/messages.fr-CA.d.ts.map +1 -0
  29. package/dist/i18n/messages.fr-CA.js +11 -0
  30. package/dist/i18n/messages.fr-CA.js.map +1 -0
  31. package/dist/i18n/messages.fr-FR.d.ts +3 -0
  32. package/dist/i18n/messages.fr-FR.d.ts.map +1 -0
  33. package/dist/i18n/messages.fr-FR.js +11 -0
  34. package/dist/i18n/messages.fr-FR.js.map +1 -0
  35. package/dist/i18n/messages.fr.d.ts +3 -0
  36. package/dist/i18n/messages.fr.d.ts.map +1 -0
  37. package/dist/i18n/messages.fr.js +55 -0
  38. package/dist/i18n/messages.fr.js.map +1 -0
  39. package/dist/index.d.ts +9 -0
  40. package/dist/index.d.ts.map +1 -0
  41. package/dist/index.js +8 -0
  42. package/dist/index.js.map +1 -0
  43. package/dist/language/include-resolver.d.ts +46 -0
  44. package/dist/language/include-resolver.d.ts.map +1 -0
  45. package/dist/language/include-resolver.js +306 -0
  46. package/dist/language/include-resolver.js.map +1 -0
  47. package/dist/language/nowline-module.d.ts +18 -0
  48. package/dist/language/nowline-module.d.ts.map +1 -0
  49. package/dist/language/nowline-module.js +63 -0
  50. package/dist/language/nowline-module.js.map +1 -0
  51. package/dist/language/nowline-validator.d.ts +65 -0
  52. package/dist/language/nowline-validator.d.ts.map +1 -0
  53. package/dist/language/nowline-validator.js +1654 -0
  54. package/dist/language/nowline-validator.js.map +1 -0
  55. package/package.json +37 -0
  56. package/src/generated/ast.ts +1178 -0
  57. package/src/generated/grammar.ts +2511 -0
  58. package/src/generated/module.ts +25 -0
  59. package/src/i18n/codes.ts +102 -0
  60. package/src/i18n/index.ts +102 -0
  61. package/src/i18n/messages.en.ts +86 -0
  62. package/src/i18n/messages.fr-CA.ts +13 -0
  63. package/src/i18n/messages.fr-FR.ts +13 -0
  64. package/src/i18n/messages.fr.ts +91 -0
  65. package/src/index.ts +22 -0
  66. package/src/language/include-resolver.ts +470 -0
  67. package/src/language/nowline-module.ts +114 -0
  68. package/src/language/nowline-validator.ts +1991 -0
  69. package/src/language/nowline.langium +217 -0
@@ -0,0 +1,1178 @@
1
+ /******************************************************************************
2
+ * This file was generated by langium-cli 4.2.0.
3
+ * DO NOT EDIT MANUALLY!
4
+ ******************************************************************************/
5
+
6
+ /* eslint-disable */
7
+ import * as langium from 'langium';
8
+
9
+ export const NowlineTerminals = {
10
+ INDENT: /\x01/,
11
+ DEDENT: /\x02/,
12
+ INCLUDE_OPTION_KEY: /(config|roadmap):/,
13
+ URL: /https?:\/\/[^\s\[\],]+/,
14
+ STRING: /"([^"\\]|\\.)*"/,
15
+ DATE_LITERAL: /\d{4}-\d{2}-\d{2}/,
16
+ DURATION_LITERAL: /\d+(\.\d+)?[dwmqy]/,
17
+ PERCENTAGE: /\d+(\.\d+)?%/,
18
+ COLOR_HEX: /#[0-9a-fA-F]{3,8}/,
19
+ DECIMAL: /\d+\.\d+/,
20
+ INTEGER: /\d+/,
21
+ PROPERTY_KEY_WITH_COLON: /[a-zA-Z_][a-zA-Z0-9_-]*:/,
22
+ ID: /[a-zA-Z_][a-zA-Z0-9_-]*/,
23
+ WS: /[\t ]+/,
24
+ NL: /[\r\n]+/,
25
+ SL_COMMENT: /\/\/[^\r\n]*/,
26
+ ML_COMMENT: /\/\*[\s\S]*?\*\//,
27
+ LINE_CONTINUATION: /\\[ \t]*\r?\n[ \t]*/,
28
+ };
29
+
30
+ export type NowlineTerminalNames = keyof typeof NowlineTerminals;
31
+
32
+ export type NowlineKeywordNames =
33
+ | ","
34
+ | "["
35
+ | "]"
36
+ | "anchor"
37
+ | "calendar"
38
+ | "config"
39
+ | "default"
40
+ | "description"
41
+ | "footnote"
42
+ | "group"
43
+ | "include"
44
+ | "item"
45
+ | "label"
46
+ | "milestone"
47
+ | "nowline"
48
+ | "parallel"
49
+ | "person"
50
+ | "roadmap"
51
+ | "scale"
52
+ | "size"
53
+ | "status"
54
+ | "style"
55
+ | "swimlane"
56
+ | "symbol"
57
+ | "team";
58
+
59
+ export type NowlineTokenNames = NowlineTerminalNames | NowlineKeywordNames;
60
+
61
+ export interface AnchorDeclaration extends langium.AstNode {
62
+ readonly $container: NowlineFile;
63
+ readonly $type: 'AnchorDeclaration';
64
+ description?: DescriptionDirective;
65
+ name?: string;
66
+ properties: Array<EntityProperty>;
67
+ title?: string;
68
+ }
69
+
70
+ export const AnchorDeclaration = {
71
+ $type: 'AnchorDeclaration',
72
+ description: 'description',
73
+ name: 'name',
74
+ properties: 'properties',
75
+ title: 'title'
76
+ } as const;
77
+
78
+ export function isAnchorDeclaration(item: unknown): item is AnchorDeclaration {
79
+ return reflection.isInstance(item, AnchorDeclaration.$type);
80
+ }
81
+
82
+ export interface BlockProperty extends langium.AstNode {
83
+ readonly $container: CalendarBlock | NowlineDirective | ScaleBlock;
84
+ readonly $type: 'BlockProperty';
85
+ key: string;
86
+ value: BlockPropertyValue;
87
+ }
88
+
89
+ export const BlockProperty = {
90
+ $type: 'BlockProperty',
91
+ key: 'key',
92
+ value: 'value'
93
+ } as const;
94
+
95
+ export function isBlockProperty(item: unknown): item is BlockProperty {
96
+ return reflection.isInstance(item, BlockProperty.$type);
97
+ }
98
+
99
+ export type BlockPropertyValue = string;
100
+
101
+ export function isBlockPropertyValue(item: unknown): item is BlockPropertyValue {
102
+ return (typeof item === 'string' && (/[a-zA-Z_][a-zA-Z0-9_-]*/.test(item) || /\d+/.test(item) || /"([^"\\]|\\.)*"/.test(item) || /\d+(\.\d+)?[dwmqy]/.test(item)));
103
+ }
104
+
105
+ export interface CalendarBlock extends langium.AstNode {
106
+ readonly $container: NowlineFile;
107
+ readonly $type: 'CalendarBlock';
108
+ properties: Array<BlockProperty>;
109
+ }
110
+
111
+ export const CalendarBlock = {
112
+ $type: 'CalendarBlock',
113
+ properties: 'properties'
114
+ } as const;
115
+
116
+ export function isCalendarBlock(item: unknown): item is CalendarBlock {
117
+ return reflection.isInstance(item, CalendarBlock.$type);
118
+ }
119
+
120
+ export type ConfigEntry = CalendarBlock | DefaultDeclaration | ScaleBlock | StyleDeclaration | SymbolDeclaration;
121
+
122
+ export const ConfigEntry = {
123
+ $type: 'ConfigEntry'
124
+ } as const;
125
+
126
+ export function isConfigEntry(item: unknown): item is ConfigEntry {
127
+ return reflection.isInstance(item, ConfigEntry.$type);
128
+ }
129
+
130
+ export interface DefaultDeclaration extends langium.AstNode {
131
+ readonly $container: NowlineFile;
132
+ readonly $type: 'DefaultDeclaration';
133
+ entityType: DefaultEntityType;
134
+ properties: Array<EntityProperty>;
135
+ }
136
+
137
+ export const DefaultDeclaration = {
138
+ $type: 'DefaultDeclaration',
139
+ entityType: 'entityType',
140
+ properties: 'properties'
141
+ } as const;
142
+
143
+ export function isDefaultDeclaration(item: unknown): item is DefaultDeclaration {
144
+ return reflection.isInstance(item, DefaultDeclaration.$type);
145
+ }
146
+
147
+ export type DefaultEntityType = 'anchor' | 'footnote' | 'group' | 'item' | 'label' | 'milestone' | 'parallel' | 'roadmap' | 'swimlane';
148
+
149
+ export function isDefaultEntityType(item: unknown): item is DefaultEntityType {
150
+ return item === 'item' || item === 'label' || item === 'swimlane' || item === 'roadmap' || item === 'milestone' || item === 'footnote' || item === 'anchor' || item === 'parallel' || item === 'group';
151
+ }
152
+
153
+ export interface DescriptionDirective extends langium.AstNode {
154
+ readonly $container: AnchorDeclaration | FootnoteDeclaration | GroupBlock | ItemDeclaration | LabelDeclaration | MilestoneDeclaration | ParallelBlock | PersonDeclaration | SizeDeclaration | StatusDeclaration | SwimlaneDeclaration | SymbolDeclaration | TeamDeclaration;
155
+ readonly $type: 'DescriptionDirective';
156
+ text: string;
157
+ }
158
+
159
+ export const DescriptionDirective = {
160
+ $type: 'DescriptionDirective',
161
+ text: 'text'
162
+ } as const;
163
+
164
+ export function isDescriptionDirective(item: unknown): item is DescriptionDirective {
165
+ return reflection.isInstance(item, DescriptionDirective.$type);
166
+ }
167
+
168
+ export interface EntityProperty extends langium.AstNode {
169
+ readonly $container: AnchorDeclaration | DefaultDeclaration | FootnoteDeclaration | GroupBlock | ItemDeclaration | LabelDeclaration | MilestoneDeclaration | ParallelBlock | PersonDeclaration | RoadmapDeclaration | SizeDeclaration | StatusDeclaration | SwimlaneDeclaration | SymbolDeclaration | TeamDeclaration;
170
+ readonly $type: 'EntityProperty';
171
+ key: string;
172
+ value?: PropertyAtom;
173
+ values: Array<PropertyAtom>;
174
+ }
175
+
176
+ export const EntityProperty = {
177
+ $type: 'EntityProperty',
178
+ key: 'key',
179
+ value: 'value',
180
+ values: 'values'
181
+ } as const;
182
+
183
+ export function isEntityProperty(item: unknown): item is EntityProperty {
184
+ return reflection.isInstance(item, EntityProperty.$type);
185
+ }
186
+
187
+ export interface FootnoteDeclaration extends langium.AstNode {
188
+ readonly $container: NowlineFile;
189
+ readonly $type: 'FootnoteDeclaration';
190
+ description?: DescriptionDirective;
191
+ name?: string;
192
+ properties: Array<EntityProperty>;
193
+ title?: string;
194
+ }
195
+
196
+ export const FootnoteDeclaration = {
197
+ $type: 'FootnoteDeclaration',
198
+ description: 'description',
199
+ name: 'name',
200
+ properties: 'properties',
201
+ title: 'title'
202
+ } as const;
203
+
204
+ export function isFootnoteDeclaration(item: unknown): item is FootnoteDeclaration {
205
+ return reflection.isInstance(item, FootnoteDeclaration.$type);
206
+ }
207
+
208
+ export interface GroupBlock extends langium.AstNode {
209
+ readonly $container: GroupBlock | ParallelBlock | SwimlaneDeclaration;
210
+ readonly $type: 'GroupBlock';
211
+ content: Array<GroupContent>;
212
+ name?: string;
213
+ properties: Array<EntityProperty>;
214
+ title?: string;
215
+ }
216
+
217
+ export const GroupBlock = {
218
+ $type: 'GroupBlock',
219
+ content: 'content',
220
+ name: 'name',
221
+ properties: 'properties',
222
+ title: 'title'
223
+ } as const;
224
+
225
+ export function isGroupBlock(item: unknown): item is GroupBlock {
226
+ return reflection.isInstance(item, GroupBlock.$type);
227
+ }
228
+
229
+ export type GroupContent = DescriptionDirective | GroupBlock | ItemDeclaration | ParallelBlock;
230
+
231
+ export const GroupContent = {
232
+ $type: 'GroupContent'
233
+ } as const;
234
+
235
+ export function isGroupContent(item: unknown): item is GroupContent {
236
+ return reflection.isInstance(item, GroupContent.$type);
237
+ }
238
+
239
+ export interface IncludeDeclaration extends langium.AstNode {
240
+ readonly $container: NowlineFile;
241
+ readonly $type: 'IncludeDeclaration';
242
+ options: Array<IncludeOption>;
243
+ path: string;
244
+ }
245
+
246
+ export const IncludeDeclaration = {
247
+ $type: 'IncludeDeclaration',
248
+ options: 'options',
249
+ path: 'path'
250
+ } as const;
251
+
252
+ export function isIncludeDeclaration(item: unknown): item is IncludeDeclaration {
253
+ return reflection.isInstance(item, IncludeDeclaration.$type);
254
+ }
255
+
256
+ export interface IncludeOption extends langium.AstNode {
257
+ readonly $container: IncludeDeclaration;
258
+ readonly $type: 'IncludeOption';
259
+ key: string;
260
+ value: string;
261
+ }
262
+
263
+ export const IncludeOption = {
264
+ $type: 'IncludeOption',
265
+ key: 'key',
266
+ value: 'value'
267
+ } as const;
268
+
269
+ export function isIncludeOption(item: unknown): item is IncludeOption {
270
+ return reflection.isInstance(item, IncludeOption.$type);
271
+ }
272
+
273
+ export interface ItemDeclaration extends langium.AstNode {
274
+ readonly $container: GroupBlock | ParallelBlock | SwimlaneDeclaration;
275
+ readonly $type: 'ItemDeclaration';
276
+ description?: DescriptionDirective;
277
+ name?: string;
278
+ properties: Array<EntityProperty>;
279
+ title?: string;
280
+ }
281
+
282
+ export const ItemDeclaration = {
283
+ $type: 'ItemDeclaration',
284
+ description: 'description',
285
+ name: 'name',
286
+ properties: 'properties',
287
+ title: 'title'
288
+ } as const;
289
+
290
+ export function isItemDeclaration(item: unknown): item is ItemDeclaration {
291
+ return reflection.isInstance(item, ItemDeclaration.$type);
292
+ }
293
+
294
+ export interface LabelDeclaration extends langium.AstNode {
295
+ readonly $container: NowlineFile;
296
+ readonly $type: 'LabelDeclaration';
297
+ description?: DescriptionDirective;
298
+ name?: string;
299
+ properties: Array<EntityProperty>;
300
+ title?: string;
301
+ }
302
+
303
+ export const LabelDeclaration = {
304
+ $type: 'LabelDeclaration',
305
+ description: 'description',
306
+ name: 'name',
307
+ properties: 'properties',
308
+ title: 'title'
309
+ } as const;
310
+
311
+ export function isLabelDeclaration(item: unknown): item is LabelDeclaration {
312
+ return reflection.isInstance(item, LabelDeclaration.$type);
313
+ }
314
+
315
+ export interface MilestoneDeclaration extends langium.AstNode {
316
+ readonly $container: NowlineFile;
317
+ readonly $type: 'MilestoneDeclaration';
318
+ description?: DescriptionDirective;
319
+ name?: string;
320
+ properties: Array<EntityProperty>;
321
+ title?: string;
322
+ }
323
+
324
+ export const MilestoneDeclaration = {
325
+ $type: 'MilestoneDeclaration',
326
+ description: 'description',
327
+ name: 'name',
328
+ properties: 'properties',
329
+ title: 'title'
330
+ } as const;
331
+
332
+ export function isMilestoneDeclaration(item: unknown): item is MilestoneDeclaration {
333
+ return reflection.isInstance(item, MilestoneDeclaration.$type);
334
+ }
335
+
336
+ export interface NowlineDirective extends langium.AstNode {
337
+ readonly $container: NowlineFile;
338
+ readonly $type: 'NowlineDirective';
339
+ properties: Array<BlockProperty>;
340
+ version: string;
341
+ }
342
+
343
+ export const NowlineDirective = {
344
+ $type: 'NowlineDirective',
345
+ properties: 'properties',
346
+ version: 'version'
347
+ } as const;
348
+
349
+ export function isNowlineDirective(item: unknown): item is NowlineDirective {
350
+ return reflection.isInstance(item, NowlineDirective.$type);
351
+ }
352
+
353
+ export interface NowlineFile extends langium.AstNode {
354
+ readonly $type: 'NowlineFile';
355
+ configEntries: Array<ConfigEntry>;
356
+ directive?: NowlineDirective;
357
+ hasConfig: boolean;
358
+ includes: Array<IncludeDeclaration>;
359
+ roadmapDecl?: RoadmapDeclaration;
360
+ roadmapEntries: Array<RoadmapEntry>;
361
+ }
362
+
363
+ export const NowlineFile = {
364
+ $type: 'NowlineFile',
365
+ configEntries: 'configEntries',
366
+ directive: 'directive',
367
+ hasConfig: 'hasConfig',
368
+ includes: 'includes',
369
+ roadmapDecl: 'roadmapDecl',
370
+ roadmapEntries: 'roadmapEntries'
371
+ } as const;
372
+
373
+ export function isNowlineFile(item: unknown): item is NowlineFile {
374
+ return reflection.isInstance(item, NowlineFile.$type);
375
+ }
376
+
377
+ export interface ParallelBlock extends langium.AstNode {
378
+ readonly $container: GroupBlock | SwimlaneDeclaration;
379
+ readonly $type: 'ParallelBlock';
380
+ content: Array<ParallelContent>;
381
+ name?: string;
382
+ properties: Array<EntityProperty>;
383
+ title?: string;
384
+ }
385
+
386
+ export const ParallelBlock = {
387
+ $type: 'ParallelBlock',
388
+ content: 'content',
389
+ name: 'name',
390
+ properties: 'properties',
391
+ title: 'title'
392
+ } as const;
393
+
394
+ export function isParallelBlock(item: unknown): item is ParallelBlock {
395
+ return reflection.isInstance(item, ParallelBlock.$type);
396
+ }
397
+
398
+ export type ParallelContent = DescriptionDirective | GroupBlock | ItemDeclaration;
399
+
400
+ export const ParallelContent = {
401
+ $type: 'ParallelContent'
402
+ } as const;
403
+
404
+ export function isParallelContent(item: unknown): item is ParallelContent {
405
+ return reflection.isInstance(item, ParallelContent.$type);
406
+ }
407
+
408
+ export interface PersonDeclaration extends langium.AstNode {
409
+ readonly $container: NowlineFile;
410
+ readonly $type: 'PersonDeclaration';
411
+ description?: DescriptionDirective;
412
+ name?: string;
413
+ properties: Array<EntityProperty>;
414
+ title?: string;
415
+ }
416
+
417
+ export const PersonDeclaration = {
418
+ $type: 'PersonDeclaration',
419
+ description: 'description',
420
+ name: 'name',
421
+ properties: 'properties',
422
+ title: 'title'
423
+ } as const;
424
+
425
+ export function isPersonDeclaration(item: unknown): item is PersonDeclaration {
426
+ return reflection.isInstance(item, PersonDeclaration.$type);
427
+ }
428
+
429
+ export interface PersonMemberRef extends langium.AstNode {
430
+ readonly $container: TeamDeclaration;
431
+ readonly $type: 'PersonMemberRef';
432
+ ref: string;
433
+ }
434
+
435
+ export const PersonMemberRef = {
436
+ $type: 'PersonMemberRef',
437
+ ref: 'ref'
438
+ } as const;
439
+
440
+ export function isPersonMemberRef(item: unknown): item is PersonMemberRef {
441
+ return reflection.isInstance(item, PersonMemberRef.$type);
442
+ }
443
+
444
+ export type PropertyAtom = 'person' | string;
445
+
446
+ export function isPropertyAtom(item: unknown): item is PropertyAtom {
447
+ return item === 'person' || (typeof item === 'string' && (/[a-zA-Z_][a-zA-Z0-9_-]*/.test(item) || /"([^"\\]|\\.)*"/.test(item) || /\d+(\.\d+)?[dwmqy]/.test(item) || /\d+(\.\d+)?%/.test(item) || /https?:\/\/[^\s\[\],]+/.test(item) || /\d{4}-\d{2}-\d{2}/.test(item) || /#[0-9a-fA-F]{3,8}/.test(item) || /\d+\.\d+/.test(item) || /\d+/.test(item)));
448
+ }
449
+
450
+ export interface RoadmapDeclaration extends langium.AstNode {
451
+ readonly $container: NowlineFile;
452
+ readonly $type: 'RoadmapDeclaration';
453
+ name?: string;
454
+ properties: Array<EntityProperty>;
455
+ title?: string;
456
+ }
457
+
458
+ export const RoadmapDeclaration = {
459
+ $type: 'RoadmapDeclaration',
460
+ name: 'name',
461
+ properties: 'properties',
462
+ title: 'title'
463
+ } as const;
464
+
465
+ export function isRoadmapDeclaration(item: unknown): item is RoadmapDeclaration {
466
+ return reflection.isInstance(item, RoadmapDeclaration.$type);
467
+ }
468
+
469
+ export type RoadmapEntry = AnchorDeclaration | FootnoteDeclaration | LabelDeclaration | MilestoneDeclaration | PersonDeclaration | SizeDeclaration | StatusDeclaration | SwimlaneDeclaration | TeamDeclaration;
470
+
471
+ export const RoadmapEntry = {
472
+ $type: 'RoadmapEntry'
473
+ } as const;
474
+
475
+ export function isRoadmapEntry(item: unknown): item is RoadmapEntry {
476
+ return reflection.isInstance(item, RoadmapEntry.$type);
477
+ }
478
+
479
+ export interface ScaleBlock extends langium.AstNode {
480
+ readonly $container: NowlineFile;
481
+ readonly $type: 'ScaleBlock';
482
+ properties: Array<BlockProperty>;
483
+ }
484
+
485
+ export const ScaleBlock = {
486
+ $type: 'ScaleBlock',
487
+ properties: 'properties'
488
+ } as const;
489
+
490
+ export function isScaleBlock(item: unknown): item is ScaleBlock {
491
+ return reflection.isInstance(item, ScaleBlock.$type);
492
+ }
493
+
494
+ export interface SizeDeclaration extends langium.AstNode {
495
+ readonly $container: NowlineFile;
496
+ readonly $type: 'SizeDeclaration';
497
+ description?: DescriptionDirective;
498
+ name?: string;
499
+ properties: Array<EntityProperty>;
500
+ title?: string;
501
+ }
502
+
503
+ export const SizeDeclaration = {
504
+ $type: 'SizeDeclaration',
505
+ description: 'description',
506
+ name: 'name',
507
+ properties: 'properties',
508
+ title: 'title'
509
+ } as const;
510
+
511
+ export function isSizeDeclaration(item: unknown): item is SizeDeclaration {
512
+ return reflection.isInstance(item, SizeDeclaration.$type);
513
+ }
514
+
515
+ export interface StatusDeclaration extends langium.AstNode {
516
+ readonly $container: NowlineFile;
517
+ readonly $type: 'StatusDeclaration';
518
+ description?: DescriptionDirective;
519
+ name?: string;
520
+ properties: Array<EntityProperty>;
521
+ title?: string;
522
+ }
523
+
524
+ export const StatusDeclaration = {
525
+ $type: 'StatusDeclaration',
526
+ description: 'description',
527
+ name: 'name',
528
+ properties: 'properties',
529
+ title: 'title'
530
+ } as const;
531
+
532
+ export function isStatusDeclaration(item: unknown): item is StatusDeclaration {
533
+ return reflection.isInstance(item, StatusDeclaration.$type);
534
+ }
535
+
536
+ export interface StyleDeclaration extends langium.AstNode {
537
+ readonly $container: NowlineFile;
538
+ readonly $type: 'StyleDeclaration';
539
+ name?: string;
540
+ properties: Array<StyleProperty>;
541
+ title?: string;
542
+ }
543
+
544
+ export const StyleDeclaration = {
545
+ $type: 'StyleDeclaration',
546
+ name: 'name',
547
+ properties: 'properties',
548
+ title: 'title'
549
+ } as const;
550
+
551
+ export function isStyleDeclaration(item: unknown): item is StyleDeclaration {
552
+ return reflection.isInstance(item, StyleDeclaration.$type);
553
+ }
554
+
555
+ export interface StyleProperty extends langium.AstNode {
556
+ readonly $container: StyleDeclaration;
557
+ readonly $type: 'StyleProperty';
558
+ key: string;
559
+ value: StylePropertyValue;
560
+ }
561
+
562
+ export const StyleProperty = {
563
+ $type: 'StyleProperty',
564
+ key: 'key',
565
+ value: 'value'
566
+ } as const;
567
+
568
+ export function isStyleProperty(item: unknown): item is StyleProperty {
569
+ return reflection.isInstance(item, StyleProperty.$type);
570
+ }
571
+
572
+ export type StylePropertyValue = 'person' | string;
573
+
574
+ export function isStylePropertyValue(item: unknown): item is StylePropertyValue {
575
+ return item === 'person' || (typeof item === 'string' && (/[a-zA-Z_][a-zA-Z0-9_-]*/.test(item) || /#[0-9a-fA-F]{3,8}/.test(item) || /"([^"\\]|\\.)*"/.test(item)));
576
+ }
577
+
578
+ export type SwimlaneContent = DescriptionDirective | GroupBlock | ItemDeclaration | ParallelBlock;
579
+
580
+ export const SwimlaneContent = {
581
+ $type: 'SwimlaneContent'
582
+ } as const;
583
+
584
+ export function isSwimlaneContent(item: unknown): item is SwimlaneContent {
585
+ return reflection.isInstance(item, SwimlaneContent.$type);
586
+ }
587
+
588
+ export interface SwimlaneDeclaration extends langium.AstNode {
589
+ readonly $container: NowlineFile;
590
+ readonly $type: 'SwimlaneDeclaration';
591
+ content: Array<SwimlaneContent>;
592
+ name?: string;
593
+ properties: Array<EntityProperty>;
594
+ title?: string;
595
+ }
596
+
597
+ export const SwimlaneDeclaration = {
598
+ $type: 'SwimlaneDeclaration',
599
+ content: 'content',
600
+ name: 'name',
601
+ properties: 'properties',
602
+ title: 'title'
603
+ } as const;
604
+
605
+ export function isSwimlaneDeclaration(item: unknown): item is SwimlaneDeclaration {
606
+ return reflection.isInstance(item, SwimlaneDeclaration.$type);
607
+ }
608
+
609
+ export interface SymbolDeclaration extends langium.AstNode {
610
+ readonly $container: NowlineFile;
611
+ readonly $type: 'SymbolDeclaration';
612
+ description?: DescriptionDirective;
613
+ name?: string;
614
+ properties: Array<EntityProperty>;
615
+ title?: string;
616
+ }
617
+
618
+ export const SymbolDeclaration = {
619
+ $type: 'SymbolDeclaration',
620
+ description: 'description',
621
+ name: 'name',
622
+ properties: 'properties',
623
+ title: 'title'
624
+ } as const;
625
+
626
+ export function isSymbolDeclaration(item: unknown): item is SymbolDeclaration {
627
+ return reflection.isInstance(item, SymbolDeclaration.$type);
628
+ }
629
+
630
+ export type TeamContent = DescriptionDirective | PersonMemberRef | TeamDeclaration;
631
+
632
+ export const TeamContent = {
633
+ $type: 'TeamContent'
634
+ } as const;
635
+
636
+ export function isTeamContent(item: unknown): item is TeamContent {
637
+ return reflection.isInstance(item, TeamContent.$type);
638
+ }
639
+
640
+ export interface TeamDeclaration extends langium.AstNode {
641
+ readonly $container: NowlineFile | TeamDeclaration;
642
+ readonly $type: 'TeamDeclaration';
643
+ content: Array<TeamContent>;
644
+ name?: string;
645
+ properties: Array<EntityProperty>;
646
+ title?: string;
647
+ }
648
+
649
+ export const TeamDeclaration = {
650
+ $type: 'TeamDeclaration',
651
+ content: 'content',
652
+ name: 'name',
653
+ properties: 'properties',
654
+ title: 'title'
655
+ } as const;
656
+
657
+ export function isTeamDeclaration(item: unknown): item is TeamDeclaration {
658
+ return reflection.isInstance(item, TeamDeclaration.$type);
659
+ }
660
+
661
+ export type NowlineAstType = {
662
+ AnchorDeclaration: AnchorDeclaration
663
+ BlockProperty: BlockProperty
664
+ CalendarBlock: CalendarBlock
665
+ ConfigEntry: ConfigEntry
666
+ DefaultDeclaration: DefaultDeclaration
667
+ DescriptionDirective: DescriptionDirective
668
+ EntityProperty: EntityProperty
669
+ FootnoteDeclaration: FootnoteDeclaration
670
+ GroupBlock: GroupBlock
671
+ GroupContent: GroupContent
672
+ IncludeDeclaration: IncludeDeclaration
673
+ IncludeOption: IncludeOption
674
+ ItemDeclaration: ItemDeclaration
675
+ LabelDeclaration: LabelDeclaration
676
+ MilestoneDeclaration: MilestoneDeclaration
677
+ NowlineDirective: NowlineDirective
678
+ NowlineFile: NowlineFile
679
+ ParallelBlock: ParallelBlock
680
+ ParallelContent: ParallelContent
681
+ PersonDeclaration: PersonDeclaration
682
+ PersonMemberRef: PersonMemberRef
683
+ RoadmapDeclaration: RoadmapDeclaration
684
+ RoadmapEntry: RoadmapEntry
685
+ ScaleBlock: ScaleBlock
686
+ SizeDeclaration: SizeDeclaration
687
+ StatusDeclaration: StatusDeclaration
688
+ StyleDeclaration: StyleDeclaration
689
+ StyleProperty: StyleProperty
690
+ SwimlaneContent: SwimlaneContent
691
+ SwimlaneDeclaration: SwimlaneDeclaration
692
+ SymbolDeclaration: SymbolDeclaration
693
+ TeamContent: TeamContent
694
+ TeamDeclaration: TeamDeclaration
695
+ }
696
+
697
+ export class NowlineAstReflection extends langium.AbstractAstReflection {
698
+ override readonly types = {
699
+ AnchorDeclaration: {
700
+ name: AnchorDeclaration.$type,
701
+ properties: {
702
+ description: {
703
+ name: AnchorDeclaration.description
704
+ },
705
+ name: {
706
+ name: AnchorDeclaration.name
707
+ },
708
+ properties: {
709
+ name: AnchorDeclaration.properties,
710
+ defaultValue: []
711
+ },
712
+ title: {
713
+ name: AnchorDeclaration.title
714
+ }
715
+ },
716
+ superTypes: [RoadmapEntry.$type]
717
+ },
718
+ BlockProperty: {
719
+ name: BlockProperty.$type,
720
+ properties: {
721
+ key: {
722
+ name: BlockProperty.key
723
+ },
724
+ value: {
725
+ name: BlockProperty.value
726
+ }
727
+ },
728
+ superTypes: []
729
+ },
730
+ CalendarBlock: {
731
+ name: CalendarBlock.$type,
732
+ properties: {
733
+ properties: {
734
+ name: CalendarBlock.properties,
735
+ defaultValue: []
736
+ }
737
+ },
738
+ superTypes: [ConfigEntry.$type]
739
+ },
740
+ ConfigEntry: {
741
+ name: ConfigEntry.$type,
742
+ properties: {
743
+ },
744
+ superTypes: []
745
+ },
746
+ DefaultDeclaration: {
747
+ name: DefaultDeclaration.$type,
748
+ properties: {
749
+ entityType: {
750
+ name: DefaultDeclaration.entityType
751
+ },
752
+ properties: {
753
+ name: DefaultDeclaration.properties,
754
+ defaultValue: []
755
+ }
756
+ },
757
+ superTypes: [ConfigEntry.$type]
758
+ },
759
+ DescriptionDirective: {
760
+ name: DescriptionDirective.$type,
761
+ properties: {
762
+ text: {
763
+ name: DescriptionDirective.text
764
+ }
765
+ },
766
+ superTypes: [GroupContent.$type, ParallelContent.$type, SwimlaneContent.$type, TeamContent.$type]
767
+ },
768
+ EntityProperty: {
769
+ name: EntityProperty.$type,
770
+ properties: {
771
+ key: {
772
+ name: EntityProperty.key
773
+ },
774
+ value: {
775
+ name: EntityProperty.value
776
+ },
777
+ values: {
778
+ name: EntityProperty.values,
779
+ defaultValue: []
780
+ }
781
+ },
782
+ superTypes: []
783
+ },
784
+ FootnoteDeclaration: {
785
+ name: FootnoteDeclaration.$type,
786
+ properties: {
787
+ description: {
788
+ name: FootnoteDeclaration.description
789
+ },
790
+ name: {
791
+ name: FootnoteDeclaration.name
792
+ },
793
+ properties: {
794
+ name: FootnoteDeclaration.properties,
795
+ defaultValue: []
796
+ },
797
+ title: {
798
+ name: FootnoteDeclaration.title
799
+ }
800
+ },
801
+ superTypes: [RoadmapEntry.$type]
802
+ },
803
+ GroupBlock: {
804
+ name: GroupBlock.$type,
805
+ properties: {
806
+ content: {
807
+ name: GroupBlock.content,
808
+ defaultValue: []
809
+ },
810
+ name: {
811
+ name: GroupBlock.name
812
+ },
813
+ properties: {
814
+ name: GroupBlock.properties,
815
+ defaultValue: []
816
+ },
817
+ title: {
818
+ name: GroupBlock.title
819
+ }
820
+ },
821
+ superTypes: [GroupContent.$type, ParallelContent.$type, SwimlaneContent.$type]
822
+ },
823
+ GroupContent: {
824
+ name: GroupContent.$type,
825
+ properties: {
826
+ },
827
+ superTypes: []
828
+ },
829
+ IncludeDeclaration: {
830
+ name: IncludeDeclaration.$type,
831
+ properties: {
832
+ options: {
833
+ name: IncludeDeclaration.options,
834
+ defaultValue: []
835
+ },
836
+ path: {
837
+ name: IncludeDeclaration.path
838
+ }
839
+ },
840
+ superTypes: []
841
+ },
842
+ IncludeOption: {
843
+ name: IncludeOption.$type,
844
+ properties: {
845
+ key: {
846
+ name: IncludeOption.key
847
+ },
848
+ value: {
849
+ name: IncludeOption.value
850
+ }
851
+ },
852
+ superTypes: []
853
+ },
854
+ ItemDeclaration: {
855
+ name: ItemDeclaration.$type,
856
+ properties: {
857
+ description: {
858
+ name: ItemDeclaration.description
859
+ },
860
+ name: {
861
+ name: ItemDeclaration.name
862
+ },
863
+ properties: {
864
+ name: ItemDeclaration.properties,
865
+ defaultValue: []
866
+ },
867
+ title: {
868
+ name: ItemDeclaration.title
869
+ }
870
+ },
871
+ superTypes: [GroupContent.$type, ParallelContent.$type, SwimlaneContent.$type]
872
+ },
873
+ LabelDeclaration: {
874
+ name: LabelDeclaration.$type,
875
+ properties: {
876
+ description: {
877
+ name: LabelDeclaration.description
878
+ },
879
+ name: {
880
+ name: LabelDeclaration.name
881
+ },
882
+ properties: {
883
+ name: LabelDeclaration.properties,
884
+ defaultValue: []
885
+ },
886
+ title: {
887
+ name: LabelDeclaration.title
888
+ }
889
+ },
890
+ superTypes: [RoadmapEntry.$type]
891
+ },
892
+ MilestoneDeclaration: {
893
+ name: MilestoneDeclaration.$type,
894
+ properties: {
895
+ description: {
896
+ name: MilestoneDeclaration.description
897
+ },
898
+ name: {
899
+ name: MilestoneDeclaration.name
900
+ },
901
+ properties: {
902
+ name: MilestoneDeclaration.properties,
903
+ defaultValue: []
904
+ },
905
+ title: {
906
+ name: MilestoneDeclaration.title
907
+ }
908
+ },
909
+ superTypes: [RoadmapEntry.$type]
910
+ },
911
+ NowlineDirective: {
912
+ name: NowlineDirective.$type,
913
+ properties: {
914
+ properties: {
915
+ name: NowlineDirective.properties,
916
+ defaultValue: []
917
+ },
918
+ version: {
919
+ name: NowlineDirective.version
920
+ }
921
+ },
922
+ superTypes: []
923
+ },
924
+ NowlineFile: {
925
+ name: NowlineFile.$type,
926
+ properties: {
927
+ configEntries: {
928
+ name: NowlineFile.configEntries,
929
+ defaultValue: []
930
+ },
931
+ directive: {
932
+ name: NowlineFile.directive
933
+ },
934
+ hasConfig: {
935
+ name: NowlineFile.hasConfig,
936
+ defaultValue: false
937
+ },
938
+ includes: {
939
+ name: NowlineFile.includes,
940
+ defaultValue: []
941
+ },
942
+ roadmapDecl: {
943
+ name: NowlineFile.roadmapDecl
944
+ },
945
+ roadmapEntries: {
946
+ name: NowlineFile.roadmapEntries,
947
+ defaultValue: []
948
+ }
949
+ },
950
+ superTypes: []
951
+ },
952
+ ParallelBlock: {
953
+ name: ParallelBlock.$type,
954
+ properties: {
955
+ content: {
956
+ name: ParallelBlock.content,
957
+ defaultValue: []
958
+ },
959
+ name: {
960
+ name: ParallelBlock.name
961
+ },
962
+ properties: {
963
+ name: ParallelBlock.properties,
964
+ defaultValue: []
965
+ },
966
+ title: {
967
+ name: ParallelBlock.title
968
+ }
969
+ },
970
+ superTypes: [GroupContent.$type, SwimlaneContent.$type]
971
+ },
972
+ ParallelContent: {
973
+ name: ParallelContent.$type,
974
+ properties: {
975
+ },
976
+ superTypes: []
977
+ },
978
+ PersonDeclaration: {
979
+ name: PersonDeclaration.$type,
980
+ properties: {
981
+ description: {
982
+ name: PersonDeclaration.description
983
+ },
984
+ name: {
985
+ name: PersonDeclaration.name
986
+ },
987
+ properties: {
988
+ name: PersonDeclaration.properties,
989
+ defaultValue: []
990
+ },
991
+ title: {
992
+ name: PersonDeclaration.title
993
+ }
994
+ },
995
+ superTypes: [RoadmapEntry.$type]
996
+ },
997
+ PersonMemberRef: {
998
+ name: PersonMemberRef.$type,
999
+ properties: {
1000
+ ref: {
1001
+ name: PersonMemberRef.ref
1002
+ }
1003
+ },
1004
+ superTypes: [TeamContent.$type]
1005
+ },
1006
+ RoadmapDeclaration: {
1007
+ name: RoadmapDeclaration.$type,
1008
+ properties: {
1009
+ name: {
1010
+ name: RoadmapDeclaration.name
1011
+ },
1012
+ properties: {
1013
+ name: RoadmapDeclaration.properties,
1014
+ defaultValue: []
1015
+ },
1016
+ title: {
1017
+ name: RoadmapDeclaration.title
1018
+ }
1019
+ },
1020
+ superTypes: []
1021
+ },
1022
+ RoadmapEntry: {
1023
+ name: RoadmapEntry.$type,
1024
+ properties: {
1025
+ },
1026
+ superTypes: []
1027
+ },
1028
+ ScaleBlock: {
1029
+ name: ScaleBlock.$type,
1030
+ properties: {
1031
+ properties: {
1032
+ name: ScaleBlock.properties,
1033
+ defaultValue: []
1034
+ }
1035
+ },
1036
+ superTypes: [ConfigEntry.$type]
1037
+ },
1038
+ SizeDeclaration: {
1039
+ name: SizeDeclaration.$type,
1040
+ properties: {
1041
+ description: {
1042
+ name: SizeDeclaration.description
1043
+ },
1044
+ name: {
1045
+ name: SizeDeclaration.name
1046
+ },
1047
+ properties: {
1048
+ name: SizeDeclaration.properties,
1049
+ defaultValue: []
1050
+ },
1051
+ title: {
1052
+ name: SizeDeclaration.title
1053
+ }
1054
+ },
1055
+ superTypes: [RoadmapEntry.$type]
1056
+ },
1057
+ StatusDeclaration: {
1058
+ name: StatusDeclaration.$type,
1059
+ properties: {
1060
+ description: {
1061
+ name: StatusDeclaration.description
1062
+ },
1063
+ name: {
1064
+ name: StatusDeclaration.name
1065
+ },
1066
+ properties: {
1067
+ name: StatusDeclaration.properties,
1068
+ defaultValue: []
1069
+ },
1070
+ title: {
1071
+ name: StatusDeclaration.title
1072
+ }
1073
+ },
1074
+ superTypes: [RoadmapEntry.$type]
1075
+ },
1076
+ StyleDeclaration: {
1077
+ name: StyleDeclaration.$type,
1078
+ properties: {
1079
+ name: {
1080
+ name: StyleDeclaration.name
1081
+ },
1082
+ properties: {
1083
+ name: StyleDeclaration.properties,
1084
+ defaultValue: []
1085
+ },
1086
+ title: {
1087
+ name: StyleDeclaration.title
1088
+ }
1089
+ },
1090
+ superTypes: [ConfigEntry.$type]
1091
+ },
1092
+ StyleProperty: {
1093
+ name: StyleProperty.$type,
1094
+ properties: {
1095
+ key: {
1096
+ name: StyleProperty.key
1097
+ },
1098
+ value: {
1099
+ name: StyleProperty.value
1100
+ }
1101
+ },
1102
+ superTypes: []
1103
+ },
1104
+ SwimlaneContent: {
1105
+ name: SwimlaneContent.$type,
1106
+ properties: {
1107
+ },
1108
+ superTypes: []
1109
+ },
1110
+ SwimlaneDeclaration: {
1111
+ name: SwimlaneDeclaration.$type,
1112
+ properties: {
1113
+ content: {
1114
+ name: SwimlaneDeclaration.content,
1115
+ defaultValue: []
1116
+ },
1117
+ name: {
1118
+ name: SwimlaneDeclaration.name
1119
+ },
1120
+ properties: {
1121
+ name: SwimlaneDeclaration.properties,
1122
+ defaultValue: []
1123
+ },
1124
+ title: {
1125
+ name: SwimlaneDeclaration.title
1126
+ }
1127
+ },
1128
+ superTypes: [RoadmapEntry.$type]
1129
+ },
1130
+ SymbolDeclaration: {
1131
+ name: SymbolDeclaration.$type,
1132
+ properties: {
1133
+ description: {
1134
+ name: SymbolDeclaration.description
1135
+ },
1136
+ name: {
1137
+ name: SymbolDeclaration.name
1138
+ },
1139
+ properties: {
1140
+ name: SymbolDeclaration.properties,
1141
+ defaultValue: []
1142
+ },
1143
+ title: {
1144
+ name: SymbolDeclaration.title
1145
+ }
1146
+ },
1147
+ superTypes: [ConfigEntry.$type]
1148
+ },
1149
+ TeamContent: {
1150
+ name: TeamContent.$type,
1151
+ properties: {
1152
+ },
1153
+ superTypes: []
1154
+ },
1155
+ TeamDeclaration: {
1156
+ name: TeamDeclaration.$type,
1157
+ properties: {
1158
+ content: {
1159
+ name: TeamDeclaration.content,
1160
+ defaultValue: []
1161
+ },
1162
+ name: {
1163
+ name: TeamDeclaration.name
1164
+ },
1165
+ properties: {
1166
+ name: TeamDeclaration.properties,
1167
+ defaultValue: []
1168
+ },
1169
+ title: {
1170
+ name: TeamDeclaration.title
1171
+ }
1172
+ },
1173
+ superTypes: [RoadmapEntry.$type, TeamContent.$type]
1174
+ }
1175
+ } as const satisfies langium.AstMetaData
1176
+ }
1177
+
1178
+ export const reflection = new NowlineAstReflection();