Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,24 @@
content="A smart shopping list that learns your purchase habits and makes suggestions, so you don't forget to buy what's important."
/>
<link rel="icon" type="image/svg+xml" href="/src/favicon.ico" />

<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css"
integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN"
crossorigin="anonymous"
/>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PRAISE: Nice job importing the Google Font using the link element. The other way(s) I can remember to import Google Fonts can make things ....non-non-heinous!

<link
href="https://fonts.googleapis.com/css2?family=Nunito:ital,wght@0,200..1000;1,200..1000&display=swap"
rel="stylesheet"
/>
<meta name="color-scheme" content="dark light" />
<title>GrocerEase</title>
<script type="module" src="/src/index.tsx" defer></script>
</head>

<body>
<div id="root"></div>
</body>
Expand Down
195 changes: 104 additions & 91 deletions src/index.scss
Original file line number Diff line number Diff line change
@@ -1,103 +1,116 @@
@import "~bootstrap/scss/bootstrap";

:root {
--color-black: hsla(220, 13%, 18%, 1);
--color-gray-dark: hsla(220, 13%, 25%, 1);
--color-white: hsla(220, 13%, 98%, 1);
--color-gray-light: hsla(220, 13%, 94%, 1);
--color-emerald-green: hsla(168, 92%, 25%, 1);
--color-vermillion-green: hsla(168, 92%, 43%, 1);
--color-cobalt-blue: hsla(215, 100%, 34%, 1);
--color-pastel-blue: hsla(215, 100%, 73%, 1);
--color-red: hsl(0, 68%, 42%);
// :root {
// --color-black: hsla(220, 13%, 18%, 1);
// --color-gray-dark: hsla(220, 13%, 25%, 1);
// --color-white: hsla(220, 13%, 98%, 1);
// --color-gray-light: hsla(220, 13%, 94%, 1);
// --color-emerald-green: hsla(168, 92%, 25%, 1);
// --color-vermillion-green: hsla(168, 92%, 43%, 1);
// --color-cobalt-blue: hsla(215, 100%, 34%, 1);
// --color-pastel-blue: hsla(215, 100%, 73%, 1);
// --color-red: hsl(0, 68%, 42%);

--color-accent: var(--color-pastel-blue);
--color-bg: var(--color-black);
--color-border: hsla(220, 13%, 32%, 1);
--color-error: var(--color-red);
--color-text: var(--color-white);
// @import "~bootstrap/scss/bootstrap";

/**
* Set the value of 1rem to 10px to make relative units
* easier to work with.
* (The default is 16px. 16 * 62.5% = 10)
*/
font-size: 62.5%;
}
// :root {
// --color-black: hsla(220, 13%, 18%, 1);
// --color-gray-dark: hsla(220, 13%, 25%, 1);
// --color-white: hsla(220, 13%, 98%, 1);
// --color-gray-light: hsla(220, 13%, 94%, 1);
// --color-emerald-green: hsla(168, 92%, 25%, 1);
// --color-vermillion-green: hsla(168, 92%, 43%, 1);
// --color-cobalt-blue: hsla(215, 100%, 34%, 1);
// --color-pastel-blue: hsla(215, 100%, 73%, 1);
// --color-red: hsl(0, 68%, 42%);

@media screen and (prefers-color-scheme: light) {
:root {
--color-accent: var(--color-cobalt-blue);
--color-bg: var(--color-white);
--color-border: hsla(220, 13%, 78%, 1);
--color-text: var(--color-black);
}
}

:root.theme-light {
--color-accent: var(--color-cobalt-blue);
--color-bg: var(--color-white);
--color-border: hsla(220, 13%, 78%, 1);
--color-text: var(--color-black);
}
// --color-accent: var(--color-pastel-blue);
// --color-bg: var(--color-black);
// --color-border: hsla(220, 13%, 32%, 1);
// --color-error: var(--color-red);
// --color-text: var(--color-white);

*,
*::after,
*::before {
box-sizing: border-box;
}
// /**
// * Set the value of 1rem to 10px to make relative units
// * easier to work with.
// * (The default is 16px. 16 * 62.5% = 10)
// */
// font-size: 62.5%;
// }

