refactor: apply repository naming contract

Apply the accepted pre-release package, service, type, directory, and role renames as one repository-wide change.
This commit is contained in:
Tianyi Cui
2026-08-13 00:36:22 +08:00
parent 101df7cf58
commit a2d0f7f411
3281 changed files with 21730 additions and 21592 deletions

View File

@@ -1,12 +1,12 @@
import { describe, expect, it } from 'vitest'
import { Context } from '@deepseek-ai/cordis'
import * as SettingsInvariant from '@deepseek-ai/dsh-client-ui-settings/invariant'
import InvariantService from '@deepseek-ai/dsh-invariants'
import InvariantRegistry from '@deepseek-ai/dsh-invariants'
describe('invariant companion', () => {
it('registers under the package name with an empty installer', async () => {
const ctx = new Context()
await ctx.plugin(InvariantService, { enabled: true })
await ctx.plugin(InvariantRegistry, { enabled: true })
await expect(ctx.plugin(SettingsInvariant).await()).resolves.toBeDefined()
})

View File

@@ -5,7 +5,7 @@
*/
import { Context } from '@deepseek-ai/cordis'
import { describe, expect, it } from 'vitest'
import { apply, inject, SettingsScopeService } from '../src/client/index.ts'
import { apply, inject, SettingsScopeBinder } from '../src/client/index.ts'
/** Boot the browser half over a bare root context; it injects nothing. */
function bench() {
@@ -17,7 +17,7 @@ describe('settings domain base plugin', () => {
it('mounts the scope service under settingsScope', async () => {
const { ctx, fiber } = bench()
await fiber.await()
expect(ctx.get('settingsScope')).toBeInstanceOf(SettingsScopeService)
expect(ctx.get('settingsScope')).toBeInstanceOf(SettingsScopeBinder)
})
it('fiber disposal retires the service', async () => {

View File

@@ -4,7 +4,7 @@ import { describe, expect, it, vi } from 'vitest'
import type { RpcResponse, SettingsNamespaceView } from '@deepseek-ai/dsh-api-remotes/client'
import { TestRemote } from '@deepseek-ai/dsh-client-test-runtime'
import type { SettingsScope } from '@deepseek-ai/dsh-client-runtime/client'
import { SettingsScopeController, SettingsScopeService } from '../src/client/settings-scope.ts'
import { SettingsScopeController, SettingsScopeBinder } from '../src/client/settings-scope.ts'
interface UiTestSettings {
preference: 'light' | 'dark' | 'system'
@@ -365,7 +365,7 @@ describe('SettingsScopeController', () => {
expect(scope.getSnapshot()).toMatchObject({ value: { preference: 'light' }, revision: 5 })
})
})
describe('SettingsScopeService.bind', () => {
describe('SettingsScopeBinder.bind', () => {
it('subscribes before the initial read and converges to the latest queued invalidation', async () => {
const initial = deferred<ReturnType<typeof described>>()
const describeCall = vi.fn()
@@ -379,7 +379,7 @@ describe('SettingsScopeService.bind', () => {
} as never)
let scope!: SettingsScope<UiTestSettings>
new TestRemote(ctx)
await ctx.plugin(SettingsScopeService).await()
await ctx.plugin(SettingsScopeBinder).await()
const fiber = ctx.plugin({
inject: ['connection', 'remote', 'settingsScope'],
apply: (plugin: Context) => {
@@ -411,7 +411,7 @@ describe('SettingsScopeService.bind', () => {
} as never)
let scope!: SettingsScope<UiTestSettings>
new TestRemote(ctx)
await ctx.plugin(SettingsScopeService).await()
await ctx.plugin(SettingsScopeBinder).await()
const fiber = ctx.plugin({
inject: ['connection', 'remote', 'settingsScope'],
apply: (plugin: Context) => {