Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Karla/hide functions #104

Merged
merged 3 commits into from
Apr 7, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 33 additions & 23 deletions src/components/ProfilePage/ProfilePageRender.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import {
import { IoIosCloseCircle } from "react-icons/io";
import useExperiences from "../../hooks/use-experiences.js";


function ProfilePageDetails() {
const { id } = useParams();
const {
Expand Down Expand Up @@ -132,26 +131,32 @@ function ProfilePageDetails() {

<div className="other-info-container">
<div className="skills-section">
<h3>Tags:</h3>
<div className="skill-tags">
<ul>
{profile.tags.map((tag, index) => (
<li key={index}>{tag}</li>
))}
</ul>
</div>
{profile.tags.length === 0 ? null : (
<>
<h3>Tags:</h3>
<div className="skill-tags">
<ul>
{profile.tags.map((tag, index) => (
<li key={index}>{tag}</li>
))}
</ul>
</div>
</>
)}
<div>
<div className="industry-tags">
<h3>Industry Tags:</h3>
<ul>
{profile.industries.map((industry, index) => (
<li key={index}>{industry}</li>
))}
</ul>
</div>
{profile.industries.length === 0 ? null : (
<div className="industry-tags">
<h3>Industry Tags:</h3>
<ul>
{profile.industries.map((industry, index) => (
<li key={index}>{industry}</li>
))}
</ul>
</div>
)}
</div>

</div>

<div className="profile-page-render-experiences-section">
<h3>Experiences</h3>

Expand All @@ -170,19 +175,24 @@ function ProfilePageDetails() {
</div>

<div className="experience-cards-container">
{experiences.map((experienceData, key) => {
return (
{experiences.length === 0 ? (
<div>
<p>This profile has no experiences to display at the moment</p>
</div>
) : (
experiences.map((experienceData, key) => (
<div className="mb-1">
<ExperienceCard
key={key}
experienceData={experienceData}
profileOwner={user.id}
/>
</div>
);
})}
))
)}
</div>
</div>

<div className="contact-info">
{auth.token ? (
<>
Expand Down Expand Up @@ -291,4 +301,4 @@ function ProfilePageDetails() {
);
}

export default ProfilePageDetails;
export default ProfilePageDetails;
Loading