Skip to content

Remove the breadcrumb navigation. - #3303

Open
drgrice1 wants to merge 1 commit into
openwebwork:developfrom
drgrice1:breadcrumb-remove
Open

drgrice1 wants to merge 1 commit into
openwebwork:developfrom
drgrice1:breadcrumb-remove

Conversation

@drgrice1

@drgrice1 drgrice1 commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

The path method has been renamed to the pageTitle method, since that is all it is ever used for now that it does not also generated the breadcrumb. The old page_title method has been renamed to the pageHeader method to avoid confusion. Also, the pathMacro method is now the formatTitle method.

The site navigation side bar is now shown in tests. The "Assignments" link and a link back to the set detail page for the test are the only links shown in the site navigation menu for students during a test. The "Account Settings", "Grades", "Achievements", and "Achievements Leaderboard" links are not shown for students during a test. The options link in the user menu is not shown for a student during a test either.

Note that all of those links and the instructor page links are shown for instructors during a test.

Now that the site navigation menu is visible for tests, the siblings region can be utilized. So add a problem navigation to the GatewayQuiz siblings section. A link for a problem on the current page scrolls to the problem, and a link for a problem on another page opens that page and then scrolls to the problem.

@somiaj

somiaj commented Nov 22, 2026

Copy link
Copy Markdown
Contributor

Would it be useful to make the menu closed on page load on tests? This way they mostly look the same, but have a button to open the menu if needed?

@drgrice1

Copy link
Copy Markdown
Member Author

I decided not to do that for three reasons. First, there are now siblings links in a test that are pertinent during a test. Second, the format in a test now matches that of a problem in a regular assignment. Third, the menu is not designed to work that way, and trying to make it so would be a pain to implement.

@drgrice1
drgrice1 force-pushed the breadcrumb-remove branch 3 times, most recently from b74db4b to cd759a3 Compare November 24, 2026 15:53
@somiaj

somiaj commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

I had one more question about this. Why is javascript needed for the siblings problem links? There are already problem anchors, do these not work correctly linking to a problem on the same page?

@drgrice1

Copy link
Copy Markdown
Member Author

I debated on changing that. There is a case that anchored links do not quite work right though. Basically, MathJax rendering can cause resizing of the page above the anchor with can push the page down and mess up positioning of the initial anchor. The JavaScript delays the scroll until after MathJax has rendered for this reason.

@drgrice1

Copy link
Copy Markdown
Member Author

Actually, looking closer at the possibility of using fragments instead of the JavaScript reveals that it would work for the jump links in the page, but it would not for the new siblings links. The problem is that those problems are not in the current page. So a fragment would simply fail. Even for the current jump links though, there is the benefit of not polluting the URL in the browser history.

@drgrice1

Copy link
Copy Markdown
Member Author

To further explain the benefit of not polluting the URL, if the jump links were switched to using a fragment, and then that hash would be in the URL after using the jump link. Then if you reload the page with F5, if the page is bookmarked, if back/forward navigation is used, or the link is copied and opened in another browser (for example if the link is emailed to someone else), then the MathJax positioning does become an issue.

@somiaj somiaj left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Glad to have the breadcrumb navigation gone.

@somiaj

somiaj commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

Thanks for the explanation, I just wasn't sure what the advantages of using this with JavaScript was.

@drgrice1
drgrice1 force-pushed the breadcrumb-remove branch 7 times, most recently from 64e2287 to f979801 Compare November 24, 2026 22:35
The `path` method has been renamed to the `pageTitle` method, since that
is all it is ever used for now that it does not also generated the
breadcrumb. The old `page_title` method has been renamed to the
`pageHeader` method to avoid confusion.  Also, the `pathMacro` method is
now the `formatTitle` method.

The site navigation side bar is now shown in tests. The "Assignments"
header is shown for students during a test, but is only text (not a
link).  The only student link shown during a test is back to the set
detail page for the test. The "Account Settings", "Grades",
"Achievements", and "Achievements Leaderboard" links are not shown for
students during a test.

Note that all of those links and the instructor page links are shown for
instructors during a test.

Add a problem navigation to the GatewayQuiz siblings section.

List links to all of the problems in a test in the site navigation
sidebar. A link for a problem on the current page scrolls to the
problem, and a link for a problem on another page opens that page and
then scrolls to the problem.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants