Skip to content

Commit

Permalink
feat: theme customization
Browse files Browse the repository at this point in the history
  • Loading branch information
haoziqaq committed Oct 27, 2024
1 parent b4ff662 commit 1a53c72
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/.vitepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { defineConfig } from 'vitepress'
export default defineConfig({
title: 'Rattail',
description: 'A utilities library for front-end developers, lightweight and ts-friendly',
head: [['link', { rel: 'icon', href: '/favicon.ico' }]],
locales: {
root: {
label: 'English',
Expand Down Expand Up @@ -31,6 +32,7 @@ export default defineConfig({
},
},
themeConfig: {
logo: { src: '/logo.svg', style: { height: '44px' } },
nav: [{ text: 'Home', link: '/' }],

sidebar: [
Expand Down
5 changes: 5 additions & 0 deletions docs/.vitepress/theme/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
:root {
--vp-c-brand-1: #cf8040;
--vp-c-brand-2: #a06433;
--vp-button-brand-bg: #cf8040;
}
4 changes: 4 additions & 0 deletions docs/.vitepress/theme/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import DefaultTheme from 'vitepress/theme'
import './custom.css'

export default DefaultTheme
1 change: 1 addition & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ hero:
name: 'Rattail'
text: 'A Utilities Library'
tagline: A utilities library for front-end developers, lightweight and ts-friendly
logo: /logo.svg
actions:
- theme: brand
text: Get Started
Expand Down
Binary file added docs/public/favicon.ico
Binary file not shown.
9 changes: 9 additions & 0 deletions docs/public/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 1a53c72

Please sign in to comment.