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

嵌入块支持隐藏标题下方的块 #4404

Closed
WolkeAtreide opened this issue Mar 27, 2022 · 3 comments
Closed

嵌入块支持隐藏标题下方的块 #4404

WolkeAtreide opened this issue Mar 27, 2022 · 3 comments
Assignees
Milestone

Comments

@WolkeAtreide
Copy link

WolkeAtreide commented Mar 27, 2022

在使用嵌入块的过程中,很多时候并不想看到标题块下方的内容。原本建议将标题块设置为h和p两种属性。
和D沟通后,提议内置函数的方法。

@88250 88250 self-assigned this Mar 27, 2022
@88250 88250 changed the title 新建一个内置函数使得在嵌入块可以只搜索标题而不显示下方块 提供内置函数使得嵌入块只渲染标题 Mar 27, 2022
@1995hanjian
Copy link

很期待,赞一个

@88250 88250 changed the title 提供内置函数使得嵌入块只渲染标题 嵌入块支持只渲染标题 Mar 28, 2022
@88250 88250 changed the title 嵌入块支持只渲染标题 嵌入块支持仅渲染标题 Mar 28, 2022
@88250 88250 added this to the 1.9.6 milestone Mar 28, 2022
@fanglypro
Copy link

fanglypro commented Mar 28, 2022

这个和 https://ld246.com/article/1647743396243 这个问题我认为是类似的问题,都是查询/反链的汇总过程中的上下文显示问题。

如果是以 roam 的逻辑的话,这部分可以这样设计:传递型标题/列表项(只有块引用或空格)只显示标题/父结点,下级内容折叠,关联型标题/列表项(除了块引用外有其他文字)下级内容展开,和反链面板是统一的逻辑。

标题的设计逻辑应当和列表的设计逻辑统一,与“嵌入块支持仅渲染标题”对应的是“嵌入块支持仅渲染列表项的第一个段落块(即父结点)”,在查询列表的过程中会有和查询标题相同的问题,两者在逻辑上我认为应该一视同仁。

而想要实现上面 roam 的逻辑,又有一些比较重要的条件思源还不支持:1. 要在嵌入块(sql)中支持直接折叠展开,而现在需要点开浮窗后折叠展开,看似只差了一步点击操作,而在面向真实应用场景下大量的sql搜索结果时,是完全不同的体验(而且之后编辑器式反链面板实现后,嵌入块也应当可以按照编辑器式反链面板的逻辑改成编辑器式);2. 嵌入块中的折叠展开不影响原文的折叠展开,这个我在编辑器式反链面板的 issue 中也提到了。

以上观点是从 roam 的设计思路角度出发,供参考,思源的底层设计和 roam 不一样肯定无法完全照搬,设计难度比纯大纲的 roam 要高很多,但面对有层级关系的问题时,将层级关系与大纲列表对应,交互逻辑上应当是类似的。

@88250
Copy link
Member

88250 commented Mar 29, 2022

@fanglypro 嵌入块这里暂时不考虑类似反链大纲的逻辑关联,还是以查询为主。

@88250 88250 changed the title 嵌入块支持仅渲染标题 嵌入块支持隐藏标题下方的块 Mar 30, 2022
88250 added a commit to siyuan-note/appearance that referenced this issue Mar 30, 2022
88250 added a commit to siyuan-note/appearance that referenced this issue Mar 30, 2022
@88250 88250 closed this as completed Mar 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants