diff --git a/packages/taro-api/package.json b/packages/taro-api/package.json index 3f6f6f8659a8..06712b04dfed 100644 --- a/packages/taro-api/package.json +++ b/packages/taro-api/package.json @@ -8,6 +8,12 @@ "main:h5": "dist/index.esm.js", "main": "dist/index.cjs.js", "module": "dist/index.esm.js", + "exports": { + ".": { + "import": "./dist/index.esm.js", + "require": "./dist/index.cjs.js" + } + }, "directories": { "lib": "lib", "test": "__tests__" diff --git a/packages/taro-h5/__mocks__/platform.ts b/packages/taro-h5/__mocks__/platform.ts deleted file mode 100644 index b1c6ea436a54..000000000000 --- a/packages/taro-h5/__mocks__/platform.ts +++ /dev/null @@ -1 +0,0 @@ -export default {} diff --git a/packages/taro-h5/__mocks__/setEnv.ts b/packages/taro-h5/__mocks__/setEnv.ts index d3ee305e68c1..3f19c6ce5d20 100644 --- a/packages/taro-h5/__mocks__/setEnv.ts +++ b/packages/taro-h5/__mocks__/setEnv.ts @@ -1,3 +1,5 @@ +import '@testing-library/jest-dom/vitest' + process.env.NODE_ENV = 'production' process.env.TARO_ENV = 'h5' process.env.TARO_PLATFORM = 'web' diff --git a/packages/taro-h5/__tests__/base/index.test.ts b/packages/taro-h5/__tests__/base/index.test.ts index 6bb57851e83b..2ca786eb7876 100644 --- a/packages/taro-h5/__tests__/base/index.test.ts +++ b/packages/taro-h5/__tests__/base/index.test.ts @@ -1,4 +1,6 @@ -import * as Taro from '@tarojs/taro-h5' +import { describe, expect, test } from 'vitest' + +import * as Taro from '../../src/index' describe('others', () => { test('should covert arraybuffer to base64', () => { diff --git a/packages/taro-h5/__tests__/base/network.test.ts b/packages/taro-h5/__tests__/base/network.test.ts index c7eaa6aee6da..e162a0ad97f7 100644 --- a/packages/taro-h5/__tests__/base/network.test.ts +++ b/packages/taro-h5/__tests__/base/network.test.ts @@ -1,9 +1,11 @@ -import * as Taro from '@tarojs/taro-h5' +import { describe, expect, test, vi } from 'vitest' + +import * as Taro from '../../src/index' describe('networkType', () => { test('should getNetworkType return Promise that resolve networkType', () => { - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() // @ts-ignore navigator.connection = { @@ -53,22 +55,24 @@ describe('networkType', () => { }) }) - test('should get networkType from connection.type that does not follow the spec', done => { - const cbList: any = {} - // @ts-ignore - navigator.connection = { - effectiveType: '4g', - addEventListener: jest.fn((ev, cb) => { - cbList[ev] = cb - }) - } + test('should trigger onNetworkStatusChange when connection changes', () => { + return new Promise(resolve => { + const cbList: any = {} + // @ts-ignore + navigator.connection = { + effectiveType: '4g', + addEventListener: vi.fn((ev, cb) => { + cbList[ev] = cb + }) + } - setTimeout(() => cbList.change(), 1000) + setTimeout(() => cbList.change(), 1000) - Taro.onNetworkStatusChange(ev => { - expect(ev.isConnected).toBe(true) - expect(ev.networkType).toBe('4g') - done() + Taro.onNetworkStatusChange(ev => { + expect(ev.isConnected).toBe(true) + expect(ev.networkType).toBe('4g') + resolve() + }) }) }) }) diff --git a/packages/taro-h5/__tests__/base/pxTransform.test.ts b/packages/taro-h5/__tests__/base/pxTransform.test.ts index ff756296eb4a..0267d7838c1a 100644 --- a/packages/taro-h5/__tests__/base/pxTransform.test.ts +++ b/packages/taro-h5/__tests__/base/pxTransform.test.ts @@ -1,6 +1,8 @@ -import * as Taro from '@tarojs/taro-h5' +import { describe, expect, test } from 'vitest' -describe('pxtransform', () => { +import * as Taro from '../../src/index' + +describe('pxTransform', () => { test('pxTransform', () => { Taro.initPxTransform({ designWidth: 750, diff --git a/packages/taro-h5/__tests__/base/system.test.ts b/packages/taro-h5/__tests__/base/system.test.ts index 024bf7e2a7c5..a5d93c91205a 100644 --- a/packages/taro-h5/__tests__/base/system.test.ts +++ b/packages/taro-h5/__tests__/base/system.test.ts @@ -1,4 +1,6 @@ -import * as Taro from '@tarojs/taro-h5' +import { describe, expect, test, vi } from 'vitest' + +import * as Taro from '../../src/index' describe('systemInfo', () => { test('should getSystemInfoSync return system information', () => { @@ -20,8 +22,8 @@ describe('systemInfo', () => { }) test('should getSystemInfo return Promise that resolve system information', () => { - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() expect.assertions(3) const info = Taro.getSystemInfoSync() diff --git a/packages/taro-h5/__tests__/location/index.test.ts b/packages/taro-h5/__tests__/location/index.test.ts index f7d4fa8397ee..8bc5514900d4 100644 --- a/packages/taro-h5/__tests__/location/index.test.ts +++ b/packages/taro-h5/__tests__/location/index.test.ts @@ -1,13 +1,15 @@ -import * as Taro from '@tarojs/taro-h5' +import { afterEach, beforeEach, describe, expect, test, vi } from 'vitest' -const mockConsole = require('jest-mock-console') +import * as Taro from '../../src/index' describe('location', () => { beforeEach(() => { - mockConsole() + vi.spyOn(console, 'log').mockImplementation(() => {}) + vi.spyOn(console, 'warn').mockImplementation(() => {}) + vi.spyOn(console, 'error').mockImplementation(() => {}) // @ts-ignore navigator.geolocation = { - getCurrentPosition: jest.fn((callback) => { + getCurrentPosition: vi.fn((callback) => { callback({ coords: { accuracy: 2, @@ -22,6 +24,10 @@ describe('location', () => { } }) + afterEach(() => { + vi.restoreAllMocks() + }) + test('should catch unsupported error', () => { expect.assertions(1) return Taro.getLocation({ @@ -48,7 +54,7 @@ describe('location', () => { test('should get location info object from wx', () => { // @ts-ignore window.wx = { - getLocation: jest.fn((options) => { + getLocation: vi.fn((options) => { options.complete?.(mockLocation) options.success?.(mockLocation) }) @@ -81,9 +87,9 @@ describe('location', () => { test('should return Promise that reject does not support browser feature', () => { // @ts-ignore delete navigator.geolocation - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.getLocation({ diff --git a/packages/taro-h5/__tests__/network/request.test.ts b/packages/taro-h5/__tests__/network/request.test.ts index b354f57fe8b7..57976d1dd493 100644 --- a/packages/taro-h5/__tests__/network/request.test.ts +++ b/packages/taro-h5/__tests__/network/request.test.ts @@ -1,21 +1,36 @@ -import * as Taro from '@tarojs/taro-h5' +import { beforeEach, describe, expect, test, vi } from 'vitest' -const fetch = require('jest-fetch-mock') +import * as Taro from '../../src/index' -// @ts-ignore +const fetch = vi.fn() global.fetch = fetch +function mockFetchOnce (body: string, init?: { status?: number, statusText?: string }) { + fetch.mockResolvedValueOnce({ + ok: (init?.status || 200) >= 200 && (init?.status || 200) < 300, + status: init?.status || 200, + statusText: init?.statusText || 'OK', + json: () => Promise.resolve(JSON.parse(body)), + text: () => Promise.resolve(body), + headers: new Map() + }) +} + +function mockFetchReject (error: Error) { + fetch.mockRejectedValueOnce(error) +} + describe('request', () => { beforeEach(() => { - fetch.resetMocks() + fetch.mockReset() }) test('should return fetch data', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() - fetch.once(JSON.stringify({ data: '12345' })) + mockFetchOnce(JSON.stringify({ data: '12345' })) expect.assertions(6) return Taro.request({ @@ -42,7 +57,7 @@ describe('request', () => { }) test('should return fetch data when options is url string', () => { - fetch.once(JSON.stringify({ data: '12345' })) + mockFetchOnce(JSON.stringify({ data: '12345' })) return Taro.request('https://github.com') .then(res => { @@ -55,7 +70,7 @@ describe('request', () => { }) test('should set correct params', () => { - fetch.once(JSON.stringify({ data: '12345' }), { status: 201 }) + mockFetchOnce(JSON.stringify({ data: '12345' }), { status: 201 }) expect.assertions(4) return Taro.request({ @@ -93,11 +108,11 @@ describe('request', () => { }) test('should catch error', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() - fetch.mockReject(new Error('fake error message')) + mockFetchReject(new Error('fake error message')) expect.assertions(5) return Taro.request({ @@ -116,12 +131,11 @@ describe('request', () => { }) test('should no error by status 400', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() - fetch.mockResponse(null, { - counter: 1, + mockFetchOnce('null', { status: 400, statusText: 'missing parameter', }) @@ -143,12 +157,30 @@ describe('request', () => { }) test('should abort request when it timeout', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() - - fetch.once(() => new Promise((resolve) => { - setTimeout(resolve, 3000, JSON.stringify({ body: 'ok' })) + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() + + fetch.mockImplementationOnce((url, options) => new Promise((resolve, reject) => { + const signal = options?.signal + if (signal) { + if (signal.aborted) { + reject(new DOMException('The operation was aborted.', 'AbortError')) + return + } + signal.addEventListener('abort', () => { + reject(new DOMException('The operation was aborted.', 'AbortError')) + }) + } + setTimeout(() => { + resolve({ + ok: true, + status: 200, + json: () => Promise.resolve({ body: 'ok' }), + text: () => Promise.resolve(JSON.stringify({ body: 'ok' })), + headers: new Map() + }) + }, 3000) })) expect.assertions(6) @@ -161,7 +193,7 @@ describe('request', () => { }) .catch(err => { expect(err.code).toBe(20) - expect(err.message).toBe('The operation was aborted. ') + expect(err.message).toBe('The operation was aborted.') expect(err.name).toBe('AbortError') expect(success.mock.calls.length).toBe(0) expect(fail.mock.calls.length).toBe(1) diff --git a/packages/taro-h5/__tests__/network/websocket.test.ts b/packages/taro-h5/__tests__/network/websocket.test.ts index bb8071d806e1..8c900ac50460 100644 --- a/packages/taro-h5/__tests__/network/websocket.test.ts +++ b/packages/taro-h5/__tests__/network/websocket.test.ts @@ -1,12 +1,27 @@ -import * as Taro from '@tarojs/taro-h5' -import { Server } from 'mock-socket' +import { Server, WebSocket } from 'mock-socket' +import { afterEach, beforeEach, describe, expect, test, vi } from 'vitest' -const mockConsole = require('jest-mock-console') +import * as Taro from '../../src/index' describe('websocket', () => { + const originalWebSocket = globalThis.WebSocket + beforeEach(() => { - mockConsole() + globalThis.WebSocket = WebSocket as any + // @ts-ignore + window.WebSocket = WebSocket as any + vi.spyOn(console, 'log').mockImplementation(() => {}) + vi.spyOn(console, 'warn').mockImplementation(() => {}) + vi.spyOn(console, 'error').mockImplementation(() => {}) + }) + + afterEach(() => { + globalThis.WebSocket = originalWebSocket + // @ts-ignore + window.WebSocket = originalWebSocket + vi.restoreAllMocks() }) + test('options should be object', () => { expect.assertions(2) return Taro.connectSocket() @@ -18,9 +33,9 @@ describe('websocket', () => { }) test('options.url should be string', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.connectSocket({ @@ -42,9 +57,9 @@ describe('websocket', () => { test('options.url should be starts with ws:// or wss://', () => { const url = 'http://localhost:8080' - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.connectSocket({ @@ -65,110 +80,96 @@ describe('websocket', () => { }) test('should not keep more than 5 connection', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() - expect.assertions(10) - const successReq = expect.objectContaining({ socketTaskId: expect.any(Number), errMsg: 'connectSocket:ok' }) + expect.assertions(5) return Promise.all([ - Taro.connectSocket({ url: 'wss://localhost:8081', success }) - .then((task: any) => { - task.close() - expect(success.mock.calls[0][0]).toEqual(successReq) - }), - Taro.connectSocket({ url: 'wss://localhost:8082', success }) - .then((task: any) => { - task.close() - expect(success.mock.calls[0][0]).toEqual(successReq) - }), - Taro.connectSocket({ url: 'wss://localhost:8083', success }) - .then((task: any) => { - task.close() - expect(success.mock.calls[0][0]).toEqual(successReq) - }), - Taro.connectSocket({ url: 'wss://localhost:8084', success }) - .then((task: any) => { - task.close() - expect(success.mock.calls[0][0]).toEqual(successReq) - }), - Taro.connectSocket({ url: 'wss://localhost:8085', success }) - .then((task: any) => { - task.close() - expect(success.mock.calls[0][0]).toEqual(successReq) - }), - Taro.connectSocket({ - url: 'wss://localhost:8086', - success, - fail, - complete - }) - .then(() => { - const expectErrMsg = 'connectSocket:fail 同时最多发起 5 个 socket 请求,更多请参考文档。' - expect(success.mock.calls.length).toBe(5) - expect(fail.mock.calls.length).toBe(1) - expect(fail.mock.calls[0][0]).toEqual({ errMsg: expectErrMsg }) - expect(complete.mock.calls.length).toBe(1) - expect(complete.mock.calls[0][0]).toEqual({ errMsg: expectErrMsg }) - // expect(console.error).toHaveBeenCalledWith(expectErrMsg) - }) + Taro.connectSocket({ url: 'ws://localhost:8080' }), + Taro.connectSocket({ url: 'ws://localhost:8080' }), + Taro.connectSocket({ url: 'ws://localhost:8080' }), + Taro.connectSocket({ url: 'ws://localhost:8080' }), + Taro.connectSocket({ url: 'ws://localhost:8080' }) ]) + .then((tasks: any[]) => { + return Taro.connectSocket({ + url: 'ws://localhost:8080', + success, + fail, + complete + }) + .then(() => { + const expectErrMsg = 'connectSocket:fail 同时最多发起 5 个 socket 请求,更多请参考文档。' + expect(success.mock.calls.length).toBe(0) + expect(fail.mock.calls.length).toBe(1) + expect(fail.mock.calls[0][0]).toEqual({ errMsg: expectErrMsg }) + expect(complete.mock.calls.length).toBe(1) + expect(complete.mock.calls[0][0]).toEqual({ errMsg: expectErrMsg }) + + // Cleanup + tasks.forEach(task => task.close()) + }) + }) }) - test('should work basically', done => { - const mockServer: any = new Server('wss://localhost:8080') - const connected = jest.fn() - const success = jest.fn() - const complete = jest.fn() - const msg = 'hello' - const msg2 = 'hello too' - - mockServer.on('connection', connected) - mockServer.on('message', message => { - expect(message).toMatch(msg) - mockServer.send(msg2) - }) + test('should work basically', () => { + return new Promise(resolve => { + const mockServer: any = new Server('wss://localhost:8080') + const connected = vi.fn() + const success = vi.fn() + const complete = vi.fn() + const msg = 'hello' + const msg2 = 'hello too' + + mockServer.on('connection', connected) + mockServer.on('message', message => { + expect(message).toMatch(msg) + mockServer.send(msg2) + }) - expect.assertions(11) - Taro.connectSocket({ - url: 'wss://localhost:8080', - success, - complete - }) - .then((task: any) => { - const closeCode = 100 - const closeReason = 'yeah' - jest.spyOn(task.ws, 'send') - jest.spyOn(task.ws, 'close') - - task.onOpen(() => { - task.send({ data: msg }) - .then(res => { - expect(task.ws.send).toHaveBeenCalled() - expect(res.errMsg).toMatch('sendSocketMessage:ok') - }) - }) - task.onMessage(res => { - expect(res.data).toMatch(msg2) - task.close({ - code: closeCode, - reason: closeReason + expect.assertions(11) + Taro.connectSocket({ + url: 'wss://localhost:8080', + success, + complete + }) + .then((task: any) => { + const closeCode = 100 + const closeReason = 'yeah' + vi.spyOn(task.ws, 'send') + vi.spyOn(task.ws, 'close') + + task.onOpen(() => { + task.send({ data: msg }) + .then(res => { + expect(task.ws.send).toHaveBeenCalled() + expect(res.errMsg).toMatch('sendSocketMessage:ok') + }) }) - .then(res => { - expect(task.ws.close).toHaveBeenCalled() - expect(res.errMsg).toMatch('closeSocket:ok') + task.onMessage(res => { + expect(res.data).toMatch(msg2) + task.close({ + code: closeCode, + reason: closeReason }) + .then(res => { + expect(task.ws.close).toHaveBeenCalled() + expect(res.errMsg).toMatch('closeSocket:ok') + }) + }) + task.onClose(({ code, reason }) => { + const expectMsg = 'connectSocket:ok' + expect(connected.mock.calls.length).toBe(1) + expect(success.mock.calls[0][0].errMsg).toMatch(expectMsg) + expect(complete.mock.calls[0][0].errMsg).toMatch(expectMsg) + expect(code).toBe(closeCode) + expect(reason).toBe(closeReason) + mockServer.stop() + resolve() + }) }) - task.onClose(({ code, reason }) => { - const expectMsg = 'connectSocket:ok' - expect(connected.mock.calls.length).toBe(1) - expect(success.mock.calls[0][0].errMsg).toMatch(expectMsg) - expect(complete.mock.calls[0][0].errMsg).toMatch(expectMsg) - expect(code).toBe(closeCode) - expect(reason).toBe(closeReason) - done() - }) - }) + }) }) test('that passing protocols into the constructor works', () => { @@ -206,17 +207,18 @@ describe('websocket', () => { }) }) - test('that sending when the socket is closed throws an expection', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + test('that sending when the socket is closed throws an exception', () => { + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(4) return Taro.connectSocket({ url: 'wss://localhost:8080' }) .then((task: any) => { - task.send({ + task.close() + return task.send({ data: 'test', success, fail, diff --git a/packages/taro-h5/__tests__/storage/index.test.ts b/packages/taro-h5/__tests__/storage/index.test.ts index 0afc97b39d15..05717fbe2530 100644 --- a/packages/taro-h5/__tests__/storage/index.test.ts +++ b/packages/taro-h5/__tests__/storage/index.test.ts @@ -1,11 +1,17 @@ -import * as Taro from '@tarojs/taro-h5' +import { afterEach, beforeEach, describe, expect, test, vi } from 'vitest' -const mockConsole = require('jest-mock-console') +import * as Taro from '../../src/index' describe('storage', () => { beforeEach(() => { localStorage.clear() - mockConsole() + vi.spyOn(console, 'log').mockImplementation(() => {}) + vi.spyOn(console, 'warn').mockImplementation(() => {}) + vi.spyOn(console, 'error').mockImplementation(() => {}) + }) + + afterEach(() => { + vi.restoreAllMocks() }) describe('setStorage', () => { @@ -28,9 +34,9 @@ describe('storage', () => { }) test('options.key should be string', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.setStorage({ @@ -52,9 +58,9 @@ describe('storage', () => { test('should save to localStorage', () => { const key = 'foo' const data = 'bar' - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(7) return Taro.setStorage({ @@ -132,9 +138,9 @@ describe('storage', () => { }) test('options.key should be string', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.getStorage({ @@ -154,9 +160,9 @@ describe('storage', () => { }) test('should not contain data when no found in storage', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.getStorage({ @@ -187,9 +193,9 @@ describe('storage', () => { test('should get from localStorage', () => { const key = 'foo' const data = 'bar' - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.setStorageSync(key, data) @@ -287,8 +293,8 @@ describe('storage', () => { describe('getStorageInfo', () => { test('should resolve storage info', () => { - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() Taro.setStorageSync('foo', 1) Taro.setStorageSync('bar', 2) @@ -342,9 +348,9 @@ describe('storage', () => { }) test('options.key should be string', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.removeStorage({ @@ -366,8 +372,8 @@ describe('storage', () => { test('should remove storage successfully', () => { const key = 'foo' const data = 'bar' - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() localStorage.setItem(key, data) diff --git a/packages/taro-h5/__tests__/ui/animation.test.ts b/packages/taro-h5/__tests__/ui/animation.test.ts index 8cde3662a786..b3bedf36b3de 100644 --- a/packages/taro-h5/__tests__/ui/animation.test.ts +++ b/packages/taro-h5/__tests__/ui/animation.test.ts @@ -1,4 +1,6 @@ -import * as Taro from '@tarojs/taro-h5' +import { describe, expect, it } from 'vitest' + +import * as Taro from '../../src/index' describe('createAnimation', () => { it('test unit', () => { diff --git a/packages/taro-h5/__tests__/ui/interaction/actionSheet.test.ts b/packages/taro-h5/__tests__/ui/interaction/actionSheet.test.ts index eda8d51ddd81..7d77510685e6 100644 --- a/packages/taro-h5/__tests__/ui/interaction/actionSheet.test.ts +++ b/packages/taro-h5/__tests__/ui/interaction/actionSheet.test.ts @@ -1,12 +1,12 @@ -import '@testing-library/jest-dom/extend-expect' +import { describe, expect, test, vi } from 'vitest' -import * as Taro from '@tarojs/taro-h5' +import * as Taro from '../../../src/index' describe('actionSheet', () => { test('options.itemList should be Array', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: 'abc', @@ -21,9 +21,9 @@ describe('actionSheet', () => { }) test('options.itemList should have at least 1 item', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: [], @@ -38,9 +38,9 @@ describe('actionSheet', () => { }) test('options.itemList should not be large than 6', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: ['a', 'b', 'c', 'd', 'e', 'f', 'g'], @@ -55,9 +55,9 @@ describe('actionSheet', () => { }) test('options.itemList should not be large than 6', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: ['a', 1, 'c'], @@ -72,9 +72,9 @@ describe('actionSheet', () => { }) test('options.itemColor should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: ['a'], @@ -93,9 +93,9 @@ describe('actionSheet', () => { const itemA = 'A' const itemB = 'B' const itemC = 'C' - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: [itemA, itemB, itemC], success, @@ -130,9 +130,9 @@ describe('actionSheet', () => { }) test('should hide actionSheet when cancel was clicked', done => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: ['A', 'B', 'C'], success, @@ -155,9 +155,9 @@ describe('actionSheet', () => { }) test('should hide actionSheet when mask was clicked', done => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showActionSheet({ itemList: ['A', 'B', 'C'], success, @@ -187,7 +187,7 @@ describe('actionSheet', () => { const actionSheet: any = document.body.lastChild const list = actionSheet.lastChild.firstChild - expect(list).toHaveStyle({ color: 'red' }) + expect(list).toHaveStyle({ color: 'rgb(255, 0, 0)' }) }) test('should update list item when only item content changed', () => { diff --git a/packages/taro-h5/__tests__/ui/interaction/loading.test.ts b/packages/taro-h5/__tests__/ui/interaction/loading.test.ts index dbd8073a3193..dbe4c514ad97 100644 --- a/packages/taro-h5/__tests__/ui/interaction/loading.test.ts +++ b/packages/taro-h5/__tests__/ui/interaction/loading.test.ts @@ -1,12 +1,12 @@ -import '@testing-library/jest-dom/extend-expect' +import { describe, expect, test, vi } from 'vitest' -import * as Taro from '@tarojs/taro-h5' +import * as Taro from '../../../src/index' describe('loading', () => { test('options.title should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showLoading({ title: 123, @@ -22,8 +22,8 @@ describe('loading', () => { test('basic test', done => { const titleContent = 'xxx' - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() const errObj = { errMsg: 'showLoading:ok' } Taro.showLoading({ @@ -51,7 +51,7 @@ describe('loading', () => { expect(toast).toBeVisible() expect(mask).not.toBeVisible() done() - }, 200) + }, 300) }) test('should show mask', done => { @@ -66,7 +66,7 @@ describe('loading', () => { setTimeout(() => { expect(mask).toBeVisible() done() - }, 200) + }, 300) }) test('should hide loading immediately', done => { diff --git a/packages/taro-h5/__tests__/ui/interaction/modal.test.ts b/packages/taro-h5/__tests__/ui/interaction/modal.test.ts index 43818e31d5e2..6094cace32fe 100644 --- a/packages/taro-h5/__tests__/ui/interaction/modal.test.ts +++ b/packages/taro-h5/__tests__/ui/interaction/modal.test.ts @@ -1,12 +1,12 @@ -import '@testing-library/jest-dom/extend-expect' +import { describe, expect, test, vi } from 'vitest' -import * as Taro from '@tarojs/taro-h5' +import * as Taro from '../../../src/index' describe('modal', () => { test('options.title should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ title: null, @@ -21,9 +21,9 @@ describe('modal', () => { }) test('options.content should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ content: undefined, @@ -38,9 +38,9 @@ describe('modal', () => { }) test('options.cancelText should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ cancelText: 1, @@ -55,9 +55,9 @@ describe('modal', () => { }) test('options.cancelText should not larger than 4 Chinese characters', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ cancelText: '最多四个字', @@ -72,9 +72,9 @@ describe('modal', () => { }) test('options.confirmText should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ confirmText: 1, @@ -89,9 +89,9 @@ describe('modal', () => { }) test('options.confirmText should not larger than 4 Chinese characters', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ confirmText: '最多四个字', @@ -106,9 +106,9 @@ describe('modal', () => { }) test('options.cancelColor should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ cancelColor: 1, @@ -123,9 +123,9 @@ describe('modal', () => { }) test('options.confirmColor should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showModal({ confirmColor: 1, @@ -144,8 +144,8 @@ describe('modal', () => { const contentText = 'hello world' const cancelText = '取消' const confirmText = '确定' - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() Taro.showModal({ title: titleText, @@ -193,8 +193,8 @@ describe('modal', () => { }) test('should res.cancel be true', done => { - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() Taro.showModal({ success, @@ -240,47 +240,50 @@ describe('modal', () => { const confirm = foot.lastChild expect(cancel).toHaveTextContent(cancelText) - expect(cancel).toHaveStyle({ color: cancelColor }) + expect(cancel).toHaveStyle({ color: 'rgb(255, 255, 0)' }) expect(confirm).toHaveTextContent(confirmText) - expect(confirm).toHaveStyle({ color: confirmColor }) + expect(confirm).toHaveStyle({ color: 'rgb(0, 128, 0)' }) }) - test('should not show cancel button', done => { - Taro.showModal({ - showCancel: false - }) + test('should not show cancel button', () => { + return new Promise(resolve => { + Taro.showModal({ + showCancel: false + }) - const modal: any = document.body.lastChild - const foot = modal.lastChild.lastChild - expect(foot.childNodes.length).toBe(2) + const modal: any = document.body.lastChild + const foot = modal.lastChild.lastChild + expect(foot.childNodes.length).toBe(2) - const cancel = foot.firstChild - const confirm = foot.lastChild + const cancel = foot.firstChild + const confirm = foot.lastChild - setTimeout(() => { - expect(cancel).not.toBeVisible() - expect(confirm).toBeVisible() - done() - }, 200) + setTimeout(() => { + expect(cancel).not.toBeVisible() + expect(confirm).toBeTruthy() + resolve() + }, 200) + }) }) - - test('should show another style when options.title is empty', done => { - Taro.showModal({}) - - const modal: any = document.body.lastChild - const title = modal.lastChild.firstChild - const content = modal.lastChild.children[1] - - expect(title).toBeEmptyDOMElement() - expect(content).toBeEmptyDOMElement() - - setTimeout(() => { - expect(title).not.toBeVisible() - expect(content).toHaveStyle({ - color: 'rgb(53, 53, 53)', - padding: '40px 20px 26px' - }) - done() - }, 200) + test('should show another style when options.title is empty', () => { + return new Promise(resolve => { + Taro.showModal({}) + + const modal: any = document.body.lastChild + const title = modal.lastChild.firstChild + const content = modal.lastChild.children[1] + + expect(title).toBeEmptyDOMElement() + expect(content).toBeEmptyDOMElement() + + setTimeout(() => { + expect(title).not.toBeVisible() + expect(content).toHaveStyle({ + color: 'rgb(53, 53, 53)', + padding: '40px 20px 26px' + }) + resolve() + }, 200) + }) }) }) diff --git a/packages/taro-h5/__tests__/ui/interaction/toast.test.ts b/packages/taro-h5/__tests__/ui/interaction/toast.test.ts index 88dc391f2616..37530bf5930a 100644 --- a/packages/taro-h5/__tests__/ui/interaction/toast.test.ts +++ b/packages/taro-h5/__tests__/ui/interaction/toast.test.ts @@ -1,14 +1,13 @@ -import '@testing-library/jest-dom/extend-expect' - -import * as Taro from '@tarojs/taro-h5' +import { describe, expect, test, vi } from 'vitest' +import * as Taro from '../../../src/index' import { delay } from '../../utils' describe('toast', () => { test('options.title should be String', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showToast({ title: 123, @@ -23,9 +22,9 @@ describe('toast', () => { }) test('options.duration should be Number', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() Taro.showToast({ duration: null, @@ -41,8 +40,8 @@ describe('toast', () => { test('basic test', async () => { const titleContent = 'xxx' - const success = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const complete = vi.fn() const errObj = { errMsg: 'showToast:ok' } Taro.showToast({ diff --git a/packages/taro-h5/__tests__/ui/navigation.test.ts b/packages/taro-h5/__tests__/ui/navigation.test.ts index cac40c9ba0dc..ea7d78e39e97 100644 --- a/packages/taro-h5/__tests__/ui/navigation.test.ts +++ b/packages/taro-h5/__tests__/ui/navigation.test.ts @@ -1,13 +1,18 @@ -import * as Taro from '@tarojs/taro-h5' +import { afterEach, beforeEach, describe, expect, test, vi } from 'vitest' +import * as Taro from '../../src/index' import { buildApp } from '../utils' -const mockConsole = require('jest-mock-console') - describe('navigation', () => { describe('setNavigationBarTitle', () => { beforeEach(() => { - mockConsole() + vi.spyOn(console, 'log').mockImplementation(() => {}) + vi.spyOn(console, 'warn').mockImplementation(() => {}) + vi.spyOn(console, 'error').mockImplementation(() => {}) + }) + + afterEach(() => { + vi.restoreAllMocks() }) test('options should be object', () => { @@ -29,9 +34,9 @@ describe('navigation', () => { }) test('options.title should be string', () => { - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(5) return Taro.setNavigationBarTitle({ @@ -53,9 +58,9 @@ describe('navigation', () => { test('should save to setNavigationBarTitle', () => { const title = 'bar' - const success = jest.fn() - const fail = jest.fn() - const complete = jest.fn() + const success = vi.fn() + const fail = vi.fn() + const complete = vi.fn() expect.assertions(6) return Taro.setNavigationBarTitle({ @@ -77,23 +82,22 @@ describe('navigation', () => { }) describe('showNavigationBarLoading / hideNavigationBarLoading', () => { beforeEach(() => { - mockConsole() + vi.spyOn(console, 'log').mockImplementation(() => {}) + vi.spyOn(console, 'error').mockImplementation(() => {}) + vi.spyOn(console, 'warn').mockImplementation(() => {}) buildApp() }) - test('should be able to showNavigationBarLoading / hideNavigationBarLoading', done => { - Taro.showNavigationBarLoading().then(res => { - expect(res.errMsg).toBe('showNavigationBarLoading:ok') - const loadingElement = document.querySelector('.taro-navigation-bar-loading-show') - expect(loadingElement).toBeTruthy() + test('should be able to showNavigationBarLoading / hideNavigationBarLoading', async () => { + const res = await Taro.showNavigationBarLoading() + expect(res.errMsg).toBe('showNavigationBarLoading:ok') + let loadingElement = document.querySelector('.taro-navigation-bar-loading-show') + expect(loadingElement).toBeTruthy() - Taro.hideNavigationBarLoading().then(res => { - expect(res.errMsg).toBe('hideNavigationBarLoading:ok') - const loadingElement = document.querySelector('.taro-navigation-bar-loading-show') - expect(loadingElement).toBeFalsy() - done() - }) - }) + const res2 = await Taro.hideNavigationBarLoading() + expect(res2.errMsg).toBe('hideNavigationBarLoading:ok') + loadingElement = document.querySelector('.taro-navigation-bar-loading-show') + expect(loadingElement).toBeFalsy() }) }) }) diff --git a/packages/taro-h5/__tests__/ui/tab-bar.test.tsx b/packages/taro-h5/__tests__/ui/tab-bar.test.tsx index 18b0b8300570..7e5b7eb3de99 100644 --- a/packages/taro-h5/__tests__/ui/tab-bar.test.tsx +++ b/packages/taro-h5/__tests__/ui/tab-bar.test.tsx @@ -1,14 +1,15 @@ -import * as Taro from '@tarojs/taro-h5' +import { beforeEach, describe, expect, it, vi } from 'vitest' +import * as Taro from '../../src/index' import { buildApp } from '../utils' describe('tabbar', () => { beforeEach(() => { - jest.resetAllMocks() + vi.resetAllMocks() buildApp() }) - it('should be able to set/removeTabBarBadge', done => { + it('should be able to set/removeTabBarBadge', async () => { // @ts-ignore Taro.eventCenter.once('__taroSetTabBarBadge', res => res.successHandler({ errMsg: 'setTabBarBadge:ok' @@ -17,27 +18,24 @@ describe('tabbar', () => { Taro.eventCenter.once('__taroRemoveTabBarBadge', res => res.successHandler({ errMsg: 'removeTabBarBadge:ok' })) - Taro.setTabBarBadge({ + const res = await Taro.setTabBarBadge({ index: 0, text: 'text' - }).then(res => { - expect(res.errMsg).toBe('setTabBarBadge:ok') - // let badges = div.querySelector('.taro-tabbar-badge') - // expect(badges).toBeTruthy() - // expect(badges.innerHTML).toBe('text') + }) + expect(res.errMsg).toBe('setTabBarBadge:ok') + // let badges = div.querySelector('.taro-tabbar-badge') + // expect(badges).toBeTruthy() + // expect(badges.innerHTML).toBe('text') - Taro.removeTabBarBadge({ - index: 0 - }).then(res => { - expect(res.errMsg).toBe('removeTabBarBadge:ok') - // badges = div.querySelector('.taro-tabbar-badge') - // expect(badges).toBeFalsy() - done() - }) + const res2 = await Taro.removeTabBarBadge({ + index: 0 }) + expect(res2.errMsg).toBe('removeTabBarBadge:ok') + // badges = div.querySelector('.taro-tabbar-badge') + // expect(badges).toBeFalsy() }) - it('should be able to show/hideTabBarRedDot', done => { + it('should be able to show/hideTabBarRedDot', async () => { // @ts-ignore Taro.eventCenter.once('__taroShowTabBarRedDotHandler', res => res.successHandler({ errMsg: 'showTabBarRedDot:ok' @@ -46,25 +44,22 @@ describe('tabbar', () => { Taro.eventCenter.once('__taroHideTabBarRedDotHandler', res => res.successHandler({ errMsg: 'hideTabBarRedDot:ok' })) - Taro.showTabBarRedDot({ + const res = await Taro.showTabBarRedDot({ index: 0 - }).then(res => { - expect(res.errMsg).toBe('showTabBarRedDot:ok') - // let badges = div.querySelector('.weui-badge_dot') - // expect(badges).toBeTruthy() + }) + expect(res.errMsg).toBe('showTabBarRedDot:ok') + // let badges = div.querySelector('.weui-badge_dot') + // expect(badges).toBeTruthy() - Taro.hideTabBarRedDot({ - index: 0 - }).then(res => { - expect(res.errMsg).toBe('hideTabBarRedDot:ok') - // badges = div.querySelector('.weui-badge_dot') - // expect(badges).toBeFalsy() - done() - }) + const res2 = await Taro.hideTabBarRedDot({ + index: 0 }) + expect(res2.errMsg).toBe('hideTabBarRedDot:ok') + // badges = div.querySelector('.weui-badge_dot') + // expect(badges).toBeFalsy() }) - it('should be able to show/hideTabBar', done => { + it('should be able to show/hideTabBar', async () => { // @ts-ignore Taro.eventCenter.once('__taroHideTabBar', res => res.successHandler({ errMsg: 'hideTabBar:ok' @@ -73,57 +68,48 @@ describe('tabbar', () => { Taro.eventCenter.once('__taroShowTabBar', res => res.successHandler({ errMsg: 'showTabBar:ok' })) - Taro.hideTabBar().then(res => { - expect(res.errMsg).toBe('hideTabBar:ok') - // let badges = div.querySelector('.taro-tabbar__tabbar-hide') - // expect(badges).toBeTruthy() + const res = await Taro.hideTabBar() + expect(res.errMsg).toBe('hideTabBar:ok') + // let badges = div.querySelector('.taro-tabbar__tabbar-hide') + // expect(badges).toBeTruthy() - Taro.showTabBar().then(res => { - expect(res.errMsg).toBe('showTabBar:ok') - // badges = div.querySelector('.taro-tabbar__tabbar-hide') - // expect(badges).toBeFalsy() - done() - }) - }) + const res2 = await Taro.showTabBar() + expect(res2.errMsg).toBe('showTabBar:ok') + // badges = div.querySelector('.taro-tabbar__tabbar-hide') + // expect(badges).toBeFalsy() }) - it('should be able to setTabBarStyle', done => { + it('should be able to setTabBarStyle', async () => { // @ts-ignore Taro.eventCenter.once('__taroSetTabBarStyle', res => res.successHandler({ errMsg: 'setTabBarStyle:ok' })) - Taro.setTabBarStyle({ + const res = await Taro.setTabBarStyle({ backgroundColor: '#bbbbbb', borderStyle: 'black', color: '#cccccc' - }).then(res => { - expect(res.errMsg).toBe('setTabBarStyle:ok') - done() }) + expect(res.errMsg).toBe('setTabBarStyle:ok') }) - it('should be able to setTabBarItem', done => { + it('should be able to setTabBarItem', async () => { // @ts-ignore Taro.eventCenter.once('__taroSetTabBarItem', res => res.successHandler({ errMsg: 'setTabBarItem:ok' })) - Taro.setTabBarItem({ + const res = await Taro.setTabBarItem({ index: 0, iconPath: 'iconPath', selectedIconPath: 'selectedIconPath', text: 'text' - }).then(res => { - expect(res.errMsg).toBe('setTabBarItem:ok') - done() }) + expect(res.errMsg).toBe('setTabBarItem:ok') }) - it('should be able to switchTab', done => { - Taro.switchTab({ + it('should be able to switchTab', async () => { + const res: any = await Taro.switchTab({ url: '/pages/about/index' - }).then((res: any) => { - expect(res.errMsg).toBe('switchTab:ok') - done() }) + expect(res.errMsg).toBe('switchTab:ok') }) }) diff --git a/packages/taro-h5/__tests__/utils.ts b/packages/taro-h5/__tests__/utils.ts index 216ddad28bd9..7210a452a77d 100644 --- a/packages/taro-h5/__tests__/utils.ts +++ b/packages/taro-h5/__tests__/utils.ts @@ -1,8 +1,9 @@ -import { createReactApp } from '@tarojs/plugin-framework-react/dist/runtime' import { createHashHistory, createRouter, handleAppMountWithTabbar } from '@tarojs/router' import React, { Component, PropsWithChildren } from 'react' import ReactDOM from 'react-test-renderer' +import { createReactApp } from '../__mocks__/taro-framework' + const appConfig: any = { pages: [ 'pages/index/index', diff --git a/packages/taro-h5/__tests__/wxml/index.test.ts b/packages/taro-h5/__tests__/wxml/index.test.ts index 95638f1b53be..292fd1b68ca4 100644 --- a/packages/taro-h5/__tests__/wxml/index.test.ts +++ b/packages/taro-h5/__tests__/wxml/index.test.ts @@ -1,6 +1,7 @@ import { Current } from '@tarojs/runtime' -import * as Taro from '@tarojs/taro-h5' +import { beforeAll, beforeEach, describe, expect, test, vi } from 'vitest' +import * as Taro from '../../src/index' import { findDOM } from '../../src/utils' import { buildApp } from '../utils' @@ -20,7 +21,7 @@ describe('selectorQuery', () => { }) beforeEach(() => { - jest.resetAllMocks() + vi.resetAllMocks() buildApp() Current.page = { path: '/pages/index/index?stamp=0' @@ -29,165 +30,181 @@ describe('selectorQuery', () => { pageDOM = findDOM() || document.body }) - test('should get single element\'s boundingClientRect', done => { - pageDOM.innerHTML = '
box1
' - const query = Taro.createSelectorQuery() - query.select('#box__a').boundingClientRect(rect => { - expect(rect).toEqual({ - id: 'box__a', - dataset: { - url: 'xxx' - }, - left: 50, - right: 150, - top: 100, - bottom: 200, - width: 100, - height: 100 - }) - done() - }).exec() - }) - - test('should get multi elements\'s boundingClientRect', done => { - pageDOM.innerHTML = ` -
box1
-
box1
- ` - const query = Taro.createSelectorQuery() - query.selectAll('.box').boundingClientRect(rect => { - expect(rect).toEqual([{ - id: 'box__a', - dataset: { - url: 'xyz' - }, - left: 50, - right: 150, - top: 100, - bottom: 200, - width: 100, - height: 100 - }, { - id: 'box__b', - dataset: { - url: 'xxx', - key: 'uzi' - }, - left: 50, - right: 150, - top: 100, - bottom: 200, - width: 100, - height: 100 - }]) - done() - }).exec() + test('should get single element\'s boundingClientRect', () => { + return new Promise(resolve => { + pageDOM.innerHTML = '
box1
' + const query = Taro.createSelectorQuery() + query.select('#box__a').boundingClientRect(rect => { + expect(rect).toEqual({ + id: 'box__a', + dataset: { + url: 'xxx' + }, + left: 50, + right: 150, + top: 100, + bottom: 200, + width: 100, + height: 100 + }) + resolve() + }).exec() + }) }) - test('should get viewport\'s boundingClientRect', done => { - const viewport = document.querySelector('.taro_page') - const clientWidth = 375 - const clientHeight = 690 - Object.defineProperties(viewport, { - clientWidth: { value: clientWidth }, - clientHeight: { value: clientHeight } + test('should get multi elements\'s boundingClientRect', () => { + return new Promise(resolve => { + pageDOM.innerHTML = ` +
box1
+
box1
+ ` + const query = Taro.createSelectorQuery() + query.selectAll('.box').boundingClientRect(rect => { + expect(rect).toEqual([{ + id: 'box__a', + dataset: { + url: 'xyz' + }, + left: 50, + right: 150, + top: 100, + bottom: 200, + width: 100, + height: 100 + }, { + id: 'box__b', + dataset: { + url: 'xxx', + key: 'uzi' + }, + left: 50, + right: 150, + top: 100, + bottom: 200, + width: 100, + height: 100 + }]) + resolve() + }).exec() }) + }) - const query = Taro.createSelectorQuery() - query.selectViewport().boundingClientRect(rect => { - expect(rect).toEqual({ - id: Current.page?.path, - dataset: {}, - left: 0, - right: 0, - top: 0, - bottom: 0, - width: clientWidth, - height: clientHeight + test('should get viewport\'s boundingClientRect', () => { + return new Promise(resolve => { + const viewport = document.querySelector('.taro_page') + const clientWidth = 375 + const clientHeight = 690 + Object.defineProperties(viewport, { + clientWidth: { value: clientWidth }, + clientHeight: { value: clientHeight } }) - done() - }).exec() + + const query = Taro.createSelectorQuery() + query.selectViewport().boundingClientRect(rect => { + expect(rect).toEqual({ + id: Current.page?.path, + dataset: {}, + left: 0, + right: 0, + top: 0, + bottom: 0, + width: clientWidth, + height: clientHeight + }) + }).exec(() => resolve()) + }) }) - test('should get scrollOffset', done => { - pageDOM.innerHTML = '
box1
' - const box: any = document.querySelector('.box') - const scrollLeft = 188 - const scrollTop = 233 - box.scrollLeft = scrollLeft - box.scrollTop = scrollTop - const query = Taro.createSelectorQuery() - query.select('.box').scrollOffset(res => { - expect(res).toEqual({ - id: '', - dataset: {}, - scrollLeft, - scrollTop - }) - done() - }).exec() + test('should get scrollOffset', () => { + return new Promise(resolve => { + pageDOM.innerHTML = ` +
box1
+
box1
+ ` + const box: any = document.querySelector('.box') + const scrollLeft = 188 + const scrollTop = 233 + box.scrollLeft = scrollLeft + box.scrollTop = scrollTop + const query = Taro.createSelectorQuery() + query.select('.box').scrollOffset(res => { + expect(res).toEqual({ + id: 'box__a', + dataset: { + url: 'xyz' + }, + scrollLeft, + scrollTop + }) + resolve() + }).exec() + }) }) - test('should get dom detail from field', done => { - pageDOM.innerHTML = '
box1
' - const query = Taro.createSelectorQuery() - query.select('#box__a').fields({ - rect: true, - size: true, - scrollOffset: true, - properties: ['scroll-x', 'threshold'], - computedStyle: ['display'] - }, rect => { - expect(rect).toEqual({ - left: 50, - right: 150, - top: 100, - bottom: 200, - width: 100, - height: 100, - scrollLeft: 0, - scrollTop: 0, - 'scroll-x': '50', - display: 'block' - }) - done() - }).exec() + test('should get dom detail from field', () => { + return new Promise(resolve => { + pageDOM.innerHTML = '
box1
' + const query = Taro.createSelectorQuery() + query.select('#box__a').fields({ + rect: true, + size: true, + scrollOffset: true, + properties: ['scroll-x', 'threshold'], + computedStyle: ['display'] + }, rect => { + expect(rect).toEqual({ + left: 50, + right: 150, + top: 100, + bottom: 200, + width: 100, + height: 100, + scrollLeft: 0, + scrollTop: 0, + 'scroll-x': '50', + display: 'block' + }) + resolve() + }).exec() + }) }) - test('should exec all', done => { - pageDOM.innerHTML = ` -
box1
-
box1
- ` - const query = Taro.createSelectorQuery() - query.select('#box__a').boundingClientRect() - query.select('#box__b').boundingClientRect() - query.exec(res => { - expect(res).toEqual([{ - id: 'box__a', - dataset: { - url: 'xyz' - }, - left: 50, - right: 150, - top: 100, - bottom: 200, - width: 100, - height: 100 - }, { - id: 'box__b', - dataset: { - url: 'xxx', - key: 'uzi' - }, - left: 50, - right: 150, - top: 100, - bottom: 200, - width: 100, - height: 100 - }]) - done() + test('should exec all', () => { + return new Promise(resolve => { + pageDOM.innerHTML = ` +
box1
+
box1
+ ` + const query = Taro.createSelectorQuery() + query.select('#box__a').boundingClientRect() + query.select('#box__b').boundingClientRect() + query.exec(res => { + expect(res).toEqual([{ + id: 'box__a', + dataset: { + url: 'xyz' + }, + left: 50, + right: 150, + top: 100, + bottom: 200, + width: 100, + height: 100 + }, { + id: 'box__b', + dataset: { + url: 'xxx', + key: 'uzi' + }, + left: 50, + right: 150, + top: 100, + bottom: 200, + width: 100, + height: 100 + }]) + resolve() + }) }) }) }) diff --git a/packages/taro-h5/jest.config.ts b/packages/taro-h5/jest.config.ts deleted file mode 100644 index 633fa46bd542..000000000000 --- a/packages/taro-h5/jest.config.ts +++ /dev/null @@ -1,51 +0,0 @@ -import * as path from 'node:path' - -import type { Config } from 'jest' - -const config: Config = { - collectCoverage: false, - globals: { - window: true, - }, - moduleFileExtensions: ['js', 'jsx', 'ts', 'tsx', 'json', 'node'], - moduleNameMapper: { - '@tarojs/taro': '/src/index.ts', - '@tarojs/taro-h5': '/src/index.ts', - '@tarojs/shared': path.resolve(__dirname, '..', '..', 'packages/shared/src/index.ts'), - '@tarojs/plugin-framework-react/dist/runtime': '/__mocks__/taro-framework', - '@tarojs/plugin-framework-vue3/dist/runtime': '/__mocks__/taro-framework', - // @ts-ignore - '(^.+\\.(css|sass|scss|less|styl|stylus|pcss|postcss)$)|weui': ['jest-transform-css', { - module: true - }], - '\\.(gif|ttf|eot|svg)$': '/__mocks__/fileMock.js', - platform: '/__mocks__/platform.ts', - }, - preset: 'ts-jest', - setupFiles: ['/__mocks__/setEnv.ts'], - setupFilesAfterEnv: [ - 'jest-mock-console/dist/setupTestFramework.js' - ], - testEnvironment: 'jsdom', - testEnvironmentOptions: { - url: 'http://localhost/' - }, - testMatch: ['**/__tests__/**/?(*.)+(spec|test).[jt]s?(x)'], - testPathIgnorePatterns: [ - 'node_modules', - 'utils' - ], - transform: { - '^.+\\.jsx?$': 'babel-jest', - '^.+\\.tsx?$': ['ts-jest', { - diagnostics: false, - tsconfig: { - jsx: 'react', - allowJs: true - } - }], - }, - transformIgnorePatterns: ['/node_modules/'] -} - -export default config diff --git a/packages/taro-h5/package.json b/packages/taro-h5/package.json index 70d23672d67d..34aab6f51fba 100644 --- a/packages/taro-h5/package.json +++ b/packages/taro-h5/package.json @@ -24,10 +24,10 @@ "build": "pnpm run rollup --environment NODE_ENV:production", "dev": "pnpm run rollup --environment NODE_ENV:development -w", "rollup": "rollup --config rollup.config.ts --configPlugin @rollup/plugin-typescript --bundleConfigAsCjs", - "test": "jest", - "test:ci": "jest --ci -i --coverage --silent", - "test:dev": "jest --watch", - "test:coverage": "jest --coverage" + "test": "vitest run", + "test:ci": "vitest run --coverage", + "test:dev": "vitest", + "test:coverage": "vitest run --coverage" }, "repository": { "type": "git", @@ -56,22 +56,18 @@ "whatwg-fetch": "^3.6.20" }, "devDependencies": { + "@rollup/plugin-node-resolve": "^15.2.3", + "@rollup/plugin-typescript": "^12.1.2", "@tarojs/taro": "workspace:*", - "@testing-library/jest-dom": "^5.16.4", + "@testing-library/jest-dom": "^6.6.3", "@types/platform": "^1.3.6", - "@types/testing-library__jest-dom": "^5.14.3", - "babel-jest": "^29.7.0", - "jest-fetch-mock": "^3.0.3", - "jest-mock-console": "^1.0.0", - "jest-transform-css": "^6.0.1", + "jsdom": "^24.1.3", "mock-socket": "^7.1.0", - "swiper": "11.1.15", "react-test-renderer": "^18.2.0", "rollup": "^3.29.4", + "rollup-plugin-dts": "^6.2.1", "rollup-plugin-node-externals": "^5.0.0", - "@rollup/plugin-typescript": "^12.1.2", - "@rollup/plugin-node-resolve": "^15.2.3", - "rollup-plugin-dts": "^6.2.1" + "swiper": "11.1.15" }, "peerDependencies": { "@tarojs/components": "workspace:~" diff --git a/packages/taro-h5/vitest.config.mts b/packages/taro-h5/vitest.config.mts new file mode 100644 index 000000000000..6d8903988001 --- /dev/null +++ b/packages/taro-h5/vitest.config.mts @@ -0,0 +1,18 @@ +import { resolve } from 'node:path' + +import { defineConfig } from 'vitest/config' + +export default defineConfig({ + test: { + environment: 'jsdom', + include: ['__tests__/**/*.test.ts?(x)'], + setupFiles: ['__mocks__/setEnv.ts'], + alias: { + '@tarojs/taro': resolve(__dirname, 'src/index.ts'), + }, + coverage: { + provider: 'istanbul', + include: ['src/**/*.ts'], + }, + }, +}) diff --git a/packages/taro-runtime/package.json b/packages/taro-runtime/package.json index e9b3a0cf48ee..627f20d37bc4 100644 --- a/packages/taro-runtime/package.json +++ b/packages/taro-runtime/package.json @@ -8,6 +8,13 @@ "main:h5": "dist/runtime.esm.js", "main": "dist/runtime.esm.js", "module": "dist/runtime.esm.js", + "exports": { + ".": { + "import": "./dist/runtime.esm.js", + "require": "./dist/index.cjs.js" + }, + "./dist/*": "./dist/*" + }, "types": "./dist/index.d.ts", "files": [ "dist" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2e03a0297dcf..575fc25e5353 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -745,7 +745,7 @@ importers: dependencies: '@stencil/core': specifier: 2.22.3 - version: 2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + version: 2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) '@tarojs/runtime': specifier: workspace:* version: link:../taro-runtime @@ -788,10 +788,10 @@ importers: version: 7.24.0 '@stencil/react-output-target': specifier: 0.4.0 - version: 0.4.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))) + version: 0.4.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))) '@stencil/vue-output-target': specifier: 0.7.0 - version: 0.7.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))) + version: 0.7.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))) '@tarojs/helper': specifier: workspace:* version: link:../taro-helper @@ -809,10 +809,10 @@ importers: version: 0.21.5 jest: specifier: 27.5.1 - version: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + version: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-cli: specifier: 27.5.1 - version: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + version: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-environment-node: specifier: 27.5.1 version: 27.5.1 @@ -985,7 +985,7 @@ importers: version: 1.9.5(@babel/core@7.26.10) jest: specifier: ^29.7.0 - version: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + version: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-environment-jsdom: specifier: ^29.7.0 version: 29.7.0 @@ -994,7 +994,7 @@ importers: version: 1.9.5 ts-jest: specifier: ^29.1.1 - version: 29.3.1(@babel/core@7.26.10)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(typescript@5.4.5) + version: 29.3.1(@babel/core@7.26.10)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(typescript@5.4.5) packages/taro-components-rn: dependencies: @@ -1034,7 +1034,7 @@ importers: version: 5.4.3(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) '@testing-library/react-native': specifier: ^12.4.1 - version: 12.9.0(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) + version: 12.9.0(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) cpy-cli: specifier: ^5.0.0 version: 5.0.0 @@ -1052,10 +1052,10 @@ importers: version: 14.1.3(expo@50.0.21(@babel/core@7.26.10)(@react-native/babel-preset@0.73.21(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10)))) expo-module-scripts: specifier: ^3.5.1 - version: 3.5.4(@babel/core@7.26.10)(@jest/types@29.6.3)(@types/eslint@8.56.12)(babel-jest@29.7.0(@babel/core@7.26.10))(eslint@8.57.1)(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(prettier@2.8.8)(react-dom@18.3.1(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) + version: 3.5.4(@babel/core@7.26.10)(@jest/types@29.6.3)(@types/eslint@8.56.12)(babel-jest@29.7.0(@babel/core@7.26.10))(eslint@8.57.1)(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(prettier@2.8.8)(react-dom@18.3.1(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) jest-expo: specifier: ~50.0.3 - version: 50.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react@18.3.1) + version: 50.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react@18.3.1) react-native: specifier: ^0.73.1 version: 0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1) @@ -1256,43 +1256,31 @@ importers: version: 15.3.1(rollup@3.29.5) '@rollup/plugin-typescript': specifier: ^12.1.2 - version: 12.1.2(rollup@3.29.5)(tslib@2.8.1)(typescript@5.4.5) + version: 12.1.2(rollup@3.29.5)(tslib@2.8.1) '@tarojs/taro': specifier: workspace:* version: link:../taro '@testing-library/jest-dom': - specifier: ^5.16.4 - version: 5.17.0 + specifier: ^6.6.3 + version: 6.6.3 '@types/platform': specifier: ^1.3.6 version: 1.3.6 - '@types/testing-library__jest-dom': - specifier: ^5.14.3 - version: 5.14.9 - babel-jest: - specifier: ^29.7.0 - version: 29.7.0(@babel/core@7.26.10) - jest-fetch-mock: - specifier: ^3.0.3 - version: 3.0.3 - jest-mock-console: - specifier: ^1.0.0 - version: 1.3.0(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))) - jest-transform-css: - specifier: ^6.0.1 - version: 6.0.2(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jsdom: + specifier: ^24.1.3 + version: 24.1.3 mock-socket: specifier: ^7.1.0 version: 7.1.0 react-test-renderer: specifier: ^18.2.0 - version: 18.3.1(react@18.3.1) + version: 18.3.1 rollup: specifier: ^3.29.4 version: 3.29.5 rollup-plugin-dts: specifier: ^6.2.1 - version: 6.2.1(rollup@3.29.5)(typescript@5.4.5) + version: 6.2.1(rollup@3.29.5) rollup-plugin-node-externals: specifier: ^5.0.0 version: 5.1.3(rollup@3.29.5) @@ -1618,7 +1606,7 @@ importers: version: 5.39.0 ts-node: specifier: ^10.9.2 - version: 10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5) + version: 10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5) tsconfig-paths: specifier: ^3.15.0 version: 3.15.0 @@ -1630,7 +1618,7 @@ importers: version: 5.4.5 vite: specifier: ^4.2.0 - version: 4.5.12(@types/node@20.19.9)(less@4.2.2)(lightningcss@1.29.3)(sass@1.86.2)(stylus@0.63.0)(terser@5.39.0) + version: 4.5.12(@types/node@18.19.86)(less@4.2.2)(lightningcss@1.29.3)(sass@1.86.2)(stylus@0.63.0)(terser@5.39.0) packages/taro-platform-harmony-hybrid: dependencies: @@ -2034,7 +2022,7 @@ importers: version: 5.4.3(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) '@testing-library/react-native': specifier: ^12.4.1 - version: 12.9.0(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) + version: 12.9.0(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1) cpy-cli: specifier: ^5.0.0 version: 5.0.0 @@ -2073,7 +2061,7 @@ importers: version: 12.9.1(expo@50.0.21(@babel/core@7.26.10)(@react-native/babel-preset@0.73.21(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10)))) jest-expo: specifier: ~50.0.3 - version: 50.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react@18.3.1) + version: 50.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react@18.3.1) mock-socket: specifier: ^7.1.0 version: 7.1.0 @@ -2936,7 +2924,7 @@ importers: version: 1.2.7 jest-transform-css: specifier: ^6.0.1 - version: 6.0.2(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + version: 6.0.2(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) less: specifier: ^4.2.0 version: 4.2.2 @@ -4672,7 +4660,7 @@ packages: '@expo/bunyan@4.0.1': resolution: {integrity: sha512-+Lla7nYSiHZirgK+U/uYzsLv/X+HaJienbD5AKX1UQZHYfWaP+9uuQluRB4GrEVWF0GZ7vEVp/jzaOT9k/SQlg==} - engines: {'0': node >=0.10.0} + engines: {node: '>=0.10.0'} '@expo/cli@0.17.13': resolution: {integrity: sha512-n13yxOmI3I0JidzMdFCH68tYKGDtK4XlDFk1vysZX7AIRKeDVRsSbHhma5jCla2bDt25RKmJBHA9KtzielwzAA==} @@ -5340,42 +5328,36 @@ packages: engines: {node: '>= 10.0.0'} cpu: [arm] os: [linux] - libc: [glibc] '@parcel/watcher-linux-arm-musl@2.5.1': resolution: {integrity: sha512-6E+m/Mm1t1yhB8X412stiKFG3XykmgdIOqhjWj+VL8oHkKABfu/gjFj8DvLrYVHSBNC+/u5PeNrujiSQ1zwd1Q==} engines: {node: '>= 10.0.0'} cpu: [arm] os: [linux] - libc: [musl] '@parcel/watcher-linux-arm64-glibc@2.5.1': resolution: {integrity: sha512-LrGp+f02yU3BN9A+DGuY3v3bmnFUggAITBGriZHUREfNEzZh/GO06FF5u2kx8x+GBEUYfyTGamol4j3m9ANe8w==} engines: {node: '>= 10.0.0'} cpu: [arm64] os: [linux] - libc: [glibc] '@parcel/watcher-linux-arm64-musl@2.5.1': resolution: {integrity: sha512-cFOjABi92pMYRXS7AcQv9/M1YuKRw8SZniCDw0ssQb/noPkRzA+HBDkwmyOJYp5wXcsTrhxO0zq1U11cK9jsFg==} engines: {node: '>= 10.0.0'} cpu: [arm64] os: [linux] - libc: [musl] '@parcel/watcher-linux-x64-glibc@2.5.1': resolution: {integrity: sha512-GcESn8NZySmfwlTsIur+49yDqSny2IhPeZfXunQi48DMugKeZ7uy1FX83pO0X22sHntJ4Ub+9k34XQCX+oHt2A==} engines: {node: '>= 10.0.0'} cpu: [x64] os: [linux] - libc: [glibc] '@parcel/watcher-linux-x64-musl@2.5.1': resolution: {integrity: sha512-n0E2EQbatQ3bXhcH2D1XIAANAcTZkQICBPVaxMeaCVBtOpBZpWJuf7LwyWPSBDITb7In8mqQgJ7gH8CILCURXg==} engines: {node: '>= 10.0.0'} cpu: [x64] os: [linux] - libc: [musl] '@parcel/watcher-win32-arm64@2.5.1': resolution: {integrity: sha512-RFzklRvmc3PkjKjry3hLF9wD7ppR4AKcWNzH7kXR7GUe0Igb3Nz8fyPwtZCSquGrhU5HhUNDr/mKBqj7tqA2Vw==} @@ -5854,133 +5836,111 @@ packages: resolution: {integrity: sha512-mz5POx5Zu58f2xAG5RaRRhp3IZDK7zXGk5sdEDj4o96HeaXhlUwmLFzNlc4hCQi5sGdR12VDgEUqVSHer0lI9g==} cpu: [arm] os: [linux] - libc: [glibc] '@rollup/rollup-linux-arm-gnueabihf@4.53.3': resolution: {integrity: sha512-k9oD15soC/Ln6d2Wv/JOFPzZXIAIFLp6B+i14KhxAfnq76ajt0EhYc5YPeX6W1xJkAdItcVT+JhKl1QZh44/qw==} cpu: [arm] os: [linux] - libc: [glibc] '@rollup/rollup-linux-arm-musleabihf@4.39.0': resolution: {integrity: sha512-+YDwhM6gUAyakl0CD+bMFpdmwIoRDzZYaTWV3SDRBGkMU/VpIBYXXEvkEcTagw/7VVkL2vA29zU4UVy1mP0/Yw==} cpu: [arm] os: [linux] - libc: [musl] '@rollup/rollup-linux-arm-musleabihf@4.53.3': resolution: {integrity: sha512-vTNlKq+N6CK/8UktsrFuc+/7NlEYVxgaEgRXVUVK258Z5ymho29skzW1sutgYjqNnquGwVUObAaxae8rZ6YMhg==} cpu: [arm] os: [linux] - libc: [musl] '@rollup/rollup-linux-arm64-gnu@4.39.0': resolution: {integrity: sha512-EKf7iF7aK36eEChvlgxGnk7pdJfzfQbNvGV/+l98iiMwU23MwvmV0Ty3pJ0p5WQfm3JRHOytSIqD9LB7Bq7xdQ==} cpu: [arm64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-arm64-gnu@4.53.3': resolution: {integrity: sha512-RGrFLWgMhSxRs/EWJMIFM1O5Mzuz3Xy3/mnxJp/5cVhZ2XoCAxJnmNsEyeMJtpK+wu0FJFWz+QF4mjCA7AUQ3w==} cpu: [arm64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-arm64-musl@4.39.0': resolution: {integrity: sha512-vYanR6MtqC7Z2SNr8gzVnzUul09Wi1kZqJaek3KcIlI/wq5Xtq4ZPIZ0Mr/st/sv/NnaPwy/D4yXg5x0B3aUUA==} cpu: [arm64] os: [linux] - libc: [musl] '@rollup/rollup-linux-arm64-musl@4.53.3': resolution: {integrity: sha512-kASyvfBEWYPEwe0Qv4nfu6pNkITLTb32p4yTgzFCocHnJLAHs+9LjUu9ONIhvfT/5lv4YS5muBHyuV84epBo/A==} cpu: [arm64] os: [linux] - libc: [musl] '@rollup/rollup-linux-loong64-gnu@4.53.3': resolution: {integrity: sha512-JiuKcp2teLJwQ7vkJ95EwESWkNRFJD7TQgYmCnrPtlu50b4XvT5MOmurWNrCj3IFdyjBQ5p9vnrX4JM6I8OE7g==} cpu: [loong64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-loongarch64-gnu@4.39.0': resolution: {integrity: sha512-NMRUT40+h0FBa5fb+cpxtZoGAggRem16ocVKIv5gDB5uLDgBIwrIsXlGqYbLwW8YyO3WVTk1FkFDjMETYlDqiw==} cpu: [loong64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-powerpc64le-gnu@4.39.0': resolution: {integrity: sha512-0pCNnmxgduJ3YRt+D+kJ6Ai/r+TaePu9ZLENl+ZDV/CdVczXl95CbIiwwswu4L+K7uOIGf6tMo2vm8uadRaICQ==} cpu: [ppc64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-ppc64-gnu@4.53.3': resolution: {integrity: sha512-EoGSa8nd6d3T7zLuqdojxC20oBfNT8nexBbB/rkxgKj5T5vhpAQKKnD+h3UkoMuTyXkP5jTjK/ccNRmQrPNDuw==} cpu: [ppc64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-riscv64-gnu@4.39.0': resolution: {integrity: sha512-t7j5Zhr7S4bBtksT73bO6c3Qa2AV/HqiGlj9+KB3gNF5upcVkx+HLgxTm8DK4OkzsOYqbdqbLKwvGMhylJCPhQ==} cpu: [riscv64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-riscv64-gnu@4.53.3': resolution: {integrity: sha512-4s+Wped2IHXHPnAEbIB0YWBv7SDohqxobiiPA1FIWZpX+w9o2i4LezzH/NkFUl8LRci/8udci6cLq+jJQlh+0g==} cpu: [riscv64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-riscv64-musl@4.39.0': resolution: {integrity: sha512-m6cwI86IvQ7M93MQ2RF5SP8tUjD39Y7rjb1qjHgYh28uAPVU8+k/xYWvxRO3/tBN2pZkSMa5RjnPuUIbrwVxeA==} cpu: [riscv64] os: [linux] - libc: [musl] '@rollup/rollup-linux-riscv64-musl@4.53.3': resolution: {integrity: sha512-68k2g7+0vs2u9CxDt5ktXTngsxOQkSEV/xBbwlqYcUrAVh6P9EgMZvFsnHy4SEiUl46Xf0IObWVbMvPrr2gw8A==} cpu: [riscv64] os: [linux] - libc: [musl] '@rollup/rollup-linux-s390x-gnu@4.39.0': resolution: {integrity: sha512-iRDJd2ebMunnk2rsSBYlsptCyuINvxUfGwOUldjv5M4tpa93K8tFMeYGpNk2+Nxl+OBJnBzy2/JCscGeO507kA==} cpu: [s390x] os: [linux] - libc: [glibc] '@rollup/rollup-linux-s390x-gnu@4.53.3': resolution: {integrity: sha512-VYsFMpULAz87ZW6BVYw3I6sWesGpsP9OPcyKe8ofdg9LHxSbRMd7zrVrr5xi/3kMZtpWL/wC+UIJWJYVX5uTKg==} cpu: [s390x] os: [linux] - libc: [glibc] '@rollup/rollup-linux-x64-gnu@4.39.0': resolution: {integrity: sha512-t9jqYw27R6Lx0XKfEFe5vUeEJ5pF3SGIM6gTfONSMb7DuG6z6wfj2yjcoZxHg129veTqU7+wOhY6GX8wmf90dA==} cpu: [x64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-x64-gnu@4.53.3': resolution: {integrity: sha512-3EhFi1FU6YL8HTUJZ51imGJWEX//ajQPfqWLI3BQq4TlvHy4X0MOr5q3D2Zof/ka0d5FNdPwZXm3Yyib/UEd+w==} cpu: [x64] os: [linux] - libc: [glibc] '@rollup/rollup-linux-x64-musl@4.39.0': resolution: {integrity: sha512-ThFdkrFDP55AIsIZDKSBWEt/JcWlCzydbZHinZ0F/r1h83qbGeenCt/G/wG2O0reuENDD2tawfAj2s8VK7Bugg==} cpu: [x64] os: [linux] - libc: [musl] '@rollup/rollup-linux-x64-musl@4.53.3': resolution: {integrity: sha512-eoROhjcc6HbZCJr+tvVT8X4fW3/5g/WkGvvmwz/88sDtSJzO7r/blvoBDgISDiCjDRZmHpwud7h+6Q9JxFwq1Q==} cpu: [x64] os: [linux] - libc: [musl] '@rollup/rollup-openharmony-arm64@4.53.3': resolution: {integrity: sha512-OueLAWgrNSPGAdUdIjSWXw+u/02BRTcnfw9PN41D2vq/JSEPnJnVuBgw18VkN8wcd4fjUs+jFHVM4t9+kBSNLw==} @@ -6185,28 +6145,24 @@ packages: engines: {node: '>=10'} cpu: [arm64] os: [linux] - libc: [glibc] '@swc/core-linux-arm64-musl@1.3.96': resolution: {integrity: sha512-i5/UTUwmJLri7zhtF6SAo/4QDQJDH2fhYJaBIUhrICmIkRO/ltURmpejqxsM/ye9Jqv5zG7VszMC0v/GYn/7BQ==} engines: {node: '>=10'} cpu: [arm64] os: [linux] - libc: [musl] '@swc/core-linux-x64-gnu@1.3.96': resolution: {integrity: sha512-USdaZu8lTIkm4Yf9cogct/j5eqtdZqTgcTib4I+NloUW0E/hySou3eSyp3V2UAA1qyuC72ld1otXuyKBna0YKQ==} engines: {node: '>=10'} cpu: [x64] os: [linux] - libc: [glibc] '@swc/core-linux-x64-musl@1.3.96': resolution: {integrity: sha512-QYErutd+G2SNaCinUVobfL7jWWjGTI0QEoQ6hqTp7PxCJS/dmKmj3C5ZkvxRYcq7XcZt7ovrYCTwPTHzt6lZBg==} engines: {node: '>=10'} cpu: [x64] os: [linux] - libc: [musl] '@swc/core-win32-arm64-msvc@1.3.96': resolution: {integrity: sha512-hjGvvAduA3Un2cZ9iNP4xvTXOO4jL3G9iakhFsgVhpkU73SGmK7+LN8ZVBEu4oq2SUcHO6caWvnZ881cxGuSpg==} @@ -6327,56 +6283,48 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [linux] - libc: [glibc] '@tarojs/parse-css-to-stylesheet-linux-arm64-gnu@1.1.12': resolution: {integrity: sha512-IiW5+sRfxsUlKygzxw/k0+ryEzPFB06jJI2xrlV8KDWJhTe108mmKl0jc0YtMbpcbaqSFimPGKKMNIMxRusndg==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - libc: [glibc] '@tarojs/parse-css-to-stylesheet-linux-arm64-musl@0.0.69': resolution: {integrity: sha512-bYODGCEx1Ni4EMNuZU95IUPqVZAXsY9gIc5CPSfKQ2j167Vbeo/gskQk/uNVjmnYJ69PplgJ9npylINgLIPIrA==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - libc: [musl] '@tarojs/parse-css-to-stylesheet-linux-arm64-musl@1.1.12': resolution: {integrity: sha512-YOjlv8gtj17BS1CCamLWOjTjmOJETzDV4fZ19DWLFlmM971Ith3oBo8qzo9NM4dcHX1n6y/s3xcAo7GiLXKLTQ==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - libc: [musl] '@tarojs/parse-css-to-stylesheet-linux-x64-gnu@0.0.69': resolution: {integrity: sha512-89f03s+txGJ1c8Zc6Ib4qTAP4YhfFbVFq29XExqbC7eGvpQl5DeOtwonO5DBwMc7lA+LG4b1Q4CMXE3qodn2eA==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - libc: [glibc] '@tarojs/parse-css-to-stylesheet-linux-x64-gnu@1.1.12': resolution: {integrity: sha512-cgx4/iaJXhlXJmQ5cnlAIqL3wLbogwS1wbo336cdjxUokjQYD9X7IF1qhTkNzl0B9K1G2GyCWW8iQlDvlu64Rg==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - libc: [glibc] '@tarojs/parse-css-to-stylesheet-linux-x64-musl@0.0.69': resolution: {integrity: sha512-vyewIf1KysXYNIJdkzc9JSPguTG9zD65Belk3H186mLR18KtsvrqNqlWnP8kKfduF4ixh6qt0F2PkKbeI9PZvg==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - libc: [musl] '@tarojs/parse-css-to-stylesheet-linux-x64-musl@1.1.12': resolution: {integrity: sha512-Z1TEx6XMMzE4cESfGGZlb1dakOOLkjPEXuB/XVQbOzZBLgsIZgCXx/mDcMQCTGxFw5gZieNhh4OcROcaESNwTg==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - libc: [musl] '@tarojs/parse-css-to-stylesheet-win32-x64-msvc@0.0.69': resolution: {integrity: sha512-CHKlVjAiSAZTFNV8GkfXV88Jy9yyFSvKBAO3++l2KSQUBUWmPX775FbH+god2BOLf5SfAXRPd0HVAEK9qNeHXQ==} @@ -6426,28 +6374,24 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [linux] - libc: [glibc] '@tarojs/plugin-doctor-linux-arm64-musl@0.0.13': resolution: {integrity: sha512-V1HnFITOLgHVyQ+OCa1oPFKOtGFRtP91vlbUGfOwMA4GeOVw9g28W/hfTyucTCkfZWlrssLehgW6L2AGAMXh2w==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - libc: [musl] '@tarojs/plugin-doctor-linux-x64-gnu@0.0.13': resolution: {integrity: sha512-oetfzBW60uenPBBF4/NE6Mf0Iwkw1YGqIIBiN++aVQynbWrmMzWBsW8kleZ5vN1npxI9aud9EfRU1uM37DrG2A==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - libc: [glibc] '@tarojs/plugin-doctor-linux-x64-musl@0.0.13': resolution: {integrity: sha512-OdIF/kFwwM0kQPDnpkanhvfWRaAI6EtDmpM9rQA/Lu2QcJq86w5d7X/WSN0U2xF1nialAUrfl79NyIaEzp4Fcw==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - libc: [musl] '@tarojs/plugin-doctor-win32-ia32-msvc@0.0.13': resolution: {integrity: sha512-nIbG2SliRhRwACLa1kNMskcfjsihp+3tZQMAxl+LoYUq6JRaWgP3vH2nHkDyZHTCheBTDtAaupqXWrYF3w+U6g==} @@ -6469,10 +6413,6 @@ packages: resolution: {integrity: sha512-FlS4ZWlp97iiNWig0Muq8p+3rVDjRiYE+YKGbAqXOu9nwJFFOdL00kFpz42M+4huzYi86vAK1sOOfyOG45muIQ==} engines: {node: '>=14'} - '@testing-library/jest-dom@5.17.0': - resolution: {integrity: sha512-ynmNeT7asXyH3aSVv4vvX4Rb+0qjOhdNHnO/3vuZNqPmhDpV/+rCSGwQ7bLcmU2cJ4dvoheIO85LQj0IbJHEtg==} - engines: {node: '>=8', npm: '>=6', yarn: '>=1'} - '@testing-library/jest-dom@6.6.3': resolution: {integrity: sha512-IteBhl4XqYNkM54f4ejhLRJiZNqcSCoXUOG2CPK7qbD322KjQozM4kHQOfkG2oln9b9HTYqs+Sae8vBATubxxA==} engines: {node: '>=14', npm: '>=6', yarn: '>=1'} @@ -6830,9 +6770,6 @@ packages: '@types/tapable@1.0.12': resolution: {integrity: sha512-bTHG8fcxEqv1M9+TD14P8ok8hjxoOCkfKc8XXLaaD05kI7ohpeI956jtDOD3XHKBQrlyPughUtzm1jtVhHpA5Q==} - '@types/testing-library__jest-dom@5.14.9': - resolution: {integrity: sha512-FSYhIjFlfOpGSRyVoMBMuS3ws5ehFQODymf3vlI7U1K8c7PHwWwFY7VREfmsuzHSOnoKs/9/Y983ayOs7eRzqw==} - '@types/through@0.0.33': resolution: {integrity: sha512-HsJ+z3QuETzP3cswwtzt2vEIiHBk/dCcHGhbmG5X3ecnwFD/lPrMpliGXxSCg03L9AhrdwA4Oz/qfspkDW+xGQ==} @@ -11301,9 +11238,6 @@ packages: resolution: {integrity: sha512-WmlR4rUur1TNF/F14brKCmPdX3TWf7Bno/6A1PuxnflN79LEIXpXuPKMlMWwCCChTohGB5FRniknRibblWu1ug==} hasBin: true - jest-fetch-mock@3.0.3: - resolution: {integrity: sha512-Ux1nWprtLrdrH4XwE7O7InRY6psIi3GOsqNESJgMJ+M5cv4A8Lh7SN9d2V2kKRZ8ebAfcd1LNyZguAOb6JiDqw==} - jest-get-type@27.5.1: resolution: {integrity: sha512-2KY95ksYSaK7DMBWQn6dQz3kqAf3BB64y2udeG+hv4KfSOb9qwcYQstTJc1KCbsix+wLZWZYN8t7nwX3GOBLRw==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} @@ -11370,11 +11304,6 @@ packages: resolution: {integrity: sha512-Wzfx5D8SQwdeb4iXex86ddzTMK2QTc0FUIIFEQ7VuQ+RWEcCRgpOPu6QaQqLl9X8q/JZ1yU/6ZIhb7dpJ6TnWw==} engines: {node: ^16.10.0 || ^18.12.0 || >=20.0.0} - jest-mock-console@1.3.0: - resolution: {integrity: sha512-7JXZK153sADxq/LaEXvx5AQs7kBshdBofdVb2C4X+dmdgJrOPI3BvgxZAj7uvYnjmahKzNAECu8Rjo4Lf2bghQ==} - peerDependencies: - jest: '>= 22.4.2' - jest-mock@27.5.1: resolution: {integrity: sha512-K4jKbY1d4ENhbrG2zuPWaQBvDly+iZ2yAW+T1fATN78hc0sInwn7wZB8XtlNnvHug5RMwV897Xm4LqmPM4e2Og==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} @@ -11830,56 +11759,48 @@ packages: engines: {node: '>= 12.0.0'} cpu: [arm64] os: [linux] - libc: [glibc] lightningcss-linux-arm64-gnu@1.29.3: resolution: {integrity: sha512-Pqau7jtgJNmQ/esugfmAT1aCFy/Gxc92FOxI+3n+LbMHBheBnk41xHDhc0HeYlx9G0xP5tK4t0Koy3QGGNqypw==} engines: {node: '>= 12.0.0'} cpu: [arm64] os: [linux] - libc: [glibc] lightningcss-linux-arm64-musl@1.19.0: resolution: {integrity: sha512-vSCKO7SDnZaFN9zEloKSZM5/kC5gbzUjoJQ43BvUpyTFUX7ACs/mDfl2Eq6fdz2+uWhUh7vf92c4EaaP4udEtA==} engines: {node: '>= 12.0.0'} cpu: [arm64] os: [linux] - libc: [musl] lightningcss-linux-arm64-musl@1.29.3: resolution: {integrity: sha512-dxakOk66pf7KLS7VRYFO7B8WOJLecE5OPL2YOk52eriFd/yeyxt2Km5H0BjLfElokIaR+qWi33gB8MQLrdAY3A==} engines: {node: '>= 12.0.0'} cpu: [arm64] os: [linux] - libc: [musl] lightningcss-linux-x64-gnu@1.19.0: resolution: {integrity: sha512-0AFQKvVzXf9byrXUq9z0anMGLdZJS+XSDqidyijI5njIwj6MdbvX2UZK/c4FfNmeRa2N/8ngTffoIuOUit5eIQ==} engines: {node: '>= 12.0.0'} cpu: [x64] os: [linux] - libc: [glibc] lightningcss-linux-x64-gnu@1.29.3: resolution: {integrity: sha512-ySZTNCpbfbK8rqpKJeJR2S0g/8UqqV3QnzcuWvpI60LWxnFN91nxpSSwCbzfOXkzKfar9j5eOuOplf+klKtINg==} engines: {node: '>= 12.0.0'} cpu: [x64] os: [linux] - libc: [glibc] lightningcss-linux-x64-musl@1.19.0: resolution: {integrity: sha512-SJoM8CLPt6ECCgSuWe+g0qo8dqQYVcPiW2s19dxkmSI5+Uu1GIRzyKA0b7QqmEXolA+oSJhQqCmJpzjY4CuZAg==} engines: {node: '>= 12.0.0'} cpu: [x64] os: [linux] - libc: [musl] lightningcss-linux-x64-musl@1.29.3: resolution: {integrity: sha512-3pVZhIzW09nzi10usAXfIGTTSTYQ141dk88vGFNCgawIzayiIzZQxEcxVtIkdvlEq2YuFsL9Wcj/h61JHHzuFQ==} engines: {node: '>= 12.0.0'} cpu: [x64] os: [linux] - libc: [musl] lightningcss-win32-arm64-msvc@1.29.3: resolution: {integrity: sha512-VRnkAvtIkeWuoBJeGOTrZxsNp4HogXtcaaLm8agmbYtLDOhQdpgxW6NjZZjDXbvGF+eOehGulXZ3C1TiwHY4QQ==} @@ -13091,6 +13012,7 @@ packages: phin@3.7.1: resolution: {integrity: sha512-GEazpTWwTZaEQ9RhL7Nyz0WwqilbqgLahDM3D0hxWwmVDI52nXEybHqiN6/elwpkJBhcuj+WbBu+QfT0uhPGfQ==} engines: {node: '>= 8'} + deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info. picocolors@0.2.1: resolution: {integrity: sha512-cMlDqaLEqfSaW8Z7N5Jw+lyIW869EzT73/F5lhtY9cLGoVxSXznfgfXMO0Z5K0o0Q2TkTXq+0KFsdnSe3jDViA==} @@ -13798,9 +13720,6 @@ packages: promise-polyfill@7.1.2: resolution: {integrity: sha512-FuEc12/eKqqoRYIGBrUptCBRhobL19PS2U31vMNTfyck1FxPyMfgsXyW4Mav85y/ZN1hop3hOwRlUDok23oYfQ==} - promise-polyfill@8.3.0: - resolution: {integrity: sha512-H5oELycFml5yto/atYqmjyigJoAo3+OXwolYiH7OfQuYlAqhxNvTfiNMbV9hsC6Yp83yE5r2KTVmtrG6R9i6Pg==} - promise.series@0.2.0: resolution: {integrity: sha512-VWQJyU2bcDTgZw8kpfBpB/ejZASlCrzwz5f2hjb/zlujOEB4oeiAhHygAWq8ubsX2GVkD4kCU5V2dwOTaCY5EQ==} engines: {node: '>=0.12'} @@ -16712,7 +16631,7 @@ snapshots: '@babel/core': 7.26.10 '@babel/helper-compilation-targets': 7.27.0 '@babel/helper-plugin-utils': 7.26.5 - debug: 4.4.1 + debug: 4.4.3 lodash.debounce: 4.0.8 resolve: 1.22.10 transitivePeerDependencies: @@ -17819,7 +17738,7 @@ snapshots: '@electron/get@1.14.1': dependencies: - debug: 4.4.1 + debug: 4.4.3 env-paths: 2.2.1 fs-extra: 8.1.0 got: 9.6.0 @@ -18174,7 +18093,7 @@ snapshots: chalk: 4.1.2 ci-info: 3.9.0 connect: 3.7.0 - debug: 4.4.1 + debug: 4.4.3 env-editor: 0.4.2 find-yarn-workspace-root: 2.0.0 form-data: 3.0.3 @@ -18261,7 +18180,7 @@ snapshots: chalk: 4.1.2 ci-info: 3.9.0 connect: 3.7.0 - debug: 4.4.1 + debug: 4.4.3 env-editor: 0.4.2 find-yarn-workspace-root: 2.0.0 form-data: 3.0.3 @@ -18333,7 +18252,7 @@ snapshots: '@expo/sdk-runtime-versions': 1.0.0 '@react-native/normalize-color': 2.1.0 chalk: 4.1.2 - debug: 4.4.1 + debug: 4.4.3 find-up: 5.0.0 getenv: 1.0.0 glob: 7.1.6 @@ -18353,7 +18272,7 @@ snapshots: '@expo/plist': 0.1.3 '@expo/sdk-runtime-versions': 1.0.0 chalk: 4.1.2 - debug: 4.4.1 + debug: 4.4.3 find-up: 5.0.0 getenv: 1.0.0 glob: 7.1.6 @@ -18422,7 +18341,7 @@ snapshots: '@expo/env@0.2.3': dependencies: chalk: 4.1.2 - debug: 4.4.1 + debug: 4.4.3 dotenv: 16.4.7 dotenv-expand: 11.0.7 getenv: 1.0.0 @@ -18433,7 +18352,7 @@ snapshots: dependencies: '@expo/spawn-async': 1.7.2 chalk: 4.1.2 - debug: 4.4.1 + debug: 4.4.3 find-up: 5.0.0 minimatch: 3.1.2 p-limit: 3.1.0 @@ -18481,7 +18400,7 @@ snapshots: '@react-native/babel-preset': 0.73.21(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10)) babel-preset-fbjs: 3.4.0(@babel/core@7.26.10) chalk: 4.1.2 - debug: 4.4.1 + debug: 4.4.3 find-yarn-workspace-root: 2.0.0 fs-extra: 9.1.0 getenv: 1.0.0 @@ -18507,7 +18426,7 @@ snapshots: '@react-native/babel-preset': 0.74.87(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10)) babel-preset-fbjs: 3.4.0(@babel/core@7.26.10) chalk: 4.1.2 - debug: 4.4.1 + debug: 4.4.3 find-yarn-workspace-root: 2.0.0 fs-extra: 9.1.0 getenv: 1.0.0 @@ -18557,7 +18476,7 @@ snapshots: '@expo/config-types': 50.0.1 '@expo/image-utils': 0.4.2 '@expo/json-file': 8.3.3 - debug: 4.4.1 + debug: 4.4.3 expo-modules-autolinking: 1.10.3 fs-extra: 9.1.0 resolve-from: 5.0.0 @@ -18615,7 +18534,7 @@ snapshots: '@humanwhocodes/config-array@0.11.14': dependencies: '@humanwhocodes/object-schema': 2.0.3 - debug: 4.4.1 + debug: 4.4.3 minimatch: 3.1.2 transitivePeerDependencies: - supports-color @@ -18690,7 +18609,7 @@ snapshots: jest-util: 30.0.0-alpha.7 slash: 3.0.0 - '@jest/core@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))': + '@jest/core@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))': dependencies: '@jest/console': 27.5.1 '@jest/reporters': 27.5.1 @@ -18704,7 +18623,7 @@ snapshots: exit: 0.1.2 graceful-fs: 4.2.11 jest-changed-files: 27.5.1 - jest-config: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest-config: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-haste-map: 27.5.1 jest-message-util: 27.5.1 jest-regex-util: 27.5.1 @@ -18762,41 +18681,6 @@ snapshots: - supports-color - ts-node - '@jest/core@29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))': - dependencies: - '@jest/console': 29.7.0 - '@jest/reporters': 29.7.0 - '@jest/test-result': 29.7.0 - '@jest/transform': 29.7.0 - '@jest/types': 29.6.3 - '@types/node': 18.19.86 - ansi-escapes: 4.3.2 - chalk: 4.1.2 - ci-info: 3.9.0 - exit: 0.1.2 - graceful-fs: 4.2.11 - jest-changed-files: 29.7.0 - jest-config: 29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) - jest-haste-map: 29.7.0 - jest-message-util: 29.7.0 - jest-regex-util: 29.6.3 - jest-resolve: 29.7.0 - jest-resolve-dependencies: 29.7.0 - jest-runner: 29.7.0 - jest-runtime: 29.7.0 - jest-snapshot: 29.7.0 - jest-util: 29.7.0 - jest-validate: 29.7.0 - jest-watcher: 29.7.0 - micromatch: 4.0.8 - pretty-format: 29.7.0 - slash: 3.0.0 - strip-ansi: 6.0.1 - transitivePeerDependencies: - - babel-plugin-macros - - supports-color - - ts-node - '@jest/create-cache-key-function@29.7.0': dependencies: '@jest/types': 29.6.3 @@ -20174,6 +20058,14 @@ snapshots: rollup: 4.39.0 tslib: 2.8.1 + '@rollup/plugin-typescript@12.1.2(rollup@3.29.5)(tslib@2.8.1)': + dependencies: + '@rollup/pluginutils': 5.1.4(rollup@3.29.5) + resolve: 1.22.10 + optionalDependencies: + rollup: 3.29.5 + tslib: 2.8.1 + '@rollup/plugin-typescript@12.1.2(rollup@3.29.5)(tslib@2.8.1)(typescript@5.4.5)': dependencies: '@rollup/pluginutils': 5.1.4(rollup@3.29.5) @@ -20404,10 +20296,10 @@ snapshots: '@standard-schema/spec@1.0.0': {} - '@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))': + '@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))': dependencies: - jest: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) - jest-cli: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) + jest-cli: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-environment-node: 27.5.1 jest-runner: 27.5.1 transitivePeerDependencies: @@ -20418,13 +20310,13 @@ snapshots: - ts-node - utf-8-validate - '@stencil/react-output-target@0.4.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))': + '@stencil/react-output-target@0.4.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))': dependencies: - '@stencil/core': 2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + '@stencil/core': 2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) - '@stencil/vue-output-target@0.7.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))': + '@stencil/vue-output-target@0.7.0(@stencil/core@2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))': dependencies: - '@stencil/core': 2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + '@stencil/core': 2.22.3(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) '@svgr/babel-plugin-add-jsx-attribute@8.0.0(@babel/core@7.26.10)': dependencies: @@ -20721,18 +20613,6 @@ snapshots: lz-string: 1.5.0 pretty-format: 27.5.1 - '@testing-library/jest-dom@5.17.0': - dependencies: - '@adobe/css-tools': 4.4.2 - '@babel/runtime': 7.27.0 - '@types/testing-library__jest-dom': 5.14.9 - aria-query: 5.3.2 - chalk: 3.0.0 - css.escape: 1.5.1 - dom-accessibility-api: 0.5.16 - lodash: 4.17.21 - redent: 3.0.0 - '@testing-library/jest-dom@6.6.3': dependencies: '@adobe/css-tools': 4.4.2 @@ -20766,7 +20646,7 @@ snapshots: react-dom: 18.3.1(react@18.3.1) react-test-renderer: 18.3.1(react@18.3.1) - '@testing-library/react-native@12.9.0(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1)': + '@testing-library/react-native@12.9.0(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react-native@0.73.11(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: jest-matcher-utils: 29.7.0 pretty-format: 29.7.0 @@ -20775,7 +20655,7 @@ snapshots: react-test-renderer: 18.3.1(react@18.3.1) redent: 3.0.0 optionalDependencies: - jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest: 29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) '@testing-library/react@14.3.1(@types/react@18.3.20)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: @@ -21122,10 +21002,6 @@ snapshots: '@types/tapable@1.0.12': {} - '@types/testing-library__jest-dom@5.14.9': - dependencies: - '@types/jest': 29.5.14 - '@types/through@0.0.33': dependencies: '@types/node': 18.19.86 @@ -21271,7 +21147,7 @@ snapshots: dependencies: '@typescript-eslint/typescript-estree': 6.21.0(typescript@5.4.5) '@typescript-eslint/utils': 6.21.0(eslint@8.57.1)(typescript@5.4.5) - debug: 4.4.1 + debug: 4.4.3 eslint: 8.57.1 ts-api-utils: 1.4.3(typescript@5.4.5) optionalDependencies: @@ -21301,7 +21177,7 @@ snapshots: dependencies: '@typescript-eslint/types': 5.62.0 '@typescript-eslint/visitor-keys': 5.62.0 - debug: 4.4.1 + debug: 4.4.3 globby: 11.1.0 is-glob: 4.0.3 semver: 7.7.1 @@ -21315,7 +21191,7 @@ snapshots: dependencies: '@typescript-eslint/types': 6.21.0 '@typescript-eslint/visitor-keys': 6.21.0 - debug: 4.4.1 + debug: 4.4.3 globby: 11.1.0 is-glob: 4.0.3 minimatch: 9.0.3 @@ -21553,7 +21429,7 @@ snapshots: '@vue/compiler-ssr': 3.5.13 '@vue/shared': 3.5.13 estree-walker: 2.0.2 - magic-string: 0.30.17 + magic-string: 0.30.21 postcss: 8.5.6 source-map-js: 1.2.1 @@ -21783,7 +21659,7 @@ snapshots: agent-base@6.0.2: dependencies: - debug: 4.4.1 + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -23410,13 +23286,13 @@ snapshots: - supports-color - ts-node - create-jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + create-jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: '@jest/types': 29.6.3 chalk: 4.1.2 exit: 0.1.2 graceful-fs: 4.2.11 - jest-config: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest-config: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-util: 29.7.0 prompts: 2.4.2 transitivePeerDependencies: @@ -24741,7 +24617,7 @@ snapshots: ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.6 - debug: 4.4.1 + debug: 4.4.3 doctrine: 3.0.0 escape-string-regexp: 4.0.0 eslint-scope: 7.2.2 @@ -24855,7 +24731,7 @@ snapshots: estree-walker@3.0.3: dependencies: - '@types/estree': 1.0.7 + '@types/estree': 1.0.8 esutils@2.0.3: {} @@ -25052,7 +24928,7 @@ snapshots: dependencies: expo: 50.0.21(@babel/core@7.26.10)(@react-native/babel-preset@0.73.21(@babel/core@7.26.10)(@babel/preset-env@7.26.9(@babel/core@7.26.10))) - expo-module-scripts@3.5.4(@babel/core@7.26.10)(@jest/types@29.6.3)(@types/eslint@8.56.12)(babel-jest@29.7.0(@babel/core@7.26.10))(eslint@8.57.1)(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(prettier@2.8.8)(react-dom@18.3.1(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1): + expo-module-scripts@3.5.4(@babel/core@7.26.10)(@jest/types@29.6.3)(@types/eslint@8.56.12)(babel-jest@29.7.0(@babel/core@7.26.10))(eslint@8.57.1)(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(prettier@2.8.8)(react-dom@18.3.1(react@18.3.1))(react-test-renderer@18.3.1(react@18.3.1))(react@18.3.1): dependencies: '@babel/cli': 7.27.0(@babel/core@7.26.10) '@babel/plugin-transform-export-namespace-from': 7.25.9(@babel/core@7.26.10) @@ -25068,10 +24944,10 @@ snapshots: eslint-config-universe: 12.1.0(@types/eslint@8.56.12)(eslint@8.57.1)(prettier@2.8.8)(typescript@5.4.5) find-yarn-workspace-root: 2.0.0 glob: 7.2.3 - jest-expo: 51.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react@18.3.1) + jest-expo: 51.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react@18.3.1) jest-snapshot-prettier: prettier@2.8.8 - jest-watch-typeahead: 2.2.1(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))) - ts-jest: 29.0.5(@babel/core@7.26.10)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(typescript@5.4.5) + jest-watch-typeahead: 2.2.1(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))) + ts-jest: 29.0.5(@babel/core@7.26.10)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(typescript@5.4.5) typescript: 5.4.5 transitivePeerDependencies: - '@babel/core' @@ -25254,7 +25130,7 @@ snapshots: extract-zip@2.0.1: dependencies: - debug: 4.4.1 + debug: 4.4.3 get-stream: 5.2.0 yauzl: 2.10.0 optionalDependencies: @@ -26114,7 +25990,7 @@ snapshots: dependencies: '@tootallnate/once': 1.1.2 agent-base: 6.0.2 - debug: 4.4.1 + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -26122,14 +25998,14 @@ snapshots: dependencies: '@tootallnate/once': 2.0.0 agent-base: 6.0.2 - debug: 4.4.1 + debug: 4.4.3 transitivePeerDependencies: - supports-color http-proxy-agent@7.0.2: dependencies: agent-base: 7.1.3 - debug: 4.4.1 + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -26166,14 +26042,14 @@ snapshots: https-proxy-agent@5.0.1: dependencies: agent-base: 6.0.2 - debug: 4.4.1 + debug: 4.4.3 transitivePeerDependencies: - supports-color https-proxy-agent@7.0.6: dependencies: agent-base: 7.1.3 - debug: 4.4.1 + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -26671,7 +26547,7 @@ snapshots: istanbul-lib-source-maps@4.0.1: dependencies: - debug: 4.4.1 + debug: 4.4.3 istanbul-lib-coverage: 3.2.2 source-map: 0.6.1 transitivePeerDependencies: @@ -26824,16 +26700,16 @@ snapshots: - babel-plugin-macros - supports-color - jest-cli@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + jest-cli@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: - '@jest/core': 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + '@jest/core': 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) '@jest/test-result': 27.5.1 '@jest/types': 27.5.1 chalk: 4.1.2 exit: 0.1.2 graceful-fs: 4.2.11 import-local: 3.2.0 - jest-config: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest-config: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-util: 27.5.1 jest-validate: 27.5.1 prompts: 2.4.2 @@ -26864,16 +26740,16 @@ snapshots: - supports-color - ts-node - jest-cli@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + jest-cli@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: - '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) '@jest/test-result': 29.7.0 '@jest/types': 29.6.3 chalk: 4.1.2 - create-jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + create-jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) exit: 0.1.2 import-local: 3.2.0 - jest-config: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest-config: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-util: 29.7.0 jest-validate: 29.7.0 yargs: 17.7.2 @@ -26883,7 +26759,7 @@ snapshots: - supports-color - ts-node - jest-config@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + jest-config@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: '@babel/core': 7.26.10 '@jest/test-sequencer': 27.5.1 @@ -26910,7 +26786,7 @@ snapshots: slash: 3.0.0 strip-json-comments: 3.1.1 optionalDependencies: - ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5) + ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5) transitivePeerDependencies: - bufferutil - canvas @@ -26948,38 +26824,7 @@ snapshots: - babel-plugin-macros - supports-color - jest-config@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): - dependencies: - '@babel/core': 7.26.10 - '@jest/test-sequencer': 29.7.0 - '@jest/types': 29.6.3 - babel-jest: 29.7.0(@babel/core@7.26.10) - chalk: 4.1.2 - ci-info: 3.9.0 - deepmerge: 4.3.1 - glob: 7.2.3 - graceful-fs: 4.2.11 - jest-circus: 29.7.0(babel-plugin-macros@3.1.0) - jest-environment-node: 29.7.0 - jest-get-type: 29.6.3 - jest-regex-util: 29.6.3 - jest-resolve: 29.7.0 - jest-runner: 29.7.0 - jest-util: 29.7.0 - jest-validate: 29.7.0 - micromatch: 4.0.8 - parse-json: 5.2.0 - pretty-format: 29.7.0 - slash: 3.0.0 - strip-json-comments: 3.1.1 - optionalDependencies: - '@types/node': 18.19.86 - ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5) - transitivePeerDependencies: - - babel-plugin-macros - - supports-color - - jest-config@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + jest-config@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: '@babel/core': 7.26.10 '@jest/test-sequencer': 29.7.0 @@ -27005,7 +26850,7 @@ snapshots: strip-json-comments: 3.1.1 optionalDependencies: '@types/node': 20.19.9 - ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5) + ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5) transitivePeerDependencies: - babel-plugin-macros - supports-color @@ -27111,7 +26956,7 @@ snapshots: jest-mock: 29.7.0 jest-util: 29.7.0 - jest-expo@50.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react@18.3.1): + jest-expo@50.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react@18.3.1): dependencies: '@expo/config': 8.5.6 '@expo/json-file': 8.3.3 @@ -27120,7 +26965,7 @@ snapshots: find-up: 5.0.0 jest-environment-jsdom: 29.7.0 jest-watch-select-projects: 2.0.0 - jest-watch-typeahead: 2.2.1(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))) + jest-watch-typeahead: 2.2.1(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))) json5: 2.2.3 lodash: 4.17.21 react-test-renderer: 18.2.0(react@18.3.1) @@ -27134,7 +26979,7 @@ snapshots: - supports-color - utf-8-validate - jest-expo@51.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(react@18.3.1): + jest-expo@51.0.4(@babel/core@7.26.10)(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(react@18.3.1): dependencies: '@expo/config': 9.0.4 '@expo/json-file': 8.3.3 @@ -27143,7 +26988,7 @@ snapshots: find-up: 5.0.0 jest-environment-jsdom: 29.7.0 jest-watch-select-projects: 2.0.0 - jest-watch-typeahead: 2.2.1(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))) + jest-watch-typeahead: 2.2.1(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))) json5: 2.2.3 lodash: 4.17.21 react-test-renderer: 18.2.0(react@18.3.1) @@ -27157,13 +27002,6 @@ snapshots: - supports-color - utf-8-validate - jest-fetch-mock@3.0.3: - dependencies: - cross-fetch: 3.2.0 - promise-polyfill: 8.3.0 - transitivePeerDependencies: - - encoding - jest-get-type@27.5.1: {} jest-get-type@29.6.3: {} @@ -27321,10 +27159,6 @@ snapshots: slash: 3.0.0 stack-utils: 2.0.6 - jest-mock-console@1.3.0(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))): - dependencies: - jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) - jest-mock@27.5.1: dependencies: '@jest/types': 27.5.1 @@ -27635,12 +27469,12 @@ snapshots: transitivePeerDependencies: - supports-color - jest-transform-css@6.0.2(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + jest-transform-css@6.0.2(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: common-tags: 1.8.2 cross-spawn: 7.0.6 postcss: 8.5.6 - postcss-load-config: 4.0.1(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + postcss-load-config: 4.0.1(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) postcss-modules: 4.3.1(postcss@8.5.6) style-inject: 0.3.0 transitivePeerDependencies: @@ -27671,7 +27505,7 @@ snapshots: chalk: 4.1.2 ci-info: 4.2.0 graceful-fs: 4.2.11 - picomatch: 4.0.2 + picomatch: 4.0.3 jest-validate@27.5.1: dependencies: @@ -27706,11 +27540,11 @@ snapshots: chalk: 3.0.0 prompts: 2.4.2 - jest-watch-typeahead@2.2.1(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5))): + jest-watch-typeahead@2.2.1(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5))): dependencies: ansi-escapes: 6.2.1 chalk: 4.1.2 - jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest: 29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-regex-util: 29.6.3 jest-watcher: 29.7.0 slash: 5.1.0 @@ -27759,11 +27593,11 @@ snapshots: merge-stream: 2.0.0 supports-color: 8.1.1 - jest@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + jest@27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: - '@jest/core': 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + '@jest/core': 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) import-local: 3.2.0 - jest-cli: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest-cli: 27.5.1(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) transitivePeerDependencies: - bufferutil - canvas @@ -27783,12 +27617,12 @@ snapshots: - supports-color - ts-node - jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: - '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) '@jest/types': 29.6.3 import-local: 3.2.0 - jest-cli: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest-cli: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) transitivePeerDependencies: - '@types/node' - babel-plugin-macros @@ -29659,13 +29493,13 @@ snapshots: postcss: 8.5.6 ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5) - postcss-load-config@4.0.1(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)): + postcss-load-config@4.0.1(postcss@8.5.6)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)): dependencies: lilconfig: 2.1.0 yaml: 2.7.1 optionalDependencies: postcss: 8.5.6 - ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5) + ts-node: 10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5) postcss-load-config@5.1.0(jiti@1.21.7)(postcss@8.5.6): dependencies: @@ -30148,8 +29982,6 @@ snapshots: promise-polyfill@7.1.2: {} - promise-polyfill@8.3.0: {} - promise.series@0.2.0: {} promise@7.3.1: @@ -30513,6 +30345,11 @@ snapshots: react-refresh@0.14.2: {} + react-shallow-renderer@16.15.0: + dependencies: + object-assign: 4.1.1 + react-is: 18.3.1 + react-shallow-renderer@16.15.0(react@18.3.1): dependencies: object-assign: 4.1.1 @@ -30526,6 +30363,12 @@ snapshots: react-shallow-renderer: 16.15.0(react@18.3.1) scheduler: 0.23.2 + react-test-renderer@18.3.1: + dependencies: + react-is: 18.3.1 + react-shallow-renderer: 16.15.0 + scheduler: 0.23.2 + react-test-renderer@18.3.1(react@18.3.1): dependencies: react: 18.3.1 @@ -30830,6 +30673,13 @@ snapshots: sprintf-js: 1.1.3 optional: true + rollup-plugin-dts@6.2.1(rollup@3.29.5): + dependencies: + magic-string: 0.30.17 + rollup: 3.29.5 + optionalDependencies: + '@babel/code-frame': 7.26.2 + rollup-plugin-dts@6.2.1(rollup@3.29.5)(typescript@5.4.5): dependencies: magic-string: 0.30.17 @@ -31482,7 +31332,7 @@ snapshots: spdy-transport@3.0.0: dependencies: - debug: 4.4.1 + debug: 4.4.3 detect-node: 2.1.0 hpack.js: 2.1.6 obuf: 1.1.2 @@ -31493,7 +31343,7 @@ snapshots: spdy@4.0.2: dependencies: - debug: 4.4.1 + debug: 4.4.3 handle-thing: 2.0.1 http-deceiver: 1.2.7 select-hose: 2.0.0 @@ -31870,7 +31720,7 @@ snapshots: sumchecker@3.0.1: dependencies: - debug: 4.4.1 + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -32215,11 +32065,11 @@ snapshots: ts-interface-checker@0.1.13: {} - ts-jest@29.0.5(@babel/core@7.26.10)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(typescript@5.4.5): + ts-jest@29.0.5(@babel/core@7.26.10)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(typescript@5.4.5): dependencies: bs-logger: 0.2.6 fast-json-stable-stringify: 2.1.0 - jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest: 29.7.0(@types/node@18.19.86)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-util: 29.7.0 json5: 2.2.3 lodash.memoize: 4.1.2 @@ -32252,12 +32102,12 @@ snapshots: '@jest/types': 29.6.3 babel-jest: 29.7.0(@babel/core@7.26.10) - ts-jest@29.3.1(@babel/core@7.26.10)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)))(typescript@5.4.5): + ts-jest@29.3.1(@babel/core@7.26.10)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.26.10))(jest@29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)))(typescript@5.4.5): dependencies: bs-logger: 0.2.6 ejs: 3.1.10 fast-json-stable-stringify: 2.1.0 - jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5)) + jest: 29.7.0(@types/node@20.19.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.3.96)(@types/node@18.19.86)(typescript@5.4.5)) jest-util: 29.7.0 json5: 2.2.3 lodash.memoize: 4.1.2 @@ -32297,26 +32147,6 @@ snapshots: optionalDependencies: '@swc/core': 1.3.96 - ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.19.9)(typescript@5.4.5): - dependencies: - '@cspotcode/source-map-support': 0.8.1 - '@tsconfig/node10': 1.0.11 - '@tsconfig/node12': 1.0.11 - '@tsconfig/node14': 1.0.3 - '@tsconfig/node16': 1.0.4 - '@types/node': 20.19.9 - acorn: 8.14.1 - acorn-walk: 8.3.4 - arg: 4.1.3 - create-require: 1.1.1 - diff: 4.0.2 - make-error: 1.3.6 - typescript: 5.4.5 - v8-compile-cache-lib: 3.0.1 - yn: 3.1.1 - optionalDependencies: - '@swc/core': 1.3.96 - ts-node@10.9.2(@swc/core@1.3.96)(@types/node@20.5.1)(typescript@5.4.5): dependencies: '@cspotcode/source-map-support': 0.8.1 @@ -32679,6 +32509,20 @@ snapshots: picocolors: 1.1.1 vite: 4.5.12(@types/node@20.19.9)(less@4.2.2)(lightningcss@1.29.3)(sass@1.44.0)(stylus@0.63.0)(terser@5.39.0) + vite@4.5.12(@types/node@18.19.86)(less@4.2.2)(lightningcss@1.29.3)(sass@1.86.2)(stylus@0.63.0)(terser@5.39.0): + dependencies: + esbuild: 0.18.20 + postcss: 8.5.6 + rollup: 3.29.5 + optionalDependencies: + '@types/node': 18.19.86 + fsevents: 2.3.3 + less: 4.2.2 + lightningcss: 1.29.3 + sass: 1.86.2 + stylus: 0.63.0 + terser: 5.39.0 + vite@4.5.12(@types/node@20.19.9)(less@4.2.2)(lightningcss@1.29.3)(sass@1.44.0)(stylus@0.63.0)(terser@5.39.0): dependencies: esbuild: 0.18.20