import Inferno from 'inferno'
import Component from 'inferno-component'
import styled from 'styled-components'
import { bind, debounce } from 'decko'

import { RaisedButton } from '@slup/buttons'
import { Slider } from '@slup/slider'
import { Logo } from '../components/logo'

const LogoContainer = styled.div`
  display: flex;
  flex: 1;
  height: 100%;
  align-items: center;
  justify-content: center;
  flex-direction: column;
`

export class Home extends Component {
  @bind
  @debounce(300)
  handleClick() {
    this.context.router.push('/components/buttons')
  }

  render() {
    return (
      <LogoContainer>
        {Logo}
        <RaisedButton onClick={this.handleClick} primary>Get started</RaisedButton>
      </LogoContainer>
    )
  }
}

@@ -471,251 +471,791 @@
 %7B%0A  
-@bind%0A  @debounce(300)%0A  handleClick() %7B%0A    this.context.router.push('/components/buttons')%0A  %7D%0A%0A  render() %7B%0A    return (%0A      %3CLogoContainer%3E%0A        %7BLogo%7D%0A        %3CRaisedButton onClick=%7Bthis.handleClick%7D primary%3EGet started%3C/RaisedButton
+state = %7B value: 0, focus: false %7D%0A%0A  @bind%0A  onChange(value) %7B%0A    this.setState(%7B value %7D)%0A  %7D%0A%0A  @bind%0A  onFocus() %7B%0A    this.setState(%7B focus: true %7D)%0A  %7D%0A%0A  @bind%0A  onBlur() %7B%0A    console.log('called')%0A    this.setState(%7B focus: false %7D)%0A  %7D%0A%0A  @bind%0A  @debounce(300)%0A  handleClick() %7B%0A    this.context.router.push('/components/buttons')%0A  %7D%0A%0A  render() %7B%0A    return (%0A      %3CLogoContainer%3E%0A        %7BLogo%7D%0A        %3CRaisedButton onClick=%7Bthis.handleClick%7D primary%3EGet started%3C/RaisedButton%3E%0A        %3CSlider%0A          value=%7Bthis.state.value%7D %0A          focus=%7Bthis.state.focus%7D%0A          keyFocus=%7Bthis.state.focus%7D%0A          max=%7B100%7D%0A          onChange=%7Bthis.onChange%7D %0A          onFocus=%7Bthis.onFocus%7D %0A          onBlur=%7Bthis.onBlur%7D%0A          discrete %0A          steps=%7B10%7D /
 %3E%0A  

Revert ":fire: Removed useless sample code"