@codecademy/brand 2.0.0-alpha.ec446648d8.0 → 2.0.0-alpha.fd9088f77a.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 (103) hide show
  1. package/README.md +1 -1
  2. package/dist/AppBar/AppBarSection.d.ts +1 -1
  3. package/dist/AppHeader/AppHeaderElements/AppHeaderCatalogSection/elements.d.ts +14 -14
  4. package/dist/AppHeader/AppHeaderElements/AppHeaderLink/index.d.ts +5 -5
  5. package/dist/AppHeader/AppHeaderElements/AppHeaderListItem/index.d.ts +1 -1
  6. package/dist/AppHeader/AppHeaderElements/AppHeaderLogo/index.js +9 -9
  7. package/dist/AppHeader/Search/consts.js +1 -1
  8. package/dist/AppHeader/shared/elements.d.ts +9 -9
  9. package/dist/Carousel/elements.d.ts +2 -2
  10. package/dist/DropdownButton/index.d.ts +2 -2
  11. package/dist/GlobalFooter/FooterHeading.d.ts +2 -2
  12. package/dist/GlobalFooter/FooterLinks.d.ts +1 -1
  13. package/dist/GlobalFooter/FooterSubHeading.d.ts +2 -2
  14. package/dist/LayoutMenu/LayoutMenu.js +4 -3
  15. package/dist/LayoutMenuVariant/LayoutMenu.js +4 -3
  16. package/dist/LearningOutcomeBadges/LearningOutcomeLowAssessmentBadge.d.ts +1 -1
  17. package/dist/LearningOutcomeCard/index.d.ts +12 -9
  18. package/dist/LearningOutcomeCard/index.js +143 -165
  19. package/dist/LearningOutcomeTile/Tile.d.ts +1 -1
  20. package/dist/LearningOutcomeTile/index.d.ts +1 -2
  21. package/dist/LearningOutcomeTile/index.js +4 -2
  22. package/dist/LearningOutcomeTile/types.d.ts +1 -0
  23. package/dist/Logos/LogoCodecademy/index.d.ts +2 -0
  24. package/dist/{Logo/CodecademyProMonoLogo.js → Logos/LogoCodecademy/index.js} +15 -15
  25. package/dist/Logos/LogoCodecademyMini/index.d.ts +2 -0
  26. package/dist/Logos/LogoCodecademyMini/index.js +18 -0
  27. package/dist/Logos/LogoCodecademyPro/index.d.ts +2 -0
  28. package/dist/{Logo/CodecademyProLogo.js → Logos/LogoCodecademyPro/index.js} +11 -7
  29. package/dist/Logos/LogoCodecademyTeams/index.d.ts +2 -0
  30. package/dist/{Logo/CodecademyTeamsLogo.js → Logos/LogoCodecademyTeams/index.js} +9 -4
  31. package/dist/Logos/LogoFromSkillsoft/index.d.ts +3 -0
  32. package/dist/Logos/LogoFromSkillsoft/index.js +47 -0
  33. package/dist/Logos/LogoLXStudio/index.d.ts +3 -0
  34. package/dist/Logos/LogoLXStudio/index.js +40 -0
  35. package/dist/{LogoProCutout → Logos/ProLabel/ProLabelCutout}/index.d.ts +2 -2
  36. package/dist/{LogoProCutout → Logos/ProLabel/ProLabelCutout}/index.js +1 -1
  37. package/dist/Logos/ProLabel/ProLabelCutoutTransparent/index.d.ts +7 -0
  38. package/dist/{LogoProCutoutTransparent → Logos/ProLabel/ProLabelCutoutTransparent}/index.js +1 -1
  39. package/dist/{ProLogo → Logos/ProLabel}/index.d.ts +2 -2
  40. package/dist/{ProLogo → Logos/ProLabel}/index.js +5 -5
  41. package/dist/Logos/index.d.ts +7 -0
  42. package/dist/Logos/index.js +7 -0
  43. package/dist/Logos/shared.d.ts +636 -0
  44. package/dist/Logos/shared.js +16 -0
  45. package/dist/Notifications/elements.d.ts +2 -2
  46. package/dist/PlanCard/index.js +66 -28
  47. package/dist/Testimonial/index.d.ts +1 -1
  48. package/dist/index.d.ts +1 -7
  49. package/dist/index.js +1 -7
  50. package/dist/stories/Atoms/Logos/LogoCodecademy.stories.d.ts +6 -0
  51. package/dist/stories/Atoms/Logos/LogoCodecademy.stories.js +8 -0
  52. package/dist/stories/Atoms/Logos/LogoCodecademyMini.stories.d.ts +6 -0
  53. package/dist/stories/Atoms/Logos/LogoCodecademyMini.stories.js +8 -0
  54. package/dist/stories/Atoms/Logos/LogoCodecademyPro.stories.d.ts +6 -0
  55. package/dist/stories/Atoms/Logos/LogoCodecademyPro.stories.js +8 -0
  56. package/dist/stories/Atoms/Logos/LogoCodecademyTeams.stories.d.ts +6 -0
  57. package/dist/stories/Atoms/Logos/LogoCodecademyTeams.stories.js +8 -0
  58. package/dist/stories/Atoms/Logos/LogoFromSkillsoft.stories.d.ts +1 -1
  59. package/dist/stories/Atoms/Logos/LogoFromSkillsoft.stories.js +2 -8
  60. package/dist/stories/Atoms/Logos/LogoLXStudio.stories.d.ts +1 -1
  61. package/dist/stories/Atoms/Logos/LogoLXStudio.stories.js +1 -1
  62. package/dist/stories/Atoms/Logos/ProLabel.stories.d.ts +3 -1
  63. package/dist/stories/Atoms/Logos/ProLabel.stories.js +23 -10
  64. package/dist/stories/Molecules/AppBar.stories.js +2 -2
  65. package/dist/stories/Molecules/LearningOutcomeCard.stories.d.ts +2 -7
  66. package/dist/stories/Molecules/LearningOutcomeCard.stories.js +54 -168
  67. package/package.json +1 -1
  68. package/dist/LearningOutcomeAssessmentScores/AssessmentDetail.d.ts +0 -8
  69. package/dist/LearningOutcomeAssessmentScores/AssessmentDetail.js +0 -55
  70. package/dist/LearningOutcomeAssessmentScores/index.d.ts +0 -8
  71. package/dist/LearningOutcomeAssessmentScores/index.js +0 -24
  72. package/dist/LearningOutcomeFlyout/index.d.ts +0 -29
  73. package/dist/LearningOutcomeFlyout/index.js +0 -153
  74. package/dist/Logo/CodecademyLogo.d.ts +0 -2
  75. package/dist/Logo/CodecademyLogo.js +0 -19
  76. package/dist/Logo/CodecademyPremiumLogo.d.ts +0 -2
  77. package/dist/Logo/CodecademyPremiumLogo.js +0 -35
  78. package/dist/Logo/CodecademyProAltLogo.d.ts +0 -2
  79. package/dist/Logo/CodecademyProAltLogo.js +0 -19
  80. package/dist/Logo/CodecademyProLockupLogo.d.ts +0 -2
  81. package/dist/Logo/CodecademyProLockupLogo.js +0 -13
  82. package/dist/Logo/CodecademyProLogo.d.ts +0 -2
  83. package/dist/Logo/CodecademyProMonoLogo.d.ts +0 -2
  84. package/dist/Logo/CodecademyProgramLogo.d.ts +0 -2
  85. package/dist/Logo/CodecademyProgramLogo.js +0 -14
  86. package/dist/Logo/CodecademyTeamsLogo.d.ts +0 -2
  87. package/dist/Logo/index.d.ts +0 -8
  88. package/dist/Logo/index.js +0 -30
  89. package/dist/LogoFromSkillsoft/index.d.ts +0 -227
  90. package/dist/LogoFromSkillsoft/index.js +0 -55
  91. package/dist/LogoLXStudio/index.d.ts +0 -3
  92. package/dist/LogoLXStudio/index.js +0 -47
  93. package/dist/LogoProCutoutTransparent/index.d.ts +0 -7
  94. package/dist/ProLabel/index.d.ts +0 -376
  95. package/dist/ProLabel/index.js +0 -59
  96. package/dist/stories/Atoms/Logos/Logo.stories.d.ts +0 -13
  97. package/dist/stories/Atoms/Logos/Logo.stories.js +0 -78
  98. package/dist/stories/Atoms/Logos/ProLogoAlt.stories.d.ts +0 -6
  99. package/dist/stories/Atoms/Logos/ProLogoAlt.stories.js +0 -24
  100. package/dist/stories/Molecules/LearningOutcomeAssessmentScores.stories.d.ts +0 -6
  101. package/dist/stories/Molecules/LearningOutcomeAssessmentScores.stories.js +0 -23
  102. package/dist/stories/Molecules/LearningOutcomeFlyout.stories.d.ts +0 -5
  103. package/dist/stories/Molecules/LearningOutcomeFlyout.stories.js +0 -34
