Merge branch 'issue6' into develop

This commit is contained in:
leogermani 2019-01-11 17:21:55 -02:00
commit a97672258e
7 changed files with 103 additions and 154 deletions

View File

@ -7,7 +7,8 @@
],
"require": {
"twbs/bootstrap": "4.*",
"fabianobn/slick": "v1.8.*"
"fabianobn/slick": "v1.8.*",
"fabianobn/ekko-lightbox": "dev-master"
},
"scripts": {
"post-install-cmd": "bash install.sh",

185
composer.lock generated
View File

@ -1,47 +1,39 @@
{
"_readme": [
"This file locks the dependencies of your project to a known state",
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"hash": "ddc02b7d91b22a56841ec209e22e2955",
"content-hash": "98bbd33116059a9a051feb1c6e71394e",
"content-hash": "39d18487fda0792bc6d9517f079e9e45",
"packages": [
{
"name": "composer/installers",
"version": "v1.5.0",
"name": "fabianobn/ekko-lightbox",
"version": "dev-master",
"source": {
"type": "git",
"url": "https://github.com/composer/installers.git",
"reference": "049797d727261bf27f2690430d935067710049c2"
"url": "https://github.com/fabianobn/ekko-lightbox.git",
"reference": "a12102c8913e1b28da086d4072cfdcaa2ce2c92d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/composer/installers/zipball/049797d727261bf27f2690430d935067710049c2",
"reference": "049797d727261bf27f2690430d935067710049c2",
"url": "https://api.github.com/repos/fabianobn/ekko-lightbox/zipball/a12102c8913e1b28da086d4072cfdcaa2ce2c92d",
"reference": "a12102c8913e1b28da086d4072cfdcaa2ce2c92d",
"shasum": ""
},
"require": {
"composer-plugin-api": "^1.0"
},
"replace": {
"roundcube/plugin-installer": "*",
"shama/baton": "*"
},
"require-dev": {
"composer/composer": "1.0.*@dev",
"phpunit/phpunit": "^4.8.36"
},
"type": "composer-plugin",
"type": "library",
"extra": {
"class": "Composer\\Installers\\Plugin",
"branch-alias": {
"dev-master": "1.0-dev"
}
},
"autoload": {
"psr-4": {
"Composer\\Installers\\": "src/Composer/Installers"
"vendor": {
"scripts": [
"dist/ekko-lightbox.js",
"dist/ekko-lightbox.min.js"
],
"styles": [
"dist/ekko-lightbox.css"
],
"files": [
"dist/ekko-lightbox.min.js.map",
"dist/ekko-lightbox.js.map"
]
}
},
"notification-url": "https://packagist.org/downloads/",
@ -50,82 +42,20 @@
],
"authors": [
{
"name": "Kyle Robinson Young",
"email": "kyle@dontkry.com",
"homepage": "https://github.com/shama"
"name": "ashleydw",
"email": "hello@ashleyd.ws"
}
],
"description": "A multi-framework Composer library installer",
"homepage": "https://composer.github.io/installers/",
"description": "A lightbox gallery plugin for Bootstrap 4 based on the modal plugin",
"homepage": "https://github.com/ashleydw/lightbox",
"keywords": [
"Craft",
"Dolibarr",
"Eliasis",
"Hurad",
"ImageCMS",
"Kanboard",
"Lan Management System",
"MODX Evo",
"Mautic",
"Maya",
"OXID",
"Plentymarkets",
"Porto",
"RadPHP",
"SMF",
"Thelia",
"WolfCMS",
"agl",
"aimeos",
"annotatecms",
"attogram",
"bitrix",
"cakephp",
"chef",
"cockpit",
"codeigniter",
"concrete5",
"croogo",
"dokuwiki",
"drupal",
"eZ Platform",
"elgg",
"expressionengine",
"fuelphp",
"grav",
"installer",
"itop",
"joomla",
"kohana",
"laravel",
"lavalite",
"lithium",
"magento",
"majima",
"mako",
"mediawiki",
"modulework",
"modx",
"moodle",
"osclass",
"phpbb",
"piwik",
"ppi",
"puppet",
"pxcms",
"reindex",
"roundcube",
"shopware",
"silverstripe",
"sydes",
"symfony",
"typo3",
"wordpress",
"yawik",
"zend",
"zikula"
"bootstrap",
"gallery",
"jquery",
"lightbox",
"modal"
],
"time": "2017-12-29 09:13:20"
"time": "2018-12-21T18:09:49+00:00"
},
{
"name": "fabianobn/slick",
@ -144,20 +74,20 @@
"type": "library",
"notification-url": "https://packagist.org/downloads/",
"description": "This is the atualized Slick Slider used in Wordpress",
"time": "2018-06-29 17:54:50"
"time": "2018-06-29T17:54:50+00:00"
},
{
"name": "twbs/bootstrap",
"version": "v4.1.3",
"version": "v4.2.0",
"source": {
"type": "git",
"url": "https://github.com/twbs/bootstrap.git",
"reference": "3b558734382ce58b51e5fc676453bfd53bba9201"
"reference": "d50ed9a2bde22067c0e5f21d1614e477e362165a"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/twbs/bootstrap/zipball/3b558734382ce58b51e5fc676453bfd53bba9201",
"reference": "3b558734382ce58b51e5fc676453bfd53bba9201",
"url": "https://api.github.com/repos/twbs/bootstrap/zipball/d50ed9a2bde22067c0e5f21d1614e477e362165a",
"reference": "d50ed9a2bde22067c0e5f21d1614e477e362165a",
"shasum": ""
},
"replace": {
@ -195,50 +125,15 @@
"sass",
"web"
],
"time": "2018-07-24 15:54:34"
},
{
"name": "wp-bootstrap/wp-bootstrap-navwalker",
"version": "v4.1.0",
"source": {
"type": "git",
"url": "https://github.com/wp-bootstrap/wp-bootstrap-navwalker.git",
"reference": "87228b01eb4652c39349f209ee9da6ec6fa2b5c3"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/wp-bootstrap/wp-bootstrap-navwalker/zipball/87228b01eb4652c39349f209ee9da6ec6fa2b5c3",
"reference": "87228b01eb4652c39349f209ee9da6ec6fa2b5c3",
"shasum": ""
},
"require": {
"composer/installers": "~1.0"
},
"require-dev": {
"stevegrunwell/wp-enforcer": "^0.5.0"
},
"type": "library",
"notification-url": "https://packagist.org/downloads/",
"license": [
"GPL-3.0+"
],
"authors": [
{
"name": "Brandon Hubbard"
},
{
"name": "William Patton",
"email": "will@pattonwebz.com"
}
],
"description": "A custom WordPress nav walker class to fully implement the Bootstrap 4 navigation style in a custom theme using the WordPress built in menu manager.",
"time": "2018-04-14 01:22:55"
"time": "2018-12-21T17:03:29+00:00"
}
],
"packages-dev": [],
"aliases": [],
"minimum-stability": "stable",
"stability-flags": [],
"stability-flags": {
"fabianobn/ekko-lightbox": 20
},
"prefer-stable": false,
"prefer-lowest": false,
"platform": [],

View File

@ -15,9 +15,8 @@ echo "\nCopy Frameword CSS - Bootstrap ...\n\n";
mkdir("src/assets/vendor/bootstrap/js", 0777, true);
}
recurse_copy("vendor/twbs/bootstrap/scss", "src/assets/vendor/bootstrap/scss");
copy("vendor/twbs/bootstrap/dist/js/bootstrap.min.js", "src/assets/vendor/bootstrap/js/bootstrap.min.js");
copy("vendor/twbs/bootstrap/dist/js/bootstrap.bundle.min.js", "src/assets/vendor/bootstrap/js/bootstrap.min.js");
recurse_copy("vendor/twbs/bootstrap/js/src", "src/assets/vendor/bootstrap/js/src");
copy("vendor/twbs/bootstrap/site/docs/4.1/assets/js/vendor/popper.min.js", "src/assets/vendor/bootstrap/js/popper.min.js");
echo "Copy Slick for Slider...\n\n";
if (!file_exists("src/assets/vendor/slick")) {
@ -32,6 +31,13 @@ echo "Copy Slick for Slider...\n\n";
copy("vendor/fabianobn/slick/slick/ajax-loader.gif", "src/assets/vendor/slick/ajax-loader.gif");
recurse_copy("vendor/fabianobn/slick/slick/fonts", "src/assets/vendor/slick/fonts");
echo "Copy Ekko Lightbox...\n\n";
if (!file_exists("src/assets/vendor/ekko-lightbox")) {
mkdir("src/assets/vendor/ekko-lightbox/", 0777, true);
}
copy("vendor/fabianobn/ekko-lightbox/dist/ekko-lightbox.min.js", "src/assets/vendor/ekko-lightbox/ekko-lightbox.min.js");
copy("vendor/fabianobn/ekko-lightbox/dist/ekko-lightbox.css", "src/assets/vendor/ekko-lightbox/ekko-lightbox.min.css");
echo "Finish Copy files! \n\n";
function recurse_copy($src,$dst) {
@ -49,4 +55,18 @@ function recurse_copy($src,$dst) {
}
closedir($dir);
}
function delete_files($target) {
if(is_dir($target)){
$files = glob( $target . "*", GLOB_MARK ); //GLOB_MARK adds a slash to directories returned
foreach( $files as $file ){
delete_files( $file );
}
rmdir( $target );
} elseif(is_file($target)) {
unlink( $target );
}
}
'

View File

@ -112,5 +112,11 @@ jQuery( document ).ready(function( $ ) {
}
return false;
});
$('.margin-pagination .navigation.pagination[role="navigation"]').addClass('justify-content-center justify-content-md-end');
$(document).on('click', '[data-toggle="lightbox"]', function(event) {
event.preventDefault();
$(this).ekkoLightbox();
});
});

