Skip to content
Permalink
Browse files

Initial commit from 10Up modern/tweaks branch

  • Loading branch information
richtabor committed Jul 27, 2019
1 parent b060386 commit 7689aa6433e4c54cbce5b4d0c0162bf04be599b6
Showing 387 changed files with 33,466 additions and 0 deletions.
@@ -0,0 +1,5 @@
{
"presets": [
"@babel/preset-env"
]
}
@@ -0,0 +1,6 @@
# Browsers that we support

> 1%
last 2 versions
Firefox ESR
IE 11
@@ -0,0 +1,15 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = tab

[{*.json,*.yml,.babelrc,.bowerrc,.browserslistrc,.postcssrc}]
indent_style = space
indent_size = 2

[*.txt,wp-config-sample.php]
end_of_line = crlf
@@ -0,0 +1,7 @@
assets/js/vendor
assets/js/admin/vendor
assets/js/frontend/vendor
assets/js/shared/vendor
gulp-tasks/
webpack.config.babel.js
gulpfile.babel.js
@@ -0,0 +1,15 @@
module.exports = {
parser: 'babel-eslint',
extends: ['@10up/eslint-config'],
env: {
browser: true,
es6: true,
},
globals: {
window: true,
document: true,
wp: true,
jQuery: true,
MaverickPreviewData: true,
}
};
@@ -0,0 +1,31 @@
node_modules
bower_components
release
vendor
phpunit.xml
.idea
.vscode

# Project Files
dist
!assets/shared/js/frontend/vendor/

# Editors
*.esproj
*.tmproj
*.tmproject
tmtags
.*.sw[a-z]
*.un~
Session.vim
*.swp

# Mac OSX
.DS_Store
._*
.Spotlight-V100
.Trashes

# Windows
Thumbs.db
Desktop.ini
@@ -0,0 +1,15 @@
{
"extends": "@10up/stylelint-config",
"rules": {
"selector-nested-pattern": ["^&"],
"no-descending-specificity": null,
"at-rule-no-unknown": [true, {
"ignoreAtRules": ["define-mixin", "mixin"]
}],
"at-rule-empty-line-before": ["always", {
"except": ["first-nested", "blockless-after-blockless"],
"ignore": ['after-comment'],
}],
"sh-waqar/declaration-use-variable": [ [ "/color/", { ignoreValues: ["transparent", "inherit", "currentColor"] } ] ],
}
}
15 404.php
@@ -0,0 +1,15 @@
<?php
/**
* The 404 template file
*
* @package Maverick
*/

get_header(); ?>

<div class="content-area u-ma-auto u-max-width-full">
<?php get_template_part( 'partials/content', 'none' ); ?>
</div><!-- .u-ma-auto .u-max-width-full -->

<?php
get_footer();
@@ -0,0 +1,23 @@
<?php
/**
* archive.php (for archives and blog landing)
*
* @package Maverick
*/

get_header(); ?>

<div class="content-area u-ma-auto u-max-width-full">
<h1><?php the_archive_title(); ?></h1>

<?php if ( have_posts() ) : ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php get_template_part( 'partials/content' ); ?>
<?php endwhile; ?>
<?php the_posts_navigation(); ?>
<?php endif; ?>

</div><!-- .u-ma-auto .u-max-width-full -->

<?php
get_footer();
@@ -0,0 +1 @@
@import url("customizer/switcher-control.css");
@@ -0,0 +1,74 @@
/* stylelint-disable */
.switcher__wrapper {

padding: 5px;

& .switcher__choice {
cursor: pointer;
display: block;
margin-bottom: 10px;
position: relative;

& .label {
box-sizing: border-box;
width: 100%;
position: absolute;
bottom: 0;
height: 30px;
background: rgba(0,0,0, 0.6);
padding: 5px;
color: #FFF;
}
}

& label {
position: relative;
}

& label[for^="maverick_header_variation"] img {
border: 1px solid #b4b9be;
}

& input[type="radio"] {
height: 0;
margin: 0;
opacity: 0;
padding: 0;
position: absolute;
width: 0;
}

& input[type="radio"]:checked + img {
border-color: #5b9dd9;
box-shadow: 0 0 2px rgba(30,140,190,.8);
outline: 2px solid transparent;
}

&:focus-within {
outline: 1px dashed #5b9dd9;
}
}