package/dist/index.d.ts CHANGED
@@ -45,18 +45,14 @@ export * from './InfoCard';
45
45
  export * from './Konamimojisplosion';
46
46
  export * from './LandingPage';
47
47
  export * from './LayoutMenu';
48
- export * from './LearningOutcomeAssessmentScores';
49
48
  export * from './LearningOutcomeBadges';
50
49
  export * from './LearningOutcomeCard';
51
- export * from './LearningOutcomeFlyout';
52
50
  export * from './LearningOutcomeTile';
53
51
  export * from './lib/breakpointHooks';
54
52
  export * from './ListSection';
55
53
  export * from './Loading';
56
54
  export * from './LoadingCurriculumCard';
57
- export * from './Logo';
58
- export * from './LogoFromSkillsoft';
59
- export * from './LogoLXStudio';
55
+ export * from './Logos';
60
56
  export * from './MarketingToaster';
61
57
  export * from './NotificationList';
62
58
  export * from './NotificationList/NotificationItem';
@@ -72,8 +68,6 @@ export * from './PlanCard/PlanCardBanner';
72
68
  export * from './PlanCard/types';
73
69
  export * from './PricingSection';
74
70
  export * from './ProductFeatureShowcase';
75
- export * from './ProLabel';
76
- export * from './ProLogo';
77
71
  export * from './ProLogoAlt';
