Skip to content

changes pull #489

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 10 additions & 11 deletions templates/admin/complete-screen.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
<?php

/**
* Template for the admin Setup Complete screen
* Template for the admin Setup Complete screen (Open Source Version)
*
* @var bool $new_account
*
* @var string $settings_url
* @var string $create_url
* @var string $support_url
Expand All @@ -13,18 +12,18 @@
* @var string $settings_sections
*/

use BigCommerce\Settings\Screens\Onboarding_Complete_Screen;
use OpenSource\Settings\Screens\Onboarding_Complete_Screen;

?>
<div class="bc-plugin-page-header">
<img src="<?php echo esc_url( bigcommerce()->plugin_dir_url() . 'assets/img/admin/big-commerce-logo.svg' ); ?>" alt="<?php esc_attr_e( 'BigCommerce', 'bigcommerce' ); ?>">
<div class="plugin-page-header">
<img src="<?php echo esc_url( plugin_dir_url( __FILE__ ) . 'assets/img/admin/plugin-logo.svg' ); ?>" alt="<?php esc_attr_e( 'Open Source Plugin', 'opensource' ); ?>">
</div>
<?php do_action( 'bigcommerce/settings/before_title/page=' . Onboarding_Complete_Screen::NAME ); ?>
<div class="bc-welcome">
<?php do_action( 'bigcommerce/settings/onboarding/progress' ); ?>
<div class="bc-welcome__content bc-welcome__content--complete">
<div class="bc-welcome__content-wrap">
<h1 class="bc-welcome__content-title"><?php esc_html_e( "You've successfully installed the BigCommerce for WordPress Plugin and connected your BigCommerce Store!", 'bigcommerce' ); ?></h1>
<?php do_action( 'opensource/settings/before_title/page=' . Onboarding_Complete_Screen::NAME ); ?>
<div class="welcome">
<?php do_action( 'opensource/settings/onboarding/progress' ); ?>
<div class="welcome__content welcome__content--complete">
<div class="welcome__content-wrap">
<h1 class="welcome__content-title"><?php esc_html_e( "You've successfully installed the Open Source Plugin and configured your settings!", 'opensource' ); ?></h1>
</div>
</div>

Expand Down
33 changes: 16 additions & 17 deletions templates/admin/next-steps.php
Original file line number Diff line number Diff line change
@@ -1,43 +1,42 @@
<?php
/**
* Template to display next onboarding steps on the settings screen
* Template to display next onboarding steps on the settings screen (Open Source Version)
*
* @var array $required
* @var array $optional
* @var bool $new_account
*/

