Git Product home page Git Product logo

Comments (6)

aadcg avatar aadcg commented on May 23, 2024 2

Closed via #3284.

from nyxt.

aartaka avatar aartaka commented on May 23, 2024 1

My fear is that the shadow DOM is relatively recent and there may be API inconsistencies across different web renderers. Will there be performance discrepancies? Open questions.

Well, the shadowRoot is well-supported by most major browsers and engines, including WebKit.

from nyxt.

aadcg avatar aadcg commented on May 23, 2024

Thanks for the bug report @hakan-demirli.

I can reproduce it and it shows a major flaw in the architecture of hint-mode. The added hint elements must be added either (1) as a shadow DOM or (2) as children of an element whose sibling is body. This has been noted by @heiwiper before. From #3001:

(@heiwiper) I also want to suggest moving all the hint elements into a single parent element outside the main DOM body.

The issue in this bing page is that its CSS sets display to none for elements that match the Nyxt hints. It was only a matter of time until an actual example of this flaw would be observed.

from nyxt.

heiwiper avatar heiwiper commented on May 23, 2024

The added hint elements must be added either (1) as a shadow DOM or (2) as children of an element whose sibling is body.

The two suggestions are complementary:

  • The node being a sibling of body serves as a good separation of hints added by nyxt from the rest of the DOM.
  • The Shadow DOM serves to encapsulate hint elements from the rest of the DOM.

I would like to work on this issue if possible.

from nyxt.

aadcg avatar aadcg commented on May 23, 2024

@heiwiper they are complementary, but encapsulation isn't mandatory. I'd probably only give it a try after the hints are moved outside of body. My fear is that the shadow DOM is relatively recent and there may be API inconsistencies across different web renderers. Will there be performance discrepancies? Open questions.

Once we support at least 2 renderers (#2989), we'd be in a better position to attempt using shadow DOMs.

Please go ahead if you'd like to work on it. Thanks.

from nyxt.

heiwiper avatar heiwiper commented on May 23, 2024

@heiwiper they are complementary, but encapsulation isn't mandatory. I'd probably only give it a try after the hints are moved outside of body.

I agree with you. Shadow DOM would serve as an extra layer so it is not a necessity for now at least. I will keep an eye on the other issue you have mentioned.

Edit: add quote

from nyxt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.