78
72
  export * from './RatingsBar';
79
73
  export * from './ResourceCard';
package/dist/index.js CHANGED
@@ -45,18 +45,14 @@ export * from './InfoCard';
45
45
  export * from './Konamimojisplosion';
46
46
  export * from './LandingPage';
47
47
  export * from './LayoutMenu';
48
- export * from './LearningOutcomeAssessmentScores';
49
48
  export * from './LearningOutcomeBadges';
50
49
  export * from './LearningOutcomeCard';
51
- export * from './LearningOutcomeFlyout';
52
50
  export * from './LearningOutcomeTile';
53
51
  export * from './lib/breakpointHooks';
54
52
  export * from './ListSection';
55
53
  export * from './Loading';
56
54
  export * from './LoadingCurriculumCard';
57
- export * from './Logo';
58
- export * from './LogoFromSkillsoft';
59
- export * from './LogoLXStudio';
55
+ export * from './Logos';
60
56
  export * from './MarketingToaster';
61
57
  export * from './NotificationList';
62
58
  export * from './NotificationList/NotificationItem';
@@ -72,8 +68,6 @@ export * from './PlanCard/PlanCardBanner';
72
68
  export * from './PlanCard/types';
73
69
  export * from './PricingSection';
74
70
  export * from './ProductFeatureShowcase';
75
- export * from './ProLabel';
76
- export * from './ProLogo';
77
71
  export * from './ProLogoAlt';
78
72
  export * from './RatingsBar';
79
73
  export * from './ResourceCard';
