Skip to content

Commit

Permalink
added cable car icon
Browse files Browse the repository at this point in the history
  • Loading branch information
fterrier committed Feb 10, 2015
1 parent b1f97ba commit 0853aa6
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 5 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ pom.xml.asc
/resources/public/js
/resources/public/css
.repl*
.DS_Store
Binary file added resources/public/images/cable-car.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 12 additions & 1 deletion src/less/styles.less
Original file line number Diff line number Diff line change
Expand Up @@ -550,10 +550,21 @@ a .link-icon a.link-icon, a:hover .link-icon, a.link-icon:hover, a:visited .link
.fa.fa-tram {
background: transparent url('/images/tram.png') no-repeat 0 0px;
background-size: 1.25em 1.25em;
position: absolute;
top: 0.2em;
right: 0.05em;
}

.fa.fa-cable-car {
background: transparent url('/images/cable-car.png') no-repeat 0 0px;
background-size: 0.75em 1em;
top: 0.25em;
right: -0.3em;
}

.fa.fa-tram, .fa.fa-cable-car {
position: absolute;
height: 1.2em;
width: 1em;
}

}
8 changes: 4 additions & 4 deletions src/tramboard_clj/script/tram.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -277,16 +277,16 @@
"tram" "fa-tram"
"subway" "fa-train"
"rack-train" "fa-subway"
"cable-car" "fa-subway"
"cable-car" "fa-cable-car"
"bus" "fa-bus"
"train" "fa-subway"
"taxi" "fa-taxi"
"boat" "fa-ship"

"train"))
icon (dom/i #js {:className (str "fa " (map-transport-icon type))})]
(if (= type "tram")
(dom/span #js {:className "span-fa"} icon (dom/span #js {:className "hidden"} "tram"))
(if (or (= type "tram") (= type "cable-car"))
(dom/span #js {:className "span-fa"} icon (dom/span #js {:className "hidden"} "transport icon"))
icon)))))

(defn arrival-row [{:keys [arrival current-view current-state] :as app} owner]
Expand Down Expand Up @@ -728,7 +728,7 @@
(strong "tram") " " (om/build transport-icon "tram") ", "
(strong "train") " " (om/build transport-icon "train") ", "
(strong "boat") " " (om/build transport-icon "boat") " or "
(strong "cable car") ".")
(strong "cable car") " " (om/build transport-icon "cable-car") ".")
(dom/div nil "Enter any stop in "
(dom/div #js {:className "phoca-flagbox"}
(dom/span #js {:className "phoca-flag ch"} nil) )
Expand Down

0 comments on commit 0853aa6

Please sign in to comment.