first commit

This commit is contained in:
2023-09-12 21:41:04 +02:00
commit 3361a7f053
13284 changed files with 2116755 additions and 0 deletions

View File

@@ -0,0 +1,45 @@
<?php
/**
* Challenge HTML template specific to Form Builder.
*
* @since 1.6.2
*/
if ( ! \defined( 'ABSPATH' ) ) {
exit;
}
?>
<div class="wpforms-challenge-tooltips">
<div id="tooltip-content1">
<h3><?php esc_html_e( 'Name Your Form', 'wpforms-lite' ); ?></h3>
<p><?php esc_html_e( 'Give your form a name so you can easily identify it.', 'wpforms-lite' ); ?></p>
<button type="button" class="wpforms-challenge-step1-done wpforms-challenge-done-btn"><?php esc_html_e( 'Done', 'wpforms-lite' ); ?></button>
</div>
<div id="tooltip-content2">
<h3><?php esc_html_e( 'Select a Template', 'wpforms-lite' ); ?></h3>
<p><?php esc_html_e( 'Build your form from scratch or use one of our pre-made templates.', 'wpforms-lite' ); ?></p>
</div>
<div id="tooltip-content3">
<p><?php esc_html_e( 'You can add additional fields to your form, if you need them.', 'wpforms-lite' ); ?></p>
<button type="button" class="wpforms-challenge-step3-done wpforms-challenge-done-btn"><?php esc_html_e( 'Done', 'wpforms-lite' ); ?></button>
</div>
<div id="tooltip-content4">
<h3><?php esc_html_e( 'Check Notification Settings', 'wpforms-lite' ); ?></h3>
<p><?php esc_html_e( 'The default notification settings might be sufficient, but double&#8209;check to be sure.', 'wpforms-lite' ); ?></p>
<button type="button" class="wpforms-challenge-step4-done wpforms-challenge-done-btn"><?php esc_html_e( 'Done', 'wpforms-lite' ); ?></button>
</div>
</div>
<div class="wpforms-challenge-popup-container">
<div id="wpforms-challenge-welcome-builder-popup" class="wpforms-challenge-popup wpforms-challenge-popup-plain">
<div class="wpforms-challenge-popup-content">
<h3><?php esc_html_e( 'Welcome to the Form Builder', 'wpforms-lite' ); ?></h3>
<p><?php esc_html_e( 'Our form builder is a full-screen, distraction-free experience where you manage your forms. The following steps will walk you through essential areas.', 'wpforms-lite' ); ?></p>
<button type="button" class="wpforms-challenge-popup-btn"><?php esc_html_e( 'Lets Go!', 'wpforms-lite' ); ?></button>
</div>
</div>
</div>

View File

