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

feat: configureable header links #475

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

asadali145
Copy link

@asadali145 asadali145 commented Mar 29, 2024

Issue

openedx/platform-roadmap#349

Description

Makes header links, labels, and User name display more customizable using the configurations.

Testing

  • You can test this PR with the Account MFE & Learning MFE
  • Set these variables in .env.development of the Account & Learning MFE
    • SHOW_FULLNAME=true
    • DASHBOARD_URL=<ANY URL>
    • EXTERNAL_ACCOUNT_PROFILE_URL=<ANY URL>
    • SHOW_SETTINGS_LABEL=true
    • ACCOUNT_SETTINGS_URL=http://localhost:1997
  • Use the local version of this header component and checkout this branch
  • For header, run:
    • npm i
    • npm run build
  • Now start the MFEs
  • Header should reflect the configured changes.
  • Also, test without the variables and the defaults should match the master branch.

Screenshots

Screenshot 2024-03-29 at 5 34 39 PM

@openedx-webhooks openedx-webhooks added the open-source-contribution PR author is not from Axim or 2U label Mar 29, 2024
@openedx-webhooks
Copy link

openedx-webhooks commented Mar 29, 2024

Thanks for the pull request, @asadali145!

What's next?

Please work through the following steps to get your changes ready for engineering review:

🔘 Get product approval

If you haven't already, check this list to see if your contribution needs to go through the product review process.

  • If it does, you'll need to submit a product proposal for your contribution, and have it reviewed by the Product Working Group.
    • This process (including the steps you'll need to take) is documented here.
  • If it doesn't, simply proceed with the next step.

🔘 Provide context

To help your reviewers and other members of the community understand the purpose and larger context of your changes, feel free to add as much of the following information to the PR description as you can:

  • Dependencies

    This PR must be merged before / after / at the same time as ...

  • Blockers

    This PR is waiting for OEP-1234 to be accepted.

  • Timeline information

    This PR must be merged by XX date because ...

  • Partner information

    This is for a course on edx.org.

  • Supporting documentation
  • Relevant Open edX discussion forum threads

🔘 Get a green build

If one or more checks are failing, continue working on your changes until this is no longer the case and your build turns green.

🔘 Let us know that your PR is ready for review:

Who will review my changes?

This repository is currently unmaintained.

To get help with finding a technical reviewer, tag the community contributions project manager for this PR in a comment and let them know that your changes are ready for review:

  1. On the right-hand side of the PR, find the Contributions project, click the caret in the top right corner to expand it, and check the "Primary PM" field for the name of your PM.
  2. Find their GitHub handle here.

Where can I find more information?

If you'd like to get more details on all aspects of the review process for open source pull requests (OSPRs), check out the following resources:

When can I expect my changes to be merged?

Our goal is to get community contributions seen and reviewed as efficiently as possible.

However, the amount of time that it takes to review and merge a PR can vary significantly based on factors such as:

  • The size and impact of the changes that it introduces
  • The need for product review
  • Maintenance status of the parent repository

💡 As a result it may take up to several weeks or months to complete a review and merge your PR.

@asadali145 asadali145 changed the title feat: custom header links feat!: custom header links Mar 29, 2024
@mphilbrick211 mphilbrick211 added the needs test run Author's first PR to this repository, awaiting test authorization from Axim label Mar 29, 2024
@e0d e0d removed the needs test run Author's first PR to this repository, awaiting test authorization from Axim label Apr 1, 2024
Copy link

codecov bot commented Apr 1, 2024

Codecov Report

Attention: Patch coverage is 93.75000% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 67.71%. Comparing base (45246ad) to head (35287fc).
Report is 3 commits behind head on master.

❗ Current head 35287fc differs from pull request most recent head d5227d4. Consider uploading reports for the commit d5227d4 to get more accurate results

Files Patch % Lines
src/Header.jsx 88.88% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #475      +/-   ##
==========================================
- Coverage   70.67%   67.71%   -2.96%     
==========================================
  Files          24       24              
  Lines         358      350       -8     
  Branches       90       88       -2     
==========================================
- Hits          253      237      -16     
- Misses        103      111       +8     
  Partials        2        2              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@asadali145 asadali145 changed the title feat!: custom header links feat!: configureable header links Apr 1, 2024
@asadali145 asadali145 changed the title feat!: configureable header links feat: configureable header links Apr 1, 2024
@asadali145 asadali145 marked this pull request as ready for review April 5, 2024 11:47
@mphilbrick211
Copy link

Hi @asadali145! Would you mind resolving the branch conflicts while I look for someone to review for you? Thanks!

* Added user full name option

* nit
@asadali145
Copy link
Author

@mphilbrick211 This should be good for a review now.

@asadali145
Copy link
Author

@arbrandes What are your thoughts on this PR? It is similar to the footer PR openedx/frontend-component-footer#403 related to openedx/platform-roadmap#324

@mphilbrick211 mphilbrick211 added the needs reviewer assigned PR needs to be (re-)assigned a new reviewer label Jul 30, 2024
@arbrandes
Copy link
Contributor

@asadali145, the latest on this is that we'll be addressing header configurability as part of the OEP-65/Module Federation work. For the most part, it will be done as proposed here:

https://openedx.atlassian.net/wiki/spaces/OEPM/pages/4412243977/Proposal+Customizable+Header+for+LMS

In the meantime, we're also adding PluginSlots to the header, such as this one.

#528

The slots should be ready by Sumac.

@pdpinch
Copy link

pdpinch commented Oct 14, 2024

@asadali145 should we pursue this via the header pluginslot instead of configuration settings?

@asadali145
Copy link
Author

@asadali145 should we pursue this via the header pluginslot instead of configuration settings?

@pdpinch I don't think there is much that I can do at the moment per this comment on my footer PR

@davidjoy
Copy link
Contributor

My recommendation would be for us to add plugin slots to the header/footer to support customization use cases for now, I think @brian-smith-tcril is helping with this effort.

As the comment @asadali145 linked mentions, we're working on a longer-term version of the header and footer which will support more customization through simple configuration. That's taking some time to get right, and won't be available for a while. Certainly not by Sumac, maybe by Teak.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs reviewer assigned PR needs to be (re-)assigned a new reviewer open-source-contribution PR author is not from Axim or 2U
Projects
Status: Ready for Review
Development

Successfully merging this pull request may close these issues.

8 participants