Skip to content

Commit

Permalink
fix help links
Browse files Browse the repository at this point in the history
Several links were still pointing to the old web address.
I tried to search for them all so hopefully all fixed now.
  • Loading branch information
huss committed Nov 12, 2024
1 parent be1abbf commit 322fbe6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/client/app/components/HeaderButtonsComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export default function HeaderButtonsComponent() {
const version = useAppSelector(selectOEDVersion);
const helpUrl = useAppSelector(selectHelpUrl);
// options help
const optionsHelp = helpUrl + '/optionsMenu.html';
const optionsHelp = helpUrl + '/optionsMenu/';

const loggedInAsAdmin = useAppSelector(selectIsAdmin);
const loggedIn = useAppSelector(selectIsLoggedIn);
Expand Down Expand Up @@ -127,7 +127,7 @@ export default function HeaderButtonsComponent() {
display: pathname === '/' ? 'block' : 'none'
};
// Admin help or regular user page
const neededPage = loggedInAsAdmin ? '/adminPageChoices.html' : '/pageChoices.html';
const neededPage = loggedInAsAdmin ? '/adminPageChoices/' : '/pageChoices/';
const currentPageChoicesHelp = helpUrl + neededPage;

setState(prevState => ({
Expand Down
6 changes: 2 additions & 4 deletions src/client/app/components/LanguageSelectorComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import * as React from 'react';
import { FormattedMessage } from 'react-intl';
import { DropdownItem, DropdownMenu, DropdownToggle, UncontrolledDropdown } from 'reactstrap';
import { selectSelectedLanguage, updateSelectedLanguage } from '../redux/slices/appStateSlice';
import { selectOEDVersion } from '../redux/api/versionApi';
import { useAppDispatch, useAppSelector } from '../redux/reduxHooks';
import { LanguageTypes } from '../types/redux/i18n';
import { selectBaseHelpUrl } from '../redux/slices/adminSlice';
Expand All @@ -19,10 +18,9 @@ export default function LanguageSelectorComponent() {
const dispatch = useAppDispatch();

const selectedLanguage = useAppSelector(selectSelectedLanguage);
const version = useAppSelector(selectOEDVersion);
const baseHelpUrl = useAppSelector(selectBaseHelpUrl);

const helpUrl = baseHelpUrl + version;
const helpUrl = baseHelpUrl;

return (
<>
Expand All @@ -48,7 +46,7 @@ export default function LanguageSelectorComponent() {
</DropdownItem>
<DropdownItem divider />
<DropdownItem
href={helpUrl + '/language.html'}>
href={helpUrl + '/language/'}>
<FormattedMessage id="help" />
</DropdownItem>
</DropdownMenu>
Expand Down

0 comments on commit 322fbe6

Please sign in to comment.