@@ -0,0 +1,111 @@
<?php
/**
* Challenge HTML template specific to form embed page.
*
* @since 1.6.2
*
* @var integer $minutes
*/
if ( ! \defined( 'ABSPATH' ) ) {
exit;
}
?>
<div class="wpforms-challenge-tooltips">
<div id="tooltip-content5">
<?php if ( wpforms_is_gutenberg_active() ) : // Gutenberg content. ?>
<h3><?php esc_html_e( 'Add a Block', 'wpforms-lite' ); ?></h3>
<p>
<?php
echo wp_kses(
sprintf(
/* translators: %s - Link to the WPForms documentation page. */
__( 'Click the plus button, search for WPForms, click the block to<br>embed it. <a href="%s" target="_blank" rel="noopener noreferrer">Learn More</a>.', 'wpforms-lite' ),
'https://wpforms.com/docs/creating-first-form/#display-form'
),
[
'a' => [
'href' => [],
'rel' => [],
'target' => [],
],
'br' => [],
]
);
?>
</p>
<i class="wpforms-challenge-tooltips-red-arrow"></i>
<?php else : ?>
<h3><?php esc_html_e( 'Embed in a Page', 'wpforms-lite' ); ?></h3>
<p><?php esc_html_e( 'Click the “Add Form” button, select your form, then add the embed code.', 'wpforms-lite' ); ?></p>
<?php endif; ?>
<button type="button" class="wpforms-challenge-step5-done wpforms-challenge-done-btn"><?php esc_html_e( 'Done', 'wpforms-lite' ); ?></button>
</div>
</div>
<div class="wpforms-challenge-popup-container">
<div id="wpforms-challenge-congrats-popup" class="wpforms-challenge-popup">
<div class="wpforms-challenge-popup-header wpforms-challenge-popup-header-congrats">
<i class="wpforms-challenge-popup-close fa fa-times-circle fa-lg"></i>
</div>
<div class="wpforms-challenge-popup-content">
<h3><?php esc_html_e( 'Congrats, you did it!', 'wpforms-lite' ); ?></h3>
<p>
<?php
echo wp_kses(
sprintf(
/* translators: %1$s - Number of minutes in HTML container; %2$s - Single or plural word 'minute'; %3$s - Number of seconds in HTML container; %4$s - Single or plural word 'second'; %5$s - 5 rating star symbols HTML. */
__( 'You completed the WPForms Challenge in <b>%1$s %2$s %3$s %4$s</b>. Share your success story with other WPForms users and help us spread the word <b>by giving WPForms a 5-star rating (%5$s) on WordPress.org</b>. Thanks for your support and we look forward to bringing you more awesome features.', 'wpforms-lite' ),
'<span id="wpforms-challenge-congrats-minutes"></span>',
_n( 'minute', 'minutes', absint( $minutes ), 'wpforms-lite' ),
'<span id="wpforms-challenge-congrats-seconds"></span>',
_n( 'second', 'seconds', absint( $minutes ), 'wpforms-lite' ),
'<span class="rating-stars"><i class="fa fa-star"></i><i class="fa fa-star"></i><i class="fa fa-star"></i><i class="fa fa-star"></i><i class="fa fa-star"></i></span>'
),
[
'span' => [
'id' => [],
'class' => [],
],
'b' => [],
'i' => [
'class' => [],
],
]
);
?>
</p>
<a href="https://wordpress.org/support/plugin/wpforms-lite/reviews/?filter=5#new-post" class="wpforms-challenge-popup-btn wpforms-challenge-popup-rate-btn" target="_blank" rel="noopener"><?php esc_html_e( 'Rate WPForms on WordPress.org', 'wpforms-lite' ); ?>
<span class="dashicons dashicons-external"></span></a>
</div>
</div>
<div id="wpforms-challenge-contact-popup" class="wpforms-challenge-popup">
<div class="wpforms-challenge-popup-header wpforms-challenge-popup-header-contact">
<i class="wpforms-challenge-popup-close fa fa-times-circle fa-lg"></i>
</div>
<div class="wpforms-challenge-popup-content">
<form id="wpforms-challenge-contact-form">
<h3><?php esc_html_e( 'Help us improve WPForms', 'wpforms-lite' ); ?></h3>
<p>
<?php
echo esc_html(
sprintf(
/* translators: %1$d - Number of minutes; %2$s - Single or plural word 'minute'. */
__( 'We\'re sorry that it took longer than %1$d %2$s to create a form. Our goal is to create the most beginner friendly WordPress form plugin. Please take a moment to let us know how we can improve WPForms.', 'wpforms-lite' ),
absint( $minutes ),
_n( 'minute', 'minutes', absint( $minutes ), 'wpforms-lite' )
)
);
?>
</p>
<textarea class="wpforms-challenge-contact-message"></textarea>
<label>
<input type="checkbox" class="wpforms-challenge-contact-permission"><?php esc_html_e( 'Yes, I give WPForms permission to contact me for any follow up questions.', 'wpforms-lite' ); ?>
</label>
<button type="submit" class="wpforms-challenge-popup-btn wpforms-challenge-popup-contact-btn"><?php esc_html_e( 'Submit Feedback', 'wpforms-lite' ); ?></button>
</form>
</div>
</div>
</div>

