Skip to content

Commit d232be1

Browse files
committed
fix: update comments for clarity and add collectionKeys to component picker tests
1 parent ee3db52 commit d232be1

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/library-authoring/LibraryContent.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ const LibraryContent = ({ contentType = ContentType.home }: LibraryContentProps)
4747
* Filter collections on the frontend to display only collection cards in the Collections tab.
4848
* This approach is used instead of backend filtering to ensure that all components (including those
4949
* within collections) remain available in the 'hits' array. This is necessary for the component
50-
* selection workflow when adding components to xblocks by choosing the while collection in Collections tab.
50+
* selection workflow when adding components to xblocks by choosing the whole collection in Collections tab.
5151
* Note: LibraryAuthoringPage.tsx has been modified to skip backend filtering for this purpose.
5252
*/
5353
const filteredHits = contentType === ContentType.collections

src/library-authoring/component-picker/ComponentPicker.test.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,7 @@ describe('<ComponentPicker />', () => {
224224
{
225225
usageKey: 'lb:Axim:TEST:html:571fe018-f3ce-45c9-8f53-5dafcb422fdd',
226226
blockType: 'html',
227+
collectionKeys: undefined,
227228
},
228229
]));
229230

@@ -235,10 +236,12 @@ describe('<ComponentPicker />', () => {
235236
{
236237
usageKey: 'lb:Axim:TEST:html:571fe018-f3ce-45c9-8f53-5dafcb422fdd',
237238
blockType: 'html',
239+
collectionKeys: undefined,
238240
},
239241
{
240242
blockType: 'html',
241243
usageKey: 'lb:Axim:TEST:html:73a22298-bcd9-4f4c-ae34-0bc2b0612480',
244+
collectionKeys: undefined,
242245
},
243246
]));
244247

@@ -250,6 +253,7 @@ describe('<ComponentPicker />', () => {
250253
{
251254
blockType: 'html',
252255
usageKey: 'lb:Axim:TEST:html:73a22298-bcd9-4f4c-ae34-0bc2b0612480',
256+
collectionKeys: undefined,
253257
},
254258
]));
255259
});

0 commit comments

Comments
 (0)