forked from openedx/frontend-app-authoring
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: files-and-videos folder (openedx#672)
- Loading branch information
1 parent
3dac6aa
commit 78eb512
Showing
49 changed files
with
226 additions
and
178 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 6 additions & 6 deletions
12
...os/files-page/FilesAndUploadsProvider.jsx → ...d-videos/files-page/FilesPageProvider.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,25 @@ | ||
import React, { useMemo } from 'react'; | ||
import PropTypes from 'prop-types'; | ||
|
||
export const FilesAndUploadsContext = React.createContext({}); | ||
export const FilesPageContext = React.createContext({}); | ||
|
||
const FilesAndUploadsProvider = ({ courseId, children }) => { | ||
const FilesPageProvider = ({ courseId, children }) => { | ||
const contextValue = useMemo(() => ({ | ||
courseId, | ||
path: `/course/${courseId}/assets`, | ||
}), []); | ||
return ( | ||
<FilesAndUploadsContext.Provider | ||
<FilesPageContext.Provider | ||
value={contextValue} | ||
> | ||
{children} | ||
</FilesAndUploadsContext.Provider> | ||
</FilesPageContext.Provider> | ||
); | ||
}; | ||
|
||
FilesAndUploadsProvider.propTypes = { | ||
FilesPageProvider.propTypes = { | ||
courseId: PropTypes.string.isRequired, | ||
children: PropTypes.node.isRequired, | ||
}; | ||
|
||
export default FilesAndUploadsProvider; | ||
export default FilesPageProvider; |
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
src/files-and-videos/data/slice.js → ...files-and-videos/files-page/data/slice.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
src/files-and-videos/data/thunks.js → ...iles-and-videos/files-page/data/thunks.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
import FilesAndUploads from './FilesAndUploads'; | ||
import FilesPage from './FilesPage'; | ||
import FileInfoModalSidebar from './FileInfoModalSidebar'; | ||
|
||
export default FilesAndUploads; | ||
export default FilesPage; | ||
export { FileInfoModalSidebar }; |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/files-and-videos/FileInput.jsx → src/files-and-videos/generic/FileInput.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.