Skip to content
This repository was archived by the owner on Nov 5, 2024. It is now read-only.

Commit 3122e3f

Browse files
committed
init
1 parent 8e6b1bb commit 3122e3f

File tree

10 files changed

+204
-11
lines changed

10 files changed

+204
-11
lines changed

.DS_Store

6 KB
Binary file not shown.

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# docs
2+
This is the website code for the p-lang docs!

book.toml

Lines changed: 0 additions & 6 deletions
This file was deleted.

src/SUMMARY.md

Lines changed: 0 additions & 3 deletions
This file was deleted.

src/css/colors.css

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
:root {
2+
--background-dark: #121212
3+
}

src/css/main.css

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
* {
2+
margin: 0;
3+
padding: 0;
4+
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
5+
}
6+
7+
.page-content {
8+
margin-left: .5rem;
9+
margin-top: 1.75rem;
10+
width: 100%
11+
}
12+
13+
.body {
14+
display: flex;
15+
flex-direction: row;
16+
padding: 1.5rem;
17+
padding-left: .5rem;
18+
}
19+
20+
code {
21+
font-family: Monaco, monospace;
22+
line-height: 100%;
23+
background-color: #f0f0f0;
24+
padding: 0.4em;
25+
letter-spacing: -0.05em;
26+
word-break: normal;
27+
border-radius: 8px;
28+
}
29+
30+
.side-bar {
31+
width: 350px;
32+
height: 100vh;
33+
overflow-y: hidden;
34+
overflow-x: auto;
35+
}
36+
37+
li>a {
38+
color: rgb(0, 122, 128)
39+
}
40+
41+
.current {
42+
color: rgb(43, 0, 128)
43+
}
44+
.currentSub {
45+
color: rgb(128, 0, 105)
46+
}
47+
48+
.side-bar > a > .icon {
49+
width: 150px;
50+
}
51+
52+
.webfooter{
53+
position: fixed;
54+
bottom: 0;
55+
margin: 0.4em;
56+
}

src/getting-started.html

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
6+
<title>Plang Documents - Introduction</title>
7+
<link rel="stylesheet" href="css/colors.css">
8+
<link rel="stylesheet" href="css/main.css">
9+
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
10+
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL" crossorigin="anonymous"></script>
11+
</head>
12+
<body>
13+
<div class="body">
14+
<div class="side-bar">
15+
<a href="index.html">
16+
<img
17+
class="icon"
18+
src="https://avatars.githubusercontent.com/u/146694713?s=400&u=4e01b5afefbf7e40641702e5cbdf785ff183fe35&v=4"
19+
alt="P Icon"
20+
/></a>
21+
<ul>
22+
<li><a href="index.html">Introduction</a></li>
23+
<li><a class="current" href="getting-started.html">Getting Started</a></li>
24+
<ul>
25+
<li><a href="getting-started.html#installing">Installing</a></li>
26+
<li><a href="getting-started.html#pint-first-time">Running pint for the first time</a></li>
27+
</ul>
28+
</ul>
29+
</div>
30+
<div class="page-content">
31+
<h1 class="page-title" id="getting-started">Getting Started</h1>
32+
<p>Simple tutorial on how to get started</p>
33+
<div class="accordion">
34+
<div class="accordion-item" id="installing">
35+
<h2 class="accordion-header" id="headingOne">
36+
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne" aria-expanded="true" aria-controls="collapseOne">
37+
Installing
38+
</button>
39+
</h2>
40+
<div id="collapseOne" class="accordion-collapse collapse show" aria-labelledby="headingOne">
41+
<div class="accordion-body">
42+
<strong>This is your first step in the tutorial</strong> To get started, make sure you have installed npm. Check it by running: <code style="margin-right: 5px">npm -v</code> If that ran successfully, you can continue.<br>Now simply run: <code>npm i -g @p-lang/plang</code>
43+
</div>
44+
</div>
45+
</div>
46+
<div class="accordion-item" id="pint-first-time">
47+
<h2 class="accordion-header" id="headingTwo">
48+
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo" aria-expanded="true" aria-controls="collapseTwo">
49+
Running pint for the first time
50+
</button>
51+
</h2>
52+
<div id="collapseTwo" class="accordion-collapse collapse" aria-labelledby="headingTwo">
53+
<div class="accordion-body">
54+
Now you can run a special command called <strong>pint</strong>. This is the P interpreter, aka the program you will run your P programs with. <br>You can also now use the prepl (P read-eval-proccess loop) to run P directly in your terminal to start the repl just run <code>pint</code> with no arguments to run a single file using <strong>pint</strong> run:<br><code>pint &lt;filepath&gt;</code><br><br>Congrats you have successfully ran pint for the first time ever!
55+
</div>
56+
</div>
57+
</div>
58+
</div>
59+
</div>
60+
</div>
61+
<footer class="webfooter">&copy; Plang 2023</footer>
62+
<script src="script/main.js"></script>
63+
</body>
64+
</html>

src/index.html

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
6+
<title>Plang Documents - Introduction</title>
7+
<link rel="stylesheet" href="css/colors.css" />
8+
<link rel="stylesheet" href="css/main.css" />
9+
<link
10+
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css"
11+
rel="stylesheet"
12+
integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN"
13+
crossorigin="anonymous"
14+
/>
15+
<script
16+
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js"
17+
integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL"
18+
crossorigin="anonymous"
19+
></script>
20+
</head>
21+
<body>
22+
<div class="body">
23+
<div class="side-bar">
24+
<a href="index.html">
25+
<img
26+
class="icon"
27+
src="https://avatars.githubusercontent.com/u/146694713?s=400&u=4e01b5afefbf7e40641702e5cbdf785ff183fe35&v=4"
28+
alt="P Icon"
29+
/></a>
30+
<ul>
31+
<li>
32+
<a class="current" href="index.html">Introduction</a>
33+
</li>
34+
<li>
35+
<a href="getting-started.html">Getting Started</a>
36+
</li>
37+
<ul>
38+
<li><a href="getting-started.html#installing">Installing</a></li>
39+
<li>
40+
<a href="getting-started.html#pint-first-time"
41+
>Running pint for the first time</a
42+
>
43+
</li>
44+
</ul>
45+
</ul>
46+
</div>
47+
<div class="page-content">
48+
<h1 class="page-title" id="Introduction">Introduction</h1>
49+
<p>
50+
P is a statically-typed, interpreted programming language written in
51+
100% TypeScript.
52+
</p>
53+
<h2>Links:</h2>
54+
<ul>
55+
<li>
56+
<a href="https://github.com/p-programming-language">Github</a>
57+
</li>
58+
<li>
59+
<a href="https://github.com/p-programming-language/plang"
60+
>Github Repo</a
61+
>
62+
</li>
63+
</ul>
64+
</div>
65+
</div>
66+
<footer class="webfooter">&copy; Plang 2023</footer>
67+
<script src="script/main.js"></script>
68+
</body>
69+
</html>

src/intro.md

Lines changed: 0 additions & 2 deletions
This file was deleted.

src/script/main.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
const installingLink = document.querySelector('ul li a[href*="#installing"]');
2+
3+
if (installingLink) {
4+
const currentURL = window.location.href;
5+
if (currentURL.includes('getting-started.html#installing')) {
6+
installingLink.classList.add('currentSub');
7+
} else if (currentURL.includes('getting-started.html#pint-first-time')) {
8+
installingLink.classList.add('currentSub');
9+
}
10+
}

0 commit comments

Comments
 (0)