7ca9e691d4
* Migrate leaderboard tests to RTL. * Remove test of default prop value. * Migrate ReportSummary tests to RTL. * Migrate ActivityCard tests to RTL. * Migrate ActivityCardPlaceholder tests to RTL. * Migrate remaining ProductType tests to RTL. * Migrate Card tests to RTL. * Update RTL and user event packages. * Migrate Date tests to RTL. * Migrate D3Legend tests to RTL. * Migrate D3Base tests to RTL. * Migrate Gravatar tests to RTL. * Migrate ImageUpload tests to RTL. * Migrate ProductImage tests to RTL. * Migrate Rating tests to RTL. * Migrate Search tests to RTL. * Migrate Plugins tests to RTL. * Migrate SelectControl tests to RTL. * Migrate Timeline tests to RTL. Remove tests that inspect DOM since there are snapshots. * Migrate DismissModal tests to RTL. * Migrate SetupNotice tests to RTL. * Migrate WelcomeCard tests to RTL. * Fix setup error reason retrieval in ShippingBanner. * Migrate ShippingBanner tests to RTL. * Migrate RecommendedExtensions tests to RTL. * Migrate KnowledgeBase tests to RTL. * Rename enzyme setup file, modify to setup RTL. * No need to import jest-dom in test files. * Remove enzyme dependency. * Use snapshot for testing Leaderboard markup. * Switch from "not to be empty" to "be in the document". * No need to waitFor() recordEvent mock. * Be specific about clicking the "hide" button. * Use toBeVisible() instead of checking style property. |
||
---|---|---|
.. | ||
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.