Skip to content

Commit fdc7892

Browse files
authored
refactor: localize internal implementation types (#101731)
1 parent c8d95da commit fdc7892

38 files changed

Lines changed: 47 additions & 49 deletions

extensions/discord/src/approval-handler.runtime.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ type PreparedDeliveryTarget = {
4949
recipientUserId?: string;
5050
};
5151

52-
export type DiscordApprovalHandlerContext = {
52+
type DiscordApprovalHandlerContext = {
5353
token: string;
5454
config: DiscordExecApprovalConfig;
5555
};

extensions/feishu/src/doctor.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ export type FeishuDoctorInspection = {
7171
sessionEntries: FeishuDoctorSessionEntry[];
7272
};
7373

74-
export type FeishuDoctorRepairReport = {
74+
type FeishuDoctorRepairReport = {
7575
backupDir: string;
7676
stateDirRepairAttempted: boolean;
7777
rebuiltStateDir: boolean;

extensions/feishu/src/monitor.account.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export type FeishuReactionCreatedEvent = {
4646
action_time?: string;
4747
};
4848

49-
export type FeishuReactionDeletedEvent = FeishuReactionCreatedEvent & {
49+
type FeishuReactionDeletedEvent = FeishuReactionCreatedEvent & {
5050
reaction_id?: string;
5151
};
5252

@@ -500,7 +500,9 @@ export async function monitorSingleAccount(params: MonitorSingleAccountParams):
500500
const eventDispatcher = createEventDispatcher(account);
501501
const chatHistories = new Map<string, HistoryEntry[]>();
502502
threadBindingManager = createFeishuThreadBindingManager({ accountId, cfg });
503-
const channelRuntime = params.channelRuntime?.inbound ? params.channelRuntime : getFeishuRuntime().channel;
503+
const channelRuntime = params.channelRuntime?.inbound
504+
? params.channelRuntime
505+
: getFeishuRuntime().channel;
504506

505507
registerEventHandlers(eventDispatcher, {
506508
cfg,

extensions/file-transfer/src/shared/policy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ import { mutateConfigFile } from "openclaw/plugin-sdk/config-mutation";
5252
import { getRuntimeConfig } from "openclaw/plugin-sdk/runtime-config-snapshot";
5353

5454
export type FilePolicyKind = "read" | "write";
55-
export type FilePolicyAskMode = "off" | "on-miss" | "always";
55+
type FilePolicyAskMode = "off" | "on-miss" | "always";
5656

5757
type FilePolicyDecision =
5858
| { ok: true; reason: "matched-allow"; maxBytes?: number; followSymlinks: boolean }

extensions/logbook/src/node-host.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { resolvePreferredOpenClawTmpDir } from "openclaw/plugin-sdk/temp-path";
1010

1111
const execFileAsync = promisify(execFile);
1212

13-
export type LogbookSnapshotParams = {
13+
type LogbookSnapshotParams = {
1414
screenIndex?: number;
1515
maxWidth?: number;
1616
quality?: number;

extensions/matrix/src/approval-handler.runtime.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ export type MatrixApprovalHandlerDeps = {
139139
repairDirectRooms?: typeof repairMatrixDirectRooms;
140140
};
141141

142-
export type MatrixApprovalHandlerContext = {
142+
type MatrixApprovalHandlerContext = {
143143
client: MatrixClient;
144144
deps?: MatrixApprovalHandlerDeps;
145145
};

extensions/msteams/src/graph-messages.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ export const TEAMS_REACTION_TYPES = [
312312
"sad",
313313
"angry",
314314
] as const;
315-
export type TeamsReactionType = (typeof TEAMS_REACTION_TYPES)[number];
315+
type TeamsReactionType = (typeof TEAMS_REACTION_TYPES)[number];
316316

317317
type GraphReaction = {
318318
reactionType?: string;

extensions/qa-lab/src/live-transports/shared/credential-lease.runtime.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ type QaCredentialLeaseHeartbeat = {
7474
throwIfFailed(): void;
7575
};
7676

77-
export type QaCredentialRole = "ci" | "maintainer";
77+
type QaCredentialRole = "ci" | "maintainer";
7878

7979
type QaCredentialLeaseSource = "convex" | "env";
8080

extensions/qa-lab/src/live-transports/whatsapp/whatsapp-live.runtime.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ import {
5151

5252
const execFileAsync = promisify(execFile);
5353

54-
export type WhatsAppQaRuntimeEnv = {
54+
type WhatsAppQaRuntimeEnv = {
5555
driverAuthArchiveBase64: string;
5656
driverPhoneE164: string;
5757
sutAuthArchiveBase64: string;

extensions/qa-lab/src/scorecard-taxonomy.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,10 +325,10 @@ export type QaNativeCoverageEvidenceKind = "script" | "vitest" | "playwright";
325325
export type QaScorecardEvidenceKind = QaNativeCoverageEvidenceKind | "qa-scenario";
326326
export type QaScorecardEvidenceMode = z.infer<typeof qaScorecardEvidenceModeSchema>;
327327
export type QaScorecardChannelDriver = z.infer<typeof qaScorecardChannelDriverSchema>;
328-
export type QaMaturityScoreKey = (typeof QA_MATURITY_SCORE_KEYS)[number];
328+
type QaMaturityScoreKey = (typeof QA_MATURITY_SCORE_KEYS)[number];
329329
export type QaMaturityScoreObject = z.infer<typeof qaMaturityScoreObjectSchema>;
330330
export type QaMaturityScoreSurfaceLts = z.infer<typeof qaMaturityScoreSurfaceLtsSchema>;
331-
export type QaMaturityScoreCategory = z.infer<typeof qaMaturityScoreCategorySchema>;
331+
type QaMaturityScoreCategory = z.infer<typeof qaMaturityScoreCategorySchema>;
332332
export type QaMaturityScoreSurface = z.infer<typeof qaMaturityScoreSurfaceSchema>;
333333
export type QaMaturityScores = z.infer<typeof qaMaturityScoresSchema>;
334334
export type QaMaturityTaxonomyLevel = z.infer<typeof qaMaturityLevelSchema>;

0 commit comments

Comments
 (0)