Skip to content

Commit e169067

Browse files
authored
Merge pull request #741 from ProgressPlanner/filip/onboarding-tweaks
Onboarding tweaks
2 parents 8a219fa + bf2d64f commit e169067

File tree

15 files changed

+136
-79
lines changed

15 files changed

+136
-79
lines changed

assets/css/onboarding/onboarding.css

Lines changed: 62 additions & 56 deletions
Large diffs are not rendered by default.

assets/js/onboarding/steps/OnboardingStep.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ class OnboardingStep {
300300
const dashboardText =
301301
this.wizard.config?.l10n?.dashboard ||
302302
'Take me to the Recommendations dashboard';
303-
this.nextBtn.textContent = dashboardText;
303+
this.nextBtn.innerHTML = dashboardText;
304304
}
305305
}
306306

classes/class-onboard-wizard.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,8 @@ public function add_popover_scripts() {
315315
'startOnboarding' => \esc_html__( 'Start onboarding', 'progress-planner' ),
316316
/* translators: %s: Progress Planner name. */
317317
'privacyPolicyError' => sprintf( \esc_html__( 'You need to agree with the privacy policy to use the %s plugin.', 'progress-planner' ), \esc_html( \progress_planner()->get_ui__branding()->get_admin_menu_name() ) ),
318-
'dashboard' => \esc_html__( 'Take me to the dashboard', 'progress-planner' ),
318+
/* translators: %s: arrow icon */
319+
'dashboard' => sprintf( \esc_html__( 'Take me to the dashboard %s', 'progress-planner' ), '<span class="dashicons dashicons-arrow-right-alt2"></span>' ),
319320
'backToRecommendations' => \esc_html__( 'Back to recommendations', 'progress-planner' ),
320321
],
321322
'errorIcon' => \progress_planner()->get_asset( 'images/icon_exclamation_circle.svg' ),

views/onboarding/badges.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,12 @@
5656
</div>
5757
<div class="tour-footer">
5858
<div class="prpl-tour-next-wrapper">
59-
<button class="prpl-tour-next prpl-btn prpl-btn-secondary"><?php \esc_html_e( 'Got it', 'progress-planner' ); ?></button>
59+
<button class="prpl-tour-next prpl-btn prpl-btn-secondary">
60+
<?php
61+
/* translators: %s: arrow icon */
62+
printf( \esc_html__( 'Got it %s', 'progress-planner' ), '<span class="dashicons dashicons-arrow-right-alt2"></span>' );
63+
?>
64+
</button>
6065
</div>
6166
</div>
6267
</script>

views/onboarding/email-frequency.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,12 @@
9696
</div>
9797
<div class="tour-footer">
9898
<div class="prpl-tour-next-wrapper">
99-
<button class="prpl-tour-next prpl-btn prpl-btn-secondary"><?php \esc_html_e( 'Got it', 'progress-planner' ); ?></button>
99+
<button class="prpl-tour-next prpl-btn prpl-btn-secondary">
100+
<?php
101+
/* translators: %s: arrow icon */
102+
printf( \esc_html__( 'Got it %s', 'progress-planner' ), '<span class="dashicons dashicons-arrow-right-alt2"></span>' );
103+
?>
104+
</button>
100105
</div>
101106
</div>
102107
</script>

views/onboarding/first-task.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,15 @@
3131
</div>
3232
<div class="prpl-column">
3333
<?php if ( isset( $task ) ) : ?>
34-
<?php \progress_planner()->the_view( 'onboarding/tasks/' . $task['task_id'] . '.php', [ 'task' => $task ] ); ?>
34+
<?php
35+
\progress_planner()->the_view(
36+
'onboarding/tasks/' . $task['task_id'] . '.php',
37+
[
38+
'task' => $task,
39+
'show_chevron' => true,
40+
]
41+
);
42+
?>
3543
<?php endif; ?>
3644
</div>
3745
</div>

views/onboarding/more-tasks.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,12 @@
7474
</div>
7575
<div class="tour-footer">
7676
<div class="prpl-tour-next-wrapper">
77-
<button class="prpl-tour-next prpl-btn prpl-btn-secondary"><?php \esc_html_e( 'Take me to the dashboard', 'progress-planner' ); ?> &rsaquo;</button>
77+
<button class="prpl-tour-next prpl-btn prpl-btn-secondary">
78+
<?php
79+
/* translators: %s: arrow icon */
80+
printf( \esc_html__( 'Take me to the dashboard %s', 'progress-planner' ), '<span class="dashicons dashicons-arrow-right-alt2"></span>' );
81+
?>
82+
</button>
7883
</div>
7984
</div>
8085
</script>

