Giter Site home page Giter Site logo

Comments (4)

TheSharpieOne avatar TheSharpieOne commented on June 10, 2024

The code needs to have access to the wrapping component to determine if any element within it has focus. It does this to determine if focus should be removed when blocking starts.
The tag was intended to be used as you are using it, allowing for any component to be used.
The simplest solution here would be to restrict the focus management feature to when tag is a strings... but that would suck.

from react-block-ui.

TheSharpieOne avatar TheSharpieOne commented on June 10, 2024

I added a helper element which I can use to dynamically get the wrapping element from to determine focus. This should resolve your issue.

from react-block-ui.

GoPro16 avatar GoPro16 commented on June 10, 2024

@TheSharpieOne I'm not sure if your helper resolved this issue. I created a code sandbox link as an example of this error still persisting only on the first load since the ref doesn't exist yet. After that, "during development" on react hot reloads the error doesn't re-pop up.

https://codesandbox.io/s/7jw0k58j41

from react-block-ui.

TheSharpieOne avatar TheSharpieOne commented on June 10, 2024

Apparently I broke this with this commit: 7ba8b8e
I added a ref back to the wrapping component where Tag is used :(

The container was used to determine the size of the content being blocked to keep the loading indicator centered. Could probably use the helpers to determine the top and bottom of the content area instead of the wrapping container.

from react-block-ui.

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.