Skip to content

Commit

Permalink
docs(docs): rebuild docs
Browse files Browse the repository at this point in the history
  • Loading branch information
bhough committed Mar 20, 2020
1 parent 9a321ac commit 49538c2
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
7 changes: 5 additions & 2 deletions docs/assets/polished.js
Original file line number Diff line number Diff line change
Expand Up @@ -619,6 +619,8 @@
/**
* Fetches the value of a passed CSS Variable.
*
* Passthrough can be enabled (off by default) for when you are unsure of the input and want non-variable values to be returned instead of an error.
*
* @example
* // Styles as object usage
* const styles = {
Expand All @@ -637,8 +639,9 @@
* }
*/

function cssVar(cssVariable) {
function cssVar(cssVariable, passThrough) {
if (!cssVariable || !cssVariable.match(cssVariableRegex)) {
if (passThrough) return cssVariable;
throw new PolishedError(73);
}

Expand Down Expand Up @@ -3116,7 +3119,7 @@

var color2 = _extends({}, parsedColor2, {
alpha: typeof parsedColor2.alpha === 'number' ? parsedColor2.alpha : 1
}); // The formular is copied from the original Sass implementation:
}); // The formula is copied from the original Sass implementation:
// http://sass-lang.com/documentation/Sass/Script/Functions.html#mix-instance_method


Expand Down
11 changes: 10 additions & 1 deletion docs/docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8350,9 +8350,10 @@ <h3 class='fl m0' id='cssvar'>


<p>Fetches the value of a passed CSS Variable.</p>
<p>Passthrough can be enabled (off by default) for when you are unsure of the input and want non-variable values to be returned instead of an error.</p>


<div class='pre p1 fill-light mt0'>cssVar(cssVariable: <a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String">string</a>): (<a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String">string</a> | <a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number">number</a>)</div>
<div class='pre p1 fill-light mt0'>cssVar(cssVariable: <a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String">string</a>, passThrough: <a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Boolean">boolean</a>?): (<a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String">string</a> | <a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number">number</a>)</div>


<p>
Expand Down Expand Up @@ -8381,6 +8382,14 @@ <h3 class='fl m0' id='cssvar'>

</div>

<div class='space-bottom0'>
<div>
<span class='code bold'>passThrough</span> <code class='quiet'>(<a href="https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Boolean">boolean</a>?)</code>

</div>

</div>

</div>


Expand Down

0 comments on commit 49538c2

Please sign in to comment.