From 89aa919dee923b60cf10c98c2d298ab4952f3629 Mon Sep 17 00:00:00 2001 From: kiballion Date: Wed, 18 Jan 2017 23:06:47 +0200 Subject: [PATCH] v2.4 --- css/magnific-popup.css | 351 ++++++++++++++++++++++++++++++++ css/style.css | 51 +++-- css/style.scss | 162 +++++++-------- curly-extension.php | 189 ++++++++--------- js/jquery.magnific-popup.min.js | 4 + js/main.js | 38 +++- js/min/main-min.js | 2 +- shortcodes/tabs.php | 97 +++++---- 8 files changed, 652 insertions(+), 242 deletions(-) create mode 100755 css/magnific-popup.css create mode 100755 js/jquery.magnific-popup.min.js diff --git a/css/magnific-popup.css b/css/magnific-popup.css new file mode 100755 index 0000000..8561e18 --- /dev/null +++ b/css/magnific-popup.css @@ -0,0 +1,351 @@ +/* Magnific Popup CSS */ +.mfp-bg { + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 1042; + overflow: hidden; + position: fixed; + background: #0b0b0b; + opacity: 0.8; } + +.mfp-wrap { + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 1043; + position: fixed; + outline: none !important; + -webkit-backface-visibility: hidden; } + +.mfp-container { + text-align: center; + position: absolute; + width: 100%; + height: 100%; + left: 0; + top: 0; + padding: 0 8px; + box-sizing: border-box; } + +.mfp-container:before { + content: ''; + display: inline-block; + height: 100%; + vertical-align: middle; } + +.mfp-align-top .mfp-container:before { + display: none; } + +.mfp-content { + position: relative; + display: inline-block; + vertical-align: middle; + margin: 0 auto; + text-align: left; + z-index: 1045; } + +.mfp-inline-holder .mfp-content, +.mfp-ajax-holder .mfp-content { + width: 100%; + cursor: auto; } + +.mfp-ajax-cur { + cursor: progress; } + +.mfp-zoom-out-cur, .mfp-zoom-out-cur .mfp-image-holder .mfp-close { + cursor: -moz-zoom-out; + cursor: -webkit-zoom-out; + cursor: zoom-out; } + +.mfp-zoom { + cursor: pointer; + cursor: -webkit-zoom-in; + cursor: -moz-zoom-in; + cursor: zoom-in; } + +.mfp-auto-cursor .mfp-content { + cursor: auto; } + +.mfp-close, +.mfp-arrow, +.mfp-preloader, +.mfp-counter { + -webkit-user-select: none; + -moz-user-select: none; + user-select: none; } + +.mfp-loading.mfp-figure { + display: none; } + +.mfp-hide { + display: none !important; } + +.mfp-preloader { + color: #CCC; + position: absolute; + top: 50%; + width: auto; + text-align: center; + margin-top: -0.8em; + left: 8px; + right: 8px; + z-index: 1044; } + .mfp-preloader a { + color: #CCC; } + .mfp-preloader a:hover { + color: #FFF; } + +.mfp-s-ready .mfp-preloader { + display: none; } + +.mfp-s-error .mfp-content { + display: none; } + +button.mfp-close, +button.mfp-arrow { + overflow: visible; + cursor: pointer; + background: transparent; + border: 0; + -webkit-appearance: none; + display: block; + outline: none; + padding: 0; + z-index: 1046; + box-shadow: none; + touch-action: manipulation; } + +button::-moz-focus-inner { + padding: 0; + border: 0; } + +.mfp-close { + width: 44px; + height: 44px; + line-height: 44px; + position: absolute; + right: 0; + top: 0; + text-decoration: none; + text-align: center; + opacity: 0.65; + padding: 0 0 18px 10px; + color: #FFF; + font-style: normal; + font-size: 28px; + font-family: Arial, Baskerville, monospace; } + .mfp-close:hover, + .mfp-close:focus { + opacity: 1; } + .mfp-close:active { + top: 1px; } + +.mfp-close-btn-in .mfp-close { + color: #333; } + +.mfp-image-holder .mfp-close, +.mfp-iframe-holder .mfp-close { + color: #FFF; + right: -6px; + text-align: right; + padding-right: 6px; + width: 100%; } + +.mfp-counter { + position: absolute; + top: 0; + right: 0; + color: #CCC; + font-size: 12px; + line-height: 18px; + white-space: nowrap; } + +.mfp-arrow { + position: absolute; + opacity: 0.65; + margin: 0; + top: 50%; + margin-top: -55px; + padding: 0; + width: 90px; + height: 110px; + -webkit-tap-highlight-color: transparent; } + .mfp-arrow:active { + margin-top: -54px; } + .mfp-arrow:hover, + .mfp-arrow:focus { + opacity: 1; } + .mfp-arrow:before, + .mfp-arrow:after { + content: ''; + display: block; + width: 0; + height: 0; + position: absolute; + left: 0; + top: 0; + margin-top: 35px; + margin-left: 35px; + border: medium inset transparent; } + .mfp-arrow:after { + border-top-width: 13px; + border-bottom-width: 13px; + top: 8px; } + .mfp-arrow:before { + border-top-width: 21px; + border-bottom-width: 21px; + opacity: 0.7; } + +.mfp-arrow-left { + left: 0; } + .mfp-arrow-left:after { + border-right: 17px solid #FFF; + margin-left: 31px; } + .mfp-arrow-left:before { + margin-left: 25px; + border-right: 27px solid #3F3F3F; } + +.mfp-arrow-right { + right: 0; } + .mfp-arrow-right:after { + border-left: 17px solid #FFF; + margin-left: 39px; } + .mfp-arrow-right:before { + border-left: 27px solid #3F3F3F; } + +.mfp-iframe-holder { + padding-top: 40px; + padding-bottom: 40px; } + .mfp-iframe-holder .mfp-content { + line-height: 0; + width: 100%; + max-width: 900px; } + .mfp-iframe-holder .mfp-close { + top: -40px; } + +.mfp-iframe-scaler { + width: 100%; + height: 0; + overflow: hidden; + padding-top: 56.25%; } + .mfp-iframe-scaler iframe { + position: absolute; + display: block; + top: 0; + left: 0; + width: 100%; + height: 100%; + box-shadow: 0 0 8px rgba(0, 0, 0, 0.6); + background: #000; } + +/* Main image in popup */ +img.mfp-img { + width: auto; + max-width: 100%; + height: auto; + display: block; + line-height: 0; + box-sizing: border-box; + padding: 40px 0 40px; + margin: 0 auto; } + +/* The shadow behind the image */ +.mfp-figure { + line-height: 0; } + .mfp-figure:after { + content: ''; + position: absolute; + left: 0; + top: 40px; + bottom: 40px; + display: block; + right: 0; + width: auto; + height: auto; + z-index: -1; + box-shadow: 0 0 8px rgba(0, 0, 0, 0.6); + background: #444; } + .mfp-figure small { + color: #BDBDBD; + display: block; + font-size: 12px; + line-height: 14px; } + .mfp-figure figure { + margin: 0; } + +.mfp-bottom-bar { + margin-top: -36px; + position: absolute; + top: 100%; + left: 0; + width: 100%; + cursor: auto; } + +.mfp-title { + text-align: left; + line-height: 18px; + color: #F3F3F3; + word-wrap: break-word; + padding-right: 36px; } + +.mfp-image-holder .mfp-content { + max-width: 100%; } + +.mfp-gallery .mfp-image-holder .mfp-figure { + cursor: pointer; } + +@media screen and (max-width: 800px) and (orientation: landscape), screen and (max-height: 300px) { + /** + * Remove all paddings around the image on small screen + */ + .mfp-img-mobile .mfp-image-holder { + padding-left: 0; + padding-right: 0; } + .mfp-img-mobile img.mfp-img { + padding: 0; } + .mfp-img-mobile .mfp-figure:after { + top: 0; + bottom: 0; } + .mfp-img-mobile .mfp-figure small { + display: inline; + margin-left: 5px; } + .mfp-img-mobile .mfp-bottom-bar { + background: rgba(0, 0, 0, 0.6); + bottom: 0; + margin: 0; + top: auto; + padding: 3px 5px; + position: fixed; + box-sizing: border-box; } + .mfp-img-mobile .mfp-bottom-bar:empty { + padding: 0; } + .mfp-img-mobile .mfp-counter { + right: 5px; + top: 3px; } + .mfp-img-mobile .mfp-close { + top: 0; + right: 0; + width: 35px; + height: 35px; + line-height: 35px; + background: rgba(0, 0, 0, 0.6); + position: fixed; + text-align: center; + padding: 0; } } + +@media all and (max-width: 900px) { + .mfp-arrow { + -webkit-transform: scale(0.75); + transform: scale(0.75); } + .mfp-arrow-left { + -webkit-transform-origin: 0; + transform-origin: 0; } + .mfp-arrow-right { + -webkit-transform-origin: 100%; + transform-origin: 100%; } + .mfp-container { + padding-left: 6px; + padding-right: 6px; } } diff --git a/css/style.css b/css/style.css index c2a2433..d98a0ea 100644 --- a/css/style.css +++ b/css/style.css @@ -1,13 +1,18 @@ -@charset "UTF-8"; -/** Table of Contents: 8.0 - Shortcodes 8.1 - Accordion 8.2 - Slider 8.3 - Action Boxes 8.4 - Lists 8.5 - Buttons 8.6 - Toggle Box 8.7 - Clients Slider 8.8 - Columns 8.9 - Dividers 8.10 - Boxes 8.11 - Tabs 8.12 - Marker 8.13 - Drop cap 8.14 - Person 8.15 - Icons 8.16 - Zoomify 8.17 - Blockquote 8.18 - Testimonials 8.19 - Map Maker 8.20 - Pricing Table 8.21 - Event Agenda 8.22 - Countdown 8.23 - Alerts 8.24 - Progress Bar 8.25 - Full Width ----------------------------------------------------------------------------- */ +/** Table of Contents: 8.0 - Shortcodes 8.1 - Accordion 8.2 - Slider 8.3 - Action Boxes 8.4 - Lists 8.5 - Buttons 8.6 - Toggle Box 8.7 - Clients Slider 8.8 - Columns 8.9 - Dividers 8.10 - Boxes 8.11 - Tabs 8.12 - Marker 8.13 - Drop cap 8.14 - Person 8.15 - Icons 8.16 - Zoomify 8.17 - Blockquote 8.18 - Testimonials 8.19 - Map Maker 8.20 - Pricing Table 8.21 - Event Agenda 8.22 - Countdown 8.23 - Alerts 8.24 - Progress Bar 8.25 - Full Width ----------------------------------------------------------------------------- */ /* Photo Frame */ -.photo-frame { position: relative; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); border: 4px solid #fff; display: block; } -.photo-frame::before { content: ""; height: 100%; width: 100%; background: #fff; border: 4px solid #fff; position: absolute; z-index: -1; top: -5px; left: -10px; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); border-radius: 3px; -webkit-transform: rotate(-2deg); -ms-transform: rotate(-2deg); transform: rotate(-2deg); box-sizing: border-box; } -.photo-frame::after { content: ""; height: 100%; width: 100%; background: #fff; border: 4px solid #fff; position: absolute; z-index: -1; bottom: -3px; right: -5px; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); border-radius: 3px; -webkit-transform: rotate(3deg); -ms-transform: rotate(3deg); transform: rotate(3deg); box-sizing: border-box; } -.photo-frame img { border-radius: 0; } -.photo-frame p:empty { display: none; } -.photo-frame br { display: none; } -.photo-frame p { margin: 0 auto !important; } +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper, .photo-frame.zoom-picture-container { position: relative; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); border: 4px solid #fff; border-radius: 2px; display: block; } + +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper::before, .photo-frame.zoom-picture-container::before { content: ""; height: 100%; width: 100%; background: #fff; border: 4px solid #fff; position: absolute; z-index: -1; top: -5px; left: -10px; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); border-radius: 2px; -webkit-transform: rotate(-1.5deg) translateX(-0.5%); transform: rotate(-1.5deg) translateX(-0.5%); box-sizing: border-box; } + +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper::after, .photo-frame.zoom-picture-container::after { content: ""; height: 100%; width: 100%; background: #fff; border: 4px solid #fff; position: absolute; z-index: -1; bottom: -3px; right: -5px; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); border-radius: 2px; -webkit-transform: rotate(2.5deg) translateY(0.5%); transform: rotate(2.5deg) translateY(0.5%); box-sizing: border-box; } + +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper img, .photo-frame.zoom-picture-container img { border-radius: 0; } + +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper p:empty, .photo-frame.zoom-picture-container p:empty { display: none; } + +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper br, .photo-frame.zoom-picture-container br { display: none; } + +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper p, .photo-frame.zoom-picture-container p { margin: 0 auto !important; } /** 8.0 - Shortcodes ----------------------------------------------------------------------------- */ /** 8.1 - Accordion ----------------------------------------------------------------------------- */ @@ -20,6 +25,7 @@ .panel .accordion-toggle.collapsed:before { content: '\F055' !important; } .panel-heading h6 { line-height: 3em; } + .panel-heading a { text-decoration: none; } .panel-body { padding-bottom: 1rem; } @@ -67,11 +73,11 @@ .list-bullets li:before { content: '\F111'; } -.list-circle li:before { content: ""; } +.list-circle li:before { content: '\F10C'; } -.list-square li:before { content: ""; } +.list-square li:before { content: '\F0C8'; } -.list-crosslist li:before { content: ""; } +.list-crosslist li:before { content: '\F00D'; } .list-checklist li:before { content: '\F00C'; } @@ -124,7 +130,7 @@ .clients-carousel ul a { padding: 1px; display: block; overflow: hidden; } -.clients-carousel img { -webkit-transition: opacity 160ms ease-in-out; transition: opacity 160ms ease-in-out; -webkit-backface-visibility: hidden; -webkit-transform: rotate(0); -ms-transform: rotate(0); transform: rotate(0); position: relative; opacity: 0.4; filter: alpha(opacity=40); } +.clients-carousel img { -webkit-transition: opacity 160ms ease-in-out; transition: opacity 160ms ease-in-out; -webkit-backface-visibility: hidden; -webkit-transform: rotate(0); transform: rotate(0); position: relative; opacity: 0.4; filter: alpha(opacity=40); } .clients-carousel img:hover { opacity: 1; filter: alpha(opacity=100); } @@ -158,7 +164,9 @@ .clearfix { clear: none !important; } @media (max-width: 992px) { .content-column { float: left; width: 48.387224% !important; } } + @media (max-width: 768px) { .content-column { float: none; width: 100% !important; margin: 2rem 0 !important; } } + /** 8.9 - Dividers ----------------------------------------------------------------------------- */ .divider { clear: both; color: transparent; height: 20px; background-position: center center; margin: 0 0 40px; background-repeat: no-repeat; border-bottom: none; } @@ -290,10 +298,12 @@ .wl-pricing-table.light .highlight-column:first-child, .wl-pricing-table.light .highlight-column:last-child { box-shadow: inset 0px 0px 20px rgba(0, 0, 0, 0.3); } .pricing-row h4 { border-bottom: none; } + .pricing-row h4::after { display: none; } /** 8.21 - Event Agenda ----------------------------------------------------------------------------- */ .event-agenda { line-height: 1.425em; } + .event-agenda .event-agenda-day { margin-top: 4rem; } .event-agenda-event span { font-size: 0.9em; } @@ -354,20 +364,35 @@ /** Recent Posts Widget ----------------------------------------------------------------------------- */ .custom_recent_posts .recent-posts { list-style: none; padding: 0; margin: 0; } + .custom_recent_posts .recent-posts li { padding: 0; margin: 0 0 2rem 0; } + .custom_recent_posts .recent-posts li::before { display: none; } + .custom_recent_posts .recent-posts li h6 { margin-bottom: 0.5em; margin-top: 0; } + .custom_recent_posts .recent-posts.type-thumbnail li { padding: 20px 0 20px 100px; margin: 0 0 1.4rem 0; min-height: 80px; } + .custom_recent_posts .recent-posts.type-thumbnail li:hover .wp-post-image { opacity: 1; } + .custom_recent_posts .recent-posts.type-thumbnail .wp-post-image { max-width: 80px; height: auto; position: absolute; left: 0; top: 20px; -webkit-transition: opacity 200ms; transition: opacity 200ms; opacity: 0; } + .custom_recent_posts .recent-posts.type-thumbnail time { display: block; width: 80px; height: 80px; position: absolute; left: 0; top: 20px; text-align: center; border-radius: 3px; } + .custom_recent_posts .recent-posts.type-thumbnail time span { font-size: 2.5em; display: block; padding-top: 0.25em; line-height: 1.2em; } + .custom_recent_posts .recent-posts.type-thumbnail time em { font-style: normal; } + .custom_recent_posts .recent-posts.type-fullwidth .wp-post-image { max-width: 100%; height: auto; margin-bottom: 1em; } + .custom_recent_posts .recent-posts.type-fullwidth time { display: none; } + .custom_recent_posts .recent-posts .cols-1 { width: 100%; } + .custom_recent_posts .recent-posts .cols-2 { width: 50%; } + .custom_recent_posts .recent-posts .cols-3 { width: 33.3333333%; } + .custom_recent_posts .recent-posts .cols-4 { width: 25%; } @media (max-width: 992px) { .custom_recent_posts .recent-posts .cols-1, .custom_recent_posts .recent-posts .cols-2, .custom_recent_posts .recent-posts .cols-3, .custom_recent_posts .recent-posts .cols-4 { width: 100%; } } diff --git a/css/style.scss b/css/style.scss index d703c41..883822c 100644 --- a/css/style.scss +++ b/css/style.scss @@ -25,8 +25,8 @@ * 8.21 - Event Agenda * 8.22 - Countdown * 8.23 - Alerts - * 8.24 - Progress Bar - * 8.25 - Full Width + * 8.24 - Progress Bar + * 8.25 - Full Width * ----------------------------------------------------------------------------- */ @@ -34,24 +34,26 @@ $screen-xs-max: 768px; $screen-sm-max: 992px; /* Photo Frame */ -.photo-frame{ +.photo-frame:not(.zoom-picture-container) .vc_single_image-wrapper, +.photo-frame.zoom-picture-container{ position: relative; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); border: 4px solid #fff; + border-radius: 2px; display: block; - + &::before{ content: ""; height: 100%; width: 100%; background: #fff; - border: 4px solid #fff; + border: 4px solid #fff; position: absolute; z-index: -1; top: -5px; left: -10px; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); - border-radius: 3px; - transform: rotate(-2deg); + border-radius: 2px; + transform: rotate(-1.5deg) translateX(-0.5%); box-sizing: border-box; } &::after{ @@ -64,8 +66,8 @@ $screen-sm-max: 992px; bottom: -3px; right: -5px; box-shadow: 1px 1px 5px 0px rgba(0, 0, 0, 0.25); - border-radius: 3px; - transform: rotate(3deg); + border-radius: 2px; + transform: rotate(2.5deg) translateY(0.5%); box-sizing: border-box; } img{ @@ -91,7 +93,7 @@ $screen-sm-max: 992px; * 8.1 - Accordion * ----------------------------------------------------------------------------- */ - + .panel{ background: transparent; margin: 0 !important; @@ -129,7 +131,7 @@ $screen-sm-max: 992px; * 8.2 - Slider * ----------------------------------------------------------------------------- */ - + .carousel{ margin-bottom: 20px; } @@ -151,7 +153,7 @@ $screen-sm-max: 992px; * 8.3 - Action Boxes * ----------------------------------------------------------------------------- */ - + .action-box{ padding: 20px; margin: 0 0 20px 0; @@ -163,7 +165,7 @@ $screen-sm-max: 992px; margin-top: 0; margin-bottom: 10px; line-height: 1em; -} +} .action-box .btn:first-child{ float: right; } @@ -202,11 +204,11 @@ $screen-sm-max: 992px; * 8.4 - Lists * ----------------------------------------------------------------------------- */ - + .list-none ul{ list-style: none; padding: 0 !important; -} +} .list-none li{ margin-bottom: 0.5em; } @@ -246,7 +248,7 @@ $screen-sm-max: 992px; * 8.5 - Buttons * ----------------------------------------------------------------------------- */ - + .btn, input[type="button"], input[type="submit"]{ @@ -274,7 +276,7 @@ input[type="submit"]{ * 8.6 - Toggle Box * ----------------------------------------------------------------------------- */ - + .toggle-box h6{ cursor: pointer; line-height: 1.425em; @@ -287,7 +289,7 @@ input[type="submit"]{ * 8.7 - Clients Slider * ----------------------------------------------------------------------------- */ - + .clients-carousel-container{ position: relative; margin-bottom: 30px; @@ -329,11 +331,11 @@ input[type="submit"]{ -moz-transform: rotate(0); transform: rotate(0); position: relative; - opacity: 0.4; + opacity: 0.4; filter:alpha(opacity=40); } .clients-carousel img:hover{ - opacity: 1; + opacity: 1; filter:alpha(opacity=100); } .clients-carousel .next:after, @@ -370,7 +372,7 @@ input[type="submit"]{ * 8.8 - Columns * ----------------------------------------------------------------------------- */ - + .content-column { float:left; margin-right:3.22555%; margin-bottom: 40px } .content-column.half { width: 48.387224% } .content-column.one-three { width: 31.182966% } @@ -399,22 +401,22 @@ input[type="submit"]{ * 8.9 - Dividers * ----------------------------------------------------------------------------- */ - -.divider{ - clear:both; - color: transparent; - height: 20px; - background-position: center center; - margin: 0 0 40px; - background-repeat: no-repeat; - border-bottom: none; + +.divider{ + clear:both; + color: transparent; + height: 20px; + background-position: center center; + margin: 0 0 40px; + background-repeat: no-repeat; + border-bottom: none; } /** * 8.10 - Boxes * ----------------------------------------------------------------------------- */ - + .well{ padding: 35px; border: none; @@ -474,7 +476,7 @@ input[type="submit"]{ * 8.11 - Tabs * ----------------------------------------------------------------------------- */ - + .tabs-container{ margin-bottom: 20px; } @@ -484,8 +486,8 @@ input[type="submit"]{ .nav-tabs a{ border: none !important; } -.nav-tabs .active>a, -.nav-tabs .active>a:hover, +.nav-tabs .active>a, +.nav-tabs .active>a:hover, .nav-tabs .active>a:focus{ background-color: transparent; } @@ -501,7 +503,7 @@ input[type="submit"]{ * 8.12 - Marker * ----------------------------------------------------------------------------- */ - + .label{ font-size: small; } @@ -510,7 +512,7 @@ input[type="submit"]{ * 8.13 - Dropcap * ----------------------------------------------------------------------------- */ - + .dropcap{ font-size: 40px; float: left; @@ -530,7 +532,7 @@ input[type="submit"]{ padding-left: 110px; position: relative; margin: 2.8rem 0; -} +} .person.mini img{ position: absolute; left: 0; @@ -565,7 +567,7 @@ input[type="submit"]{ * 8.16 - Zoomify * ----------------------------------------------------------------------------- */ - + .zoom-picture:after, .zoom-picture-container .vc_single_image-wrapper:after{ content: '\F002'; @@ -588,7 +590,7 @@ input[type="submit"]{ * 8.18 - Testimonials * ----------------------------------------------------------------------------- */ - + .testimonials{ margin-bottom: 20px; } @@ -641,7 +643,7 @@ input[type="submit"]{ * 8.19 - Map Maker * ----------------------------------------------------------------------------- */ - + .map-container{ position: relative; z-index: 1; @@ -662,8 +664,8 @@ input[type="submit"]{ */ .wl-pricing-table { - text-align:center; - margin-bottom: 60px; + text-align:center; + margin-bottom: 60px; overflow: hidden; } .wl-pricing-table .pricing-footer a{ @@ -699,7 +701,7 @@ input[type="submit"]{ margin: 0; padding: 0; line-height: 1em; -} +} .wl-pricing-table h4 *{ position: relative; font-weight: bold; @@ -773,7 +775,7 @@ input[type="submit"]{ } .pricing-row h4{ border-bottom: none; - + &::after{ display: none; } @@ -783,10 +785,10 @@ input[type="submit"]{ * 8.21 - Event Agenda * ----------------------------------------------------------------------------- */ - + .event-agenda{ line-height: 1.425em; - + .event-agenda-day{ margin-top: 4rem; } @@ -822,7 +824,7 @@ input[type="submit"]{ * 8.22 - Countdown * ----------------------------------------------------------------------------- */ - + .curly-counter{ margin-bottom: 20px; } @@ -855,7 +857,7 @@ input[type="submit"]{ * 8.23 - Alerts * ----------------------------------------------------------------------------- */ - + .alert .fa{ background: transparent; border: none; @@ -868,43 +870,43 @@ input[type="submit"]{ .alert h2, .alert h3, .alert h4, -.alert h5, +.alert h5, .alert h6{ margin-bottom: 0; margin-top: 10px; } -.alert.alert-warning h1, -.alert.alert-warning h2, -.alert.alert-warning h3, -.alert.alert-warning h4, -.alert.alert-warning h5, +.alert.alert-warning h1, +.alert.alert-warning h2, +.alert.alert-warning h3, +.alert.alert-warning h4, +.alert.alert-warning h5, .alert.alert-warning h6, .alert.alert-warning .fa::before{ color: #C09853; } -.alert.alert-success h1, -.alert.alert-success h2, -.alert.alert-success h3, -.alert.alert-success h4, -.alert.alert-success h5, +.alert.alert-success h1, +.alert.alert-success h2, +.alert.alert-success h3, +.alert.alert-success h4, +.alert.alert-success h5, .alert.alert-success h6, .alert.alert-success .fa::before{ color: #468847; } -.alert.alert-info h1, -.alert.alert-info h2, -.alert.alert-info h3, -.alert.alert-info h4, -.alert.alert-info h5, +.alert.alert-info h1, +.alert.alert-info h2, +.alert.alert-info h3, +.alert.alert-info h4, +.alert.alert-info h5, .alert.alert-info h6, .alert.alert-info .fa::before{ color: #3A87AD; } -.alert.alert-danger h1, -.alert.alert-danger h2, -.alert.alert-danger h3, -.alert.alert-danger h4, -.alert.alert-danger h5, +.alert.alert-danger h1, +.alert.alert-danger h2, +.alert.alert-danger h3, +.alert.alert-danger h4, +.alert.alert-danger h5, .alert.alert-danger h6, .alert.alert-danger .fa::before{ color: #B94A48; @@ -914,15 +916,15 @@ input[type="submit"]{ * 8.25 - FullWidth * ----------------------------------------------------------------------------- */ - + .fullwidth-row .col-lg-12 *:last-child{ margin-bottom: 0; } - + /** * 8.26 - Progress * ----------------------------------------------------------------------------- - */ + */ .progress{ box-shadow: none; @@ -934,23 +936,23 @@ input[type="submit"]{ box-shadow: none; line-height: inherit; height: inherit; -} +} /** * Recent Posts Widget * ----------------------------------------------------------------------------- - */ + */ .custom_recent_posts{ .recent-posts{ list-style: none; padding: 0; margin: 0; - + li{ padding: 0; margin: 0 0 2rem 0; - + &::before{ display: none; } @@ -964,7 +966,7 @@ input[type="submit"]{ padding: 20px 0 20px 100px; margin: 0 0 1.4rem 0; min-height: 80px; - + &:hover{ .wp-post-image{ opacity: 1; @@ -989,7 +991,7 @@ input[type="submit"]{ top: 20px; text-align: center; border-radius: 3px; - + span{ font-size: 2.5em; display: block; @@ -1022,7 +1024,7 @@ input[type="submit"]{ } .cols-4{ width: 25%; - } + } } } @media (max-width: $screen-sm-max) { @@ -1036,4 +1038,4 @@ input[type="submit"]{ } } } -} \ No newline at end of file +} diff --git a/curly-extension.php b/curly-extension.php index e68aac7..7d27c0a 100644 --- a/curly-extension.php +++ b/curly-extension.php @@ -3,110 +3,113 @@ Plugin Name: Curly Themes Extension Plugin URI: http://demo.curlythemes.com Description: Curly Themes Extension is a collection of Shortcodes, Widgets and Plugins. This plugin exclusive for Curly Themes -Version: 2.3 +Version: 2.4 Author: Curly Themes Author URI: http://www.curlythemes.com */ class CurlyThemesExtension { - + public function __construct( $prefix = null ) { - + if ( ! defined( 'THEMEPREFIX' ) ) { define( 'THEMEPREFIX' , $prefix ); } - + add_action('init', array($this, 'add_button')); add_filter('the_content', array($this, 'shortcode_sanitizer')); add_filter('widget_text', array($this, 'shortcode_sanitizer')); add_filter('vc_inner_shortcode', array($this, 'shortcode_sanitizer')); - + add_action('wp_enqueue_scripts', array($this, 'load_shortcodes_scripts')); - + // Plugins add_action('after_setup_theme', array($this, 'activate_plugins')); - + // Include Shortcodes self::includes(); - + // Include Widgets self::widgets(); } + /* Frontend Scripts - ================================================= */ + ================================================= */ function load_shortcodes_scripts() { if ( !is_admin() ) { - - // Register Scripts + + // Register Scripts wp_register_script('curly-carousel', plugins_url( '/js/jquery.carouFredSel-6.2.1-packed.js' , __FILE__ ), null, null, true); wp_register_script('curly-fitvid', plugins_url( '/js/jquery.fitvids.js' , __FILE__ ), null, null, true); wp_register_script('curly-picture-zoom', plugins_url( '/js/jquery.zoom-min.js' , __FILE__ ), null , null, true); - wp_register_script('curly-roundabout', plugins_url( '/js/jquery.roundabout.min.js', __FILE__ ), null, null, true); + wp_register_script('curly-roundabout', plugins_url( '/js/jquery.roundabout.min.js', __FILE__ ), null, null, true); wp_register_script('curly-easing', plugins_url( '/js/jquery.easing.1.3.js', __FILE__ ), null, null, true); - wp_register_script('curly-drag', plugins_url( '/js/jquery.event.drag-2.2.js', __FILE__ ), null, null, true); - wp_register_script('curly-drop', plugins_url( '/js/jquery.event.drop-2.2.js', __FILE__ ), null, null, true); + wp_register_script('curly-drag', plugins_url( '/js/jquery.event.drag-2.2.js', __FILE__ ), null, null, true); + wp_register_script('curly-drop', plugins_url( '/js/jquery.event.drop-2.2.js', __FILE__ ), null, null, true); wp_register_script('curly-ios', plugins_url( '/js/jquery.iosslider.min.js', __FILE__ ), null, true); wp_register_script('curly-countdown', plugins_url( '/js/jquery.countdown.min.js' , __FILE__ ), null, null, true); - + // Register Styles wp_register_style('curly-ios-css', plugins_url( '/css/slider-ios.css', __FILE__ ), null, null, 'all'); - wp_register_style('curly-lightbox-css', plugins_url('/css/lightbox.css', __FILE__ ), null, null, 'all'); - + wp_register_style('curly-lightbox-css', plugins_url('/css/magnific-popup.css', __FILE__ ), null, '2.0', 'all'); + + wp_enqueue_script('curly-lightbox', plugins_url( '/js/jquery.magnific-popup.min.js', __FILE__ ), 'jquery', '2.0', true); + // Enqueue Scripts - wp_enqueue_script( - 'curly-shortcodes', - plugins_url( '/js/main.js' , __FILE__ ), - array( 'jquery', 'curly-main' ), - null, + wp_enqueue_script( + 'curly-shortcodes', + plugins_url( '/js/main.js' , __FILE__ ), + array( 'jquery', 'curly-main' ), + null, true ); - wp_enqueue_script('curly-lightbox', plugins_url( '/js/lightbox-2.6.min.js', __FILE__ ), 'jquery', null, true); - + + // Enqueue Styles wp_enqueue_style('curly-shortcodes', plugins_url( '/css/style.css' , __FILE__ ), array('curly-style') , null); wp_enqueue_style('curly-lightbox-css'); - + // Dynamic CSS - $output - include('css/render.css.php'); - - /// Minify CSS + include('css/render.css.php'); + + /// Minify CSS wp_add_inline_style( 'curly-shortcodes', apply_filters( 'curly_minify_css', htmlspecialchars_decode( $curly_css_output ) ) ); - } + } } - + /* Shortcodes ================================================= */ function includes() { include ( 'shortcodes/columns.php' ); - include ( 'shortcodes/dividers.php' ); + include ( 'shortcodes/dividers.php' ); include ( 'shortcodes/buttons.php' ); include ( 'shortcodes/alert.php' ); include ( 'shortcodes/quotes.php' ); - include ( 'shortcodes/lists.php' ); - include ( 'shortcodes/abbr.php' ); + include ( 'shortcodes/lists.php' ); + include ( 'shortcodes/abbr.php' ); include ( 'shortcodes/dropcap.php' ); - include ( 'shortcodes/highlight.php' ); + include ( 'shortcodes/highlight.php' ); include ( 'shortcodes/action.php' ); - include ( 'shortcodes/tabs.php' ); - include ( 'shortcodes/toggle-box.php' ); - include ( 'shortcodes/accordion.php' ); - include ( 'shortcodes/youtube.php' ); - include ( 'shortcodes/vimeo.php' ); - include ( 'shortcodes/boxes.php' ); - include ( 'shortcodes/marker.php' ); - include ( 'shortcodes/testimonials.php' ); - include ( 'shortcodes/slider.php' ); + include ( 'shortcodes/tabs.php' ); + include ( 'shortcodes/toggle-box.php' ); + include ( 'shortcodes/accordion.php' ); + include ( 'shortcodes/youtube.php' ); + include ( 'shortcodes/vimeo.php' ); + include ( 'shortcodes/boxes.php' ); + include ( 'shortcodes/marker.php' ); + include ( 'shortcodes/testimonials.php' ); + include ( 'shortcodes/slider.php' ); include ( 'shortcodes/person.php' ); - include ( 'shortcodes/clear.php' ); - include ( 'shortcodes/progress.php' ); - include ( 'shortcodes/icon.php' ); - include ( 'shortcodes/client-list.php' ); - include ( 'shortcodes/pretty-photo.php' ); - include ( 'shortcodes/agenda.php' ); - include ( 'shortcodes/pricing.php' ); - include ( 'shortcodes/map-maker.php' ); + include ( 'shortcodes/clear.php' ); + include ( 'shortcodes/progress.php' ); + include ( 'shortcodes/icon.php' ); + include ( 'shortcodes/client-list.php' ); + include ( 'shortcodes/pretty-photo.php' ); + include ( 'shortcodes/agenda.php' ); + include ( 'shortcodes/pricing.php' ); + include ( 'shortcodes/map-maker.php' ); include ( 'shortcodes/picture-zoom.php' ); include ( 'shortcodes/fullwidth.php' ); include ( 'shortcodes/slider-ios.php' ); @@ -114,48 +117,48 @@ function includes() { include ( 'shortcodes/photo-frame.php' ); include ( 'shortcodes/countdown.php' ); } - + function widgets() { // Widgets include ('widgets/recent.php' ); include ('widgets/search.php' ); } - + /* Add Shortcodes Buttons to TinyMCE ================================================= */ - function add_button() { - if ( current_user_can('edit_posts') && current_user_can('edit_pages') ) - { - add_filter('mce_external_plugins', array($this, 'add_plugin')); - add_filter('mce_buttons', array($this, 'register_button')); - } + function add_button() { + if ( current_user_can('edit_posts') && current_user_can('edit_pages') ) + { + add_filter('mce_external_plugins', array($this, 'add_plugin')); + add_filter('mce_buttons', array($this, 'register_button')); + } } - - function register_button($buttons) { - array_push($buttons, "curly"); - return $buttons; - } - - function add_plugin($plugin_array) { + + function register_button($buttons) { + array_push($buttons, "curly"); + return $buttons; + } + + function add_plugin($plugin_array) { $plugin_array['curly'] = plugins_url('/shortcodes/tinymce/buttons.js', __FILE__ ); - return $plugin_array; + return $plugin_array; } - + /* Shortcode Sanitizer ================================================= */ function shortcode_sanitizer( $content ) { /* $needle = join("|",array("column", '\/column', "list", "\/list", "tabs", "\/tabs", "tab", "\/tab", "toggle", "\/toggle", "accordion", "\/accordion", "testimonials", "\/testimonials", "testimonial", "\/testimonial", "clear", "divider", "button", "\/button", "blockquote", "\/blockquote", "highlight", "\/highlight", "call2action", "\/call2action", "toggle-box", "\/toggle-box", "slider", "slide", "youtube", "vimeo", "progress", "icon", "clients", "\/clients", "client", "\/client", "pretty-photo", "agenda", "\/agenda", "event-day", "\/event-day", "event", "\/event", "pricing-table", "\/pricing-table", "pricing-column", "\/pricing-column", "pricing-header", "\/pricing-header", "pricing-row", "\/pricing-row", "pricing-footer", "\/pricing-footer", "map-maker", "\/map-maker", "picture-zoom", "full-width-box", '\/full-width-box', "box", "\/box", "alert", "\/alert", "ios-slider", "ios-slide", "roundabout-slider", "roundabout-slide", "person", "\/person", "photo-frame", "\/photo-frame", "gallery", "countdown", "location", "simple-weather", "simple-text-rotator", "\/simple-text-rotator", "simple-qr")); - + $html = preg_replace("/(

)?\[($needle)(\s[^\]]+)?\](<\/p>|
)?/","[$2$3]",$content); $html = preg_replace("/(

)?\[\/($needle)](<\/p>|
)/","[/$2]",$html); - + return $html; - + */ - + $array = array( '

