@@ -7,9 +7,9 @@ import contentMessages from '@src/library-authoring/add-content/messages';
77import { useCourseAuthoringContext } from '@src/CourseAuthoringContext' ;
88import { SidebarFilters } from '@src/library-authoring/library-filters/SidebarFilters' ;
99import {
10- Button , Icon , Stack , Tab , Tabs ,
10+ Stack , Tab , Tabs ,
1111} from '@openedx/paragon' ;
12- import { getIconBorderStyleColor , getItemIcon } from '@src/generic/block-type-utils' ;
12+ import { getItemIcon } from '@src/generic/block-type-utils' ;
1313import {
1414 useCallback , useEffect , useMemo , useState ,
1515} from 'react' ;
@@ -20,6 +20,7 @@ import { ContentType } from '@src/library-authoring/routes';
2020import { ComponentPicker } from '@src/library-authoring' ;
2121import { MultiLibraryProvider } from '@src/library-authoring/common/context/MultiLibraryContext' ;
2222import { COURSE_BLOCK_NAMES } from '@src/constants' ;
23+ import { BlockCardButton } from '@src/generic/sidebar/BlockCardButton' ;
2324import AlertMessage from '@src/generic/alert-message' ;
2425import { useCourseItemData } from '@src/course-outline/data/apiHooks' ;
2526import { useOutlineSidebarContext } from './OutlineSidebarContext' ;
@@ -157,19 +158,12 @@ const AddContentButton = ({ name, blockType } : AddContentButtonProps) => {
157158 const disabled = handleAddSection . isPending || handleAddSubsection . isPending || handleAddAndOpenUnit . isPending ;
158159
159160 return (
160- < Button
161- variant = "tertiary shadow"
162- className = "mx-2 justify-content-start px-4 font-weight-bold"
161+ < BlockCardButton
162+ name = { name }
163+ blockType = { blockType }
163164 onClick = { onCreateContent }
164165 disabled = { disabled }
165- >
166- < Stack direction = "horizontal" gap = { 3 } >
167- < span className = { `p-2 rounded ${ getIconBorderStyleColor ( blockType ) } ` } >
168- < Icon size = "lg" src = { getItemIcon ( blockType ) } />
169- </ span >
170- { name }
171- </ Stack >
172- </ Button >
166+ />
173167 ) ;
174168} ;
175169
0 commit comments