1
1
mirror of https://github.com/anoma/juvix.git synced 2024-09-11 16:26:33 +03:00
Commit Graph

16 Commits

Author SHA1 Message Date
Dimitris Apostolou
d6d21a22e3
Fix typos (#2573) 2024-01-08 13:27:18 +01:00
Jonathan Cubides
2b566e0870
Remove unused files (#2398)
Merge after
- #2397

---------

Co-authored-by: Łukasz Czajka <62751+lukaszcz@users.noreply.github.com>
2023-09-28 14:20:19 +02:00
Jan Mas Rovira
9dd9b50517
Add macchiato html theme (#2323)
Cute theme: https://github.com/catppuccin/catppuccin#-palette
2023-09-04 21:07:53 +02:00
Jan Mas Rovira
340f1927ae
Generate html documentation for alias and fixity definitions (#2327)
![image](https://github.com/anoma/juvix/assets/5511599/91eb9f54-370b-4036-8aea-a39b1008b7f0)


![image](https://github.com/anoma/juvix/assets/5511599/abc0100b-5f7e-444e-adec-867707d03997)
2023-08-31 15:07:38 +01:00
Jan Mas Rovira
92714b8254
Add css colors ju-comment and ju-judoc (#2321)
This pr adds colors for comments and judoc for the html backend
2023-08-30 15:55:15 +02:00
Łukasz Czajka
eebe961321
User-friendly operator declaration syntax (#2270)
* Closes #1964 

Adds the possibility to define operator fixities. They live in a
separate namespace. Standard library defines a few in
`Stdlib.Data.Fixity`:
```

syntax fixity rapp {arity: binary, assoc: right};
syntax fixity lapp {arity: binary, assoc: left, same: rapp};
syntax fixity seq {arity: binary, assoc: left, above: [lapp]};

syntax fixity functor {arity: binary, assoc: right};

syntax fixity logical {arity: binary, assoc: right, above: [seq]};
syntax fixity comparison {arity: binary, assoc: none, above: [logical]};

syntax fixity pair {arity: binary, assoc: right};
syntax fixity cons {arity: binary, assoc: right, above: [pair]};

syntax fixity step {arity: binary, assoc: right};
syntax fixity range {arity: binary, assoc: right, above: [step]};

syntax fixity additive {arity: binary, assoc: left, above: [comparison, range, cons]};
syntax fixity multiplicative {arity: binary, assoc: left, above: [additive]};

syntax fixity composition {arity: binary, assoc: right, above: [multiplicative]};
```

The fixities are identifiers in a separate namespace (different from
symbol and module namespaces). They can be exported/imported and then
used in operator declarations:
```
import Stdlib.Data.Fixity open;

syntax operator && logical;
syntax operator || logical;
syntax operator + additive;
syntax operator * multiplicative;
```
2023-08-09 18:15:51 +02:00
Veronika Romashkina
9840878413
Remove Subtree sections, all collapse all button (#2213)
- Resolves #2198

<img width="700" alt="Screenshot 2023-06-20 at 14 09 21"
src="https://github.com/anoma/juvix/assets/8126674/f5ebb89e-5f2a-41fe-8495-13b1ec4aea02">
2023-06-23 11:31:59 +01:00
Jonathan Cubides
22027f137c
Refactor html command with extra options (#1725)
This PR redefines the `html` command unifying our previous subcommands
for the HTML backend. You should use the command in the following way to
obtain the same results as before:

- `juvix html src.juvix` -> `juvix html src.juvix --only-source`
- `juvix dev doc src.juvix` -> `juvix html src.juvix`

- Other fixes here include the flag `--non-recursive`, which replaces
the previous behavior in that we now generate all the HTML recursively
by default.
- The flag `--no-print-metadata` is now called `--no-footer` 
- Also, another change introduced by this PR is asset handling; for
example, with our canonical Juvix program,
the new output is organized as follows.

```
juvix html HelloWorld.juvix --only-source && tree html/
Copying assets files to test/html/assets
Writing HelloWorld.html
html/
├── assets
│   ├── css
│   │   ├── linuwial.css
│   │   ├── source-ayu-light.css
│   │   └── source-nord.css
│   ├── images
│   │   ├── tara-magicien.png
│   │   ├── tara-seating.svg
│   │   ├── tara-smiling.png
│   │   ├── tara-smiling.svg
│   │   ├── tara-teaching.png
│   │   └── tara-teaching.svg
│   └── js
│       ├── highlight.js
│       └── tex-chtml.js
└── HelloWorld.html
├── Stdlib.Data.Bool.html
├── Stdlib.Data.List.html
├── Stdlib.Data.Maybe.html
├── Stdlib.Data.Nat.html
├── Stdlib.Data.Ord.html
├── Stdlib.Data.Product.html
├── Stdlib.Data.String.html
├── Stdlib.Function.html
├── Stdlib.Prelude.html
└── Stdlib.System.IO.html
```
In addition, for the vscode-plugin, this PR adds two flags,
`--prefix-assets` and `--prefix-url`, for which one provides input to
help vscode find resource locations and Juvix files.

PS. Make sure to run `make clean` the first time you run `make install`
for the first time.
2023-01-17 18:11:59 +01:00
Jonathan Cubides
c6a43e63b1
Small changes for the presentation (#1456) 2022-08-17 18:27:42 +02:00
janmasrovira
2532b34041
Implement an html documentation generator similar to haddock (#1413) (#1416) 2022-07-28 17:19:07 +02:00
Paul Cadman
e557f24b1d
Restore mascot images to the minijuvix book (#250) 2022-07-06 14:23:13 +02:00
Paul Cadman
f59df1f329
Restore Juvix mascot image to README (#248)
* Restore Juvix mascot to README

* Excludes assets/ from end-of-file-fixer commit hook
2022-07-06 11:49:58 +02:00
Jonathan Cubides
a749575734
Add minijuvix version info and date to HTML output (#186)
* Add minijuvix version info and date to HTML output

* Fix pre-commit
2022-06-21 17:03:22 +02:00
Jan Mas Rovira
271464df04 add integer and string literals 2022-03-15 12:37:33 +01:00
Jan Mas Rovira
fdd5a0391d [html] add light theme; add cli option to pick theme 2022-02-05 23:15:42 +01:00
Jan Mas Rovira
1919c32417 [html] improve html pretty printing 2022-02-05 13:27:33 +01:00