@contractspec/example.learning-journey-registry 1.46.1 → 1.47.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.
@@ -3,13 +3,13 @@
3
3
  *
4
4
  * Defines the feature module for the learning journey registry.
5
5
  */
6
- import type { FeatureModuleSpec } from '@contractspec/lib.contracts';
6
+ import { defineFeature } from '@contractspec/lib.contracts';
7
7
 
8
8
  /**
9
9
  * Learning Journey Registry feature module that bundles
10
10
  * the shared presentations for learning journey tracks.
11
11
  */
12
- export const LearningJourneyRegistryFeature: FeatureModuleSpec = {
12
+ export const LearningJourneyRegistryFeature = defineFeature({
13
13
  meta: {
14
14
  key: 'learning-journey-registry',
15
15
  version: '1.0.0',
@@ -61,4 +61,4 @@ export const LearningJourneyRegistryFeature: FeatureModuleSpec = {
61
61
  capabilities: {
62
62
  requires: [{ key: 'identity', version: '1.0.0' }],
63
63
  },
64
- };
64
+ });
@@ -1,8 +1,4 @@
1
- import type {
2
- PresentationSpecMeta,
3
- PresentationSpec,
4
- } from '@contractspec/lib.contracts';
5
- import { StabilityEnum } from '@contractspec/lib.contracts';
1
+ import { definePresentation, StabilityEnum, type PresentationSpecMeta } from '@contractspec/lib.contracts';
6
2
 
7
3
  const baseMeta: Pick<
8
4
  PresentationSpecMeta,
@@ -17,7 +13,7 @@ const baseMeta: Pick<
17
13
  context: 'Learning journey section',
18
14
  };
19
15
 
20
- export const LearningTrackListPresentation: PresentationSpec = {
16
+ export const LearningTrackListPresentation = definePresentation({
21
17
  meta: {
22
18
  key: 'learning.journey.track_list',
23
19
  version: '1.0.0',
@@ -30,9 +26,9 @@ export const LearningTrackListPresentation: PresentationSpec = {
30
26
  componentKey: 'LearningTrackList',
31
27
  },
32
28
  targets: ['react', 'markdown'],
33
- };
29
+ });
34
30
 
35
- export const LearningTrackDetailPresentation: PresentationSpec = {
31
+ export const LearningTrackDetailPresentation = definePresentation({
36
32
  meta: {
37
33
  key: 'learning.journey.track_detail',
38
34
  version: '1.0.0',
@@ -45,9 +41,9 @@ export const LearningTrackDetailPresentation: PresentationSpec = {
45
41
  componentKey: 'LearningTrackDetail',
46
42
  },
47
43
  targets: ['react', 'markdown', 'application/json'],
48
- };
44
+ });
49
45
 
50
- export const LearningTrackProgressWidgetPresentation: PresentationSpec = {
46
+ export const LearningTrackProgressWidgetPresentation = definePresentation({
51
47
  meta: {
52
48
  key: 'learning.journey.progress_widget',
53
49
  version: '1.0.0',
@@ -60,7 +56,7 @@ export const LearningTrackProgressWidgetPresentation: PresentationSpec = {
60
56
  componentKey: 'LearningTrackProgressWidget',
61
57
  },
62
58
  targets: ['react'],
63
- };
59
+ });
64
60
 
65
61
  export const learningJourneyPresentations = [
66
62
  LearningTrackListPresentation,