Skip to content
71 changes: 60 additions & 11 deletions Form-Controls/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,71 @@
<title>My form exercise</title>
<meta name="description" content="" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet" href="style.css">
</head>
<body>
<header>
<h1>Product Pick</h1>
</header>

<main>
<h1>Product Pick</h1>
<form>
<!-- write your html here-->
<!--
try writing out the requirements first as comments
this will also help you fill in your PR message later-->

<label for="name">Customer Name:</label>

<input
type="text"
id="name"
name="name"
required
pattern=".*\S.{1,}.*"
>
<br><br>
<label for="email">Email Address:</label>

<input
type="email"
id="email"
name="email"
required
>
<br><br>
<label for="colour">T-Shirt Colour:</label>

<select id="colour" name="colour" required>
<option value="">Select a colour</option>
<option value="black">Black</option>
<option value="white">White</option>
<option value="blue">Yellow</option>

</select>
<br><br>
<p>T-Shirt Size:</p>
<br>
<div class="sizes">

<input type="radio" id="xs" name="size" value="XS" required>
<label for="xs">XS</label>

<input type="radio" id="s" name="size" value="S">
<label for="s">S</label>

<input type="radio" id="m" name="size" value="M">
<label for="m">M</label>

<input type="radio" id="l" name="size" value="L">
<label for="l">L</label>

<input type="radio" id="xl" name="size" value="XL">
<label for="xl">XL</label>

<input type="radio" id="xxl" name="size" value="XXL">
<label for="xxl">XXL</label>

</div>
<br><br>
<button type="submit">Place Order</button>
</form>
<p>By Dan Mears</p>
</main>
<footer>
<!-- change to your name-->
<p>By HOMEWORK SOLUTION</p>
</footer>

</body>
</html>
110 changes: 110 additions & 0 deletions Form-Controls/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
/* Import cool Google Font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');

/* Reset default spacing */
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}

/* Page styling */
body {
font-family: 'Poppins', sans-serif;
background: #f4f4f4;
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
color: #444;
}

/* Main form container */
main {
background: white;
padding: 40px;
border-radius: 20px;
width: 400px;
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Heading */
h1 {
text-align: center;
margin-bottom: 25px;
color: #ff4f87;
}

/* Labels */
label,
p {
font-weight: 500;
margin-bottom: 8px;
display: block;
}

/* Text inputs and dropdown */
input[type="text"],
input[type="email"],
select {
width: 100%;
padding: 12px;
border: 2px solid #ddd;
border-radius: 12px;
margin-top: 6px;
margin-bottom: 20px;
font-size: 14px;
transition: 0.3s;
}

/* Input focus effect */
input[type="text"]:focus,
input[type="email"]:focus,
select:focus {
border-color: #ff4f87;
outline: none;
}

/* Radio buttons section */
input[type="radio"] {
margin-right: 5px;
margin-left: 10px;
}

/* Submit button */
button {
width: 100%;
padding: 14px;
border: none;
border-radius: 12px;
background: #ff4f87;
color: white;
font-size: 16px;
font-weight: 600;
cursor: pointer;
transition: 0.3s;
}

/* Button hover effect */
button:hover {
background: #e63e74;
}

/* main */
main {
text-align: center;
}
/* Shirt sizes in one row */
.sizes {
display: flex;
gap: 1px;
font-size: 13px;
align-items: center;
flex-wrap: wrap;
}

/* Fix radio labels */
.sizes label {
display: inline;
margin-right: 10px;
}
65 changes: 51 additions & 14 deletions Wireframe/index.html
Original file line number Diff line number Diff line change
@@ -1,33 +1,70 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Wireframe</title>
<title>README, Wireframes and Git Branches</title>
<link rel="stylesheet" href="style.css" />
</head>
<body>
<header>
<h1>Wireframe</h1>
<p>
This is the default, provided code and no changes have been made yet.
</p>
<h1>README, Wireframes and Git Branches</h1>
<p>A simple guide to three important web development concepts.</p>
</header>
<main>
<article>
<img src="placeholder.svg" alt="" />
<h2>Title</h2>
<img
src="https://myscope.training/images/RDM-module/figure_22.jpg"
alt="README file illustration"
/>
<h2>What is the purpose of a README file?</h2>
<p>
Lorem ipsum dolor sit amet consectetur adipisicing elit. Quisquam,
voluptates. Quisquam, voluptates.
A README file explains what a project is, how it works, and how
someone can use it. It often includes setup instructions, features,
and important notes for developers.
</p>
<a href="">Read more</a>
<a
href="https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-readmes"
>Read more</a
>
</article>

<article>
<img
src="https://www.oursky.com/images/blogs/86256bf2c9_6799482b54769870a1e9c883_1.jpeg"
alt="Wireframe file illustration"
/>
<h2>What is the purpose of a wireframe?</h2>
<p>
A wireframe is a simple plan for a webpage or app. It shows where
content, images, buttons, and sections will go before the final design
is created.
</p>
<a
href="https://github.com/dwyl/learn-wireframing/blob/master/README.md"
>Read more</a
>
</article>

<article>
<img
src="https://www.sqlshack.com/wp-content/uploads/2020/09/git-branch-and-timelines.png"
alt="Git branch file illustration"
/>
<h2>What is a branch in Git?</h2>
<p>
A branch in Git is a separate version of a project. It lets developers
work on new features or fixes without changing the main version of the
code.
</p>
<a
href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches"
>Read more</a
>
</article>
</main>
<footer>
<p>
This is the default, provided code and no changes have been made yet.
</p>
<p>Created as a beginner guide to key web development terms.</p>
</footer>
</body>
</html>
41 changes: 32 additions & 9 deletions Wireframe/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,23 @@ As well as useful links to learn more */
====== Design Palette ====== */
:root {
--paper: oklch(7 0 0);
--ink: color-mix(in oklab, var(--color) 5%, black);
--ink: blue;
--font: 100%/1.5 system-ui;
--space: clamp(6px, 6px + 2vw, 15px);
--line: 1px solid;
--container: 1280px;
}
/* ====== Base Elements ======
General rules for basic HTML elements in any context */
header {
text-align: center;
}
/* Futuristic font */
body {
background: var(--paper);
color: var(--ink);
font: var(--font);
font-family: "Orbitron", "Rajdhani", "Segoe UI", sans-serif;
}
a {
padding: var(--space);
Expand All @@ -39,7 +44,10 @@ a {
img,
svg {
width: 100%;
height: 250px;
object-fit: cover;
border: 3px solid blue;
border-radius: 20px;
}
/* ====== Site Layout ======
Setting the overall rules for page regions
Expand All @@ -50,9 +58,11 @@ main {
margin: 0 auto calc(var(--space) * 4) auto;
}
footer {
position: fixed;
bottom: 0;
text-align: center;
font-size: 0.8rem;
color: var(--ink);
margin-top: 20px;
padding: 10px;
}
/* ====== Articles Grid Layout ====
Setting the rules for how articles are placed in the main element.
Expand All @@ -76,14 +86,27 @@ Keeping things orderly and separate is the key to good, simple CSS.
*/
article {
border: var(--line);
border-radius: 20px;
box-shadow: 0 0 15px blue;
padding-bottom: var(--space);
text-align: left;
display: grid;
grid-template-columns: var(--space) 1fr var(--space);
> * {
grid-column: 2/3;
}
> img {
grid-column: span 3;
}
}
article > * {
grid-column: 2 / 3;
}
article > img {
grid-column: 2 / 3;
margin-top: var(--space);
}
> img {
grid-column: 2 / 3;
margin-top: var(--space);
}
h1,
h2,
a {
text-transform: uppercase;
letter-spacing: 1px;
}
Loading