@albionlabs/chat-widget 0.2.3 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -121,9 +121,14 @@
121
121
  statement: 'Sign in to quant.bot'
122
122
  });
123
123
 
124
+ // personal_sign expects hex-encoded data per EIP-191
125
+ const hexMessage = '0x' + Array.from(new TextEncoder().encode(message))
126
+ .map((b) => b.toString(16).padStart(2, '0'))
127
+ .join('');
128
+
124
129
  const signature = await provider.request({
125
130
  method: 'personal_sign',
126
- params: [message, walletAddress]
131
+ params: [hexMessage, walletAddress]
127
132
  }) as string;
128
133
 
129
134
  const result = await login(signature, message, walletAddress);
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const WIDGET_VERSION = "0.2.3";
1
+ export declare const WIDGET_VERSION = "0.2.4";
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const WIDGET_VERSION = '0.2.3';
1
+ export const WIDGET_VERSION = '0.2.4';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@albionlabs/chat-widget",
3
- "version": "0.2.3",
3
+ "version": "0.2.4",
4
4
  "type": "module",
5
5
  "repository": {
6
6
  "type": "git",