mirror of
https://github.com/LC044/WeChatMsg
synced 2024-11-14 05:21:41 +08:00
commit
0a69b7b749
@ -82,10 +82,12 @@ class HtmlExporter(ExporterBase):
|
||||
try:
|
||||
audio_path = media_msg_db.get_audio_path(msgSvrId, output_path=origin_docx_path + "/voice")
|
||||
audio_path = "./voice/" + os.path.basename(audio_path)
|
||||
voice_to_text = escape_js_and_html(media_msg_db.get_audio_text(str_content))
|
||||
except:
|
||||
logger.error(traceback.format_exc())
|
||||
return
|
||||
voice_to_text = media_msg_db.get_audio_text(str_content)
|
||||
if voice_to_text and voice_to_text != "":
|
||||
voice_to_text = escape_js_and_html(voice_to_text)
|
||||
doc.write(
|
||||
f'''{{ type:34, text:'{audio_path}',is_send:{is_send},avatar_path:'{avatar}',voice_to_text:'{voice_to_text}',timestamp:{timestamp},is_chatroom:{is_chatroom},displayname:'{display_name}'}},'''
|
||||
)
|
||||
|
@ -217,7 +217,7 @@ audio{
|
||||
}
|
||||
|
||||
.chat-music-audio .player-original p ,.chat-file .app-info p{
|
||||
margin-top: 5px;
|
||||
margin-top: 3px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
@ -239,8 +239,11 @@ audio{
|
||||
.chat-music-audio .player-info ,.chat-file .file-info{
|
||||
width: 200px;
|
||||
height: 80px;
|
||||
margin-left: 4px;
|
||||
margin-top: 15px;
|
||||
white-space: normal;
|
||||
flex-basis: 200px;
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.chat-music-audio .song-title,.chat-file .file-name {
|
||||
@ -249,10 +252,20 @@ audio{
|
||||
}
|
||||
|
||||
.chat-music-audio .artist ,.chat-file .file-size{
|
||||
margin-top: 10px;
|
||||
margin-top: 5px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
.app-info {
|
||||
font-size: 13px;
|
||||
margin-left: 3px;
|
||||
margin-right: 3px;
|
||||
}
|
||||
|
||||
.file-size {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.chat-music-audio .play-button {
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
@ -754,8 +767,8 @@ input {
|
||||
<div class="file-img flex2">
|
||||
<img src="${message.icon_path}"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="app-info"><p>${message.app_name}</p></div>`
|
||||
</div>` +
|
||||
(message.app_name ? `<div class="app-info"><p>${message.app_name}</p></div>` : "");
|
||||
return messageFileTag;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user