Skip to content

Commit

Permalink
docs(transparentize): fix trailing comma and semicolon in example code
Browse files Browse the repository at this point in the history
  • Loading branch information
hideo54 authored and bhough committed Apr 3, 2022
1 parent 7fc0ff9 commit 58796b6
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions docs/assets/polished.js
Expand Up @@ -3576,16 +3576,16 @@
* @example
* // Styles as object usage
* const styles = {
* background: transparentize(0.1, '#fff');
* background: transparentize(0.1, '#fff'),
* background: transparentize(0.2, 'hsl(0, 0%, 100%)'),
* background: transparentize('0.5', 'rgba(255, 0, 0, 0.8)'),
* }
*
* // styled-components usage
* const div = styled.div`
* background: ${transparentize(0.1, '#fff')};
* background: ${transparentize(0.2, 'hsl(0, 0%, 100%)')},
* background: ${transparentize('0.5', 'rgba(255, 0, 0, 0.8)')},
* background: ${transparentize(0.2, 'hsl(0, 0%, 100%)')};
* background: ${transparentize('0.5', 'rgba(255, 0, 0, 0.8)')};
* `
*
* // CSS in JS Output
Expand Down
6 changes: 3 additions & 3 deletions docs/docs/index.html
Expand Up @@ -6489,16 +6489,16 @@ <h3 class='fl m0' id='transparentize'>

<pre class='p1 overflow-auto round fill-light'><span class="hljs-comment">// Styles as object usage</span>
<span class="hljs-keyword">const</span> styles = {
<span class="hljs-built_in">background</span>: transparentize(<span class="hljs-number">0.1</span>, <span class="hljs-string">'#fff'</span>);
<span class="hljs-built_in">background</span>: transparentize(<span class="hljs-number">0.1</span>, <span class="hljs-string">'#fff'</span>),
<span class="hljs-built_in">background</span>: transparentize(<span class="hljs-number">0.2</span>, <span class="hljs-string">'hsl(0, 0%, 100%)'</span>),
<span class="hljs-built_in">background</span>: transparentize(<span class="hljs-string">'0.5'</span>, <span class="hljs-string">'rgba(255, 0, 0, 0.8)'</span>),
}

<span class="hljs-comment">// styled-components usage</span>
<span class="hljs-keyword">const</span> div = styled.div`
<span class="hljs-built_in">background</span>: ${transparentize(<span class="hljs-number">0.1</span>, <span class="hljs-string">'#fff'</span>)};
<span class="hljs-built_in">background</span>: ${transparentize(<span class="hljs-number">0.2</span>, <span class="hljs-string">'hsl(0, 0%, 100%)'</span>)},
<span class="hljs-built_in">background</span>: ${transparentize(<span class="hljs-string">'0.5'</span>, <span class="hljs-string">'rgba(255, 0, 0, 0.8)'</span>)},
<span class="hljs-built_in">background</span>: ${transparentize(<span class="hljs-number">0.2</span>, <span class="hljs-string">'hsl(0, 0%, 100%)'</span>)};
<span class="hljs-built_in">background</span>: ${transparentize(<span class="hljs-string">'0.5'</span>, <span class="hljs-string">'rgba(255, 0, 0, 0.8)'</span>)};
`

<span class="hljs-comment">// CSS in JS Output</span>
Expand Down
6 changes: 3 additions & 3 deletions src/color/transparentize.js
Expand Up @@ -11,16 +11,16 @@ import parseToRgb from './parseToRgb'
* @example
* // Styles as object usage
* const styles = {
* background: transparentize(0.1, '#fff');
* background: transparentize(0.1, '#fff'),
* background: transparentize(0.2, 'hsl(0, 0%, 100%)'),
* background: transparentize('0.5', 'rgba(255, 0, 0, 0.8)'),
* }
*
* // styled-components usage
* const div = styled.div`
* background: ${transparentize(0.1, '#fff')};
* background: ${transparentize(0.2, 'hsl(0, 0%, 100%)')},
* background: ${transparentize('0.5', 'rgba(255, 0, 0, 0.8)')},
* background: ${transparentize(0.2, 'hsl(0, 0%, 100%)')};
* background: ${transparentize('0.5', 'rgba(255, 0, 0, 0.8)')};
* `
*
* // CSS in JS Output
Expand Down

0 comments on commit 58796b6

Please sign in to comment.