├── README.md ├── gin ├── .DS_Store └── app │ ├── Procfile │ ├── server.go │ └── templates │ ├── bio.tmpl │ ├── index.tmpl │ └── layout.tmpl ├── kemal └── app │ ├── .gitignore │ ├── .travis.yml │ ├── LICENSE │ ├── README.md │ ├── shard.lock │ ├── shard.yml │ ├── spec │ ├── app_spec.cr │ └── spec_helper.cr │ └── src │ ├── app.cr │ └── views │ ├── _bio.ecr │ └── index.ecr ├── martini └── app │ ├── Procfile │ ├── server │ ├── server.go │ └── templates │ ├── bio.tmpl │ ├── index.tmpl │ └── layout.tmpl ├── phoenix └── app │ ├── .gitignore │ ├── Procfile │ ├── config │ ├── config.exs │ ├── dev.exs │ ├── locales │ │ └── en.exs │ ├── prod.exs │ └── test.exs │ ├── lib │ ├── benchmarker.ex │ └── benchmarker │ │ └── endpoint.ex │ ├── mix.exs │ ├── mix.lock │ ├── priv │ └── static │ │ ├── css │ │ └── phoenix.css │ │ ├── images │ │ └── phoenix.png │ │ └── js │ │ └── phoenix.js │ ├── test │ ├── benchmarker_test.exs │ └── test_helper.exs │ └── web │ ├── controllers │ └── page_controller.ex │ ├── router.ex │ ├── templates │ ├── layout │ │ └── app.html.eex │ └── page │ │ ├── bio.html.eex │ │ ├── error.html.eex │ │ ├── index.html.eex │ │ └── not_found.html.eex │ ├── views │ ├── error_view.ex │ ├── layout_view.ex │ └── page_view.ex │ └── web.ex ├── rails └── app │ ├── .gitignore │ ├── Gemfile │ ├── Gemfile.lock │ ├── README.rdoc │ ├── Rakefile │ ├── app │ ├── controllers │ │ ├── application_controller.rb │ │ ├── concerns │ │ │ └── .keep │ │ └── dashboard_controller.rb │ └── views │ │ └── dashboard │ │ ├── _bio.html.erb │ │ └── index.html.erb │ ├── bin │ ├── bundle │ ├── rails │ ├── rake │ ├── setup │ └── spring │ ├── config.ru │ ├── config │ ├── application.rb │ ├── boot.rb │ ├── environment.rb │ ├── environments │ │ ├── development.rb │ │ ├── production.rb │ │ └── test.rb │ ├── initializers │ │ ├── assets.rb │ │ ├── backtrace_silencers.rb │ │ ├── cookies_serializer.rb │ │ ├── filter_parameter_logging.rb │ │ ├── inflections.rb │ │ ├── mime_types.rb │ │ ├── session_store.rb │ │ └── wrap_parameters.rb │ ├── locales │ │ └── en.yml │ ├── routes.rb │ └── secrets.yml │ ├── db │ └── seeds.rb │ ├── lib │ ├── assets │ │ └── .keep │ └── tasks │ │ └── .keep │ ├── log │ └── .keep │ ├── public │ ├── 404.html │ ├── 422.html │ ├── 500.html │ ├── favicon.ico │ └── robots.txt │ └── vendor │ └── assets │ ├── javascripts │ └── .keep │ └── stylesheets │ └── .keep ├── results └── plot.png └── sinatra └── app ├── Gemfile ├── Gemfile.lock ├── Procfile ├── app.rb ├── config.ru └── views ├── _bio.erb └── index.erb /README.md: -------------------------------------------------------------------------------- 1 | # Kemal Showdown 2 | 3 | :horse_racing: benchmark Kemal with Sinatra-like web frameworks 4 | 5 | # Results 6 | 7 | Check the results here 8 | 9 | # Running The Benchmark 10 | 11 | The benchmark is done with `wrk` with the following command. 12 | 13 | `wrk -c 40 -d 20 http://localhost:3001/kemal` 14 | 15 | ## Kemal 16 | 17 | Be sure to have Crystal `v0.20.4`. 18 | 19 | ``` 20 | cd kemal/app 21 | shards install 22 | crystal build --release src/app.cr 23 | ./app -p 3001 24 | ``` 25 | 26 | You should see the app running in `http://localhost:3001/kemal`. 27 | 28 | ``` 29 | Running 20s test @ http://localhost:3001/kemal 30 | 2 threads and 40 connections 31 | Thread Stats Avg Stdev Max +/- Stdev 32 | Latency 1.12ms 542.03us 11.84ms 73.85% 33 | Req/Sec 18.13k 2.18k 19.47k 89.05% 34 | 725107 requests in 20.10s, 695.67MB read 35 | Requests/sec: 36073.95 36 | Transfer/sec: 34.61MB 37 | ``` 38 | 39 | ## Sinatra 40 | 41 | Ruby 2.3.0 is preferred. 42 | 43 | ``` 44 | cd sinatra/app 45 | bundle 46 | RACK_ENV=production bundle exec puma -t 1:16 -w 4 --preload -p 3001 47 | ``` 48 | 49 | You should see the app running in `http://localhost:3001/kemal`. 50 | 51 | ``` 52 | Running 20s test @ http://localhost:3001/kemal 53 | 2 threads and 40 connections 54 | Thread Stats Avg Stdev Max +/- Stdev 55 | Latency 9.18ms 3.18ms 74.08ms 80.53% 56 | Req/Sec 2.21k 185.76 2.70k 74.75% 57 | 87796 requests in 20.01s, 89.26MB read 58 | Requests/sec: 4387.90 59 | Transfer/sec: 4.46MB 60 | ``` 61 | 62 | ## Rails 63 | 64 | ``` 65 | cd rails/app 66 | bundle 67 | PUMA_WORKERS=4 MIN_THREADS=1 MAX_THREADS=16 RACK_ENV=production bundle exec puma -p 3001 68 | ``` 69 | 70 | You should see the app running in `http://localhost:3001/kemal`. 71 | 72 | ``` 73 | Running 20s test @ http://localhost:3001/kemal 74 | 2 threads and 40 connections 75 | Thread Stats Avg Stdev Max +/- Stdev 76 | Latency 17.87ms 10.07ms 85.18ms 70.91% 77 | Req/Sec 449.13 75.00 630.00 57.50% 78 | 17895 requests in 20.02s, 20.81MB read 79 | Requests/sec: 893.94 80 | Transfer/sec: 1.04MB 81 | ``` 82 | 83 | ## Phoenix 84 | 85 | Be sure to have Elixir `1.4.0` 86 | 87 | ``` 88 | cd phoenix/app 89 | mix deps.get 90 | MIX_ENV=prod mix compile 91 | PORT=3001 MIX_ENV=prod elixir -pa _build/prod/consolidated -S mix phoenix.server -p 3001 92 | ``` 93 | 94 | ``` 95 | Running 20s test @ http://localhost:3001/kemal 96 | 2 threads and 40 connections 97 | Thread Stats Avg Stdev Max +/- Stdev 98 | Latency 1.23ms 590.43us 18.90ms 78.94% 99 | Req/Sec 14.77k 1.13k 18.27k 70.75% 100 | 588111 requests in 20.00s, 613.13MB read 101 | Requests/sec: 29400.52 102 | Transfer/sec: 30.65MB 103 | ``` 104 | 105 | ## Martini 106 | 107 | ``` 108 | go build server.go 109 | PORT=3001 GOMAXPROCS=4 MARTINI_ENV=production ./server 110 | ``` 111 | 112 | ``` 113 | Running 20s test @ http://localhost:3001/kemal 114 | 2 threads and 40 connections 115 | Thread Stats Avg Stdev Max +/- Stdev 116 | Latency 2.68ms 4.31ms 159.31ms 97.95% 117 | Req/Sec 8.32k 347.25 9.17k 76.50% 118 | 331285 requests in 20.00s, 340.58MB read 119 | Requests/sec: 16563.61 120 | Transfer/sec: 17.03MB 121 | ``` 122 | 123 | ## Gin 124 | 125 | ``` 126 | GOMAXPROCS=4 PORT=3001 GIN_MODE=release go run server.go 127 | ``` 128 | 129 | ``` 130 | Running 20s test @ http://localhost:3001/kemal 131 | 2 threads and 40 connections 132 | Thread Stats Avg Stdev Max +/- Stdev 133 | Latency 1.11ms 2.08ms 152.27ms 99.94% 134 | Req/Sec 18.70k 1.88k 22.71k 61.00% 135 | 744367 requests in 20.00s, 765.25MB read 136 | Requests/sec: 37216.68 137 | Transfer/sec: 38.26MB 138 | ``` 139 | 140 | - All benchmarks performed on MacBook Pro (Retina, 15-inch, Late 2013), 2 GHz Intel Core i7, 8 GB 1600 MHz DDR3 -------------------------------------------------------------------------------- /gin/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/gin/.DS_Store -------------------------------------------------------------------------------- /gin/app/Procfile: -------------------------------------------------------------------------------- 1 | web: GOMAXPROCS=4 GIN_MODE=release go run server.go 2 | 3 | -------------------------------------------------------------------------------- /gin/app/server.go: -------------------------------------------------------------------------------- 1 | package main 2 | 3 | import ( 4 | "fmt" 5 | "os" 6 | 7 | "github.com/gin-gonic/gin" 8 | ) 9 | 10 | func main() { 11 | // Creates a router without any middleware by default 12 | r := gin.New() 13 | 14 | // Global middlewares 15 | r.Use(gin.Recovery()) 16 | 17 | // Setup templates 18 | r.LoadHTMLGlob("templates/*") 19 | 20 | // Action handler 21 | r.GET("/:title", func(c *gin.Context) { 22 | title := c.Params.ByName("title") 23 | members := []gin.H{ 24 | {"Name": "Serdar Dogruyol"}, 25 | {"Name": "Fatih Kadir Akin"}, 26 | {"Name": "Askin Gedik"}, 27 | {"Name": "Ary Borenszweig"}} 28 | 29 | c.HTML(200, "layout.tmpl", gin.H{"Title": title, "Members": members}) 30 | }) 31 | 32 | // manually get port from environment 33 | port := os.Getenv("PORT") 34 | if port == "" { 35 | port = ":3000" 36 | } else { 37 | port = ":" + port 38 | } 39 | 40 | // Run the server 41 | fmt.Println("Starting on port " + port) 42 | r.Run(port) 43 | } 44 | -------------------------------------------------------------------------------- /gin/app/templates/bio.tmpl: -------------------------------------------------------------------------------- 1 | Name: {{.}} 2 | -------------------------------------------------------------------------------- /gin/app/templates/index.tmpl: -------------------------------------------------------------------------------- 1 |
2 |

Welcome to Kemal!

3 |

Kemal is a Crystal Web Framework targeting to be crazy fast, scalable and simple.

4 |
5 | 6 |
7 |
8 |

Resources: {{.Title}}

9 | 17 |
18 | 19 |
20 |

Help

21 | 26 | 27 |

Team Members

28 | 35 |
36 | 37 |
38 | Enjoy it! 39 |
40 | -------------------------------------------------------------------------------- /gin/app/templates/layout.tmpl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | {{ template "index.tmpl" . }} 5 | 6 | 7 | -------------------------------------------------------------------------------- /kemal/app/.gitignore: -------------------------------------------------------------------------------- 1 | /doc/ 2 | /libs/ 3 | /.crystal/ 4 | /.shards/ 5 | .gitignore 6 | -------------------------------------------------------------------------------- /kemal/app/.travis.yml: -------------------------------------------------------------------------------- 1 | language: crystal 2 | -------------------------------------------------------------------------------- /kemal/app/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016 Serdar Dogruyol 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /kemal/app/README.md: -------------------------------------------------------------------------------- 1 | # app 2 | 3 | TODO: Write a description here 4 | 5 | ## Installation 6 | 7 | 8 | TODO: Write installation instructions here 9 | 10 | 11 | ## Usage 12 | 13 | 14 | 15 | TODO: Write usage instructions here 16 | 17 | ## Development 18 | 19 | TODO: Write development instructions here 20 | 21 | ## Contributing 22 | 23 | 1. Fork it ( https://github.com/[your-github-name]/app/fork ) 24 | 2. Create your feature branch (git checkout -b my-new-feature) 25 | 3. Commit your changes (git commit -am 'Add some feature') 26 | 4. Push to the branch (git push origin my-new-feature) 27 | 5. Create a new Pull Request 28 | 29 | ## Contributors 30 | 31 | - [[your-github-name]](https://github.com/[your-github-name]) Serdar Dogruyol - creator, maintainer 32 | -------------------------------------------------------------------------------- /kemal/app/shard.lock: -------------------------------------------------------------------------------- 1 | version: 1.0 2 | shards: 3 | kemal: 4 | github: kemalcr/kemal 5 | commit: 42827c9a9df439640e1d2dec90bd21476197ca9b 6 | 7 | kilt: 8 | github: jeromegn/kilt 9 | version: 0.3.3 10 | 11 | multipart: 12 | github: RX14/multipart.cr 13 | version: 0.1.2 14 | 15 | radix: 16 | github: luislavena/radix 17 | version: 0.3.5 18 | 19 | -------------------------------------------------------------------------------- /kemal/app/shard.yml: -------------------------------------------------------------------------------- 1 | name: app 2 | version: 0.1.0 3 | 4 | dependencies: 5 | kemal: 6 | github: kemalcr/kemal 7 | branch: master 8 | 9 | authors: 10 | - Serdar Dogruyol 11 | 12 | license: MIT 13 | -------------------------------------------------------------------------------- /kemal/app/spec/app_spec.cr: -------------------------------------------------------------------------------- 1 | require "./spec_helper" 2 | 3 | describe App do 4 | # TODO: Write tests 5 | 6 | it "works" do 7 | false.should eq(true) 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /kemal/app/spec/spec_helper.cr: -------------------------------------------------------------------------------- 1 | require "spec" 2 | require "../src/app" 3 | -------------------------------------------------------------------------------- /kemal/app/src/app.cr: -------------------------------------------------------------------------------- 1 | require "kemal" 2 | 3 | logging false 4 | 5 | get "/:title" do |env| 6 | title = env.params.url["title"] 7 | 8 | members = [ 9 | { name: "Serdar Dogruyol" }, 10 | { name: "Fatih Kadir Akin" }, 11 | { name: "Askin Gedik" }, 12 | { name: "Ary Borenszweig" } 13 | ] 14 | 15 | render "src/views/index.ecr" 16 | end 17 | 18 | Kemal.run 19 | -------------------------------------------------------------------------------- /kemal/app/src/views/_bio.ecr: -------------------------------------------------------------------------------- 1 | Name: <%= member[:name] %> 2 | -------------------------------------------------------------------------------- /kemal/app/src/views/index.ecr: -------------------------------------------------------------------------------- 1 |
2 |

Welcome to Kemal!

3 |

Kemal is a Crystal Web Framework targeting to be crazy fast, scalable and simple.

4 |
5 | 6 |
7 |
8 |

Resources: <%= title %>

9 | 17 |
18 | 19 |
20 |

Help

21 | 26 | 27 |

Team Members

28 |
    29 | <% members.each do |member| %> 30 |
  • 31 | <%= render "src/views/_bio.ecr" %> 32 |
  • 33 | <% end %> 34 |
35 |
36 | 37 |
38 | Enjoy it! 39 |
40 | -------------------------------------------------------------------------------- /martini/app/Procfile: -------------------------------------------------------------------------------- 1 | web: GOMAXPROCS=4 MARTINI_ENV=production go run server.go 2 | -------------------------------------------------------------------------------- /martini/app/server: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/martini/app/server -------------------------------------------------------------------------------- /martini/app/server.go: -------------------------------------------------------------------------------- 1 | package main 2 | 3 | import ( 4 | "github.com/go-martini/martini" 5 | "github.com/martini-contrib/render" 6 | ) 7 | 8 | type People []Person 9 | type Person struct { 10 | Name string 11 | } 12 | 13 | func main() { 14 | // Apparently to disable logging we can't use ClassicMartini(?), so do 15 | // everything it would normally do and leave out logging, then make a 16 | // ClassicMartini struct anyhow so we can use it the way all the tutorials 17 | // say. There is almost certainly a better way of doing this. 18 | r := martini.NewRouter() 19 | mn := martini.New() 20 | mn.Use(martini.Recovery()) 21 | mn.Use(martini.Static("public")) 22 | mn.MapTo(r, (*martini.Routes)(nil)) 23 | mn.Action(r.Handle) 24 | m := &martini.ClassicMartini{mn, r} 25 | 26 | // note to people checking out this code: in a normal typical use case, you 27 | // would not need any of the above, and would instead only use the line below. 28 | // m := martini.Classic() 29 | 30 | // set a default layout for templates 31 | m.Use(render.Renderer(render.Options{Layout: "layout"})) 32 | 33 | // HTTP action controller 34 | m.Get("/:title", func(params martini.Params, r render.Render) { 35 | title := params["title"] 36 | members := People{ 37 | Person{Name: "Serdar Dogruyol"}, 38 | Person{Name: "Fatih Kadir Akin"}, 39 | Person{Name: "Askin Gedik"}, 40 | Person{Name: "Ary Borenszweig"}, 41 | } 42 | 43 | // use an anonymous struct to pass complex template data 44 | // see http://talks.golang.org/2012/10things.slide#2 45 | context := struct { 46 | Title string 47 | Members People 48 | }{ 49 | title, 50 | members, 51 | } 52 | 53 | r.HTML(200, "index", context) 54 | }) 55 | 56 | m.Run() 57 | } 58 | -------------------------------------------------------------------------------- /martini/app/templates/bio.tmpl: -------------------------------------------------------------------------------- 1 | Name: {{.}} 2 | -------------------------------------------------------------------------------- /martini/app/templates/index.tmpl: -------------------------------------------------------------------------------- 1 |
2 |

Welcome to Kemal!

3 |

Kemal is a Crystal Web Framework targeting to be crazy fast, scalable and simple.

4 |
5 | 6 |
7 |
8 |

Resources: {{.Title}}

9 | 17 |
18 | 19 |
20 |

Help

21 | 26 | 27 |

Team Members

28 |
    29 | {{ range .Members }} 30 |
  • 31 | {{ template "bio" .Name }} 32 |
  • 33 | {{ end }} 34 |
35 |
36 | 37 |
38 | Enjoy it! 39 |
40 | -------------------------------------------------------------------------------- /martini/app/templates/layout.tmpl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | {{ yield }} 5 | 6 | 7 | -------------------------------------------------------------------------------- /phoenix/app/.gitignore: -------------------------------------------------------------------------------- 1 | /_build 2 | /deps 3 | erl_crash.dump 4 | *.ez 5 | -------------------------------------------------------------------------------- /phoenix/app/Procfile: -------------------------------------------------------------------------------- 1 | web: MIX_ENV=prod elixir -pa _build/prod/consolidated -S mix phoenix.server 2 | -------------------------------------------------------------------------------- /phoenix/app/config/config.exs: -------------------------------------------------------------------------------- 1 | # This file is responsible for configuring your application 2 | # and its dependencies with the aid of the Mix.Config module. 3 | # 4 | # This configuration file is loaded before any dependency and 5 | # is restricted to this project. 6 | use Mix.Config 7 | 8 | # Configures the endpoint 9 | config :benchmarker, Benchmarker.Endpoint, 10 | url: [host: "localhost"], 11 | secret_key_base: "73VPBpeLgZrt/w5Xu7J+8gNUZekDfyc/zrK6/wLr/+pssmAB7pndkPy8wg0ISYP1", 12 | debug_errors: false, 13 | root: Path.expand("..", __DIR__) 14 | 15 | # Configures Elixir's Logger 16 | config :logger, :console, 17 | format: "$time $metadata[$level] $message\n", 18 | metadata: [:request_id] 19 | 20 | # Import environment specific config. This must remain at the bottom 21 | # of this file so it overrides the configuration defined above. 22 | import_config "#{Mix.env}.exs" 23 | -------------------------------------------------------------------------------- /phoenix/app/config/dev.exs: -------------------------------------------------------------------------------- 1 | use Mix.Config 2 | 3 | config :benchmarker, Benchmarker.Endpoint, 4 | http: [port: System.get_env("PORT") || 4000], 5 | debug_errors: true, 6 | cache_static_lookup: false 7 | 8 | # Enables code reloading for development 9 | config :benchmarker, Benchmarker.Endpoint, code_reloader: true 10 | 11 | # Do not include metadata nor timestamps in development logs 12 | config :logger, :console, format: "[$level] $message\n" 13 | -------------------------------------------------------------------------------- /phoenix/app/config/locales/en.exs: -------------------------------------------------------------------------------- 1 | [ 2 | hello: "Hello" 3 | ] 4 | -------------------------------------------------------------------------------- /phoenix/app/config/prod.exs: -------------------------------------------------------------------------------- 1 | use Mix.Config 2 | 3 | # ## SSL Support 4 | # 5 | # To get SSL working, you will need to set: 6 | # 7 | # https: [port: 443, 8 | # keyfile: System.get_env("SOME_APP_SSL_KEY_PATH"), 9 | # certfile: System.get_env("SOME_APP_SSL_CERT_PATH")] 10 | # 11 | # Where those two env variables point to a file on 12 | # disk for the key and cert. 13 | 14 | config :benchmarker, Benchmarker.Endpoint, 15 | url: [host: "example.com"], 16 | http: [port: System.get_env("PORT") || 4000], 17 | secret_key_base: "73VPBpeLgZrt/w5Xu7J+8gNUZekDfyc/zrK6/wLr/+pssmAB7pndkPy8wg0ISYP1" 18 | 19 | # Do not pring debug messages in production 20 | config :logger, level: :error 21 | 22 | # ## Using releases 23 | # 24 | # If you are doing OTP releases, you need to instruct Phoenix 25 | # to start the server for all endpoints: 26 | # 27 | # config :phoenix, :serve_endpoints, true 28 | # 29 | # Alternatively, you can configure exactly which server to 30 | # start per endpoint: 31 | # 32 | # config :benchmarker, Benchmarker.Endpoint, server: true 33 | # 34 | -------------------------------------------------------------------------------- /phoenix/app/config/test.exs: -------------------------------------------------------------------------------- 1 | use Mix.Config 2 | 3 | config :benchmarker, Benchmarker.Endpoint, 4 | http: [port: System.get_env("PORT") || 4001] 5 | 6 | # Print only warnings and errors during test 7 | config :logger, level: :warn -------------------------------------------------------------------------------- /phoenix/app/lib/benchmarker.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker do 2 | use Application 3 | 4 | # See http://elixir-lang.org/docs/stable/elixir/Application.html 5 | # for more information on OTP Applications 6 | def start(_type, _args) do 7 | import Supervisor.Spec, warn: false 8 | 9 | children = [ 10 | # Start the endpoint when the application starts 11 | worker(Benchmarker.Endpoint, []), 12 | 13 | # Here you could define other workers and supervisors as children 14 | # worker(Benchmarker.Worker, [arg1, arg2, arg3]), 15 | ] 16 | 17 | # See http://elixir-lang.org/docs/stable/elixir/Supervisor.html 18 | # for other strategies and supported options 19 | opts = [strategy: :one_for_one, name: Benchmarker.Supervisor] 20 | Supervisor.start_link(children, opts) 21 | end 22 | 23 | # Tell Phoenix to update the endpoint configuration 24 | # whenever the application is updated. 25 | def config_change(changed, _new, removed) do 26 | Benchmarker.Endpoint.config_change(changed, removed) 27 | :ok 28 | end 29 | end 30 | -------------------------------------------------------------------------------- /phoenix/app/lib/benchmarker/endpoint.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.Endpoint do 2 | use Phoenix.Endpoint, otp_app: :benchmarker 3 | 4 | plug Plug.Static, 5 | at: "/static", from: :benchmarker 6 | 7 | plug Plug.Parsers, 8 | parsers: [:urlencoded, :multipart, :json], 9 | pass: ["*/*"], 10 | json_decoder: Poison 11 | 12 | plug Plug.MethodOverride 13 | plug Plug.Head 14 | 15 | plug Plug.Session, 16 | store: :cookie, 17 | key: "_benchmarker_key", 18 | signing_salt: "UU4/F5b7", 19 | encryption_salt: "9R4y+niH" 20 | 21 | plug Benchmarker.Router 22 | 23 | if code_reloading? do 24 | plug Phoenix.LiveReloader 25 | plug Phoenix.CodeReloader 26 | end 27 | end 28 | -------------------------------------------------------------------------------- /phoenix/app/mix.exs: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.Mixfile do 2 | use Mix.Project 3 | 4 | def project do 5 | [app: :benchmarker, 6 | version: "0.0.1", 7 | elixir: "~> 1.1", 8 | elixirc_paths: elixirc_paths(Mix.env), 9 | compilers: [:phoenix] ++ Mix.compilers, 10 | build_embedded: Mix.env == :prod, 11 | start_permanent: Mix.env == :prod, 12 | deps: deps] 13 | end 14 | 15 | # Configuration for the OTP application 16 | # 17 | # Type `mix help compile.app` for more information 18 | def application do 19 | [mod: {Benchmarker, []}, 20 | applications: [:phoenix, :cowboy, :logger]] 21 | end 22 | 23 | # Specifies your project dependencies 24 | # 25 | # Type `mix help deps` for examples and options 26 | defp deps do 27 | [{:phoenix, "~> 1.2.0"}, 28 | {:cowboy, "~> 1.0.4"}, 29 | {:phoenix_live_reload, "~> 1.0.6"}, 30 | {:phoenix_html, "~> 2.9.2"} 31 | ] 32 | end 33 | 34 | defp elixirc_paths(:test), do: ["lib", "web", "test/support"] 35 | defp elixirc_paths(_), do: ["lib", "web"] 36 | end 37 | -------------------------------------------------------------------------------- /phoenix/app/mix.lock: -------------------------------------------------------------------------------- 1 | %{"cowboy": {:hex, :cowboy, "1.0.4", "a324a8df9f2316c833a470d918aaf73ae894278b8aa6226ce7a9bf699388f878", [:make, :rebar], [{:cowlib, "~> 1.0.0", [hex: :cowlib, optional: false]}, {:ranch, "~> 1.0", [hex: :ranch, optional: false]}]}, 2 | "cowlib": {:hex, :cowlib, "1.0.2", "9d769a1d062c9c3ac753096f868ca121e2730b9a377de23dec0f7e08b1df84ee", [:make], []}, 3 | "fs": {:hex, :fs, "0.9.2", "ed17036c26c3f70ac49781ed9220a50c36775c6ca2cf8182d123b6566e49ec59", [:rebar], []}, 4 | "mime": {:hex, :mime, "1.0.1", "05c393850524767d13a53627df71beeebb016205eb43bfbd92d14d24ec7a1b51", [:mix], []}, 5 | "phoenix": {:hex, :phoenix, "1.2.1", "6dc592249ab73c67575769765b66ad164ad25d83defa3492dc6ae269bd2a68ab", [:mix], [{:cowboy, "~> 1.0", [hex: :cowboy, optional: true]}, {:phoenix_pubsub, "~> 1.0", [hex: :phoenix_pubsub, optional: false]}, {:plug, "~> 1.1", [hex: :plug, optional: false]}, {:poison, "~> 1.5 or ~> 2.0", [hex: :poison, optional: false]}]}, 6 | "phoenix_html": {:hex, :phoenix_html, "2.9.2", "371160b30cf4e10443b015efce6f03e1f19aae98ff6487620477b13a5b2ef660", [:mix], [{:plug, "~> 1.0", [hex: :plug, optional: false]}]}, 7 | "phoenix_live_reload": {:hex, :phoenix_live_reload, "1.0.6", "4490d588c4f60248b1c5f1f0dc0a7271e1aed4bddbd8b1542630f7bf6bc7b012", [:mix], [{:fs, "~> 0.9.1", [hex: :fs, optional: false]}, {:phoenix, "~> 1.0 or ~> 1.2-rc", [hex: :phoenix, optional: false]}]}, 8 | "phoenix_pubsub": {:hex, :phoenix_pubsub, "1.0.1", "c10ddf6237007c804bf2b8f3c4d5b99009b42eca3a0dfac04ea2d8001186056a", [:mix], []}, 9 | "plug": {:hex, :plug, "1.3.0", "6e2b01afc5db3fd011ca4a16efd9cb424528c157c30a44a0186bcc92c7b2e8f3", [:mix], [{:cowboy, "~> 1.0.1 or ~> 1.1", [hex: :cowboy, optional: true]}, {:mime, "~> 1.0", [hex: :mime, optional: false]}]}, 10 | "poison": {:hex, :poison, "2.2.0", "4763b69a8a77bd77d26f477d196428b741261a761257ff1cf92753a0d4d24a63", [:mix], []}, 11 | "ranch": {:hex, :ranch, "1.2.1", "a6fb992c10f2187b46ffd17ce398ddf8a54f691b81768f9ef5f461ea7e28c762", [:make], []}} 12 | -------------------------------------------------------------------------------- /phoenix/app/priv/static/css/phoenix.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.1.1 (http://getbootstrap.com) 3 | * Copyright 2011-2014 Twitter, Inc. 4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 5 | */ 6 | 7 | /*! normalize.css v3.0.0 | MIT License | git.io/normalize */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background:0 0}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:700}table{border-collapse:collapse;border-spacing:0}td,th{padding:0}@media print{*{text-shadow:none!important;color:#000!important;background:transparent!important;box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}a[href^="javascript:"]:after,a[href^="#"]:after{content:""}pre,blockquote{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}tr,img{page-break-inside:avoid}img{max-width:100%!important}p,h2,h3{orphans:3;widows:3}h2,h3{page-break-after:avoid}select{background:#fff!important}.navbar{display:none}.table td,.table th{background-color:#fff!important}.btn>.caret,.dropup>.btn>.caret{border-top-color:#000!important}.label{border:1px solid #000}.table{border-collapse:collapse!important}.table-bordered th,.table-bordered td{border:1px solid #ddd!important}}*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}:before,:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}html{font-size:62.5%;-webkit-tap-highlight-color:rgba(0,0,0,0)}body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333;background-color:#fff}input,button,select,textarea{font-family:inherit;font-size:inherit;line-height:inherit}a{color:#428bca;text-decoration:none}a:hover,a:focus{color:#2a6496;text-decoration:underline}a:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}figure{margin:0}img{vertical-align:middle}.img-responsive,.thumbnail>img,.thumbnail a>img,.carousel-inner>.item>img,.carousel-inner>.item>a>img{display:block;max-width:100%;height:auto}.img-rounded{border-radius:6px}.img-thumbnail{padding:4px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out;display:inline-block;max-width:100%;height:auto}.img-circle{border-radius:50%}hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);border:0}h1,h2,h3,h4,h5,h6,.h1,.h2,.h3,.h4,.h5,.h6{font-family:inherit;font-weight:500;line-height:1.1;color:inherit}h1 small,h2 small,h3 small,h4 small,h5 small,h6 small,.h1 small,.h2 small,.h3 small,.h4 small,.h5 small,.h6 small,h1 .small,h2 .small,h3 .small,h4 .small,h5 .small,h6 .small,.h1 .small,.h2 .small,.h3 .small,.h4 .small,.h5 .small,.h6 .small{font-weight:400;line-height:1;color:#999}h1,.h1,h2,.h2,h3,.h3{margin-top:20px;margin-bottom:10px}h1 small,.h1 small,h2 small,.h2 small,h3 small,.h3 small,h1 .small,.h1 .small,h2 .small,.h2 .small,h3 .small,.h3 .small{font-size:65%}h4,.h4,h5,.h5,h6,.h6{margin-top:10px;margin-bottom:10px}h4 small,.h4 small,h5 small,.h5 small,h6 small,.h6 small,h4 .small,.h4 .small,h5 .small,.h5 .small,h6 .small,.h6 .small{font-size:75%}h1,.h1{font-size:36px}h2,.h2{font-size:30px}h3,.h3{font-size:24px}h4,.h4{font-size:18px}h5,.h5{font-size:14px}h6,.h6{font-size:12px}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:16px;font-weight:200;line-height:1.4}@media (min-width:768px){.lead{font-size:21px}}small,.small{font-size:85%}cite{font-style:normal}.text-left{text-align:left}.text-right{text-align:right}.text-center{text-align:center}.text-justify{text-align:justify}.text-muted{color:#999}.text-primary{color:#428bca}a.text-primary:hover{color:#3071a9}.text-success{color:#3c763d}a.text-success:hover{color:#2b542c}.text-info{color:#31708f}a.text-info:hover{color:#245269}.text-warning{color:#8a6d3b}a.text-warning:hover{color:#66512c}.text-danger{color:#a94442}a.text-danger:hover{color:#843534}.bg-primary{color:#fff;background-color:#428bca}a.bg-primary:hover{background-color:#3071a9}.bg-success{background-color:#dff0d8}a.bg-success:hover{background-color:#c1e2b3}.bg-info{background-color:#d9edf7}a.bg-info:hover{background-color:#afd9ee}.bg-warning{background-color:#fcf8e3}a.bg-warning:hover{background-color:#f7ecb5}.bg-danger{background-color:#f2dede}a.bg-danger:hover{background-color:#e4b9b9}.page-header{padding-bottom:9px;margin:40px 0 20px;border-bottom:1px solid #eee}ul,ol{margin-top:0;margin-bottom:10px}ul ul,ol ul,ul ol,ol ol{margin-bottom:0}.list-unstyled{padding-left:0;list-style:none}.list-inline{padding-left:0;list-style:none;margin-left:-5px}.list-inline>li{display:inline-block;padding-left:5px;padding-right:5px}dl{margin-top:0;margin-bottom:20px}dt,dd{line-height:1.42857143}dt{font-weight:700}dd{margin-left:0}@media (min-width:768px){.dl-horizontal dt{float:left;width:160px;clear:left;text-align:right;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}}abbr[title],abbr[data-original-title]{cursor:help;border-bottom:1px dotted #999}.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:10px 20px;margin:0 0 20px;font-size:17.5px;border-left:5px solid #eee}blockquote p:last-child,blockquote ul:last-child,blockquote ol:last-child{margin-bottom:0}blockquote footer,blockquote small,blockquote .small{display:block;font-size:80%;line-height:1.42857143;color:#999}blockquote footer:before,blockquote small:before,blockquote .small:before{content:'\2014 \00A0'}.blockquote-reverse,blockquote.pull-right{padding-right:15px;padding-left:0;border-right:5px solid #eee;border-left:0;text-align:right}.blockquote-reverse footer:before,blockquote.pull-right footer:before,.blockquote-reverse small:before,blockquote.pull-right small:before,.blockquote-reverse .small:before,blockquote.pull-right .small:before{content:''}.blockquote-reverse footer:after,blockquote.pull-right footer:after,.blockquote-reverse small:after,blockquote.pull-right small:after,.blockquote-reverse .small:after,blockquote.pull-right .small:after{content:'\00A0 \2014'}blockquote:before,blockquote:after{content:""}address{margin-bottom:20px;font-style:normal;line-height:1.42857143}code,kbd,pre,samp{font-family:Menlo,Monaco,Consolas,"Courier New",monospace}code{padding:2px 4px;font-size:90%;color:#c7254e;background-color:#f9f2f4;white-space:nowrap;border-radius:4px}kbd{padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;box-shadow:inset 0 -1px 0 rgba(0,0,0,.25)}pre{display:block;padding:9.5px;margin:0 0 10px;font-size:13px;line-height:1.42857143;word-break:break-all;word-wrap:break-word;color:#333;background-color:#f5f5f5;border:1px solid #ccc;border-radius:4px}pre code{padding:0;font-size:inherit;color:inherit;white-space:pre-wrap;background-color:transparent;border-radius:0}.pre-scrollable{max-height:340px;overflow-y:scroll}.container{margin-right:auto;margin-left:auto;padding-left:15px;padding-right:15px}@media (min-width:768px){.container{width:750px}}@media (min-width:992px){.container{width:970px}}@media (min-width:1200px){.container{width:1170px}}.container-fluid{margin-right:auto;margin-left:auto;padding-left:15px;padding-right:15px}.row{margin-left:-15px;margin-right:-15px}.col-xs-1,.col-sm-1,.col-md-1,.col-lg-1,.col-xs-2,.col-sm-2,.col-md-2,.col-lg-2,.col-xs-3,.col-sm-3,.col-md-3,.col-lg-3,.col-xs-4,.col-sm-4,.col-md-4,.col-lg-4,.col-xs-5,.col-sm-5,.col-md-5,.col-lg-5,.col-xs-6,.col-sm-6,.col-md-6,.col-lg-6,.col-xs-7,.col-sm-7,.col-md-7,.col-lg-7,.col-xs-8,.col-sm-8,.col-md-8,.col-lg-8,.col-xs-9,.col-sm-9,.col-md-9,.col-lg-9,.col-xs-10,.col-sm-10,.col-md-10,.col-lg-10,.col-xs-11,.col-sm-11,.col-md-11,.col-lg-11,.col-xs-12,.col-sm-12,.col-md-12,.col-lg-12{position:relative;min-height:1px;padding-left:15px;padding-right:15px}.col-xs-1,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9,.col-xs-10,.col-xs-11,.col-xs-12{float:left}.col-xs-12{width:100%}.col-xs-11{width:91.66666667%}.col-xs-10{width:83.33333333%}.col-xs-9{width:75%}.col-xs-8{width:66.66666667%}.col-xs-7{width:58.33333333%}.col-xs-6{width:50%}.col-xs-5{width:41.66666667%}.col-xs-4{width:33.33333333%}.col-xs-3{width:25%}.col-xs-2{width:16.66666667%}.col-xs-1{width:8.33333333%}.col-xs-pull-12{right:100%}.col-xs-pull-11{right:91.66666667%}.col-xs-pull-10{right:83.33333333%}.col-xs-pull-9{right:75%}.col-xs-pull-8{right:66.66666667%}.col-xs-pull-7{right:58.33333333%}.col-xs-pull-6{right:50%}.col-xs-pull-5{right:41.66666667%}.col-xs-pull-4{right:33.33333333%}.col-xs-pull-3{right:25%}.col-xs-pull-2{right:16.66666667%}.col-xs-pull-1{right:8.33333333%}.col-xs-pull-0{right:0}.col-xs-push-12{left:100%}.col-xs-push-11{left:91.66666667%}.col-xs-push-10{left:83.33333333%}.col-xs-push-9{left:75%}.col-xs-push-8{left:66.66666667%}.col-xs-push-7{left:58.33333333%}.col-xs-push-6{left:50%}.col-xs-push-5{left:41.66666667%}.col-xs-push-4{left:33.33333333%}.col-xs-push-3{left:25%}.col-xs-push-2{left:16.66666667%}.col-xs-push-1{left:8.33333333%}.col-xs-push-0{left:0}.col-xs-offset-12{margin-left:100%}.col-xs-offset-11{margin-left:91.66666667%}.col-xs-offset-10{margin-left:83.33333333%}.col-xs-offset-9{margin-left:75%}.col-xs-offset-8{margin-left:66.66666667%}.col-xs-offset-7{margin-left:58.33333333%}.col-xs-offset-6{margin-left:50%}.col-xs-offset-5{margin-left:41.66666667%}.col-xs-offset-4{margin-left:33.33333333%}.col-xs-offset-3{margin-left:25%}.col-xs-offset-2{margin-left:16.66666667%}.col-xs-offset-1{margin-left:8.33333333%}.col-xs-offset-0{margin-left:0}@media (min-width:768px){.col-sm-1,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9,.col-sm-10,.col-sm-11,.col-sm-12{float:left}.col-sm-12{width:100%}.col-sm-11{width:91.66666667%}.col-sm-10{width:83.33333333%}.col-sm-9{width:75%}.col-sm-8{width:66.66666667%}.col-sm-7{width:58.33333333%}.col-sm-6{width:50%}.col-sm-5{width:41.66666667%}.col-sm-4{width:33.33333333%}.col-sm-3{width:25%}.col-sm-2{width:16.66666667%}.col-sm-1{width:8.33333333%}.col-sm-pull-12{right:100%}.col-sm-pull-11{right:91.66666667%}.col-sm-pull-10{right:83.33333333%}.col-sm-pull-9{right:75%}.col-sm-pull-8{right:66.66666667%}.col-sm-pull-7{right:58.33333333%}.col-sm-pull-6{right:50%}.col-sm-pull-5{right:41.66666667%}.col-sm-pull-4{right:33.33333333%}.col-sm-pull-3{right:25%}.col-sm-pull-2{right:16.66666667%}.col-sm-pull-1{right:8.33333333%}.col-sm-pull-0{right:0}.col-sm-push-12{left:100%}.col-sm-push-11{left:91.66666667%}.col-sm-push-10{left:83.33333333%}.col-sm-push-9{left:75%}.col-sm-push-8{left:66.66666667%}.col-sm-push-7{left:58.33333333%}.col-sm-push-6{left:50%}.col-sm-push-5{left:41.66666667%}.col-sm-push-4{left:33.33333333%}.col-sm-push-3{left:25%}.col-sm-push-2{left:16.66666667%}.col-sm-push-1{left:8.33333333%}.col-sm-push-0{left:0}.col-sm-offset-12{margin-left:100%}.col-sm-offset-11{margin-left:91.66666667%}.col-sm-offset-10{margin-left:83.33333333%}.col-sm-offset-9{margin-left:75%}.col-sm-offset-8{margin-left:66.66666667%}.col-sm-offset-7{margin-left:58.33333333%}.col-sm-offset-6{margin-left:50%}.col-sm-offset-5{margin-left:41.66666667%}.col-sm-offset-4{margin-left:33.33333333%}.col-sm-offset-3{margin-left:25%}.col-sm-offset-2{margin-left:16.66666667%}.col-sm-offset-1{margin-left:8.33333333%}.col-sm-offset-0{margin-left:0}}@media (min-width:992px){.col-md-1,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9,.col-md-10,.col-md-11,.col-md-12{float:left}.col-md-12{width:100%}.col-md-11{width:91.66666667%}.col-md-10{width:83.33333333%}.col-md-9{width:75%}.col-md-8{width:66.66666667%}.col-md-7{width:58.33333333%}.col-md-6{width:50%}.col-md-5{width:41.66666667%}.col-md-4{width:33.33333333%}.col-md-3{width:25%}.col-md-2{width:16.66666667%}.col-md-1{width:8.33333333%}.col-md-pull-12{right:100%}.col-md-pull-11{right:91.66666667%}.col-md-pull-10{right:83.33333333%}.col-md-pull-9{right:75%}.col-md-pull-8{right:66.66666667%}.col-md-pull-7{right:58.33333333%}.col-md-pull-6{right:50%}.col-md-pull-5{right:41.66666667%}.col-md-pull-4{right:33.33333333%}.col-md-pull-3{right:25%}.col-md-pull-2{right:16.66666667%}.col-md-pull-1{right:8.33333333%}.col-md-pull-0{right:0}.col-md-push-12{left:100%}.col-md-push-11{left:91.66666667%}.col-md-push-10{left:83.33333333%}.col-md-push-9{left:75%}.col-md-push-8{left:66.66666667%}.col-md-push-7{left:58.33333333%}.col-md-push-6{left:50%}.col-md-push-5{left:41.66666667%}.col-md-push-4{left:33.33333333%}.col-md-push-3{left:25%}.col-md-push-2{left:16.66666667%}.col-md-push-1{left:8.33333333%}.col-md-push-0{left:0}.col-md-offset-12{margin-left:100%}.col-md-offset-11{margin-left:91.66666667%}.col-md-offset-10{margin-left:83.33333333%}.col-md-offset-9{margin-left:75%}.col-md-offset-8{margin-left:66.66666667%}.col-md-offset-7{margin-left:58.33333333%}.col-md-offset-6{margin-left:50%}.col-md-offset-5{margin-left:41.66666667%}.col-md-offset-4{margin-left:33.33333333%}.col-md-offset-3{margin-left:25%}.col-md-offset-2{margin-left:16.66666667%}.col-md-offset-1{margin-left:8.33333333%}.col-md-offset-0{margin-left:0}}@media (min-width:1200px){.col-lg-1,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9,.col-lg-10,.col-lg-11,.col-lg-12{float:left}.col-lg-12{width:100%}.col-lg-11{width:91.66666667%}.col-lg-10{width:83.33333333%}.col-lg-9{width:75%}.col-lg-8{width:66.66666667%}.col-lg-7{width:58.33333333%}.col-lg-6{width:50%}.col-lg-5{width:41.66666667%}.col-lg-4{width:33.33333333%}.col-lg-3{width:25%}.col-lg-2{width:16.66666667%}.col-lg-1{width:8.33333333%}.col-lg-pull-12{right:100%}.col-lg-pull-11{right:91.66666667%}.col-lg-pull-10{right:83.33333333%}.col-lg-pull-9{right:75%}.col-lg-pull-8{right:66.66666667%}.col-lg-pull-7{right:58.33333333%}.col-lg-pull-6{right:50%}.col-lg-pull-5{right:41.66666667%}.col-lg-pull-4{right:33.33333333%}.col-lg-pull-3{right:25%}.col-lg-pull-2{right:16.66666667%}.col-lg-pull-1{right:8.33333333%}.col-lg-pull-0{right:0}.col-lg-push-12{left:100%}.col-lg-push-11{left:91.66666667%}.col-lg-push-10{left:83.33333333%}.col-lg-push-9{left:75%}.col-lg-push-8{left:66.66666667%}.col-lg-push-7{left:58.33333333%}.col-lg-push-6{left:50%}.col-lg-push-5{left:41.66666667%}.col-lg-push-4{left:33.33333333%}.col-lg-push-3{left:25%}.col-lg-push-2{left:16.66666667%}.col-lg-push-1{left:8.33333333%}.col-lg-push-0{left:0}.col-lg-offset-12{margin-left:100%}.col-lg-offset-11{margin-left:91.66666667%}.col-lg-offset-10{margin-left:83.33333333%}.col-lg-offset-9{margin-left:75%}.col-lg-offset-8{margin-left:66.66666667%}.col-lg-offset-7{margin-left:58.33333333%}.col-lg-offset-6{margin-left:50%}.col-lg-offset-5{margin-left:41.66666667%}.col-lg-offset-4{margin-left:33.33333333%}.col-lg-offset-3{margin-left:25%}.col-lg-offset-2{margin-left:16.66666667%}.col-lg-offset-1{margin-left:8.33333333%}.col-lg-offset-0{margin-left:0}}table{max-width:100%;background-color:transparent}th{text-align:left}.table{width:100%;margin-bottom:20px}.table>thead>tr>th,.table>tbody>tr>th,.table>tfoot>tr>th,.table>thead>tr>td,.table>tbody>tr>td,.table>tfoot>tr>td{padding:8px;line-height:1.42857143;vertical-align:top;border-top:1px solid #ddd}.table>thead>tr>th{vertical-align:bottom;border-bottom:2px solid #ddd}.table>caption+thead>tr:first-child>th,.table>colgroup+thead>tr:first-child>th,.table>thead:first-child>tr:first-child>th,.table>caption+thead>tr:first-child>td,.table>colgroup+thead>tr:first-child>td,.table>thead:first-child>tr:first-child>td{border-top:0}.table>tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed>thead>tr>th,.table-condensed>tbody>tr>th,.table-condensed>tfoot>tr>th,.table-condensed>thead>tr>td,.table-condensed>tbody>tr>td,.table-condensed>tfoot>tr>td{padding:5px}.table-bordered{border:1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>tbody>tr>th,.table-bordered>tfoot>tr>th,.table-bordered>thead>tr>td,.table-bordered>tbody>tr>td,.table-bordered>tfoot>tr>td{border:1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>thead>tr>td{border-bottom-width:2px}.table-striped>tbody>tr:nth-child(odd)>td,.table-striped>tbody>tr:nth-child(odd)>th{background-color:#f9f9f9}.table-hover>tbody>tr:hover>td,.table-hover>tbody>tr:hover>th{background-color:#f5f5f5}table col[class*=col-]{position:static;float:none;display:table-column}table td[class*=col-],table th[class*=col-]{position:static;float:none;display:table-cell}.table>thead>tr>td.active,.table>tbody>tr>td.active,.table>tfoot>tr>td.active,.table>thead>tr>th.active,.table>tbody>tr>th.active,.table>tfoot>tr>th.active,.table>thead>tr.active>td,.table>tbody>tr.active>td,.table>tfoot>tr.active>td,.table>thead>tr.active>th,.table>tbody>tr.active>th,.table>tfoot>tr.active>th{background-color:#f5f5f5}.table-hover>tbody>tr>td.active:hover,.table-hover>tbody>tr>th.active:hover,.table-hover>tbody>tr.active:hover>td,.table-hover>tbody>tr.active:hover>th{background-color:#e8e8e8}.table>thead>tr>td.success,.table>tbody>tr>td.success,.table>tfoot>tr>td.success,.table>thead>tr>th.success,.table>tbody>tr>th.success,.table>tfoot>tr>th.success,.table>thead>tr.success>td,.table>tbody>tr.success>td,.table>tfoot>tr.success>td,.table>thead>tr.success>th,.table>tbody>tr.success>th,.table>tfoot>tr.success>th{background-color:#dff0d8}.table-hover>tbody>tr>td.success:hover,.table-hover>tbody>tr>th.success:hover,.table-hover>tbody>tr.success:hover>td,.table-hover>tbody>tr.success:hover>th{background-color:#d0e9c6}.table>thead>tr>td.info,.table>tbody>tr>td.info,.table>tfoot>tr>td.info,.table>thead>tr>th.info,.table>tbody>tr>th.info,.table>tfoot>tr>th.info,.table>thead>tr.info>td,.table>tbody>tr.info>td,.table>tfoot>tr.info>td,.table>thead>tr.info>th,.table>tbody>tr.info>th,.table>tfoot>tr.info>th{background-color:#d9edf7}.table-hover>tbody>tr>td.info:hover,.table-hover>tbody>tr>th.info:hover,.table-hover>tbody>tr.info:hover>td,.table-hover>tbody>tr.info:hover>th{background-color:#c4e3f3}.table>thead>tr>td.warning,.table>tbody>tr>td.warning,.table>tfoot>tr>td.warning,.table>thead>tr>th.warning,.table>tbody>tr>th.warning,.table>tfoot>tr>th.warning,.table>thead>tr.warning>td,.table>tbody>tr.warning>td,.table>tfoot>tr.warning>td,.table>thead>tr.warning>th,.table>tbody>tr.warning>th,.table>tfoot>tr.warning>th{background-color:#fcf8e3}.table-hover>tbody>tr>td.warning:hover,.table-hover>tbody>tr>th.warning:hover,.table-hover>tbody>tr.warning:hover>td,.table-hover>tbody>tr.warning:hover>th{background-color:#faf2cc}.table>thead>tr>td.danger,.table>tbody>tr>td.danger,.table>tfoot>tr>td.danger,.table>thead>tr>th.danger,.table>tbody>tr>th.danger,.table>tfoot>tr>th.danger,.table>thead>tr.danger>td,.table>tbody>tr.danger>td,.table>tfoot>tr.danger>td,.table>thead>tr.danger>th,.table>tbody>tr.danger>th,.table>tfoot>tr.danger>th{background-color:#f2dede}.table-hover>tbody>tr>td.danger:hover,.table-hover>tbody>tr>th.danger:hover,.table-hover>tbody>tr.danger:hover>td,.table-hover>tbody>tr.danger:hover>th{background-color:#ebcccc}@media (max-width:767px){.table-responsive{width:100%;margin-bottom:15px;overflow-y:hidden;overflow-x:scroll;-ms-overflow-style:-ms-autohiding-scrollbar;border:1px solid #ddd;-webkit-overflow-scrolling:touch}.table-responsive>.table{margin-bottom:0}.table-responsive>.table>thead>tr>th,.table-responsive>.table>tbody>tr>th,.table-responsive>.table>tfoot>tr>th,.table-responsive>.table>thead>tr>td,.table-responsive>.table>tbody>tr>td,.table-responsive>.table>tfoot>tr>td{white-space:nowrap}.table-responsive>.table-bordered{border:0}.table-responsive>.table-bordered>thead>tr>th:first-child,.table-responsive>.table-bordered>tbody>tr>th:first-child,.table-responsive>.table-bordered>tfoot>tr>th:first-child,.table-responsive>.table-bordered>thead>tr>td:first-child,.table-responsive>.table-bordered>tbody>tr>td:first-child,.table-responsive>.table-bordered>tfoot>tr>td:first-child{border-left:0}.table-responsive>.table-bordered>thead>tr>th:last-child,.table-responsive>.table-bordered>tbody>tr>th:last-child,.table-responsive>.table-bordered>tfoot>tr>th:last-child,.table-responsive>.table-bordered>thead>tr>td:last-child,.table-responsive>.table-bordered>tbody>tr>td:last-child,.table-responsive>.table-bordered>tfoot>tr>td:last-child{border-right:0}.table-responsive>.table-bordered>tbody>tr:last-child>th,.table-responsive>.table-bordered>tfoot>tr:last-child>th,.table-responsive>.table-bordered>tbody>tr:last-child>td,.table-responsive>.table-bordered>tfoot>tr:last-child>td{border-bottom:0}}fieldset{padding:0;margin:0;border:0;min-width:0}legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}label{display:inline-block;margin-bottom:5px;font-weight:700}input[type=search]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}input[type=radio],input[type=checkbox]{margin:4px 0 0;margin-top:1px \9;line-height:normal}input[type=file]{display:block}input[type=range]{display:block;width:100%}select[multiple],select[size]{height:auto}input[type=file]:focus,input[type=radio]:focus,input[type=checkbox]:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}output{display:block;padding-top:7px;font-size:14px;line-height:1.42857143;color:#555}.form-control{display:block;width:100%;height:34px;padding:6px 12px;font-size:14px;line-height:1.42857143;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.form-control::-moz-placeholder{color:#999;opacity:1}.form-control:-ms-input-placeholder{color:#999}.form-control::-webkit-input-placeholder{color:#999}.form-control[disabled],.form-control[readonly],fieldset[disabled] .form-control{cursor:not-allowed;background-color:#eee;opacity:1}textarea.form-control{height:auto}input[type=search]{-webkit-appearance:none}input[type=date]{line-height:34px}.form-group{margin-bottom:15px}.radio,.checkbox{display:block;min-height:20px;margin-top:10px;margin-bottom:10px;padding-left:20px}.radio label,.checkbox label{display:inline;font-weight:400;cursor:pointer}.radio input[type=radio],.radio-inline input[type=radio],.checkbox input[type=checkbox],.checkbox-inline input[type=checkbox]{float:left;margin-left:-20px}.radio+.radio,.checkbox+.checkbox{margin-top:-5px}.radio-inline,.checkbox-inline{display:inline-block;padding-left:20px;margin-bottom:0;vertical-align:middle;font-weight:400;cursor:pointer}.radio-inline+.radio-inline,.checkbox-inline+.checkbox-inline{margin-top:0;margin-left:10px}input[type=radio][disabled],input[type=checkbox][disabled],.radio[disabled],.radio-inline[disabled],.checkbox[disabled],.checkbox-inline[disabled],fieldset[disabled] input[type=radio],fieldset[disabled] input[type=checkbox],fieldset[disabled] .radio,fieldset[disabled] .radio-inline,fieldset[disabled] .checkbox,fieldset[disabled] .checkbox-inline{cursor:not-allowed}.input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-sm{height:30px;line-height:30px}textarea.input-sm,select[multiple].input-sm{height:auto}.input-lg{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}select.input-lg{height:46px;line-height:46px}textarea.input-lg,select[multiple].input-lg{height:auto}.has-feedback{position:relative}.has-feedback .form-control{padding-right:42.5px}.has-feedback .form-control-feedback{position:absolute;top:25px;right:0;display:block;width:34px;height:34px;line-height:34px;text-align:center}.has-success .help-block,.has-success .control-label,.has-success .radio,.has-success .checkbox,.has-success .radio-inline,.has-success .checkbox-inline{color:#3c763d}.has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.has-success .input-group-addon{color:#3c763d;border-color:#3c763d;background-color:#dff0d8}.has-success .form-control-feedback{color:#3c763d}.has-warning .help-block,.has-warning .control-label,.has-warning .radio,.has-warning .checkbox,.has-warning .radio-inline,.has-warning .checkbox-inline{color:#8a6d3b}.has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.has-warning .input-group-addon{color:#8a6d3b;border-color:#8a6d3b;background-color:#fcf8e3}.has-warning .form-control-feedback{color:#8a6d3b}.has-error .help-block,.has-error .control-label,.has-error .radio,.has-error .checkbox,.has-error .radio-inline,.has-error .checkbox-inline{color:#a94442}.has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.has-error .input-group-addon{color:#a94442;border-color:#a94442;background-color:#f2dede}.has-error .form-control-feedback{color:#a94442}.form-control-static{margin-bottom:0}.help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.form-inline .input-group>.form-control{width:100%}.form-inline .control-label{margin-bottom:0;vertical-align:middle}.form-inline .radio,.form-inline .checkbox{display:inline-block;margin-top:0;margin-bottom:0;padding-left:0;vertical-align:middle}.form-inline .radio input[type=radio],.form-inline .checkbox input[type=checkbox]{float:none;margin-left:0}.form-inline .has-feedback .form-control-feedback{top:0}}.form-horizontal .control-label,.form-horizontal .radio,.form-horizontal .checkbox,.form-horizontal .radio-inline,.form-horizontal .checkbox-inline{margin-top:0;margin-bottom:0;padding-top:7px}.form-horizontal .radio,.form-horizontal .checkbox{min-height:27px}.form-horizontal .form-group{margin-left:-15px;margin-right:-15px}.form-horizontal .form-control-static{padding-top:7px}@media (min-width:768px){.form-horizontal .control-label{text-align:right}}.form-horizontal .has-feedback .form-control-feedback{top:0;right:15px}.btn{display:inline-block;margin-bottom:0;font-weight:400;text-align:center;vertical-align:middle;cursor:pointer;background-image:none;border:1px solid transparent;white-space:nowrap;padding:6px 12px;font-size:14px;line-height:1.42857143;border-radius:4px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.btn:focus,.btn:active:focus,.btn.active:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.btn:hover,.btn:focus{color:#333;text-decoration:none}.btn:active,.btn.active{outline:0;background-image:none;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn.disabled,.btn[disabled],fieldset[disabled] .btn{cursor:not-allowed;pointer-events:none;opacity:.65;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none}.btn-default{color:#333;background-color:#fff;border-color:#ccc}.btn-default:hover,.btn-default:focus,.btn-default:active,.btn-default.active,.open .dropdown-toggle.btn-default{color:#333;background-color:#ebebeb;border-color:#adadad}.btn-default:active,.btn-default.active,.open .dropdown-toggle.btn-default{background-image:none}.btn-default.disabled,.btn-default[disabled],fieldset[disabled] .btn-default,.btn-default.disabled:hover,.btn-default[disabled]:hover,fieldset[disabled] .btn-default:hover,.btn-default.disabled:focus,.btn-default[disabled]:focus,fieldset[disabled] .btn-default:focus,.btn-default.disabled:active,.btn-default[disabled]:active,fieldset[disabled] .btn-default:active,.btn-default.disabled.active,.btn-default[disabled].active,fieldset[disabled] .btn-default.active{background-color:#fff;border-color:#ccc}.btn-default .badge{color:#fff;background-color:#333}.btn-primary{color:#fff;background-color:#428bca;border-color:#357ebd}.btn-primary:hover,.btn-primary:focus,.btn-primary:active,.btn-primary.active,.open .dropdown-toggle.btn-primary{color:#fff;background-color:#3276b1;border-color:#285e8e}.btn-primary:active,.btn-primary.active,.open .dropdown-toggle.btn-primary{background-image:none}.btn-primary.disabled,.btn-primary[disabled],fieldset[disabled] .btn-primary,.btn-primary.disabled:hover,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary:hover,.btn-primary.disabled:focus,.btn-primary[disabled]:focus,fieldset[disabled] .btn-primary:focus,.btn-primary.disabled:active,.btn-primary[disabled]:active,fieldset[disabled] .btn-primary:active,.btn-primary.disabled.active,.btn-primary[disabled].active,fieldset[disabled] .btn-primary.active{background-color:#428bca;border-color:#357ebd}.btn-primary .badge{color:#428bca;background-color:#fff}.btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.btn-success:hover,.btn-success:focus,.btn-success:active,.btn-success.active,.open .dropdown-toggle.btn-success{color:#fff;background-color:#47a447;border-color:#398439}.btn-success:active,.btn-success.active,.open .dropdown-toggle.btn-success{background-image:none}.btn-success.disabled,.btn-success[disabled],fieldset[disabled] .btn-success,.btn-success.disabled:hover,.btn-success[disabled]:hover,fieldset[disabled] .btn-success:hover,.btn-success.disabled:focus,.btn-success[disabled]:focus,fieldset[disabled] .btn-success:focus,.btn-success.disabled:active,.btn-success[disabled]:active,fieldset[disabled] .btn-success:active,.btn-success.disabled.active,.btn-success[disabled].active,fieldset[disabled] .btn-success.active{background-color:#5cb85c;border-color:#4cae4c}.btn-success .badge{color:#5cb85c;background-color:#fff}.btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.btn-info:hover,.btn-info:focus,.btn-info:active,.btn-info.active,.open .dropdown-toggle.btn-info{color:#fff;background-color:#39b3d7;border-color:#269abc}.btn-info:active,.btn-info.active,.open .dropdown-toggle.btn-info{background-image:none}.btn-info.disabled,.btn-info[disabled],fieldset[disabled] .btn-info,.btn-info.disabled:hover,.btn-info[disabled]:hover,fieldset[disabled] .btn-info:hover,.btn-info.disabled:focus,.btn-info[disabled]:focus,fieldset[disabled] .btn-info:focus,.btn-info.disabled:active,.btn-info[disabled]:active,fieldset[disabled] .btn-info:active,.btn-info.disabled.active,.btn-info[disabled].active,fieldset[disabled] .btn-info.active{background-color:#5bc0de;border-color:#46b8da}.btn-info .badge{color:#5bc0de;background-color:#fff}.btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.btn-warning:hover,.btn-warning:focus,.btn-warning:active,.btn-warning.active,.open .dropdown-toggle.btn-warning{color:#fff;background-color:#ed9c28;border-color:#d58512}.btn-warning:active,.btn-warning.active,.open .dropdown-toggle.btn-warning{background-image:none}.btn-warning.disabled,.btn-warning[disabled],fieldset[disabled] .btn-warning,.btn-warning.disabled:hover,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning:hover,.btn-warning.disabled:focus,.btn-warning[disabled]:focus,fieldset[disabled] .btn-warning:focus,.btn-warning.disabled:active,.btn-warning[disabled]:active,fieldset[disabled] .btn-warning:active,.btn-warning.disabled.active,.btn-warning[disabled].active,fieldset[disabled] .btn-warning.active{background-color:#f0ad4e;border-color:#eea236}.btn-warning .badge{color:#f0ad4e;background-color:#fff}.btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.btn-danger:hover,.btn-danger:focus,.btn-danger:active,.btn-danger.active,.open .dropdown-toggle.btn-danger{color:#fff;background-color:#d2322d;border-color:#ac2925}.btn-danger:active,.btn-danger.active,.open .dropdown-toggle.btn-danger{background-image:none}.btn-danger.disabled,.btn-danger[disabled],fieldset[disabled] .btn-danger,.btn-danger.disabled:hover,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger:hover,.btn-danger.disabled:focus,.btn-danger[disabled]:focus,fieldset[disabled] .btn-danger:focus,.btn-danger.disabled:active,.btn-danger[disabled]:active,fieldset[disabled] .btn-danger:active,.btn-danger.disabled.active,.btn-danger[disabled].active,fieldset[disabled] .btn-danger.active{background-color:#d9534f;border-color:#d43f3a}.btn-danger .badge{color:#d9534f;background-color:#fff}.btn-link{color:#428bca;font-weight:400;cursor:pointer;border-radius:0}.btn-link,.btn-link:active,.btn-link[disabled],fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.btn-link,.btn-link:hover,.btn-link:focus,.btn-link:active{border-color:transparent}.btn-link:hover,.btn-link:focus{color:#2a6496;text-decoration:underline;background-color:transparent}.btn-link[disabled]:hover,fieldset[disabled] .btn-link:hover,.btn-link[disabled]:focus,fieldset[disabled] .btn-link:focus{color:#999;text-decoration:none}.btn-lg,.btn-group-lg>.btn{padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.btn-sm,.btn-group-sm>.btn{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.btn-xs,.btn-group-xs>.btn{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.btn-block{display:block;width:100%;padding-left:0;padding-right:0}.btn-block+.btn-block{margin-top:5px}input[type=submit].btn-block,input[type=reset].btn-block,input[type=button].btn-block{width:100%}.fade{opacity:0;-webkit-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{display:none}.collapse.in{display:block}.collapsing{position:relative;height:0;overflow:hidden;-webkit-transition:height .35s ease;transition:height .35s ease}@font-face{font-family:'Glyphicons Halflings';src:url(../fonts/glyphicons-halflings-regular.eot);src:url(../fonts/glyphicons-halflings-regular.eot?#iefix) format('embedded-opentype'),url(../fonts/glyphicons-halflings-regular.woff) format('woff'),url(../fonts/glyphicons-halflings-regular.ttf) format('truetype'),url(../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular) format('svg')}.glyphicon{position:relative;top:1px;display:inline-block;font-family:'Glyphicons Halflings';font-style:normal;font-weight:400;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\2a"}.glyphicon-plus:before{content:"\2b"}.glyphicon-euro:before{content:"\20ac"}.glyphicon-minus:before{content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content:"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"}.glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphicon-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empty:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{content:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e011"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{content:"\e013"}.glyphicon-remove:before{content:"\e014"}.glyphicon-zoom-in:before{content:"\e015"}.glyphicon-zoom-out:before{content:"\e016"}.glyphicon-off:before{content:"\e017"}.glyphicon-signal:before{content:"\e018"}.glyphicon-cog:before{content:"\e019"}.glyphicon-trash:before{content:"\e020"}.glyphicon-home:before{content:"\e021"}.glyphicon-file:before{content:"\e022"}.glyphicon-time:before{content:"\e023"}.glyphicon-road:before{content:"\e024"}.glyphicon-download-alt:before{content:"\e025"}.glyphicon-download:before{content:"\e026"}.glyphicon-upload:before{content:"\e027"}.glyphicon-inbox:before{content:"\e028"}.glyphicon-play-circle:before{content:"\e029"}.glyphicon-repeat:before{content:"\e030"}.glyphicon-refresh:before{content:"\e031"}.glyphicon-list-alt:before{content:"\e032"}.glyphicon-lock:before{content:"\e033"}.glyphicon-flag:before{content:"\e034"}.glyphicon-headphones:before{content:"\e035"}.glyphicon-volume-off:before{content:"\e036"}.glyphicon-volume-down:before{content:"\e037"}.glyphicon-volume-up:before{content:"\e038"}.glyphicon-qrcode:before{content:"\e039"}.glyphicon-barcode:before{content:"\e040"}.glyphicon-tag:before{content:"\e041"}.glyphicon-tags:before{content:"\e042"}.glyphicon-book:before{content:"\e043"}.glyphicon-bookmark:before{content:"\e044"}.glyphicon-print:before{content:"\e045"}.glyphicon-camera:before{content:"\e046"}.glyphicon-font:before{content:"\e047"}.glyphicon-bold:before{content:"\e048"}.glyphicon-italic:before{content:"\e049"}.glyphicon-text-height:before{content:"\e050"}.glyphicon-text-width:before{content:"\e051"}.glyphicon-align-left:before{content:"\e052"}.glyphicon-align-center:before{content:"\e053"}.glyphicon-align-right:before{content:"\e054"}.glyphicon-align-justify:before{content:"\e055"}.glyphicon-list:before{content:"\e056"}.glyphicon-indent-left:before{content:"\e057"}.glyphicon-indent-right:before{content:"\e058"}.glyphicon-facetime-video:before{content:"\e059"}.glyphicon-picture:before{content:"\e060"}.glyphicon-map-marker:before{content:"\e062"}.glyphicon-adjust:before{content:"\e063"}.glyphicon-tint:before{content:"\e064"}.glyphicon-edit:before{content:"\e065"}.glyphicon-share:before{content:"\e066"}.glyphicon-check:before{content:"\e067"}.glyphicon-move:before{content:"\e068"}.glyphicon-step-backward:before{content:"\e069"}.glyphicon-fast-backward:before{content:"\e070"}.glyphicon-backward:before{content:"\e071"}.glyphicon-play:before{content:"\e072"}.glyphicon-pause:before{content:"\e073"}.glyphicon-stop:before{content:"\e074"}.glyphicon-forward:before{content:"\e075"}.glyphicon-fast-forward:before{content:"\e076"}.glyphicon-step-forward:before{content:"\e077"}.glyphicon-eject:before{content:"\e078"}.glyphicon-chevron-left:before{content:"\e079"}.glyphicon-chevron-right:before{content:"\e080"}.glyphicon-plus-sign:before{content:"\e081"}.glyphicon-minus-sign:before{content:"\e082"}.glyphicon-remove-sign:before{content:"\e083"}.glyphicon-ok-sign:before{content:"\e084"}.glyphicon-question-sign:before{content:"\e085"}.glyphicon-info-sign:before{content:"\e086"}.glyphicon-screenshot:before{content:"\e087"}.glyphicon-remove-circle:before{content:"\e088"}.glyphicon-ok-circle:before{content:"\e089"}.glyphicon-ban-circle:before{content:"\e090"}.glyphicon-arrow-left:before{content:"\e091"}.glyphicon-arrow-right:before{content:"\e092"}.glyphicon-arrow-up:before{content:"\e093"}.glyphicon-arrow-down:before{content:"\e094"}.glyphicon-share-alt:before{content:"\e095"}.glyphicon-resize-full:before{content:"\e096"}.glyphicon-resize-small:before{content:"\e097"}.glyphicon-exclamation-sign:before{content:"\e101"}.glyphicon-gift:before{content:"\e102"}.glyphicon-leaf:before{content:"\e103"}.glyphicon-fire:before{content:"\e104"}.glyphicon-eye-open:before{content:"\e105"}.glyphicon-eye-close:before{content:"\e106"}.glyphicon-warning-sign:before{content:"\e107"}.glyphicon-plane:before{content:"\e108"}.glyphicon-calendar:before{content:"\e109"}.glyphicon-random:before{content:"\e110"}.glyphicon-comment:before{content:"\e111"}.glyphicon-magnet:before{content:"\e112"}.glyphicon-chevron-up:before{content:"\e113"}.glyphicon-chevron-down:before{content:"\e114"}.glyphicon-retweet:before{content:"\e115"}.glyphicon-shopping-cart:before{content:"\e116"}.glyphicon-folder-close:before{content:"\e117"}.glyphicon-folder-open:before{content:"\e118"}.glyphicon-resize-vertical:before{content:"\e119"}.glyphicon-resize-horizontal:before{content:"\e120"}.glyphicon-hdd:before{content:"\e121"}.glyphicon-bullhorn:before{content:"\e122"}.glyphicon-bell:before{content:"\e123"}.glyphicon-certificate:before{content:"\e124"}.glyphicon-thumbs-up:before{content:"\e125"}.glyphicon-thumbs-down:before{content:"\e126"}.glyphicon-hand-right:before{content:"\e127"}.glyphicon-hand-left:before{content:"\e128"}.glyphicon-hand-up:before{content:"\e129"}.glyphicon-hand-down:before{content:"\e130"}.glyphicon-circle-arrow-right:before{content:"\e131"}.glyphicon-circle-arrow-left:before{content:"\e132"}.glyphicon-circle-arrow-up:before{content:"\e133"}.glyphicon-circle-arrow-down:before{content:"\e134"}.glyphicon-globe:before{content:"\e135"}.glyphicon-wrench:before{content:"\e136"}.glyphicon-tasks:before{content:"\e137"}.glyphicon-filter:before{content:"\e138"}.glyphicon-briefcase:before{content:"\e139"}.glyphicon-fullscreen:before{content:"\e140"}.glyphicon-dashboard:before{content:"\e141"}.glyphicon-paperclip:before{content:"\e142"}.glyphicon-heart-empty:before{content:"\e143"}.glyphicon-link:before{content:"\e144"}.glyphicon-phone:before{content:"\e145"}.glyphicon-pushpin:before{content:"\e146"}.glyphicon-usd:before{content:"\e148"}.glyphicon-gbp:before{content:"\e149"}.glyphicon-sort:before{content:"\e150"}.glyphicon-sort-by-alphabet:before{content:"\e151"}.glyphicon-sort-by-alphabet-alt:before{content:"\e152"}.glyphicon-sort-by-order:before{content:"\e153"}.glyphicon-sort-by-order-alt:before{content:"\e154"}.glyphicon-sort-by-attributes:before{content:"\e155"}.glyphicon-sort-by-attributes-alt:before{content:"\e156"}.glyphicon-unchecked:before{content:"\e157"}.glyphicon-expand:before{content:"\e158"}.glyphicon-collapse-down:before{content:"\e159"}.glyphicon-collapse-up:before{content:"\e160"}.glyphicon-log-in:before{content:"\e161"}.glyphicon-flash:before{content:"\e162"}.glyphicon-log-out:before{content:"\e163"}.glyphicon-new-window:before{content:"\e164"}.glyphicon-record:before{content:"\e165"}.glyphicon-save:before{content:"\e166"}.glyphicon-open:before{content:"\e167"}.glyphicon-saved:before{content:"\e168"}.glyphicon-import:before{content:"\e169"}.glyphicon-export:before{content:"\e170"}.glyphicon-send:before{content:"\e171"}.glyphicon-floppy-disk:before{content:"\e172"}.glyphicon-floppy-saved:before{content:"\e173"}.glyphicon-floppy-remove:before{content:"\e174"}.glyphicon-floppy-save:before{content:"\e175"}.glyphicon-floppy-open:before{content:"\e176"}.glyphicon-credit-card:before{content:"\e177"}.glyphicon-transfer:before{content:"\e178"}.glyphicon-cutlery:before{content:"\e179"}.glyphicon-header:before{content:"\e180"}.glyphicon-compressed:before{content:"\e181"}.glyphicon-earphone:before{content:"\e182"}.glyphicon-phone-alt:before{content:"\e183"}.glyphicon-tower:before{content:"\e184"}.glyphicon-stats:before{content:"\e185"}.glyphicon-sd-video:before{content:"\e186"}.glyphicon-hd-video:before{content:"\e187"}.glyphicon-subtitles:before{content:"\e188"}.glyphicon-sound-stereo:before{content:"\e189"}.glyphicon-sound-dolby:before{content:"\e190"}.glyphicon-sound-5-1:before{content:"\e191"}.glyphicon-sound-6-1:before{content:"\e192"}.glyphicon-sound-7-1:before{content:"\e193"}.glyphicon-copyright-mark:before{content:"\e194"}.glyphicon-registration-mark:before{content:"\e195"}.glyphicon-cloud-download:before{content:"\e197"}.glyphicon-cloud-upload:before{content:"\e198"}.glyphicon-tree-conifer:before{content:"\e199"}.glyphicon-tree-deciduous:before{content:"\e200"}.caret{display:inline-block;width:0;height:0;margin-left:2px;vertical-align:middle;border-top:4px solid;border-right:4px solid transparent;border-left:4px solid transparent}.dropdown{position:relative}.dropdown-toggle:focus{outline:0}.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;float:left;min-width:160px;padding:5px 0;margin:2px 0 0;list-style:none;font-size:14px;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175);background-clip:padding-box}.dropdown-menu.pull-right{right:0;left:auto}.dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.dropdown-menu>li>a{display:block;padding:3px 20px;clear:both;font-weight:400;line-height:1.42857143;color:#333;white-space:nowrap}.dropdown-menu>li>a:hover,.dropdown-menu>li>a:focus{text-decoration:none;color:#262626;background-color:#f5f5f5}.dropdown-menu>.active>a,.dropdown-menu>.active>a:hover,.dropdown-menu>.active>a:focus{color:#fff;text-decoration:none;outline:0;background-color:#428bca}.dropdown-menu>.disabled>a,.dropdown-menu>.disabled>a:hover,.dropdown-menu>.disabled>a:focus{color:#999}.dropdown-menu>.disabled>a:hover,.dropdown-menu>.disabled>a:focus{text-decoration:none;background-color:transparent;background-image:none;filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);cursor:not-allowed}.open>.dropdown-menu{display:block}.open>a{outline:0}.dropdown-menu-right{left:auto;right:0}.dropdown-menu-left{left:0;right:auto}.dropdown-header{display:block;padding:3px 20px;font-size:12px;line-height:1.42857143;color:#999}.dropdown-backdrop{position:fixed;left:0;right:0;bottom:0;top:0;z-index:990}.pull-right>.dropdown-menu{right:0;left:auto}.dropup .caret,.navbar-fixed-bottom .dropdown .caret{border-top:0;border-bottom:4px solid;content:""}.dropup .dropdown-menu,.navbar-fixed-bottom .dropdown .dropdown-menu{top:auto;bottom:100%;margin-bottom:1px}@media (min-width:768px){.navbar-right .dropdown-menu{left:auto;right:0}.navbar-right .dropdown-menu-left{left:0;right:auto}}.btn-group,.btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.btn-group>.btn,.btn-group-vertical>.btn{position:relative;float:left}.btn-group>.btn:hover,.btn-group-vertical>.btn:hover,.btn-group>.btn:focus,.btn-group-vertical>.btn:focus,.btn-group>.btn:active,.btn-group-vertical>.btn:active,.btn-group>.btn.active,.btn-group-vertical>.btn.active{z-index:2}.btn-group>.btn:focus,.btn-group-vertical>.btn:focus{outline:0}.btn-group .btn+.btn,.btn-group .btn+.btn-group,.btn-group .btn-group+.btn,.btn-group .btn-group+.btn-group{margin-left:-1px}.btn-toolbar{margin-left:-5px}.btn-toolbar .btn-group,.btn-toolbar .input-group{float:left}.btn-toolbar>.btn,.btn-toolbar>.btn-group,.btn-toolbar>.input-group{margin-left:5px}.btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){border-radius:0}.btn-group>.btn:first-child{margin-left:0}.btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){border-bottom-right-radius:0;border-top-right-radius:0}.btn-group>.btn:last-child:not(:first-child),.btn-group>.dropdown-toggle:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0}.btn-group>.btn-group{float:left}.btn-group>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group>.btn-group:first-child>.btn:last-child,.btn-group>.btn-group:first-child>.dropdown-toggle{border-bottom-right-radius:0;border-top-right-radius:0}.btn-group>.btn-group:last-child>.btn:first-child{border-bottom-left-radius:0;border-top-left-radius:0}.btn-group .dropdown-toggle:active,.btn-group.open .dropdown-toggle{outline:0}.btn-group>.btn+.dropdown-toggle{padding-left:8px;padding-right:8px}.btn-group>.btn-lg+.dropdown-toggle{padding-left:12px;padding-right:12px}.btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.btn .caret{margin-left:0}.btn-lg .caret{border-width:5px 5px 0;border-bottom-width:0}.dropup .btn-lg .caret{border-width:0 5px 5px}.btn-group-vertical>.btn,.btn-group-vertical>.btn-group,.btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.btn-group-vertical>.btn-group>.btn{float:none}.btn-group-vertical>.btn+.btn,.btn-group-vertical>.btn+.btn-group,.btn-group-vertical>.btn-group+.btn,.btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.btn-group-vertical>.btn:not(:first-child):not(:last-child){border-radius:0}.btn-group-vertical>.btn:first-child:not(:last-child){border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn:last-child:not(:first-child){border-bottom-left-radius:4px;border-top-right-radius:0;border-top-left-radius:0}.btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-right-radius:0;border-top-left-radius:0}.btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.btn-group-justified>.btn,.btn-group-justified>.btn-group{float:none;display:table-cell;width:1%}.btn-group-justified>.btn-group .btn{width:100%}[data-toggle=buttons]>.btn>input[type=radio],[data-toggle=buttons]>.btn>input[type=checkbox]{display:none}.input-group{position:relative;display:table;border-collapse:separate}.input-group[class*=col-]{float:none;padding-left:0;padding-right:0}.input-group .form-control{position:relative;z-index:2;float:left;width:100%;margin-bottom:0}.input-group-lg>.form-control,.input-group-lg>.input-group-addon,.input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}select.input-group-lg>.form-control,select.input-group-lg>.input-group-addon,select.input-group-lg>.input-group-btn>.btn{height:46px;line-height:46px}textarea.input-group-lg>.form-control,textarea.input-group-lg>.input-group-addon,textarea.input-group-lg>.input-group-btn>.btn,select[multiple].input-group-lg>.form-control,select[multiple].input-group-lg>.input-group-addon,select[multiple].input-group-lg>.input-group-btn>.btn{height:auto}.input-group-sm>.form-control,.input-group-sm>.input-group-addon,.input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-group-sm>.form-control,select.input-group-sm>.input-group-addon,select.input-group-sm>.input-group-btn>.btn{height:30px;line-height:30px}textarea.input-group-sm>.form-control,textarea.input-group-sm>.input-group-addon,textarea.input-group-sm>.input-group-btn>.btn,select[multiple].input-group-sm>.form-control,select[multiple].input-group-sm>.input-group-addon,select[multiple].input-group-sm>.input-group-btn>.btn{height:auto}.input-group-addon,.input-group-btn,.input-group .form-control{display:table-cell}.input-group-addon:not(:first-child):not(:last-child),.input-group-btn:not(:first-child):not(:last-child),.input-group .form-control:not(:first-child):not(:last-child){border-radius:0}.input-group-addon,.input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;border-radius:4px}.input-group-addon.input-sm{padding:5px 10px;font-size:12px;border-radius:3px}.input-group-addon.input-lg{padding:10px 16px;font-size:18px;border-radius:6px}.input-group-addon input[type=radio],.input-group-addon input[type=checkbox]{margin-top:0}.input-group .form-control:first-child,.input-group-addon:first-child,.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group>.btn,.input-group-btn:first-child>.dropdown-toggle,.input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle),.input-group-btn:last-child>.btn-group:not(:last-child)>.btn{border-bottom-right-radius:0;border-top-right-radius:0}.input-group-addon:first-child{border-right:0}.input-group .form-control:last-child,.input-group-addon:last-child,.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group>.btn,.input-group-btn:last-child>.dropdown-toggle,.input-group-btn:first-child>.btn:not(:first-child),.input-group-btn:first-child>.btn-group:not(:first-child)>.btn{border-bottom-left-radius:0;border-top-left-radius:0}.input-group-addon:last-child{border-left:0}.input-group-btn{position:relative;font-size:0;white-space:nowrap}.input-group-btn>.btn{position:relative}.input-group-btn>.btn+.btn{margin-left:-1px}.input-group-btn>.btn:hover,.input-group-btn>.btn:focus,.input-group-btn>.btn:active{z-index:2}.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group{margin-right:-1px}.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group{margin-left:-1px}.nav{margin-bottom:0;padding-left:0;list-style:none}.nav>li{position:relative;display:block}.nav>li>a{position:relative;display:block;padding:10px 15px}.nav>li>a:hover,.nav>li>a:focus{text-decoration:none;background-color:#eee}.nav>li.disabled>a{color:#999}.nav>li.disabled>a:hover,.nav>li.disabled>a:focus{color:#999;text-decoration:none;background-color:transparent;cursor:not-allowed}.nav .open>a,.nav .open>a:hover,.nav .open>a:focus{background-color:#eee;border-color:#428bca}.nav .nav-divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.nav>li>a>img{max-width:none}.nav-tabs{border-bottom:1px solid #ddd}.nav-tabs>li{float:left;margin-bottom:-1px}.nav-tabs>li>a{margin-right:2px;line-height:1.42857143;border:1px solid transparent;border-radius:4px 4px 0 0}.nav-tabs>li>a:hover{border-color:#eee #eee #ddd}.nav-tabs>li.active>a,.nav-tabs>li.active>a:hover,.nav-tabs>li.active>a:focus{color:#555;background-color:#fff;border:1px solid #ddd;border-bottom-color:transparent;cursor:default}.nav-tabs.nav-justified{width:100%;border-bottom:0}.nav-tabs.nav-justified>li{float:none}.nav-tabs.nav-justified>li>a{text-align:center;margin-bottom:5px}.nav-tabs.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-tabs.nav-justified>li{display:table-cell;width:1%}.nav-tabs.nav-justified>li>a{margin-bottom:0}}.nav-tabs.nav-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:hover,.nav-tabs.nav-justified>.active>a:focus{border:1px solid #ddd}@media (min-width:768px){.nav-tabs.nav-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:hover,.nav-tabs.nav-justified>.active>a:focus{border-bottom-color:#fff}}.nav-pills>li{float:left}.nav-pills>li>a{border-radius:4px}.nav-pills>li+li{margin-left:2px}.nav-pills>li.active>a,.nav-pills>li.active>a:hover,.nav-pills>li.active>a:focus{color:#fff;background-color:#428bca}.nav-stacked>li{float:none}.nav-stacked>li+li{margin-top:2px;margin-left:0}.nav-justified{width:100%}.nav-justified>li{float:none}.nav-justified>li>a{text-align:center;margin-bottom:5px}.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-justified>li{display:table-cell;width:1%}.nav-justified>li>a{margin-bottom:0}}.nav-tabs-justified{border-bottom:0}.nav-tabs-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:hover,.nav-tabs-justified>.active>a:focus{border:1px solid #ddd}@media (min-width:768px){.nav-tabs-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:hover,.nav-tabs-justified>.active>a:focus{border-bottom-color:#fff}}.tab-content>.tab-pane{display:none}.tab-content>.active{display:block}.nav-tabs .dropdown-menu{margin-top:-1px;border-top-right-radius:0;border-top-left-radius:0}.navbar{position:relative;min-height:50px;margin-bottom:20px;border:1px solid transparent}@media (min-width:768px){.navbar{border-radius:4px}}@media (min-width:768px){.navbar-header{float:left}}.navbar-collapse{max-height:340px;overflow-x:visible;padding-right:15px;padding-left:15px;border-top:1px solid transparent;box-shadow:inset 0 1px 0 rgba(255,255,255,.1);-webkit-overflow-scrolling:touch}.navbar-collapse.in{overflow-y:auto}@media (min-width:768px){.navbar-collapse{width:auto;border-top:0;box-shadow:none}.navbar-collapse.collapse{display:block!important;height:auto!important;padding-bottom:0;overflow:visible!important}.navbar-collapse.in{overflow-y:visible}.navbar-fixed-top .navbar-collapse,.navbar-static-top .navbar-collapse,.navbar-fixed-bottom .navbar-collapse{padding-left:0;padding-right:0}}.container>.navbar-header,.container-fluid>.navbar-header,.container>.navbar-collapse,.container-fluid>.navbar-collapse{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.container>.navbar-header,.container-fluid>.navbar-header,.container>.navbar-collapse,.container-fluid>.navbar-collapse{margin-right:0;margin-left:0}}.navbar-static-top{z-index:1000;border-width:0 0 1px}@media (min-width:768px){.navbar-static-top{border-radius:0}}.navbar-fixed-top,.navbar-fixed-bottom{position:fixed;right:0;left:0;z-index:1030}@media (min-width:768px){.navbar-fixed-top,.navbar-fixed-bottom{border-radius:0}}.navbar-fixed-top{top:0;border-width:0 0 1px}.navbar-fixed-bottom{bottom:0;margin-bottom:0;border-width:1px 0 0}.navbar-brand{float:left;padding:15px;font-size:18px;line-height:20px;height:50px}.navbar-brand:hover,.navbar-brand:focus{text-decoration:none}@media (min-width:768px){.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand{margin-left:-15px}}.navbar-toggle{position:relative;float:right;margin-right:15px;padding:9px 10px;margin-top:8px;margin-bottom:8px;background-color:transparent;background-image:none;border:1px solid transparent;border-radius:4px}.navbar-toggle:focus{outline:0}.navbar-toggle .icon-bar{display:block;width:22px;height:2px;border-radius:1px}.navbar-toggle .icon-bar+.icon-bar{margin-top:4px}@media (min-width:768px){.navbar-toggle{display:none}}.navbar-nav{margin:7.5px -15px}.navbar-nav>li>a{padding-top:10px;padding-bottom:10px;line-height:20px}@media (max-width:767px){.navbar-nav .open .dropdown-menu{position:static;float:none;width:auto;margin-top:0;background-color:transparent;border:0;box-shadow:none}.navbar-nav .open .dropdown-menu>li>a,.navbar-nav .open .dropdown-menu .dropdown-header{padding:5px 15px 5px 25px}.navbar-nav .open .dropdown-menu>li>a{line-height:20px}.navbar-nav .open .dropdown-menu>li>a:hover,.navbar-nav .open .dropdown-menu>li>a:focus{background-image:none}}@media (min-width:768px){.navbar-nav{float:left;margin:0}.navbar-nav>li{float:left}.navbar-nav>li>a{padding-top:15px;padding-bottom:15px}.navbar-nav.navbar-right:last-child{margin-right:-15px}}@media (min-width:768px){.navbar-left{float:left!important}.navbar-right{float:right!important}}.navbar-form{margin-left:-15px;margin-right:-15px;padding:10px 15px;border-top:1px solid transparent;border-bottom:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);margin-top:8px;margin-bottom:8px}@media (min-width:768px){.navbar-form .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.navbar-form .form-control{display:inline-block;width:auto;vertical-align:middle}.navbar-form .input-group>.form-control{width:100%}.navbar-form .control-label{margin-bottom:0;vertical-align:middle}.navbar-form .radio,.navbar-form .checkbox{display:inline-block;margin-top:0;margin-bottom:0;padding-left:0;vertical-align:middle}.navbar-form .radio input[type=radio],.navbar-form .checkbox input[type=checkbox]{float:none;margin-left:0}.navbar-form .has-feedback .form-control-feedback{top:0}}@media (max-width:767px){.navbar-form .form-group{margin-bottom:5px}}@media (min-width:768px){.navbar-form{width:auto;border:0;margin-left:0;margin-right:0;padding-top:0;padding-bottom:0;-webkit-box-shadow:none;box-shadow:none}.navbar-form.navbar-right:last-child{margin-right:-15px}}.navbar-nav>li>.dropdown-menu{margin-top:0;border-top-right-radius:0;border-top-left-radius:0}.navbar-fixed-bottom .navbar-nav>li>.dropdown-menu{border-bottom-right-radius:0;border-bottom-left-radius:0}.navbar-btn{margin-top:8px;margin-bottom:8px}.navbar-btn.btn-sm{margin-top:10px;margin-bottom:10px}.navbar-btn.btn-xs{margin-top:14px;margin-bottom:14px}.navbar-text{margin-top:15px;margin-bottom:15px}@media (min-width:768px){.navbar-text{float:left;margin-left:15px;margin-right:15px}.navbar-text.navbar-right:last-child{margin-right:0}}.navbar-default{background-color:#f8f8f8;border-color:#e7e7e7}.navbar-default .navbar-brand{color:#777}.navbar-default .navbar-brand:hover,.navbar-default .navbar-brand:focus{color:#5e5e5e;background-color:transparent}.navbar-default .navbar-text{color:#777}.navbar-default .navbar-nav>li>a{color:#777}.navbar-default .navbar-nav>li>a:hover,.navbar-default .navbar-nav>li>a:focus{color:#333;background-color:transparent}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.active>a:hover,.navbar-default .navbar-nav>.active>a:focus{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav>.disabled>a,.navbar-default .navbar-nav>.disabled>a:hover,.navbar-default .navbar-nav>.disabled>a:focus{color:#ccc;background-color:transparent}.navbar-default .navbar-toggle{border-color:#ddd}.navbar-default .navbar-toggle:hover,.navbar-default .navbar-toggle:focus{background-color:#ddd}.navbar-default .navbar-toggle .icon-bar{background-color:#888}.navbar-default .navbar-collapse,.navbar-default .navbar-form{border-color:#e7e7e7}.navbar-default .navbar-nav>.open>a,.navbar-default .navbar-nav>.open>a:hover,.navbar-default .navbar-nav>.open>a:focus{background-color:#e7e7e7;color:#555}@media (max-width:767px){.navbar-default .navbar-nav .open .dropdown-menu>li>a{color:#777}.navbar-default .navbar-nav .open .dropdown-menu>li>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>li>a:focus{color:#333;background-color:transparent}.navbar-default .navbar-nav .open .dropdown-menu>.active>a,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:focus{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:focus{color:#ccc;background-color:transparent}}.navbar-default .navbar-link{color:#777}.navbar-default .navbar-link:hover{color:#333}.navbar-inverse{background-color:#222;border-color:#080808}.navbar-inverse .navbar-brand{color:#999}.navbar-inverse .navbar-brand:hover,.navbar-inverse .navbar-brand:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-text{color:#999}.navbar-inverse .navbar-nav>li>a{color:#999}.navbar-inverse .navbar-nav>li>a:hover,.navbar-inverse .navbar-nav>li>a:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.active>a:hover,.navbar-inverse .navbar-nav>.active>a:focus{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav>.disabled>a,.navbar-inverse .navbar-nav>.disabled>a:hover,.navbar-inverse .navbar-nav>.disabled>a:focus{color:#444;background-color:transparent}.navbar-inverse .navbar-toggle{border-color:#333}.navbar-inverse .navbar-toggle:hover,.navbar-inverse .navbar-toggle:focus{background-color:#333}.navbar-inverse .navbar-toggle .icon-bar{background-color:#fff}.navbar-inverse .navbar-collapse,.navbar-inverse .navbar-form{border-color:#101010}.navbar-inverse .navbar-nav>.open>a,.navbar-inverse .navbar-nav>.open>a:hover,.navbar-inverse .navbar-nav>.open>a:focus{background-color:#080808;color:#fff}@media (max-width:767px){.navbar-inverse .navbar-nav .open .dropdown-menu>.dropdown-header{border-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu .divider{background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a{color:#999}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:focus{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:focus{color:#444;background-color:transparent}}.navbar-inverse .navbar-link{color:#999}.navbar-inverse .navbar-link:hover{color:#fff}.breadcrumb{padding:8px 15px;margin-bottom:20px;list-style:none;background-color:#f5f5f5;border-radius:4px}.breadcrumb>li{display:inline-block}.breadcrumb>li+li:before{content:"/\00a0";padding:0 5px;color:#ccc}.breadcrumb>.active{color:#999}.pagination{display:inline-block;padding-left:0;margin:20px 0;border-radius:4px}.pagination>li{display:inline}.pagination>li>a,.pagination>li>span{position:relative;float:left;padding:6px 12px;line-height:1.42857143;text-decoration:none;color:#428bca;background-color:#fff;border:1px solid #ddd;margin-left:-1px}.pagination>li:first-child>a,.pagination>li:first-child>span{margin-left:0;border-bottom-left-radius:4px;border-top-left-radius:4px}.pagination>li:last-child>a,.pagination>li:last-child>span{border-bottom-right-radius:4px;border-top-right-radius:4px}.pagination>li>a:hover,.pagination>li>span:hover,.pagination>li>a:focus,.pagination>li>span:focus{color:#2a6496;background-color:#eee;border-color:#ddd}.pagination>.active>a,.pagination>.active>span,.pagination>.active>a:hover,.pagination>.active>span:hover,.pagination>.active>a:focus,.pagination>.active>span:focus{z-index:2;color:#fff;background-color:#428bca;border-color:#428bca;cursor:default}.pagination>.disabled>span,.pagination>.disabled>span:hover,.pagination>.disabled>span:focus,.pagination>.disabled>a,.pagination>.disabled>a:hover,.pagination>.disabled>a:focus{color:#999;background-color:#fff;border-color:#ddd;cursor:not-allowed}.pagination-lg>li>a,.pagination-lg>li>span{padding:10px 16px;font-size:18px}.pagination-lg>li:first-child>a,.pagination-lg>li:first-child>span{border-bottom-left-radius:6px;border-top-left-radius:6px}.pagination-lg>li:last-child>a,.pagination-lg>li:last-child>span{border-bottom-right-radius:6px;border-top-right-radius:6px}.pagination-sm>li>a,.pagination-sm>li>span{padding:5px 10px;font-size:12px}.pagination-sm>li:first-child>a,.pagination-sm>li:first-child>span{border-bottom-left-radius:3px;border-top-left-radius:3px}.pagination-sm>li:last-child>a,.pagination-sm>li:last-child>span{border-bottom-right-radius:3px;border-top-right-radius:3px}.pager{padding-left:0;margin:20px 0;list-style:none;text-align:center}.pager li{display:inline}.pager li>a,.pager li>span{display:inline-block;padding:5px 14px;background-color:#fff;border:1px solid #ddd;border-radius:15px}.pager li>a:hover,.pager li>a:focus{text-decoration:none;background-color:#eee}.pager .next>a,.pager .next>span{float:right}.pager .previous>a,.pager .previous>span{float:left}.pager .disabled>a,.pager .disabled>a:hover,.pager .disabled>a:focus,.pager .disabled>span{color:#999;background-color:#fff;cursor:not-allowed}.label{display:inline;padding:.2em .6em .3em;font-size:75%;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.25em}.label[href]:hover,.label[href]:focus{color:#fff;text-decoration:none;cursor:pointer}.label:empty{display:none}.btn .label{position:relative;top:-1px}.label-default{background-color:#999}.label-default[href]:hover,.label-default[href]:focus{background-color:gray}.label-primary{background-color:#428bca}.label-primary[href]:hover,.label-primary[href]:focus{background-color:#3071a9}.label-success{background-color:#5cb85c}.label-success[href]:hover,.label-success[href]:focus{background-color:#449d44}.label-info{background-color:#5bc0de}.label-info[href]:hover,.label-info[href]:focus{background-color:#31b0d5}.label-warning{background-color:#f0ad4e}.label-warning[href]:hover,.label-warning[href]:focus{background-color:#ec971f}.label-danger{background-color:#d9534f}.label-danger[href]:hover,.label-danger[href]:focus{background-color:#c9302c}.badge{display:inline-block;min-width:10px;padding:3px 7px;font-size:12px;font-weight:700;color:#fff;line-height:1;vertical-align:baseline;white-space:nowrap;text-align:center;background-color:#999;border-radius:10px}.badge:empty{display:none}.btn .badge{position:relative;top:-1px}.btn-xs .badge{top:0;padding:1px 5px}a.badge:hover,a.badge:focus{color:#fff;text-decoration:none;cursor:pointer}a.list-group-item.active>.badge,.nav-pills>.active>a>.badge{color:#428bca;background-color:#fff}.nav-pills>li>a>.badge{margin-left:3px}.jumbotron{padding:30px;margin-bottom:30px;color:inherit;background-color:#eee}.jumbotron h1,.jumbotron .h1{color:inherit}.jumbotron p{margin-bottom:15px;font-size:21px;font-weight:200}.container .jumbotron{border-radius:6px}.jumbotron .container{max-width:100%}@media screen and (min-width:768px){.jumbotron{padding-top:48px;padding-bottom:48px}.container .jumbotron{padding-left:60px;padding-right:60px}.jumbotron h1,.jumbotron .h1{font-size:63px}}.thumbnail{display:block;padding:4px;margin-bottom:20px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.thumbnail>img,.thumbnail a>img{margin-left:auto;margin-right:auto}a.thumbnail:hover,a.thumbnail:focus,a.thumbnail.active{border-color:#428bca}.thumbnail .caption{padding:9px;color:#333}.alert{padding:15px;margin-bottom:20px;border:1px solid transparent;border-radius:4px}.alert h4{margin-top:0;color:inherit}.alert .alert-link{font-weight:700}.alert>p,.alert>ul{margin-bottom:0}.alert>p+p{margin-top:5px}.alert-dismissable{padding-right:35px}.alert-dismissable .close{position:relative;top:-2px;right:-21px;color:inherit}.alert-success{background-color:#dff0d8;border-color:#d6e9c6;color:#3c763d}.alert-success hr{border-top-color:#c9e2b3}.alert-success .alert-link{color:#2b542c}.alert-info{background-color:#d9edf7;border-color:#bce8f1;color:#31708f}.alert-info hr{border-top-color:#a6e1ec}.alert-info .alert-link{color:#245269}.alert-warning{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}.alert-warning hr{border-top-color:#f7e1b5}.alert-warning .alert-link{color:#66512c}.alert-danger{background-color:#f2dede;border-color:#ebccd1;color:#a94442}.alert-danger hr{border-top-color:#e4b9c0}.alert-danger .alert-link{color:#843534}@-webkit-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}.progress{overflow:hidden;height:20px;margin-bottom:20px;background-color:#f5f5f5;border-radius:4px;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.progress-bar{float:left;width:0;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;background-color:#428bca;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);-webkit-transition:width .6s ease;transition:width .6s ease}.progress-striped .progress-bar{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-size:40px 40px}.progress.active .progress-bar{-webkit-animation:progress-bar-stripes 2s linear infinite;animation:progress-bar-stripes 2s linear infinite}.progress-bar-success{background-color:#5cb85c}.progress-striped .progress-bar-success{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-info{background-color:#5bc0de}.progress-striped .progress-bar-info{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-warning{background-color:#f0ad4e}.progress-striped .progress-bar-warning{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-danger{background-color:#d9534f}.progress-striped .progress-bar-danger{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.media,.media-body{overflow:hidden;zoom:1}.media,.media .media{margin-top:15px}.media:first-child{margin-top:0}.media-object{display:block}.media-heading{margin:0 0 5px}.media>.pull-left{margin-right:10px}.media>.pull-right{margin-left:10px}.media-list{padding-left:0;list-style:none}.list-group{margin-bottom:20px;padding-left:0}.list-group-item{position:relative;display:block;padding:10px 15px;margin-bottom:-1px;background-color:#fff;border:1px solid #ddd}.list-group-item:first-child{border-top-right-radius:4px;border-top-left-radius:4px}.list-group-item:last-child{margin-bottom:0;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.list-group-item>.badge{float:right}.list-group-item>.badge+.badge{margin-right:5px}a.list-group-item{color:#555}a.list-group-item .list-group-item-heading{color:#333}a.list-group-item:hover,a.list-group-item:focus{text-decoration:none;background-color:#f5f5f5}a.list-group-item.active,a.list-group-item.active:hover,a.list-group-item.active:focus{z-index:2;color:#fff;background-color:#428bca;border-color:#428bca}a.list-group-item.active .list-group-item-heading,a.list-group-item.active:hover .list-group-item-heading,a.list-group-item.active:focus .list-group-item-heading{color:inherit}a.list-group-item.active .list-group-item-text,a.list-group-item.active:hover .list-group-item-text,a.list-group-item.active:focus .list-group-item-text{color:#e1edf7}.list-group-item-success{color:#3c763d;background-color:#dff0d8}a.list-group-item-success{color:#3c763d}a.list-group-item-success .list-group-item-heading{color:inherit}a.list-group-item-success:hover,a.list-group-item-success:focus{color:#3c763d;background-color:#d0e9c6}a.list-group-item-success.active,a.list-group-item-success.active:hover,a.list-group-item-success.active:focus{color:#fff;background-color:#3c763d;border-color:#3c763d}.list-group-item-info{color:#31708f;background-color:#d9edf7}a.list-group-item-info{color:#31708f}a.list-group-item-info .list-group-item-heading{color:inherit}a.list-group-item-info:hover,a.list-group-item-info:focus{color:#31708f;background-color:#c4e3f3}a.list-group-item-info.active,a.list-group-item-info.active:hover,a.list-group-item-info.active:focus{color:#fff;background-color:#31708f;border-color:#31708f}.list-group-item-warning{color:#8a6d3b;background-color:#fcf8e3}a.list-group-item-warning{color:#8a6d3b}a.list-group-item-warning .list-group-item-heading{color:inherit}a.list-group-item-warning:hover,a.list-group-item-warning:focus{color:#8a6d3b;background-color:#faf2cc}a.list-group-item-warning.active,a.list-group-item-warning.active:hover,a.list-group-item-warning.active:focus{color:#fff;background-color:#8a6d3b;border-color:#8a6d3b}.list-group-item-danger{color:#a94442;background-color:#f2dede}a.list-group-item-danger{color:#a94442}a.list-group-item-danger .list-group-item-heading{color:inherit}a.list-group-item-danger:hover,a.list-group-item-danger:focus{color:#a94442;background-color:#ebcccc}a.list-group-item-danger.active,a.list-group-item-danger.active:hover,a.list-group-item-danger.active:focus{color:#fff;background-color:#a94442;border-color:#a94442}.list-group-item-heading{margin-top:0;margin-bottom:5px}.list-group-item-text{margin-bottom:0;line-height:1.3}.panel{margin-bottom:20px;background-color:#fff;border:1px solid transparent;border-radius:4px;-webkit-box-shadow:0 1px 1px rgba(0,0,0,.05);box-shadow:0 1px 1px rgba(0,0,0,.05)}.panel-body{padding:15px}.panel-heading{padding:10px 15px;border-bottom:1px solid transparent;border-top-right-radius:3px;border-top-left-radius:3px}.panel-heading>.dropdown .dropdown-toggle{color:inherit}.panel-title{margin-top:0;margin-bottom:0;font-size:16px;color:inherit}.panel-title>a{color:inherit}.panel-footer{padding:10px 15px;background-color:#f5f5f5;border-top:1px solid #ddd;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.list-group{margin-bottom:0}.panel>.list-group .list-group-item{border-width:1px 0;border-radius:0}.panel>.list-group:first-child .list-group-item:first-child{border-top:0;border-top-right-radius:3px;border-top-left-radius:3px}.panel>.list-group:last-child .list-group-item:last-child{border-bottom:0;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel-heading+.list-group .list-group-item:first-child{border-top-width:0}.panel>.table,.panel>.table-responsive>.table{margin-bottom:0}.panel>.table:first-child,.panel>.table-responsive:first-child>.table:first-child{border-top-right-radius:3px;border-top-left-radius:3px}.panel>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table:first-child>thead:first-child>tr:first-child th:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:first-child{border-top-left-radius:3px}.panel>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table:first-child>thead:first-child>tr:first-child th:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:last-child{border-top-right-radius:3px}.panel>.table:last-child,.panel>.table-responsive:last-child>.table:last-child{border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:first-child{border-bottom-left-radius:3px}.panel>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:last-child{border-bottom-right-radius:3px}.panel>.panel-body+.table,.panel>.panel-body+.table-responsive{border-top:1px solid #ddd}.panel>.table>tbody:first-child>tr:first-child th,.panel>.table>tbody:first-child>tr:first-child td{border-top:0}.panel>.table-bordered,.panel>.table-responsive>.table-bordered{border:0}.panel>.table-bordered>thead>tr>th:first-child,.panel>.table-responsive>.table-bordered>thead>tr>th:first-child,.panel>.table-bordered>tbody>tr>th:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:first-child,.panel>.table-bordered>tfoot>tr>th:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:first-child,.panel>.table-bordered>thead>tr>td:first-child,.panel>.table-responsive>.table-bordered>thead>tr>td:first-child,.panel>.table-bordered>tbody>tr>td:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:first-child,.panel>.table-bordered>tfoot>tr>td:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:first-child{border-left:0}.panel>.table-bordered>thead>tr>th:last-child,.panel>.table-responsive>.table-bordered>thead>tr>th:last-child,.panel>.table-bordered>tbody>tr>th:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:last-child,.panel>.table-bordered>tfoot>tr>th:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:last-child,.panel>.table-bordered>thead>tr>td:last-child,.panel>.table-responsive>.table-bordered>thead>tr>td:last-child,.panel>.table-bordered>tbody>tr>td:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:last-child,.panel>.table-bordered>tfoot>tr>td:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:last-child{border-right:0}.panel>.table-bordered>thead>tr:first-child>td,.panel>.table-responsive>.table-bordered>thead>tr:first-child>td,.panel>.table-bordered>tbody>tr:first-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>td,.panel>.table-bordered>thead>tr:first-child>th,.panel>.table-responsive>.table-bordered>thead>tr:first-child>th,.panel>.table-bordered>tbody>tr:first-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>th{border-bottom:0}.panel>.table-bordered>tbody>tr:last-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>td,.panel>.table-bordered>tfoot>tr:last-child>td,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>td,.panel>.table-bordered>tbody>tr:last-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>th,.panel>.table-bordered>tfoot>tr:last-child>th,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>th{border-bottom:0}.panel>.table-responsive{border:0;margin-bottom:0}.panel-group{margin-bottom:20px}.panel-group .panel{margin-bottom:0;border-radius:4px;overflow:hidden}.panel-group .panel+.panel{margin-top:5px}.panel-group .panel-heading{border-bottom:0}.panel-group .panel-heading+.panel-collapse .panel-body{border-top:1px solid #ddd}.panel-group .panel-footer{border-top:0}.panel-group .panel-footer+.panel-collapse .panel-body{border-bottom:1px solid #ddd}.panel-default{border-color:#ddd}.panel-default>.panel-heading{color:#333;background-color:#f5f5f5;border-color:#ddd}.panel-default>.panel-heading+.panel-collapse .panel-body{border-top-color:#ddd}.panel-default>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#ddd}.panel-primary{border-color:#428bca}.panel-primary>.panel-heading{color:#fff;background-color:#428bca;border-color:#428bca}.panel-primary>.panel-heading+.panel-collapse .panel-body{border-top-color:#428bca}.panel-primary>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#428bca}.panel-success{border-color:#d6e9c6}.panel-success>.panel-heading{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.panel-success>.panel-heading+.panel-collapse .panel-body{border-top-color:#d6e9c6}.panel-success>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#d6e9c6}.panel-info{border-color:#bce8f1}.panel-info>.panel-heading{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.panel-info>.panel-heading+.panel-collapse .panel-body{border-top-color:#bce8f1}.panel-info>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#bce8f1}.panel-warning{border-color:#faebcc}.panel-warning>.panel-heading{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.panel-warning>.panel-heading+.panel-collapse .panel-body{border-top-color:#faebcc}.panel-warning>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#faebcc}.panel-danger{border-color:#ebccd1}.panel-danger>.panel-heading{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.panel-danger>.panel-heading+.panel-collapse .panel-body{border-top-color:#ebccd1}.panel-danger>.panel-footer+.panel-collapse .panel-body{border-bottom-color:#ebccd1}.well{min-height:20px;padding:19px;margin-bottom:20px;background-color:#f5f5f5;border:1px solid #e3e3e3;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.05);box-shadow:inset 0 1px 1px rgba(0,0,0,.05)}.well blockquote{border-color:#ddd;border-color:rgba(0,0,0,.15)}.well-lg{padding:24px;border-radius:6px}.well-sm{padding:9px;border-radius:3px}.close{float:right;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;opacity:.2;filter:alpha(opacity=20)}.close:hover,.close:focus{color:#000;text-decoration:none;cursor:pointer;opacity:.5;filter:alpha(opacity=50)}button.close{padding:0;cursor:pointer;background:0 0;border:0;-webkit-appearance:none}.modal-open{overflow:hidden}.modal{display:none;overflow:auto;overflow-y:scroll;position:fixed;top:0;right:0;bottom:0;left:0;z-index:1050;-webkit-overflow-scrolling:touch;outline:0}.modal.fade .modal-dialog{-webkit-transform:translate(0,-25%);-ms-transform:translate(0,-25%);transform:translate(0,-25%);-webkit-transition:-webkit-transform .3s ease-out;-moz-transition:-moz-transform .3s ease-out;-o-transition:-o-transform .3s ease-out;transition:transform .3s ease-out}.modal.in .modal-dialog{-webkit-transform:translate(0,0);-ms-transform:translate(0,0);transform:translate(0,0)}.modal-dialog{position:relative;width:auto;margin:10px}.modal-content{position:relative;background-color:#fff;border:1px solid #999;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 3px 9px rgba(0,0,0,.5);box-shadow:0 3px 9px rgba(0,0,0,.5);background-clip:padding-box;outline:0}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1040;background-color:#000}.modal-backdrop.fade{opacity:0;filter:alpha(opacity=0)}.modal-backdrop.in{opacity:.5;filter:alpha(opacity=50)}.modal-header{padding:15px;border-bottom:1px solid #e5e5e5;min-height:16.42857143px}.modal-header .close{margin-top:-2px}.modal-title{margin:0;line-height:1.42857143}.modal-body{position:relative;padding:20px}.modal-footer{margin-top:15px;padding:19px 20px 20px;text-align:right;border-top:1px solid #e5e5e5}.modal-footer .btn+.btn{margin-left:5px;margin-bottom:0}.modal-footer .btn-group .btn+.btn{margin-left:-1px}.modal-footer .btn-block+.btn-block{margin-left:0}@media (min-width:768px){.modal-dialog{width:600px;margin:30px auto}.modal-content{-webkit-box-shadow:0 5px 15px rgba(0,0,0,.5);box-shadow:0 5px 15px rgba(0,0,0,.5)}.modal-sm{width:300px}}@media (min-width:992px){.modal-lg{width:900px}}.tooltip{position:absolute;z-index:1030;display:block;visibility:visible;font-size:12px;line-height:1.4;opacity:0;filter:alpha(opacity=0)}.tooltip.in{opacity:.9;filter:alpha(opacity=90)}.tooltip.top{margin-top:-3px;padding:5px 0}.tooltip.right{margin-left:3px;padding:0 5px}.tooltip.bottom{margin-top:3px;padding:5px 0}.tooltip.left{margin-left:-3px;padding:0 5px}.tooltip-inner{max-width:200px;padding:3px 8px;color:#fff;text-align:center;text-decoration:none;background-color:#000;border-radius:4px}.tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.tooltip.top .tooltip-arrow{bottom:0;left:50%;margin-left:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-left .tooltip-arrow{bottom:0;left:5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-right .tooltip-arrow{bottom:0;right:5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.right .tooltip-arrow{top:50%;left:0;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#000}.tooltip.left .tooltip-arrow{top:50%;right:0;margin-top:-5px;border-width:5px 0 5px 5px;border-left-color:#000}.tooltip.bottom .tooltip-arrow{top:0;left:50%;margin-left:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-left .tooltip-arrow{top:0;left:5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-right .tooltip-arrow{top:0;right:5px;border-width:0 5px 5px;border-bottom-color:#000}.popover{position:absolute;top:0;left:0;z-index:1010;display:none;max-width:276px;padding:1px;text-align:left;background-color:#fff;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2);white-space:normal}.popover.top{margin-top:-10px}.popover.right{margin-left:10px}.popover.bottom{margin-top:10px}.popover.left{margin-left:-10px}.popover-title{margin:0;padding:8px 14px;font-size:14px;font-weight:400;line-height:18px;background-color:#f7f7f7;border-bottom:1px solid #ebebeb;border-radius:5px 5px 0 0}.popover-content{padding:9px 14px}.popover>.arrow,.popover>.arrow:after{position:absolute;display:block;width:0;height:0;border-color:transparent;border-style:solid}.popover>.arrow{border-width:11px}.popover>.arrow:after{border-width:10px;content:""}.popover.top>.arrow{left:50%;margin-left:-11px;border-bottom-width:0;border-top-color:#999;border-top-color:rgba(0,0,0,.25);bottom:-11px}.popover.top>.arrow:after{content:" ";bottom:1px;margin-left:-10px;border-bottom-width:0;border-top-color:#fff}.popover.right>.arrow{top:50%;left:-11px;margin-top:-11px;border-left-width:0;border-right-color:#999;border-right-color:rgba(0,0,0,.25)}.popover.right>.arrow:after{content:" ";left:1px;bottom:-10px;border-left-width:0;border-right-color:#fff}.popover.bottom>.arrow{left:50%;margin-left:-11px;border-top-width:0;border-bottom-color:#999;border-bottom-color:rgba(0,0,0,.25);top:-11px}.popover.bottom>.arrow:after{content:" ";top:1px;margin-left:-10px;border-top-width:0;border-bottom-color:#fff}.popover.left>.arrow{top:50%;right:-11px;margin-top:-11px;border-right-width:0;border-left-color:#999;border-left-color:rgba(0,0,0,.25)}.popover.left>.arrow:after{content:" ";right:1px;border-right-width:0;border-left-color:#fff;bottom:-10px}.carousel{position:relative}.carousel-inner{position:relative;overflow:hidden;width:100%}.carousel-inner>.item{display:none;position:relative;-webkit-transition:.6s ease-in-out left;transition:.6s ease-in-out left}.carousel-inner>.item>img,.carousel-inner>.item>a>img{line-height:1}.carousel-inner>.active,.carousel-inner>.next,.carousel-inner>.prev{display:block}.carousel-inner>.active{left:0}.carousel-inner>.next,.carousel-inner>.prev{position:absolute;top:0;width:100%}.carousel-inner>.next{left:100%}.carousel-inner>.prev{left:-100%}.carousel-inner>.next.left,.carousel-inner>.prev.right{left:0}.carousel-inner>.active.left{left:-100%}.carousel-inner>.active.right{left:100%}.carousel-control{position:absolute;top:0;left:0;bottom:0;width:15%;opacity:.5;filter:alpha(opacity=50);font-size:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6)}.carousel-control.left{background-image:-webkit-linear-gradient(left,color-stop(rgba(0,0,0,.5) 0),color-stop(rgba(0,0,0,.0001) 100%));background-image:linear-gradient(to right,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1)}.carousel-control.right{left:auto;right:0;background-image:-webkit-linear-gradient(left,color-stop(rgba(0,0,0,.0001) 0),color-stop(rgba(0,0,0,.5) 100%));background-image:linear-gradient(to right,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1)}.carousel-control:hover,.carousel-control:focus{outline:0;color:#fff;text-decoration:none;opacity:.9;filter:alpha(opacity=90)}.carousel-control .icon-prev,.carousel-control .icon-next,.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right{position:absolute;top:50%;z-index:5;display:inline-block}.carousel-control .icon-prev,.carousel-control .glyphicon-chevron-left{left:50%}.carousel-control .icon-next,.carousel-control .glyphicon-chevron-right{right:50%}.carousel-control .icon-prev,.carousel-control .icon-next{width:20px;height:20px;margin-top:-10px;margin-left:-10px;font-family:serif}.carousel-control .icon-prev:before{content:'\2039'}.carousel-control .icon-next:before{content:'\203a'}.carousel-indicators{position:absolute;bottom:10px;left:50%;z-index:15;width:60%;margin-left:-30%;padding-left:0;list-style:none;text-align:center}.carousel-indicators li{display:inline-block;width:10px;height:10px;margin:1px;text-indent:-999px;border:1px solid #fff;border-radius:10px;cursor:pointer;background-color:#000 \9;background-color:rgba(0,0,0,0)}.carousel-indicators .active{margin:0;width:12px;height:12px;background-color:#fff}.carousel-caption{position:absolute;left:15%;right:15%;bottom:20px;z-index:10;padding-top:20px;padding-bottom:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6)}.carousel-caption .btn{text-shadow:none}@media screen and (min-width:768px){.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-prev,.carousel-control .icon-next{width:30px;height:30px;margin-top:-15px;margin-left:-15px;font-size:30px}.carousel-caption{left:20%;right:20%;padding-bottom:30px}.carousel-indicators{bottom:20px}}.clearfix:before,.clearfix:after,.container:before,.container:after,.container-fluid:before,.container-fluid:after,.row:before,.row:after,.form-horizontal .form-group:before,.form-horizontal .form-group:after,.btn-toolbar:before,.btn-toolbar:after,.btn-group-vertical>.btn-group:before,.btn-group-vertical>.btn-group:after,.nav:before,.nav:after,.navbar:before,.navbar:after,.navbar-header:before,.navbar-header:after,.navbar-collapse:before,.navbar-collapse:after,.pager:before,.pager:after,.panel-body:before,.panel-body:after,.modal-footer:before,.modal-footer:after{content:" ";display:table}.clearfix:after,.container:after,.container-fluid:after,.row:after,.form-horizontal .form-group:after,.btn-toolbar:after,.btn-group-vertical>.btn-group:after,.nav:after,.navbar:after,.navbar-header:after,.navbar-collapse:after,.pager:after,.panel-body:after,.modal-footer:after{clear:both}.center-block{display:block;margin-left:auto;margin-right:auto}.pull-right{float:right!important}.pull-left{float:left!important}.hide{display:none!important}.show{display:block!important}.invisible{visibility:hidden}.text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.hidden{display:none!important;visibility:hidden!important}.affix{position:fixed}@-ms-viewport{width:device-width}.visible-xs,.visible-sm,.visible-md,.visible-lg{display:none!important}@media (max-width:767px){.visible-xs{display:block!important}table.visible-xs{display:table}tr.visible-xs{display:table-row!important}th.visible-xs,td.visible-xs{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.visible-sm{display:block!important}table.visible-sm{display:table}tr.visible-sm{display:table-row!important}th.visible-sm,td.visible-sm{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.visible-md{display:block!important}table.visible-md{display:table}tr.visible-md{display:table-row!important}th.visible-md,td.visible-md{display:table-cell!important}}@media (min-width:1200px){.visible-lg{display:block!important}table.visible-lg{display:table}tr.visible-lg{display:table-row!important}th.visible-lg,td.visible-lg{display:table-cell!important}}@media (max-width:767px){.hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.hidden-md{display:none!important}}@media (min-width:1200px){.hidden-lg{display:none!important}}.visible-print{display:none!important}@media print{.visible-print{display:block!important}table.visible-print{display:table}tr.visible-print{display:table-row!important}th.visible-print,td.visible-print{display:table-cell!important}}@media print{.hidden-print{display:none!important}} 8 | 9 | 10 | /* Space out content a bit */ 11 | body { 12 | padding-top: 20px; 13 | padding-bottom: 20px; 14 | } 15 | 16 | /* Everything but the jumbotron gets side spacing for mobile first views */ 17 | .header, 18 | .marketing, 19 | .footer { 20 | padding-right: 15px; 21 | padding-left: 15px; 22 | } 23 | .logo { 24 | width: 519px; 25 | height: 71px; 26 | display: inline-block; 27 | margin-bottom: 1em; 28 | background-image: url("/images/phoenix.png"); 29 | background-size: 519px 71px; 30 | } 31 | /* Custom page header */ 32 | .header { 33 | border-bottom: 1px solid #e5e5e5; 34 | } 35 | /* Make the masthead heading the same height as the navigation */ 36 | .header h3 { 37 | padding-bottom: 19px; 38 | margin-top: 0; 39 | margin-bottom: 0; 40 | line-height: 40px; 41 | } 42 | 43 | /* Custom page footer */ 44 | .footer { 45 | padding-top: 19px; 46 | color: #777; 47 | border-top: 1px solid #e5e5e5; 48 | } 49 | 50 | /* Customize container */ 51 | @media (min-width: 768px) { 52 | .container { 53 | max-width: 730px; 54 | } 55 | } 56 | .container-narrow > hr { 57 | margin: 30px 0; 58 | } 59 | 60 | /* Main marketing message and sign up button */ 61 | .jumbotron { 62 | text-align: center; 63 | border-bottom: 1px solid #e5e5e5; 64 | } 65 | .jumbotron .btn { 66 | padding: 14px 24px; 67 | font-size: 21px; 68 | } 69 | 70 | /* Supporting marketing content */ 71 | .marketing { 72 | margin: 40px 0; 73 | } 74 | .marketing p + h4 { 75 | margin-top: 28px; 76 | } 77 | 78 | /* Responsive: Portrait tablets and up */ 79 | @media screen and (min-width: 768px) { 80 | /* Remove the padding we set earlier */ 81 | .header, 82 | .marketing, 83 | .footer { 84 | padding-right: 0; 85 | padding-left: 0; 86 | } 87 | /* Space out the masthead */ 88 | .header { 89 | margin-bottom: 30px; 90 | } 91 | /* Remove the bottom border on the jumbotron for visual effect */ 92 | .jumbotron { 93 | border-bottom: 0; 94 | } 95 | } 96 | -------------------------------------------------------------------------------- /phoenix/app/priv/static/images/phoenix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/phoenix/app/priv/static/images/phoenix.png -------------------------------------------------------------------------------- /phoenix/app/priv/static/js/phoenix.js: -------------------------------------------------------------------------------- 1 | (function(/*! Brunch !*/) { 2 | 'use strict'; 3 | 4 | var globals = typeof window !== 'undefined' ? window : global; 5 | if (typeof globals.require === 'function') return; 6 | 7 | var modules = {}; 8 | var cache = {}; 9 | 10 | var has = function(object, name) { 11 | return ({}).hasOwnProperty.call(object, name); 12 | }; 13 | 14 | var expand = function(root, name) { 15 | var results = [], parts, part; 16 | if (/^\.\.?(\/|$)/.test(name)) { 17 | parts = [root, name].join('/').split('/'); 18 | } else { 19 | parts = name.split('/'); 20 | } 21 | for (var i = 0, length = parts.length; i < length; i++) { 22 | part = parts[i]; 23 | if (part === '..') { 24 | results.pop(); 25 | } else if (part !== '.' && part !== '') { 26 | results.push(part); 27 | } 28 | } 29 | return results.join('/'); 30 | }; 31 | 32 | var dirname = function(path) { 33 | return path.split('/').slice(0, -1).join('/'); 34 | }; 35 | 36 | var localRequire = function(path) { 37 | return function(name) { 38 | var dir = dirname(path); 39 | var absolute = expand(dir, name); 40 | return globals.require(absolute, path); 41 | }; 42 | }; 43 | 44 | var initModule = function(name, definition) { 45 | var module = {id: name, exports: {}}; 46 | cache[name] = module; 47 | definition(module.exports, localRequire(name), module); 48 | return module.exports; 49 | }; 50 | 51 | var require = function(name, loaderPath) { 52 | var path = expand(name, '.'); 53 | if (loaderPath == null) loaderPath = '/'; 54 | 55 | if (has(cache, path)) return cache[path].exports; 56 | if (has(modules, path)) return initModule(path, modules[path]); 57 | 58 | var dirIndex = expand(path, './index'); 59 | if (has(cache, dirIndex)) return cache[dirIndex].exports; 60 | if (has(modules, dirIndex)) return initModule(dirIndex, modules[dirIndex]); 61 | 62 | throw new Error('Cannot find module "' + name + '" from '+ '"' + loaderPath + '"'); 63 | }; 64 | 65 | var define = function(bundle, fn) { 66 | if (typeof bundle === 'object') { 67 | for (var key in bundle) { 68 | if (has(bundle, key)) { 69 | modules[key] = bundle[key]; 70 | } 71 | } 72 | } else { 73 | modules[bundle] = fn; 74 | } 75 | }; 76 | 77 | var list = function() { 78 | var result = []; 79 | for (var item in modules) { 80 | if (has(modules, item)) { 81 | result.push(item); 82 | } 83 | } 84 | return result; 85 | }; 86 | 87 | globals.require = require; 88 | globals.require.define = define; 89 | globals.require.register = define; 90 | globals.require.list = list; 91 | globals.require.brunch = true; 92 | })(); 93 | require.define({'phoenix': function(exports, require, module){ "use strict"; 94 | 95 | var _prototypeProperties = function (child, staticProps, instanceProps) { if (staticProps) Object.defineProperties(child, staticProps); if (instanceProps) Object.defineProperties(child.prototype, instanceProps); }; 96 | 97 | var _classCallCheck = function (instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }; 98 | 99 | // Phoenix Channels JavaScript client 100 | // 101 | // ## Socket Connection 102 | // 103 | // A single connection is established to the server and 104 | // channels are mulitplexed over the connection. 105 | // Connect to the server using the `Socket` class: 106 | // 107 | // let socket = new Socket("/ws") 108 | // socket.connect() 109 | // 110 | // The `Socket` constructor takes the mount point of the socket 111 | // as well as options that can be found in the Socket docs, 112 | // such as configuring the `LongPoller` transport, and heartbeat. 113 | // 114 | // 115 | // ## Channels 116 | // 117 | // Channels are isolated, concurrent processes on the server that 118 | // subscribe to topics and broker events between the client and server. 119 | // To join a channel, you must provide the topic, and channel params for 120 | // authorization. Here's an example chat room example where `"new_msg"` 121 | // events are listened for, messages are pushed to the server, and 122 | // the channel is joined with ok/error matches, and `after` hook: 123 | // 124 | // let chan = socket.chan("rooms:123", {token: roomToken}) 125 | // chan.on("new_msg", msg => console.log("Got message", msg) ) 126 | // $input.onEnter( e => { 127 | // chan.push("new_msg", {body: e.target.val}) 128 | // .receive("ok", (message) => console.log("created message", message) ) 129 | // .receive("error", (reasons) => console.log("create failed", reasons) ) 130 | // .after(10000, () => console.log("Networking issue. Still waiting...") ) 131 | // }) 132 | // chan.join() 133 | // .receive("ok", ({messages}) => console.log("catching up", messages) ) 134 | // .receive("error", ({reason}) => console.log("failed join", reason) ) 135 | // .after(10000, () => console.log("Networking issue. Still waiting...") ) 136 | // 137 | // 138 | // ## Joining 139 | // 140 | // Joining a channel with `chan.join(topic, params)`, binds the params to 141 | // `chan.params`. Subsequent rejoins will send up the modified params for 142 | // updating authorization params, or passing up last_message_id information. 143 | // Successful joins receive an "ok" status, while unsuccessful joins 144 | // receive "error". 145 | // 146 | // 147 | // ## Pushing Messages 148 | // 149 | // From the prevoius example, we can see that pushing messages to the server 150 | // can be done with `chan.push(eventName, payload)` and we can optionally 151 | // receive responses from the push. Additionally, we can use 152 | // `after(millsec, callback)` to abort waiting for our `receive` hooks and 153 | // take action after some period of waiting. 154 | // 155 | // 156 | // ## Socket Hooks 157 | // 158 | // Lifecycle events of the multiplexed connection can be hooked into via 159 | // `socket.onError()` and `socket.onClose()` events, ie: 160 | // 161 | // socket.onError( () => console.log("there was an error with the connection!") ) 162 | // socket.onClose( () => console.log("the connection dropped") ) 163 | // 164 | // 165 | // ## Channel Hooks 166 | // 167 | // For each joined channel, you can bind to `onError` and `onClose` events 168 | // to monitor the channel lifecycle, ie: 169 | // 170 | // chan.onError( () => console.log("there was an error!") ) 171 | // chan.onClose( () => console.log("the channel has gone away gracefully") ) 172 | // 173 | // ### onError hooks 174 | // 175 | // `onError` hooks are invoked if the socket connection drops, or the channel 176 | // crashes on the server. In either case, a channel rejoin is attemtped 177 | // automatically in an exponential backoff manner. 178 | // 179 | // ### onClose hooks 180 | // 181 | // `onClose` hooks are invoked only in two cases. 1) the channel explicitly 182 | // closed on the server, or 2). The client explicitly closed, by calling 183 | // `chan.leave()` 184 | // 185 | 186 | var SOCKET_STATES = { connecting: 0, open: 1, closing: 2, closed: 3 }; 187 | var CHAN_STATES = { 188 | closed: "closed", 189 | errored: "errored", 190 | joined: "joined", 191 | joining: "joining" }; 192 | var CHAN_EVENTS = { 193 | close: "phx_close", 194 | error: "phx_error", 195 | join: "phx_join", 196 | reply: "phx_reply", 197 | leave: "phx_leave" 198 | }; 199 | 200 | var Push = (function () { 201 | 202 | // Initializes the Push 203 | // 204 | // chan - The Channel 205 | // event - The event, ie `"phx_join"` 206 | // payload - The payload, ie `{user_id: 123}` 207 | // 208 | 209 | function Push(chan, event, payload) { 210 | _classCallCheck(this, Push); 211 | 212 | this.chan = chan; 213 | this.event = event; 214 | this.payload = payload || {}; 215 | this.receivedResp = null; 216 | this.afterHook = null; 217 | this.recHooks = []; 218 | this.sent = false; 219 | } 220 | 221 | _prototypeProperties(Push, null, { 222 | send: { 223 | value: function send() { 224 | var _this = this; 225 | 226 | var ref = this.chan.socket.makeRef(); 227 | this.refEvent = this.chan.replyEventName(ref); 228 | this.receivedResp = null; 229 | this.sent = false; 230 | 231 | this.chan.on(this.refEvent, function (payload) { 232 | _this.receivedResp = payload; 233 | _this.matchReceive(payload); 234 | _this.cancelRefEvent(); 235 | _this.cancelAfter(); 236 | }); 237 | 238 | this.startAfter(); 239 | this.sent = true; 240 | this.chan.socket.push({ 241 | topic: this.chan.topic, 242 | event: this.event, 243 | payload: this.payload, 244 | ref: ref 245 | }); 246 | }, 247 | writable: true, 248 | configurable: true 249 | }, 250 | receive: { 251 | value: function receive(status, callback) { 252 | if (this.receivedResp && this.receivedResp.status === status) { 253 | callback(this.receivedResp.response); 254 | } 255 | 256 | this.recHooks.push({ status: status, callback: callback }); 257 | return this; 258 | }, 259 | writable: true, 260 | configurable: true 261 | }, 262 | after: { 263 | value: function after(ms, callback) { 264 | if (this.afterHook) { 265 | throw "only a single after hook can be applied to a push"; 266 | } 267 | var timer = null; 268 | if (this.sent) { 269 | timer = setTimeout(callback, ms); 270 | } 271 | this.afterHook = { ms: ms, callback: callback, timer: timer }; 272 | return this; 273 | }, 274 | writable: true, 275 | configurable: true 276 | }, 277 | matchReceive: { 278 | 279 | // private 280 | 281 | value: function matchReceive(_ref) { 282 | var status = _ref.status; 283 | var response = _ref.response; 284 | var ref = _ref.ref; 285 | 286 | this.recHooks.filter(function (h) { 287 | return h.status === status; 288 | }).forEach(function (h) { 289 | return h.callback(response); 290 | }); 291 | }, 292 | writable: true, 293 | configurable: true 294 | }, 295 | cancelRefEvent: { 296 | value: function cancelRefEvent() { 297 | this.chan.off(this.refEvent); 298 | }, 299 | writable: true, 300 | configurable: true 301 | }, 302 | cancelAfter: { 303 | value: function cancelAfter() { 304 | if (!this.afterHook) { 305 | return; 306 | } 307 | clearTimeout(this.afterHook.timer); 308 | this.afterHook.timer = null; 309 | }, 310 | writable: true, 311 | configurable: true 312 | }, 313 | startAfter: { 314 | value: function startAfter() { 315 | var _this = this; 316 | 317 | if (!this.afterHook) { 318 | return; 319 | } 320 | var callback = function () { 321 | _this.cancelRefEvent(); 322 | _this.afterHook.callback(); 323 | }; 324 | this.afterHook.timer = setTimeout(callback, this.afterHook.ms); 325 | }, 326 | writable: true, 327 | configurable: true 328 | } 329 | }); 330 | 331 | return Push; 332 | })(); 333 | 334 | var Channel = exports.Channel = (function () { 335 | function Channel(topic, params, socket) { 336 | var _this = this; 337 | 338 | _classCallCheck(this, Channel); 339 | 340 | this.state = CHAN_STATES.closed; 341 | this.topic = topic; 342 | this.params = params || {}; 343 | this.socket = socket; 344 | this.bindings = []; 345 | this.joinedOnce = false; 346 | this.joinPush = new Push(this, CHAN_EVENTS.join, this.params); 347 | this.pushBuffer = []; 348 | 349 | this.joinPush.receive("ok", function () { 350 | _this.state = CHAN_STATES.joined; 351 | }); 352 | this.onClose(function () { 353 | _this.state = CHAN_STATES.closed; 354 | _this.socket.remove(_this); 355 | }); 356 | this.onError(function (reason) { 357 | _this.state = CHAN_STATES.errored; 358 | setTimeout(function () { 359 | return _this.rejoinUntilConnected(); 360 | }, _this.socket.reconnectAfterMs); 361 | }); 362 | this.on(CHAN_EVENTS.reply, function (payload, ref) { 363 | _this.trigger(_this.replyEventName(ref), payload); 364 | }); 365 | } 366 | 367 | _prototypeProperties(Channel, null, { 368 | rejoinUntilConnected: { 369 | value: function rejoinUntilConnected() { 370 | var _this = this; 371 | 372 | if (this.state !== CHAN_STATES.errored) { 373 | return; 374 | } 375 | if (this.socket.isConnected()) { 376 | this.rejoin(); 377 | } else { 378 | setTimeout(function () { 379 | return _this.rejoinUntilConnected(); 380 | }, this.socket.reconnectAfterMs); 381 | } 382 | }, 383 | writable: true, 384 | configurable: true 385 | }, 386 | join: { 387 | value: function join() { 388 | if (this.joinedOnce) { 389 | throw "tried to join mulitple times. 'join' can only be called a singe time per channel instance"; 390 | } else { 391 | this.joinedOnce = true; 392 | } 393 | this.sendJoin(); 394 | return this.joinPush; 395 | }, 396 | writable: true, 397 | configurable: true 398 | }, 399 | onClose: { 400 | value: function onClose(callback) { 401 | this.on(CHAN_EVENTS.close, callback); 402 | }, 403 | writable: true, 404 | configurable: true 405 | }, 406 | onError: { 407 | value: function onError(callback) { 408 | this.on(CHAN_EVENTS.error, function (reason) { 409 | return callback(reason); 410 | }); 411 | }, 412 | writable: true, 413 | configurable: true 414 | }, 415 | on: { 416 | value: function on(event, callback) { 417 | this.bindings.push({ event: event, callback: callback }); 418 | }, 419 | writable: true, 420 | configurable: true 421 | }, 422 | off: { 423 | value: function off(event) { 424 | this.bindings = this.bindings.filter(function (bind) { 425 | return bind.event !== event; 426 | }); 427 | }, 428 | writable: true, 429 | configurable: true 430 | }, 431 | canPush: { 432 | value: function canPush() { 433 | return this.socket.isConnected() && this.state === CHAN_STATES.joined; 434 | }, 435 | writable: true, 436 | configurable: true 437 | }, 438 | push: { 439 | value: function push(event, payload) { 440 | if (!this.joinedOnce) { 441 | throw "tried to push '" + event + "' to '" + this.topic + "' before joining. Use chan.join() before pushing events"; 442 | } 443 | var pushEvent = new Push(this, event, payload); 444 | if (this.canPush()) { 445 | pushEvent.send(); 446 | } else { 447 | this.pushBuffer.push(pushEvent); 448 | } 449 | 450 | return pushEvent; 451 | }, 452 | writable: true, 453 | configurable: true 454 | }, 455 | leave: { 456 | 457 | // Leaves the channel 458 | // 459 | // Unsubscribes from server events, and 460 | // instructs channel to terminate on server 461 | // 462 | // Triggers onClose() hooks 463 | // 464 | // To receive leave acknowledgements, use the a `receive` 465 | // hook to bind to the server ack, ie: 466 | // 467 | // chan.leave().receive("ok", () => alert("left!") ) 468 | // 469 | 470 | value: function leave() { 471 | var _this = this; 472 | 473 | return this.push(CHAN_EVENTS.leave).receive("ok", function () { 474 | _this.trigger(CHAN_EVENTS.close, "leave"); 475 | }); 476 | }, 477 | writable: true, 478 | configurable: true 479 | }, 480 | isMember: { 481 | 482 | // private 483 | 484 | value: function isMember(topic) { 485 | return this.topic === topic; 486 | }, 487 | writable: true, 488 | configurable: true 489 | }, 490 | sendJoin: { 491 | value: function sendJoin() { 492 | this.state = CHAN_STATES.joining; 493 | this.joinPush.send(); 494 | }, 495 | writable: true, 496 | configurable: true 497 | }, 498 | rejoin: { 499 | value: function rejoin() { 500 | this.sendJoin(); 501 | this.pushBuffer.forEach(function (pushEvent) { 502 | return pushEvent.send(); 503 | }); 504 | this.pushBuffer = []; 505 | }, 506 | writable: true, 507 | configurable: true 508 | }, 509 | trigger: { 510 | value: function trigger(triggerEvent, payload, ref) { 511 | this.bindings.filter(function (bind) { 512 | return bind.event === triggerEvent; 513 | }).map(function (bind) { 514 | return bind.callback(payload, ref); 515 | }); 516 | }, 517 | writable: true, 518 | configurable: true 519 | }, 520 | replyEventName: { 521 | value: function replyEventName(ref) { 522 | return "chan_reply_" + ref; 523 | }, 524 | writable: true, 525 | configurable: true 526 | } 527 | }); 528 | 529 | return Channel; 530 | })(); 531 | 532 | var Socket = exports.Socket = (function () { 533 | 534 | // Initializes the Socket 535 | // 536 | // endPoint - The string WebSocket endpoint, ie, "ws://example.com/ws", 537 | // "wss://example.com" 538 | // "/ws" (inherited host & protocol) 539 | // opts - Optional configuration 540 | // transport - The Websocket Transport, ie WebSocket, Phoenix.LongPoller. 541 | // Defaults to WebSocket with automatic LongPoller fallback. 542 | // heartbeatIntervalMs - The millisec interval to send a heartbeat message 543 | // reconnectAfterMs - The millisec interval to reconnect after connection loss 544 | // logger - The optional function for specialized logging, ie: 545 | // `logger: function(msg){ console.log(msg) }` 546 | // longpoller_timeout - The maximum timeout of a long poll AJAX request. 547 | // Defaults to 20s (double the server long poll timer). 548 | // 549 | // For IE8 support use an ES5-shim (https://github.com/es-shims/es5-shim) 550 | // 551 | 552 | function Socket(endPoint) { 553 | var opts = arguments[1] === undefined ? {} : arguments[1]; 554 | 555 | _classCallCheck(this, Socket); 556 | 557 | this.stateChangeCallbacks = { open: [], close: [], error: [], message: [] }; 558 | this.reconnectTimer = null; 559 | this.channels = []; 560 | this.sendBuffer = []; 561 | this.ref = 0; 562 | this.transport = opts.transport || window.WebSocket || LongPoller; 563 | this.heartbeatIntervalMs = opts.heartbeatIntervalMs || 30000; 564 | this.reconnectAfterMs = opts.reconnectAfterMs || 5000; 565 | this.logger = opts.logger || function () {}; // noop 566 | this.longpoller_timeout = opts.longpoller_timeout || 20000; 567 | this.endPoint = this.expandEndpoint(endPoint); 568 | } 569 | 570 | _prototypeProperties(Socket, null, { 571 | protocol: { 572 | value: function protocol() { 573 | return location.protocol.match(/^https/) ? "wss" : "ws"; 574 | }, 575 | writable: true, 576 | configurable: true 577 | }, 578 | expandEndpoint: { 579 | value: function expandEndpoint(endPoint) { 580 | if (endPoint.charAt(0) !== "/") { 581 | return endPoint; 582 | } 583 | if (endPoint.charAt(1) === "/") { 584 | return "" + this.protocol() + ":" + endPoint; 585 | } 586 | 587 | return "" + this.protocol() + "://" + location.host + "" + endPoint; 588 | }, 589 | writable: true, 590 | configurable: true 591 | }, 592 | disconnect: { 593 | value: function disconnect(callback, code, reason) { 594 | if (this.conn) { 595 | this.conn.onclose = function () {}; // noop 596 | if (code) { 597 | this.conn.close(code, reason || ""); 598 | } else { 599 | this.conn.close(); 600 | } 601 | this.conn = null; 602 | } 603 | callback && callback(); 604 | }, 605 | writable: true, 606 | configurable: true 607 | }, 608 | connect: { 609 | value: function connect() { 610 | var _this = this; 611 | 612 | this.disconnect(function () { 613 | _this.conn = new _this.transport(_this.endPoint); 614 | _this.conn.timeout = _this.longpoller_timeout; 615 | _this.conn.onopen = function () { 616 | return _this.onConnOpen(); 617 | }; 618 | _this.conn.onerror = function (error) { 619 | return _this.onConnError(error); 620 | }; 621 | _this.conn.onmessage = function (event) { 622 | return _this.onConnMessage(event); 623 | }; 624 | _this.conn.onclose = function (event) { 625 | return _this.onConnClose(event); 626 | }; 627 | }); 628 | }, 629 | writable: true, 630 | configurable: true 631 | }, 632 | log: { 633 | 634 | // Logs the message. Override `this.logger` for specialized logging. noops by default 635 | 636 | value: function log(msg) { 637 | this.logger(msg); 638 | }, 639 | writable: true, 640 | configurable: true 641 | }, 642 | onOpen: { 643 | 644 | // Registers callbacks for connection state change events 645 | // 646 | // Examples 647 | // 648 | // socket.onError(function(error){ alert("An error occurred") }) 649 | // 650 | 651 | value: function onOpen(callback) { 652 | this.stateChangeCallbacks.open.push(callback); 653 | }, 654 | writable: true, 655 | configurable: true 656 | }, 657 | onClose: { 658 | value: function onClose(callback) { 659 | this.stateChangeCallbacks.close.push(callback); 660 | }, 661 | writable: true, 662 | configurable: true 663 | }, 664 | onError: { 665 | value: function onError(callback) { 666 | this.stateChangeCallbacks.error.push(callback); 667 | }, 668 | writable: true, 669 | configurable: true 670 | }, 671 | onMessage: { 672 | value: function onMessage(callback) { 673 | this.stateChangeCallbacks.message.push(callback); 674 | }, 675 | writable: true, 676 | configurable: true 677 | }, 678 | onConnOpen: { 679 | value: function onConnOpen() { 680 | var _this = this; 681 | 682 | this.flushSendBuffer(); 683 | clearInterval(this.reconnectTimer); 684 | if (!this.conn.skipHeartbeat) { 685 | clearInterval(this.heartbeatTimer); 686 | this.heartbeatTimer = setInterval(function () { 687 | return _this.sendHeartbeat(); 688 | }, this.heartbeatIntervalMs); 689 | } 690 | this.stateChangeCallbacks.open.forEach(function (callback) { 691 | return callback(); 692 | }); 693 | }, 694 | writable: true, 695 | configurable: true 696 | }, 697 | onConnClose: { 698 | value: function onConnClose(event) { 699 | var _this = this; 700 | 701 | this.log("WS close:"); 702 | this.log(event); 703 | this.triggerChanError(); 704 | clearInterval(this.reconnectTimer); 705 | clearInterval(this.heartbeatTimer); 706 | this.reconnectTimer = setInterval(function () { 707 | return _this.connect(); 708 | }, this.reconnectAfterMs); 709 | this.stateChangeCallbacks.close.forEach(function (callback) { 710 | return callback(event); 711 | }); 712 | }, 713 | writable: true, 714 | configurable: true 715 | }, 716 | onConnError: { 717 | value: function onConnError(error) { 718 | this.log("WS error:"); 719 | this.log(error); 720 | this.triggerChanError(); 721 | this.stateChangeCallbacks.error.forEach(function (callback) { 722 | return callback(error); 723 | }); 724 | }, 725 | writable: true, 726 | configurable: true 727 | }, 728 | triggerChanError: { 729 | value: function triggerChanError() { 730 | this.channels.forEach(function (chan) { 731 | return chan.trigger(CHAN_EVENTS.error); 732 | }); 733 | }, 734 | writable: true, 735 | configurable: true 736 | }, 737 | connectionState: { 738 | value: function connectionState() { 739 | switch (this.conn && this.conn.readyState) { 740 | case SOCKET_STATES.connecting: 741 | return "connecting"; 742 | case SOCKET_STATES.open: 743 | return "open"; 744 | case SOCKET_STATES.closing: 745 | return "closing"; 746 | default: 747 | return "closed"; 748 | } 749 | }, 750 | writable: true, 751 | configurable: true 752 | }, 753 | isConnected: { 754 | value: function isConnected() { 755 | return this.connectionState() === "open"; 756 | }, 757 | writable: true, 758 | configurable: true 759 | }, 760 | remove: { 761 | value: function remove(chan) { 762 | this.channels = this.channels.filter(function (c) { 763 | return !c.isMember(chan.topic); 764 | }); 765 | }, 766 | writable: true, 767 | configurable: true 768 | }, 769 | chan: { 770 | value: function chan(topic, params) { 771 | var chan = new Channel(topic, params, this); 772 | this.channels.push(chan); 773 | return chan; 774 | }, 775 | writable: true, 776 | configurable: true 777 | }, 778 | push: { 779 | value: function push(data) { 780 | var _this = this; 781 | 782 | var callback = function () { 783 | return _this.conn.send(JSON.stringify(data)); 784 | }; 785 | if (this.isConnected()) { 786 | callback(); 787 | } else { 788 | this.sendBuffer.push(callback); 789 | } 790 | }, 791 | writable: true, 792 | configurable: true 793 | }, 794 | makeRef: { 795 | 796 | // Return the next message ref, accounting for overflows 797 | 798 | value: function makeRef() { 799 | var newRef = this.ref + 1; 800 | if (newRef === this.ref) { 801 | this.ref = 0; 802 | } else { 803 | this.ref = newRef; 804 | } 805 | 806 | return this.ref.toString(); 807 | }, 808 | writable: true, 809 | configurable: true 810 | }, 811 | sendHeartbeat: { 812 | value: function sendHeartbeat() { 813 | this.push({ topic: "phoenix", event: "heartbeat", payload: {}, ref: this.makeRef() }); 814 | }, 815 | writable: true, 816 | configurable: true 817 | }, 818 | flushSendBuffer: { 819 | value: function flushSendBuffer() { 820 | if (this.isConnected() && this.sendBuffer.length > 0) { 821 | this.sendBuffer.forEach(function (callback) { 822 | return callback(); 823 | }); 824 | this.sendBuffer = []; 825 | } 826 | }, 827 | writable: true, 828 | configurable: true 829 | }, 830 | onConnMessage: { 831 | value: function onConnMessage(rawMessage) { 832 | this.log("message received:"); 833 | this.log(rawMessage); 834 | var msg = JSON.parse(rawMessage.data); 835 | var topic = msg.topic; 836 | var event = msg.event; 837 | var payload = msg.payload; 838 | var ref = msg.ref; 839 | 840 | this.channels.filter(function (chan) { 841 | return chan.isMember(topic); 842 | }).forEach(function (chan) { 843 | return chan.trigger(event, payload, ref); 844 | }); 845 | this.stateChangeCallbacks.message.forEach(function (callback) { 846 | return callback(msg); 847 | }); 848 | }, 849 | writable: true, 850 | configurable: true 851 | } 852 | }); 853 | 854 | return Socket; 855 | })(); 856 | 857 | var LongPoller = exports.LongPoller = (function () { 858 | function LongPoller(endPoint) { 859 | _classCallCheck(this, LongPoller); 860 | 861 | this.retryInMs = 5000; 862 | this.endPoint = null; 863 | this.token = null; 864 | this.sig = null; 865 | this.skipHeartbeat = true; 866 | this.onopen = function () {}; // noop 867 | this.onerror = function () {}; // noop 868 | this.onmessage = function () {}; // noop 869 | this.onclose = function () {}; // noop 870 | this.upgradeEndpoint = this.normalizeEndpoint(endPoint); 871 | this.pollEndpoint = this.upgradeEndpoint + (/\/$/.test(endPoint) ? "poll" : "/poll"); 872 | this.readyState = SOCKET_STATES.connecting; 873 | 874 | this.poll(); 875 | } 876 | 877 | _prototypeProperties(LongPoller, null, { 878 | normalizeEndpoint: { 879 | value: function normalizeEndpoint(endPoint) { 880 | return endPoint.replace("ws://", "http://").replace("wss://", "https://"); 881 | }, 882 | writable: true, 883 | configurable: true 884 | }, 885 | endpointURL: { 886 | value: function endpointURL() { 887 | return this.pollEndpoint + ("?token=" + encodeURIComponent(this.token) + "&sig=" + encodeURIComponent(this.sig)); 888 | }, 889 | writable: true, 890 | configurable: true 891 | }, 892 | closeAndRetry: { 893 | value: function closeAndRetry() { 894 | this.close(); 895 | this.readyState = SOCKET_STATES.connecting; 896 | }, 897 | writable: true, 898 | configurable: true 899 | }, 900 | ontimeout: { 901 | value: function ontimeout() { 902 | this.onerror("timeout"); 903 | this.closeAndRetry(); 904 | }, 905 | writable: true, 906 | configurable: true 907 | }, 908 | poll: { 909 | value: function poll() { 910 | var _this = this; 911 | 912 | if (!(this.readyState === SOCKET_STATES.open || this.readyState === SOCKET_STATES.connecting)) { 913 | return; 914 | } 915 | 916 | Ajax.request("GET", this.endpointURL(), "application/json", null, this.timeout, this.ontimeout.bind(this), function (resp) { 917 | if (resp) { 918 | var status = resp.status; 919 | var token = resp.token; 920 | var sig = resp.sig; 921 | var messages = resp.messages; 922 | 923 | _this.token = token; 924 | _this.sig = sig; 925 | } else { 926 | var status = 0; 927 | } 928 | 929 | switch (status) { 930 | case 200: 931 | messages.forEach(function (msg) { 932 | return _this.onmessage({ data: JSON.stringify(msg) }); 933 | }); 934 | _this.poll(); 935 | break; 936 | case 204: 937 | _this.poll(); 938 | break; 939 | case 410: 940 | _this.readyState = SOCKET_STATES.open; 941 | _this.onopen(); 942 | _this.poll(); 943 | break; 944 | case 0: 945 | case 500: 946 | _this.onerror(); 947 | _this.closeAndRetry(); 948 | break; 949 | default: 950 | throw "unhandled poll status " + status; 951 | } 952 | }); 953 | }, 954 | writable: true, 955 | configurable: true 956 | }, 957 | send: { 958 | value: function send(body) { 959 | var _this = this; 960 | 961 | Ajax.request("POST", this.endpointURL(), "application/json", body, this.timeout, this.onerror.bind(this, "timeout"), function (resp) { 962 | if (!resp || resp.status !== 200) { 963 | _this.onerror(status); 964 | _this.closeAndRetry(); 965 | } 966 | }); 967 | }, 968 | writable: true, 969 | configurable: true 970 | }, 971 | close: { 972 | value: function close(code, reason) { 973 | this.readyState = SOCKET_STATES.closed; 974 | this.onclose(); 975 | }, 976 | writable: true, 977 | configurable: true 978 | } 979 | }); 980 | 981 | return LongPoller; 982 | })(); 983 | 984 | var Ajax = exports.Ajax = (function () { 985 | function Ajax() { 986 | _classCallCheck(this, Ajax); 987 | } 988 | 989 | _prototypeProperties(Ajax, { 990 | request: { 991 | value: function request(method, endPoint, accept, body, timeout, ontimeout, callback) { 992 | if (window.XDomainRequest) { 993 | var req = new XDomainRequest(); // IE8, IE9 994 | this.xdomainRequest(req, method, endPoint, body, timeout, ontimeout, callback); 995 | } else { 996 | var req = window.XMLHttpRequest ? new XMLHttpRequest() : // IE7+, Firefox, Chrome, Opera, Safari 997 | new ActiveXObject("Microsoft.XMLHTTP"); // IE6, IE5 998 | this.xhrRequest(req, method, endPoint, accept, body, timeout, ontimeout, callback); 999 | } 1000 | }, 1001 | writable: true, 1002 | configurable: true 1003 | }, 1004 | xdomainRequest: { 1005 | value: function xdomainRequest(req, method, endPoint, body, timeout, ontimeout, callback) { 1006 | var _this = this; 1007 | 1008 | req.timeout = timeout; 1009 | req.open(method, endPoint); 1010 | req.onload = function () { 1011 | var response = _this.parseJSON(req.responseText); 1012 | callback && callback(response); 1013 | }; 1014 | if (ontimeout) { 1015 | req.ontimeout = ontimeout; 1016 | } 1017 | 1018 | // Work around bug in IE9 that requires an attached onprogress handler 1019 | req.onprogress = function () {}; 1020 | 1021 | req.send(body); 1022 | }, 1023 | writable: true, 1024 | configurable: true 1025 | }, 1026 | xhrRequest: { 1027 | value: function xhrRequest(req, method, endPoint, accept, body, timeout, ontimeout, callback) { 1028 | var _this = this; 1029 | 1030 | req.timeout = timeout; 1031 | req.open(method, endPoint, true); 1032 | req.setRequestHeader("Content-Type", accept); 1033 | req.onerror = function () { 1034 | callback && callback(null); 1035 | }; 1036 | req.onreadystatechange = function () { 1037 | if (req.readyState === _this.states.complete && callback) { 1038 | var response = _this.parseJSON(req.responseText); 1039 | callback(response); 1040 | } 1041 | }; 1042 | if (ontimeout) { 1043 | req.ontimeout = ontimeout; 1044 | } 1045 | 1046 | req.send(body); 1047 | }, 1048 | writable: true, 1049 | configurable: true 1050 | }, 1051 | parseJSON: { 1052 | value: function parseJSON(resp) { 1053 | return resp && resp !== "" ? JSON.parse(resp) : null; 1054 | }, 1055 | writable: true, 1056 | configurable: true 1057 | } 1058 | }); 1059 | 1060 | return Ajax; 1061 | })(); 1062 | 1063 | Ajax.states = { complete: 4 }; 1064 | Object.defineProperty(exports, "__esModule", { 1065 | value: true 1066 | }); 1067 | }}); 1068 | if(typeof(window) === 'object' && !window.Phoenix){ window.Phoenix = require('phoenix') }; -------------------------------------------------------------------------------- /phoenix/app/test/benchmarker_test.exs: -------------------------------------------------------------------------------- 1 | defmodule BenchmarkerTest do 2 | use ExUnit.Case 3 | 4 | test "the truth" do 5 | assert 1 + 1 == 2 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /phoenix/app/test/test_helper.exs: -------------------------------------------------------------------------------- 1 | ExUnit.start 2 | -------------------------------------------------------------------------------- /phoenix/app/web/controllers/page_controller.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.PageController do 2 | use Benchmarker.Web, :controller 3 | 4 | def index(conn, %{"title" => title}) do 5 | render conn, "index.html", title: title, members: [ 6 | %{name: "Serdar Dogruyol"}, 7 | %{name: "Fatih Kadir Akin"}, 8 | %{name: "Askin Gedik"}, 9 | %{name: "Ary Borenszweig"} 10 | ] 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /phoenix/app/web/router.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.Router do 2 | use Phoenix.Router 3 | 4 | pipeline :browser do 5 | plug :accepts, ~w(html) 6 | plug :fetch_session 7 | end 8 | 9 | scope "/", Benchmarker do 10 | pipe_through :browser 11 | 12 | get "/:title", PageController, :index 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /phoenix/app/web/templates/layout/app.html.eex: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | <%= render @view_module, @view_template, assigns %> 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /phoenix/app/web/templates/page/bio.html.eex: -------------------------------------------------------------------------------- 1 | Name: <%= @member.name %> 2 | -------------------------------------------------------------------------------- /phoenix/app/web/templates/page/error.html.eex: -------------------------------------------------------------------------------- 1 | Something went wrong 2 | -------------------------------------------------------------------------------- /phoenix/app/web/templates/page/index.html.eex: -------------------------------------------------------------------------------- 1 |
2 |

Welcome to Kemal!

3 |

Kemal is a Crystal Web Framework targeting to be crazy fast, scalable and simple.

4 |
5 | 6 |
7 |
8 |

Resources: <%= @title %>

9 | 17 |
18 | 19 |
20 |

Help

21 | 26 | 27 |

Team Members

28 |
    29 | <%= for member <- @members do %> 30 |
  • 31 | <%= render "bio.html", member: member %> 32 |
  • 33 | <% end %> 34 |
35 |
36 | 37 |
38 | Enjoy it! 39 |
40 | -------------------------------------------------------------------------------- /phoenix/app/web/templates/page/not_found.html.eex: -------------------------------------------------------------------------------- 1 | The page you are looking for does not exist 2 | -------------------------------------------------------------------------------- /phoenix/app/web/views/error_view.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.ErrorView do 2 | use Benchmarker.Web, :view 3 | 4 | def render("404.html", _assigns) do 5 | "Page not found - 404" 6 | end 7 | 8 | def render("500.html", _assigns) do 9 | "Server internal error - 500" 10 | end 11 | 12 | # Render all other templates as 500 13 | def render(_, assigns) do 14 | render "500.html", assigns 15 | end 16 | end 17 | -------------------------------------------------------------------------------- /phoenix/app/web/views/layout_view.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.LayoutView do 2 | use Benchmarker.Web, :view 3 | end 4 | -------------------------------------------------------------------------------- /phoenix/app/web/views/page_view.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.PageView do 2 | use Benchmarker.Web, :view 3 | end 4 | -------------------------------------------------------------------------------- /phoenix/app/web/web.ex: -------------------------------------------------------------------------------- 1 | defmodule Benchmarker.Web do 2 | def view do 3 | quote do 4 | use Phoenix.View, root: "web/templates" 5 | 6 | # Import common functionality 7 | import Benchmarker.Router.Helpers 8 | 9 | import Phoenix.Controller, only: [get_flash: 2] 10 | end 11 | end 12 | 13 | def controller do 14 | quote do 15 | use Phoenix.Controller 16 | 17 | # Import URL helpers from the router 18 | import Benchmarker.Router.Helpers 19 | end 20 | end 21 | 22 | def model do 23 | quote do 24 | end 25 | end 26 | 27 | @doc """ 28 | When used, dispatch to the appropriate controller/view/etc. 29 | """ 30 | defmacro __using__(which) when is_atom(which) do 31 | apply(__MODULE__, which, []) 32 | end 33 | end -------------------------------------------------------------------------------- /rails/app/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files for more about ignoring files. 2 | # 3 | # If you find yourself ignoring temporary files generated by your text editor 4 | # or operating system, you probably want to add a global ignore instead: 5 | # git config --global core.excludesfile '~/.gitignore_global' 6 | 7 | # Ignore bundler config. 8 | /.bundle 9 | 10 | # Ignore the default SQLite database. 11 | /db/*.sqlite3 12 | /db/*.sqlite3-journal 13 | 14 | # Ignore all logfiles and tempfiles. 15 | /log/* 16 | !/log/.keep 17 | /tmp 18 | -------------------------------------------------------------------------------- /rails/app/Gemfile: -------------------------------------------------------------------------------- 1 | source 'https://rubygems.org' 2 | 3 | 4 | # Bundle edge Rails instead: gem 'rails', github: 'rails/rails' 5 | gem 'rails', '4.2.3' 6 | gem 'puma' 7 | 8 | -------------------------------------------------------------------------------- /rails/app/Gemfile.lock: -------------------------------------------------------------------------------- 1 | GEM 2 | remote: https://rubygems.org/ 3 | specs: 4 | actionmailer (4.2.3) 5 | actionpack (= 4.2.3) 6 | actionview (= 4.2.3) 7 | activejob (= 4.2.3) 8 | mail (~> 2.5, >= 2.5.4) 9 | rails-dom-testing (~> 1.0, >= 1.0.5) 10 | actionpack (4.2.3) 11 | actionview (= 4.2.3) 12 | activesupport (= 4.2.3) 13 | rack (~> 1.6) 14 | rack-test (~> 0.6.2) 15 | rails-dom-testing (~> 1.0, >= 1.0.5) 16 | rails-html-sanitizer (~> 1.0, >= 1.0.2) 17 | actionview (4.2.3) 18 | activesupport (= 4.2.3) 19 | builder (~> 3.1) 20 | erubis (~> 2.7.0) 21 | rails-dom-testing (~> 1.0, >= 1.0.5) 22 | rails-html-sanitizer (~> 1.0, >= 1.0.2) 23 | activejob (4.2.3) 24 | activesupport (= 4.2.3) 25 | globalid (>= 0.3.0) 26 | activemodel (4.2.3) 27 | activesupport (= 4.2.3) 28 | builder (~> 3.1) 29 | activerecord (4.2.3) 30 | activemodel (= 4.2.3) 31 | activesupport (= 4.2.3) 32 | arel (~> 6.0) 33 | activesupport (4.2.3) 34 | i18n (~> 0.7) 35 | json (~> 1.7, >= 1.7.7) 36 | minitest (~> 5.1) 37 | thread_safe (~> 0.3, >= 0.3.4) 38 | tzinfo (~> 1.1) 39 | arel (6.0.3) 40 | builder (3.2.2) 41 | concurrent-ruby (1.0.1) 42 | erubis (2.7.0) 43 | globalid (0.3.6) 44 | activesupport (>= 4.1.0) 45 | i18n (0.7.0) 46 | json (1.8.3) 47 | loofah (2.0.3) 48 | nokogiri (>= 1.5.9) 49 | mail (2.6.4) 50 | mime-types (>= 1.16, < 4) 51 | mime-types (3.0) 52 | mime-types-data (~> 3.2015) 53 | mime-types-data (3.2016.0221) 54 | mini_portile2 (2.0.0) 55 | minitest (5.8.4) 56 | nokogiri (1.6.7.2) 57 | mini_portile2 (~> 2.0.0.rc2) 58 | puma (3.2.0) 59 | rack (1.6.4) 60 | rack-test (0.6.3) 61 | rack (>= 1.0) 62 | rails (4.2.3) 63 | actionmailer (= 4.2.3) 64 | actionpack (= 4.2.3) 65 | actionview (= 4.2.3) 66 | activejob (= 4.2.3) 67 | activemodel (= 4.2.3) 68 | activerecord (= 4.2.3) 69 | activesupport (= 4.2.3) 70 | bundler (>= 1.3.0, < 2.0) 71 | railties (= 4.2.3) 72 | sprockets-rails 73 | rails-deprecated_sanitizer (1.0.3) 74 | activesupport (>= 4.2.0.alpha) 75 | rails-dom-testing (1.0.7) 76 | activesupport (>= 4.2.0.beta, < 5.0) 77 | nokogiri (~> 1.6.0) 78 | rails-deprecated_sanitizer (>= 1.0.1) 79 | rails-html-sanitizer (1.0.3) 80 | loofah (~> 2.0) 81 | railties (4.2.3) 82 | actionpack (= 4.2.3) 83 | activesupport (= 4.2.3) 84 | rake (>= 0.8.7) 85 | thor (>= 0.18.1, < 2.0) 86 | rake (11.1.2) 87 | sprockets (3.5.2) 88 | concurrent-ruby (~> 1.0) 89 | rack (> 1, < 3) 90 | sprockets-rails (3.0.4) 91 | actionpack (>= 4.0) 92 | activesupport (>= 4.0) 93 | sprockets (>= 3.0.0) 94 | thor (0.19.1) 95 | thread_safe (0.3.5) 96 | tzinfo (1.2.2) 97 | thread_safe (~> 0.1) 98 | 99 | PLATFORMS 100 | ruby 101 | 102 | DEPENDENCIES 103 | puma 104 | rails (= 4.2.3) 105 | 106 | BUNDLED WITH 107 | 1.10.6 108 | -------------------------------------------------------------------------------- /rails/app/README.rdoc: -------------------------------------------------------------------------------- 1 | == README 2 | 3 | This README would normally document whatever steps are necessary to get the 4 | application up and running. 5 | 6 | Things you may want to cover: 7 | 8 | * Ruby version 9 | 10 | * System dependencies 11 | 12 | * Configuration 13 | 14 | * Database creation 15 | 16 | * Database initialization 17 | 18 | * How to run the test suite 19 | 20 | * Services (job queues, cache servers, search engines, etc.) 21 | 22 | * Deployment instructions 23 | 24 | * ... 25 | 26 | 27 | Please feel free to use a different markup language if you do not plan to run 28 | rake doc:app. 29 | -------------------------------------------------------------------------------- /rails/app/Rakefile: -------------------------------------------------------------------------------- 1 | # Add your own tasks in files placed in lib/tasks ending in .rake, 2 | # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. 3 | 4 | require File.expand_path('../config/application', __FILE__) 5 | 6 | Rails.application.load_tasks 7 | -------------------------------------------------------------------------------- /rails/app/app/controllers/application_controller.rb: -------------------------------------------------------------------------------- 1 | class ApplicationController < ActionController::Base 2 | # Prevent CSRF attacks by raising an exception. 3 | # For APIs, you may want to use :null_session instead. 4 | protect_from_forgery with: :exception 5 | end 6 | -------------------------------------------------------------------------------- /rails/app/app/controllers/concerns/.keep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/rails/app/app/controllers/concerns/.keep -------------------------------------------------------------------------------- /rails/app/app/controllers/dashboard_controller.rb: -------------------------------------------------------------------------------- 1 | class DashboardController < ApplicationController 2 | layout false 3 | 4 | def index 5 | @title = params[:title] 6 | 7 | @members = [ 8 | { name: 'Serdar Dogruyol' }, 9 | { name: 'Fatih Kadir Akin' }, 10 | { name: 'Askin Gedik' }, 11 | { name: 'Ary Borenszweig'} 12 | ] 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /rails/app/app/views/dashboard/_bio.html.erb: -------------------------------------------------------------------------------- 1 | Name: <%= member[:name] %> -------------------------------------------------------------------------------- /rails/app/app/views/dashboard/index.html.erb: -------------------------------------------------------------------------------- 1 |
2 |

Welcome to Kemal!

3 |

Kemal is a Crystal Web Framework targeting to be crazy fast, scalable and simple.

4 |
5 | 6 |
7 |
8 |

Resources: <%= @title %>

9 | 17 |
18 | 19 |
20 |

Help

21 | 26 | 27 |

Team Members

28 |
    29 | <% for member in @members do %> 30 |
  • 31 | <%= render partial: "bio.html", locals: {member: member} %> 32 |
  • 33 | <% end %> 34 |
35 |
36 | 37 |
38 | Enjoy it! 39 |
-------------------------------------------------------------------------------- /rails/app/bin/bundle: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) 3 | load Gem.bin_path('bundler', 'bundle') 4 | -------------------------------------------------------------------------------- /rails/app/bin/rails: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | begin 3 | load File.expand_path('../spring', __FILE__) 4 | rescue LoadError => e 5 | raise unless e.message.include?('spring') 6 | end 7 | APP_PATH = File.expand_path('../../config/application', __FILE__) 8 | require_relative '../config/boot' 9 | require 'rails/commands' 10 | -------------------------------------------------------------------------------- /rails/app/bin/rake: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | begin 3 | load File.expand_path('../spring', __FILE__) 4 | rescue LoadError => e 5 | raise unless e.message.include?('spring') 6 | end 7 | require_relative '../config/boot' 8 | require 'rake' 9 | Rake.application.run 10 | -------------------------------------------------------------------------------- /rails/app/bin/setup: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require 'pathname' 3 | 4 | # path to your application root. 5 | APP_ROOT = Pathname.new File.expand_path('../../', __FILE__) 6 | 7 | Dir.chdir APP_ROOT do 8 | # This script is a starting point to setup your application. 9 | # Add necessary setup steps to this file: 10 | 11 | puts "== Installing dependencies ==" 12 | system "gem install bundler --conservative" 13 | system "bundle check || bundle install" 14 | 15 | # puts "\n== Copying sample files ==" 16 | # unless File.exist?("config/database.yml") 17 | # system "cp config/database.yml.sample config/database.yml" 18 | # end 19 | 20 | puts "\n== Preparing database ==" 21 | system "bin/rake db:setup" 22 | 23 | puts "\n== Removing old logs and tempfiles ==" 24 | system "rm -f log/*" 25 | system "rm -rf tmp/cache" 26 | 27 | puts "\n== Restarting application server ==" 28 | system "touch tmp/restart.txt" 29 | end 30 | -------------------------------------------------------------------------------- /rails/app/bin/spring: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | 3 | # This file loads spring without using Bundler, in order to be fast. 4 | # It gets overwritten when you run the `spring binstub` command. 5 | 6 | unless defined?(Spring) 7 | require 'rubygems' 8 | require 'bundler' 9 | 10 | if (match = Bundler.default_lockfile.read.match(/^GEM$.*?^ (?: )*spring \((.*?)\)$.*?^$/m)) 11 | Gem.paths = { 'GEM_PATH' => [Bundler.bundle_path.to_s, *Gem.path].uniq.join(Gem.path_separator) } 12 | gem 'spring', match[1] 13 | require 'spring/binstub' 14 | end 15 | end 16 | -------------------------------------------------------------------------------- /rails/app/config.ru: -------------------------------------------------------------------------------- 1 | # This file is used by Rack-based servers to start the application. 2 | 3 | require ::File.expand_path('../config/environment', __FILE__) 4 | run Rails.application 5 | -------------------------------------------------------------------------------- /rails/app/config/application.rb: -------------------------------------------------------------------------------- 1 | require File.expand_path('../boot', __FILE__) 2 | 3 | require "action_controller/railtie" 4 | require "action_view/railtie" 5 | 6 | # Require the gems listed in Gemfile, including any gems 7 | # you've limited to :test, :development, or :production. 8 | Bundler.require(*Rails.groups) 9 | 10 | module App 11 | class Application < Rails::Application 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /rails/app/config/boot.rb: -------------------------------------------------------------------------------- 1 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) 2 | 3 | require 'bundler/setup' # Set up gems listed in the Gemfile. 4 | -------------------------------------------------------------------------------- /rails/app/config/environment.rb: -------------------------------------------------------------------------------- 1 | # Load the Rails application. 2 | require File.expand_path('../application', __FILE__) 3 | 4 | # Initialize the Rails application. 5 | Rails.application.initialize! 6 | -------------------------------------------------------------------------------- /rails/app/config/environments/development.rb: -------------------------------------------------------------------------------- 1 | Rails.application.configure do 2 | # Settings specified here will take precedence over those in config/application.rb. 3 | 4 | # In the development environment your application's code is reloaded on 5 | # every request. This slows down response time but is perfect for development 6 | # since you don't have to restart the web server when you make code changes. 7 | config.cache_classes = false 8 | 9 | # Do not eager load code on boot. 10 | config.eager_load = false 11 | 12 | # Show full error reports and disable caching. 13 | config.consider_all_requests_local = true 14 | config.action_controller.perform_caching = false 15 | 16 | # Print deprecation notices to the Rails logger. 17 | config.active_support.deprecation = :log 18 | 19 | # Debug mode disables concatenation and preprocessing of assets. 20 | # This option may cause significant delays in view rendering with a large 21 | # number of complex assets. 22 | config.assets.debug = true 23 | 24 | # Asset digests allow you to set far-future HTTP expiration dates on all assets, 25 | # yet still be able to expire them through the digest params. 26 | config.assets.digest = true 27 | 28 | # Adds additional error checking when serving assets at runtime. 29 | # Checks for improperly declared sprockets dependencies. 30 | # Raises helpful error messages. 31 | config.assets.raise_runtime_errors = true 32 | 33 | # Raises error for missing translations 34 | # config.action_view.raise_on_missing_translations = true 35 | end 36 | -------------------------------------------------------------------------------- /rails/app/config/environments/production.rb: -------------------------------------------------------------------------------- 1 | Rails.application.configure do 2 | # Settings specified here will take precedence over those in config/application.rb. 3 | 4 | # Code is not reloaded between requests. 5 | config.cache_classes = true 6 | 7 | # Eager load code on boot. This eager loads most of Rails and 8 | # your application in memory, allowing both threaded web servers 9 | # and those relying on copy on write to perform better. 10 | # Rake tasks automatically ignore this option for performance. 11 | config.eager_load = true 12 | 13 | # Full error reports are disabled and caching is turned on. 14 | config.consider_all_requests_local = false 15 | config.action_controller.perform_caching = true 16 | 17 | # Enable Rack::Cache to put a simple HTTP cache in front of your application 18 | # Add `rack-cache` to your Gemfile before enabling this. 19 | # For large-scale production use, consider using a caching reverse proxy like 20 | # NGINX, varnish or squid. 21 | # config.action_dispatch.rack_cache = true 22 | 23 | # Disable serving static files from the `/public` folder by default since 24 | # Apache or NGINX already handles this. 25 | config.serve_static_files = ENV['RAILS_SERVE_STATIC_FILES'].present? 26 | 27 | # Compress JavaScripts and CSS. 28 | config.assets.js_compressor = :uglifier 29 | # config.assets.css_compressor = :sass 30 | 31 | # Do not fallback to assets pipeline if a precompiled asset is missed. 32 | config.assets.compile = false 33 | 34 | # Asset digests allow you to set far-future HTTP expiration dates on all assets, 35 | # yet still be able to expire them through the digest params. 36 | config.assets.digest = true 37 | 38 | # `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb 39 | 40 | # Specifies the header that your server uses for sending files. 41 | # config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache 42 | # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX 43 | 44 | # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies. 45 | # config.force_ssl = true 46 | 47 | # Use the lowest log level to ensure availability of diagnostic information 48 | # when problems arise. 49 | config.log_level = :fatal 50 | 51 | # Prepend all log lines with the following tags. 52 | # config.log_tags = [ :subdomain, :uuid ] 53 | 54 | # Use a different logger for distributed setups. 55 | # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new) 56 | 57 | # Use a different cache store in production. 58 | # config.cache_store = :mem_cache_store 59 | 60 | # Enable serving of images, stylesheets, and JavaScripts from an asset server. 61 | # config.action_controller.asset_host = 'http://assets.example.com' 62 | 63 | # Ignore bad email addresses and do not raise email delivery errors. 64 | # Set this to true and configure the email server for immediate delivery to raise delivery errors. 65 | # config.action_mailer.raise_delivery_errors = false 66 | 67 | # Enable locale fallbacks for I18n (makes lookups for any locale fall back to 68 | # the I18n.default_locale when a translation cannot be found). 69 | config.i18n.fallbacks = true 70 | 71 | # Send deprecation notices to registered listeners. 72 | config.active_support.deprecation = :notify 73 | 74 | # Use default logging formatter so that PID and timestamp are not suppressed. 75 | config.log_formatter = ::Logger::Formatter.new 76 | end 77 | -------------------------------------------------------------------------------- /rails/app/config/environments/test.rb: -------------------------------------------------------------------------------- 1 | Rails.application.configure do 2 | # Settings specified here will take precedence over those in config/application.rb. 3 | 4 | # The test environment is used exclusively to run your application's 5 | # test suite. You never need to work with it otherwise. Remember that 6 | # your test database is "scratch space" for the test suite and is wiped 7 | # and recreated between test runs. Don't rely on the data there! 8 | config.cache_classes = true 9 | 10 | # Do not eager load code on boot. This avoids loading your whole application 11 | # just for the purpose of running a single test. If you are using a tool that 12 | # preloads Rails for running tests, you may have to set it to true. 13 | config.eager_load = false 14 | 15 | # Configure static file server for tests with Cache-Control for performance. 16 | config.serve_static_files = true 17 | config.static_cache_control = 'public, max-age=3600' 18 | 19 | # Show full error reports and disable caching. 20 | config.consider_all_requests_local = true 21 | config.action_controller.perform_caching = false 22 | 23 | # Raise exceptions instead of rendering exception templates. 24 | config.action_dispatch.show_exceptions = false 25 | 26 | # Disable request forgery protection in test environment. 27 | config.action_controller.allow_forgery_protection = false 28 | 29 | # Randomize the order test cases are executed. 30 | config.active_support.test_order = :random 31 | 32 | # Print deprecation notices to the stderr. 33 | config.active_support.deprecation = :stderr 34 | 35 | # Raises error for missing translations 36 | # config.action_view.raise_on_missing_translations = true 37 | end 38 | -------------------------------------------------------------------------------- /rails/app/config/initializers/assets.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Version of your assets, change this if you want to expire all your assets. 4 | Rails.application.config.assets.version = '1.0' 5 | 6 | # Add additional assets to the asset load path 7 | # Rails.application.config.assets.paths << Emoji.images_path 8 | 9 | # Precompile additional assets. 10 | # application.js, application.css, and all non-JS/CSS in app/assets folder are already added. 11 | # Rails.application.config.assets.precompile += %w( search.js ) 12 | -------------------------------------------------------------------------------- /rails/app/config/initializers/backtrace_silencers.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces. 4 | # Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ } 5 | 6 | # You can also remove all the silencers if you're trying to debug a problem that might stem from framework code. 7 | # Rails.backtrace_cleaner.remove_silencers! 8 | -------------------------------------------------------------------------------- /rails/app/config/initializers/cookies_serializer.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | Rails.application.config.action_dispatch.cookies_serializer = :json 4 | -------------------------------------------------------------------------------- /rails/app/config/initializers/filter_parameter_logging.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Configure sensitive parameters which will be filtered from the log file. 4 | Rails.application.config.filter_parameters += [:password] 5 | -------------------------------------------------------------------------------- /rails/app/config/initializers/inflections.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Add new inflection rules using the following format. Inflections 4 | # are locale specific, and you may define rules for as many different 5 | # locales as you wish. All of these examples are active by default: 6 | # ActiveSupport::Inflector.inflections(:en) do |inflect| 7 | # inflect.plural /^(ox)$/i, '\1en' 8 | # inflect.singular /^(ox)en/i, '\1' 9 | # inflect.irregular 'person', 'people' 10 | # inflect.uncountable %w( fish sheep ) 11 | # end 12 | 13 | # These inflection rules are supported but not enabled by default: 14 | # ActiveSupport::Inflector.inflections(:en) do |inflect| 15 | # inflect.acronym 'RESTful' 16 | # end 17 | -------------------------------------------------------------------------------- /rails/app/config/initializers/mime_types.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Add new mime types for use in respond_to blocks: 4 | # Mime::Type.register "text/richtext", :rtf 5 | -------------------------------------------------------------------------------- /rails/app/config/initializers/session_store.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | Rails.application.config.session_store :cookie_store, key: '_app_session' 4 | -------------------------------------------------------------------------------- /rails/app/config/initializers/wrap_parameters.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # This file contains settings for ActionController::ParamsWrapper which 4 | # is enabled by default. 5 | 6 | # Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array. 7 | ActiveSupport.on_load(:action_controller) do 8 | wrap_parameters format: [:json] if respond_to?(:wrap_parameters) 9 | end 10 | 11 | # To enable root element in JSON for ActiveRecord objects. 12 | # ActiveSupport.on_load(:active_record) do 13 | # self.include_root_in_json = true 14 | # end 15 | -------------------------------------------------------------------------------- /rails/app/config/locales/en.yml: -------------------------------------------------------------------------------- 1 | # Files in the config/locales directory are used for internationalization 2 | # and are automatically loaded by Rails. If you want to use locales other 3 | # than English, add the necessary files in this directory. 4 | # 5 | # To use the locales, use `I18n.t`: 6 | # 7 | # I18n.t 'hello' 8 | # 9 | # In views, this is aliased to just `t`: 10 | # 11 | # <%= t('hello') %> 12 | # 13 | # To use a different locale, set it with `I18n.locale`: 14 | # 15 | # I18n.locale = :es 16 | # 17 | # This would use the information in config/locales/es.yml. 18 | # 19 | # To learn more, please read the Rails Internationalization guide 20 | # available at http://guides.rubyonrails.org/i18n.html. 21 | 22 | en: 23 | hello: "Hello world" 24 | -------------------------------------------------------------------------------- /rails/app/config/routes.rb: -------------------------------------------------------------------------------- 1 | Rails.application.routes.draw do 2 | get '/:title', to: 'dashboard#index' 3 | end 4 | -------------------------------------------------------------------------------- /rails/app/config/secrets.yml: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Your secret key is used for verifying the integrity of signed cookies. 4 | # If you change this key, all old signed cookies will become invalid! 5 | 6 | # Make sure the secret is at least 30 characters and all random, 7 | # no regular words or you'll be exposed to dictionary attacks. 8 | # You can use `rake secret` to generate a secure secret key. 9 | 10 | # Make sure the secrets in this file are kept private 11 | # if you're sharing your code publicly. 12 | 13 | development: 14 | secret_key_base: e8aced332a04b4a222176e590dc8e53958466b898a11450e1768423f0523b00f1314b9002b3f3dc80e05df3aa3171e067aa1c09e5927c5360da6a7b9f50ce8c5 15 | 16 | test: 17 | secret_key_base: 26c73e324d278aa07f042db9508961c1f3058e8a69394ad58efd794118dfcd7f7e34110e5437b661dd0d93271b571f7be75ad7f33a0f21c32b74028b80f60e2d 18 | 19 | # Do not keep production secrets in the repository, 20 | # instead read values from the environment. 21 | production: 22 | secret_key_base: <%= ENV["SECRET_KEY_BASE"] %> 23 | -------------------------------------------------------------------------------- /rails/app/db/seeds.rb: -------------------------------------------------------------------------------- 1 | # This file should contain all the record creation needed to seed the database with its default values. 2 | # The data can then be loaded with the rake db:seed (or created alongside the db with db:setup). 3 | # 4 | # Examples: 5 | # 6 | # cities = City.create([{ name: 'Chicago' }, { name: 'Copenhagen' }]) 7 | # Mayor.create(name: 'Emanuel', city: cities.first) 8 | -------------------------------------------------------------------------------- /rails/app/lib/assets/.keep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/rails/app/lib/assets/.keep -------------------------------------------------------------------------------- /rails/app/lib/tasks/.keep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/rails/app/lib/tasks/.keep -------------------------------------------------------------------------------- /rails/app/log/.keep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/rails/app/log/.keep -------------------------------------------------------------------------------- /rails/app/public/404.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | The page you were looking for doesn't exist (404) 5 | 6 | 55 | 56 | 57 | 58 | 59 |
60 |
61 |

