From: Anthony Talarico Date: Mon, 10 Dec 2018 16:47:28 +0000 (-0500) Subject: changing css file name, commenting out the unpkg cdn call for leaflet, changing the... X-Git-Tag: v1.0.0^2~22 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/index.cgi?a=commitdiff_plain;h=40ddcce295ebaa01fb56c1e1b2743319446ac320;p=WP-Plugins%2Fglm-member-db-county-map.git changing css file name, commenting out the unpkg cdn call for leaflet, changing the default coordinates for the county map display --- diff --git a/css/front.min.css b/css/front.min.css deleted file mode 100644 index 86881a8..0000000 --- a/css/front.min.css +++ /dev/null @@ -1 +0,0 @@ -#area-map-container{padding:0 10px;text-align:center;margin-bottom:25px;width:70vw;margin:0 auto;position:relative;left:-7%}#area-map-container #area-map{z-index:0;height:550px;box-shadow:0 -5px 20px rgba(0,0,0,0.19),0 6px 6px rgba(0,0,0,0.23)}.glm-theme-map-label{display:block;width:105px}@media (max-width: 1024px){#area-map-container{overflow:hidden;min-height:420px}#area-map-container #area-map{position:relative}} diff --git a/css/glm-county-map.min.css b/css/glm-county-map.min.css new file mode 100644 index 0000000..cfd80bb --- /dev/null +++ b/css/glm-county-map.min.css @@ -0,0 +1 @@ +#area-map-container{padding:0 10px;text-align:center;margin-bottom:25px;width:100%;margin:0 auto;position:relative}#area-map-container #area-map{z-index:0;height:550px;box-shadow:0 -5px 20px rgba(0,0,0,0.19),0 6px 6px rgba(0,0,0,0.23)}.glm-theme-map-label{display:block;width:105px}@media (max-width: 1024px){#area-map-container{overflow:hidden;min-height:420px}#area-map-container #area-map{position:relative}} diff --git a/gulpfile.js b/gulpfile.js index 92795ab..fd95bb0 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -28,7 +28,7 @@ gulp.task('front-sass', function() { // includePaths: sassPaths , outputStyle: 'compressed' })).on('error', swallowError) - .pipe(rename('front.min.css')) + .pipe(rename('glm-county-map.min.css')) .pipe(gulp.dest('css')) }); diff --git a/models/front/map/display.php b/models/front/map/display.php index 8bdc7ba..abb4363 100644 --- a/models/front/map/display.php +++ b/models/front/map/display.php @@ -114,7 +114,14 @@ class GlmMembersFront_map_display extends GlmDataMapSettings $pages[$page->ID]['name'] = $page->post_title; $pages[$page->ID]['url'] = get_permalink($page->ID); } - wp_enqueue_style('admin-css', GLM_MEMBERS_COUNTY_MAP_PLUGIN_URL . 'css/front.min.css'); + add_action( 'wp_enqueue_scripts', 'register_plugin_styles' ); + + function register_plugin_styles() { + + wp_register_style('front-css', GLM_MEMBERS_COUNTY_MAP_PLUGIN_URL . 'css/glm-county-map.min.css'); + wp_enqueue_style('front-css'); + } + // Compile template data $templateData = array( 'assets' => GLM_MEMBERS_COUNTY_MAP_PLUGIN_URL . 'assets/', diff --git a/sass/front/_map.scss b/sass/front/_map.scss index e178904..b6e391e 100644 --- a/sass/front/_map.scss +++ b/sass/front/_map.scss @@ -2,10 +2,10 @@ padding: 0 10px; text-align: center; margin-bottom: 25px; - width: 70vw; + width: 100%; margin: 0 auto; position: relative; - left: -7%; + // left: -7%; #area-map{ z-index: 0; height: 550px; diff --git a/views/front/map/display.html b/views/front/map/display.html index adc56ce..16e7c8e 100644 --- a/views/front/map/display.html +++ b/views/front/map/display.html @@ -2,19 +2,19 @@
- - - - + + +