Version Description
Download this release
Release Info
Developer | pacotole |
Plugin | WhatsApp me |
Version | 4.2.0 |
Comparing to | |
See all releases |
Code changes from version 4.1.15 to 4.2.0
- README.txt +42 -10
- admin/class-joinchat-admin.php +92 -72
- admin/css/joinchat.css +4 -1
- admin/css/joinchat.min.css +1 -1
- includes/class-joinchat-common.php +78 -0
- includes/class-joinchat-elementor-finder.php +15 -5
- includes/class-joinchat-i18n.php +131 -0
- includes/class-joinchat-integrations.php +7 -3
- includes/class-joinchat-util.php +40 -31
- includes/class-joinchat.php +6 -4
- joinchat.php +2 -2
- languages/creame-whatsapp-me.pot +145 -125
- public/class-joinchat-public.php +13 -44
- public/css/joinchat.css +28 -4
- public/css/joinchat.min.css +1 -1
README.txt
CHANGED
@@ -1,25 +1,28 @@
|
|
1 |
=== Join.chat ===
|
2 |
Contributors: creapuntome, pacotole, davidlillo, monillo
|
3 |
-
Donate link: https://
|
4 |
-
Tags:
|
5 |
Requires at least: 3.5.0
|
6 |
Tested up to: 5.8
|
7 |
Requires PHP: 5.3
|
8 |
-
Stable tag: 4.
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
12 |
-
|
13 |
|
14 |
== Description ==
|
15 |
|
16 |
-
|
17 |
|
18 |
> The best WordPress plugin for WhatsApp, with more than 400,000 installations worldwide.
|
19 |
|
20 |
https://www.youtube.com/watch?v=Ad2ZpPnX_3Q
|
21 |
|
22 |
-
[Documentation](https://join.chat/en/docs/?utm_source=wporg&utm_medium=web&utm_campaign=
|
|
|
|
|
|
|
23 |
|
24 |
### ⌁ What you can do with Join.chat (formerly WAme) ✅
|
25 |
|
@@ -89,13 +92,10 @@ This Add-on allows you to create rich content in the chat window, to make the ca
|
|
89 |
#### 🎲 [Random Phone](https://join.chat/en/addons/random-phone/).
|
90 |
With Random Phone you can add as many phone numbers as you want, there is no limit. Every time a user of your site clicks on the start chat button, they will be randomly and equitably referred to each of the different support numbers you have configured.
|
91 |
|
92 |
-
#### 🤖 [Chatbot Svachat](https://join.chat/en/addons/svachat-bot/).
|
93 |
-
Our Add-on Chatbot (Svachat) is designed to answer your customers' recurring questions (FAQS) by creating a chatbot that interacts with the user and decides based on the user's queries.
|
94 |
-
|
95 |
### ⌁ If you like Join.chat 😍
|
96 |
1. Please leave us a [★★★★★](https://wordpress.org/support/plugin/creame-whatsapp-me/reviews/#new-post) rating. We'll thank you.
|
97 |
2. Help us with the [translation in your language](https://translate.wordpress.org/projects/wp-plugins/creame-whatsapp-me)
|
98 |
-
3. Visit our blog and find tips and tricks at [join.chat](https://join.chat/en/blog/?utm_source=wporg&utm_medium=web&utm_campaign=
|
99 |
4. Follow [@joinchatnow](https://twitter.com/joinchatnow) on twitter.
|
100 |
|
101 |
|
@@ -155,6 +155,29 @@ Join.chat save two localStorage variables for proper operation:
|
|
155 |
* `joinchat_views` is a visits counter to control when to show chat window.
|
156 |
* `joinchat_hashes` if you set a Call To Action (CTA), when user launch WhatsApp or close Chat Window the CTA hashed is saved to prevent show automatically that CTA again.
|
157 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
158 |
= WPML/Polylang translations =
|
159 |
|
160 |
Join.chat settings are saved in your site's main language. For other languages translation go to *WPML/Polylang Settings > String translations*, filter strings group by "Join.chat" and update the strings for each language.
|
@@ -217,6 +240,15 @@ There is a Javascript event that Join.chat triggers automatically before launch
|
|
217 |
|
218 |
== Changelog ==
|
219 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
220 |
= 4.1.15 =
|
221 |
* **NEW:** WordPress 5.8 tested & updated.
|
222 |
* FIX RTL text align right.
|
1 |
=== Join.chat ===
|
2 |
Contributors: creapuntome, pacotole, davidlillo, monillo
|
3 |
+
Donate link: https://join.chat/donate/
|
4 |
+
Tags: Chat, Click to Chat, Facebook Messenger, WhatsApp, Telegram, Whatsapp Business, button, support chat, support, contact, directly message WhatsApp, floating WhatsApp, WhatsApp chat
|
5 |
Requires at least: 3.5.0
|
6 |
Tested up to: 5.8
|
7 |
Requires PHP: 5.3
|
8 |
+
Stable tag: 4.2
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
12 |
+
WhatsApp, Messenger, Telegram, Phone call… capture users through their favorite Apps and turn into clients
|
13 |
|
14 |
== Description ==
|
15 |
|
16 |
+
**🎉 Chat with your website visitors through their favorite chat applications. Place a floating button at the bottom of your site and give the best support to your customers.**
|
17 |
|
18 |
> The best WordPress plugin for WhatsApp, with more than 400,000 installations worldwide.
|
19 |
|
20 |
https://www.youtube.com/watch?v=Ad2ZpPnX_3Q
|
21 |
|
22 |
+
[Documentation](https://join.chat/en/docs/?utm_source=wporg&utm_medium=web&utm_campaign=v4_2) | [Add-ons](https://join.chat/en/addons/?utm_source=wporg&utm_medium=web&utm_campaign=v4_2) | [Support](https://join.chat/en/support/?utm_source=wporg&utm_medium=web&utm_campaign=v4_2)
|
23 |
+
|
24 |
+
### 🧪 Try Join.chat
|
25 |
+
Do you want to test the Join.chat configuration panel without installing it? You can try it in a [WordPress on the fly demo](https://demo.tastewp.com/creame-whatsapp-me)
|
26 |
|
27 |
### ⌁ What you can do with Join.chat (formerly WAme) ✅
|
28 |
|
92 |
#### 🎲 [Random Phone](https://join.chat/en/addons/random-phone/).
|
93 |
With Random Phone you can add as many phone numbers as you want, there is no limit. Every time a user of your site clicks on the start chat button, they will be randomly and equitably referred to each of the different support numbers you have configured.
|
94 |
|
|
|
|
|
|
|
95 |
### ⌁ If you like Join.chat 😍
|
96 |
1. Please leave us a [★★★★★](https://wordpress.org/support/plugin/creame-whatsapp-me/reviews/#new-post) rating. We'll thank you.
|
97 |
2. Help us with the [translation in your language](https://translate.wordpress.org/projects/wp-plugins/creame-whatsapp-me)
|
98 |
+
3. Visit our blog and find tips and tricks at [join.chat](https://join.chat/en/blog/?utm_source=wporg&utm_medium=web&utm_campaign=v4_2).
|
99 |
4. Follow [@joinchatnow](https://twitter.com/joinchatnow) on twitter.
|
100 |
|
101 |
|
155 |
* `joinchat_views` is a visits counter to control when to show chat window.
|
156 |
* `joinchat_hashes` if you set a Call To Action (CTA), when user launch WhatsApp or close Chat Window the CTA hashed is saved to prevent show automatically that CTA again.
|
157 |
|
158 |
+
= Allow other roles to change settings =
|
159 |
+
|
160 |
+
By default Join.chat settings is a submenu under "Settings" and can only be edited by users with `administrator` role.
|
161 |
+
You can change the required capability to edit Join.chat general settings with the filter `joinchat_capability`.
|
162 |
+
|
163 |
+
e.g. allow shop managers:
|
164 |
+
|
165 |
+
`add_filter( 'joinchat_capability', function(){ return 'manage_woocommerce'; } );`
|
166 |
+
|
167 |
+
e.g. allow editors:
|
168 |
+
|
169 |
+
`add_filter( 'joinchat_capability', function(){ return 'edit_pages'; } );`
|
170 |
+
|
171 |
+
When change `joinchat_capability` Join.chat menu will be placed as direct menu in your wp-admin but also you can force it with the filter `joinchat_submenu`:
|
172 |
+
|
173 |
+
e.g. force as menu:
|
174 |
+
|
175 |
+
`add_filter( 'joinchat_submenu', '__return_false' );`
|
176 |
+
|
177 |
+
e.g. force as submenu:
|
178 |
+
|
179 |
+
`add_filter( 'joinchat_submenu', '__return_true' );`
|
180 |
+
|
181 |
= WPML/Polylang translations =
|
182 |
|
183 |
Join.chat settings are saved in your site's main language. For other languages translation go to *WPML/Polylang Settings > String translations*, filter strings group by "Join.chat" and update the strings for each language.
|
240 |
|
241 |
== Changelog ==
|
242 |
|
243 |
+
= 4.2 =
|
244 |
+
* **NEW:** Now can change default role allowed to configure Join.chat global settings.
|
245 |
+
* **NEW:** Now can show Join.chat as a direct menu in wp-admin.
|
246 |
+
* **NEW:** link to update translatable settings when changed.
|
247 |
+
* **NEW:** Accessibility: disable animations for devices with Reduced Motion preference.
|
248 |
+
* FIX Elementor 3.5 Finder deprecation message.
|
249 |
+
* FIX WPML ensure translations are registered in default site language.
|
250 |
+
* Styles minor improvements.
|
251 |
+
|
252 |
= 4.1.15 =
|
253 |
* **NEW:** WordPress 5.8 tested & updated.
|
254 |
* FIX RTL text align right.
|
admin/class-joinchat-admin.php
CHANGED
@@ -30,6 +30,15 @@ class JoinChatAdmin {
|
|
30 |
*/
|
31 |
private $version;
|
32 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
33 |
/**
|
34 |
* The setings of this plugin.
|
35 |
*
|
@@ -69,6 +78,7 @@ class JoinChatAdmin {
|
|
69 |
|
70 |
$this->plugin_name = $plugin_name;
|
71 |
$this->version = $version;
|
|
|
72 |
|
73 |
// Updated in get_settings() at 'admin_init' hook
|
74 |
$this->enhanced_phone = '17.0.12'; // intl-tel-input version
|
@@ -103,45 +113,8 @@ class JoinChatAdmin {
|
|
103 |
)
|
104 |
);
|
105 |
|
106 |
-
//
|
107 |
-
$
|
108 |
-
array(
|
109 |
-
'telephone' => '',
|
110 |
-
'mobile_only' => 'no',
|
111 |
-
'button_image' => '',
|
112 |
-
'button_tip' => '',
|
113 |
-
'button_delay' => 3,
|
114 |
-
'whatsapp_web' => 'no',
|
115 |
-
'message_text' => '',
|
116 |
-
'message_delay' => 10,
|
117 |
-
'message_views' => 2,
|
118 |
-
'message_badge' => 'no',
|
119 |
-
'message_send' => '',
|
120 |
-
'message_start' => __( 'Open chat', 'creame-whatsapp-me' ),
|
121 |
-
'position' => 'right',
|
122 |
-
'visibility' => array( 'all' => 'yes' ),
|
123 |
-
'color' => '#25d366',
|
124 |
-
'dark_mode' => 'no',
|
125 |
-
'header' => '__jc__', // values: '__jc__', '__wa__' or other custom text
|
126 |
-
),
|
127 |
-
apply_filters( 'joinchat_extra_settings', array() )
|
128 |
-
);
|
129 |
-
|
130 |
-
$this->settings = $default_settings;
|
131 |
-
$saved_settings = get_option( 'joinchat', $default_settings );
|
132 |
-
|
133 |
-
if ( is_array( $saved_settings ) ) {
|
134 |
-
// Migrate addons 'remove_brand' setting to 'header' (v. < 4.1)
|
135 |
-
if ( isset( $saved_settings['remove_brand'] ) ) {
|
136 |
-
$remove = $saved_settings['remove_brand'];
|
137 |
-
$saved_settings['header'] = 'wa' == $remove ? '__wa__' : ( 'no' == $remove ? '__jc__' : '' );
|
138 |
-
}
|
139 |
-
|
140 |
-
// clean unused saved settings
|
141 |
-
$saved_settings = array_intersect_key( $saved_settings, $default_settings );
|
142 |
-
// merge defaults with saved settings
|
143 |
-
$this->settings = array_merge( $default_settings, $saved_settings );
|
144 |
-
}
|
145 |
|
146 |
}
|
147 |
|
@@ -207,18 +180,18 @@ class JoinChatAdmin {
|
|
207 |
public function settings_init() {
|
208 |
|
209 |
// Register WordPress 'joinchat' settings
|
210 |
-
register_setting(
|
211 |
|
212 |
foreach ( $this->tabs as $tab => $tab_name ) {
|
213 |
|
214 |
-
add_settings_section( "joinchat_tab_{$tab}_open", null, array( $this, 'settings_tab_open' ),
|
215 |
|
216 |
$sections = $this->get_tab_sections( $tab );
|
217 |
|
218 |
foreach ( $sections as $section => $fields ) {
|
219 |
$section_id = "joinchat_tab_{$tab}__{$section}";
|
220 |
|
221 |
-
add_settings_section( $section_id, null, array( $this, 'section_output' ),
|
222 |
|
223 |
foreach ( $fields as $field => $field_args ) {
|
224 |
if ( is_array( $field_args ) ) {
|
@@ -229,11 +202,11 @@ class JoinChatAdmin {
|
|
229 |
$field_callback = array( $this, 'field_output' );
|
230 |
}
|
231 |
|
232 |
-
add_settings_field( "joinchat_$field", $field_name, $field_callback,
|
233 |
}
|
234 |
}
|
235 |
|
236 |
-
add_settings_section( "joinchat_tab_{$tab}_close", null, array( $this, 'settings_tab_close' ),
|
237 |
}
|
238 |
|
239 |
}
|
@@ -350,7 +323,7 @@ class JoinChatAdmin {
|
|
350 |
|
351 |
// Prevent bad behavior when validate twice on first save
|
352 |
// bug https://core.trac.wordpress.org/ticket/21989
|
353 |
-
if ( count( get_settings_errors(
|
354 |
return $input;
|
355 |
}
|
356 |
|
@@ -387,28 +360,18 @@ class JoinChatAdmin {
|
|
387 |
return 'yes' == $v || 'no' == $v;
|
388 |
}
|
389 |
);
|
390 |
-
unset( $input['view'] );
|
391 |
}
|
392 |
|
|
|
|
|
|
|
393 |
// Filter for other validations or extra settings
|
394 |
-
$input = apply_filters( 'joinchat_settings_validate', $input );
|
395 |
|
396 |
-
|
397 |
-
* Register WPML/Polylang strings for translation
|
398 |
-
* https://wpml.org/wpml-hook/wpml_register_single_string/
|
399 |
-
*/
|
400 |
-
$settings_i18n = JoinChatUtil::settings_i18n( $input );
|
401 |
-
|
402 |
-
foreach ( $settings_i18n as $setting_key => $setting_name ) {
|
403 |
-
if ( isset( $input[ $setting_key ] ) ) {
|
404 |
-
do_action( 'wpml_register_single_string', 'Join.chat', $setting_name, $input[ $setting_key ] );
|
405 |
-
}
|
406 |
-
}
|
407 |
|
408 |
// Extra actions on save
|
409 |
-
do_action( '
|
410 |
-
|
411 |
-
add_settings_error( 'joinchat', 'settings_updated', __( 'Settings saved', 'creame-whatsapp-me' ), 'updated' );
|
412 |
|
413 |
return $input;
|
414 |
}
|
@@ -685,12 +648,60 @@ class JoinChatAdmin {
|
|
685 |
* Add menu to the options page in the WordPress admin
|
686 |
*
|
687 |
* @since 1.0.0
|
|
|
688 |
* @access public
|
689 |
* @return void
|
690 |
*/
|
691 |
public function add_menu() {
|
692 |
|
693 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
694 |
|
695 |
}
|
696 |
|
@@ -787,7 +798,8 @@ class JoinChatAdmin {
|
|
787 |
*/
|
788 |
public function settings_link( $links ) {
|
789 |
|
790 |
-
$settings_link = '<a href="
|
|
|
791 |
array_unshift( $links, $settings_link );
|
792 |
|
793 |
return $links;
|
@@ -843,8 +855,14 @@ class JoinChatAdmin {
|
|
843 |
<div class="wrap">
|
844 |
<h1><?php _e( 'Join.chat Settings', 'creame-whatsapp-me' ); ?></h1>
|
845 |
|
|
|
|
|
|
|
|
|
|
|
|
|
846 |
<form method="post" id="joinchat_form" action="options.php" autocomplete="off">
|
847 |
-
<?php settings_fields(
|
848 |
<h2 class="nav-tab-wrapper wp-clearfix" role="tablist">
|
849 |
<?php foreach ( $this->tabs as $tab => $name ) : ?>
|
850 |
<?php if ( $active_tab === $tab ) : ?>
|
@@ -855,7 +873,7 @@ class JoinChatAdmin {
|
|
855 |
<?php endforeach; ?>
|
856 |
</h2>
|
857 |
<div class="joinchat-tabs">
|
858 |
-
<?php do_settings_sections(
|
859 |
</div><!-- end tabs -->
|
860 |
<?php submit_button(); ?>
|
861 |
</form>
|
@@ -881,7 +899,7 @@ class JoinChatAdmin {
|
|
881 |
|
882 |
foreach ( $post_types as $post_type ) {
|
883 |
add_meta_box(
|
884 |
-
|
885 |
__( 'Join.chat', 'creame-whatsapp-me' ),
|
886 |
array( $this, 'meta_box' ),
|
887 |
$post_type,
|
@@ -985,16 +1003,18 @@ class JoinChatAdmin {
|
|
985 |
|
986 |
global $wpdb;
|
987 |
|
988 |
-
if ( wp_is_post_autosave( $post_id )
|
989 |
-
|
990 |
-
|
|
|
991 |
return;
|
992 |
}
|
993 |
|
994 |
// Encode emojis if utf8mb4 not supported by DB
|
995 |
if ( function_exists( 'wp_encode_emoji' )
|
996 |
-
|
997 |
-
|
|
|
998 |
add_filter( 'sanitize_text_field', 'wp_encode_emoji' );
|
999 |
}
|
1000 |
|
@@ -1093,7 +1113,7 @@ class JoinChatAdmin {
|
|
1093 |
public function admin_footer_text( $footer_text ) {
|
1094 |
$current_screen = get_current_screen();
|
1095 |
|
1096 |
-
if ( $current_screen &&
|
1097 |
$footer_text = sprintf(
|
1098 |
__( 'Do you like %1$s? Please help us with a %2$s rating.', 'creame-whatsapp-me' ),
|
1099 |
'<strong>Join.chat</strong>',
|
30 |
*/
|
31 |
private $version;
|
32 |
|
33 |
+
/**
|
34 |
+
* Common class for admin and front methods.
|
35 |
+
*
|
36 |
+
* @since 4.2.0
|
37 |
+
* @access private
|
38 |
+
* @var JoinChatCommon $common instance.
|
39 |
+
*/
|
40 |
+
private $common;
|
41 |
+
|
42 |
/**
|
43 |
* The setings of this plugin.
|
44 |
*
|
78 |
|
79 |
$this->plugin_name = $plugin_name;
|
80 |
$this->version = $version;
|
81 |
+
$this->common = new JoinChatCommon();
|
82 |
|
83 |
// Updated in get_settings() at 'admin_init' hook
|
84 |
$this->enhanced_phone = '17.0.12'; // intl-tel-input version
|
113 |
)
|
114 |
);
|
115 |
|
116 |
+
// Load settings
|
117 |
+
$this->settings = $this->common->load_settings();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
118 |
|
119 |
}
|
120 |
|
180 |
public function settings_init() {
|
181 |
|
182 |
// Register WordPress 'joinchat' settings
|
183 |
+
register_setting( $this->plugin_name, $this->plugin_name, array( $this, 'settings_validate' ) );
|
184 |
|
185 |
foreach ( $this->tabs as $tab => $tab_name ) {
|
186 |
|
187 |
+
add_settings_section( "joinchat_tab_{$tab}_open", null, array( $this, 'settings_tab_open' ), $this->plugin_name );
|
188 |
|
189 |
$sections = $this->get_tab_sections( $tab );
|
190 |
|
191 |
foreach ( $sections as $section => $fields ) {
|
192 |
$section_id = "joinchat_tab_{$tab}__{$section}";
|
193 |
|
194 |
+
add_settings_section( $section_id, null, array( $this, 'section_output' ), $this->plugin_name );
|
195 |
|
196 |
foreach ( $fields as $field => $field_args ) {
|
197 |
if ( is_array( $field_args ) ) {
|
202 |
$field_callback = array( $this, 'field_output' );
|
203 |
}
|
204 |
|
205 |
+
add_settings_field( "joinchat_$field", $field_name, $field_callback, $this->plugin_name, $section_id, $field );
|
206 |
}
|
207 |
}
|
208 |
|
209 |
+
add_settings_section( "joinchat_tab_{$tab}_close", null, array( $this, 'settings_tab_close' ), $this->plugin_name );
|
210 |
}
|
211 |
|
212 |
}
|
323 |
|
324 |
// Prevent bad behavior when validate twice on first save
|
325 |
// bug https://core.trac.wordpress.org/ticket/21989
|
326 |
+
if ( count( get_settings_errors( $this->plugin_name ) ) ) {
|
327 |
return $input;
|
328 |
}
|
329 |
|
360 |
return 'yes' == $v || 'no' == $v;
|
361 |
}
|
362 |
);
|
|
|
363 |
}
|
364 |
|
365 |
+
// Clean input items that are not in settings
|
366 |
+
$input = array_intersect_key( $input, $this->settings );
|
367 |
+
|
368 |
// Filter for other validations or extra settings
|
369 |
+
$input = apply_filters( 'joinchat_settings_validate', $input, $this->settings );
|
370 |
|
371 |
+
add_settings_error( $this->plugin_name, 'settings_updated', __( 'Settings saved', 'creame-whatsapp-me' ), 'updated' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
372 |
|
373 |
// Extra actions on save
|
374 |
+
do_action( 'joinchat_settings_validation', $input, $this->settings );
|
|
|
|
|
375 |
|
376 |
return $input;
|
377 |
}
|
648 |
* Add menu to the options page in the WordPress admin
|
649 |
*
|
650 |
* @since 1.0.0
|
651 |
+
* @since 4.2.0 allowed direct menu page
|
652 |
* @access public
|
653 |
* @return void
|
654 |
*/
|
655 |
public function add_menu() {
|
656 |
|
657 |
+
$title = 'Join.chat';
|
658 |
+
|
659 |
+
if ( JoinChatUtil::options_submenu() ) {
|
660 |
+
$icon = '<span class="dashicons-before dashicons-whatsapp" aria-hidden="true" ' .
|
661 |
+
'style="display:inline-block;max-height:18px;position:relative;top:-2px;left:8px"></span>';
|
662 |
+
|
663 |
+
add_options_page( $title, $title . $icon, JoinChatUtil::capability(), $this->plugin_name, array( $this, 'options_page' ) );
|
664 |
+
} else {
|
665 |
+
add_menu_page( $title, $title, JoinChatUtil::capability(), $this->plugin_name, array( $this, 'options_page' ), 'dashicons-whatsapp', 81 );
|
666 |
+
}
|
667 |
+
|
668 |
+
}
|
669 |
+
|
670 |
+
/**
|
671 |
+
* Show admin notices
|
672 |
+
*
|
673 |
+
* @since 4.2.0
|
674 |
+
* @access public
|
675 |
+
* @return void
|
676 |
+
*/
|
677 |
+
public function notices() {
|
678 |
+
|
679 |
+
$current_screen = get_current_screen();
|
680 |
+
|
681 |
+
// Save notice dismiss one month
|
682 |
+
if ( isset( $_GET['joinchat-ignore-notice'] ) ) {
|
683 |
+
set_transient( 'joinchat_notice_dismiss__' . get_current_user_id(), true, MONTH_IN_SECONDS );
|
684 |
+
}
|
685 |
+
|
686 |
+
// If no phone number defined
|
687 |
+
if ( ( ! defined( 'DISABLE_NAG_NOTICES' ) || ! DISABLE_NAG_NOTICES )
|
688 |
+
&& empty( $this->settings['telephone'] )
|
689 |
+
&& current_user_can( JoinChatUtil::capability() )
|
690 |
+
&& ( $current_screen && false === strpos( $current_screen->id, '_joinchat' ) )
|
691 |
+
&& ! get_transient( 'joinchat_notice_dismiss__' . get_current_user_id() )
|
692 |
+
) {
|
693 |
+
|
694 |
+
printf(
|
695 |
+
'<div class="notice notice-info"><p><strong>Join.chat</strong> %s %s %s</p></div>',
|
696 |
+
__( 'You only need to add your WhatsApp number to contact with your users.', 'creame-whatsapp-me' ),
|
697 |
+
sprintf( '<a href="%s" class="button-primary">%s</a>', JoinChatUtil::admin_url(), __( 'Settings', 'creame-whatsapp-me' ) ),
|
698 |
+
sprintf(
|
699 |
+
'<a href="%s" class="button-secondary">%s</a>',
|
700 |
+
add_query_arg( 'joinchat-ignore-notice', '', home_url( $_SERVER['REQUEST_URI'] ) ),
|
701 |
+
__( 'Dismiss', 'creame-whatsapp-me' )
|
702 |
+
)
|
703 |
+
);
|
704 |
+
}
|
705 |
|
706 |
}
|
707 |
|
798 |
*/
|
799 |
public function settings_link( $links ) {
|
800 |
|
801 |
+
$settings_link = sprintf( '<a href="%s">%s</a>', JoinChatUtil::admin_url(), __( 'Settings', 'creame-whatsapp-me' ) );
|
802 |
+
|
803 |
array_unshift( $links, $settings_link );
|
804 |
|
805 |
return $links;
|
855 |
<div class="wrap">
|
856 |
<h1><?php _e( 'Join.chat Settings', 'creame-whatsapp-me' ); ?></h1>
|
857 |
|
858 |
+
<?php
|
859 |
+
if ( ! JoinChatUtil::options_submenu() ) {
|
860 |
+
settings_errors();
|
861 |
+
}
|
862 |
+
?>
|
863 |
+
|
864 |
<form method="post" id="joinchat_form" action="options.php" autocomplete="off">
|
865 |
+
<?php settings_fields( $this->plugin_name ); ?>
|
866 |
<h2 class="nav-tab-wrapper wp-clearfix" role="tablist">
|
867 |
<?php foreach ( $this->tabs as $tab => $name ) : ?>
|
868 |
<?php if ( $active_tab === $tab ) : ?>
|
873 |
<?php endforeach; ?>
|
874 |
</h2>
|
875 |
<div class="joinchat-tabs">
|
876 |
+
<?php do_settings_sections( $this->plugin_name ); ?>
|
877 |
</div><!-- end tabs -->
|
878 |
<?php submit_button(); ?>
|
879 |
</form>
|
899 |
|
900 |
foreach ( $post_types as $post_type ) {
|
901 |
add_meta_box(
|
902 |
+
$this->plugin_name,
|
903 |
__( 'Join.chat', 'creame-whatsapp-me' ),
|
904 |
array( $this, 'meta_box' ),
|
905 |
$post_type,
|
1003 |
|
1004 |
global $wpdb;
|
1005 |
|
1006 |
+
if ( wp_is_post_autosave( $post_id )
|
1007 |
+
|| ! isset( $_POST['joinchat_nonce'] )
|
1008 |
+
|| ! wp_verify_nonce( $_POST['joinchat_nonce'], 'joinchat_data' )
|
1009 |
+
) {
|
1010 |
return;
|
1011 |
}
|
1012 |
|
1013 |
// Encode emojis if utf8mb4 not supported by DB
|
1014 |
if ( function_exists( 'wp_encode_emoji' )
|
1015 |
+
&& 'utf8mb4' !== $wpdb->get_col_charset( $wpdb->postmeta, 'meta_value' )
|
1016 |
+
&& ! has_filter( 'sanitize_text_field', 'wp_encode_emoji' )
|
1017 |
+
) {
|
1018 |
add_filter( 'sanitize_text_field', 'wp_encode_emoji' );
|
1019 |
}
|
1020 |
|
1113 |
public function admin_footer_text( $footer_text ) {
|
1114 |
$current_screen = get_current_screen();
|
1115 |
|
1116 |
+
if ( $current_screen && false !== strpos( $current_screen->id, '_joinchat' ) ) {
|
1117 |
$footer_text = sprintf(
|
1118 |
__( 'Do you like %1$s? Please help us with a %2$s rating.', 'creame-whatsapp-me' ),
|
1119 |
'<strong>Join.chat</strong>',
|
admin/css/joinchat.css
CHANGED
@@ -157,14 +157,17 @@ tr.joinchat--focus .joinchat_vars_help {
|
|
157 |
|
158 |
/* Help */
|
159 |
|
|
|
160 |
.settings_page_joinchat .help-tab-content li ul {
|
161 |
margin-top: 6px;
|
162 |
}
|
163 |
|
|
|
164 |
.settings_page_joinchat .help-tab-content li li {
|
165 |
list-style-type: circle;
|
166 |
}
|
167 |
|
|
|
168 |
.settings_page_joinchat .help-tab-content code {
|
169 |
-webkit-user-select: all;
|
170 |
-moz-user-select: all;
|
@@ -217,4 +220,4 @@ tr.joinchat--focus .joinchat_vars_help {
|
|
217 |
.js .joinchat-metabox textarea {
|
218 |
overflow: hidden;
|
219 |
min-height: 3em;
|
220 |
-
}
|
157 |
|
158 |
/* Help */
|
159 |
|
160 |
+
.toplevel_page_joinchat .help-tab-content li ul,
|
161 |
.settings_page_joinchat .help-tab-content li ul {
|
162 |
margin-top: 6px;
|
163 |
}
|
164 |
|
165 |
+
.toplevel_page_joinchat .help-tab-content li li,
|
166 |
.settings_page_joinchat .help-tab-content li li {
|
167 |
list-style-type: circle;
|
168 |
}
|
169 |
|
170 |
+
.toplevel_page_joinchat .help-tab-content code,
|
171 |
.settings_page_joinchat .help-tab-content code {
|
172 |
-webkit-user-select: all;
|
173 |
-moz-user-select: all;
|
220 |
.js .joinchat-metabox textarea {
|
221 |
overflow: hidden;
|
222 |
min-height: 3em;
|
223 |
+
}
|
admin/css/joinchat.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
.joinchat-hidden{display:none !important}.js #joinchat_form textarea{overflow:hidden;min-height:100px}.joinchat-tab{display:none}.joinchat-tab-active{display:block !important}#joinchat_tab_visibility tr:hover{background:rgba(0,0,0,.05)}#joinchat_tab_visibility th,#joinchat_tab_visibility td{padding:7px 15px}#joinchat_tab_visibility label{margin-right:15px}#joinchat_tab_visibility .dashicons{opacity:.5}#joinchat_tab_visibility input[type=radio]+span{transition:all 200ms}#joinchat_tab_visibility input[type=radio]:checked+span{color:#79ba49;opacity:1}#joinchat_tab_visibility input[type=radio]:checked+.dashicons-hidden{color:#ca4a1f}.joinchat-show-help{display:inline-block;width:1.1em;height:1.1em;line-height:1.1em;border-radius:50%;background:#999;color:#fff;font-weight:bold;text-decoration:none;text-align:center}.joinchat-show-help:hover,.joinchat-show-help:active,.joinchat-show-help:focus{background:#444;color:#fff}#tab-panel-styles-and-vars span{white-space:nowrap}.form-table td p.joinchat-addon{display:inline-block;padding:0 6px;border-radius:3px;background:#fffbe5;font-size:13px}.iti--allow-dropdown input{padding-left:52px !important}#joinchat_button_image_wrapper{position:relative;padding:8px 0 0 80px}#joinchat_button_image_holder{position:absolute;top:0;left:0;box-sizing:border-box;width:60px;height:60px;border:1px solid #25d366;border-radius:50%;background:#25d366 url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="36" height="36"><path fill="%23fff" d="M3.516 3.516c4.686-4.686 12.284-4.686 16.97 0 4.686 4.686 4.686 12.283 0 16.97a12.004 12.004 0 01-13.754 2.299l-5.814.735a.392.392 0 01-.438-.44l.748-5.788A12.002 12.002 0 013.517 3.517zm3.61 17.043l.3.158a9.846 9.846 0 0011.534-1.758c3.843-3.843 3.843-10.074 0-13.918-3.843-3.843-10.075-3.843-13.918 0a9.846 9.846 0 00-1.747 11.554l.16.303-.51 3.942a.196.196 0 00.219.22l3.961-.501zm6.534-7.003l-.933 1.164a9.843 9.843 0 01-3.497-3.495l1.166-.933a.792.792 0 00.23-.94L9.561 6.96a.793.793 0 00-.924-.445 1291.6 1291.6 0 00-2.023.524.797.797 0 00-.588.88 11.754 11.754 0 0010.005 10.005.797.797 0 00.88-.587l.525-2.023a.793.793 0 00-.445-.923L14.6 13.327a.792.792 0 00-.94.23z"/></svg>') no-repeat center;box-shadow:1px 6px 24px 0 rgba(7,94,84,.24);overflow:hidden}[dir=rtl] #joinchat_button_image_wrapper{padding:8px 80px 0 0}[dir=rtl] #joinchat_button_image_holder{right:0;left:auto}.joinchat_vars_help{margin-top:5px;font-size:11px;font-weight:normal;line-height:1.9;opacity:0;transition:opacity .2s ease-out .2s}tr:hover .joinchat_vars_help,tr.joinchat--focus .joinchat_vars_help{opacity:1;transition-delay:.5s}.joinchat_vars_help code{-webkit-user-select:all;-moz-user-select:all;-ms-user-select:all;user-select:all;padding:2px 1px;font-size:inherit;vertical-align:bottom}.joinchat_vars_help code:hover{background:rgba(0,0,0,0.2)}@media screen and (max-width:782px){.joinchat_vars_help{margin-top:2px;opacity:1}.joinchat_vars_help br{display:none}}#joinchat_form .iris-picker{visibility:visible}.settings_page_joinchat .help-tab-content li ul{margin-top:6px}.settings_page_joinchat .help-tab-content li li{list-style-type:circle}.settings_page_joinchat .help-tab-content code{-webkit-user-select:all;-moz-user-select:all;-ms-user-select:all;user-select:all}.joinchat-metabox code{-webkit-user-select:all;-moz-user-select:all;-ms-user-select:all;user-select:all;padding:2px 1px;font-size:smaller;vertical-align:text-bottom}.joinchat-metabox .dashicons{opacity:.5}.joinchat-metabox input::placeholder{color:#dedfe0}.joinchat-metabox input::-ms-input-placeholder{color:#dedfe0}.joinchat-metabox input[type=radio]{margin-right:1px}.joinchat-metabox input[type=radio]+span{margin-right:5px;transition:all 200ms}.joinchat-metabox input[type=radio]:checked+span{color:#79ba49;opacity:1}.joinchat-metabox input[type=radio]:checked+.dashicons-hidden{color:#ca4a1f}.js .joinchat-metabox textarea{overflow:hidden;min-height:3em}
|
1 |
+
.joinchat-hidden{display:none !important}.js #joinchat_form textarea{overflow:hidden;min-height:100px}.joinchat-tab{display:none}.joinchat-tab-active{display:block !important}#joinchat_tab_visibility tr:hover{background:rgba(0,0,0,.05)}#joinchat_tab_visibility th,#joinchat_tab_visibility td{padding:7px 15px}#joinchat_tab_visibility label{margin-right:15px}#joinchat_tab_visibility .dashicons{opacity:.5}#joinchat_tab_visibility input[type=radio]+span{transition:all 200ms}#joinchat_tab_visibility input[type=radio]:checked+span{color:#79ba49;opacity:1}#joinchat_tab_visibility input[type=radio]:checked+.dashicons-hidden{color:#ca4a1f}.joinchat-show-help{display:inline-block;width:1.1em;height:1.1em;line-height:1.1em;border-radius:50%;background:#999;color:#fff;font-weight:bold;text-decoration:none;text-align:center}.joinchat-show-help:hover,.joinchat-show-help:active,.joinchat-show-help:focus{background:#444;color:#fff}#tab-panel-styles-and-vars span{white-space:nowrap}.form-table td p.joinchat-addon{display:inline-block;padding:0 6px;border-radius:3px;background:#fffbe5;font-size:13px}.iti--allow-dropdown input{padding-left:52px !important}#joinchat_button_image_wrapper{position:relative;padding:8px 0 0 80px}#joinchat_button_image_holder{position:absolute;top:0;left:0;box-sizing:border-box;width:60px;height:60px;border:1px solid #25d366;border-radius:50%;background:#25d366 url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="36" height="36"><path fill="%23fff" d="M3.516 3.516c4.686-4.686 12.284-4.686 16.97 0 4.686 4.686 4.686 12.283 0 16.97a12.004 12.004 0 01-13.754 2.299l-5.814.735a.392.392 0 01-.438-.44l.748-5.788A12.002 12.002 0 013.517 3.517zm3.61 17.043l.3.158a9.846 9.846 0 0011.534-1.758c3.843-3.843 3.843-10.074 0-13.918-3.843-3.843-10.075-3.843-13.918 0a9.846 9.846 0 00-1.747 11.554l.16.303-.51 3.942a.196.196 0 00.219.22l3.961-.501zm6.534-7.003l-.933 1.164a9.843 9.843 0 01-3.497-3.495l1.166-.933a.792.792 0 00.23-.94L9.561 6.96a.793.793 0 00-.924-.445 1291.6 1291.6 0 00-2.023.524.797.797 0 00-.588.88 11.754 11.754 0 0010.005 10.005.797.797 0 00.88-.587l.525-2.023a.793.793 0 00-.445-.923L14.6 13.327a.792.792 0 00-.94.23z"/></svg>') no-repeat center;box-shadow:1px 6px 24px 0 rgba(7,94,84,.24);overflow:hidden}[dir=rtl] #joinchat_button_image_wrapper{padding:8px 80px 0 0}[dir=rtl] #joinchat_button_image_holder{right:0;left:auto}.joinchat_vars_help{margin-top:5px;font-size:11px;font-weight:normal;line-height:1.9;opacity:0;transition:opacity .2s ease-out .2s}tr:hover .joinchat_vars_help,tr.joinchat--focus .joinchat_vars_help{opacity:1;transition-delay:.5s}.joinchat_vars_help code{-webkit-user-select:all;-moz-user-select:all;-ms-user-select:all;user-select:all;padding:2px 1px;font-size:inherit;vertical-align:bottom}.joinchat_vars_help code:hover{background:rgba(0,0,0,0.2)}@media screen and (max-width:782px){.joinchat_vars_help{margin-top:2px;opacity:1}.joinchat_vars_help br{display:none}}#joinchat_form .iris-picker{visibility:visible}.toplevel_page_joinchat .help-tab-content li ul,.settings_page_joinchat .help-tab-content li ul{margin-top:6px}.toplevel_page_joinchat .help-tab-content li li,.settings_page_joinchat .help-tab-content li li{list-style-type:circle}.toplevel_page_joinchat .help-tab-content code,.settings_page_joinchat .help-tab-content code{-webkit-user-select:all;-moz-user-select:all;-ms-user-select:all;user-select:all}.joinchat-metabox code{-webkit-user-select:all;-moz-user-select:all;-ms-user-select:all;user-select:all;padding:2px 1px;font-size:smaller;vertical-align:text-bottom}.joinchat-metabox .dashicons{opacity:.5}.joinchat-metabox input::placeholder{color:#dedfe0}.joinchat-metabox input::-ms-input-placeholder{color:#dedfe0}.joinchat-metabox input[type=radio]{margin-right:1px}.joinchat-metabox input[type=radio]+span{margin-right:5px;transition:all 200ms}.joinchat-metabox input[type=radio]:checked+span{color:#79ba49;opacity:1}.joinchat-metabox input[type=radio]:checked+.dashicons-hidden{color:#ca4a1f}.js .joinchat-metabox textarea{overflow:hidden;min-height:3em}
|
includes/class-joinchat-common.php
ADDED
@@ -0,0 +1,78 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* Fornt and Back Common class.
|
5 |
+
*
|
6 |
+
* @since 4.2.0
|
7 |
+
* @package JoinChat
|
8 |
+
* @subpackage JoinChat/includes
|
9 |
+
* @author Creame <hola@crea.me>
|
10 |
+
*/
|
11 |
+
class JoinChatCommon {
|
12 |
+
|
13 |
+
/**
|
14 |
+
* Initialize the class.
|
15 |
+
*
|
16 |
+
* @since 4.2.0
|
17 |
+
*/
|
18 |
+
public function __construct() {}
|
19 |
+
|
20 |
+
/**
|
21 |
+
* Return the default settings.
|
22 |
+
*
|
23 |
+
* @since 4.2.0
|
24 |
+
* @return array
|
25 |
+
*/
|
26 |
+
public function default_settings() {
|
27 |
+
|
28 |
+
$defaults = array(
|
29 |
+
'telephone' => '',
|
30 |
+
'mobile_only' => 'no',
|
31 |
+
'button_image' => '',
|
32 |
+
'button_tip' => '',
|
33 |
+
'button_delay' => 3,
|
34 |
+
'whatsapp_web' => 'no',
|
35 |
+
'message_text' => '',
|
36 |
+
'message_views' => 2,
|
37 |
+
'message_delay' => 10,
|
38 |
+
'message_badge' => 'no',
|
39 |
+
'message_send' => '',
|
40 |
+
'message_start' => __( 'Open chat', 'creame-whatsapp-me' ),
|
41 |
+
'position' => 'right',
|
42 |
+
'visibility' => array( 'all' => 'yes' ),
|
43 |
+
'color' => '#25d366',
|
44 |
+
'dark_mode' => 'no',
|
45 |
+
'header' => '__jc__', // values: '__jc__', '__wa__' or other custom text
|
46 |
+
);
|
47 |
+
|
48 |
+
return array_merge( $defaults, apply_filters( 'joinchat_extra_settings', array() ) );
|
49 |
+
|
50 |
+
}
|
51 |
+
|
52 |
+
/**
|
53 |
+
* Load saved settings.
|
54 |
+
*
|
55 |
+
* @since 4.2.0
|
56 |
+
* @return array
|
57 |
+
*/
|
58 |
+
public function load_settings() {
|
59 |
+
|
60 |
+
$default_settings = $this->default_settings();
|
61 |
+
|
62 |
+
// Can hook 'option_joinchat' and 'default_option_joinchat' filters
|
63 |
+
$settings = array_merge( $default_settings, (array) get_option( 'joinchat', $default_settings ) );
|
64 |
+
|
65 |
+
// Migrate addons 'remove_brand' setting to 'header' (v. < 4.1)
|
66 |
+
if ( isset( $settings['remove_brand'] ) ) {
|
67 |
+
$remove = $settings['remove_brand'];
|
68 |
+
$settings['header'] = 'wa' == $remove ? '__wa__' : ( 'no' == $remove ? '__jc__' : '' );
|
69 |
+
}
|
70 |
+
|
71 |
+
// Clean unused saved settings
|
72 |
+
$settings = array_intersect_key( $settings, $default_settings );
|
73 |
+
|
74 |
+
return $settings;
|
75 |
+
|
76 |
+
}
|
77 |
+
|
78 |
+
}
|
includes/class-joinchat-elementor-finder.php
CHANGED
@@ -22,6 +22,18 @@ class JoinChatElementorFinder extends \Elementor\Core\Common\Modules\Finder\Base
|
|
22 |
|
23 |
}
|
24 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
/**
|
26 |
* Get category items.
|
27 |
*
|
@@ -31,26 +43,24 @@ class JoinChatElementorFinder extends \Elementor\Core\Common\Modules\Finder\Base
|
|
31 |
*/
|
32 |
public function get_category_items( array $options = array() ) {
|
33 |
|
34 |
-
$settings_url = admin_url( 'options-general.php' ) . '?page=joinchat';
|
35 |
-
|
36 |
$items = array(
|
37 |
'general' => array(
|
38 |
'title' => _x( 'General Settings', 'Title in Elementor Finder', 'creame-whatsapp-me' ),
|
39 |
-
'url' =>
|
40 |
'icon' => 'settings',
|
41 |
'keywords' => explode( ',', 'joinchat,whatsapp,' . _x( 'settings,phone', 'Keywords in Elementor Finder', 'creame-whatsapp-me' ) ),
|
42 |
'description' => __( 'Join.chat settings page', 'creame-whatsapp-me' ),
|
43 |
),
|
44 |
'visibility' => array(
|
45 |
'title' => _x( 'Visibility Settings', 'Title in Elementor Finder', 'creame-whatsapp-me' ),
|
46 |
-
'url' =>
|
47 |
'icon' => 'eye',
|
48 |
'keywords' => explode( ',', 'joinchat,whatsapp,' . _x( 'visibility,show,hide', 'Keywords in Elementor Finder', 'creame-whatsapp-me' ) ),
|
49 |
'description' => __( 'Join.chat settings page', 'creame-whatsapp-me' ),
|
50 |
),
|
51 |
);
|
52 |
|
53 |
-
return apply_filters( 'joinchat_elementor_finder_items', $items
|
54 |
|
55 |
}
|
56 |
|
22 |
|
23 |
}
|
24 |
|
25 |
+
/**
|
26 |
+
* Get category id.
|
27 |
+
*
|
28 |
+
* @since 4.2.0
|
29 |
+
* @return string
|
30 |
+
*/
|
31 |
+
public function get_id() {
|
32 |
+
|
33 |
+
return 'joinchat';
|
34 |
+
|
35 |
+
}
|
36 |
+
|
37 |
/**
|
38 |
* Get category items.
|
39 |
*
|
43 |
*/
|
44 |
public function get_category_items( array $options = array() ) {
|
45 |
|
|
|
|
|
46 |
$items = array(
|
47 |
'general' => array(
|
48 |
'title' => _x( 'General Settings', 'Title in Elementor Finder', 'creame-whatsapp-me' ),
|
49 |
+
'url' => JoinChatUtil::admin_url(),
|
50 |
'icon' => 'settings',
|
51 |
'keywords' => explode( ',', 'joinchat,whatsapp,' . _x( 'settings,phone', 'Keywords in Elementor Finder', 'creame-whatsapp-me' ) ),
|
52 |
'description' => __( 'Join.chat settings page', 'creame-whatsapp-me' ),
|
53 |
),
|
54 |
'visibility' => array(
|
55 |
'title' => _x( 'Visibility Settings', 'Title in Elementor Finder', 'creame-whatsapp-me' ),
|
56 |
+
'url' => add_query_arg( 'tab', 'visibility', JoinChatUtil::admin_url() ),
|
57 |
'icon' => 'eye',
|
58 |
'keywords' => explode( ',', 'joinchat,whatsapp,' . _x( 'visibility,show,hide', 'Keywords in Elementor Finder', 'creame-whatsapp-me' ) ),
|
59 |
'description' => __( 'Join.chat settings page', 'creame-whatsapp-me' ),
|
60 |
),
|
61 |
);
|
62 |
|
63 |
+
return apply_filters( 'joinchat_elementor_finder_items', $items );
|
64 |
|
65 |
}
|
66 |
|
includes/class-joinchat-i18n.php
CHANGED
@@ -13,6 +13,24 @@
|
|
13 |
*/
|
14 |
class JoinChat_i18n {
|
15 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
16 |
/**
|
17 |
* Load the plugin text domain for translation.
|
18 |
*
|
@@ -24,4 +42,117 @@ class JoinChat_i18n {
|
|
24 |
|
25 |
}
|
26 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
27 |
}
|
13 |
*/
|
14 |
class JoinChat_i18n {
|
15 |
|
16 |
+
/**
|
17 |
+
* Initialize the class.
|
18 |
+
*
|
19 |
+
* @since 4.2.0
|
20 |
+
*/
|
21 |
+
public function __construct( $loader ) {
|
22 |
+
|
23 |
+
// No delegate to $loader, use WordPress add_action
|
24 |
+
add_action( 'init', array( $this, 'load_plugin_textdomain' ) );
|
25 |
+
|
26 |
+
if ( defined( 'WPML_PLUGIN_PATH' ) || defined( 'POLYLANG_VERSION' ) ) {
|
27 |
+
|
28 |
+
$loader->add_action( 'joinchat_settings_validation', $this, 'settings_save', 10, 2 );
|
29 |
+
$loader->add_filter( 'joinchat_get_settings_site', $this, 'settings_load' );
|
30 |
+
|
31 |
+
}
|
32 |
+
}
|
33 |
+
|
34 |
/**
|
35 |
* Load the plugin text domain for translation.
|
36 |
*
|
42 |
|
43 |
}
|
44 |
|
45 |
+
/**
|
46 |
+
* Return list of settings that can be translated
|
47 |
+
*
|
48 |
+
* Note: don't translate string labels to prevent missing translations if
|
49 |
+
* public front lang is different of admin lang
|
50 |
+
*
|
51 |
+
* @since 4.2 (before this was in JoinChatUtil)
|
52 |
+
* @access private
|
53 |
+
* @param null|array $settings
|
54 |
+
* @return array setting keys and string names
|
55 |
+
*/
|
56 |
+
private function settings_i18n( $settings = null ) {
|
57 |
+
|
58 |
+
$localized = array(
|
59 |
+
'telephone' => 'Telephone',
|
60 |
+
'button_tip' => 'Tooltip',
|
61 |
+
'message_text' => 'Call to Action',
|
62 |
+
'message_send' => 'Message',
|
63 |
+
'message_start' => 'Button Text',
|
64 |
+
);
|
65 |
+
|
66 |
+
if ( isset( $settings['header'] ) && ! in_array( $settings['header'], array( '', '__jc__', '__wa__' ) ) ) {
|
67 |
+
$localized['header'] = 'Header';
|
68 |
+
}
|
69 |
+
|
70 |
+
return apply_filters( 'joinchat_settings_i18n', $localized, $settings );
|
71 |
+
|
72 |
+
}
|
73 |
+
|
74 |
+
/**
|
75 |
+
* Register strings for translation
|
76 |
+
*
|
77 |
+
* Register traslatable fields and show notice if has changes.
|
78 |
+
* view: https://wpml.org/wpml-hook/wpml_register_single_string/
|
79 |
+
*
|
80 |
+
* @since 4.2
|
81 |
+
* @param array $settings
|
82 |
+
* @param array $old_settings
|
83 |
+
* @return void
|
84 |
+
*/
|
85 |
+
public function settings_save( $settings, $old_settings ) {
|
86 |
+
|
87 |
+
$settings_i18n = $this->settings_i18n( $settings );
|
88 |
+
$default_language = apply_filters( 'wpml_default_language', null );
|
89 |
+
$translate_notice = false;
|
90 |
+
|
91 |
+
foreach ( $settings_i18n as $key => $label ) {
|
92 |
+
$value = isset( $settings[ $key ] ) ? $settings[ $key ] : '';
|
93 |
+
do_action( 'wpml_register_single_string', 'Join.chat', $label, $value, false, $default_language );
|
94 |
+
|
95 |
+
if ( isset( $old_settings[ $key ] ) && $old_settings[ $key ] !== $value ) {
|
96 |
+
$translate_notice = true;
|
97 |
+
}
|
98 |
+
}
|
99 |
+
|
100 |
+
// Show notice with link to string translations
|
101 |
+
if ( $translate_notice ) {
|
102 |
+
|
103 |
+
if ( defined( 'WPML_PLUGIN_PATH' ) ) {
|
104 |
+
$link = add_query_arg(
|
105 |
+
array(
|
106 |
+
'page' => 'wpml-string-translation/menu/string-translation.php',
|
107 |
+
'context' => 'Join.chat',
|
108 |
+
),
|
109 |
+
admin_url( 'admin.php' )
|
110 |
+
);
|
111 |
+
} else {
|
112 |
+
$link = add_query_arg(
|
113 |
+
array(
|
114 |
+
'page' => 'mlang_strings',
|
115 |
+
'group' => 'Join.chat',
|
116 |
+
'lang' => 'all',
|
117 |
+
),
|
118 |
+
admin_url( 'admin.php' )
|
119 |
+
);
|
120 |
+
}
|
121 |
+
|
122 |
+
// Note: message is wrapped with <strong>...</strong> tags
|
123 |
+
$message = sprintf(
|
124 |
+
'%s</strong> %s <strong><a href="%s">%s</a>',
|
125 |
+
sprintf( __( 'Default site language (%s)', 'creame-whatsapp-me' ), strtoupper( $default_language ) ),
|
126 |
+
__( 'There are changes in fields that can be translated.', 'creame-whatsapp-me' ),
|
127 |
+
esc_url( $link ),
|
128 |
+
__( 'Check translations', 'creame-whatsapp-me' )
|
129 |
+
);
|
130 |
+
|
131 |
+
add_settings_error( 'joinchat', 'review_i18n', $message, 'info' );
|
132 |
+
|
133 |
+
}
|
134 |
+
|
135 |
+
}
|
136 |
+
|
137 |
+
/**
|
138 |
+
* Get settings translations for current language
|
139 |
+
*
|
140 |
+
* @since 4.2
|
141 |
+
* @param array $settings
|
142 |
+
* @return array
|
143 |
+
*/
|
144 |
+
public function settings_load( $settings ) {
|
145 |
+
|
146 |
+
$settings_i18n = $this->settings_i18n( $settings );
|
147 |
+
|
148 |
+
foreach ( $settings_i18n as $key => $label ) {
|
149 |
+
if ( isset( $settings[ $key ] ) ) {
|
150 |
+
$settings[ $key ] = apply_filters( 'wpml_translate_single_string', $settings[ $key ], 'Join.chat', $label );
|
151 |
+
}
|
152 |
+
}
|
153 |
+
|
154 |
+
return $settings;
|
155 |
+
|
156 |
+
}
|
157 |
+
|
158 |
}
|
includes/class-joinchat-integrations.php
CHANGED
@@ -86,7 +86,11 @@ class JoinChatIntegrations {
|
|
86 |
|
87 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-elementor-finder.php';
|
88 |
|
89 |
-
|
|
|
|
|
|
|
|
|
90 |
|
91 |
}
|
92 |
|
@@ -98,11 +102,11 @@ class JoinChatIntegrations {
|
|
98 |
* @param string $settings_url Join.chat settings base url
|
99 |
* @return array
|
100 |
*/
|
101 |
-
public function elementor_finder_woocommerce_item( $items
|
102 |
|
103 |
$items['woocommerce'] = array(
|
104 |
'title' => _x( 'WooCommerce Settings', 'Title in Elementor Finder', 'creame-whatsapp-me' ),
|
105 |
-
'url' =>
|
106 |
'icon' => 'woocommerce',
|
107 |
'keywords' => explode( ',', 'joinchat,whatsapp,' . _x( 'woocommerce,shop,product', 'Keywords in Elementor Finder', 'creame-whatsapp-me' ) ),
|
108 |
'description' => __( 'Join.chat settings page', 'creame-whatsapp-me' ),
|
86 |
|
87 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-elementor-finder.php';
|
88 |
|
89 |
+
if ( version_compare( ELEMENTOR_VERSION, '3.5.0', '>=' ) ) {
|
90 |
+
$categories_manager->register( new JoinChatElementorFinder() );
|
91 |
+
} else {
|
92 |
+
$categories_manager->add_category( 'joinchat', new JoinChatElementorFinder() );
|
93 |
+
}
|
94 |
|
95 |
}
|
96 |
|
102 |
* @param string $settings_url Join.chat settings base url
|
103 |
* @return array
|
104 |
*/
|
105 |
+
public function elementor_finder_woocommerce_item( $items ) {
|
106 |
|
107 |
$items['woocommerce'] = array(
|
108 |
'title' => _x( 'WooCommerce Settings', 'Title in Elementor Finder', 'creame-whatsapp-me' ),
|
109 |
+
'url' => add_query_arg( 'tab', 'woocommerce', JoinChatUtil::admin_url() ),
|
110 |
'icon' => 'woocommerce',
|
111 |
'keywords' => explode( ',', 'joinchat,whatsapp,' . _x( 'woocommerce,shop,product', 'Keywords in Elementor Finder', 'creame-whatsapp-me' ) ),
|
112 |
'description' => __( 'Join.chat settings page', 'creame-whatsapp-me' ),
|
includes/class-joinchat-util.php
CHANGED
@@ -12,36 +12,6 @@
|
|
12 |
*/
|
13 |
class JoinChatUtil {
|
14 |
|
15 |
-
/**
|
16 |
-
* Return list of settings that can be translated
|
17 |
-
*
|
18 |
-
* Note: don't translate string $name to prevent missing translations if
|
19 |
-
* public front lang is different of admin lang
|
20 |
-
*
|
21 |
-
* @since 3.1.2
|
22 |
-
* @since 4.1 added optional param $settings
|
23 |
-
* @access public
|
24 |
-
* @param null|array $settings
|
25 |
-
* @return array setting keys and string names
|
26 |
-
*/
|
27 |
-
public static function settings_i18n( $settings = null ) {
|
28 |
-
|
29 |
-
$localized = array(
|
30 |
-
'telephone' => 'Telephone',
|
31 |
-
'button_tip' => 'Tooltip',
|
32 |
-
'message_text' => 'Call to Action',
|
33 |
-
'message_send' => 'Message',
|
34 |
-
'message_start' => 'Button Text',
|
35 |
-
);
|
36 |
-
|
37 |
-
if ( isset( $settings['header'] ) && ! in_array( $settings['header'], array( '', '__jc__', '__wa__' ) ) ) {
|
38 |
-
$localized['header'] = 'Header';
|
39 |
-
}
|
40 |
-
|
41 |
-
return apply_filters( 'joinchat_settings_i18n', $localized, $settings );
|
42 |
-
|
43 |
-
}
|
44 |
-
|
45 |
/**
|
46 |
* Clean user input fields
|
47 |
*
|
@@ -245,7 +215,7 @@ class JoinChatUtil {
|
|
245 |
|
246 |
if ( is_home() || is_singular() ) {
|
247 |
$title = single_post_title( '', false );
|
248 |
-
} elseif ( is_tax() ) {
|
249 |
$title = single_term_title( '', false );
|
250 |
} elseif ( function_exists( 'wp_get_document_title' ) ) {
|
251 |
$title = wp_get_document_title();
|
@@ -278,4 +248,43 @@ class JoinChatUtil {
|
|
278 |
return json_encode( $data, apply_filters( 'joinchat_json_options', $json_options ) );
|
279 |
|
280 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
281 |
}
|
12 |
*/
|
13 |
class JoinChatUtil {
|
14 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
/**
|
16 |
* Clean user input fields
|
17 |
*
|
215 |
|
216 |
if ( is_home() || is_singular() ) {
|
217 |
$title = single_post_title( '', false );
|
218 |
+
} elseif ( is_category() || is_tag() || is_tax() ) {
|
219 |
$title = single_term_title( '', false );
|
220 |
} elseif ( function_exists( 'wp_get_document_title' ) ) {
|
221 |
$title = wp_get_document_title();
|
248 |
return json_encode( $data, apply_filters( 'joinchat_json_options', $json_options ) );
|
249 |
|
250 |
}
|
251 |
+
|
252 |
+
/**
|
253 |
+
* Return required capability to change settings
|
254 |
+
*
|
255 |
+
* Default capability 'manage_options'
|
256 |
+
*
|
257 |
+
* @since 4.2.0
|
258 |
+
* @param string $capability
|
259 |
+
* @return string
|
260 |
+
*/
|
261 |
+
public static function capability( $capability = '' ) {
|
262 |
+
|
263 |
+
return apply_filters( 'joinchat_capability', $capability ?: 'manage_options' );
|
264 |
+
|
265 |
+
}
|
266 |
+
|
267 |
+
/**
|
268 |
+
* Plugin admin page is in options submenu
|
269 |
+
*
|
270 |
+
* @since 4.2.0
|
271 |
+
* @return bool
|
272 |
+
*/
|
273 |
+
public static function options_submenu() {
|
274 |
+
|
275 |
+
return apply_filters( 'joinchat_submenu', 'manage_options' === self::capability() );
|
276 |
+
|
277 |
+
}
|
278 |
+
|
279 |
+
/**
|
280 |
+
* Plugin admin page url
|
281 |
+
*
|
282 |
+
* @since 4.2.0
|
283 |
+
* @return string
|
284 |
+
*/
|
285 |
+
public static function admin_url() {
|
286 |
+
|
287 |
+
return admin_url( self::options_submenu() ? 'options-general.php' : 'admin.php' ) . '?page=joinchat';
|
288 |
+
|
289 |
+
}
|
290 |
}
|
includes/class-joinchat.php
CHANGED
@@ -94,6 +94,7 @@ class JoinChat {
|
|
94 |
private function load_dependencies() {
|
95 |
|
96 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-loader.php';
|
|
|
97 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-i18n.php';
|
98 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-integrations.php';
|
99 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-util.php';
|
@@ -114,10 +115,7 @@ class JoinChat {
|
|
114 |
*/
|
115 |
private function set_locale() {
|
116 |
|
117 |
-
$plugin_i18n = new JoinChat_i18n();
|
118 |
-
|
119 |
-
// No delegate to $this->loader, use WordPress add_action
|
120 |
-
add_action( 'init', array( $plugin_i18n, 'load_plugin_textdomain' ) );
|
121 |
|
122 |
}
|
123 |
|
@@ -157,15 +155,19 @@ class JoinChat {
|
|
157 |
$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'register_styles' );
|
158 |
$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'register_scripts' );
|
159 |
$this->loader->add_action( 'admin_menu', $plugin_admin, 'add_menu' );
|
|
|
160 |
$this->loader->add_action( 'add_meta_boxes', $plugin_admin, 'add_meta_boxes' );
|
161 |
$this->loader->add_action( 'save_post', $plugin_admin, 'save_post' );
|
162 |
$this->loader->add_action( 'load-settings_page_joinchat', $plugin_admin, 'help_tab' );
|
|
|
163 |
$this->loader->add_action( 'update_option_joinchat', $plugin_admin, 'clear_cache', 100 );
|
164 |
|
165 |
$this->loader->add_filter( 'plugin_action_links_' . JOINCHAT_BASENAME, $plugin_admin, 'settings_link' );
|
166 |
$this->loader->add_filter( 'plugin_row_meta', $plugin_admin, 'plugin_links', 10, 2 );
|
167 |
$this->loader->add_filter( 'admin_footer_text', $plugin_admin, 'admin_footer_text', PHP_INT_MAX );
|
168 |
|
|
|
|
|
169 |
}
|
170 |
|
171 |
/**
|
94 |
private function load_dependencies() {
|
95 |
|
96 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-loader.php';
|
97 |
+
require_once JOINCHAT_DIR . 'includes/class-joinchat-common.php';
|
98 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-i18n.php';
|
99 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-integrations.php';
|
100 |
require_once JOINCHAT_DIR . 'includes/class-joinchat-util.php';
|
115 |
*/
|
116 |
private function set_locale() {
|
117 |
|
118 |
+
$plugin_i18n = new JoinChat_i18n( $this->loader );
|
|
|
|
|
|
|
119 |
|
120 |
}
|
121 |
|
155 |
$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'register_styles' );
|
156 |
$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'register_scripts' );
|
157 |
$this->loader->add_action( 'admin_menu', $plugin_admin, 'add_menu' );
|
158 |
+
$this->loader->add_action( 'admin_notices', $plugin_admin, 'notices' );
|
159 |
$this->loader->add_action( 'add_meta_boxes', $plugin_admin, 'add_meta_boxes' );
|
160 |
$this->loader->add_action( 'save_post', $plugin_admin, 'save_post' );
|
161 |
$this->loader->add_action( 'load-settings_page_joinchat', $plugin_admin, 'help_tab' );
|
162 |
+
$this->loader->add_action( 'load-toplevel_page_joinchat', $plugin_admin, 'help_tab' );
|
163 |
$this->loader->add_action( 'update_option_joinchat', $plugin_admin, 'clear_cache', 100 );
|
164 |
|
165 |
$this->loader->add_filter( 'plugin_action_links_' . JOINCHAT_BASENAME, $plugin_admin, 'settings_link' );
|
166 |
$this->loader->add_filter( 'plugin_row_meta', $plugin_admin, 'plugin_links', 10, 2 );
|
167 |
$this->loader->add_filter( 'admin_footer_text', $plugin_admin, 'admin_footer_text', PHP_INT_MAX );
|
168 |
|
169 |
+
$this->loader->add_filter( 'option_page_capability_joinchat', 'JoinChatUtil', 'capability' );
|
170 |
+
|
171 |
}
|
172 |
|
173 |
/**
|
joinchat.php
CHANGED
@@ -9,7 +9,7 @@
|
|
9 |
* Plugin Name: Join.chat
|
10 |
* Plugin URI: https://join.chat
|
11 |
* Description: Connects a WordPress chat with WhatsApp. The best solution for marketing and support. Stop losing customers and increase your sales.
|
12 |
-
* Version: 4.
|
13 |
* Author: Creame
|
14 |
* Author URI: https://crea.me
|
15 |
* License: GPL-2.0+
|
@@ -26,7 +26,7 @@ if ( ! defined( 'WPINC' ) ) {
|
|
26 |
/**
|
27 |
* Define constants.
|
28 |
*/
|
29 |
-
define( 'JOINCHAT_VERSION', '4.
|
30 |
define( 'JOINCHAT_FILE', __FILE__ );
|
31 |
define( 'JOINCHAT_DIR', plugin_dir_path( JOINCHAT_FILE ) );
|
32 |
define( 'JOINCHAT_BASENAME', plugin_basename( JOINCHAT_FILE ) );
|
9 |
* Plugin Name: Join.chat
|
10 |
* Plugin URI: https://join.chat
|
11 |
* Description: Connects a WordPress chat with WhatsApp. The best solution for marketing and support. Stop losing customers and increase your sales.
|
12 |
+
* Version: 4.2.0
|
13 |
* Author: Creame
|
14 |
* Author URI: https://crea.me
|
15 |
* License: GPL-2.0+
|
26 |
/**
|
27 |
* Define constants.
|
28 |
*/
|
29 |
+
define( 'JOINCHAT_VERSION', '4.2.0' );
|
30 |
define( 'JOINCHAT_FILE', __FILE__ );
|
31 |
define( 'JOINCHAT_DIR', plugin_dir_path( JOINCHAT_FILE ) );
|
32 |
define( 'JOINCHAT_BASENAME', plugin_basename( JOINCHAT_FILE ) );
|
languages/creame-whatsapp-me.pot
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
msgid ""
|
3 |
msgstr ""
|
4 |
"Project-Id-Version: Join.chat\n"
|
5 |
-
"POT-Creation-Date:
|
6 |
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
7 |
"Last-Translator: Your Name <you@example.com>\n"
|
8 |
"Language-Team: Creame <hola@crea.me>\n"
|
@@ -27,7 +27,7 @@ msgid ""
|
|
27 |
"I have a question about *{PRODUCT} ({SKU})*"
|
28 |
msgstr ""
|
29 |
|
30 |
-
#: admin/class-joinchat-admin.php:
|
31 |
msgid "404 Page"
|
32 |
msgstr ""
|
33 |
|
@@ -35,53 +35,53 @@ msgstr ""
|
|
35 |
msgid "<strong>WooCommerce</strong>, in product pages you can also use:"
|
36 |
msgstr ""
|
37 |
|
38 |
-
#: admin/class-joinchat-admin.php:
|
39 |
#, php-format
|
40 |
msgid "Add links, images, videos and more with %s"
|
41 |
msgstr ""
|
42 |
|
43 |
-
#: admin/class-joinchat-admin.php:
|
44 |
#, php-format
|
45 |
msgid "Add unlimited numbers with %1$s or multiple contacts with %2$s"
|
46 |
msgstr ""
|
47 |
|
48 |
-
#: admin/class-joinchat-admin.php:
|
49 |
msgid "Add-ons"
|
50 |
msgstr ""
|
51 |
|
52 |
-
#: admin/class-joinchat-admin.php:
|
53 |
msgid "Adding some CSS classes in your HTML:"
|
54 |
msgstr ""
|
55 |
|
56 |
-
#: admin/class-joinchat-admin.php:
|
57 |
msgid "Archives"
|
58 |
msgstr ""
|
59 |
|
60 |
-
#: admin/class-joinchat-admin.php:
|
61 |
msgid "Author Archives"
|
62 |
msgstr ""
|
63 |
|
64 |
-
#: admin/class-joinchat-admin.php:
|
65 |
msgid "Auto (detects device dark mode)"
|
66 |
msgstr ""
|
67 |
|
68 |
-
#: admin/class-joinchat-admin.php:
|
69 |
msgid "Blog Page"
|
70 |
msgstr ""
|
71 |
|
72 |
-
#: admin/class-joinchat-admin.php:
|
73 |
msgid "Button"
|
74 |
msgstr ""
|
75 |
|
76 |
-
#: admin/class-joinchat-admin.php:
|
77 |
msgid "Button Delay"
|
78 |
msgstr ""
|
79 |
|
80 |
-
#: admin/class-joinchat-admin.php:
|
81 |
msgid "Button Text"
|
82 |
msgstr ""
|
83 |
|
84 |
-
#: admin/class-joinchat-admin.php:
|
85 |
msgid "Call to Action"
|
86 |
msgstr ""
|
87 |
|
@@ -93,7 +93,7 @@ msgstr ""
|
|
93 |
msgid "Call to Action for Products on Sale"
|
94 |
msgstr ""
|
95 |
|
96 |
-
#: admin/class-joinchat-admin.php:
|
97 |
msgid "Can use vars"
|
98 |
msgstr ""
|
99 |
|
@@ -101,22 +101,26 @@ msgstr ""
|
|
101 |
msgid "Cart"
|
102 |
msgstr ""
|
103 |
|
104 |
-
#: admin/class-joinchat-admin.php:
|
105 |
msgid "Chat Delay"
|
106 |
msgstr ""
|
107 |
|
108 |
-
#: admin/class-joinchat-admin.php:
|
109 |
msgid "Chat Window"
|
110 |
msgstr ""
|
111 |
|
112 |
-
#: admin/class-joinchat-admin.php:
|
113 |
msgid "Chat Window auto displays after delay"
|
114 |
msgstr ""
|
115 |
|
116 |
-
#: admin/class-joinchat-admin.php:
|
117 |
msgid "Chat Window auto displays from this number of page views"
|
118 |
msgstr ""
|
119 |
|
|
|
|
|
|
|
|
|
120 |
#: admin/class-joinchat-woo-admin.php:131
|
121 |
msgid "Checkout"
|
122 |
msgstr ""
|
@@ -131,13 +135,13 @@ msgid ""
|
|
131 |
"support. Stop losing customers and increase your sales."
|
132 |
msgstr ""
|
133 |
|
134 |
-
#: admin/class-joinchat-admin.php:
|
135 |
msgid ""
|
136 |
"Contact phone number <strong>(the button will not be shown if it's empty)"
|
137 |
"</strong>"
|
138 |
msgstr ""
|
139 |
|
140 |
-
#: admin/class-joinchat-admin.php:
|
141 |
msgid "Contact us"
|
142 |
msgstr ""
|
143 |
|
@@ -145,23 +149,28 @@ msgstr ""
|
|
145 |
msgid "Creame"
|
146 |
msgstr ""
|
147 |
|
148 |
-
#: admin/class-joinchat-admin.php:
|
149 |
msgid "Custom Post Types"
|
150 |
msgstr ""
|
151 |
|
152 |
-
#: admin/class-joinchat-admin.php:
|
153 |
msgid "Custom:"
|
154 |
msgstr ""
|
155 |
|
156 |
-
#: admin/class-joinchat-admin.php:
|
157 |
msgid "Dark Mode"
|
158 |
msgstr ""
|
159 |
|
160 |
-
#: admin/class-joinchat-admin.php:
|
161 |
msgid "Date Archives"
|
162 |
msgstr ""
|
163 |
|
164 |
-
#:
|
|
|
|
|
|
|
|
|
|
|
165 |
msgid "Default visibility"
|
166 |
msgstr ""
|
167 |
|
@@ -174,34 +183,38 @@ msgstr ""
|
|
174 |
msgid "Define a text for your products to encourage customers to contact"
|
175 |
msgstr ""
|
176 |
|
177 |
-
#: admin/class-joinchat-admin.php:
|
178 |
msgid "Define a text to encourage users to contact by WhatsApp"
|
179 |
msgstr ""
|
180 |
|
181 |
-
#: admin/class-joinchat-admin.php:
|
|
|
|
|
|
|
|
|
182 |
msgid ""
|
183 |
"Display a notification balloon instead of opening the Chat Window for a "
|
184 |
"\"less intrusive\" mode"
|
185 |
msgstr ""
|
186 |
|
187 |
-
#: admin/class-joinchat-admin.php:
|
188 |
#, php-format
|
189 |
msgid "Do you like %1$s? Please help us with a %2$s rating."
|
190 |
msgstr ""
|
191 |
|
192 |
-
#: admin/class-joinchat-admin.php:
|
193 |
msgid "Documentation"
|
194 |
msgstr ""
|
195 |
|
196 |
-
#: admin/class-joinchat-admin.php:
|
197 |
msgid "e.g."
|
198 |
msgstr ""
|
199 |
|
200 |
-
#: admin/class-joinchat-admin.php:
|
201 |
msgid "Example:"
|
202 |
msgstr ""
|
203 |
|
204 |
-
#: admin/class-joinchat-admin.php:
|
205 |
#, php-format
|
206 |
msgid "Follow %s on twitter."
|
207 |
msgstr ""
|
@@ -212,40 +225,40 @@ msgid ""
|
|
212 |
"use:"
|
213 |
msgstr ""
|
214 |
|
215 |
-
#: admin/class-joinchat-admin.php:
|
216 |
msgid ""
|
217 |
"From here you can configure on which pages the WhatsApp button will be "
|
218 |
"visible."
|
219 |
msgstr ""
|
220 |
|
221 |
-
#: admin/class-joinchat-admin.php:
|
222 |
msgid "Front Page"
|
223 |
msgstr ""
|
224 |
|
225 |
-
#: admin/class-joinchat-admin.php:
|
226 |
msgid "General"
|
227 |
msgstr ""
|
228 |
|
229 |
-
#: admin/class-joinchat-admin.php:
|
230 |
msgid "Global"
|
231 |
msgstr ""
|
232 |
|
233 |
-
#: admin/class-joinchat-admin.php:
|
234 |
msgid "Header"
|
235 |
msgstr ""
|
236 |
|
237 |
-
#: admin/class-joinchat-admin.php:
|
238 |
msgid ""
|
239 |
"Hello 👋\n"
|
240 |
"Can we help you?"
|
241 |
msgstr ""
|
242 |
|
243 |
-
#: admin/class-joinchat-admin.php:
|
244 |
msgid "Hi *{SITE}*! I need more info about {TITLE} {URL}"
|
245 |
msgstr ""
|
246 |
|
247 |
-
#: admin/class-joinchat-admin.php:
|
248 |
-
#: admin/class-joinchat-admin.php:
|
249 |
msgid "Hide"
|
250 |
msgstr ""
|
251 |
|
@@ -257,23 +270,23 @@ msgstr ""
|
|
257 |
msgid "https://join.chat"
|
258 |
msgstr ""
|
259 |
|
260 |
-
#: admin/class-joinchat-admin.php:
|
261 |
msgid ""
|
262 |
"If it's defined a \"Call to Action\", the Chat Window can be displayed "
|
263 |
"automatically if conditions are met."
|
264 |
msgstr ""
|
265 |
|
266 |
-
#: admin/class-joinchat-admin.php:
|
267 |
msgid ""
|
268 |
"If you define a \"Call to Action\" a window will be displayed simulating a "
|
269 |
"chat before launching WhatsApp."
|
270 |
msgstr ""
|
271 |
|
272 |
-
#: admin/class-joinchat-admin.php:
|
273 |
msgid "If you like Join.chat 😍"
|
274 |
msgstr ""
|
275 |
|
276 |
-
#: admin/class-joinchat-admin.php:
|
277 |
#, php-format
|
278 |
msgid ""
|
279 |
"If you need help, first review our <a href=\"%1$s\" target=\"_blank\">"
|
@@ -282,49 +295,49 @@ msgid ""
|
|
282 |
"href=\"%3$s\" target=\"_blank\">premium support</a>."
|
283 |
msgstr ""
|
284 |
|
285 |
-
#: admin/class-joinchat-admin.php:
|
286 |
msgid "Image"
|
287 |
msgstr ""
|
288 |
|
289 |
-
#: admin/class-joinchat-admin.php:
|
290 |
msgid "Inherit"
|
291 |
msgstr ""
|
292 |
|
293 |
#. Name of the plugin
|
294 |
-
#: admin/class-joinchat-admin.php:
|
295 |
msgid "Join.chat"
|
296 |
msgstr ""
|
297 |
|
298 |
-
#: admin/class-joinchat-admin.php:
|
299 |
msgid "Join.chat Settings"
|
300 |
msgstr ""
|
301 |
|
302 |
-
#: includes/class-joinchat-elementor-finder.php:
|
303 |
-
#: includes/class-joinchat-elementor-finder.php:
|
304 |
-
#: includes/class-joinchat-integrations.php:
|
305 |
msgid "Join.chat settings page"
|
306 |
msgstr ""
|
307 |
|
308 |
-
#: includes/class-joinchat-elementor-finder.php:
|
309 |
msgctxt "Keywords in Elementor Finder"
|
310 |
msgid "settings,phone"
|
311 |
msgstr ""
|
312 |
|
313 |
-
#: includes/class-joinchat-elementor-finder.php:
|
314 |
msgctxt "Keywords in Elementor Finder"
|
315 |
msgid "visibility,show,hide"
|
316 |
msgstr ""
|
317 |
|
318 |
-
#: includes/class-joinchat-integrations.php:
|
319 |
msgctxt "Keywords in Elementor Finder"
|
320 |
msgid "woocommerce,shop,product"
|
321 |
msgstr ""
|
322 |
|
323 |
-
#: admin/class-joinchat-admin.php:
|
324 |
msgid "Left"
|
325 |
msgstr ""
|
326 |
|
327 |
-
#: admin/class-joinchat-admin.php:
|
328 |
msgid "Message"
|
329 |
msgstr ""
|
330 |
|
@@ -332,7 +345,7 @@ msgstr ""
|
|
332 |
msgid "Message for Products"
|
333 |
msgstr ""
|
334 |
|
335 |
-
#: admin/class-joinchat-admin.php:
|
336 |
msgid "Mobile Only"
|
337 |
msgstr ""
|
338 |
|
@@ -340,58 +353,57 @@ msgstr ""
|
|
340 |
msgid "My Account"
|
341 |
msgstr ""
|
342 |
|
343 |
-
#: admin/class-joinchat-admin.php:
|
344 |
msgid "No"
|
345 |
msgstr ""
|
346 |
|
347 |
-
#: admin/class-joinchat-admin.php:
|
348 |
msgid "Notification Balloon"
|
349 |
msgstr ""
|
350 |
|
351 |
-
#: admin/class-joinchat-admin.php:
|
352 |
msgid "Only display the button on mobile devices"
|
353 |
msgstr ""
|
354 |
|
355 |
-
#: admin/class-joinchat-admin.php:
|
356 |
msgid "only show if it's an not seen CTA."
|
357 |
msgstr ""
|
358 |
|
359 |
-
#: admin/class-joinchat-admin.php:
|
360 |
msgid "Open <em>WhatsApp Web</em> directly on desktop"
|
361 |
msgstr ""
|
362 |
|
363 |
-
#:
|
364 |
-
#: admin/class-joinchat-admin.php:596
|
365 |
msgid "Open chat"
|
366 |
msgstr ""
|
367 |
|
368 |
-
#: admin/class-joinchat-admin.php:
|
369 |
#, php-format
|
370 |
msgid "Other icons and more channels (Telegram, Messenger…) with %s"
|
371 |
msgstr ""
|
372 |
|
373 |
-
#: admin/class-joinchat-admin.php:
|
374 |
msgid "Page"
|
375 |
msgstr ""
|
376 |
|
377 |
-
#: admin/class-joinchat-admin.php:
|
378 |
msgid "Page Title"
|
379 |
msgstr ""
|
380 |
|
381 |
-
#: admin/class-joinchat-admin.php:
|
382 |
msgid "Page Views"
|
383 |
msgstr ""
|
384 |
|
385 |
-
#: admin/class-joinchat-admin.php:
|
386 |
#, php-format
|
387 |
msgid "Please leave us a %s rating. We'll thank you."
|
388 |
msgstr ""
|
389 |
|
390 |
-
#: admin/class-joinchat-admin.php:
|
391 |
msgid "Position on Screen"
|
392 |
msgstr ""
|
393 |
|
394 |
-
#: admin/class-joinchat-admin.php:
|
395 |
msgid "Post"
|
396 |
msgstr ""
|
397 |
|
@@ -399,7 +411,7 @@ msgstr ""
|
|
399 |
msgid "Powered by"
|
400 |
msgstr ""
|
401 |
|
402 |
-
#: admin/class-joinchat-admin.php:
|
403 |
msgid "Powered by Join.chat"
|
404 |
msgstr ""
|
405 |
|
@@ -407,7 +419,7 @@ msgstr ""
|
|
407 |
msgid "Predefined text for the first message the client will send you"
|
408 |
msgstr ""
|
409 |
|
410 |
-
#: admin/class-joinchat-admin.php:
|
411 |
msgid "Predefined text for the first message the user will send you"
|
412 |
msgstr ""
|
413 |
|
@@ -423,15 +435,15 @@ msgstr ""
|
|
423 |
msgid "Product Page"
|
424 |
msgstr ""
|
425 |
|
426 |
-
#: admin/class-joinchat-admin.php:
|
427 |
msgid "Remove"
|
428 |
msgstr ""
|
429 |
|
430 |
-
#: admin/class-joinchat-admin.php:
|
431 |
msgid "Restore default visibility"
|
432 |
msgstr ""
|
433 |
|
434 |
-
#: admin/class-joinchat-admin.php:
|
435 |
msgid "Right"
|
436 |
msgstr ""
|
437 |
|
@@ -442,37 +454,37 @@ msgid ""
|
|
442 |
"If you have any questions, ask us."
|
443 |
msgstr ""
|
444 |
|
445 |
-
#: admin/class-joinchat-admin.php:
|
446 |
msgid "Search Results"
|
447 |
msgstr ""
|
448 |
|
449 |
-
#: admin/class-joinchat-admin.php:
|
450 |
msgid "seconds"
|
451 |
msgstr ""
|
452 |
|
453 |
-
#: admin/class-joinchat-admin.php:
|
454 |
msgid "seconds (0 disabled)"
|
455 |
msgstr ""
|
456 |
|
457 |
-
#: admin/class-joinchat-admin.php:
|
458 |
msgid "Select an image"
|
459 |
msgstr ""
|
460 |
|
461 |
-
#: admin/class-joinchat-admin.php:
|
462 |
msgid "Select button image"
|
463 |
msgstr ""
|
464 |
|
465 |
-
#: admin/class-joinchat-admin.php:
|
466 |
msgid ""
|
467 |
"Set the contact number and where you want the WhatsApp button to be "
|
468 |
"displayed."
|
469 |
msgstr ""
|
470 |
|
471 |
-
#: admin/class-joinchat-admin.php:
|
472 |
msgid "Settings"
|
473 |
msgstr ""
|
474 |
|
475 |
-
#: admin/class-joinchat-admin.php:
|
476 |
msgid "Settings saved"
|
477 |
msgstr ""
|
478 |
|
@@ -480,41 +492,41 @@ msgstr ""
|
|
480 |
msgid "Shop"
|
481 |
msgstr ""
|
482 |
|
483 |
-
#: admin/class-joinchat-admin.php:
|
484 |
msgid "Short text shown next to button"
|
485 |
msgstr ""
|
486 |
|
487 |
-
#: admin/class-joinchat-admin.php:
|
488 |
-
#: admin/class-joinchat-admin.php:
|
489 |
msgid "Show"
|
490 |
msgstr ""
|
491 |
|
492 |
-
#: admin/class-joinchat-admin.php:
|
493 |
msgid "Show Help"
|
494 |
msgstr ""
|
495 |
|
496 |
-
#: admin/class-joinchat-admin.php:
|
497 |
msgid "Singular"
|
498 |
msgstr ""
|
499 |
|
500 |
-
#: admin/class-joinchat-admin.php:
|
501 |
msgid "Styles and Variables"
|
502 |
msgstr ""
|
503 |
|
504 |
-
#: admin/class-joinchat-admin.php:
|
505 |
#, php-format
|
506 |
msgid "Subscribe to our newsletter and visit our blog at %s."
|
507 |
msgstr ""
|
508 |
|
509 |
-
#: admin/class-joinchat-admin.php:
|
510 |
msgid "Support"
|
511 |
msgstr ""
|
512 |
|
513 |
-
#: admin/class-joinchat-admin.php:
|
514 |
msgid "Telephone"
|
515 |
msgstr ""
|
516 |
|
517 |
-
#: admin/class-joinchat-admin.php:
|
518 |
msgid "Text to open chat on Chat Window button"
|
519 |
msgstr ""
|
520 |
|
@@ -522,99 +534,103 @@ msgstr ""
|
|
522 |
msgid "Thank You"
|
523 |
msgstr ""
|
524 |
|
525 |
-
#: admin/class-joinchat-admin.php:
|
526 |
msgid "The image will alternate with button icon"
|
527 |
msgstr ""
|
528 |
|
529 |
-
#: admin/class-joinchat-admin.php:
|
530 |
msgid "Theme Color"
|
531 |
msgstr ""
|
532 |
|
|
|
|
|
|
|
|
|
533 |
#: admin/class-joinchat-woo-admin.php:224
|
534 |
msgid ""
|
535 |
"This *{PRODUCT}* can be yours for only *{PRICE}*!\n"
|
536 |
"If you have any questions, ask us."
|
537 |
msgstr ""
|
538 |
|
539 |
-
#: admin/class-joinchat-admin.php:
|
540 |
msgid "Time since the page is opened until the button is displayed"
|
541 |
msgstr ""
|
542 |
|
543 |
-
#: includes/class-joinchat-elementor-finder.php:
|
544 |
msgctxt "Title in Elementor Finder"
|
545 |
msgid "General Settings"
|
546 |
msgstr ""
|
547 |
|
548 |
-
#: includes/class-joinchat-elementor-finder.php:
|
549 |
msgctxt "Title in Elementor Finder"
|
550 |
msgid "Visibility Settings"
|
551 |
msgstr ""
|
552 |
|
553 |
-
#: includes/class-joinchat-integrations.php:
|
554 |
msgctxt "Title in Elementor Finder"
|
555 |
msgid "WooCommerce Settings"
|
556 |
msgstr ""
|
557 |
|
558 |
-
#: admin/class-joinchat-admin.php:
|
559 |
msgid "to hide Chat Window on click."
|
560 |
msgstr ""
|
561 |
|
562 |
-
#: admin/class-joinchat-admin.php:
|
563 |
msgid "to leave it blank use"
|
564 |
msgstr ""
|
565 |
|
566 |
-
#: admin/class-joinchat-admin.php:
|
567 |
msgid "to open WhatsApp directly on click."
|
568 |
msgstr ""
|
569 |
|
570 |
-
#: admin/class-joinchat-admin.php:
|
571 |
msgid "to show always."
|
572 |
msgstr ""
|
573 |
|
574 |
-
#: admin/class-joinchat-admin.php:
|
575 |
msgid "to show Chat Window (or open WhatsApp if there is no CTA) on click."
|
576 |
msgstr ""
|
577 |
|
578 |
-
#: admin/class-joinchat-admin.php:
|
579 |
msgid ""
|
580 |
"To show Chat Window when an HTML element appears on screen when user scrolls:"
|
581 |
msgstr ""
|
582 |
|
583 |
-
#: admin/class-joinchat-admin.php:
|
584 |
msgid "Tooltip"
|
585 |
msgstr ""
|
586 |
|
587 |
-
#: admin/class-joinchat-admin.php:
|
588 |
msgid "Triggers"
|
589 |
msgstr ""
|
590 |
|
591 |
-
#: public/class-joinchat-public.php:
|
592 |
-
#: admin/class-joinchat-admin.php:
|
593 |
msgctxt "url lang slug (only available for spanish \"es\")"
|
594 |
msgid "en"
|
595 |
msgstr ""
|
596 |
|
597 |
-
#: admin/class-joinchat-admin.php:
|
598 |
msgid "Use image"
|
599 |
msgstr ""
|
600 |
|
601 |
-
#: admin/class-joinchat-admin.php:
|
602 |
msgid "Visibility"
|
603 |
msgstr ""
|
604 |
|
605 |
-
#: admin/class-joinchat-admin.php:
|
606 |
msgid "Visibility Settings"
|
607 |
msgstr ""
|
608 |
|
609 |
-
#: admin/class-joinchat-admin.php:
|
610 |
msgid "WhatsApp Logo"
|
611 |
msgstr ""
|
612 |
|
613 |
-
#: admin/class-joinchat-admin.php:
|
614 |
msgid "WhatsApp Web"
|
615 |
msgstr ""
|
616 |
|
617 |
-
#: admin/class-joinchat-admin.php:
|
618 |
msgid "With anchor links:"
|
619 |
msgstr ""
|
620 |
|
@@ -622,7 +638,7 @@ msgstr ""
|
|
622 |
msgid "WooCommerce"
|
623 |
msgstr ""
|
624 |
|
625 |
-
#: admin/class-joinchat-admin.php:
|
626 |
msgid "Yes"
|
627 |
msgstr ""
|
628 |
|
@@ -632,31 +648,35 @@ msgid ""
|
|
632 |
"pages."
|
633 |
msgstr ""
|
634 |
|
635 |
-
#: admin/class-joinchat-admin.php:
|
636 |
msgid "You can interact on your page with Join.chat in two ways:"
|
637 |
msgstr ""
|
638 |
|
639 |
-
#: admin/class-joinchat-admin.php:
|
640 |
msgid ""
|
641 |
"You can introduce yourself, offer help or even make promotions to your users."
|
642 |
msgstr ""
|
643 |
|
644 |
-
#: admin/class-joinchat-admin.php:
|
645 |
msgid ""
|
646 |
"You can use dynamic variables that will be replaced by the values of the "
|
647 |
"page the user visits:"
|
648 |
msgstr ""
|
649 |
|
650 |
-
#: admin/class-joinchat-admin.php:
|
651 |
msgid ""
|
652 |
"You can use formatting styles like in WhatsApp: _<em>italic</em>_ *<strong>"
|
653 |
"bold</strong>* ~<del>strikethrough</del>~."
|
654 |
msgstr ""
|
655 |
|
656 |
-
#: admin/class-joinchat-admin.php:
|
657 |
msgid "You can use vars"
|
658 |
msgstr ""
|
659 |
|
660 |
-
#: admin/class-joinchat-admin.php:
|
|
|
|
|
|
|
|
|
661 |
msgid "💬 Need help?"
|
662 |
msgstr ""
|
2 |
msgid ""
|
3 |
msgstr ""
|
4 |
"Project-Id-Version: Join.chat\n"
|
5 |
+
"POT-Creation-Date: 2022-01-18 15:14+0000\n"
|
6 |
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
7 |
"Last-Translator: Your Name <you@example.com>\n"
|
8 |
"Language-Team: Creame <hola@crea.me>\n"
|
27 |
"I have a question about *{PRODUCT} ({SKU})*"
|
28 |
msgstr ""
|
29 |
|
30 |
+
#: admin/class-joinchat-admin.php:263
|
31 |
msgid "404 Page"
|
32 |
msgstr ""
|
33 |
|
35 |
msgid "<strong>WooCommerce</strong>, in product pages you can also use:"
|
36 |
msgstr ""
|
37 |
|
38 |
+
#: admin/class-joinchat-admin.php:551
|
39 |
#, php-format
|
40 |
msgid "Add links, images, videos and more with %s"
|
41 |
msgstr ""
|
42 |
|
43 |
+
#: admin/class-joinchat-admin.php:494
|
44 |
#, php-format
|
45 |
msgid "Add unlimited numbers with %1$s or multiple contacts with %2$s"
|
46 |
msgstr ""
|
47 |
|
48 |
+
#: admin/class-joinchat-admin.php:825
|
49 |
msgid "Add-ons"
|
50 |
msgstr ""
|
51 |
|
52 |
+
#: admin/class-joinchat-admin.php:744
|
53 |
msgid "Adding some CSS classes in your HTML:"
|
54 |
msgstr ""
|
55 |
|
56 |
+
#: admin/class-joinchat-admin.php:265
|
57 |
msgid "Archives"
|
58 |
msgstr ""
|
59 |
|
60 |
+
#: admin/class-joinchat-admin.php:267
|
61 |
msgid "Author Archives"
|
62 |
msgstr ""
|
63 |
|
64 |
+
#: admin/class-joinchat-admin.php:593
|
65 |
msgid "Auto (detects device dark mode)"
|
66 |
msgstr ""
|
67 |
|
68 |
+
#: admin/class-joinchat-admin.php:262
|
69 |
msgid "Blog Page"
|
70 |
msgstr ""
|
71 |
|
72 |
+
#: admin/class-joinchat-admin.php:421
|
73 |
msgid "Button"
|
74 |
msgstr ""
|
75 |
|
76 |
+
#: admin/class-joinchat-admin.php:233
|
77 |
msgid "Button Delay"
|
78 |
msgstr ""
|
79 |
|
80 |
+
#: admin/class-joinchat-admin.php:239
|
81 |
msgid "Button Text"
|
82 |
msgstr ""
|
83 |
|
84 |
+
#: admin/class-joinchat-admin.php:238 admin/class-joinchat-admin.php:966
|
85 |
msgid "Call to Action"
|
86 |
msgstr ""
|
87 |
|
93 |
msgid "Call to Action for Products on Sale"
|
94 |
msgstr ""
|
95 |
|
96 |
+
#: admin/class-joinchat-admin.php:973
|
97 |
msgid "Can use vars"
|
98 |
msgstr ""
|
99 |
|
101 |
msgid "Cart"
|
102 |
msgstr ""
|
103 |
|
104 |
+
#: admin/class-joinchat-admin.php:245
|
105 |
msgid "Chat Delay"
|
106 |
msgstr ""
|
107 |
|
108 |
+
#: admin/class-joinchat-admin.php:426
|
109 |
msgid "Chat Window"
|
110 |
msgstr ""
|
111 |
|
112 |
+
#: admin/class-joinchat-admin.php:568
|
113 |
msgid "Chat Window auto displays after delay"
|
114 |
msgstr ""
|
115 |
|
116 |
+
#: admin/class-joinchat-admin.php:573
|
117 |
msgid "Chat Window auto displays from this number of page views"
|
118 |
msgstr ""
|
119 |
|
120 |
+
#: includes/class-joinchat-i18n.php:128
|
121 |
+
msgid "Check translations"
|
122 |
+
msgstr ""
|
123 |
+
|
124 |
#: admin/class-joinchat-woo-admin.php:131
|
125 |
msgid "Checkout"
|
126 |
msgstr ""
|
135 |
"support. Stop losing customers and increase your sales."
|
136 |
msgstr ""
|
137 |
|
138 |
+
#: admin/class-joinchat-admin.php:492
|
139 |
msgid ""
|
140 |
"Contact phone number <strong>(the button will not be shown if it's empty)"
|
141 |
"</strong>"
|
142 |
msgstr ""
|
143 |
|
144 |
+
#: admin/class-joinchat-admin.php:743 admin/class-joinchat-admin.php:755
|
145 |
msgid "Contact us"
|
146 |
msgstr ""
|
147 |
|
149 |
msgid "Creame"
|
150 |
msgstr ""
|
151 |
|
152 |
+
#: admin/class-joinchat-admin.php:451
|
153 |
msgid "Custom Post Types"
|
154 |
msgstr ""
|
155 |
|
156 |
+
#: admin/class-joinchat-admin.php:606
|
157 |
msgid "Custom:"
|
158 |
msgstr ""
|
159 |
|
160 |
+
#: admin/class-joinchat-admin.php:241 admin/class-joinchat-admin.php:587
|
161 |
msgid "Dark Mode"
|
162 |
msgstr ""
|
163 |
|
164 |
+
#: admin/class-joinchat-admin.php:266
|
165 |
msgid "Date Archives"
|
166 |
msgstr ""
|
167 |
|
168 |
+
#: includes/class-joinchat-i18n.php:125
|
169 |
+
#, php-format
|
170 |
+
msgid "Default site language (%s)"
|
171 |
+
msgstr ""
|
172 |
+
|
173 |
+
#: admin/class-joinchat-admin.php:983
|
174 |
msgid "Default visibility"
|
175 |
msgstr ""
|
176 |
|
183 |
msgid "Define a text for your products to encourage customers to contact"
|
184 |
msgstr ""
|
185 |
|
186 |
+
#: admin/class-joinchat-admin.php:549
|
187 |
msgid "Define a text to encourage users to contact by WhatsApp"
|
188 |
msgstr ""
|
189 |
|
190 |
+
#: admin/class-joinchat-admin.php:701
|
191 |
+
msgid "Dismiss"
|
192 |
+
msgstr ""
|
193 |
+
|
194 |
+
#: admin/class-joinchat-admin.php:579
|
195 |
msgid ""
|
196 |
"Display a notification balloon instead of opening the Chat Window for a "
|
197 |
"\"less intrusive\" mode"
|
198 |
msgstr ""
|
199 |
|
200 |
+
#: admin/class-joinchat-admin.php:1118
|
201 |
#, php-format
|
202 |
msgid "Do you like %1$s? Please help us with a %2$s rating."
|
203 |
msgstr ""
|
204 |
|
205 |
+
#: admin/class-joinchat-admin.php:824
|
206 |
msgid "Documentation"
|
207 |
msgstr ""
|
208 |
|
209 |
+
#: admin/class-joinchat-admin.php:155
|
210 |
msgid "e.g."
|
211 |
msgstr ""
|
212 |
|
213 |
+
#: admin/class-joinchat-admin.php:743 admin/class-joinchat-admin.php:755
|
214 |
msgid "Example:"
|
215 |
msgstr ""
|
216 |
|
217 |
+
#: admin/class-joinchat-admin.php:778
|
218 |
#, php-format
|
219 |
msgid "Follow %s on twitter."
|
220 |
msgstr ""
|
225 |
"use:"
|
226 |
msgstr ""
|
227 |
|
228 |
+
#: admin/class-joinchat-admin.php:442
|
229 |
msgid ""
|
230 |
"From here you can configure on which pages the WhatsApp button will be "
|
231 |
"visible."
|
232 |
msgstr ""
|
233 |
|
234 |
+
#: admin/class-joinchat-admin.php:261
|
235 |
msgid "Front Page"
|
236 |
msgstr ""
|
237 |
|
238 |
+
#: admin/class-joinchat-admin.php:111
|
239 |
msgid "General"
|
240 |
msgstr ""
|
241 |
|
242 |
+
#: admin/class-joinchat-admin.php:256
|
243 |
msgid "Global"
|
244 |
msgstr ""
|
245 |
|
246 |
+
#: admin/class-joinchat-admin.php:242 admin/class-joinchat-admin.php:600
|
247 |
msgid "Header"
|
248 |
msgstr ""
|
249 |
|
250 |
+
#: admin/class-joinchat-admin.php:548
|
251 |
msgid ""
|
252 |
"Hello 👋\n"
|
253 |
"Can we help you?"
|
254 |
msgstr ""
|
255 |
|
256 |
+
#: admin/class-joinchat-admin.php:557
|
257 |
msgid "Hi *{SITE}*! I need more info about {TITLE} {URL}"
|
258 |
msgstr ""
|
259 |
|
260 |
+
#: admin/class-joinchat-admin.php:479 admin/class-joinchat-admin.php:644
|
261 |
+
#: admin/class-joinchat-admin.php:981
|
262 |
msgid "Hide"
|
263 |
msgstr ""
|
264 |
|
270 |
msgid "https://join.chat"
|
271 |
msgstr ""
|
272 |
|
273 |
+
#: admin/class-joinchat-admin.php:435
|
274 |
msgid ""
|
275 |
"If it's defined a \"Call to Action\", the Chat Window can be displayed "
|
276 |
"automatically if conditions are met."
|
277 |
msgstr ""
|
278 |
|
279 |
+
#: admin/class-joinchat-admin.php:428
|
280 |
msgid ""
|
281 |
"If you define a \"Call to Action\" a window will be displayed simulating a "
|
282 |
"chat before launching WhatsApp."
|
283 |
msgstr ""
|
284 |
|
285 |
+
#: admin/class-joinchat-admin.php:767
|
286 |
msgid "If you like Join.chat 😍"
|
287 |
msgstr ""
|
288 |
|
289 |
+
#: admin/class-joinchat-admin.php:762
|
290 |
#, php-format
|
291 |
msgid ""
|
292 |
"If you need help, first review our <a href=\"%1$s\" target=\"_blank\">"
|
295 |
"href=\"%3$s\" target=\"_blank\">premium support</a>."
|
296 |
msgstr ""
|
297 |
|
298 |
+
#: admin/class-joinchat-admin.php:230
|
299 |
msgid "Image"
|
300 |
msgstr ""
|
301 |
|
302 |
+
#: admin/class-joinchat-admin.php:481
|
303 |
msgid "Inherit"
|
304 |
msgstr ""
|
305 |
|
306 |
#. Name of the plugin
|
307 |
+
#: admin/class-joinchat-admin.php:903
|
308 |
msgid "Join.chat"
|
309 |
msgstr ""
|
310 |
|
311 |
+
#: admin/class-joinchat-admin.php:856
|
312 |
msgid "Join.chat Settings"
|
313 |
msgstr ""
|
314 |
|
315 |
+
#: includes/class-joinchat-elementor-finder.php:52
|
316 |
+
#: includes/class-joinchat-elementor-finder.php:59
|
317 |
+
#: includes/class-joinchat-integrations.php:112
|
318 |
msgid "Join.chat settings page"
|
319 |
msgstr ""
|
320 |
|
321 |
+
#: includes/class-joinchat-elementor-finder.php:51
|
322 |
msgctxt "Keywords in Elementor Finder"
|
323 |
msgid "settings,phone"
|
324 |
msgstr ""
|
325 |
|
326 |
+
#: includes/class-joinchat-elementor-finder.php:58
|
327 |
msgctxt "Keywords in Elementor Finder"
|
328 |
msgid "visibility,show,hide"
|
329 |
msgstr ""
|
330 |
|
331 |
+
#: includes/class-joinchat-integrations.php:111
|
332 |
msgctxt "Keywords in Elementor Finder"
|
333 |
msgid "woocommerce,shop,product"
|
334 |
msgstr ""
|
335 |
|
336 |
+
#: admin/class-joinchat-admin.php:509
|
337 |
msgid "Left"
|
338 |
msgstr ""
|
339 |
|
340 |
+
#: admin/class-joinchat-admin.php:229 admin/class-joinchat-admin.php:970
|
341 |
msgid "Message"
|
342 |
msgstr ""
|
343 |
|
345 |
msgid "Message for Products"
|
346 |
msgstr ""
|
347 |
|
348 |
+
#: admin/class-joinchat-admin.php:234 admin/class-joinchat-admin.php:501
|
349 |
msgid "Mobile Only"
|
350 |
msgstr ""
|
351 |
|
353 |
msgid "My Account"
|
354 |
msgstr ""
|
355 |
|
356 |
+
#: admin/class-joinchat-admin.php:589
|
357 |
msgid "No"
|
358 |
msgstr ""
|
359 |
|
360 |
+
#: admin/class-joinchat-admin.php:247 admin/class-joinchat-admin.php:577
|
361 |
msgid "Notification Balloon"
|
362 |
msgstr ""
|
363 |
|
364 |
+
#: admin/class-joinchat-admin.php:503
|
365 |
msgid "Only display the button on mobile devices"
|
366 |
msgstr ""
|
367 |
|
368 |
+
#: admin/class-joinchat-admin.php:751
|
369 |
msgid "only show if it's an not seen CTA."
|
370 |
msgstr ""
|
371 |
|
372 |
+
#: admin/class-joinchat-admin.php:544
|
373 |
msgid "Open <em>WhatsApp Web</em> directly on desktop"
|
374 |
msgstr ""
|
375 |
|
376 |
+
#: admin/class-joinchat-admin.php:562 includes/class-joinchat-common.php:40
|
|
|
377 |
msgid "Open chat"
|
378 |
msgstr ""
|
379 |
|
380 |
+
#: admin/class-joinchat-admin.php:526
|
381 |
#, php-format
|
382 |
msgid "Other icons and more channels (Telegram, Messenger…) with %s"
|
383 |
msgstr ""
|
384 |
|
385 |
+
#: admin/class-joinchat-admin.php:269
|
386 |
msgid "Page"
|
387 |
msgstr ""
|
388 |
|
389 |
+
#: admin/class-joinchat-admin.php:730
|
390 |
msgid "Page Title"
|
391 |
msgstr ""
|
392 |
|
393 |
+
#: admin/class-joinchat-admin.php:246
|
394 |
msgid "Page Views"
|
395 |
msgstr ""
|
396 |
|
397 |
+
#: admin/class-joinchat-admin.php:770
|
398 |
#, php-format
|
399 |
msgid "Please leave us a %s rating. We'll thank you."
|
400 |
msgstr ""
|
401 |
|
402 |
+
#: admin/class-joinchat-admin.php:232 admin/class-joinchat-admin.php:507
|
403 |
msgid "Position on Screen"
|
404 |
msgstr ""
|
405 |
|
406 |
+
#: admin/class-joinchat-admin.php:270
|
407 |
msgid "Post"
|
408 |
msgstr ""
|
409 |
|
411 |
msgid "Powered by"
|
412 |
msgstr ""
|
413 |
|
414 |
+
#: admin/class-joinchat-admin.php:602
|
415 |
msgid "Powered by Join.chat"
|
416 |
msgstr ""
|
417 |
|
419 |
msgid "Predefined text for the first message the client will send you"
|
420 |
msgstr ""
|
421 |
|
422 |
+
#: admin/class-joinchat-admin.php:558
|
423 |
msgid "Predefined text for the first message the user will send you"
|
424 |
msgstr ""
|
425 |
|
435 |
msgid "Product Page"
|
436 |
msgstr ""
|
437 |
|
438 |
+
#: admin/class-joinchat-admin.php:523
|
439 |
msgid "Remove"
|
440 |
msgstr ""
|
441 |
|
442 |
+
#: admin/class-joinchat-admin.php:443
|
443 |
msgid "Restore default visibility"
|
444 |
msgstr ""
|
445 |
|
446 |
+
#: admin/class-joinchat-admin.php:511
|
447 |
msgid "Right"
|
448 |
msgstr ""
|
449 |
|
454 |
"If you have any questions, ask us."
|
455 |
msgstr ""
|
456 |
|
457 |
+
#: admin/class-joinchat-admin.php:264
|
458 |
msgid "Search Results"
|
459 |
msgstr ""
|
460 |
|
461 |
+
#: admin/class-joinchat-admin.php:537
|
462 |
msgid "seconds"
|
463 |
msgstr ""
|
464 |
|
465 |
+
#: admin/class-joinchat-admin.php:567
|
466 |
msgid "seconds (0 disabled)"
|
467 |
msgstr ""
|
468 |
|
469 |
+
#: admin/class-joinchat-admin.php:521
|
470 |
msgid "Select an image"
|
471 |
msgstr ""
|
472 |
|
473 |
+
#: admin/class-joinchat-admin.php:522
|
474 |
msgid "Select button image"
|
475 |
msgstr ""
|
476 |
|
477 |
+
#: admin/class-joinchat-admin.php:422
|
478 |
msgid ""
|
479 |
"Set the contact number and where you want the WhatsApp button to be "
|
480 |
"displayed."
|
481 |
msgstr ""
|
482 |
|
483 |
+
#: admin/class-joinchat-admin.php:697 admin/class-joinchat-admin.php:801
|
484 |
msgid "Settings"
|
485 |
msgstr ""
|
486 |
|
487 |
+
#: admin/class-joinchat-admin.php:371
|
488 |
msgid "Settings saved"
|
489 |
msgstr ""
|
490 |
|
492 |
msgid "Shop"
|
493 |
msgstr ""
|
494 |
|
495 |
+
#: admin/class-joinchat-admin.php:533
|
496 |
msgid "Short text shown next to button"
|
497 |
msgstr ""
|
498 |
|
499 |
+
#: admin/class-joinchat-admin.php:477 admin/class-joinchat-admin.php:642
|
500 |
+
#: admin/class-joinchat-admin.php:979
|
501 |
msgid "Show"
|
502 |
msgstr ""
|
503 |
|
504 |
+
#: admin/class-joinchat-admin.php:436 admin/class-joinchat-admin.php:1055
|
505 |
msgid "Show Help"
|
506 |
msgstr ""
|
507 |
|
508 |
+
#: admin/class-joinchat-admin.php:268
|
509 |
msgid "Singular"
|
510 |
msgstr ""
|
511 |
|
512 |
+
#: admin/class-joinchat-admin.php:723
|
513 |
msgid "Styles and Variables"
|
514 |
msgstr ""
|
515 |
|
516 |
+
#: admin/class-joinchat-admin.php:774
|
517 |
#, php-format
|
518 |
msgid "Subscribe to our newsletter and visit our blog at %s."
|
519 |
msgstr ""
|
520 |
|
521 |
+
#: admin/class-joinchat-admin.php:759 admin/class-joinchat-admin.php:826
|
522 |
msgid "Support"
|
523 |
msgstr ""
|
524 |
|
525 |
+
#: admin/class-joinchat-admin.php:228 admin/class-joinchat-admin.php:962
|
526 |
msgid "Telephone"
|
527 |
msgstr ""
|
528 |
|
529 |
+
#: admin/class-joinchat-admin.php:563
|
530 |
msgid "Text to open chat on Chat Window button"
|
531 |
msgstr ""
|
532 |
|
534 |
msgid "Thank You"
|
535 |
msgstr ""
|
536 |
|
537 |
+
#: admin/class-joinchat-admin.php:524
|
538 |
msgid "The image will alternate with button icon"
|
539 |
msgstr ""
|
540 |
|
541 |
+
#: admin/class-joinchat-admin.php:240
|
542 |
msgid "Theme Color"
|
543 |
msgstr ""
|
544 |
|
545 |
+
#: includes/class-joinchat-i18n.php:126
|
546 |
+
msgid "There are changes in fields that can be translated."
|
547 |
+
msgstr ""
|
548 |
+
|
549 |
#: admin/class-joinchat-woo-admin.php:224
|
550 |
msgid ""
|
551 |
"This *{PRODUCT}* can be yours for only *{PRICE}*!\n"
|
552 |
"If you have any questions, ask us."
|
553 |
msgstr ""
|
554 |
|
555 |
+
#: admin/class-joinchat-admin.php:538
|
556 |
msgid "Time since the page is opened until the button is displayed"
|
557 |
msgstr ""
|
558 |
|
559 |
+
#: includes/class-joinchat-elementor-finder.php:48
|
560 |
msgctxt "Title in Elementor Finder"
|
561 |
msgid "General Settings"
|
562 |
msgstr ""
|
563 |
|
564 |
+
#: includes/class-joinchat-elementor-finder.php:55
|
565 |
msgctxt "Title in Elementor Finder"
|
566 |
msgid "Visibility Settings"
|
567 |
msgstr ""
|
568 |
|
569 |
+
#: includes/class-joinchat-integrations.php:108
|
570 |
msgctxt "Title in Elementor Finder"
|
571 |
msgid "WooCommerce Settings"
|
572 |
msgstr ""
|
573 |
|
574 |
+
#: admin/class-joinchat-admin.php:747
|
575 |
msgid "to hide Chat Window on click."
|
576 |
msgstr ""
|
577 |
|
578 |
+
#: admin/class-joinchat-admin.php:975
|
579 |
msgid "to leave it blank use"
|
580 |
msgstr ""
|
581 |
|
582 |
+
#: admin/class-joinchat-admin.php:741 admin/class-joinchat-admin.php:748
|
583 |
msgid "to open WhatsApp directly on click."
|
584 |
msgstr ""
|
585 |
|
586 |
+
#: admin/class-joinchat-admin.php:752
|
587 |
msgid "to show always."
|
588 |
msgstr ""
|
589 |
|
590 |
+
#: admin/class-joinchat-admin.php:740 admin/class-joinchat-admin.php:746
|
591 |
msgid "to show Chat Window (or open WhatsApp if there is no CTA) on click."
|
592 |
msgstr ""
|
593 |
|
594 |
+
#: admin/class-joinchat-admin.php:749
|
595 |
msgid ""
|
596 |
"To show Chat Window when an HTML element appears on screen when user scrolls:"
|
597 |
msgstr ""
|
598 |
|
599 |
+
#: admin/class-joinchat-admin.php:231
|
600 |
msgid "Tooltip"
|
601 |
msgstr ""
|
602 |
|
603 |
+
#: admin/class-joinchat-admin.php:735
|
604 |
msgid "Triggers"
|
605 |
msgstr ""
|
606 |
|
607 |
+
#: public/class-joinchat-public.php:216 admin/class-joinchat-admin.php:487
|
608 |
+
#: admin/class-joinchat-admin.php:718 admin/class-joinchat-admin.php:822
|
609 |
msgctxt "url lang slug (only available for spanish \"es\")"
|
610 |
msgid "en"
|
611 |
msgstr ""
|
612 |
|
613 |
+
#: admin/class-joinchat-admin.php:522
|
614 |
msgid "Use image"
|
615 |
msgstr ""
|
616 |
|
617 |
+
#: admin/class-joinchat-admin.php:112
|
618 |
msgid "Visibility"
|
619 |
msgstr ""
|
620 |
|
621 |
+
#: admin/class-joinchat-admin.php:441
|
622 |
msgid "Visibility Settings"
|
623 |
msgstr ""
|
624 |
|
625 |
+
#: admin/class-joinchat-admin.php:604
|
626 |
msgid "WhatsApp Logo"
|
627 |
msgstr ""
|
628 |
|
629 |
+
#: admin/class-joinchat-admin.php:235 admin/class-joinchat-admin.php:542
|
630 |
msgid "WhatsApp Web"
|
631 |
msgstr ""
|
632 |
|
633 |
+
#: admin/class-joinchat-admin.php:738
|
634 |
msgid "With anchor links:"
|
635 |
msgstr ""
|
636 |
|
638 |
msgid "WooCommerce"
|
639 |
msgstr ""
|
640 |
|
641 |
+
#: admin/class-joinchat-admin.php:591
|
642 |
msgid "Yes"
|
643 |
msgstr ""
|
644 |
|
648 |
"pages."
|
649 |
msgstr ""
|
650 |
|
651 |
+
#: admin/class-joinchat-admin.php:737
|
652 |
msgid "You can interact on your page with Join.chat in two ways:"
|
653 |
msgstr ""
|
654 |
|
655 |
+
#: admin/class-joinchat-admin.php:429
|
656 |
msgid ""
|
657 |
"You can introduce yourself, offer help or even make promotions to your users."
|
658 |
msgstr ""
|
659 |
|
660 |
+
#: admin/class-joinchat-admin.php:726
|
661 |
msgid ""
|
662 |
"You can use dynamic variables that will be replaced by the values of the "
|
663 |
"page the user visits:"
|
664 |
msgstr ""
|
665 |
|
666 |
+
#: admin/class-joinchat-admin.php:725
|
667 |
msgid ""
|
668 |
"You can use formatting styles like in WhatsApp: _<em>italic</em>_ *<strong>"
|
669 |
"bold</strong>* ~<del>strikethrough</del>~."
|
670 |
msgstr ""
|
671 |
|
672 |
+
#: admin/class-joinchat-admin.php:1054
|
673 |
msgid "You can use vars"
|
674 |
msgstr ""
|
675 |
|
676 |
+
#: admin/class-joinchat-admin.php:696
|
677 |
+
msgid "You only need to add your WhatsApp number to contact with your users."
|
678 |
+
msgstr ""
|
679 |
+
|
680 |
+
#: admin/class-joinchat-admin.php:532
|
681 |
msgid "💬 Need help?"
|
682 |
msgstr ""
|
public/class-joinchat-public.php
CHANGED
@@ -32,6 +32,15 @@ class JoinChatPublic {
|
|
32 |
*/
|
33 |
private $version;
|
34 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
35 |
/**
|
36 |
* The setings of this plugin.
|
37 |
*
|
@@ -65,6 +74,7 @@ class JoinChatPublic {
|
|
65 |
|
66 |
$this->plugin_name = $plugin_name;
|
67 |
$this->version = $version;
|
|
|
68 |
|
69 |
// Updated in get_settings() at 'wp' hook
|
70 |
$this->show = false;
|
@@ -84,53 +94,12 @@ class JoinChatPublic {
|
|
84 |
*/
|
85 |
public function get_settings() {
|
86 |
|
|
|
|
|
|
|
87 |
// If use "global $post;" take first post in loop on archive pages
|
88 |
$obj = get_queried_object();
|
89 |
|
90 |
-
$default_settings = array_merge(
|
91 |
-
array(
|
92 |
-
'telephone' => '',
|
93 |
-
'mobile_only' => 'no',
|
94 |
-
'button_image' => '',
|
95 |
-
'button_tip' => '',
|
96 |
-
'button_delay' => 3,
|
97 |
-
'whatsapp_web' => 'no',
|
98 |
-
'message_text' => '',
|
99 |
-
'message_views' => 2,
|
100 |
-
'message_delay' => 10,
|
101 |
-
'message_badge' => 'no',
|
102 |
-
'message_send' => '',
|
103 |
-
'message_start' => __( 'Open chat', 'creame-whatsapp-me' ),
|
104 |
-
'position' => 'right',
|
105 |
-
'visibility' => array( 'all' => 'yes' ),
|
106 |
-
'color' => '#25d366',
|
107 |
-
'dark_mode' => 'no',
|
108 |
-
'header' => '__jc__', // values: '__jc__', '__wa__' or other custom text
|
109 |
-
),
|
110 |
-
apply_filters( 'joinchat_extra_settings', array() )
|
111 |
-
);
|
112 |
-
|
113 |
-
// Can hook 'option_joinchat' and 'default_option_joinchat' filters
|
114 |
-
$settings = array_merge( $default_settings, (array) get_option( 'joinchat', $default_settings ) );
|
115 |
-
|
116 |
-
// Migrate addons 'remove_brand' setting to 'header' (v. < 4.1)
|
117 |
-
if ( isset( $settings['remove_brand'] ) ) {
|
118 |
-
$remove = $settings['remove_brand'];
|
119 |
-
$settings['header'] = 'wa' == $remove ? '__wa__' : ( 'no' == $remove ? '__jc__' : '' );
|
120 |
-
}
|
121 |
-
|
122 |
-
// Clean unused saved settings
|
123 |
-
$settings = array_intersect_key( $settings, $default_settings );
|
124 |
-
|
125 |
-
// Load WPML/Polylang translated strings
|
126 |
-
$settings_i18n = JoinChatUtil::settings_i18n( $settings );
|
127 |
-
|
128 |
-
foreach ( $settings_i18n as $key => $label ) {
|
129 |
-
if ( isset( $settings[ $key ] ) ) {
|
130 |
-
$settings[ $key ] = $settings[ $key ] ? apply_filters( 'wpml_translate_single_string', $settings[ $key ], 'Join.chat', $label ) : '';
|
131 |
-
}
|
132 |
-
}
|
133 |
-
|
134 |
// Filter for site settings (can be overriden by post settings)
|
135 |
$settings = apply_filters( 'joinchat_get_settings_site', $settings, $obj );
|
136 |
|
32 |
*/
|
33 |
private $version;
|
34 |
|
35 |
+
/**
|
36 |
+
* Common class for admin and front methods.
|
37 |
+
*
|
38 |
+
* @since 4.2.0
|
39 |
+
* @access private
|
40 |
+
* @var JoinChatCommon $common instance.
|
41 |
+
*/
|
42 |
+
private $common;
|
43 |
+
|
44 |
/**
|
45 |
* The setings of this plugin.
|
46 |
*
|
74 |
|
75 |
$this->plugin_name = $plugin_name;
|
76 |
$this->version = $version;
|
77 |
+
$this->common = new JoinChatCommon();
|
78 |
|
79 |
// Updated in get_settings() at 'wp' hook
|
80 |
$this->show = false;
|
94 |
*/
|
95 |
public function get_settings() {
|
96 |
|
97 |
+
// Load settings
|
98 |
+
$settings = $this->common->load_settings();
|
99 |
+
|
100 |
// If use "global $post;" take first post in loop on archive pages
|
101 |
$obj = get_queried_object();
|
102 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
103 |
// Filter for site settings (can be overriden by post settings)
|
104 |
$settings = apply_filters( 'joinchat_get_settings_site', $settings, $obj );
|
105 |
|
public/css/joinchat.css
CHANGED
@@ -71,6 +71,12 @@
|
|
71 |
--msg: var(--dark);
|
72 |
}
|
73 |
|
|
|
|
|
|
|
|
|
|
|
|
|
74 |
@supports not (width: clamp(1px, 1%, 10px)) {
|
75 |
.joinchat {
|
76 |
--text: rgba(var(--bw), var(--bw), var(--bw), 0.9);
|
@@ -217,6 +223,17 @@
|
|
217 |
animation: joinchat_chat 6s 3.2s ease-in-out infinite;
|
218 |
}
|
219 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
220 |
.joinchat__button__sendtext {
|
221 |
padding: 0;
|
222 |
max-width: 0;
|
@@ -239,6 +256,12 @@
|
|
239 |
padding: 0 24px 0 4px;
|
240 |
}
|
241 |
|
|
|
|
|
|
|
|
|
|
|
|
|
242 |
.joinchat__badge {
|
243 |
position: absolute;
|
244 |
top: -4px;
|
@@ -268,8 +291,8 @@
|
|
268 |
|
269 |
.joinchat__tooltip {
|
270 |
position: absolute;
|
271 |
-
top:
|
272 |
-
right:
|
273 |
max-width: calc(100vw - 105px);
|
274 |
height: 32px;
|
275 |
padding: 0 14px;
|
@@ -282,7 +305,7 @@
|
|
282 |
opacity: 0;
|
283 |
transition: opacity 0.3s ease-out 0.4s;
|
284 |
filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.4));
|
285 |
-
transform:
|
286 |
pointer-events: none;
|
287 |
}
|
288 |
|
@@ -342,7 +365,7 @@
|
|
342 |
max-width: 400px;
|
343 |
min-height: 170px;
|
344 |
max-height: calc(var(--vh) - var(--bottom) - var(--sep));
|
345 |
-
border-radius:
|
346 |
background: transparent;
|
347 |
box-shadow: 0 2px 6px 0 rgba(0, 0, 0, 0.5);
|
348 |
text-align: left;
|
@@ -461,6 +484,7 @@
|
|
461 |
background: #fff linear-gradient(0deg, var(--bg), var(--bg));
|
462 |
overflow-x: hidden;
|
463 |
overflow-y: auto;
|
|
|
464 |
will-change: scroll-position;
|
465 |
}
|
466 |
|
71 |
--msg: var(--dark);
|
72 |
}
|
73 |
|
74 |
+
@media (prefers-reduced-motion) {
|
75 |
+
.joinchat {
|
76 |
+
transition: none !important;
|
77 |
+
}
|
78 |
+
}
|
79 |
+
|
80 |
@supports not (width: clamp(1px, 1%, 10px)) {
|
81 |
.joinchat {
|
82 |
--text: rgba(var(--bw), var(--bw), var(--bw), 0.9);
|
223 |
animation: joinchat_chat 6s 3.2s ease-in-out infinite;
|
224 |
}
|
225 |
|
226 |
+
@media (prefers-reduced-motion) {
|
227 |
+
.joinchat__button__send .joinchat_svg__plain {
|
228 |
+
stroke-dasharray: 0;
|
229 |
+
animation: none;
|
230 |
+
}
|
231 |
+
|
232 |
+
.joinchat__button__send .joinchat_svg__chat {
|
233 |
+
animation: none;
|
234 |
+
}
|
235 |
+
}
|
236 |
+
|
237 |
.joinchat__button__sendtext {
|
238 |
padding: 0;
|
239 |
max-width: 0;
|
256 |
padding: 0 24px 0 4px;
|
257 |
}
|
258 |
|
259 |
+
@media (prefers-reduced-motion) {
|
260 |
+
.joinchat__button__sendtext {
|
261 |
+
transition: none !important;
|
262 |
+
}
|
263 |
+
}
|
264 |
+
|
265 |
.joinchat__badge {
|
266 |
position: absolute;
|
267 |
top: -4px;
|
291 |
|
292 |
.joinchat__tooltip {
|
293 |
position: absolute;
|
294 |
+
top: 50%;
|
295 |
+
right: calc(var(--btn) + 16px);
|
296 |
max-width: calc(100vw - 105px);
|
297 |
height: 32px;
|
298 |
padding: 0 14px;
|
305 |
opacity: 0;
|
306 |
transition: opacity 0.3s ease-out 0.4s;
|
307 |
filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.4));
|
308 |
+
transform: translateY(-50%);
|
309 |
pointer-events: none;
|
310 |
}
|
311 |
|
365 |
max-width: 400px;
|
366 |
min-height: 170px;
|
367 |
max-height: calc(var(--vh) - var(--bottom) - var(--sep));
|
368 |
+
border-radius: calc(var(--btn)/2 + 2px);
|
369 |
background: transparent;
|
370 |
box-shadow: 0 2px 6px 0 rgba(0, 0, 0, 0.5);
|
371 |
text-align: left;
|
484 |
background: #fff linear-gradient(0deg, var(--bg), var(--bg));
|
485 |
overflow-x: hidden;
|
486 |
overflow-y: auto;
|
487 |
+
overscroll-behavior-y: contain;
|
488 |
will-change: scroll-position;
|
489 |
}
|
490 |
|
public/css/joinchat.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
.joinchat{--bottom:20px;--sep:20px;--header:70px;--btn:60px;--vh:100vh;--red:37;--green:211;--blue:102;--rgb:var(--red),var(--green),var(--blue);--color:rgb(var(--rgb));--dark:rgb(calc(var(--red) - 75),calc(var(--green) - 75),calc(var(--blue) - 75));--hover:rgb(calc(var(--red) + 50),calc(var(--green) + 50),calc(var(--blue) + 50));--bg:rgba(var(--rgb),0.04);--tolerance:210;--bw: calc((var(--red)*0.2126 + var(--green)*0.7152 + var(--blue)*0.0722 - var(--tolerance))*-100000);--text:rgba(var(--bw),var(--bw),var(--bw),clamp(0.7,var(--bw),1));--msg:var(--color);position:fixed;z-index:1000;right:var(--sep);bottom:var(--bottom);color:var(--text);font:normal normal normal 16px/1.625em -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,sans-serif;letter-spacing:0;transform:scale3d(0,0,0);transition:transform .3s ease-in-out;-webkit-user-select:none;user-select:none;touch-action:manipulation;-webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:rgba(0,0,0,0)}.joinchat *,.joinchat :after,.joinchat :before{box-sizing:border-box}.joinchat:not(.joinchat--show)>div{display:none}.joinchat--show{transform:scaleX(1);transition:transform .5s cubic-bezier(.18,.89,.32,1.28)}.joinchat.joinchat--left{right:auto;left:var(--sep)}@media (max-width:480px),(orientation:landscape) and (max-width:767px){.joinchat{--bottom:6px;--sep:6px;--header:55px}}@media (max-width:767px){.joinchat.joinchat--footer-bar{--bottom:76px}}.joinchat.joinchat--dark{--msg:var(--dark)}@supports not (width:clamp(1px,1%,10px)){.joinchat{--text:rgba(var(--bw),var(--bw),var(--bw),0.9)}}@media (color-index:48){.joinchat.joinchat--dark-auto{--msg:var(--dark)}}@media (prefers-color-scheme:dark){.joinchat.joinchat--dark-auto{--msg:var(--dark)}}.joinchat__button{display:flex;flex-direction:row;position:absolute;z-index:2;bottom:8px;right:8px;height:var(--btn);min-width:var(--btn);max-width:95vw;background:#25d366;color:inherit;border-radius:calc(var(--btn)/2);box-shadow:1px 6px 24px 0 rgba(7,94,84,.24);cursor:pointer;transition:background .2s linear;will-change:background-color,width}[dir=rtl] .joinchat__button{flex-direction:row-reverse}.joinchat__button:hover{background:#128c7e;transition:background 1.5s linear}.joinchat__button:active{background:#128c7e;transition:none}.joinchat--left .joinchat__button{right:auto;left:8px;flex-direction:row-reverse}[dir=rtl] .joinchat--left .joinchat__button{flex-direction:row}.joinchat--chatbox .joinchat__button{background:var(--color);transition:background .2s linear;box-shadow:0 1px 2px 0 rgba(0,0,0,.3)}.joinchat--chatbox .joinchat__button:active,.joinchat--chatbox .joinchat__button:hover{background:var(--hover)}.joinchat__button__open{width:var(--btn);height:var(--btn);background:transparent url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E %3Cpath fill='%23fff' d='M3.516 3.516c4.686-4.686 12.284-4.686 16.97 0 4.686 4.686 4.686 12.283 0 16.97a12.004 12.004 0 01-13.754 2.299l-5.814.735a.392.392 0 01-.438-.44l.748-5.788A12.002 12.002 0 013.517 3.517zm3.61 17.043l.3.158a9.846 9.846 0 0011.534-1.758c3.843-3.843 3.843-10.074 0-13.918-3.843-3.843-10.075-3.843-13.918 0a9.846 9.846 0 00-1.747 11.554l.16.303-.51 3.942a.196.196 0 00.219.22l3.961-.501zm6.534-7.003l-.933 1.164a9.843 9.843 0 01-3.497-3.495l1.166-.933a.792.792 0 00.23-.94L9.561 6.96a.793.793 0 00-.924-.445 1291.6 1291.6 0 00-2.023.524.797.797 0 00-.588.88 11.754 11.754 0 0010.005 10.005.797.797 0 00.88-.587l.525-2.023a.793.793 0 00-.445-.923L14.6 13.327a.792.792 0 00-.94.23z'/%3E %3C/svg%3E") 50% no-repeat;background-size:60%}.joinchat--chatbox .joinchat__button__open{display:none}.joinchat__button__image{position:absolute;top:1px;right:1px;width:calc(var(--btn) - 2px);height:calc(var(--btn) - 2px);border-radius:50%;overflow:hidden;opacity:0}.joinchat__button__image img{display:block;width:100%;height:100%;-o-object-fit:cover;object-fit:cover}.joinchat--show .joinchat__button__image{animation:joinchat_image_loop 20s linear 5s infinite normal both}.joinchat--image .joinchat__button__image{opacity:1;animation:none}.joinchat--chatbox .joinchat__button__image{display:none}.joinchat__button__send{display:none;width:var(--btn);height:var(--btn);max-width:var(--btn);padding:12px 11px 12px 13px;margin:0;flex-shrink:0}.joinchat--chatbox .joinchat__button__send{display:block}.joinchat__button__send path{fill:none!important;stroke:var(--text)!important}.joinchat__button__send .joinchat_svg__plain{stroke-dasharray:1097;stroke-dashoffset:1097;animation:joinchat_plain 6s .2s ease-in-out infinite}.joinchat__button__send .joinchat_svg__chat{stroke-dasharray:1020;stroke-dashoffset:1020;animation:joinchat_chat 6s 3.2s ease-in-out infinite}.joinchat__button__sendtext{padding:0;max-width:0;font-weight:600;line-height:var(--btn);white-space:nowrap;opacity:0;overflow:hidden;transition:none}.joinchat--chatbox .joinchat__button__sendtext{padding:0 4px 0 24px;max-width:200px;opacity:1;transition:max-width .2s linear,opacity .4s ease-out .2s}.joinchat--chatbox.joinchat--left .joinchat__button__sendtext{padding:0 24px 0 4px}.joinchat__badge{position:absolute;top:-4px;right:-4px;width:20px;height:20px;border:none;border-radius:50%;background:#e82c0c;color:#fff;font-size:12px;font-weight:600;line-height:20px;text-align:center;box-shadow:none;opacity:0;pointer-events:none}.joinchat__badge.joinchat__badge--in{animation:joinchat_badge_in .5s cubic-bezier(.27,.9,.41,1.28) 1 both}.joinchat__badge.joinchat__badge--out{animation:joinchat_badge_out .4s cubic-bezier(.215,.61,.355,1) 1 both}.joinchat__tooltip{position:absolute;top:14px;right:76px;max-width:calc(100vw - 105px);height:32px;padding:0 14px;border:none;border-radius:16px;background:#fff;color:rgba(0,0,0,.8);line-height:31px;white-space:nowrap;opacity:0;transition:opacity .3s ease-out .4s;filter:drop-shadow(0 1px 4px rgba(0,0,0,.4));transform:translateZ(0);pointer-events:none}.joinchat__tooltip:after{content:"";display:block;position:absolute;top:10px;right:-6px;border:8px solid transparent;border-width:6px 0 6px 8px;border-left-color:#fff}.joinchat__tooltip div{overflow:hidden;text-overflow:ellipsis}.joinchat--tooltip .joinchat__tooltip{animation:joinchat_tootlip 20s linear 5s 1 normal both}@media (hover:hover){.joinchat__button:hover .joinchat__tooltip{opacity:1;animation:none;transition:opacity .2s}}.joinchat--chatbox .joinchat__tooltip{display:none}.joinchat--left .joinchat__tooltip{right:auto;left:76px}.joinchat--left .joinchat__tooltip:after{left:-6px;right:auto;border-color:transparent;border-width:6px 8px 6px 0;border-right-color:#fff}.joinchat__box{display:flex;flex-direction:column;position:absolute;bottom:0;right:0;z-index:1;width:calc(100vw - var(--sep)*2);max-width:400px;min-height:170px;max-height:calc(var(--vh) - var(--bottom) - var(--sep));border-radius:32px;background:transparent;box-shadow:0 2px 6px 0 rgba(0,0,0,.5);text-align:left;overflow:hidden;transform:scale3d(0,0,0);opacity:0;transition:max-height .2s ease-out,opacity .4s ease-out,transform 0s linear .3s}[dir=rtl] .joinchat__box{text-align:right}.joinchat--chatbox .joinchat__box{opacity:1;transform:scaleX(1);transition:max-height .2s ease-out,opacity .2s ease-out,transform 0s linear}.joinchat--left .joinchat__box{right:auto;left:0}.joinchat__header{display:flex;flex-flow:row;align-items:center;position:relative;flex-shrink:0;height:var(--header);padding:0 70px 0 26px;margin:0;background:var(--color)}[dir=rtl] .joinchat__header{padding:0 26px 0 70px}.joinchat--dark .joinchat__header{background:var(--dark)}.joinchat__header__text{font-size:19px;font-weight:600;max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;opacity:.8}.joinchat__powered{font-size:11px;line-height:18px;color:inherit!important;text-decoration:none!important;fill:currentColor;opacity:.8}.joinchat__powered svg{display:inline-block;width:auto;height:18px;vertical-align:-30%}.joinchat__powered:active,.joinchat__powered:hover{color:inherit!important;text-decoration:none!important;opacity:.9;filter:drop-shadow(0 1px 3px rgba(0,0,0,.3))}.joinchat__wa{height:28px;width:auto;fill:currentColor;opacity:.8}.joinchat__close{position:absolute;top:50%;right:24px;width:34px;height:34px;margin-top:-16px;border-radius:50%;background:rgba(0,0,0,.4) url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23fff'%3E %3Cpath d='M24 2.4L21.6 0 12 9.6 2.4 0 0 2.4 9.6 12 0 21.6 2.4 24l9.6-9.6 9.6 9.6 2.4-2.4-9.6-9.6L24 2.4z'/%3E %3C/svg%3E") 50% no-repeat;background-size:12px;cursor:pointer;transition:background-color .3s ease-out}.joinchat__close:hover{background-color:rgba(0,0,0,.6)}.joinchat__close:active{background-color:rgba(0,0,0,.7)}[dir=rtl] .joinchat__close{right:auto;left:24px}.joinchat__box__scroll{padding:20px 0 70px;padding-bottom:calc(var(--btn) + 10px);background:#fff linear-gradient(0deg,var(--bg),var(--bg));overflow-x:hidden;overflow-y:auto;will-change:scroll-position}.joinchat__box__scroll::-webkit-scrollbar{width:5px;background:transparent}.joinchat__box__scroll::-webkit-scrollbar-thumb{border-radius:3px;background:transparent}.joinchat--blur .joinchat__box__scroll{background:rgba(var(--rgb),.2);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.joinchat--dark .joinchat__box__scroll{background:#1a1a1a}.joinchat__box__scroll:hover::-webkit-scrollbar-thumb{background:rgba(0,0,0,.2)}@supports (-webkit-overflow-scrolling:touch){.joinchat__box__scroll{overflow-y:scroll;-webkit-overflow-scrolling:touch}}@media (max-width:480px),(orientation:landscape) and (max-width:767px){.joinchat__header__text{font-size:17px}.joinchat__close{margin-top:-14px;width:28px;height:28px}.joinchat__box__scroll{padding-top:15px}}@media (color-index:48){.joinchat--dark-auto .joinchat__box__scroll{background:#1a1a1a}.joinchat--dark-auto .joinchat__header{background:var(--dark)}}@media (prefers-color-scheme:dark){.joinchat--dark-auto .joinchat__box__scroll{background:#1a1a1a}.joinchat--dark-auto .joinchat__header{background:var(--dark)}}.joinchat__message{position:relative;min-height:60px;padding:17px 20px;margin:0 26px 26px;border-radius:32px;background:#fff;color:#4a4a4a;filter:drop-shadow(0 1px 2px rgba(0,0,0,.3));transform:translateZ(0)}.joinchat__message:before{content:"";display:block;position:absolute;bottom:20px;left:-15px;width:17px;height:25px;background:inherit;-webkit-clip-path:var(--peak,url(#joinchat__message__peak));clip-path:var(--peak,url(#joinchat__message__peak))}.joinchat--dark .joinchat__message{background:#505050;color:#d8d8d8}@media (color-index:48){.joinchat--dark-auto .joinchat__message{background:#505050;color:#d8d8d8}}@media (prefers-color-scheme:dark){.joinchat--dark-auto .joinchat__message{background:#505050;color:#d8d8d8}}@media (max-width:480px),(orientation:landscape) and (max-width:767px){.joinchat__message{padding:18px 16px;line-height:24px;margin:0 20px 20px}}@keyframes joinchat_badge_in{0%{opacity:0;transform:translateY(50px)}to{opacity:1;transform:translateY(0)}}@keyframes joinchat_badge_out{0%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-20px)}}@keyframes joinchat_plain{0%,50%,to{stroke-dashoffset:1097}5%,45%{stroke-dashoffset:0}}@keyframes joinchat_chat{0%,50%,to{stroke-dashoffset:1020}5%,45%{stroke-dashoffset:0}}@keyframes joinchat_image_loop{0%{opacity:0}3%,20%{opacity:1}25%,to{opacity:0}}@keyframes joinchat_tootlip{0%{opacity:0;transform:scaleY(0)}1%,20%{opacity:1;transform:scaleY(1)}25%,to{opacity:0;transform:scaleY(1)}}
|
1 |
+
.joinchat{--bottom:20px;--sep:20px;--header:70px;--btn:60px;--vh:100vh;--red:37;--green:211;--blue:102;--rgb:var(--red),var(--green),var(--blue);--color:rgb(var(--rgb));--dark:rgb(calc(var(--red) - 75),calc(var(--green) - 75),calc(var(--blue) - 75));--hover:rgb(calc(var(--red) + 50),calc(var(--green) + 50),calc(var(--blue) + 50));--bg:rgba(var(--rgb),0.04);--tolerance:210;--bw:calc(var(--red)*0.2126*-100000 + var(--green)*0.7152*-100000 + var(--blue)*0.0722*-100000 - var(--tolerance)*-100000);--text:rgba(var(--bw),var(--bw),var(--bw),clamp(0.7,var(--bw),1));--msg:var(--color);position:fixed;z-index:1000;right:var(--sep);bottom:var(--bottom);color:var(--text);font:normal normal normal 16px/1.625em -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,sans-serif;letter-spacing:0;transform:scale3d(0,0,0);transition:transform .3s ease-in-out;-webkit-user-select:none;user-select:none;touch-action:manipulation;-webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:rgba(0,0,0,0)}.joinchat *,.joinchat :after,.joinchat :before{box-sizing:border-box}.joinchat:not(.joinchat--show)>div{display:none}.joinchat--show{transform:scaleX(1);transition:transform .5s cubic-bezier(.18,.89,.32,1.28)}.joinchat.joinchat--left{right:auto;left:var(--sep)}@media (max-width:480px),(orientation:landscape) and (max-width:767px){.joinchat{--bottom:6px;--sep:6px;--header:55px}}@media (max-width:767px){.joinchat.joinchat--footer-bar{--bottom:76px}}.joinchat.joinchat--dark{--msg:var(--dark)}@media (prefers-reduced-motion){.joinchat{transition:none!important}}@supports not (width:clamp(1px,1%,10px)){.joinchat{--text:rgba(var(--bw),var(--bw),var(--bw),0.9)}}@media (color-index:48){.joinchat.joinchat--dark-auto{--msg:var(--dark)}}@media (prefers-color-scheme:dark){.joinchat.joinchat--dark-auto{--msg:var(--dark)}}.joinchat__button{display:flex;flex-direction:row;position:absolute;z-index:2;bottom:8px;right:8px;height:var(--btn);min-width:var(--btn);max-width:95vw;background:#25d366;color:inherit;border-radius:calc(var(--btn)/2);box-shadow:1px 6px 24px 0 rgba(7,94,84,.24);cursor:pointer;transition:background .2s linear;will-change:background-color,width}[dir=rtl] .joinchat__button{flex-direction:row-reverse}.joinchat__button:hover{background:#128c7e;transition:background 1.5s linear}.joinchat__button:active{background:#128c7e;transition:none}.joinchat--left .joinchat__button{right:auto;left:8px;flex-direction:row-reverse}[dir=rtl] .joinchat--left .joinchat__button{flex-direction:row}.joinchat--chatbox .joinchat__button{background:var(--color);transition:background .2s linear;box-shadow:0 1px 2px 0 rgba(0,0,0,.3)}.joinchat--chatbox .joinchat__button:active,.joinchat--chatbox .joinchat__button:hover{background:var(--hover)}.joinchat__button__open{width:var(--btn);height:var(--btn);background:transparent url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E %3Cpath fill='%23fff' d='M3.516 3.516c4.686-4.686 12.284-4.686 16.97 0 4.686 4.686 4.686 12.283 0 16.97a12.004 12.004 0 01-13.754 2.299l-5.814.735a.392.392 0 01-.438-.44l.748-5.788A12.002 12.002 0 013.517 3.517zm3.61 17.043l.3.158a9.846 9.846 0 0011.534-1.758c3.843-3.843 3.843-10.074 0-13.918-3.843-3.843-10.075-3.843-13.918 0a9.846 9.846 0 00-1.747 11.554l.16.303-.51 3.942a.196.196 0 00.219.22l3.961-.501zm6.534-7.003l-.933 1.164a9.843 9.843 0 01-3.497-3.495l1.166-.933a.792.792 0 00.23-.94L9.561 6.96a.793.793 0 00-.924-.445 1291.6 1291.6 0 00-2.023.524.797.797 0 00-.588.88 11.754 11.754 0 0010.005 10.005.797.797 0 00.88-.587l.525-2.023a.793.793 0 00-.445-.923L14.6 13.327a.792.792 0 00-.94.23z'/%3E %3C/svg%3E") 50% no-repeat;background-size:60%}.joinchat--chatbox .joinchat__button__open{display:none}.joinchat__button__image{position:absolute;top:1px;right:1px;width:calc(var(--btn) - 2px);height:calc(var(--btn) - 2px);border-radius:50%;overflow:hidden;opacity:0}.joinchat__button__image img{display:block;width:100%;height:100%;-o-object-fit:cover;object-fit:cover}.joinchat--show .joinchat__button__image{animation:joinchat_image_loop 20s linear 5s infinite normal both}.joinchat--image .joinchat__button__image{opacity:1;animation:none}.joinchat--chatbox .joinchat__button__image{display:none}.joinchat__button__send{display:none;width:var(--btn);height:var(--btn);max-width:var(--btn);padding:12px 11px 12px 13px;margin:0;flex-shrink:0}.joinchat--chatbox .joinchat__button__send{display:block}.joinchat__button__send path{fill:none!important;stroke:var(--text)!important}.joinchat__button__send .joinchat_svg__plain{stroke-dasharray:1097;stroke-dashoffset:1097;animation:joinchat_plain 6s .2s ease-in-out infinite}.joinchat__button__send .joinchat_svg__chat{stroke-dasharray:1020;stroke-dashoffset:1020;animation:joinchat_chat 6s 3.2s ease-in-out infinite}@media (prefers-reduced-motion){.joinchat__button__send .joinchat_svg__plain{stroke-dasharray:0;animation:none}.joinchat__button__send .joinchat_svg__chat{animation:none}}.joinchat__button__sendtext{padding:0;max-width:0;font-weight:600;line-height:var(--btn);white-space:nowrap;opacity:0;overflow:hidden;transition:none}.joinchat--chatbox .joinchat__button__sendtext{padding:0 4px 0 24px;max-width:200px;opacity:1;transition:max-width .2s linear,opacity .4s ease-out .2s}.joinchat--chatbox.joinchat--left .joinchat__button__sendtext{padding:0 24px 0 4px}@media (prefers-reduced-motion){.joinchat__button__sendtext{transition:none!important}}.joinchat__badge{position:absolute;top:-4px;right:-4px;width:20px;height:20px;border:none;border-radius:50%;background:#e82c0c;color:#fff;font-size:12px;font-weight:600;line-height:20px;text-align:center;box-shadow:none;opacity:0;pointer-events:none}.joinchat__badge.joinchat__badge--in{animation:joinchat_badge_in .5s cubic-bezier(.27,.9,.41,1.28) 1 both}.joinchat__badge.joinchat__badge--out{animation:joinchat_badge_out .4s cubic-bezier(.215,.61,.355,1) 1 both}.joinchat__tooltip{position:absolute;top:50%;right:calc(var(--btn) + 16px);max-width:calc(100vw - 105px);height:32px;padding:0 14px;border:none;border-radius:16px;background:#fff;color:rgba(0,0,0,.8);line-height:31px;white-space:nowrap;opacity:0;transition:opacity .3s ease-out .4s;filter:drop-shadow(0 1px 4px rgba(0,0,0,.4));transform:translateY(-50%);pointer-events:none}.joinchat__tooltip:after{content:"";display:block;position:absolute;top:10px;right:-6px;border:8px solid transparent;border-width:6px 0 6px 8px;border-left-color:#fff}.joinchat__tooltip div{overflow:hidden;text-overflow:ellipsis}.joinchat--tooltip .joinchat__tooltip{animation:joinchat_tootlip 20s linear 5s 1 normal both}@media (hover:hover){.joinchat__button:hover .joinchat__tooltip{opacity:1;animation:none;transition:opacity .2s}}.joinchat--chatbox .joinchat__tooltip{display:none}.joinchat--left .joinchat__tooltip{right:auto;left:76px}.joinchat--left .joinchat__tooltip:after{left:-6px;right:auto;border-color:transparent;border-width:6px 8px 6px 0;border-right-color:#fff}.joinchat__box{display:flex;flex-direction:column;position:absolute;bottom:0;right:0;z-index:1;width:calc(100vw - var(--sep)*2);max-width:400px;min-height:170px;max-height:calc(var(--vh) - var(--bottom) - var(--sep));border-radius:32px;background:transparent;box-shadow:0 2px 6px 0 rgba(0,0,0,.5);text-align:left;overflow:hidden;transform:scale3d(0,0,0);opacity:0;transition:max-height .2s ease-out,opacity .4s ease-out,transform 0s linear .3s}[dir=rtl] .joinchat__box{text-align:right}.joinchat--chatbox .joinchat__box{opacity:1;transform:scaleX(1);transition:max-height .2s ease-out,opacity .2s ease-out,transform 0s linear}.joinchat--left .joinchat__box{right:auto;left:0}.joinchat__header{display:flex;flex-flow:row;align-items:center;position:relative;flex-shrink:0;height:var(--header);padding:0 70px 0 26px;margin:0;background:var(--color)}[dir=rtl] .joinchat__header{padding:0 26px 0 70px}.joinchat--dark .joinchat__header{background:var(--dark)}.joinchat__header__text{font-size:19px;font-weight:600;max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;opacity:.8}.joinchat__powered{font-size:11px;line-height:18px;color:inherit!important;text-decoration:none!important;fill:currentColor;opacity:.8}.joinchat__powered svg{display:inline-block;width:auto;height:18px;vertical-align:-30%}.joinchat__powered:active,.joinchat__powered:hover{color:inherit!important;text-decoration:none!important;opacity:.9;filter:drop-shadow(0 1px 3px rgba(0,0,0,.3))}.joinchat__wa{height:28px;width:auto;fill:currentColor;opacity:.8}.joinchat__close{position:absolute;top:50%;right:24px;width:34px;height:34px;margin-top:-16px;border-radius:50%;background:rgba(0,0,0,.4) url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23fff'%3E %3Cpath d='M24 2.4L21.6 0 12 9.6 2.4 0 0 2.4 9.6 12 0 21.6 2.4 24l9.6-9.6 9.6 9.6 2.4-2.4-9.6-9.6L24 2.4z'/%3E %3C/svg%3E") 50% no-repeat;background-size:12px;cursor:pointer;transition:background-color .3s ease-out}.joinchat__close:hover{background-color:rgba(0,0,0,.6)}.joinchat__close:active{background-color:rgba(0,0,0,.7)}[dir=rtl] .joinchat__close{right:auto;left:24px}.joinchat__box__scroll{padding:20px 0 70px;padding-bottom:calc(var(--btn) + 10px);background:#fff linear-gradient(0deg,var(--bg),var(--bg));overflow-x:hidden;overflow-y:auto;will-change:scroll-position}.joinchat__box__scroll::-webkit-scrollbar{width:5px;background:transparent}.joinchat__box__scroll::-webkit-scrollbar-thumb{border-radius:3px;background:transparent}.joinchat--blur .joinchat__box__scroll{background:rgba(var(--rgb),.2);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.joinchat--dark .joinchat__box__scroll{background:#1a1a1a}.joinchat__box__scroll:hover::-webkit-scrollbar-thumb{background:rgba(0,0,0,.2)}@supports (-webkit-overflow-scrolling:touch){.joinchat__box__scroll{overflow-y:scroll;-webkit-overflow-scrolling:touch}}@media (max-width:480px),(orientation:landscape) and (max-width:767px){.joinchat__header__text{font-size:17px}.joinchat__close{margin-top:-14px;width:28px;height:28px}.joinchat__box__scroll{padding-top:15px}}@media (color-index:48){.joinchat--dark-auto .joinchat__box__scroll{background:#1a1a1a}.joinchat--dark-auto .joinchat__header{background:var(--dark)}}@media (prefers-color-scheme:dark){.joinchat--dark-auto .joinchat__box__scroll{background:#1a1a1a}.joinchat--dark-auto .joinchat__header{background:var(--dark)}}.joinchat__message{position:relative;min-height:60px;padding:17px 20px;margin:0 26px 26px;border-radius:32px;background:#fff;color:#4a4a4a;filter:drop-shadow(0 1px 2px rgba(0,0,0,.3));transform:translateZ(0)}.joinchat__message:before{content:"";display:block;position:absolute;bottom:20px;left:-15px;width:17px;height:25px;background:inherit;-webkit-clip-path:url(#joinchat__message__peak);clip-path:url(#joinchat__message__peak);-webkit-clip-path:var(--peak,url(#joinchat__message__peak));clip-path:var(--peak,url(#joinchat__message__peak))}.joinchat--dark .joinchat__message{background:#505050;color:#d8d8d8}@media (color-index:48){.joinchat--dark-auto .joinchat__message{background:#505050;color:#d8d8d8}}@media (prefers-color-scheme:dark){.joinchat--dark-auto .joinchat__message{background:#505050;color:#d8d8d8}}@media (max-width:480px),(orientation:landscape) and (max-width:767px){.joinchat__message{padding:18px 16px;line-height:24px;margin:0 20px 20px}}@keyframes joinchat_badge_in{0%{opacity:0;transform:translateY(50px)}to{opacity:1;transform:translateY(0)}}@keyframes joinchat_badge_out{0%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-20px)}}@keyframes joinchat_plain{0%,50%,to{stroke-dashoffset:1097}5%,45%{stroke-dashoffset:0}}@keyframes joinchat_chat{0%,50%,to{stroke-dashoffset:1020}5%,45%{stroke-dashoffset:0}}@keyframes joinchat_image_loop{0%{opacity:0}3%,20%{opacity:1}25%,to{opacity:0}}@keyframes joinchat_tootlip{0%{opacity:0;transform:scaleY(0)}1%,20%{opacity:1;transform:scaleY(1)}25%,to{opacity:0;transform:scaleY(1)}}
|