chore: mark version v1.1.0

This commit is contained in:
Pedro Lopez
2020-02-26 23:34:01 -04:00
parent bb40218c66
commit 130da046f5
30 changed files with 886 additions and 168 deletions

View File

@@ -4,7 +4,7 @@
<head>
<meta name="generator" content="JSDoc 3.6.3">
<meta charset="utf-8">
<title>whatsapp-web.js 1.0.2 &raquo; Source: structures/Chat.js</title>
<title>whatsapp-web.js 1.1.0 &raquo; Source: structures/Chat.js</title>
<link rel="stylesheet" href="https://brick.a.ssl.fastly.net/Karla:400,400i,700,700i" type="text/css">
<link rel="stylesheet" href="https://brick.a.ssl.fastly.net/Noto+Serif:400,400i,700,700i" type="text/css">
<link rel="stylesheet" href="https://brick.a.ssl.fastly.net/Inconsolata:500" type="text/css">
@@ -15,7 +15,7 @@
<nav id="jsdoc-navbar" role="navigation" class="jsdoc-navbar">
<div id="jsdoc-navbar-container">
<div id="jsdoc-navbar-content">
<a href="index.html" class="jsdoc-navbar-package-name">whatsapp-web.<wbr>js 1.<wbr>0.<wbr>2</a>
<a href="index.html" class="jsdoc-navbar-package-name">whatsapp-web.<wbr>js 1.<wbr>1.<wbr>0</a>
</div>
</div>
</nav>
@@ -81,6 +81,12 @@ class Chat extends Base {
*/
this.timestamp &#x3D; data.t;
/**
* Indicates if the Chat is archived
* @type {boolean}
*/
this.archived &#x3D; data.archive;
return super._patch(data);
}
@@ -93,6 +99,41 @@ class Chat extends Base {
async sendMessage(content, options) {
return this.client.sendMessage(this.id._serialized, content, options);
}
/**
* Clears all messages from the chat
* @returns {Promise&amp;lt;Boolean&gt;} result
*/
async clearMessages() {
return this.client.pupPage.evaluate(chatId &#x3D;&gt; {
return window.WWebJS.sendClearChat(chatId);
}, this.id._serialized);
}
/**
* Deletes the chat
* @returns {Promise&amp;lt;Boolean&gt;} result
*/
async delete() {
return this.client.pupPage.evaluate(chatId &#x3D;&gt; {
return window.WWebJS.sendDeleteChat(chatId);
}, this.id._serialized);
}
/**
* Archives this chat
*/
async archive() {
return this.client.archiveChat(this.id._serialized);
}
/**
* un-archives this chat
*/
async unarchive() {
return this.client.unarchiveChat(this.id._serialized);
}
}
module.exports &#x3D; Chat;</code></pre>
@@ -105,7 +146,7 @@ module.exports &#x3D; Chat;</code></pre>
<footer id="jsdoc-footer" class="jsdoc-footer">
<div id="jsdoc-footer-container">
<p>
Generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc</a> 3.6.3 on February 10, 2020.
Generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc</a> 3.6.3 on February 26, 2020.
</p>
</div>
</footer>