RickoNoNo3/react-winbox

I dont know how to use this, i have 1 iq

Enzogaming59430 opened this issue · 1 comments

Im new in react and trying to make this work

What should i do


EDIT : I FINNALY MADE IT WORK BUT NOT PROPRELY, VERTICAL RESIZING MAKES THE WINDOW DISAPEARS, THE HIDE AND RESIZE BUTTON IS BROKEN AND CAN ONLY MOVE THE WINDOW HORISONTALY

import React from 'react';
import WinBox from 'react-winbox';

const app = () => {
  
  return(
<WinBox
  width={this.state.boxWidth ?? 500}
  height={300}
  x="center"
  y={30}
  noClose={this.state.inEditing}>
  <div>
    
    <h1>Hello, WinBox!</h1>
    <MyComponent myProps={1} onChange={this.handleChange}/>
  </div>
</WinBox>
)
}

export default app; ``````


There is a note aimed at this situation. See https://github.com/RickoNoNo3/react-winbox#usage

To use WinBox, ensure the document body has an initial non-zero height, e.g. 100vh.

Maybe it's not so striking yet, I'll try to make it more clear. Thank you.