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 #1

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open
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
28 changes: 1 addition & 27 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1 @@
## The Golden Rule:

🦸 🦸‍♂️ `Stop starting and start finishing.` 🏁

If you work on more than one feature at a time, you are guaranteed to multiply your bugs and your anxiety.

## Making a plan

1. **Make a drawing of your app. Simple "wireframes"**
1. **Look at the drawing and name the HTML elements you'll need to realize your vision**
1. **Look at the drawing and imagine using the app. What _state_ do you need to track?**
1. **For each HTML element ask: Why do I need this? (i.e., "we need div to display the results in")**
1. **Once we know _why_ we need each element, think about how to implement the "Why" as a "How" (i.e., `resultsEl.textContent = newResults`)**
1. **Find all the 'events' (user clicks, form submit, on load etc) in your app. Ask one by one, "What happens when" for each of these events. Does any state change? Does any DOM update?**
1. **Think about how to validate each of your features according to a Definition of Done. (Hint: console.log usually helps here.)**
1. **Consider what features _depend_ on what other features. Use this dependency logic to figure out what order to complete tasks.**

Additional considerations:

- Ask: which of your HTML elements need to be hard coded, and which need to be dynamically generated?
- Consider your data model.
- What kinds of objects (i.e., Dogs, Friends, Todos, etc) will you need?
- What are the key/value pairs?
- What arrays might you need?
- What needs to live in a persistence layer?
- Is there some state we need to initialize?
- Ask: should any of this work be abstracted into functions? (i.e., is the work complicated? can it be reused?)
![](./wireframe.png)
106 changes: 74 additions & 32 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,39 +1,81 @@
<!DOCTYPE html>
<html lang="en">
<head>
<!-- metadata -->
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />

<head>
<!-- metadata -->
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<!-- title and favicon -->
<title></title>

<!-- title and favicon -->
<title>Web App</title>
<link rel="icon" type="image/x-icon" href="assets/alchemy-favicon.png" />
<!-- js -->
<script type="module" src="app.js"></script>

<!-- js -->
<script type="module" src="app.js"></script>
<!-- fonts -->
<!-- see https://fonts.google.com/ -->

<!-- fonts -->
<!-- see https://fonts.google.com/ -->
<!-- css -->
<link rel="stylesheet" href="styles/reset.css" />
<link rel="stylesheet" href="styles/global.css" />
<!-- add link for page specific css -->
</head>

<!-- css -->
<link rel="stylesheet" href="styles/reset.css" />
<link rel="stylesheet" href="styles/global.css" />
<!-- add link for page specific css -->

</head>

<body>
<header>
<img class="logo" src="assets/html_css_js.png" alt="logo">
<h1>Web App</h1>
</header>

<main>

</main>

</body>

</html>
<body>
<header>
<h1>CL</h1>
<section class="selectors">
<div>
<label class="navigation-selector">
<select id="location-dropdown">
<option value="Portland">Portland</option>
<option value="Bellingham">Bellingham</option>
<option value="Bend">Bend</option>
</select>
</label>
</div>
<div>
<label class="county-selector">
<select id="county-dropdown">
<option value="all-portland">All Portland</option>
<option value="washington-co">Washington Co</option>
<option value="multnomah-co">Multnomah Co</option>
</select>
</label>
</div>
<div>
<label class="community-selector">
<select id="community-dropdown">
<option value="community">community</option>
<option value="for sale">for sale</option>
<option value="events">events</option>
</select>
</label>
</div>
</section>
</header>
<main>
<section class="search-function">
<input type="search" id="search-bar" placeholder="search missed connections" />
<button type="submit" id="submit-btn">search</button>
</section>
<section class="filter-options">
<input type="checkbox" id="search-titles" />
<label for="search-titles">search titles only</label>
<input type="checkbox" id="has-image" />
<label for="has-image">has image</label>
<input type="checkbox" id="posted-today" />
<label for="posted-today">posted today</label>
<input type="checkbox" id="bundle-duplicates" />
<label for="bundle-duplicates">bundle duplicates</label>
<input type="checkbox" id="include-nearby" />
<label for="include-nearby">include nearby areas</label>
</section>
<section class="zip-code">
<input type="number" id="miles" placeholder="miles" />
<input type="number" id="zip" placeholder="from zip" />
<button type="submit" id="submit">search</button>
</section>
</main>
</body>
</html>
58 changes: 36 additions & 22 deletions styles/global.css
Original file line number Diff line number Diff line change
@@ -1,35 +1,49 @@
:root {
--background: rgb(224, 234, 247);
--header-background: rgb(254, 251, 245);
--primary-font: Corbel, 'Lucida Grande', 'Lucida Sans Unicode', 'Lucida Sans', 'DejaVu Sans',
'Bitstream Vera Sans', 'Liberation Sans', Verdana, 'Verdana Ref', sans-serif;
}

body {
font-family: var(--primary-font);
background: var(--background);
display: grid;
grid-template-rows: auto 1fr;
font-family: sans-serif;
background-color: white;
}

header {
position: sticky;
top: 0;
padding: 15px;
height: 80px;
background-color: lightgray;
height: 30px;
width: 1fr;
}

.selectors {
grid-template-rows: auto;
display: flex;
align-items: center;
gap: 10px;
margin-left: 35px;
}

background-color: var(--header-background);
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
main {
grid-template-rows: 190px 1000px 1fr;
}

header .logo {
height: 100%;
h1 {
font-size: 16px;
font: 'sans-serif';
color: purple;
margin: 3px 5px 0px;
}

main {
padding: 20px;
.search-function {
position: absolute;
top: 200px;
left: 575px;
padding: 0 3px 0 8px;
}

.filter-options {
display: flex;
margin: 25px;
grid-template-rows: auto;
}

.search-bar {
height: 100px;
}

.button {
height: 100px;
}
Binary file added wireframe.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.