<commit_before>module Views where

import Html exposing (Html)
import Html.Events exposing (onClick)
import Html.Attributes exposing (style)
import Signal exposing (Address)
import Graphics.Element as G
import Graphics.Collage exposing (..)
import Text as T
import List as L
import Dict
import Color
import Array
import Debug
import RenderNetwork

import Helpers exposing (getOrFail)
import Types
import EmailTexts exposing (emailTexts)
import GameScreens exposing (..)
import Model exposing (..)

gameButton : Address Action -> Action -> String -> Html
gameButton address action text =
    Html.button
        [
            onClick address action,
            style [ ("background-color", "rgb(94, 5, 135)"),
                    ("color", "white"),
                    ("width", "100px"),
                    ("height", "100px")
                  ]
        ]
        [Html.text text]


renderTitleScreen : Address Action -> Html
renderTitleScreen address =
        let
            titleBackgroundColor = Color.rgb 94 5 135
            titleImage = G.image 666 500 "../game_logo.png"
        in
            Html.div
                []
                [   Html.fromElement <| titleImage,
                    gameButton address (GoToScreen <| MessageScreen 0)  "New Game",
                    gameButton address (GoToScreen <| ChooseLevelScreen)  "Continue"
                ]



renderChooseLevel : Address Action -> Model -> Html
renderChooseLevel address model =
    let
        screenLinkIfUnlocked address (screenType, name) =
            case screenType of
                Message n -> Html.li [onClick address (GoToScreen <| MessageScreen n)] [Html.text name]<commit_msg>direct link to logo due to issue in github.io<commit_after>module Views where

import Html exposing (Html)
import Html.Events exposing (onClick)
import Html.Attributes exposing (style)
import Signal exposing (Address)
import Graphics.Element as G
import Graphics.Collage exposing (..)
import Text as T
import List as L
import Dict
import Color
import Array
import Debug
import RenderNetwork

import Helpers exposing (getOrFail)
import Types
import EmailTexts exposing (emailTexts)
import GameScreens exposing (..)
import Model exposing (..)

gameButton : Address Action -> Action -> String -> Html
gameButton address action text =
    Html.button
        [
            onClick address action,
            style [ ("background-color", "rgb(94, 5, 135)"),
                    ("color", "white"),
                    ("width", "100px"),
                    ("height", "100px")
                  ]
        ]
        [Html.text text]


renderTitleScreen : Address Action -> Html
renderTitleScreen address =
        let
            titleBackgroundColor = Color.rgb 94 5 135
            titleImage = G.image 666 500 "http://neunenak.github.io/assholetransitbureaucrat2015/game_logo.png"
        in
            Html.div
                []
                [   Html.fromElement <| titleImage,
                    gameButton address (GoToScreen <| MessageScreen 0)  "New Game",
                    gameButton address (GoToScreen <| ChooseLevelScreen)  "Continue"
                ]



renderChooseLevel : Address Action -> Model -> Html
renderChooseLevel address model =
    let
        screenLinkIfUnlocked address (screenType, name) =
            case screenType of
                Message n -> Html.li [onClick address (GoToScreen <| MessageScreen n)] [Html.text name]
{'fraction_non_alphanumeric': 0.08415841584158416, 'fraction_numerical': 0.0157251019219569, 'mean_word_length': 2.2193064667291473, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5032274', 'n_tokens_mistral': 975, 'n_tokens_neox': 865, 'n_words': 299}