[' => '[', ']

' => ']', @@ -163,41 +166,41 @@ function shortcode_sanitizer( $content ) { '] ' => ']', ' [' => '[' ); - + return strtr( $content, $array ); - + } - + function activate_plugins() { - + include_once( ABSPATH . 'wp-admin/includes/plugin.php' ); - + if ( ! is_plugin_active( 'simple-text-rotator/simple-text-rotator.php' ) ) { include_once ('plugins/simple-text-rotator/simple-text-rotator.php' ); } - + if ( ! is_plugin_active( 'simple-qr/simple-qr.php' ) ) { include_once ('plugins/simple-qr/simple-qr.php' ); } } - + } - + class CurlyThemesShortcodeBuilder { - + public function __construct( $prefix = null ) { - + if ( !defined( 'THEMEPREFIX' ) ) { define( 'THEMEPREFIX' , $prefix ); } - + add_action('admin_footer', array($this, 'shortcode_builder')); add_action('admin_enqueue_scripts', array($this, 'load_shortcodes_admin_scripts')); - + } - + function shortcode_builder() { - + $html = ''; - + echo $html; } function load_shortcodes_admin_scripts() { - + wp_enqueue_style('curly-wp-editor', plugins_url( '/css/wp-editor.css' , __FILE__ ), null, null); wp_enqueue_script('curly-shortcode-builder', plugins_url( '/js/builder.js' , __FILE__ ), null, null); - + // Get Current Color Scheme - global $_wp_admin_css_colors; + global $_wp_admin_css_colors; $admin_colors = $_wp_admin_css_colors; $color_scheme = $admin_colors[get_user_option('admin_color')]->colors; - + $color_scheme = ' #curly_shortcodes a:hover{ background: '.$color_scheme[3].' } '; - + wp_add_inline_style('curly-wp-editor', $color_scheme); } } @@ -273,4 +276,4 @@ function load_shortcodes_admin_scripts() { require_once( 'class.vc.php' ); -?> \ No newline at end of file +?> diff --git a/js/jquery.magnific-popup.min.js b/js/jquery.magnific-popup.min.js new file mode 100755 index 0000000..6ee3a3b --- /dev/null +++ b/js/jquery.magnific-popup.min.js @@ -0,0 +1,4 @@ +/*! Magnific Popup - v1.1.0 - 2016-02-20 +* http://dimsemenov.com/plugins/magnific-popup/ +* Copyright (c) 2016 Dmitry Semenov; */ +!function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a("object"==typeof exports?require("jquery"):window.jQuery||window.Zepto)}(function(a){var b,c,d,e,f,g,h="Close",i="BeforeClose",j="AfterClose",k="BeforeAppend",l="MarkupParse",m="Open",n="Change",o="mfp",p="."+o,q="mfp-ready",r="mfp-removing",s="mfp-prevent-close",t=function(){},u=!!window.jQuery,v=a(window),w=function(a,c){b.ev.on(o+a+p,c)},x=function(b,c,d,e){var f=document.createElement("div");return f.className="mfp-"+b,d&&(f.innerHTML=d),e?c&&c.appendChild(f):(f=a(f),c&&f.appendTo(c)),f},y=function(c,d){b.ev.triggerHandler(o+c,d),b.st.callbacks&&(c=c.charAt(0).toLowerCase()+c.slice(1),b.st.callbacks[c]&&b.st.callbacks[c].apply(b,a.isArray(d)?d:[d]))},z=function(c){return c===g&&b.currTemplate.closeBtn||(b.currTemplate.closeBtn=a(b.st.closeMarkup.replace("%title%",b.st.tClose)),g=c),b.currTemplate.closeBtn},A=function(){a.magnificPopup.instance||(b=new t,b.init(),a.magnificPopup.instance=b)},B=function(){var a=document.createElement("p").style,b=["ms","O","Moz","Webkit"];if(void 0!==a.transition)return!0;for(;b.length;)if(b.pop()+"Transition"in a)return!0;return!1};t.prototype={constructor:t,init:function(){var c=navigator.appVersion;b.isLowIE=b.isIE8=document.all&&!document.addEventListener,b.isAndroid=/android/gi.test(c),b.isIOS=/iphone|ipad|ipod/gi.test(c),b.supportsTransition=B(),b.probablyMobile=b.isAndroid||b.isIOS||/(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent),d=a(document),b.popupsCache={}},open:function(c){var e;if(c.isObj===!1){b.items=c.items.toArray(),b.index=0;var g,h=c.items;for(e=0;e(a||v.height())},_setFocus:function(){(b.st.focus?b.content.find(b.st.focus).eq(0):b.wrap).focus()},_onFocusIn:function(c){return c.target===b.wrap[0]||a.contains(b.wrap[0],c.target)?void 0:(b._setFocus(),!1)},_parseMarkup:function(b,c,d){var e;d.data&&(c=a.extend(d.data,c)),y(l,[b,c,d]),a.each(c,function(c,d){if(void 0===d||d===!1)return!0;if(e=c.split("_"),e.length>1){var f=b.find(p+"-"+e[0]);if(f.length>0){var g=e[1];"replaceWith"===g?f[0]!==d[0]&&f.replaceWith(d):"img"===g?f.is("img")?f.attr("src",d):f.replaceWith(a("").attr("src",d).attr("class",f.attr("class"))):f.attr(e[1],d)}}else b.find(p+"-"+c).html(d)})},_getScrollbarSize:function(){if(void 0===b.scrollbarSize){var a=document.createElement("div");a.style.cssText="width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;",document.body.appendChild(a),b.scrollbarSize=a.offsetWidth-a.clientWidth,document.body.removeChild(a)}return b.scrollbarSize}},a.magnificPopup={instance:null,proto:t.prototype,modules:[],open:function(b,c){return A(),b=b?a.extend(!0,{},b):{},b.isObj=!0,b.index=c||0,this.instance.open(b)},close:function(){return a.magnificPopup.instance&&a.magnificPopup.instance.close()},registerModule:function(b,c){c.options&&(a.magnificPopup.defaults[b]=c.options),a.extend(this.proto,c.proto),this.modules.push(b)},defaults:{disableOn:0,key:null,midClick:!1,mainClass:"",preloader:!0,focus:"",closeOnContentClick:!1,closeOnBgClick:!0,closeBtnInside:!0,showCloseBtn:!0,enableEscapeKey:!0,modal:!1,alignTop:!1,removalDelay:0,prependTo:null,fixedContentPos:"auto",fixedBgPos:"auto",overflowY:"auto",closeMarkup:'',tClose:"Close (Esc)",tLoading:"Loading...",autoFocusLast:!0}},a.fn.magnificPopup=function(c){A();var d=a(this);if("string"==typeof c)if("open"===c){var e,f=u?d.data("magnificPopup"):d[0].magnificPopup,g=parseInt(arguments[1],10)||0;f.items?e=f.items[g]:(e=d,f.delegate&&(e=e.find(f.delegate)),e=e.eq(g)),b._openClick({mfpEl:e},d,f)}else b.isOpen&&b[c].apply(b,Array.prototype.slice.call(arguments,1));else c=a.extend(!0,{},c),u?d.data("magnificPopup",c):d[0].magnificPopup=c,b.addGroup(d,c);return d};var C,D,E,F="inline",G=function(){E&&(D.after(E.addClass(C)).detach(),E=null)};a.magnificPopup.registerModule(F,{options:{hiddenClass:"hide",markup:"",tNotFound:"Content not found"},proto:{initInline:function(){b.types.push(F),w(h+"."+F,function(){G()})},getInline:function(c,d){if(G(),c.src){var e=b.st.inline,f=a(c.src);if(f.length){var g=f[0].parentNode;g&&g.tagName&&(D||(C=e.hiddenClass,D=x(C),C="mfp-"+C),E=f.after(D).detach().removeClass(C)),b.updateStatus("ready")}else b.updateStatus("error",e.tNotFound),f=a("
");return c.inlineElement=f,f}return b.updateStatus("ready"),b._parseMarkup(d,{},c),d}}});var H,I="ajax",J=function(){H&&a(document.body).removeClass(H)},K=function(){J(),b.req&&b.req.abort()};a.magnificPopup.registerModule(I,{options:{settings:null,cursor:"mfp-ajax-cur",tError:'The content could not be loaded.'},proto:{initAjax:function(){b.types.push(I),H=b.st.ajax.cursor,w(h+"."+I,K),w("BeforeChange."+I,K)},getAjax:function(c){H&&a(document.body).addClass(H),b.updateStatus("loading");var d=a.extend({url:c.src,success:function(d,e,f){var g={data:d,xhr:f};y("ParseAjax",g),b.appendContent(a(g.data),I),c.finished=!0,J(),b._setFocus(),setTimeout(function(){b.wrap.addClass(q)},16),b.updateStatus("ready"),y("AjaxContentAdded")},error:function(){J(),c.finished=c.loadError=!0,b.updateStatus("error",b.st.ajax.tError.replace("%url%",c.src))}},b.st.ajax.settings);return b.req=a.ajax(d),""}}});var L,M=function(c){if(c.data&&void 0!==c.data.title)return c.data.title;var d=b.st.image.titleSrc;if(d){if(a.isFunction(d))return d.call(b,c);if(c.el)return c.el.attr(d)||""}return""};a.magnificPopup.registerModule("image",{options:{markup:'
',cursor:"mfp-zoom-out-cur",titleSrc:"title",verticalFit:!0,tError:'The image could not be loaded.'},proto:{initImage:function(){var c=b.st.image,d=".image";b.types.push("image"),w(m+d,function(){"image"===b.currItem.type&&c.cursor&&a(document.body).addClass(c.cursor)}),w(h+d,function(){c.cursor&&a(document.body).removeClass(c.cursor),v.off("resize"+p)}),w("Resize"+d,b.resizeImage),b.isLowIE&&w("AfterChange",b.resizeImage)},resizeImage:function(){var a=b.currItem;if(a&&a.img&&b.st.image.verticalFit){var c=0;b.isLowIE&&(c=parseInt(a.img.css("padding-top"),10)+parseInt(a.img.css("padding-bottom"),10)),a.img.css("max-height",b.wH-c)}},_onImageHasSize:function(a){a.img&&(a.hasSize=!0,L&&clearInterval(L),a.isCheckingImgSize=!1,y("ImageHasSize",a),a.imgHidden&&(b.content&&b.content.removeClass("mfp-loading"),a.imgHidden=!1))},findImageSize:function(a){var c=0,d=a.img[0],e=function(f){L&&clearInterval(L),L=setInterval(function(){return d.naturalWidth>0?void b._onImageHasSize(a):(c>200&&clearInterval(L),c++,void(3===c?e(10):40===c?e(50):100===c&&e(500)))},f)};e(1)},getImage:function(c,d){var e=0,f=function(){c&&(c.img[0].complete?(c.img.off(".mfploader"),c===b.currItem&&(b._onImageHasSize(c),b.updateStatus("ready")),c.hasSize=!0,c.loaded=!0,y("ImageLoadComplete")):(e++,200>e?setTimeout(f,100):g()))},g=function(){c&&(c.img.off(".mfploader"),c===b.currItem&&(b._onImageHasSize(c),b.updateStatus("error",h.tError.replace("%url%",c.src))),c.hasSize=!0,c.loaded=!0,c.loadError=!0)},h=b.st.image,i=d.find(".mfp-img");if(i.length){var j=document.createElement("img");j.className="mfp-img",c.el&&c.el.find("img").length&&(j.alt=c.el.find("img").attr("alt")),c.img=a(j).on("load.mfploader",f).on("error.mfploader",g),j.src=c.src,i.is("img")&&(c.img=c.img.clone()),j=c.img[0],j.naturalWidth>0?c.hasSize=!0:j.width||(c.hasSize=!1)}return b._parseMarkup(d,{title:M(c),img_replaceWith:c.img},c),b.resizeImage(),c.hasSize?(L&&clearInterval(L),c.loadError?(d.addClass("mfp-loading"),b.updateStatus("error",h.tError.replace("%url%",c.src))):(d.removeClass("mfp-loading"),b.updateStatus("ready")),d):(b.updateStatus("loading"),c.loading=!0,c.hasSize||(c.imgHidden=!0,d.addClass("mfp-loading"),b.findImageSize(c)),d)}}});var N,O=function(){return void 0===N&&(N=void 0!==document.createElement("p").style.MozTransform),N};a.magnificPopup.registerModule("zoom",{options:{enabled:!1,easing:"ease-in-out",duration:300,opener:function(a){return a.is("img")?a:a.find("img")}},proto:{initZoom:function(){var a,c=b.st.zoom,d=".zoom";if(c.enabled&&b.supportsTransition){var e,f,g=c.duration,j=function(a){var b=a.clone().removeAttr("style").removeAttr("class").addClass("mfp-animated-image"),d="all "+c.duration/1e3+"s "+c.easing,e={position:"fixed",zIndex:9999,left:0,top:0,"-webkit-backface-visibility":"hidden"},f="transition";return e["-webkit-"+f]=e["-moz-"+f]=e["-o-"+f]=e[f]=d,b.css(e),b},k=function(){b.content.css("visibility","visible")};w("BuildControls"+d,function(){if(b._allowZoom()){if(clearTimeout(e),b.content.css("visibility","hidden"),a=b._getItemToZoom(),!a)return void k();f=j(a),f.css(b._getOffset()),b.wrap.append(f),e=setTimeout(function(){f.css(b._getOffset(!0)),e=setTimeout(function(){k(),setTimeout(function(){f.remove(),a=f=null,y("ZoomAnimationEnded")},16)},g)},16)}}),w(i+d,function(){if(b._allowZoom()){if(clearTimeout(e),b.st.removalDelay=g,!a){if(a=b._getItemToZoom(),!a)return;f=j(a)}f.css(b._getOffset(!0)),b.wrap.append(f),b.content.css("visibility","hidden"),setTimeout(function(){f.css(b._getOffset())},16)}}),w(h+d,function(){b._allowZoom()&&(k(),f&&f.remove(),a=null)})}},_allowZoom:function(){return"image"===b.currItem.type},_getItemToZoom:function(){return b.currItem.hasSize?b.currItem.img:!1},_getOffset:function(c){var d;d=c?b.currItem.img:b.st.zoom.opener(b.currItem.el||b.currItem);var e=d.offset(),f=parseInt(d.css("padding-top"),10),g=parseInt(d.css("padding-bottom"),10);e.top-=a(window).scrollTop()-f;var h={width:d.width(),height:(u?d.innerHeight():d[0].offsetHeight)-g-f};return O()?h["-moz-transform"]=h.transform="translate("+e.left+"px,"+e.top+"px)":(h.left=e.left,h.top=e.top),h}}});var P="iframe",Q="//about:blank",R=function(a){if(b.currTemplate[P]){var c=b.currTemplate[P].find("iframe");c.length&&(a||(c[0].src=Q),b.isIE8&&c.css("display",a?"block":"none"))}};a.magnificPopup.registerModule(P,{options:{markup:'
',srcAction:"iframe_src",patterns:{youtube:{index:"youtube.com",id:"v=",src:"//www.youtube.com/embed/%id%?autoplay=1"},vimeo:{index:"vimeo.com/",id:"/",src:"//player.vimeo.com/video/%id%?autoplay=1"},gmaps:{index:"//maps.google.",src:"%id%&output=embed"}}},proto:{initIframe:function(){b.types.push(P),w("BeforeChange",function(a,b,c){b!==c&&(b===P?R():c===P&&R(!0))}),w(h+"."+P,function(){R()})},getIframe:function(c,d){var e=c.src,f=b.st.iframe;a.each(f.patterns,function(){return e.indexOf(this.index)>-1?(this.id&&(e="string"==typeof this.id?e.substr(e.lastIndexOf(this.id)+this.id.length,e.length):this.id.call(this,e)),e=this.src.replace("%id%",e),!1):void 0});var g={};return f.srcAction&&(g[f.srcAction]=e),b._parseMarkup(d,g,c),b.updateStatus("ready"),d}}});var S=function(a){var c=b.items.length;return a>c-1?a-c:0>a?c+a:a},T=function(a,b,c){return a.replace(/%curr%/gi,b+1).replace(/%total%/gi,c)};a.magnificPopup.registerModule("gallery",{options:{enabled:!1,arrowMarkup:'',preload:[0,2],navigateByImgClick:!0,arrows:!0,tPrev:"Previous (Left arrow key)",tNext:"Next (Right arrow key)",tCounter:"%curr% of %total%"},proto:{initGallery:function(){var c=b.st.gallery,e=".mfp-gallery";return b.direction=!0,c&&c.enabled?(f+=" mfp-gallery",w(m+e,function(){c.navigateByImgClick&&b.wrap.on("click"+e,".mfp-img",function(){return b.items.length>1?(b.next(),!1):void 0}),d.on("keydown"+e,function(a){37===a.keyCode?b.prev():39===a.keyCode&&b.next()})}),w("UpdateStatus"+e,function(a,c){c.text&&(c.text=T(c.text,b.currItem.index,b.items.length))}),w(l+e,function(a,d,e,f){var g=b.items.length;e.counter=g>1?T(c.tCounter,f.index,g):""}),w("BuildControls"+e,function(){if(b.items.length>1&&c.arrows&&!b.arrowLeft){var d=c.arrowMarkup,e=b.arrowLeft=a(d.replace(/%title%/gi,c.tPrev).replace(/%dir%/gi,"left")).addClass(s),f=b.arrowRight=a(d.replace(/%title%/gi,c.tNext).replace(/%dir%/gi,"right")).addClass(s);e.click(function(){b.prev()}),f.click(function(){b.next()}),b.container.append(e.add(f))}}),w(n+e,function(){b._preloadTimeout&&clearTimeout(b._preloadTimeout),b._preloadTimeout=setTimeout(function(){b.preloadNearbyImages(),b._preloadTimeout=null},16)}),void w(h+e,function(){d.off(e),b.wrap.off("click"+e),b.arrowRight=b.arrowLeft=null})):!1},next:function(){b.direction=!0,b.index=S(b.index+1),b.updateItemHTML()},prev:function(){b.direction=!1,b.index=S(b.index-1),b.updateItemHTML()},goTo:function(a){b.direction=a>=b.index,b.index=a,b.updateItemHTML()},preloadNearbyImages:function(){var a,c=b.st.gallery.preload,d=Math.min(c[0],b.items.length),e=Math.min(c[1],b.items.length);for(a=1;a<=(b.direction?e:d);a++)b._preloadItem(b.index+a);for(a=1;a<=(b.direction?d:e);a++)b._preloadItem(b.index-a)},_preloadItem:function(c){if(c=S(c),!b.items[c].preloaded){var d=b.items[c];d.parsed||(d=b.parseEl(c)),y("LazyLoad",d),"image"===d.type&&(d.img=a('').on("load.mfploader",function(){d.hasSize=!0}).on("error.mfploader",function(){d.hasSize=!0,d.loadError=!0,y("LazyLoadError",d)}).attr("src",d.src)),d.preloaded=!0}}}});var U="retina";a.magnificPopup.registerModule(U,{options:{replaceSrc:function(a){return a.src.replace(/\.\w+$/,function(a){return"@2x"+a})},ratio:1},proto:{initRetina:function(){if(window.devicePixelRatio>1){var a=b.st.retina,c=a.ratio;c=isNaN(c)?c():c,c>1&&(w("ImageHasSize."+U,function(a,b){b.img.css({"max-width":b.img[0].naturalWidth/c,width:"100%"})}),w("ElementParse."+U,function(b,d){d.src=a.replaceSrc(d,c)}))}}}}),A()}); \ No newline at end of file diff --git a/js/main.js b/js/main.js index d287a71..331a668 100644 --- a/js/main.js +++ b/js/main.js @@ -1,10 +1,10 @@ jQuery(document).ready(function(){ "use strict"; - + if ( jQuery('.video-container').length > 0 ) { jQuery(".video-container").fitVids(); } - + // Accordion if ( jQuery('.panel-group').length > 0 ) { jQuery('.panel-group').each(function () { @@ -14,20 +14,22 @@ jQuery(document).ready(function(){ } }); } - - if( jQuery('.zoom-picture').length > 0 ) { + + if( jQuery('.zoom-picture').length > 0 ) { jQuery('.zoom-picture').zoom(); } - - if( jQuery('.zoom-picture-container').length > 0 ) { + + if( jQuery('.zoom-picture-container').length > 0 ) { jQuery('.vc_single_image-wrapper', '.zoom-picture-container').zoom(); } - + }); + + (function($) { "use strict"; - + /** Gallery Isotope */ $(function() { if ( $('.recent-posts .recent-post').length > 0 ) { @@ -39,7 +41,23 @@ jQuery(document).ready(function(){ }); } }); - + + $('.gallery').each(function() { // the containers for all your galleries + + + if( $('a[href$=".jpg"], a[href$=".JPG"], a[href$=".png"], a[href$=".PNG"], a[href$=".gif"], a[href$=".GIF"], a[href$=".jpeg"], a[href$=".JPEG"], a[href$=".bmp"], a[href$=".BMP"]', this ).length > 0 ){ + $(this).magnificPopup({ + delegate: '.gallery-item a', // the selector for gallery item + type: 'image', + gallery: { + enabled:true + } + }); + } + + + }); + })(jQuery); @@ -52,4 +70,4 @@ if ( jQuery('.fullwidth-row').length >0 ) { jQuery(this).next().not('div.fullwidth-row').remove(); } }); -} \ No newline at end of file +} diff --git a/js/min/main-min.js b/js/min/main-min.js index 54edf1a..0fb87c7 100644 --- a/js/min/main-min.js +++ b/js/min/main-min.js @@ -1 +1 @@ -jQuery(document).ready(function(){"use strict";jQuery(".video-container").length>0&&jQuery(".video-container").fitVids(),jQuery(".panel-group").length>0&&jQuery(".panel-group").each(function(){0==jQuery(this).find(".in").length&&(jQuery(".panel:first-child .panel-collapse",jQuery(this)).addClass("in"),jQuery(".panel:first-child .accordion-toggle",jQuery(this)).removeClass("collapsed"))}),jQuery(".zoom-picture").length>0&&jQuery(".zoom-picture").zoom(),jQuery(".zoom-picture-container").length>0&&jQuery(".vc_single_image-wrapper",".zoom-picture-container").zoom()}),function($){"use strict";$(function(){if($(".recent-posts .recent-post").length>0){var e=$(".recent-posts");e.imagesLoaded(function(){e.masonry({itemSelector:".recent-post"})})}})}(jQuery),jQuery(".fullwidth-row").length>0&&jQuery(".fullwidth-row").each(function(){0==jQuery.trim(jQuery(this).prev().not("div.fullwidth-row").children(".row").children(".col-lg-12").html()).length&&jQuery(this).prev().not("div.fullwidth-row").remove(),0==jQuery.trim(jQuery(this).next().not("div.fullwidth-row").children(".row").children(".col-lg-12").html()).length&&jQuery(this).next().not("div.fullwidth-row").remove()}); \ No newline at end of file +jQuery(document).ready(function(){"use strict";jQuery(".video-container").length>0&&jQuery(".video-container").fitVids(),jQuery(".panel-group").length>0&&jQuery(".panel-group").each(function(){0==jQuery(this).find(".in").length&&(jQuery(".panel:first-child .panel-collapse",jQuery(this)).addClass("in"),jQuery(".panel:first-child .accordion-toggle",jQuery(this)).removeClass("collapsed"))}),jQuery(".zoom-picture").length>0&&jQuery(".zoom-picture").zoom(),jQuery(".zoom-picture-container").length>0&&jQuery(".vc_single_image-wrapper",".zoom-picture-container").zoom()}),function($){"use strict";$(function(){if($(".recent-posts .recent-post").length>0){var e=$(".recent-posts");e.imagesLoaded(function(){e.masonry({itemSelector:".recent-post"})})}}),$(".gallery").each(function(){$('a[href$=".jpg"], a[href$=".JPG"], a[href$=".png"], a[href$=".PNG"], a[href$=".gif"], a[href$=".GIF"], a[href$=".jpeg"], a[href$=".JPEG"], a[href$=".bmp"], a[href$=".BMP"]',this).length>0&&$(this).magnificPopup({delegate:".gallery-item a",type:"image",gallery:{enabled:!0}})})}(jQuery),jQuery(".fullwidth-row").length>0&&jQuery(".fullwidth-row").each(function(){0==jQuery.trim(jQuery(this).prev().not("div.fullwidth-row").children(".row").children(".col-lg-12").html()).length&&jQuery(this).prev().not("div.fullwidth-row").remove(),0==jQuery.trim(jQuery(this).next().not("div.fullwidth-row").children(".row").children(".col-lg-12").html()).length&&jQuery(this).next().not("div.fullwidth-row").remove()}); \ No newline at end of file diff --git a/shortcodes/tabs.php b/shortcodes/tabs.php index 67a7186..bba784f 100644 --- a/shortcodes/tabs.php +++ b/shortcodes/tabs.php @@ -1,13 +1,14 @@ '; - + $html .= ''; - + $html .= '
'; $html .= apply_filters( 'the_content', $content); $html .= '
'; - + $html .= '
'; - + return $html; } @@ -32,88 +33,94 @@ function curly_tabs( $atts, $content = null ) { function curly_tab( $atts, $content = null ) { $GLOBALS['tabsSlideID']++; extract(shortcode_atts(array(), $atts)); - if( $GLOBALS['tabsSlideID'] % 100 == 1 ) { - $css = ' active'; + if( $GLOBALS['tabsSlideID'] % 100 == 1 ) { + $css = ' active'; } else { $css = null; } $html = '
' . apply_filters( 'the_content', $content) .'
'; - + return $html; } +*/ add_shortcode('curly_tabs', 'curly_tabs_vc'); +add_shortcode('curly_tab', 'curly_tab_vc'); + function curly_tabs_vc( $atts, $content = null ) { - - $GLOBALS['tabsID'] = ( isset($GLOBALS['tabsID']) ) ? $GLOBALS['tabsID'] + 1 : 0; + + $GLOBALS['tabsID'] = isset( $GLOBALS['tabsID'] ) ? $GLOBALS['tabsID'] + 1 : 0; $GLOBALS['tabsSlideID'] = $GLOBALS['tabsID'] * 100; - + $pattern = get_shortcode_regex(); - + preg_match_all( "/$pattern/", $content, $shortcodes ); - + $shortcodes_array = $shortcodes[2]; $shortcodes_values_array = $shortcodes[3]; $shortcodes_content_array = $shortcodes[5]; - + extract( shortcode_atts( array() , $atts ) ); - + if( has_shortcode( $content, 'curly_tab' ) ){ - + $html = '
'; - + $html .= ''; - + $html .= '
'; - + $html .= do_shortcode( $content ); - + $html .= '
'; - + $html .= '
'; - + return $html; - + } - + } -add_shortcode('curly_tab', 'curly_tab_vc'); + function curly_tab_vc( $atts, $content = null ) { - $GLOBALS['tabsSlideID']++; - extract(shortcode_atts(array(), $atts)); - if( $GLOBALS['tabsSlideID'] % 100 == 1 ) { - $css = ' active'; + + extract(shortcode_atts(array( 'id' => null ), $atts)); + + $group = intval( $GLOBALS['tabsSlideID'] / 100 ); + + if( $GLOBALS['tabsSlideID'] % 100 == 0 ) { + $css = ' active'; } else { $css = null; } - $html = '
' . apply_filters( 'the_content', $content) .'
'; - + $html = '
' . apply_filters( 'the_content', $content) .'
'; + $GLOBALS['tabsSlideID']++; return $html; } -?> \ No newline at end of file +?>