From: Steve Sutton Date: Thu, 30 Aug 2018 18:52:07 +0000 (-0400) Subject: Update from main plugin X-Git-Tag: v1.0.16^2~1 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=4f3980f08590e901f3b92b8a5977a184ea28972c;p=WP-Themes%2Fvisitescanaba.git Update from main plugin view file updates for list members --- diff --git a/glm-member-db/views/front/members/list.html b/glm-member-db/views/front/members/list.html index ae614d0..780e4ec 100644 --- a/glm-member-db/views/front/members/list.html +++ b/glm-member-db/views/front/members/list.html @@ -147,7 +147,7 @@ {if $settings.selected_map_interface == 1} -
+
{/if} {if $settings.selected_map_interface == 2} @@ -192,15 +192,20 @@

{/if} {*list_map_show_address*}
-

- {if $m.phone && $settings.list_map_show_phone}Phone: {apply_filters('glm_associate_phone_filter', $m.phone)}
{/if} - {if $m.toll_free && $settings.list_map_show_tollfree}{apply_filters('glm_associate_phone_filter', $m.toll_free)}
{/if} - {if $m.url && $settings.list_map_show_url}Web site: {$m.url}
{/if} +

+ {if $m.phone && $settings.list_map_show_phone}Phone: {apply_filters('glm_associate_phone_filter', $m.phone)}
{/if} + {if $m.toll_free && $settings.list_map_show_tollfree}{apply_filters('glm_associate_phone_filter', $m.toll_free)}
{/if} {if $m.email && $settings.list_map_show_email}E-Mail Address: {$m.email}
{/if} - {if $m.region && $settings.list_map_show_region}Region: {$m.region}{/if} + {if $m.region && $settings.list_map_show_region}Region: {$m.region}
{/if} + {if $m.url && $settings.list_map_show_url}Website
{/if}

+ + {if $m.short_descr && $settings.list_map_show_short_descr}{$m.short_descr|truncate:200}
{/if} + {if $settings.list_map_show_detaillink && !$m.has_no_profile} + More Info + {/if} {if $m.categories && $settings.list_map_show_categories}
{$terms.term_member_cap} Categories @@ -598,13 +603,23 @@ }); {/if} + var mapContainerWidth = Number(leafletMap._container.clientWidth); + var maxPopupWidth = .65 * mapContainerWidth; + if (maxPopupWidth > 600) { + maxPopupWidth = 600; + } + var mapContainerHeight = Number(leafletMap._container.clientHeight); + var maxPopupHeight = .7 * mapContainerHeight; {foreach $mapItems as $m} {if $m.lat != 0 && $m.lon != 0} // Create marker for this member and and to Feature Group var leafletMarker = L.marker([{$m.lat}, {$m.lon}], { title: '{$m.member_name|escape:quotes}' }) - .bindPopup($('#map_info_' + {$m.id}).html()) + .bindPopup($('#map_info_' + {$m.id}).html(), { + maxWidth: maxPopupWidth, + maxHeight: maxPopupHeight + }) .addTo(markerGroup); {/if} @@ -621,7 +636,8 @@ leafletMap.on('popupopen', function(e) { var px = leafletMap.project(e.popup._latlng); - px.y -= e.popup._container.clientHeight/2; + px.x -= 20; // Bump a bit to the right to avoid resize buttons + px.y -= e.popup._container.clientHeight/2; // Position more toward the center leafletMap.panTo(leafletMap.unproject(px),{ animate: true }); });