#22: This isn't even nearly working...

But it's starting to work!
This commit is contained in:
Simon Brooke 2017-03-16 08:22:07 +00:00
parent 036c84972a
commit a46f55e50e
3 changed files with 46 additions and 18 deletions

View file

@ -160,7 +160,7 @@ th {
#main-container{ #main-container{
} }
#back-link { #back-link, .back-link {
min-width: 8em; min-width: 8em;
padding: 0.25em 1em; padding: 0.25em 1em;
background-color: gray; background-color: gray;
@ -170,7 +170,7 @@ th {
border-bottom-right-radius: 0.5em; border-bottom-right-radius: 0.5em;
} }
#back-link:hover, #back-link:active { #back-link:hover, #back-link:active, .back-link:hover, .back-link:active, {
text-decoration: none; text-decoration: none;
background-color: rgb(160, 160, 160); background-color: rgb(160, 160, 160);
} }

View file

@ -3,9 +3,27 @@
<head> <head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8"> <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<title>Welcome to YouYesYet</title> <link rel="stylesheet" type="text/css" href="css/yyy-static.css" />
<link href="https://fonts.googleapis.com/css?family=Archivo+Black|Archivo+Narrow" rel="stylesheet"/>
<title>You Yes Yet?</title>
</head> </head>
<body> <body>
<header>
<div id="nav">
<img id="nav-icon" src="img/threelines.png" alt="Menu"/>
<menu id="nav-menu" class="nav">
<li class=""><a href="index.html">Home</a></li>
<li class=""><a href="library.html">Library</a></li>
<li class=""><a href="register.html">Register</a></li>
<li class=""><a href="login.html">Login</a></li>
<li class=""><a href="about.html">About</a></li>
</menu>
</div>
<h1>
You yes yet?
</h1>
</header>
<div id="app"> <div id="app">
<div class="container-fluid"> <div class="container-fluid">
@ -29,10 +47,6 @@
</div> </div>
<!-- scripts and styles --> <!-- scripts and styles -->
{% script "/vendor/leaflet/dist/leaflet.js" %}
{% style "/assets/bootstrap/css/bootstrap.min.css" %}
{% style "/assets/font-awesome/css/font-awesome.min.css" %}
{% style "/css/screen.css" %}
<script type="text/javascript"> <script type="text/javascript">
var context = "{{servlet-context}}"; var context = "{{servlet-context}}";

View file

@ -27,29 +27,43 @@
{:on-click #(swap! collapsed? not)} "☰"] {:on-click #(swap! collapsed? not)} "☰"]
[:div.collapse.navbar-toggleable-xs [:div.collapse.navbar-toggleable-xs
(when-not @collapsed? {:class "in"}) (when-not @collapsed? {:class "in"})
[:a.navbar-brand {:href "#/"} "youyesyet"] [:a.navbar-brand {:href "#/"} "You yes yet?"]
[:ul.nav.navbar-nav [:ul.nav.navbar-nav
[nav-link "#/" "Home" :home collapsed?] [nav-link "#/" "Home" :home collapsed?]
[nav-link "#/map" "Map" :home collapsed?] [nav-link "#/map" "Map" :home collapsed?]
[nav-link "#/about" "About" :about collapsed?]]]])) [nav-link "#/about" "About" :about collapsed?]]]]))
(defn back-link []
[:div.back-link-container {:id ":div.back-link-container"}
[:a {:href "javascript:history.back()" :id "back-link"} "Back"]])
(defn big-link [text target]
[:div.big-link-container
[:a.big-link {:href target} text]])
(defn about-page [] (defn about-page []
[:div.container [:div.container {:id "main-container"}
(back-link)
(big-link "Map" "#/map")
[:div.row [:div.row
[:div.col-md-12 [:div.col-md-12
"this is the story of youyesyet... work in progress"]]]) "this is the story of youyesyet... work in progress"]]])
(defn home-page [] (defn home-page []
[:div.container [:div.container {:id "main-container"}
(back-link)
(big-link "Map" "#/map")
(big-link "About" "#/about")
[:div.jumbotron [:div.jumbotron
[:h1 "Welcome to youyesyet"] [:h1 "Welcome to youyesyet"]
[:p "Time to start building your site!"] [:p "Time to start building your site!"]
[:p [:a.btn.btn-primary.btn-lg {:href "http://luminusweb.net"} "Learn more »"]]] [:p [:a.btn.btn-primary.btn-lg {:href "http://luminusweb.net"} "Learn more »"]]]])
(when-let [docs @(rf/subscribe [:docs])] ;; (when-let [docs @(rf/subscribe [:docs])]
[:div.row ;; [:div.row
[:div.col-md-12 ;; [:div.col-md-12
[:div {:dangerouslySetInnerHTML ;; [:div {:dangerouslySetInnerHTML
{:__html (md->html docs)}}]]])]) ;; {:__html (md->html docs)}}]]])])
(defn map-page [] (defn map-page []
(maps/map-div)) (maps/map-div))