Skip to content

Commit

Permalink
docs(README): add new previews and cleanup usage (#35)
Browse files Browse the repository at this point in the history
  • Loading branch information
uncenter authored May 24, 2024
1 parent 5ac9adb commit 011b0fb
Show file tree
Hide file tree
Showing 7 changed files with 37 additions and 14 deletions.
51 changes: 37 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,49 +12,72 @@
</p>

<p align="center">
<img src="https://raw.githubusercontent.com/catppuccin/catppuccin/main/assets/misc/sample.png"/>
<img src="assets/preview.webp"/>
</p>

## Previews

<details>
<summary>🌻 Latte</summary>
<img src="assets/latte.webp"/>
</details>
<details>
<summary>🪴 Frappé</summary>
<img src="assets/frappe.webp"/>
</details>
<details>
<summary>🌺 Macchiato</summary>
<img src="assets/macchiato.webp"/>
</details>
<details>
<summary>🌿 Mocha</summary>
<img src="assets/mocha.webp"/>
</details>

## Usage

Add the CSS for your preferred flavor in your markup. You can do this by either getting the files via NPM or a CDN.
Add the CSS for your preferred flavor in your markup. You can do this by either getting the files from npm, or through a CDN.

### npm

### NPM:
Install the `@catppuccin/highlightjs` package with your preferred package manager.

Installation:
```bash
npm install -D @catppuccin/highlightjs
```

You can then use the files in `@catppuccin/highlightjs/css` or `@catppuccin/highlightjs/sass`.

### CDN:
### CDN

Embed the [Highlight.js script](https://highlightjs.org/download/), then one of our themes.
Embed the [Highlight.js script](https://highlightjs.org/download/) along with one of our themes.

> [!NOTE]
> The "variable version" assumes that you have a flavor of Catppuccin already present in your CSS variables, e.g. `:root { --ctp-mauve:136,57,239; }`.
> This is particularly useful if you use [Catppuccin TailwindCSS](https://github.com/catppuccin/tailwindcss)
<!-- x-release-please-start-version -->

unpkg:
#### unpkg

```html
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin-mocha.css">
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin-macchiato.css">
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin-frappe.css">
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin-latte.css">
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin-frappe.css">
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin-macchiato.css">
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin-mocha.css">
<!-- variable version -->
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin.variables.css">
<link rel="stylesheet" href="//unpkg.com/@catppuccin/[email protected]/css/catppuccin.variables.important.css">
```

jsdelivr:
#### jsDelivr

```html
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin-mocha.css">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin-macchiato.css">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin-frappe.css">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin-latte.css">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin-frappe.css">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin-macchiato.css">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin-mocha.css">

<!-- variable version -->
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin.variables.css">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/@catppuccin/[email protected]/css/catppuccin.variables.important.css">
Expand Down
Empty file removed assets/.gitkeep
Empty file.
Binary file added assets/frappe.webp
Binary file not shown.
Binary file added assets/latte.webp
Binary file not shown.
Binary file added assets/macchiato.webp
Binary file not shown.
Binary file added assets/mocha.webp
Binary file not shown.
Binary file added assets/preview.webp
Binary file not shown.

0 comments on commit 011b0fb

Please sign in to comment.