Skip to content

Commit

Permalink
Merge pull request #393 from caolib/gh-pages
Browse files Browse the repository at this point in the history
update onelight theme
  • Loading branch information
abnerlee authored Jan 2, 2025
2 parents bba4397 + 1b202a5 commit b377727
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 73 deletions.
74 changes: 74 additions & 0 deletions _posts/theme/2024-12-18-OneLight.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
---
layout: theme
title: OneLight
category: theme
homepage: https://github.com/caolib/typora-onelight-theme
download: https://github.com/caolib/typora-onelight-theme/releases
author: caolib
thumbnail: onelight.png
typora-root-url: ../../
---

<h1 align='center'>OneLight Theme For Typora</h1>

> [!tip]
> **这里有两篇文章使用one-light主题,可点击查看主题详细效果展示**
>
> - **[onelight](https://bin-sites.pages.dev/onelight)**
> - **[计算机网络](https://bin-sites.pages.dev/net/计算机网络)**
---

![image-20241229005550600](https://s2.loli.net/2024/12/29/4zq9VbuAKvkFhYo.png)

![image-20241229005801957](https://s2.loli.net/2024/12/29/mHh5nuwyVWvpoGI.png)

## **1.如何使用**

- 下载[主题文件](https://github.com/caolib/typora-onelight-theme/releases)
- 在typora中选择 文件 → 偏好设置 → 外观 → 打开主题文件夹
- 将下载的zip解压,将**css文件****文件夹**粘贴到typora的主题文件夹中

> [!caution]
>
> - **如果你想克隆本仓库,为了避免克隆到其他分支,请使用下面这条命令,这样只会克隆主分支**
>
> ```shell
> git clone --single-branch https://github.com/caolib/typora-onelight-theme.git
> ```
>
> - 如果你想从网络导入
>
> ```css
> @import url("https://cdn.jsdelivr.net/gh/caolib/typora-onelight-theme@onelight/dist/onelight.min.css");
> ```
---
## **2.关于字体**
`onelight.css`文件开头设置了默认字体,可以自行修改
![](https://github.com/user-attachments/assets/ab75260f-cff0-43b7-b8e5-dfea38e8525c)
> **如果要使用主题中的字体,建议下载字体安装**,中文字体是[喵字果汁体](https://clb-cdn.pages.dev/fonts/MiaoZi-GuoZhiTi.ttf),英文字体是Cascadia Code
## **3.关于背景图片**
> [!tip]
>
> 背景图片在`onelight/img`文件夹下,默认是bg.gif,可以自行替换,你也可以在css文件中搜索并替换文件
>
> ```css
> content {
> background-color: transparent;
> // 可以替换此处的图片,不想显示可以将这段整个注释掉
> background-image: url('./onelight/img/bg.gif');
> background-position: 100% 100%;
> background-repeat: no-repeat;
> // 修改图片大小
> background-size: 200px auto;
> transition: background-image .5s ease-in-out, background-size .5s ease-in-out
> }
> ```
>
> <img src="https://s2.loli.net/2024/12/15/Fn6LcrKWC2dlp1J.gif" alt="recording" style="zoom: 50%;" />
73 changes: 0 additions & 73 deletions _posts/theme/2024-4-15-OneLight.md

This file was deleted.

Binary file modified media/thumbnails/onelight.png
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 b377727

Please sign in to comment.