printf( '<div class="bc-complete__next-steps-header"><i class="bc-icon icon-bc-authenticate"></i><h2 class="bc-next-step-heading">%s</h2><p class="bc-complete__new-account-email">%s</p></div>',
$new_account ? __( 'Authenticate and Confirm your BigCommerce Account', 'bigcommerce' ) : __( 'Next Steps', 'bigcommerce' ),
$new_account ? __( 'Check your email for a link to confirm your account.', 'bigcommerce' ) : __( 'Complete the steps below to optimize your BigCommerce for WordPress experience.', 'bigcommerce' )
printf( '<div class="complete__next-steps-header"><i class="icon icon-authenticate"></i><h2 class="next-step-heading">%s</h2><p class="complete__new-account-email">%s</p></div>',
$new_account ? __( 'Authenticate and Confirm your Open Source Account', 'opensource' ) : __( 'Next Steps', 'opensource' ),
$new_account ? __( 'Check your email for a link to confirm your account.', 'opensource' ) : __( 'Complete the steps below to optimize your Open Source Plugin experience.', 'opensource' )
);

if ( ! empty( $required ) ) {
printf( '<h3 class="bc-next-steps__section-title">%s</h3>', esc_html( __( 'Required Steps', 'bigcommerce' ) ) );
printf( '<h3 class="next-steps__section-title">%s</h3>', esc_html( __( 'Required Steps', 'opensource' ) ) );
foreach ( $required as $key => $step ) {
printf( '<div class="bc-next-step-wrapper bc-required-step %s">', sanitize_html_class( 'bc-next-step--' . $key ) );
printf( '<div class="bc-next-step-status-wrapper">' );
printf( '<i class="bc-icon %s"></i> <span class="bc-next-step-incomplete">%s</span>', sanitize_html_class( 'icon-bc-' . $step['icon'] ), esc_html( __( 'Incomplete', 'bigcommerce' ) ) );
printf( '<div class="next-step-wrapper required-step %s">', sanitize_html_class( 'next-step--' . $key ) );
printf( '<div class="next-step-status-wrapper">' );
printf( '<i class="icon %s"></i> <span class="next-step-incomplete">%s</span>', sanitize_html_class( 'icon-' . $step['icon'] ), esc_html( __( 'Incomplete', 'opensource' ) ) );
printf( '</div>' );
printf( '<h3 class="h2 bc-next-step-heading">%s</h3>', esc_html( $step['heading'] ) );
printf( '<h3 class="h2 next-step-heading">%s</h3>', esc_html( $step['heading'] ) );
if ( ! empty( $step['url'] ) && ! empty( $step['label'] ) ) {
printf( '<a href="%s" class="bc-next-step-cta" target="_blank" rel="noopener">%s</a>', esc_url( $step['url'] ), esc_html( $step['label'] ) );
printf( '<a href="%s" class="next-step-cta" target="_blank" rel="noopener">%s</a>', esc_url( $step['url'] ), esc_html( $step['label'] ) );
}
echo '</div>';
}
}


if ( ! empty( $optional ) ) {
printf( '<h3 class="bc-next-steps__section-title">%s</h3>', esc_html( __( 'Optional Steps', 'bigcommerce' ) ) );
printf( '<h3 class="next-steps__section-title">%s</h3>', esc_html( __( 'Optional Steps', 'opensource' ) ) );
foreach ( $optional as $key => $step ) {
printf( '<div class="bc-next-step-wrapper bc-optional-step %s">', sanitize_html_class( 'bc-next-step--' . $key ) );
printf( '<div class="bc-next-step-status-wrapper">' );
printf( '<i class="bc-icon %s"></i> <span class="bc-next-step-incomplete">%s</span>', sanitize_html_class( 'icon-bc-' . $step['icon'] ), esc_html( __( 'Incomplete', 'bigcommerce' ) ) );
printf( '<div class="next-step-wrapper optional-step %s">', sanitize_html_class( 'next-step--' . $key ) );
printf( '<div class="next-step-status-wrapper">' );
printf( '<i class="icon %s"></i> <span class="next-step-incomplete">%s</span>', sanitize_html_class( 'icon-' . $step['icon'] ), esc_html( __( 'Incomplete', 'opensource' ) ) );
printf( '</div>' );
printf( '<h3 class="h2 bc-next-step-heading">%s</h3>', esc_html( $step['heading'] ) );
printf( '<h3 class="h2 next-step-heading">%s</h3>', esc_html( $step['heading'] ) );
if ( ! empty( $step['url'] ) && ! empty( $step['label'] ) ) {
printf( '<a href="%s" class="bc-next-step-cta" target="_blank" rel="noopener">%s</a>', esc_url( $step['url'] ), esc_html( $step['label'] ) );
printf( '<a href="%s" class="next-step-cta" target="_blank" rel="noopener">%s</a>', esc_url( $step['url'] ), esc_html( $step['label'] ) );
}
echo '</div>';
}
Expand Down
18 changes: 9 additions & 9 deletions templates/admin/resources-screen.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,22 +9,22 @@
*/
?>
<?php echo $page_header; ?>
<div class="bc-resources" data-js="bc-resources-wrapper">
<script id="bigcommerce-resources" data-js="bigcommerce-resources-json"><?php echo 'var bigcommerce_resources_json = ' . wp_json_encode( $resources ); ?></script>
<header class="bc-resources-header bg-geometric-bg">
<div class="open-source-resources" data-js="open-source-resources-wrapper">
<script id="open-source-resources" data-js="open-source-resources-json"><?php echo 'var open_source_resources_json = ' . wp_json_encode( $resources ); ?></script>
<header class="open-source-resources-header bg-geometric-bg">

<div class="bc-resources-header--inner bc-resources-tabs__max-width">
<h1 class="bc-resources-heading"><?php echo esc_html( $page_title ); ?></h1>
<div class="open-source-resources-header--inner open-source-resources-tabs__max-width">
<h1 class="open-source-resources-heading"><?php echo esc_html( $page_title ); ?></h1>

<section class="bc-resources-tabs">
<div class="bc-resources-tabs__header" data-js="bc-resources-tabs-header">
<ul class="bc-resources-tabs__list bc-resources-tabs__max-width" data-js="bc-resources-tabs-list" role="tablist">
<section class="open-source-resources-tabs">
<div class="open-source-resources-tabs__header" data-js="open-source-resources-tabs-header">
<ul class="open-source-resources-tabs__list open-source-resources-tabs__max-width" data-js="open-source-resources-tabs-list" role="tablist">
</ul>
</div>
</section>
</div>
</header>

<section class="bc-resources-content" data-js="bc-resources-tab-content">
<section class="open-source-resources-content" data-js="open-source-resources-tab-content">
</section>
</div>