Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Nextra margin-top in nested lists (#2686)
Before: <img width="846" alt="image" src="https://github.com/WATonomous/infra-config/assets/5977478/965bf0bb-d26b-40fa-a9ac-4a959b78b4f8"> After: <img width="845" alt="image" src="https://github.com/WATonomous/infra-config/assets/5977478/d7dcc120-e891-4a2a-aa6d-28a70a705717"> The problem is that by default, Nextra applies `first:nx-mt-0` on `:first-child`. But in some cases (as shown above), the nested list is not the first child. In the example above, the first child is the `a` tag: <img width="1413" alt="image" src="https://github.com/WATonomous/infra-config/assets/5977478/e3e326b2-f8c1-47bb-8678-808b61262b03"> The fix is to use `:first-of-type` instead. Related: shuding/nextra#863
- Loading branch information