d773bb483a
* Focus cupon input if it has errors * Add changelog file * Add styles to coupon field with error on cart page * Make coupon errors accessible on the cart page * Add styles to coupon field with error on checkout page * Rename coupon variables on cart * Focus coupon field with error before updating live region on cart page * Focus coupon field with error before updating live region on checkout page * Remove incorrect early return * Update coupon error notice test * Improve coupon error message semantics * Fix coupon errors for block based themes * Update tests to not look for coupon errors on the notice block * Rename coupon-error-message to coupon-error-notice * Fix notice if coupon doesn't exist on tests * FIx invalid coupon notice on classic theme test * Update test for coupon inline notice * Fix code formatting Co-authored-by: Darin Kotter <darin.kotter@gmail.com> * Fix code formatting Co-authored-by: Darin Kotter <darin.kotter@gmail.com> * Fix code formatting Co-authored-by: Darin Kotter <darin.kotter@gmail.com> * Fix code formatting Co-authored-by: Darin Kotter <darin.kotter@gmail.com> * Don't clear coupon input if code doesn't exist * Create coupon error notice mixin * Update coupon error notice styles * Coupon error notice T19 compatibility * Coupon error notice T17 compatibility * Coupon error notice TT1 compatibility * Coupon error notice TT compatibility * Coupon error notice TT2 compatibility * Coupon error notice TT3 compatibility * Add spaces around paramenters Co-authored-by: Darin Kotter <darin.kotter@gmail.com> * Add spaces around paramenters Co-authored-by: Darin Kotter <darin.kotter@gmail.com> * Replace $red SCSS variable with a CSS one * Keep input with the invalid coupon code after notice appears * Fix typo in comment Co-authored-by: Mike Jolley <mike.jolley@me.com> * Fix typo in comment Co-authored-by: Mike Jolley <mike.jolley@me.com> * Break notice message into two lines * Break if statement into two lines --------- Co-authored-by: Darin Kotter <darin.kotter@gmail.com> Co-authored-by: Mike Jolley <mike.jolley@me.com> |
||
---|---|---|
.. | ||
components | ||
context | ||
hocs | ||
hooks | ||
utils | ||
README.MD |
README.MD
Base Components/Context/Hooks
Base components are designed to be used on the frontend of a store. Due to this, we need to avoid using heavy WordPress externals as dependencies (@wordpress/blocks
, @wordpress/block-editor
, etc).
Note 2 exceptions, we do use the Slot
and Fill
which we import and bundle from @wordpress/components
. Otherwise you should avoid importing anything else from that package.
The other exception is the FormTokenField
, which is used in deprecated blocks and use of that import is also deprecated.
If you need primitive/low-level components to build components in this library, please use Ariakit to build them. See Button for an example.
Check the built *.assets.php
files to ensure extra dependencies aren't being added to the build.