Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | /chat: removed the unused/unnecessary jump-to-top/bottom buttons. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA3-256: |
a044fea7850b8372c40dda7884025c83 |
| User & Date: | stephan 2021-03-27 16:04:04.527 |
Context
|
2021-03-28
| ||
| 05:14 | Add example of fossil timeline + diff to get changes between specific versions ... (check-in: 19f4b064ac user: danshearer tags: trunk) | |
|
2021-03-27
| ||
| 16:04 | /chat: removed the unused/unnecessary jump-to-top/bottom buttons. ... (check-in: a044fea785 user: stephan tags: trunk) | |
|
2021-03-26
| ||
| 20:28 | Darkmode skin ticket page style improvements from [forum:/forumpost/f7f89e2cdb | forum post f7f89e2cdb]. ... (check-in: fb39f02b77 user: stephan tags: trunk) | |
Changes
Changes to src/chat.c.
| ︙ | ︙ | |||
161 162 163 164 165 166 167 | @ <div id='chat-input-line'> @ <input type="text" name="msg" id="chat-input-single" \ @ placeholder="Type message here." autocomplete="off"> @ <textarea rows="8" id="chat-input-multi" \ @ placeholder="Type message here. Ctrl-Enter sends it." \ @ class="hidden"></textarea> @ <input type="submit" value="Send" id="chat-message-submit"> | < < | 161 162 163 164 165 166 167 168 169 170 171 172 173 174 | @ <div id='chat-input-line'> @ <input type="text" name="msg" id="chat-input-single" \ @ placeholder="Type message here." autocomplete="off"> @ <textarea rows="8" id="chat-input-multi" \ @ placeholder="Type message here. Ctrl-Enter sends it." \ @ class="hidden"></textarea> @ <input type="submit" value="Send" id="chat-message-submit"> @ <span id="chat-settings-button" class="settings-icon" \ @ aria-label="Settings..." aria-haspopup="true" ></span> @ </div> @ <div id='chat-input-file-area'> @ <div class='file-selection-wrapper'> @ <div class='help-buttonlet'> @ Select a file to upload, drag/drop a file into this spot, |
| ︙ | ︙ |
Changes to src/chat.js.
| ︙ | ︙ | |||
105 106 107 108 109 110 111 |
messagesWrapper: E1('#chat-messages-wrapper'),
inputForm: E1('#chat-form'),
btnSubmit: E1('#chat-message-submit'),
inputSingle: E1('#chat-input-single'),
inputMulti: E1('#chat-input-multi'),
inputCurrent: undefined/*one of inputSingle or inputMulti*/,
inputFile: E1('#chat-input-file'),
| | < < | 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 |
messagesWrapper: E1('#chat-messages-wrapper'),
inputForm: E1('#chat-form'),
btnSubmit: E1('#chat-message-submit'),
inputSingle: E1('#chat-input-single'),
inputMulti: E1('#chat-input-multi'),
inputCurrent: undefined/*one of inputSingle or inputMulti*/,
inputFile: E1('#chat-input-file'),
contentDiv: E1('div.content')
},
me: F.user.name,
mxMsg: F.config.chat.initSize ? -F.config.chat.initSize : -50,
mnMsg: undefined/*lowest message ID we've seen so far (for history loading)*/,
pageIsActive: 'visible'===document.visibilityState,
changesSincePageHidden: 0,
notificationBubbleColor: 'white',
|
| ︙ | ︙ | |||
337 338 339 340 341 342 343 |
}else if(Chat.e.newestMessage){
Chat.e.newestMessage.scrollIntoView(false);
}
},
toggleChatOnlyMode: function(){
return this.chatOnlyMode(!this.isChatOnlyMode());
},
| < < < < < < < < | 335 336 337 338 339 340 341 342 343 344 345 346 347 348 |
}else if(Chat.e.newestMessage){
Chat.e.newestMessage.scrollIntoView(false);
}
},
toggleChatOnlyMode: function(){
return this.chatOnlyMode(!this.isChatOnlyMode());
},
messageIsInView: function(e){
return e ? overlapsElemView(e, this.e.messagesWrapper) : false;
},
settings:{
get: (k,dflt)=>F.storage.get(k,dflt),
getBool: (k,dflt)=>F.storage.getBool(k,dflt),
set: (k,v)=>F.storage.set(k,v),
|
| ︙ | ︙ | |||
963 964 965 966 967 968 969 |
},{
label: "Images inline",
boolValue: ()=>Chat.settings.getBool('images-inline'),
callback: function(){
const v = Chat.settings.toggle('images-inline');
F.toast.message("Image mode set to "+(v ? "inline" : "hyperlink")+".");
}
| < < < < | 953 954 955 956 957 958 959 960 961 962 963 964 965 966 |
},{
label: "Images inline",
boolValue: ()=>Chat.settings.getBool('images-inline'),
callback: function(){
const v = Chat.settings.toggle('images-inline');
F.toast.message("Image mode set to "+(v ? "inline" : "hyperlink")+".");
}
}];
/** Set up selection list of notification sounds. */
if(true/*flip this to false to enable selection of audio files*/){
settingsOps.push({
label: "Audible alerts",
boolValue: ()=>Chat.settings.getBool('audible-alert'),
|
| ︙ | ︙ | |||
1081 1082 1083 1084 1085 1086 1087 |
return rect.right - popupSize.width;
};
settingsPopup.options.adjustY = function(y){
const rect = settingsButton.getBoundingClientRect();
return rect.top - popupSize.height -2;
};
})()/*#chat-settings-button setup*/;
| < < < < < < < < < < < < < | 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 |
return rect.right - popupSize.width;
};
settingsPopup.options.adjustY = function(y){
const rect = settingsButton.getBoundingClientRect();
return rect.top - popupSize.height -2;
};
})()/*#chat-settings-button setup*/;
/** Callback for poll() to inject new content into the page. jx ==
the response from /chat-poll. If atEnd is true, the message is
appended to the end of the chat list (for loading older
messages), else the beginning (the default). */
const newcontent = function f(jx,atEnd){
if(!f.processPost){
|
| ︙ | ︙ |