Initial commit

parents
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
node_modules
dist
dist-ssr
*.local
# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
\ No newline at end of file
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/x-icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Burger Builder</title>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>
This diff is collapsed.
{
"name": "burger-builder-template",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"dev": "vite",
"build": "tsc && vite build",
"preview": "vite preview"
},
"dependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"@types/react": "^18.0.28",
"@types/react-dom": "^18.0.11",
"@vitejs/plugin-react": "^3.1.0",
"typescript": "^4.9.3",
"vite": "^4.2.0"
}
}
import React from 'react';
function App() {
return null;
}
export default App
.BuildControl {
display: flex;
justify-content: space-between;
align-items: center;
margin: 5px 0;
}
.BuildControl button {
display: block;
font: inherit;
padding: 5px;
margin: 0 5px;
width: 80px;
border: 1px solid #aa6817;
cursor: pointer;
outline: none;
}
.BuildControl button:disabled {
background-color: #ac9980;
border: 1px solid #7e7365;
color: #ccc;
cursor: default;
}
.BuildControl button:hover:disabled {
background-color: #ac9980;
color: #ccc;
cursor: not-allowed;
}
.Label {
padding: 10px;
font-weight: bold;
width: 80px;
}
.BuildControl .Less {
background-color: #D39952;
color: white;
}
.BuildControl .More {
background-color: #8f5e1e;
color: white;
}
.BuildControl .Less:hover, .BuildControl .Less:active {
background-color: #daa972;
color: white;
}
.BuildControl .More:hover, .BuildControl .More:active {
background-color: #99703f;
color: white;
}
import React from 'react';
import './BuildControl.css';
interface Props {}
const BuildControl = (props: Props) => {
return null;
}
export default BuildControl;
.BuildControls {
width: 100%;
background-color: #CF8F2E;
display: flex;
flex-flow: column;
align-items: center;
box-shadow: 0 2px 1px #ccc;
margin: auto;
padding: 10px 0;
}
import React from 'react';
import './BuildControls.css';
interface Props {}
const BuildControls = (props: Props) => {
return null;
}
export default BuildControls;
.Burger {
width: 100%;
margin: auto;
height: 250px;
overflow: auto;
text-align: center;
font-weight: bold;
font-size: 1.2rem;
}
@media (min-width: 1000px) and (min-height: 700px) {
.Burger {
width: 700px;
height: 600px;
}
}
@media (min-width: 500px) and (min-height: 401px) {
.Burger {
width: 450px;
height: 300px;
}
}
@media (min-width: 500px) and (max-height: 400px) {
.Burger {
width: 350px;
height: 200px;
}
}
import React from 'react';
import './Burger.css';
interface Props {}
const Burger = (props: Props) => {
return null;
}
export default Burger;
.BreadBottom {
height: 13%;
width: 80%;
background: linear-gradient(#F08E4A, #e27b36);
border-radius: 0 0 30px 30px;
box-shadow: inset -15px 0 #c15711;
margin: 2% auto;
}
.BreadTop {
height: 20%;
width: 80%;
background: linear-gradient(#bc581e, #e27b36);
border-radius: 50% 50% 0 0;
box-shadow: inset -15px 0 #c15711;
margin: 2% auto;
position: relative;
}
.Seeds1 {
width: 10%;
height: 15%;
position: absolute;
background-color: white;
left: 30%;
top: 50%;
border-radius: 40%;
transform: rotate(-20deg);
box-shadow: inset -2px -3px #c9c9c9;
}
.Seeds1:after {
content: "";
width: 100%;
height: 100%;
position: absolute;
background-color: white;
left: -170%;
top: -260%;
border-radius: 40%;
transform: rotate(60deg);
box-shadow: inset -1px 2px #c9c9c9;
}
.Seeds1:before {
content: "";
width: 100%;
height: 100%;
position: absolute;
background-color: white;
left: 180%;
top: -50%;
border-radius: 40%;
transform: rotate(60deg);
box-shadow: inset -1px -3px #c9c9c9;
}
.Seeds2 {
width: 10%;
height: 15%;
position: absolute;
background-color: white;
left: 64%;
top: 50%;
border-radius: 40%;
transform: rotate(10deg);
box-shadow: inset -3px 0 #c9c9c9;
}
.Seeds2:before {
content: "";
width: 100%;
height: 100%;
position: absolute;
background-color: white;
left: 150%;
top: -130%;
border-radius: 40%;
transform: rotate(90deg);
box-shadow: inset 1px 3px #c9c9c9;
}
.Meat {
width: 80%;
height: 8%;
background: linear-gradient(#7f3608, #702e05);
margin: 2% auto;
border-radius: 15px;
}
.Cheese {
width: 90%;
height: 4.5%;
margin: 2% auto;
background: linear-gradient(#f4d004, #d6bb22);
border-radius: 20px;
}
.Salad {
width: 85%;
height: 7%;
margin: 2% auto;
background: linear-gradient(#228c1d, #91ce50);
border-radius: 20px;
}
.Bacon {
width: 80%;
height: 3%;
background: linear-gradient(#bf3813, #c45e38);
margin: 2% auto;
}
import React from 'react';
import './Ingredient.css';
interface Props {}
const Ingredient = (props: Props) => {
return null;
}
export default Ingredient;
import React from 'react';
const BurgerBuilder = () => {
return (
<>
<div>Burger will be here</div>
<div>Build controls will be here</div>
</>
)
}
export default BurgerBuilder;
:root {
font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
line-height: 1.5;
font-weight: 400;
color-scheme: light dark;
color: rgba(255, 255, 255, 0.87);
background-color: #242424;
font-synthesis: none;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
-webkit-text-size-adjust: 100%;
}
a {
font-weight: 500;
color: #646cff;
text-decoration: inherit;
}
a:hover {
color: #535bf2;
}
body {
margin: 0;
min-width: 320px;
min-height: 100vh;
}
h1 {
font-size: 3.2em;
line-height: 1.1;
}
button {
border-radius: 8px;
border: 1px solid transparent;
padding: 0.6em 1.2em;
font-size: 1em;
font-weight: 500;
font-family: inherit;
background-color: #1a1a1a;
cursor: pointer;
transition: border-color 0.25s;
}
button:hover {
border-color: #646cff;
}
button:focus,
button:focus-visible {
outline: 4px auto -webkit-focus-ring-color;
}
@media (prefers-color-scheme: light) {
:root {
color: #213547;
background-color: #ffffff;
}
a:hover {
color: #747bff;
}
button {
background-color: #f9f9f9;
}
}
export type IngredientNames = 'salad' | 'cheese' | 'meat' | 'bacon';
export type Ingredients = {
[key in IngredientNames]: number;
}
\ No newline at end of file
import React from 'react'
import ReactDOM from 'react-dom/client'
import App from './App'
import './index.css'
ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
<React.StrictMode>
<App />
</React.StrictMode>,
)
/// <reference types="vite/client" />
{
"compilerOptions": {
"target": "ESNext",
"useDefineForClassFields": true,
"lib": ["DOM", "DOM.Iterable", "ESNext"],
"allowJs": false,
"skipLibCheck": true,
"esModuleInterop": false,
"allowSyntheticDefaultImports": true,
"strict": true,
"forceConsistentCasingInFileNames": true,
"module": "ESNext",
"moduleResolution": "Node",
"resolveJsonModule": true,
"isolatedModules": true,
"noEmit": true,
"jsx": "react-jsx"
},
"include": ["src"],
"references": [{ "path": "./tsconfig.node.json" }]
}
{
"compilerOptions": {
"composite": true,
"module": "ESNext",
"moduleResolution": "Node",
"allowSyntheticDefaultImports": true
},
"include": ["vite.config.ts"]
}
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
})
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment