Closed HussainTaj-arbisoft closed 8 months ago
Netlify Deployments:
www: https://ocw-hugo-themes-www-pr-1269--ocw-next.netlify.app/
Course v2: https://ocw-hugo-themes-course-v2-pr-1269--ocw-next.netlify.app/
Thanks for the screen recording. I shared it with the OCW team. The design is great, BUT the video revealed an edge case that we didn't consider.
One of those links goes to https://www.ocw-openmatters.org, which the OCW team considers to be an internal site. Is there a reasonable way to add it to the list of sites considered "internal" ?
Is there a reasonable way to add it to the list of sites considered "internal"?
We can create a whitelist of sorts and treat those links as internal links. The current code can easily be extended to include this functionality.
We will need the complete list of domains and patterns to exclude. It will help us decide what string comparison approach to use.
I'll share the complete list of external URLs currently being used in production.
A complete list of external URLs is shared here: https://github.com/mitodl/hq/issues/1812#issuecomment-1778996149
@HussainTaj-arbisoft what remains to be done here?
@HussainTaj-arbisoft what remains to be done here?
@pdpinch, the exclusions remain to be implemented. I had a suggestion about it and I'm waiting for feedback on https://github.com/mitodl/hq/issues/1812#issuecomment-1788850100
@gumaerc, I've updated this PR according to our new requirements. It is ready to be looked at again.
There are now three types of behaviors links will show.
Menu items can now have a parameter called includeLicenseWarning
. You may view an example here.
Testing instructions are the same as before. For reference and testing, you may take this course content. Alternatively, this could also be tested as a part of https://github.com/mitodl/ocw-studio/pull/2034.
@gumaerc, this PR is also on hold for now. Since it incorporates changes of https://github.com/mitodl/ocw-studio/pull/2034, it won't require a review unless we move ahead with that change.
Superseded by https://github.com/mitodl/ocw-hugo-themes/pull/1364
What are the relevant tickets?
Closes https://github.com/mitodl/hq/issues/1812
Description (What does it do?)
This PR:
Choice of approach
A single modal's markdown is placed inside the
body
tag. The confirm action link is dynamically updated when a user clicks an external link.Bootstrap's modals are sensitive to positioned parents. This is the reason why the modal needs to be placed inside the
body
tag.Design: The off-bits
You might observe that the output looks a bit different from the designs (which might not be obvious). The reasons for this are:
Arial
while we useHelvetica
font.The following image shows a stress test of the icon placement design.
Screenshots (if appropriate):
https://github.com/mitodl/ocw-hugo-themes/assets/71316217/bfc87c2c-2ea7-4ab6-ab0f-9141c11be6a2
https://github.com/mitodl/ocw-hugo-themes/assets/71316217/82ec1ab8-dd69-4a01-9aa4-c676152f5535
How can this be tested?
hussaintaj/1812-external-link-modal
.