Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev main #14

Merged
merged 15 commits into from
Jun 4, 2021
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"private": true,
"homepage": "https://demos.creative-tim.com/material-tailwind-dashboard-react/#/",
"dependencies": {
"@material-tailwind/react": "0.3.2",
"@material-tailwind/react": "^0.3.3",
"@react-google-maps/api": "^2.1.1",
"@testing-library/jest-dom": "^5.11.4",
"@testing-library/react": "^11.1.0",
Expand Down
33 changes: 26 additions & 7 deletions src/assets/styles/tailwind.css
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,14 @@ video {
margin-bottom: 4rem;
}.mt-14{
margin-top: 3.5rem;
}.mb-0{
margin-bottom: 0px;
}.mt-96{
margin-top: 24rem;
}.mt-\[32rem\]{
margin-top: 32rem;
}.mb-8{
margin-bottom: 2rem;
}.block{
display: block;
}.inline-block{
Expand All @@ -471,6 +479,12 @@ video {
height: auto;
}.h-\[600px\]{
height: 600px;
}.h-72{
height: 18rem;
}.h-56{
height: 14rem;
}.h-40{
height: 10rem;
}.min-h-full{
min-height: 100%;
}.w-full{
Expand Down Expand Up @@ -553,10 +567,15 @@ video {
}.bg-white{
--tw-bg-opacity: 1;
background-color: rgba(255, 255, 255, var(--tw-bg-opacity));
}.bg-red-500{
--tw-bg-opacity: 1;
background-color: rgba(239, 68, 68, var(--tw-bg-opacity));
}.bg-gradient-to-tr{
background-image: linear-gradient(to top right, var(--tw-gradient-stops));
}.p-4{
padding: 1rem;
}.p-0{
padding: 0px;
}.py-6{
padding-top: 1.5rem;
padding-bottom: 1.5rem;
Expand All @@ -566,6 +585,9 @@ video {
}.px-16{
padding-left: 4rem;
padding-right: 4rem;
}.px-0{
padding-left: 0px;
padding-right: 0px;
}.px-2{
padding-left: 0.5rem;
padding-right: 0.5rem;
Expand All @@ -581,9 +603,6 @@ video {
}.px-6{
padding-left: 1.5rem;
padding-right: 1.5rem;
}.px-0{
padding-left: 0px;
padding-right: 0px;
}.pt-8{
padding-top: 2rem;
}.pr-4{
Expand Down Expand Up @@ -652,18 +671,18 @@ video {
transition-duration: 150ms;
}.duration-300{
transition-duration: 300ms;
}.tippy-box[data-placement^=top]>.tippy-svg-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-svg-arrow:after,.tippy-box[data-placement^=top]>.tippy-svg-arrow>svg{top:16px;transform:rotate(180deg)}.tippy-box[data-placement^=bottom]>.tippy-svg-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-svg-arrow>svg{bottom:16px}.tippy-box[data-placement^=left]>.tippy-svg-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-svg-arrow:after,.tippy-box[data-placement^=left]>.tippy-svg-arrow>svg{transform:rotate(90deg);top:calc(50% - 3px);left:11px}.tippy-box[data-placement^=right]>.tippy-svg-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-svg-arrow:after,.tippy-box[data-placement^=right]>.tippy-svg-arrow>svg{transform:rotate(-90deg);top:calc(50% - 3px);right:11px}.tippy-svg-arrow{width:16px;height:16px;fill:#333;text-align:initial}.tippy-svg-arrow,.tippy-svg-arrow>svg{position:absolute}.tippy-box[data-animation=scale][data-placement^=top]{transform-origin:bottom}.tippy-box[data-animation=scale][data-placement^=bottom]{transform-origin:top}.tippy-box[data-animation=scale][data-placement^=left]{transform-origin:right}.tippy-box[data-animation=scale][data-placement^=right]{transform-origin:left}.tippy-box[data-animation=scale][data-state=hidden]{transform:scale(.5);opacity:0}.tippy-box[data-animation=shift-away][data-state=hidden]{opacity:0}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=top]{transform:translateY(10px)}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=bottom]{transform:translateY(-10px)}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=left]{transform:translateX(10px)}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=right]{transform:translateX(-10px)}/*! tailwindcss v2.1.1 | MIT License | https://tailwindcss.com *//*! modern-normalize v1.0.0 | MIT License | https://github.com/sindresorhus/modern-normalize *//*
}.tippy-box[data-placement^=top]>.tippy-svg-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-svg-arrow:after,.tippy-box[data-placement^=top]>.tippy-svg-arrow>svg{top:16px;transform:rotate(180deg)}.tippy-box[data-placement^=bottom]>.tippy-svg-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-svg-arrow>svg{bottom:16px}.tippy-box[data-placement^=left]>.tippy-svg-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-svg-arrow:after,.tippy-box[data-placement^=left]>.tippy-svg-arrow>svg{transform:rotate(90deg);top:calc(50% - 3px);left:11px}.tippy-box[data-placement^=right]>.tippy-svg-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-svg-arrow:after,.tippy-box[data-placement^=right]>.tippy-svg-arrow>svg{transform:rotate(-90deg);top:calc(50% - 3px);right:11px}.tippy-svg-arrow{width:16px;height:16px;fill:#333;text-align:initial}.tippy-svg-arrow,.tippy-svg-arrow>svg{position:absolute}.tippy-box[data-animation=scale][data-placement^=top]{transform-origin:bottom}.tippy-box[data-animation=scale][data-placement^=bottom]{transform-origin:top}.tippy-box[data-animation=scale][data-placement^=left]{transform-origin:right}.tippy-box[data-animation=scale][data-placement^=right]{transform-origin:left}.tippy-box[data-animation=scale][data-state=hidden]{transform:scale(.5);opacity:0}.tippy-box[data-animation=shift-away][data-state=hidden]{opacity:0}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=top]{transform:translateY(10px)}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=bottom]{transform:translateY(-10px)}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=left]{transform:translateX(10px)}.tippy-box[data-animation=shift-away][data-state=hidden][data-placement^=right]{transform:translateX(-10px)}/*! tailwindcss v2.1.2 | MIT License | https://tailwindcss.com *//*! modern-normalize v1.1.0 | MIT License | https://github.com/sindresorhus/modern-normalize *//*
Document
========
*//**
Use a better box model (opinionated).
*/*,
*::before,
*::after {
::before,
::after {
box-sizing: border-box;
}/**
Use a more readable tab size (opinionated).
*/:root {
*/html {
-moz-tab-size: 4;
tab-size: 4;
}/**
Expand Down
2 changes: 1 addition & 1 deletion src/components/ChartBar.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export default function ChartBar() {
}, []);
return (
<Card>
<CardHeader color="red" contentPosition="left">
<CardHeader color="pink" contentPosition="left">
<h6 className="uppercase text-gray-200 text-xs font-medium">
Overview
</h6>
Expand Down
4 changes: 2 additions & 2 deletions src/components/PageVisitsCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ import Button from '@material-tailwind/react/Button';
export default function PageVisitsCard() {
return (
<Card>
<CardHeader color="teal" contentPosition="none">
<CardHeader color="blue" contentPosition="none">
<div className="w-full flex items-center justify-between">
<h2 className="text-white text-2xl">Page Visits</h2>
<Button
color="transparent"
buttonType="link"
size="lg"
ripple="light"
style={{ padding: 0 }}
>
See More
</Button>
Expand Down
2 changes: 1 addition & 1 deletion src/components/ProfileCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export default function ProfileCard() {
</div>
</div>
</div>
<div className="text-center mt-8">
<div className="text-center">
<H5 color="gray">John Smith</H5>
<div className="mt-0 mb-2 text-gray-700 flex items-center justify-center gap-2">
<Icon name="place" size="xl" />
Expand Down
4 changes: 2 additions & 2 deletions src/components/SettingsForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ import Textarea from '@material-tailwind/react/Textarea';
export default function SettingsForm() {
return (
<Card>
<CardHeader color="purple" size="lg" contentPosition="none">
<CardHeader color="purple" contentPosition="none">
<div className="w-full flex items-center justify-between">
<h2 className="text-white text-2xl">My Account</h2>
<Button
color="transparent"
buttonType="link"
size="lg"
ripple="light"
style={{ padding: 0 }}
>
Settings
</Button>
Expand Down
2 changes: 1 addition & 1 deletion src/components/Sidebar.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ export default function Sidebar() {
className="flex items-center gap-4 text-sm font-light py-3"
>
<Icon name="account_circle" size="2xl" />
Progile Page
Profile Page
</a>
</li>
</ul>
Expand Down
8 changes: 3 additions & 5 deletions src/components/StatusCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ export default function StatusCard({
<div className="px-4 mb-10">
<Card>
<CardRow>
<CardHeader color={color} size="lg" iconOnly>
<Icon name={icon} size="5xl" color="white" />
<CardHeader color={color} iconOnly className="mb-0">
<Icon name={icon} size="3xl" color="white" />
</CardHeader>

<CardStatus title={title} amount={amount} />
Expand All @@ -31,9 +31,7 @@ export default function StatusCard({
color={percentageColor}
date={date}
>
<div className="inline-block align-middle">
<Icon color={percentageColor} name={percentageIcon} />
</div>
<Icon color={percentageColor} name={percentageIcon} />
</CardStatusFooter>
</Card>
</div>
Expand Down
26 changes: 5 additions & 21 deletions src/components/TableCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import Team4 from 'assets/img/team-4-470x470.png';
export default function CardTable() {
return (
<Card>
<CardHeader color="purple" size="lg" contentPosition="left">
<CardHeader color="purple" contentPosition="left">
<h2 className="text-white text-2xl">Card Table</h2>
</CardHeader>
<CardBody>
Expand Down Expand Up @@ -81,11 +81,7 @@ export default function CardTable() {
</div>
</th>
<th className="border-b border-gray-200 align-middle font-light text-sm whitespace-nowrap px-2 py-4 text-left">
<Progress
color="red"
value="60"
percentage
/>
<Progress color="red" value="60" />
</th>
</tr>
<tr>
Expand Down Expand Up @@ -132,11 +128,7 @@ export default function CardTable() {
</div>
</th>
<th className="border-b border-gray-200 align-middle font-light text-sm whitespace-nowrap px-2 py-4 text-left">
<Progress
color="green"
value="100"
percentage
/>
<Progress color="green" value="100" />
</th>
</tr>
<tr>
Expand Down Expand Up @@ -183,11 +175,7 @@ export default function CardTable() {
</div>
</th>
<th className="border-b border-gray-200 align-middle font-light text-sm whitespace-nowrap px-2 py-4 text-left">
<Progress
color="teal"
value="90"
percentage
/>
<Progress color="teal" value="90" />
</th>
</tr>
<tr>
Expand Down Expand Up @@ -234,11 +222,7 @@ export default function CardTable() {
</div>
</th>
<th className="border-b border-gray-200 align-middle font-light text-sm whitespace-nowrap px-2 py-4 text-left">
<Progress
color="green"
value="100"
percentage
/>
<Progress color="green" value="100" />
</th>
</tr>
</tbody>
Expand Down
2 changes: 1 addition & 1 deletion src/components/TrafficCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export default function TrafficCard() {
color="transparent"
buttonType="link"
size="lg"
ripple="light"
style={{ padding: 0 }}
>
See More
</Button>
Expand Down
36 changes: 19 additions & 17 deletions src/pages/Dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,26 @@ import TrafficCard from 'components/TrafficCard';
export default function Dashboard() {
return (
<>
<div className="bg-light-blue-500 pt-14 pb-28 px-3 md:px-8 h-auto">
<div className="bg-light-blue-500 px-3 md:px-8 h-40" />

<div className="px-3 md:px-8 -mt-24">
<div className="container mx-auto max-w-full">
<div className="grid grid-cols-1 xl:grid-cols-5">
<div className="xl:col-start-1 xl:col-end-4 px-4 mb-14">
<ChartLine />
</div>
<div className="xl:col-start-4 xl:col-end-6 px-4 mb-14">
<ChartBar />
</div>
</div>
</div>
</div>

<div className="px-3 md:px-8">
<div className="container mx-auto max-w-full">
<div className="grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-4">
<div className="grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-4 mb-4">
<StatusCard
color="red"
color="pink"
icon="trending_up"
title="Traffic"
amount="350,897"
Expand Down Expand Up @@ -41,7 +56,7 @@ export default function Dashboard() {
date="Since yesterday"
/>
<StatusCard
color="teal"
color="blue"
icon="poll"
title="Performance"
amount="49,65%"
Expand All @@ -54,19 +69,6 @@ export default function Dashboard() {
</div>
</div>

<div className="px-3 md:px-8 h-auto -mt-24">
<div className="container mx-auto max-w-full">
<div className="grid grid-cols-1 xl:grid-cols-5">
<div className="xl:col-start-1 xl:col-end-4 px-4 mb-14">
<ChartLine />
</div>
<div className="xl:col-start-4 xl:col-end-6 px-4 mb-14">
<ChartBar />
</div>
</div>
</div>
</div>

<div className="px-3 md:px-8 h-auto">
<div className="container mx-auto max-w-full">
<div className="grid grid-cols-1 xl:grid-cols-5">
Expand Down
4 changes: 2 additions & 2 deletions src/pages/Maps.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default function Dashboard() {
<div className="container mx-auto max-w-full">
<div className="grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-4">
<StatusCard
color="red"
color="pink"
icon="trending_up"
title="Traffic"
amount="350,897"
Expand Down Expand Up @@ -38,7 +38,7 @@ export default function Dashboard() {
date="Since yesterday"
/>
<StatusCard
color="teal"
color="blue"
icon="poll"
title="Performance"
amount="49,65%"
Expand Down
4 changes: 2 additions & 2 deletions src/pages/Settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export default function Dashboard() {
<div className="container mx-auto max-w-full">
<div className="grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-4">
<StatusCard
color="red"
color="pink"
icon="trending_up"
title="Traffic"
amount="350,897"
Expand Down Expand Up @@ -39,7 +39,7 @@ export default function Dashboard() {
date="Since yesterday"
/>
<StatusCard
color="teal"
color="blue"
icon="poll"
title="Performance"
amount="49,65%"
Expand Down
4 changes: 2 additions & 2 deletions src/pages/Tables.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default function Dashboard() {
<div className="container mx-auto max-w-full">
<div className="grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-4">
<StatusCard
color="red"
color="pink"
icon="trending_up"
title="Traffic"
amount="350,897"
Expand Down Expand Up @@ -38,7 +38,7 @@ export default function Dashboard() {
date="Since yesterday"
/>
<StatusCard
color="teal"
color="blue"
icon="poll"
title="Performance"
amount="49,65%"
Expand Down
Loading