aboutsummaryrefslogtreecommitdiff
path: root/frontend/src/components/ViewPaste.js
diff options
context:
space:
mode:
authorjackyzha0 <[email protected]>2020-05-17 09:55:35 -0700
committerjackyzha0 <[email protected]>2020-05-17 09:55:35 -0700
commit9941d9b18217e05f69547985a170234ee84c39f5 (patch)
treefe1dd7ed3141ac536d899b9c85401834d14490be /frontend/src/components/ViewPaste.js
parentremove lang input (diff)
downloadctrl-v-9941d9b18217e05f69547985a170234ee84c39f5.tar.xz
ctrl-v-9941d9b18217e05f69547985a170234ee84c39f5.zip
save comp
Diffstat (limited to 'frontend/src/components/ViewPaste.js')
-rw-r--r--frontend/src/components/ViewPaste.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/frontend/src/components/ViewPaste.js b/frontend/src/components/ViewPaste.js
index 81d78f3..914f94c 100644
--- a/frontend/src/components/ViewPaste.js
+++ b/frontend/src/components/ViewPaste.js
@@ -29,6 +29,7 @@ class ViewPaste extends React.Component {
this.validatePass = this.validatePass.bind(this);
this.ErrorLabel = React.createRef();
this.PasswordModal = React.createRef();
+ this.componentRef = React.createRef();
}
handleChange(event) {
@@ -89,12 +90,14 @@ class ViewPaste extends React.Component {
content={this.state.content}
lang={this.state.language}
theme={this.state.theme}
+ ref={this.componentRef}
id="pasteInput" />
<PasteInfo
hash={this.props.hash}
lang={this.state.language}
theme={this.state.theme}
onChange={this.handleChange}
+ compref={this.componentRef}
err={<Error ref={this.ErrorLabel} />}
expiry={this.state.expiry} />
</div>