Refactor home page to remove social links section #33

Closed
opened 2026-01-15 06:51:45 +00:00 by lmiranda · 0 comments
Owner

Description

Remove the social links section from the home page since these links are now accessible globally via the sidebar navigation. This reduces redundancy and keeps the bio page focused on content.

Files to Modify

  • portfolio_app/pages/home.py

Changes Required

Delete or comment out:

SOCIAL_LINKS = [
    {
        "platform": "LinkedIn",
        "url": "https://linkedin.com/in/leobmiranda",
        "icon": "mdi:linkedin",
    },
    {
        "platform": "GitHub",
        "url": "https://github.com/leomiranda",
        "icon": "mdi:github",
    },
]

Delete or comment out:

def create_social_links() -> dmc.Group:
    """Create social media links."""
    return dmc.Group(
        [
            dmc.Anchor(
                dmc.Button(
                    link["platform"],
                    leftSection=DashIconify(icon=link["icon"], width=20),
                    variant="outline",
                    size="md",
                ),
                href=link["url"],
                target="_blank",
            )
            for link in SOCIAL_LINKS
        ],
        justify="center",
        gap="md",
    )

3. Update Layout

Remove create_social_links() from layout:

# Before
layout = dmc.Container(
    dmc.Stack(
        [
            create_hero_section(),
            create_summary_section(),
            create_tech_stack_section(),
            create_projects_section(),
            create_social_links(),  # Remove this line
            dmc.Divider(my="lg"),
            create_availability_section(),
            dmc.Space(h=40),
        ],
        gap="xl",
    ),
    size="md",
    py="xl",
)

# After
layout = dmc.Container(
    dmc.Stack(
        [
            create_hero_section(),
            create_summary_section(),
            create_tech_stack_section(),
            create_projects_section(),
            dmc.Divider(my="lg"),
            create_availability_section(),
            dmc.Space(h=40),
        ],
        gap="xl",
    ),
    size="md",
    py="xl",
)

4. Optional: Remove DashIconify Import

If DashIconify is no longer used elsewhere in the file, remove:

from dash_iconify import DashIconify

Acceptance Criteria

  • Social links no longer appear on home page
  • Social links still accessible via sidebar
  • Home page renders without errors
  • No unused imports remain
  • Layout spacing still looks good
  • Page still displays all other content correctly

Part of Sprint 7 (#27)

Depends On

  • #31 (app layout restructured with sidebar visible)
## Description Remove the social links section from the home page since these links are now accessible globally via the sidebar navigation. This reduces redundancy and keeps the bio page focused on content. ## Files to Modify - `portfolio_app/pages/home.py` ## Changes Required ### 1. Remove Social Links Constant Delete or comment out: ```python SOCIAL_LINKS = [ { "platform": "LinkedIn", "url": "https://linkedin.com/in/leobmiranda", "icon": "mdi:linkedin", }, { "platform": "GitHub", "url": "https://github.com/leomiranda", "icon": "mdi:github", }, ] ``` ### 2. Remove create_social_links Function Delete or comment out: ```python def create_social_links() -> dmc.Group: """Create social media links.""" return dmc.Group( [ dmc.Anchor( dmc.Button( link["platform"], leftSection=DashIconify(icon=link["icon"], width=20), variant="outline", size="md", ), href=link["url"], target="_blank", ) for link in SOCIAL_LINKS ], justify="center", gap="md", ) ``` ### 3. Update Layout Remove `create_social_links()` from layout: ```python # Before layout = dmc.Container( dmc.Stack( [ create_hero_section(), create_summary_section(), create_tech_stack_section(), create_projects_section(), create_social_links(), # Remove this line dmc.Divider(my="lg"), create_availability_section(), dmc.Space(h=40), ], gap="xl", ), size="md", py="xl", ) # After layout = dmc.Container( dmc.Stack( [ create_hero_section(), create_summary_section(), create_tech_stack_section(), create_projects_section(), dmc.Divider(my="lg"), create_availability_section(), dmc.Space(h=40), ], gap="xl", ), size="md", py="xl", ) ``` ### 4. Optional: Remove DashIconify Import If `DashIconify` is no longer used elsewhere in the file, remove: ```python from dash_iconify import DashIconify ``` ## Acceptance Criteria - [ ] Social links no longer appear on home page - [ ] Social links still accessible via sidebar - [ ] Home page renders without errors - [ ] No unused imports remain - [ ] Layout spacing still looks good - [ ] Page still displays all other content correctly ## Part of Sprint 7 (#27) ## Depends On - #31 (app layout restructured with sidebar visible)
lmiranda added this to the Launch: Host, Bio and Toronto House Market Analysis project 2026-01-16 14:51:54 +00:00
lmiranda self-assigned this 2026-01-16 14:51:59 +00:00
lmiranda moved this to Done in Launch: Host, Bio and Toronto House Market Analysis on 2026-01-16 14:52:19 +00:00
Sign in to join this conversation.