summaryrefslogtreecommitdiff
path: root/src/toys/godel/index.html
blob: 678d56a2bdde6ea71787a0f5e5f7781c72054bd2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <link rel="stylesheet" href="https://adelie.liz.coffee/bundle.css">
  <title>Gödel Numbering</title>
</head>
<body>
  <main>
    <article>
      <h3>Gödel Numbering</h3>
      <p class="muted">"Compile" L into JS and explore the source Gödel encodings.</p>

      <section>
        <div>
          <h4>L Source</h4>
          <div id="source-editor" class="code-editor-container mb-sm" aria-label="L source code"></div>
          <div>
            <button id="compile-btn" class="primary">Compile</button>
            <button id="copy-btn">Copy Share Link</button>
          </div>
          <span id="compile-status" class="status-text muted"></span>
        </div>
      </section>

      <section class="mt-sm">
        <div>
          <h4>"Compiled" JS</h4>
          <div id="compiled-editor" class="code-editor-container mb-sm" aria-label="Compiled JavaScript"></div>
          <div class="button-group">
            <button id="eval-btn">Eval</button>
          </div>
          <span id="eval-status" class="status-text muted"></span>
        </div>
      </section>

      <section class="mt-sm">
        <h4>Gödel Sequence</h4>
        <pre id="godel-sequence">Compile to view the Gödel sequence.</pre>
        <div>
          <button id="compute-godel-btn">Compute Gödel Number</button>
        </div>
        <pre id="godel-number"></pre>
      </section>
    </article>
  </main>

  <script src="https://adelie.liz.coffee/bundle.js"></script>
  <script src="https://adelie.liz.coffee/adelie-editor.js"></script>
  <script type="module" src="./js/main.js"></script>
</body>
</html>