Skip to content

Commit 82e95b4

Browse files
committed
Update NRI LOC and add PivotalTracker with nice quote
1 parent d9f9af0 commit 82e95b4

File tree

3 files changed

+134
-35
lines changed

3 files changed

+134
-35
lines changed

assets/logos/pivotaltracker.svg

Lines changed: 1 addition & 0 deletions
Loading

assets/style.css

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ a:hover {
116116
}
117117
}
118118

119+
119120
/* examples */
120121

121122
.examples li {
@@ -133,6 +134,77 @@ a:hover {
133134
}
134135

135136

137+
/* users */
138+
139+
.featured-user {
140+
max-width: 600px;
141+
padding-top: 40px;
142+
padding-bottom: 20px;
143+
margin-left: auto;
144+
margin-right: auto;
145+
}
146+
147+
.featured-user .quote {
148+
background: #eeeeee;
149+
padding: 10px 30px;
150+
border-radius: 10px;
151+
position: relative;
152+
color: #b4b4b4;
153+
font-size: 20px;
154+
color: #5A6378;
155+
quotes: "\201C""\201D""\2018""\2019"
156+
}
157+
158+
.featured-user .quote p:first-of-type:before {
159+
content: open-quote;
160+
font-size: 4em;
161+
line-height: 0.1em;
162+
margin-right: 0.25em;
163+
vertical-align: -0.4em;
164+
}
165+
166+
.featured-user .quote:after {
167+
content: "";
168+
position: absolute;
169+
bottom: -20px;
170+
right: 130px;
171+
border-width: 20px 20px 0;
172+
border-style: solid;
173+
border-color: #eeeeee transparent;
174+
display: block;
175+
width: 0;
176+
}
177+
178+
.featured-user .attribution {
179+
height: 100px;
180+
}
181+
182+
.featured-user .attribution-logo {
183+
float: right;
184+
}
185+
186+
@media (max-width: 500px) {
187+
.featured-user .attribution-logo {
188+
display: none;
189+
}
190+
}
191+
192+
.featured-user .attribution-author {
193+
width: 300px;
194+
display: block;
195+
float: right;
196+
font-size: 18px;
197+
color: #5A6378;
198+
text-align: center;
199+
padding-top: 24px
200+
}
201+
202+
.featured-user .attribution-author p {
203+
padding: 0;
204+
margin: 0;
205+
}
206+
207+
136208
/* top bar */
137209

138210

src/pages/home.elm

Lines changed: 61 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ features =
113113
, Feature "No Runtime Exceptions" 200 "/assets/home/errors.png" "/blog/compilers-as-assistants" <|
114114
[ text "Unlike hand-written JavaScript, Elm code does not produce runtime exceptions in practice. Instead, Elm uses type inference to detect problems during compilation and give "
115115
, a [href "/blog/compilers-as-assistants"] [text "friendly hints"]
116-
, text ". This way problems never make it to your users. NoRedInk has 36k lines of Elm, and after more than a year in production, it still has not produced a single runtime exception."
116+
, text ". This way problems never make it to your users. NoRedInk has 80k+ lines of Elm, and after more than a year in production, it still has not produced a single runtime exception."
117117
]
118118
, Feature "Great Performance" 320 "/assets/home/benchmark.png" "/blog/blazing-fast-html-round-two" <|
119119
[ text "Elm has its own virtual DOM implementation, designed for simplicity and speed. All values are immutable in Elm, and "
@@ -230,26 +230,37 @@ userSection : Html msg
230230
userSection =
231231
section [class "home-section"]
232232
[ h1 [] [text "Featured Users"]
233-
, p [class "home-paragraph"]
234-
[ text "Definitely check out the links for "
235-
, a [href "http://tech.noredink.com/post/129641182738/building-a-live-validated-signup-form-in-elm"] [text "NoRedInk"]
236-
, text ", "
237-
, a [href "http://www.gizra.com/content/thinking-choosing-elm/"] [text "Gizra"]
238-
, text ", and "
239-
, a [href "http://futurice.com/blog/elm-in-the-real-world"] [text "Futurice"]
240-
, text " to learn more about how and why they are using Elm. If you want to join them and use Elm at work, definitely follow "
241-
, a [href "/blog/how-to-use-elm-at-work"] [text "this advice"]
242-
, text " and do it gradually. Elm is all about reducing risk, even in adoption!"
233+
, div [ class "featured-user" ]
234+
[ div [ class "quote" ]
235+
[ p [] [ text "We’ve had zero run-time failures, the filesize is ridiculously small, and it runs faster than anything else in our code base. We’ve also had fewer bugs... " ]
236+
, p [] [ text "To sum it up, our manager has mandated that all new code be written in Elm." ]
237+
]
238+
, div [ class "attribution" ]
239+
[ div [ class "attribution-author" ]
240+
[ p [] [ text "Jeff Schomay" ]
241+
, p [] [ a [ href "https://www.pivotaltracker.com/blog/Elm-pivotal-tracker/" ] [ text "PivotalTracker Blog" ] ]
242+
]
243+
, a [ class "attribution-logo"
244+
, href "https://www.pivotaltracker.com"
245+
]
246+
[ div
247+
[ style
248+
[ "width" => "200px"
249+
, "height" => "100px"
250+
, "background-image" => ("url('" ++ toLogoSrc "PivotalTracker" "svg" ++ "')")
251+
, "background-repeat" => "no-repeat"
252+
, "background-position" => "center"
253+
]
254+
]
255+
[]
256+
]
257+
]
243258
]
244259
, fluidList 200 3
245260
[ company
246261
"NoRedInk"
247262
"http://tech.noredink.com/post/129641182738/building-a-live-validated-signup-form-in-elm"
248263
"png"
249-
, company
250-
"CircuitHub"
251-
"https://circuithub.com/"
252-
"png"
253264
, company
254265
"Carfax"
255266
"https://www.carfax.com/"
@@ -262,13 +273,17 @@ userSection =
262273
"Gizra"
263274
"http://www.gizra.com/content/thinking-choosing-elm/"
264275
"png"
276+
, company
277+
"Prezi"
278+
"https://prezi.com/"
279+
"png"
265280
, company
266281
"TruQu"
267282
"https://truqu.com/"
268283
"png"
269284
, company
270-
"Prezi"
271-
"https://prezi.com/"
285+
"CircuitHub"
286+
"https://circuithub.com/"
272287
"png"
273288
, company
274289
"Beautiful Destinations"
@@ -278,26 +293,37 @@ userSection =
278293
]
279294

280295

296+
company : String -> String -> String -> List (Html msg)
281297
company name website extension =
298+
[ toLogo name website extension ]
299+
300+
301+
toLogo : String -> String -> String -> Html msg
302+
toLogo name website extension =
303+
let
304+
imgSrc =
305+
toLogoSrc name extension
306+
in
307+
a [ href website ]
308+
[ div
309+
[ style
310+
[ "width" => "200px"
311+
, "height" => "100px"
312+
, "background-image" => ("url('" ++ imgSrc ++ "')")
313+
, "background-repeat" => "no-repeat"
314+
, "background-position" => "center"
315+
]
316+
]
317+
[]
318+
]
319+
320+
321+
toLogoSrc : String -> String -> String
322+
toLogoSrc name extension =
282323
let
283324
lowerName =
284325
String.toLower name
285-
286-
imgSrc =
287-
"/assets/logos/"
288-
++ String.map (\c -> if c == ' ' then '-' else c) lowerName
289-
++ "." ++ extension
290326
in
291-
[ a [ href website ]
292-
[ div
293-
[ style
294-
[ "width" => "200px"
295-
, "height" => "100px"
296-
, "background-image" => ("url('" ++ imgSrc ++ "')")
297-
, "background-repeat" => "no-repeat"
298-
, "background-position" => "center"
299-
]
300-
]
301-
[]
302-
]
303-
]
327+
"/assets/logos/"
328+
++ String.map (\c -> if c == ' ' then '-' else c) lowerName
329+
++ "." ++ extension

0 commit comments

Comments
 (0)