mirror of https://github.com/kern/filepizza
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
410 B
JavaScript
21 lines
410 B
JavaScript
import React from 'react';
|
|
|
|
export default class Tempalink extends React.Component {
|
|
|
|
onClick() {
|
|
this.refs.input.getDOMNode().setSelectionRange(0, 9999);
|
|
}
|
|
|
|
render() {
|
|
var url = window.location.origin + '/d/' + this.props.token;
|
|
return <input
|
|
className="tempalink"
|
|
onClick={this.onClick.bind(this)}
|
|
readOnly
|
|
ref="input"
|
|
type="text"
|
|
value={url} />;
|
|
}
|
|
|
|
}
|