четверг, 10 апреля 2014 г.

Troubleshooting object inspector in Blogspot preview

I don't know how you, but I do use frequently the CSS/JavaScript debugger in the browser, and it bothers me a lot when I see situations, sites, pages where I'm unable to use it easily. Blogspot page preview is the such case - they intercept click events on the pages while showing me preview page, and as a side effect of this interception Chrome debugging tools are unable to show me information about selected object (because click is not real click here).
If you open preview page and invoke debugger tools, CSS inspector (Ctrl+Shift+I), and try to select the reading area you will probably fail here...
You will probably select the object which cover whole reading pane, and which "coincidentally" has CSS class "Blogger-clickTrap". Taking into account the intention of this div box has been added there I prefer to get rid of it. Yes, just delete this node in the DOM tree in the left:

Since now on you have 2 nice side effects:

  • CSS debugger object selector is able to work again;
  • and click events are properly working for all JavaScript on the page.
That's the desired effect we wanted to return.

Комментариев нет :

Отправить комментарий