Нет описания

modal.php 3.3KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <?php
  2. /**
  3. * Challenge main modal window template.
  4. *
  5. * @since 1.6.2
  6. *
  7. * @var string $state
  8. * @var integer $step
  9. * @var integer $minutes
  10. */
  11. if ( ! \defined( 'ABSPATH' ) ) {
  12. exit;
  13. }
  14. ?>
  15. <div class="wpforms-challenge <?php echo 'start' === $state ? 'wpforms-challenge-start' : ''; ?>"
  16. data-wpforms-challenge-saved-step="<?php echo absint( $step ); ?>">
  17. <div class="wpforms-challenge-list-block">
  18. <i class="list-block-button toggle-list" title="<?php esc_attr_e( 'Toggle list', 'wpforms-lite' ); ?>"></i>
  19. <i class="list-block-button challenge-skip" title="<?php esc_attr_e( 'Skip challenge', 'wpforms-lite' ); ?>"
  20. data-cancel-title="<?php esc_attr_e( 'Cancel challenge', 'wpforms-lite' ); ?>"></i>
  21. <p>
  22. <?php
  23. echo wp_kses(
  24. sprintf(
  25. /* translators: %1$d - Number of minutes; %2$s - Single or plural word 'minute'. */
  26. __( 'Complete the <b>WPForms Challenge</b> and get up and running within %1$d&nbsp;%2$s.', 'wpforms-lite' ),
  27. absint( $minutes ),
  28. _n( 'minute', 'minutes', absint( $minutes ), 'wpforms-lite' )
  29. ),
  30. [ 'b' => [] ]
  31. );
  32. ?>
  33. </p>
  34. <ul class="wpforms-challenge-list">
  35. <li class="wpforms-challenge-step1-item"><?php esc_html_e( 'Name Your Form', 'wpforms-lite' ); ?></li>
  36. <li class="wpforms-challenge-step2-item"><?php esc_html_e( 'Select a Template', 'wpforms-lite' ); ?></li>
  37. <li class="wpforms-challenge-step3-item"><?php esc_html_e( 'Add Fields to Your Form', 'wpforms-lite' ); ?></li>
  38. <li class="wpforms-challenge-step4-item"><?php esc_html_e( 'Check Notifications', 'wpforms-lite' ); ?></li>
  39. <li class="wpforms-challenge-step5-item"><?php esc_html_e( 'Embed in a Page', 'wpforms-lite' ); ?></li>
  40. <li class="wpforms-challenge-completed"><?php esc_html_e( 'Challenge Complete', 'wpforms-lite' ); ?></li>
  41. </ul>
  42. </div>
  43. <div class="wpforms-challenge-bar" style="display:none">
  44. <div></div>
  45. </div>
  46. <div class="wpforms-challenge-block-timer">
  47. <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' ); ?>">
  48. <div>
  49. <h3><?php esc_html_e( 'WPForms Challenge', 'wpforms-lite' ); ?></h3>
  50. <p>
  51. <?php
  52. printf(
  53. /* translators: %s - minutes in 2:00 format. */
  54. esc_html__( '%s remaining', 'wpforms-lite' ),
  55. '<span id="wpforms-challenge-timer">' . absint( $minutes ) . ':00</span>'
  56. );
  57. ?>
  58. </p>
  59. </div>
  60. </div>
  61. <div class="wpforms-challenge-block-under-timer">
  62. <?php if ( 'start' === $state ) : ?>
  63. <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">
  64. <?php esc_html_e( 'Start Challenge', 'wpforms-lite' ); ?>
  65. </a>
  66. <?php elseif ( 'progress' === $state ) : ?>
  67. <button type="button" class="wpforms-btn wpforms-btn-md wpforms-btn-grey wpforms-challenge-pause"><?php esc_html_e( 'Pause', 'wpforms-lite' ); ?></button>
  68. <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>
  69. <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>
  70. <?php endif; ?>
  71. </div>
  72. </div>