Skip to content

Commit

Permalink
Merge pull request #574 from captain-Akshay/captain/learningpath
Browse files Browse the repository at this point in the history
feat(components): enchancement in learning component
  • Loading branch information
leecalcote committed Apr 22, 2024
2 parents 4c86edf + 4458b47 commit ab2b042
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 16 deletions.
8 changes: 3 additions & 5 deletions src/custom/LearningCard/LearningCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,7 @@ interface Tutorial {
courseTitle: string;
description: string;
status?: boolean;
cardImage: {
src: string;
};
cardImage: string;
};
}

Expand Down Expand Up @@ -52,7 +50,7 @@ const LearningCard: React.FC<Props> = ({ tutorial, path, courseCount }) => {
<p className="summary">{tutorial.frontmatter.description}</p>
</CardDesc>
<CardImage>
<img src={tutorial.frontmatter.cardImage.src} alt={tutorial.frontmatter.title} />
<img src={tutorial.frontmatter.cardImage} alt={tutorial.frontmatter.title} />
</CardImage>
</div>
</CardParent>
Expand Down Expand Up @@ -83,7 +81,7 @@ const LearningCard: React.FC<Props> = ({ tutorial, path, courseCount }) => {
</p>
</CardSubdata>
<CardImage>
<img src={tutorial.frontmatter.cardImage.src} alt={tutorial.frontmatter.title} />
<img src={tutorial.frontmatter.cardImage} />
</CardImage>
</div>
</CardParent>
Expand Down
8 changes: 3 additions & 5 deletions src/custom/SetupPrerequisite/SetupPrerequisite.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,13 @@ interface SetupItem {
}
interface SetupPreReqProps {
Steps: SetupItem[];
PrerequisiteLine?: string;
}
const SetupPreReq: React.FC<SetupPreReqProps> = ({ Steps }) => (
const SetupPreReq: React.FC<SetupPreReqProps> = ({ Steps, PrerequisiteLine }) => (
<SetupPreReqWrapper>
<div className="get-started-desc" id="pre-requisites">
<h2>Prerequisites</h2>
<p>
In this learning path, we will be using Meshery as the management plane to manage the
service meshes. Meshery, collaborative Kubernetes manager
</p>
<p>{PrerequisiteLine}</p>
</div>
<ContainerCardWrapper id="Set up">
{Steps.map((item) => {
Expand Down
9 changes: 3 additions & 6 deletions src/custom/SetupPrerequisite/style.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,9 @@ const Card = styled('div')(({ theme }) => ({

const CardHeader = styled('div')({
display: 'flex',
flex: 'auto',
'& .setup-imgs ': {
flex: '0 0 25%',
alignSelf: 'center',
margin: '0 0.5rem'
}
alignItems: 'center',
margin: '1rem 0 !important',
gap: '1rem'
});

const SetupImgs = styled('div')({
Expand Down

0 comments on commit ab2b042

Please sign in to comment.