Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
open-source
Guaraci WordPress Plugin
Commits
34aef05c
Commit
34aef05c
authored
Feb 07, 2020
by
Bruno Antunes Magrini
Browse files
Merge branch 'develop'
parents
67c19f2e
1a230453
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
51 additions
and
0 deletions
+51
-0
pagebuilder-components/widgets/featured-videos/featured-videos.js
...der-components/widgets/featured-videos/featured-videos.js
+1
-0
pagebuilder-widgets/posts-list/tpl/template.php
pagebuilder-widgets/posts-list/tpl/template.php
+50
-0
No files found.
pagebuilder-components/widgets/featured-videos/featured-videos.js
View file @
34aef05c
...
...
@@ -6,6 +6,7 @@
$thumbs
.
on
(
'
click
'
,
function
(
e
){
e
.
preventDefault
();
$iframe
=
$
(
this
).
parents
().
parents
().
siblings
().
children
(
'
.js-featured-videos--iframe
'
);
$iframe
.
attr
(
'
src
'
,
url
+
$
(
this
).
data
(
'
videoId
'
)
+
'
?autoplay=1
'
);
$thumbs
.
removeClass
(
'
active
'
);
$
(
this
).
addClass
(
'
active
'
);
...
...
pagebuilder-widgets/posts-list/tpl/template.php
0 → 100644
View file @
34aef05c
<div
class=
"posts-list
<?=
$instance
[
'hide_images'
]
==
'on'
?
'hide-images'
:
''
?>
<?=
$instance
[
'exibicao'
]
?>
"
>
<div
class=
"row"
style=
"max-width: 100%"
>
<?php
$query
=
new
WP_Query
(
$query_args
);
$i
=
0
;
while
(
$query
->
have_posts
())
:
$i
++
;
$query
->
the_post
();
global
$post
;
?>
<div
class=
"column large-
<?=
12
/
$instance
[
'columns'
]
?>
mb-15"
>
<div
class=
"card"
>
<?php
if
(
images\tag
(
'card-large'
,
''
)
!=
''
&&
(
(
$i
==
1
&&
$instance
[
'exibicao'
]
==
'block'
)
||
(
$instance
[
'exibicao'
]
!=
'block'
)
)
)
:
?>
<a
tabindex=
"-1"
href=
"
<?=
get_the_permalink
()
?>
"
class=
"card--image-wrapper"
>
<?php
echo
images\tag
(
'card-large'
,
'card--image'
)
?>
</a>
<?php
endif
;
?>
<div
class=
"card--content"
>
<div
class=
"categories-list"
>
<?php
$post_categories
=
wp_get_post_categories
(
get_the_ID
()
);
foreach
(
$post_categories
as
$category_id
){
$category
=
get_category
(
$category_id
);
?>
<div
class=
"categories-list--category category-
<?=
$category
->
slug
?>
"
>
<a
href=
"
<?=
esc_url
(
get_term_link
(
$category
,
'category'
))
?>
"
>
<?=
$category
->
name
?>
</a>
</div>
<?php
}
?>
</div>
<h4
class=
"card--title"
>
<a
href=
"
<?=
get_the_permalink
()
?>
"
>
<?php
the_title
()
?>
</a>
</h4>
<?php
if
(
has_excerpt
()
&&
$instance
[
'hide_excerpt'
]
!=
'on'
)
:
?>
<div
class=
"card-excerpt"
>
<?php
the_excerpt
()
?>
</div>
<?php
endif
;
?>
</div>
</div>
</div>
<?php
endwhile
?>
</div>
</div>
<?php
if
(
$link
->
url
)
:
?>
<a
href=
"
<?=
$link
->
url
?>
"
class=
"goto"
>
<?=
$link
->
label
?>
</a>
<?php
endif
;
?>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment