Hard code web UI address in certain links to make testing servers work

This commit is contained in:
Alex Liebowitz 2016-12-06 14:58:51 -05:00
parent 494168474f
commit 1295b7e1b9
3 changed files with 3 additions and 2 deletions

View file

@ -2,6 +2,7 @@ var lbry = {
isConnected: false, isConnected: false,
rootPath: '.', rootPath: '.',
daemonConnectionString: 'http://localhost:5279/lbryapi', daemonConnectionString: 'http://localhost:5279/lbryapi',
webUiUri: 'http://localhost:5279',
colors: { colors: {
primary: '#155B4A' primary: '#155B4A'
}, },

View file

@ -284,7 +284,7 @@ var PublishPage = React.createClass({
var formData = new FormData(fileInput.form); var formData = new FormData(fileInput.form);
formData.append('file', fileInput.files[0]); formData.append('file', fileInput.files[0]);
xhr.open('POST', '/upload', true); xhr.open('POST', lbry.webUiUri + '/upload', true);
xhr.send(formData); xhr.send(formData);
} }
}, },

View file

@ -47,7 +47,7 @@ var WatchPage = React.createClass({
? <LoadScreen message={'Loading video...'} details={this.state.loadStatusMessage} /> ? <LoadScreen message={'Loading video...'} details={this.state.loadStatusMessage} />
: <main className="full-screen"> : <main className="full-screen">
<video ref="player" width="100%" height="100%"> <video ref="player" width="100%" height="100%">
<source type={(this.state.mimeType == 'audio/m4a' || this.state.mimeType == 'audio/mp4a-latm') ? 'video/mp4' : this.state.mimeType} src={'/view?name=' + this.props.name} /> <source type={(this.state.mimeType == 'audio/m4a' || this.state.mimeType == 'audio/mp4a-latm') ? 'video/mp4' : this.state.mimeType} src={lbry.webUiUri + '/view?name=' + this.props.name} />
</video> </video>
</main> </main>
); );