react-bootstrap-table / react-bootstrap-table2

Next Generation of react-bootstrap-table
https://react-bootstrap-table.github.io/react-bootstrap-table2/
MIT License
1.27k stars 430 forks source link

Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element' #578

Open EndStatement opened 5 years ago

EndStatement commented 5 years ago

Error on overlayFactory() implementation

<BootstrapTable keyField="id" data={this.state.data} columns={this.state.columns} striped bootstrap4={ true } loading={ true } overlay={ overlayFactory({ spinner: true, background: 'rgba(192,192,192,0.3)' })} /> Here's the error message:

app.js:103595 The above error occurred in the component: in TableLoadingOverlayWrapper (created by BootstrapTable) in BootstrapTable in SortProvider in DataProvider (created by BootstrapTableContainer) in BootstrapTableContainer (created by DailyTimeRecord) in div (created by DailyTimeRecord) in div (created by DailyTimeRecord) in DailyTimeRecord (created by Route) in Route (created by Main) in Switch (created by Main) in div (created by Main) in div (created by Main) in Switch (created by Main) in Router (created by BrowserRouter) in BrowserRouter (created by Main) in div (created by Main) in Main

AllenFang commented 5 years ago

@HumbleCarl i will check this, currently, I will not suggest people to use react-bootstrap-table2-overlay instead you can custom by yourself, you can check this example.

Currently, react-bootstrap-table2-overlay use third party library and it produced some bugs.

AllenFang commented 5 years ago

Anyway, I will look into it but not sure the fixing time.

EndStatement commented 5 years ago

Copy that. Thank you sir!

sailor95 commented 4 years ago

I faced the same error in the browser, and I found that the overlay functionalities works when the noDataIndication prop is provided.
So what I did was to provide a blank noDataIndication, then I can use the overlay with no error.