View File

@ -509,6 +509,9 @@ nav{
text-overflow: ellipsis;
white-space: nowrap;
}
.tainacan-edit-item-collection {
font-size: 1rem;
}
}
.title-back{
font: {
@ -605,4 +608,13 @@ nav{
@import "_footer";
@import "_view-mode-grid.scss";
@import "_view-mode-grid.scss";
.ekko-lightbox-nav-overlay {
a {
opacity: 1;
span {
padding: 0;
}
}
}

View File

@ -14,9 +14,9 @@ if ( ! function_exists( 'tainacan_enqueues' ) ) {
//Style
wp_register_style( 'tainacan_bootstrap4CSS', get_template_directory_uri() . '/assets/vendor/bootstrap/css/bootstrap.min.css' );
wp_enqueue_style( 'tainacan_bootstrap4CSS' );
//Popper
/* //Popper
wp_register_script( 'tainacan_popper_bootstrap4', get_template_directory_uri() . '/assets/vendor/bootstrap/js/popper.min.js', '', '', true );
wp_enqueue_script( 'tainacan_popper_bootstrap4' );
wp_enqueue_script( 'tainacan_popper_bootstrap4' ); */
//Javascript
wp_register_script( 'tainacan_bootstrap4JS', get_template_directory_uri() . '/assets/vendor/bootstrap/js/bootstrap.min.js', array( 'jquery' ), '', true );
wp_enqueue_script( 'tainacan_bootstrap4JS' );
@ -33,6 +33,14 @@ if ( ! function_exists( 'tainacan_enqueues' ) ) {
wp_register_script( 'tainacan_SlickJS', get_template_directory_uri() . '/assets/vendor/slick/js/slick.min.js', array( 'jquery' ), '1.6.1', true );
wp_enqueue_script( 'tainacan_SlickJS' );
/**
* Ekko Lightbox
*/
wp_register_style( 'tainacan_EkkoLightboxCss', get_template_directory_uri() . '/assets/vendor/ekko-lightbox/ekko-lightbox.min.css');
wp_enqueue_style( 'tainacan_EkkoLightboxCss' );
wp_register_script( 'tainacan_EkkoLightboxJs', get_template_directory_uri() . '/assets/vendor/ekko-lightbox/ekko-lightbox.min.js', array('jquery'), null, true);
wp_enqueue_script( 'tainacan_EkkoLightboxJs' );
/**
* Google
*/

View File

@ -13,9 +13,11 @@
<div class="border-bottom border-jelly-bean tainacan-title-page" style="border-width: 2px !important;">
<ul class="list-inline mb-1">
<li class="list-inline-item text-midnight-blue font-weight-bold title-page">
<?php the_title(); ?>
<?php the_title(); ?>
</li>
<li class="list-inline-item float-right title-back">
<a href="javascript:history.go(-1)"><?php _e( 'Back', 'tainacan-interface' ); ?></a>
</li>
<li class="list-inline-item float-right title-back"><a href="javascript:history.go(-1)"><?php _e( 'Back', 'tainacan-interface' ); ?></a></li>
</ul>
</div>
</div>
@ -27,6 +29,11 @@
<header class="mb-4">
<div class="header-meta text-muted mb-5">
<span class="time"><?php tainacan_meta_date_author(); ?></span>
<?php if(function_exists('tainacan_the_item_edit_link')) {
echo '<span class="tainacan-edit-item-collection">';
tainacan_the_item_edit_link(null, ' - ');
echo '</span>';
} ?>
</div>
</header>
<?php if ( tainacan_has_document() ) : ?>
@ -72,7 +79,7 @@
<div class="single-item-collection--attachments">
<?php foreach ( $attachment as $attachment ) { ?>
<div class="single-item-collection--attachments-img">
<a href="<?php echo $attachment->guid; ?>" target="_BLANK">
<a href="<?php echo $attachment->guid; ?>" data-toggle="lightbox" data-gallery="example-gallery">
<?php
echo wp_get_attachment_image( $attachment->ID, 'tainacan-interface-item-attachments' );
?>