View File

@@ -0,0 +1,78 @@
<?php
/**
* Challenge main modal window template.
*
* @since 1.6.2
*
* @var string $state
* @var integer $step
* @var integer $minutes
*/
if ( ! \defined( 'ABSPATH' ) ) {
exit;
}
?>
<div class="wpforms-challenge <?php echo 'start' === $state ? 'wpforms-challenge-start' : ''; ?>"
data-wpforms-challenge-saved-step="<?php echo absint( $step ); ?>">
<div class="wpforms-challenge-list-block">
<i class="list-block-button toggle-list" title="<?php esc_attr_e( 'Toggle list', 'wpforms-lite' ); ?>"></i>
<i class="list-block-button challenge-skip" title="<?php esc_attr_e( 'Skip challenge', 'wpforms-lite' ); ?>"
data-cancel-title="<?php esc_attr_e( 'Cancel challenge', 'wpforms-lite' ); ?>"></i>
<p>
<?php
echo wp_kses(
sprintf(
/* translators: %1$d - Number of minutes; %2$s - Single or plural word 'minute'. */
__( 'Complete the <b>WPForms Challenge</b> and get up and running within %1$d&nbsp;%2$s.', 'wpforms-lite' ),
absint( $minutes ),
_n( 'minute', 'minutes', absint( $minutes ), 'wpforms-lite' )
),
[ 'b' => [] ]
);
?>
</p>
<ul class="wpforms-challenge-list">
<li class="wpforms-challenge-step1-item"><?php esc_html_e( 'Name Your Form', 'wpforms-lite' ); ?></li>
<li class="wpforms-challenge-step2-item"><?php esc_html_e( 'Select a Template', 'wpforms-lite' ); ?></li>
<li class="wpforms-challenge-step3-item"><?php esc_html_e( 'Add Fields to Your Form', 'wpforms-lite' ); ?></li>
<li class="wpforms-challenge-step4-item"><?php esc_html_e( 'Check Notifications', 'wpforms-lite' ); ?></li>
<li class="wpforms-challenge-step5-item"><?php esc_html_e( 'Embed in a Page', 'wpforms-lite' ); ?></li>
<li class="wpforms-challenge-completed"><?php esc_html_e( 'Challenge Complete', 'wpforms-lite' ); ?></li>
</ul>
</div>
<div class="wpforms-challenge-bar" style="display:none">
<div></div>
</div>
<div class="wpforms-challenge-block-timer">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/challenge/sullie-circle.png' ); ?>" alt="<?php esc_html_e( 'Sullie the WPForms mascot', 'wpforms-lite' ); ?>">
<div>
<h3><?php esc_html_e( 'WPForms Challenge', 'wpforms-lite' ); ?></h3>
<p>
<?php
printf(
/* translators: %s - minutes in 2:00 format. */
esc_html__( '%s remaining', 'wpforms-lite' ),
'<span id="wpforms-challenge-timer">' . absint( $minutes ) . ':00</span>'
);
?>
</p>
</div>
</div>
<div class="wpforms-challenge-block-under-timer">
<?php if ( 'start' === $state ) : ?>
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wpforms-builder&challenge=init' ) ); ?>" class="wpforms-btn wpforms-btn-md wpforms-btn-orange wpforms-challenge-start">
<?php esc_html_e( 'Start Challenge', 'wpforms-lite' ); ?>
</a>
<?php elseif ( 'progress' === $state ) : ?>
<button type="button" class="wpforms-btn wpforms-btn-md wpforms-btn-grey wpforms-challenge-pause"><?php esc_html_e( 'Pause', 'wpforms-lite' ); ?></button>
<button type="button" class="wpforms-btn wpforms-btn-md wpforms-btn-orange wpforms-challenge-resume" style="display: none;"><?php esc_html_e( 'Continue', 'wpforms-lite' ); ?></button>
<button type="button" class="wpforms-btn wpforms-btn-md wpforms-btn-orange wpforms-challenge-end" style="display: none;"><?php esc_html_e( 'End Challenge', 'wpforms-lite' ); ?></button>
<?php endif; ?>
</div>
</div>

