Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
e4b5eac
docs: design spec for GitlabProjectInfo embedded sections
ebuildy Jul 8, 2026
9a998f0
docs: add extended project stats to GitlabProjectInfo spec
ebuildy Jul 8, 2026
92f80ce
docs: implementation plan for GitlabProjectInfo sections + stats
ebuildy Jul 8, 2026
ff972f8
feat: add getCommits to GitLabClient
ebuildy Jul 8, 2026
865a791
feat: add CommitData type and fetchCommits fetcher
ebuildy Jul 8, 2026
6fa4098
feat: compose count-gated sections into fetchProjectInfo
ebuildy Jul 8, 2026
dd5db25
test: verify projectInfo cache key varies by section counts
ebuildy Jul 8, 2026
9add50a
feat: render embedded sections and link override in GitlabProjectInfo
ebuildy Jul 8, 2026
72e7ec2
feat: export CommitData and cover cards layout
ebuildy Jul 8, 2026
797b092
docs: document GitlabProjectInfo embedded sections
ebuildy Jul 8, 2026
b2bbf3a
docs: single-line GitlabProjectInfo cards example
ebuildy Jul 8, 2026
5e264c7
feat: add formatBytes helper
ebuildy Jul 8, 2026
dee5377
feat: add statistics option and getContributorsCount to client
ebuildy Jul 8, 2026
213a06e
fix: guard getContributorsCount against NaN X-Total
ebuildy Jul 8, 2026
001ca6a
feat: map commit/contributor/issue/size stats in fetchProjectInfo
ebuildy Jul 8, 2026
1504a14
refactor: surface programmer errors in contributors fetch; fix test f…
ebuildy Jul 8, 2026
491b93e
feat: render extended stat pills in GitlabProjectInfo
ebuildy Jul 8, 2026
e7951c0
docs: document GitlabProjectInfo extended stats
ebuildy Jul 8, 2026
39f38d9
style: theme the embedded GitlabProjectInfo sections and cards layout
ebuildy Jul 8, 2026
3b683ca
feat: relative dates for commits/issues; right-aligned issue date
ebuildy Jul 8, 2026
cbceb9e
feat: right-align relative dates for releases and commits too
ebuildy Jul 8, 2026
2f62ff8
feat: show project path in green below the description
ebuildy Jul 8, 2026
629c077
feat: add showLinks prop to toggle release/commit/issue links
ebuildy Jul 8, 2026
6094d80
feat: created date in stats; use absolute human dates (drop relative …
ebuildy Jul 8, 2026
480898b
docs: fix mangled ProjectInfo blockquote
ebuildy Jul 8, 2026
2d9e570
chore: doc
ebuildy Jul 9, 2026
c07da50
chore: design
ebuildy Jul 9, 2026
6a288ea
chore: claude
ebuildy Jul 9, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,3 +133,9 @@ Rules:
- If graphify-out/wiki/index.md exists, use it for broad navigation instead of raw source browsing.
- Read graphify-out/GRAPH_REPORT.md only for broad architecture review or when query/path/explain do not surface enough context.
- After modifying code, run `graphify update .` to keep the graph current (AST-only, no API cost).

## Gitlab API

You are familiar with Gitlab API:

OpenAPI: <https://gitlab.com/gitlab-org/gitlab/-/raw/master/doc/api/openapi/openapi_v3.yaml>
34 changes: 32 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ Embed **GitLab** resources — project info, README, releases, issues, and any
file or code snippet — directly in your **Docusaurus 3** documentation using MDX
components.

![Screenshot](./docs/screenshot1.png)

All data is fetched **at build time** and baked into your static site. No API
tokens or network calls ever reach the browser, and pages stay fast.

Expand Down Expand Up @@ -89,17 +91,45 @@ namespace path (`project="group/subgroup/repo"`).

### `<GitlabProjectInfo>`

A card with name, description, topics, stars/forks, and last activity.
A card with name, description, topics, stars/forks, and last activity. It can
also embed compact **releases**, **commits**, and **issues** sections — each is
opt-in and only fetched when its count prop is a positive number.

```mdx
<GitlabProjectInfo project="group/repo" />
<GitlabProjectInfo project="group/repo" showStats={false} />

<GitlabProjectInfo project="group/app" releases={3} commits={5} issues={5} />

<GitlabProjectInfo project="group/app" releases={3} releasesLayout="cards" link="https://example.com/app" />
```

| Prop | Type | Default | Description |
|---|---|---|---|
| `project` | string \| number | — | **Required.** Project path or ID |
| `showStats` | boolean | `true` | Show stars/forks/last-activity row |
| `showStats` | boolean | `true` | Show the stars / forks / created / last-activity row |
| `showLinks` | boolean | `true` | Link the release / commit / issue items. Set `false` to render them as plain text (the card title stays a link) |
| `link` | string | project's `web_url` | Override the card title's link target |
| `releases` | number | — | Embed the latest N releases. Absent or `≤ 0` — not fetched, not rendered |
| `commits` | number | — | Embed the latest N commits. Absent or `≤ 0` — not fetched, not rendered |
| `issues` | number | — | Embed the latest N issues. Absent or `≤ 0` — not fetched, not rendered |
| `releasesLayout` | `"list"` \| `"cards"` | `"list"` | Layout for the releases section. An invalid value fails the build |
| `commitsLayout` | `"list"` \| `"cards"` | `"list"` | Layout for the commits section. An invalid value fails the build |
| `issuesLayout` | `"list"` \| `"cards"` | `"list"` | Layout for the issues section. An invalid value fails the build |

> Each section's `list` layout renders one compact line per item — release:
> tag and name; commit: linked short SHA, title, and author; issue: linked
> `#iid` and title. Every item shows its date (absolute, e.g. `May 1, 2020`)
> pinned to the right. `cards` renders a richer variant of the same data.
>
> The `showStats` row can also show extra pills — total commit count,
> contributor count, open issue count, repository size — automatically,
> whenever that data is available; there's no attribute to request them. Set
> `showStats={false}` to hide the whole row (pills included). Commit count and
> repository size come from the project's `statistics`, which GitLab only
> returns to tokens with **Reporter role or higher**; on anonymous/public
> builds those two pills are simply omitted. Contributor count also depends
> on the API returning a total count header, and is omitted if it isn't.

### `<GitlabReadme>`

Expand Down
Binary file added docs/screenshot1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading