Commit graph whatsapp-web.js/index.d.ts
Author SHA1 Message Date
Maksim Koryukov
11594b2887
refactor(client): move sendReaction method to the Client (#201695)
`Message.react` moved to `Client.sendReaction`
2026-04-12 09:30:32 -03:00
Adi1231234
1a9a1b7022
fix: recover ciphertext messages via PLACEHOLDER_MESSAGE_RESEND (PDO type 4) (#182677)
* fix: recover ciphertext messages via PLACEHOLDER_MESSAGE_RESEND

Add automatic recovery for ciphertext messages using WhatsApp's built-in
PLACEHOLDER_MESSAGE_RESEND (PDO type 4). Override the AB test gate and
send recovery requests after a 5s grace period.

Also adds message_ciphertext_failed event at 15s and fixes incorrect
JSDoc on onAddMessageCiphertextEvent.

* fix: skip message event when ciphertext resolves to revoked

when a ciphertext message is revoked before it decrypts, WhatsApp's
internal revoke handler calls model.set({ type: 'revoked', ... }) on
the existing model in place. This triggers change:type on the ciphertext
model, which fired the deferred listener and emitted a spurious message
event with type === 'revoked'.

add an early return in the once('change:type') callback to skip
onaddmessageevent when the resolved type is revoked.

fixes wwebjs/whatsapp-web.js#201668

* fix: use handlePlaceholderMsgsSeen for ciphertext recovery

replace the manual sendPeerDataOperationRequest call with a direct call
to handlePlaceholderMsgsSeen. This adds subtype filtering (skips
bot_unavailable_fanout, hosted_unavailable_fanout,
view_once_unavailable_fanout), an age check (14 day limit via the
placeholder_message_resend_maximum_days_limit AB prop), and internal
deduplication so the same message doesn't get multiple PDO requests.

the true second argument is the 'is visible' flag the function expects.
since the gate override is already in place earlier in the evaluate
block, the function passes its own internal gate check and proceeds
normally.

suggested by @sofi-ans in review.

* fix: batch ciphertext PDO requests instead of sending per-message

handleplaceholdermsgsseen has built-in chunking (batches of 32 per PDO)
but calling it with [msg] per message from Msg.on('add') bypasses that.
collect ciphertext messages into a shared buffer and flush them in a
single call after the 5s grace period.

also guard the failTimer to skip if the message type already changed.

* fix: replace silent catch blocks with established patterns

address reviewer feedback - remove catch (_) { // comment } pattern:
- Gate override now uses injectToFunction (existing utility)
- PDO call uses direct require without silent error swallowing

* fix(types): add on() overload for message_ciphertext_failed event

* fix: skip unavailable fanout placeholders from ciphertext recovery

unavailable fanout placeholders (view_once, hosted, bot) are
unrecoverable - WhatsApp's handlePlaceholderMsgsSeen explicitly
skips them and won't resend via PDO. Without this check, the
15s failTimer fires message_ciphertext_failed as a false positive.
2026-04-01 11:15:54 -03:00
Adi1231234
3e810b6913
feat: add cancelPairingCode() and requestPairingCode() on QR clients (#22449)
* feat: add cancelPairingCode() and allow requestPairingCode()

- requestPairingCode() now exposes onCodeReceivedEvent if needed,
  so it works on clients initialized in QR mode
- Add cancelPairingCode() method to stop pairing and return to QR
- Update TypeScript definitions

* fix(auth): dynamic ADV key in getQR + structural cancelPairingCode

the getQR closure captured advSecretKey once during initialize(), but
requestpairingcode/cancelPairingCode changes the key in IndexedDB.
the stale closure key caused QR scans to fail with HMAC validation error.

fix: read key dynamically via WAWebUserPrefsMultiDevice.getADVSecretKey()
(synchronous in-memory cache) on every getQR call, matching how WhatsApp
web's internal QR component works.

cancelpairingcode now mirrors WhatsApp Web's resetLinkDeviceState:
refreshqr() restarts WebSocket for fresh refs, then
initializeqrlinking() generates a new key. QR emission happens
automatically via the existing change:ref listener.

---------

Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>
2026-03-24 10:01:31 -03:00
2^1
807efd502d
chore: cleanup, ci workflows and formatting (#127064)
* ci: setup workflows, dependabot, labeler and commit linting

* docs: update README, community files and issue templates

* chore: configure prettier, editorconfig and format codebase

* chore: restore changes lost during rebase

* docs: adjust url for new logo

* fix: align badges

* chore: resolve conflicts and re-add temp lint
2026-03-10 01:45:12 +02:00
Rajeh Taher
883d7e4eda
Store: remove all mentions of window.Store (#127077)
* Store: remove all mentions of window.Store

* Apply suggestion from @BenyFilho

Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>

---------

Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>
2026-03-01 16:49:21 -03:00
Rajeh Taher
9b1eb76b2b
general: tree-shaking pre-MD and old comet versions (#5675)
Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>
Co-authored-by: tuyuribr <45042245+tuyuribr@users.noreply.github.com>
2026-02-10 23:24:54 +00:00
BenyFilho
9e0fe29218
New Chat property isLocked (#5798)
* New property isLocked

* New property isLocked
2026-02-06 21:42:51 -03:00
Merlin
42d0c40e2e
Adapt TypeScript Events enum (#3271)
* Add missing js Events to ts Events enum

* Placing back call

Placing back call

* Update index.d.ts

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
Co-authored-by: tuyuribr <45042245+tuyuribr@users.noreply.github.com>
Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>
2026-01-31 13:33:11 -03:00
tuyuribr
0439d7f123
New compatibilities (#3973)
* New compatibilities

* Update Client.js

* 1

* Update Client.js

* 3

* Update Client.js

---------

Co-authored-by: Rajeh Taher <rajeh@reforward.dev>
2025-12-13 06:55:09 +02:00
RendyCraft047
6aa1bd85ab
feat: whatsapp stories implementation (#3994)
* support sending message from status broadcast

* add to index.d.ts

* add method to contact

* new modules

* Update Utils.js

* add for the examples

* add color assertion function

* finishing..

* added waveforms for audio messages and minor fixes

* fix eslint

* refactor

reorganize the store to include additional modules.

* adapt

* the last one.

---------

Co-authored-by: Rajeh Taher <rajeh@reforward.dev>
2025-12-13 06:34:55 +02:00
RendyCraft047
d815847d3e
fix: addition and improvement of enumerable values on types (#3740)
* Update index.d.ts

* Update Constants.js

* fix

* `code_received` is missing too

* album message types

* add to index.d.ts

* fix types error
2025-11-20 11:30:54 +00:00
Jan Loewe
166dc73c73
feat(ScheduledEvent): add none option for callType (#3838) 2025-11-20 11:28:32 +00:00
RendyCraft047
0c36613cc7
feat+fix: send vote messages & vote update event (#3913)
* add send vote function

* Update index.d.ts

* fix and add required modules

* fix poll update in group chat

* adjustments to improvements

* add example usages

* fix eslint

---------

Co-authored-by: Rajeh Taher <rajeh@reforward.dev>
2025-11-09 16:37:51 -03:00
BenyFilho
6876dd236b
Fix method saveOrEditAddressbookContact (#3923)
* Fix method saveOrEditAddressbookContact

* Update saveOrEditAddressbookContact return void

* Update saveOrEditAddressbookContact return void
2025-11-04 16:30:25 -03:00
BenyFilho
7c7851f4d4
feat: getPollVotes (#3807)
* Add required module

* Add getPollVotes function

* Add getPollVotes function

* Add getPollVotes function

* Add Message.getPollVotes

* Add Message.getPollVotes
2025-10-07 19:24:05 +00:00
alechkos
7304ec2135
feat: get/add/edit customer notes (#3806)
* feat: add required module

* feat: add 'addOrEditCustomerNote' function

* feat: add 'getCustomerNote' function

* fix: check for logic availability

* feat: add 'Chat.addOrEditCustomerNote'

* feat: add Chat.getCustomerNote
2025-09-27 11:35:22 -03:00
Fernando Mondo
912b78d299
fix: Add protocolMessageKey and fix revoked messages to preserve original before.id (#3715)
* Add protocolMessageKey and fix revoke

* Add protocolMessageKey and fix revoke

* docs: add explanation
2025-08-28 17:39:22 +03:00
alechkos
bd677a8a66
fix: send message properly (#3692)
* fix: remove high cpu consumption by adding waiting for message logic

 Co-authored-by: Shir Serlui <70711723+shirser121@users.noreply.github.com>

* refactor: use already defined msg id

* refactor: use optional arg for waiting for msg ack
2025-08-12 07:33:02 +03:00
Mob Code 100
b5adf47664
feat: Switch between QR or phone number pairing method (#3180)
* fix(webpack-exodus): Added the new patch

* fix(webpack-exodus): Fixed v2.3000.x and v2.24

* chore(webpack-exodus): eslint

* fix(webpack-exodus): Fixed Store

* fix(webpack-exodus): slight store fix

* chore(webpack-exodus): fix example so that I don't crash on every load

* chore: eslint fix

* fix(webpack-exodus): prevent confusion with build systems

* fix(webpack-exodus): Add proper groups module

* fix(webpack-exodus): Fix order queries

* fix(webpack-exodus): Bad export name

* feat(webpack-exodus): Re-injection, No more selectors, Pairing Code auth

* fix(webpack-exodus): Eslint and better login/logout handling

* fix(webpack-exodus): 2.24 compatibility

* revert testing options

* chore(webpack-exodus): ESLint

* chore(webpack-exodus): final eslint tweak (did not commit with last commit for some reason)

* style: fix broken link in readme file

* fix(webpack-exodus): Fix forwarding messages

* fix(webpack-exodus): finish forwarding function

* Making the ESLint god happy

* Fix window.Store.ProfilePic.profilePicFind is not a function error (#3001)

* Change window.Store.ProfilePic.profilePicFind to window.Store.ProfilePic.requestProfilePicFromServer

* Prevent breaking v2.2x

* refactor: make it more readable

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Sanitize, improves and fixes

* make ESList god happy

* fix getInviteCode for group (#3007) (#3029)

* fix getInviteCode for group (#3007)

* move changes to proper getInviteCode method.

* style fix

* refactor: add try-catch in a case the user is not a group admin

* refactor: handle promise properly

---------

Co-authored-by: Sven Neumann <s.neumann@websix.de>
Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* fixes

* Update LocalWebCache.js

* fix delete on 2.3000 (#3048)

* fix delete on 2.3000

* fix compareWwebVersions

* fix: use proper comparison operator

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Implement bot invoking capabilities (#3009)

* Implement bot invoking capabilities

* Update index.d.ts

* Eslint

* Webpack exodus fix message_reaction event (#3099)

* exposed WAWebAddonReactionTableMode

* capture reaction using WAWebAddonReactionTableMode

* move compareWwebVersions and check version before trying to expose new store

* message_reaction on example.js (#3102)

* handle message_reaction event on example.js

* log wweb version on ready

* fix reactions on pvt chats (#3104)

* New group function

* new group settings

* Update Client.js

* Switch pairing method between QR and phone number

* Remove existing pairing code interval

* Modify example.js

* Update docs

* Small improvements in inject function

* Fix ESLint

* example.js correction

* docs: fix docs for 'requestPairingCode' method

Co-authored-by: Leandro Matilla <30844484+wis-dev@users.noreply.github.com>

* Update Utils.js getChatModel because Meta chat object affected Group Chats

* Ajust to set isGroup as false as default

* Remove the need for custom interval

* Fix typo

* Fix intermittent response bug #9864

Co-authored-by: Mob Code 100 <66469454+MobCode100@users.noreply.github.com>

* fix: eslint fix

* Revert "Remove the need for custom interval"

This reverts commit c5d5e5626684742cadbf58f28739c1c2c9dcc582.

* Add wait for PairingCodeLinkUtils on requestPairingCode

* Remove unused vars WhatsWebStaticURL

Co-authored-by: Mob Code 100 <66469454+MobCode100@users.noreply.github.com>

* style: format code

---------

Co-authored-by: Rajeh Taher <rajeh@reforward.dev>
Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
Co-authored-by: tuyuribr <45042245+tuyuribr@users.noreply.github.com>
Co-authored-by: Seow Zhen Jun <56989187+seowzhenjun0126@users.noreply.github.com>
Co-authored-by: Sven <sven2neumann@gmail.com>
Co-authored-by: Sven Neumann <s.neumann@websix.de>
Co-authored-by: Jorge Rocha Gualtieri <jorge@jrg.com.br>
Co-authored-by: Mateus Mercer <accounts@matbm.net>
Co-authored-by: Leandro Matilla <30844484+wis-dev@users.noreply.github.com>
Co-authored-by: BenyFilho <168232825+BenyFilho@users.noreply.github.com>
Co-authored-by: Shir Serlui <70711723+shirser121@users.noreply.github.com>
2025-08-09 00:37:25 +03:00
alechkos
f9db14d185
feat: Event messages (#3345)
* feat: add createCallLink function

* feat: create Event class

* feat: add functionality for sending Events

* feat: add editEvent function

* refactor: send event location prop as wa does

* refactor: combine modules

* feat: add sendResponseToEvent function

* fix: createEventCallLink parameter

* docs: add documentation

* fix: eslint

* refactor: change timestamp to Date for the user's convenience

* refactor: rename 'Event' to 'ScheduledEvent' for more clarity

* style: fix typo in inner function

* refactor: remove unnecessary inner function

* refactor: rename 'sendResponseToEvent' to 'sendResponseToScheduledEvent' for more clarity

* fix: update the module name
2025-08-09 00:36:27 +03:00
alechkos
18b1d32825
feat: get pinned messages (#3004)
* feat: add getPinnedMessage method

* docs: add docs for the method

* chore: fix eslint

* refactor: change logic of getting pinned messages

* refactor: combine all PinnedMsgUtils

* chore: remove comments and mark as ready for review

* style: fix typo

Co-authored-by: crazynds <36674096+crazynds@users.noreply.github.com>

---------

Co-authored-by: crazynds <36674096+crazynds@users.noreply.github.com>
2025-08-09 00:34:52 +03:00
Eniola Osabiya
44418e66c2
fix(types): update mentions type in MessageEditOptions (#3691)
* fix(types): update mentions type in MessageEditOptions #2166

* style: fix typos

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2025-08-07 09:54:04 +03:00
alechkos
ca30ac4b18
feat: customise linked device name (#3325)
* feat: add functionality for setting device and browser names

* feat: add usage example

* feat: add usage example

* docs: add docs for new functionality

* docs: add missing property

* docs: supplement the implementation documentation
2025-08-06 15:50:42 +03:00
BenyFilho
81fd090e36
fix: Client.createGroup + GroupChat.addParticipants (#3670)
* Adjustment addParticipants

* createGroup fully refactored, fixed bugs, added creation options and updated docs

* fix: eslint fix

* refactor: GroupChat.addParticipants fully refactored

* fix: eslint fix

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2025-08-01 06:43:45 +03:00
BenyFilho
81fb154a9f
feat: getContactLidAndPhone (#3673)
* Add method getContactLidOrPhone

* Add method getContactLidOrPhone

* Add method getContactLidOrPhone

* Add method getContactLidOrPhone

* Add method getContactLidOrPhone

* Add method getContactLidOrPhone

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Add method getContactLidOrPhone

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Add method getContactLidOrPhone

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Add method getContactLidOrPhone

* Delete docs/index.html

* Delete docs/Client.html

* Create Client.html

* Create index.html

* Update to return the object

* Update to return an object

* Update Client.js to return both objects lid and phone

* Update Client.js to return both objects lid and phone

* Update src/Client.js

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Update src/Client.js

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Update index.d.ts

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* refactor: rename function name for more clarity

* Change accept and return Array

* Change accept and return Array

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2025-07-29 17:39:39 +03:00
Swaraj Chavan
fcb58d3070
Fix TS2371 error in requestPairingCode type declaration (#3622) 2025-06-30 09:33:54 +03:00
tofers
0ffb66fdb1
feat: send Media HD (#3535)
* Changing the quality of media downloads

* return function result

* add option sendImageAsHd

* change example

* fix quotes

* chore: remove unused code

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2025-06-02 22:19:22 +03:00
Yusif Aliyev
94ce20b4a5
fix: change mentionedIds type from ChatId[] to string[] in Message (#3581)
* fix: change mentionedIds type from ChatId[] to string[] in Message interface

* fix: correct types for mentionedIds and groupMentions

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2025-06-02 21:05:18 +03:00
alechkos
f7d0456a49
hotfix: fix window.WWebJS.getChatModel (#3573) 2025-06-01 23:37:21 -03:00
alechkos
d0642b761c
feat: Channel (#2620)
* window.injectToFunction clarifications

* added createChannel method

* initial Channel class structure

* added getChannelById and getChannels methods

* added 4 methods to change channel metadata

* added deleteChannel method

* added subscribe to/unsubscribe from channel methods

* ecmaVersion updated to 2022

* added searchChannels method

* refactoring of: getChat, getChannel, getChatModel, getChannelModel

* removed Channel.canSend

* sendMessage updated to support channels [p1]

* createChannel: returns string if an error occupied

* added getSubscribers

* added mute/unmute methods

* searchChannels: minor update

* sendMessage updated to support channels [p2]

- added support to send image, sticker, gif and video

* [REFAC] refactored chat retrieving in getChatOrChannel

* [FEAT] added getChannelByInviteCode method

* [CHG] added check if channel creation enabled

* [FEAT] added sendChannelAdminInvitation method

* [WIP] preparations for sending polls [p1]

* [BUG] fixed some internal functions

* [BUG] fixed poll creation

* [COPY] renamed some internal functions

- window.WWebJS.getChatOrChannel renamed back to window.WWebJS.getChat
-window.WWebJS.getChatOrChannelModel renamed back to window.WWebJS.getChatModel

* fix: typo

* fix: send docs without caption

* fix: fixed some internal function

* fix: channel retrieving

* fix: fixed internal getChannelMetadata function

* fix: fixed channel admin can unsubscribe from channel

* feat: channel admin functionality

* feat: added fetchMessages method

Co-authored-by: tuke307 <58882912+tuke307@users.noreply.github.com>

* refactor: revert removing support for Buttons and Lists

Note: buttons and lists are deprecated

* refactor: revert parameter name from 'chatOrChannel' to 'chat'

* fix: support Node v12

* refactor: return 'undefined' in a case of falsy value

* refactor: use already created variable

* docs: fix 'countryCodes' property type

* fix: 'searchChannels' method fixed

* fix: add check in 'setReactionSetting' method

* sendNewsletterMessageJob requires a proper Msg Object in 2.24xx (#10)

Co-authored-by: Sven Neumann <s.neumann@websix.de>

* style: fix broken link in readme file

* fix: only directPath determines whether hasMedia or not

fixes #2952

* fix: get rid of unnecessary 'await'

* feat: add option to send polls in channels

* refactor: get channel instances with 'getChatById'

* chore: fix eslint

* fix: fatal error

* refactor: delete local models by default when unsubscribing

* fix: prevent TypeError if no channel models are returned

* fix: update 'searchChannels' function for WWeb > 2.3000.0

* fix: fix for 'getChannelByInviteCode' function

* fix: fix for 'sendChannelAdminInvite' function

* fix: update 'fetchMessages' for channels

* refactor: update 'setReactionSetting' function

* fix: update 'sendMessage' for channels

* feat: add 'transferChannelOwnership' function

* refactor: add 'deleteChannel' function to 'Client'

* style: fix project code style

* chore: eslint fix

* feat: add 'sendSeen' function

* fix: fix the function restoration after injection

* refactor: remove duplicate module

* fix: get isNewsletter properly

* fix: fix channels media - add mediaHandle

Co-authored-by: devlikepro <155617407+devlikepro@users.noreply.github.com>

---------

Co-authored-by: tuke307 <58882912+tuke307@users.noreply.github.com>
Co-authored-by: Sven <sven2neumann@gmail.com>
Co-authored-by: Sven Neumann <s.neumann@websix.de>
Co-authored-by: devlikepro <155617407+devlikepro@users.noreply.github.com>
2025-05-31 21:36:19 +03:00
alechkos
91217f87ba
fix: Chat.isMuted (#2999)
* fix: isMuted returns true or false

* docs: add missing parts

* refactor: apply simplification

* fix: update chat instance after calling mute/unmute

* stylee: clarify and fix docs

* fix: fix convertation of Date to timestamp

* refactor: small code refactor
2025-05-30 16:41:31 +03:00
alechkos
d29eaf7def
feat: save contact to addressbook (#3533)
* feat: add respectfull modules

* feat: add saveOrEditAddressbookContact function

* feat: add deleteAddressbookContact function

* refactor: import necessary type for return value

* style: fix typo

* docs: add ocs

* style: fix typo
2025-05-30 16:39:32 +03:00
WavyCat
3836309f99
Fix the Location declaration (#3555)
Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2025-05-30 16:28:40 +03:00
alechkos
bad202d2bc
fix: fix 'delete' method for messages (#3301) 2025-05-30 15:51:41 +03:00
tofers
c0ba5e545b
feat: Setting background synchronization (#3331)
* Changing the background synchronization setting

* add  example

* return function

* style: add clarification note

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
Co-authored-by: Shir Serlui <70711723+shirser121@users.noreply.github.com>
2025-05-30 11:06:08 +03:00
tuyuribr
ad11b5bfee
Send message without quote if quoteFails (#3475)
* Send message without quote if quoteFails

New option to send a message without quote when quotedMessage fails

* Rest

* Changing to sendMessage level

* Update Utils.js

* Update Utils.js

* Update Utils.js

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2025-04-24 18:10:39 -03:00
devlikeapro
f56d25f1c4
Add max retries for fs.promises.rm (#3351) 2024-12-23 19:33:08 +02:00
tofers
5b0e139ad4
Get Stories (#3294)
* Get all broadcast

* fixed return msgs

* feat: add usage example

* Update src/structures/Broadcast.js

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2024-09-30 20:33:31 +03:00
alechkos
5b0e0612de
fix: make function getContactDeviceCount work (#3284)
Co-authored-by: Shir Serlui <70711723+shirser121@users.noreply.github.com>
2024-09-23 17:12:17 +03:00
Kang
0fa6ebb66d
Sync history conversation of the Chat (#3281)
* Sync historical message

* Add documentation

* Code simplify

* feat: add syncHistory method in Chat class

* docs: update docs

* chore: update examples

* fix: handle asynchronous function properly

* refactor: include await

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2024-09-20 11:29:08 +03:00
tuyuribr
d2597bba72
Count user connected devices (#3223)
* Update Store.js

* All

* Make Eslist god happy

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
Co-authored-by: Shir Serlui <70711723+shirser121@users.noreply.github.com>
2024-09-18 10:33:23 +03:00
Rajeh Taher
13ce571c64
Farewell, Webpack! Re-injection, Pairing Code login, and 2.24x jumbofix (#2816)
* fix(webpack-exodus): Added the new patch

* fix(webpack-exodus): Fixed v2.3000.x and v2.24

* chore(webpack-exodus): eslint

* fix(webpack-exodus): Fixed Store

* fix(webpack-exodus): slight store fix

* chore(webpack-exodus): fix example so that I don't crash on every load

* chore: eslint fix

* fix(webpack-exodus): prevent confusion with build systems

* fix(webpack-exodus): Add proper groups module

* fix(webpack-exodus): Fix order queries

* fix(webpack-exodus): Bad export name

* feat(webpack-exodus): Re-injection, No more selectors, Pairing Code auth

* fix(webpack-exodus): Eslint and better login/logout handling

* fix(webpack-exodus): 2.24 compatibility

* revert testing options

* chore(webpack-exodus): ESLint

* chore(webpack-exodus): final eslint tweak (did not commit with last commit for some reason)

* style: fix broken link in readme file

* fix(webpack-exodus): Fix forwarding messages

* fix(webpack-exodus): finish forwarding function

* Making the ESLint god happy

* Fix window.Store.ProfilePic.profilePicFind is not a function error (#3001)

* Change window.Store.ProfilePic.profilePicFind to window.Store.ProfilePic.requestProfilePicFromServer

* Prevent breaking v2.2x

* refactor: make it more readable

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Sanitize, improves and fixes

* make ESList god happy

* fix getInviteCode for group (#3007) (#3029)

* fix getInviteCode for group (#3007)

* move changes to proper getInviteCode method.

* style fix

* refactor: add try-catch in a case the user is not a group admin

* refactor: handle promise properly

---------

Co-authored-by: Sven Neumann <s.neumann@websix.de>
Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* fixes

* Update LocalWebCache.js

* fix delete on 2.3000 (#3048)

* fix delete on 2.3000

* fix compareWwebVersions

* fix: use proper comparison operator

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>

* Implement bot invoking capabilities (#3009)

* Implement bot invoking capabilities

* Update index.d.ts

* Eslint

* Webpack exodus fix message_reaction event (#3099)

* exposed WAWebAddonReactionTableMode

* capture reaction using WAWebAddonReactionTableMode

* move compareWwebVersions and check version before trying to expose new store

* message_reaction on example.js (#3102)

* handle message_reaction event on example.js

* log wweb version on ready

* fix reactions on pvt chats (#3104)

* New group function

* new group settings

* Update Client.js

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
Co-authored-by: tuyuribr <45042245+tuyuribr@users.noreply.github.com>
Co-authored-by: Seow Zhen Jun <56989187+seowzhenjun0126@users.noreply.github.com>
Co-authored-by: Sven <sven2neumann@gmail.com>
Co-authored-by: Sven Neumann <s.neumann@websix.de>
Co-authored-by: Jorge Rocha Gualtieri <jorge@jrg.com.br>
Co-authored-by: Mateus Mercer <accounts@matbm.net>
2024-07-23 22:19:22 -03:00
Thomas
41b280c769
Expose chat pinned property (#2771)
Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2024-05-01 07:57:19 +03:00
alechkos
01714fe599
feat: vote_update event (#2596)
* Merge branch 'add-polls' into polls-ext

* added listener to poll votes

* added isUnvote property

* added option for custom message secret

* usage example updated

* added logic for catching removed votes

* usage example updated

* fixed logic for poll vote events

* temp usage example

* No more `isCurrentState`

* messageSecret converted to array

Co-authored-by: tuyuribr <45042245+tuyuribr@users.noreply.github.com>

* docs updated

* we already have messageSecret in vote.parentMessage

* PollVote.selectedOptions changed to be similar to pollOptions

* docs fixed

* window.injectToFunction clarifications

* minor clarifications

* fix: typo

* style: fix broken link in readme file

---------

Co-authored-by: tuyuribr <45042245+tuyuribr@users.noreply.github.com>
2024-04-30 20:23:17 +03:00
Gulg
b99d28c5c6
Add members settings (#2788)
* Update GroupChat.js

* Update index.d.ts

* style: clarify method doc

* refactor: add additional check

* fix: provide valid error name

---------

Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2024-04-28 16:22:07 +03:00
Pierre CORSINI
ef2f725bce
Fix TS compilation error "Statements are not allowed in ambient contexts" by removing semicolons. (#2697)
Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2024-01-18 07:50:00 +02:00
alechkos
e0d955f130
feat: group mentions + improved user mentions (#2602)
* added logic to mention groups + fixed user mentions

* usage example updated

* docs fixed

* window.injectToFunction clarifications

* usage example clarifications

* fix: typo

* docs: added missed docs
2024-01-11 10:33:10 +02:00
alechkos
8d683a668b
feat: pin/unpin messages (#2692)
* feat: add Message.pin and Message.unpin methods

* feat: added usage example

* docs: clarifications
2024-01-11 10:24:02 +02:00
tofers
1dd35be834
feat: event message_ciphertext (#2292)
* add option cipherMsg

* add event  message_ciphertext

* example

* remove option cipherMsg

* removing unlinked code

* Update Client.js

---------

Co-authored-by: Shir Serlui <70711723+shirser121@users.noreply.github.com>
Co-authored-by: alechkos <93551621+alechkos@users.noreply.github.com>
2023-12-16 17:10:26 +01:00
alechkos
981fa822a0
fix: send docs without caption (#2660)
* fix: allow to send docs without a caption

* fix: typo

* fix: async function proper handling
2023-12-12 18:36:44 -03:00