Skip to content

Commit

Permalink
merging to prod for releasing v2.3.5 (#1106)
Browse files Browse the repository at this point in the history
* Fixed printing map function on fullscreen mode

* Increases version

* Fixes legen box styling after existing the print view

* Fixes #1101 (#1103)

* Fixes #1104 (#1105)

* added orange to _colors.less

* Harmonizing date formats
  • Loading branch information
Alex Corbi authored Jul 16, 2017
1 parent 241140c commit ab28c6e
Show file tree
Hide file tree
Showing 11 changed files with 165 additions and 103 deletions.
12 changes: 5 additions & 7 deletions inc/jeo-scripts/fullscreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,23 +48,21 @@
$('body').removeClass('map-fullscreen');
container.removeClass('fullscreen-map');
$(".baselayer-container").removeClass('fullscreen-map');
$(".category-map-layers").removeClass('fullscreen-map');
$(".map-legend-container").removeClass('fullscreen-map');
if (frame) {
frame.id = "";
}
} else {
$('body').addClass('map-fullscreen');
container.addClass('fullscreen-map');
$(".baselayer-container").addClass('fullscreen-map');
$(".category-map-layers").addClass('fullscreen-map');
$(".map-legend-container").addClass('fullscreen-map');

if (frame) {
frame.id = "iframe-fullscreen-map";
}

/*if ( self !== top ) {
}else{
}*/

}
}

