summaryrefslogtreecommitdiff
path: root/app/client
diff options
context:
space:
mode:
Diffstat (limited to 'app/client')
-rw-r--r--app/client/common/select.component.js3
-rw-r--r--app/client/modules/morph/morph.tasks.js1
-rw-r--r--app/client/modules/morph/views/morph.app.js8
3 files changed, 7 insertions, 5 deletions
diff --git a/app/client/common/select.component.js b/app/client/common/select.component.js
index 0a48dce..334d95a 100644
--- a/app/client/common/select.component.js
+++ b/app/client/common/select.component.js
@@ -10,6 +10,7 @@ class Select extends Component {
handleChange(e){
clearTimeout(this.timeout)
let new_value = e.target.value
+ if (new_value === 'PLACEHOLDER') return
this.props.onChange && this.props.onChange(this.props.name, new_value)
}
render() {
@@ -50,7 +51,7 @@ class Select extends Component {
onChange={this.handleChange}
value={currentValue || lastValue}
>
- {this.props.placeholder && <option value=''>{this.props.placeholder}</option>}
+ {this.props.placeholder && <option value="PLACEHOLDER">{this.props.placeholder}</option>}
{options}
</select>
</label>
diff --git a/app/client/modules/morph/morph.tasks.js b/app/client/modules/morph/morph.tasks.js
index ba0f6b9..1e938c8 100644
--- a/app/client/modules/morph/morph.tasks.js
+++ b/app/client/modules/morph/morph.tasks.js
@@ -8,6 +8,7 @@ import actions from '../../actions'
import module from './morph.module'
export const morph_task = (state, folder) => dispatch => {
+ if (state.a === 'PLACEHOLDER' || state.b === 'PLACEHOLDER') return
const task = {
module: module.name,
activity: 'morph',
diff --git a/app/client/modules/morph/views/morph.app.js b/app/client/modules/morph/views/morph.app.js
index 4a5b51b..09294a3 100644
--- a/app/client/modules/morph/views/morph.app.js
+++ b/app/client/modules/morph/views/morph.app.js
@@ -22,8 +22,8 @@ class MorphResults extends Component {
super()
this.state = {
dataset_module: 'pix2pixhd',
- a: "",
- b: "",
+ a: "PLACEHOLDER",
+ b: "PLACEHOLDER",
a_offset: 0,
a_duration: 1,
a_pos: 0,
@@ -69,7 +69,7 @@ class MorphResults extends Component {
<Group title="From">
<Select
title="Starting sequence"
- placeholder="Please choose a sequence"
+ placeholder="Please choose a video"
value={this.state.a}
options={sequence_options}
onChange={(name, key) => this.setState({ a: key, a_duration: sequenceLookup[key].count, a_pos: 0, a_offset: 0 })}
@@ -85,7 +85,7 @@ class MorphResults extends Component {
<Group title="To">
<Select
title="Ending sequence"
- placeholder="Please choose a sequence"
+ placeholder="Please choose a video"
value={this.state.b}
options={sequence_options}
onChange={(name, key) => this.setState({ b: key, b_duration: sequenceLookup[key].count, b_pos: 0, b_offset: 0 })}