View File

@@ -0,0 +1,24 @@
<?php
/**
* Challenge CTA on WPForms welcome activation screen HTML template.
*
* @since 1.6.2
*/
if ( ! \defined( 'ABSPATH' ) ) {
exit;
}
?>
<div class="challenge">
<div class="block">
<h1><?php esc_html_e( 'Take the WPForms Challenge', 'wpforms-lite' ); ?></h1>
<h6><?php esc_html_e( 'Create your first form with our guided setup wizard in less than 5 minutes to experience the WPForms difference.', 'wpforms-lite' ); ?></h6>
<div class="button-wrap">
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wpforms-builder&challenge=init' ) ); ?>" class="wpforms-btn wpforms-btn-lg wpforms-btn-orange">
<?php esc_html_e( 'Start the WPForms Challenge', 'wpforms-lite' ); ?>
</a>
</div>
</div>
</div>

View File

@@ -0,0 +1,46 @@
<?php
/**
* No forms HTML template.
*
* @since 1.6.2.3
*/
if ( ! \defined( 'ABSPATH' ) ) {
exit;
}
?>
<div class="wpforms-admin-empty-state-container wpforms-admin-no-forms">
<h2 class="waving-hand-emoji"><?php esc_html_e( 'Hi there!', 'wpforms-lite' ); ?></h2>
<p><?php esc_html_e( 'It looks like you havent created any forms yet.', 'wpforms-lite' ); ?></p>
<p><?php esc_html_e( 'You can use WPForms to build contact forms, surveys, payment forms, and more with just a few clicks.', 'wpforms-lite' ); ?></p>
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/empty-states/no-forms.svg' ); ?>" alt=""/>
<br>
<?php if ( wpforms_current_user_can( 'create_forms' ) ) : ?>
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wpforms-builder' ) ); ?>" class="wpforms-btn add-new-h2 wpforms-btn-orange"><?php esc_html_e( 'Create Your Form', 'wpforms-lite' ); ?></a>
<?php endif; ?>
<p class="wpforms-admin-no-forms-footer">
<?php
printf(
wp_kses( /* translators: %s - URL to the documentation article. */
__( 'Need some help? Check out our <a href="%s" target="_blank" rel="noopener noreferrer">comprehensive guide</a>.', 'wpforms-lite' ),
[
'a' => [
'href' => [],
'target' => [],
'rel' => [],
],
]
),
'https://wpforms.com/docs/creating-first-form/'
);
?>
</p>
</div>

View File

