mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-05 16:40:26 +00:00
refactor: rename setup helper surfaces
This commit is contained in:
@@ -3,7 +3,7 @@ import type { OpenClawConfig } from "../../config/config.js";
|
||||
import { DEFAULT_ACCOUNT_ID } from "../../routing/session-key.js";
|
||||
|
||||
const promptAccountIdSdkMock = vi.hoisted(() => vi.fn(async () => "default"));
|
||||
vi.mock("../../plugin-sdk/onboarding.js", () => ({
|
||||
vi.mock("../../plugin-sdk/setup.js", () => ({
|
||||
promptAccountId: promptAccountIdSdkMock,
|
||||
}));
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import {
|
||||
import type { OpenClawConfig } from "../../config/config.js";
|
||||
import type { DmPolicy, GroupPolicy } from "../../config/types.js";
|
||||
import type { SecretInput } from "../../config/types.secrets.js";
|
||||
import { promptAccountId as promptAccountIdSdk } from "../../plugin-sdk/onboarding.js";
|
||||
import { promptAccountId as promptAccountIdSdk } from "../../plugin-sdk/setup.js";
|
||||
import { DEFAULT_ACCOUNT_ID, normalizeAccountId } from "../../routing/session-key.js";
|
||||
import type { WizardPrompter } from "../../wizard/prompts.js";
|
||||
import type { PromptAccountId, PromptAccountIdParams } from "./setup-flow-types.js";
|
||||
|
||||
@@ -4,7 +4,7 @@ import type { RuntimeEnv } from "../../runtime.js";
|
||||
import type { WizardPrompter } from "../../wizard/prompts.js";
|
||||
import type { ChannelId, ChannelPlugin } from "./types.js";
|
||||
|
||||
export type ChannelOnboardingSetupPlugin = Pick<
|
||||
export type ChannelSetupPlugin = Pick<
|
||||
ChannelPlugin,
|
||||
"id" | "meta" | "capabilities" | "config" | "setup" | "setupWizard"
|
||||
>;
|
||||
@@ -15,7 +15,7 @@ export type SetupChannelsOptions = {
|
||||
onSelection?: (selection: ChannelId[]) => void;
|
||||
accountIds?: Partial<Record<ChannelId, string>>;
|
||||
onAccountId?: (channel: ChannelId, accountId: string) => void;
|
||||
onResolvedPlugin?: (channel: ChannelId, plugin: ChannelOnboardingSetupPlugin) => void;
|
||||
onResolvedPlugin?: (channel: ChannelId, plugin: ChannelSetupPlugin) => void;
|
||||
promptAccountIds?: boolean;
|
||||
whatsappAccountId?: string;
|
||||
promptWhatsAppAccountId?: boolean;
|
||||
|
||||
Reference in New Issue
Block a user