diff --git a/plugins/woocommerce-admin/client/settings/index.js b/plugins/woocommerce-admin/client/settings/index.js index a67d47dec27..4b89da92f77 100644 --- a/plugins/woocommerce-admin/client/settings/index.js +++ b/plugins/woocommerce-admin/client/settings/index.js @@ -22,10 +22,7 @@ const Settings = ( { params } ) => {
- +

Content here

diff --git a/plugins/woocommerce-admin/client/settings/section-nav.js b/plugins/woocommerce-admin/client/settings/section-nav.js index 329f9da24b6..d5a7e365b25 100644 --- a/plugins/woocommerce-admin/client/settings/section-nav.js +++ b/plugins/woocommerce-admin/client/settings/section-nav.js @@ -4,12 +4,15 @@ import { __experimentalItemGroup as ItemGroup, __experimentalItem as Item, + Button, } from '@wordpress/components'; +import { getNewPath, navigateTo, getQuery } from '@woocommerce/navigation'; +import classnames from 'classnames'; -export const SectionNav = ( { data, section } ) => { +export const SectionNav = ( { data } ) => { const { sections } = data; const sectionKeys = Object.keys( sections ); - console.log( section ); + const { section } = getQuery(); if ( sectionKeys.length === 1 ) { return null; @@ -17,9 +20,25 @@ export const SectionNav = ( { data, section } ) => { return ( <> - + { sectionKeys.map( ( key ) => ( - { sections[ key ].label } + + + ) ) } diff --git a/plugins/woocommerce-admin/client/settings/style.scss b/plugins/woocommerce-admin/client/settings/style.scss index 289a5aa3dd3..f14ed2ddeae 100644 --- a/plugins/woocommerce-admin/client/settings/style.scss +++ b/plugins/woocommerce-admin/client/settings/style.scss @@ -28,7 +28,7 @@ .woocommerce-settings-layout { width: 100%; display: flex; - gap: 10px; + gap: 30px; padding: 50px 16px 16px 16px; } @@ -39,3 +39,20 @@ .woocommerce-settings-content { flex: 1; } + +.woocommerce-settings-section-nav { + .components-item { + &.active-section { + .components-button { + background-color: lightgray; + } + } + } + + .components-button { + width: 100%; + border: none !important; + box-shadow: none !important; + padding: 20px 12px; + } +}