qa
Signed-off-by: Jeff <jeff@gotenzing.com>
Showing
14 changed files
with
46 additions
and
31 deletions
| ... | @@ -18953,7 +18953,7 @@ ul.sf_date_field .sf-datepicker { | ... | @@ -18953,7 +18953,7 @@ ul.sf_date_field .sf-datepicker { |
| 18953 | @media screen and (max-width: 59.375rem) { | 18953 | @media screen and (max-width: 59.375rem) { |
| 18954 | #search-wrapper #main > article .photo { | 18954 | #search-wrapper #main > article .photo { |
| 18955 | max-width: 100%; | 18955 | max-width: 100%; |
| 18956 | max-height: unset; | 18956 | max-height: 200px; |
| 18957 | max-width: 100%; | 18957 | max-width: 100%; |
| 18958 | min-height: unset; | 18958 | min-height: unset; |
| 18959 | } | 18959 | } |
| ... | @@ -20738,7 +20738,7 @@ ul.sf_date_field .sf-datepicker { | ... | @@ -20738,7 +20738,7 @@ ul.sf_date_field .sf-datepicker { |
| 20738 | .relevant-resources #relevant-resources td .rel .photo { | 20738 | .relevant-resources #relevant-resources td .rel .photo { |
| 20739 | flex-basis: 100%; | 20739 | flex-basis: 100%; |
| 20740 | max-width: 100%; | 20740 | max-width: 100%; |
| 20741 | max-height: unset; | 20741 | max-height: 200px; |
| 20742 | max-width: 100%; | 20742 | max-width: 100%; |
| 20743 | min-height: unset; | 20743 | min-height: unset; |
| 20744 | margin-right: 0px; | 20744 | margin-right: 0px; | ... | ... |
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
| ... | @@ -20767,17 +20767,6 @@ | ... | @@ -20767,17 +20767,6 @@ |
| 20767 | $('.search-box').removeClass('show'); | 20767 | $('.search-box').removeClass('show'); |
| 20768 | $('.badge').show(); | 20768 | $('.badge').show(); |
| 20769 | }); | 20769 | }); |
| 20770 | if ($(window).width() < 960) { | ||
| 20771 | $(".search-result .entry-summary, .content p").each(function () { | ||
| 20772 | var yourString = $(this).text(); | ||
| 20773 | var maxLength = 160; | ||
| 20774 | if (yourString.length > maxLength) { | ||
| 20775 | var trimmedString = yourString.substr(0, maxLength); | ||
| 20776 | trimmedString = trimmedString.substr(0, Math.min(trimmedString.length, trimmedString.lastIndexOf(" "))); | ||
| 20777 | $(this).text(trimmedString + "..."); | ||
| 20778 | } | ||
| 20779 | }); | ||
| 20780 | } | ||
| 20781 | } | 20770 | } |
| 20782 | return { | 20771 | return { |
| 20783 | init: init | 20772 | init: init |
| ... | @@ -26222,7 +26211,7 @@ | ... | @@ -26222,7 +26211,7 @@ |
| 26222 | }); | 26211 | }); |
| 26223 | 26212 | ||
| 26224 | // Add your custom JS here. | 26213 | // Add your custom JS here. |
| 26225 | new LazyLoad(); | 26214 | var myLazyLoad = new LazyLoad(); |
| 26226 | window.tz_checkVisible = function (elm, evalType, offset, heightBuffer) { | 26215 | window.tz_checkVisible = function (elm, evalType, offset, heightBuffer) { |
| 26227 | evalType = evalType || "visible"; | 26216 | evalType = evalType || "visible"; |
| 26228 | var vpH = jQuery(window).height(), | 26217 | var vpH = jQuery(window).height(), |
| ... | @@ -26238,6 +26227,7 @@ | ... | @@ -26238,6 +26227,7 @@ |
| 26238 | if (evalType === "above") return y < vpH + st; | 26227 | if (evalType === "above") return y < vpH + st; |
| 26239 | }; | 26228 | }; |
| 26240 | jQuery(document).ready(function ($) { | 26229 | jQuery(document).ready(function ($) { |
| 26230 | trim_text(); | ||
| 26241 | $('#relevant-resources').dataTable({ | 26231 | $('#relevant-resources').dataTable({ |
| 26242 | info: false, | 26232 | info: false, |
| 26243 | ordering: false, | 26233 | ordering: false, |
| ... | @@ -26252,6 +26242,19 @@ | ... | @@ -26252,6 +26242,19 @@ |
| 26252 | scrollTop: $("#relevant-resources").offset().top - 250 | 26242 | scrollTop: $("#relevant-resources").offset().top - 250 |
| 26253 | }, 100); | 26243 | }, 100); |
| 26254 | }); | 26244 | }); |
| 26245 | function trim_text() { | ||
| 26246 | if ($(window).width() < 960) { | ||
| 26247 | $(".search-result .entry-summary, .content p").each(function () { | ||
| 26248 | var yourString = $(this).text(); | ||
| 26249 | var maxLength = 160; | ||
| 26250 | if (yourString.length > maxLength) { | ||
| 26251 | var trimmedString = yourString.substr(0, maxLength); | ||
| 26252 | trimmedString = trimmedString.substr(0, Math.min(trimmedString.length, trimmedString.lastIndexOf(" "))); | ||
| 26253 | $(this).text(trimmedString + "..."); | ||
| 26254 | } | ||
| 26255 | }); | ||
| 26256 | } | ||
| 26257 | } | ||
| 26255 | (function () { | 26258 | (function () { |
| 26256 | var origOpen = XMLHttpRequest.prototype.open; | 26259 | var origOpen = XMLHttpRequest.prototype.open; |
| 26257 | XMLHttpRequest.prototype.open = function (method, url) { | 26260 | XMLHttpRequest.prototype.open = function (method, url) { |
| ... | @@ -26261,7 +26264,8 @@ | ... | @@ -26261,7 +26264,8 @@ |
| 26261 | $('html, body, #page').animate({ | 26264 | $('html, body, #page').animate({ |
| 26262 | scrollTop: $("#search-wrapper").offset().top - 250 | 26265 | scrollTop: $("#search-wrapper").offset().top - 250 |
| 26263 | }, 100); | 26266 | }, 100); |
| 26264 | console.log('click'); | 26267 | myLazyLoad.update(); |
| 26268 | trim_text(); | ||
| 26265 | }, 100); | 26269 | }, 100); |
| 26266 | } | 26270 | } |
| 26267 | }); | 26271 | }); | ... | ... |
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
| ... | @@ -61,7 +61,11 @@ if ( !empty( $terms ) && !is_wp_error( $terms ) ){ | ... | @@ -61,7 +61,11 @@ if ( !empty( $terms ) && !is_wp_error( $terms ) ){ |
| 61 | } | 61 | } |
| 62 | 62 | ||
| 63 | ?> | 63 | ?> |
| 64 | <img src='<?= $image ?>' loading="eager" alt='<?= $image_alt ?>' /> | 64 | |
| 65 | |||
| 66 | |||
| 67 | |||
| 68 | <img src='#' data-src="<?= $image ?>" class='lazy' alt='<?= $image_alt ?>' /> | ||
| 65 | </div> | 69 | </div> |
| 66 | <?php endif; ?> | 70 | <?php endif; ?> |
| 67 | <div class='content'> | 71 | <div class='content'> | ... | ... |
| ... | @@ -48,17 +48,7 @@ var Search = (function($) { | ... | @@ -48,17 +48,7 @@ var Search = (function($) { |
| 48 | $('.badge').show(); | 48 | $('.badge').show(); |
| 49 | }) | 49 | }) |
| 50 | 50 | ||
| 51 | if ($(window).width() < 960) { | 51 | |
| 52 | $( ".search-result .entry-summary, .content p" ).each(function() { | ||
| 53 | var yourString = $(this).text(); | ||
| 54 | var maxLength = 160; | ||
| 55 | if (yourString.length > maxLength) { | ||
| 56 | var trimmedString = yourString.substr(0, maxLength); | ||
| 57 | trimmedString = trimmedString.substr(0, Math.min(trimmedString.length, trimmedString.lastIndexOf(" "))); | ||
| 58 | $(this).text(trimmedString + "..."); | ||
| 59 | } | ||
| 60 | }); | ||
| 61 | } | ||
| 62 | } | 52 | } |
| 63 | 53 | ||
| 64 | return { | 54 | return { | ... | ... |
| ... | @@ -35,6 +35,7 @@ window.tz_checkVisible = function(elm, evalType , offset, heightBuffer) { | ... | @@ -35,6 +35,7 @@ window.tz_checkVisible = function(elm, evalType , offset, heightBuffer) { |
| 35 | 35 | ||
| 36 | jQuery(document).ready(function($) { | 36 | jQuery(document).ready(function($) { |
| 37 | 37 | ||
| 38 | trim_text(); | ||
| 38 | $('#relevant-resources').dataTable( { | 39 | $('#relevant-resources').dataTable( { |
| 39 | info: false, | 40 | info: false, |
| 40 | ordering: false, | 41 | ordering: false, |
| ... | @@ -53,6 +54,21 @@ jQuery(document).ready(function($) { | ... | @@ -53,6 +54,21 @@ jQuery(document).ready(function($) { |
| 53 | }); | 54 | }); |
| 54 | 55 | ||
| 55 | 56 | ||
| 57 | function trim_text(){ | ||
| 58 | if ($(window).width() < 960) { | ||
| 59 | $( ".search-result .entry-summary, .content p" ).each(function() { | ||
| 60 | var yourString = $(this).text(); | ||
| 61 | var maxLength = 160; | ||
| 62 | if (yourString.length > maxLength) { | ||
| 63 | var trimmedString = yourString.substr(0, maxLength); | ||
| 64 | trimmedString = trimmedString.substr(0, Math.min(trimmedString.length, trimmedString.lastIndexOf(" "))); | ||
| 65 | $(this).text(trimmedString + "..."); | ||
| 66 | } | ||
| 67 | }); | ||
| 68 | } | ||
| 69 | } | ||
| 70 | |||
| 71 | |||
| 56 | 72 | ||
| 57 | (function() { | 73 | (function() { |
| 58 | var origOpen = XMLHttpRequest.prototype.open; | 74 | var origOpen = XMLHttpRequest.prototype.open; |
| ... | @@ -63,7 +79,8 @@ jQuery(document).ready(function($) { | ... | @@ -63,7 +79,8 @@ jQuery(document).ready(function($) { |
| 63 | $('html, body, #page').animate({ | 79 | $('html, body, #page').animate({ |
| 64 | scrollTop: $("#search-wrapper").offset().top - 250 | 80 | scrollTop: $("#search-wrapper").offset().top - 250 |
| 65 | }, 100); | 81 | }, 100); |
| 66 | console.log('click'); | 82 | myLazyLoad.update(); |
| 83 | trim_text(); | ||
| 67 | }, 100); | 84 | }, 100); |
| 68 | } | 85 | } |
| 69 | }); | 86 | }); | ... | ... |
| ... | @@ -31,7 +31,7 @@ | ... | @@ -31,7 +31,7 @@ |
| 31 | @media screen and (max-width: 59.375rem) { | 31 | @media screen and (max-width: 59.375rem) { |
| 32 | flex-basis: 100%; | 32 | flex-basis: 100%; |
| 33 | max-width: 100%; | 33 | max-width: 100%; |
| 34 | max-height: unset; | 34 | max-height: 200px; |
| 35 | max-width: 100%; | 35 | max-width: 100%; |
| 36 | min-height: unset; | 36 | min-height: unset; |
| 37 | margin-right: 0px; | 37 | margin-right: 0px; | ... | ... |
| ... | @@ -48,7 +48,7 @@ | ... | @@ -48,7 +48,7 @@ |
| 48 | border: 1px solid #bebebe; | 48 | border: 1px solid #bebebe; |
| 49 | @media screen and (max-width: 59.375rem) { | 49 | @media screen and (max-width: 59.375rem) { |
| 50 | max-width: 100%; | 50 | max-width: 100%; |
| 51 | max-height: unset; | 51 | max-height: 200px; |
| 52 | max-width: 100%; | 52 | max-width: 100%; |
| 53 | min-height: unset; | 53 | min-height: unset; |
| 54 | } | 54 | } | ... | ... |
-
Please register or sign in to post a comment