first
This commit is contained in:
340
wp-content/plugins/metronet-profile-picture/LICENSE
Normal file
340
wp-content/plugins/metronet-profile-picture/LICENSE
Normal file
@ -0,0 +1,340 @@
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 2, June 1991
|
||||
|
||||
Copyright (C) 1989, 1991 Free Software Foundation, Inc., <http://fsf.org/>
|
||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
License is intended to guarantee your freedom to share and change free
|
||||
software--to make sure the software is free for all its users. This
|
||||
General Public License applies to most of the Free Software
|
||||
Foundation's software and to any other program whose authors commit to
|
||||
using it. (Some other Free Software Foundation software is covered by
|
||||
the GNU Lesser General Public License instead.) You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
this service if you wish), that you receive source code or can get it
|
||||
if you want it, that you can change the software or use pieces of it
|
||||
in new free programs; and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
anyone to deny you these rights or to ask you to surrender the rights.
|
||||
These restrictions translate to certain responsibilities for you if you
|
||||
distribute copies of the software, or if you modify it.
|
||||
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must give the recipients all the rights that
|
||||
you have. You must make sure that they, too, receive or can get the
|
||||
source code. And you must show them these terms so they know their
|
||||
rights.
|
||||
|
||||
We protect your rights with two steps: (1) copyright the software, and
|
||||
(2) offer you this license which gives you legal permission to copy,
|
||||
distribute and/or modify the software.
|
||||
|
||||
Also, for each author's protection and ours, we want to make certain
|
||||
that everyone understands that there is no warranty for this free
|
||||
software. If the software is modified by someone else and passed on, we
|
||||
want its recipients to know that what they have is not the original, so
|
||||
that any problems introduced by others will not reflect on the original
|
||||
authors' reputations.
|
||||
|
||||
Finally, any free program is threatened constantly by software
|
||||
patents. We wish to avoid the danger that redistributors of a free
|
||||
program will individually obtain patent licenses, in effect making the
|
||||
program proprietary. To prevent this, we have made it clear that any
|
||||
patent must be licensed for everyone's free use or not licensed at all.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. This License applies to any program or other work which contains
|
||||
a notice placed by the copyright holder saying it may be distributed
|
||||
under the terms of this General Public License. The "Program", below,
|
||||
refers to any such program or work, and a "work based on the Program"
|
||||
means either the Program or any derivative work under copyright law:
|
||||
that is to say, a work containing the Program or a portion of it,
|
||||
either verbatim or with modifications and/or translated into another
|
||||
language. (Hereinafter, translation is included without limitation in
|
||||
the term "modification".) Each licensee is addressed as "you".
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running the Program is not restricted, and the output from the Program
|
||||
is covered only if its contents constitute a work based on the
|
||||
Program (independent of having been made by running the Program).
|
||||
Whether that is true depends on what the Program does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Program's
|
||||
source code as you receive it, in any medium, provided that you
|
||||
conspicuously and appropriately publish on each copy an appropriate
|
||||
copyright notice and disclaimer of warranty; keep intact all the
|
||||
notices that refer to this License and to the absence of any warranty;
|
||||
and give any other recipients of the Program a copy of this License
|
||||
along with the Program.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy, and
|
||||
you may at your option offer warranty protection in exchange for a fee.
|
||||
|
||||
2. You may modify your copy or copies of the Program or any portion
|
||||
of it, thus forming a work based on the Program, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a) You must cause the modified files to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
b) You must cause any work that you distribute or publish, that in
|
||||
whole or in part contains or is derived from the Program or any
|
||||
part thereof, to be licensed as a whole at no charge to all third
|
||||
parties under the terms of this License.
|
||||
|
||||
c) If the modified program normally reads commands interactively
|
||||
when run, you must cause it, when started running for such
|
||||
interactive use in the most ordinary way, to print or display an
|
||||
announcement including an appropriate copyright notice and a
|
||||
notice that there is no warranty (or else, saying that you provide
|
||||
a warranty) and that users may redistribute the program under
|
||||
these conditions, and telling the user how to view a copy of this
|
||||
License. (Exception: if the Program itself is interactive but
|
||||
does not normally print such an announcement, your work based on
|
||||
the Program is not required to print an announcement.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Program,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Program, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Program.
|
||||
|
||||
In addition, mere aggregation of another work not based on the Program
|
||||
with the Program (or with a work based on the Program) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may copy and distribute the Program (or a work based on it,
|
||||
under Section 2) in object code or executable form under the terms of
|
||||
Sections 1 and 2 above provided that you also do one of the following:
|
||||
|
||||
a) Accompany it with the complete corresponding machine-readable
|
||||
source code, which must be distributed under the terms of Sections
|
||||
1 and 2 above on a medium customarily used for software interchange; or,
|
||||
|
||||
b) Accompany it with a written offer, valid for at least three
|
||||
years, to give any third party, for a charge no more than your
|
||||
cost of physically performing source distribution, a complete
|
||||
machine-readable copy of the corresponding source code, to be
|
||||
distributed under the terms of Sections 1 and 2 above on a medium
|
||||
customarily used for software interchange; or,
|
||||
|
||||
c) Accompany it with the information you received as to the offer
|
||||
to distribute corresponding source code. (This alternative is
|
||||
allowed only for noncommercial distribution and only if you
|
||||
received the program in object code or executable form with such
|
||||
an offer, in accord with Subsection b above.)
|
||||
|
||||
The source code for a work means the preferred form of the work for
|
||||
making modifications to it. For an executable work, complete source
|
||||
code means all the source code for all modules it contains, plus any
|
||||
associated interface definition files, plus the scripts used to
|
||||
control compilation and installation of the executable. However, as a
|
||||
special exception, the source code distributed need not include
|
||||
anything that is normally distributed (in either source or binary
|
||||
form) with the major components (compiler, kernel, and so on) of the
|
||||
operating system on which the executable runs, unless that component
|
||||
itself accompanies the executable.
|
||||
|
||||
If distribution of executable or object code is made by offering
|
||||
access to copy from a designated place, then offering equivalent
|
||||
access to copy the source code from the same place counts as
|
||||
distribution of the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
4. You may not copy, modify, sublicense, or distribute the Program
|
||||
except as expressly provided under this License. Any attempt
|
||||
otherwise to copy, modify, sublicense or distribute the Program is
|
||||
void, and will automatically terminate your rights under this License.
|
||||
However, parties who have received copies, or rights, from you under
|
||||
this License will not have their licenses terminated so long as such
|
||||
parties remain in full compliance.
|
||||
|
||||
5. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Program or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Program (or any work based on the
|
||||
Program), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Program or works based on it.
|
||||
|
||||
6. Each time you redistribute the Program (or any work based on the
|
||||
Program), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute or modify the Program subject to
|
||||
these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties to
|
||||
this License.
|
||||
|
||||
7. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Program at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Program by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Program.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable under
|
||||
any particular circumstance, the balance of the section is intended to
|
||||
apply and the section as a whole is intended to apply in other
|
||||
circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system, which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
8. If the distribution and/or use of the Program is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Program under this License
|
||||
may add an explicit geographical distribution limitation excluding
|
||||
those countries, so that distribution is permitted only in or among
|
||||
countries not thus excluded. In such case, this License incorporates
|
||||
the limitation as if written in the body of this License.
|
||||
|
||||
9. The Free Software Foundation may publish revised and/or new versions
|
||||
of the General Public License from time to time. Such new versions will
|
||||
be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the Program
|
||||
specifies a version number of this License which applies to it and "any
|
||||
later version", you have the option of following the terms and conditions
|
||||
either of that version or of any later version published by the Free
|
||||
Software Foundation. If the Program does not specify a version number of
|
||||
this License, you may choose any version ever published by the Free Software
|
||||
Foundation.
|
||||
|
||||
10. If you wish to incorporate parts of the Program into other free
|
||||
programs whose distribution conditions are different, write to the author
|
||||
to ask for permission. For software which is copyrighted by the Free
|
||||
Software Foundation, write to the Free Software Foundation; we sometimes
|
||||
make exceptions for this. Our decision will be guided by the two goals
|
||||
of preserving the free status of all derivatives of our free software and
|
||||
of promoting the sharing and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
|
||||
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
|
||||
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
|
||||
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
|
||||
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
|
||||
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
|
||||
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
|
||||
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
|
||||
REPAIR OR CORRECTION.
|
||||
|
||||
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
|
||||
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
|
||||
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
|
||||
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
|
||||
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
|
||||
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
|
||||
POSSIBILITY OF SUCH DAMAGES.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
convey the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
{description}
|
||||
Copyright (C) {year} {fullname}
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License along
|
||||
with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program is interactive, make it output a short notice like this
|
||||
when it starts in an interactive mode:
|
||||
|
||||
Gnomovision version 69, Copyright (C) year name of author
|
||||
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, the commands you use may
|
||||
be called something other than `show w' and `show c'; they could even be
|
||||
mouse-clicks or menu items--whatever suits your program.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or your
|
||||
school, if any, to sign a "copyright disclaimer" for the program, if
|
||||
necessary. Here is a sample; alter the names:
|
||||
|
||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
|
||||
`Gnomovision' (which makes passes at compilers) written by James Hacker.
|
||||
|
||||
{signature of Ty Coon}, 1 April 1989
|
||||
Ty Coon, President of Vice
|
||||
|
||||
This General Public License does not permit incorporating your program into
|
||||
proprietary programs. If your program is a subroutine library, you may
|
||||
consider it more useful to permit linking proprietary applications with the
|
||||
library. If this is what you want to do, use the GNU Lesser General
|
||||
Public License instead of this License.
|
||||
|
@ -0,0 +1,634 @@
|
||||
.editor-styles-wrapper .mpp-profile-wrap {
|
||||
margin: 0 auto;
|
||||
padding: 3%;
|
||||
border-radius: 5px;
|
||||
margin-bottom: 1.2em;
|
||||
margin-bottom: 20px;
|
||||
line-height: 1.1;
|
||||
&.round .mpp-profile-image-wrapper {
|
||||
border-radius: 50%;
|
||||
overflow: hidden;
|
||||
}
|
||||
&.round .mpp-profile-image-wrapper img {
|
||||
border-radius: 50%;
|
||||
}
|
||||
h1,h2,h3,h4,h5,h6 {
|
||||
clear: none;
|
||||
}
|
||||
h2:before {
|
||||
display: none;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.1;
|
||||
z-index: 1000;
|
||||
background: #ddd;
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
width: 100%;
|
||||
margin-right: 20px;
|
||||
button {
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
z-index: 1000;
|
||||
}
|
||||
.mpp-profile-image-square {
|
||||
position: relative;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
z-index: 5;
|
||||
}
|
||||
.mpp-profile-image-square img {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
z-index: 5;
|
||||
}
|
||||
.mpp-content-wrap {
|
||||
display: block;
|
||||
padding: 0 15px 0 15px;
|
||||
-ms-flex: 3 0 0px;
|
||||
flex: 3 0 0;
|
||||
}
|
||||
.mpp-profile-name {
|
||||
font: 1.4em;
|
||||
line-height: 1.2;
|
||||
}
|
||||
@media only screen and (max-width: 600px) {
|
||||
flex: auto;
|
||||
}
|
||||
}
|
||||
.mpp-profile-view-posts {
|
||||
display: block;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
background-color: #cf6d38;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.editor-styles-wrapper .mpp-enhanced-profile-wrap.regular {
|
||||
position: relative;
|
||||
margin: 0 auto;
|
||||
line-height: 1.1;
|
||||
&.round .mpp-profile-image-wrapper {
|
||||
border-radius: 50%;
|
||||
overflow: hidden;
|
||||
}
|
||||
&.round .mpp-profile-image-wrapper img {
|
||||
border-radius: 50%;
|
||||
}
|
||||
h2:before {
|
||||
display: none;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.1;
|
||||
z-index: 1000;
|
||||
background: #ddd;
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
width: 100%;
|
||||
margin-right: 20px;
|
||||
button {
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
z-index: 1000;
|
||||
}
|
||||
.mpp-profile-image-square {
|
||||
position: relative;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
z-index: 5;
|
||||
}
|
||||
.mpp-profile-image-square img {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
z-index: 5;
|
||||
}
|
||||
.mpp-content-wrap {
|
||||
display: block;
|
||||
padding: 0 15px 0 15px;
|
||||
-ms-flex: 3 0 0px;
|
||||
flex: 3 0 0;
|
||||
}
|
||||
.mpp-profile-name {
|
||||
font: 1.4em;
|
||||
line-height: 1.2;
|
||||
}
|
||||
@media only screen and (max-width: 600px) {
|
||||
flex: auto;
|
||||
}
|
||||
}
|
||||
.mpp-gutenberg-view-posts {
|
||||
clear: both;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-profile-view-posts {
|
||||
clear: both;
|
||||
display: block;
|
||||
float: left;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
margin-right: 20px;
|
||||
background-color: #cf6d38;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-profile-view-website {
|
||||
display: block;
|
||||
float: left;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
background-color: #333;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
&.right .mpp-profile-view-posts {
|
||||
float: right;
|
||||
margin-left: 20px;
|
||||
}
|
||||
&.center .mpp-profile-view-posts {
|
||||
display: inline-block;
|
||||
float: none;
|
||||
margin-left: 20px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Icon Sizes */
|
||||
$sizes: 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24;
|
||||
@each $size in $sizes {
|
||||
.editor-styles-wrapper .mpp-profile-wrap.mt-font-size-#{$size},
|
||||
.editor-styles-wrapper .mpp-enhanced-profile-wrap.regular .mt-font-size-#{$size},
|
||||
.editor-styles-wrapper .mpp-enhanced-profile-wrap.profile .mt-font-size-#{$size},
|
||||
.editor-styles-wrapper .mpp-enhanced-profile-wrap.compact .mt-font-size-#{$size},
|
||||
.editor-styles-wrapper .mpp-profile-text.mt-font-size-#{$size} {
|
||||
font-size: #{$size}px;
|
||||
p,
|
||||
div {
|
||||
font-size: #{$size}px;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/* For Social Media */
|
||||
.mpp-social {
|
||||
margin-top: 15px;
|
||||
svg {
|
||||
max-width: 32px;
|
||||
max-height: 32px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
}
|
||||
/* Social Media Colors */
|
||||
$colors: twitter #00aced,
|
||||
amazon #000000,
|
||||
behance #0692e9,
|
||||
blogger #fb8f3d,
|
||||
codepen #000000,
|
||||
dribble #F46899,
|
||||
dropbox #018BD3,
|
||||
eventbrite #f6682F,
|
||||
facebook #3b5998,
|
||||
flickr #ff0084,
|
||||
foursquare #0072b1,
|
||||
ghost #000000,
|
||||
github #070709,
|
||||
google-plus #CF3D2E,
|
||||
instagram #A1755C,
|
||||
linkedin #0085AE,
|
||||
feed #f26522,
|
||||
medium #000000,
|
||||
path #000000,
|
||||
pinterest #CC2127,
|
||||
pocket #000000,
|
||||
polldaddy #bc0b0b,
|
||||
reddit #000000,
|
||||
skype #01AEF2,
|
||||
spotify #1ed760,
|
||||
squarespace #000000,
|
||||
stumbleupon #EB4823,
|
||||
telegram #000000,
|
||||
tumblr-alt #314E6C,
|
||||
twitch #4b367c,
|
||||
twitter-alt #00aced,
|
||||
vimeo #1ab7ea,
|
||||
wordpress #21759b,
|
||||
youtube #bb0000
|
||||
;
|
||||
.mpp-social {
|
||||
clear: both;
|
||||
}
|
||||
.mpp-social svg {
|
||||
@each $color in $colors {
|
||||
&.icon-#{nth($color,1)} {
|
||||
fill: #{nth($color,2)};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* For Profile Theme */
|
||||
.editor-styles-wrapper .mpp-enhanced-profile-wrap.profile {
|
||||
padding: 10px;
|
||||
h2 {
|
||||
font-size: 0.8em;
|
||||
font-weight: normal;
|
||||
margin-bottom: 5px;
|
||||
&:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
&.round .profile-avatar {
|
||||
border-radius: 50%;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.0;
|
||||
z-index: 1000;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
margin-right: 15px;
|
||||
}
|
||||
.mpp-profile-meta {
|
||||
clear: both;
|
||||
margin: 10px 0;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
.alignleft {
|
||||
max-width: none;
|
||||
float: left;
|
||||
}
|
||||
.alignright {
|
||||
max-width: none;
|
||||
float: right;
|
||||
}
|
||||
}
|
||||
|
||||
/* For Tabbed Theme */
|
||||
.editor-styles-wrapper .mpp-author-tabbed {
|
||||
padding: 10px;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
.mpp-social {
|
||||
margin-top: 0;
|
||||
}
|
||||
.mpp-author-social-wrapper {
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
h2 {
|
||||
font-size: 0.8em;
|
||||
font-weight: normal;
|
||||
margin-bottom: 5px;
|
||||
&:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.mpp-tab-wrapper {
|
||||
clear: both;
|
||||
}
|
||||
.mpp-author-heading {
|
||||
float: left;
|
||||
}
|
||||
.mpp-author-social {
|
||||
float: right;
|
||||
}
|
||||
.mpp-author-heading .mpp-author-profile-heading {
|
||||
display: inline-block;
|
||||
background: #42737b;
|
||||
color: #FFF;
|
||||
padding: 10px 20px;
|
||||
font-size: 14px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
.mpp-author-profile-sub-heading {
|
||||
font-size: 14px;
|
||||
line-height: 1.1;
|
||||
max-width: 150px;
|
||||
text-align: center;
|
||||
}
|
||||
&.round .profile-avatar {
|
||||
border-radius: 50%;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
clear: both;
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.0;
|
||||
z-index: 1000;
|
||||
margin-right: 30px;
|
||||
img {
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-height: 150px;
|
||||
max-width: 150px;
|
||||
}
|
||||
|
||||
}
|
||||
.mpp-profile-meta {
|
||||
clear: both;
|
||||
margin: 10px 0;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
.mpp-author-profile-title {
|
||||
color: gray;
|
||||
text-transform: uppercase;
|
||||
font-size: 12px;
|
||||
}
|
||||
.mpp-tabbed-profile-information {
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
ul.mpp-author-tabs {
|
||||
position:relative;
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
|
||||
li {
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
min-width: 200px;
|
||||
background: #42737b;
|
||||
margin: 0 5px 0 0;
|
||||
text-align: center;
|
||||
margin-right: 10px;
|
||||
color: #FFF;
|
||||
padding: 10px 20px;
|
||||
font-size: 16px;
|
||||
}
|
||||
li:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
li.mpp-tab-posts {
|
||||
background: #30424b;
|
||||
}
|
||||
}
|
||||
ul.mpp-author-tab-content {
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
li {
|
||||
margin: 0;
|
||||
}
|
||||
&.white {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #FFFFFF;
|
||||
border: 1px solid darken(#FFFFFF, 5%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
color: #333;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#FFFFFF, 5%);
|
||||
}
|
||||
}
|
||||
&.light {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #f7f7f7;
|
||||
border: 1px solid darken(#f7f7f7, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
color: #333;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#f7f7f7, 10%);
|
||||
}
|
||||
}
|
||||
&.black {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #333;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#333, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#333, 10%);
|
||||
}
|
||||
}
|
||||
&.magenta {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #FF00FF;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#FF00FF, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#FF00FF, 10%);
|
||||
}
|
||||
}
|
||||
&.blue {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #0009c1;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#0009c1, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#0009c1, 10%);
|
||||
}
|
||||
}
|
||||
&.green {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #03ac27;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#03ac27, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#03ac27, 10%);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* For Compact Theme */
|
||||
.editor-styles-wrapper .mpp-enhanced-profile-wrap.compact {
|
||||
text-align: center;
|
||||
padding: 10px;
|
||||
max-width: 400px;
|
||||
margin: 0 auto;
|
||||
line-height: 1.1;
|
||||
h2 {
|
||||
font-size: 0.8em;
|
||||
font-weight: normal;
|
||||
margin-bottom: 5px;
|
||||
&:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
&.round .profile-avatar {
|
||||
border-radius: 50%;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
text-align: center;
|
||||
line-height: 1.0;
|
||||
z-index: 1000;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
.mpp-profile-text {
|
||||
line-height: 1.1;
|
||||
}
|
||||
.mpp-compact-meta {
|
||||
clear: both;
|
||||
margin: 10px 0;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
.mpp-profile-view-posts {
|
||||
clear: both;
|
||||
display: block;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
margin-right: 20px;
|
||||
background-color: #cf6d38;
|
||||
color: #FFF;
|
||||
margin-bottom: 10px;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-profile-view-website {
|
||||
display: block;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
background-color: #333;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,767 @@
|
||||
.post-content .mpp-profile-wrap,
|
||||
.post-content .mpp-enhanced-profile-wrap {
|
||||
h1, h2 , h3, h4 , h5, h6 {
|
||||
clear: none;
|
||||
}
|
||||
h2 {
|
||||
margin: 0;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
p {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
}
|
||||
.mpp-profile-wrap {
|
||||
margin: 0 auto;
|
||||
padding: 3%;
|
||||
border-radius: 5px;
|
||||
margin-bottom: 1.2em;
|
||||
margin-bottom: 20px;
|
||||
line-height: 1.3;
|
||||
&.round .mpp-profile-image-wrapper {
|
||||
border-radius: 50%;
|
||||
overflow: hidden;
|
||||
}
|
||||
&.round .mpp-profile-image-wrapper img {
|
||||
border-radius: 50%;
|
||||
}
|
||||
h1,h2,h3,h4,h5,h6 {
|
||||
clear: none;
|
||||
}
|
||||
h2 {
|
||||
margin-top: 0;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
h2:before {
|
||||
display: none;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.1;
|
||||
z-index: 1000;
|
||||
background: #ddd;
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
width: 100%;
|
||||
margin-right: 20px;
|
||||
margin-bottom: 20px;
|
||||
button {
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
z-index: 1000;
|
||||
}
|
||||
.mpp-profile-image-square {
|
||||
position: relative;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
z-index: 5;
|
||||
}
|
||||
.mpp-profile-image-square img {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
z-index: 5;
|
||||
}
|
||||
.mpp-content-wrap {
|
||||
display: block;
|
||||
padding: 0 15px 0 15px;
|
||||
-ms-flex: 3 0 0px;
|
||||
flex: 3 0 0;
|
||||
}
|
||||
.mpp-profile-name {
|
||||
font: 1.4em;
|
||||
line-height: 1.2;
|
||||
}
|
||||
@media only screen and (max-width: 600px) {
|
||||
flex: auto;
|
||||
}
|
||||
}
|
||||
.mpp-gutenberg-view-posts {
|
||||
clear: both;
|
||||
padding-top: 20px;
|
||||
}
|
||||
.mpp-profile-view-posts {
|
||||
clear: both;
|
||||
display: block;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
background-color: #cf6d38;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-enhanced-profile-wrap.regular {
|
||||
position: relative;
|
||||
margin: 0 auto;
|
||||
line-height: 1.5;
|
||||
&.round .mpp-profile-image-wrapper {
|
||||
border-radius: 50%;
|
||||
overflow: hidden;
|
||||
}
|
||||
&.round .mpp-profile-image-wrapper img {
|
||||
border-radius: 50%;
|
||||
}
|
||||
h1,h2,h3,h4,h5,h6 {
|
||||
clear: none;
|
||||
}
|
||||
h2:before {
|
||||
display: none;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.1;
|
||||
z-index: 1000;
|
||||
background: #ddd;
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
width: 100%;
|
||||
margin-right: 20px;
|
||||
margin-bottom: 20px;
|
||||
@media only screen and (max-width: 400px) {
|
||||
float: none;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
}
|
||||
button {
|
||||
position: relative;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
z-index: 1000;
|
||||
}
|
||||
.mpp-profile-image-square {
|
||||
position: relative;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
z-index: 5;
|
||||
|
||||
}
|
||||
.mpp-profile-image-square img {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
z-index: 5;
|
||||
}
|
||||
.mpp-content-wrap {
|
||||
display: block;
|
||||
padding: 0 15px 0 15px;
|
||||
-ms-flex: 3 0 0px;
|
||||
flex: 3 0 0;
|
||||
@media only screen and (max-width: 400px) {
|
||||
display: block;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
.mpp-profile-name {
|
||||
font: 1.4em;
|
||||
line-height: 1.2;
|
||||
}
|
||||
@media only screen and (max-width: 600px) {
|
||||
flex: auto;
|
||||
}
|
||||
}
|
||||
.mpp-content-wrap {
|
||||
@media only screen and (max-width: 400px) {
|
||||
display: block;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
.mpp-gutenberg-view-posts {
|
||||
clear: both;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-profile-view-posts {
|
||||
clear: both;
|
||||
display: block;
|
||||
float: left;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
margin-right: 20px;
|
||||
background-color: #cf6d38;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
@media only screen and (max-width: 400px) {
|
||||
display: block;
|
||||
width: 90%;
|
||||
margin: 0 auto;
|
||||
text-align: center;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-profile-view-website {
|
||||
display: block;
|
||||
float: left;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
background-color: #333;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
@media only screen and (max-width: 400px) {
|
||||
display: block;
|
||||
width: 90%;
|
||||
margin: 0 auto;
|
||||
text-align: center;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Icon Sizes */
|
||||
$sizes: 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24;
|
||||
@each $size in $sizes {
|
||||
.mpp-profile-wrap.mt-font-size-#{$size},
|
||||
.mpp-enhanced-profile-wrap.regular .mt-font-size-#{$size},
|
||||
.mpp-enhanced-profile-wrap.profile .mt-font-size-#{$size},
|
||||
.mpp-enhanced-profile-wrap.compact .mt-font-size-#{$size},
|
||||
.mpp-profile-text.mt-font-size-#{$size} {
|
||||
font-size: #{$size}px;
|
||||
p,
|
||||
div {
|
||||
font-size: #{$size}px;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/* For Social Media */
|
||||
.mpp-social {
|
||||
margin-top: 15px;
|
||||
svg {
|
||||
max-width: 32px;
|
||||
max-height: 32px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
text-decoration: none !important;
|
||||
}
|
||||
}
|
||||
/* Social Media Colors */
|
||||
$colors: twitter #00aced,
|
||||
amazon #000000,
|
||||
behance #0692e9,
|
||||
blogger #fb8f3d,
|
||||
codepen #000000,
|
||||
dribble #F46899,
|
||||
dropbox #018BD3,
|
||||
eventbrite #f6682F,
|
||||
facebook #3b5998,
|
||||
flickr #ff0084,
|
||||
foursquare #0072b1,
|
||||
ghost #000000,
|
||||
github #070709,
|
||||
google-plus #CF3D2E,
|
||||
instagram #A1755C,
|
||||
linkedin #0085AE,
|
||||
feed #f26522,
|
||||
medium #000000,
|
||||
path #000000,
|
||||
pinterest #CC2127,
|
||||
pocket #000000,
|
||||
polldaddy #bc0b0b,
|
||||
reddit #000000,
|
||||
skype #01AEF2,
|
||||
spotify #1ed760,
|
||||
squarespace #000000,
|
||||
stumbleupon #EB4823,
|
||||
telegram #000000,
|
||||
tumblr-alt #314E6C,
|
||||
twitch #4b367c,
|
||||
twitter-alt #00aced,
|
||||
vimeo #1ab7ea,
|
||||
wordpress #21759b,
|
||||
youtube #bb0000
|
||||
;
|
||||
.mpp-social {
|
||||
clear: both;
|
||||
}
|
||||
.mpp-social svg {
|
||||
@each $color in $colors {
|
||||
&.icon-#{nth($color,1)} {
|
||||
fill: #{nth($color,2)};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-enhanced-profile-wrap.profile {
|
||||
padding: 10px;
|
||||
h2 {
|
||||
margin: 0;
|
||||
font-size: 0.8em;
|
||||
font-weight: normal;
|
||||
margin-bottom: 5px;
|
||||
&:before {
|
||||
display: none;
|
||||
}
|
||||
@media only screen and (max-width: 400px) {
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
&.round .profile-avatar {
|
||||
border-radius: 50%;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.0;
|
||||
z-index: 1000;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
margin-right: 15px;
|
||||
|
||||
@media only screen and (max-width: 400px) {
|
||||
float: none;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
.mpp-profile-meta {
|
||||
clear: both;
|
||||
margin: 10px 0;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
.alignleft {
|
||||
max-width: none;
|
||||
float: left;
|
||||
@media only screen and (max-width: 400px) {
|
||||
float: none;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
.alignright {
|
||||
max-width: none;
|
||||
@media only screen and (max-width: 400px) {
|
||||
float: none;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* For Tabbed Theme */
|
||||
.mpp-author-tabbed {
|
||||
padding: 10px;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
.mpp-social {
|
||||
margin-top: 0;
|
||||
}
|
||||
.mpp-author-social-wrapper {
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
h1, h2, h3, h4, h5 , h6 {
|
||||
clear: none;
|
||||
}
|
||||
h2 {
|
||||
font-size: 0.8em;
|
||||
font-weight: normal;
|
||||
margin-bottom: 5px;
|
||||
&:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.mpp-tab-wrapper {
|
||||
clear: both;
|
||||
}
|
||||
.mpp-author-heading {
|
||||
float: left;
|
||||
@media only screen and (max-width: 600px) {
|
||||
float: none;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
width: 90%;
|
||||
}
|
||||
}
|
||||
.mpp-author-social {
|
||||
float: right;
|
||||
@media only screen and (max-width: 600px) {
|
||||
float: none;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
.mpp-author-heading .mpp-author-profile-heading {
|
||||
display: inline-block;
|
||||
background: #42737b;
|
||||
color: #FFF;
|
||||
padding: 10px 20px;
|
||||
font-size: 14px;
|
||||
text-transform: uppercase;
|
||||
@media only screen and (max-width: 600px) {
|
||||
display: block;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
}
|
||||
.mpp-author-profile-sub-heading {
|
||||
font-size: 14px;
|
||||
line-height: 1.1;
|
||||
max-width: 150px;
|
||||
text-align: center;
|
||||
}
|
||||
&.round .profile-avatar {
|
||||
border-radius: 50%;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
clear: both;
|
||||
position: relative;
|
||||
float: left;
|
||||
line-height: 1.0;
|
||||
z-index: 1000;
|
||||
margin-right: 30px;
|
||||
img {
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-height: 150px;
|
||||
max-width: 150px;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
.mpp-profile-meta {
|
||||
clear: both;
|
||||
margin: 10px 0;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
.mpp-author-profile-title {
|
||||
color: gray;
|
||||
text-transform: uppercase;
|
||||
font-size: 12px;
|
||||
}
|
||||
.mpp-tabbed-profile-information {
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
.mpp-tab {
|
||||
display: none;
|
||||
}
|
||||
.mpp-tab-active {
|
||||
display: block;
|
||||
}
|
||||
ul.mpp-author-tabs {
|
||||
position:relative;
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
|
||||
li {
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
min-width: 200px;
|
||||
background: #42737b;
|
||||
margin: 0 5px 0 0;
|
||||
text-align: center;
|
||||
margin-right: 10px;
|
||||
color: #FFF;
|
||||
padding: 10px 20px;
|
||||
font-size: 16px;
|
||||
@media only screen and (max-width: 500px) {
|
||||
width: 100%;
|
||||
display: block;
|
||||
}
|
||||
|
||||
&.active:after {
|
||||
content: "";
|
||||
display: block;
|
||||
position: absolute;
|
||||
bottom: -10px;
|
||||
left: calc(50% - 10px);
|
||||
border-top: 10px solid #42737b;
|
||||
border-top-color: #42737b;
|
||||
border-left: 10px solid transparent;
|
||||
border-right: 10px solid transparent;
|
||||
@media only screen and (max-width: 500px) {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
li:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
li.mpp-tab-posts {
|
||||
background: #30424b;
|
||||
&.active:after {
|
||||
border-top: 10px solid #30424b;
|
||||
border-top-color: #30424b;
|
||||
}
|
||||
}
|
||||
}
|
||||
ul.mpp-author-tab-content {
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
li {
|
||||
margin: 0;
|
||||
}
|
||||
&.white {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #FFFFFF;
|
||||
border: 1px solid darken(#FFFFFF, 5%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
color: #333;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#FFFFFF, 5%);
|
||||
}
|
||||
}
|
||||
&.light {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #f7f7f7;
|
||||
border: 1px solid darken(#f7f7f7, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
color: #333;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#f7f7f7, 10%);
|
||||
}
|
||||
}
|
||||
&.black {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #333;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#333, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#333, 10%);
|
||||
}
|
||||
}
|
||||
&.magenta {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #FF00FF;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#FF00FF, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#FF00FF, 10%);
|
||||
}
|
||||
}
|
||||
&.blue {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #0009c1;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#0009c1, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#0009c1, 10%);
|
||||
}
|
||||
}
|
||||
&.green {
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
background: #03ac27;
|
||||
color: #FFF;
|
||||
border: 1px solid darken(#03ac27, 10%);
|
||||
padding: 10px 20px;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
background: darken(#03ac27, 10%);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* For Compact Theme */
|
||||
.mpp-enhanced-profile-wrap.compact {
|
||||
text-align: center;
|
||||
padding: 10px;
|
||||
max-width: 400px;
|
||||
margin: 0 auto;
|
||||
line-height: 1.1;
|
||||
&.center {
|
||||
margin: 0 auto;
|
||||
}
|
||||
&.left {
|
||||
margin-left: 0;
|
||||
}
|
||||
&.right {
|
||||
margin-right: 0;
|
||||
}
|
||||
.mpp-social svg {
|
||||
margin-right: 0;
|
||||
}
|
||||
h2 {
|
||||
font-size: 0.8em;
|
||||
font-weight: normal;
|
||||
margin-bottom: 5px;
|
||||
&:before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
&.round .profile-avatar {
|
||||
border-radius: 50%;
|
||||
}
|
||||
.mpp-profile-image-wrapper {
|
||||
position: relative;
|
||||
text-align: center;
|
||||
line-height: 1.0;
|
||||
z-index: 1000;
|
||||
min-width: 150px;
|
||||
min-height: 150px;
|
||||
max-width: 150px;
|
||||
max-height: 150px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
.mpp-profile-text {
|
||||
line-height: 1.1;
|
||||
}
|
||||
.mpp-compact-meta {
|
||||
clear: both;
|
||||
margin: 10px 0;
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
.mpp-profile-view-posts {
|
||||
clear: both;
|
||||
display: block;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
margin-right: 20px;
|
||||
background-color: #cf6d38;
|
||||
color: #FFF;
|
||||
margin-bottom: 10px;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
&:after {
|
||||
content: "";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
|
||||
.mpp-profile-view-website {
|
||||
display: block;
|
||||
text-align: center;
|
||||
padding: 10px 20px;
|
||||
margin-top: 20px;
|
||||
background-color: #333;
|
||||
color: #FFF;
|
||||
a,
|
||||
a:hover,
|
||||
a:visited {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: #FFF;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
4
wp-content/plugins/metronet-profile-picture/dist/blocks.build.css
vendored
Normal file
4
wp-content/plugins/metronet-profile-picture/dist/blocks.build.css
vendored
Normal file
File diff suppressed because one or more lines are too long
1
wp-content/plugins/metronet-profile-picture/dist/blocks.build.css.map
vendored
Normal file
1
wp-content/plugins/metronet-profile-picture/dist/blocks.build.css.map
vendored
Normal file
File diff suppressed because one or more lines are too long
3
wp-content/plugins/metronet-profile-picture/dist/blocks.build.js
vendored
Normal file
3
wp-content/plugins/metronet-profile-picture/dist/blocks.build.js
vendored
Normal file
File diff suppressed because one or more lines are too long
5
wp-content/plugins/metronet-profile-picture/dist/blocks.build.js.LICENSE.txt
vendored
Normal file
5
wp-content/plugins/metronet-profile-picture/dist/blocks.build.js.LICENSE.txt
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*!
|
||||
Copyright (c) 2017 Jed Watson.
|
||||
Licensed under the MIT License (MIT), see
|
||||
http://jedwatson.github.io/classnames
|
||||
*/
|
1
wp-content/plugins/metronet-profile-picture/dist/blocks.build.js.map
vendored
Normal file
1
wp-content/plugins/metronet-profile-picture/dist/blocks.build.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
3
wp-content/plugins/metronet-profile-picture/dist/blocks.editor.build.css
vendored
Normal file
3
wp-content/plugins/metronet-profile-picture/dist/blocks.editor.build.css
vendored
Normal file
File diff suppressed because one or more lines are too long
1
wp-content/plugins/metronet-profile-picture/dist/blocks.editor.build.css.map
vendored
Normal file
1
wp-content/plugins/metronet-profile-picture/dist/blocks.editor.build.css.map
vendored
Normal file
File diff suppressed because one or more lines are too long
3
wp-content/plugins/metronet-profile-picture/dist/blocks.style.build.css
vendored
Normal file
3
wp-content/plugins/metronet-profile-picture/dist/blocks.style.build.css
vendored
Normal file
File diff suppressed because one or more lines are too long
1
wp-content/plugins/metronet-profile-picture/dist/blocks.style.build.css.map
vendored
Normal file
1
wp-content/plugins/metronet-profile-picture/dist/blocks.style.build.css.map
vendored
Normal file
File diff suppressed because one or more lines are too long
@ -0,0 +1,653 @@
|
||||
<?php // phpcs:ignore
|
||||
// Prevent direct file access.
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
die( 'No direct access' );
|
||||
}
|
||||
/**
|
||||
* Gutenberg class for Metronet Profile Picture
|
||||
*
|
||||
* Gutenberg class for Metronet Profile Picture
|
||||
*
|
||||
* @category Metronet Metronet Profile Picture
|
||||
* @package Metronet Metronet Profile Picture
|
||||
* @author Ronald Huereca <ronald@mediaron.com>
|
||||
* @license GPL-2.0+
|
||||
* @link https://github.com/ronalfy/user-profile-picture
|
||||
*
|
||||
* @since 2.0.0
|
||||
*/
|
||||
class Metronet_Profile_Picture_Gutenberg {
|
||||
/**
|
||||
* Class constructor.
|
||||
*/
|
||||
public function __construct() {
|
||||
if ( ! function_exists( 'register_block_type' ) ) {
|
||||
return;
|
||||
}
|
||||
|
||||
add_action( 'init', array( $this, 'register_block' ) );
|
||||
add_action( 'enqueue_block_assets', array( $this, 'add_gutenberg_styles' ) );
|
||||
add_action( 'enqueue_block_editor_assets', array( $this, 'add_gutenberg_scripts' ) );
|
||||
add_action( 'admin_footer', array( $this, 'load_gutenblock_svgs' ) );
|
||||
}
|
||||
|
||||
/**
|
||||
* Register the main User Profile Picture block.
|
||||
*/
|
||||
public function register_block() {
|
||||
register_block_type(
|
||||
'mpp/user-profile',
|
||||
array(
|
||||
'attributes' => array(),
|
||||
)
|
||||
);
|
||||
register_block_type(
|
||||
'mpp/user-profile-enhanced',
|
||||
array(
|
||||
'attributes' => array(
|
||||
'profileName' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'theme' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'regular',
|
||||
),
|
||||
'profileTitle' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'profileContent' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'profileViewPosts' => array(
|
||||
'type' => 'string',
|
||||
'default' => __( 'View Posts', 'metronet-profile-picture' ),
|
||||
),
|
||||
'profileViewWebsite' => array(
|
||||
'type' => 'string',
|
||||
'default' => __( 'View Website', 'metronet-profile-picture' ),
|
||||
),
|
||||
'profileAlignment' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'profileImgURL' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'profileImgID' => array(
|
||||
'type' => 'number',
|
||||
'default' => '',
|
||||
),
|
||||
'profileURL' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'padding' => array(
|
||||
'type' => 'number',
|
||||
'default' => 0,
|
||||
),
|
||||
'border' => array(
|
||||
'type' => 'number',
|
||||
'default' => 0,
|
||||
),
|
||||
'borderRounded' => array(
|
||||
'type' => 'number',
|
||||
'default' => 0,
|
||||
),
|
||||
'borderColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#f2f2f2',
|
||||
),
|
||||
'profileBackgroundColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#f2f2f2',
|
||||
),
|
||||
'profileTextColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#32373c',
|
||||
),
|
||||
'profileViewPostsBackgroundColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#cf6d38',
|
||||
),
|
||||
'profileViewPostsTextColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#FFFFFF',
|
||||
),
|
||||
'profileWebsiteBackgroundColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#000000',
|
||||
),
|
||||
'profileWebsiteTextColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#FFFFFF',
|
||||
),
|
||||
'profileLinkColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'inherit',
|
||||
),
|
||||
'headerFontSize' => array(
|
||||
'type' => 'number',
|
||||
'default' => 24,
|
||||
),
|
||||
'buttonFontSize' => array(
|
||||
'type' => 'number',
|
||||
'default' => 16,
|
||||
),
|
||||
'profileFontSize' => array(
|
||||
'type' => 'number',
|
||||
'default' => 18,
|
||||
),
|
||||
'profileAvatarShape' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'square',
|
||||
),
|
||||
'showName' => array(
|
||||
'type' => 'boolean',
|
||||
'default' => true,
|
||||
),
|
||||
'showTitle' => array(
|
||||
'type' => 'boolean',
|
||||
'default' => true,
|
||||
),
|
||||
'showDescription' => array(
|
||||
'type' => 'boolean',
|
||||
'default' => true,
|
||||
),
|
||||
'showViewPosts' => array(
|
||||
'type' => 'boolean',
|
||||
'default' => true,
|
||||
),
|
||||
'showWebsite' => array(
|
||||
'type' => 'boolean',
|
||||
'default' => true,
|
||||
),
|
||||
'user_id' => array(
|
||||
'type' => 'number',
|
||||
'default' => 0,
|
||||
),
|
||||
'socialFacebook' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialTwitter' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialYouTube' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialLinkedIn' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialWordPress' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialGitHub' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialPinterest' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialInstagram' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'website' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'socialMediaOptions' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'colors',
|
||||
),
|
||||
'socialMediaColors' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#000000',
|
||||
),
|
||||
'tabbedAuthorProfile' => array(
|
||||
'type' => 'string',
|
||||
'default' => __( 'Author Details', 'metronet-profile-picture' ),
|
||||
),
|
||||
'tabbedAuthorProfileHeading' => array(
|
||||
'type' => 'string',
|
||||
'default' => __( 'Author Details', 'metronet-profile-picture' ),
|
||||
),
|
||||
'tabbedAuthorLatestPosts' => array(
|
||||
'type' => 'string',
|
||||
'default' => __( 'Latest Posts', 'metronet-profile-picture' ),
|
||||
),
|
||||
'tabbedAuthorSubHeading' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'tabbedAuthorProfileTitle' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'profileTabHeadlineColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#42737b',
|
||||
),
|
||||
'profileTabColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#42737b',
|
||||
),
|
||||
'profileTabPostsColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#30424b',
|
||||
),
|
||||
'profileTabHeadlineTextColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#FFFFFF',
|
||||
),
|
||||
'profileTabTextColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#FFFFFF',
|
||||
),
|
||||
'profileTabPostsTextColor' => array(
|
||||
'type' => 'string',
|
||||
'default' => '#FFFFFF',
|
||||
),
|
||||
'profileLatestPostsOptionsValue' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'light',
|
||||
),
|
||||
'profileCompactAlignment' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'center',
|
||||
),
|
||||
'showPostsWidth' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
'showSocialMedia' => array(
|
||||
'type' => 'boolean',
|
||||
'default' => true,
|
||||
),
|
||||
'profileName' => array(
|
||||
'type' => 'string',
|
||||
'default' => '',
|
||||
),
|
||||
|
||||
),
|
||||
'render_callback' => array( $this, 'display_frontend' ),
|
||||
'editor_script' => 'mpp_gutenberg',
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Display the front-end for the Gutenberg block.
|
||||
*
|
||||
* @param array $attributes Array of block attributes.
|
||||
*/
|
||||
public function display_frontend( $attributes ) {
|
||||
if ( is_admin() ) {
|
||||
return;
|
||||
}
|
||||
ob_start();
|
||||
if ( empty( $attributes['profileImgURL'] ) ) {
|
||||
$attributes['profileImgURL'] = wp_get_attachment_image_url( $attributes['profileImgID'], 'thumbnail', false, '' );
|
||||
}
|
||||
?>
|
||||
<?php if ( 'regular' === $attributes['theme'] || 'compact' === $attributes['theme'] || 'profile' === $attributes['theme'] ) : ?>
|
||||
<div class="mpp-enhanced-profile-wrap mpp-block-profile <?php echo 'compact' === $attributes['theme'] ? esc_attr( $attributes['profileCompactAlignment'] ) : ''; ?> <?php echo esc_attr( $attributes['theme'] ); ?> <?php echo esc_attr( $attributes['profileAvatarShape'] ); ?>" style="<?php echo $attributes['padding'] > 0 ? 'padding: ' . esc_attr( $attributes['padding'] ) . 'px;' : ''; ?><?php echo $attributes['border'] > 0 ? 'border:' . esc_attr( $attributes['border'] ) . 'px solid ' . esc_attr( $attributes['borderColor'] ) . ';' : ''; ?><?php echo $attributes['borderRounded'] > 0 ? 'border-radius:' . esc_attr( $attributes['borderRounded'] ) . 'px;' : ''; ?>background-color: <?php echo esc_attr( $attributes['profileBackgroundColor'] ) . ';'; ?> color: <?php echo esc_attr( $attributes['profileTextColor'] ) . ';'; ?>">
|
||||
<div class="mpp-profile-gutenberg-wrap mt-font-size-<?php echo esc_attr( $attributes['profileFontSize'] ); ?>">
|
||||
<?php if ( 'regular' === $attributes['theme'] ) : ?>
|
||||
<div class="mpp-profile-image-wrapper">
|
||||
<div class="mpp-profile-image-square">
|
||||
<img class="profile-avatar" alt="avatar" src="<?php echo esc_url( $attributes['profileImgURL'] ); ?>" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="mpp-content-wrap">
|
||||
<?php if ( $attributes['showName'] ) : ?>
|
||||
<h2 style="color:<?php echo esc_attr( $attributes['profileTextColor'] ); ?>; font-size: <?php echo esc_attr( $attributes['headerFontSize'] ) . 'px;'; ?>"><?php echo wp_kses_post( $attributes['profileName'] ); ?></h2>
|
||||
<?php endif; ?>
|
||||
<?php if ( $attributes['showTitle'] ) : ?>
|
||||
<p style="color:<?php echo esc_attr( $attributes['profileTextColor'] ); ?>"><?php echo wp_kses_post( $attributes['profileTitle'] ); ?></p>
|
||||
<?php endif; ?>
|
||||
<?php if ( $attributes['showDescription'] ) : ?>
|
||||
<div><?php echo wp_kses_post( $attributes['profileContent'] ); ?></div>
|
||||
<?php endif; ?>
|
||||
<?php if ( isset( $attributes['profileURL'] ) && strlen( $attributes['profileURL'] ) > 0 ) : ?>
|
||||
<div class="mpp-gutenberg-view-posts">
|
||||
<?php if ( $attributes['showViewPosts'] ) : ?>
|
||||
<div class="mpp-profile-view-posts" style="background-color: <?php echo esc_attr( $attributes['profileViewPostsBackgroundColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileViewPostsTextColor'] ); ?>; width: <?php echo esc_attr( $attributes['showPostsWidth'] ); ?>; font-size: <?php echo esc_attr( $attributes['buttonFontSize'] ); ?>px;">
|
||||
<a href="<?php echo esc_url( $attributes['profileURL'] ); ?>" style="background: <?php echo esc_attr( $attributes['profileViewPostsBackgroundColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileViewPostsTextColor'] ); ?>">
|
||||
<?php
|
||||
if ( isset( $attributes['profileViewPosts'] ) ) {
|
||||
echo esc_html( $attributes['profileViewPosts'] );
|
||||
} else {
|
||||
esc_html_e( 'View Posts', 'metronet-profile-picture' );
|
||||
}
|
||||
?>
|
||||
</a>
|
||||
</div><!-- .mpp-profile-view-posts -->
|
||||
<?php endif; ?>
|
||||
<?php if ( '' !== $attributes['website'] && $attributes['showWebsite'] ) : ?>
|
||||
<div class="mpp-profile-view-website" style="background: <?php echo esc_attr( $attributes['profileWebsiteBackgroundColor'] ); ?>;color: <?php echo esc_attr( $attributes['profileWebsiteTextColor'] ); ?>; font-size: <?php echo esc_attr( $attributes['buttonFontSize'] ); ?>px;">
|
||||
<a href="<?php echo esc_url( $attributes['website'] ); ?>" style="background: <?php echo esc_attr( $attributes['profileWebsiteBackgroundColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileWebsiteTextColor'] ); ?>;">
|
||||
<?php
|
||||
if ( isset( $attributes['profileViewWebsite'] ) ) {
|
||||
echo esc_html( $attributes['profileViewWebsite'] );
|
||||
} else {
|
||||
esc_html_e( 'View Website', 'metronet-profile-picture' );
|
||||
}
|
||||
?>
|
||||
</a>
|
||||
</div><!-- .mpp-profile-view-website -->
|
||||
<?php endif; ?>
|
||||
</div><!-- .mpp-gutenberg-view-posts -->
|
||||
<?php endif; ?>
|
||||
</div><!-- .mpp-content-wrap -->
|
||||
<?php endif; /* End Regular Theme */ ?>
|
||||
<?php if ( 'profile' === $attributes['theme'] ) : ?>
|
||||
<?php if ( $attributes['showName'] ) : ?>
|
||||
<h2 style="color: <?php echo esc_attr( $attributes['profileTextColor'] ); ?>; font-size: <?php echo esc_attr( $attributes['headerFontSize'] ) . 'px'; ?>"><?php echo wp_kses_post( $attributes['profileName'] ); ?></h2>
|
||||
<?php endif; ?>
|
||||
<div class="mpp-profile-image-wrapper">
|
||||
<div class="mpp-profile-image-square">
|
||||
<img src="<?php echo esc_url( $attributes['profileImgURL'] ); ?>" alt="avatar" class="profile-avatar" />
|
||||
</div>
|
||||
</div><!-- .mpp-profile-image-wrapper -->
|
||||
<?php if ( $attributes['showDescription'] ) : ?>
|
||||
<div class="mpp-profile-text">
|
||||
<?php echo wp_kses_post( $attributes['profileContent'] ); ?>
|
||||
</div><!-- .mpp-profile-text -->
|
||||
<?php endif; ?>
|
||||
<?php
|
||||
$font_size = isset( $attributes['fontSize'] ) ? $attributes['fontSize'] : false;
|
||||
$font_size_style = '';
|
||||
if ( $font_size ) {
|
||||
$font_size_style = 'font-size: ' . $font_size . 'px';
|
||||
}
|
||||
?>
|
||||
<div class="mpp-profile-meta" style="<?php echo esc_attr( $font_size_style ); ?>">
|
||||
<?php if ( $attributes['showViewPosts'] ) : ?>
|
||||
<div class="mpp-profile-link alignleft">
|
||||
<a href="<?php echo esc_url( $attributes['profileURL'] ); ?>" style="color: <?php echo esc_attr( $attributes['profileLinkColor'] ); ?>;"><?php esc_html_e( 'View all posts by', 'metronet-profile-picture' ); ?> <?php echo esc_html( $attributes['profileName'] ); ?></a>
|
||||
</div><!-- .mpp-profile-link -->
|
||||
<div class="mpp-profile-link alignright">
|
||||
<a href="<?php echo esc_url( $attributes['website'] ); ?>" style="color: <?php echo esc_attr( $attributes['profileLinkColor'] ); ?>">
|
||||
<?php esc_html_e( 'Website', 'metronet-profile-picture' ); ?>
|
||||
</a>
|
||||
</div><!-- .mpp-profile-link -->
|
||||
<?php endif; ?>
|
||||
</div><!-- .mpp-profile-meta -->
|
||||
<?php endif; /* End of profile theme */ ?>
|
||||
<?php if ( 'compact' === $attributes['theme'] ) : ?>
|
||||
<?php if ( $attributes['showName'] ) : ?>
|
||||
<h2 style="color: <?php echo esc_attr( $attributes['profileTextColor'] ); ?>; font-size: <?php echo esc_attr( $attributes['headerFontSize'] ) . 'px'; ?>"><?php echo wp_kses_post( $attributes['profileName'] ); ?></h2>
|
||||
<?php endif; ?>
|
||||
<div class="mpp-profile-image-wrapper">
|
||||
<div class="mpp-profile-image-square">
|
||||
<img src="<?php echo esc_url( $attributes['profileImgURL'] ); ?>" alt="avatar" class="profile-avatar" />
|
||||
</div>
|
||||
</div><!-- .mpp-profile-image-wrapper -->
|
||||
<?php if ( $attributes['showDescription'] ) : ?>
|
||||
<div class="mpp-profile-text">
|
||||
<?php echo wp_kses_post( $attributes['profileContent'] ); ?>
|
||||
</div><!-- .mpp-profile-text -->
|
||||
<?php endif; ?>
|
||||
<div class="mpp-compact-meta">
|
||||
<?php if ( $attributes['showViewPosts'] ) : ?>
|
||||
<div class="mpp-profile-view-posts" style="background: <?php echo esc_attr( $attributes['profileViewPostsBackgroundColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileViewPostsTextColor'] ); ?>; width: 90%; margin: 0 auto 10px auto; font-size: <?php echo esc_attr( $attributes['buttonFontSize'] ); ?>px;">
|
||||
<a href="<?php echo esc_url( $attributes['profileURL'] ); ?>" style="color: <?php echo esc_attr( $attributes['profileViewPostsTextColor'] ); ?>; background: <?php echo esc_attr( $attributes['profileViewPostsBackgroundColor'] ); ?>;"><?php esc_html_e( 'View Posts', 'metronet-profile-picture' ); ?></a>
|
||||
</div><!-- .mpp-profile-view-posts -->
|
||||
<?php endif; ?>
|
||||
<?php if ( '' !== $attributes['website'] && $attributes['showWebsite'] ) : ?>
|
||||
<div class="mpp-profile-view-website" style="background: <?php echo esc_attr( $attributes['profileWebsiteBackgroundColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileWebsiteTextColor'] ); ?>; width: 90%; margin: 0 auto 0 auto; font-size: <?php echo esc_attr( $attributes['buttonFontSize'] ); ?>px;">
|
||||
<a href="<?php echo esc_url( $attributes['website'] ); ?>" style="color: <?php echo esc_attr( $attributes['profileWebsiteTextColor'] ); ?>; background: <?php echo esc_attr( $attributes['profileWebsiteBackgroundColor'] ); ?>;"><?php esc_html_e( 'View Website', 'metronet-profile-picture' ); ?></a>
|
||||
</div><!-- .mpp-profile-view-posts -->
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
||||
<?php endif; /* Compact theme end */ ?>
|
||||
<?php if ( true === $attributes['showSocialMedia'] && ( 'regular' === $attributes['theme'] || 'compact' === $attributes['theme'] || 'profile' === $attributes['theme'] ) ) : ?>
|
||||
<?php echo $this->get_social_icons( $attributes ); // phpcs:ignore ?>
|
||||
<?php endif; ?>
|
||||
</div><!-- .mpp-profile-gutenberg-wrap -->
|
||||
</div><!-- .mpp-profile-wrap -->
|
||||
<?php endif; ?>
|
||||
<?php if ( 'tabbed' === $attributes['theme'] ) : ?>
|
||||
<style>
|
||||
.mpp-author-tabbed ul.mpp-author-tabs li.active:after {
|
||||
border-top: 10px solid <?php echo esc_attr( $attributes['profileTabColor'] ); ?>;
|
||||
border-top-color: <?php echo esc_attr( $attributes['profileTabColor'] ); ?>;
|
||||
}
|
||||
.mpp-author-tabbed ul.mpp-author-tabs li.mpp-tab-posts.active:after {
|
||||
border-top: 10px solid <?php echo esc_attr( $attributes['profileTabPostsColor'] ); ?>;
|
||||
border-top-color: <?php echo esc_attr( $attributes['profileTabPostsColor'] ); ?>;
|
||||
}
|
||||
</style>
|
||||
<div class="mpp-author-tabbed tabbed <?php echo esc_attr( $attributes['profileAvatarShape'] ); ?> mpp-block-profile">
|
||||
<ul class="mpp-author-tabs">
|
||||
<li class="mpp-tab-profile active mpp-gutenberg-tab" data-tab="mpp-profile-tab" style="background: <?php echo esc_attr( $attributes['profileTabColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileTabTextColor'] ); ?>;">
|
||||
<?php echo wp_kses_post( $attributes['tabbedAuthorProfile'] ); ?>
|
||||
</li>
|
||||
<li class="mpp-tab-posts mpp-gutenberg-tab" data-tab="mpp-latestposts-tab" style="background: <?php echo esc_attr( $attributes['profileTabPostsColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileTabPostsTextColor'] ); ?>;">
|
||||
<?php echo wp_kses_post( $attributes['tabbedAuthorLatestPosts'] ); ?>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="mpp-tab-wrapper" style="<?php echo $attributes['padding'] > 0 ? 'padding: ' . esc_attr( $attributes['padding'] ) . 'px;' : ''; ?><?php echo $attributes['border'] > 0 ? 'border:' . esc_attr( $attributes['border'] ) . 'px solid ' . esc_attr( $attributes['borderColor'] ) . ';' : ''; ?><?php echo $attributes['borderRounded'] > 0 ? 'border-radius:' . esc_attr( $attributes['borderRounded'] ) . 'px;' : ''; ?>background-color: <?php echo esc_attr( $attributes['profileBackgroundColor'] ) . ';'; ?> color: <?php echo esc_attr( $attributes['profileTextColor'] ) . ';'; ?>">
|
||||
<div class="mpp-tab-active mpp-profile-tab mpp-tab">
|
||||
<div class="mpp-author-social-wrapper">
|
||||
<div class="mpp-author-heading">
|
||||
<div class="mpp-author-profile-heading" style="background: <?php echo esc_attr( $attributes['profileTabHeadlineColor'] ); ?>; color: <?php echo esc_attr( $attributes['profileTabHeadlineTextColor'] ); ?>;">
|
||||
<?php echo wp_kses_post( $attributes['tabbedAuthorProfileHeading'] ); ?>
|
||||
</div><!-- .mpp-author-heading -->
|
||||
</div><!-- .mpp-author-social-wrapper -->
|
||||
<?php if ( $attributes['showSocialMedia'] ) : ?>
|
||||
<div class="mpp-author-social">
|
||||
<?php echo $this->get_social_icons( $attributes ); // phpcs:ignore ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div><!-- .mpp-author-social-wrapper -->
|
||||
<div class="mpp-profile-image-wrapper">
|
||||
<div class="mpp-profile-image-square">
|
||||
<img class="profile-avatar" alt="avatar" src="<?php echo esc_url( $attributes['profileImgURL'] ); ?>">
|
||||
<div class="mpp-author-profile-sub-heading">
|
||||
<?php echo wp_kses_post( $attributes['tabbedAuthorSubHeading'] ); ?>
|
||||
</div>
|
||||
</div><!-- .mpp-profile-image-square -->
|
||||
</div><!-- .mpp-profile-image-wrapper -->
|
||||
<div class="mpp-tabbed-profile-information">
|
||||
<?php if ( $attributes['showTitle'] || '' !== $attributes['tabbedAuthorProfileTitle'] ) : ?>
|
||||
<?php echo '<div>' . wp_kses_post( $attributes['tabbedAuthorProfileTitle'] ) . '</div>'; ?>
|
||||
<?php endif; ?>
|
||||
<?php if ( $attributes['showName'] ) : ?>
|
||||
<h2 style="color: <?php echo esc_attr( $attributes['profileTextColor'] ); ?>; font-size: <?php echo esc_attr( $attributes['headerFontSize'] ) . 'px;'; ?>"><?php echo wp_kses_post( $attributes['profileName'] ); ?></h2>
|
||||
<?php endif; ?>
|
||||
<?php if ( $attributes['showDescription'] ) : ?>
|
||||
<div class="mpp-profile-text mt-font-size-<?php echo esc_attr( $attributes['profileFontSize'] ); ?>">
|
||||
<?php echo wp_kses_post( $attributes['profileContent'] ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div><!-- .mpp-tabbed-profile-information -->
|
||||
</div><!-- first profile tab -->
|
||||
<div class="mpp-tabbed-latest-posts mpp-latestposts-tab mpp-tab">
|
||||
<?php
|
||||
$user_id = $attributes['user_id'];
|
||||
$args = array(
|
||||
'post_type' => 'post',
|
||||
'post_status' => 'publish',
|
||||
'author' => $user_id,
|
||||
'orderby' => 'date',
|
||||
'order' => 'DESC',
|
||||
'posts_per_page' => 5,
|
||||
);
|
||||
$posts = get_posts( $args );
|
||||
?>
|
||||
<ul class="mpp-author-tab-content <?php echo esc_attr( $attributes['profileLatestPostsOptionsValue'] ); ?>">
|
||||
<?php
|
||||
foreach ( $posts as $post ) {
|
||||
printf( "<li><a href='%s'>%s</a></li>", esc_url( get_permalink( $post->ID ) ), esc_html( $post->post_title ) );
|
||||
}
|
||||
?>
|
||||
</ul>
|
||||
</div><!-- .mpp-tabbed-latest-posts -->
|
||||
</div><!-- mpp-tab-wrapper -->
|
||||
</div><!-- .mpp-author-tabbed -->
|
||||
|
||||
<?php endif; ?>
|
||||
<?php
|
||||
$this->load_gutenblock_svgs();
|
||||
return ob_get_clean();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the social icons for the block.
|
||||
*
|
||||
* @param array $attributes Gutenberg attributes.
|
||||
*/
|
||||
public function get_social_icons( $attributes ) {
|
||||
ob_start();
|
||||
?>
|
||||
<div class="mpp-social">
|
||||
<?php if ( ! empty( $attributes['socialFacebook'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialFacebook'] ); ?>">
|
||||
<svg class="icon icon-facebook" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#facebook"></use>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $attributes['socialTwitter'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialTwitter'] ); ?>">
|
||||
<svg class="icon icon-twitter" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#twitter"></use>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $attributes['socialInstagram'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialInstagram'] ); ?>">
|
||||
<svg class="icon icon-instagram" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#instagram"></use>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $attributes['socialPinterest'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialPinterest'] ); ?>">
|
||||
<svg class="icon icon-pinterest" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#pinterest"></use>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $attributes['socialLinkedIn'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialLinkedIn'] ); ?>">
|
||||
<svg class="icon icon-linkedin" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#linkedin"></use>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $attributes['socialYouTube'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialYouTube'] ); ?>">
|
||||
<svg class="icon icon-youtube" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#youtube"></use>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $attributes['socialGitHub'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialGitHub'] ); ?>">
|
||||
<svg class="icon icon-github" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#github"></use>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $attributes['socialWordPress'] ) ) : ?>
|
||||
<a href="<?php echo esc_url( $attributes['socialWordPress'] ); ?>">
|
||||
<svg class="icon icon-wordpress" role="img" style="<?php echo 'custom' === $attributes['socialMediaOptions'] ? 'fill:' . esc_attr( $attributes['socialMediaColors'] ) . ';' : ''; ?>">
|
||||
<use href="#wordpress"></use><?php // phpcs:ignore ?>
|
||||
</svg>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</div><!-- .mpp-social -->
|
||||
<?php
|
||||
return ob_get_clean();
|
||||
}
|
||||
|
||||
/**
|
||||
* Add SVGs for the social icons in the block.
|
||||
*/
|
||||
public function load_gutenblock_svgs() {
|
||||
if ( '' !== get_post_type() ) {
|
||||
// Define SVG sprite file.
|
||||
$path = '/img/social-logos.svg';
|
||||
$svg_icons = rtrim( dirname( plugin_dir_path( __FILE__ ) ), '/' );
|
||||
if ( ! empty( $path ) && is_string( $path ) ) {
|
||||
$svg_icons .= '/' . ltrim( $path, '/' );
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter Social Icons Sprite.
|
||||
*
|
||||
* @since 2.1.0
|
||||
*
|
||||
* @param string Absolute directory path to SVG sprite
|
||||
*/
|
||||
$svg_icons = apply_filters( 'mpp_icons_sprite', $svg_icons );
|
||||
// If it exists, include it.
|
||||
if ( file_exists( $svg_icons ) ) {
|
||||
echo '<div style="position: absolute; height: 0; width: 0; overflow: hidden;">';
|
||||
require $svg_icons;
|
||||
echo '</div>';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Add Gutenberg scripts.
|
||||
*/
|
||||
public function add_gutenberg_scripts() {
|
||||
|
||||
wp_enqueue_script( 'mpp_gutenberg', Metronet_Profile_Picture::get_plugin_url( 'dist/blocks.build.js' ), array( 'wp-blocks', 'wp-element' ), METRONET_PROFILE_PICTURE_VERSION, true );
|
||||
|
||||
/* For the Gutenberg plugin */
|
||||
if ( function_exists( 'wp_set_script_translations' ) ) {
|
||||
wp_set_script_translations( 'mpp_gutenberg', 'metronet-profile-picture' );
|
||||
} elseif ( function_exists( 'gutenberg_get_jed_locale_data' ) ) {
|
||||
$locale = gutenberg_get_jed_locale_data( 'metronet-profile-picture' );
|
||||
$content = 'wp.i18n.setLocaleData( ' . wp_json_encode( $locale ) . ', "post-type-archive-mapping" );';
|
||||
wp_script_add_data( 'mpp_gutenberg', 'data', $content );
|
||||
} elseif ( function_exists( 'wp_get_jed_locale_data' ) ) {
|
||||
/* for 5.0 */
|
||||
$locale = wp_get_jed_locale_data( 'metronet-profile-picture' );
|
||||
$content = 'wp.i18n.setLocaleData( ' . $locale . ', "metronet-profile-picture" );';
|
||||
wp_script_add_data( 'mpp_gutenberg', 'data', $content );
|
||||
}
|
||||
|
||||
// Pass in REST URL.
|
||||
wp_localize_script(
|
||||
'mpp_gutenberg',
|
||||
'mpp_gutenberg',
|
||||
array(
|
||||
'rest_url' => esc_url( rest_url( 'mpp/v2' ) ),
|
||||
'nonce' => wp_create_nonce( 'wp_rest' ),
|
||||
'mystery_man' => Metronet_Profile_Picture::get_plugin_url( 'img/mystery.png' ),
|
||||
)
|
||||
);
|
||||
|
||||
wp_enqueue_style( 'mpp_gutenberg', Metronet_Profile_Picture::get_plugin_url( '/dist/blocks.editor.build.css' ), array(), METRONET_PROFILE_PICTURE_VERSION, 'all' );
|
||||
}
|
||||
|
||||
/**
|
||||
* Add Gutenberg styles.
|
||||
*/
|
||||
public function add_gutenberg_styles() {
|
||||
if ( is_admin() ) {
|
||||
return;
|
||||
}
|
||||
// Ensure script debug allows non-minified scripts.
|
||||
wp_enqueue_style( 'mpp_gutenberg', Metronet_Profile_Picture::get_plugin_url( '/dist/blocks.style.build.css' ), array(), METRONET_PROFILE_PICTURE_VERSION, 'all' );
|
||||
wp_enqueue_script( 'mpp_gutenberg_tabs', Metronet_Profile_Picture::get_plugin_url( 'js/mpp-frontend.js' ), array( 'jquery' ), METRONET_PROFILE_PICTURE_VERSION, true );
|
||||
|
||||
}
|
||||
}
|
@ -0,0 +1,2 @@
|
||||
<?php // phpcs:ignore
|
||||
// no direct access.
|
BIN
wp-content/plugins/metronet-profile-picture/img/loading.gif
Normal file
BIN
wp-content/plugins/metronet-profile-picture/img/loading.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 16 KiB |
BIN
wp-content/plugins/metronet-profile-picture/img/mystery.png
Normal file
BIN
wp-content/plugins/metronet-profile-picture/img/mystery.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 8.2 KiB |
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 32 KiB |
@ -0,0 +1,9 @@
|
||||
jQuery( document ).ready( function( $ ) {
|
||||
$( '.mpp-gutenberg-tab' ).on( 'click', function( e ) {
|
||||
$('.mpp-author-tabs li').removeClass('active');
|
||||
$(this).addClass('active');
|
||||
var $tabs = $('.mpp-tab').removeClass('mpp-tab-active');
|
||||
var new_tab = $(this).data('tab');
|
||||
$('.' + new_tab).addClass('mpp-tab-active');
|
||||
} );
|
||||
} );
|
157
wp-content/plugins/metronet-profile-picture/js/mpp.js
Normal file
157
wp-content/plugins/metronet-profile-picture/js/mpp.js
Normal file
@ -0,0 +1,157 @@
|
||||
jQuery( document ).ready( function( $ ) {
|
||||
//Refresh the profile image thumbnail
|
||||
function mt_ajax_thumbnail_refresh() {
|
||||
var post_id = jQuery( "#metronet_post_id" ).val();
|
||||
jQuery( '#metronet-profile-image' ).html( '<img class="mpp-loading" alt="Loading" width="150" height="150" src="' + metronet_profile_image.loading_gif + '" />' );
|
||||
$.post( metronet_profile_image.ajax_url, {
|
||||
action: 'metronet_get_thumbnail',
|
||||
post_id: post_id,
|
||||
_wpnonce: metronet_profile_image.nonce,
|
||||
user_id: jQuery( "#metronet_profile_id" ).val(),
|
||||
},
|
||||
function( response ) {
|
||||
jQuery( "#metronet-profile-image" ).html( mt_display_block( response.thumb_html ) );
|
||||
jQuery( '.user-profile-picture img ').replaceWith( response.avatar );
|
||||
if ( response.user_id === response.logged_in_user_id ) {
|
||||
jQuery( '#wp-admin-bar-my-account img.avatar-26' ).replaceWith( response.avatar_admin_small );
|
||||
jQuery( '#wp-admin-bar-my-account img.avatar-64' ).replaceWith( response.avatar_admin_medium );
|
||||
}
|
||||
},
|
||||
'json'
|
||||
);
|
||||
};
|
||||
//Remove the profile image
|
||||
function mt_remove_profile_image() {
|
||||
jQuery( '#metronet-profile-image' ).html( '<img class="mpp-loading" alt="Loading" width="150" height="150" src="' + metronet_profile_image.loading_gif + '" />' );
|
||||
$.post( metronet_profile_image.ajax_url, {
|
||||
action: 'metronet_remove_thumbnail',
|
||||
post_id: metronet_profile_image.user_post_id,
|
||||
user_id: jQuery( "#metronet_profile_id" ).val(),
|
||||
_wpnonce: metronet_profile_image.nonce
|
||||
},
|
||||
function( response ) {
|
||||
jQuery( "#metronet-profile-image" ).html( mt_display_block( response.thumb_html ) );
|
||||
jQuery( '.user-profile-picture img ').replaceWith( response.avatar );
|
||||
if ( response.user_id === response.logged_in_user_id ) {
|
||||
jQuery( '#wp-admin-bar-my-account img.avatar-26' ).replaceWith( response.avatar_admin_small );
|
||||
jQuery( '#wp-admin-bar-my-account img.avatar-64' ).replaceWith( response.avatar_admin_medium );
|
||||
}
|
||||
},
|
||||
'json'
|
||||
);
|
||||
}
|
||||
// Set thumbnail img and wrapping a to display:block to fix visual bug
|
||||
function mt_display_block(htmlString) {
|
||||
var temp = document.createElement('div');
|
||||
temp.innerHTML = htmlString;
|
||||
temp.firstElementChild.style.display = 'block';
|
||||
temp.firstElementChild.firstElementChild.style.display = 'block';
|
||||
return temp.innerHTML;
|
||||
}
|
||||
|
||||
$('#mpp').on( "click", '.mpp_add_media', function(e) {
|
||||
|
||||
//Assign the default view for the media uploader
|
||||
|
||||
var uploader = wp.media({
|
||||
state: 'featured-image',
|
||||
states: [ new wp.media.controller.FeaturedImage() ],
|
||||
title: metronet_profile_image.set_profile_text,
|
||||
button: {
|
||||
text: metronet_profile_image.remove_profile_text
|
||||
},
|
||||
multiple: false,
|
||||
});
|
||||
|
||||
// CUSTOM TOOLBAR ON BOTTOM OF MEDIA MANAGER. SETS UP THE TWO ACTION BUTTONS
|
||||
|
||||
uploader.on( 'toolbar:create', function( toolbar ) {
|
||||
var options = {};
|
||||
options.items = {};
|
||||
options.items.select = {
|
||||
text: metronet_profile_image.set_profile_text,
|
||||
style: 'primary',
|
||||
click: wp.media.view.Toolbar.Select.prototype.clickSelect,
|
||||
requires: { selection: true },
|
||||
event: 'select',
|
||||
reset: false,
|
||||
close: true,
|
||||
state: false,
|
||||
syncSelection: true
|
||||
};
|
||||
if ( ! $( '#metronet-profile-image a' ).hasClass('default-image') ) {
|
||||
options.items.remove = {
|
||||
text: metronet_profile_image.remove_profile_text,
|
||||
style: 'secondary',
|
||||
requires: { selection: false },
|
||||
click: wp.media.view.Toolbar.Select.prototype.clickSelect,
|
||||
event: 'remove',
|
||||
reset: true,
|
||||
close: true,
|
||||
state: false,
|
||||
syncSelection: true
|
||||
};
|
||||
}
|
||||
this.createSelectToolbar( toolbar, options );
|
||||
}, uploader );
|
||||
|
||||
|
||||
//For when the featured thumbnail is set
|
||||
uploader.mt_featured_set = function( id ) {
|
||||
jQuery( '#metronet-profile-image' ).html( '<img class="mpp-loading" alt="Loading" width="150" height="150" src="' + metronet_profile_image.loading_gif + '" />' );
|
||||
$.post( metronet_profile_image.ajax_url, {
|
||||
action: 'metronet_add_thumbnail',
|
||||
post_id: metronet_profile_image.user_post_id,
|
||||
user_id: jQuery( "#metronet_profile_id" ).val(),
|
||||
thumbnail_id: id,
|
||||
_wpnonce: metronet_profile_image.nonce
|
||||
},
|
||||
function( response ) {
|
||||
jQuery( "#metronet-profile-image" ).html( mt_display_block( response.thumb_html ) );
|
||||
jQuery( '.user-profile-picture img ').replaceWith( response.avatar );
|
||||
if ( response.user_id === response.logged_in_user_id ) {
|
||||
jQuery( '#wp-admin-bar-my-account img.avatar-26' ).replaceWith( response.avatar_admin_small );
|
||||
jQuery( '#wp-admin-bar-my-account img.avatar-64' ).replaceWith( response.avatar_admin_medium );
|
||||
}
|
||||
},
|
||||
'json'
|
||||
);
|
||||
};
|
||||
|
||||
//For when the Add Profile Image is clicked
|
||||
uploader.on( 'select', function() {
|
||||
|
||||
var featured = uploader.state().get('selection').single();
|
||||
wp.media.featuredImage.set( featured ? featured.id : -1 );
|
||||
if ( ! featured.id ) {
|
||||
return;
|
||||
}
|
||||
|
||||
uploader.mt_featured_set( featured.id );
|
||||
|
||||
|
||||
} );
|
||||
|
||||
//When the remove buttons is clicked
|
||||
uploader.on( 'remove', function() {
|
||||
wp.media.featuredImage.set( -1 );
|
||||
mt_remove_profile_image();
|
||||
} );
|
||||
|
||||
|
||||
//For when the window is closed (update the thumbnail)
|
||||
uploader.on('escape', function(){
|
||||
mt_ajax_thumbnail_refresh();
|
||||
});
|
||||
|
||||
//Open the media uploader
|
||||
uploader.open();
|
||||
return false;
|
||||
});
|
||||
$( "#mpp" ).on( 'click', 'a#metronet-remove', function( e ) {
|
||||
e.preventDefault();
|
||||
wp.media.featuredImage.set( -1 );
|
||||
mt_remove_profile_image();
|
||||
} );
|
||||
|
||||
} );
|
Binary file not shown.
@ -0,0 +1,51 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Metronet Profile Picture\n"
|
||||
"Report-Msgid-Bugs-To: http://wordpress.org/tag/simple-comment-editing\n"
|
||||
"POT-Creation-Date: 2015-03-09 22:01-0600\n"
|
||||
"PO-Revision-Date: 2015-03-09 22:01-0600\n"
|
||||
"Last-Translator: Ronald Huereca <ron@ronalfy.com>\n"
|
||||
"Language-Team: \n"
|
||||
"Language: en\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.5.3\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
"X-Poedit-KeywordsList: _e;__;esc_html__;esc_html_e;esc_attr__;esc_attr_e\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"X-Poedit-SearchPath-0: ..\n"
|
||||
|
||||
#: ../metronet-profile-picture.php:85 ../metronet-profile-picture.php:108
|
||||
#: ../metronet-profile-picture.php:359 ../metronet-profile-picture.php:407
|
||||
msgid "Remove profile image"
|
||||
msgstr "Eliminar la Foto de Perfil"
|
||||
|
||||
#: ../metronet-profile-picture.php:116 ../metronet-profile-picture.php:135
|
||||
#: ../metronet-profile-picture.php:350
|
||||
msgid "Upload or Change Profile Picture"
|
||||
msgstr "Seleccionar una Foto de Perfil"
|
||||
|
||||
#: ../metronet-profile-picture.php:271 ../metronet-profile-picture.php:408
|
||||
msgid "Crop Thumbnail"
|
||||
msgstr "Recortar la imagen"
|
||||
|
||||
#: ../metronet-profile-picture.php:335
|
||||
msgid "Profile Image"
|
||||
msgstr "Foto de Perfil"
|
||||
|
||||
#: ../metronet-profile-picture.php:381
|
||||
msgid "Override Avatar?"
|
||||
msgstr ""
|
||||
"¿Anteponer esta foto al Avatar? (Marca esta casilla si no tienes Gravatar "
|
||||
"para que tu foto sea visible)"
|
||||
|
||||
#: ../metronet-profile-picture.php:406
|
||||
msgid "Set profile image"
|
||||
msgstr "Establecer la Foto de Perfil"
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Select \"Set profile image\" after uploading to choose the profile image"
|
||||
#~ msgstr ""
|
||||
#~ "Selecciona \"Seleccionar una Foto de Perfil\" tras subir la imagen "
|
||||
#~ "elegida a la librería"
|
Binary file not shown.
@ -0,0 +1,44 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Metronet Profile Picture\n"
|
||||
"Report-Msgid-Bugs-To: http://wordpress.org/tag/simple-comment-editing\n"
|
||||
"POT-Creation-Date: 2015-03-09 23:35-0600\n"
|
||||
"PO-Revision-Date: 2016-03-31 14:35+0200\n"
|
||||
"Last-Translator: Marek eM <monter@techlog.pl>\n"
|
||||
"Language-Team: \n"
|
||||
"Language: pl_PL\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 1.8.7\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
"X-Poedit-KeywordsList: _e;__;esc_html__;esc_html_e;esc_attr__;esc_attr_e\n"
|
||||
"X-Poedit-Basepath: .\n"
|
||||
"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
|
||||
"X-Poedit-SearchPath-0: ..\n"
|
||||
|
||||
#: ../metronet-profile-picture.php:85 ../metronet-profile-picture.php:108
|
||||
#: ../metronet-profile-picture.php:359 ../metronet-profile-picture.php:407
|
||||
msgid "Remove profile image"
|
||||
msgstr "Usuń zdjęcie profilowe"
|
||||
|
||||
#: ../metronet-profile-picture.php:116 ../metronet-profile-picture.php:135
|
||||
#: ../metronet-profile-picture.php:350
|
||||
msgid "Upload or Change Profile Picture"
|
||||
msgstr "Dodaj nowe lub zmień swoje zdjęcie profilowe"
|
||||
|
||||
#: ../metronet-profile-picture.php:271 ../metronet-profile-picture.php:408
|
||||
msgid "Crop Thumbnail"
|
||||
msgstr "Przytnij miniaturę"
|
||||
|
||||
#: ../metronet-profile-picture.php:335
|
||||
msgid "Profile Image"
|
||||
msgstr "Zdjęcie profilowe"
|
||||
|
||||
#: ../metronet-profile-picture.php:381
|
||||
msgid "Override Avatar?"
|
||||
msgstr "Zastąpić Avatar?"
|
||||
|
||||
#: ../metronet-profile-picture.php:406
|
||||
msgid "Set profile image"
|
||||
msgstr "Ustaw zdjęcie profilowe"
|
@ -0,0 +1,450 @@
|
||||
# Copyright (C) 2019 Ronald Huereca
|
||||
# This file is distributed under the same license as the User Profile Picture plugin.
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: User Profile Picture 2.2.6\n"
|
||||
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/user-profile-picture\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"POT-Creation-Date: 2019-06-10T16:20:09+00:00\n"
|
||||
"PO-Revision-Date: 2019-06-10T16:20:09+00:00\n"
|
||||
"X-Generator: WP-CLI 2.0.1\n"
|
||||
"X-Domain: metronet-profile-picture\n"
|
||||
|
||||
#. Plugin Name of the plugin
|
||||
msgid "User Profile Picture"
|
||||
msgstr ""
|
||||
|
||||
#. Plugin URI of the plugin
|
||||
msgid "http://wordpress.org/extend/plugins/metronet-profile-picture/"
|
||||
msgstr ""
|
||||
|
||||
#. Description of the plugin
|
||||
msgid "Use the native WP uploader on your user profile page."
|
||||
msgstr ""
|
||||
|
||||
#. Author of the plugin
|
||||
msgid "Ronald Huereca"
|
||||
msgstr ""
|
||||
|
||||
#. Author URI of the plugin
|
||||
msgid "https://www.mediaron.com"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:116
|
||||
#: metronet-profile-picture.php:167
|
||||
#: metronet-profile-picture.php:185
|
||||
#: metronet-profile-picture.php:221
|
||||
#: metronet-profile-picture.php:554
|
||||
#: metronet-profile-picture.php:560
|
||||
msgid "Upload or Change Profile Picture"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:118
|
||||
#: metronet-profile-picture.php:169
|
||||
#: metronet-profile-picture.php:186
|
||||
#: metronet-profile-picture.php:222
|
||||
#: metronet-profile-picture.php:556
|
||||
#: metronet-profile-picture.php:562
|
||||
msgid "Click to Edit"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:119
|
||||
#: metronet-profile-picture.php:170
|
||||
#: metronet-profile-picture.php:570
|
||||
msgid "Remove profile image"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:463
|
||||
#: metronet-profile-picture.php:630
|
||||
msgid "Crop Thumbnail"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:543
|
||||
msgid "Profile Image"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:595
|
||||
msgid "Override Avatar?"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:628
|
||||
msgid "Set Profile Image"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:629
|
||||
msgid "Remove Profile Image"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:847
|
||||
msgid "You must be able to upload files."
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:851
|
||||
#: metronet-profile-picture.php:889
|
||||
#: metronet-profile-picture.php:916
|
||||
#: metronet-profile-picture.php:954
|
||||
msgid "User not found."
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:854
|
||||
msgid "You must have a role of editor or above to set a new profile image."
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:858
|
||||
msgid "User not owner."
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:925
|
||||
#: metronet-profile-picture.php:961
|
||||
msgid "Profile picture not found."
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:1154
|
||||
msgid "Author"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:1155
|
||||
#: gutenberg/class-gutenberg.php:212
|
||||
msgid "Latest Posts"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:1156
|
||||
msgid "Author Information"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:1193
|
||||
#: metronet-profile-picture.php:1249
|
||||
#: gutenberg/class-gutenberg.php:307
|
||||
#: gutenberg/class-gutenberg.php:363
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View Posts"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:1198
|
||||
#: metronet-profile-picture.php:1254
|
||||
#: gutenberg/class-gutenberg.php:312
|
||||
#: gutenberg/class-gutenberg.php:368
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View Website"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:1222
|
||||
#: gutenberg/class-gutenberg.php:336
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View all posts by"
|
||||
msgstr ""
|
||||
|
||||
#: metronet-profile-picture.php:1226
|
||||
#: gutenberg/class-gutenberg.php:340
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Website"
|
||||
msgstr ""
|
||||
|
||||
#: gutenberg/class-gutenberg.php:204
|
||||
#: gutenberg/class-gutenberg.php:208
|
||||
msgid "Author Details"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "User Profile Legacy"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "User Profile"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Regular"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Profile"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Tabbed"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Compact"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Square"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Round"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Brand Colors"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Custom"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "None"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "White"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Light"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Black"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Magenta"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Blue"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Green"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Left"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Center"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Right"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "User Profile Settings"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Select a user"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Select a theme"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Select an alignment"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Avatar Shape"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Choose between a round or square avatar shape."
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Show Name"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Show Title"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Show Description"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Show View Posts"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Show Website"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Show Social Media"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Colors"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Background Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Text Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Link Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Profile Tab Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Profile Tab Color Text"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Profile Posts Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Profile Post Color Text"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Profile Headline Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Profile Headline Color Text"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Select a Post Theme"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View Posts Background Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View Posts Background"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View Posts Text Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Website Background Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View Website Background"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "View Website Text Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Spacing and Font Settings"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Header Font Size"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Font Size"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Button Size"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Padding"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Border"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Border Rounded"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Border Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Social Media Settings"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Social Media Colors"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Social Media Color"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Facebook"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Twitter"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Instagram"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "LinkedIn"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "YouTube"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "GitHub"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Pinterest"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "WordPress"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Add name"
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Add profile text..."
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Add tab name."
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Add profile description..."
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Add profile title..."
|
||||
msgstr ""
|
||||
|
||||
#: dist/blocks.build.js:1
|
||||
msgid "Loading..."
|
||||
msgstr ""
|
File diff suppressed because it is too large
Load Diff
370
wp-content/plugins/metronet-profile-picture/readme.txt
Normal file
370
wp-content/plugins/metronet-profile-picture/readme.txt
Normal file
@ -0,0 +1,370 @@
|
||||
=== User Profile Picture ===
|
||||
Contributors: cozmoslabs, ronalfy, Alaadiaa
|
||||
Tags: users, user profile, gravatar, avatar, blocks, block
|
||||
Requires at least: 3.5
|
||||
Tested up to: 5.8
|
||||
Stable tag: 2.6.0
|
||||
Requires PHP: 5.6
|
||||
License: GPLv2 or later
|
||||
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
Donate link: https://cozmoslabs.com/
|
||||
|
||||
Set a custom profile image (avatar) for a user using the standard WordPress media upload tool.
|
||||
== Description ==
|
||||
|
||||
Set or remove a custom profile image for a user using the standard WordPress media upload tool.
|
||||
|
||||
<a href="https://www.cozmoslabs.com/user-profile-picture/">View Documentation and Examples</a>
|
||||
|
||||
https://www.youtube.com/watch?v=9icnOWWZUpA&rel=0
|
||||
|
||||
Users must have the ability to upload images (typically author role or greater). You can use the plugin <a href="https://wordpress.org/plugins/profile-builder/">Profile Builder</a> to allow other roles (e.g. subscribers) the ability to upload images.
|
||||
|
||||
A template tag is supplied for outputting to a theme and the option to override a user's default avatar is also available.
|
||||
|
||||
== Documentation and Feedback ==
|
||||
|
||||
See the documentation on <a href="https://github.com/madalinungureanu/user-profile-picture">GitHub</a>.
|
||||
|
||||
> Please <a href="https://wordpress.org/support/plugin/metronet-profile-picture/reviews/#new-post">Rate the Plugin</a>.
|
||||
|
||||
== Installation ==
|
||||
|
||||
1. Upload `metronet-profile-picture` folder to the `/wp-content/plugins/` directory
|
||||
2. Activate the plugin through the 'Plugins' menu in WordPress
|
||||
3. Place `<?php mt_profile_img() ?>` in your templates (arguments and usage are below)
|
||||
|
||||
Arguments:
|
||||
|
||||
`/**
|
||||
* mt_profile_img
|
||||
*
|
||||
* Adds a profile image
|
||||
*
|
||||
@param $user_id INT - The user ID for the user to retrieve the image for
|
||||
@ param $args mixed
|
||||
size - string || array (see get_the_post_thumbnail)
|
||||
attr - string || array (see get_the_post_thumbnail)
|
||||
echo - bool (true or false) - whether to echo the image or return it
|
||||
*/
|
||||
`
|
||||
|
||||
Example Usage:
|
||||
`
|
||||
<?php
|
||||
//Assuming $post is in scope
|
||||
if (function_exists ( 'mt_profile_img' ) ) {
|
||||
$author_id=$post->post_author;
|
||||
mt_profile_img( $author_id, array(
|
||||
'size' => 'thumbnail',
|
||||
'attr' => array( 'alt' => 'Alternative Text' ),
|
||||
'echo' => true )
|
||||
);
|
||||
}
|
||||
?>
|
||||
`
|
||||
|
||||
Since 2.2.0, you can add a profile author box using function `mt_author_box`.
|
||||
|
||||
`
|
||||
<?php
|
||||
mt_author_box( $post->post_author, array(
|
||||
'theme' => 'tabbed',
|
||||
'profileAvatarShape' => 'round',
|
||||
'showWebsite' => true,
|
||||
'website' => 'https://www.ronalfy.com',
|
||||
'showSocialMedia' => true,
|
||||
'socialMediaOptions' => 'brand',
|
||||
'socialWordPress' => 'https://profiles.wordpress.org/ronalfy',
|
||||
'socialFacebook' => 'https://facebook.com/mindefusement',
|
||||
) );
|
||||
`
|
||||
|
||||
View the code on <a href="https://github.com/madalinungureanu/user-profile-picture">GitHub</a>.
|
||||
|
||||
The REST API is currently supported for versions of WordPress 4.4 and up.
|
||||
|
||||
== Frequently Asked Questions ==
|
||||
|
||||
= How do you set a user profile image? =
|
||||
|
||||
1. Visit the profile page you would like to edit.
|
||||
2. Click on the profile picture to add, edit, or remove the profile picture.
|
||||
|
||||
= What role does a user have to be to set a profile image? =
|
||||
|
||||
Author or greater.
|
||||
|
||||
= How do I create specific thumbnail sizes? =
|
||||
|
||||
As of 1.5, three image sizes are created: profile_24, profile_48, and profile_96. You are not limited to these sizes, however.
|
||||
|
||||
= Does the plugin work with Multisite? =
|
||||
|
||||
Yes, but you'll have to set a new profile image per site. This is currently a limitation of the way the plugin stores its data. Ideas to overcome this are welcome.
|
||||
|
||||
== Screenshots ==
|
||||
|
||||
1. Profile page options.
|
||||
2. Media upload dialog.
|
||||
3. Gutenberg settings back-end
|
||||
4. Gutenberg profile front-end
|
||||
|
||||
== Changelog ==
|
||||
|
||||
= 2.6.0 =
|
||||
* Released 2021-06-25
|
||||
* Fixed a security flaw where a user can change others profile picture.
|
||||
|
||||
= 2.5.0 =
|
||||
* Released 2021-02-18
|
||||
* Medium level (6.5) security fix. Please update as soon as possible.
|
||||
* Cleaned up REST user data so only pertitent information is returned to prevent user data leakage to roles with the upload_files capability.
|
||||
|
||||
= 2.4.0 =
|
||||
* Released 2020-11-17
|
||||
* Fixing REST issues.
|
||||
* Cleaning up dist scripts.
|
||||
* General code cleanup.
|
||||
|
||||
= 2.3.11 =
|
||||
* Released 2020-02-29
|
||||
* Added option to disable image sizes.
|
||||
|
||||
= 2.3.10 =
|
||||
* Released 2019-12-29
|
||||
* Added new hook for add-on capability.
|
||||
|
||||
= 2.3.9 =
|
||||
* Released 2019-12-06
|
||||
* Removing adverts for User Profile Picture Enhanced.
|
||||
|
||||
= 2.3.8 =
|
||||
* Released 2019-10-30
|
||||
* Removing top-level navigation.
|
||||
|
||||
= 2.3.7 =
|
||||
* Released 2019-10-23
|
||||
* Fixing options not being saved properly.
|
||||
|
||||
= 2.3.6 =
|
||||
* Released 2019-10-09
|
||||
* Updating compatibility with WordPress 5.3
|
||||
* Fixing JavaScript error in WordPress 5.3
|
||||
|
||||
= 2.3.5 =
|
||||
* Released 2019-09-17
|
||||
* Added option in Gutenberg block to customize the View Posts and View Website text.
|
||||
|
||||
= 2.3.2 =
|
||||
* Released 2019-07-14
|
||||
* Adding more filters for third-party plugin integration.
|
||||
|
||||
= 2.3.0 =
|
||||
* Released 2019-07-06
|
||||
* Gutenberg blocks are now in the User Profile Picture category.
|
||||
* New filters for add-on extensibility
|
||||
* Added Options page so you can disable the Gutenberg blocks if you so desire.
|
||||
* Bug fix: Adding user display name to post title when User Profile Picture creates the user page.
|
||||
|
||||
= 2.2.8 =
|
||||
* Released 2019-06-11
|
||||
* New REST API endpoint for changing profile pictures.
|
||||
|
||||
= 2.2.7 =
|
||||
* Released 2019-06-11
|
||||
* Fixing permissions in REST API
|
||||
|
||||
= 2.2.6 =
|
||||
* Released 2019-06-10
|
||||
* Fixing permissions in REST API
|
||||
|
||||
= 2.2.5 =
|
||||
* Released 2019-06-02
|
||||
* Code cleanup.
|
||||
* Leaner Gutenberg JavaScript.
|
||||
* Gutenberg improvements.
|
||||
* Security improvements.
|
||||
|
||||
= 2.2.0 =
|
||||
* Released 2019-05-12
|
||||
* Added template tags for displaying an author box
|
||||
|
||||
= 2.1.3 =
|
||||
* Released 2019-02-16
|
||||
* Added filter to get users in Gutenberg besides author
|
||||
|
||||
= 2.1.2 =
|
||||
* Released 2019-01-26
|
||||
* Resolving PHP notice for dirname
|
||||
|
||||
= 2.1.1 =
|
||||
* Released 2018-12-20
|
||||
* Adding white posts theme to the tabbed view block
|
||||
* Fixing clearing for the tabbed view block
|
||||
|
||||
= 2.1.0 =
|
||||
* Released 2018-12-19
|
||||
* Old block deprecated, but still supported
|
||||
* New block added with more control over appearance and includes themes.
|
||||
|
||||
= 2.0.2 =
|
||||
* Released 2018-11-20
|
||||
* Gutenberg fixes with alignment (center, right) on the front end.
|
||||
* Gutenberg fixes with the toggle boxes defaulting back to nothing.
|
||||
|
||||
= 2.0.1 =
|
||||
* Released 2018-11-20
|
||||
* Fixing PHP 5.2 incompatibility
|
||||
* Fixing Gutenberg block when there is no profile picture present on the front-end
|
||||
* Updating translations file
|
||||
|
||||
= 2.0.0 =
|
||||
* Released 2018-11-19
|
||||
* Added Gutenberg block for easy outputting to posts
|
||||
* Tested with WordPress 5.0
|
||||
|
||||
= 1.5.5 =
|
||||
* Released 2018-08-19
|
||||
* Enhancement: Loading image now shows between states for better UX
|
||||
* Enhancement: Plugin attempts to override the default WordPress avatar in the User Profile page
|
||||
* Enhancement: Plugin attempts to override the admin bar avatars if the users match
|
||||
* Enhancement: Added Click to Edit bar to make it more obvious what to do with the profile picture
|
||||
* Refactor: Plugin now uses wp_send_json instead of json_encode for more compatibility
|
||||
|
||||
= 1.5.1 =
|
||||
* Released 2018-07-12
|
||||
* Fixed a condition where a featured image was shown for the author instead of a blank gravatar
|
||||
|
||||
= 1.5.0 =
|
||||
* Released 2018-07-11
|
||||
* Support for AMP avatar has been added
|
||||
* Two REST API endpoints have been added to facilitate better programatic avatar selection
|
||||
|
||||
= 1.4.3 =
|
||||
* Released 2016-09-24
|
||||
* Bug fix: Post featured image is being shown as user's profile picture when no avatar is selected.
|
||||
|
||||
= 1.4.1 =
|
||||
* Released 2016-08-30 (Props @Monter)
|
||||
* Fix select states in image modal
|
||||
|
||||
= 1.4.0 =
|
||||
* Released 2016-08-29 (props kelderic)
|
||||
* Bug fix: CSS Fixes to the trashcan icon and image placeholders
|
||||
* Bug fix: Modal window was set to the wrong settings
|
||||
* Enhancement: Avatar override is now the default option
|
||||
|
||||
= 1.3.1 =
|
||||
* Released 2016-04-02
|
||||
* Fixing thumbnail calls that could potential be inadvertently filtered and cause the profile picture to provide an erroneous callback. Props @Monter.
|
||||
|
||||
= 1.3.0 =
|
||||
* Released 2016-03-28
|
||||
* Adding REST API endpoint
|
||||
|
||||
= 1.2.7 =
|
||||
* Updated 2015-08-20 for WP 4.3 compatibility
|
||||
* Released 2015-06-10
|
||||
* Bug fix: warning message saying missing argument for avatar_override
|
||||
|
||||
= 1.2.5 =
|
||||
* Released 2015-06-06
|
||||
* Bug fix: get_avatar override now accepts custom classes.
|
||||
* Added `mpp_avatar_classes` filter to get_avatar override to allow global class overrides/additions.
|
||||
|
||||
= 1.2.3 =
|
||||
* Released 2015-05-20
|
||||
* Revised post type initialization to make sure post type is completely hidden.
|
||||
* Refactored function mt_profile_img to use a different API call so that output isn't inadvertently filtered.
|
||||
* Added new filter, mpp_thumbnail_html, to filter output.
|
||||
|
||||
= 1.2.2 =
|
||||
* Released 2015-04-16
|
||||
* Added compatibility to Advanced Custom Fields.
|
||||
* Added increased capabilities check to Ajax calls.
|
||||
* Ensuring WordPress 4.2 compatibility.
|
||||
|
||||
= 1.2.1 =
|
||||
* Released 2015-03-03
|
||||
* Fixed internationalization errors.
|
||||
* Added Spanish translation.
|
||||
|
||||
= 1.2.0 =
|
||||
* Released 2014-12-07
|
||||
* Reducing clutter in the interface. Removed text option to upload. Added default image if no profile image is available. Added option to remove the profile image.
|
||||
* Fixed internationalization bug in the JavaScript.
|
||||
|
||||
= 1.1.0 =
|
||||
* Released 2014-11-11
|
||||
* Added the ability to remove profile images (aside from deleting the image).
|
||||
* Added better internationalization capabilities.
|
||||
* Added compatibility with <a href="https://wordpress.org/plugins/theme-my-login/">Theme My Login</a>.
|
||||
|
||||
= 1.0.23 =
|
||||
* Released 2014-10-20
|
||||
* Added a new filter to allow the "Override Avatar" interface to be hidden (and turned on my default).
|
||||
|
||||
= 1.0.22 =
|
||||
* Released 2014-09-02
|
||||
* Added minor update to additional user meta for easier querying (props Solinx)
|
||||
|
||||
= 1.0.21 =
|
||||
* Released 2013-09-09
|
||||
* Fixed avatar override on options discussion page.
|
||||
|
||||
= 1.0.20 =
|
||||
* Released 2013-05-13
|
||||
* Added a filter for turning on "Override Avatar" by default.
|
||||
|
||||
= 1.0.19 =
|
||||
* Added support for 2.0.x version of <a href='http://wordpress.org/extend/plugins/post-thumbnail-editor/'>Post Thumbnail Editor</a>
|
||||
|
||||
= 1.0.18 =
|
||||
* Added basic multisite support
|
||||
|
||||
= 1.0.16 =
|
||||
* Fixed a bug where only the profile image interface was showing for only authors and not editors and administrators.
|
||||
|
||||
= 1.0.15 =
|
||||
* Built-in support for <a href="http://wordpress.org/extend/plugins/post-thumbnail-editor/">Post Thumbnail Editor</a>
|
||||
* Better integration with the new WP 3.5 media uploader
|
||||
* Various bug fixes.
|
||||
|
||||
= 1.0.10 =
|
||||
* Usability enhancements.
|
||||
* Stripping out useless code.
|
||||
* Updating documentation
|
||||
|
||||
= 1.0.9 =
|
||||
* Adding support for the new 3.5 media uploader.
|
||||
|
||||
= 1.0.3 =
|
||||
* Bug fix: Avatar classes in the comment section
|
||||
|
||||
= 1.0.2 =
|
||||
* Bug fix: Error being shown in comment section
|
||||
|
||||
= 1.0.1 =
|
||||
* Bug fix: Not able to "uncheck" Override Avatar.
|
||||
* Bug fix: Deleting profile image and not reverting to normal avatar.
|
||||
|
||||
= 1.0.0 =
|
||||
* Initial release.
|
||||
|
||||
== Upgrade Notice ==
|
||||
|
||||
= 2.6.0 =
|
||||
Please update. Fixed a security flaw where a user can change others profile picture.
|
||||
|
||||
= 2.5.0 =
|
||||
Medium level (6.5) security fix. Please update as soon as possible. Cleaned up REST user data so only pertitent information is returned to prevent user data leakage to roles with the upload_files capability.
|
||||
|
||||
= 2.4.0 =
|
||||
Fixing REST issues. Cleaning up dist scripts. General code cleanup.
|
||||
|
||||
= 2.3.11 =
|
||||
Added option to disable image sizes.
|
||||
|
||||
= 2.3.10 =
|
||||
Added new hook for add-on capability.
|
Reference in New Issue
Block a user