aboutsummaryrefslogtreecommitdiff
path: root/build/current-color
diff options
context:
space:
mode:
Diffstat (limited to 'build/current-color')
-rw-r--r--build/current-color/index.html32
1 files changed, 22 insertions, 10 deletions
diff --git a/build/current-color/index.html b/build/current-color/index.html
index a28a733..12972d0 100644
--- a/build/current-color/index.html
+++ b/build/current-color/index.html
@@ -1,31 +1,41 @@
<!doctype html>
-<html lang="en" id="top">
+<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" href="data:,">
<title>CSS Value: `currentColor`</title>
- <link href="https://bt.ht/atom.xml" type="application/atom+xml" rel="alternate" title="Atom feed for blog posts" />
- <style>*{box-sizing:border-box;}body{font-family:sans-serif;margin:0 auto;max-width:650px;padding:1rem;}img{max-width:100%;}pre{overflow:auto;}table{text-align:left;width:100%;}</style>
+ <link href="/atom.xml" type="application/atom+xml" rel="alternate" title="Atom feed for blog posts" />
+ <link href="/rss.xml" type="application/rss+xml" rel="alternate" title="RSS feed for blog posts" />
+<style>*{box-sizing:border-box;}body{font-family:sans-serif;line-height:1.33;margin:0 auto;max-width:650px;padding:1rem;}img{max-width:100%;}pre{border:1px solid;overflow:auto;padding:5px;}table{text-align:left;width:100%;}.footnotes{font-size:90%;}</style>
</head>
<nav>
- <a href="#menu">Menu &darr;</a>
+ <a href="#menu">Menu &darr;</a>
</nav>
<main>
-<h1>CSS Value: <code>currentColor</code></h1>
+<h1 id="css-value-">CSS Value: <code>currentColor</code></h1>
+
<p>2019-04-13</p>
+
<p><em>There are a large number of nuanced and mostly unheard of</em> CSS value types, but today we are going to focus on <code>currentColor</code>. So what is the <code>currentColor</code> value type anyway?</p>
-<blockquote><p>The currentColor value type will apply the existing color value to other properties like background-color, etc.</p>
+
+<blockquote>
+<p>The currentColor value type will apply the existing color value to other properties like background-color, etc.</p>
</blockquote>
-<h2>See it in action</h2>
-<p>Let's assume with have a single div with the following properties:</p>
+
+<h2 id="see-it-in-action">See it in action</h2>
+
+<p>Let&#8217;s assume with have a single div with the following properties:</p>
+
<pre><code>div {
color: dodgerblue;
}
</code></pre>
-<p>If we wanted to use that same color for other properties on elements inside that initial <code>div</code>, it's simple - we just need to call <code>currentColor</code> like so:</p>
+
+<p>If we wanted to use that same color for other properties on elements inside that initial <code>div</code>, it&#8217;s simple - we just need to call <code>currentColor</code> like so:</p>
+
<pre><code>div {
color: dodgerblue;
}
@@ -38,8 +48,10 @@ div a {
border-bottom: 1px solid currentColor;
}
</code></pre>
+
<p><strong>Sidenote</strong>: If you re-declare the default <code>color</code> property further along in your CSS, the <code>currentColor</code> value will update according to the last color set.</p>
-<p>And that's it. Best of all, this value type is supported across all major browsers!</p>
+
+<p>And that&#8217;s it. Best of all, this value type is supported across all major browsers!</p>
<footer role="contentinfo">
<h2>Menu Navigation</h2>
<ul id="menu">