Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

style: Improve .dragover style of file tree #13574

Merged
merged 1 commit into from
Dec 24, 2024

Conversation

TCOTC
Copy link
Contributor

@TCOTC TCOTC commented Dec 21, 2024

部分情况下样式会有点奇怪(尤其是用 CSS 修改了文档树样式之后)。改成跟数据库里一样的伪元素实现

image

@TCOTC TCOTC marked this pull request as ready for review December 22, 2024 22:15
@@ -140,6 +140,7 @@
height: 4px;
background-color: var(--b3-theme-primary-lighter);
z-index: 3;
pointer-events: none;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个 js 有处理,不需要了。

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我感觉伪元素还是统一都加上 pointer-events: none; 最保险

@Vanessa219
Copy link
Member

这个要怎么重现?

@TCOTC
Copy link
Contributor Author

TCOTC commented Dec 23, 2024

默认主题下就是这样:

video.webm

不过主要的问题是这个样式目前的实现不太优雅,会影响别的自定义样式:

.sy__file ul.b3-list.b3-list--background {
	border-radius: var(--b3-border-radius);
	margin: 1px 4px 6px 4px;
	outline: 1px solid var(--b3-theme-on-surface-light);
	/* overflow: hidden; */
}
.sy__file .b3-list-item {
	margin-left: 0;
	margin-right: 0;

	&[data-type="navigation-root"] {
		line-height: 30px; /* 笔记本行高 */
	}
}

image

@Vanessa219 Vanessa219 merged commit 35f112d into siyuan-note:dev Dec 24, 2024
6 checks passed
@TCOTC TCOTC deleted the dev-dragover branch December 24, 2024 13:30
Vanessa219 added a commit that referenced this pull request Dec 24, 2024
@Vanessa219
Copy link
Member

不拉进 3.1.18 版本了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants