Switch font input to AutocompleteInput

This commit is contained in:
Lukas Martinelli 2016-12-30 20:53:12 +01:00
parent 48f10bcb73
commit cf80e80025
2 changed files with 3 additions and 6 deletions

View file

@ -41,6 +41,7 @@ class AutocompleteInput extends React.Component {
style={{
userSelect: 'none',
color: colors.lowgray,
cursor: 'default',
background: isHighlighted ? colors.midgray : colors.gray,
padding: margins[0],
fontSize: fontSizes[5],

View file

@ -1,5 +1,5 @@
import React from 'react'
import SelectInput from './SelectInput'
import AutocompleteInput from './AutocompleteInput'
import input from '../../config/input.js'
//TODO: Query available font stack dynamically
@ -24,12 +24,8 @@ class FontInput extends React.Component {
render() {
const inputs = this.values.map((value, i) => {
return <SelectInput
return <AutocompleteInput
key={i}
style={{
width: '100%',
...this.props.style,
}}
value={value}
options={fontStacks.map(f => [f, f])}
onChange={this.changeFont.bind(this, i)}