This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@use 'sass:math'; | |
@use 'sass:meta'; | |
@use "sass:list"; | |
@function strip-units($number) { | |
@if meta.type-of($number) == 'number' and not math.is-unitless($number) { | |
@return $number / ($number * 0 + 1); | |
} | |
@return $number; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin setProp($prop, $val) { | |
--#{$prop}: #{$val}; | |
} | |
@mixin prop($customProp, $renderedValue) { | |
// #{$customProp}: map-get($VariablesMap, $renderedValue); | |
#{$customProp}: var(unquote('--#{$renderedValue}')); | |
} | |
// Colors |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function my_shortcode_attr( $atts, $content = null) { | |
$a = shortcode_atts( array( | |
'url' => '#', | |
'class' => '' | |
), $atts ); | |
return '<a class="' . $a["class"] . '" href="' . $a["url"] . '">' . $content . '</a>'; | |
} | |
add_shortcode( 'myshortcode', 'my_shortcode_attr' ); | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function my_shortcode( $atts, $content = null ) { | |
return '<span class="myshortcode-class">' . $content . '</span>'; | |
} | |
add_shortcode( 'myshortcode', 'my_shortcode' ); | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Default config settings | |
* | |
* Enter any WordPress config settings that are nonspecific to any environment | |
* in this file. | |
*/ | |
/** Database Charset to use in creating database tables. */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Advanced Custom Fields Options function | |
* Fetch an Options field value from the default language when empty | |
*/ | |
function cl_acf_set_language() { | |
return acf_get_setting('default_language'); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function is_post_type($type){ | |
global $wp_query; | |
if($type == get_post_type($wp_query->post->ID)) return true; | |
return false; | |
} | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ item.url.length > 1 && <div className="hover-target"> | |
<Button to={item.url} text={item.button} /> | |
</div> | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
class MyComponent extends Component { | |
constructor(props) { | |
super(); | |
this.state = [{ | |
}] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get remove mono-runtime-common gnome-orca virtualbox-guest* | |
NewerOlder