We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Before you start - checklist
What are you trying to achieve? Please describe.
I'm trying to show a base64 encoded PDF. I'm using the following snippet-
<Document file={`data:application/pdf;base64,JVBERi0xLjIgCjkgMCBvYmoKPDwKPj4Kc3RyZWFtCkJULyA5IFRmKFRlc3QpJyBFVAplbmRzdHJlYW0KZW5kb2JqCjQgMCBvYmoKPDwKL1R5cGUgL1BhZ2UKL1BhcmVudCA1IDAgUgovQ29udGVudHMgOSAwIFIKPj4KZW5kb2JqCjUgMCBvYmoKPDwKL0tpZHMgWzQgMCBSIF0KL0NvdW50IDEKL1R5cGUgL1BhZ2VzCi9NZWRpYUJveCBbIDAgMCA5OSA5IF0KPj4KZW5kb2JqCjMgMCBvYmoKPDwKL1BhZ2VzIDUgMCBSCi9UeXBlIC9DYXRhbG9nCj4+CmVuZG9iagp0cmFpbGVyCjw8Ci9Sb290IDMgMCBSCj4+CiUlRU9G`}> <Page pageNumber={1} /> </Document>
I receive the following error-
Describe solutions you've tried
Additional information
<Modal {...this.props} size="lg" aria-labelledby="contained-modal-title-vcenter" centered show={this.state.showPDF} onHide={() => this.setState({ showPDF: false })} > <Modal.Header closeButton> <Modal.Title id="contained-modal-title-vcenter"> Please provide your consent to continue </Modal.Title> </Modal.Header> <Modal.Body> <Document file={\`data:application/pdf;base64,JVBERi0xLjIgCjkgMCBvYmoKPDwKPj4Kc3RyZWFtCkJULyA5IFRmKFRlc3QpJyBFVAplbmRzdHJlYW0KZW5kb2JqCjQgMCBvYmoKPDwKL1R5cGUgL1BhZ2UKL1BhcmVudCA1IDAgUgovQ29udGVudHMgOSAwIFIKPj4KZW5kb2JqCjUgMCBvYmoKPDwKL0tpZHMgWzQgMCBSIF0KL0NvdW50IDEKL1R5cGUgL1BhZ2VzCi9NZWRpYUJveCBbIDAgMCA5OSA5IF0KPj4KZW5kb2JqCjMgMCBvYmoKPDwKL1BhZ2VzIDUgMCBSCi9UeXBlIC9DYXRhbG9nCj4+CmVuZG9iagp0cmFpbGVyCjw8Ci9Sb290IDMgMCBSCj4+CiUlRU9G\`}> <Page pageNumber={1} /> {/*{Array.from(new Array(numPages), (el, index) => ( <Page key={`page_${index + 1}`} pageNumber={index + 1} /> ))}*/} </Document> {/*<embed src={`data:application/pdf;base64,${loadedFile}`} type="application/pdf" width="100%"></embed>*/} <Container> <Form> <Form.Group> <Button variant="success" type="submit" onClick={this.handleConsent}> I Agree </Button> </Form.Group> </Form> </Container> </Modal.Body> </Modal>
Environment
The text was updated successfully, but these errors were encountered:
Fixed the formatting.. Halp!
Sorry, something went wrong.
See #97 and others.
Duplicate of #97
No branches or pull requests
Before you start - checklist
What are you trying to achieve? Please describe.
I'm trying to show a base64 encoded PDF. I'm using the following snippet-
I receive the following error-
Describe solutions you've tried
Additional information
Environment
The text was updated successfully, but these errors were encountered: