D
D
Dmitry2016-11-02 14:44:21
JavaScript
Dmitry, 2016-11-02 14:44:21

js problem in safari?

An incomprehensible bug was found in Safari, I can not understand what the problem is and how to solve it.
Here is the site.
1. Scroll down to:
0a2a07269cd742cca3a5765e935689df.png

2. Select your iPad. You will be redirected to a page with a choice of model.
3. Choose a model, the second step appears - choose a malfunction.
4. When a fault is selected, the "Finish" button appears at the bottom. When it appears, reload the page, go to the main page through the logo, scroll down again to select between iPad and iPhone (step 1).
5. Repeat the 2nd and 3rd steps: when choosing a fault, the "File" button does not appear now.

Do the steps strictly as written.

This bug was noticed on mobile devices and tablets, there is no way to check it on the desktop (I will be grateful if you check it).

If the steps are not clear, write, I will explain better in the comments :)

I add the "Finish" button by checking the presence of the .active class for elements (malfunctions):

var activeCounter = $('.neispravnost .ns-blok.active').length;
if(activeCounter !== 0){
    $('#step2 .problem').addClass('active');
} else{
    $('#step2 .problem').removeClass('active');
}

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander, 2016-11-02
@letehaha

On the desktop, everything is fine, I checked it 3 times. On the iPhone, everything was the opposite: during the first pass, the button did not appear, but when I removed all the marks and marked it again, it worked, on the second pass everything worked the first time.
The suspicion is that the page did not have time to fully load and when the menu item was selected, the hook did not yet hang on the button.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question