@whooshbang/sdk 1.0.0-rc.26 → 1.0.0-rc.28
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 +15 -3
- package/dist/recipient/element.d.ts +51 -0
- package/dist/recipient/element.js +868 -0
- package/dist/recipient/element.js.map +1 -0
- package/dist/recipient/handoff.d.ts +78 -0
- package/dist/recipient/handoff.js +96 -0
- package/dist/recipient/handoff.js.map +1 -0
- package/dist/recipient/i18n/ar.d.ts +3 -0
- package/dist/recipient/i18n/ar.js +33 -0
- package/dist/recipient/i18n/ar.js.map +1 -0
- package/dist/recipient/i18n/catalog.d.ts +68 -0
- package/dist/recipient/i18n/catalog.js +74 -0
- package/dist/recipient/i18n/catalog.js.map +1 -0
- package/dist/recipient/i18n/de.d.ts +3 -0
- package/dist/recipient/i18n/de.js +33 -0
- package/dist/recipient/i18n/de.js.map +1 -0
- package/dist/recipient/i18n/en.d.ts +3 -0
- package/dist/recipient/i18n/en.js +33 -0
- package/dist/recipient/i18n/en.js.map +1 -0
- package/dist/recipient/i18n/es.d.ts +3 -0
- package/dist/recipient/i18n/es.js +33 -0
- package/dist/recipient/i18n/es.js.map +1 -0
- package/dist/recipient/i18n/fa.d.ts +3 -0
- package/dist/recipient/i18n/fa.js +33 -0
- package/dist/recipient/i18n/fa.js.map +1 -0
- package/dist/recipient/i18n/fr.d.ts +3 -0
- package/dist/recipient/i18n/fr.js +33 -0
- package/dist/recipient/i18n/fr.js.map +1 -0
- package/dist/recipient/i18n/hi.d.ts +3 -0
- package/dist/recipient/i18n/hi.js +33 -0
- package/dist/recipient/i18n/hi.js.map +1 -0
- package/dist/recipient/i18n/id.d.ts +3 -0
- package/dist/recipient/i18n/id.js +33 -0
- package/dist/recipient/i18n/id.js.map +1 -0
- package/dist/recipient/i18n/it.d.ts +3 -0
- package/dist/recipient/i18n/it.js +33 -0
- package/dist/recipient/i18n/it.js.map +1 -0
- package/dist/recipient/i18n/nl.d.ts +3 -0
- package/dist/recipient/i18n/nl.js +33 -0
- package/dist/recipient/i18n/nl.js.map +1 -0
- package/dist/recipient/i18n/pl.d.ts +3 -0
- package/dist/recipient/i18n/pl.js +33 -0
- package/dist/recipient/i18n/pl.js.map +1 -0
- package/dist/recipient/i18n/pt-BR.d.ts +3 -0
- package/dist/recipient/i18n/pt-BR.js +33 -0
- package/dist/recipient/i18n/pt-BR.js.map +1 -0
- package/dist/recipient/i18n/ru.d.ts +3 -0
- package/dist/recipient/i18n/ru.js +33 -0
- package/dist/recipient/i18n/ru.js.map +1 -0
- package/dist/recipient/i18n/tr.d.ts +3 -0
- package/dist/recipient/i18n/tr.js +33 -0
- package/dist/recipient/i18n/tr.js.map +1 -0
- package/dist/recipient/i18n/uk.d.ts +3 -0
- package/dist/recipient/i18n/uk.js +33 -0
- package/dist/recipient/i18n/uk.js.map +1 -0
- package/dist/recipient/i18n/zh-Hans.d.ts +3 -0
- package/dist/recipient/i18n/zh-Hans.js +33 -0
- package/dist/recipient/i18n/zh-Hans.js.map +1 -0
- package/dist/recipient/index.d.ts +5 -0
- package/dist/recipient/index.js +6 -0
- package/dist/recipient/index.js.map +1 -0
- package/dist/recipient/mount.d.ts +20 -0
- package/dist/recipient/mount.js +26 -0
- package/dist/recipient/mount.js.map +1 -0
- package/dist/recipient/view.d.ts +69 -0
- package/dist/recipient/view.js +119 -0
- package/dist/recipient/view.js.map +1 -0
- package/package.json +23 -4
package/README.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# `@whooshbang/sdk`
|
|
2
2
|
|
|
3
|
-
Fetch-injected, ESM-only client
|
|
4
|
-
contract. The package has no automatic retry
|
|
5
|
-
Node-only runtime import, or Cloudflare binding.
|
|
3
|
+
Fetch-injected, ESM-only client and opt-in browser recipient surface for the
|
|
4
|
+
release-candidate WhooshBang V1 contract. The package has no automatic retry
|
|
5
|
+
policy, persistence, telemetry, Node-only runtime import, or Cloudflare binding.
|
|
6
6
|
|
|
7
7
|
Install the current release candidate from the public npm registry:
|
|
8
8
|
|
|
@@ -163,6 +163,18 @@ owner-voiced key enum as the service. Effective embedded-panel overrides arrive
|
|
|
163
163
|
through the session's sparse `panel_copy`; mandatory system-owned strings are
|
|
164
164
|
not writable SDK inputs.
|
|
165
165
|
|
|
166
|
+
The framework-neutral recipient settings UI ships in browser-only subpaths:
|
|
167
|
+
import `@whooshbang/sdk/recipient/element` to register
|
|
168
|
+
`<whooshbang-recipient-settings>`, or import `mountRecipientSettings` from
|
|
169
|
+
`@whooshbang/sdk/recipient` for an imperative mount. These subpaths are kept out
|
|
170
|
+
of the package root, so a server or Worker importing `@whooshbang/sdk` never
|
|
171
|
+
evaluates DOM globals. These subpaths are published in
|
|
172
|
+
`@whooshbang/sdk@1.0.0-rc.27`; `1.0.0-rc.26` does not contain them.
|
|
173
|
+
|
|
174
|
+
`@whooshbang/sdk@1.0.0-rc.28` adds the accessible WhooshBang attribution and
|
|
175
|
+
canonical red fallback while leaving every configured customer name, logo, and
|
|
176
|
+
accent authoritative.
|
|
177
|
+
|
|
166
178
|
## Machine clients
|
|
167
179
|
|
|
168
180
|
`createMachineCredential` generates the C0-03 secret with Web Crypto and
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { type CreateRecipientSessionResponse } from "@whooshbang/contracts";
|
|
2
|
+
export declare const RECIPIENT_SETTINGS_ELEMENT = "whooshbang-recipient-settings";
|
|
3
|
+
export interface RecipientSettingsConfiguration {
|
|
4
|
+
/** Where the recipient-session API lives. Defaults to the hosted service. */
|
|
5
|
+
readonly baseUrl?: string;
|
|
6
|
+
/**
|
|
7
|
+
* How the recipient reaches the provider.
|
|
8
|
+
*
|
|
9
|
+
* `popup` keeps them on the page and is the default. `redirect` navigates
|
|
10
|
+
* the whole tab and comes back to the destination the integrator's backend
|
|
11
|
+
* named with `return_to` — the right choice for a host that cannot use a
|
|
12
|
+
* popup at all, and the reason a session without a registered return
|
|
13
|
+
* destination refuses to create one.
|
|
14
|
+
*/
|
|
15
|
+
readonly completionMode?: "popup" | "redirect";
|
|
16
|
+
/**
|
|
17
|
+
* Where the hosted handoff page lives.
|
|
18
|
+
*
|
|
19
|
+
* Only a local or staging build should set this. Production leaves it at the
|
|
20
|
+
* canonical origin, which is the one a popup completion is accepted from.
|
|
21
|
+
*/
|
|
22
|
+
readonly hostedOrigin?: string;
|
|
23
|
+
}
|
|
24
|
+
type SessionInput = CreateRecipientSessionResponse | null;
|
|
25
|
+
/**
|
|
26
|
+
* The one element an integrator mounts.
|
|
27
|
+
*
|
|
28
|
+
* It takes its session as a JavaScript property rather than an attribute on
|
|
29
|
+
* purpose: an attribute is something a server-rendered page would print into
|
|
30
|
+
* HTML, and the creation capability must never appear in markup, in a URL, or
|
|
31
|
+
* anywhere a page cache could keep it.
|
|
32
|
+
*/
|
|
33
|
+
export declare class WhooshBangRecipientSettingsElement extends HTMLElement {
|
|
34
|
+
#private;
|
|
35
|
+
constructor();
|
|
36
|
+
get session(): SessionInput;
|
|
37
|
+
/**
|
|
38
|
+
* Accepts the creation response the integrator's backend returned.
|
|
39
|
+
*
|
|
40
|
+
* Assigning it is what starts the component. Assigning a fresh one later —
|
|
41
|
+
* after an expiry, say — restarts it cleanly, which is the recovery an
|
|
42
|
+
* integrator implements with two lines rather than a reload.
|
|
43
|
+
*/
|
|
44
|
+
set session(value: SessionInput);
|
|
45
|
+
get configuration(): RecipientSettingsConfiguration;
|
|
46
|
+
set configuration(value: RecipientSettingsConfiguration);
|
|
47
|
+
connectedCallback(): void;
|
|
48
|
+
disconnectedCallback(): void;
|
|
49
|
+
}
|
|
50
|
+
export declare function defineRecipientSettingsElement(registry?: CustomElementRegistry): void;
|
|
51
|
+
export {};
|