diff --git a/e2e/vite.spec.ts b/e2e/vite.spec.ts index 5ac32622..a67bbbd2 100644 --- a/e2e/vite.spec.ts +++ b/e2e/vite.spec.ts @@ -27,14 +27,12 @@ describe('vite', () => { expect(await getText(global.page, '#lang label')).toMatch('言語') expect(await getText(global.page, '#fruits label')).toMatch('バナナが欲しい?') expect(await getText(global.page, '#msg')).toMatch('こんにちは、世界!') - expect(await getText(global.page, '#custom-directive')).toMatch('やあ!') }) test('change locale', async () => { await global.page.selectOption('#lang select', 'en') expect(await getText(global.page, '#lang label')).toMatch('Language') expect(await getText(global.page, '#msg')).toMatch('hello, world!') - expect(await getText(global.page, '#custom-directive')).toMatch('Hi!') }) test('change banana select', async () => { diff --git a/examples/vite/src/App.vue b/examples/vite/src/App.vue index c39e9f51..ee9ce19e 100644 --- a/examples/vite/src/App.vue +++ b/examples/vite/src/App.vue @@ -7,7 +7,6 @@

{{ t('hello') }}

-

diff --git a/package.json b/package.json index bbe000b6..c4433fbb 100644 --- a/package.json +++ b/package.json @@ -28,19 +28,6 @@ "typescript-eslint": "^8.26.1", "vitest": "^3.0.8" }, - "pnpm": { - "overrides": { - "vue-i18n": "next", - "petite-vue-i18n": "next", - "@intlify/shared": "next", - "@intlify/core-base": "next", - "@intlify/message-compiler": "next", - "@intlify/vue-i18n-extensions>@intlify/shared": "next", - "@intlify/vue-i18n-extensions>@intlify/message-compiler": "next", - "@intlify/bundle-utils>@intlify/shared": "^12.0.0-alpha.2", - "@intlify/bundle-utils>@intlify/message-compiler": "^12.0.0-alpha.2" - } - }, "license": "MIT", "prettier": "@kazupon/prettier-config", "lint-staged": { diff --git a/packages/unplugin-vue-i18n/README.md b/packages/unplugin-vue-i18n/README.md index ba720f95..c78e0561 100644 --- a/packages/unplugin-vue-i18n/README.md +++ b/packages/unplugin-vue-i18n/README.md @@ -661,6 +661,11 @@ If do you will use this option, you need to enable `jitCompilation` option. If you want to put it manually, you can specify the signature of the translation function as a string or a string array. +> [!IMPORTANT] +> +> `optimizeTranslationDirective` option is deprecated in v12, because `v-t` custom directive will be dropped in vue-i18n v12 +> This option will be supported with unplugin-vue-i18n v6.x (vue-i18n until v11) + > [!WARNING] > About for manually signature, see the details [vue-i18n-extensions API docs](https://github.com/intlify/vue-i18n-extensions/blob/next/docs/%40intlify/vue-i18n-extensions-api.md#translationsignatures) and [usecase from vue-i18n-extensions PR](https://github.com/intlify/vue-i18n-extensions/pull/217/files#diff-3fb9543f91e011d4b0dc9beff44082fe1a99c9eab70c1afab23c3c34352b7c38R121-R200) diff --git a/packages/unplugin-vue-i18n/package.json b/packages/unplugin-vue-i18n/package.json index a2f0b69e..4fc26ff5 100644 --- a/packages/unplugin-vue-i18n/package.json +++ b/packages/unplugin-vue-i18n/package.json @@ -11,9 +11,9 @@ "url": "https://github.com/intlify/bundle-tools/issues" }, "peerDependencies": { - "petite-vue-i18n": "*", + "petite-vue-i18n": "^12.0.0-alpha.2", "vue": "^3.2.25", - "vue-i18n": "*" + "vue-i18n": "^12.0.0-alpha.2" }, "peerDependenciesMeta": { "petite-vue-i18n": { @@ -24,13 +24,9 @@ } }, "dependencies": { - "@eslint-community/eslint-utils": "^4.4.0", "@intlify/bundle-utils": "workspace:*", "@intlify/shared": "next", - "@intlify/vue-i18n-extensions": "^8.0.0", "@rollup/pluginutils": "^5.1.0", - "@typescript-eslint/scope-manager": "^8.13.0", - "@typescript-eslint/typescript-estree": "^8.13.0", "debug": "^4.3.3", "defu": "^6.1.4", "fast-glob": "^3.2.12", diff --git a/packages/unplugin-vue-i18n/src/core/directive.ts b/packages/unplugin-vue-i18n/src/core/directive.ts deleted file mode 100644 index e977884d..00000000 --- a/packages/unplugin-vue-i18n/src/core/directive.ts +++ /dev/null @@ -1,409 +0,0 @@ -import { isBoolean } from '@intlify/shared' -import { transformVTDirective } from '@intlify/vue-i18n-extensions' -import { analyze as analyzeScope } from '@typescript-eslint/scope-manager' -import { AST_NODE_TYPES, parse, simpleTraverse } from '@typescript-eslint/typescript-estree' -import createDebug from 'debug' -import path from 'node:path' -// @ts-expect-error -- FIXME: missing types -import eslintUitls from '@eslint-community/eslint-utils' -import { checkVuePlugin, getVitePlugin, normalizePath, resolveNamespace } from '../utils' -import { getDescriptor, getVuePluginOptions, parseVueRequest } from '../vue' - -import type { TranslationSignatureResolver } from '@intlify/vue-i18n-extensions' -import type { Scope } from '@typescript-eslint/scope-manager' -import { ParserServicesWithTypeInformation, TSESTree } from '@typescript-eslint/typescript-estree' -import type { RollupPlugin, UnpluginOptions } from 'unplugin' -import type { TranslationDirectiveResolveIndetifier, VuePluginResolvedOptions } from '../vue' -import type { ResolvedOptions } from './options' - -type Node = Parameters[0] - -const debug = createDebug(resolveNamespace('directive')) - -export function directivePlugin({ - optimizeTranslationDirective, - translationIdentifiers -}: ResolvedOptions): UnpluginOptions { - let vuePlugin: RollupPlugin | null = null - let vuePluginOptions: VuePluginResolvedOptions | null = null - - const excludeLangs = ['pug', 'jsx', 'tsx'] - - return { - name: resolveNamespace('directive'), - enforce: 'pre', - vite: { - config(config) { - // @ts-expect-error -- TODO - vuePlugin = getVitePlugin(config, 'vite:vue') - if (!checkVuePlugin(vuePlugin!)) { - return - } - - if (optimizeTranslationDirective) { - vuePlugin!.api.options = resolveVueOptions( - vuePlugin!, - optimizeTranslationDirective, - translationIdentifiers - ) - debug(`vite:vue options['template']:`, vuePlugin!.api.options) - } - }, - - configResolved(config) { - vuePlugin = getVitePlugin(config, 'vite:vue') - if (!checkVuePlugin(vuePlugin)) { - return - } - } - }, - - async transform(code, id) { - if (id.endsWith('.vue')) { - const { filename, query } = parseVueRequest(id) - if (!excludeLangs.includes(query.lang ?? '')) { - // lazy load vue plugin options - if (vuePluginOptions == null) { - vuePluginOptions = getVuePluginOptions(vuePlugin!) - } - if (vuePluginOptions?.compiler) { - analyzeIdentifiers( - getDescriptor(filename, code, vuePluginOptions), - vuePluginOptions, - translationIdentifiers - ) - return { - code, - map: { version: 3, mappings: '', sources: [] } as any - } - } - } - } - } - } -} - -function resolveVueOptions( - vuePlugin: RollupPlugin, - optimizeTranslationDirective: ResolvedOptions['optimizeTranslationDirective'], - translationIdentifiers: ResolvedOptions['translationIdentifiers'] -): any { - const vueOptions = vuePlugin.api.options - vueOptions.template ||= {} - vueOptions.template.compilerOptions ||= {} - vueOptions.template.compilerOptions.directiveTransforms ||= {} - - /** - * NOTE: - * This is a custom translation signature resolver for Vue SFC. - * The resolver works by this plugin. - * That is analyzing the identifier of the `t` function exposed by `useI18n` in vue-i18n. - * The analyzed identifier is replaced by the directive transform of the Vue compiler. - */ - const translationSignatureResolver: TranslationSignatureResolver = (context, baseResolver) => { - const { filename } = context - const vuePluginOptions = getVuePluginOptions(vuePlugin) - const normalizedFilename = normalizePath(path.relative(vuePluginOptions.root, filename)) - const resolveIdentifier = translationIdentifiers.get(normalizedFilename) - debug('resolved vue-i18n Identifier', resolveIdentifier) - if (resolveIdentifier == null) { - return undefined - } - - if (resolveIdentifier.type === 'identifier') { - return baseResolver(context, resolveIdentifier.key) - } else { - // object - const resolvedSignature = baseResolver(context, resolveIdentifier.key) - return resolveIdentifier?.style === 'script-setup' - ? `${resolvedSignature}.t` - : resolvedSignature - } - } - - vueOptions.template.compilerOptions.directiveTransforms.t = transformVTDirective({ - translationSignatures: isBoolean(optimizeTranslationDirective) - ? translationSignatureResolver - : optimizeTranslationDirective - }) - - return vueOptions -} - -function analyzeIdentifiers( - descriptor: ReturnType, - { root }: VuePluginResolvedOptions, - translationIdentifiers: Map -) { - const source = descriptor.scriptSetup?.content || descriptor.script?.content - debug('getDescriptor content', source) - if (!source) { - return - } - - const ast = parse(source, { range: true }) - simpleTraverse(ast, { - enter(node, parent) { - if (parent) { - node.parent = parent - } - } - }) - const scopeManager = analyzeScope(ast, { sourceType: 'module' }) - const scope = getScope(scopeManager, ast) - - const importLocalName = getImportLocalName(scope, 'vue-i18n', 'useI18n') - if (importLocalName == null) { - return - } - debug('importLocalName', importLocalName) - const resolvedIdentifier = getVueI18nIdentifier(scope, importLocalName!) - - if (resolvedIdentifier) { - const normalizedFilename = normalizePath(path.relative(root, descriptor.filename)) - debug('set vue-i18n resolved identifier: ', resolvedIdentifier) - translationIdentifiers.set(normalizedFilename, resolvedIdentifier) - } -} - -function getScope(manager: ReturnType, node: Node): Scope { - const scope = manager.acquire(node, true) - if (scope) { - if (scope.type === 'function-expression-name') { - return scope.childScopes[0] - } - return scope - } - return manager.scopes[0] -} - -function getImportLocalName(scope: Scope, source: string, imported: string): string | null { - const importDecl = getImportDeclaration(scope, source) - if (importDecl) { - const specifierNode = importDecl.specifiers.find( - specifierNode => - isImportedIdentifierInImportClause(specifierNode) && - specifierNode.imported.name === imported - ) - return specifierNode ? specifierNode.local.name : null - } - return null -} - -function getImportDeclaration(scope: Scope, source: string) { - const tracker = new eslintUitls.ReferenceTracker(scope) - const traceMap = { - [source]: { - [eslintUitls.ReferenceTracker.ESM]: true, - [eslintUitls.ReferenceTracker.READ]: true - } - } - const refs = Array.from(tracker.iterateEsmReferences(traceMap)) satisfies { - path: string - node: Node - }[] - return refs.length ? (refs[0].node as TSESTree.ImportDeclaration) : null -} - -function isImportedIdentifierInImportClause( - node: TSESTree.ImportClause -): node is TSESTree.ImportClause & { imported: TSESTree.Identifier } { - return 'imported' in node -} - -function getVueI18nIdentifier(scope: Scope, local: string) { - // Get the CallExpression and ReturnStatement needed for analysis from scope. - const { callExpression, returnStatement } = getCallExpressionAndReturnStatement(scope, local) - - // If CallExpression cannot get, `useI18n` will not be called and exit from this function - if (callExpression == null) { - return null - } - - // Get the AST Nodes from `id` prop on VariableDeclarator - // e.g. `const { t } = useI18n()` - // VariableDeclarator Node: `{ t } = useI18n()` - // expeted AST Nodes: `{ t }` - const id = getVariableDeclarationIdFrom(callExpression) - if (id == null) { - return null - } - - // parse variable id from AST Nodes - const variableIdPairs = parseVariableId(id) - debug('variableIdPairs:', variableIdPairs) - - // parse variable id from RestStatement Node - const returnVariableIdPairs = parseReturnStatement(returnStatement) - debug('returnVariableIdPairs:', returnVariableIdPairs) - - // resolve identifier - return resolveIdentifier(variableIdPairs, returnVariableIdPairs) -} - -const EMPTY_NODE_RETURN = { - callExpression: null, - returnStatement: null -} as const - -function getCallExpressionAndReturnStatement( - scope: Scope, - local: string -): - | { - callExpression: TSESTree.CallExpression | null - returnStatement: TSESTree.ReturnStatement | null - } - | typeof EMPTY_NODE_RETURN { - // TODO: missing types (eslint-utils) - const variable = eslintUitls.findVariable(scope, local) - if (variable == null) { - return EMPTY_NODE_RETURN - } - - // @ts-expect-error -- FIXME: missing types (eslint-utils) - const callExpressionRef = variable.references.find(ref => { - return ref.identifier.parent?.type === AST_NODE_TYPES.CallExpression - }) - if (callExpressionRef == null) { - return EMPTY_NODE_RETURN - } - - let returnStatement: TSESTree.ReturnStatement | null = null - if ( - callExpressionRef.from.type === 'function' && - callExpressionRef.from.block.type === AST_NODE_TYPES.FunctionExpression && - callExpressionRef.from.block.parent.type === AST_NODE_TYPES.Property && - callExpressionRef.from.block.parent.key.type === AST_NODE_TYPES.Identifier && - callExpressionRef.from.block.parent.key.name === 'setup' - ) { - returnStatement = callExpressionRef.from.block.body.body.find((statement: Node) => { - return statement.type === AST_NODE_TYPES.ReturnStatement - }) as TSESTree.ReturnStatement | null - } - - return { - callExpression: callExpressionRef.identifier.parent as TSESTree.CallExpression, - returnStatement - } -} - -function getVariableDeclarationIdFrom(node: TSESTree.CallExpression) { - if (node.parent?.type !== AST_NODE_TYPES.VariableDeclarator) { - return null - } - return node.parent.id as TSESTree.Identifier | TSESTree.ObjectPattern -} - -type VariableIdPair = { - key: string | null - value: string | null -} - -function parseVariableId(node: TSESTree.Identifier | TSESTree.ObjectPattern): VariableIdPair[] { - if (node.type === AST_NODE_TYPES.Identifier) { - // Identifier - // e.g `const i18n = useI18n()` - // [{ key: 'i18n', value: null }] - return [{ key: node.name, value: null }] - } else { - // ObjectPattern - // e.g `const { t, d: datetime } = useI18n()` - // [{ key: 't', value: 't' }, { key: 'd', value: 'datetime' }] - const props = node.properties.filter( - // ignore RestElement - prop => prop.type === AST_NODE_TYPES.Property - ) as TSESTree.Property[] - const pairs = [] as { key: string | null; value: string | null }[] - for (const prop of props) { - if ( - prop?.key.type === AST_NODE_TYPES.Identifier && - prop?.value.type === AST_NODE_TYPES.Identifier - ) { - pairs.push({ key: prop.key.name, value: prop.value.name }) - } - } - return pairs - } -} - -function parseReturnStatement(node: TSESTree.ReturnStatement | null): VariableIdPair[] { - const pairs = [] as VariableIdPair[] - if (node == null || node.argument == null) { - return pairs - } - - if (node.argument.type === AST_NODE_TYPES.ObjectExpression) { - // ObjectExpression - for (const prop of node.argument.properties) { - if (prop.type === AST_NODE_TYPES.Property) { - if ( - prop.key.type === AST_NODE_TYPES.Identifier && - prop.value.type === AST_NODE_TYPES.Identifier - ) { - // Identifier - // e.g `return { t, d: datetime }` - // [{ key: 't', value: 't' }, { key: 'd', value: 'datetime' }] - pairs.push({ key: prop.key.name, value: prop.value.name }) - } else if ( - prop.key.type === AST_NODE_TYPES.Identifier && - prop.value.type === AST_NODE_TYPES.MemberExpression && - prop.value.object.type === AST_NODE_TYPES.Identifier && - prop.value.property.type === AST_NODE_TYPES.Identifier - ) { - // MemberExpression - // e.g `return { t: i18n.t }` - // [{ key: 't', value: 'i18n.t' }] - pairs.push({ - key: prop.key.name, - value: `${prop.value.object.name}.${prop.value.property.name}` - }) - } - } - } - return pairs - } else if (node.argument.type === AST_NODE_TYPES.Identifier) { - // Identifier - // e.g `return i18n` - return pairs - } else { - // other AST Nodes - return pairs - } -} - -function resolveIdentifier( - localVariables: VariableIdPair[], - returnVariable: VariableIdPair[] -): TranslationDirectiveResolveIndetifier | null { - if (returnVariable.length === 0) { - // for ` - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-global-option.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-global-option.vue deleted file mode 100644 index e31068cf..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-global-option.vue +++ /dev/null @@ -1,14 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-local-option.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-local-option.vue deleted file mode 100644 index f91090d3..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-local-option.vue +++ /dev/null @@ -1,19 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-no-option.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-no-option.vue deleted file mode 100644 index a3646a6a..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-no-option.vue +++ /dev/null @@ -1,12 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-no-use.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-no-use.vue deleted file mode 100644 index 19912bbd..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-no-use.vue +++ /dev/null @@ -1,10 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-obj.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-obj.vue deleted file mode 100644 index e3c3a052..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/script-setup-obj.vue +++ /dev/null @@ -1,12 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-alias.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/setup-alias.vue deleted file mode 100644 index 2ed51507..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-alias.vue +++ /dev/null @@ -1,17 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-global-option.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/setup-global-option.vue deleted file mode 100644 index 266768b9..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-global-option.vue +++ /dev/null @@ -1,19 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-local-option.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/setup-local-option.vue deleted file mode 100644 index 383c7675..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-local-option.vue +++ /dev/null @@ -1,24 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-no-option.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/setup-no-option.vue deleted file mode 100644 index 73bb3a2e..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-no-option.vue +++ /dev/null @@ -1,17 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-no-use.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/setup-no-use.vue deleted file mode 100644 index 5146277f..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-no-use.vue +++ /dev/null @@ -1,15 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-return-alias-with-obj.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/setup-return-alias-with-obj.vue deleted file mode 100644 index 40d1a2d7..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-return-alias-with-obj.vue +++ /dev/null @@ -1,17 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-return-alias.vue b/packages/unplugin-vue-i18n/test/fixtures/directives/setup-return-alias.vue deleted file mode 100644 index 19263201..00000000 --- a/packages/unplugin-vue-i18n/test/fixtures/directives/setup-return-alias.vue +++ /dev/null @@ -1,17 +0,0 @@ - - - diff --git a/packages/unplugin-vue-i18n/test/resource-compilation.test.ts b/packages/unplugin-vue-i18n/test/resource-compilation.test.ts index 6ccc1cc3..9f39d2b6 100644 --- a/packages/unplugin-vue-i18n/test/resource-compilation.test.ts +++ b/packages/unplugin-vue-i18n/test/resource-compilation.test.ts @@ -1,10 +1,13 @@ -import type { MessageCompilerContext } from '@intlify/core-base' -import { vi, expect, test, beforeEach, afterEach } from 'vitest' import { compile, createMessageContext } from '@intlify/core-base' import { assign, isFunction } from '@intlify/shared' import { resolve } from 'node:path' +import { afterEach, beforeEach, expect, test, vi } from 'vitest' import { bundleAndRun, getCurrentTestBundler, isTestFramework } from './utils' + +import type { MessageCompilerContext } from '@intlify/core-base' + let spyConsoleError: any + beforeEach(() => { spyConsoleError = vi.spyOn(global.console, 'error').mockImplementation(() => {}) }) diff --git a/packages/unplugin-vue-i18n/test/translation-directive.test.ts b/packages/unplugin-vue-i18n/test/translation-directive.test.ts deleted file mode 100644 index 241d4ed2..00000000 --- a/packages/unplugin-vue-i18n/test/translation-directive.test.ts +++ /dev/null @@ -1,23 +0,0 @@ -import fg from 'fast-glob' -import path from 'node:path' -import { describe, expect, test } from 'vitest' -import { bundleAndRun, getCurrentTestBundler, isTestFramework } from './utils' - -const bundler = getCurrentTestBundler() - -describe.skipIf(!isTestFramework('vite'))('translation directive', async () => { - const fixtures = await fg(path.resolve(__dirname, './fixtures/directives/*.vue')) - fixtures.forEach(fixture => { - const filename = path.basename(fixture) - const basename = filename.replace(/\.vue$/, '') - test(basename, async () => { - const options = { - target: './fixtures/directives/', - optimizeTranslationDirective: true - } - const mod = await bundleAndRun(filename, bundler, options) - const renderString = mod.module.render.toString() as string - expect(renderString).toMatchSnapshot() - }) - }) -}) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 02a34a0b..3d809376 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -4,17 +4,6 @@ settings: autoInstallPeers: true excludeLinksFromLockfile: false -overrides: - vue-i18n: next - petite-vue-i18n: next - '@intlify/shared': next - '@intlify/core-base': next - '@intlify/message-compiler': next - '@intlify/vue-i18n-extensions>@intlify/shared': next - '@intlify/vue-i18n-extensions>@intlify/message-compiler': next - '@intlify/bundle-utils>@intlify/shared': ^12.0.0-alpha.2 - '@intlify/bundle-utils>@intlify/message-compiler': ^12.0.0-alpha.2 - importers: .: @@ -149,10 +138,10 @@ importers: specifier: ^7.26.0 version: 7.26.0(@babel/core@7.26.10) '@intlify/message-compiler': - specifier: ^12.0.0-alpha.2 + specifier: next version: 12.0.0-alpha.2 '@intlify/shared': - specifier: ^12.0.0-alpha.2 + specifier: next version: 12.0.0-alpha.2 acorn: specifier: ^8.8.2 @@ -188,27 +177,15 @@ importers: packages/unplugin-vue-i18n: dependencies: - '@eslint-community/eslint-utils': - specifier: ^4.4.0 - version: 4.4.0(eslint@9.22.0(jiti@2.4.2)) '@intlify/bundle-utils': specifier: workspace:* version: link:../bundle-utils '@intlify/shared': specifier: next version: 12.0.0-alpha.2 - '@intlify/vue-i18n-extensions': - specifier: ^8.0.0 - version: 8.0.0(@intlify/shared@12.0.0-alpha.2)(@vue/compiler-dom@3.5.13)(vue-i18n@12.0.0-alpha.2(vue@3.4.29(typescript@5.8.2)))(vue@3.4.29(typescript@5.8.2)) '@rollup/pluginutils': specifier: ^5.1.0 - version: 5.1.0(rollup@4.34.8) - '@typescript-eslint/scope-manager': - specifier: ^8.13.0 - version: 8.13.0 - '@typescript-eslint/typescript-estree': - specifier: ^8.13.0 - version: 8.13.0(typescript@5.8.2) + version: 5.1.0(rollup@3.29.4) debug: specifier: ^4.3.3 version: 4.3.5 @@ -225,7 +202,7 @@ importers: specifier: ^1.2.0 version: 1.7.4 petite-vue-i18n: - specifier: next + specifier: ^12.0.0-alpha.2 version: 12.0.0-alpha.2(vue@3.4.29(typescript@5.8.2)) picocolors: specifier: ^1.0.0 @@ -237,7 +214,7 @@ importers: specifier: ^3.4 version: 3.4.29(typescript@5.8.2) vue-i18n: - specifier: next + specifier: ^12.0.0-alpha.2 version: 12.0.0-alpha.2(vue@3.4.29(typescript@5.8.2)) devDependencies: '@intlify/core-base': @@ -982,24 +959,6 @@ packages: peerDependencies: vue: ^3.0.0 - '@intlify/vue-i18n-extensions@8.0.0': - resolution: {integrity: sha512-w0+70CvTmuqbskWfzeYhn0IXxllr6mU+IeM2MU0M+j9OW64jkrvqY+pYFWrUnIIC9bEdij3NICruicwd5EgUuQ==} - engines: {node: '>= 18'} - peerDependencies: - '@intlify/shared': ^9.0.0 || ^10.0.0 || ^11.0.0 - '@vue/compiler-dom': ^3.0.0 - vue: ^3.0.0 - vue-i18n: ^9.0.0 || ^10.0.0 || ^11.0.0 - peerDependenciesMeta: - '@intlify/shared': - optional: true - '@vue/compiler-dom': - optional: true - vue: - optional: true - vue-i18n: - optional: true - '@isaacs/cliui@8.0.2': resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} engines: {node: '>=12'} @@ -1809,10 +1768,6 @@ packages: eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <5.9.0' - '@typescript-eslint/scope-manager@8.13.0': - resolution: {integrity: sha512-XsGWww0odcUT0gJoBZ1DeulY1+jkaHUciUq4jKNv4cpInbvvrtDoyBH9rE/n2V29wQJPk8iCH1wipra9BhmiMA==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/scope-manager@8.26.1': resolution: {integrity: sha512-6EIvbE5cNER8sqBu6V7+KeMZIC1664d2Yjt+B9EWUXrsyWpxx4lEZrmvxgSKRC6gX+efDL/UY9OpPZ267io3mg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -1824,23 +1779,10 @@ packages: eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <5.9.0' - '@typescript-eslint/types@8.13.0': - resolution: {integrity: sha512-4cyFErJetFLckcThRUFdReWJjVsPCqyBlJTi6IDEpc1GWCIIZRFxVppjWLIMcQhNGhdWJJRYFHpHoDWvMlDzng==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/types@8.26.1': resolution: {integrity: sha512-n4THUQW27VmQMx+3P+B0Yptl7ydfceUj4ON/AQILAASwgYdZ/2dhfymRMh5egRUrvK5lSmaOm77Ry+lmXPOgBQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/typescript-estree@8.13.0': - resolution: {integrity: sha512-v7SCIGmVsRK2Cy/LTLGN22uea6SaUIlpBcO/gnMGT/7zPtxp90bphcGf4fyrCQl3ZtiBKqVTG32hb668oIYy1g==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true - '@typescript-eslint/typescript-estree@8.26.1': resolution: {integrity: sha512-yUwPpUHDgdrv1QJ7YQal3cMVBGWfnuCdKbXw1yyjArax3353rEJP1ZA+4F8nOlQ3RfS2hUN/wze3nlY+ZOhvoA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -1854,10 +1796,6 @@ packages: eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <5.9.0' - '@typescript-eslint/visitor-keys@8.13.0': - resolution: {integrity: sha512-7N/+lztJqH4Mrf0lb10R/CbI1EaAMMGyF5y0oJvFoAhafwgiRA7TXyd8TFn8FC8k5y2dTsYogg238qavRGNnlw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/visitor-keys@8.26.1': resolution: {integrity: sha512-AjOC3zfnxd6S4Eiy3jwktJPclqhFHNyd8L6Gycf9WUPoKZpgM5PjkxY1X7uSy61xVpiJDhhk7XT2NVsN3ALTWg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -5103,12 +5041,6 @@ packages: peerDependencies: tslib: '2' - ts-api-utils@1.3.0: - resolution: {integrity: sha512-UQMIo7pb8WRomKR1/+MFVLTroIvDVtMX3K6OUir8ynLyzB8Jeriont2bTAtmNPa1ekAgN7YPDyf6V+ygrdU+eQ==} - engines: {node: '>=16'} - peerDependencies: - typescript: '>=4.2.0' - ts-api-utils@2.0.1: resolution: {integrity: sha512-dnlgjFSVetynI8nzgJ+qF62efpglpWRk8isUEWZGWlJYySCTD6aKvbUDu+zbPeDakk3bg5H4XpitHukgfL1m9w==} engines: {node: '>=18.12'} @@ -6143,11 +6075,6 @@ snapshots: eslint: 9.22.0(jiti@2.4.0) eslint-visitor-keys: 3.4.3 - '@eslint-community/eslint-utils@4.4.0(eslint@9.22.0(jiti@2.4.2))': - dependencies: - eslint: 9.22.0(jiti@2.4.2) - eslint-visitor-keys: 3.4.3 - '@eslint-community/regexpp@4.12.1': {} '@eslint/config-array@0.19.2': @@ -6236,15 +6163,6 @@ snapshots: '@vue/devtools-api': 6.6.3 vue: 3.5.13(typescript@5.8.2) - '@intlify/vue-i18n-extensions@8.0.0(@intlify/shared@12.0.0-alpha.2)(@vue/compiler-dom@3.5.13)(vue-i18n@12.0.0-alpha.2(vue@3.4.29(typescript@5.8.2)))(vue@3.4.29(typescript@5.8.2))': - dependencies: - '@babel/parser': 7.24.7 - optionalDependencies: - '@intlify/shared': 12.0.0-alpha.2 - '@vue/compiler-dom': 3.5.13 - vue: 3.4.29(typescript@5.8.2) - vue-i18n: 12.0.0-alpha.2(vue@3.4.29(typescript@5.8.2)) - '@isaacs/cliui@8.0.2': dependencies: string-width: 5.1.2 @@ -6633,14 +6551,6 @@ snapshots: optionalDependencies: rollup: 3.29.4 - '@rollup/pluginutils@5.1.0(rollup@4.34.8)': - dependencies: - '@types/estree': 1.0.5 - estree-walker: 2.0.2 - picomatch: 2.3.1 - optionalDependencies: - rollup: 4.34.8 - '@rollup/rollup-android-arm-eabi@4.34.8': optional: true @@ -6989,11 +6899,6 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/scope-manager@8.13.0': - dependencies: - '@typescript-eslint/types': 8.13.0 - '@typescript-eslint/visitor-keys': 8.13.0 - '@typescript-eslint/scope-manager@8.26.1': dependencies: '@typescript-eslint/types': 8.26.1 @@ -7010,25 +6915,8 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/types@8.13.0': {} - '@typescript-eslint/types@8.26.1': {} - '@typescript-eslint/typescript-estree@8.13.0(typescript@5.8.2)': - dependencies: - '@typescript-eslint/types': 8.13.0 - '@typescript-eslint/visitor-keys': 8.13.0 - debug: 4.3.5 - fast-glob: 3.3.2 - is-glob: 4.0.3 - minimatch: 9.0.4 - semver: 7.6.2 - ts-api-utils: 1.3.0(typescript@5.8.2) - optionalDependencies: - typescript: 5.8.2 - transitivePeerDependencies: - - supports-color - '@typescript-eslint/typescript-estree@8.26.1(typescript@5.8.2)': dependencies: '@typescript-eslint/types': 8.26.1 @@ -7054,11 +6942,6 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/visitor-keys@8.13.0': - dependencies: - '@typescript-eslint/types': 8.13.0 - eslint-visitor-keys: 3.4.3 - '@typescript-eslint/visitor-keys@8.26.1': dependencies: '@typescript-eslint/types': 8.26.1 @@ -7163,7 +7046,7 @@ snapshots: estree-walker: 2.0.2 magic-string: 0.30.10 postcss: 8.4.38 - source-map-js: 1.2.0 + source-map-js: 1.2.1 '@vue/compiler-sfc@3.5.13': dependencies: @@ -8498,48 +8381,6 @@ snapshots: transitivePeerDependencies: - supports-color - eslint@9.22.0(jiti@2.4.2): - dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@9.22.0(jiti@2.4.2)) - '@eslint-community/regexpp': 4.12.1 - '@eslint/config-array': 0.19.2 - '@eslint/config-helpers': 0.1.0 - '@eslint/core': 0.12.0 - '@eslint/eslintrc': 3.3.0 - '@eslint/js': 9.22.0 - '@eslint/plugin-kit': 0.2.7 - '@humanfs/node': 0.16.6 - '@humanwhocodes/module-importer': 1.0.1 - '@humanwhocodes/retry': 0.4.2 - '@types/estree': 1.0.6 - '@types/json-schema': 7.0.15 - ajv: 6.12.6 - chalk: 4.1.2 - cross-spawn: 7.0.6 - debug: 4.4.0 - escape-string-regexp: 4.0.0 - eslint-scope: 8.3.0 - eslint-visitor-keys: 4.2.0 - espree: 10.3.0 - esquery: 1.6.0 - esutils: 2.0.3 - fast-deep-equal: 3.1.3 - file-entry-cache: 8.0.0 - find-up: 5.0.0 - glob-parent: 6.0.2 - ignore: 5.3.1 - imurmurhash: 0.1.4 - is-glob: 4.0.3 - json-stable-stringify-without-jsonify: 1.0.1 - lodash.merge: 4.6.2 - minimatch: 3.1.2 - natural-compare: 1.4.0 - optionator: 0.9.4 - optionalDependencies: - jiti: 2.4.2 - transitivePeerDependencies: - - supports-color - espree@10.3.0: dependencies: acorn: 8.14.0 @@ -10986,10 +10827,6 @@ snapshots: dependencies: tslib: 2.8.1 - ts-api-utils@1.3.0(typescript@5.8.2): - dependencies: - typescript: 5.8.2 - ts-api-utils@2.0.1(typescript@5.8.2): dependencies: typescript: 5.8.2