https://github.com/zyf722/typst-tabler-icons
A Typst library for Tabler Icons, a set of over 5800 free MIT-licensed high-quality SVG icons.
https://github.com/zyf722/typst-tabler-icons
icons tabler-icons typst typst-package
Last synced: 3 months ago
JSON representation
A Typst library for Tabler Icons, a set of over 5800 free MIT-licensed high-quality SVG icons.
- Host: GitHub
- URL: https://github.com/zyf722/typst-tabler-icons
- Owner: zyf722
- License: mit
- Created: 2024-10-06T14:49:50.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-01-10T07:31:21.000Z (5 months ago)
- Last Synced: 2026-01-11T02:09:51.757Z (5 months ago)
- Topics: icons, tabler-icons, typst, typst-package
- Language: Typst
- Homepage: https://typst.app/universe/package/use-tabler-icons
- Size: 306 KB
- Stars: 12
- Watchers: 1
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
> **Note**
>
> This project is greatly inspired by and mainly edited based on [typst-fontawesome](https://github.com/duskmoon314/typst-fontawesome).
A Typst library for [Tabler Icons](https://github.com/tabler/tabler-icons), a set of over 5800 free MIT-licensed high-quality SVG icons.
## Usage
### Install Font
Install [the webfont for Tabler Icons](https://docs.tabler.io/icons/libraries/webfont) before using this library. Or, if you are using Typst web app, simply upload the font file to your project.
> [!NOTE]
>
> Since Tabler Icons v3.36.0, filled icons have been separated into a different font file. If you want to use filled icons, make sure to install both the regular ` tabler-icons.ttf` and filled `tabler-icons-filled.ttf` font files.
### Import the Library
#### Using the Typst Packages
You can install the library using the typst packages:
```typst
#import "@preview/use-tabler-icons:0.18.0": *
```
#### Manually Install
Just copy all files under [`src`](https://github.com/zyf722/typst-tabler-icons/tree/main/src) to your project and rename them to avoid naming conflicts.
Then, import `lib.typ` to use the library:
```typst
#import "lib.typ": *
```
### Use the Icons
You can use the `tabler-icon` function to create an icon with its name:
```typst
#tabler-icon("calendar")
```
Or you can directly use the `ti-` prefix :
```typst
#ti-calendar()
```
As these icons are actually text with custom font, you can pass any text attributes to the function:
```typst
#tabler-icon("calendar", fill: blue)
```
Refer to [`gallery.pdf`](https://github.com/zyf722/typst-tabler-icons/tree/main/gallery/gallery.pdf) and [Tabler Icons website](https://tabler.io/icons) for all available icons.
## Contributing
[Pull Requests](https://github.com/zyf722/typst-tabler-icons/pulls) are welcome!
It is strongly recommended to follow the [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) specification when writing commit messages and creating pull requests.
### Github Actions Workflow
This package uses a daily run [Github Actions workflow](https://github.com/zyf722/typst-tabler-icons/tree/main/.github/workflows/build.yml) to keep the library up-to-date with the latest version of Tabler Icons, which internally runs [`scripts/generate.mjs`](https://github.com/zyf722/typst-tabler-icons/tree/main/scripts/generate.mjs) to generate Typst source code of the library and gallery.
## License
[MIT](https://github.com/zyf722/typst-tabler-icons/tree/main/LICENSE)