Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sidebar and index overhaul (2) #1244

Merged
merged 5 commits into from
Nov 18, 2024
Merged

Sidebar and index overhaul (2) #1244

merged 5 commits into from
Nov 18, 2024

Conversation

gpetiot
Copy link
Collaborator

@gpetiot gpetiot commented Nov 13, 2024

Follow-up on #1232, catching up on #1220

@gpetiot gpetiot requested a review from panglesd November 13, 2024 10:47
@gpetiot gpetiot added the no changelog This pull request does not need a changelog entry label Nov 13, 2024
@jonludlam
Copy link
Member

I'm getting a different sidebar viewing the modules than when viewing the pages - when viewing the modules the whole hierarchy seems to disappear:

Screenshot 2024-11-14 at 19 58 06

vs

Screenshot 2024-11-14 at 19 58 12

@jonludlam
Copy link
Member

OK, looks like the logic from here got inverted to be on the skip clause rather than the generate clause, but the inversion of the wasn't quite right here - I think it's missing a not on the is_prefix.

Guillaume Petiot and others added 5 commits November 18, 2024 10:46
Co-authored-by: Paul-Elliot <[email protected]>
We use the id name (corresponding to the directory name) for the page title.

There is one case where we don't have access to an id:
```
$ odoc compile --output_dir _odoc --parent-id "" file.mld
$ odoc link _odoc/page-file.mld
$ odoc sidebar-generate -P _odoc/
```

The parent id of page `file` is `None` and we do not have an `index.mld` with
the same parent...

See also the test
@jonludlam jonludlam merged commit 10cdc58 into ocaml:master Nov 18, 2024
14 checks passed
@gpetiot gpetiot deleted the toc-tree-2 branch November 18, 2024 12:18
panglesd added a commit to panglesd/sherlodoc that referenced this pull request Dec 9, 2024
Several changes:
- Entries are now defined in the `odoc_index` library,
- Entries can have new kinds (pages, source, ...)
- Indexes have the form of "skeletons of entries", that can be folded.
- Indexes can be created by odoc with the `odoc compile-index` command, and
  then consumed by sherlodoc.

These changes come from:
- ocaml/odoc#1228
- ocaml/odoc#1232
- ocaml/odoc#1233
- ocaml/odoc#1244
- ocaml/odoc#1250
- ocaml/odoc#1251
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no changelog This pull request does not need a changelog entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants