-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
103 lines (97 loc) · 5.36 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.3.0/css/all.min.css" integrity="sha512-SzlrxWUlpfuzQ+pcUCosxcglQRNAq/DZjVsC0lE40xsADsfeQoEypE+enwcOiGjk/bSuGGKHEyjSoQ1zVisanQ==" crossorigin="anonymous" referrerpolicy="no-referrer" />
<link rel="stylesheet" href="style.css">
<title>myshadow</title>
</head>
<body>
<div class="main">
<header>
<nav class="navbar">
<h1 class="nav-logo"> <i class="fa-solid fa-bolt-lightning"></i> shadow</h1>
<button class="learn-button">learn box-shadow</button>
</nav>
<div class="learn-shadow-content hide" id="" editable="false">
<h2 class="header-shadow">box-shadow</h2>
<p>the box-shadow property in CSS is used to apply shadows on elements.</p>
<h3 class="sub-header-shadow">syntax</h3>
<code >
<!-- <pre> -->
<textarea class="css-code">
box-shadow : [horizontal offset] [vertical offset] [blur radius] [optional spread radius] [color];
</textarea>
<!-- </pre> -->
</code>
<ul>
<li>the <span>horizontal offset (required)</span> of the shadow, positive means the shadow will be on the right of the box, a negative offset will put the shadow on the left of the box.</li>
<li>the <span>vertical offset (required)</span> of the shadow, a negative one means the box-shadow will be above the box, a positive one means the shadow will be below the box.</li>
<li>the <span> blur radius (required)</span>, if set to 0 the shadow will be sharp, the higher the number, the more blurred it will be, and the further out the shadow will extend. For instance a shadow with 5px of horizontal offset that also has a 5px blur radius will be 10px of total shadow.</li>
<li>the <span>spread radius (optional)</span>, positive values increase the size of the shadow, negative values decrease the size. Default is 0 (the shadow is same size as blur).</li>
<li>the <span>color (required)</span> takes any color value, like hex, named, rgba or hsla. If the color value is omitted, box shadows are drawn in the foreground color (text color). But be aware, older WebKit browsers (pre Chrome 20 and Safari 6) ignore the rule when color is omitted.</li>
</ul>
<code >
<!-- <pre> -->
<textarea class="css-code">
.my-element {
box-shadow: 5px 5px 20px 5px #000;
}
</textarea>
<!-- </pre> -->
</code>
<a class="learn-more" href="https://css-tricks.com/almanac/properties/b/box-shadow/" target="_blank">learn more on css tricks</a>
</div>
</header>
<main>
<article class="shadow-box" id="shadow-box"> </article>
<p class="copymessage hideCopy">copied 🎉</p>
<section class="tool-box">
<article>
<label for="">
offset x(px)
</label>
<input id="offsetx" type="number" min="1" max="100" value="5">
</article>
<article>
<label for="">
offset y(px)
</label>
<input id="offsety" type="number" min="1" max="100" value="5">
</article>
<article>
<label for="">
blur(px)
</label>
<input id="blur" type="number" min="0" max="100" value="0">
</article>
<article>
<label for="">
spread(px)
</label>
<input id="spread" type="number" min="0" max="100" value="5">
</article>
</section>
<article class="color-tool">
<!-- <label for="">
color
</label> -->
<input id="color" class="color" type="color" value="#000000">
</article>
</main>
<footer class="footer">
<section class="footer-top">
<h1 class="nav-logo"> <i class="fa-solid fa-bolt-lightning"></i> shadow</h1>
<p>create awesome shadows</p>
</section>
<section class="footer-bottom">
<a target="_blank" class="footer-link" href="https://github.com/sobitp59/shadow"> <i class="fa-brands fa-github"></i> source code </a>
<a target="_blank" class="footer-link" href="https://twitter.com/sobit_prasad"> <i class="fa-brands fa-twitter"></i> connect</a>
</section>
</footer>
</div>
<script src="script.js"></script>
</body>
</html>