Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
ai
noblogs-wp
Commits
e4b5b516
Commit
e4b5b516
authored
May 22, 2020
by
agata
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[auto] theme: micro 1.5.4
parent
87e4f671
Changes
23
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
23 changed files
with
8657 additions
and
405 deletions
+8657
-405
wp-content/themes/micro/archive.php
wp-content/themes/micro/archive.php
+1
-1
wp-content/themes/micro/assets/css/master.css
wp-content/themes/micro/assets/css/master.css
+273
-277
wp-content/themes/micro/assets/css/master.min.css
wp-content/themes/micro/assets/css/master.min.css
+1
-1
wp-content/themes/micro/assets/sass/base/_general.scss
wp-content/themes/micro/assets/sass/base/_general.scss
+9
-0
wp-content/themes/micro/assets/sass/components/_gutenberg.scss
...ntent/themes/micro/assets/sass/components/_gutenberg.scss
+87
-0
wp-content/themes/micro/assets/sass/components/_input.scss
wp-content/themes/micro/assets/sass/components/_input.scss
+16
-3
wp-content/themes/micro/assets/sass/layout/_header.scss
wp-content/themes/micro/assets/sass/layout/_header.scss
+34
-23
wp-content/themes/micro/assets/sass/master.scss
wp-content/themes/micro/assets/sass/master.scss
+1
-0
wp-content/themes/micro/assets/scripts/bundle.js
wp-content/themes/micro/assets/scripts/bundle.js
+150
-0
wp-content/themes/micro/assets/scripts/bundle.min.js
wp-content/themes/micro/assets/scripts/bundle.min.js
+1
-1
wp-content/themes/micro/assets/scripts/inc/customizer.js
wp-content/themes/micro/assets/scripts/inc/customizer.js
+0
-0
wp-content/themes/micro/assets/scripts/inc/navigation.js
wp-content/themes/micro/assets/scripts/inc/navigation.js
+116
-0
wp-content/themes/micro/assets/scripts/inc/skip-link-focus-fix.js
...nt/themes/micro/assets/scripts/inc/skip-link-focus-fix.js
+33
-0
wp-content/themes/micro/comments.php
wp-content/themes/micro/comments.php
+12
-3
wp-content/themes/micro/footer.php
wp-content/themes/micro/footer.php
+1
-1
wp-content/themes/micro/functions.php
wp-content/themes/micro/functions.php
+2
-22
wp-content/themes/micro/header.php
wp-content/themes/micro/header.php
+5
-3
wp-content/themes/micro/inc/custom-header.php
wp-content/themes/micro/inc/custom-header.php
+44
-9
wp-content/themes/micro/package-lock.json
wp-content/themes/micro/package-lock.json
+7830
-0
wp-content/themes/micro/package.json
wp-content/themes/micro/package.json
+13
-13
wp-content/themes/micro/readme.txt
wp-content/themes/micro/readme.txt
+25
-45
wp-content/themes/micro/scripts.js
wp-content/themes/micro/scripts.js
+1
-1
wp-content/themes/micro/style.css
wp-content/themes/micro/style.css
+2
-2
No files found.
wp-content/themes/micro/archive.php
View file @
e4b5b516
...
...
@@ -56,4 +56,4 @@ get_header(); ?>
</section>
<!-- .section-fullwidth section-main -->
<?php
get_footer
();
get_footer
();
\ No newline at end of file
wp-content/themes/micro/assets/css/master.css
View file @
e4b5b516
This diff is collapsed.
Click to expand it.
wp-content/themes/micro/assets/css/master.min.css
View file @
e4b5b516
This diff is collapsed.
Click to expand it.
wp-content/themes/micro/assets/sass/base/_general.scss
View file @
e4b5b516
...
...
@@ -49,6 +49,11 @@ a {
color
:
$color-background
;
background-color
:
$color-text
;
}
&
:focus
{
outline
:
1px
dashed
$color-text
;
box-shadow
:
inset
0
0
0
2px
$color-background
;
}
}
h1
,
h2
,
h3
,
h4
,
h5
{
...
...
@@ -338,4 +343,8 @@ dd {
table
{
margin
:
0
0
1
.5em
;
width
:
100%
;
}
hr
{
background
:
$color-text
;
}
\ No newline at end of file
wp-content/themes/micro/assets/sass/components/_gutenberg.scss
0 → 100644
View file @
e4b5b516
.wp-block-button
{
&
__link
{
border-radius
:
0
;
border
:
1px
solid
$color-text
;
background
:
$color-text
;
color
:
$color-background
;
&
:hover
{
color
:
$color-background
;
}
}
&
.is-style-outline
{
.wp-block-button__link
{
border-color
:
$color-text
;
background
:
$color-background
;
color
:
$color-text
;
}
}
}
.wp-block-file
{
.wp-block-file__button
{
border-radius
:
0
;
border
:
1px
solid
$color-text
;
background
:
$color-text
;
color
:
$color-background
;
}
}
.wp-block-gallery
{
&
.alignleft
,
&
.alignright
{
display
:
flex
;
}
}
.wp-block-column
{
.wp-block-image
{
margin-left
:
0
;
margin-right
:
0
;
}
}
.wp-block-latest-posts
{
margin-left
:
0
;
a
{
font-weight
:
bold
;
}
&
__post-date
{
color
:
$color-text
;
}
}
.entry
{
.columns-2
,
.columns-3
,
.columns-4
,
.columns-5
,
.columns-6
,
.columns-7
,
.columns-8
,
.wp-block-latest-posts
,
.wp-block-latest-comments
{
// In case there is UL tag
margin-left
:
0
;
}
}
.wp-block-latest-comments
{
&
__comment-date
{
color
:
$color-text
;
}
}
.wp-block-table
{
&
.is-style-stripes
{
border-bottom
:
1px
solid
$color-text
;
tbody
tr
:nth-child
(
odd
)
{
background
:
$color-text
;
color
:
$color-background
;
}
}
}
\ No newline at end of file
wp-content/themes/micro/assets/sass/components/_input.scss
View file @
e4b5b516
::-webkit-input-placeholder
{
/* Chrome/Opera/Safari */
color
:
rgba
(
$color-text
,
.5
);
}
::-moz-placeholder
{
/* Firefox 19+ */
color
:
rgba
(
$color-text
,
.5
);
}
:-ms-input-placeholder
{
/* IE 10+ */
color
:
rgba
(
$color-text
,
.5
);
}
:-moz-placeholder
{
/* Firefox 18- */
color
:
rgba
(
$color-text
,
.5
);
}
input
{
background
:
$color-background
;
border
:
1px
solid
$color-text
;
color
:
$color-text
;
font-size
:
13px
;
padding
:
8px
10px
;
&
:focus
{
outline
:
none
;
}
&
[
type
=
"button"
]
:active
{
background
:
$color-text
;
color
:
$color-background
;
...
...
@@ -23,7 +36,7 @@ textarea {
font-family
:
$font-primary
;
font-size
:
13px
;
padding
:
8px
10px
;
&
:focus
{
outline
:
none
;
}
...
...
wp-content/themes/micro/assets/sass/layout/_header.scss
View file @
e4b5b516
...
...
@@ -32,7 +32,8 @@
}
}
.menu-item
{
.menu-item
,
.page_item
{
display
:
inline-block
;
margin-right
:
10px
;
position
:
relative
;
...
...
@@ -51,8 +52,10 @@
}
}
.menu-item-has-children
{
&
:hover
>
.sub-menu
{
.menu-item-has-children
,
.page_item_has_children
{
&
:hover
>
.sub-menu
,
&
:hover
>
.children
{
display
:
block
;
}
}
...
...
@@ -79,7 +82,8 @@
pointer-events
:
auto
;
}
.menu-item
{
.menu-item
,
.page_item
{
border-bottom
:
1px
solid
rgba
(
black
,
0
.1
);
margin
:
0
;
display
:
block
;
...
...
@@ -90,14 +94,16 @@
}
}
.menu-item-has-children
.dropdown-arrow
{
.menu-item-has-children
.dropdown-arrow
,
.page_item_has_children
.dropdown-arrow
{
height
:
rem-calc
(
10px
+
16px
*
2
);
width
:
rem-calc
(
10px
+
16px
*
2
);
line-height
:
rem-calc
(
10px
+
16px
*
2
);
padding
:
0
;
}
.sub-menu
{
.sub-menu
,
.children
{
border-top
:
1px
solid
rgba
(
black
,
0
.1
);
background
:
black
;
}
...
...
@@ -112,35 +118,39 @@
display
:
block
;
}
.sub-menu
{
pointer-events
:
none
;
opacity
:
0
;
transition
:
0
.2s
;
transform
:
translateY
(
40px
);
top
:
100%
;
}
li
{
position
:
relative
;
}
li
:hover
>
.sub-menu
{
a
:focus
+
.sub-menu
,
a
:focus
+
.children
,
&
.focus
>
.sub-menu
,
&
.focus
>
.children
{
opacity
:
1
;
pointer-events
:
auto
;
}
}
li
:hover
>
.sub-menu
,
li
:hover
>
.children
{
opacity
:
1
;
pointer-events
:
auto
;
transition
:
0
.2s
;
transform
:
translateY
(
0
);
}
.sub-menu
{
.sub-menu
,
.children
{
pointer-events
:
none
;
opacity
:
0
;
top
:
100%
;
position
:
absolute
;
border
:
1px
solid
rgba
(
black
,
0
.1
);
top
:
1
5px
;
top
:
1
00%
;
background
:
rgba
(
black
,
0
.98
);
max-width
:
200px
;
text-align
:
left
;
z-index
:
99
;
.sub-menu
{
.sub-menu
.children
{
left
:
100%
;
top
:
-1px
;
}
...
...
@@ -150,7 +160,6 @@
padding
:
8px
13px
;
font-size
:
13px
;
font-weight
:
normal
;
color
:
black
;
&
:hover
{
background
:
transparent
;
...
...
@@ -177,6 +186,8 @@
display
:
inline-block
;
font-size
:
22px
;
margin
:
0
;
line-height
:
1
.2
;
font-weight
:
bold
;
}
.site-description
{
...
...
wp-content/themes/micro/assets/sass/master.scss
View file @
e4b5b516
...
...
@@ -35,6 +35,7 @@
@import
"components/comment"
;
@import
"components/input"
;
@import
"components/entry"
;
@import
"components/gutenberg"
;
@import
"components/widgets"
;
...
...
wp-content/themes/micro/assets/scripts/bundle.js
View file @
e4b5b516
jQuery
(
document
).
ready
(
function
(
$
)
{
'
use strict
'
;
/**
* The actual plugin for mobile dropdown
*/
var
mobileDropdown
=
(
function
()
{
var
settings
=
{
heightHeader
:
80
,
heightAdminbar
:
50
};
// The selector variables.
var
selector
=
{
menuIcon
:
$
(
"
.menu-toggle
"
),
dropdownArrow
:
$
(
"
span.dropdown-arrow
"
),
menuNav
:
$
(
'
.main-navigation
'
),
wavesButtonSelector
:
'
.button
'
};
var
events
=
function
()
{
// When header is clicked.
selector
.
menuIcon
.
on
(
'
click
'
,
openMenu
);
// Dropdown menu links
$
(
'
li.menu-item-has-children
'
).
on
(
'
click
'
,
$
(
this
).
closest
(
'
span.dropdown-arrow
'
),
openDropdownMenu
);
};
var
focusMenuWithChildren
=
function
()
{
// Get all the link elements within the primary menu.
var
links
,
i
,
len
,
menu
=
document
.
querySelector
(
'
.menu-primary-container
'
);
if
(
!
menu
)
{
console
.
log
(
menu
);
return
false
;
}
links
=
menu
.
getElementsByTagName
(
'
a
'
);
// Each time a menu link is focused or blurred, toggle focus.
for
(
i
=
0
,
len
=
links
.
length
;
i
<
len
;
i
++
)
{
links
[
i
].
addEventListener
(
'
focus
'
,
toggleFocus
,
true
);
links
[
i
].
addEventListener
(
'
blur
'
,
toggleFocus
,
true
);
}
// Sets or removes the .focus class on an element.
function
toggleFocus
()
{
var
self
=
this
;
// Move up through the ancestors of the current link until we hit .primary-menu.
while
(
-
1
===
self
.
className
.
indexOf
(
'
menu
'
))
{
// On li elements toggle the class .focus.
if
(
'
li
'
===
self
.
tagName
.
toLowerCase
())
{
if
(
-
1
!==
self
.
className
.
indexOf
(
'
focus
'
))
{
self
.
className
=
self
.
className
.
replace
(
'
focus
'
,
''
);
}
else
{
self
.
className
+=
'
focus
'
;
}
}
self
=
self
.
parentElement
;
}
}
}
var
openMenu
=
function
(
event
)
{
var
headerHeight
=
settings
.
heightHeader
;
var
adminbarHeight
=
settings
.
heightAdminbar
;
// No need for this when you are not logged in.
if
(
!
$
(
"
body
"
).
hasClass
(
"
admin-bar
"
)
)
{
adminbarHeight
=
0
;
}
// Change button state
$
(
this
).
toggleClass
(
'
is-opened
'
);
// Open the main menu.
selector
.
menuNav
.
toggleClass
(
'
is-extended
'
).
removeClass
(
'
init
'
);
// selector.menuNav.height( $(window).height() - headerHeight - adminbarHeight );
$
(
'
body
'
).
toggleClass
(
'
is-menu-opened
'
);
};
var
openDropdownMenu
=
function
(
event
)
{
event
.
stopImmediatePropagation
();
// Fix issue with double clicking.
$
(
this
).
toggleClass
(
"
is-extended
"
);
};
var
buildDropdownArrow
=
function
()
{
$
(
'
.menu-item-has-children
'
).
each
(
function
()
{
$
(
this
).
append
(
"
<span class='dropdown-arrow'><i class='fa fa-angle-right'></i></span>
"
);
});
};
/**
* Run the dropdown menu.
*/
var
initialiseDropdown
=
function
()
{
focusMenuWithChildren
();
buildDropdownArrow
();
events
();
};
return
{
init
:
initialiseDropdown
};
})();
mobileDropdown
.
init
();
});
/**
* File skip-link-focus-fix.js.
*
* Helps with accessibility for keyboard only users.
*
* Learn more: https://git.io/vWdr2
*/
(
function
()
{
var
isWebkit
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
'
webkit
'
)
>
-
1
,
isOpera
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
'
opera
'
)
>
-
1
,
isIe
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
'
msie
'
)
>
-
1
;
if
(
(
isWebkit
||
isOpera
||
isIe
)
&&
document
.
getElementById
&&
window
.
addEventListener
)
{
window
.
addEventListener
(
'
hashchange
'
,
function
()
{
var
id
=
location
.
hash
.
substring
(
1
),
element
;
if
(
!
(
/^
[
A-z0-9_-
]
+$/
.
test
(
id
)
)
)
{
return
;
}
element
=
document
.
getElementById
(
id
);
if
(
element
)
{
if
(
!
(
/^
(?:
a|select|input|button|textarea
)
$/i
.
test
(
element
.
tagName
)
)
)
{
element
.
tabIndex
=
-
1
;
}
element
.
focus
();
}
},
false
);
}
})();
jQuery
(
document
).
ready
(
function
(
$
)
{
'
use strict
'
;
/*
...
...
wp-content/themes/micro/assets/scripts/bundle.min.js
View file @
e4b5b516
jQuery
(
document
).
ready
(
function
(
n
){
"
use strict
"
;
var
o
=
function
(){
return
!
0
};
o
()
||
(
console
.
log
=
function
(){})});
\ No newline at end of file
jQuery
(
document
).
ready
(
function
(
e
){
"
use strict
"
;(
function
(){
var
n
=
{
menuIcon
:
e
(
"
.menu-toggle
"
),
dropdownArrow
:
e
(
"
span.dropdown-arrow
"
),
menuNav
:
e
(
"
.main-navigation
"
),
wavesButtonSelector
:
"
.button
"
},
t
=
function
(){
n
.
menuIcon
.
on
(
"
click
"
,
o
),
e
(
"
li.menu-item-has-children
"
).
on
(
"
click
"
,
e
(
this
).
closest
(
"
span.dropdown-arrow
"
),
s
)},
a
=
function
(){
function
e
(){
for
(
var
e
=
this
;
-
1
===
e
.
className
.
indexOf
(
"
menu
"
);)
"
li
"
===
e
.
tagName
.
toLowerCase
()
&&
(
-
1
!==
e
.
className
.
indexOf
(
"
focus
"
)?
e
.
className
=
e
.
className
.
replace
(
"
focus
"
,
""
):
e
.
className
+=
"
focus
"
),
e
=
e
.
parentElement
}
var
n
,
t
,
a
,
o
=
document
.
querySelector
(
"
.menu-primary-container
"
);
if
(
!
o
)
return
console
.
log
(
o
),
!
1
;
for
(
n
=
o
.
getElementsByTagName
(
"
a
"
),
t
=
0
,
a
=
n
.
length
;
t
<
a
;
t
++
)
n
[
t
].
addEventListener
(
"
focus
"
,
e
,
!
0
),
n
[
t
].
addEventListener
(
"
blur
"
,
e
,
!
0
)},
o
=
function
(
t
){
e
(
"
body
"
).
hasClass
(
"
admin-bar
"
),
e
(
this
).
toggleClass
(
"
is-opened
"
),
n
.
menuNav
.
toggleClass
(
"
is-extended
"
).
removeClass
(
"
init
"
),
e
(
"
body
"
).
toggleClass
(
"
is-menu-opened
"
)},
s
=
function
(
n
){
n
.
stopImmediatePropagation
(),
e
(
this
).
toggleClass
(
"
is-extended
"
)},
i
=
function
(){
e
(
"
.menu-item-has-children
"
).
each
(
function
(){
e
(
this
).
append
(
"
<span class='dropdown-arrow'><i class='fa fa-angle-right'></i></span>
"
)})};
return
{
init
:
function
(){
a
(),
i
(),
t
()}}})().
init
()}),
function
(){
var
e
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"
webkit
"
)
>-
1
,
n
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"
opera
"
)
>-
1
,
t
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"
msie
"
)
>-
1
;(
e
||
n
||
t
)
&&
document
.
getElementById
&&
window
.
addEventListener
&&
window
.
addEventListener
(
"
hashchange
"
,
function
(){
var
e
,
n
=
location
.
hash
.
substring
(
1
);
/^
[
A-z0-9_-
]
+$/
.
test
(
n
)
&&
(
e
=
document
.
getElementById
(
n
))
&&
(
/^
(?:
a|select|input|button|textarea
)
$/i
.
test
(
e
.
tagName
)
||
(
e
.
tabIndex
=-
1
),
e
.
focus
())},
!
1
)}(),
jQuery
(
document
).
ready
(
function
(
e
){
"
use strict
"
});
\ No newline at end of file
wp-content/themes/micro/assets/scripts/inc/customizer.js
0 → 100644
View file @
e4b5b516
wp-content/themes/micro/assets/scripts/inc/navigation.js
0 → 100644
View file @
e4b5b516
jQuery
(
document
).
ready
(
function
(
$
)
{
'
use strict
'
;
/**
* The actual plugin for mobile dropdown
*/
var
mobileDropdown
=
(
function
()
{
var
settings
=
{
heightHeader
:
80
,
heightAdminbar
:
50
};
// The selector variables.
var
selector
=
{
menuIcon
:
$
(
"
.menu-toggle
"
),
dropdownArrow
:
$
(
"
span.dropdown-arrow
"
),
menuNav
:
$
(
'
.main-navigation
'
),
wavesButtonSelector
:
'
.button
'
};
var
events
=
function
()
{
// When header is clicked.
selector
.
menuIcon
.
on
(
'
click
'
,
openMenu
);
// Dropdown menu links
$
(
'
li.menu-item-has-children
'
).
on
(
'
click
'
,
$
(
this
).
closest
(
'
span.dropdown-arrow
'
),
openDropdownMenu
);
};
// Code taken from https://github.com/WordPress/twentytwenty
var
focusMenuWithChildren
=
function
()
{
// Get all the link elements within the primary menu.
var
links
,
i
,
len
,
menu
=
document
.
querySelector
(
'
.menu-primary-container
'
);
if
(
!
menu
)
{
console
.
log
(
menu
);
return
false
;
}
links
=
menu
.
getElementsByTagName
(
'
a
'
);
// Each time a menu link is focused or blurred, toggle focus.
for
(
i
=
0
,
len
=
links
.
length
;
i
<
len
;
i
++
)
{
links
[
i
].
addEventListener
(
'
focus
'
,
toggleFocus
,
true
);
links
[
i
].
addEventListener
(
'
blur
'
,
toggleFocus
,
true
);
}
// Sets or removes the .focus class on an element.
function
toggleFocus
()
{
var
self
=
this
;
// Move up through the ancestors of the current link until we hit .primary-menu.
while
(
-
1
===
self
.
className
.
indexOf
(
'
menu
'
))
{
// On li elements toggle the class .focus.
if
(
'
li
'
===
self
.
tagName
.
toLowerCase
())
{
if
(
-
1
!==
self
.
className
.
indexOf
(
'
focus
'
))
{
self
.
className
=
self
.
className
.
replace
(
'
focus
'
,
''
);
}
else
{
self
.
className
+=
'
focus
'
;
}
}
self
=
self
.
parentElement
;
}
}
}
var
openMenu
=
function
(
event
)
{
var
headerHeight
=
settings
.
heightHeader
;
var
adminbarHeight
=
settings
.
heightAdminbar
;
// No need for this when you are not logged in.
if
(
!
$
(
"
body
"
).
hasClass
(
"
admin-bar
"
)
)
{
adminbarHeight
=
0
;
}
// Change button state
$
(
this
).
toggleClass
(
'
is-opened
'
);
// Open the main menu.
selector
.
menuNav
.
toggleClass
(
'
is-extended
'
).
removeClass
(
'
init
'
);
// selector.menuNav.height( $(window).height() - headerHeight - adminbarHeight );
$
(
'
body
'
).
toggleClass
(
'
is-menu-opened
'
);
};
var
openDropdownMenu
=
function
(
event
)
{
event
.
stopImmediatePropagation
();
// Fix issue with double clicking.
$
(
this
).
toggleClass
(
"
is-extended
"
);
};
var
buildDropdownArrow
=
function
()
{
$
(
'
.menu-item-has-children
'
).
each
(
function
()
{
$
(
this
).
append
(
"
<span class='dropdown-arrow'><i class='fa fa-angle-right'></i></span>
"
);
});
};
/**
* Run the dropdown menu.
*/
var
initialiseDropdown
=
function
()
{
focusMenuWithChildren
();
buildDropdownArrow
();
events
();
};
return
{
init
:
initialiseDropdown
};
})();
mobileDropdown
.
init
();
});
\ No newline at end of file
wp-content/themes/micro/assets/scripts/inc/skip-link-focus-fix.js
0 → 100644
View file @
e4b5b516
/**
* File skip-link-focus-fix.js.
*
* Helps with accessibility for keyboard only users.
*
* Learn more: https://git.io/vWdr2
*/
(
function
()
{
var
isWebkit
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
'
webkit
'
)
>
-
1
,
isOpera
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
'
opera
'
)
>
-
1
,
isIe
=
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
'
msie
'
)
>
-
1
;
if
(
(
isWebkit
||
isOpera
||
isIe
)
&&
document
.
getElementById
&&
window
.
addEventListener
)
{
window
.
addEventListener
(
'
hashchange
'
,
function
()
{
var
id
=
location
.
hash
.
substring
(
1
),
element
;
if
(
!
(
/^
[
A-z0-9_-
]
+$/
.
test
(
id
)
)
)
{
return
;
}
element
=
document
.
getElementById
(
id
);