(插件最近活过来了!)
遇到的问题
没办法正常执行我写得程序,大佬帮忙看看。{具体问题表现看“# 实际的效果”}
预期的效果
1.我打算在「光标」停留在任意笔记的任意位置,根据「模板」创建「“任意命名”」笔记,并将笔记的「双向链接」插入在「光标」所在位置。
2.同时将上一步创建的「"任意命名”」笔记,移到固定的文件夹里。
因此我写了两个模板。
tp-add Newslink(插入链接的模版):
<%*
let input= await tp.system.prompt("Please enter the title")
let templater= tp.file.find_tfile("2024(News)")
-%>
- [[<% (await tp.file.create_new(templater,input,true)).basename%>]]
2024(News)
文档属性 {没办法复制}
---
<%await tp.file.move("/News/Critic/"+tp.file.title)%>
### 🎓PRESENTATION
{该部分使用的是note gallery插件,此部分要写代码才能使用该插件}
~<%tp.system.prompt("~~~","~~~")%>note-gallery
query: 'path:Omnivore tag:#<%tp.system.prompt("🏷","news")%>'
debugQuery: false
sort: desc
sortBy: Date published
fontSize: 8pt
showTitle: ture
recursive: false
breakpoints:
default: 2
limit: 10
<%tp.system.prompt("~~~~","~~~~")%>
原图:
![image|690x329, 100%](upload://caicjuzUJKn7rnv7pjloOWYjfU6.jpeg)
### 🕍三句话叙述清楚事情的经过
1. 🍇
2. 🥥
3. 🥑
### 🗻疑点
>[!note|50%]
> - 🍚
> - 🍵
> - 🍨
### 🏟️思考
### 🔗关联新闻事件
Attach:alt+A
实际的结果
超链出现在新创建的文件中,而不是「光标」处,「光标」处为空白
如图:
已尝试的解决方案
- 检查了"tp-add Newslink"的每一步(单独验证),没有任何问题,
- 只使用2024(News)模版也没有任何问题。
- 如果把2024(News)换成另一个模版,里面都存在不同的代码,没有任何问题。
类似于这种:
问题究竟出在哪
求求大佬解答 我已经耗了一天多了