I'm new to JS so bare with me. Basically, what I want to achieve is once I click on a button I want to display an element only if a certain text is displayed.
So, the code below consists of the button.
<input name="delivery-mode" id="delivery-mode-pickup" data-bind="checked: deliveryAddressModeClickAndCollect, events:{change:setDeliveryAddressModeClickAndCollect}" class="form-radiobutton" type="radio" value="Pickup">
The code below consist of the text "Please select your store" as a rule for the JS to only display the element that I want if that text is visible
<span class="store" data-bind="text: _getCurrentStoreText">Please select your store</span></span>
The code below is the element that I want to display if the button is clicked and if the text is "Please select your store"
<div id="change-store-dropdown-display" class="change-store-dropdown" style="display: none;" data-bind="displayAnimation: { fade: showStoreList }">
Aucun commentaire:
Enregistrer un commentaire