.switcher__wrapper.color_scheme {
display: flex;
justify-content: space-between;

& .switcher__choice {
flex: 1;
height: 100px;
margin-right: 10px;

& .color-scheme {
display: block;
width: 100%;
height: 100%;
}

&:hover {
opacity: 0.5;
}
}

}

/* stylelint-enable */
@@ -0,0 +1 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m12 0c-6.2743424.04054365-11.47263686 4.87881291-11.96263624 11.134124-.48999937 6.2553111 3.8915168 11.8439989 10.08301554 12.8610334v-8.428299h-2.99939464v-3.4892958h2.99939464v-2.69945524c0-2.99939468 1.7996368-4.69905166 4.539084-4.69905166.8975462.0116032 1.7930606.08845704 2.6794592.22995359v3.08937652h-1.5096953c-.9469302-.12406387-1.8152125.54281273-1.9396086 1.48969936-.0200099.12585069-.0200099.25407263 0 .37992332v2.22955001h3.3093322l-.5298931 3.4892958h-2.789437v8.4083031c6.1914987-1.0170345 10.5730149-6.6057223 10.0830155-12.8610334-.4899993-6.25531109-5.6882938-11.09358035-11.9626362-11.134124z" fill-rule="evenodd"/></svg>
@@ -0,0 +1 @@
<svg fill="none" height="218" width="476" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h476v218H0z" fill="#fff"/><g fill="#111"><rect height="12" opacity=".5" rx="6" width="12" x="207" y="57"/><rect height="12" opacity=".5" rx="6" width="12" x="232" y="57"/><rect height="12" opacity=".5" rx="6" width="12" x="257" y="57"/><path d="M162 102h30v5h-30zm41 0h30v5h-30zm41 0h30v5h-30zm41 0h30v5h-30z"/><path d="M187 137h103v4H187z" opacity=".3"/></g></svg>
@@ -0,0 +1 @@
<svg fill="none" height="218" width="476" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h476v218H0z" fill="#fff"/><g fill="#111"><rect height="12" opacity=".5" rx="6" width="12" x="357" y="143"/><rect height="12" opacity=".5" rx="6" width="12" x="382" y="143"/><rect height="12" opacity=".5" rx="6" width="12" x="407" y="143"/><path d="M241 45h34.902v5H241zm72.131 0h34.902v5h-34.902zm70.967 0H419v5h-34.902z"/><path d="M241 59h34.902v2H241zm72.131 0h34.902v2h-34.902zm70.967 0H419v2h-34.902zM241 70h34.902v2H241z" opacity=".4"/><path d="M46 45h34.902v5H46z"/><path d="M46 60h146v47H46z" opacity=".2"/><path d="M313.131 70h34.902v2h-34.902zm70.967 0H419v2h-34.902zM241 81h34.902v2H241zm72.131 0h34.902v2h-34.902zm70.967 0H419v2h-34.902z" opacity=".4"/><path d="M46 147h103v4H46z" opacity=".3"/></g></svg>
@@ -0,0 +1 @@
<svg fill="none" height="218" width="476" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h476v218H0z" fill="#fff"/><g fill="#111"><rect height="12" opacity=".5" rx="6" width="12" x="364" y="96"/><rect height="12" opacity=".5" rx="6" width="12" x="389" y="96"/><rect height="12" opacity=".5" rx="6" width="12" x="414" y="96"/><path d="M39 97h30v5H39zm41 0h30v5H80zm41 0h30v5h-30zm41 0h30v5h-30z"/><path d="M39 115h103v4H39z" opacity=".3"/></g></svg>
@@ -0,0 +1 @@
<svg fill="none" height="218" width="476" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h476v218H0z" fill="#fff"/><g fill="#111"><rect height="12" opacity=".5" rx="6" width="12" x="362" y="119"/><rect height="12" opacity=".5" rx="6" width="12" x="387" y="119"/><rect height="12" opacity=".5" rx="6" width="12" x="412" y="119"/><path d="M145 68h34.902v5H145zm72.131 0h34.902v5h-34.902zm70.967 0H323v5h-34.902z"/><path d="M145 82h34.902v2H145zm72.131 0h34.902v2h-34.902zm70.967 0H323v2h-34.902zM145 93h34.902v2H145zm72.131 0h34.902v2h-34.902zm70.967 0H323v2h-34.902zM145 104h34.902v2H145zm72.131 0h34.902v2h-34.902zm70.967 0H323v2h-34.902z" opacity=".4"/><path d="M51 68h34.902v5H51z"/><path d="M321 146h103v4H321z" opacity=".3"/></g></svg>
@@ -0,0 +1 @@
<svg fill="none" height="100" viewBox="0 0 476 100" width="476" xmlns="http://www.w3.org/2000/svg"><path d="m0 0h476v100h-476z" fill="#fff"/><g fill="#111"><path d="m31 37h69v26h-69z"/><g opacity=".5"><path d="m269 48h30v5h-30z"/><path d="m310 48h30v5h-30z"/><path d="m351 48h30v5h-30z"/><path d="m392 48h30v5h-30z"/></g><rect height="12" opacity=".5" rx="6" width="12" x="438" y="44"/></g></svg>
@@ -0,0 +1 @@
<svg width="476" height="100" fill="none" xmlns="http://www.w3.org/2000/svg"><path fill="#fff" d="M0 0H476V100H0z"/><path fill="#111" d="M203 25H272V51H203z"/><g opacity=".5" fill="#111"><path d="M162 70H192V75H162z"/><path d="M203 70H233V75H203z"/><path d="M244 70H274V75H244z"/><path d="M285 70H315V75H285z"/></g></svg>
@@ -0,0 +1 @@
<svg width="476" height="100" fill="none" xmlns="http://www.w3.org/2000/svg"><path fill="#fff" d="M0 0H476V100H0z"/><path fill="#EDEDED" d="M0 0H43V100H0z"/><rect opacity=".5" x="438" y="44" width="12" height="12" rx="6" fill="#111"/><path fill="#111" d="M69 37H138V63H69z"/><path fill="#979797" d="M12 44H24V56H12z"/></svg>
@@ -0,0 +1 @@
<svg width="476" height="100" fill="none" xmlns="http://www.w3.org/2000/svg"><path fill="#fff" d="M0 0H476V100H0z"/><path fill="#111" d="M371 37H440V63H371z"/><g opacity=".5" fill="#111"><path d="M31 48H61V53H31z"/><path d="M72 48H102V53H72z"/><path d="M113 48H143V53H113z"/><path d="M154 48H184V53H154z"/></g></svg>
@@ -0,0 +1 @@
<svg width="476" height="100" fill="none" xmlns="http://www.w3.org/2000/svg"><path fill="#fff" d="M0 0H476V100H0z"/><rect opacity=".5" x="31" y="44" width="12" height="12" rx="6" fill="#111"/><path fill="#111" d="M203 37H272V63H203z"/></svg>
@@ -0,0 +1 @@
<svg fill="none" height="100" width="476" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h476v100H0z" fill="#fff"/><g fill="#111"><path d="M371 37h69v26h-69zM62 48h30v5H62zm41 0h30v5h-30zm41 0h30v5h-30zm41 0h30v5h-30z"/><rect height="12" opacity=".5" rx="6" width="12" x="31" y="44"/></g></svg>
@@ -0,0 +1 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m12 0c-3.26 0-3.667.015-4.947.072-1.278.06-2.148.261-2.913.558-.789.306-1.459.717-2.126 1.384s-1.079 1.336-1.384 2.126c-.297.765-.499 1.635-.558 2.913-.06 1.28-.072 1.687-.072 4.947s.015 3.667.072 4.947c.06 1.277.261 2.148.558 2.913.306.788.717 1.459 1.384 2.126.667.666 1.336 1.079 2.126 1.384.766.296 1.636.499 2.913.558 1.28.06 1.687.072 4.947.072s3.667-.015 4.947-.072c1.277-.06 2.148-.262 2.913-.558.788-.306 1.459-.718 2.126-1.384.666-.667 1.079-1.335 1.384-2.126.296-.765.499-1.636.558-2.913.06-1.28.072-1.687.072-4.947s-.015-3.667-.072-4.947c-.06-1.277-.262-2.149-.558-2.913-.306-.789-.718-1.459-1.384-2.126-.667-.667-1.335-1.079-2.126-1.384-.765-.297-1.636-.499-2.913-.558-1.28-.06-1.687-.072-4.947-.072zm0 2.16c3.203 0 3.585.016 4.85.071 1.17.055 1.805.249 2.227.415.562.217.96.477 1.382.896.419.42.679.819.896 1.381.164.422.36 1.057.413 2.227.057 1.266.07 1.646.07 4.85s-.015 3.585-.074 4.85c-.061 1.17-.256 1.805-.421 2.227-.224.562-.479.96-.899 1.382-.419.419-.824.679-1.38.896-.42.164-1.065.36-2.235.413-1.274.057-1.649.07-4.859.07-3.211 0-3.586-.015-4.859-.074-1.171-.061-1.816-.256-2.236-.421-.569-.224-.96-.479-1.379-.899-.421-.419-.69-.824-.9-1.38-.165-.42-.359-1.065-.42-2.235-.045-1.26-.061-1.649-.061-4.844 0-3.196.016-3.586.061-4.861.061-1.17.255-1.814.42-2.234.21-.57.479-.96.9-1.381.419-.419.81-.689 1.379-.898.42-.166 1.051-.361 2.221-.421 1.275-.045 1.65-.06 4.859-.06zm0 3.678c-3.405 0-6.162 2.76-6.162 6.162 0 3.405 2.76 6.162 6.162 6.162 3.405 0 6.162-2.76 6.162-6.162 0-3.405-2.76-6.162-6.162-6.162zm0 10.162c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm7.846-10.405c0 .795-.646 1.44-1.44 1.44-.795 0-1.44-.646-1.44-1.44s.646-1.439 1.44-1.439c.793-.001 1.44.645 1.44 1.439z"/></svg>
@@ -0,0 +1 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667h-3.554v-11.452h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zm-15.11-13.019c-1.144 0-2.063-.926-2.063-2.065 0-1.138.92-2.063 2.063-2.063 1.14 0 2.064.925 2.064 2.063 0 1.139-.925 2.065-2.064 2.065zm1.782 13.019h-3.564v-11.452h3.564zm15.106-20.452h-20.454c-.979 0-1.771.774-1.771 1.729v20.542c0 .956.792 1.729 1.771 1.729h20.451c.978 0 1.778-.773 1.778-1.729v-20.542c0-.955-.8-1.729-1.778-1.729z"/></svg>
@@ -0,0 +1 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m12.0175431 0c-6.63731671 0-12.0175431 5.367-12.0175431 11.987 0 5.079 3.16578255 9.417 7.63677374 11.162-.10525877-.949-.19949042-2.403.04110104-3.439.2195397-.937 1.40946493-5.957 1.40946493-5.957s-.35988472-.72-.35988472-1.781c0-1.663.96938307-2.911 2.17334281-2.911 1.0265235 0 1.5217409.769 1.5217409 1.688 0 1.029-.6546092 2.567-.9944446 3.992-.2857024 1.193.6014786 2.165 1.7793743 2.165 2.1332442 0 3.7772858-2.245 3.7772858-5.487 0-2.861-2.0680841-4.869-5.0203417-4.869-3.41840356 0-5.42232988 2.562-5.42232988 5.199 0 1.033.39497097 2.143.89119084 2.741.09924398.12.11227602.225.08520948.345-.0902218.375-.29372207 1.199-.33482311 1.363-.05313061.225-.17242387.271-.40198822.165-1.49868427-.69-2.43899587-2.878-2.43899587-4.646 0-3.776 2.75477215-7.252 7.93951796-7.252 4.168247 0 7.4102168 2.967 7.4102168 6.923 0 4.135-2.6134247 7.462-6.2483605 7.462-1.2169918 0-2.3598012-.629-2.7647968-1.379l-.75084587 2.848c-.26966292 1.045-1.00647424 2.352-1.50169165 3.146 1.12576751.345 2.31168292.535 3.55874862.535 6.6232822 0 12.0145357-5.365 12.0145357-11.987 0-6.623-5.3912535-11.987-12.0145357-11.987z" fill-rule="evenodd"/></svg>
@@ -0,0 +1 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m23.953002 4.58154047c-.8849632.38836966-1.8299238.65294025-2.8248823.77374418 1.0139577-.61000993 1.7939252-1.57144947 2.1629098-2.71858762-.9509603.55410067-2.0049164.95744603-3.1268697 1.18208144-.8959626-.95744603-2.1729094-1.55647378-3.5908504-1.55647378-2.7168868 0-4.919795 2.19943023-4.919795 4.90903243 0 .38936804.0449982.76376039.1269947 1.12217866-4.08982954-.19268726-7.71467851-2.15350477-10.14057743-5.11769377-.42698221.72083006-.66597225 1.55847054-.66597225 2.47098948 0 1.7072291.86996375 3.20779362 2.18790884 4.08936279-.80696638-.02595787-1.56593476-.24759813-2.22790717-.61500182v.06090115c0 2.38113529 1.69292946 4.36691229 3.94583559 4.81917829-.4129828.1108201-.84896463.1707229-1.29594601.1707229-.31398691 0-.61497437-.0299514-.91596183-.0858607.63097371 1.9498354 2.44489813 3.3715279 4.60380817 3.4114631-1.67993 1.3168627-3.8088413 2.101589-6.10174576 2.101589-.38998375 0-.77896754-.0229627-1.16995125-.0668914 2.1889088 1.3917411 4.76780134 2.2054205 7.55668514 2.2054205 9.05362276 0 13.99841676-7.4838534 13.99841676-13.96333691 0-.20866133 0-.41931942-.0149994-.62897914.96096-.68788353 1.799925-1.55747215 2.4598975-2.54387119z" fill-rule="evenodd"/></svg>
@@ -0,0 +1,8 @@
import SwitcherControl from './customizer/controls/switcher-control';

const api = wp.customize;

api.controlConstructor = {
...api.controlConstructor,
maverick_switcher_control: SwitcherControl, // eslint-disable-line camelcase
};
@@ -0,0 +1,9 @@
import DesignStylePreview from './customizer/preview/design-style';
import HeaderColorsPreview from './customizer/preview/header-colors';
import FooterColorsPreview from './customizer/preview/footer-colors';
import ColorSchemePreview from './customizer/preview/color-schemes';

DesignStylePreview();
HeaderColorsPreview();
FooterColorsPreview();
ColorSchemePreview();
@@ -0,0 +1,14 @@
const SwitcherControl = wp.customize.Control.extend( {
/**
* Runs DOM is ready
*/
ready() {
const control = this;

this.container.on( 'change', 'input:radio', function() {
control.setting.set( this.value );
} );
}
} );

export default SwitcherControl;

0 comments on commit 7689aa6

Please sign in to comment.
You can’t perform that action at this time.