Skip to content

Commit 6b7f0e1

Browse files
committed
Current version of Psi+ is 1.5.2060
It is based on: * psi: 9ddd60f6 * plugins: 347230b * psimedia: 478567e * resources: fc4cfc1
1 parent 39bd93c commit 6b7f0e1

File tree

7 files changed

+14
-14
lines changed

7 files changed

+14
-14
lines changed

themes/chatview/psi/LunnaCat_Classic/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@
190190
: "<div class='infmsg'>%icon%<b>*** %usertext%</b></div>",
191191
trackbar: '<hr class="trackbar" />'
192192
},
193-
dateFormat : "HH:mm:ss",
193+
timeFormat : "HH:mm:ss",
194194
proxy : function() { //optional
195195
if (shared.cdata.type == "settings") {
196196
applyPsiSettings();

themes/chatview/psi/adapter.js

+8-7
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,9 @@ function psiThemeAdapter(chat) {
7979
session : session,
8080
isMuc : session.isMuc,
8181
accountId : window.srvSession.account,
82-
dateFormat : "HH:MM:SS",
82+
timeFormat : "HH:mm:ss",
83+
dateFormat : "LL",
84+
dateTimeFormat: "LL HH:mm:ss",
8385
scroller : null,
8486
varHandlers : {},
8587
prevGrouppingData : null,
@@ -94,7 +96,7 @@ function psiThemeAdapter(chat) {
9496

9597
TemplateTimeVar : function(name, format) {
9698
this.name = name;
97-
this.formatter = new chat.DateTimeFormatter(format || shared.dateFormat);
99+
this.formatter = new chat.DateTimeFormatter(format || (name == "date"? shared.dateFormat : shared.timeFormat));
98100
},
99101

100102
TemplateTemplateVar : function(template_name) {
@@ -155,7 +157,9 @@ function psiThemeAdapter(chat) {
155157
}
156158
var t = shared.templates;
157159
shared.chatElement = config.chatElement;
160+
shared.timeFormat = config.timeFormat || shared.timeFormat;
158161
shared.dateFormat = config.dateFormat || shared.dateFormat;
162+
shared.dateTimeFormat = config.dateTimeFormat || shared.dateTimeFormat;
159163
shared.scroller = config.scroller || new chat.WindowScroller(false);
160164
shared.groupping = config.groupping || shared.groupping;
161165
proxy = config.proxy;
@@ -231,11 +235,8 @@ function psiThemeAdapter(chat) {
231235
if (this.name == "sender") { //may not be html
232236
d = chat.util.escapeHtml(d);
233237
} else if (d instanceof Date) {
234-
if (this.name == "time") {
235-
d = chat.util.dateFormat(d, shared.dateFormat);
236-
} else { // last message date ?
237-
d = chat.util.dateFormat(d, "LL");
238-
}
238+
// "date" and "time" variables use TemplateTimeVar. this is something unknown
239+
d = chat.util.dateFormat(d, shared.dateTimeFormat);
239240
} else if (this.name == "avatarurl") {
240241
var url;
241242
if (shared.cdata.local) {

themes/chatview/psi/bubble/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -56,12 +56,12 @@
5656
messageGroupping: messageGroupping,
5757
sys: `<div class="sysmsg" title="%time{LL}%">%message%</div>`,
5858
sysMessageUT: `<div class="sysmsg" title="%time{LL}%">%message%<div class="usertext">%usertext%</div></div>`,
59-
lastMsgDate: `<div class="sysmsg">%date{LL}%</div>`,
59+
lastMsgDate: `<div class="sysmsg">%date%</div>`,
6060
subject: shared.isMuc?
6161
"<div class='sysmsg' title='%time{LL}%'>%message%<div class='usertext'><b>%usertext%</b></div></div>"
6262
: "<div class='sysmsg'><b>%usertext%</b></div>",
6363
},
64-
dateFormat : "HH:mm",
64+
timeFormat : "HH:mm",
6565
proxy : function() { //optional
6666
if (shared.cdata.type == "reactions") {
6767
renderReactions(shared.cdata);

themes/chatview/psi/classic/index.html

-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,6 @@
105105
: "<div class='infmsg'>%icon%<b>*** %usertext%</b></div>",
106106
trackbar: '<hr class="trackbar" />'
107107
},
108-
dateFormat : "HH:mm:ss",
109108
proxy : function() { //optional
110109
if (shared.cdata.type == "settings") {
111110
applyPsiSettings();

themes/chatview/psi/new_classic/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@
181181

182182
left_time: '<div class="left_time"><div>%time%</div></div>'
183183
},
184-
dateFormat : "HH:mm",
184+
timeFormat : "HH:mm",
185185
proxy : function() { //optional
186186
if (shared.cdata.mtype == "message") {
187187
return shared.cdata.emote && shared.templates.messageNC || null;

themes/chatview/psi/stylized_classic/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@
211211
: "<div class='infmsg'>%icon%<b>*** %usertext%</b></div>",
212212
trackbar: '<hr style="height:1px; border:1px solid black; border-color:#2d2d2d #5b5b5b #5b5b5b #2d2d2d" />'
213213
},
214-
dateFormat : "HH:mm",
214+
timeFormat : "HH:mm",
215215
proxy : function() { //optional
216216
if (shared.cdata.mtype == "message") {
217217
return shared.cdata.emote && shared.templates.messageNC ||

version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.5.2059 (2024-10-12, b29c1f43)
1+
1.5.2060 (2024-10-12, 9ddd60f6)

0 commit comments

Comments
 (0)