@@ -0,0 +1,6 @@
1
+ import type { Meta, StoryObj } from '@storybook/react';
2
+ import { LogoCodecademy } from '../../../Logos';
3
+ declare const meta: Meta<typeof LogoCodecademy>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof LogoCodecademy>;
6
+ export declare const Default: Story;
@@ -0,0 +1,8 @@
1
+ import { LogoCodecademy } from '../../../Logos';
2
+ const meta = {
3
+ component: LogoCodecademy
4
+ };
5
+ export default meta;
6
+ export const Default = {
7
+ args: {}
8
+ };
@@ -0,0 +1,6 @@
1
+ import type { Meta, StoryObj } from '@storybook/react';
2
+ import { LogoCodecademyMini } from '../../../Logos';
3
+ declare const meta: Meta<typeof LogoCodecademyMini>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof LogoCodecademyMini>;
6
+ export declare const Default: Story;
@@ -0,0 +1,8 @@
1
+ import { LogoCodecademyMini } from '../../../Logos';
2
+ const meta = {
3
+ component: LogoCodecademyMini
4
+ };
5
+ export default meta;
6
+ export const Default = {
7
+ args: {}
8
+ };
@@ -0,0 +1,6 @@
1
+ import type { Meta, StoryObj } from '@storybook/react';
2
+ import { LogoCodecademyPro } from '../../../Logos';
3
+ declare const meta: Meta<typeof LogoCodecademyPro>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof LogoCodecademyPro>;
6
+ export declare const Default: Story;
@@ -0,0 +1,8 @@
1
+ import { LogoCodecademyPro } from '../../../Logos';
2
+ const meta = {
3
+ component: LogoCodecademyPro
4
+ };
5
+ export default meta;
6
+ export const Default = {
7
+ args: {}
8
+ };
@@ -0,0 +1,6 @@
1
+ import type { Meta, StoryObj } from '@storybook/react';
2
+ import { LogoCodecademyTeams } from '../../../Logos';
3
+ declare const meta: Meta<typeof LogoCodecademyTeams>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof LogoCodecademyTeams>;
6
+ export declare const Default: Story;
@@ -0,0 +1,8 @@
1
+ import { LogoCodecademyTeams } from '../../../Logos';
2
+ const meta = {
3
+ component: LogoCodecademyTeams
4
+ };
5
+ export default meta;
6
+ export const Default = {
7
+ args: {}
8
+ };
@@ -1,5 +1,5 @@
1
1
  import type { Meta, StoryObj } from '@storybook/react';
2
- import { LogoFromSkillsoft } from '../../../index';
2
+ import { LogoFromSkillsoft } from '../../../Logos';
3
3
  declare const meta: Meta<typeof LogoFromSkillsoft>;
4
4
  export default meta;
5
5
  type Story = StoryObj<typeof LogoFromSkillsoft>;
