Skip to content

template

7sDream edited this page Apr 21, 2021 · 2 revisions

内容模板

firelomo 的上下文菜单可能会在三种状态下被触发:

模板的作用是自定义在这些条件下时默认的发送内容。

模板中被花括号 {} 包围的各个字段,会被上下文中的内容替换,其他内容则保持原样。

通用上下文

三种上下文中都可以使用的字段有:

字段 内容 示例
date 当前日期,格式 Year/Month/Day 2021/04/22
time 当前时间,格式 hour:minute:second 15:29:03
dateTime 当前日期时间,格式和上面两个一样,中间空格分割 2021/04/22 15:29:03
dateYear 当前年份 2021
dateMonth 当前月份 04
dateDay 当前日期 22
timeHour 当前时间的小时 15
timeMinute 当前时间的分钟 29
timeSecond 当前时间的秒钟 03
pageTitle 当前页面的标题 template · 7sDream/firelomo Wiki
pageUrl 当前页面的链接 https://github.com/7sDream/firelomo/wiki/template

选中内容模板

额外可用的字段有:

字段 内容 示例
selection 选中的内容(只含有文字) 一个火狐扩展,用于简便快速的将火狐中的内容发送到 flomo。

链接模板

额外可用的字段有:

字段 内容 示例
linkTitle 链接的文字 firelomo
linkUrl 链接的目标地址 https://github.com/7sDream/firelomo

页面模板

没有额外可用的字段。

Clone this wiki locally