Changeset 2264875
- Timestamp:
- 03/21/2020 07:40:13 AM (5 years ago)
- Location:
- magic-conversation-for-gravity-forms/trunk
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
magic-conversation-for-gravity-forms/trunk/assets/css/sideform.css
r2239122 r2264875 157 157 line-height: 40px; 158 158 text-align: right; 159 } 160 161 .mcfgfp-pin-team-close-ex { 162 right: 0px; 163 top: 0px; 164 color: #777; 165 text-align: center; 166 z-index: 1; 159 167 } 160 168 … … 238 246 239 247 #mcfgfp-pin-container .mcfgfp-pin-header-buttons-close { 240 background-image: url("img/close.png");248 /*background-image: url("img/close.png");*/ 241 249 background-repeat: no-repeat; 242 250 background-size: 14px 14px; … … 250 258 @media not all, (min--moz-device-pixel-ratio: 1.3), not all, (min-resolution: 1.3dppx) { 251 259 #mcfgfp-pin-container .mcfgfp-pin-header-buttons-close { 252 background-image: url("img/[email protected]");260 /*background-image: url("img/[email protected]");*/ 253 261 } 254 262 } … … 292 300 293 301 #mcfgfp-pin-container .mcfgfp-pin-conversation-background-1 { 294 background-image: url("img/background-1.png");302 /*background-image: url("img/background-1.png");*/ 295 303 background-repeat: repeat; 296 304 background-size: 417px 417px; … … 308 316 @media not all, (min--moz-device-pixel-ratio: 1.3), not all, (min-resolution: 1.3dppx) { 309 317 #mcfgfp-pin-container .mcfgfp-pin-conversation-background-1 { 310 background-image: url("img/[email protected]");318 /*background-image: url("img/[email protected]");*/ 311 319 } 312 320 } -
magic-conversation-for-gravity-forms/trunk/assets/html/sideform-bak.html
r1592967 r2264875 114 114 115 115 #intercom-container .intercom-header-buttons-close { 116 background-image: url("img/close.png");116 /*background-image: url("img/close.png");*/ 117 117 background-repeat: no-repeat; 118 118 background-size: 14px 14px; … … 126 126 @media not all, (min--moz-device-pixel-ratio: 1.3), not all, (min-resolution: 1.3dppx) { 127 127 #intercom-container .intercom-header-buttons-close { 128 background-image: url("img/[email protected]");128 /*background-image: url("img/[email protected]");*/ 129 129 } 130 130 } -
magic-conversation-for-gravity-forms/trunk/assets/js/v3/magic-conversation.js
r2259507 r2264875 27 27 var newHeight = $('.mcfgfp-pin-conversation-body-profile').height(); 28 28 // console.log('mcfgf_fix_top newHeight', newHeight); 29 if(!newHeight) { 30 newHeight = 0; 31 } 29 32 $('.mcfgfp-pin-conversation-body-parts').css('top', newHeight+'px'); 30 33 } … … 94 97 95 98 //side form 96 $('#mcfgfp-pin-container .mcfgfp-pin-btn, .mcfgfp-say-hi- body, .mcfgfp-launcher-badge, #mcfgfp-pin-container .mcfgfp-pin-team-close').on('click', function(){99 $('#mcfgfp-pin-container .mcfgfp-pin-btn, .mcfgfp-say-hi-card, .mcfgfp-say-hi-body, .mcfgfp-launcher-badge, #mcfgfp-pin-container .mcfgfp-pin-team-close').on('click', function(){ 97 100 // console.log('_loadConversationForm 1', inited); 98 101 $('.mcfgfp-notifications-dismiss-button').trigger('click'); … … 198 201 if(mcfgf_settings_basics.conversation_header_background_color) { 199 202 mcfgf_css_ex += '.mcfgfp-pin-conversation-body-profile { background-color: '+mcfgf_settings_basics.conversation_header_background_color+' !important;}'+"\r\n"; 203 } 204 205 if(mcfgf_settings_basics.conversation_header_font_color) { 206 mcfgf_css_ex += '#mcfgf-pin-container .mcfgf-pin-team-profile-full-response-delay, #mcfgf-pin-container .mcfgf-pin-team-profile-full-team-name { color: '+mcfgf_settings_basics.conversation_header_font_color+' !important;}'+"\r\n"; 207 } 208 209 if(mcfgf_settings_basics.conversation_notification_background_color) { 210 mcfgf_css_ex += '.mcfgfp-say-hi-card { background-color: '+mcfgf_settings_basics.conversation_notification_background_color+' !important;}'+"\r\n"; 211 212 mcfgf_css_ex += '#mcfgfp-pin-container .mcfgfp-say-hi-card::after { border-color: transparent transparent '+mcfgf_settings_basics.conversation_notification_background_color+' !important;}'+"\r\n"; 213 } 214 215 if(mcfgf_settings_basics.conversation_notification_font_color) { 216 mcfgf_css_ex += '.mcfgfp-say-hi-card .mcfgfp-say-hi-title-name, .mcfgfp-say-hi-card .mcfgfp-say-hi-body, .mcfgfp-say-hi-card .mcfgfp-say-hi-body span { color: '+mcfgf_settings_basics.conversation_notification_font_color+' !important;}'+"\r\n"; 200 217 } 201 218 -
magic-conversation-for-gravity-forms/trunk/help.php
r1592967 r2264875 25 25 $url_base = Settings_MagicConversationForGravityForms::$base_url; 26 26 ?> 27 <div class="wrap"><h1>Magic Conversation For Gravity Forms Pro Help</h1></div> 27 <style> 28 pre.mcfgf_code { 29 /*! background: #eee; */ 30 /*! background-image: -webkit-linear-gradient(#eee 50%,#e0e0e0 50%); */ 31 /*! background-image: -moz-linear-gradient(#eee 50%,#e0e0e0 50%); */ 32 /*! background-image: -ms-linear-gradient(#eee 50%,#e0e0e0 50%); */ 33 /*! background-image: -o-linear-gradient(#eee 50%,#e0e0e0 50%); */ 34 background-image: linear-gradient(#fff 50%,#fcfcfc 50%); 35 background-position: 0 0; 36 background-repeat: repeat; 37 background-size: 4.5em 4.5em; 38 color: #555; 39 font-family: monospace, serif; 40 /*font-size: 16px;*/ 41 line-height: 2.25em; 42 margin: 1em 0em; 43 overflow: auto; 44 padding: 0 1.25em; 45 max-width:100%; 46 white-space: pre-wrap; /* css-3 */ 47 white-space: -moz-pre-wrap; /* Mozilla, since 1999 */ 48 white-space: -pre-wrap; /* Opera 4-6 */ 49 white-space: -o-pre-wrap; /* Opera 7 */ 50 word-wrap: break-word; /* Internet Explorer 5.5+ */ 51 } 52 </style> 53 <div class="wrap"><h1>Magic Conversation For Gravity Forms Help</h1></div> 28 54 <p>Please review the plugin documentation and frequently asked questions (FAQ) first. If you still can't find the answer <a target="_blank" href="<?php echo $url_base; ?>/contact/" target="_blank">open a support ticket</a> and we will be happy to answer your questions and assist you with any problems. Please note: If you have not purchased a license from us, you will not have access to these help resources.</p> 55 56 57 <h3>Quick Start</h3> 58 59 <p>Show a Conversation Button on the Home page or the entire website:</p> 60 61 <p><pre class="mcfgf_code">Settings -> Conversation Form -> Choose a form</pre></p> 62 63 <p>Embed a conversation into a post/page with a short code:</p> 64 65 <p><pre class="mcfgf_code">[magic-conversation id="1" width="100%" height="395px"]</pre></p> 66 67 <p>Add a Floating Conversation Button to a specific page with a short code:</p> 68 69 <p><pre class="mcfgf_code">[magic-conversation-button id="1"]</pre></p> 70 71 <p>Trigger a conversation with a link:</p> 72 73 <p><pre class="mcfgf_code"><a href="/open-magic-conversation?form_id=1">Open Conversation</a></pre></p> 74 75 <p>Trigger a conversation with JavaScript code:</p> 76 77 <p><pre class="mcfgf_code">window.mcfgf_open_magic_conversation("/open-magic-conversation?form_id=1");</pre></p> 78 29 79 <h3>Documentation</h3> 30 80 <ul> -
magic-conversation-for-gravity-forms/trunk/main.php
r2259507 r2264875 1623 1623 } 1624 1624 } 1625 if(window.mcfgf_global) { 1626 window.mcfgf_global.form_id = '.$form_id.'; 1627 } 1628 console.log("__mcb_domReady 001"); 1625 if(window.mcfgf_global && window.mcfgf_global.form_id) { 1626 window.mcfgf_global.form_id = false; 1627 } 1629 1628 __mcb_domReady(function() { 1630 1629 console.log("__mcb_domReady 002"); -
magic-conversation-for-gravity-forms/trunk/plugin-index.php
r2262953 r2264875 2 2 /* 3 3 * Plugin Name: Magic Conversation For Gravity Forms 4 * Version: 3.0.6 84 * Version: 3.0.69 5 5 * Description: Turn your Gravity Forms into Conversation Form 6 6 * Author: Magic Conversation … … 15 15 16 16 if ( ! defined( 'ABSPATH' ) ) exit; 17 define('MCFGFP_VER', '3.0.6 8.406');17 define('MCFGFP_VER', '3.0.69.417'); 18 18 $mcfgfBaseDir = dirname(__FILE__); 19 19 -
magic-conversation-for-gravity-forms/trunk/readme.txt
r2262953 r2264875 5 5 Requires at least: 3.2 6 6 Tested up to: 5.2 7 Stable tag: 3.0.6 87 Stable tag: 3.0.69 8 8 Stable tag: trunk 9 9 License: GPLv2 or later … … 117 117 118 118 == Changelog == 119 120 Version v3.0.69 121 Added Quick Start guide to Help page. 122 Added welcome message tooltip background and font color support. 123 Added support of configure and show merge tags in welcome message. 124 Added support of configure and show merge tags in conversation header. 125 Moved welcome message and conversation header content configuration to Forms -> Edit -> Settings -> Conversaton. 126 Fixed issue on open conversation when user clicks welcome message. 127 Fixed issue on hide conversation header when user disabled conversation header 128 Fixed issue on hide welcome message when user disabled welcome message 119 129 120 130 Version v3.0.68 -
magic-conversation-for-gravity-forms/trunk/settings.php
r2261111 r2264875 334 334 'name' => 'h2_conversation_button', 335 335 'desc' => __( '', 'mcfgf' ), 336 'label' => __( '<h4> GlobalConversation Button</h4>', 'mcfgf' ),336 'label' => __( '<h4>Floating Conversation Button</h4>', 'mcfgf' ), 337 337 'type' => 'html' 338 338 ), … … 347 347 'label' => __( 'Home Page Only', 'mcfgf' ), 348 348 'desc' => __( 'Show the global conversation button on home page only.', 'mcfgf' ), 349 'type' => 'checkbox'350 ),351 array(352 'name' => 'enable_notification_message',353 'label' => __( 'Notification with welcome message', 'mcfgf' ),354 'desc' => __( 'Show a notification welcome message on top of global conversation button.', 'mcfgf' ),355 349 'type' => 'checkbox' 356 350 ), … … 434 428 ) 435 429 ), 430 // Global Conversation Tooltip 431 array( 432 'name' => 'h2_conversation_notification', 433 'desc' => __( '', 'mcfgf' ), 434 'label' => __( '<h4>Conversation Welcome Message</h4>', 'mcfgf' ), 435 'type' => 'html' 436 ), 437 array( 438 'name' => 'enable_notification_message', 439 'label' => __( 'Welcome Tooltip Message', 'mcfgf' ), 440 'desc' => __( 'Show a welcome tooltip on top of global conversation button.', 'mcfgf' ), 441 'type' => 'checkbox' 442 ), 443 array( 444 'name' => 'conversation_notification_background_color', 445 'label' => __( 'Background Color', 'mcfgf' ), 446 'desc' => __( 'Background color for welcome tooltip message', 'mcfgf' ), 447 'type' => 'color', 448 'default' => '' 449 ), 450 array( 451 'name' => 'conversation_notification_font_color', 452 'label' => __( 'Text Color', 'mcfgf' ), 453 'desc' => __( 'Text color for welcome tooltip message', 'mcfgf' ), 454 'type' => 'color', 455 'default' => '' 456 ), 457 // Global Conversation Header 436 458 array( 437 459 'name' => 'h2_conversation_header', … … 446 468 'type' => 'checkbox' 447 469 ), 448 array(449 'name' => 'conversation_header_title',450 'label' => __( 'Title for Conversation Header', 'mcfgf' ),451 // 'desc' => __( 'Default: Type your answer here', 'mcfgf' ),452 'placeholder' => __( 'Please enter a title', 'mcfgf' ),453 'type' => 'text',454 'default' => 'Conversation Title',455 'sanitize_callback' => 'sanitize_text_field'456 ),457 array(458 'name' => 'conversation_header_sub_title',459 'label' => __( 'Sub Title for Conversation Header', 'mcfgf' ),460 // 'desc' => __( 'Default: Type your answer here', 'mcfgf' ),461 'placeholder' => __( 'Please enter a sub title', 'mcfgf' ),462 'type' => 'text',463 'default' => 'Conversation Sub Title',464 'sanitize_callback' => 'sanitize_text_field'465 ),470 // array( 471 // 'name' => 'conversation_header_title', 472 // 'label' => __( 'Title for Conversation Header', 'mcfgf' ), 473 // // 'desc' => __( 'Default: Type your answer here', 'mcfgf' ), 474 // 'placeholder' => __( 'Please enter a title', 'mcfgf' ), 475 // 'type' => 'text', 476 // 'default' => 'Conversation Title', 477 // 'sanitize_callback' => 'sanitize_text_field' 478 // ), 479 // array( 480 // 'name' => 'conversation_header_sub_title', 481 // 'label' => __( 'Sub Title for Conversation Header', 'mcfgf' ), 482 // // 'desc' => __( 'Default: Type your answer here', 'mcfgf' ), 483 // 'placeholder' => __( 'Please enter a sub title', 'mcfgf' ), 484 // 'type' => 'text', 485 // 'default' => 'Conversation Sub Title', 486 // 'sanitize_callback' => 'sanitize_text_field' 487 // ), 466 488 // array( 467 489 // 'name' => 'conversation_header_username', -
magic-conversation-for-gravity-forms/trunk/sideform.php
r2116024 r2264875 54 54 } 55 55 56 public function parseMergeTags($form, $text = false) { 57 if(!empty($text)) { 58 $text = GFCommon::replace_variables( $text, $form, false, false, false ); 59 } 60 return $text; 61 } 62 56 63 public function showSideFormButtonV3($form_id, $avatar_robot, $showGlobalButton = false) { 57 64 global $mcfgf_settings_basics; 58 65 unset($_POST); 59 66 $form = GFAPI::get_form($form_id); 67 68 $welcom_message_title = $this->parseMergeTags($form, isset($form['gf_conversation']['conversation_welcome_message_title']) ? $form['gf_conversation']['conversation_welcome_message_title'] : (isset($mcfgf_settings_basics['conversation_tooltip_title']) ? $mcfgf_settings_basics['conversation_tooltip_title'] : false)); 69 70 71 72 $welcom_message_sub_title = $this->parseMergeTags($form, isset($form['gf_conversation']['conversation_welcome_message_sub_title']) ? $form['gf_conversation']['conversation_welcome_message_sub_title'] : (isset($mcfgf_settings_basics['conversation_tooltip_sub_title']) ? $mcfgf_settings_basics['conversation_tooltip_sub_title'] : false)); 73 74 $header_title = $this->parseMergeTags($form, isset($form['gf_conversation']['conversation_header_title']) ? $form['gf_conversation']['conversation_header_title'] : (isset($form['title']) ? $form['title'] : false)); 75 76 $header_sub_title = $this->parseMergeTags($form, isset($form['gf_conversation']['conversation_header_sub_title']) ? $form['gf_conversation']['conversation_header_sub_title'] : (isset($form['description']) ? $form['description'] : false)); 77 60 78 $url_base = Settings_MagicConversationForGravityForms::$base_url; 61 79 … … 63 81 $mcfgf_is_free = mcfgf_is_free(); 64 82 $enable_notification_message = isset($mcfgf_settings_basics['enable_notification_message']) && $mcfgf_settings_basics['enable_notification_message']=='on'; 83 84 $enable_conversation_header = isset($mcfgf_settings_basics['enable_conversation_header']) && $mcfgf_settings_basics['enable_conversation_header']=='on'; 85 65 86 $ajax_url = admin_url( 'admin-ajax.php' ); 66 87 $ver = MCFGFP_VER; … … 98 119 <div class="mcfgfp-pin-btn-close"><?php echo $ex_button_image_close; ?></div> 99 120 </div> 100 <?php if ($enable_notification_message): ?>121 101 122 <div data-reactroot="" class="mcfgfp-notifications"> 123 <?php if ($enable_notification_message && ($welcom_message_title || $welcom_message_sub_title)): ?> 102 124 <button class="mcfgfp-notifications-dismiss-button">Clear<span class="mcfgfp-notifications-dismiss-button-icon"></span></button> 125 <?php endif ?> 103 126 <div class="mcfgfp-notification"> 104 127 <div class="mcfgfp-say-hi"> 128 <?php if ($enable_notification_message && ($welcom_message_title || $welcom_message_sub_title)): ?> 105 129 <div class="mcfgfp-say-hi-card"> 130 <?php if($welcom_message_title): ?> 106 131 <div class="mcfgfp-say-hi-title"> 107 132 <div class="mcfgfp-say-hi-title-name-from"> 108 <span class="mcfgfp-say-hi-title-name"><?php echo $mcfgf_settings_basics['conversation_header_title']; ?></span> 109 </div> 110 </div> 111 <div class="mcfgfp-say-hi-body"><span><?php echo $mcfgf_settings_basics['conversation_header_welcome_message']; ?></span></div> 112 </div> 133 <span class="mcfgfp-say-hi-title-name"><?php echo $welcom_message_title; ?></span> 134 </div> 135 </div> 136 <?php endif; ?> 137 <?php if($welcom_message_sub_title): ?> 138 <div class="mcfgfp-say-hi-body"><span><?php echo $welcom_message_sub_title; ?></span></div> 139 <?php endif; ?> 140 </div> 141 <?php endif ?> 113 142 <div data-reactroot="" class="mcfgfp-launcher-badge"><img src="<?php echo $avatar_robot; ?>" /></div> 114 143 </div> … … 117 146 118 147 </div> 119 <?php endif ?>148 120 149 </div> 121 150 <?php endif; ?> … … 135 164 </div> 136 165 <div class="mcfgfp-pin-conversation-body mcfgfp-pin-conversation-body-snapped" style="transform: translateY(0px); bottom: 0px;"> 166 <?php if($enable_conversation_header): ?> 137 167 <div class="mcfgfp-pin-conversation-body-profile"> 138 168 <div class="mcfgfp-pin-conversation-profile mcfgfp-pin-conversation-profile-expanded"> … … 142 172 </div> 143 173 <div class="mcfgfp-pin-team-profile-full-team-name"> 144 <?php echo $ form['title']; ?>174 <?php echo $header_title; ?> 145 175 <?php //echo $mcfgf_settings_basics['conversation_header_title']; ?> 146 176 </div> 177 <?php if($header_sub_title): ?> 147 178 <div class="mcfgfp-pin-team-profile-full-response-delay"> 148 <?php echo $ form['description']; ?>179 <?php echo $header_sub_title; ?> 149 180 <?php // echo $mcfgf_settings_basics['conversation_header_sub_title']; ?> 150 181 </div> 182 <?php endif;?> 151 183 <div class="mcfgfp-pin-team-profile-full-avatar-container" style="display: none"> 152 184 <div class="mcfgfp-pin-team-profile-full-avatar mcfgfp-pin-index-0"> … … 165 197 </div> 166 198 </div> 199 <?php else: ?> 200 <div class="iconfont icon-close mcfgfp-pin-team-close mcfgfp-pin-team-close-ex"> 201 </div> 202 <?php endif; ?> 167 203 <div class="mcfgfp-pin-conversation-body-parts" style="top: 195px; bottom: 0px;"> 168 204 <div class="mcfgfp-pin-conversation-body-parts-wrapper"> … … 252 288 </div> 253 289 <div class="mcfgfp-pin-team-profile-full-team-name"> 254 <?php echo $mcfgf_settings_basics['conversation_ header_title']; ?>290 <?php echo $mcfgf_settings_basics['conversation_tooltip_title']; ?> 255 291 </div> 256 292 <div class="mcfgfp-pin-team-profile-full-response-delay"> 257 <?php echo $mcfgf_settings_basics['conversation_ header_sub_title']; ?>293 <?php echo $mcfgf_settings_basics['conversation_tooltip_sub_title']; ?> 258 294 </div> 259 295 <div class="mcfgfp-pin-team-profile-full-avatar-container"> -
magic-conversation-for-gravity-forms/trunk/yakker-gravityforms/class-gfyakkeraddon.php
r2261111 r2264875 331 331 ), 332 332 array( 333 'label' => esc_html__( 'Welcome Message Title', 'yakkeraddon' ), 334 'type' => 'text', 335 'name' => 'conversation_welcome_message_title', 336 'tooltip' => esc_html__( 'The welcome message tooltip title displayed on top of conversation button.', 'yakkeraddon' ), 337 'class' => 'medium merge-tag-support mt-position-right', 338 'default_value' => 'Hello', 339 //'feedback_callback' => array( $this, 'is_valid_setting' ), 340 ), 341 array( 342 'label' => esc_html__( 'Welcome Message Sub-Title', 'yakkeraddon' ), 343 'type' => 'text', 344 'name' => 'conversation_welcome_message_sub_title', 345 'tooltip' => esc_html__( 'The welcome message tooltip sub title displayed on top of conversation button.', 'yakkeraddon' ), 346 'class' => 'medium merge-tag-support mt-position-right', 347 'default_value' => 'I\'m Magic Conversation.', 348 //'feedback_callback' => array( $this, 'is_valid_setting' ), 349 ), 350 array( 351 'label' => esc_html__( 'Conversation Header Title', 'yakkeraddon' ), 352 'type' => 'text', 353 'name' => 'conversation_header_title', 354 'tooltip' => esc_html__( 'The title of conversation header displayed on top of conversation opened by click conversation button.', 'yakkeraddon' ), 355 'class' => 'medium merge-tag-support mt-position-right', 356 'default_value' => 'Hello', 357 //'feedback_callback' => array( $this, 'is_valid_setting' ), 358 ), 359 array( 360 'label' => esc_html__( 'Conversation Header Sub-Title', 'yakkeraddon' ), 361 'type' => 'text', 362 'name' => 'conversation_header_sub_title', 363 'tooltip' => esc_html__( 'The sub title of conversation header displayed on top of conversation opened by click conversation button.', 'yakkeraddon' ), 364 'class' => 'medium merge-tag-support mt-position-right', 365 'default_value' => 'I\'m Magic Conversation.', 366 //'feedback_callback' => array( $this, 'is_valid_setting' ), 367 ), 368 array( 333 369 'label' => esc_html__( 'Display Name For Robot', 'yakkeraddon' ), 334 370 'type' => 'text',
Note: See TracChangeset
for help on using the changeset viewer.