From c8edf6496390b33c6392af824f53ce064ece7212 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciek=20G=C5=82owacki?= Date: Sun, 8 Nov 2020 13:40:11 +0100 Subject: [PATCH] topbar dropdown width aligned with input wrapper width --- src/components/Dropdown.tsx | 12 +++++------- src/components/SchedulerRow.tsx | 4 ++-- src/components/Topbar.tsx | 17 ++++++----------- 3 files changed, 13 insertions(+), 20 deletions(-) diff --git a/src/components/Dropdown.tsx b/src/components/Dropdown.tsx index 1f82b1c..206ce34 100644 --- a/src/components/Dropdown.tsx +++ b/src/components/Dropdown.tsx @@ -3,9 +3,7 @@ import { coursesContext } from '../contexts/CoursesProvider'; import { Course } from '../types'; import styled from 'styled-components'; -const WrapperIchuj = styled.div` - max-width: 1400px; -`; + const DropdownContainer = styled.div` position: relative; @@ -102,16 +100,16 @@ export const Dropdown = forwardRef(({ open, input, handleCloseDropdown }: Dropdo }; return ( - + {open && ( - + <> {filteredCourses.map(({ name, id }, index) => (

{name}

))} -
+ )} -
+ ); }); diff --git a/src/components/SchedulerRow.tsx b/src/components/SchedulerRow.tsx index 8c5a53b..9a04014 100644 --- a/src/components/SchedulerRow.tsx +++ b/src/components/SchedulerRow.tsx @@ -51,7 +51,7 @@ const Classes = styled.div` height: ${({ cellHeight }) => (cellHeight * 2 * 3) / 4}px; padding-left: 10px; text-align: left; - background-color: ${({ groupType }) => (groupType === 'CLASS' ? '#FFDC61' : '#A68820')}; + background-color: ${({ groupType }) => (groupType === 'CLASS' ? '#FFDC61' : '#9ed3ff')}; box-shadow: 9px 9px 8px -2px rgba(0, 0, 0, 0.59); `; @@ -109,7 +109,7 @@ export const SchedulerRow = ({ groups, indexRow, cellTop, cellWidth, cellHeight >

{groups[index].name}

- {groups[index].room} +

{groups[index].room}

- {/* */} +