Skip to content
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ The whole thing is completely free to read online, but the original is also avai

## TODOs:
- [ ] refactor web code
- [ ] make mobile-friendly
- [x] make content mobile-friendly
- [ ] make homepage mobile-friendly
- [x] prepare "content edit request" interface on GitHub
- [ ] add exercises
- [ ] update (just overall, the outdated parts)
Expand Down
3 changes: 2 additions & 1 deletion docs/a-fistful-of-monads.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>A Fistful of Monads - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
45 changes: 41 additions & 4 deletions docs/assets/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ h1 {
font-family:georgia, Arial, serif;
margin-bottom:15px;
font-weight:normal;
overflow-wrap:break-word;
hyphens:auto;
}
@media screen and (max-width:400px) {
h1 {
font-size:40px;
line-height:40px;
}
}
h2 {
font-size:20px;
Expand Down Expand Up @@ -43,17 +51,24 @@ em {
list-style-type:disc;
margin:25px 25px;
}
img {
/* If width is limited by max-width, scale height proportionally */
height:auto;
}
img.right {
float: right;
margin:10px;
max-width:40%;
}
img.left {
float: left;
margin:10px;
max-width:40%;
}
img.center {
margin:10px auto 25px auto;
display:block;
max-width:100%;
}
pre.code {
color:white;
Expand Down Expand Up @@ -100,15 +115,22 @@ pre.code {
color:black;
}
.fixed {
white-space:nowrap;
font-family:Consolas, "Courier New", monospace;
background-color:#ddd;
font-weight:normal;
padding:0px 3px;
font-weight:bold;
/* Allow inline code to wrap if necessary */
/* These rules were based off the CSS used on the Stack Exchange website */
white-space-collapse:preserve;
overflow-wrap:break-word;
text-wrap:wrap;
/* Rounded corners help user connect two parts of one code snippet wrapped across lines */
border-radius:4px;
}
#content {
width:800px;
/* For narrow viewports, the content width will be 90% of the viewport width */
width:min(800px, 90vw);
margin:0px auto;
}
.introcontent {
Expand All @@ -125,8 +147,8 @@ pre.code {
font-family:arial,serif;
font-size:24px;
padding-left:25px;
margin:0px;
color:#408156 ;
margin:0px;
color:#408156;
margin-bottom:25px;
}
.chapters > li {
Expand Down Expand Up @@ -179,6 +201,21 @@ pre.code {
display:table-cell;
width:33%;
}
/* For narrow viewports, let navigation links split to separate lines */
@media screen and (max-width:300px) {
.footdiv {
display:unset;
}
.footdiv ul {
display:unset;
margin:0 25px 0 0 !important;
}
.footdiv ul li {
display:block;
width:unset;
}
}

.prevlink {
padding-left:20px;
background-image:url(https://s3.amazonaws.com/lyah/prv.png);
Expand Down
3 changes: 2 additions & 1 deletion docs/chapters.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Chapters - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/faq.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>FAQ - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/for-a-few-monads-more.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>For a Few Monads More - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/functionally-solving-problems.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Functionally Solving Problems - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/functors-applicative-functors-and-monoids.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Functors, Applicative Functors and Monoids - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/higher-order-functions.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Higher Order Functions - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/input-and-output.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Input and Output - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/introduction.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Introduction - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/making-our-own-types-and-typeclasses.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Making Our Own Types and Typeclasses - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/modules.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Modules - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/recursion.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Recursion - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/starting-out.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Starting Out - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
45 changes: 41 additions & 4 deletions docs/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ h1 {
font-family:georgia, Arial, serif;
margin-bottom:15px;
font-weight:normal;
overflow-wrap:break-word;
hyphens:auto;
}
@media screen and (max-width:400px) {
h1 {
font-size:40px;
line-height:40px;
}
}
h2 {
font-size:20px;
Expand Down Expand Up @@ -43,17 +51,24 @@ em {
list-style-type:disc;
margin:25px 25px;
}
img {
/* If width is limited by max-width, scale height proportionally */
height:auto;
}
img.right {
float: right;
margin:10px;
max-width:40%;
}
img.left {
float: left;
margin:10px;
max-width:40%;
}
img.center {
margin:10px auto 25px auto;
display:block;
max-width:100%;
}
pre.code {
color:white;
Expand Down Expand Up @@ -100,15 +115,22 @@ pre.code {
color:black;
}
.fixed {
white-space:nowrap;
font-family:Consolas, "Courier New", monospace;
background-color:#ddd;
font-weight:normal;
padding:0px 3px;
font-weight:bold;
/* Allow inline code to wrap if necessary */
/* These rules were based off the CSS used on the Stack Exchange website */
white-space-collapse:preserve;
overflow-wrap:break-word;
text-wrap:wrap;
/* Rounded corners help user connect two parts of one code snippet wrapped across lines */
border-radius:4px;
}
#content {
width:800px;
/* For narrow viewports, the content width will be 90% of the viewport width */
width:min(800px, 90vw);
margin:0px auto;
}
.introcontent {
Expand All @@ -125,8 +147,8 @@ pre.code {
font-family:arial,serif;
font-size:24px;
padding-left:25px;
margin:0px;
color:#408156 ;
margin:0px;
color:#408156;
margin-bottom:25px;
}
.chapters > li {
Expand Down Expand Up @@ -179,6 +201,21 @@ pre.code {
display:table-cell;
width:33%;
}
/* For narrow viewports, let navigation links split to separate lines */
@media screen and (max-width:300px) {
.footdiv {
display:unset;
}
.footdiv ul {
display:unset;
margin:0 25px 0 0 !important;
}
.footdiv ul li {
display:block;
width:unset;
}
}

.prevlink {
padding-left:20px;
background-image:url(https://s3.amazonaws.com/lyah/prv.png);
Expand Down
3 changes: 2 additions & 1 deletion docs/syntax-in-functions.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Syntax in Functions - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/types-and-typeclasses.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Types and Typeclasses - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
3 changes: 2 additions & 1 deletion docs/zippers.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"https://www.w3.org/TR/html4/strict.dtd">
<html>
<html lang="en">
<head>
<title>Zippers - Learn You a Haskell for Great Good!</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<base href="">
<style type="text/css">
@import url('reset.css');
Expand Down
Loading