From af0124d4e6c571a345d86b65dcfa6c1335812caf Mon Sep 17 00:00:00 2001 From: Kristin Aoki <42981026+KristinAoki@users.noreply.github.com> Date: Thu, 16 Nov 2023 18:05:50 -0500 Subject: [PATCH] fix: general page layout and colors (#693) --- src/files-and-videos/files-page/FilesPage.jsx | 26 ++++----- src/files-and-videos/generic/FileTable.jsx | 8 ++- src/files-and-videos/index.scss | 21 +++++++ .../videos-page/VideosPage.jsx | 57 +++++++++---------- 4 files changed, 66 insertions(+), 46 deletions(-) diff --git a/src/files-and-videos/files-page/FilesPage.jsx b/src/files-and-videos/files-page/FilesPage.jsx index 013d7a511..1111dbc93 100644 --- a/src/files-and-videos/files-page/FilesPage.jsx +++ b/src/files-and-videos/files-page/FilesPage.jsx @@ -3,7 +3,7 @@ import PropTypes from 'prop-types'; import { isEmpty } from 'lodash'; import { useDispatch, useSelector } from 'react-redux'; import { injectIntl, FormattedMessage, intlShape } from '@edx/frontend-platform/i18n'; -import { CheckboxFilter } from '@edx/paragon'; +import { CheckboxFilter, Container } from '@edx/paragon'; import Placeholder from '@edx/frontend-lib-content-components'; import { RequestStatus } from '../../data/constants'; @@ -169,18 +169,16 @@ const FilesPage = ({ } return ( -
-
- -
- -
+ + +
+
-
+
); }; diff --git a/src/files-and-videos/generic/FileTable.jsx b/src/files-and-videos/generic/FileTable.jsx index 38fea10db..0d285e773 100644 --- a/src/files-and-videos/generic/FileTable.jsx +++ b/src/files-and-videos/generic/FileTable.jsx @@ -51,7 +51,8 @@ const FileTable = ({ xs: 12, sm: 6, md: 4, - lg: 2, + lg: 3, + xl: 2, }; const [currentView, setCurrentView] = useState(defaultVal); const [isDeleteOpen, setDeleteOpen, setDeleteClose] = useToggle(false); @@ -212,9 +213,10 @@ const FileTable = ({ }} /> ) : ( -
+
- { currentView === 'card' && } +
+ { currentView === 'card' && } { currentView === 'list' && } diff --git a/src/files-and-videos/index.scss b/src/files-and-videos/index.scss index 32c5d08f9..632267368 100644 --- a/src/files-and-videos/index.scss +++ b/src/files-and-videos/index.scss @@ -6,6 +6,27 @@ #table-filters-dropdown { visibility: hidden; } + + .pgn__data-table-layout-main { + background-color: $light-200; + + .pgn__data-table-status-bar { + padding: 12px 0; + + .pgn__data-table-actions-left { + margin-top: 16px; + } + } + + .pgn__data-table-card-view { + margin-left: 24px; + + .pgn__card-grid__card-item { + padding: 0 24px 24px 0; + margin-bottom: 0; + } + } + } } .pgn__form-control-set-inline { diff --git a/src/files-and-videos/videos-page/VideosPage.jsx b/src/files-and-videos/videos-page/VideosPage.jsx index 16e0b5c2d..b7f035292 100644 --- a/src/files-and-videos/videos-page/VideosPage.jsx +++ b/src/files-and-videos/videos-page/VideosPage.jsx @@ -12,6 +12,7 @@ import { ActionRow, Button, CheckboxFilter, + Container, } from '@edx/paragon'; import Placeholder from '@edx/frontend-lib-content-components'; @@ -177,34 +178,32 @@ const VideosPage = ({ } return ( -
-
- - -
- -
- - {isVideoTranscriptEnabled ? ( - - ) : null} -
-
+ + + +
+ +
+ + {isVideoTranscriptEnabled ? ( + + ) : null} +
{isVideoTranscriptEnabled ? ( -
+
); };