views/onboarding/quit-confirmation.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@
1818
<div class="prpl-quit-confirmation">
1919
<div class="prpl-error-box">
2020
<span class="prpl-error-icon">
21-
<?php \progress_planner()->the_asset( 'images/icon_exclamation_circle.svg' ); ?>
21+
<?php \progress_planner()->the_asset( 'images/icon_exclamation_circle_solid.svg' ); ?>
2222
</span>
2323
<div>
2424
<h3><?php \esc_html_e( 'Are you sure you want to quit?', 'progress-planner' ); ?></h3>
2525
<p>
2626
<?php
2727
/* translators: %s: Progress Planner name. */
28-
\printf( \esc_html__( 'You need to finish the onboarding before you can work with the %s and start improving your site.', 'progress-planner' ), \esc_html( \progress_planner()->get_ui__branding()->get_admin_menu_name() ) );
28+
\printf( \esc_html__( 'You need to finish the onboarding before you can work with the %s plugin and start improving your site.', 'progress-planner' ), \esc_html( \progress_planner()->get_ui__branding()->get_admin_menu_name() ) );
2929
?>
3030
</p>
3131
</div>

views/onboarding/settings.php

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,10 @@
119119
class="prpl-btn prpl-save-setting-btn"
120120
disabled
121121
>
122-
<?php \esc_html_e( 'Save setting', 'progress-planner' ); ?>
122+
<?php
123+
/* translators: %s: arrow icon */
124+
printf( \esc_html__( 'Save setting %s', 'progress-planner' ), '<span class="dashicons dashicons-arrow-right-alt2"></span>' );
125+
?>
123126
</button>
124127
</div>
125128
</div>
@@ -134,7 +137,12 @@ class="prpl-btn prpl-save-setting-btn"
134137
<div class="prpl-columns-wrapper-flex">
135138
<div class="prpl-column">
136139
<div class="prpl-background-content">
137-
<p><?php echo \esc_html( $prpl_page_type['description'] ); ?></p>
140+
<p>
141+
<?php \esc_html_e( 'Choose the post types you actively use for your content.', 'progress-planner' ); ?>
142+
</p>
143+
<p>
144+
<?php \esc_html_e( 'We\'ll track and reward progress only on the ones you select.', 'progress-planner' ); ?>
145+
</p>
138146
</div>
139147
</div>
140148
<div class="prpl-column">
@@ -143,12 +151,6 @@ class="prpl-btn prpl-save-setting-btn"
143151
<?php \esc_html_e( 'Settings:', 'progress-planner' ); ?> <?php \esc_html_e( 'Valuable post types', 'progress-planner' ); ?>
144152
<span class="prpl-settings-progress"><?php echo \esc_html( $prpl_current_step_number ); ?>/<?php echo \esc_html( $prpl_total_number_of_steps ); ?></span>
145153
</h3>
146-
<p>
147-
<?php \esc_html_e( 'Choose the post types you actively use for your content.', 'progress-planner' ); ?>
148-
</p>
149-
<p>
150-
<?php \esc_html_e( 'We\'ll track and reward progress only on the ones you select.', 'progress-planner' ); ?>
151-
</p>
152154
</div>
153155

154156
<div class="prpl-setting-content">
@@ -190,7 +192,10 @@ class="prpl-post-type-toggle-input"
190192
class="prpl-btn prpl-save-setting-btn"
191193
disabled
192194
>
193-
<?php \esc_html_e( 'Save setting', 'progress-planner' ); ?>
195+
<?php
196+
/* translators: %s: arrow icon */
197+
printf( \esc_html__( 'Save setting %s', 'progress-planner' ), '<span class="dashicons dashicons-arrow-right-alt2"></span>' );
198+
?>
194199
</button>
195200
</div>
196201
</div>
@@ -200,7 +205,12 @@ class="prpl-btn prpl-save-setting-btn"
200205
</div>
201206
<div class="tour-footer">
202207
<div class="prpl-tour-next-wrapper">
203-
<button class="prpl-tour-next prpl-btn prpl-btn-secondary"><?php \esc_html_e( 'Next', 'progress-planner' ); ?></button>
208+
<button class="prpl-tour-next prpl-btn prpl-btn-secondary">
209+
<?php
210+
/* translators: %s: arrow icon */
211+
printf( \esc_html__( 'Next %s', 'progress-planner' ), '<span class="dashicons dashicons-arrow-right-alt2"></span>' );
212+
?>
213+
</button>
204214
</div>
205215
</div>
206216
</script>

views/onboarding/tasks/core-blogdescription.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@
3030
<?php else : ?>
3131
<?php \esc_html_e( 'Set tagline', 'progress-planner' ); ?>
3232
<?php endif; ?>
33+
<?php if ( ! empty( $show_chevron ) ) : ?>
34+
<span class="dashicons dashicons-arrow-right-alt2"></span>
35+
<?php endif; ?>
3336
</button>
3437
</form>
3538
</div>

0 commit comments

Comments
 (0)