this._map.invalidateSize(true);
Expand Down
1 change: 1 addition & 0 deletions inc/jeo-scripts/printmap.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@ var printing_map;
$(".printing-description").hide();
$(".printing-description").text("");
$(".baselayer-container").show();
$(".map-legend-container").height("5px");
$(".category-map-layers").show();
if ($(".map-legend-ul li").length > 2){
$(".map-legend-container").fadeIn();
Expand Down
2 changes: 1 addition & 1 deletion inc/utils/content.php
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ function echo_post_meta($the_post, $show_elements = array('date','categories','t
if (odm_language_manager()->get_current_language() == 'km') {
echo convert_date_to_kh_date(get_the_modified_time('j.M.Y'));
} else {
echo get_the_modified_time('Y-m-d');
echo get_the_modified_time('j F Y');
}
?>
<?php else: ?>
Expand Down
1 change: 1 addition & 0 deletions less/_colors.less
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
@black: #000000;
@red: #ff0000;
@green: #7dd220;
@orange: #ffd000;

// Resource's format
@format-default: @gray;
Expand Down
68 changes: 40 additions & 28 deletions less/_map-explorer.less
Original file line number Diff line number Diff line change
Expand Up @@ -30,21 +30,46 @@ section#map{
height: 100%;
z-index: 9999999;
}

.interactive-map .fullscreen-map, .fullscreen-map.map-container {
bottom: 0;
height: auto !important;
left: 0;
position: fixed !important;
right: 0;
top: 0;
width: auto !important;
z-index: 9999999;
}
.baselayer-container.fullscreen-map{
top: 5px;
left: 5px;
right: auto;
.map-fullscreen{
.fullscreen-map.map-container {
bottom: 0;
height: auto !important;
left: 0;
position: fixed !important;
right: 0;
top: 0;
width: auto !important;
z-index: 9999999;
}
.baselayer-container.fullscreen-map{
top: 5px;
left: 5px;
right: auto;
bottom: auto;
}
.category-map-layers.fullscreen-map{
z-index: 9999999 !important;
position: fixed !important;
right: 10px !important;
left: auto;
top: 10px;
bottom: auto;
z-index: 100;
background: #fff;
width: 270px !important;
height: auto !important;
}
.map-legend-container.fullscreen-map{
width: 250px !important;
z-index: 9999999 !important;
position: fixed !important;
left: 0 !important;
right: auto;
top: auto;
}
.leaflet-left {
left: 5px !important;
}
}
.interactive-map {
border: 0;
Expand Down Expand Up @@ -849,19 +874,6 @@ html#map-embed {
}
/*********************************/

.map-fullscreen {
.category-map-layers{
z-index: 9999999 !important;
position: fixed !important;
right: 10px !important;
}
.map-legend-container{
z-index: 9999999 !important;
position: fixed !important;
left: 0 !important;
}
}

.leaflet-popup-tip-container{
width: 25px !important;
height: 25px !important;
Expand Down
48 changes: 38 additions & 10 deletions less/_print-map.less
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,16 @@
height: 100%;
}

.print-preview-basemap .north-direction {
width: 14px;
height: 32px;
float: left;
margin-top: 1px;
margin-right: 2px;
.print-preview-basemap {
left: 5px;

.north-direction {
width: 14px;
height: 32px;
float: left;
margin-top: 1px;
margin-right: 2px;
}
}
.map-container {
position: absolute;
Expand All @@ -66,15 +70,39 @@
width: auto !important;
height: auto !important;

.map {
/*left: -13%;
width: 115%;*/
&.fullscreen-map {
position: absolute !important;
}

.leaflet-left {
left: 0 !important;
}
}

.category-map-layers {
&.fullscreen-map {
position: absolute !important;
}
}

.map-legend-container {
&.fullscreen-map {
position: absolute !important;
}
}

.baselayer-container {
&.fullscreen-map {
position: absolute !important;
}
}
.priting_footer {
z-index: 9999999;
}

.map-title{
margin-top: 5px;
z-index: 9;
z-index: 99999999;
position: relative;
text-align: center;
width: auto;
Expand Down
13 changes: 11 additions & 2 deletions less/_stories.less
Original file line number Diff line number Diff line change
@@ -1,18 +1,27 @@
.story-header{

header{
min-height: 400px;

.post-title{
background-color: rgba(0,0,0,0.3);
margin: 200px auto;
text-align: center;
padding: @big-padd;

h1{
font-size: 48px;
color: #fff;
line-height: @header-line-height;
}

img{
-webkit-filter: brightness(70%);
filter: brightness(70%);
}

}

p{
color: #fff;
}

.post-meta{
Expand Down
1 change: 1 addition & 0 deletions less/_variables.less
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@font-size-h6: 12px;
@font-size-h7: 10px;

@header-line-height: 48px;
@title-line-height: 32px;
@subtitle-line-height: 24px;
@paragraph-line-height: 21px;
Expand Down
36 changes: 19 additions & 17 deletions less/opendev.less
Original file line number Diff line number Diff line change
Expand Up @@ -13,32 +13,34 @@ img {

table {
border-collapse: collapse;
margin: 25px 0 20px;
margin: 20px auto;
border-spacing: 0px;
border-left: 1px solid #AAA;
border-right: 1px solid #AAA;
border-bottom: 1px solid #AAA;
color: #111;
}

tr{
border: 1px solid #AAA;
tr{

&:nth-child(2n) {
background-color: #FFF;
}

&:nth-child(2n) {
background-color: #FFF;
&:nth-child(2n+1) {
background-color: @light-gray;
}
}

&:nth-child(2n+1) {
background-color: #6393D2;
td{
padding: 2px 10px;
line-height: 1.42857;
vertical-align: top;

p{
padding: @xsmall-padd;
margin: 0px;
}
}
}

td{
padding: 8px;
line-height: 1.42857;
vertical-align: top;
border-top: 1px solid #bbb;
}


#od-head {
h1 {
Expand Down
84 changes: 47 additions & 37 deletions single-story.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,48 +7,58 @@

<article id="content" class="single-post">

<?php
if (has_post_thumbnail() ): ?>
<div class="story-header">
<?php $image = wp_get_attachment_image_src( get_post_thumbnail_id(), 'single-post-thumbnail' ); ?>
<header style="min-height:400px;background-image: url('<?php echo $image[0]; ?>')">
<div class="container">
<div class="row">
<div class="eight columns offset-by-four">
<div class="post-title">
<h1><?php the_title(); ?></h1>
<section class="container section-title main-title">
<div class="row">

<?php
if (has_post_thumbnail() ): ?>
<div class="sixteen columns post-title story-header">
<?php $image = wp_get_attachment_image_src( get_post_thumbnail_id(), 'single-post-thumbnail' ); ?>
<header style="min-height:400px;background: linear-gradient( rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5) ), url('<?php echo $image[0]; ?>')">
<div class="container">
<div class="row">
<div class="eight columns offset-by-four">
<div class="post-title">
<h1><?php the_title(); ?></h1>
</div>
</div>
</div>
<div class="row">
<div class="ten columns offset-by-three">
<p><?php the_excerpt(); ?></p>
</div>
</div>
<div class="row">
<div class="six columns offset-by-five">
<p><?php echo_post_meta(get_post(),array('date','categories','tags'),$date_to_show); ?></p>
</div>
</div>
<!-- <div class="row">
<div class="sixteen columns">
<div class="widget share-widget center post-meta">
<?php odm_get_template('social-share',array(),true); ?>
</div>
</div>
</div>
</div> -->
</div>
<!-- <div class="row">
<div class="sixteen columns">
<div class="widget share-widget center post-meta">
<?php odm_get_template('social-share',array(),true); ?>
</div>
</div>
</div> -->
</div>
</header>
</section>
<?php
</header>
</div>
<?php
else: ?>
<section class="container section-title main-title">
<header class="row">
<div class="twelve columns post-title">
<h1><?php the_title(); ?></h1>
<?php echo_post_meta(get_post()); ?>
</div>
<div class="four columns">
<div class="widget share-widget">
<?php odm_get_template('social-share',array(),true); ?>
</div>
</div>
</header>
</section>
<div class="twelve columns post-title">
<h1><?php the_title(); ?></h1>
<?php echo_post_meta(get_post()); ?>
</div>
<div class="four columns">
<div class="widget share-widget">
<?php odm_get_template('social-share',array(),true); ?>
</div>
</div>
</div>
</section>

<?php
endif; ?>
<?php
endif; ?>

<section class="container">
<div class="row">
Expand Down
2 changes: 1 addition & 1 deletion style.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Author: Open Development Mekong
Author URI: http://github.com/OpenDevelopmentMekong
Description: Open Development Mekong's wordpress theme. Based on JEO child theme
Template: jeo
Version: 2.3.2
Version: 2.3.5
License: GNU General Public License v3 or later
License URI: http://www.gnu.org/licenses/gpl-3.0.html
*/
Expand Down

0 comments on commit ab28c6e

Please sign in to comment.