Commit Graph

21 Commits

Author SHA1 Message Date
Justin Shreve 0fe061b97d Add Feature Flags (https://github.com/woocommerce/woocommerce-admin/pull/1500)
* First pass at adding feature flags. Accessible over PHP and JS.

* Hook up dev config to test enviornments, hook up features to their flags.

* Cleanup some code and add documentation. Remove beta config.

* Handle PR Feedback: Add devdocs flag, remove categories flag, fix auto-generated PHP warning.

* Add todo for beta phase.

* Handle PR feedback: Simplify is_array check, update build command, simplify test mock, remove empty webpack line.
2019-02-12 15:02:02 -05:00
Kevin Killingsworth 8b7e309e6f navigation: Lazy-create history (https://github.com/woocommerce/woocommerce-admin/pull/1472)
history.createHashHistory() is being called whenever this package is
imported, which causes the URL to redirect to a hash. This is
unnecessary in cases where elements of wc-admin are used outside of a
completely controlled/routed page.

This lazy-creates the history object only when it's needed and therefore
avoids the URL redirection unless history features are in use.
2019-02-06 13:28:29 -06:00
Joshua T Flowers fb0d71f117 Update page query to 1 when base query is changed (https://github.com/woocommerce/woocommerce-admin/pull/1444)
* Update page query to 1 when base query is changed

* Use history replace instead of updating query
2019-02-04 10:55:06 +08:00
Joshua T Flowers 49e78b90cf Add settings page with excluded order statuses (https://github.com/woocommerce/woocommerce-admin/pull/1364)
* Add settings page routes

* Add control options for excluded statuses

* Add control options for excluded statuses

* Add excluded order statuses to rest api

* Add wc settings to wc-api

* Add wc settings to wc-api

* Split and validate multiselect values in settings controller

* Add wcAdminSettings to wcSettings global

* Set initial excluded statuses from serverside wcSettings data

* Add extensible filter for wcSettings global

* Split arrays into comma separated strings in wc-api

* Extract setting as separate component

* Extra settings to config file

* Add checkboxGroup option as input type

* Separate status types into default and custom groups

* Add setting option styling

* Add responsive styling for settings

* Fix wpClosedMenu and wpOpenMenu for settings page

* Add support for resetting to default values

* Only show checkbox group if options are available

* Add proptypes to Setting component

* Add extensible filter to analytics settings

* Add readme for settings config and extensibility

* Hook up excluded status settings to reports

* Pass object to settings API instead of comma delimited string

* Fix inpuType -> inputType typo

* Remove hasError from constructor

* Bump settings API to v4

* Use interpolateComponents instead of dangerously setting html

* Use empty array in initial excldued statuses setting value if none is retrieved

* Remove double check for refunded status in default order statuses

* Update settings wc-api to use namespace

* Add aria=labelledby to checkbox group
2019-01-31 09:04:11 +08:00
Paul Sealock 0d59998625 Persist chart settings 2018-11-20 12:55:30 +13:00
Kelly Dwan d27cb26ef7 Build: Move `lib/nav-utils` and `lib/history` to `@woocommerce/navigation` (https://github.com/woocommerce/woocommerce-admin/pull/763)
* Move nav-utils and history to new package

* Update config to build and use new navigation package

* Update all imports to use new navigation package

* Remove unnecessary README

* Update nav-utils path
2018-11-05 16:02:04 -05:00
Albert Juhé Lluveras 856dde0d3d Fix: date params were no longer persisted when navigating pages (https://github.com/woocommerce/woocommerce-admin/pull/717) 2018-10-29 16:43:30 +01:00
Jonathan Belcher 57e46e3273 Updates default analytics menu (https://github.com/woocommerce/woocommerce-admin/pull/658)
* Updates default analytics menu

* Make revenue the default analytics page

* Fix header link to direct to Revenue report

* Fix highlighting with additional filters
2018-10-27 13:38:35 -04:00
Albert Juhé Lluveras 1c819740f4 Persist date params in Products table link (https://github.com/woocommerce/woocommerce-admin/pull/671) 2018-10-25 12:07:30 +02:00
Paul Sealock 240599c095 Persist date related parameters on report navigation 2018-10-24 12:16:35 +13:00
Jonathan Belcher 9d337ce8e0 Add all instances of menu to toggle current state. 2018-10-10 12:06:32 -04:00
Jonathan Belcher a947d304dc Reafctors code to vanila js and removes jQuery 2018-10-10 10:24:57 -04:00
Kelly Dwan 62276fb361 Add visual component docs from markdown examples (https://github.com/woocommerce/woocommerce-admin/pull/470)
* Remove content from README, leaving only the example

* Rename edited READMEs

* Add a devdocs page rendering from markdown example files

* Add more components to devdocs

* Add the rest of the component examples

* Add navigation to single components, show generated readme on single component view

* Style devdocs like calypso

* Split devdocs into two columns at “desktop” sizes

* Update segmented selection example

* Update link

* Add header to avoid notices error
2018-09-24 11:36:35 -04:00
Justin Shreve 898a82ca1d Fix wp-admin navigation active state (https://github.com/woocommerce/woocommerce-admin/pull/352) 2018-09-05 14:37:26 -04:00
Justin Shreve 71c12e6795 Update woo-dash naming to new wc-admin name (https://github.com/woocommerce/woocommerce-admin/pull/183) 2018-07-10 08:48:06 -04:00
Justin Shreve d604f3625c Rename sidebar to activity-panel, and refactor code and behavior. 2018-06-28 09:52:45 -04:00
Justin Shreve ba68ada59d Add Pagination Component (https://github.com/woocommerce/woocommerce-admin/pull/117)
* Add pagination component

* Refactor query string/route updating so it can be done using a nav-utils helper function

* Fix typo and adjust accessibility attributes for error handling and current page

* Update styles
2018-06-26 10:59:35 -04:00
Justin Shreve bf80e5c649 Global Header & Activity Panel on all WooCommerce Pages (https://github.com/woocommerce/woocommerce-admin/pull/110)
* Makes the header/sidebar component embeddable on other WooCommerce pages.

* Some mobile CSS fixes to make sure the header bar displays properly on smaller screensizes.

* Refactor notices and pull out success message from the panel

* Handle positioning of screen options, update message handling, css fixes and header height increase to match mockups, some code cleanup

* Only enable the header embed on normal/classic WooCommerce pages, and provide a method for plugins to opt-in.
This change also builds nicer breadcrumbs for pages.

* Code cleanup and consistent naming.

* Some spacing cleanup. Also updated the page title method to correctly set page titles in PHP for classic WC pages
2018-06-26 10:49:42 -04:00
Paul Sealock b25fdc3f31 DatePicker: Add url support and container 2018-06-05 10:20:25 +12:00
Justin Shreve 7b0d0b1fed Update wp-admin navigation structure (https://github.com/woocommerce/woocommerce-admin/pull/70)
* Updates wp-admin navigation structure: Dashboard is now under WooCommerce, and Analytics is moved visually under WooCommerce

* Fix focus padding issue and make sure arrow displays for the current submenu
2018-05-22 15:59:32 -04:00
Kelly Dwan 8f23630269 Layout: Add structure components & CSS (https://github.com/woocommerce/woocommerce-admin/pull/45)
* Refactor dashboard layout into new Layout components

* Style the new layout

* Use Slot/Fill for the Header component

* Center cards, fixed size for sidebar

* Only set the box-sizing on things within our app

* Make app the full height of the wp-admin frame

* Add styles to show/hide sidebar

* Toggle the sidebar

* Wrap router around entire Layout, use page setting to show/hide sidebar on page

* Fix the styles on show/hide buttons, add title & close button to the sidebar

* Use a min-height on visible sidebars

* Add/update READMEs

* Update space between main content & sidebar
2018-05-18 13:31:08 -04:00