8ebd33fe6b
* Use lazy loading to split up the size of the js downloaded * Use lazy loading to split up the size of the js downloaded * Add Moment Timezone plugin to reduce size of data file. * Lazy load header panels and use Dashicons for faster loading * Load assets from the correct publicPath * Load assets from the correct publicPath * PHP cs fixes * Fix missing quotes on string literal. * Fix PropType warning for lazy loaded component. * Separate the task list and dashboard chunks. * Lazy load dashboard sections. * Restore original icons and reduce size by importing only the icons needed * Lazy load alerts to save more Kb on initial load * Minify built JS in production mode. * Add preload tags for WC Admin assets. (https://github.com/woocommerce/woocommerce-admin/pull/4162) * Fix linting errors. * Add modified UnminifiedWebpackPlugin. * Produce minified and unminified bundles for all builds. * Remove unused variable from webpack config. * Run unminify after sourcemap generation. * Only hook after optimization if we're using a devtool. * Add minification suffix in Loader::get_url(). * Lazy load OBW on new home screen. * Move OBW style up a level to layout. * Hydrate ProfileWizard independently of withSelect and withDispatch * Fix order of composition and fallback function when using hydration. Co-authored-by: Jeff Stieler <jeff.m.stieler@gmail.com> Co-authored-by: Paul Sealock <psealock@gmail.com> |
||
---|---|---|
.. | ||
activity-panel | ||
test | ||
README.md | ||
index.js | ||
style.scss |
README.md
Header
A basic component for the app header. The header outputs breadcrumbs via the sections
prop (required) and access to the activity panel. It also sets the document title.
How to use:
import Header from 'header';
render: function() {
return (
<Header
sections={ [
[ '/analytics', __( 'Analytics', 'woocommerce-admin' ) ],
__( 'Report Title', 'woocommerce-admin' ),
] }
/>
);
}
Props
sections
(required): Used to generate breadcrumbs. Accepts a single items or an array of items. To make an item a link, wrap it in an array with a relative link (example:[ '/analytics', __( 'Analytics', 'woocommerce-admin' ) ]
).isEmbedded
: Boolean describing if the header is embedded on an existing wp-admin page. False if rendered as part of a full react page.
Activity Panel
This component contains the Activity Panel. This is shown on every page and is rendered as part of the header.