@glossarist/concept-browser 0.7.20 → 0.7.22

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": "@glossarist/concept-browser",
3
- "version": "0.7.20",
3
+ "version": "0.7.22",
4
4
  "description": "Vue SPA for browsing Glossarist terminology datasets with cross-reference resolution, graph visualization, and multi-language support",
5
5
  "type": "module",
6
6
  "bin": {
@@ -25,7 +25,7 @@
25
25
  "autoprefixer": "^10.4.21",
26
26
  "d3": "^7.9.0",
27
27
  "favicons": "^7.2.0",
28
- "glossarist": "^0.3.0",
28
+ "glossarist": "^0.3.3",
29
29
  "js-yaml": "^4.1.0",
30
30
  "pinia": "^2.3.1",
31
31
  "postcss": "^8.5.3",
@@ -8,7 +8,7 @@ describe('OntologyRegistry', () => {
8
8
  expect(ontology.getAll('normativeStatus').length).toBe(4);
9
9
  expect(ontology.getAll('sourceType').length).toBe(2);
10
10
  expect(ontology.getAll('sourceStatus').length).toBe(10);
11
- expect(ontology.getAll('relationshipType').length).toBe(14);
11
+ expect(ontology.getAll('relationshipType').length).toBe(51);
12
12
  expect(ontology.getAll('designationType').length).toBe(5);
13
13
  expect(ontology.getAll('termType').length).toBe(24);
14
14
  expect(ontology.getAll('grammarGender').length).toBe(4);
@@ -100,9 +100,9 @@ describe('OntologyRegistry', () => {
100
100
  expect(types).toContain('false_friend');
101
101
  expect(types).toContain('abbreviated_form_for');
102
102
  expect(types).toContain('short_form_for');
103
- expect(types).toContain('sequentially_related');
104
- expect(types).toContain('spatially_related');
105
- expect(types).toContain('temporally_related');
103
+ expect(types).toContain('sequentially_related_concept');
104
+ expect(types).toContain('spatially_related_concept');
105
+ expect(types).toContain('temporally_related_concept');
106
106
  expect(types).toContain('related_concept_broader');
107
107
  expect(types).toContain('related_concept_narrower');
108
108
  });
@@ -52,11 +52,11 @@ describe('categorizeRelationship', () => {
52
52
 
53
53
  describe('relationshipLabel', () => {
54
54
  it('formats snake_case as title case', () => {
55
- expect(relationshipLabel('broader_generic')).toBe('Broader Generic');
56
- expect(relationshipLabel('related_concept')).toBe('Related Concept');
55
+ expect(relationshipLabel('broader_generic')).toBe('broader (generic)');
56
+ expect(relationshipLabel('related_concept')).toBe('related concept');
57
57
  });
58
58
 
59
59
  it('handles single word', () => {
60
- expect(relationshipLabel('broader')).toBe('Broader');
60
+ expect(relationshipLabel('broader')).toBe('broader');
61
61
  });
62
62
  });
@@ -243,24 +243,6 @@
243
243
  "prefLabel": "related concept (narrower)",
244
244
  "definition": "Associative relationship to a concept with narrower scope (ISO 25964 / TBX)."
245
245
  },
246
- "sequentially_related": {
247
- "id": "sequentially_related",
248
- "iri": "gloss:rel/sequentially_related",
249
- "prefLabel": "sequentially related",
250
- "definition": "Sequential spatiotemporal relationship (ISO 25964 / TBX)."
251
- },
252
- "spatially_related": {
253
- "id": "spatially_related",
254
- "iri": "gloss:rel/spatially_related",
255
- "prefLabel": "spatially related",
256
- "definition": "Spatial relationship (ISO 25964 / TBX)."
257
- },
258
- "temporally_related": {
259
- "id": "temporally_related",
260
- "iri": "gloss:rel/temporally_related",
261
- "prefLabel": "temporally related",
262
- "definition": "Temporal relationship (ISO 25964 / TBX)."
263
- },
264
246
  "homograph": {
265
247
  "id": "homograph",
266
248
  "iri": "gloss:rel/homograph",
@@ -284,6 +266,246 @@
284
266
  "iri": "gloss:rel/short_form_for",
285
267
  "prefLabel": "short form for",
286
268
  "definition": "This designation is a short form of another designation."
269
+ },
270
+ "deprecated_by": {
271
+ "id": "deprecated_by",
272
+ "iri": "https://glossarist.org/ontologies/relationship-type#deprecated_by",
273
+ "prefLabel": "deprecated by",
274
+ "definition": "This concept has been deprecated by another concept (ISO 10241-1)."
275
+ },
276
+ "replaces": {
277
+ "id": "replaces",
278
+ "iri": "https://glossarist.org/ontologies/relationship-type#replaces",
279
+ "prefLabel": "replaces",
280
+ "definition": "This concept replaces another concept (ISO 10241-1)."
281
+ },
282
+ "replaced_by": {
283
+ "id": "replaced_by",
284
+ "iri": "https://glossarist.org/ontologies/relationship-type#replaced_by",
285
+ "prefLabel": "replaced by",
286
+ "definition": "This concept has been replaced by another concept (ISO 10241-1)."
287
+ },
288
+ "invalidates": {
289
+ "id": "invalidates",
290
+ "iri": "https://glossarist.org/ontologies/relationship-type#invalidates",
291
+ "prefLabel": "invalidates",
292
+ "definition": "This concept invalidates another concept, indicating it contains a substantial error and should not be used (ISO 19135)."
293
+ },
294
+ "invalidated_by": {
295
+ "id": "invalidated_by",
296
+ "iri": "https://glossarist.org/ontologies/relationship-type#invalidated_by",
297
+ "prefLabel": "invalidated by",
298
+ "definition": "This concept has been invalidated by another concept due to a substantial error (ISO 19135)."
299
+ },
300
+ "retires": {
301
+ "id": "retires",
302
+ "iri": "https://glossarist.org/ontologies/relationship-type#retires",
303
+ "prefLabel": "retires",
304
+ "definition": "This concept retires another concept, indicating it is no longer recommended for use (ISO 19135)."
305
+ },
306
+ "retired_by": {
307
+ "id": "retired_by",
308
+ "iri": "https://glossarist.org/ontologies/relationship-type#retired_by",
309
+ "prefLabel": "retired by",
310
+ "definition": "This concept has been retired by another concept (ISO 19135)."
311
+ },
312
+ "has_concept": {
313
+ "id": "has_concept",
314
+ "iri": "https://glossarist.org/ontologies/relationship-type#has_concept",
315
+ "prefLabel": "has concept",
316
+ "definition": "This concept has the nominated concept as a specialisation of its definition (ISO 19135)."
317
+ },
318
+ "is_concept_of": {
319
+ "id": "is_concept_of",
320
+ "iri": "https://glossarist.org/ontologies/relationship-type#is_concept_of",
321
+ "prefLabel": "is concept of",
322
+ "definition": "This concept is a specialisation of the source concept (ISO 19135)."
323
+ },
324
+ "instance_of": {
325
+ "id": "instance_of",
326
+ "iri": "https://glossarist.org/ontologies/relationship-type#instance_of",
327
+ "prefLabel": "instance of",
328
+ "definition": "This concept is an instance of the nominated concept (ISO 19135)."
329
+ },
330
+ "has_instance": {
331
+ "id": "has_instance",
332
+ "iri": "https://glossarist.org/ontologies/relationship-type#has_instance",
333
+ "prefLabel": "has instance",
334
+ "definition": "This concept has the nominated concept as an instance (ISO 19135)."
335
+ },
336
+ "has_definition": {
337
+ "id": "has_definition",
338
+ "iri": "https://glossarist.org/ontologies/relationship-type#has_definition",
339
+ "prefLabel": "has definition",
340
+ "definition": "This concept has the nominated concept as its definition (ISO 19135)."
341
+ },
342
+ "definition_of": {
343
+ "id": "definition_of",
344
+ "iri": "https://glossarist.org/ontologies/relationship-type#definition_of",
345
+ "prefLabel": "definition of",
346
+ "definition": "This concept is the definition of the source concept (ISO 19135)."
347
+ },
348
+ "has_part": {
349
+ "id": "has_part",
350
+ "iri": "https://glossarist.org/ontologies/relationship-type#has_part",
351
+ "prefLabel": "has part",
352
+ "definition": "This concept has the nominated concept as a part of its composition (ISO 19135)."
353
+ },
354
+ "is_part_of": {
355
+ "id": "is_part_of",
356
+ "iri": "https://glossarist.org/ontologies/relationship-type#is_part_of",
357
+ "prefLabel": "is part of",
358
+ "definition": "This concept is a part of the source concept (ISO 19135)."
359
+ },
360
+ "inherits": {
361
+ "id": "inherits",
362
+ "iri": "https://glossarist.org/ontologies/relationship-type#inherits",
363
+ "prefLabel": "inherits",
364
+ "definition": "This concept inherits and extends properties from the nominated concept (ISO 19135)."
365
+ },
366
+ "inherited_by": {
367
+ "id": "inherited_by",
368
+ "iri": "https://glossarist.org/ontologies/relationship-type#inherited_by",
369
+ "prefLabel": "inherited by",
370
+ "definition": "This concept is inherited by the source concept (ISO 19135)."
371
+ },
372
+ "has_version": {
373
+ "id": "has_version",
374
+ "iri": "https://glossarist.org/ontologies/relationship-type#has_version",
375
+ "prefLabel": "has version",
376
+ "definition": "This concept has the nominated concept as a version (ISO 19135)."
377
+ },
378
+ "version_of": {
379
+ "id": "version_of",
380
+ "iri": "https://glossarist.org/ontologies/relationship-type#version_of",
381
+ "prefLabel": "version of",
382
+ "definition": "This concept is a version of the source concept (ISO 19135)."
383
+ },
384
+ "current_version": {
385
+ "id": "current_version",
386
+ "iri": "https://glossarist.org/ontologies/relationship-type#current_version",
387
+ "prefLabel": "current version",
388
+ "definition": "This concept has the nominated concept as its current version (ISO 19135)."
389
+ },
390
+ "current_version_of": {
391
+ "id": "current_version_of",
392
+ "iri": "https://glossarist.org/ontologies/relationship-type#current_version_of",
393
+ "prefLabel": "current version of",
394
+ "definition": "This concept is the current version of the source concept (ISO 19135)."
395
+ },
396
+ "broader": {
397
+ "id": "broader",
398
+ "iri": "https://glossarist.org/ontologies/relationship-type#broader",
399
+ "prefLabel": "broader",
400
+ "definition": "This concept has a broader (more general) scope (SKOS)."
401
+ },
402
+ "narrower": {
403
+ "id": "narrower",
404
+ "iri": "https://glossarist.org/ontologies/relationship-type#narrower",
405
+ "prefLabel": "narrower",
406
+ "definition": "This concept has a narrower (more specific) scope (SKOS)."
407
+ },
408
+ "broader_generic": {
409
+ "id": "broader_generic",
410
+ "iri": "https://glossarist.org/ontologies/relationship-type#broader_generic",
411
+ "prefLabel": "broader (generic)",
412
+ "definition": "Generic (is-a) broader relationship (ISO 25964)."
413
+ },
414
+ "narrower_generic": {
415
+ "id": "narrower_generic",
416
+ "iri": "https://glossarist.org/ontologies/relationship-type#narrower_generic",
417
+ "prefLabel": "narrower (generic)",
418
+ "definition": "Generic (is-a) narrower relationship (ISO 25964)."
419
+ },
420
+ "broader_partitive": {
421
+ "id": "broader_partitive",
422
+ "iri": "https://glossarist.org/ontologies/relationship-type#broader_partitive",
423
+ "prefLabel": "broader (partitive)",
424
+ "definition": "Partitive (whole-of) broader relationship (ISO 25964)."
425
+ },
426
+ "narrower_partitive": {
427
+ "id": "narrower_partitive",
428
+ "iri": "https://glossarist.org/ontologies/relationship-type#narrower_partitive",
429
+ "prefLabel": "narrower (partitive)",
430
+ "definition": "Partitive (part-of) narrower relationship (ISO 25964)."
431
+ },
432
+ "broader_instantial": {
433
+ "id": "broader_instantial",
434
+ "iri": "https://glossarist.org/ontologies/relationship-type#broader_instantial",
435
+ "prefLabel": "broader (instantial)",
436
+ "definition": "Instantial broader relationship (ISO 25964)."
437
+ },
438
+ "narrower_instantial": {
439
+ "id": "narrower_instantial",
440
+ "iri": "https://glossarist.org/ontologies/relationship-type#narrower_instantial",
441
+ "prefLabel": "narrower (instantial)",
442
+ "definition": "Instantial narrower relationship (ISO 25964)."
443
+ },
444
+ "equivalent": {
445
+ "id": "equivalent",
446
+ "iri": "https://glossarist.org/ontologies/relationship-type#equivalent",
447
+ "prefLabel": "equivalent",
448
+ "definition": "This concept is equivalent to another concept (SKOS)."
449
+ },
450
+ "close_match": {
451
+ "id": "close_match",
452
+ "iri": "https://glossarist.org/ontologies/relationship-type#close_match",
453
+ "prefLabel": "close match",
454
+ "definition": "This concept is a close match to another concept (SKOS)."
455
+ },
456
+ "broad_match": {
457
+ "id": "broad_match",
458
+ "iri": "https://glossarist.org/ontologies/relationship-type#broad_match",
459
+ "prefLabel": "broad match",
460
+ "definition": "This concept has a broader match to another concept (SKOS)."
461
+ },
462
+ "narrow_match": {
463
+ "id": "narrow_match",
464
+ "iri": "https://glossarist.org/ontologies/relationship-type#narrow_match",
465
+ "prefLabel": "narrow match",
466
+ "definition": "This concept has a narrower match to another concept (SKOS)."
467
+ },
468
+ "related_match": {
469
+ "id": "related_match",
470
+ "iri": "https://glossarist.org/ontologies/relationship-type#related_match",
471
+ "prefLabel": "related match",
472
+ "definition": "This concept has a related match to another concept (SKOS)."
473
+ },
474
+ "see": {
475
+ "id": "see",
476
+ "iri": "https://glossarist.org/ontologies/relationship-type#see",
477
+ "prefLabel": "see",
478
+ "definition": "Reference to another concept (ISO 10241-1)."
479
+ },
480
+ "related_concept": {
481
+ "id": "related_concept",
482
+ "iri": "https://glossarist.org/ontologies/relationship-type#related_concept",
483
+ "prefLabel": "related concept",
484
+ "definition": "Associative relationship to another concept (ISO 25964)."
485
+ },
486
+ "references": {
487
+ "id": "references",
488
+ "iri": "https://glossarist.org/ontologies/relationship-type#references",
489
+ "prefLabel": "references",
490
+ "definition": "This concept references another concept."
491
+ },
492
+ "sequentially_related_concept": {
493
+ "id": "sequentially_related_concept",
494
+ "iri": "gloss:rel/sequentially_related",
495
+ "prefLabel": "sequentially related",
496
+ "definition": "Sequential spatiotemporal relationship (ISO 25964 / TBX)."
497
+ },
498
+ "spatially_related_concept": {
499
+ "id": "spatially_related_concept",
500
+ "iri": "gloss:rel/spatially_related",
501
+ "prefLabel": "spatially related",
502
+ "definition": "Spatial relationship (ISO 25964 / TBX)."
503
+ },
504
+ "temporally_related_concept": {
505
+ "id": "temporally_related_concept",
506
+ "iri": "gloss:rel/temporally_related",
507
+ "prefLabel": "temporally related",
508
+ "definition": "Temporal relationship (ISO 25964 / TBX)."
287
509
  }
288
510
  }
289
511
  },
@@ -53,7 +53,7 @@ export const RELATIONSHIP_CATEGORIES: RelationshipCategory[] = [
53
53
  {
54
54
  id: 'spatiotemporal',
55
55
  label: 'Spatiotemporal',
56
- types: ['sequentially_related', 'spatially_related', 'temporally_related'],
56
+ types: ['sequentially_related_concept', 'spatially_related_concept', 'temporally_related_concept'],
57
57
  color: 'text-teal-600 bg-teal-50',
58
58
  },
59
59
  {
@@ -73,7 +73,7 @@ export const RELATIONSHIP_CATEGORIES: RelationshipCategory[] = [
73
73
 
74
74
 
75
75
  export const INVERSE_RELATIONSHIPS: Record<string, string> = {
76
- // Lifecycle
76
+ // Lifecycle (ISO 10241-1)
77
77
  supersedes: 'superseded_by',
78
78
  superseded_by: 'supersedes',
79
79
  deprecates: 'deprecated_by',
@@ -81,34 +81,41 @@ export const INVERSE_RELATIONSHIPS: Record<string, string> = {
81
81
  replaces: 'replaced_by',
82
82
  replaced_by: 'replaces',
83
83
  invalidates: 'invalidated_by',
84
+ invalidated_by: 'invalidates',
84
85
  retires: 'retired_by',
86
+ retired_by: 'retires',
85
87
 
86
- // Hierarchical (generic)
88
+ // Hierarchical (generic — SKOS)
87
89
  broader: 'narrower',
88
90
  narrower: 'broader',
89
91
  broader_generic: 'narrower_generic',
90
92
  narrower_generic: 'broader_generic',
91
93
 
92
- // Hierarchical (partitive)
94
+ // Hierarchical (partitive — ISO 25964)
93
95
  broader_partitive: 'narrower_partitive',
94
96
  narrower_partitive: 'broader_partitive',
95
97
  has_part: 'is_part_of',
96
98
  is_part_of: 'has_part',
97
99
 
98
- // Hierarchical (instantial)
100
+ // Hierarchical (instantial — ISO 25964)
99
101
  broader_instantial: 'narrower_instantial',
100
102
  narrower_instantial: 'broader_instantial',
101
103
  instance_of: 'has_instance',
102
104
  has_instance: 'instance_of',
103
105
 
104
- // ISO 19135 register relations
106
+ // ISO 19135 concept-to-concept
105
107
  has_concept: 'is_concept_of',
106
108
  is_concept_of: 'has_concept',
107
109
  inherits: 'inherited_by',
108
110
  inherited_by: 'inherits',
109
111
  has_definition: 'definition_of',
112
+ definition_of: 'has_definition',
113
+
114
+ // ISO 19135 versioning
110
115
  has_version: 'version_of',
116
+ version_of: 'has_version',
111
117
  current_version: 'current_version_of',
118
+ current_version_of: 'current_version',
112
119
 
113
120
  // Symmetric (self-inverse)
114
121
  equivalent: 'equivalent',
@@ -116,6 +123,7 @@ export const INVERSE_RELATIONSHIPS: Record<string, string> = {
116
123
  contrast: 'contrast',
117
124
  close_match: 'close_match',
118
125
  related_match: 'related_match',
126
+ related_concept: 'related_concept',
119
127
  };
120
128
  const CATEGORY_MAP = new Map<string, RelationshipCategory>();
121
129
  for (const cat of RELATIONSHIP_CATEGORIES) {