@@ -0,0 +1,78 @@
<?php
/**
* Form Embed Wizard.
* Embed popup HTML template.
*
* @since 1.6.2
*/
if ( ! \defined( 'ABSPATH' ) ) {
exit;
}
$pages_exists = ! empty( $args['dropdown_pages'] ) ? 1 : 0;
?>
<div id="wpforms-admin-form-embed-wizard-container" class="wpforms-admin-popup-container">
<div id="wpforms-admin-form-embed-wizard" class="wpforms-admin-popup" data-pages-exists="<?php echo esc_attr( $pages_exists ); ?>">
<div class="wpforms-admin-popup-content">
<h3><?php esc_html_e( 'Embed in a Page', 'wpforms-lite' ); ?></h3>
<div id="wpforms-admin-form-embed-wizard-content-initial">
<p class="no-gap"><b><?php esc_html_e( 'We can help embed your form with just a few clicks!', 'wpforms-lite' ); ?></b></p>
<?php if ( ! empty( $args['user_can_edit_pages'] ) ) : ?>
<p><?php esc_html_e( 'Would you like to embed your form in an existing page, or create a new one?', 'wpforms-lite' ); ?></p>
<?php endif; ?>
</div>
<?php if ( ! empty( $args['user_can_edit_pages'] ) ) : ?>
<div id="wpforms-admin-form-embed-wizard-content-select-page" style="display: none;">
<p><?php esc_html_e( 'Select the page you would like to embed your form in.', 'wpforms-lite' ); ?></p>
</div>
<div id="wpforms-admin-form-embed-wizard-content-create-page" style="display: none;">
<p><?php esc_html_e( 'What would you like to call the new page?', 'wpforms-lite' ); ?></p>
</div>
<div id="wpforms-admin-form-embed-wizard-section-btns" class="wpforms-admin-popup-bottom">
<button type="button" data-action="select-page" class="wpforms-admin-popup-btn"><?php esc_html_e( 'Select Existing Page', 'wpforms-lite' ); ?></button>
<button type="button" data-action="create-page" class="wpforms-admin-popup-btn"><?php esc_html_e( 'Create New Page', 'wpforms-lite' ); ?></button>
</div>
<div id="wpforms-admin-form-embed-wizard-section-go" class="wpforms-admin-popup-bottom wpforms-admin-popup-flex" style="display: none;">
<?php echo $args['dropdown_pages']; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
<input type="text" id="wpforms-admin-form-embed-wizard-new-page-title" value="" placeholder="<?php esc_attr_e( 'Name Your Page', 'wpforms-lite' ); ?>">
<button type="button" data-action="go" class="wpforms-admin-popup-btn"><?php esc_html_e( 'Lets Go!', 'wpforms-lite' ); ?></button>
</div>
<?php endif; ?>
<div id="wpforms-admin-form-embed-wizard-section-toggles" class="wpforms-admin-popup-bottom">
<p class="secondary">
<?php
printf(
wp_kses( /* translators: %1$s - Video tutorial toggle CSS classes, %2$s - shortcode toggle CSS classes. */
__( 'You can also <a href="#" class="%1$s">embed your form manually</a> or <a href="#" class="%2$s">use a shortcode</a>', 'wpforms-lite' ),
[
'a' => [
'href' => [],
'class' => [],
],
]
),
'tutorial-toggle wpforms-admin-popup-toggle',
'shortcode-toggle wpforms-admin-popup-toggle'
);
?>
</p>
<iframe style="display: none;" src="about:blank" frameborder="0" id="wpforms-admin-form-embed-wizard-tutorial" allowfullscreen width="450" height="256"></iframe>
<div id="wpforms-admin-form-embed-wizard-shortcode-wrap" style="display: none;">
<input type="text" id="wpforms-admin-form-embed-wizard-shortcode" class="wpforms-admin-popup-shortcode" disabled />
<span id="wpforms-admin-form-embed-wizard-shortcode-copy" title="<?php esc_attr_e( 'Copy embed code to clipboard', 'wpforms-lite' ); ?>">
<i class="fa fa-files-o" aria-hidden="true"></i>
</span>
</div>
</div>
<div id="wpforms-admin-form-embed-wizard-section-goback" class="wpforms-admin-popup-bottom" style="display: none;">
<p class="secondary">
<a href="#" class="wpforms-admin-popup-toggle initialstate-toggle">« <?php esc_html_e( 'Go back', 'wpforms-lite' ); ?></a>
</p>
</div>
</div>
<i class="fa fa-times wpforms-admin-popup-close"></i>
</div>
</div>

View File