body {
background-color: var(--color-bg);
color: var(--color-text);
font-family:
-apple-system,
BlinkMacSystemFont,
avenir next,
avenir,
segoe ui,
helvetica neue,
helvetica,
Ubuntu,
roboto,
noto,
arial,
sans-serif;
font-size: 1.8rem;
/** Make sure the app fills the height of the screen. */
height: 100dvh;
line-height: 1.4;
margin: 0;
// @media screen and (prefers-color-scheme: light) {
// :root {
// --color-accent: var(--color-cobalt-blue);
// --color-bg: var(--color-white);
// --color-border: hsla(220, 13%, 78%, 1);
// --color-text: var(--color-black);
// }
// }

-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
// :root.theme-light {
// --color-accent: var(--color-cobalt-blue);
// --color-bg: var(--color-white);
// --color-border: hsla(220, 13%, 78%, 1);
// --color-text: var(--color-black);
// }

code {
--color-bg: var(--color-gray-dark);
--color-text: var(--color-accent);
// *,
// *::after,
// *::before {
// box-sizing: border-box;
// }

background-color: var(--color-bg);
border-radius: 4px;
color: var(--color-text);
display: inline-block;
font-family:
Menlo,
Consolas,
Monaco,
Liberation Mono,
Lucida Console,
monospace;
font-size: 0.9em;
padding: 2px 2px;
}
// body {
// background-color: var(--color-bg);
// color: var(--color-text);
// font-family:
// -apple-system,
// BlinkMacSystemFont,
// avenir next,
// avenir,
// segoe ui,
// helvetica neue,
// helvetica,
// Ubuntu,
// roboto,
// noto,
// arial,
// sans-serif;
// font-size: 1.8rem;
// /** Make sure the app fills the height of the screen. */
// height: 100dvh;
// line-height: 1.4;
// margin: 0;

@media screen and (prefers-color-scheme: light) {
code {
--color-bg: var(--color-gray-light);
}
}
// -webkit-font-smoothing: antialiased;
// -moz-osx-font-smoothing: grayscale;
// }

:root.theme-light code {
--color-bg: var(--color-gray-light);
}
// code {
// --color-bg: var(--color-gray-dark);
// --color-text: var(--color-accent);

// background-color: var(--color-bg);
// border-radius: 4px;
// color: var(--color-text);
// display: inline-block;
// font-family:
// Menlo,
// Consolas,
// Monaco,
// Liberation Mono,
// Lucida Console,
// monospace;
// font-size: 0.9em;
// padding: 2px 2px;
// }

// @media screen and (prefers-color-scheme: light) {
// code {
// --color-bg: var(--color-gray-light);
// }
// }

// :root.theme-light code {
// --color-bg: var(--color-gray-light);
// }
4 changes: 3 additions & 1 deletion src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ import { createRoot } from "react-dom/client";
import { BrowserRouter as Router } from "react-router-dom";
import { App } from "./App";

import "./index.scss";
import "bootstrap/dist/css/bootstrap.min.css";
import "./styles/global.scss";
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: is this just the base styling of the app basically?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, basically.



const root = createRoot(document.getElementById("root") as HTMLElement);
root.render(
Expand Down
7 changes: 3 additions & 4 deletions src/styles/_variables.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
// ====== COLOURS ========
$primary-blue: #e3f2fd;
$secondary-blue: #2d4b77;
$white: #fff;
$grey: #525252;
$primary-beige: #f1e6cc;
$primary-blue: #3f6476;
$secondary-blue: #001f3f;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

non-blocking because I realizes I don't remember if the 3rd blue is used at all but there is one more color in the design incase we want to add it in this push

#356481

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PRAISE: Three colors are good to start with (some palette websites generate palettes of four, five or more colors)! I like how we are getting rid of white!

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I didn't see the fourth colour used in any of the elements, so didn't add it in. But we can definitely add that later on if needed.

9 changes: 9 additions & 0 deletions src/styles/global.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
@import "../styles/variables.scss";

body {
font-family: "Nunito", sans-serif;
font-optical-sizing: auto;
font-weight: 400;
font-style: normal;
background-color: $primary-beige;
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PRAISE: Ooooh! The start of a style sheet--one of the things I like about SCSS!