MCPcopy Create free account
hub / github.com/XIU2/UserScript / question_time

Function question_time

Zhihu-Enhanced.user.js:1551–1555  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1549
1550// 问题创建时间
1551function question_time() {
1552 if (!(document.querySelector('.QuestionPage .QuestionHeader-side .QuestionTime-xiu'))) {
1553 document.querySelector('.QuestionPage .QuestionHeader-side').insertAdjacentHTML('beforeEnd', '<div class="QuestionTime-xiu" style="color: #9098ac; margin-top: 5px; font-size: 13px; font-style: italic;"><p>创建时间:' + getUTC8(new Date(document.querySelector('.QuestionPage > meta[itemprop=dateCreated]').content)) + '</p><p>最后编辑:' + getUTC8(new Date(document.querySelector('.QuestionPage > meta[itemprop=dateModified]').content)) + '</p></div>');
1554 }
1555}
1556
1557
1558// UTC 标准时转 UTC+8 北京时间,修改自:https://greasyfork.org/zh-CN/scripts/402808(精简)

Callers 1

startFunction · 0.85

Calls 1

getUTC8Function · 0.85

Tested by

no test coverage detected