feat: Update previous and next unit navigation buttons design (#1617)
* feat: Update previous and next unit navigation buttons design * feat: add unit test * feat: move unit navigation to be inline with unit title
This commit is contained in:
@@ -5,7 +5,6 @@ import { PluginSlot } from '@openedx/frontend-plugin-framework';
|
||||
import NextButton from '../../courseware/course/sequence/sequence-navigation/generic/NextButton';
|
||||
|
||||
interface Props {
|
||||
courseId: string | '';
|
||||
disabled: boolean;
|
||||
buttonText: string | '';
|
||||
nextLink: string;
|
||||
@@ -14,10 +13,10 @@ interface Props {
|
||||
onClickHandler: () => void;
|
||||
variant: string;
|
||||
buttonStyle: string;
|
||||
isAtTop: boolean;
|
||||
}
|
||||
|
||||
export const NextUnitTopNavTriggerSlot : React.FC<Props> = ({
|
||||
courseId,
|
||||
disabled,
|
||||
buttonText,
|
||||
nextLink,
|
||||
@@ -25,11 +24,11 @@ export const NextUnitTopNavTriggerSlot : React.FC<Props> = ({
|
||||
onClickHandler,
|
||||
variant,
|
||||
buttonStyle,
|
||||
isAtTop,
|
||||
}) => (
|
||||
<PluginSlot
|
||||
id="next_unit_top_nav_trigger_slot"
|
||||
pluginProps={{
|
||||
courseId,
|
||||
disabled,
|
||||
buttonText,
|
||||
nextLink,
|
||||
@@ -37,6 +36,7 @@ export const NextUnitTopNavTriggerSlot : React.FC<Props> = ({
|
||||
onClickHandler,
|
||||
variant,
|
||||
buttonStyle,
|
||||
isAtTop,
|
||||
}}
|
||||
>
|
||||
<NextButton
|
||||
@@ -47,6 +47,7 @@ export const NextUnitTopNavTriggerSlot : React.FC<Props> = ({
|
||||
nextLink,
|
||||
disabled,
|
||||
buttonText,
|
||||
isAtTop,
|
||||
}}
|
||||
/>
|
||||
</PluginSlot>
|
||||
|
||||
Reference in New Issue
Block a user