@@ -0,0 +1,43 @@
<?php
/**
* Form Embed Wizard.
* Embed page tooltip HTML template.
*
* @since 1.6.2
*/
if ( ! \defined( 'ABSPATH' ) ) {
exit;
}
?>
<div class="wpforms-admin-form-embed-wizard-tooltip">
<div id="wpforms-admin-form-embed-wizard-tooltip-content">
<?php if ( wpforms_is_gutenberg_active() ) : // Gutenberg content. ?>
<h3><?php esc_html_e( 'Add a Block', 'wpforms-lite' ); ?></h3>
<p>
<?php
printf(
wp_kses( /* translators: %s - Link to the WPForms documentation page. */
__( 'Click the plus button, search for WPForms, click the block to<br>embed it. <a href="%s" target="_blank" rel="noopener noreferrer">Learn More</a>.', 'wpforms-lite' ),
[
'a' => [
'href' => [],
'rel' => [],
'target' => [],
],
'br' => [],
]
),
'https://wpforms.com/docs/creating-first-form/#display-form'
);
?>
</p>
<i class="wpforms-admin-form-embed-wizard-tooltips-red-arrow"></i>
<?php else : ?>
<h3><?php esc_html_e( 'Embed in a Page', 'wpforms-lite' ); ?></h3>
<p><?php esc_html_e( 'Click the “Add Form” button, select your form, then add the embed code.', 'wpforms-lite' ); ?></p>
<?php endif; ?>
<button type="button" class="wpforms-admin-form-embed-wizard-done-btn"><?php esc_html_e( 'Done', 'wpforms-lite' ); ?></button>
</div>
</div>

View File

@@ -0,0 +1,18 @@
<p><?php esc_html_e( "hCaptcha is a free and privacy-oriented spam prevention service. Within your forms, hCaptcha will display a checkbox asking users to prove they're human (much like Google's v2 Checkbox reCAPTCHA). This is a simple step for legitimate site visitors, but is extremely effective at blocking spam.", 'wpforms-lite' ); ?></p>
<p>
<?php
printf(
wp_kses( /* translators: %s - WPForms.com Setup hCaptcha URL. */
__( 'For more details on how hCaptcha works, as well as a step by step setup guide, please check out our <a href="%s" target="_blank" rel="noopener noreferrer">documentation</a>.', 'wpforms-lite' ),
[
'a' => [
'href' => [],
'target' => [],
'rel' => [],
],
]
),
'https://wpforms.com/docs/how-to-set-up-and-use-hcaptcha-in-wpforms'
);
?>
</p>

View File

@@ -0,0 +1,46 @@
<p><?php esc_html_e( 'reCAPTCHA is a free anti-spam service from Google which helps to protect your website from spam and abuse while letting real people pass through with ease.', 'wpforms-lite' ); ?></p>
<p><?php esc_html_e( 'Google offers 3 versions of reCAPTCHA (all supported within WPForms):', 'wpforms-lite' ); ?></p>
<ul style="list-style: disc;margin-left: 20px;">
<li>
<?php
echo wp_kses(
__( '<strong>v2 Checkbox reCAPTCHA</strong>: Prompts users to check a box to prove they\'re human.', 'wpforms-lite' ),
[ 'strong' => [] ]
);
?>
</li>
<li>
<?php
echo wp_kses(
__( '<strong>v2 Invisible reCAPTCHA</strong>: Uses advanced technology to detect real users without requiring any input.', 'wpforms-lite' ),
[ 'strong' => [] ]
);
?>
</li>
<li>
<?php
echo wp_kses(
__( '<strong>v3 reCAPTCHA</strong>: Uses a behind-the-scenes scoring system to detect abusive traffic, and lets you decide the minimum passing score. Recommended for advanced use only (or if using Google AMP).', 'wpforms-lite' ),
[ 'strong' => [] ]
);
?>
</li>
</ul>
<p><?php esc_html_e( 'Sites already using one type of reCAPTCHA will need to create new site keys before switching to a different option.', 'wpforms-lite' ); ?></p>
<p>
<?php
printf(
wp_kses( /* translators: %s - WPForms.com Setup reCAPTCHA URL. */
__( '<a href="%s" target="_blank" rel="noopener noreferrer">Read our walk through</a> to learn more and for step-by-step directions.', 'wpforms-lite' ),
[
'a' => [
'href' => [],
'target' => [],
'rel' => [],
],
]
),
'http://wpforms.com/docs/how-to-set-up-and-use-recaptcha-in-wpforms/'
);
?>
</p>