From 24f8767278c7aaefde0dc6f0a4da3cc691431222 Mon Sep 17 00:00:00 2001 From: Akshay Date: Wed, 25 Nov 2020 17:09:26 +0530 Subject: add license notice, links to source and license in footer --- src/Views.elm | 40 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 38 insertions(+), 2 deletions(-) (limited to 'src/Views.elm') diff --git a/src/Views.elm b/src/Views.elm index b54fc93..3a8afed 100644 --- a/src/Views.elm +++ b/src/Views.elm @@ -1,3 +1,21 @@ +{- + - This file is part of `typers`. + - + - `typers` is free software: you can redistribute it and/or modify + - it under the terms of the GNU Affero Public License as published by + - the Free Software Foundation, either version 3 of the License, or + - (at your option) any later version. + - + - `typers` is distributed in the hope that it will be useful, + - but WITHOUT ANY WARRANTY; without even the implied warranty of + - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + - GNU Affero Public License for more details. + - + - You should have received a copy of the GNU Affero Public License + - along with `typers`. If not, see . +-} + + module Views exposing (..) import Array exposing (..) @@ -5,9 +23,9 @@ import Base exposing (..) import Css exposing (..) import Html import Html.Styled exposing (..) -import Html.Styled.Attributes exposing (css) +import Html.Styled.Attributes exposing (css, href) import Html.Styled.Events exposing (onClick) -import Styles exposing (styledButton, styledListItem, styledUnorderedList) +import Styles exposing (..) import Time exposing (Posix, toHour, toMinute, toSecond, utc) import Utils exposing (diffDuration, isNothing, wordCountWith) @@ -122,3 +140,21 @@ viewStats model = in p [] [ text (Maybe.withDefault "" stats) ] + + +viewFooter : Html Msg +viewFooter = + let + footerItems = + [ ( "src", "https://git.peppe.rs/web/typers/about" ) + , ( "license", "https://git.peppe.rs/web/typers/tree/COPYING" ) + ] + in + styledUnorderedList [] + (List.map + (\( inner, hr ) -> + styledListItem [] + [ styledExternalLink [ href hr ] [ text inner ] ] + ) + footerItems + ) -- cgit v1.2.3