Commit Graph

6 Commits

Author SHA1 Message Date
Joel Thiessen 588776deb3 Fix persisted queries being lost when navigating to excluded page (such as Homescreen) (https://github.com/woocommerce/woocommerce-admin/pull/6614) 2021-04-02 14:35:31 -07:00
Joshua T Flowers c71d64a937 Fix double prefixing of navigation URLs (https://github.com/woocommerce/woocommerce-admin/pull/6460)
* Fix double prefixing of navigation URLs

* Add changelog and testing instructions
2021-03-02 11:18:48 -05:00
Joshua T Flowers a8757648a1 Refactor menu item mapping and sorting (https://github.com/woocommerce/woocommerce-admin/pull/6382)
* Separate primary and secondary menu components

* Simplify category mapping

* Map categories and items simultaneously to improve performance

* Sort added menu items

* Pre-sort menu items

* Create single mapped sorting on server-side

* Fix incorrect menu ID references

* Update tests

* Move methods to utils file

* Add in permissions check in client nav

* Fix server-side capability check

* Fix duplicate expectation and test name

* Add testing instructions
2021-02-22 13:54:27 -05:00
Joshua T Flowers 10b9579cde Add nav item route regex matching (https://github.com/woocommerce/woocommerce-admin/pull/5818)
* Use default expression to match items

* Pass match expression for WCA homepage

* Match post types if the current post type matches item

* Remove unused getParams

* Update tests for isMatch util

* Update nav docs

* Update default expression to match params in any order

* add query arg tests: additional and order

* Use match score based on regex matches

* Return max safe int for exact matches

* Update tests for match score

* more tests

Co-authored-by: Paul Sealock <psealock@gmail.com>
2020-12-09 13:45:30 +13:00
Joshua T Flowers 84e006cc62 Migrate navigation store to data package (https://github.com/woocommerce/woocommerce-admin/pull/5420)
* Move data store to package and hydrate navigation

* Use wc settings to get site URL and title

* Use wc settings admin link

* Update nav util tests to work with installs in subdirectory
2020-10-21 13:02:45 -04:00
Paul Sealock ad7cf64303 Navigation: Add client code (https://github.com/woocommerce/woocommerce-admin/pull/5309)
* is_feature_enabled

* feature class

* copy/paste

* hooked up

* its alive

* add wc-admin items

* clean up entry point

* Analytics remove url

* rebase error

* add back in check is_feature_enabled

* specificity CSS
2020-10-13 14:40:53 +13:00