The page you were looking for doesn't exist.

62 |

You may have mistyped the address or the page may have moved.

63 |
64 |

If you are the application owner check the logs for more information.

65 |
66 | 67 | 68 | -------------------------------------------------------------------------------- /rails/app/public/422.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | The change you wanted was rejected (422) 5 | 6 | 55 | 56 | 57 | 58 | 59 |
60 |
61 |

The change you wanted was rejected.

62 |

Maybe you tried to change something you didn't have access to.

63 |
64 |

If you are the application owner check the logs for more information.

65 |
66 | 67 | 68 | -------------------------------------------------------------------------------- /rails/app/public/500.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | We're sorry, but something went wrong (500) 5 | 6 | 55 | 56 | 57 | 58 | 59 |
60 |
61 |

We're sorry, but something went wrong.

62 |
63 |

If you are the application owner check the logs for more information.

64 |
65 | 66 | 67 | -------------------------------------------------------------------------------- /rails/app/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/rails/app/public/favicon.ico -------------------------------------------------------------------------------- /rails/app/public/robots.txt: -------------------------------------------------------------------------------- 1 | # See http://www.robotstxt.org/robotstxt.html for documentation on how to use the robots.txt file 2 | # 3 | # To ban all spiders from the entire site uncomment the next two lines: 4 | # User-agent: * 5 | # Disallow: / 6 | -------------------------------------------------------------------------------- /rails/app/vendor/assets/javascripts/.keep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/rails/app/vendor/assets/javascripts/.keep -------------------------------------------------------------------------------- /rails/app/vendor/assets/stylesheets/.keep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/rails/app/vendor/assets/stylesheets/.keep -------------------------------------------------------------------------------- /results/plot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/results/plot.png -------------------------------------------------------------------------------- /sinatra/app/Gemfile: -------------------------------------------------------------------------------- 1 | source 'https://rubygems.org' 2 | 3 | gem 'sinatra' 4 | gem 'puma' -------------------------------------------------------------------------------- /sinatra/app/Gemfile.lock: -------------------------------------------------------------------------------- 1 | GEM 2 | remote: https://rubygems.org/ 3 | specs: 4 | puma (3.2.0) 5 | rack (1.6.4) 6 | rack-protection (1.5.3) 7 | rack 8 | sinatra (1.4.7) 9 | rack (~> 1.5) 10 | rack-protection (~> 1.4) 11 | tilt (>= 1.3, < 3) 12 | tilt (2.0.2) 13 | 14 | PLATFORMS 15 | ruby 16 | 17 | DEPENDENCIES 18 | puma 19 | sinatra 20 | 21 | BUNDLED WITH 22 | 1.10.6 23 | -------------------------------------------------------------------------------- /sinatra/app/Procfile: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sdogruyol/kemal-showdown/6547a61571af1d273bd9ab0a964b52c597b381fe/sinatra/app/Procfile -------------------------------------------------------------------------------- /sinatra/app/app.rb: -------------------------------------------------------------------------------- 1 | require 'sinatra' 2 | 3 | configure { set :logging, false } 4 | 5 | get '/:title' do 6 | @title = params[:title] 7 | 8 | @members = [ 9 | { name: 'Serdar Dogruyol' }, 10 | { name: 'Fatih Kadir Akin' }, 11 | { name: 'Askin Gedik' }, 12 | { name: 'Ary Borenszweig'} 13 | ] 14 | 15 | erb :index 16 | end 17 | -------------------------------------------------------------------------------- /sinatra/app/config.ru: -------------------------------------------------------------------------------- 1 | require 'bundler' 2 | Bundler.require 3 | 4 | require 'tilt/erb' 5 | 6 | require './app' 7 | run Sinatra::Application -------------------------------------------------------------------------------- /sinatra/app/views/_bio.erb: -------------------------------------------------------------------------------- 1 | Name: <%= member[:name] %> -------------------------------------------------------------------------------- /sinatra/app/views/index.erb: -------------------------------------------------------------------------------- 1 |
2 |

Welcome to Kemal!

3 |

Kemal is a Crystal Web Framework targeting to be crazy fast, scalable and simple.

4 |
5 | 6 |
7 |
8 |

Resources: <%= @title %>

9 | 17 |
18 | 19 |
20 |

Help

21 | 26 | 27 |

Team Members

28 |
    29 | <% for member in @members do %> 30 |
  • 31 | <%= erb :_bio, locals: {member: member} %> 32 |
  • 33 | <% end %> 34 |
35 |
36 | 37 |
38 | Enjoy it! 39 |
40 | --------------------------------------------------------------------------------