Closed leonardjohn closed 2 years ago
@leonardjohn - Thanks for filing this, but you’ll need to add a CodePen repro before we can help. You can start from one of the COMPONENT examples (click “Export to CodePen”) or https://aka.ms/fluentpen.
@gouttierre many thanks for your update. please find the source code on CodeSandbox here:https://codesandbox.io/s/stoic-nash-df2e8 two problems here:
thanks in advance.
@gouttierre @khmakoto any update on this?
@khmakoto
Gentle ping that this issue needs attention.
Because this issue has not had activity for over 180 days, we're automatically closing it for house-keeping purposes.
Still require assistance? Please, create a new issue with up-to date details.
Dear guys, just want to know how to open custom dialog in another component control? e.g.: ParentComponent.tsx: import CustomDialog from "CustomDialog" export class ParentComponent { ... public render() { return ( <Button onClick={()=>{this.showDialog()}} ); } public showDialog() { //How to show/hide dialog here? } ... }
CustomDialog.tsx: import Dialog from "@fluentui/react-northstar"
export class CustomDialog { public async componentWillMount() { this.setState({open:false}) } public setOpen() { if (!this.state.open) this.setState({open:true}); else this.setState({open:false}); } public render() { return ( <Dialog open={this.state.open} .../> ); } } export default CustomDialog
thanks in advance