Skip to content

Commit 9b774ba

Browse files
committed
Add github star
1 parent c1ef388 commit 9b774ba

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

src/Main.hs

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ import qualified Data.Map.Strict as M
1616
-----------------------------------------------------------------------------
1717
import Miso hiding (on)
1818
import Miso.Lens
19+
import qualified Miso.Style as CSS
1920
-----------------------------------------------------------------------------
2021
import WebSocket
2122
-----------------------------------------------------------------------------
@@ -60,9 +61,24 @@ app = (component emptyModel update_ appView)
6061
update_ NoOp =
6162
pure ()
6263
-----------------------------------------------------------------------------
64+
githubStar :: View model action
65+
githubStar = iframe_
66+
[ title_ "GitHub"
67+
, height_ "30"
68+
, width_ "170"
69+
, textProp "scrolling" "0"
70+
, textProp "frameborder" "0"
71+
, src_
72+
"https://ghbtns.com/github-btn.html?user=haskell-miso&repo=miso-websocket&type=star&count=true&size=large"
73+
]
74+
[]
75+
-----------------------------------------------------------------------------
6376
appView :: Model -> View Model Action
6477
appView m =
6578
div_
79+
[]
80+
[ githubStar
81+
, div_
6682
[ class_ "container"
6783
]
6884
[ h1_
@@ -87,4 +103,5 @@ appView m =
87103
| connId <- IS.toList (m ^. connections)
88104
]
89105
]
106+
]
90107
-----------------------------------------------------------------------------

0 commit comments

Comments
 (0)