@scalemule/nextjs 0.1.51 → 0.1.53
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.
- package/README.md +51 -5
- package/dist/client.d.mts +6 -1
- package/dist/client.d.ts +6 -1
- package/dist/client.js +24 -4
- package/dist/client.mjs +24 -4
- package/dist/{index-BQgmT53x.d.mts → index-2PnO4RAF.d.mts} +19 -5
- package/dist/{index-BQgmT53x.d.ts → index-2PnO4RAF.d.ts} +19 -5
- package/dist/index.d.mts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +136 -48
- package/dist/index.mjs +136 -48
- package/dist/server/auth.d.mts +7 -2
- package/dist/server/auth.d.ts +7 -2
- package/dist/server/auth.js +260 -39
- package/dist/server/auth.mjs +260 -40
- package/dist/server/index.d.mts +24 -5
- package/dist/server/index.d.ts +24 -5
- package/dist/server/index.js +286 -66
- package/dist/server/index.mjs +286 -66
- package/dist/server/webhook-handler.d.mts +2 -2
- package/dist/server/webhook-handler.d.ts +2 -2
- package/dist/testing.d.mts +1 -1
- package/dist/testing.d.ts +1 -1
- package/dist/{webhook-handler-44RRJH-r.d.ts → webhook-handler-1nnrmWT0.d.ts} +11 -1
- package/dist/{webhook-handler-DKt6H8FB.d.mts → webhook-handler-DNpCXDDA.d.mts} +11 -1
- package/docs/network-audio.md +10 -5
- package/package.json +2 -2
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { g as createWebhookHandler } from '../webhook-handler-
|
|
1
|
+
export { g as createWebhookHandler } from '../webhook-handler-DNpCXDDA.mjs';
|
|
2
2
|
import '@scalemule/money';
|
|
3
|
-
import '../index-
|
|
3
|
+
import '../index-2PnO4RAF.mjs';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { g as createWebhookHandler } from '../webhook-handler-
|
|
1
|
+
export { g as createWebhookHandler } from '../webhook-handler-1nnrmWT0.js';
|
|
2
2
|
import '@scalemule/money';
|
|
3
|
-
import '../index-
|
|
3
|
+
import '../index-2PnO4RAF.js';
|
package/dist/testing.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { U as User, A as ApiError,
|
|
3
|
+
import { U as User, A as ApiError, ad as StorageFile } from './index-2PnO4RAF.mjs';
|
|
4
4
|
|
|
5
5
|
interface MockUserOptions {
|
|
6
6
|
id?: string;
|
package/dist/testing.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { U as User, A as ApiError,
|
|
3
|
+
import { U as User, A as ApiError, ad as StorageFile } from './index-2PnO4RAF.js';
|
|
4
4
|
|
|
5
5
|
interface MockUserOptions {
|
|
6
6
|
id?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MoneyClient } from '@scalemule/money';
|
|
2
|
-
import { A as ApiError,
|
|
2
|
+
import { A as ApiError, a3 as RegisterRequest, q as ClientContext, U as User, L as LoginResponse, y as LoginRequest, c as ListFilesParams, w as ListFilesResponse, ad as StorageFile, aj as UploadResponse } from './index-2PnO4RAF.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Server-Side ScaleMule Client
|
|
@@ -49,6 +49,16 @@ declare class ScaleMuleServer {
|
|
|
49
49
|
*/
|
|
50
50
|
private request;
|
|
51
51
|
auth: {
|
|
52
|
+
/** Issue a 60-second, single-use transfer code after a server OAuth callback. */
|
|
53
|
+
createSessionHandoff: (sessionToken: string, audience: string) => Promise<{
|
|
54
|
+
code: string;
|
|
55
|
+
expires_in: number;
|
|
56
|
+
}>;
|
|
57
|
+
/** Exchange only on the server; write the returned session into an HTTP-only cookie. */
|
|
58
|
+
exchangeSessionHandoff: (code: string, audience: string) => Promise<{
|
|
59
|
+
session_token: string;
|
|
60
|
+
user_id: string;
|
|
61
|
+
}>;
|
|
52
62
|
/**
|
|
53
63
|
* Register a new user
|
|
54
64
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MoneyClient } from '@scalemule/money';
|
|
2
|
-
import { A as ApiError,
|
|
2
|
+
import { A as ApiError, a3 as RegisterRequest, q as ClientContext, U as User, L as LoginResponse, y as LoginRequest, c as ListFilesParams, w as ListFilesResponse, ad as StorageFile, aj as UploadResponse } from './index-2PnO4RAF.mjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Server-Side ScaleMule Client
|
|
@@ -49,6 +49,16 @@ declare class ScaleMuleServer {
|
|
|
49
49
|
*/
|
|
50
50
|
private request;
|
|
51
51
|
auth: {
|
|
52
|
+
/** Issue a 60-second, single-use transfer code after a server OAuth callback. */
|
|
53
|
+
createSessionHandoff: (sessionToken: string, audience: string) => Promise<{
|
|
54
|
+
code: string;
|
|
55
|
+
expires_in: number;
|
|
56
|
+
}>;
|
|
57
|
+
/** Exchange only on the server; write the returned session into an HTTP-only cookie. */
|
|
58
|
+
exchangeSessionHandoff: (code: string, audience: string) => Promise<{
|
|
59
|
+
session_token: string;
|
|
60
|
+
user_id: string;
|
|
61
|
+
}>;
|
|
52
62
|
/**
|
|
53
63
|
* Register a new user
|
|
54
64
|
*/
|
package/docs/network-audio.md
CHANGED
|
@@ -11,7 +11,7 @@ React at runtime. Existing `AudioPlayer` and `NarrationPlayer` APIs are unchange
|
|
|
11
11
|
| Client-side navigation under the same provider | The same audio element continues playing. |
|
|
12
12
|
| Leaving the narrated article | Highlighting is destroyed; audio continues. |
|
|
13
13
|
| Returning to that article | Highlighting resumes at the current clock if enabled. |
|
|
14
|
-
|
|
|
14
|
+
| Following a network link in the original reader tab to another participating domain | A previously opened network player window keeps playing. The destination bar reconnects. |
|
|
15
15
|
| Full navigation/reload without a network window | The old audio stops. An optional checkpoint restores the queue and position paused. |
|
|
16
16
|
| Closing the network window | The reader restores the latest reported queue and position paused, with a Play prompt. |
|
|
17
17
|
| Closing the reader tab | The network window can continue independently. |
|
|
@@ -24,8 +24,11 @@ policy. Once playing, navigation of its original reader tab does not replace its
|
|
|
24
24
|
audio element. Browser/OS suspension can still interrupt media, especially on
|
|
25
25
|
mobile. Test supported browsers before promising uninterrupted listening.
|
|
26
26
|
|
|
27
|
-
This implementation reconnects the **original reader tab**
|
|
28
|
-
|
|
27
|
+
This implementation reconnects the **original reader tab** when readers follow
|
|
28
|
+
links between participating sites. Direct address-bar or browser-initiated
|
|
29
|
+
cross-site navigation can sever the window relationship: audio continues in the
|
|
30
|
+
player window, but the destination bar may not reconnect. Use the player window's
|
|
31
|
+
controls in that case. It does not discover unrelated tabs or synchronize devices. COOP headers that
|
|
29
32
|
sever `window.opener`, sandbox restrictions and popup blockers can prevent the
|
|
30
33
|
connection. Failed initial connections preserve local playback and show a notice.
|
|
31
34
|
An unresponsive remote player never triggers automatic local playback, which
|
|
@@ -205,8 +208,10 @@ The automated suite covers article unmounts, highlighting cleanup/return, queue
|
|
|
205
208
|
advancement, publication identity, stale/aborted requests, signed URL refresh,
|
|
206
209
|
autoplay denial, bounded recovery, blocked popups, exact origin/source checks,
|
|
207
210
|
remote reconnect and host closure. Also test real media in supported browsers:
|
|
208
|
-
start in the reader, open the network window,
|
|
209
|
-
allowed origin, control playback from the destination,
|
|
211
|
+
start in the reader, open the network window, follow an actual network link in
|
|
212
|
+
the original tab to another allowed origin, control playback from the destination,
|
|
213
|
+
and close the host. Browser automation that changes the address directly does not
|
|
214
|
+
exercise the same window relationship as clicking a site link.
|
|
210
215
|
Verify ad consent and publication authorization in the actual applications.
|
|
211
216
|
Release the SDK, integrate layouts/routes/resolvers in the participating sites,
|
|
212
217
|
then deploy through their existing release process. These SDK changes alone do
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scalemule/nextjs",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.53",
|
|
4
4
|
"description": "ScaleMule SDK for Next.js applications - authentication, storage, and user management",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
"dependencies": {
|
|
69
69
|
"@scalemule/ledvery": "^0.0.1",
|
|
70
70
|
"@scalemule/money": "^0.0.1",
|
|
71
|
-
"@scalemule/sdk": "^0.0.
|
|
71
|
+
"@scalemule/sdk": "^0.0.69"
|
|
72
72
|
},
|
|
73
73
|
"peerDependencies": {
|
|
74
74
|
"next": ">=14.0.0",
|