feat(cursor): 添加鼠标样式

This commit is contained in:
nineya 2023-11-13 11:53:50 +08:00
parent f086832b39
commit aa13dc8249
21 changed files with 18 additions and 7 deletions

@ -880,6 +880,10 @@ spec:
label: 关闭
- value: breeze
label: 清风(深色)
- value: mellow
label: 卡通圆润
- value: black_cat
label: 黑色小猫
- $formkit: select
name: cursor_move
label: 鼠标移动特效

@ -1,7 +1,7 @@
@default: url(../../cursor/breeze/Arrow.cur), auto;
@pointer: url(../../cursor/breeze/Hand.cur), auto;
@text: url(../../cursor/breeze/IBeam.cur), auto;
@zoom-in: url(../../cursor/breeze/Arrow.cur), auto;
@default: var(--cursor-default);
@pointer: var(--cursor-pointer);
@text: var(--cursor-text);
@zoom-in: var(--cursor-zoom-in);
body {
cursor: @default;
@ -11,7 +11,11 @@ a, button, .expand-done, .navbar-above .navbar-nav .item, .navbar-slideicon, .na
cursor: @pointer;
}
.main-content img {
.aplayer .aplayer-pic, .aplayer .aplayer-music, .aplayer .aplayer-bar-wrap, .aplayer .aplayer-icon {
cursor: @pointer !important;
}
.main-content :not(.jg-entry)>img:not([class]) {
cursor: @zoom-in;
}

@ -1 +0,0 @@
.main-content img,body{cursor:url(../../cursor/breeze/Arrow.cur),auto}.actions>div,.expand-done,.main-content figure>figcaption div,.navbar-above .navbar-nav .item,.navbar-searchicon,.navbar-slideicon,.photos .picture-details,.widget .ad-tag .click-close,a,button{cursor:url(../../cursor/breeze/Hand.cur),auto}blockquote,code,h1,h2,h3,h4,h5,h6,hr,input[type=text],li,p,td,textarea,th{cursor:url(../../cursor/breeze/IBeam.cur),auto}

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

Binary file not shown.

After

(image error) Size: 4.2 KiB

@ -13,6 +13,10 @@
html {
--theme: [(${theme.config.basic_style.theme_color})];
filter: [(${theme.config.enhance.enable_gray_mode ? 'grayscale(1) !important' : 'none'})];
[(${theme.config.enhance.cursor_style == 'breeze' ? '--cursor-default: url(/themes/theme-dream/assets/cursor/breeze/Arrow.cur), auto;--cursor-pointer: url(/themes/theme-dream/assets/cursor/breeze/Hand.cur), auto; --cursor-text: url(/themes/theme-dream/assets/cursor/breeze/IBeam.cur), auto; --cursor-zoom-in: url(/themes/theme-dream/assets/cursor/breeze/Cross.cur), auto;'
: theme.config.enhance.cursor_style == 'black_cat' ? '--cursor-default: url(/themes/theme-dream/assets/cursor/black_cat/normal.cur), auto;--cursor-pointer: url(/themes/theme-dream/assets/cursor/black_cat/ayuda.cur), auto;--cursor-text: url(/themes/theme-dream/assets/cursor/black_cat/texto.cur), auto;--cursor-zoom-in: url(/themes/theme-dream/assets/cursor/black_cat/precision.cur), auto;'
: theme.config.enhance.cursor_style == 'mellow' ? '--cursor-default: url(/themes/theme-dream/assets/cursor/mellow/normal.cur), auto;--cursor-pointer: url(/themes/theme-dream/assets/cursor/mellow/link.cur), auto;--cursor-text: url(/themes/theme-dream/assets/cursor/mellow/normal.cur), auto;--cursor-zoom-in: url(/themes/theme-dream/assets/cursor/mellow/normal.cur), auto;'
: '' })]
}
html.night {

@ -39,7 +39,7 @@ th:with="description=${isPost ? post != null ? post.status.excerpt : singlePage
<link th:if="${isPost == true || isPhotos == true}" data-pjax rel="stylesheet" th:href="@{/assets/lib/fancybox@5.3.7/jquery.fancybox.min.css}">
<link rel="stylesheet" th:href="@{/assets/lib/qmsg/qmsg.min.css}">
<link th:if="${theme.config.enhance.cursor_style != 'none'}" rel="stylesheet" th:href="@{'/assets/css/cursor/' + ${theme.config.enhance.cursor_style} + '.min.css'(mew=${theme.spec.version})}">
<link th:if="${theme.config.enhance.cursor_style != 'none'}" rel="stylesheet" th:href="@{/assets/css/cursor.min.css(mew=${theme.spec.version})}">
<th:block th:replace="~{common/config}"/>