@@ -1,5 +1,4 @@
1
- import { LogoFromSkillsoft } from '../../../index';
2
- import { jsx as _jsx } from "react/jsx-runtime";
1
+ import { LogoFromSkillsoft } from '../../../Logos';
3
2
  const meta = {
4
3
  args: {
5
4
  height: 40
@@ -7,9 +6,4 @@ const meta = {
7
6
  component: LogoFromSkillsoft
8
7
  };
9
8
  export default meta;
10
- export const Default = {
11
- render: args => /*#__PURE__*/_jsx(LogoFromSkillsoft, {
12
- ...args
13
- }),
14
- name: 'LogoFromSkillsoft'
15
- };
9
+ export const Default = {};
@@ -1,5 +1,5 @@
1
1
  import type { Meta, StoryObj } from '@storybook/react';
2
- import { LogoLXStudio } from '../../../index';
2
+ import { LogoLXStudio } from '../../../Logos';
3
3
  declare const meta: Meta<typeof LogoLXStudio>;
4
4
  export default meta;
5
5
  type Story = StoryObj<typeof LogoLXStudio>;
@@ -1,4 +1,4 @@
1
- import { LogoLXStudio } from '../../../index';
1
+ import { LogoLXStudio } from '../../../Logos';
2
2
  const meta = {
3
3
  args: {
4
4
  height: 40
@@ -1,6 +1,8 @@
1
1
  import type { Meta, StoryObj } from '@storybook/react';
2
- import { ProLabel } from '../../../index';
2
+ import { ProLabel } from '../../../Logos/ProLabel';
3
3
  declare const meta: Meta<typeof ProLabel>;
4
4
  export default meta;
5
5
  type Story = StoryObj<typeof ProLabel>;
6
6
  export declare const Default: Story;
7
+ export declare const Cutout: Story;
8
+ export declare const Transparent: Story;
@@ -1,16 +1,29 @@
1
- import { ProLabel } from '../../../index';
1
+ import { Background } from '@codecademy/gamut-styles';
2
+ import { ProLabel } from '../../../Logos/ProLabel';
2
3
  import { jsx as _jsx } from "react/jsx-runtime";
3
4
  const meta = {
4
- component: ProLabel,
5
- args: {
6
- mode: 'light',
7
- height: 40
8
- }
5
+ component: ProLabel
9
6
  };
10
7
  export default meta;
11
8
  export const Default = {
12
- render: args => /*#__PURE__*/_jsx(ProLabel, {
13
- ...args
14
- }),
15
- name: 'ProLabel'
9
+ args: {
10
+ variant: 'cutout'
11
+ }
12
+ };
13
+ export const Cutout = {
14
+ args: {
15
+ variant: 'cutout'
16
+ }
17
+ };
18
+ export const Transparent = {
19
+ args: {
20
+ variant: 'transparent'
21
+ },
22
+ render: args => /*#__PURE__*/_jsx(Background, {
23
+ bg: "navy",
24
+ p: 8,
25
+ children: /*#__PURE__*/_jsx(ProLabel, {
26
+ ...args
27
+ })
28
+ })
16
29
  };
@@ -1,4 +1,4 @@
1
- import { AppBar, AppBarSection, Logo } from '../../index';
1
+ import { AppBar, AppBarSection, LogoCodecademy } from '../../index';
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  export default {
4
4
  component: AppBar,
@@ -19,7 +19,7 @@ export const Header = {
19
19
  render: () => /*#__PURE__*/_jsxs(AppBar, {
20
20
  children: [/*#__PURE__*/_jsx(AppBarSection, {
21
21
  position: "left",
22
- children: /*#__PURE__*/_jsx(Logo, {})
22
+ children: /*#__PURE__*/_jsx(LogoCodecademy, {})
23
23
  }), /*#__PURE__*/_jsx(AppBarSection, {
24
24
  position: "center",
25
25
  children: "Pricing"
@@ -3,13 +3,8 @@ import { LearningOutcomeCard } from '../../LearningOutcomeCard';
3
3
  declare const meta: Meta<typeof LearningOutcomeCard>;
4
4
  export default meta;
5
5
  type Story = StoryObj<typeof LearningOutcomeCard>;
6
- export declare const Base: Story;
7
- export declare const BaseCardWithHover: Story;
8
- export declare const BaseCardWithTopics: Story;
6
+ export declare const Default: Story;
9
7
  export declare const EmphasizedCard: Story;
10
- export declare const EmphasizedCardWithHover: Story;
11
- export declare const EmphasizedCardWithTopics: Story;
12
8
  export declare const EmphasizedCardWithProgress: Story;
13
9
  export declare const EmphasizedCardWithProgress100: Story;
14
- export declare const EmphasizedCardWithProgressAnimation: Story;
15
- export declare const EmphasizedCardWithProgress100Animation: Story;
10
+ export declare const EmphasizedCardWithAnimation: Story;
@@ -1,189 +1,75 @@
1
- import { FlexBox } from '@codecademy/gamut';
1
+ import { Background } from '@codecademy/gamut-styles';
2
2
  import { LearningOutcomeCard } from '../../LearningOutcomeCard';
3
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  const meta = {
5
5
  component: LearningOutcomeCard,
6
6
  args: {
7
- outcome: 'Implement sorting algorithms in Java.'
8
- }
9
- };
10
- export default meta;
11
- export const Base = {
12
- render: args => /*#__PURE__*/_jsxs(FlexBox, {
13
- gap: 16,
14
- children: [/*#__PURE__*/_jsx(LearningOutcomeCard, {
15
- ...args,
16
- level: 1
17
- }), /*#__PURE__*/_jsx(LearningOutcomeCard, {
18
- ...args,
19
- level: 2
20
- }), /*#__PURE__*/_jsx(LearningOutcomeCard, {
21
- ...args,
22
- level: 3
23
- })]
24
- }),
25
- name: 'Base card'
26
- };
27
- export const BaseCardWithHover = {
28
- render: args => /*#__PURE__*/_jsxs(FlexBox, {
29
- gap: 16,
30
- children: [/*#__PURE__*/_jsx(LearningOutcomeCard, {
31
- ...args,
32
- level: 1,
33
- isInteractive: true
34
- }), /*#__PURE__*/_jsx(LearningOutcomeCard, {
35
- ...args,
36
- level: 2,
37
- isInteractive: true
38
- }), /*#__PURE__*/_jsx(LearningOutcomeCard, {
39
- ...args,
40
- level: 3,
41
- isInteractive: true
42
- })]
43
- }),
44
- name: 'Base card with hover'
45
- };
46
- export const BaseCardWithTopics = {
47
- render: args => /*#__PURE__*/_jsxs(FlexBox, {
48
- gap: 16,
49
- children: [/*#__PURE__*/_jsx(LearningOutcomeCard, {
50
- ...args,
51
- level: 1,
52
- skills: [{
53
- title: 'java'
54
- }, {
55
- title: 'skill'
56
- }, {
57
- title: 'computer science'
58
- }]
59
- }), /*#__PURE__*/_jsx(LearningOutcomeCard, {
60
- ...args,
61
- level: 2,
62
- skills: [{
63
- title: 'java'
64
- }, {
65
- title: 'skill'
66
- }, {
67
- title: 'computer science'
68
- }]
69
- }), /*#__PURE__*/_jsx(LearningOutcomeCard, {
70
- ...args,
71
- level: 3,
72
- skills: [{
73
- title: 'java'
74
- }, {
75
- title: 'skill'
76
- }, {
77
- title: 'computer science'
78
- }]
79
- })]
80
- }),
81
- name: 'Base card with topics'
82
- };
83
- export const EmphasizedCard = {
84
- render: args => /*#__PURE__*/_jsx(LearningOutcomeCard, {
85
- ...args,
86
7
  level: 1,
87
- mode: "emphasized"
88
- }),
89
- name: 'Emphasized card'
90
- };
91
- export const EmphasizedCardWithHover = {
92
- render: args => /*#__PURE__*/_jsx(LearningOutcomeCard, {
93
- ...args,
94
- level: 2,
95
- mode: "emphasized",
96
- isInteractive: true
97
- }),
98
- name: 'Emphasized card with hover'
99
- };
100
- export const EmphasizedCardWithTopics = {
101
- render: args => /*#__PURE__*/_jsx(LearningOutcomeCard, {
102
- ...args,
103
- level: 3,
8
+ outcome: 'Implement sorting algorithms in Java.',
104
9
  skills: [{
105
10
  title: 'java'
106
11
  }, {
107
12
  title: 'skill'
108
13
  }, {
109
14
  title: 'computer science'
110
- }],
111
- mode: "emphasized",
112
- isInteractive: true
113
- }),
114
- name: 'Emphasized card with topics'
15
+ }]
16
+ }
115
17
  };
116
- export const EmphasizedCardWithProgress = {
18
+ export default meta;
19
+ export const Default = {
117
20
  render: args => /*#__PURE__*/_jsx(LearningOutcomeCard, {
118
- ...args,
119
- level: 2,
120
- progress: 60,
121
- skills: [{
122
- title: 'java'
123
- }, {
124
- title: 'skill'
125
- }, {
126
- title: 'computer science'
127
- }],
128
- mode: "emphasized",
129
- isInteractive: true
21
+ ...args
130
22
  }),
131
- name: 'Emphasized card with progress'
23
+ name: 'Learning Outcome Simple Card'
132
24
  };
133
- export const EmphasizedCardWithProgress100 = {
134
- render: args => /*#__PURE__*/_jsx(LearningOutcomeCard, {
135
- ...args,
136
- level: 3,
137
- progress: 100,
138
- skills: [{
139
- title: 'java'
140
- }, {
141
- title: 'skill'
142
- }, {
143
- title: 'computer science'
144
- }],
145
- mode: "emphasized",
146
- isInteractive: true
25
+ export const EmphasizedCard = {
26
+ render: args => /*#__PURE__*/_jsx(Background, {
27
+ bg: "navy",
28
+ p: 24,
29
+ children: /*#__PURE__*/_jsx(LearningOutcomeCard, {
30
+ emphasized: true,
31
+ ...args
32
+ })
147
33
  }),
148
- name: 'Emphasized card with 100% progress'
34
+ name: 'Emphasized Card'
149
35
  };
150
- export const EmphasizedCardWithProgressAnimation = {
151
- render: args => /*#__PURE__*/_jsx(LearningOutcomeCard, {
152
- ...args,
153
- level: 2,
154
- progress: 80,
155
- progressUpdateData: {
156
- previousProgress: 50,
157
- progressDuration: 500
158
- },
159
- skills: [{
160
- title: 'java'
161
- }, {
162
- title: 'skill'
163
- }, {
164
- title: 'computer science'
165
- }],
166
- mode: "emphasized"
36
+ export const EmphasizedCardWithProgress = {
37
+ render: args => /*#__PURE__*/_jsx(Background, {
38
+ bg: "navy",
39
+ p: 24,
40
+ children: /*#__PURE__*/_jsx(LearningOutcomeCard, {
41
+ emphasized: true,
42
+ progress: 60,
43
+ ...args
44
+ })
167
45
  }),
168
- name: 'Emphasized card with progress with animation'
46
+ name: 'Emphasized card displaying progress, for use in the Learning Environment'
169
47
  };
170
- export const EmphasizedCardWithProgress100Animation = {
171
- render: args => /*#__PURE__*/_jsx(LearningOutcomeCard, {
172
- ...args,
173
- level: 2,
174
- progress: 100,
175
- progressUpdateData: {
176
- previousProgress: 50,
177
- completionDelay: 500
178
- },
179
- skills: [{
180
- title: 'java'
181
- }, {
182
- title: 'skill'
183
- }, {
184
- title: 'computer science'
185
- }],
186
- mode: "emphasized"
48
+ export const EmphasizedCardWithProgress100 = {
49
+ render: args => /*#__PURE__*/_jsx(Background, {
50
+ bg: "navy",
51
+ p: 24,
52
+ children: /*#__PURE__*/_jsx(LearningOutcomeCard, {
53
+ emphasized: true,
54
+ progress: 100,
55
+ ...args
56
+ })
57
+ }),
58
+ name: 'Emphasized card displaying 100% progress, for use in the Learning Environment'
59
+ };
60
+ export const EmphasizedCardWithAnimation = {
61
+ render: args => /*#__PURE__*/_jsx(Background, {
62
+ bg: "navy",
63
+ p: 24,
64
+ children: /*#__PURE__*/_jsx(LearningOutcomeCard, {
65
+ emphasized: true,
66
+ progress: 80,
67
+ progressUpdateData: {
68
+ previousProgress: 50,
69
+ progressDuration: 500
70
+ },
71
+ ...args
72
+ })
187
73
  }),
188
- name: 'Emphasized card with 100% progress with animation'
74
+ name: 'Emphasized card first displays 50% progress then animates until showing 80%, for use in the Learning Environment'
189
75
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@codecademy/brand",
3
3
  "description": "Brand component library for Codecademy",
4
- "version": "2.0.0-alpha.ec446648d8.0",
4
+ "version": "2.0.0-alpha.fd9088f77a.0",
5
5
  "author": "Codecademy Engineering <dev@codecademy.com>",
6
6
  "dependencies": {
7
7
  "@emotion/is-prop-valid": "^1.2.1",
@@ -1,8 +0,0 @@
1
- import React from 'react';
2
- interface AssessmentDetailProps {
3
- isHighestScore?: boolean;
4
- score?: number | null;
5
- scoreAchievedAt?: string | null;
6
- }
7
- export declare const AssessmentDetail: React.FC<AssessmentDetailProps>;
8
- export {};
@@ -1,55 +0,0 @@
1
- import { Box, FlexBox, Text } from '@codecademy/gamut';
2
- import React from 'react';
3
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
4
- export const AssessmentDetail = ({
5
- isHighestScore,
6
- score,
7
- scoreAchievedAt
8
- }) => {
9
- const hasPassedAssessment = score && score >= 70;
10
- return /*#__PURE__*/_jsxs(FlexBox, {
11
- borderColor: "background-hover",
12
- borderRight: isHighestScore ? 1 : 'none',
13
- width: "100%",
14
- p: 16,
15
- column: true,
16
- children: [/*#__PURE__*/_jsx(Text, {
17
- fontWeight: 700,
18
- children: isHighestScore ? 'Highest score' : 'Most recent'
19
- }), score != null ? /*#__PURE__*/_jsxs(_Fragment, {
20
- children: [/*#__PURE__*/_jsxs(FlexBox, {
21
- mt: 8,
22
- alignItems: "center",
23
- children: [/*#__PURE__*/_jsx(Text, {
24
- variant: "title-sm",
25
- "data-testid": "score-percent",
26
- mr: 4,
27
- color: hasPassedAssessment ? 'green-700' : undefined,
28
- children: `${score}%`
29
- }), /*#__PURE__*/_jsx(Box, {
30
- children: !hasPassedAssessment && /*#__PURE__*/_jsx(Box, {
31
- "data-testid": "failed-assessment-indicator",
32
- borderRadius: "full",
33
- dimensions: 16,
34
- bg: "orange-500",
35
- mb: 4
36
- })
37
- })]
38
- }), !!scoreAchievedAt && /*#__PURE__*/_jsx(Text, {
39
- textColor: "text-secondary",
40
- children: scoreAchievedAt
41
- })]
42
- }) : /*#__PURE__*/_jsxs(FlexBox, {
43
- column: true,
44
- color: "text-secondary",
45
- children: [/*#__PURE__*/_jsx(Text, {
46
- fontWeight: 700,
47
- my: 4,
48
- "aria-hidden": true,
49
- children: "-"
50
- }), /*#__PURE__*/_jsx(Text, {
51
- children: "Not tested yet"
52
- })]
53
- })]
54
- });
55
- };
@@ -1,8 +0,0 @@
1
- interface AssessmentScoresProps {
2
- highestScore: number | null | undefined;
3
- highestScoreAchievedAt: string | null | undefined;
4
- latestScore: number | null | undefined;
5
- latestScoreAchievedAt: string | null | undefined;
6
- }
7
- export declare const LearningOutcomeAssessmentScores: React.FC<AssessmentScoresProps>;
8
- export {};
@@ -1,24 +0,0 @@
1
- import { FlexBox } from '@codecademy/gamut';
2
- import { AssessmentDetail } from './AssessmentDetail';
3
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
4
- export const LearningOutcomeAssessmentScores = ({
5
- highestScore,
6
- highestScoreAchievedAt,
7
- latestScore,
8
- latestScoreAchievedAt
9
- }) => {
10
- return /*#__PURE__*/_jsxs(FlexBox, {
11
- borderColor: "background-hover",
12
- border: 1,
13
- borderRadius: "md",
14
- width: "100%",
15
- children: [/*#__PURE__*/_jsx(AssessmentDetail, {
16
- isHighestScore: true,
17
- score: highestScore,
18
- scoreAchievedAt: highestScoreAchievedAt
19
- }), /*#__PURE__*/_jsx(AssessmentDetail, {
20
- score: latestScore,
21
- scoreAchievedAt: latestScoreAchievedAt
22
- })]
23
- });
24
- };
@@ -1,29 +0,0 @@
1
- import { LearningOutcomeLevels } from '../LearningOutcomeBadges';
2
- export declare enum SkillClassification {
3
- Language = "language",
4
- Subject = "subject"
5
- }
6
- interface LearningOutcomeSkill {
7
- id: string;
8
- slug: string;
9
- title?: string | null;
10
- classification?: SkillClassification | null;
11
- }
12
- interface LearningOutcomeDetailsProps {
13
- level: LearningOutcomeLevels;
14
- outcome: string;
15
- percentComplete: number | undefined | null;
16
- highestScore: number | undefined | null;
17
- highestScoreAchievedAt: string | undefined | null;
18
- latestScore: number | undefined | null;
19
- latestScoreAchievedAt: string | undefined | null;
20
- skills?: LearningOutcomeSkill[] | null;
21
- }
22
- interface LearningOutcomeFlyoutProps {
23
- expanded: boolean;
24
- onClose: () => void;
25
- learningOutcome: LearningOutcomeDetailsProps;
26
- }
27
- export declare const sortSkillsByClassification: (skills?: LearningOutcomeSkill[] | null) => LearningOutcomeSkill[];
28
- export declare const LearningOutcomeFlyout: React.FC<LearningOutcomeFlyoutProps>;
29
- export {};