RobertSpread / spreadcart

simple plugin to display a cart for the spreadshop everywhere on your domain
1 stars 1 forks source link

Basket icon fixes + icon config simplification #15

Closed jtlapp closed 8 years ago

jtlapp commented 8 years ago

(This pull must follow my nodejs-support branch.) Fixed basket icon associated errors and simplified cart configuration, as follows:

(1) commented out removal SpreadShop basket, because this produces SpreadShop JS errors; relying on CSS to hide it

(2) no longer errors before basket data has been put in local storage. now checks to make sure basketData is non-null before using

(3) shopping cart icon was displaced vertically by the height of quantity bubble. had to style the user-supplied container in spreadCart.css. opted not to nest an additional div to allow for mod (4).

(4) the plugin-provided basket icon now has a default CSS ID of "spreadCartIcon". if you set clickTargetID to this ID, you get the default icon. if you set clickTargetID to any other ID, you get a clickable link and no red quantity bubble, so the user can keep the SpreadShop cart. removed the showBasketIcon configuration parameter.

jtlapp commented 8 years ago

Oops. This batch is missing a tweak. In index.html, "myBasket" needs to change to "spreadCartIcon".